tgif-QPL-4.2.5/0000755000076400007640000000000011602233424012770 5ustar williamwilliamtgif-QPL-4.2.5/wb_seg.c0000644000076400007640000001441311602233314014403 0ustar williamwilliam/* * Author: Denise Jorge de Oliveira in Dec, 1999 * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb_seg.c,v 1.2 2005/07/26 18:30:27 william Exp $ */ #ifndef _SEG_C #define _SEG_C #define _INCLUDE_FROM_WB_SEG_C_ #include "tgifdefs.h" #include "wb_seg.e" struct SegmentationList *first=NULL; struct SegmentationList *last=NULL; /************************************************************************/ static struct SegmentationList *NewNodeList ( struct SegmentationPack Pack ) { struct SegmentationList *indice; indice = (struct SegmentationList *)malloc( sizeof(struct SegmentationList)); memcpy(indice->id, Pack.id, SEG_ID); indice->LogicalClock = Pack.LogicalClock; indice->NumPackets = Pack.NumPackets; indice->ArrivedPcts = 0; indice->Frag = (struct Fragment *)malloc(Pack.NumPackets*(sizeof(struct Fragment))); indice->prev = last; indice->next = NULL; memset( (char *)indice->Frag, 0, Pack.NumPackets*(sizeof(struct Fragment)) ); if( last != NULL ) { last->next = indice; last = indice; } else { first = last = indice; } return( last ); } /************************************************************************/ static void DeleteNode( struct SegmentationList *indice ) { struct SegmentationList *prev, *next; prev = indice->prev; if( prev == NULL ) first = indice->next; else prev->next = indice->next; next = indice->next; if( next == NULL ) last = indice->prev; else next->prev = indice->prev; free( indice->Frag ); free( indice ); } /************************************************************************/ static void NewPacket ( struct SegmentationPack *pack, char *id, char *data, int datasize, int LogicalClock, int NumPackets, int NumSeq) { /* fprintf(stderr, "\n****Antes de Converter %d\n", NumSeq ); */ memcpy(pack->id, id, SEG_ID); memcpy(pack->data, data, SEG_DATA_SIZE); pack->DataSize = htonl(datasize); pack->LogicalClock = htonl(LogicalClock); pack->NumPackets = htonl(NumPackets); pack->NumSeq = htonl(NumSeq); /* fprintf(stderr, "\n&&&&DEPOS de Converter %d\n", pack->NumSeq ); */ } /************************************************************************/ void InitializeSegmentation () { first = last = NULL; } /************************************************************************/ ptrSegPack Segment (char * Buffer, int BufLen, char *id, int LogicalClock, int * NPackets) { int divisor; int offset; int i; int qtd; char aux[SEG_DATA_SIZE]; ptrSegPack pack; divisor = (int) (BufLen/SEG_DATA_SIZE); if( BufLen % SEG_DATA_SIZE != 0 ) *NPackets = divisor + 1; else *NPackets = divisor; pack = (ptrSegPack) malloc ((*NPackets)*(sizeof(SegPack))); offset = 0; for (i = 0; i < *NPackets; i++, offset += SEG_DATA_SIZE) { if( BufLen - offset > SEG_DATA_SIZE ) qtd = SEG_DATA_SIZE; else qtd = BufLen - offset; memcpy (aux, &Buffer[offset], qtd ); NewPacket (&pack[i], id, aux, qtd, LogicalClock, *NPackets, i); } return( pack ); } /****************************************************************************** Verifica se jaŽ existe uma entrada para a fonte do pacote Pack. Se sim, retorna TRUE e a posicao dessa entrada em indice. *******************************************************************************/ static struct SegmentationList *Compare( struct SegmentationPack Pack ) { int status; struct SegmentationList *indice; status = FALSE; indice = first; while( indice != NULL ) { if( Pack.LogicalClock == indice->LogicalClock ) { if( strcmp( Pack.id, indice->id ) == 0 ) { status = TRUE; break; } } indice = indice->next; } if( !status ) indice = NULL; return( indice ); } /************************************************************************************** Copia o novo fragmento para a sua posicao na lista. Retorna TRUE se todos os fragmentos de um pacote chegaram. **************************************************************************************/ static int FillFragment(struct SegmentationPack Pack, struct SegmentationList *index) { int status; status = FALSE; if( !index->Frag[ Pack.NumSeq ].DataSize ) { memcpy( index->Frag[ Pack.NumSeq ].data, Pack.data, Pack.DataSize ); index->Frag[ Pack.NumSeq ].DataSize = Pack.DataSize; index->ArrivedPcts++; if( index->ArrivedPcts == index->NumPackets ) status = TRUE; } return( status ); } /************************************************************************/ static void ConvertNetworkToHost (struct SegmentationPack *pack) { /* fprintf(stderr, "\n****Antes de desconverter %d\n", pack->NumSeq ); */ pack->DataSize = ntohl(pack->DataSize); pack->LogicalClock = ntohl(pack->LogicalClock); pack->NumPackets = ntohl(pack->NumPackets); pack->NumSeq = ntohl(pack->NumSeq); } /************************************************************************/ char *DeSegment (struct SegmentationPack Pack, int *NumBytes ) { struct SegmentationList *indice; int packetLength; char *buffer; int i; indice = NULL; buffer = NULL; *NumBytes = packetLength = 0; ConvertNetworkToHost(&Pack); /* fprintf(stderr, "Chegou pacote %d\n", Pack.NumSeq ); */ /* Check if this source was already inserted */ if( (indice = Compare( Pack )) == NULL ) indice = NewNodeList( Pack ); /* If this is the last fragment */ if( FillFragment( Pack, indice ) ) { packetLength = (indice->NumPackets - 1) * SEG_DATA_SIZE + indice->Frag[indice->NumPackets - 1].DataSize; buffer = (char *)malloc( packetLength ); for( i = 0; i < indice->NumPackets; i++ ) memcpy( &buffer[ i * SEG_DATA_SIZE ], (char *)indice->Frag[i].data, indice->Frag[i].DataSize ); *NumBytes = packetLength; DeleteNode( indice ); } return( buffer ); } /************************************************************************/ #endif /* _SEG_C */ tgif-QPL-4.2.5/list.e0000644000076400007640000000606411602233312014113 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/list.e,v 1.6 2011/05/16 16:21:58 william Exp $ */ #ifndef _TGIF_LIST_E_ #define _TGIF_LIST_E_ typedef int (CMPFN)ARGS_DECL((void*, void*)); /* a comparison function */ typedef struct tagCVListElem { void *obj; struct tagCVListElem *next; struct tagCVListElem *prev; } CVListElem; typedef struct tagCVList { int num_members; CVListElem anchor; int (*Length)(struct tagCVList *); int (*Empty)(struct tagCVList *); int (*Append)(struct tagCVList *, void*); int (*Prepend)(struct tagCVList *, void*); void (*Unlink)(struct tagCVList *, CVListElem*); void (*UnlinkAll)(struct tagCVList *); int (*InsertBefore)(struct tagCVList *, void*, CVListElem*); int (*InsertAfter)(struct tagCVList *, void*, CVListElem*); CVListElem *(*First)(struct tagCVList *); CVListElem *(*Last)(struct tagCVList *); CVListElem *(*Next)(struct tagCVList *, CVListElem *cur); CVListElem *(*Prev)(struct tagCVList *, CVListElem *cur); /* returns the CVListElem that contains obj */ CVListElem *(*Find)(struct tagCVList *, void*, CMPFN*); } CVList; #ifdef _INCLUDE_FROM_LIST_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_LIST_C_*/ extern int CompareForStringList ARGS_DECL((void *pv1, void *pv2)); extern int ListLength ARGS_DECL((CVList*)); extern int ListEmpty ARGS_DECL((CVList*)); extern int ListAppend ARGS_DECL((CVList*, void*)); extern int ListPrepend ARGS_DECL((CVList*, void*)); extern void ListUnlink ARGS_DECL((CVList*, CVListElem*)); extern void ListUnlinkAll ARGS_DECL((CVList*)); extern int ListInsertAfter ARGS_DECL((CVList*, void*, CVListElem*)); extern int ListInsertBefore ARGS_DECL((CVList*, void*, CVListElem*)); extern CVListElem *ListFirst ARGS_DECL((CVList*)); extern CVListElem *ListLast ARGS_DECL((CVList*)); extern CVListElem *ListNext ARGS_DECL((CVList*, CVListElem*)); extern CVListElem *ListPrev ARGS_DECL((CVList*, CVListElem*)); extern CVListElem *ListFind ARGS_DECL((CVList*, void*, CMPFN*)); extern void CVListCleanUp ARGS_DECL((CVList*)); extern int CVListInit ARGS_DECL((CVList*)); #ifdef _INCLUDE_FROM_LIST_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_LIST_C_*/ #endif /*_TGIF_LIST_E_*/ tgif-QPL-4.2.5/tdgtlist.c0000644000076400007640000012002611602233313014770 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtlist.c,v 1.8 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TDGTLIST_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "auxtext.e" #include "choose.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "font.e" #include "mainloop.e" #include "menu.e" #include "msg.e" #include "pattern.e" #include "raster.e" #include "rect.e" #include "scroll.e" #include "setup.e" #include "strtbl.e" #include "tdgtlist.e" #include "tidget.e" #include "util.e" static void RedrawTdgtList ARGS_DECL((TidgetInfo *pti)); static int TdgtListEventHandler ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo *handling_pti)); static int IsTdgtListEvent ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo **ppti_handler_tidget_return)); static void DestroyTdgtList ARGS_DECL((TidgetInfo *pti)); static void MapTdgtList ARGS_DECL((TidgetInfo *pti)); static void TdgtListMoveResize ARGS_DECL((TidgetInfo *pti, int x, int y, int w, int h)); static int TdgtListSendCmd ARGS_DECL((TidgetInfo *pti, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); static int gnListFontHeight=0; static int gnListFontWidth=0; static int gnListFontAsc=0; static int gnListFontDes=0; static XFontStruct *gnListFontPtr=NULL; /* --------------------- Utility Functions --------------------- */ static void FreeListItemInfo(pListItemInfo) ListItemInfo *pListItemInfo; { UtilFree(pListItemInfo->buf); free(pListItemInfo); } /* --------------------- RedrawTdgtList() --------------------- */ static void RedrawTdgtListItem(pTdgtList, index, pListItemInfo) TdgtList *pTdgtList; int index; ListItemInfo *pListItemInfo; { ListInfo *pListInfo=(&pTdgtList->list_info); int len=0, top=0, end=0, checkbox_cols=0, text_left=0, box_offset=0, box_w=0; int selected=(index==pListInfo->marked_index); int length=ListLength(&pListInfo->list); XGCValues values; if (!pTdgtList->can_select) selected = FALSE; top = gnListFontAsc+1; if (pListInfo->first_index+pListInfo->num_visible_lines > length) { end = length; } else { end = pListInfo->first_index + pListInfo->num_visible_lines; } if (pListInfo->p_check_array != NULL && pListInfo->p_check_array->num_cols > 0) { checkbox_cols = pListInfo->p_check_array->num_cols; text_left = checkbox_cols*ROW_HEIGHT; box_offset = 1; box_w = (ROW_HEIGHT-((box_offset+1)<<1)); } if (pTdgtList->multicolor) { if (selected) { } else { char *buf=NULL; XFontStruct *font_ptr=NULL; int font_asc=0; TidgetDrawMsgStringFunc *pf_draw_string_func=NULL; len = strlen(pListItemInfo->nick_name)+strlen(pListItemInfo->buf)+8; buf = (char*)malloc(len*sizeof(char)); if (buf == NULL) FailAllocMessage(); if (*pListItemInfo->nick_name == '\0') { sprintf(buf, "%s", pListItemInfo->buf); } else { sprintf(buf, "%s : %s", pListItemInfo->nick_name, pListItemInfo->buf); } TidgetGetFontInfoGivenStyle(pListItemInfo->font_style, &font_ptr, NULL, NULL, &font_asc, NULL); values.foreground = myBgPixel; values.background = myFgPixel; values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground | GCBackground | GCFunction | GCFillStyle, &values); XFillRectangle(mainDisplay, pTdgtList->dsp_win, revNameGC, 0, (index-pListInfo->first_index)*ROW_HEIGHT, ITEM_LEN*defaultFontWidth, ROW_HEIGHT); switch (pListItemInfo->font_style) { case STYLE_NR: if (msgFontPtr != NULL) { XSetFont(mainDisplay, gTidgetManager.gc, msgFontPtr->fid); } pf_draw_string_func = DrawMsgString; break; case STYLE_BR: if (boldMsgFontPtr != NULL) { XSetFont(mainDisplay, gTidgetManager.gc, boldMsgFontPtr->fid); } pf_draw_string_func = DrawBoldMsgString; break; case STYLE_NI: if (italicMsgFontPtr != NULL) { XSetFont(mainDisplay, gTidgetManager.gc, italicMsgFontPtr->fid); } pf_draw_string_func = DrawItalicMsgString; break; case STYLE_BI: if (boldItalicMsgFontPtr != NULL) { XSetFont(mainDisplay, gTidgetManager.gc, boldItalicMsgFontPtr->fid); } pf_draw_string_func = DrawBoldItalicMsgString; break; } values.foreground = ((pListItemInfo->color_index == INVALID) ? myFgPixel : colorPixels[pListItemInfo->color_index]); values.background = myBgPixel; values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground |GCBackground | GCFunction | GCFillStyle, &values); (pf_draw_string_func)(mainDisplay, pTdgtList->dsp_win, gTidgetManager.gc, text_left, (index-pListInfo->first_index)*ROW_HEIGHT+top, buf, strlen(buf)); TidgetManagerResetGC(); free(buf); } } else { if (selected) { values.foreground = myFgPixel; values.background = myBgPixel; } else { values.foreground = myBgPixel; values.background = myFgPixel; } values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground | GCBackground | GCFunction | GCFillStyle, &values); XFillRectangle(mainDisplay, pTdgtList->dsp_win, gTidgetManager.gc, 0, (index-pListInfo->first_index)*ROW_HEIGHT, ITEM_LEN*defaultFontWidth, ROW_HEIGHT); len = strlen(pListInfo->entries[index]); DrawMsgString(mainDisplay, pTdgtList->dsp_win, gTidgetManager.gc, text_left, (index-pListInfo->first_index)*ROW_HEIGHT+top, pListInfo->entries[index], len); TidgetManagerResetGC(); } if (checkbox_cols > 0) { int col=0, cur_x=0; if (selected) { values.foreground = myFgPixel; values.background = myBgPixel; } else { values.foreground = myBgPixel; values.background = myFgPixel; } values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground | GCBackground | GCFunction | GCFillStyle, &values); for (col=0; col < pListInfo->p_check_array->num_cols; col++) { DrawCheckbox(mainDisplay, pTdgtList->dsp_win, gTidgetManager.gc, cur_x+box_offset, (index-pListInfo->first_index)*ROW_HEIGHT+top-box_w, box_w, box_w, pListInfo->p_check_array->value[col][index]); cur_x += ROW_HEIGHT; } TidgetManagerResetGC(); } } static void RedrawTdgtListScrollWindow(pTdgtList) TdgtList *pTdgtList; { ListInfo *pListInfo=(&pTdgtList->list_info); double frac=(double)0, start_frac=(double)0; int block_h=0, block_start=0; int length=ListLength(&pListInfo->list); start_frac = (length > 0) ? (double)((double)(pListInfo->first_index) / (double)length) : ((double)0.0); /* starting pixel */ block_start = (int)(pTdgtList->scr_area_h * start_frac); if (length > pListInfo->num_visible_lines) { frac = (double)((double)pListInfo->num_visible_lines / (double)(length)); } else { frac = 1.0; } if (pListInfo->first_index+pListInfo->num_visible_lines >= length) { block_h = pTdgtList->scr_area_h - block_start; } else { block_h = (int)(pTdgtList->scr_area_h * frac); } TgDrawScrollBar(mainDisplay, pTdgtList->scr_win, VERT_SCROLLBAR, 0, 0, scrollBarW, pTdgtList->scr_area_h, start_frac, pListInfo->num_visible_lines, length); } static void RedrawTdgtListDspWindow(pTdgtList) TdgtList *pTdgtList; { ListInfo *pListInfo=(&pTdgtList->list_info); int length=ListLength(&pListInfo->list); int i=0, end=0; XGCValues values; if (pListInfo->first_index+pListInfo->num_visible_lines > length) { end = length; } else { end = pListInfo->first_index + pListInfo->num_visible_lines; } values.foreground = myBgPixel; values.background = myFgPixel; values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground | GCBackground | GCFunction | GCFillStyle, &values); XFillRectangle(mainDisplay, pTdgtList->dsp_win, gTidgetManager.gc, 0, 0, pTdgtList->dsp_win_info.w, pTdgtList->dsp_win_info.h); TidgetManagerResetGC(); if (pTdgtList->multicolor) { CVListElem *pElem=NULL; for (i=0, pElem=ListFirst(&pListInfo->list); i < pListInfo->first_index && pElem != NULL; i++, pElem=ListNext(&pListInfo->list, pElem)) { } for (i=pListInfo->first_index; i < end && pElem != NULL; i++, pElem=ListNext(&pListInfo->list, pElem)) { ListItemInfo *pListItemInfo=(ListItemInfo*)(pElem->obj); RedrawTdgtListItem(pTdgtList, i, pListItemInfo); } } else { for (i=pListInfo->first_index; i < end; i++) { RedrawTdgtListItem(pTdgtList, i, NULL); } } } static void RedrawTdgtListBaseWindow(pTdgtList) TdgtList *pTdgtList; { if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, pTdgtList->pti->tci.win_info.w, pTdgtList->pti->tci.win_info.h); TgDrawThreeDButton(mainDisplay, pTdgtList->pti->tci.win, gTidgetManager.gc, &bbox, TGBS_LOWRED, 2, FALSE); TidgetManagerResetGC(); } } static void RedrawTdgtList(pti) TidgetInfo *pti; { TdgtList *pTdgtList=(TdgtList*)(pti->tidget); XEvent ev; RedrawTdgtListScrollWindow(pTdgtList); RedrawTdgtListDspWindow(pTdgtList); RedrawTdgtListBaseWindow(pTdgtList); while (XCheckWindowEvent(mainDisplay, pTdgtList->pti->tci.win, ExposureMask, &ev)) ; } /* --------------------- TdgtListEventHandler() --------------------- */ static int TdgtListScrollItemCallback(pv_userdata) void *pv_userdata; /* returns TRUE to cancel scrolling */ { TdgtList *pTdgtList=((TdgtList*)pv_userdata); ListInfo *pListInfo=(&pTdgtList->list_info); int num_visible_lines=pListInfo->num_visible_lines; int length=ListLength(&pListInfo->list); if (pTdgtList->scr_dir == SCRL_UP) { if (pListInfo->first_index == 0) return FALSE; pListInfo->first_index--; } else { if (length <= num_visible_lines || pListInfo->first_index+num_visible_lines == length) { return FALSE; } pListInfo->first_index++; } RedrawTdgtList(pTdgtList->pti); XSync(mainDisplay, False); return FALSE; } static int TdgtListScrollPageCallback(pv_userdata) void *pv_userdata; /* returns TRUE to cancel scrolling */ { TdgtList *pTdgtList=((TdgtList*)pv_userdata); ListInfo *pListInfo=(&pTdgtList->list_info); int num_visible_lines=pListInfo->num_visible_lines; int length=ListLength(&pListInfo->list); if (pTdgtList->scr_dir == SCRL_UP) { if (pListInfo->first_index == 0) return FALSE; pListInfo->first_index -= num_visible_lines; if (pListInfo->first_index < 0) pListInfo->first_index = 0; } else { if (length <= num_visible_lines || pListInfo->first_index+num_visible_lines == length) { return FALSE; } pListInfo->first_index += num_visible_lines; if (pListInfo->first_index+num_visible_lines >= length) { pListInfo->first_index = length-num_visible_lines; } } RedrawTdgtList(pTdgtList->pti); XSync(mainDisplay, False); return FALSE; } static int DoTdgtListBtnScroll(pTdgtList, scroll_page, scr_dir, pbbox) TdgtList *pTdgtList; int scroll_page, scr_dir; struct BBRec *pbbox; /* returns TRUE if done scrolling */ { ListInfo *pListInfo=(&pTdgtList->list_info); int num_visible_lines=pListInfo->num_visible_lines; int length=ListLength(&pListInfo->list); ScrollBtnCallbackInfo sbci; pTdgtList->scr_dir = scr_dir; memset(&sbci, 0, sizeof(ScrollBtnCallbackInfo)); if (scroll_page) { sbci.ms = 200; sbci.pv_userdata = pTdgtList; sbci.pf_scroll_btn_callback = TdgtListScrollPageCallback; if (TgPressButtonLoop(mainDisplay, pTdgtList->scr_win, NULL, &sbci)) { if (scr_dir == SCRL_UP) { if (pListInfo->first_index == 0) return TRUE; pListInfo->first_index -= num_visible_lines; if (pListInfo->first_index < 0) pListInfo->first_index = 0; } else { if (length <= num_visible_lines || pListInfo->first_index+num_visible_lines == length) { return TRUE; } pListInfo->first_index += num_visible_lines; if (pListInfo->first_index+num_visible_lines >= length) { pListInfo->first_index = length-num_visible_lines; } } } } else { sbci.ms = 50; sbci.pv_userdata = pTdgtList; sbci.pf_scroll_btn_callback = TdgtListScrollItemCallback; if (TgPressButtonLoop(mainDisplay, pTdgtList->scr_win, pbbox, &sbci)) { if (scr_dir == SCRL_UP) { if (pListInfo->first_index == 0) return TRUE; pListInfo->first_index--; } else { if (length <= num_visible_lines || pListInfo->first_index+num_visible_lines == length) { return TRUE; } pListInfo->first_index++; } } } return FALSE; } static void DoDragInTdgtList(pTdgtList, button_ev, btn_y, btn_offset) TdgtList *pTdgtList; XButtonEvent *button_ev; int btn_y, btn_offset; { ListInfo *pListInfo=(&pTdgtList->list_info); int length=ListLength(&pListInfo->list); int num_visible_lines=pListInfo->num_visible_lines; double frac=(double)0, start_frac=(double)0; int block_h=0, block_start=0, done=FALSE; if (length <= num_visible_lines) return; frac = (double)((double)num_visible_lines / (double)(length)); block_h = (int)(pTdgtList->scr_area_h * frac); if (length > pListInfo->num_visible_lines) { frac = (double)((double)pListInfo->num_visible_lines / (double)(length)); block_h = (int)(((double)(pTdgtList->scr_area_h-(scrollBarW<<1))) * frac); } else { frac = 1.0; block_h = pTdgtList->scr_area_h-(scrollBarW<<1); } if (threeDLook) { block_start = button_ev->y+btn_offset;; start_frac = (double)((double)(block_start-scrollBarW) / (double)(pTdgtList->scr_area_h-(scrollBarW<<1))); if (block_start+block_h >= pTdgtList->scr_area_h-scrollBarW) { pListInfo->first_index = length - num_visible_lines; } else { pListInfo->first_index = (int)(length * start_frac); } } else { block_start = button_ev->y; start_frac = (double)((double)(block_start) / (double)(pTdgtList->scr_area_h)); if (block_start+block_h >= pTdgtList->scr_area_h) { pListInfo->first_index = length - num_visible_lines; } else { pListInfo->first_index = (int)(length * start_frac); } } RedrawTdgtList(pTdgtList->pti); XGrabPointer(mainDisplay, pTdgtList->scr_win, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); while (!done) { XEvent ev; XNextEvent(mainDisplay, &ev); if (ev.type == Expose || ev.type == VisibilityNotify) { ExposeEventHandler(&ev, TRUE); } else if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); if (debugNoPointerGrab) XSync(mainDisplay, False); done = TRUE; } else if (ev.type == MotionNotify) { int new_name_first=0, y=ev.xmotion.y; if (threeDLook) { y += btn_offset; start_frac = (double)(((double)(y-scrollBarW)) / ((double)(pTdgtList->scr_area_h-(scrollBarW<<1)))); if (y <= scrollBarW) { new_name_first = 0; } else if (y+block_h >= pTdgtList->scr_area_h-scrollBarW) { new_name_first = length - num_visible_lines; } else { new_name_first = (int)(length * start_frac); } } else { start_frac = (double)(((double)y) / ((double)pTdgtList->scr_area_h)); if (y <= 0) { new_name_first = 0; } else if (y+block_h >= pTdgtList->scr_area_h) { new_name_first = length - num_visible_lines; } else { new_name_first = (int)(length * start_frac); } } if (pListInfo->first_index != new_name_first) { pListInfo->first_index = new_name_first; RedrawTdgtList(pTdgtList->pti); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } } static void TdgtListScrollHandler(pTdgtList, button_ev) TdgtList *pTdgtList; XButtonEvent *button_ev; { ListInfo *pListInfo=(&pTdgtList->list_info); int length=ListLength(&pListInfo->list); int do_drag=FALSE, btn_offset=0; if (!threeDLook && button_ev->button == Button3 && button_ev->type == ButtonPress) { if (DoTdgtListBtnScroll(pTdgtList, ((button_ev->state & (ShiftMask|ControlMask)) != 0), SCRL_UP, NULL)) { return; } } else if (!threeDLook && button_ev->button == Button1 && button_ev->type == ButtonPress) { if (DoTdgtListBtnScroll(pTdgtList, ((button_ev->state & (ShiftMask|ControlMask)) != 0), SCRL_DN, NULL)) { return; } } else if (button_ev->button == Button1 && button_ev->type == ButtonPress) { if (button_ev->y < scrollBarW || button_ev->y >= pTdgtList->scr_area_h-scrollBarW) { int which=INVALID; struct BBRec bbox; if (button_ev->y < scrollBarW) { which = SCRL_UP; SetBBRec(&bbox, 0, 0, scrollBarW, scrollBarW); } else { which = SCRL_DN; SetBBRec(&bbox, 0, pTdgtList->scr_area_h-scrollBarW, scrollBarW, pTdgtList->scr_area_h); } if (DoTdgtListBtnScroll(pTdgtList, FALSE, which, &bbox)) { return; } } else { double start_frac=(double)0; int hit=0; start_frac = (length > 0) ? (double)((double)(pListInfo->first_index) / (double)length) : ((double)0.0); hit = TgGetScrollHit(button_ev->x, button_ev->y, VERT_SCROLLBAR, scrollBarW, pTdgtList->scr_area_h, start_frac, pListInfo->num_visible_lines, length, &btn_offset); if (hit == 0) { do_drag = TRUE; } else { if (DoTdgtListBtnScroll(pTdgtList, TRUE, (hit < 0 ? SCRL_UP : SCRL_DN), NULL)) { return; } } } } else if (!threeDLook && button_ev->button == Button2 && button_ev->type == ButtonPress) { do_drag = TRUE; } if (do_drag) { DoDragInTdgtList(pTdgtList, button_ev, button_ev->y, btn_offset); } else { RedrawTdgtList(pTdgtList->pti); } } static int TdgtListDspHandler(pTdgtList, button_ev) TdgtList *pTdgtList; XButtonEvent *button_ev; { if (enableMouseWheel && (button_ev->button == Button4 || button_ev->button == Button5)) { int which=INVALID; struct BBRec bbox; if (button_ev->button == Button4) { which = SCRL_UP; SetBBRec(&bbox, 0, 0, scrollBarW, scrollBarW); } else if (button_ev->button == Button5) { which = SCRL_DN; SetBBRec(&bbox, 0, pTdgtList->scr_area_h-scrollBarW, scrollBarW, pTdgtList->scr_area_h); } if (which != INVALID) { DoTdgtListBtnScroll(pTdgtList, FALSE, which, &bbox); RedrawTdgtList(pTdgtList->pti); } return INVALID; } else if (button_ev->button != Button1) { return INVALID; } return INVALID; } static int TdgtListControlChar(pTdgtList, key_ev, key_sym) TdgtList *pTdgtList; XKeyEvent *key_ev; KeySym key_sym; { ListInfo *pListInfo=(&pTdgtList->list_info); int length=ListLength(&pListInfo->list); int num_visible_lines=pListInfo->num_visible_lines; int i=0; if (key_ev->state & ControlMask) { switch (key_sym) { case XK_Left: return (BAD); case XK_KP_Left: return (BAD); case XK_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_KP_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_Right: return (BAD); case XK_KP_Right: return (BAD); case XK_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_KP_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_KP_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_KP_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; } } else { switch (key_sym) { case XK_Left: return BAD; case XK_KP_Left: return BAD; case XK_Up: key_sym = ((unsigned long)'k')&0xff; break; case XK_KP_Up: key_sym = ((unsigned long)'k')&0xff; break; case XK_Right: return BAD; case XK_KP_Right: return BAD; case XK_Down: key_sym = ((unsigned long)'j')&0xff; break; case XK_KP_Down: key_sym = ((unsigned long)'j')&0xff; break; case XK_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_KP_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_KP_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; } } switch (key_sym&0xff) { case 'w': /* erase */ case 'y': return INVALID; case 'n': /* down one */ case 'j': if (pTdgtList->can_select) { /* * i = (pni->marked_index < length-1) ? * pni->marked_index+1 : length-1; */ } else { if (length > num_visible_lines) { if (pListInfo->first_index+num_visible_lines < length) { pListInfo->first_index++; } } } break; case 'p': /* up one */ case 'k': if (pTdgtList->can_select) { /* * i = (pni->marked_index>0) ? pni->marked_index-1 : 0; */ } else { if (length > num_visible_lines) { if (pListInfo->first_index > 0) { pListInfo->first_index--; } } } break; case 'd': /* down one page */ case 'f': if (pTdgtList->can_select) { /* * if (pni->marked_index==INVALID) { * i = (length <= num_visible_lines) ? length-1 : * num_visible_lines; * } else if (pni->marked_index < length-num_visible_lines) { * i = pni->marked_index+num_visible_lines; * } else { * i = length-1; * } */ } else { if (length > num_visible_lines) { if (pListInfo->first_index+num_visible_lines < length) { pListInfo->first_index += num_visible_lines; if (pListInfo->first_index + num_visible_lines > length) { pListInfo->first_index = length - num_visible_lines; } } } } break; case 'u': /* up one page */ case 'b': if (pTdgtList->can_select) { /* * i = (pni->marked_index > (num_visible_lines-1)) ? * pni->marked_index-num_visible_lines : 0; */ } else { pListInfo->first_index -= num_visible_lines; if (pListInfo->first_index < 0) pListInfo->first_index = 0; } break; default: return BAD; } return i; } static void SpecialKeyInTdgtList(pTdgtList, key_ev, key_sym, pn_changing, pn_selected_btn_index) TdgtList *pTdgtList; XKeyEvent *key_ev; KeySym key_sym; int *pn_changing, *pn_selected_btn_index; { ListInfo *pListInfo=(&pTdgtList->list_info); int saved_first=pListInfo->first_index; int saved_marked=pListInfo->marked_index; int rc=TdgtListControlChar(pTdgtList, key_ev, key_sym); if (rc == BAD || rc == INVALID) return; if (saved_first != pListInfo->first_index || saved_marked != pListInfo->marked_index) { RedrawTdgtList(pTdgtList->pti); } } static XComposeStatus c_stat; static int KeyPressInTdgtList(pTdgtList, key_ev, pn_changing, pn_selected_btn_index) TdgtList *pTdgtList; XKeyEvent *key_ev; int *pn_changing, *pn_selected_btn_index; { ListInfo *pListInfo=(&pTdgtList->list_info); int length=ListLength(&pListInfo->list); char buf[80]; KeySym key_sym; int has_ch=FALSE; has_ch = XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); TranslateKeys(buf, &key_sym); if ((key_ev->state & ControlMask) && key_sym == XK_j) { SpecialKeyInTdgtList(pTdgtList, key_ev, key_sym, pn_changing, pn_selected_btn_index); } else if (CharIsCRorLF(key_ev, buf, key_sym, &has_ch)) { if (pTdgtList->can_select) { /* * if (pni->def_btn_id != INVALID) { * *pn_changing = FALSE; * *pn_selected_btn_index = GetBtnIndexFromBtnId(pni->def_btn_id); * } */ } else { return FALSE; } } else if (CharIsESC(key_ev, buf, key_sym, &has_ch)) { if (pTdgtList->can_select) { /* * *pn_changing = FALSE; * *pn_selected_btn_index = GetBtnIndexFromBtnId(BUTTON_CANCEL); */ } } else if (CharIsBSorDEL(key_ev, buf, key_sym, &has_ch, FALSE)) { if (pTdgtList->can_select) { /* * if (pni->edit_style == NAMES_SELECT_FILE && * (pni->faking_dot_dot || pni->pop_from_root)) { * *pn_changing = FALSE; * *pn_selected_btn_index = INVALID; * } else { * BackSpaceInNames(pn_changing, pn_selected_btn_index); * } */ } } else if (CharIsTAB(key_ev, buf, key_sym, &has_ch)) { if (pTdgtList->can_select) { /* should tab out of focus?! */ } } else if (length != 0 && ((key_sym>'\040' && key_sym<='\177' && (key_ev->state & ControlMask)) || key_sym==XK_Up || key_sym==XK_Down || key_sym==XK_KP_Up || key_sym==XK_KP_Down || key_sym==XK_Page_Up || key_sym==XK_KP_Page_Up || key_sym==XK_Page_Down || key_sym==XK_KP_Page_Down)) { SpecialKeyInTdgtList(pTdgtList, key_ev, key_sym, pn_changing, pn_selected_btn_index); } else if (key_sym>='\040' && key_sym<='\177' && length != 0) { if (pTdgtList->can_select) { /* * CharInNames(buf, pn_changing, pn_selected_btn_index); */ } return FALSE; } return TRUE; } static void ButtonPressInTdgtList(pTdgtList, button_ev, pn_changing, pn_selected_btn_index) TdgtList *pTdgtList; XButtonEvent *button_ev; int *pn_changing, *pn_selected_btn_index; { if (button_ev->window == pTdgtList->scr_win) { TdgtListScrollHandler(pTdgtList, button_ev); } else if (button_ev->window == pTdgtList->dsp_win) { int double_clicked=(TdgtListDspHandler(pTdgtList, button_ev)!=INVALID); if (double_clicked) { /* do something here */ } if (pTdgtList->can_select) { /* do something here */ } } } static int TdgtListEventHandler(pti, input, handling_pti) TidgetInfo *pti, *handling_pti; XEvent *input; { TdgtList *pTdgtList=(TdgtList*)(pti->tidget); if (pti != handling_pti) return FALSE; if (input->type == Expose) { RedrawTdgtList(pTdgtList->pti); } else if (input->type == KeyPress) { if (pTdgtList->can_select) { /* KeyPressInTdgtList(pTdgtList, &changing, &selected_btn_index); */ } else { return KeyPressInTdgtList(pTdgtList, &input->xkey, NULL, NULL); } } else if (input->type == ButtonPress) { if (pTdgtList->can_select) { /* ButtonPressInTdgtList(pTdgtList, &changing, &selected_btn_index); */ } else { ButtonPressInTdgtList(pTdgtList, &input->xbutton, NULL, NULL); } } return TRUE; } /* --------------------- IsTdgtListEvent() --------------------- */ static int IsTdgtListEvent(pti, input, ppti_handler_tidget_return) TidgetInfo *pti, **ppti_handler_tidget_return; XEvent *input; { TdgtList *pTdgtList=(TdgtList*)(pti->tidget); if (input->xany.window == pTdgtList->pti->tci.win || input->xany.window == pTdgtList->dsp_win || input->xany.window == pTdgtList->scr_win) { *ppti_handler_tidget_return = pti; return TRUE; } return FALSE; } /* --------------------- DestroyTdgtList() --------------------- */ static void DestroyTdgtList(pti) TidgetInfo *pti; { TdgtList *pTdgtList=(TdgtList*)(pti->tidget); TdgtListReset(pTdgtList); free(pTdgtList); } /* --------------------- MapTdgtList() --------------------- */ static void MapTdgtList(pti) TidgetInfo *pti; { TdgtList *pTdgtList=(TdgtList*)(pti->tidget); #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, pTdgtList->pti->tci.win); XSelectInput(mainDisplay, pTdgtList->pti->tci.win, ExposureMask); XMapWindow(mainDisplay, pTdgtList->dsp_win); XSelectInput(mainDisplay, pTdgtList->dsp_win, KeyPressMask | ButtonPressMask | ExposureMask); XMapWindow(mainDisplay, pTdgtList->scr_win); XSelectInput(mainDisplay, pTdgtList->scr_win, KeyPressMask | ButtonPressMask | ExposureMask); #else XSelectInput(mainDisplay, pTdgtList->pti->tci.win, ExposureMask); XMapWindow(mainDisplay, pTdgtList->pti->tci.win); XSelectInput(mainDisplay, pTdgtList->dsp_win, KeyPressMask | ButtonPressMask | ExposureMask); XMapWindow(mainDisplay, pTdgtList->dsp_win); XSelectInput(mainDisplay, pTdgtList->scr_win, KeyPressMask | ButtonPressMask | ExposureMask); XMapWindow(mainDisplay, pTdgtList->scr_win); #endif } /* --------------------- TdgtListMoveResize() --------------------- */ static void TdgtListMoveResize(pti, x, y, w, h) TidgetInfo *pti; int x, y, w, h; { TdgtList *pTdgtList=(TdgtList*)(pti->tidget); pTdgtList->pti->tci.win_info.x = x; pTdgtList->pti->tci.win_info.y = y; pTdgtList->pti->tci.win_info.w = w; pTdgtList->pti->tci.win_info.h = h; pTdgtList->pti->tci.content_w = w-(windowPadding<<1)-pTdgtList->pti->tci.h_pad; pTdgtList->pti->tci.content_h = h-(windowPadding<<1)-pTdgtList->pti->tci.v_pad; XMoveResizeWindow(mainDisplay, pTdgtList->pti->tci.win, x, y, w, h); pTdgtList->dsp_win_info.x = windowPadding; pTdgtList->dsp_win_info.y = windowPadding; pTdgtList->dsp_win_info.w = w-(windowPadding<<1)-scrollBarW; pTdgtList->dsp_win_info.h = h-(windowPadding<<1); XMoveResizeWindow(mainDisplay, pTdgtList->dsp_win, pTdgtList->dsp_win_info.x, pTdgtList->dsp_win_info.y, pTdgtList->dsp_win_info.w, pTdgtList->dsp_win_info.h); pTdgtList->scr_win_info.x = w-windowPadding-scrollBarW; pTdgtList->scr_win_info.y = windowPadding; pTdgtList->scr_win_info.w = scrollBarW; pTdgtList->scr_win_info.h = h-(windowPadding<<1); XMoveResizeWindow(mainDisplay, pTdgtList->scr_win, pTdgtList->scr_win_info.x, pTdgtList->scr_win_info.y, pTdgtList->scr_win_info.w, pTdgtList->scr_win_info.h); } /* --------------------- TdgtListSendCmd() --------------------- */ static int TdgtListSendCmd(pti, cmd_type, cmd_arg, pv_cmd_userdata) TidgetInfo *pti; int cmd_type, cmd_arg; void *pv_cmd_userdata; { TdgtList *pTdgtList=(TdgtList*)(pti->tidget); if (pTdgtList != NULL) { } return FALSE; } /* --------------------- TdgtListReset() --------------------- */ void TdgtListReset(pTdgtList) TdgtList *pTdgtList; { ListInfo *pListInfo=(&pTdgtList->list_info); CVListElem *pElem=NULL; TdgtListCleanUpEntries(pTdgtList); for (pElem=ListFirst(&pListInfo->list); pElem != NULL; pElem=ListNext(&pListInfo->list, pElem)) { ListItemInfo *pListItemInfo=(ListItemInfo*)(pElem->obj); FreeListItemInfo(pListItemInfo); } ListUnlinkAll(&pListInfo->list); } /* --------------------- CreateTdgtList() --------------------- */ static void TdgtListCalcHeight(num_visible_lines, pn_content_h) int num_visible_lines, *pn_content_h; { int h=(num_visible_lines*ROW_HEIGHT); if (pn_content_h != NULL) *pn_content_h = h; } TdgtList *CreateTdgtList(parent_win, parent_tidgetinfo, ctl_id, x, y, w, h_pad, v_pad, num_visible_lines, can_select, multicolor, auto_scroll_on_insert) Window parent_win; TidgetInfo *parent_tidgetinfo; int ctl_id, x, y, w, h_pad, v_pad, num_visible_lines, auto_scroll_on_insert; { int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel), h=0, content_h=0; TdgtList *pTdgtList=NULL; TdgtListCalcHeight(num_visible_lines, &content_h); h = content_h + (windowPadding<<1) + (v_pad<<1); pTdgtList = (TdgtList*)malloc(sizeof(TdgtList)); if (pTdgtList == NULL) FailAllocMessage(); memset(pTdgtList, 0, sizeof(TdgtList)); pTdgtList->pti = NewTidgetInfo(parent_tidgetinfo, TIDGET_TYPE_LIST, pTdgtList, ctl_id, NULL); if ((pTdgtList->pti->tci.win=XCreateSimpleWindow(mainDisplay, parent_win, x, y, w, h, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("CreateTdgtList()", NULL, TRUE); } XSelectInput(mainDisplay, pTdgtList->pti->tci.win, ExposureMask); SetTidgetInfoBasic(pTdgtList->pti, TIDGET_TYPE_LIST, pTdgtList, parent_win, x, y, w, h, h_pad, v_pad, TGBS_LOWRED, NULL); TidgetSetCallbacks(pTdgtList->pti, RedrawTdgtList, TdgtListEventHandler, IsTdgtListEvent, DestroyTdgtList, MapTdgtList, TdgtListMoveResize, TdgtListSendCmd); CVListInit(&pTdgtList->list_info.list); /* Note: scrollBarW accounts for windowPadding */ if ((pTdgtList->dsp_win=XCreateSimpleWindow(mainDisplay, pTdgtList->pti->tci.win, windowPadding, windowPadding, w-(windowPadding<<1)-scrollBarW, h-(windowPadding<<1), brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("CreateTdgtList()", NULL, TRUE); } XSelectInput(mainDisplay, pTdgtList->dsp_win, KeyPressMask | ButtonPressMask | ExposureMask); pTdgtList->dsp_win_info.x = windowPadding; pTdgtList->dsp_win_info.y = windowPadding; pTdgtList->dsp_win_info.w = w-(windowPadding<<1)-scrollBarW; pTdgtList->dsp_win_info.h = h-(windowPadding<<1); if ((pTdgtList->scr_win=XCreateSimpleWindow(mainDisplay, pTdgtList->pti->tci.win, w-windowPadding-scrollBarW, windowPadding, scrollBarW, h-(windowPadding<<1), brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("CreateTdgtList()", NULL, TRUE); } XSelectInput(mainDisplay, pTdgtList->scr_win, KeyPressMask | ButtonPressMask | ExposureMask); pTdgtList->scr_win_info.x = w-windowPadding-scrollBarW; pTdgtList->scr_win_info.y = windowPadding; pTdgtList->scr_win_info.w = scrollBarW; pTdgtList->scr_win_info.h = h-(windowPadding<<1); pTdgtList->list_info.num_visible_lines = num_visible_lines; pTdgtList->can_select = can_select; pTdgtList->multicolor = (colorDisplay ? multicolor : FALSE); pTdgtList->auto_scroll_on_insert = auto_scroll_on_insert; pTdgtList->scr_area_h = num_visible_lines*ROW_HEIGHT; return pTdgtList; } /* --------------------- TdgtListCleanUpEntries() --------------------- */ int TdgtListCleanUpEntries(pTdgtList) TdgtList *pTdgtList; { ListInfo *pListInfo=(&pTdgtList->list_info); int length=ListLength(&pListInfo->list); if (pListInfo->entries != NULL) { int i=0; for (i=0; i < length; i++) { UtilFree(pListInfo->entries[i]); } free(pListInfo->entries); pListInfo->entries = NULL; } return TRUE; } /* --------------------- TdgtListUpdateEntries() --------------------- */ int TdgtListUpdateEntries(pTdgtList) TdgtList *pTdgtList; { ListInfo *pListInfo=(&pTdgtList->list_info); CVListElem *pElem=NULL; int length=ListLength(&pListInfo->list), index=0; if (pListInfo->entries != NULL) { TdgtListCleanUpEntries(pTdgtList); } pListInfo->entries = (char**)malloc(length*sizeof(char*)); if (pListInfo->entries == NULL) FailAllocMessage(); memset(pListInfo->entries, 0, length*sizeof(char*)); for (pElem=ListFirst(&pListInfo->list); pElem != NULL; pElem=ListNext(&pListInfo->list, pElem), index++) { ListItemInfo *pListItemInfo=(ListItemInfo*)(pElem->obj); pListInfo->entries[index] = UtilStrDup(pListItemInfo->buf); if (pListInfo->entries[index] == NULL) FailAllocMessage(); } return TRUE; } /* --------------------- TdgtListScrollToBottom() --------------------- */ int TdgtListScrollToBottom(pTdgtList) TdgtList *pTdgtList; { ListInfo *pListInfo=(&pTdgtList->list_info); int length=ListLength(&pListInfo->list); if (pListInfo->num_visible_lines < length) { pListInfo->first_index = length - pListInfo->num_visible_lines; } else { pListInfo->first_index = 0; } return TRUE; } /* --------------------- TdgtListInsertString() --------------------- */ int TdgtListInsertString(pTdgtList, buf) TdgtList *pTdgtList; char *buf; { ListInfo *pListInfo=(&pTdgtList->list_info); ListItemInfo *pListItemInfo=(ListItemInfo*)malloc(sizeof(ListItemInfo)); if (pListItemInfo == NULL) FailAllocMessage(); memset(pListItemInfo, 0, sizeof(ListItemInfo)); *pListItemInfo->nick_name = '\0'; pListItemInfo->color_index = colorIndex; pListItemInfo->font_style = STYLE_NR; pListItemInfo->buf = UtilStrDup(buf); if (pListItemInfo->buf == NULL) FailAllocMessage(); TdgtListCleanUpEntries(pTdgtList); ListAppend(&pListInfo->list, pListItemInfo); if (pTdgtList->auto_scroll_on_insert) { TdgtListScrollToBottom(pTdgtList); } TdgtListUpdateEntries(pTdgtList); RedrawTdgtList(pTdgtList->pti); return TRUE; } int TdgtListInsertListItemInfo(pTdgtList, pListItemInfo) TdgtList *pTdgtList; ListItemInfo *pListItemInfo; { ListInfo *pListInfo=(&pTdgtList->list_info); TdgtListCleanUpEntries(pTdgtList); ListAppend(&pListInfo->list, pListItemInfo); if (pTdgtList->auto_scroll_on_insert) { TdgtListScrollToBottom(pTdgtList); } TdgtListUpdateEntries(pTdgtList); RedrawTdgtList(pTdgtList->pti); return TRUE; } int TdgtListSetAutoScrollOnInsert(pTdgtList, auto_scroll_on_insert) TdgtList *pTdgtList; int auto_scroll_on_insert; { pTdgtList->auto_scroll_on_insert = auto_scroll_on_insert; return TRUE; } int TdgtListGetAutoScrollOnInsert(pTdgtList) TdgtList *pTdgtList; { return pTdgtList->auto_scroll_on_insert; } /* --------------------- Init & Clean Up --------------------- */ int InitTdgtList() { if (msgFontSet == NULL && msgFontPtr == NULL) { gnListFontHeight = defaultFontHeight; gnListFontWidth = defaultFontWidth; gnListFontAsc = defaultFontAsc; gnListFontDes = defaultFontDes; gnListFontPtr = defaultFontPtr; } else { gnListFontHeight = msgFontHeight; gnListFontWidth = msgFontWidth; gnListFontAsc = msgFontAsc; gnListFontDes = msgFontDes; gnListFontPtr = msgFontPtr; } return TRUE; } void CleanUpTdgtList() { gnListFontHeight = gnListFontWidth = gnListFontAsc = gnListFontDes = 0; gnListFontPtr = NULL; } tgif-QPL-4.2.5/util.c0000644000076400007640000003702211602233313014112 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/util.c,v 1.13 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_UTIL_C_ #include "tgifdefs.h" #include "dialog.e" #include "file.e" #include "remote.e" #include "strtbl.e" #include "util.e" void UtilFree(pszStr) char *pszStr; { if (pszStr != NULL) free(pszStr); } char *UtilFreeStringArray(ppsz, nItems) char **ppsz; int nItems; /* ppsz is also freed */ { if (ppsz != NULL) { int i; for (i=0; i < nItems; i++) UtilFree(ppsz[i]); free(ppsz); } return NULL; } char *UtilStrDup(pszStr) char *pszStr; /* must eventually free the returned string with free() */ { int len=(pszStr == NULL ? 0 : strlen(pszStr)); char *c_ptr=(char*)malloc((len+1)*sizeof(char)); if (c_ptr == NULL) return NULL; strcpy(c_ptr, (pszStr == NULL ? "" : pszStr)); return c_ptr; } int UtilStrCpyN(pszDest, nMaxDestSz, pszSrc) char *pszDest, *pszSrc; int nMaxDestSz; { int len=0; if (pszDest != NULL && nMaxDestSz > 0) *pszDest = '\0'; if (pszDest == NULL || pszSrc == NULL || nMaxDestSz <= 0) return 0; len = strlen(pszSrc); if (len > nMaxDestSz-1) len = nMaxDestSz-1; strncpy(pszDest, pszSrc, len); pszDest[len] = '\0'; return len; } int UtilStrCpy(pszDest, pszSrc) char *pszDest, *pszSrc; /* safe copy byte by byte from pszSrc to pszDest */ { int len=0; if (pszDest == NULL || pszSrc == NULL) return 0; while (((*pszDest++)=(*pszSrc++)) != '\0') { len++; } return len; } void UtilLeftTrim(pszStr) char *pszStr; /* pszStr must be terminated by '\0' */ { register char *c_ptr; for (c_ptr=pszStr; *c_ptr != '\0'; c_ptr++) { char ch=(*c_ptr); if (!(ch == ' ' || ch == '\t' || ch == '\n' || ch == '\r')) { break; } } if (*c_ptr != '\0' && c_ptr != pszStr) { while ((*pszStr++ = *c_ptr++) != '\0') ; } } void UtilRightTrim(pszStr) char *pszStr; /* pszStr must be terminated by '\0' */ { register int len; for (len=strlen(pszStr)-1; len >= 0; len--) { char ch=pszStr[len]; if (ch == ' ' || ch == '\t' || ch == '\n' || ch == '\r') { pszStr[len] = '\0'; } else { break; } } } void UtilTrimBlanks(pszStr) char *pszStr; /* pszStr must be terminated by '\0' */ { register int len; register char *c_ptr; for (len=strlen(pszStr)-1; len >= 0; len--) { char ch=pszStr[len]; if (ch == ' ' || ch == '\t' || ch == '\n' || ch == '\r') { pszStr[len] = '\0'; } else { break; } } for (c_ptr=pszStr; *c_ptr != '\0'; c_ptr++) { char ch=(*c_ptr); if (!(ch == ' ' || ch == '\t' || ch == '\n' || ch == '\r')) { break; } } if (*c_ptr != '\0' && c_ptr != pszStr) { while ((*pszStr++ = *c_ptr++) != '\0') ; } } void UtilStrUpper(psz) char *psz; { for ( ; *psz != '\0'; psz++) { if (*psz >= 'a' && *psz <= 'z') { *psz = *psz-'a'+'A'; } } } void UtilStrLower(psz) char *psz; { for ( ; *psz != '\0'; psz++) { if (*psz >= 'A' && *psz <= 'Z') { *psz = *psz-'A'+'a'; } } } int UtilStrNCaseCmp(pszStr1, pszStr2, nCount) char *pszStr1, *pszStr2; int nCount; { char *c_ptr1, *c_ptr2, ch1, ch2; int i=0; for (c_ptr1=pszStr1, c_ptr2=pszStr2; i < nCount && (*c_ptr1 != '\0' || *c_ptr2 != '\0'); c_ptr1++, c_ptr2++, i++) { ch1 = *c_ptr1; ch2 = *c_ptr2; if (ch1 >= 'A' && ch1 <= 'Z') ch1 = ch1-'A'+'a'; if (ch2 >= 'A' && ch2 <= 'Z') ch2 = ch2-'A'+'a'; if (ch1 != ch2) break; } if (i == nCount) return 0; return ((*c_ptr1)-(*c_ptr2)); } int UtilStrICmp(pszStr1, pszStr2) char *pszStr1, *pszStr2; { int diff=FALSE; char *c_ptr1, *c_ptr2, ch1, ch2; for (c_ptr1=pszStr1, c_ptr2=pszStr2; *c_ptr1 != '\0' || *c_ptr2 != '\0'; c_ptr1++, c_ptr2++) { ch1 = *c_ptr1; ch2 = *c_ptr2; if (ch1 >= 'A' && ch1 <= 'Z') ch1 = ch1-'A'+'a'; if (ch2 >= 'A' && ch2 <= 'Z') ch2 = ch2-'A'+'a'; if (ch1 != ch2) { diff = TRUE; break; } } return (diff ? ((*c_ptr1)-(*c_ptr2)) : 0); } char *UtilStrRChr(pszStr, int_ch) char *pszStr; int int_ch; { int len=strlen(pszStr); char ch=(char)int_ch; for (len--; len >= 0; len--) { if (pszStr[len] == ch) { return (&pszStr[len]); } } return NULL; } char *UtilStrTok(pszStr, pszDelim, ppszState) char *pszStr, *pszDelim, **ppszState; { char *psz=NULL, *psz_start=NULL; if (pszStr != NULL) { *ppszState = NULL; psz_start = pszStr; while (*psz_start != '\0' && strchr(pszDelim, *psz_start) != NULL) { psz_start++; } if (*psz_start == '\0') return NULL; for (psz=psz_start; *psz != '\0'; psz++) { if (strchr(pszDelim, *psz) != NULL) { *psz = '\0'; *ppszState = psz; return psz_start; } } if (*psz == '\0' && psz_start != psz) { return psz_start; } } else { if (*ppszState == NULL) return NULL; psz_start = &(*ppszState)[1]; *ppszState = NULL; while (*psz_start != '\0' && strchr(pszDelim, *psz_start) != NULL) { psz_start++; } if (*psz_start == '\0') return NULL; for (psz=psz_start; *psz != '\0'; psz++) { if (strchr(pszDelim, *psz) != NULL) { *psz = '\0'; *ppszState = psz; return psz_start; } } if (*psz == '\0' && psz_start != psz) { return psz_start; } } return NULL; } #ifdef NO_STRSTR char *strstr (pszStr, pszSubStr) char *pszStr, *pszSubStr; { int len; for (len=strlen(pszSubStr); *pszStr != '\0'; pszStr++) { if (strncmp(pszStr, pszSubStr, len) == 0) { return(pszStr); } } return NULL; } #endif /* NO_STRSTR */ int UtilShrinkName(pszFile) char *pszFile; { char *c_ptr=NULL, *real_ptr=NULL, *real_name=NULL; if (pszFile[0] == '.' && pszFile[1] == DIR_SEP) return TRUE; if (*pszFile != DIR_SEP) return FALSE; real_name = UtilStrDup(pszFile); if (real_name == NULL) return FALSE; real_ptr = real_name; c_ptr = &real_name[1]; while (*c_ptr != '\0') { if (*c_ptr == '.') { if (c_ptr[1] == '.') { if (c_ptr[2] == DIR_SEP) { /* "../" */ if (real_ptr != real_name) { while (*(--real_ptr) != DIR_SEP) ; } c_ptr = (&c_ptr[3]); } else { while (*c_ptr != '\0' && *c_ptr != DIR_SEP) { *(++real_ptr) = *c_ptr++; } if (*c_ptr == DIR_SEP) { c_ptr++; *(++real_ptr) = DIR_SEP; } } } else if (c_ptr[1] == DIR_SEP) { /* "./" */ c_ptr = (&c_ptr[2]); } else { while (*c_ptr != '\0' && *c_ptr != DIR_SEP) { *(++real_ptr) = *c_ptr++; } if (*c_ptr == DIR_SEP) { c_ptr++; *(++real_ptr) = DIR_SEP; } } #ifndef apollo } else if (*c_ptr == DIR_SEP) { c_ptr++; #endif } else { while (*c_ptr != '\0' && *c_ptr != DIR_SEP) { *(++real_ptr) = *c_ptr++; } if (*c_ptr == DIR_SEP) { c_ptr++; *(++real_ptr) = DIR_SEP; } } } *(++real_ptr) = '\0'; strcpy(pszFile, real_name); free(real_name); return TRUE; } void UtilRemoveQuotes(pszStr) char *pszStr; { int nStart=0, nEnd=strlen(pszStr)-1, still_going=TRUE; while (still_going) { if (nStart >= nEnd) break; switch (pszStr[nStart]) { case '"': if (pszStr[nEnd] != '"') still_going = FALSE; break; case '\'': if (pszStr[nEnd] != '\'') still_going = FALSE; break; default: still_going = FALSE; break; } if (still_going) { nStart++; pszStr[nEnd--] = '\0'; } } if (nStart != 0) { char *c_ptr=&pszStr[nStart]; while (*pszStr != '\0') *pszStr++ = (*c_ptr++); } } static char gszMsg[512]; char *UtilGetALine(pFile) FILE *pFile; { unsigned long len; if (fgets(gszMsg, sizeof(gszMsg), pFile) == NULL) return NULL; len = strlen(gszMsg); if (len == sizeof(gszMsg)-1 && gszMsg[len-1] != '\n') { char *buf=UtilStrDup(gszMsg); unsigned long cur_len; int still_going=TRUE; if (buf == NULL) return NULL; cur_len = strlen(buf); while (still_going && fgets(gszMsg, sizeof(gszMsg), pFile) != NULL) { len = strlen(gszMsg); if (len != sizeof(gszMsg)-1) { still_going = FALSE; } else if (gszMsg[len-1] == '\n') { gszMsg[--len] = '\0'; still_going = FALSE; } if (buf != NULL) { char *new_buf=(char*)realloc(buf, (size_t)(cur_len+len+1)); if (new_buf == NULL) { free(buf); return NULL; } buf = new_buf; strcat(&buf[cur_len], gszMsg); cur_len += len; } } return buf; } else { if (gszMsg[len-1] == '\n') gszMsg[--len] = '\0'; return UtilStrDup(gszMsg); } } char *UtilGetAContinuedLine(pFile) FILE *pFile; { unsigned long len; char *buf; if ((buf=UtilGetALine(pFile)) == NULL) return NULL; len = strlen(buf); while (len > 0 && buf[len-1] == '\\') { char *tmp_buf; int tmp_len; buf[--len] = '\0'; tmp_buf = UtilGetALine(pFile); if (tmp_buf == NULL) return buf; tmp_len = strlen(tmp_buf); if (tmp_len == 0) { free(tmp_buf); return buf; } else if ((buf=(char*)realloc(buf, len+tmp_len+1)) == NULL) { free(tmp_buf); return NULL; } strcpy(&buf[len], tmp_buf); len += tmp_len; free(tmp_buf); } return buf; } int UtilCopyFile(pszFromFile, pszToFile) char *pszFromFile, *pszToFile; { char buf[0x1000]; int bytes_read=0; int fd1=(-1), fd2=(-1); mode_t mode=((tmpFileMode == 0) ? 0700 : tmpFileMode); if ((fd1=open(pszFromFile, O_RDONLY)) == (-1)) return TG_REMOTE_STATUS_READ; if (UtilPathExists(pszToFile)) { if ((fd2=open(pszToFile, O_WRONLY|O_TRUNC)) == (-1)) { close(fd1); return TG_REMOTE_STATUS_WRITE; } } else { if ((fd2=open(pszToFile, O_WRONLY|O_CREAT|O_TRUNC, mode)) == (-1)) { close(fd1); return TG_REMOTE_STATUS_WRITE; } } while ((bytes_read=read(fd1, buf, sizeof(buf))) > 0) { if (write(fd2, buf, bytes_read) <= 0) { close(fd1); close(fd2); return TG_REMOTE_STATUS_FILE; } } close(fd1); close(fd2); if (tmpFileMode != 0 && chmod(pszToFile, tmpFileMode)) { char msg[MAXSTRING<<1]; sprintf(msg, TgLoadString(STID_CANNOT_CHMOD), pszToFile, tmpFileMode); MsgBox(msg, TOOL_NAME, INFO_MB); } return TG_REMOTE_STATUS_OK; } int UtilConcatFile(pszFromFile1, pszFromFile2, pszToFile) char *pszFromFile1, *pszFromFile2, *pszToFile; { char buf[0x1000]; int bytes_read=0; int fd1=(-1), fd2=(-1), fd3=(-1); mode_t mode=((tmpFileMode == 0) ? 0700 : tmpFileMode); if ((fd1=open(pszFromFile1, O_RDONLY)) == (-1)) return TG_REMOTE_STATUS_READ; if ((fd2=open(pszFromFile2, O_RDONLY)) == (-1)) { close(fd1); return TG_REMOTE_STATUS_READ; } if (UtilPathExists(pszToFile)) { if ((fd3=open(pszToFile, O_WRONLY|O_TRUNC)) == (-1)) { close(fd1); close(fd2); return TG_REMOTE_STATUS_WRITE; } } else { if ((fd3=open(pszToFile, O_WRONLY|O_CREAT|O_TRUNC, mode)) == (-1)) { close(fd1); close(fd2); return TG_REMOTE_STATUS_WRITE; } } while ((bytes_read=read(fd1, buf, sizeof(buf))) > 0) { if (write(fd3, buf, bytes_read) <= 0) { close(fd1); close(fd2); close(fd3); return TG_REMOTE_STATUS_FILE; } } close(fd1); while ((bytes_read=read(fd2, buf, sizeof(buf))) > 0) { if (write(fd3, buf, bytes_read) <= 0) { close(fd2); close(fd3); return TG_REMOTE_STATUS_FILE; } } close(fd2); close(fd3); if (tmpFileMode != 0 && chmod(pszToFile, tmpFileMode)) { char msg[MAXSTRING<<1]; sprintf(msg, TgLoadString(STID_CANNOT_CHMOD), pszToFile, tmpFileMode); MsgBox(msg, TOOL_NAME, INFO_MB); } return TG_REMOTE_STATUS_OK; } int UtilPathExists(pszPath) char *pszPath; { struct stat stat_buf; return (stat(pszPath, &stat_buf) == 0); } int UtilPathIsLink(pszPath) char *pszPath; /* * if pszPath is not valid, return FALSE * if pszPath is valid but not a link, return FALSE * if pszPath is valid and is a link, return TRUE */ { #ifndef _NO_LSTAT struct stat stat_buf; if (lstat(pszPath, &stat_buf) == 0 && ((stat_buf.st_mode & S_IFLNK) == S_IFLNK)) { return TRUE; } #endif /* _NO_LSTAT */ return FALSE; } int UtilIsDirectory(pszPath) char *pszPath; { struct stat stat_buf; return (stat(pszPath, &stat_buf) == 0 && (stat_buf.st_mode & S_IFDIR) == S_IFDIR); } int UtilCreateDirHier(pszDir) char *pszDir; { char *psz=NULL; int ok=TRUE; if (*pszDir == '\0') return FALSE; if (UtilPathExists(pszDir)) { if (UtilPathIsLink(pszDir)) { return TRUE; } if (UtilIsDirectory(pszDir)) { return TRUE; } return FALSE; } if (*pszDir == DIR_SEP && pszDir[1] == '\0') { return FALSE; } if ((psz=strrchr(pszDir, DIR_SEP)) == NULL) { return FALSE; } *psz = '\0'; if (!UtilCreateDirHier(pszDir)) { ok = FALSE; } *psz = DIR_SEP; if (ok) { if (mkdir(pszDir, 0755) != 0) { return FALSE; } } return ok; } #ifndef _NO_GETTIMEOFDAY static long ms_time(tv) struct timeval *tv; { return ((long)(tv->tv_usec / 1000.0)) + ((long)(tv->tv_sec * 1000)); } #endif /* ~_NO_GETTIMEOFDAY */ long UtilGetMilliSecTime(pl_sec, pl_msec) long *pl_sec, *pl_msec; { #ifdef _NO_GETTIMEOFDAY struct timeb start; #else /* ~_NO_GETTIMEOFDAY */ struct timeval start; struct timezone zone; #endif /* _NO_GETTIMEOFDAY */ long ms_start_time=0L; #ifdef _NO_GETTIMEOFDAY ftime(&start); ms_start_time = ((long)start.time * 1000) + ((long)start.millitm); if (pl_sec != NULL) *pl_sec = ((long)(start.time)); if (pl_msec != NULL) *pl_msec = ((long)(start.millitm)); #else /* ~_NO_GETTIMEOFDAY */ gettimeofday(&start, &zone); ms_start_time = ms_time(&start); if (pl_sec != NULL) *pl_sec = ((long)(start.tv_sec)); if (pl_msec != NULL) *pl_msec = ((long)(start.tv_usec/1000)); #endif /* _NO_GETTIMEOFDAY */ return ms_start_time; } tgif-QPL-4.2.5/mark.e0000644000076400007640000000313011602233312014061 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/mark.e,v 1.6 2011/05/16 16:21:58 william Exp $ */ #ifndef _MARK_E_ #define _MARK_E_ extern int somethingHighLighted; #ifdef _INCLUDE_FROM_MARK_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_MARK_C_*/ extern void CleanUpMark ARGS_DECL((void)); extern int InitMark ARGS_DECL((void)); extern void HighLightAnObj ARGS_DECL((struct ObjRec *)); extern void HighLightForward ARGS_DECL((void)); extern void HighLightReverse ARGS_DECL((void)); extern void AddTickMarks ARGS_DECL((int nCmdId)); extern int SetTickMarkSizeValue ARGS_DECL((char*)); extern void SetTickMarkSize ARGS_DECL((char*)); #ifdef _INCLUDE_FROM_MARK_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_MARK_C_*/ #endif /*_MARK_E_*/ tgif-QPL-4.2.5/install-sh0000755000076400007640000003160011602233316014774 0ustar williamwilliam#!/bin/sh # install - install a program, script, or datafile scriptversion=2006-10-14.15 # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the # following copyright and license. # # Copyright (C) 1994 X Consortium # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to # deal in the Software without restriction, including without limitation the # rights to use, copy, modify, merge, publish, distribute, sublicense, and/or # sell copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN # AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- # TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # # Except as contained in this notice, the name of the X Consortium shall not # be used in advertising or otherwise to promote the sale, use or other deal- # ings in this Software without prior written authorization from the X Consor- # tium. # # # FSF changes to this file are in the public domain. # # Calling this script install-sh is preferred over install.sh, to prevent # `make' implicit rules from creating a file called install from it # when there is no Makefile. # # This script is compatible with the BSD install script, but was written # from scratch. nl=' ' IFS=" "" $nl" # set DOITPROG to echo to test this script # Don't use :- since 4.3BSD and earlier shells don't like it. doit="${DOITPROG-}" if test -z "$doit"; then doit_exec=exec else doit_exec=$doit fi # Put in absolute file names if you don't have them in your path; # or use environment vars. mvprog="${MVPROG-mv}" cpprog="${CPPROG-cp}" chmodprog="${CHMODPROG-chmod}" chownprog="${CHOWNPROG-chown}" chgrpprog="${CHGRPPROG-chgrp}" stripprog="${STRIPPROG-strip}" rmprog="${RMPROG-rm}" mkdirprog="${MKDIRPROG-mkdir}" posix_glob= posix_mkdir= # Desired mode of installed file. mode=0755 chmodcmd=$chmodprog chowncmd= chgrpcmd= stripcmd= rmcmd="$rmprog -f" mvcmd="$mvprog" src= dst= dir_arg= dstarg= no_target_directory= usage="Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE or: $0 [OPTION]... SRCFILES... DIRECTORY or: $0 [OPTION]... -t DIRECTORY SRCFILES... or: $0 [OPTION]... -d DIRECTORIES... In the 1st form, copy SRCFILE to DSTFILE. In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. In the 4th, create DIRECTORIES. Options: -c (ignored) -d create directories instead of installing files. -g GROUP $chgrpprog installed files to GROUP. -m MODE $chmodprog installed files to MODE. -o USER $chownprog installed files to USER. -s $stripprog installed files. -t DIRECTORY install into DIRECTORY. -T report an error if DSTFILE is a directory. --help display this help and exit. --version display version info and exit. Environment variables override the default commands: CHGRPPROG CHMODPROG CHOWNPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG " while test $# -ne 0; do case $1 in -c) shift continue;; -d) dir_arg=true shift continue;; -g) chgrpcmd="$chgrpprog $2" shift shift continue;; --help) echo "$usage"; exit $?;; -m) mode=$2 shift shift case $mode in *' '* | *' '* | *' '* | *'*'* | *'?'* | *'['*) echo "$0: invalid mode: $mode" >&2 exit 1;; esac continue;; -o) chowncmd="$chownprog $2" shift shift continue;; -s) stripcmd=$stripprog shift continue;; -t) dstarg=$2 shift shift continue;; -T) no_target_directory=true shift continue;; --version) echo "$0 $scriptversion"; exit $?;; --) shift break;; -*) echo "$0: invalid option: $1" >&2 exit 1;; *) break;; esac done if test $# -ne 0 && test -z "$dir_arg$dstarg"; then # When -d is used, all remaining arguments are directories to create. # When -t is used, the destination is already specified. # Otherwise, the last argument is the destination. Remove it from $@. for arg do if test -n "$dstarg"; then # $@ is not empty: it contains at least $arg. set fnord "$@" "$dstarg" shift # fnord fi shift # arg dstarg=$arg done fi if test $# -eq 0; then if test -z "$dir_arg"; then echo "$0: no input file specified." >&2 exit 1 fi # It's OK to call `install-sh -d' without argument. # This can happen when creating conditional directories. exit 0 fi if test -z "$dir_arg"; then trap '(exit $?); exit' 1 2 13 15 # Set umask so as not to create temps with too-generous modes. # However, 'strip' requires both read and write access to temps. case $mode in # Optimize common cases. *644) cp_umask=133;; *755) cp_umask=22;; *[0-7]) if test -z "$stripcmd"; then u_plus_rw= else u_plus_rw='% 200' fi cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; *) if test -z "$stripcmd"; then u_plus_rw= else u_plus_rw=,u+rw fi cp_umask=$mode$u_plus_rw;; esac fi for src do # Protect names starting with `-'. case $src in -*) src=./$src ;; esac if test -n "$dir_arg"; then dst=$src dstdir=$dst test -d "$dstdir" dstdir_status=$? else # Waiting for this to be detected by the "$cpprog $src $dsttmp" command # might cause directories to be created, which would be especially bad # if $src (and thus $dsttmp) contains '*'. if test ! -f "$src" && test ! -d "$src"; then echo "$0: $src does not exist." >&2 exit 1 fi if test -z "$dstarg"; then echo "$0: no destination specified." >&2 exit 1 fi dst=$dstarg # Protect names starting with `-'. case $dst in -*) dst=./$dst ;; esac # If destination is a directory, append the input filename; won't work # if double slashes aren't ignored. if test -d "$dst"; then if test -n "$no_target_directory"; then echo "$0: $dstarg: Is a directory" >&2 exit 1 fi dstdir=$dst dst=$dstdir/`basename "$src"` dstdir_status=0 else # Prefer dirname, but fall back on a substitute if dirname fails. dstdir=` (dirname "$dst") 2>/dev/null || expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$dst" : 'X\(//\)[^/]' \| \ X"$dst" : 'X\(//\)$' \| \ X"$dst" : 'X\(/\)' \| . 2>/dev/null || echo X"$dst" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q' ` test -d "$dstdir" dstdir_status=$? fi fi obsolete_mkdir_used=false if test $dstdir_status != 0; then case $posix_mkdir in '') # Create intermediate dirs using mode 755 as modified by the umask. # This is like FreeBSD 'install' as of 1997-10-28. umask=`umask` case $stripcmd.$umask in # Optimize common cases. *[2367][2367]) mkdir_umask=$umask;; .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; *[0-7]) mkdir_umask=`expr $umask + 22 \ - $umask % 100 % 40 + $umask % 20 \ - $umask % 10 % 4 + $umask % 2 `;; *) mkdir_umask=$umask,go-w;; esac # With -d, create the new directory with the user-specified mode. # Otherwise, rely on $mkdir_umask. if test -n "$dir_arg"; then mkdir_mode=-m$mode else mkdir_mode= fi posix_mkdir=false case $umask in *[123567][0-7][0-7]) # POSIX mkdir -p sets u+wx bits regardless of umask, which # is incompatible with FreeBSD 'install' when (umask & 300) != 0. ;; *) tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0 if (umask $mkdir_umask && exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1 then if test -z "$dir_arg" || { # Check for POSIX incompatibilities with -m. # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or # other-writeable bit of parent directory when it shouldn't. # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. ls_ld_tmpdir=`ls -ld "$tmpdir"` case $ls_ld_tmpdir in d????-?r-*) different_mode=700;; d????-?--*) different_mode=755;; *) false;; esac && $mkdirprog -m$different_mode -p -- "$tmpdir" && { ls_ld_tmpdir_1=`ls -ld "$tmpdir"` test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" } } then posix_mkdir=: fi rmdir "$tmpdir/d" "$tmpdir" else # Remove any dirs left behind by ancient mkdir implementations. rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null fi trap '' 0;; esac;; esac if $posix_mkdir && ( umask $mkdir_umask && $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" ) then : else # The umask is ridiculous, or mkdir does not conform to POSIX, # or it failed possibly due to a race condition. Create the # directory the slow way, step by step, checking for races as we go. case $dstdir in /*) prefix=/ ;; -*) prefix=./ ;; *) prefix= ;; esac case $posix_glob in '') if (set -f) 2>/dev/null; then posix_glob=true else posix_glob=false fi ;; esac oIFS=$IFS IFS=/ $posix_glob && set -f set fnord $dstdir shift $posix_glob && set +f IFS=$oIFS prefixes= for d do test -z "$d" && continue prefix=$prefix$d if test -d "$prefix"; then prefixes= else if $posix_mkdir; then (umask=$mkdir_umask && $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break # Don't fail if two instances are running concurrently. test -d "$prefix" || exit 1 else case $prefix in *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; *) qprefix=$prefix;; esac prefixes="$prefixes '$qprefix'" fi fi prefix=$prefix/ done if test -n "$prefixes"; then # Don't fail if two instances are running concurrently. (umask $mkdir_umask && eval "\$doit_exec \$mkdirprog $prefixes") || test -d "$dstdir" || exit 1 obsolete_mkdir_used=true fi fi fi if test -n "$dir_arg"; then { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 else # Make a couple of temp file names in the proper directory. dsttmp=$dstdir/_inst.$$_ rmtmp=$dstdir/_rm.$$_ # Trap to clean up those temp files at exit. trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 # Copy the file name to the temp name. (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && # and set any options; do chmod last to preserve setuid bits. # # If any of these fail, we abort the whole thing. If we want to # ignore errors from any of these, just make sure not to ignore # errors from the above "$doit $cpprog $src $dsttmp" command. # { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } \ && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } \ && { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } \ && { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && # Now rename the file to the real destination. { $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null \ || { # The rename failed, perhaps because mv can't rename something else # to itself, or perhaps because mv is so ancient that it does not # support -f. # Now remove or move aside any old file at destination location. # We try this two ways since rm can't unlink itself on some # systems and the destination file might be busy for other # reasons. In this case, the final cleanup might fail but the new # file should still install successfully. { if test -f "$dst"; then $doit $rmcmd -f "$dst" 2>/dev/null \ || { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null \ && { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; }; }\ || { echo "$0: cannot unlink or rename $dst" >&2 (exit 1); exit 1 } else : fi } && # Now rename the file to the real destination. $doit $mvcmd "$dsttmp" "$dst" } } || exit 1 trap '' 0 fi done # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: tgif-QPL-4.2.5/eq4xpm.sym0000644000076400007640000007177311602233311014752 0ustar williamwilliam%TGIF 4.1.42-QPL state(0,37,100.000,0,64,0,32,1,9,1,1,0,0,1,0,1,0,'Courier',0,57600,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/eq4xpm.sym,v 1.1 2004/06/18 23:20:01 william Exp $ % %W% % % Author: Kai Sattler % unit("1 pixel/pixel"). shapeshadow(3,3). color_info(119,65535,1,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 53052, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 42649, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1, "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 33287, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 53052, 0, 65280, 52736, 0, 1, "#d02090", 55132, 8321, 38488, 53248, 8192, 36864, 1, "#101010", 4160, 4160, 4160, 4096, 4096, 4096, 1, "#00CC7F", 0, 53052, 31207, 0, 52224, 32512, 1, "#0000B2", 0, 0, 46810, 0, 0, 45568, 1, "#00E5E5", 0, 59293, 59293, 0, 58624, 58624, 1, "#00007F", 0, 0, 31207, 0, 0, 32512, 1, "#990000", 40569, 0, 0, 39168, 0, 0, 1, "#FFCC00", 65535, 53052, 0, 65280, 52224, 0, 1, "#4C0000", 18724, 0, 0, 19456, 0, 0, 1, "#353535", 12482, 13523, 12482, 13568, 13568, 13568, 1, "#007FFF", 0, 32247, 65535, 0, 32512, 65280, 1, "#FF6600", 65535, 26005, 0, 65280, 26112, 0, 1, "#99E500", 40569, 59293, 0, 39168, 58624, 0, 1, "#00B2FF", 0, 45770, 65535, 0, 45568, 65280, 1, "#004CE5", 0, 19764, 59293, 0, 19456, 58624, 1, "#FF9900", 65535, 39529, 0, 65280, 39168, 0, 1, "#fe0000", 65535, 0, 0, 65024, 0, 0, 1, "#0000fe", 0, 0, 65535, 0, 0, 65024, 1, "#b9b9b9", 48891, 47850, 48891, 47360, 47360, 47360, 1, "#99E566", 40569, 59293, 24965, 39168, 58624, 26112, 1, "#0099FF", 0, 39529, 65535, 0, 39168, 65280, 1, "#4CCC4C", 18724, 53052, 18724, 19456, 52224, 19456, 1, "#FFFFB2", 65535, 65535, 46810, 65280, 65280, 45568, 1, "#9CE763", 40569, 59293, 24965, 39936, 59136, 25344, 1, "#4ACF4A", 18724, 53052, 18724, 18944, 52992, 18944, 1, "#009AFF", 0, 39529, 65535, 0, 39424, 65280, 1, "#FFFFB5", 65535, 65535, 46810, 65280, 65280, 46336, 1, "#00D18C", 0, 54092, 36408, 0, 53504, 35840, 1, "#00A0E5", 0, 41609, 59293, 0, 40960, 58624, 1, "#1E3DF9", 6241, 15603, 65535, 7680, 15616, 63744, 1, "#00C6C6", 0, 50971, 50971, 0, 50688, 50688, 1, "#6B00DB", 27046, 0, 57213, 27392, 0, 56064, 1, "#A000C6", 42649, 0, 50971, 40960, 0, 50688, 1, "#6B7BB5", 27046, 31207, 46810, 27392, 31488, 46336, 1, "#637BAD", 24965, 31207, 44730, 25344, 31488, 44288, 1, "#4A63A5", 18724, 24965, 42649, 18944, 25344, 42240, 1, "#949CC6", 38488, 40569, 50971, 37888, 39936, 50688, 1, "#6373AD", 24965, 29126, 44730, 25344, 29440, 44288, 1, "#D6DEEF", 55132, 57213, 61374, 54784, 56832, 61184, 1, "#A5B5D6", 42649, 46810, 55132, 42240, 46336, 54784, 1, "#CED6E7", 53052, 55132, 59293, 52736, 54784, 59136, 1, "#CECEE7", 53052, 53052, 59293, 52736, 52736, 59136, 1, "#5A73AD", 22885, 29126, 44730, 23040, 29440, 44288, 1, "#294A94", 10402, 18724, 38488, 10496, 18944, 37888, 1, "#5A6BAD", 22885, 27046, 44730, 23040, 27392, 44288, 1, "#425A9C", 16643, 22885, 40569, 16896, 23040, 39936, 1, "#294294", 10402, 16643, 38488, 10496, 16896, 37888, 1, "#526BA5", 20804, 27046, 42649, 20992, 27392, 42240, 1, "#21428C", 8321, 16643, 36408, 8448, 16896, 35840, 1, "#5263A5", 20804, 24965, 42649, 20992, 25344, 42240, 1, "#ADBDD6", 44730, 48891, 55132, 44288, 48384, 54784, 1, "#DEDEEF", 57213, 57213, 61374, 56832, 56832, 61184, 1, "#ADB5D6", 44730, 46810, 55132, 44288, 46336, 54784, 1, "#D6D6E7", 55132, 55132, 59293, 54784, 54784, 59136, 1, "#A5ADCE", 42649, 44730, 53052, 42240, 44288, 52736, 1, "#395A9C", 14563, 22885, 40569, 14592, 23040, 39936, 1, "#39529C", 14563, 20804, 40569, 14592, 20992, 39936, 1, "#315294", 12482, 20804, 38488, 12544, 20992, 37888, 1, "#314A94", 12482, 18724, 38488, 12544, 18944, 37888, 1, "#E7EFF7", 59293, 61374, 63454, 59136, 61184, 63232, 1, "#E7E7F7", 59293, 59293, 63454, 59136, 59136, 63232, 1, "#738CBD", 29126, 36408, 48891, 29440, 35840, 48384, 1, "#9CADCE", 40569, 44730, 53052, 39936, 44288, 52736, 1, "#6B84B5", 27046, 34327, 46810, 27392, 33792, 46336, 1, "#B5BDD6", 46810, 48891, 55132, 46336, 48384, 54784, 1, "#9CA5CE", 40569, 42649, 53052, 39936, 42240, 52736, 1, "#8494BD", 34327, 38488, 48891, 33792, 37888, 48384, 1, "#94A5C6", 38488, 42649, 50971, 37888, 42240, 50688, 1, "#F7FFFF", 63454, 65535, 65535, 63232, 65280, 65280, 1, "#F7F7FF", 63454, 63454, 65535, 63232, 63232, 65280, 1, "#EFF7F7", 61374, 63454, 63454, 61184, 63232, 63232, 1, "#EFEFF7", 61374, 61374, 63454, 61184, 61184, 63232, 1, "#E7E7EF", 59293, 59293, 61374, 59136, 59136, 61184, 1, "#7B8CBD", 31207, 36408, 48891, 31488, 35840, 48384, 1, "#7384B5", 29126, 34327, 46810, 29440, 33792, 46336, 1, "#083184", 2080, 12482, 34327, 2048, 12544, 33792, 1, "#082984", 2080, 10402, 34327, 2048, 10496, 33792, 1, "#21398C", 8321, 14563, 36408, 8448, 14592, 35840, 1, "#DEE7EF", 57213, 59293, 61374, 56832, 59136, 61184, 1, "#F7F7F7", 63454, 63454, 63454, 63232, 63232, 63232, 1, "#C6CEDE", 50971, 53052, 57213, 50688, 52736, 56832, 1, "#4263A5", 16643, 24965, 42649, 16896, 25344, 42240, 1, "#8C9CC6", 36408, 40569, 50971, 35840, 39936, 50688, 1, "#18398C", 6241, 14563, 36408, 6144, 14592, 35840, 1, "#18318C", 6241, 12482, 36408, 6144, 12544, 35840, 1, "#103184", 4160, 12482, 34327, 4096, 12544, 33792, 1, "#C6CEE7", 50971, 53052, 59293, 50688, 52736, 59136, 1, "#BDC6DE", 48891, 50971, 57213, 48384, 50688, 56832, 1, "#0031FF", 0, 12482, 65535, 0, 12544, 65280, 1, "#CCE57F", 53052, 59293, 31207, 52224, 58624, 32512, 1, "#939393", 38488, 37448, 38488, 37632, 37632, 37632, 1, "#FFFF99", 65535, 65535, 40569, 65280, 65280, 39168, 1, "#339933", 12482, 39529, 12482, 13056, 39168, 13056, 1, "#197F19", 6241, 32247, 6241, 6400, 32512, 6400, 1, "#66B24C", 24965, 45770, 18724, 26112, 45568, 19456, 1, "#99CC66", 40569, 53052, 24965, 39168, 52224, 26112, 1, "#5E5E5E", 22885, 23925, 22885, 24064, 24064, 24064, 1, "#006600", 0, 26005, 0, 0, 26112, 0, 1, "#C9C9C9", 53052, 52011, 53052, 51456, 51456, 51456, 1, "#7D7D7D", 31207, 32247, 31207, 32000, 32000, 32000, 1 ]). slideshow_info('#0000b2',10,10). script_frac("0.6"). fg_bg_colors('black','#ffff00'). dont_reencode("FFDingbests:ZapfDingbats"). page(1,"LaTeX equation symbol (uses ps2epsi).",1,''). group([ text('#0000ff',192,229,22,0,1,355,265,1059,11,2,0,-1,0,0,2,355,265,-1,1,"",0,0,0,0,240,'',[ minilines(355,265,-1,1,0,-1,0,[ mini_line(295,11,2,0,1,0,[ str_block(0,79,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,79,11,2,0,-2,0,0,0,0,0, "Make sure that ")]), str_block(0,24,11,2,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,57600,24,11,2,0,1,0,0,0,0,0, "latex")]), str_block(0,6,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,6,11,2,0,-2,0,0,0,0,0, ", ")]), str_block(0,27,11,2,0,0,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,57600,27,11,2,0,0,0,0,0,0,0, "dvips")]), str_block(0,6,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,6,11,2,0,-2,0,0,0,0,0, ", ")]), str_block(0,113,11,2,0,-2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,57600,113,11,2,0,-2,0,0,0,0,0, "convert (ImageMagic) ")]), str_block(0,40,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,40,11,2,0,-2,0,0,0,0,0, "and the ")]) ]), mini_line(299,11,2,-1,0,0,[ str_block(0,40,11,2,0,-2,0,0,0,[ str_seg('blue','Helvetica-BoldOblique',3,57600,40,11,2,0,-2,0,0,0,0,0, "netpbm ")]), str_block(0,97,11,2,-1,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,97,11,2,-1,-2,0,0,0,0,0, "package as well as ")]), str_block(0,11,11,2,-1,0,0,0,0,[ str_seg('blue','Helvetica-BoldOblique',3,57600,11,11,2,-1,0,0,0,0,0,0, "xv")]), str_block(0,3,11,2,0,-2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,57600,3,11,2,0,-2,0,0,0,0,0, " ")]), str_block(0,121,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,121,11,2,0,-2,0,0,0,0,0, "(eventually) are in your ")]), str_block(0,24,9,2,-1,-1,0,0,0,[ str_seg('#ff00ff','Courier-Bold',1,57600,24,9,2,-1,-1,0,0,0,0,0, "PATH")]), str_block(0,3,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,3,11,2,0,-1,0,0,0,0,0, ".")]) ]), mini_line(321,11,2,0,0,0,[ str_block(0,321,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,321,11,2,0,-2,0,0,0,0,0, "After you instantiate this symbol, you can change the resolution ")]) ]), mini_line(290,11,2,0,0,0,[ str_block(0,42,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,42,9,2,0,-1,0,0,0,0,0, "density")]), str_block(0,3,11,2,0,-2,0,0,0,[ str_seg('green','Helvetica-BoldOblique',3,57600,3,11,2,0,-2,0,0,0,0,0, " ")]), str_block(0,40,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,40,11,2,0,-2,0,0,0,0,0, "and the ")]), str_block(0,48,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,48,9,2,0,-1,0,0,0,0,0, "geometry")]), str_block(0,3,11,2,0,-2,0,0,0,[ str_seg('green','Helvetica-BoldOblique',3,57600,3,11,2,0,-2,0,0,0,0,0, " ")]), str_block(0,154,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,154,11,2,0,-1,0,0,0,0,0, "in order to enhance the quality.")]) ]), mini_line(319,11,2,0,0,0,[ str_block(0,319,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,319,11,2,0,-2,0,0,0,0,0, "In addition, you can set the number of colors used in the image. ")]) ]), mini_line(315,11,2,0,0,0,[ str_block(0,55,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,55,11,2,0,-2,0,0,0,0,0, "To do this, ")]), str_block(0,52,11,2,0,0,0,0,0,[ str_seg('magenta','Helvetica-BoldOblique',3,57600,52,11,2,0,0,0,0,0,0,0, "right-click")]), str_block(0,208,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,208,11,2,0,0,0,0,0,0,0, " on the symbol and choose \"Edit Attribute")]) ]), mini_line(329,11,2,0,0,0,[ str_block(0,159,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,159,11,2,0,-2,0,0,0,0,0, "in Editor\". Ther you can find the ")]), str_block(0,48,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,48,9,2,0,-1,0,0,0,0,0, "density=")]), str_block(0,25,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,25,11,2,0,-2,0,0,0,0,0, ", the ")]), str_block(0,54,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,54,9,2,0,-1,0,0,0,0,0, "geometry=")]), str_block(0,43,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,43,11,2,0,-2,0,0,0,0,0, " and the ")]) ]), mini_line(355,11,2,0,0,0,[ str_block(0,48,9,2,0,-5,0,0,0,[ str_seg('blue','Courier',0,57600,48,9,2,0,-5,0,0,0,0,0, "colors= ")]), str_block(0,307,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,307,11,2,0,0,0,0,0,0,0, "Attributes. The default values already give quite a reasonable")]) ]), mini_line(326,11,2,0,1,0,[ str_block(0,326,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,326,11,2,0,1,0,0,0,0,0, "quality of the equation image. Under this menue, you can also find")]) ]), mini_line(318,11,2,0,0,0,[ str_block(0,19,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,19,11,2,0,-2,0,0,0,0,0, "the ")]), str_block(0,18,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,18,9,2,0,-1,0,0,0,0,0, "eq=")]), str_block(0,281,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,281,11,2,0,-1,0,0,0,0,0, " Attribute, where you can edit the equation in TeX-style.")]) ]), mini_line(330,11,2,0,1,0,[ str_block(0,129,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,129,11,2,0,-2,0,0,0,0,0, "As soon as the symbol is ")]), str_block(0,62,11,2,0,0,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,57600,62,11,2,0,0,0,0,0,0,0, "double-click")]), str_block(0,139,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,139,11,2,0,1,0,0,0,0,0, "ed for the first time, you will")]) ]), mini_line(329,11,2,0,0,0,[ str_block(0,329,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,329,11,2,0,0,0,0,0,0,0, "be prompted for an equation name, which you just can answer with")]) ]), mini_line(339,11,2,0,0,0,[ str_block(0,37,11,2,0,-1,0,0,0,[ str_seg('magenta','Helvetica-BoldOblique',3,57600,37,11,2,0,-1,0,0,0,0,0, "ENTER,")]), str_block(0,302,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,302,11,2,0,0,0,0,0,0,0, " if you don't need to refer to the equation. The equation name")]) ]), mini_line(324,11,2,0,0,0,[ str_block(0,324,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,324,11,2,0,0,0,0,0,0,0, "will then be a unique number. After this the LaTeX scripts will run")]) ]), mini_line(171,11,2,0,0,0,[ str_block(0,171,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,171,11,2,0,-2,0,0,0,0,0, "as well as the image conversions. ")]) ]), mini_line(347,11,2,0,1,0,[ str_block(0,28,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,28,11,2,0,-2,0,0,0,0,0, "If the ")]), str_block(0,30,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,30,9,2,0,-1,0,0,0,0,0, "proc=")]), str_block(0,94,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,94,11,2,0,-2,0,0,0,0,0, " attribute contains ")]), str_block(0,18,9,2,0,0,0,0,0,[ str_seg('blue','Courier',0,57600,18,9,2,0,0,0,0,0,0,0, "cmd")]), str_block(0,177,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,177,11,2,0,1,0,0,0,0,0, ", then the image will directly appear")]) ]), mini_line(327,11,2,-1,0,0,[ str_block(0,98,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,98,11,2,0,-2,0,0,0,0,0, "in tgif. If it contains ")]), str_block(0,24,9,2,0,0,0,0,0,[ str_seg('blue','Courier',0,57600,24,9,2,0,0,0,0,0,0,0, "ecmd")]), str_block(0,31,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,31,11,2,0,-2,0,0,0,0,0, ", then ")]), str_block(0,11,11,2,-1,0,0,0,0,[ str_seg('blue','Helvetica-BoldOblique',3,57600,11,11,2,-1,0,0,0,0,0,0, "xv")]), str_block(0,163,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,163,11,2,0,0,0,0,0,0,0, " will be launched before inclusion")]) ]), mini_line(348,11,2,0,0,0,[ str_block(0,348,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,348,11,2,0,0,0,0,0,0,0, "of the equation image. You then have the possibility to manipulate the")]) ]), mini_line(337,11,2,0,1,0,[ str_block(0,337,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,337,11,2,0,1,0,0,0,0,0, "image. NOTE that you have to save the image then as XPM and quit")]) ]), mini_line(189,11,2,-1,0,0,[ str_block(0,11,11,2,-1,0,0,0,0,[ str_seg('blue','Helvetica-BoldOblique',3,57600,11,11,2,-1,0,0,0,0,0,0, "xv")]), str_block(0,178,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,178,11,2,0,-1,0,0,0,0,0, " in order to include the image in tgif.")]) ]), mini_line(316,11,2,0,1,0,[ str_block(0,21,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,21,11,2,0,-2,0,0,0,0,0, "The ")]), str_block(0,18,9,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,57600,18,9,2,0,-1,0,0,0,0,0, "eq=")]), str_block(0,277,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,277,11,2,0,1,0,0,0,0,0, "attribute visible in the beginning is hidden after the first")]) ]), mini_line(60,11,2,0,0,0,[ str_block(0,60,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,60,11,2,0,-1,0,0,0,0,0, "compilation.")]) ]) ])]), text('#0000ff',192,194,3,0,1,257,37,643,11,2,0,-1,0,0,2,257,37,0,0,"",0,0,0,0,205,'',[ minilines(257,37,0,0,0,-1,0,[ mini_line(238,11,2,0,0,0,[ str_block(0,136,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,136,11,2,0,-2,0,0,0,0,0, "Make sure you are running ")]), str_block(0,53,11,2,0,0,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,57600,53,11,2,0,0,0,0,0,0,0, "tgif-4.1.11")]), str_block(0,49,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,49,11,2,0,-1,0,0,0,0,0, " or newer.")]) ]), mini_line(257,11,2,0,0,0,[ str_block(0,257,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,257,11,2,0,0,0,0,0,0,0, "You can find out what version of tgif you are running")]) ]), mini_line(219,11,2,0,0,0,[ str_block(0,219,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,219,11,2,0,-1,0,0,0,0,0, "by selecting About() from the Special menu.")]) ]) ])]), text('#0000ff',160,229,1,0,1,16,13,848,11,2,0,0,0,0,2,16,13,0,0,"",0,0,0,0,240,'',[ minilines(16,13,0,0,0,0,0,[ mini_line(16,11,2,0,0,0,[ str_block(0,16,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,16,11,2,0,0,0,0,0,0,0, "(2)")]) ]) ])]), text('#0000ff',160,194,1,0,1,16,13,863,11,2,0,0,0,0,2,16,13,0,0,"",0,0,0,0,205,'',[ minilines(16,13,0,0,0,0,0,[ mini_line(16,11,2,0,0,0,[ str_block(0,16,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,16,11,2,0,0,0,0,0,0,0, "(1)")]) ]) ])]) ], 13509,0,0,[ ]). sym([ polygon('yellow','',5,[ 64,150,128,150,128,134,64,134,64,150],0,1,0,0,212,0,0,0,0,0,'1',0, "00",[ ]) ], 593,0,0,[ attr("ecmd=", "", 0, 1, 0, text('blue',160,449,6,0,1,1215,96,14196,13,3,0,0,0,0,2,1215,96,0,0,"",0,0,0,0,462,'',[ minilines(1215,96,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "ecmd=")]) ]), mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-4,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(459,13,3,0,0,0,[ str_block(0,459,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,459,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e latex $(file_name);")]) ]), mini_line(711,13,3,0,0,0,[ str_block(0,711,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,711,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e dvips -E -n 1 -o $(file_name).eps $(file_name);")]) ]), mini_line(1215,13,3,0,0,0,[ str_block(0,1215,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1215,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e convert -geometry $(geometry) -density $(density) -colors $(colors) $(file_name).eps $(file_name).ppm;")]) ]), mini_line(369,13,3,0,0,0,[ str_block(0,369,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,369,13,3,0,-4,0,0,0,0,0, " xv -geometry +50+50 $(file_name).ppm;")]) ]) ])])), attr("eq=", "", 1, 1, 0, text('blue',160,98,5,0,1,135,80,25,13,3,0,0,0,0,2,135,80,0,0,"",0,0,0,0,111,'',[ minilines(135,80,0,0,0,0,0,[ mini_line(27,13,3,0,0,0,[ str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, "eq=")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "\\LARGE")]) ]), mini_line(18,13,3,0,0,0,[ str_block(0,18,13,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,18,13,3,0,-3,0,0,0,0,0, "\\[")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,135,13,3,0,-2,0,0,0,0,0, " E\\,=\\,M\\,C^2")]) ]), mini_line(18,13,3,0,0,0,[ str_block(0,18,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,18,13,3,0,-4,0,0,0,0,0, "\\]")]) ]) ])])), attr("file_name=", "", 0, 1, 0, text('blue',161,939,1,0,1,90,16,29,13,3,0,0,0,0,2,90,16,0,0,"",0,0,0,0,952,'',[ minilines(90,16,0,0,0,0,0,[ mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, "file_name=")]) ]) ])])), attr("cleanup=", "", 0, 1, 0, text('blue',162,644,4,0,1,540,64,14605,13,3,0,0,0,0,2,540,64,0,0,"",0,0,0,0,657,'',[ minilines(540,64,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "cleanup=")]) ]), mini_line(540,13,3,0,0,0,[ str_block(0,540,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,540,13,3,0,-2,0,0,0,0,0, " rm -f $(file_name).tex $(file_name).aux $(file_name).dvi")]) ]), mini_line(513,13,3,0,0,0,[ str_block(0,513,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,513,13,3,0,-2,0,0,0,0,0, " $(file_name).log $(file_name).ps $(file_name).eps")]) ]), mini_line(522,13,3,0,0,0,[ str_block(0,522,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,522,13,3,0,-1,0,0,0,0,0, " $(file_name).ppm $(file_name).xpm $(file_name).gif")]) ]) ])])), attr("exec=", "", 0, 1, 0, text('blue',161,179,14,0,1,477,224,14429,13,3,0,0,0,0,2,477,224,0,0,"",0,0,0,0,192,'',[ minilines(477,224,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "exec=")]) ]), mini_line(378,13,3,0,0,0,[ str_block(0,378,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,378,13,3,0,-4,0,0,0,0,0, " mktemp(\"/tmp/TgifXXXXXX\",\"file_name\");")]) ]), mini_line(306,13,3,0,0,0,[ str_block(0,306,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,306,13,3,0,-4,0,0,0,0,0, " strlen(name_assigned,$(name));")]) ]), mini_line(405,13,3,0,0,0,[ str_block(0,405,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,405,13,3,0,-4,0,0,0,0,0, " if($(name_assigned)==0,assign_name,NULL);")]) ]), mini_line(306,13,3,0,0,0,[ str_block(0,306,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,306,13,3,0,-4,0,0,0,0,0, " strlen(name_assigned,$(name));")]) ]), mini_line(468,13,3,0,0,0,[ str_block(0,468,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,468,13,3,0,-4,0,0,0,0,0, " if($(name_assigned)==0,assign_random_name,NULL);")]) ]), mini_line(468,13,3,0,0,0,[ str_block(0,468,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,468,13,3,0,-4,0,0,0,0,0, " write_attr_into_file(header,\"$(file_name).tex\");")]) ]), mini_line(441,13,3,0,0,0,[ str_block(0,441,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,441,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(eq,\"$(file_name).tex\");")]) ]), mini_line(477,13,3,0,0,0,[ str_block(0,477,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,477,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(footer,\"$(file_name).tex\");")]) ]), mini_line(180,13,3,0,0,0,[ str_block(0,180,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,180,13,3,0,-4,0,0,0,0,0, " launch($(proc));")]) ]), mini_line(369,13,3,0,0,0,[ str_block(0,369,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,369,13,3,0,-4,0,0,0,0,0, " update_xpm_child(\"$(file_name).xpm\");")]) ]), mini_line(288,13,3,0,0,0,[ str_block(0,288,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,288,13,3,0,-4,0,0,0,0,0, " select_obj_by_name($(name));")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,162,13,3,0,-4,0,0,0,0,0, " hide_attr(eq);")]) ]), mini_line(189,13,3,0,0,0,[ str_block(0,189,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,189,13,3,0,-4,0,0,0,0,0, " launch(\"cleanup\")")]) ]) ])])), attr("header=", "", 0, 1, 0, text('#0000ff',161,711,11,0,1,270,176,14136,13,3,0,0,0,0,2,270,176,0,0,"",0,0,0,0,724,'',[ minilines(270,176,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "header=")]) ]), mini_line(261,13,3,0,0,0,[ str_block(0,261,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,261,13,3,0,-4,0,0,0,0,0, "\\documentclass[12pt]{article}")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,162,13,3,0,-1,0,0,0,0,0, "\\oddsidemargin=0in")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "\\textwidth=6.5in")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,13,3,0,-2,0,0,0,0,0, "\\topmargin=0pt")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,13,3,0,-2,0,0,0,0,0, "\\textheight=609pt")]) ]), mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,117,13,3,0,-2,0,0,0,0,0, "\\parskip=14pt")]) ]), mini_line(270,13,3,0,0,0,[ str_block(0,270,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,270,13,3,0,-4,0,0,0,0,0, "\\setlength{\\unitlength}{0.5cm}")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,13,3,0,-4,0,0,0,0,0, "\\pagestyle{empty}")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,3,0,-4,0,0,0,0,0, "\\begin{document}")]) ]), mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,13,3,0,-1,0,0,0,0,0, "%")]) ]) ])])), attr("footer=", "", 0, 1, 0, text('#ff00ff',162,887,3,0,1,126,48,613,13,3,0,0,0,0,2,126,48,0,0,"",0,0,0,0,900,'',[ minilines(126,48,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "footer=")]) ]), mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,13,3,0,-1,0,0,0,0,0, "%")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,13,3,0,-4,0,0,0,0,0, "\\end{document}")]) ]) ])])), attr("", "not_rigid", 0, 1, 0, text('blue',161,953,1,0,1,81,16,535,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,966,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "not_rigid")]) ]) ])])), attr("name=", "", 0, 1, 0, text('blue',161,5,1,0,1,45,16,13584,13,3,0,0,0,0,2,45,16,0,0,"",0,0,0,0,18,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "name=")]) ]) ])])), attr("name_assigned=", "", 0, 1, 0, text('blue',161,21,1,0,1,126,16,13738,13,3,0,0,0,0,2,126,16,0,0,"",0,0,0,0,34,'',[ minilines(126,16,0,0,0,0,0,[ mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,126,13,3,0,-1,0,0,0,0,0, "name_assigned=")]) ]) ])])), attr("assign_name=", "", 0, 1, 0, text('blue',161,37,2,0,1,1413,32,14586,13,3,0,0,0,0,2,1413,32,0,0,"",0,0,0,0,50,'',[ minilines(1413,32,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "assign_name=")]) ]), mini_line(1413,13,3,0,0,0,[ str_block(0,1413,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1413,13,3,0,-4,0,0,0,0,0, " get_user_input(name,\"Please give a name to this equation object:\",\"( A random name will be assigned if an empty string is entered or is pressed. )\");")]) ]) ])])), attr("assign_random_name=", "", 0, 1, 0, text('blue',161,69,2,0,1,171,32,13960,13,3,0,0,0,0,2,171,32,0,0,"",0,0,0,0,82,'',[ minilines(171,32,0,0,0,0,0,[ mini_line(171,13,3,0,0,0,[ str_block(0,171,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,171,13,3,0,-1,0,0,0,0,0, "assign_random_name=")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,135,13,3,0,-4,0,0,0,0,0, " new_id(name);")]) ]) ])])), attr("geometry=", "25%", 0, 1, 0, text('blue',161,401,1,0,1,108,16,14529,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,414,'',[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "geometry=25%")]) ]) ])])), attr("density=", "576", 0, 1, 0, text('blue',161,413,1,0,1,99,16,14548,13,3,0,0,0,0,2,99,16,0,0,"",0,0,0,0,426,'',[ minilines(99,16,0,0,0,0,0,[ mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,99,13,3,0,-2,0,0,0,0,0, "density=576")]) ]) ])])), attr("cmd=", "", 0, 1, 0, text('blue',160,545,6,0,1,1197,96,14567,13,3,0,0,0,0,2,1197,96,0,0,"",0,0,0,0,558,'',[ minilines(1197,96,0,0,0,0,0,[ mini_line(36,13,3,0,0,0,[ str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, "cmd=")]) ]), mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-4,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(459,13,3,0,0,0,[ str_block(0,459,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,459,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e latex $(file_name);")]) ]), mini_line(702,13,3,0,0,0,[ str_block(0,702,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,702,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e dvips -E -n 1 -o $(file_name).ps $(file_name);")]) ]), mini_line(1197,13,3,0,0,0,[ str_block(0,1197,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1197,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e convert -geometry $(geometry) -density $(density) -colors $(colors) $(file_name).ps $(file_name).gif;")]) ]), mini_line(540,13,3,0,0,0,[ str_block(0,540,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,540,13,3,0,-4,0,0,0,0,0, " giftopnm $(file_name).gif | ppmtoxpm > $(file_name).xpm;")]) ]) ])])), attr("proc=", "cmd", 0, 1, 0, text('blue',161,437,1,0,1,72,16,14332,13,3,0,0,0,0,2,72,16,0,0,"",0,0,0,0,450,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "proc=cmd")]) ]) ])])), attr("colors=", "16", 0, 1, 0, text('blue',161,425,1,0,1,81,16,14647,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,438,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-2,0,0,0,0,0, "colors=16")]) ]) ])])) ]). tgif-QPL-4.2.5/chinput.e0000644000076400007640000000125111602233311014602 0ustar williamwilliam/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/chinput.e,v 1.2 2011/06/14 02:32:18 william Exp $ */ #ifndef _NO_CHINPUT #ifndef _CHINPUT_E_ #define _CHINPUT_E_ #ifdef _INCLUDE_FROM_CHINPUT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_CHINPUT_C_*/ extern int Tg_HZclientInit ARGS_DECL((Display*)); extern int Tg_HZsendKey ARGS_DECL((Display*, Window, XKeyEvent*)); extern int Tg_HZhandleCM ARGS_DECL((XClientMessageEvent*, XKeyEvent*, char*)); #ifdef _INCLUDE_FROM_CHINPUT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_CHINPUT_C_*/ #endif /*_CHINPUT_E_*/ #endif /* ~_NO_CHINPUT */ tgif-QPL-4.2.5/Tgif.tmpl-dragonfly0000644000076400007640000000437611602233313016551 0ustar williamwilliamXCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-dragonfly,v 1.10 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_NO_IDNLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) XCOMM SYS_LIBRARIES = -ldl -lm -lz SYS_LIBRARIES = -lm -lz tgif-QPL-4.2.5/choice.c0000644000076400007640000021016211602233311014363 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/choice.c,v 1.15 2011/05/16 16:21:56 william Exp $ */ #define _INCLUDE_FROM_CHOICE_C_ #include "tgifdefs.h" #include "expfdefs.h" #include "align.e" #include "arc.e" #include "auxtext.e" #include "box.e" #include "choice.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "edit.e" #include "file.e" #include "font.e" #include "grid.e" #include "inmethod.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "menuinfo.e" #include "miniline.e" #include "msg.e" #include "navigate.e" #include "oval.e" #include "page.e" #include "pattern.e" #include "poly.e" #include "polygon.e" #include "raster.e" #include "rcbox.e" #include "rect.e" #include "select.e" #include "setup.e" #include "shape.e" #include "special.e" #include "stretch.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "wb.e" #include "xbitmap.e" #include "xprtfltr.e" #define FILE_ROW 0 #define ZOOM_ROW 0 #define RADIUS_ROW 0 #define PAGE_ROW 0 #define HORI_ALIGN_ROW 0 #define FONT_ROW 0 #define VSPACE_ROW 0 #define SHAPE_ROW 0 #define DASH_ROW 0 #define LINE_TYPE_ROW 0 #define FILL_ROW 0 #define COLOR_ROW 0 #define PRINT_ROW 1 #define MOVE_MODE_ROW 1 #define ROTATE_ROW 1 #define PAGELAYOUT_ROW 1 #define VERT_ALIGN_ROW 1 #define TEXT_SIZE_ROW 1 #define JUST_ROW 1 #define STRETCHTEXT_ROW 1 #define LINE_STYLE_ROW 1 #define LINE_WIDTH_ROW 1 #define PEN_ROW 1 #define TRANSPAT_ROW 1 #define FILE_COL 0 #define ZOOM_COL 1 #define RADIUS_COL 2 #define PAGE_COL 3 #define HORI_ALIGN_COL 4 #define FONT_COL 5 #define VSPACE_COL 6 #define SHAPE_COL 7 #define DASH_COL 8 #define LINE_TYPE_COL 9 #define FILL_COL 10 #define COLOR_COL 11 #define PRINT_COL 0 #define MOVE_MODE_COL 1 #define ROTATE_COL 2 #define PAGELAYOUT_COL 3 #define VERT_ALIGN_COL 4 #define TEXT_SIZE_COL 5 #define JUST_COL 6 #define STRETCHTEXT_COL 7 #define LINE_STYLE_COL 8 #define LINE_WIDTH_COL 9 #define PEN_COL 10 #define TRANSPAT_COL 11 #define CHOICE_SHIFT 4 #define CHOICE_COLOR ((COLOR_COL<fid; choiceGC = XCreateGC(mainDisplay, choiceWindow, GCForeground | GCBackground | GCFillStyle | GCFont, &values); memset(&rotatedAbcBBox, 0, sizeof(struct BBRec)); abcBitmap = XCreateBitmapFromData(mainDisplay, choiceWindow, (char *)abc_bits, abc_width, abc_height); if (abcBitmap == None) FailAllocPixmapMessage(abc_width, abc_height); abcImage = XGetImage(mainDisplay, abcBitmap, 0, 0, abc_width, abc_height, 1, ZPixmap); if (abcImage == NULL) FailAllocMessage(); } void CleanUpChoices() { XFreeGC(mainDisplay, choiceGC); choiceGC = (GC)0; XFreePixmap(mainDisplay, abcBitmap); XDestroyImage(abcImage); abcImage = NULL; if (rotatedAbcBitmap != None) XFreePixmap(mainDisplay, rotatedAbcBitmap); abcBitmap = rotatedAbcBitmap = None; } static void ShowStipple(dpy, win, gc, bitmap, col, row, w, h) Display *dpy; Window win; GC gc; Pixmap bitmap; int col, row, w, h; { if (threeDLook) { int x=1+windowPadding+col*(choiceImageW+windowPadding); int y=1+windowPadding+row*(choiceImageH+windowPadding); XGCValues values; values.stipple = bitmap; values.ts_x_origin = x; values.ts_y_origin = y; XChangeGC(dpy, gc, GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(dpy, win, gc, x, y, w, h); XSetTSOrigin(dpy, gc, 0, 0); } else { int x=col*choiceImageW, y=row*choiceImageH; XSetStipple(dpy, gc, bitmap); XFillRectangle(dpy, win, gc, x, y, w, h); } } static void HighLightThreeDButton(choice, highlight) int choice, highlight; { struct BBRec bbox; int col=0, row=0; if (!threeDLook) return; col = (choice>>CHOICE_SHIFT); row = choice-(col<>1); for (r=0; r < abcRotatedBitmapSize; r++) { int c, y=r-half_sz; double dy=((double)y)+0.5; for (c=0; c < abcRotatedBitmapSize; c++) { int x=c-half_sz; double dx=((double)x)+0.5; double new_dx=(double)0, new_dy=(double)0; ReverseTransformDoublePointThroughCTM(dx, dy, &ctm, &new_dx, &new_dy); if (new_dx >= ((double)0) && new_dx < ((double)abc_width) && new_dy >= ((double)0) && new_dy < ((double)abc_height)) { int new_x=(int)new_dx, new_y=(int)new_dy; if (new_x < 0) new_x = 0; if (new_x >= abc_width) new_x = abc_width-1; if (new_y < 0) new_y = 0; if (new_y >= abc_height) new_y = abc_height-1; if (XGetPixel(abcImage, new_x, new_y) == 1) { XPutPixel(image, c, r, 1); if (c < ltx) ltx = c; if (r < lty) lty = r; if (c > rbx) rbx = c; if (r > rby) rby = r; } } } } XPutImage(mainDisplay, rotatedAbcBitmap, xbmGC, image, 0, 0, 0, 0, abcRotatedBitmapSize, abcRotatedBitmapSize); XDestroyImage(image); rotatedAbcBBox.ltx = ltx; rotatedAbcBBox.lty = lty; rotatedAbcBBox.rbx = rbx; rotatedAbcBBox.rby = rby; } void ShowWhereToPrint() { if (colorDump) { XSetForeground(mainDisplay, rasterGC, colorPixels[colorIndex]); } ShowStipple(mainDisplay, choiceWindow, rasterGC, whereToPrintPixmap[whereToPrint], PRINT_COL, PRINT_ROW, choiceImageW, choiceImageH); if (colorDump) XSetForeground(mainDisplay, rasterGC, myFgPixel); } void ShowColor(PropagateWhereToPrint) int PropagateWhereToPrint; { XGCValues values; if (colorDisplay) { int x=COLOR_COL*choiceImageW, y=COLOR_ROW*choiceImageH; if (threeDLook) { x = 1+windowPadding+COLOR_COL*(choiceImageW+windowPadding); y = 1+windowPadding+COLOR_ROW*(choiceImageH+windowPadding); } values.foreground = colorPixels[colorIndex]; values.function = GXcopy; values.fill_style = FillOpaqueStippled; values.stipple = patPixmap[1]; XChangeGC(mainDisplay, patGC, GCForeground | GCFunction | GCFillStyle | GCStipple, &values); XFillRectangle(mainDisplay, choiceWindow, patGC, x, y, choiceImageW, choiceImageH); } if (PropagateWhereToPrint) ShowWhereToPrint(); } void ShowHoriAlign() { ShowStipple(mainDisplay, choiceWindow, rasterGC, alignHoriPixmap[horiAlign], HORI_ALIGN_COL, HORI_ALIGN_ROW, choiceImageW, choiceImageH); } void ShowVertAlign() { ShowStipple(mainDisplay, choiceWindow, rasterGC, alignVertPixmap[vertAlign], VERT_ALIGN_COL, VERT_ALIGN_ROW, choiceImageW, choiceImageH); } void ShowJust() { ShowStipple(mainDisplay, choiceWindow, rasterGC, justPixmap[textJust], JUST_COL, JUST_ROW, choiceImageW, choiceImageH); } void ShowCurFont() { static int snPrevShowDoubleByteFont=INVALID; char *choice_char=GetShowFontChar(curFont); int x, y, w, h, choice_len=(choice_char==NULL ? 0 : strlen(choice_char)); XRectangle recs[1]; XGCValues values; int image_x=FONT_COL*choiceImageW, image_y=FONT_ROW*choiceImageH; int saved_sz_unit=curSzUnit; if (threeDLook) { image_x = 1+windowPadding+FONT_COL*(choiceImageW+windowPadding); image_y = 1+windowPadding+FONT_ROW*(choiceImageH+windowPadding); } recs[0].x = image_x; recs[0].y = image_y; recs[0].width = choiceImageW; recs[0].height = choiceImageH; if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { curSzUnit = GetCurSzUnit(); SetCanvasFont(); } if (choice_char != NULL && canvasFontDoubleByte && canvasFontDoubleByteModBytes) { choice_char[0] |= 0x80; choice_char[1] |= 0x80; } if (choice_char == NULL) { /* do not translate -- the string is used to measure things */ w = XTextWidth(canvasFontPtr, "W", 1); } else { w = MyTextWidth(canvasFontPtr, choice_char, choice_len); } h = canvasFontHeight; XClearArea(mainDisplay, choiceWindow, image_x-windowPadding, image_y-windowPadding, choiceImageW+(windowPadding<<1), choiceImageH+(windowPadding<<1), FALSE); XSetFont(mainDisplay, choiceGC, canvasFontPtr->fid); XSetClipRectangles(mainDisplay, choiceGC, 0, 0, recs, 1, YXBanded); values.foreground = myFgPixel; values.background = myBgPixel; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground, &values); x = (w > choiceImageW) ? image_x - (w-choiceImageW)/2 : image_x + (choiceImageW-w)/2; y = (h > choiceImageH) ? image_y + (canvasFontAsc-(h-choiceImageH)/2) : image_y + (canvasFontAsc+(choiceImageH-h)/2); if (canvasFontDoubleByte && canvasFontDoubleByteVertical) { Pixmap bitmap=None; TextExtentsInfo stTextExtents; memset(&stTextExtents, 0, sizeof(TextExtentsInfo)); /* choice_char cannot be NULL */ stTextExtents.buf = choice_char; stTextExtents.len = choice_len; bitmap = PaintVertChar(&stTextExtents, ROTATE270); if (bitmap == None) { return; } x = image_x + ((choiceImageW-stTextExtents.bbox_h)>>1); y = image_y + ((choiceImageH-stTextExtents.bbox_w)>>1); values.clip_mask = bitmap; values.clip_x_origin = x; values.clip_y_origin = y; XChangeGC(mainDisplay, choiceGC, GCClipMask | GCClipXOrigin | GCClipYOrigin, &values); XFillRectangle(mainDisplay, choiceWindow, choiceGC, (x>image_x ? x : image_x), (y>image_y ? y: image_y), (x>image_x ? stTextExtents.bbox_w : choiceImageW), (y>image_y ? stTextExtents.bbox_h : choiceImageH)); values.clip_mask = None; values.clip_x_origin = 0; values.clip_y_origin = 0; XChangeGC(mainDisplay, choiceGC, GCClipMask | GCClipXOrigin | GCClipYOrigin, &values); y += stTextExtents.bbox_w; w = stTextExtents.bbox_h; } else { if (choice_char == NULL) { /* do not translate -- the string is used to measure things */ XDrawString(mainDisplay, choiceWindow, choiceGC, x, y, "W", 1); } else { MyDrawString(mainDisplay, choiceWindow, choiceGC, mainDepth, x, y, choice_char, choice_len); } } if (curUnderlineOn) { XDrawLine(mainDisplay, choiceWindow, choiceGC, x, y+curUnderlineYOffset, x+w, y+curUnderlineYOffset); } if (curOverlineOn) { XDrawLine(mainDisplay, choiceWindow, choiceGC, x, y-canvasFontAsc-curOverlineYOffset, x+w, y-canvasFontAsc-curOverlineYOffset); } values.foreground = xorOne; values.background = xorZero; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground, &values); recs[0].x = 0; recs[0].y = 0; recs[0].width = choiceWindowW; recs[0].height = choiceWindowH; XSetClipRectangles(mainDisplay, choiceGC, 0, 0, recs, 1, YXBanded); /* * The following code was added so that when you move the text cursor * from a double-byte font to a single-byte font, we can close * the double-byte input method. */ if (gnInputMethod != TGIM_NONE) { if (snPrevShowDoubleByteFont != INVALID && snPrevShowDoubleByteFont && !canvasFontDoubleByte && tgIMDeactiveOnCreateText(mainDisplay, drawWindow)) { if (tgIMHandleCreateText(mainDisplay, drawWindow)) { } } snPrevShowDoubleByteFont = canvasFontDoubleByte; } if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { curSzUnit = saved_sz_unit; SetCanvasFont(); } } void ShowTextVSpace() { int len, x, y; char s[80]; XGCValues values; int image_x=VSPACE_COL*choiceImageW, image_y=VSPACE_ROW*choiceImageH; if (threeDLook) { image_x = 1+windowPadding+VSPACE_COL*(choiceImageW+windowPadding); image_y = 1+windowPadding+VSPACE_ROW*(choiceImageH+windowPadding); } ShowStipple(mainDisplay, choiceWindow, rasterGC, vspacePixmap, VSPACE_COL, VSPACE_ROW, choiceImageW, choiceImageH); sprintf(s, "%1d", textVSpace); len = strlen(s); if (threeDLook) { x = image_x+(choiceImageW>>1)-1; y = image_y+((choiceImageH-rulerFontAsc)>>1)+rulerFontAsc; } else { x = (int)((VSPACE_COL+0.5)*choiceImageW-2); y = VSPACE_ROW*choiceImageH+((choiceImageH-rulerFontAsc)>>1)+rulerFontAsc; } values.foreground = myFgPixel; values.background = myBgPixel; values.font = rulerFontPtr->fid; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground | GCFont, &values); XDrawString(mainDisplay, choiceWindow, choiceGC, x, y, s, len); values.foreground = xorOne; values.background = xorZero; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground, &values); } void ShowZoom() { int len, x, y, w, x_w, one_w; char s[80]; XGCValues values; int image_x=ZOOM_COL*choiceImageW, image_y=ZOOM_ROW*choiceImageH; if (threeDLook) { image_x = 1+windowPadding+ZOOM_COL*(choiceImageW+windowPadding); image_y = 1+windowPadding+ZOOM_ROW*(choiceImageH+windowPadding); } XClearArea(mainDisplay, choiceWindow, image_x-windowPadding, image_y-windowPadding, choiceImageW+(windowPadding<<1), choiceImageH+(windowPadding<<1), FALSE); sprintf(s, "x%1d", 1<>1); y = image_y+((choiceImageH-rulerFontAsc)>>1)+rulerFontAsc; values.foreground = myFgPixel; values.background = myBgPixel; values.font = rulerFontPtr->fid; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground | GCFont, &values); /* do not translate -- program constants */ XDrawString(mainDisplay, choiceWindow, choiceGC, x, y, "x", 1); x += x_w; sprintf(s, "%1d", 1<>1) + windowPadding + 1; /* do not translate -- program constants */ XDrawString(mainDisplay, choiceWindow, choiceGC, x+((w-x_w-one_w)>>1), y-2, "1", 1); XDrawLine(mainDisplay, choiceWindow, choiceGC, x, y, x+(w-x_w-1), y); XDrawString(mainDisplay, choiceWindow, choiceGC, x, y+rulerFontAsc, s, len); } values.foreground = xorOne; values.background = xorZero; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground, &values); } void ShowTextSize() { int len, x, y, w; char s[80]; XGCValues values; int image_x=TEXT_SIZE_COL*choiceImageW, image_y=TEXT_SIZE_ROW*choiceImageH; int sz_unit=GetCurSzUnit(); if (threeDLook) { image_x = 1+windowPadding+TEXT_SIZE_COL*(choiceImageW+windowPadding); image_y = 1+windowPadding+TEXT_SIZE_ROW*(choiceImageH+windowPadding); } XClearArea(mainDisplay, choiceWindow, image_x-windowPadding, image_y-windowPadding, choiceImageW+(windowPadding<<1), choiceImageH+(windowPadding<<1), FALSE); if (showFontSizeInPoints) { sprintf(s, "%1dpt", SzUnitToPointSize(sz_unit)); } else { sprintf(s, "%1d", SzUnitToFontSize(sz_unit)); } len = strlen(s); w = XTextWidth(defaultFontPtr, s, len); x = image_x + ((choiceImageW-w)>>1); y = image_y + ((choiceImageH-defaultFontAsc)>>1) + defaultFontAsc; values.foreground = myFgPixel; values.background = myBgPixel; values.font = defaultFontPtr->fid; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground | GCFont, &values); XDrawString(mainDisplay, choiceWindow, choiceGC, x, y, s, len); values.foreground = xorOne; values.background = xorZero; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground, &values); } void ShowRotate() { int ltx, lty, w, h, rbx, rby, x, y; XGCValues values; Pixmap bitmap=None; int image_x=ROTATE_COL*choiceImageW, image_y=ROTATE_ROW*choiceImageH; if (threeDLook) { image_x = 1+windowPadding+ROTATE_COL*(choiceImageW+windowPadding); image_y = 1+windowPadding+ROTATE_ROW*(choiceImageH+windowPadding); } UpdateAbcBitmap(); XClearArea(mainDisplay, choiceWindow, image_x-windowPadding, image_y-windowPadding, choiceImageW+(windowPadding<<1), choiceImageH+(windowPadding<<1), FALSE); if (textRotation == 0) { bitmap = abcBitmap; x = 0; y = 0; w = abc_width; h = abc_height; } else { bitmap = rotatedAbcBitmap; x = rotatedAbcBBox.ltx; y = rotatedAbcBBox.lty; w = rotatedAbcBBox.rbx-x; h = rotatedAbcBBox.rby-y; } ltx = ((choiceImageW-w)>>1); lty = ((choiceImageH-h)>>1); rbx = ltx + w; rby = lty + h; if (ltx < 0) { x = (-ltx); w -= x; ltx = 0; } if (lty < 0) { y = (-lty); h -= y; lty = 0; } if (rbx > choiceImageW) { w -= (rbx-choiceImageW); rbx = choiceImageW; } if (rby > choiceImageH) { h -= (rbx-choiceImageH); rby = choiceImageH; } values.foreground = myFgPixel; values.background = myBgPixel; values.function = GXcopy; values.fill_style = FillStippled; values.ts_x_origin = image_x+ltx-x; values.ts_y_origin = image_y+lty-y; values.stipple = bitmap; XChangeGC(mainDisplay, patGC, GCForeground | GCBackground | GCFunction | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, choiceWindow, patGC, image_x+ltx, image_y+lty, rbx-ltx, rby-lty); XSetTSOrigin(mainDisplay, patGC, 0, 0); } void ShowLineWidth() { char s[40]; int x, y, len, w; XGCValues values; int image_x=LINE_WIDTH_COL*choiceImageW, image_y=LINE_WIDTH_ROW*choiceImageH; if (threeDLook) { image_x = 1+windowPadding+LINE_WIDTH_COL*(choiceImageW+windowPadding); image_y = 1+windowPadding+LINE_WIDTH_ROW*(choiceImageH+windowPadding); } ShowStipple(mainDisplay, choiceWindow, rasterGC, shortLineWidthPixmap[lineWidth], LINE_WIDTH_COL, LINE_WIDTH_ROW, choiceImageW, choiceImageH); UtilStrCpyN(s, sizeof(s), curWidthOfLineSpec[lineWidth]); len = strlen(s); w = rulerFontWidth * len; x = image_x+((choiceImageW-w)>>1); y = image_y+((choiceImageH-rulerFontAsc)>>1) + rulerFontAsc; values.foreground = (threeDLook ? myLtGryPixel : myBgPixel); values.background = (threeDLook ? myLtGryPixel : myBgPixel); values.font = rulerFontPtr->fid; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground | GCFont, &values); XFillRectangle(mainDisplay, choiceWindow, choiceGC, x-2, y-rulerFontAsc-2, w+4, rulerFontAsc+4); XSetForeground(mainDisplay, choiceGC, myFgPixel); XDrawString(mainDisplay, choiceWindow, choiceGC, x, y, s, len); values.foreground = xorOne; values.background = xorZero; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground, &values); } void ShowLineStyle() { ShowStipple(mainDisplay, choiceWindow, rasterGC, shortLineStylePixmap[lineStyle], LINE_STYLE_COL, LINE_STYLE_ROW, choiceImageW, choiceImageH); } void ShowLineType() { ShowStipple(mainDisplay, choiceWindow, rasterGC, shortLineTypePixmap[curSpline], LINE_TYPE_COL, LINE_TYPE_ROW, choiceImageW, choiceImageH); } void ShowDash() { ShowStipple(mainDisplay, choiceWindow, rasterGC, shortDashPixmap[curDash], DASH_COL, DASH_ROW, choiceImageW, choiceImageH); } void ShowFile() { switch (pageStyle) { case PORTRAIT: ShowStipple(mainDisplay, choiceWindow, rasterGC, filePixmap, FILE_COL, FILE_ROW, choiceImageW, choiceImageH); break; case LANDSCAPE: ShowStipple(mainDisplay, choiceWindow, rasterGC, landscapePixmap, FILE_COL, FILE_ROW, choiceImageW, choiceImageH); break; } } void ShowRCBRadius() { int len, x, y; char s[80]; XGCValues values; int image_x=RADIUS_COL*choiceImageW, image_y=RADIUS_ROW*choiceImageH; if (threeDLook) { image_x = 1+windowPadding+RADIUS_COL*(choiceImageW+windowPadding); image_y = 1+windowPadding+RADIUS_ROW*(choiceImageH+windowPadding); } ShowStipple(mainDisplay, choiceWindow, rasterGC, rcbRadiusPixmap, RADIUS_COL, RADIUS_ROW, choiceImageW, choiceImageH); sprintf(s, "%1d", rcbRadius); len = strlen(s); if (threeDLook) { x = image_x+(choiceImageW>>1)-1; y = image_y+((choiceImageH-rulerFontAsc)>>1)+rulerFontAsc; } else { x = (int)((RADIUS_COL+0.5)*choiceImageW-2); y = (((RADIUS_ROW+1)*choiceImageH-rulerFontAsc)>>1)+rulerFontAsc; } values.foreground = myFgPixel; values.background = myBgPixel; values.font = rulerFontPtr->fid; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground | GCFont, &values); XDrawString(mainDisplay, choiceWindow, choiceGC, x, y, s, len); values.foreground = xorOne; values.background = xorZero; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground, &values); } void ShowMoveMode() { ShowStipple(mainDisplay, choiceWindow, rasterGC, moveModePixmap[moveMode], MOVE_MODE_COL, MOVE_MODE_ROW, choiceImageW, choiceImageH); } void ShowShape() { ShowStipple(mainDisplay, choiceWindow, rasterGC, shapePixmap[SHAPE_STAR], SHAPE_COL, SHAPE_ROW, choiceImageW, choiceImageH); } void ShowStretchableTextMode() { ShowStipple(mainDisplay, choiceWindow, rasterGC, stretchableModePixmap[stretchableText], STRETCHTEXT_COL, STRETCHTEXT_ROW, choiceImageW, choiceImageH); } void ShowFill() { XGCValues values; int image_x=FILL_COL*choiceImageW, image_y=FILL_ROW*choiceImageH; if (threeDLook) { image_x = 1+windowPadding+FILL_COL*(choiceImageW+windowPadding); image_y = 1+windowPadding+FILL_ROW*(choiceImageH+windowPadding); } values.foreground = myFgPixel; values.background = (threeDLook ? myLtGryPixel : myBgPixel); values.function = GXcopy; values.fill_style = FillOpaqueStippled; values.stipple = patPixmap[objFill]; values.ts_x_origin = image_x; values.ts_y_origin = image_y; XChangeGC(mainDisplay, patGC, GCForeground | GCBackground | GCFunction | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, choiceWindow, patGC, image_x, image_y, choiceImageW, choiceImageH); XSetTSOrigin(mainDisplay, patGC, 0, 0); } void ShowTransPatMode() { ShowStipple(mainDisplay, choiceWindow, rasterGC, transPatPixmap[transPat], TRANSPAT_COL, TRANSPAT_ROW, choiceImageW, choiceImageH); } void ShowPen() { XGCValues values; int image_x=PEN_COL*choiceImageW, image_y=PEN_ROW*choiceImageH; if (threeDLook) { image_x = 1+windowPadding+PEN_COL*(choiceImageW+windowPadding); image_y = 1+windowPadding+PEN_ROW*(choiceImageH+windowPadding); } values.foreground = myFgPixel; values.background = (threeDLook ? myLtGryPixel : myBgPixel); values.function = GXcopy; values.fill_style = FillOpaqueStippled; values.stipple = patPixmap[penPat]; values.ts_x_origin = image_x; values.ts_y_origin = image_y; XChangeGC(mainDisplay, patGC, GCForeground | GCBackground | GCFunction | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, choiceWindow, patGC, image_x, image_y, choiceImageW, choiceImageH); XSetTSOrigin(mainDisplay, patGC, 0, 0); if (penPat != NONEPAT) { XClearArea(mainDisplay, choiceWindow, image_x+(choiceImageW>>2), image_y+(choiceImageH>>2), (choiceImageW>>1), (choiceImageH>>1), FALSE); } } void ShowPage() { int len, x, y, w; char s[80]; XGCValues values; int image_x=PAGE_COL*choiceImageW, image_y=PAGE_ROW*choiceImageH; if (threeDLook) { image_x = 1+windowPadding+PAGE_COL*(choiceImageW+windowPadding); image_y = 1+windowPadding+PAGE_ROW*(choiceImageH+windowPadding); } XClearArea(mainDisplay, choiceWindow, image_x-windowPadding, image_y-windowPadding, choiceImageW+(windowPadding<<1), choiceImageH+(windowPadding<<1), FALSE); switch (pageLayoutMode) { case PAGE_STACK: sprintf(s, "%1d/%1d", curPageNum, lastPageNum); break; case PAGE_TILE: sprintf(s, "%1dx%1d", paperCol, paperRow); break; } len = strlen(s); w = XTextWidth(rulerFontPtr, s, len); x = image_x+((choiceImageW-w)>>1); y = image_y+((choiceImageH-rulerFontAsc)>>1) + rulerFontAsc; values.foreground = myFgPixel; values.background = myBgPixel; values.font = rulerFontPtr->fid; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground | GCFont, &values); XDrawString(mainDisplay, choiceWindow, choiceGC, x, y, s, len); values.foreground = xorOne; values.background = xorZero; XChangeGC(mainDisplay, choiceGC, GCForeground | GCBackground, &values); RedrawPageWindow(); } void ShowPageLayout() { int image_x=PAGELAYOUT_COL*choiceImageW, image_y=PAGELAYOUT_ROW*choiceImageH; if (threeDLook) { image_x = 1+windowPadding+PAGELAYOUT_COL*(choiceImageW+windowPadding); image_y = 1+windowPadding+PAGELAYOUT_ROW*(choiceImageH+windowPadding); } XClearArea(mainDisplay, choiceWindow, image_x-windowPadding, image_y-windowPadding, choiceImageW+(windowPadding<<1), choiceImageH+(windowPadding<<1), FALSE); ShowStipple(mainDisplay, choiceWindow, rasterGC, pageLayoutPixmap[pageLayoutMode], PAGELAYOUT_COL, PAGELAYOUT_ROW, choiceImageW, choiceImageH); } static int NeedSelectTopObject(Choice, VertexTypeObj) int Choice, VertexTypeObj; { if (VertexTypeObj) { return (Choice==NOTHING || Choice==VERTEXMODE || Choice==ROTATEMODE); } else { return (Choice==NOTHING || Choice==ROTATEMODE); } } void ShowCurChoiceMouseStatus(choice, state, cur_text_under_mouse) int choice, cur_text_under_mouse; unsigned int state; /* 0 or ControlMask */ { if (choice == INVALID) { SetMouseStatus(TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_MAIN_MENU), TgLoadCachedString(CSTID_PARANED_NONE)); } else if (choice == NOTHING && inHyperSpace) { SetCurChoiceMouseStatusStrings(choice, TRUE, NULL, cur_text_under_mouse, state); } else { SetCurChoiceMouseStatusStrings(choice, FALSE, NULL, cur_text_under_mouse, state); } } void SetCurChoice(NewChoice) int NewChoice; { struct ObjRec *selected_single_text_obj=NULL; int old_choice=curChoice, sel_top_obj=FALSE; if (curChoice == NewChoice) return; if (gstWBInfo.do_whiteboard && (serializingFile || deserializingFile)) { return; } if (inSlideShow) { if (NewChoice == NOTHING || NewChoice == DRAWTEXT || NewChoice == VERTEXMODE || NewChoice == ROTATEMODE) { /* these modes are not allowed in slideshow */ return; } } switch (curChoice) { case NOTHING: if (topSel != NULL) { if (NewChoice == VERTEXMODE) { UnSelNonVertexObjs(TRUE, TRUE); /* with highlight */ UpdSelBBox(); } else if (NewChoice != ROTATEMODE) { if (NewChoice == DRAWTEXT && topSel != NULL && topSel == botSel && topSel->obj->type == OBJ_TEXT) { selected_single_text_obj = topSel->obj; } HighLightReverse(); RemoveAllSel(); } else { HighLightReverse(); } } break; case DRAWTEXT: CreateTextObj(TRUE, TRUE); if (NeedSelectTopObject(NewChoice, FALSE) && textDrawn) { HighLightJustDrawnText(); sel_top_obj = TRUE; } textDrawn = FALSE; textCursorShown = FALSE; break; case DRAWBOX: if (NeedSelectTopObject(NewChoice, FALSE) && boxDrawn) { SelectTopObj(); sel_top_obj = TRUE; } boxDrawn = FALSE; break; case DRAWCORNEROVAL: case DRAWCENTEROVAL: case DRAWEDGECIRCLE: if (NeedSelectTopObject(NewChoice, FALSE) && ovalDrawn) { SelectTopObj(); sel_top_obj = TRUE; } ovalDrawn = FALSE; break; case DRAWPOLY: if (NeedSelectTopObject(NewChoice, TRUE) && polyDrawn) { SelectTopObj(); sel_top_obj = TRUE; } polyDrawn = FALSE; break; case DRAWPOLYGON: if (NeedSelectTopObject(NewChoice, TRUE) && polygonDrawn) { SelectTopObj(); sel_top_obj = TRUE; } polygonDrawn = FALSE; break; case DRAWARC: case DRAWEDGEARC: if (NeedSelectTopObject(NewChoice, FALSE) && arcDrawn) { SelectTopObj(); sel_top_obj = TRUE; } arcDrawn = FALSE; break; case DRAWRCBOX: if (NeedSelectTopObject(NewChoice, FALSE) && rcBoxDrawn) { SelectTopObj(); sel_top_obj = TRUE; } rcBoxDrawn = FALSE; break; case FREEHAND: if (NeedSelectTopObject(NewChoice, TRUE) && polyDrawn) { SelectTopObj(); sel_top_obj = TRUE; } polyDrawn = FALSE; break; case VERTEXMODE: if (NewChoice == NOTHING) { HighLightReverse(); JustRemoveAllVSel(); HighLightForward(); } else if (NewChoice == ROTATEMODE) { HighLightReverse(); JustRemoveAllVSel(); } else { HighLightReverse(); RemoveAllSel(); } break; case ROTATEMODE: if (topSel != NULL) { if (NewChoice == VERTEXMODE) { UnSelNonVertexObjs(TRUE, TRUE); /* with highlight */ UpdSelBBox(); HighLightReverse(); } else if (NewChoice != NOTHING) { if (NewChoice == DRAWTEXT && topSel != NULL && topSel == botSel && topSel->obj->type == OBJ_TEXT) { selected_single_text_obj = topSel->obj; } HighLightReverse(); RemoveAllSel(); } else { HighLightReverse(); } } break; } curChoice = NewChoice; switch (curChoice) { case DRAWTEXT: case DRAWBOX: case DRAWCORNEROVAL: case DRAWCENTEROVAL: case DRAWEDGECIRCLE: case DRAWPOLY: case DRAWPOLYGON: case DRAWARC: case DRAWEDGEARC: case DRAWRCBOX: case FREEHAND: if (colorLayers && !colorLayerOn[colorIndex]) { sprintf(gszMsgBox, TgLoadString(STID_INVISIBLE_COLOR_SELECTED_YNC), colorIndex, colorMenuItems[colorIndex]); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) == MB_ID_YES) { colorLayerOn[colorIndex] = TRUE; RedrawColorWindow(); ClearAndRedrawDrawWindow(); } } break; case NOTHING: if (old_choice != VERTEXMODE && !sel_top_obj) { HighLightForward(); } break; case VERTEXMODE: if (old_choice == ROTATEMODE) { HighLightForward(); } break; case ROTATEMODE: if (sel_top_obj) { curChoice = old_choice; HighLightReverse(); curChoice = ROTATEMODE; HighLightForward(); } else if (old_choice == NOTHING) { HighLightForward(); } else if (old_choice == VERTEXMODE) { HighLightForward(); } break; } if (!setCurChoiceDontUpdateUI) { ShowCursor(); RedrawModeWindow(); UpdatePinnedMenu(MENU_MODE); ShowCurChoiceMouseStatus(curChoice, 0, FALSE); } textCursorShown = FALSE; if (inHyperSpace && curChoice != NOTHING) { ToggleHyperSpace(FALSE); } else if (!inHyperSpace && selected_single_text_obj != NULL) { CleanOuterInnerSel(); CleanOuterInnerSelForFind(); HighLightText(selected_single_text_obj, NULL, INVALID, NULL, INVALID); } } static int prevChoice=NOTHING; void PushCurChoice() /* Kouichi Matsuda's modification */ { if (curChoice == NOTHING) { SetCurChoice(prevChoice); } else { prevChoice = curChoice; SetCurChoice(NOTHING); } } static void TextVSpaceLoop(button_ev) XButtonEvent *button_ev; { int saved_text_vspace=textVSpace, res=8, done=FALSE, need_to_restore=FALSE; int orig_x=button_ev->x, orig_y=button_ev->y, saved_change=0; XEvent ev; if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, choiceWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } while (!done) { XNextEvent(mainDisplay, &ev); if (ev.type == Expose || ev.type == VisibilityNotify) { ExposeEventHandler(&ev, TRUE); } else if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); done = TRUE; } else if (ev.type == MotionNotify) { int dx=ev.xmotion.x-orig_x, dy=ev.xmotion.y-orig_y; int change=((abs(dx)>abs(dy)) ? (int)(dx/res) : (int)(dy/res)); if (change != saved_change) { textVSpace = saved_text_vspace+change; ShowTextVSpace(); saved_change = change; } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } ShowTextVSpace(); if ((topSel == NULL || stickyMenuSelection) && (textCursorH+textVSpace <= 0)) { need_to_restore = TRUE; } ChangeVSpace(textVSpace); if (need_to_restore) { textVSpace = saved_text_vspace; ShowTextVSpace(); } } static void RCBRadiusLoop(button_ev) XButtonEvent *button_ev; { int saved_rcb_radius = rcbRadius, res=8, done=FALSE; int orig_x=button_ev->x, orig_y=button_ev->y, saved_change=0; XEvent ev; if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, choiceWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } while (!done) { XNextEvent(mainDisplay, &ev); if (ev.type == Expose || ev.type == VisibilityNotify) { ExposeEventHandler(&ev, TRUE); } else if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); done = TRUE; } else if (ev.type == MotionNotify) { int dx=ev.xmotion.x-orig_x, dy=ev.xmotion.y-orig_y; int change=((abs(dx)>abs(dy)) ? (int)(dx/res) : (int)(dy/res)); if (change != saved_change) { rcbRadius = max(MIN_RCB_RADIUS, saved_rcb_radius+change); ShowRCBRadius(); saved_change = change; } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } if (topSel != NULL) ChangeAllSelRCBRadius(rcbRadius); } static void ZoomLoop(button_ev) XButtonEvent *button_ev; { int saved_zoomed_in=zoomedIn, saved_zoom_scale=zoomScale, res=8; int new_zoomed_in, new_zoom_scale, done=FALSE, saved_change=0; int initial_zoom, zoom, max_zoom, win_w, win_h; int orig_x=button_ev->x, orig_y=button_ev->y; XEvent ev; initial_zoom = (zoomedIn) ? (MAX_ZOOMED_IN-zoomScale) : (MAX_ZOOMED_IN+zoomScale); win_w = drawWinW; win_h = drawWinH; new_zoomed_in = zoomedIn; new_zoom_scale = zoomScale; while ((win_w>>1) >= paperWidth && (win_h>>1) >= paperHeight) { if (new_zoomed_in) { new_zoom_scale++; } else if (new_zoom_scale == 0) { new_zoomed_in = TRUE; new_zoom_scale++; } else { new_zoom_scale--; } win_w >>= 1; win_h >>= 1; } while (win_w < paperWidth || win_h < paperHeight) { if (!new_zoomed_in) { new_zoom_scale++; } else if (new_zoom_scale == 1) { new_zoomed_in = FALSE; new_zoom_scale--; } else { new_zoom_scale--; } win_w <<= 1; win_h <<= 1; } max_zoom = (new_zoomed_in) ? (MAX_ZOOMED_IN-new_zoom_scale) : (MAX_ZOOMED_IN+new_zoom_scale); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, choiceWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } while (!done) { XNextEvent(mainDisplay, &ev); if (ev.type == Expose || ev.type == VisibilityNotify) { ExposeEventHandler(&ev, TRUE); } else if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); done = TRUE; } else if (ev.type == MotionNotify) { int dx=ev.xmotion.x-orig_x, dy=ev.xmotion.y-orig_y; int change=((abs(dx)>abs(dy)) ? (int)(dx/res) : (int)(dy/res)); if (change != saved_change) { zoom = initial_zoom+change; if (zoom < 0) zoom = 0; if (zoom > max_zoom) zoom = max_zoom; zoomedIn = (zoom < MAX_ZOOMED_IN); zoomScale = (zoomedIn) ? (MAX_ZOOMED_IN-zoom) : (zoom-MAX_ZOOMED_IN); ShowZoom(); saved_change = change; } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } if (saved_zoomed_in==zoomedIn && saved_zoom_scale==zoomScale) return; new_zoomed_in = zoomedIn; new_zoom_scale = zoomScale; zoomedIn = saved_zoomed_in; zoomScale = saved_zoom_scale; PreciseZoom(new_zoomed_in, new_zoom_scale, FALSE); } void FormatFloat(pfval, buf) float *pfval; char *buf; { char int_buf[80], frac_buf[4]; float fval=((*pfval)*1000.0); int ival=round(fval), len; *buf = '\0'; if (ival == 0) { strcpy(buf, "0"); return; } sprintf(int_buf, "%04d", ival); len = strlen(int_buf); if (strcmp(&int_buf[len-3], "000") == 0) { *frac_buf = '\0'; } else if (strcmp(&int_buf[len-2], "00") == 0) { int_buf[len-2] = '\0'; strcpy(frac_buf, &int_buf[len-3]); } else if (strcmp(&int_buf[len-1], "0") == 0) { int_buf[len-1] = '\0'; strcpy(frac_buf, &int_buf[len-3]); } else { strcpy(frac_buf, &int_buf[len-3]); } int_buf[len-3] = '\0'; if (*frac_buf == '\0') { strcpy(buf, int_buf); } else { sprintf(buf, "%s.%s", int_buf, frac_buf); } } void FormatAngle(angle, buf) int angle; /* degrees*64 */ char *buf; { float fval=(((float)angle)/64.0); FormatFloat(&fval, buf); } static void ShowRotateMouseStatus() { char left_buf[MAXSTRING], right_buf[MAXSTRING], tmp_buf[MAXSTRING]; if (rotationIncrement == 0) { SetMouseStatus(TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PARANED_NONE)); return; } FormatAngle(rotationIncrement, tmp_buf); sprintf(left_buf, TgLoadCachedString(CSTID_ROTATE_DEGREES_CW), tmp_buf); sprintf(right_buf, TgLoadCachedString(CSTID_ROTATE_DEGREES_CCW), tmp_buf); SetMouseStatus(left_buf, TgLoadCachedString(CSTID_PARANED_NONE), right_buf); } static int ValidChoice(choice) int choice; { switch (choice) { case CHOICE_COLOR: case CHOICE_HORI_ALIGN: case CHOICE_VERT_ALIGN: case CHOICE_PAGE: case CHOICE_PAGELAYOUT: case CHOICE_JUST: case CHOICE_FONT: case CHOICE_VSPACE: case CHOICE_TEXT_SIZE: case CHOICE_ROTATE: case CHOICE_LINE_WIDTH: case CHOICE_LINE_STYLE: case CHOICE_LINE_TYPE: case CHOICE_DASH: case CHOICE_RADIUS: case CHOICE_ZOOM: case CHOICE_MOVE_MODE: case CHOICE_SHAPE: case CHOICE_STRETCHTEXT: case CHOICE_TRANSPAT: case CHOICE_PRINT: case CHOICE_FILE: case CHOICE_FILL: case CHOICE_PEN: return TRUE; } return FALSE; } int ChoiceEventHandler(input) XEvent *input; { XEvent ev; int xindex, yindex, x=0, y=0, choice; if (input->type == Expose) { XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, choiceWindow, ExposureMask, &ev)) ; RedrawChoiceWindow(); } else if (input->type == EnterNotify || input->type == LeaveNotify) { SetMouseStatus("", "", ""); if (curRaisedChoice != INVALID) { HighLightThreeDButton(curRaisedChoice, FALSE); curRaisedChoice = INVALID; } } else if (input->type == MotionNotify) { int nIndex=0; char szLeft[MAXSTRING], szRight[MAXSTRING]; if (threeDLook) { xindex = (int)((input->xmotion.x-1) / (choiceImageW+windowPadding)); yindex = (int)((input->xmotion.y-1) / (choiceImageH+windowPadding)); choice = (xindex<xmotion.x / choiceImageW); yindex = (int)(input->xmotion.y / choiceImageH); choice = (xindex<type == ButtonPress) { XButtonEvent *button_ev=(&(input->xbutton)); int delta=0, root_x, root_y; Window root_win, child_win; unsigned int status; Msg(""); switch (button_ev->button) { case Button1: delta = 1; break; case Button2: XQueryPointer(mainDisplay, rootWindow, &root_win, &child_win, &root_x, &root_y, &x, &y, &status); break; case Button3: delta = -1; break; default: return INVALID; } if (threeDLook) { xindex = (int)((input->xmotion.x-1) / (choiceImageW+windowPadding)); yindex = (int)((input->xmotion.y-1) / (choiceImageH+windowPadding)); choice = (xindex<xmotion.x / choiceImageW); yindex = (int)(input->xmotion.y / choiceImageH); choice = (xindex<= (360<<6)) textRotation -= (360<<6); ShowRotate(); if (topSel != NULL) { if (delta == 1) { RotateClockWise(); } else { RotateCounter(); } } } ShowRotateMouseStatus(); break; case CHOICE_LINE_WIDTH: if (delta == 0) { LineWidthMenu(x, y, FALSE); } else { lineWidth = (lineWidth+maxLineWidths+delta) % maxLineWidths; ShowLineWidth(); UpdatePinnedMenu(MENU_LINEWIDTH); if (topSel != NULL) { ChangeAllSelLineWidth(lineWidth, TRUE); } else { sprintf(gszMsgBox, TgLoadString(STID_LINE_WIDTH_SET_TO), curWidthOfLineSpec[lineWidth]); Msg(gszMsgBox); } QuickSetMouseStatus(lineWidthMouseStatus, 0); } break; case CHOICE_LINE_STYLE: if (delta == 0) { LineStyleMenu(x, y, FALSE); } else { lineStyle = (lineStyle+MAXLINESTYLES+delta) % MAXLINESTYLES; ShowLineStyle(); UpdatePinnedMenu(MENU_LINESTYLE); if (topSel != NULL) ChangeAllSelLineStyle(lineStyle, TRUE); QuickSetMouseStatus(lineStyleMouseStatus, 0); } break; case CHOICE_LINE_TYPE: if (delta == 0) { LineTypeMenu(x, y, FALSE); } else { curSpline = (curSpline+MAXLINETYPES+delta) % MAXLINETYPES; ShowLineType(); UpdatePinnedMenu(MENU_LINETYPE); if (topSel != NULL) { ChangeAllSelLineType(curSpline, TRUE); } else { *gszMsgBox = '\0'; switch (curSpline) { case LT_STRAIGHT: Msg(TgLoadString(STID_LINE_TYPE_IS_STRAIGHT)); break; case LT_SPLINE: Msg(TgLoadString(STID_LINE_TYPE_IS_SPLINE)); break; case LT_INTSPLINE: Msg(TgLoadString(STID_LINE_TYPE_IS_INTSPLINE)); break; case LT_STRUCT_SPLINE: Msg(TgLoadString(STID_LINE_TYPE_IS_STRUCT_SPLINE)); break; } } QuickSetMouseStatus(lineTypeMouseStatus, 0); } break; case CHOICE_DASH: if (delta == 0) { LineDashMenu(x, y, FALSE); } else { curDash = (curDash+MAXDASHES+delta) % MAXDASHES; ShowDash(); UpdatePinnedMenu(MENU_LINEDASH); if (topSel != NULL) ChangeAllSelLineDash(curDash, TRUE); QuickSetMouseStatus(lineDashMouseStatus, 0); } break; case CHOICE_RADIUS: if (delta == 0) { RCBRadiusLoop(button_ev); } else { if (rcbRadius+delta >= MIN_RCB_RADIUS) { rcbRadius += delta; ShowRCBRadius(); if (topSel != NULL) ChangeAllSelRCBRadius(rcbRadius); } QuickSetMouseStatus(rcbRadiusMouseStatus, 0); } break; case CHOICE_ZOOM: switch (delta) { case -1: ZoomOut(); QuickSetMouseStatus(zoomMouseStatus, 0); break; case 0: ZoomLoop(button_ev); break; case 1: ZoomIn(); break; } break; case CHOICE_MOVE_MODE: if (delta == 0) { MoveModeMenu(x, y, FALSE); } else { ToggleMoveMode(); QuickSetMouseStatus(moveModeMouseStatus, moveMode); } break; case CHOICE_SHAPE: if (delta == 0) ShapeMenu(x, y, FALSE); break; case CHOICE_STRETCHTEXT: if (delta == 0) { StretchableTextModeMenu(x, y, FALSE); } else { ToggleStretchableText(); QuickSetMouseStatus(stretchableTextModeMouseStatus, stretchableText); } break; case CHOICE_TRANSPAT: if (delta == 0) { TransPatModeMenu(x, y, FALSE); } else { transPat = !transPat; ShowTransPatMode(); UpdatePinnedMenu(MENU_TRANSPAT); if (topSel != NULL) ChangeAllSelTransPat(transPat, TRUE); QuickSetMouseStatus(transPatMouseStatus, transPat); } break; case CHOICE_PRINT: if (delta == 0) { ExportFormatMenu(x, y, FALSE); } else { whereToPrint = (whereToPrint+maxWhereToPrint+delta) % maxWhereToPrint-1; ToggleWhereToPrint(); } break; case CHOICE_FILE: if (delta == 0) { PageStyleMenu(x, y, FALSE); } else { switch (pageStyle) { case PORTRAIT: ChangePageStyle(LANDSCAPE); break; case LANDSCAPE: ChangePageStyle(PORTRAIT); break; } QuickSetMouseStatus(fileMouseStatus, pageStyle); } break; case CHOICE_FILL: if (delta == 0) { FillMenu(x, y, FALSE); } else { if (curChoice == DRAWTEXT && !textCursorShown) { if (TieLooseEnds()) { SetCurChoice(NOTHING); HighLightReverse(); } else { SetCurChoice(NOTHING); } RemoveAllSel(); } objFill = (objFill+MAXPATTERNS+delta) % MAXPATTERNS; ShowFill(); UpdatePinnedMenu(MENU_FILL); if (topSel != NULL) { ChangeAllSelFill(objFill, TRUE); } else if (curChoice == DRAWTEXT && textCursorShown) { ChangeAllSelFill(objFill, FALSE); } QuickSetMouseStatus(fillMouseStatus, 0); } break; case CHOICE_PEN: if (delta == 0) { PenMenu(x, y, FALSE); } else { if (curChoice == DRAWTEXT && !textCursorShown) { if (TieLooseEnds()) { SetCurChoice(NOTHING); HighLightReverse(); } else { SetCurChoice(NOTHING); } RemoveAllSel(); } penPat = (penPat+MAXPATTERNS+delta) % MAXPATTERNS; ShowPen(); UpdatePinnedMenu(MENU_PEN); if (topSel != NULL) { ChangeAllSelPen(penPat, TRUE); } else if (curChoice == DRAWTEXT && textCursorShown) { ChangeAllSelPen(penPat, FALSE); } QuickSetMouseStatus(penMouseStatus, 0); } break; } cycleThroughChoice = FALSE; } return INVALID; } static void HighLightModeThreeDButton(mode, highlight) int mode, highlight; { struct BBRec bbox; if (!threeDLook) return; bbox.ltx = (windowPadding>>1); bbox.lty = (windowPadding>>1)+mode*(choiceImageH+(windowPadding<<1)); bbox.rbx = bbox.ltx+choiceImageW+(windowPadding<<1); bbox.rby = bbox.lty+choiceImageH+(windowPadding<<1); if (highlight) { TgDrawThreeDButton(mainDisplay, modeWindow, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); } else if (mode == curChoice) { TgDrawThreeDButton(mainDisplay, modeWindow, textMenuGC, &bbox, TGBS_LOWRED, 2, FALSE); } else { TgClearThreeDButton(mainDisplay, modeWindow, textMenuGC, &bbox, 2); } } void RedrawModeWindow() { int i, x=(windowPadding>>1), y=(windowPadding>>1); XGCValues values; XClearWindow(mainDisplay, modeWindow); for (i=0; i < MAXCHOICES; i++) { Pixmap bitmap=((i==DRAWPOLY && connectingPortsByWire) ? wireBitmap : choicePixmap[i]); if (threeDLook) { values.stipple = bitmap; values.ts_x_origin = x+windowPadding; values.ts_y_origin = y+windowPadding; XChangeGC(mainDisplay, rasterGC, GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, modeWindow, rasterGC, values.ts_x_origin, values.ts_y_origin, choiceImageW, choiceImageH); XSetTSOrigin(mainDisplay, rasterGC, 0, 0); if (i == curChoice) { struct BBRec bbox; SetBBRec(&bbox, x, y, x+choiceImageW+(windowPadding<<1), y+choiceImageH+(windowPadding<<1)); TgDrawThreeDButton(mainDisplay, modeWindow, textMenuGC, &bbox, TGBS_LOWRED, 2, FALSE); } } else { if (i == curChoice) { XSetForeground(mainDisplay, textMenuGC, myFgPixel); XFillRectangle(mainDisplay, modeWindow, textMenuGC, x+windowPadding, y+windowPadding, choiceImageW, choiceImageH); XSetStipple(mainDisplay, rvPixmapMenuGC, bitmap); XFillRectangle(mainDisplay, modeWindow, rvPixmapMenuGC, x+windowPadding, y+windowPadding, choiceImageW, choiceImageH); } else { XSetStipple(mainDisplay, rasterGC, bitmap); XFillRectangle(mainDisplay, modeWindow, rasterGC, x+windowPadding, y+windowPadding, choiceImageW, choiceImageH); } } y += choiceImageH+(windowPadding<<1); } if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, modeWindowW, modeWindowH); TgDrawThreeDButton(mainDisplay, modeWindow, textMenuGC, &bbox, TGBS_RAISED, 1, FALSE); } } int ModeEventHandler(input) XEvent *input; { XEvent ev; int mode=INVALID; if (noModeWindow) return INVALID; if (input->type == Expose) { XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, modeWindow, ExposureMask, &ev)) ; RedrawModeWindow(); } else if (input->type == EnterNotify || input->type == LeaveNotify) { if (input->type == EnterNotify) { SetStringStatus(""); } else { SetMouseStatus("", "", ""); } if (curRaisedMode != INVALID) { HighLightModeThreeDButton(curRaisedMode, FALSE); curRaisedMode = INVALID; } } else if (input->type == MotionNotify) { mode = (int)((input->xmotion.y-(windowPadding>>1)) / (choiceImageH+(windowPadding<<1))); if (threeDLook) { if (mode != curRaisedMode) { if (curRaisedMode != INVALID) { HighLightModeThreeDButton(curRaisedMode, FALSE); curRaisedMode = INVALID; } if (mode >= 0 && mode < MAXCHOICES) { HighLightModeThreeDButton(mode, TRUE); curRaisedMode = mode; } } } if (mode >=0 && mode < MAXCHOICES) { TgMenuItemInfo *menu_iteminfos=modeMenuInfo.items; if (mode == ROTATEMODE) { QuickSetMouseStatus(autoRotatePivotMouseStatus, 0); } else { /* the raw status_str is English */ SetStringStatus(_(menu_iteminfos[mode].status_str)); } } else { SetStringStatus(""); } } else if (input->type == ButtonPress) { XButtonEvent *button_ev=(&(input->xbutton)); mode = (int)((input->xbutton.y-(windowPadding>>1)) / (choiceImageH+(windowPadding<<1))); if (mode >=0 && mode < MAXCHOICES) { if (button_ev->button == Button2 && mode == ROTATEMODE) { int x=0, y=0, root_x=0, root_y=0; Window root_win=None, child_win=None; unsigned int status=0; XQueryPointer(mainDisplay, rootWindow, &root_win, &child_win, &root_x, &root_y, &x, &y, &status); AutoRotatePivotMenu(x, y, FALSE); } else { TgMenuItemInfo *menu_iteminfos=modeMenuInfo.items; SetCurChoice(mode); /* the raw status_str is English */ SetStringStatus(_(menu_iteminfos[mode].status_str)); } } else if (button_ev->button == Button2 && mode >= MAXCHOICES) { return MainMenu(); } } return INVALID; } tgif-QPL-4.2.5/tgtwb5dl.e0000644000076400007640000000530111602233313014666 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgtwb5dl.e,v 1.9 2011/05/16 16:22:00 william Exp $ */ #ifndef _TGTWB5DL_E_ #define _TGTWB5DL_E_ #include "tidget.h" #define DEFAULT_CHAR_SIZE 16 #define CHINESE_ROWS 10 #define CHINESE_COLS 20 #define SPELL_CHINESE 0 #define SPELL_ENGLISH 1 #define ID_ZYFH_DIALOG 101 #define ID_ZYFH_DPY 102 #define ID_ZYFH_KEYPAD 103 #define ID_ZYFH_EDIT 104 #define ID_ZYFH_BMPLIST 105 #define ID_ZYFH_BTN_FETCH 106 #define ID_ZYFH_BTN_SEND 107 #define ID_ZYFH_BTN_CR 108 #define ID_ZYFH_BTN_CLOSE 109 #define GB_ENCODING 0 #define BIG5_ENCODING 1 typedef struct tagZyfhInfo { int initialized; int mapped; char *b5_font_name; char im_name[40]; int b5_font_real_encoding; /* INVALID, GB_ENCODING, or BIG5_ENCODING */ int b5_font_mod_bytes; XFontStruct *xfs; int b5_font_w, b5_font_h, b5_font_asc, b5_font_des; int zyfh_num_cols /* 13 */, zyfh_num_rows /* 4 */; int zyfh_max_symbols /* 13*4 */; int zyfh_bitmap_w /* 13*16 */, zyfh_bitmap_h /* 4*16 */; int zyfh_image_wh; Pixmap zyfh_bitmap; /* the zhu-yin-fu-hao keypad */ Pixmap symbol_bitmap; /* a 16x16 bitmap for the zyfh_dpy_ctl */ TidgetInfo *dialogbox_tidgetinfo; } ZyfhInfo; extern ZyfhInfo gZyfhInfo; #ifdef _INCLUDE_FROM_TGTWB5DL_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TGTWB5DL_C_*/ extern void ShowTdgtb5DialogBox ARGS_DECL((void)); extern void HideTdgtb5DialogBox ARGS_DECL((void)); extern TidgetInfo *CreateTdgtb5DialogBox ARGS_DECL((Display*, Window)); extern void DestroyTdgtb5DialogBox ARGS_DECL((Display*, TidgetInfo*)); extern int Tdgtb5DlgLoop ARGS_DECL((TidgetInfo*)); extern int InitTdgtb5Dlg ARGS_DECL((void)); extern void CleanUpTdgtb5Dlg ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TGTWB5DL_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TGTWB5DL_C_*/ #endif /*_TGTWB5DL_E_*/ tgif-QPL-4.2.5/Tgif.tmpl0000644000076400007640000000601611602233313014557 0ustar williamwilliamXCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl,v 1.23 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif XCOMM ----------------------------------------------- XCOMM For Red Hat Linux 7.2 and above, /usr/bin/xpmtoppm does not XCOMM know how to handle XPM format version 1. Please XCOMM add -D_XPM3TOPPM to the last MOREDEFINES below. XCOMM ----------------------------------------------- PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif XCOMM MOREDEFINES = -D_HAS_STREAMS_SUPPORT -DENABLE_NLS -D_TGIF_DBG LOCALEDIR = /usr/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -DDEFATTRGROUP=\"TANGRAM-II:Declaration:Events:Messages:Rewards:Initialization:Watches\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -DUSE_XT_INITIALIZE -DPTHREAD MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) $(DEPXTOOLLIB) $(DEPXMULIB) LOCAL_LIBRARIES = $(XLIB) $(XTOOLLIB) $(XMULIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) SYS_LIBRARIES = -ldl -lm -lz -lpthread -lidn XCOMM SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM Linux 2.0.35 XCOMM XCOMM Linux 2.4.18-14 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM tgif-QPL-4.2.5/tangram2.e0000644000076400007640000000676511602233313014664 0ustar williamwilliam/* * Author: Daniel Ratton Figueiredo * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tangram2.e,v 1.9 2011/05/16 16:21:59 william Exp $ */ #ifndef _TGIF_TANGRAM2_E_ #define _TGIF_TANGRAM2_E_ #define CMDID_TANGRAM2_BASE 0x4000 #define CMDID_ABOUT_TANGRAM2 (CMDID_TANGRAM2_BASE+0) #define CMDID_TANGRAM2_GENERATE_CHAIN (CMDID_TANGRAM2_BASE+1) #define CMDID_TANGRAM2_START_SIMULATOR (CMDID_TANGRAM2_BASE+2) #define CMDID_TANGRAM2_SIMULATION_STEP (CMDID_TANGRAM2_BASE+3) #define CMDID_TANGRAM2_END_SIMULATOR (CMDID_TANGRAM2_BASE+4) #define MAXTANGRAM2CMDIDS (CMDID_ABOUT_TANGRAM2+5) extern char cmdLineGenParser[MAXSTRING]; extern TgMenuInfo tangram2MenuInfo; #ifdef _INCLUDE_FROM_TANGRAM2_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TANGRAM2_C_*/ /* ======================= Init & CleanUp ======================= */ extern void CleanUpTangram2 ARGS_DECL((void)); extern int InitTangram2 ARGS_DECL((void)); /* ======================= Tangram2 Shortcuts ======================= */ extern void CleanUpTangram2ShortCut ARGS_DECL((void)); extern int InitTangram2ShortCut ARGS_DECL((void)); extern int ValidTangram2CmdName ARGS_DECL((char *buf, int buf_sz, int *pn_num_args)); extern int ValidTangram2CmdId ARGS_DECL((int nCmdId)); extern int DoTangram2Cmd ARGS_DECL((int nCmdId, char *args)); extern int FetchTangram2ShortCutNumArgs ARGS_DECL((int index, int *pn_num_args)); extern int DoTangram2ShortCut ARGS_DECL((int index, char *args)); /* ======================= Tangram2 Internal Commands ======================= */ extern ExecInfo *Tangram2GetExecInfo ARGS_DECL((char *func_name)); /* ======================= Tangram2 Menu ======================= */ extern int RefreshTangram2Menu ARGS_DECL((TgMenu*)); extern TgMenu *CreateTangram2Menu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int Tangram2Menu ARGS_DECL((int X, int Y, int TrackMenubar)); /* ======================= Tangram2 Menu Functions ======================= */ extern void AboutTangram2 ARGS_DECL((void)); extern void Tangram2GenerateChain ARGS_DECL((char*)); extern void Tangram2StartSimulator ARGS_DECL((char*)); extern void Tangram2SimulationStep ARGS_DECL((void)); extern void Tangram2EndSimulator ARGS_DECL((void)); /* ======================= Tangram2 Misc Functions ======================= */ extern void Tangram2UpdateInitAttr ARGS_DECL((struct ObjRec *, char*)); #ifdef _INCLUDE_FROM_TANGRAM2_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TANGRAM2_C_*/ #endif /*_TGIF_TANGRAM2_E_*/ tgif-QPL-4.2.5/dialog.e0000644000076400007640000000406611602233311014376 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/dialog.e,v 1.6 2011/05/16 16:21:57 william Exp $ */ #ifndef _DIALOG_E_ #define _DIALOG_E_ extern int doPassword; extern char gszMsgBox[2048]; extern int dialogboxUse3DBorder; #ifdef _INCLUDE_FROM_DIALOG_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_DIALOG_C_*/ extern unsigned int CornerLoop ARGS_DECL((int *OrigX, int *OrigY)); extern unsigned int DrawWindowLoop ARGS_DECL((int *X, int *Y, Cursor, int SnapToGrid)); extern unsigned int PickAPoint ARGS_DECL((int *OrigX, int *OrigY, Cursor)); extern void CalcFormatStringInBox ARGS_DECL((char *buf, XFontStruct*, int font_height, int format_box_w, int *pn_num_lines, int *pn_max_w, int *pn_max_h, char **ppsz_formated_buf)); extern int MsgBox ARGS_DECL((char *Message, char *Title, int IconAndBtns)); extern int Dialog ARGS_DECL((char *Message, char *Comment, char *ReturnStr)); #ifdef _INCLUDE_FROM_DIALOG_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_DIALOG_C_*/ #endif /*_DIALOG_E_*/ tgif-QPL-4.2.5/wb1.e0000644000076400007640000000111411602233313013621 0ustar williamwilliam/* * Author: Renato Santana, in Januray, 1996. * * (Obsoleted in tgif-4.1.9 by the TangramII group at land.ufrj.br.) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb1.e,v 1.1 2004/06/18 23:19:10 william Exp $ */ #ifdef _TGIF_WB #ifndef _WB1_E_ #define _WB1_E_ #ifdef _INCLUDE_FROM_WB1_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_WB1_C_*/ #ifdef _INCLUDE_FROM_WB1_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_WB1_C_*/ #endif /*_WB1_E_*/ #endif /* _TGIF_WB */ tgif-QPL-4.2.5/tgif.spec.in0000644000076400007640000000554311602233313015206 0ustar williamwilliam# # @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgif.spec.in,v 1.5 2010/09/09 02:28:12 william Exp $ # %define rel 1 %define prefix /usr/X11R6 %define name tgif Summary: tgif 2-D drawing package Summary(pl): tgif - pakiet do tworzenia grafiki 2D Name: %{name} Version: %{ver} Release: %{rel} License: custom (please see Copyright file in distribution) Group: X11/Applications/Graphics Group(pl): X11/Aplikacje/Grafika Source: ftp://bourbon.usc.edu/pub/tgif/%{name}-%{ver}.tar.gz URL: http://bourbon.usc.edu/tgif/ BuildRoot: /tmp/%{name}-%{version}-root Prefix: %prefix Packager: Roberto A. Oppedisano Requires: xorg-x11-fonts-ISO8859-1-75dpi Requires: ghostscript Requires: netpbm-progs Requires: zlib %description Xlib based interactive 2-D drawing facility under X11. Supports hierarchical construction of drawings and easy navigation between sets of drawings. It's also a hyper-graphics (or hyper-structured-graphics) browser on the World-Wide-Web. Please see the README file for various information including copyright notices. %prep %setup -n tgif-%{ver} %build xmkmf make %install [ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf $RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT%{prefix}/bin mkdir -p $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif mkdir -p $RPM_BUILD_ROOT%{prefix}/man/man1 install -s tgif $RPM_BUILD_ROOT%{prefix}/bin/tgif install -c -m 0444 tgif.Xdefaults $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tgificon.eps $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tgificon.obj $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tgificon.xbm $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tgificon.xpm $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tangram.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4-2x.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4-ps2epsi.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4-epstool.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4xpm.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4-lyx-ps2epsi.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4-2x-nowin-jpg.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 keys.obj $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tgif.man $RPM_BUILD_ROOT%{prefix}/man/man1/tgif.1 %clean [ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root) %doc README Copyright HISTORY %{prefix}/bin/tgif %{prefix}/lib/X11/tgif ################################################################ # Note: For RedHat 7.0 or above, use the value below. If you # # have RedHat 6.x, you should delete the .gz at the end. # ################################################################ %{prefix}/man/man1/tgif.1.gz tgif-QPL-4.2.5/tdgtbmpl.e0000644000076400007640000000561711602233313014761 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtbmpl.e,v 1.6 2011/05/16 16:21:59 william Exp $ */ #ifndef _TDGTBMPL_E_ #define _TDGTBMPL_E_ #include "tidget.h" #include "list.e" #define TDGTBMPL_DEF_H_PAD 0 #define TDGTBMPL_DEF_V_PAD 0 struct tagBmpListItemInfo; typedef void (TdgtBmpListFreeItemCallbackFunc)ARGS_DECL(( struct tagBmpListItemInfo *)); typedef struct tagBmpListItemInfo { Pixmap pixmap; int width, height, depth; void *pv_userdata; /* callback functions */ TdgtBmpListFreeItemCallbackFunc *pf_free_callback; } BmpListItemInfo; typedef struct tagTdgtBmpList { TidgetInfo *pti; Window dsp_win, scr_win; SimpleWinInfo dsp_win_info, scr_win_info; int can_select; /* if FALSE, cannot select an item */ int one_bmp_w, one_bmp_h; /* width and height of one bitmap */ int gap; /* gap between bitmaps, both horizontal and vertical */ int first_index; int marked_index; int num_cols; int num_visible_lines; CVList list; MouseOverStatusInfo mosi; /* temporary variables */ int scr_dir; /* which direction it's scrolling */ Time last_selected_index; /* for double-clicking */ Time last_clicked_time; /* for double-clicking */ } TdgtBmpList; #ifdef _INCLUDE_FROM_TDGTBMPL_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TDGTBMPL_C_*/ extern void TdgtBmpListReset ARGS_DECL((TdgtBmpList*)); extern TdgtBmpList *CreateTdgtBmpList ARGS_DECL((Window parent_win, TidgetInfo *parent_tidgetinfo, int ctl_ld, int x, int y, int h_pad, int v_pad, int bmp_w, int bmp_h, int num_cols, int num_visible_lines, int gap, int can_select, MouseOverStatusInfo *pmosi)); extern int TdgtBmpListCleanUpEntries ARGS_DECL((TdgtBmpList*)); extern int TdgtBmpListScrollToBottom ARGS_DECL((TdgtBmpList*)); extern int TdgtBmpListAddItem ARGS_DECL((TdgtBmpList*, BmpListItemInfo*)); extern int InitTdgtBmpList ARGS_DECL((void)); extern void CleanUpTdgtBmpList ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TDGTBMPL_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TDGTBMPL_C_*/ #endif /*_TDGTBMPL_E_*/ tgif-QPL-4.2.5/menu.c0000644000076400007640000036226011602233312014105 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/menu.c,v 1.17 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_MENU_C_ #include "tgifdefs.h" #include "cmdids.h" #include "align.e" #include "box.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "edit.e" #include "exec.e" #include "file.e" #include "font.e" #include "grid.e" #include "help.e" #include "imgproc.e" #include "mainloop.e" #include "mainmenu.e" #include "menu.e" #include "menuinfo.e" #include "move.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "raster.e" #include "rect.e" #include "remote.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "shape.e" #include "special.e" #include "stk.e" #include "strtbl.e" #include "tangram2.e" #include "text.e" #include "util.e" #include "version.e" #include "xbm/check.xbm" #include "xbm/submenu.xbm" int iconWindowCreated=FALSE; int iconWindowShown=FALSE; int importingIconFile=FALSE; int showVersion=FALSE; int activeMenu=INVALID; #define SEPARATOR_PADDING 1 static int separatorHeight=SEPARATOR_PADDING; GC textMenuGC=(GC)0; GC rvPixmapMenuGC=(GC)0; int menuRowsBeforeScroll=21; int menuColsBeforeScroll=27; int maxScrollableMenuWidth=0; int maxScrollableMenuHeight=0; int deleteCmdAsCut=FALSE; MenuDontSendCommandInfo gstMenuDontSendCommandInfo; static int savedZoomScale=0, savedDrawOrigX=0, savedDrawOrigY=0; static int savedZoomedIn=FALSE; static int savedDrawWinW=0, savedDrawWinH=0, savedFileModified=FALSE; static struct BBRec excludeMenubarWinBBox; static int excludeMenubarIndex=INVALID; static int gnNumMenubarItems=0; static int gnNumMainMenuItems=0; /* * gpMenubarItemInfos[i].menu_str and gpMenubarItemInfos[i].status_str * are raw English strings */ static TgMenuItemInfo *gpMenubarItemInfos=NULL; static TgMenuItemInfo *gpMainMenuItemInfos=NULL; static int gnMinimalMenubar=TRUE; static int gnAutoWrapMenubar=FALSE; static void BuildMenubarInfo() { static int nInitialized=FALSE; char *c_ptr=NULL; TgMenuItemInfo *item_info=NULL; if (nInitialized) return; nInitialized = TRUE; gnMinimalMenubar = TRUE; if (((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MinimalMenubar")) != NULL) && UtilStrICmp(c_ptr,"false") == 0) { gnMinimalMenubar = FALSE; } gnAutoWrapMenubar = FALSE; if (((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"AutoWrapMenubar")) != NULL) && UtilStrICmp(c_ptr,"true") == 0) { gnAutoWrapMenubar = TRUE; } /* menubar */ gpMenubarItemInfos = (gnMinimalMenubar ? minimalMenubarMenuInfo.items : maximalMenubarMenuInfo.items); gnNumMenubarItems = 0; for (item_info=gpMenubarItemInfos; item_info->menu_str != NULL; item_info++) { gnNumMenubarItems++; } if (!cmdLineTgrm2) { int i=0, j=0; TgMenuItemInfo *pMenubarItemInfos=(TgMenuItemInfo*)malloc( (gnNumMenubarItems+1)*sizeof(TgMenuItemInfo)); for (i=0; i <= gnNumMenubarItems; i++) { if (gpMenubarItemInfos[i].cmdid != MENU_TANGRAM2) { memcpy(&pMenubarItemInfos[j++], &gpMenubarItemInfos[i], sizeof(TgMenuItemInfo)); } } memcpy(&pMenubarItemInfos[j], &gpMenubarItemInfos[i], sizeof(TgMenuItemInfo)); gpMenubarItemInfos = pMenubarItemInfos; gnNumMenubarItems--; } /* main menu */ gpMainMenuItemInfos = mainMenuInfo.items; gnNumMainMenuItems = 0; for (item_info=gpMainMenuItemInfos; item_info->menu_str != NULL; item_info++) { gnNumMainMenuItems++; } if (!cmdLineTgrm2) { int i=0, j=0; TgMenuItemInfo *pMainMenuItemInfos=(TgMenuItemInfo*)malloc( (gnNumMainMenuItems+1)*sizeof(TgMenuItemInfo)); for (i=0; i <= gnNumMainMenuItems; i++) { if (gpMainMenuItemInfos[i].cmdid != MENU_TANGRAM2) { memcpy(&pMainMenuItemInfos[j++], &gpMainMenuItemInfos[i], sizeof(TgMenuItemInfo)); } } memcpy(&pMainMenuItemInfos[j], &gpMainMenuItemInfos[i], sizeof(TgMenuItemInfo)); gpMainMenuItemInfos = pMainMenuItemInfos; gnNumMainMenuItems--; } } static void UpdateMenubarItemInfo(x, w, h, MenuX, MenuY, TextBBox) int x, w, h, *MenuX, *MenuY; struct BBRec *TextBBox; { if (MenuX != NULL || MenuY != NULL) { int win_x, win_y, main_win_x, main_win_y; unsigned int win_w, win_h, win_brdr_w, win_d; Window root_win; ComputeMainWinXY(&main_win_x, &main_win_y); XGetGeometry(mainDisplay, menubarWindow, &root_win, &win_x, &win_y, &win_w, &win_h, &win_brdr_w, &win_d); if (MenuX != NULL) { *MenuX = main_win_x + win_x + x - 3 - ((menuFontSet==NULL && menuFontPtr==NULL) ? 0 : (menuFontWidth>>1)); if (!threeDLook) { *MenuX += 4; } } if (MenuY != NULL) { *MenuY = main_win_y+brdrW+win_y+h+(win_brdr_w<<1)-1; } } if (TextBBox != NULL) { TextBBox->ltx = x-((menuFontSet==NULL && menuFontPtr==NULL) ? 0 : (menuFontWidth>>1)); TextBBox->rbx = x+w+((menuFontSet==NULL && menuFontPtr==NULL) ? 0 : menuFontWidth); TextBBox->lty = h-((menuFontSet==NULL && menuFontPtr == NULL) ? initialMenubarWindowH : menuFontHeight); TextBBox->rby = h; } } static int WhichMenubarItem(X, Y, MenuX, MenuY, TextBBox) int X, Y, *MenuX, *MenuY; struct BBRec *TextBBox; { int i, x=0, w=0, h=0, len=0, gap=0, padding=(windowPadding>>1); int min_x=((menuFontSet==NULL && menuFontPtr==NULL) ? 2 : menuFontWidth); if (noMenubar || Y < 0 || Y >= menubarWindowH || X < min_x || X >= menubarWindowW) { return INVALID; } if (menuFontSet != NULL || menuFontPtr != NULL) { x = menuFontWidth; h = menuFontHeight; gap = (x<<1); x += padding; h += padding; for (i=0; i < gnNumMenubarItems; i++) { len = strlen(_(gpMenubarItemInfos[i].menu_str)); w = MenuTextWidth(menuFontPtr, _(gpMenubarItemInfos[i].menu_str), len); if ((!noMinWinSize || !gnMinimalMenubar || gnAutoWrapMenubar) && x+w+padding >= menubarWindowW) { if (Y < h) return INVALID; x = menuFontWidth+padding; h += menuFontHeight+padding; } if (Y < h && X < x+w+gap+padding) { if (!colorDisplay && gpMenubarItemInfos[i].cmdid == MENU_COLOR) { return INVALID; } UpdateMenubarItemInfo(x+padding, w, h, MenuX, MenuY, TextBBox); return i; } x += w+gap+padding; } } else { x = 2; h = initialMenubarWindowH; gap = defaultFontWidth+(defaultFontWidth>>1); x += padding; h += padding; for (i=0; i < gnNumMenubarItems; i++) { len = strlen(_(gpMenubarItemInfos[i].menu_str)); w = defaultFontWidth*len; if ((!noMinWinSize || !gnMinimalMenubar || gnAutoWrapMenubar) && x+w+padding >= menubarWindowW) { if (Y < h) return INVALID; x = 2+padding; h += initialMenubarWindowH+padding; } if (Y < h && X < x+w+gap+padding) { if (!colorDisplay && gpMenubarItemInfos[i].cmdid == MENU_COLOR) { return INVALID; } UpdateMenubarItemInfo(x+padding, w, h, MenuX, MenuY, TextBBox); return i; } x += w+gap+padding; } } return INVALID; } static int GetMenubarItemInfo(index, MenuX, MenuY, TextBBox) int index, *MenuX, *MenuY; struct BBRec *TextBBox; { int i, x=0, w=0, h=0, len=0, gap=0, padding=(windowPadding>>1); if (menuFontSet != NULL || menuFontPtr != NULL) { x = menuFontWidth; h = menuFontHeight; gap = (x<<1); x += padding; h += padding; for (i=0; i < gnNumMenubarItems; i++) { len = strlen(_(gpMenubarItemInfos[i].menu_str)); w = MenuTextWidth(menuFontPtr, _(gpMenubarItemInfos[i].menu_str), len); if ((!noMinWinSize || !gnMinimalMenubar || gnAutoWrapMenubar) && x+w+padding >= menubarWindowW) { x = menuFontWidth+padding; h += menuFontHeight+padding; } if (i == index) { UpdateMenubarItemInfo(x+padding, w, h, MenuX, MenuY, TextBBox); return i; } x += w+gap+padding; } } else { x = 2; h = initialMenubarWindowH; gap = defaultFontWidth+(defaultFontWidth>>1); x += padding; h += padding; for (i=0; i < gnNumMenubarItems; i++) { len = strlen(_(gpMenubarItemInfos[i].menu_str)); w = defaultFontWidth*len; if ((!noMinWinSize || !gnMinimalMenubar || gnAutoWrapMenubar) && x+w+padding >= menubarWindowW) { x = 2+padding; h += initialMenubarWindowH+padding; } if (i == index) { UpdateMenubarItemInfo(x+padding, w, h, MenuX, MenuY, TextBBox); return i; } x += w+gap+padding; } } return INVALID; } void SendCommandToSelf(nCmdId, nIndex) int nCmdId, nIndex; { XClientMessageEvent client_ev; memset(&client_ev, 0, sizeof(XClientMessageEvent)); client_ev.type = ClientMessage; client_ev.window = mainWindow; client_ev.message_type = executeCmdByIDAtom; client_ev.format = 16; client_ev.data.s[0] = (short)TG_COMMAND; client_ev.data.s[1] = (short)(nCmdId & 0x0ffff); client_ev.data.s[2] = (short)(nIndex & 0x0ffff); XSendEvent(mainDisplay, mainWindow, False, NoEventMask, (XEvent*)&client_ev); } TgMenuItem *FindMenuItemByCmdId(menu, cmdid) TgMenu *menu; int cmdid; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); if ((menu_item->flags & TGMU_SEPARATOR) == 0) { if (menu_item->cmdid == cmdid) { return menu_item; } } } return NULL; } TgMenuItem *FindMenuItemByIndex(menu, index) TgMenu *menu; int index; /* skip TGMU_SEPARATOR */ { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); if ((menu_item->flags & TGMU_SEPARATOR) == 0) { if (i == index) { return menu_item; } } } return NULL; } TgMenuItem *FindMenuItemBySubMenuInfoPtr(menu, submenu_info) TgMenu *menu; TgMenuInfo *submenu_info; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); if ((menu_item->flags & TGMU_HAS_SUBMENU) == TGMU_HAS_SUBMENU) { TgMenuItemInfo *create_info=menu_item->submenu_create_info; if (create_info->submenu_info == submenu_info) { return menu_item; } } } return NULL; } static int TgSetMenuItemCheckOrRadioById(menu, cmdid, checked, mask) TgMenu *menu; int cmdid, checked, mask; { TgMenuItem stMenuItem; TgMenuItem *menu_item=NULL; if (menu == NULL) return FALSE; if ((menu_item=FindMenuItemByCmdId(menu, cmdid)) == NULL) { return FALSE; } memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = checked; if (!TgSetMenuItemInfo(menu_item, mask, &stMenuItem)) { return FALSE; } return TRUE; } int TgSetMenuItemCheckById(menu, cmdid, checked) TgMenu *menu; int cmdid, checked; { return TgSetMenuItemCheckOrRadioById(menu, cmdid, checked, TGMU_MASK_CHECK); } int TgSetMenuItemRadioById(menu, cmdid, checked) TgMenu *menu; int cmdid, checked; { return TgSetMenuItemCheckOrRadioById(menu, cmdid, checked, TGMU_MASK_RADIO); } int TgIsMenuItemChecked(menu, index) TgMenu *menu; int index; { TgMenuItem *menuitems=menu->menuitems; if (index >= 0 && index < menu->num_items) { int flags=(menuitems[index].flags); return (menuitems[index].checked && (flags & TGMU_HAS_CHECK) == TGMU_HAS_CHECK); } return FALSE; } int TgIsMenuItemRadio(menu, index) TgMenu *menu; int index; { TgMenuItem *menuitems=menu->menuitems; if (index >= 0 && index < menu->num_items) { int flags=(menuitems[index].flags); return (menuitems[index].checked && (flags & TGMU_HAS_RADIO) == TGMU_HAS_RADIO); } return FALSE; } int TgIsMenuItemEnabled(menu, index) TgMenu *menu; int index; { TgMenuItem *menuitems=menu->menuitems; if (index >= 0 && index < menu->num_items) { int flags=(menuitems[index].flags); return ((flags & TGMU_DISABLED) != TGMU_DISABLED); } return FALSE; } int TgEnableMenuItemById(menu, cmdid, enabled) TgMenu *menu; int cmdid, enabled; { TgMenuItem *menu_item=NULL; if (menu == NULL) return FALSE; if ((menu_item=FindMenuItemByCmdId(menu, cmdid)) == NULL) { return FALSE; } if (enabled) { menu_item->flags &= (~TGMU_DISABLED); } else { menu_item->flags |= TGMU_DISABLED; } return TRUE; } int TgEnableMenuItemByIndex(menu, index, enabled) TgMenu *menu; int index, enabled; { TgMenuItem *menu_item=NULL; if (menu == NULL) return FALSE; if ((menu_item=FindMenuItemByIndex(menu, index)) == NULL) { return FALSE; } if (enabled) { menu_item->flags &= (~TGMU_DISABLED); } else { menu_item->flags |= TGMU_DISABLED; } return TRUE; } int TgEnableMenuItemBySubMenuInfoPtr(menu, submenu_info, enabled) TgMenu *menu; TgMenuInfo *submenu_info; int enabled; { TgMenuItem *menu_item=NULL; if (menu == NULL) return FALSE; if ((menu_item=FindMenuItemBySubMenuInfoPtr(menu, submenu_info)) == NULL) { return FALSE; } if (enabled) { menu_item->flags &= (~TGMU_DISABLED); } else { menu_item->flags |= TGMU_DISABLED; } return TRUE; } void TgClearThreeDButton(dpy, win, gc, bbox, linewidth) Display *dpy; Window win; GC gc; struct BBRec *bbox; int linewidth; { int x=bbox->ltx, y=bbox->lty, w=bbox->rbx-bbox->ltx, h=bbox->rby-bbox->lty; XSetForeground(dpy, gc, myLtGryPixel); if (linewidth == 1) { XDrawLine(dpy, win, gc, x, y+h-1, x+w-1, y+h-1); XDrawLine(dpy, win, gc, x+w-1, y+h-1, x+w-1, y); XDrawLine(dpy, win, gc, x, y+h-2, x, y); XDrawLine(dpy, win, gc, x, y, x+w-2, y); } else if (linewidth >= 2) { XDrawLine(dpy, win, gc, x, y+h-1, x+w-1, y+h-1); XDrawLine(dpy, win, gc, x+w-1, y+h-1, x+w-1, y); XDrawLine(dpy, win, gc, x+1, y+h-2, x+w-2, y+h-2); XDrawLine(dpy, win, gc, x+w-2, y+h-2, x+w-2, y+1); XDrawLine(dpy, win, gc, x+1, y+h-3, x+1, y+1); XDrawLine(dpy, win, gc, x+1, y+1, x+w-3, y+1); XDrawLine(dpy, win, gc, x, y+h-2, x, y); XDrawLine(dpy, win, gc, x, y, x+w-2, y); } } void TgDrawThreeDButton(dpy, win, gc, bbox, state, linewidth, button) Display *dpy; Window win; GC gc; struct BBRec *bbox; int state, linewidth, button; /* button is TRUE if the item is a button */ { int x=bbox->ltx, y=bbox->lty, w=bbox->rbx-bbox->ltx, h=bbox->rby-bbox->lty; int pixels[4]; memset(pixels, 0, 4*sizeof(int)); switch (state) { case TGBS_NORMAL: return; case TGBS_RAISED: if (linewidth == 1) { pixels[0] = myDkGryPixel; /* inner lower right */ pixels[1] = myBlackPixel; /* outer lower right */ pixels[2] = myLtGryPixel; /* inner upper left */ pixels[3] = myWhitePixel; /* outer upper left */ } else { pixels[0] = myBlackPixel; /* outer lower right */ pixels[1] = myDkGryPixel; /* inner lower right */ if (button) { pixels[2] = myLtGryPixel; /* inner upper left */ pixels[3] = myWhitePixel; /* outer upper left */ } else { pixels[2] = myWhitePixel; /* inner upper left */ pixels[3] = myLtGryPixel; /* outer upper left */ } } break; case TGBS_LOWRED: if (linewidth == 1) { if (button) { pixels[0] = myDkGryPixel; /* outer lower right */ pixels[1] = myBlackPixel; /* inner lower right */ /* useless here */ pixels[2] = myWhitePixel; /* inner upper left */ /* useless here */ pixels[3] = myLtGryPixel; /* outer upper left */ } else { pixels[0] = myWhitePixel; /* outer lower right */ pixels[1] = myLtGryPixel; /* inner lower right */ /* useless here */ pixels[2] = myBlackPixel; /* inner upper left */ /* useless here */ pixels[3] = myDkGryPixel; /* outer upper left */ } } else { if (button) { pixels[0] = myLtGryPixel; /* outer lower right */ pixels[1] = myWhitePixel; /* inner lower right */ pixels[2] = myDkGryPixel; /* inner upper left */ pixels[3] = myBlackPixel; /* outer upper left */ } else { pixels[0] = myWhitePixel; /* outer lower right */ pixels[1] = myLtGryPixel; /* inner lower right */ pixels[2] = myBlackPixel; /* inner upper left */ pixels[3] = myDkGryPixel; /* outer upper left */ } } break; case TGBS_GRAYED: return; } if (linewidth == 1) { XSetForeground(dpy, gc, pixels[0]); XDrawLine(dpy, win, gc, x, y+h-1, x+w-1, y+h-1); XDrawLine(dpy, win, gc, x+w-1, y+h-1, x+w-1, y); XSetForeground(dpy, gc, pixels[3]); XDrawLine(dpy, win, gc, x, y+h-2, x, y); XDrawLine(dpy, win, gc, x, y, x+w-2, y); } else if (linewidth >= 2) { XSetForeground(dpy, gc, pixels[0]); XDrawLine(dpy, win, gc, x, y+h-1, x+w-1, y+h-1); XDrawLine(dpy, win, gc, x+w-1, y+h-1, x+w-1, y); XSetForeground(dpy, gc, pixels[1]); XDrawLine(dpy, win, gc, x+1, y+h-2, x+w-2, y+h-2); XDrawLine(dpy, win, gc, x+w-2, y+h-2, x+w-2, y+1); XSetForeground(dpy, gc, pixels[2]); XDrawLine(dpy, win, gc, x+1, y+h-3, x+1, y+1); XDrawLine(dpy, win, gc, x+1, y+1, x+w-3, y+1); XSetForeground(dpy, gc, pixels[3]); XDrawLine(dpy, win, gc, x, y+h-2, x, y); XDrawLine(dpy, win, gc, x, y, x+w-2, y); } } void TgDrawStipple(dpy, win, gc, stipple, x, y, w, h, fg_pixel, bg_pixel, fill_style) Display *dpy; Window win; GC gc; Pixmap stipple; int x, y, w, h, fg_pixel, bg_pixel, fill_style; { XGCValues values; values.foreground = fg_pixel; values.background = bg_pixel; values.fill_style = fill_style; values.stipple = stipple; values.ts_x_origin = x; values.ts_y_origin = y; XChangeGC(dpy, gc, GCForeground | GCBackground | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(dpy, win, gc, values.ts_x_origin, values.ts_y_origin, w, h); values.fill_style = FillSolid; values.ts_x_origin = 0; values.ts_y_origin = 0; XChangeGC(dpy, gc, GCFillStyle | GCTileStipXOrigin | GCTileStipYOrigin, &values); } void TgDraw2DGrayedPixmap(dpy, win, bitmap, x, y, w, h, fg_pixel, bg_pixel) Display *dpy; Window win; Pixmap bitmap; int x, y, w, h, fg_pixel, bg_pixel; { XGCValues values; GC gc=NULL; if (threeDLook) { /* not meant for threeDLook */ return; } values.foreground = fg_pixel; values.background = bg_pixel; values.function = GXcopy; values.fill_style = FillStippled; values.stipple = patPixmap[SCROLLPAT]; values.ts_x_origin = x; values.ts_y_origin = y; values.clip_mask = bitmap; values.clip_x_origin = x; values.clip_y_origin = y; gc = XCreateGC(dpy, win, GCForeground | GCBackground | GCFunction | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin | GCClipMask | GCClipXOrigin | GCClipYOrigin, &values); if (gc != NULL) { XFillRectangle(dpy, win, gc, x, y, w, h); XFreeGC(mainDisplay, gc); } } static struct BBRec gstMenubarWinBBox; static void SetMenubarWinBBox() { unsigned int win_w, win_h, win_brdr_w, win_d; int win_x, win_y, main_win_x, main_win_y; Window root_win=None; ComputeMainWinXY(&main_win_x, &main_win_y); XGetGeometry(mainDisplay, menubarWindow, &root_win, &win_x, &win_y, &win_w, &win_h, &win_brdr_w, &win_d); gstMenubarWinBBox.ltx = main_win_x + win_x; gstMenubarWinBBox.lty = main_win_y + win_y; gstMenubarWinBBox.rbx = gstMenubarWinBBox.ltx + win_w; gstMenubarWinBBox.rby = gstMenubarWinBBox.lty + win_h; } static void SetParentMenuWinBBox(menu) TgMenu *menu; { memcpy(&gstMenubarWinBBox, &menu->parent_menu->bbox, sizeof(struct BBRec)); } static void AdjMenuGeometry(menu, pn_orig_x, pn_orig_y, pn_min_pin, pn_max_pin) TgMenu *menu; int *pn_orig_x, *pn_orig_y, *pn_min_pin, *pn_max_pin; { int dsp_w=DisplayWidth(mainDisplay, mainScreen); int dsp_h=DisplayHeight(mainDisplay, mainScreen); int orig_x=menu->bbox.ltx, orig_y=menu->bbox.lty; int menu_w=menu->bbox.rbx-orig_x+((menu->padding)<<1); int menu_h=menu->bbox.rby-orig_y+((menu->padding)<<1); int min_pin=0, max_pin=0, dx=0, dy=0; TgMenu *parent_menu=menu->parent_menu; if (menu->scroll_start > 0) { switch (menu->type) { case TGMUTYPE_TEXT: menu_w += scrollBarW + menu->padding; menu_h = maxScrollableMenuHeight; break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: menu_w = maxScrollableMenuWidth; menu_h += scrollBarW + menu->padding; break; } } if (orig_x+menu_w >= dsp_w-1-((menu->brdr_w)<<1)) { orig_x = dsp_w - 1 - menu_w + ((menu->padding)<<1); if (parent_menu != NULL) { orig_x = parent_menu->bbox.ltx - 1 - menu_w + ((menu->padding)<<1); } } if (orig_y+menu_h >= dsp_h-1-((menu->brdr_w)<<1)) { orig_y = dsp_h - 1 - menu_h + ((menu->padding)<<1); } if (parent_menu != NULL) { if (orig_x < parent_menu->bbox.ltx-((menu->brdr_w)<<1)) { min_pin = orig_x - mainMenuPinDistance; } else { min_pin = parent_menu->bbox.ltx - ((menu->brdr_w)<<1) - mainMenuPinDistance; } if (orig_x+menu_w+((menu->brdr_w)<<2) >= parent_menu->bbox.rbx+((menu->brdr_w)<<1)) { max_pin = orig_x + menu_w + ((menu->brdr_w)<<2) + mainMenuPinDistance; } else { max_pin = parent_menu->bbox.rbx + ((menu->brdr_w)<<1) + mainMenuPinDistance; } } else { min_pin = orig_x - mainMenuPinDistance; max_pin = orig_x + menu_w + ((menu->brdr_w)<<2) + mainMenuPinDistance; } dx = orig_x - menu->bbox.ltx; dy = orig_y - menu->bbox.lty; menu->bbox.ltx += dx; menu->bbox.lty += dy; menu->bbox.rbx += dx; menu->bbox.rby += dy; *pn_orig_x = orig_x; *pn_orig_y = orig_y; *pn_min_pin = min_pin; *pn_max_pin = max_pin; } static void TgDrawTextMenuItem(menu, menu_item) TgMenu *menu; TgMenuItem *menu_item; { int x=0, baseline=0, y_offset=0; int item_w=(menu_item->bbox.rbx-menu_item->bbox.ltx); int item_h=(menu_item->bbox.rby-menu_item->bbox.lty); int flags=menu_item->flags; /* TGMU_* */ int state=menu_item->state; /* TGBS* */ int checked=menu_item->checked; int multicolor=((flags & TGMU_MULTICOLOR)==TGMU_MULTICOLOR); int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); int fg_pixels[4], bg_pixels[4]; XGCValues values; memset(fg_pixels, 0, 4*sizeof(int)); memset(bg_pixels, 0, 4*sizeof(int)); if (menu->scroll_start > 0 && menu->first_index > 0) { y_offset = (menu->first_index * (((menuFontSet==NULL && menuFontPtr == NULL) ? initialMenubarWindowH : menuFontHeight) + 1)); } if (multicolor) { fg_pixels[TGBS_NORMAL] = menu_item->multicolor_pixel; bg_pixels[TGBS_NORMAL] = bg_pixel; fg_pixels[TGBS_GRAYED] = myDkGryPixel; bg_pixels[TGBS_GRAYED] = bg_pixel; /* use reversed video */ fg_pixels[TGBS_RAISED] = myBgPixel; bg_pixels[TGBS_RAISED] = menu_item->multicolor_pixel; } else { fg_pixels[TGBS_NORMAL] = myFgPixel; bg_pixels[TGBS_NORMAL] = bg_pixel; fg_pixels[TGBS_GRAYED] = myDkGryPixel; bg_pixels[TGBS_GRAYED] = bg_pixel; /* use reversed video */ fg_pixels[TGBS_RAISED] = myBgPixel; bg_pixels[TGBS_RAISED] = myFgPixel; } if (flags & TGMU_DISABLED) state = TGBS_GRAYED; switch (state) { case TGBS_NORMAL: /* not selected */ case TGBS_GRAYED: /* disabled */ case TGBS_RAISED: /* selected */ break; case TGBS_LOWRED: /* not valid for a text menu item state */ return; } XSetForeground(mainDisplay, textMenuGC, bg_pixels[state]); XFillRectangle(mainDisplay, menu->window, textMenuGC, menu_item->bbox.ltx, menu_item->bbox.lty-y_offset, item_w+WINDOW_PADDING-windowPadding, item_h+(threeDLook?0:1)); if ((flags & TGMU_SEPARATOR) == TGMU_SEPARATOR) { if (threeDLook) { XSetForeground(mainDisplay, textMenuGC, myDkGryPixel); XDrawLine(mainDisplay, menu->window, textMenuGC, menu_item->bbox.ltx, menu_item->bbox.lty-y_offset, item_w, menu_item->bbox.lty-y_offset); XSetForeground(mainDisplay, textMenuGC, myWhitePixel); XDrawLine(mainDisplay, menu->window, textMenuGC, menu_item->bbox.ltx, menu_item->bbox.lty+1-y_offset, item_w, menu_item->bbox.lty+1-y_offset); } else { XSetForeground(mainDisplay, textMenuGC, myFgPixel); XDrawLine(mainDisplay, menu->window, textMenuGC, menu_item->bbox.ltx, menu_item->bbox.lty+1-y_offset, item_w+1, menu_item->bbox.lty+1-y_offset); } return; } baseline = menu_item->bbox.lty - y_offset + ((menuFontSet==NULL && menuFontPtr==NULL) ? defaultFontAsc : menuFontAsc); x = menu->check_start; if ((flags & (TGMU_HAS_CHECK|TGMU_HAS_RADIO)) != 0 && checked) { int dy=((item_h-check_height)>>1); values.foreground = fg_pixels[state]; values.background = bg_pixels[state]; values.fill_style = FillStippled; values.stipple = None; if ((flags & TGMU_HAS_CHECK) == TGMU_HAS_CHECK) { values.stipple = checkBitmap; } else if ((flags & TGMU_HAS_RADIO) == TGMU_HAS_RADIO) { values.stipple = radioBitmap; } if (values.stipple != None) { values.ts_x_origin = x; values.ts_y_origin = menu_item->bbox.lty+dy-y_offset; XChangeGC(mainDisplay, textMenuGC, GCForeground | GCBackground | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, menu->window, textMenuGC, values.ts_x_origin, values.ts_y_origin, check_width, check_height); values.fill_style = FillSolid; values.ts_x_origin = 0; values.ts_y_origin = 0; XChangeGC(mainDisplay, textMenuGC, GCFillStyle | GCTileStipXOrigin | GCTileStipYOrigin, &values); } } x = menu->str_start; if (threeDLook) { if (state == TGBS_GRAYED) { XSetForeground(mainDisplay, textMenuGC, myWhitePixel); DrawMenuString(mainDisplay, menu->window, textMenuGC, x+1, baseline+1, _(menu_item->menu_str), strlen(_(menu_item->menu_str))); } XSetForeground(mainDisplay, textMenuGC, fg_pixels[state]); DrawMenuString(mainDisplay, menu->window, textMenuGC, x, baseline, _(menu_item->menu_str), strlen(_(menu_item->menu_str))); } else { if (state == TGBS_GRAYED) { DrawMenuString(mainDisplay, menu->window, revGrayGC, x, baseline, _(menu_item->menu_str), strlen(_(menu_item->menu_str))); } else { XSetForeground(mainDisplay, textMenuGC, fg_pixels[state]); DrawMenuString(mainDisplay, menu->window, textMenuGC, x, baseline, _(menu_item->menu_str), strlen(_(menu_item->menu_str))); } } if ((flags & TGMU_HAS_SHORTCUT) == TGMU_HAS_SHORTCUT) { x = menu->shortcut_start; if (state == TGBS_GRAYED) { XSetForeground(mainDisplay, textMenuGC, myWhitePixel); DrawMenuString(mainDisplay, menu->window, textMenuGC, x+1, baseline+1, menu_item->detail.shortcut_str, strlen(menu_item->detail.shortcut_str)); } XSetForeground(mainDisplay, textMenuGC, fg_pixels[state]); DrawMenuString(mainDisplay, menu->window, textMenuGC, x, baseline, menu_item->detail.shortcut_str, strlen(menu_item->detail.shortcut_str)); } if ((flags & TGMU_HAS_SUBMENU) == TGMU_HAS_SUBMENU) { int dy=((item_h-check_height)>>1); x = menu->arrow_start; values.foreground = fg_pixels[state]; values.background = bg_pixels[state]; values.fill_style = FillStippled; if (!threeDLook && state == TGBS_GRAYED) { values.stipple = graySubmenuBitmap; } else { values.stipple = submenuBitmap; } values.ts_x_origin = x; values.ts_y_origin = menu_item->bbox.lty+dy-y_offset; XChangeGC(mainDisplay, textMenuGC, GCForeground | GCBackground | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, menu->window, textMenuGC, values.ts_x_origin, values.ts_y_origin, check_width, check_height); values.fill_style = FillSolid; values.ts_x_origin = 0; values.ts_y_origin = 0; XChangeGC(mainDisplay, textMenuGC, GCFillStyle | GCTileStipXOrigin | GCTileStipYOrigin, &values); } } static void TgDrawBitmapOrColorMenuItem(menu, menu_item) TgMenu *menu; TgMenuItem *menu_item; { int item_x=menu_item->bbox.ltx, item_y=menu_item->bbox.lty, x_offset=0; int item_w=menu_item->bbox.rbx-item_x, item_h=menu_item->bbox.rby-item_y; int flags=menu_item->flags; /* TGMU_* */ int state=menu_item->state; /* TGBS* */ int checked=menu_item->checked, color_menu=(menu->type==TGMUTYPE_COLOR); int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel), color_pixel=INVALID; Pixmap bitmap=None; if (menu->scroll_start > 0 && menu->first_index > 0) { x_offset = ((menu->image_w+(windowPadding<<1)) * menu->first_index); } if (color_menu) { color_pixel = (*(int*)(menu_item->menu_str)); } else { bitmap = (*(Pixmap*)(menu_item->menu_str)); } if (state == TGBS_NORMAL && checked) state = TGBS_LOWRED; if (flags & TGMU_DISABLED) state = TGBS_GRAYED; switch (state) { case TGBS_NORMAL: /* not selected */ case TGBS_RAISED: /* selected, i.e., mouse overed */ case TGBS_LOWRED: /* checked but not selected */ case TGBS_GRAYED: /* not valid for a bitmap menu item state */ break; } XSetForeground(mainDisplay, textMenuGC, bg_pixel); XFillRectangle(mainDisplay, menu->window, textMenuGC, menu_item->bbox.ltx-x_offset, menu_item->bbox.lty, item_w, item_h); if ((flags & TGMU_SEPARATOR) == TGMU_SEPARATOR) { return; } if (threeDLook) { if (x_offset != 0) { OffsetBBox(&menu_item->bbox, -x_offset, 0, &menu_item->bbox); TgDrawThreeDButton(mainDisplay, menu->window, textMenuGC, &menu_item->bbox, state, 2, TRUE); OffsetBBox(&menu_item->bbox, +x_offset, 0, &menu_item->bbox); } else { TgDrawThreeDButton(mainDisplay, menu->window, textMenuGC, &menu_item->bbox, state, 2, TRUE); } if (color_menu) { TgDrawStipple(mainDisplay, menu->window, textMenuGC, patPixmap[SOLIDPAT], item_x+menu->padding-x_offset, item_y+menu->padding, menu->image_w, menu->image_h, color_pixel, bg_pixel, FillSolid); } else { if (state == TGBS_GRAYED) { TgDrawStipple(mainDisplay, menu->window, textMenuGC, bitmap, item_x+menu->padding-x_offset+1, item_y+menu->padding+1, menu->image_w, menu->image_h, myWhitePixel, bg_pixel, FillStippled); TgDrawStipple(mainDisplay, menu->window, textMenuGC, bitmap, item_x+menu->padding-x_offset, item_y+menu->padding, menu->image_w, menu->image_h, myDkGryPixel, bg_pixel, FillStippled); } else { TgDrawStipple(mainDisplay, menu->window, textMenuGC, bitmap, item_x+menu->padding-x_offset, item_y+menu->padding, menu->image_w, menu->image_h, myFgPixel, bg_pixel, FillStippled); } } } else if (color_menu) { XSetForeground(mainDisplay, textMenuGC, color_pixel); XFillRectangle(mainDisplay, menu->window, textMenuGC, item_x+menu->padding-x_offset, item_y+menu->padding, menu->image_w, menu->image_h); } else { if (state == TGBS_NORMAL) { XSetStipple(mainDisplay, rasterGC, bitmap); XFillRectangle(mainDisplay, menu->window, rasterGC, item_x+menu->padding-x_offset, item_y+menu->padding, menu->image_w, menu->image_h); } else if (state == TGBS_GRAYED) { TgDraw2DGrayedPixmap(mainDisplay, menu->window, bitmap, item_x+menu->padding-x_offset, item_y+menu->padding, menu->image_w, menu->image_h, myFgPixel, myBgPixel); } else { XSetForeground(mainDisplay, textMenuGC, myFgPixel); XFillRectangle(mainDisplay, menu->window, textMenuGC, item_x+menu->padding-x_offset, item_y+menu->padding, menu->image_w, menu->image_h); XSetStipple(mainDisplay, rvPixmapMenuGC, bitmap); XFillRectangle(mainDisplay, menu->window, rvPixmapMenuGC, item_x+menu->padding-x_offset, item_y+menu->padding, menu->image_w, menu->image_h); } } } void TgDrawMenuItem(menu, menu_item) TgMenu *menu; TgMenuItem *menu_item; { switch (menu->type) { case TGMUTYPE_TEXT: TgDrawTextMenuItem(menu, menu_item); break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: TgDrawBitmapOrColorMenuItem(menu, menu_item); break; } } void TgDrawEntireMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; XClearWindow(mainDisplay, menu->window); if (menu->scroll_start > 0) { int min_index=0, max_index=0; if (menu->type == TGMUTYPE_COLOR || menu->type == TGMUTYPE_BITMAP) { min_index = menu->first_index*menu->num_rows; max_index = (menu->first_index+menuColsBeforeScroll)*menu->num_rows; } for (i=0; i < num_items; i++) { switch (menu->type) { case TGMUTYPE_TEXT: if (i >= menu->first_index && i < menu->first_index+menuRowsBeforeScroll) { TgDrawMenuItem(menu, &menuitems[i]); } break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: if (i >= min_index && i < max_index) { TgDrawMenuItem(menu, &menuitems[i]); } break; } } } else { for (i=0; i < num_items; i++) { TgDrawMenuItem(menu, &menuitems[i]); } } if (threeDLook) { struct BBRec bbox; bbox.ltx = 0; bbox.lty = 0; if (menu->scroll_start > 0) { double start_frac=(double)0; switch (menu->type) { case TGMUTYPE_TEXT: start_frac = (double)((double)(menu->first_index) / (double)(num_items)); bbox.rbx = menu->scroll_start+(windowPadding<<1); bbox.rby = maxScrollableMenuHeight; TgDrawThreeDButton(mainDisplay, menu->window, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); TgDrawScrollBar(mainDisplay, menu->window, VERT_SCROLLBAR, bbox.rbx+(windowPadding>>1), (windowPadding>>1), scrollBarW, maxScrollableMenuHeight-windowPadding, start_frac, menuRowsBeforeScroll, num_items); bbox.ltx = bbox.rbx; bbox.lty = 0; bbox.rbx = bbox.ltx+scrollBarW+windowPadding; bbox.rby = maxScrollableMenuHeight; TgDrawThreeDButton(mainDisplay, menu->window, textMenuGC, &bbox, TGBS_RAISED, 1, FALSE); break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: start_frac = (double)((double)(menu->first_index) / (double)(menu->num_cols)); bbox.rbx = maxScrollableMenuWidth; bbox.rby = menu->scroll_start+(windowPadding<<1); TgDrawThreeDButton(mainDisplay, menu->window, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); TgDrawScrollBar(mainDisplay, menu->window, HORI_SCROLLBAR, (windowPadding>>1), bbox.rby+(windowPadding>>1), maxScrollableMenuWidth-windowPadding, scrollBarW, start_frac, menuColsBeforeScroll, menu->num_cols); bbox.ltx = 0; bbox.lty = bbox.rby; bbox.rbx = maxScrollableMenuWidth; bbox.rby = bbox.lty+scrollBarW+windowPadding; TgDrawThreeDButton(mainDisplay, menu->window, textMenuGC, &bbox, TGBS_LOWRED, 1, TRUE); break; } } else { bbox.rbx = menu->bbox.rbx-menu->bbox.ltx+(windowPadding<<1); bbox.rby = menu->bbox.rby-menu->bbox.lty+(windowPadding<<1); TgDrawThreeDButton(mainDisplay, menu->window, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); } } else if (menu->scroll_start > 0) { double start_frac=(double)0; switch (menu->type) { case TGMUTYPE_TEXT: start_frac = (double)((double)(menu->first_index)/(double)(num_items)); TgDrawScrollBar(mainDisplay, menu->window, VERT_SCROLLBAR, menu->scroll_start, 0, scrollBarW, maxScrollableMenuHeight, start_frac, menuRowsBeforeScroll, num_items); MyBox(menu->window, textMenuGC, menu->scroll_start, 0, menu->scroll_start+scrollBarW, maxScrollableMenuHeight); break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: start_frac = (double)((double)(menu->first_index) / (double)(menu->num_cols)); TgDrawScrollBar(mainDisplay, menu->window, HORI_SCROLLBAR, 0, menu->scroll_start, maxScrollableMenuWidth, scrollBarW, start_frac, menuColsBeforeScroll, menu->num_cols); MyBox(menu->window, textMenuGC, 0, menu->scroll_start, maxScrollableMenuWidth, menu->scroll_start+scrollBarW); break; } } } int TgWhichMenuIndex(menu, x, y, must_be_in_menu) TgMenu *menu; int x, y, must_be_in_menu; /* * Returns INVALID if clicked outside of the menu. * Returns -2 if clicked on a separator. * Returns -3 if clicked on scrollbar. * Otherwise, returned a menu index. */ { int i=0, num_items=menu->num_items; int first_index=0, max_index_plus_1=num_items, x_offset=0, y_offset=0; if (must_be_in_menu) { if (!(x >= 0 && x < menu->bbox.rbx-menu->bbox.ltx && y >= 0 && y < menu->bbox.rby-menu->bbox.lty)) { return INVALID; } } switch (menu->type) { case TGMUTYPE_TEXT: if (menu->scroll_start > 0) { if (x >= menu->scroll_start+windowPadding) { return (-3); } first_index = menu->first_index; max_index_plus_1 = menu->first_index+menuRowsBeforeScroll; if (first_index > 0) { y_offset = (first_index * (((menuFontSet==NULL && menuFontPtr == NULL) ? initialMenubarWindowH : menuFontHeight) + 1)); } } for (i=first_index; i < max_index_plus_1; i++) { TgMenuItem *menu_item=(&menu->menuitems[i]); if (y >= menu_item->bbox.lty-y_offset && y < menu_item->bbox.rby+1-y_offset) { if (menu_item->flags & TGMU_SEPARATOR) { return (-2); } return i; } } break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: if (menu->scroll_start > 0) { if (y >= menu->scroll_start+windowPadding) { return (-3); } first_index = (menu->first_index*menu->num_rows); max_index_plus_1 = (menu->first_index+menuColsBeforeScroll)*menu->num_rows; if (first_index > 0) { x_offset = ((menu->image_w+(windowPadding<<1)) * menu->first_index); } } for (i=first_index; i < num_items; i++) { TgMenuItem *menu_item=(&menu->menuitems[i]); if ((x >= menu_item->bbox.ltx-x_offset && x < menu_item->bbox.rbx+1-x_offset) && (y >= menu_item->bbox.lty && y < menu_item->bbox.rby+1)) { if (menu_item->flags & TGMU_SEPARATOR) { return (-2); } return i; } if (i+1 == max_index_plus_1) break; } break; } return INVALID; } static int gnUncheckWhenMoused=FALSE; static int TgPointInAnAncestorMenu(menu, root_x, root_y) TgMenu *menu; int root_x, root_y; { if (menu == NULL) return FALSE; if (PointInBBox(root_x, root_y, menu->bbox)) return TRUE; return TgPointInAnAncestorMenu(menu->parent_menu, root_x, root_y); } static int TgPointInParentMenuSelectedItem(parent_menu) TgMenu *parent_menu; { Window root_win=None, child_win=None; unsigned int status; int parent_root_x, parent_root_y, x=0, y=0; XQueryPointer(mainDisplay, parent_menu->window, &root_win, &child_win, &parent_root_x, &parent_root_y, &x, &y, &status); return (TgWhichMenuIndex(parent_menu, x, y, FALSE) == parent_menu->selected_index); } TgMenu *TgCreatePopUpSubMenu(menu, selected_index) TgMenu *menu; int selected_index; { TgMenu *submenu=NULL; TgMenuItem *menuitems=menu->menuitems; TgMenuItemInfo *create_info=menuitems[selected_index].submenu_create_info; if (create_info == NULL) return NULL; if (create_info->submenu_info->create_proc == TgCreateMenuFromMenuInfo) { submenu = menuitems[selected_index].detail.submenu = (create_info->submenu_info->create_proc)(menu, 0, 0, create_info->submenu_info, FALSE); } else { /* * if the creation procedure is not the default TgCreateMenuFromMenuInfo, * the status_str_xlated will be ignored */ submenu = menuitems[selected_index].detail.submenu = (create_info->submenu_info->create_proc)(menu, 0, 0, create_info->submenu_info, INVALID); } return submenu; } int TgPopUpSubMenu(menu, win_x, win_y) TgMenu *menu; int win_x, win_y; { int rc=INVALID, new_selected=menu->selected_index; TgMenuItem *menuitems=menu->menuitems; TgMenu *submenu=menuitems[new_selected].detail.submenu; int menu_w=menu->bbox.rbx-menu->bbox.ltx+((menu->padding)<<1); int i, x=0, y=0, dx=0, dy=0; int saved_active_menu=INVALID, need_to_restore_active_menu=FALSE; submenu->parent_menu = menu; submenu->disallow_pinning = ((menuitems[new_selected].flags & TGMU_SUBMENU_PINNABLE) == 0); if ((menuitems[new_selected].flags & TGMU_SUBMENU_PINNABLE) == TGMU_SUBMENU_PINNABLE && menuitems[new_selected].cmdid != INVALID) { saved_active_menu = activeMenu; activeMenu = menuitems[new_selected].cmdid; need_to_restore_active_menu = TRUE; } x = menu_w+win_x-((menu->padding)<<1); y = menuitems[new_selected].bbox.lty+win_y-menu->padding; dx = x-submenu->bbox.ltx; dy = y-submenu->bbox.lty; submenu->bbox.ltx += dx; submenu->bbox.lty += dy; submenu->bbox.rbx += dx; submenu->bbox.rby += dy; for (i=0; i < submenu->num_items; i++) { submenu->menuitems[i].state = TGBS_NORMAL; } if (submenu->refresh_proc != NULL) { (submenu->refresh_proc)(submenu); } rc = TgMenuLoop(submenu); if (need_to_restore_active_menu) { activeMenu = saved_active_menu; } return rc; } static int ScrollItemCallback(pv_userdata) void *pv_userdata; /* returns TRUE to cancel scrolling */ { TgMenu *menu=((TgMenu*)pv_userdata); int v_scroll=TRUE; switch (menu->type) { case TGMUTYPE_TEXT: v_scroll = TRUE; break; case TGMUTYPE_COLOR: v_scroll = FALSE; break; case TGMUTYPE_BITMAP: v_scroll = FALSE; break; } if (menu->can_scroll == SCRL_UP || menu->can_scroll == SCRL_LF) { /* can_scroll temporary used as scroll_dir */ if (menu->first_index == 0) return FALSE; menu->first_index--; } else if (v_scroll) { if (menu->num_items <= menuRowsBeforeScroll || menu->first_index+menuRowsBeforeScroll == menu->num_items) { return FALSE; } menu->first_index++; } else { if (menu->num_cols <= menuColsBeforeScroll || menu->first_index+menuColsBeforeScroll == menu->num_cols) { return FALSE; } menu->first_index++; } TgDrawEntireMenu(menu); XSync(mainDisplay, False); return FALSE; } static int ScrollPageCallback(pv_userdata) void *pv_userdata; /* returns TRUE to cancel scrolling */ { TgMenu *menu=((TgMenu*)pv_userdata); int v_scroll=TRUE; switch (menu->type) { case TGMUTYPE_TEXT: v_scroll = TRUE; break; case TGMUTYPE_COLOR: v_scroll = FALSE; break; case TGMUTYPE_BITMAP: v_scroll = FALSE; break; } if (menu->can_scroll == SCRL_UP || menu->can_scroll == SCRL_LF) { /* can_scroll temporary used as scroll_dir */ if (menu->first_index == 0) return FALSE; menu->first_index -= menuRowsBeforeScroll; if (menu->first_index < 0) menu->first_index = 0; } else if (v_scroll) { if (menu->num_items <= menuRowsBeforeScroll || menu->first_index+menuRowsBeforeScroll == menu->num_items) { return FALSE; } menu->first_index += menuRowsBeforeScroll; if (menu->first_index+menuRowsBeforeScroll >= menu->num_items) { menu->first_index = menu->num_items-menuRowsBeforeScroll; } } else { if (menu->num_cols <= menuColsBeforeScroll || menu->first_index+menuColsBeforeScroll == menu->num_cols) { return FALSE; } menu->first_index += menuColsBeforeScroll; if (menu->first_index+menuColsBeforeScroll >= menu->num_cols) { menu->first_index = menu->num_cols-menuColsBeforeScroll; } } TgDrawEntireMenu(menu); XSync(mainDisplay, False); return FALSE; } static int DoScrollMenu(menu, scroll_page, scroll_dir, pbbox) TgMenu *menu; int scroll_page, scroll_dir; struct BBRec *pbbox; { int v_scroll=TRUE; ScrollBtnCallbackInfo sbci; /* * temporary use can_scroll for scroll_dir * menu->can_scroll must be restored to TRUE before returning */ menu->can_scroll = scroll_dir; memset(&sbci, 0, sizeof(ScrollBtnCallbackInfo)); switch (menu->type) { case TGMUTYPE_TEXT: v_scroll = TRUE; break; case TGMUTYPE_COLOR: v_scroll = FALSE; break; case TGMUTYPE_BITMAP: v_scroll = FALSE; break; } if (scroll_page) { sbci.ms = 200; sbci.pv_userdata = menu; sbci.pf_scroll_btn_callback = ScrollPageCallback; if (TgPressButtonLoop(mainDisplay, menu->window, NULL, &sbci)) { if (scroll_dir == SCRL_UP || scroll_dir == SCRL_LF) { if (menu->first_index == 0) { menu->can_scroll = TRUE; return TRUE; } menu->first_index -= menuRowsBeforeScroll; if (menu->first_index < 0) menu->first_index = 0; } else if (v_scroll) { if (menu->num_items <= menuRowsBeforeScroll || menu->first_index+menuRowsBeforeScroll == menu->num_items) { menu->can_scroll = TRUE; return TRUE; } menu->first_index += menuRowsBeforeScroll; if (menu->first_index+menuRowsBeforeScroll >= menu->num_items) { menu->first_index = menu->num_items-menuRowsBeforeScroll; } } else { if (menu->num_cols <= menuColsBeforeScroll || menu->first_index+menuColsBeforeScroll == menu->num_cols) { menu->can_scroll = TRUE; return TRUE; } menu->first_index += menuColsBeforeScroll; if (menu->first_index+menuColsBeforeScroll >= menu->num_cols) { menu->first_index = menu->num_cols-menuColsBeforeScroll; } } } } else { sbci.ms = 50; sbci.pv_userdata = menu; sbci.pf_scroll_btn_callback = ScrollItemCallback; if (TgPressButtonLoop(mainDisplay, menu->window, pbbox, &sbci)) { if (scroll_dir == SCRL_UP || scroll_dir == SCRL_LF) { if (menu->first_index == 0) { menu->can_scroll = TRUE; return TRUE; } menu->first_index--; } else if (v_scroll) { if (menu->num_items <= menuRowsBeforeScroll || menu->first_index+menuRowsBeforeScroll == menu->num_items) { menu->can_scroll = TRUE; return TRUE; } menu->first_index++; } else { if (menu->num_cols <= menuColsBeforeScroll || menu->first_index+menuColsBeforeScroll == menu->num_cols) { menu->can_scroll = TRUE; return TRUE; } menu->first_index++; } } } menu->can_scroll = TRUE; return FALSE; } static void DoDragInScrollMenu(menu, menu_w, menu_h, mouse_x, mouse_y, btn_offset) TgMenu *menu; int menu_w, menu_h, mouse_x, mouse_y, btn_offset; { double start_frac=(double)0, frac=(double)0; int done=FALSE, block_start=0, block_h=0, block_w=0, v_scroll=TRUE; XEvent ev; switch (menu->type) { case TGMUTYPE_TEXT: v_scroll = TRUE; break; case TGMUTYPE_COLOR: v_scroll = FALSE; break; case TGMUTYPE_BITMAP: v_scroll = FALSE; break; } if (v_scroll) { if (menu->num_items <= menuRowsBeforeScroll) return; frac = (double)((double)menuRowsBeforeScroll / (double)(menu->num_items)); if (threeDLook) { block_h = (int)((menu_h-(scrollBarW<<1)) * frac); } else { block_h = (int)(menu_h * frac); } if (threeDLook) { block_start = mouse_y + btn_offset;; start_frac = (double)((double)(block_start-scrollBarW) / (double)(menu_h-(scrollBarW<<1))); if (block_start+block_h >= menu_h-scrollBarW) { menu->first_index = menu->num_items - menuRowsBeforeScroll; } else { menu->first_index = (int)(menu->num_items * start_frac); } } else { block_start = mouse_y; start_frac = (double)((double)(block_start) / (double)(menu_h)); if (block_start+block_h >= menu_h) { menu->first_index = menu->num_items - menuRowsBeforeScroll; } else { menu->first_index = (int)(menu->num_items * start_frac); } } } else { if (menu->num_cols <= menuColsBeforeScroll) return; frac = (double)((double)menuColsBeforeScroll / (double)(menu->num_cols)); if (threeDLook) { block_w = (int)((menu_w-(scrollBarW<<1)) * frac); } else { block_w = (int)(menu_w * frac); } if (threeDLook) { block_start = mouse_x + btn_offset;; start_frac = (double)((double)(block_start-scrollBarW) / (double)(menu_w-(scrollBarW<<1))); if (block_start+block_w >= menu_w-scrollBarW) { menu->first_index = menu->num_cols - menuColsBeforeScroll; } else { menu->first_index = (int)(menu->num_cols * start_frac); } } else { block_start = mouse_x; start_frac = (double)((double)(block_start) / (double)(menu_w)); if (block_start+block_w >= menu_w) { menu->first_index = menu->num_cols - menuColsBeforeScroll; } else { menu->first_index = (int)(menu->num_cols * start_frac); } } } TgDrawEntireMenu(menu); if (!(menu->parent_menu == NULL && !debugNoPointerGrab)) { XGrabPointer(mainDisplay, menu->window, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } while (!done) { XNextEvent(mainDisplay, &ev); if (ev.type == Expose || ev.type == VisibilityNotify) { ExposeEventHandler(&ev, TRUE); } else if (ev.type == ButtonRelease) { if (!(menu->parent_menu == NULL && !debugNoPointerGrab)) { XUngrabPointer(mainDisplay, CurrentTime); if (debugNoPointerGrab) XSync(mainDisplay, False); } done = TRUE; } else if (ev.type == MotionNotify) { int new_name_first=0; if (v_scroll) { int y=ev.xmotion.y; if (threeDLook) { y += btn_offset; start_frac = (double)(((double)(y-scrollBarW)) / ((double)(menu_h-(scrollBarW<<1)-block_h))); if (y <= scrollBarW) { new_name_first = 0; } else if (y+block_h >= menu_h-scrollBarW) { new_name_first = menu->num_items - menuRowsBeforeScroll; } else { new_name_first = (int)((menu->num_items-menuRowsBeforeScroll) * start_frac); } } else { start_frac = (double)(((double)y) / ((double)menu_h)); if (y <= 0) { new_name_first = 0; } else if (y+block_h >= menu_h) { new_name_first = menu->num_items - menuRowsBeforeScroll; } else { new_name_first = (int)(menu->num_items * start_frac); } } } else { int x=ev.xmotion.x; if (threeDLook) { x += btn_offset; start_frac = (double)(((double)(x-scrollBarW)) / ((double)(menu_w-(scrollBarW<<1)-block_w))); if (x <= scrollBarW) { new_name_first = 0; } else if (x+block_w >= menu_w-scrollBarW) { new_name_first = menu->num_cols - menuColsBeforeScroll; } else { new_name_first = (int)((menu->num_cols-menuColsBeforeScroll) * start_frac); } } else { start_frac = (double)(((double)x) / ((double)menu_w)); if (x <= 0) { new_name_first = 0; } else if (x+block_w >= menu_w) { new_name_first = menu->num_cols - menuColsBeforeScroll; } else { new_name_first = (int)(menu->num_cols * start_frac); } } } if (menu->first_index != new_name_first) { menu->first_index = new_name_first; TgDrawEntireMenu(menu); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } } void ScrollMenu(menu, x, y, menu_w, menu_h, button_state) TgMenu *menu; int x, y, menu_w, menu_h, button_state; { int menu_x=x, menu_y=y, x_off=0, y_off=0; int do_drag=FALSE, btn_offset=0, v_scroll=TRUE; unsigned int button=Button1; if ((button_state & Button1Mask) == Button1Mask) button = Button1; if ((button_state & Button2Mask) == Button2Mask) button = Button2; if ((button_state & Button3Mask) == Button3Mask) button = Button3; switch (menu->type) { case TGMUTYPE_TEXT: v_scroll = TRUE; break; case TGMUTYPE_COLOR: v_scroll = FALSE; break; case TGMUTYPE_BITMAP: v_scroll = FALSE; break; } if (v_scroll) { menu_x = x-menu->scroll_start-windowPadding; } else { menu_y = y-menu->scroll_start-windowPadding; } if (!threeDLook && button == Button3) { if (DoScrollMenu(menu, FALSE, (v_scroll ? SCRL_UP : SCRL_LF), NULL)) { return; } } else if (!threeDLook && button == Button1) { if (DoScrollMenu(menu, FALSE, (v_scroll ? SCRL_DN : SCRL_RT), NULL)) { return; } } else if (button == Button1) { if (v_scroll) { /* vertical scroll bar */ if (menu_y < scrollBarW || menu_y >= menu_h-scrollBarW) { int which=0; struct BBRec bbox; x_off = menu->scroll_start+(windowPadding<<1)+(windowPadding>>1); if (menu_y < scrollBarW) { y_off = (windowPadding>>1); which = SCRL_UP; SetBBRec(&bbox, x_off, y_off, x_off+scrollBarW, y_off+scrollBarW); } else { y_off = -(windowPadding>>1); which = SCRL_DN; SetBBRec(&bbox, x_off, y_off+menu_h-scrollBarW, x_off+scrollBarW, y_off+menu_h); } if (DoScrollMenu(menu, FALSE, which, &bbox)) { return; } } else { double start_frac=(double)0; int hit=0; start_frac = (menu->num_items > 0) ? (double)((double)(menu->first_index) / (double)(menu->num_items)) : ((double)0.0); hit = TgGetScrollHit(menu_x, menu_y, VERT_SCROLLBAR, scrollBarW, menu_h, start_frac, menuRowsBeforeScroll, menu->num_items, &btn_offset); if (hit == 0) { do_drag = TRUE; } else { if (DoScrollMenu(menu, TRUE, (hit<0 ? SCRL_UP : SCRL_DN), NULL)) { return; } } } } else { /* horizontal scroll bar */ if (menu_x < scrollBarW || menu_x >= menu_w-scrollBarW) { int which=0; struct BBRec bbox; y_off = menu->scroll_start+(windowPadding<<1)+(windowPadding>>1); if (menu_x < scrollBarW) { x_off = (windowPadding>>1); which = SCRL_LF; SetBBRec(&bbox, x_off, y_off, x_off+scrollBarW, y_off+scrollBarW); } else { x_off = -(windowPadding>>1); which = SCRL_RT; SetBBRec(&bbox, x_off+menu_w-scrollBarW, y_off, x_off+menu_w, y_off+scrollBarW); } if (DoScrollMenu(menu, FALSE, which, &bbox)) { return; } } else { double start_frac=(double)0; int hit=0; start_frac = (menu->num_items > 0) ? (double)((double)(menu->first_index) / (double)(menu->num_cols)) : ((double)0.0); hit = TgGetScrollHit(menu_x, menu_y, HORI_SCROLLBAR, menu_w, scrollBarW, start_frac, menuColsBeforeScroll, menu->num_cols, &btn_offset); if (hit == 0) { do_drag = TRUE; } else { if (DoScrollMenu(menu, TRUE, (hit<0 ? SCRL_LF : SCRL_RT), NULL)) { return; } } } } } else if (!threeDLook && button == Button2) { do_drag = TRUE; } if (do_drag) { DoDragInScrollMenu(menu, menu_w, menu_h, x, y, btn_offset); return; } TgDrawEntireMenu(menu); } int TgMenuLoop(menu) TgMenu *menu; { int menuing=TRUE; int orig_x=menu->bbox.ltx, orig_y=menu->bbox.lty; int menu_w=menu->bbox.rbx-orig_x+((menu->padding)<<1); int menu_h=menu->bbox.rby-orig_y+((menu->padding)<<1); int min_pin=0, max_pin=0, suspended=FALSE; TgMenuItem *menuitems=NULL; Window root_win=None, child_win=None; TgMenu *parent_menu=menu->parent_menu; int x, y, rc=INVALID, saved_root_x, saved_root_y; int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); unsigned int status; XEvent ev; XWMHints wmhints; XSizeHints sizehints; XSetWindowAttributes win_attrs; int pinned_x=0, pinned_y=0, menu_pinned=FALSE; int tmp_disallow_pinning=inSlideShow; int one_line_status=FALSE; char status_buf[MAX_STATUS_BTNS+1][MAXSTRING+1]; SaveStatusStringsIntoBuf(status_buf, &one_line_status); if (menu->scroll_start > 0) { switch (menu->type) { case TGMUTYPE_TEXT: menu_w += scrollBarW + menu->padding; menu_h = maxScrollableMenuHeight; break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: menu_w = maxScrollableMenuWidth; menu_h += scrollBarW + menu->padding; break; } } menuitems = menu->menuitems; if (menu->track_menubar && menubarWindow != None) { SetMenubarWinBBox(); } else if (menu->parent_menu != NULL && menu->track_parent_menu) { SetParentMenuWinBBox(menu); } AdjMenuGeometry(menu, &orig_x, &orig_y, &min_pin, &max_pin); if ((menu->window=XCreateSimpleWindow(mainDisplay, rootWindow, orig_x+windowPadding, orig_y+windowPadding, menu_w, menu_h, menu->brdr_w, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("TgMenuLoop()", NULL, FALSE); return rc; } win_attrs.save_under = True; win_attrs.override_redirect = True; win_attrs.colormap = mainColormap; XChangeWindowAttributes(mainDisplay, menu->window, CWSaveUnder | CWOverrideRedirect | CWColormap, &win_attrs); wmhints.flags = InputHint | StateHint; wmhints.input = True; wmhints.initial_state = NormalState; XSetWMHints(mainDisplay, menu->window, &wmhints); sizehints.flags = PPosition | PSize | USPosition | PMinSize | PMaxSize; sizehints.x = orig_x+windowPadding; sizehints.y = orig_y+windowPadding; sizehints.width = sizehints.min_width = sizehints.max_width = menu_w; sizehints.height = sizehints.min_height = sizehints.max_height = menu_h; #ifdef NOTR4MODE XSetNormalHints(mainDisplay, menu->window, &sizehints); #else XSetWMNormalHints(mainDisplay, menu->window, &sizehints); #endif menu->selected_index = INVALID; RegisterWM_DELETE_WINDOW(menu->window); XSetTransientForHint(mainDisplay, menu->window, mainWindow); #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, menu->window); XSelectInput(mainDisplay, menu->window, StructureNotifyMask | ExposureMask | KeyPressMask | ButtonPressMask | ButtonReleaseMask | PointerMotionMask | EnterWindowMask | LeaveWindowMask); #else XSelectInput(mainDisplay, menu->window, StructureNotifyMask | ExposureMask | KeyPressMask | ButtonPressMask | ButtonReleaseMask | PointerMotionMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, menu->window); #endif if (menu->parent_menu == NULL && !(menu->track_menubar && menubarWindow != None) && !menu->track_parent_menu) { XWarpPointer(mainDisplay,None,rootWindow,0,0,0,0,orig_x-2,orig_y-2); } XQueryPointer(mainDisplay, menu->window, &root_win, &child_win, &saved_root_x, &saved_root_y, &x, &y, &status); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, menu->window, FALSE, PointerMotionMask | ButtonPressMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } while (menuing) { int root_x, root_y, any_button_down; XNextEvent(mainDisplay, &ev); if (ev.type == Expose || ev.type == VisibilityNotify) { if (ev.xany.window == menu->window) { TgDrawEntireMenu(menu); } else { ExposeEventHandler(&ev, FALSE); } } if (!debugNoPointerGrab && (ev.type == ButtonPress || ev.type == ButtonRelease)) { XButtonEvent *button_ev=(&(ev.xbutton)); XQueryPointer(mainDisplay, menu->window, &root_win, &child_win, &root_x, &root_y, &x, &y, &status); x = button_ev->x; y = button_ev->y; if (ev.type == ButtonPress) { switch (button_ev->button) { case Button1: status = Button1Mask; break; case Button2: status = Button2Mask; break; case Button3: status = Button3Mask; break; } } } else { XQueryPointer(mainDisplay, menu->window, &root_win, &child_win, &root_x, &root_y, &x, &y, &status); } any_button_down = ((status & BUTTONSMASK) != 0); if (suspended) { if (!any_button_down) { continue; } suspended = FALSE; tmp_disallow_pinning = TRUE; } if (!any_button_down) { if (!menu_pinned && abs(root_x-saved_root_x)<=2 && abs(root_y-saved_root_y)<=2) { suspended = TRUE; continue; } else if (menu->parent_menu != NULL && PointInBBox(root_x, root_y, menu->parent_menu->bbox) && TgPointInParentMenuSelectedItem(menu->parent_menu)) { suspended = TRUE; continue; } if (menu_pinned) { XDrawRectangle(mainDisplay, rootWindow, revDefaultGC, pinned_x, pinned_y, menu_w+(brdrW<<1), menu_h+(brdrW<<1)); XSetSubwindowMode(mainDisplay, revDefaultGC, ClipByChildren); pinned_x = root_x; pinned_y = root_y; TgRealizePinnedMenuWindow(menu, pinned_x, pinned_y, menu_w+(brdrW<<1), menu_h+(brdrW<<1)); rc = INVALID; } else if (x >= 0 && x < menu_w && y >= 0 && y < menu_h) { rc = TgWhichMenuIndex(menu, x, y, FALSE); switch (rc) { case INVALID: break; case (-2): /* separator */ rc = INVALID; suspended = TRUE; continue; case (-3): /* scrollbar */ rc = INVALID; suspended = TRUE; continue; default: if (menu->menuitems[rc].cmdid != INVALID && ((menu->menuitems[rc].flags & TGMU_DISABLED) == TGMU_DISABLED)) { rc = INVALID; suspended = TRUE; continue; } else if (menu->is_main_menu) { rc = menu->menuitems[rc].cmdid; } else if (menu->menuitems[rc].cmdid != INVALID && ((menu->menuitems[rc].flags & TGMU_DISABLED) != TGMU_DISABLED)) { if (gstMenuDontSendCommandInfo.dont_send_command) { gstMenuDontSendCommandInfo.selected_index = rc; } else { SendCommandToSelf(menu->menuitems[rc].cmdid, rc); } /* * Nothing catches -4, so all the parent menus will close. */ rc = (-4); } break; } } else { rc = INVALID; } menuing = FALSE; } else if (menu_pinned) { XDrawRectangle(mainDisplay, rootWindow, revDefaultGC, pinned_x, pinned_y, menu_w+(brdrW<<1), menu_h+(brdrW<<1)); pinned_x = root_x; pinned_y = root_y; XDrawRectangle(mainDisplay, rootWindow, revDefaultGC, pinned_x, pinned_y, menu_w+(brdrW<<1), menu_h+(brdrW<<1)); } else if (x >= 0 && x < menu_w && y >=0 && y < menu_h) { int new_selected=TgWhichMenuIndex(menu, x, y, FALSE); if (new_selected == (-3) || menu->selected_index != new_selected) { if (menu->selected_index != INVALID) { if (gnUncheckWhenMoused && !threeDLook && menu->type != TGMUTYPE_TEXT && ((menuitems[menu->selected_index].flags & TGMU_SEPARATOR) == 0) && menuitems[menu->selected_index].checked) { menuitems[menu->selected_index].checked = FALSE; } menuitems[menu->selected_index].state = TGBS_NORMAL; TgDrawMenuItem(menu, &menuitems[menu->selected_index]); } if (new_selected >= 0) { menuitems[new_selected].state = TGBS_RAISED; TgDrawMenuItem(menu, &menuitems[new_selected]); if (menuitems[new_selected].status_str != NULL) { /* the status_str has been translated */ SetStringStatus(menuitems[new_selected].status_str); } } switch (new_selected) { case INVALID: break; case (-2): new_selected = INVALID; break; /* separator */ case (-3): /* scrollbar */ if (menu->scroll_start > 0 && tmp_disallow_pinning) { /* loop to scroll */ ScrollMenu(menu, x, y, menu_w, menu_h, (status&BUTTONSMASK)); } new_selected = INVALID; XQueryPointer(mainDisplay, menu->window, &root_win, &child_win, &root_x, &root_y, &x, &y, &status); any_button_down = ((status & BUTTONSMASK) != 0); if (!any_button_down) { suspended = TRUE; } if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, menu->window, FALSE, PointerMotionMask | ButtonPressMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } break; default: break; } menu->selected_index = new_selected; if (new_selected != INVALID && (menuitems[new_selected].flags & TGMU_HAS_SUBMENU) == TGMU_HAS_SUBMENU && (menuitems[new_selected].flags & TGMU_DISABLED) == 0 && menuitems[new_selected].submenu_create_info != NULL) { TgMenu *submenu=NULL; submenu = TgCreatePopUpSubMenu(menu, new_selected); if (submenu != NULL) { #ifdef _CHAMELEON_BUG if (!debugNoPointerGrab) { XUngrabPointer(mainDisplay, CurrentTime); } #endif /* _CHAMELEON_BUG */ rc = TgPopUpSubMenu(menu, orig_x, orig_y); submenu = menuitems[new_selected].detail.submenu; if (submenu != NULL) { TgDestroyMenu(submenu, TRUE); menuitems[new_selected].detail.submenu = NULL; } } if (rc != INVALID && rc != (-3)) { menuing = FALSE; } else if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, menu->window, FALSE, PointerMotionMask | ButtonPressMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } } } tmp_disallow_pinning = inSlideShow; } else if (menu->parent_menu != NULL && menu->track_parent_menu && PointInBBox(root_x, root_y, gstMenubarWinBBox) && !TgPointInParentMenuSelectedItem(menu->parent_menu)) { menuing = FALSE; rc = BAD; } else if (menu->parent_menu != NULL && PointInBBox(root_x, root_y, menu->parent_menu->bbox)) { /* we are in the parent menu */ if (!TgPointInParentMenuSelectedItem(menu->parent_menu)) { menuing = FALSE; rc = (-3); } } else if (menu->parent_menu != NULL && TgPointInAnAncestorMenu(menu->parent_menu, root_x, root_y)) { /* we are in an ancestor menu */ menuing = FALSE; rc = (-3); } else if (menu->track_menubar && menubarWindow != None && PointInBBox(root_x, root_y, gstMenubarWinBBox) && WhichMenubarItem(root_x-gstMenubarWinBBox.ltx, root_y-gstMenubarWinBBox.lty, NULL, NULL, NULL) != INVALID && !PointInBBox(root_x-gstMenubarWinBBox.ltx, root_y-gstMenubarWinBBox.lty, excludeMenubarWinBBox)) { menuing = FALSE; rc = BAD; } else if (!menu->disallow_pinning && !tmp_disallow_pinning && !menu_pinned && (activeMenu != INVALID || menu->is_main_menu) && (root_x < min_pin || root_x > max_pin)) { pinned_x = root_x; pinned_y = root_y; XSetSubwindowMode(mainDisplay, revDefaultGC, IncludeInferiors); XDrawRectangle(mainDisplay, rootWindow, revDefaultGC, pinned_x, pinned_y, menu_w+(brdrW<<1), menu_h+(brdrW<<1)); SetStringStatus(TgLoadCachedString(CSTID_RELEASE_MOUSE_TO_PIN_MENU)); menu_pinned = TRUE; } else if (menu->selected_index != INVALID) { menuitems[menu->selected_index].state = TGBS_NORMAL; TgDrawMenuItem(menu, &menuitems[menu->selected_index]); menu->selected_index = INVALID; } } if (parent_menu == NULL && !debugNoPointerGrab) { XUngrabPointer(mainDisplay, CurrentTime); } if (menu->window != None) XDestroyWindow(mainDisplay, menu->window); XSync(mainDisplay, False); RestoreStatusStringsFromBuf(status_buf, one_line_status); return rc; } TgMenu *TgDestroyMenu(menu, free_menu) TgMenu *menu; int free_menu; /* return NULL if menu is freed */ { int i, num_items=menu->num_items; TgMenuItem *menuitems=NULL; menuitems = menu->menuitems; if (menuitems != NULL) { for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); UtilFree(menu_item->status_str); if (menu_item->menu_str_allocated) { UtilFree(menu_item->menu_str); menu_item->menu_str = NULL; } menu_item->status_str = NULL; if ((menu_item->flags & TGMU_HAS_SUBMENU) && menu_item->detail.submenu != NULL) { TgDestroyMenu(menu_item->detail.submenu, TRUE); } } free(menuitems); } if (free_menu) { free(menu); return NULL; } return menu; } static int TgGetTextMenuItemWidths(menu_item, pn_check_w, pn_str_w, pn_shortcut_w) TgMenuItem *menu_item; int *pn_check_w, *pn_str_w, *pn_shortcut_w; { int flags=menu_item->flags; if ((flags & TGMU_SEPARATOR) == TGMU_SEPARATOR) { if (pn_check_w != NULL) *pn_check_w = 0; if (pn_str_w != NULL) *pn_str_w = 0; if (pn_shortcut_w != NULL) *pn_shortcut_w = 0; return TRUE; } if (pn_check_w != NULL) { if ((flags & (TGMU_HAS_CHECK|TGMU_HAS_RADIO)) != 0) { *pn_check_w = check_width; } else { *pn_check_w = 0; } } if (pn_str_w != NULL) { char *menu_str=menu_item->menu_str; if (menuFontSet != NULL || menuFontPtr != NULL) { *pn_str_w = MenuTextWidth(menuFontPtr, _(menu_str), strlen(_(menu_str))); } else { *pn_str_w = defaultFontWidth * strlen(_(menu_str)); } } if (pn_shortcut_w != NULL) { if (flags & TGMU_HAS_SHORTCUT) { char *shortcut_str=menu_item->detail.shortcut_str; /* don't translate shortuct_str */ if (menuFontSet != NULL || menuFontPtr != NULL) { *pn_shortcut_w = MenuTextWidth(menuFontPtr, shortcut_str, strlen(shortcut_str)); } else { *pn_shortcut_w = defaultFontWidth * strlen(shortcut_str); } } else { *pn_shortcut_w = 0; } } return TRUE; } int TgSetMenuItemInfo(to_menu_item, mask, from_menu_item) TgMenuItem *to_menu_item, *from_menu_item; int mask; { if (mask & TGMU_MASK_LTXY) { to_menu_item->bbox.ltx = from_menu_item->bbox.ltx; to_menu_item->bbox.lty = from_menu_item->bbox.lty; } if (mask & TGMU_SEPARATOR) { to_menu_item->flags |= TGMU_SEPARATOR; return TRUE; } if (mask & TGMU_MASK_STATE) to_menu_item->state = from_menu_item->state; if (mask & TGMU_MASK_CMDID) to_menu_item->cmdid = from_menu_item->cmdid; if (mask & TGMU_MASK_MULTICOLOR) { to_menu_item->flags |= TGMU_MULTICOLOR; to_menu_item->multicolor_pixel = from_menu_item->multicolor_pixel; } if (mask & TGMU_MASK_PXMPBTN1) { to_menu_item->checked_pxmpbtn = from_menu_item->checked_pxmpbtn; } if (mask & TGMU_MASK_PXMPBTN2) { to_menu_item->unchecked_pxmpbtn = from_menu_item->unchecked_pxmpbtn; } if (mask & TGMU_MASK_CHECK) { to_menu_item->flags |= TGMU_HAS_CHECK; to_menu_item->flags &= (~TGMU_HAS_RADIO); to_menu_item->checked = from_menu_item->checked; } if (mask & TGMU_MASK_RADIO) { to_menu_item->flags |= TGMU_HAS_RADIO; to_menu_item->flags &= (~TGMU_HAS_CHECK); to_menu_item->checked = from_menu_item->checked; } if (mask & TGMU_MASK_MENUSTR) { to_menu_item->menu_str = from_menu_item->menu_str; } if (mask & TGMU_MASK_STATUSSTR) { char *psz=NULL; UtilFree(to_menu_item->status_str); if (mask & TGMU_MASK_RAWSTATUSSTR) { /* the from_menu_item->status_str has NOT been translated */ to_menu_item->status_str = UtilStrDup(_(from_menu_item->status_str)); } else { /* the from_menu_item->status_str has been translated */ to_menu_item->status_str = UtilStrDup(from_menu_item->status_str); } if (to_menu_item->status_str == NULL) FailAllocMessage(); /* do not translate -- program constants */ if (from_menu_item->status_str != NULL && (psz=strstr(from_menu_item->status_str, "<>")) != NULL) { char *psz1=(&psz[strlen("<>")]); sprintf(&to_menu_item->status_str[psz-from_menu_item->status_str], "%s%s", TOOL_NAME, psz1); } } if (mask & TGMU_MASK_SUBMENU) { to_menu_item->flags |= TGMU_HAS_SUBMENU; to_menu_item->flags &= (~TGMU_HAS_SHORTCUT); to_menu_item->submenu_create_info = from_menu_item->submenu_create_info; if (mask & TGMU_MASK_PINNABLESUBMENU) { to_menu_item->flags |= TGMU_SUBMENU_PINNABLE; } } if (mask & TGMU_MASK_SHORTCUTSTR) { to_menu_item->flags |= TGMU_HAS_SHORTCUT; to_menu_item->flags &= (~TGMU_HAS_SUBMENU); to_menu_item->detail.shortcut_str = from_menu_item->detail.shortcut_str; } if (mask & TGMU_MASK_USERDATA) { to_menu_item->userdata = from_menu_item->userdata; } return TRUE; } static int TgAdjustMenuItemHeight(menu, menu_item) TgMenu *menu; TgMenuItem *menu_item; { int flags=menu_item->flags, item_w=0, item_h=0; if (flags & TGMU_SEPARATOR) { menu_item->bbox.rby = menu_item->bbox.lty+separatorHeight; return TRUE; } switch (menu->type) { case TGMUTYPE_TEXT: if (menuFontSet != NULL || menuFontPtr != NULL) { menu_item->bbox.rby = menu_item->bbox.lty+menuFontHeight; } else { menu_item->bbox.rby = menu_item->bbox.lty+defaultFontHeight; } break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: item_w = menu->image_w; item_h = menu->image_h; if (threeDLook) { item_w += (windowPadding<<1); item_h += (windowPadding<<1); } menu_item->bbox.rbx = menu_item->bbox.ltx+item_w; menu_item->bbox.rby = menu_item->bbox.lty+item_h; break; } return TRUE; } void TgAdjustMenuGeometry(menu, image_w, image_h, max_rows) TgMenu *menu; int image_w, image_h, max_rows; /* only for TGMUTYPE_BITMAP or TGMUTYPE_COLOR */ { int max_h=0, item_w=image_w, item_h=image_h; int i, xoff=0, yoff=0, max_col_w=0, max_w=0, num_items=menu->num_items; if (threeDLook) { item_w += (windowPadding<<1); item_h += (windowPadding<<1); } menu->image_w = image_w; menu->image_h = image_h; menu->num_rows = max_rows; menu->num_cols = (((num_items % max_rows) == 0) ? num_items / max_rows : ((int)(num_items/max_rows))+1); xoff = menu->padding; yoff = menu->padding; for (i=0; i < num_items; i++) { int flags=TGMU_MASK_LTXY, col_w=0, item_h=0; TgMenuItem *menu_item=(&menu->menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.bbox.ltx = xoff; stMenuItem.bbox.lty = yoff; if (menu_item->menu_str == TGMUITEM_SEPARATOR) { flags |= TGMU_SEPARATOR; } if (!TgSetMenuItemInfo(menu_item, flags, &stMenuItem)) { TgDestroyMenu(menu, TRUE); /* frees menu in TgDestroyMenu() */ return; } /* now adjust the width and height of menu_item->bbox */ TgAdjustMenuItemHeight(menu, menu_item); col_w = menu_item->bbox.rbx-menu_item->bbox.ltx; item_h = menu_item->bbox.rby-menu_item->bbox.lty; if (col_w > max_col_w) max_col_w = col_w; yoff += item_h; if (xoff+max_col_w > max_w) max_w = xoff+max_col_w; if (yoff > max_h) max_h = yoff; if (((i+1) % max_rows) == 0) { xoff += max_col_w; yoff = menu->padding; } } menu->check_start = menu->str_start = menu->shortcut_start = menu->arrow_start = xoff; menu->bbox.rbx = menu->bbox.ltx+max_w-menu->padding; menu->bbox.rby = menu->bbox.lty+max_h-menu->padding; maxScrollableMenuWidth = (menuColsBeforeScroll*item_w) + (windowPadding<<1); if (menu->can_scroll && (max_w+windowPadding) > maxScrollableMenuWidth) { menu->scroll_start = (item_h*max_rows); } } static int CreateTextMenuItemsFromMenuItemInfo(menu, menu_iteminfos, status_str_xlated) TgMenu *menu; TgMenuItemInfo *menu_iteminfos; int status_str_xlated; { TgMenuItemInfo *item_info=NULL; int i, xoff=0, yoff=0, max_str_w=0, max_shortcut_w=submenu_width, total_w=0; int num_items=0; for (item_info=menu_iteminfos; item_info->menu_str != NULL; item_info++) { num_items++; } menu->num_items = num_items; menu->menuitems = (TgMenuItem*)malloc(num_items*sizeof(TgMenuItem)); if (menu->menuitems == NULL) FailAllocMessage(); memset(menu->menuitems, 0, num_items*sizeof(TgMenuItem)); xoff = menu->padding; yoff = menu->padding; for (item_info=menu_iteminfos, i=0; item_info->menu_str != NULL; item_info++, i++) { int flags=0, check_w=0, str_w=0, shortcut_w=0; TgMenuItem *menu_item=(&menu->menuitems[i]); TgMenuItem stMenuItem; memset(menu_item, 0, sizeof(TgMenuItem)); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.bbox.ltx = xoff; stMenuItem.bbox.lty = yoff; if (item_info->menu_str == TGMUITEM_SEPARATOR) { flags |= TGMU_SEPARATOR | TGMU_MASK_LTXY; } else { stMenuItem.state = TGBS_NORMAL; stMenuItem.cmdid = item_info->cmdid; stMenuItem.menu_str = item_info->menu_str; /* the from_menu_item->status_str has been translated */ stMenuItem.status_str = item_info->status_str; flags |= TGMU_MASK_LTXY | TGMU_MASK_STATE | TGMU_MASK_CMDID | TGMU_MASK_MENUSTR | TGMU_MASK_STATUSSTR; if (!status_str_xlated) { flags |= TGMU_MASK_RAWSTATUSSTR; } if (item_info->shortcut_str == TGMUITEM_SUBMENU || item_info->shortcut_str == TGMUITEM_PINNABLESUBMENU) { flags |= TGMU_MASK_SUBMENU; if (item_info->shortcut_str == TGMUITEM_PINNABLESUBMENU) { flags |= TGMU_MASK_PINNABLESUBMENU; } stMenuItem.submenu_create_info = item_info; } else if (item_info->shortcut_str != NULL) { flags |= TGMU_MASK_SHORTCUTSTR; stMenuItem.detail.shortcut_str = item_info->shortcut_str; } } if (!TgSetMenuItemInfo(menu_item, flags, &stMenuItem)) { TgDestroyMenu(menu, TRUE); /* frees menu in TgDestroyMenu() */ return FALSE; } TgAdjustMenuItemHeight(menu, menu_item); TgGetTextMenuItemWidths(menu_item, &check_w, &str_w, &shortcut_w); if (str_w > max_str_w) max_str_w = str_w; if (shortcut_w > max_shortcut_w) max_shortcut_w = shortcut_w; yoff += menu_item->bbox.rby-menu_item->bbox.lty+1; } menu->check_start = xoff+2; menu->str_start = menu->check_start+check_width+2; menu->shortcut_start = menu->str_start+max_str_w+(menuFontWidth<<1)+2; menu->arrow_start = menu->shortcut_start+max_shortcut_w-submenu_width; total_w = menu->arrow_start+submenu_width-xoff+2+menuFontWidth; menu->bbox.rbx = menu->bbox.ltx + total_w; menu->bbox.rby = menu->bbox.lty + yoff; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menu->menuitems[i]); menu_item->bbox.rbx = menu->shortcut_start+max_shortcut_w+menuFontWidth; } if (menu->can_scroll && yoff > maxScrollableMenuHeight) { menu->scroll_start = total_w; } return TRUE; } static void SetScrollableMenuSize(menu) TgMenu *menu; { switch (menu->type) { case TGMUTYPE_TEXT: maxScrollableMenuHeight = (menuRowsBeforeScroll * (((menuFontSet==NULL && menuFontPtr == NULL) ? initialMenubarWindowH : menuFontHeight) + 1)) + (windowPadding<<1); break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: /* * Do nothing! * maxScrollableMenuWidth will be set in TgAdjustMenuGeometry() */ break; } } static int CreateBitmapOrColorMenuItemsFromMenuItemInfo(menu, menu_iteminfos, status_str_xlated) TgMenu *menu; TgMenuItemInfo *menu_iteminfos; int status_str_xlated; { TgMenuItemInfo *item_info=NULL; int i, xoff=0, yoff=0, num_items=0; for (item_info=menu_iteminfos; item_info->menu_str != NULL; item_info++) { num_items++; } menu->num_items = num_items; menu->menuitems = (TgMenuItem*)malloc(num_items*sizeof(TgMenuItem)); if (menu->menuitems == NULL) FailAllocMessage(); memset(menu->menuitems, 0, num_items*sizeof(TgMenuItem)); xoff = menu->padding; yoff = menu->padding; for (item_info=menu_iteminfos, i=0; item_info->menu_str != NULL; item_info++, i++) { int flags=0; TgMenuItem *menu_item=(&menu->menuitems[i]); TgMenuItem stMenuItem; memset(menu_item, 0, sizeof(TgMenuItem)); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.bbox.ltx = xoff; stMenuItem.bbox.lty = yoff; if (item_info->menu_str == TGMUITEM_SEPARATOR) { flags |= TGMU_SEPARATOR | TGMU_MASK_LTXY; } else { stMenuItem.state = TGBS_NORMAL; stMenuItem.cmdid = item_info->cmdid; stMenuItem.menu_str = item_info->menu_str; /* the from_menu_item->status_str has been translated */ stMenuItem.status_str = item_info->status_str; flags |= TGMU_MASK_LTXY | TGMU_MASK_STATE | TGMU_MASK_CMDID | TGMU_MASK_MENUSTR | TGMU_MASK_STATUSSTR; if (!status_str_xlated) { flags |= TGMU_MASK_RAWSTATUSSTR; } if (item_info->shortcut_str != NULL) { flags |= TGMU_MASK_SHORTCUTSTR; stMenuItem.detail.shortcut_str = item_info->shortcut_str; } } if (!TgSetMenuItemInfo(menu_item, flags, &stMenuItem)) { TgDestroyMenu(menu, TRUE); /* frees menu in TgDestroyMenu() */ return FALSE; } TgAdjustMenuItemHeight(menu, menu_item); } return TRUE; } TgMenu *TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y, status_str_xlated; TgMenuInfo *menu_info; { TgMenu *menu=(TgMenu*)malloc(sizeof(TgMenu)); TgMenuItemInfo *menu_iteminfos=menu_info->items; #ifdef _TGIF_DBG /* debug, do not translate */ if (status_str_xlated == INVALID) { XUngrabPointer(mainDisplay, CurrentTime); sprintf(gszMsgBox, "Error: %s() is called with %s=INVALID.", "TgCreateMenuFromMenuInfo", "status_str_xlated"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } #endif /* _TGIF_DBG */ if (menu == NULL) FailAllocMessage(); memset(menu, 0, sizeof(TgMenu)); menu->type = (menu_info->type & TGMUTYPE_MASK); if ((menu_info->type & TGMUTYPE_CANSCROLL) == TGMUTYPE_CANSCROLL) { menu->can_scroll = TRUE; /* scroll_start and first_index already 0 */ } menu_info->type &= TGMUTYPE_MASK; menu->num_items = 0; menu->selected_index = INVALID; menu->bbox.ltx = menu->bbox.rbx = x; menu->bbox.lty = menu->bbox.rby = y; menu->padding = (threeDLook ? windowPadding : 0); menu->brdr_w = (threeDLook ? 0 : (brdrW<<1)); menu->track_menubar = TRUE; menu->parent_menu = parent_menu; SetScrollableMenuSize(menu); switch (menu_info->type) { case TGMUTYPE_TEXT: if (!CreateTextMenuItemsFromMenuItemInfo(menu, menu_iteminfos, status_str_xlated)) { free(menu); return NULL; } break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: if (!CreateBitmapOrColorMenuItemsFromMenuItemInfo(menu, menu_iteminfos, status_str_xlated)) { free(menu); return NULL; } break; } return menu; } void SetScrollableMenuFirstIndex(menu, selected_item_index) TgMenu *menu; int selected_item_index; /* use this only for radio-button style menu, no separators */ { if (menu->scroll_start > 0) { int col=0; switch (menu->type) { case TGMUTYPE_TEXT: if (selected_item_index >= menuRowsBeforeScroll) { menu->first_index = selected_item_index; if (menu->first_index < 0) menu->first_index = 0; if (menu->first_index+menuRowsBeforeScroll >= menu->num_items) { menu->first_index = menu->num_items-menuRowsBeforeScroll; } } break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: col = (int)(selected_item_index/menu->num_rows); if (col >= menuColsBeforeScroll) { menu->first_index = col; if (menu->first_index < 0) menu->first_index = 0; if (menu->first_index+menuColsBeforeScroll >= menu->num_cols) { menu->first_index = menu->num_cols-menuColsBeforeScroll; } } break; } } } int RefreshMainMenu(menu) TgMenu *menu; { int ok=TRUE; ok &= TgEnableMenuItemById(menu, MENU_STACKEDPAGE, (pageLayoutMode==PAGE_STACK)); ok &= TgEnableMenuItemById(menu, MENU_TILEDPAGE, (pageLayoutMode!=PAGE_STACK)); ok &= TgEnableMenuItemById(menu, MENU_COLOR, colorDisplay); return ok; } TgMenu *CreateMainMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { menu->track_menubar = FALSE; menu->is_main_menu = TRUE; if (!RefreshMainMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshMainMenu); } return menu; } int MainMenu() { int x=0, y=0, root_x=0, root_y=0; int rc=INVALID, index=INVALID; Window root_win=None, child_win=None; unsigned int status=0; TgMenu *menu=NULL; Msg(""); XQueryPointer(mainDisplay, rootWindow, &root_win, &child_win, &root_x, &root_y, &x, &y, &status); activeMenu = MENU_MAIN; if (cmdLineTgrm2) { menu = (mainMenuInfo.create_proc)(NULL, x, y, &mainMenuInfo, 0); } else { TgMenuInfo tgmi; memcpy(&tgmi, &mainMenuInfo, sizeof(TgMenuInfo)); tgmi.items = gpMainMenuItemInfos; menu = (tgmi.create_proc)(NULL, x, y, &tgmi, 0); } if (menu != NULL) { index = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } activeMenu = INVALID; if (index == INVALID || index == (-4)) return INVALID; return rc; } int IsPrefix(Prefix, Str, Rest) char *Prefix, *Str, **Rest; { register char *c_ptr=Prefix; for (*Rest=Str; *c_ptr!='\0' && **Rest!='\0'; (*Rest)++, c_ptr++) { if (**Rest != *c_ptr) { return FALSE; } } return (*c_ptr == '\0' && **Rest == DIR_SEP); } void RedrawTitleWindow() { int y, len, amount, left; char s[MAXPATHLENGTH], name[MAXPATHLENGTH], * c_ptr, * rest; struct BBRec bbox; XClearWindow(mainDisplay, titleWindow); s[0] = '\0'; if (curFileDefined) { if (*curSymDir == '\0') { sprintf(name, "%s%c%s", curDir, DIR_SEP, curFileName); } else { sprintf(name, "%s%c%s", curSymDir, DIR_SEP, curFileName); } if (IsPrefix(bootDir, name, &rest)) { c_ptr = ++rest; } else { c_ptr = name; } FormatFloat(&printMag, gszMsgBox); sprintf(s, "%s:%s (%s%%)", curDomainName, c_ptr, gszMsgBox); } else { FormatFloat(&printMag, gszMsgBox); sprintf(s, "%s:%s (%s%%)", curDomainName, TgLoadCachedString(CSTID_SQUARE_BRACK_UNNAMED), gszMsgBox); } if (pageLayoutMode==PAGE_STACK && curPage!=NULL) { sprintf(&s[strlen(s)], " \"%s\"", (curPage->name==NULL) ? "" : curPage->name); } if (fileModified) { if (IsFiletUnSavable()) { sprintf(gszMsgBox, " %s", TgLoadCachedString(CSTID_SQUARE_BRACK_MODIFIED_UNSAV)); } else { sprintf(gszMsgBox, " %s", TgLoadCachedString(CSTID_SQUARE_BRACK_MODIFIED)); } strcat(s, gszMsgBox); } if (s[0] != '\0') { len = strlen(s); if (msgFontSet != NULL || msgFontPtr != NULL) { if (msgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, msgFontPtr->fid); } if (showVersion) { DrawMsgString(mainDisplay, titleWindow, defaultGC, 1+windowPadding, (titleWindowH>>1)+msgFontAsc+1, s, len); } else { DrawMsgString(mainDisplay, titleWindow, defaultGC, 1+windowPadding, msgFontAsc+1+windowPadding, s, len); } XSetFont(mainDisplay, defaultGC, defaultFontPtr->fid); } else { if (showVersion) { DrawMsgString(mainDisplay, titleWindow, defaultGC, 1+windowPadding, (titleWindowH>>1)+defaultFontAsc+1, s, len); } else { DrawMsgString(mainDisplay, titleWindow, defaultGC, 1+windowPadding, defaultFontAsc+1+windowPadding, s, len); } } } if (showVersion) { SetFullVersionString(); strcpy(s, fullToolName); len = strlen(s); if (msgFontSet != NULL || msgFontPtr != NULL) { amount = MsgTextWidth(msgFontPtr, s, len); left = ((titleWindowW-amount)>>1); if (msgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, msgFontPtr->fid); } DrawMsgString(mainDisplay, titleWindow, defaultGC, left, msgFontAsc+2+(windowPadding>>1), s, len); XSetFont(mainDisplay, defaultGC, defaultFontPtr->fid); for (y=4+(windowPadding>>1); y < (titleWindowH>>1)-4; y += 2) { XDrawLine(mainDisplay, titleWindow, defaultGC, 2+windowPadding, y, left-msgFontWidth, y); XDrawLine(mainDisplay, titleWindow, defaultGC, left+amount+msgFontWidth, y, titleWindowW-3, y); } } else { amount = defaultFontWidth * len; left = ((titleWindowW-amount)>>1); DrawMsgString(mainDisplay, titleWindow, defaultGC, left, defaultFontAsc+2+(windowPadding>>1), s, len); for (y=4+(windowPadding>>1); y < (titleWindowH>>1)-4; y += 2) { XDrawLine(mainDisplay, titleWindow, defaultGC, 2+windowPadding, y, left-defaultFontWidth, y); XDrawLine(mainDisplay, titleWindow, defaultGC, left+amount+defaultFontWidth, y, titleWindowW-3, y); } } } if (threeDLook) { bbox.ltx = 0; bbox.lty = 0; bbox.rbx = titleWindowW; bbox.rby = titleWindowH; TgDrawThreeDButton(mainDisplay, titleWindow, textMenuGC, &bbox, TGBS_RAISED, 1, FALSE); } } static struct ObjRec *iconTopObj=NULL, *iconBotObj=NULL; static struct ObjRec *iconTgifObj=NULL; static int justIconified=FALSE; void RedrawIconWindow() { register struct ObjRec *obj_ptr; numRedrawBBox = 0; for (obj_ptr = iconBotObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = NULL; DrawObj(iconWindow, obj_ptr); } if (justIconified && iconTgifObj != NULL && iconTgifObj->fattr != NULL) { struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; justIconified = FALSE; if ((attr_ptr=FindAttrWithName(iconTgifObj,"icon_init_exec_obj=",NULL)) != NULL && (obj_ptr=FindObjWithName(iconBotObj, iconTgifObj, attr_ptr->attr_value.s,FALSE,FALSE,NULL,NULL)) != NULL && (attr_ptr=FindAttrWithName(obj_ptr,EXEC_ATTR,NULL)) != NULL) { int saved_intr_check_interval=intrCheckInterval; int saved_history_depth=historyDepth; intrCheckInterval = 1; historyDepth = 0; ShowInterrupt(1); DoExec(attr_ptr, obj_ptr); HideInterrupt(); intrCheckInterval = saved_intr_check_interval; historyDepth = saved_history_depth; } } justIconified = FALSE; } static char iconFileName[] = "tgificon"; static void InitIcon() { struct ObjRec *obj_ptr, *saved_tgif_obj; char s[MAXPATHLENGTH], *c_ptr, msg[MAXSTRING], ext_str[MAXPATHLENGTH]; FILE *fp=NULL; int ltx=0, lty=0, rbx=0, rby=0, seen_obj=FALSE; int dx, dy, w, h, len, ext_len, x, y, read_status; unsigned int icon_w, icon_h; XSizeHints sizehints; int tmp_linenum; char tmp_filename[MAXPATHLENGTH], tmp_filefullpath[MAXPATHLENGTH]; DelAllPages(); lastPageNum = 1; InitPage(); iconWindowCreated = FALSE; if (((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"UseWMIconPixmap")) == NULL) || UtilStrICmp(c_ptr,"false") != 0) { return; } if (((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"NoTgifIcon")) != NULL) && UtilStrICmp(c_ptr,"True") == 0) { return; } strcpy(s, drawPath); strcat(s, DIR_SEP_STR); if ((c_ptr=getenv("TGIFICON")) == NULL) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"TGIFICON")) != NULL) { if (*c_ptr == DIR_SEP) { strcpy(s, c_ptr); } else { strcat(s, c_ptr); } } else { strcat(s, iconFileName); } } else if (((int)strlen(c_ptr)) >= 200) { /* too long, must be an error */ strcat(s, iconFileName); } else if (*c_ptr == DIR_SEP) { strcpy(s, c_ptr); } else { strcat(s, c_ptr); } sprintf(ext_str, ".%s", OBJ_FILE_EXT); ext_len = strlen(ext_str); len = strlen(s); if (len < ext_len || strcmp(&s[len-ext_len],ext_str) != 0) { sprintf(&(s[len]), ".%s", OBJ_FILE_EXT); } if ((fp=fopen(s, "r")) == NULL) { /* * fprintf(stderr, "Warning: Cannot open the tgif icon file '%s'.\n", s); */ return; } strcpy(tmp_filefullpath, scanFileFullPath); strcpy(tmp_filename, scanFileName); tmp_linenum = scanLineNum; UtilStrCpyN(scanFileFullPath, sizeof(scanFileFullPath), s); strcpy(scanFileName, s); scanLineNum = 0; saved_tgif_obj = tgifObj; InitTgifObj(); importingFile = TRUE; /* ignore the 'state' predicate */ importingIconFile = TRUE; /* read the 'file_attr' predicate */ readingPageNum = loadedCurPageNum = 0; foundGoodStateObject = FALSE; while ((read_status=ReadObj(fp, &obj_ptr)) == TRUE) { if (obj_ptr != NULL) { AddObj(NULL, topObj, obj_ptr); if (!seen_obj) { seen_obj = TRUE; ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; } else { if (obj_ptr->bbox.ltx < ltx) ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < lty) lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > rbx) rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > rby) rby = obj_ptr->bbox.rby; } } } strcpy(scanFileFullPath, tmp_filefullpath); strcpy(scanFileName, tmp_filename); scanLineNum = tmp_linenum; importingFile = FALSE; importingIconFile = FALSE; fclose(fp); if (read_status == INVALID) { sprintf(msg, TgLoadString(STID_ICON_FILEVER_TOO_LARGE), fileVersion); Msg(s); CleanUpTgifObj(); tgifObj = saved_tgif_obj; return; } w = rbx - ltx; h = rby - lty; if (w > iconWindowW) { dx = -ltx; iconWindowW = w; } else { dx = -ltx+((iconWindowW-w)>>1); } if (h > iconWindowH) { dy = -lty; iconWindowH = h; } else { dy = -lty+((iconWindowH-h)>>1); } for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { MoveObj(obj_ptr, dx, dy); } iconTgifObj = tgifObj; tgifObj = saved_tgif_obj; iconTopObj = topObj; iconBotObj = botObj; curPage->top = curPage->bot = topObj = botObj = NULL; CleanUpPage(); sizehints.x = 0; sizehints.y = 0; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"IconGeometry")) != NULL) { int bitmask=XParseGeometry(c_ptr, &x, &y, &icon_w, &icon_h); if ((bitmask & XValue) && (bitmask & YValue)) { if (bitmask & XValue) sizehints.x = x; if (bitmask & YValue) sizehints.y = y; if (bitmask & XNegative) sizehints.x += DisplayWidth(mainDisplay, mainScreen) - iconWindowW - (brdrW<<1) - 1; if (bitmask & YNegative) sizehints.y += DisplayHeight(mainDisplay, mainScreen) - iconWindowH - (brdrW<<1) - 1; } } if ((iconBaseWindow = XCreateSimpleWindow(mainDisplay, rootWindow, sizehints.x, sizehints.y, iconWindowW+(brdrW<<1), iconWindowH+(brdrW<<1), brdrW, myBorderPixel, myBgPixel)) == 0) { FailToCreateWindowMessage("InitIcon()", NULL, TRUE); } if ((iconWindow = XCreateSimpleWindow(mainDisplay, iconBaseWindow, 0, 0, iconWindowW, iconWindowH, brdrW, myBorderPixel, myBgPixel)) == 0) { FailToCreateWindowMessage("InitIcon()", NULL, TRUE); } XStoreName(mainDisplay, iconBaseWindow, TOOL_NAME); XSelectInput(mainDisplay, iconBaseWindow, StructureNotifyMask | VisibilityChangeMask); if (((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DoubleClickUnIconify")) != NULL) && UtilStrICmp(c_ptr,"True") == 0) { XSelectInput(mainDisplay, iconWindow, ButtonPressMask | KeyPressMask | ExposureMask); } else { XSelectInput(mainDisplay, iconWindow, KeyPressMask | ExposureMask); } iconWindowCreated = TRUE; } void InitTitle() { InitIcon(); } void InitMenu() { XGCValues values; char *c_ptr=NULL; values.foreground = myFgPixel; values.background = (threeDLook ? myLtGryPixel : myBgPixel); values.fill_style = FillSolid; /* * If (menuFontSet) is not NULL, it's okay to set values.font to * whatever because it won't get used. */ values.font = (menuFontPtr==NULL ? defaultFontPtr->fid : menuFontPtr->fid); textMenuGC = XCreateGC(mainDisplay, rootWindow, GCForeground | GCBackground | GCFillStyle | GCFont, &values); values.foreground = myBgPixel; values.background = myFgPixel; values.fill_style = FillStippled; rvPixmapMenuGC = XCreateGC(mainDisplay, rootWindow, GCForeground | GCBackground | GCFillStyle | GCFont, &values); InitMainMenu(); BuildMenubarInfo(); separatorHeight = (threeDLook ? SEPARATOR_PADDING+2 : SEPARATOR_PADDING+1); deleteCmdAsCut = FALSE; if (((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DeleteCmdAsCut")) != NULL) && UtilStrICmp(c_ptr,"true") == 0) { /* this X default is obsolete */ deleteCmdAsCut = TRUE; } memset(&gstMenuDontSendCommandInfo, 0, sizeof(MenuDontSendCommandInfo)); } void CleanUpMenu() { struct ObjRec *saved_top_obj, *saved_bot_obj, *saved_tgif_obj; XFreeGC(mainDisplay, textMenuGC); XFreeGC(mainDisplay, rvPixmapMenuGC); CleanUpMainMenu(); if (stackingWins != NULL) { free(stackingWins); stackingWins = NULL; } if (iconTgifObj != NULL) { saved_tgif_obj = tgifObj; tgifObj = iconTgifObj; CleanUpTgifObj(); tgifObj = saved_tgif_obj; } if (iconTopObj != NULL) { saved_top_obj = topObj; saved_bot_obj = botObj; topObj = iconTopObj; botObj = iconBotObj; DelAllObj(); topObj = saved_top_obj; botObj = saved_bot_obj; } if (check_bits == NULL) { } if (submenu_bits == NULL) { } if (!cmdLineTgrm2) { free(gpMenubarItemInfos); gpMenubarItemInfos = NULL; gnNumMenubarItems = 0; free(gpMainMenuItemInfos); gpMainMenuItemInfos = NULL; gnNumMainMenuItems = 0; } } void SaveDrawWinInfo() { savedZoomScale = zoomScale; savedZoomedIn = zoomedIn; savedDrawOrigX = drawOrigX; savedDrawOrigY = drawOrigY; savedDrawWinW = drawWinW; savedDrawWinH = drawWinH; savedFileModified = fileModified; } void UnIconify() { register int j, i; if (!iconWindowShown) return; iconWindowShown = FALSE; zoomScale = savedZoomScale; zoomedIn = savedZoomedIn; drawOrigX = savedDrawOrigX; drawOrigY = savedDrawOrigY; drawWinW = savedDrawWinW; drawWinH = savedDrawWinH; fileModified = savedFileModified; UpdDrawWinBBox(); SetDefaultDrawWinClipRecs(); #ifdef notdef XUnmapWindow(mainDisplay, iconWindow); #endif if (iconWindowCreated) XUnmapWindow(mainDisplay, iconBaseWindow); XMapWindow(mainDisplay, mainWindow); for (i=0; i < numExtraWins; i++) { if (extraWinInfo[i].raise && !extraWinInfo[i].mapped && extraWinInfo[i].window != None) { XMapRaised(mainDisplay, extraWinInfo[i].window); extraWinInfo[i].mapped = TRUE; } } for (i=0; i < numStacking; i++) { for (j=0; j < numExtraWins; j++) { if (extraWinInfo[j].raise && extraWinInfo[j].window==stackingWins[i]) { extraWinInfo[j].mapped = TRUE; break; } } XMapRaised(mainDisplay, stackingWins[i]); } XFlush(mainDisplay); XSync(mainDisplay, False); } void Iconify() { register int i; if (iconWindowShown) return; iconWindowShown = TRUE; SaveDrawWinInfo(); zoomScale = 0; zoomedIn = FALSE; drawOrigX = 0; drawOrigY = 0; drawWinW = iconWindowW; drawWinH = iconWindowH; UpdDrawWinBBox(); SetDefaultIconWinClipRecs(); justIconified = TRUE; #ifdef notdef XUnmapWindow(mainDisplay, mainWindow); #endif SaveStackingOrder(); if (pinnedMainMenu) XUnmapWindow(mainDisplay, mainMenuWindow); for (i = 0; i < numExtraWins; i++) { if (extraWinInfo[i].raise && extraWinInfo[i].mapped && extraWinInfo[i].window != None) { XUnmapWindow(mainDisplay, extraWinInfo[i].window); extraWinInfo[i].mapped = FALSE; } } if (iconWindowCreated) { XMapWindow(mainDisplay, iconBaseWindow); XMapWindow(mainDisplay, iconWindow); } } static int iconJustClicked=FALSE; static Time iconClickTime; void IconEventHandler(input) XEvent *input; { XEvent ev; Time click_time; if (input->xany.window == iconWindow && input->type == ButtonPress) { XButtonEvent *button_ev=(&(input->xbutton)); if (iconWindowShown && !justIconified && button_ev->button == Button2 && (button_ev->state & (ShiftMask | ControlMask))) { justIconified = TRUE; RedrawIconWindow(); } else { click_time = input->xbutton.time; if (iconJustClicked && (click_time-iconClickTime)xany.window==iconBaseWindow && input->type==UnmapNotify) { UnIconify(); } else if (input->xany.window==iconBaseWindow && input->type==MapNotify) { Iconify(); /* } else if (input->xany.window==iconBaseWindow && (input->type==MapNotify || input->type == VisibilityNotify && input->xvisibility.state == VisibilityUnobscured)) { Iconify(); */ } else if (input->xany.window == iconWindow && input->type == Expose) { if (!iconWindowShown) return; while (XCheckWindowEvent(mainDisplay, iconWindow, ExposureMask, &ev)) ; while (XCheckWindowEvent(mainDisplay, iconBaseWindow, StructureNotifyMask, &ev)) ; RedrawIconWindow(); } } void TitleEventHandler(input) XEvent *input; { XEvent ev; if (input->type == Expose) { XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, titleWindow, ExposureMask, &ev)) ; RedrawTitleWindow(); } else if (input->type == EnterNotify) { SetMouseStatus(TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_MAIN_MENU), TgLoadCachedString(CSTID_MAIN_MENU)); } else if (input->type == ButtonPress && (input->xbutton.button == Button2 || input->xbutton.button == Button3)) { MainMenu(); } } void CalcMenubarWindowHeight() /* Given menubarWindowW, set manubarWindowH to fit everything */ { int i, x=0, w=0, h=0, gap=0, padding=(windowPadding>>1); BuildMenubarInfo(); if (menuFontSet != NULL || menuFontPtr != NULL) { x = menuFontWidth; h = menuFontHeight; gap = (x<<1); x += padding; h += padding; for (i=0; i < gnNumMenubarItems; i++) { w = MenuTextWidth(menuFontPtr, _(gpMenubarItemInfos[i].menu_str), strlen(_(gpMenubarItemInfos[i].menu_str))); if ((!noMinWinSize || !gnMinimalMenubar || gnAutoWrapMenubar) && x+w+padding >= menubarWindowW) { x = menuFontWidth+padding; h += menuFontHeight+padding; } x += w+gap+padding; } x += (padding<<1); h += (padding<<1); } else { x = 2; h = initialMenubarWindowH; gap = defaultFontWidth+(defaultFontWidth>>1); x += padding; h += padding; for (i=0; i < gnNumMenubarItems; i++) { w = defaultFontWidth*strlen(_(gpMenubarItemInfos[i].menu_str)); if ((!noMinWinSize || !gnMinimalMenubar || gnAutoWrapMenubar) && x+w+padding >= menubarWindowW) { x = 2+padding; h += initialMenubarWindowH+padding; } x += w+gap+padding; } x += (padding<<1); h += (padding<<1); } menubarWindowH = h; } static void HighLightMenubarString(item_str, bbox, highlight) char *item_str; struct BBRec *bbox; int highlight; /* HighLightMenubarString() will use _(item_str) internally */ { if (threeDLook) { struct BBRec real_bbox; real_bbox.ltx = bbox->ltx-2; real_bbox.lty = bbox->lty; real_bbox.rbx = bbox->rbx+2; real_bbox.rby = bbox->rby+1; if (highlight) { TgDrawThreeDButton(mainDisplay, menubarWindow, textMenuGC, &real_bbox, TGBS_RAISED, 1, FALSE); } else { TgClearThreeDButton(mainDisplay, menubarWindow, textMenuGC, &real_bbox, 1); } } else { int fg_pixel=(highlight ? myBgPixel : myFgPixel); int bg_pixel=(highlight ? myFgPixel : (threeDLook?myLtGryPixel:myBgPixel)); XSetForeground(mainDisplay, textMenuGC, bg_pixel); XFillRectangle(mainDisplay, menubarWindow, textMenuGC, bbox->ltx-2, bbox->lty, bbox->rbx-bbox->ltx+4, bbox->rby-bbox->lty); XSetForeground(mainDisplay, textMenuGC, fg_pixel); if (menuFontSet != NULL || menuFontPtr != NULL) { DrawMenuString(mainDisplay, menubarWindow, textMenuGC, bbox->ltx+(menuFontWidth>>1), menuFontAsc+bbox->lty, _(item_str), strlen(_(item_str))); } else { DrawMenuString(mainDisplay, menubarWindow, textMenuGC, bbox->ltx, defaultFontAsc+bbox->lty, _(item_str), strlen(_(item_str))); } } } void RedrawMenubarWindow() { int i, x=0, y=0, w=0, len=0, gap=0, padding=(windowPadding>>1); struct BBRec bbox; XClearWindow(mainDisplay, menubarWindow); XSetForeground(mainDisplay, textMenuGC, myFgPixel); if (menuFontSet != NULL || menuFontPtr != NULL) { x = menuFontWidth; y = menuFontAsc; gap = (x<<1); x += padding; y += padding; for (i=0; i < gnNumMenubarItems; i++) { len = strlen(_(gpMenubarItemInfos[i].menu_str)); w = MenuTextWidth(menuFontPtr, _(gpMenubarItemInfos[i].menu_str), len); if ((!noMinWinSize || !gnMinimalMenubar || gnAutoWrapMenubar) && x+w+padding >= menubarWindowW) { x = menuFontWidth+padding; y += menuFontHeight+padding; } if (!colorDisplay && gpMenubarItemInfos[i].cmdid == MENU_COLOR) { /* disable color menu -- at this point, threeDLook must be FALSE */ DrawMenuString(mainDisplay, menubarWindow, revGrayGC, x+padding, y+padding, _(gpMenubarItemInfos[i].menu_str), len); } else { DrawMenuString(mainDisplay, menubarWindow, textMenuGC, x+padding, y+padding, _(gpMenubarItemInfos[i].menu_str), len); } x += w+gap+padding; } } else { x = 2; y = defaultFontAsc; gap = defaultFontWidth+(defaultFontWidth>>1); x += padding; y += padding; for (i=0; i < gnNumMenubarItems; i++) { len = strlen(_(gpMenubarItemInfos[i].menu_str)); w = defaultFontWidth*len; if ((!noMinWinSize || !gnMinimalMenubar || gnAutoWrapMenubar) && x+w+padding >= menubarWindowW) { x = 2+padding; y += initialMenubarWindowH+padding; } if (!colorDisplay && gpMenubarItemInfos[i].cmdid == MENU_COLOR) { /* disable color menu -- at this point, threeDLook must be FALSE */ DrawMenuString(mainDisplay, menubarWindow, revGrayGC, x+padding, y+padding, _(gpMenubarItemInfos[i].menu_str), len); } else { DrawMenuString(mainDisplay, menubarWindow, textMenuGC, x+padding, y+padding, _(gpMenubarItemInfos[i].menu_str), len); } x += w+gap+padding; } } if (threeDLook) { bbox.ltx = 0; bbox.lty = 0; bbox.rbx = menubarWindowW; bbox.rby = menubarWindowH; TgDrawThreeDButton(mainDisplay, menubarWindow, textMenuGC, &bbox, TGBS_RAISED, 1, FALSE); } if (excludeMenubarIndex != INVALID) { struct BBRec text_bbox; int exclude_gap=((menuFontSet==NULL && menuFontPtr==NULL) ? (defaultFontWidth<<1) : (menuFontWidth<<1)); SetBBRec(&text_bbox, excludeMenubarWinBBox.ltx+2+windowPadding, excludeMenubarWinBBox.lty+2+windowPadding, excludeMenubarWinBBox.rbx-2-windowPadding-exclude_gap, excludeMenubarWinBBox.rby-2-windowPadding); /* HighLightMenubarString() doesn't need _() */ HighLightMenubarString(gpMenubarItemInfos[excludeMenubarIndex].menu_str, &text_bbox, TRUE); } } static int PullDownFromMenubar(index, x, y, text_bbox) int index, x, y; struct BBRec *text_bbox; { int rc=BAD; int exclude_gap=((menuFontSet==NULL && menuFontPtr==NULL) ? (defaultFontWidth<<1) : (menuFontWidth<<1)); while (rc == BAD) { if (index != INVALID) { /* HighLightMenubarString() doesn't need _() */ HighLightMenubarString(gpMenubarItemInfos[index].menu_str, text_bbox, TRUE); excludeMenubarWinBBox.ltx = text_bbox->ltx-2-windowPadding; excludeMenubarWinBBox.lty = text_bbox->lty-2-windowPadding; excludeMenubarWinBBox.rbx = text_bbox->rbx+exclude_gap+2+windowPadding; excludeMenubarWinBBox.rby = text_bbox->rby+2+windowPadding; excludeMenubarIndex = index; } switch (gpMenubarItemInfos[index].cmdid) { case MENU_FILE: rc = FileMenu(x, y, TRUE); break; case MENU_EDIT: rc = EditMenu(x, y, TRUE); break; case MENU_LAYOUT: rc = LayoutMenu(x, y, TRUE); break; case MENU_ARRANGE: rc = ArrangeMenu(x, y, TRUE); break; case MENU_PROPERTIES: rc = PropertiesMenu(x, y, TRUE); break; case MENU_MOVEMODE: rc = MoveModeMenu(x, y, TRUE); break; case MENU_PAGE: rc = PageMenu(x, y, TRUE); break; case MENU_PAGELAYOUT: rc = PageLayoutMenu(x, y, TRUE); break; case MENU_HORIALIGN: rc = HoriAlignMenu(x, y, TRUE); break; case MENU_VERTALIGN: rc = VertAlignMenu(x, y, TRUE); break; case MENU_FONT: rc = FontMenu(x, y, TRUE); break; case MENU_STYLE: rc = StyleMenu(x, y, TRUE); break; case MENU_SIZE: rc = SizeMenu(x, y, TRUE); break; case MENU_SHAPE: rc = ShapeMenu(x, y, TRUE); break; case MENU_STRETCHTEXT: rc = StretchableTextModeMenu(x, y, TRUE); break; case MENU_LINEDASH: rc = LineDashMenu(x, y, TRUE); break; case MENU_LINESTYLE: rc = LineStyleMenu(x, y, TRUE); break; case MENU_LINETYPE: rc = LineTypeMenu(x, y, TRUE); break; case MENU_LINEWIDTH: rc = LineWidthMenu(x, y, TRUE); break; case MENU_FILL: rc = FillMenu(x, y, TRUE); break; case MENU_PEN: rc = PenMenu(x, y, TRUE); break; case MENU_TRANSPAT: rc = TransPatModeMenu(x, y, TRUE); break; case MENU_COLOR: rc = ColorMenu(x, y, TRUE); break; case MENU_IMAGEPROC: rc = ImageProcMenu(x, y, TRUE); break; case MENU_NAVIGATE: rc = NavigateMenu(x, y, TRUE); break; case MENU_SPECIAL: rc = SpecialMenu(x, y, TRUE); break; case MENU_HELP: rc = HelpMenu(x, y, TRUE); break; case MENU_TANGRAM2: if (cmdLineTgrm2) { rc = Tangram2Menu(x, y, TRUE); } break; } if (index != INVALID) { /* HighLightMenubarString() doesn't need _() */ HighLightMenubarString(gpMenubarItemInfos[index].menu_str, text_bbox, FALSE); } if (rc == BAD) { Window root_win, child_win; int mouse_x, mouse_y, root_x, root_y; unsigned int status; XQueryPointer(mainDisplay, menubarWindow, &root_win, &child_win, &root_x, &root_y, &mouse_x, &mouse_y, &status); index = WhichMenubarItem(mouse_x, mouse_y, &x, &y, text_bbox); if (!(status & BUTTONSMASK) && index == (-1)) { return INVALID; } } else if (rc == (-4)) { return INVALID; } else if (index != MENU_FILE) { return INVALID; } } return rc; } static int curRaisedMenuItem=INVALID; int MenubarEventHandler(input) XEvent *input; { XEvent ev; int rc=INVALID; if (input->type == Expose) { XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay,menubarWindow,ExposureMask,&ev)) ; RedrawMenubarWindow(); } else if (input->type == EnterNotify || input->type == LeaveNotify) { SetMouseStatus("", "", ""); if (curRaisedMenuItem != INVALID) { struct BBRec text_bbox; GetMenubarItemInfo(curRaisedMenuItem, NULL, NULL, &text_bbox); /* HighLightMenubarString() doesn't need _() */ HighLightMenubarString(gpMenubarItemInfos[curRaisedMenuItem].menu_str, &text_bbox, FALSE); curRaisedMenuItem = INVALID; } } else if (input->type == MotionNotify) { int index; index = WhichMenubarItem(input->xmotion.x, input->xmotion.y, NULL, NULL, NULL); if (index == INVALID) { SetMouseStatusToAllNone(); } else { SetMouseStatus("", _(gpMenubarItemInfos[index].status_str), ""); } if (threeDLook) { if (index != curRaisedMenuItem) { struct BBRec text_bbox; if (curRaisedMenuItem != INVALID) { GetMenubarItemInfo(curRaisedMenuItem, NULL, NULL, &text_bbox); /* HighLightMenubarString() doesn't need _() */ HighLightMenubarString( gpMenubarItemInfos[curRaisedMenuItem].menu_str, &text_bbox, FALSE); curRaisedMenuItem = INVALID; } if (index != INVALID) { GetMenubarItemInfo(index, NULL, NULL, &text_bbox); /* HighLightMenubarString() doesn't need _() */ HighLightMenubarString(gpMenubarItemInfos[index].menu_str, &text_bbox, TRUE); curRaisedMenuItem = index; } } } XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, menubarWindow, PointerMotionMask, &ev)) ; } else if (input->type == ButtonPress) { int win_x, win_y, index; struct BBRec text_bbox; index = WhichMenubarItem(input->xbutton.x, input->xbutton.y, &win_x, &win_y, &text_bbox); if (index == INVALID) { SetMouseStatusToAllNone(); } else { SaveStatusStrings(); rc = PullDownFromMenubar(index, win_x, win_y, &text_bbox); RestoreStatusStrings(); SetMouseStatus(NULL, NULL, NULL); SetBBRec(&excludeMenubarWinBBox, -1, -1, -1, -1); excludeMenubarIndex = INVALID; } if (threeDLook) { if (index != curRaisedMenuItem) { struct BBRec text_bbox; if (curRaisedMenuItem != INVALID) { GetMenubarItemInfo(curRaisedMenuItem, NULL, NULL, &text_bbox); /* HighLightMenubarString() doesn't need _() */ HighLightMenubarString( gpMenubarItemInfos[curRaisedMenuItem].menu_str, &text_bbox, FALSE); curRaisedMenuItem = INVALID; } GetMenubarItemInfo(index, NULL, NULL, &text_bbox); /* HighLightMenubarString() doesn't need _() */ HighLightMenubarString(gpMenubarItemInfos[index].menu_str, &text_bbox, TRUE); curRaisedMenuItem = index; } } XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, menubarWindow, ButtonPressMask, &ev)) ; } return rc; } tgif-QPL-4.2.5/animate.e0000644000076400007640000000266611602233310014560 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/animate.e,v 1.6 2011/05/16 16:21:56 william Exp $ */ #ifndef _ANIMATE_E_ #define _ANIMATE_E_ #ifdef _INCLUDE_FROM_ANIMATE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_ANIMATE_C_*/ extern void AnimateSend ARGS_DECL((struct PolyRec *, int Speed, int Pixel)); extern void AnimateSel ARGS_DECL((void)); extern void AnimateFlashColor ARGS_DECL((struct ObjRec *, int Index)); extern void FlashSelColor ARGS_DECL((void)); #ifdef _INCLUDE_FROM_ANIMATE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_ANIMATE_C_*/ #endif /*_ANIMATE_E_*/ tgif-QPL-4.2.5/Tgif.tmpl-sco0000644000076400007640000000466711602233313015353 0ustar williamwilliamXCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-sco,v 1.12 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = #endif #elif ProjectX > 5 XIMPDEFINES = #endif PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_NO_IDNLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) SYS_LIBRARIES = -Bdynamic -lm -lz XCOMM SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM OpenServer 5.0.5 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM tgif-QPL-4.2.5/patchlvl.h0000644000076400007640000000176411602233312014762 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/patchlvl.h,v 1.19 2011/06/26 02:00:11 william Exp $ */ #ifndef _TGIF_PATCHLEVEL_H_ #define _TGIF_PATCHLEVEL_H_ #define TGIF_PATCHLEVEL 5 #endif /*_TGIF_PATCHLEVEL_H_*/ tgif-QPL-4.2.5/config.h0000644000076400007640000001746211602233423014417 0ustar williamwilliam/* config.h. Generated from config.h.in by configure. */ /* config.h.in. Generated from configure.ac by autoheader. */ /* Define to 1 if the `closedir' function returns void instead of `int'. */ /* #undef CLOSEDIR_VOID */ /* Define to 1 if you have the header file. */ #define HAVE_ARPA_INET_H 1 /* Define to 1 if you have the header file, and it defines `DIR'. */ #define HAVE_DIRENT_H 1 /* Define to 1 if you have the header file. */ #define HAVE_FCNTL_H 1 /* Define to 1 if you have the `fork' function. */ #define HAVE_FORK 1 /* Define to 1 if you have the `ftime' function. */ #define HAVE_FTIME 1 /* Define to 1 if you have the `getcwd' function. */ #define HAVE_GETCWD 1 /* Define to 1 if you have the `gethostbyname' function. */ #define HAVE_GETHOSTBYNAME 1 /* Define to 1 if you have the `gethostname' function. */ #define HAVE_GETHOSTNAME 1 /* Define to 1 if you have the `gettimeofday' function. */ #define HAVE_GETTIMEOFDAY 1 /* Define to 1 if you have the header file. */ #define HAVE_INTTYPES_H 1 /* Define to 1 if you have the `dl' library (-ldl). */ #define HAVE_LIBDL 1 /* Define to 1 if you have the `idn' library (-lidn). */ #define HAVE_LIBIDN 1 /* Define to 1 if you have the header file. */ #define HAVE_LIBINTL_H 1 /* Define to 1 if you have the `m' library (-lm). */ #define HAVE_LIBM 1 /* Define to 1 if you have the `nsl' library (-lnsl). */ #define HAVE_LIBNSL 1 /* Define to 1 if you have the `pthread' library (-lpthread). */ #define HAVE_LIBPTHREAD 1 /* Define to 1 if you have the `socket' library (-lsocket). */ /* #undef HAVE_LIBSOCKET */ /* Define to 1 if you have the `X11' library (-lX11). */ #define HAVE_LIBX11 1 /* Define to 1 if you have the `Xt' library (-lXt). */ #define HAVE_LIBXT 1 /* Define to 1 if you have the `z' library (-lz). */ #define HAVE_LIBZ 1 /* Define to 1 if `lstat' has the bug that it succeeds when given the zero-length file name argument. */ /* #undef HAVE_LSTAT_EMPTY_STRING_BUG */ /* Define to 1 if your system has a GNU libc compatible `malloc' function, and to 0 otherwise. */ #define HAVE_MALLOC 1 /* Define to 1 if you have the `memmove' function. */ #define HAVE_MEMMOVE 1 /* Define to 1 if you have the header file. */ #define HAVE_MEMORY_H 1 /* Define to 1 if you have the `memset' function. */ #define HAVE_MEMSET 1 /* Define to 1 if you have the `mkdir' function. */ #define HAVE_MKDIR 1 /* Define to 1 if you have the header file, and it defines `DIR'. */ /* #undef HAVE_NDIR_H */ /* Define to 1 if you have the header file. */ #define HAVE_NETDB_H 1 /* Define to 1 if you have the header file. */ #define HAVE_NETINET_IN_H 1 /* Define to 1 if you have the `pow' function. */ #define HAVE_POW 1 /* Define to 1 if you have the `putenv' function. */ #define HAVE_PUTENV 1 /* Define to 1 if your system has a GNU libc compatible `realloc' function, and to 0 otherwise. */ #define HAVE_REALLOC 1 /* Define to 1 if you have the `select' function. */ #define HAVE_SELECT 1 /* Define to 1 if you have the `setlocale' function. */ #define HAVE_SETLOCALE 1 /* Define to 1 if you have the `socket' function. */ #define HAVE_SOCKET 1 /* Define to 1 if you have the `sqrt' function. */ #define HAVE_SQRT 1 /* Define to 1 if `stat' has the bug that it succeeds when given the zero-length file name argument. */ /* #undef HAVE_STAT_EMPTY_STRING_BUG */ /* Define to 1 if you have the header file. */ #define HAVE_STDINT_H 1 /* Define to 1 if you have the header file. */ #define HAVE_STDLIB_H 1 /* Define to 1 if you have the `strchr' function. */ #define HAVE_STRCHR 1 /* Define to 1 if you have the header file. */ #define HAVE_STRINGS_H 1 /* Define to 1 if you have the header file. */ #define HAVE_STRING_H 1 /* Define to 1 if you have the `strpbrk' function. */ #define HAVE_STRPBRK 1 /* Define to 1 if you have the `strrchr' function. */ #define HAVE_STRRCHR 1 /* Define to 1 if you have the `strstr' function. */ #define HAVE_STRSTR 1 /* Define to 1 if you have the `strtol' function. */ #define HAVE_STRTOL 1 /* Define to 1 if you have the header file, and it defines `DIR'. */ /* #undef HAVE_SYS_DIR_H */ /* Define to 1 if you have the header file. */ #define HAVE_SYS_FILE_H 1 /* Define to 1 if you have the header file. */ #define HAVE_SYS_IOCTL_H 1 /* Define to 1 if you have the header file, and it defines `DIR'. */ /* #undef HAVE_SYS_NDIR_H */ /* Define to 1 if you have the header file. */ #define HAVE_SYS_SELECT_H 1 /* Define to 1 if you have the header file. */ #define HAVE_SYS_SOCKET_H 1 /* Define to 1 if you have the header file. */ #define HAVE_SYS_STAT_H 1 /* Define to 1 if you have the header file. */ #define HAVE_SYS_TIMEB_H 1 /* Define to 1 if you have the header file. */ #define HAVE_SYS_TIME_H 1 /* Define to 1 if you have the header file. */ #define HAVE_SYS_TYPES_H 1 /* Define to 1 if you have that is POSIX.1 compatible. */ #define HAVE_SYS_WAIT_H 1 /* Define to 1 if you have the header file. */ #define HAVE_UNISTD_H 1 /* Define to 1 if you have the `vfork' function. */ #define HAVE_VFORK 1 /* Define to 1 if you have the header file. */ /* #undef HAVE_VFORK_H */ /* Define to 1 if `fork' works. */ #define HAVE_WORKING_FORK 1 /* Define to 1 if `vfork' works. */ #define HAVE_WORKING_VFORK 1 /* Define to 1 if `lstat' dereferences a symlink specified with a trailing slash. */ #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1 /* Name of package */ #define PACKAGE "tgif" /* Define to the address where bug reports for this package should be sent. */ #define PACKAGE_BUGREPORT "bill.cheng@acm.org" /* Define to the full name of this package. */ #define PACKAGE_NAME "tgif" /* Define to the full name and version of this package. */ #define PACKAGE_STRING "tgif 4.2.5" /* Define to the one symbol short name of this package. */ #define PACKAGE_TARNAME "tgif" /* Define to the version of this package. */ #define PACKAGE_VERSION "4.2.5" /* Define as the return type of signal handlers (`int' or `void'). */ #define RETSIGTYPE void /* Define to the type of arg 1 for `select'. */ #define SELECT_TYPE_ARG1 int /* Define to the type of args 2, 3 and 4 for `select'. */ #define SELECT_TYPE_ARG234 (fd_set *) /* Define to the type of arg 5 for `select'. */ #define SELECT_TYPE_ARG5 (struct timeval *) /* Define to 1 if you have the ANSI C header files. */ #define STDC_HEADERS 1 /* Define to 1 if you can safely include both and . */ #define TIME_WITH_SYS_TIME 1 /* Version number of package */ #define VERSION "4.2.5" /* Define for Solaris 2.5.1 so the uint32_t typedef from , , or is not used. If the typedef was allowed, the #define below would cause a syntax error. */ /* #undef _UINT32_T */ /* Define to empty if `const' does not conform to ANSI C. */ /* #undef const */ /* Define to rpl_malloc if the replacement function should be used. */ /* #undef malloc */ /* Define to `int' if does not define. */ /* #undef mode_t */ /* Define to `int' if does not define. */ /* #undef pid_t */ /* Define to rpl_realloc if the replacement function should be used. */ /* #undef realloc */ /* Define to `unsigned int' if does not define. */ /* #undef size_t */ /* Define to the type of an unsigned integer type of width exactly 16 bits if such a type exists and the standard includes do not define it. */ /* #undef uint16_t */ /* Define to the type of an unsigned integer type of width exactly 32 bits if such a type exists and the standard includes do not define it. */ /* #undef uint32_t */ /* Define as `fork' if `vfork' does not work. */ /* #undef vfork */ tgif-QPL-4.2.5/expr.e0000644000076400007640000000250111602233311014105 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/expr.e,v 1.6 2011/05/16 16:21:57 william Exp $ */ #ifndef _EXPR_E_ #define _EXPR_E_ #ifdef _INCLUDE_FROM_EXPR_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_EXPR_C_*/ extern void CleanUpExpr ARGS_DECL((void)); extern int ExprAtomType ARGS_DECL((char*)); extern int EvalExpr ARGS_DECL((char*, struct VRec *)); #ifdef _INCLUDE_FROM_EXPR_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_EXPR_C_*/ #endif /*_EXPR_E_*/ tgif-QPL-4.2.5/vms_comp.c0000644000076400007640000004057711602233313014771 0ustar williamwilliam/* * Author: George Carrette, in November, 1990. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/vms_comp.c,v 1.1 2004/06/18 23:19:10 william Exp $ */ /* vms_comp routines, generally useful functions to aid in porting/running various common Unix style code under VAX/VMS. This code has been sufficient to run programs from sources such as COMP.SOURCES.X, in particular XV and TGIF. Some routines are for direct unix compatibility and have the same exact calling sequence and names as in various versions of unix. Some are vms specific and are intended to be called from generally unix-style programs inside a minimal amount of {#ifdef VMS #endif} conditionalized code. ** Written by George Carrette, in November, 1990. ** Includes modified VMS readdir() routines. ** Written by Rich $alz, in August, 1990. ** some additions by Rolf Niepraschk, niepraschk@ptb.de, 1997/11/24 To use: #include "vms_comp.h" Used generally where you see #include . Contains: bcopy ... full functionality rindex ... full functionality lstat ... full functionality, just a name change fork ... dummy, returns 1. getwd ... full functionality, returns unix style pathname. unlink ... full functionality(?), just a name change popen ... ?. pclose ... ?. opendir ... almost full functionality. closedir ... almost full functionality. readdir ... almost full functionality. telldir ... almost full functionality. seekdir ... almost full functionality. ioctl ... dummy, returns 0. -- RN -- fcntl ... dummy, returns 0. -- RN -- do_vms_wildcard ... non-unix. but put this into your MAIN program to get limited wildcard processing on the command line. Currently returns vms style pathnames. */ /* some of these unix compat functions are just dummy versions to get the code running. some are fully functional. the use of fork and popen/pclose in particular assume unix command shell as used in the main code. And since this sort of thing is generally done for the purposes such as printing, spooling mail, etc, which are best done in considerably different ways under VMS, it is better to dummy this stuff up now and then restructure the code that calls this sort of thing to be more abstract/subroutinized and then conditionalize it specifically for VMS */ #include "vms_comp.h" #ifdef VMS #if 0 /* RN */ bcopy(x,y,n) char *x,*y; long n; {memmove(x,y,n);} char *rindex(p,c) char *p; int c; {return(strrchr(p,c));} int lstat(x,y) {return(stat(x,y));} #endif /* RN */ fork() {return(1);} static char *getwd_tmp = NULL; char *getwd(p) char *p; {int c; char *l1,*l2; if (getwd_tmp == NULL) getwd_tmp = (char *) malloc(512); l1 = getwd_tmp; getcwd(l1,512); l2 = p; *l2++ = '/'; while((c = *l1++)) switch(c) {case '.': case '[': *l2++ = '/'; break; case ']': case ':': break; default: *l2++ = c;} *l2 = 0; return(p);} #if 0 /* RN */ unlink(p) char *p; {delete(p);} #endif /* RN */ static vms_wild_putargs(),vms_wild_put_one(),vms_wild_put_wild(); static struct dsc$descriptor *set_dsc(); static struct dsc$descriptor *set_dsc_cst(); do_vms_wildcard(pargc,pargv) int *pargc; char ***pargv; {int j,vsize; int argc; char **argv; argc = *pargc; argv = *pargv; *pargc = 0; vsize = 3; *pargv = (char **) malloc(sizeof (char *) * vsize); for(j=0;jnext) if (l->fp == fp) return(l); return(NULL);} void p_describe(fp) FILE *fp; {struct popen_cell *cell; if (!(cell = find_popen_cell(fp))) {printf("File pointer is not from popen, or it has been closed\n"); return;} printf("FILE *fp = %08X\n",cell->fp); printf("char *mbx_name = %s\n",cell->mbx_name); printf("short mbx_chan = %d\n",cell->mbx_chan); printf("long pid = %08X\n",cell->pid); printf("long completed = %d\n",cell->completed); printf("long comp_status = %d\n",cell->comp_status); printf("struct popen_cell *next = %08X\n",cell->next); printf("struct popen_cell *prev = %08X\n",cell->prev);} static void proc_exit_ast(cell) struct popen_cell *cell; {cell->completed = 1;} static void pclose_cleanup(cell) struct popen_cell *cell; {sys$dassgn(cell->mbx_chan); free(cell->mbx_name); if (!cell->completed) sys$delprc(&cell->pid,0); memset(cell,0,sizeof(struct popen_cell)); free(cell);} static void pclose_delq(cell) struct popen_cell *cell; {if (cell->prev) {cell->prev->next = cell->next; if (cell->next) cell->next->prev = cell->prev;} else {popen_list = cell->next; if (cell->next) cell->next->prev = NULL;}} static void popen_push(cell) struct popen_cell *cell; {if (popen_list) popen_list->prev = cell; cell->prev = NULL; cell->next = popen_list; popen_list = cell;} /* 17-APR-1991 -GJC@MITECH.COM version 1.0 Implement unix popen and pclose in vms by using mailboxes. */ /* popen starts a subprocess and opens a pipe to its stdout or stdin (mode = "r" its stdout, = "w" its stdin) */ FILE *popen(command,mode) char *command,*mode; {char *temp; struct popen_cell *cell; int readp,n,mask,ret; char *name,*prompt,*in,*out; struct dsc$descriptor comm_d,in_d,out_d,name_d,prompt_d; if (strcmp(mode,"r") == 0) readp = 1; else if (strcmp(mode,"w") == 0) readp = 0; else return(NULL); temp = mktemp("POPEN_MB_XXXXXXXXXX"); n = strlen(temp); cell = (struct popen_cell *) malloc(sizeof(struct popen_cell)); cell->mbx_name = (char *) malloc(n+1); strcpy(cell->mbx_name,temp); if ((cell->mbx_chan = create_mbx(cell->mbx_name)) < 0) {cell->completed = 1; pclose_cleanup(cell); return(NULL);} if (readp) {in = "NL:"; out = cell->mbx_name;} else {in = cell->mbx_name; out = "NL:";} name = 0; prompt = 0; mask = CLI$M_NOWAIT; cell->completed = 0; ret = lib$spawn((command) ? set_dsc_cst(&comm_d,command) : 0, (in) ? set_dsc_cst(&in_d,in) : 0, (out) ? set_dsc_cst(&out_d,out) : 0, &mask, (name) ? set_dsc_cst(&name_d,name) : 0, &cell->pid, &cell->comp_status, 0, /* event flag */ proc_exit_ast, cell, (prompt) ? set_dsc_cst(&prompt_d,prompt) : 0, 0 /* cli */ ); if (ret != SS$_NORMAL) {cell->completed = 1; pclose_cleanup(cell); return(NULL);} if (!(cell->fp = fopen(cell->mbx_name,mode))) {pclose_cleanup(cell); return(NULL);} popen_push(cell); return(cell->fp);} pclose(fp) FILE *fp; {int i; struct popen_cell *cell; i = fclose(fp); if (cell = find_popen_cell(fp)) {pclose_delq(cell); pclose_cleanup(cell);} return(i);} static int create_mbx(name) char *name; {short chan; int prmflg,maxmsg,bufquo,promsk,acmode,iflag,retval; struct dsc$descriptor lognam; prmflg = 0; maxmsg = mailbox_size; bufquo = mailbox_byte_quota; promsk = mailbox_protection_mask; acmode = 0; set_dsc_cst(&lognam,name); retval = sys$crembx(prmflg,&chan,maxmsg,bufquo,promsk,acmode,&lognam); if (retval != SS$_NORMAL) return(-1); return(chan);} #endif /* __VMS_VER < 70000000 */ /* RN */ /* ** VMS readdir() routines. ** Written by Rich $alz, in August, 1990. ** This code has no copyright. */ /* 12-NOV-1990 added d_namlen field and special case "." name -GJC@MITECH.COM added unlink and getwd, also typically needed to port unix style code that does directory manipulation. 26-MAR-1991 added lowercasing of d_name. -GJC@MITECH.COM typically strcmp and other operations may be done on the names. added a lot more hair to fixunixname. */ /* Uncomment the next line to get a test routine. */ /*#define TEST*/ /* Number of elements in vms_versions array */ #define VERSIZE(e) (sizeof e->vms_versions / sizeof e->vms_versions[0]) static char *fixunixname(name) char *name; /* This handles special cases such as "." and ".." and also undoes some of the stuff that getwd does. */ {FILE *f; char *p; static char *tmp = NULL; if (strcmp(".",name) == 0) return(""); if (strcmp("..",name) == 0) return("[-]"); if (strchr(name,':') || strchr(name,'[') || strchr(name,']')) return(name); if (tmp == NULL) tmp = (char *) malloc(128); if (name[0] != '/') /* foo/bar/baz => [.foo.bar.baz] */ {strcpy(tmp,"[."); strcat(tmp,name); p = &tmp[strlen(tmp) - 1]; if (*p == '/') *p = 0; strcat(tmp,"]"); for(p=tmp;*p;++p) if (*p == '/') *p = '.'; return(tmp);} if ((name[0] == '/') && !strchr(name+1,'/')) /* /foo => foo:[000000] */ {strcpy(tmp,name+1); strcat(tmp,":[000000]"); return(tmp);} /* /foo/bar/baz => foo:[bar.baz] */ p = strchr(name+1,'/'); *p = 0; strcpy(tmp,name+1); strcat(tmp,":["); strcat(tmp,p+1); p = &tmp[strlen(tmp) - 1]; if (*p == '/') *p = 0; strcat(tmp,"]"); for(p=tmp;*p;++p) if (*p == '/') *p = '.'; return(tmp);} /* ** Open a directory, return a handle for later use. */ static char *opendir_pat = "*.*"; DIR *opendir(name) char *name; {DIR *dd; /* Get memory for the handle, and the pattern. */ if ((dd = (DIR *)malloc(sizeof *dd)) == NULL) {errno = ENOMEM; return NULL;} name = fixunixname(name); dd->pattern = (char *) malloc((unsigned int)(strlen(name) + strlen(opendir_pat) + 1)); if (dd->pattern == NULL) {free((char *)dd); errno = ENOMEM; return NULL;} /* Fill in the fields; mainly playing with the descriptor. */ strcpy(dd->pattern,name); strcat(dd->pattern,opendir_pat); dd->context = 0; dd->vms_wantversions = 0; set_dsc_cst(&dd->pat,dd->pattern); return dd;} /* ** Set the flag to indicate we want versions or not. */ void vmsreaddirversions(dd, flag) DIR *dd; int flag; {dd->vms_wantversions = flag;} /* ** Free up an opened directory. */ void closedir(dd) DIR *dd; {if (dd->context) lib$find_file_end(&dd->context); free(dd->pattern); free((char *)dd);} /* ** Collect all the version numbers for the current file. */ static void collectversions(dd) DIR *dd; {struct dsc$descriptor_s pat; struct dsc$descriptor_s res; struct dirent *e; char *p; char buff[sizeof dd->entry.d_name]; int i; char *text; long context; /* Convenient shorthand. */ e = &dd->entry; /* Add the version wildcard, ignoring the "*.*" put on before */ i = strlen(dd->pattern); text = (char *) malloc((unsigned int)(i + strlen(e->d_name)+ 2 + 1)); if (text == NULL) return; (void)strcpy(text, dd->pattern); text[i - strlen(opendir_pat)] = 0; strcat(text,e->d_name); strcat(text,";*"); /* Set up the pattern descriptor. */ set_dsc_cst(&pat,text); /* Set up result descriptor. */ set_dsc(&res,buff,sizeof buff - 2); /* Read files, collecting versions. */ for (context = 0; e->vms_verscount < VERSIZE(e); e->vms_verscount++) {if (lib$find_file(&pat, &res, &context) == RMS$_NMF || context == 0) break; buff[sizeof buff - 1] = '\0'; if (p = strchr(buff, ';')) e->vms_versions[e->vms_verscount] = atoi(p + 1); else e->vms_versions[e->vms_verscount] = -1;} lib$find_file_end(&context); free(text);} static strtolower(s) char *s; {int c; char *p; p = s; while(c = *p) {if ((c > 'Z') || (c < 'A')) ++p; else *p++ = c + ('a' - 'A');}} /* ** Read the next entry from the directory. */ struct dirent *readdir(dd) DIR *dd; {struct dsc$descriptor_s res; char *p; char buff[sizeof dd->entry.d_name]; int i; int status; /* Set up result descriptor, and get next file. */ set_dsc(&res,buff,sizeof buff - 2); status = lib$find_file(&dd->pat, &res, &dd->context); if (status == RMS$_NMF || dd->context == 0L) /* None left... */ return NULL; if ((status != SS$_NORMAL) && (status != RMS$_NORMAL)) /* May be something like RMS$_SYN for bad syntax patterns */ return NULL; /* Force the buffer to end with a NUL. */ buff[sizeof buff - 1] = '\0'; for (p = buff; !isspace(*p); p++); *p = '\0'; /* Skip any directory component and just copy the name. */ if (p = strchr(buff, ']')) (void)strcpy(dd->entry.d_name, p + 1); else (void)strcpy(dd->entry.d_name, buff); /* Clobber the version. */ if (p = strchr(dd->entry.d_name, ';')) *p = '\0'; dd->entry.d_namlen = strlen(dd->entry.d_name); dd->entry.vms_verscount = 0; if (dd->vms_wantversions) collectversions(dd); /* force to lowercase, since many unix programs look for specific file extensions, etc, which are almost always in lowercase */ strtolower(dd->entry.d_name); return &dd->entry;} /* ** Return something that can be used in a seekdir later. */ long telldir(dd) DIR *dd; {return dd->context;} /* ** Return to a spot where we used to be. */ void seekdir(dd, pos) DIR *dd; long pos; {dd->context = pos;} int ioctl(int fildes, int request,... /* arg */) { fprintf(stderr, "\"ioctl\" not implemented (VMS)\n"); return 0; } int fcntl (int filedes, int request , int argument) { fprintf(stderr, "\"fcntl\" not implemented (VMS)\n"); return 0; } #ifdef TEST main() { char buff[256]; DIR *dd; struct dirent *dp; int i; int j; for ( ; ; ) { printf("\n\nEnter dir: "); (void)fflush(stdout); (void)gets(buff); if (buff[0] == '\0') break; if ((dd = opendir(buff)) == NULL) { perror(buff); continue; } /* Print the directory contents twice, the second time print * the versions. */ for (i = 0; i < 2; i++) { while (dp = readdir(dd)) { printf("%s%s", i ? "\t" : " ", dp->d_name); for (j = 0; j < dp->vms_verscount; j++) printf(" %d", dp->vms_versions[j]); printf("\n"); } rewinddir(dd); vmsreaddirversions(dd, 1); } closedir(dd); } exit(0); } #endif /* TEST */ #endif /* VMS */ tgif-QPL-4.2.5/ftp.c0000644000076400007640000004631611602233311013732 0ustar williamwilliam/* * Some code in this file is derived from the public domain code in * WWW/Library/Implementation/HTFTP.c distributed with lynx-2.2, * whose original author is Tim Berners-lee . * * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/ftp.c,v 1.10 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_FTP_C_ #include "tgifdefs.h" #include "dialog.e" #include "file.e" #include "ftp.e" #include "msg.e" #include "remote.e" #include "strtbl.e" #include "tcp.e" #include "util.e" int debugFtp=0; static int gnReadyToReceiveData=FALSE; void FtpFreeBuf(buf) char *buf; { free(buf); } void FtpDebug(val) int val; { debugFtp = val; } int FtpDoConnect(psz_host, us_port, pn_socket) char *psz_host; int us_port, *pn_socket; { int rc, len=strlen(psz_host)+80; char *msg=(char*)malloc((len+1)*sizeof(char)); if (msg == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } sprintf(msg, TgLoadCachedString(CSTID_MAKING_CONN_TO_HOST), "FTP", psz_host); ShowRemoteStatus(msg); rc = TcpDoConnect(psz_host, us_port, pn_socket); if (rc == TG_REMOTE_STATUS_OK) { sprintf(msg, TgLoadCachedString(CSTID_CONN_TO_HOST_ESTABLISHED), "FTP", psz_host); } else { sprintf(msg, TgLoadString(STID_FAIL_TO_CONN_TO_HOST), "FTP", psz_host); } ShowRemoteStatus(msg); free(msg); return rc; } static char *AppendSimpleString(buf, value) char *buf, *value; { int cur_len=(buf==NULL ? 0 : strlen(buf)); if (value == NULL) { int new_len=cur_len+2; if (buf == NULL) { buf = (char*)malloc((new_len+1)*sizeof(char)); } else { buf = (char*)realloc(buf, new_len+1); } if (buf == NULL) return NULL; sprintf(&buf[cur_len], "\r\n"); } else { int new_len=cur_len+strlen(value)+2; if (buf == NULL) { buf = (char*)malloc((new_len+1)*sizeof(char)); } else { buf = (char*)realloc(buf, new_len+1); } if (buf == NULL) return NULL; sprintf(&buf[cur_len], "%s\r\n", value); } return buf; } int FtpDoWrite(n_socket, psz_path) int n_socket; char *psz_path; { int status=TG_REMOTE_STATUS_OK; if (psz_path == NULL) return TG_REMOTE_STATUS_OK; status = TcpDoWrite(n_socket, psz_path, (int)strlen(psz_path)); return status; } static void FtpDumpResponse(func_name, buf) char *func_name, *buf; { char *c_ptr=strchr(buf, '\n'), *line_ptr=buf; FILE *fp=stdout; /* debug, do not translate */ if (debugFtp > 0) fprintf(fp, "In %s:\n", func_name); while (c_ptr != NULL) { char *prev_ptr=c_ptr; if (prev_ptr != line_ptr && *(--prev_ptr) == '\r') { *prev_ptr = '\0'; } else { prev_ptr = NULL; *c_ptr = '\0'; } if (debugFtp > 0) fprintf(fp, " %s\n", line_ptr); if (prev_ptr == NULL) { *c_ptr = '\n'; } else { *prev_ptr = '\r'; } line_ptr = &c_ptr[1]; c_ptr = strchr(line_ptr, '\n'); } if (line_ptr != NULL) { int len=strlen(line_ptr); if (len > 0 && line_ptr[len-1] == '\r') { line_ptr[len-1] = '\0'; if (debugFtp > 0) fprintf(fp, " %s\n", line_ptr); line_ptr[len-1] = '\r'; } else { if (debugFtp > 0) fprintf(fp, " %s\n", line_ptr); } } } #define MIN_READ_SIZE 0x100 static int ftpReadData=FALSE; int FtpDoRead(n_socket, ppsz_buf, pn_buf_sz) int n_socket, *pn_buf_sz; char **ppsz_buf; { int buf_sz=0x400, len=0, end_of_file=FALSE; int rc=(-1); char *buf=(char*)malloc(buf_sz*sizeof(char)); if (pn_buf_sz != NULL) *pn_buf_sz = 0; *ppsz_buf = NULL; if (buf == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } CleanUpDownloadStats(); do { int bytes_read; char progress_buf[MAXSTRING]; *progress_buf = '\0'; if (buf_sz - len < MIN_READ_SIZE) { buf_sz += 0x400; if ((buf=(char*)realloc(buf, buf_sz)) == NULL) { FailAllocMessage(); if (PRTGIF && cmdLineDumpURL && cmdLineDumpURLShowStatus && pn_buf_sz != NULL) { fprintf(stderr, "\n"); } return TG_REMOTE_STATUS_MEM; } } bytes_read = read(n_socket, &buf[len], buf_sz-len-1); /* debug, do not translate */ if (debugFtp >= 3) fprintf(stderr, " read %1d bytes\n", bytes_read); if (bytes_read <= 0) { if (bytes_read < 0 && (errno == ENOTCONN || errno == ECONNRESET || errno == EPIPE)) { free(buf); fprintf(stderr, TgLoadString(STID_NETWORK_READ_ERROR), "FTP"); fprintf(stderr, "\n"); if (PRTGIF && cmdLineDumpURL && cmdLineDumpURLShowStatus && pn_buf_sz != NULL) { fprintf(stderr, "\n"); } return TG_REMOTE_STATUS_READ; } else if (bytes_read < 0) { free(buf); fprintf(stderr, TgLoadString(STID_NETWORK_ERROR), "FTP"); fprintf(stderr, "\n"); if (PRTGIF && cmdLineDumpURL && cmdLineDumpURLShowStatus && pn_buf_sz != NULL) { fprintf(stderr, "\n"); } return TG_REMOTE_STATUS_NET; } if (!UpdateDownloadStats(0, progress_buf)) { *progress_buf = '\0'; } end_of_file = TRUE; } else { if (!UpdateDownloadStats(bytes_read, progress_buf)) { *progress_buf = '\0'; } len += bytes_read; } if (!end_of_file && UserAbortComm()) { if (buf != NULL) free(buf); sprintf(gszMsgBox, TgLoadString(STID_CONN_ABORT_BY_USER), "FTP"); ShowRemoteStatus(gszMsgBox); if (PRTGIF && cmdLineDumpURL && cmdLineDumpURLShowStatus && pn_buf_sz != NULL) { fprintf(stderr, "\n"); } return TG_REMOTE_STATUS_INTR; } else { char msg[MAXSTRING], *c_ptr; int cont_code=(-1); /* do not translate -- program constants */ sprintf(msg, "FTP: %1d bytes %s...", len, (*progress_buf=='\0' ? "" : progress_buf)); ShowRemoteStatus(msg); if (PRTGIF && cmdLineDumpURL && cmdLineDumpURLShowStatus && pn_buf_sz != NULL) { /* do not translate -- program constants */ fprintf(stderr, "FTP: %1d bytes %s...\r", len, (*progress_buf=='\0' ? "" : progress_buf)); } buf[len] = '\0'; if (!ftpReadData) { for (c_ptr=buf; *c_ptr != '\0'; c_ptr++) { char cont_ch; if (sscanf(c_ptr, "%d%c", &rc, &cont_ch) == 2) { if (cont_code == (-1)) { if (cont_ch == '-') { cont_code = rc; } else { end_of_file = TRUE; break; } } else if (cont_code == rc && cont_ch == ' ') { cont_code = (-1); end_of_file = TRUE; break; } } c_ptr = strchr(c_ptr, '\n'); if (c_ptr == NULL) break; } } } } while (!end_of_file); if (PRTGIF && cmdLineDumpURL && cmdLineDumpURLShowStatus && pn_buf_sz != NULL) { fprintf(stderr, "\n"); } /* debug, do not translate */ if (debugFtp >= 2) fprintf(stderr, " rc = %1d in FtpDoRead().\n", rc); if (rc == 421) { free(buf); fprintf(stderr, TgLoadString(STID_CONN_TERM_BY_SERVER), "FTP"); fprintf(stderr, "\n"); return TG_REMOTE_STATUS_TERM; } else { buf[len] = '\0'; *ppsz_buf = buf; if (pn_buf_sz != NULL) *pn_buf_sz = len; return TG_REMOTE_STATUS_OK; } } static int FtpSendSimpleCmd(n_socket, value) int n_socket; char *value; { int status=TG_REMOTE_STATUS_OK; char *cmd; if ((cmd=AppendSimpleString(NULL, value)) == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } status = FtpDoWrite(n_socket, cmd); free(cmd); return status; } static int FtpSendUserName(n_socket, value) int n_socket; char *value; { return FtpSendSimpleCmd(n_socket, value); } static int FtpSendPassword(n_socket, password) int n_socket; char *password; { return FtpSendSimpleCmd(n_socket, password); } static int FtpSendType(n_socket, type_cmd) int n_socket; char *type_cmd; { return FtpSendSimpleCmd(n_socket, type_cmd); } static int FtpSendRetrieveCmd(n_socket, psz_path) int n_socket; char *psz_path; { int status=TG_REMOTE_STATUS_OK; char *cmd; /* do not translate -- program constants */ cmd = (char*)malloc((strlen("RETR")+1+strlen(psz_path)+2+1)*sizeof(char)); if (cmd == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } /* do not translate -- program constants */ sprintf(cmd, "RETR %s\r\n", psz_path); status = FtpDoWrite(n_socket, cmd); free(cmd); return status; } static int FtpSendListCmd(n_socket) int n_socket; { /* do not translate -- program constants */ return FtpSendSimpleCmd(n_socket, "NLST"); } static int FtpSendCWDCmd(n_socket, psz_path) int n_socket; char *psz_path; { int status=TG_REMOTE_STATUS_OK; char *cmd; /* do not translate -- program constants */ cmd = (char*)malloc((strlen("CWD")+1+strlen(psz_path)+2+1)*sizeof(char)); if (cmd == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } /* do not translate -- program constants */ sprintf(cmd, "CWD %s\r\n", psz_path); status = FtpDoWrite(n_socket, cmd); free(cmd); return status; } static int FtpSendPortCmd(n_socket, pn_data_socket) int n_socket, *pn_data_socket; { struct sockaddr_in soc_address; struct sockaddr_in *sin=(&soc_address); char port_cmd[20]; *pn_data_socket = socket(AF_INET, SOCK_STREAM, IPPROTO_TCP); if (*pn_data_socket < 0) { fprintf(stderr, TgLoadString(STID_FAIL_TO_OPEN_DATA_SOCKET), "FTP"); fprintf(stderr, "\n"); return TG_REMOTE_STATUS_FILE; } sin->sin_family = AF_INET; sin->sin_addr.s_addr = INADDR_ANY; { int rc, addr_sz; addr_sz = sizeof(soc_address); rc = getsockname(n_socket, (struct sockaddr *)&soc_address, (void*)(&addr_sz)); if (rc < 0) { close(*pn_data_socket); *pn_data_socket = (-1); return TG_REMOTE_STATUS_HOST; } soc_address.sin_port = 0; rc = bind(*pn_data_socket, (struct sockaddr*)&soc_address, sizeof(soc_address)); if (rc < 0) { close(*pn_data_socket); *pn_data_socket = (-1); return TG_REMOTE_STATUS_HOST; } addr_sz = sizeof(soc_address); rc = getsockname(*pn_data_socket, (struct sockaddr *)&soc_address, (void*)(&addr_sz)); if (rc < 0) { close(*pn_data_socket); *pn_data_socket = (-1); return TG_REMOTE_STATUS_HOST; } } /* do not translate -- program constants */ sprintf(port_cmd, "PORT %d,%d,%d,%d,%d,%d", (int)*((unsigned char *)(&sin->sin_addr)+0), (int)*((unsigned char *)(&sin->sin_addr)+1), (int)*((unsigned char *)(&sin->sin_addr)+2), (int)*((unsigned char *)(&sin->sin_addr)+3), (int)*((unsigned char *)(&sin->sin_port)+0), (int)*((unsigned char *)(&sin->sin_port)+1)); if (listen(*pn_data_socket, 1) < 0) { close(*pn_data_socket); *pn_data_socket = (-1); return TG_REMOTE_STATUS_HOST; } return FtpSendSimpleCmd(n_socket, port_cmd); } static int FtpReadCmd(n_socket, ppsz_buf, pn_cmd) int n_socket, *pn_cmd; char **ppsz_buf; /* if returns TG_REMOTE_STATUS_OK, caller must call FtpFreeBuf(*ppsz_buf) */ { int status; if ((status=FtpDoRead(n_socket, ppsz_buf, NULL)) == TG_REMOTE_STATUS_OK) { status = TG_REMOTE_STATUS_FORMAT; if (*ppsz_buf != NULL) { if (sscanf(*ppsz_buf, "%d", pn_cmd) == 1) { *pn_cmd = (int)(*pn_cmd / 100); status = TG_REMOTE_STATUS_OK; } } } if (status != TG_REMOTE_STATUS_OK && *ppsz_buf != NULL) { FtpFreeBuf(*ppsz_buf); *ppsz_buf = NULL; } return status; } static int FtpLogin(n_socket) int n_socket; { char *buf=NULL; int status, ftp_cmd=(-1); if ((status=FtpReadCmd(n_socket, &buf, &ftp_cmd)) == TG_REMOTE_STATUS_OK) { /* debug, do not translate */ FtpDumpResponse("FtpLogin", buf); status = TG_REMOTE_STATUS_FORMAT; if (ftp_cmd == 2) { /* do not translate -- program constants */ status = FtpSendUserName(n_socket, "USER anonymous"); } FtpFreeBuf(buf); } return status; } static char SZ_PASSWORD[128]; static int gnPasswordInitialized=FALSE; static void InitPassword() { char user_name[128]; if (gnPasswordInitialized) return; gnPasswordInitialized = TRUE; GetUserID(user_name, sizeof(user_name)); /* do not translate -- program constants */ sprintf(SZ_PASSWORD, "PASS %s", user_name); } static int FtpPassword(n_socket) int n_socket; { char *buf=NULL; int status, ftp_cmd=(-1); if ((status=FtpReadCmd(n_socket, &buf, &ftp_cmd)) == TG_REMOTE_STATUS_OK) { /* debug, do not translate */ FtpDumpResponse("FtpPassword", buf); status = TG_REMOTE_STATUS_FORMAT; if (ftp_cmd == 3) { InitPassword(); status = FtpSendPassword(n_socket, SZ_PASSWORD); } FtpFreeBuf(buf); } return status; } static int FtpPort(n_socket, pn_data_socket) int n_socket, *pn_data_socket; { char *buf=NULL; int status, ftp_cmd=(-1); if ((status=FtpReadCmd(n_socket, &buf, &ftp_cmd)) == TG_REMOTE_STATUS_OK) { /* debug, do not translate */ FtpDumpResponse("FtpPort", buf); status = TG_REMOTE_STATUS_FORMAT; if (ftp_cmd == 2) { status = FtpSendPortCmd(n_socket, pn_data_socket); } else if (ftp_cmd == 3) { FtpFreeBuf(buf); /* do not translate -- program constants */ status = FtpSendPassword(n_socket, "ACCT noaccount"); if ((status=FtpReadCmd(n_socket, &buf, &ftp_cmd)) == TG_REMOTE_STATUS_OK) { /* debug, do not translate */ FtpDumpResponse("FtpPort", buf); status = TG_REMOTE_STATUS_FORMAT; if (ftp_cmd == 2) { status = FtpSendPortCmd(n_socket, pn_data_socket); } FtpFreeBuf(buf); buf = NULL; } } if (buf != NULL) FtpFreeBuf(buf); } return status; } static int FtpType(n_socket) int n_socket; { char *buf=NULL; int status, ftp_cmd=(-1); if ((status=FtpReadCmd(n_socket, &buf, &ftp_cmd)) == TG_REMOTE_STATUS_OK) { /* debug, do not translate */ FtpDumpResponse("FtpType", buf); status = TG_REMOTE_STATUS_FORMAT; if (ftp_cmd == 2) { /* do not translate -- program constants */ status = FtpSendType(n_socket, "TYPE I"); } FtpFreeBuf(buf); } return status; } static int FtpRetr(n_socket, psz_path) int n_socket; char *psz_path; { char *buf=NULL; int status, ftp_cmd=(-1); if ((status=FtpReadCmd(n_socket, &buf, &ftp_cmd)) == TG_REMOTE_STATUS_OK) { /* debug, do not translate */ FtpDumpResponse("FtpRetr", buf); status = TG_REMOTE_STATUS_FORMAT; if (ftp_cmd == 2) { status = FtpSendRetrieveCmd(n_socket, psz_path); } FtpFreeBuf(buf); } return status; } static int FtpCwd(n_socket, psz_path, pn_is_dir) int n_socket, *pn_is_dir; char *psz_path; { char *buf=NULL; int status, ftp_cmd=(-1); *pn_is_dir = FALSE; if ((status=FtpReadCmd(n_socket, &buf, &ftp_cmd)) == TG_REMOTE_STATUS_OK) { /* debug, do not translate */ FtpDumpResponse("FtpCwd", buf); status = TG_REMOTE_STATUS_FORMAT; if (ftp_cmd != 1) { FtpFreeBuf(buf); status = FtpSendCWDCmd(n_socket, psz_path); if ((status=FtpReadCmd(n_socket, &buf, &ftp_cmd)) == TG_REMOTE_STATUS_OK) { /* debug, do not translate */ FtpDumpResponse("FtpCwd", buf); if (ftp_cmd == 2) { *pn_is_dir = TRUE; gnReadyToReceiveData = TRUE; status = FtpSendListCmd(n_socket); } FtpFreeBuf(buf); buf = NULL; } } else { gnReadyToReceiveData = TRUE; status = TG_REMOTE_STATUS_OK; } if (buf != NULL) FtpFreeBuf(buf); } return status; } static int FtpGetContent(n_socket, data_socket, is_dir, ppsz_buf, pn_buf_sz) int n_socket, data_socket, is_dir, *pn_buf_sz; char **ppsz_buf; { struct sockaddr_in soc_address; int soc_addrlen=sizeof(soc_address), accepted_socket; int status=TG_REMOTE_STATUS_OK; if (pn_buf_sz != NULL) *pn_buf_sz = 0; *ppsz_buf = NULL; accepted_socket = accept(data_socket, (struct sockaddr *)&soc_address, (void*)(&soc_addrlen)); if (accepted_socket < 0) return TG_REMOTE_STATUS_HOST; ftpReadData = TRUE; if (is_dir) { /* a directory */ status = FtpDoRead(accepted_socket, ppsz_buf, pn_buf_sz); } else { /* a file */ status = FtpDoRead(accepted_socket, ppsz_buf, pn_buf_sz); } ftpReadData = FALSE; close(accepted_socket); return TG_REMOTE_STATUS_OK; } int FtpDoTalk(n_socket, psz_path, ppsz_buf, pn_buf_sz) int n_socket, *pn_buf_sz; char *psz_path, **ppsz_buf; { int status=TG_REMOTE_STATUS_OK, data_socket=(-1), is_dir=FALSE; char msg[80]; *ppsz_buf = NULL; if ((status=FtpLogin(n_socket)) != TG_REMOTE_STATUS_OK) return status; if ((status=FtpPassword(n_socket)) != TG_REMOTE_STATUS_OK) return status; if ((status=FtpPort(n_socket, &data_socket)) != TG_REMOTE_STATUS_OK) { return status; } if ((status=FtpType(n_socket)) != TG_REMOTE_STATUS_OK) return status; if ((status=FtpRetr(n_socket, psz_path)) != TG_REMOTE_STATUS_OK) { if (data_socket != (-1)) close(data_socket); return (FTP_LOGGED_IN|status); } gnReadyToReceiveData = FALSE; if ((status=FtpCwd(n_socket, psz_path, &is_dir)) != TG_REMOTE_STATUS_OK) { if (data_socket != (-1)) close(data_socket); return (FTP_LOGGED_IN|status); } if (gnReadyToReceiveData) { sprintf(msg, TgLoadCachedString(CSTID_LOGIN_SUCC_RETRIEVE_DATA), "FTP"); ShowRemoteStatus(msg); status = FtpGetContent(n_socket, data_socket, is_dir, ppsz_buf, pn_buf_sz); } if (data_socket != (-1)) close(data_socket); return (FTP_LOGGED_IN|status); } tgif-QPL-4.2.5/stamp-h10000644000076400007640000000002711602233423014343 0ustar williamwilliamtimestamp for config.h tgif-QPL-4.2.5/tgificon.eps0000644000076400007640000000561411602233313015306 0ustar williamwilliam%!PS-Adobe-2.0 EPSF-1.2 %%BoundingBox: 0 748 45 792 %%BeginPreview: 46 45 1 45 % 000003000000 % 000004800000 % 000008400000 % 000010200000 % 000020100000 % 00004f880000 % 00008b040000 % 000106020000 % 000206010000 % 000404008000 % 000800004000 % 001fffffe000 % 003003001000 % 005002800800 % 009002400400 % 0111c2200200 % 021342100100 % 041202080080 % 0813e2040040 % 1013c2020020 % 201002010010 % 401002008008 % 801002004004 % fffffffffff8 % 200002000010 % 100002000020 % 080002000040 % 0400021c0080 % 0200020c0100 % 010002180200 % 008002180400 % 0040f2180800 % 002082001000 % 0011e2002000 % 000982004000 % 000582008000 % 000202010000 % 000102020000 % 000082040000 % 000042080000 % 000022100000 % 000012200000 % 00000a400000 % 000006800000 % 000003000000 %%EndImage %%EndPreview %!PS-Adobe-2.0 EPSF-1.2 %%BoundingBox: -0.561 746.437 45.563 792.563 %%Title: tgificon %%CreationDate: Tue Jan 21 19:50:28 1992 %%Creator: Tgif by William Cheng %%Pages: 1 1 %%DocumentFonts: Times-Roman Helvetica Courier NewCenturySchlbk Symbol %% @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgificon.eps,v 1.1 2004/06/18 23:19:38 william Exp $ %%EndComments %%BeginSetup /centertext { dup stringwidth pop 2 div neg 0 rmoveto } def /righttext { dup stringwidth pop neg 0 rmoveto } def %%EndSetup %%Page: 1 1 gsave 1 setmiterlimit 1 setlinewidth 72 0 mul 72 11 mul translate 72 128 div 100 mul 100 div dup neg scale % POLYGON/CLOSED-SPLINE gsave newpath 0 40 moveto 40 40 lineto 40 80 lineto closepath stroke grestore % POLYGON/CLOSED-SPLINE gsave newpath 40 40 moveto 40 80 lineto 80 40 lineto closepath stroke grestore % POLYGON/CLOSED-SPLINE gsave newpath 40 0 moveto 20 20 lineto 60 20 lineto closepath stroke grestore % POLYGON/CLOSED-SPLINE gsave newpath 20 20 moveto 0 40 lineto 20 40 lineto closepath stroke grestore % POLYGON/CLOSED-SPLINE gsave newpath 20 20 moveto 20 40 lineto 40 40 lineto 40 20 lineto closepath stroke grestore % POLYGON/CLOSED-SPLINE gsave newpath 40 20 moveto 40 40 lineto 60 40 lineto closepath stroke grestore % POLYGON/CLOSED-SPLINE gsave newpath 40 20 moveto 60 40 lineto 80 40 lineto 60 20 lineto closepath stroke grestore % TEXT 0 setgray /Times-BoldItalic findfont [14 0 0 -14 0 0] makefont setfont gsave 40 18 moveto (T) centertext show grestore % TEXT 0 setgray /Courier-Bold findfont [14 0 0 -14 0 0] makefont setfont gsave 30 36 moveto (G) centertext show grestore % TEXT 0 setgray /NewCenturySchlbk-BoldItalic findfont [14 0 0 -14 0 0] makefont setfont gsave 50 57 moveto (I) centertext show grestore % TEXT 0 setgray /Helvetica-BoldOblique findfont [14 0 0 -14 0 0] makefont setfont gsave 30 64 moveto (F) centertext show grestore grestore showpage %%Trailer %%MatchingCreationDate: Tue Jan 21 19:50:28 1992 %%EOF tgif-QPL-4.2.5/rmcast/0000755000076400007640000000000011602233155014262 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/INSTALL0000644000076400007640000000050110126440050015301 0ustar williamwilliamCompiling the Reliable Multicast Library: To compile librmcast.a: ./configure make Other options: make clean This will clean up the rmcast directory See the rmchat directory to learn how to create a multicast application with the Reliable Multicast Library. tgif-QPL-4.2.5/rmcast/tgif/0000755000076400007640000000000011602233155015213 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/tgif/tgwb0000755000076400007640000001054211225226450016107 0ustar williamwilliam#!/bin/bash RML_VERSION=2.0.0 DEFAULT_TGWB=0 MCASTPROXY="mcastproxy" TGWB_CONFIG_DIR="$HOME/.tgwb" TGWB_CONFIG="$TGWB_CONFIG_DIR/tgwb.conf" PROXY_CONFIG="$TGWB_CONFIG_DIR/mcastproxy.conf" PROXY_PIDFILE="$TGWB_CONFIG_DIR/mcastproxy.pid" usage(){ cat <] Where --default-tgwb-only: do not ask anything just run tgwb with default config END } create_tgwb_config(){ cat <$TGWB_CONFIG #Reliable Multicast Library configuration file RM_VERSION=$RML_VERSION TRANSMISSION_MODE=0 DEST_IP=$TGWB_IP DEST_PORT=$TGWB_PORT TTL=1 MICROSLEEP=10 LOG_FILE=$TGWB_LOG TIMER_DISTRIBUTION=0 TIMER_PARAM_A=2 TIMER_PARAM_B=2 TIMER_PARAM_C=5 TIMER_PARAM_D=2 TIMER_PARAM_E=2 TIMER_PARAM_F=2 HOSTS_IDENTIFIED=0 DEFAULT 50 MAX_NAK=100 MAX_MEMBER_CACHE_SIZE=4000 NEW_MEMBER_SUPPORT=0 STATISTICS=0 REFRESH_TIMER=10 LOSS_PROB=0 LEAVE_GROUP_WAIT_TIME=500000 RCV_BUFFER_SIZE=10000 END } create_proxy_config(){ cat <$PROXY_CONFIG GROUPADDR=$TGWB_IP NADDR=1 ADDRLIST $PROXY_IP TTL=1 REUSEADDR=1 LOOPBACK=1 UCASTPORT=$PROXY_PORT MCASTPORT=$TGWB_PORT END } create_config_files(){ echo "Multicast IP address to use [default 225.1.2.3]:" read TGWB_IP if [ "x"$TGWB_IP = "x" ]; then echo " Using default IP address 225.1.2.3" TGWB_IP="225.1.2.3" fi echo "Port [default 5151]" read TGWB_PORT if [ "x"$TGWB_PORT = "x" ]; then echo " Using default Port 5151" TGWB_PORT="5151" fi if [ "x"$RUN_PROXY = "xy" ]; then while [ "x"$PROXY_IP = "x" ];do echo "Receiver mcastproxy IP address:" read PROXY_IP done echo "Receiver mcastproxy Port [32566]:" read PROXY_PORT if [ "x"$PROXY_PORT = "x" ]; then echo " Using default Port 32566" PROXY_PORT=32566 fi create_proxy_config fi create_tgwb_config } echo echo "##########################################" echo " Tangram-II Whiteboard version $RML_VERSION" echo " by Jorge Allyson Azevedo" echo " allyson@land.ufrj.br" echo " http://www.land.ufrj.br" echo "#########################################" echo if [ $# -gt 0 ]; then if [ $# = 1 ] && [ "$1" = "--default-tgwb-only" ]; then DEFAULT_TGWB=1 else usage exit 1 fi fi TGWB_CMD=`which tgwb-bin1` if [ $? != 0 ]; then echo echo -n "[Warning] tgwb-bin not found, trying to find tgif ... " TGWB_CMD=`which tgif` if [ $? != 0 ]; then echo echo "[Error] tgif not found." exit 1 else tgif -print -justversion 2>&1 | awk '{if(( $3 == 4.1 ) && ( $5 >= 46 )){exit 0}else{exit 1}}' if [ $? != 0 ]; then echo echo "[Error] tgif version must be equal or greater than 4.1.46" echo exit 1 else echo "OK" TGWB_CMD="tgif -tgrm2 -tgwb2 -sbim xim" fi fi fi if [ -d $TGWB_CONFIG_DIR ]; then echo "Config directory $TGWB_CONFIG_DIR found." else echo "Config directory $TGWB_CONFIG_DIR not found, creating it ..." mkdir $TGWB_CONFIG_DIR && STATUS=0 || STATUS=1 if [ $STATUS -eq 0 ]; then echo " $TGWB_CONFIG_DIR created." else echo "could not create $TGWB_CONFIG_DIR" exit 1 fi fi if [ -e $TGWB_CONFIG ] && [ $DEFAULT_TGWB != 1 ]; then echo "Do you want to change your TGWB configuration? [y|n]" read RECONFIGURE fi while [ "x"$RUN_PROXY != "xy" ] && [ "x"$RUN_PROXY != "xn" ] && [ $DEFAULT_TGWB != 1 ];do echo "Do you want to run the mcastproxy program? [y|n]" read RUN_PROXY done MCASTPROXY_CMD=`which $MCASTPROXY | head -1` if [ $? != 0 ] && [ $DEFAULT_TGWB != 1 ]; then echo "[Error] mcastproxy not found. Check your installation!" exit 1 fi if [ "x"$RECONFIGURE = "x" ] || [ "x"$RECONFIGURE = "xy" ] && [ $DEFAULT_TGWB != 1 ]; then create_config_files fi if [ -e $PROXY_PIDFILE ] && [ $DEFAULT_TGWB != 1 ]; then PROXY_PID=`cat $PROXY_PIDFILE` kill -9 $PROXY_PID > /dev/null 2>&1 killall -9 mcastproxy > /dev/null 2>&1 rm -f $PROXY_PIDFILE fi # Execute mcastproxy first ... if [ "x"$RUN_PROXY = "xy" ]; then $MCASTPROXY_CMD & fi # ... and then tgwb $TGWB_CMD if [ "x"$RUN_PROXY = "xy" ]; then PROXY_PID=`cat $PROXY_PIDFILE` kill -9 $PROXY_PID > /dev/null 2>&1 rm -f $PROXY_PIDFILE fi tgif-QPL-4.2.5/rmcast/tgif/tgif_tgwb.sh0000755000076400007640000000535010434752721017540 0ustar williamwilliam#!/bin/bash ################################################################################ # File: tgif_tgwb.sh # Author: {allyson}@land.ufrj.br # Date: 2006-03-30 # # Description: compiles TGWB tgif source code # # Copyright 2006 LAND/UFRJ # http://www.land.ufrj.br # ################################################################################ if [ $# != 1 ]; then echo echo "Usage:" echo echo " $0 " echo exit 1 fi if [ ! -d $1 ]; then echo echo "[tgif_tgwb] $1 is not a directory" echo exit 1 fi cd $1 if [ ! -f Tgif.tmpl ]; then echo echo "[tgif_tgwb] Tgif.tmpl not found" echo exit 1 fi if [ ! -f Target.tmpl ]; then echo echo "[tgif_tgwb] Target.tmpl not found" echo exit 1 fi if [ ! -w Tgif.tmpl ]; then chmod u+w Tgif.tmpl fi if [ ! -w Target.tmpl ]; then chmod u+w Target.tmpl fi mv Target.tmpl Target.tmpl.orig sed -e 's/TARGET_1 = tgif/TARGET_1 = tgwb-bin/' Target.tmpl.orig > Target.tmpl.tgwb if [ $? = 0 ]; then echo echo "[tgif_tgwb] File Target.tmpl successfully modified" echo else echo echo "[tgif_tgwb] Failed trying to modify Target.tmpl" echo exit 1 fi mv Target.tmpl.tgwb Target.tmpl mv Tgif.tmpl Tgif.tmpl.orig sed '/^SYS_LIBRARIES/ a\EXTRA_LIBRARIES = -L./rmcast/src -lpthread -lrmcast' Tgif.tmpl.orig | sed -e 's/= tgif/= tgwb-bin/' -e 's/^MOREDEFINES.*$/MOREDEFINES = -D_TGIF_WB2 -D_TANGRAM_II -DDEFATTRGROUP=\\\"TANGRAM-II:Declaration:Initialization:Events:Messages:Rewards:Watches\\"/' > Tgif.tmpl.tgwb if [ $? = 0 ]; then echo echo "[tgif_tgwb] File Tgif.tmpl successfully modified" echo else echo echo "[tgif_tgwb] Failed trying to modify Tgif.tmpl" echo exit 1 fi mv Tgif.tmpl.tgwb Tgif.tmpl xmkmf if [ $? = 0 ]; then echo echo "[tgif_tgwb] Makefile successfully created by xmkmf" echo else echo echo "[tgif_tgwb] Makefile creation by xmkmf failed" echo exit 1 fi ln -sf tgif.man tgwb-bin.man cd rmcast ./configure if [ $? = 0 ]; then echo echo "[tgif_tgwb] rmcast's Makefile successfully created by configure" echo else echo echo "[tgif_tgwb] rmcast's Makefile creation by configure failed" echo cd .. exit 1 fi make clean all if [ $? = 0 ]; then echo echo "[tgif_tgwb] rmcast library successfully compiled" echo else echo echo "[tgif_tgwb] rmcast library compilation failed" echo cd .. exit 1 fi cd .. make clean all if [ $? = 0 ]; then echo echo "[tgif_tgwb] TGWB successfully compiled" echo else echo echo "[tgif_tgwb] TGWB compilation failed" echo exit 1 fi echo echo "[tgif_tgwb] To install TGWB in your system, run as root: make install-tgwb" echo tgif-QPL-4.2.5/rmcast/autom4te.cache/0000755000076400007640000000000011566506146017102 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/autom4te.cache/output.00000644000076400007640000272562211566506146020543 0ustar williamwilliam@%:@! /bin/sh @%:@ Guess values for system-dependent variables and create Makefiles. @%:@ Generated by GNU Autoconf 2.61 for rmcast 2.0.0. @%:@ @%:@ Report bugs to . @%:@ @%:@ Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @%:@ 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. @%:@ This configure script is free software; the Free Software Foundation @%:@ gives unlimited permission to copy, distribute and modify it. ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi # PATH needs CR # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset else as_unset=false fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) as_nl=' ' IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. case $0 in *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 { (exit 1); exit 1; } fi # Work around bugs in pre-3.0 UWIN ksh. for as_var in ENV MAIL MAILPATH do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. for as_var in \ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ LC_TELEPHONE LC_TIME do if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then eval $as_var=C; export $as_var else ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var fi done # Required to use basename. if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi # Name of the executable. as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # CDPATH. $as_unset CDPATH if test "x$CONFIG_SHELL" = x; then if (eval ":") 2>/dev/null; then as_have_required=yes else as_have_required=no fi if test $as_have_required = yes && (eval ": (as_func_return () { (exit \$1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = \"\$1\" ); then : else exitcode=1 echo positional parameters were not saved. fi test \$exitcode = 0) || { (exit 1); exit 1; } ( as_lineno_1=\$LINENO as_lineno_2=\$LINENO test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" && test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; } ") 2> /dev/null; then : else as_candidate_shells= as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. case $as_dir in /*) for as_base in sh bash ksh sh5; do as_candidate_shells="$as_candidate_shells $as_dir/$as_base" done;; esac done IFS=$as_save_IFS for as_shell in $as_candidate_shells $SHELL; do # Try only shells that exist, to save several forks. if { test -f "$as_shell" || test -f "$as_shell.exe"; } && { ("$as_shell") 2> /dev/null <<\_ASEOF if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi : _ASEOF }; then CONFIG_SHELL=$as_shell as_have_required=yes if { "$as_shell" 2> /dev/null <<\_ASEOF if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi : (as_func_return () { (exit $1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = "$1" ); then : else exitcode=1 echo positional parameters were not saved. fi test $exitcode = 0) || { (exit 1); exit 1; } ( as_lineno_1=$LINENO as_lineno_2=$LINENO test "x$as_lineno_1" != "x$as_lineno_2" && test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; } _ASEOF }; then break fi fi done if test "x$CONFIG_SHELL" != x; then for as_var in BASH_ENV ENV do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var done export CONFIG_SHELL exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} fi if test $as_have_required = no; then echo This script requires a shell more modern than all the echo shells that I found on your system. Please install a echo modern shell, or manually run the script under such a echo shell if you do have one. { (exit 1); exit 1; } fi fi fi (eval "as_func_return () { (exit \$1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = \"\$1\" ); then : else exitcode=1 echo positional parameters were not saved. fi test \$exitcode = 0") || { echo No shell found that supports shell functions. echo Please tell autoconf@gnu.org about your system, echo including any error possibly output before this echo message } as_lineno_1=$LINENO as_lineno_2=$LINENO test "x$as_lineno_1" != "x$as_lineno_2" && test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || { # Create $as_me.lineno as a copy of $as_myself, but with $LINENO # uniformly replaced by the line number. The first 'sed' inserts a # line-number line after each line using $LINENO; the second 'sed' # does the real work. The second script uses 'N' to pair each # line-number line with the line containing $LINENO, and appends # trailing '-' during substitution so that $LINENO is not a special # case at line end. # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the # scripts with optimization help from Paolo Bonzini. Blame Lee # E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 { (exit 1); exit 1; }; } # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in -n*) case `echo 'x\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. *) ECHO_C='\c';; esac;; *) ECHO_N='-n';; esac if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir fi echo >conf$$.file if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p=: else test -d ./-p && rmdir ./-p as_mkdir_p=false fi if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" # Check that we are running under the correct shell. SHELL=${CONFIG_SHELL-/bin/sh} case X$ECHO in X*--fallback-echo) # Remove one level of quotation (which was required for Make). ECHO=`echo "$ECHO" | sed 's,\\\\\$\\$0,'$0','` ;; esac echo=${ECHO-echo} if test "X$1" = X--no-reexec; then # Discard the --no-reexec flag, and continue. shift elif test "X$1" = X--fallback-echo; then # Avoid inline document here, it may be left over : elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then # Yippee, $echo works! : else # Restart under the correct shell. exec $SHELL "$0" --no-reexec ${1+"$@"} fi if test "X$1" = X--fallback-echo; then # used as fallback echo shift cat </dev/null 2>&1 && unset CDPATH if test -z "$ECHO"; then if test "X${echo_test_string+set}" != Xset; then # find a string as large as possible, as long as the shell can cope with it for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... if (echo_test_string=`eval $cmd`) 2>/dev/null && echo_test_string=`eval $cmd` && (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null then break fi done fi if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then : else # The Solaris, AIX, and Digital Unix default echo programs unquote # backslashes. This makes it impossible to quote backslashes using # echo "$something" | sed 's/\\/\\\\/g' # # So, first we look for a working echo in the user's PATH. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for dir in $PATH /usr/ucb; do IFS="$lt_save_ifs" if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then echo="$dir/echo" break fi done IFS="$lt_save_ifs" if test "X$echo" = Xecho; then # We didn't find a better echo, so look for alternatives. if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then # This shell has a builtin print -r that does the trick. echo='print -r' elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && test "X$CONFIG_SHELL" != X/bin/ksh; then # If we have ksh, try running configure again with it. ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} export ORIGINAL_CONFIG_SHELL CONFIG_SHELL=/bin/ksh export CONFIG_SHELL exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"} else # Try using printf. echo='printf %s\n' if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then # Cool, printf works : elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && test "X$echo_testing_string" = 'X\t' && echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL export CONFIG_SHELL SHELL="$CONFIG_SHELL" export SHELL echo="$CONFIG_SHELL $0 --fallback-echo" elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && test "X$echo_testing_string" = 'X\t' && echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then echo="$CONFIG_SHELL $0 --fallback-echo" else # maybe with a smaller string... prev=: for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null then break fi prev="$cmd" done if test "$prev" != 'sed 50q "$0"'; then echo_test_string=`eval $prev` export echo_test_string exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"} else # Oops. We lost completely, so just stick with echo. echo=echo fi fi fi fi fi fi # Copy echo and quote the copy suitably for passing to libtool from # the Makefile, instead of quoting the original, which is used later. ECHO=$echo if test "X$ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo" fi tagnames=${tagnames+${tagnames},}CXX tagnames=${tagnames+${tagnames},}F77 exec 7<&0 &1 # Name of the host. # hostname on some systems (SVR3.2, Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` # # Initializations. # ac_default_prefix=/usr/local ac_clean_files= ac_config_libobj_dir=. LIB@&t@OBJS= cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME='rmcast' PACKAGE_TARNAME='rmcast' PACKAGE_VERSION='2.0.0' PACKAGE_STRING='rmcast 2.0.0' PACKAGE_BUGREPORT='support@land.ufrj.br' ac_unique_file="src/rmcache.h" # Factoring default headers for most tests. ac_includes_default="\ #include #ifdef HAVE_SYS_TYPES_H # include #endif #ifdef HAVE_SYS_STAT_H # include #endif #ifdef STDC_HEADERS # include # include #else # ifdef HAVE_STDLIB_H # include # endif #endif #ifdef HAVE_STRING_H # if !defined STDC_HEADERS && defined HAVE_MEMORY_H # include # endif # include #endif #ifdef HAVE_STRINGS_H # include #endif #ifdef HAVE_INTTYPES_H # include #endif #ifdef HAVE_STDINT_H # include #endif #ifdef HAVE_UNISTD_H # include #endif" ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir localstatedir includedir oldincludedir docdir infodir htmldir dvidir pdfdir psdir libdir localedir mandir DEFS ECHO_C ECHO_N ECHO_T LIBS build_alias host_alias target_alias INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE build build_cpu build_vendor build_os host host_cpu host_vendor host_os SED GREP EGREP LN_S ECHO AR RANLIB DSYMUTIL NMEDIT CPP CXX CXXFLAGS ac_ct_CXX CXXDEPMODE am__fastdepCXX_TRUE am__fastdepCXX_FALSE CXXCPP F77 FFLAGS ac_ct_F77 LIBTOOL LIB@&t@OBJS LTLIBOBJS' ac_subst_files='' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS CPP CXX CXXFLAGS CCC CXXCPP F77 FFLAGS' # Initialize some variables set by options. ac_init_help= ac_init_version=false # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. # (The list follows the same order as the GNU Coding Standards.) bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datarootdir='${prefix}/share' datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' pdfdir='${docdir}' psdir='${docdir}' libdir='${exec_prefix}/lib' localedir='${datarootdir}/locale' mandir='${datarootdir}/man' ac_prev= ac_dashdash= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval $ac_prev=\$ac_option ac_prev= continue fi case $ac_option in *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=*) datadir=$ac_optarg ;; -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | --dataroo | --dataro | --datar) ac_prev=datarootdir ;; -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) datarootdir=$ac_optarg ;; -disable-* | --disable-*) ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid feature name: $ac_feature" >&2 { (exit 1); exit 1; }; } ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'` eval enable_$ac_feature=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) docdir=$ac_optarg ;; -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) ac_prev=dvidir ;; -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) dvidir=$ac_optarg ;; -enable-* | --enable-*) ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid feature name: $ac_feature" >&2 { (exit 1); exit 1; }; } ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'` eval enable_$ac_feature=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) ac_prev=htmldir ;; -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | --ht=*) htmldir=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localedir | --localedir | --localedi | --localed | --locale) ac_prev=localedir ;; -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) localedir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst | --locals) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) ac_prev=pdfdir ;; -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) pdfdir=$ac_optarg ;; -psdir | --psdir | --psdi | --psd | --ps) ac_prev=psdir ;; -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) psdir=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid package name: $ac_package" >&2 { (exit 1); exit 1; }; } ac_package=`echo $ac_package | sed 's/[-.]/_/g'` eval with_$ac_package=\$ac_optarg ;; -without-* | --without-*) ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid package name: $ac_package" >&2 { (exit 1); exit 1; }; } ac_package=`echo $ac_package | sed 's/[-.]/_/g'` eval with_$ac_package=no ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) { echo "$as_me: error: unrecognized option: $ac_option Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; } ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid variable name: $ac_envvar" >&2 { (exit 1); exit 1; }; } eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` { echo "$as_me: error: missing argument to $ac_option" >&2 { (exit 1); exit 1; }; } fi # Be sure to have absolute directory names. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 { (exit 1); exit 1; }; } done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. If a cross compiler is detected then cross compile mode will be used." >&2 elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || { echo "$as_me: error: Working directory cannot be determined" >&2 { (exit 1); exit 1; }; } test "X$ac_ls_di" = "X$ac_pwd_ls_di" || { echo "$as_me: error: pwd does not report name of working directory" >&2 { (exit 1); exit 1; }; } # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. ac_confdir=`$as_dirname -- "$0" || $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$0" : 'X\(//\)[^/]' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || echo X"$0" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` srcdir=$ac_confdir if test ! -r "$srcdir/$ac_unique_file"; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2 { (exit 1); exit 1; }; } fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2 { (exit 1); exit 1; }; } pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then srcdir=. fi # Remove unnecessary trailing slashes from srcdir. # Double slashes in file names in object file debugging info # mess up M-x gdb in Emacs. case $srcdir in */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; esac for ac_var in $ac_precious_vars; do eval ac_env_${ac_var}_set=\${${ac_var}+set} eval ac_env_${ac_var}_value=\$${ac_var} eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} eval ac_cv_env_${ac_var}_value=\$${ac_var} done # # Report the --help message. # if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF \`configure' configures rmcast 2.0.0 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] --docdir=DIR documentation root @<:@DATAROOTDIR/doc/rmcast@:>@ --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF Program names: --program-prefix=PREFIX prepend PREFIX to installed program names --program-suffix=SUFFIX append SUFFIX to installed program names --program-transform-name=PROGRAM run sed PROGRAM on installed program names System types: --build=BUILD configure for building on BUILD [guessed] --host=HOST cross-compile to build programs to run on HOST [BUILD] _ACEOF fi if test -n "$ac_init_help"; then case $ac_init_help in short | recursive ) echo "Configuration of rmcast 2.0.0:";; esac cat <<\_ACEOF Optional Features: --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors --enable-shared@<:@=PKGS@:>@ build shared libraries @<:@default=yes@:>@ --enable-static@<:@=PKGS@:>@ build static libraries @<:@default=yes@:>@ --enable-fast-install@<:@=PKGS@:>@ optimize for fast installation @<:@default=yes@:>@ --disable-libtool-lock avoid locking (might break parallel builds) Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-gnu-ld assume the C compiler uses GNU ld @<:@default=no@:>@ --with-pic try to use only PIC/non-PIC objects @<:@default=use both@:>@ --with-tags@<:@=TAGS@:>@ include additional configurations @<:@automatic@:>@ Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L if you have libraries in a nonstandard directory LIBS libraries to pass to the linker, e.g. -l CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I if you have headers in a nonstandard directory CPP C preprocessor CXX C++ compiler command CXXFLAGS C++ compiler flags CXXCPP C++ preprocessor F77 Fortran 77 compiler command FFLAGS Fortran 77 compiler flags Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to . _ACEOF ac_status=$? fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d "$ac_dir" || continue ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" || { ac_status=$?; continue; } # Check for guested configure. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive elif test -f "$ac_srcdir/configure"; then echo && $SHELL "$ac_srcdir/configure" --help=recursive else echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF rmcast configure 2.0.0 generated by GNU Autoconf 2.61 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF exit fi cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by rmcast $as_me 2.0.0, which was generated by GNU Autoconf 2.61. Invocation command line was $ $0 $@ _ACEOF exec 5>>config.log { cat <<_ASUNAME @%:@@%:@ --------- @%:@@%:@ @%:@@%:@ Platform. @%:@@%:@ @%:@@%:@ --------- @%:@@%:@ hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. echo "PATH: $as_dir" done IFS=$as_save_IFS } >&5 cat >&5 <<_ACEOF @%:@@%:@ ----------- @%:@@%:@ @%:@@%:@ Core tests. @%:@@%:@ @%:@@%:@ ----------- @%:@@%:@ _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;; 2) ac_configure_args1="$ac_configure_args1 '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi ac_configure_args="$ac_configure_args '$ac_arg'" ;; esac done done $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; } $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; } # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? # Save into config.log some information that might help in debugging. { echo cat <<\_ASBOX @%:@@%:@ ---------------- @%:@@%:@ @%:@@%:@ Cache variables. @%:@@%:@ @%:@@%:@ ---------------- @%:@@%:@ _ASBOX echo # The following way of writing the cache mishandles newlines in values, ( for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( *) $as_unset $ac_var ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( *${as_nl}ac_space=\ *) sed -n \ "s/'\''/'\''\\\\'\'''\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" ;; #( *) sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) echo cat <<\_ASBOX @%:@@%:@ ----------------- @%:@@%:@ @%:@@%:@ Output variables. @%:@@%:@ @%:@@%:@ ----------------- @%:@@%:@ _ASBOX echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac echo "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then cat <<\_ASBOX @%:@@%:@ ------------------- @%:@@%:@ @%:@@%:@ File substitutions. @%:@@%:@ @%:@@%:@ ------------------- @%:@@%:@ _ASBOX echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac echo "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then cat <<\_ASBOX @%:@@%:@ ----------- @%:@@%:@ @%:@@%:@ confdefs.h. @%:@@%:@ @%:@@%:@ ----------- @%:@@%:@ _ASBOX echo cat confdefs.h echo fi test "$ac_signal" != 0 && echo "$as_me: caught signal $ac_signal" echo "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF @%:@define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF @%:@define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF @%:@define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF @%:@define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF @%:@define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer explicitly selected file to automatically selected ones. if test -n "$CONFIG_SITE"; then set x "$CONFIG_SITE" elif test "x$prefix" != xNONE; then set x "$prefix/share/config.site" "$prefix/etc/config.site" else set x "$ac_default_prefix/share/config.site" \ "$ac_default_prefix/etc/config.site" fi shift for ac_site_file do if test -r "$ac_site_file"; then { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5 echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special # files actually), so we avoid doing that. if test -f "$cache_file"; then { echo "$as_me:$LINENO: loading cache $cache_file" >&5 echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { echo "$as_me:$LINENO: creating cache $cache_file" >&5 echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in $ac_precious_vars; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val=\$ac_cv_env_${ac_var}_value eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} { echo "$as_me:$LINENO: former value: $ac_old_val" >&5 echo "$as_me: former value: $ac_old_val" >&2;} { echo "$as_me:$LINENO: current value: $ac_new_val" >&5 echo "$as_me: current value: $ac_new_val" >&2;} ac_cache_corrupted=: fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) ac_configure_args="$ac_configure_args '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; then { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5 echo "$as_me: error: changes in the environment can compromise the build" >&2;} { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} { (exit 1); exit 1; }; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_aux_dir= for ac_dir in config "$srcdir"/config; do if test -f "$ac_dir/install-sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" break elif test -f "$ac_dir/install.sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break elif test -f "$ac_dir/shtool"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/shtool install -c" break fi done if test -z "$ac_aux_dir"; then { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5 echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;} { (exit 1); exit 1; }; } fi # These three variables are undocumented and unsupported, # and are intended to be withdrawn in a future Autoconf release. # They can cause serious problems if a builder's source tree is in a directory # whose full name contains unusual characters. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. ac_config_headers="$ac_config_headers config.h" am__api_version="1.9" # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. { echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; } if test -z "$INSTALL"; then if test "${ac_cv_path_install+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in ./ | .// | /cC/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi done done ;; esac done IFS=$as_save_IFS fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a # value for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. INSTALL=$ac_install_sh fi fi { echo "$as_me:$LINENO: result: $INSTALL" >&5 echo "${ECHO_T}$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { echo "$as_me:$LINENO: checking whether build environment is sane" >&5 echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6; } # Just in case sleep 1 echo timestamp > conftest.file # Do `set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` if test "$*" = "X"; then # -L didn't work. set X `ls -t $srcdir/configure conftest.file` fi rm -f conftest.file if test "$*" != "X $srcdir/configure conftest.file" \ && test "$*" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". { { echo "$as_me:$LINENO: error: ls -t appears to fail. Make sure there is not a broken alias in your environment" >&5 echo "$as_me: error: ls -t appears to fail. Make sure there is not a broken alias in your environment" >&2;} { (exit 1); exit 1; }; } fi test "$2" = conftest.file ) then # Ok. : else { { echo "$as_me:$LINENO: error: newly created file is older than distributed files! Check your system clock" >&5 echo "$as_me: error: newly created file is older than distributed files! Check your system clock" >&2;} { (exit 1); exit 1; }; } fi { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. test "$program_suffix" != NONE && program_transform_name="s&\$&$program_suffix&;$program_transform_name" # Double any \ or $. echo might interpret backslashes. # By default was `s,x,x', remove it if useless. cat <<\_ACEOF >conftest.sed s/[\\$]/&&/g;s/;s,x,x,$// _ACEOF program_transform_name=`echo $program_transform_name | sed -f conftest.sed` rm -f conftest.sed # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= { echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5 echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} fi if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then # We used to keeping the `.' as first argument, in order to # allow $(mkdir_p) to be used without argument. As in # $(mkdir_p) $(somedir) # where $(somedir) is conditionally defined. However this is wrong # for two reasons: # 1. if the package is installed by a user who cannot write `.' # make install will fail, # 2. the above comment should most certainly read # $(mkdir_p) $(DESTDIR)$(somedir) # so it does not work when $(somedir) is undefined and # $(DESTDIR) is not. # To support the latter case, we have to write # test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir), # so the `.' trick is pointless. mkdir_p='mkdir -p --' else # On NextStep and OpenStep, the `mkdir' command does not # recognize any option. It will interpret all options as # directories to create, and then abort because `.' already # exists. for d in ./-p ./--version; do test -d $d && rmdir $d done # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists. if test -f "$ac_aux_dir/mkinstalldirs"; then mkdir_p='$(mkinstalldirs)' else mkdir_p='$(install_sh) -d' fi fi for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_AWK+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_AWK="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then { echo "$as_me:$LINENO: result: $AWK" >&5 echo "${ECHO_T}$AWK" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$AWK" && break done { echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6; } set x ${MAKE-make}; ac_make=`echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF # GNU make sometimes prints "make[1]: Entering...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; *) eval ac_cv_prog_make_${ac_make}_set=no;; esac rm -f conftest.make fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } SET_MAKE= else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null # test to see if srcdir already configured if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5 echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;} { (exit 1); exit 1; }; } fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi # Define the identity of the package. PACKAGE='rmcast' VERSION='2.0.0' cat >>confdefs.h <<_ACEOF @%:@define PACKAGE "$PACKAGE" _ACEOF cat >>confdefs.h <<_ACEOF @%:@define VERSION "$VERSION" _ACEOF # Some tools Automake needs. ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} install_sh=${install_sh-"$am_aux_dir/install-sh"} # Installed binaries are usually stripped using `strip' when the user # run `make install-strip'. However `strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the `STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { echo "$as_me:$LINENO: result: $STRIP" >&5 echo "${ECHO_T}$STRIP" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_STRIP="strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5 echo "${ECHO_T}$ac_ct_STRIP" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi fi INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s" # We need awk for the "check" target. The system "awk" is bad on # some platforms. # Always define AMTAR for backward compatibility. AMTAR=${AMTAR-"${am_missing_run}tar"} am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' # Checks for programs. #AC_PROG_AWK ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}gcc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="gcc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}cc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $@%:@ != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH See \`config.log' for more details." >&5 echo "$as_me: error: no acceptable C compiler found in \$PATH See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } # Provide some information about the compiler. echo "$as_me:$LINENO: checking for C compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (ac_try="$ac_compiler --version >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler --version >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -v >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -v >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -V >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -V >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. { echo "$as_me:$LINENO: checking for C compiler default output file name" >&5 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; } ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # # List of possible output files, starting from the most likely. # The algorithm is not robust to junk in `.', hence go to wildcards (a.*) # only as a last resort. b.out is created by i960 compilers. ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out' # # The IRIX 6 linker writes into existing files which may not be # executable, retaining their permissions. Remove them first so a # subsequent execution test works. ac_rmfiles= for ac_file in $ac_files do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done rm -f $ac_rmfiles if { (ac_try="$ac_link_default" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link_default") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. for ac_file in $ac_files '' do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not # safe: cross compilers may not add the suffix if given an `-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. break;; * ) break;; esac done test "$ac_cv_exeext" = no && ac_cv_exeext= else ac_file='' fi { echo "$as_me:$LINENO: result: $ac_file" >&5 echo "${ECHO_T}$ac_file" >&6; } if test -z "$ac_file"; then echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { echo "$as_me:$LINENO: error: C compiler cannot create executables See \`config.log' for more details." >&5 echo "$as_me: error: C compiler cannot create executables See \`config.log' for more details." >&2;} { (exit 77); exit 77; }; } fi ac_exeext=$ac_cv_exeext # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { echo "$as_me:$LINENO: checking whether the C compiler works" >&5 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; } # FIXME: These cross compiler hacks should be removed for Autoconf 3.0 # If not cross compiling, check that we can run a simple program. if test "$cross_compiling" != yes; then if { ac_try='./$ac_file' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else { { echo "$as_me:$LINENO: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&5 echo "$as_me: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi fi fi { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } rm -f a.out a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { echo "$as_me:$LINENO: checking whether we are cross compiling" >&5 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; } { echo "$as_me:$LINENO: result: $cross_compiling" >&5 echo "${ECHO_T}$cross_compiling" >&6; } { echo "$as_me:$LINENO: checking for suffix of executables" >&5 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; } if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done else { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&5 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi rm -f conftest$ac_cv_exeext { echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5 echo "${ECHO_T}$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT { echo "$as_me:$LINENO: checking for suffix of object files" >&5 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; } if test "${ac_cv_objext+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.o conftest.obj if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile See \`config.log' for more details." >&5 echo "$as_me: error: cannot compute suffix of object files: cannot compile See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_objext" >&5 echo "${ECHO_T}$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; } if test "${ac_cv_c_compiler_gnu+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_compiler_gnu=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; } GCC=`test $ac_compiler_gnu = yes && echo yes` ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; } if test "${ac_cv_prog_cc_g+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cc_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 CFLAGS="" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cc_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; } if test "$ac_test_CFLAGS" = set; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi { echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5 echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; } if test "${ac_cv_prog_cc_c89+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_prog_cc_c89=no ac_save_CC=$CC cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #include #include /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); static char *e (p, i) char **p; int i; { return p[i]; } static char *f (char * (*g) (char **, int), char **p, ...) { char *s; va_list v; va_start (v,p); s = g (p, va_arg (v,int)); va_end (v); return s; } /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has function prototypes and stuff, but not '\xHH' hex character constants. These don't provoke an error unfortunately, instead are silently treated as 'x'. The following induces an error, until -std is added to get proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an array size at least. It's necessary to write '\x00'==0 to get something that's true only with -std. */ int osf4_cc_array ['\x00' == 0 ? 1 : -1]; /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters inside strings and character constants. */ #define FOO(x) 'x' int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);}; int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); int argc; char **argv; int main () { return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cc_c89=$ac_arg else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) { echo "$as_me:$LINENO: result: none needed" >&5 echo "${ECHO_T}none needed" >&6; } ;; xno) { echo "$as_me:$LINENO: result: unsupported" >&5 echo "${ECHO_T}unsupported" >&6; } ;; *) CC="$CC $ac_cv_prog_cc_c89" { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5 echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;; esac ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo done .PHONY: am__doit END # If we don't find an include directive, just comment out the code. { echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5 echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6; } am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # We grep out `Entering directory' and `Leaving directory' # messages which can occur if `w' ends up in MAKEFLAGS. # In particular we don't look at `^make:' because GNU make might # be invoked under some other name (usually "gmake"), in which # case it prints its new name instead of `make'. if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then am__include=include am__quote= _am_result=GNU fi # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then am__include=.include am__quote="\"" _am_result=BSD fi fi { echo "$as_me:$LINENO: result: $_am_result" >&5 echo "${ECHO_T}$_am_result" >&6; } rm -f confinc confmf # Check whether --enable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then enableval=$enable_dependency_tracking; fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= AMDEP_FALSE='#' else AMDEP_TRUE='#' AMDEP_FALSE= fi depcc="$CC" am_compiler_list= { echo "$as_me:$LINENO: checking dependency style of $depcc" >&5 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6; } if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CC_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CC_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi { echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then am__fastdepCC_TRUE= am__fastdepCC_FALSE='#' else am__fastdepCC_TRUE='#' am__fastdepCC_FALSE= fi # Check whether --enable-shared was given. if test "${enable_shared+set}" = set; then enableval=$enable_shared; p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; no) enable_shared=no ;; *) enable_shared=no # Look at the argument we got. We use all the common list separators. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then enable_shared=yes fi done IFS="$lt_save_ifs" ;; esac else enable_shared=yes fi # Check whether --enable-static was given. if test "${enable_static+set}" = set; then enableval=$enable_static; p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; no) enable_static=no ;; *) enable_static=no # Look at the argument we got. We use all the common list separators. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then enable_static=yes fi done IFS="$lt_save_ifs" ;; esac else enable_static=yes fi # Check whether --enable-fast-install was given. if test "${enable_fast_install+set}" = set; then enableval=$enable_fast_install; p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; no) enable_fast_install=no ;; *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done IFS="$lt_save_ifs" ;; esac else enable_fast_install=yes fi # Make sure we can run config.sub. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5 echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;} { (exit 1); exit 1; }; } { echo "$as_me:$LINENO: checking build system type" >&5 echo $ECHO_N "checking build system type... $ECHO_C" >&6; } if test "${ac_cv_build+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_build_alias=$build_alias test "x$ac_build_alias" = x && ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` test "x$ac_build_alias" = x && { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5 echo "$as_me: error: cannot guess build type; you must specify one" >&2;} { (exit 1); exit 1; }; } ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5 echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;} { (exit 1); exit 1; }; } fi { echo "$as_me:$LINENO: result: $ac_cv_build" >&5 echo "${ECHO_T}$ac_cv_build" >&6; } case $ac_cv_build in *-*-*) ;; *) { { echo "$as_me:$LINENO: error: invalid value of canonical build" >&5 echo "$as_me: error: invalid value of canonical build" >&2;} { (exit 1); exit 1; }; };; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' set x $ac_cv_build shift build_cpu=$1 build_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: build_os=$* IFS=$ac_save_IFS case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac { echo "$as_me:$LINENO: checking host system type" >&5 echo $ECHO_N "checking host system type... $ECHO_C" >&6; } if test "${ac_cv_host+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "x$host_alias" = x; then ac_cv_host=$ac_cv_build else ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5 echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;} { (exit 1); exit 1; }; } fi fi { echo "$as_me:$LINENO: result: $ac_cv_host" >&5 echo "${ECHO_T}$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; *) { { echo "$as_me:$LINENO: error: invalid value of canonical host" >&5 echo "$as_me: error: invalid value of canonical host" >&2;} { (exit 1); exit 1; }; };; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' set x $ac_cv_host shift host_cpu=$1 host_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: host_os=$* IFS=$ac_save_IFS case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac { echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5 echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6; } if test "${lt_cv_path_SED+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Loop through the user's path and test for sed and gsed. # Then use that list of sed's as ones to test for truncation. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for lt_ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$lt_ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$lt_ac_prog$ac_exec_ext"; }; then lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" fi done done done IFS=$as_save_IFS lt_ac_max=0 lt_ac_count=0 # Add /usr/xpg4/bin/sed as it is typically found on Solaris # along with /bin/sed that truncates output. for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do test ! -f $lt_ac_sed && continue cat /dev/null > conftest.in lt_ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >conftest.in # Check for GNU sed and select it if it is found. if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then lt_cv_path_SED=$lt_ac_sed break fi while true; do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo >>conftest.nl $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break cmp -s conftest.out conftest.nl || break # 10000 chars as input seems more than enough test $lt_ac_count -gt 10 && break lt_ac_count=`expr $lt_ac_count + 1` if test $lt_ac_count -gt $lt_ac_max; then lt_ac_max=$lt_ac_count lt_cv_path_SED=$lt_ac_sed fi done done fi SED=$lt_cv_path_SED { echo "$as_me:$LINENO: result: $SED" >&5 echo "${ECHO_T}$SED" >&6; } { echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5 echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; } if test "${ac_cv_path_GREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Extract the first word of "grep ggrep" to use in msg output if test -z "$GREP"; then set dummy grep ggrep; ac_prog_name=$2 if test "${ac_cv_path_GREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_path_GREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in *GNU*) ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; *) ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" echo 'GREP' >> "conftest.nl" "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break ac_count=`expr $ac_count + 1` if test $ac_count -gt ${ac_path_GREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_GREP_found && break 3 done done done IFS=$as_save_IFS fi GREP="$ac_cv_path_GREP" if test -z "$GREP"; then { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} { (exit 1); exit 1; }; } fi else ac_cv_path_GREP=$GREP fi fi { echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5 echo "${ECHO_T}$ac_cv_path_GREP" >&6; } GREP="$ac_cv_path_GREP" { echo "$as_me:$LINENO: checking for egrep" >&5 echo $ECHO_N "checking for egrep... $ECHO_C" >&6; } if test "${ac_cv_path_EGREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 then ac_cv_path_EGREP="$GREP -E" else # Extract the first word of "egrep" to use in msg output if test -z "$EGREP"; then set dummy egrep; ac_prog_name=$2 if test "${ac_cv_path_EGREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_path_EGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in *GNU*) ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; *) ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" echo 'EGREP' >> "conftest.nl" "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break ac_count=`expr $ac_count + 1` if test $ac_count -gt ${ac_path_EGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_EGREP_found && break 3 done done done IFS=$as_save_IFS fi EGREP="$ac_cv_path_EGREP" if test -z "$EGREP"; then { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} { (exit 1); exit 1; }; } fi else ac_cv_path_EGREP=$EGREP fi fi fi { echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5 echo "${ECHO_T}$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" # Check whether --with-gnu-ld was given. if test "${with_gnu_ld+set}" = set; then withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes else with_gnu_ld=no fi ac_prog=ld if test "$GCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. { echo "$as_me:$LINENO: checking for ld used by $CC" >&5 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6; } case $host in *-*-mingw*) # gcc leaves a trailing carriage return which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [\\/]* | ?:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the pathname of ld ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD="$ac_prog" ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test "$with_gnu_ld" = yes; then { echo "$as_me:$LINENO: checking for GNU ld" >&5 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6; } else { echo "$as_me:$LINENO: checking for non-GNU ld" >&5 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6; } fi if test "${lt_cv_path_LD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -z "$LD"; then lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD="$ac_dir/$ac_prog" # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &5 echo "${ECHO_T}$LD" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;} { (exit 1); exit 1; }; } { echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6; } if test "${lt_cv_prog_gnu_ld+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 &5 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld { echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5 echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6; } if test "${lt_cv_ld_reload_flag+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_ld_reload_flag='-r' fi { echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5 echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6; } reload_flag=$lt_cv_ld_reload_flag case $reload_flag in "" | " "*) ;; *) reload_flag=" $reload_flag" ;; esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in darwin*) if test "$GCC" = yes; then reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' else reload_cmds='$LD$reload_flag -o $output$reload_objs' fi ;; esac { echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5 echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6; } if test "${lt_cv_path_NM+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM="$NM" else lt_nm_to_check="${ac_tool_prefix}nm" if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. tmp_nm="$ac_dir/$lt_tmp_nm" if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then # Check to see if the nm accepts a BSD-compat flag. # Adding the `sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in */dev/null* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but continue # so that we can try to find one that supports BSD flags ;; esac ;; esac fi done IFS="$lt_save_ifs" done test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm fi fi { echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5 echo "${ECHO_T}$lt_cv_path_NM" >&6; } NM="$lt_cv_path_NM" { echo "$as_me:$LINENO: checking whether ln -s works" >&5 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6; } LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } else { echo "$as_me:$LINENO: result: no, using $LN_S" >&5 echo "${ECHO_T}no, using $LN_S" >&6; } fi { echo "$as_me:$LINENO: checking how to recognize dependent libraries" >&5 echo $ECHO_N "checking how to recognize dependent libraries... $ECHO_C" >&6; } if test "${lt_cv_deplibs_check_method+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_file_magic_cmd='$MAGIC_CMD' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. # `unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # which responds to the $file_magic_cmd with a given extended regex. # If you have `file' or equivalent on your system and you're not sure # whether `pass_all' will *always* work, you probably want this one. case $host_os in aix[4-9]*) lt_cv_deplibs_check_method=pass_all ;; beos*) lt_cv_deplibs_check_method=pass_all ;; bsdi[45]*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' lt_cv_file_magic_cmd='/usr/bin/file -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; cygwin*) # func_win32_libid is a shell function defined in ltmain.sh lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' ;; mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | dragonfly*) if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac else lt_cv_deplibs_check_method=pass_all fi ;; gnu*) lt_cv_deplibs_check_method=pass_all ;; hpux10.20* | hpux11*) lt_cv_file_magic_cmd=/usr/bin/file case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so ;; hppa*64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]' lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library' lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac ;; interix[3-9]*) # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) case $LD in *-32|*"-32 ") libmagic=32-bit;; *-n32|*"-n32 ") libmagic=N32;; *-64|*"-64 ") libmagic=64-bit;; *) libmagic=never-match;; esac lt_cv_deplibs_check_method=pass_all ;; # This must be Linux ELF. linux* | k*bsd*-gnu) lt_cv_deplibs_check_method=pass_all ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' fi ;; newos6*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; nto-qnx*) lt_cv_deplibs_check_method=unknown ;; openbsd*) if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; rdos*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; ncr) lt_cv_deplibs_check_method=pass_all ;; sequent) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;; sni) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" lt_cv_file_magic_test_file=/lib/libc.so ;; siemens) lt_cv_deplibs_check_method=pass_all ;; pc) lt_cv_deplibs_check_method=pass_all ;; esac ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; esac fi { echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5 echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6; } file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # Check whether --enable-libtool-lock was given. if test "${enable_libtool_lock+set}" = set; then enableval=$enable_libtool_lock; fi test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then case `/usr/bin/file conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE="32" ;; *ELF-64*) HPUX_IA64_MODE="64" ;; esac fi rm -rf conftest* ;; *-*-irix6*) # Find out which ABI we are using. echo '#line __oline__ "configure"' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then if test "$lt_cv_prog_gnu_ld" = yes; then case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; *N32*) LD="${LD-ld} -melf32bmipn32" ;; *64-bit*) LD="${LD-ld} -melf64bmip" ;; esac else case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; *N32*) LD="${LD-ld} -n32" ;; *64-bit*) LD="${LD-ld} -64" ;; esac fi fi rm -rf conftest* ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ s390*-*linux*|sparc*-*linux*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then case `/usr/bin/file conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_i386" ;; ppc64-*linux*|powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) LD="${LD-ld} -m elf_s390" ;; sparc64-*linux*) LD="${LD-ld} -m elf32_sparc" ;; esac ;; *64-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; ppc*-*linux*|powerpc*-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*) LD="${LD-ld} -m elf64_s390" ;; sparc*-*linux*) LD="${LD-ld} -m elf64_sparc" ;; esac ;; esac fi rm -rf conftest* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -belf" { echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5 echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6; } if test "${lt_cv_cc_needs_belf+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_cv_cc_needs_belf=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 lt_cv_cc_needs_belf=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu fi { echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5 echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6; } if test x"$lt_cv_cc_needs_belf" != x"yes"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS="$SAVE_CFLAGS" fi ;; sparc*-*solaris*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then case `/usr/bin/file conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) LD="${LD-ld} -m elf64_sparc" ;; *) if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then LD="${LD-ld} -64" fi ;; esac ;; esac fi rm -rf conftest* ;; esac need_locks="$enable_libtool_lock" ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; } # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then if test "${ac_cv_prog_CPP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Double quotes because CPP needs to be expanded for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" do ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@ifdef __STDC__ @%:@ include @%:@else @%:@ include @%:@endif Syntax error _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@include _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then break fi done ac_cv_prog_CPP=$CPP fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi { echo "$as_me:$LINENO: result: $CPP" >&5 echo "${ECHO_T}$CPP" >&6; } ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@ifdef __STDC__ @%:@ include @%:@else @%:@ include @%:@endif Syntax error _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@include _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details." >&5 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { echo "$as_me:$LINENO: checking for ANSI C header files" >&5 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; } if test "${ac_cv_header_stdc+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_header_stdc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi fi { echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 echo "${ECHO_T}$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then cat >>confdefs.h <<\_ACEOF @%:@define STDC_HEADERS 1 _ACEOF fi # On IRIX 5.3, sys/types and inttypes.h are conflicting. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ inttypes.h stdint.h unistd.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default @%:@include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then eval "$as_ac_Header=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_Header=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF @%:@define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_header in dlfcn.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default @%:@include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX @%:@@%:@ ----------------------------------- @%:@@%:@ @%:@@%:@ Report this to support@land.ufrj.br @%:@@%:@ @%:@@%:@ ----------------------------------- @%:@@%:@ _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF @%:@define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu if test -z "$CXX"; then if test -n "$CCC"; then CXX=$CCC else if test -n "$ac_tool_prefix"; then for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CXX"; then ac_cv_prog_CXX="$CXX" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CXX=$ac_cv_prog_CXX if test -n "$CXX"; then { echo "$as_me:$LINENO: result: $CXX" >&5 echo "${ECHO_T}$CXX" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$CXX" && break done fi if test -z "$CXX"; then ac_ct_CXX=$CXX for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_CXX"; then ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CXX="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CXX=$ac_cv_prog_ac_ct_CXX if test -n "$ac_ct_CXX"; then { echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5 echo "${ECHO_T}$ac_ct_CXX" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$ac_ct_CXX" && break done if test "x$ac_ct_CXX" = x; then CXX="g++" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac CXX=$ac_ct_CXX fi fi fi fi # Provide some information about the compiler. echo "$as_me:$LINENO: checking for C++ compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (ac_try="$ac_compiler --version >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler --version >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -v >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -v >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -V >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -V >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5 echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6; } if test "${ac_cv_cxx_compiler_gnu+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_compiler_gnu=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_cxx_compiler_gnu=$ac_compiler_gnu fi { echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5 echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6; } GXX=`test $ac_compiler_gnu = yes && echo yes` ac_test_CXXFLAGS=${CXXFLAGS+set} ac_save_CXXFLAGS=$CXXFLAGS { echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5 echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6; } if test "${ac_cv_prog_cxx_g+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_save_cxx_werror_flag=$ac_cxx_werror_flag ac_cxx_werror_flag=yes ac_cv_prog_cxx_g=no CXXFLAGS="-g" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cxx_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 CXXFLAGS="" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cxx_werror_flag=$ac_save_cxx_werror_flag CXXFLAGS="-g" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cxx_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cxx_werror_flag=$ac_save_cxx_werror_flag fi { echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5 echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6; } if test "$ac_test_CXXFLAGS" = set; then CXXFLAGS=$ac_save_CXXFLAGS elif test $ac_cv_prog_cxx_g = yes; then if test "$GXX" = yes; then CXXFLAGS="-g -O2" else CXXFLAGS="-g" fi else if test "$GXX" = yes; then CXXFLAGS="-O2" else CXXFLAGS= fi fi ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu depcc="$CXX" am_compiler_list= { echo "$as_me:$LINENO: checking dependency style of $depcc" >&5 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6; } if test "${am_cv_CXX_dependencies_compiler_type+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CXX_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CXX_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CXX_dependencies_compiler_type=none fi fi { echo "$as_me:$LINENO: result: $am_cv_CXX_dependencies_compiler_type" >&5 echo "${ECHO_T}$am_cv_CXX_dependencies_compiler_type" >&6; } CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then am__fastdepCXX_TRUE= am__fastdepCXX_FALSE='#' else am__fastdepCXX_TRUE='#' am__fastdepCXX_FALSE= fi if test -n "$CXX" && ( test "X$CXX" != "Xno" && ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || (test "X$CXX" != "Xg++"))) ; then ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu { echo "$as_me:$LINENO: checking how to run the C++ preprocessor" >&5 echo $ECHO_N "checking how to run the C++ preprocessor... $ECHO_C" >&6; } if test -z "$CXXCPP"; then if test "${ac_cv_prog_CXXCPP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Double quotes because CXXCPP needs to be expanded for CXXCPP in "$CXX -E" "/lib/cpp" do ac_preproc_ok=false for ac_cxx_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@ifdef __STDC__ @%:@ include @%:@else @%:@ include @%:@endif Syntax error _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || test ! -s conftest.err }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@include _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then break fi done ac_cv_prog_CXXCPP=$CXXCPP fi CXXCPP=$ac_cv_prog_CXXCPP else ac_cv_prog_CXXCPP=$CXXCPP fi { echo "$as_me:$LINENO: result: $CXXCPP" >&5 echo "${ECHO_T}$CXXCPP" >&6; } ac_preproc_ok=false for ac_cxx_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@ifdef __STDC__ @%:@ include @%:@else @%:@ include @%:@endif Syntax error _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || test ! -s conftest.err }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@include _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { echo "$as_me:$LINENO: error: C++ preprocessor \"$CXXCPP\" fails sanity check See \`config.log' for more details." >&5 echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi ac_ext=f ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&5' ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_f77_compiler_gnu if test -n "$ac_tool_prefix"; then for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$F77"; then ac_cv_prog_F77="$F77" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_F77="$ac_tool_prefix$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi F77=$ac_cv_prog_F77 if test -n "$F77"; then { echo "$as_me:$LINENO: result: $F77" >&5 echo "${ECHO_T}$F77" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$F77" && break done fi if test -z "$F77"; then ac_ct_F77=$F77 for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_F77"; then ac_cv_prog_ac_ct_F77="$ac_ct_F77" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_F77="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_F77=$ac_cv_prog_ac_ct_F77 if test -n "$ac_ct_F77"; then { echo "$as_me:$LINENO: result: $ac_ct_F77" >&5 echo "${ECHO_T}$ac_ct_F77" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$ac_ct_F77" && break done if test "x$ac_ct_F77" = x; then F77="" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac F77=$ac_ct_F77 fi fi # Provide some information about the compiler. echo "$as_me:$LINENO: checking for Fortran 77 compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (ac_try="$ac_compiler --version >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler --version >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -v >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -v >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -V >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -V >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } rm -f a.out # If we don't use `.F' as extension, the preprocessor is not run on the # input file. (Note that this only needs to work for GNU compilers.) ac_save_ext=$ac_ext ac_ext=F { echo "$as_me:$LINENO: checking whether we are using the GNU Fortran 77 compiler" >&5 echo $ECHO_N "checking whether we are using the GNU Fortran 77 compiler... $ECHO_C" >&6; } if test "${ac_cv_f77_compiler_gnu+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF program main #ifndef __GNUC__ choke me #endif end _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_f77_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_compiler_gnu=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_f77_compiler_gnu=$ac_compiler_gnu fi { echo "$as_me:$LINENO: result: $ac_cv_f77_compiler_gnu" >&5 echo "${ECHO_T}$ac_cv_f77_compiler_gnu" >&6; } ac_ext=$ac_save_ext ac_test_FFLAGS=${FFLAGS+set} ac_save_FFLAGS=$FFLAGS FFLAGS= { echo "$as_me:$LINENO: checking whether $F77 accepts -g" >&5 echo $ECHO_N "checking whether $F77 accepts -g... $ECHO_C" >&6; } if test "${ac_cv_prog_f77_g+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else FFLAGS=-g cat >conftest.$ac_ext <<_ACEOF program main end _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_f77_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_f77_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_prog_f77_g=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_prog_f77_g" >&5 echo "${ECHO_T}$ac_cv_prog_f77_g" >&6; } if test "$ac_test_FFLAGS" = set; then FFLAGS=$ac_save_FFLAGS elif test $ac_cv_prog_f77_g = yes; then if test "x$ac_cv_f77_compiler_gnu" = xyes; then FFLAGS="-g -O2" else FFLAGS="-g" fi else if test "x$ac_cv_f77_compiler_gnu" = xyes; then FFLAGS="-O2" else FFLAGS= fi fi G77=`test $ac_compiler_gnu = yes && echo yes` ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! # find the maximum length of command line arguments { echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5 echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6; } if test "${lt_cv_sys_max_cmd_len+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else i=0 teststring="ABCD" case $build_os in msdosdjgpp*) # On DJGPP, this test can blow up pretty badly due to problems in libc # (any single argument exceeding 2000 bytes causes a buffer overrun # during glob expansion). Even if it were fixed, the result of this # check would be larger than it should be. lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; gnu*) # Under GNU Hurd, this test is not required because there is # no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; cygwin* | mingw*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, # you end up with a "frozen" computer, even though with patience # the test eventually succeeds (with a max line length of 256k). # Instead, let's just punt: use the minimum linelength reported by # all of the supported platforms: 8192 (on NT/2K/XP). lt_cv_sys_max_cmd_len=8192; ;; amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` elif test -x /usr/sbin/sysctl; then lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi # And add a safety zone lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; interix*) # We know the value 262144 and hardcode it with a safety zone (like BSD) lt_cv_sys_max_cmd_len=196608 ;; osf*) # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not # nice to cause kernel panics so lets avoid the loop below. # First set a reasonable default. lt_cv_sys_max_cmd_len=16384 # if test -x /sbin/sysconfig; then case `/sbin/sysconfig -q proc exec_disable_arg_limit` in *1*) lt_cv_sys_max_cmd_len=-1 ;; esac fi ;; sco3.2v5*) lt_cv_sys_max_cmd_len=102400 ;; sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` else lt_cv_sys_max_cmd_len=32768 fi ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` if test -n "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \ = "XX$teststring") >/dev/null 2>&1 && new_result=`expr "X$teststring" : ".*" 2>&1` && lt_cv_sys_max_cmd_len=$new_result && test $i != 17 # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring done teststring= # Add a significant safety factor because C++ compilers can tack on massive # amounts of additional arguments before passing them to the linker. # It appears as though 1/2 is a usable value. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` fi ;; esac fi if test -n $lt_cv_sys_max_cmd_len ; then { echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5 echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6; } else { echo "$as_me:$LINENO: result: none" >&5 echo "${ECHO_T}none" >&6; } fi # Check for command to grab the raw symbol name followed by C symbol from nm. { echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5 echo $ECHO_N "checking command to parse $NM output from $compiler object... $ECHO_C" >&6; } if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # Character class describing NM global symbol codes. symcode='[BCDEGRST]' # Regexp to match symbols that can be accessed directly from C. sympat='\([_A-Za-z][_A-Za-z0-9]*\)' # Transform an extracted symbol line into a proper C declaration lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" # Transform an extracted symbol line into symbol name and symbol address lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" # Define system-specific variables. case $host_os in aix*) symcode='[BCDT]' ;; cygwin* | mingw* | pw32*) symcode='[ABCDGISTW]' ;; hpux*) # Its linker distinguishes data from code symbols if test "$host_cpu" = ia64; then symcode='[ABCDEGRST]' fi lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" ;; linux* | k*bsd*-gnu) if test "$host_cpu" = ia64; then symcode='[ABCDGIRSTW]' lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" fi ;; irix* | nonstopux*) symcode='[BCDEGRST]' ;; osf*) symcode='[BCDEGQRST]' ;; solaris*) symcode='[BDRT]' ;; sco3.2v5*) symcode='[DT]' ;; sysv4.2uw2*) symcode='[DT]' ;; sysv5* | sco5v6* | unixware* | OpenUNIX*) symcode='[ABDT]' ;; sysv4) symcode='[DFNSTU]' ;; esac # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac # If we're using GNU nm, then use its standard symbol codes. case `$NM -V 2>&1` in *GNU* | *'with BFD'*) symcode='[ABCDGIRSTW]' ;; esac # Try without a prefix undercore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* cat > conftest.$ac_ext <&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # Now try to grab the symbols. nlist=conftest.nm if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5 (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" else rm -f "$nlist"T fi # Make sure that we snagged all the symbols we need. if grep ' nm_test_var$' "$nlist" >/dev/null; then if grep ' nm_test_func$' "$nlist" >/dev/null; then cat < conftest.$ac_ext #ifdef __cplusplus extern "C" { #endif EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' cat <> conftest.$ac_ext #if defined (__STDC__) && __STDC__ # define lt_ptr_t void * #else # define lt_ptr_t char * # define const #endif /* The mapping between symbol names and symbols. */ const struct { const char *name; lt_ptr_t address; } lt_preloaded_symbols[] = { EOF $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext cat <<\EOF >> conftest.$ac_ext {0, (lt_ptr_t) 0} }; #ifdef __cplusplus } #endif EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_save_LIBS="$LIBS" lt_save_CFLAGS="$CFLAGS" LIBS="conftstm.$ac_objext" CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext}; then pipe_works=yes fi LIBS="$lt_save_LIBS" CFLAGS="$lt_save_CFLAGS" else echo "cannot find nm_test_func in $nlist" >&5 fi else echo "cannot find nm_test_var in $nlist" >&5 fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 fi else echo "$progname: failed program was:" >&5 cat conftest.$ac_ext >&5 fi rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. if test "$pipe_works" = yes; then break else lt_cv_sys_global_symbol_pipe= fi done fi if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then { echo "$as_me:$LINENO: result: failed" >&5 echo "${ECHO_T}failed" >&6; } else { echo "$as_me:$LINENO: result: ok" >&5 echo "${ECHO_T}ok" >&6; } fi { echo "$as_me:$LINENO: checking for objdir" >&5 echo $ECHO_N "checking for objdir... $ECHO_C" >&6; } if test "${lt_cv_objdir+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi rmdir .libs 2>/dev/null fi { echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5 echo "${ECHO_T}$lt_cv_objdir" >&6; } objdir=$lt_cv_objdir case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test "X${COLLECT_NAMES+set}" != Xset; then COLLECT_NAMES= export COLLECT_NAMES fi ;; esac # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. Xsed='sed -e 1s/^X//' sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g' # Same as above, but do not quote variable references. double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g' # Sed substitution to delay expansion of an escaped shell variable in a # double_quote_subst'ed string. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' # Sed substitution to avoid accidental globbing in evaled expressions no_glob_subst='s/\*/\\\*/g' # Constants: rm="rm -f" # Global variables: default_ofile=libtool can_build_shared=yes # All known linkers require a `.a' archive for static linking (except MSVC, # which needs '.lib'). libext=a ltmain="$ac_aux_dir/ltmain.sh" ofile="$default_ofile" with_gnu_ld="$lt_cv_prog_gnu_ld" if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. set dummy ${ac_tool_prefix}ar; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_AR+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$AR"; then ac_cv_prog_AR="$AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_AR="${ac_tool_prefix}ar" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AR=$ac_cv_prog_AR if test -n "$AR"; then { echo "$as_me:$LINENO: result: $AR" >&5 echo "${ECHO_T}$AR" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_AR"; then ac_ct_AR=$AR # Extract the first word of "ar", so it can be a program name with args. set dummy ar; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_AR+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_AR"; then ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_AR="ar" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_AR=$ac_cv_prog_ac_ct_AR if test -n "$ac_ct_AR"; then { echo "$as_me:$LINENO: result: $ac_ct_AR" >&5 echo "${ECHO_T}$ac_ct_AR" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_AR" = x; then AR="false" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac AR=$ac_ct_AR fi else AR="$ac_cv_prog_AR" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. set dummy ${ac_tool_prefix}ranlib; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_RANLIB+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$RANLIB"; then ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi RANLIB=$ac_cv_prog_RANLIB if test -n "$RANLIB"; then { echo "$as_me:$LINENO: result: $RANLIB" >&5 echo "${ECHO_T}$RANLIB" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_RANLIB"; then ac_ct_RANLIB=$RANLIB # Extract the first word of "ranlib", so it can be a program name with args. set dummy ranlib; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_RANLIB"; then ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_RANLIB="ranlib" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB if test -n "$ac_ct_RANLIB"; then { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5 echo "${ECHO_T}$ac_ct_RANLIB" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_RANLIB" = x; then RANLIB=":" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac RANLIB=$ac_ct_RANLIB fi else RANLIB="$ac_cv_prog_RANLIB" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { echo "$as_me:$LINENO: result: $STRIP" >&5 echo "${ECHO_T}$STRIP" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_STRIP="strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5 echo "${ECHO_T}$ac_ct_STRIP" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi old_CC="$CC" old_CFLAGS="$CFLAGS" # Set sane defaults for various variables test -z "$AR" && AR=ar test -z "$AR_FLAGS" && AR_FLAGS=cru test -z "$AS" && AS=as test -z "$CC" && CC=cc test -z "$LTCC" && LTCC=$CC test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS test -z "$DLLTOOL" && DLLTOOL=dlltool test -z "$LD" && LD=ld test -z "$LN_S" && LN_S="ln -s" test -z "$MAGIC_CMD" && MAGIC_CMD=file test -z "$NM" && NM=nm test -z "$SED" && SED=sed test -z "$OBJDUMP" && OBJDUMP=objdump test -z "$RANLIB" && RANLIB=: test -z "$STRIP" && STRIP=: test -z "$ac_objext" && ac_objext=o # Determine commands to create old-style static archives. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" ;; *) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" fi for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` # Only perform the check for file, if the check method requires it case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then { echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5 echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6; } if test "${lt_cv_path_MAGIC_CMD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD="$MAGIC_CMD" lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/${ac_tool_prefix}file; then lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD="$lt_cv_path_MAGIC_CMD" if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org EOF fi ;; esac fi break fi done IFS="$lt_save_ifs" MAGIC_CMD="$lt_save_MAGIC_CMD" ;; esac fi MAGIC_CMD="$lt_cv_path_MAGIC_CMD" if test -n "$MAGIC_CMD"; then { echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5 echo "${ECHO_T}$MAGIC_CMD" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then { echo "$as_me:$LINENO: checking for file" >&5 echo $ECHO_N "checking for file... $ECHO_C" >&6; } if test "${lt_cv_path_MAGIC_CMD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD="$MAGIC_CMD" lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/file; then lt_cv_path_MAGIC_CMD="$ac_dir/file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD="$lt_cv_path_MAGIC_CMD" if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org EOF fi ;; esac fi break fi done IFS="$lt_save_ifs" MAGIC_CMD="$lt_save_MAGIC_CMD" ;; esac fi MAGIC_CMD="$lt_cv_path_MAGIC_CMD" if test -n "$MAGIC_CMD"; then { echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5 echo "${ECHO_T}$MAGIC_CMD" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi else MAGIC_CMD=: fi fi fi ;; esac case $host_os in rhapsody* | darwin*) if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_DSYMUTIL+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$DSYMUTIL"; then ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DSYMUTIL=$ac_cv_prog_DSYMUTIL if test -n "$DSYMUTIL"; then { echo "$as_me:$LINENO: result: $DSYMUTIL" >&5 echo "${ECHO_T}$DSYMUTIL" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_DSYMUTIL"; then ac_ct_DSYMUTIL=$DSYMUTIL # Extract the first word of "dsymutil", so it can be a program name with args. set dummy dsymutil; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_DSYMUTIL+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_DSYMUTIL"; then ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL if test -n "$ac_ct_DSYMUTIL"; then { echo "$as_me:$LINENO: result: $ac_ct_DSYMUTIL" >&5 echo "${ECHO_T}$ac_ct_DSYMUTIL" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_DSYMUTIL" = x; then DSYMUTIL=":" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac DSYMUTIL=$ac_ct_DSYMUTIL fi else DSYMUTIL="$ac_cv_prog_DSYMUTIL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. set dummy ${ac_tool_prefix}nmedit; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_NMEDIT+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$NMEDIT"; then ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi NMEDIT=$ac_cv_prog_NMEDIT if test -n "$NMEDIT"; then { echo "$as_me:$LINENO: result: $NMEDIT" >&5 echo "${ECHO_T}$NMEDIT" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_NMEDIT"; then ac_ct_NMEDIT=$NMEDIT # Extract the first word of "nmedit", so it can be a program name with args. set dummy nmedit; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_NMEDIT+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_NMEDIT"; then ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_NMEDIT="nmedit" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT if test -n "$ac_ct_NMEDIT"; then { echo "$as_me:$LINENO: result: $ac_ct_NMEDIT" >&5 echo "${ECHO_T}$ac_ct_NMEDIT" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_NMEDIT" = x; then NMEDIT=":" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac NMEDIT=$ac_ct_NMEDIT fi else NMEDIT="$ac_cv_prog_NMEDIT" fi { echo "$as_me:$LINENO: checking for -single_module linker flag" >&5 echo $ECHO_N "checking for -single_module linker flag... $ECHO_C" >&6; } if test "${lt_cv_apple_cc_single_mod+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_apple_cc_single_mod=no if test -z "${LT_MULTI_MODULE}"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. echo "int foo(void){return 1;}" > conftest.c $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib ${wl}-single_module conftest.c if test -f libconftest.dylib; then lt_cv_apple_cc_single_mod=yes rm -rf libconftest.dylib* fi rm conftest.c fi fi { echo "$as_me:$LINENO: result: $lt_cv_apple_cc_single_mod" >&5 echo "${ECHO_T}$lt_cv_apple_cc_single_mod" >&6; } { echo "$as_me:$LINENO: checking for -exported_symbols_list linker flag" >&5 echo $ECHO_N "checking for -exported_symbols_list linker flag... $ECHO_C" >&6; } if test "${lt_cv_ld_exported_symbols_list+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_cv_ld_exported_symbols_list=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 lt_cv_ld_exported_symbols_list=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LDFLAGS="$save_LDFLAGS" fi { echo "$as_me:$LINENO: result: $lt_cv_ld_exported_symbols_list" >&5 echo "${ECHO_T}$lt_cv_ld_exported_symbols_list" >&6; } case $host_os in rhapsody* | darwin1.[0123]) _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; darwin*) # if running on 10.5 or later, the deployment target defaults # to the OS version, if on x86, and 10.4, the deployment # target defaults to 10.4. Don't you love it? case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 10.0,*86*-darwin8*|10.0,*-darwin[91]*) _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 10.[012]*) _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 10.*) _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; esac ;; esac if test "$lt_cv_apple_cc_single_mod" = "yes"; then _lt_dar_single_mod='$single_module' fi if test "$lt_cv_ld_exported_symbols_list" = "yes"; then _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' else _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}" fi if test "$DSYMUTIL" != ":"; then _lt_dsymutil="~$DSYMUTIL \$lib || :" else _lt_dsymutil= fi ;; esac enable_dlopen=no enable_win32_dll=no # Check whether --enable-libtool-lock was given. if test "${enable_libtool_lock+set}" = set; then enableval=$enable_libtool_lock; fi test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes # Check whether --with-pic was given. if test "${with_pic+set}" = set; then withval=$with_pic; pic_mode="$withval" else pic_mode=default fi test -z "$pic_mode" && pic_mode=default # Use C for the default configuration in the libtool script tagname= lt_save_CC="$CC" ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o objext=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $rm conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $rm -r conftest* lt_prog_compiler_no_builtin_flag= if test "$GCC" = yes; then lt_prog_compiler_no_builtin_flag=' -fno-builtin' { echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-fno-rtti -fno-exceptions" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:__oline__: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_rtti_exceptions=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6; } if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" else : fi fi lt_prog_compiler_wl= lt_prog_compiler_pic= lt_prog_compiler_static= { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; } if test "$GCC" = yes; then lt_prog_compiler_wl='-Wl,' lt_prog_compiler_static='-static' case $host_os in aix*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' fi ;; amigaos*) # FIXME: we need at least 68020 code to build shared libraries, but # adding the `-m68020' flag to GCC prevents building anything better, # like `-m68040'. lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic='-DDLL_EXPORT' ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. lt_prog_compiler_can_build_shared=no enable_shared=no ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic=-Kconform_pic fi ;; hpux*) # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic='-fPIC' ;; esac ;; *) lt_prog_compiler_pic='-fPIC' ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) lt_prog_compiler_wl='-Wl,' if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' else lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' fi ;; darwin*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files case $cc_basename in xlc*) lt_prog_compiler_pic='-qnocommon' lt_prog_compiler_wl='-Wl,' ;; esac ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). lt_prog_compiler_pic='-DDLL_EXPORT' ;; hpux9* | hpux10* | hpux11*) lt_prog_compiler_wl='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? lt_prog_compiler_static='${wl}-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) lt_prog_compiler_wl='-Wl,' # PIC (with -KPIC) is the default. lt_prog_compiler_static='-non_shared' ;; newsos6) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; linux* | k*bsd*-gnu) case $cc_basename in icc* | ecc*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-static' ;; pgcc* | pgf77* | pgf90* | pgf95*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fpic' lt_prog_compiler_static='-Bstatic' ;; ccc*) lt_prog_compiler_wl='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static='-non_shared' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='-Wl,' ;; *Sun\ F*) # Sun Fortran 8.3 passes all unrecognized flags to the linker lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='' ;; esac ;; esac ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static='-non_shared' ;; rdos*) lt_prog_compiler_static='-non_shared' ;; solaris*) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' case $cc_basename in f77* | f90* | f95*) lt_prog_compiler_wl='-Qoption ld ';; *) lt_prog_compiler_wl='-Wl,';; esac ;; sunos4*) lt_prog_compiler_wl='-Qoption ld ' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec ;then lt_prog_compiler_pic='-Kconform_pic' lt_prog_compiler_static='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; unicos*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_can_build_shared=no ;; uts4*) lt_prog_compiler_pic='-pic' lt_prog_compiler_static='-Bstatic' ;; *) lt_prog_compiler_can_build_shared=no ;; esac fi { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5 echo "${ECHO_T}$lt_prog_compiler_pic" >&6; } # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic"; then { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_pic_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_pic_works=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic -DPIC" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:__oline__: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_pic_works" >&6; } if test x"$lt_cv_prog_compiler_pic_works" = xyes; then case $lt_prog_compiler_pic in "" | " "*) ;; *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; esac else lt_prog_compiler_pic= lt_prog_compiler_can_build_shared=no fi fi case $host_os in # For platforms which do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic= ;; *) lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" ;; esac # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_static_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_static_works=no save_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works=yes fi else lt_cv_prog_compiler_static_works=yes fi fi $rm -r conftest* LDFLAGS="$save_LDFLAGS" fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_static_works" >&6; } if test x"$lt_cv_prog_compiler_static_works" = xyes; then : else lt_prog_compiler_static= fi { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_c_o+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:__oline__: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o=yes fi fi chmod u+w . 2>&5 $rm conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files $rm out/* && rmdir out cd .. rmdir conftest $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6; } hard_links="nottested" if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then # do not overwrite the value of need_locks provided by the user { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; } hard_links=yes $rm conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6; } if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; } runpath_var= allow_undefined_flag= enable_shared_with_static_runtimes=no archive_cmds= archive_expsym_cmds= old_archive_From_new_cmds= old_archive_from_expsyms_cmds= export_dynamic_flag_spec= whole_archive_flag_spec= thread_safe_flag_spec= hardcode_libdir_flag_spec= hardcode_libdir_flag_spec_ld= hardcode_libdir_separator= hardcode_direct=no hardcode_minus_L=no hardcode_shlibpath_var=unsupported link_all_deplibs=unknown hardcode_automatic=no module_cmds= module_expsym_cmds= always_export_symbols=no export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list include_expsyms= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ` (' and `)$', so one must not match beginning or # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', # as well as any symbol that contains `d'. exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. extract_expsyms_cmds= # Just being paranoid about ensuring that cc_basename is set. for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` case $host_os in cygwin* | mingw* | pw32*) # FIXME: the MSVC++ port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++. if test "$GCC" != yes; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++) with_gnu_ld=yes ;; openbsd*) with_gnu_ld=no ;; esac ld_shlibs=yes if test "$with_gnu_ld" = yes; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='${wl}' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir' export_dynamic_flag_spec='${wl}--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else whole_archive_flag_spec= fi supports_anon_versioning=no case `$LD -v 2>/dev/null` in *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[3-9]*) # On AIX/PPC, the GNU linker is very broken if test "$host_cpu" != ia64; then ld_shlibs=no cat <&2 *** Warning: the GNU linker, at least up to release 2.9.1, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to modify your PATH *** so that a non-GNU linker is found, and then restart. EOF fi ;; amigaos*) archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes # Samuel A. Falvo II reports # that the semantics of dynamic libraries on AmigaOS, at least up # to version 4, is to share data among multiple programs linked # with the same dynamic library. Since this doesn't match the # behavior of shared libraries on other platforms, we can't use # them. ld_shlibs=no ;; beos*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then allow_undefined_flag=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' else ld_shlibs=no fi ;; cygwin* | mingw* | pw32*) # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec='-L$libdir' allow_undefined_flag=unsupported always_export_symbols=no enable_shared_with_static_runtimes=yes export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file (1st line # is EXPORTS), use it as is; otherwise, prepend... archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs=no fi ;; interix[3-9]*) hardcode_direct=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='${wl}-rpath,$libdir' export_dynamic_flag_spec='${wl}-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | k*bsd*-gnu) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then tmp_addflag= case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; esac case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; *) tmp_sharedflag='-shared' ;; esac archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' if test $supports_anon_versioning = yes; then archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ $echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' fi link_all_deplibs=no else ld_shlibs=no fi ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then ld_shlibs=no cat <&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. EOF elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' else ld_shlibs=no fi ;; esac ;; sunos4*) archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct=yes hardcode_shlibpath_var=no ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; esac if test "$ld_shlibs" = no; then runpath_var= hardcode_libdir_flag_spec= export_dynamic_flag_spec= whole_archive_flag_spec= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) allow_undefined_flag=unsupported always_export_symbols=yes archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. hardcode_minus_L=yes if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct=unsupported fi ;; aix[4-9]*) if test "$host_cpu" = ia64; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag="" else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to AIX nm, but means don't demangle with GNU nm if $NM -V 2>&1 | grep 'GNU' > /dev/null; then export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' else export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # need to do runtime linking. case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then aix_use_runtimelinking=yes break fi done ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds='' hardcode_direct=yes hardcode_libdir_separator=':' link_all_deplibs=yes if test "$GCC" = yes; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`${CC} -print-prog-name=collect2` if test -f "$collect2name" && \ strings "$collect2name" | grep resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L=yes hardcode_libdir_flag_spec='-L$libdir' hardcode_libdir_separator= fi ;; esac shared_flag='-shared' if test "$aix_use_runtimelinking" = yes; then shared_flag="$shared_flag "'${wl}-G' fi else # not using gcc if test "$host_cpu" = ia64; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test "$aix_use_runtimelinking" = yes; then shared_flag='${wl}-G' else shared_flag='${wl}-bM:SRE' fi fi fi # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols=yes if test "$aix_use_runtimelinking" = yes; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag='-berok' # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" else if test "$host_cpu" = ia64; then hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' allow_undefined_flag="-z nodefs" archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag=' ${wl}-bernotok' allow_undefined_flag=' ${wl}-berok' # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec='$convenience' archive_cmds_need_lc=yes # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; amigaos*) archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes # see comment about different semantics on the GNU ld section ld_shlibs=no ;; bsdi[45]*) export_dynamic_flag_spec=-rdynamic ;; cygwin* | mingw* | pw32*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=".dll" # FIXME: Setting linknames here is a bad hack. archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. old_archive_From_new_cmds='true' # FIXME: Should let the user specify the lib program. old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' fix_srcfile_path='`cygpath -w "$srcfile"`' enable_shared_with_static_runtimes=yes ;; darwin* | rhapsody*) case $host_os in rhapsody* | darwin1.[012]) allow_undefined_flag='${wl}-undefined ${wl}suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[012]) allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 10.*) allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup' ;; esac fi ;; esac archive_cmds_need_lc=no hardcode_direct=no hardcode_automatic=yes hardcode_shlibpath_var=unsupported whole_archive_flag_spec='' link_all_deplibs=yes if test "$GCC" = yes ; then output_verbose_link_cmd='echo' archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" else case $cc_basename in xlc*) output_verbose_link_cmd='echo' archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' module_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' ;; *) ld_shlibs=no ;; esac fi ;; dgux*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; freebsd1*) ld_shlibs=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly*) archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; hpux9*) if test "$GCC" = yes; then archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' else archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' fi hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' hardcode_libdir_separator=: hardcode_direct=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes export_dynamic_flag_spec='${wl}-E' ;; hpux10*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' hardcode_libdir_separator=: hardcode_direct=yes export_dynamic_flag_spec='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes fi ;; hpux11*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then case $host_cpu in hppa*64*) archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' hardcode_libdir_separator=: case $host_cpu in hppa*64*|ia64*) hardcode_libdir_flag_spec_ld='+b $libdir' hardcode_direct=no hardcode_shlibpath_var=no ;; *) hardcode_direct=yes export_dynamic_flag_spec='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test "$GCC" = yes; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_ld='-rpath $libdir' fi hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator=: link_all_deplibs=yes ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; newsos6) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator=: hardcode_shlibpath_var=no ;; openbsd*) if test -f /usr/libexec/ld.so; then hardcode_direct=yes hardcode_shlibpath_var=no if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' hardcode_libdir_flag_spec='${wl}-rpath,$libdir' export_dynamic_flag_spec='${wl}-E' else case $host_os in openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-R$libdir' ;; *) archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='${wl}-rpath,$libdir' ;; esac fi else ld_shlibs=no fi ;; os2*) hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes allow_undefined_flag=unsupported archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' ;; osf3*) if test "$GCC" = yes; then allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' fi hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test "$GCC" = yes; then allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec='-rpath $libdir' fi hardcode_libdir_separator=: ;; solaris*) no_undefined_flag=' -z text' if test "$GCC" = yes; then wlarc='${wl}' archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' else wlarc='' archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' fi hardcode_libdir_flag_spec='-R$libdir' hardcode_shlibpath_var=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands `-z linker_flag'. GCC discards it without `$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test "$GCC" = yes; then whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' else whole_archive_flag_spec='-z allextract$convenience -z defaultextract' fi ;; esac link_all_deplibs=yes ;; sunos4*) if test "x$host_vendor" = xsequent; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi hardcode_libdir_flag_spec='-L$libdir' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; sysv4) case $host_vendor in sni) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' reload_cmds='$CC -r -o $output$reload_objs' hardcode_direct=no ;; motorola) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' hardcode_shlibpath_var=no ;; sysv4.3*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no export_dynamic_flag_spec='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ld_shlibs=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag='${wl}-z,text' archive_cmds_need_lc=no hardcode_shlibpath_var=no runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We can NOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag='${wl}-z,text' allow_undefined_flag='${wl}-z,nodefs' archive_cmds_need_lc=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' hardcode_libdir_separator=':' link_all_deplibs=yes export_dynamic_flag_spec='${wl}-Bexport' runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; *) ld_shlibs=no ;; esac fi { echo "$as_me:$LINENO: result: $ld_shlibs" >&5 echo "${ECHO_T}$ld_shlibs" >&6; } test "$ld_shlibs" = no && can_build_shared=no # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc" in x|xyes) # Assume -lc should be added archive_cmds_need_lc=yes if test "$enable_shared" = yes && test "$GCC" = yes; then case $archive_cmds in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; } $rm conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl pic_flag=$lt_prog_compiler_pic compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag allow_undefined_flag= if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } then archive_cmds_need_lc=no else archive_cmds_need_lc=yes fi allow_undefined_flag=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $rm conftest* { echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5 echo "${ECHO_T}$archive_cmds_need_lc" >&6; } ;; esac fi ;; esac { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; } library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=".so" postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" if test "$GCC" = yes; then case $host_os in darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; *) lt_awk_arg="/^libraries:/" ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then # if the path contains ";" then we assume it to be the separator # otherwise default to the standard path separator (i.e. ":") - it is # assumed that no part of a normal pathname contains ";" but that should # okay in the real world where ";" in dirpaths is itself problematic. lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'` else lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # Ok, now we have the path, separated by spaces, we can step through it # and add multilib dir if necessary. lt_tmp_lt_search_path_spec= lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` for lt_sys_path in $lt_search_path_spec; do if test -d "$lt_sys_path/$lt_multi_os_dir"; then lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" else test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk ' BEGIN {RS=" "; FS="/|\n";} { lt_foo=""; lt_count=0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { lt_foo="/" $lt_i lt_foo; } else { lt_count--; } } } } if (lt_foo != "") { lt_freq[lt_foo]++; } if (lt_freq[lt_foo] == 1) { print lt_foo; } }'` sys_lib_search_path_spec=`echo $lt_search_path_spec` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='${libname}${release}${shared_ext}$major' ;; aix[4-9]*) version_type=linux need_lib_prefix=no need_version=no hardcode_into_libs=yes if test "$host_cpu" = ia64; then # AIX 5 supports IA64 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line `#! .'. This would cause the generated library to # depend on `.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then : else can_build_shared=no fi ;; esac # AIX (on Power*) has no versioning support, so currently we can not hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. if test "$aix_use_runtimelinking" = yes; then # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' else # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='${libname}${release}.a $libname.a' soname_spec='${libname}${release}${shared_ext}$major' fi shlibpath_var=LIBPATH fi ;; amigaos*) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; beos*) library_names_spec='${libname}${shared_ext}' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32*) version_type=windows shrext_cmds=".dll" need_version=no need_lib_prefix=no case $GCC,$host_os in yes,cygwin* | yes,mingw* | yes,pw32*) library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \${file}`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" ;; mingw*) # MinGW DLLs use traditional 'lib' prefix soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH printed by # mingw gcc, but we are running on Cygwin. Gcc prints its search # path with ; separators, and with drive letters. We can handle the # drive letters (cygwin fileutils understands them), so leave them, # especially as we might pass files found there to a mingw objdump, # which wouldn't understand a cygwinified path. Ahh. sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' ;; esac ;; *) library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' ;; esac dynamic_linker='Win32 ld.exe' # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' soname_spec='${libname}${release}${major}$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd1*) dynamic_linker=no ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[123]*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; gnu*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' if test "X$HPUX_IA64_MODE" = X32; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" fi sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555. postinstall_cmds='chmod 555 $lib' ;; interix[3-9]*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test "$lt_cv_prog_gnu_ld" = yes; then version_type=linux else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. linux* | k*bsd*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Append ld.so.conf contents to the search path if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsdelf*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; nto-qnx*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; openbsd*) version_type=sunos sys_lib_dlsearch_path_spec="/usr/lib" need_lib_prefix=no # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. case $host_os in openbsd3.3 | openbsd3.3.*) need_version=yes ;; *) need_version=no ;; esac library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then case $host_os in openbsd2.[89] | openbsd2.[89].*) shlibpath_overrides_runpath=no ;; *) shlibpath_overrides_runpath=yes ;; esac else shlibpath_overrides_runpath=yes fi ;; os2*) libname_spec='$name' shrext_cmds=".dll" need_lib_prefix=no library_names_spec='$libname${shared_ext} $libname.a' dynamic_linker='OS/2 ld.exe' shlibpath_var=LIBPATH ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test "$with_gnu_ld" = yes; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no export_dynamic_flag_spec='${wl}-Blargedynsym' runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec ;then version_type=linux library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' soname_spec='$libname${shared_ext}.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=freebsd-elf need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes if test "$with_gnu_ld" = yes; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' shlibpath_overrides_runpath=no else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' shlibpath_overrides_runpath=yes case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; uts4*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6; } test "$dynamic_linker" = no && can_build_shared=no if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" fi sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" fi sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test "$GCC" = yes; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; } hardcode_action= if test -n "$hardcode_libdir_flag_spec" || \ test -n "$runpath_var" || \ test "X$hardcode_automatic" = "Xyes" ; then # We can hardcode non-existant directories. if test "$hardcode_direct" != no && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no && test "$hardcode_minus_L" != no; then # Linking always hardcodes the temporary library directory. hardcode_action=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action=unsupported fi { echo "$as_me:$LINENO: result: $hardcode_action" >&5 echo "${ECHO_T}$hardcode_action" >&6; } if test "$hardcode_action" = relink; then # Fast installation is not supported enable_fast_install=no elif test "$shlibpath_overrides_runpath" = yes || test "$enable_shared" = no; then # Fast installation is not necessary enable_fast_install=needless fi striplib= old_striplib= { echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6; } if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" test -z "$striplib" && striplib="$STRIP --strip-unneeded" { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } else # FIXME - insert some real tests, host_os isn't really good enough case $host_os in darwin*) if test -n "$STRIP" ; then striplib="$STRIP -x" old_striplib="$STRIP -S" { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi ;; *) { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } ;; esac fi if test "x$enable_dlopen" != xyes; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown else lt_cv_dlopen=no lt_cv_dlopen_libs= case $host_os in beos*) lt_cv_dlopen="load_add_on" lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32*) lt_cv_dlopen="LoadLibrary" lt_cv_dlopen_libs= ;; cygwin*) lt_cv_dlopen="dlopen" lt_cv_dlopen_libs= ;; darwin*) # if libdl is installed we need to link against it { echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6; } if test "${ac_cv_lib_dl_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_dl_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6; } if test $ac_cv_lib_dl_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else lt_cv_dlopen="dyld" lt_cv_dlopen_libs= lt_cv_dlopen_self=yes fi ;; *) { echo "$as_me:$LINENO: checking for shl_load" >&5 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6; } if test "${ac_cv_func_shl_load+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Define shl_load to an innocuous variant, in case declares shl_load. For example, HP-UX 11i declares gettimeofday. */ #define shl_load innocuous_shl_load /* System header to define __stub macros and hopefully few prototypes, which can conflict with char shl_load (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef shl_load /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char shl_load (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_shl_load || defined __stub___shl_load choke me #endif int main () { return shl_load (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_func_shl_load=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_func_shl_load=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5 echo "${ECHO_T}$ac_cv_func_shl_load" >&6; } if test $ac_cv_func_shl_load = yes; then lt_cv_dlopen="shl_load" else { echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6; } if test "${ac_cv_lib_dld_shl_load+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char shl_load (); int main () { return shl_load (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_dld_shl_load=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dld_shl_load=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6; } if test $ac_cv_lib_dld_shl_load = yes; then lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" else { echo "$as_me:$LINENO: checking for dlopen" >&5 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6; } if test "${ac_cv_func_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Define dlopen to an innocuous variant, in case declares dlopen. For example, HP-UX 11i declares gettimeofday. */ #define dlopen innocuous_dlopen /* System header to define __stub macros and hopefully few prototypes, which can conflict with char dlopen (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef dlopen /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_dlopen || defined __stub___dlopen choke me #endif int main () { return dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_func_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_func_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5 echo "${ECHO_T}$ac_cv_func_dlopen" >&6; } if test $ac_cv_func_dlopen = yes; then lt_cv_dlopen="dlopen" else { echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6; } if test "${ac_cv_lib_dl_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_dl_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6; } if test $ac_cv_lib_dl_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else { echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6; } if test "${ac_cv_lib_svld_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lsvld $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_svld_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_svld_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6; } if test $ac_cv_lib_svld_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" else { echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6; } if test "${ac_cv_lib_dld_dld_link+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dld_link (); int main () { return dld_link (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_dld_dld_link=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dld_dld_link=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6; } if test $ac_cv_lib_dld_dld_link = yes; then lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" fi fi fi fi fi fi ;; esac if test "x$lt_cv_dlopen" != xno; then enable_dlopen=yes else enable_dlopen=no fi case $lt_cv_dlopen in dlopen) save_CPPFLAGS="$CPPFLAGS" test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" save_LDFLAGS="$LDFLAGS" wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS="$LIBS" LIBS="$lt_cv_dlopen_libs $LIBS" { echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6; } if test "${lt_cv_dlopen_self+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then : lt_cv_dlopen_self=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext < #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif #ifdef __cplusplus extern "C" void exit (int); #endif void fnord() { int i=42;} int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; /* dlclose (self); */ } else puts (dlerror ()); exit (status); } EOF if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; esac else : # compilation failed lt_cv_dlopen_self=no fi fi rm -fr conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5 echo "${ECHO_T}$lt_cv_dlopen_self" >&6; } if test "x$lt_cv_dlopen_self" = xyes; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" { echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6; } if test "${lt_cv_dlopen_self_static+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then : lt_cv_dlopen_self_static=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext < #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif #ifdef __cplusplus extern "C" void exit (int); #endif void fnord() { int i=42;} int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; /* dlclose (self); */ } else puts (dlerror ()); exit (status); } EOF if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; esac else : # compilation failed lt_cv_dlopen_self_static=no fi fi rm -fr conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5 echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6; } fi CPPFLAGS="$save_CPPFLAGS" LDFLAGS="$save_LDFLAGS" LIBS="$save_LIBS" ;; esac case $lt_cv_dlopen_self in yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; *) enable_dlopen_self=unknown ;; esac case $lt_cv_dlopen_self_static in yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; *) enable_dlopen_self_static=unknown ;; esac fi # Report which library types will actually be built { echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6; } { echo "$as_me:$LINENO: result: $can_build_shared" >&5 echo "${ECHO_T}$can_build_shared" >&6; } { echo "$as_me:$LINENO: checking whether to build shared libraries" >&5 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6; } test "$can_build_shared" = "no" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test "$enable_shared" = yes && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[4-9]*) if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then test "$enable_shared" = yes && enable_static=no fi ;; esac { echo "$as_me:$LINENO: result: $enable_shared" >&5 echo "${ECHO_T}$enable_shared" >&6; } { echo "$as_me:$LINENO: checking whether to build static libraries" >&5 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6; } # Make sure either enable_shared or enable_static is yes. test "$enable_shared" = yes || enable_static=yes { echo "$as_me:$LINENO: result: $enable_static" >&5 echo "${ECHO_T}$enable_static" >&6; } # The else clause should only fire when bootstrapping the # libtool distribution, otherwise you forgot to ship ltmain.sh # with your package, and you will get complaints that there are # no rules to generate ltmain.sh. if test -f "$ltmain"; then # See if we are running on zsh, and set the options which allow our commands through # without removal of \ escapes. if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi # Now quote all the things that may contain metacharacters while being # careful not to overquote the AC_SUBSTed values. We take copies of the # variables and quote the copies for generation of the libtool script. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ SED SHELL STRIP \ libname_spec library_names_spec soname_spec extract_expsyms_cmds \ old_striplib striplib file_magic_cmd finish_cmds finish_eval \ deplibs_check_method reload_flag reload_cmds need_locks \ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_c_name_address \ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ old_postinstall_cmds old_postuninstall_cmds \ compiler \ CC \ LD \ lt_prog_compiler_wl \ lt_prog_compiler_pic \ lt_prog_compiler_static \ lt_prog_compiler_no_builtin_flag \ export_dynamic_flag_spec \ thread_safe_flag_spec \ whole_archive_flag_spec \ enable_shared_with_static_runtimes \ old_archive_cmds \ old_archive_from_new_cmds \ predep_objects \ postdep_objects \ predeps \ postdeps \ compiler_lib_search_path \ compiler_lib_search_dirs \ archive_cmds \ archive_expsym_cmds \ postinstall_cmds \ postuninstall_cmds \ old_archive_from_expsyms_cmds \ allow_undefined_flag \ no_undefined_flag \ export_symbols_cmds \ hardcode_libdir_flag_spec \ hardcode_libdir_flag_spec_ld \ hardcode_libdir_separator \ hardcode_automatic \ module_cmds \ module_expsym_cmds \ lt_cv_prog_compiler_c_o \ fix_srcfile_path \ exclude_expsyms \ include_expsyms; do case $var in old_archive_cmds | \ old_archive_from_new_cmds | \ archive_cmds | \ archive_expsym_cmds | \ module_cmds | \ module_expsym_cmds | \ old_archive_from_expsyms_cmds | \ export_symbols_cmds | \ extract_expsyms_cmds | reload_cmds | finish_cmds | \ postinstall_cmds | postuninstall_cmds | \ old_postinstall_cmds | old_postuninstall_cmds | \ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) # Double-quote double-evaled strings. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" ;; *) eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; esac done case $lt_echo in *'\$0 --fallback-echo"') lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` ;; esac cfgfile="${ofile}T" trap "$rm \"$cfgfile\"; exit 1" 1 2 15 $rm -f "$cfgfile" { echo "$as_me:$LINENO: creating $ofile" >&5 echo "$as_me: creating $ofile" >&6;} cat <<__EOF__ >> "$cfgfile" #! $SHELL # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) # NOTE: Changes made to this file will be lost: look at ltmain.sh. # # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 # Free Software Foundation, Inc. # # This file is part of GNU Libtool: # Originally by Gordon Matzigkeit , 1996 # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # A sed program that does not truncate output. SED=$lt_SED # Sed that helps us avoid accidentally triggering echo(1) options like -n. Xsed="$SED -e 1s/^X//" # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # The names of the tagged configurations supported by this script. available_tags= # ### BEGIN LIBTOOL CONFIG # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # An echo program that does not interpret backslashes. echo=$lt_echo # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A C compiler. LTCC=$lt_LTCC # LTCC compiler flags. LTCFLAGS=$lt_LTCFLAGS # A language-specific compiler. CC=$lt_compiler # Is the compiler the GNU C compiler? with_gcc=$GCC # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD # Whether we need hard or soft links. LN_S=$lt_LN_S # A BSD-compatible nm program. NM=$lt_NM # A symbol stripping program STRIP=$lt_STRIP # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL" # Used on cygwin: object dumper. OBJDUMP="$OBJDUMP" # Used on cygwin: assembler. AS="$AS" # The name of the directory that contains temporary libtool files. objdir=$objdir # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl # Object file suffix (normally "o"). objext="$ac_objext" # Old archive suffix (normally "a"). libext="$libext" # Shared library suffix (normally ".so"). shrext_cmds='$shrext_cmds' # Executable file suffix (normally ""). exeext="$exeext" # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic pic_mode=$pic_mode # What is the maximum length of a command? max_cmd_len=$lt_cv_sys_max_cmd_len # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o # Must we lock files when doing compilation? need_locks=$lt_need_locks # Do we need the lib prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec # Library versioning type. version_type=$version_type # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Commands used to build and install an old-style archive. RANLIB=$lt_RANLIB old_archive_cmds=$lt_old_archive_cmds old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds # Commands used to build and install a shared archive. archive_cmds=$lt_archive_cmds archive_expsym_cmds=$lt_archive_expsym_cmds postinstall_cmds=$lt_postinstall_cmds postuninstall_cmds=$lt_postuninstall_cmds # Commands used to build a loadable module (assumed same as above if empty) module_cmds=$lt_module_cmds module_expsym_cmds=$lt_module_expsym_cmds # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_predep_objects # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs=$lt_compiler_lib_search_dirs # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method == file_magic. file_magic_cmd=$lt_file_magic_cmd # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # Same as above, but a single script fragment to be evaled but not shown. finish_eval=$lt_finish_eval # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm in a C name address pair global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # This is the shared library runtime path variable. runpath_var=$runpath_var # This is the shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist. hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec # If ld is used when linking, flag to hardcode \$libdir into # a binary during linking. This must work even if \$libdir does # not exist. hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=$hardcode_automatic # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="$variables_saved_for_relink" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs # Compile-time system search path for libraries sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Run-time system search path for libraries sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec # Fix the shell variable \$srcfile for the compiler. fix_srcfile_path=$lt_fix_srcfile_path # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms # Symbols that must always be exported. include_expsyms=$lt_include_expsyms # ### END LIBTOOL CONFIG __EOF__ case $host_os in aix3*) cat <<\EOF >> "$cfgfile" # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test "X${COLLECT_NAMES+set}" != Xset; then COLLECT_NAMES= export COLLECT_NAMES fi EOF ;; esac # We use sed instead of cat because bash on DJGPP gets confused if # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || \ (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" else # If there is no Makefile yet, we rely on a make rule to execute # `config.status --recheck' to rerun these tests and create the # libtool script then. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` if test -f "$ltmain_in"; then test -f Makefile && make "$ltmain" fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC="$lt_save_CC" # Check whether --with-tags was given. if test "${with_tags+set}" = set; then withval=$with_tags; tagnames="$withval" fi if test -f "$ltmain" && test -n "$tagnames"; then if test ! -f "${ofile}"; then { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not exist" >&5 echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;} fi if test -z "$LTCC"; then eval "`$SHELL ${ofile} --config | grep '^LTCC='`" if test -z "$LTCC"; then { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not look like a libtool script" >&5 echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;} else { echo "$as_me:$LINENO: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5 echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;} fi fi if test -z "$LTCFLAGS"; then eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`" fi # Extract list of available tagged configurations in $ofile. # Note that this assumes the entire list is on one line. available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for tagname in $tagnames; do IFS="$lt_save_ifs" # Check whether tagname contains only valid characters case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in "") ;; *) { { echo "$as_me:$LINENO: error: invalid tag name: $tagname" >&5 echo "$as_me: error: invalid tag name: $tagname" >&2;} { (exit 1); exit 1; }; } ;; esac if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null then { { echo "$as_me:$LINENO: error: tag name \"$tagname\" already exists" >&5 echo "$as_me: error: tag name \"$tagname\" already exists" >&2;} { (exit 1); exit 1; }; } fi # Update the list of available tags. if test -n "$tagname"; then echo appending configuration tag \"$tagname\" to $ofile case $tagname in CXX) if test -n "$CXX" && ( test "X$CXX" != "Xno" && ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || (test "X$CXX" != "Xg++"))) ; then ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu archive_cmds_need_lc_CXX=no allow_undefined_flag_CXX= always_export_symbols_CXX=no archive_expsym_cmds_CXX= export_dynamic_flag_spec_CXX= hardcode_direct_CXX=no hardcode_libdir_flag_spec_CXX= hardcode_libdir_flag_spec_ld_CXX= hardcode_libdir_separator_CXX= hardcode_minus_L_CXX=no hardcode_shlibpath_var_CXX=unsupported hardcode_automatic_CXX=no module_cmds_CXX= module_expsym_cmds_CXX= link_all_deplibs_CXX=unknown old_archive_cmds_CXX=$old_archive_cmds no_undefined_flag_CXX= whole_archive_flag_spec_CXX= enable_shared_with_static_runtimes_CXX=no # Dependencies to place before and after the object being linked: predep_objects_CXX= postdep_objects_CXX= predeps_CXX= postdeps_CXX= compiler_lib_search_path_CXX= compiler_lib_search_dirs_CXX= # Source file extension for C++ test sources. ac_ext=cpp # Object file extension for compiled C++ test sources. objext=o objext_CXX=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(int, char *[]) { return(0); }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $rm conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $rm -r conftest* # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_LD=$LD lt_save_GCC=$GCC GCC=$GXX lt_save_with_gnu_ld=$with_gnu_ld lt_save_path_LD=$lt_cv_path_LD if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx else $as_unset lt_cv_prog_gnu_ld fi if test -n "${lt_cv_path_LDCXX+set}"; then lt_cv_path_LD=$lt_cv_path_LDCXX else $as_unset lt_cv_path_LD fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} compiler=$CC compiler_CXX=$CC for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` # We don't want -fno-exception wen compiling C++ code, so set the # no_builtin_flag separately if test "$GXX" = yes; then lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' else lt_prog_compiler_no_builtin_flag_CXX= fi if test "$GXX" = yes; then # Set up default GNU C++ configuration # Check whether --with-gnu-ld was given. if test "${with_gnu_ld+set}" = set; then withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes else with_gnu_ld=no fi ac_prog=ld if test "$GCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. { echo "$as_me:$LINENO: checking for ld used by $CC" >&5 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6; } case $host in *-*-mingw*) # gcc leaves a trailing carriage return which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [\\/]* | ?:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the pathname of ld ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD="$ac_prog" ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test "$with_gnu_ld" = yes; then { echo "$as_me:$LINENO: checking for GNU ld" >&5 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6; } else { echo "$as_me:$LINENO: checking for non-GNU ld" >&5 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6; } fi if test "${lt_cv_path_LD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -z "$LD"; then lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD="$ac_dir/$ac_prog" # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &5 echo "${ECHO_T}$LD" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;} { (exit 1); exit 1; }; } { echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6; } if test "${lt_cv_prog_gnu_ld+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 &5 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld # Check if GNU C++ uses GNU ld as the underlying linker, since the # archiving commands below assume that GNU ld is being used. if test "$with_gnu_ld" = yes; then archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir' export_dynamic_flag_spec_CXX='${wl}--export-dynamic' # If archive_cmds runs LD, not CC, wlarc should be empty # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to # investigate it a little bit more. (MM) wlarc='${wl}' # ancient GNU ld didn't support --whole-archive et. al. if eval "`$CC -print-prog-name=ld` --help 2>&1" | \ grep 'no-whole-archive' > /dev/null; then whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else whole_archive_flag_spec_CXX= fi else with_gnu_ld=no wlarc= # A generic and very simple default shared library creation # command for GNU C++ for the case where it uses the native # linker, instead of GNU ld. If possible, this setting should # overridden to take advantage of the native linker features on # the platform it is being used on. archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' fi # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' else GXX=no with_gnu_ld=no wlarc= fi # PORTME: fill in a description of your system's C++ link characteristics { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; } ld_shlibs_CXX=yes case $host_os in aix3*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aix[4-9]*) if test "$host_cpu" = ia64; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag="" else aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # need to do runtime linking. case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do case $ld_flag in *-brtl*) aix_use_runtimelinking=yes break ;; esac done ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds_CXX='' hardcode_direct_CXX=yes hardcode_libdir_separator_CXX=':' link_all_deplibs_CXX=yes if test "$GXX" = yes; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`${CC} -print-prog-name=collect2` if test -f "$collect2name" && \ strings "$collect2name" | grep resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct_CXX=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L_CXX=yes hardcode_libdir_flag_spec_CXX='-L$libdir' hardcode_libdir_separator_CXX= fi ;; esac shared_flag='-shared' if test "$aix_use_runtimelinking" = yes; then shared_flag="$shared_flag "'${wl}-G' fi else # not using gcc if test "$host_cpu" = ia64; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test "$aix_use_runtimelinking" = yes; then shared_flag='${wl}-G' else shared_flag='${wl}-bM:SRE' fi fi fi # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols_CXX=yes if test "$aix_use_runtimelinking" = yes; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag_CXX='-berok' # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds_CXX="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" else if test "$host_cpu" = ia64; then hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib' allow_undefined_flag_CXX="-z nodefs" archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag_CXX=' ${wl}-bernotok' allow_undefined_flag_CXX=' ${wl}-berok' # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec_CXX='$convenience' archive_cmds_need_lc_CXX=yes # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; beos*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then allow_undefined_flag_CXX=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' else ld_shlibs_CXX=no fi ;; chorus*) case $cc_basename in *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; cygwin* | mingw* | pw32*) # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec_CXX='-L$libdir' allow_undefined_flag_CXX=unsupported always_export_symbols_CXX=no enable_shared_with_static_runtimes_CXX=yes if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file (1st line # is EXPORTS), use it as is; otherwise, prepend... archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs_CXX=no fi ;; darwin* | rhapsody*) archive_cmds_need_lc_CXX=no hardcode_direct_CXX=no hardcode_automatic_CXX=yes hardcode_shlibpath_var_CXX=unsupported whole_archive_flag_spec_CXX='' link_all_deplibs_CXX=yes allow_undefined_flag_CXX="$_lt_dar_allow_undefined" if test "$GXX" = yes ; then output_verbose_link_cmd='echo' archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" module_expsym_cmds_CXX="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" if test "$lt_cv_apple_cc_single_mod" != "yes"; then archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" fi else case $cc_basename in xlc*) output_verbose_link_cmd='echo' archive_cmds_CXX='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' module_cmds_CXX='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' module_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' ;; *) ld_shlibs_CXX=no ;; esac fi ;; dgux*) case $cc_basename in ec++*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; ghcx*) # Green Hills C++ Compiler # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; freebsd[12]*) # C++ shared libraries reported to be fairly broken before switch to ELF ld_shlibs_CXX=no ;; freebsd-elf*) archive_cmds_need_lc_CXX=no ;; freebsd* | dragonfly*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions ld_shlibs_CXX=yes ;; gnu*) ;; hpux9*) hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' hardcode_libdir_separator_CXX=: export_dynamic_flag_spec_CXX='${wl}-E' hardcode_direct_CXX=yes hardcode_minus_L_CXX=yes # Not in the search PATH, # but as the default # location of the library. case $cc_basename in CC*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aCC*) archive_cmds_CXX='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[-]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes; then archive_cmds_CXX='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; hpux10*|hpux11*) if test $with_gnu_ld = no; then hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' hardcode_libdir_separator_CXX=: case $host_cpu in hppa*64*|ia64*) ;; *) export_dynamic_flag_spec_CXX='${wl}-E' ;; esac fi case $host_cpu in hppa*64*|ia64*) hardcode_direct_CXX=no hardcode_shlibpath_var_CXX=no ;; *) hardcode_direct_CXX=yes hardcode_minus_L_CXX=yes # Not in the search PATH, # but as the default # location of the library. ;; esac case $cc_basename in CC*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aCC*) case $host_cpu in hppa*64*) archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes; then if test $with_gnu_ld = no; then case $host_cpu in hppa*64*) archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; interix[3-9]*) hardcode_direct_CXX=no hardcode_shlibpath_var_CXX=no hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' export_dynamic_flag_spec_CXX='${wl}-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in CC*) # SGI C++ archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' ;; *) if test "$GXX" = yes; then if test "$with_gnu_ld" = no; then archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib' fi fi link_all_deplibs_CXX=yes ;; esac hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_CXX=: ;; linux* | k*bsd*-gnu) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' hardcode_libdir_flag_spec_CXX='${wl}--rpath,$libdir' export_dynamic_flag_spec_CXX='${wl}--export-dynamic' # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; icpc*) # Intel C++ with_gnu_ld=yes # version 8.0 and above of icpc choke on multiply defined symbols # if we add $predep_objects and $postdep_objects, however 7.1 and # earlier do not add the objects themselves. case `$CC -V 2>&1` in *"Version 7."*) archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 8.0 or newer tmp_idyn= case $host_cpu in ia64*) tmp_idyn=' -i_dynamic';; esac archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' ;; esac archive_cmds_need_lc_CXX=no hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' export_dynamic_flag_spec_CXX='${wl}--export-dynamic' whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' ;; pgCC* | pgcpp*) # Portland Group C++ compiler archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir' export_dynamic_flag_spec_CXX='${wl}--export-dynamic' whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' ;; cxx*) # Compaq C++ archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec_CXX='-rpath $libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 no_undefined_flag_CXX=' -zdefs' archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' hardcode_libdir_flag_spec_CXX='-R$libdir' whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' # Not sure whether something based on # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 # would be better. output_verbose_link_cmd='echo' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' ;; esac ;; esac ;; lynxos*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; m88k*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; mvs*) case $cc_basename in cxx*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' wlarc= hardcode_libdir_flag_spec_CXX='-R$libdir' hardcode_direct_CXX=yes hardcode_shlibpath_var_CXX=no fi # Workaround some broken pre-1.5 toolchains output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' ;; openbsd2*) # C++ shared libraries are fairly broken ld_shlibs_CXX=no ;; openbsd*) if test -f /usr/libexec/ld.so; then hardcode_direct_CXX=yes hardcode_shlibpath_var_CXX=no archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' export_dynamic_flag_spec_CXX='${wl}-E' whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' fi output_verbose_link_cmd='echo' else ld_shlibs_CXX=no fi ;; osf3*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' hardcode_libdir_separator_CXX=: # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; cxx*) allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes && test "$with_gnu_ld" = no; then allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; osf4* | osf5*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' hardcode_libdir_separator_CXX=: # Archives containing C++ object files must be created using # the KAI C++ compiler. old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; cxx*) allow_undefined_flag_CXX=' -expect_unresolved \*' archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ echo "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~ $rm $lib.exp' hardcode_libdir_flag_spec_CXX='-rpath $libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes && test "$with_gnu_ld" = no; then allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; psos*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; lcc*) # Lucid # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; solaris*) case $cc_basename in CC*) # Sun C++ 4.2, 5.x and Centerline C++ archive_cmds_need_lc_CXX=yes no_undefined_flag_CXX=' -zdefs' archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' hardcode_libdir_flag_spec_CXX='-R$libdir' hardcode_shlibpath_var_CXX=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands `-z linker_flag'. # Supported since Solaris 2.6 (maybe 2.5.1?) whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' ;; esac link_all_deplibs_CXX=yes output_verbose_link_cmd='echo' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' ;; gcx*) # Green Hills C++ Compiler archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' # The C++ compiler must be used to create the archive. old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' ;; *) # GNU C++ compiler with Solaris linker if test "$GXX" = yes && test "$with_gnu_ld" = no; then no_undefined_flag_CXX=' ${wl}-z ${wl}defs' if $CC --version | grep -v '^2\.7' > /dev/null; then archive_cmds_CXX='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" else # g++ 2.7 appears to require `-G' NOT `-shared' on this # platform. archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" fi hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir' case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' ;; esac fi ;; esac ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag_CXX='${wl}-z,text' archive_cmds_need_lc_CXX=no hardcode_shlibpath_var_CXX=no runpath_var='LD_RUN_PATH' case $cc_basename in CC*) archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We can NOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. # For security reasons, it is highly recommended that you always # use absolute paths for naming shared libraries, and exclude the # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. # So that behaviour is only enabled if SCOABSPATH is set to a # non-empty value in the environment. Most likely only useful for # creating official distributions of packages. # This is a hack until libtool officially supports absolute path # names for shared libraries. no_undefined_flag_CXX='${wl}-z,text' allow_undefined_flag_CXX='${wl}-z,nodefs' archive_cmds_need_lc_CXX=no hardcode_shlibpath_var_CXX=no hardcode_libdir_flag_spec_CXX='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' hardcode_libdir_separator_CXX=':' link_all_deplibs_CXX=yes export_dynamic_flag_spec_CXX='${wl}-Bexport' runpath_var='LD_RUN_PATH' case $cc_basename in CC*) archive_cmds_CXX='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_CXX='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; vxworks*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac { echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5 echo "${ECHO_T}$ld_shlibs_CXX" >&6; } test "$ld_shlibs_CXX" = no && can_build_shared=no GCC_CXX="$GXX" LD_CXX="$LD" cat > conftest.$ac_ext <&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # Parse the compiler output and extract the necessary # objects, libraries and library flags. # Sentinel used to keep track of whether or not we are before # the conftest object file. pre_test_object_deps_done=no # The `*' in the case matches for architectures that use `case' in # $output_verbose_cmd can trigger glob expansion during the loop # eval without this substitution. output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"` for p in `eval $output_verbose_link_cmd`; do case $p in -L* | -R* | -l*) # Some compilers place space between "-{L,R}" and the path. # Remove the space. if test $p = "-L" \ || test $p = "-R"; then prev=$p continue else prev= fi if test "$pre_test_object_deps_done" = no; then case $p in -L* | -R*) # Internal compiler library paths should come after those # provided the user. The postdeps already come after the # user supplied libs so there is no need to process them. if test -z "$compiler_lib_search_path_CXX"; then compiler_lib_search_path_CXX="${prev}${p}" else compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}" fi ;; # The "-l" case would never come before the object being # linked, so don't bother handling this case. esac else if test -z "$postdeps_CXX"; then postdeps_CXX="${prev}${p}" else postdeps_CXX="${postdeps_CXX} ${prev}${p}" fi fi ;; *.$objext) # This assumes that the test object file only shows up # once in the compiler output. if test "$p" = "conftest.$objext"; then pre_test_object_deps_done=yes continue fi if test "$pre_test_object_deps_done" = no; then if test -z "$predep_objects_CXX"; then predep_objects_CXX="$p" else predep_objects_CXX="$predep_objects_CXX $p" fi else if test -z "$postdep_objects_CXX"; then postdep_objects_CXX="$p" else postdep_objects_CXX="$postdep_objects_CXX $p" fi fi ;; *) ;; # Ignore the rest. esac done # Clean up. rm -f a.out a.exe else echo "libtool.m4: error: problem compiling CXX test program" fi $rm -f confest.$objext compiler_lib_search_dirs_CXX= if test -n "$compiler_lib_search_path_CXX"; then compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` fi # PORTME: override above test on systems where it is broken case $host_os in interix[3-9]*) # Interix 3.5 installs completely hosed .la files for C++, so rather than # hack all around it, let's just trust "g++" to DTRT. predep_objects_CXX= postdep_objects_CXX= postdeps_CXX= ;; linux*) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 # # The more standards-conforming stlport4 library is # incompatible with the Cstd library. Avoid specifying # it if it's in CXXFLAGS. Ignore libCrun as # -library=stlport4 depends on it. case " $CXX $CXXFLAGS " in *" -library=stlport4 "*) solaris_use_stlport4=yes ;; esac if test "$solaris_use_stlport4" != yes; then postdeps_CXX='-library=Cstd -library=Crun' fi ;; esac ;; solaris*) case $cc_basename in CC*) # The more standards-conforming stlport4 library is # incompatible with the Cstd library. Avoid specifying # it if it's in CXXFLAGS. Ignore libCrun as # -library=stlport4 depends on it. case " $CXX $CXXFLAGS " in *" -library=stlport4 "*) solaris_use_stlport4=yes ;; esac # Adding this requires a known-good setup of shared libraries for # Sun compiler versions before 5.6, else PIC objects from an old # archive will be linked into the output, leading to subtle bugs. if test "$solaris_use_stlport4" != yes; then postdeps_CXX='-library=Cstd -library=Crun' fi ;; esac ;; esac case " $postdeps_CXX " in *" -lc "*) archive_cmds_need_lc_CXX=no ;; esac lt_prog_compiler_wl_CXX= lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX= { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; } # C++ specific cases for pic, static, wl, etc. if test "$GXX" = yes; then lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='-static' case $host_os in aix*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_CXX='-Bstatic' fi ;; amigaos*) # FIXME: we need at least 68020 code to build shared libraries, but # adding the `-m68020' flag to GCC prevents building anything better, # like `-m68040'. lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | os2* | pw32*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic_CXX='-DDLL_EXPORT' ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic_CXX='-fno-common' ;; *djgpp*) # DJGPP does not support shared libraries at all lt_prog_compiler_pic_CXX= ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic_CXX=-Kconform_pic fi ;; hpux*) # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) ;; *) lt_prog_compiler_pic_CXX='-fPIC' ;; esac ;; *) lt_prog_compiler_pic_CXX='-fPIC' ;; esac else case $host_os in aix[4-9]*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_CXX='-Bstatic' else lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' fi ;; chorus*) case $cc_basename in cxch68*) # Green Hills C++ Compiler # _LT_AC_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" ;; esac ;; darwin*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files case $cc_basename in xlc*) lt_prog_compiler_pic_CXX='-qnocommon' lt_prog_compiler_wl_CXX='-Wl,' ;; esac ;; dgux*) case $cc_basename in ec++*) lt_prog_compiler_pic_CXX='-KPIC' ;; ghcx*) # Green Hills C++ Compiler lt_prog_compiler_pic_CXX='-pic' ;; *) ;; esac ;; freebsd* | dragonfly*) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' if test "$host_cpu" != ia64; then lt_prog_compiler_pic_CXX='+Z' fi ;; aCC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_CXX='+Z' ;; esac ;; *) ;; esac ;; interix*) # This is c89, which is MS Visual C++ (no shared libs) # Anyone wants to do a port? ;; irix5* | irix6* | nonstopux*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='-non_shared' # CC pic flag -KPIC is the default. ;; *) ;; esac ;; linux* | k*bsd*-gnu) case $cc_basename in KCC*) # KAI C++ Compiler lt_prog_compiler_wl_CXX='--backend -Wl,' lt_prog_compiler_pic_CXX='-fPIC' ;; icpc* | ecpc*) # Intel C++ lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-static' ;; pgCC* | pgcpp*) # Portland Group C++ compiler. lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-fpic' lt_prog_compiler_static_CXX='-Bstatic' ;; cxx*) # Compaq C++ # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX='-non_shared' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' lt_prog_compiler_wl_CXX='-Qoption ld ' ;; esac ;; esac ;; lynxos*) ;; m88k*) ;; mvs*) case $cc_basename in cxx*) lt_prog_compiler_pic_CXX='-W c,exportall' ;; *) ;; esac ;; netbsd* | netbsdelf*-gnu) ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) lt_prog_compiler_wl_CXX='--backend -Wl,' ;; RCC*) # Rational C++ 2.4.1 lt_prog_compiler_pic_CXX='-pic' ;; cxx*) # Digital/Compaq C++ lt_prog_compiler_wl_CXX='-Wl,' # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX='-non_shared' ;; *) ;; esac ;; psos*) ;; solaris*) case $cc_basename in CC*) # Sun C++ 4.2, 5.x and Centerline C++ lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' lt_prog_compiler_wl_CXX='-Qoption ld ' ;; gcx*) # Green Hills C++ Compiler lt_prog_compiler_pic_CXX='-PIC' ;; *) ;; esac ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x lt_prog_compiler_pic_CXX='-pic' lt_prog_compiler_static_CXX='-Bstatic' ;; lcc*) # Lucid lt_prog_compiler_pic_CXX='-pic' ;; *) ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 lt_prog_compiler_pic_CXX='-KPIC' ;; *) ;; esac ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' ;; esac ;; vxworks*) ;; *) lt_prog_compiler_can_build_shared_CXX=no ;; esac fi { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_CXX" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_CXX" >&6; } # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic_CXX"; then { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_pic_works_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_pic_works_CXX=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:__oline__: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works_CXX=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_pic_works_CXX" >&6; } if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then case $lt_prog_compiler_pic_CXX in "" | " "*) ;; *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; esac else lt_prog_compiler_pic_CXX= lt_prog_compiler_can_build_shared_CXX=no fi fi case $host_os in # For platforms which do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic_CXX= ;; *) lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" ;; esac # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_static_works_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_static_works_CXX=no save_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works_CXX=yes fi else lt_cv_prog_compiler_static_works_CXX=yes fi fi $rm -r conftest* LDFLAGS="$save_LDFLAGS" fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works_CXX" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_static_works_CXX" >&6; } if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then : else lt_prog_compiler_static_CXX= fi { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_c_o_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o_CXX=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:__oline__: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o_CXX=yes fi fi chmod u+w . 2>&5 $rm conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files $rm out/* && rmdir out cd .. rmdir conftest $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_CXX" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_CXX" >&6; } hard_links="nottested" if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then # do not overwrite the value of need_locks provided by the user { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; } hard_links=yes $rm conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6; } if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; } export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' case $host_os in aix[4-9]*) # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to AIX nm, but means don't demangle with GNU nm if $NM -V 2>&1 | grep 'GNU' > /dev/null; then export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' else export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' fi ;; pw32*) export_symbols_cmds_CXX="$ltdll_cmds" ;; cygwin* | mingw*) export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;/^.*[ ]__nm__/s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' ;; linux* | k*bsd*-gnu) link_all_deplibs_CXX=no ;; *) export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; esac exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' { echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5 echo "${ECHO_T}$ld_shlibs_CXX" >&6; } test "$ld_shlibs_CXX" = no && can_build_shared=no # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc_CXX" in x|xyes) # Assume -lc should be added archive_cmds_need_lc_CXX=yes if test "$enable_shared" = yes && test "$GCC" = yes; then case $archive_cmds_CXX in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; } $rm conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl_CXX pic_flag=$lt_prog_compiler_pic_CXX compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag_CXX allow_undefined_flag_CXX= if { (eval echo "$as_me:$LINENO: \"$archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 (eval $archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } then archive_cmds_need_lc_CXX=no else archive_cmds_need_lc_CXX=yes fi allow_undefined_flag_CXX=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $rm conftest* { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_CXX" >&5 echo "${ECHO_T}$archive_cmds_need_lc_CXX" >&6; } ;; esac fi ;; esac { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; } library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=".so" postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='${libname}${release}${shared_ext}$major' ;; aix[4-9]*) version_type=linux need_lib_prefix=no need_version=no hardcode_into_libs=yes if test "$host_cpu" = ia64; then # AIX 5 supports IA64 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line `#! .'. This would cause the generated library to # depend on `.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then : else can_build_shared=no fi ;; esac # AIX (on Power*) has no versioning support, so currently we can not hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. if test "$aix_use_runtimelinking" = yes; then # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' else # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='${libname}${release}.a $libname.a' soname_spec='${libname}${release}${shared_ext}$major' fi shlibpath_var=LIBPATH fi ;; amigaos*) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; beos*) library_names_spec='${libname}${shared_ext}' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32*) version_type=windows shrext_cmds=".dll" need_version=no need_lib_prefix=no case $GCC,$host_os in yes,cygwin* | yes,mingw* | yes,pw32*) library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \${file}`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" ;; mingw*) # MinGW DLLs use traditional 'lib' prefix soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH printed by # mingw gcc, but we are running on Cygwin. Gcc prints its search # path with ; separators, and with drive letters. We can handle the # drive letters (cygwin fileutils understands them), so leave them, # especially as we might pass files found there to a mingw objdump, # which wouldn't understand a cygwinified path. Ahh. sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' ;; esac ;; *) library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' ;; esac dynamic_linker='Win32 ld.exe' # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' soname_spec='${libname}${release}${major}$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd1*) dynamic_linker=no ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[123]*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; gnu*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' if test "X$HPUX_IA64_MODE" = X32; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" fi sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555. postinstall_cmds='chmod 555 $lib' ;; interix[3-9]*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test "$lt_cv_prog_gnu_ld" = yes; then version_type=linux else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. linux* | k*bsd*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Append ld.so.conf contents to the search path if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsdelf*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; nto-qnx*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; openbsd*) version_type=sunos sys_lib_dlsearch_path_spec="/usr/lib" need_lib_prefix=no # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. case $host_os in openbsd3.3 | openbsd3.3.*) need_version=yes ;; *) need_version=no ;; esac library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then case $host_os in openbsd2.[89] | openbsd2.[89].*) shlibpath_overrides_runpath=no ;; *) shlibpath_overrides_runpath=yes ;; esac else shlibpath_overrides_runpath=yes fi ;; os2*) libname_spec='$name' shrext_cmds=".dll" need_lib_prefix=no library_names_spec='$libname${shared_ext} $libname.a' dynamic_linker='OS/2 ld.exe' shlibpath_var=LIBPATH ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test "$with_gnu_ld" = yes; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no export_dynamic_flag_spec='${wl}-Blargedynsym' runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec ;then version_type=linux library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' soname_spec='$libname${shared_ext}.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=freebsd-elf need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes if test "$with_gnu_ld" = yes; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' shlibpath_overrides_runpath=no else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' shlibpath_overrides_runpath=yes case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; uts4*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6; } test "$dynamic_linker" = no && can_build_shared=no if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" fi sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" fi sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test "$GCC" = yes; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; } hardcode_action_CXX= if test -n "$hardcode_libdir_flag_spec_CXX" || \ test -n "$runpath_var_CXX" || \ test "X$hardcode_automatic_CXX" = "Xyes" ; then # We can hardcode non-existant directories. if test "$hardcode_direct_CXX" != no && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, CXX)" != no && test "$hardcode_minus_L_CXX" != no; then # Linking always hardcodes the temporary library directory. hardcode_action_CXX=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action_CXX=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action_CXX=unsupported fi { echo "$as_me:$LINENO: result: $hardcode_action_CXX" >&5 echo "${ECHO_T}$hardcode_action_CXX" >&6; } if test "$hardcode_action_CXX" = relink; then # Fast installation is not supported enable_fast_install=no elif test "$shlibpath_overrides_runpath" = yes || test "$enable_shared" = no; then # Fast installation is not necessary enable_fast_install=needless fi # The else clause should only fire when bootstrapping the # libtool distribution, otherwise you forgot to ship ltmain.sh # with your package, and you will get complaints that there are # no rules to generate ltmain.sh. if test -f "$ltmain"; then # See if we are running on zsh, and set the options which allow our commands through # without removal of \ escapes. if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi # Now quote all the things that may contain metacharacters while being # careful not to overquote the AC_SUBSTed values. We take copies of the # variables and quote the copies for generation of the libtool script. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ SED SHELL STRIP \ libname_spec library_names_spec soname_spec extract_expsyms_cmds \ old_striplib striplib file_magic_cmd finish_cmds finish_eval \ deplibs_check_method reload_flag reload_cmds need_locks \ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_c_name_address \ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ old_postinstall_cmds old_postuninstall_cmds \ compiler_CXX \ CC_CXX \ LD_CXX \ lt_prog_compiler_wl_CXX \ lt_prog_compiler_pic_CXX \ lt_prog_compiler_static_CXX \ lt_prog_compiler_no_builtin_flag_CXX \ export_dynamic_flag_spec_CXX \ thread_safe_flag_spec_CXX \ whole_archive_flag_spec_CXX \ enable_shared_with_static_runtimes_CXX \ old_archive_cmds_CXX \ old_archive_from_new_cmds_CXX \ predep_objects_CXX \ postdep_objects_CXX \ predeps_CXX \ postdeps_CXX \ compiler_lib_search_path_CXX \ compiler_lib_search_dirs_CXX \ archive_cmds_CXX \ archive_expsym_cmds_CXX \ postinstall_cmds_CXX \ postuninstall_cmds_CXX \ old_archive_from_expsyms_cmds_CXX \ allow_undefined_flag_CXX \ no_undefined_flag_CXX \ export_symbols_cmds_CXX \ hardcode_libdir_flag_spec_CXX \ hardcode_libdir_flag_spec_ld_CXX \ hardcode_libdir_separator_CXX \ hardcode_automatic_CXX \ module_cmds_CXX \ module_expsym_cmds_CXX \ lt_cv_prog_compiler_c_o_CXX \ fix_srcfile_path_CXX \ exclude_expsyms_CXX \ include_expsyms_CXX; do case $var in old_archive_cmds_CXX | \ old_archive_from_new_cmds_CXX | \ archive_cmds_CXX | \ archive_expsym_cmds_CXX | \ module_cmds_CXX | \ module_expsym_cmds_CXX | \ old_archive_from_expsyms_cmds_CXX | \ export_symbols_cmds_CXX | \ extract_expsyms_cmds | reload_cmds | finish_cmds | \ postinstall_cmds | postuninstall_cmds | \ old_postinstall_cmds | old_postuninstall_cmds | \ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) # Double-quote double-evaled strings. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" ;; *) eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; esac done case $lt_echo in *'\$0 --fallback-echo"') lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` ;; esac cfgfile="$ofile" cat <<__EOF__ >> "$cfgfile" # ### BEGIN LIBTOOL TAG CONFIG: $tagname # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc_CXX # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # An echo program that does not interpret backslashes. echo=$lt_echo # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A C compiler. LTCC=$lt_LTCC # LTCC compiler flags. LTCFLAGS=$lt_LTCFLAGS # A language-specific compiler. CC=$lt_compiler_CXX # Is the compiler the GNU C compiler? with_gcc=$GCC_CXX # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD_CXX # Whether we need hard or soft links. LN_S=$lt_LN_S # A BSD-compatible nm program. NM=$lt_NM # A symbol stripping program STRIP=$lt_STRIP # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL" # Used on cygwin: object dumper. OBJDUMP="$OBJDUMP" # Used on cygwin: assembler. AS="$AS" # The name of the directory that contains temporary libtool files. objdir=$objdir # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl_CXX # Object file suffix (normally "o"). objext="$ac_objext" # Old archive suffix (normally "a"). libext="$libext" # Shared library suffix (normally ".so"). shrext_cmds='$shrext_cmds' # Executable file suffix (normally ""). exeext="$exeext" # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic_CXX pic_mode=$pic_mode # What is the maximum length of a command? max_cmd_len=$lt_cv_sys_max_cmd_len # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX # Must we lock files when doing compilation? need_locks=$lt_need_locks # Do we need the lib prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static_CXX # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec_CXX # Library versioning type. version_type=$version_type # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Commands used to build and install an old-style archive. RANLIB=$lt_RANLIB old_archive_cmds=$lt_old_archive_cmds_CXX old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX # Commands used to build and install a shared archive. archive_cmds=$lt_archive_cmds_CXX archive_expsym_cmds=$lt_archive_expsym_cmds_CXX postinstall_cmds=$lt_postinstall_cmds postuninstall_cmds=$lt_postuninstall_cmds # Commands used to build a loadable module (assumed same as above if empty) module_cmds=$lt_module_cmds_CXX module_expsym_cmds=$lt_module_expsym_cmds_CXX # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_predep_objects_CXX # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects_CXX # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps_CXX # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_CXX # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_CXX # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method == file_magic. file_magic_cmd=$lt_file_magic_cmd # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag_CXX # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_CXX # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # Same as above, but a single script fragment to be evaled but not shown. finish_eval=$lt_finish_eval # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm in a C name address pair global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # This is the shared library runtime path variable. runpath_var=$runpath_var # This is the shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action_CXX # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist. hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX # If ld is used when linking, flag to hardcode \$libdir into # a binary during linking. This must work even if \$libdir does # not exist. hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct_CXX # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L_CXX # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=$hardcode_automatic_CXX # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="$variables_saved_for_relink" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs_CXX # Compile-time system search path for libraries sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Run-time system search path for libraries sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec # Fix the shell variable \$srcfile for the compiler. fix_srcfile_path=$lt_fix_srcfile_path # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols_CXX # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds_CXX # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms_CXX # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_CXX # ### END LIBTOOL TAG CONFIG: $tagname __EOF__ else # If there is no Makefile yet, we rely on a make rule to execute # `config.status --recheck' to rerun these tests and create the # libtool script then. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` if test -f "$ltmain_in"; then test -f Makefile && make "$ltmain" fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC=$lt_save_CC LDCXX=$LD LD=$lt_save_LD GCC=$lt_save_GCC with_gnu_ldcxx=$with_gnu_ld with_gnu_ld=$lt_save_with_gnu_ld lt_cv_path_LDCXX=$lt_cv_path_LD lt_cv_path_LD=$lt_save_path_LD lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld else tagname="" fi ;; F77) if test -n "$F77" && test "X$F77" != "Xno"; then ac_ext=f ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&5' ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_f77_compiler_gnu archive_cmds_need_lc_F77=no allow_undefined_flag_F77= always_export_symbols_F77=no archive_expsym_cmds_F77= export_dynamic_flag_spec_F77= hardcode_direct_F77=no hardcode_libdir_flag_spec_F77= hardcode_libdir_flag_spec_ld_F77= hardcode_libdir_separator_F77= hardcode_minus_L_F77=no hardcode_automatic_F77=no module_cmds_F77= module_expsym_cmds_F77= link_all_deplibs_F77=unknown old_archive_cmds_F77=$old_archive_cmds no_undefined_flag_F77= whole_archive_flag_spec_F77= enable_shared_with_static_runtimes_F77=no # Source file extension for f77 test sources. ac_ext=f # Object file extension for compiled f77 test sources. objext=o objext_F77=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t return end " # Code to be used in simple link tests lt_simple_link_test_code="\ program t end " # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $rm conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $rm -r conftest* # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${F77-"f77"} compiler=$CC compiler_F77=$CC for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` { echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6; } { echo "$as_me:$LINENO: result: $can_build_shared" >&5 echo "${ECHO_T}$can_build_shared" >&6; } { echo "$as_me:$LINENO: checking whether to build shared libraries" >&5 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6; } test "$can_build_shared" = "no" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test "$enable_shared" = yes && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[4-9]*) if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then test "$enable_shared" = yes && enable_static=no fi ;; esac { echo "$as_me:$LINENO: result: $enable_shared" >&5 echo "${ECHO_T}$enable_shared" >&6; } { echo "$as_me:$LINENO: checking whether to build static libraries" >&5 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6; } # Make sure either enable_shared or enable_static is yes. test "$enable_shared" = yes || enable_static=yes { echo "$as_me:$LINENO: result: $enable_static" >&5 echo "${ECHO_T}$enable_static" >&6; } GCC_F77="$G77" LD_F77="$LD" lt_prog_compiler_wl_F77= lt_prog_compiler_pic_F77= lt_prog_compiler_static_F77= { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; } if test "$GCC" = yes; then lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_static_F77='-static' case $host_os in aix*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_F77='-Bstatic' fi ;; amigaos*) # FIXME: we need at least 68020 code to build shared libraries, but # adding the `-m68020' flag to GCC prevents building anything better, # like `-m68040'. lt_prog_compiler_pic_F77='-m68020 -resident32 -malways-restore-a4' ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic_F77='-DDLL_EXPORT' ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic_F77='-fno-common' ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. lt_prog_compiler_can_build_shared_F77=no enable_shared=no ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic_F77=-Kconform_pic fi ;; hpux*) # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_F77='-fPIC' ;; esac ;; *) lt_prog_compiler_pic_F77='-fPIC' ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) lt_prog_compiler_wl_F77='-Wl,' if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_F77='-Bstatic' else lt_prog_compiler_static_F77='-bnso -bI:/lib/syscalls.exp' fi ;; darwin*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files case $cc_basename in xlc*) lt_prog_compiler_pic_F77='-qnocommon' lt_prog_compiler_wl_F77='-Wl,' ;; esac ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). lt_prog_compiler_pic_F77='-DDLL_EXPORT' ;; hpux9* | hpux10* | hpux11*) lt_prog_compiler_wl_F77='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_F77='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? lt_prog_compiler_static_F77='${wl}-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) lt_prog_compiler_wl_F77='-Wl,' # PIC (with -KPIC) is the default. lt_prog_compiler_static_F77='-non_shared' ;; newsos6) lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' ;; linux* | k*bsd*-gnu) case $cc_basename in icc* | ecc*) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-static' ;; pgcc* | pgf77* | pgf90* | pgf95*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_pic_F77='-fpic' lt_prog_compiler_static_F77='-Bstatic' ;; ccc*) lt_prog_compiler_wl_F77='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static_F77='-non_shared' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' lt_prog_compiler_wl_F77='-Wl,' ;; *Sun\ F*) # Sun Fortran 8.3 passes all unrecognized flags to the linker lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' lt_prog_compiler_wl_F77='' ;; esac ;; esac ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl_F77='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static_F77='-non_shared' ;; rdos*) lt_prog_compiler_static_F77='-non_shared' ;; solaris*) lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' case $cc_basename in f77* | f90* | f95*) lt_prog_compiler_wl_F77='-Qoption ld ';; *) lt_prog_compiler_wl_F77='-Wl,';; esac ;; sunos4*) lt_prog_compiler_wl_F77='-Qoption ld ' lt_prog_compiler_pic_F77='-PIC' lt_prog_compiler_static_F77='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec ;then lt_prog_compiler_pic_F77='-Kconform_pic' lt_prog_compiler_static_F77='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' ;; unicos*) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_can_build_shared_F77=no ;; uts4*) lt_prog_compiler_pic_F77='-pic' lt_prog_compiler_static_F77='-Bstatic' ;; *) lt_prog_compiler_can_build_shared_F77=no ;; esac fi { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_F77" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_F77" >&6; } # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic_F77"; then { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_pic_works_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_pic_works_F77=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic_F77" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:__oline__: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works_F77=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works_F77" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_pic_works_F77" >&6; } if test x"$lt_cv_prog_compiler_pic_works_F77" = xyes; then case $lt_prog_compiler_pic_F77 in "" | " "*) ;; *) lt_prog_compiler_pic_F77=" $lt_prog_compiler_pic_F77" ;; esac else lt_prog_compiler_pic_F77= lt_prog_compiler_can_build_shared_F77=no fi fi case $host_os in # For platforms which do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic_F77= ;; *) lt_prog_compiler_pic_F77="$lt_prog_compiler_pic_F77" ;; esac # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl_F77 eval lt_tmp_static_flag=\"$lt_prog_compiler_static_F77\" { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_static_works_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_static_works_F77=no save_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works_F77=yes fi else lt_cv_prog_compiler_static_works_F77=yes fi fi $rm -r conftest* LDFLAGS="$save_LDFLAGS" fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works_F77" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_static_works_F77" >&6; } if test x"$lt_cv_prog_compiler_static_works_F77" = xyes; then : else lt_prog_compiler_static_F77= fi { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_c_o_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o_F77=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:__oline__: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o_F77=yes fi fi chmod u+w . 2>&5 $rm conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files $rm out/* && rmdir out cd .. rmdir conftest $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_F77" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_F77" >&6; } hard_links="nottested" if test "$lt_cv_prog_compiler_c_o_F77" = no && test "$need_locks" != no; then # do not overwrite the value of need_locks provided by the user { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; } hard_links=yes $rm conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6; } if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; } runpath_var= allow_undefined_flag_F77= enable_shared_with_static_runtimes_F77=no archive_cmds_F77= archive_expsym_cmds_F77= old_archive_From_new_cmds_F77= old_archive_from_expsyms_cmds_F77= export_dynamic_flag_spec_F77= whole_archive_flag_spec_F77= thread_safe_flag_spec_F77= hardcode_libdir_flag_spec_F77= hardcode_libdir_flag_spec_ld_F77= hardcode_libdir_separator_F77= hardcode_direct_F77=no hardcode_minus_L_F77=no hardcode_shlibpath_var_F77=unsupported link_all_deplibs_F77=unknown hardcode_automatic_F77=no module_cmds_F77= module_expsym_cmds_F77= always_export_symbols_F77=no export_symbols_cmds_F77='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list include_expsyms_F77= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ` (' and `)$', so one must not match beginning or # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', # as well as any symbol that contains `d'. exclude_expsyms_F77='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. extract_expsyms_cmds= # Just being paranoid about ensuring that cc_basename is set. for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` case $host_os in cygwin* | mingw* | pw32*) # FIXME: the MSVC++ port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++. if test "$GCC" != yes; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++) with_gnu_ld=yes ;; openbsd*) with_gnu_ld=no ;; esac ld_shlibs_F77=yes if test "$with_gnu_ld" = yes; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='${wl}' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec_F77='${wl}--rpath ${wl}$libdir' export_dynamic_flag_spec_F77='${wl}--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then whole_archive_flag_spec_F77="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else whole_archive_flag_spec_F77= fi supports_anon_versioning=no case `$LD -v 2>/dev/null` in *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[3-9]*) # On AIX/PPC, the GNU linker is very broken if test "$host_cpu" != ia64; then ld_shlibs_F77=no cat <&2 *** Warning: the GNU linker, at least up to release 2.9.1, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to modify your PATH *** so that a non-GNU linker is found, and then restart. EOF fi ;; amigaos*) archive_cmds_F77='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_minus_L_F77=yes # Samuel A. Falvo II reports # that the semantics of dynamic libraries on AmigaOS, at least up # to version 4, is to share data among multiple programs linked # with the same dynamic library. Since this doesn't match the # behavior of shared libraries on other platforms, we can't use # them. ld_shlibs_F77=no ;; beos*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then allow_undefined_flag_F77=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds_F77='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' else ld_shlibs_F77=no fi ;; cygwin* | mingw* | pw32*) # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, F77) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec_F77='-L$libdir' allow_undefined_flag_F77=unsupported always_export_symbols_F77=no enable_shared_with_static_runtimes_F77=yes export_symbols_cmds_F77='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file (1st line # is EXPORTS), use it as is; otherwise, prepend... archive_expsym_cmds_F77='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs_F77=no fi ;; interix[3-9]*) hardcode_direct_F77=no hardcode_shlibpath_var_F77=no hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir' export_dynamic_flag_spec_F77='${wl}-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds_F77='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | k*bsd*-gnu) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then tmp_addflag= case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; esac case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 whole_archive_flag_spec_F77='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; *) tmp_sharedflag='-shared' ;; esac archive_cmds_F77='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' if test $supports_anon_versioning = yes; then archive_expsym_cmds_F77='$echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ $echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' fi link_all_deplibs_F77=no else ld_shlibs_F77=no fi ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds_F77='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then ld_shlibs_F77=no cat <&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. EOF elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs_F77=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) ld_shlibs_F77=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then hardcode_libdir_flag_spec_F77='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' else ld_shlibs_F77=no fi ;; esac ;; sunos4*) archive_cmds_F77='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct_F77=yes hardcode_shlibpath_var_F77=no ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs_F77=no fi ;; esac if test "$ld_shlibs_F77" = no; then runpath_var= hardcode_libdir_flag_spec_F77= export_dynamic_flag_spec_F77= whole_archive_flag_spec_F77= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) allow_undefined_flag_F77=unsupported always_export_symbols_F77=yes archive_expsym_cmds_F77='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. hardcode_minus_L_F77=yes if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct_F77=unsupported fi ;; aix[4-9]*) if test "$host_cpu" = ia64; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag="" else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to AIX nm, but means don't demangle with GNU nm if $NM -V 2>&1 | grep 'GNU' > /dev/null; then export_symbols_cmds_F77='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' else export_symbols_cmds_F77='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # need to do runtime linking. case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then aix_use_runtimelinking=yes break fi done ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds_F77='' hardcode_direct_F77=yes hardcode_libdir_separator_F77=':' link_all_deplibs_F77=yes if test "$GCC" = yes; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`${CC} -print-prog-name=collect2` if test -f "$collect2name" && \ strings "$collect2name" | grep resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct_F77=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L_F77=yes hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_libdir_separator_F77= fi ;; esac shared_flag='-shared' if test "$aix_use_runtimelinking" = yes; then shared_flag="$shared_flag "'${wl}-G' fi else # not using gcc if test "$host_cpu" = ia64; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test "$aix_use_runtimelinking" = yes; then shared_flag='${wl}-G' else shared_flag='${wl}-bM:SRE' fi fi fi # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols_F77=yes if test "$aix_use_runtimelinking" = yes; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag_F77='-berok' # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF program main end _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_f77_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_F77='${wl}-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds_F77="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" else if test "$host_cpu" = ia64; then hardcode_libdir_flag_spec_F77='${wl}-R $libdir:/usr/lib:/lib' allow_undefined_flag_F77="-z nodefs" archive_expsym_cmds_F77="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF program main end _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_f77_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_F77='${wl}-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag_F77=' ${wl}-bernotok' allow_undefined_flag_F77=' ${wl}-berok' # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec_F77='$convenience' archive_cmds_need_lc_F77=yes # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds_F77="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; amigaos*) archive_cmds_F77='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_minus_L_F77=yes # see comment about different semantics on the GNU ld section ld_shlibs_F77=no ;; bsdi[45]*) export_dynamic_flag_spec_F77=-rdynamic ;; cygwin* | mingw* | pw32*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. hardcode_libdir_flag_spec_F77=' ' allow_undefined_flag_F77=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=".dll" # FIXME: Setting linknames here is a bad hack. archive_cmds_F77='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. old_archive_From_new_cmds_F77='true' # FIXME: Should let the user specify the lib program. old_archive_cmds_F77='lib -OUT:$oldlib$oldobjs$old_deplibs' fix_srcfile_path_F77='`cygpath -w "$srcfile"`' enable_shared_with_static_runtimes_F77=yes ;; darwin* | rhapsody*) case $host_os in rhapsody* | darwin1.[012]) allow_undefined_flag_F77='${wl}-undefined ${wl}suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then allow_undefined_flag_F77='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[012]) allow_undefined_flag_F77='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 10.*) allow_undefined_flag_F77='${wl}-undefined ${wl}dynamic_lookup' ;; esac fi ;; esac archive_cmds_need_lc_F77=no hardcode_direct_F77=no hardcode_automatic_F77=yes hardcode_shlibpath_var_F77=unsupported whole_archive_flag_spec_F77='' link_all_deplibs_F77=yes if test "$GCC" = yes ; then output_verbose_link_cmd='echo' archive_cmds_F77="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" module_cmds_F77="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" archive_expsym_cmds_F77="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" module_expsym_cmds_F77="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" else case $cc_basename in xlc*) output_verbose_link_cmd='echo' archive_cmds_F77='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' module_cmds_F77='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds archive_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' module_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' ;; *) ld_shlibs_F77=no ;; esac fi ;; dgux*) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_shlibpath_var_F77=no ;; freebsd1*) ld_shlibs_F77=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' hardcode_libdir_flag_spec_F77='-R$libdir' hardcode_direct_F77=yes hardcode_shlibpath_var_F77=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2*) archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_F77=yes hardcode_minus_L_F77=yes hardcode_shlibpath_var_F77=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly*) archive_cmds_F77='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec_F77='-R$libdir' hardcode_direct_F77=yes hardcode_shlibpath_var_F77=no ;; hpux9*) if test "$GCC" = yes; then archive_cmds_F77='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' else archive_cmds_F77='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' fi hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir' hardcode_libdir_separator_F77=: hardcode_direct_F77=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_F77=yes export_dynamic_flag_spec_F77='${wl}-E' ;; hpux10*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then archive_cmds_F77='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_F77='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir' hardcode_libdir_separator_F77=: hardcode_direct_F77=yes export_dynamic_flag_spec_F77='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_F77=yes fi ;; hpux11*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then case $host_cpu in hppa*64*) archive_cmds_F77='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds_F77='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_F77='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir' hardcode_libdir_separator_F77=: case $host_cpu in hppa*64*|ia64*) hardcode_libdir_flag_spec_ld_F77='+b $libdir' hardcode_direct_F77=no hardcode_shlibpath_var_F77=no ;; *) hardcode_direct_F77=yes export_dynamic_flag_spec_F77='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_F77=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test "$GCC" = yes; then archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else archive_cmds_F77='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_ld_F77='-rpath $libdir' fi hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_F77=: link_all_deplibs_F77=yes ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else archive_cmds_F77='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi hardcode_libdir_flag_spec_F77='-R$libdir' hardcode_direct_F77=yes hardcode_shlibpath_var_F77=no ;; newsos6) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_F77=yes hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_F77=: hardcode_shlibpath_var_F77=no ;; openbsd*) if test -f /usr/libexec/ld.so; then hardcode_direct_F77=yes hardcode_shlibpath_var_F77=no if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir' export_dynamic_flag_spec_F77='${wl}-E' else case $host_os in openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_F77='-R$libdir' ;; *) archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir' ;; esac fi else ld_shlibs_F77=no fi ;; os2*) hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_minus_L_F77=yes allow_undefined_flag_F77=unsupported archive_cmds_F77='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' old_archive_From_new_cmds_F77='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' ;; osf3*) if test "$GCC" = yes; then allow_undefined_flag_F77=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else allow_undefined_flag_F77=' -expect_unresolved \*' archive_cmds_F77='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' fi hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_F77=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test "$GCC" = yes; then allow_undefined_flag_F77=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' else allow_undefined_flag_F77=' -expect_unresolved \*' archive_cmds_F77='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' archive_expsym_cmds_F77='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec_F77='-rpath $libdir' fi hardcode_libdir_separator_F77=: ;; solaris*) no_undefined_flag_F77=' -z text' if test "$GCC" = yes; then wlarc='${wl}' archive_cmds_F77='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' else wlarc='' archive_cmds_F77='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' archive_expsym_cmds_F77='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' fi hardcode_libdir_flag_spec_F77='-R$libdir' hardcode_shlibpath_var_F77=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands `-z linker_flag'. GCC discards it without `$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test "$GCC" = yes; then whole_archive_flag_spec_F77='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' else whole_archive_flag_spec_F77='-z allextract$convenience -z defaultextract' fi ;; esac link_all_deplibs_F77=yes ;; sunos4*) if test "x$host_vendor" = xsequent; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. archive_cmds_F77='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_F77='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_direct_F77=yes hardcode_minus_L_F77=yes hardcode_shlibpath_var_F77=no ;; sysv4) case $host_vendor in sni) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_F77=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. archive_cmds_F77='$LD -G -o $lib $libobjs $deplibs $linker_flags' reload_cmds_F77='$CC -r -o $output$reload_objs' hardcode_direct_F77=no ;; motorola) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_F77=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' hardcode_shlibpath_var_F77=no ;; sysv4.3*) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var_F77=no export_dynamic_flag_spec_F77='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var_F77=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ld_shlibs_F77=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag_F77='${wl}-z,text' archive_cmds_need_lc_F77=no hardcode_shlibpath_var_F77=no runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds_F77='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_F77='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We can NOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag_F77='${wl}-z,text' allow_undefined_flag_F77='${wl}-z,nodefs' archive_cmds_need_lc_F77=no hardcode_shlibpath_var_F77=no hardcode_libdir_flag_spec_F77='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' hardcode_libdir_separator_F77=':' link_all_deplibs_F77=yes export_dynamic_flag_spec_F77='${wl}-Bexport' runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds_F77='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_F77='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_shlibpath_var_F77=no ;; *) ld_shlibs_F77=no ;; esac fi { echo "$as_me:$LINENO: result: $ld_shlibs_F77" >&5 echo "${ECHO_T}$ld_shlibs_F77" >&6; } test "$ld_shlibs_F77" = no && can_build_shared=no # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc_F77" in x|xyes) # Assume -lc should be added archive_cmds_need_lc_F77=yes if test "$enable_shared" = yes && test "$GCC" = yes; then case $archive_cmds_F77 in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; } $rm conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl_F77 pic_flag=$lt_prog_compiler_pic_F77 compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag_F77 allow_undefined_flag_F77= if { (eval echo "$as_me:$LINENO: \"$archive_cmds_F77 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 (eval $archive_cmds_F77 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } then archive_cmds_need_lc_F77=no else archive_cmds_need_lc_F77=yes fi allow_undefined_flag_F77=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $rm conftest* { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_F77" >&5 echo "${ECHO_T}$archive_cmds_need_lc_F77" >&6; } ;; esac fi ;; esac { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; } library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=".so" postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='${libname}${release}${shared_ext}$major' ;; aix[4-9]*) version_type=linux need_lib_prefix=no need_version=no hardcode_into_libs=yes if test "$host_cpu" = ia64; then # AIX 5 supports IA64 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line `#! .'. This would cause the generated library to # depend on `.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then : else can_build_shared=no fi ;; esac # AIX (on Power*) has no versioning support, so currently we can not hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. if test "$aix_use_runtimelinking" = yes; then # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' else # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='${libname}${release}.a $libname.a' soname_spec='${libname}${release}${shared_ext}$major' fi shlibpath_var=LIBPATH fi ;; amigaos*) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; beos*) library_names_spec='${libname}${shared_ext}' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32*) version_type=windows shrext_cmds=".dll" need_version=no need_lib_prefix=no case $GCC,$host_os in yes,cygwin* | yes,mingw* | yes,pw32*) library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \${file}`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" ;; mingw*) # MinGW DLLs use traditional 'lib' prefix soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH printed by # mingw gcc, but we are running on Cygwin. Gcc prints its search # path with ; separators, and with drive letters. We can handle the # drive letters (cygwin fileutils understands them), so leave them, # especially as we might pass files found there to a mingw objdump, # which wouldn't understand a cygwinified path. Ahh. sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' ;; esac ;; *) library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' ;; esac dynamic_linker='Win32 ld.exe' # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' soname_spec='${libname}${release}${major}$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd1*) dynamic_linker=no ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[123]*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; gnu*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' if test "X$HPUX_IA64_MODE" = X32; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" fi sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555. postinstall_cmds='chmod 555 $lib' ;; interix[3-9]*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test "$lt_cv_prog_gnu_ld" = yes; then version_type=linux else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. linux* | k*bsd*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Append ld.so.conf contents to the search path if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsdelf*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; nto-qnx*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; openbsd*) version_type=sunos sys_lib_dlsearch_path_spec="/usr/lib" need_lib_prefix=no # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. case $host_os in openbsd3.3 | openbsd3.3.*) need_version=yes ;; *) need_version=no ;; esac library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then case $host_os in openbsd2.[89] | openbsd2.[89].*) shlibpath_overrides_runpath=no ;; *) shlibpath_overrides_runpath=yes ;; esac else shlibpath_overrides_runpath=yes fi ;; os2*) libname_spec='$name' shrext_cmds=".dll" need_lib_prefix=no library_names_spec='$libname${shared_ext} $libname.a' dynamic_linker='OS/2 ld.exe' shlibpath_var=LIBPATH ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test "$with_gnu_ld" = yes; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no export_dynamic_flag_spec='${wl}-Blargedynsym' runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec ;then version_type=linux library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' soname_spec='$libname${shared_ext}.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=freebsd-elf need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes if test "$with_gnu_ld" = yes; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' shlibpath_overrides_runpath=no else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' shlibpath_overrides_runpath=yes case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; uts4*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6; } test "$dynamic_linker" = no && can_build_shared=no if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" fi sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" fi sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test "$GCC" = yes; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; } hardcode_action_F77= if test -n "$hardcode_libdir_flag_spec_F77" || \ test -n "$runpath_var_F77" || \ test "X$hardcode_automatic_F77" = "Xyes" ; then # We can hardcode non-existant directories. if test "$hardcode_direct_F77" != no && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, F77)" != no && test "$hardcode_minus_L_F77" != no; then # Linking always hardcodes the temporary library directory. hardcode_action_F77=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action_F77=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action_F77=unsupported fi { echo "$as_me:$LINENO: result: $hardcode_action_F77" >&5 echo "${ECHO_T}$hardcode_action_F77" >&6; } if test "$hardcode_action_F77" = relink; then # Fast installation is not supported enable_fast_install=no elif test "$shlibpath_overrides_runpath" = yes || test "$enable_shared" = no; then # Fast installation is not necessary enable_fast_install=needless fi # The else clause should only fire when bootstrapping the # libtool distribution, otherwise you forgot to ship ltmain.sh # with your package, and you will get complaints that there are # no rules to generate ltmain.sh. if test -f "$ltmain"; then # See if we are running on zsh, and set the options which allow our commands through # without removal of \ escapes. if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi # Now quote all the things that may contain metacharacters while being # careful not to overquote the AC_SUBSTed values. We take copies of the # variables and quote the copies for generation of the libtool script. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ SED SHELL STRIP \ libname_spec library_names_spec soname_spec extract_expsyms_cmds \ old_striplib striplib file_magic_cmd finish_cmds finish_eval \ deplibs_check_method reload_flag reload_cmds need_locks \ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_c_name_address \ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ old_postinstall_cmds old_postuninstall_cmds \ compiler_F77 \ CC_F77 \ LD_F77 \ lt_prog_compiler_wl_F77 \ lt_prog_compiler_pic_F77 \ lt_prog_compiler_static_F77 \ lt_prog_compiler_no_builtin_flag_F77 \ export_dynamic_flag_spec_F77 \ thread_safe_flag_spec_F77 \ whole_archive_flag_spec_F77 \ enable_shared_with_static_runtimes_F77 \ old_archive_cmds_F77 \ old_archive_from_new_cmds_F77 \ predep_objects_F77 \ postdep_objects_F77 \ predeps_F77 \ postdeps_F77 \ compiler_lib_search_path_F77 \ compiler_lib_search_dirs_F77 \ archive_cmds_F77 \ archive_expsym_cmds_F77 \ postinstall_cmds_F77 \ postuninstall_cmds_F77 \ old_archive_from_expsyms_cmds_F77 \ allow_undefined_flag_F77 \ no_undefined_flag_F77 \ export_symbols_cmds_F77 \ hardcode_libdir_flag_spec_F77 \ hardcode_libdir_flag_spec_ld_F77 \ hardcode_libdir_separator_F77 \ hardcode_automatic_F77 \ module_cmds_F77 \ module_expsym_cmds_F77 \ lt_cv_prog_compiler_c_o_F77 \ fix_srcfile_path_F77 \ exclude_expsyms_F77 \ include_expsyms_F77; do case $var in old_archive_cmds_F77 | \ old_archive_from_new_cmds_F77 | \ archive_cmds_F77 | \ archive_expsym_cmds_F77 | \ module_cmds_F77 | \ module_expsym_cmds_F77 | \ old_archive_from_expsyms_cmds_F77 | \ export_symbols_cmds_F77 | \ extract_expsyms_cmds | reload_cmds | finish_cmds | \ postinstall_cmds | postuninstall_cmds | \ old_postinstall_cmds | old_postuninstall_cmds | \ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) # Double-quote double-evaled strings. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" ;; *) eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; esac done case $lt_echo in *'\$0 --fallback-echo"') lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` ;; esac cfgfile="$ofile" cat <<__EOF__ >> "$cfgfile" # ### BEGIN LIBTOOL TAG CONFIG: $tagname # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc_F77 # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_F77 # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # An echo program that does not interpret backslashes. echo=$lt_echo # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A C compiler. LTCC=$lt_LTCC # LTCC compiler flags. LTCFLAGS=$lt_LTCFLAGS # A language-specific compiler. CC=$lt_compiler_F77 # Is the compiler the GNU C compiler? with_gcc=$GCC_F77 # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD_F77 # Whether we need hard or soft links. LN_S=$lt_LN_S # A BSD-compatible nm program. NM=$lt_NM # A symbol stripping program STRIP=$lt_STRIP # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL" # Used on cygwin: object dumper. OBJDUMP="$OBJDUMP" # Used on cygwin: assembler. AS="$AS" # The name of the directory that contains temporary libtool files. objdir=$objdir # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl_F77 # Object file suffix (normally "o"). objext="$ac_objext" # Old archive suffix (normally "a"). libext="$libext" # Shared library suffix (normally ".so"). shrext_cmds='$shrext_cmds' # Executable file suffix (normally ""). exeext="$exeext" # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic_F77 pic_mode=$pic_mode # What is the maximum length of a command? max_cmd_len=$lt_cv_sys_max_cmd_len # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o_F77 # Must we lock files when doing compilation? need_locks=$lt_need_locks # Do we need the lib prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static_F77 # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_F77 # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_F77 # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_F77 # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec_F77 # Library versioning type. version_type=$version_type # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Commands used to build and install an old-style archive. RANLIB=$lt_RANLIB old_archive_cmds=$lt_old_archive_cmds_F77 old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_F77 # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_F77 # Commands used to build and install a shared archive. archive_cmds=$lt_archive_cmds_F77 archive_expsym_cmds=$lt_archive_expsym_cmds_F77 postinstall_cmds=$lt_postinstall_cmds postuninstall_cmds=$lt_postuninstall_cmds # Commands used to build a loadable module (assumed same as above if empty) module_cmds=$lt_module_cmds_F77 module_expsym_cmds=$lt_module_expsym_cmds_F77 # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_predep_objects_F77 # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects_F77 # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps_F77 # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_F77 # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_F77 # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_F77 # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method == file_magic. file_magic_cmd=$lt_file_magic_cmd # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag_F77 # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_F77 # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # Same as above, but a single script fragment to be evaled but not shown. finish_eval=$lt_finish_eval # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm in a C name address pair global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # This is the shared library runtime path variable. runpath_var=$runpath_var # This is the shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action_F77 # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist. hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_F77 # If ld is used when linking, flag to hardcode \$libdir into # a binary during linking. This must work even if \$libdir does # not exist. hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_F77 # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_F77 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct_F77 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L_F77 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var_F77 # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=$hardcode_automatic_F77 # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="$variables_saved_for_relink" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs_F77 # Compile-time system search path for libraries sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Run-time system search path for libraries sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec # Fix the shell variable \$srcfile for the compiler. fix_srcfile_path=$lt_fix_srcfile_path # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols_F77 # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds_F77 # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms_F77 # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_F77 # ### END LIBTOOL TAG CONFIG: $tagname __EOF__ else # If there is no Makefile yet, we rely on a make rule to execute # `config.status --recheck' to rerun these tests and create the # libtool script then. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` if test -f "$ltmain_in"; then test -f Makefile && make "$ltmain" fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC="$lt_save_CC" else tagname="" fi ;; GCJ) if test -n "$GCJ" && test "X$GCJ" != "Xno"; then # Source file extension for Java test sources. ac_ext=java # Object file extension for compiled Java test sources. objext=o objext_GCJ=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="class foo {}" # Code to be used in simple link tests lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $rm conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $rm -r conftest* # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${GCJ-"gcj"} compiler=$CC compiler_GCJ=$CC for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` # GCJ did not exist at the time GCC didn't implicitly link libc in. archive_cmds_need_lc_GCJ=no old_archive_cmds_GCJ=$old_archive_cmds lt_prog_compiler_no_builtin_flag_GCJ= if test "$GCC" = yes; then lt_prog_compiler_no_builtin_flag_GCJ=' -fno-builtin' { echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-fno-rtti -fno-exceptions" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:__oline__: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_rtti_exceptions=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6; } if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then lt_prog_compiler_no_builtin_flag_GCJ="$lt_prog_compiler_no_builtin_flag_GCJ -fno-rtti -fno-exceptions" else : fi fi lt_prog_compiler_wl_GCJ= lt_prog_compiler_pic_GCJ= lt_prog_compiler_static_GCJ= { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; } if test "$GCC" = yes; then lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_static_GCJ='-static' case $host_os in aix*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_GCJ='-Bstatic' fi ;; amigaos*) # FIXME: we need at least 68020 code to build shared libraries, but # adding the `-m68020' flag to GCC prevents building anything better, # like `-m68040'. lt_prog_compiler_pic_GCJ='-m68020 -resident32 -malways-restore-a4' ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic_GCJ='-fno-common' ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. lt_prog_compiler_can_build_shared_GCJ=no enable_shared=no ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic_GCJ=-Kconform_pic fi ;; hpux*) # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_GCJ='-fPIC' ;; esac ;; *) lt_prog_compiler_pic_GCJ='-fPIC' ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) lt_prog_compiler_wl_GCJ='-Wl,' if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_GCJ='-Bstatic' else lt_prog_compiler_static_GCJ='-bnso -bI:/lib/syscalls.exp' fi ;; darwin*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files case $cc_basename in xlc*) lt_prog_compiler_pic_GCJ='-qnocommon' lt_prog_compiler_wl_GCJ='-Wl,' ;; esac ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). ;; hpux9* | hpux10* | hpux11*) lt_prog_compiler_wl_GCJ='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_GCJ='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? lt_prog_compiler_static_GCJ='${wl}-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) lt_prog_compiler_wl_GCJ='-Wl,' # PIC (with -KPIC) is the default. lt_prog_compiler_static_GCJ='-non_shared' ;; newsos6) lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; linux* | k*bsd*-gnu) case $cc_basename in icc* | ecc*) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-static' ;; pgcc* | pgf77* | pgf90* | pgf95*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_pic_GCJ='-fpic' lt_prog_compiler_static_GCJ='-Bstatic' ;; ccc*) lt_prog_compiler_wl_GCJ='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static_GCJ='-non_shared' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' lt_prog_compiler_wl_GCJ='-Wl,' ;; *Sun\ F*) # Sun Fortran 8.3 passes all unrecognized flags to the linker lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' lt_prog_compiler_wl_GCJ='' ;; esac ;; esac ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl_GCJ='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static_GCJ='-non_shared' ;; rdos*) lt_prog_compiler_static_GCJ='-non_shared' ;; solaris*) lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' case $cc_basename in f77* | f90* | f95*) lt_prog_compiler_wl_GCJ='-Qoption ld ';; *) lt_prog_compiler_wl_GCJ='-Wl,';; esac ;; sunos4*) lt_prog_compiler_wl_GCJ='-Qoption ld ' lt_prog_compiler_pic_GCJ='-PIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec ;then lt_prog_compiler_pic_GCJ='-Kconform_pic' lt_prog_compiler_static_GCJ='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; unicos*) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_can_build_shared_GCJ=no ;; uts4*) lt_prog_compiler_pic_GCJ='-pic' lt_prog_compiler_static_GCJ='-Bstatic' ;; *) lt_prog_compiler_can_build_shared_GCJ=no ;; esac fi { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_GCJ" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_GCJ" >&6; } # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic_GCJ"; then { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_pic_works_GCJ+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_pic_works_GCJ=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic_GCJ" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:__oline__: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works_GCJ=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works_GCJ" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_pic_works_GCJ" >&6; } if test x"$lt_cv_prog_compiler_pic_works_GCJ" = xyes; then case $lt_prog_compiler_pic_GCJ in "" | " "*) ;; *) lt_prog_compiler_pic_GCJ=" $lt_prog_compiler_pic_GCJ" ;; esac else lt_prog_compiler_pic_GCJ= lt_prog_compiler_can_build_shared_GCJ=no fi fi case $host_os in # For platforms which do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic_GCJ= ;; *) lt_prog_compiler_pic_GCJ="$lt_prog_compiler_pic_GCJ" ;; esac # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl_GCJ eval lt_tmp_static_flag=\"$lt_prog_compiler_static_GCJ\" { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_static_works_GCJ+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_static_works_GCJ=no save_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works_GCJ=yes fi else lt_cv_prog_compiler_static_works_GCJ=yes fi fi $rm -r conftest* LDFLAGS="$save_LDFLAGS" fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works_GCJ" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_static_works_GCJ" >&6; } if test x"$lt_cv_prog_compiler_static_works_GCJ" = xyes; then : else lt_prog_compiler_static_GCJ= fi { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_c_o_GCJ+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o_GCJ=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:__oline__: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o_GCJ=yes fi fi chmod u+w . 2>&5 $rm conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files $rm out/* && rmdir out cd .. rmdir conftest $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_GCJ" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_GCJ" >&6; } hard_links="nottested" if test "$lt_cv_prog_compiler_c_o_GCJ" = no && test "$need_locks" != no; then # do not overwrite the value of need_locks provided by the user { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; } hard_links=yes $rm conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6; } if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; } runpath_var= allow_undefined_flag_GCJ= enable_shared_with_static_runtimes_GCJ=no archive_cmds_GCJ= archive_expsym_cmds_GCJ= old_archive_From_new_cmds_GCJ= old_archive_from_expsyms_cmds_GCJ= export_dynamic_flag_spec_GCJ= whole_archive_flag_spec_GCJ= thread_safe_flag_spec_GCJ= hardcode_libdir_flag_spec_GCJ= hardcode_libdir_flag_spec_ld_GCJ= hardcode_libdir_separator_GCJ= hardcode_direct_GCJ=no hardcode_minus_L_GCJ=no hardcode_shlibpath_var_GCJ=unsupported link_all_deplibs_GCJ=unknown hardcode_automatic_GCJ=no module_cmds_GCJ= module_expsym_cmds_GCJ= always_export_symbols_GCJ=no export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list include_expsyms_GCJ= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ` (' and `)$', so one must not match beginning or # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', # as well as any symbol that contains `d'. exclude_expsyms_GCJ='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. extract_expsyms_cmds= # Just being paranoid about ensuring that cc_basename is set. for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` case $host_os in cygwin* | mingw* | pw32*) # FIXME: the MSVC++ port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++. if test "$GCC" != yes; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++) with_gnu_ld=yes ;; openbsd*) with_gnu_ld=no ;; esac ld_shlibs_GCJ=yes if test "$with_gnu_ld" = yes; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='${wl}' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec_GCJ='${wl}--rpath ${wl}$libdir' export_dynamic_flag_spec_GCJ='${wl}--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then whole_archive_flag_spec_GCJ="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else whole_archive_flag_spec_GCJ= fi supports_anon_versioning=no case `$LD -v 2>/dev/null` in *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[3-9]*) # On AIX/PPC, the GNU linker is very broken if test "$host_cpu" != ia64; then ld_shlibs_GCJ=no cat <&2 *** Warning: the GNU linker, at least up to release 2.9.1, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to modify your PATH *** so that a non-GNU linker is found, and then restart. EOF fi ;; amigaos*) archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_minus_L_GCJ=yes # Samuel A. Falvo II reports # that the semantics of dynamic libraries on AmigaOS, at least up # to version 4, is to share data among multiple programs linked # with the same dynamic library. Since this doesn't match the # behavior of shared libraries on other platforms, we can't use # them. ld_shlibs_GCJ=no ;; beos*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then allow_undefined_flag_GCJ=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds_GCJ='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' else ld_shlibs_GCJ=no fi ;; cygwin* | mingw* | pw32*) # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, GCJ) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec_GCJ='-L$libdir' allow_undefined_flag_GCJ=unsupported always_export_symbols_GCJ=no enable_shared_with_static_runtimes_GCJ=yes export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file (1st line # is EXPORTS), use it as is; otherwise, prepend... archive_expsym_cmds_GCJ='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs_GCJ=no fi ;; interix[3-9]*) hardcode_direct_GCJ=no hardcode_shlibpath_var_GCJ=no hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' export_dynamic_flag_spec_GCJ='${wl}-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds_GCJ='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds_GCJ='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | k*bsd*-gnu) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then tmp_addflag= case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; esac case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 whole_archive_flag_spec_GCJ='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; *) tmp_sharedflag='-shared' ;; esac archive_cmds_GCJ='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' if test $supports_anon_versioning = yes; then archive_expsym_cmds_GCJ='$echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ $echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' fi link_all_deplibs_GCJ=no else ld_shlibs_GCJ=no fi ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds_GCJ='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then ld_shlibs_GCJ=no cat <&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. EOF elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs_GCJ=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) ld_shlibs_GCJ=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then hardcode_libdir_flag_spec_GCJ='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' else ld_shlibs_GCJ=no fi ;; esac ;; sunos4*) archive_cmds_GCJ='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs_GCJ=no fi ;; esac if test "$ld_shlibs_GCJ" = no; then runpath_var= hardcode_libdir_flag_spec_GCJ= export_dynamic_flag_spec_GCJ= whole_archive_flag_spec_GCJ= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) allow_undefined_flag_GCJ=unsupported always_export_symbols_GCJ=yes archive_expsym_cmds_GCJ='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. hardcode_minus_L_GCJ=yes if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct_GCJ=unsupported fi ;; aix[4-9]*) if test "$host_cpu" = ia64; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag="" else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to AIX nm, but means don't demangle with GNU nm if $NM -V 2>&1 | grep 'GNU' > /dev/null; then export_symbols_cmds_GCJ='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' else export_symbols_cmds_GCJ='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # need to do runtime linking. case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then aix_use_runtimelinking=yes break fi done ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds_GCJ='' hardcode_direct_GCJ=yes hardcode_libdir_separator_GCJ=':' link_all_deplibs_GCJ=yes if test "$GCC" = yes; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`${CC} -print-prog-name=collect2` if test -f "$collect2name" && \ strings "$collect2name" | grep resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct_GCJ=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L_GCJ=yes hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_libdir_separator_GCJ= fi ;; esac shared_flag='-shared' if test "$aix_use_runtimelinking" = yes; then shared_flag="$shared_flag "'${wl}-G' fi else # not using gcc if test "$host_cpu" = ia64; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test "$aix_use_runtimelinking" = yes; then shared_flag='${wl}-G' else shared_flag='${wl}-bM:SRE' fi fi fi # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols_GCJ=yes if test "$aix_use_runtimelinking" = yes; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag_GCJ='-berok' # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds_GCJ="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" else if test "$host_cpu" = ia64; then hardcode_libdir_flag_spec_GCJ='${wl}-R $libdir:/usr/lib:/lib' allow_undefined_flag_GCJ="-z nodefs" archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag_GCJ=' ${wl}-bernotok' allow_undefined_flag_GCJ=' ${wl}-berok' # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec_GCJ='$convenience' archive_cmds_need_lc_GCJ=yes # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; amigaos*) archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_minus_L_GCJ=yes # see comment about different semantics on the GNU ld section ld_shlibs_GCJ=no ;; bsdi[45]*) export_dynamic_flag_spec_GCJ=-rdynamic ;; cygwin* | mingw* | pw32*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. hardcode_libdir_flag_spec_GCJ=' ' allow_undefined_flag_GCJ=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=".dll" # FIXME: Setting linknames here is a bad hack. archive_cmds_GCJ='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. old_archive_From_new_cmds_GCJ='true' # FIXME: Should let the user specify the lib program. old_archive_cmds_GCJ='lib -OUT:$oldlib$oldobjs$old_deplibs' fix_srcfile_path_GCJ='`cygpath -w "$srcfile"`' enable_shared_with_static_runtimes_GCJ=yes ;; darwin* | rhapsody*) case $host_os in rhapsody* | darwin1.[012]) allow_undefined_flag_GCJ='${wl}-undefined ${wl}suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[012]) allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 10.*) allow_undefined_flag_GCJ='${wl}-undefined ${wl}dynamic_lookup' ;; esac fi ;; esac archive_cmds_need_lc_GCJ=no hardcode_direct_GCJ=no hardcode_automatic_GCJ=yes hardcode_shlibpath_var_GCJ=unsupported whole_archive_flag_spec_GCJ='' link_all_deplibs_GCJ=yes if test "$GCC" = yes ; then output_verbose_link_cmd='echo' archive_cmds_GCJ="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" module_cmds_GCJ="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" archive_expsym_cmds_GCJ="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" module_expsym_cmds_GCJ="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" else case $cc_basename in xlc*) output_verbose_link_cmd='echo' archive_cmds_GCJ='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' ;; *) ld_shlibs_GCJ=no ;; esac fi ;; dgux*) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_shlibpath_var_GCJ=no ;; freebsd1*) ld_shlibs_GCJ=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' hardcode_libdir_flag_spec_GCJ='-R$libdir' hardcode_direct_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2*) archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_GCJ=yes hardcode_minus_L_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly*) archive_cmds_GCJ='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec_GCJ='-R$libdir' hardcode_direct_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; hpux9*) if test "$GCC" = yes; then archive_cmds_GCJ='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' else archive_cmds_GCJ='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' fi hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' hardcode_libdir_separator_GCJ=: hardcode_direct_GCJ=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_GCJ=yes export_dynamic_flag_spec_GCJ='${wl}-E' ;; hpux10*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_GCJ='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' hardcode_libdir_separator_GCJ=: hardcode_direct_GCJ=yes export_dynamic_flag_spec_GCJ='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_GCJ=yes fi ;; hpux11*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then case $host_cpu in hppa*64*) archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' hardcode_libdir_separator_GCJ=: case $host_cpu in hppa*64*|ia64*) hardcode_libdir_flag_spec_ld_GCJ='+b $libdir' hardcode_direct_GCJ=no hardcode_shlibpath_var_GCJ=no ;; *) hardcode_direct_GCJ=yes export_dynamic_flag_spec_GCJ='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_GCJ=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test "$GCC" = yes; then archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else archive_cmds_GCJ='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_ld_GCJ='-rpath $libdir' fi hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_GCJ=: link_all_deplibs_GCJ=yes ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else archive_cmds_GCJ='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi hardcode_libdir_flag_spec_GCJ='-R$libdir' hardcode_direct_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; newsos6) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_GCJ=yes hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_GCJ=: hardcode_shlibpath_var_GCJ=no ;; openbsd*) if test -f /usr/libexec/ld.so; then hardcode_direct_GCJ=yes hardcode_shlibpath_var_GCJ=no if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' export_dynamic_flag_spec_GCJ='${wl}-E' else case $host_os in openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_GCJ='-R$libdir' ;; *) archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' ;; esac fi else ld_shlibs_GCJ=no fi ;; os2*) hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_minus_L_GCJ=yes allow_undefined_flag_GCJ=unsupported archive_cmds_GCJ='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' old_archive_From_new_cmds_GCJ='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' ;; osf3*) if test "$GCC" = yes; then allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else allow_undefined_flag_GCJ=' -expect_unresolved \*' archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' fi hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_GCJ=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test "$GCC" = yes; then allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' else allow_undefined_flag_GCJ=' -expect_unresolved \*' archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' archive_expsym_cmds_GCJ='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec_GCJ='-rpath $libdir' fi hardcode_libdir_separator_GCJ=: ;; solaris*) no_undefined_flag_GCJ=' -z text' if test "$GCC" = yes; then wlarc='${wl}' archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' else wlarc='' archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' fi hardcode_libdir_flag_spec_GCJ='-R$libdir' hardcode_shlibpath_var_GCJ=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands `-z linker_flag'. GCC discards it without `$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test "$GCC" = yes; then whole_archive_flag_spec_GCJ='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' else whole_archive_flag_spec_GCJ='-z allextract$convenience -z defaultextract' fi ;; esac link_all_deplibs_GCJ=yes ;; sunos4*) if test "x$host_vendor" = xsequent; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. archive_cmds_GCJ='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_GCJ='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_direct_GCJ=yes hardcode_minus_L_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; sysv4) case $host_vendor in sni) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_GCJ=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' reload_cmds_GCJ='$CC -r -o $output$reload_objs' hardcode_direct_GCJ=no ;; motorola) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_GCJ=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' hardcode_shlibpath_var_GCJ=no ;; sysv4.3*) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var_GCJ=no export_dynamic_flag_spec_GCJ='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var_GCJ=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ld_shlibs_GCJ=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag_GCJ='${wl}-z,text' archive_cmds_need_lc_GCJ=no hardcode_shlibpath_var_GCJ=no runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds_GCJ='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_GCJ='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We can NOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag_GCJ='${wl}-z,text' allow_undefined_flag_GCJ='${wl}-z,nodefs' archive_cmds_need_lc_GCJ=no hardcode_shlibpath_var_GCJ=no hardcode_libdir_flag_spec_GCJ='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' hardcode_libdir_separator_GCJ=':' link_all_deplibs_GCJ=yes export_dynamic_flag_spec_GCJ='${wl}-Bexport' runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds_GCJ='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_GCJ='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_shlibpath_var_GCJ=no ;; *) ld_shlibs_GCJ=no ;; esac fi { echo "$as_me:$LINENO: result: $ld_shlibs_GCJ" >&5 echo "${ECHO_T}$ld_shlibs_GCJ" >&6; } test "$ld_shlibs_GCJ" = no && can_build_shared=no # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc_GCJ" in x|xyes) # Assume -lc should be added archive_cmds_need_lc_GCJ=yes if test "$enable_shared" = yes && test "$GCC" = yes; then case $archive_cmds_GCJ in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; } $rm conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl_GCJ pic_flag=$lt_prog_compiler_pic_GCJ compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag_GCJ allow_undefined_flag_GCJ= if { (eval echo "$as_me:$LINENO: \"$archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 (eval $archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } then archive_cmds_need_lc_GCJ=no else archive_cmds_need_lc_GCJ=yes fi allow_undefined_flag_GCJ=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $rm conftest* { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_GCJ" >&5 echo "${ECHO_T}$archive_cmds_need_lc_GCJ" >&6; } ;; esac fi ;; esac { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; } library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=".so" postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='${libname}${release}${shared_ext}$major' ;; aix[4-9]*) version_type=linux need_lib_prefix=no need_version=no hardcode_into_libs=yes if test "$host_cpu" = ia64; then # AIX 5 supports IA64 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line `#! .'. This would cause the generated library to # depend on `.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then : else can_build_shared=no fi ;; esac # AIX (on Power*) has no versioning support, so currently we can not hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. if test "$aix_use_runtimelinking" = yes; then # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' else # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='${libname}${release}.a $libname.a' soname_spec='${libname}${release}${shared_ext}$major' fi shlibpath_var=LIBPATH fi ;; amigaos*) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; beos*) library_names_spec='${libname}${shared_ext}' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32*) version_type=windows shrext_cmds=".dll" need_version=no need_lib_prefix=no case $GCC,$host_os in yes,cygwin* | yes,mingw* | yes,pw32*) library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \${file}`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" ;; mingw*) # MinGW DLLs use traditional 'lib' prefix soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH printed by # mingw gcc, but we are running on Cygwin. Gcc prints its search # path with ; separators, and with drive letters. We can handle the # drive letters (cygwin fileutils understands them), so leave them, # especially as we might pass files found there to a mingw objdump, # which wouldn't understand a cygwinified path. Ahh. sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' ;; esac ;; *) library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' ;; esac dynamic_linker='Win32 ld.exe' # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' soname_spec='${libname}${release}${major}$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd1*) dynamic_linker=no ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[123]*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; gnu*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' if test "X$HPUX_IA64_MODE" = X32; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" fi sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555. postinstall_cmds='chmod 555 $lib' ;; interix[3-9]*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test "$lt_cv_prog_gnu_ld" = yes; then version_type=linux else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. linux* | k*bsd*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Append ld.so.conf contents to the search path if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsdelf*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; nto-qnx*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; openbsd*) version_type=sunos sys_lib_dlsearch_path_spec="/usr/lib" need_lib_prefix=no # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. case $host_os in openbsd3.3 | openbsd3.3.*) need_version=yes ;; *) need_version=no ;; esac library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then case $host_os in openbsd2.[89] | openbsd2.[89].*) shlibpath_overrides_runpath=no ;; *) shlibpath_overrides_runpath=yes ;; esac else shlibpath_overrides_runpath=yes fi ;; os2*) libname_spec='$name' shrext_cmds=".dll" need_lib_prefix=no library_names_spec='$libname${shared_ext} $libname.a' dynamic_linker='OS/2 ld.exe' shlibpath_var=LIBPATH ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test "$with_gnu_ld" = yes; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no export_dynamic_flag_spec='${wl}-Blargedynsym' runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec ;then version_type=linux library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' soname_spec='$libname${shared_ext}.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=freebsd-elf need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes if test "$with_gnu_ld" = yes; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' shlibpath_overrides_runpath=no else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' shlibpath_overrides_runpath=yes case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; uts4*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6; } test "$dynamic_linker" = no && can_build_shared=no if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" fi sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" fi sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test "$GCC" = yes; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; } hardcode_action_GCJ= if test -n "$hardcode_libdir_flag_spec_GCJ" || \ test -n "$runpath_var_GCJ" || \ test "X$hardcode_automatic_GCJ" = "Xyes" ; then # We can hardcode non-existant directories. if test "$hardcode_direct_GCJ" != no && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, GCJ)" != no && test "$hardcode_minus_L_GCJ" != no; then # Linking always hardcodes the temporary library directory. hardcode_action_GCJ=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action_GCJ=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action_GCJ=unsupported fi { echo "$as_me:$LINENO: result: $hardcode_action_GCJ" >&5 echo "${ECHO_T}$hardcode_action_GCJ" >&6; } if test "$hardcode_action_GCJ" = relink; then # Fast installation is not supported enable_fast_install=no elif test "$shlibpath_overrides_runpath" = yes || test "$enable_shared" = no; then # Fast installation is not necessary enable_fast_install=needless fi # The else clause should only fire when bootstrapping the # libtool distribution, otherwise you forgot to ship ltmain.sh # with your package, and you will get complaints that there are # no rules to generate ltmain.sh. if test -f "$ltmain"; then # See if we are running on zsh, and set the options which allow our commands through # without removal of \ escapes. if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi # Now quote all the things that may contain metacharacters while being # careful not to overquote the AC_SUBSTed values. We take copies of the # variables and quote the copies for generation of the libtool script. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ SED SHELL STRIP \ libname_spec library_names_spec soname_spec extract_expsyms_cmds \ old_striplib striplib file_magic_cmd finish_cmds finish_eval \ deplibs_check_method reload_flag reload_cmds need_locks \ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_c_name_address \ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ old_postinstall_cmds old_postuninstall_cmds \ compiler_GCJ \ CC_GCJ \ LD_GCJ \ lt_prog_compiler_wl_GCJ \ lt_prog_compiler_pic_GCJ \ lt_prog_compiler_static_GCJ \ lt_prog_compiler_no_builtin_flag_GCJ \ export_dynamic_flag_spec_GCJ \ thread_safe_flag_spec_GCJ \ whole_archive_flag_spec_GCJ \ enable_shared_with_static_runtimes_GCJ \ old_archive_cmds_GCJ \ old_archive_from_new_cmds_GCJ \ predep_objects_GCJ \ postdep_objects_GCJ \ predeps_GCJ \ postdeps_GCJ \ compiler_lib_search_path_GCJ \ compiler_lib_search_dirs_GCJ \ archive_cmds_GCJ \ archive_expsym_cmds_GCJ \ postinstall_cmds_GCJ \ postuninstall_cmds_GCJ \ old_archive_from_expsyms_cmds_GCJ \ allow_undefined_flag_GCJ \ no_undefined_flag_GCJ \ export_symbols_cmds_GCJ \ hardcode_libdir_flag_spec_GCJ \ hardcode_libdir_flag_spec_ld_GCJ \ hardcode_libdir_separator_GCJ \ hardcode_automatic_GCJ \ module_cmds_GCJ \ module_expsym_cmds_GCJ \ lt_cv_prog_compiler_c_o_GCJ \ fix_srcfile_path_GCJ \ exclude_expsyms_GCJ \ include_expsyms_GCJ; do case $var in old_archive_cmds_GCJ | \ old_archive_from_new_cmds_GCJ | \ archive_cmds_GCJ | \ archive_expsym_cmds_GCJ | \ module_cmds_GCJ | \ module_expsym_cmds_GCJ | \ old_archive_from_expsyms_cmds_GCJ | \ export_symbols_cmds_GCJ | \ extract_expsyms_cmds | reload_cmds | finish_cmds | \ postinstall_cmds | postuninstall_cmds | \ old_postinstall_cmds | old_postuninstall_cmds | \ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) # Double-quote double-evaled strings. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" ;; *) eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; esac done case $lt_echo in *'\$0 --fallback-echo"') lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` ;; esac cfgfile="$ofile" cat <<__EOF__ >> "$cfgfile" # ### BEGIN LIBTOOL TAG CONFIG: $tagname # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc_GCJ # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_GCJ # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # An echo program that does not interpret backslashes. echo=$lt_echo # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A C compiler. LTCC=$lt_LTCC # LTCC compiler flags. LTCFLAGS=$lt_LTCFLAGS # A language-specific compiler. CC=$lt_compiler_GCJ # Is the compiler the GNU C compiler? with_gcc=$GCC_GCJ # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD_GCJ # Whether we need hard or soft links. LN_S=$lt_LN_S # A BSD-compatible nm program. NM=$lt_NM # A symbol stripping program STRIP=$lt_STRIP # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL" # Used on cygwin: object dumper. OBJDUMP="$OBJDUMP" # Used on cygwin: assembler. AS="$AS" # The name of the directory that contains temporary libtool files. objdir=$objdir # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl_GCJ # Object file suffix (normally "o"). objext="$ac_objext" # Old archive suffix (normally "a"). libext="$libext" # Shared library suffix (normally ".so"). shrext_cmds='$shrext_cmds' # Executable file suffix (normally ""). exeext="$exeext" # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic_GCJ pic_mode=$pic_mode # What is the maximum length of a command? max_cmd_len=$lt_cv_sys_max_cmd_len # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o_GCJ # Must we lock files when doing compilation? need_locks=$lt_need_locks # Do we need the lib prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static_GCJ # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_GCJ # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_GCJ # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_GCJ # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec_GCJ # Library versioning type. version_type=$version_type # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Commands used to build and install an old-style archive. RANLIB=$lt_RANLIB old_archive_cmds=$lt_old_archive_cmds_GCJ old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_GCJ # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_GCJ # Commands used to build and install a shared archive. archive_cmds=$lt_archive_cmds_GCJ archive_expsym_cmds=$lt_archive_expsym_cmds_GCJ postinstall_cmds=$lt_postinstall_cmds postuninstall_cmds=$lt_postuninstall_cmds # Commands used to build a loadable module (assumed same as above if empty) module_cmds=$lt_module_cmds_GCJ module_expsym_cmds=$lt_module_expsym_cmds_GCJ # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_predep_objects_GCJ # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects_GCJ # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps_GCJ # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_GCJ # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_GCJ # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_GCJ # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method == file_magic. file_magic_cmd=$lt_file_magic_cmd # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag_GCJ # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_GCJ # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # Same as above, but a single script fragment to be evaled but not shown. finish_eval=$lt_finish_eval # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm in a C name address pair global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # This is the shared library runtime path variable. runpath_var=$runpath_var # This is the shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action_GCJ # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist. hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_GCJ # If ld is used when linking, flag to hardcode \$libdir into # a binary during linking. This must work even if \$libdir does # not exist. hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_GCJ # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_GCJ # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct_GCJ # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L_GCJ # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var_GCJ # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=$hardcode_automatic_GCJ # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="$variables_saved_for_relink" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs_GCJ # Compile-time system search path for libraries sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Run-time system search path for libraries sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec # Fix the shell variable \$srcfile for the compiler. fix_srcfile_path=$lt_fix_srcfile_path # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols_GCJ # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds_GCJ # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms_GCJ # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_GCJ # ### END LIBTOOL TAG CONFIG: $tagname __EOF__ else # If there is no Makefile yet, we rely on a make rule to execute # `config.status --recheck' to rerun these tests and create the # libtool script then. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` if test -f "$ltmain_in"; then test -f Makefile && make "$ltmain" fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC="$lt_save_CC" else tagname="" fi ;; RC) # Source file extension for RC test sources. ac_ext=rc # Object file extension for compiled RC test sources. objext=o objext_RC=$objext # Code to be used in simple compile tests lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' # Code to be used in simple link tests lt_simple_link_test_code="$lt_simple_compile_test_code" # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $rm conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $rm -r conftest* # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${RC-"windres"} compiler=$CC compiler_RC=$CC for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` lt_cv_prog_compiler_c_o_RC=yes # The else clause should only fire when bootstrapping the # libtool distribution, otherwise you forgot to ship ltmain.sh # with your package, and you will get complaints that there are # no rules to generate ltmain.sh. if test -f "$ltmain"; then # See if we are running on zsh, and set the options which allow our commands through # without removal of \ escapes. if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi # Now quote all the things that may contain metacharacters while being # careful not to overquote the AC_SUBSTed values. We take copies of the # variables and quote the copies for generation of the libtool script. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ SED SHELL STRIP \ libname_spec library_names_spec soname_spec extract_expsyms_cmds \ old_striplib striplib file_magic_cmd finish_cmds finish_eval \ deplibs_check_method reload_flag reload_cmds need_locks \ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_c_name_address \ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ old_postinstall_cmds old_postuninstall_cmds \ compiler_RC \ CC_RC \ LD_RC \ lt_prog_compiler_wl_RC \ lt_prog_compiler_pic_RC \ lt_prog_compiler_static_RC \ lt_prog_compiler_no_builtin_flag_RC \ export_dynamic_flag_spec_RC \ thread_safe_flag_spec_RC \ whole_archive_flag_spec_RC \ enable_shared_with_static_runtimes_RC \ old_archive_cmds_RC \ old_archive_from_new_cmds_RC \ predep_objects_RC \ postdep_objects_RC \ predeps_RC \ postdeps_RC \ compiler_lib_search_path_RC \ compiler_lib_search_dirs_RC \ archive_cmds_RC \ archive_expsym_cmds_RC \ postinstall_cmds_RC \ postuninstall_cmds_RC \ old_archive_from_expsyms_cmds_RC \ allow_undefined_flag_RC \ no_undefined_flag_RC \ export_symbols_cmds_RC \ hardcode_libdir_flag_spec_RC \ hardcode_libdir_flag_spec_ld_RC \ hardcode_libdir_separator_RC \ hardcode_automatic_RC \ module_cmds_RC \ module_expsym_cmds_RC \ lt_cv_prog_compiler_c_o_RC \ fix_srcfile_path_RC \ exclude_expsyms_RC \ include_expsyms_RC; do case $var in old_archive_cmds_RC | \ old_archive_from_new_cmds_RC | \ archive_cmds_RC | \ archive_expsym_cmds_RC | \ module_cmds_RC | \ module_expsym_cmds_RC | \ old_archive_from_expsyms_cmds_RC | \ export_symbols_cmds_RC | \ extract_expsyms_cmds | reload_cmds | finish_cmds | \ postinstall_cmds | postuninstall_cmds | \ old_postinstall_cmds | old_postuninstall_cmds | \ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) # Double-quote double-evaled strings. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" ;; *) eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; esac done case $lt_echo in *'\$0 --fallback-echo"') lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` ;; esac cfgfile="$ofile" cat <<__EOF__ >> "$cfgfile" # ### BEGIN LIBTOOL TAG CONFIG: $tagname # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc_RC # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # An echo program that does not interpret backslashes. echo=$lt_echo # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A C compiler. LTCC=$lt_LTCC # LTCC compiler flags. LTCFLAGS=$lt_LTCFLAGS # A language-specific compiler. CC=$lt_compiler_RC # Is the compiler the GNU C compiler? with_gcc=$GCC_RC # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD_RC # Whether we need hard or soft links. LN_S=$lt_LN_S # A BSD-compatible nm program. NM=$lt_NM # A symbol stripping program STRIP=$lt_STRIP # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL" # Used on cygwin: object dumper. OBJDUMP="$OBJDUMP" # Used on cygwin: assembler. AS="$AS" # The name of the directory that contains temporary libtool files. objdir=$objdir # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl_RC # Object file suffix (normally "o"). objext="$ac_objext" # Old archive suffix (normally "a"). libext="$libext" # Shared library suffix (normally ".so"). shrext_cmds='$shrext_cmds' # Executable file suffix (normally ""). exeext="$exeext" # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic_RC pic_mode=$pic_mode # What is the maximum length of a command? max_cmd_len=$lt_cv_sys_max_cmd_len # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC # Must we lock files when doing compilation? need_locks=$lt_need_locks # Do we need the lib prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static_RC # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC # Library versioning type. version_type=$version_type # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Commands used to build and install an old-style archive. RANLIB=$lt_RANLIB old_archive_cmds=$lt_old_archive_cmds_RC old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC # Commands used to build and install a shared archive. archive_cmds=$lt_archive_cmds_RC archive_expsym_cmds=$lt_archive_expsym_cmds_RC postinstall_cmds=$lt_postinstall_cmds postuninstall_cmds=$lt_postuninstall_cmds # Commands used to build a loadable module (assumed same as above if empty) module_cmds=$lt_module_cmds_RC module_expsym_cmds=$lt_module_expsym_cmds_RC # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_predep_objects_RC # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects_RC # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps_RC # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_RC # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_RC # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_RC # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method == file_magic. file_magic_cmd=$lt_file_magic_cmd # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag_RC # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_RC # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # Same as above, but a single script fragment to be evaled but not shown. finish_eval=$lt_finish_eval # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm in a C name address pair global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # This is the shared library runtime path variable. runpath_var=$runpath_var # This is the shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action_RC # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist. hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC # If ld is used when linking, flag to hardcode \$libdir into # a binary during linking. This must work even if \$libdir does # not exist. hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct_RC # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L_RC # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var_RC # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=$hardcode_automatic_RC # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="$variables_saved_for_relink" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs_RC # Compile-time system search path for libraries sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Run-time system search path for libraries sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec # Fix the shell variable \$srcfile for the compiler. fix_srcfile_path=$lt_fix_srcfile_path # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols_RC # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds_RC # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms_RC # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_RC # ### END LIBTOOL TAG CONFIG: $tagname __EOF__ else # If there is no Makefile yet, we rely on a make rule to execute # `config.status --recheck' to rerun these tests and create the # libtool script then. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` if test -f "$ltmain_in"; then test -f Makefile && make "$ltmain" fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC="$lt_save_CC" ;; *) { { echo "$as_me:$LINENO: error: Unsupported tag name: $tagname" >&5 echo "$as_me: error: Unsupported tag name: $tagname" >&2;} { (exit 1); exit 1; }; } ;; esac # Append the new tag name to the list of available tags. if test -n "$tagname" ; then available_tags="$available_tags $tagname" fi fi done IFS="$lt_save_ifs" # Now substitute the updated list of available tags. if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then mv "${ofile}T" "$ofile" chmod +x "$ofile" else rm -f "${ofile}T" { { echo "$as_me:$LINENO: error: unable to update list of available tagged configurations." >&5 echo "$as_me: error: unable to update list of available tagged configurations." >&2;} { (exit 1); exit 1; }; } fi fi # This can be used to rebuild libtool when needed LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' # Prevent multiple expansion # Checks for libraries. { echo "$as_me:$LINENO: checking for pow in -lm" >&5 echo $ECHO_N "checking for pow in -lm... $ECHO_C" >&6; } if test "${ac_cv_lib_m_pow+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lm $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char pow (); int main () { return pow (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_m_pow=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_m_pow=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_m_pow" >&5 echo "${ECHO_T}$ac_cv_lib_m_pow" >&6; } if test $ac_cv_lib_m_pow = yes; then cat >>confdefs.h <<_ACEOF @%:@define HAVE_LIBM 1 _ACEOF LIBS="-lm $LIBS" fi { echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6; } if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lpthread $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char pthread_create (); int main () { return pthread_create (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_pthread_pthread_create=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_pthread_pthread_create=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6; } if test $ac_cv_lib_pthread_pthread_create = yes; then cat >>confdefs.h <<_ACEOF @%:@define HAVE_LIBPTHREAD 1 _ACEOF LIBS="-lpthread $LIBS" fi # Checks for header files. { echo "$as_me:$LINENO: checking for ANSI C header files" >&5 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; } if test "${ac_cv_header_stdc+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_header_stdc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi fi { echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 echo "${ECHO_T}$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then cat >>confdefs.h <<\_ACEOF @%:@define STDC_HEADERS 1 _ACEOF fi for ac_header in arpa/inet.h netdb.h netinet/in.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default @%:@include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX @%:@@%:@ ----------------------------------- @%:@@%:@ @%:@@%:@ Report this to support@land.ufrj.br @%:@@%:@ @%:@@%:@ ----------------------------------- @%:@@%:@ _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF @%:@define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done # Checks for typedefs, structures, and compiler characteristics. { echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6; } if test "${ac_cv_c_const+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { /* FIXME: Include the comments suggested by Paul. */ #ifndef __cplusplus /* Ultrix mips cc rejects this. */ typedef int charset[2]; const charset cs; /* SunOS 4.1.1 cc rejects this. */ char const *const *pcpcc; char **ppc; /* NEC SVR4.0.2 mips cc rejects this. */ struct point {int x, y;}; static struct point const zero = {0,0}; /* AIX XL C 1.02.0.0 rejects this. It does not let you subtract one const X* pointer from another in an arm of an if-expression whose if-part is not a constant expression */ const char *g = "string"; pcpcc = &g + (g ? g-g : 0); /* HPUX 7.0 cc rejects these. */ ++pcpcc; ppc = (char**) pcpcc; pcpcc = (char const *const *) ppc; { /* SCO 3.2v4 cc rejects this. */ char *t; char const *s = 0 ? (char *) 0 : (char const *) 0; *t++ = 0; if (s) return 0; } { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ int x[] = {25, 17}; const int *foo = &x[0]; ++foo; } { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ typedef const int *iptr; iptr p = 0; ++p; } { /* AIX XL C 1.02.0.0 rejects this saying "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ struct s { int j; const int *ap[3]; }; struct s *b; b->j = 5; } { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ const int foo = 10; if (!foo) return 0; } return !cs[0] && !zero.x; #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_c_const=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_c_const=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5 echo "${ECHO_T}$ac_cv_c_const" >&6; } if test $ac_cv_c_const = no; then cat >>confdefs.h <<\_ACEOF @%:@define const _ACEOF fi { echo "$as_me:$LINENO: checking for inline" >&5 echo $ECHO_N "checking for inline... $ECHO_C" >&6; } if test "${ac_cv_c_inline+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_c_inline=no for ac_kw in inline __inline__ __inline; do cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #ifndef __cplusplus typedef int foo_t; static $ac_kw foo_t static_foo () {return 0; } $ac_kw foo_t foo () {return 0; } #endif _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_c_inline=$ac_kw else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext test "$ac_cv_c_inline" != no && break done fi { echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5 echo "${ECHO_T}$ac_cv_c_inline" >&6; } case $ac_cv_c_inline in inline | yes) ;; *) case $ac_cv_c_inline in no) ac_val=;; *) ac_val=$ac_cv_c_inline;; esac cat >>confdefs.h <<_ACEOF #ifndef __cplusplus #define inline $ac_val #endif _ACEOF ;; esac { echo "$as_me:$LINENO: checking for size_t" >&5 echo $ECHO_N "checking for size_t... $ECHO_C" >&6; } if test "${ac_cv_type_size_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default typedef size_t ac__type_new_; int main () { if ((ac__type_new_ *) 0) return 0; if (sizeof (ac__type_new_)) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_type_size_t=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_type_size_t=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5 echo "${ECHO_T}$ac_cv_type_size_t" >&6; } if test $ac_cv_type_size_t = yes; then : else cat >>confdefs.h <<_ACEOF @%:@define size_t unsigned int _ACEOF fi { echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5 echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6; } if test "${ac_cv_have_decl_sys_siglist+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { #ifndef sys_siglist (void) sys_siglist; #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_have_decl_sys_siglist=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_have_decl_sys_siglist=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5 echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6; } if test $ac_cv_have_decl_sys_siglist = yes; then cat >>confdefs.h <<_ACEOF @%:@define HAVE_DECL_SYS_SIGLIST 1 _ACEOF else cat >>confdefs.h <<_ACEOF @%:@define HAVE_DECL_SYS_SIGLIST 0 _ACEOF fi { echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6; } if test "${ac_cv_header_time+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #include int main () { if ((struct tm *) 0) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_header_time=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_header_time=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5 echo "${ECHO_T}$ac_cv_header_time" >&6; } if test $ac_cv_header_time = yes; then cat >>confdefs.h <<\_ACEOF @%:@define TIME_WITH_SYS_TIME 1 _ACEOF fi { echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6; } if test "${ac_cv_struct_tm+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include int main () { struct tm tm; int *p = &tm.tm_sec; return !p; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_struct_tm=time.h else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_struct_tm=sys/time.h fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5 echo "${ECHO_T}$ac_cv_struct_tm" >&6; } if test $ac_cv_struct_tm = sys/time.h; then cat >>confdefs.h <<\_ACEOF @%:@define TM_IN_SYS_TIME 1 _ACEOF fi # Checks for library functions. ac_header_dirent=no for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include <$ac_hdr> int main () { if ((DIR *) 0) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then eval "$as_ac_Header=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_Header=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF @%:@define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 _ACEOF ac_header_dirent=$ac_hdr; break fi done # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. if test $ac_header_dirent = dirent.h; then { echo "$as_me:$LINENO: checking for library containing opendir" >&5 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6; } if test "${ac_cv_search_opendir+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_func_search_save_LIBS=$LIBS cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char opendir (); int main () { return opendir (); ; return 0; } _ACEOF for ac_lib in '' dir; do if test -z "$ac_lib"; then ac_res="none required" else ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_search_opendir=$ac_res else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext if test "${ac_cv_search_opendir+set}" = set; then break fi done if test "${ac_cv_search_opendir+set}" = set; then : else ac_cv_search_opendir=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 echo "${ECHO_T}$ac_cv_search_opendir" >&6; } ac_res=$ac_cv_search_opendir if test "$ac_res" != no; then test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi else { echo "$as_me:$LINENO: checking for library containing opendir" >&5 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6; } if test "${ac_cv_search_opendir+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_func_search_save_LIBS=$LIBS cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char opendir (); int main () { return opendir (); ; return 0; } _ACEOF for ac_lib in '' x; do if test -z "$ac_lib"; then ac_res="none required" else ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_search_opendir=$ac_res else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext if test "${ac_cv_search_opendir+set}" = set; then break fi done if test "${ac_cv_search_opendir+set}" = set; then : else ac_cv_search_opendir=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 echo "${ECHO_T}$ac_cv_search_opendir" >&6; } ac_res=$ac_cv_search_opendir if test "$ac_res" != no; then test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi fi { echo "$as_me:$LINENO: checking whether closedir returns void" >&5 echo $ECHO_N "checking whether closedir returns void... $ECHO_C" >&6; } if test "${ac_cv_func_closedir_void+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_closedir_void=yes else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header_dirent> #ifndef __cplusplus int closedir (); #endif int main () { return closedir (opendir (".")) != 0; ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_closedir_void=no else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_closedir_void=yes fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_closedir_void" >&5 echo "${ECHO_T}$ac_cv_func_closedir_void" >&6; } if test $ac_cv_func_closedir_void = yes; then cat >>confdefs.h <<\_ACEOF @%:@define CLOSEDIR_VOID 1 _ACEOF fi { echo "$as_me:$LINENO: checking for pid_t" >&5 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6; } if test "${ac_cv_type_pid_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default typedef pid_t ac__type_new_; int main () { if ((ac__type_new_ *) 0) return 0; if (sizeof (ac__type_new_)) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_type_pid_t=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_type_pid_t=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5 echo "${ECHO_T}$ac_cv_type_pid_t" >&6; } if test $ac_cv_type_pid_t = yes; then : else cat >>confdefs.h <<_ACEOF @%:@define pid_t int _ACEOF fi for ac_header in vfork.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default @%:@include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX @%:@@%:@ ----------------------------------- @%:@@%:@ @%:@@%:@ Report this to support@land.ufrj.br @%:@@%:@ @%:@@%:@ ----------------------------------- @%:@@%:@ _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF @%:@define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_func in fork vfork do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Define $ac_func to an innocuous variant, in case declares $ac_func. For example, HP-UX 11i declares gettimeofday. */ #define $ac_func innocuous_$ac_func /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef $ac_func /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $ac_func (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$ac_func || defined __stub___$ac_func choke me #endif int main () { return $ac_func (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then eval "$as_ac_var=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_var=no" fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_var'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <<_ACEOF @%:@define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done if test "x$ac_cv_func_fork" = xyes; then { echo "$as_me:$LINENO: checking for working fork" >&5 echo $ECHO_N "checking for working fork... $ECHO_C" >&6; } if test "${ac_cv_func_fork_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_fork_works=cross else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { /* By Ruediger Kuhlmann. */ return fork () < 0; ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_fork_works=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_fork_works=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5 echo "${ECHO_T}$ac_cv_func_fork_works" >&6; } else ac_cv_func_fork_works=$ac_cv_func_fork fi if test "x$ac_cv_func_fork_works" = xcross; then case $host in *-*-amigaos* | *-*-msdosdjgpp*) # Override, as these systems have only a dummy fork() stub ac_cv_func_fork_works=no ;; *) ac_cv_func_fork_works=yes ;; esac { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} fi ac_cv_func_vfork_works=$ac_cv_func_vfork if test "x$ac_cv_func_vfork" = xyes; then { echo "$as_me:$LINENO: checking for working vfork" >&5 echo $ECHO_N "checking for working vfork... $ECHO_C" >&6; } if test "${ac_cv_func_vfork_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_vfork_works=cross else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Thanks to Paul Eggert for this test. */ $ac_includes_default #include #ifdef HAVE_VFORK_H # include #endif /* On some sparc systems, changes by the child to local and incoming argument registers are propagated back to the parent. The compiler is told about this with #include , but some compilers (e.g. gcc -O) don't grok . Test for this by using a static variable whose address is put into a register that is clobbered by the vfork. */ static void #ifdef __cplusplus sparc_address_test (int arg) # else sparc_address_test (arg) int arg; #endif { static pid_t child; if (!child) { child = vfork (); if (child < 0) { perror ("vfork"); _exit(2); } if (!child) { arg = getpid(); write(-1, "", 0); _exit (arg); } } } int main () { pid_t parent = getpid (); pid_t child; sparc_address_test (0); child = vfork (); if (child == 0) { /* Here is another test for sparc vfork register problems. This test uses lots of local variables, at least as many local variables as main has allocated so far including compiler temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should reuse the register of parent for one of the local variables, since it will think that parent can't possibly be used any more in this routine. Assigning to the local variable will thus munge parent in the parent process. */ pid_t p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); /* Convince the compiler that p..p7 are live; otherwise, it might use the same hardware register for all 8 local variables. */ if (p != p1 || p != p2 || p != p3 || p != p4 || p != p5 || p != p6 || p != p7) _exit(1); /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent from child file descriptors. If the child closes a descriptor before it execs or exits, this munges the parent's descriptor as well. Test for this by closing stdout in the child. */ _exit(close(fileno(stdout)) != 0); } else { int status; struct stat st; while (wait(&status) != child) ; return ( /* Was there some problem with vforking? */ child < 0 /* Did the child fail? (This shouldn't happen.) */ || status /* Did the vfork/compiler bug occur? */ || parent != getpid() /* Did the file descriptor bug occur? */ || fstat(fileno(stdout), &st) != 0 ); } } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_vfork_works=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_vfork_works=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5 echo "${ECHO_T}$ac_cv_func_vfork_works" >&6; } fi; if test "x$ac_cv_func_fork_works" = xcross; then ac_cv_func_vfork_works=$ac_cv_func_vfork { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} fi if test "x$ac_cv_func_vfork_works" = xyes; then cat >>confdefs.h <<\_ACEOF @%:@define HAVE_WORKING_VFORK 1 _ACEOF else cat >>confdefs.h <<\_ACEOF @%:@define vfork fork _ACEOF fi if test "x$ac_cv_func_fork_works" = xyes; then cat >>confdefs.h <<\_ACEOF @%:@define HAVE_WORKING_FORK 1 _ACEOF fi for ac_header in stdlib.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default @%:@include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX @%:@@%:@ ----------------------------------- @%:@@%:@ @%:@@%:@ Report this to support@land.ufrj.br @%:@@%:@ @%:@@%:@ ----------------------------------- @%:@@%:@ _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF @%:@define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done { echo "$as_me:$LINENO: checking for GNU libc compatible malloc" >&5 echo $ECHO_N "checking for GNU libc compatible malloc... $ECHO_C" >&6; } if test "${ac_cv_func_malloc_0_nonnull+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_malloc_0_nonnull=no else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #if defined STDC_HEADERS || defined HAVE_STDLIB_H # include #else char *malloc (); #endif int main () { return ! malloc (0); ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_malloc_0_nonnull=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_malloc_0_nonnull=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_malloc_0_nonnull" >&5 echo "${ECHO_T}$ac_cv_func_malloc_0_nonnull" >&6; } if test $ac_cv_func_malloc_0_nonnull = yes; then cat >>confdefs.h <<\_ACEOF @%:@define HAVE_MALLOC 1 _ACEOF else cat >>confdefs.h <<\_ACEOF @%:@define HAVE_MALLOC 0 _ACEOF case " $LIB@&t@OBJS " in *" malloc.$ac_objext "* ) ;; *) LIB@&t@OBJS="$LIB@&t@OBJS malloc.$ac_objext" ;; esac cat >>confdefs.h <<\_ACEOF @%:@define malloc rpl_malloc _ACEOF fi for ac_header in stdlib.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default @%:@include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX @%:@@%:@ ----------------------------------- @%:@@%:@ @%:@@%:@ Report this to support@land.ufrj.br @%:@@%:@ @%:@@%:@ ----------------------------------- @%:@@%:@ _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF @%:@define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done { echo "$as_me:$LINENO: checking for GNU libc compatible realloc" >&5 echo $ECHO_N "checking for GNU libc compatible realloc... $ECHO_C" >&6; } if test "${ac_cv_func_realloc_0_nonnull+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_realloc_0_nonnull=no else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #if defined STDC_HEADERS || defined HAVE_STDLIB_H # include #else char *realloc (); #endif int main () { return ! realloc (0, 0); ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_realloc_0_nonnull=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_realloc_0_nonnull=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_realloc_0_nonnull" >&5 echo "${ECHO_T}$ac_cv_func_realloc_0_nonnull" >&6; } if test $ac_cv_func_realloc_0_nonnull = yes; then cat >>confdefs.h <<\_ACEOF @%:@define HAVE_REALLOC 1 _ACEOF else cat >>confdefs.h <<\_ACEOF @%:@define HAVE_REALLOC 0 _ACEOF case " $LIB@&t@OBJS " in *" realloc.$ac_objext "* ) ;; *) LIB@&t@OBJS="$LIB@&t@OBJS realloc.$ac_objext" ;; esac cat >>confdefs.h <<\_ACEOF @%:@define realloc rpl_realloc _ACEOF fi for ac_header in sys/select.h sys/socket.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default @%:@include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ @%:@include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX @%:@@%:@ ----------------------------------- @%:@@%:@ @%:@@%:@ Report this to support@land.ufrj.br @%:@@%:@ @%:@@%:@ ----------------------------------- @%:@@%:@ _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF @%:@define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done { echo "$as_me:$LINENO: checking types of arguments for select" >&5 echo $ECHO_N "checking types of arguments for select... $ECHO_C" >&6; } if test "${ac_cv_func_select_args+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else for ac_arg234 in 'fd_set *' 'int *' 'void *'; do for ac_arg1 in 'int' 'size_t' 'unsigned long int' 'unsigned int'; do for ac_arg5 in 'struct timeval *' 'const struct timeval *'; do cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #ifdef HAVE_SYS_SELECT_H # include #endif #ifdef HAVE_SYS_SOCKET_H # include #endif int main () { extern int select ($ac_arg1, $ac_arg234, $ac_arg234, $ac_arg234, $ac_arg5); ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_func_select_args="$ac_arg1,$ac_arg234,$ac_arg5"; break 3 else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext done done done # Provide a safe default value. : ${ac_cv_func_select_args='int,int *,struct timeval *'} fi { echo "$as_me:$LINENO: result: $ac_cv_func_select_args" >&5 echo "${ECHO_T}$ac_cv_func_select_args" >&6; } ac_save_IFS=$IFS; IFS=',' set dummy `echo "$ac_cv_func_select_args" | sed 's/\*/\*/g'` IFS=$ac_save_IFS shift cat >>confdefs.h <<_ACEOF @%:@define SELECT_TYPE_ARG1 $1 _ACEOF cat >>confdefs.h <<_ACEOF @%:@define SELECT_TYPE_ARG234 ($2) _ACEOF cat >>confdefs.h <<_ACEOF @%:@define SELECT_TYPE_ARG5 ($3) _ACEOF rm -f conftest* { echo "$as_me:$LINENO: checking for function prototypes" >&5 echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6; } if test "$ac_cv_prog_cc_c89" != no; then { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } cat >>confdefs.h <<\_ACEOF @%:@define PROTOTYPES 1 _ACEOF cat >>confdefs.h <<\_ACEOF @%:@define __PROTOTYPES 1 _ACEOF else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi { echo "$as_me:$LINENO: checking whether setvbuf arguments are reversed" >&5 echo $ECHO_N "checking whether setvbuf arguments are reversed... $ECHO_C" >&6; } if test "${ac_cv_func_setvbuf_reversed+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_func_setvbuf_reversed=no cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include # ifdef PROTOTYPES int (setvbuf) (FILE *, int, char *, size_t); # endif int main () { char buf; return setvbuf (stdout, _IOLBF, &buf, 1); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include # ifdef PROTOTYPES int (setvbuf) (FILE *, int, char *, size_t); # endif int main () { char buf; return setvbuf (stdout, &buf, _IOLBF, 1); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then # It compiles and links either way, so it must not be declared # with a prototype and most likely this is a K&R C compiler. # Try running it. if test "$cross_compiling" = yes; then : # Assume setvbuf is not reversed when cross-compiling. else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { /* This call has the arguments reversed. A reversed system may check and see that the address of buf is not _IOLBF, _IONBF, or _IOFBF, and return nonzero. */ char buf; if (setvbuf (stdout, _IOLBF, &buf, 1) != 0) return 1; putchar ('\r'); return 0; /* Non-reversed systems SEGV here. */ ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_setvbuf_reversed=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi ac_cv_func_setvbuf_reversed=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_func_setvbuf_reversed" >&5 echo "${ECHO_T}$ac_cv_func_setvbuf_reversed" >&6; } if test $ac_cv_func_setvbuf_reversed = yes; then cat >>confdefs.h <<\_ACEOF @%:@define SETVBUF_REVERSED 1 _ACEOF fi { echo "$as_me:$LINENO: checking return type of signal handlers" >&5 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6; } if test "${ac_cv_type_signal+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include int main () { return *(signal (0, 0)) (0) == 1; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_type_signal=int else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_type_signal=void fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5 echo "${ECHO_T}$ac_cv_type_signal" >&6; } cat >>confdefs.h <<_ACEOF @%:@define RETSIGTYPE $ac_cv_type_signal _ACEOF for ac_func in alarm bzero gethostbyname gethostname gettimeofday inet_ntoa memset pow putenv select setlocale socket strchr strdup strerror strstr do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Define $ac_func to an innocuous variant, in case declares $ac_func. For example, HP-UX 11i declares gettimeofday. */ #define $ac_func innocuous_$ac_func /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef $ac_func /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $ac_func (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$ac_func || defined __stub___$ac_func choke me #endif int main () { return $ac_func (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then eval "$as_ac_var=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_var=no" fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_var'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <<_ACEOF @%:@define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done ac_config_files="$ac_config_files Makefile src/Makefile mcastproxy/Makefile rmchat/Makefile" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure # scripts and configure runs, see configure's option --config-cache. # It is not useful on other systems. If it contains results you don't # want to keep, you may remove or edit it. # # config.status only pays attention to the cache file if you give it # the --recheck option to rerun configure. # # `ac_cv_env_foo' variables (set or unset) will be overridden when # loading this file, other *unset* `ac_cv_foo' will be assigned the # following values. _ACEOF # The following way of writing the cache mishandles newlines in values, # but we know of no workaround that is simple, portable, and efficient. # So, we kill variables containing newlines. # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. ( for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( *) $as_unset $ac_var ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) # `set' does not quote correctly, so add quotes (double-quote # substitution turns \\\\ into \\, and sed turns \\ into \). sed -n \ "s/'/'\\\\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" ;; #( *) # `set' quotes correctly as required by POSIX, so do not add quotes. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) | sed ' /^ac_cv_env_/b end t clear :clear s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ t end s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then test "x$cache_file" != "x/dev/null" && { echo "$as_me:$LINENO: updating cache $cache_file" >&5 echo "$as_me: updating cache $cache_file" >&6;} cat confcache >$cache_file else { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5 echo "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi rm -f confcache test "x$prefix" = xNONE && prefix=$ac_default_prefix # Let make expand exec_prefix. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' DEFS=-DHAVE_CONFIG_H ac_libobjs= ac_ltlibobjs= for ac_i in : $LIB@&t@OBJS; do test "x$ac_i" = x: && continue # 1. Remove the extension, and $U if already installed. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' ac_i=`echo "$ac_i" | sed "$ac_script"` # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR # will be set to the directory where LIBOBJS objects are built. ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext" ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo' done LIB@&t@OBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCXX\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"am__fastdepCXX\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi : ${CONFIG_STATUS=./config.status} ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5 echo "$as_me: creating $CONFIG_STATUS" >&6;} cat >$CONFIG_STATUS <<_ACEOF #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. # Compiler output produced by configure, useful for debugging # configure, is in config.log if it exists. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi # PATH needs CR # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset else as_unset=false fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) as_nl=' ' IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. case $0 in *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 { (exit 1); exit 1; } fi # Work around bugs in pre-3.0 UWIN ksh. for as_var in ENV MAIL MAILPATH do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. for as_var in \ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ LC_TELEPHONE LC_TIME do if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then eval $as_var=C; export $as_var else ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var fi done # Required to use basename. if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi # Name of the executable. as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # CDPATH. $as_unset CDPATH as_lineno_1=$LINENO as_lineno_2=$LINENO test "x$as_lineno_1" != "x$as_lineno_2" && test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || { # Create $as_me.lineno as a copy of $as_myself, but with $LINENO # uniformly replaced by the line number. The first 'sed' inserts a # line-number line after each line using $LINENO; the second 'sed' # does the real work. The second script uses 'N' to pair each # line-number line with the line containing $LINENO, and appends # trailing '-' during substitution so that $LINENO is not a special # case at line end. # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the # scripts with optimization help from Paolo Bonzini. Blame Lee # E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 { (exit 1); exit 1; }; } # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in -n*) case `echo 'x\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. *) ECHO_C='\c';; esac;; *) ECHO_N='-n';; esac if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir fi echo >conf$$.file if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p=: else test -d ./-p && rmdir ./-p as_mkdir_p=false fi if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 # Save the log message, to keep $[0] and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by rmcast $as_me 2.0.0, which was generated by GNU Autoconf 2.61. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ on `(hostname || uname -n) 2>/dev/null | sed 1q` " _ACEOF cat >>$CONFIG_STATUS <<_ACEOF # Files that config.status was made for. config_files="$ac_config_files" config_headers="$ac_config_headers" config_commands="$ac_config_commands" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF ac_cs_usage="\ \`$as_me' instantiates files from templates according to the current configuration. Usage: $0 [OPTIONS] [FILE]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit -q, --quiet do not print progress messages -d, --debug don't remove temporary files --recheck update $as_me by reconfiguring in the same conditions --file=FILE[:TEMPLATE] instantiate the configuration file FILE --header=FILE[:TEMPLATE] instantiate the configuration header FILE Configuration files: $config_files Configuration headers: $config_headers Configuration commands: $config_commands Report bugs to ." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF ac_cs_version="\\ rmcast config.status 2.0.0 configured by $0, generated by GNU Autoconf 2.61, with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" Copyright (C) 2006 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='$ac_pwd' srcdir='$srcdir' INSTALL='$INSTALL' _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # If no file are specified by the user, then we need to provide default # value. By we need to know if files were specified by the user. ac_need_defaults=: while test $# != 0 do case $1 in --*=*) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` ac_shift=: ;; *) ac_option=$1 ac_optarg=$2 ac_shift=shift ;; esac case $ac_option in # Handling of the options. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) echo "$ac_cs_version"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift CONFIG_FILES="$CONFIG_FILES $ac_optarg" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg" ac_need_defaults=false;; --he | --h) # Conflict between --help and --header { echo "$as_me: error: ambiguous option: $1 Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; };; --help | --hel | -h ) echo "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) { echo "$as_me: error: unrecognized option: $1 Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; } ;; *) ac_config_targets="$ac_config_targets $1" ac_need_defaults=false ;; esac shift done ac_configure_extra_args= if $ac_cs_silent; then exec 6>/dev/null ac_configure_extra_args="$ac_configure_extra_args --silent" fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF if \$ac_cs_recheck; then echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6 CONFIG_SHELL=$SHELL export CONFIG_SHELL exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion fi _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../@%:@@%:@ /;s/...$/ @%:@@%:@/;p;x;p;x' <<_ASBOX @%:@@%:@ Running $as_me. @%:@@%:@ _ASBOX echo "$ac_log" } >&5 _ACEOF cat >>$CONFIG_STATUS <<_ACEOF # # INIT-COMMANDS # AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # Handling of arguments. for ac_config_target in $ac_config_targets do case $ac_config_target in "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; "mcastproxy/Makefile") CONFIG_FILES="$CONFIG_FILES mcastproxy/Makefile" ;; "rmchat/Makefile") CONFIG_FILES="$CONFIG_FILES rmchat/Makefile" ;; *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 echo "$as_me: error: invalid argument: $ac_config_target" >&2;} { (exit 1); exit 1; }; };; esac done # If the user did not use the arguments to specify the items to instantiate, # then the envvar interface is used. Set only those that are not. # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason against having it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: # after its creation but before its name has been assigned to `$tmp'. $debug || { tmp= trap 'exit_status=$? { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status ' 0 trap '{ (exit 1); exit 1; }' 1 2 13 15 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || { echo "$me: cannot create a temporary directory in ." >&2 { (exit 1); exit 1; } } # # Set up the sed scripts for CONFIG_FILES section. # # No need to generate the scripts if there are no CONFIG_FILES. # This happens for instance when ./config.status config.h if test -n "$CONFIG_FILES"; then _ACEOF ac_delim='%!_!# ' for ac_last_try in false false false false false :; do cat >conf$$subs.sed <<_ACEOF SHELL!$SHELL$ac_delim PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim PACKAGE_NAME!$PACKAGE_NAME$ac_delim PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim PACKAGE_STRING!$PACKAGE_STRING$ac_delim PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim exec_prefix!$exec_prefix$ac_delim prefix!$prefix$ac_delim program_transform_name!$program_transform_name$ac_delim bindir!$bindir$ac_delim sbindir!$sbindir$ac_delim libexecdir!$libexecdir$ac_delim datarootdir!$datarootdir$ac_delim datadir!$datadir$ac_delim sysconfdir!$sysconfdir$ac_delim sharedstatedir!$sharedstatedir$ac_delim localstatedir!$localstatedir$ac_delim includedir!$includedir$ac_delim oldincludedir!$oldincludedir$ac_delim docdir!$docdir$ac_delim infodir!$infodir$ac_delim htmldir!$htmldir$ac_delim dvidir!$dvidir$ac_delim pdfdir!$pdfdir$ac_delim psdir!$psdir$ac_delim libdir!$libdir$ac_delim localedir!$localedir$ac_delim mandir!$mandir$ac_delim DEFS!$DEFS$ac_delim ECHO_C!$ECHO_C$ac_delim ECHO_N!$ECHO_N$ac_delim ECHO_T!$ECHO_T$ac_delim LIBS!$LIBS$ac_delim build_alias!$build_alias$ac_delim host_alias!$host_alias$ac_delim target_alias!$target_alias$ac_delim INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim INSTALL_DATA!$INSTALL_DATA$ac_delim CYGPATH_W!$CYGPATH_W$ac_delim PACKAGE!$PACKAGE$ac_delim VERSION!$VERSION$ac_delim ACLOCAL!$ACLOCAL$ac_delim AUTOCONF!$AUTOCONF$ac_delim AUTOMAKE!$AUTOMAKE$ac_delim AUTOHEADER!$AUTOHEADER$ac_delim MAKEINFO!$MAKEINFO$ac_delim install_sh!$install_sh$ac_delim STRIP!$STRIP$ac_delim INSTALL_STRIP_PROGRAM!$INSTALL_STRIP_PROGRAM$ac_delim mkdir_p!$mkdir_p$ac_delim AWK!$AWK$ac_delim SET_MAKE!$SET_MAKE$ac_delim am__leading_dot!$am__leading_dot$ac_delim AMTAR!$AMTAR$ac_delim am__tar!$am__tar$ac_delim am__untar!$am__untar$ac_delim CC!$CC$ac_delim CFLAGS!$CFLAGS$ac_delim LDFLAGS!$LDFLAGS$ac_delim CPPFLAGS!$CPPFLAGS$ac_delim ac_ct_CC!$ac_ct_CC$ac_delim EXEEXT!$EXEEXT$ac_delim OBJEXT!$OBJEXT$ac_delim DEPDIR!$DEPDIR$ac_delim am__include!$am__include$ac_delim am__quote!$am__quote$ac_delim AMDEP_TRUE!$AMDEP_TRUE$ac_delim AMDEP_FALSE!$AMDEP_FALSE$ac_delim AMDEPBACKSLASH!$AMDEPBACKSLASH$ac_delim CCDEPMODE!$CCDEPMODE$ac_delim am__fastdepCC_TRUE!$am__fastdepCC_TRUE$ac_delim am__fastdepCC_FALSE!$am__fastdepCC_FALSE$ac_delim build!$build$ac_delim build_cpu!$build_cpu$ac_delim build_vendor!$build_vendor$ac_delim build_os!$build_os$ac_delim host!$host$ac_delim host_cpu!$host_cpu$ac_delim host_vendor!$host_vendor$ac_delim host_os!$host_os$ac_delim SED!$SED$ac_delim GREP!$GREP$ac_delim EGREP!$EGREP$ac_delim LN_S!$LN_S$ac_delim ECHO!$ECHO$ac_delim AR!$AR$ac_delim RANLIB!$RANLIB$ac_delim DSYMUTIL!$DSYMUTIL$ac_delim NMEDIT!$NMEDIT$ac_delim CPP!$CPP$ac_delim CXX!$CXX$ac_delim CXXFLAGS!$CXXFLAGS$ac_delim ac_ct_CXX!$ac_ct_CXX$ac_delim CXXDEPMODE!$CXXDEPMODE$ac_delim am__fastdepCXX_TRUE!$am__fastdepCXX_TRUE$ac_delim _ACEOF if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then break elif $ac_last_try; then { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} { (exit 1); exit 1; }; } else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed` if test -n "$ac_eof"; then ac_eof=`echo "$ac_eof" | sort -nru | sed 1q` ac_eof=`expr $ac_eof + 1` fi cat >>$CONFIG_STATUS <<_ACEOF cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof /@[a-zA-Z_][a-zA-Z_0-9]*@/!b _ACEOF sed ' s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g s/^/s,@/; s/!/@,|#_!!_#|/ :n t n s/'"$ac_delim"'$/,g/; t s/$/\\/; p N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n ' >>$CONFIG_STATUS >$CONFIG_STATUS <<_ACEOF CEOF$ac_eof _ACEOF ac_delim='%!_!# ' for ac_last_try in false false false false false :; do cat >conf$$subs.sed <<_ACEOF am__fastdepCXX_FALSE!$am__fastdepCXX_FALSE$ac_delim CXXCPP!$CXXCPP$ac_delim F77!$F77$ac_delim FFLAGS!$FFLAGS$ac_delim ac_ct_F77!$ac_ct_F77$ac_delim LIBTOOL!$LIBTOOL$ac_delim LIB@&t@OBJS!$LIB@&t@OBJS$ac_delim LTLIBOBJS!$LTLIBOBJS$ac_delim _ACEOF if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 8; then break elif $ac_last_try; then { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} { (exit 1); exit 1; }; } else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed` if test -n "$ac_eof"; then ac_eof=`echo "$ac_eof" | sort -nru | sed 1q` ac_eof=`expr $ac_eof + 1` fi cat >>$CONFIG_STATUS <<_ACEOF cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof /@[a-zA-Z_][a-zA-Z_0-9]*@/!b end _ACEOF sed ' s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g s/^/s,@/; s/!/@,|#_!!_#|/ :n t n s/'"$ac_delim"'$/,g/; t s/$/\\/; p N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n ' >>$CONFIG_STATUS >$CONFIG_STATUS <<_ACEOF :end s/|#_!!_#|//g CEOF$ac_eof _ACEOF # VPATH may cause trouble with some makes, so we remove $(srcdir), # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and # trailing colons and then remove the whole line if VPATH becomes empty # (actually we leave an empty line to preserve line numbers). if test "x$srcdir" = x.; then ac_vpsub='/^[ ]*VPATH[ ]*=/{ s/:*\$(srcdir):*/:/ s/:*\${srcdir}:*/:/ s/:*@srcdir@:*/:/ s/^\([^=]*=[ ]*\):*/\1/ s/:*$// s/^[^=]*=[ ]*$// }' fi cat >>$CONFIG_STATUS <<\_ACEOF fi # test -n "$CONFIG_FILES" for ac_tag in :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS do case $ac_tag in :[FHLC]) ac_mode=$ac_tag; continue;; esac case $ac_mode$ac_tag in :[FHL]*:*);; :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5 echo "$as_me: error: Invalid tag $ac_tag." >&2;} { (exit 1); exit 1; }; };; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac ac_save_IFS=$IFS IFS=: set x $ac_tag IFS=$ac_save_IFS shift ac_file=$1 shift case $ac_mode in :L) ac_source=$1;; :[FH]) ac_file_inputs= for ac_f do case $ac_f in -) ac_f="$tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, # because $ac_f cannot contain `:'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5 echo "$as_me: error: cannot find input file: $ac_f" >&2;} { (exit 1); exit 1; }; };; esac ac_file_inputs="$ac_file_inputs $ac_f" done # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input="Generated from "`IFS=: echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure." if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { echo "$as_me:$LINENO: creating $ac_file" >&5 echo "$as_me: creating $ac_file" >&6;} fi case $ac_tag in *:-:* | *:-) cat >"$tmp/stdin";; esac ;; esac ac_dir=`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` { as_dir="$ac_dir" case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 echo "$as_me: error: cannot create directory $as_dir" >&2;} { (exit 1); exit 1; }; }; } ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix case $ac_mode in :F) # # CONFIG_FILE # case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= case `sed -n '/datarootdir/ { p q } /@datadir@/p /@docdir@/p /@infodir@/p /@localedir@/p /@mandir@/p ' $ac_file_inputs` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF cat >>$CONFIG_STATUS <<_ACEOF ac_datarootdir_hack=' s&@datadir@&$datadir&g s&@docdir@&$docdir&g s&@infodir@&$infodir&g s&@localedir@&$localedir&g s&@mandir@&$mandir&g s&\\\${datarootdir}&$datarootdir&g' ;; esac _ACEOF # Neutralize VPATH when `$srcdir' = `.'. # Shell code in configure.ac might set extrasub. # FIXME: do we really want to maintain this feature? cat >>$CONFIG_STATUS <<_ACEOF sed "$ac_vpsub $extrasub _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s&@configure_input@&$configure_input&;t t s&@top_builddir@&$ac_top_builddir_sub&;t t s&@srcdir@&$ac_srcdir&;t t s&@abs_srcdir@&$ac_abs_srcdir&;t t s&@top_srcdir@&$ac_top_srcdir&;t t s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t s&@builddir@&$ac_builddir&;t t s&@abs_builddir@&$ac_abs_builddir&;t t s&@abs_top_builddir@&$ac_abs_top_builddir&;t t s&@INSTALL@&$ac_INSTALL&;t t $ac_datarootdir_hack " $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&5 echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&2;} rm -f "$tmp/stdin" case $ac_file in -) cat "$tmp/out"; rm -f "$tmp/out";; *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;; esac ;; :H) # # CONFIG_HEADER # _ACEOF # Transform confdefs.h into a sed script `conftest.defines', that # substitutes the proper values into config.h.in to produce config.h. rm -f conftest.defines conftest.tail # First, append a space to every undef/define line, to ease matching. echo 's/$/ /' >conftest.defines # Then, protect against being on the right side of a sed subst, or in # an unquoted here document, in config.status. If some macros were # called several times there might be several #defines for the same # symbol, which is useless. But do not sort them, since the last # AC_DEFINE must be honored. ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* # These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where # NAME is the cpp macro being defined, VALUE is the value it is being given. # PARAMS is the parameter list in the macro definition--in most cases, it's # just an empty string. ac_dA='s,^\\([ #]*\\)[^ ]*\\([ ]*' ac_dB='\\)[ (].*,\\1define\\2' ac_dC=' ' ac_dD=' ,' uniq confdefs.h | sed -n ' t rset :rset s/^[ ]*#[ ]*define[ ][ ]*// t ok d :ok s/[\\&,]/\\&/g s/^\('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p s/^\('"$ac_word_re"'\)[ ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p ' >>conftest.defines # Remove the space that was appended to ease matching. # Then replace #undef with comments. This is necessary, for # example, in the case of _POSIX_SOURCE, which is predefined and required # on some systems where configure will not decide to define it. # (The regexp can be short, since the line contains either #define or #undef.) echo 's/ $// s,^[ #]*u.*,/* & */,' >>conftest.defines # Break up conftest.defines: ac_max_sed_lines=50 # First sed command is: sed -f defines.sed $ac_file_inputs >"$tmp/out1" # Second one is: sed -f defines.sed "$tmp/out1" >"$tmp/out2" # Third one will be: sed -f defines.sed "$tmp/out2" >"$tmp/out1" # et cetera. ac_in='$ac_file_inputs' ac_out='"$tmp/out1"' ac_nxt='"$tmp/out2"' while : do # Write a here document: cat >>$CONFIG_STATUS <<_ACEOF # First, check the format of the line: cat >"\$tmp/defines.sed" <<\\CEOF /^[ ]*#[ ]*undef[ ][ ]*$ac_word_re[ ]*\$/b def /^[ ]*#[ ]*define[ ][ ]*$ac_word_re[( ]/b def b :def _ACEOF sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS echo 'CEOF sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail grep . conftest.tail >/dev/null || break rm -f conftest.defines mv conftest.tail conftest.defines done rm -f conftest.defines conftest.tail echo "ac_result=$ac_in" >>$CONFIG_STATUS cat >>$CONFIG_STATUS <<\_ACEOF if test x"$ac_file" != x-; then echo "/* $configure_input */" >"$tmp/config.h" cat "$ac_result" >>"$tmp/config.h" if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then { echo "$as_me:$LINENO: $ac_file is unchanged" >&5 echo "$as_me: $ac_file is unchanged" >&6;} else rm -f $ac_file mv "$tmp/config.h" $ac_file fi else echo "/* $configure_input */" cat "$ac_result" fi rm -f "$tmp/out12" # Compute $ac_file's index in $config_headers. _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $ac_file | $ac_file:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $ac_file" >`$as_dirname -- $ac_file || $as_expr X$ac_file : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X$ac_file : 'X\(//\)[^/]' \| \ X$ac_file : 'X\(//\)$' \| \ X$ac_file : 'X\(/\)' \| . 2>/dev/null || echo X$ac_file | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'`/stamp-h$_am_stamp_count ;; :C) { echo "$as_me:$LINENO: executing $ac_file commands" >&5 echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "depfiles":C) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # So let's grep whole file. if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then dirpart=`$as_dirname -- "$mf" || $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$mf" : 'X\(//\)[^/]' \| \ X"$mf" : 'X\(//\)$' \| \ X"$mf" : 'X\(/\)' \| . 2>/dev/null || echo X"$mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`$as_dirname -- "$file" || $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$file" : 'X\(//\)[^/]' \| \ X"$file" : 'X\(//\)$' \| \ X"$file" : 'X\(/\)' \| . 2>/dev/null || echo X"$file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` { as_dir=$dirpart/$fdir case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 echo "$as_me: error: cannot create directory $as_dir" >&2;} { (exit 1); exit 1; }; }; } # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done ;; esac done # for ac_tag { (exit 0); exit 0; } _ACEOF chmod +x $CONFIG_STATUS ac_clean_files=$ac_clean_files_save # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || { (exit 1); exit 1; } fi tgif-QPL-4.2.5/rmcast/autom4te.cache/traces.00000644000076400007640000013450211566506146020451 0ustar williamwilliamm4trace:configure.in:5: -1- AC_INIT([rmcast], [2.0.0], [support@land.ufrj.br]) m4trace:configure.in:5: -1- m4_pattern_forbid([^_?A[CHUM]_]) m4trace:configure.in:5: -1- m4_pattern_forbid([_AC_]) m4trace:configure.in:5: -1- m4_pattern_forbid([^LIBOBJS$], [do not use LIBOBJS directly, use AC_LIBOBJ (see section `AC_LIBOBJ vs LIBOBJS']) m4trace:configure.in:5: -1- m4_pattern_allow([^AS_FLAGS$]) m4trace:configure.in:5: -1- m4_pattern_forbid([^_?m4_]) m4trace:configure.in:5: -1- m4_pattern_forbid([^dnl$]) m4trace:configure.in:5: -1- m4_pattern_forbid([^_?AS_]) m4trace:configure.in:5: -1- AC_SUBST([SHELL], [${CONFIG_SHELL-/bin/sh}]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([SHELL]) m4trace:configure.in:5: -1- m4_pattern_allow([^SHELL$]) m4trace:configure.in:5: -1- AC_SUBST([PATH_SEPARATOR]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([PATH_SEPARATOR]) m4trace:configure.in:5: -1- m4_pattern_allow([^PATH_SEPARATOR$]) m4trace:configure.in:5: -1- AC_SUBST([PACKAGE_NAME], [m4_ifdef([AC_PACKAGE_NAME], ['AC_PACKAGE_NAME'])]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([PACKAGE_NAME]) m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_NAME$]) m4trace:configure.in:5: -1- AC_SUBST([PACKAGE_TARNAME], [m4_ifdef([AC_PACKAGE_TARNAME], ['AC_PACKAGE_TARNAME'])]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([PACKAGE_TARNAME]) m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_TARNAME$]) m4trace:configure.in:5: -1- AC_SUBST([PACKAGE_VERSION], [m4_ifdef([AC_PACKAGE_VERSION], ['AC_PACKAGE_VERSION'])]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([PACKAGE_VERSION]) m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_VERSION$]) m4trace:configure.in:5: -1- AC_SUBST([PACKAGE_STRING], [m4_ifdef([AC_PACKAGE_STRING], ['AC_PACKAGE_STRING'])]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([PACKAGE_STRING]) m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_STRING$]) m4trace:configure.in:5: -1- AC_SUBST([PACKAGE_BUGREPORT], [m4_ifdef([AC_PACKAGE_BUGREPORT], ['AC_PACKAGE_BUGREPORT'])]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([PACKAGE_BUGREPORT]) m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_BUGREPORT$]) m4trace:configure.in:5: -1- AC_SUBST([exec_prefix], [NONE]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([exec_prefix]) m4trace:configure.in:5: -1- m4_pattern_allow([^exec_prefix$]) m4trace:configure.in:5: -1- AC_SUBST([prefix], [NONE]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([prefix]) m4trace:configure.in:5: -1- m4_pattern_allow([^prefix$]) m4trace:configure.in:5: -1- AC_SUBST([program_transform_name], [s,x,x,]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([program_transform_name]) m4trace:configure.in:5: -1- m4_pattern_allow([^program_transform_name$]) m4trace:configure.in:5: -1- AC_SUBST([bindir], ['${exec_prefix}/bin']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([bindir]) m4trace:configure.in:5: -1- m4_pattern_allow([^bindir$]) m4trace:configure.in:5: -1- AC_SUBST([sbindir], ['${exec_prefix}/sbin']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([sbindir]) m4trace:configure.in:5: -1- m4_pattern_allow([^sbindir$]) m4trace:configure.in:5: -1- AC_SUBST([libexecdir], ['${exec_prefix}/libexec']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([libexecdir]) m4trace:configure.in:5: -1- m4_pattern_allow([^libexecdir$]) m4trace:configure.in:5: -1- AC_SUBST([datarootdir], ['${prefix}/share']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([datarootdir]) m4trace:configure.in:5: -1- m4_pattern_allow([^datarootdir$]) m4trace:configure.in:5: -1- AC_SUBST([datadir], ['${datarootdir}']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([datadir]) m4trace:configure.in:5: -1- m4_pattern_allow([^datadir$]) m4trace:configure.in:5: -1- AC_SUBST([sysconfdir], ['${prefix}/etc']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([sysconfdir]) m4trace:configure.in:5: -1- m4_pattern_allow([^sysconfdir$]) m4trace:configure.in:5: -1- AC_SUBST([sharedstatedir], ['${prefix}/com']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([sharedstatedir]) m4trace:configure.in:5: -1- m4_pattern_allow([^sharedstatedir$]) m4trace:configure.in:5: -1- AC_SUBST([localstatedir], ['${prefix}/var']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([localstatedir]) m4trace:configure.in:5: -1- m4_pattern_allow([^localstatedir$]) m4trace:configure.in:5: -1- AC_SUBST([includedir], ['${prefix}/include']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([includedir]) m4trace:configure.in:5: -1- m4_pattern_allow([^includedir$]) m4trace:configure.in:5: -1- AC_SUBST([oldincludedir], ['/usr/include']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([oldincludedir]) m4trace:configure.in:5: -1- m4_pattern_allow([^oldincludedir$]) m4trace:configure.in:5: -1- AC_SUBST([docdir], [m4_ifset([AC_PACKAGE_TARNAME], ['${datarootdir}/doc/${PACKAGE_TARNAME}'], ['${datarootdir}/doc/${PACKAGE}'])]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([docdir]) m4trace:configure.in:5: -1- m4_pattern_allow([^docdir$]) m4trace:configure.in:5: -1- AC_SUBST([infodir], ['${datarootdir}/info']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([infodir]) m4trace:configure.in:5: -1- m4_pattern_allow([^infodir$]) m4trace:configure.in:5: -1- AC_SUBST([htmldir], ['${docdir}']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([htmldir]) m4trace:configure.in:5: -1- m4_pattern_allow([^htmldir$]) m4trace:configure.in:5: -1- AC_SUBST([dvidir], ['${docdir}']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([dvidir]) m4trace:configure.in:5: -1- m4_pattern_allow([^dvidir$]) m4trace:configure.in:5: -1- AC_SUBST([pdfdir], ['${docdir}']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([pdfdir]) m4trace:configure.in:5: -1- m4_pattern_allow([^pdfdir$]) m4trace:configure.in:5: -1- AC_SUBST([psdir], ['${docdir}']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([psdir]) m4trace:configure.in:5: -1- m4_pattern_allow([^psdir$]) m4trace:configure.in:5: -1- AC_SUBST([libdir], ['${exec_prefix}/lib']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([libdir]) m4trace:configure.in:5: -1- m4_pattern_allow([^libdir$]) m4trace:configure.in:5: -1- AC_SUBST([localedir], ['${datarootdir}/locale']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([localedir]) m4trace:configure.in:5: -1- m4_pattern_allow([^localedir$]) m4trace:configure.in:5: -1- AC_SUBST([mandir], ['${datarootdir}/man']) m4trace:configure.in:5: -1- AC_SUBST_TRACE([mandir]) m4trace:configure.in:5: -1- m4_pattern_allow([^mandir$]) m4trace:configure.in:5: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_NAME]) m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_NAME$]) m4trace:configure.in:5: -1- AH_OUTPUT([PACKAGE_NAME], [/* Define to the full name of this package. */ #undef PACKAGE_NAME]) m4trace:configure.in:5: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_TARNAME]) m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_TARNAME$]) m4trace:configure.in:5: -1- AH_OUTPUT([PACKAGE_TARNAME], [/* Define to the one symbol short name of this package. */ #undef PACKAGE_TARNAME]) m4trace:configure.in:5: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_VERSION]) m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_VERSION$]) m4trace:configure.in:5: -1- AH_OUTPUT([PACKAGE_VERSION], [/* Define to the version of this package. */ #undef PACKAGE_VERSION]) m4trace:configure.in:5: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_STRING]) m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_STRING$]) m4trace:configure.in:5: -1- AH_OUTPUT([PACKAGE_STRING], [/* Define to the full name and version of this package. */ #undef PACKAGE_STRING]) m4trace:configure.in:5: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE_BUGREPORT]) m4trace:configure.in:5: -1- m4_pattern_allow([^PACKAGE_BUGREPORT$]) m4trace:configure.in:5: -1- AH_OUTPUT([PACKAGE_BUGREPORT], [/* Define to the address where bug reports for this package should be sent. */ #undef PACKAGE_BUGREPORT]) m4trace:configure.in:5: -1- AC_SUBST([DEFS]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([DEFS]) m4trace:configure.in:5: -1- m4_pattern_allow([^DEFS$]) m4trace:configure.in:5: -1- AC_SUBST([ECHO_C]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([ECHO_C]) m4trace:configure.in:5: -1- m4_pattern_allow([^ECHO_C$]) m4trace:configure.in:5: -1- AC_SUBST([ECHO_N]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([ECHO_N]) m4trace:configure.in:5: -1- m4_pattern_allow([^ECHO_N$]) m4trace:configure.in:5: -1- AC_SUBST([ECHO_T]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([ECHO_T]) m4trace:configure.in:5: -1- m4_pattern_allow([^ECHO_T$]) m4trace:configure.in:5: -1- AC_SUBST([LIBS]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([LIBS]) m4trace:configure.in:5: -1- m4_pattern_allow([^LIBS$]) m4trace:configure.in:5: -1- AC_SUBST([build_alias]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([build_alias]) m4trace:configure.in:5: -1- m4_pattern_allow([^build_alias$]) m4trace:configure.in:5: -1- AC_SUBST([host_alias]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([host_alias]) m4trace:configure.in:5: -1- m4_pattern_allow([^host_alias$]) m4trace:configure.in:5: -1- AC_SUBST([target_alias]) m4trace:configure.in:5: -1- AC_SUBST_TRACE([target_alias]) m4trace:configure.in:5: -1- m4_pattern_allow([^target_alias$]) m4trace:configure.in:6: -1- AC_CONFIG_AUX_DIR([config]) m4trace:configure.in:8: -1- _m4_warn([obsolete], [The macro `AM_CONFIG_HEADER' is obsolete. You should run autoupdate.], [aclocal.m4:7005: AM_CONFIG_HEADER is expanded from... configure.in:8: the top level]) m4trace:configure.in:8: -1- AC_CONFIG_HEADERS([config.h]) m4trace:configure.in:9: -1- AM_INIT_AUTOMAKE m4trace:configure.in:9: -1- m4_pattern_allow([^AM_[A-Z]+FLAGS$]) m4trace:configure.in:9: -1- AM_AUTOMAKE_VERSION([1.9.6]) m4trace:configure.in:9: -1- AC_REQUIRE_AUX_FILE([install-sh]) m4trace:configure.in:9: -1- AC_SUBST([INSTALL_PROGRAM]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([INSTALL_PROGRAM]) m4trace:configure.in:9: -1- m4_pattern_allow([^INSTALL_PROGRAM$]) m4trace:configure.in:9: -1- AC_SUBST([INSTALL_SCRIPT]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([INSTALL_SCRIPT]) m4trace:configure.in:9: -1- m4_pattern_allow([^INSTALL_SCRIPT$]) m4trace:configure.in:9: -1- AC_SUBST([INSTALL_DATA]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([INSTALL_DATA]) m4trace:configure.in:9: -1- m4_pattern_allow([^INSTALL_DATA$]) m4trace:configure.in:9: -1- AC_SUBST([CYGPATH_W]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([CYGPATH_W]) m4trace:configure.in:9: -1- m4_pattern_allow([^CYGPATH_W$]) m4trace:configure.in:9: -1- _m4_warn([obsolete], [The macro `AC_FOREACH' is obsolete. You should run autoupdate.], [../../lib/autoconf/general.m4:196: AC_FOREACH is expanded from... aclocal.m4:7330: _AM_SET_OPTIONS is expanded from... aclocal.m4:7032: AM_INIT_AUTOMAKE is expanded from... configure.in:9: the top level]) m4trace:configure.in:9: -1- AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME']) m4trace:configure.in:9: -1- AC_SUBST_TRACE([PACKAGE]) m4trace:configure.in:9: -1- m4_pattern_allow([^PACKAGE$]) m4trace:configure.in:9: -1- AC_SUBST([VERSION], ['AC_PACKAGE_VERSION']) m4trace:configure.in:9: -1- AC_SUBST_TRACE([VERSION]) m4trace:configure.in:9: -1- m4_pattern_allow([^VERSION$]) m4trace:configure.in:9: -1- AC_DEFINE_TRACE_LITERAL([PACKAGE]) m4trace:configure.in:9: -1- m4_pattern_allow([^PACKAGE$]) m4trace:configure.in:9: -1- AH_OUTPUT([PACKAGE], [/* Name of package */ #undef PACKAGE]) m4trace:configure.in:9: -1- AC_DEFINE_TRACE_LITERAL([VERSION]) m4trace:configure.in:9: -1- m4_pattern_allow([^VERSION$]) m4trace:configure.in:9: -1- AH_OUTPUT([VERSION], [/* Version number of package */ #undef VERSION]) m4trace:configure.in:9: -1- AC_SUBST([ACLOCAL]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([ACLOCAL]) m4trace:configure.in:9: -1- m4_pattern_allow([^ACLOCAL$]) m4trace:configure.in:9: -1- AC_SUBST([AUTOCONF]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([AUTOCONF]) m4trace:configure.in:9: -1- m4_pattern_allow([^AUTOCONF$]) m4trace:configure.in:9: -1- AC_SUBST([AUTOMAKE]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([AUTOMAKE]) m4trace:configure.in:9: -1- m4_pattern_allow([^AUTOMAKE$]) m4trace:configure.in:9: -1- AC_SUBST([AUTOHEADER]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([AUTOHEADER]) m4trace:configure.in:9: -1- m4_pattern_allow([^AUTOHEADER$]) m4trace:configure.in:9: -1- AC_SUBST([MAKEINFO]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([MAKEINFO]) m4trace:configure.in:9: -1- m4_pattern_allow([^MAKEINFO$]) m4trace:configure.in:9: -1- AC_SUBST([install_sh]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([install_sh]) m4trace:configure.in:9: -1- m4_pattern_allow([^install_sh$]) m4trace:configure.in:9: -1- AC_SUBST([STRIP]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([STRIP]) m4trace:configure.in:9: -1- m4_pattern_allow([^STRIP$]) m4trace:configure.in:9: -1- AC_SUBST([INSTALL_STRIP_PROGRAM]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([INSTALL_STRIP_PROGRAM]) m4trace:configure.in:9: -1- m4_pattern_allow([^INSTALL_STRIP_PROGRAM$]) m4trace:configure.in:9: -1- AC_SUBST([mkdir_p]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([mkdir_p]) m4trace:configure.in:9: -1- m4_pattern_allow([^mkdir_p$]) m4trace:configure.in:9: -1- AC_SUBST([AWK]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([AWK]) m4trace:configure.in:9: -1- m4_pattern_allow([^AWK$]) m4trace:configure.in:9: -1- AC_SUBST([SET_MAKE]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([SET_MAKE]) m4trace:configure.in:9: -1- m4_pattern_allow([^SET_MAKE$]) m4trace:configure.in:9: -1- AC_SUBST([am__leading_dot]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([am__leading_dot]) m4trace:configure.in:9: -1- m4_pattern_allow([^am__leading_dot$]) m4trace:configure.in:9: -1- AC_SUBST([AMTAR]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([AMTAR]) m4trace:configure.in:9: -1- m4_pattern_allow([^AMTAR$]) m4trace:configure.in:9: -1- AC_SUBST([am__tar]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([am__tar]) m4trace:configure.in:9: -1- m4_pattern_allow([^am__tar$]) m4trace:configure.in:9: -1- AC_SUBST([am__untar]) m4trace:configure.in:9: -1- AC_SUBST_TRACE([am__untar]) m4trace:configure.in:9: -1- m4_pattern_allow([^am__untar$]) m4trace:configure.in:13: -1- AC_SUBST([CC]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([CC]) m4trace:configure.in:13: -1- m4_pattern_allow([^CC$]) m4trace:configure.in:13: -1- AC_SUBST([CFLAGS]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([CFLAGS]) m4trace:configure.in:13: -1- m4_pattern_allow([^CFLAGS$]) m4trace:configure.in:13: -1- AC_SUBST([LDFLAGS]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([LDFLAGS]) m4trace:configure.in:13: -1- m4_pattern_allow([^LDFLAGS$]) m4trace:configure.in:13: -1- AC_SUBST([LIBS]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([LIBS]) m4trace:configure.in:13: -1- m4_pattern_allow([^LIBS$]) m4trace:configure.in:13: -1- AC_SUBST([CPPFLAGS]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([CPPFLAGS]) m4trace:configure.in:13: -1- m4_pattern_allow([^CPPFLAGS$]) m4trace:configure.in:13: -1- AC_SUBST([CC]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([CC]) m4trace:configure.in:13: -1- m4_pattern_allow([^CC$]) m4trace:configure.in:13: -1- AC_SUBST([CC]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([CC]) m4trace:configure.in:13: -1- m4_pattern_allow([^CC$]) m4trace:configure.in:13: -1- AC_SUBST([CC]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([CC]) m4trace:configure.in:13: -1- m4_pattern_allow([^CC$]) m4trace:configure.in:13: -1- AC_SUBST([CC]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([CC]) m4trace:configure.in:13: -1- m4_pattern_allow([^CC$]) m4trace:configure.in:13: -1- AC_SUBST([ac_ct_CC]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([ac_ct_CC]) m4trace:configure.in:13: -1- m4_pattern_allow([^ac_ct_CC$]) m4trace:configure.in:13: -1- AC_SUBST([EXEEXT], [$ac_cv_exeext]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([EXEEXT]) m4trace:configure.in:13: -1- m4_pattern_allow([^EXEEXT$]) m4trace:configure.in:13: -1- AC_SUBST([OBJEXT], [$ac_cv_objext]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([OBJEXT]) m4trace:configure.in:13: -1- m4_pattern_allow([^OBJEXT$]) m4trace:configure.in:13: -1- AC_SUBST([DEPDIR], ["${am__leading_dot}deps"]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([DEPDIR]) m4trace:configure.in:13: -1- m4_pattern_allow([^DEPDIR$]) m4trace:configure.in:13: -1- AC_SUBST([am__include]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([am__include]) m4trace:configure.in:13: -1- m4_pattern_allow([^am__include$]) m4trace:configure.in:13: -1- AC_SUBST([am__quote]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([am__quote]) m4trace:configure.in:13: -1- m4_pattern_allow([^am__quote$]) m4trace:configure.in:13: -1- AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) m4trace:configure.in:13: -1- AC_SUBST([AMDEP_TRUE]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([AMDEP_TRUE]) m4trace:configure.in:13: -1- m4_pattern_allow([^AMDEP_TRUE$]) m4trace:configure.in:13: -1- AC_SUBST([AMDEP_FALSE]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([AMDEP_FALSE]) m4trace:configure.in:13: -1- m4_pattern_allow([^AMDEP_FALSE$]) m4trace:configure.in:13: -1- AC_SUBST([AMDEPBACKSLASH]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([AMDEPBACKSLASH]) m4trace:configure.in:13: -1- m4_pattern_allow([^AMDEPBACKSLASH$]) m4trace:configure.in:13: -1- AC_SUBST([CCDEPMODE], [depmode=$am_cv_CC_dependencies_compiler_type]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([CCDEPMODE]) m4trace:configure.in:13: -1- m4_pattern_allow([^CCDEPMODE$]) m4trace:configure.in:13: -1- AM_CONDITIONAL([am__fastdepCC], [ test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3]) m4trace:configure.in:13: -1- AC_SUBST([am__fastdepCC_TRUE]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([am__fastdepCC_TRUE]) m4trace:configure.in:13: -1- m4_pattern_allow([^am__fastdepCC_TRUE$]) m4trace:configure.in:13: -1- AC_SUBST([am__fastdepCC_FALSE]) m4trace:configure.in:13: -1- AC_SUBST_TRACE([am__fastdepCC_FALSE]) m4trace:configure.in:13: -1- m4_pattern_allow([^am__fastdepCC_FALSE$]) m4trace:configure.in:14: -1- AC_PROG_LIBTOOL m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete. You should run autoupdate.], [../../lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from... ../../lib/autoconf/general.m4:1364: AC_ARG_ENABLE is expanded from... aclocal.m4:2049: AC_ENABLE_SHARED is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete. You should run autoupdate.], [../../lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from... ../../lib/autoconf/general.m4:1364: AC_ARG_ENABLE is expanded from... aclocal.m4:2088: AC_ENABLE_STATIC is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete. You should run autoupdate.], [../../lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from... ../../lib/autoconf/general.m4:1364: AC_ARG_ENABLE is expanded from... aclocal.m4:2127: AC_ENABLE_FAST_INSTALL is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- AC_CANONICAL_HOST m4trace:configure.in:14: -1- AC_CANONICAL_BUILD m4trace:configure.in:14: -1- AC_REQUIRE_AUX_FILE([config.sub]) m4trace:configure.in:14: -1- AC_REQUIRE_AUX_FILE([config.guess]) m4trace:configure.in:14: -1- AC_SUBST([build], [$ac_cv_build]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([build]) m4trace:configure.in:14: -1- m4_pattern_allow([^build$]) m4trace:configure.in:14: -1- AC_SUBST([build_cpu], [$[1]]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([build_cpu]) m4trace:configure.in:14: -1- m4_pattern_allow([^build_cpu$]) m4trace:configure.in:14: -1- AC_SUBST([build_vendor], [$[2]]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([build_vendor]) m4trace:configure.in:14: -1- m4_pattern_allow([^build_vendor$]) m4trace:configure.in:14: -1- AC_SUBST([build_os]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([build_os]) m4trace:configure.in:14: -1- m4_pattern_allow([^build_os$]) m4trace:configure.in:14: -1- AC_SUBST([host], [$ac_cv_host]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([host]) m4trace:configure.in:14: -1- m4_pattern_allow([^host$]) m4trace:configure.in:14: -1- AC_SUBST([host_cpu], [$[1]]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([host_cpu]) m4trace:configure.in:14: -1- m4_pattern_allow([^host_cpu$]) m4trace:configure.in:14: -1- AC_SUBST([host_vendor], [$[2]]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([host_vendor]) m4trace:configure.in:14: -1- m4_pattern_allow([^host_vendor$]) m4trace:configure.in:14: -1- AC_SUBST([host_os]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([host_os]) m4trace:configure.in:14: -1- m4_pattern_allow([^host_os$]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete. You should run autoupdate.], [../../lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from... ../../lib/autoconf/general.m4:1382: AC_ARG_WITH is expanded from... aclocal.m4:2268: AC_PROG_LD is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- AC_SUBST([SED]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([SED]) m4trace:configure.in:14: -1- m4_pattern_allow([^SED$]) m4trace:configure.in:14: -1- AC_SUBST([GREP]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([GREP]) m4trace:configure.in:14: -1- m4_pattern_allow([^GREP$]) m4trace:configure.in:14: -1- AC_SUBST([GREP]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([GREP]) m4trace:configure.in:14: -1- m4_pattern_allow([^GREP$]) m4trace:configure.in:14: -1- AC_SUBST([EGREP]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([EGREP]) m4trace:configure.in:14: -1- m4_pattern_allow([^EGREP$]) m4trace:configure.in:14: -1- AC_SUBST([EGREP]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([EGREP]) m4trace:configure.in:14: -1- m4_pattern_allow([^EGREP$]) m4trace:configure.in:14: -1- AC_SUBST([LN_S], [$as_ln_s]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([LN_S]) m4trace:configure.in:14: -1- m4_pattern_allow([^LN_S$]) m4trace:configure.in:14: -1- AC_SUBST([ECHO]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([ECHO]) m4trace:configure.in:14: -1- m4_pattern_allow([^ECHO$]) m4trace:configure.in:14: -1- AC_SUBST([AR]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([AR]) m4trace:configure.in:14: -1- m4_pattern_allow([^AR$]) m4trace:configure.in:14: -1- AC_SUBST([RANLIB]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([RANLIB]) m4trace:configure.in:14: -1- m4_pattern_allow([^RANLIB$]) m4trace:configure.in:14: -1- AC_SUBST([STRIP]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([STRIP]) m4trace:configure.in:14: -1- m4_pattern_allow([^STRIP$]) m4trace:configure.in:14: -1- AC_SUBST([DSYMUTIL]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([DSYMUTIL]) m4trace:configure.in:14: -1- m4_pattern_allow([^DSYMUTIL$]) m4trace:configure.in:14: -1- AC_SUBST([NMEDIT]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([NMEDIT]) m4trace:configure.in:14: -1- m4_pattern_allow([^NMEDIT$]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete. You should run autoupdate.], [../../lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from... ../../lib/autoconf/general.m4:1364: AC_ARG_ENABLE is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete. You should run autoupdate.], [../../lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from... ../../lib/autoconf/general.m4:1382: AC_ARG_WITH is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_TRY_LINK' is obsolete. You should run autoupdate.], [../../lib/autoconf/general.m4:2414: AC_TRY_LINK is expanded from... ../../lib/m4sugar/m4sh.m4:516: AS_IF is expanded from... ../../lib/autoconf/general.m4:1898: AC_CACHE_VAL is expanded from... ../../lib/autoconf/general.m4:1911: AC_CACHE_CHECK is expanded from... aclocal.m4:557: _LT_AC_LOCK is expanded from... aclocal.m4:1177: AC_LIBTOOL_SYS_HARD_LINK_LOCKS is expanded from... aclocal.m4:2801: _LT_AC_LANG_C_CONFIG is expanded from... aclocal.m4:2800: AC_LIBTOOL_LANG_C_CONFIG is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- AH_OUTPUT([HAVE_DLFCN_H], [/* Define to 1 if you have the header file. */ #undef HAVE_DLFCN_H]) m4trace:configure.in:14: -1- AC_SUBST([CPP]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([CPP]) m4trace:configure.in:14: -1- m4_pattern_allow([^CPP$]) m4trace:configure.in:14: -1- AC_SUBST([CPPFLAGS]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([CPPFLAGS]) m4trace:configure.in:14: -1- m4_pattern_allow([^CPPFLAGS$]) m4trace:configure.in:14: -1- AC_SUBST([CPP]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([CPP]) m4trace:configure.in:14: -1- m4_pattern_allow([^CPP$]) m4trace:configure.in:14: -1- AC_DEFINE_TRACE_LITERAL([STDC_HEADERS]) m4trace:configure.in:14: -1- m4_pattern_allow([^STDC_HEADERS$]) m4trace:configure.in:14: -1- AH_OUTPUT([STDC_HEADERS], [/* Define to 1 if you have the ANSI C header files. */ #undef STDC_HEADERS]) m4trace:configure.in:14: -1- AH_OUTPUT([HAVE_SYS_TYPES_H], [/* Define to 1 if you have the header file. */ #undef HAVE_SYS_TYPES_H]) m4trace:configure.in:14: -1- AH_OUTPUT([HAVE_SYS_STAT_H], [/* Define to 1 if you have the header file. */ #undef HAVE_SYS_STAT_H]) m4trace:configure.in:14: -1- AH_OUTPUT([HAVE_STDLIB_H], [/* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H]) m4trace:configure.in:14: -1- AH_OUTPUT([HAVE_STRING_H], [/* Define to 1 if you have the header file. */ #undef HAVE_STRING_H]) m4trace:configure.in:14: -1- AH_OUTPUT([HAVE_MEMORY_H], [/* Define to 1 if you have the header file. */ #undef HAVE_MEMORY_H]) m4trace:configure.in:14: -1- AH_OUTPUT([HAVE_STRINGS_H], [/* Define to 1 if you have the header file. */ #undef HAVE_STRINGS_H]) m4trace:configure.in:14: -1- AH_OUTPUT([HAVE_INTTYPES_H], [/* Define to 1 if you have the header file. */ #undef HAVE_INTTYPES_H]) m4trace:configure.in:14: -1- AH_OUTPUT([HAVE_STDINT_H], [/* Define to 1 if you have the header file. */ #undef HAVE_STDINT_H]) m4trace:configure.in:14: -1- AH_OUTPUT([HAVE_UNISTD_H], [/* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H]) m4trace:configure.in:14: -1- _LT_AC_TAGCONFIG m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_HELP_STRING' is obsolete. You should run autoupdate.], [../../lib/autoconf/general.m4:209: AC_HELP_STRING is expanded from... ../../lib/autoconf/general.m4:1382: AC_ARG_WITH is expanded from... aclocal.m4:1926: _LT_AC_TAGCONFIG is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [back quotes and double quotes must not be escaped in: $as_me:$LINENO: error: tag name \"$tagname\" already exists], [aclocal.m4:1926: _LT_AC_TAGCONFIG is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [back quotes and double quotes must not be escaped in: $as_me: error: tag name \"$tagname\" already exists], [aclocal.m4:1926: _LT_AC_TAGCONFIG is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- AC_SUBST([CXX]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([CXX]) m4trace:configure.in:14: -1- m4_pattern_allow([^CXX$]) m4trace:configure.in:14: -1- AC_SUBST([CXXFLAGS]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([CXXFLAGS]) m4trace:configure.in:14: -1- m4_pattern_allow([^CXXFLAGS$]) m4trace:configure.in:14: -1- AC_SUBST([LDFLAGS]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([LDFLAGS]) m4trace:configure.in:14: -1- m4_pattern_allow([^LDFLAGS$]) m4trace:configure.in:14: -1- AC_SUBST([LIBS]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([LIBS]) m4trace:configure.in:14: -1- m4_pattern_allow([^LIBS$]) m4trace:configure.in:14: -1- AC_SUBST([CPPFLAGS]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([CPPFLAGS]) m4trace:configure.in:14: -1- m4_pattern_allow([^CPPFLAGS$]) m4trace:configure.in:14: -1- AC_SUBST([CXX]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([CXX]) m4trace:configure.in:14: -1- m4_pattern_allow([^CXX$]) m4trace:configure.in:14: -1- AC_SUBST([ac_ct_CXX]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([ac_ct_CXX]) m4trace:configure.in:14: -1- m4_pattern_allow([^ac_ct_CXX$]) m4trace:configure.in:14: -1- AC_SUBST([CXXDEPMODE], [depmode=$am_cv_CXX_dependencies_compiler_type]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([CXXDEPMODE]) m4trace:configure.in:14: -1- m4_pattern_allow([^CXXDEPMODE$]) m4trace:configure.in:14: -1- AM_CONDITIONAL([am__fastdepCXX], [ test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CXX_dependencies_compiler_type" = gcc3]) m4trace:configure.in:14: -1- AC_SUBST([am__fastdepCXX_TRUE]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([am__fastdepCXX_TRUE]) m4trace:configure.in:14: -1- m4_pattern_allow([^am__fastdepCXX_TRUE$]) m4trace:configure.in:14: -1- AC_SUBST([am__fastdepCXX_FALSE]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([am__fastdepCXX_FALSE]) m4trace:configure.in:14: -1- m4_pattern_allow([^am__fastdepCXX_FALSE$]) m4trace:configure.in:14: -1- AC_SUBST([CXXCPP]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([CXXCPP]) m4trace:configure.in:14: -1- m4_pattern_allow([^CXXCPP$]) m4trace:configure.in:14: -1- AC_SUBST([CPPFLAGS]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([CPPFLAGS]) m4trace:configure.in:14: -1- m4_pattern_allow([^CPPFLAGS$]) m4trace:configure.in:14: -1- AC_SUBST([CXXCPP]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([CXXCPP]) m4trace:configure.in:14: -1- m4_pattern_allow([^CXXCPP$]) m4trace:configure.in:14: -1- AC_SUBST([F77]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([F77]) m4trace:configure.in:14: -1- m4_pattern_allow([^F77$]) m4trace:configure.in:14: -1- AC_SUBST([FFLAGS]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([FFLAGS]) m4trace:configure.in:14: -1- m4_pattern_allow([^FFLAGS$]) m4trace:configure.in:14: -1- AC_SUBST([LDFLAGS]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([LDFLAGS]) m4trace:configure.in:14: -1- m4_pattern_allow([^LDFLAGS$]) m4trace:configure.in:14: -1- AC_SUBST([LIBS]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([LIBS]) m4trace:configure.in:14: -1- m4_pattern_allow([^LIBS$]) m4trace:configure.in:14: -1- AC_SUBST([F77]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([F77]) m4trace:configure.in:14: -1- m4_pattern_allow([^F77$]) m4trace:configure.in:14: -1- AC_SUBST([ac_ct_F77]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([ac_ct_F77]) m4trace:configure.in:14: -1- m4_pattern_allow([^ac_ct_F77$]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_LANG_SAVE' is obsolete. You should run autoupdate.], [../../lib/autoconf/lang.m4:167: AC_LANG_SAVE is expanded from... aclocal.m4:4187: _LT_AC_LANG_GCJ_CONFIG is expanded from... aclocal.m4:4186: AC_LIBTOOL_LANG_GCJ_CONFIG is expanded from... aclocal.m4:1926: _LT_AC_TAGCONFIG is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_LANG_RESTORE' is obsolete. You should run autoupdate.], [../../lib/autoconf/lang.m4:176: AC_LANG_RESTORE is expanded from... aclocal.m4:4187: _LT_AC_LANG_GCJ_CONFIG is expanded from... aclocal.m4:4186: AC_LIBTOOL_LANG_GCJ_CONFIG is expanded from... aclocal.m4:1926: _LT_AC_TAGCONFIG is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_LANG_SAVE' is obsolete. You should run autoupdate.], [../../lib/autoconf/lang.m4:167: AC_LANG_SAVE is expanded from... aclocal.m4:4243: _LT_AC_LANG_RC_CONFIG is expanded from... aclocal.m4:4242: AC_LIBTOOL_LANG_RC_CONFIG is expanded from... aclocal.m4:1926: _LT_AC_TAGCONFIG is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- _m4_warn([obsolete], [The macro `AC_LANG_RESTORE' is obsolete. You should run autoupdate.], [../../lib/autoconf/lang.m4:176: AC_LANG_RESTORE is expanded from... aclocal.m4:4243: _LT_AC_LANG_RC_CONFIG is expanded from... aclocal.m4:4242: AC_LIBTOOL_LANG_RC_CONFIG is expanded from... aclocal.m4:1926: _LT_AC_TAGCONFIG is expanded from... aclocal.m4:86: AC_LIBTOOL_SETUP is expanded from... aclocal.m4:66: _AC_PROG_LIBTOOL is expanded from... aclocal.m4:31: AC_PROG_LIBTOOL is expanded from... configure.in:14: the top level]) m4trace:configure.in:14: -1- AC_SUBST([LIBTOOL]) m4trace:configure.in:14: -1- AC_SUBST_TRACE([LIBTOOL]) m4trace:configure.in:14: -1- m4_pattern_allow([^LIBTOOL$]) m4trace:configure.in:17: -1- AH_OUTPUT([HAVE_LIBM], [/* Define to 1 if you have the `m\' library (-lm). */ #undef HAVE_LIBM]) m4trace:configure.in:17: -1- AC_DEFINE_TRACE_LITERAL([HAVE_LIBM]) m4trace:configure.in:17: -1- m4_pattern_allow([^HAVE_LIBM$]) m4trace:configure.in:18: -1- AH_OUTPUT([HAVE_LIBPTHREAD], [/* Define to 1 if you have the `pthread\' library (-lpthread). */ #undef HAVE_LIBPTHREAD]) m4trace:configure.in:18: -1- AC_DEFINE_TRACE_LITERAL([HAVE_LIBPTHREAD]) m4trace:configure.in:18: -1- m4_pattern_allow([^HAVE_LIBPTHREAD$]) m4trace:configure.in:21: -1- AC_DEFINE_TRACE_LITERAL([STDC_HEADERS]) m4trace:configure.in:21: -1- m4_pattern_allow([^STDC_HEADERS$]) m4trace:configure.in:21: -1- AH_OUTPUT([STDC_HEADERS], [/* Define to 1 if you have the ANSI C header files. */ #undef STDC_HEADERS]) m4trace:configure.in:22: -1- AH_OUTPUT([HAVE_ARPA_INET_H], [/* Define to 1 if you have the header file. */ #undef HAVE_ARPA_INET_H]) m4trace:configure.in:22: -1- AH_OUTPUT([HAVE_NETDB_H], [/* Define to 1 if you have the header file. */ #undef HAVE_NETDB_H]) m4trace:configure.in:22: -1- AH_OUTPUT([HAVE_NETINET_IN_H], [/* Define to 1 if you have the header file. */ #undef HAVE_NETINET_IN_H]) m4trace:configure.in:25: -1- AC_DEFINE_TRACE_LITERAL([const]) m4trace:configure.in:25: -1- m4_pattern_allow([^const$]) m4trace:configure.in:25: -1- AH_OUTPUT([const], [/* Define to empty if `const\' does not conform to ANSI C. */ #undef const]) m4trace:configure.in:26: -1- AH_OUTPUT([inline], [/* Define to `__inline__\' or `__inline\' if that\'s what the C compiler calls it, or to nothing if \'inline\' is not supported under any name. */ #ifndef __cplusplus #undef inline #endif]) m4trace:configure.in:27: -1- AC_DEFINE_TRACE_LITERAL([size_t]) m4trace:configure.in:27: -1- m4_pattern_allow([^size_t$]) m4trace:configure.in:27: -1- AH_OUTPUT([size_t], [/* Define to `unsigned int\' if does not define. */ #undef size_t]) m4trace:configure.in:28: -1- AC_DEFINE_TRACE_LITERAL([HAVE_DECL_SYS_SIGLIST]) m4trace:configure.in:28: -1- m4_pattern_allow([^HAVE_DECL_SYS_SIGLIST$]) m4trace:configure.in:28: -1- AH_OUTPUT([HAVE_DECL_SYS_SIGLIST], [/* Define to 1 if you have the declaration of `sys_siglist\', and to 0 if you don\'t. */ #undef HAVE_DECL_SYS_SIGLIST]) m4trace:configure.in:28: -1- AC_DEFINE_TRACE_LITERAL([HAVE_DECL_SYS_SIGLIST]) m4trace:configure.in:28: -1- m4_pattern_allow([^HAVE_DECL_SYS_SIGLIST$]) m4trace:configure.in:29: -1- AC_DEFINE_TRACE_LITERAL([TIME_WITH_SYS_TIME]) m4trace:configure.in:29: -1- m4_pattern_allow([^TIME_WITH_SYS_TIME$]) m4trace:configure.in:29: -1- AH_OUTPUT([TIME_WITH_SYS_TIME], [/* Define to 1 if you can safely include both and . */ #undef TIME_WITH_SYS_TIME]) m4trace:configure.in:30: -1- AC_DEFINE_TRACE_LITERAL([TM_IN_SYS_TIME]) m4trace:configure.in:30: -1- m4_pattern_allow([^TM_IN_SYS_TIME$]) m4trace:configure.in:30: -1- AH_OUTPUT([TM_IN_SYS_TIME], [/* Define to 1 if your declares `struct tm\'. */ #undef TM_IN_SYS_TIME]) m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_DIRENT_H], [/* Define to 1 if you have the header file, and it defines `DIR\'. */ #undef HAVE_DIRENT_H]) m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_SYS_NDIR_H], [/* Define to 1 if you have the header file, and it defines `DIR\'. */ #undef HAVE_SYS_NDIR_H]) m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_SYS_DIR_H], [/* Define to 1 if you have the header file, and it defines `DIR\'. */ #undef HAVE_SYS_DIR_H]) m4trace:configure.in:33: -1- AH_OUTPUT([HAVE_NDIR_H], [/* Define to 1 if you have the header file, and it defines `DIR\'. */ #undef HAVE_NDIR_H]) m4trace:configure.in:33: -1- AC_DEFINE_TRACE_LITERAL([CLOSEDIR_VOID]) m4trace:configure.in:33: -1- m4_pattern_allow([^CLOSEDIR_VOID$]) m4trace:configure.in:33: -1- AH_OUTPUT([CLOSEDIR_VOID], [/* Define to 1 if the `closedir\' function returns void instead of `int\'. */ #undef CLOSEDIR_VOID]) m4trace:configure.in:34: -1- AC_DEFINE_TRACE_LITERAL([pid_t]) m4trace:configure.in:34: -1- m4_pattern_allow([^pid_t$]) m4trace:configure.in:34: -1- AH_OUTPUT([pid_t], [/* Define to `int\' if does not define. */ #undef pid_t]) m4trace:configure.in:34: -1- AH_OUTPUT([HAVE_VFORK_H], [/* Define to 1 if you have the header file. */ #undef HAVE_VFORK_H]) m4trace:configure.in:34: -1- AH_OUTPUT([HAVE_FORK], [/* Define to 1 if you have the `fork\' function. */ #undef HAVE_FORK]) m4trace:configure.in:34: -1- AH_OUTPUT([HAVE_VFORK], [/* Define to 1 if you have the `vfork\' function. */ #undef HAVE_VFORK]) m4trace:configure.in:34: -1- AC_DEFINE_TRACE_LITERAL([HAVE_WORKING_VFORK]) m4trace:configure.in:34: -1- m4_pattern_allow([^HAVE_WORKING_VFORK$]) m4trace:configure.in:34: -1- AH_OUTPUT([HAVE_WORKING_VFORK], [/* Define to 1 if `vfork\' works. */ #undef HAVE_WORKING_VFORK]) m4trace:configure.in:34: -1- AC_DEFINE_TRACE_LITERAL([vfork]) m4trace:configure.in:34: -1- m4_pattern_allow([^vfork$]) m4trace:configure.in:34: -1- AH_OUTPUT([vfork], [/* Define as `fork\' if `vfork\' does not work. */ #undef vfork]) m4trace:configure.in:34: -1- AC_DEFINE_TRACE_LITERAL([HAVE_WORKING_FORK]) m4trace:configure.in:34: -1- m4_pattern_allow([^HAVE_WORKING_FORK$]) m4trace:configure.in:34: -1- AH_OUTPUT([HAVE_WORKING_FORK], [/* Define to 1 if `fork\' works. */ #undef HAVE_WORKING_FORK]) m4trace:configure.in:35: -1- AH_OUTPUT([HAVE_STDLIB_H], [/* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H]) m4trace:configure.in:35: -1- AC_DEFINE_TRACE_LITERAL([HAVE_MALLOC]) m4trace:configure.in:35: -1- m4_pattern_allow([^HAVE_MALLOC$]) m4trace:configure.in:35: -1- AH_OUTPUT([HAVE_MALLOC], [/* Define to 1 if your system has a GNU libc compatible `malloc\' function, and to 0 otherwise. */ #undef HAVE_MALLOC]) m4trace:configure.in:35: -1- AC_DEFINE_TRACE_LITERAL([HAVE_MALLOC]) m4trace:configure.in:35: -1- m4_pattern_allow([^HAVE_MALLOC$]) m4trace:configure.in:35: -1- AC_LIBSOURCE([malloc.c]) m4trace:configure.in:35: -1- AC_SUBST([LIB@&t@OBJS], ["$LIB@&t@OBJS malloc.$ac_objext"]) m4trace:configure.in:35: -1- AC_SUBST_TRACE([LIB@&t@OBJS]) m4trace:configure.in:35: -1- m4_pattern_allow([^LIB@&t@OBJS$]) m4trace:configure.in:35: -1- AC_DEFINE_TRACE_LITERAL([malloc]) m4trace:configure.in:35: -1- m4_pattern_allow([^malloc$]) m4trace:configure.in:35: -1- AH_OUTPUT([malloc], [/* Define to rpl_malloc if the replacement function should be used. */ #undef malloc]) m4trace:configure.in:36: -1- AH_OUTPUT([HAVE_STDLIB_H], [/* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H]) m4trace:configure.in:36: -1- AC_DEFINE_TRACE_LITERAL([HAVE_REALLOC]) m4trace:configure.in:36: -1- m4_pattern_allow([^HAVE_REALLOC$]) m4trace:configure.in:36: -1- AH_OUTPUT([HAVE_REALLOC], [/* Define to 1 if your system has a GNU libc compatible `realloc\' function, and to 0 otherwise. */ #undef HAVE_REALLOC]) m4trace:configure.in:36: -1- AC_DEFINE_TRACE_LITERAL([HAVE_REALLOC]) m4trace:configure.in:36: -1- m4_pattern_allow([^HAVE_REALLOC$]) m4trace:configure.in:36: -1- AC_LIBSOURCE([realloc.c]) m4trace:configure.in:36: -1- AC_SUBST([LIB@&t@OBJS], ["$LIB@&t@OBJS realloc.$ac_objext"]) m4trace:configure.in:36: -1- AC_SUBST_TRACE([LIB@&t@OBJS]) m4trace:configure.in:36: -1- m4_pattern_allow([^LIB@&t@OBJS$]) m4trace:configure.in:36: -1- AC_DEFINE_TRACE_LITERAL([realloc]) m4trace:configure.in:36: -1- m4_pattern_allow([^realloc$]) m4trace:configure.in:36: -1- AH_OUTPUT([realloc], [/* Define to rpl_realloc if the replacement function should be used. */ #undef realloc]) m4trace:configure.in:37: -1- AH_OUTPUT([HAVE_SYS_SELECT_H], [/* Define to 1 if you have the header file. */ #undef HAVE_SYS_SELECT_H]) m4trace:configure.in:37: -1- AH_OUTPUT([HAVE_SYS_SOCKET_H], [/* Define to 1 if you have the header file. */ #undef HAVE_SYS_SOCKET_H]) m4trace:configure.in:37: -1- AC_DEFINE_TRACE_LITERAL([SELECT_TYPE_ARG1]) m4trace:configure.in:37: -1- m4_pattern_allow([^SELECT_TYPE_ARG1$]) m4trace:configure.in:37: -1- AH_OUTPUT([SELECT_TYPE_ARG1], [/* Define to the type of arg 1 for `select\'. */ #undef SELECT_TYPE_ARG1]) m4trace:configure.in:37: -1- AC_DEFINE_TRACE_LITERAL([SELECT_TYPE_ARG234]) m4trace:configure.in:37: -1- m4_pattern_allow([^SELECT_TYPE_ARG234$]) m4trace:configure.in:37: -1- AH_OUTPUT([SELECT_TYPE_ARG234], [/* Define to the type of args 2, 3 and 4 for `select\'. */ #undef SELECT_TYPE_ARG234]) m4trace:configure.in:37: -1- AC_DEFINE_TRACE_LITERAL([SELECT_TYPE_ARG5]) m4trace:configure.in:37: -1- m4_pattern_allow([^SELECT_TYPE_ARG5$]) m4trace:configure.in:37: -1- AH_OUTPUT([SELECT_TYPE_ARG5], [/* Define to the type of arg 5 for `select\'. */ #undef SELECT_TYPE_ARG5]) m4trace:configure.in:38: -1- AC_DEFINE_TRACE_LITERAL([PROTOTYPES]) m4trace:configure.in:38: -1- m4_pattern_allow([^PROTOTYPES$]) m4trace:configure.in:38: -1- AH_OUTPUT([PROTOTYPES], [/* Define to 1 if the C compiler supports function prototypes. */ #undef PROTOTYPES]) m4trace:configure.in:38: -1- AC_DEFINE_TRACE_LITERAL([__PROTOTYPES]) m4trace:configure.in:38: -1- m4_pattern_allow([^__PROTOTYPES$]) m4trace:configure.in:38: -1- AH_OUTPUT([__PROTOTYPES], [/* Define like PROTOTYPES; this can be used by system headers. */ #undef __PROTOTYPES]) m4trace:configure.in:38: -1- AC_DEFINE_TRACE_LITERAL([SETVBUF_REVERSED]) m4trace:configure.in:38: -1- m4_pattern_allow([^SETVBUF_REVERSED$]) m4trace:configure.in:38: -1- AH_OUTPUT([SETVBUF_REVERSED], [/* Define to 1 if the `setvbuf\' function takes the buffering type as its second argument and the buffer pointer as the third, as on System V before release 3. */ #undef SETVBUF_REVERSED]) m4trace:configure.in:39: -1- AC_DEFINE_TRACE_LITERAL([RETSIGTYPE]) m4trace:configure.in:39: -1- m4_pattern_allow([^RETSIGTYPE$]) m4trace:configure.in:39: -1- AH_OUTPUT([RETSIGTYPE], [/* Define as the return type of signal handlers (`int\' or `void\'). */ #undef RETSIGTYPE]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_ALARM], [/* Define to 1 if you have the `alarm\' function. */ #undef HAVE_ALARM]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_BZERO], [/* Define to 1 if you have the `bzero\' function. */ #undef HAVE_BZERO]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_GETHOSTBYNAME], [/* Define to 1 if you have the `gethostbyname\' function. */ #undef HAVE_GETHOSTBYNAME]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_GETHOSTNAME], [/* Define to 1 if you have the `gethostname\' function. */ #undef HAVE_GETHOSTNAME]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_GETTIMEOFDAY], [/* Define to 1 if you have the `gettimeofday\' function. */ #undef HAVE_GETTIMEOFDAY]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_INET_NTOA], [/* Define to 1 if you have the `inet_ntoa\' function. */ #undef HAVE_INET_NTOA]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_MEMSET], [/* Define to 1 if you have the `memset\' function. */ #undef HAVE_MEMSET]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_POW], [/* Define to 1 if you have the `pow\' function. */ #undef HAVE_POW]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_PUTENV], [/* Define to 1 if you have the `putenv\' function. */ #undef HAVE_PUTENV]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_SELECT], [/* Define to 1 if you have the `select\' function. */ #undef HAVE_SELECT]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_SETLOCALE], [/* Define to 1 if you have the `setlocale\' function. */ #undef HAVE_SETLOCALE]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_SOCKET], [/* Define to 1 if you have the `socket\' function. */ #undef HAVE_SOCKET]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_STRCHR], [/* Define to 1 if you have the `strchr\' function. */ #undef HAVE_STRCHR]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_STRDUP], [/* Define to 1 if you have the `strdup\' function. */ #undef HAVE_STRDUP]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_STRERROR], [/* Define to 1 if you have the `strerror\' function. */ #undef HAVE_STRERROR]) m4trace:configure.in:40: -1- AH_OUTPUT([HAVE_STRSTR], [/* Define to 1 if you have the `strstr\' function. */ #undef HAVE_STRSTR]) m4trace:configure.in:42: -1- AC_CONFIG_FILES([Makefile src/Makefile mcastproxy/Makefile rmchat/Makefile]) m4trace:configure.in:42: -1- _m4_warn([obsolete], [AC_OUTPUT should be used without arguments. You should run autoupdate.], []) m4trace:configure.in:42: -1- AC_SUBST([LIB@&t@OBJS], [$ac_libobjs]) m4trace:configure.in:42: -1- AC_SUBST_TRACE([LIB@&t@OBJS]) m4trace:configure.in:42: -1- m4_pattern_allow([^LIB@&t@OBJS$]) m4trace:configure.in:42: -1- AC_SUBST([LTLIBOBJS], [$ac_ltlibobjs]) m4trace:configure.in:42: -1- AC_SUBST_TRACE([LTLIBOBJS]) m4trace:configure.in:42: -1- m4_pattern_allow([^LTLIBOBJS$]) m4trace:configure.in:42: -1- AC_SUBST_TRACE([top_builddir]) m4trace:configure.in:42: -1- AC_SUBST_TRACE([srcdir]) m4trace:configure.in:42: -1- AC_SUBST_TRACE([abs_srcdir]) m4trace:configure.in:42: -1- AC_SUBST_TRACE([top_srcdir]) m4trace:configure.in:42: -1- AC_SUBST_TRACE([abs_top_srcdir]) m4trace:configure.in:42: -1- AC_SUBST_TRACE([builddir]) m4trace:configure.in:42: -1- AC_SUBST_TRACE([abs_builddir]) m4trace:configure.in:42: -1- AC_SUBST_TRACE([abs_top_builddir]) m4trace:configure.in:42: -1- AC_SUBST_TRACE([INSTALL]) tgif-QPL-4.2.5/rmcast/autom4te.cache/requests0000644000076400007640000000514211566506151020676 0ustar williamwilliam# This file was generated. # It contains the lists of macros which have been traced. # It can be safely removed. @request = ( bless( [ '0', 1, [ '/usr/share/autoconf' ], [ '/usr/share/autoconf/autoconf/autoconf.m4f', 'aclocal.m4', 'configure.in' ], { '_LT_AC_TAGCONFIG' => 1, 'AM_PROG_F77_C_O' => 1, 'AC_INIT' => 1, 'm4_pattern_forbid' => 1, 'AC_CANONICAL_TARGET' => 1, 'AC_SUBST' => 1, 'AC_CONFIG_LIBOBJ_DIR' => 1, 'AC_FC_SRCEXT' => 1, 'AC_CANONICAL_HOST' => 1, 'AC_PROG_LIBTOOL' => 1, 'AM_INIT_AUTOMAKE' => 1, 'AC_CONFIG_SUBDIRS' => 1, 'AM_AUTOMAKE_VERSION' => 1, 'LT_CONFIG_LTDL_DIR' => 1, 'AC_REQUIRE_AUX_FILE' => 1, 'AC_CONFIG_LINKS' => 1, 'm4_sinclude' => 1, 'LT_SUPPORTED_TAG' => 1, 'AM_MAINTAINER_MODE' => 1, 'AM_GNU_GETTEXT_INTL_SUBDIR' => 1, '_m4_warn' => 1, 'AM_PROG_CXX_C_O' => 1, 'AM_ENABLE_MULTILIB' => 1, 'AC_CONFIG_FILES' => 1, 'include' => 1, 'LT_INIT' => 1, 'AM_GNU_GETTEXT' => 1, 'AC_LIBSOURCE' => 1, 'AM_PROG_FC_C_O' => 1, 'AC_CANONICAL_BUILD' => 1, 'AC_FC_FREEFORM' => 1, 'AH_OUTPUT' => 1, '_AM_SUBST_NOTMAKE' => 1, 'AC_CONFIG_AUX_DIR' => 1, 'sinclude' => 1, 'm4_pattern_allow' => 1, 'AM_PROG_CC_C_O' => 1, 'AC_CANONICAL_SYSTEM' => 1, 'AM_CONDITIONAL' => 1, 'AC_CONFIG_HEADERS' => 1, 'AC_DEFINE_TRACE_LITERAL' => 1, 'm4_include' => 1, 'AC_SUBST_TRACE' => 1 } ], 'Autom4te::Request' ) ); tgif-QPL-4.2.5/rmcast/tools/0000755000076400007640000000000011602233155015422 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/tools/tcpdump2rmcast/0000755000076400007640000000000011602233155020372 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/tools/tcpdump2rmcast/tcpdump2rmcast.c0000644000076400007640000001437710122646342023524 0ustar williamwilliam#include #include #include #include #include "rmstruct.e" #include "rminternals.e" #include "rmmsgpckt.e" FILE *logfile; void set(int *dest, int dat3, int dat4); void showLogMsg(char type, PACKET_INFO *pckt_info); struct timeval time_of_day; int main() { PACKET_INFO pckt_info; int data[1000]; int cont,i; char line[180]; char char_trash1[100], char_trash2[100], char_trash3[100], char_trash4[100]; int dat1,dat2,dat3,dat4,dat5,dat6,dat7,dat8, trash1, trash2, trash3, trash4; char *aux; int hour, min, sec, msec; if (fgets(line,180,stdin)==NULL) exit(1); while (line!=NULL) { if (line[0] != '\t') { sscanf(line,"%d:%d:%d.%d %s %s %s %s", &hour, &min, &sec, &msec, char_trash1,char_trash2,char_trash3,char_trash4); aux = line; while ((*aux)!=':') aux++; aux++; while ((*aux)!=':') aux++; aux++; while ((*aux)!=':') aux++; aux++; aux++; if ( *aux == 'i' ) { puts(line); fgets(line,180,stdin); while (line[0]=='\t') fgets(line,180,stdin); continue; } time_of_day.tv_sec = (hour*60+min)*60+sec; time_of_day.tv_usec = msec; if (fgets(line,180,stdin)==NULL) { break; } } else { for (i=0; i<1; i++) { if (fgets(line,180,stdin)==NULL) { break; } } memset(data,0,1000); cont = 0; sscanf(line,"%x %x %x %x %x %x %x %x", &trash1, &trash2, &trash3, &trash4, &dat1, &dat2, &dat3, &dat4); set(&(data[cont]), dat3, dat4); cont++; if (fgets(line,180,stdin)==NULL) break; puts(line); while (line[0]=='\t') { sscanf(line,"%x %x %x %x %x %x %x %x", &dat1, &dat2, &dat3, &dat4, &dat5, &dat6, &dat7, &dat8); set(&(data[cont]), dat1, dat2); cont ++; set(&(data[cont]), dat3, dat4); cont ++; set(&(data[cont]), dat5, dat6); cont ++; set(&(data[cont]), dat7, dat8); cont ++; if (fgets(line,180,stdin)==NULL) break; } // msgPcktShowMessage((BYTE *)data); msgPcktUnmountMessage(&pckt_info, (BYTE *)data); showLogMsg('R', &pckt_info); } } return 1; } void set(int *dest, int dat3, int dat4) { int aux; aux = ((dat4 << 16) | dat3) ; memcpy(dest, &aux, 4); swab(dest,dest,4); } void showLogMsg(char type, PACKET_INFO *pckt_info) { int sn=0; char member_id[100]; char pid[6]; char last_sn[16]; // gettimeofday(&time_of_day, 0); if (pckt_info !=NULL) { switch (pckt_info->type) { case DATA_PACKET_TYPE: sn = pckt_info->packet_data.data_packet.sn; strcpy(member_id,pckt_info->sender_id.ip); strcat(member_id,"\t"); sprintf(pid,"%d",pckt_info->sender_id.pid); strcat(member_id,pid); break; case NAK_PACKET_TYPE: sn = pckt_info->packet_data.nak_packet.sn; // sprintf(last_sn," -> %d",pckt_info->packet_data.nak_packet.last_sn); strcpy(member_id,pckt_info->packet_data.nak_packet.requested_member_id.ip); strcat(member_id,"\t"); sprintf(pid,"%d",pckt_info->packet_data.nak_packet.requested_member_id.pid); strcat(member_id,pid); break; case RETRANSM_PACKET_TYPE: sn = pckt_info->packet_data.retransm_packet.data_packet.sn; strcpy(member_id,pckt_info->packet_data.retransm_packet.original_sender_id.ip); strcat(member_id,"\t"); sprintf(pid,"%d",pckt_info->packet_data.retransm_packet.original_sender_id.pid); strcat(member_id,pid); break; #ifdef REFRESH case REFRESH_PACKET_TYPE: sn = pckt_info->packet_data.refresh_packet.sn_of_last_msg_sent; strcpy(member_id,pckt_info->sender_id.ip); strcat(member_id,"\t"); sprintf(pid,"%d",pckt_info->sender_id.pid); strcat(member_id,pid); break; #endif default: fprintf(stderr,"Unknown packet type: %c\n",pckt_info->type); break; } if((pckt_info->type <= 3)||(pckt_info->type == 8)) { fprintf(stderr,"%.0Lf %c %s %20s\t%3d%s\n", ( (((long double)time_of_day.tv_sec)*1000000+(long double)time_of_day.tv_usec) ) , type, MESSAGE_TYPE_NAME[(int)pckt_info->type], member_id, sn, ((type == NAK_PACKET_TYPE) ? last_sn:"")); } } else { fprintf(logfile,"%.0Lf %c\n", ( (((long double)time_of_day.tv_sec)*1000000+(long double)time_of_day.tv_usec) ) , type); } } tgif-QPL-4.2.5/rmcast/tools/tcpdump2rmcast/timeofday.c0000644000076400007640000000101510122646342022516 0ustar williamwilliam#include #include #include #include int main() { struct timeval time_of_day; struct tm time; gettimeofday(&time_of_day, 0); fprintf(stderr,"%ld:%ld\n", time_of_day.tv_sec, time_of_day.tv_usec ); fprintf(stderr,"%s", ctime((const time_t*)&time_of_day)); tm = *((const time_t*)&time_of_day); time_of_day. tv_sec = ( (tm.tm_hour * 60 + tm.tm_min) * 60 ) + tm.tm_sec; return 1; } tgif-QPL-4.2.5/rmcast/tools/tcpdump2rmcast/README0000644000076400007640000000145410122646342021260 0ustar williamwilliamProgram: tcpdump2rmcast Converts a file generated by the tcpdump command to the format of rmcast log. To compile: gcc tcpdump2rmcast.c rmmsgpckt_debug.o -otcpdump2rmcast -Wall To execute: ./tcpdump2rmcast < log_file 2> out.txt To generate the tcpdump log file: tcpdump -lx ip multicast and src host_name > log_file (as root) Obs.: the showLogMsg() is the same as in rminternals.c, except for line 111, which is commented. Please note that the rmmsgpckt_debug.o file is included here for convenience. It may be generated by compiling rmcast including the option -DDEBUG in DEFINES line of the Makefile of rmcast, and then renaming rmmsgpckt.o to rmmsgpckt_debug.o. Allyson, Daniel Sadoc and Milena { allyson, sadoc, milena }@land.ufrj.br tgif-QPL-4.2.5/rmcast/tools/tcpdump2rmcast/Makefile0000644000076400007640000000012510122646342022032 0ustar williamwilliamall: gcc -DREFRESH tcpdump2rmcast.c rmmsgpckt_debug.o -otcpdump2rmcast -Wall -I.. tgif-QPL-4.2.5/rmcast/tools/scripts/0000755000076400007640000000000011602233155017111 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/tools/scripts/makedeb.sh0000755000076400007640000000713111141162505021040 0ustar williamwilliam#!/bin/bash # Variaveis que cujos valores sao passados como parametros SONUMBER=0 SOURCEDIR=$1 DEBIANDIR=$SOURCEDIR/debian PACKAGENAME=$2 VERSION=$3 LIBDIR=$4 BINDIR=$5 INCLUDEDIR=$6 DOCDIR=$7/doc/lib$PACKAGENAME$SONUMBER # Outras variaveis RELEASE=1land ARCHITECTURE="i386" DEBFILENAME="lib${PACKAGENAME}${SONUMBER}_${VERSION}-${RELEASE}_${ARCHITECTURE}.deb" DEBFILENAME_DEV="lib${PACKAGENAME}${SONUMBER}-dev_${VERSION}-${RELEASE}_${ARCHITECTURE}.deb" echo "Copiando os arquivos" rm -rf ${DEBIANDIR} mkdir -p ${DEBIANDIR}/DEBIAN make DESTDIR=${DEBIANDIR} install rm -rf $DEBIANDIR/$BINDIR strip $DEBIANDIR/$LIBDIR/librmcast.so.0.0.0 chmod -x $DEBIANDIR/$LIBDIR/librmcast.so.0.0.0 mv $DEBIANDIR/$LIBDIR/librmcast.so.0.0.0 $DEBIANDIR/$LIBDIR/librmcast.so.0 $SOURCEDIR # pacote librmcast0-dev echo "Gerando o pacote ${DEBFILENAME_DEV}" chmod -x $DEBIANDIR/$LIBDIR/librmcast.la echo "Gerando o arquivo md5sums" DDIR=`echo ${DEBIANDIR} | sed 's:\/:\\\/:g'` find ${DEBIANDIR} -wholename "${DEBIANDIR}/DEBIAN" -prune -o -type f -exec md5sum '{}' \; | sed -e s/$DDIR// -e 's/\///' > ${DEBIANDIR}/DEBIAN/md5sums echo "Gerando o arquivo control" cat > ${DEBIANDIR}/DEBIAN/control < Description: Reliable multicast library - development headers rmcast is a library for data transmission through multicast in a reliable way. EOF fakeroot dpkg-deb --build ${DEBIANDIR} ${DEBFILENAME_DEV} # pacote librmcast0 echo "Gerando o pacote ${DEBFILENAME}" rm -f $DEBIANDIR/$LIBDIR/librmcast.so $DEBIANDIR/$LIBDIR/librmcast.la $DEBIANDIR/$LIBDIR/librmcast.a rm -rf $DEBIANDIR/$INCLUDEDIR mv $SOURCEDIR/librmcast.so.0.0.0 $SOURCEDIR/librmcast.so.0 $DEBIANDIR/$LIBDIR mkdir -p $DEBIANDIR/$DOCDIR cp $SOURCEDIR/LICENSE.QPL $DEBIANDIR/$DOCDIR/copyright chmod 0644 $DEBIANDIR/$DOCDIR/copyright echo "Gerando o arquivo shlibs ..." echo "librmcast 0 librmcast0 (>= ${VERSION}-${RELEASE})" > ${DEBIANDIR}/DEBIAN/shlibs echo "Gerando o arquivo postinst" cat > ${DEBIANDIR}/DEBIAN/postinst < ${DEBIANDIR}/DEBIAN/postrm < ${DEBIANDIR}/DEBIAN/md5sums echo "Gerando o arquivo control" cat > ${DEBIANDIR}/DEBIAN/control <> ${DEBIANDIR}/DEBIAN/control rm -f ${DEBIANDIR}/control cat >> ${DEBIANDIR}/DEBIAN/control < Description: Reliable multicast library - runtime library rmcast is a library for data transmission through multicast in a reliable way. EOF fakeroot dpkg-deb --build ${DEBIANDIR} ${DEBFILENAME} rm -rf ${DEBIANDIR} exit 0 tgif-QPL-4.2.5/rmcast/tools/scripts/rmlog.awk0000644000076400007640000001435410122646342020746 0ustar williamwilliamBEGIN{ csnddt=0; crcvdt=0; csndnak=0; crcvnak=0; csndrefresh=0; crcvrefresh=0; csndret=0; crcvret=0; csimloss=0; cldt=0; clnak=0; clref=0; clret=0; cpackets=0; control=1; } { if (control>7) { if($2=="S"){ if ($3=="DT"){ csnddt++; sdt[$6]++; } else if ($3=="NK"){ if ( NF >= 11 ){ base_sn=$8; window_size=$9; hmask=$10; lmask=$11; i=0; while( int(lmask/2) > 0 ){ if( (lmask%2)==1 ) snak[base_sn + i + 1]++; lmask=int(lmask/2); i++; } if( (lmask%2)==1 ) snak[base_sn + i + 1]++; i=0; while( int(hmask/2) > 0 ){ if( (hmask%2)==1 ) snak[(int(window_size/2)) + base_sn + i + 1]++; hmask=int(hmask/2); i++; } if( (hmask%2)==1 ) snak[(int(window_size/2)) + base_sn + i + 1]++; } else{ snak[$8]++; } csndnak++; } else if ($3=="RF") csndrefresh++; else if ($3=="RT"){ sret[$8]++; csndret++; } } else if($2=="R"){ if (($3=="DT") && ($4==member_ip) && ($5==member_pid)){ crcvdt++; rdt[$6]++; } else if (($3=="NK") && ($4==member_ip) && ($5==member_pid)){ if ( NF >= 11 ){ base_sn=$8; window_size=$9; hmask=$10; lmask=$11; i=0; while( int(lmask/2) > 0 ){ if( (lmask%2)==1 ) rnak[base_sn + i + 1]++; lmask=int(lmask/2); i++; } if( (lmask%2)==1 ) rnak[base_sn + i + 1]++; i=0; while( int(hmask/2) > 0 ){ if( (hmask%2)==1 ) rnak[(int(window_size/2)) + base_sn + i + 1]++; hmask=int(hmask/2); i++; } if( (hmask%2)==1 ) rnak[(int(window_size/2)) + base_sn + i + 1]++; } else{ rnak[$8]++; } crcvnak++; } else if ($3=="RF") crcvrefresh++; else if (($3=="RT") && ($4==member_ip) && ($5==member_pid)){ rret[$8]++; crcvret++; } } else if($2=="L"){ csimloss++; if (($3=="DT") && ($4==member_ip) && ($5==member_pid)){ ldt[$6]++; cldt++; } else if (($3=="NK") && ($4==member_ip) && ($5==member_pid)){ lnak[$8]++; clnak++; } else if (($3=="RF") && ($4==member_ip) && ($5==member_pid)){ lref[$6]++; clref++; } else if (($3=="RT") && ($4==member_ip) && ($5==member_pid)){ lret[$8]++; clret++; } } cpackets++; } control++; } END{ printf("--------------------------------------------------\n"); printf(" Data related to\n %s -> %s:%d\n",f1,member_ip,member_pid); printf("--------------------------------------------------\n"); printf("Data sent: %d\n",csnddt); printf("Data received from %s:%d %d\n",member_ip,member_pid,crcvdt); printf("NACKs sent: %d\n",csndnak); printf("NACKs received from %s:%d %d\n",member_ip,member_pid,crcvnak); printf("Refresh sent: %d\n",csndrefresh); printf("Refresh received from %s:%d %d\n",member_ip,member_pid,crcvrefresh); printf("Retrans sent: %d\n",csndret); printf("Retrans received from %s:%d %d\n",member_ip,member_pid,crcvret); printf("Total simulated loss: %d\n",csimloss); printf("Data loss with simulation from %s:%d %d\n",member_ip,member_pid,cldt); printf("NACKs lost by simulation from %s:%d %d\n",member_ip,member_pid,clnak); printf("Refresh lost by simulation from %s:%d %d\n",member_ip,member_pid,clref); printf("Retrans lost by simulation from %s:%d %d\n",member_ip,member_pid,clret); printf("Packets identified: %d\n",cpackets); naksenviados=sprintf("%s.naksenviados",f1); naksrecebidos=sprintf("%s.naksrecebidos",f1); retenviadas=sprintf("%s.retenviadas",f1); retrecebidas=sprintf("%s.retrecebidas",f1); dtperdidos=sprintf("%s.dtperdidos",f1); nakperdidos=sprintf("%s.nakperdidos",f1); retperdidos=sprintf("%s.retperdidas",f1); refperdidos=sprintf("%s.refperdidos",f1); dtenviados=sprintf("%s.dtenviados",f1); dtrecebidos=sprintf("%s.dtrecebidos",f1); print " "> naksenviados; print " "> retenviadas; print " "> naksrecebidos; print " "> retrecebidas; print " "> dtperdidos; print " "> nakperdidos; print " "> retperdidos; print " "> refperdidos; print " "> dtenviados; print " "> dtrecebidos; for( j = 0; j < maxsndpackets; j++ ) { printf("%d %d\n",j,snak[j]) >> naksenviados; printf("%d %d\n",j,sret[j]) >> retenviadas; printf("%d %d\n",j,rnak[j]) >> naksrecebidos; printf("%d %d\n",j,rret[j]) >> retrecebidas; printf("%d %d\n",j,ldt[j]) >> dtperdidos; printf("%d %d\n",j,lnak[j]) >> nakperdidos; printf("%d %d\n",j,lret[j]) >> retperdidos; printf("%d %d\n",j,lref[j]) >> refperdidos; printf("%d %d\n",j,sdt[j]) >> dtenviados; printf("%d %d\n",j,rdt[j]) >> dtrecebidos; } if( maxsndpackets > 0 ) printf("Loss: %.4f%% \n\n",(1 - (crcvdt/maxsndpackets))); printf("--------------------------------------------------\n\n"); } tgif-QPL-4.2.5/rmcast/tools/scripts/solarisrmsg.sh0000755000076400007640000000044010122646342022015 0ustar williamwilliam#/bin/bash # This script removes everthing from your system message queue # For further information about message queue and other IPC features # look in the man pages ipcs -q | grep $USER | awk '{print $2}' > ~/list.id for i in `cat ~/list.id` do ipcrm -q $i done rm -f ~/list.id tgif-QPL-4.2.5/rmcast/tools/scripts/rmcastplot.bash0000755000076400007640000001557110122646342022156 0ustar williamwilliam#!/bin/bash #Config RMLOG=rmlog.awk #Functions usage(){ echo echo "--------------------------------------------------------------------------------------------------------" echo " Usage:" echo echo " rmcastplot.bash [awk_script_dir] [tgif|png]" echo echo " xyrange: [XMIN:XMAX][YMIN:YMAX] gnuplot style" echo " member1.log: full path to member log" echo " member2_log: full path to member log" echo " awk_script_dir: optional parameter. Full path to directory where $RMLOG script is found" echo " tgif or png: optional parameter. Changes gnuplot output to generate Tgif files or PNG files" echo "--------------------------------------------------------------------------------------------------------" echo } findawk(){ if [ -e $RMLOG ];then AWKSCRIPT=$RMLOG echo " found." else echo " not found." usage exit 0 fi } # Main if [ $# -eq 0 ];then usage exit 0 else #Naming parameters XYRANGE=$1 LOG1=$2 LOG2=$3 if [ -z $4 ];then echo -n "awk script path not provided, trying to find it in local directory ... " findawk else if [ "$4" = "tgif" ];then echo -n "awk script path not provided, trying to found it in local directory ... " findawk else if [ "$4" = "png" ];then echo -n "awk script path not provided, trying to found it in local directory ... " findawk else echo -n "Awk script path provided, checking ... " if [ -e $4/$RMLOG ];then echo "OK." AWKSCRIPT=$4/$RMLOG else echo "FAILED." exit 0 fi fi fi fi echo MEMBER1_NAME=`head -1 $LOG1 | awk '{if(NR==1)print $2}'` MEMBER1_IP=`head -2 $LOG1 | awk '{if(NR==2)print $2}'` MEMBER1_PID=`head -3 $LOG1 | awk '{if(NR==3)print $2}'` SENT_PACKETS1=`tail -1 $LOG1 | awk '{if($1 == "Sent_Packets:")print $2}'` echo "Member 1 Name: $MEMBER1_NAME" echo "Member 1 IP: $MEMBER1_IP" echo "Member 1 PID: $MEMBER1_PID" echo "Member 1 sent packets: $SENT_PACKETS1" echo MEMBER2_NAME=`head -1 $LOG2 | awk '{if(NR==1)print $2}'` MEMBER2_IP=`head -2 $LOG2 | awk '{if(NR==2)print $2}'` MEMBER2_PID=`head -3 $LOG2 | awk '{if(NR==3)print $2}'` SENT_PACKETS2=`tail -1 $LOG2 | awk '{if($1 == "Sent_Packets:")print $2}'` echo "Member 2 Name: $MEMBER2_NAME" echo "Member 2 IP: $MEMBER2_IP" echo "Member 2 PID: $MEMBER2_PID" echo "Member 2 sent packets: $SENT_PACKETS2" echo # Awk filtering awk -f $AWKSCRIPT maxsndpackets=$SENT_PACKETS1 f1=$LOG2 member_ip=$MEMBER1_IP member_pid=$MEMBER1_PID $LOG2 awk -f $AWKSCRIPT maxsndpackets=$SENT_PACKETS2 f1=$LOG1 member_ip=$MEMBER2_IP member_pid=$MEMBER2_PID $LOG1 #Preparing to plotting DTPLOT="$LOG1.$LOG2.dtplot" NAKSPLOT="$LOG1.$LOG2.naksplot" RETPLOT="$LOG1.$LOG2.retplot" echo > $DTPLOT echo > $NAKSPLOT echo > $RETPLOT if [ "$4" = "tgif" ];then echo "set term tgif portrait [1,1] dashed \"Helvetica\" 14 " >> $DTPLOT echo "set output \"$LOG1.dtplot.obj\"" >> $DTPLOT fi if [ "$4" = "png" ];then echo "set term png small color" >> $DTPLOT echo "set output \"$LOG1.dtplot.png\"" >> $DTPLOT fi echo "plot $XYRANGE \"$LOG1.dtenviados\" title \"$MEMBER1_NAME:$MEMBER1_PID: Data sent to multicast group\" lt 7" >> $DTPLOT if [ "$4" = "png" ];then echo "set output \"$LOG1.dtplot.png\"" >> $DTPLOT fi echo "replot \"$LOG2.dtrecebidos\" title \"$MEMBER2_NAME:$MEMBER2_PID: Data rcv from $MEMBER1_NAME:$MEMBER1_PID\" with lines 8" >> $DTPLOT if [ "$4" = "png" ];then echo "set output \"$LOG1.dtplot.png\"" >> $DTPLOT fi echo "replot \"$LOG2.dtperdidos\" title \"$MEMBER2_NAME:$MEMBER2_PID: Data lost from $MEMBER1_NAME:$MEMBER1_PID\" with lines 3" >> $DTPLOT if [ "$4" = "tgif" ];then echo "set term tgif portrait [1,1] dashed \"Helvetica\" 14 " >> $NAKSPLOT echo "set output \"$LOG1.naksplot.obj\"" >> $NAKSPLOT fi if [ "$4" = "png" ];then echo "set term png small color" >> $NAKSPLOT echo "set output \"$LOG1.naksplot.png\"" >> $NAKSPLOT fi echo "plot $XYRANGE \"$LOG2.naksenviados\" title \"$MEMBER2_NAME:$MEMBER2_PID: Naks sent to multicast group\" with lines 8" >> $NAKSPLOT if [ "$4" = "png" ];then echo "set output \"$LOG1.naksplot.png\"" >> $NAKSPLOT fi echo "replot \"$LOG1.naksrecebidos\" title \"$MEMBER1_NAME:$MEMBER1_PID: Naks rcv from $MEMBER2_NAME:$MEMBER2_PID\" with lines 3" >> $NAKSPLOT if [ "$4" = "png" ];then echo "set output \"$LOG1.naksplot.png\"" >> $NAKSPLOT fi echo "replot \"$LOG1.retenviadas\" title \"$MEMBER1_NAME:$MEMBER1_PID: Retransmission sent to multicast group\" lt 7" >> $NAKSPLOT if [ "$4" = "png" ];then echo "set output \"$LOG1.naksplot.png\"" >> $NAKSPLOT fi echo "replot \"$LOG2.retrecebidas\" title \"$MEMBER2_NAME:$MEMBER2_PID: Retransmission rcv from $MEMBER1_NAME:$MEMBER1_PID\" with lines" >> $NAKSPLOT if [ "$4" = "tgif" ];then echo "set term tgif portrait [1,1] dashed \"Helvetica\" 14 " >> $RETPLOT echo "set output \"$LOG1.retplot.obj\"" >> $RETPLOT fi if [ "$4" = "png" ];then echo "set term png small color" >> $RETPLOT echo "set output \"$LOG1.retplot.png\"" >> $RETPLOT fi echo "plot $XYRANGE \"$LOG1.retenviadas\" title \"$MEMBER1_NAME:$MEMBER1_PID: Retransmission sent to multicast group\" lt 7" >> $RETPLOT if [ "$4" = "png" ];then echo "set output \"$LOG1.retplot.png\"" >> $RETPLOT fi echo "replot \"$LOG2.retrecebidas\" title \"$MEMBER2_NAME:$MEMBER2_PID: Retransmission rcv from $MEMBER1_NAME:$MEMBER1_PID\" with lines 8" >> $RETPLOT if [ "$4" = "png" ];then echo "set output \"$LOG1.retplot.png\"" >> $RETPLOT fi echo "replot \"$LOG2.retperdidas\" title \"$MEMBER2_NAME:$MEMBER2_PID: Retransmission lost from $MEMBER1_NAME:$MEMBER1_PID\" with lines 3" >> $RETPLOT #Plotting gnuplot -persist < $DTPLOT gnuplot -persist < $NAKSPLOT gnuplot -persist < $RETPLOT fi tgif-QPL-4.2.5/rmcast/tools/scripts/special/0000755000076400007640000000000011602233155020531 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/tools/scripts/special/lossplot.awk0000755000076400007640000000071310122646342023122 0ustar williamwilliamBEGIN{ } { if( NR == 1 ){ DATE=$1; } if( NR == 4 ){ HOST1=$1; } if( NR == 10 ){ PCKT_LOSS1=$4; } if( NR == 15 ){ HOST2=$1; } if( NR == 21 ){ PCKT_LOSS2=$4; } if( NR == 26 ){ HOST3=$1; } if( NR == 32 ){ PCKT_LOSS3=$4; } } END{ printf("%d %f\n",DATE,PCKT_LOSS1)>>(HOST1".plot"); printf("%d %f\n",DATE,PCKT_LOSS2)>>(HOST2".plot"); printf("%d %f\n",DATE,PCKT_LOSS3)>>(HOST3".plot"); } tgif-QPL-4.2.5/rmcast/tools/scripts/special/rmlog.awk0000644000076400007640000001647710122646342022376 0ustar williamwilliamBEGIN{ csnddt=0; crcvdt=0; csndnak=0; crcvnak=0; csndrefresh=0; crcvrefresh=0; csndret=0; crcvret=0; csimloss=0; cldt=0; clnak=0; clref=0; clret=0; cpackets=0; control=1; } { if (control>7) { if($2=="S"){ if ($3=="DT") { csnddt++; sdt[$6]++; } else if ($3=="NK"){ if ( NF >= 11 ){ base_sn=$8; window_size=$9; hmask=$10; lmask=$11; i=0; if(lmask<0){ lmask=(-1)*lmask; snak[base_sn + (window_size/2)]++; } while( int(lmask/2) > 0 ){ if( (lmask%2)==1 ) snak[base_sn + i + 1]++; lmask=int(lmask/2); i++; } if( (lmask%2)==1 ) snak[base_sn + i + 1]++; i=0; if(hmask<0){ hmask=(-1)*hmask; snak[base_sn + window_size]++; } while( int(hmask/2) > 0 ){ if( (hmask%2)==1 ) snak[(int(window_size/2)) + base_sn + i + 1]++; hmask=int(hmask/2); i++; } if( (hmask%2)==1 ) snak[(int(window_size/2)) + base_sn + i + 1]++; } else{ snak[$8]++; } csndnak++; } else if ($3=="RF") csndrefresh++; else if ($3=="RT"){ sret[$8]++; csndret++; } } else if($2=="R"){ if (($3=="DT") && ($4==member_ip) && ($5==member_pid)){ crcvdt++; rdt[$6]++; } else if (($3=="NK") && ($4==member_ip) && ($5==member_pid)){ if ( NF >= 11 ){ base_sn=$8; window_size=$9; hmask=$10; lmask=$11; i=0; if(lmask<0){ lmask=(-1)*lmask; rnak[base_sn + (window_size/2)]++; } while( int(lmask/2) > 0 ){ if( (lmask%2)==1 ) rnak[base_sn + i + 1]++; lmask=int(lmask/2); i++; } if( (lmask%2)==1 ) rnak[base_sn + i + 1]++; i=0; if(hmask<0){ hmask=(-1)*hmask; rnak[base_sn + window_size]++; } while( int(hmask/2) > 0 ){ if( (hmask%2)==1 ) rnak[(int(window_size/2)) + base_sn + i + 1]++; hmask=int(hmask/2); i++; } if( (hmask%2)==1 ) rnak[(int(window_size/2)) + base_sn + i + 1]++; } else{ rnak[$8]++; } crcvnak++; } else if (($3=="RF") && ($4==member_ip) && ($5==member_pid)) crcvrefresh++; else if (($3=="RT") && ($4==member_ip) && ($5==member_pid)){ rret[$8]++; crcvret++; } } else if($2=="L") { csimloss++; if (($3=="DT") && ($4==member_ip) && ($5==member_pid)){ ldt[$6]++; cldt++; } else if (($3=="NK") && ($4==member_ip) && ($5==member_pid)){ lnak[$8]++; clnak++; } else if (($3=="RF") && ($4==member_ip) && ($5==member_pid)){ lref[$6]++; clref++; } else if (($3=="RT") && ($4==member_ip) && ($5==member_pid)){ lret[$8]++; clret++; } } cpackets++; } control++; } END{ printf("--------------------------------------------------\n"); printf(" Data related to\n %s -> %s:%d\n",f1,member_ip,member_pid); printf("--------------------------------------------------\n"); printf("Data sent= %d\n",csnddt); printf("Data received from %s:%d= %d\n",member_ip,member_pid,crcvdt); printf("NACKs sent= %d\n",csndnak); printf("NACKs received from %s:%d= %d\n",member_ip,member_pid,crcvnak); printf("Refresh sent= %d\n",csndrefresh); printf("Refresh received from %s:%d= %d\n",member_ip,member_pid,crcvrefresh); printf("Retrans sent= %d\n",csndret); printf("Retrans received from %s:%d= %d\n",member_ip,member_pid,crcvret); printf("Total simulated loss= %d\n",csimloss); printf("Data lost by simulation from %s:%d= %d\n",member_ip,member_pid,cldt); printf("NACKs lost by simulation from %s:%d= %d\n",member_ip,member_pid,clnak); printf("Refresh lost by simulation from %s:%d= %d\n",member_ip,member_pid,clref); printf("Retrans lost by simulation from %s:%d= %d\n",member_ip,member_pid,clret); printf("Packets identified= %d\n",cpackets); naksenviados=sprintf("%s.naksenviados",f1); naksrecebidos=sprintf("%s.naksrecebidos",f1); retenviadas=sprintf("%s.retenviadas",f1); retrecebidas=sprintf("%s.retrecebidas",f1); dtperdidos=sprintf("%s.dtperdidos",f1); nakperdidos=sprintf("%s.nakperdidos",f1); retperdidos=sprintf("%s.retperdidas",f1); refperdidos=sprintf("%s.refperdidos",f1); dtenviados=sprintf("%s.dtenviados",f1); dtrecebidos=sprintf("%s.dtrecebidos",f1); print " "> naksenviados; print " "> retenviadas; print " "> naksrecebidos; print " "> retrecebidas; print " "> dtperdidos; print " "> nakperdidos; print " "> retperdidos; print " "> refperdidos; print " "> dtenviados; print " "> dtrecebidos; for( j = 0; j < maxpcktsource; j++ ) { printf("%d %d\n",j,snak[j]) >> naksenviados; printf("%d %d\n",j,sret[j]) >> retenviadas; printf("%d %d\n",j,rnak[j]) >> naksrecebidos; printf("%d %d\n",j,rret[j]) >> retrecebidas; printf("%d %d\n",j,ldt[j]) >> dtperdidos; printf("%d %d\n",j,lnak[j]) >> nakperdidos; printf("%d %d\n",j,lret[j]) >> retperdidos; printf("%d %d\n",j,lref[j]) >> refperdidos; printf("%d %d\n",j,sdt[j]) >> dtenviados; printf("%d %d\n",j,rdt[j]) >> dtrecebidos; } printf("--------------------------------------------------\n\n"); } tgif-QPL-4.2.5/rmcast/tools/scripts/special/rmcastlossplot.bash0000755000076400007640000000041610122646342024467 0ustar williamwilliam#!/bin/bash for i in `ls *.loss`;do awk -f lossplot.awk $i done for i in `ls *.plot`;do echo "set term png small color">temp echo "set output \"${i}.png\"">>temp echo "plot \"$i\" with lines">>temp gnuplot -persist < temp done \rm temp *.plot tgif-QPL-4.2.5/rmcast/tools/scripts/special/autoplot.bash0000755000076400007640000000477310122646342023257 0ustar williamwilliam#!/bin/bash # AWK script AWKSCRIPT=rmlog2.awk #Functions usage(){ echo echo "--------------------------------------------------------------------------------------------------------" echo " Usage:" echo echo " autoplot.bash " echo echo " max_packets_from_source: amount of packets sent by the source" echo " xyrange: [XMIN:XMAX][YMIN:YMAX] gnuplot style" echo " NULL: write loss info to the default output file (logfile1_logfile2.out)" echo " loss_info_file_extension: extension for the output file where the loss information must be written" echo "--------------------------------------------------------------------------------------------------------" echo } if [ $# -ne 3 ];then usage exit 0 else #Naming parameters MAX_PACKETS_FROM_SOURCE=$1 XYRANGE=$2 if [ $3 != "NULL" ];then LOSS_INFO_FILE=$3 if [ -z $LOSS_INFO_DIR ];then LOSS_INFO_DIR=`pwd` echo "LOSS_INFO_DIR not found, using $LOSS_INFO_DIR" fi for FILE1 in `ls *.log`;do for FILE2 in `ls *.log`;do if [ "$FILE1" != "$FILE2" ];then echo "--------" echo "$FILE1 -> $FILE2" OUTPUT="${FILE1}_${FILE2}.out" ./rmcastplot.bash $MAX_PACKETS_FROM_SOURCE $XYRANGE $FILE1 $FILE2 png> $OUTPUT LOSS_OUTPUT="${LOSS_INFO_DIR}/${FILE1}_${LOSS_INFO_FILE}.loss" echo "${LOSS_INFO_FILE}">> $LOSS_OUTPUT awk -F "=" -f $AWKSCRIPT output_file=$LOSS_OUTPUT $OUTPUT echo "--------" fi done done else for FILE1 in `ls *.log`;do for FILE2 in `ls *.log`;do if [ "$FILE1" != "$FILE2" ];then echo "--------" echo "$FILE1 -> $FILE2" OUTPUT="${FILE1}_${FILE2}.out" ./rmcastplot.bash $MAX_PACKETS_FROM_SOURCE $XYRANGE $FILE1 $FILE2 png> $OUTPUT awk -F "=" -f $AWKSCRIPT output_file=$OUTPUT $OUTPUT echo "--------" fi done done fi fi tgif-QPL-4.2.5/rmcast/tools/scripts/special/rmcastplot.bash0000755000076400007640000001114710122646342023571 0ustar williamwilliam#!/bin/bash #Config RMLOG=rmlog.awk #Functions usage(){ echo echo "--------------------------------------------------------------------------------------------------------" echo " Usage:" echo echo " rmcastplot.bash [awk_script_dir] [tgif|png]" echo echo " max_pckt_sent_by_source: amount of packets sent by the source" echo " xyrange: [XMIN:XMAX][YMIN:YMAX] gnuplot style" echo " member1.log: full path to member log" echo " member2_log: full path to member log" echo " awk_script_dir: optional parameter. Full path to directory where $RMLOG script is found" echo " tgif or png: optional parameter. Changes gnuplot output to generate Tgif files or PNG files" echo "--------------------------------------------------------------------------------------------------------" echo } findawk(){ if [ -e $RMLOG ];then AWKSCRIPT=$RMLOG echo " found.">&2 else echo " not found.">&2 usage exit 0 fi } # Main if [ $# -eq 0 ];then usage exit 0 else #Naming parameters PACKETS_SENT_FROM_SOURCE=$1 XYRANGE=$2 LOG1=$3 LOG2=$4 if [ -z $5 ];then echo -n "awk script path not provided, trying to find it in local directory ... ">&2 findawk else if [ "$5" = "tgif" ];then echo -n "awk script path not provided, trying to found it in local directory ... ">&2 findawk else if [ "$5" = "png" ];then echo -n "awk script path not provided, trying to found it in local directory ... ">&2 findawk else echo -n "Awk script path provided, checking ... ">&2 if [ -e $5/$RMLOG ];then echo "OK.">&2 AWKSCRIPT=$5/$RMLOG else echo "FAILED.">&2 exit 0 fi fi fi fi MEMBER1_NAME=`head -1 $LOG1 | awk '{if(NR==1)print $2}'` MEMBER1_IP=`head -2 $LOG1 | awk '{if(NR==2)print $2}'` MEMBER1_PID=`head -3 $LOG1 | awk '{if(NR==3)print $2}'` SENT_PACKETS1=`tail -1 $LOG1 | awk '{if($1 == "Sent_Packets:")print $2}'` echo echo "Packets sent by the source= $PACKETS_SENT_FROM_SOURCE" echo echo "Member 1 Name= $MEMBER1_NAME" echo "Member 1 IP= $MEMBER1_IP" echo "Member 1 PID= $MEMBER1_PID" echo "Member 1 sent packets= $SENT_PACKETS1" echo MEMBER2_NAME=`head -1 $LOG2 | awk '{if(NR==1)print $2}'` MEMBER2_IP=`head -2 $LOG2 | awk '{if(NR==2)print $2}'` MEMBER2_PID=`head -3 $LOG2 | awk '{if(NR==3)print $2}'` SENT_PACKETS2=`tail -1 $LOG2 | awk '{if($1 == "Sent_Packets:")print $2}'` echo "Member 2 Name= $MEMBER2_NAME" echo "Member 2 IP= $MEMBER2_IP" echo "Member 2 PID= $MEMBER2_PID" echo "Member 2 sent packets= $SENT_PACKETS2" echo # Awk filtering awk -f $AWKSCRIPT maxpcktsource=$PACKETS_SENT_FROM_SOURCE maxpckts=$SENT_PACKETS1 f1=$LOG2 member_ip=$MEMBER1_IP member_pid=$MEMBER1_PID $LOG2 awk -f $AWKSCRIPT maxpcktsource=$PACKETS_SENT_FROM_SOURCE maxpckts=$SENT_PACKETS2 f1=$LOG1 member_ip=$MEMBER2_IP member_pid=$MEMBER2_PID $LOG1 #Preparing to plotting NAKSPLOT="$LOG1.$LOG2.naksplot" echo > $NAKSPLOT if [ "$5" = "png" ];then echo "set term png small color" >> $NAKSPLOT echo "set output \"$LOG1\_$LOG2.png\"" >> $NAKSPLOT fi echo "plot $XYRANGE \"$LOG2.naksenviados\" title \"$MEMBER2_NAME:$MEMBER2_PID: Naks sent to multicast group\" lt 7" >> $NAKSPLOT if [ "$5" = "png" ];then echo "set output \"$LOG1\_$LOG2.png\"" >> $NAKSPLOT fi echo "replot \"$LOG1.retenviadas\" title \"$MEMBER1_NAME:$MEMBER1_PID: Retrans. sent to multicast group\" with lines 8" >> $NAKSPLOT if [ "$5" = "png" ];then echo "set output \"$LOG1\_$LOG2.png\"" >> $NAKSPLOT fi echo "replot \"$LOG2.retrecebidas\" title \"$MEMBER2_NAME:$MEMBER2_PID: Retrans. rcv from $MEMBER1_NAME:$MEMBER1_PID\" with lines" >> $NAKSPLOT #Plotting gnuplot -persist < $NAKSPLOT #Removing temporary files: \rm $LOG1.* $LOG2.* fi tgif-QPL-4.2.5/rmcast/tools/scripts/special/rmlog2.awk0000644000076400007640000000451010122646342022441 0ustar williamwilliamBEGIN{ } { if( NR == 4 ){ SOURCE_NAME=$2; } if( NR == 6 ){ SOURCE_PID=$2; } if( NR == 9 ){ RECEIVER_NAME=$2;} if( NR == 11 ){ RECEIVER_PID=$2; } if( NR == 19 ){ DATA_RECV=$2; } if( NR == 38 ){ DATA_SENT=$2; } if( NR == 40 ){ NACK_SENT=$2; } if( NR == 21 ){ NACK_RECV=$2; } if( NR == 42 ){ REF_SENT=$2; } if( NR == 23 ){ REF_RECV=$2; } if( NR == 44 ){ RET_SENT=$2; } if( NR == 25 ){ RET_RECV=$2; } } END{ printf("\n--------------------------------------------------\n") >> output_file; printf("%s:%d losses from %s:%d\n",RECEIVER_NAME,RECEIVER_PID,SOURCE_NAME,SOURCE_PID) >> output_file; printf("--------------------------------------------------\n") >> output_file; if( (DATA_SENT > 0) && (DATA_RECV < DATA_SENT) ) printf( "Data loss= %.4f\n", 1 - ( DATA_RECV/DATA_SENT ) ) >> output_file; else { printf( "Data loss= 0\n") >> output_file; DATA_RECV=DATA_SENT; } if( (NACK_SENT > 0) && (NACK_RECV < NACK_SENT) ) printf( "NACK loss= %.4f\n", 1 - ( NACK_RECV/NACK_SENT ) ) >> output_file; else { printf( "NACK loss= 0\n" ) >> output_file; NACK_RECV=NACK_SENT; } if( (REF_SENT > 0) && (REF_RECV < REF_SENT) ) printf( "Refresh loss= %.4f\n", 1 - ( REF_RECV/REF_SENT ) ) >> output_file; else { printf( "Refresh loss= 0\n" ) >> output_file; REF_RECV=REF_SENT; } if( (RET_SENT > 0) && (RET_RECV < RET_SENT) ) printf( "Retransmission loss= %.4f\n", 1 - ( RET_RECV/RET_SENT ) ) >> output_file; else { printf( "Retransmission loss= 0\n" ) >> output_file; RET_RECV=RET_SENT; } packets_sent_sum=DATA_SENT + NACK_SENT + REF_SENT + RET_SENT; if( packets_sent_sum > 0 ) { packets_recv_sum=DATA_RECV + NACK_RECV + REF_RECV + RET_RECV; printf("Total packet loss= %.4f\n", 1 - (packets_recv_sum/packets_sent_sum) ) >> output_file; } printf("--------------------------------------------------\n") >> output_file; } tgif-QPL-4.2.5/rmcast/tools/scripts/README0000644000076400007640000000075410122646342020001 0ustar williamwilliamThe tgwb.sh is a script for tgwb configuration and start-up. The rmcastplot.bash script is intended to generate statistics from the logs written by the rmcast library. The script is self explanatory. Type its name to see how to use it. NOTE: You will need gnuplot to plot the data. The rmsg.sh and solarisrmsg.sh scripts are intended to release some system resources that can be locked due to a Rmcastlibrary crash. NOTE: You must be the owner of the resources to release them. tgif-QPL-4.2.5/rmcast/tools/scripts/rmsg.sh0000755000076400007640000000044210122646342020422 0ustar williamwilliam#!/bin/bash # This script removes everthing from your system message queue # For further information about message queue and other IPC features # look in the man pages ipcs -q | grep $USER | awk '{print $2}' > ~/list.id for i in `cat ~/list.id` do ipcrm msg $i done rm -f ~/list.id tgif-QPL-4.2.5/rmcast/src/0000755000076400007640000000000011602233155015051 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/src/rmwinmask.c0000644000076400007640000001520611141162245017230 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmwinmask.c ------------------- begin : Feb 2002 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifndef _RMWINMASK_C #include "rmwinmask.h" #ifdef SINGLE_NACK #define _RMWINMASK_C #include "rmcache.h" #include "rminternals.h" #include "rmstruct.h" #include #include #include #include #include #include #include #include pthread_mutex_t nak_window_mask_mutex = PTHREAD_MUTEX_INITIALIZER; /*********************** Routines to handle the window nack mask ************************************/ int window_mask_get_bit2(int *window_mask, int position) { int retval = -1; #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK window_mask_get_bit2: entering\n"); #endif if (position < MAX_WINDOW_SIZE) { #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK window_mask_get_bit2: inside if\n"); #endif pthread_mutex_lock(&nak_window_mask_mutex); #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK window_mask_get_bit2: inside if, after locking nak_window_mask_mutex\n"); #endif retval = window_mask[position]; pthread_mutex_unlock(&nak_window_mask_mutex); } #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK window_mask_get_bit2: leaving return=%d\n",retval); #endif return(retval); } /*************************************************************************************** * * int window_mask_sn_within_window(int *window_mask, int sn, MEMBER_STATUS *mstatus) * * Arguments: window_mask - pointer to the member's window mask; * sn - sn number; mstatus - pointer to the member's status structure; * * Return value: 1 on success; * 0 otherwise. * ***************************************************************************************/ int window_mask_sn_within_window(int *window_mask, int sn, MEMBER_STATUS *mstatus) { if ( sn > ( (mstatus->last_seq_rcv) + MAX_WINDOW_SIZE ) || sn < (mstatus->last_seq_rcv + 1) ) { return 0; } else { return 1; } } int window_mask_get_bit(int *window_mask, int sn, MEMBER_STATUS *mstatus) { int aux_position=0; int retval=-1; int out_retval=0; #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK window_mask_get_bit: Inside window_mask_get_bit\n"); fprintf(stderr,"DWINDOW_MASK window_mask_get_bit: mstatus=%p window_mask=%p sn=%d\n",mstatus,window_mask,sn); #endif if( (mstatus!=NULL) && (out_retval=window_mask_sn_within_window(window_mask, sn, mstatus))) { aux_position= ( mstatus->window_ini + ( sn - (mstatus->last_seq_rcv +1))) % MAX_WINDOW_SIZE; #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK window_mask_get_bit: aux_position=%d\n",aux_position); #endif retval=window_mask_get_bit2 ( mstatus->window_mask,aux_position ); } else { #ifdef DWINDOW_MASK if (out_retval==0) fprintf(stderr,"window_mask_get_bit Warning: sn=%d out of window!\n",sn); #endif }; return (retval); } int window_mask_set_bit2(int *window_mask, int position, int value) { int retval=1; #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK window_mask_set_bit2: position=%d value=%d\n",position,value); #endif if (position <= MAX_WINDOW_SIZE) { pthread_mutex_lock(&nak_window_mask_mutex); window_mask[position] = value; pthread_mutex_unlock(&nak_window_mask_mutex); retval=0; } return (retval); } int window_mask_set_bit(int *window_mask, int sn, MEMBER_STATUS *mstatus, int value) { int retval=0; #ifdef DWINDOW_MASK int l=0; int h=0; window_mask_array2numbers(window_mask,&h,&l,mstatus->window_ini); fprintf(stderr,"DWINDOW_MASK window_mask_set_bit: window_mask before h=%d l=%d \n",h,l); #endif if (window_mask_sn_within_window(window_mask, sn, mstatus)) { retval=window_mask_set_bit2( window_mask, ( mstatus->window_ini + ( sn - (mstatus->last_seq_rcv + 1 )) ) % MAX_WINDOW_SIZE, value ); #ifdef DWINDOW_MASK window_mask_array2numbers(window_mask,&h,&l,mstatus->window_ini); fprintf(stderr,"DWINDOW_MASK window_mask_set_bit: window_mask after h=%d l=%d \n",h,l); #endif } return retval; } int window_mask_numbers2array(int *window_mask, int hmask, int lmask) { int cont = 0; pthread_mutex_lock(&nak_window_mask_mutex); for (cont = 0; cont < min(MAX_WINDOW_SIZE,8*sizeof(int)); cont ++) { window_mask[ cont ] = (( lmask >> cont ) & 1 ); } for (cont = sizeof(int) * 8; cont < min(MAX_WINDOW_SIZE,2*8*sizeof(int)); cont ++) { window_mask[ cont ] = ( ( hmask >> (cont - (sizeof(int)*8)) ) & 1 ); } pthread_mutex_unlock(&nak_window_mask_mutex); return 1; } int window_mask_array2numbers(int *window_mask, int *hmask, int *lmask, int mask_ini) { int cont = 0; pthread_mutex_lock(&nak_window_mask_mutex); *lmask = 0; *hmask = 0; for (cont = 0; cont < min(MAX_WINDOW_SIZE,8*sizeof(int)); cont ++) { if (window_mask[ (cont + mask_ini)%MAX_WINDOW_SIZE ] == 1) { *lmask |= (1 << cont); } } for (cont = sizeof(int) * 8; cont < min(MAX_WINDOW_SIZE,2*8*sizeof(int)); cont ++) { if (window_mask[ (cont + mask_ini)%MAX_WINDOW_SIZE ] == 1) { *hmask |= 1 << (cont - sizeof(int) * 8); } } pthread_mutex_unlock(&nak_window_mask_mutex); return 1; } #endif /* SINGLE_NACK */ #endif /* _RMWINMASK_C */ tgif-QPL-4.2.5/rmcast/src/rminternals.h0000644000076400007640000001226611225226450017570 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rminternals.h ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifdef HAVE_CONFIG_H #include "../config.h" #endif #ifndef RMINTERNALS_H #define RMINTERNALS_H #define NUM_TIMERS 5 /* number of timers used by the program */ #define RECEIVE 'R' #define SEND 'S' #define RECEIVE_AND_LOSE 'L' #include "rmstruct.h" #include #include #include #include #include #include #include #include #include #include #include #include #include #include "rmmsgpckt.h" #include "rmevent.h" #include "rmcache.h" #include "rmmsg.h" #define FOREVER while(1) void *rmcastHandleSignals( void *arg ); int rmcastCreateSocket( int port ); void rmcastSetTTLValue( int soc, int ttl ); void rmcastSetLoopBack( int soc, int loop ); void rmcastJoinGroup( int soc, char *group_addr ); int rmcastLeaveGroup( int soc, char *group_addr ); int rmcastSendPacket( int soc, BYTE *message, int message_size ); void *rmcastReceivePackets( void *soc ); int rmcastCatchEvents( int i ); /****************************************************************************************************/ /* Routines To Facilitate the Interface with the Event List and the Cache */ int rmcastRemoveEvent( PACKET_INFO *packt, int event_type ); int rmcastFindEvent( PACKET_INFO *packt, int event_type ); int rmcastCacheContains( PACKET_INFO *packt ); int rmcastInsertEvent( PACKET_INFO *packt, int event_type ); void rmcastProcessDataPacket( PACKET_INFO pckt_info ); void rmcastProcessRefreshPacket( PACKET_INFO pckt_info ); double generate_uniform( void ); void lock_eventlist_and_cache(); void unlock_eventlist_and_cache(); void showLogMsg( char type, PACKET_INFO *pckt_info ); /****************************************************************************************************/ #define MAX_HOSTS 10 /* Maximum number of hosts which timers will be stored */ struct SHOSTS_DELAYS { char IP[IP_STRING_SIZE]; /* Host IP */ int estimated_delay; /* Estimated one-way delay to host */ }; typedef struct SHOSTS_DELAYS HOSTS_DELAYS; struct SGLOBAL_OPTIONS { int *pipe; char tcp_ip[ IP_STRING_SIZE ]; int tcp_port; void (*shut_down_routine)(void); int cur_state_server_is_up; char dest_ip[IP_STRING_SIZE]; /* this is the destination ip used in the connection to the multicast group (or unicast destination host) */ int dest_port; int ttl; unsigned int microsleep; int hosts_identified; int timer_distribution; int max_nak; /* max number of NAKs that can be sent for each sn */ /* * We will be able to retransmit the last max_member_cache_size packets from each member of the multicast group, * i.e., we will store the last max_member_cache_size packets from each member of the multicast group in the cache. */ int max_member_cache_size; int version; int transmission_mode; char log_file[ 255 ]; int new_member_support; int statistics; int refresh_timer; float loss_prob; int leave_group_wait_time; int rcv_buffer_size; HOSTS_DELAYS hosts_delays[ MAX_HOSTS ]; int timer_paramA; int timer_paramB; int timer_paramC; int timer_paramD; int timer_paramE; int timer_paramF; }; typedef struct SGLOBAL_OPTIONS GLOBAL_OPTIONS; /****************************************************************************************************/ struct SUSER_INFO { struct TIMER { int min,max; } timer[ NUM_TIMERS ]; struct GROUP_ID { char ip[ IP_STRING_SIZE ]; /* ip address and... */ int port; /* port of the group */ } group_id; MEMBER_ID member_id; int cache_size; int sn; int socket; }; typedef struct SUSER_INFO USER_INFO; /****************************************************************************************************/ #endif tgif-QPL-4.2.5/rmcast/src/rmstruct.h0000644000076400007640000001511511141162245017107 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmstruct.h ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifdef HAVE_CONFIG_H #include "../config.h" #endif #ifndef MSTRUCT_H #include #include #include #ifdef SOLARIS #include #endif #ifndef SOLARIS #define SOCKLEN_TYPE (socklen_t*) #else #define SOCKLEN_TYPE #endif #define MSTRUCT_H #ifdef SINGLE_NACK #define MAX_WINDOW_SIZE 64 #endif /* Transmission modes */ #define MULTICAST 0 #define UNICAST 1 /* Packet types */ #define DATA_PACKET_TYPE 1 #define RETRANSM_PACKET_TYPE 2 #define NAK_PACKET_TYPE 3 #define REFRESH_PACKET_TYPE 4 #define JOIN_REQUEST_PACKET_TYPE 5 #define JOIN_ACCEPT_PACKET_TYPE 6 #define LEAVE_GROUP_PACKET_TYPE 7 #define IP_STRING_SIZE 16 /* Member status in the cache */ #define CACHE_STATUS_DEACTIVE 0 #define CACHE_STATUS_ACTIVE 1 #define CACHE_STATUS_ANY 2 #ifndef TRUE #define TRUE 1 #define FALSE 0 #endif #ifdef RANDOM_TIMERS /* Distributions available for the random timers */ #define UNIFORM 0 #define EXPONENTIAL 1 #endif typedef unsigned char BYTE; /*************** members info *****************************************/ struct SMEMBER_ID { char ip[IP_STRING_SIZE]; /* ip address and... */ int pid; /* process id of the member */ }; typedef struct SMEMBER_ID MEMBER_ID; struct SMEMBER_STATUS { int first_rcv; /* first packet received from a specific member */ int last_rcv; /* last packet received from a specific member */ int last_seq_rcv; /* last packet received in the correct order from a specific member. Please, note that this is also used as the base for the sliding window used to restrict the sending of NACKs. See documentation for more details. */ int last_identified; /* last packet received, or to which a nack was sent */ #ifdef SINGLE_NACK int window_size; int window_mask[MAX_WINDOW_SIZE]; int window_ini; #endif }; typedef struct SMEMBER_STATUS MEMBER_STATUS; /************** session member information ***************************/ struct SSM_INFO { MEMBER_ID member_id; MEMBER_STATUS member_status; }; typedef struct SSM_INFO SM_INFO ; /**************** data packet info *************************************/ struct SDATA_PACKET { int sn; /* sequence number */ int data_size; /* number of data bytes */ BYTE *data; /* data to be sent or data received */ }; typedef struct SDATA_PACKET DATA_PACKET; /**************** cache info ******************************************/ struct SCACHE_NODE { DATA_PACKET data_pckt; struct SCACHE_NODE *next, *previous; /* pointers to next and previous nodes */ }; typedef struct SCACHE_NODE CACHE_NODE; struct SNAK_LIST { int sn; int counter; struct SNAK_LIST *previous; struct SNAK_LIST *next; }; typedef struct SNAK_LIST NAK_LIST; struct SCACHE { int number_of_nodes; /* number of nodes currently stored for a specific member */ int active; /* active == 0 means the member has left the multicast group */ SM_INFO sm_info; CACHE_NODE *first, /* pointer to the first of the packets stored for a specific member */ *last, /* pointer to the last of the packets stored for a specific member */ *last_inserted; /* pointer to the last of the packets inserted for a specific member */ NAK_LIST *nak_list; /* Pointer to nak list */ struct SCACHE *next; }; typedef struct SCACHE CACHE; /*************** events information**************************************/ struct SEVENT_LIST { MEMBER_ID *member_id; char action; /* action to be executed */ long timer_value; /* time when this action will be executed */ int sn; /* sequence number */ struct timeval last_update_time; /* Last time when the timer was updated */ struct SEVENT_LIST *next; }; typedef struct SEVENT_LIST EVENT_LIST; /*************** packet information**************************************/ struct SRETRANSM_PACKET { MEMBER_ID original_sender_id; DATA_PACKET data_packet; }; typedef struct SRETRANSM_PACKET RETRANSM_PACKET; struct SNAK_PACKET { MEMBER_ID requested_member_id; int sn; #ifdef SINGLE_NACK int base_sn; int window_size; int hmask, lmask; /* higher and lower parts of the mask, respectively */ #endif }; typedef struct SNAK_PACKET NAK_PACKET; struct SREFRESH_PACKET { int sn_of_last_msg_sent; /* sequence number of last message sent */ }; typedef struct SREFRESH_PACKET REFRESH_PACKET; struct SJOIN_ACCEPT_PACKET { int port; }; typedef struct SJOIN_ACCEPT_PACKET JOIN_ACCEPT_PACKET; struct SPACKET_INFO { char type; /* the type of the packet */ BYTE flags; /* flags field */ MEMBER_ID sender_id; /* id of the sender of the packet */ int packet_size; /* the size, in bytes, of the packet */ union PACKET_DATA { DATA_PACKET data_packet; RETRANSM_PACKET retransm_packet; NAK_PACKET nak_packet; REFRESH_PACKET refresh_packet; JOIN_ACCEPT_PACKET join_accept_packet; } packet_data; }; typedef struct SPACKET_INFO PACKET_INFO; /************************************************************************/ #endif tgif-QPL-4.2.5/rmcast/src/rmmsg.h0000644000076400007640000000351011222706507016352 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmmsg.h ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifdef HAVE_CONFIG_H #include "../config.h" #endif #ifndef MSG_H #define MSG_H #include #include #include #include #include #include #include #ifndef MSG_QUEUE_HEADER_SIZE #define MSG_QUEUE_HEADER_SIZE 2 /* number of bytes used to store the data size */ #endif extern int errno; #define MAXOBN 20000 #define MAXPRIOR 10 #define QPERM 0660 #define QKEY_BASE (key_t) 0105 struct q_entry { long mtype; char mtext[ MAXOBN + 1 ]; }; int init_queue(); int messageQueueEnter( char *objname, int len ); void remove_queues( int i ); #endif tgif-QPL-4.2.5/rmcast/src/rmcache.h0000644000076400007640000000476411222706507016643 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmcache.h ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifdef HAVE_CONFIG_H #include "../config.h" #endif #ifndef RMCACHE_H #define RMCACHE_H #include "rmstruct.h" #ifndef RMINTERNALS_H #include "rminternals.h" #endif void cacheInit(CACHE **cache); int cacheAllocHeaderNode(CACHE **cache, MEMBER_ID *member); int cacheAllocMessageNode(CACHE_NODE **cache_node, DATA_PACKET *node_info); int cacheFreeMessageNode(CACHE_NODE **node); int cacheInsertMessage(CACHE **cache, MEMBER_ID *member, DATA_PACKET *data_packet); CACHE *cacheInsertMember(CACHE **cache, MEMBER_ID *member); int cacheIsEmpty(CACHE **cache); int cacheOfAnyMemberIsFull(CACHE *cache); int memberIsEqual(MEMBER_ID *member1, MEMBER_ID *member2); CACHE *cacheLookForMember(CACHE **cache, MEMBER_ID *member_id); DATA_PACKET *cacheLookForMessage(CACHE **cache1, MEMBER_ID *member_id,int message_sn); int cacheDeactivateMember(CACHE *cache, MEMBER_ID *member); int cacheGetSMInfo(CACHE *cache, SM_INFO **sm_info, int *nusers); void cacheShow(CACHE *cache); int cacheUpdateNakList(CACHE **cache, MEMBER_ID *member, int sn); int cacheDeleteNakNode(CACHE *cache, MEMBER_ID *member, int sn); void cacheUnpack(CACHE **cache, char *buf, int buffsize); void cachePack(CACHE **cache, char **buf, int *buffsize); int cacheCountMembers( CACHE *cache, int member_required_status); #endif tgif-QPL-4.2.5/rmcast/src/rmtcp.h0000644000076400007640000000342111141162245016346 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmtcp.h ------------------- begin : 2002 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifdef HAVE_CONFIG_H #include "../config.h" #endif #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include "rmcast.h" #define MAXLINE 1000 #define LISTENQ 1000 int rmcastReceiveTCPStatus(char *ip, int port, CurStatus *cur_status); void * rmcastSendTCPStatus(void *arg); typedef struct sockaddr_in SA; tgif-QPL-4.2.5/rmcast/src/rmcast.h0000644000076400007640000000666611225226450016532 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmcast.h ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifndef RMCAST_H #define RMCAST_H #define RM_USE_CURRENT_CONFIG -1 #define PIPE 1 /* this option cannot figure in the config. file */ #define TCP_IP 2 /* this option cannot be modified by the user */ #define TCP_PORT 3 /* this option cannot be modified by the user */ #define SHUT_DOWN_ROUTINE 4 /* this option cannot figure in the config. file */ #define CUR_STATE_SERVER_IS_UP 5 /* this option cannot be modified by the user */ #define DEST_IP 6 #define DEST_PORT 7 #define TTL 8 #define MICROSLEEP 9 #define TIMER_DISTRIBUTION 10 #define MAX_NAK 11 #define MAX_MEMBER_CACHE_SIZE 12 #define RM_VERSION 13 /* still not used */ #define TRANSMISSION_MODE 14 #define LOG_FILE 15 #define NEW_MEMBER_SUPPORT 16 #define STATISTICS 17 /* still not used */ #define REFRESH_TIMER 18 #define LOSS_PROB 19 #define LEAVE_GROUP_WAIT_TIME 20 #define RCV_BUFFER_SIZE 21 #define HOSTS_IDENTIFIED 22 #define TIMER_PARAM_A 23 #define TIMER_PARAM_B 24 #define TIMER_PARAM_C 25 #define TIMER_PARAM_D 26 #define TIMER_PARAM_E 27 #define TIMER_PARAM_F 28 struct tagCurStatus { int size; char *data; }; typedef struct tagCurStatus CurStatus; int RM_initialize( void *callbackterm( void ) ); int RM_joinGroup( char *group, int port); void RM_leaveGroup( int sock, char *group); void RM_terminate( void ); int RM_sendto( int socket, void *buffer, int buffsize ); int RM_recv( int socket, void *buffer, int buffsize ); int RM_getCurStatus( char *group, int port, CurStatus *current_status ); int RM_sendCurStatus( int connfd, char *buff, int buffsize ); int RM_readConfigFile( char *filename, char show_config_file ); void RM_getOption( int opt, void *return_value ); void RM_setOption( int opt, void *optvalue ); int RM_setHostDelay( char *hostname, int estimated_one_way_delay ); int RM_getHostDelay( char *hostname, int *estimated_one_way_delay ); void RMDEBUG_setpidip( int pid, char *ip ); void RMDEBUG_setsn( int sn ); void RM_getVersion( char *buf, int buf_sz ); #endif tgif-QPL-4.2.5/rmcast/src/rmmsgpckt.c0000644000076400007640000005015311141162245017227 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmmsgpckt.c ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifndef RMMSGPCKT_C #define RMMSGPCKT_C #include #include #include #include #include "rmstruct.h" #include "rmmsgpckt.h" #define MIN(a,b) ((asender_id.pid); EXCHANGE_BYTE_ORDER(pckt_info->packet_size); switch (pckt_info->type) { case DATA_PACKET_TYPE: EXCHANGE_BYTE_ORDER(pckt_info->packet_data.data_packet.sn); EXCHANGE_BYTE_ORDER(pckt_info->packet_data.data_packet.data_size); break; case RETRANSM_PACKET_TYPE: EXCHANGE_BYTE_ORDER(pckt_info->packet_data.retransm_packet.original_sender_id.pid); EXCHANGE_BYTE_ORDER(pckt_info->packet_data.retransm_packet.data_packet.sn); EXCHANGE_BYTE_ORDER(pckt_info->packet_data.retransm_packet.data_packet.data_size); break; case NAK_PACKET_TYPE: EXCHANGE_BYTE_ORDER(pckt_info->packet_data.nak_packet.requested_member_id.pid); EXCHANGE_BYTE_ORDER(pckt_info->packet_data.nak_packet.sn); #ifdef SINGLE_NACK EXCHANGE_BYTE_ORDER(pckt_info->packet_data.nak_packet.base_sn); EXCHANGE_BYTE_ORDER(pckt_info->packet_data.nak_packet.window_size); EXCHANGE_BYTE_ORDER(pckt_info->packet_data.nak_packet.hmask); EXCHANGE_BYTE_ORDER(pckt_info->packet_data.nak_packet.lmask); #endif break; case REFRESH_PACKET_TYPE: EXCHANGE_BYTE_ORDER(pckt_info->packet_data.refresh_packet.sn_of_last_msg_sent); break; case LEAVE_GROUP_PACKET_TYPE: break; case JOIN_ACCEPT_PACKET_TYPE: EXCHANGE_BYTE_ORDER(pckt_info->packet_data.join_accept_packet.port); break; case JOIN_REQUEST_PACKET_TYPE: break; } } #endif /******************************************************************************************************* * * void msgPcktUnmountMessage(PACKET_INFO *pckt_info, BYTE *message) * * Unmount the message come from the network, filling PACKET_INFO structure with the apropriate values. * * Arguments: message, a pointer to the message to be unmounted (source of information); * pckt_info, a pointer to the target strucutre, which will hold the message info. * (this structure must have been previously allocated). * ******************************************************************************************************/ void msgPcktUnmountMessage(PACKET_INFO *pckt_info, BYTE *message) { #ifdef DEBUG_PCKT fprintf(stderr,"DEBUG_PCKT msgPcktUnmountMessage: [char: %d flag: %d MEMBER_ID: %d int: %d]\n", sizeof(char), sizeof(BYTE), /* Flags related */ sizeof(MEMBER_ID), sizeof(int)); #endif get(&(pckt_info->type),message,sizeof(char)); /* Flags related */ get(&(pckt_info->flags),message,sizeof(BYTE)); get(&(pckt_info->sender_id),message,sizeof(MEMBER_ID)); get(&(pckt_info->packet_size),message,sizeof(int)); switch (pckt_info->type) { case DATA_PACKET_TYPE: get(&(pckt_info->packet_data.data_packet.sn),message,sizeof(int)); get(&(pckt_info->packet_data.data_packet.data_size),message,sizeof(int)); (pckt_info->packet_data.data_packet.data)=(BYTE*)message; break; case RETRANSM_PACKET_TYPE: get(&(pckt_info->packet_data.retransm_packet.original_sender_id),message,sizeof(MEMBER_ID)); get(&(pckt_info->packet_data.retransm_packet.data_packet.sn),message,sizeof(int)); get(&(pckt_info->packet_data.retransm_packet.data_packet.data_size),message,sizeof(int)); (pckt_info->packet_data.retransm_packet.data_packet.data) = (BYTE*)message; break; case NAK_PACKET_TYPE: get(&(pckt_info->packet_data.nak_packet.requested_member_id),message,sizeof(MEMBER_ID)); get(&(pckt_info->packet_data.nak_packet.sn),message,sizeof(int)); #ifdef SINGLE_NACK get(&(pckt_info->packet_data.nak_packet.base_sn), message, sizeof(int)); get(&(pckt_info->packet_data.nak_packet.window_size),message, sizeof(int)); get(&(pckt_info->packet_data.nak_packet.hmask), message, sizeof(int)); get(&(pckt_info->packet_data.nak_packet.lmask), message, sizeof(int)); #endif break; #ifdef REFRESH case REFRESH_PACKET_TYPE: get(&(pckt_info->packet_data.refresh_packet.sn_of_last_msg_sent), message, sizeof(int)); break; #endif case LEAVE_GROUP_PACKET_TYPE: /* do nothing. We already have the sender id*/ break; case JOIN_ACCEPT_PACKET_TYPE: get(&(pckt_info->packet_data.join_accept_packet.port), message, sizeof(int)); break; case JOIN_REQUEST_PACKET_TYPE: break; default: fprintf(stderr,"Unknown packet type: %d\n",pckt_info->type); break; } #ifdef SOLARIS fprintf(stderr,"SOLARIS msgPcktUnmountMessage: That's SOLARIS so, excanching by order:\n[sender pid] "); fprintf(stderr,"%d %x\n",pckt_info->sender_id.pid,pckt_info->sender_id.pid); msgPcktExchangeByteOrder(pckt_info); fprintf(stderr,"SOLARIS msgPcktUnmountMessage: [sender pid]: %d %x\n",pckt_info->sender_id.pid,pckt_info->sender_id.pid); #endif #ifdef DEBUG_PCKT fprintf(stderr,"DEBUG_PCKT msgPcktUnmountMessage: returning\n"); #endif return; } /******************************************************************************************************* * * void msgPcktMountMessage(PACKET_INFO *pckt_info, BYTE **message, int *msgsize) * * Mount the message to be sent over the network, getting data from the PACKET_INFO structure. * * Arguments: pckt_info, a pointer to the source structure, from which data will be retrieved; * message, a pointer to the message to be mounted - * (the space needed to store the message will be allocated as necessary); * msgsize, a pointer to an integer which will return the effective size of the message. * ******************************************************************************************************/ void msgPcktMountMessage(PACKET_INFO *pckt_info, BYTE **message, int *msgsize) { BYTE *aux_message_pt; BYTE *common_header; int *sn_pointer; int common_header_size; int msg_specific = 0, data_size = 0; int packet_size = 0; #ifdef DEBUG_PCKT fprintf(stderr,"DEBUG_PCKT msgPcktMountMessage: mounting packet\n"); #endif #ifdef SOLARIS fprintf(stderr,"That's SOLARIS so, excanching by order:\n[sender pid] "); fprintf(stderr,"%d %x\n",pckt_info->sender_id.pid,pckt_info->sender_id.pid); msgPcktExchangeByteOrder(pckt_info); #endif #ifdef DEBUG_PCKT fprintf(stderr,"DEBUG_PCKT msgPcktMountMessage: [sender pid] "); fprintf(stderr,"%d %x\n",pckt_info->sender_id.pid,pckt_info->sender_id.pid); #endif /* info about type of the message, sender_id and packet_size */ common_header_size= sizeof(char)+sizeof(BYTE)+sizeof(MEMBER_ID)+sizeof(int); /* sizeof(BYTE) is Flags related */ common_header = (BYTE*)malloc(common_header_size); aux_message_pt = common_header; #ifdef DEBUG_PCKT fprintf(stderr,"DEBUG_PCKT msgPcktMountMessage:common_header allocated at: %p\n", common_header); #endif /* Flags are not used by now, so we just set it to zero */ pckt_info->flags='0'; getPCKInfo(aux_message_pt, &(pckt_info->type), sizeof(char)); /* Flags related */ getPCKInfo(aux_message_pt, &(pckt_info->flags), sizeof(BYTE)); getPCKInfo(aux_message_pt, &(pckt_info->sender_id), sizeof(MEMBER_ID)); getPCKInfo(aux_message_pt, &(pckt_info->packet_size), sizeof(int)); packet_size = 0; /* specific info plus data */ switch(pckt_info->type) { case DATA_PACKET_TYPE: msg_specific = sizeof(DATA_PACKET)-sizeof(BYTE*); data_size = (pckt_info)->packet_data.data_packet.data_size; (*message) = (BYTE*)malloc(common_header_size+msg_specific+data_size); aux_message_pt = *message; getPCKInfo(aux_message_pt,common_header,common_header_size); sn_pointer = (int*)aux_message_pt; getPCKInfo(aux_message_pt,&(pckt_info->packet_data.data_packet.sn), sizeof(int)); getPCKInfo(aux_message_pt,&(pckt_info->packet_data.data_packet.data_size), sizeof(int)); getPCKInfo(aux_message_pt, (pckt_info->packet_data.data_packet.data), data_size); break; case RETRANSM_PACKET_TYPE: msg_specific = sizeof(RETRANSM_PACKET)-sizeof(BYTE*); data_size = sizeof(BYTE)*(pckt_info)->packet_data.retransm_packet.data_packet.data_size; (*message) = (BYTE*)malloc(common_header_size+msg_specific+data_size); aux_message_pt = *message; getPCKInfo(aux_message_pt,common_header,common_header_size); getPCKInfo(aux_message_pt,(void*)(&(pckt_info->packet_data.retransm_packet)), msg_specific); getPCKInfo(aux_message_pt,(pckt_info->packet_data.retransm_packet.data_packet.data), data_size); break; case NAK_PACKET_TYPE: (*message) = (BYTE*)malloc(common_header_size+sizeof(NAK_PACKET)); aux_message_pt = *message; getPCKInfo(aux_message_pt,common_header,common_header_size); getPCKInfo(aux_message_pt, &(pckt_info->packet_data.nak_packet.requested_member_id), sizeof(MEMBER_ID)); getPCKInfo(aux_message_pt, &(pckt_info->packet_data.nak_packet.sn), sizeof(int)); #ifdef SINGLE_NACK getPCKInfo(aux_message_pt, &(pckt_info->packet_data.nak_packet.base_sn), sizeof(int)); getPCKInfo(aux_message_pt, &(pckt_info->packet_data.nak_packet.window_size), sizeof(int)); getPCKInfo(aux_message_pt, &(pckt_info->packet_data.nak_packet.hmask), sizeof(int)); getPCKInfo(aux_message_pt, &(pckt_info->packet_data.nak_packet.lmask), sizeof(int)); #endif break; #ifdef REFRESH case REFRESH_PACKET_TYPE: (*message) = (BYTE*)malloc(common_header_size+sizeof(int)); aux_message_pt = *message; getPCKInfo(aux_message_pt,common_header,common_header_size); getPCKInfo(aux_message_pt, &(pckt_info->packet_data.refresh_packet.sn_of_last_msg_sent), sizeof(int)); break; #endif case LEAVE_GROUP_PACKET_TYPE: (*message) = (BYTE*)malloc(common_header_size); aux_message_pt = *message; getPCKInfo(aux_message_pt,common_header,common_header_size); /* do nothing. The packet is already built */ break; case JOIN_ACCEPT_PACKET_TYPE: (*message) = (BYTE*)malloc(common_header_size+sizeof(int)); aux_message_pt = *message; getPCKInfo(aux_message_pt,common_header,common_header_size); getPCKInfo(aux_message_pt, &(pckt_info->packet_data.join_accept_packet.port), sizeof(int)); break; case JOIN_REQUEST_PACKET_TYPE: (*message) = (BYTE*)malloc(common_header_size); aux_message_pt = *message; getPCKInfo(aux_message_pt,common_header,common_header_size); break; default: fprintf(stderr,"DEBUG_PCKT msgPcktMountMessage: Unknown packet type: %d\n",pckt_info->type); } packet_size++; aux_message_pt = *message + sizeof(char) + sizeof(BYTE) + sizeof(MEMBER_ID); memcpy(aux_message_pt, &packet_size,sizeof(int)); *msgsize = packet_size; #ifdef DEBUG_PCKT { int cont; fprintf(stderr,"DEBUG_PCKT msgPcktMountMessage: Mounted message: \n"); for (cont = 0; cont < packet_size; cont++) { fprintf(stderr,"%d ", ((signed char*)(*message))[cont]); } } fprintf(stderr,"\nhere\n"); msgPcktShowMessage((BYTE*)*message) ; #endif free (common_header); } #endif tgif-QPL-4.2.5/rmcast/src/rmmsgpckt.h0000644000076400007640000000303511141162245017231 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmmsgpckt.h ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifdef HAVE_CONFIG_H #include "../config.h" #endif #define NUMBER_OF_MESSAGE_TYPES 20 extern char *MESSAGE_TYPE_NAME[NUMBER_OF_MESSAGE_TYPES]; void msgPcktShowMessage(BYTE *message); void msgPcktUnmountMessage(PACKET_INFO *pckt_info, BYTE *message); void msgPcktMountMessage(PACKET_INFO *pckt_info, BYTE **message, int *msgsize); tgif-QPL-4.2.5/rmcast/src/rmevent.h0000644000076400007640000000536211141162245016707 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmevent.h ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifdef HAVE_CONFIG_H #include "../config.h" #endif #ifndef RMEVENT_H #define RMEVENT_H #include #include "rmstruct.h" #define NAK_SND_WAIT 1 /* Waiting to send a NAK */ #define RET_RCV_WAIT 2 /* Waiting to receive a retransmission */ #define RET_SND_WAIT 3 /* Waiting to send a retransmission */ #define REF_SND_WAIT 4 /* Waiting to send a refresh message */ #define LEV_GRP_WAIT 5 /* Waiting to leave the multicast group */ #ifdef SINGLE_NACK /* Special actions for SINGLE NACK */ #define SUPPRESSED_NAK 6 /* Intermediate state between NAK_SND_WAIT and RET_RCV_WAIT */ #define RET_RCV_EXPIRED 7 /* Event RET_RCV_WAIT has expired create NAK_SND_WAIT event */ #endif void eventListInit(EVENT_LIST **el); int eventListAllocNode(EVENT_LIST **el_node, MEMBER_ID *member, char action, int sn, long timer_value); int eventListInsert(EVENT_LIST **el, MEMBER_ID *member_id, char *sender_ip, char action, int sn); void eventListShow(EVENT_LIST *el); int eventListRemove(EVENT_LIST **el, MEMBER_ID *member_id, char action, int sn); int eventListRemoveFirst(EVENT_LIST **el); EVENT_LIST * eventListFind(EVENT_LIST **el,MEMBER_ID *member_id, char action, int sn, EVENT_LIST **antNode); int eventListIsEqual(EVENT_LIST *node1, EVENT_LIST *node2); float generateSample(char distribution); int generateTimerValue(char action, char distribution, char *sender_ip); void setTimerValue(struct itimerval *value, long int time); long double getTimerValue(/* struct itimerval *value */ struct timeval *value); #endif tgif-QPL-4.2.5/rmcast/src/rmwinmask.h0000644000076400007640000000530011141162245017227 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmwinmask.h ------------------- begin : Feb 2002 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifdef HAVE_CONFIG_H #include "../config.h" #endif #ifndef _RMWINMASK_H #define _RMWINMASK_H #include "rmcache.h" #include "rminternals.h" #include "rmstruct.h" #include #include #include #include #include #include #include #include extern pthread_mutex_t nak_window_mask_mutex; /*********************** Routines to handle the window nack mask ************************************/ #define min(a,b) ( ( (a)<(b))?a:b ) #define MAX_WINDOW_SIZE 64 int window_mask_get_bit2(int *window_mask, int position); int window_mask_sn_within_window(int *window_mask, int sn, MEMBER_STATUS *mstatus); int window_mask_get_bit(int *window_mask, int sn, MEMBER_STATUS *mstatus); int window_mask_set_bit2(int *window_mask, int position, int value); int window_mask_set_bit(int *window_mask, int sn, MEMBER_STATUS *mstatus, int value); int window_mask_numbers2array(int *window_mask, int hmask, int lmask); int window_mask_array2numbers(int *window_mask, int *hmask, int *lmask, int mask_ini); #define SHOW for( i = MAX_WINDOW_SIZE - 1; i >= 0 ; i--) \ {\ fprintf(stderr,"%d", c->sm_info.member_status.window_mask[ i ] );\ if ( i == c->sm_info.member_status.window_ini )\ fprintf ( stderr, "}" );\ if ( i == c->sm_info.member_status.window_ini + c->sm_info.member_status.window_size ) \ fprintf ( stderr, "{" ); \ }\ fprintf(stderr,"\n"); #endif tgif-QPL-4.2.5/rmcast/src/rmcast.c0000644000076400007640000012016711225226450016516 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmcast.c ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifndef RMCAST_C #define RMCAST_C #include #include #include #include #include #include #include #include #include #ifdef LINUX #include #include //where if_nameindex() was hiding #include //for ioctl() arg #endif #include "rmcast.h" #include "rminternals.h" #include "rmtcp.h" #ifdef SOLARIS int siginterrupt( int sig, int flag ) { struct sigaction act; (void)sigaction( sig, NULL, &act ); if( flag ) act.sa_flags &= ~SA_RESTART; else act.sa_flags |= SA_RESTART; return sigaction( sig, &act, NULL); } #endif pthread_t rcv_thread, signal_handler_thread; extern int h_errno; extern EVENT_LIST *event_list; extern CACHE *cache; extern USER_INFO local_user_info; extern sigset_t alrmset; extern FILE *logfile; extern GLOBAL_OPTIONS rmcast_options; void (*callback_terminate)( void ); #ifdef DSUPPRESSION FILE *suppressionfile; #endif time_t seed; static int r_qid = -1; /* message queue identifier */ static int initialized = 0; /* flag that specifies if the user is connected to the multicast group. It may also be read as: did the user try to get the current state?*/ static int sent_packets = 0; /* To count the number of packets sent by the member */ #ifdef SOLARIS pthread_mutex_t change_local_user_sn; #else pthread_mutex_t change_local_user_sn = PTHREAD_MUTEX_INITIALIZER; #endif /******************************************************************************* * * void RM_readConfigFile(char *filename, char show_config_file) * * Reads configuration file indicated by filename * * Parameters: filename, name of the configuration file. * show_config_file, 1 shows config file contents in stdout * 0 does not show config file contents * * Returns: 1, if config file reading was OK; * 0, otherwise * ******************************************************************************/ int RM_readConfigFile( char *filename, char show_config_file ) { FILE *fpin = NULL; int i, j, aux_estimated_delay, optionnumber, host_counter = -1; char option[ 255 ], value[ 255 ], trash[ 4 ]; char line[ 255 ]; char aux_host_name[ 255 ]; int retval = FALSE; fpin = fopen( filename, "r" ); if( fpin != NULL ) { retval = TRUE; if( show_config_file == TRUE ) { fprintf( stdout, "RELIABLE MULTICAST LIBRARY\n\n" ); fprintf( stdout, "---- Reading configuration file ----\n" ); } fgets( line, 255, fpin ); while( !feof( fpin ) && ( retval==1 ) ) { i = sscanf( line, " %[^=# ] %[=#] %s", option, trash, value ); if( i != 3 || trash[ 0 ] == '#' ) { // fprintf( stderr, "skiping line (%d)\n", i ); } else { if( show_config_file == TRUE ) fprintf( stdout, "%s=%s\n", option, value ); if( strcmp( option, "DEST_IP" ) == 0 ) optionnumber = DEST_IP; else if( strcmp( option, "DEST_PORT" ) == 0 ) optionnumber = DEST_PORT; else if( strcmp( option, "TTL" ) == 0 ) optionnumber = TTL; else if( strcmp( option, "MICROSLEEP" ) == 0 ) optionnumber = MICROSLEEP; else if( strcmp( option, "TIMER_PARAM_A" ) == 0 ) optionnumber = TIMER_PARAM_A; else if( strcmp( option, "TIMER_PARAM_B" ) == 0 ) optionnumber = TIMER_PARAM_B; else if( strcmp( option, "TIMER_PARAM_C" ) == 0 ) optionnumber = TIMER_PARAM_C; else if( strcmp( option, "TIMER_PARAM_D" ) == 0 ) optionnumber = TIMER_PARAM_D; else if( strcmp( option, "TIMER_PARAM_E" ) == 0 ) optionnumber = TIMER_PARAM_E; else if( strcmp( option, "TIMER_PARAM_F" ) == 0 ) optionnumber = TIMER_PARAM_F; else if( strcmp( option, "HOSTS_IDENTIFIED" ) == 0 ) optionnumber = HOSTS_IDENTIFIED; else if( strcmp( option, "TIMER_DISTRIBUTION" ) == 0 ) optionnumber = TIMER_DISTRIBUTION; else if( strcmp( option, "MAX_NAK" ) == 0 ) optionnumber = MAX_NAK; else if( strcmp( option, "MAX_MEMBER_CACHE_SIZE" ) == 0 ) optionnumber = MAX_MEMBER_CACHE_SIZE; else if( strcmp( option, "RM_VERSION" ) == 0 ) optionnumber = RM_VERSION; else if( strcmp( option, "TRANSMISSION_MODE" ) == 0 ) optionnumber = TRANSMISSION_MODE; else if( strcmp( option, "LOG_FILE" ) == 0 ) optionnumber = LOG_FILE; else if( strcmp( option, "NEW_MEMBER_SUPPORT" ) == 0 ) optionnumber = NEW_MEMBER_SUPPORT; else if( strcmp( option, "STATISTICS" ) == 0 ) optionnumber = STATISTICS; else if( strcmp( option, "REFRESH_TIMER" ) == 0 ) optionnumber = REFRESH_TIMER; else if(strcmp( option, "LOSS_PROB" ) == 0 ) optionnumber = LOSS_PROB; else if(strcmp( option, "LEAVE_GROUP_WAIT_TIME" ) == 0 ) optionnumber = LEAVE_GROUP_WAIT_TIME; else if( strcmp( option, "RCV_BUFFER_SIZE" ) == 0 ) optionnumber = RCV_BUFFER_SIZE; else { fprintf( stderr, "RM_readConfigFile Warning - Invalid option in input file: %s", line ); fgets( line, 255, fpin ); continue; } switch( optionnumber ) { case LOG_FILE: case DEST_IP: RM_setOption( optionnumber, (void*)value ); break; case HOSTS_IDENTIFIED: host_counter = atoi( value ); if( ( host_counter > -1 ) && ( host_counter < MAX_HOSTS ) ) { fgets( line, 255, fpin ); for( j = 0; j <= host_counter; j++ ) { if( !feof( fpin ) ) { sscanf( line, "%s %d", aux_host_name, &aux_estimated_delay ); if( RM_setHostDelay( aux_host_name, aux_estimated_delay ) > 0 ) { if( ( show_config_file == TRUE ) && ( RM_getHostDelay( aux_host_name, &aux_estimated_delay ) == 1 ) ) { fprintf( stdout, "%s %d\n", aux_host_name, aux_estimated_delay ); } } else { fprintf( stderr, "RM_readConfigFile Error: Unknown host %s\n", aux_host_name ); retval = FALSE; break; } } else { fprintf( stderr, "RM_readConfigFile Error reading timers in config file" ); retval = FALSE; } fgets( line, 255, fpin ); } host_counter=-1; } break; default: RM_setOption( optionnumber, (void*)atoi( value ) ); } } fgets( line, 255, fpin ); } if( ( show_config_file == TRUE ) && ( retval == TRUE ) ) fprintf( stdout, "----- Configuration file OK.-----\n\n" ); fclose( fpin ); } return retval; } /******************************************************************************* * * void RM_initialize() * * Initializes internal structures (cache, event list and message queue) and * local user information (ip, pid and sn). * * Parameters: no parameteres. * Returns: 1, on success; * 0, on error. * ******************************************************************************/ #ifdef SOLARIS int gethostname( char *name, int namelen ); #endif int RM_initialize( void *callbackterm( void ) ) { int i; char localhost_ip[ IP_STRING_SIZE ], localhost_name[ 31 ]; struct timeval tv; struct timezone tz; #ifdef LINUX int auxsock = 0; struct ifreq ifreq; struct sockaddr_in *saptr = NULL; struct if_nameindex *iflist = NULL, *listsave = NULL; #else struct hostent *localhost_ent; #endif /* LINUX */ callback_terminate = (void *)callbackterm; /* * #ifdef SOLARIS * * sigset_t alrmset; * * sigfillset(&alrmset); * * * * pthread_sigmask(SIG_BLOCK, &alrmset, NULL); * * pthread_mutex_init(&change_local_user_sn,NULL); * * #endif */ /* Create seed for random numbers generation */ gettimeofday( &tv, &tz ); seed = time( (time_t *)&tv.tv_sec ); srandom( (unsigned int)seed ); rmcast_options.cur_state_server_is_up = 0; initialized = 0; if( ( rmcast_options.log_file[ 0 ] != 0 ) && ( strcmp( rmcast_options.log_file, "NULL" ) != 0 ) ) { if( ( logfile = fopen( rmcast_options.log_file,"w" ) ) == NULL ) { fprintf( stderr, "RM_initialize Error: could not open %s.", rmcast_options.log_file ); return 0; } if( setvbuf( logfile, NULL, _IONBF, 0 ) != 0 ) fprintf( stderr, "RM_initialize ERROR: setvbuf failed.\n" ); } else { logfile = NULL; } #ifdef DSUPPRESSION if( ( suppressionfile = fopen("log.suppression","w") ) == NULL ) { fprintf( stderr, "RM_initialize Error: could not open 'log.suppression'." ); return 0; } #endif for( i=0; i < IP_STRING_SIZE; i++ ) localhost_ip[ i ] = 0; /* localhost_ip <- local ip */ gethostname( localhost_name, 30 ); if( logfile != NULL ) { fprintf( logfile, "host: %s\n", localhost_name ); } #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_initialize: local host name: %s\n", localhost_name ); #endif #ifdef LINUX /* need a socket for ioctl() */ if( ( auxsock = socket( AF_INET, SOCK_STREAM, 0 ) ) < 0 ) { perror( "RM_initialize: socket for ioctl" ); return 0; } /* returns pointer to dynamically allocated list of structs */ iflist = listsave = if_nameindex(); /* walk thru the array returned and query for each */ /* interface's address */ for( ; *(char *)iflist != 0; iflist++ ) { /* copy in the interface name to look up address of */ strncpy( ifreq.ifr_name, iflist->if_name, IF_NAMESIZE ); /* get the address for this interface */ if( ioctl( auxsock, SIOCGIFADDR, &ifreq ) < 0 ) { if( errno =! 99 ) { perror( "RM_initialize: ioctl" ); return 0; } } /* Take a valid address */ saptr = (struct sockaddr_in *)&ifreq.ifr_addr; strcpy( localhost_ip, inet_ntoa( saptr->sin_addr ) ); /* Take the first ip different from 127.0.0.1 */ if( strcmp( "127.0.0.1", localhost_ip ) != 0 ) break; } /* free the dynamic memory kernel allocated for us */ if_freenameindex( listsave ); #else localhost_ent = gethostbyname( localhost_name ); if( localhost_ent != NULL ) { strcpy( localhost_ip, inet_ntoa( *((struct in_addr*)(localhost_ent->h_addr_list[ 0 ])) ) ); } else { fprintf (stderr, "RM_initialize ERROR: Unable to resolve host name: %s\n", localhost_name ); return 0; } #endif /* LINUX */ /* initialization of the local cache, event list and message queue */ cacheInit( &cache ); eventListInit( &event_list ); if( ( r_qid == -1 ) && ( r_qid = init_queue() ) == -1 ) { fprintf( stderr, "RM_initialize ERROR: Couldn't create message queue.\n" ); return 0; } /* initialization of local user info */ pthread_mutex_lock( &change_local_user_sn ); local_user_info.sn = 0; pthread_mutex_unlock( &change_local_user_sn ); local_user_info.member_id.pid = (int)getpid(); strncpy( local_user_info.member_id.ip, localhost_ip, IP_STRING_SIZE ); if( logfile != NULL ) { fprintf( logfile, "ip: %s\n", localhost_ip ); fprintf( logfile, "pid: %d\n", local_user_info.member_id.pid ); fprintf( logfile, "---------------------------------------------------------------------------------------------------------------------------\n" ); fprintf( logfile, "Time Snd/Rcv/Loss type sender_ip sender_pid requested_ip requested_pid sn [{base sn} {win size} {hmask} {lmask}]\n" ); fprintf( logfile, "---------------------------------------------------------------------------------------------------------------------------\n" ); } #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_initialize: local host ip: %s\n", localhost_ip ); #endif return 1; } #ifdef SUPPORT_FOR_NEW_MEMBERS static void recvfrom_alarm( int signo ) { /* just interrupt the recvfrom() */ return; } #endif /******************************************************************************* * * int RM_getCurStatus (char *group, int port, CurStatus *c) * * When this routine is used, RM_initialize must have been called at least once. * * Sets up multicast group information, creates the thread responsible for receiving * packets and activates the alarm responsible for catching events from the event list. * If the CurState parameter is different from NULL, the current state of the multicast * group will be catched. * * Parameters: group, the multicast group ip; * port, the multicast group port; * c_status, pointer to the location where the current state of * the multicast group will be stored. * * Returns: the socket created. If c is not equal to NULL, it will point to the current * state of the group. * ******************************************************************************/ pthread_t pthread_cur_state_server; #ifndef SOLARIS #define SOCKLEN_TYPE (socklen_t*) #else #define SOCKLEN_TYPE #endif #ifdef SOLARIS int siginterrupt( int sig, int flag ); #endif int RM_getCurStatus( char *group1, int port1, CurStatus *current_status ) { #ifdef SOLARIS sigset_t alrmset; #endif char *group; int port; if( ( (int)group1 ) == RM_USE_CURRENT_CONFIG ) { group = rmcast_options.dest_ip; } else { group = group1; } if( ( (int)port1 ) == RM_USE_CURRENT_CONFIG ) { port = rmcast_options.dest_port; } else { port = port1; } /* Now, we are setting the multicast info (multicast port and multicast ip), */ local_user_info.group_id.port = port ; strncpy( local_user_info.group_id.ip, group, IP_STRING_SIZE ); local_user_info.socket = rmcastCreateSocket( port ); rmcastJoinGroup( local_user_info.socket, group ); if( logfile != NULL ) fprintf( logfile, "joined to group\n" ); #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_getCurStatus: joined to group\n" ); #endif #ifdef SUPPORT_FOR_NEW_MEMBERS if( current_status != NULL ) { char *buffer; int buffsize; int timeout; int len, nbytes; char message[ rmcast_options.rcv_buffer_size ]; CurStatus retval; PACKET_INFO pckt_info; struct sockaddr sender; timeout = 0; pckt_info.type = JOIN_REQUEST_PACKET_TYPE; pckt_info.flags = 0; pckt_info.sender_id = local_user_info.member_id; pckt_info.packet_size = 0; msgPcktMountMessage( &pckt_info, (BYTE**)&buffer, &buffsize ); msgPcktShowMessage( (BYTE*)buffer ); if ( rmcastSendPacket( local_user_info.socket, (BYTE*)buffer, buffsize ) == 0 ) { current_status = NULL; return 0; } /* waiting to receive a "join accept packet" */ #ifdef SOLARIS /* * sigemptyset( &alrmset ); * sigaddset ( &alrmset, SIGALRM ); * * pthread_sigmask( SIG_UNBLOCK, &alrmset, NULL ); */ #endif siginterrupt( SIGALRM, 1 ); /* please, see siginterrupt(3) */ if( signal( SIGALRM, recvfrom_alarm ) == SIG_ERR ) { fprintf( stderr,"RM_getCurStatus ERROR: alarm failed" ); current_status = NULL; return 0; } alarm( 2 ); #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_getCurStatus: Waiting for a 'join accept message'\n"); #endif do { static int first = 1; #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_getCurStatus: Still waiting for a 'join accept message'\n" ); #endif if( !first ) first = 0; bzero( message, rmcast_options.rcv_buffer_size ); len = sizeof( struct sockaddr_in ); if( ( nbytes = (int)recvfrom( local_user_info.socket, message, rmcast_options.rcv_buffer_size, 0, (struct sockaddr *) &sender, SOCKLEN_TYPE &len )) < 0 ) { if( errno != EINTR ) continue; } if( nbytes > 0 ) { #ifdef DEBUG_PCKT { int cont; fprintf( stderr, "DEBUG_PCKT RM_getCurStatus: Received message: \n" ); for( cont = 0; cont < nbytes; cont++ ) { fprintf( stderr, "%d [%c] ", ((signed char*)(message))[ cont ], (message)[ cont ] ); } } #endif msgPcktUnmountMessage( &pckt_info, (BYTE*)message ); #ifdef DEBUG_SHOW fprintf( stderr, "DEBUG_SHOW RM_getCurStatus: Showing message:\n" ); msgPcktShowMessage( (BYTE*)message ); #endif if( !memberIsEqual( &local_user_info.member_id, &pckt_info.sender_id) ) timeout=0; } else { timeout = 1; pckt_info.type = -1; } } while( ( pckt_info.type != JOIN_ACCEPT_PACKET_TYPE ) && ( timeout == 0 ) ); siginterrupt( SIGALRM, 0 ); /* the default behaviour in Linux */ #ifdef SOLARIS /* * sigemptyset( &alrmset ); * sigaddset ( &alrmset, SIGALRM ); * * * pthread_sigmask( SIG_BLOCK, &alrmset, NULL ); */ #endif if( !timeout ) { #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_getCurStatus: 'join accept packet' received\n" ); #endif if( rmcastReceiveTCPStatus( pckt_info.sender_id.ip, pckt_info.packet_data.join_accept_packet.port, &retval ) == FALSE ) { #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_getCurStatus: TCP status received\n" ); #endif retval.size = -1; } } else { #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_getCurStatus: timer expired probably I'm the first of the group!\n" ); #endif retval.size = -1; } *current_status = retval; } #endif #ifndef SOLARIS sigfillset(&alrmset); sigdelset(&alrmset, SIGTSTP); pthread_sigmask(SIG_BLOCK, &alrmset, NULL); #endif #ifdef SUPPORT_FOR_NEW_MEMBERS if( pthread_create( &pthread_cur_state_server, NULL, rmcastSendTCPStatus, NULL ) != 0 ) fprintf( stderr, "RM_getCurStatus ERROR: Couldn't create the new thread to send the current status: the 'current status server'\n" ); else rmcast_options.cur_state_server_is_up = 1; #endif initialized = 1; return local_user_info.socket; } /******************************************************************************* * * int RM_joinGroup (char *group, int port) * * When this routine is used, RM_initialize must have been called at least once. * * Sets up multicast group information, creates the thread responsible for receiving * packets and activates the alarm responsible for catching events from the event list. * * Parameters: group, the multicast group ip; * port, the multicast group port; * * Returns: the socket created. If c is not equal to NULL, it will point to the current * state of the group. * ******************************************************************************/ int RM_joinGroup( char *group1, int port1 ) { #ifdef SOLARIS sigset_t alrmset; #endif char *group; int port; if( (int)group1 == RM_USE_CURRENT_CONFIG ) group = rmcast_options.dest_ip; else group = group1; if( (int)port1 == RM_USE_CURRENT_CONFIG ) port = rmcast_options.dest_port; else port = port1; #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_joinGroup: %s initialized, will try to get the current state.\n", initialized?"":"not" ); #endif if( !initialized ) RM_getCurStatus( group, port, NULL ); /* creating the thread responsible for receiving packets */ pthread_create( &rcv_thread, NULL, rmcastReceivePackets, (void*)local_user_info.socket ); /* creating the signal handler thread */ pthread_create( &signal_handler_thread, NULL, rmcastHandleSignals, NULL ); return local_user_info.socket; } int RM_sendCurStatus( int connfd, char *buff, int buffsize ) { /* FIXME: this routine may consume a lot of time * it's necessary to implement it as a new thread or process */ int n; char *packed_cache; int cache_size; write( connfd, &buffsize, sizeof(int) ); n = write( connfd, buff, buffsize ); if( n < 0 ) perror( "RM_SendCurStatus ERROR: write error" ); #ifdef DEBUG_SHOW fprintf( stderr, "DEBUG_SHOW RM_SendCurStatus: Showing the cache...\n" ); cacheShow( cache ); #endif cachePack( &cache, &packed_cache, &cache_size ); write( connfd, &cache_size, sizeof(int) ); n = write( connfd, packed_cache, cache_size ); if( n < 0 ) perror( "RM_SendCurStatus ERROR: write error" ); close( connfd ); return n; } void RM_getOption( int opt, void *return_value ) { switch( opt ) { case NEW_MEMBER_SUPPORT: *((int *)return_value) = rmcast_options.new_member_support; break; case DEST_IP: strcpy( (char *)return_value, rmcast_options.dest_ip ); break; case DEST_PORT: *((int *)return_value) = rmcast_options.dest_port; break; case TTL: *((int *)return_value) = rmcast_options.ttl; break; case MICROSLEEP: *((unsigned int *)return_value) = rmcast_options.microsleep; break; case TIMER_PARAM_A: *((int *)return_value) = rmcast_options.timer_paramA; break; case TIMER_PARAM_B: *((int *)return_value) = rmcast_options.timer_paramB; break; case TIMER_PARAM_C: *((int *)return_value) = rmcast_options.timer_paramC; break; case TIMER_PARAM_D: *((int *)return_value) = rmcast_options.timer_paramD; break; case TIMER_PARAM_E: *((int *)return_value) = rmcast_options.timer_paramE; break; case TIMER_PARAM_F: *((int *)return_value) = rmcast_options.timer_paramF; break; case HOSTS_IDENTIFIED: *((int *)return_value) = rmcast_options.hosts_identified; break; case TIMER_DISTRIBUTION: *((int *)return_value) = rmcast_options.timer_distribution; break; case MAX_NAK: *((int *)return_value) = rmcast_options.max_nak; break; case MAX_MEMBER_CACHE_SIZE: *((int *)return_value) = rmcast_options.max_member_cache_size; break; case RM_VERSION: *((int *)return_value) = rmcast_options.version; break; case TRANSMISSION_MODE: *((int *)return_value) = rmcast_options.transmission_mode; break; case LOG_FILE: strcpy( (char *)return_value, rmcast_options.log_file ); break; case STATISTICS: *((int *)return_value) = rmcast_options.statistics; break; case REFRESH_TIMER: *((int *)return_value) = rmcast_options.refresh_timer; break; case LOSS_PROB: *((int *)return_value) = rmcast_options.loss_prob*100; break; case LEAVE_GROUP_WAIT_TIME: *((int *)return_value) = rmcast_options.leave_group_wait_time; break; case RCV_BUFFER_SIZE: *((int *)return_value) = rmcast_options.rcv_buffer_size; break; default: fprintf( stderr, "RM_getOption warning: Trying to get an invalid option: %d\n", opt ); break; } } void RM_setOption( int opt, void *opt_value ) { char logfilename[ 255 ], localhost_name[ 127 ]; char pid[ 16 ]; switch( opt ) { case PIPE: /* address of the pipe used to make the connection between the application and the multicast library */ rmcast_options.pipe = (int*)opt_value; break; case SHUT_DOWN_ROUTINE: /* pointer to the routine called when shutting down the protocol */ rmcast_options.shut_down_routine = (void (*)(void))opt_value; break; case DEST_IP: strcpy( rmcast_options.dest_ip , (char*)opt_value ); break; case DEST_PORT: rmcast_options.dest_port = (int)opt_value ; break; case TTL: rmcast_options.ttl = (int)opt_value; break; case MICROSLEEP: rmcast_options.microsleep = (unsigned int)opt_value; break; case TIMER_PARAM_A: rmcast_options.timer_paramA = (int)opt_value; break; case TIMER_PARAM_B: rmcast_options.timer_paramB = (int)opt_value; break; case TIMER_PARAM_C: rmcast_options.timer_paramC = (int)opt_value; break; case TIMER_PARAM_D: rmcast_options.timer_paramD = (int)opt_value; break; case TIMER_PARAM_E: rmcast_options.timer_paramE = (int)opt_value; break; case TIMER_PARAM_F: rmcast_options.timer_paramF = (int)opt_value; break; case HOSTS_IDENTIFIED: rmcast_options.hosts_identified = (int)opt_value; break; case TIMER_DISTRIBUTION: rmcast_options.timer_distribution = (int)opt_value; break; case MAX_NAK: rmcast_options.max_nak = (int)opt_value; break; case MAX_MEMBER_CACHE_SIZE: rmcast_options.max_member_cache_size = (int)opt_value; break; case RM_VERSION: rmcast_options.version = (int)opt_value; break; case TRANSMISSION_MODE: rmcast_options.transmission_mode = (int)opt_value; break; case LOG_FILE: if( strcmp( (char*)opt_value, "NULL" ) == 0 ) rmcast_options.log_file[ 0 ] = 0; else { gethostname( localhost_name, 30 ); strcpy( logfilename, ""); strcat( logfilename, (char*)opt_value ); strcat( logfilename, "." ); strcat( logfilename, localhost_name ); strcat( logfilename, "." ); sprintf( pid, "%d", (int)getpid() ); strcat( logfilename, pid ); strcpy ( rmcast_options.log_file, logfilename ); } break; case NEW_MEMBER_SUPPORT: rmcast_options.new_member_support = (int)opt_value; break; case STATISTICS: rmcast_options.statistics = (int)opt_value; break; case REFRESH_TIMER: rmcast_options.refresh_timer = (int)opt_value; break; case LOSS_PROB: rmcast_options.loss_prob = (int)opt_value / (float)100; break; case LEAVE_GROUP_WAIT_TIME: rmcast_options.leave_group_wait_time = (int)opt_value; break; case RCV_BUFFER_SIZE: rmcast_options.rcv_buffer_size = (int)opt_value; break; default: fprintf( stderr, "RM_setOption warning: Trying to set and invalid option: %d\n", opt ); break; } } /******************************************************************************* * * int RM_setHostDelay(char *hostname, int estimated_one_way_delay ) * * Updated the estimated one-way delay if host identified by 'hostname' exists * Try to insert a new entry if the host identfied by 'hostname' does not exist * * Parameters: hostname, the host name * estimated_one_way_delay, the estimated one-way delay for 'hostname' * * Returns: 1 if the host delay was updated * 2 if the host delay was inserted as a new entry * -1 if there is no room for another host in the rmcast_options.hosts_delays structure * -2 if the IP address for 'hostname' was not found * ******************************************************************************/ int RM_setHostDelay( char *hostname, int estimated_one_way_delay ) { struct hostent *host_info; int i,retval = -1; char aux_host_ip[ IP_STRING_SIZE ]; if( strcmp( hostname, "DEFAULT" ) == 0 ) { rmcast_options.hosts_delays[ 0 ].estimated_delay = 1000 * estimated_one_way_delay; retval = 1; } else if( ( host_info = gethostbyname( hostname ) ) != NULL ) { sprintf( aux_host_ip, "%s", inet_ntoa( *((struct in_addr*)(host_info->h_addr_list[ 0 ])) ) ); i = 1; while( ( i <= rmcast_options.hosts_identified ) && ( retval != 1 ) ) { if( strcmp( rmcast_options.hosts_delays[ i ].IP, aux_host_ip ) == 0 ) { rmcast_options.hosts_delays[i].estimated_delay = 1000 * estimated_one_way_delay; retval = 1; } else i++; } if( ( retval == -1 ) && ( i < MAX_HOSTS ) ) { sprintf( rmcast_options.hosts_delays[ i ].IP, "%s", aux_host_ip ); rmcast_options.hosts_delays[ i ].estimated_delay = 1000 * estimated_one_way_delay; RM_setOption( HOSTS_IDENTIFIED, (void*)( rmcast_options.hosts_identified + 1 )); retval = 2; } else if( i >= MAX_HOSTS ) retval = -2; } return retval; } /******************************************************************************* * * int RM_getHostDelay(char *hostname, int *estimated_one_way_delay ) * * Get the estimated_one_way_delay stored for the host identified by 'hostname' if it exists * * Parameters: hostname, the host name * estimated_one_way_delaylowest_timer, the estimated one-way delay for the 'hostname' * * Returns: 1 if the host identified by 'hostname' exists * -1 if the host identified by 'hostname' does not exist in the * rmcast_options.hosts_delays structure * -2 if the IP address for 'hostname' was not found * ************************************************************************************/ int RM_getHostDelay( char *hostname, int *estimated_one_way_delay ) { struct hostent *host_info; int i, retval = -1; char aux_host_ip[ IP_STRING_SIZE ]; if( ( strcmp( hostname, "DEFAULT" ) == 0 ) || ( hostname == NULL ) ) { *estimated_one_way_delay = ( rmcast_options.hosts_delays[ 0 ].estimated_delay / 1000 ); retval = 1; } else if( ( host_info = gethostbyname( hostname ) ) != NULL ) { sprintf( aux_host_ip, "%s",inet_ntoa( *((struct in_addr*)(host_info->h_addr_list[ 0 ])) ) ); for( i = 1; i < MAX_HOSTS; i++ ) { if( strcmp( rmcast_options.hosts_delays[ i ].IP, aux_host_ip ) == 0 ) { *estimated_one_way_delay = ( rmcast_options.hosts_delays[ i ].estimated_delay / 1000 ); retval = 1; break; } } } else { retval = -2; } return retval; } /******************************************************************************* * * void RM_leaveGroup(int sock, char *group) * * Used to leave from the multicast group. * * Parameters: sock, the multicast socket; * group, the multicast ip. * ******************************************************************************/ void RM_leaveGroup( int sock, char *group1 ) { char *group; if( (int)group1 == RM_USE_CURRENT_CONFIG ) group = rmcast_options.dest_ip; else group = group1; rmcastLeaveGroup( sock, group ); pthread_join( signal_handler_thread, NULL ); } /******************************************************************************* * * void RM_terminate( void ) * * Close logfile if needed and call the terminate callback function * ******************************************************************************/ void RM_terminate( void ) { #ifdef DEBUG_NET_MSGS fprintf( stderr,"DEBUG_NET_MSGS RM_terminate\n" ); #endif if( logfile != NULL ) { fprintf( logfile, "Sent_Packets: %d", sent_packets ); fclose( logfile ); } callback_terminate(); } /******************************************************************************* * * int RM_sendto (int socket, char *buffer, int buffsize) * * Sends a message, contained in buffer, to the multicast group. * * Parameters: socket, the socket number; * buffer, message to be sent; * buffsize, maximum number of chars to be sent. * * Returns: 1, on success; * 0, on error. * ******************************************************************************/ int RM_sendto( int socket, void *buffer, int buffsize ) { PACKET_INFO pckt_info; BYTE* local_buffer = NULL; int final_message_size, retval; pckt_info.type = DATA_PACKET_TYPE; pckt_info.flags = 0; strcpy( pckt_info.sender_id.ip, local_user_info.member_id.ip ); pckt_info.sender_id.pid = local_user_info.member_id.pid; lock_eventlist_and_cache(); pthread_mutex_lock( &change_local_user_sn ); pckt_info.packet_data.data_packet.sn = local_user_info.sn; pthread_mutex_unlock( &change_local_user_sn ); pckt_info.packet_data.data_packet.data_size = buffsize; pckt_info.packet_data.data_packet.data = (BYTE*)malloc( sizeof( char ) * buffsize + 1 ); memcpy( (char*)( pckt_info.packet_data.data_packet.data ), buffer, buffsize ); retval = cacheInsertMessage( &cache, &(pckt_info.sender_id), &(pckt_info.packet_data.data_packet) ); unlock_eventlist_and_cache(); if( retval == 0 ) { fprintf( stderr, "RM_sendto ERROR: inserting message in local cache.\n" ); return 0; } msgPcktMountMessage( &pckt_info, &local_buffer, &final_message_size ); #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_sendto: Will send a message... \n" ); #endif if( rmcastSendPacket( socket, local_buffer, final_message_size ) == 0 ) return 0; sent_packets++; /* counting sent packets */ #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_sendto: Message sent ok!\n" ); #endif #ifdef DEBUG_SHOW msgPcktShowMessage( local_buffer ); #endif free( local_buffer ); return TRUE; } /******************************************************************************* * * int RM_recv (int socket, char *buffer, int buffsize) * * Waits to receive a message. * * Parameters: socket, the socket number; * buffer, message received; * buffsize, maximum number of chars to be received. * * Returns: number of bytes received, on success; * -1, on error. * ******************************************************************************/ int RM_recv( int socket, void *buffer, int buffsize ) { struct q_entry r_entry = { 0 }; int mlen = 0, size = 0, power = 0, ind = 0; #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_recv: Waiting to receive a \"reliable\" message...\n" ); #endif /* waiting to receive a ŽreliableŽ message trhough the message queue */ if( ( mlen = msgrcv( r_qid, &r_entry, MAXOBN, 0, MSG_NOERROR ) ) == -1 ) { #ifdef DEBUG_NET_MSGS perror("DEBUG_NET_MSGS RM_recv: msgrcv failed"); #endif if( errno == EIDRM || errno == EINVAL ) return -1; } else { /* a ŽreliableŽ message was received */ size =0; /* convert mtext from base 256 to base 10 - mtext[0] is the least signif. digit of mtext */ for( power = 1, ind = 0; ind < MSG_QUEUE_HEADER_SIZE; power = (int)pow( 256, ind ) ) { size += ((unsigned char)(r_entry.mtext[ ind ])) * power; #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_recv: power: %d r_entry.mtext[%d]=%d size=%d\n", power, ind, r_entry.mtext[ ind ], size ); #endif ind++; } if( size > buffsize ) { fprintf( stderr, "RM_recv warning: Message greater than buffer. message size=%d, buffer size=%d\n", size, buffsize ); return -1; } else memcpy( buffer, &( r_entry.mtext[ MSG_QUEUE_HEADER_SIZE ] ), size ); #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_recv: A \"reliable\" message was received=%s!\n", (char*)buffer ); #endif } #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS RM_recv: sending message to application. Message size=%d\n", size ); #endif return size; } /******************************************************************************/ void RMDEBUG_setpidip( int pid, char *ip ) { local_user_info.member_id.pid = pid; strncpy( local_user_info.member_id.ip, ip, IP_STRING_SIZE ); } /******************************************************************************/ void RMDEBUG_setsn( int sn ) { pthread_mutex_lock( &change_local_user_sn ); local_user_info.sn = sn; pthread_mutex_unlock( &change_local_user_sn ); } void RM_getVersion( char *buf, int buf_sz ) { strncpy( buf, "RMCAST "STR_VERSION, buf_sz ); } #endif tgif-QPL-4.2.5/rmcast/src/rmcache.c0000644000076400007640000010031011222706507016616 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmcache.c ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifndef RMCACHE_C #define RMCACHE_C #include "rmstruct.h" #include #include #include #include "rmcache.h" #include "rmwinmask.h" #ifndef RMINTERNALS_H #include "rminternals.h" #endif extern GLOBAL_OPTIONS rmcast_options; #ifdef SOLARIS pthread_mutex_t cache_mutex; #else pthread_mutex_t cache_mutex = PTHREAD_MUTEX_INITIALIZER; #endif /*---------------- Auxiliary functions to manipulate the cache ---------------*/ /******************************************************************************* * * int cacheAllocHeaderNode(CACHE **cache, MEMBER_ID *member) * * Allocates a cache header node. * * Arguments: cache, the cache; * member, the member to be inserted. * * Returns: 0 on error, 1 otherwise. * ******************************************************************************/ int cacheAllocHeaderNode(CACHE **cache, MEMBER_ID *member) { if( ( *cache = (CACHE*)malloc( sizeof( CACHE ) ) ) == NULL ) { fprintf( stderr, "cacheAllocHeaderNode ERROR: Allocating cache header node\n" ); return 0; } bzero( (*cache), sizeof( CACHE ) ); (*cache)->active = 1; if( member != NULL ) (*cache)->sm_info.member_id = *member; (*cache)->sm_info.member_status.last_identified = -1; (*cache)->sm_info.member_status.first_rcv = -1; (*cache)->sm_info.member_status.last_rcv = -1; (*cache)->sm_info.member_status.last_seq_rcv = -1; #ifdef SINGLE_NACK (*cache)->sm_info.member_status.window_size = MAX_WINDOW_SIZE; (*cache)->sm_info.member_status.window_ini = 0; memset( (*cache)->sm_info.member_status.window_mask, 0, MAX_WINDOW_SIZE ); #ifdef DSINGLE_NACK { int h = 0; int l = 0; window_mask_array2numbers( (*cache)->sm_info.member_status.window_mask, &h, &l, (*cache)->sm_info.member_status.window_ini ); fprintf( stderr, "DSINGLE_NACK cacheAllocHeaderNode: window_mask h=%d l=%d\n", h, l ); } #endif #endif return 1; } /******************************************************************************* * * int cacheAllocMessageNode(CACHE_NODE **cache_node, DATA_PACKET *node_info) * * Allocates a cache message node. * * Arguments: cache_node, the cache node to be created, it'll be allocated here; * node_info, information about the message node to be created. * * Returns: 0 on error, 1 otherwise. * ******************************************************************************/ int cacheAllocMessageNode( CACHE_NODE **cache_node, DATA_PACKET *node_info ) { if( ( *cache_node = (CACHE_NODE*)malloc( sizeof( CACHE_NODE ) ) ) == NULL ) { fprintf( stderr, "cacheAllocMessageNode ERROR: allocating cache message node" ); return 0; } bzero( *cache_node, sizeof( CACHE_NODE ) ); (*cache_node)->data_pckt.sn = node_info->sn; (*cache_node)->data_pckt.data_size = node_info->data_size; (*cache_node)->data_pckt.data = (BYTE*)malloc( ( node_info->data_size + 1 ) * sizeof( BYTE ) ); memcpy( (*cache_node)->data_pckt.data,node_info->data, ( node_info->data_size + 1 ) ); /* Observation: we allocate and copy data_size data bytes, plus one byte for the string termination caracter */ return 1; } /******************************************************************************* * * int cacheFreeMessageNode(CACHE_NODE **node) * * Free a cache message node. * * Arguments: cache_node, the cache node to be released. * * Returns: 1 allways. * ******************************************************************************/ int cacheFreeMessageNode( CACHE_NODE **node ) { free( (*node)->data_pckt.data ); free( *node ); *node = NULL; return 1; } /*---------------- Main functions to manipulate the cache --------------------*/ /******************************************************************************* * * void cacheInit(CACHE **cache) * * Initialize the cache. * * Arguments: cache, the cache; * ******************************************************************************/ void cacheInit( CACHE **cache ) { #ifdef SOLARIS pthread_mutex_init( &cache_mutex, NULL ); #endif *cache = NULL; } /******************************************************************************* * * int cacheInsertMessage(CACHE **cache, MEMBER_ID *member, DATA_PACKET *data_packet) * * Inserts a message in the cache. * * Arguments: cache, the cache; * member, the member who originaly sent the message; * data_packet, message data. * * Side Effects: this routine updates, in the cache, the following fields regarding * the member who originaly sent the message: * * - number_of_nodes * * SM_INFO->MEMBER_STATUS * * - first_rcv * - last_rcv * - last_seq_rcv * - last_identified * #ifdef SINGLE_NACK * - window_size; * - window_mask[MAX_WINDOW_SIZE]; * - window_ini * #ifdef * * - CACHE_NODE *first * - CACHE_NODE *last * - CACHE_NODE *last_inserted; * * Return value: 0, on error; * 1, if the inserted message was in sequence, * i.e. the message received was the one expected; * 2, if the inserted message was not is sequence. * ******************************************************************************/ #define CHECK_INTEGRITY_OF_CACHE \ \ if( newMessageCacheNode -> next == NULL && memberHeaderNode->last != newMessageCacheNode )\ { \ fprintf(stderr,"ATTENTION!!!! memberHeaderNode->last != newMessageCacheNode \ && newMessageCacheNode->next == NULL" ); \ } int cacheInsertMessage( CACHE **cache, MEMBER_ID *member, DATA_PACKET *data_packet ) { int count = 0; int isfirst = 0; CACHE *memberHeaderNode = NULL; CACHE_NODE *newMessageCacheNode = NULL, *auxMessageNode = NULL; /* ============== Allocating space for the new message ================== */ memberHeaderNode = cacheLookForMember(cache, member); if( memberHeaderNode == NULL ) { if( ( memberHeaderNode = cacheInsertMember( cache, member ) ) == NULL) { return 0; } } if( memberHeaderNode->number_of_nodes == rmcast_options.max_member_cache_size ) { if( memberHeaderNode->last->data_pckt.sn <= memberHeaderNode->sm_info.member_status.last_seq_rcv ) { /* The last node can be removed only if it was sent to the application */ ((memberHeaderNode->last)->previous)->next = NULL; auxMessageNode = (memberHeaderNode->last); (memberHeaderNode->last) = ((memberHeaderNode->last)->previous); cacheFreeMessageNode( &auxMessageNode ); memberHeaderNode->number_of_nodes--; } else { return 0; } } if( cacheAllocMessageNode( &newMessageCacheNode, data_packet ) == (int)NULL ) { return 0; } /* ================ Inserting the new message =========================== */ if( memberHeaderNode->number_of_nodes == 0 ) { /* we will insert the first message node*/ memberHeaderNode->last = memberHeaderNode->first = newMessageCacheNode; isfirst = 1; #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE cacheInsertMessage: we will insert the first message node\n" ); #endif } else { #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE cacheInsertMessage: a message node will be inserted\n" ); #endif auxMessageNode = memberHeaderNode->first; while( auxMessageNode != NULL ) { if(auxMessageNode->data_pckt.sn <= newMessageCacheNode->data_pckt.sn ) break; auxMessageNode = auxMessageNode->next; count++; } if( auxMessageNode ) { if( auxMessageNode->data_pckt.sn == newMessageCacheNode->data_pckt.sn ) { return 0; /* repeated node */ } } if( count == 0 ) { memberHeaderNode->first = newMessageCacheNode; } #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE cacheInsertMessage: adjusting pointers\n" ); #endif if( auxMessageNode ) { newMessageCacheNode->next = auxMessageNode; newMessageCacheNode->previous = auxMessageNode->previous; if( auxMessageNode->previous != NULL ) auxMessageNode->previous->next = newMessageCacheNode; auxMessageNode->previous = newMessageCacheNode; } else { #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE cacheInsertMessage: inserting at the end..." ); cacheShow( *cache ); #endif newMessageCacheNode->previous = memberHeaderNode->last; memberHeaderNode->last->next = newMessageCacheNode; memberHeaderNode->last = newMessageCacheNode; } #ifdef DEBUG_CACHE CHECK_INTEGRITY_OF_CACHE; #endif } #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE cacheInsertMessage: node (%d) inserted in cache\n", data_packet->sn ); #endif /* Updating fields regarding the member who originaly sent the msg ======*/ memberHeaderNode->last_inserted = newMessageCacheNode; memberHeaderNode->number_of_nodes++; if( memberHeaderNode->sm_info.member_status.first_rcv == -1 ) memberHeaderNode->sm_info.member_status.first_rcv = data_packet->sn; memberHeaderNode->sm_info.member_status.last_rcv = data_packet->sn; if( memberHeaderNode->sm_info.member_status.last_identified < data_packet->sn ) { memberHeaderNode->sm_info.member_status.last_identified = data_packet->sn; } if( ( memberHeaderNode->sm_info.member_status.last_seq_rcv + 1 ) == newMessageCacheNode->data_pckt.sn ) { while( ( newMessageCacheNode != NULL ) && ( memberHeaderNode->sm_info.member_status.last_seq_rcv + 1 == newMessageCacheNode->data_pckt.sn ) ) { memberHeaderNode->sm_info.member_status.last_seq_rcv++; #ifdef SINGLE_NACK { #ifdef DSINGLE_NACK int l = 0; int h = 0; window_mask_array2numbers( memberHeaderNode->sm_info.member_status.window_mask, &h, &l, memberHeaderNode->sm_info.member_status.window_ini); /* fprintf(stderr,"DSINGLE_NACK cacheInsertMessage: window_mask before l=%d h=%d\n",l,h); */ #endif window_mask_set_bit2( memberHeaderNode->sm_info.member_status.window_mask, memberHeaderNode->sm_info.member_status.window_ini, 0 ); memberHeaderNode->sm_info.member_status.window_ini = ( memberHeaderNode->sm_info.member_status.window_ini + 1 ) % MAX_WINDOW_SIZE; #ifdef DSINGLE_NACK window_mask_array2numbers( memberHeaderNode->sm_info.member_status.window_mask, &h, &l, memberHeaderNode->sm_info.member_status.window_ini); #endif } #endif newMessageCacheNode = newMessageCacheNode -> previous; } #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE cacheInsertMessage: node (%d) inserted in cache, in sequence\n", data_packet->sn ); #endif return 1; } else { #ifdef SINGLE_NACK if( ( memberHeaderNode->sm_info.member_status.last_seq_rcv <= data_packet->sn ) && ( data_packet->sn <= memberHeaderNode->sm_info.member_status.last_seq_rcv + MAX_WINDOW_SIZE ) ) { memberHeaderNode->sm_info.member_status.window_mask[ ( memberHeaderNode->sm_info.member_status.window_ini + data_packet->sn - (memberHeaderNode->sm_info.member_status.last_seq_rcv + 1 ) ) % MAX_WINDOW_SIZE ] = 0; } #endif #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE cacheInsertMessage: node (%d) inserted in cache, not in sequence\n", data_packet->sn ); #endif /* the packet is not in sequence - it will be needed to send a nak */ return 2; } } /******************************************************************************* * * void cachePack(CACHE **cache, char **buf, int *buffsize) * * Packs the cache information in a buffer. * * Arguments: cache, the cache; * buf, points to the place where the packed info will be stored; * buffsize, returns the number of bytes in buf. * * Side effects: this routine allocates the buf variable, and stores its * final size in buffsize. * ******************************************************************************/ void cachePack( CACHE **cache, char **buf, int *buffsize ) { CACHE *current_header_node; char *buf_next_write_pos; int nelem = 0; current_header_node = *cache; *buf = NULL; while( current_header_node != NULL ) { nelem ++; /* allocating space to store info about the new cache header node */ *buf = realloc( *buf, ( nelem * sizeof(CACHE)) ); /* writing the information about the new cache header node */ buf_next_write_pos = *buf + ( (nelem - 1) * sizeof(CACHE) ); memcpy(buf_next_write_pos, current_header_node, sizeof(CACHE) ); current_header_node = current_header_node->next; } *buffsize = nelem * sizeof(CACHE); } /******************************************************************************* * * void cacheUnpack(CACHE **cache, char *buf, int buffsize) * * Unpacks the cache information contained in a buffer. * * Arguments: cache, the cache; * buf, points to the place from where the packed info will be read; * buffsize, the number of bytes in buf. * * Side effects: updates the cache. * ******************************************************************************/ void cacheUnpack( CACHE **cache, char *buf, int buffsize ) { char *buf_next_read_pos; /* number of bytes read */ int nbread = 0; CACHE *cur_member; CACHE cur_member_buf; buf_next_read_pos = buf; for( nbread = 0; nbread < buffsize; nbread += sizeof( CACHE ) ) { memcpy( &cur_member_buf, buf_next_read_pos, sizeof( CACHE ) ); cur_member = cacheInsertMember( cache, &(cur_member_buf.sm_info.member_id ) ); cur_member->sm_info.member_status = cur_member_buf.sm_info.member_status; cur_member->sm_info.member_status.last_rcv = cur_member->sm_info.member_status.last_seq_rcv; cur_member->sm_info.member_status.last_identified = cur_member->sm_info.member_status.last_seq_rcv; buf_next_read_pos += sizeof( CACHE ); } } /******************************************************************************* * * CACHE *cacheInsertMember(CACHE **cache, MEMBER_ID *member) * * Inserts a member in the cache. * * Arguments: cache, the cache; * member, the member identification; * * Return value: a pointer to the inserted member; NULL on error. * ******************************************************************************/ CACHE *cacheInsertMember( CACHE **cache, MEMBER_ID *member ) { CACHE *auxHeaderNode = *cache, *newHeaderNode; if( cacheAllocHeaderNode( &newHeaderNode, member ) == (int)NULL ) { return NULL; } if( cacheIsEmpty( cache ) ) { /* cache is empty */ *cache = newHeaderNode; } else { /* inserts new node in the end of the list */ #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE cacheInsertMember: searching where to insert new member node...\n" ); #endif while( auxHeaderNode->next != NULL ) { auxHeaderNode = auxHeaderNode->next; } #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE cacheInsertMember: member node will be inserted...\n" ); #endif auxHeaderNode->next = newHeaderNode; } return newHeaderNode; } /******************************************************************************* * * int cacheIsEmpty(CACHE **cache) * * Checks if the cache is empty. * * Arguments: cache, the cache; * * Return value: 1 if the cache is empty; 0 otherwise. * ******************************************************************************/ int cacheIsEmpty( CACHE **cache ) { if( *cache == NULL ) return 1; else return 0; } /******************************************************************************* * * int cacheOfAnyMemberIsFull(CACHE *cache) * * Checks if the cache space reserved for any member is full. * * Arguments: cache, the cache; * * Return value: 1 if the the cache of any member is full; 0 otherwise. * ******************************************************************************/ int cacheOfAnyMemberIsFull( CACHE *cache ) { CACHE *auxCacheHeaderNode = cache; while( auxCacheHeaderNode->number_of_nodes < rmcast_options.max_member_cache_size ) { auxCacheHeaderNode = auxCacheHeaderNode->next; if( auxCacheHeaderNode == NULL ) return 0; } return !( auxCacheHeaderNode->number_of_nodes < rmcast_options.max_member_cache_size ); } int memberIsEqual( MEMBER_ID *member1, MEMBER_ID *member2 ) { if( ( member1->pid == member2->pid ) && ( !strcmp( member1->ip, member2->ip ) ) ) return 1; else return 0; } /******************************************************************************* * * CACHE* cacheLookForMember(CACHE **cache1, MEMBER_ID *member_id) * * Searches for a member in the cache. * * Arguments: cache, the cache; * member_id, the member identification. * * Return value: a pointer to the requested member node, * or NULL if the member does not exist. * ******************************************************************************/ CACHE* cacheLookForMember( CACHE **cache1, MEMBER_ID *member_id ) { CACHE *auxHeaderNode = NULL; CACHE *cache = NULL; if( !cacheIsEmpty( cache1 ) && ( member_id != NULL ) ) { cache = *cache1; auxHeaderNode = cache; while( !memberIsEqual( member_id, &auxHeaderNode->sm_info.member_id ) ) { auxHeaderNode = auxHeaderNode->next; if( auxHeaderNode == NULL ) break; } } #ifdef DEBUG_CACHE else { fprintf( stderr, "DEBUG_CACHE cacheLookForMember: Cache is empty.\n" ); } #endif return (auxHeaderNode); } /******************************************************************************* * * int cacheDesactivateMember(CACHE *cache, MEMBER_ID *member) * * Deactivate a cache member, setting its activate bit to zero. * * Arguments: cache, the cache; * member_id, the member to be deactivated. * * Return value: 1 on success, 0 on fail. * ******************************************************************************/ int cacheDeactivateMember( CACHE *cache, MEMBER_ID *member ) { CACHE* auxCacheHeaderNode = cacheLookForMember( &cache,member ); if( auxCacheHeaderNode != NULL ) { auxCacheHeaderNode -> active = 0; return 1; } else return 0; } /******************************************************************************* * * void cacheShow(CACHE *cache) * * Show the cache on the screen. * * Arguments: cache, the cache; * ******************************************************************************/ void cacheShow( CACHE *cache ) { #ifdef DEBUG_SHOW CACHE* auxCacheHeaderNode = cache; CACHE_NODE *auxMessageNode; char aux_string[ IP_STRING_SIZE ]; int i; #ifdef SINGLE_NACK #ifdef DSINGLE_NACK int h = 0; int l = 0; char aux_str[ 200 ]; #endif #endif fprintf( stderr, "\n-----cacheShow-------------------------------------------------------\n" ); while( auxCacheHeaderNode != NULL ) { for ( i = 0; i < IP_STRING_SIZE; i++ ) aux_string[ i ] = auxCacheHeaderNode->sm_info.member_id.ip[ i ]; auxMessageNode = auxCacheHeaderNode->first; fprintf( stderr, "[%x %x %sactive {first:%d last:%d last_seq:%d last identified:%d}] (%d nodes) %s %d :\n", (unsigned int)auxCacheHeaderNode->first, (unsigned int)auxCacheHeaderNode->last, (auxCacheHeaderNode->active==1?" ":"des"), auxCacheHeaderNode->sm_info.member_status.first_rcv, auxCacheHeaderNode->sm_info.member_status.last_rcv, auxCacheHeaderNode->sm_info.member_status.last_seq_rcv, auxCacheHeaderNode->sm_info.member_status.last_identified, auxCacheHeaderNode->number_of_nodes, aux_string, auxCacheHeaderNode->sm_info.member_id.pid ); #ifdef SINGLE_NACK #ifdef DSINGLE_NACK window_mask_array2numbers( auxCacheHeaderNode->sm_info.member_status.window_mask, &h, &l, auxCacheHeaderNode->sm_info.member_status.window_ini ); sprintf( aux_str, "DSINGLE_NACK (DEBUG_SHOW) cacheShow: window_ini=%d h=%d l=%d\n", auxCacheHeaderNode->sm_info.member_status.window_ini, h, l ); for( i = 0; i < MAX_WINDOW_SIZE; i++ ) sprintf( aux_str, "%s%s%d", aux_str, ( i == auxCacheHeaderNode->sm_info.member_status.window_ini )?"*":"", auxCacheHeaderNode->sm_info.member_status.window_mask[ i ] ); fprintf( stderr, "%s\n", aux_str ); #endif #endif /* SINGLE_NACK */ #ifdef DCACHE_CONTENTS while( auxMessageNode != NULL ) { fprintf( stderr, " \t([%08x %08x %08x] sn: %d pck size: %d %s)\n", (unsigned int)auxMessageNode->previous, (unsigned int)auxMessageNode, (unsigned int)auxMessageNode->next, auxMessageNode->data_pckt.sn, auxMessageNode->data_pckt.data_size, (char*)auxMessageNode->data_pckt.data ); auxMessageNode = auxMessageNode->next; } #endif auxCacheHeaderNode = auxCacheHeaderNode->next; } fprintf( stderr, "\n--------------------------------------------------------------------\n\n" ); #endif } /******************************************************************************* * * void cacheGetSMInfo(CACHE *cache, SM_INFO **sm_table, int *nusers) * * Gets session message information from the cache. * * Arguments: cache, the cache; * sm_table, a pointer to where the destination info. will be stored - * itŽs allocated here; * nusers, returns the number of users in the cache - * it must be previously allocated. * Returns: 1, on success; * 0, on error. * ******************************************************************************/ int cacheGetSMInfo( CACHE *cache, SM_INFO **sm_table, int *nusers ) { int i = 0; CACHE* auxCacheHeaderNode = cache; *sm_table = NULL; *nusers = 0; for( auxCacheHeaderNode=cache; auxCacheHeaderNode != NULL; auxCacheHeaderNode=auxCacheHeaderNode->next ) { if( ( *sm_table = (SM_INFO*)realloc( *sm_table, ( i + 1 )*sizeof( SM_INFO ) ) ) == NULL ) { fprintf(stderr, "cacheGetSMInfo ERROR: allocating sm_info\n" ); return 0; } memcpy( (*sm_table)+i, &auxCacheHeaderNode->sm_info, sizeof( SM_INFO ) ); i++; (*nusers)++; } return 1; } /******************************************************************************* * * DATA_PACKET *cacheLookForMessage(CACHE **cache1, MEMBER_ID *member_id,int message_sn) * * Searches for a message in the cache. * * Arguments: cache1, the cache; * member_id, original sender of the message information; * message_sn, message sequence number; * * Returns: a pointer to the data packet, or NULL when not found. * ******************************************************************************/ DATA_PACKET *cacheLookForMessage( CACHE **cache1, MEMBER_ID *member_id, int message_sn ) { CACHE *auxMember; CACHE_NODE *auxMsg; CACHE *cache; DATA_PACKET *auxDatapkg; cache = *cache1; auxDatapkg = NULL; #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK cacheLookForMessage: entering, looking for %s:%d:%d\n", member_id->ip, member_id->pid, message_sn ); #endif #ifdef DNAK_RCV fprintf( stderr, "DNAK_RCV cacheLookForMessage: entering, looking for %s:%d:%d\n", member_id->ip, member_id->pid, message_sn ); #endif if( ( auxMember = cacheLookForMember( &cache, member_id ) ) != NULL ) { auxMsg = auxMember->first; while( ( auxMsg != NULL ) && ( auxMsg->data_pckt.sn != message_sn ) ) { auxMsg=auxMsg->next; } if( auxMsg != NULL && auxMsg->data_pckt.sn == message_sn ) { auxDatapkg=&auxMsg->data_pckt; } } return auxDatapkg; } /*---- Auxiliary functions to manipulate the nak list ------------------------*/ /******************************************************************************* * * int cacheAllocNAKNode(NAK_LIST **nak_node, int sn) * * Allocates a new nak (not acknowledge) node, and fills it with specified info. * * Arguments: nak_node, the node which will be created; * sn, the sequence number of the nak node. * * Returns: 0 on error, 1 on success. * ******************************************************************************/ int cacheAllocNAKNode( NAK_LIST **nak_node, int sn ) { if( ( *nak_node = (NAK_LIST*)malloc( sizeof( NAK_LIST ) ) ) == NULL ) { fprintf( stderr, "Error allocating cache message node\n" ); return 0; } bzero( *nak_node, sizeof( NAK_LIST ) ); (*nak_node)->sn = sn; /* at least one nak was sent */ (*nak_node)->counter = 1; return 1; } /******************************************************************************* * * int cacheUpdateNakList(CACHE **cache1, MEMBER_ID *member, int sn) * * Updates the list of naks sent with respect to a specific member. * * Arguments: cache1, the cache; * member, the original sender of the message; * sn, the sequence number of the message that we will wait for. * * Returns: 0 on error, 1 on success. * ******************************************************************************/ int cacheUpdateNakList( CACHE **cache1, MEMBER_ID *member, int sn ) { NAK_LIST *auxNakNode, *aux2, *new_nak_node; CACHE *memberHeaderNode; CACHE *cache; aux2 = NULL; cache = *cache1; if( ( memberHeaderNode = cacheLookForMember( &cache, member ) ) == NULL ) { fprintf( stderr, "cacheUpdateNakList - Error: member (%s:%d) not found in cache.\n", member->ip, member->pid ); return 0; } auxNakNode = memberHeaderNode->nak_list; if( auxNakNode == NULL ) { if( cacheAllocNAKNode( &new_nak_node, sn ) == 0 ) { fprintf( stderr, "cacheUpdateNakList - Error: cacheAllocNAKNode failed.\n" ); return 0; } memberHeaderNode->nak_list = new_nak_node; } else { while( auxNakNode != NULL ) { if( auxNakNode->sn != sn ) { aux2 = auxNakNode; auxNakNode = auxNakNode->next; } else { if( auxNakNode->counter >= rmcast_options.max_nak ) { return 0; } else { auxNakNode->counter++; break; } } } if( auxNakNode == NULL ) { if( cacheAllocNAKNode( &new_nak_node, sn ) == 0 ) { fprintf( stderr, "cacheUpdateNakList - Error: cacheAllocNAKNode failed.\n" ); return 0; } aux2->next = new_nak_node; } } return 1; } int cacheDeleteNakNode( CACHE *cache, MEMBER_ID *member, int sn ) { NAK_LIST *auxNakNode, *auxNakNode2; CACHE *memberHeaderNode; int retval = 1; int node_not_found = 1; if( ( memberHeaderNode = cacheLookForMember( &cache, member ) ) != NULL ) { auxNakNode = memberHeaderNode->nak_list; while( ( auxNakNode != NULL ) && node_not_found ) { if( auxNakNode->sn != sn ) { auxNakNode = auxNakNode->next; } else { auxNakNode2 = auxNakNode; auxNakNode = auxNakNode->next; auxNakNode2->next = NULL; free( auxNakNode2 ); node_not_found = 0; fprintf( stderr, "nak node removed: (%s:%d:%d)\n", member->ip, member->pid, sn); } } if( node_not_found ) { fprintf( stderr, "cacheDeleteNakNode - Error: Nak node (%s:%d:%d) not found.\n", member->ip, member->pid, sn ); retval = 0; } } else { fprintf( stderr, "cacheDeleteNakNode - Error: member (%s:%d) not found in cache.\n", member->ip, member->pid ); retval = 0; } return retval; } /*---- End of auxiliary functions to manipulate the nak list -----------------*/ /******************************************************************************* * * int cacheCountMembers( CACHE *cache, int member_status_required) * * Count the members in the cache according to the status specified in member_status_required * * Arguments: cache, pointer to the first node of the cache * member_status_required, the member status required to consider a member * while counting * * Returns: Number of members found in the cache according to the status specified * in member_status_required * ******************************************************************************/ int cacheCountMembers( CACHE *cache, int member_status_required ) { CACHE* auxCacheHeaderNode = cache; int member_counter = 0; while( auxCacheHeaderNode != NULL ) { if( member_status_required == CACHE_STATUS_ANY ) { /* We must count all registered members */ member_counter++; } else { /* We will count only the members who has active == member_status_required */ if( auxCacheHeaderNode->active == member_status_required ) member_counter++; } auxCacheHeaderNode = auxCacheHeaderNode->next; } return( member_counter ); } #endif /* RMCACHE_C */ tgif-QPL-4.2.5/rmcast/src/rmevent.c0000644000076400007640000013167111141162245016705 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmevent.c ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifndef RMEVENT_C #define RMEVENT_C #include #include #include #include #include #include #include "rmstruct.h" #include "rmevent.h" #include "rminternals.h" #include "rmwinmask.h" #include "rmcast.h" /*---------------- Global variables ------------------------------------------------------------------*/ #ifdef DSUPPRESSION extern FILE *suppressionfile; #endif extern pthread_t rcv_thread, signal_handler_thread; extern GLOBAL_OPTIONS rmcast_options; #ifndef RANDOM_TIMERS static long DEFAULT_TIMER_VALUE [7] = { 0, 1000000, 2000000, 1000000, 10000000, 5000000, 0 }; #endif char *EVENT_ACTION_NAME[9] = { "ZERO_ACTION", "NAK_SND_WAIT", "RET_RCV_WAIT", "RET_SND_WAIT", "REF_SND_WAIT", "LEV_GRP_WAIT", "SUPPRESSED_NAK", "RET_RCV_EXPIRED", "UNKNOWN"}; #ifdef SOLARIS pthread_mutex_t event_list_mutex; #else pthread_mutex_t event_list_mutex = PTHREAD_MUTEX_INITIALIZER; #endif extern CACHE *cache; extern USER_INFO local_user_info; /* * inline means that the precompiler will replace the calling of getRemaining time with the * code of the function, i.e., the function will not exist in compile time */ inline void getRemainingTime(EVENT_LIST **el, long double*remaining_time, char *msg); EVENT_LIST * eventListFind2(EVENT_LIST **el1,MEMBER_ID *member_id, char action, int sn, EVENT_LIST **antNode); extern GLOBAL_OPTIONS rmcast_options; /*---------------- Auxiliary functions to manipulate the timer ---------------------------------------*/ /*************************************************************************************** * * float generateSample(char distribution) * * Generates a random sample. * * Arguments: distribution, the distribution of the random var (not yet implemented). * * Returns: a random number between 0 and 1. * ***************************************************************************************/ float generateSample(char distribution) { double sample=0,uniform=0; double e,lambda; switch(distribution) { case UNIFORM: sample=((double)random()/(double)RAND_MAX); break; case EXPONENTIAL: e = exp( 1 ); /* Lambda must be log(number of members of the multicast group) + 1 */ lambda = log( cacheCountMembers( cache,CACHE_STATUS_ACTIVE ) ) + 1; uniform = ((double)random()/(double)RAND_MAX); sample = -(log(uniform)/lambda); break; default: fprintf(stderr,"generateSample ERROR: unknown distribution=%c",distribution); } return ( sample ); } /*************************************************************************************** * * int generateTimerValue(MEMBER_ID member_id, char action, char distribution) * * Generates a timer value corresponding to the defined action. This value indicates * in how many microseconds the action will be executed. * * Arguments: member_id, member id of the member related to the event * action, the action to be executed. * distribution, the distribution of the random var (not yet implemented). * * Returns: the timer value, in microseconds. * ***************************************************************************************/ int generateTimerValue(char action, char distribution, char *sender_ip) { int retval; int estimated_delay, /* estimated one-way delay */ timerlow, /* lower bound for the timer interval */ timerhigh; /* higher bound for the timer interval */ retval = 0; switch((int)action){ case NAK_SND_WAIT: #ifndef RANDOM_TIMERS retval = DEFAULT_TIMER_VALUE[(int)action]; #else if (RM_getHostDelay(sender_ip,&estimated_delay) > 0){ timerlow= rmcast_options.timer_paramA*estimated_delay; timerhigh= (rmcast_options.timer_paramA+rmcast_options.timer_paramB)*estimated_delay; retval = (int)1000*( (timerhigh - timerlow) * generateSample(distribution) + timerlow); /* fprintf(stderr,"Using timer related to %s:%d %d %d %d\n",sender_ip,(int)action,timerlow,timerhigh,retval); */ } else{ RM_getHostDelay("DEFAULT",&estimated_delay); timerlow= rmcast_options.timer_paramA*estimated_delay; timerhigh= (rmcast_options.timer_paramA+rmcast_options.timer_paramB)*estimated_delay; retval = (int)1000*( (timerhigh - timerlow) * generateSample(distribution) + timerlow); /* fprintf(stderr,"Using timer related to %s:%d %d %d %d\n",sender_ip,(int)action,timerlow,timerhigh,retval); */ } #endif break; case RET_RCV_WAIT: #ifndef RANDOM_TIMERS retval = DEFAULT_TIMER_VALUE[(int)action]; #else if (RM_getHostDelay(sender_ip,&estimated_delay) > 0){ timerlow= rmcast_options.timer_paramC*estimated_delay; timerhigh= (rmcast_options.timer_paramC+rmcast_options.timer_paramD)*estimated_delay; retval = (int)1000*( (timerhigh - timerlow) * generateSample(distribution) + timerlow); /* fprintf(stderr,"Using timer related to %s:%d %d %d %d\n",sender_ip,(int)action,timerlow,timerhigh,retval); */ } else{ RM_getHostDelay("DEFAULT",&estimated_delay); timerlow= rmcast_options.timer_paramA*estimated_delay; timerhigh= (rmcast_options.timer_paramA+rmcast_options.timer_paramB)*estimated_delay; retval = (int)1000*( (timerhigh - timerlow) * generateSample(distribution) + timerlow); /* fprintf(stderr,"Using timer related to %s:%d %d %d %d\n",sender_ip,(int)action,timerlow,timerhigh,retval); */ } #endif break; case RET_SND_WAIT: #ifndef RANDOM_TIMERS retval = DEFAULT_TIMER_VALUE[(int)action]; #else if (RM_getHostDelay(sender_ip,&estimated_delay) > 0){ timerlow= rmcast_options.timer_paramE*estimated_delay; timerhigh= (rmcast_options.timer_paramE+rmcast_options.timer_paramF)*estimated_delay; retval = (int)1000*( (timerhigh - timerlow) * generateSample(distribution) + timerlow); /* fprintf(stderr,"Using timer related to %s:%d %d %d %d\n",sender_ip,(int)action,timerlow,timerhigh,retval); */ } else{ RM_getHostDelay("DEFAULT",&estimated_delay); timerlow= rmcast_options.timer_paramC*estimated_delay; timerhigh= (rmcast_options.timer_paramC+rmcast_options.timer_paramD)*estimated_delay; retval = (int)1000*( (timerhigh - timerlow) * generateSample(distribution) + timerlow); /* fprintf(stderr,"Using timer related to %s:%d %d %d %d\n",sender_ip,(int)action,timerlow,timerhigh,retval); */ } #endif break; case REF_SND_WAIT: retval = rmcast_options.refresh_timer*1000000; break; case LEV_GRP_WAIT: retval = rmcast_options.leave_group_wait_time; break; default: fprintf(stderr,"generateTimerValue Warning: Unknow action=%d\n",action); } return ( retval ); } /*************************************************************************************** * * inline void getRemainingTime(EVENT_LIST **el, long double*remaining_time, char *msg) * * Gets the remaining time to execute a specific action in the event list. * * Arguments: el, the event list; * remaining_time, the remaining time to execute the action; * msg, an error message to be shown if remaining_time <= 0. * ***************************************************************************************/ inline void getRemainingTime(EVENT_LIST **el, long double *remaining_time, char *msg) { struct timeval current_time; gettimeofday(¤t_time, 0); (*remaining_time) = (*el)->timer_value - ( getTimerValue(&(current_time))- getTimerValue(&((*el)->last_update_time)) ); if (*remaining_time <= 0) { #ifdef DEBUG_EVENTS fprintf(stderr,"Error: remaining time < 0\n"); fprintf(stderr,"\tRemaining time: %.0Lf \n",*remaining_time); fprintf(stderr,"\tCurrent time : %.0Lf \n",getTimerValue(&(current_time)) ); fprintf(stderr,"\tLast update time : %.0Lf \n",getTimerValue(&((*el)->last_update_time)) ); if (msg!=NULL) fprintf(stderr,"\tmsg : %s \n",msg ); #endif (*remaining_time) = 0; } } /*************************************************************************************** * * void setTimerValue(struct itimerval *value, long int time) * * Converts the time from microseconds to struct itimerval. * * Arguments: value, where the converted value will be stored (a struct itimerval); * time, the time in microseconds. * ***************************************************************************************/ void setTimerValue(struct itimerval *value, long int time) { (*value).it_interval.tv_sec = 0; (*value).it_interval.tv_usec = 0; (*value).it_value.tv_sec = time/1000000; (*value).it_value.tv_usec = time%1000000; } /*************************************************************************************** * * long double getTimerValue(struct timeval *value ) * * Converts the time from struct timeval to microseconds. * * Arguments: value, the struct timeval source. * * Returns: the time, in microseconds. * ***************************************************************************************/ long double getTimerValue(/* struct itimerval *value */ struct timeval *value ) { return (((long double)(*value).tv_sec*1000000)+((long double)(*value).tv_usec)); } /*---------------- Main functions to manipulate the event list ---------------------------------------*/ /*************************************************************************************** * * void eventListInit(EVENT_LIST **el) * * Initialize the event list. * * Arguments: el, the event list; * ***************************************************************************************/ void eventListInit(EVENT_LIST **el) { #ifdef SOLARIS pthread_mutex_init(&event_list_mutex,NULL); #endif *el = NULL; /* * FIXME under unicast mode, it doesn't make sense to have long timer values * if (rmcast_options.transmission_mode == UNICAST) * { * * int i; * * for (i=0; i<6; i++) * DEFAULT_TIMER_VALUE [i] /= 10000; * } */ } /*************************************************************************************** * * int eventListAllocNode(EVENT_LIST **el_node, MEMBER_ID *member, char action, * int sn, long timer_value) * * Allocates a event list node, and fills it with specified info. * * Arguments: el_node, the node which will be created; * member, action, sn and timer_value hold info. to be stored in new node. * * Returns: 0 on error, 1 on success. * ***************************************************************************************/ int eventListAllocNode(EVENT_LIST **el_node, MEMBER_ID *member, char action, int sn, long timer_value) { if ((*el_node = (EVENT_LIST*)malloc(sizeof(EVENT_LIST)))==NULL) { return (0); } (*el_node)->member_id = member; (*el_node)->action = action; (*el_node)->timer_value = timer_value; (*el_node)->sn = sn; gettimeofday( &((*el_node)->last_update_time), 0) ; (*el_node)->next = NULL; return (1); } /*************************************************************************************** * * int eventListInsert(EVENT_LIST **el, MEMBER_ID *member_id, char *sender_ip, char action, int sn) * * Inserts an event node in the event list. * * Arguments: el, the event list; * member_id, the member identification; * sender_ip, the IP address of the sender. Used for host related timer generation * action, event action to be executed; * sn, sequence number of the message to retransmited/requested. * ***************************************************************************************/ int eventListInsert(EVENT_LIST **el, MEMBER_ID *member_id, char *sender_ip, char action, int sn) { EVENT_LIST *newNode, *auxNode, *antNode; long int timer_value=0, accumulator=0; long double remaining_time; struct timeval current_time; int retval = -2; #ifdef SINGLE_NACK int i = -1; int nack_sn = -1; int aux_bit_value = 0; int event_flag = 0; int control = 0; int cont = 0; CACHE *aux_cache_member; cacheShow(cache); aux_cache_member = cacheLookForMember(&cache, member_id); #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventListInsert: [aux_cache_member: %p &cache: %p member_id: %p]\n",aux_cache_member,&cache,member_id); #endif #ifdef DNAK_RCV fprintf(stderr,"DNAK_RCV eventListInsert: entering. Action=%d sn=%d\n",action,sn); #endif if( aux_cache_member != NULL ) { switch ( action ) { case NAK_SND_WAIT: /* Trying to insert a single NACK */ for ( i = aux_cache_member->sm_info.member_status.last_seq_rcv+1; i <= aux_cache_member->sm_info.member_status.window_size + aux_cache_member->sm_info.member_status.last_seq_rcv ; i ++ ) { /* Note: the first bit of the mask always refer to the packet with sn = last_seq_rcv + 1 */ #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK eventListInsert: before window_mask_get_bit call. Event action=%d sn=%d i=%d\n",action,sn,i); #endif aux_bit_value = window_mask_get_bit( aux_cache_member->sm_info.member_status.window_mask,i, &aux_cache_member->sm_info.member_status ); if ( ( aux_bit_value == NAK_SND_WAIT ) || ( aux_bit_value == RET_RCV_WAIT ) ) { /* NAK_SND_WAIT or RET_RCV_WAIT already exists */ control = aux_bit_value; break; } } if ( control == RET_RCV_WAIT ) { /* RET_RCV_WAIT event exists - just set the bit to RET_RCV_WAIT, the nack will be send in the next time */ window_mask_set_bit( aux_cache_member->sm_info.member_status.window_mask,sn, &aux_cache_member->sm_info.member_status, RET_RCV_WAIT ); } else { if( cacheUpdateNakList(&cache, member_id, sn) > 0 ) { window_mask_set_bit( aux_cache_member->sm_info.member_status.window_mask,sn, &aux_cache_member->sm_info.member_status, NAK_SND_WAIT ); } else { /* * We have sent the max number of NAK (see rmcast_options structure) we didn't recover the packet * so we must exit because we cannot keep the reliability */ fprintf(stderr,"********\n"); fprintf(stderr,"eventListInsert ERROR: Recovering packet failed. Max number (%d) of NAKs reached!\n",rmcast_options.max_nak); fprintf(stderr,"\tHost IP:PID=%s:%d\tsn=%d\n",member_id->ip,member_id->pid,i); fprintf(stderr,"********\n"); RM_leaveGroup(local_user_info.socket, local_user_info.member_id.ip); } if( control == 0 ) { /* We have to insert a new event */ event_flag = NAK_SND_WAIT; } } break; case RET_RCV_EXPIRED: /* RET_RCV_WAIT event has expired: change bits 2 to 1 in the mask and create NAK_SND_WAIT event */ for ( i = aux_cache_member->sm_info.member_status.last_seq_rcv+1; i <= aux_cache_member->sm_info.member_status.window_size + aux_cache_member->sm_info.member_status.last_seq_rcv ; i ++ ) { /* Note: the first bit of the mask always refer to the packet with sn = last_seq_rcv + 1 */ #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK eventListInsert: before window_mask_get_bit call. Event action=%d sn=%d i=%d\n",action,sn,i); #endif aux_bit_value = window_mask_get_bit( aux_cache_member->sm_info.member_status.window_mask,i, &aux_cache_member->sm_info.member_status ); if ( aux_bit_value == RET_RCV_WAIT ) { if( cacheUpdateNakList(&cache, member_id, i) > 0 ) { window_mask_set_bit( aux_cache_member->sm_info.member_status.window_mask,i, &aux_cache_member->sm_info.member_status, NAK_SND_WAIT ); } else { /* * We have sent the max number of NAK (see rmcast_options structure) we didn't recover the packet * so we must exit because we cannot keep the reliability */ fprintf(stderr,"********\n"); fprintf(stderr,"eventListInsert ERROR: Recovering packet failed. Max number (%d) of NAKs reached!\n",rmcast_options.max_nak); fprintf(stderr,"\tHost IP:PID=%s:%d\tsn=%d\n",member_id->ip,member_id->pid,i); fprintf(stderr,"********\n"); RM_leaveGroup(local_user_info.socket, local_user_info.member_id.ip); } } } event_flag = NAK_SND_WAIT; break; case RET_RCV_WAIT: /* NAK_SND_WAIT has expired: change bits 1 to 2 in the mask and create RET_RCV_WAIT event */ for( i = aux_cache_member->sm_info.member_status.last_seq_rcv+1; i <= aux_cache_member->sm_info.member_status.window_size + aux_cache_member->sm_info.member_status.last_seq_rcv ; i ++ ) { /* Note: the first bit of the mask always refer to the packet with sn = last_seq_rcv + 1 */ #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK eventListInsert: before window_mask_get_bit call. Event action=%d sn=%d i=%d\n",action,sn,i); #endif aux_bit_value = window_mask_get_bit( aux_cache_member->sm_info.member_status.window_mask,i, &aux_cache_member->sm_info.member_status ); if( ( aux_bit_value == NAK_SND_WAIT ) || ( aux_bit_value == SUPPRESSED_NAK ) ) { window_mask_set_bit( aux_cache_member->sm_info.member_status.window_mask, i, &aux_cache_member->sm_info.member_status, RET_RCV_WAIT ); } } #ifdef DNAK_RCV fprintf( stderr, "DNAK_RCV eventListInsert: Now we have to insert a RET_RCV_WAIT event!\n"); #endif event_flag = RET_RCV_WAIT; break; case SUPPRESSED_NAK: /* Suppress NAK identified by sn */ for( i = aux_cache_member->sm_info.member_status.last_seq_rcv+1; i <= aux_cache_member->sm_info.member_status.window_size + aux_cache_member->sm_info.member_status.last_seq_rcv ; i ++ ) { /* Note: the first bit of the mask always refer to the packet with sn = last_seq_rcv + 1 */ #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK eventListInsert: before window_mask_get_bit call. Event action=%d sn=%d i=%d\n",action,sn,i); #endif aux_bit_value = window_mask_get_bit( aux_cache_member->sm_info.member_status.window_mask,i, &aux_cache_member->sm_info.member_status ); if( ( aux_bit_value == NAK_SND_WAIT ) ) { /* NAK_SND_WAIT already exists, add 1 to cont */ control = aux_bit_value; nack_sn = i; cont++; } if( aux_bit_value == RET_RCV_WAIT ) { /* RET_RCV_WAIT already exists */ control = aux_bit_value; break; } } if (control == RET_RCV_WAIT ) { /* No need to set the bit to SUPPRESSED_NAK because no NAK_SND_WAIT event exists */ window_mask_set_bit( aux_cache_member->sm_info.member_status.window_mask, sn, &aux_cache_member->sm_info.member_status, RET_RCV_WAIT ); } else if( control == NAK_SND_WAIT ) { window_mask_set_bit( aux_cache_member->sm_info.member_status.window_mask, sn, &aux_cache_member->sm_info.member_status, SUPPRESSED_NAK ); #ifdef DSUPPRESSION fprintf(suppressionfile,"nk %s %s %d %d\n",sender_ip,member_id->ip,member_id->pid,sn); #endif if( ( nack_sn == sn ) && ( cont == 1) ) { /* * We have changed the last NAK bit to SUPPRESSED_NAK. * now we have to change each SUPPRESSED_NAK bit to RET_RCV_WAIT * and insert a RET_RCV_WAIT event */ #ifdef DSUPPRESSION fprintf(suppressionfile,"NK %s %s %d %d\n",sender_ip,member_id->ip,member_id->pid,sn); #endif for( i = aux_cache_member->sm_info.member_status.last_seq_rcv+1; i <= aux_cache_member->sm_info.member_status.window_size + aux_cache_member->sm_info.member_status.last_seq_rcv ; i ++ ) { /* Note: the first bit of the mask always refer to the packet with sn = last_seq_rcv + 1 */ #ifdef DWINDOW_MASK fprintf(stderr,"DWINDOW_MASK eventListInsert: before window_mask_get_bit call. Event action=%d sn=%d i=%d\n",action,sn,i); #endif aux_bit_value = window_mask_get_bit( aux_cache_member->sm_info.member_status.window_mask,i, &aux_cache_member->sm_info.member_status ); if( ( aux_bit_value == NAK_SND_WAIT ) ) { window_mask_set_bit( aux_cache_member->sm_info.member_status.window_mask, i, &aux_cache_member->sm_info.member_status, RET_RCV_WAIT ); } } event_flag = RET_RCV_WAIT; } } else { window_mask_set_bit( aux_cache_member->sm_info.member_status.window_mask, sn, &aux_cache_member->sm_info.member_status, RET_RCV_WAIT ); event_flag = RET_RCV_WAIT; } break; default: event_flag = action; } } else { event_flag = action; } if ( event_flag > 0 ) { action = event_flag; #endif /* Single NACK */ #ifdef DNAK_RCV fprintf(stderr,"After switch (action) --> action == %d\n",action); #endif gettimeofday(¤t_time, 0); auxNode = *el; if (*el!=NULL) { getRemainingTime(el,&remaining_time,"(Called from eventListInsert)\n"); } else { remaining_time = 0; } #ifdef DEBUG_EVENTS fprintf(stderr,"DEBUG_EVENTS eventListInsert: current event list:\n"); eventListShow(*el); fprintf(stderr,"DEBUG_EVENTS eventListInsert: node to be inserted:\n"); fprintf(stderr,"DEBUG_EVENTS eventListInsert: action: %d sn: %d\n", action, sn); fprintf(stderr,"DEBUG_EVENTS eventListInsert: remaining time: %.0Lf\n", remaining_time); fprintf(stderr,"DEBUG_EVENTS eventListInsert: current time %.0Lf\n\n", getTimerValue(¤t_time) ); #endif if (*el!=NULL) { /* .. and set the timer value of the header of the list to the remaining time to the first event occur */ (*el)->timer_value = remaining_time; (*el)->last_update_time = current_time; } timer_value=generateTimerValue(action,rmcast_options.timer_distribution,sender_ip); #ifdef DEBUG_EVENTS fprintf(stderr,"DEBUG_EVENTS eventListInsert: time %ld\n\n", timer_value ); #endif if ((eventListAllocNode(&newNode,member_id,action,sn,timer_value))==(int)NULL) { return (0); } if (auxNode == NULL) /* if the list is empty... */ { (*el) = newNode; } else { if (newNode->timer_value < auxNode->timer_value) { /* if the node to be inserted is the first of the list...*/ (newNode)->next = auxNode; (*el) = newNode; (newNode)->next->timer_value -= newNode->timer_value; } else { antNode = auxNode; accumulator = auxNode->timer_value; while(accumulator < newNode->timer_value) { antNode = auxNode; auxNode = auxNode->next; if (auxNode==NULL) break; accumulator += auxNode->timer_value; } if (auxNode == NULL) { /* ... if the node to be inserted is the last of the list... */ antNode->next = newNode; newNode->timer_value -= accumulator; } else { if (auxNode!=antNode) { /* ... if the node to be inserted is in the middle of the list */ newNode->next = auxNode; antNode->next = newNode; #ifdef DEBUG_EVENTS fprintf(stderr,"DEBUG_EVENTS eventListInsert: accumulator: %ld newNode->timer_value: %ld antNode->timer_value: %ld auxNode->timer_value: %ld", accumulator , newNode->timer_value , antNode->timer_value, auxNode->timer_value); #endif newNode->timer_value -= (accumulator - auxNode->timer_value); auxNode->timer_value -= newNode->timer_value; } else { /* ... finally, if the node to be inserted has a time value equal to the first of the list... */ newNode->next = antNode->next; antNode->next = newNode; newNode->timer_value = 0; } } } } #ifdef DEBUG_SHOW eventListShow(*el); #endif #ifdef DEBUG_EVENTS fprintf(stderr,"DEBUG_EVENTS eventListInsert: sending SIGUSR1 signal\n"); #endif retval = pthread_kill(signal_handler_thread, SIGUSR1); if ( retval ) { fprintf(stderr,"eventListInsert ERROR: pthread_kill error: %d \n",retval); } #ifdef DEBUG_EVENTS else { fprintf(stderr,"DEBUG_EVENTS eventListInsert: signal sent\n"); } #endif #ifdef DNAK_RCV fprintf(stderr, "eventListInsert: showing Event List before leaving\n"); eventListShow(*el); #endif #ifdef SINGLE_NACK } /* if (control >0 ) */ #endif return (1); } /*************************************************************************************** * * void eventListShow(EVENT_LIST *el) * * Shows the event list. * * Arguments: el, the event list. * ***************************************************************************************/ void eventListShow(EVENT_LIST *el) { #ifdef DEBUG_EVENTS EVENT_LIST *aux; int i=0; long double remaining_time; struct timeval current_time; gettimeofday(¤t_time, 0); aux = el; fprintf(stderr,"\n----------EventList------------\n\n"); if (aux==NULL) { fprintf(stderr,"EventList is EMPTY\n"); fprintf(stderr,"\n------------------------------\n\n"); return; } fprintf(stderr,"aux: %p\n",aux); for (;aux!=NULL;aux=aux->next) { fprintf(stderr," [%p](ip=%s pid=%d action=%2d sn=%2d timer=%8ld) -> ", aux, ((aux->member_id!=NULL)?aux->member_id->ip:"NULL"), ((aux->member_id!=NULL)?aux->member_id->pid:-1), aux->action, aux->sn, aux->timer_value); if (i%2) fprintf(stderr,"\n"); i++; } fprintf(stderr," NULL\n"); fprintf(stderr," eventListShow: number of nodes in event list=%d\n",i); if (el!=NULL) { getRemainingTime(&el,&remaining_time,"Called from eventListShow"); } fprintf(stderr,"\n------------------------------\n\n"); #endif } /*************************************************************************************** * * int eventListRemoveFirst(EVENT_LIST **el) * * Removes the first element of the event list. * * Arguments: el, the event list. * * Return: 1, on success; * 0, on fail. * * Pay Attention! * * This function neither sends any signal, nor calls any time related function. * ***************************************************************************************/ int eventListRemoveFirst(EVENT_LIST **el) { EVENT_LIST *ant; /* #ifdef SINGLE_NACK int i = 0; CACHE *aux_cache_member = cacheLookForMember(&cache, (*el)->member_id); if ( (*el != NULL) && (aux_cache_member != NULL )) { if ( (*el) -> action == NAK_SND_WAIT ) { for ( i = 0; i < MAX_WINDOW_SIZE ; i ++ ) { if ( window_mask_get_bit2( aux_cache_member->sm_info.member_status.window_mask, i ) == NAK_SND_WAIT ) { window_mask_set_bit2( aux_cache_member->sm_info.member_status.window_mask, i , RET_RCV_WAIT ); } } } else if ( (*el) -> action == RET_RCV_WAIT ) { for ( i = 0; i < MAX_WINDOW_SIZE ; i ++ ) { if ( window_mask_get_bit2( aux_cache_member->sm_info.member_status.window_mask, i ) == RET_RCV_WAIT ) { window_mask_set_bit2( aux_cache_member->sm_info.member_status.window_mask, i , NAK_SND_WAIT ); } } } } #endif */ if (*el==NULL) { return (0); } else { ant = *el; (*el) = (*el)->next; free(ant); return (1); } } /*************************************************************************************** * * int eventListRemove(EVENT_LIST **el, MEMBER_ID *member_id, char action, int sn) * * Arguments: el, the event list; * member_id, action and sn, identify the node to be removed; * * Return value: 1 on success; * 0 otherwise. * ***************************************************************************************/ int eventListRemove(EVENT_LIST **el, MEMBER_ID *member_id, char action, int sn) { EVENT_LIST *ant_node; int retval = 0; EVENT_LIST *node_to_be_removed; long double remaining_time=0; struct timeval current_time; #ifdef SINGLE_NACK int i = 0; CACHE *aux_cache_member; aux_cache_member = cacheLookForMember(&cache, member_id); if(aux_cache_member!=NULL) { #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventListRemove: Trying to remove event action=%d\n",action); #endif #ifdef DNAK_RCV fprintf(stderr, "eventListRemove: Trying to remove event action=%d\n",action); #endif if ( action == NAK_SND_WAIT || action == RET_RCV_WAIT ) { if( ( sn <= aux_cache_member->sm_info.member_status.last_seq_rcv ) || ( sn > aux_cache_member->sm_info.member_status.last_seq_rcv + aux_cache_member->sm_info.member_status.window_size ) ) { #ifdef DNAK_RCV fprintf( stderr,"eventListRemove: There is no such event because sn=%d is out of the window_mask action=%d\n",sn,action); #endif return 0; } #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventlistremove: member_status.last_seq_rcv=%d,member_status.window_ini=%d\n",aux_cache_member->sm_info.member_status.last_seq_rcv,aux_cache_member->sm_info.member_status.window_ini); #endif if ( window_mask_get_bit( aux_cache_member->sm_info.member_status.window_mask, sn, &(aux_cache_member->sm_info.member_status) ) == action ) { window_mask_set_bit( aux_cache_member->sm_info.member_status.window_mask, sn, &(aux_cache_member->sm_info.member_status), 0 ); /* Remove node from member's NAK list */ /* FIXME cacheDeleteNakNode( cache, member_id, sn); */ for ( i = aux_cache_member->sm_info.member_status.last_seq_rcv + 1; i <= aux_cache_member->sm_info.member_status.window_size + aux_cache_member->sm_info.member_status.last_seq_rcv ; i ++ ) { if ( window_mask_get_bit( aux_cache_member->sm_info.member_status.window_mask, i, &aux_cache_member->sm_info.member_status ) == action ) { return 1; } } } else return 0; } } #endif /*SINGLE NACK*/ node_to_be_removed= eventListFind(el,member_id,action,sn,&ant_node); #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventlistRemove: after looking for event, action=%d,sn=%d.\n",action,sn); #endif #ifdef DNAK_RCV fprintf(stderr, "eventlistRemove: after looking for event, action=%d,sn=%d.\n",action,sn); #endif if (node_to_be_removed==NULL) { #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventlistRemove:event (action=%d sn=%d) not found.\n",action,sn); #endif #ifdef DNAK_RCV fprintf(stderr, "eventlistRemove:event (action=%d sn=%d) not found.\n",action,sn); #endif return (0); } else { #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventlistRemove: event (action=%d sn=%d) found.\n",action,sn); #endif #ifdef DNAK_RCV fprintf(stderr, "eventlistRemove: event (action=%d sn=%d) found.\n",action,sn); #endif if (ant_node == NULL) { /* the node to be removed is the first node of the list */ if (*el!=NULL) { getRemainingTime(el,&remaining_time,"(eventListRemove)\n"); } else { remaining_time = 0; } *el = (*el)->next; if (*el!=NULL) { (*el)->timer_value += remaining_time; gettimeofday(¤t_time, 0); (*el)->last_update_time = current_time; if ((*el)->timer_value == 0) { #ifdef DEBUG_EVENTS fprintf(stderr,"DEBUG_EVENTS eventListRemove warning: the alarm was restarted.\n"); #endif eventListShow(*el); } } retval = pthread_kill(signal_handler_thread, SIGUSR1); if ( retval ) { fprintf(stderr,"evenListRemove ERROR: trying to kill signal handler thread retval=%d \n",retval); } } else { if (node_to_be_removed->next!=NULL) { node_to_be_removed->next->timer_value += node_to_be_removed->timer_value; ant_node->next = node_to_be_removed -> next; } else { /* the node to be removed is the last node of the list */ ant_node->next = NULL; } } } free(node_to_be_removed); node_to_be_removed = NULL; return (1); } int eventListIsEqual(EVENT_LIST *node1, EVENT_LIST *node2) { if ((node1->member_id == NULL) || (node2->member_id == NULL)) { #ifdef SINGLE_NACK #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventListIsEqual: node null, node1=%p node2=%p\n",node1->member_id,node2->member_id); #endif if ( node1->action == NAK_SND_WAIT || node1->action == RET_RCV_WAIT ) { if ( node1->action == node2->action ) { #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventListIsEqual: (first return) event is equal action=%d\n",node1->action); #endif return 1; } else { #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventListIsEqual: (first return) event is not equal action=%d\n",node1->action); #endif return 0; } } #endif if ( (node1->action == node2->action) && (node1->sn == node2->sn)) return 1; else return 0; } #ifdef SINGLE_NACK if ( node1->action == NAK_SND_WAIT || node1->action == RET_RCV_WAIT ) { if ((!strcmp(node1->member_id->ip, node2->member_id->ip)) && (node1->member_id->pid == node2->member_id->pid) && (node1->action == node2->action) ) { #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventListIsEqual: (second return) event is equal action=%d\n",node1->action); #endif return (1); } else { #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventListIsEqual: (second return) event is equal action=%d\n",node1->action); #endif return (0); } } #endif if ((!strcmp(node1->member_id->ip, node2->member_id->ip)) && (node1->member_id->pid == node2->member_id->pid) && (node1->action == node2->action) && (node1->sn == node2->sn)) return (1); else return (0); } /*************************************************************************************** * * EVENT_LIST * eventListFind(EVENT_LIST **el1,MEMBER_ID *member_id, char action, * int sn, EVENT_LIST **antNode) * * Search for a node in the event list. * * Arguments: el1, the event list; * member_id, action and sn, identify the node to be found; * antNode, return a pointer to the node that points to the one, * or NULL if the node removed is the last one. * * Return value: a pointer to the node found, or NULL if the node wasn't found. * ***************************************************************************************/ EVENT_LIST * eventListFind(EVENT_LIST **el1,MEMBER_ID *member_id, char action, int sn, EVENT_LIST **antNode) { EVENT_LIST *el; EVENT_LIST *event_node, *auxPointer; *antNode = NULL; el = *el1; auxPointer = el; #ifdef SINGLE_NACK { CACHE *aux_cache_member = NULL; aux_cache_member = cacheLookForMember(&cache, member_id); #ifdef DNAK_RCV fprintf(stderr,"eventListFind: looking for ip:pid:sn:action = %s:%d:%d:%d\n", member_id->ip, member_id->pid, sn, action); eventListShow(el); #endif if ( aux_cache_member != NULL ) { if ( sn > ( aux_cache_member->sm_info.member_status.last_seq_rcv + aux_cache_member->sm_info.member_status.window_size ) ) { #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventListFind: sn=%d is out of window(last_seq_rcv+1,last_seq_rcv+MAX_WINDOW_SIZE)=(%d,%d)!\n", sn, aux_cache_member->sm_info.member_status.last_seq_rcv, aux_cache_member->sm_info.member_status.last_seq_rcv + MAX_WINDOW_SIZE); #endif #ifdef DNAK_RCV fprintf(stderr,"eventListFind: sn=%d is out of window(last_seq_rcv+1,last_seq_rcv+MAX_WINDOW_SIZE)=(%d,%d)!\n", sn, aux_cache_member->sm_info.member_status.last_seq_rcv, aux_cache_member->sm_info.member_status.last_seq_rcv + MAX_WINDOW_SIZE); #endif return NULL; } } else { #ifdef DSINGLE_NACK fprintf(stderr,"DSINGLE_NACK eventListFind: no such member found in the cache!\n"); #endif #ifdef DNAK_RCV fprintf(stderr,"eventListFind: member found in the cache: %s:%d\n",member_id->ip,member_id->pid); #endif return NULL; } } #endif #ifdef DEBUG_EVENTS fprintf(stderr,"DEBUG_EVENTS eventListFind: Inside listfind\n ip: %s\n pid: %d\n action:%d\n sn: %d\n######\n", member_id->ip, member_id->pid, action, sn); #ifdef DEBUG_SHOW eventListShow(el); #endif #endif if ((eventListAllocNode(&event_node, member_id, action, sn, 0))==(int)NULL) { perror("eventListFind: Alloc list node at eventListFind"); RM_leaveGroup(local_user_info.socket, local_user_info.member_id.ip); } while (auxPointer!=NULL) { if (eventListIsEqual(event_node, auxPointer)) { /* The event was found! */ break; } *antNode = auxPointer; auxPointer = auxPointer->next; } free(event_node); return (auxPointer); } #endif tgif-QPL-4.2.5/rmcast/src/rmtcp.c0000644000076400007640000001540011141162245016341 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmtcp.c ------------------- begin : 2002 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #include "rmtcp.h" #include "rminternals.h" #include #include #ifndef TRUE #define TRUE 1 #define FALSE 0 #endif extern USER_INFO local_user_info; extern sigset_t alrmset; extern FILE *logfile; /* extern char rmcast_tcp_ip[IP_STRING_SIZE]; extern int *rmcast_pipe; extern int rmcast_tcp_port; */ extern GLOBAL_OPTIONS rmcast_options; extern CACHE *cache; extern int errno; #ifdef SOLARIS #include #include #include #include #endif #include #define min(a,b) ((asize), sizeof(int)); cur_status->data = (char*)malloc((cur_status->size)+1); retval = read(sockfd, cur_status->data, cur_status->size); #ifdef DEBUG_TCP { int auxi; for(auxi=0; auxidata[(int)auxi], isalnum((int)cur_status->data[(int)auxi])?cur_status->data[(int)auxi]:'-'); } } fprintf(stderr,"\n"); #endif /* Now, we will read the cache */ read(sockfd, &(cs_cache.size), sizeof(int)); cs_cache.data = (char*)malloc((cs_cache.size)+1); retval = read(sockfd, cs_cache.data, cs_cache.size); cacheUnpack(&cache, cs_cache.data, cs_cache.size); cacheShow(cache); close(sockfd); return TRUE; } #ifndef SOLARIS #include #include typedef socklen_t SOCKLEN_DECL_TYPE; #else typedef int SOCKLEN_DECL_TYPE; #endif void * rmcastSendTCPStatus(void *arg) { int retval; int listenfd, connfd; SOCKLEN_DECL_TYPE len; struct sockaddr_in servaddr, cliaddr; #ifdef DEBUG_TCP char buff[10000]; #endif int cont = 0; /* * #ifdef SOLARIS * * sigset_t alrmset; * * sigfillset(&alrmset); * * * * pthread_sigmask(SIG_BLOCK, &alrmset, NULL); * * #endif */ #ifdef DEBUG_TCP fprintf(stderr,"Initializing the 'current status server'\n"); #endif if ((listenfd = socket(AF_INET, SOCK_STREAM, 0)) == -1) { perror("socket error"); return FALSE; } bzero(&servaddr, sizeof(servaddr)); servaddr.sin_family = AF_INET; servaddr.sin_addr.s_addr = htonl(INADDR_ANY); servaddr.sin_port = htons(10013); /* 271d hexa */ retval = -1; while (retval==-1) { #ifndef SOLARIS if ((retval = bind(listenfd, (const struct sockaddr *) &servaddr, sizeof(servaddr)))==-1) #else if ((retval = bind(listenfd, (struct sockaddr *) &servaddr, sizeof(servaddr)))==-1) #endif { #ifdef DEBUG_TCP fprintf(stderr,"bind error: %s (%d)\n",strerror(errno),retval); #endif cont ++; servaddr.sin_port = htons(10013 + cont); /* trying next port */ } } rmcast_options.tcp_port = 10013 + cont; #ifdef DEBUG_TCP fprintf(stderr,"Using tcp port %d\nWaiting listen... \n", rmcast_options.tcp_port); #endif if ((retval = listen(listenfd, LISTENQ))) { fprintf(stderr,"listen error: %s\n",strerror(errno)); close (listenfd); return FALSE; } len = sizeof(cliaddr); while (1) { char tmp_buf[80]; #ifdef DEBUG_TCP fprintf(stderr,"Waiting for tcp connection... \n"); #endif connfd = accept(listenfd, (struct sockaddr *) &cliaddr, &len); #ifdef DEBUG_TCP #ifndef SOLARIS fprintf(stderr,"Connection from %s, port %d\n", inet_ntop(AF_INET, &cliaddr.sin_addr, buff, sizeof(buff)), ntohs(cliaddr.sin_port)); #endif #endif /* write connfd to pipe */ sprintf(tmp_buf, "c%1d", connfd); write(rmcast_options.pipe[1], (const void *)tmp_buf, (size_t)(strlen(tmp_buf)+1)); } close (listenfd); return NULL; } tgif-QPL-4.2.5/rmcast/src/rmmsg.c0000644000076400007640000001250211225226450016343 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rmmsg.c ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifndef MSG_C #define MSG_C #include #include "rmmsg.h" int s_qid = -1; /* message queue identifier * -1: queue not initialized * -2: queue removed * otherwise: queue identifier */ #ifdef SOLARIS pthread_mutex_t remove_queues_lock; #else pthread_mutex_t remove_queues_lock = PTHREAD_MUTEX_INITIALIZER; #endif /***************************************************************************************************** * * int init_queue() * * Initializes the message queue. * * Side effects: updates s_qid. * Returns > 0 id if OK * -1 if error * ******************************************************************************************************/ int init_queue() { int queue_id; int QKEY; #ifdef SOLARIS pthread_mutex_init(&remove_queues_lock,NULL); #endif QKEY = QKEY_BASE; while( ( queue_id = msgget( QKEY, IPC_CREAT | QPERM | IPC_EXCL ) ) == -1 ) { if( errno == EEXIST ) { #ifdef DEBUG_NET_MSGS fprintf( stderr,"DEBUG_NET_MSGS init_queue: Message queue key %d already used. Trying %d. \n", QKEY, QKEY + 1 ); #endif QKEY++; } else { perror( "init_queue: msgget failed" ); return -1; } } s_qid = queue_id; return( queue_id ); } /***************************************************************************************************** * * void remove_queues(int i) * * Removes the message queue. * * Side effects: sets s_qid to -2 on success. * ******************************************************************************************************/ void remove_queues( int i ) { pthread_mutex_lock( &remove_queues_lock ); if( s_qid != -2 ) { if( msgctl( s_qid, IPC_RMID, NULL ) == -1 ) fprintf( stderr, "remove_queues ERROR: Failed to remove message queue %d.\n", s_qid ); } s_qid = -2; pthread_mutex_unlock( &remove_queues_lock ); } /***************************************************************************************************** * * int messageQueueEnter(char *objname, int len) * * Puts a message of size len in the message queue. * * Arguments: objname, the message to be enqueued; * len, the size of the message. * * Return value: 0 on success; * -1 on error. * ******************************************************************************************************/ int messageQueueEnter( char *objname, int len ) { struct q_entry s_entry; int aux, ind; pthread_mutex_lock( &remove_queues_lock ); if (len > MAXOBN) { fprintf( stderr, "messageQueueEnter ERROR: Name too long!\n" ); return -1; } if( s_qid == -1 ) s_qid = init_queue(); if ( s_qid == -1 || s_qid == -2 ) { fprintf( stderr,"messageQueueEnter ERROR: init_queue() failed!\n" ); return -1; } #ifdef DEBUG_NET_MSGS fprintf( stderr,"DEBUG_NET_MSGS messageQueueEnter: preparing to send data to app.\n" ); #endif s_entry.mtype = ( long )1; /* converts len from base 10 to base 256 - least signif. digit is stored in mtext[0] */ for( aux = len, ind = 0; aux != 0; aux = aux/256, ind++ ) s_entry.mtext[ ind ] = aux % 256; /* FIXME: the following test is really necessary? */ if( ind > MSG_QUEUE_HEADER_SIZE ) { fprintf( stderr, "messageQueueEnter ERROR: You must increment the MSG_QUEUE_HEADER_SIZE. ind=%d\n", ind ); return -1; } memcpy( &(s_entry.mtext[MSG_QUEUE_HEADER_SIZE]), objname, len ); #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS messageQueueEnter: data ready!\n" ); #endif if( msgsnd( s_qid, &s_entry, len + MSG_QUEUE_HEADER_SIZE, 0 ) == -1 ) { perror( "messageQueueEnter: Couldn't send message to app - msgsnd failed!" ); pthread_mutex_unlock( &remove_queues_lock ); return -1; } #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS messageQueueEnter: data sent to app.\n" ); #endif pthread_mutex_unlock( &remove_queues_lock ); return 0; } #endif tgif-QPL-4.2.5/rmcast/src/Makefile.in0000644000076400007640000006004711566506143017136 0ustar williamwilliam# Makefile.in generated by automake 1.9.6 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = .. am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ subdir = src DIST_COMMON = $(nobase_include_HEADERS) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/configure.in am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/config/mkinstalldirs CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = `echo $$p | sed -e 's|^.*/||'`; am__installdirs = "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)" libLTLIBRARIES_INSTALL = $(INSTALL) LTLIBRARIES = $(lib_LTLIBRARIES) librmcast_la_LIBADD = am_librmcast_la_OBJECTS = librmcast_la-rmcache.lo \ librmcast_la-rmcast.lo librmcast_la-rmevent.lo \ librmcast_la-rminternals.lo librmcast_la-rmmsg.lo \ librmcast_la-rmmsgpckt.lo librmcast_la-rmtcp.lo \ librmcast_la-rmwinmask.lo librmcast_la_OBJECTS = $(am_librmcast_la_OBJECTS) DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/config/depcomp am__depfiles_maybe = depfiles COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(LIBTOOL) --tag=CC --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ SOURCES = $(librmcast_la_SOURCES) DIST_SOURCES = $(librmcast_la_SOURCES) nobase_includeHEADERS_INSTALL = $(install_sh_DATA) HEADERS = $(nobase_include_HEADERS) ETAGS = etags CTAGS = ctags DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMDEP_FALSE = @AMDEP_FALSE@ AMDEP_TRUE = @AMDEP_TRUE@ AMTAR = @AMTAR@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DSYMUTIL = @DSYMUTIL@ ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ F77 = @F77@ FFLAGS = @FFLAGS@ GREP = @GREP@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ NMEDIT = @NMEDIT@ OBJEXT = @OBJEXT@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ VERSION = @VERSION@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_F77 = @ac_ct_F77@ am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@ am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ lib_LTLIBRARIES = librmcast.la nobase_include_HEADERS = rmcast.h librmcast_la_SOURCES = rmcache.c rmcache.h rmcast.c rmcast.h rmevent.c rmevent.h \ rminternals.c rminternals.h rmmsg.c rmmsg.h rmmsgpckt.c \ rmmsgpckt.h rmstruct.h rmtcp.c rmtcp.h rmwinmask.c \ rmwinmask.h librmcast_la_CFLAGS = -Wall -fno-strict-aliasing \ -DSTR_VERSION=\"$(PACKAGE_VERSION)\" \ -DRANDOM_TIMERS -DREFRESH -DSINGLE_NACK \ -DSUPPORT_FOR_NEW_MEMBERS -D_REENTRANT -DMALLOC_CHECK_ \ -D_POSIX_PTHREAD_SEMANTICS all: all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu src/Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --gnu src/Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh install-libLTLIBRARIES: $(lib_LTLIBRARIES) @$(NORMAL_INSTALL) test -z "$(libdir)" || $(mkdir_p) "$(DESTDIR)$(libdir)" @list='$(lib_LTLIBRARIES)'; for p in $$list; do \ if test -f $$p; then \ f=$(am__strip_dir) \ echo " $(LIBTOOL) --mode=install $(libLTLIBRARIES_INSTALL) $(INSTALL_STRIP_FLAG) '$$p' '$(DESTDIR)$(libdir)/$$f'"; \ $(LIBTOOL) --mode=install $(libLTLIBRARIES_INSTALL) $(INSTALL_STRIP_FLAG) "$$p" "$(DESTDIR)$(libdir)/$$f"; \ else :; fi; \ done uninstall-libLTLIBRARIES: @$(NORMAL_UNINSTALL) @set -x; list='$(lib_LTLIBRARIES)'; for p in $$list; do \ p=$(am__strip_dir) \ echo " $(LIBTOOL) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$p'"; \ $(LIBTOOL) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$p"; \ done clean-libLTLIBRARIES: -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES) @list='$(lib_LTLIBRARIES)'; for p in $$list; do \ dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \ test "$$dir" != "$$p" || dir=.; \ echo "rm -f \"$${dir}/so_locations\""; \ rm -f "$${dir}/so_locations"; \ done librmcast.la: $(librmcast_la_OBJECTS) $(librmcast_la_DEPENDENCIES) $(LINK) -rpath $(libdir) $(librmcast_la_LDFLAGS) $(librmcast_la_OBJECTS) $(librmcast_la_LIBADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/librmcast_la-rmcache.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/librmcast_la-rmcast.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/librmcast_la-rmevent.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/librmcast_la-rminternals.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/librmcast_la-rmmsg.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/librmcast_la-rmmsgpckt.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/librmcast_la-rmtcp.Plo@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/librmcast_la-rmwinmask.Plo@am__quote@ .c.o: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c $< .c.obj: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ `$(CYGPATH_W) '$<'`; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` .c.lo: @am__fastdepCC_TRUE@ if $(LTCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Plo"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< librmcast_la-rmcache.lo: rmcache.c @am__fastdepCC_TRUE@ if $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -MT librmcast_la-rmcache.lo -MD -MP -MF "$(DEPDIR)/librmcast_la-rmcache.Tpo" -c -o librmcast_la-rmcache.lo `test -f 'rmcache.c' || echo '$(srcdir)/'`rmcache.c; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/librmcast_la-rmcache.Tpo" "$(DEPDIR)/librmcast_la-rmcache.Plo"; else rm -f "$(DEPDIR)/librmcast_la-rmcache.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='rmcache.c' object='librmcast_la-rmcache.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -c -o librmcast_la-rmcache.lo `test -f 'rmcache.c' || echo '$(srcdir)/'`rmcache.c librmcast_la-rmcast.lo: rmcast.c @am__fastdepCC_TRUE@ if $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -MT librmcast_la-rmcast.lo -MD -MP -MF "$(DEPDIR)/librmcast_la-rmcast.Tpo" -c -o librmcast_la-rmcast.lo `test -f 'rmcast.c' || echo '$(srcdir)/'`rmcast.c; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/librmcast_la-rmcast.Tpo" "$(DEPDIR)/librmcast_la-rmcast.Plo"; else rm -f "$(DEPDIR)/librmcast_la-rmcast.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='rmcast.c' object='librmcast_la-rmcast.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -c -o librmcast_la-rmcast.lo `test -f 'rmcast.c' || echo '$(srcdir)/'`rmcast.c librmcast_la-rmevent.lo: rmevent.c @am__fastdepCC_TRUE@ if $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -MT librmcast_la-rmevent.lo -MD -MP -MF "$(DEPDIR)/librmcast_la-rmevent.Tpo" -c -o librmcast_la-rmevent.lo `test -f 'rmevent.c' || echo '$(srcdir)/'`rmevent.c; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/librmcast_la-rmevent.Tpo" "$(DEPDIR)/librmcast_la-rmevent.Plo"; else rm -f "$(DEPDIR)/librmcast_la-rmevent.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='rmevent.c' object='librmcast_la-rmevent.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -c -o librmcast_la-rmevent.lo `test -f 'rmevent.c' || echo '$(srcdir)/'`rmevent.c librmcast_la-rminternals.lo: rminternals.c @am__fastdepCC_TRUE@ if $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -MT librmcast_la-rminternals.lo -MD -MP -MF "$(DEPDIR)/librmcast_la-rminternals.Tpo" -c -o librmcast_la-rminternals.lo `test -f 'rminternals.c' || echo '$(srcdir)/'`rminternals.c; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/librmcast_la-rminternals.Tpo" "$(DEPDIR)/librmcast_la-rminternals.Plo"; else rm -f "$(DEPDIR)/librmcast_la-rminternals.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='rminternals.c' object='librmcast_la-rminternals.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -c -o librmcast_la-rminternals.lo `test -f 'rminternals.c' || echo '$(srcdir)/'`rminternals.c librmcast_la-rmmsg.lo: rmmsg.c @am__fastdepCC_TRUE@ if $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -MT librmcast_la-rmmsg.lo -MD -MP -MF "$(DEPDIR)/librmcast_la-rmmsg.Tpo" -c -o librmcast_la-rmmsg.lo `test -f 'rmmsg.c' || echo '$(srcdir)/'`rmmsg.c; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/librmcast_la-rmmsg.Tpo" "$(DEPDIR)/librmcast_la-rmmsg.Plo"; else rm -f "$(DEPDIR)/librmcast_la-rmmsg.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='rmmsg.c' object='librmcast_la-rmmsg.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -c -o librmcast_la-rmmsg.lo `test -f 'rmmsg.c' || echo '$(srcdir)/'`rmmsg.c librmcast_la-rmmsgpckt.lo: rmmsgpckt.c @am__fastdepCC_TRUE@ if $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -MT librmcast_la-rmmsgpckt.lo -MD -MP -MF "$(DEPDIR)/librmcast_la-rmmsgpckt.Tpo" -c -o librmcast_la-rmmsgpckt.lo `test -f 'rmmsgpckt.c' || echo '$(srcdir)/'`rmmsgpckt.c; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/librmcast_la-rmmsgpckt.Tpo" "$(DEPDIR)/librmcast_la-rmmsgpckt.Plo"; else rm -f "$(DEPDIR)/librmcast_la-rmmsgpckt.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='rmmsgpckt.c' object='librmcast_la-rmmsgpckt.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -c -o librmcast_la-rmmsgpckt.lo `test -f 'rmmsgpckt.c' || echo '$(srcdir)/'`rmmsgpckt.c librmcast_la-rmtcp.lo: rmtcp.c @am__fastdepCC_TRUE@ if $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -MT librmcast_la-rmtcp.lo -MD -MP -MF "$(DEPDIR)/librmcast_la-rmtcp.Tpo" -c -o librmcast_la-rmtcp.lo `test -f 'rmtcp.c' || echo '$(srcdir)/'`rmtcp.c; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/librmcast_la-rmtcp.Tpo" "$(DEPDIR)/librmcast_la-rmtcp.Plo"; else rm -f "$(DEPDIR)/librmcast_la-rmtcp.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='rmtcp.c' object='librmcast_la-rmtcp.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -c -o librmcast_la-rmtcp.lo `test -f 'rmtcp.c' || echo '$(srcdir)/'`rmtcp.c librmcast_la-rmwinmask.lo: rmwinmask.c @am__fastdepCC_TRUE@ if $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -MT librmcast_la-rmwinmask.lo -MD -MP -MF "$(DEPDIR)/librmcast_la-rmwinmask.Tpo" -c -o librmcast_la-rmwinmask.lo `test -f 'rmwinmask.c' || echo '$(srcdir)/'`rmwinmask.c; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/librmcast_la-rmwinmask.Tpo" "$(DEPDIR)/librmcast_la-rmwinmask.Plo"; else rm -f "$(DEPDIR)/librmcast_la-rmwinmask.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='rmwinmask.c' object='librmcast_la-rmwinmask.lo' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(librmcast_la_CFLAGS) $(CFLAGS) -c -o librmcast_la-rmwinmask.lo `test -f 'rmwinmask.c' || echo '$(srcdir)/'`rmwinmask.c mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: install-nobase_includeHEADERS: $(nobase_include_HEADERS) @$(NORMAL_INSTALL) test -z "$(includedir)" || $(mkdir_p) "$(DESTDIR)$(includedir)" @$(am__vpath_adj_setup) \ list='$(nobase_include_HEADERS)'; for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ $(am__vpath_adj) \ echo " $(nobase_includeHEADERS_INSTALL) '$$d$$p' '$(DESTDIR)$(includedir)/$$f'"; \ $(nobase_includeHEADERS_INSTALL) "$$d$$p" "$(DESTDIR)$(includedir)/$$f"; \ done uninstall-nobase_includeHEADERS: @$(NORMAL_UNINSTALL) @$(am__vpath_adj_setup) \ list='$(nobase_include_HEADERS)'; for p in $$list; do \ $(am__vpath_adj) \ echo " rm -f '$(DESTDIR)$(includedir)/$$f'"; \ rm -f "$(DESTDIR)$(includedir)/$$f"; \ done ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique; \ fi ctags: CTAGS CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ list='$(DISTFILES)'; for file in $$list; do \ case $$file in \ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ esac; \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkdir_p) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(LTLIBRARIES) $(HEADERS) installdirs: for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(includedir)"; do \ test -z "$$dir" || $(mkdir_p) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \ mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-libtool distclean-tags dvi: dvi-am dvi-am: html: html-am info: info-am info-am: install-data-am: install-nobase_includeHEADERS install-exec-am: install-libLTLIBRARIES install-info: install-info-am install-man: installcheck-am: maintainer-clean: maintainer-clean-am -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-info-am uninstall-libLTLIBRARIES \ uninstall-nobase_includeHEADERS .PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \ clean-libLTLIBRARIES clean-libtool ctags distclean \ distclean-compile distclean-generic distclean-libtool \ distclean-tags distdir dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-exec \ install-exec-am install-info install-info-am \ install-libLTLIBRARIES install-man \ install-nobase_includeHEADERS install-strip installcheck \ installcheck-am installdirs maintainer-clean \ maintainer-clean-generic mostlyclean mostlyclean-compile \ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \ tags uninstall uninstall-am uninstall-info-am \ uninstall-libLTLIBRARIES uninstall-nobase_includeHEADERS # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: tgif-QPL-4.2.5/rmcast/src/Makefile.am0000644000076400007640000000117611141162245017111 0ustar williamwilliamlib_LTLIBRARIES = librmcast.la nobase_include_HEADERS = rmcast.h librmcast_la_SOURCES= rmcache.c rmcache.h rmcast.c rmcast.h rmevent.c rmevent.h \ rminternals.c rminternals.h rmmsg.c rmmsg.h rmmsgpckt.c \ rmmsgpckt.h rmstruct.h rmtcp.c rmtcp.h rmwinmask.c \ rmwinmask.h librmcast_la_CFLAGS = -Wall -fno-strict-aliasing \ -DSTR_VERSION=\"$(PACKAGE_VERSION)\" \ -DRANDOM_TIMERS -DREFRESH -DSINGLE_NACK \ -DSUPPORT_FOR_NEW_MEMBERS -D_REENTRANT -DMALLOC_CHECK_ \ -D_POSIX_PTHREAD_SEMANTICS tgif-QPL-4.2.5/rmcast/src/rminternals.c0000644000076400007640000023034011225226450017556 0ustar williamwilliam/* * Copyright (C) 2002-2009, Edmundo Albuquerque de Souza e Silva. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * */ /*************************************************************************** rminternals.c ------------------- begin : May 2001 Authors : Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br ***************************************************************************/ #ifndef RMINTERNALS_C #define RMINTERNALS_C #include "rminternals.h" #include "rmcast.h" #include #include #include #include #include #include #include #include #include "rmwinmask.h" extern pthread_t rcv_thread, signal_handler_thread; extern char *EVENT_ACTION_NAME[6]; extern char *MESSAGE_TYPE_NAME[NUMBER_OF_MESSAGE_TYPES]; FILE *logfile=NULL; #ifdef DSUPPRESSION extern FILE *suppressionfile; #endif int STOP_TRANSMISSION=0; EVENT_LIST *event_list=NULL; #ifdef SINGLE_NACK EVENT_LIST *nak_event=NULL; EVENT_LIST *wait_for_retransm_event=NULL; #endif CACHE *cache=NULL; USER_INFO local_user_info; sigset_t alrmset; GLOBAL_OPTIONS rmcast_options = { /* int *pipe; */ 0 , /* char tcp_ip[IP_STRING_SIZE]; */ { 0 }, /* int tcp_port; */ 10013, /* void ( *shut_down_routine )( void ) = NULL; */ 0, /* int cur_state_server_is_up = 0; */ 0, /* char dest_ip[IP_STRING_SIZE]; */ { "225.1.2.3" } , /* int dest_port; */ 5151, /* int ttl; */ 1, /* unsigned int microsleep; */ 10, /* int hosts_identified; default 0*/ 0, /* int timer_distribution; */ UNIFORM, /* int max_nak; default 100 */ 100, /* int max_member_cache_size; default 4000 */ 4000, /* int version; */ 1, /* int transmission_mode; */ MULTICAST, /* char log_file[255]; */ "NULL", /* int new_member_support; */ 0, /* int statistics; */ 0, /* int refresh_timer; */ 10, /* float loss_prob; */ 0, /* int leave_group_wait_time; */ 500000, /* int rcv_buffer_size; */ 10000, /* HOSTS_DELAYS hosts_delays */ { { "DEFAULT", /* host IP */ 50000 /* one-way delay to host( microseconds ) */ } }, /* parameters to obtain the timer interval */ 2, 2, 5, 2, 2, 2 }; extern pthread_mutex_t change_local_user_sn; extern pthread_mutex_t event_list_mutex; extern pthread_mutex_t cache_mutex; /*********************** Main routines ************************************************************/ void lock_eventlist_and_cache( ) { pthread_mutex_lock( &event_list_mutex ); pthread_mutex_lock( &cache_mutex ); } void unlock_eventlist_and_cache( ) { pthread_mutex_unlock( &cache_mutex ); pthread_mutex_unlock( &event_list_mutex ); } /***************************************************************************************************** * * int rmcastCreateSocket ( int port ) * * Creates a multi-cast socket, using the specified port. * * Returns the socket handler. * ******************************************************************************************************/ int rmcastCreateSocket( int port ) { int aux = 1 ; struct sockaddr_in saddr; local_user_info.socket = socket( AF_INET, SOCK_DGRAM, IPPROTO_UDP ); bzero(( char* ) &saddr, sizeof( saddr ) ); saddr.sin_family = AF_INET; saddr.sin_port = htons( port ); saddr.sin_addr.s_addr = htonl( INADDR_ANY ); if( setsockopt( local_user_info.socket, SOL_SOCKET, SO_REUSEADDR, ( char* )&aux, sizeof( aux ) ) == -1 ) perror( "reuse addr error" ); if( bind( local_user_info.socket, ( struct sockaddr * )&saddr, sizeof( saddr ) ) == -1 ) { perror( "binding error" ); close( local_user_info.socket ); local_user_info.socket = -1; } if( rmcast_options.transmission_mode == MULTICAST ) { rmcastSetTTLValue( local_user_info.socket, rmcast_options.ttl ); rmcastSetLoopBack( local_user_info.socket, 1 ); } return( local_user_info.socket ); } void rmcastSetTTLValue( int soc, int ttl ) { #ifndef SOLARIS if( setsockopt( soc, IPPROTO_IP, IP_MULTICAST_TTL, ( char* )&ttl, sizeof( ttl ) ) ==-1 ) perror( "ttl" ); #endif } void rmcastSetLoopBack( int soc, int loop ) { #ifndef SOLARIS if( setsockopt( soc, IPPROTO_IP, IP_MULTICAST_LOOP, ( char* )&loop, sizeof( loop ) ) ==-1 ) perror( "loop" ); #endif } /***************************************************************************************************** * * void rmcastJoinGroup ( int soc, char *group_addr ) * * Joins the user using the socket soc to the multicast group. * * Arguments: the socket, in soc; * the multicast group ip, in group_addr * ******************************************************************************************************/ void rmcastJoinGroup ( int soc, char *group_addr ) { struct sockaddr_in group; struct ip_mreq mreq; if( rmcast_options.transmission_mode == MULTICAST ) { fprintf( stdout,"rmcastJoinGroup: Joining group %s\n", group_addr ); if(( group.sin_addr.s_addr = inet_addr( group_addr ) ) == ( unsigned )-1 ) perror( "rmcastJoingGroup: inet_addr" ); mreq.imr_multiaddr = group.sin_addr; mreq.imr_interface.s_addr = INADDR_ANY; if( setsockopt( soc, IPPROTO_IP, IP_ADD_MEMBERSHIP, ( char * )&mreq, sizeof( mreq ) ) == -1 ) perror( "rmcastJoingGroup: ADD_MEMBERSHIP" ); } } /***************************************************************************************************** * * void rmcastLeaveGroup ( int soc, char *group_addr ) * * Used when the user using the socket soc wants to leave the multicast group. * * Arguments: the socket, in soc; * the multicast group ip, in group_addr * Returns: 1, on success; * 0, on error. * ******************************************************************************************************/ int rmcastLeaveGroup ( int soc, char *group_addr ) { BYTE *buffer; int buffsize = 0; PACKET_INFO pckt_info; #ifdef REFRESH /* Mounting and sending a Refresh packet before leaving the group but only if we have already sent one data packet */ if( local_user_info.sn > 0 ){ pckt_info.type = REFRESH_PACKET_TYPE; pckt_info.flags = 0; pckt_info.sender_id = local_user_info.member_id; pckt_info.packet_size = sizeof( REFRESH_PACKET ); pthread_mutex_lock( &change_local_user_sn ); pckt_info.packet_data.refresh_packet.sn_of_last_msg_sent = local_user_info.sn - 1; pthread_mutex_unlock( &change_local_user_sn ); #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: Mounting refresh packet.\n" ); #endif msgPcktMountMessage( &pckt_info, ( BYTE** )&buffer, &buffsize ); if ( rmcastSendPacket( soc, buffer, buffsize ) == 0 ) return 0; } #endif /* REFRESH */ /* Mounting and sending a Leave group packet */ pckt_info.type = LEAVE_GROUP_PACKET_TYPE; pckt_info.flags = 0; pckt_info.sender_id = local_user_info.member_id; pckt_info.packet_size = 0; #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastLeaveGroup: mounting message\n" ); #endif msgPcktMountMessage( &pckt_info, ( BYTE** )&buffer, &buffsize ); #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastLeaveGroup: mounted 'leave group' message\n" ); #endif if ( rmcastSendPacket( soc, buffer, buffsize ) == 0 ) return 0; #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastLeaveGroup: sent 'leave group' message\n" ); #endif #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastLeaveGroup: Disconnecting... %s\n", group_addr ); #endif lock_eventlist_and_cache( ); eventListInsert( &event_list,NULL, NULL, LEV_GRP_WAIT, -1 ); unlock_eventlist_and_cache( ); #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastLeaveGroup: returning\n" ); #endif return 1; } /***************************************************************************************************** * * void showLogMsg( char type, PACKET_INFO *pckt_info ) * * Prints a message from type 'type', related to the packet 'pckt_info', in the log file 'logfile'. * * Arguments: the message type and the packet information. * * Side effects: changes the log file. * ******************************************************************************************************/ void showLogMsg( char type, PACKET_INFO *pckt_info ) { struct timeval current_time; char buffer[200]; struct tm time; #ifdef DSHOW_COMPLETE_MASK_IN_LOG char auxbuffer[100]; int n = 0; #endif memset( buffer,0,sizeof( buffer ) ); if( logfile!= NULL ) { gettimeofday( ¤t_time, 0 ); time = *gmtime(( const time_t* )¤t_time ); current_time. tv_sec = (( time.tm_hour * 60 + time.tm_min ) * 60 ) + time.tm_sec; if( pckt_info !=NULL ) { switch( pckt_info->type ) { /* --------------------------------------------------------------------------------------------------------------------------- Time Snd/Rcv/Loss type sender_ip sender_pid requested_ip requested_pid sn [{base sn} {win size} {hmask} {lmask}] --------------------------------------------------------------------------------------------------------------------------- 01234567890 x yz abc.def.ghi.jkl 1234567890 abc.def.ghi.jkl 1234567890 123456 123456 1234 1234 1234 */ case DATA_PACKET_TYPE: sprintf( buffer,"%15s %10d %6d", pckt_info->sender_id.ip,pckt_info->sender_id.pid, pckt_info->packet_data.data_packet.sn ); break; case NAK_PACKET_TYPE: #ifndef SINGLE_NACK sprintf( buffer,"%15s %10d %15s %10d %6d", pckt_info->sender_id.ip, pckt_info->sender_id.pid, pckt_info->packet_data.nak_packet.requested_member_id.ip, pckt_info->packet_data.nak_packet.requested_member_id.pid, pckt_info->packet_data.nak_packet.sn ); #else sprintf( buffer,"%15s %10d %15s %10d %6d %4d %4u %4u ", pckt_info->sender_id.ip, pckt_info->sender_id.pid, pckt_info->packet_data.nak_packet.requested_member_id.ip, pckt_info->packet_data.nak_packet.requested_member_id.pid, pckt_info->packet_data.nak_packet.base_sn, pckt_info->packet_data.nak_packet.window_size, pckt_info->packet_data.nak_packet.hmask, pckt_info->packet_data.nak_packet.lmask ); #ifdef DSHOW_COMPLETE_MASK_IN_LOG for( n= ( pckt_info->packet_data.nak_packet.window_size / 2 )-1; n>=0; n-- ) { sprintf( auxbuffer,"%d", (( unsigned int )pckt_info->packet_data.nak_packet.hmask >> n ) & 1 ); strcat( buffer,auxbuffer ); } sprintf( auxbuffer,"-" ); strcat( buffer,auxbuffer ); for( n= ( pckt_info->packet_data.nak_packet.window_size / 2 )-1; n>=0; n-- ) { sprintf( auxbuffer,"%d", (( unsigned int )pckt_info->packet_data.nak_packet.lmask >> n ) & 1 ); strcat( buffer,auxbuffer ); } #endif /*DSHOW_COMPLETE_MASK_IN_LOG */ #endif break; case RETRANSM_PACKET_TYPE: sprintf( buffer,"%15s %10d %15s %10d %6d", pckt_info->sender_id.ip, pckt_info->sender_id.pid, pckt_info->packet_data.retransm_packet.original_sender_id.ip, pckt_info->packet_data.retransm_packet.original_sender_id.pid, pckt_info->packet_data.retransm_packet.data_packet.sn ); break; #ifdef REFRESH case REFRESH_PACKET_TYPE: sprintf( buffer,"%15s %10d %6d", pckt_info->sender_id.ip,pckt_info->sender_id.pid, pckt_info->packet_data.refresh_packet.sn_of_last_msg_sent ); break; #endif case JOIN_REQUEST_PACKET_TYPE: sprintf( buffer,"%15s %10d",pckt_info->sender_id.ip,pckt_info->sender_id.pid ); break; case JOIN_ACCEPT_PACKET_TYPE: sprintf( buffer,"%15s %10d",pckt_info->sender_id.ip,pckt_info->sender_id.pid ); break; case LEAVE_GROUP_PACKET_TYPE: sprintf( buffer,"%15s %10d",pckt_info->sender_id.ip,pckt_info->sender_id.pid ); break; default: fprintf( stderr, "Unknown packet type: %c\n",pckt_info->type ); RM_leaveGroup( local_user_info.socket, local_user_info.member_id.ip ); } fprintf( logfile,"%.0Lf %c %s %s\n", (((( long double )current_time.tv_sec )*1000000+( long double )current_time.tv_usec ) ) , type, MESSAGE_TYPE_NAME[( int )pckt_info->type], buffer ); } else { fprintf( logfile,"%.0Lf %c\n", (((( long double )current_time.tv_sec )*1000000+( long double )current_time.tv_usec ) ) , type ); } } } /***************************************************************************************************** * * void* rmcastReceivePackets( void *user_soc ) * * Receives packets from socket soc. * * Arguments: the socket number, in soc; * * Side effects: may change the state of the event list or cache. * ******************************************************************************************************/ void *rmcastReceivePackets( void *user_soc ) { int soc; struct sockaddr_in sender; static int first; static int first_pckts_lost; socklen_t len; int sn; int nbytes; /* number of bytes received */ char message[rmcast_options.rcv_buffer_size]; PACKET_INFO pckt_info; MEMBER_ID aux_member_id; #ifdef DPROCESSING_TIME struct timeval time_before,time_after; struct tm time; FILE *proc_log; char tipo; #endif soc = ( int )user_soc; sn = 0; first = 1; first_pckts_lost = 10; #ifndef SOLARIS sigset_t alrmset; sigfillset( &alrmset ); /* fills the alarm set with all the signals */ /* blocks all the signals, because they wonŽt be handled by this thread */ pthread_sigmask( SIG_BLOCK, &alrmset, NULL ); #endif #ifdef DPROCESSING_TIME proc_log=fopen( "proc_times.log","w" ); #endif do{ bzero( message, rmcast_options.rcv_buffer_size ); #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: Waiting to receive a message...\n" ); #endif len = sizeof( struct sockaddr_in ); nbytes = ( int )recvfrom( soc, message, rmcast_options.rcv_buffer_size, 0, ( struct sockaddr * ) &sender, &len ); #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: A message was received from the network!( message size=%d )\n",nbytes ); #endif if( nbytes <= 0 ) { fprintf( stderr, "rmcastReceivePackets: Error while receiving a message from the net - nbytes=%d \n",nbytes ); } else /* nbytes > 0 */ { #ifdef DEBUG_PCKT { int cont; fprintf( stderr, "DEBUG_PCKT rmcastReceivePackets: Received message:\n" ); for( cont = 0; cont < nbytes; cont++ ) { fprintf( stderr, "%d", ( ( signed char * )message )[cont] ); } fprintf( stderr, "\n" ); } #endif msgPcktUnmountMessage( &pckt_info, ( BYTE* )message ); #ifdef DPROCESSING_TIME gettimeofday( &time_before, 0 ); time = *gmtime(( const time_t* )&time_before ); time_before.tv_sec = (( time.tm_hour * 60 + time.tm_min ) * 60 ) + time.tm_sec; tipo = pckt_info.type; #endif if( memberIsEqual( &( pckt_info.sender_id ), &( local_user_info.member_id ) ) ) { /* We have received our own packet, so we just log and go to the next packet */ showLogMsg( RECEIVE,&pckt_info ); continue; } #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: message type=%s\n",MESSAGE_TYPE_NAME[( int )( pckt_info.type )] ); #endif switch( pckt_info.type ) { case DATA_PACKET_TYPE: sn = pckt_info.packet_data.data_packet.sn; break; case NAK_PACKET_TYPE: sn = pckt_info.packet_data.nak_packet.sn; #ifdef DSINGLE_NACK fprintf( stderr, "NAK received:\n\tFrom:%s:%d \n\tRequesting: %s:%d:%d \n\twin_size:%d \tbase_sn:%d \thmask:%u \tlmask:%u \n", pckt_info.sender_id.ip, pckt_info.sender_id.pid, pckt_info.packet_data.nak_packet.requested_member_id.ip, pckt_info.packet_data.nak_packet.requested_member_id.pid, pckt_info.packet_data.nak_packet.sn, pckt_info.packet_data.nak_packet.window_size, pckt_info.packet_data.nak_packet.base_sn, ( unsigned int )pckt_info.packet_data.nak_packet.hmask, ( unsigned int )pckt_info.packet_data.nak_packet.lmask ); { int n; fprintf( stderr, "\tHMASK:" ); for( n = ( pckt_info.packet_data.nak_packet.window_size / 2 )-1; n>=0; n-- ) { fprintf( stderr, "%d", (( unsigned int )pckt_info.packet_data.nak_packet.hmask >> n ) & 1 ); } fprintf( stderr, "\n\tLMASK:" ); for( n = ( pckt_info.packet_data.nak_packet.window_size / 2 )-1; n>=0; n-- ) { fprintf( stderr, "%d", (( unsigned int )pckt_info.packet_data.nak_packet.lmask >> n ) & 1 ); } fprintf( stderr, "\n" ); } #endif break; case RETRANSM_PACKET_TYPE: sn = pckt_info.packet_data.retransm_packet.data_packet.sn; break; case REFRESH_PACKET_TYPE: sn = pckt_info.packet_data.refresh_packet.sn_of_last_msg_sent; break; case JOIN_REQUEST_PACKET_TYPE: sn = -1; break; case JOIN_ACCEPT_PACKET_TYPE: sn = -1; break; case LEAVE_GROUP_PACKET_TYPE: sn = -1; break; default: fprintf( stderr, "rmcastReceivePackets: Unknown packet type.\n" ); RM_leaveGroup( local_user_info.socket, local_user_info.member_id.ip ); } #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: sn=%d\n",sn ); #endif #ifdef DEBUG_SHOW msgPcktShowMessage(( BYTE * )message ); #endif /* ------------------------ Loss Simulation begin----------------------------------------- */ if( rmcast_options.loss_prob > 0 ) { /* Uncomment the following line if don't want naks and retransmission to be lost if( pckt_info.type != NAK_PACKET_TYPE && pckt_info.type != RETRANSM_PACKET_TYPE ) */ { if( generateSample( UNIFORM ) < rmcast_options.loss_prob || (( pckt_info.type == DATA_PACKET_TYPE ) &&( sn == 0 ) &&( first == 1 ) ) || ( first_pckts_lost > 0 ) ) /* * We are always losing the first 'first_pckts_lost'( e.g., 10 ) received packets, * and the first received data packet - * that is, the first burst of received packets. * After that, packets are lost according to the rmcast_options.loss_prob. */ { #ifdef DEBUG_NET_MSGS fprintf( stderr, "\nDEBUG_NET_MSGS rmcastReceivePackets: PACKET LOST sn=%d\n\n",sn ); #endif if( logfile != NULL ) { showLogMsg( RECEIVE_AND_LOSE,&pckt_info ); } if( pckt_info.type == DATA_PACKET_TYPE ) first = 0; if( first_pckts_lost>0 ) first_pckts_lost--; continue; } } } /* ------------------------ Loss Simulation end----------------------------------------- */ lock_eventlist_and_cache( ); #ifdef DMUTEX fprintf( stderr, "DMUTEX rmcastReceivePackets: event list and cache LOCKED\n" ); showLogMsg( 'K', NULL ); #endif if( logfile != NULL ) { showLogMsg( RECEIVE,&pckt_info ); } switch( pckt_info.type ) { case NAK_PACKET_TYPE: #ifdef SINGLE_NACK { int i,aux_window_mask[MAX_WINDOW_SIZE]; memset( aux_window_mask, 0, ( MAX_WINDOW_SIZE*( sizeof( int ) ) ) ); window_mask_numbers2array( aux_window_mask, pckt_info.packet_data.nak_packet.hmask, pckt_info.packet_data.nak_packet.lmask ); #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: a NAK was received!\n" ); #endif if( !memberIsEqual( &( pckt_info.packet_data.nak_packet.requested_member_id ),&( local_user_info.member_id ) ) ) { for( i = 0; i < MAX_WINDOW_SIZE; i++ ) { if( aux_window_mask[i] == 1 ) { /* Setting the real value to the sn */ pckt_info.packet_data.nak_packet.sn = pckt_info.packet_data.nak_packet.base_sn + i + 1; #ifdef DNAK_RCV fprintf( stderr, "DNAK_RCV we will try to remove event NAK_SND_WAIT for sn=%d\n",pckt_info.packet_data.nak_packet.sn ); #endif if( rmcastRemoveEvent( &pckt_info,NAK_SND_WAIT ) ) { #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: a NAK was received. inserting a RET_RCV_WAIT or a SUPPRESSED_NAK.\n" ); #endif #ifdef DNAK_RCV fprintf( stderr, "Inserting a SUPPRESSED_NAK\n" ); #endif rmcastInsertEvent( &pckt_info, SUPPRESSED_NAK ); } } } } for( i = 0; i < MAX_WINDOW_SIZE; i++ ) { if( aux_window_mask[i] == 1 ) { /* Setting the real value to the sn */ pckt_info.packet_data.nak_packet.sn = pckt_info.packet_data.nak_packet.base_sn + i + 1; #ifdef DNAK_RCV fprintf( stderr, "DNAK_RCV rmcastReceivePackets: Before calling rmcastCacheContains sn=%d\n",pckt_info.packet_data.nak_packet.sn ); #endif if( rmcastCacheContains( &pckt_info ) &&( rmcastFindEvent( &pckt_info,RET_SND_WAIT ) == 0 ) ) { #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: a NAK was received. inserting a RET_SND_WAIT.\n" ); #endif #ifdef DNAK_RCV fprintf( stderr, "Inserting a RET_SND_WAIT: %s:%d:%d\n", pckt_info.packet_data.nak_packet.requested_member_id.ip, pckt_info.packet_data.nak_packet.requested_member_id.pid, pckt_info.packet_data.nak_packet.sn ); #endif rmcastInsertEvent( &pckt_info,RET_SND_WAIT ); } } } } #else /* using multiple nacks */ #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: a NAK was received!\n" ); #endif if( !memberIsEqual( &( pckt_info.packet_data.nak_packet.requested_member_id ),&( local_user_info.member_id ) ) && rmcastRemoveEvent( &pckt_info,NAK_SND_WAIT ) ) { #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: a NAK was received. inserting a RET_RCV_WAIT.\n" ); #endif rmcastInsertEvent( &pckt_info,RET_RCV_WAIT ); } else if( !rmcastFindEvent( &pckt_info,RET_SND_WAIT ) ) { if( rmcastCacheContains( &pckt_info ) ) { #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: a NAK was received. inserting a RET_SND_WAIT.\n" ); #endif rmcastInsertEvent( &pckt_info,RET_SND_WAIT ); } } #endif /* SINGLE_NACK */ break; case LEAVE_GROUP_PACKET_TYPE: /* * FIXME * By now it is OK if the member does not exist in cache, * because he is leaving the group anyway :- ) So we don't * care about the return value for cacheDeactivateMember */ cacheDeactivateMember( cache,&( pckt_info.sender_id ) ); break; case JOIN_REQUEST_PACKET_TYPE: { char *buffer; int buffsize; PACKET_INFO pckt_info; if( rmcast_options.cur_state_server_is_up ) { pckt_info.type = JOIN_ACCEPT_PACKET_TYPE; pckt_info.flags = 0; pckt_info.sender_id = local_user_info.member_id; pckt_info.packet_size = sizeof( int ); pckt_info.packet_data.join_accept_packet.port = rmcast_options.tcp_port; #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: mounting the 'join accept packet'( port: %d )...", rmcast_options.tcp_port ); #endif msgPcktMountMessage( &pckt_info, ( BYTE** )&buffer, &buffsize ); #ifdef DEBUG_SHOW fprintf( stderr, "DEBUG_SHOW rmcastReceivePackets: ok!\n" ); msgPcktShowMessage(( BYTE* )buffer ); #endif #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: now, sending the message to the mcast group\n" ); #endif rmcastSendPacket( local_user_info.socket, ( BYTE* )buffer, buffsize ); } } break; case JOIN_ACCEPT_PACKET_TYPE: /* * Ignore this packet. He is handled only when we are entering the group. * See RM_getCurState at rmcast.c */ break; case REFRESH_PACKET_TYPE: #ifdef REFRESH rmcastProcessRefreshPacket( pckt_info ); #endif break; case RETRANSM_PACKET_TYPE: #ifdef DSUPPRESSION if( rmcastRemoveEvent( &pckt_info,RET_SND_WAIT ) ){ fprintf( suppressionfile,"RT %s %d %s %d %d\n", pckt_info.sender_id.ip, pckt_info.sender_id.pid, pckt_info.packet_data.retransm_packet.original_sender_id.ip, pckt_info.packet_data.retransm_packet.original_sender_id.pid, pckt_info.packet_data.retransm_packet.data_packet.sn ); } #else rmcastRemoveEvent( &pckt_info,RET_SND_WAIT ); #endif if( !rmcastRemoveEvent( &pckt_info,NAK_SND_WAIT ) && !rmcastRemoveEvent( &pckt_info,RET_RCV_WAIT ) ) { if( rmcastCacheContains( &pckt_info ) ) break; } /* Now we will get the content of the retransmition and put it in the cache. */ strcpy( aux_member_id.ip, pckt_info.packet_data.retransm_packet.original_sender_id.ip ); aux_member_id.pid=pckt_info.packet_data.retransm_packet.original_sender_id.pid; pckt_info.packet_data.data_packet = pckt_info.packet_data.retransm_packet.data_packet; pckt_info.sender_id = aux_member_id; /* continue... */ case DATA_PACKET_TYPE: rmcastProcessDataPacket( pckt_info ); /* inserts data in cache... */ #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastReceivePackets: after executing rmcastProcessDataPacket.\n" ); eventListShow( event_list ); #endif break; default: fprintf( stderr, "rmcastReceivePackets: Invalid message type.( %d )\n",pckt_info.type ); RM_leaveGroup( local_user_info.socket, local_user_info.member_id.ip ); } /* End switch */ unlock_eventlist_and_cache( ); #ifdef DMUTEX showLogMsg( 'U', NULL ); fprintf( stderr, "DMUTEX rmcastReceivePackets: event list and cache UNLOCKED\n" ); #endif } /* nbytes > 0 */ #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastReceivePackets: received, ok!\n" ); #endif #ifdef DPROCESSING_TIME gettimeofday( &time_after, 0 ); time = *gmtime(( const time_t* )&time_after ); time_after.tv_sec = (( time.tm_hour * 60 + time.tm_min ) * 60 ) + time.tm_sec; time_after.tv_sec = time_after.tv_sec - time_before.tv_sec; time_after.tv_usec = time_after.tv_usec - time_before.tv_usec; fprintf( proc_log,"%d %.0Lf\n",tipo, (( long double )time_after.tv_sec*1000000+( long double )time_after.tv_usec ) ); #endif } FOREVER; return NULL; } /***************************************************************************************************** * * void rmcastSendPacket( int soc, BYTE *message, int message_size ) * * Sends a message packet of size message_size to socket soc. * * Returns: 1, on success; * 0, on error. * ******************************************************************************************************/ int rmcastSendPacket( int soc, BYTE *message, int message_size ) { PACKET_INFO pckt_info; struct sockaddr_in dest; int sn; #ifdef DEBUG_SHOW2 int i; #endif int retval; char type = *(( char* )message ); char local_message[ message_size + 1 ]; struct timespec sleep_time; #ifdef DEBUG_SHOW2 fprintf( stderr, "DEBUG_SHOW2 - rmcastSendPacket: will copy a message of size %d to local var.\n",message_size ); for( i=0; i< message_size; i++ ) { fprintf( stderr, "( %d )%d",i, ( unsigned int )message[i] ); } fprintf( stderr, "\n" ); #endif memcpy( local_message, message, message_size ); dest.sin_family = AF_INET; dest.sin_port = htons ( local_user_info.group_id.port ); dest.sin_addr.s_addr = inet_addr( local_user_info.group_id.ip ); if( type == DATA_PACKET_TYPE ) { /* REFRESH event is now inserted only after user sends the first packet, i.e., local_user_info.sn==0 */ if( local_user_info.sn == 0 ) { eventListInsert( &event_list, &( local_user_info.member_id ), NULL, REF_SND_WAIT, -1 ); } pthread_mutex_lock( &change_local_user_sn ); local_user_info.sn++; pthread_mutex_unlock( &change_local_user_sn ); } msgPcktUnmountMessage( &pckt_info, ( BYTE * )local_message ); switch( pckt_info.type ) { case DATA_PACKET_TYPE: sn = pckt_info.packet_data.data_packet.sn; break; case NAK_PACKET_TYPE: sn = pckt_info.packet_data.nak_packet.sn; break; case RETRANSM_PACKET_TYPE: sn = pckt_info.packet_data.retransm_packet.data_packet.sn; break; case REFRESH_PACKET_TYPE: sn = pckt_info.packet_data.refresh_packet.sn_of_last_msg_sent; break; case JOIN_REQUEST_PACKET_TYPE: sn = -1; break; case JOIN_ACCEPT_PACKET_TYPE: sn = -1; break; default: sn = -1; } #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastSendPacket: will send a %s - sn: %d\n", MESSAGE_TYPE_NAME[( int )type],sn ); #endif if( logfile != NULL ) { showLogMsg( SEND,&pckt_info ); } retval = sendto( soc, local_message, message_size, 0, ( struct sockaddr * )&dest, sizeof( dest ) ); if( retval < 0 ) { fprintf( stderr, "ERROR - rmcastSendPacket: retval < 0\n" ); perror( "send_message" ); msgPcktShowMessage( message ); return 0; } /* fprintf( stderr, " Packet size RML: %d\n",message_size ); FIXME teste pra saber o tamanho dos pacotes */ if( ( rmcast_options.microsleep > 0 ) &&( rmcast_options.microsleep < 65536 ) ) { /* Converting rmcast_options.microsleep to nanoseconds as needed by nanosleep function */ sleep_time.tv_nsec= ( rmcast_options.microsleep*1000 ); sleep_time.tv_sec=0; nanosleep( &sleep_time,NULL ); /* usleep( rmcast_options.microsleep ); */ } return 1; } /***************************************************************************************************** * * void *rmcastHandleSignals( void *arg ) * * This thread will be the only one that threats the alarm events. * * Communication with it should be done using SIGUSR1. * *****************************************************************************************************/ extern const char * const sys_siglist[]; #define _GNU_SOURCE #include char *strsignal( int sig ); extern const char * const sys_siglist[]; void *rmcastHandleSignals( void *arg ) { int sig; int err; int finish = 0; #ifndef SOLARIS struct itimerval value; #else sigset_t alrmset; sigfillset( &alrmset ); pthread_sigmask( SIG_BLOCK, &alrmset, NULL ); #endif while( 1 ) { #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS rmcastHandleSignals: Before sigwait( )\n" ); #endif err = sigwait( &alrmset, &sig ); #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS rmcastHandleSignals: After sigwait( ) \n" ); #endif #ifdef DEBUG_EVENTS #ifdef SOLARIS fprintf( stderr, "DEBUG_EVENTS rmcastHandleSignals( SOLARIS ): signal ( %d ) received\n", sig ); #else fprintf( stderr, "DEBUG_EVENTS rmcastHandleSignals: signal %s( %d ) received\n",sys_siglist[sig], sig ); #endif #endif if( err || ( sig != SIGALRM && sig != SIGUSR1 ) ) { fprintf( stderr, "rmcastHandleSignals: [%s signal catched]\n",strsignal( sig ) ); if( sig == SIGINT || sig == SIGTERM ) { fprintf( stderr, "rmcastHandleSignals: Signal %s received. Exiting.\n",strsignal( sig ) ); RM_leaveGroup( local_user_info.socket, local_user_info.member_id.ip ); } else if( sig == SIGTSTP ) { fprintf( stderr, "DEBUG_EVENTS rmcastHandleSignals: SIGSTP received. Nothing to be done.\n" ); /* FIXME( in a future release, we may be able to handle the SIGTSTP signal ) */ } else if( sig == SIGUSR2 ) { STOP_TRANSMISSION = 1; } else continue; } lock_eventlist_and_cache( ); #ifdef DMUTEX showLogMsg( 'k', NULL ); fprintf( stderr, "DMUTEX rmcastHandleSignals: event list and cache LOCKED\n" ); #endif if( sig == SIGALRM ||( event_list != NULL && event_list->timer_value == 0 ) ) { #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastHandleSignals: calling rmcastCatchEvents\n" ); #endif finish = rmcastCatchEvents( 0 ); #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastHandleSignals: back from rmcastCatchEvents\n" ); #endif if( finish ) break; } #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastHandleSignals: showing eventlist:\n" ); eventListShow( event_list ); #endif if( event_list != NULL ) { #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS rmcastHandleSignals: setting timer to %ld( rmcastHandleSignals )\n",event_list->timer_value ); #endif #ifndef SOLARIS setTimerValue( &value,event_list->timer_value ); setitimer( ITIMER_REAL, &value,NULL ); #else alarm( event_list->timer_value/1000000 + 1 ); #endif } else { #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS rmcastHandleSignals: resetting timer( rmcastHandleSignals )\n" ); #endif #ifndef SOLARIS setTimerValue( &value,0 ); setitimer( ITIMER_REAL,&value,NULL ); #else alarm( 0 ); #endif } unlock_eventlist_and_cache( ); #ifdef DMUTEX showLogMsg( 'u', NULL ); fprintf( stderr, "DMUTEX rmcastHandleSignals: cache and event list UNLOCKED\n" ); #endif } return 0; } /***************************************************************************************************** * * int rmcastCatchEvents ( int i ) * * Catch and execute event list events. * ******************************************************************************************************/ int rmcastCatchEvents( int i ) { int retval = 0; int function_retval = 0; struct sockaddr_in group; struct ip_mreq mreq; CACHE *cache_sender_entry; #ifndef SINGLE_NACK int update_nak_list_retval; #endif EVENT_LIST first; int msgsize; BYTE *message; PACKET_INFO pack; DATA_PACKET *data; #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: Event catched!\n" ); #endif if( event_list == NULL ) { #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: Internal warning! first == NULL\n" ); #endif return retval; } first = *event_list; #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastCatchEvents: showing event list:\n" ); #endif eventListShow( event_list ); #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: event list: %p\n",&( *event_list ) ); #endif do { #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: Removing event: action %s timer value: %ld\n", EVENT_ACTION_NAME[( int )first.action], first.timer_value ); #endif #ifdef DNAK_RCV fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: Removing event: action %s timer value: %ld\n", EVENT_ACTION_NAME[( int )first.action], first.timer_value ); #endif if( eventListRemoveFirst( &event_list ) == -1 ) { #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: warning eventListRemoveFirst( &event_list ) == -1\n" ); #endif } eventListShow( event_list ); switch( first.action ) { case NAK_SND_WAIT: pack.type=NAK_PACKET_TYPE; pack.flags=0; pack.sender_id = local_user_info.member_id; pack.packet_size=sizeof( NAK_PACKET ); strcpy( pack.packet_data.nak_packet.requested_member_id.ip,first.member_id->ip ); pack.packet_data.nak_packet.requested_member_id.pid=first.member_id->pid; pack.packet_data.nak_packet.sn=first.sn; #ifdef SINGLE_NACK { CACHE *aux_cache_member = NULL; aux_cache_member = cacheLookForMember( &cache, first.member_id ); if( aux_cache_member!=NULL ) { pack.packet_data.nak_packet.base_sn=aux_cache_member->sm_info.member_status.last_seq_rcv; pack.packet_data.nak_packet.window_size=aux_cache_member->sm_info.member_status.window_size; window_mask_array2numbers( aux_cache_member->sm_info.member_status.window_mask, &pack.packet_data.nak_packet.hmask, &pack.packet_data.nak_packet.lmask, aux_cache_member->sm_info.member_status.window_ini ); } } #endif msgPcktMountMessage( &pack, &message, &msgsize ); #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: will send NAK ...\n" ); #endif rmcastSendPacket( local_user_info.socket, message, msgsize ); #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: NAK sent OK.\n" ); #endif cache_sender_entry = cacheLookForMember( &cache,first.member_id ); if( cache_sender_entry != NULL ) retval = eventListInsert( &event_list,&( cache_sender_entry->sm_info.member_id ), cache_sender_entry->sm_info.member_id.ip, RET_RCV_WAIT, first.sn ); #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: RET_RCV_WAIT was inserted in the event list.\n" ); #endif break; case RET_RCV_WAIT: /* Next we will check if it is possible to send one more NAK for the lost message, i.e., the NAK should be sent only rmcast_options.max_nak times */ #ifdef DEBUG_EVENTS fprintf( stderr, " \nDEBUG_EVENTS - rmcastCatchEvents: Waiting for retransmission timed out\n ip: %s - pid: %d - sn: %d\n", first.member_id->ip, first.member_id->pid, first.sn ); #endif #ifndef SINGLE_NACK /* When we are using SINGLE_NACK this check is done in the event list insert funciton */ if(( update_nak_list_retval = cacheUpdateNakList( &cache, first.member_id, first.sn ) ) > 0 ) { #endif cache_sender_entry = cacheLookForMember( &cache,first.member_id ); if( cache_sender_entry != NULL ) #ifdef SINGLE_NACK retval = eventListInsert( &event_list,&( cache_sender_entry->sm_info.member_id ), cache_sender_entry->sm_info.member_id.ip, RET_RCV_EXPIRED, first.sn ); #else retval = eventListInsert( &event_list,&( cache_sender_entry->sm_info.member_id ), cache_sender_entry->sm_info.member_id.ip, NAK_SND_WAIT, first.sn ); #endif /* SINGLE_NACK */ #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: NAK_SND_WAIT was inserted in the event list.\n" ); #endif #ifndef SINGLE_NACK }else if( update_nak_list_retval == 0 ) { /* * We have sent the max number of NAK( see rmcast_options structure ) we didn't recover the packet * so we must exit because we cannot keep the reliability */ fprintf( stderr, "********\n" ); fprintf( stderr, "rmcastCatchEvents ERROR: Recovering packet failed. Max number( %d ) of NAKs reached!\n",rmcast_options.max_nak ); fprintf( stderr, "\tHost IP:PID=%s:%d\tsn=%d\n",first.member_id->ip,first.member_id->pid,first.sn ); fprintf( stderr, "********\n" ); RM_leaveGroup( local_user_info.socket, local_user_info.member_id.ip ); } #endif break; case RET_SND_WAIT: if(( data=cacheLookForMessage( &cache, first.member_id, first.sn ) )!=NULL ) { pack.type = RETRANSM_PACKET_TYPE; pack.flags = 0; pack.sender_id = local_user_info.member_id; pack.packet_size = sizeof( RETRANSM_PACKET ); pack.packet_data.retransm_packet.original_sender_id = *first.member_id; pack.packet_data.retransm_packet.data_packet = *data; msgPcktMountMessage( &pack, &message, &msgsize ); #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: will send a RET... " ); #endif rmcastSendPacket( local_user_info.socket, message, msgsize ); #ifdef DEBUG_EVENTS fprintf( stderr, "ok( rmcastCatchEvents )\n" ); #endif } #ifdef DEBUG_EVENTS fprintf( stderr, " \nDEBUG_EVENTS - rmcastCatchEvents: Message retransmited\n ip: %s - pid: %d - sn: %d\n", first.member_id->ip, first.member_id->pid, first.sn ); #endif break; #ifdef REFRESH case REF_SND_WAIT: #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: Processing the refresh event.\n" ); #endif pack.type = REFRESH_PACKET_TYPE; pack.flags = 0; pack.sender_id = local_user_info.member_id; pack.packet_size = sizeof( REFRESH_PACKET ); pthread_mutex_lock( &change_local_user_sn ); pack.packet_data.refresh_packet.sn_of_last_msg_sent = local_user_info.sn - 1; pthread_mutex_unlock( &change_local_user_sn ); #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: Mounting refresh packet.\n" ); #endif msgPcktMountMessage( &pack, &message, &msgsize ); if( rmcastSendPacket( local_user_info.socket, message, msgsize ) == 1 ) eventListInsert( &event_list, NULL, NULL, REF_SND_WAIT, -1 ); /* We are not supposed to set a valid sn in the sn field when we are inserting a REF_SND_WAIT in the event list, so we use a -1 value to the sn in this eventListInsert function call*/ #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: refresh packet mounted.\n" ); #endif #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: Refresh event processed.\n" ); #endif break; #endif case LEV_GRP_WAIT: #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS - rmcastCatchEvents: Processing 'leave group' event.\n" ); #endif if(( group.sin_addr.s_addr = inet_addr( local_user_info.group_id.ip ) ) == ( unsigned )-1 ) perror( "rmcastLeaveGroup: inet_addr" ); mreq.imr_multiaddr = group.sin_addr; mreq.imr_interface.s_addr = INADDR_ANY; if( rmcast_options.transmission_mode == MULTICAST ) { if( setsockopt( local_user_info.socket, IPPROTO_IP, IP_DROP_MEMBERSHIP, ( char * )&mreq, sizeof( mreq ) ) == -1 ) perror( "rmcastLeaveGroup: DROP_MEMBERSHIP" ); } #ifdef DEBUG_NET_MSGS fprintf( stderr, "DEBUG_NET_MSGS rmcastLeaveGroup: disconnected\n" ); #endif remove_queues( 0 ); if( rmcast_options.shut_down_routine!=NULL ) rmcast_options.shut_down_routine( ); function_retval = 1; RM_terminate(); break; default: fprintf( stderr, "rmcastCatchEvents Error: Action Undefined %d\n",first.action ); } if( event_list == NULL ) break; first = *event_list; } while( first.timer_value == 0 && function_retval != 1 ); eventListShow( event_list ); return function_retval; } /*********************** End of the Main routines *************************************************/ /**************** Routines to facilitate the interface with the event list and the cache **********/ /***************************************************************************************************** * * void rmcastProcessDataPacket( PACKET_INFO pckt_info ) * * Processes the data packet. * * Arguments: the packet to be processed, in pckt_info; * * Side effects: may affect the event list, the cache and the message queue. * ******************************************************************************************************/ void rmcastProcessDataPacket( PACKET_INFO pckt_info ) { int i, retval; MEMBER_ID *aux_member_id = &( pckt_info.sender_id ); CACHE_NODE *aux_pckt_info; CACHE *p_old_cache_sender_entry = NULL, *p_new_cache_sender_entry = NULL; #ifdef SINGLE_NACK CACHE *cache_aux1_entry = NULL; #endif CACHE *aux_cache_member; CACHE old_cache_sender_entry, new_cache_sender_entry; bzero(( &old_cache_sender_entry ),sizeof( CACHE ) ); ( old_cache_sender_entry ).sm_info.member_status.last_identified = -1; ( old_cache_sender_entry ).sm_info.member_status.first_rcv = -1; ( old_cache_sender_entry ).sm_info.member_status.last_rcv = -1; ( old_cache_sender_entry ).sm_info.member_status.last_seq_rcv = -1; #ifdef SINGLE_NACK ( old_cache_sender_entry ).sm_info.member_status.window_size = MAX_WINDOW_SIZE; ( old_cache_sender_entry ).sm_info.member_status.window_ini = 0; memset(( old_cache_sender_entry ).sm_info.member_status.window_mask, 0, MAX_WINDOW_SIZE ); #endif p_old_cache_sender_entry = cacheLookForMember( &cache, aux_member_id ); if( ( p_old_cache_sender_entry != NULL ) ) { old_cache_sender_entry = *p_old_cache_sender_entry; if( pckt_info.type == DATA_PACKET_TYPE ) { /* Delete all events about this packet */ if( !rmcastRemoveEvent( &pckt_info,NAK_SND_WAIT ) ) { #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessDataPacket: no NAK_SND_WAIT event found.\n" ); #endif if( !rmcastRemoveEvent( &pckt_info,RET_RCV_WAIT ) ) { #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessDataPacket: no RET_RCV_WAIT found.\n" ); #endif rmcastRemoveEvent( &pckt_info,RET_SND_WAIT ); #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessDataPacket: After rmcastRemoveEvent( &pckt_info,RET_SND_WAIT ).\n" ); #endif } } } } pckt_info.type = DATA_PACKET_TYPE; #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE rmcastProcessDataPacket: Inserting data in cache: ip: %s pid: %d\n",aux_member_id->ip,aux_member_id->pid ); #endif aux_cache_member=cacheLookForMember( &cache, &( pckt_info.sender_id ) ); #ifdef SINGLE_NACK /*block begin*/ { int aux_sn; int aux_cont; int aux_last_seq_rcv; EVENT_LIST *aux_list_node; aux_sn = -1; aux_cont = 0; aux_list_node = NULL; aux_last_seq_rcv = -1; if( aux_cache_member != NULL ) { aux_last_seq_rcv = aux_cache_member->sm_info.member_status.last_seq_rcv; } #endif if(( aux_cache_member == NULL ) ||( pckt_info.packet_data.data_packet.sn > aux_cache_member->sm_info.member_status.last_seq_rcv ) ) retval = cacheInsertMessage( &cache, &( pckt_info.sender_id ), &( pckt_info.packet_data.data_packet ) ); else return; /* Old packet. We don't need to handle it again */ p_new_cache_sender_entry = cacheLookForMember( &cache, aux_member_id ); /* We don't need to test if p_new_cache_sender_entry is NULL because we have just inserted it into the cache */ #ifdef SINGLE_NACK /* When we are sliding the window we must check if we have to send a nack to the next sn available in the window_mask */ if( p_new_cache_sender_entry->sm_info.member_status.last_seq_rcv > aux_last_seq_rcv ) { aux_cont = ( p_new_cache_sender_entry->sm_info.member_status.last_identified - p_new_cache_sender_entry->sm_info.member_status.last_seq_rcv ); if( aux_cont > MAX_WINDOW_SIZE ) { aux_cont = MAX_WINDOW_SIZE; } for( i = p_new_cache_sender_entry->sm_info.member_status.last_seq_rcv + 1; i <= ( aux_cont + p_new_cache_sender_entry->sm_info.member_status.last_seq_rcv ); i++ ) { aux_sn = i; if( cacheLookForMessage( &cache, &( pckt_info.sender_id ), aux_sn ) == NULL ) { #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessDataPacket: trying to insert NAK_SND_WAIT event, sn=%d\n",aux_sn ); #endif if( eventListFind( &event_list,&( pckt_info.sender_id ),NAK_SND_WAIT,aux_sn,&aux_list_node ) != NULL ) { #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessDataPacket: NAK_SND_WAIT exists,just set sn=%d bit\n",aux_sn ); #endif window_mask_set_bit( aux_cache_member->sm_info.member_status.window_mask,aux_sn,&( aux_cache_member->sm_info.member_status ),NAK_SND_WAIT ); } else { if( eventListFind( &event_list,&( pckt_info.sender_id ),RET_RCV_WAIT,aux_sn,&aux_list_node ) != NULL ) { #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessDataPacket: RET_RCV_WAIT event exists, just set sn=%d bit\n",aux_sn ); #endif window_mask_set_bit( aux_cache_member->sm_info.member_status.window_mask,aux_sn,&( aux_cache_member->sm_info.member_status ),RET_RCV_WAIT ); } else { #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessDataPacket:Inserting NAK_SND_WAIT event, sn=%d:\n",aux_sn ); #endif eventListInsert( &event_list,&( aux_cache_member->sm_info.member_id ),aux_cache_member->sm_info.member_id.ip, NAK_SND_WAIT,aux_sn ); } } } } } } #endif /*SINGLE_NACK block end*/ new_cache_sender_entry = *p_new_cache_sender_entry; cacheShow( cache ); eventListShow( event_list ); aux_pckt_info = new_cache_sender_entry.last_inserted; if( retval == 1 ) /* the inserted packet is in sequence -> we will send data to the application */ { #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE rmcastProcessDataPacket: The inserted packet is in sequence...\n" ); #endif for( i = old_cache_sender_entry.sm_info.member_status.last_seq_rcv + 1; i <= new_cache_sender_entry.sm_info.member_status.last_seq_rcv; i++ ) { #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE rmcastProcessDataPacket: A \"reliable\" message will be enqueued:( sn: %d size: %d )\n", i, pckt_info.packet_data.data_packet.data_size ); #endif if( messageQueueEnter(( char* )( aux_pckt_info->data_pckt.data ),pckt_info.packet_data.data_packet.data_size ) != -1 ) { aux_pckt_info = aux_pckt_info->previous; } else { fprintf( stderr, "messageQueueEnter ERROR!\n" ); RM_leaveGroup( local_user_info.socket, local_user_info.member_id.ip ); } } #ifdef DSINGLE_NACK eventListShow( event_list ); #endif } else if( retval == 2 ) /* the inserted packet is not in sequence -> we will send nak's through the network */ { #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE rmcastprocessdatapacket: The inserted packet is NOT in sequence... \n" ); fprintf( stderr, "DEBUG_CACHE rmcastProcessDataPacket: showing eventlist:\n" ); eventListShow( event_list ); #endif for( i = old_cache_sender_entry.sm_info.member_status.last_identified+1; i < new_cache_sender_entry.sm_info.member_status.last_identified; i++ ) { pckt_info.packet_data.data_packet.sn = i; if( cacheLookForMessage( &cache, aux_member_id, i )==NULL ) { #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS rmcastProcessDataPacket: trying to schedule a NAK_SND_WAIT event to( sn: %d )\n", i ); fprintf( stderr, "DEBUG_EVENTS rmcastProcessDataPacket: new_cache_sender_entry.sm_info.member_status.last_seq_rcv=%d\n", new_cache_sender_entry.sm_info.member_status.last_seq_rcv ); #endif #ifdef SINGLE_NACK if( i < new_cache_sender_entry.sm_info.member_status.last_seq_rcv + MAX_WINDOW_SIZE ) { #endif if( !rmcastFindEvent( &pckt_info,NAK_SND_WAIT ) ) { if( !rmcastFindEvent( &pckt_info, RET_RCV_WAIT ) ) { #ifndef SINGLE_NACK /* when we are using SINGLE_NACK this check is done inside eventListInsert */ if( cacheUpdateNakList( &cache, &( pckt_info.sender_id ), i )!=0 ) { #endif rmcastInsertEvent( &pckt_info,NAK_SND_WAIT ); #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS rmcastProcessDataPacket: NAK_SND_WAIT was inserted in the event list.\n" ); #endif #ifndef SINGLE_NACK } else { /* * We have sent the max number of NAK( see rmcast_options structure ) we didn't recover the packet * so we must exit because we cannot keep the reliability */ fprintf( stderr, "********\n" ); fprintf( stderr, "rmcastProcessDataPacket ERROR: Recovering packet failed. Max number( %d ) of NAKs reached!\n",rmcast_options.max_nak ); fprintf( stderr, "\tHost IP:PID=%s:%d\tsn=%d\n",aux_member_id->ip,aux_member_id->pid,i ); fprintf( stderr, "********\n" ); RM_leaveGroup( local_user_info.socket, local_user_info.member_id.ip ); } #endif } #ifdef SINGLE_NACK else { cache_aux1_entry=cacheLookForMember( &cache, aux_member_id ); #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessDataPacket: before window_mask_set_bit\n" ); fprintf( stderr, "DSINGLE_NACK rmcastProcessDataPacket: there is a RET_RCV_WAIT, just set sn=%d\n",i ); #endif window_mask_set_bit( cache_aux1_entry->sm_info.member_status.window_mask, i,&cache_aux1_entry->sm_info.member_status,RET_RCV_WAIT ); } #endif } #ifdef SINGLE_NACK else { int aux_retval=0; #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessDataPacket: found a NAK_SND_WAIT event.\n" ); #endif cache_aux1_entry=cacheLookForMember( &cache, aux_member_id ); #ifdef DWINDOW_MASK fprintf( stderr, "DWINDOW_MASK rmcastProcessDataPacket: before window_mask_get_bit\n" ); fprintf( stderr, "DWINDOW_MASK rmcastProcessDataPacket: window_mask=%p\n",cache_aux1_entry->sm_info.member_status.window_mask ); fprintf( stderr, "DWINDOW_MASK rmcastProcessDataPacket: sn=%d\n",i ); fprintf( stderr, "DWINDOW_MASK rmcastProcessDataPacket: member_status=%p\n",&cache_aux1_entry->sm_info.member_status ); #endif aux_retval=window_mask_get_bit( cache_aux1_entry->sm_info.member_status.window_mask,i,&cache_aux1_entry->sm_info.member_status ); if( aux_retval != RET_RCV_WAIT ) /* FIXME - este teste pode nao ser necessario pois nao queremos eventos NAK e RET_RCV concorrentes */ { if( cacheUpdateNakList( &cache, &( pckt_info.sender_id ), i )!=0 ) { #ifdef DEBUG_EVENTS fprintf( stderr, "DEBUG_EVENTS rmcastProcessDataPacket: NAK_SND_WAIT event exists, just set sn=%d to NAK_SND_WAIT\n",i ); #endif window_mask_set_bit( cache_aux1_entry->sm_info.member_status.window_mask,i,&cache_aux1_entry->sm_info.member_status,NAK_SND_WAIT ); } else { /* * We have sent the max number of NAK( see rmcast_options structure ) we didn't recover the packet * so we must exit because we cannot keep the reliability */ fprintf( stderr, "********\n" ); fprintf( stderr, "rmcastProcessDataPacket ERROR: Recovering packet failed. Max number( %d ) of NAKs reached!\n",rmcast_options.max_nak ); fprintf( stderr, "\tHost IP:PID=%s:%d\tsn=%d\n",aux_member_id->ip,aux_member_id->pid,i ); fprintf( stderr, "********\n" ); RM_leaveGroup( local_user_info.socket, local_user_info.member_id.ip ); } } } } /* i is in the window_mask range*/ #endif /*SINGLE_NACK */ } /* message exists we don't need to send a NACK */ } /* for( i = old_cache_sender_entry.sm_info.member_status.last_identified+1; ... */ } /*else if( retval==2 ) */ else { #ifdef DEBUG_CACHE fprintf( stderr, "DEBUG_CACHE rmcastProcessDataPacket: CouldnŽt insert cache node.\n" ); #endif } } /***************************************************************************************************** * * void rmcastProcessRefreshPacket( PACKET_INFO pckt_info ) * * Processes the refresh packet. * * Arguments: the packet to be processed, in pckt_info; * * Side effects: may affect the event list, the cache and the message queue. * ******************************************************************************************************/ #ifdef REFRESH void rmcastProcessRefreshPacket( PACKET_INFO pckt_info ) { int i, new_value_of_last_identified; CACHE *cache_sender_entry; cache_sender_entry = cacheLookForMember( &cache, &( pckt_info.sender_id ) ); if( pckt_info.packet_data.refresh_packet.sn_of_last_msg_sent < 0 ) return; if( cache_sender_entry == NULL ) { cache_sender_entry = cacheInsertMember( &cache, &( pckt_info.sender_id ) ); } new_value_of_last_identified = pckt_info.packet_data.refresh_packet.sn_of_last_msg_sent; #ifdef SINGLE_NACK if( new_value_of_last_identified >( cache_sender_entry->sm_info.member_status.last_seq_rcv + MAX_WINDOW_SIZE ) ) { /* Send NACKs that fit in the window */ new_value_of_last_identified = cache_sender_entry->sm_info.member_status.last_seq_rcv + MAX_WINDOW_SIZE; } for( i = new_value_of_last_identified; i > cache_sender_entry->sm_info.member_status.last_identified; i -- ) { if( !rmcastFindEvent( &pckt_info,NAK_SND_WAIT ) ) { if( !rmcastFindEvent( &pckt_info,RET_RCV_WAIT ) ) { pckt_info.packet_data.refresh_packet.sn_of_last_msg_sent = i; rmcastInsertEvent( &pckt_info,NAK_SND_WAIT ); #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessRefreshPacket: NAK_SND_WAIT insertion caused by refresh message\n" ); fprintf( stderr, "DSINGLE_NACK rmcastProcessRefreshPacket: host:pid:sn=%s:%d:%d\n", pckt_info.sender_id.ip,pckt_info.sender_id.pid,i ); #endif } else { /* RET_RCV_WAIT exists, just set the i bit in the window_mask */ window_mask_set_bit( cache_sender_entry->sm_info.member_status.window_mask, i, &( cache_sender_entry->sm_info.member_status ), RET_RCV_WAIT ); #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessRefreshPacket: bit settled to RET_RCV_WAIT caused by refresh message\n" ); fprintf( stderr, "DSINGLE_NACK rmcastProcessRefreshPacket: host:pid:sn=%s:%d:%d\n", pckt_info.sender_id.ip,pckt_info.sender_id.pid,i ); #endif } } else { /* NAK_SND_WAIT exists, just set the i bit in the window_mask */ window_mask_set_bit( cache_sender_entry->sm_info.member_status.window_mask, i, &( cache_sender_entry->sm_info.member_status ), NAK_SND_WAIT ); #ifdef DSINGLE_NACK fprintf( stderr, "DSINGLE_NACK rmcastProcessRefreshPacket: bit settled to NAK_RCV_WAIT caused by refresh message\n" ); fprintf( stderr, "DSINGLE_NACK rmcastProcessRefreshPacket: host:pid:sn=%s:%d:%d\n", pckt_info.sender_id.ip,pckt_info.sender_id.pid,i ); #endif } } #else for( i = pckt_info.packet_data.refresh_packet.sn_of_last_msg_sent; i > cache_sender_entry->sm_info.member_status.last_identified; i -- ) { #ifdef DEBUG_EVENTS fprintf( stderr, "Will wait to send a nak, i: %d last received or nak: %d.\n", i, cache_sender_entry->sm_info.member_status.last_identified ); #endif pckt_info.packet_data.refresh_packet.sn_of_last_msg_sent = i; rmcastInsertEvent( &pckt_info,NAK_SND_WAIT ); } #endif /* SINGLE_NACK */ if( cache_sender_entry->sm_info.member_status.last_identified < new_value_of_last_identified ) cache_sender_entry->sm_info.member_status.last_identified = new_value_of_last_identified; } #endif /***************************************************************************************************** * * int rmcastRemoveEvent( PACKET_INFO *packt, int event_type ) * * Removes an event from the event list. * * Arguments: the network packet, in packt; * the event type, in event_type. * * Returns: 1, on sucess; * 0, otherwise. * * Side effects: it affects the event list. * ******************************************************************************************************/ int rmcastRemoveEvent( PACKET_INFO *packt, int event_type ) { int retval; retval = 0; switch( packt->type ) { case RETRANSM_PACKET_TYPE: retval = eventListRemove( &event_list, &( packt->packet_data.retransm_packet.original_sender_id ), event_type, packt->packet_data.retransm_packet.data_packet.sn ); break; case DATA_PACKET_TYPE: retval = eventListRemove( &event_list, &( packt->sender_id ), event_type, packt->packet_data.data_packet.sn ); break; case NAK_PACKET_TYPE: #ifdef DNAK_RCV fprintf( stderr, "rmcastRemoveEvent: calling eventListRemove\n" ); #endif retval = eventListRemove( &event_list, &( packt->packet_data.nak_packet.requested_member_id ), event_type, packt->packet_data.nak_packet.sn ); #ifdef DNAK_RCV fprintf( stderr, "rmcastRemoveEvent: after calling eventListRemove\n" ); #endif break; } return retval; } /***************************************************************************************************** * * int rmcastFindEvent( PACKET_INFO *packt, int event_type ) * * Searches for an event in the event list. * * Arguments: the network packet, in packt; * the event type, in event_type. * * Returns: 1, on sucess; * 0, otherwise. * ******************************************************************************************************/ int rmcastFindEvent( PACKET_INFO *packt, int event_type ) { int retval; EVENT_LIST *aux; switch( packt->type ) { case NAK_PACKET_TYPE: #ifdef DNAK_RCV fprintf( stderr, "rmcastFindEvent: calling eventlistFind to look for event:%d\n",event_type ); #endif retval = (( eventListFind( &event_list, &( packt->packet_data.nak_packet.requested_member_id ), event_type, packt->packet_data.nak_packet.sn,&aux ) )!= NULL ); #ifdef DNAK_RCV fprintf( stderr, "rmcastFindEvent: after calling eventlistFind to look for event:%d, retval=%d\n",event_type,retval ); #endif break; case DATA_PACKET_TYPE: retval = (( eventListFind( &event_list, &( packt->sender_id ), event_type, packt->packet_data.data_packet.sn,&aux ) )!=NULL ); break; case REFRESH_PACKET_TYPE: retval = (( eventListFind( &event_list, &( packt->sender_id ), event_type, packt->packet_data.refresh_packet.sn_of_last_msg_sent,&aux ) )!=NULL ); break; default: fprintf( stderr, "rmcastFindEvent ERROR: Not yet implemented event=%d packet_type=%d.\n",event_type,packt->type ); return 0; } return retval; } /***************************************************************************************************** * * int rmcastCacheContains( PACKET_INFO *packt ) * * Searches for a packet in the cache. * * Arguments: the network packet, in packt; * * Returns: 1, on sucess; * 0, otherwise. * ******************************************************************************************************/ int rmcastCacheContains( PACKET_INFO *packt ) { int retval; retval = 0; switch( packt->type ) { case NAK_PACKET_TYPE: retval = (( cacheLookForMessage( &cache, &( packt->packet_data.nak_packet.requested_member_id ), packt->packet_data.nak_packet.sn ) )!= NULL ); break; case RETRANSM_PACKET_TYPE: retval = (( cacheLookForMessage( &cache, &( packt->packet_data.retransm_packet.original_sender_id ), packt->packet_data.retransm_packet.data_packet.sn ) )!= NULL ); break; default: fprintf( stderr, "rmcastCacheContains: Unknown packet type:%d\n",packt->type ); RM_leaveGroup( local_user_info.socket, local_user_info.member_id.ip ); } return retval; } /***************************************************************************************************** * * int rmcastInsertEvent( PACKET_INFO *packt, int event_type ) * * Inserts an event in the event list. * * Arguments: the network packet, in packt; * the event type, in event_type. * * Returns: 1, on sucess; * 0, otherwise. * * Side effects: it affects the event list. * ******************************************************************************************************/ int rmcastInsertEvent( PACKET_INFO *packt, int event_type ) { int retval; CACHE *cache_sender_entry; retval = 0; switch( packt->type ) { case NAK_PACKET_TYPE: cache_sender_entry = cacheLookForMember( &cache, &( packt->packet_data.nak_packet.requested_member_id ) ); #ifdef DNAK_RCV fprintf( stderr, "rmcastInsertEvent: calling eventListInsert\n" ); #endif if( cache_sender_entry != NULL ) retval = eventListInsert( &event_list, &( cache_sender_entry->sm_info.member_id ), packt->sender_id.ip, event_type, ( packt->packet_data.nak_packet.sn ) ); #ifdef DNAK_RCV fprintf( stderr, "rmcastInsertEvent: after calling eventListInsert cache_sender_entry:%p\n",cache_sender_entry ); #endif break; case DATA_PACKET_TYPE: cache_sender_entry = cacheLookForMember( &cache, &( packt->sender_id ) ); if( cache_sender_entry!=NULL ) retval = eventListInsert( &event_list,&( cache_sender_entry->sm_info.member_id ), packt->sender_id.ip, event_type, packt->packet_data.data_packet.sn ); break; case REFRESH_PACKET_TYPE: cache_sender_entry = cacheLookForMember( &cache, &( packt->sender_id ) ); if( cache_sender_entry!=NULL ) retval = eventListInsert( &event_list,&( cache_sender_entry->sm_info.member_id ), packt->sender_id.ip,event_type, packt->packet_data.refresh_packet.sn_of_last_msg_sent ); break; default: fprintf( stderr, "rmcastInsertEvent: Unknown event type:%d\n",packt->type ); RM_leaveGroup( local_user_info.socket, local_user_info.member_id.ip ); } #ifdef DNAK_RCV if( event_type == NAK_PACKET_TYPE ) { fprintf( stderr, "rmcastInsertEvent: Show cache after NACK event insertion\n" ); cacheShow( cache ); } #endif return retval; } /**********End of the Routines to facilitate the interface with the event list and the cache ******/ #endif tgif-QPL-4.2.5/rmcast/config/0000755000076400007640000000000011602233155015527 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/config/install-sh0000755000076400007640000001273610122646341017545 0ustar williamwilliam#!/bin/sh # # install - install a program, script, or datafile # This comes from X11R5 (mit/util/scripts/install.sh). # # Copyright 1991 by the Massachusetts Institute of Technology # # Permission to use, copy, modify, distribute, and sell this software and its # documentation for any purpose is hereby granted without fee, provided that # the above copyright notice appear in all copies and that both that # copyright notice and this permission notice appear in supporting # documentation, and that the name of M.I.T. not be used in advertising or # publicity pertaining to distribution of the software without specific, # written prior permission. M.I.T. makes no representations about the # suitability of this software for any purpose. It is provided "as is" # without express or implied warranty. # # Calling this script install-sh is preferred over install.sh, to prevent # `make' implicit rules from creating a file called install from it # when there is no Makefile. # # This script is compatible with the BSD install script, but was written # from scratch. It can only install one file at a time, a restriction # shared with many OS's install programs. # set DOITPROG to echo to test this script # Don't use :- since 4.3BSD and earlier shells don't like it. doit="${DOITPROG-}" # put in absolute paths if you don't have them in your path; or use env. vars. mvprog="${MVPROG-mv}" cpprog="${CPPROG-cp}" chmodprog="${CHMODPROG-chmod}" chownprog="${CHOWNPROG-chown}" chgrpprog="${CHGRPPROG-chgrp}" stripprog="${STRIPPROG-strip}" rmprog="${RMPROG-rm}" mkdirprog="${MKDIRPROG-mkdir}" transformbasename="" transform_arg="" instcmd="$mvprog" chmodcmd="$chmodprog 0755" chowncmd="" chgrpcmd="" stripcmd="" rmcmd="$rmprog -f" mvcmd="$mvprog" src="" dst="" dir_arg="" while [ x"$1" != x ]; do case $1 in -c) instcmd="$cpprog" shift continue;; -d) dir_arg=true shift continue;; -m) chmodcmd="$chmodprog $2" shift shift continue;; -o) chowncmd="$chownprog $2" shift shift continue;; -g) chgrpcmd="$chgrpprog $2" shift shift continue;; -s) stripcmd="$stripprog" shift continue;; -t=*) transformarg=`echo $1 | sed 's/-t=//'` shift continue;; -b=*) transformbasename=`echo $1 | sed 's/-b=//'` shift continue;; *) if [ x"$src" = x ] then src=$1 else # this colon is to work around a 386BSD /bin/sh bug : dst=$1 fi shift continue;; esac done if [ x"$src" = x ] then echo "install: no input file specified" exit 1 else true fi if [ x"$dir_arg" != x ]; then dst=$src src="" if [ -d $dst ]; then instcmd=: chmodcmd="" else instcmd=mkdir fi else # Waiting for this to be detected by the "$instcmd $src $dsttmp" command # might cause directories to be created, which would be especially bad # if $src (and thus $dsttmp) contains '*'. if [ -f $src -o -d $src ] then true else echo "install: $src does not exist" exit 1 fi if [ x"$dst" = x ] then echo "install: no destination specified" exit 1 else true fi # If destination is a directory, append the input filename; if your system # does not like double slashes in filenames, you may need to add some logic if [ -d $dst ] then dst="$dst"/`basename $src` else true fi fi ## this sed command emulates the dirname command dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'` # Make sure that the destination directory exists. # this part is taken from Noah Friedman's mkinstalldirs script # Skip lots of stat calls in the usual case. if [ ! -d "$dstdir" ]; then defaultIFS=' ' IFS="${IFS-${defaultIFS}}" oIFS="${IFS}" # Some sh's can't handle IFS=/ for some reason. IFS='%' set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'` IFS="${oIFS}" pathcomp='' while [ $# -ne 0 ] ; do pathcomp="${pathcomp}${1}" shift if [ ! -d "${pathcomp}" ] ; then $mkdirprog "${pathcomp}" else true fi pathcomp="${pathcomp}/" done fi if [ x"$dir_arg" != x ] then $doit $instcmd $dst && if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi && if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi && if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi && if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi else # If we're going to rename the final executable, determine the name now. if [ x"$transformarg" = x ] then dstfile=`basename $dst` else dstfile=`basename $dst $transformbasename | sed $transformarg`$transformbasename fi # don't allow the sed command to completely eliminate the filename if [ x"$dstfile" = x ] then dstfile=`basename $dst` else true fi # Make a temp file name in the proper directory. dsttmp=$dstdir/#inst.$$# # Move or copy the file name to the temp name $doit $instcmd $src $dsttmp && trap "rm -f ${dsttmp}" 0 && # and set any options; do chmod last to preserve setuid bits # If any of these fail, we abort the whole thing. If we want to # ignore errors from any of these, just make sure not to ignore # errors from the above "$doit $instcmd $src $dsttmp" command. if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else true;fi && if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else true;fi && if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else true;fi && if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else true;fi && # Now rename the file to the real destination. $doit $rmcmd -f $dstdir/$dstfile && $doit $mvcmd $dsttmp $dstdir/$dstfile fi && exit 0 tgif-QPL-4.2.5/rmcast/config/config.sub0000755000076400007640000007772411222706506017536 0ustar williamwilliam#! /bin/sh # Configuration validation subroutine script. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, # Inc. timestamp='2007-06-28' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software # can handle that machine. It does not imply ALL GNU software can. # # This file is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA # 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Please send patches to . Submit a context # diff and a properly formatted ChangeLog entry. # # Configuration subroutine to validate and canonicalize a configuration type. # Supply the specified configuration type as an argument. # If it is invalid, we print an error message on stderr and exit with code 1. # Otherwise, we print the canonical config type on stdout and succeed. # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases # that are meaningful with *any* GNU software. # Each package is responsible for reporting which valid configurations # it does not support. The user should be able to distinguish # a failure to support a valid configuration from a meaningless # configuration. # The goal of this file is to map all the various variations of a given # machine specification into a single specification in the form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM # or in some cases, the newer four-part form: # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM # It is wrong to echo any other type of specification. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] CPU-MFR-OPSYS $0 [OPTION] ALIAS Canonicalize a configuration name. Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.sub ($timestamp) Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" exit 1 ;; *local*) # First pass through any local machine types. echo $1 exit ;; * ) break ;; esac done case $# in 0) echo "$me: missing argument$help" >&2 exit 1;; 1) ;; *) echo "$me: too many arguments$help" >&2 exit 1;; esac # Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). # Here we must recognize all the valid KERNEL-OS combinations. maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \ uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \ storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; *) basic_machine=`echo $1 | sed 's/-[^-]*$//'` if [ $basic_machine != $1 ] then os=`echo $1 | sed 's/.*-/-/'` else os=; fi ;; esac ### Let's recognize common machines as not being operating systems so ### that things like config.sub decstation-3100 work. We also ### recognize some manufacturers as not being operating systems, so we ### can provide default operating systems below. case $os in -sun*os*) # Prevent following clause from handling this invalid input. ;; -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ -apple | -axis | -knuth | -cray) os= basic_machine=$1 ;; -sim | -cisco | -oki | -wec | -winbond) os= basic_machine=$1 ;; -scout) ;; -wrs) os=-vxworks basic_machine=$1 ;; -chorusos*) os=-chorusos basic_machine=$1 ;; -chorusrdb) os=-chorusrdb basic_machine=$1 ;; -hiux*) os=-hiuxwe2 ;; -sco6) os=-sco5v6 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco5) os=-sco3.2v5 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco4) os=-sco3.2v4 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2.[4-9]*) os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2v[4-9]*) # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco5v6*) # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco*) os=-sco3.2v2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -udk*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -isc) os=-isc2.2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -clix*) basic_machine=clipper-intergraph ;; -isc*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -lynx*) os=-lynxos ;; -ptx*) basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` ;; -windowsnt*) os=`echo $os | sed -e 's/windowsnt/winnt/'` ;; -psos*) os=-psos ;; -mint | -mint[0-9]*) basic_machine=m68k-atari os=-mint ;; esac # Decode aliases for certain CPU-COMPANY combinations. case $basic_machine in # Recognize the basic CPU types without company name. # Some are omitted here because they have special meanings below. 1750a | 580 \ | a29k \ | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | am33_2.0 \ | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ | bfin \ | c4x | clipper \ | d10v | d30v | dlx | dsp16xx \ | fido | fr30 | frv \ | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ | i370 | i860 | i960 | ia64 \ | ip2k | iq2000 \ | m32c | m32r | m32rle | m68000 | m68k | m88k \ | maxq | mb | microblaze | mcore | mep \ | mips | mipsbe | mipseb | mipsel | mipsle \ | mips16 \ | mips64 | mips64el \ | mips64vr | mips64vrel \ | mips64orion | mips64orionel \ | mips64vr4100 | mips64vr4100el \ | mips64vr4300 | mips64vr4300el \ | mips64vr5000 | mips64vr5000el \ | mips64vr5900 | mips64vr5900el \ | mipsisa32 | mipsisa32el \ | mipsisa32r2 | mipsisa32r2el \ | mipsisa64 | mipsisa64el \ | mipsisa64r2 | mipsisa64r2el \ | mipsisa64sb1 | mipsisa64sb1el \ | mipsisa64sr71k | mipsisa64sr71kel \ | mipstx39 | mipstx39el \ | mn10200 | mn10300 \ | mt \ | msp430 \ | nios | nios2 \ | ns16k | ns32k \ | or32 \ | pdp10 | pdp11 | pj | pjl \ | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ | pyramid \ | score \ | sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ | sh64 | sh64le \ | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ | spu | strongarm \ | tahoe | thumb | tic4x | tic80 | tron \ | v850 | v850e \ | we32k \ | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \ | z8k) basic_machine=$basic_machine-unknown ;; m6811 | m68hc11 | m6812 | m68hc12) # Motorola 68HC11/12. basic_machine=$basic_machine-unknown os=-none ;; m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) ;; ms1) basic_machine=mt-unknown ;; # We use `pc' rather than `unknown' # because (1) that's what they normally are, and # (2) the word "unknown" tends to confuse beginning users. i*86 | x86_64) basic_machine=$basic_machine-pc ;; # Object if more than one company name word. *-*-*) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; # Recognize the basic CPU types with company name. 580-* \ | a29k-* \ | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ | avr-* | avr32-* \ | bfin-* | bs2000-* \ | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \ | clipper-* | craynv-* | cydra-* \ | d10v-* | d30v-* | dlx-* \ | elxsi-* \ | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ | h8300-* | h8500-* \ | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ | i*86-* | i860-* | i960-* | ia64-* \ | ip2k-* | iq2000-* \ | m32c-* | m32r-* | m32rle-* \ | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ | m88110-* | m88k-* | maxq-* | mcore-* \ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ | mips16-* \ | mips64-* | mips64el-* \ | mips64vr-* | mips64vrel-* \ | mips64orion-* | mips64orionel-* \ | mips64vr4100-* | mips64vr4100el-* \ | mips64vr4300-* | mips64vr4300el-* \ | mips64vr5000-* | mips64vr5000el-* \ | mips64vr5900-* | mips64vr5900el-* \ | mipsisa32-* | mipsisa32el-* \ | mipsisa32r2-* | mipsisa32r2el-* \ | mipsisa64-* | mipsisa64el-* \ | mipsisa64r2-* | mipsisa64r2el-* \ | mipsisa64sb1-* | mipsisa64sb1el-* \ | mipsisa64sr71k-* | mipsisa64sr71kel-* \ | mipstx39-* | mipstx39el-* \ | mmix-* \ | mt-* \ | msp430-* \ | nios-* | nios2-* \ | none-* | np1-* | ns16k-* | ns32k-* \ | orion-* \ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \ | pyramid-* \ | romp-* | rs6000-* \ | sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ | sparclite-* \ | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \ | tahoe-* | thumb-* \ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ | tron-* \ | v850-* | v850e-* | vax-* \ | we32k-* \ | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \ | xstormy16-* | xtensa-* \ | ymp-* \ | z8k-*) ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 386bsd) basic_machine=i386-unknown os=-bsd ;; 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) basic_machine=m68000-att ;; 3b*) basic_machine=we32k-att ;; a29khif) basic_machine=a29k-amd os=-udi ;; abacus) basic_machine=abacus-unknown ;; adobe68k) basic_machine=m68010-adobe os=-scout ;; alliant | fx80) basic_machine=fx80-alliant ;; altos | altos3068) basic_machine=m68k-altos ;; am29k) basic_machine=a29k-none os=-bsd ;; amd64) basic_machine=x86_64-pc ;; amd64-*) basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; amdahl) basic_machine=580-amdahl os=-sysv ;; amiga | amiga-*) basic_machine=m68k-unknown ;; amigaos | amigados) basic_machine=m68k-unknown os=-amigaos ;; amigaunix | amix) basic_machine=m68k-unknown os=-sysv4 ;; apollo68) basic_machine=m68k-apollo os=-sysv ;; apollo68bsd) basic_machine=m68k-apollo os=-bsd ;; aux) basic_machine=m68k-apple os=-aux ;; balance) basic_machine=ns32k-sequent os=-dynix ;; c90) basic_machine=c90-cray os=-unicos ;; convex-c1) basic_machine=c1-convex os=-bsd ;; convex-c2) basic_machine=c2-convex os=-bsd ;; convex-c32) basic_machine=c32-convex os=-bsd ;; convex-c34) basic_machine=c34-convex os=-bsd ;; convex-c38) basic_machine=c38-convex os=-bsd ;; cray | j90) basic_machine=j90-cray os=-unicos ;; craynv) basic_machine=craynv-cray os=-unicosmp ;; cr16) basic_machine=cr16-unknown os=-elf ;; crds | unos) basic_machine=m68k-crds ;; crisv32 | crisv32-* | etraxfs*) basic_machine=crisv32-axis ;; cris | cris-* | etrax*) basic_machine=cris-axis ;; crx) basic_machine=crx-unknown os=-elf ;; da30 | da30-*) basic_machine=m68k-da30 ;; decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) basic_machine=mips-dec ;; decsystem10* | dec10*) basic_machine=pdp10-dec os=-tops10 ;; decsystem20* | dec20*) basic_machine=pdp10-dec os=-tops20 ;; delta | 3300 | motorola-3300 | motorola-delta \ | 3300-motorola | delta-motorola) basic_machine=m68k-motorola ;; delta88) basic_machine=m88k-motorola os=-sysv3 ;; djgpp) basic_machine=i586-pc os=-msdosdjgpp ;; dpx20 | dpx20-*) basic_machine=rs6000-bull os=-bosx ;; dpx2* | dpx2*-bull) basic_machine=m68k-bull os=-sysv3 ;; ebmon29k) basic_machine=a29k-amd os=-ebmon ;; elxsi) basic_machine=elxsi-elxsi os=-bsd ;; encore | umax | mmax) basic_machine=ns32k-encore ;; es1800 | OSE68k | ose68k | ose | OSE) basic_machine=m68k-ericsson os=-ose ;; fx2800) basic_machine=i860-alliant ;; genix) basic_machine=ns32k-ns ;; gmicro) basic_machine=tron-gmicro os=-sysv ;; go32) basic_machine=i386-pc os=-go32 ;; h3050r* | hiux*) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; h8300hms) basic_machine=h8300-hitachi os=-hms ;; h8300xray) basic_machine=h8300-hitachi os=-xray ;; h8500hms) basic_machine=h8500-hitachi os=-hms ;; harris) basic_machine=m88k-harris os=-sysv3 ;; hp300-*) basic_machine=m68k-hp ;; hp300bsd) basic_machine=m68k-hp os=-bsd ;; hp300hpux) basic_machine=m68k-hp os=-hpux ;; hp3k9[0-9][0-9] | hp9[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k2[0-9][0-9] | hp9k31[0-9]) basic_machine=m68000-hp ;; hp9k3[2-9][0-9]) basic_machine=m68k-hp ;; hp9k6[0-9][0-9] | hp6[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k7[0-79][0-9] | hp7[0-79][0-9]) basic_machine=hppa1.1-hp ;; hp9k78[0-9] | hp78[0-9]) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[0-9][13679] | hp8[0-9][13679]) basic_machine=hppa1.1-hp ;; hp9k8[0-9][0-9] | hp8[0-9][0-9]) basic_machine=hppa1.0-hp ;; hppa-next) os=-nextstep3 ;; hppaosf) basic_machine=hppa1.1-hp os=-osf ;; hppro) basic_machine=hppa1.1-hp os=-proelf ;; i370-ibm* | ibm*) basic_machine=i370-ibm ;; # I'm not sure what "Sysv32" means. Should this be sysv3.2? i*86v32) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv32 ;; i*86v4*) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv4 ;; i*86v) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv ;; i*86sol2) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-solaris2 ;; i386mach) basic_machine=i386-mach os=-mach ;; i386-vsta | vsta) basic_machine=i386-unknown os=-vsta ;; iris | iris4d) basic_machine=mips-sgi case $os in -irix*) ;; *) os=-irix4 ;; esac ;; isi68 | isi) basic_machine=m68k-isi os=-sysv ;; m88k-omron*) basic_machine=m88k-omron ;; magnum | m3230) basic_machine=mips-mips os=-sysv ;; merlin) basic_machine=ns32k-utek os=-sysv ;; mingw32) basic_machine=i386-pc os=-mingw32 ;; mingw32ce) basic_machine=arm-unknown os=-mingw32ce ;; miniframe) basic_machine=m68000-convergent ;; *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) basic_machine=m68k-atari os=-mint ;; mips3*-*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` ;; mips3*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown ;; monitor) basic_machine=m68k-rom68k os=-coff ;; morphos) basic_machine=powerpc-unknown os=-morphos ;; msdos) basic_machine=i386-pc os=-msdos ;; ms1-*) basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` ;; mvs) basic_machine=i370-ibm os=-mvs ;; ncr3000) basic_machine=i486-ncr os=-sysv4 ;; netbsd386) basic_machine=i386-unknown os=-netbsd ;; netwinder) basic_machine=armv4l-rebel os=-linux ;; news | news700 | news800 | news900) basic_machine=m68k-sony os=-newsos ;; news1000) basic_machine=m68030-sony os=-newsos ;; news-3600 | risc-news) basic_machine=mips-sony os=-newsos ;; necv70) basic_machine=v70-nec os=-sysv ;; next | m*-next ) basic_machine=m68k-next case $os in -nextstep* ) ;; -ns2*) os=-nextstep2 ;; *) os=-nextstep3 ;; esac ;; nh3000) basic_machine=m68k-harris os=-cxux ;; nh[45]000) basic_machine=m88k-harris os=-cxux ;; nindy960) basic_machine=i960-intel os=-nindy ;; mon960) basic_machine=i960-intel os=-mon960 ;; nonstopux) basic_machine=mips-compaq os=-nonstopux ;; np1) basic_machine=np1-gould ;; nsr-tandem) basic_machine=nsr-tandem ;; op50n-* | op60c-*) basic_machine=hppa1.1-oki os=-proelf ;; openrisc | openrisc-*) basic_machine=or32-unknown ;; os400) basic_machine=powerpc-ibm os=-os400 ;; OSE68000 | ose68000) basic_machine=m68000-ericsson os=-ose ;; os68k) basic_machine=m68k-none os=-os68k ;; pa-hitachi) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; paragon) basic_machine=i860-intel os=-osf ;; pbd) basic_machine=sparc-tti ;; pbb) basic_machine=m68k-tti ;; pc532 | pc532-*) basic_machine=ns32k-pc532 ;; pc98) basic_machine=i386-pc ;; pc98-*) basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentium | p5 | k5 | k6 | nexgen | viac3) basic_machine=i586-pc ;; pentiumpro | p6 | 6x86 | athlon | athlon_*) basic_machine=i686-pc ;; pentiumii | pentium2 | pentiumiii | pentium3) basic_machine=i686-pc ;; pentium4) basic_machine=i786-pc ;; pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumpro-* | p6-* | 6x86-* | athlon-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentium4-*) basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pn) basic_machine=pn-gould ;; power) basic_machine=power-ibm ;; ppc) basic_machine=powerpc-unknown ;; ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppcle | powerpclittle | ppc-le | powerpc-little) basic_machine=powerpcle-unknown ;; ppcle-* | powerpclittle-*) basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64) basic_machine=powerpc64-unknown ;; ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64le | powerpc64little | ppc64-le | powerpc64-little) basic_machine=powerpc64le-unknown ;; ppc64le-* | powerpc64little-*) basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ps2) basic_machine=i386-ibm ;; pw32) basic_machine=i586-unknown os=-pw32 ;; rdos) basic_machine=i386-pc os=-rdos ;; rom68k) basic_machine=m68k-rom68k os=-coff ;; rm[46]00) basic_machine=mips-siemens ;; rtpc | rtpc-*) basic_machine=romp-ibm ;; s390 | s390-*) basic_machine=s390-ibm ;; s390x | s390x-*) basic_machine=s390x-ibm ;; sa29200) basic_machine=a29k-amd os=-udi ;; sb1) basic_machine=mipsisa64sb1-unknown ;; sb1el) basic_machine=mipsisa64sb1el-unknown ;; sde) basic_machine=mipsisa32-sde os=-elf ;; sei) basic_machine=mips-sei os=-seiux ;; sequent) basic_machine=i386-sequent ;; sh) basic_machine=sh-hitachi os=-hms ;; sh5el) basic_machine=sh5le-unknown ;; sh64) basic_machine=sh64-unknown ;; sparclite-wrs | simso-wrs) basic_machine=sparclite-wrs os=-vxworks ;; sps7) basic_machine=m68k-bull os=-sysv2 ;; spur) basic_machine=spur-unknown ;; st2000) basic_machine=m68k-tandem ;; stratus) basic_machine=i860-stratus os=-sysv4 ;; sun2) basic_machine=m68000-sun ;; sun2os3) basic_machine=m68000-sun os=-sunos3 ;; sun2os4) basic_machine=m68000-sun os=-sunos4 ;; sun3os3) basic_machine=m68k-sun os=-sunos3 ;; sun3os4) basic_machine=m68k-sun os=-sunos4 ;; sun4os3) basic_machine=sparc-sun os=-sunos3 ;; sun4os4) basic_machine=sparc-sun os=-sunos4 ;; sun4sol2) basic_machine=sparc-sun os=-solaris2 ;; sun3 | sun3-*) basic_machine=m68k-sun ;; sun4) basic_machine=sparc-sun ;; sun386 | sun386i | roadrunner) basic_machine=i386-sun ;; sv1) basic_machine=sv1-cray os=-unicos ;; symmetry) basic_machine=i386-sequent os=-dynix ;; t3e) basic_machine=alphaev5-cray os=-unicos ;; t90) basic_machine=t90-cray os=-unicos ;; tic54x | c54x*) basic_machine=tic54x-unknown os=-coff ;; tic55x | c55x*) basic_machine=tic55x-unknown os=-coff ;; tic6x | c6x*) basic_machine=tic6x-unknown os=-coff ;; tx39) basic_machine=mipstx39-unknown ;; tx39el) basic_machine=mipstx39el-unknown ;; toad1) basic_machine=pdp10-xkl os=-tops20 ;; tower | tower-32) basic_machine=m68k-ncr ;; tpf) basic_machine=s390x-ibm os=-tpf ;; udi29k) basic_machine=a29k-amd os=-udi ;; ultra3) basic_machine=a29k-nyu os=-sym1 ;; v810 | necv810) basic_machine=v810-nec os=-none ;; vaxv) basic_machine=vax-dec os=-sysv ;; vms) basic_machine=vax-dec os=-vms ;; vpp*|vx|vx-*) basic_machine=f301-fujitsu ;; vxworks960) basic_machine=i960-wrs os=-vxworks ;; vxworks68) basic_machine=m68k-wrs os=-vxworks ;; vxworks29k) basic_machine=a29k-wrs os=-vxworks ;; w65*) basic_machine=w65-wdc os=-none ;; w89k-*) basic_machine=hppa1.1-winbond os=-proelf ;; xbox) basic_machine=i686-pc os=-mingw32 ;; xps | xps100) basic_machine=xps100-honeywell ;; ymp) basic_machine=ymp-cray os=-unicos ;; z8k-*-coff) basic_machine=z8k-unknown os=-sim ;; none) basic_machine=none-none os=-none ;; # Here we handle the default manufacturer of certain CPU types. It is in # some cases the only manufacturer, in others, it is the most popular. w89k) basic_machine=hppa1.1-winbond ;; op50n) basic_machine=hppa1.1-oki ;; op60c) basic_machine=hppa1.1-oki ;; romp) basic_machine=romp-ibm ;; mmix) basic_machine=mmix-knuth ;; rs6000) basic_machine=rs6000-ibm ;; vax) basic_machine=vax-dec ;; pdp10) # there are many clones, so DEC is not a safe bet basic_machine=pdp10-unknown ;; pdp11) basic_machine=pdp11-dec ;; we32k) basic_machine=we32k-att ;; sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) basic_machine=sparc-sun ;; cydra) basic_machine=cydra-cydrome ;; orion) basic_machine=orion-highlevel ;; orion105) basic_machine=clipper-highlevel ;; mac | mpw | mac-mpw) basic_machine=m68k-apple ;; pmac | pmac-mpw) basic_machine=powerpc-apple ;; *-unknown) # Make sure to match an already-canonicalized machine name. ;; *) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; esac # Here we canonicalize certain aliases for manufacturers. case $basic_machine in *-digital*) basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` ;; *-commodore*) basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` ;; *) ;; esac # Decode manufacturer-specific aliases for certain operating systems. if [ x"$os" != x"" ] then case $os in # First match some system type aliases # that might get confused with valid system types. # -solaris* is a basic system type, with this one exception. -solaris1 | -solaris1.*) os=`echo $os | sed -e 's|solaris1|sunos4|'` ;; -solaris) os=-solaris2 ;; -svr4*) os=-sysv4 ;; -unixware*) os=-sysv4.2uw ;; -gnu/linux*) os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` ;; # First accept the basic system types. # The portable systems comes first. # Each alternative MUST END IN A *, to match a version number. # -sysv* is not here because it comes later, after sysvr4. -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\ | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ | -aos* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ | -openbsd* | -solidbsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | -chorusos* | -chorusrdb* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \ | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ | -skyos* | -haiku* | -rdos* | -toppers* | -drops*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) case $basic_machine in x86-* | i*86-*) ;; *) os=-nto$os ;; esac ;; -nto-qnx*) ;; -nto*) os=`echo $os | sed -e 's|nto|nto-qnx|'` ;; -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) ;; -mac*) os=`echo $os | sed -e 's|mac|macos|'` ;; -linux-dietlibc) os=-linux-dietlibc ;; -linux*) os=`echo $os | sed -e 's|linux|linux-gnu|'` ;; -sunos5*) os=`echo $os | sed -e 's|sunos5|solaris2|'` ;; -sunos6*) os=`echo $os | sed -e 's|sunos6|solaris3|'` ;; -opened*) os=-openedition ;; -os400*) os=-os400 ;; -wince*) os=-wince ;; -osfrose*) os=-osfrose ;; -osf*) os=-osf ;; -utek*) os=-bsd ;; -dynix*) os=-bsd ;; -acis*) os=-aos ;; -atheos*) os=-atheos ;; -syllable*) os=-syllable ;; -386bsd) os=-bsd ;; -ctix* | -uts*) os=-sysv ;; -nova*) os=-rtmk-nova ;; -ns2 ) os=-nextstep2 ;; -nsk*) os=-nsk ;; # Preserve the version number of sinix5. -sinix5.*) os=`echo $os | sed -e 's|sinix|sysv|'` ;; -sinix*) os=-sysv4 ;; -tpf*) os=-tpf ;; -triton*) os=-sysv3 ;; -oss*) os=-sysv3 ;; -svr4) os=-sysv4 ;; -svr3) os=-sysv3 ;; -sysvr4) os=-sysv4 ;; # This must come after -sysvr4. -sysv*) ;; -ose*) os=-ose ;; -es1800*) os=-ose ;; -xenix) os=-xenix ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) os=-mint ;; -aros*) os=-aros ;; -kaos*) os=-kaos ;; -zvmoe) os=-zvmoe ;; -none) ;; *) # Get rid of the `-' at the beginning of $os. os=`echo $os | sed 's/[^-]*-//'` echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 exit 1 ;; esac else # Here we handle the default operating systems that come with various machines. # The value should be what the vendor currently ships out the door with their # machine or put another way, the most popular os provided with the machine. # Note that if you're going to try to match "-MANUFACTURER" here (say, # "-sun"), then you have to tell the case statement up towards the top # that MANUFACTURER isn't an operating system. Otherwise, code above # will signal an error saying that MANUFACTURER isn't an operating # system, and we'll never get to this point. case $basic_machine in score-*) os=-elf ;; spu-*) os=-elf ;; *-acorn) os=-riscix1.2 ;; arm*-rebel) os=-linux ;; arm*-semi) os=-aout ;; c4x-* | tic4x-*) os=-coff ;; # This must come before the *-dec entry. pdp10-*) os=-tops20 ;; pdp11-*) os=-none ;; *-dec | vax-*) os=-ultrix4.2 ;; m68*-apollo) os=-domain ;; i386-sun) os=-sunos4.0.2 ;; m68000-sun) os=-sunos3 # This also exists in the configure program, but was not the # default. # os=-sunos4 ;; m68*-cisco) os=-aout ;; mep-*) os=-elf ;; mips*-cisco) os=-elf ;; mips*-*) os=-elf ;; or32-*) os=-coff ;; *-tti) # must be before sparc entry or we get the wrong os. os=-sysv3 ;; sparc-* | *-sun) os=-sunos4.1.1 ;; *-be) os=-beos ;; *-haiku) os=-haiku ;; *-ibm) os=-aix ;; *-knuth) os=-mmixware ;; *-wec) os=-proelf ;; *-winbond) os=-proelf ;; *-oki) os=-proelf ;; *-hp) os=-hpux ;; *-hitachi) os=-hiux ;; i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) os=-sysv ;; *-cbm) os=-amigaos ;; *-dg) os=-dgux ;; *-dolphin) os=-sysv3 ;; m68k-ccur) os=-rtu ;; m88k-omron*) os=-luna ;; *-next ) os=-nextstep ;; *-sequent) os=-ptx ;; *-crds) os=-unos ;; *-ns) os=-genix ;; i370-*) os=-mvs ;; *-next) os=-nextstep3 ;; *-gould) os=-sysv ;; *-highlevel) os=-bsd ;; *-encore) os=-bsd ;; *-sgi) os=-irix ;; *-siemens) os=-sysv4 ;; *-masscomp) os=-rtu ;; f30[01]-fujitsu | f700-fujitsu) os=-uxpv ;; *-rom68k) os=-coff ;; *-*bug) os=-coff ;; *-apple) os=-macos ;; *-atari*) os=-mint ;; *) os=-none ;; esac fi # Here we handle the case where we know the os, and the CPU type, but not the # manufacturer. We pick the logical manufacturer. vendor=unknown case $basic_machine in *-unknown) case $os in -riscix*) vendor=acorn ;; -sunos*) vendor=sun ;; -aix*) vendor=ibm ;; -beos*) vendor=be ;; -hpux*) vendor=hp ;; -mpeix*) vendor=hp ;; -hiux*) vendor=hitachi ;; -unos*) vendor=crds ;; -dgux*) vendor=dg ;; -luna*) vendor=omron ;; -genix*) vendor=ns ;; -mvs* | -opened*) vendor=ibm ;; -os400*) vendor=ibm ;; -ptx*) vendor=sequent ;; -tpf*) vendor=ibm ;; -vxsim* | -vxworks* | -windiss*) vendor=wrs ;; -aux*) vendor=apple ;; -hms*) vendor=hitachi ;; -mpw* | -macos*) vendor=apple ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) vendor=atari ;; -vos*) vendor=stratus ;; esac basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` ;; esac echo $basic_machine$os exit # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: tgif-QPL-4.2.5/rmcast/config/missing0000755000076400007640000002403610122646341017134 0ustar williamwilliam#! /bin/sh # Common stub for a few missing GNU programs while installing. # Copyright (C) 1996, 1997, 1999, 2000, 2002 Free Software Foundation, Inc. # Originally by Fran,cois Pinard , 1996. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA # 02111-1307, USA. # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. if test $# -eq 0; then echo 1>&2 "Try \`$0 --help' for more information" exit 1 fi run=: # In the cases where this matters, `missing' is being run in the # srcdir already. if test -f configure.ac; then configure_ac=configure.ac else configure_ac=configure.in fi case "$1" in --run) # Try to run requested program, and just exit if it succeeds. run= shift "$@" && exit 0 ;; esac # If it does not exist, or fails to run (possibly an outdated version), # try to emulate it. case "$1" in -h|--h|--he|--hel|--help) echo "\ $0 [OPTION]... PROGRAM [ARGUMENT]... Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an error status if there is no known handling for PROGRAM. Options: -h, --help display this help and exit -v, --version output version information and exit --run try to run the given command, and emulate it if it fails Supported PROGRAM values: aclocal touch file \`aclocal.m4' autoconf touch file \`configure' autoheader touch file \`config.h.in' automake touch all \`Makefile.in' files bison create \`y.tab.[ch]', if possible, from existing .[ch] flex create \`lex.yy.c', if possible, from existing .c help2man touch the output file lex create \`lex.yy.c', if possible, from existing .c makeinfo touch the output file tar try tar, gnutar, gtar, then tar without non-portable flags yacc create \`y.tab.[ch]', if possible, from existing .[ch]" ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) echo "missing 0.4 - GNU automake" ;; -*) echo 1>&2 "$0: Unknown \`$1' option" echo 1>&2 "Try \`$0 --help' for more information" exit 1 ;; aclocal*) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." touch aclocal.m4 ;; autoconf) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." touch configure ;; autoheader) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`acconfig.h' or \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}` test -z "$files" && files="config.h" touch_files= for f in $files; do case "$f" in *:*) touch_files="$touch_files "`echo "$f" | sed -e 's/^[^:]*://' -e 's/:.*//'`;; *) touch_files="$touch_files $f.in";; esac done touch $touch_files ;; automake*) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." find . -type f -name Makefile.am -print | sed 's/\.am$/.in/' | while read f; do touch "$f"; done ;; autom4te) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is needed, and you do not seem to have it handy on your system. You might have modified some files without having the proper tools for further handling them. You can get \`$1Help2man' as part of \`Autoconf' from any GNU archive site." file=`echo "$*" | sed -n 's/.*--output[ =]*\([^ ]*\).*/\1/p'` test -z "$file" && file=`echo "$*" | sed -n 's/.*-o[ ]*\([^ ]*\).*/\1/p'` if test -f "$file"; then touch $file else test -z "$file" || exec >$file echo "#! /bin/sh" echo "# Created by GNU Automake missing as a replacement of" echo "# $ $@" echo "exit 0" chmod +x $file exit 1 fi ;; bison|yacc) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a \`.y' file. You may need the \`Bison' package in order for those modifications to take effect. You can get \`Bison' from any GNU archive site." rm -f y.tab.c y.tab.h if [ $# -ne 1 ]; then eval LASTARG="\${$#}" case "$LASTARG" in *.y) SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" y.tab.c fi SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" y.tab.h fi ;; esac fi if [ ! -f y.tab.h ]; then echo >y.tab.h fi if [ ! -f y.tab.c ]; then echo 'main() { return 0; }' >y.tab.c fi ;; lex|flex) echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a \`.l' file. You may need the \`Flex' package in order for those modifications to take effect. You can get \`Flex' from any GNU archive site." rm -f lex.yy.c if [ $# -ne 1 ]; then eval LASTARG="\${$#}" case "$LASTARG" in *.l) SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" lex.yy.c fi ;; esac fi if [ ! -f lex.yy.c ]; then echo 'main() { return 0; }' >lex.yy.c fi ;; help2man) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a dependency of a manual page. You may need the \`Help2man' package in order for those modifications to take effect. You can get \`Help2man' from any GNU archive site." file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` if test -z "$file"; then file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'` fi if [ -f "$file" ]; then touch $file else test -z "$file" || exec >$file echo ".ab help2man is required to generate this page" exit 1 fi ;; makeinfo) if test -z "$run" && (makeinfo --version) > /dev/null 2>&1; then # We have makeinfo, but it failed. exit 1 fi echo 1>&2 "\ WARNING: \`$1' is missing on your system. You should only need it if you modified a \`.texi' or \`.texinfo' file, or any other file indirectly affecting the aspect of the manual. The spurious call might also be the consequence of using a buggy \`make' (AIX, DU, IRIX). You might want to install the \`Texinfo' package or the \`GNU make' package. Grab either from any GNU archive site." file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` if test -z "$file"; then file=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'` file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $file` fi touch $file ;; tar) shift if test -n "$run"; then echo 1>&2 "ERROR: \`tar' requires --run" exit 1 fi # We have already tried tar in the generic part. # Look for gnutar/gtar before invocation to avoid ugly error # messages. if (gnutar --version > /dev/null 2>&1); then gnutar "$@" && exit 0 fi if (gtar --version > /dev/null 2>&1); then gtar "$@" && exit 0 fi firstarg="$1" if shift; then case "$firstarg" in *o*) firstarg=`echo "$firstarg" | sed s/o//` tar "$firstarg" "$@" && exit 0 ;; esac case "$firstarg" in *h*) firstarg=`echo "$firstarg" | sed s/h//` tar "$firstarg" "$@" && exit 0 ;; esac fi echo 1>&2 "\ WARNING: I can't seem to be able to run \`tar' with the given arguments. You may want to install GNU tar or Free paxutils, or check the command line arguments." exit 1 ;; *) echo 1>&2 "\ WARNING: \`$1' is needed, and you do not seem to have it handy on your system. You might have modified some files without having the proper tools for further handling them. Check the \`README' file, it often tells you about the needed prerequirements for installing this package. You may also peek at any GNU archive site, in case some other package would contain this missing \`$1' program." exit 1 ;; esac exit 0 tgif-QPL-4.2.5/rmcast/config/depcomp0000755000076400007640000002753310122646341017117 0ustar williamwilliam#! /bin/sh # depcomp - compile a program generating dependencies as side-effects # Copyright 1999, 2000 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA # 02111-1307, USA. # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Originally written by Alexandre Oliva . if test -z "$depmode" || test -z "$source" || test -z "$object"; then echo "depcomp: Variables source, object and depmode must be set" 1>&2 exit 1 fi # `libtool' can also be set to `yes' or `no'. if test -z "$depfile"; then base=`echo "$object" | sed -e 's,^.*/,,' -e 's,\.\([^.]*\)$,.P\1,'` dir=`echo "$object" | sed 's,/.*$,/,'` if test "$dir" = "$object"; then dir= fi # FIXME: should be _deps on DOS. depfile="$dir.deps/$base" fi tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} rm -f "$tmpdepfile" # Some modes work just like other modes, but use different flags. We # parameterize here, but still list the modes in the big case below, # to make depend.m4 easier to write. Note that we *cannot* use a case # here, because this file can only contain one case statement. if test "$depmode" = hp; then # HP compiler uses -M and no extra arg. gccflag=-M depmode=gcc fi if test "$depmode" = dashXmstdout; then # This is just like dashmstdout with a different argument. dashmflag=-xM depmode=dashmstdout fi case "$depmode" in gcc3) ## gcc 3 implements dependency tracking that does exactly what ## we want. Yay! Note: for some reason libtool 1.4 doesn't like ## it if -MD -MP comes after the -MF stuff. Hmm. "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi mv "$tmpdepfile" "$depfile" ;; gcc) ## There are various ways to get dependency output from gcc. Here's ## why we pick this rather obscure method: ## - Don't want to use -MD because we'd like the dependencies to end ## up in a subdir. Having to rename by hand is ugly. ## (We might end up doing this anyway to support other compilers.) ## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like ## -MM, not -M (despite what the docs say). ## - Using -M directly means running the compiler twice (even worse ## than renaming). if test -z "$gccflag"; then gccflag=-MD, fi "$@" -Wp,"$gccflag$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" echo "$object : \\" > "$depfile" alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz ## The second -e expression handles DOS-style file names with drive letters. sed -e 's/^[^:]*: / /' \ -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" ## This next piece of magic avoids the `deleted header file' problem. ## The problem is that when a header file which appears in a .P file ## is deleted, the dependency causes make to die (because there is ## typically no way to rebuild the header). We avoid this by adding ## dummy dependencies for each header file. Too bad gcc doesn't do ## this for us directly. tr ' ' ' ' < "$tmpdepfile" | ## Some versions of gcc put a space before the `:'. On the theory ## that the space means something, we add a space to the output as ## well. ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; hp) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; sgi) if test "$libtool" = yes; then "$@" "-Wp,-MDupdate,$tmpdepfile" else "$@" -MDupdate "$tmpdepfile" fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files echo "$object : \\" > "$depfile" # Clip off the initial element (the dependent). Don't try to be # clever and replace this with sed code, as IRIX sed won't handle # lines with more than a fixed number of characters (4096 in # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; # the IRIX cc adds comments like `#:fec' to the end of the # dependency line. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \ tr ' ' ' ' >> $depfile echo >> $depfile # The second pass generates a dummy entry for each header file. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ >> $depfile else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; aix) # The C for AIX Compiler uses -M and outputs the dependencies # in a .u file. This file always lives in the current directory. # Also, the AIX compiler puts `$object:' at the start of each line; # $object doesn't have directory information. stripped=`echo "$object" | sed -e 's,^.*/,,' -e 's/\(.*\)\..*$/\1/'` tmpdepfile="$stripped.u" outname="$stripped.o" if test "$libtool" = yes; then "$@" -Wc,-M else "$@" -M fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi if test -f "$tmpdepfile"; then # Each line is of the form `foo.o: dependent.h'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile" sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile" else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; tru64) # The Tru64 compiler uses -MD to generate dependencies as a side # effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'. # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put # dependencies in `foo.d' instead, so we check for that too. # Subdirectories are respected. dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` test "x$dir" = "x$object" && dir= base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` if test "$libtool" = yes; then tmpdepfile1="$dir.libs/$base.lo.d" tmpdepfile2="$dir.libs/$base.d" "$@" -Wc,-MD else tmpdepfile1="$dir$base.o.d" tmpdepfile2="$dir$base.d" "$@" -MD fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile1" "$tmpdepfile2" exit $stat fi if test -f "$tmpdepfile1"; then tmpdepfile="$tmpdepfile1" else tmpdepfile="$tmpdepfile2" fi if test -f "$tmpdepfile"; then sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile" # That's a space and a tab in the []. sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile" else echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; #nosideeffect) # This comment above is used by automake to tell side-effect # dependency tracking mechanisms from slower ones. dashmstdout) # Important note: in order to support this mode, a compiler *must* # always write the proprocessed file to stdout, regardless of -o. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # Remove `-o $object'. We will use -o /dev/null later, # however we can't do the remplacement now because # `-o $object' might simply not be used IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done test -z "$dashmflag" && dashmflag=-M "$@" -o /dev/null $dashmflag | sed 's:^[^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" tr ' ' ' ' < "$tmpdepfile" | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; dashXmstdout) # This case only exists to satisfy depend.m4. It is never actually # run, as this mode is specially recognized in the preamble. exit 1 ;; makedepend) "$@" || exit $? # X makedepend shift cleared=no for arg in "$@"; do case $cleared in no) set ""; shift cleared=yes ;; esac case "$arg" in -D*|-I*) set fnord "$@" "$arg"; shift ;; -*) ;; *) set fnord "$@" "$arg"; shift ;; esac done obj_suffix="`echo $object | sed 's/^.*\././'`" touch "$tmpdepfile" ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" sed '1,2d' "$tmpdepfile" | tr ' ' ' ' | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" "$tmpdepfile".bak ;; cpp) # Important note: in order to support this mode, a compiler *must* # always write the proprocessed file to stdout. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # Remove `-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done "$@" -E | sed -n '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' | sed '$ s: \\$::' > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" cat < "$tmpdepfile" >> "$depfile" sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; msvisualcpp) # Important note: in order to support this mode, a compiler *must* # always write the proprocessed file to stdout, regardless of -o, # because we must use -o when running libtool. "$@" || exit $? IFS=" " for arg do case "$arg" in "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") set fnord "$@" shift shift ;; *) set fnord "$@" "$arg" shift shift ;; esac done "$@" -E | sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile" echo " " >> "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile" rm -f "$tmpdepfile" ;; none) exec "$@" ;; *) echo "Unknown depmode $depmode" 1>&2 exit 1 ;; esac exit 0 tgif-QPL-4.2.5/rmcast/config/compile0000755000076400007640000000717311113321725017113 0ustar williamwilliam#! /bin/sh # Wrapper for compilers which do not understand `-c -o'. scriptversion=2005-05-14.22 # Copyright (C) 1999, 2000, 2003, 2004, 2005 Free Software Foundation, Inc. # Written by Tom Tromey . # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # This file is maintained in Automake, please report # bugs to or send patches to # . case $1 in '') echo "$0: No command. Try \`$0 --help' for more information." 1>&2 exit 1; ;; -h | --h*) cat <<\EOF Usage: compile [--help] [--version] PROGRAM [ARGS] Wrapper for compilers which do not understand `-c -o'. Remove `-o dest.o' from ARGS, run PROGRAM with the remaining arguments, and rename the output as expected. If you are trying to build a whole package this is not the right script to run: please start by reading the file `INSTALL'. Report bugs to . EOF exit $? ;; -v | --v*) echo "compile $scriptversion" exit $? ;; esac ofile= cfile= eat= for arg do if test -n "$eat"; then eat= else case $1 in -o) # configure might choose to run compile as `compile cc -o foo foo.c'. # So we strip `-o arg' only if arg is an object. eat=1 case $2 in *.o | *.obj) ofile=$2 ;; *) set x "$@" -o "$2" shift ;; esac ;; *.c) cfile=$1 set x "$@" "$1" shift ;; *) set x "$@" "$1" shift ;; esac fi shift done if test -z "$ofile" || test -z "$cfile"; then # If no `-o' option was seen then we might have been invoked from a # pattern rule where we don't need one. That is ok -- this is a # normal compilation that the losing compiler can handle. If no # `.c' file was seen then we are probably linking. That is also # ok. exec "$@" fi # Name of file we expect compiler to create. cofile=`echo "$cfile" | sed -e 's|^.*/||' -e 's/\.c$/.o/'` # Create the lock directory. # Note: use `[/.-]' here to ensure that we don't use the same name # that we are using for the .o file. Also, base the name on the expected # object file name, since that is what matters with a parallel build. lockdir=`echo "$cofile" | sed -e 's|[/.-]|_|g'`.d while true; do if mkdir "$lockdir" >/dev/null 2>&1; then break fi sleep 1 done # FIXME: race condition here if user kills between mkdir and trap. trap "rmdir '$lockdir'; exit 1" 1 2 15 # Run the compile. "$@" ret=$? if test -f "$cofile"; then mv "$cofile" "$ofile" elif test -f "${cofile}bj"; then mv "${cofile}bj" "$ofile" fi rmdir "$lockdir" exit $ret # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: tgif-QPL-4.2.5/rmcast/config/ltmain.sh0000644000076400007640000060646711222706506017375 0ustar williamwilliam# ltmain.sh - Provide generalized library-building support services. # NOTE: Changing this file will not affect anything until you rerun configure. # # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, # 2007, 2008 Free Software Foundation, Inc. # Originally by Gordon Matzigkeit , 1996 # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. basename="s,^.*/,,g" # Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh # is ksh but when the shell is invoked as "sh" and the current value of # the _XPG environment variable is not equal to 1 (one), the special # positional parameter $0, within a function call, is the name of the # function. progpath="$0" # The name of this program: progname=`echo "$progpath" | $SED $basename` modename="$progname" # Global variables: EXIT_SUCCESS=0 EXIT_FAILURE=1 PROGRAM=ltmain.sh PACKAGE=libtool VERSION="1.5.26 Debian 1.5.26-1ubuntu1" TIMESTAMP=" (1.1220.2.493 2008/02/01 16:58:18)" # Be Bourne compatible (taken from Autoconf:_AS_BOURNE_COMPATIBLE). if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac fi BIN_SH=xpg4; export BIN_SH # for Tru64 DUALCASE=1; export DUALCASE # for MKS sh # Check that we have a working $echo. if test "X$1" = X--no-reexec; then # Discard the --no-reexec flag, and continue. shift elif test "X$1" = X--fallback-echo; then # Avoid inline document here, it may be left over : elif test "X`($echo '\t') 2>/dev/null`" = 'X\t'; then # Yippee, $echo works! : else # Restart under the correct shell, and then maybe $echo will work. exec $SHELL "$progpath" --no-reexec ${1+"$@"} fi if test "X$1" = X--fallback-echo; then # used as fallback echo shift cat <&2 $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 exit $EXIT_FAILURE fi # Global variables. mode=$default_mode nonopt= prev= prevopt= run= show="$echo" show_help= execute_dlfiles= duplicate_deps=no preserve_args= lo2o="s/\\.lo\$/.${objext}/" o2lo="s/\\.${objext}\$/.lo/" extracted_archives= extracted_serial=0 ##################################### # Shell function definitions: # This seems to be the best place for them # func_mktempdir [string] # Make a temporary directory that won't clash with other running # libtool processes, and avoids race conditions if possible. If # given, STRING is the basename for that directory. func_mktempdir () { my_template="${TMPDIR-/tmp}/${1-$progname}" if test "$run" = ":"; then # Return a directory name, but don't create it in dry-run mode my_tmpdir="${my_template}-$$" else # If mktemp works, use that first and foremost my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` if test ! -d "$my_tmpdir"; then # Failing that, at least try and use $RANDOM to avoid a race my_tmpdir="${my_template}-${RANDOM-0}$$" save_mktempdir_umask=`umask` umask 0077 $mkdir "$my_tmpdir" umask $save_mktempdir_umask fi # If we're not in dry-run mode, bomb out on failure test -d "$my_tmpdir" || { $echo "cannot create temporary directory \`$my_tmpdir'" 1>&2 exit $EXIT_FAILURE } fi $echo "X$my_tmpdir" | $Xsed } # func_win32_libid arg # return the library type of file 'arg' # # Need a lot of goo to handle *both* DLLs and import libs # Has to be a shell function in order to 'eat' the argument # that is supplied when $file_magic_command is called. func_win32_libid () { win32_libid_type="unknown" win32_fileres=`file -L $1 2>/dev/null` case $win32_fileres in *ar\ archive\ import\ library*) # definitely import win32_libid_type="x86 archive import" ;; *ar\ archive*) # could be an import, or static if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | \ $EGREP -e 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then win32_nmres=`eval $NM -f posix -A $1 | \ $SED -n -e '1,100{ / I /{ s,.*,import, p q } }'` case $win32_nmres in import*) win32_libid_type="x86 archive import";; *) win32_libid_type="x86 archive static";; esac fi ;; *DLL*) win32_libid_type="x86 DLL" ;; *executable*) # but shell scripts are "executable" too... case $win32_fileres in *MS\ Windows\ PE\ Intel*) win32_libid_type="x86 DLL" ;; esac ;; esac $echo $win32_libid_type } # func_infer_tag arg # Infer tagged configuration to use if any are available and # if one wasn't chosen via the "--tag" command line option. # Only attempt this if the compiler in the base compile # command doesn't match the default compiler. # arg is usually of the form 'gcc ...' func_infer_tag () { if test -n "$available_tags" && test -z "$tagname"; then CC_quoted= for arg in $CC; do case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac CC_quoted="$CC_quoted $arg" done case $@ in # Blanks in the command may have been stripped by the calling shell, # but not from the CC environment variable when configure was run. " $CC "* | "$CC "* | " `$echo $CC` "* | "`$echo $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$echo $CC_quoted` "* | "`$echo $CC_quoted` "*) ;; # Blanks at the start of $base_compile will cause this to fail # if we don't check for them as well. *) for z in $available_tags; do if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then # Evaluate the configuration. eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" CC_quoted= for arg in $CC; do # Double-quote args containing other shell metacharacters. case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac CC_quoted="$CC_quoted $arg" done case "$@ " in " $CC "* | "$CC "* | " `$echo $CC` "* | "`$echo $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$echo $CC_quoted` "* | "`$echo $CC_quoted` "*) # The compiler in the base compile command matches # the one in the tagged configuration. # Assume this is the tagged configuration we want. tagname=$z break ;; esac fi done # If $tagname still isn't set, then no tagged configuration # was found and let the user know that the "--tag" command # line option must be used. if test -z "$tagname"; then $echo "$modename: unable to infer tagged configuration" $echo "$modename: specify a tag with \`--tag'" 1>&2 exit $EXIT_FAILURE # else # $echo "$modename: using $tagname tagged configuration" fi ;; esac fi } # func_extract_an_archive dir oldlib func_extract_an_archive () { f_ex_an_ar_dir="$1"; shift f_ex_an_ar_oldlib="$1" $show "(cd $f_ex_an_ar_dir && $AR x $f_ex_an_ar_oldlib)" $run eval "(cd \$f_ex_an_ar_dir && $AR x \$f_ex_an_ar_oldlib)" || exit $? if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then : else $echo "$modename: ERROR: object name conflicts: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" 1>&2 exit $EXIT_FAILURE fi } # func_extract_archives gentop oldlib ... func_extract_archives () { my_gentop="$1"; shift my_oldlibs=${1+"$@"} my_oldobjs="" my_xlib="" my_xabs="" my_xdir="" my_status="" $show "${rm}r $my_gentop" $run ${rm}r "$my_gentop" $show "$mkdir $my_gentop" $run $mkdir "$my_gentop" my_status=$? if test "$my_status" -ne 0 && test ! -d "$my_gentop"; then exit $my_status fi for my_xlib in $my_oldlibs; do # Extract the objects. case $my_xlib in [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; *) my_xabs=`pwd`"/$my_xlib" ;; esac my_xlib=`$echo "X$my_xlib" | $Xsed -e 's%^.*/%%'` my_xlib_u=$my_xlib while :; do case " $extracted_archives " in *" $my_xlib_u "*) extracted_serial=`expr $extracted_serial + 1` my_xlib_u=lt$extracted_serial-$my_xlib ;; *) break ;; esac done extracted_archives="$extracted_archives $my_xlib_u" my_xdir="$my_gentop/$my_xlib_u" $show "${rm}r $my_xdir" $run ${rm}r "$my_xdir" $show "$mkdir $my_xdir" $run $mkdir "$my_xdir" exit_status=$? if test "$exit_status" -ne 0 && test ! -d "$my_xdir"; then exit $exit_status fi case $host in *-darwin*) $show "Extracting $my_xabs" # Do not bother doing anything if just a dry run if test -z "$run"; then darwin_orig_dir=`pwd` cd $my_xdir || exit $? darwin_archive=$my_xabs darwin_curdir=`pwd` darwin_base_archive=`$echo "X$darwin_archive" | $Xsed -e 's%^.*/%%'` darwin_arches=`lipo -info "$darwin_archive" 2>/dev/null | $EGREP Architectures 2>/dev/null` if test -n "$darwin_arches"; then darwin_arches=`echo "$darwin_arches" | $SED -e 's/.*are://'` darwin_arch= $show "$darwin_base_archive has multiple architectures $darwin_arches" for darwin_arch in $darwin_arches ; do mkdir -p "unfat-$$/${darwin_base_archive}-${darwin_arch}" lipo -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" func_extract_an_archive "`pwd`" "${darwin_base_archive}" cd "$darwin_curdir" $rm "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" done # $darwin_arches ## Okay now we have a bunch of thin objects, gotta fatten them up :) darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print| xargs basename | sort -u | $NL2SP` darwin_file= darwin_files= for darwin_file in $darwin_filelist; do darwin_files=`find unfat-$$ -name $darwin_file -print | $NL2SP` lipo -create -output "$darwin_file" $darwin_files done # $darwin_filelist ${rm}r unfat-$$ cd "$darwin_orig_dir" else cd "$darwin_orig_dir" func_extract_an_archive "$my_xdir" "$my_xabs" fi # $darwin_arches fi # $run ;; *) func_extract_an_archive "$my_xdir" "$my_xabs" ;; esac my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP` done func_extract_archives_result="$my_oldobjs" } # End of Shell function definitions ##################################### # Darwin sucks eval std_shrext=\"$shrext_cmds\" disable_libs=no # Parse our command line options once, thoroughly. while test "$#" -gt 0 do arg="$1" shift case $arg in -*=*) optarg=`$echo "X$arg" | $Xsed -e 's/[-_a-zA-Z0-9]*=//'` ;; *) optarg= ;; esac # If the previous option needs an argument, assign it. if test -n "$prev"; then case $prev in execute_dlfiles) execute_dlfiles="$execute_dlfiles $arg" ;; tag) tagname="$arg" preserve_args="${preserve_args}=$arg" # Check whether tagname contains only valid characters case $tagname in *[!-_A-Za-z0-9,/]*) $echo "$progname: invalid tag name: $tagname" 1>&2 exit $EXIT_FAILURE ;; esac case $tagname in CC) # Don't test for the "default" C tag, as we know, it's there, but # not specially marked. ;; *) if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "$progpath" > /dev/null; then taglist="$taglist $tagname" # Evaluate the configuration. eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$tagname'$/,/^# ### END LIBTOOL TAG CONFIG: '$tagname'$/p' < $progpath`" else $echo "$progname: ignoring unknown tag $tagname" 1>&2 fi ;; esac ;; *) eval "$prev=\$arg" ;; esac prev= prevopt= continue fi # Have we seen a non-optional argument yet? case $arg in --help) show_help=yes ;; --version) echo "\ $PROGRAM (GNU $PACKAGE) $VERSION$TIMESTAMP Copyright (C) 2008 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." exit $? ;; --config) ${SED} -e '1,/^# ### BEGIN LIBTOOL CONFIG/d' -e '/^# ### END LIBTOOL CONFIG/,$d' $progpath # Now print the configurations for the tags. for tagname in $taglist; do ${SED} -n -e "/^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$/,/^# ### END LIBTOOL TAG CONFIG: $tagname$/p" < "$progpath" done exit $? ;; --debug) $echo "$progname: enabling shell trace mode" set -x preserve_args="$preserve_args $arg" ;; --dry-run | -n) run=: ;; --features) $echo "host: $host" if test "$build_libtool_libs" = yes; then $echo "enable shared libraries" else $echo "disable shared libraries" fi if test "$build_old_libs" = yes; then $echo "enable static libraries" else $echo "disable static libraries" fi exit $? ;; --finish) mode="finish" ;; --mode) prevopt="--mode" prev=mode ;; --mode=*) mode="$optarg" ;; --preserve-dup-deps) duplicate_deps="yes" ;; --quiet | --silent) show=: preserve_args="$preserve_args $arg" ;; --tag) prevopt="--tag" prev=tag preserve_args="$preserve_args --tag" ;; --tag=*) set tag "$optarg" ${1+"$@"} shift prev=tag preserve_args="$preserve_args --tag" ;; -dlopen) prevopt="-dlopen" prev=execute_dlfiles ;; -*) $echo "$modename: unrecognized option \`$arg'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; *) nonopt="$arg" break ;; esac done if test -n "$prevopt"; then $echo "$modename: option \`$prevopt' requires an argument" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi case $disable_libs in no) ;; shared) build_libtool_libs=no build_old_libs=yes ;; static) build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` ;; esac # If this variable is set in any of the actions, the command in it # will be execed at the end. This prevents here-documents from being # left over by shells. exec_cmd= if test -z "$show_help"; then # Infer the operation mode. if test -z "$mode"; then $echo "*** Warning: inferring the mode of operation is deprecated." 1>&2 $echo "*** Future versions of Libtool will require --mode=MODE be specified." 1>&2 case $nonopt in *cc | cc* | *++ | gcc* | *-gcc* | g++* | xlc*) mode=link for arg do case $arg in -c) mode=compile break ;; esac done ;; *db | *dbx | *strace | *truss) mode=execute ;; *install*|cp|mv) mode=install ;; *rm) mode=uninstall ;; *) # If we have no mode, but dlfiles were specified, then do execute mode. test -n "$execute_dlfiles" && mode=execute # Just use the default operation mode. if test -z "$mode"; then if test -n "$nonopt"; then $echo "$modename: warning: cannot infer operation mode from \`$nonopt'" 1>&2 else $echo "$modename: warning: cannot infer operation mode without MODE-ARGS" 1>&2 fi fi ;; esac fi # Only execute mode is allowed to have -dlopen flags. if test -n "$execute_dlfiles" && test "$mode" != execute; then $echo "$modename: unrecognized option \`-dlopen'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Change the help message to a mode-specific one. generic_help="$help" help="Try \`$modename --help --mode=$mode' for more information." # These modes are in order of execution frequency so that they run quickly. case $mode in # libtool compile mode compile) modename="$modename: compile" # Get the compilation command and the source file. base_compile= srcfile="$nonopt" # always keep a non-empty value in "srcfile" suppress_opt=yes suppress_output= arg_mode=normal libobj= later= for arg do case $arg_mode in arg ) # do not "continue". Instead, add this to base_compile lastarg="$arg" arg_mode=normal ;; target ) libobj="$arg" arg_mode=normal continue ;; normal ) # Accept any command-line options. case $arg in -o) if test -n "$libobj" ; then $echo "$modename: you cannot specify \`-o' more than once" 1>&2 exit $EXIT_FAILURE fi arg_mode=target continue ;; -static | -prefer-pic | -prefer-non-pic) later="$later $arg" continue ;; -no-suppress) suppress_opt=no continue ;; -Xcompiler) arg_mode=arg # the next one goes into the "base_compile" arg list continue # The current "srcfile" will either be retained or ;; # replaced later. I would guess that would be a bug. -Wc,*) args=`$echo "X$arg" | $Xsed -e "s/^-Wc,//"` lastarg= save_ifs="$IFS"; IFS=',' for arg in $args; do IFS="$save_ifs" # Double-quote args containing other shell metacharacters. # Many Bourne shells cannot handle close brackets correctly # in scan sets, so we specify it separately. case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac lastarg="$lastarg $arg" done IFS="$save_ifs" lastarg=`$echo "X$lastarg" | $Xsed -e "s/^ //"` # Add the arguments to base_compile. base_compile="$base_compile $lastarg" continue ;; * ) # Accept the current argument as the source file. # The previous "srcfile" becomes the current argument. # lastarg="$srcfile" srcfile="$arg" ;; esac # case $arg ;; esac # case $arg_mode # Aesthetically quote the previous argument. lastarg=`$echo "X$lastarg" | $Xsed -e "$sed_quote_subst"` case $lastarg in # Double-quote args containing other shell metacharacters. # Many Bourne shells cannot handle close brackets correctly # in scan sets, and some SunOS ksh mistreat backslash-escaping # in scan sets (worked around with variable expansion), # and furthermore cannot handle '|' '&' '(' ')' in scan sets # at all, so we specify them separately. *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") lastarg="\"$lastarg\"" ;; esac base_compile="$base_compile $lastarg" done # for arg case $arg_mode in arg) $echo "$modename: you must specify an argument for -Xcompile" exit $EXIT_FAILURE ;; target) $echo "$modename: you must specify a target with \`-o'" 1>&2 exit $EXIT_FAILURE ;; *) # Get the name of the library object. [ -z "$libobj" ] && libobj=`$echo "X$srcfile" | $Xsed -e 's%^.*/%%'` ;; esac # Recognize several different file suffixes. # If the user specifies -o file.o, it is replaced with file.lo xform='[cCFSifmso]' case $libobj in *.ada) xform=ada ;; *.adb) xform=adb ;; *.ads) xform=ads ;; *.asm) xform=asm ;; *.c++) xform=c++ ;; *.cc) xform=cc ;; *.ii) xform=ii ;; *.class) xform=class ;; *.cpp) xform=cpp ;; *.cxx) xform=cxx ;; *.[fF][09]?) xform=[fF][09]. ;; *.for) xform=for ;; *.java) xform=java ;; *.obj) xform=obj ;; *.sx) xform=sx ;; esac libobj=`$echo "X$libobj" | $Xsed -e "s/\.$xform$/.lo/"` case $libobj in *.lo) obj=`$echo "X$libobj" | $Xsed -e "$lo2o"` ;; *) $echo "$modename: cannot determine name of library object from \`$libobj'" 1>&2 exit $EXIT_FAILURE ;; esac func_infer_tag $base_compile for arg in $later; do case $arg in -static) build_old_libs=yes continue ;; -prefer-pic) pic_mode=yes continue ;; -prefer-non-pic) pic_mode=no continue ;; esac done qlibobj=`$echo "X$libobj" | $Xsed -e "$sed_quote_subst"` case $qlibobj in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") qlibobj="\"$qlibobj\"" ;; esac test "X$libobj" != "X$qlibobj" \ && $echo "X$libobj" | grep '[]~#^*{};<>?"'"'"' &()|`$[]' \ && $echo "$modename: libobj name \`$libobj' may not contain shell special characters." objname=`$echo "X$obj" | $Xsed -e 's%^.*/%%'` xdir=`$echo "X$obj" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$obj"; then xdir= else xdir=$xdir/ fi lobj=${xdir}$objdir/$objname if test -z "$base_compile"; then $echo "$modename: you must specify a compilation command" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Delete any leftover library objects. if test "$build_old_libs" = yes; then removelist="$obj $lobj $libobj ${libobj}T" else removelist="$lobj $libobj ${libobj}T" fi $run $rm $removelist trap "$run $rm $removelist; exit $EXIT_FAILURE" 1 2 15 # On Cygwin there's no "real" PIC flag so we must build both object types case $host_os in cygwin* | mingw* | pw32* | os2*) pic_mode=default ;; esac if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then # non-PIC code in shared libraries is not supported pic_mode=default fi # Calculate the filename of the output object if compiler does # not support -o with -c if test "$compiler_c_o" = no; then output_obj=`$echo "X$srcfile" | $Xsed -e 's%^.*/%%' -e 's%\.[^.]*$%%'`.${objext} lockfile="$output_obj.lock" removelist="$removelist $output_obj $lockfile" trap "$run $rm $removelist; exit $EXIT_FAILURE" 1 2 15 else output_obj= need_locks=no lockfile= fi # Lock this critical section if it is needed # We use this script file to make the link, it avoids creating a new file if test "$need_locks" = yes; then until $run ln "$progpath" "$lockfile" 2>/dev/null; do $show "Waiting for $lockfile to be removed" sleep 2 done elif test "$need_locks" = warn; then if test -f "$lockfile"; then $echo "\ *** ERROR, $lockfile exists and contains: `cat $lockfile 2>/dev/null` This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $run $rm $removelist exit $EXIT_FAILURE fi $echo "$srcfile" > "$lockfile" fi if test -n "$fix_srcfile_path"; then eval srcfile=\"$fix_srcfile_path\" fi qsrcfile=`$echo "X$srcfile" | $Xsed -e "$sed_quote_subst"` case $qsrcfile in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") qsrcfile="\"$qsrcfile\"" ;; esac $run $rm "$libobj" "${libobj}T" # Create a libtool object file (analogous to a ".la" file), # but don't create it if we're doing a dry run. test -z "$run" && cat > ${libobj}T </dev/null`" != "X$srcfile"; then $echo "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $run $rm $removelist exit $EXIT_FAILURE fi # Just move the object if needed, then go on to compile the next one if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then $show "$mv $output_obj $lobj" if $run $mv $output_obj $lobj; then : else error=$? $run $rm $removelist exit $error fi fi # Append the name of the PIC object to the libtool object file. test -z "$run" && cat >> ${libobj}T <> ${libobj}T </dev/null`" != "X$srcfile"; then $echo "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $run $rm $removelist exit $EXIT_FAILURE fi # Just move the object if needed if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then $show "$mv $output_obj $obj" if $run $mv $output_obj $obj; then : else error=$? $run $rm $removelist exit $error fi fi # Append the name of the non-PIC object the libtool object file. # Only append if the libtool object file exists. test -z "$run" && cat >> ${libobj}T <> ${libobj}T <&2 fi if test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; -static) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=built ;; -static-libtool-libs) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; esac build_libtool_libs=no build_old_libs=yes break ;; esac done # See if our shared archives depend on static archives. test -n "$old_archive_from_new_cmds" && build_old_libs=yes # Go through the arguments, transforming them on the way. while test "$#" -gt 0; do arg="$1" shift case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") qarg=\"`$echo "X$arg" | $Xsed -e "$sed_quote_subst"`\" ### testsuite: skip nested quoting test ;; *) qarg=$arg ;; esac libtool_args="$libtool_args $qarg" # If the previous option needs an argument, assign it. if test -n "$prev"; then case $prev in output) compile_command="$compile_command @OUTPUT@" finalize_command="$finalize_command @OUTPUT@" ;; esac case $prev in dlfiles|dlprefiles) if test "$preload" = no; then # Add the symbol object into the linking commands. compile_command="$compile_command @SYMFILE@" finalize_command="$finalize_command @SYMFILE@" preload=yes fi case $arg in *.la | *.lo) ;; # We handle these cases below. force) if test "$dlself" = no; then dlself=needless export_dynamic=yes fi prev= continue ;; self) if test "$prev" = dlprefiles; then dlself=yes elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then dlself=yes else dlself=needless export_dynamic=yes fi prev= continue ;; *) if test "$prev" = dlfiles; then dlfiles="$dlfiles $arg" else dlprefiles="$dlprefiles $arg" fi prev= continue ;; esac ;; expsyms) export_symbols="$arg" if test ! -f "$arg"; then $echo "$modename: symbol file \`$arg' does not exist" exit $EXIT_FAILURE fi prev= continue ;; expsyms_regex) export_symbols_regex="$arg" prev= continue ;; inst_prefix) inst_prefix_dir="$arg" prev= continue ;; precious_regex) precious_files_regex="$arg" prev= continue ;; release) release="-$arg" prev= continue ;; objectlist) if test -f "$arg"; then save_arg=$arg moreargs= for fil in `cat $save_arg` do # moreargs="$moreargs $fil" arg=$fil # A libtool-controlled object. # Check to see that this really is a libtool object. if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then pic_object= non_pic_object= # Read the .lo file # If there is no directory component, then add one. case $arg in */* | *\\*) . $arg ;; *) . ./$arg ;; esac if test -z "$pic_object" || \ test -z "$non_pic_object" || test "$pic_object" = none && \ test "$non_pic_object" = none; then $echo "$modename: cannot find name of object for \`$arg'" 1>&2 exit $EXIT_FAILURE fi # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi if test "$pic_object" != none; then # Prepend the subdirectory the object is found in. pic_object="$xdir$pic_object" if test "$prev" = dlfiles; then if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then dlfiles="$dlfiles $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. dlprefiles="$dlprefiles $pic_object" prev= fi # A PIC object. libobjs="$libobjs $pic_object" arg="$pic_object" fi # Non-PIC object. if test "$non_pic_object" != none; then # Prepend the subdirectory the object is found in. non_pic_object="$xdir$non_pic_object" # A standard non-PIC object non_pic_objects="$non_pic_objects $non_pic_object" if test -z "$pic_object" || test "$pic_object" = none ; then arg="$non_pic_object" fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object="$pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi else # Only an error if not doing a dry-run. if test -z "$run"; then $echo "$modename: \`$arg' is not a valid libtool object" 1>&2 exit $EXIT_FAILURE else # Dry-run case. # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi pic_object=`$echo "X${xdir}${objdir}/${arg}" | $Xsed -e "$lo2o"` non_pic_object=`$echo "X${xdir}${arg}" | $Xsed -e "$lo2o"` libobjs="$libobjs $pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi fi done else $echo "$modename: link input file \`$save_arg' does not exist" exit $EXIT_FAILURE fi arg=$save_arg prev= continue ;; rpath | xrpath) # We need an absolute path. case $arg in [\\/]* | [A-Za-z]:[\\/]*) ;; *) $echo "$modename: only absolute run-paths are allowed" 1>&2 exit $EXIT_FAILURE ;; esac if test "$prev" = rpath; then case "$rpath " in *" $arg "*) ;; *) rpath="$rpath $arg" ;; esac else case "$xrpath " in *" $arg "*) ;; *) xrpath="$xrpath $arg" ;; esac fi prev= continue ;; xcompiler) compiler_flags="$compiler_flags $qarg" prev= compile_command="$compile_command $qarg" finalize_command="$finalize_command $qarg" continue ;; xlinker) linker_flags="$linker_flags $qarg" compiler_flags="$compiler_flags $wl$qarg" prev= compile_command="$compile_command $wl$qarg" finalize_command="$finalize_command $wl$qarg" continue ;; xcclinker) linker_flags="$linker_flags $qarg" compiler_flags="$compiler_flags $qarg" prev= compile_command="$compile_command $qarg" finalize_command="$finalize_command $qarg" continue ;; shrext) shrext_cmds="$arg" prev= continue ;; darwin_framework|darwin_framework_skip) test "$prev" = "darwin_framework" && compiler_flags="$compiler_flags $arg" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" prev= continue ;; *) eval "$prev=\"\$arg\"" prev= continue ;; esac fi # test -n "$prev" prevarg="$arg" case $arg in -all-static) if test -n "$link_static_flag"; then compile_command="$compile_command $link_static_flag" finalize_command="$finalize_command $link_static_flag" fi continue ;; -allow-undefined) # FIXME: remove this flag sometime in the future. $echo "$modename: \`-allow-undefined' is deprecated because it is the default" 1>&2 continue ;; -avoid-version) avoid_version=yes continue ;; -dlopen) prev=dlfiles continue ;; -dlpreopen) prev=dlprefiles continue ;; -export-dynamic) export_dynamic=yes continue ;; -export-symbols | -export-symbols-regex) if test -n "$export_symbols" || test -n "$export_symbols_regex"; then $echo "$modename: more than one -exported-symbols argument is not allowed" exit $EXIT_FAILURE fi if test "X$arg" = "X-export-symbols"; then prev=expsyms else prev=expsyms_regex fi continue ;; -framework|-arch|-isysroot) case " $CC " in *" ${arg} ${1} "* | *" ${arg} ${1} "*) prev=darwin_framework_skip ;; *) compiler_flags="$compiler_flags $arg" prev=darwin_framework ;; esac compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" continue ;; -inst-prefix-dir) prev=inst_prefix continue ;; # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* # so, if we see these flags be careful not to treat them like -L -L[A-Z][A-Z]*:*) case $with_gcc/$host in no/*-*-irix* | /*-*-irix*) compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" ;; esac continue ;; -L*) dir=`$echo "X$arg" | $Xsed -e 's/^-L//'` # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) absdir=`cd "$dir" && pwd` if test -z "$absdir"; then $echo "$modename: cannot determine absolute directory name of \`$dir'" 1>&2 absdir="$dir" notinst_path="$notinst_path $dir" fi dir="$absdir" ;; esac case "$deplibs " in *" -L$dir "*) ;; *) deplibs="$deplibs -L$dir" lib_search_path="$lib_search_path $dir" ;; esac case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) testbindir=`$echo "X$dir" | $Xsed -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$dir:"*) ;; *) dllsearchpath="$dllsearchpath:$dir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; *) dllsearchpath="$dllsearchpath:$testbindir";; esac ;; esac continue ;; -l*) if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos*) # These systems don't actually have a C or math library (as such) continue ;; *-*-os2*) # These systems don't actually have a C library (as such) test "X$arg" = "X-lc" && continue ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc due to us having libc/libc_r. test "X$arg" = "X-lc" && continue ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C and math libraries are in the System framework deplibs="$deplibs -framework System" continue ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype test "X$arg" = "X-lc" && continue ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work test "X$arg" = "X-lc" && continue ;; esac elif test "X$arg" = "X-lc_r"; then case $host in *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc_r directly, use -pthread flag. continue ;; esac fi deplibs="$deplibs $arg" continue ;; # Tru64 UNIX uses -model [arg] to determine the layout of C++ # classes, name mangling, and exception handling. -model) compile_command="$compile_command $arg" compiler_flags="$compiler_flags $arg" finalize_command="$finalize_command $arg" prev=xcompiler continue ;; -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) compiler_flags="$compiler_flags $arg" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" continue ;; -multi_module) single_module="${wl}-multi_module" continue ;; -module) module=yes continue ;; # -64, -mips[0-9] enable 64-bit mode on the SGI compiler # -r[0-9][0-9]* specifies the processor on the SGI compiler # -xarch=*, -xtarget=* enable 64-bit mode on the Sun compiler # +DA*, +DD* enable 64-bit mode on the HP compiler # -q* pass through compiler args for the IBM compiler # -m* pass through architecture-specific compiler args for GCC # -m*, -t[45]*, -txscale* pass through architecture-specific # compiler args for GCC # -p, -pg, --coverage, -fprofile-* pass through profiling flag for GCC # -F/path gives path to uninstalled frameworks, gcc on darwin # @file GCC response files -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" compiler_flags="$compiler_flags $arg" continue ;; -shrext) prev=shrext continue ;; -no-fast-install) fast_install=no continue ;; -no-install) case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin*) # The PATH hackery in wrapper scripts is required on Windows # and Darwin in order for the loader to find any dlls it needs. $echo "$modename: warning: \`-no-install' is ignored for $host" 1>&2 $echo "$modename: warning: assuming \`-no-fast-install' instead" 1>&2 fast_install=no ;; *) no_install=yes ;; esac continue ;; -no-undefined) allow_undefined=no continue ;; -objectlist) prev=objectlist continue ;; -o) prev=output ;; -precious-files-regex) prev=precious_regex continue ;; -release) prev=release continue ;; -rpath) prev=rpath continue ;; -R) prev=xrpath continue ;; -R*) dir=`$echo "X$arg" | $Xsed -e 's/^-R//'` # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) $echo "$modename: only absolute run-paths are allowed" 1>&2 exit $EXIT_FAILURE ;; esac case "$xrpath " in *" $dir "*) ;; *) xrpath="$xrpath $dir" ;; esac continue ;; -static | -static-libtool-libs) # The effects of -static are defined in a previous loop. # We used to do the same as -all-static on platforms that # didn't have a PIC flag, but the assumption that the effects # would be equivalent was wrong. It would break on at least # Digital Unix and AIX. continue ;; -thread-safe) thread_safe=yes continue ;; -version-info) prev=vinfo continue ;; -version-number) prev=vinfo vinfo_number=yes continue ;; -Wc,*) args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wc,//'` arg= save_ifs="$IFS"; IFS=',' for flag in $args; do IFS="$save_ifs" case $flag in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") flag="\"$flag\"" ;; esac arg="$arg $wl$flag" compiler_flags="$compiler_flags $flag" done IFS="$save_ifs" arg=`$echo "X$arg" | $Xsed -e "s/^ //"` ;; -Wl,*) args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wl,//'` arg= save_ifs="$IFS"; IFS=',' for flag in $args; do IFS="$save_ifs" case $flag in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") flag="\"$flag\"" ;; esac arg="$arg $wl$flag" compiler_flags="$compiler_flags $wl$flag" linker_flags="$linker_flags $flag" done IFS="$save_ifs" arg=`$echo "X$arg" | $Xsed -e "s/^ //"` ;; -Xcompiler) prev=xcompiler continue ;; -Xlinker) prev=xlinker continue ;; -XCClinker) prev=xcclinker continue ;; # Some other compiler flag. -* | +*) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac ;; *.$objext) # A standard object. objs="$objs $arg" ;; *.lo) # A libtool-controlled object. # Check to see that this really is a libtool object. if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then pic_object= non_pic_object= # Read the .lo file # If there is no directory component, then add one. case $arg in */* | *\\*) . $arg ;; *) . ./$arg ;; esac if test -z "$pic_object" || \ test -z "$non_pic_object" || test "$pic_object" = none && \ test "$non_pic_object" = none; then $echo "$modename: cannot find name of object for \`$arg'" 1>&2 exit $EXIT_FAILURE fi # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi if test "$pic_object" != none; then # Prepend the subdirectory the object is found in. pic_object="$xdir$pic_object" if test "$prev" = dlfiles; then if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then dlfiles="$dlfiles $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. dlprefiles="$dlprefiles $pic_object" prev= fi # A PIC object. libobjs="$libobjs $pic_object" arg="$pic_object" fi # Non-PIC object. if test "$non_pic_object" != none; then # Prepend the subdirectory the object is found in. non_pic_object="$xdir$non_pic_object" # A standard non-PIC object non_pic_objects="$non_pic_objects $non_pic_object" if test -z "$pic_object" || test "$pic_object" = none ; then arg="$non_pic_object" fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object="$pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi else # Only an error if not doing a dry-run. if test -z "$run"; then $echo "$modename: \`$arg' is not a valid libtool object" 1>&2 exit $EXIT_FAILURE else # Dry-run case. # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi pic_object=`$echo "X${xdir}${objdir}/${arg}" | $Xsed -e "$lo2o"` non_pic_object=`$echo "X${xdir}${arg}" | $Xsed -e "$lo2o"` libobjs="$libobjs $pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi fi ;; *.$libext) # An archive. deplibs="$deplibs $arg" old_deplibs="$old_deplibs $arg" continue ;; *.la) # A libtool-controlled library. if test "$prev" = dlfiles; then # This library was specified with -dlopen. dlfiles="$dlfiles $arg" prev= elif test "$prev" = dlprefiles; then # The library was specified with -dlpreopen. dlprefiles="$dlprefiles $arg" prev= else deplibs="$deplibs $arg" fi continue ;; # Some other compiler argument. *) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac ;; esac # arg # Now actually substitute the argument into the commands. if test -n "$arg"; then compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" fi done # argument parsing loop if test -n "$prev"; then $echo "$modename: the \`$prevarg' option requires an argument" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then eval arg=\"$export_dynamic_flag_spec\" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" fi oldlibs= # calculate the name of the file, without its directory outputname=`$echo "X$output" | $Xsed -e 's%^.*/%%'` libobjs_save="$libobjs" if test -n "$shlibpath_var"; then # get the directories listed in $shlibpath_var eval shlib_search_path=\`\$echo \"X\${$shlibpath_var}\" \| \$Xsed -e \'s/:/ /g\'\` else shlib_search_path= fi eval sys_lib_search_path=\"$sys_lib_search_path_spec\" eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" output_objdir=`$echo "X$output" | $Xsed -e 's%/[^/]*$%%'` if test "X$output_objdir" = "X$output"; then output_objdir="$objdir" else output_objdir="$output_objdir/$objdir" fi # Create the object directory. if test ! -d "$output_objdir"; then $show "$mkdir $output_objdir" $run $mkdir $output_objdir exit_status=$? if test "$exit_status" -ne 0 && test ! -d "$output_objdir"; then exit $exit_status fi fi # Determine the type of output case $output in "") $echo "$modename: you must specify an output file" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; *.$libext) linkmode=oldlib ;; *.lo | *.$objext) linkmode=obj ;; *.la) linkmode=lib ;; *) linkmode=prog ;; # Anything else should be a program. esac case $host in *cygwin* | *mingw* | *pw32*) # don't eliminate duplications in $postdeps and $predeps duplicate_compiler_generated_deps=yes ;; *) duplicate_compiler_generated_deps=$duplicate_deps ;; esac specialdeplibs= libs= # Find all interdependent deplibs by searching for libraries # that are linked more than once (e.g. -la -lb -la) for deplib in $deplibs; do if test "X$duplicate_deps" = "Xyes" ; then case "$libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi libs="$libs $deplib" done if test "$linkmode" = lib; then libs="$predeps $libs $compiler_lib_search_path $postdeps" # Compute libraries that are listed more than once in $predeps # $postdeps and mark them as special (i.e., whose duplicates are # not to be eliminated). pre_post_deps= if test "X$duplicate_compiler_generated_deps" = "Xyes" ; then for pre_post_dep in $predeps $postdeps; do case "$pre_post_deps " in *" $pre_post_dep "*) specialdeplibs="$specialdeplibs $pre_post_deps" ;; esac pre_post_deps="$pre_post_deps $pre_post_dep" done fi pre_post_deps= fi deplibs= newdependency_libs= newlib_search_path= need_relink=no # whether we're linking any uninstalled libtool libraries notinst_deplibs= # not-installed libtool libraries case $linkmode in lib) passes="conv link" for file in $dlfiles $dlprefiles; do case $file in *.la) ;; *) $echo "$modename: libraries can \`-dlopen' only libtool libraries: $file" 1>&2 exit $EXIT_FAILURE ;; esac done ;; prog) compile_deplibs= finalize_deplibs= alldeplibs=no newdlfiles= newdlprefiles= passes="conv scan dlopen dlpreopen link" ;; *) passes="conv" ;; esac for pass in $passes; do if test "$linkmode,$pass" = "lib,link" || test "$linkmode,$pass" = "prog,scan"; then libs="$deplibs" deplibs= fi if test "$linkmode" = prog; then case $pass in dlopen) libs="$dlfiles" ;; dlpreopen) libs="$dlprefiles" ;; link) libs="$deplibs %DEPLIBS%" test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs" ;; esac fi if test "$pass" = dlopen; then # Collect dlpreopened libraries save_deplibs="$deplibs" deplibs= fi for deplib in $libs; do lib= found=no case $deplib in -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) if test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else compiler_flags="$compiler_flags $deplib" fi continue ;; -l*) if test "$linkmode" != lib && test "$linkmode" != prog; then $echo "$modename: warning: \`-l' is ignored for archives/objects" 1>&2 continue fi name=`$echo "X$deplib" | $Xsed -e 's/^-l//'` if test "$linkmode" = lib; then searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" else searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" fi for searchdir in $searchdirs; do for search_ext in .la $std_shrext .so .a; do # Search the libtool library lib="$searchdir/lib${name}${search_ext}" if test -f "$lib"; then if test "$search_ext" = ".la"; then found=yes else found=no fi break 2 fi done done if test "$found" != yes; then # deplib doesn't seem to be a libtool library if test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" fi continue else # deplib is a libtool library # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, # We need to do some special things here, and not later. if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then case " $predeps $postdeps " in *" $deplib "*) if (${SED} -e '2q' $lib | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then library_names= old_library= case $lib in */* | *\\*) . $lib ;; *) . ./$lib ;; esac for l in $old_library $library_names; do ll="$l" done if test "X$ll" = "X$old_library" ; then # only static version available found=no ladir=`$echo "X$lib" | $Xsed -e 's%/[^/]*$%%'` test "X$ladir" = "X$lib" && ladir="." lib=$ladir/$old_library if test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" fi continue fi fi ;; *) ;; esac fi fi ;; # -l -L*) case $linkmode in lib) deplibs="$deplib $deplibs" test "$pass" = conv && continue newdependency_libs="$deplib $newdependency_libs" newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` ;; prog) if test "$pass" = conv; then deplibs="$deplib $deplibs" continue fi if test "$pass" = scan; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` ;; *) $echo "$modename: warning: \`-L' is ignored for archives/objects" 1>&2 ;; esac # linkmode continue ;; # -L -R*) if test "$pass" = link; then dir=`$echo "X$deplib" | $Xsed -e 's/^-R//'` # Make sure the xrpath contains only unique directories. case "$xrpath " in *" $dir "*) ;; *) xrpath="$xrpath $dir" ;; esac fi deplibs="$deplib $deplibs" continue ;; *.la) lib="$deplib" ;; *.$libext) if test "$pass" = conv; then deplibs="$deplib $deplibs" continue fi case $linkmode in lib) valid_a_lib=no case $deplibs_check_method in match_pattern*) set dummy $deplibs_check_method match_pattern_regex=`expr "$deplibs_check_method" : "$2 \(.*\)"` if eval $echo \"$deplib\" 2>/dev/null \ | $SED 10q \ | $EGREP "$match_pattern_regex" > /dev/null; then valid_a_lib=yes fi ;; pass_all) valid_a_lib=yes ;; esac if test "$valid_a_lib" != yes; then $echo $echo "*** Warning: Trying to link with static lib archive $deplib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have" $echo "*** because the file extensions .$libext of this argument makes me believe" $echo "*** that it is just a static archive that I should not used here." else $echo $echo "*** Warning: Linking the shared library $output against the" $echo "*** static library $deplib is not portable!" deplibs="$deplib $deplibs" fi continue ;; prog) if test "$pass" != link; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi continue ;; esac # linkmode ;; # *.$libext *.lo | *.$objext) if test "$pass" = conv; then deplibs="$deplib $deplibs" elif test "$linkmode" = prog; then if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then # If there is no dlopen support or we're linking statically, # we need to preload. newdlprefiles="$newdlprefiles $deplib" compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else newdlfiles="$newdlfiles $deplib" fi fi continue ;; %DEPLIBS%) alldeplibs=yes continue ;; esac # case $deplib if test "$found" = yes || test -f "$lib"; then : else $echo "$modename: cannot find the library \`$lib' or unhandled argument \`$deplib'" 1>&2 exit $EXIT_FAILURE fi # Check to see that this really is a libtool archive. if (${SED} -e '2q' $lib | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : else $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi ladir=`$echo "X$lib" | $Xsed -e 's%/[^/]*$%%'` test "X$ladir" = "X$lib" && ladir="." dlname= dlopen= dlpreopen= libdir= library_names= old_library= # If the library was installed with an old release of libtool, # it will not redefine variables installed, or shouldnotlink installed=yes shouldnotlink=no avoidtemprpath= # Read the .la file case $lib in */* | *\\*) . $lib ;; *) . ./$lib ;; esac if test "$linkmode,$pass" = "lib,link" || test "$linkmode,$pass" = "prog,scan" || { test "$linkmode" != prog && test "$linkmode" != lib; }; then test -n "$dlopen" && dlfiles="$dlfiles $dlopen" test -n "$dlpreopen" && dlprefiles="$dlprefiles $dlpreopen" fi if test "$pass" = conv; then # Only check for convenience libraries deplibs="$lib $deplibs" if test -z "$libdir"; then if test -z "$old_library"; then $echo "$modename: cannot find name of link library for \`$lib'" 1>&2 exit $EXIT_FAILURE fi # It is a libtool convenience library, so add in its objects. convenience="$convenience $ladir/$objdir/$old_library" old_convenience="$old_convenience $ladir/$objdir/$old_library" tmp_libs= for deplib in $dependency_libs; do deplibs="$deplib $deplibs" if test "X$duplicate_deps" = "Xyes" ; then case "$tmp_libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi tmp_libs="$tmp_libs $deplib" done elif test "$linkmode" != prog && test "$linkmode" != lib; then $echo "$modename: \`$lib' is not a convenience library" 1>&2 exit $EXIT_FAILURE fi continue fi # $pass = conv # Get the name of the library we link against. linklib= for l in $old_library $library_names; do linklib="$l" done if test -z "$linklib"; then $echo "$modename: cannot find name of link library for \`$lib'" 1>&2 exit $EXIT_FAILURE fi # This library was specified with -dlopen. if test "$pass" = dlopen; then if test -z "$libdir"; then $echo "$modename: cannot -dlopen a convenience library: \`$lib'" 1>&2 exit $EXIT_FAILURE fi if test -z "$dlname" || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then # If there is no dlname, no dlopen support or we're linking # statically, we need to preload. We also need to preload any # dependent libraries so libltdl's deplib preloader doesn't # bomb out in the load deplibs phase. dlprefiles="$dlprefiles $lib $dependency_libs" else newdlfiles="$newdlfiles $lib" fi continue fi # $pass = dlopen # We need an absolute path. case $ladir in [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; *) abs_ladir=`cd "$ladir" && pwd` if test -z "$abs_ladir"; then $echo "$modename: warning: cannot determine absolute directory name of \`$ladir'" 1>&2 $echo "$modename: passing it literally to the linker, although it might fail" 1>&2 abs_ladir="$ladir" fi ;; esac laname=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` # Find the relevant object directory and library name. if test "X$installed" = Xyes; then if test ! -f "$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then $echo "$modename: warning: library \`$lib' was moved." 1>&2 dir="$ladir" absdir="$abs_ladir" libdir="$abs_ladir" else dir="$libdir" absdir="$libdir" fi test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes else if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then dir="$ladir" absdir="$abs_ladir" # Remove this search path later notinst_path="$notinst_path $abs_ladir" else dir="$ladir/$objdir" absdir="$abs_ladir/$objdir" # Remove this search path later notinst_path="$notinst_path $abs_ladir" fi fi # $installed = yes name=`$echo "X$laname" | $Xsed -e 's/\.la$//' -e 's/^lib//'` # This library was specified with -dlpreopen. if test "$pass" = dlpreopen; then if test -z "$libdir"; then $echo "$modename: cannot -dlpreopen a convenience library: \`$lib'" 1>&2 exit $EXIT_FAILURE fi # Prefer using a static library (so that no silly _DYNAMIC symbols # are required to link). if test -n "$old_library"; then newdlprefiles="$newdlprefiles $dir/$old_library" # Otherwise, use the dlname, so that lt_dlopen finds it. elif test -n "$dlname"; then newdlprefiles="$newdlprefiles $dir/$dlname" else newdlprefiles="$newdlprefiles $dir/$linklib" fi fi # $pass = dlpreopen if test -z "$libdir"; then # Link the convenience library if test "$linkmode" = lib; then deplibs="$dir/$old_library $deplibs" elif test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$dir/$old_library $compile_deplibs" finalize_deplibs="$dir/$old_library $finalize_deplibs" else deplibs="$lib $deplibs" # used for prog,scan pass fi continue fi if test "$linkmode" = prog && test "$pass" != link; then newlib_search_path="$newlib_search_path $ladir" deplibs="$lib $deplibs" linkalldeplibs=no if test "$link_all_deplibs" != no || test -z "$library_names" || test "$build_libtool_libs" = no; then linkalldeplibs=yes fi tmp_libs= for deplib in $dependency_libs; do case $deplib in -L*) newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'`;; ### testsuite: skip nested quoting test esac # Need to link against all dependency_libs? if test "$linkalldeplibs" = yes; then deplibs="$deplib $deplibs" else # Need to hardcode shared library paths # or/and link against static libraries newdependency_libs="$deplib $newdependency_libs" fi if test "X$duplicate_deps" = "Xyes" ; then case "$tmp_libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi tmp_libs="$tmp_libs $deplib" done # for deplib continue fi # $linkmode = prog... if test "$linkmode,$pass" = "prog,link"; then if test -n "$library_names" && { { test "$prefer_static_libs" = no || test "$prefer_static_libs,$installed" = "built,yes"; } || test -z "$old_library"; }; then # We need to hardcode the library path if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then # Make sure the rpath contains only unique directories. case "$temp_rpath " in *" $dir "*) ;; *" $absdir "*) ;; *) temp_rpath="$temp_rpath $absdir" ;; esac fi # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) compile_rpath="$compile_rpath $absdir" esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" esac ;; esac fi # $linkmode,$pass = prog,link... if test "$alldeplibs" = yes && { test "$deplibs_check_method" = pass_all || { test "$build_libtool_libs" = yes && test -n "$library_names"; }; }; then # We only need to search for static libraries continue fi fi link_static=no # Whether the deplib will be linked statically use_static_libs=$prefer_static_libs if test "$use_static_libs" = built && test "$installed" = yes ; then use_static_libs=no fi if test -n "$library_names" && { test "$use_static_libs" = no || test -z "$old_library"; }; then if test "$installed" = no; then notinst_deplibs="$notinst_deplibs $lib" need_relink=yes fi # This is a shared library # Warn about portability, can't link against -module's on # some systems (darwin) if test "$shouldnotlink" = yes && test "$pass" = link ; then $echo if test "$linkmode" = prog; then $echo "*** Warning: Linking the executable $output against the loadable module" else $echo "*** Warning: Linking the shared library $output against the loadable module" fi $echo "*** $linklib is not portable!" fi if test "$linkmode" = lib && test "$hardcode_into_libs" = yes; then # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) compile_rpath="$compile_rpath $absdir" esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" esac ;; esac fi if test -n "$old_archive_from_expsyms_cmds"; then # figure out the soname set dummy $library_names realname="$2" shift; shift libname=`eval \\$echo \"$libname_spec\"` # use dlname if we got it. it's perfectly good, no? if test -n "$dlname"; then soname="$dlname" elif test -n "$soname_spec"; then # bleh windows case $host in *cygwin* | mingw*) major=`expr $current - $age` versuffix="-$major" ;; esac eval soname=\"$soname_spec\" else soname="$realname" fi # Make a new name for the extract_expsyms_cmds to use soroot="$soname" soname=`$echo $soroot | ${SED} -e 's/^.*\///'` newlib="libimp-`$echo $soname | ${SED} 's/^lib//;s/\.dll$//'`.a" # If the library has no export list, then create one now if test -f "$output_objdir/$soname-def"; then : else $show "extracting exported symbol list from \`$soname'" save_ifs="$IFS"; IFS='~' cmds=$extract_expsyms_cmds for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" fi # Create $newlib if test -f "$output_objdir/$newlib"; then :; else $show "generating import library for \`$soname'" save_ifs="$IFS"; IFS='~' cmds=$old_archive_from_expsyms_cmds for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" fi # make sure the library variables are pointing to the new library dir=$output_objdir linklib=$newlib fi # test -n "$old_archive_from_expsyms_cmds" if test "$linkmode" = prog || test "$mode" != relink; then add_shlibpath= add_dir= add= lib_linked=yes case $hardcode_action in immediate | unsupported) if test "$hardcode_direct" = no; then add="$dir/$linklib" case $host in *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; *-*-sysv4*uw2*) add_dir="-L$dir" ;; *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ *-*-unixware7*) add_dir="-L$dir" ;; *-*-darwin* ) # if the lib is a module then we can not link against # it, someone is ignoring the new warnings I added if /usr/bin/file -L $add 2> /dev/null | $EGREP ": [^:]* bundle" >/dev/null ; then $echo "** Warning, lib $linklib is a module, not a shared library" if test -z "$old_library" ; then $echo $echo "** And there doesn't seem to be a static archive available" $echo "** The link will probably fail, sorry" else add="$dir/$old_library" fi fi esac elif test "$hardcode_minus_L" = no; then case $host in *-*-sunos*) add_shlibpath="$dir" ;; esac add_dir="-L$dir" add="-l$name" elif test "$hardcode_shlibpath_var" = no; then add_shlibpath="$dir" add="-l$name" else lib_linked=no fi ;; relink) if test "$hardcode_direct" = yes; then add="$dir/$linklib" elif test "$hardcode_minus_L" = yes; then add_dir="-L$dir" # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) add_dir="$add_dir -L$inst_prefix_dir$libdir" ;; esac fi add="-l$name" elif test "$hardcode_shlibpath_var" = yes; then add_shlibpath="$dir" add="-l$name" else lib_linked=no fi ;; *) lib_linked=no ;; esac if test "$lib_linked" != yes; then $echo "$modename: configuration error: unsupported hardcode properties" exit $EXIT_FAILURE fi if test -n "$add_shlibpath"; then case :$compile_shlibpath: in *":$add_shlibpath:"*) ;; *) compile_shlibpath="$compile_shlibpath$add_shlibpath:" ;; esac fi if test "$linkmode" = prog; then test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" test -n "$add" && compile_deplibs="$add $compile_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" if test "$hardcode_direct" != yes && \ test "$hardcode_minus_L" != yes && \ test "$hardcode_shlibpath_var" = yes; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; esac fi fi fi if test "$linkmode" = prog || test "$mode" = relink; then add_shlibpath= add_dir= add= # Finalize command for both is simple: just hardcode it. if test "$hardcode_direct" = yes; then add="$libdir/$linklib" elif test "$hardcode_minus_L" = yes; then add_dir="-L$libdir" add="-l$name" elif test "$hardcode_shlibpath_var" = yes; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; esac add="-l$name" elif test "$hardcode_automatic" = yes; then if test -n "$inst_prefix_dir" && test -f "$inst_prefix_dir$libdir/$linklib" ; then add="$inst_prefix_dir$libdir/$linklib" else add="$libdir/$linklib" fi else # We cannot seem to hardcode it, guess we'll fake it. add_dir="-L$libdir" # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) add_dir="$add_dir -L$inst_prefix_dir$libdir" ;; esac fi add="-l$name" fi if test "$linkmode" = prog; then test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" test -n "$add" && finalize_deplibs="$add $finalize_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" fi fi elif test "$linkmode" = prog; then # Here we assume that one of hardcode_direct or hardcode_minus_L # is not unsupported. This is valid on all known static and # shared platforms. if test "$hardcode_direct" != unsupported; then test -n "$old_library" && linklib="$old_library" compile_deplibs="$dir/$linklib $compile_deplibs" finalize_deplibs="$dir/$linklib $finalize_deplibs" else compile_deplibs="-l$name -L$dir $compile_deplibs" finalize_deplibs="-l$name -L$dir $finalize_deplibs" fi elif test "$build_libtool_libs" = yes; then # Not a shared library if test "$deplibs_check_method" != pass_all; then # We're trying link a shared library against a static one # but the system doesn't support it. # Just print a warning and add the library to dependency_libs so # that the program can be linked against the static library. $echo $echo "*** Warning: This system can not link to static lib archive $lib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have." if test "$module" = yes; then $echo "*** But as you try to build a module library, libtool will still create " $echo "*** a static module, that should work as long as the dlopening application" $echo "*** is linked with the -dlopen flag to resolve symbols at runtime." if test -z "$global_symbol_pipe"; then $echo $echo "*** However, this would only work if libtool was able to extract symbol" $echo "*** lists from a program, using \`nm' or equivalent, but libtool could" $echo "*** not find such a program. So, this module is probably useless." $echo "*** \`nm' from GNU binutils and a full rebuild may help." fi if test "$build_old_libs" = no; then build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi else deplibs="$dir/$old_library $deplibs" link_static=yes fi fi # link shared/static library? if test "$linkmode" = lib; then if test -n "$dependency_libs" && { test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes || test "$link_static" = yes; }; then # Extract -R from dependency_libs temp_deplibs= for libdir in $dependency_libs; do case $libdir in -R*) temp_xrpath=`$echo "X$libdir" | $Xsed -e 's/^-R//'` case " $xrpath " in *" $temp_xrpath "*) ;; *) xrpath="$xrpath $temp_xrpath";; esac;; *) temp_deplibs="$temp_deplibs $libdir";; esac done dependency_libs="$temp_deplibs" fi newlib_search_path="$newlib_search_path $absdir" # Link against this library test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" # ... and its dependency_libs tmp_libs= for deplib in $dependency_libs; do newdependency_libs="$deplib $newdependency_libs" if test "X$duplicate_deps" = "Xyes" ; then case "$tmp_libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi tmp_libs="$tmp_libs $deplib" done if test "$link_all_deplibs" != no; then # Add the search paths of all dependency libraries for deplib in $dependency_libs; do case $deplib in -L*) path="$deplib" ;; *.la) dir=`$echo "X$deplib" | $Xsed -e 's%/[^/]*$%%'` test "X$dir" = "X$deplib" && dir="." # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; *) absdir=`cd "$dir" && pwd` if test -z "$absdir"; then $echo "$modename: warning: cannot determine absolute directory name of \`$dir'" 1>&2 absdir="$dir" fi ;; esac if grep "^installed=no" $deplib > /dev/null; then path="$absdir/$objdir" else eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` if test -z "$libdir"; then $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi if test "$absdir" != "$libdir"; then $echo "$modename: warning: \`$deplib' seems to be moved" 1>&2 fi path="$absdir" fi depdepl= case $host in *-*-darwin*) # we do not want to link against static libs, # but need to link against shared eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` eval deplibdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` if test -n "$deplibrary_names" ; then for tmp in $deplibrary_names ; do depdepl=$tmp done if test -f "$deplibdir/$depdepl" ; then depdepl="$deplibdir/$depdepl" elif test -f "$path/$depdepl" ; then depdepl="$path/$depdepl" else # Can't find it, oh well... depdepl= fi # do not add paths which are already there case " $newlib_search_path " in *" $path "*) ;; *) newlib_search_path="$newlib_search_path $path";; esac fi path="" ;; *) path="-L$path" ;; esac ;; -l*) case $host in *-*-darwin*) # Again, we only want to link against shared libraries eval tmp_libs=`$echo "X$deplib" | $Xsed -e "s,^\-l,,"` for tmp in $newlib_search_path ; do if test -f "$tmp/lib$tmp_libs.dylib" ; then eval depdepl="$tmp/lib$tmp_libs.dylib" break fi done path="" ;; *) continue ;; esac ;; *) continue ;; esac case " $deplibs " in *" $path "*) ;; *) deplibs="$path $deplibs" ;; esac case " $deplibs " in *" $depdepl "*) ;; *) deplibs="$depdepl $deplibs" ;; esac done fi # link_all_deplibs != no fi # linkmode = lib done # for deplib in $libs dependency_libs="$newdependency_libs" if test "$pass" = dlpreopen; then # Link the dlpreopened libraries before other libraries for deplib in $save_deplibs; do deplibs="$deplib $deplibs" done fi if test "$pass" != dlopen; then if test "$pass" != conv; then # Make sure lib_search_path contains only unique directories. lib_search_path= for dir in $newlib_search_path; do case "$lib_search_path " in *" $dir "*) ;; *) lib_search_path="$lib_search_path $dir" ;; esac done newlib_search_path= fi if test "$linkmode,$pass" != "prog,link"; then vars="deplibs" else vars="compile_deplibs finalize_deplibs" fi for var in $vars dependency_libs; do # Add libraries to $var in reverse order eval tmp_libs=\"\$$var\" new_libs= for deplib in $tmp_libs; do # FIXME: Pedantically, this is the right thing to do, so # that some nasty dependency loop isn't accidentally # broken: #new_libs="$deplib $new_libs" # Pragmatically, this seems to cause very few problems in # practice: case $deplib in -L*) new_libs="$deplib $new_libs" ;; -R*) ;; *) # And here is the reason: when a library appears more # than once as an explicit dependence of a library, or # is implicitly linked in more than once by the # compiler, it is considered special, and multiple # occurrences thereof are not removed. Compare this # with having the same library being listed as a # dependency of multiple other libraries: in this case, # we know (pedantically, we assume) the library does not # need to be listed more than once, so we keep only the # last copy. This is not always right, but it is rare # enough that we require users that really mean to play # such unportable linking tricks to link the library # using -Wl,-lname, so that libtool does not consider it # for duplicate removal. case " $specialdeplibs " in *" $deplib "*) new_libs="$deplib $new_libs" ;; *) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$deplib $new_libs" ;; esac ;; esac ;; esac done tmp_libs= for deplib in $new_libs; do case $deplib in -L*) case " $tmp_libs " in *" $deplib "*) ;; *) tmp_libs="$tmp_libs $deplib" ;; esac ;; *) tmp_libs="$tmp_libs $deplib" ;; esac done eval $var=\"$tmp_libs\" done # for var fi # Last step: remove runtime libs from dependency_libs # (they stay in deplibs) tmp_libs= for i in $dependency_libs ; do case " $predeps $postdeps $compiler_lib_search_path " in *" $i "*) i="" ;; esac if test -n "$i" ; then tmp_libs="$tmp_libs $i" fi done dependency_libs=$tmp_libs done # for pass if test "$linkmode" = prog; then dlfiles="$newdlfiles" dlprefiles="$newdlprefiles" fi case $linkmode in oldlib) case " $deplibs" in *\ -l* | *\ -L*) $echo "$modename: warning: \`-l' and \`-L' are ignored for archives" 1>&2 ;; esac if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then $echo "$modename: warning: \`-dlopen' is ignored for archives" 1>&2 fi if test -n "$rpath"; then $echo "$modename: warning: \`-rpath' is ignored for archives" 1>&2 fi if test -n "$xrpath"; then $echo "$modename: warning: \`-R' is ignored for archives" 1>&2 fi if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info/-version-number' is ignored for archives" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for archives" 1>&2 fi if test -n "$export_symbols" || test -n "$export_symbols_regex"; then $echo "$modename: warning: \`-export-symbols' is ignored for archives" 1>&2 fi # Now set the variables for building old libraries. build_libtool_libs=no oldlibs="$output" objs="$objs$old_deplibs" ;; lib) # Make sure we only generate libraries of the form `libNAME.la'. case $outputname in lib*) name=`$echo "X$outputname" | $Xsed -e 's/\.la$//' -e 's/^lib//'` eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" ;; *) if test "$module" = no; then $echo "$modename: libtool library \`$output' must begin with \`lib'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test "$need_lib_prefix" != no; then # Add the "lib" prefix for modules if required name=`$echo "X$outputname" | $Xsed -e 's/\.la$//'` eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" else libname=`$echo "X$outputname" | $Xsed -e 's/\.la$//'` fi ;; esac if test -n "$objs"; then if test "$deplibs_check_method" != pass_all; then $echo "$modename: cannot build libtool library \`$output' from non-libtool objects on this host:$objs" 2>&1 exit $EXIT_FAILURE else $echo $echo "*** Warning: Linking the shared library $output against the non-libtool" $echo "*** objects $objs is not portable!" libobjs="$libobjs $objs" fi fi if test "$dlself" != no; then $echo "$modename: warning: \`-dlopen self' is ignored for libtool libraries" 1>&2 fi set dummy $rpath if test "$#" -gt 2; then $echo "$modename: warning: ignoring multiple \`-rpath's for a libtool library" 1>&2 fi install_libdir="$2" oldlibs= if test -z "$rpath"; then if test "$build_libtool_libs" = yes; then # Building a libtool convenience library. # Some compilers have problems with a `.al' extension so # convenience libraries should have the same extension an # archive normally would. oldlibs="$output_objdir/$libname.$libext $oldlibs" build_libtool_libs=convenience build_old_libs=yes fi if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info/-version-number' is ignored for convenience libraries" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for convenience libraries" 1>&2 fi else # Parse the version information argument. save_ifs="$IFS"; IFS=':' set dummy $vinfo 0 0 0 IFS="$save_ifs" if test -n "$8"; then $echo "$modename: too many parameters to \`-version-info'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # convert absolute version numbers to libtool ages # this retains compatibility with .la files and attempts # to make the code below a bit more comprehensible case $vinfo_number in yes) number_major="$2" number_minor="$3" number_revision="$4" # # There are really only two kinds -- those that # use the current revision as the major version # and those that subtract age and use age as # a minor version. But, then there is irix # which has an extra 1 added just for fun # case $version_type in darwin|linux|osf|windows|none) current=`expr $number_major + $number_minor` age="$number_minor" revision="$number_revision" ;; freebsd-aout|freebsd-elf|sunos) current="$number_major" revision="$number_minor" age="0" ;; irix|nonstopux) current=`expr $number_major + $number_minor` age="$number_minor" revision="$number_minor" lt_irix_increment=no ;; *) $echo "$modename: unknown library version type \`$version_type'" 1>&2 $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 exit $EXIT_FAILURE ;; esac ;; no) current="$2" revision="$3" age="$4" ;; esac # Check that each of the things are valid numbers. case $current in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) $echo "$modename: CURRENT \`$current' must be a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; esac case $revision in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) $echo "$modename: REVISION \`$revision' must be a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; esac case $age in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) $echo "$modename: AGE \`$age' must be a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; esac if test "$age" -gt "$current"; then $echo "$modename: AGE \`$age' is greater than the current interface number \`$current'" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE fi # Calculate the version variables. major= versuffix= verstring= case $version_type in none) ;; darwin) # Like Linux, but with the current version available in # verstring for coding it into the library header major=.`expr $current - $age` versuffix="$major.$age.$revision" # Darwin ld doesn't like 0 for these options... minor_current=`expr $current + 1` xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision" verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" ;; freebsd-aout) major=".$current" versuffix=".$current.$revision"; ;; freebsd-elf) major=".$current" versuffix=".$current"; ;; irix | nonstopux) if test "X$lt_irix_increment" = "Xno"; then major=`expr $current - $age` else major=`expr $current - $age + 1` fi case $version_type in nonstopux) verstring_prefix=nonstopux ;; *) verstring_prefix=sgi ;; esac verstring="$verstring_prefix$major.$revision" # Add in all the interfaces that we are compatible with. loop=$revision while test "$loop" -ne 0; do iface=`expr $revision - $loop` loop=`expr $loop - 1` verstring="$verstring_prefix$major.$iface:$verstring" done # Before this point, $major must not contain `.'. major=.$major versuffix="$major.$revision" ;; linux) major=.`expr $current - $age` versuffix="$major.$age.$revision" ;; osf) major=.`expr $current - $age` versuffix=".$current.$age.$revision" verstring="$current.$age.$revision" # Add in all the interfaces that we are compatible with. loop=$age while test "$loop" -ne 0; do iface=`expr $current - $loop` loop=`expr $loop - 1` verstring="$verstring:${iface}.0" done # Make executables depend on our current version. verstring="$verstring:${current}.0" ;; sunos) major=".$current" versuffix=".$current.$revision" ;; windows) # Use '-' rather than '.', since we only want one # extension on DOS 8.3 filesystems. major=`expr $current - $age` versuffix="-$major" ;; *) $echo "$modename: unknown library version type \`$version_type'" 1>&2 $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 exit $EXIT_FAILURE ;; esac # Clear the version info if we defaulted, and they specified a release. if test -z "$vinfo" && test -n "$release"; then major= case $version_type in darwin) # we can't check for "0.0" in archive_cmds due to quoting # problems, so we reset it completely verstring= ;; *) verstring="0.0" ;; esac if test "$need_version" = no; then versuffix= else versuffix=".0.0" fi fi # Remove version info from name if versioning should be avoided if test "$avoid_version" = yes && test "$need_version" = no; then major= versuffix= verstring="" fi # Check to see if the archive will have undefined symbols. if test "$allow_undefined" = yes; then if test "$allow_undefined_flag" = unsupported; then $echo "$modename: warning: undefined symbols not allowed in $host shared libraries" 1>&2 build_libtool_libs=no build_old_libs=yes fi else # Don't allow undefined symbols. allow_undefined_flag="$no_undefined_flag" fi fi if test "$mode" != relink; then # Remove our outputs, but don't remove object files since they # may have been created when compiling PIC objects. removelist= tempremovelist=`$echo "$output_objdir/*"` for p in $tempremovelist; do case $p in *.$objext) ;; $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) if test "X$precious_files_regex" != "X"; then if echo $p | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 then continue fi fi removelist="$removelist $p" ;; *) ;; esac done if test -n "$removelist"; then $show "${rm}r $removelist" $run ${rm}r $removelist fi fi # Now set the variables for building old libraries. if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then oldlibs="$oldlibs $output_objdir/$libname.$libext" # Transform .lo files to .o files. oldobjs="$objs "`$echo "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}'$/d' -e "$lo2o" | $NL2SP` fi # Eliminate all temporary directories. #for path in $notinst_path; do # lib_search_path=`$echo "$lib_search_path " | ${SED} -e "s% $path % %g"` # deplibs=`$echo "$deplibs " | ${SED} -e "s% -L$path % %g"` # dependency_libs=`$echo "$dependency_libs " | ${SED} -e "s% -L$path % %g"` #done if test -n "$xrpath"; then # If the user specified any rpath flags, then add them. temp_xrpath= for libdir in $xrpath; do temp_xrpath="$temp_xrpath -R$libdir" case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" ;; esac done if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then dependency_libs="$temp_xrpath $dependency_libs" fi fi # Make sure dlfiles contains only unique files that won't be dlpreopened old_dlfiles="$dlfiles" dlfiles= for lib in $old_dlfiles; do case " $dlprefiles $dlfiles " in *" $lib "*) ;; *) dlfiles="$dlfiles $lib" ;; esac done # Make sure dlprefiles contains only unique files old_dlprefiles="$dlprefiles" dlprefiles= for lib in $old_dlprefiles; do case "$dlprefiles " in *" $lib "*) ;; *) dlprefiles="$dlprefiles $lib" ;; esac done if test "$build_libtool_libs" = yes; then if test -n "$rpath"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos*) # these systems don't actually have a c library (as such)! ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C library is in the System framework deplibs="$deplibs -framework System" ;; *-*-netbsd*) # Don't link with libc until the a.out ld.so is fixed. ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc due to us having libc/libc_r. ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work ;; *) # Add libc to deplibs on all other systems if necessary. if test "$build_libtool_need_lc" = "yes"; then deplibs="$deplibs -lc" fi ;; esac fi # Transform deplibs into only deplibs that can be linked in shared. name_save=$name libname_save=$libname release_save=$release versuffix_save=$versuffix major_save=$major # I'm not sure if I'm treating the release correctly. I think # release should show up in the -l (ie -lgmp5) so we don't want to # add it in twice. Is that correct? release="" versuffix="" major="" newdeplibs= droppeddeps=no case $deplibs_check_method in pass_all) # Don't check for shared/static. Everything works. # This might be a little naive. We might want to check # whether the library exists or not. But this is on # osf3 & osf4 and I'm not really sure... Just # implementing what was already the behavior. newdeplibs=$deplibs ;; test_compile) # This code stresses the "libraries are programs" paradigm to its # limits. Maybe even breaks it. We compile a program, linking it # against the deplibs as a proxy for the library. Then we can check # whether they linked in statically or dynamically with ldd. $rm conftest.c cat > conftest.c </dev/null` for potent_lib in $potential_libs; do # Follow soft links. if ls -lLd "$potent_lib" 2>/dev/null \ | grep " -> " >/dev/null; then continue fi # The statement above tries to avoid entering an # endless loop below, in case of cyclic links. # We might still enter an endless loop, since a link # loop can be closed while we follow links, # but so what? potlib="$potent_lib" while test -h "$potlib" 2>/dev/null; do potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` case $potliblink in [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; *) potlib=`$echo "X$potlib" | $Xsed -e 's,[^/]*$,,'`"$potliblink";; esac done if eval $file_magic_cmd \"\$potlib\" 2>/dev/null \ | ${SED} 10q \ | $EGREP "$file_magic_regex" > /dev/null; then newdeplibs="$newdeplibs $a_deplib" a_deplib="" break 2 fi done done fi if test -n "$a_deplib" ; then droppeddeps=yes $echo $echo "*** Warning: linker path does not have real file for library $a_deplib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have" $echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib" ; then $echo "*** with $libname but no candidates were found. (...for file magic test)" else $echo "*** with $libname and none of the candidates passed a file format test" $echo "*** using a file magic. Last file checked: $potlib" fi fi else # Add a -L argument. newdeplibs="$newdeplibs $a_deplib" fi done # Gone through all deplibs. ;; match_pattern*) set dummy $deplibs_check_method match_pattern_regex=`expr "$deplibs_check_method" : "$2 \(.*\)"` for a_deplib in $deplibs; do name=`expr $a_deplib : '-l\(.*\)'` # If $name is empty we are operating on a -L argument. if test -n "$name" && test "$name" != "0"; then if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then case " $predeps $postdeps " in *" $a_deplib "*) newdeplibs="$newdeplibs $a_deplib" a_deplib="" ;; esac fi if test -n "$a_deplib" ; then libname=`eval \\$echo \"$libname_spec\"` for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do potential_libs=`ls $i/$libname[.-]* 2>/dev/null` for potent_lib in $potential_libs; do potlib="$potent_lib" # see symlink-check above in file_magic test if eval $echo \"$potent_lib\" 2>/dev/null \ | ${SED} 10q \ | $EGREP "$match_pattern_regex" > /dev/null; then newdeplibs="$newdeplibs $a_deplib" a_deplib="" break 2 fi done done fi if test -n "$a_deplib" ; then droppeddeps=yes $echo $echo "*** Warning: linker path does not have real file for library $a_deplib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have" $echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib" ; then $echo "*** with $libname but no candidates were found. (...for regex pattern test)" else $echo "*** with $libname and none of the candidates passed a file format test" $echo "*** using a regex pattern. Last file checked: $potlib" fi fi else # Add a -L argument. newdeplibs="$newdeplibs $a_deplib" fi done # Gone through all deplibs. ;; none | unknown | *) newdeplibs="" tmp_deplibs=`$echo "X $deplibs" | $Xsed -e 's/ -lc$//' \ -e 's/ -[LR][^ ]*//g'` if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then for i in $predeps $postdeps ; do # can't use Xsed below, because $i might contain '/' tmp_deplibs=`$echo "X $tmp_deplibs" | ${SED} -e "1s,^X,," -e "s,$i,,"` done fi if $echo "X $tmp_deplibs" | $Xsed -e 's/[ ]//g' \ | grep . >/dev/null; then $echo if test "X$deplibs_check_method" = "Xnone"; then $echo "*** Warning: inter-library dependencies are not supported in this platform." else $echo "*** Warning: inter-library dependencies are not known to be supported." fi $echo "*** All declared inter-library dependencies are being dropped." droppeddeps=yes fi ;; esac versuffix=$versuffix_save major=$major_save release=$release_save libname=$libname_save name=$name_save case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library is the System framework newdeplibs=`$echo "X $newdeplibs" | $Xsed -e 's/ -lc / -framework System /'` ;; esac if test "$droppeddeps" = yes; then if test "$module" = yes; then $echo $echo "*** Warning: libtool could not satisfy all declared inter-library" $echo "*** dependencies of module $libname. Therefore, libtool will create" $echo "*** a static module, that should work as long as the dlopening" $echo "*** application is linked with the -dlopen flag." if test -z "$global_symbol_pipe"; then $echo $echo "*** However, this would only work if libtool was able to extract symbol" $echo "*** lists from a program, using \`nm' or equivalent, but libtool could" $echo "*** not find such a program. So, this module is probably useless." $echo "*** \`nm' from GNU binutils and a full rebuild may help." fi if test "$build_old_libs" = no; then oldlibs="$output_objdir/$libname.$libext" build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi else $echo "*** The inter-library dependencies that have been dropped here will be" $echo "*** automatically added whenever a program is linked with this library" $echo "*** or is declared to -dlopen it." if test "$allow_undefined" = no; then $echo $echo "*** Since this library must not contain undefined symbols," $echo "*** because either the platform does not support them or" $echo "*** it was explicitly requested with -no-undefined," $echo "*** libtool will only create a static version of it." if test "$build_old_libs" = no; then oldlibs="$output_objdir/$libname.$libext" build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi fi fi # Done checking deplibs! deplibs=$newdeplibs fi # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $deplibs " in *" -L$path/$objdir "*) new_libs="$new_libs -L$path/$objdir" ;; esac ;; esac done for deplib in $deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$new_libs $deplib" ;; esac ;; *) new_libs="$new_libs $deplib" ;; esac done deplibs="$new_libs" # All the library-specific variables (install_libdir is set above). library_names= old_library= dlname= # Test again, we may have decided not to build it any more if test "$build_libtool_libs" = yes; then if test "$hardcode_into_libs" = yes; then # Hardcode the library paths hardcode_libdirs= dep_rpath= rpath="$finalize_rpath" test "$mode" != relink && rpath="$compile_rpath$rpath" for libdir in $rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs="$libdir" else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" dep_rpath="$dep_rpath $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) perm_rpath="$perm_rpath $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir="$hardcode_libdirs" if test -n "$hardcode_libdir_flag_spec_ld"; then case $archive_cmds in *\$LD*) eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\" ;; *) eval dep_rpath=\"$hardcode_libdir_flag_spec\" ;; esac else eval dep_rpath=\"$hardcode_libdir_flag_spec\" fi fi if test -n "$runpath_var" && test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do rpath="$rpath$dir:" done eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" fi test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" fi shlibpath="$finalize_shlibpath" test "$mode" != relink && shlibpath="$compile_shlibpath$shlibpath" if test -n "$shlibpath"; then eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" fi # Get the real and link names of the library. eval shared_ext=\"$shrext_cmds\" eval library_names=\"$library_names_spec\" set dummy $library_names realname="$2" shift; shift if test -n "$soname_spec"; then eval soname=\"$soname_spec\" else soname="$realname" fi if test -z "$dlname"; then dlname=$soname fi lib="$output_objdir/$realname" linknames= for link do linknames="$linknames $link" done # Use standard objects if they are pic test -z "$pic_flag" && libobjs=`$echo "X$libobjs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` # Prepare the list of exported symbols if test -z "$export_symbols"; then if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then $show "generating symbol list for \`$libname.la'" export_symbols="$output_objdir/$libname.exp" $run $rm $export_symbols cmds=$export_symbols_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" if len=`expr "X$cmd" : ".*"` && test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then $show "$cmd" $run eval "$cmd" || exit $? skipped_export=false else # The command line is too long to execute in one step. $show "using reloadable object file for export list..." skipped_export=: # Break out early, otherwise skipped_export may be # set to false by a later but shorter cmd. break fi done IFS="$save_ifs" if test -n "$export_symbols_regex"; then $show "$EGREP -e \"$export_symbols_regex\" \"$export_symbols\" > \"${export_symbols}T\"" $run eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' $show "$mv \"${export_symbols}T\" \"$export_symbols\"" $run eval '$mv "${export_symbols}T" "$export_symbols"' fi fi fi if test -n "$export_symbols" && test -n "$include_expsyms"; then $run eval '$echo "X$include_expsyms" | $SP2NL >> "$export_symbols"' fi tmp_deplibs= for test_deplib in $deplibs; do case " $convenience " in *" $test_deplib "*) ;; *) tmp_deplibs="$tmp_deplibs $test_deplib" ;; esac done deplibs="$tmp_deplibs" if test -n "$convenience"; then if test -n "$whole_archive_flag_spec"; then save_libobjs=$libobjs eval libobjs=\"\$libobjs $whole_archive_flag_spec\" else gentop="$output_objdir/${outputname}x" generated="$generated $gentop" func_extract_archives $gentop $convenience libobjs="$libobjs $func_extract_archives_result" fi fi if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then eval flag=\"$thread_safe_flag_spec\" linker_flags="$linker_flags $flag" fi # Make a backup of the uninstalled library when relinking if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}U && $mv $realname ${realname}U)' || exit $? fi # Do each of the archive commands. if test "$module" = yes && test -n "$module_cmds" ; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then eval test_cmds=\"$module_expsym_cmds\" cmds=$module_expsym_cmds else eval test_cmds=\"$module_cmds\" cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then eval test_cmds=\"$archive_expsym_cmds\" cmds=$archive_expsym_cmds else eval test_cmds=\"$archive_cmds\" cmds=$archive_cmds fi fi if test "X$skipped_export" != "X:" && len=`expr "X$test_cmds" : ".*" 2>/dev/null` && test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then : else # The command line is too long to link in one step, link piecewise. $echo "creating reloadable object files..." # Save the value of $output and $libobjs because we want to # use them later. If we have whole_archive_flag_spec, we # want to use save_libobjs as it was before # whole_archive_flag_spec was expanded, because we can't # assume the linker understands whole_archive_flag_spec. # This may have to be revisited, in case too many # convenience libraries get linked in and end up exceeding # the spec. if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then save_libobjs=$libobjs fi save_output=$output output_la=`$echo "X$output" | $Xsed -e "$basename"` # Clear the reloadable object creation command queue and # initialize k to one. test_cmds= concat_cmds= objlist= delfiles= last_robj= k=1 output=$output_objdir/$output_la-${k}.$objext # Loop over the list of objects to be linked. for obj in $save_libobjs do eval test_cmds=\"$reload_cmds $objlist $last_robj\" if test "X$objlist" = X || { len=`expr "X$test_cmds" : ".*" 2>/dev/null` && test "$len" -le "$max_cmd_len"; }; then objlist="$objlist $obj" else # The command $test_cmds is almost too long, add a # command to the queue. if test "$k" -eq 1 ; then # The first file doesn't have a previous command to add. eval concat_cmds=\"$reload_cmds $objlist $last_robj\" else # All subsequent reloadable object files will link in # the last one created. eval concat_cmds=\"\$concat_cmds~$reload_cmds $objlist $last_robj\" fi last_robj=$output_objdir/$output_la-${k}.$objext k=`expr $k + 1` output=$output_objdir/$output_la-${k}.$objext objlist=$obj len=1 fi done # Handle the remaining objects by creating one last # reloadable object file. All subsequent reloadable object # files will link in the last one created. test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\${concat_cmds}$reload_cmds $objlist $last_robj\" if ${skipped_export-false}; then $show "generating symbol list for \`$libname.la'" export_symbols="$output_objdir/$libname.exp" $run $rm $export_symbols libobjs=$output # Append the command to create the export file. eval concat_cmds=\"\$concat_cmds~$export_symbols_cmds\" fi # Set up a command to remove the reloadable object files # after they are used. i=0 while test "$i" -lt "$k" do i=`expr $i + 1` delfiles="$delfiles $output_objdir/$output_la-${i}.$objext" done $echo "creating a temporary reloadable object file: $output" # Loop through the commands generated above and execute them. save_ifs="$IFS"; IFS='~' for cmd in $concat_cmds; do IFS="$save_ifs" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" libobjs=$output # Restore the value of output. output=$save_output if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then eval libobjs=\"\$libobjs $whole_archive_flag_spec\" fi # Expand the library linking commands again to reset the # value of $libobjs for piecewise linking. # Do each of the archive commands. if test "$module" = yes && test -n "$module_cmds" ; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then cmds=$module_expsym_cmds else cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then cmds=$archive_expsym_cmds else cmds=$archive_cmds fi fi # Append the command to remove the reloadable object files # to the just-reset $cmds. eval cmds=\"\$cmds~\$rm $delfiles\" fi save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}T && $mv ${realname}U $realname)' fi exit $lt_exit } done IFS="$save_ifs" # Restore the uninstalled library and exit if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}T && $mv $realname ${realname}T && $mv "$realname"U $realname)' || exit $? if test -n "$convenience"; then if test -z "$whole_archive_flag_spec"; then $show "${rm}r $gentop" $run ${rm}r "$gentop" fi fi exit $EXIT_SUCCESS fi # Create links to the real library. for linkname in $linknames; do if test "$realname" != "$linkname"; then $show "(cd $output_objdir && $rm $linkname && $LN_S $realname $linkname)" $run eval '(cd $output_objdir && $rm $linkname && $LN_S $realname $linkname)' || exit $? fi done # If -module or -export-dynamic was specified, set the dlname. if test "$module" = yes || test "$export_dynamic" = yes; then # On all known operating systems, these are identical. dlname="$soname" fi fi ;; obj) case " $deplibs" in *\ -l* | *\ -L*) $echo "$modename: warning: \`-l' and \`-L' are ignored for objects" 1>&2 ;; esac if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then $echo "$modename: warning: \`-dlopen' is ignored for objects" 1>&2 fi if test -n "$rpath"; then $echo "$modename: warning: \`-rpath' is ignored for objects" 1>&2 fi if test -n "$xrpath"; then $echo "$modename: warning: \`-R' is ignored for objects" 1>&2 fi if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info' is ignored for objects" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for objects" 1>&2 fi case $output in *.lo) if test -n "$objs$old_deplibs"; then $echo "$modename: cannot build library object \`$output' from non-libtool objects" 1>&2 exit $EXIT_FAILURE fi libobj="$output" obj=`$echo "X$output" | $Xsed -e "$lo2o"` ;; *) libobj= obj="$output" ;; esac # Delete the old objects. $run $rm $obj $libobj # Objects from convenience libraries. This assumes # single-version convenience libraries. Whenever we create # different ones for PIC/non-PIC, this we'll have to duplicate # the extraction. reload_conv_objs= gentop= # reload_cmds runs $LD directly, so let us get rid of # -Wl from whole_archive_flag_spec and hope we can get by with # turning comma into space.. wl= if test -n "$convenience"; then if test -n "$whole_archive_flag_spec"; then eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" reload_conv_objs=$reload_objs\ `$echo "X$tmp_whole_archive_flags" | $Xsed -e 's|,| |g'` else gentop="$output_objdir/${obj}x" generated="$generated $gentop" func_extract_archives $gentop $convenience reload_conv_objs="$reload_objs $func_extract_archives_result" fi fi # Create the old-style object. reload_objs="$objs$old_deplibs "`$echo "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}$'/d' -e '/\.lib$/d' -e "$lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test output="$obj" cmds=$reload_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" # Exit if we aren't doing a library object file. if test -z "$libobj"; then if test -n "$gentop"; then $show "${rm}r $gentop" $run ${rm}r $gentop fi exit $EXIT_SUCCESS fi if test "$build_libtool_libs" != yes; then if test -n "$gentop"; then $show "${rm}r $gentop" $run ${rm}r $gentop fi # Create an invalid libtool object if no PIC, so that we don't # accidentally link it into a program. # $show "echo timestamp > $libobj" # $run eval "echo timestamp > $libobj" || exit $? exit $EXIT_SUCCESS fi if test -n "$pic_flag" || test "$pic_mode" != default; then # Only do commands if we really have different PIC objects. reload_objs="$libobjs $reload_conv_objs" output="$libobj" cmds=$reload_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" fi if test -n "$gentop"; then $show "${rm}r $gentop" $run ${rm}r $gentop fi exit $EXIT_SUCCESS ;; prog) case $host in *cygwin*) output=`$echo $output | ${SED} -e 's,.exe$,,;s,$,.exe,'` ;; esac if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info' is ignored for programs" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for programs" 1>&2 fi if test "$preload" = yes; then if test "$dlopen_support" = unknown && test "$dlopen_self" = unknown && test "$dlopen_self_static" = unknown; then $echo "$modename: warning: \`AC_LIBTOOL_DLOPEN' not used. Assuming no dlopen support." fi fi case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library is the System framework compile_deplibs=`$echo "X $compile_deplibs" | $Xsed -e 's/ -lc / -framework System /'` finalize_deplibs=`$echo "X $finalize_deplibs" | $Xsed -e 's/ -lc / -framework System /'` ;; esac case $host in *darwin*) # Don't allow lazy linking, it breaks C++ global constructors if test "$tagname" = CXX ; then compile_command="$compile_command ${wl}-bind_at_load" finalize_command="$finalize_command ${wl}-bind_at_load" fi ;; esac # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $compile_deplibs " in *" -L$path/$objdir "*) new_libs="$new_libs -L$path/$objdir" ;; esac ;; esac done for deplib in $compile_deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$new_libs $deplib" ;; esac ;; *) new_libs="$new_libs $deplib" ;; esac done compile_deplibs="$new_libs" compile_command="$compile_command $compile_deplibs" finalize_command="$finalize_command $finalize_deplibs" if test -n "$rpath$xrpath"; then # If the user specified any rpath flags, then add them. for libdir in $rpath $xrpath; do # This is the magic to use -rpath. case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" ;; esac done fi # Now hardcode the library paths rpath= hardcode_libdirs= for libdir in $compile_rpath $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs="$libdir" else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" rpath="$rpath $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) perm_rpath="$perm_rpath $libdir" ;; esac fi case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) testbindir=`$echo "X$libdir" | $Xsed -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$libdir:"*) ;; *) dllsearchpath="$dllsearchpath:$libdir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; *) dllsearchpath="$dllsearchpath:$testbindir";; esac ;; esac done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir="$hardcode_libdirs" eval rpath=\" $hardcode_libdir_flag_spec\" fi compile_rpath="$rpath" rpath= hardcode_libdirs= for libdir in $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs="$libdir" else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" rpath="$rpath $flag" fi elif test -n "$runpath_var"; then case "$finalize_perm_rpath " in *" $libdir "*) ;; *) finalize_perm_rpath="$finalize_perm_rpath $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir="$hardcode_libdirs" eval rpath=\" $hardcode_libdir_flag_spec\" fi finalize_rpath="$rpath" if test -n "$libobjs" && test "$build_old_libs" = yes; then # Transform all the library objects into standard objects. compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` fi dlsyms= if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then if test -n "$NM" && test -n "$global_symbol_pipe"; then dlsyms="${outputname}S.c" else $echo "$modename: not configured to extract global symbols from dlpreopened files" 1>&2 fi fi if test -n "$dlsyms"; then case $dlsyms in "") ;; *.c) # Discover the nlist of each of the dlfiles. nlist="$output_objdir/${outputname}.nm" $show "$rm $nlist ${nlist}S ${nlist}T" $run $rm "$nlist" "${nlist}S" "${nlist}T" # Parse the name list into a source file. $show "creating $output_objdir/$dlsyms" test -z "$run" && $echo > "$output_objdir/$dlsyms" "\ /* $dlsyms - symbol resolution table for \`$outputname' dlsym emulation. */ /* Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP */ #ifdef __cplusplus extern \"C\" { #endif /* Prevent the only kind of declaration conflicts we can make. */ #define lt_preloaded_symbols some_other_symbol /* External symbol declarations for the compiler. */\ " if test "$dlself" = yes; then $show "generating symbol list for \`$output'" test -z "$run" && $echo ': @PROGRAM@ ' > "$nlist" # Add our own program objects to the symbol list. progfiles=`$echo "X$objs$old_deplibs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` for arg in $progfiles; do $show "extracting global C symbols from \`$arg'" $run eval "$NM $arg | $global_symbol_pipe >> '$nlist'" done if test -n "$exclude_expsyms"; then $run eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' $run eval '$mv "$nlist"T "$nlist"' fi if test -n "$export_symbols_regex"; then $run eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' $run eval '$mv "$nlist"T "$nlist"' fi # Prepare the list of exported symbols if test -z "$export_symbols"; then export_symbols="$output_objdir/$outputname.exp" $run $rm $export_symbols $run eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' case $host in *cygwin* | *mingw* ) $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' $run eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' ;; esac else $run eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' $run eval 'grep -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' $run eval 'mv "$nlist"T "$nlist"' case $host in *cygwin* | *mingw* ) $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' $run eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' ;; esac fi fi for arg in $dlprefiles; do $show "extracting global C symbols from \`$arg'" name=`$echo "$arg" | ${SED} -e 's%^.*/%%'` $run eval '$echo ": $name " >> "$nlist"' $run eval "$NM $arg | $global_symbol_pipe >> '$nlist'" done if test -z "$run"; then # Make sure we have at least an empty file. test -f "$nlist" || : > "$nlist" if test -n "$exclude_expsyms"; then $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T $mv "$nlist"T "$nlist" fi # Try sorting and uniquifying the output. if grep -v "^: " < "$nlist" | if sort -k 3 /dev/null 2>&1; then sort -k 3 else sort +2 fi | uniq > "$nlist"S; then : else grep -v "^: " < "$nlist" > "$nlist"S fi if test -f "$nlist"S; then eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$dlsyms"' else $echo '/* NONE */' >> "$output_objdir/$dlsyms" fi $echo >> "$output_objdir/$dlsyms" "\ #undef lt_preloaded_symbols #if defined (__STDC__) && __STDC__ # define lt_ptr void * #else # define lt_ptr char * # define const #endif /* The mapping between symbol names and symbols. */ " case $host in *cygwin* | *mingw* ) $echo >> "$output_objdir/$dlsyms" "\ /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs */ struct { " ;; * ) $echo >> "$output_objdir/$dlsyms" "\ const struct { " ;; esac $echo >> "$output_objdir/$dlsyms" "\ const char *name; lt_ptr address; } lt_preloaded_symbols[] = {\ " eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$dlsyms" $echo >> "$output_objdir/$dlsyms" "\ {0, (lt_ptr) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt_preloaded_symbols; } #endif #ifdef __cplusplus } #endif\ " fi pic_flag_for_symtable= case $host in # compiling the symbol table file with pic_flag works around # a FreeBSD bug that causes programs to crash when -lm is # linked before any other PIC object. But we must not use # pic_flag when linking with -static. The problem exists in # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. *-*-freebsd2*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) case "$compile_command " in *" -static "*) ;; *) pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND";; esac;; *-*-hpux*) case "$compile_command " in *" -static "*) ;; *) pic_flag_for_symtable=" $pic_flag";; esac esac # Now compile the dynamic symbol file. $show "(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")" $run eval '(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $? # Clean up the generated files. $show "$rm $output_objdir/$dlsyms $nlist ${nlist}S ${nlist}T" $run $rm "$output_objdir/$dlsyms" "$nlist" "${nlist}S" "${nlist}T" # Transform the symbol file into the correct name. case $host in *cygwin* | *mingw* ) if test -f "$output_objdir/${outputname}.def" ; then compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%" | $NL2SP` else compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` fi ;; * ) compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` ;; esac ;; *) $echo "$modename: unknown suffix for \`$dlsyms'" 1>&2 exit $EXIT_FAILURE ;; esac else # We keep going just in case the user didn't refer to # lt_preloaded_symbols. The linker will fail if global_symbol_pipe # really was required. # Nullify the symbol file. compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s% @SYMFILE@%%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s% @SYMFILE@%%" | $NL2SP` fi if test "$need_relink" = no || test "$build_libtool_libs" != yes; then # Replace the output file specification. compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e 's%@OUTPUT@%'"$output"'%g' | $NL2SP` link_command="$compile_command$compile_rpath" # We have no uninstalled library dependencies, so finalize right now. $show "$link_command" $run eval "$link_command" exit_status=$? # Delete the generated files. if test -n "$dlsyms"; then $show "$rm $output_objdir/${outputname}S.${objext}" $run $rm "$output_objdir/${outputname}S.${objext}" fi exit $exit_status fi if test -n "$shlibpath_var"; then # We should set the shlibpath_var rpath= for dir in $temp_rpath; do case $dir in [\\/]* | [A-Za-z]:[\\/]*) # Absolute path. rpath="$rpath$dir:" ;; *) # Relative path: add a thisdir entry. rpath="$rpath\$thisdir/$dir:" ;; esac done temp_rpath="$rpath" fi if test -n "$compile_shlibpath$finalize_shlibpath"; then compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" fi if test -n "$finalize_shlibpath"; then finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" fi compile_var= finalize_var= if test -n "$runpath_var"; then if test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do rpath="$rpath$dir:" done compile_var="$runpath_var=\"$rpath\$$runpath_var\" " fi if test -n "$finalize_perm_rpath"; then # We should set the runpath_var. rpath= for dir in $finalize_perm_rpath; do rpath="$rpath$dir:" done finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " fi fi if test "$no_install" = yes; then # We don't need to create a wrapper script. link_command="$compile_var$compile_command$compile_rpath" # Replace the output file specification. link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` # Delete the old output file. $run $rm $output # Link the executable and exit $show "$link_command" $run eval "$link_command" || exit $? exit $EXIT_SUCCESS fi if test "$hardcode_action" = relink; then # Fast installation is not supported link_command="$compile_var$compile_command$compile_rpath" relink_command="$finalize_var$finalize_command$finalize_rpath" $echo "$modename: warning: this platform does not like uninstalled shared libraries" 1>&2 $echo "$modename: \`$output' will be relinked during installation" 1>&2 else if test "$fast_install" != no; then link_command="$finalize_var$compile_command$finalize_rpath" if test "$fast_install" = yes; then relink_command=`$echo "X$compile_var$compile_command$compile_rpath" | $SP2NL | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g' | $NL2SP` else # fast_install is set to needless relink_command= fi else link_command="$compile_var$compile_command$compile_rpath" relink_command="$finalize_var$finalize_command$finalize_rpath" fi fi # Replace the output file specification. link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` # Delete the old output files. $run $rm $output $output_objdir/$outputname $output_objdir/lt-$outputname $show "$link_command" $run eval "$link_command" || exit $? # Now create the wrapper script. $show "creating $output" # Quote the relink command for shipping. if test -n "$relink_command"; then # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else var_value=`$echo "X$var_value" | $Xsed -e "$sed_quote_subst"` relink_command="$var=\"$var_value\"; export $var; $relink_command" fi done relink_command="(cd `pwd`; $relink_command)" relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e "$sed_quote_subst" | $NL2SP` fi # Quote $echo for shipping. if test "X$echo" = "X$SHELL $progpath --fallback-echo"; then case $progpath in [\\/]* | [A-Za-z]:[\\/]*) qecho="$SHELL $progpath --fallback-echo";; *) qecho="$SHELL `pwd`/$progpath --fallback-echo";; esac qecho=`$echo "X$qecho" | $Xsed -e "$sed_quote_subst"` else qecho=`$echo "X$echo" | $Xsed -e "$sed_quote_subst"` fi # Only actually do things if our run command is non-null. if test -z "$run"; then # win32 will think the script is a binary if it has # a .exe suffix, so we strip it off here. case $output in *.exe) output=`$echo $output|${SED} 's,.exe$,,'` ;; esac # test for cygwin because mv fails w/o .exe extensions case $host in *cygwin*) exeext=.exe outputname=`$echo $outputname|${SED} 's,.exe$,,'` ;; *) exeext= ;; esac case $host in *cygwin* | *mingw* ) output_name=`basename $output` output_path=`dirname $output` cwrappersource="$output_path/$objdir/lt-$output_name.c" cwrapper="$output_path/$output_name.exe" $rm $cwrappersource $cwrapper trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 cat > $cwrappersource <> $cwrappersource<<"EOF" #include #include #include #include #include #include #include #include #include #if defined(PATH_MAX) # define LT_PATHMAX PATH_MAX #elif defined(MAXPATHLEN) # define LT_PATHMAX MAXPATHLEN #else # define LT_PATHMAX 1024 #endif #ifndef DIR_SEPARATOR # define DIR_SEPARATOR '/' # define PATH_SEPARATOR ':' #endif #if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ defined (__OS2__) # define HAVE_DOS_BASED_FILE_SYSTEM # ifndef DIR_SEPARATOR_2 # define DIR_SEPARATOR_2 '\\' # endif # ifndef PATH_SEPARATOR_2 # define PATH_SEPARATOR_2 ';' # endif #endif #ifndef DIR_SEPARATOR_2 # define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) #else /* DIR_SEPARATOR_2 */ # define IS_DIR_SEPARATOR(ch) \ (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) #endif /* DIR_SEPARATOR_2 */ #ifndef PATH_SEPARATOR_2 # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) #else /* PATH_SEPARATOR_2 */ # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) #endif /* PATH_SEPARATOR_2 */ #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) #define XFREE(stale) do { \ if (stale) { free ((void *) stale); stale = 0; } \ } while (0) /* -DDEBUG is fairly common in CFLAGS. */ #undef DEBUG #if defined DEBUGWRAPPER # define DEBUG(format, ...) fprintf(stderr, format, __VA_ARGS__) #else # define DEBUG(format, ...) #endif const char *program_name = NULL; void * xmalloc (size_t num); char * xstrdup (const char *string); const char * base_name (const char *name); char * find_executable(const char *wrapper); int check_executable(const char *path); char * strendzap(char *str, const char *pat); void lt_fatal (const char *message, ...); int main (int argc, char *argv[]) { char **newargz; int i; program_name = (char *) xstrdup (base_name (argv[0])); DEBUG("(main) argv[0] : %s\n",argv[0]); DEBUG("(main) program_name : %s\n",program_name); newargz = XMALLOC(char *, argc+2); EOF cat >> $cwrappersource <> $cwrappersource <<"EOF" newargz[1] = find_executable(argv[0]); if (newargz[1] == NULL) lt_fatal("Couldn't find %s", argv[0]); DEBUG("(main) found exe at : %s\n",newargz[1]); /* we know the script has the same name, without the .exe */ /* so make sure newargz[1] doesn't end in .exe */ strendzap(newargz[1],".exe"); for (i = 1; i < argc; i++) newargz[i+1] = xstrdup(argv[i]); newargz[argc+1] = NULL; for (i=0; i> $cwrappersource <> $cwrappersource <> $cwrappersource <<"EOF" return 127; } void * xmalloc (size_t num) { void * p = (void *) malloc (num); if (!p) lt_fatal ("Memory exhausted"); return p; } char * xstrdup (const char *string) { return string ? strcpy ((char *) xmalloc (strlen (string) + 1), string) : NULL ; } const char * base_name (const char *name) { const char *base; #if defined (HAVE_DOS_BASED_FILE_SYSTEM) /* Skip over the disk name in MSDOS pathnames. */ if (isalpha ((unsigned char)name[0]) && name[1] == ':') name += 2; #endif for (base = name; *name; name++) if (IS_DIR_SEPARATOR (*name)) base = name + 1; return base; } int check_executable(const char * path) { struct stat st; DEBUG("(check_executable) : %s\n", path ? (*path ? path : "EMPTY!") : "NULL!"); if ((!path) || (!*path)) return 0; if ((stat (path, &st) >= 0) && ( /* MinGW & native WIN32 do not support S_IXOTH or S_IXGRP */ #if defined (S_IXOTH) ((st.st_mode & S_IXOTH) == S_IXOTH) || #endif #if defined (S_IXGRP) ((st.st_mode & S_IXGRP) == S_IXGRP) || #endif ((st.st_mode & S_IXUSR) == S_IXUSR)) ) return 1; else return 0; } /* Searches for the full path of the wrapper. Returns newly allocated full path name if found, NULL otherwise */ char * find_executable (const char* wrapper) { int has_slash = 0; const char* p; const char* p_next; /* static buffer for getcwd */ char tmp[LT_PATHMAX + 1]; int tmp_len; char* concat_name; DEBUG("(find_executable) : %s\n", wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!"); if ((wrapper == NULL) || (*wrapper == '\0')) return NULL; /* Absolute path? */ #if defined (HAVE_DOS_BASED_FILE_SYSTEM) if (isalpha ((unsigned char)wrapper[0]) && wrapper[1] == ':') { concat_name = xstrdup (wrapper); if (check_executable(concat_name)) return concat_name; XFREE(concat_name); } else { #endif if (IS_DIR_SEPARATOR (wrapper[0])) { concat_name = xstrdup (wrapper); if (check_executable(concat_name)) return concat_name; XFREE(concat_name); } #if defined (HAVE_DOS_BASED_FILE_SYSTEM) } #endif for (p = wrapper; *p; p++) if (*p == '/') { has_slash = 1; break; } if (!has_slash) { /* no slashes; search PATH */ const char* path = getenv ("PATH"); if (path != NULL) { for (p = path; *p; p = p_next) { const char* q; size_t p_len; for (q = p; *q; q++) if (IS_PATH_SEPARATOR(*q)) break; p_len = q - p; p_next = (*q == '\0' ? q : q + 1); if (p_len == 0) { /* empty path: current directory */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal ("getcwd failed"); tmp_len = strlen(tmp); concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); } else { concat_name = XMALLOC(char, p_len + 1 + strlen(wrapper) + 1); memcpy (concat_name, p, p_len); concat_name[p_len] = '/'; strcpy (concat_name + p_len + 1, wrapper); } if (check_executable(concat_name)) return concat_name; XFREE(concat_name); } } /* not found in PATH; assume curdir */ } /* Relative path | not found in path: prepend cwd */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal ("getcwd failed"); tmp_len = strlen(tmp); concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); if (check_executable(concat_name)) return concat_name; XFREE(concat_name); return NULL; } char * strendzap(char *str, const char *pat) { size_t len, patlen; assert(str != NULL); assert(pat != NULL); len = strlen(str); patlen = strlen(pat); if (patlen <= len) { str += len - patlen; if (strcmp(str, pat) == 0) *str = '\0'; } return str; } static void lt_error_core (int exit_status, const char * mode, const char * message, va_list ap) { fprintf (stderr, "%s: %s: ", program_name, mode); vfprintf (stderr, message, ap); fprintf (stderr, ".\n"); if (exit_status >= 0) exit (exit_status); } void lt_fatal (const char *message, ...) { va_list ap; va_start (ap, message); lt_error_core (EXIT_FAILURE, "FATAL", message, ap); va_end (ap); } EOF # we should really use a build-platform specific compiler # here, but OTOH, the wrappers (shell script and this C one) # are only useful if you want to execute the "real" binary. # Since the "real" binary is built for $host, then this # wrapper might as well be built for $host, too. $run $LTCC $LTCFLAGS -s -o $cwrapper $cwrappersource ;; esac $rm $output trap "$rm $output; exit $EXIT_FAILURE" 1 2 15 $echo > $output "\ #! $SHELL # $output - temporary wrapper script for $objdir/$outputname # Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP # # The $output program cannot be directly executed until all the libtool # libraries that it depends on are installed. # # This wrapper script should never be moved out of the build directory. # If it is, it will not operate correctly. # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. Xsed='${SED} -e 1s/^X//' sed_quote_subst='$sed_quote_subst' # Be Bourne compatible (taken from Autoconf:_AS_BOURNE_COMPATIBLE). if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac fi BIN_SH=xpg4; export BIN_SH # for Tru64 DUALCASE=1; export DUALCASE # for MKS sh # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH relink_command=\"$relink_command\" # This environment variable determines our operation mode. if test \"\$libtool_install_magic\" = \"$magic\"; then # install mode needs the following variable: notinst_deplibs='$notinst_deplibs' else # When we are sourced in execute mode, \$file and \$echo are already set. if test \"\$libtool_execute_magic\" != \"$magic\"; then echo=\"$qecho\" file=\"\$0\" # Make sure echo works. if test \"X\$1\" = X--no-reexec; then # Discard the --no-reexec flag, and continue. shift elif test \"X\`(\$echo '\t') 2>/dev/null\`\" = 'X\t'; then # Yippee, \$echo works! : else # Restart under the correct shell, and then maybe \$echo will work. exec $SHELL \"\$0\" --no-reexec \${1+\"\$@\"} fi fi\ " $echo >> $output "\ # Find the directory that this script lives in. thisdir=\`\$echo \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\` test \"x\$thisdir\" = \"x\$file\" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=\`ls -ld \"\$file\" | ${SED} -n 's/.*-> //p'\` while test -n \"\$file\"; do destdir=\`\$echo \"X\$file\" | \$Xsed -e 's%/[^/]*\$%%'\` # If there was a directory component, then change thisdir. if test \"x\$destdir\" != \"x\$file\"; then case \"\$destdir\" in [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; *) thisdir=\"\$thisdir/\$destdir\" ;; esac fi file=\`\$echo \"X\$file\" | \$Xsed -e 's%^.*/%%'\` file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\` done # Try to get the absolute directory name. absdir=\`cd \"\$thisdir\" && pwd\` test -n \"\$absdir\" && thisdir=\"\$absdir\" " if test "$fast_install" = yes; then $echo >> $output "\ program=lt-'$outputname'$exeext progdir=\"\$thisdir/$objdir\" if test ! -f \"\$progdir/\$program\" || \\ { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ test \"X\$file\" != \"X\$progdir/\$program\"; }; then file=\"\$\$-\$program\" if test ! -d \"\$progdir\"; then $mkdir \"\$progdir\" else $rm \"\$progdir/\$file\" fi" $echo >> $output "\ # relink executable if necessary if test -n \"\$relink_command\"; then if relink_command_output=\`eval \$relink_command 2>&1\`; then : else $echo \"\$relink_command_output\" >&2 $rm \"\$progdir/\$file\" exit $EXIT_FAILURE fi fi $mv \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || { $rm \"\$progdir/\$program\"; $mv \"\$progdir/\$file\" \"\$progdir/\$program\"; } $rm \"\$progdir/\$file\" fi" else $echo >> $output "\ program='$outputname' progdir=\"\$thisdir/$objdir\" " fi $echo >> $output "\ if test -f \"\$progdir/\$program\"; then" # Export our shlibpath_var if we have one. if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then $echo >> $output "\ # Add our own library path to $shlibpath_var $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" # Some systems cannot cope with colon-terminated $shlibpath_var # The second colon is a workaround for a bug in BeOS R4 sed $shlibpath_var=\`\$echo \"X\$$shlibpath_var\" | \$Xsed -e 's/::*\$//'\` export $shlibpath_var " fi # fixup the dll searchpath if we need to. if test -n "$dllsearchpath"; then $echo >> $output "\ # Add the dll search path components to the executable PATH PATH=$dllsearchpath:\$PATH " fi $echo >> $output "\ if test \"\$libtool_execute_magic\" != \"$magic\"; then # Run the actual program with our arguments. " case $host in # Backslashes separate directories on plain windows *-*-mingw | *-*-os2*) $echo >> $output "\ exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} " ;; *) $echo >> $output "\ exec \"\$progdir/\$program\" \${1+\"\$@\"} " ;; esac $echo >> $output "\ \$echo \"\$0: cannot exec \$program \$*\" exit $EXIT_FAILURE fi else # The program doesn't exist. \$echo \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 \$echo \"This script is just a wrapper for \$program.\" 1>&2 $echo \"See the $PACKAGE documentation for more information.\" 1>&2 exit $EXIT_FAILURE fi fi\ " chmod +x $output fi exit $EXIT_SUCCESS ;; esac # See if we need to build an old-fashioned archive. for oldlib in $oldlibs; do if test "$build_libtool_libs" = convenience; then oldobjs="$libobjs_save" addlibs="$convenience" build_libtool_libs=no else if test "$build_libtool_libs" = module; then oldobjs="$libobjs_save" build_libtool_libs=no else oldobjs="$old_deplibs $non_pic_objects" fi addlibs="$old_convenience" fi if test -n "$addlibs"; then gentop="$output_objdir/${outputname}x" generated="$generated $gentop" func_extract_archives $gentop $addlibs oldobjs="$oldobjs $func_extract_archives_result" fi # Do each command in the archive commands. if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then cmds=$old_archive_from_new_cmds else # POSIX demands no paths to be encoded in archives. We have # to avoid creating archives with duplicate basenames if we # might have to extract them afterwards, e.g., when creating a # static archive out of a convenience library, or when linking # the entirety of a libtool archive into another (currently # not supported by libtool). if (for obj in $oldobjs do $echo "X$obj" | $Xsed -e 's%^.*/%%' done | sort | sort -uc >/dev/null 2>&1); then : else $echo "copying selected object files to avoid basename conflicts..." if test -z "$gentop"; then gentop="$output_objdir/${outputname}x" generated="$generated $gentop" $show "${rm}r $gentop" $run ${rm}r "$gentop" $show "$mkdir $gentop" $run $mkdir "$gentop" exit_status=$? if test "$exit_status" -ne 0 && test ! -d "$gentop"; then exit $exit_status fi fi save_oldobjs=$oldobjs oldobjs= counter=1 for obj in $save_oldobjs do objbase=`$echo "X$obj" | $Xsed -e 's%^.*/%%'` case " $oldobjs " in " ") oldobjs=$obj ;; *[\ /]"$objbase "*) while :; do # Make sure we don't pick an alternate name that also # overlaps. newobj=lt$counter-$objbase counter=`expr $counter + 1` case " $oldobjs " in *[\ /]"$newobj "*) ;; *) if test ! -f "$gentop/$newobj"; then break; fi ;; esac done $show "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" $run ln "$obj" "$gentop/$newobj" || $run cp "$obj" "$gentop/$newobj" oldobjs="$oldobjs $gentop/$newobj" ;; *) oldobjs="$oldobjs $obj" ;; esac done fi eval cmds=\"$old_archive_cmds\" if len=`expr "X$cmds" : ".*"` && test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then cmds=$old_archive_cmds else # the command line is too long to link in one step, link in parts $echo "using piecewise archive linking..." save_RANLIB=$RANLIB RANLIB=: objlist= concat_cmds= save_oldobjs=$oldobjs # Is there a better way of finding the last object in the list? for obj in $save_oldobjs do last_oldobj=$obj done for obj in $save_oldobjs do oldobjs="$objlist $obj" objlist="$objlist $obj" eval test_cmds=\"$old_archive_cmds\" if len=`expr "X$test_cmds" : ".*" 2>/dev/null` && test "$len" -le "$max_cmd_len"; then : else # the above command should be used before it gets too long oldobjs=$objlist if test "$obj" = "$last_oldobj" ; then RANLIB=$save_RANLIB fi test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" objlist= fi done RANLIB=$save_RANLIB oldobjs=$objlist if test "X$oldobjs" = "X" ; then eval cmds=\"\$concat_cmds\" else eval cmds=\"\$concat_cmds~\$old_archive_cmds\" fi fi fi save_ifs="$IFS"; IFS='~' for cmd in $cmds; do eval cmd=\"$cmd\" IFS="$save_ifs" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" done if test -n "$generated"; then $show "${rm}r$generated" $run ${rm}r$generated fi # Now create the libtool archive. case $output in *.la) old_library= test "$build_old_libs" = yes && old_library="$libname.$libext" $show "creating $output" # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else var_value=`$echo "X$var_value" | $Xsed -e "$sed_quote_subst"` relink_command="$var=\"$var_value\"; export $var; $relink_command" fi done # Quote the link command for shipping. relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e "$sed_quote_subst" | $NL2SP` if test "$hardcode_automatic" = yes ; then relink_command= fi # Only create the output if not a dry run. if test -z "$run"; then for installed in no yes; do if test "$installed" = yes; then if test -z "$install_libdir"; then break fi output="$output_objdir/$outputname"i # Replace all uninstalled libtool libraries with the installed ones newdependency_libs= for deplib in $dependency_libs; do case $deplib in *.la) name=`$echo "X$deplib" | $Xsed -e 's%^.*/%%'` eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` if test -z "$libdir"; then $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi newdependency_libs="$newdependency_libs $libdir/$name" ;; *) newdependency_libs="$newdependency_libs $deplib" ;; esac done dependency_libs="$newdependency_libs" newdlfiles= for lib in $dlfiles; do name=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` if test -z "$libdir"; then $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi newdlfiles="$newdlfiles $libdir/$name" done dlfiles="$newdlfiles" newdlprefiles= for lib in $dlprefiles; do name=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` if test -z "$libdir"; then $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi newdlprefiles="$newdlprefiles $libdir/$name" done dlprefiles="$newdlprefiles" else newdlfiles= for lib in $dlfiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; *) abs=`pwd`"/$lib" ;; esac newdlfiles="$newdlfiles $abs" done dlfiles="$newdlfiles" newdlprefiles= for lib in $dlprefiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; *) abs=`pwd`"/$lib" ;; esac newdlprefiles="$newdlprefiles $abs" done dlprefiles="$newdlprefiles" fi $rm $output # place dlname in correct position for cygwin tdlname=$dlname case $host,$output,$installed,$module,$dlname in *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;; esac $echo > $output "\ # $outputname - a libtool library file # Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP # # Please DO NOT delete this file! # It is necessary for linking the library. # The name that we can dlopen(3). dlname='$tdlname' # Names of this library. library_names='$library_names' # The name of the static archive. old_library='$old_library' # Libraries that this one depends upon. dependency_libs='$dependency_libs' # Version information for $libname. current=$current age=$age revision=$revision # Is this an already installed library? installed=$installed # Should we warn about portability when linking against -modules? shouldnotlink=$module # Files to dlopen/dlpreopen dlopen='$dlfiles' dlpreopen='$dlprefiles' # Directory that this library needs to be installed in: libdir='$install_libdir'" if test "$installed" = no && test "$need_relink" = yes; then $echo >> $output "\ relink_command=\"$relink_command\"" fi done fi # Do a symbolic link so that the libtool archive can be found in # LD_LIBRARY_PATH before the program is installed. $show "(cd $output_objdir && $rm $outputname && $LN_S ../$outputname $outputname)" $run eval '(cd $output_objdir && $rm $outputname && $LN_S ../$outputname $outputname)' || exit $? ;; esac exit $EXIT_SUCCESS ;; # libtool install mode install) modename="$modename: install" # There may be an optional sh(1) argument at the beginning of # install_prog (especially on Windows NT). if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || # Allow the use of GNU shtool's install command. $echo "X$nonopt" | grep shtool > /dev/null; then # Aesthetically quote it. arg=`$echo "X$nonopt" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac install_prog="$arg " arg="$1" shift else install_prog= arg=$nonopt fi # The real first argument should be the name of the installation program. # Aesthetically quote it. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac install_prog="$install_prog$arg" # We need to accept at least all the BSD install flags. dest= files= opts= prev= install_type= isdir=no stripme= for arg do if test -n "$dest"; then files="$files $dest" dest=$arg continue fi case $arg in -d) isdir=yes ;; -f) case " $install_prog " in *[\\\ /]cp\ *) ;; *) prev=$arg ;; esac ;; -g | -m | -o) prev=$arg ;; -s) stripme=" -s" continue ;; -*) ;; *) # If the previous option needed an argument, then skip it. if test -n "$prev"; then prev= else dest=$arg continue fi ;; esac # Aesthetically quote the argument. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac install_prog="$install_prog $arg" done if test -z "$install_prog"; then $echo "$modename: you must specify an install program" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test -n "$prev"; then $echo "$modename: the \`$prev' option requires an argument" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test -z "$files"; then if test -z "$dest"; then $echo "$modename: no file or destination specified" 1>&2 else $echo "$modename: you must specify a destination" 1>&2 fi $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Strip any trailing slash from the destination. dest=`$echo "X$dest" | $Xsed -e 's%/$%%'` # Check to see that the destination is a directory. test -d "$dest" && isdir=yes if test "$isdir" = yes; then destdir="$dest" destname= else destdir=`$echo "X$dest" | $Xsed -e 's%/[^/]*$%%'` test "X$destdir" = "X$dest" && destdir=. destname=`$echo "X$dest" | $Xsed -e 's%^.*/%%'` # Not a directory, so check to see that there is only one file specified. set dummy $files if test "$#" -gt 2; then $echo "$modename: \`$dest' is not a directory" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi fi case $destdir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) for file in $files; do case $file in *.lo) ;; *) $echo "$modename: \`$destdir' must be an absolute directory name" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; esac done ;; esac # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic="$magic" staticlibs= future_libdirs= current_libdirs= for file in $files; do # Do each installation. case $file in *.$libext) # Do the static libraries later. staticlibs="$staticlibs $file" ;; *.la) # Check to see that this really is a libtool archive. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : else $echo "$modename: \`$file' is not a valid libtool archive" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi library_names= old_library= relink_command= # If there is no directory component, then add one. case $file in */* | *\\*) . $file ;; *) . ./$file ;; esac # Add the libdir to current_libdirs if it is the destination. if test "X$destdir" = "X$libdir"; then case "$current_libdirs " in *" $libdir "*) ;; *) current_libdirs="$current_libdirs $libdir" ;; esac else # Note the libdir as a future libdir. case "$future_libdirs " in *" $libdir "*) ;; *) future_libdirs="$future_libdirs $libdir" ;; esac fi dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'`/ test "X$dir" = "X$file/" && dir= dir="$dir$objdir" if test -n "$relink_command"; then # Determine the prefix the user has applied to our future dir. inst_prefix_dir=`$echo "$destdir" | $SED "s%$libdir\$%%"` # Don't allow the user to place us outside of our expected # location b/c this prevents finding dependent libraries that # are installed to the same prefix. # At present, this check doesn't affect windows .dll's that # are installed into $libdir/../bin (currently, that works fine) # but it's something to keep an eye on. if test "$inst_prefix_dir" = "$destdir"; then $echo "$modename: error: cannot install \`$file' to a directory not ending in $libdir" 1>&2 exit $EXIT_FAILURE fi if test -n "$inst_prefix_dir"; then # Stick the inst_prefix_dir data into the link command. relink_command=`$echo "$relink_command" | $SP2NL | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%" | $NL2SP` else relink_command=`$echo "$relink_command" | $SP2NL | $SED "s%@inst_prefix_dir@%%" | $NL2SP` fi $echo "$modename: warning: relinking \`$file'" 1>&2 $show "$relink_command" if $run eval "$relink_command"; then : else $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 exit $EXIT_FAILURE fi fi # See the names of the shared library. set dummy $library_names if test -n "$2"; then realname="$2" shift shift srcname="$realname" test -n "$relink_command" && srcname="$realname"T # Install the shared library and build the symlinks. $show "$install_prog $dir/$srcname $destdir/$realname" $run eval "$install_prog $dir/$srcname $destdir/$realname" || exit $? if test -n "$stripme" && test -n "$striplib"; then $show "$striplib $destdir/$realname" $run eval "$striplib $destdir/$realname" || exit $? fi if test "$#" -gt 0; then # Delete the old symlinks, and create new ones. # Try `ln -sf' first, because the `ln' binary might depend on # the symlink we replace! Solaris /bin/ln does not understand -f, # so we also need to try rm && ln -s. for linkname do if test "$linkname" != "$realname"; then $show "(cd $destdir && { $LN_S -f $realname $linkname || { $rm $linkname && $LN_S $realname $linkname; }; })" $run eval "(cd $destdir && { $LN_S -f $realname $linkname || { $rm $linkname && $LN_S $realname $linkname; }; })" fi done fi # Do each command in the postinstall commands. lib="$destdir/$realname" cmds=$postinstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}T && $mv ${realname}U $realname)' fi exit $lt_exit } done IFS="$save_ifs" fi # Install the pseudo-library for information purposes. name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` instname="$dir/$name"i $show "$install_prog $instname $destdir/$name" $run eval "$install_prog $instname $destdir/$name" || exit $? # Maybe install the static library, too. test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" ;; *.lo) # Install (i.e. copy) a libtool object. # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile="$destdir/$destname" else destfile=`$echo "X$file" | $Xsed -e 's%^.*/%%'` destfile="$destdir/$destfile" fi # Deduce the name of the destination old-style object file. case $destfile in *.lo) staticdest=`$echo "X$destfile" | $Xsed -e "$lo2o"` ;; *.$objext) staticdest="$destfile" destfile= ;; *) $echo "$modename: cannot copy a libtool object to \`$destfile'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; esac # Install the libtool object if requested. if test -n "$destfile"; then $show "$install_prog $file $destfile" $run eval "$install_prog $file $destfile" || exit $? fi # Install the old object if enabled. if test "$build_old_libs" = yes; then # Deduce the name of the old-style object file. staticobj=`$echo "X$file" | $Xsed -e "$lo2o"` $show "$install_prog $staticobj $staticdest" $run eval "$install_prog \$staticobj \$staticdest" || exit $? fi exit $EXIT_SUCCESS ;; *) # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile="$destdir/$destname" else destfile=`$echo "X$file" | $Xsed -e 's%^.*/%%'` destfile="$destdir/$destfile" fi # If the file is missing, and there is a .exe on the end, strip it # because it is most likely a libtool script we actually want to # install stripped_ext="" case $file in *.exe) if test ! -f "$file"; then file=`$echo $file|${SED} 's,.exe$,,'` stripped_ext=".exe" fi ;; esac # Do a test to see if this is really a libtool program. case $host in *cygwin*|*mingw*) wrapper=`$echo $file | ${SED} -e 's,.exe$,,'` ;; *) wrapper=$file ;; esac if (${SED} -e '4q' $wrapper | grep "^# Generated by .*$PACKAGE")>/dev/null 2>&1; then notinst_deplibs= relink_command= # Note that it is not necessary on cygwin/mingw to append a dot to # foo even if both foo and FILE.exe exist: automatic-append-.exe # behavior happens only for exec(3), not for open(2)! Also, sourcing # `FILE.' does not work on cygwin managed mounts. # # If there is no directory component, then add one. case $wrapper in */* | *\\*) . ${wrapper} ;; *) . ./${wrapper} ;; esac # Check the variables that should have been set. if test -z "$notinst_deplibs"; then $echo "$modename: invalid libtool wrapper script \`$wrapper'" 1>&2 exit $EXIT_FAILURE fi finalize=yes for lib in $notinst_deplibs; do # Check to see that each library is installed. libdir= if test -f "$lib"; then # If there is no directory component, then add one. case $lib in */* | *\\*) . $lib ;; *) . ./$lib ;; esac fi libfile="$libdir/"`$echo "X$lib" | $Xsed -e 's%^.*/%%g'` ### testsuite: skip nested quoting test if test -n "$libdir" && test ! -f "$libfile"; then $echo "$modename: warning: \`$lib' has not been installed in \`$libdir'" 1>&2 finalize=no fi done relink_command= # Note that it is not necessary on cygwin/mingw to append a dot to # foo even if both foo and FILE.exe exist: automatic-append-.exe # behavior happens only for exec(3), not for open(2)! Also, sourcing # `FILE.' does not work on cygwin managed mounts. # # If there is no directory component, then add one. case $wrapper in */* | *\\*) . ${wrapper} ;; *) . ./${wrapper} ;; esac outputname= if test "$fast_install" = no && test -n "$relink_command"; then if test "$finalize" = yes && test -z "$run"; then tmpdir=`func_mktempdir` file=`$echo "X$file$stripped_ext" | $Xsed -e 's%^.*/%%'` outputname="$tmpdir/$file" # Replace the output file specification. relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g' | $NL2SP` $show "$relink_command" if $run eval "$relink_command"; then : else $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 ${rm}r "$tmpdir" continue fi file="$outputname" else $echo "$modename: warning: cannot relink \`$file'" 1>&2 fi else # Install the binary that we compiled earlier. file=`$echo "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"` fi fi # remove .exe since cygwin /usr/bin/install will append another # one anyway case $install_prog,$host in */usr/bin/install*,*cygwin*) case $file:$destfile in *.exe:*.exe) # this is ok ;; *.exe:*) destfile=$destfile.exe ;; *:*.exe) destfile=`$echo $destfile | ${SED} -e 's,.exe$,,'` ;; esac ;; esac $show "$install_prog$stripme $file $destfile" $run eval "$install_prog\$stripme \$file \$destfile" || exit $? test -n "$outputname" && ${rm}r "$tmpdir" ;; esac done for file in $staticlibs; do name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` # Set up the ranlib parameters. oldlib="$destdir/$name" $show "$install_prog $file $oldlib" $run eval "$install_prog \$file \$oldlib" || exit $? if test -n "$stripme" && test -n "$old_striplib"; then $show "$old_striplib $oldlib" $run eval "$old_striplib $oldlib" || exit $? fi # Do each command in the postinstall commands. cmds=$old_postinstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" done if test -n "$future_libdirs"; then $echo "$modename: warning: remember to run \`$progname --finish$future_libdirs'" 1>&2 fi if test -n "$current_libdirs"; then # Maybe just do a dry run. test -n "$run" && current_libdirs=" -n$current_libdirs" exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' else exit $EXIT_SUCCESS fi ;; # libtool finish mode finish) modename="$modename: finish" libdirs="$nonopt" admincmds= if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then for dir do libdirs="$libdirs $dir" done for libdir in $libdirs; do if test -n "$finish_cmds"; then # Do each command in the finish commands. cmds=$finish_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || admincmds="$admincmds $cmd" done IFS="$save_ifs" fi if test -n "$finish_eval"; then # Do the single finish_eval. eval cmds=\"$finish_eval\" $run eval "$cmds" || admincmds="$admincmds $cmds" fi done fi # Exit here if they wanted silent mode. test "$show" = : && exit $EXIT_SUCCESS $echo "X----------------------------------------------------------------------" | $Xsed $echo "Libraries have been installed in:" for libdir in $libdirs; do $echo " $libdir" done $echo $echo "If you ever happen to want to link against installed libraries" $echo "in a given directory, LIBDIR, you must either use libtool, and" $echo "specify the full pathname of the library, or use the \`-LLIBDIR'" $echo "flag during linking and do at least one of the following:" if test -n "$shlibpath_var"; then $echo " - add LIBDIR to the \`$shlibpath_var' environment variable" $echo " during execution" fi if test -n "$runpath_var"; then $echo " - add LIBDIR to the \`$runpath_var' environment variable" $echo " during linking" fi if test -n "$hardcode_libdir_flag_spec"; then libdir=LIBDIR eval flag=\"$hardcode_libdir_flag_spec\" $echo " - use the \`$flag' linker flag" fi if test -n "$admincmds"; then $echo " - have your system administrator run these commands:$admincmds" fi if test -f /etc/ld.so.conf; then $echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" fi $echo $echo "See any operating system documentation about shared libraries for" $echo "more information, such as the ld(1) and ld.so(8) manual pages." $echo "X----------------------------------------------------------------------" | $Xsed exit $EXIT_SUCCESS ;; # libtool execute mode execute) modename="$modename: execute" # The first argument is the command name. cmd="$nonopt" if test -z "$cmd"; then $echo "$modename: you must specify a COMMAND" 1>&2 $echo "$help" exit $EXIT_FAILURE fi # Handle -dlopen flags immediately. for file in $execute_dlfiles; do if test ! -f "$file"; then $echo "$modename: \`$file' is not a file" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi dir= case $file in *.la) # Check to see that this really is a libtool archive. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : else $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Read the libtool library. dlname= library_names= # If there is no directory component, then add one. case $file in */* | *\\*) . $file ;; *) . ./$file ;; esac # Skip this library if it cannot be dlopened. if test -z "$dlname"; then # Warn if it was a shared library. test -n "$library_names" && $echo "$modename: warning: \`$file' was not linked with \`-export-dynamic'" continue fi dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "X$dir" = "X$file" && dir=. if test -f "$dir/$objdir/$dlname"; then dir="$dir/$objdir" else if test ! -f "$dir/$dlname"; then $echo "$modename: cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" 1>&2 exit $EXIT_FAILURE fi fi ;; *.lo) # Just add the directory containing the .lo file. dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "X$dir" = "X$file" && dir=. ;; *) $echo "$modename: warning \`-dlopen' is ignored for non-libtool libraries and objects" 1>&2 continue ;; esac # Get the absolute pathname. absdir=`cd "$dir" && pwd` test -n "$absdir" && dir="$absdir" # Now add the directory to shlibpath_var. if eval "test -z \"\$$shlibpath_var\""; then eval "$shlibpath_var=\"\$dir\"" else eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" fi done # This variable tells wrapper scripts just to set shlibpath_var # rather than running their programs. libtool_execute_magic="$magic" # Check if any of the arguments is a wrapper script. args= for file do case $file in -*) ;; *) # Do a test to see if this is really a libtool program. if (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then # If there is no directory component, then add one. case $file in */* | *\\*) . $file ;; *) . ./$file ;; esac # Transform arg to wrapped name. file="$progdir/$program" fi ;; esac # Quote arguments (to preserve shell metacharacters). file=`$echo "X$file" | $Xsed -e "$sed_quote_subst"` args="$args \"$file\"" done if test -z "$run"; then if test -n "$shlibpath_var"; then # Export the shlibpath_var. eval "export $shlibpath_var" fi # Restore saved environment variables for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES do eval "if test \"\${save_$lt_var+set}\" = set; then $lt_var=\$save_$lt_var; export $lt_var fi" done # Now prepare to actually exec the command. exec_cmd="\$cmd$args" else # Display what would be done. if test -n "$shlibpath_var"; then eval "\$echo \"\$shlibpath_var=\$$shlibpath_var\"" $echo "export $shlibpath_var" fi $echo "$cmd$args" exit $EXIT_SUCCESS fi ;; # libtool clean and uninstall mode clean | uninstall) modename="$modename: $mode" rm="$nonopt" files= rmforce= exit_status=0 # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic="$magic" for arg do case $arg in -f) rm="$rm $arg"; rmforce=yes ;; -*) rm="$rm $arg" ;; *) files="$files $arg" ;; esac done if test -z "$rm"; then $echo "$modename: you must specify an RM program" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi rmdirs= origobjdir="$objdir" for file in $files; do dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` if test "X$dir" = "X$file"; then dir=. objdir="$origobjdir" else objdir="$dir/$origobjdir" fi name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` test "$mode" = uninstall && objdir="$dir" # Remember objdir for removal later, being careful to avoid duplicates if test "$mode" = clean; then case " $rmdirs " in *" $objdir "*) ;; *) rmdirs="$rmdirs $objdir" ;; esac fi # Don't error if the file doesn't exist and rm -f was used. if (test -L "$file") >/dev/null 2>&1 \ || (test -h "$file") >/dev/null 2>&1 \ || test -f "$file"; then : elif test -d "$file"; then exit_status=1 continue elif test "$rmforce" = yes; then continue fi rmfiles="$file" case $name in *.la) # Possibly a libtool archive, so verify it. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then . $dir/$name # Delete the libtool libraries and symlinks. for n in $library_names; do rmfiles="$rmfiles $objdir/$n" done test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" case "$mode" in clean) case " $library_names " in # " " in the beginning catches empty $dlname *" $dlname "*) ;; *) rmfiles="$rmfiles $objdir/$dlname" ;; esac test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" ;; uninstall) if test -n "$library_names"; then # Do each command in the postuninstall commands. cmds=$postuninstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" if test "$?" -ne 0 && test "$rmforce" != yes; then exit_status=1 fi done IFS="$save_ifs" fi if test -n "$old_library"; then # Do each command in the old_postuninstall commands. cmds=$old_postuninstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" if test "$?" -ne 0 && test "$rmforce" != yes; then exit_status=1 fi done IFS="$save_ifs" fi # FIXME: should reinstall the best remaining shared library. ;; esac fi ;; *.lo) # Possibly a libtool object, so verify it. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then # Read the .lo file . $dir/$name # Add PIC object to the list of files to remove. if test -n "$pic_object" \ && test "$pic_object" != none; then rmfiles="$rmfiles $dir/$pic_object" fi # Add non-PIC object to the list of files to remove. if test -n "$non_pic_object" \ && test "$non_pic_object" != none; then rmfiles="$rmfiles $dir/$non_pic_object" fi fi ;; *) if test "$mode" = clean ; then noexename=$name case $file in *.exe) file=`$echo $file|${SED} 's,.exe$,,'` noexename=`$echo $name|${SED} 's,.exe$,,'` # $file with .exe has already been added to rmfiles, # add $file without .exe rmfiles="$rmfiles $file" ;; esac # Do a test to see if this is a libtool program. if (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then relink_command= . $dir/$noexename # note $name still contains .exe if it was in $file originally # as does the version of $file that was added into $rmfiles rmfiles="$rmfiles $objdir/$name $objdir/${name}S.${objext}" if test "$fast_install" = yes && test -n "$relink_command"; then rmfiles="$rmfiles $objdir/lt-$name" fi if test "X$noexename" != "X$name" ; then rmfiles="$rmfiles $objdir/lt-${noexename}.c" fi fi fi ;; esac $show "$rm $rmfiles" $run $rm $rmfiles || exit_status=1 done objdir="$origobjdir" # Try to remove the ${objdir}s in the directories where we deleted files for dir in $rmdirs; do if test -d "$dir"; then $show "rmdir $dir" $run rmdir $dir >/dev/null 2>&1 fi done exit $exit_status ;; "") $echo "$modename: you must specify a MODE" 1>&2 $echo "$generic_help" 1>&2 exit $EXIT_FAILURE ;; esac if test -z "$exec_cmd"; then $echo "$modename: invalid operation mode \`$mode'" 1>&2 $echo "$generic_help" 1>&2 exit $EXIT_FAILURE fi fi # test -z "$show_help" if test -n "$exec_cmd"; then eval exec $exec_cmd exit $EXIT_FAILURE fi # We need to display help for each of the modes. case $mode in "") $echo \ "Usage: $modename [OPTION]... [MODE-ARG]... Provide generalized library-building support services. --config show all configuration variables --debug enable verbose shell tracing -n, --dry-run display commands without modifying any files --features display basic configuration information and exit --finish same as \`--mode=finish' --help display this help message and exit --mode=MODE use operation mode MODE [default=inferred from MODE-ARGS] --quiet same as \`--silent' --silent don't print informational messages --tag=TAG use configuration variables from tag TAG --version print version information MODE must be one of the following: clean remove files from the build directory compile compile a source file into a libtool object execute automatically set library path, then run a program finish complete the installation of libtool libraries install install libraries or executables link create a library or an executable uninstall remove libraries from an installed directory MODE-ARGS vary depending on the MODE. Try \`$modename --help --mode=MODE' for a more detailed description of MODE. Report bugs to ." exit $EXIT_SUCCESS ;; clean) $echo \ "Usage: $modename [OPTION]... --mode=clean RM [RM-OPTION]... FILE... Remove files from the build directory. RM is the name of the program to use to delete files associated with each FILE (typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed to RM. If FILE is a libtool library, object or program, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; compile) $echo \ "Usage: $modename [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE Compile a source file into a libtool library object. This mode accepts the following additional options: -o OUTPUT-FILE set the output file name to OUTPUT-FILE -prefer-pic try to building PIC objects only -prefer-non-pic try to building non-PIC objects only -static always build a \`.o' file suitable for static linking COMPILE-COMMAND is a command to be used in creating a \`standard' object file from the given SOURCEFILE. The output file name is determined by removing the directory component from SOURCEFILE, then substituting the C source code suffix \`.c' with the library object suffix, \`.lo'." ;; execute) $echo \ "Usage: $modename [OPTION]... --mode=execute COMMAND [ARGS]... Automatically set library path, then run a program. This mode accepts the following additional options: -dlopen FILE add the directory containing FILE to the library path This mode sets the library path environment variable according to \`-dlopen' flags. If any of the ARGS are libtool executable wrappers, then they are translated into their corresponding uninstalled binary, and any of their required library directories are added to the library path. Then, COMMAND is executed, with ARGS as arguments." ;; finish) $echo \ "Usage: $modename [OPTION]... --mode=finish [LIBDIR]... Complete the installation of libtool libraries. Each LIBDIR is a directory that contains libtool libraries. The commands that this mode executes may require superuser privileges. Use the \`--dry-run' option if you just want to see what would be executed." ;; install) $echo \ "Usage: $modename [OPTION]... --mode=install INSTALL-COMMAND... Install executables or libraries. INSTALL-COMMAND is the installation command. The first component should be either the \`install' or \`cp' program. The rest of the components are interpreted as arguments to that command (only BSD-compatible install options are recognized)." ;; link) $echo \ "Usage: $modename [OPTION]... --mode=link LINK-COMMAND... Link object files or libraries together to form another library, or to create an executable program. LINK-COMMAND is a command using the C compiler that you would use to create a program from several object files. The following components of LINK-COMMAND are treated specially: -all-static do not do any dynamic linking at all -avoid-version do not add a version suffix if possible -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) -export-symbols SYMFILE try to export only the symbols listed in SYMFILE -export-symbols-regex REGEX try to export only the symbols matching REGEX -LLIBDIR search LIBDIR for required installed libraries -lNAME OUTPUT-FILE requires the installed library libNAME -module build a library that can dlopened -no-fast-install disable the fast-install mode -no-install link a not-installable executable -no-undefined declare that a library does not refer to external symbols -o OUTPUT-FILE create OUTPUT-FILE from the specified objects -objectlist FILE Use a list of object files found in FILE to specify objects -precious-files-regex REGEX don't remove output files matching REGEX -release RELEASE specify package release information -rpath LIBDIR the created library will eventually be installed in LIBDIR -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries -static do not do any dynamic linking of uninstalled libtool libraries -static-libtool-libs do not do any dynamic linking of libtool libraries -version-info CURRENT[:REVISION[:AGE]] specify library version info [each variable defaults to 0] All other options (arguments beginning with \`-') are ignored. Every other argument is treated as a filename. Files ending in \`.la' are treated as uninstalled libtool libraries, other files are standard or library object files. If the OUTPUT-FILE ends in \`.la', then a libtool library is created, only library objects (\`.lo' files) may be specified, and \`-rpath' is required, except when creating a convenience library. If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created using \`ar' and \`ranlib', or on Windows using \`lib'. If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file is created, otherwise an executable program is created." ;; uninstall) $echo \ "Usage: $modename [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... Remove libraries from an installation directory. RM is the name of the program to use to delete files associated with each FILE (typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed to RM. If FILE is a libtool library, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; *) $echo "$modename: invalid operation mode \`$mode'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; esac $echo $echo "Try \`$modename --help' for more information about other modes." exit $? # The TAGs below are defined such that we never get into a situation # in which we disable both kinds of libraries. Given conflicting # choices, we go for a static library, that is the most portable, # since we can't tell whether shared libraries were disabled because # the user asked for that or because the platform doesn't support # them. This is particularly important on AIX, because we don't # support having both static and shared libraries enabled at the same # time on that platform, so we default to a shared-only configuration. # If a disable-shared tag is given, we'll fallback to a static-only # configuration. But we'll never go from static-only to shared-only. # ### BEGIN LIBTOOL TAG CONFIG: disable-shared disable_libs=shared # ### END LIBTOOL TAG CONFIG: disable-shared # ### BEGIN LIBTOOL TAG CONFIG: disable-static disable_libs=static # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: # mode:shell-script # sh-indentation:2 # End: tgif-QPL-4.2.5/rmcast/config/mkinstalldirs0000755000076400007640000000132511112562762020343 0ustar williamwilliam#! /bin/sh # mkinstalldirs --- make directory hierarchy # Author: Noah Friedman # Created: 1993-05-16 # Public domain # $Id: mkinstalldirs,v 1.4 2008/11/24 17:35:46 william Exp $ errstatus=0 for file do set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'` shift pathcomp= for d do pathcomp="$pathcomp$d" case "$pathcomp" in -* ) pathcomp=./$pathcomp ;; esac if test ! -d "$pathcomp"; then echo "mkdir $pathcomp" mkdir "$pathcomp" || lasterr=$? if test ! -d "$pathcomp"; then errstatus=$lasterr fi fi pathcomp="$pathcomp/" done done exit $errstatus # mkinstalldirs ends here tgif-QPL-4.2.5/rmcast/config/config.guess0000755000076400007640000012706111222706506020061 0ustar williamwilliam#! /bin/sh # Attempt to guess a canonical system name. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, # Inc. timestamp='2007-07-22' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA # 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Originally written by Per Bothner . # Please send patches to . Submit a context # diff and a properly formatted ChangeLog entry. # # This script attempts to guess a canonical system name similar to # config.sub. If it succeeds, it prints the system name on stdout, and # exits with 0. Otherwise, it exits with 1. # # The plan is that this can be called by configure scripts if you # don't specify an explicit build system type. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] Output the configuration name of the system \`$me' is run on. Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" >&2 exit 1 ;; * ) break ;; esac done if test $# != 0; then echo "$me: too many arguments$help" >&2 exit 1 fi trap 'exit 1' 1 2 15 # CC_FOR_BUILD -- compiler used by this script. Note that the use of a # compiler to aid in system detection is discouraged as it requires # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still # use `HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. set_cc_for_build=' trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; : ${TMPDIR=/tmp} ; { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; dummy=$tmp/dummy ; tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; case $CC_FOR_BUILD,$HOST_CC,$CC in ,,) echo "int x;" > $dummy.c ; for c in cc gcc c89 c99 ; do if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then CC_FOR_BUILD="$c"; break ; fi ; done ; if test x"$CC_FOR_BUILD" = x ; then CC_FOR_BUILD=no_compiler_found ; fi ;; ,,*) CC_FOR_BUILD=$CC ;; ,*,*) CC_FOR_BUILD=$HOST_CC ;; esac ; set_cc_for_build= ;' # This is needed to find uname on a Pyramid OSx when run in the BSD universe. # (ghazi@noc.rutgers.edu 1994-08-24) if (test -f /.attbin/uname) >/dev/null 2>&1 ; then PATH=$PATH:/.attbin ; export PATH fi UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown # Note: order is significant - the case branches are not exclusive. case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*, # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently # switched to ELF, *-*-netbsd* would select the old # object file format. This provides both forward # compatibility and a consistent mechanism for selecting the # object file format. # # Note: NetBSD doesn't particularly care about the vendor # portion of the name. We always set it to "unknown". sysctl="sysctl -n hw.machine_arch" UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ /usr/sbin/$sysctl 2>/dev/null || echo unknown)` case "${UNAME_MACHINE_ARCH}" in armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; sh5el) machine=sh5le-unknown ;; *) machine=${UNAME_MACHINE_ARCH}-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently, or will in the future. case "${UNAME_MACHINE_ARCH}" in arm*|i386|m68k|ns32k|sh3*|sparc|vax) eval $set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep __ELF__ >/dev/null then # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). # Return netbsd for either. FIX? os=netbsd else os=netbsdelf fi ;; *) os=netbsd ;; esac # The OS release # Debian GNU/NetBSD machines have a different userland, and # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. case "${UNAME_VERSION}" in Debian*) release='-gnu' ;; *) release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` ;; esac # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. echo "${machine}-${os}${release}" exit ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} exit ;; *:ekkoBSD:*:*) echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} exit ;; *:SolidBSD:*:*) echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} exit ;; macppc:MirBSD:*:*) echo powerpc-unknown-mirbsd${UNAME_RELEASE} exit ;; *:MirBSD:*:*) echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} exit ;; alpha:OSF1:*:*) case $UNAME_RELEASE in *4.0) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on # OSF/1 and Tru64 systems produced since 1995. I hope that # covers most systems running today. This code pipes the CPU # types through head -n 1, so we only detect the type of CPU 0. ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` case "$ALPHA_CPU_TYPE" in "EV4 (21064)") UNAME_MACHINE="alpha" ;; "EV4.5 (21064)") UNAME_MACHINE="alpha" ;; "LCA4 (21066/21068)") UNAME_MACHINE="alpha" ;; "EV5 (21164)") UNAME_MACHINE="alphaev5" ;; "EV5.6 (21164A)") UNAME_MACHINE="alphaev56" ;; "EV5.6 (21164PC)") UNAME_MACHINE="alphapca56" ;; "EV5.7 (21164PC)") UNAME_MACHINE="alphapca57" ;; "EV6 (21264)") UNAME_MACHINE="alphaev6" ;; "EV6.7 (21264A)") UNAME_MACHINE="alphaev67" ;; "EV6.8CB (21264C)") UNAME_MACHINE="alphaev68" ;; "EV6.8AL (21264B)") UNAME_MACHINE="alphaev68" ;; "EV6.8CX (21264D)") UNAME_MACHINE="alphaev68" ;; "EV6.9A (21264/EV69A)") UNAME_MACHINE="alphaev69" ;; "EV7 (21364)") UNAME_MACHINE="alphaev7" ;; "EV7.9 (21364A)") UNAME_MACHINE="alphaev79" ;; esac # A Pn.n version is a patched version. # A Vn.n version is a released version. # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` exit ;; Alpha\ *:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # Should we change UNAME_MACHINE based on the output of uname instead # of the specific Alpha model? echo alpha-pc-interix exit ;; 21064:Windows_NT:50:3) echo alpha-dec-winnt3.5 exit ;; Amiga*:UNIX_System_V:4.0:*) echo m68k-unknown-sysv4 exit ;; *:[Aa]miga[Oo][Ss]:*:*) echo ${UNAME_MACHINE}-unknown-amigaos exit ;; *:[Mm]orph[Oo][Ss]:*:*) echo ${UNAME_MACHINE}-unknown-morphos exit ;; *:OS/390:*:*) echo i370-ibm-openedition exit ;; *:z/VM:*:*) echo s390-ibm-zvmoe exit ;; *:OS400:*:*) echo powerpc-ibm-os400 exit ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} exit ;; arm:riscos:*:*|arm:RISCOS:*:*) echo arm-unknown-riscos exit ;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) echo hppa1.1-hitachi-hiuxmpp exit ;; Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. if test "`(/bin/universe) 2>/dev/null`" = att ; then echo pyramid-pyramid-sysv3 else echo pyramid-pyramid-bsd fi exit ;; NILE*:*:*:dcosx) echo pyramid-pyramid-svr4 exit ;; DRS?6000:unix:4.0:6*) echo sparc-icl-nx6 exit ;; DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) case `/usr/bin/uname -p` in sparc) echo sparc-icl-nx7; exit ;; esac ;; sun4H:SunOS:5.*:*) echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:*:*) case "`/usr/bin/arch -k`" in Series*|S4*) UNAME_RELEASE=`uname -v` ;; esac # Japanese Language versions have a version number like `4.1.3-JL'. echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` exit ;; sun3*:SunOS:*:*) echo m68k-sun-sunos${UNAME_RELEASE} exit ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 case "`/bin/arch`" in sun3) echo m68k-sun-sunos${UNAME_RELEASE} ;; sun4) echo sparc-sun-sunos${UNAME_RELEASE} ;; esac exit ;; aushp:SunOS:*:*) echo sparc-auspex-sunos${UNAME_RELEASE} exit ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not # "atarist" or "atariste" at least should have a processor # > m68000). The system name ranges from "MiNT" over "FreeMiNT" # to the lowercase version "mint" (or "freemint"). Finally # the system name "TOS" denotes a system which is actually not # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) echo m68k-milan-mint${UNAME_RELEASE} exit ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) echo m68k-hades-mint${UNAME_RELEASE} exit ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) echo m68k-unknown-mint${UNAME_RELEASE} exit ;; m68k:machten:*:*) echo m68k-apple-machten${UNAME_RELEASE} exit ;; powerpc:machten:*:*) echo powerpc-apple-machten${UNAME_RELEASE} exit ;; RISC*:Mach:*:*) echo mips-dec-mach_bsd4.3 exit ;; RISC*:ULTRIX:*:*) echo mips-dec-ultrix${UNAME_RELEASE} exit ;; VAX*:ULTRIX*:*:*) echo vax-dec-ultrix${UNAME_RELEASE} exit ;; 2020:CLIX:*:* | 2430:CLIX:*:*) echo clipper-intergraph-clix${UNAME_RELEASE} exit ;; mips:*:*:UMIPS | mips:*:*:RISCos) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #ifdef __cplusplus #include /* for printf() prototype */ int main (int argc, char *argv[]) { #else int main (argc, argv) int argc; char *argv[]; { #endif #if defined (host_mips) && defined (MIPSEB) #if defined (SYSTYPE_SYSV) printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_SVR4) printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); #endif #endif exit (-1); } EOF $CC_FOR_BUILD -o $dummy $dummy.c && dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && SYSTEM_NAME=`$dummy $dummyarg` && { echo "$SYSTEM_NAME"; exit; } echo mips-mips-riscos${UNAME_RELEASE} exit ;; Motorola:PowerMAX_OS:*:*) echo powerpc-motorola-powermax exit ;; Motorola:*:4.3:PL8-*) echo powerpc-harris-powermax exit ;; Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) echo powerpc-harris-powermax exit ;; Night_Hawk:Power_UNIX:*:*) echo powerpc-harris-powerunix exit ;; m88k:CX/UX:7*:*) echo m88k-harris-cxux7 exit ;; m88k:*:4*:R4*) echo m88k-motorola-sysv4 exit ;; m88k:*:3*:R3*) echo m88k-motorola-sysv3 exit ;; AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] then if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ [ ${TARGET_BINARY_INTERFACE}x = x ] then echo m88k-dg-dgux${UNAME_RELEASE} else echo m88k-dg-dguxbcs${UNAME_RELEASE} fi else echo i586-dg-dgux${UNAME_RELEASE} fi exit ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) echo m88k-dolphin-sysv3 exit ;; M88*:*:R3*:*) # Delta 88k system running SVR3 echo m88k-motorola-sysv3 exit ;; XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) echo m88k-tektronix-sysv3 exit ;; Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) echo m68k-tektronix-bsd exit ;; *:IRIX*:*:*) echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` exit ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' i*86:AIX:*:*) echo i386-ibm-aix exit ;; ia64:AIX:*:*) if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} exit ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include main() { if (!__power_pc()) exit(1); puts("powerpc-ibm-aix3.2.5"); exit(0); } EOF if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` then echo "$SYSTEM_NAME" else echo rs6000-ibm-aix3.2.5 fi elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then echo rs6000-ibm-aix3.2.4 else echo rs6000-ibm-aix3.2 fi exit ;; *:AIX:*:[45]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc fi if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${IBM_ARCH}-ibm-aix${IBM_REV} exit ;; *:AIX:*:*) echo rs6000-ibm-aix exit ;; ibmrt:4.4BSD:*|romp-ibm:BSD:*) echo romp-ibm-bsd4.4 exit ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to exit ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) echo rs6000-bull-bosx exit ;; DPX/2?00:B.O.S.:*:*) echo m68k-bull-sysv3 exit ;; 9000/[34]??:4.3bsd:1.*:*) echo m68k-hp-bsd exit ;; hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) echo m68k-hp-bsd4.4 exit ;; 9000/[34678]??:HP-UX:*:*) HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` case "${UNAME_MACHINE}" in 9000/31? ) HP_ARCH=m68000 ;; 9000/[34]?? ) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) if [ -x /usr/bin/getconf ]; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` case "${sc_cpu_version}" in 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 case "${sc_kernel_bits}" in 32) HP_ARCH="hppa2.0n" ;; 64) HP_ARCH="hppa2.0w" ;; '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 esac ;; esac fi if [ "${HP_ARCH}" = "" ]; then eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #define _HPUX_SOURCE #include #include int main () { #if defined(_SC_KERNEL_BITS) long bits = sysconf(_SC_KERNEL_BITS); #endif long cpu = sysconf (_SC_CPU_VERSION); switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0"); break; case CPU_PA_RISC1_1: puts ("hppa1.1"); break; case CPU_PA_RISC2_0: #if defined(_SC_KERNEL_BITS) switch (bits) { case 64: puts ("hppa2.0w"); break; case 32: puts ("hppa2.0n"); break; default: puts ("hppa2.0"); break; } break; #else /* !defined(_SC_KERNEL_BITS) */ puts ("hppa2.0"); break; #endif default: puts ("hppa1.0"); break; } exit (0); } EOF (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac if [ ${HP_ARCH} = "hppa2.0w" ] then eval $set_cc_for_build # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler # generating 64-bit code. GNU and HP use different nomenclature: # # $ CC_FOR_BUILD=cc ./config.guess # => hppa2.0w-hp-hpux11.23 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess # => hppa64-hp-hpux11.23 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | grep __LP64__ >/dev/null then HP_ARCH="hppa2.0w" else HP_ARCH="hppa64" fi fi echo ${HP_ARCH}-hp-hpux${HPUX_REV} exit ;; ia64:HP-UX:*:*) HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` echo ia64-hp-hpux${HPUX_REV} exit ;; 3050*:HI-UX:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include int main () { long cpu = sysconf (_SC_CPU_VERSION); /* The order matters, because CPU_IS_HP_MC68K erroneously returns true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct results, however. */ if (CPU_IS_PA_RISC (cpu)) { switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; default: puts ("hppa-hitachi-hiuxwe2"); break; } } else if (CPU_IS_HP_MC68K (cpu)) puts ("m68k-hitachi-hiuxwe2"); else puts ("unknown-hitachi-hiuxwe2"); exit (0); } EOF $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && { echo "$SYSTEM_NAME"; exit; } echo unknown-hitachi-hiuxwe2 exit ;; 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) echo hppa1.1-hp-bsd exit ;; 9000/8??:4.3bsd:*:*) echo hppa1.0-hp-bsd exit ;; *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) echo hppa1.0-hp-mpeix exit ;; hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) echo hppa1.1-hp-osf exit ;; hp8??:OSF1:*:*) echo hppa1.0-hp-osf exit ;; i*86:OSF1:*:*) if [ -x /usr/sbin/sysversion ] ; then echo ${UNAME_MACHINE}-unknown-osf1mk else echo ${UNAME_MACHINE}-unknown-osf1 fi exit ;; parisc*:Lites*:*:*) echo hppa1.1-hp-lites exit ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) echo c1-convex-bsd exit ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) echo c34-convex-bsd exit ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) echo c38-convex-bsd exit ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) echo c4-convex-bsd exit ;; CRAY*Y-MP:*:*:*) echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*[A-Z]90:*:*:*) echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ -e 's/\.[^.]*$/.X/' exit ;; CRAY*TS:*:*:*) echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*T3E:*:*:*) echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*SV1:*:*:*) echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; *:UNICOS/mp:*:*) echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; 5000:UNIX_System_V:4.*:*) FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} exit ;; sparc*:BSD/OS:*:*) echo sparc-unknown-bsdi${UNAME_RELEASE} exit ;; *:BSD/OS:*:*) echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit ;; *:FreeBSD:*:*) case ${UNAME_MACHINE} in pc98) echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; amd64) echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; *) echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; esac exit ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin exit ;; *:MINGW*:*) echo ${UNAME_MACHINE}-pc-mingw32 exit ;; i*:windows32*:*) # uname -m includes "-pc" on this system. echo ${UNAME_MACHINE}-mingw32 exit ;; i*:PW*:*) echo ${UNAME_MACHINE}-pc-pw32 exit ;; *:Interix*:[3456]*) case ${UNAME_MACHINE} in x86) echo i586-pc-interix${UNAME_RELEASE} exit ;; EM64T | authenticamd) echo x86_64-unknown-interix${UNAME_RELEASE} exit ;; esac ;; [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) echo i${UNAME_MACHINE}-pc-mks exit ;; i*:Windows_NT*:* | Pentium*:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we # UNAME_MACHINE based on the output of uname instead of i386? echo i586-pc-interix exit ;; i*:UWIN*:*) echo ${UNAME_MACHINE}-pc-uwin exit ;; amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) echo x86_64-unknown-cygwin exit ;; p*:CYGWIN*:*) echo powerpcle-unknown-cygwin exit ;; prep*:SunOS:5.*:*) echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; *:GNU:*:*) # the GNU system echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` exit ;; *:GNU/*:*:*) # other systems with GNU libc and userland echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu exit ;; i*86:Minix:*:*) echo ${UNAME_MACHINE}-pc-minix exit ;; arm*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; avr32*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; cris:Linux:*:*) echo cris-axis-linux-gnu exit ;; crisv32:Linux:*:*) echo crisv32-axis-linux-gnu exit ;; frv:Linux:*:*) echo frv-unknown-linux-gnu exit ;; ia64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; m32r*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; m68*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; mips:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU #undef mips #undef mipsel #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) CPU=mipsel #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) CPU=mips #else CPU= #endif #endif EOF eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' /^CPU/{ s: ::g p }'`" test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; mips64:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU #undef mips64 #undef mips64el #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) CPU=mips64el #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) CPU=mips64 #else CPU= #endif #endif EOF eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' /^CPU/{ s: ::g p }'`" test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; or32:Linux:*:*) echo or32-unknown-linux-gnu exit ;; ppc:Linux:*:*) echo powerpc-unknown-linux-gnu exit ;; ppc64:Linux:*:*) echo powerpc64-unknown-linux-gnu exit ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in EV5) UNAME_MACHINE=alphaev5 ;; EV56) UNAME_MACHINE=alphaev56 ;; PCA56) UNAME_MACHINE=alphapca56 ;; PCA57) UNAME_MACHINE=alphapca56 ;; EV6) UNAME_MACHINE=alphaev6 ;; EV67) UNAME_MACHINE=alphaev67 ;; EV68*) UNAME_MACHINE=alphaev68 ;; esac objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} exit ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in PA7*) echo hppa1.1-unknown-linux-gnu ;; PA8*) echo hppa2.0-unknown-linux-gnu ;; *) echo hppa-unknown-linux-gnu ;; esac exit ;; parisc64:Linux:*:* | hppa64:Linux:*:*) echo hppa64-unknown-linux-gnu exit ;; s390:Linux:*:* | s390x:Linux:*:*) echo ${UNAME_MACHINE}-ibm-linux exit ;; sh64*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; sh*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; sparc:Linux:*:* | sparc64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; vax:Linux:*:*) echo ${UNAME_MACHINE}-dec-linux-gnu exit ;; x86_64:Linux:*:*) echo x86_64-unknown-linux-gnu exit ;; xtensa:Linux:*:*) echo xtensa-unknown-linux-gnu exit ;; i*86:Linux:*:*) # The BFD linker knows what the default object file format is, so # first see if it will tell us. cd to the root directory to prevent # problems with other programs or directories called `ld' in the path. # Set LC_ALL=C to ensure ld outputs messages in English. ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \ | sed -ne '/supported targets:/!d s/[ ][ ]*/ /g s/.*supported targets: *// s/ .*// p'` case "$ld_supported_targets" in elf32-i386) TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu" ;; a.out-i386-linux) echo "${UNAME_MACHINE}-pc-linux-gnuaout" exit ;; coff-i386) echo "${UNAME_MACHINE}-pc-linux-gnucoff" exit ;; "") # Either a pre-BFD a.out linker (linux-gnuoldld) or # one that does not give us useful --help. echo "${UNAME_MACHINE}-pc-linux-gnuoldld" exit ;; esac # Determine whether the default compiler is a.out or elf eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include #ifdef __ELF__ # ifdef __GLIBC__ # if __GLIBC__ >= 2 LIBC=gnu # else LIBC=gnulibc1 # endif # else LIBC=gnulibc1 # endif #else #if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC) LIBC=gnu #else LIBC=gnuaout #endif #endif #ifdef __dietlibc__ LIBC=dietlibc #endif EOF eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' /^LIBC/{ s: ::g p }'`" test x"${LIBC}" != x && { echo "${UNAME_MACHINE}-pc-linux-${LIBC}" exit } test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; } ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both # sysname and nodename. echo i386-sequent-sysv4 exit ;; i*86:UNIX_SV:4.2MP:2.*) # Unixware is an offshoot of SVR4, but it has its own version # number series starting with 2... # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} exit ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. echo ${UNAME_MACHINE}-pc-os2-emx exit ;; i*86:XTS-300:*:STOP) echo ${UNAME_MACHINE}-unknown-stop exit ;; i*86:atheos:*:*) echo ${UNAME_MACHINE}-unknown-atheos exit ;; i*86:syllable:*:*) echo ${UNAME_MACHINE}-pc-syllable exit ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) echo i386-unknown-lynxos${UNAME_RELEASE} exit ;; i*86:*DOS:*:*) echo ${UNAME_MACHINE}-pc-msdosdjgpp exit ;; i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} else echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} fi exit ;; i*86:*:5:[678]*) # UnixWare 7.x, OpenUNIX and OpenServer 6. case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} exit ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ && UNAME_MACHINE=i586 (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 echo ${UNAME_MACHINE}-pc-sco$UNAME_REL else echo ${UNAME_MACHINE}-pc-sysv32 fi exit ;; pc:*:*:*) # Left here for compatibility: # uname -m prints for DJGPP always 'pc', but it prints nothing about # the processor, so we play safe by assuming i386. echo i386-pc-msdosdjgpp exit ;; Intel:Mach:3*:*) echo i386-pc-mach3 exit ;; paragon:*:*:*) echo i860-intel-osf1 exit ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 fi exit ;; mini*:CTIX:SYS*5:*) # "miniframe" echo m68010-convergent-sysv exit ;; mc68k:UNIX:SYSTEM5:3.51m) echo m68k-convergent-sysv exit ;; M680?0:D-NIX:5.3:*) echo m68k-diab-dnix exit ;; M68*:*:R3V[5678]*:*) test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) OS_REL='' test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4.3${OS_REL}; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) echo m68k-unknown-lynxos${UNAME_RELEASE} exit ;; mc68030:UNIX_System_V:4.*:*) echo m68k-atari-sysv4 exit ;; TSUNAMI:LynxOS:2.*:*) echo sparc-unknown-lynxos${UNAME_RELEASE} exit ;; rs6000:LynxOS:2.*:*) echo rs6000-unknown-lynxos${UNAME_RELEASE} exit ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*) echo powerpc-unknown-lynxos${UNAME_RELEASE} exit ;; SM[BE]S:UNIX_SV:*:*) echo mips-dde-sysv${UNAME_RELEASE} exit ;; RM*:ReliantUNIX-*:*:*) echo mips-sni-sysv4 exit ;; RM*:SINIX-*:*:*) echo mips-sni-sysv4 exit ;; *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` echo ${UNAME_MACHINE}-sni-sysv4 else echo ns32k-sni-sysv fi exit ;; PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort # says echo i586-unisys-sysv4 exit ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm echo hppa1.1-stratus-sysv4 exit ;; *:*:*:FTX*) # From seanf@swdc.stratus.com. echo i860-stratus-sysv4 exit ;; i*86:VOS:*:*) # From Paul.Green@stratus.com. echo ${UNAME_MACHINE}-stratus-vos exit ;; *:VOS:*:*) # From Paul.Green@stratus.com. echo hppa1.1-stratus-vos exit ;; mc68*:A/UX:*:*) echo m68k-apple-aux${UNAME_RELEASE} exit ;; news*:NEWS-OS:6*:*) echo mips-sony-newsos6 exit ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then echo mips-nec-sysv${UNAME_RELEASE} else echo mips-unknown-sysv${UNAME_RELEASE} fi exit ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. echo powerpc-be-beos exit ;; BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. echo powerpc-apple-beos exit ;; BePC:BeOS:*:*) # BeOS running on Intel PC compatible. echo i586-pc-beos exit ;; SX-4:SUPER-UX:*:*) echo sx4-nec-superux${UNAME_RELEASE} exit ;; SX-5:SUPER-UX:*:*) echo sx5-nec-superux${UNAME_RELEASE} exit ;; SX-6:SUPER-UX:*:*) echo sx6-nec-superux${UNAME_RELEASE} exit ;; SX-7:SUPER-UX:*:*) echo sx7-nec-superux${UNAME_RELEASE} exit ;; SX-8:SUPER-UX:*:*) echo sx8-nec-superux${UNAME_RELEASE} exit ;; SX-8R:SUPER-UX:*:*) echo sx8r-nec-superux${UNAME_RELEASE} exit ;; Power*:Rhapsody:*:*) echo powerpc-apple-rhapsody${UNAME_RELEASE} exit ;; *:Rhapsody:*:*) echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} exit ;; *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown case $UNAME_PROCESSOR in unknown) UNAME_PROCESSOR=powerpc ;; esac echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} exit ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` if test "$UNAME_PROCESSOR" = "x86"; then UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} exit ;; *:QNX:*:4*) echo i386-pc-qnx exit ;; NSE-?:NONSTOP_KERNEL:*:*) echo nse-tandem-nsk${UNAME_RELEASE} exit ;; NSR-?:NONSTOP_KERNEL:*:*) echo nsr-tandem-nsk${UNAME_RELEASE} exit ;; *:NonStop-UX:*:*) echo mips-compaq-nonstopux exit ;; BS2000:POSIX*:*:*) echo bs2000-siemens-sysv exit ;; DS/*:UNIX_System_V:*:*) echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} exit ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 # is converted to i386 for consistency with other x86 # operating systems. if test "$cputype" = "386"; then UNAME_MACHINE=i386 else UNAME_MACHINE="$cputype" fi echo ${UNAME_MACHINE}-unknown-plan9 exit ;; *:TOPS-10:*:*) echo pdp10-unknown-tops10 exit ;; *:TENEX:*:*) echo pdp10-unknown-tenex exit ;; KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) echo pdp10-dec-tops20 exit ;; XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) echo pdp10-xkl-tops20 exit ;; *:TOPS-20:*:*) echo pdp10-unknown-tops20 exit ;; *:ITS:*:*) echo pdp10-unknown-its exit ;; SEI:*:*:SEIUX) echo mips-sei-seiux${UNAME_RELEASE} exit ;; *:DragonFly:*:*) echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit ;; *:*VMS:*:*) UNAME_MACHINE=`(uname -p) 2>/dev/null` case "${UNAME_MACHINE}" in A*) echo alpha-dec-vms ; exit ;; I*) echo ia64-dec-vms ; exit ;; V*) echo vax-dec-vms ; exit ;; esac ;; *:XENIX:*:SysV) echo i386-pc-xenix exit ;; i*86:skyos:*:*) echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' exit ;; i*86:rdos:*:*) echo ${UNAME_MACHINE}-pc-rdos exit ;; esac #echo '(No uname command or uname output not recognized.)' 1>&2 #echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 eval $set_cc_for_build cat >$dummy.c < # include #endif main () { #if defined (sony) #if defined (MIPSEB) /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, I don't know.... */ printf ("mips-sony-bsd\n"); exit (0); #else #include printf ("m68k-sony-newsos%s\n", #ifdef NEWSOS4 "4" #else "" #endif ); exit (0); #endif #endif #if defined (__arm) && defined (__acorn) && defined (__unix) printf ("arm-acorn-riscix\n"); exit (0); #endif #if defined (hp300) && !defined (hpux) printf ("m68k-hp-bsd\n"); exit (0); #endif #if defined (NeXT) #if !defined (__ARCHITECTURE__) #define __ARCHITECTURE__ "m68k" #endif int version; version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; if (version < 4) printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); else printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); exit (0); #endif #if defined (MULTIMAX) || defined (n16) #if defined (UMAXV) printf ("ns32k-encore-sysv\n"); exit (0); #else #if defined (CMU) printf ("ns32k-encore-mach\n"); exit (0); #else printf ("ns32k-encore-bsd\n"); exit (0); #endif #endif #endif #if defined (__386BSD__) printf ("i386-pc-bsd\n"); exit (0); #endif #if defined (sequent) #if defined (i386) printf ("i386-sequent-dynix\n"); exit (0); #endif #if defined (ns32000) printf ("ns32k-sequent-dynix\n"); exit (0); #endif #endif #if defined (_SEQUENT_) struct utsname un; uname(&un); if (strncmp(un.version, "V2", 2) == 0) { printf ("i386-sequent-ptx2\n"); exit (0); } if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ printf ("i386-sequent-ptx1\n"); exit (0); } printf ("i386-sequent-ptx\n"); exit (0); #endif #if defined (vax) # if !defined (ultrix) # include # if defined (BSD) # if BSD == 43 printf ("vax-dec-bsd4.3\n"); exit (0); # else # if BSD == 199006 printf ("vax-dec-bsd4.3reno\n"); exit (0); # else printf ("vax-dec-bsd\n"); exit (0); # endif # endif # else printf ("vax-dec-bsd\n"); exit (0); # endif # else printf ("vax-dec-ultrix\n"); exit (0); # endif #endif #if defined (alliant) && defined (i860) printf ("i860-alliant-bsd\n"); exit (0); #endif exit (1); } EOF $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` && { echo "$SYSTEM_NAME"; exit; } # Apollos put the system type in the environment. test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; } # Convex versions that predate uname can use getsysinfo(1) if [ -x /usr/convex/getsysinfo ] then case `getsysinfo -f cpu_type` in c1*) echo c1-convex-bsd exit ;; c2*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit ;; c34*) echo c34-convex-bsd exit ;; c38*) echo c38-convex-bsd exit ;; c4*) echo c4-convex-bsd exit ;; esac fi cat >&2 < in order to provide the needed information to handle your system. config.guess timestamp = $timestamp uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` /bin/uname -X = `(/bin/uname -X) 2>/dev/null` hostinfo = `(hostinfo) 2>/dev/null` /bin/universe = `(/bin/universe) 2>/dev/null` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` /bin/arch = `(/bin/arch) 2>/dev/null` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` UNAME_MACHINE = ${UNAME_MACHINE} UNAME_RELEASE = ${UNAME_RELEASE} UNAME_SYSTEM = ${UNAME_SYSTEM} UNAME_VERSION = ${UNAME_VERSION} EOF exit 1 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: tgif-QPL-4.2.5/rmcast/ChangeLog0000644000076400007640000006554411225226447016061 0ustar williamwilliam #################### version 2.0.0 cvs tag ver_2_0_0 Modified files: doc/manual/tgwb.lyx doc/manual/tgwb.tex etc/rmcast.config.README rmchat/rmchat.c src/rmcast.c src/rmcast.h src/rminternals.c src/rminternals.h src/rmmsg.c Added files: Allyson 06/07/2009 src/rmcast.c src/rmcast.h - RM_initialize now requires a pointer to a callback function. That function will be called whenever we need to terminate and will allow the application to clean up its resources before exiting. - RM_terminate return type is now void and it calls the callback function passed by the application through RM_initialize parameter src/rminternals.h - code clean up src/rminternals.c - call RM_terminate in the correct place src/rmmsg.c - unlock remove_queues_lock before returning rmchat/rmchat.c - modified to use new RM_initialize doc/manual/tgwb.tex doc/manual/tgwb.lyx - updated documentation etc/rmcast.config.README - removed info about rmcast.config.sample2 #################### version 1.11.8 cvs tag ver_1_11_8 Modified files: src/rmcache.c src/rmcache.h src/rmcast.c src/rmcast.h src/rminternals.c src/rminternals.h src/rmmsg.c src/rmmsg.h Added files: Allyson 22/06/2009 src/rmcache.c src/rmcache.h - replaced calls to function exit() - function cacheGetSMinfo now returns a integer (0 on error) src/rmcast.c src/rmcast.h - replaced calls to function exit() - function RM_initialize now returns a integer (0 on error) - function RM_terminate now returns a integer (0 on error) - function getCurStatus returns 0 if rmcastSendPacket fails - modified variable name from c to current_status in getCurStatus src/rminternals.c src/rminternals.h - replaced calls to function exit() - function rmcastLeaveGroup now returns a integer (0 on error) - function rmcastLeaveGroup returns 0 if rmcastSendPacket fails - function rmcastSendPacket now returns a integer (0 on error) src/rmmsg.c src/rmmsg.h - replaced calls to function exit() - code clean-up #################### version 1.11.7 cvs tag ver_1_11_7 Modified files: tools/scripts/makedeb.sh Added files: Allyson 28/01/2009 tools/scripts/makedeb.sh - corrected errors and improved deb package creation #################### version 1.11.6 cvs tag ver_1_11_6 Modified files: Makefile.am rmchat/rmchat.c src/Makefile.am src/rmcache.c src/rmcache.h src/rmcast.c src/rmcast.h src/rmevent.c src/rmevent.h src/rminternals.c src/rminternals.h src/rmmsg.c src/rmmsg.h src/rmmsgpckt.c src/rmmsgpckt.h src/rmstruct.h src/rmtcp.c src/rmtcp.h src/rmwinmask.c src/rmwinmask.h Added files: tools/scripts/makedeb.sh Removed files: tgif/mainloop.c tgif/wb.c Allyson 12/01/2009 Makefile.am - included target "deb" to create binary .deb packages for Debian tools/scripts/makedeb.sh - new file added: shell script to build deb packages tgif/mainloop.c tgif/wb.c - removed, tgif version of this files are too different now rmchat/rmchat.c src/*.c src/*.h - updated Copyright information #################### version 1.11.5 cvs tag ver_1_11_5 Modified files: RMLcommit.sh tgif/tgwb Added files: Allyson 26/11/2008 RMcommit.sh - modified again to automatically update tgif/tgwb version tgif/tgwb - manually updated version number again #################### version 1.11.4 cvs tag ver_1_11_4 Modified files: RMLcommit.sh configure.in src/Makefile.am src/rmcast.h tgif/tgwb Added files: Allyson 26/11/2008 RMcommit.sh - modified to automatically update tgif/tgwb version - removed unused variable EXTRA_FILES configure.in - moved out defines to src/Makefile.am src/Makefile.am - moved in defines from ../configure.in src/rmcast.h - removed ifdef and include of config.h tgif/tgwb - manually updated version number (hopefully) for the last time #################### version 1.11.3 cvs tag ver_1_11_3 Modified files: README README.tgwb autotools.sh tgif/tgwb Added files: Allyson 23/11/2008 autotools.sh - modified to call aclocal/automake instead of aclocal-1.7/automake-1.7 README - updated tgif download URL (no need for port 8001 anymore) README.tgwb tgif/tgwb - updated to reflect the changes made in tgif version 4.1.46, which no longer generates a different binary for tgwb. Tgif will try to load the reliable multicast library librmcast.so dynamically when executed with the "-tgwb2" command line parameter. #################### version 1.11.2 cvs tag ver_1_11_2 Modified files: src/rmcast.c Added files: Allyson 18/10/2008 src/rmcast.c - added "RMCAST" string before version number in RM_getVersion (required by tgwb) - removed debug info #################### version 1.11.1 cvs tag ver_1_11_1 Modified files: rmchat/rmchat.c Added files: Allyson 17/10/2008 rmchat/rmchat.c - added missing variable declaration #################### version 1.11.0 cvs tag ver_1_11_0 Modified files: README.tgwb configure.in rmchat/rmchat.c src/Makefile.am src/rmcache.c src/rmcache.h src/rmcast.c src/rmcast.h src/rmevent.c src/rmevent.h src/rminternals.c src/rminternals.h src/rmmsg.c src/rmmsg.h src/rmmsgpckt.c src/rmmsgpckt.h src/rmstruct.h src/rmtcp.c src/rmtcp.h src/rmwinmask.c src/rmwinmask.h Added files: RMLcommit.sh Allyson 17/10/2008 RMLcommit.sh - Added commit script README.tgwb - Added -lz to EXTRA_LIBRARIES configure.in - Use the same macros than other tools develop by LAND src/Makefile.am - Added define to pass down version string during compilation src/rmcast.c src/rmcast.h - Added new function RM_getVersion() src/rmcache.c src/rmcache.h src/rmcast.c src/rmcast.h src/rmevent.c src/rmevent.h src/rminternals.c src/rminternals.h src/rmmsg.c src/rmmsg.h src/rmmsgpckt.c src/rmmsgpckt.h src/rmstruct.h src/rmtcp.c src/rmtcp.h src/rmwinmask.c src/rmwinmask.h - Updated copyright year to 2008 rmchat/rmchat.c - Modified to use the new function RM_getVersion() - Code clean up 2008-10-06 Allyson * Release version 1.10 (cvs tag: rmcast_v1_10) * Modified autotools to use libtool to generate static and dynamic libraries * Modified files: - ChangeLog - autotools.sh - configure.in - etc/rmcast.config.sample - rmchat/Makefile.am - src/Makefile.am 2008-07-02 Allyson * Release version 1.9.1 (cvs tag: rmcast_v1_9_1) * Modified mcastproxy to re-read config file on receiving SIGHUP and code clean up. mcastproxy/mcastproxy.c 2008-05-01 Allyson * Release version 1.9 (cvs tag: rmcast_v1_9) * Modified default timer from 300ms to 50ms: src/rminternals.c tgif/tgwb etc/rmcast.config.sample README.tgwb * Code clean up in src/rminternals.c 2006-05-17 Allyson * Release version 1.8 (cvs tag: rmcast_v1_8) * Replaced return values for exit() to EXIT_SUCCESS and EXIT_FAILURE * Modified RM_leaveGroup() type from int to void * RM_terminate() now returns EXIT_SUCCESS * Some code clean up (including rmchat/rmchat.c) * Code fixed to avoid gcc4 warnings * Fixed major bug in mcastproxy * Modified configure.in and tgif/tgwb to update rmcast version to 1.8 2006-03-30 Allyson * Added tgif/tgif_tgwb.sh, a script to help compiling tgwb from tgif source code 2006-03-15 Allyson * Release version 1.7 (cvs tag: rmcast_v1_7) * Modified mcastproxy/mcastproxy.c to properly read and use REUSEADDR from config file * Added -Wall option to CFLAGS in src/Makefile.am mcastproxy/Makefile.am and rmchat/Makefile.am * Code clean up and fixed to avoid gcc warnings * Modified configure.in and tgif/tgwb to update rmcast version to 1.7 2005-10-04 Allyson * Modified src/rmcast.c to properly detect network interfaces * Modified src/rminternals.c to use same default values as the config file * Modified configure.in and tgif/tgwb to update rmcast version to 1.6 2004-09-26 Allyson * Some small modifications on tgif/tgwb script * Updated tgif/*.c 2004-01-27 Allyson * Release version 1.4 * config option VERSION changed to RM_VERSION * Now we use QPL license instead of GPL * Code is now Autoconfiscated (configure script created) * New directory structure * New ChangeLog 1.3 (cvs tag: rmcast_v1_3) Sep 01,2003 Allyson - RELEASE VERSION 1.3 - Updated TGWB files to conform to tgif release 4.1.43. That release added a chat window to TGWB. - Updated - tgif/wb.c - tgif/mainloop.c 1.2 (cvs tag: rmcast_v1_2) Jul 28,2003 Allyson - RELEASE VERSION 1.2 - Added - tools/scripts/tgwb.sh - Updated - README - tools/scripts/README 1.1 (cvs tag: rmcast_v1_1) Apr 12,2003 Allyson - RELEASE VERSION 1.1 - some code corrections and clean-up - updated tgif/wb.c to search for config file $HOME/.tgwb/tgwb.conf before using the default values - modified mcastproxy to search for config file $HOME/.tgwb/mcastproxy.conf - mcastproxy code clean-up - Makefile file clean-up - Removed - docs/rmcast.config.sample2 - docs/rmcast.config.sample3 - Updated - tgif/wb/c - tools/mcastproxy/mcastproxy.c - Makefile 1.0 (cvs tag: rmcast_v1) Jan 31,2003 Allyson - RELEASE VERSION 1 - some code corrections and clean-up - updated tgif/wb.c to properly read the config files from /etc/tgwb.conf or $HOME/.tgwb.conf - modified mcastproxy error messages - modified signal handler in rminternals.h. Now SIGUSR2 is used to stop transmissions - Updated - rminternals.c - doc/rmcast.config.sample3 - tgif/wb.c - tools/mcastproxy/mcastproxy.c 1.0rc1( cvs tag: rmcast_v1rc1 ) Nov 03,2002 Allyson - RELEASE CANDIDATE 1 - Added a new debug DSUPPRESSION to generate a log file where each line identifies either a retransmition (RT) or a NAK suppression (NK or nk). NK indicates that a NAK was suppressed, nk indicates that only a position of a NAK was suppressed. See rminternals.c and rmevent.c for further info. - Added new options to the config file. Now the timer parameters must be used as follows: TIMER_PARAM_A and TIMER_PARAM_B refers to NAK_SND_WAIT event TIMER_PARAM_C and TIMER_PARAM_D refers to RET_RCV_WAIT event TIMER_PARAM_E and TIMER_PARAM_F refers to RET_SND_WAIT event - Updated - Makefile - rmcast.c - rmcast.h - rmevent.c - rminternals.c - rminternals.h - doc/rmcast.config.sample3 0.99e Oct 17,2002 Allyson - Added a new debug DPROCESSING_TIME to generate a log file with the processing times (in ms) required for each type of received packets. See rmcastReceivePackets in rminternals.c - Increased microsleep in mcastproxy - Updated - rminternals.c - Makefile - tools/mcastproxy/mcastproxy.c 0.99d Sep 22,2002 Allyson - Modified generateTimerValue function. Now users can provide parameters to calculate the intervals for NAKs and retransmitions - Updated - Updated RM_readConfigFile to adapt to the new config file - Modified rmcast.config. Option added: TIMER_PARAM_A, TIMER_PARAM_B, TIMER_PARAM_C, TIMER_PARAM_D Option modified: HOST_IDENTIFIED Now the must indicate the one-way delay for each host identified. New options allows user to control the timer interval. See doc/rmcast.config.sample3 for example - Improved RM_getOption function. Now almost every option can be obtained using this function - Replaced functions: RM_getHostTimers by RM_getHostDelay RM_setHostTimers by RM_setHostDelay Now, the timer intervals can be obtained using these functions and the timer parameters values as follows: - (TIMER_PARAM_A*T,(TIMER_PARAM_A+TIMER_PARAM_B)*T) is the time interval for for NAKs - (TIMER_PARAM_C*T,(TIMER_PARAM_C+TIMER_PARAM_D)*T) is the time interval for for retransmitions Where T is the estimated one-way delay to the sender and the timer parameters values can be obtained using the RM_getOption function - Updated - doc/rmcast.config.sample3 - rmcast.h - rmcast.c - rminternals.c - rminternals.h - rmevent.c 0.99c Sep 16,2002 Allyson - Removed BUG related to timer generation in generateTimerValue function - Seed for random numbers generation is now created on initialization - Idented rmlog.awk script code - Inserted NOT TESTED at all, the cacheDeleteNakNode function - Updated - rmcast.c - rmevent.c - tools/scripts/rmlog.awk - tools/scripts/rmcastplot.bash - tools/mcastproxy/mcastproxy.c 0.99b Sep 04,2002 Allyson - Replaced word USER by MEMBER - Replaced old define MAX_IP_STRING_SIZE by IP_STRING_SIZE - Cleaned up DONT_SEND_NAK_AGAIN_IMMEDIATLY references - Replaced mispelled function cacheDesactivateMember by cacheDeactivateMember - Updated - rmcast.h - rmcast.c - rmcache.c - rmcache.h - rmmsgpckt.c - rmstruct.h - rmtcp.c - rminternals.h - rminternals.c - Makefile - doc/rmcast.config.sample3 0.99 Sep 01,2002 Allyson - Now RM_terminate is called only when the event LEV_GRP_EVENT triggers - Updated RM_readConfigFile to adapt to the new config file - Modified rmcast.config. Options removed: AVG_DELAY, TIMER_UPPER, TIMER_LOWER Option added: HOSTS_IDENTIFIED New option allows for host related timers, see doc/rmcast.config.sample3 for example - Added 2 new functions to rmcast.c: RM_setHostTimer and RM_getHostTimer - Removed duplicated function generate_uniform - generateTimerValue function was modified to adapt to host related timers - eventListInsert function was modified to adapt to host related timers - Updated every call to evenListInsert - Updated - rmcast.c - rmcast.h - rmevent.c - rmevent.h - rminternals.c - rminternals.h - examples/rmchat/rmchat.c - New file: - docs/rmcast.config.sample3 0.98c Aug 28,2002 Allyson - SIGTERM is now handled properly in the rmcastHandleSignals function - Modified RM_readConfigFile function. Now the user can choose if while the config file is been read its options are displayed. - Small modifications in generateTimerValue and generateSample functions - Updated application files to adapt to the new RM_readConfigFile function ( tgif/wb.c e examples/rmchat/rmchat.c ) - Updated - rminternals.c - rmcast.c - rmcast.h - rmevent.c - tgif/wb.c - examples/rmchat/rmchat.c 0.98b Aug 15,2002 Allyson - The function RM_readConfigFile now has a return value indicating if the file was read successfully - Updated application files to adapt to the new RM_readConfigFile function ( tgif/wb.c e examples/rmchat/rmchat.c ) - Replaced usleep() by nanosleep() in rminternals.c - Changed rmcast_options.microsleep type from 'int' to 'unisgned int' in rminternals.h - Updated rmcast.c rmcast.h rminternlas.h rminternals.c tgif/wb.c examples/rmchat/rmchat.c 0.98a Aug 11,2002 Allyson - Now REFRESH messages are sent only after the member has sent the first data packet - rmchat is no longer sending a packet before prompting - rmchat can now use a distribution and a send rate in the send command - Updated rminternals.c rmcast.c rmevents.c rmevents.h examples/rmchat/rmchat.c 0.98 Jul 10,2002 Allyson & Milena - BUG removed: when using multiple nacks there was a non-initilized variable in rmcastProcessDataPacket function - Updated rminternals.c 0.97 Jul 03,2002 Allyson & Milena - Now we no longer need to provide max_packet_sent parameter to rmcastplot.bash. The file rmcast.c was modified to write the number of sent packets in the log file (when log is enabled, of course) - Added missing RM_terminate() function call in rmchat.c - Updated rmcast.c tools/scripts/rmcastplot.bash tools/scripts/rmlog.awk examples/rmchat/rmchat.c 0.96 ( cvs tag: rmcast_beta2 ) Jul 02,2002 Allyson & Milena - BUG FOUND & REMOVED: the MAX_MEMBER_CACHE_SIZE and TIMER_DISTRIBUTION option was not properly handled in RM_readConfigFile - Data or retransmission packets from user i with sn > i.last_seq_rcv don't need to be handled (rmcastProcessDataPacket) - Updated: rminternals.c rmcast.c rmmsgpckt.c examples/rmchat/rmchat.c tools/scripts/rmcastplot.bash 0.95 Jul 01,2002 Allyson - BUG REMOVED regarding infinite loop in the rmcastReceivePackets: the problem was caused by a missing pthread_mutex_lock in the rmcastHandleSignals function - BUG REMOVED regarding refresh messages handling: there was an incorrect variable reference in the initialization of the for loop in the rmcastProcessRefreshPacket function - BUG REMOVED regarding sending of retransmissions: wrong ifdef in the rmcastCacheContains function - Idented some files - Created new function cacheCountMembers to count registered members. This function will be used to adjust the timers when the distribution == EXPONENTIAL - Added new defines to rmstruct.h - Improved some comments in rmstruct.h - Updated rminternals.c rmevent.c rmstruct.h rmcache.h rmcache.c examples/rmchat/rmchat.c 0.94 Jun 25,2002 Allyson & Milena - BUG FOUND: program goes to a infinite loop when dealing with NACKs from other members - Temporary debug defined: DNAK_RCV - New actions defined in rmevent.c: SUPPRESSED_NAK and RET_RCV_EXPIRED - NAK receiving and events handle functions rewritten - Updated rminternals.c rmevent.c rmevent.h rmcache.c 0.93 Jun 18,2002 Allyson - Removed BUG regarding refresh messages (rminternals.c) - Removed files doc/inconsistence.HOWTO and doc/join-howto.txt - Removed log directory - Added tools/mcastproxy/Makefile - Updated CONTENTS tools/mcastproxy/mcastproxy.c tools/mcastproxy/README tools/mcastproxy/mcastproxy.conf examples/rmchat/rmchat.c 0.92 Jun 13,2002 Allyson - Updated tools/mcastproxy - Updated CONTENTS, rmmsgpckt.c 0.91 Jun 12,2002 Allyson - Included a new field in all RML(Reliable Multicast Library) packets, called "flags" - Modified files rmstruct.h, rmcast.c, rminternals.c and rmmsgpckt.c to add support for the new field "flags" - Added new application mcastproxy in the tools directory - using this application one can make a "unicast bridge" between 2 or more multicast groups. See README in tools/mcastproxy for further info 0.9 (cvs tag: rmcast_beta1) May 03,2002 Sadoc - Leave group routines implemented. Now members send a LEAVE_GROUP_PACKET before actually leaving the group. 0.8.4 Apr 22,2002 Allyson - Updated files: README, INSTALL, doc/rmcast.config.README, doc/rmcast.config.sample2, examples/rmchat/rmchat.c 0.8.3 Apr 14,2002 Allyson - Updated rmlog.awk and rminternals.c to deal with SINGLE_NACK 0.8.2 Apr 12,2002 Allyson - Some otimization on the code in rmcastReceivePackets related to RET_SND_WAIT event insertion. - Rewritten the generateTimerValue function in rmevent.c. Now we can generate different timer values to each kind of event. 0.8.1 Apr 10,2002 Allyson, Milena & Sadoc - Removed some bugs related to some wrong #ifdef in the code - New updates in scripts to deal with SINGLE_NACK (again!) 0.8 (cvs tag: single_nack_beta2) Apr 08,2002 Allyson, Milena & Sadoc - Updated log functions and scripts to deal with SINGLE_NACK - Removed the 0.7 KNOWN BUG - Removed references to the DEFAULT_TIMER_VALUE vector in rmevent.c when RANDOM_TIMERS is enabled. - Update rmcastProcessRefreshPacket function to work properly when SINGLE_NACK is enabled. - New options available in the doc/rmcast.config.sample2 (see that file for further info): MAX_NAK: indicates the max number of nacks that can be sent for each sn. MAX_MEMBER_CACHE_SIZE: indicates how many packets we will store for each member. - Removed references to MAX_NAK in all files. Now we are using rmcast_option.max_nak instead of MAX_NAK. - Removed references to MAX_MEMBER_CACHE_SIZE in all files. Now we are using rmcast_option.max_member_cache_size instead of MAX_MEMBER_CACHE_SIZE. 0.7 (just a bkp version, not functional. cvs tag: single_nack_bkp) Apr 03,2002 Allyson & Milena - Bounded, correctly this time, the max number of nack that we can send for a packet when using SINGLE_NACK. This number of nacks is bounded by the MAX_NAK constant, defined in rmstruct.c - Removed some bugs related to the insertion of events when using SINGLE_NACK. - New debug defines in Makefile: Now if you want to debug the FULL cache content you must define DCACHE_CONTENTS in addition of DEBUG_SHOW (see Makefile for further info) Now if you want to debug the FULL message content you must define DMSG_CONTENTS in addition of DEBUG_SHOW (see Makefile for further info) - KNOWN BUG: sometimes, in a event list node,the IP string and the PID change their values to strange ones. This stops the sending of nacks and, in consequence, the sending of data to the application. 0.6 (cvs tag: single_nack_beta1) Mar 31,2002 Allyson - Removed some bugs related to the SINGLE_NACK feature. - Added new fields to the log file to support SINGLE_NACK mask logging. - Updated tools/scripts/rmcastplot.bash script to deal with the new fields in the log file. - Removed some old scripts from the CVS repository. - Fixed some (not all) FIXME requests in some files. - Improved debug messages.Now we can "barely" understand what they said - Implemented generation of UNIFORM random timers. (You must define DRANDOM_TIMERS to enable it. See Makefile for details) - New options available in the doc/rmcast.config.sample2 (see that file for further info): TIMER_LOWER: this option replace the old AVG_DELAY option. It's the lower bound for the random timers TIMER_UPPER: the upper bound for the random timers TIMER_DISTRIBUTION: the distribution for the random timers. By now the only possible distribution is UNIFORM. 0.5 Mar 19,2002 Allyson & Milena First try in optimizing nack sending (compile with SINGLE_NACK to enable this feature. See Makefile for details) 0.2 Mar 01,2002 Allyson Included one example application (see the examples directory) 0.2pre7 Feb 14,2002 Allyson Included REFRESH_TIMER option in the option file 0.2pre6 Feb 04,2002 Allyson & Sadoc Several bug fixes regarding SUPPORT_FOR_NEW_USERS. Using new TGIF(QPL) version 4.1.41.82 We have created a configuration file (see doc/rmcast.config.README e doc/rmcast.config.sample). Now the user can set the protocol through the options in that file. Now TGWB has no need to define SUPPORT_FOR_NEW_USERS (use rmcast.config instead) Now "Unicast Mode" is available Updated CONTENTS file 0.2pre5 Nov 22,2001 Allyson, Milena & Sadoc Started testing SUPPORT_FOR_NEW_USERS blocks. The protocol running without the SUPPORT_FOR_NEW_USERS is working well. 0.2pre4 Nov 12 Allyson, Milena & Sadoc We did some changes regarding RedHat 7.2 gcc compability. We didn't test SUPPORT_FOR_NEW_USERS routines. 0.2pre3 Oct 30 Allyson, Milena & Sadoc Finished first level of SUPPORT_FOR_NEW_USERS Obs: The TGWB Makefile,wb.c and mainloop.c files were update too. 0.2pre2 Oct 22 Sadoc & Milena Added some routines related to the support for new users. The changes can be activated defining SUPPORT_FOR_NEW_USERS constant. Obs: The TGWB Makefile,wb.c and mainloop.c files were update too. 0.2pre1 Oct 18 Allyson code clean up Update of README, AUTHORS and INSTALL files Pre-release (0.1) Oct 17 Actually this was the first release. It was used with Tangram2 Whiteboard (tgwb) in Tgif-4.41 by Bill Cheng. Further info about Tgif can be found at: http://bourbon.cs.umd.edu:8001/tgif tgif-QPL-4.2.5/rmcast/mcastproxy/0000755000076400007640000000000011602233155016473 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/mcastproxy/mcastproxy.c0000644000076400007640000003107611073474306021066 0ustar williamwilliam#include #include #include #include #include #include #include #include #include #include #include #define FLAGS 1 #define SENT_BY_PROXY 1 #define NOTSENT_BY_PROXY 0 #define MAX( a, b ) ( (a) > (b) ? (a) : (b) ) #define MAX_PACK_SIZE ( 64 * 1024 ) #define get(dest, org, bytes) { bzero(dest,bytes); memcpy(dest,org, bytes); org+=bytes; } /* Returned errors identification */ #define MP_ERROR_PIDFILE 1 /* Could not create pidfile */ #define MP_ERROR_NOHOME 2 /* HOME environment variable not found */ #define MP_ERROR_OPENCONFFILE 3 /* Could not open config file */ #define MP_ERROR_INVALIDCONFFILE 4 /* Invalid config file */ #define MP_ERROR_RESOLVHOST 5 /* Could not resolve host name */ #define MP_ERROR_MSOCKET 6 /* Could not create multicast socket */ #define MP_ERROR_USOCKET 7 /* Could not create unicast socket */ typedef struct { char *group_addr; char **addr_list; int n_addr; char ttl; int reuse_addr; char enable_loopback; int ucast_port; int mcast_port; } Config; Config config; FILE *fp; char mcastproxy_config_file[255]; typedef void (*sighandler_t)(int); int read_config_file( FILE *, Config * ); void re_read_config_file( int ); int create_ucast_socket( Config * ); int create_mcast_socket( Config *, struct sockaddr_in *); int convert_addr( Config *, struct sockaddr_in *, struct sockaddr_in ** ); void close_mcast_sock( int , struct sockaddr_in * ); void showHosts( int ); int main( int argc, char * argv[] ) { FILE *pidfile; struct sockaddr_in group_addr; struct sockaddr_in * addr_list; fd_set readfds; int mcast_sock, ucast_sock, byread, bysent, i; char pack_buf[MAX_PACK_SIZE]; char mcastproxy_pid_file[255]; char *homedir; unsigned char flags; signal( SIGUSR1, showHosts ); signal( SIGHUP, re_read_config_file ); if( ( homedir = getenv( "HOME" ) ) != NULL ) { sprintf( mcastproxy_pid_file, "%s/.tgwb/mcastproxy.pid", homedir ); if( ( pidfile = fopen( mcastproxy_pid_file, "w" ) ) == NULL ) { fprintf( stderr, "\n[mcastproxy Error] Opening %s file.\n", mcastproxy_pid_file ); exit( MP_ERROR_PIDFILE ); } fprintf( pidfile, "%d", (int)getpid() ); fclose( pidfile ); } else { fprintf( stderr, "\n[mcastproxy Error] $HOME environment variable not found\n" ); exit( MP_ERROR_NOHOME ); } printf( "\n----------------------------\n" ); printf( "Starting mcastproxy ...\n" ); printf( "\tReading mcastproxy.conf ..." ); sprintf( mcastproxy_config_file, "%s/.tgwb/mcastproxy.conf", homedir ); if( ( fp = fopen( mcastproxy_config_file, "r" ) ) == NULL ) { fprintf( stderr, "\n[mcastproxy Error] Opening configuration file '%s'\n", mcastproxy_config_file ); exit( MP_ERROR_OPENCONFFILE ); } if( read_config_file( fp, &config ) < 0 ) { fprintf( stderr, "\n[mcastproxy Error] Invalid Configuration file." ); exit( MP_ERROR_INVALIDCONFFILE ); } printf( " OK!\n" ); if( convert_addr( &config, &group_addr, &addr_list ) < 0 ) { fprintf(stderr,"\n\n[mcastproxy Error] Could not resolve host.\n" ); exit( MP_ERROR_RESOLVHOST ); } mcast_sock = create_mcast_socket( &config, &group_addr ); if( mcast_sock < 0 ) { fprintf(stderr,"\n[mcastproxy Error] Creating the multicast socket." ); exit( MP_ERROR_MSOCKET ); } ucast_sock = create_ucast_socket( &config ); if( ucast_sock < 0 ) { fprintf(stderr,"\n[mcastproxy Error] Creating the unicast socket.\n" ); exit( MP_ERROR_USOCKET ); } printf( "mcastproxy is running.\n" ); printf( "----------------------------\n" ); flags = NOTSENT_BY_PROXY; while( 1 ) { FD_ZERO( &readfds ); FD_SET( mcast_sock, &readfds ); FD_SET( ucast_sock, &readfds ); if( select( MAX( mcast_sock, ucast_sock ) + 1, &readfds, NULL, NULL, NULL ) < 0 ) { /* fprintf( stderr, "\n[mcastproxy warning] Select error." ); */ continue; } if( FD_ISSET( mcast_sock, &readfds ) ) { byread = recv( mcast_sock, pack_buf, MAX_PACK_SIZE, 0 ); if( byread > 0 ) { for( i = 0; i < config.n_addr; i++ ) { if( config.enable_loopback == 1 ) flags = pack_buf[ FLAGS ]; if( ( config.enable_loopback == 0 ) || ( flags != SENT_BY_PROXY ) ) { bysent = sendto( ucast_sock, pack_buf, byread, 0, (struct sockaddr *)&addr_list[ i ], sizeof( struct sockaddr ) ); if( bysent < 0 ) perror( "sendto" ); usleep( 1 ); } } } } if( FD_ISSET( ucast_sock, &readfds ) ) { byread = recv( ucast_sock, pack_buf, MAX_PACK_SIZE, 0 ); if( byread > 0 ) { memset( &group_addr, 0, sizeof( group_addr ) ); group_addr.sin_family = AF_INET; group_addr.sin_port = htons(config.mcast_port); group_addr.sin_addr.s_addr = inet_addr( config.group_addr ); if( config.enable_loopback == 1 ) pack_buf[ FLAGS ] = SENT_BY_PROXY; bysent = sendto( mcast_sock, pack_buf, byread, 0, (struct sockaddr *) &group_addr, sizeof( struct sockaddr ) ); if( bysent < 0 ){ perror( "sendto" ); } usleep( 1 ); } } } close_mcast_sock( mcast_sock, &group_addr ); close( ucast_sock ); return EXIT_SUCCESS; } int read_config_file( FILE * fp, Config * config ) { char line[100]; char *temp; int i; if( fgets( line, 100, fp ) == NULL ) return -1; if( ( temp = strchr( line, '=' ) ) == NULL ) return -1; temp++; if( temp[ strlen( temp ) - 1 ] == '\n' ) temp[ strlen( temp ) - 1 ] = '\0'; config->group_addr = strdup( temp ); if( fgets( line, 100, fp ) == NULL ) return -1; if( ( temp = strchr( line, '=' ) ) == NULL ) return -1; temp++; config->n_addr = atoi( temp ); config->addr_list = ( char ** ) malloc( sizeof(char *) * config->n_addr ); if( fgets( line, 100, fp ) == NULL ) return -1; /* We will read one IP address or hostname per line */ for ( i = 0; i < config->n_addr; i++ ) { if( fgets( line, 100, fp ) == NULL ) return -1; line[ strlen( line ) - 1 ] = '\0'; config->addr_list[ i ] = strdup( line ); } if( fgets( line, 100, fp ) == NULL ) return -1; if( ( temp = strchr( line, '=' ) ) == NULL ) return -1; temp++; config->ttl = (char) atoi( temp ); if( fgets( line, 100, fp ) == NULL ) return -1; if( ( temp = strchr( line, '=' ) ) == NULL ) return -1; temp++; config->reuse_addr = atoi( temp ); if( fgets( line, 100, fp ) == NULL ) return -1; if( ( temp = strchr( line, '=' ) ) == NULL ) return -1; temp++; config->enable_loopback = (char) atoi( temp ); if( fgets( line, 100, fp ) == NULL ) return -1; if( ( temp = strchr( line, '=' ) ) == NULL ) return -1; temp++; config->ucast_port = atoi( temp ); if( fgets( line, 100, fp ) == NULL ) return -1; if( ( temp = strchr( line, '=' ) ) == NULL ) return -1; temp++; config->mcast_port = atoi( temp ); return 0; } void re_read_config_file( int signo ) { if( ( fp = fopen( mcastproxy_config_file, "r" ) ) == NULL ) { fprintf( stderr, "\n[mcastproxy Error] Opening configuration file '%s'\n", mcastproxy_config_file ); exit( MP_ERROR_OPENCONFFILE ); } if( read_config_file( fp, &config ) < 0 ) { fprintf( stderr, "\n[mcastproxy Error] Invalid new configuration file." ); exit( MP_ERROR_INVALIDCONFFILE ); } } int create_ucast_socket( Config * config ) { int sckd; struct sockaddr_in addr; memset( &addr, 0, sizeof( addr ) ); sckd = socket( AF_INET, SOCK_DGRAM, 0 ); if( sckd > 0 ) { addr.sin_family = AF_INET; addr.sin_addr.s_addr = INADDR_ANY; addr.sin_port = htons( config->ucast_port ); if( bind( sckd, (struct sockaddr *) &addr, sizeof( addr ) ) < 0 ) { perror( "Binding" ); return -1; } } return sckd; } int create_mcast_socket( Config * config , struct sockaddr_in * group_addr) { int sckd; unsigned char byte; /* variable used to enable/disable loopback */ struct sockaddr_in groupHost; /* multicast group host info structure */ struct ip_mreq mreq; /* multicast group info structure */ byte = 1; /* Get the multicast group host information */ groupHost.sin_family = AF_INET; groupHost.sin_port = htons(config->mcast_port); groupHost.sin_addr.s_addr = htonl(INADDR_ANY); /* Allocate a UDP socket and set the multicast options */ if( ( sckd = socket( AF_INET, SOCK_DGRAM, 0 ) ) < 0 ) { perror( "create socket" ); return -1; } /* allow multipule processes to bind to same multicast port */ if( setsockopt( sckd, SOL_SOCKET, SO_REUSEADDR, &(config->reuse_addr), sizeof( config->reuse_addr ) ) == -1 ) { perror( "setsockopt SO_REUSEADDR" ); return -1; } /* bind the UDP socket to the mcast address to recv messages from the group */ if( bind( sckd,(struct sockaddr *) &groupHost, sizeof( groupHost ) ) < 0 ) { perror( "bind" ); return -1; } byte = config->ttl; if( setsockopt( sckd, IPPROTO_IP, IP_MULTICAST_TTL, &byte, sizeof( byte ) ) < 0 ) { perror( "setsockopt IP_MULTICAST_TTL" ); return -1; } byte = config->enable_loopback; /*enable loopback*/ if( setsockopt( sckd, IPPROTO_IP,IP_MULTICAST_LOOP, (char *)&byte, sizeof( byte ) ) < 0 ) { perror( "setsockopt IP_MULTICAST_LOOP" ); return -1; } /* check if group address is indeed a Class D address */ mreq.imr_multiaddr = group_addr->sin_addr; mreq.imr_interface.s_addr = INADDR_ANY; if ( setsockopt( sckd, IPPROTO_IP, IP_ADD_MEMBERSHIP, (char *) &mreq, sizeof( mreq ) ) < 0 ) { perror( "setsockopt IP_ADD_MEMBERSHIP" ); return -1; } return sckd; } int convert_addr( Config * config, struct sockaddr_in * group_addr, struct sockaddr_in ** addr_list ) { struct hostent *host; int i; memset( group_addr, 0, sizeof( *group_addr ) ); group_addr->sin_family = AF_INET; group_addr->sin_port = htons( config->mcast_port ); group_addr->sin_addr.s_addr = inet_addr( config->group_addr ); (*addr_list) = (struct sockaddr_in *) malloc( config->n_addr * sizeof( struct sockaddr_in ) ) ; for( i = 0; i < config->n_addr; i++ ) { memset( &((*addr_list)[ i ]), 0, sizeof( (*addr_list)[ i ] ) ); (*addr_list)[ i ].sin_family = AF_INET; (*addr_list)[ i ].sin_port = htons( config->ucast_port ); printf( "\tAdding host %s ...", config->addr_list[ i ] ); host = gethostbyname( config->addr_list[ i ] ); if( host == 0 ) { fprintf( stderr, "\n[mcastproxy Error] Resolving host '%s'\n", config->addr_list[ i ] ); return -1; } printf( " OK!\n" ); memcpy( &((*addr_list)[ i ].sin_addr), host->h_addr, host->h_length ); } return 0; } void close_mcast_sock( int mcast_sock, struct sockaddr_in * group_addr ) { struct ip_mreq dreq; /* multicast group info structure */ dreq.imr_multiaddr = group_addr->sin_addr; dreq.imr_interface.s_addr = INADDR_ANY; setsockopt( mcast_sock, IPPROTO_IP, IP_DROP_MEMBERSHIP, (char *) &dreq,sizeof( dreq ) ); } void showHosts( int signo ) { int i; for( i = 0; i < config.n_addr; i++ ) fprintf( stdout, "Host %2d: %s\n", i, config.addr_list[ i ] ); return; } tgif-QPL-4.2.5/rmcast/mcastproxy/Makefile.in0000644000076400007640000003726111566506143020562 0ustar williamwilliam# Makefile.in generated by automake 1.9.6 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = .. am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ bin_PROGRAMS = mcastproxy$(EXEEXT) subdir = mcastproxy DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/configure.in am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/config/mkinstalldirs CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = am__installdirs = "$(DESTDIR)$(bindir)" binPROGRAMS_INSTALL = $(INSTALL_PROGRAM) PROGRAMS = $(bin_PROGRAMS) am_mcastproxy_OBJECTS = mcastproxy-mcastproxy.$(OBJEXT) mcastproxy_OBJECTS = $(am_mcastproxy_OBJECTS) mcastproxy_LDADD = $(LDADD) DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/config/depcomp am__depfiles_maybe = depfiles COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(LIBTOOL) --tag=CC --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ SOURCES = $(mcastproxy_SOURCES) DIST_SOURCES = $(mcastproxy_SOURCES) ETAGS = etags CTAGS = ctags DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMDEP_FALSE = @AMDEP_FALSE@ AMDEP_TRUE = @AMDEP_TRUE@ AMTAR = @AMTAR@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DSYMUTIL = @DSYMUTIL@ ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ F77 = @F77@ FFLAGS = @FFLAGS@ GREP = @GREP@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ NMEDIT = @NMEDIT@ OBJEXT = @OBJEXT@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ VERSION = @VERSION@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_F77 = @ac_ct_F77@ am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@ am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ mcastproxy_SOURCES = mcastproxy.c mcastproxy_CFLAGS = -Wall all: all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu mcastproxy/Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --gnu mcastproxy/Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) test -z "$(bindir)" || $(mkdir_p) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; for p in $$list; do \ p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ if test -f $$p \ || test -f $$p1 \ ; then \ f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \ echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ else :; fi; \ done uninstall-binPROGRAMS: @$(NORMAL_UNINSTALL) @list='$(bin_PROGRAMS)'; for p in $$list; do \ f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \ echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \ rm -f "$(DESTDIR)$(bindir)/$$f"; \ done clean-binPROGRAMS: @list='$(bin_PROGRAMS)'; for p in $$list; do \ f=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ echo " rm -f $$p $$f"; \ rm -f $$p $$f ; \ done mcastproxy$(EXEEXT): $(mcastproxy_OBJECTS) $(mcastproxy_DEPENDENCIES) @rm -f mcastproxy$(EXEEXT) $(LINK) $(mcastproxy_LDFLAGS) $(mcastproxy_OBJECTS) $(mcastproxy_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mcastproxy-mcastproxy.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c $< .c.obj: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ `$(CYGPATH_W) '$<'`; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` .c.lo: @am__fastdepCC_TRUE@ if $(LTCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Plo"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< mcastproxy-mcastproxy.o: mcastproxy.c @am__fastdepCC_TRUE@ if $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(mcastproxy_CFLAGS) $(CFLAGS) -MT mcastproxy-mcastproxy.o -MD -MP -MF "$(DEPDIR)/mcastproxy-mcastproxy.Tpo" -c -o mcastproxy-mcastproxy.o `test -f 'mcastproxy.c' || echo '$(srcdir)/'`mcastproxy.c; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/mcastproxy-mcastproxy.Tpo" "$(DEPDIR)/mcastproxy-mcastproxy.Po"; else rm -f "$(DEPDIR)/mcastproxy-mcastproxy.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='mcastproxy.c' object='mcastproxy-mcastproxy.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(mcastproxy_CFLAGS) $(CFLAGS) -c -o mcastproxy-mcastproxy.o `test -f 'mcastproxy.c' || echo '$(srcdir)/'`mcastproxy.c mcastproxy-mcastproxy.obj: mcastproxy.c @am__fastdepCC_TRUE@ if $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(mcastproxy_CFLAGS) $(CFLAGS) -MT mcastproxy-mcastproxy.obj -MD -MP -MF "$(DEPDIR)/mcastproxy-mcastproxy.Tpo" -c -o mcastproxy-mcastproxy.obj `if test -f 'mcastproxy.c'; then $(CYGPATH_W) 'mcastproxy.c'; else $(CYGPATH_W) '$(srcdir)/mcastproxy.c'; fi`; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/mcastproxy-mcastproxy.Tpo" "$(DEPDIR)/mcastproxy-mcastproxy.Po"; else rm -f "$(DEPDIR)/mcastproxy-mcastproxy.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='mcastproxy.c' object='mcastproxy-mcastproxy.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(mcastproxy_CFLAGS) $(CFLAGS) -c -o mcastproxy-mcastproxy.obj `if test -f 'mcastproxy.c'; then $(CYGPATH_W) 'mcastproxy.c'; else $(CYGPATH_W) '$(srcdir)/mcastproxy.c'; fi` mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique; \ fi ctags: CTAGS CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ list='$(DISTFILES)'; for file in $$list; do \ case $$file in \ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ esac; \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkdir_p) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(PROGRAMS) installdirs: for dir in "$(DESTDIR)$(bindir)"; do \ test -z "$$dir" || $(mkdir_p) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-libtool distclean-tags dvi: dvi-am dvi-am: html: html-am info: info-am info-am: install-data-am: install-exec-am: install-binPROGRAMS install-info: install-info-am install-man: installcheck-am: maintainer-clean: maintainer-clean-am -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-binPROGRAMS uninstall-info-am .PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ clean-generic clean-libtool ctags distclean distclean-compile \ distclean-generic distclean-libtool distclean-tags distdir dvi \ dvi-am html html-am info info-am install install-am \ install-binPROGRAMS install-data install-data-am install-exec \ install-exec-am install-info install-info-am install-man \ install-strip installcheck installcheck-am installdirs \ maintainer-clean maintainer-clean-generic mostlyclean \ mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ pdf pdf-am ps ps-am tags uninstall uninstall-am \ uninstall-binPROGRAMS uninstall-info-am # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: tgif-QPL-4.2.5/rmcast/mcastproxy/Makefile.am0000644000076400007640000000012410434752620020531 0ustar williamwilliambin_PROGRAMS = mcastproxy mcastproxy_SOURCES= mcastproxy.c mcastproxy_CFLAGS= -Wall tgif-QPL-4.2.5/rmcast/mcastproxy/README0000644000076400007640000000421110122646342017353 0ustar williamwilliamMulticast "Proxy" This is application should be used to build a "unicast bridge" between 2 or more multicast groups. ---------------- Using mcastproxy ---------------- For instance, suppose one want to run a multicast session in 2 networks A and B. A and B have local multicast support but there is no such support between them. So, we can simulate this support using mcastproxy following the steps below: 1. Choose a machine in network A, e.g., m1.A 2. Choose a machine in network B, e.g., m1.B 3. Before starting run mcastproxy in m1.A you must fill the mcastproxy.conf file with the options (See "The mcastproxy Config File Options" section below): GROUPADDR=225.1.2.3 NADDR=1 ADDRLIST m1.B TTL=1 REUSEADDR=1 LOOPBACK=0 UCASTPORT=32566 MCASTPORT=5151 4. In m1.B the mcastproxy.conf file should be like: GROUPADDR=225.1.2.3 NADDR=1 ADDRLIST m1.A TTL=1 REUSEADDR=1 LOOPBACK=0 UCASTPORT=32566 MCASTPORT=5151 5. When both mcastproxies are running, you can use any Reliable Multicast Library based application through A and B. ---------------------------------- The mcastproxy Config File Options ---------------------------------- GROUPADDR The IP multicast group address NADDR Number of proxies addresses to send data to ADDRLIST After this it will be the address list of other proxies you will send data to (one per line) TTL Time to Live for the multicast packets REUSEADDR Enable address reuse LOOPBACK Enable loopback. Values: 0 - loopback disabled. You MUST NOT run a multicast client in the same host which you are running mcastproxy 1 - loopback enabled. This will work only for special packets such as the ones from Reliable Multicast Library UCASTPORT Unicast port where you will listen to. This will be the same port to where you have to send packets to MCASTPORT Multicast port where you will listen and send packets to tgif-QPL-4.2.5/rmcast/README.tgwb0000644000076400007640000002170711112562556016121 0ustar williamwilliamThis is the ``tgwb - Tangram Whiteboard'' README file. Contents: 1. Introduction 2. Compiling and installing 2.1 Tgif version prior to 4.1.46 2.2 Tgif version 4.1.46 and newer 3. Using 3.1 Environment 3.2 Configuration 3.3 mcastproxy 4. Known bugs 5. Further information 1. Introduction This section describes a whiteboard tool built on top of TGIF: TGWB (Tangram Whiteboard). The tgwb allows simultaneous modifications in drawings by users in a group. It is a versatile multicast distributed tool. TGWB is a module of the Tangram2, developed at LAND (http://www.land.ufrj.br). Distributed whiteboards must ensure that every member in a session has the same view of the drawings. A Reliable Multicast Library and a total ordering mechanism was developed to allow reliable multicast transmission and member view consistency. 2. Compiling and installing 2.1 Tgif versions prior to 4.1.16 TGWB is basically tgif with 3 noted differences: a) Modify Target.tmpl and change TARGET_1 to tgwb as follows: TARGET_1 = tgwb-bin b) Follow the instructions in the README file for tgif. Make all the selections and modifications you need for Tgif.tmpl. Right before you build (starting from running "xmkmf"), do the following in Tgif.tmpl: i) Replace "tgif" in the PROGRAMS line by "tgwb-bin" ii) Append the following compiler option to the MOREDEFINES line: -D_TGIF_WB2 iii) Add the following line after the SYS_LIBRARIES line: EXTRA_LIBRARIES = -L./rmcast/src -lz -lpthread -lrmcast c) This version requires the rmcast library which is included with the distribution. To build the rmcast library, simple do: cd rmcast ./configure make cd .. d) Then build tgwb: xmkmf make tgwb e) To install, execute as root: make install-tgwb 2.2 Tgif version 4.1.46 or newer Since version 4.1.46, tgif will load the reliable multicast library dynamically. If you want to use the whiteboard mode you will have to execute the following steps: a) Compile and install tgif: cd tgif- xmkf make make install b) Compile and install the reliable multicast library included in the rmcast directory within the tgif code: cd rmcast ./configure make make install OBS: to install the library in the default location (/usr/local/lib) you will need root privileges. To run tgif in whiteboard mode execute: tgif -tgwb2 OBS: If tgif could not find the reliable multicast library, you can try: tgif -tgwb2 -rmcastlibdir For instance, if librmcast.so is in the /usr/local/lib directory you can execute: tgif -tgwb2 -rmcastlibdir /usr/local/lib 3. Using TGWB 3.1 Environment The TGWB tool was develop to be used in a IP Multicast network. If Multicast is not available one can use the mcastproxy program to connect the whiteboards. More information about mcastproxy can be found in section 3.3. 3.2 TGWB Configuration The reliable multicast transmission was implemented as a function library called RML (Reliable Multicast Library). When tgwb is started the user is prompted for configuration options, such as multicast address and port and whether or not the mcastproxy (see section 3.3) program should be started. Another way to customize RML options is editing the configure file tgwb.conf, located at .tgwb directory in the user's home. The following is a TGWB configuration file example: ######################################################################### #Reliable Multicast Library configuration file #Reliable Multicast Library version RM_VERSION=1.0 #Transmission mode: 0 multicast (default), 1 unicast TRANSMISSION_MODE=0 #Multicast or Unicast IP address to send data (destination IP) DEST_IP=225.1.2.3 #Multicast or Unicast port to send data (destination port) DEST_PORT=5151 #Time to live for the packets setting (1 indicates local network) TTL=1 #Inter-packet sleep timer: #Time between packet transmissions ( choose from 0 to 65535 microseconds) MICROSLEEP=10 #Log file path - NULL disable logging (default) LOG_FILE=NULL #Random Timers Distribution: 0 uniform 1 exponential TIMER_DISTRIBUTION=0 #Timer parameters # Timers values are obtained in the intervals: # (TIMER_PARAM_A*T,(TIMER_PARAM_A+TIMER_PARAM_B)*T) for NAKs # (TIMER_PARAM_C*T,(TIMER_PARAM_C+TIMER_PARAM_D)*T) for wait for retransmitions # (TIMER_PARAM_E*T,(TIMER_PARAM_C+TIMER_PARAM_F)*T) for for retransmitions # Where # TIMER_PARAM_A, TIMER_PARAM_B, TIMER_PARAM_C, TIMER_PARAM_D, TIMER_PARAM_E and # TIMER_PARAM_F are integer constants # T is the estimated one-way delay to the senders TIMER_PARAM_A=2 TIMER_PARAM_B=2 TIMER_PARAM_C=5 TIMER_PARAM_D=2 TIMER_PARAM_E=2 TIMER_PARAM_F=2 #Host related parameters and timers: # Must contain exactly the following lines: # HOSTS_IDENTIFIED=0 # DEFAULT # host1 # host2 # ... # hostN # If HOSTS_IDENTIFIED=0 then we will read only the DEFAULT # estimated delay. HOSTS_IDENTIFIED=0 DEFAULT 50 #Max number of naks that can be sent for each packet. 100 (default) MAX_NAK=100 # We will be able to retransmit the last MAX_MEMBER_CACHE_SIZE packets from each # member of the multicast group, i.e., we will store the last # MAX_MEMBER_CACHE_SIZE PACKETS from each member of the multicast group in the # cache. 4000 (default) # # WARNING: if you set MAX_MEMBER_CACHE_SIZE to low values the protocol may fail! # MAX_MEMBER_CACHE_SIZE=4000 #Enable support for new members 1 enabled (default), 0 disabled NEW_MEMBER_SUPPORT=0 #Show transmission statistics: 0 disabled (default) 1 enabled STATISTICS=0 #Time between transmission of refresh messages (seconds) REFRESH_TIMER=10 #Loss simulation: 0 disabled (default) any float number > 0 enabled # # A note about loss simulation: # When loss simulation is enabled (LOSS_PROB > 0) we always loose the first 10 # received packets, and the first received data packet - that is, # the first burst of received packets. # After that, packets are lost according to LOSS_PROB. # Example: LOSS_PROB=30 # The first 10 received packets will be lost. # Then, 30% of the packets will be lost LOSS_PROB=0 # Time to wait, in microseconds, before leaving the multicast group. LEAVE_GROUP_WAIT_TIME=500000 # Size of the buffer of the receiver host # (maximum size of a message that may be processed by the receiver host). RCV_BUFFER_SIZE=10000 ######################################################################### 3.3 mcastproxy When IP Multicast is not available the mcastproxy program can be used to connect hosts. Suppose that students from two different campi want to use TGWB. Suppose also that multicast is available in the local networks but it is not available among the campi. In that scenario, illustrated in figure below, the mcastproxy program can be used to connect each campi. There will be one instance of mcastproxy in each campus. Each mcastproxy instance can listen to local multicast traffic and send it unicast to each other campus. The packets received through unicast are sent through multicast to local users. Campus 1 Network <----Multicast----> mcastproxy1 | | | | Unicast | | | | Campus 2 Network <----Multicast----> mcastproxy2 mcastproxy program uses a configuration file, mcastproxy.conf from the .tgwb directory located at user's home. Next is presented an example of this file. ############################################ #Multicast group address GROUPADDR=225.1.2.3 #Number of hosts to send unicast packets NADDR=2 #IP Addresses list to send unicast packets ADDRLIST 192.168.1.2 10.0.0.1 # Time to live for multicast packets TTL=1 REUSEADDR=0 # Loopback: 1 enable, 0 disable LOOPBACK=1 # Unicast port to use UCASTPORT=32566 # Multicast port to use MCASTPORT=5151 ############################################ 4. Known bugs The current release of tgwb has a few known bugs. The major one being that there is no provision made for joining a whiteboard in session; the way to get around this problem is to select New from the File Menu of a tgwb to clear all whiteboards. 5. Further Information Please read the "Copyright" file in this distribution for the copyright and licensing information. Further information can be found in the RML documentation or at http://www.land.ufrj.br/tools/rmcast tgif-QPL-4.2.5/rmcast/AUTHORS0000644000076400007640000000024210122646341015331 0ustar williamwilliamJorge Allyson Azevedo Milena Scanferla Daniel Sadoc Menasche Thanks to Magnos Martinello tgif-QPL-4.2.5/rmcast/aclocal.m40000644000076400007640000101644511566506143016146 0ustar williamwilliam# generated automatically by aclocal 1.9.6 -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, # 2005 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- # serial 52 Debian 1.5.26-1ubuntu1 AC_PROG_LIBTOOL # AC_PROVIDE_IFELSE(MACRO-NAME, IF-PROVIDED, IF-NOT-PROVIDED) # ----------------------------------------------------------- # If this macro is not defined by Autoconf, define it here. m4_ifdef([AC_PROVIDE_IFELSE], [], [m4_define([AC_PROVIDE_IFELSE], [m4_ifdef([AC_PROVIDE_$1], [$2], [$3])])]) # AC_PROG_LIBTOOL # --------------- AC_DEFUN([AC_PROG_LIBTOOL], [AC_REQUIRE([_AC_PROG_LIBTOOL])dnl dnl If AC_PROG_CXX has already been expanded, run AC_LIBTOOL_CXX dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX. AC_PROVIDE_IFELSE([AC_PROG_CXX], [AC_LIBTOOL_CXX], [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX ])]) dnl And a similar setup for Fortran 77 support AC_PROVIDE_IFELSE([AC_PROG_F77], [AC_LIBTOOL_F77], [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77 ])]) dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly. dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both. AC_PROVIDE_IFELSE([AC_PROG_GCJ], [AC_LIBTOOL_GCJ], [AC_PROVIDE_IFELSE([A][M_PROG_GCJ], [AC_LIBTOOL_GCJ], [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ], [AC_LIBTOOL_GCJ], [ifdef([AC_PROG_GCJ], [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])]) ifdef([A][M_PROG_GCJ], [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])]) ifdef([LT_AC_PROG_GCJ], [define([LT_AC_PROG_GCJ], defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])]) ])])# AC_PROG_LIBTOOL # _AC_PROG_LIBTOOL # ---------------- AC_DEFUN([_AC_PROG_LIBTOOL], [AC_REQUIRE([AC_LIBTOOL_SETUP])dnl AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl # This can be used to rebuild libtool when needed LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' AC_SUBST(LIBTOOL)dnl # Prevent multiple expansion define([AC_PROG_LIBTOOL], []) ])# _AC_PROG_LIBTOOL # AC_LIBTOOL_SETUP # ---------------- AC_DEFUN([AC_LIBTOOL_SETUP], [AC_PREREQ(2.50)dnl AC_REQUIRE([AC_ENABLE_SHARED])dnl AC_REQUIRE([AC_ENABLE_STATIC])dnl AC_REQUIRE([AC_ENABLE_FAST_INSTALL])dnl AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_PROG_LD])dnl AC_REQUIRE([AC_PROG_LD_RELOAD_FLAG])dnl AC_REQUIRE([AC_PROG_NM])dnl AC_REQUIRE([AC_PROG_LN_S])dnl AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! AC_REQUIRE([AC_OBJEXT])dnl AC_REQUIRE([AC_EXEEXT])dnl dnl AC_LIBTOOL_SYS_MAX_CMD_LEN AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE AC_LIBTOOL_OBJDIR AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl _LT_AC_PROG_ECHO_BACKSLASH case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test "X${COLLECT_NAMES+set}" != Xset; then COLLECT_NAMES= export COLLECT_NAMES fi ;; esac # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. Xsed='sed -e 1s/^X//' [sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g'] # Same as above, but do not quote variable references. [double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g'] # Sed substitution to delay expansion of an escaped shell variable in a # double_quote_subst'ed string. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' # Sed substitution to avoid accidental globbing in evaled expressions no_glob_subst='s/\*/\\\*/g' # Constants: rm="rm -f" # Global variables: default_ofile=libtool can_build_shared=yes # All known linkers require a `.a' archive for static linking (except MSVC, # which needs '.lib'). libext=a ltmain="$ac_aux_dir/ltmain.sh" ofile="$default_ofile" with_gnu_ld="$lt_cv_prog_gnu_ld" AC_CHECK_TOOL(AR, ar, false) AC_CHECK_TOOL(RANLIB, ranlib, :) AC_CHECK_TOOL(STRIP, strip, :) old_CC="$CC" old_CFLAGS="$CFLAGS" # Set sane defaults for various variables test -z "$AR" && AR=ar test -z "$AR_FLAGS" && AR_FLAGS=cru test -z "$AS" && AS=as test -z "$CC" && CC=cc test -z "$LTCC" && LTCC=$CC test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS test -z "$DLLTOOL" && DLLTOOL=dlltool test -z "$LD" && LD=ld test -z "$LN_S" && LN_S="ln -s" test -z "$MAGIC_CMD" && MAGIC_CMD=file test -z "$NM" && NM=nm test -z "$SED" && SED=sed test -z "$OBJDUMP" && OBJDUMP=objdump test -z "$RANLIB" && RANLIB=: test -z "$STRIP" && STRIP=: test -z "$ac_objext" && ac_objext=o # Determine commands to create old-style static archives. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" ;; *) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" fi _LT_CC_BASENAME([$compiler]) # Only perform the check for file, if the check method requires it case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then AC_PATH_MAGIC fi ;; esac _LT_REQUIRED_DARWIN_CHECKS AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no) AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], enable_win32_dll=yes, enable_win32_dll=no) AC_ARG_ENABLE([libtool-lock], [AC_HELP_STRING([--disable-libtool-lock], [avoid locking (might break parallel builds)])]) test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes AC_ARG_WITH([pic], [AC_HELP_STRING([--with-pic], [try to use only PIC/non-PIC objects @<:@default=use both@:>@])], [pic_mode="$withval"], [pic_mode=default]) test -z "$pic_mode" && pic_mode=default # Use C for the default configuration in the libtool script tagname= AC_LIBTOOL_LANG_C_CONFIG _LT_AC_TAGCONFIG ])# AC_LIBTOOL_SETUP # _LT_AC_SYS_COMPILER # ------------------- AC_DEFUN([_LT_AC_SYS_COMPILER], [AC_REQUIRE([AC_PROG_CC])dnl # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC ])# _LT_AC_SYS_COMPILER # _LT_CC_BASENAME(CC) # ------------------- # Calculate cc_basename. Skip known compiler wrappers and cross-prefix. AC_DEFUN([_LT_CC_BASENAME], [for cc_temp in $1""; do case $cc_temp in compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` ]) # _LT_COMPILER_BOILERPLATE # ------------------------ # Check for compiler boilerplate output or warnings with # the simple compiler test code. AC_DEFUN([_LT_COMPILER_BOILERPLATE], [AC_REQUIRE([LT_AC_PROG_SED])dnl ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $rm conftest* ])# _LT_COMPILER_BOILERPLATE # _LT_LINKER_BOILERPLATE # ---------------------- # Check for linker boilerplate output or warnings with # the simple link test code. AC_DEFUN([_LT_LINKER_BOILERPLATE], [AC_REQUIRE([LT_AC_PROG_SED])dnl ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $rm -r conftest* ])# _LT_LINKER_BOILERPLATE # _LT_REQUIRED_DARWIN_CHECKS # -------------------------- # Check for some things on darwin AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS],[ case $host_os in rhapsody* | darwin*) AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:]) AC_CHECK_TOOL([NMEDIT], [nmedit], [:]) AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], [lt_cv_apple_cc_single_mod=no if test -z "${LT_MULTI_MODULE}"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. echo "int foo(void){return 1;}" > conftest.c $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib ${wl}-single_module conftest.c if test -f libconftest.dylib; then lt_cv_apple_cc_single_mod=yes rm -rf libconftest.dylib* fi rm conftest.c fi]) AC_CACHE_CHECK([for -exported_symbols_list linker flag], [lt_cv_ld_exported_symbols_list], [lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], [lt_cv_ld_exported_symbols_list=yes], [lt_cv_ld_exported_symbols_list=no]) LDFLAGS="$save_LDFLAGS" ]) case $host_os in rhapsody* | darwin1.[[0123]]) _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; darwin*) # if running on 10.5 or later, the deployment target defaults # to the OS version, if on x86, and 10.4, the deployment # target defaults to 10.4. Don't you love it? case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 10.[[012]]*) _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 10.*) _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; esac ;; esac if test "$lt_cv_apple_cc_single_mod" = "yes"; then _lt_dar_single_mod='$single_module' fi if test "$lt_cv_ld_exported_symbols_list" = "yes"; then _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' else _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}" fi if test "$DSYMUTIL" != ":"; then _lt_dsymutil="~$DSYMUTIL \$lib || :" else _lt_dsymutil= fi ;; esac ]) # _LT_AC_SYS_LIBPATH_AIX # ---------------------- # Links a minimal program and checks the executable # for the system default hardcoded library path. In most cases, # this is /usr/lib:/lib, but when the MPI compilers are used # the location of the communication and MPI libs are included too. # If we don't find anything, use the default library path according # to the aix ld manual. AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX], [AC_REQUIRE([LT_AC_PROG_SED])dnl AC_LINK_IFELSE(AC_LANG_PROGRAM,[ lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi],[]) if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi ])# _LT_AC_SYS_LIBPATH_AIX # _LT_AC_SHELL_INIT(ARG) # ---------------------- AC_DEFUN([_LT_AC_SHELL_INIT], [ifdef([AC_DIVERSION_NOTICE], [AC_DIVERT_PUSH(AC_DIVERSION_NOTICE)], [AC_DIVERT_PUSH(NOTICE)]) $1 AC_DIVERT_POP ])# _LT_AC_SHELL_INIT # _LT_AC_PROG_ECHO_BACKSLASH # -------------------------- # Add some code to the start of the generated configure script which # will find an echo command which doesn't interpret backslashes. AC_DEFUN([_LT_AC_PROG_ECHO_BACKSLASH], [_LT_AC_SHELL_INIT([ # Check that we are running under the correct shell. SHELL=${CONFIG_SHELL-/bin/sh} case X$ECHO in X*--fallback-echo) # Remove one level of quotation (which was required for Make). ECHO=`echo "$ECHO" | sed 's,\\\\\[$]\\[$]0,'[$]0','` ;; esac echo=${ECHO-echo} if test "X[$]1" = X--no-reexec; then # Discard the --no-reexec flag, and continue. shift elif test "X[$]1" = X--fallback-echo; then # Avoid inline document here, it may be left over : elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then # Yippee, $echo works! : else # Restart under the correct shell. exec $SHELL "[$]0" --no-reexec ${1+"[$]@"} fi if test "X[$]1" = X--fallback-echo; then # used as fallback echo shift cat </dev/null 2>&1 && unset CDPATH if test -z "$ECHO"; then if test "X${echo_test_string+set}" != Xset; then # find a string as large as possible, as long as the shell can cope with it for cmd in 'sed 50q "[$]0"' 'sed 20q "[$]0"' 'sed 10q "[$]0"' 'sed 2q "[$]0"' 'echo test'; do # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... if (echo_test_string=`eval $cmd`) 2>/dev/null && echo_test_string=`eval $cmd` && (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null then break fi done fi if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then : else # The Solaris, AIX, and Digital Unix default echo programs unquote # backslashes. This makes it impossible to quote backslashes using # echo "$something" | sed 's/\\/\\\\/g' # # So, first we look for a working echo in the user's PATH. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for dir in $PATH /usr/ucb; do IFS="$lt_save_ifs" if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then echo="$dir/echo" break fi done IFS="$lt_save_ifs" if test "X$echo" = Xecho; then # We didn't find a better echo, so look for alternatives. if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then # This shell has a builtin print -r that does the trick. echo='print -r' elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && test "X$CONFIG_SHELL" != X/bin/ksh; then # If we have ksh, try running configure again with it. ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} export ORIGINAL_CONFIG_SHELL CONFIG_SHELL=/bin/ksh export CONFIG_SHELL exec $CONFIG_SHELL "[$]0" --no-reexec ${1+"[$]@"} else # Try using printf. echo='printf %s\n' if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then # Cool, printf works : elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && test "X$echo_testing_string" = 'X\t' && echo_testing_string=`($ORIGINAL_CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL export CONFIG_SHELL SHELL="$CONFIG_SHELL" export SHELL echo="$CONFIG_SHELL [$]0 --fallback-echo" elif echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo '\t') 2>/dev/null` && test "X$echo_testing_string" = 'X\t' && echo_testing_string=`($CONFIG_SHELL "[$]0" --fallback-echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then echo="$CONFIG_SHELL [$]0 --fallback-echo" else # maybe with a smaller string... prev=: for cmd in 'echo test' 'sed 2q "[$]0"' 'sed 10q "[$]0"' 'sed 20q "[$]0"' 'sed 50q "[$]0"'; do if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null then break fi prev="$cmd" done if test "$prev" != 'sed 50q "[$]0"'; then echo_test_string=`eval $prev` export echo_test_string exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "[$]0" ${1+"[$]@"} else # Oops. We lost completely, so just stick with echo. echo=echo fi fi fi fi fi fi # Copy echo and quote the copy suitably for passing to libtool from # the Makefile, instead of quoting the original, which is used later. ECHO=$echo if test "X$ECHO" = "X$CONFIG_SHELL [$]0 --fallback-echo"; then ECHO="$CONFIG_SHELL \\\$\[$]0 --fallback-echo" fi AC_SUBST(ECHO) ])])# _LT_AC_PROG_ECHO_BACKSLASH # _LT_AC_LOCK # ----------- AC_DEFUN([_LT_AC_LOCK], [AC_ARG_ENABLE([libtool-lock], [AC_HELP_STRING([--disable-libtool-lock], [avoid locking (might break parallel builds)])]) test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE="32" ;; *ELF-64*) HPUX_IA64_MODE="64" ;; esac fi rm -rf conftest* ;; *-*-irix6*) # Find out which ABI we are using. echo '[#]line __oline__ "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then if test "$lt_cv_prog_gnu_ld" = yes; then case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; *N32*) LD="${LD-ld} -melf32bmipn32" ;; *64-bit*) LD="${LD-ld} -melf64bmip" ;; esac else case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; *N32*) LD="${LD-ld} -n32" ;; *64-bit*) LD="${LD-ld} -64" ;; esac fi fi rm -rf conftest* ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ s390*-*linux*|sparc*-*linux*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_i386" ;; ppc64-*linux*|powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) LD="${LD-ld} -m elf_s390" ;; sparc64-*linux*) LD="${LD-ld} -m elf32_sparc" ;; esac ;; *64-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; ppc*-*linux*|powerpc*-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*) LD="${LD-ld} -m elf64_s390" ;; sparc*-*linux*) LD="${LD-ld} -m elf64_sparc" ;; esac ;; esac fi rm -rf conftest* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -belf" AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, [AC_LANG_PUSH(C) AC_TRY_LINK([],[],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) AC_LANG_POP]) if test x"$lt_cv_cc_needs_belf" != x"yes"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS="$SAVE_CFLAGS" fi ;; sparc*-*solaris*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) LD="${LD-ld} -m elf64_sparc" ;; *) if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then LD="${LD-ld} -64" fi ;; esac ;; esac fi rm -rf conftest* ;; AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL], [*-*-cygwin* | *-*-mingw* | *-*-pw32*) AC_CHECK_TOOL(DLLTOOL, dlltool, false) AC_CHECK_TOOL(AS, as, false) AC_CHECK_TOOL(OBJDUMP, objdump, false) ;; ]) esac need_locks="$enable_libtool_lock" ])# _LT_AC_LOCK # AC_LIBTOOL_COMPILER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, # [OUTPUT-FILE], [ACTION-SUCCESS], [ACTION-FAILURE]) # ---------------------------------------------------------------- # Check whether the given compiler option works AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION], [AC_REQUIRE([LT_AC_PROG_SED]) AC_CACHE_CHECK([$1], [$2], [$2=no ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$3" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&AS_MESSAGE_LOG_FD echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then $2=yes fi fi $rm conftest* ]) if test x"[$]$2" = xyes; then ifelse([$5], , :, [$5]) else ifelse([$6], , :, [$6]) fi ])# AC_LIBTOOL_COMPILER_OPTION # AC_LIBTOOL_LINKER_OPTION(MESSAGE, VARIABLE-NAME, FLAGS, # [ACTION-SUCCESS], [ACTION-FAILURE]) # ------------------------------------------------------------ # Check whether the given compiler option works AC_DEFUN([AC_LIBTOOL_LINKER_OPTION], [AC_REQUIRE([LT_AC_PROG_SED])dnl AC_CACHE_CHECK([$1], [$2], [$2=no save_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS $3" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&AS_MESSAGE_LOG_FD $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then $2=yes fi else $2=yes fi fi $rm -r conftest* LDFLAGS="$save_LDFLAGS" ]) if test x"[$]$2" = xyes; then ifelse([$4], , :, [$4]) else ifelse([$5], , :, [$5]) fi ])# AC_LIBTOOL_LINKER_OPTION # AC_LIBTOOL_SYS_MAX_CMD_LEN # -------------------------- AC_DEFUN([AC_LIBTOOL_SYS_MAX_CMD_LEN], [# find the maximum length of command line arguments AC_MSG_CHECKING([the maximum length of command line arguments]) AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl i=0 teststring="ABCD" case $build_os in msdosdjgpp*) # On DJGPP, this test can blow up pretty badly due to problems in libc # (any single argument exceeding 2000 bytes causes a buffer overrun # during glob expansion). Even if it were fixed, the result of this # check would be larger than it should be. lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; gnu*) # Under GNU Hurd, this test is not required because there is # no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; cygwin* | mingw*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, # you end up with a "frozen" computer, even though with patience # the test eventually succeeds (with a max line length of 256k). # Instead, let's just punt: use the minimum linelength reported by # all of the supported platforms: 8192 (on NT/2K/XP). lt_cv_sys_max_cmd_len=8192; ;; amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` elif test -x /usr/sbin/sysctl; then lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi # And add a safety zone lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; interix*) # We know the value 262144 and hardcode it with a safety zone (like BSD) lt_cv_sys_max_cmd_len=196608 ;; osf*) # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not # nice to cause kernel panics so lets avoid the loop below. # First set a reasonable default. lt_cv_sys_max_cmd_len=16384 # if test -x /sbin/sysconfig; then case `/sbin/sysconfig -q proc exec_disable_arg_limit` in *1*) lt_cv_sys_max_cmd_len=-1 ;; esac fi ;; sco3.2v5*) lt_cv_sys_max_cmd_len=102400 ;; sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ ]]//'` else lt_cv_sys_max_cmd_len=32768 fi ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` if test -n "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \ = "XX$teststring") >/dev/null 2>&1 && new_result=`expr "X$teststring" : ".*" 2>&1` && lt_cv_sys_max_cmd_len=$new_result && test $i != 17 # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring done teststring= # Add a significant safety factor because C++ compilers can tack on massive # amounts of additional arguments before passing them to the linker. # It appears as though 1/2 is a usable value. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` fi ;; esac ]) if test -n $lt_cv_sys_max_cmd_len ; then AC_MSG_RESULT($lt_cv_sys_max_cmd_len) else AC_MSG_RESULT(none) fi ])# AC_LIBTOOL_SYS_MAX_CMD_LEN # _LT_AC_CHECK_DLFCN # ------------------ AC_DEFUN([_LT_AC_CHECK_DLFCN], [AC_CHECK_HEADERS(dlfcn.h)dnl ])# _LT_AC_CHECK_DLFCN # _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE, # ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING) # --------------------------------------------------------------------- AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF], [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl if test "$cross_compiling" = yes; then : [$4] else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext < #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif #ifdef __cplusplus extern "C" void exit (int); #endif void fnord() { int i=42;} int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; /* dlclose (self); */ } else puts (dlerror ()); exit (status); }] EOF if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) $1 ;; x$lt_dlneed_uscore) $2 ;; x$lt_dlunknown|x*) $3 ;; esac else : # compilation failed $3 fi fi rm -fr conftest* ])# _LT_AC_TRY_DLOPEN_SELF # AC_LIBTOOL_DLOPEN_SELF # ---------------------- AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF], [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl if test "x$enable_dlopen" != xyes; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown else lt_cv_dlopen=no lt_cv_dlopen_libs= case $host_os in beos*) lt_cv_dlopen="load_add_on" lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32*) lt_cv_dlopen="LoadLibrary" lt_cv_dlopen_libs= ;; cygwin*) lt_cv_dlopen="dlopen" lt_cv_dlopen_libs= ;; darwin*) # if libdl is installed we need to link against it AC_CHECK_LIB([dl], [dlopen], [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ lt_cv_dlopen="dyld" lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ]) ;; *) AC_CHECK_FUNC([shl_load], [lt_cv_dlopen="shl_load"], [AC_CHECK_LIB([dld], [shl_load], [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], [AC_CHECK_FUNC([dlopen], [lt_cv_dlopen="dlopen"], [AC_CHECK_LIB([dl], [dlopen], [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], [AC_CHECK_LIB([svld], [dlopen], [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], [AC_CHECK_LIB([dld], [dld_link], [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) ]) ]) ]) ]) ]) ;; esac if test "x$lt_cv_dlopen" != xno; then enable_dlopen=yes else enable_dlopen=no fi case $lt_cv_dlopen in dlopen) save_CPPFLAGS="$CPPFLAGS" test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" save_LDFLAGS="$LDFLAGS" wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS="$LIBS" LIBS="$lt_cv_dlopen_libs $LIBS" AC_CACHE_CHECK([whether a program can dlopen itself], lt_cv_dlopen_self, [dnl _LT_AC_TRY_DLOPEN_SELF( lt_cv_dlopen_self=yes, lt_cv_dlopen_self=yes, lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) ]) if test "x$lt_cv_dlopen_self" = xyes; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" AC_CACHE_CHECK([whether a statically linked program can dlopen itself], lt_cv_dlopen_self_static, [dnl _LT_AC_TRY_DLOPEN_SELF( lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=yes, lt_cv_dlopen_self_static=no, lt_cv_dlopen_self_static=cross) ]) fi CPPFLAGS="$save_CPPFLAGS" LDFLAGS="$save_LDFLAGS" LIBS="$save_LIBS" ;; esac case $lt_cv_dlopen_self in yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; *) enable_dlopen_self=unknown ;; esac case $lt_cv_dlopen_self_static in yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; *) enable_dlopen_self_static=unknown ;; esac fi ])# AC_LIBTOOL_DLOPEN_SELF # AC_LIBTOOL_PROG_CC_C_O([TAGNAME]) # --------------------------------- # Check to see if options -c and -o are simultaneously supported by compiler AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O], [AC_REQUIRE([LT_AC_PROG_SED])dnl AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext], [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)], [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [[^ ]]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:__oline__: $lt_compile\"" >&AS_MESSAGE_LOG_FD) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&AS_MESSAGE_LOG_FD echo "$as_me:__oline__: \$? = $ac_status" >&AS_MESSAGE_LOG_FD if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes fi fi chmod u+w . 2>&AS_MESSAGE_LOG_FD $rm conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files $rm out/* && rmdir out cd .. rmdir conftest $rm conftest* ]) ])# AC_LIBTOOL_PROG_CC_C_O # AC_LIBTOOL_SYS_HARD_LINK_LOCKS([TAGNAME]) # ----------------------------------------- # Check to see if we can do hard links to lock some files if needed AC_DEFUN([AC_LIBTOOL_SYS_HARD_LINK_LOCKS], [AC_REQUIRE([_LT_AC_LOCK])dnl hard_links="nottested" if test "$_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then # do not overwrite the value of need_locks provided by the user AC_MSG_CHECKING([if we can lock with hard links]) hard_links=yes $rm conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no AC_MSG_RESULT([$hard_links]) if test "$hard_links" = no; then AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) need_locks=warn fi else need_locks=no fi ])# AC_LIBTOOL_SYS_HARD_LINK_LOCKS # AC_LIBTOOL_OBJDIR # ----------------- AC_DEFUN([AC_LIBTOOL_OBJDIR], [AC_CACHE_CHECK([for objdir], [lt_cv_objdir], [rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi rmdir .libs 2>/dev/null]) objdir=$lt_cv_objdir ])# AC_LIBTOOL_OBJDIR # AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH([TAGNAME]) # ---------------------------------------------- # Check hardcoding attributes. AC_DEFUN([AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH], [AC_MSG_CHECKING([how to hardcode library paths into programs]) _LT_AC_TAGVAR(hardcode_action, $1)= if test -n "$_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)" || \ test -n "$_LT_AC_TAGVAR(runpath_var, $1)" || \ test "X$_LT_AC_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then # We can hardcode non-existant directories. if test "$_LT_AC_TAGVAR(hardcode_direct, $1)" != no && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)" != no && test "$_LT_AC_TAGVAR(hardcode_minus_L, $1)" != no; then # Linking always hardcodes the temporary library directory. _LT_AC_TAGVAR(hardcode_action, $1)=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. _LT_AC_TAGVAR(hardcode_action, $1)=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. _LT_AC_TAGVAR(hardcode_action, $1)=unsupported fi AC_MSG_RESULT([$_LT_AC_TAGVAR(hardcode_action, $1)]) if test "$_LT_AC_TAGVAR(hardcode_action, $1)" = relink; then # Fast installation is not supported enable_fast_install=no elif test "$shlibpath_overrides_runpath" = yes || test "$enable_shared" = no; then # Fast installation is not necessary enable_fast_install=needless fi ])# AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH # AC_LIBTOOL_SYS_LIB_STRIP # ------------------------ AC_DEFUN([AC_LIBTOOL_SYS_LIB_STRIP], [striplib= old_striplib= AC_MSG_CHECKING([whether stripping libraries is possible]) if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" test -z "$striplib" && striplib="$STRIP --strip-unneeded" AC_MSG_RESULT([yes]) else # FIXME - insert some real tests, host_os isn't really good enough case $host_os in darwin*) if test -n "$STRIP" ; then striplib="$STRIP -x" old_striplib="$STRIP -S" AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) fi ;; *) AC_MSG_RESULT([no]) ;; esac fi ])# AC_LIBTOOL_SYS_LIB_STRIP # AC_LIBTOOL_SYS_DYNAMIC_LINKER # ----------------------------- # PORTME Fill in your ld.so characteristics AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER], [AC_REQUIRE([LT_AC_PROG_SED])dnl AC_MSG_CHECKING([dynamic linker characteristics]) library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=".so" postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" m4_if($1,[],[ if test "$GCC" = yes; then case $host_os in darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; *) lt_awk_arg="/^libraries:/" ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then # if the path contains ";" then we assume it to be the separator # otherwise default to the standard path separator (i.e. ":") - it is # assumed that no part of a normal pathname contains ";" but that should # okay in the real world where ";" in dirpaths is itself problematic. lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'` else lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # Ok, now we have the path, separated by spaces, we can step through it # and add multilib dir if necessary. lt_tmp_lt_search_path_spec= lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` for lt_sys_path in $lt_search_path_spec; do if test -d "$lt_sys_path/$lt_multi_os_dir"; then lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" else test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk ' BEGIN {RS=" "; FS="/|\n";} { lt_foo=""; lt_count=0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { lt_foo="/" $lt_i lt_foo; } else { lt_count--; } } } } if (lt_foo != "") { lt_freq[[lt_foo]]++; } if (lt_freq[[lt_foo]] == 1) { print lt_foo; } }'` sys_lib_search_path_spec=`echo $lt_search_path_spec` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi]) need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='${libname}${release}${shared_ext}$major' ;; aix[[4-9]]*) version_type=linux need_lib_prefix=no need_version=no hardcode_into_libs=yes if test "$host_cpu" = ia64; then # AIX 5 supports IA64 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line `#! .'. This would cause the generated library to # depend on `.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[[01]] | aix4.[[01]].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then : else can_build_shared=no fi ;; esac # AIX (on Power*) has no versioning support, so currently we can not hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. if test "$aix_use_runtimelinking" = yes; then # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' else # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='${libname}${release}.a $libname.a' soname_spec='${libname}${release}${shared_ext}$major' fi shlibpath_var=LIBPATH fi ;; amigaos*) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; beos*) library_names_spec='${libname}${shared_ext}' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[[45]]*) version_type=linux need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32*) version_type=windows shrext_cmds=".dll" need_version=no need_lib_prefix=no case $GCC,$host_os in yes,cygwin* | yes,mingw* | yes,pw32*) library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \${file}`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" ;; mingw*) # MinGW DLLs use traditional 'lib' prefix soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$sys_lib_search_path_spec" | [grep ';[c-zC-Z]:/' >/dev/null]; then # It is most probably a Windows format PATH printed by # mingw gcc, but we are running on Cygwin. Gcc prints its search # path with ; separators, and with drive letters. We can handle the # drive letters (cygwin fileutils understands them), so leave them, # especially as we might pass files found there to a mingw objdump, # which wouldn't understand a cygwinified path. Ahh. sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' ;; esac ;; *) library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' ;; esac dynamic_linker='Win32 ld.exe' # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' soname_spec='${libname}${release}${major}$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd1*) dynamic_linker=no ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[[123]]*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2*) shlibpath_overrides_runpath=yes ;; freebsd3.[[01]]* | freebsdelf3.[[01]]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \ freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; gnu*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' if test "X$HPUX_IA64_MODE" = X32; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" fi sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555. postinstall_cmds='chmod 555 $lib' ;; interix[[3-9]]*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test "$lt_cv_prog_gnu_ld" = yes; then version_type=linux else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. linux* | k*bsd*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Append ld.so.conf contents to the search path if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsdelf*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; nto-qnx*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; openbsd*) version_type=sunos sys_lib_dlsearch_path_spec="/usr/lib" need_lib_prefix=no # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. case $host_os in openbsd3.3 | openbsd3.3.*) need_version=yes ;; *) need_version=no ;; esac library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then case $host_os in openbsd2.[[89]] | openbsd2.[[89]].*) shlibpath_overrides_runpath=no ;; *) shlibpath_overrides_runpath=yes ;; esac else shlibpath_overrides_runpath=yes fi ;; os2*) libname_spec='$name' shrext_cmds=".dll" need_lib_prefix=no library_names_spec='$libname${shared_ext} $libname.a' dynamic_linker='OS/2 ld.exe' shlibpath_var=LIBPATH ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test "$with_gnu_ld" = yes; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no export_dynamic_flag_spec='${wl}-Blargedynsym' runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec ;then version_type=linux library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' soname_spec='$libname${shared_ext}.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=freebsd-elf need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes if test "$with_gnu_ld" = yes; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' shlibpath_overrides_runpath=no else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' shlibpath_overrides_runpath=yes case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; uts4*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac AC_MSG_RESULT([$dynamic_linker]) test "$dynamic_linker" = no && can_build_shared=no AC_CACHE_VAL([lt_cv_sys_lib_search_path_spec], [lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"]) sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" AC_CACHE_VAL([lt_cv_sys_lib_dlsearch_path_spec], [lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"]) sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test "$GCC" = yes; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi ])# AC_LIBTOOL_SYS_DYNAMIC_LINKER # _LT_AC_TAGCONFIG # ---------------- AC_DEFUN([_LT_AC_TAGCONFIG], [AC_REQUIRE([LT_AC_PROG_SED])dnl AC_ARG_WITH([tags], [AC_HELP_STRING([--with-tags@<:@=TAGS@:>@], [include additional configurations @<:@automatic@:>@])], [tagnames="$withval"]) if test -f "$ltmain" && test -n "$tagnames"; then if test ! -f "${ofile}"; then AC_MSG_WARN([output file `$ofile' does not exist]) fi if test -z "$LTCC"; then eval "`$SHELL ${ofile} --config | grep '^LTCC='`" if test -z "$LTCC"; then AC_MSG_WARN([output file `$ofile' does not look like a libtool script]) else AC_MSG_WARN([using `LTCC=$LTCC', extracted from `$ofile']) fi fi if test -z "$LTCFLAGS"; then eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`" fi # Extract list of available tagged configurations in $ofile. # Note that this assumes the entire list is on one line. available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for tagname in $tagnames; do IFS="$lt_save_ifs" # Check whether tagname contains only valid characters case `$echo "X$tagname" | $Xsed -e 's:[[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]]::g'` in "") ;; *) AC_MSG_ERROR([invalid tag name: $tagname]) ;; esac if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null then AC_MSG_ERROR([tag name \"$tagname\" already exists]) fi # Update the list of available tags. if test -n "$tagname"; then echo appending configuration tag \"$tagname\" to $ofile case $tagname in CXX) if test -n "$CXX" && ( test "X$CXX" != "Xno" && ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || (test "X$CXX" != "Xg++"))) ; then AC_LIBTOOL_LANG_CXX_CONFIG else tagname="" fi ;; F77) if test -n "$F77" && test "X$F77" != "Xno"; then AC_LIBTOOL_LANG_F77_CONFIG else tagname="" fi ;; GCJ) if test -n "$GCJ" && test "X$GCJ" != "Xno"; then AC_LIBTOOL_LANG_GCJ_CONFIG else tagname="" fi ;; RC) AC_LIBTOOL_LANG_RC_CONFIG ;; *) AC_MSG_ERROR([Unsupported tag name: $tagname]) ;; esac # Append the new tag name to the list of available tags. if test -n "$tagname" ; then available_tags="$available_tags $tagname" fi fi done IFS="$lt_save_ifs" # Now substitute the updated list of available tags. if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then mv "${ofile}T" "$ofile" chmod +x "$ofile" else rm -f "${ofile}T" AC_MSG_ERROR([unable to update list of available tagged configurations.]) fi fi ])# _LT_AC_TAGCONFIG # AC_LIBTOOL_DLOPEN # ----------------- # enable checks for dlopen support AC_DEFUN([AC_LIBTOOL_DLOPEN], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP]) ])# AC_LIBTOOL_DLOPEN # AC_LIBTOOL_WIN32_DLL # -------------------- # declare package support for building win32 DLLs AC_DEFUN([AC_LIBTOOL_WIN32_DLL], [AC_BEFORE([$0], [AC_LIBTOOL_SETUP]) ])# AC_LIBTOOL_WIN32_DLL # AC_ENABLE_SHARED([DEFAULT]) # --------------------------- # implement the --enable-shared flag # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. AC_DEFUN([AC_ENABLE_SHARED], [define([AC_ENABLE_SHARED_DEFAULT], ifelse($1, no, no, yes))dnl AC_ARG_ENABLE([shared], [AC_HELP_STRING([--enable-shared@<:@=PKGS@:>@], [build shared libraries @<:@default=]AC_ENABLE_SHARED_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; no) enable_shared=no ;; *) enable_shared=no # Look at the argument we got. We use all the common list separators. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then enable_shared=yes fi done IFS="$lt_save_ifs" ;; esac], [enable_shared=]AC_ENABLE_SHARED_DEFAULT) ])# AC_ENABLE_SHARED # AC_DISABLE_SHARED # ----------------- # set the default shared flag to --disable-shared AC_DEFUN([AC_DISABLE_SHARED], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl AC_ENABLE_SHARED(no) ])# AC_DISABLE_SHARED # AC_ENABLE_STATIC([DEFAULT]) # --------------------------- # implement the --enable-static flag # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. AC_DEFUN([AC_ENABLE_STATIC], [define([AC_ENABLE_STATIC_DEFAULT], ifelse($1, no, no, yes))dnl AC_ARG_ENABLE([static], [AC_HELP_STRING([--enable-static@<:@=PKGS@:>@], [build static libraries @<:@default=]AC_ENABLE_STATIC_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; no) enable_static=no ;; *) enable_static=no # Look at the argument we got. We use all the common list separators. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then enable_static=yes fi done IFS="$lt_save_ifs" ;; esac], [enable_static=]AC_ENABLE_STATIC_DEFAULT) ])# AC_ENABLE_STATIC # AC_DISABLE_STATIC # ----------------- # set the default static flag to --disable-static AC_DEFUN([AC_DISABLE_STATIC], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl AC_ENABLE_STATIC(no) ])# AC_DISABLE_STATIC # AC_ENABLE_FAST_INSTALL([DEFAULT]) # --------------------------------- # implement the --enable-fast-install flag # DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. AC_DEFUN([AC_ENABLE_FAST_INSTALL], [define([AC_ENABLE_FAST_INSTALL_DEFAULT], ifelse($1, no, no, yes))dnl AC_ARG_ENABLE([fast-install], [AC_HELP_STRING([--enable-fast-install@<:@=PKGS@:>@], [optimize for fast installation @<:@default=]AC_ENABLE_FAST_INSTALL_DEFAULT[@:>@])], [p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; no) enable_fast_install=no ;; *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done IFS="$lt_save_ifs" ;; esac], [enable_fast_install=]AC_ENABLE_FAST_INSTALL_DEFAULT) ])# AC_ENABLE_FAST_INSTALL # AC_DISABLE_FAST_INSTALL # ----------------------- # set the default to --disable-fast-install AC_DEFUN([AC_DISABLE_FAST_INSTALL], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl AC_ENABLE_FAST_INSTALL(no) ])# AC_DISABLE_FAST_INSTALL # AC_LIBTOOL_PICMODE([MODE]) # -------------------------- # implement the --with-pic flag # MODE is either `yes' or `no'. If omitted, it defaults to `both'. AC_DEFUN([AC_LIBTOOL_PICMODE], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl pic_mode=ifelse($#,1,$1,default) ])# AC_LIBTOOL_PICMODE # AC_PROG_EGREP # ------------- # This is predefined starting with Autoconf 2.54, so this conditional # definition can be removed once we require Autoconf 2.54 or later. m4_ifndef([AC_PROG_EGREP], [AC_DEFUN([AC_PROG_EGREP], [AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep], [if echo a | (grep -E '(a|b)') >/dev/null 2>&1 then ac_cv_prog_egrep='grep -E' else ac_cv_prog_egrep='egrep' fi]) EGREP=$ac_cv_prog_egrep AC_SUBST([EGREP]) ])]) # AC_PATH_TOOL_PREFIX # ------------------- # find a file program which can recognize shared library AC_DEFUN([AC_PATH_TOOL_PREFIX], [AC_REQUIRE([AC_PROG_EGREP])dnl AC_MSG_CHECKING([for $1]) AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, [case $MAGIC_CMD in [[\\/*] | ?:[\\/]*]) lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD="$MAGIC_CMD" lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR dnl $ac_dummy forces splitting on constant user-supplied paths. dnl POSIX.2 word splitting is done only on the output of word expansions, dnl not every word. This closes a longstanding sh security hole. ac_dummy="ifelse([$2], , $PATH, [$2])" for ac_dir in $ac_dummy; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/$1; then lt_cv_path_MAGIC_CMD="$ac_dir/$1" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD="$lt_cv_path_MAGIC_CMD" if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org EOF fi ;; esac fi break fi done IFS="$lt_save_ifs" MAGIC_CMD="$lt_save_MAGIC_CMD" ;; esac]) MAGIC_CMD="$lt_cv_path_MAGIC_CMD" if test -n "$MAGIC_CMD"; then AC_MSG_RESULT($MAGIC_CMD) else AC_MSG_RESULT(no) fi ])# AC_PATH_TOOL_PREFIX # AC_PATH_MAGIC # ------------- # find a file program which can recognize a shared library AC_DEFUN([AC_PATH_MAGIC], [AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then AC_PATH_TOOL_PREFIX(file, /usr/bin$PATH_SEPARATOR$PATH) else MAGIC_CMD=: fi fi ])# AC_PATH_MAGIC # AC_PROG_LD # ---------- # find the pathname to the GNU or non-GNU linker AC_DEFUN([AC_PROG_LD], [AC_ARG_WITH([gnu-ld], [AC_HELP_STRING([--with-gnu-ld], [assume the C compiler uses GNU ld @<:@default=no@:>@])], [test "$withval" = no || with_gnu_ld=yes], [with_gnu_ld=no]) AC_REQUIRE([LT_AC_PROG_SED])dnl AC_REQUIRE([AC_PROG_CC])dnl AC_REQUIRE([AC_CANONICAL_HOST])dnl AC_REQUIRE([AC_CANONICAL_BUILD])dnl ac_prog=ld if test "$GCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. AC_MSG_CHECKING([for ld used by $CC]) case $host in *-*-mingw*) # gcc leaves a trailing carriage return which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [[\\/]]* | ?:[[\\/]]*) re_direlt='/[[^/]][[^/]]*/\.\./' # Canonicalize the pathname of ld ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD="$ac_prog" ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test "$with_gnu_ld" = yes; then AC_MSG_CHECKING([for GNU ld]) else AC_MSG_CHECKING([for non-GNU ld]) fi AC_CACHE_VAL(lt_cv_path_LD, [if test -z "$LD"; then lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD="$ac_dir/$ac_prog" # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &1 /dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | dragonfly*) if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[[3-9]]86 (compact )?demand paged shared library' lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac else lt_cv_deplibs_check_method=pass_all fi ;; gnu*) lt_cv_deplibs_check_method=pass_all ;; hpux10.20* | hpux11*) lt_cv_file_magic_cmd=/usr/bin/file case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|ELF-[[0-9]][[0-9]]) shared object file - IA64' lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so ;; hppa*64*) [lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]'] lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) lt_cv_deplibs_check_method='file_magic (s[[0-9]][[0-9]][[0-9]]|PA-RISC[[0-9]].[[0-9]]) shared library' lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac ;; interix[[3-9]]*) # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) case $LD in *-32|*"-32 ") libmagic=32-bit;; *-n32|*"-n32 ") libmagic=N32;; *-64|*"-64 ") libmagic=64-bit;; *) libmagic=never-match;; esac lt_cv_deplibs_check_method=pass_all ;; # This must be Linux ELF. linux* | k*bsd*-gnu) lt_cv_deplibs_check_method=pass_all ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|_pic\.a)$' fi ;; newos6*) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (executable|dynamic lib)' lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; nto-qnx*) lt_cv_deplibs_check_method=unknown ;; openbsd*) if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; rdos*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]' lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; ncr) lt_cv_deplibs_check_method=pass_all ;; sequent) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB (shared object|dynamic lib )' ;; sni) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method="file_magic ELF [[0-9]][[0-9]]*-bit [[LM]]SB dynamic lib" lt_cv_file_magic_test_file=/lib/libc.so ;; siemens) lt_cv_deplibs_check_method=pass_all ;; pc) lt_cv_deplibs_check_method=pass_all ;; esac ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; esac ]) file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown ])# AC_DEPLIBS_CHECK_METHOD # AC_PROG_NM # ---------- # find the pathname to a BSD-compatible name lister AC_DEFUN([AC_PROG_NM], [AC_CACHE_CHECK([for BSD-compatible nm], lt_cv_path_NM, [if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM="$NM" else lt_nm_to_check="${ac_tool_prefix}nm" if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. tmp_nm="$ac_dir/$lt_tmp_nm" if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then # Check to see if the nm accepts a BSD-compat flag. # Adding the `sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in */dev/null* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but continue # so that we can try to find one that supports BSD flags ;; esac ;; esac fi done IFS="$lt_save_ifs" done test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm fi]) NM="$lt_cv_path_NM" ])# AC_PROG_NM # AC_CHECK_LIBM # ------------- # check for math library AC_DEFUN([AC_CHECK_LIBM], [AC_REQUIRE([AC_CANONICAL_HOST])dnl LIBM= case $host in *-*-beos* | *-*-cygwin* | *-*-pw32* | *-*-darwin*) # These system don't have libm, or don't need it ;; *-ncr-sysv4.3*) AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") ;; *) AC_CHECK_LIB(m, cos, LIBM="-lm") ;; esac ])# AC_CHECK_LIBM # AC_LIBLTDL_CONVENIENCE([DIRECTORY]) # ----------------------------------- # sets LIBLTDL to the link flags for the libltdl convenience library and # LTDLINCL to the include flags for the libltdl header and adds # --enable-ltdl-convenience to the configure arguments. Note that # AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, # it is assumed to be `libltdl'. LIBLTDL will be prefixed with # '${top_builddir}/' and LTDLINCL will be prefixed with '${top_srcdir}/' # (note the single quotes!). If your package is not flat and you're not # using automake, define top_builddir and top_srcdir appropriately in # the Makefiles. AC_DEFUN([AC_LIBLTDL_CONVENIENCE], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl case $enable_ltdl_convenience in no) AC_MSG_ERROR([this package needs a convenience libltdl]) ;; "") enable_ltdl_convenience=yes ac_configure_args="$ac_configure_args --enable-ltdl-convenience" ;; esac LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdlc.la LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) # For backwards non-gettext consistent compatibility... INCLTDL="$LTDLINCL" ])# AC_LIBLTDL_CONVENIENCE # AC_LIBLTDL_INSTALLABLE([DIRECTORY]) # ----------------------------------- # sets LIBLTDL to the link flags for the libltdl installable library and # LTDLINCL to the include flags for the libltdl header and adds # --enable-ltdl-install to the configure arguments. Note that # AC_CONFIG_SUBDIRS is not called here. If DIRECTORY is not provided, # and an installed libltdl is not found, it is assumed to be `libltdl'. # LIBLTDL will be prefixed with '${top_builddir}/'# and LTDLINCL with # '${top_srcdir}/' (note the single quotes!). If your package is not # flat and you're not using automake, define top_builddir and top_srcdir # appropriately in the Makefiles. # In the future, this macro may have to be called after AC_PROG_LIBTOOL. AC_DEFUN([AC_LIBLTDL_INSTALLABLE], [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl AC_CHECK_LIB(ltdl, lt_dlinit, [test x"$enable_ltdl_install" != xyes && enable_ltdl_install=no], [if test x"$enable_ltdl_install" = xno; then AC_MSG_WARN([libltdl not installed, but installation disabled]) else enable_ltdl_install=yes fi ]) if test x"$enable_ltdl_install" = x"yes"; then ac_configure_args="$ac_configure_args --enable-ltdl-install" LIBLTDL='${top_builddir}/'ifelse($#,1,[$1],['libltdl'])/libltdl.la LTDLINCL='-I${top_srcdir}/'ifelse($#,1,[$1],['libltdl']) else ac_configure_args="$ac_configure_args --enable-ltdl-install=no" LIBLTDL="-lltdl" LTDLINCL= fi # For backwards non-gettext consistent compatibility... INCLTDL="$LTDLINCL" ])# AC_LIBLTDL_INSTALLABLE # AC_LIBTOOL_CXX # -------------- # enable support for C++ libraries AC_DEFUN([AC_LIBTOOL_CXX], [AC_REQUIRE([_LT_AC_LANG_CXX]) ])# AC_LIBTOOL_CXX # _LT_AC_LANG_CXX # --------------- AC_DEFUN([_LT_AC_LANG_CXX], [AC_REQUIRE([AC_PROG_CXX]) AC_REQUIRE([_LT_AC_PROG_CXXCPP]) _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX]) ])# _LT_AC_LANG_CXX # _LT_AC_PROG_CXXCPP # ------------------ AC_DEFUN([_LT_AC_PROG_CXXCPP], [ AC_REQUIRE([AC_PROG_CXX]) if test -n "$CXX" && ( test "X$CXX" != "Xno" && ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || (test "X$CXX" != "Xg++"))) ; then AC_PROG_CXXCPP fi ])# _LT_AC_PROG_CXXCPP # AC_LIBTOOL_F77 # -------------- # enable support for Fortran 77 libraries AC_DEFUN([AC_LIBTOOL_F77], [AC_REQUIRE([_LT_AC_LANG_F77]) ])# AC_LIBTOOL_F77 # _LT_AC_LANG_F77 # --------------- AC_DEFUN([_LT_AC_LANG_F77], [AC_REQUIRE([AC_PROG_F77]) _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77]) ])# _LT_AC_LANG_F77 # AC_LIBTOOL_GCJ # -------------- # enable support for GCJ libraries AC_DEFUN([AC_LIBTOOL_GCJ], [AC_REQUIRE([_LT_AC_LANG_GCJ]) ])# AC_LIBTOOL_GCJ # _LT_AC_LANG_GCJ # --------------- AC_DEFUN([_LT_AC_LANG_GCJ], [AC_PROVIDE_IFELSE([AC_PROG_GCJ],[], [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[], [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[], [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])], [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])], [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])]) _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ]) ])# _LT_AC_LANG_GCJ # AC_LIBTOOL_RC # ------------- # enable support for Windows resource files AC_DEFUN([AC_LIBTOOL_RC], [AC_REQUIRE([LT_AC_PROG_RC]) _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC]) ])# AC_LIBTOOL_RC # AC_LIBTOOL_LANG_C_CONFIG # ------------------------ # Ensure that the configuration vars for the C compiler are # suitably defined. Those variables are subsequently used by # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. AC_DEFUN([AC_LIBTOOL_LANG_C_CONFIG], [_LT_AC_LANG_C_CONFIG]) AC_DEFUN([_LT_AC_LANG_C_CONFIG], [lt_save_CC="$CC" AC_LANG_PUSH(C) # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o _LT_AC_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' _LT_AC_SYS_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) AC_LIBTOOL_PROG_COMPILER_PIC($1) AC_LIBTOOL_PROG_CC_C_O($1) AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) AC_LIBTOOL_PROG_LD_SHLIBS($1) AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) AC_LIBTOOL_SYS_LIB_STRIP AC_LIBTOOL_DLOPEN_SELF # Report which library types will actually be built AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test "$can_build_shared" = "no" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test "$enable_shared" = yes && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then test "$enable_shared" = yes && enable_static=no fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test "$enable_shared" = yes || enable_static=yes AC_MSG_RESULT([$enable_static]) AC_LIBTOOL_CONFIG($1) AC_LANG_POP CC="$lt_save_CC" ])# AC_LIBTOOL_LANG_C_CONFIG # AC_LIBTOOL_LANG_CXX_CONFIG # -------------------------- # Ensure that the configuration vars for the C compiler are # suitably defined. Those variables are subsequently used by # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. AC_DEFUN([AC_LIBTOOL_LANG_CXX_CONFIG], [_LT_AC_LANG_CXX_CONFIG(CXX)]) AC_DEFUN([_LT_AC_LANG_CXX_CONFIG], [AC_LANG_PUSH(C++) AC_REQUIRE([AC_PROG_CXX]) AC_REQUIRE([_LT_AC_PROG_CXXCPP]) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no _LT_AC_TAGVAR(allow_undefined_flag, $1)= _LT_AC_TAGVAR(always_export_symbols, $1)=no _LT_AC_TAGVAR(archive_expsym_cmds, $1)= _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= _LT_AC_TAGVAR(hardcode_minus_L, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_AC_TAGVAR(hardcode_automatic, $1)=no _LT_AC_TAGVAR(module_cmds, $1)= _LT_AC_TAGVAR(module_expsym_cmds, $1)= _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_AC_TAGVAR(no_undefined_flag, $1)= _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Dependencies to place before and after the object being linked: _LT_AC_TAGVAR(predep_objects, $1)= _LT_AC_TAGVAR(postdep_objects, $1)= _LT_AC_TAGVAR(predeps, $1)= _LT_AC_TAGVAR(postdeps, $1)= _LT_AC_TAGVAR(compiler_lib_search_path, $1)= _LT_AC_TAGVAR(compiler_lib_search_dirs, $1)= # Source file extension for C++ test sources. ac_ext=cpp # Object file extension for compiled C++ test sources. objext=o _LT_AC_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_AC_SYS_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_LD=$LD lt_save_GCC=$GCC GCC=$GXX lt_save_with_gnu_ld=$with_gnu_ld lt_save_path_LD=$lt_cv_path_LD if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx else $as_unset lt_cv_prog_gnu_ld fi if test -n "${lt_cv_path_LDCXX+set}"; then lt_cv_path_LD=$lt_cv_path_LDCXX else $as_unset lt_cv_path_LD fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} compiler=$CC _LT_AC_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) # We don't want -fno-exception wen compiling C++ code, so set the # no_builtin_flag separately if test "$GXX" = yes; then _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' else _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= fi if test "$GXX" = yes; then # Set up default GNU C++ configuration AC_PROG_LD # Check if GNU C++ uses GNU ld as the underlying linker, since the # archiving commands below assume that GNU ld is being used. if test "$with_gnu_ld" = yes; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' # If archive_cmds runs LD, not CC, wlarc should be empty # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to # investigate it a little bit more. (MM) wlarc='${wl}' # ancient GNU ld didn't support --whole-archive et. al. if eval "`$CC -print-prog-name=ld` --help 2>&1" | \ grep 'no-whole-archive' > /dev/null; then _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= fi else with_gnu_ld=no wlarc= # A generic and very simple default shared library creation # command for GNU C++ for the case where it uses the native # linker, instead of GNU ld. If possible, this setting should # overridden to take advantage of the native linker features on # the platform it is being used on. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' fi # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' else GXX=no with_gnu_ld=no wlarc= fi # PORTME: fill in a description of your system's C++ link characteristics AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) _LT_AC_TAGVAR(ld_shlibs, $1)=yes case $host_os in aix3*) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; aix[[4-9]]*) if test "$host_cpu" = ia64; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag="" else aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # need to do runtime linking. case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do case $ld_flag in *-brtl*) aix_use_runtimelinking=yes break ;; esac done ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. _LT_AC_TAGVAR(archive_cmds, $1)='' _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_AC_TAGVAR(link_all_deplibs, $1)=yes if test "$GXX" = yes; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`${CC} -print-prog-name=collect2` if test -f "$collect2name" && \ strings "$collect2name" | grep resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= fi ;; esac shared_flag='-shared' if test "$aix_use_runtimelinking" = yes; then shared_flag="$shared_flag "'${wl}-G' fi else # not using gcc if test "$host_cpu" = ia64; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test "$aix_use_runtimelinking" = yes; then shared_flag='${wl}-G' else shared_flag='${wl}-bM:SRE' fi fi fi # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. _LT_AC_TAGVAR(always_export_symbols, $1)=yes if test "$aix_use_runtimelinking" = yes; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' # Determine the default libpath from the value encoded in an empty executable. _LT_AC_SYS_LIBPATH_AIX _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" else if test "$host_cpu" = ia64; then _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an empty executable. _LT_AC_SYS_LIBPATH_AIX _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' # Exported symbols can be pulled into shared objects from archives _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience' _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes # This is similar to how AIX traditionally builds its shared libraries. _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; beos*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; chorus*) case $cc_basename in *) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; esac ;; cygwin* | mingw* | pw32*) # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_AC_TAGVAR(always_export_symbols, $1)=no _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file (1st line # is EXPORTS), use it as is; otherwise, prepend... _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; darwin* | rhapsody*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_automatic, $1)=yes _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' _LT_AC_TAGVAR(link_all_deplibs, $1)=yes _LT_AC_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" if test "$GXX" = yes ; then output_verbose_link_cmd='echo' _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" _LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" if test "$lt_cv_apple_cc_single_mod" != "yes"; then _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" fi else case $cc_basename in xlc*) output_verbose_link_cmd='echo' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' ;; *) _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; esac fi ;; dgux*) case $cc_basename in ec++*) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; ghcx*) # Green Hills C++ Compiler # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; esac ;; freebsd[[12]]*) # C++ shared libraries reported to be fairly broken before switch to ELF _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; freebsd-elf*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;; freebsd* | dragonfly*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions _LT_AC_TAGVAR(ld_shlibs, $1)=yes ;; gnu*) ;; hpux9*) _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default # location of the library. case $cc_basename in CC*) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; aCC*) _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[[-]]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes; then _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' else # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; hpux10*|hpux11*) if test $with_gnu_ld = no; then _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) ;; *) _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' ;; esac fi case $host_cpu in hppa*64*|ia64*) _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default # location of the library. ;; esac case $cc_basename in CC*) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; aCC*) case $host_cpu in hppa*64*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes; then if test $with_gnu_ld = no; then case $host_cpu in hppa*64*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi else # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; interix[[3-9]]*) _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in CC*) # SGI C++ _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' ;; *) if test "$GXX" = yes; then if test "$with_gnu_ld" = no; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib' fi fi _LT_AC_TAGVAR(link_all_deplibs, $1)=yes ;; esac _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: ;; linux* | k*bsd*-gnu) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath,$libdir' _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; icpc*) # Intel C++ with_gnu_ld=yes # version 8.0 and above of icpc choke on multiply defined symbols # if we add $predep_objects and $postdep_objects, however 7.1 and # earlier do not add the objects themselves. case `$CC -V 2>&1` in *"Version 7."*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 8.0 or newer tmp_idyn= case $host_cpu in ia64*) tmp_idyn=' -i_dynamic';; esac _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' ;; esac _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' ;; pgCC* | pgcpp*) # Portland Group C++ compiler _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' ;; cxx*) # Compaq C++ _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' runpath_var=LD_RUN_PATH _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' # Not sure whether something based on # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 # would be better. output_verbose_link_cmd='echo' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' ;; esac ;; esac ;; lynxos*) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; m88k*) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; mvs*) case $cc_basename in cxx*) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; esac ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' wlarc= _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no fi # Workaround some broken pre-1.5 toolchains output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' ;; openbsd2*) # C++ shared libraries are fairly broken _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; openbsd*) if test -f /usr/libexec/ld.so; then _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' fi output_verbose_link_cmd='echo' else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; osf3*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -Bstatic -o $oldlib $oldobjs' ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; cxx*) _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes && test "$with_gnu_ld" = no; then _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' else # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; osf4* | osf5*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. _LT_AC_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: # Archives containing C++ object files must be created using # the KAI C++ compiler. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -o $oldlib $oldobjs' ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; cxx*) _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ echo "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~ $rm $lib.exp' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes && test "$with_gnu_ld" = no; then _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' else # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; psos*) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; lcc*) # Lucid # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; esac ;; solaris*) case $cc_basename in CC*) # Sun C++ 4.2, 5.x and Centerline C++ _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands `-z linker_flag'. # Supported since Solaris 2.6 (maybe 2.5.1?) _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; esac _LT_AC_TAGVAR(link_all_deplibs, $1)=yes output_verbose_link_cmd='echo' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs' ;; gcx*) # Green Hills C++ Compiler _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' # The C++ compiler must be used to create the archive. _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' ;; *) # GNU C++ compiler with Solaris linker if test "$GXX" = yes && test "$with_gnu_ld" = no; then _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' if $CC --version | grep -v '^2\.7' > /dev/null; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" else # g++ 2.7 appears to require `-G' NOT `-shared' on this # platform. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" fi _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' ;; esac fi ;; esac ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' case $cc_basename in CC*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We can NOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. # For security reasons, it is highly recommended that you always # use absolute paths for naming shared libraries, and exclude the # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. # So that behaviour is only enabled if SCOABSPATH is set to a # non-empty value in the environment. Most likely only useful for # creating official distributions of packages. # This is a hack until libtool officially supports absolute path # names for shared libraries. _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_AC_TAGVAR(link_all_deplibs, $1)=yes _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' runpath_var='LD_RUN_PATH' case $cc_basename in CC*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; esac ;; vxworks*) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; *) # FIXME: insert proper C++ library support _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; esac AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no _LT_AC_TAGVAR(GCC, $1)="$GXX" _LT_AC_TAGVAR(LD, $1)="$LD" AC_LIBTOOL_POSTDEP_PREDEP($1) AC_LIBTOOL_PROG_COMPILER_PIC($1) AC_LIBTOOL_PROG_CC_C_O($1) AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) AC_LIBTOOL_PROG_LD_SHLIBS($1) AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) AC_LIBTOOL_CONFIG($1) AC_LANG_POP CC=$lt_save_CC LDCXX=$LD LD=$lt_save_LD GCC=$lt_save_GCC with_gnu_ldcxx=$with_gnu_ld with_gnu_ld=$lt_save_with_gnu_ld lt_cv_path_LDCXX=$lt_cv_path_LD lt_cv_path_LD=$lt_save_path_LD lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld ])# AC_LIBTOOL_LANG_CXX_CONFIG # AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME]) # ------------------------------------ # Figure out "hidden" library dependencies from verbose # compiler output when linking a shared library. # Parse the compiler output and extract the necessary # objects, libraries and library flags. AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP], [AC_REQUIRE([LT_AC_PROG_SED])dnl dnl we can't use the lt_simple_compile_test_code here, dnl because it contains code intended for an executable, dnl not a library. It's possible we should let each dnl tag define a new lt_????_link_test_code variable, dnl but it's only used here... ifelse([$1],[],[cat > conftest.$ac_ext < conftest.$ac_ext < conftest.$ac_ext < conftest.$ac_ext <&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 # # The more standards-conforming stlport4 library is # incompatible with the Cstd library. Avoid specifying # it if it's in CXXFLAGS. Ignore libCrun as # -library=stlport4 depends on it. case " $CXX $CXXFLAGS " in *" -library=stlport4 "*) solaris_use_stlport4=yes ;; esac if test "$solaris_use_stlport4" != yes; then _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' fi ;; esac ;; solaris*) case $cc_basename in CC*) # The more standards-conforming stlport4 library is # incompatible with the Cstd library. Avoid specifying # it if it's in CXXFLAGS. Ignore libCrun as # -library=stlport4 depends on it. case " $CXX $CXXFLAGS " in *" -library=stlport4 "*) solaris_use_stlport4=yes ;; esac # Adding this requires a known-good setup of shared libraries for # Sun compiler versions before 5.6, else PIC objects from an old # archive will be linked into the output, leading to subtle bugs. if test "$solaris_use_stlport4" != yes; then _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' fi ;; esac ;; esac ]) case " $_LT_AC_TAGVAR(postdeps, $1) " in *" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;; esac ])# AC_LIBTOOL_POSTDEP_PREDEP # AC_LIBTOOL_LANG_F77_CONFIG # -------------------------- # Ensure that the configuration vars for the C compiler are # suitably defined. Those variables are subsequently used by # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)]) AC_DEFUN([_LT_AC_LANG_F77_CONFIG], [AC_REQUIRE([AC_PROG_F77]) AC_LANG_PUSH(Fortran 77) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no _LT_AC_TAGVAR(allow_undefined_flag, $1)= _LT_AC_TAGVAR(always_export_symbols, $1)=no _LT_AC_TAGVAR(archive_expsym_cmds, $1)= _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= _LT_AC_TAGVAR(hardcode_minus_L, $1)=no _LT_AC_TAGVAR(hardcode_automatic, $1)=no _LT_AC_TAGVAR(module_cmds, $1)= _LT_AC_TAGVAR(module_expsym_cmds, $1)= _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds _LT_AC_TAGVAR(no_undefined_flag, $1)= _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no # Source file extension for f77 test sources. ac_ext=f # Object file extension for compiled f77 test sources. objext=o _LT_AC_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t return end " # Code to be used in simple link tests lt_simple_link_test_code="\ program t end " # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_AC_SYS_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${F77-"f77"} compiler=$CC _LT_AC_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) test "$can_build_shared" = "no" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test "$enable_shared" = yes && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then test "$enable_shared" = yes && enable_static=no fi ;; esac AC_MSG_RESULT([$enable_shared]) AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. test "$enable_shared" = yes || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_AC_TAGVAR(GCC, $1)="$G77" _LT_AC_TAGVAR(LD, $1)="$LD" AC_LIBTOOL_PROG_COMPILER_PIC($1) AC_LIBTOOL_PROG_CC_C_O($1) AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) AC_LIBTOOL_PROG_LD_SHLIBS($1) AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) AC_LIBTOOL_CONFIG($1) AC_LANG_POP CC="$lt_save_CC" ])# AC_LIBTOOL_LANG_F77_CONFIG # AC_LIBTOOL_LANG_GCJ_CONFIG # -------------------------- # Ensure that the configuration vars for the C compiler are # suitably defined. Those variables are subsequently used by # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)]) AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG], [AC_LANG_SAVE # Source file extension for Java test sources. ac_ext=java # Object file extension for compiled Java test sources. objext=o _LT_AC_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="class foo {}" # Code to be used in simple link tests lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_AC_SYS_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${GCJ-"gcj"} compiler=$CC _LT_AC_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) # GCJ did not exist at the time GCC didn't implicitly link libc in. _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no _LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1) AC_LIBTOOL_PROG_COMPILER_PIC($1) AC_LIBTOOL_PROG_CC_C_O($1) AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1) AC_LIBTOOL_PROG_LD_SHLIBS($1) AC_LIBTOOL_SYS_DYNAMIC_LINKER($1) AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1) AC_LIBTOOL_CONFIG($1) AC_LANG_RESTORE CC="$lt_save_CC" ])# AC_LIBTOOL_LANG_GCJ_CONFIG # AC_LIBTOOL_LANG_RC_CONFIG # ------------------------- # Ensure that the configuration vars for the Windows resource compiler are # suitably defined. Those variables are subsequently used by # AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'. AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)]) AC_DEFUN([_LT_AC_LANG_RC_CONFIG], [AC_LANG_SAVE # Source file extension for RC test sources. ac_ext=rc # Object file extension for compiled RC test sources. objext=o _LT_AC_TAGVAR(objext, $1)=$objext # Code to be used in simple compile tests lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' # Code to be used in simple link tests lt_simple_link_test_code="$lt_simple_compile_test_code" # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_AC_SYS_COMPILER # save warnings/boilerplate of simple test code _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${RC-"windres"} compiler=$CC _LT_AC_TAGVAR(compiler, $1)=$CC _LT_CC_BASENAME([$compiler]) _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes AC_LIBTOOL_CONFIG($1) AC_LANG_RESTORE CC="$lt_save_CC" ])# AC_LIBTOOL_LANG_RC_CONFIG # AC_LIBTOOL_CONFIG([TAGNAME]) # ---------------------------- # If TAGNAME is not passed, then create an initial libtool script # with a default configuration from the untagged config vars. Otherwise # add code to config.status for appending the configuration named by # TAGNAME from the matching tagged config vars. AC_DEFUN([AC_LIBTOOL_CONFIG], [# The else clause should only fire when bootstrapping the # libtool distribution, otherwise you forgot to ship ltmain.sh # with your package, and you will get complaints that there are # no rules to generate ltmain.sh. if test -f "$ltmain"; then # See if we are running on zsh, and set the options which allow our commands through # without removal of \ escapes. if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi # Now quote all the things that may contain metacharacters while being # careful not to overquote the AC_SUBSTed values. We take copies of the # variables and quote the copies for generation of the libtool script. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ SED SHELL STRIP \ libname_spec library_names_spec soname_spec extract_expsyms_cmds \ old_striplib striplib file_magic_cmd finish_cmds finish_eval \ deplibs_check_method reload_flag reload_cmds need_locks \ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_c_name_address \ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ old_postinstall_cmds old_postuninstall_cmds \ _LT_AC_TAGVAR(compiler, $1) \ _LT_AC_TAGVAR(CC, $1) \ _LT_AC_TAGVAR(LD, $1) \ _LT_AC_TAGVAR(lt_prog_compiler_wl, $1) \ _LT_AC_TAGVAR(lt_prog_compiler_pic, $1) \ _LT_AC_TAGVAR(lt_prog_compiler_static, $1) \ _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) \ _LT_AC_TAGVAR(export_dynamic_flag_spec, $1) \ _LT_AC_TAGVAR(thread_safe_flag_spec, $1) \ _LT_AC_TAGVAR(whole_archive_flag_spec, $1) \ _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) \ _LT_AC_TAGVAR(old_archive_cmds, $1) \ _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) \ _LT_AC_TAGVAR(predep_objects, $1) \ _LT_AC_TAGVAR(postdep_objects, $1) \ _LT_AC_TAGVAR(predeps, $1) \ _LT_AC_TAGVAR(postdeps, $1) \ _LT_AC_TAGVAR(compiler_lib_search_path, $1) \ _LT_AC_TAGVAR(compiler_lib_search_dirs, $1) \ _LT_AC_TAGVAR(archive_cmds, $1) \ _LT_AC_TAGVAR(archive_expsym_cmds, $1) \ _LT_AC_TAGVAR(postinstall_cmds, $1) \ _LT_AC_TAGVAR(postuninstall_cmds, $1) \ _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) \ _LT_AC_TAGVAR(allow_undefined_flag, $1) \ _LT_AC_TAGVAR(no_undefined_flag, $1) \ _LT_AC_TAGVAR(export_symbols_cmds, $1) \ _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) \ _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) \ _LT_AC_TAGVAR(hardcode_libdir_separator, $1) \ _LT_AC_TAGVAR(hardcode_automatic, $1) \ _LT_AC_TAGVAR(module_cmds, $1) \ _LT_AC_TAGVAR(module_expsym_cmds, $1) \ _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \ _LT_AC_TAGVAR(fix_srcfile_path, $1) \ _LT_AC_TAGVAR(exclude_expsyms, $1) \ _LT_AC_TAGVAR(include_expsyms, $1); do case $var in _LT_AC_TAGVAR(old_archive_cmds, $1) | \ _LT_AC_TAGVAR(old_archive_from_new_cmds, $1) | \ _LT_AC_TAGVAR(archive_cmds, $1) | \ _LT_AC_TAGVAR(archive_expsym_cmds, $1) | \ _LT_AC_TAGVAR(module_cmds, $1) | \ _LT_AC_TAGVAR(module_expsym_cmds, $1) | \ _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) | \ _LT_AC_TAGVAR(export_symbols_cmds, $1) | \ extract_expsyms_cmds | reload_cmds | finish_cmds | \ postinstall_cmds | postuninstall_cmds | \ old_postinstall_cmds | old_postuninstall_cmds | \ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) # Double-quote double-evaled strings. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" ;; *) eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; esac done case $lt_echo in *'\[$]0 --fallback-echo"') lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\[$]0 --fallback-echo"[$]/[$]0 --fallback-echo"/'` ;; esac ifelse([$1], [], [cfgfile="${ofile}T" trap "$rm \"$cfgfile\"; exit 1" 1 2 15 $rm -f "$cfgfile" AC_MSG_NOTICE([creating $ofile])], [cfgfile="$ofile"]) cat <<__EOF__ >> "$cfgfile" ifelse([$1], [], [#! $SHELL # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) # NOTE: Changes made to this file will be lost: look at ltmain.sh. # # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 # Free Software Foundation, Inc. # # This file is part of GNU Libtool: # Originally by Gordon Matzigkeit , 1996 # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # A sed program that does not truncate output. SED=$lt_SED # Sed that helps us avoid accidentally triggering echo(1) options like -n. Xsed="$SED -e 1s/^X//" # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # The names of the tagged configurations supported by this script. available_tags= # ### BEGIN LIBTOOL CONFIG], [# ### BEGIN LIBTOOL TAG CONFIG: $tagname]) # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$_LT_AC_TAGVAR(archive_cmds_need_lc, $1) # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1) # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # An echo program that does not interpret backslashes. echo=$lt_echo # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A C compiler. LTCC=$lt_LTCC # LTCC compiler flags. LTCFLAGS=$lt_LTCFLAGS # A language-specific compiler. CC=$lt_[]_LT_AC_TAGVAR(compiler, $1) # Is the compiler the GNU C compiler? with_gcc=$_LT_AC_TAGVAR(GCC, $1) # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_[]_LT_AC_TAGVAR(LD, $1) # Whether we need hard or soft links. LN_S=$lt_LN_S # A BSD-compatible nm program. NM=$lt_NM # A symbol stripping program STRIP=$lt_STRIP # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL" # Used on cygwin: object dumper. OBJDUMP="$OBJDUMP" # Used on cygwin: assembler. AS="$AS" # The name of the directory that contains temporary libtool files. objdir=$objdir # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # How to pass a linker flag through the compiler. wl=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) # Object file suffix (normally "o"). objext="$ac_objext" # Old archive suffix (normally "a"). libext="$libext" # Shared library suffix (normally ".so"). shrext_cmds='$shrext_cmds' # Executable file suffix (normally ""). exeext="$exeext" # Additional compiler flags for building library objects. pic_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) pic_mode=$pic_mode # What is the maximum length of a command? max_cmd_len=$lt_cv_sys_max_cmd_len # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_[]_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) # Must we lock files when doing compilation? need_locks=$lt_need_locks # Do we need the lib prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Compiler flag to prevent dynamic linking. link_static_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_static, $1) # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_[]_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_[]_LT_AC_TAGVAR(export_dynamic_flag_spec, $1) # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_[]_LT_AC_TAGVAR(whole_archive_flag_spec, $1) # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_[]_LT_AC_TAGVAR(thread_safe_flag_spec, $1) # Library versioning type. version_type=$version_type # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Commands used to build and install an old-style archive. RANLIB=$lt_RANLIB old_archive_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_cmds, $1) old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_new_cmds, $1) # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_[]_LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1) # Commands used to build and install a shared archive. archive_cmds=$lt_[]_LT_AC_TAGVAR(archive_cmds, $1) archive_expsym_cmds=$lt_[]_LT_AC_TAGVAR(archive_expsym_cmds, $1) postinstall_cmds=$lt_postinstall_cmds postuninstall_cmds=$lt_postuninstall_cmds # Commands used to build a loadable module (assumed same as above if empty) module_cmds=$lt_[]_LT_AC_TAGVAR(module_cmds, $1) module_expsym_cmds=$lt_[]_LT_AC_TAGVAR(module_expsym_cmds, $1) # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_[]_LT_AC_TAGVAR(predep_objects, $1) # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_[]_LT_AC_TAGVAR(postdep_objects, $1) # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1) # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1) # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_dirs, $1) # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1) # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method == file_magic. file_magic_cmd=$lt_file_magic_cmd # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_[]_LT_AC_TAGVAR(allow_undefined_flag, $1) # Flag that forces no undefined symbols. no_undefined_flag=$lt_[]_LT_AC_TAGVAR(no_undefined_flag, $1) # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # Same as above, but a single script fragment to be evaled but not shown. finish_eval=$lt_finish_eval # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm in a C name address pair global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # This is the shared library runtime path variable. runpath_var=$runpath_var # This is the shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # How to hardcode a shared library path into an executable. hardcode_action=$_LT_AC_TAGVAR(hardcode_action, $1) # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist. hardcode_libdir_flag_spec=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) # If ld is used when linking, flag to hardcode \$libdir into # a binary during linking. This must work even if \$libdir does # not exist. hardcode_libdir_flag_spec_ld=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1) # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_[]_LT_AC_TAGVAR(hardcode_libdir_separator, $1) # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$_LT_AC_TAGVAR(hardcode_direct, $1) # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$_LT_AC_TAGVAR(hardcode_minus_L, $1) # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$_LT_AC_TAGVAR(hardcode_shlibpath_var, $1) # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=$_LT_AC_TAGVAR(hardcode_automatic, $1) # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="$variables_saved_for_relink" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$_LT_AC_TAGVAR(link_all_deplibs, $1) # Compile-time system search path for libraries sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Run-time system search path for libraries sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec # Fix the shell variable \$srcfile for the compiler. fix_srcfile_path=$lt_fix_srcfile_path # Set to yes if exported symbols are required. always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1) # The commands to list exported symbols. export_symbols_cmds=$lt_[]_LT_AC_TAGVAR(export_symbols_cmds, $1) # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_[]_LT_AC_TAGVAR(exclude_expsyms, $1) # Symbols that must always be exported. include_expsyms=$lt_[]_LT_AC_TAGVAR(include_expsyms, $1) ifelse([$1],[], [# ### END LIBTOOL CONFIG], [# ### END LIBTOOL TAG CONFIG: $tagname]) __EOF__ ifelse([$1],[], [ case $host_os in aix3*) cat <<\EOF >> "$cfgfile" # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test "X${COLLECT_NAMES+set}" != Xset; then COLLECT_NAMES= export COLLECT_NAMES fi EOF ;; esac # We use sed instead of cat because bash on DJGPP gets confused if # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || \ (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" ]) else # If there is no Makefile yet, we rely on a make rule to execute # `config.status --recheck' to rerun these tests and create the # libtool script then. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` if test -f "$ltmain_in"; then test -f Makefile && make "$ltmain" fi fi ])# AC_LIBTOOL_CONFIG # AC_LIBTOOL_PROG_COMPILER_NO_RTTI([TAGNAME]) # ------------------------------------------- AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_NO_RTTI], [AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= if test "$GCC" = yes; then _LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' AC_LIBTOOL_COMPILER_OPTION([if $compiler supports -fno-rtti -fno-exceptions], lt_cv_prog_compiler_rtti_exceptions, [-fno-rtti -fno-exceptions], [], [_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1) -fno-rtti -fno-exceptions"]) fi ])# AC_LIBTOOL_PROG_COMPILER_NO_RTTI # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE # --------------------------------- AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE], [AC_REQUIRE([AC_CANONICAL_HOST]) AC_REQUIRE([LT_AC_PROG_SED]) AC_REQUIRE([AC_PROG_NM]) AC_REQUIRE([AC_OBJEXT]) # Check for command to grab the raw symbol name followed by C symbol from nm. AC_MSG_CHECKING([command to parse $NM output from $compiler object]) AC_CACHE_VAL([lt_cv_sys_global_symbol_pipe], [ # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # Character class describing NM global symbol codes. symcode='[[BCDEGRST]]' # Regexp to match symbols that can be accessed directly from C. sympat='\([[_A-Za-z]][[_A-Za-z0-9]]*\)' # Transform an extracted symbol line into a proper C declaration lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" # Transform an extracted symbol line into symbol name and symbol address lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" # Define system-specific variables. case $host_os in aix*) symcode='[[BCDT]]' ;; cygwin* | mingw* | pw32*) symcode='[[ABCDGISTW]]' ;; hpux*) # Its linker distinguishes data from code symbols if test "$host_cpu" = ia64; then symcode='[[ABCDEGRST]]' fi lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" ;; linux* | k*bsd*-gnu) if test "$host_cpu" = ia64; then symcode='[[ABCDGIRSTW]]' lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" fi ;; irix* | nonstopux*) symcode='[[BCDEGRST]]' ;; osf*) symcode='[[BCDEGQRST]]' ;; solaris*) symcode='[[BDRT]]' ;; sco3.2v5*) symcode='[[DT]]' ;; sysv4.2uw2*) symcode='[[DT]]' ;; sysv5* | sco5v6* | unixware* | OpenUNIX*) symcode='[[ABDT]]' ;; sysv4) symcode='[[DFNSTU]]' ;; esac # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac # If we're using GNU nm, then use its standard symbol codes. case `$NM -V 2>&1` in *GNU* | *'with BFD'*) symcode='[[ABCDGIRSTW]]' ;; esac # Try without a prefix undercore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* cat > conftest.$ac_ext < $nlist) && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" else rm -f "$nlist"T fi # Make sure that we snagged all the symbols we need. if grep ' nm_test_var$' "$nlist" >/dev/null; then if grep ' nm_test_func$' "$nlist" >/dev/null; then cat < conftest.$ac_ext #ifdef __cplusplus extern "C" { #endif EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' cat <> conftest.$ac_ext #if defined (__STDC__) && __STDC__ # define lt_ptr_t void * #else # define lt_ptr_t char * # define const #endif /* The mapping between symbol names and symbols. */ const struct { const char *name; lt_ptr_t address; } lt_preloaded_symbols[[]] = { EOF $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext cat <<\EOF >> conftest.$ac_ext {0, (lt_ptr_t) 0} }; #ifdef __cplusplus } #endif EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_save_LIBS="$LIBS" lt_save_CFLAGS="$CFLAGS" LIBS="conftstm.$ac_objext" CFLAGS="$CFLAGS$_LT_AC_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then pipe_works=yes fi LIBS="$lt_save_LIBS" CFLAGS="$lt_save_CFLAGS" else echo "cannot find nm_test_func in $nlist" >&AS_MESSAGE_LOG_FD fi else echo "cannot find nm_test_var in $nlist" >&AS_MESSAGE_LOG_FD fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&AS_MESSAGE_LOG_FD fi else echo "$progname: failed program was:" >&AS_MESSAGE_LOG_FD cat conftest.$ac_ext >&5 fi rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. if test "$pipe_works" = yes; then break else lt_cv_sys_global_symbol_pipe= fi done ]) if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then AC_MSG_RESULT(failed) else AC_MSG_RESULT(ok) fi ]) # AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE # AC_LIBTOOL_PROG_COMPILER_PIC([TAGNAME]) # --------------------------------------- AC_DEFUN([AC_LIBTOOL_PROG_COMPILER_PIC], [_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)= _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= _LT_AC_TAGVAR(lt_prog_compiler_static, $1)= AC_MSG_CHECKING([for $compiler option to produce PIC]) ifelse([$1],[CXX],[ # C++ specific cases for pic, static, wl, etc. if test "$GXX" = yes; then _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi ;; amigaos*) # FIXME: we need at least 68020 code to build shared libraries, but # adding the `-m68020' flag to GCC prevents building anything better, # like `-m68040'. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | os2* | pw32*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' ;; *djgpp*) # DJGPP does not support shared libraries at all _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= ;; interix[[3-9]]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; sysv4*MP*) if test -d /usr/nec; then _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic fi ;; hpux*) # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) ;; *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac ;; *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac else case $host_os in aix[[4-9]]*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' fi ;; chorus*) case $cc_basename in cxch68*) # Green Hills C++ Compiler # _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" ;; esac ;; darwin*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files case $cc_basename in xlc*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' ;; esac ;; dgux*) case $cc_basename in ec++*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' ;; ghcx*) # Green Hills C++ Compiler _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; *) ;; esac ;; freebsd* | dragonfly*) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) case $cc_basename in CC*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' if test "$host_cpu" != ia64; then _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' fi ;; aCC*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' ;; esac ;; *) ;; esac ;; interix*) # This is c89, which is MS Visual C++ (no shared libs) # Anyone wants to do a port? ;; irix5* | irix6* | nonstopux*) case $cc_basename in CC*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' # CC pic flag -KPIC is the default. ;; *) ;; esac ;; linux* | k*bsd*-gnu) case $cc_basename in KCC*) # KAI C++ Compiler _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; icpc* | ecpc*) # Intel C++ _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; pgCC* | pgcpp*) # Portland Group C++ compiler. _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; cxx*) # Compaq C++ # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; esac ;; esac ;; lynxos*) ;; m88k*) ;; mvs*) case $cc_basename in cxx*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-W c,exportall' ;; *) ;; esac ;; netbsd* | netbsdelf*-gnu) ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='--backend -Wl,' ;; RCC*) # Rational C++ 2.4.1 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; cxx*) # Digital/Compaq C++ _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; *) ;; esac ;; psos*) ;; solaris*) case $cc_basename in CC*) # Sun C++ 4.2, 5.x and Centerline C++ _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' ;; gcx*) # Green Hills C++ Compiler _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' ;; *) ;; esac ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; lcc*) # Lucid _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' ;; *) ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' ;; *) ;; esac ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) case $cc_basename in CC*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; esac ;; vxworks*) ;; *) _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ], [ if test "$GCC" = yes; then _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi ;; amigaos*) # FIXME: we need at least 68020 code to build shared libraries, but # adding the `-m68020' flag to GCC prevents building anything better, # like `-m68040'. _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' ;; interix[[3-9]]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no enable_shared=no ;; sysv4*MP*) if test -d /usr/nec; then _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic fi ;; hpux*) # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac ;; *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-bnso -bI:/lib/syscalls.exp' fi ;; darwin*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files case $cc_basename in xlc*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-qnocommon' _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' ;; esac ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) ;; hpux9* | hpux10* | hpux11*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # PIC (with -KPIC) is the default. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; newsos6) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; linux* | k*bsd*-gnu) case $cc_basename in icc* | ecc*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; pgcc* | pgf77* | pgf90* | pgf95*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; ccc*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # All Alpha code is PIC. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' ;; *Sun\ F*) # Sun Fortran 8.3 passes all unrecognized flags to the linker _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='' ;; esac ;; esac ;; osf3* | osf4* | osf5*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' # All OSF/1 code is PIC. _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; rdos*) _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; solaris*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' case $cc_basename in f77* | f90* | f95*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ';; *) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,';; esac ;; sunos4*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld ' _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec ;then _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; unicos*) _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; uts4*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-pic' _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; *) _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no ;; esac fi ]) AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)]) # # Check to make sure the PIC flag actually works. # if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works], _LT_AC_TAGVAR(lt_cv_prog_compiler_pic_works, $1), [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [], [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in "" | " "*) ;; *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=" $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)" ;; esac], [_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no]) fi case $host_os in # For platforms which do not support PIC, -DPIC is meaningless: *djgpp*) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)= ;; *) _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])" ;; esac # # Check to make sure the static flag actually works. # wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\" AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works], _LT_AC_TAGVAR(lt_cv_prog_compiler_static_works, $1), $lt_tmp_static_flag, [], [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=]) ]) # AC_LIBTOOL_PROG_LD_SHLIBS([TAGNAME]) # ------------------------------------ # See if the linker supports building shared libraries. AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS], [AC_REQUIRE([LT_AC_PROG_SED])dnl AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries]) ifelse([$1],[CXX],[ _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' case $host_os in aix[[4-9]]*) # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to AIX nm, but means don't demangle with GNU nm if $NM -V 2>&1 | grep 'GNU' > /dev/null; then _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' else _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' fi ;; pw32*) _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" ;; cygwin* | mingw*) _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' ;; linux* | k*bsd*-gnu) _LT_AC_TAGVAR(link_all_deplibs, $1)=no ;; *) _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; esac _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] ],[ runpath_var= _LT_AC_TAGVAR(allow_undefined_flag, $1)= _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no _LT_AC_TAGVAR(archive_cmds, $1)= _LT_AC_TAGVAR(archive_expsym_cmds, $1)= _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)= _LT_AC_TAGVAR(old_archive_from_expsyms_cmds, $1)= _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= _LT_AC_TAGVAR(thread_safe_flag_spec, $1)= _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)= _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_minus_L, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_AC_TAGVAR(link_all_deplibs, $1)=unknown _LT_AC_TAGVAR(hardcode_automatic, $1)=no _LT_AC_TAGVAR(module_cmds, $1)= _LT_AC_TAGVAR(module_expsym_cmds, $1)= _LT_AC_TAGVAR(always_export_symbols, $1)=no _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list _LT_AC_TAGVAR(include_expsyms, $1)= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ` (' and `)$', so one must not match beginning or # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', # as well as any symbol that contains `d'. _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. dnl Note also adjust exclude_expsyms for C++ above. extract_expsyms_cmds= # Just being paranoid about ensuring that cc_basename is set. _LT_CC_BASENAME([$compiler]) case $host_os in cygwin* | mingw* | pw32*) # FIXME: the MSVC++ port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++. if test "$GCC" != yes; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++) with_gnu_ld=yes ;; openbsd*) with_gnu_ld=no ;; esac _LT_AC_TAGVAR(ld_shlibs, $1)=yes if test "$with_gnu_ld" = yes; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='${wl}' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= fi supports_anon_versioning=no case `$LD -v 2>/dev/null` in *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[[3-9]]*) # On AIX/PPC, the GNU linker is very broken if test "$host_cpu" != ia64; then _LT_AC_TAGVAR(ld_shlibs, $1)=no cat <&2 *** Warning: the GNU linker, at least up to release 2.9.1, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to modify your PATH *** so that a non-GNU linker is found, and then restart. EOF fi ;; amigaos*) _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Samuel A. Falvo II reports # that the semantics of dynamic libraries on AmigaOS, at least up # to version 4, is to share data among multiple programs linked # with the same dynamic library. Since this doesn't match the # behavior of shared libraries on other platforms, we can't use # them. _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; beos*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; cygwin* | mingw* | pw32*) # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_AC_TAGVAR(always_export_symbols, $1)=no _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols' if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file (1st line # is EXPORTS), use it as is; otherwise, prepend... _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; interix[[3-9]]*) _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | k*bsd*-gnu) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then tmp_addflag= case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; esac case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; *) tmp_sharedflag='-shared' ;; esac _LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' if test $supports_anon_versioning = yes; then _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ $echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' fi _LT_AC_TAGVAR(link_all_deplibs, $1)=no else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then _LT_AC_TAGVAR(ld_shlibs, $1)=no cat <&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. EOF elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*) _LT_AC_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; esac ;; sunos4*) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; esac if test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no; then runpath_var= _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)= _LT_AC_TAGVAR(whole_archive_flag_spec, $1)= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_AC_TAGVAR(always_export_symbols, $1)=yes _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported fi ;; aix[[4-9]]*) if test "$host_cpu" = ia64; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag="" else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to AIX nm, but means don't demangle with GNU nm if $NM -V 2>&1 | grep 'GNU' > /dev/null; then _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' else _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\[$]2 == "T") || (\[$]2 == "D") || (\[$]2 == "B")) && ([substr](\[$]3,1,1) != ".")) { print \[$]3 } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # need to do runtime linking. case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then aix_use_runtimelinking=yes break fi done ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. _LT_AC_TAGVAR(archive_cmds, $1)='' _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_AC_TAGVAR(link_all_deplibs, $1)=yes if test "$GCC" = yes; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`${CC} -print-prog-name=collect2` if test -f "$collect2name" && \ strings "$collect2name" | grep resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)= fi ;; esac shared_flag='-shared' if test "$aix_use_runtimelinking" = yes; then shared_flag="$shared_flag "'${wl}-G' fi else # not using gcc if test "$host_cpu" = ia64; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test "$aix_use_runtimelinking" = yes; then shared_flag='${wl}-G' else shared_flag='${wl}-bM:SRE' fi fi fi # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. _LT_AC_TAGVAR(always_export_symbols, $1)=yes if test "$aix_use_runtimelinking" = yes; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. _LT_AC_TAGVAR(allow_undefined_flag, $1)='-berok' # Determine the default libpath from the value encoded in an empty executable. _LT_AC_SYS_LIBPATH_AIX _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" else if test "$host_cpu" = ia64; then _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs" _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an empty executable. _LT_AC_SYS_LIBPATH_AIX _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' # Exported symbols can be pulled into shared objects from archives _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience' _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes # This is similar to how AIX traditionally builds its shared libraries. _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; amigaos*) _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # see comment about different semantics on the GNU ld section _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; bsdi[[45]]*) _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=-rdynamic ;; cygwin* | mingw* | pw32*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=' ' _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=".dll" # FIXME: Setting linknames here is a bad hack. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true' # FIXME: Should let the user specify the lib program. _LT_AC_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs' _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`' _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; darwin* | rhapsody*) case $host_os in rhapsody* | darwin1.[[012]]) _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[[012]]) _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 10.*) _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup' ;; esac fi ;; esac _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_automatic, $1)=yes _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='' _LT_AC_TAGVAR(link_all_deplibs, $1)=yes if test "$GCC" = yes ; then output_verbose_link_cmd='echo' _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" _LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" else case $cc_basename in xlc*) output_verbose_link_cmd='echo' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' ;; *) _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; esac fi ;; dgux*) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; freebsd1*) _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2*) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; hpux9*) if test "$GCC" = yes; then _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' else _LT_AC_TAGVAR(archive_cmds, $1)='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' fi _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: _LT_AC_TAGVAR(hardcode_direct, $1)=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' ;; hpux10*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test "$with_gnu_ld" = no; then _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes fi ;; hpux11*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then case $host_cpu in hppa*64*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac fi if test "$with_gnu_ld" = no; then _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir' _LT_AC_TAGVAR(hardcode_direct, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test "$GCC" = yes; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='-rpath $libdir' fi _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: _LT_AC_TAGVAR(link_all_deplibs, $1)=yes ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; newsos6) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; openbsd*) if test -f /usr/libexec/ld.so; then _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' else case $host_os in openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' ;; *) _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' ;; esac fi else _LT_AC_TAGVAR(ld_shlibs, $1)=no fi ;; os2*) _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_AC_TAGVAR(archive_cmds, $1)='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' ;; osf3*) if test "$GCC" = yes; then _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' fi _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test "$GCC" = yes; then _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' else _LT_AC_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' _LT_AC_TAGVAR(archive_cmds, $1)='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' # Both c and cxx compiler support -rpath directly _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' fi _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=: ;; solaris*) _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text' if test "$GCC" = yes; then wlarc='${wl}' _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' else wlarc='' _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' fi _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands `-z linker_flag'. GCC discards it without `$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test "$GCC" = yes; then _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' else _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' fi ;; esac _LT_AC_TAGVAR(link_all_deplibs, $1)=yes ;; sunos4*) if test "x$host_vendor" = xsequent; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_AC_TAGVAR(hardcode_direct, $1)=yes _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; sysv4) case $host_vendor in sni) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(hardcode_direct, $1)=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(reload_cmds, $1)='$CC -r -o $output$reload_objs' _LT_AC_TAGVAR(hardcode_direct, $1)=no ;; motorola) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(hardcode_direct, $1)=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; sysv4.3*) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes _LT_AC_TAGVAR(ld_shlibs, $1)=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We can NOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_AC_TAGVAR(link_all_deplibs, $1)=yes _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no ;; *) _LT_AC_TAGVAR(ld_shlibs, $1)=no ;; esac fi ]) AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)]) test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no # # Do we need to explicitly link libc? # case "x$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)" in x|xyes) # Assume -lc should be added _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes if test "$enable_shared" = yes && test "$GCC" = yes; then case $_LT_AC_TAGVAR(archive_cmds, $1) in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. AC_MSG_CHECKING([whether -lc should be explicitly linked in]) $rm conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if AC_TRY_EVAL(ac_compile) 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$_LT_AC_TAGVAR(allow_undefined_flag, $1) _LT_AC_TAGVAR(allow_undefined_flag, $1)= if AC_TRY_EVAL(_LT_AC_TAGVAR(archive_cmds, $1) 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) then _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no else _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes fi _LT_AC_TAGVAR(allow_undefined_flag, $1)=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $rm conftest* AC_MSG_RESULT([$_LT_AC_TAGVAR(archive_cmds_need_lc, $1)]) ;; esac fi ;; esac ])# AC_LIBTOOL_PROG_LD_SHLIBS # _LT_AC_FILE_LTDLL_C # ------------------- # Be careful that the start marker always follows a newline. AC_DEFUN([_LT_AC_FILE_LTDLL_C], [ # /* ltdll.c starts here */ # #define WIN32_LEAN_AND_MEAN # #include # #undef WIN32_LEAN_AND_MEAN # #include # # #ifndef __CYGWIN__ # # ifdef __CYGWIN32__ # # define __CYGWIN__ __CYGWIN32__ # # endif # #endif # # #ifdef __cplusplus # extern "C" { # #endif # BOOL APIENTRY DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved); # #ifdef __cplusplus # } # #endif # # #ifdef __CYGWIN__ # #include # DECLARE_CYGWIN_DLL( DllMain ); # #endif # HINSTANCE __hDllInstance_base; # # BOOL APIENTRY # DllMain (HINSTANCE hInst, DWORD reason, LPVOID reserved) # { # __hDllInstance_base = hInst; # return TRUE; # } # /* ltdll.c ends here */ ])# _LT_AC_FILE_LTDLL_C # _LT_AC_TAGVAR(VARNAME, [TAGNAME]) # --------------------------------- AC_DEFUN([_LT_AC_TAGVAR], [ifelse([$2], [], [$1], [$1_$2])]) # old names AC_DEFUN([AM_PROG_LIBTOOL], [AC_PROG_LIBTOOL]) AC_DEFUN([AM_ENABLE_SHARED], [AC_ENABLE_SHARED($@)]) AC_DEFUN([AM_ENABLE_STATIC], [AC_ENABLE_STATIC($@)]) AC_DEFUN([AM_DISABLE_SHARED], [AC_DISABLE_SHARED($@)]) AC_DEFUN([AM_DISABLE_STATIC], [AC_DISABLE_STATIC($@)]) AC_DEFUN([AM_PROG_LD], [AC_PROG_LD]) AC_DEFUN([AM_PROG_NM], [AC_PROG_NM]) # This is just to silence aclocal about the macro not being used ifelse([AC_DISABLE_FAST_INSTALL]) AC_DEFUN([LT_AC_PROG_GCJ], [AC_CHECK_TOOL(GCJ, gcj, no) test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" AC_SUBST(GCJFLAGS) ]) AC_DEFUN([LT_AC_PROG_RC], [AC_CHECK_TOOL(RC, windres, no) ]) # Cheap backport of AS_EXECUTABLE_P and required macros # from Autoconf 2.59; we should not use $as_executable_p directly. # _AS_TEST_PREPARE # ---------------- m4_ifndef([_AS_TEST_PREPARE], [m4_defun([_AS_TEST_PREPARE], [if test -x / >/dev/null 2>&1; then as_executable_p='test -x' else as_executable_p='test -f' fi ])])# _AS_TEST_PREPARE # AS_EXECUTABLE_P # --------------- # Check whether a file is executable. m4_ifndef([AS_EXECUTABLE_P], [m4_defun([AS_EXECUTABLE_P], [AS_REQUIRE([_AS_TEST_PREPARE])dnl $as_executable_p $1[]dnl ])])# AS_EXECUTABLE_P # NOTE: This macro has been submitted for inclusion into # # GNU Autoconf as AC_PROG_SED. When it is available in # # a released version of Autoconf we should remove this # # macro and use it instead. # # LT_AC_PROG_SED # -------------- # Check for a fully-functional sed program, that truncates # as few characters as possible. Prefer GNU sed if found. AC_DEFUN([LT_AC_PROG_SED], [AC_MSG_CHECKING([for a sed that does not truncate output]) AC_CACHE_VAL(lt_cv_path_SED, [# Loop through the user's path and test for sed and gsed. # Then use that list of sed's as ones to test for truncation. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for lt_ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do if AS_EXECUTABLE_P(["$as_dir/$lt_ac_prog$ac_exec_ext"]); then lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" fi done done done IFS=$as_save_IFS lt_ac_max=0 lt_ac_count=0 # Add /usr/xpg4/bin/sed as it is typically found on Solaris # along with /bin/sed that truncates output. for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do test ! -f $lt_ac_sed && continue cat /dev/null > conftest.in lt_ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >conftest.in # Check for GNU sed and select it if it is found. if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then lt_cv_path_SED=$lt_ac_sed break fi while true; do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo >>conftest.nl $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break cmp -s conftest.out conftest.nl || break # 10000 chars as input seems more than enough test $lt_ac_count -gt 10 && break lt_ac_count=`expr $lt_ac_count + 1` if test $lt_ac_count -gt $lt_ac_max; then lt_ac_max=$lt_ac_count lt_cv_path_SED=$lt_ac_sed fi done done ]) SED=$lt_cv_path_SED AC_SUBST([SED]) AC_MSG_RESULT([$SED]) ]) # Copyright (C) 2002, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_AUTOMAKE_VERSION(VERSION) # ---------------------------- # Automake X.Y traces this macro to ensure aclocal.m4 has been # generated from the m4 files accompanying Automake X.Y. AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version="1.9"]) # AM_SET_CURRENT_AUTOMAKE_VERSION # ------------------------------- # Call AM_AUTOMAKE_VERSION so it can be traced. # This function is AC_REQUIREd by AC_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], [AM_AUTOMAKE_VERSION([1.9.6])]) # AM_AUX_DIR_EXPAND -*- Autoconf -*- # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to # `$srcdir', `$srcdir/..', or `$srcdir/../..'. # # Of course, Automake must honor this variable whenever it calls a # tool from the auxiliary directory. The problem is that $srcdir (and # therefore $ac_aux_dir as well) can be either absolute or relative, # depending on how configure is run. This is pretty annoying, since # it makes $ac_aux_dir quite unusable in subdirectories: in the top # source directory, any form will work fine, but in subdirectories a # relative path needs to be adjusted first. # # $ac_aux_dir/missing # fails when called from a subdirectory if $ac_aux_dir is relative # $top_srcdir/$ac_aux_dir/missing # fails if $ac_aux_dir is absolute, # fails when called from a subdirectory in a VPATH build with # a relative $ac_aux_dir # # The reason of the latter failure is that $top_srcdir and $ac_aux_dir # are both prefixed by $srcdir. In an in-source build this is usually # harmless because $srcdir is `.', but things will broke when you # start a VPATH build or use an absolute $srcdir. # # So we could use something similar to $top_srcdir/$ac_aux_dir/missing, # iff we strip the leading $srcdir from $ac_aux_dir. That would be: # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` # and then we would define $MISSING as # MISSING="\${SHELL} $am_aux_dir/missing" # This will work as long as MISSING is not called from configure, because # unfortunately $(top_srcdir) has no meaning in configure. # However there are other variables, like CC, which are often used in # configure, and could therefore not use this "fixed" $ac_aux_dir. # # Another solution, used here, is to always expand $ac_aux_dir to an # absolute PATH. The drawback is that using absolute paths prevent a # configured tree to be moved without reconfiguration. AC_DEFUN([AM_AUX_DIR_EXPAND], [dnl Rely on autoconf to set up CDPATH properly. AC_PREREQ([2.50])dnl # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` ]) # AM_CONDITIONAL -*- Autoconf -*- # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 7 # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], [AC_PREREQ(2.52)dnl ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl AC_SUBST([$1_TRUE]) AC_SUBST([$1_FALSE]) if $2; then $1_TRUE= $1_FALSE='#' else $1_TRUE='#' $1_FALSE= fi AC_CONFIG_COMMANDS_PRE( [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then AC_MSG_ERROR([[conditional "$1" was never defined. Usually this means the macro was only invoked conditionally.]]) fi])]) # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 8 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be # written in clear, in which case automake, when reading aclocal.m4, # will think it sees a *use*, and therefore will trigger all it's # C support machinery. Also note that it means that autoscan, seeing # CC etc. in the Makefile, will ask for an AC_PROG_CC use... # _AM_DEPENDENCIES(NAME) # ---------------------- # See how the compiler implements dependency checking. # NAME is "CC", "CXX", "GCJ", or "OBJC". # We try a few techniques and use that to set a single cache variable. # # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular # dependency, and given that the user is not expected to run this macro, # just rely on AC_PROG_CC. AC_DEFUN([_AM_DEPENDENCIES], [AC_REQUIRE([AM_SET_DEPDIR])dnl AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl AC_REQUIRE([AM_MAKE_INCLUDE])dnl AC_REQUIRE([AM_DEP_TRACK])dnl ifelse([$1], CC, [depcc="$CC" am_compiler_list=], [$1], CXX, [depcc="$CXX" am_compiler_list=], [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], [depcc="$$1" am_compiler_list=]) AC_CACHE_CHECK([dependency style of $depcc], [am_cv_$1_dependencies_compiler_type], [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_$1_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_$1_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_$1_dependencies_compiler_type=none fi ]) AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) AM_CONDITIONAL([am__fastdep$1], [ test "x$enable_dependency_tracking" != xno \ && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) ]) # AM_SET_DEPDIR # ------------- # Choose a directory name for dependency files. # This macro is AC_REQUIREd in _AM_DEPENDENCIES AC_DEFUN([AM_SET_DEPDIR], [AC_REQUIRE([AM_SET_LEADING_DOT])dnl AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl ]) # AM_DEP_TRACK # ------------ AC_DEFUN([AM_DEP_TRACK], [AC_ARG_ENABLE(dependency-tracking, [ --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors]) if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) AC_SUBST([AMDEPBACKSLASH]) ]) # Generate code to set up dependency tracking. -*- Autoconf -*- # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. #serial 3 # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [for mf in $CONFIG_FILES; do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # So let's grep whole file. if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then dirpart=`AS_DIRNAME("$mf")` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`AS_DIRNAME(["$file"])` AS_MKDIR_P([$dirpart/$fdir]) # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done ])# _AM_OUTPUT_DEPENDENCY_COMMANDS # AM_OUTPUT_DEPENDENCY_COMMANDS # ----------------------------- # This macro should only be invoked once -- use via AC_REQUIRE. # # This code is only required when automatic dependency tracking # is enabled. FIXME. This creates each `.P' file that we will # need in order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) ]) # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 8 # AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) # Do all the work for Automake. -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 12 # This macro actually does too much. Some checks are only needed if # your package does certain things. But this isn't really a big deal. # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) # AM_INIT_AUTOMAKE([OPTIONS]) # ----------------------------------------------- # The call with PACKAGE and VERSION arguments is the old style # call (pre autoconf-2.50), which is being phased out. PACKAGE # and VERSION should now be passed to AC_INIT and removed from # the call to AM_INIT_AUTOMAKE. # We support both call styles for the transition. After # the next Automake release, Autoconf can make the AC_INIT # arguments mandatory, and then we can depend on a new Autoconf # release and drop the old call support. AC_DEFUN([AM_INIT_AUTOMAKE], [AC_PREREQ([2.58])dnl dnl Autoconf wants to disallow AM_ names. We explicitly allow dnl the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl AC_REQUIRE([AC_PROG_INSTALL])dnl # test to see if srcdir already configured if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi AC_SUBST([CYGPATH_W]) # Define the identity of the package. dnl Distinguish between old-style and new-style calls. m4_ifval([$2], [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl AC_SUBST([PACKAGE], [$1])dnl AC_SUBST([VERSION], [$2])], [_AM_SET_OPTIONS([$1])dnl AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl _AM_IF_OPTION([no-define],, [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl # Some tools Automake needs. AC_REQUIRE([AM_SANITY_CHECK])dnl AC_REQUIRE([AC_ARG_PROGRAM])dnl AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) AM_MISSING_PROG(AUTOCONF, autoconf) AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) AM_MISSING_PROG(AUTOHEADER, autoheader) AM_MISSING_PROG(MAKEINFO, makeinfo) AM_PROG_INSTALL_SH AM_PROG_INSTALL_STRIP AC_REQUIRE([AM_PROG_MKDIR_P])dnl # We need awk for the "check" target. The system "awk" is bad on # some platforms. AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AM_SET_LEADING_DOT])dnl _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], [_AM_PROG_TAR([v7])])]) _AM_IF_OPTION([no-dependencies],, [AC_PROVIDE_IFELSE([AC_PROG_CC], [_AM_DEPENDENCIES(CC)], [define([AC_PROG_CC], defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl AC_PROVIDE_IFELSE([AC_PROG_CXX], [_AM_DEPENDENCIES(CXX)], [define([AC_PROG_CXX], defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl ]) ]) # When config.status generates a header, we must update the stamp-h file. # This file resides in the same directory as the config header # that is generated. The stamp files are numbered to have different names. # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the # loop where config.status creates the headers, so we can generate # our stamp files there. AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], [# Compute $1's index in $config_headers. _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $1 | $1:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count]) # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_SH # ------------------ # Define $install_sh. AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl install_sh=${install_sh-"$am_aux_dir/install-sh"} AC_SUBST(install_sh)]) # Copyright (C) 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 2 # Check whether the underlying file-system supports filenames # with a leading dot. For instance MS-DOS doesn't. AC_DEFUN([AM_SET_LEADING_DOT], [rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null AC_SUBST([am__leading_dot])]) # Check to see how 'make' treats includes. -*- Autoconf -*- # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 3 # AM_MAKE_INCLUDE() # ----------------- # Check to see how make treats includes. AC_DEFUN([AM_MAKE_INCLUDE], [am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo done .PHONY: am__doit END # If we don't find an include directive, just comment out the code. AC_MSG_CHECKING([for style of include used by $am_make]) am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # We grep out `Entering directory' and `Leaving directory' # messages which can occur if `w' ends up in MAKEFLAGS. # In particular we don't look at `^make:' because GNU make might # be invoked under some other name (usually "gmake"), in which # case it prints its new name instead of `make'. if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then am__include=include am__quote= _am_result=GNU fi # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then am__include=.include am__quote="\"" _am_result=BSD fi fi AC_SUBST([am__include]) AC_SUBST([am__quote]) AC_MSG_RESULT([$_am_result]) rm -f confinc confmf ]) # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 4 # AM_MISSING_PROG(NAME, PROGRAM) # ------------------------------ AC_DEFUN([AM_MISSING_PROG], [AC_REQUIRE([AM_MISSING_HAS_RUN]) $1=${$1-"${am_missing_run}$2"} AC_SUBST($1)]) # AM_MISSING_HAS_RUN # ------------------ # Define MISSING if not defined so far and test if it supports --run. # If it does, set am_missing_run to use it, otherwise, to nothing. AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= AC_MSG_WARN([`missing' script is too old or missing]) fi ]) # Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_MKDIR_P # --------------- # Check whether `mkdir -p' is supported, fallback to mkinstalldirs otherwise. # # Automake 1.8 used `mkdir -m 0755 -p --' to ensure that directories # created by `make install' are always world readable, even if the # installer happens to have an overly restrictive umask (e.g. 077). # This was a mistake. There are at least two reasons why we must not # use `-m 0755': # - it causes special bits like SGID to be ignored, # - it may be too restrictive (some setups expect 775 directories). # # Do not use -m 0755 and let people choose whatever they expect by # setting umask. # # We cannot accept any implementation of `mkdir' that recognizes `-p'. # Some implementations (such as Solaris 8's) are not thread-safe: if a # parallel make tries to run `mkdir -p a/b' and `mkdir -p a/c' # concurrently, both version can detect that a/ is missing, but only # one can create it and the other will error out. Consequently we # restrict ourselves to GNU make (using the --version option ensures # this.) AC_DEFUN([AM_PROG_MKDIR_P], [if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then # We used to keeping the `.' as first argument, in order to # allow $(mkdir_p) to be used without argument. As in # $(mkdir_p) $(somedir) # where $(somedir) is conditionally defined. However this is wrong # for two reasons: # 1. if the package is installed by a user who cannot write `.' # make install will fail, # 2. the above comment should most certainly read # $(mkdir_p) $(DESTDIR)$(somedir) # so it does not work when $(somedir) is undefined and # $(DESTDIR) is not. # To support the latter case, we have to write # test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir), # so the `.' trick is pointless. mkdir_p='mkdir -p --' else # On NextStep and OpenStep, the `mkdir' command does not # recognize any option. It will interpret all options as # directories to create, and then abort because `.' already # exists. for d in ./-p ./--version; do test -d $d && rmdir $d done # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists. if test -f "$ac_aux_dir/mkinstalldirs"; then mkdir_p='$(mkinstalldirs)' else mkdir_p='$(install_sh) -d' fi fi AC_SUBST([mkdir_p])]) # Helper functions for option handling. -*- Autoconf -*- # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 3 # _AM_MANGLE_OPTION(NAME) # ----------------------- AC_DEFUN([_AM_MANGLE_OPTION], [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) # _AM_SET_OPTION(NAME) # ------------------------------ # Set option NAME. Presently that only means defining a flag for this option. AC_DEFUN([_AM_SET_OPTION], [m4_define(_AM_MANGLE_OPTION([$1]), 1)]) # _AM_SET_OPTIONS(OPTIONS) # ---------------------------------- # OPTIONS is a space-separated list of Automake options. AC_DEFUN([_AM_SET_OPTIONS], [AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) # ------------------------------------------- # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) # Check to make sure that the build environment is sane. -*- Autoconf -*- # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 4 # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane]) # Just in case sleep 1 echo timestamp > conftest.file # Do `set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` if test "$[*]" = "X"; then # -L didn't work. set X `ls -t $srcdir/configure conftest.file` fi rm -f conftest.file if test "$[*]" != "X $srcdir/configure conftest.file" \ && test "$[*]" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken alias in your environment]) fi test "$[2]" = conftest.file ) then # Ok. : else AC_MSG_ERROR([newly created file is older than distributed files! Check your system clock]) fi AC_MSG_RESULT(yes)]) # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_STRIP # --------------------- # One issue with vendor `install' (even GNU) is that you can't # specify the program used to strip binaries. This is especially # annoying in cross-compiling environments, where the build's strip # is unlikely to handle the host's binaries. # Fortunately install-sh will honor a STRIPPROG variable, so we # always use install-sh in `make install-strip', and initialize # STRIPPROG with the value of the STRIP variable (set by the user). AC_DEFUN([AM_PROG_INSTALL_STRIP], [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl # Installed binaries are usually stripped using `strip' when the user # run `make install-strip'. However `strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the `STRIP' environment variable to overrule this program. dnl Don't test for $cross_compiling = yes, because it might be `maybe'. if test "$cross_compiling" != no; then AC_CHECK_TOOL([STRIP], [strip], :) fi INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) # Check how to create a tarball. -*- Autoconf -*- # Copyright (C) 2004, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 2 # _AM_PROG_TAR(FORMAT) # -------------------- # Check how to create a tarball in format FORMAT. # FORMAT should be one of `v7', `ustar', or `pax'. # # Substitute a variable $(am__tar) that is a command # writing to stdout a FORMAT-tarball containing the directory # $tardir. # tardir=directory && $(am__tar) > result.tar # # Substitute a variable $(am__untar) that extract such # a tarball read from stdin. # $(am__untar) < result.tar AC_DEFUN([_AM_PROG_TAR], [# Always define AMTAR for backward compatibility. AM_MISSING_PROG([AMTAR], [tar]) m4_if([$1], [v7], [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], [m4_case([$1], [ustar],, [pax],, [m4_fatal([Unknown tar format])]) AC_MSG_CHECKING([how to create a $1 tar archive]) # Loop over all known methods to create a tar archive until one works. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' _am_tools=${am_cv_prog_tar_$1-$_am_tools} # Do not fold the above two line into one, because Tru64 sh and # Solaris sh will not grok spaces in the rhs of `-'. for _am_tool in $_am_tools do case $_am_tool in gnutar) for _am_tar in tar gnutar gtar; do AM_RUN_LOG([$_am_tar --version]) && break done am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' am__untar="$_am_tar -xf -" ;; plaintar) # Must skip GNU tar: if it does not support --format= it doesn't create # ustar tarball either. (tar --version) >/dev/null 2>&1 && continue am__tar='tar chf - "$$tardir"' am__tar_='tar chf - "$tardir"' am__untar='tar xf -' ;; pax) am__tar='pax -L -x $1 -w "$$tardir"' am__tar_='pax -L -x $1 -w "$tardir"' am__untar='pax -r' ;; cpio) am__tar='find "$$tardir" -print | cpio -o -H $1 -L' am__tar_='find "$tardir" -print | cpio -o -H $1 -L' am__untar='cpio -i -H $1 -d' ;; none) am__tar=false am__tar_=false am__untar=false ;; esac # If the value was cached, stop now. We just wanted to have am__tar # and am__untar set. test -n "${am_cv_prog_tar_$1}" && break # tar/untar a dummy directory, and stop if the command works rm -rf conftest.dir mkdir conftest.dir echo GrepMe > conftest.dir/file AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) rm -rf conftest.dir if test -s conftest.tar; then AM_RUN_LOG([$am__untar /dev/null 2>&1 && break fi done rm -rf conftest.dir AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) AC_MSG_RESULT([$am_cv_prog_tar_$1])]) AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR tgif-QPL-4.2.5/rmcast/libtool0000755000076400007640000070027011602233137015662 0ustar williamwilliam#! /bin/sh # libtoolT - Provide generalized library-building support services. # Generated automatically by (GNU rmcast 2.0.0) # NOTE: Changes made to this file will be lost: look at ltmain.sh. # # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 # Free Software Foundation, Inc. # # This file is part of GNU Libtool: # Originally by Gordon Matzigkeit , 1996 # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # A sed program that does not truncate output. SED="/bin/sed" # Sed that helps us avoid accidentally triggering echo(1) options like -n. Xsed="/bin/sed -e 1s/^X//" # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # The names of the tagged configurations supported by this script. available_tags=" CXX F77" # ### BEGIN LIBTOOL CONFIG # Libtool was configured on host merlot.usc.edu: # Shell to use when invoking shell scripts. SHELL="/bin/sh" # Whether or not to build shared libraries. build_libtool_libs=yes # Whether or not to build static libraries. build_old_libs=yes # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=no # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=no # Whether or not to optimize for fast installation. fast_install=yes # The host system. host_alias= host=i686-pc-linux-gnu host_os=linux-gnu # The build system. build_alias= build=i686-pc-linux-gnu build_os=linux-gnu # An echo program that does not interpret backslashes. echo="echo" # The archiver. AR="ar" AR_FLAGS="cru" # A C compiler. LTCC="gcc" # LTCC compiler flags. LTCFLAGS="-g -O2" # A language-specific compiler. CC="gcc" # Is the compiler the GNU C compiler? with_gcc=yes # An ERE matcher. EGREP="/bin/grep -E" # The linker used to build libraries. LD="/usr/bin/ld" # Whether we need hard or soft links. LN_S="ln -s" # A BSD-compatible nm program. NM="/usr/bin/nm -B" # A symbol stripping program STRIP="strip" # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=file # Used on cygwin: DLL creation program. DLLTOOL="dlltool" # Used on cygwin: object dumper. OBJDUMP="objdump" # Used on cygwin: assembler. AS="as" # The name of the directory that contains temporary libtool files. objdir=.libs # How to create reloadable object files. reload_flag=" -r" reload_cmds="\$LD\$reload_flag -o \$output\$reload_objs" # How to pass a linker flag through the compiler. wl="-Wl," # Object file suffix (normally "o"). objext="o" # Old archive suffix (normally "a"). libext="a" # Shared library suffix (normally ".so"). shrext_cmds='.so' # Executable file suffix (normally ""). exeext="" # Additional compiler flags for building library objects. pic_flag=" -fPIC -DPIC" pic_mode=default # What is the maximum length of a command? max_cmd_len=98304 # Does compiler simultaneously support -c and -o options? compiler_c_o="yes" # Must we lock files when doing compilation? need_locks="no" # Do we need the lib prefix for modules? need_lib_prefix=no # Do we need a version for libraries? need_version=no # Whether dlopen is supported. dlopen_support=unknown # Whether dlopen of programs is supported. dlopen_self=unknown # Whether dlopen of statically linked programs is supported. dlopen_self_static=unknown # Compiler flag to prevent dynamic linking. link_static_flag="-static" # Compiler flag to turn off builtin functions. no_builtin_flag=" -fno-builtin" # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec="\${wl}--export-dynamic" # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec="\${wl}--whole-archive\$convenience \${wl}--no-whole-archive" # Compiler flag to generate thread-safe objects. thread_safe_flag_spec="" # Library versioning type. version_type=linux # Format of library name prefix. libname_spec="lib\$name" # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec="\${libname}\${release}\${shared_ext}\$versuffix \${libname}\${release}\${shared_ext}\$major \$libname\${shared_ext}" # The coded name of the library, if different from the real name. soname_spec="\${libname}\${release}\${shared_ext}\$major" # Commands used to build and install an old-style archive. RANLIB="ranlib" old_archive_cmds="\$AR \$AR_FLAGS \$oldlib\$oldobjs~\$RANLIB \$oldlib" old_postinstall_cmds="chmod 644 \$oldlib~\$RANLIB \$oldlib" old_postuninstall_cmds="" # Create an old-style archive from a shared archive. old_archive_from_new_cmds="" # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds="" # Commands used to build and install a shared archive. archive_cmds="\$CC -shared \$libobjs \$deplibs \$compiler_flags \${wl}-soname \$wl\$soname -o \$lib" archive_expsym_cmds="\$echo \\\"{ global:\\\" > \$output_objdir/\$libname.ver~ cat \$export_symbols | sed -e \\\"s/\\\\(.*\\\\)/\\\\1;/\\\" >> \$output_objdir/\$libname.ver~ \$echo \\\"local: *; };\\\" >> \$output_objdir/\$libname.ver~ \$CC -shared \$libobjs \$deplibs \$compiler_flags \${wl}-soname \$wl\$soname \${wl}-version-script \${wl}\$output_objdir/\$libname.ver -o \$lib" postinstall_cmds="" postuninstall_cmds="" # Commands used to build a loadable module (assumed same as above if empty) module_cmds="" module_expsym_cmds="" # Commands to strip libraries. old_striplib="strip --strip-debug" striplib="strip --strip-unneeded" # Dependencies to place before the objects being linked to create a # shared library. predep_objects="" # Dependencies to place after the objects being linked to create a # shared library. postdep_objects="" # Dependencies to place before the objects being linked to create a # shared library. predeps="" # Dependencies to place after the objects being linked to create a # shared library. postdeps="" # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs="" # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path="" # Method to check whether dependent libraries are shared objects. deplibs_check_method="pass_all" # Command to use when deplibs_check_method == file_magic. file_magic_cmd="\$MAGIC_CMD" # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag="" # Flag that forces no undefined symbols. no_undefined_flag="" # Commands used to finish a libtool library installation in a directory. finish_cmds="PATH=\\\"\\\$PATH:/sbin\\\" ldconfig -n \$libdir" # Same as above, but a single script fragment to be evaled but not shown. finish_eval="" # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe="sed -n -e 's/^.*[ ]\\([ABCDGIRSTW][ABCDGIRSTW]*\\)[ ][ ]*\\([_A-Za-z][_A-Za-z0-9]*\\)\$/\\1 \\2 \\2/p'" # Transform the output of nm in a proper C declaration global_symbol_to_cdecl="sed -n -e 's/^. .* \\(.*\\)\$/extern int \\1;/p'" # Transform the output of nm in a C name address pair global_symbol_to_c_name_address="sed -n -e 's/^: \\([^ ]*\\) \$/ {\\\"\\1\\\", (lt_ptr) 0},/p' -e 's/^[BCDEGRST] \\([^ ]*\\) \\([^ ]*\\)\$/ {\"\\2\", (lt_ptr) \\&\\2},/p'" # This is the shared library runtime path variable. runpath_var=LD_RUN_PATH # This is the shared library path variable. shlibpath_var=LD_LIBRARY_PATH # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=no # How to hardcode a shared library path into an executable. hardcode_action=immediate # Whether we should hardcode library paths into libraries. hardcode_into_libs=yes # Flag to hardcode $libdir into a binary during linking. # This must work even if $libdir does not exist. hardcode_libdir_flag_spec="\${wl}--rpath \${wl}\$libdir" # If ld is used when linking, flag to hardcode $libdir into # a binary during linking. This must work even if $libdir does # not exist. hardcode_libdir_flag_spec_ld="" # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator="" # Set to yes if using DIR/libNAME during linking hardcodes DIR into the # resulting binary. hardcode_direct=no # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=no # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=unsupported # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=no # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="PATH LD_LIBRARY_PATH LD_RUN_PATH GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=no # Compile-time system search path for libraries sys_lib_search_path_spec="/usr/lib/gcc/i386-redhat-linux/4.1.2 /usr/lib /lib" # Run-time system search path for libraries sys_lib_dlsearch_path_spec="/lib /usr/lib /usr/lib/mysql /usr/lib/opensync/ /usr/lib/opensync/formats/ /usr/lib/opensync/plugins/ /usr/lib/qt-3.3/lib " # Fix the shell variable $srcfile for the compiler. fix_srcfile_path="" # Set to yes if exported symbols are required. always_export_symbols=no # The commands to list exported symbols. export_symbols_cmds="\$NM \$libobjs \$convenience | \$global_symbol_pipe | \$SED 's/.* //' | sort | uniq > \$export_symbols" # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds="" # Symbols that should not be listed in the preloaded symbols. exclude_expsyms="_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*" # Symbols that must always be exported. include_expsyms="" # ### END LIBTOOL CONFIG # ltmain.sh - Provide generalized library-building support services. # NOTE: Changing this file will not affect anything until you rerun configure. # # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, # 2007, 2008 Free Software Foundation, Inc. # Originally by Gordon Matzigkeit , 1996 # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. basename="s,^.*/,,g" # Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh # is ksh but when the shell is invoked as "sh" and the current value of # the _XPG environment variable is not equal to 1 (one), the special # positional parameter $0, within a function call, is the name of the # function. progpath="$0" # The name of this program: progname=`echo "$progpath" | $SED $basename` modename="$progname" # Global variables: EXIT_SUCCESS=0 EXIT_FAILURE=1 PROGRAM=ltmain.sh PACKAGE=libtool VERSION="1.5.26 Debian 1.5.26-1ubuntu1" TIMESTAMP=" (1.1220.2.493 2008/02/01 16:58:18)" # Be Bourne compatible (taken from Autoconf:_AS_BOURNE_COMPATIBLE). if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac fi BIN_SH=xpg4; export BIN_SH # for Tru64 DUALCASE=1; export DUALCASE # for MKS sh # Check that we have a working $echo. if test "X$1" = X--no-reexec; then # Discard the --no-reexec flag, and continue. shift elif test "X$1" = X--fallback-echo; then # Avoid inline document here, it may be left over : elif test "X`($echo '\t') 2>/dev/null`" = 'X\t'; then # Yippee, $echo works! : else # Restart under the correct shell, and then maybe $echo will work. exec $SHELL "$progpath" --no-reexec ${1+"$@"} fi if test "X$1" = X--fallback-echo; then # used as fallback echo shift cat <&2 $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 exit $EXIT_FAILURE fi # Global variables. mode=$default_mode nonopt= prev= prevopt= run= show="$echo" show_help= execute_dlfiles= duplicate_deps=no preserve_args= lo2o="s/\\.lo\$/.${objext}/" o2lo="s/\\.${objext}\$/.lo/" extracted_archives= extracted_serial=0 ##################################### # Shell function definitions: # This seems to be the best place for them # func_mktempdir [string] # Make a temporary directory that won't clash with other running # libtool processes, and avoids race conditions if possible. If # given, STRING is the basename for that directory. func_mktempdir () { my_template="${TMPDIR-/tmp}/${1-$progname}" if test "$run" = ":"; then # Return a directory name, but don't create it in dry-run mode my_tmpdir="${my_template}-$$" else # If mktemp works, use that first and foremost my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` if test ! -d "$my_tmpdir"; then # Failing that, at least try and use $RANDOM to avoid a race my_tmpdir="${my_template}-${RANDOM-0}$$" save_mktempdir_umask=`umask` umask 0077 $mkdir "$my_tmpdir" umask $save_mktempdir_umask fi # If we're not in dry-run mode, bomb out on failure test -d "$my_tmpdir" || { $echo "cannot create temporary directory \`$my_tmpdir'" 1>&2 exit $EXIT_FAILURE } fi $echo "X$my_tmpdir" | $Xsed } # func_win32_libid arg # return the library type of file 'arg' # # Need a lot of goo to handle *both* DLLs and import libs # Has to be a shell function in order to 'eat' the argument # that is supplied when $file_magic_command is called. func_win32_libid () { win32_libid_type="unknown" win32_fileres=`file -L $1 2>/dev/null` case $win32_fileres in *ar\ archive\ import\ library*) # definitely import win32_libid_type="x86 archive import" ;; *ar\ archive*) # could be an import, or static if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | \ $EGREP -e 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then win32_nmres=`eval $NM -f posix -A $1 | \ $SED -n -e '1,100{ / I /{ s,.*,import, p q } }'` case $win32_nmres in import*) win32_libid_type="x86 archive import";; *) win32_libid_type="x86 archive static";; esac fi ;; *DLL*) win32_libid_type="x86 DLL" ;; *executable*) # but shell scripts are "executable" too... case $win32_fileres in *MS\ Windows\ PE\ Intel*) win32_libid_type="x86 DLL" ;; esac ;; esac $echo $win32_libid_type } # func_infer_tag arg # Infer tagged configuration to use if any are available and # if one wasn't chosen via the "--tag" command line option. # Only attempt this if the compiler in the base compile # command doesn't match the default compiler. # arg is usually of the form 'gcc ...' func_infer_tag () { if test -n "$available_tags" && test -z "$tagname"; then CC_quoted= for arg in $CC; do case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac CC_quoted="$CC_quoted $arg" done case $@ in # Blanks in the command may have been stripped by the calling shell, # but not from the CC environment variable when configure was run. " $CC "* | "$CC "* | " `$echo $CC` "* | "`$echo $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$echo $CC_quoted` "* | "`$echo $CC_quoted` "*) ;; # Blanks at the start of $base_compile will cause this to fail # if we don't check for them as well. *) for z in $available_tags; do if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then # Evaluate the configuration. eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" CC_quoted= for arg in $CC; do # Double-quote args containing other shell metacharacters. case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac CC_quoted="$CC_quoted $arg" done case "$@ " in " $CC "* | "$CC "* | " `$echo $CC` "* | "`$echo $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$echo $CC_quoted` "* | "`$echo $CC_quoted` "*) # The compiler in the base compile command matches # the one in the tagged configuration. # Assume this is the tagged configuration we want. tagname=$z break ;; esac fi done # If $tagname still isn't set, then no tagged configuration # was found and let the user know that the "--tag" command # line option must be used. if test -z "$tagname"; then $echo "$modename: unable to infer tagged configuration" $echo "$modename: specify a tag with \`--tag'" 1>&2 exit $EXIT_FAILURE # else # $echo "$modename: using $tagname tagged configuration" fi ;; esac fi } # func_extract_an_archive dir oldlib func_extract_an_archive () { f_ex_an_ar_dir="$1"; shift f_ex_an_ar_oldlib="$1" $show "(cd $f_ex_an_ar_dir && $AR x $f_ex_an_ar_oldlib)" $run eval "(cd \$f_ex_an_ar_dir && $AR x \$f_ex_an_ar_oldlib)" || exit $? if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then : else $echo "$modename: ERROR: object name conflicts: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" 1>&2 exit $EXIT_FAILURE fi } # func_extract_archives gentop oldlib ... func_extract_archives () { my_gentop="$1"; shift my_oldlibs=${1+"$@"} my_oldobjs="" my_xlib="" my_xabs="" my_xdir="" my_status="" $show "${rm}r $my_gentop" $run ${rm}r "$my_gentop" $show "$mkdir $my_gentop" $run $mkdir "$my_gentop" my_status=$? if test "$my_status" -ne 0 && test ! -d "$my_gentop"; then exit $my_status fi for my_xlib in $my_oldlibs; do # Extract the objects. case $my_xlib in [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; *) my_xabs=`pwd`"/$my_xlib" ;; esac my_xlib=`$echo "X$my_xlib" | $Xsed -e 's%^.*/%%'` my_xlib_u=$my_xlib while :; do case " $extracted_archives " in *" $my_xlib_u "*) extracted_serial=`expr $extracted_serial + 1` my_xlib_u=lt$extracted_serial-$my_xlib ;; *) break ;; esac done extracted_archives="$extracted_archives $my_xlib_u" my_xdir="$my_gentop/$my_xlib_u" $show "${rm}r $my_xdir" $run ${rm}r "$my_xdir" $show "$mkdir $my_xdir" $run $mkdir "$my_xdir" exit_status=$? if test "$exit_status" -ne 0 && test ! -d "$my_xdir"; then exit $exit_status fi case $host in *-darwin*) $show "Extracting $my_xabs" # Do not bother doing anything if just a dry run if test -z "$run"; then darwin_orig_dir=`pwd` cd $my_xdir || exit $? darwin_archive=$my_xabs darwin_curdir=`pwd` darwin_base_archive=`$echo "X$darwin_archive" | $Xsed -e 's%^.*/%%'` darwin_arches=`lipo -info "$darwin_archive" 2>/dev/null | $EGREP Architectures 2>/dev/null` if test -n "$darwin_arches"; then darwin_arches=`echo "$darwin_arches" | $SED -e 's/.*are://'` darwin_arch= $show "$darwin_base_archive has multiple architectures $darwin_arches" for darwin_arch in $darwin_arches ; do mkdir -p "unfat-$$/${darwin_base_archive}-${darwin_arch}" lipo -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" func_extract_an_archive "`pwd`" "${darwin_base_archive}" cd "$darwin_curdir" $rm "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" done # $darwin_arches ## Okay now we have a bunch of thin objects, gotta fatten them up :) darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print| xargs basename | sort -u | $NL2SP` darwin_file= darwin_files= for darwin_file in $darwin_filelist; do darwin_files=`find unfat-$$ -name $darwin_file -print | $NL2SP` lipo -create -output "$darwin_file" $darwin_files done # $darwin_filelist ${rm}r unfat-$$ cd "$darwin_orig_dir" else cd "$darwin_orig_dir" func_extract_an_archive "$my_xdir" "$my_xabs" fi # $darwin_arches fi # $run ;; *) func_extract_an_archive "$my_xdir" "$my_xabs" ;; esac my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP` done func_extract_archives_result="$my_oldobjs" } # End of Shell function definitions ##################################### # Darwin sucks eval std_shrext=\"$shrext_cmds\" disable_libs=no # Parse our command line options once, thoroughly. while test "$#" -gt 0 do arg="$1" shift case $arg in -*=*) optarg=`$echo "X$arg" | $Xsed -e 's/[-_a-zA-Z0-9]*=//'` ;; *) optarg= ;; esac # If the previous option needs an argument, assign it. if test -n "$prev"; then case $prev in execute_dlfiles) execute_dlfiles="$execute_dlfiles $arg" ;; tag) tagname="$arg" preserve_args="${preserve_args}=$arg" # Check whether tagname contains only valid characters case $tagname in *[!-_A-Za-z0-9,/]*) $echo "$progname: invalid tag name: $tagname" 1>&2 exit $EXIT_FAILURE ;; esac case $tagname in CC) # Don't test for the "default" C tag, as we know, it's there, but # not specially marked. ;; *) if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "$progpath" > /dev/null; then taglist="$taglist $tagname" # Evaluate the configuration. eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$tagname'$/,/^# ### END LIBTOOL TAG CONFIG: '$tagname'$/p' < $progpath`" else $echo "$progname: ignoring unknown tag $tagname" 1>&2 fi ;; esac ;; *) eval "$prev=\$arg" ;; esac prev= prevopt= continue fi # Have we seen a non-optional argument yet? case $arg in --help) show_help=yes ;; --version) echo "\ $PROGRAM (GNU $PACKAGE) $VERSION$TIMESTAMP Copyright (C) 2008 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." exit $? ;; --config) ${SED} -e '1,/^# ### BEGIN LIBTOOL CONFIG/d' -e '/^# ### END LIBTOOL CONFIG/,$d' $progpath # Now print the configurations for the tags. for tagname in $taglist; do ${SED} -n -e "/^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$/,/^# ### END LIBTOOL TAG CONFIG: $tagname$/p" < "$progpath" done exit $? ;; --debug) $echo "$progname: enabling shell trace mode" set -x preserve_args="$preserve_args $arg" ;; --dry-run | -n) run=: ;; --features) $echo "host: $host" if test "$build_libtool_libs" = yes; then $echo "enable shared libraries" else $echo "disable shared libraries" fi if test "$build_old_libs" = yes; then $echo "enable static libraries" else $echo "disable static libraries" fi exit $? ;; --finish) mode="finish" ;; --mode) prevopt="--mode" prev=mode ;; --mode=*) mode="$optarg" ;; --preserve-dup-deps) duplicate_deps="yes" ;; --quiet | --silent) show=: preserve_args="$preserve_args $arg" ;; --tag) prevopt="--tag" prev=tag preserve_args="$preserve_args --tag" ;; --tag=*) set tag "$optarg" ${1+"$@"} shift prev=tag preserve_args="$preserve_args --tag" ;; -dlopen) prevopt="-dlopen" prev=execute_dlfiles ;; -*) $echo "$modename: unrecognized option \`$arg'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; *) nonopt="$arg" break ;; esac done if test -n "$prevopt"; then $echo "$modename: option \`$prevopt' requires an argument" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi case $disable_libs in no) ;; shared) build_libtool_libs=no build_old_libs=yes ;; static) build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` ;; esac # If this variable is set in any of the actions, the command in it # will be execed at the end. This prevents here-documents from being # left over by shells. exec_cmd= if test -z "$show_help"; then # Infer the operation mode. if test -z "$mode"; then $echo "*** Warning: inferring the mode of operation is deprecated." 1>&2 $echo "*** Future versions of Libtool will require --mode=MODE be specified." 1>&2 case $nonopt in *cc | cc* | *++ | gcc* | *-gcc* | g++* | xlc*) mode=link for arg do case $arg in -c) mode=compile break ;; esac done ;; *db | *dbx | *strace | *truss) mode=execute ;; *install*|cp|mv) mode=install ;; *rm) mode=uninstall ;; *) # If we have no mode, but dlfiles were specified, then do execute mode. test -n "$execute_dlfiles" && mode=execute # Just use the default operation mode. if test -z "$mode"; then if test -n "$nonopt"; then $echo "$modename: warning: cannot infer operation mode from \`$nonopt'" 1>&2 else $echo "$modename: warning: cannot infer operation mode without MODE-ARGS" 1>&2 fi fi ;; esac fi # Only execute mode is allowed to have -dlopen flags. if test -n "$execute_dlfiles" && test "$mode" != execute; then $echo "$modename: unrecognized option \`-dlopen'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Change the help message to a mode-specific one. generic_help="$help" help="Try \`$modename --help --mode=$mode' for more information." # These modes are in order of execution frequency so that they run quickly. case $mode in # libtool compile mode compile) modename="$modename: compile" # Get the compilation command and the source file. base_compile= srcfile="$nonopt" # always keep a non-empty value in "srcfile" suppress_opt=yes suppress_output= arg_mode=normal libobj= later= for arg do case $arg_mode in arg ) # do not "continue". Instead, add this to base_compile lastarg="$arg" arg_mode=normal ;; target ) libobj="$arg" arg_mode=normal continue ;; normal ) # Accept any command-line options. case $arg in -o) if test -n "$libobj" ; then $echo "$modename: you cannot specify \`-o' more than once" 1>&2 exit $EXIT_FAILURE fi arg_mode=target continue ;; -static | -prefer-pic | -prefer-non-pic) later="$later $arg" continue ;; -no-suppress) suppress_opt=no continue ;; -Xcompiler) arg_mode=arg # the next one goes into the "base_compile" arg list continue # The current "srcfile" will either be retained or ;; # replaced later. I would guess that would be a bug. -Wc,*) args=`$echo "X$arg" | $Xsed -e "s/^-Wc,//"` lastarg= save_ifs="$IFS"; IFS=',' for arg in $args; do IFS="$save_ifs" # Double-quote args containing other shell metacharacters. # Many Bourne shells cannot handle close brackets correctly # in scan sets, so we specify it separately. case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac lastarg="$lastarg $arg" done IFS="$save_ifs" lastarg=`$echo "X$lastarg" | $Xsed -e "s/^ //"` # Add the arguments to base_compile. base_compile="$base_compile $lastarg" continue ;; * ) # Accept the current argument as the source file. # The previous "srcfile" becomes the current argument. # lastarg="$srcfile" srcfile="$arg" ;; esac # case $arg ;; esac # case $arg_mode # Aesthetically quote the previous argument. lastarg=`$echo "X$lastarg" | $Xsed -e "$sed_quote_subst"` case $lastarg in # Double-quote args containing other shell metacharacters. # Many Bourne shells cannot handle close brackets correctly # in scan sets, and some SunOS ksh mistreat backslash-escaping # in scan sets (worked around with variable expansion), # and furthermore cannot handle '|' '&' '(' ')' in scan sets # at all, so we specify them separately. *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") lastarg="\"$lastarg\"" ;; esac base_compile="$base_compile $lastarg" done # for arg case $arg_mode in arg) $echo "$modename: you must specify an argument for -Xcompile" exit $EXIT_FAILURE ;; target) $echo "$modename: you must specify a target with \`-o'" 1>&2 exit $EXIT_FAILURE ;; *) # Get the name of the library object. [ -z "$libobj" ] && libobj=`$echo "X$srcfile" | $Xsed -e 's%^.*/%%'` ;; esac # Recognize several different file suffixes. # If the user specifies -o file.o, it is replaced with file.lo xform='[cCFSifmso]' case $libobj in *.ada) xform=ada ;; *.adb) xform=adb ;; *.ads) xform=ads ;; *.asm) xform=asm ;; *.c++) xform=c++ ;; *.cc) xform=cc ;; *.ii) xform=ii ;; *.class) xform=class ;; *.cpp) xform=cpp ;; *.cxx) xform=cxx ;; *.[fF][09]?) xform=[fF][09]. ;; *.for) xform=for ;; *.java) xform=java ;; *.obj) xform=obj ;; *.sx) xform=sx ;; esac libobj=`$echo "X$libobj" | $Xsed -e "s/\.$xform$/.lo/"` case $libobj in *.lo) obj=`$echo "X$libobj" | $Xsed -e "$lo2o"` ;; *) $echo "$modename: cannot determine name of library object from \`$libobj'" 1>&2 exit $EXIT_FAILURE ;; esac func_infer_tag $base_compile for arg in $later; do case $arg in -static) build_old_libs=yes continue ;; -prefer-pic) pic_mode=yes continue ;; -prefer-non-pic) pic_mode=no continue ;; esac done qlibobj=`$echo "X$libobj" | $Xsed -e "$sed_quote_subst"` case $qlibobj in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") qlibobj="\"$qlibobj\"" ;; esac test "X$libobj" != "X$qlibobj" \ && $echo "X$libobj" | grep '[]~#^*{};<>?"'"'"' &()|`$[]' \ && $echo "$modename: libobj name \`$libobj' may not contain shell special characters." objname=`$echo "X$obj" | $Xsed -e 's%^.*/%%'` xdir=`$echo "X$obj" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$obj"; then xdir= else xdir=$xdir/ fi lobj=${xdir}$objdir/$objname if test -z "$base_compile"; then $echo "$modename: you must specify a compilation command" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Delete any leftover library objects. if test "$build_old_libs" = yes; then removelist="$obj $lobj $libobj ${libobj}T" else removelist="$lobj $libobj ${libobj}T" fi $run $rm $removelist trap "$run $rm $removelist; exit $EXIT_FAILURE" 1 2 15 # On Cygwin there's no "real" PIC flag so we must build both object types case $host_os in cygwin* | mingw* | pw32* | os2*) pic_mode=default ;; esac if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then # non-PIC code in shared libraries is not supported pic_mode=default fi # Calculate the filename of the output object if compiler does # not support -o with -c if test "$compiler_c_o" = no; then output_obj=`$echo "X$srcfile" | $Xsed -e 's%^.*/%%' -e 's%\.[^.]*$%%'`.${objext} lockfile="$output_obj.lock" removelist="$removelist $output_obj $lockfile" trap "$run $rm $removelist; exit $EXIT_FAILURE" 1 2 15 else output_obj= need_locks=no lockfile= fi # Lock this critical section if it is needed # We use this script file to make the link, it avoids creating a new file if test "$need_locks" = yes; then until $run ln "$progpath" "$lockfile" 2>/dev/null; do $show "Waiting for $lockfile to be removed" sleep 2 done elif test "$need_locks" = warn; then if test -f "$lockfile"; then $echo "\ *** ERROR, $lockfile exists and contains: `cat $lockfile 2>/dev/null` This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $run $rm $removelist exit $EXIT_FAILURE fi $echo "$srcfile" > "$lockfile" fi if test -n "$fix_srcfile_path"; then eval srcfile=\"$fix_srcfile_path\" fi qsrcfile=`$echo "X$srcfile" | $Xsed -e "$sed_quote_subst"` case $qsrcfile in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") qsrcfile="\"$qsrcfile\"" ;; esac $run $rm "$libobj" "${libobj}T" # Create a libtool object file (analogous to a ".la" file), # but don't create it if we're doing a dry run. test -z "$run" && cat > ${libobj}T </dev/null`" != "X$srcfile"; then $echo "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $run $rm $removelist exit $EXIT_FAILURE fi # Just move the object if needed, then go on to compile the next one if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then $show "$mv $output_obj $lobj" if $run $mv $output_obj $lobj; then : else error=$? $run $rm $removelist exit $error fi fi # Append the name of the PIC object to the libtool object file. test -z "$run" && cat >> ${libobj}T <> ${libobj}T </dev/null`" != "X$srcfile"; then $echo "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $run $rm $removelist exit $EXIT_FAILURE fi # Just move the object if needed if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then $show "$mv $output_obj $obj" if $run $mv $output_obj $obj; then : else error=$? $run $rm $removelist exit $error fi fi # Append the name of the non-PIC object the libtool object file. # Only append if the libtool object file exists. test -z "$run" && cat >> ${libobj}T <> ${libobj}T <&2 fi if test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; -static) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=built ;; -static-libtool-libs) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; esac build_libtool_libs=no build_old_libs=yes break ;; esac done # See if our shared archives depend on static archives. test -n "$old_archive_from_new_cmds" && build_old_libs=yes # Go through the arguments, transforming them on the way. while test "$#" -gt 0; do arg="$1" shift case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") qarg=\"`$echo "X$arg" | $Xsed -e "$sed_quote_subst"`\" ### testsuite: skip nested quoting test ;; *) qarg=$arg ;; esac libtool_args="$libtool_args $qarg" # If the previous option needs an argument, assign it. if test -n "$prev"; then case $prev in output) compile_command="$compile_command @OUTPUT@" finalize_command="$finalize_command @OUTPUT@" ;; esac case $prev in dlfiles|dlprefiles) if test "$preload" = no; then # Add the symbol object into the linking commands. compile_command="$compile_command @SYMFILE@" finalize_command="$finalize_command @SYMFILE@" preload=yes fi case $arg in *.la | *.lo) ;; # We handle these cases below. force) if test "$dlself" = no; then dlself=needless export_dynamic=yes fi prev= continue ;; self) if test "$prev" = dlprefiles; then dlself=yes elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then dlself=yes else dlself=needless export_dynamic=yes fi prev= continue ;; *) if test "$prev" = dlfiles; then dlfiles="$dlfiles $arg" else dlprefiles="$dlprefiles $arg" fi prev= continue ;; esac ;; expsyms) export_symbols="$arg" if test ! -f "$arg"; then $echo "$modename: symbol file \`$arg' does not exist" exit $EXIT_FAILURE fi prev= continue ;; expsyms_regex) export_symbols_regex="$arg" prev= continue ;; inst_prefix) inst_prefix_dir="$arg" prev= continue ;; precious_regex) precious_files_regex="$arg" prev= continue ;; release) release="-$arg" prev= continue ;; objectlist) if test -f "$arg"; then save_arg=$arg moreargs= for fil in `cat $save_arg` do # moreargs="$moreargs $fil" arg=$fil # A libtool-controlled object. # Check to see that this really is a libtool object. if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then pic_object= non_pic_object= # Read the .lo file # If there is no directory component, then add one. case $arg in */* | *\\*) . $arg ;; *) . ./$arg ;; esac if test -z "$pic_object" || \ test -z "$non_pic_object" || test "$pic_object" = none && \ test "$non_pic_object" = none; then $echo "$modename: cannot find name of object for \`$arg'" 1>&2 exit $EXIT_FAILURE fi # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi if test "$pic_object" != none; then # Prepend the subdirectory the object is found in. pic_object="$xdir$pic_object" if test "$prev" = dlfiles; then if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then dlfiles="$dlfiles $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. dlprefiles="$dlprefiles $pic_object" prev= fi # A PIC object. libobjs="$libobjs $pic_object" arg="$pic_object" fi # Non-PIC object. if test "$non_pic_object" != none; then # Prepend the subdirectory the object is found in. non_pic_object="$xdir$non_pic_object" # A standard non-PIC object non_pic_objects="$non_pic_objects $non_pic_object" if test -z "$pic_object" || test "$pic_object" = none ; then arg="$non_pic_object" fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object="$pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi else # Only an error if not doing a dry-run. if test -z "$run"; then $echo "$modename: \`$arg' is not a valid libtool object" 1>&2 exit $EXIT_FAILURE else # Dry-run case. # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi pic_object=`$echo "X${xdir}${objdir}/${arg}" | $Xsed -e "$lo2o"` non_pic_object=`$echo "X${xdir}${arg}" | $Xsed -e "$lo2o"` libobjs="$libobjs $pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi fi done else $echo "$modename: link input file \`$save_arg' does not exist" exit $EXIT_FAILURE fi arg=$save_arg prev= continue ;; rpath | xrpath) # We need an absolute path. case $arg in [\\/]* | [A-Za-z]:[\\/]*) ;; *) $echo "$modename: only absolute run-paths are allowed" 1>&2 exit $EXIT_FAILURE ;; esac if test "$prev" = rpath; then case "$rpath " in *" $arg "*) ;; *) rpath="$rpath $arg" ;; esac else case "$xrpath " in *" $arg "*) ;; *) xrpath="$xrpath $arg" ;; esac fi prev= continue ;; xcompiler) compiler_flags="$compiler_flags $qarg" prev= compile_command="$compile_command $qarg" finalize_command="$finalize_command $qarg" continue ;; xlinker) linker_flags="$linker_flags $qarg" compiler_flags="$compiler_flags $wl$qarg" prev= compile_command="$compile_command $wl$qarg" finalize_command="$finalize_command $wl$qarg" continue ;; xcclinker) linker_flags="$linker_flags $qarg" compiler_flags="$compiler_flags $qarg" prev= compile_command="$compile_command $qarg" finalize_command="$finalize_command $qarg" continue ;; shrext) shrext_cmds="$arg" prev= continue ;; darwin_framework|darwin_framework_skip) test "$prev" = "darwin_framework" && compiler_flags="$compiler_flags $arg" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" prev= continue ;; *) eval "$prev=\"\$arg\"" prev= continue ;; esac fi # test -n "$prev" prevarg="$arg" case $arg in -all-static) if test -n "$link_static_flag"; then compile_command="$compile_command $link_static_flag" finalize_command="$finalize_command $link_static_flag" fi continue ;; -allow-undefined) # FIXME: remove this flag sometime in the future. $echo "$modename: \`-allow-undefined' is deprecated because it is the default" 1>&2 continue ;; -avoid-version) avoid_version=yes continue ;; -dlopen) prev=dlfiles continue ;; -dlpreopen) prev=dlprefiles continue ;; -export-dynamic) export_dynamic=yes continue ;; -export-symbols | -export-symbols-regex) if test -n "$export_symbols" || test -n "$export_symbols_regex"; then $echo "$modename: more than one -exported-symbols argument is not allowed" exit $EXIT_FAILURE fi if test "X$arg" = "X-export-symbols"; then prev=expsyms else prev=expsyms_regex fi continue ;; -framework|-arch|-isysroot) case " $CC " in *" ${arg} ${1} "* | *" ${arg} ${1} "*) prev=darwin_framework_skip ;; *) compiler_flags="$compiler_flags $arg" prev=darwin_framework ;; esac compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" continue ;; -inst-prefix-dir) prev=inst_prefix continue ;; # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* # so, if we see these flags be careful not to treat them like -L -L[A-Z][A-Z]*:*) case $with_gcc/$host in no/*-*-irix* | /*-*-irix*) compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" ;; esac continue ;; -L*) dir=`$echo "X$arg" | $Xsed -e 's/^-L//'` # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) absdir=`cd "$dir" && pwd` if test -z "$absdir"; then $echo "$modename: cannot determine absolute directory name of \`$dir'" 1>&2 absdir="$dir" notinst_path="$notinst_path $dir" fi dir="$absdir" ;; esac case "$deplibs " in *" -L$dir "*) ;; *) deplibs="$deplibs -L$dir" lib_search_path="$lib_search_path $dir" ;; esac case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) testbindir=`$echo "X$dir" | $Xsed -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$dir:"*) ;; *) dllsearchpath="$dllsearchpath:$dir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; *) dllsearchpath="$dllsearchpath:$testbindir";; esac ;; esac continue ;; -l*) if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos*) # These systems don't actually have a C or math library (as such) continue ;; *-*-os2*) # These systems don't actually have a C library (as such) test "X$arg" = "X-lc" && continue ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc due to us having libc/libc_r. test "X$arg" = "X-lc" && continue ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C and math libraries are in the System framework deplibs="$deplibs -framework System" continue ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype test "X$arg" = "X-lc" && continue ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work test "X$arg" = "X-lc" && continue ;; esac elif test "X$arg" = "X-lc_r"; then case $host in *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc_r directly, use -pthread flag. continue ;; esac fi deplibs="$deplibs $arg" continue ;; # Tru64 UNIX uses -model [arg] to determine the layout of C++ # classes, name mangling, and exception handling. -model) compile_command="$compile_command $arg" compiler_flags="$compiler_flags $arg" finalize_command="$finalize_command $arg" prev=xcompiler continue ;; -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) compiler_flags="$compiler_flags $arg" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" continue ;; -multi_module) single_module="${wl}-multi_module" continue ;; -module) module=yes continue ;; # -64, -mips[0-9] enable 64-bit mode on the SGI compiler # -r[0-9][0-9]* specifies the processor on the SGI compiler # -xarch=*, -xtarget=* enable 64-bit mode on the Sun compiler # +DA*, +DD* enable 64-bit mode on the HP compiler # -q* pass through compiler args for the IBM compiler # -m* pass through architecture-specific compiler args for GCC # -m*, -t[45]*, -txscale* pass through architecture-specific # compiler args for GCC # -p, -pg, --coverage, -fprofile-* pass through profiling flag for GCC # -F/path gives path to uninstalled frameworks, gcc on darwin # @file GCC response files -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" compiler_flags="$compiler_flags $arg" continue ;; -shrext) prev=shrext continue ;; -no-fast-install) fast_install=no continue ;; -no-install) case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin*) # The PATH hackery in wrapper scripts is required on Windows # and Darwin in order for the loader to find any dlls it needs. $echo "$modename: warning: \`-no-install' is ignored for $host" 1>&2 $echo "$modename: warning: assuming \`-no-fast-install' instead" 1>&2 fast_install=no ;; *) no_install=yes ;; esac continue ;; -no-undefined) allow_undefined=no continue ;; -objectlist) prev=objectlist continue ;; -o) prev=output ;; -precious-files-regex) prev=precious_regex continue ;; -release) prev=release continue ;; -rpath) prev=rpath continue ;; -R) prev=xrpath continue ;; -R*) dir=`$echo "X$arg" | $Xsed -e 's/^-R//'` # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) $echo "$modename: only absolute run-paths are allowed" 1>&2 exit $EXIT_FAILURE ;; esac case "$xrpath " in *" $dir "*) ;; *) xrpath="$xrpath $dir" ;; esac continue ;; -static | -static-libtool-libs) # The effects of -static are defined in a previous loop. # We used to do the same as -all-static on platforms that # didn't have a PIC flag, but the assumption that the effects # would be equivalent was wrong. It would break on at least # Digital Unix and AIX. continue ;; -thread-safe) thread_safe=yes continue ;; -version-info) prev=vinfo continue ;; -version-number) prev=vinfo vinfo_number=yes continue ;; -Wc,*) args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wc,//'` arg= save_ifs="$IFS"; IFS=',' for flag in $args; do IFS="$save_ifs" case $flag in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") flag="\"$flag\"" ;; esac arg="$arg $wl$flag" compiler_flags="$compiler_flags $flag" done IFS="$save_ifs" arg=`$echo "X$arg" | $Xsed -e "s/^ //"` ;; -Wl,*) args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wl,//'` arg= save_ifs="$IFS"; IFS=',' for flag in $args; do IFS="$save_ifs" case $flag in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") flag="\"$flag\"" ;; esac arg="$arg $wl$flag" compiler_flags="$compiler_flags $wl$flag" linker_flags="$linker_flags $flag" done IFS="$save_ifs" arg=`$echo "X$arg" | $Xsed -e "s/^ //"` ;; -Xcompiler) prev=xcompiler continue ;; -Xlinker) prev=xlinker continue ;; -XCClinker) prev=xcclinker continue ;; # Some other compiler flag. -* | +*) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac ;; *.$objext) # A standard object. objs="$objs $arg" ;; *.lo) # A libtool-controlled object. # Check to see that this really is a libtool object. if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then pic_object= non_pic_object= # Read the .lo file # If there is no directory component, then add one. case $arg in */* | *\\*) . $arg ;; *) . ./$arg ;; esac if test -z "$pic_object" || \ test -z "$non_pic_object" || test "$pic_object" = none && \ test "$non_pic_object" = none; then $echo "$modename: cannot find name of object for \`$arg'" 1>&2 exit $EXIT_FAILURE fi # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi if test "$pic_object" != none; then # Prepend the subdirectory the object is found in. pic_object="$xdir$pic_object" if test "$prev" = dlfiles; then if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then dlfiles="$dlfiles $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. dlprefiles="$dlprefiles $pic_object" prev= fi # A PIC object. libobjs="$libobjs $pic_object" arg="$pic_object" fi # Non-PIC object. if test "$non_pic_object" != none; then # Prepend the subdirectory the object is found in. non_pic_object="$xdir$non_pic_object" # A standard non-PIC object non_pic_objects="$non_pic_objects $non_pic_object" if test -z "$pic_object" || test "$pic_object" = none ; then arg="$non_pic_object" fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object="$pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi else # Only an error if not doing a dry-run. if test -z "$run"; then $echo "$modename: \`$arg' is not a valid libtool object" 1>&2 exit $EXIT_FAILURE else # Dry-run case. # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi pic_object=`$echo "X${xdir}${objdir}/${arg}" | $Xsed -e "$lo2o"` non_pic_object=`$echo "X${xdir}${arg}" | $Xsed -e "$lo2o"` libobjs="$libobjs $pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi fi ;; *.$libext) # An archive. deplibs="$deplibs $arg" old_deplibs="$old_deplibs $arg" continue ;; *.la) # A libtool-controlled library. if test "$prev" = dlfiles; then # This library was specified with -dlopen. dlfiles="$dlfiles $arg" prev= elif test "$prev" = dlprefiles; then # The library was specified with -dlpreopen. dlprefiles="$dlprefiles $arg" prev= else deplibs="$deplibs $arg" fi continue ;; # Some other compiler argument. *) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac ;; esac # arg # Now actually substitute the argument into the commands. if test -n "$arg"; then compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" fi done # argument parsing loop if test -n "$prev"; then $echo "$modename: the \`$prevarg' option requires an argument" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then eval arg=\"$export_dynamic_flag_spec\" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" fi oldlibs= # calculate the name of the file, without its directory outputname=`$echo "X$output" | $Xsed -e 's%^.*/%%'` libobjs_save="$libobjs" if test -n "$shlibpath_var"; then # get the directories listed in $shlibpath_var eval shlib_search_path=\`\$echo \"X\${$shlibpath_var}\" \| \$Xsed -e \'s/:/ /g\'\` else shlib_search_path= fi eval sys_lib_search_path=\"$sys_lib_search_path_spec\" eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" output_objdir=`$echo "X$output" | $Xsed -e 's%/[^/]*$%%'` if test "X$output_objdir" = "X$output"; then output_objdir="$objdir" else output_objdir="$output_objdir/$objdir" fi # Create the object directory. if test ! -d "$output_objdir"; then $show "$mkdir $output_objdir" $run $mkdir $output_objdir exit_status=$? if test "$exit_status" -ne 0 && test ! -d "$output_objdir"; then exit $exit_status fi fi # Determine the type of output case $output in "") $echo "$modename: you must specify an output file" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; *.$libext) linkmode=oldlib ;; *.lo | *.$objext) linkmode=obj ;; *.la) linkmode=lib ;; *) linkmode=prog ;; # Anything else should be a program. esac case $host in *cygwin* | *mingw* | *pw32*) # don't eliminate duplications in $postdeps and $predeps duplicate_compiler_generated_deps=yes ;; *) duplicate_compiler_generated_deps=$duplicate_deps ;; esac specialdeplibs= libs= # Find all interdependent deplibs by searching for libraries # that are linked more than once (e.g. -la -lb -la) for deplib in $deplibs; do if test "X$duplicate_deps" = "Xyes" ; then case "$libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi libs="$libs $deplib" done if test "$linkmode" = lib; then libs="$predeps $libs $compiler_lib_search_path $postdeps" # Compute libraries that are listed more than once in $predeps # $postdeps and mark them as special (i.e., whose duplicates are # not to be eliminated). pre_post_deps= if test "X$duplicate_compiler_generated_deps" = "Xyes" ; then for pre_post_dep in $predeps $postdeps; do case "$pre_post_deps " in *" $pre_post_dep "*) specialdeplibs="$specialdeplibs $pre_post_deps" ;; esac pre_post_deps="$pre_post_deps $pre_post_dep" done fi pre_post_deps= fi deplibs= newdependency_libs= newlib_search_path= need_relink=no # whether we're linking any uninstalled libtool libraries notinst_deplibs= # not-installed libtool libraries case $linkmode in lib) passes="conv link" for file in $dlfiles $dlprefiles; do case $file in *.la) ;; *) $echo "$modename: libraries can \`-dlopen' only libtool libraries: $file" 1>&2 exit $EXIT_FAILURE ;; esac done ;; prog) compile_deplibs= finalize_deplibs= alldeplibs=no newdlfiles= newdlprefiles= passes="conv scan dlopen dlpreopen link" ;; *) passes="conv" ;; esac for pass in $passes; do if test "$linkmode,$pass" = "lib,link" || test "$linkmode,$pass" = "prog,scan"; then libs="$deplibs" deplibs= fi if test "$linkmode" = prog; then case $pass in dlopen) libs="$dlfiles" ;; dlpreopen) libs="$dlprefiles" ;; link) libs="$deplibs %DEPLIBS%" test "X$link_all_deplibs" != Xno && libs="$libs $dependency_libs" ;; esac fi if test "$pass" = dlopen; then # Collect dlpreopened libraries save_deplibs="$deplibs" deplibs= fi for deplib in $libs; do lib= found=no case $deplib in -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) if test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else compiler_flags="$compiler_flags $deplib" fi continue ;; -l*) if test "$linkmode" != lib && test "$linkmode" != prog; then $echo "$modename: warning: \`-l' is ignored for archives/objects" 1>&2 continue fi name=`$echo "X$deplib" | $Xsed -e 's/^-l//'` if test "$linkmode" = lib; then searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" else searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" fi for searchdir in $searchdirs; do for search_ext in .la $std_shrext .so .a; do # Search the libtool library lib="$searchdir/lib${name}${search_ext}" if test -f "$lib"; then if test "$search_ext" = ".la"; then found=yes else found=no fi break 2 fi done done if test "$found" != yes; then # deplib doesn't seem to be a libtool library if test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" fi continue else # deplib is a libtool library # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, # We need to do some special things here, and not later. if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then case " $predeps $postdeps " in *" $deplib "*) if (${SED} -e '2q' $lib | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then library_names= old_library= case $lib in */* | *\\*) . $lib ;; *) . ./$lib ;; esac for l in $old_library $library_names; do ll="$l" done if test "X$ll" = "X$old_library" ; then # only static version available found=no ladir=`$echo "X$lib" | $Xsed -e 's%/[^/]*$%%'` test "X$ladir" = "X$lib" && ladir="." lib=$ladir/$old_library if test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" fi continue fi fi ;; *) ;; esac fi fi ;; # -l -L*) case $linkmode in lib) deplibs="$deplib $deplibs" test "$pass" = conv && continue newdependency_libs="$deplib $newdependency_libs" newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` ;; prog) if test "$pass" = conv; then deplibs="$deplib $deplibs" continue fi if test "$pass" = scan; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` ;; *) $echo "$modename: warning: \`-L' is ignored for archives/objects" 1>&2 ;; esac # linkmode continue ;; # -L -R*) if test "$pass" = link; then dir=`$echo "X$deplib" | $Xsed -e 's/^-R//'` # Make sure the xrpath contains only unique directories. case "$xrpath " in *" $dir "*) ;; *) xrpath="$xrpath $dir" ;; esac fi deplibs="$deplib $deplibs" continue ;; *.la) lib="$deplib" ;; *.$libext) if test "$pass" = conv; then deplibs="$deplib $deplibs" continue fi case $linkmode in lib) valid_a_lib=no case $deplibs_check_method in match_pattern*) set dummy $deplibs_check_method match_pattern_regex=`expr "$deplibs_check_method" : "$2 \(.*\)"` if eval $echo \"$deplib\" 2>/dev/null \ | $SED 10q \ | $EGREP "$match_pattern_regex" > /dev/null; then valid_a_lib=yes fi ;; pass_all) valid_a_lib=yes ;; esac if test "$valid_a_lib" != yes; then $echo $echo "*** Warning: Trying to link with static lib archive $deplib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have" $echo "*** because the file extensions .$libext of this argument makes me believe" $echo "*** that it is just a static archive that I should not used here." else $echo $echo "*** Warning: Linking the shared library $output against the" $echo "*** static library $deplib is not portable!" deplibs="$deplib $deplibs" fi continue ;; prog) if test "$pass" != link; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi continue ;; esac # linkmode ;; # *.$libext *.lo | *.$objext) if test "$pass" = conv; then deplibs="$deplib $deplibs" elif test "$linkmode" = prog; then if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then # If there is no dlopen support or we're linking statically, # we need to preload. newdlprefiles="$newdlprefiles $deplib" compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else newdlfiles="$newdlfiles $deplib" fi fi continue ;; %DEPLIBS%) alldeplibs=yes continue ;; esac # case $deplib if test "$found" = yes || test -f "$lib"; then : else $echo "$modename: cannot find the library \`$lib' or unhandled argument \`$deplib'" 1>&2 exit $EXIT_FAILURE fi # Check to see that this really is a libtool archive. if (${SED} -e '2q' $lib | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : else $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi ladir=`$echo "X$lib" | $Xsed -e 's%/[^/]*$%%'` test "X$ladir" = "X$lib" && ladir="." dlname= dlopen= dlpreopen= libdir= library_names= old_library= # If the library was installed with an old release of libtool, # it will not redefine variables installed, or shouldnotlink installed=yes shouldnotlink=no avoidtemprpath= # Read the .la file case $lib in */* | *\\*) . $lib ;; *) . ./$lib ;; esac if test "$linkmode,$pass" = "lib,link" || test "$linkmode,$pass" = "prog,scan" || { test "$linkmode" != prog && test "$linkmode" != lib; }; then test -n "$dlopen" && dlfiles="$dlfiles $dlopen" test -n "$dlpreopen" && dlprefiles="$dlprefiles $dlpreopen" fi if test "$pass" = conv; then # Only check for convenience libraries deplibs="$lib $deplibs" if test -z "$libdir"; then if test -z "$old_library"; then $echo "$modename: cannot find name of link library for \`$lib'" 1>&2 exit $EXIT_FAILURE fi # It is a libtool convenience library, so add in its objects. convenience="$convenience $ladir/$objdir/$old_library" old_convenience="$old_convenience $ladir/$objdir/$old_library" tmp_libs= for deplib in $dependency_libs; do deplibs="$deplib $deplibs" if test "X$duplicate_deps" = "Xyes" ; then case "$tmp_libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi tmp_libs="$tmp_libs $deplib" done elif test "$linkmode" != prog && test "$linkmode" != lib; then $echo "$modename: \`$lib' is not a convenience library" 1>&2 exit $EXIT_FAILURE fi continue fi # $pass = conv # Get the name of the library we link against. linklib= for l in $old_library $library_names; do linklib="$l" done if test -z "$linklib"; then $echo "$modename: cannot find name of link library for \`$lib'" 1>&2 exit $EXIT_FAILURE fi # This library was specified with -dlopen. if test "$pass" = dlopen; then if test -z "$libdir"; then $echo "$modename: cannot -dlopen a convenience library: \`$lib'" 1>&2 exit $EXIT_FAILURE fi if test -z "$dlname" || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then # If there is no dlname, no dlopen support or we're linking # statically, we need to preload. We also need to preload any # dependent libraries so libltdl's deplib preloader doesn't # bomb out in the load deplibs phase. dlprefiles="$dlprefiles $lib $dependency_libs" else newdlfiles="$newdlfiles $lib" fi continue fi # $pass = dlopen # We need an absolute path. case $ladir in [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; *) abs_ladir=`cd "$ladir" && pwd` if test -z "$abs_ladir"; then $echo "$modename: warning: cannot determine absolute directory name of \`$ladir'" 1>&2 $echo "$modename: passing it literally to the linker, although it might fail" 1>&2 abs_ladir="$ladir" fi ;; esac laname=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` # Find the relevant object directory and library name. if test "X$installed" = Xyes; then if test ! -f "$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then $echo "$modename: warning: library \`$lib' was moved." 1>&2 dir="$ladir" absdir="$abs_ladir" libdir="$abs_ladir" else dir="$libdir" absdir="$libdir" fi test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes else if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then dir="$ladir" absdir="$abs_ladir" # Remove this search path later notinst_path="$notinst_path $abs_ladir" else dir="$ladir/$objdir" absdir="$abs_ladir/$objdir" # Remove this search path later notinst_path="$notinst_path $abs_ladir" fi fi # $installed = yes name=`$echo "X$laname" | $Xsed -e 's/\.la$//' -e 's/^lib//'` # This library was specified with -dlpreopen. if test "$pass" = dlpreopen; then if test -z "$libdir"; then $echo "$modename: cannot -dlpreopen a convenience library: \`$lib'" 1>&2 exit $EXIT_FAILURE fi # Prefer using a static library (so that no silly _DYNAMIC symbols # are required to link). if test -n "$old_library"; then newdlprefiles="$newdlprefiles $dir/$old_library" # Otherwise, use the dlname, so that lt_dlopen finds it. elif test -n "$dlname"; then newdlprefiles="$newdlprefiles $dir/$dlname" else newdlprefiles="$newdlprefiles $dir/$linklib" fi fi # $pass = dlpreopen if test -z "$libdir"; then # Link the convenience library if test "$linkmode" = lib; then deplibs="$dir/$old_library $deplibs" elif test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$dir/$old_library $compile_deplibs" finalize_deplibs="$dir/$old_library $finalize_deplibs" else deplibs="$lib $deplibs" # used for prog,scan pass fi continue fi if test "$linkmode" = prog && test "$pass" != link; then newlib_search_path="$newlib_search_path $ladir" deplibs="$lib $deplibs" linkalldeplibs=no if test "$link_all_deplibs" != no || test -z "$library_names" || test "$build_libtool_libs" = no; then linkalldeplibs=yes fi tmp_libs= for deplib in $dependency_libs; do case $deplib in -L*) newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'`;; ### testsuite: skip nested quoting test esac # Need to link against all dependency_libs? if test "$linkalldeplibs" = yes; then deplibs="$deplib $deplibs" else # Need to hardcode shared library paths # or/and link against static libraries newdependency_libs="$deplib $newdependency_libs" fi if test "X$duplicate_deps" = "Xyes" ; then case "$tmp_libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi tmp_libs="$tmp_libs $deplib" done # for deplib continue fi # $linkmode = prog... if test "$linkmode,$pass" = "prog,link"; then if test -n "$library_names" && { { test "$prefer_static_libs" = no || test "$prefer_static_libs,$installed" = "built,yes"; } || test -z "$old_library"; }; then # We need to hardcode the library path if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then # Make sure the rpath contains only unique directories. case "$temp_rpath " in *" $dir "*) ;; *" $absdir "*) ;; *) temp_rpath="$temp_rpath $absdir" ;; esac fi # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) compile_rpath="$compile_rpath $absdir" esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" esac ;; esac fi # $linkmode,$pass = prog,link... if test "$alldeplibs" = yes && { test "$deplibs_check_method" = pass_all || { test "$build_libtool_libs" = yes && test -n "$library_names"; }; }; then # We only need to search for static libraries continue fi fi link_static=no # Whether the deplib will be linked statically use_static_libs=$prefer_static_libs if test "$use_static_libs" = built && test "$installed" = yes ; then use_static_libs=no fi if test -n "$library_names" && { test "$use_static_libs" = no || test -z "$old_library"; }; then if test "$installed" = no; then notinst_deplibs="$notinst_deplibs $lib" need_relink=yes fi # This is a shared library # Warn about portability, can't link against -module's on # some systems (darwin) if test "$shouldnotlink" = yes && test "$pass" = link ; then $echo if test "$linkmode" = prog; then $echo "*** Warning: Linking the executable $output against the loadable module" else $echo "*** Warning: Linking the shared library $output against the loadable module" fi $echo "*** $linklib is not portable!" fi if test "$linkmode" = lib && test "$hardcode_into_libs" = yes; then # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) compile_rpath="$compile_rpath $absdir" esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" esac ;; esac fi if test -n "$old_archive_from_expsyms_cmds"; then # figure out the soname set dummy $library_names realname="$2" shift; shift libname=`eval \\$echo \"$libname_spec\"` # use dlname if we got it. it's perfectly good, no? if test -n "$dlname"; then soname="$dlname" elif test -n "$soname_spec"; then # bleh windows case $host in *cygwin* | mingw*) major=`expr $current - $age` versuffix="-$major" ;; esac eval soname=\"$soname_spec\" else soname="$realname" fi # Make a new name for the extract_expsyms_cmds to use soroot="$soname" soname=`$echo $soroot | ${SED} -e 's/^.*\///'` newlib="libimp-`$echo $soname | ${SED} 's/^lib//;s/\.dll$//'`.a" # If the library has no export list, then create one now if test -f "$output_objdir/$soname-def"; then : else $show "extracting exported symbol list from \`$soname'" save_ifs="$IFS"; IFS='~' cmds=$extract_expsyms_cmds for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" fi # Create $newlib if test -f "$output_objdir/$newlib"; then :; else $show "generating import library for \`$soname'" save_ifs="$IFS"; IFS='~' cmds=$old_archive_from_expsyms_cmds for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" fi # make sure the library variables are pointing to the new library dir=$output_objdir linklib=$newlib fi # test -n "$old_archive_from_expsyms_cmds" if test "$linkmode" = prog || test "$mode" != relink; then add_shlibpath= add_dir= add= lib_linked=yes case $hardcode_action in immediate | unsupported) if test "$hardcode_direct" = no; then add="$dir/$linklib" case $host in *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; *-*-sysv4*uw2*) add_dir="-L$dir" ;; *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ *-*-unixware7*) add_dir="-L$dir" ;; *-*-darwin* ) # if the lib is a module then we can not link against # it, someone is ignoring the new warnings I added if /usr/bin/file -L $add 2> /dev/null | $EGREP ": [^:]* bundle" >/dev/null ; then $echo "** Warning, lib $linklib is a module, not a shared library" if test -z "$old_library" ; then $echo $echo "** And there doesn't seem to be a static archive available" $echo "** The link will probably fail, sorry" else add="$dir/$old_library" fi fi esac elif test "$hardcode_minus_L" = no; then case $host in *-*-sunos*) add_shlibpath="$dir" ;; esac add_dir="-L$dir" add="-l$name" elif test "$hardcode_shlibpath_var" = no; then add_shlibpath="$dir" add="-l$name" else lib_linked=no fi ;; relink) if test "$hardcode_direct" = yes; then add="$dir/$linklib" elif test "$hardcode_minus_L" = yes; then add_dir="-L$dir" # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) add_dir="$add_dir -L$inst_prefix_dir$libdir" ;; esac fi add="-l$name" elif test "$hardcode_shlibpath_var" = yes; then add_shlibpath="$dir" add="-l$name" else lib_linked=no fi ;; *) lib_linked=no ;; esac if test "$lib_linked" != yes; then $echo "$modename: configuration error: unsupported hardcode properties" exit $EXIT_FAILURE fi if test -n "$add_shlibpath"; then case :$compile_shlibpath: in *":$add_shlibpath:"*) ;; *) compile_shlibpath="$compile_shlibpath$add_shlibpath:" ;; esac fi if test "$linkmode" = prog; then test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" test -n "$add" && compile_deplibs="$add $compile_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" if test "$hardcode_direct" != yes && \ test "$hardcode_minus_L" != yes && \ test "$hardcode_shlibpath_var" = yes; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; esac fi fi fi if test "$linkmode" = prog || test "$mode" = relink; then add_shlibpath= add_dir= add= # Finalize command for both is simple: just hardcode it. if test "$hardcode_direct" = yes; then add="$libdir/$linklib" elif test "$hardcode_minus_L" = yes; then add_dir="-L$libdir" add="-l$name" elif test "$hardcode_shlibpath_var" = yes; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; esac add="-l$name" elif test "$hardcode_automatic" = yes; then if test -n "$inst_prefix_dir" && test -f "$inst_prefix_dir$libdir/$linklib" ; then add="$inst_prefix_dir$libdir/$linklib" else add="$libdir/$linklib" fi else # We cannot seem to hardcode it, guess we'll fake it. add_dir="-L$libdir" # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) add_dir="$add_dir -L$inst_prefix_dir$libdir" ;; esac fi add="-l$name" fi if test "$linkmode" = prog; then test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" test -n "$add" && finalize_deplibs="$add $finalize_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" fi fi elif test "$linkmode" = prog; then # Here we assume that one of hardcode_direct or hardcode_minus_L # is not unsupported. This is valid on all known static and # shared platforms. if test "$hardcode_direct" != unsupported; then test -n "$old_library" && linklib="$old_library" compile_deplibs="$dir/$linklib $compile_deplibs" finalize_deplibs="$dir/$linklib $finalize_deplibs" else compile_deplibs="-l$name -L$dir $compile_deplibs" finalize_deplibs="-l$name -L$dir $finalize_deplibs" fi elif test "$build_libtool_libs" = yes; then # Not a shared library if test "$deplibs_check_method" != pass_all; then # We're trying link a shared library against a static one # but the system doesn't support it. # Just print a warning and add the library to dependency_libs so # that the program can be linked against the static library. $echo $echo "*** Warning: This system can not link to static lib archive $lib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have." if test "$module" = yes; then $echo "*** But as you try to build a module library, libtool will still create " $echo "*** a static module, that should work as long as the dlopening application" $echo "*** is linked with the -dlopen flag to resolve symbols at runtime." if test -z "$global_symbol_pipe"; then $echo $echo "*** However, this would only work if libtool was able to extract symbol" $echo "*** lists from a program, using \`nm' or equivalent, but libtool could" $echo "*** not find such a program. So, this module is probably useless." $echo "*** \`nm' from GNU binutils and a full rebuild may help." fi if test "$build_old_libs" = no; then build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi else deplibs="$dir/$old_library $deplibs" link_static=yes fi fi # link shared/static library? if test "$linkmode" = lib; then if test -n "$dependency_libs" && { test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes || test "$link_static" = yes; }; then # Extract -R from dependency_libs temp_deplibs= for libdir in $dependency_libs; do case $libdir in -R*) temp_xrpath=`$echo "X$libdir" | $Xsed -e 's/^-R//'` case " $xrpath " in *" $temp_xrpath "*) ;; *) xrpath="$xrpath $temp_xrpath";; esac;; *) temp_deplibs="$temp_deplibs $libdir";; esac done dependency_libs="$temp_deplibs" fi newlib_search_path="$newlib_search_path $absdir" # Link against this library test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" # ... and its dependency_libs tmp_libs= for deplib in $dependency_libs; do newdependency_libs="$deplib $newdependency_libs" if test "X$duplicate_deps" = "Xyes" ; then case "$tmp_libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi tmp_libs="$tmp_libs $deplib" done if test "$link_all_deplibs" != no; then # Add the search paths of all dependency libraries for deplib in $dependency_libs; do case $deplib in -L*) path="$deplib" ;; *.la) dir=`$echo "X$deplib" | $Xsed -e 's%/[^/]*$%%'` test "X$dir" = "X$deplib" && dir="." # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; *) absdir=`cd "$dir" && pwd` if test -z "$absdir"; then $echo "$modename: warning: cannot determine absolute directory name of \`$dir'" 1>&2 absdir="$dir" fi ;; esac if grep "^installed=no" $deplib > /dev/null; then path="$absdir/$objdir" else eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` if test -z "$libdir"; then $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi if test "$absdir" != "$libdir"; then $echo "$modename: warning: \`$deplib' seems to be moved" 1>&2 fi path="$absdir" fi depdepl= case $host in *-*-darwin*) # we do not want to link against static libs, # but need to link against shared eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` eval deplibdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` if test -n "$deplibrary_names" ; then for tmp in $deplibrary_names ; do depdepl=$tmp done if test -f "$deplibdir/$depdepl" ; then depdepl="$deplibdir/$depdepl" elif test -f "$path/$depdepl" ; then depdepl="$path/$depdepl" else # Can't find it, oh well... depdepl= fi # do not add paths which are already there case " $newlib_search_path " in *" $path "*) ;; *) newlib_search_path="$newlib_search_path $path";; esac fi path="" ;; *) path="-L$path" ;; esac ;; -l*) case $host in *-*-darwin*) # Again, we only want to link against shared libraries eval tmp_libs=`$echo "X$deplib" | $Xsed -e "s,^\-l,,"` for tmp in $newlib_search_path ; do if test -f "$tmp/lib$tmp_libs.dylib" ; then eval depdepl="$tmp/lib$tmp_libs.dylib" break fi done path="" ;; *) continue ;; esac ;; *) continue ;; esac case " $deplibs " in *" $path "*) ;; *) deplibs="$path $deplibs" ;; esac case " $deplibs " in *" $depdepl "*) ;; *) deplibs="$depdepl $deplibs" ;; esac done fi # link_all_deplibs != no fi # linkmode = lib done # for deplib in $libs dependency_libs="$newdependency_libs" if test "$pass" = dlpreopen; then # Link the dlpreopened libraries before other libraries for deplib in $save_deplibs; do deplibs="$deplib $deplibs" done fi if test "$pass" != dlopen; then if test "$pass" != conv; then # Make sure lib_search_path contains only unique directories. lib_search_path= for dir in $newlib_search_path; do case "$lib_search_path " in *" $dir "*) ;; *) lib_search_path="$lib_search_path $dir" ;; esac done newlib_search_path= fi if test "$linkmode,$pass" != "prog,link"; then vars="deplibs" else vars="compile_deplibs finalize_deplibs" fi for var in $vars dependency_libs; do # Add libraries to $var in reverse order eval tmp_libs=\"\$$var\" new_libs= for deplib in $tmp_libs; do # FIXME: Pedantically, this is the right thing to do, so # that some nasty dependency loop isn't accidentally # broken: #new_libs="$deplib $new_libs" # Pragmatically, this seems to cause very few problems in # practice: case $deplib in -L*) new_libs="$deplib $new_libs" ;; -R*) ;; *) # And here is the reason: when a library appears more # than once as an explicit dependence of a library, or # is implicitly linked in more than once by the # compiler, it is considered special, and multiple # occurrences thereof are not removed. Compare this # with having the same library being listed as a # dependency of multiple other libraries: in this case, # we know (pedantically, we assume) the library does not # need to be listed more than once, so we keep only the # last copy. This is not always right, but it is rare # enough that we require users that really mean to play # such unportable linking tricks to link the library # using -Wl,-lname, so that libtool does not consider it # for duplicate removal. case " $specialdeplibs " in *" $deplib "*) new_libs="$deplib $new_libs" ;; *) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$deplib $new_libs" ;; esac ;; esac ;; esac done tmp_libs= for deplib in $new_libs; do case $deplib in -L*) case " $tmp_libs " in *" $deplib "*) ;; *) tmp_libs="$tmp_libs $deplib" ;; esac ;; *) tmp_libs="$tmp_libs $deplib" ;; esac done eval $var=\"$tmp_libs\" done # for var fi # Last step: remove runtime libs from dependency_libs # (they stay in deplibs) tmp_libs= for i in $dependency_libs ; do case " $predeps $postdeps $compiler_lib_search_path " in *" $i "*) i="" ;; esac if test -n "$i" ; then tmp_libs="$tmp_libs $i" fi done dependency_libs=$tmp_libs done # for pass if test "$linkmode" = prog; then dlfiles="$newdlfiles" dlprefiles="$newdlprefiles" fi case $linkmode in oldlib) case " $deplibs" in *\ -l* | *\ -L*) $echo "$modename: warning: \`-l' and \`-L' are ignored for archives" 1>&2 ;; esac if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then $echo "$modename: warning: \`-dlopen' is ignored for archives" 1>&2 fi if test -n "$rpath"; then $echo "$modename: warning: \`-rpath' is ignored for archives" 1>&2 fi if test -n "$xrpath"; then $echo "$modename: warning: \`-R' is ignored for archives" 1>&2 fi if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info/-version-number' is ignored for archives" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for archives" 1>&2 fi if test -n "$export_symbols" || test -n "$export_symbols_regex"; then $echo "$modename: warning: \`-export-symbols' is ignored for archives" 1>&2 fi # Now set the variables for building old libraries. build_libtool_libs=no oldlibs="$output" objs="$objs$old_deplibs" ;; lib) # Make sure we only generate libraries of the form `libNAME.la'. case $outputname in lib*) name=`$echo "X$outputname" | $Xsed -e 's/\.la$//' -e 's/^lib//'` eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" ;; *) if test "$module" = no; then $echo "$modename: libtool library \`$output' must begin with \`lib'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test "$need_lib_prefix" != no; then # Add the "lib" prefix for modules if required name=`$echo "X$outputname" | $Xsed -e 's/\.la$//'` eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" else libname=`$echo "X$outputname" | $Xsed -e 's/\.la$//'` fi ;; esac if test -n "$objs"; then if test "$deplibs_check_method" != pass_all; then $echo "$modename: cannot build libtool library \`$output' from non-libtool objects on this host:$objs" 2>&1 exit $EXIT_FAILURE else $echo $echo "*** Warning: Linking the shared library $output against the non-libtool" $echo "*** objects $objs is not portable!" libobjs="$libobjs $objs" fi fi if test "$dlself" != no; then $echo "$modename: warning: \`-dlopen self' is ignored for libtool libraries" 1>&2 fi set dummy $rpath if test "$#" -gt 2; then $echo "$modename: warning: ignoring multiple \`-rpath's for a libtool library" 1>&2 fi install_libdir="$2" oldlibs= if test -z "$rpath"; then if test "$build_libtool_libs" = yes; then # Building a libtool convenience library. # Some compilers have problems with a `.al' extension so # convenience libraries should have the same extension an # archive normally would. oldlibs="$output_objdir/$libname.$libext $oldlibs" build_libtool_libs=convenience build_old_libs=yes fi if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info/-version-number' is ignored for convenience libraries" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for convenience libraries" 1>&2 fi else # Parse the version information argument. save_ifs="$IFS"; IFS=':' set dummy $vinfo 0 0 0 IFS="$save_ifs" if test -n "$8"; then $echo "$modename: too many parameters to \`-version-info'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # convert absolute version numbers to libtool ages # this retains compatibility with .la files and attempts # to make the code below a bit more comprehensible case $vinfo_number in yes) number_major="$2" number_minor="$3" number_revision="$4" # # There are really only two kinds -- those that # use the current revision as the major version # and those that subtract age and use age as # a minor version. But, then there is irix # which has an extra 1 added just for fun # case $version_type in darwin|linux|osf|windows|none) current=`expr $number_major + $number_minor` age="$number_minor" revision="$number_revision" ;; freebsd-aout|freebsd-elf|sunos) current="$number_major" revision="$number_minor" age="0" ;; irix|nonstopux) current=`expr $number_major + $number_minor` age="$number_minor" revision="$number_minor" lt_irix_increment=no ;; *) $echo "$modename: unknown library version type \`$version_type'" 1>&2 $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 exit $EXIT_FAILURE ;; esac ;; no) current="$2" revision="$3" age="$4" ;; esac # Check that each of the things are valid numbers. case $current in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) $echo "$modename: CURRENT \`$current' must be a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; esac case $revision in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) $echo "$modename: REVISION \`$revision' must be a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; esac case $age in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) $echo "$modename: AGE \`$age' must be a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; esac if test "$age" -gt "$current"; then $echo "$modename: AGE \`$age' is greater than the current interface number \`$current'" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE fi # Calculate the version variables. major= versuffix= verstring= case $version_type in none) ;; darwin) # Like Linux, but with the current version available in # verstring for coding it into the library header major=.`expr $current - $age` versuffix="$major.$age.$revision" # Darwin ld doesn't like 0 for these options... minor_current=`expr $current + 1` xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision" verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" ;; freebsd-aout) major=".$current" versuffix=".$current.$revision"; ;; freebsd-elf) major=".$current" versuffix=".$current"; ;; irix | nonstopux) if test "X$lt_irix_increment" = "Xno"; then major=`expr $current - $age` else major=`expr $current - $age + 1` fi case $version_type in nonstopux) verstring_prefix=nonstopux ;; *) verstring_prefix=sgi ;; esac verstring="$verstring_prefix$major.$revision" # Add in all the interfaces that we are compatible with. loop=$revision while test "$loop" -ne 0; do iface=`expr $revision - $loop` loop=`expr $loop - 1` verstring="$verstring_prefix$major.$iface:$verstring" done # Before this point, $major must not contain `.'. major=.$major versuffix="$major.$revision" ;; linux) major=.`expr $current - $age` versuffix="$major.$age.$revision" ;; osf) major=.`expr $current - $age` versuffix=".$current.$age.$revision" verstring="$current.$age.$revision" # Add in all the interfaces that we are compatible with. loop=$age while test "$loop" -ne 0; do iface=`expr $current - $loop` loop=`expr $loop - 1` verstring="$verstring:${iface}.0" done # Make executables depend on our current version. verstring="$verstring:${current}.0" ;; sunos) major=".$current" versuffix=".$current.$revision" ;; windows) # Use '-' rather than '.', since we only want one # extension on DOS 8.3 filesystems. major=`expr $current - $age` versuffix="-$major" ;; *) $echo "$modename: unknown library version type \`$version_type'" 1>&2 $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 exit $EXIT_FAILURE ;; esac # Clear the version info if we defaulted, and they specified a release. if test -z "$vinfo" && test -n "$release"; then major= case $version_type in darwin) # we can't check for "0.0" in archive_cmds due to quoting # problems, so we reset it completely verstring= ;; *) verstring="0.0" ;; esac if test "$need_version" = no; then versuffix= else versuffix=".0.0" fi fi # Remove version info from name if versioning should be avoided if test "$avoid_version" = yes && test "$need_version" = no; then major= versuffix= verstring="" fi # Check to see if the archive will have undefined symbols. if test "$allow_undefined" = yes; then if test "$allow_undefined_flag" = unsupported; then $echo "$modename: warning: undefined symbols not allowed in $host shared libraries" 1>&2 build_libtool_libs=no build_old_libs=yes fi else # Don't allow undefined symbols. allow_undefined_flag="$no_undefined_flag" fi fi if test "$mode" != relink; then # Remove our outputs, but don't remove object files since they # may have been created when compiling PIC objects. removelist= tempremovelist=`$echo "$output_objdir/*"` for p in $tempremovelist; do case $p in *.$objext) ;; $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) if test "X$precious_files_regex" != "X"; then if echo $p | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 then continue fi fi removelist="$removelist $p" ;; *) ;; esac done if test -n "$removelist"; then $show "${rm}r $removelist" $run ${rm}r $removelist fi fi # Now set the variables for building old libraries. if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then oldlibs="$oldlibs $output_objdir/$libname.$libext" # Transform .lo files to .o files. oldobjs="$objs "`$echo "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}'$/d' -e "$lo2o" | $NL2SP` fi # Eliminate all temporary directories. #for path in $notinst_path; do # lib_search_path=`$echo "$lib_search_path " | ${SED} -e "s% $path % %g"` # deplibs=`$echo "$deplibs " | ${SED} -e "s% -L$path % %g"` # dependency_libs=`$echo "$dependency_libs " | ${SED} -e "s% -L$path % %g"` #done if test -n "$xrpath"; then # If the user specified any rpath flags, then add them. temp_xrpath= for libdir in $xrpath; do temp_xrpath="$temp_xrpath -R$libdir" case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" ;; esac done if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then dependency_libs="$temp_xrpath $dependency_libs" fi fi # Make sure dlfiles contains only unique files that won't be dlpreopened old_dlfiles="$dlfiles" dlfiles= for lib in $old_dlfiles; do case " $dlprefiles $dlfiles " in *" $lib "*) ;; *) dlfiles="$dlfiles $lib" ;; esac done # Make sure dlprefiles contains only unique files old_dlprefiles="$dlprefiles" dlprefiles= for lib in $old_dlprefiles; do case "$dlprefiles " in *" $lib "*) ;; *) dlprefiles="$dlprefiles $lib" ;; esac done if test "$build_libtool_libs" = yes; then if test -n "$rpath"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos*) # these systems don't actually have a c library (as such)! ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C library is in the System framework deplibs="$deplibs -framework System" ;; *-*-netbsd*) # Don't link with libc until the a.out ld.so is fixed. ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc due to us having libc/libc_r. ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work ;; *) # Add libc to deplibs on all other systems if necessary. if test "$build_libtool_need_lc" = "yes"; then deplibs="$deplibs -lc" fi ;; esac fi # Transform deplibs into only deplibs that can be linked in shared. name_save=$name libname_save=$libname release_save=$release versuffix_save=$versuffix major_save=$major # I'm not sure if I'm treating the release correctly. I think # release should show up in the -l (ie -lgmp5) so we don't want to # add it in twice. Is that correct? release="" versuffix="" major="" newdeplibs= droppeddeps=no case $deplibs_check_method in pass_all) # Don't check for shared/static. Everything works. # This might be a little naive. We might want to check # whether the library exists or not. But this is on # osf3 & osf4 and I'm not really sure... Just # implementing what was already the behavior. newdeplibs=$deplibs ;; test_compile) # This code stresses the "libraries are programs" paradigm to its # limits. Maybe even breaks it. We compile a program, linking it # against the deplibs as a proxy for the library. Then we can check # whether they linked in statically or dynamically with ldd. $rm conftest.c cat > conftest.c </dev/null` for potent_lib in $potential_libs; do # Follow soft links. if ls -lLd "$potent_lib" 2>/dev/null \ | grep " -> " >/dev/null; then continue fi # The statement above tries to avoid entering an # endless loop below, in case of cyclic links. # We might still enter an endless loop, since a link # loop can be closed while we follow links, # but so what? potlib="$potent_lib" while test -h "$potlib" 2>/dev/null; do potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` case $potliblink in [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; *) potlib=`$echo "X$potlib" | $Xsed -e 's,[^/]*$,,'`"$potliblink";; esac done if eval $file_magic_cmd \"\$potlib\" 2>/dev/null \ | ${SED} 10q \ | $EGREP "$file_magic_regex" > /dev/null; then newdeplibs="$newdeplibs $a_deplib" a_deplib="" break 2 fi done done fi if test -n "$a_deplib" ; then droppeddeps=yes $echo $echo "*** Warning: linker path does not have real file for library $a_deplib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have" $echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib" ; then $echo "*** with $libname but no candidates were found. (...for file magic test)" else $echo "*** with $libname and none of the candidates passed a file format test" $echo "*** using a file magic. Last file checked: $potlib" fi fi else # Add a -L argument. newdeplibs="$newdeplibs $a_deplib" fi done # Gone through all deplibs. ;; match_pattern*) set dummy $deplibs_check_method match_pattern_regex=`expr "$deplibs_check_method" : "$2 \(.*\)"` for a_deplib in $deplibs; do name=`expr $a_deplib : '-l\(.*\)'` # If $name is empty we are operating on a -L argument. if test -n "$name" && test "$name" != "0"; then if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then case " $predeps $postdeps " in *" $a_deplib "*) newdeplibs="$newdeplibs $a_deplib" a_deplib="" ;; esac fi if test -n "$a_deplib" ; then libname=`eval \\$echo \"$libname_spec\"` for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do potential_libs=`ls $i/$libname[.-]* 2>/dev/null` for potent_lib in $potential_libs; do potlib="$potent_lib" # see symlink-check above in file_magic test if eval $echo \"$potent_lib\" 2>/dev/null \ | ${SED} 10q \ | $EGREP "$match_pattern_regex" > /dev/null; then newdeplibs="$newdeplibs $a_deplib" a_deplib="" break 2 fi done done fi if test -n "$a_deplib" ; then droppeddeps=yes $echo $echo "*** Warning: linker path does not have real file for library $a_deplib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have" $echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib" ; then $echo "*** with $libname but no candidates were found. (...for regex pattern test)" else $echo "*** with $libname and none of the candidates passed a file format test" $echo "*** using a regex pattern. Last file checked: $potlib" fi fi else # Add a -L argument. newdeplibs="$newdeplibs $a_deplib" fi done # Gone through all deplibs. ;; none | unknown | *) newdeplibs="" tmp_deplibs=`$echo "X $deplibs" | $Xsed -e 's/ -lc$//' \ -e 's/ -[LR][^ ]*//g'` if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then for i in $predeps $postdeps ; do # can't use Xsed below, because $i might contain '/' tmp_deplibs=`$echo "X $tmp_deplibs" | ${SED} -e "1s,^X,," -e "s,$i,,"` done fi if $echo "X $tmp_deplibs" | $Xsed -e 's/[ ]//g' \ | grep . >/dev/null; then $echo if test "X$deplibs_check_method" = "Xnone"; then $echo "*** Warning: inter-library dependencies are not supported in this platform." else $echo "*** Warning: inter-library dependencies are not known to be supported." fi $echo "*** All declared inter-library dependencies are being dropped." droppeddeps=yes fi ;; esac versuffix=$versuffix_save major=$major_save release=$release_save libname=$libname_save name=$name_save case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library is the System framework newdeplibs=`$echo "X $newdeplibs" | $Xsed -e 's/ -lc / -framework System /'` ;; esac if test "$droppeddeps" = yes; then if test "$module" = yes; then $echo $echo "*** Warning: libtool could not satisfy all declared inter-library" $echo "*** dependencies of module $libname. Therefore, libtool will create" $echo "*** a static module, that should work as long as the dlopening" $echo "*** application is linked with the -dlopen flag." if test -z "$global_symbol_pipe"; then $echo $echo "*** However, this would only work if libtool was able to extract symbol" $echo "*** lists from a program, using \`nm' or equivalent, but libtool could" $echo "*** not find such a program. So, this module is probably useless." $echo "*** \`nm' from GNU binutils and a full rebuild may help." fi if test "$build_old_libs" = no; then oldlibs="$output_objdir/$libname.$libext" build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi else $echo "*** The inter-library dependencies that have been dropped here will be" $echo "*** automatically added whenever a program is linked with this library" $echo "*** or is declared to -dlopen it." if test "$allow_undefined" = no; then $echo $echo "*** Since this library must not contain undefined symbols," $echo "*** because either the platform does not support them or" $echo "*** it was explicitly requested with -no-undefined," $echo "*** libtool will only create a static version of it." if test "$build_old_libs" = no; then oldlibs="$output_objdir/$libname.$libext" build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi fi fi # Done checking deplibs! deplibs=$newdeplibs fi # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $deplibs " in *" -L$path/$objdir "*) new_libs="$new_libs -L$path/$objdir" ;; esac ;; esac done for deplib in $deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$new_libs $deplib" ;; esac ;; *) new_libs="$new_libs $deplib" ;; esac done deplibs="$new_libs" # All the library-specific variables (install_libdir is set above). library_names= old_library= dlname= # Test again, we may have decided not to build it any more if test "$build_libtool_libs" = yes; then if test "$hardcode_into_libs" = yes; then # Hardcode the library paths hardcode_libdirs= dep_rpath= rpath="$finalize_rpath" test "$mode" != relink && rpath="$compile_rpath$rpath" for libdir in $rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs="$libdir" else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" dep_rpath="$dep_rpath $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) perm_rpath="$perm_rpath $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir="$hardcode_libdirs" if test -n "$hardcode_libdir_flag_spec_ld"; then case $archive_cmds in *\$LD*) eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\" ;; *) eval dep_rpath=\"$hardcode_libdir_flag_spec\" ;; esac else eval dep_rpath=\"$hardcode_libdir_flag_spec\" fi fi if test -n "$runpath_var" && test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do rpath="$rpath$dir:" done eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" fi test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" fi shlibpath="$finalize_shlibpath" test "$mode" != relink && shlibpath="$compile_shlibpath$shlibpath" if test -n "$shlibpath"; then eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" fi # Get the real and link names of the library. eval shared_ext=\"$shrext_cmds\" eval library_names=\"$library_names_spec\" set dummy $library_names realname="$2" shift; shift if test -n "$soname_spec"; then eval soname=\"$soname_spec\" else soname="$realname" fi if test -z "$dlname"; then dlname=$soname fi lib="$output_objdir/$realname" linknames= for link do linknames="$linknames $link" done # Use standard objects if they are pic test -z "$pic_flag" && libobjs=`$echo "X$libobjs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` # Prepare the list of exported symbols if test -z "$export_symbols"; then if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then $show "generating symbol list for \`$libname.la'" export_symbols="$output_objdir/$libname.exp" $run $rm $export_symbols cmds=$export_symbols_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" if len=`expr "X$cmd" : ".*"` && test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then $show "$cmd" $run eval "$cmd" || exit $? skipped_export=false else # The command line is too long to execute in one step. $show "using reloadable object file for export list..." skipped_export=: # Break out early, otherwise skipped_export may be # set to false by a later but shorter cmd. break fi done IFS="$save_ifs" if test -n "$export_symbols_regex"; then $show "$EGREP -e \"$export_symbols_regex\" \"$export_symbols\" > \"${export_symbols}T\"" $run eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' $show "$mv \"${export_symbols}T\" \"$export_symbols\"" $run eval '$mv "${export_symbols}T" "$export_symbols"' fi fi fi if test -n "$export_symbols" && test -n "$include_expsyms"; then $run eval '$echo "X$include_expsyms" | $SP2NL >> "$export_symbols"' fi tmp_deplibs= for test_deplib in $deplibs; do case " $convenience " in *" $test_deplib "*) ;; *) tmp_deplibs="$tmp_deplibs $test_deplib" ;; esac done deplibs="$tmp_deplibs" if test -n "$convenience"; then if test -n "$whole_archive_flag_spec"; then save_libobjs=$libobjs eval libobjs=\"\$libobjs $whole_archive_flag_spec\" else gentop="$output_objdir/${outputname}x" generated="$generated $gentop" func_extract_archives $gentop $convenience libobjs="$libobjs $func_extract_archives_result" fi fi if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then eval flag=\"$thread_safe_flag_spec\" linker_flags="$linker_flags $flag" fi # Make a backup of the uninstalled library when relinking if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}U && $mv $realname ${realname}U)' || exit $? fi # Do each of the archive commands. if test "$module" = yes && test -n "$module_cmds" ; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then eval test_cmds=\"$module_expsym_cmds\" cmds=$module_expsym_cmds else eval test_cmds=\"$module_cmds\" cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then eval test_cmds=\"$archive_expsym_cmds\" cmds=$archive_expsym_cmds else eval test_cmds=\"$archive_cmds\" cmds=$archive_cmds fi fi if test "X$skipped_export" != "X:" && len=`expr "X$test_cmds" : ".*" 2>/dev/null` && test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then : else # The command line is too long to link in one step, link piecewise. $echo "creating reloadable object files..." # Save the value of $output and $libobjs because we want to # use them later. If we have whole_archive_flag_spec, we # want to use save_libobjs as it was before # whole_archive_flag_spec was expanded, because we can't # assume the linker understands whole_archive_flag_spec. # This may have to be revisited, in case too many # convenience libraries get linked in and end up exceeding # the spec. if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then save_libobjs=$libobjs fi save_output=$output output_la=`$echo "X$output" | $Xsed -e "$basename"` # Clear the reloadable object creation command queue and # initialize k to one. test_cmds= concat_cmds= objlist= delfiles= last_robj= k=1 output=$output_objdir/$output_la-${k}.$objext # Loop over the list of objects to be linked. for obj in $save_libobjs do eval test_cmds=\"$reload_cmds $objlist $last_robj\" if test "X$objlist" = X || { len=`expr "X$test_cmds" : ".*" 2>/dev/null` && test "$len" -le "$max_cmd_len"; }; then objlist="$objlist $obj" else # The command $test_cmds is almost too long, add a # command to the queue. if test "$k" -eq 1 ; then # The first file doesn't have a previous command to add. eval concat_cmds=\"$reload_cmds $objlist $last_robj\" else # All subsequent reloadable object files will link in # the last one created. eval concat_cmds=\"\$concat_cmds~$reload_cmds $objlist $last_robj\" fi last_robj=$output_objdir/$output_la-${k}.$objext k=`expr $k + 1` output=$output_objdir/$output_la-${k}.$objext objlist=$obj len=1 fi done # Handle the remaining objects by creating one last # reloadable object file. All subsequent reloadable object # files will link in the last one created. test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\${concat_cmds}$reload_cmds $objlist $last_robj\" if ${skipped_export-false}; then $show "generating symbol list for \`$libname.la'" export_symbols="$output_objdir/$libname.exp" $run $rm $export_symbols libobjs=$output # Append the command to create the export file. eval concat_cmds=\"\$concat_cmds~$export_symbols_cmds\" fi # Set up a command to remove the reloadable object files # after they are used. i=0 while test "$i" -lt "$k" do i=`expr $i + 1` delfiles="$delfiles $output_objdir/$output_la-${i}.$objext" done $echo "creating a temporary reloadable object file: $output" # Loop through the commands generated above and execute them. save_ifs="$IFS"; IFS='~' for cmd in $concat_cmds; do IFS="$save_ifs" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" libobjs=$output # Restore the value of output. output=$save_output if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then eval libobjs=\"\$libobjs $whole_archive_flag_spec\" fi # Expand the library linking commands again to reset the # value of $libobjs for piecewise linking. # Do each of the archive commands. if test "$module" = yes && test -n "$module_cmds" ; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then cmds=$module_expsym_cmds else cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then cmds=$archive_expsym_cmds else cmds=$archive_cmds fi fi # Append the command to remove the reloadable object files # to the just-reset $cmds. eval cmds=\"\$cmds~\$rm $delfiles\" fi save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}T && $mv ${realname}U $realname)' fi exit $lt_exit } done IFS="$save_ifs" # Restore the uninstalled library and exit if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}T && $mv $realname ${realname}T && $mv "$realname"U $realname)' || exit $? if test -n "$convenience"; then if test -z "$whole_archive_flag_spec"; then $show "${rm}r $gentop" $run ${rm}r "$gentop" fi fi exit $EXIT_SUCCESS fi # Create links to the real library. for linkname in $linknames; do if test "$realname" != "$linkname"; then $show "(cd $output_objdir && $rm $linkname && $LN_S $realname $linkname)" $run eval '(cd $output_objdir && $rm $linkname && $LN_S $realname $linkname)' || exit $? fi done # If -module or -export-dynamic was specified, set the dlname. if test "$module" = yes || test "$export_dynamic" = yes; then # On all known operating systems, these are identical. dlname="$soname" fi fi ;; obj) case " $deplibs" in *\ -l* | *\ -L*) $echo "$modename: warning: \`-l' and \`-L' are ignored for objects" 1>&2 ;; esac if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then $echo "$modename: warning: \`-dlopen' is ignored for objects" 1>&2 fi if test -n "$rpath"; then $echo "$modename: warning: \`-rpath' is ignored for objects" 1>&2 fi if test -n "$xrpath"; then $echo "$modename: warning: \`-R' is ignored for objects" 1>&2 fi if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info' is ignored for objects" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for objects" 1>&2 fi case $output in *.lo) if test -n "$objs$old_deplibs"; then $echo "$modename: cannot build library object \`$output' from non-libtool objects" 1>&2 exit $EXIT_FAILURE fi libobj="$output" obj=`$echo "X$output" | $Xsed -e "$lo2o"` ;; *) libobj= obj="$output" ;; esac # Delete the old objects. $run $rm $obj $libobj # Objects from convenience libraries. This assumes # single-version convenience libraries. Whenever we create # different ones for PIC/non-PIC, this we'll have to duplicate # the extraction. reload_conv_objs= gentop= # reload_cmds runs $LD directly, so let us get rid of # -Wl from whole_archive_flag_spec and hope we can get by with # turning comma into space.. wl= if test -n "$convenience"; then if test -n "$whole_archive_flag_spec"; then eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" reload_conv_objs=$reload_objs\ `$echo "X$tmp_whole_archive_flags" | $Xsed -e 's|,| |g'` else gentop="$output_objdir/${obj}x" generated="$generated $gentop" func_extract_archives $gentop $convenience reload_conv_objs="$reload_objs $func_extract_archives_result" fi fi # Create the old-style object. reload_objs="$objs$old_deplibs "`$echo "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}$'/d' -e '/\.lib$/d' -e "$lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test output="$obj" cmds=$reload_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" # Exit if we aren't doing a library object file. if test -z "$libobj"; then if test -n "$gentop"; then $show "${rm}r $gentop" $run ${rm}r $gentop fi exit $EXIT_SUCCESS fi if test "$build_libtool_libs" != yes; then if test -n "$gentop"; then $show "${rm}r $gentop" $run ${rm}r $gentop fi # Create an invalid libtool object if no PIC, so that we don't # accidentally link it into a program. # $show "echo timestamp > $libobj" # $run eval "echo timestamp > $libobj" || exit $? exit $EXIT_SUCCESS fi if test -n "$pic_flag" || test "$pic_mode" != default; then # Only do commands if we really have different PIC objects. reload_objs="$libobjs $reload_conv_objs" output="$libobj" cmds=$reload_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" fi if test -n "$gentop"; then $show "${rm}r $gentop" $run ${rm}r $gentop fi exit $EXIT_SUCCESS ;; prog) case $host in *cygwin*) output=`$echo $output | ${SED} -e 's,.exe$,,;s,$,.exe,'` ;; esac if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info' is ignored for programs" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for programs" 1>&2 fi if test "$preload" = yes; then if test "$dlopen_support" = unknown && test "$dlopen_self" = unknown && test "$dlopen_self_static" = unknown; then $echo "$modename: warning: \`AC_LIBTOOL_DLOPEN' not used. Assuming no dlopen support." fi fi case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library is the System framework compile_deplibs=`$echo "X $compile_deplibs" | $Xsed -e 's/ -lc / -framework System /'` finalize_deplibs=`$echo "X $finalize_deplibs" | $Xsed -e 's/ -lc / -framework System /'` ;; esac case $host in *darwin*) # Don't allow lazy linking, it breaks C++ global constructors if test "$tagname" = CXX ; then compile_command="$compile_command ${wl}-bind_at_load" finalize_command="$finalize_command ${wl}-bind_at_load" fi ;; esac # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $compile_deplibs " in *" -L$path/$objdir "*) new_libs="$new_libs -L$path/$objdir" ;; esac ;; esac done for deplib in $compile_deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$new_libs $deplib" ;; esac ;; *) new_libs="$new_libs $deplib" ;; esac done compile_deplibs="$new_libs" compile_command="$compile_command $compile_deplibs" finalize_command="$finalize_command $finalize_deplibs" if test -n "$rpath$xrpath"; then # If the user specified any rpath flags, then add them. for libdir in $rpath $xrpath; do # This is the magic to use -rpath. case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" ;; esac done fi # Now hardcode the library paths rpath= hardcode_libdirs= for libdir in $compile_rpath $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs="$libdir" else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" rpath="$rpath $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) perm_rpath="$perm_rpath $libdir" ;; esac fi case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) testbindir=`$echo "X$libdir" | $Xsed -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$libdir:"*) ;; *) dllsearchpath="$dllsearchpath:$libdir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; *) dllsearchpath="$dllsearchpath:$testbindir";; esac ;; esac done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir="$hardcode_libdirs" eval rpath=\" $hardcode_libdir_flag_spec\" fi compile_rpath="$rpath" rpath= hardcode_libdirs= for libdir in $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs="$libdir" else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" rpath="$rpath $flag" fi elif test -n "$runpath_var"; then case "$finalize_perm_rpath " in *" $libdir "*) ;; *) finalize_perm_rpath="$finalize_perm_rpath $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir="$hardcode_libdirs" eval rpath=\" $hardcode_libdir_flag_spec\" fi finalize_rpath="$rpath" if test -n "$libobjs" && test "$build_old_libs" = yes; then # Transform all the library objects into standard objects. compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` fi dlsyms= if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then if test -n "$NM" && test -n "$global_symbol_pipe"; then dlsyms="${outputname}S.c" else $echo "$modename: not configured to extract global symbols from dlpreopened files" 1>&2 fi fi if test -n "$dlsyms"; then case $dlsyms in "") ;; *.c) # Discover the nlist of each of the dlfiles. nlist="$output_objdir/${outputname}.nm" $show "$rm $nlist ${nlist}S ${nlist}T" $run $rm "$nlist" "${nlist}S" "${nlist}T" # Parse the name list into a source file. $show "creating $output_objdir/$dlsyms" test -z "$run" && $echo > "$output_objdir/$dlsyms" "\ /* $dlsyms - symbol resolution table for \`$outputname' dlsym emulation. */ /* Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP */ #ifdef __cplusplus extern \"C\" { #endif /* Prevent the only kind of declaration conflicts we can make. */ #define lt_preloaded_symbols some_other_symbol /* External symbol declarations for the compiler. */\ " if test "$dlself" = yes; then $show "generating symbol list for \`$output'" test -z "$run" && $echo ': @PROGRAM@ ' > "$nlist" # Add our own program objects to the symbol list. progfiles=`$echo "X$objs$old_deplibs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` for arg in $progfiles; do $show "extracting global C symbols from \`$arg'" $run eval "$NM $arg | $global_symbol_pipe >> '$nlist'" done if test -n "$exclude_expsyms"; then $run eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' $run eval '$mv "$nlist"T "$nlist"' fi if test -n "$export_symbols_regex"; then $run eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' $run eval '$mv "$nlist"T "$nlist"' fi # Prepare the list of exported symbols if test -z "$export_symbols"; then export_symbols="$output_objdir/$outputname.exp" $run $rm $export_symbols $run eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' case $host in *cygwin* | *mingw* ) $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' $run eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' ;; esac else $run eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' $run eval 'grep -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' $run eval 'mv "$nlist"T "$nlist"' case $host in *cygwin* | *mingw* ) $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' $run eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' ;; esac fi fi for arg in $dlprefiles; do $show "extracting global C symbols from \`$arg'" name=`$echo "$arg" | ${SED} -e 's%^.*/%%'` $run eval '$echo ": $name " >> "$nlist"' $run eval "$NM $arg | $global_symbol_pipe >> '$nlist'" done if test -z "$run"; then # Make sure we have at least an empty file. test -f "$nlist" || : > "$nlist" if test -n "$exclude_expsyms"; then $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T $mv "$nlist"T "$nlist" fi # Try sorting and uniquifying the output. if grep -v "^: " < "$nlist" | if sort -k 3 /dev/null 2>&1; then sort -k 3 else sort +2 fi | uniq > "$nlist"S; then : else grep -v "^: " < "$nlist" > "$nlist"S fi if test -f "$nlist"S; then eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$dlsyms"' else $echo '/* NONE */' >> "$output_objdir/$dlsyms" fi $echo >> "$output_objdir/$dlsyms" "\ #undef lt_preloaded_symbols #if defined (__STDC__) && __STDC__ # define lt_ptr void * #else # define lt_ptr char * # define const #endif /* The mapping between symbol names and symbols. */ " case $host in *cygwin* | *mingw* ) $echo >> "$output_objdir/$dlsyms" "\ /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs */ struct { " ;; * ) $echo >> "$output_objdir/$dlsyms" "\ const struct { " ;; esac $echo >> "$output_objdir/$dlsyms" "\ const char *name; lt_ptr address; } lt_preloaded_symbols[] = {\ " eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$dlsyms" $echo >> "$output_objdir/$dlsyms" "\ {0, (lt_ptr) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt_preloaded_symbols; } #endif #ifdef __cplusplus } #endif\ " fi pic_flag_for_symtable= case $host in # compiling the symbol table file with pic_flag works around # a FreeBSD bug that causes programs to crash when -lm is # linked before any other PIC object. But we must not use # pic_flag when linking with -static. The problem exists in # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. *-*-freebsd2*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) case "$compile_command " in *" -static "*) ;; *) pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND";; esac;; *-*-hpux*) case "$compile_command " in *" -static "*) ;; *) pic_flag_for_symtable=" $pic_flag";; esac esac # Now compile the dynamic symbol file. $show "(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")" $run eval '(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $? # Clean up the generated files. $show "$rm $output_objdir/$dlsyms $nlist ${nlist}S ${nlist}T" $run $rm "$output_objdir/$dlsyms" "$nlist" "${nlist}S" "${nlist}T" # Transform the symbol file into the correct name. case $host in *cygwin* | *mingw* ) if test -f "$output_objdir/${outputname}.def" ; then compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%" | $NL2SP` else compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` fi ;; * ) compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` ;; esac ;; *) $echo "$modename: unknown suffix for \`$dlsyms'" 1>&2 exit $EXIT_FAILURE ;; esac else # We keep going just in case the user didn't refer to # lt_preloaded_symbols. The linker will fail if global_symbol_pipe # really was required. # Nullify the symbol file. compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s% @SYMFILE@%%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s% @SYMFILE@%%" | $NL2SP` fi if test "$need_relink" = no || test "$build_libtool_libs" != yes; then # Replace the output file specification. compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e 's%@OUTPUT@%'"$output"'%g' | $NL2SP` link_command="$compile_command$compile_rpath" # We have no uninstalled library dependencies, so finalize right now. $show "$link_command" $run eval "$link_command" exit_status=$? # Delete the generated files. if test -n "$dlsyms"; then $show "$rm $output_objdir/${outputname}S.${objext}" $run $rm "$output_objdir/${outputname}S.${objext}" fi exit $exit_status fi if test -n "$shlibpath_var"; then # We should set the shlibpath_var rpath= for dir in $temp_rpath; do case $dir in [\\/]* | [A-Za-z]:[\\/]*) # Absolute path. rpath="$rpath$dir:" ;; *) # Relative path: add a thisdir entry. rpath="$rpath\$thisdir/$dir:" ;; esac done temp_rpath="$rpath" fi if test -n "$compile_shlibpath$finalize_shlibpath"; then compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" fi if test -n "$finalize_shlibpath"; then finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" fi compile_var= finalize_var= if test -n "$runpath_var"; then if test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do rpath="$rpath$dir:" done compile_var="$runpath_var=\"$rpath\$$runpath_var\" " fi if test -n "$finalize_perm_rpath"; then # We should set the runpath_var. rpath= for dir in $finalize_perm_rpath; do rpath="$rpath$dir:" done finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " fi fi if test "$no_install" = yes; then # We don't need to create a wrapper script. link_command="$compile_var$compile_command$compile_rpath" # Replace the output file specification. link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` # Delete the old output file. $run $rm $output # Link the executable and exit $show "$link_command" $run eval "$link_command" || exit $? exit $EXIT_SUCCESS fi if test "$hardcode_action" = relink; then # Fast installation is not supported link_command="$compile_var$compile_command$compile_rpath" relink_command="$finalize_var$finalize_command$finalize_rpath" $echo "$modename: warning: this platform does not like uninstalled shared libraries" 1>&2 $echo "$modename: \`$output' will be relinked during installation" 1>&2 else if test "$fast_install" != no; then link_command="$finalize_var$compile_command$finalize_rpath" if test "$fast_install" = yes; then relink_command=`$echo "X$compile_var$compile_command$compile_rpath" | $SP2NL | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g' | $NL2SP` else # fast_install is set to needless relink_command= fi else link_command="$compile_var$compile_command$compile_rpath" relink_command="$finalize_var$finalize_command$finalize_rpath" fi fi # Replace the output file specification. link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` # Delete the old output files. $run $rm $output $output_objdir/$outputname $output_objdir/lt-$outputname $show "$link_command" $run eval "$link_command" || exit $? # Now create the wrapper script. $show "creating $output" # Quote the relink command for shipping. if test -n "$relink_command"; then # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else var_value=`$echo "X$var_value" | $Xsed -e "$sed_quote_subst"` relink_command="$var=\"$var_value\"; export $var; $relink_command" fi done relink_command="(cd `pwd`; $relink_command)" relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e "$sed_quote_subst" | $NL2SP` fi # Quote $echo for shipping. if test "X$echo" = "X$SHELL $progpath --fallback-echo"; then case $progpath in [\\/]* | [A-Za-z]:[\\/]*) qecho="$SHELL $progpath --fallback-echo";; *) qecho="$SHELL `pwd`/$progpath --fallback-echo";; esac qecho=`$echo "X$qecho" | $Xsed -e "$sed_quote_subst"` else qecho=`$echo "X$echo" | $Xsed -e "$sed_quote_subst"` fi # Only actually do things if our run command is non-null. if test -z "$run"; then # win32 will think the script is a binary if it has # a .exe suffix, so we strip it off here. case $output in *.exe) output=`$echo $output|${SED} 's,.exe$,,'` ;; esac # test for cygwin because mv fails w/o .exe extensions case $host in *cygwin*) exeext=.exe outputname=`$echo $outputname|${SED} 's,.exe$,,'` ;; *) exeext= ;; esac case $host in *cygwin* | *mingw* ) output_name=`basename $output` output_path=`dirname $output` cwrappersource="$output_path/$objdir/lt-$output_name.c" cwrapper="$output_path/$output_name.exe" $rm $cwrappersource $cwrapper trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 cat > $cwrappersource <> $cwrappersource<<"EOF" #include #include #include #include #include #include #include #include #include #if defined(PATH_MAX) # define LT_PATHMAX PATH_MAX #elif defined(MAXPATHLEN) # define LT_PATHMAX MAXPATHLEN #else # define LT_PATHMAX 1024 #endif #ifndef DIR_SEPARATOR # define DIR_SEPARATOR '/' # define PATH_SEPARATOR ':' #endif #if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ defined (__OS2__) # define HAVE_DOS_BASED_FILE_SYSTEM # ifndef DIR_SEPARATOR_2 # define DIR_SEPARATOR_2 '\\' # endif # ifndef PATH_SEPARATOR_2 # define PATH_SEPARATOR_2 ';' # endif #endif #ifndef DIR_SEPARATOR_2 # define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) #else /* DIR_SEPARATOR_2 */ # define IS_DIR_SEPARATOR(ch) \ (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) #endif /* DIR_SEPARATOR_2 */ #ifndef PATH_SEPARATOR_2 # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) #else /* PATH_SEPARATOR_2 */ # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) #endif /* PATH_SEPARATOR_2 */ #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) #define XFREE(stale) do { \ if (stale) { free ((void *) stale); stale = 0; } \ } while (0) /* -DDEBUG is fairly common in CFLAGS. */ #undef DEBUG #if defined DEBUGWRAPPER # define DEBUG(format, ...) fprintf(stderr, format, __VA_ARGS__) #else # define DEBUG(format, ...) #endif const char *program_name = NULL; void * xmalloc (size_t num); char * xstrdup (const char *string); const char * base_name (const char *name); char * find_executable(const char *wrapper); int check_executable(const char *path); char * strendzap(char *str, const char *pat); void lt_fatal (const char *message, ...); int main (int argc, char *argv[]) { char **newargz; int i; program_name = (char *) xstrdup (base_name (argv[0])); DEBUG("(main) argv[0] : %s\n",argv[0]); DEBUG("(main) program_name : %s\n",program_name); newargz = XMALLOC(char *, argc+2); EOF cat >> $cwrappersource <> $cwrappersource <<"EOF" newargz[1] = find_executable(argv[0]); if (newargz[1] == NULL) lt_fatal("Couldn't find %s", argv[0]); DEBUG("(main) found exe at : %s\n",newargz[1]); /* we know the script has the same name, without the .exe */ /* so make sure newargz[1] doesn't end in .exe */ strendzap(newargz[1],".exe"); for (i = 1; i < argc; i++) newargz[i+1] = xstrdup(argv[i]); newargz[argc+1] = NULL; for (i=0; i> $cwrappersource <> $cwrappersource <> $cwrappersource <<"EOF" return 127; } void * xmalloc (size_t num) { void * p = (void *) malloc (num); if (!p) lt_fatal ("Memory exhausted"); return p; } char * xstrdup (const char *string) { return string ? strcpy ((char *) xmalloc (strlen (string) + 1), string) : NULL ; } const char * base_name (const char *name) { const char *base; #if defined (HAVE_DOS_BASED_FILE_SYSTEM) /* Skip over the disk name in MSDOS pathnames. */ if (isalpha ((unsigned char)name[0]) && name[1] == ':') name += 2; #endif for (base = name; *name; name++) if (IS_DIR_SEPARATOR (*name)) base = name + 1; return base; } int check_executable(const char * path) { struct stat st; DEBUG("(check_executable) : %s\n", path ? (*path ? path : "EMPTY!") : "NULL!"); if ((!path) || (!*path)) return 0; if ((stat (path, &st) >= 0) && ( /* MinGW & native WIN32 do not support S_IXOTH or S_IXGRP */ #if defined (S_IXOTH) ((st.st_mode & S_IXOTH) == S_IXOTH) || #endif #if defined (S_IXGRP) ((st.st_mode & S_IXGRP) == S_IXGRP) || #endif ((st.st_mode & S_IXUSR) == S_IXUSR)) ) return 1; else return 0; } /* Searches for the full path of the wrapper. Returns newly allocated full path name if found, NULL otherwise */ char * find_executable (const char* wrapper) { int has_slash = 0; const char* p; const char* p_next; /* static buffer for getcwd */ char tmp[LT_PATHMAX + 1]; int tmp_len; char* concat_name; DEBUG("(find_executable) : %s\n", wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!"); if ((wrapper == NULL) || (*wrapper == '\0')) return NULL; /* Absolute path? */ #if defined (HAVE_DOS_BASED_FILE_SYSTEM) if (isalpha ((unsigned char)wrapper[0]) && wrapper[1] == ':') { concat_name = xstrdup (wrapper); if (check_executable(concat_name)) return concat_name; XFREE(concat_name); } else { #endif if (IS_DIR_SEPARATOR (wrapper[0])) { concat_name = xstrdup (wrapper); if (check_executable(concat_name)) return concat_name; XFREE(concat_name); } #if defined (HAVE_DOS_BASED_FILE_SYSTEM) } #endif for (p = wrapper; *p; p++) if (*p == '/') { has_slash = 1; break; } if (!has_slash) { /* no slashes; search PATH */ const char* path = getenv ("PATH"); if (path != NULL) { for (p = path; *p; p = p_next) { const char* q; size_t p_len; for (q = p; *q; q++) if (IS_PATH_SEPARATOR(*q)) break; p_len = q - p; p_next = (*q == '\0' ? q : q + 1); if (p_len == 0) { /* empty path: current directory */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal ("getcwd failed"); tmp_len = strlen(tmp); concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); } else { concat_name = XMALLOC(char, p_len + 1 + strlen(wrapper) + 1); memcpy (concat_name, p, p_len); concat_name[p_len] = '/'; strcpy (concat_name + p_len + 1, wrapper); } if (check_executable(concat_name)) return concat_name; XFREE(concat_name); } } /* not found in PATH; assume curdir */ } /* Relative path | not found in path: prepend cwd */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal ("getcwd failed"); tmp_len = strlen(tmp); concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); if (check_executable(concat_name)) return concat_name; XFREE(concat_name); return NULL; } char * strendzap(char *str, const char *pat) { size_t len, patlen; assert(str != NULL); assert(pat != NULL); len = strlen(str); patlen = strlen(pat); if (patlen <= len) { str += len - patlen; if (strcmp(str, pat) == 0) *str = '\0'; } return str; } static void lt_error_core (int exit_status, const char * mode, const char * message, va_list ap) { fprintf (stderr, "%s: %s: ", program_name, mode); vfprintf (stderr, message, ap); fprintf (stderr, ".\n"); if (exit_status >= 0) exit (exit_status); } void lt_fatal (const char *message, ...) { va_list ap; va_start (ap, message); lt_error_core (EXIT_FAILURE, "FATAL", message, ap); va_end (ap); } EOF # we should really use a build-platform specific compiler # here, but OTOH, the wrappers (shell script and this C one) # are only useful if you want to execute the "real" binary. # Since the "real" binary is built for $host, then this # wrapper might as well be built for $host, too. $run $LTCC $LTCFLAGS -s -o $cwrapper $cwrappersource ;; esac $rm $output trap "$rm $output; exit $EXIT_FAILURE" 1 2 15 $echo > $output "\ #! $SHELL # $output - temporary wrapper script for $objdir/$outputname # Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP # # The $output program cannot be directly executed until all the libtool # libraries that it depends on are installed. # # This wrapper script should never be moved out of the build directory. # If it is, it will not operate correctly. # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. Xsed='${SED} -e 1s/^X//' sed_quote_subst='$sed_quote_subst' # Be Bourne compatible (taken from Autoconf:_AS_BOURNE_COMPATIBLE). if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac fi BIN_SH=xpg4; export BIN_SH # for Tru64 DUALCASE=1; export DUALCASE # for MKS sh # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH relink_command=\"$relink_command\" # This environment variable determines our operation mode. if test \"\$libtool_install_magic\" = \"$magic\"; then # install mode needs the following variable: notinst_deplibs='$notinst_deplibs' else # When we are sourced in execute mode, \$file and \$echo are already set. if test \"\$libtool_execute_magic\" != \"$magic\"; then echo=\"$qecho\" file=\"\$0\" # Make sure echo works. if test \"X\$1\" = X--no-reexec; then # Discard the --no-reexec flag, and continue. shift elif test \"X\`(\$echo '\t') 2>/dev/null\`\" = 'X\t'; then # Yippee, \$echo works! : else # Restart under the correct shell, and then maybe \$echo will work. exec $SHELL \"\$0\" --no-reexec \${1+\"\$@\"} fi fi\ " $echo >> $output "\ # Find the directory that this script lives in. thisdir=\`\$echo \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\` test \"x\$thisdir\" = \"x\$file\" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=\`ls -ld \"\$file\" | ${SED} -n 's/.*-> //p'\` while test -n \"\$file\"; do destdir=\`\$echo \"X\$file\" | \$Xsed -e 's%/[^/]*\$%%'\` # If there was a directory component, then change thisdir. if test \"x\$destdir\" != \"x\$file\"; then case \"\$destdir\" in [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; *) thisdir=\"\$thisdir/\$destdir\" ;; esac fi file=\`\$echo \"X\$file\" | \$Xsed -e 's%^.*/%%'\` file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\` done # Try to get the absolute directory name. absdir=\`cd \"\$thisdir\" && pwd\` test -n \"\$absdir\" && thisdir=\"\$absdir\" " if test "$fast_install" = yes; then $echo >> $output "\ program=lt-'$outputname'$exeext progdir=\"\$thisdir/$objdir\" if test ! -f \"\$progdir/\$program\" || \\ { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ test \"X\$file\" != \"X\$progdir/\$program\"; }; then file=\"\$\$-\$program\" if test ! -d \"\$progdir\"; then $mkdir \"\$progdir\" else $rm \"\$progdir/\$file\" fi" $echo >> $output "\ # relink executable if necessary if test -n \"\$relink_command\"; then if relink_command_output=\`eval \$relink_command 2>&1\`; then : else $echo \"\$relink_command_output\" >&2 $rm \"\$progdir/\$file\" exit $EXIT_FAILURE fi fi $mv \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || { $rm \"\$progdir/\$program\"; $mv \"\$progdir/\$file\" \"\$progdir/\$program\"; } $rm \"\$progdir/\$file\" fi" else $echo >> $output "\ program='$outputname' progdir=\"\$thisdir/$objdir\" " fi $echo >> $output "\ if test -f \"\$progdir/\$program\"; then" # Export our shlibpath_var if we have one. if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then $echo >> $output "\ # Add our own library path to $shlibpath_var $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" # Some systems cannot cope with colon-terminated $shlibpath_var # The second colon is a workaround for a bug in BeOS R4 sed $shlibpath_var=\`\$echo \"X\$$shlibpath_var\" | \$Xsed -e 's/::*\$//'\` export $shlibpath_var " fi # fixup the dll searchpath if we need to. if test -n "$dllsearchpath"; then $echo >> $output "\ # Add the dll search path components to the executable PATH PATH=$dllsearchpath:\$PATH " fi $echo >> $output "\ if test \"\$libtool_execute_magic\" != \"$magic\"; then # Run the actual program with our arguments. " case $host in # Backslashes separate directories on plain windows *-*-mingw | *-*-os2*) $echo >> $output "\ exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} " ;; *) $echo >> $output "\ exec \"\$progdir/\$program\" \${1+\"\$@\"} " ;; esac $echo >> $output "\ \$echo \"\$0: cannot exec \$program \$*\" exit $EXIT_FAILURE fi else # The program doesn't exist. \$echo \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 \$echo \"This script is just a wrapper for \$program.\" 1>&2 $echo \"See the $PACKAGE documentation for more information.\" 1>&2 exit $EXIT_FAILURE fi fi\ " chmod +x $output fi exit $EXIT_SUCCESS ;; esac # See if we need to build an old-fashioned archive. for oldlib in $oldlibs; do if test "$build_libtool_libs" = convenience; then oldobjs="$libobjs_save" addlibs="$convenience" build_libtool_libs=no else if test "$build_libtool_libs" = module; then oldobjs="$libobjs_save" build_libtool_libs=no else oldobjs="$old_deplibs $non_pic_objects" fi addlibs="$old_convenience" fi if test -n "$addlibs"; then gentop="$output_objdir/${outputname}x" generated="$generated $gentop" func_extract_archives $gentop $addlibs oldobjs="$oldobjs $func_extract_archives_result" fi # Do each command in the archive commands. if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then cmds=$old_archive_from_new_cmds else # POSIX demands no paths to be encoded in archives. We have # to avoid creating archives with duplicate basenames if we # might have to extract them afterwards, e.g., when creating a # static archive out of a convenience library, or when linking # the entirety of a libtool archive into another (currently # not supported by libtool). if (for obj in $oldobjs do $echo "X$obj" | $Xsed -e 's%^.*/%%' done | sort | sort -uc >/dev/null 2>&1); then : else $echo "copying selected object files to avoid basename conflicts..." if test -z "$gentop"; then gentop="$output_objdir/${outputname}x" generated="$generated $gentop" $show "${rm}r $gentop" $run ${rm}r "$gentop" $show "$mkdir $gentop" $run $mkdir "$gentop" exit_status=$? if test "$exit_status" -ne 0 && test ! -d "$gentop"; then exit $exit_status fi fi save_oldobjs=$oldobjs oldobjs= counter=1 for obj in $save_oldobjs do objbase=`$echo "X$obj" | $Xsed -e 's%^.*/%%'` case " $oldobjs " in " ") oldobjs=$obj ;; *[\ /]"$objbase "*) while :; do # Make sure we don't pick an alternate name that also # overlaps. newobj=lt$counter-$objbase counter=`expr $counter + 1` case " $oldobjs " in *[\ /]"$newobj "*) ;; *) if test ! -f "$gentop/$newobj"; then break; fi ;; esac done $show "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" $run ln "$obj" "$gentop/$newobj" || $run cp "$obj" "$gentop/$newobj" oldobjs="$oldobjs $gentop/$newobj" ;; *) oldobjs="$oldobjs $obj" ;; esac done fi eval cmds=\"$old_archive_cmds\" if len=`expr "X$cmds" : ".*"` && test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then cmds=$old_archive_cmds else # the command line is too long to link in one step, link in parts $echo "using piecewise archive linking..." save_RANLIB=$RANLIB RANLIB=: objlist= concat_cmds= save_oldobjs=$oldobjs # Is there a better way of finding the last object in the list? for obj in $save_oldobjs do last_oldobj=$obj done for obj in $save_oldobjs do oldobjs="$objlist $obj" objlist="$objlist $obj" eval test_cmds=\"$old_archive_cmds\" if len=`expr "X$test_cmds" : ".*" 2>/dev/null` && test "$len" -le "$max_cmd_len"; then : else # the above command should be used before it gets too long oldobjs=$objlist if test "$obj" = "$last_oldobj" ; then RANLIB=$save_RANLIB fi test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" objlist= fi done RANLIB=$save_RANLIB oldobjs=$objlist if test "X$oldobjs" = "X" ; then eval cmds=\"\$concat_cmds\" else eval cmds=\"\$concat_cmds~\$old_archive_cmds\" fi fi fi save_ifs="$IFS"; IFS='~' for cmd in $cmds; do eval cmd=\"$cmd\" IFS="$save_ifs" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" done if test -n "$generated"; then $show "${rm}r$generated" $run ${rm}r$generated fi # Now create the libtool archive. case $output in *.la) old_library= test "$build_old_libs" = yes && old_library="$libname.$libext" $show "creating $output" # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else var_value=`$echo "X$var_value" | $Xsed -e "$sed_quote_subst"` relink_command="$var=\"$var_value\"; export $var; $relink_command" fi done # Quote the link command for shipping. relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e "$sed_quote_subst" | $NL2SP` if test "$hardcode_automatic" = yes ; then relink_command= fi # Only create the output if not a dry run. if test -z "$run"; then for installed in no yes; do if test "$installed" = yes; then if test -z "$install_libdir"; then break fi output="$output_objdir/$outputname"i # Replace all uninstalled libtool libraries with the installed ones newdependency_libs= for deplib in $dependency_libs; do case $deplib in *.la) name=`$echo "X$deplib" | $Xsed -e 's%^.*/%%'` eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` if test -z "$libdir"; then $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi newdependency_libs="$newdependency_libs $libdir/$name" ;; *) newdependency_libs="$newdependency_libs $deplib" ;; esac done dependency_libs="$newdependency_libs" newdlfiles= for lib in $dlfiles; do name=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` if test -z "$libdir"; then $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi newdlfiles="$newdlfiles $libdir/$name" done dlfiles="$newdlfiles" newdlprefiles= for lib in $dlprefiles; do name=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` if test -z "$libdir"; then $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi newdlprefiles="$newdlprefiles $libdir/$name" done dlprefiles="$newdlprefiles" else newdlfiles= for lib in $dlfiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; *) abs=`pwd`"/$lib" ;; esac newdlfiles="$newdlfiles $abs" done dlfiles="$newdlfiles" newdlprefiles= for lib in $dlprefiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; *) abs=`pwd`"/$lib" ;; esac newdlprefiles="$newdlprefiles $abs" done dlprefiles="$newdlprefiles" fi $rm $output # place dlname in correct position for cygwin tdlname=$dlname case $host,$output,$installed,$module,$dlname in *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;; esac $echo > $output "\ # $outputname - a libtool library file # Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP # # Please DO NOT delete this file! # It is necessary for linking the library. # The name that we can dlopen(3). dlname='$tdlname' # Names of this library. library_names='$library_names' # The name of the static archive. old_library='$old_library' # Libraries that this one depends upon. dependency_libs='$dependency_libs' # Version information for $libname. current=$current age=$age revision=$revision # Is this an already installed library? installed=$installed # Should we warn about portability when linking against -modules? shouldnotlink=$module # Files to dlopen/dlpreopen dlopen='$dlfiles' dlpreopen='$dlprefiles' # Directory that this library needs to be installed in: libdir='$install_libdir'" if test "$installed" = no && test "$need_relink" = yes; then $echo >> $output "\ relink_command=\"$relink_command\"" fi done fi # Do a symbolic link so that the libtool archive can be found in # LD_LIBRARY_PATH before the program is installed. $show "(cd $output_objdir && $rm $outputname && $LN_S ../$outputname $outputname)" $run eval '(cd $output_objdir && $rm $outputname && $LN_S ../$outputname $outputname)' || exit $? ;; esac exit $EXIT_SUCCESS ;; # libtool install mode install) modename="$modename: install" # There may be an optional sh(1) argument at the beginning of # install_prog (especially on Windows NT). if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || # Allow the use of GNU shtool's install command. $echo "X$nonopt" | grep shtool > /dev/null; then # Aesthetically quote it. arg=`$echo "X$nonopt" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac install_prog="$arg " arg="$1" shift else install_prog= arg=$nonopt fi # The real first argument should be the name of the installation program. # Aesthetically quote it. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac install_prog="$install_prog$arg" # We need to accept at least all the BSD install flags. dest= files= opts= prev= install_type= isdir=no stripme= for arg do if test -n "$dest"; then files="$files $dest" dest=$arg continue fi case $arg in -d) isdir=yes ;; -f) case " $install_prog " in *[\\\ /]cp\ *) ;; *) prev=$arg ;; esac ;; -g | -m | -o) prev=$arg ;; -s) stripme=" -s" continue ;; -*) ;; *) # If the previous option needed an argument, then skip it. if test -n "$prev"; then prev= else dest=$arg continue fi ;; esac # Aesthetically quote the argument. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac install_prog="$install_prog $arg" done if test -z "$install_prog"; then $echo "$modename: you must specify an install program" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test -n "$prev"; then $echo "$modename: the \`$prev' option requires an argument" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test -z "$files"; then if test -z "$dest"; then $echo "$modename: no file or destination specified" 1>&2 else $echo "$modename: you must specify a destination" 1>&2 fi $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Strip any trailing slash from the destination. dest=`$echo "X$dest" | $Xsed -e 's%/$%%'` # Check to see that the destination is a directory. test -d "$dest" && isdir=yes if test "$isdir" = yes; then destdir="$dest" destname= else destdir=`$echo "X$dest" | $Xsed -e 's%/[^/]*$%%'` test "X$destdir" = "X$dest" && destdir=. destname=`$echo "X$dest" | $Xsed -e 's%^.*/%%'` # Not a directory, so check to see that there is only one file specified. set dummy $files if test "$#" -gt 2; then $echo "$modename: \`$dest' is not a directory" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi fi case $destdir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) for file in $files; do case $file in *.lo) ;; *) $echo "$modename: \`$destdir' must be an absolute directory name" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; esac done ;; esac # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic="$magic" staticlibs= future_libdirs= current_libdirs= for file in $files; do # Do each installation. case $file in *.$libext) # Do the static libraries later. staticlibs="$staticlibs $file" ;; *.la) # Check to see that this really is a libtool archive. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : else $echo "$modename: \`$file' is not a valid libtool archive" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi library_names= old_library= relink_command= # If there is no directory component, then add one. case $file in */* | *\\*) . $file ;; *) . ./$file ;; esac # Add the libdir to current_libdirs if it is the destination. if test "X$destdir" = "X$libdir"; then case "$current_libdirs " in *" $libdir "*) ;; *) current_libdirs="$current_libdirs $libdir" ;; esac else # Note the libdir as a future libdir. case "$future_libdirs " in *" $libdir "*) ;; *) future_libdirs="$future_libdirs $libdir" ;; esac fi dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'`/ test "X$dir" = "X$file/" && dir= dir="$dir$objdir" if test -n "$relink_command"; then # Determine the prefix the user has applied to our future dir. inst_prefix_dir=`$echo "$destdir" | $SED "s%$libdir\$%%"` # Don't allow the user to place us outside of our expected # location b/c this prevents finding dependent libraries that # are installed to the same prefix. # At present, this check doesn't affect windows .dll's that # are installed into $libdir/../bin (currently, that works fine) # but it's something to keep an eye on. if test "$inst_prefix_dir" = "$destdir"; then $echo "$modename: error: cannot install \`$file' to a directory not ending in $libdir" 1>&2 exit $EXIT_FAILURE fi if test -n "$inst_prefix_dir"; then # Stick the inst_prefix_dir data into the link command. relink_command=`$echo "$relink_command" | $SP2NL | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%" | $NL2SP` else relink_command=`$echo "$relink_command" | $SP2NL | $SED "s%@inst_prefix_dir@%%" | $NL2SP` fi $echo "$modename: warning: relinking \`$file'" 1>&2 $show "$relink_command" if $run eval "$relink_command"; then : else $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 exit $EXIT_FAILURE fi fi # See the names of the shared library. set dummy $library_names if test -n "$2"; then realname="$2" shift shift srcname="$realname" test -n "$relink_command" && srcname="$realname"T # Install the shared library and build the symlinks. $show "$install_prog $dir/$srcname $destdir/$realname" $run eval "$install_prog $dir/$srcname $destdir/$realname" || exit $? if test -n "$stripme" && test -n "$striplib"; then $show "$striplib $destdir/$realname" $run eval "$striplib $destdir/$realname" || exit $? fi if test "$#" -gt 0; then # Delete the old symlinks, and create new ones. # Try `ln -sf' first, because the `ln' binary might depend on # the symlink we replace! Solaris /bin/ln does not understand -f, # so we also need to try rm && ln -s. for linkname do if test "$linkname" != "$realname"; then $show "(cd $destdir && { $LN_S -f $realname $linkname || { $rm $linkname && $LN_S $realname $linkname; }; })" $run eval "(cd $destdir && { $LN_S -f $realname $linkname || { $rm $linkname && $LN_S $realname $linkname; }; })" fi done fi # Do each command in the postinstall commands. lib="$destdir/$realname" cmds=$postinstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}T && $mv ${realname}U $realname)' fi exit $lt_exit } done IFS="$save_ifs" fi # Install the pseudo-library for information purposes. name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` instname="$dir/$name"i $show "$install_prog $instname $destdir/$name" $run eval "$install_prog $instname $destdir/$name" || exit $? # Maybe install the static library, too. test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" ;; *.lo) # Install (i.e. copy) a libtool object. # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile="$destdir/$destname" else destfile=`$echo "X$file" | $Xsed -e 's%^.*/%%'` destfile="$destdir/$destfile" fi # Deduce the name of the destination old-style object file. case $destfile in *.lo) staticdest=`$echo "X$destfile" | $Xsed -e "$lo2o"` ;; *.$objext) staticdest="$destfile" destfile= ;; *) $echo "$modename: cannot copy a libtool object to \`$destfile'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; esac # Install the libtool object if requested. if test -n "$destfile"; then $show "$install_prog $file $destfile" $run eval "$install_prog $file $destfile" || exit $? fi # Install the old object if enabled. if test "$build_old_libs" = yes; then # Deduce the name of the old-style object file. staticobj=`$echo "X$file" | $Xsed -e "$lo2o"` $show "$install_prog $staticobj $staticdest" $run eval "$install_prog \$staticobj \$staticdest" || exit $? fi exit $EXIT_SUCCESS ;; *) # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile="$destdir/$destname" else destfile=`$echo "X$file" | $Xsed -e 's%^.*/%%'` destfile="$destdir/$destfile" fi # If the file is missing, and there is a .exe on the end, strip it # because it is most likely a libtool script we actually want to # install stripped_ext="" case $file in *.exe) if test ! -f "$file"; then file=`$echo $file|${SED} 's,.exe$,,'` stripped_ext=".exe" fi ;; esac # Do a test to see if this is really a libtool program. case $host in *cygwin*|*mingw*) wrapper=`$echo $file | ${SED} -e 's,.exe$,,'` ;; *) wrapper=$file ;; esac if (${SED} -e '4q' $wrapper | grep "^# Generated by .*$PACKAGE")>/dev/null 2>&1; then notinst_deplibs= relink_command= # Note that it is not necessary on cygwin/mingw to append a dot to # foo even if both foo and FILE.exe exist: automatic-append-.exe # behavior happens only for exec(3), not for open(2)! Also, sourcing # `FILE.' does not work on cygwin managed mounts. # # If there is no directory component, then add one. case $wrapper in */* | *\\*) . ${wrapper} ;; *) . ./${wrapper} ;; esac # Check the variables that should have been set. if test -z "$notinst_deplibs"; then $echo "$modename: invalid libtool wrapper script \`$wrapper'" 1>&2 exit $EXIT_FAILURE fi finalize=yes for lib in $notinst_deplibs; do # Check to see that each library is installed. libdir= if test -f "$lib"; then # If there is no directory component, then add one. case $lib in */* | *\\*) . $lib ;; *) . ./$lib ;; esac fi libfile="$libdir/"`$echo "X$lib" | $Xsed -e 's%^.*/%%g'` ### testsuite: skip nested quoting test if test -n "$libdir" && test ! -f "$libfile"; then $echo "$modename: warning: \`$lib' has not been installed in \`$libdir'" 1>&2 finalize=no fi done relink_command= # Note that it is not necessary on cygwin/mingw to append a dot to # foo even if both foo and FILE.exe exist: automatic-append-.exe # behavior happens only for exec(3), not for open(2)! Also, sourcing # `FILE.' does not work on cygwin managed mounts. # # If there is no directory component, then add one. case $wrapper in */* | *\\*) . ${wrapper} ;; *) . ./${wrapper} ;; esac outputname= if test "$fast_install" = no && test -n "$relink_command"; then if test "$finalize" = yes && test -z "$run"; then tmpdir=`func_mktempdir` file=`$echo "X$file$stripped_ext" | $Xsed -e 's%^.*/%%'` outputname="$tmpdir/$file" # Replace the output file specification. relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g' | $NL2SP` $show "$relink_command" if $run eval "$relink_command"; then : else $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 ${rm}r "$tmpdir" continue fi file="$outputname" else $echo "$modename: warning: cannot relink \`$file'" 1>&2 fi else # Install the binary that we compiled earlier. file=`$echo "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"` fi fi # remove .exe since cygwin /usr/bin/install will append another # one anyway case $install_prog,$host in */usr/bin/install*,*cygwin*) case $file:$destfile in *.exe:*.exe) # this is ok ;; *.exe:*) destfile=$destfile.exe ;; *:*.exe) destfile=`$echo $destfile | ${SED} -e 's,.exe$,,'` ;; esac ;; esac $show "$install_prog$stripme $file $destfile" $run eval "$install_prog\$stripme \$file \$destfile" || exit $? test -n "$outputname" && ${rm}r "$tmpdir" ;; esac done for file in $staticlibs; do name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` # Set up the ranlib parameters. oldlib="$destdir/$name" $show "$install_prog $file $oldlib" $run eval "$install_prog \$file \$oldlib" || exit $? if test -n "$stripme" && test -n "$old_striplib"; then $show "$old_striplib $oldlib" $run eval "$old_striplib $oldlib" || exit $? fi # Do each command in the postinstall commands. cmds=$old_postinstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" done if test -n "$future_libdirs"; then $echo "$modename: warning: remember to run \`$progname --finish$future_libdirs'" 1>&2 fi if test -n "$current_libdirs"; then # Maybe just do a dry run. test -n "$run" && current_libdirs=" -n$current_libdirs" exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' else exit $EXIT_SUCCESS fi ;; # libtool finish mode finish) modename="$modename: finish" libdirs="$nonopt" admincmds= if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then for dir do libdirs="$libdirs $dir" done for libdir in $libdirs; do if test -n "$finish_cmds"; then # Do each command in the finish commands. cmds=$finish_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || admincmds="$admincmds $cmd" done IFS="$save_ifs" fi if test -n "$finish_eval"; then # Do the single finish_eval. eval cmds=\"$finish_eval\" $run eval "$cmds" || admincmds="$admincmds $cmds" fi done fi # Exit here if they wanted silent mode. test "$show" = : && exit $EXIT_SUCCESS $echo "X----------------------------------------------------------------------" | $Xsed $echo "Libraries have been installed in:" for libdir in $libdirs; do $echo " $libdir" done $echo $echo "If you ever happen to want to link against installed libraries" $echo "in a given directory, LIBDIR, you must either use libtool, and" $echo "specify the full pathname of the library, or use the \`-LLIBDIR'" $echo "flag during linking and do at least one of the following:" if test -n "$shlibpath_var"; then $echo " - add LIBDIR to the \`$shlibpath_var' environment variable" $echo " during execution" fi if test -n "$runpath_var"; then $echo " - add LIBDIR to the \`$runpath_var' environment variable" $echo " during linking" fi if test -n "$hardcode_libdir_flag_spec"; then libdir=LIBDIR eval flag=\"$hardcode_libdir_flag_spec\" $echo " - use the \`$flag' linker flag" fi if test -n "$admincmds"; then $echo " - have your system administrator run these commands:$admincmds" fi if test -f /etc/ld.so.conf; then $echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" fi $echo $echo "See any operating system documentation about shared libraries for" $echo "more information, such as the ld(1) and ld.so(8) manual pages." $echo "X----------------------------------------------------------------------" | $Xsed exit $EXIT_SUCCESS ;; # libtool execute mode execute) modename="$modename: execute" # The first argument is the command name. cmd="$nonopt" if test -z "$cmd"; then $echo "$modename: you must specify a COMMAND" 1>&2 $echo "$help" exit $EXIT_FAILURE fi # Handle -dlopen flags immediately. for file in $execute_dlfiles; do if test ! -f "$file"; then $echo "$modename: \`$file' is not a file" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi dir= case $file in *.la) # Check to see that this really is a libtool archive. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : else $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Read the libtool library. dlname= library_names= # If there is no directory component, then add one. case $file in */* | *\\*) . $file ;; *) . ./$file ;; esac # Skip this library if it cannot be dlopened. if test -z "$dlname"; then # Warn if it was a shared library. test -n "$library_names" && $echo "$modename: warning: \`$file' was not linked with \`-export-dynamic'" continue fi dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "X$dir" = "X$file" && dir=. if test -f "$dir/$objdir/$dlname"; then dir="$dir/$objdir" else if test ! -f "$dir/$dlname"; then $echo "$modename: cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" 1>&2 exit $EXIT_FAILURE fi fi ;; *.lo) # Just add the directory containing the .lo file. dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "X$dir" = "X$file" && dir=. ;; *) $echo "$modename: warning \`-dlopen' is ignored for non-libtool libraries and objects" 1>&2 continue ;; esac # Get the absolute pathname. absdir=`cd "$dir" && pwd` test -n "$absdir" && dir="$absdir" # Now add the directory to shlibpath_var. if eval "test -z \"\$$shlibpath_var\""; then eval "$shlibpath_var=\"\$dir\"" else eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" fi done # This variable tells wrapper scripts just to set shlibpath_var # rather than running their programs. libtool_execute_magic="$magic" # Check if any of the arguments is a wrapper script. args= for file do case $file in -*) ;; *) # Do a test to see if this is really a libtool program. if (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then # If there is no directory component, then add one. case $file in */* | *\\*) . $file ;; *) . ./$file ;; esac # Transform arg to wrapped name. file="$progdir/$program" fi ;; esac # Quote arguments (to preserve shell metacharacters). file=`$echo "X$file" | $Xsed -e "$sed_quote_subst"` args="$args \"$file\"" done if test -z "$run"; then if test -n "$shlibpath_var"; then # Export the shlibpath_var. eval "export $shlibpath_var" fi # Restore saved environment variables for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES do eval "if test \"\${save_$lt_var+set}\" = set; then $lt_var=\$save_$lt_var; export $lt_var fi" done # Now prepare to actually exec the command. exec_cmd="\$cmd$args" else # Display what would be done. if test -n "$shlibpath_var"; then eval "\$echo \"\$shlibpath_var=\$$shlibpath_var\"" $echo "export $shlibpath_var" fi $echo "$cmd$args" exit $EXIT_SUCCESS fi ;; # libtool clean and uninstall mode clean | uninstall) modename="$modename: $mode" rm="$nonopt" files= rmforce= exit_status=0 # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic="$magic" for arg do case $arg in -f) rm="$rm $arg"; rmforce=yes ;; -*) rm="$rm $arg" ;; *) files="$files $arg" ;; esac done if test -z "$rm"; then $echo "$modename: you must specify an RM program" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi rmdirs= origobjdir="$objdir" for file in $files; do dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` if test "X$dir" = "X$file"; then dir=. objdir="$origobjdir" else objdir="$dir/$origobjdir" fi name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` test "$mode" = uninstall && objdir="$dir" # Remember objdir for removal later, being careful to avoid duplicates if test "$mode" = clean; then case " $rmdirs " in *" $objdir "*) ;; *) rmdirs="$rmdirs $objdir" ;; esac fi # Don't error if the file doesn't exist and rm -f was used. if (test -L "$file") >/dev/null 2>&1 \ || (test -h "$file") >/dev/null 2>&1 \ || test -f "$file"; then : elif test -d "$file"; then exit_status=1 continue elif test "$rmforce" = yes; then continue fi rmfiles="$file" case $name in *.la) # Possibly a libtool archive, so verify it. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then . $dir/$name # Delete the libtool libraries and symlinks. for n in $library_names; do rmfiles="$rmfiles $objdir/$n" done test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" case "$mode" in clean) case " $library_names " in # " " in the beginning catches empty $dlname *" $dlname "*) ;; *) rmfiles="$rmfiles $objdir/$dlname" ;; esac test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" ;; uninstall) if test -n "$library_names"; then # Do each command in the postuninstall commands. cmds=$postuninstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" if test "$?" -ne 0 && test "$rmforce" != yes; then exit_status=1 fi done IFS="$save_ifs" fi if test -n "$old_library"; then # Do each command in the old_postuninstall commands. cmds=$old_postuninstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" if test "$?" -ne 0 && test "$rmforce" != yes; then exit_status=1 fi done IFS="$save_ifs" fi # FIXME: should reinstall the best remaining shared library. ;; esac fi ;; *.lo) # Possibly a libtool object, so verify it. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then # Read the .lo file . $dir/$name # Add PIC object to the list of files to remove. if test -n "$pic_object" \ && test "$pic_object" != none; then rmfiles="$rmfiles $dir/$pic_object" fi # Add non-PIC object to the list of files to remove. if test -n "$non_pic_object" \ && test "$non_pic_object" != none; then rmfiles="$rmfiles $dir/$non_pic_object" fi fi ;; *) if test "$mode" = clean ; then noexename=$name case $file in *.exe) file=`$echo $file|${SED} 's,.exe$,,'` noexename=`$echo $name|${SED} 's,.exe$,,'` # $file with .exe has already been added to rmfiles, # add $file without .exe rmfiles="$rmfiles $file" ;; esac # Do a test to see if this is a libtool program. if (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then relink_command= . $dir/$noexename # note $name still contains .exe if it was in $file originally # as does the version of $file that was added into $rmfiles rmfiles="$rmfiles $objdir/$name $objdir/${name}S.${objext}" if test "$fast_install" = yes && test -n "$relink_command"; then rmfiles="$rmfiles $objdir/lt-$name" fi if test "X$noexename" != "X$name" ; then rmfiles="$rmfiles $objdir/lt-${noexename}.c" fi fi fi ;; esac $show "$rm $rmfiles" $run $rm $rmfiles || exit_status=1 done objdir="$origobjdir" # Try to remove the ${objdir}s in the directories where we deleted files for dir in $rmdirs; do if test -d "$dir"; then $show "rmdir $dir" $run rmdir $dir >/dev/null 2>&1 fi done exit $exit_status ;; "") $echo "$modename: you must specify a MODE" 1>&2 $echo "$generic_help" 1>&2 exit $EXIT_FAILURE ;; esac if test -z "$exec_cmd"; then $echo "$modename: invalid operation mode \`$mode'" 1>&2 $echo "$generic_help" 1>&2 exit $EXIT_FAILURE fi fi # test -z "$show_help" if test -n "$exec_cmd"; then eval exec $exec_cmd exit $EXIT_FAILURE fi # We need to display help for each of the modes. case $mode in "") $echo \ "Usage: $modename [OPTION]... [MODE-ARG]... Provide generalized library-building support services. --config show all configuration variables --debug enable verbose shell tracing -n, --dry-run display commands without modifying any files --features display basic configuration information and exit --finish same as \`--mode=finish' --help display this help message and exit --mode=MODE use operation mode MODE [default=inferred from MODE-ARGS] --quiet same as \`--silent' --silent don't print informational messages --tag=TAG use configuration variables from tag TAG --version print version information MODE must be one of the following: clean remove files from the build directory compile compile a source file into a libtool object execute automatically set library path, then run a program finish complete the installation of libtool libraries install install libraries or executables link create a library or an executable uninstall remove libraries from an installed directory MODE-ARGS vary depending on the MODE. Try \`$modename --help --mode=MODE' for a more detailed description of MODE. Report bugs to ." exit $EXIT_SUCCESS ;; clean) $echo \ "Usage: $modename [OPTION]... --mode=clean RM [RM-OPTION]... FILE... Remove files from the build directory. RM is the name of the program to use to delete files associated with each FILE (typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed to RM. If FILE is a libtool library, object or program, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; compile) $echo \ "Usage: $modename [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE Compile a source file into a libtool library object. This mode accepts the following additional options: -o OUTPUT-FILE set the output file name to OUTPUT-FILE -prefer-pic try to building PIC objects only -prefer-non-pic try to building non-PIC objects only -static always build a \`.o' file suitable for static linking COMPILE-COMMAND is a command to be used in creating a \`standard' object file from the given SOURCEFILE. The output file name is determined by removing the directory component from SOURCEFILE, then substituting the C source code suffix \`.c' with the library object suffix, \`.lo'." ;; execute) $echo \ "Usage: $modename [OPTION]... --mode=execute COMMAND [ARGS]... Automatically set library path, then run a program. This mode accepts the following additional options: -dlopen FILE add the directory containing FILE to the library path This mode sets the library path environment variable according to \`-dlopen' flags. If any of the ARGS are libtool executable wrappers, then they are translated into their corresponding uninstalled binary, and any of their required library directories are added to the library path. Then, COMMAND is executed, with ARGS as arguments." ;; finish) $echo \ "Usage: $modename [OPTION]... --mode=finish [LIBDIR]... Complete the installation of libtool libraries. Each LIBDIR is a directory that contains libtool libraries. The commands that this mode executes may require superuser privileges. Use the \`--dry-run' option if you just want to see what would be executed." ;; install) $echo \ "Usage: $modename [OPTION]... --mode=install INSTALL-COMMAND... Install executables or libraries. INSTALL-COMMAND is the installation command. The first component should be either the \`install' or \`cp' program. The rest of the components are interpreted as arguments to that command (only BSD-compatible install options are recognized)." ;; link) $echo \ "Usage: $modename [OPTION]... --mode=link LINK-COMMAND... Link object files or libraries together to form another library, or to create an executable program. LINK-COMMAND is a command using the C compiler that you would use to create a program from several object files. The following components of LINK-COMMAND are treated specially: -all-static do not do any dynamic linking at all -avoid-version do not add a version suffix if possible -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) -export-symbols SYMFILE try to export only the symbols listed in SYMFILE -export-symbols-regex REGEX try to export only the symbols matching REGEX -LLIBDIR search LIBDIR for required installed libraries -lNAME OUTPUT-FILE requires the installed library libNAME -module build a library that can dlopened -no-fast-install disable the fast-install mode -no-install link a not-installable executable -no-undefined declare that a library does not refer to external symbols -o OUTPUT-FILE create OUTPUT-FILE from the specified objects -objectlist FILE Use a list of object files found in FILE to specify objects -precious-files-regex REGEX don't remove output files matching REGEX -release RELEASE specify package release information -rpath LIBDIR the created library will eventually be installed in LIBDIR -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries -static do not do any dynamic linking of uninstalled libtool libraries -static-libtool-libs do not do any dynamic linking of libtool libraries -version-info CURRENT[:REVISION[:AGE]] specify library version info [each variable defaults to 0] All other options (arguments beginning with \`-') are ignored. Every other argument is treated as a filename. Files ending in \`.la' are treated as uninstalled libtool libraries, other files are standard or library object files. If the OUTPUT-FILE ends in \`.la', then a libtool library is created, only library objects (\`.lo' files) may be specified, and \`-rpath' is required, except when creating a convenience library. If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created using \`ar' and \`ranlib', or on Windows using \`lib'. If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file is created, otherwise an executable program is created." ;; uninstall) $echo \ "Usage: $modename [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... Remove libraries from an installation directory. RM is the name of the program to use to delete files associated with each FILE (typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed to RM. If FILE is a libtool library, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; *) $echo "$modename: invalid operation mode \`$mode'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; esac $echo $echo "Try \`$modename --help' for more information about other modes." exit $? # The TAGs below are defined such that we never get into a situation # in which we disable both kinds of libraries. Given conflicting # choices, we go for a static library, that is the most portable, # since we can't tell whether shared libraries were disabled because # the user asked for that or because the platform doesn't support # them. This is particularly important on AIX, because we don't # support having both static and shared libraries enabled at the same # time on that platform, so we default to a shared-only configuration. # If a disable-shared tag is given, we'll fallback to a static-only # configuration. But we'll never go from static-only to shared-only. # ### BEGIN LIBTOOL TAG CONFIG: disable-shared disable_libs=shared # ### END LIBTOOL TAG CONFIG: disable-shared # ### BEGIN LIBTOOL TAG CONFIG: disable-static disable_libs=static # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: # mode:shell-script # sh-indentation:2 # End: # ### BEGIN LIBTOOL TAG CONFIG: CXX # Libtool was configured on host merlot.usc.edu: # Shell to use when invoking shell scripts. SHELL="/bin/sh" # Whether or not to build shared libraries. build_libtool_libs=yes # Whether or not to build static libraries. build_old_libs=yes # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=no # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=no # Whether or not to optimize for fast installation. fast_install=yes # The host system. host_alias= host=i686-pc-linux-gnu host_os=linux-gnu # The build system. build_alias= build=i686-pc-linux-gnu build_os=linux-gnu # An echo program that does not interpret backslashes. echo="echo" # The archiver. AR="ar" AR_FLAGS="cru" # A C compiler. LTCC="gcc" # LTCC compiler flags. LTCFLAGS="-g -O2" # A language-specific compiler. CC="g++" # Is the compiler the GNU C compiler? with_gcc=yes # An ERE matcher. EGREP="/bin/grep -E" # The linker used to build libraries. LD="/usr/bin/ld" # Whether we need hard or soft links. LN_S="ln -s" # A BSD-compatible nm program. NM="/usr/bin/nm -B" # A symbol stripping program STRIP="strip" # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=file # Used on cygwin: DLL creation program. DLLTOOL="dlltool" # Used on cygwin: object dumper. OBJDUMP="objdump" # Used on cygwin: assembler. AS="as" # The name of the directory that contains temporary libtool files. objdir=.libs # How to create reloadable object files. reload_flag=" -r" reload_cmds="\$LD\$reload_flag -o \$output\$reload_objs" # How to pass a linker flag through the compiler. wl="-Wl," # Object file suffix (normally "o"). objext="o" # Old archive suffix (normally "a"). libext="a" # Shared library suffix (normally ".so"). shrext_cmds='.so' # Executable file suffix (normally ""). exeext="" # Additional compiler flags for building library objects. pic_flag=" -fPIC -DPIC" pic_mode=default # What is the maximum length of a command? max_cmd_len=98304 # Does compiler simultaneously support -c and -o options? compiler_c_o="yes" # Must we lock files when doing compilation? need_locks="no" # Do we need the lib prefix for modules? need_lib_prefix=no # Do we need a version for libraries? need_version=no # Whether dlopen is supported. dlopen_support=unknown # Whether dlopen of programs is supported. dlopen_self=unknown # Whether dlopen of statically linked programs is supported. dlopen_self_static=unknown # Compiler flag to prevent dynamic linking. link_static_flag="-static" # Compiler flag to turn off builtin functions. no_builtin_flag=" -fno-builtin" # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec="\${wl}--export-dynamic" # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec="\${wl}--whole-archive\$convenience \${wl}--no-whole-archive" # Compiler flag to generate thread-safe objects. thread_safe_flag_spec="" # Library versioning type. version_type=linux # Format of library name prefix. libname_spec="lib\$name" # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec="\${libname}\${release}\${shared_ext}\$versuffix \${libname}\${release}\${shared_ext}\$major \$libname\${shared_ext}" # The coded name of the library, if different from the real name. soname_spec="\${libname}\${release}\${shared_ext}\$major" # Commands used to build and install an old-style archive. RANLIB="ranlib" old_archive_cmds="\$AR \$AR_FLAGS \$oldlib\$oldobjs~\$RANLIB \$oldlib" old_postinstall_cmds="chmod 644 \$oldlib~\$RANLIB \$oldlib" old_postuninstall_cmds="" # Create an old-style archive from a shared archive. old_archive_from_new_cmds="" # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds="" # Commands used to build and install a shared archive. archive_cmds="\$CC -shared -nostdlib \$predep_objects \$libobjs \$deplibs \$postdep_objects \$compiler_flags \${wl}-soname \$wl\$soname -o \$lib" archive_expsym_cmds="\$CC -shared -nostdlib \$predep_objects \$libobjs \$deplibs \$postdep_objects \$compiler_flags \${wl}-soname \$wl\$soname \${wl}-retain-symbols-file \$wl\$export_symbols -o \$lib" postinstall_cmds="" postuninstall_cmds="" # Commands used to build a loadable module (assumed same as above if empty) module_cmds="" module_expsym_cmds="" # Commands to strip libraries. old_striplib="strip --strip-debug" striplib="strip --strip-unneeded" # Dependencies to place before the objects being linked to create a # shared library. predep_objects="/usr/lib/gcc/i386-redhat-linux/4.1.2/../../../crti.o /usr/lib/gcc/i386-redhat-linux/4.1.2/crtbeginS.o" # Dependencies to place after the objects being linked to create a # shared library. postdep_objects="/usr/lib/gcc/i386-redhat-linux/4.1.2/crtendS.o /usr/lib/gcc/i386-redhat-linux/4.1.2/../../../crtn.o" # Dependencies to place before the objects being linked to create a # shared library. predeps="" # Dependencies to place after the objects being linked to create a # shared library. postdeps="-lstdc++ -lm -lgcc_s -lc -lgcc_s" # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs="/usr/lib/gcc/i386-redhat-linux/4.1.2 /usr/lib/gcc/i386-redhat-linux/4.1.2 /usr/lib/gcc/i386-redhat-linux/4.1.2/../../.." # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path="-L/usr/lib/gcc/i386-redhat-linux/4.1.2 -L/usr/lib/gcc/i386-redhat-linux/4.1.2 -L/usr/lib/gcc/i386-redhat-linux/4.1.2/../../.." # Method to check whether dependent libraries are shared objects. deplibs_check_method="pass_all" # Command to use when deplibs_check_method == file_magic. file_magic_cmd="\$MAGIC_CMD" # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag="" # Flag that forces no undefined symbols. no_undefined_flag="" # Commands used to finish a libtool library installation in a directory. finish_cmds="PATH=\\\"\\\$PATH:/sbin\\\" ldconfig -n \$libdir" # Same as above, but a single script fragment to be evaled but not shown. finish_eval="" # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe="sed -n -e 's/^.*[ ]\\([ABCDGIRSTW][ABCDGIRSTW]*\\)[ ][ ]*\\([_A-Za-z][_A-Za-z0-9]*\\)\$/\\1 \\2 \\2/p'" # Transform the output of nm in a proper C declaration global_symbol_to_cdecl="sed -n -e 's/^. .* \\(.*\\)\$/extern int \\1;/p'" # Transform the output of nm in a C name address pair global_symbol_to_c_name_address="sed -n -e 's/^: \\([^ ]*\\) \$/ {\\\"\\1\\\", (lt_ptr) 0},/p' -e 's/^[BCDEGRST] \\([^ ]*\\) \\([^ ]*\\)\$/ {\"\\2\", (lt_ptr) \\&\\2},/p'" # This is the shared library runtime path variable. runpath_var=LD_RUN_PATH # This is the shared library path variable. shlibpath_var=LD_LIBRARY_PATH # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=no # How to hardcode a shared library path into an executable. hardcode_action=immediate # Whether we should hardcode library paths into libraries. hardcode_into_libs=yes # Flag to hardcode $libdir into a binary during linking. # This must work even if $libdir does not exist. hardcode_libdir_flag_spec="\${wl}--rpath \${wl}\$libdir" # If ld is used when linking, flag to hardcode $libdir into # a binary during linking. This must work even if $libdir does # not exist. hardcode_libdir_flag_spec_ld="" # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator="" # Set to yes if using DIR/libNAME during linking hardcodes DIR into the # resulting binary. hardcode_direct=no # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=no # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=unsupported # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=no # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="PATH LD_LIBRARY_PATH LD_RUN_PATH GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=no # Compile-time system search path for libraries sys_lib_search_path_spec="/usr/lib/gcc/i386-redhat-linux/4.1.2 /usr/lib /lib" # Run-time system search path for libraries sys_lib_dlsearch_path_spec="/lib /usr/lib /usr/lib/mysql /usr/lib/opensync/ /usr/lib/opensync/formats/ /usr/lib/opensync/plugins/ /usr/lib/qt-3.3/lib " # Fix the shell variable $srcfile for the compiler. fix_srcfile_path="" # Set to yes if exported symbols are required. always_export_symbols=no # The commands to list exported symbols. export_symbols_cmds="\$NM \$libobjs \$convenience | \$global_symbol_pipe | \$SED 's/.* //' | sort | uniq > \$export_symbols" # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds="" # Symbols that should not be listed in the preloaded symbols. exclude_expsyms="_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*" # Symbols that must always be exported. include_expsyms="" # ### END LIBTOOL TAG CONFIG: CXX # ### BEGIN LIBTOOL TAG CONFIG: F77 # Libtool was configured on host merlot.usc.edu: # Shell to use when invoking shell scripts. SHELL="/bin/sh" # Whether or not to build shared libraries. build_libtool_libs=yes # Whether or not to build static libraries. build_old_libs=yes # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=no # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=no # Whether or not to optimize for fast installation. fast_install=yes # The host system. host_alias= host=i686-pc-linux-gnu host_os=linux-gnu # The build system. build_alias= build=i686-pc-linux-gnu build_os=linux-gnu # An echo program that does not interpret backslashes. echo="echo" # The archiver. AR="ar" AR_FLAGS="cru" # A C compiler. LTCC="gcc" # LTCC compiler flags. LTCFLAGS="-g -O2" # A language-specific compiler. CC="gfortran" # Is the compiler the GNU C compiler? with_gcc=yes # An ERE matcher. EGREP="/bin/grep -E" # The linker used to build libraries. LD="/usr/bin/ld" # Whether we need hard or soft links. LN_S="ln -s" # A BSD-compatible nm program. NM="/usr/bin/nm -B" # A symbol stripping program STRIP="strip" # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=file # Used on cygwin: DLL creation program. DLLTOOL="dlltool" # Used on cygwin: object dumper. OBJDUMP="objdump" # Used on cygwin: assembler. AS="as" # The name of the directory that contains temporary libtool files. objdir=.libs # How to create reloadable object files. reload_flag=" -r" reload_cmds="\$LD\$reload_flag -o \$output\$reload_objs" # How to pass a linker flag through the compiler. wl="-Wl," # Object file suffix (normally "o"). objext="o" # Old archive suffix (normally "a"). libext="a" # Shared library suffix (normally ".so"). shrext_cmds='.so' # Executable file suffix (normally ""). exeext="" # Additional compiler flags for building library objects. pic_flag=" -fPIC" pic_mode=default # What is the maximum length of a command? max_cmd_len=98304 # Does compiler simultaneously support -c and -o options? compiler_c_o="yes" # Must we lock files when doing compilation? need_locks="no" # Do we need the lib prefix for modules? need_lib_prefix=no # Do we need a version for libraries? need_version=no # Whether dlopen is supported. dlopen_support=unknown # Whether dlopen of programs is supported. dlopen_self=unknown # Whether dlopen of statically linked programs is supported. dlopen_self_static=unknown # Compiler flag to prevent dynamic linking. link_static_flag="-static" # Compiler flag to turn off builtin functions. no_builtin_flag="" # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec="\${wl}--export-dynamic" # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec="\${wl}--whole-archive\$convenience \${wl}--no-whole-archive" # Compiler flag to generate thread-safe objects. thread_safe_flag_spec="" # Library versioning type. version_type=linux # Format of library name prefix. libname_spec="lib\$name" # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec="\${libname}\${release}\${shared_ext}\$versuffix \${libname}\${release}\${shared_ext}\$major \$libname\${shared_ext}" # The coded name of the library, if different from the real name. soname_spec="\${libname}\${release}\${shared_ext}\$major" # Commands used to build and install an old-style archive. RANLIB="ranlib" old_archive_cmds="\$AR \$AR_FLAGS \$oldlib\$oldobjs~\$RANLIB \$oldlib" old_postinstall_cmds="chmod 644 \$oldlib~\$RANLIB \$oldlib" old_postuninstall_cmds="" # Create an old-style archive from a shared archive. old_archive_from_new_cmds="" # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds="" # Commands used to build and install a shared archive. archive_cmds="\$CC -shared \$libobjs \$deplibs \$compiler_flags \${wl}-soname \$wl\$soname -o \$lib" archive_expsym_cmds="\$echo \\\"{ global:\\\" > \$output_objdir/\$libname.ver~ cat \$export_symbols | sed -e \\\"s/\\\\(.*\\\\)/\\\\1;/\\\" >> \$output_objdir/\$libname.ver~ \$echo \\\"local: *; };\\\" >> \$output_objdir/\$libname.ver~ \$CC -shared \$libobjs \$deplibs \$compiler_flags \${wl}-soname \$wl\$soname \${wl}-version-script \${wl}\$output_objdir/\$libname.ver -o \$lib" postinstall_cmds="" postuninstall_cmds="" # Commands used to build a loadable module (assumed same as above if empty) module_cmds="" module_expsym_cmds="" # Commands to strip libraries. old_striplib="strip --strip-debug" striplib="strip --strip-unneeded" # Dependencies to place before the objects being linked to create a # shared library. predep_objects="" # Dependencies to place after the objects being linked to create a # shared library. postdep_objects="" # Dependencies to place before the objects being linked to create a # shared library. predeps="" # Dependencies to place after the objects being linked to create a # shared library. postdeps="" # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs="" # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path="" # Method to check whether dependent libraries are shared objects. deplibs_check_method="pass_all" # Command to use when deplibs_check_method == file_magic. file_magic_cmd="\$MAGIC_CMD" # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag="" # Flag that forces no undefined symbols. no_undefined_flag="" # Commands used to finish a libtool library installation in a directory. finish_cmds="PATH=\\\"\\\$PATH:/sbin\\\" ldconfig -n \$libdir" # Same as above, but a single script fragment to be evaled but not shown. finish_eval="" # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe="sed -n -e 's/^.*[ ]\\([ABCDGIRSTW][ABCDGIRSTW]*\\)[ ][ ]*\\([_A-Za-z][_A-Za-z0-9]*\\)\$/\\1 \\2 \\2/p'" # Transform the output of nm in a proper C declaration global_symbol_to_cdecl="sed -n -e 's/^. .* \\(.*\\)\$/extern int \\1;/p'" # Transform the output of nm in a C name address pair global_symbol_to_c_name_address="sed -n -e 's/^: \\([^ ]*\\) \$/ {\\\"\\1\\\", (lt_ptr) 0},/p' -e 's/^[BCDEGRST] \\([^ ]*\\) \\([^ ]*\\)\$/ {\"\\2\", (lt_ptr) \\&\\2},/p'" # This is the shared library runtime path variable. runpath_var=LD_RUN_PATH # This is the shared library path variable. shlibpath_var=LD_LIBRARY_PATH # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=no # How to hardcode a shared library path into an executable. hardcode_action=immediate # Whether we should hardcode library paths into libraries. hardcode_into_libs=yes # Flag to hardcode $libdir into a binary during linking. # This must work even if $libdir does not exist. hardcode_libdir_flag_spec="\${wl}--rpath \${wl}\$libdir" # If ld is used when linking, flag to hardcode $libdir into # a binary during linking. This must work even if $libdir does # not exist. hardcode_libdir_flag_spec_ld="" # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator="" # Set to yes if using DIR/libNAME during linking hardcodes DIR into the # resulting binary. hardcode_direct=no # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=no # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=unsupported # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=no # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="PATH LD_LIBRARY_PATH LD_RUN_PATH GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=no # Compile-time system search path for libraries sys_lib_search_path_spec="/usr/lib/gcc/i386-redhat-linux/4.1.2 /usr/lib /lib" # Run-time system search path for libraries sys_lib_dlsearch_path_spec="/lib /usr/lib /usr/lib/mysql /usr/lib/opensync/ /usr/lib/opensync/formats/ /usr/lib/opensync/plugins/ /usr/lib/qt-3.3/lib " # Fix the shell variable $srcfile for the compiler. fix_srcfile_path="" # Set to yes if exported symbols are required. always_export_symbols=no # The commands to list exported symbols. export_symbols_cmds="\$NM \$libobjs \$convenience | \$global_symbol_pipe | \$SED 's/.* //' | sort | uniq > \$export_symbols" # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds="" # Symbols that should not be listed in the preloaded symbols. exclude_expsyms="_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*" # Symbols that must always be exported. include_expsyms="" # ### END LIBTOOL TAG CONFIG: F77 tgif-QPL-4.2.5/rmcast/config.h.in0000644000076400007640000001354611113321725016314 0ustar williamwilliam/* config.h.in. Generated from configure.in by autoheader. */ /* Define to 1 if the `closedir' function returns void instead of `int'. */ #undef CLOSEDIR_VOID /* Define to 1 if you have the `alarm' function. */ #undef HAVE_ALARM /* Define to 1 if you have the header file. */ #undef HAVE_ARPA_INET_H /* Define to 1 if you have the `bzero' function. */ #undef HAVE_BZERO /* Define to 1 if you have the declaration of `sys_siglist', and to 0 if you don't. */ #undef HAVE_DECL_SYS_SIGLIST /* Define to 1 if you have the header file, and it defines `DIR'. */ #undef HAVE_DIRENT_H /* Define to 1 if you have the header file. */ #undef HAVE_DLFCN_H /* Define to 1 if you have the `fork' function. */ #undef HAVE_FORK /* Define to 1 if you have the `gethostbyname' function. */ #undef HAVE_GETHOSTBYNAME /* Define to 1 if you have the `gethostname' function. */ #undef HAVE_GETHOSTNAME /* Define to 1 if you have the `gettimeofday' function. */ #undef HAVE_GETTIMEOFDAY /* Define to 1 if you have the `inet_ntoa' function. */ #undef HAVE_INET_NTOA /* Define to 1 if you have the header file. */ #undef HAVE_INTTYPES_H /* Define to 1 if you have the `m' library (-lm). */ #undef HAVE_LIBM /* Define to 1 if you have the `pthread' library (-lpthread). */ #undef HAVE_LIBPTHREAD /* Define to 1 if your system has a GNU libc compatible `malloc' function, and to 0 otherwise. */ #undef HAVE_MALLOC /* Define to 1 if you have the header file. */ #undef HAVE_MEMORY_H /* Define to 1 if you have the `memset' function. */ #undef HAVE_MEMSET /* Define to 1 if you have the header file, and it defines `DIR'. */ #undef HAVE_NDIR_H /* Define to 1 if you have the header file. */ #undef HAVE_NETDB_H /* Define to 1 if you have the header file. */ #undef HAVE_NETINET_IN_H /* Define to 1 if you have the `pow' function. */ #undef HAVE_POW /* Define to 1 if you have the `putenv' function. */ #undef HAVE_PUTENV /* Define to 1 if your system has a GNU libc compatible `realloc' function, and to 0 otherwise. */ #undef HAVE_REALLOC /* Define to 1 if you have the `select' function. */ #undef HAVE_SELECT /* Define to 1 if you have the `setlocale' function. */ #undef HAVE_SETLOCALE /* Define to 1 if you have the `socket' function. */ #undef HAVE_SOCKET /* Define to 1 if you have the header file. */ #undef HAVE_STDINT_H /* Define to 1 if you have the header file. */ #undef HAVE_STDLIB_H /* Define to 1 if you have the `strchr' function. */ #undef HAVE_STRCHR /* Define to 1 if you have the `strdup' function. */ #undef HAVE_STRDUP /* Define to 1 if you have the `strerror' function. */ #undef HAVE_STRERROR /* Define to 1 if you have the header file. */ #undef HAVE_STRINGS_H /* Define to 1 if you have the header file. */ #undef HAVE_STRING_H /* Define to 1 if you have the `strstr' function. */ #undef HAVE_STRSTR /* Define to 1 if you have the header file, and it defines `DIR'. */ #undef HAVE_SYS_DIR_H /* Define to 1 if you have the header file, and it defines `DIR'. */ #undef HAVE_SYS_NDIR_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_SELECT_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_SOCKET_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_STAT_H /* Define to 1 if you have the header file. */ #undef HAVE_SYS_TYPES_H /* Define to 1 if you have the header file. */ #undef HAVE_UNISTD_H /* Define to 1 if you have the `vfork' function. */ #undef HAVE_VFORK /* Define to 1 if you have the header file. */ #undef HAVE_VFORK_H /* Define to 1 if `fork' works. */ #undef HAVE_WORKING_FORK /* Define to 1 if `vfork' works. */ #undef HAVE_WORKING_VFORK /* Name of package */ #undef PACKAGE /* Define to the address where bug reports for this package should be sent. */ #undef PACKAGE_BUGREPORT /* Define to the full name of this package. */ #undef PACKAGE_NAME /* Define to the full name and version of this package. */ #undef PACKAGE_STRING /* Define to the one symbol short name of this package. */ #undef PACKAGE_TARNAME /* Define to the version of this package. */ #undef PACKAGE_VERSION /* Define to 1 if the C compiler supports function prototypes. */ #undef PROTOTYPES /* Define as the return type of signal handlers (`int' or `void'). */ #undef RETSIGTYPE /* Define to the type of arg 1 for `select'. */ #undef SELECT_TYPE_ARG1 /* Define to the type of args 2, 3 and 4 for `select'. */ #undef SELECT_TYPE_ARG234 /* Define to the type of arg 5 for `select'. */ #undef SELECT_TYPE_ARG5 /* Define to 1 if the `setvbuf' function takes the buffering type as its second argument and the buffer pointer as the third, as on System V before release 3. */ #undef SETVBUF_REVERSED /* Define to 1 if you have the ANSI C header files. */ #undef STDC_HEADERS /* Define to 1 if you can safely include both and . */ #undef TIME_WITH_SYS_TIME /* Define to 1 if your declares `struct tm'. */ #undef TM_IN_SYS_TIME /* Version number of package */ #undef VERSION /* Define like PROTOTYPES; this can be used by system headers. */ #undef __PROTOTYPES /* Define to empty if `const' does not conform to ANSI C. */ #undef const /* Define to `__inline__' or `__inline' if that's what the C compiler calls it, or to nothing if 'inline' is not supported under any name. */ #ifndef __cplusplus #undef inline #endif /* Define to rpl_malloc if the replacement function should be used. */ #undef malloc /* Define to `int' if does not define. */ #undef pid_t /* Define to rpl_realloc if the replacement function should be used. */ #undef realloc /* Define to `unsigned int' if does not define. */ #undef size_t /* Define as `fork' if `vfork' does not work. */ #undef vfork tgif-QPL-4.2.5/rmcast/rmchat/0000755000076400007640000000000011602233155015540 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/rmchat/Makefile.in0000644000076400007640000003665411566506143017634 0ustar williamwilliam# Makefile.in generated by automake 1.9.6 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = .. am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ bin_PROGRAMS = rmchat$(EXEEXT) subdir = rmchat DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/configure.in am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/config/mkinstalldirs CONFIG_HEADER = $(top_builddir)/config.h CONFIG_CLEAN_FILES = am__installdirs = "$(DESTDIR)$(bindir)" binPROGRAMS_INSTALL = $(INSTALL_PROGRAM) PROGRAMS = $(bin_PROGRAMS) am_rmchat_OBJECTS = rmchat-rmchat.$(OBJEXT) rmchat_OBJECTS = $(am_rmchat_OBJECTS) rmchat_DEPENDENCIES = DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir) depcomp = $(SHELL) $(top_srcdir)/config/depcomp am__depfiles_maybe = depfiles COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) LTCOMPILE = $(LIBTOOL) --tag=CC --mode=compile $(CC) $(DEFS) \ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \ $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(LIBTOOL) --tag=CC --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \ $(AM_LDFLAGS) $(LDFLAGS) -o $@ SOURCES = $(rmchat_SOURCES) DIST_SOURCES = $(rmchat_SOURCES) ETAGS = etags CTAGS = ctags DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) ACLOCAL = @ACLOCAL@ AMDEP_FALSE = @AMDEP_FALSE@ AMDEP_TRUE = @AMDEP_TRUE@ AMTAR = @AMTAR@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DSYMUTIL = @DSYMUTIL@ ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ F77 = @F77@ FFLAGS = @FFLAGS@ GREP = @GREP@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ NMEDIT = @NMEDIT@ OBJEXT = @OBJEXT@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ VERSION = @VERSION@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_F77 = @ac_ct_F77@ am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@ am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ rmchat_SOURCES = rmchat.c rmchat_LDADD = -L../src/.libs/ -lrmcast rmchat_CFLAGS = -Wall INCLUDES = -I../src all: all-am .SUFFIXES: .SUFFIXES: .c .lo .o .obj $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu rmchat/Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --gnu rmchat/Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(top_srcdir)/configure: $(am__configure_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) test -z "$(bindir)" || $(mkdir_p) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; for p in $$list; do \ p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ if test -f $$p \ || test -f $$p1 \ ; then \ f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \ echo " $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ $(INSTALL_PROGRAM_ENV) $(LIBTOOL) --mode=install $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ else :; fi; \ done uninstall-binPROGRAMS: @$(NORMAL_UNINSTALL) @list='$(bin_PROGRAMS)'; for p in $$list; do \ f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \ echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \ rm -f "$(DESTDIR)$(bindir)/$$f"; \ done clean-binPROGRAMS: @list='$(bin_PROGRAMS)'; for p in $$list; do \ f=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ echo " rm -f $$p $$f"; \ rm -f $$p $$f ; \ done rmchat$(EXEEXT): $(rmchat_OBJECTS) $(rmchat_DEPENDENCIES) @rm -f rmchat$(EXEEXT) $(LINK) $(rmchat_LDFLAGS) $(rmchat_OBJECTS) $(rmchat_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rmchat-rmchat.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c $< .c.obj: @am__fastdepCC_TRUE@ if $(COMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ `$(CYGPATH_W) '$<'`; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` .c.lo: @am__fastdepCC_TRUE@ if $(LTCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Plo"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(LTCOMPILE) -c -o $@ $< rmchat-rmchat.o: rmchat.c @am__fastdepCC_TRUE@ if $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(rmchat_CFLAGS) $(CFLAGS) -MT rmchat-rmchat.o -MD -MP -MF "$(DEPDIR)/rmchat-rmchat.Tpo" -c -o rmchat-rmchat.o `test -f 'rmchat.c' || echo '$(srcdir)/'`rmchat.c; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/rmchat-rmchat.Tpo" "$(DEPDIR)/rmchat-rmchat.Po"; else rm -f "$(DEPDIR)/rmchat-rmchat.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='rmchat.c' object='rmchat-rmchat.o' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(rmchat_CFLAGS) $(CFLAGS) -c -o rmchat-rmchat.o `test -f 'rmchat.c' || echo '$(srcdir)/'`rmchat.c rmchat-rmchat.obj: rmchat.c @am__fastdepCC_TRUE@ if $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(rmchat_CFLAGS) $(CFLAGS) -MT rmchat-rmchat.obj -MD -MP -MF "$(DEPDIR)/rmchat-rmchat.Tpo" -c -o rmchat-rmchat.obj `if test -f 'rmchat.c'; then $(CYGPATH_W) 'rmchat.c'; else $(CYGPATH_W) '$(srcdir)/rmchat.c'; fi`; \ @am__fastdepCC_TRUE@ then mv -f "$(DEPDIR)/rmchat-rmchat.Tpo" "$(DEPDIR)/rmchat-rmchat.Po"; else rm -f "$(DEPDIR)/rmchat-rmchat.Tpo"; exit 1; fi @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='rmchat.c' object='rmchat-rmchat.obj' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(rmchat_CFLAGS) $(CFLAGS) -c -o rmchat-rmchat.obj `if test -f 'rmchat.c'; then $(CYGPATH_W) 'rmchat.c'; else $(CYGPATH_W) '$(srcdir)/rmchat.c'; fi` mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique; \ fi ctags: CTAGS CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ list='$(DISTFILES)'; for file in $$list; do \ case $$file in \ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ esac; \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkdir_p) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done check-am: all-am check: check-am all-am: Makefile $(PROGRAMS) installdirs: for dir in "$(DESTDIR)$(bindir)"; do \ test -z "$$dir" || $(mkdir_p) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-binPROGRAMS clean-generic clean-libtool mostlyclean-am distclean: distclean-am -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-libtool distclean-tags dvi: dvi-am dvi-am: html: html-am info: info-am info-am: install-data-am: install-exec-am: install-binPROGRAMS install-info: install-info-am install-man: installcheck-am: maintainer-clean: maintainer-clean-am -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic \ mostlyclean-libtool pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-binPROGRAMS uninstall-info-am .PHONY: CTAGS GTAGS all all-am check check-am clean clean-binPROGRAMS \ clean-generic clean-libtool ctags distclean distclean-compile \ distclean-generic distclean-libtool distclean-tags distdir dvi \ dvi-am html html-am info info-am install install-am \ install-binPROGRAMS install-data install-data-am install-exec \ install-exec-am install-info install-info-am install-man \ install-strip installcheck installcheck-am installdirs \ maintainer-clean maintainer-clean-generic mostlyclean \ mostlyclean-compile mostlyclean-generic mostlyclean-libtool \ pdf pdf-am ps ps-am tags uninstall uninstall-am \ uninstall-binPROGRAMS uninstall-info-am # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: tgif-QPL-4.2.5/rmcast/rmchat/Makefile.am0000644000076400007640000000020111073474516017577 0ustar williamwilliambin_PROGRAMS = rmchat rmchat_SOURCES = rmchat.c rmchat_LDADD = -L../src/.libs/ -lrmcast rmchat_CFLAGS = -Wall INCLUDES= -I../src tgif-QPL-4.2.5/rmcast/rmchat/rmchat.c0000644000076400007640000002211711225226450017166 0ustar williamwilliam/*************************************************************************** rmchat.c ------------------- begin : February 2002 copyright : (C) 2002-2009 by Jorge Allyson Azevedo Milena Scanferla Daniel Sadoc email : {allyson,milena,sadoc}@land.ufrj.br This program is a simple chat application that uses the Rmcast Library. ***************************************************************************/ /*************************************************************************** * * * This program is free software; you can redistribute it and/or modify * * it under the terms of the GNU General Public License as published by * * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * * ***************************************************************************/ #include #include #include #include #include #include #include #include #include /* Rmcast Library header */ #define BUFFSIZE 200 /* Max buffer size for messages */ #define TRUE 1 #define FALSE 0 /* Functions */ double generate_sample( float rate ); /* Global Variables */ int chatSock; int end = 0; int not_send_first = 1; void callback_term( void ) { fprintf( stderr, "rmchat exiting ...\n" ); exit( EXIT_SUCCESS ); } /*************************************************************************** * generate_sample( float rate ) * * * * Function to generate random samples with exponetial distribuition. * * * ****************************************************************************/ double generate_sample( float rate ) { double sample,uniform; time_t seed; struct timeval tv; double e,lambda; gettimeofday( &tv, NULL ); seed=time( (time_t *)&tv.tv_sec ); srandom( (unsigned int)seed ); e = exp( 1 ); lambda = rate; uniform = ( (double)random()/(double)RAND_MAX ); sample =-( log(uniform)/lambda ); return sample; } /*************************************************************************** * ReceivePacket * * * * Function (thread) to receive data from the network * * * ****************************************************************************/ void *ReceivePacket( void *arg ) { char receive_buffer[ BUFFSIZE ]; int bytes_read; while( !end ) { if( ( bytes_read = RM_recv( chatSock, receive_buffer, BUFFSIZE ) ) > 0 ) { /* We have received data from the network, show it to the user */ fprintf( stdout,"\n%s>", receive_buffer ); fflush( stdout ); } else { fprintf( stderr, "[ReceivePacket Error]: receiving data.\n" ); break; } } return 0; } int main( int argc, char **argv ) { pthread_t tid; /* Thread Id */ int port; struct timespec sleep_time; char rmcast_version[ 10 ]; char buffer[ BUFFSIZE ]; char aux[ 16 ]; char user_name[ 20 ]; char msg_buff[ BUFFSIZE - 20 ]; tid = 0; port = 0; /* Checking the input parameters */ if( argc != 2 ) { fprintf( stderr, "Usage:\n\t%s \n", argv[ 0 ] ); exit( EXIT_FAILURE ); } /* Setting and trying to read the configuration file first. */ if( !RM_readConfigFile( argv[ 1 ], TRUE ) ) { fprintf( stderr, "[rmchat Error]: Couldn't read config file (%s)\n", argv[ 1 ] ); exit( EXIT_FAILURE ); } /* Initialize the Rmcast Library functions */ RM_initialize( (void *)callback_term ); /* * Join the Multicast Group. * If you want to set a "hardcoded" Multicast group IP and port replace the * RM_USE_CURRENT_CONFIG constants, otherwise we will use the IP and Port * from the configuration file or from the default options */ chatSock = RM_joinGroup( (char*)RM_USE_CURRENT_CONFIG, RM_USE_CURRENT_CONFIG ); RM_getVersion( rmcast_version, sizeof( rmcast_version ) ); fprintf( stdout, "RMCHAT using rmcast version: %s\n", rmcast_version ); fprintf( stdout,"\nEnter a user name (max 16 chars):\n" ); scanf( "%s", user_name ); aux[ 0 ] = '\0'; strcat( aux, "[" ); strcat( aux, user_name ); strcat( aux, "]>" ); fprintf( stdout, "\n*************\nHello %s!\n", user_name ); fprintf( stdout, "Now you can send messages to the Multicast Group!\n" ); fprintf( stdout, "Type \"exit\" if you want to quit the program\n*************\n>" ); /* Now we will create a thread to receive data from the network */ if( pthread_create( &tid, NULL, ReceivePacket, NULL ) != 0 ) { /* Error, terminate the application */ fprintf( stderr, "[rmchat Error]: Could not create Receive Thread\n" ); RM_leaveGroup( chatSock, (char*)RM_USE_CURRENT_CONFIG ); } while( TRUE ) { buffer[ 0 ] = '\0'; /* Now we will read the messages from the standard input */ fgets( msg_buff, BUFFSIZE - 21, stdin ); if( strcmp( msg_buff, "exit\n" ) == 0 ) { /* The user wants to terminate the application */ fprintf( stdout, "\n*************\n" ); fprintf( stdout, "Exiting rmchat ...\n" ); break; } else { if( strcmp( msg_buff, "send\n" ) == 0 ) { /* Send command: will send packets with a number to the group, just for tests purposes */ int j; int num; float rate; char aux2[ 10 ]; long long int aux_sample; char dist[ 3 ]; num = 0; rate = 0; aux_sample = 0; /* Ask the user how many packets we are supposed to send */ fprintf( stdout, "Enter:\n DET \n\tor\n" ); fprintf( stdout, " EXP \n" ); fprintf( stdout, "\t(time in milisseconds and rate in packets/milisseconds)\n" ); scanf( "%s %d %f", dist, &num, &rate ); printf( "num=%d rate=%f\n", num, rate ); for( j = 0; j < num; j++ ) { /*Fill the message with a number */ buffer[ 0 ] = '\0'; strcat( buffer, aux ); sprintf( aux2, "%d\n", j ); strcat( buffer, aux2 ); if( ( strcmp( dist, "EXP" ) == 0 ) ) { aux_sample = (long long int)( 1000000 * generate_sample( rate ) ); } else { aux_sample = (long long int)( rate * 1000000 ); } if( aux_sample >= (1000000000) ) { sleep_time.tv_nsec = aux_sample % 1000000000; sleep_time.tv_sec = (long long int)( aux_sample / 1000000000 ); } else { sleep_time.tv_nsec = aux_sample; sleep_time.tv_sec = 0; } /*printf("sleep s=%ld ns=%ld\n",sleep_time.tv_sec,sleep_time.tv_nsec);*/ nanosleep( &sleep_time, NULL ); /* Send the message to the Multicast Group */ RM_sendto( chatSock, buffer, BUFFSIZE ); fprintf( stdout, "\n%s>", buffer); } } else { strcat( buffer, aux ); strcat( buffer, msg_buff ); if( !not_send_first ) /* Send the message to the Multicast Group */ RM_sendto( chatSock, buffer, BUFFSIZE ); else not_send_first = 0; fprintf( stdout, "\n%s>", buffer ); } } } /* Getting Multicast Group IP and Port from the Rmcast Library */ RM_getOption( DEST_IP, (void *)aux ); RM_getOption( DEST_PORT, (void *)&port ); /* Stop the Receive thread */ pthread_cancel( tid ); /* Leave the Multicast Group */ fprintf( stdout, "Leaving Multicast Group %s:%d \n", aux, port ); RM_leaveGroup( chatSock, (char*)RM_USE_CURRENT_CONFIG ); return 0; } tgif-QPL-4.2.5/rmcast/LICENSE.QPL0000644000076400007640000001116010122646341015722 0ustar williamwilliam THE Q PUBLIC LICENSE version 1.0 Copyright (C) 1999-2000 Trolltech AS, Norway. Everyone is permitted to copy and distribute this license document. The intent of this license is to establish freedom to share and change the software regulated by this license under the open source model. This license applies to any software containing a notice placed by the copyright holder saying that it may be distributed under the terms of the Q Public License version 1.0. Such software is herein referred to as the Software. This license covers modification and distribution of the Software, use of third-party application programs based on the Software, and development of free software which uses the Software. Granted Rights 1. You are granted the non-exclusive rights set forth in this license provided you agree to and comply with any and all conditions in this license. Whole or partial distribution of the Software, or software items that link with the Software, in any form signifies acceptance of this license. 2. You may copy and distribute the Software in unmodified form provided that the entire package, including - but not restricted to - copyright, trademark notices and disclaimers, as released by the initial developer of the Software, is distributed. 3. You may make modifications to the Software and distribute your modifications, in a form that is separate from the Software, such as patches. The following restrictions apply to modifications: a. Modifications must not alter or remove any copyright notices in the Software. b. When modifications to the Software are released under this license, a non-exclusive royalty-free right is granted to the initial developer of the Software to distribute your modification in future versions of the Software provided such versions remain available under these terms in addition to any other license(s) of the initial developer. 4. You may distribute machine-executable forms of the Software or machine-executable forms of modified versions of the Software, provided that you meet these restrictions: a. You must include this license document in the distribution. b. You must ensure that all recipients of the machine-executable forms are also able to receive the complete machine-readable source code to the distributed Software, including all modifications, without any charge beyond the costs of data transfer, and place prominent notices in the distribution explaining this. c. You must ensure that all modifications included in the machine-executable forms are available under the terms of this license. 5. You may use the original or modified versions of the Software to compile, link and run application programs legally developed by you or by others. 6. You may develop application programs, reusable components and other software items that link with the original or modified versions of the Software. These items, when distributed, are subject to the following requirements: a. You must ensure that all recipients of machine-executable forms of these items are also able to receive and use the complete machine-readable source code to the items without any charge beyond the costs of data transfer. b. You must explicitly license all recipients of your items to use and re-distribute original and modified versions of the items in both machine-executable and source code forms. The recipients must be able to do so without any charges whatsoever, and they must be able to re-distribute to anyone they choose. c. If the items are not available to the general public, and the initial developer of the Software requests a copy of the items, then you must supply one. Limitations of Liability In no event shall the initial developers or copyright holders be liable for any damages whatsoever, including - but not restricted to - lost revenue or profits or other direct, indirect, special, incidental or consequential damages, even if they have been advised of the possibility of such damages, except to the extent invariable law, if any, provides otherwise. No Warranty The Software and this license document are provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. Choice of Law This license is governed by the Laws of United States. Disputes shall be settled by Los Angeles City Court, California, USA. tgif-QPL-4.2.5/rmcast/etc/0000755000076400007640000000000011602233155015035 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/etc/rmcast.config.README0000644000076400007640000000267511225226450020464 0ustar williamwilliam There are two ways for an application to customize the Reliable Multicast Library options: - Using the RM_setOption(int OPTION_ID, void *OPTION_VALUE) function Where: OPTION_ID: indicates what option you want to set. You can found the option list in the rmcast.h header file. OPTION_VALUE: the value you want to set the option to Example: ... /* Setting REFRESH_TIMER */ int refresh_timer=10; RM_setOption(REFRESH_TIMER,(void *) refresh_timer); ... - Using RM_readConfigFile(char *FILENAME) This function will tell the Reliable Multicast Library to read the user's options from FILENAME. A sample config file is available in this directory, where you will find the list of options and their default values. Example: /* Read the config file from /etc/rmcast.config */ ... char config_file[50]; strcpy(config_file,"/etc/rmcast.config"); RM_readConfigFile(config_file); ... NOTE: There is a constant, RM_USE_CURRENT_CONFIG, that can replace functions parameters In those situations, the RM_USE_CURRENT_CONFIG will indicate that the default values must be used.(e.g. RM_joinGroup()). To retrieve the current value of an option from the Reliable Multicast Library you must use the RM_getOption() function. tgif-QPL-4.2.5/rmcast/etc/rmcast.config.sample0000644000076400007640000000572411076162235021012 0ustar williamwilliam#Reliable Multicast Library configuration file #Reliable Multicast Library version RM_VERSION=1.10 #Transmission mode: 0 multicast (default), 1 unicast TRANSMISSION_MODE=0 #Multicast or Unicast IP address to send data (destination IP) DEST_IP=225.1.2.3 #Multicast or Unicast port to send data (destination port) DEST_PORT=5151 #Time to live for the packets setting (1 indicates local network) TTL=1 #Inter-packet sleep timer: #Time between packet transmissions ( choose from 0 to 65535 microseconds) MICROSLEEP=10 #Log file path - NULL disable logging (default) LOG_FILE=NULL #Random Timers Distribution: 0 uniform 1 exponential TIMER_DISTRIBUTION=0 #Timer parameters # Timers values are obtained in the intervals: # (TIMER_PARAM_A*T,(TIMER_PARAM_A+TIMER_PARAM_B)*T) for NAKs # (TIMER_PARAM_C*T,(TIMER_PARAM_C+TIMER_PARAM_D)*T) for wait for retransmitions # (TIMER_PARAM_E*T,(TIMER_PARAM_C+TIMER_PARAM_F)*T) for for retransmitions # Where # TIMER_PARAM_A, TIMER_PARAM_B, TIMER_PARAM_C, TIMER_PARAM_D, TIMER_PARAM_E and # TIMER_PARAM_F are integer constants # T is the estimated one-way delay to the senders TIMER_PARAM_A=2 TIMER_PARAM_B=2 TIMER_PARAM_C=5 TIMER_PARAM_D=2 TIMER_PARAM_E=2 TIMER_PARAM_F=2 #Host related parameters and timers: # Must contain exactly the following lines: # HOSTS_IDENTIFIED=0 # DEFAULT # host1 # host2 # ... # hostN # If HOSTS_IDENTIFIED=0 then we will read only the DEFAULT # estimated delay. HOSTS_IDENTIFIED=0 DEFAULT 50 #Max number of naks that can be sent for each packet. 100 (default) MAX_NAK=100 # We will be able to retransmit the last MAX_MEMBER_CACHE_SIZE packets from each # member of the multicast group, i.e., we will store the last # MAX_MEMBER_CACHE_SIZE PACKETS from each member of the multicast group in the # cache. 4000 (default) # # WARNING: if you set MAX_MEMBER_CACHE_SIZE to low values the protocol may fail! # MAX_MEMBER_CACHE_SIZE=4000 #Enable support for new members 1 enabled (default), 0 disabled NEW_MEMBER_SUPPORT=0 #Show transmission statistics: 0 disabled (default) 1 enabled STATISTICS=0 #Time between transmission of refresh messages (seconds) REFRESH_TIMER=10 #Loss simulation: 0 disabled (default) any float number > 0 enabled # # A note about loss simulation: # When loss simulation is enabled (LOSS_PROB > 0) we always loose the first 10 # received packets, and the first received data packet - that is, # the first burst of received packets. # After that, packets are lost according to LOSS_PROB. # Example: LOSS_PROB=30 # The first 10 received packets will be lost. # Then, 30% of the packets will be lost LOSS_PROB=0 # Time to wait, in microseconds, before leaving the multicast group. LEAVE_GROUP_WAIT_TIME=500000 # Size of the buffer of the receiver host # (maximum size of a message that may be processed by the receiver host). RCV_BUFFER_SIZE=10000 tgif-QPL-4.2.5/rmcast/TODO0000644000076400007640000000265610434752620014770 0ustar williamwilliam- Enviar REFRESH apenas depois de um tempo sem enviar dados DICA: atualizar var last_data_sent_time sempre q enviar dados ao disparar o evento REFRESH: if(current_time - last_data_sent_time >= refresh_timer) send refresh escalona novo refresh para daqui a refresh_timer else escalona novo REFRESH para refresh_timer - (current_time - last_data_sent_time) - Remover nó da lista de NAKs qdo receber retransmissăo. - Mudar mensagem REFRESH para que inclua a lista dos sns dos ultimos pacotes de dados enviados por fontes conhecidas e năo apenas do emissor da mensagem REFRESH. - Otimizar a busca na cache. - Diminuir o escopo dos mutexs - A forma como foram implementadas as rotinas e a estrutura da cache nao sao muito otimizadas. O tempo de processamento dos pacotes cresce linearmente até a cache ficar cheia. - Implementar rotina para que usuarios possam entrar e sair a qq momento da sessao multicast. OBS: qd for implementar a entrada de usuario sem suporte, retirar o obrigacao do primeiro pacote ser o 0. 04/02/2002 - aguardando rotina do Bill para empacotar/desempacotar o estado atual 25/04/2002 - primeiros testes com a saida de usuarios (Daniel) 02/07/2002 - Ainda aguardando resposta do Bill - Implementar rotinas para gerar estatisticas da sessao. Mostrar "on the fly" ou gerar arquivo com os resultados no final. tgif-QPL-4.2.5/rmcast/Makefile.in0000644000076400007640000004625211566506143016351 0ustar williamwilliam# Makefile.in generated by automake 1.9.6 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ top_builddir = . am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd INSTALL = @INSTALL@ install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in $(srcdir)/config.h.in \ $(top_srcdir)/configure AUTHORS COPYING ChangeLog INSTALL NEWS \ TODO config/compile config/config.guess config/config.sub \ config/depcomp config/install-sh config/ltmain.sh \ config/missing config/mkinstalldirs subdir = . ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/configure.in am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno configure.status.lineno mkinstalldirs = $(SHELL) $(top_srcdir)/config/mkinstalldirs CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = SOURCES = DIST_SOURCES = RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ html-recursive info-recursive install-data-recursive \ install-exec-recursive install-info-recursive \ install-recursive installcheck-recursive installdirs-recursive \ pdf-recursive ps-recursive uninstall-info-recursive \ uninstall-recursive ETAGS = etags CTAGS = ctags DIST_SUBDIRS = $(SUBDIRS) DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ { test ! -d $(distdir) \ || { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \ && rm -fr $(distdir); }; } DIST_ARCHIVES = $(distdir).tar.gz GZIP_ENV = --best distuninstallcheck_listfiles = find . -type f -print distcleancheck_listfiles = find . -type f -print ACLOCAL = @ACLOCAL@ AMDEP_FALSE = @AMDEP_FALSE@ AMDEP_TRUE = @AMDEP_TRUE@ AMTAR = @AMTAR@ AR = @AR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = @CFLAGS@ CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CXX = @CXX@ CXXCPP = @CXXCPP@ CXXDEPMODE = @CXXDEPMODE@ CXXFLAGS = @CXXFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ DSYMUTIL = @DSYMUTIL@ ECHO = @ECHO@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ F77 = @F77@ FFLAGS = @FFLAGS@ GREP = @GREP@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LIBTOOL = @LIBTOOL@ LN_S = @LN_S@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ NMEDIT = @NMEDIT@ OBJEXT = @OBJEXT@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ RANLIB = @RANLIB@ SED = @SED@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ VERSION = @VERSION@ ac_ct_CC = @ac_ct_CC@ ac_ct_CXX = @ac_ct_CXX@ ac_ct_F77 = @ac_ct_F77@ am__fastdepCC_FALSE = @am__fastdepCC_FALSE@ am__fastdepCC_TRUE = @am__fastdepCC_TRUE@ am__fastdepCXX_FALSE = @am__fastdepCXX_FALSE@ am__fastdepCXX_TRUE = @am__fastdepCXX_TRUE@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build = @build@ build_alias = @build_alias@ build_cpu = @build_cpu@ build_os = @build_os@ build_vendor = @build_vendor@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host = @host@ host_alias = @host_alias@ host_cpu = @host_cpu@ host_os = @host_os@ host_vendor = @host_vendor@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ SUBDIRS = . src rmchat mcastproxy EXTRA_DIST = LICENSE.QPL README.tgwb doc tools tgif etc all: config.h $(MAKE) $(AM_MAKEFLAGS) all-recursive .SUFFIXES: am--refresh: @: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ echo ' cd $(srcdir) && $(AUTOMAKE) --gnu '; \ cd $(srcdir) && $(AUTOMAKE) --gnu \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --gnu Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --gnu Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ echo ' $(SHELL) ./config.status'; \ $(SHELL) ./config.status;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck $(top_srcdir)/configure: $(am__configure_deps) cd $(srcdir) && $(AUTOCONF) $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) config.h: stamp-h1 @if test ! -f $@; then \ rm -f stamp-h1; \ $(MAKE) stamp-h1; \ else :; fi stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status @rm -f stamp-h1 cd $(top_builddir) && $(SHELL) ./config.status config.h $(srcdir)/config.h.in: $(am__configure_deps) cd $(top_srcdir) && $(AUTOHEADER) rm -f stamp-h1 touch $@ distclean-hdr: -rm -f config.h stamp-h1 mostlyclean-libtool: -rm -f *.lo clean-libtool: -rm -rf .libs _libs distclean-libtool: -rm -f libtool uninstall-info-am: # This directory's subdirectories are mostly independent; you can cd # into them and run `make' without going through this Makefile. # To change the values of `make' variables: instead of editing Makefiles, # (1) if the variable is set in `config.status', edit `config.status' # (which will cause the Makefiles to be regenerated when you run `make'); # (2) otherwise, pass the desired values on the `make' command line. $(RECURSIVE_TARGETS): @failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ *k*) failcom='fail=yes';; \ esac; \ done; \ dot_seen=no; \ target=`echo $@ | sed s/-recursive//`; \ list='$(SUBDIRS)'; for subdir in $$list; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ dot_seen=yes; \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || eval $$failcom; \ done; \ if test "$$dot_seen" = "no"; then \ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ fi; test -z "$$fail" mostlyclean-recursive clean-recursive distclean-recursive \ maintainer-clean-recursive: @failcom='exit 1'; \ for f in x $$MAKEFLAGS; do \ case $$f in \ *=* | --[!k]*);; \ *k*) failcom='fail=yes';; \ esac; \ done; \ dot_seen=no; \ case "$@" in \ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ *) list='$(SUBDIRS)' ;; \ esac; \ rev=''; for subdir in $$list; do \ if test "$$subdir" = "."; then :; else \ rev="$$subdir $$rev"; \ fi; \ done; \ rev="$$rev ."; \ target=`echo $@ | sed s/-recursive//`; \ for subdir in $$rev; do \ echo "Making $$target in $$subdir"; \ if test "$$subdir" = "."; then \ local_target="$$target-am"; \ else \ local_target="$$target"; \ fi; \ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ || eval $$failcom; \ done && test -z "$$fail" tags-recursive: list='$(SUBDIRS)'; for subdir in $$list; do \ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ done ctags-recursive: list='$(SUBDIRS)'; for subdir in $$list; do \ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ done ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS TAGS: tags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ include_option=--etags-include; \ empty_fix=.; \ else \ include_option=--include; \ empty_fix=; \ fi; \ list='$(SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test ! -f $$subdir/TAGS || \ tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \ fi; \ done; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique; \ fi ctags: CTAGS CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) $(am__remove_distdir) mkdir $(distdir) $(mkdir_p) $(distdir)/config @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \ list='$(DISTFILES)'; for file in $$list; do \ case $$file in \ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \ esac; \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \ if test "$$dir" != "$$file" && test "$$dir" != "."; then \ dir="/$$dir"; \ $(mkdir_p) "$(distdir)$$dir"; \ else \ dir=''; \ fi; \ if test -d $$d/$$file; then \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ if test "$$subdir" = .; then :; else \ test -d "$(distdir)/$$subdir" \ || $(mkdir_p) "$(distdir)/$$subdir" \ || exit 1; \ distdir=`$(am__cd) $(distdir) && pwd`; \ top_distdir=`$(am__cd) $(top_distdir) && pwd`; \ (cd $$subdir && \ $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$$top_distdir" \ distdir="$$distdir/$$subdir" \ distdir) \ || exit 1; \ fi; \ done $(MAKE) $(AM_MAKEFLAGS) \ top_distdir="$(top_distdir)" distdir="$(distdir)" \ dist-hook -find $(distdir) -type d ! -perm -777 -exec chmod a+rwx {} \; -o \ ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ ! -type d ! -perm -444 -exec $(SHELL) $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r $(distdir) dist-gzip: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 $(am__remove_distdir) dist-tarZ: distdir tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z $(am__remove_distdir) dist-shar: distdir shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz $(am__remove_distdir) dist-zip: distdir -rm -f $(distdir).zip zip -rq $(distdir).zip $(distdir) $(am__remove_distdir) dist dist-all: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) # This target untars the dist file and tries a VPATH configuration. Then # it guarantees that the distribution is self-contained by making another # tarfile. distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac chmod -R a-w $(distdir); chmod a+w $(distdir) mkdir $(distdir)/_build mkdir $(distdir)/_inst chmod a-w $(distdir) dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ && cd $(distdir)/_build \ && ../configure --srcdir=.. --prefix="$$dc_install_base" \ $(DISTCHECK_CONFIGURE_FLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(MAKE) $(AM_MAKEFLAGS) check \ && $(MAKE) $(AM_MAKEFLAGS) install \ && $(MAKE) $(AM_MAKEFLAGS) installcheck \ && $(MAKE) $(AM_MAKEFLAGS) uninstall \ && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ distuninstallcheck \ && chmod -R a-w "$$dc_install_base" \ && ({ \ (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ } || { rm -rf "$$dc_destdir"; exit 1; }) \ && rm -rf "$$dc_destdir" \ && $(MAKE) $(AM_MAKEFLAGS) dist \ && rm -rf $(DIST_ARCHIVES) \ && $(MAKE) $(AM_MAKEFLAGS) distcleancheck $(am__remove_distdir) @(echo "$(distdir) archives ready for distribution: "; \ list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ sed -e '1{h;s/./=/g;p;x;}' -e '$${p;x;}' distuninstallcheck: @cd $(distuninstallcheck_dir) \ && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ || { echo "ERROR: files left after uninstall:" ; \ if test -n "$(DESTDIR)"; then \ echo " (check DESTDIR support)"; \ fi ; \ $(distuninstallcheck_listfiles) ; \ exit 1; } >&2 distcleancheck: distclean @if test '$(srcdir)' = . ; then \ echo "ERROR: distcleancheck can only run from a VPATH build" ; \ exit 1 ; \ fi @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left in build directory after distclean:" ; \ $(distcleancheck_listfiles) ; \ exit 1; } >&2 check-am: all-am check: check-recursive all-am: Makefile config.h installdirs: installdirs-recursive installdirs-am: install: install-recursive install-exec: install-exec-recursive install-data: install-data-recursive uninstall: uninstall-recursive install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-recursive install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-recursive clean-am: clean-generic clean-libtool mostlyclean-am distclean: distclean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -f Makefile distclean-am: clean-am distclean-generic distclean-hdr \ distclean-libtool distclean-tags dvi: dvi-recursive dvi-am: html: html-recursive info: info-recursive info-am: install-data-am: install-exec-am: install-info: install-info-recursive install-man: installcheck-am: maintainer-clean: maintainer-clean-recursive -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-recursive mostlyclean-am: mostlyclean-generic mostlyclean-libtool pdf: pdf-recursive pdf-am: ps: ps-recursive ps-am: uninstall-am: uninstall-info-am uninstall-info: uninstall-info-recursive .PHONY: $(RECURSIVE_TARGETS) CTAGS GTAGS all all-am am--refresh check \ check-am clean clean-generic clean-libtool clean-recursive \ ctags ctags-recursive dist dist-all dist-bzip2 dist-gzip \ dist-hook dist-shar dist-tarZ dist-zip distcheck distclean \ distclean-generic distclean-hdr distclean-libtool \ distclean-recursive distclean-tags distcleancheck distdir \ distuninstallcheck dvi dvi-am html html-am info info-am \ install install-am install-data install-data-am install-exec \ install-exec-am install-info install-info-am install-man \ install-strip installcheck installcheck-am installdirs \ installdirs-am maintainer-clean maintainer-clean-generic \ maintainer-clean-recursive mostlyclean mostlyclean-generic \ mostlyclean-libtool mostlyclean-recursive pdf pdf-am ps ps-am \ tags tags-recursive uninstall uninstall-am uninstall-info-am dist-hook: rm -rf `find $(distdir)/doc -type d -name CVS` rm -rf `find $(distdir)/tools -type d -name CVS` rm -rf `find $(distdir)/tgif -type d -name CVS` rm -rf `find $(distdir)/etc -type d -name CVS` deb: all tools/scripts/makedeb.sh `pwd` $(PACKAGE) $(PACKAGE_VERSION) $(libdir) $(bindir) $(includedir) $(datadir) # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: tgif-QPL-4.2.5/rmcast/Makefile.am0000644000076400007640000000063511141161553016322 0ustar williamwilliamSUBDIRS = . src rmchat mcastproxy EXTRA_DIST = LICENSE.QPL README.tgwb doc tools tgif etc dist-hook: rm -rf `find $(distdir)/doc -type d -name CVS` rm -rf `find $(distdir)/tools -type d -name CVS` rm -rf `find $(distdir)/tgif -type d -name CVS` rm -rf `find $(distdir)/etc -type d -name CVS` deb: all tools/scripts/makedeb.sh `pwd` $(PACKAGE) $(PACKAGE_VERSION) $(libdir) $(bindir) $(includedir) $(datadir) tgif-QPL-4.2.5/rmcast/doc/0000755000076400007640000000000011602233155015027 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/doc/manual/0000755000076400007640000000000011602233155016304 5ustar williamwilliamtgif-QPL-4.2.5/rmcast/doc/manual/nack_mask.obj0000644000076400007640000002441111077130422020730 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,0,0,0,16,0,9,2,1,0,0,0,0,1,0,'Courier',0,69120,0,0,0,10,0,0,1,1,0,16,0,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/nack_mask.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 50971, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 40569, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). page(1,"",1,''). text('black',188,86,1,0,1,9,16,0,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,99,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]). text('black',184,190,1,0,1,9,16,195,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,203,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "3")]) ]) ])]). text('black',156,31,1,0,1,84,14,305,11,3,0,0,0,0,2,84,14,0,0,"",0,0,0,0,42,'',[ minilines(84,14,0,0,0,0,0,[ mini_line(84,11,3,0,0,0,[ str_block(0,84,11,3,0,0,0,0,0,[ str_seg('black','Courier',0,69120,84,11,3,0,0,0,0,0,0,0, "Decimal Form")]) ]) ])]). text('black',343,31,1,0,1,77,14,307,11,3,0,0,0,0,2,77,14,0,0,"",0,0,0,0,42,'',[ minilines(77,14,0,0,0,0,0,[ mini_line(77,11,3,0,0,0,[ str_block(0,77,11,3,0,0,0,0,0,[ str_seg('black','Courier',0,69120,77,11,3,0,0,0,0,0,0,0, "Binary Form")]) ]) ])]). text('black',85,88,1,0,1,35,14,311,11,3,0,0,0,0,2,35,14,0,0,"",0,0,0,0,99,'',[ minilines(35,14,0,0,0,0,0,[ mini_line(35,11,3,0,0,0,[ str_block(0,35,11,3,0,0,0,0,0,[ str_seg('black','Courier',0,69120,35,11,3,0,0,0,0,0,0,0, "hmask")]) ]) ])]). text('black',85,192,1,0,1,35,14,313,11,3,0,0,0,0,2,35,14,0,0,"",0,0,0,0,203,'',[ minilines(35,14,0,0,0,0,0,[ mini_line(35,11,3,0,0,0,[ str_block(0,35,11,3,0,0,0,0,0,[ str_seg('black','Courier',0,69120,35,11,3,0,0,0,0,0,0,0, "lmask")]) ]) ])]). box('black','',148,50,571,253,0,1,1,302,0,0,0,0,0,'1',0,[ ]). poly('black','',2,[ 247,51,247,254],0,1,1,303,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 148,149,571,149],0,1,1,304,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ text('black',315,73,1,0,1,45,24,38,19,5,0,0,0,0,2,45,24,0,0,"",0,0,0,0,92,'',[ minilines(45,24,0,0,0,0,0,[ mini_line(45,19,5,0,0,0,[ str_block(0,45,19,5,0,-6,0,0,0,[ str_seg('black','Courier',0,138240,45,19,5,0,-6,0,0,0,0,0, "...")]) ]) ])]), group([ box('black','',263,72,288,104,0,1,1,5,0,0,0,0,0,'1',0,[ ]), text('black',276,80,1,1,1,9,16,6,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,93,'',[ minilines(9,16,0,0,1,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "0")]) ]) ])]) ], 65,0,0,[ ]), group([ box('black','',290,72,315,104,0,1,1,12,0,0,0,0,0,'1',0,[ ]), text('black',302,80,1,1,1,9,16,13,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,93,'',[ minilines(9,16,0,0,1,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "0")]) ]) ])]) ], 68,0,0,[ ]), group([ box('black','',361,73,386,105,0,1,1,18,0,0,0,0,0,'1',0,[ ]), text('black',374,81,1,1,1,9,16,19,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,94,'',[ minilines(9,16,0,0,1,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "0")]) ]) ])]) ], 71,0,0,[ ]), group([ box('black','',388,73,413,105,0,1,1,20,0,0,0,0,0,'1',0,[ ]), text('black',400,81,1,1,1,9,16,21,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,94,'',[ minilines(9,16,0,0,1,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "0")]) ]) ])]) ], 74,0,0,[ ]), poly('black','',4,[ 262,109,262,120,441,120,441,110],0,1,1,114,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), text('black',286,123,1,0,1,108,16,117,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,136,'',[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-2,0,0,0,0,0, "32 positions")]) ]) ])]), text('black',420,55,1,0,1,14,14,129,11,3,0,0,0,0,2,14,14,0,0,"",0,0,0,0,66,'',[ minilines(14,14,0,0,0,0,0,[ mini_line(14,11,3,0,0,0,[ str_block(0,14,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,14,11,3,0,-1,0,0,0,0,0, "32")]) ]) ])]), text('black',394,55,1,0,1,14,14,137,11,3,0,0,0,0,2,14,14,0,0,"",0,0,0,0,66,'',[ minilines(14,14,0,0,0,0,0,[ mini_line(14,11,3,0,0,0,[ str_block(0,14,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,14,11,3,0,-1,0,0,0,0,0, "33")]) ]) ])]), text('black',296,55,1,0,1,14,14,139,11,3,0,0,0,0,2,14,14,0,0,"",0,0,0,0,66,'',[ minilines(14,14,0,0,0,0,0,[ mini_line(14,11,3,0,0,0,[ str_block(0,14,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,14,11,3,0,-1,0,0,0,0,0, "62")]) ]) ])]), text('black',269,55,1,0,1,14,14,140,11,3,0,0,0,0,2,14,14,0,0,"",0,0,0,0,66,'',[ minilines(14,14,0,0,0,0,0,[ mini_line(14,11,3,0,0,0,[ str_block(0,14,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,14,11,3,0,-1,0,0,0,0,0, "63")]) ]) ])]), text('black',463,54,1,0,1,105,14,151,11,3,0,0,0,0,2,105,14,0,0,"",0,0,0,0,65,'',[ minilines(105,14,0,0,0,0,0,[ mini_line(105,11,3,0,0,0,[ str_block(0,105,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,105,11,3,0,-1,0,0,0,0,0, "position number")]) ]) ])]), poly('black','',2,[ 460,62,442,62],1,1,1,153,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), group([ box('black','',415,73,440,105,0,1,1,354,0,0,0,0,0,'1',0,[ ]), text('black',428,81,1,1,1,9,16,353,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,94,'',[ minilines(9,16,0,0,1,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 352,0,0,[ ]), text('black',367,55,1,0,1,14,14,387,11,3,0,0,0,0,2,14,14,0,0,"",0,0,0,0,66,'',[ minilines(14,14,0,0,0,0,0,[ mini_line(14,11,3,0,0,0,[ str_block(0,14,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,14,11,3,0,-1,0,0,0,0,0, "34")]) ]) ])]) ], 2101,0,0,[ ]). group([ text('black',315,181,1,0,1,45,24,476,19,5,0,0,0,0,2,45,24,0,0,"",0,0,0,0,200,'',[ minilines(45,24,0,0,0,0,0,[ mini_line(45,19,5,0,0,0,[ str_block(0,45,19,5,0,-6,0,0,0,[ str_seg('black','Courier',0,138240,45,19,5,0,-6,0,0,0,0,0, "...")]) ]) ])]), group([ box('black','',263,180,288,212,0,1,1,475,0,0,0,0,0,'1',0,[ ]), text('black',276,188,1,1,1,9,16,474,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,201,'',[ minilines(9,16,0,0,1,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "0")]) ]) ])]) ], 473,0,0,[ ]), group([ box('black','',290,180,315,212,0,1,1,472,0,0,0,0,0,'1',0,[ ]), text('black',302,188,1,1,1,9,16,471,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,201,'',[ minilines(9,16,0,0,1,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "0")]) ]) ])]) ], 470,0,0,[ ]), group([ box('black','',361,181,386,213,0,1,1,469,0,0,0,0,0,'1',0,[ ]), text('black',374,189,1,1,1,9,16,468,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,202,'',[ minilines(9,16,0,0,1,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "0")]) ]) ])]) ], 467,0,0,[ ]), group([ box('black','',388,181,413,213,0,1,1,466,0,0,0,0,0,'1',0,[ ]), text('black',400,189,1,1,1,9,16,465,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,202,'',[ minilines(9,16,0,0,1,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 464,0,0,[ ]), poly('black','',4,[ 262,217,262,228,441,228,441,218],0,1,1,463,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), text('black',286,231,1,0,1,108,16,462,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,244,'',[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-2,0,0,0,0,0, "32 positions")]) ]) ])]), text('black',424,163,1,0,1,7,14,461,11,3,0,0,0,0,2,7,14,0,0,"",0,0,0,0,174,'',[ minilines(7,14,0,0,0,0,0,[ mini_line(7,11,3,0,0,0,[ str_block(0,7,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,7,11,3,0,-1,0,0,0,0,0, "0")]) ]) ])]), text('black',396,163,1,0,1,7,14,460,11,3,0,0,0,0,2,7,14,0,0,"",0,0,0,0,174,'',[ minilines(7,14,0,0,0,0,0,[ mini_line(7,11,3,0,0,0,[ str_block(0,7,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,7,11,3,0,-1,0,0,0,0,0, "1")]) ]) ])]), text('black',296,163,1,0,1,14,14,459,11,3,0,0,0,0,2,14,14,0,0,"",0,0,0,0,174,'',[ minilines(14,14,0,0,0,0,0,[ mini_line(14,11,3,0,0,0,[ str_block(0,14,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,14,11,3,0,-1,0,0,0,0,0, "30")]) ]) ])]), text('black',269,163,1,0,1,14,14,458,11,3,0,0,0,0,2,14,14,0,0,"",0,0,0,0,174,'',[ minilines(14,14,0,0,0,0,0,[ mini_line(14,11,3,0,0,0,[ str_block(0,14,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,14,11,3,0,-1,0,0,0,0,0, "31")]) ]) ])]), text('black',463,162,1,0,1,105,14,457,11,3,0,0,0,0,2,105,14,0,0,"",0,0,0,0,173,'',[ minilines(105,14,0,0,0,0,0,[ mini_line(105,11,3,0,0,0,[ str_block(0,105,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,105,11,3,0,-1,0,0,0,0,0, "position number")]) ]) ])]), poly('black','',2,[ 460,170,442,170],1,1,1,456,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), group([ box('black','',415,181,440,213,0,1,1,455,0,0,0,0,0,'1',0,[ ]), text('black',428,189,1,1,1,9,16,454,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,202,'',[ minilines(9,16,0,0,1,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 453,0,0,[ ]), text('black',370,163,1,0,1,7,14,452,11,3,0,0,0,0,2,7,14,0,0,"",0,0,0,0,174,'',[ minilines(7,14,0,0,0,0,0,[ mini_line(7,11,3,0,0,0,[ str_block(0,7,11,3,0,-1,0,0,0,[ str_seg('black','Courier',0,69120,7,11,3,0,-1,0,0,0,0,0, "2")]) ]) ])]) ], 2127,0,0,[ ]). tgif-QPL-4.2.5/rmcast/doc/manual/log_plot_1.eps0000644000076400007640000236714210122646341021074 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: -1 522 361 793 %%Title: log_plot_1 %%CreationDate: Wed May 15 13:32:47 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 59 dict def tgifdict begin /tgifxpmdict 4 dict def /tgifbwpicstr 1 string def /tgifcolorpicstr 3 string def /tgifsetpixels { tgifxpmdict begin /pixels exch def end } def /tgifsetpix { tgifxpmdict begin pixels 3 1 roll putinterval end } def /tgifcolorspot { tgifxpmdict begin /index exch def pixels index 3 mul 3 getinterval aload pop 255 mul cvi tgifcolorpicstr 2 3 -1 roll put 255 mul cvi tgifcolorpicstr 1 3 -1 roll put 255 mul cvi tgifcolorpicstr 0 3 -1 roll put tgifcolorpicstr end } def /tgifnewcolorspot { tgifxpmdict begin /index exch def pixels index 3 mul 3 getinterval aload pop setrgbcolor end } def /tgifcolordict 4 dict def /colorimage where { pop } { /colorimage { tgifcolordict begin pop pop pop pop pop /ih exch def /iw exch def /x 0 def /y 0 def 1 1 ih { pop 1 1 iw { pop currentfile tgifbwpicstr readhexstring pop 0 get tgifnewcolorspot x y moveto 1 0 rlineto 0 1 rlineto -1 0 rlineto closepath fill /x x 1 add def } for /y y 1 add def /x 0 def } for end } def } ifelse /tgiftranscolorspot { tgifxpmdict begin /index exch def pixels index 3 mul 3 getinterval aload pop dup 0 lt { pop pop pop false } { setrgbcolor true } ifelse end } def /tgiftranscolorimage { tgifcolordict begin pop pop pop pop pop /ih exch def /iw exch def /x 0 def /y 0 def 1 1 ih { pop 1 1 iw { pop currentfile tgifbwpicstr readhexstring pop 0 get tgiftranscolorspot { x y moveto 1 0 rlineto 0 1 rlineto -1 0 rlineto closepath fill } if /x x 1 add def } for /y y 1 add def /x 0 def } for end } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: -1 522 361 793 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % XPM GS 0 0 TR 1.000 1.000 SC 0 RO 641 478 8 [1 0 0 1 0 0] {currentfile tgifbwpicstr readhexstring pop} IM b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffffff ffffffffffff000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 0000000000000000000000ffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff00ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff b66cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffff00ffffffffff000000 ffffffff000000ffffffff000000ffffffff000000ffffffffffffffffffffffffffffff ffff00000000ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff 006cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffff00ffffffffff0000ffffffffff0000ffffffff00ffffff 00ffff00ffffff00ffff00ffffff00ffff00ffffff00ffffff0000ffffffffffffffffff ffffff00ffff00ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00000000ffffff000000ffffff00ff 0000ffffffff0000ff00ffffff000000ffffff00ff0000ffffff00ff0000ffffffff0000 00ffffffff00000000ffff0000000000ffffff0000ffffffffffff00ffffffffffffffff 00ffff00ffffff00ffff00ffffff00ffffffffffff00ffffff0000ffffffffffffffffff ffffff00ffff00ffffff000000ffffff0000000000ffffff000000ffffffffffffffffff ffff00000000ffffff000000ffffff00ff0000ffffff0000000000ffffffffffffffffff ffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffff00ffffff00ffff0000 ffff00ffff00ffff0000ffff00ffffff00ffff0000ffff00ffff0000ffff00ffff00ffff ff00ffff00ffffffffffffffff00ffffffffffffffffffffffffff00ffffffffffff0000 ffffffff000000ffffffff00000000ffffffff0000ffffffffffffffffffffffffffffff ffffff00ffff00ffffffffffff00ffffffff00ffffffffffffffff00ffffffffffffffff ff00ffffffffffff00ffffff00ffff0000ffff00ffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffff00ff00ff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff000000ffffff0000000000ffff00ff ffff00ffff00ffffff00ffff0000000000ffff00ffffffffffff00ffffff00ffff00ffff ff00ffffff000000ffffffffff00ffffffffff0000ffffffffffff00ffffffffffffffff 00ffff00ffffff00ffffffffffff00ffffffffffff00ffffff0000ffffffffffffffffff ffffff00ffff00ffffff00000000ffffffff00ffffffffff00000000ffffffffffffffff ffff000000ffffff0000000000ffff00ffffff00ffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffff00ffffffffffff00ff ffff00ffff00ffff0000ffff00ffffffffffff00ffffffffffff00ffffff00ffff00ffff ff00ffffffffffff00ffffffff00ff00ffffff0000ffffffffffff00ffffffff00ffffff 00ffff00ffffff00ffffffffff00ffffff00ffffff00ffffff0000ffffffffffffffffff ffffff00ffff00ffff00ffffff00ffffffff00ff00ffff00ffffff00ffffffffffffffff ffffffffff00ffff00ffffffffffff00ffffff00ffffffff00ff00ffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00000000ffffffff000000ffffff00ff ffff00ffffff0000ff00ffffff000000ffffff00ffffffffffff00ffffff00ffffff0000 00ffffff00000000ffffffffffff00ffffffffffffffffffffff000000ffffffff000000 ffffffff000000ffffffff0000ffffffffff000000ffffffffffffffffffffffffffffff ffff00000000ffffffff00000000ffffffffff00ffffffff00000000ffffffffffffffff ff00000000ffffffff000000ffffff00ffffff00ffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffff00ffffffffff000000ffff ffff000000ffffffffffff00ffffffff000000ffffffffffffffffffffffffffffffffff 00000000ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff00ffffff ffff000000ffffffff000000ffffffff000000ffffffff000000ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffff00ffffffffff0000ffffffffff0000ffffffff00ffffff00ff ff00ffffff00ffffffff0000ffffff00ffffff00ffffff0000ffffffffffffffffffffff ff00ffff00ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffff00ff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffff00ffffffffff0000ffffffffff0000ffffff ff00ffffff00ffff00ffffff00ffff00ffffff00ffff00ffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ff0000ffffffff000000ffffffff000000ffffffff000000ffffffff0000ff ffffff00ffffff00ffffff000000ffffff00ff0000ffffff00ff0000ffffffff000000ff ffffff00000000ffff0000000000ffffff0000ffffffffffff00ffffffff00ffffff00ff ffffffffff00ffffff00ff00ffffff00ffffff00ffffff0000ffffffffffffffffffffff ff00ffff00ffffff000000ffffff0000000000ffffff000000ffffffffffffffffffff00 ff0000ffffffff000000ffffffff000000ffffffff000000ffffffff0000ffffffff00ff ffff00ffffff000000ffffffff0000ff00ffffffffffffffffffffff00ffffffff00ff00 00ffffffff000000ffffff0000ff00ffffffffffffffffffffff00000000ffffff000000 ffffff00ff0000ffffffff0000ff00ffffff000000ffffff00ff0000ffffff00ff0000ff ffffff000000ffffffff00000000ffff0000000000ffffff0000ffffffffffff00ffffff ffffffffff00ffff00ffffff00ffff00ffffff00ffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff0000ffff00ffff00ffffff00ffff00ffffff00ffff00ffffff00ffffffff00ff ffffff00ffffff00ffff00ffffff00ffff0000ffff00ffff0000ffff00ffff00ffffff00 ffff00ffffffffffffffff00ffffffffffffffffffffffffff00ffffffffff000000ffff ffffff0000ffffff00ffff00ffffffff000000ffffffffffffffffffffffffffffffffff ff00ffff00ffffffffffff00ffffffff00ffffffffffffffff00ffffffffffffffffff00 00ffff00ffff00ffffff00ffff00ffffff00ffff00ffffff00ffffffff00ffffffff00ff ffff00ffff00ffffff00ffff00ffff0000ffffffffffffffffffff000000ffffff0000ff ff00ffff00ffffff00ffff00ff00ff00ffffffffffffffffff00ffffffffffff00ffffff 00ffff0000ffff00ffff00ffff0000ffff00ffffff00ffff0000ffff00ffff0000ffff00 ffff00ffffff00ffff00ffffffffffffffff00ffffffffffffffffffffffffff00ffffff ffffff0000ffffffff000000ffffffff00000000ffffffff0000ffffffffffffffffff00 ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffff0000000000ffff00ffffffffffff0000000000ffffffff00ff ffffff00ffffff00ffff0000000000ffff00ffffffffffff00ffffff00ffff00ffffff00 ffffff000000ffffffffff00ffffffffff0000ffffffffffff00ffffffff00ffffff00ff ffffffffff00ffff0000000000ffff00ffffff00ffffff0000ffffffffffffffffffffff ff00ffff00ffffff00000000ffffffff00ffffffffff00000000ffffffffffffffffff00 ffffffffffff0000000000ffff00ffffffffffff0000000000ffffffff00ffffffff00ff ffff00ffff0000000000ffff00ffffff00ffffffffffffffffffffff00ffffffff00ffff ffffffff00ffffff00ffff00ff00ff00ffffffffffffffffffff000000ffffff00000000 00ffff00ffffff00ffff00ffffff00ffff0000000000ffff00ffffffffffff00ffffff00 ffff00ffffff00ffffff000000ffffffffff00ffffffffff0000ffffffffffff00ffffff ffffffffff00ffff00ffffff00ffffffffffff00ffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffff00ffffffffffff00ffffff00ffff00ffffffffffffffff00ff ffffffff00ff00ffffff00ffffffffffff00ffffffffffff00ffffff00ffff00ffffff00 ffffffffffff00ffffffff00ff00ffffff0000ffffffffffff00ffffffff00ffffff00ff ff00ffffff00ffffffffff00ffffff00ffffff00ffffff0000ffffffffffffffffffffff ff00ffff00ffff00ffffff00ffffffff00ff00ffff00ffffff00ffffffffffffffffff00 ffffffffffff00ffffffffffff00ffffff00ffff00ffffffffffffffff00ffffffffff00 ff00ffffff00ffffffffffff00ffff0000ffffffffffffffffffffff00ffffffff00ffff ffffffff00ffffff00ffff00ff00ff00ffffffffffffffffffffffffff00ffff00ffffff ffffff00ffffff00ffff00ffff0000ffff00ffffffffffff00ffffffffffff00ffffff00 ffff00ffffff00ffffffffffff00ffffffff00ff00ffffff0000ffffffffffff00ffffff ff00ffffff00ffff00ffffff00ffffffffff00ffffff00ffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffff000000ffffffff000000ffffffff000000ffffffff000000 ffffffffff00ffffffffff000000ffffff00ffffffffffff00ffffff00ffffff000000ff ffff00000000ffffffffffff00ffffffffffffffffffffff000000ffffffff000000ffff ffff000000ffffffffffff00ffffffff000000ffffffffffffffffffffffffffffffffff 00000000ffffffff00000000ffffffffff00ffffffff00000000ffffffffffffffffff00 ffffffffffffff000000ffffffff000000ffffffff000000ffffffff000000ffffffffff 00ffffffffff000000ffffffff0000ff00ffffffffffffffffffffff00ffffffff00ffff ffffffffff000000ffffff00ff00ff00ffffffffffffffffff00000000ffffffff000000 ffffff00ffffff00ffffff0000ff00ffffff000000ffffff00ffffffffffff00ffffff00 ffffff000000ffffff00000000ffffffffffff00ffffffffffffffffffffff000000ffff ffff000000ffffffff000000ffffffff0000ffffffffff000000ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffff00ffffffffff000000ffffffff000000ffffff ffffff00ffffffff000000ffffffffffffffffffffffffffffffffff00000000ffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffff0000ffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff00ffffff ffff000000ffffffff000000ffffffff000000ffffffff000000ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffff00ffffffffff0000ffffffffff0000ffffffff00ffffff00ffff00ffffff00ffff ffff0000ffffff00ffffff00ffffff0000ffffffffffffffffffffffff00ffff00ffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffff00ff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffff00ffffffffff0000ffffffffff0000ffffff ff00ffffff00ffff00ffffff00ffff00ffffff00ffff00ffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff0000 ffffffff000000ffffffff000000ffffffff000000ffffffff0000ffffffff00ffffff00 ffffff000000ffffff00ff0000ffffff00ff0000ffffffff000000ffffffff00000000ff ff0000000000ffffff0000ffffffffffff00ffffffff00ffffff00ffffffffffff00ffff ff00ff00ffffff00ffffff00ffffff0000ffffffffffffffffffffffff00ffff00ffffff 000000ffffff0000000000ffffff000000ffffffffffffffffffffffff00ffffffffff00 0000ffffffff00000000ffff0000000000ffffffffffffffffffffff00ffffffff00ff00 00ffffffff000000ffffff0000ff00ffffffffffffffffffffff00000000ffffff000000 ffffff00ff0000ffffffff0000ff00ffffff000000ffffff00ff0000ffffff00ff0000ff ffffff000000ffffffff00000000ffff0000000000ffffff0000ffffffffffff00ffffff ffffffffff00ffff00ffffff00ffff00ffffff00ffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff 00ffff00ffffff00ffff00ffffff00ffff00ffffff00ffffffff00ffffffff00ffffff00 ffff00ffffff00ffff0000ffff00ffff0000ffff00ffff00ffffff00ffff00ffffffffff ffffff00ffffffffffffffffffffffffff00ffffffffff000000ffffffffff0000ffffff 00ffff00ffffffff000000ffffffffffffffffffffffffffffffffffff00ffff00ffffff ffffff00ffffffff00ffffffffffffffff00ffffffffffffffffffffff00ffffffff00ff ffff00ffff00ffffffffffffffff00ffffffffffffffffffffffff000000ffffff0000ff ff00ffff00ffffff00ffff00ff00ff00ffffffffffffffffff00ffffffffffff00ffffff 00ffff0000ffff00ffff00ffff0000ffff00ffffff00ffff0000ffff00ffff0000ffff00 ffff00ffffff00ffff00ffffffffffffffff00ffffffffffffffffffffffffff00ffffff ffffff0000ffffffff000000ffffffff00000000ffffffff0000ffffffffffffffffff00 00ffff0000ffff0000ffff0000ffff0000ffff0000ffff0000ffff0000ffff0000ffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffff0000000000ffff00ffffffffffff0000000000ffffffff00ffffffff00ffffff00 ffff0000000000ffff00ffffffffffff00ffffff00ffff00ffffff00ffffff000000ffff ffffff00ffffffffff0000ffffffffffff00ffffffff00ffffff00ffffffffffff00ffff 0000000000ffff00ffffff00ffffff0000ffffffffffffffffffffffff00ffff00ffffff 00000000ffffffff00ffffffffff00000000ffffffffffffffffffffff00ffffffff00ff ffff00ffffff000000ffffffffff00ffffffffffffffffffffffffff00ffffffff00ffff ffffffff00ffffff00ffff00ff00ff00ffffffffffffffffffff000000ffffff00000000 00ffff00ffffff00ffff00ffffff00ffff0000000000ffff00ffffffffffff00ffffff00 ffff00ffffff00ffffff000000ffffffffff00ffffffffff0000ffffffffffff00ffffff ffffffffff00ffff00ffffff00ffffffffffff00ffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffff00ffffffffffff00ffffff00ffff00ffffffffffffffff00ffffffffff00ff00ff ffff00ffffffffffff00ffffffffffff00ffffff00ffff00ffffff00ffffffffffff00ff ffffff00ff00ffffff0000ffffffffffff00ffffffff00ffffff00ffff00ffffff00ffff ffffff00ffffff00ffffff00ffffff0000ffffffffffffffffffffffff00ffff00ffff00 ffffff00ffffffff00ff00ffff00ffffff00ffffffffffffffffffffff00ffffffff00ff ffff00ffffffffffff00ffffffff00ff00ffffffffffffffffffffff00ffffffff00ffff ffffffff00ffffff00ffff00ff00ff00ffffffffffffffffffffffffff00ffff00ffffff ffffff00ffffff00ffff00ffff0000ffff00ffffffffffff00ffffffffffff00ffffff00 ffff00ffffff00ffffffffffff00ffffffff00ff00ffffff0000ffffffffffff00ffffff ff00ffffff00ffff00ffffff00ffffffffff00ffffff00ffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffff000000ffffffff000000ffffffff000000ffffffff000000ffffffffff00ffff ffffff000000ffffff00ffffffffffff00ffffff00ffffff000000ffffff00000000ffff ffffffff00ffffffffffffffffffffff000000ffffffff000000ffffffff000000ffffff ffffff00ffffffff000000ffffffffffffffffffffffffffffffffff00000000ffffffff 00000000ffffffffff00ffffffff00000000ffffffffffffffffffff000000ffffffff00 0000ffffff00000000ffffffffffff00ffffffffffffffffffffffff00ffffffff00ffff ffffffffff000000ffffff00ff00ff00ffffffffffffffffff00000000ffffffff000000 ffffff00ffffff00ffffff0000ff00ffffff000000ffffff00ffffffffffff00ffffff00 ffffff000000ffffff00000000ffffffffffff00ffffffffffffffffffffff000000ffff ffff000000ffffffff000000ffffffff0000ffffffffff000000ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffff000000ffffffffffffffffffff0000000000ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffff00ffffff00ffffffffffffffffff00ffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffff00ffffffffffffffffff00000000ffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffff000000ffffffffffffffffffffffffffff00ffff ffffffffffff000000000000ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff000000000000ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff00ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffff00ffffffffffffff0000ffffffff00ffffff00ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffff0000000000ffffff0000ffffffffff000000ffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff00ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffff ffffffffffff000000000000ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff000000000000ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffff0000000000ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffff00ffffffffffffffffffffff0000000000ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffff0000ffffffffffffffffffffff00ffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffff00ffffffffffffffffffffff00000000ffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff00ffff ffffffffffff000000000000ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff000000000000ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff00ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffff00ffffffffff0000ffffffff00ffffff00ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffff000000ffffffff0000ffffffffff000000ffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffff000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff000000ffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffff00ff0000000000000000ffff0000ffff0000ffff0000ffff0000ffff0000ffff 0000ffff0000ff000000ff000000ffff0000ffff0000ffff0000ffff0000ffff0000ffff 0000ffff0000ffff0000ff000000ffff0000ffff0000ffff0000ffff0000ffff0000ffff 0000ffff0000ffff0000ffff000000ff0000ffff0000ffff0000ffff0000ffff0000ffff 0000ffff0000ffff0000ffff0000ff000000ff000000ffff0000ffff0000ffff0000ffff 0000ffff0000ffff0000ffff0000ffff0000ff000000ffff0000ffff0000ffff0000ffff 0000ffff0000ffff0000ffff0000ffff0000ffff000000ff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ff00ff00ff00ff00ff00ff00 ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00 ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00000000000000ff00 ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00 ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00 ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00 000000000000ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00 ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00 ff00ff00ff00ff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff000000000000ff00ffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffff000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff000000ffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff0000ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff0000ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff00 ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff00ff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff00ffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff00ffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff00ffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff00ffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff00ffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffff00ffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffff000000ffffffffffffffffffff0000000000ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffff00ffffff00ffffffffffffffffff00ffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffff00ffff0000ffffffffffffffffff00000000ffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffff00ff00ff00ffffffffffffffffffffffffff00ffff ffffffffffff000000000000ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffff000000000000ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffff0000ffff00ffffffffffffffffffffffffff00ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffff00ffffff00ffffff0000ffffffff00ffffff00ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffff000000ffffffff0000ffffffffff000000ffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffff00ffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff00ffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff00ffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff00ffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff00ffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff00ffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff00ff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff00 ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff0000ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff00ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff0000ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff0000ffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ff00ffff ffffffffffff000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 0000000000000000000000ffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff000000ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff00 0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffff000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffff00ff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ff ffffff00ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff0000ffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff00ff ff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff000000ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff00ff 00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffff000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffff00ffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff0000ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff0000000000ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff0000 ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffff0000000000ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff00ff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff0000000000ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff000000ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffffff00 0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000 ffffff0000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff000000ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff df6cffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Wed May 15 13:32:47 2002 %%DocumentFonts: %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/flowcontrol.obj0000644000076400007640000010514111077130422021351 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,83,0,0,16,0,9,1,1,1,0,1,0,1,0,'Courier-Bold',1,80640,0,0,0,10,0,0,1,1,0,16,0,0,1,1,1,0,1088,1408,1,0,5760,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/flowcontrol.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 50971, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 40569, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). page(1,"",1,''). poly('black','',2,[ 192,424,836,424],0,1,1,1455,0,0,4,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ text('black',223,279,1,0,1,16,126,1678,12,4,0,0,0,0,2,126,16,0,0,"",0,1,0,0,291,'',[ 223,279,223,279,349,295,-1.83691e-13,-1000,1000,-1.83691e-13,-24,-8,222,278,350,296],[ minilines(126,16,0,0,0,0,0,[ mini_line(126,12,4,0,0,0,[ str_block(0,126,12,4,0,0,0,0,0,[ str_seg('black','Courier-Bold',1,80640,126,12,4,0,0,0,0,0,0,0, "Naive Approach")]) ]) ])]), box('black','',196,141,221,277,0,1,1,1680,0,0,0,1,0,'1',0,[ 234,289,234,289,370,314,-1.83691e-13,-1000,1000,-1.83691e-13,-38,-12],[ ]) ], 1695,0,0,[ ]). group([ text('black',234,734,1,0,1,16,234,1689,12,4,0,0,0,0,2,234,16,0,0,"",0,1,0,0,746,'',[ 234,734,234,734,468,750,-1.83691e-13,-1000,1000,-1.83691e-13,-24,-8,233,733,469,751],[ minilines(234,16,0,0,0,0,0,[ mini_line(234,12,4,0,0,0,[ str_block(0,234,12,4,0,-2,0,0,0,[ str_seg('black','Courier-Bold',1,80640,234,12,4,0,-2,0,0,0,0,0, "Approach with Flow Control")]) ]) ])]), box('black','',204,483,229,731,0,1,1,1690,0,0,0,1,0,'1',0,[ 242,631,242,631,378,656,-1.83691e-13,-1823.53,1000,-3.34966e-13,-38,100],[ ]) ], 1698,0,0,[ ]). poly('black','',2,[ 505,62,505,379],0,2,1,241,0,0,0,0,0,1,0,'2',0,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ 504,62,505,62,505,379,1000,0,0,1107.26,0,0],[ ]). poly('black','',2,[ 666,61,666,380],0,2,1,243,0,0,0,0,0,1,0,'2',0,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ 665,61,666,61,666,380,1000,0,0,1100.31,0,0],[ ]). poly('black','',2,[ 505,103,665,151],0,1,1,250,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ box('black','',676,117,746,135,0,1,1,255,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 690,117,690,135],0,1,1,257,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), box('black','',676,117,690,135,0,1,1,262,0,0,0,0,0,'1',0,[ ]), box('black','',690,117,704,135,0,1,1,264,0,0,0,0,0,'1',0,[ ]), box('black','',704,117,718,135,0,1,1,265,0,0,0,0,0,'1',0,[ ]), box('black','',718,117,732,135,0,1,1,269,0,0,0,0,0,'1',0,[ ]), box('black','',732,117,746,135,0,1,1,272,0,0,0,0,0,'1',0,[ ]) ], 314,0,0,[ ]). poly('black','',2,[ 505,156,665,204],0,1,1,389,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 506,176,666,224],0,1,1,390,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 504,197,664,245],0,1,1,391,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 504,221,664,269],0,1,1,392,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ group([ box('black','',676,193,746,211,0,1,1,412,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 690,193,690,211],0,1,1,411,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), box('black','',676,193,690,211,0,1,1,410,0,0,0,0,0,'1',0,[ ]), box('black','',690,193,704,211,0,1,1,409,0,0,0,0,0,'1',0,[ ]), box('black','',704,193,718,211,0,1,1,408,0,0,0,0,0,'1',0,[ ]), box('black','',718,193,732,211,0,1,1,407,0,0,0,0,0,'1',0,[ ]), box('black','',732,193,746,211,0,1,1,406,0,0,0,0,0,'1',0,[ ]) ], 405,0,0,[ ]), text('black',679,194,1,0,1,9,16,413,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,207,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]), text('black',693,194,1,0,1,9,16,414,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,207,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "2")]) ]) ])]), text('black',707,194,1,0,1,9,16,415,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,207,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "3")]) ]) ])]), text('black',721,194,1,0,1,9,16,416,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,207,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "4")]) ]) ])]), text('black',735,194,1,0,1,9,16,454,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,207,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "5")]) ]) ])]) ], 482,0,0,[ ]). group([ group([ box('black','',676,217,746,235,0,1,1,424,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 690,217,690,235],0,1,1,423,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), box('black','',676,217,690,235,0,1,1,422,0,0,0,0,0,'1',0,[ ]), box('black','',690,217,704,235,0,1,1,421,0,0,0,0,0,'1',0,[ ]), box('black','',704,217,718,235,0,1,1,420,0,0,0,0,0,'1',0,[ ]), box('black','',718,217,732,235,0,1,1,419,0,0,0,0,0,'1',0,[ ]), box('black','',732,217,746,235,0,1,1,418,0,0,0,0,0,'1',0,[ ]) ], 417,0,0,[ ]), text('black',679,218,1,0,1,9,16,425,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,231,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "6")]) ]) ])]), text('black',693,218,1,0,1,9,16,426,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,231,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "2")]) ]) ])]), text('black',707,218,1,0,1,9,16,427,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,231,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "3")]) ]) ])]), text('black',721,218,1,0,1,9,16,428,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,231,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "4")]) ]) ])]), text('black',736,217,1,0,1,9,16,466,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,230,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "5")]) ]) ])]) ], 496,0,0,[ ]). group([ group([ box('black','',676,241,746,259,0,1,1,436,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 690,241,690,259],0,1,1,435,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), box('black','',676,241,690,259,0,1,1,434,0,0,0,0,0,'1',0,[ ]), box('black','',690,241,704,259,0,1,1,433,0,0,0,0,0,'1',0,[ ]), box('black','',704,241,718,259,0,1,1,432,0,0,0,0,0,'1',0,[ ]), box('black','',718,241,732,259,0,1,1,431,0,0,0,0,0,'1',0,[ ]), box('black','',732,241,746,259,0,1,1,430,0,0,0,0,0,'1',0,[ ]) ], 429,0,0,[ ]), text('black',679,242,1,0,1,9,16,437,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,255,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "6")]) ]) ])]), text('black',693,242,1,0,1,9,16,438,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,255,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "7")]) ]) ])]), text('black',707,242,1,0,1,9,16,439,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,255,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "3")]) ]) ])]), text('black',721,242,1,0,1,9,16,440,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,255,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "4")]) ]) ])]), text('black',734,242,1,0,1,9,16,467,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,255,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "5")]) ]) ])]) ], 510,0,0,[ ]). group([ group([ box('black','',676,264,746,282,0,1,1,448,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 690,264,690,282],0,1,1,447,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), box('black','',676,264,690,282,0,1,1,446,0,0,0,0,0,'1',0,[ ]), box('black','',690,264,704,282,0,1,1,445,0,0,0,0,0,'1',0,[ ]), box('black','',704,264,718,282,0,1,1,444,0,0,0,0,0,'1',0,[ ]), box('black','',718,264,732,282,0,1,1,443,0,0,0,0,0,'1',0,[ ]), box('black','',732,264,746,282,0,1,1,442,0,0,0,0,0,'1',0,[ ]) ], 441,0,0,[ ]), text('black',679,265,1,0,1,9,16,449,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,278,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "6")]) ]) ])]), text('black',693,265,1,0,1,9,16,450,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,278,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "7")]) ]) ])]), text('black',707,265,1,0,1,9,16,451,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,278,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "8")]) ]) ])]), text('black',721,265,1,0,1,9,16,452,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,278,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "4")]) ]) ])]), text('black',735,265,1,0,1,9,16,468,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,278,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "5")]) ]) ])]) ], 524,0,0,[ ]). group([ group([ box('black','',676,143,746,161,0,1,1,282,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 690,143,690,161],0,1,1,283,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), box('black','',676,143,690,161,0,1,1,284,0,0,0,0,0,'1',0,[ ]), box('black','',690,143,704,161,0,1,1,285,0,0,0,0,0,'1',0,[ ]), box('black','',704,143,718,161,0,1,1,286,0,0,0,0,0,'1',0,[ ]), box('black','',718,143,732,161,0,1,1,287,0,0,0,0,0,'1',0,[ ]), box('black','',732,143,746,161,0,1,1,288,0,0,0,0,0,'1',0,[ ]) ], 322,0,0,[ ]), text('black',680,144,1,0,1,9,16,344,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,157,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 570,0,0,[ ]). poly('black','',2,[ 276,59,276,399],0,2,1,630,0,0,0,0,0,1,0,'2',0,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ 276,59,276,59,276,399,1000,0,0,1032.35,0,0],[ ]). poly('black','',2,[ 437,58,437,407],0,2,1,631,0,0,0,0,0,1,0,'2',0,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ 437,58,437,58,437,407,1000,0,0,1005.92,0,0],[ ]). poly('black','',2,[ 276,68,338,86],0,1,1,632,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 327,94,344,78],0,1,1,643,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 335,76,342,99],0,1,1,644,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 275,105,337,123],0,1,1,657,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 326,131,343,115],0,1,1,658,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 334,113,341,136],0,1,1,659,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 277,166,339,184],0,1,1,684,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 328,192,345,176],0,1,1,685,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 336,174,343,197],0,1,1,686,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 276,200,436,242],0,1,1,687,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 437,250,276,280],0,1,1,690,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',261,40,1,0,1,54,16,756,12,4,0,0,0,0,2,54,16,0,0,"",0,0,0,0,52,'',[ minilines(54,16,0,0,0,0,0,[ mini_line(54,12,4,0,0,0,[ str_block(0,54,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,54,12,4,0,-1,0,0,0,0,0, "sender")]) ]) ])]). text('black',398,37,1,0,1,72,16,758,12,4,0,0,0,0,2,72,16,0,0,"",0,0,0,0,49,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,12,4,0,0,0,[ str_block(0,72,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,72,12,4,0,-1,0,0,0,0,0, "receiver")]) ]) ])]). text('black',484,37,1,0,1,54,16,762,12,4,0,0,0,0,2,54,16,0,0,"",0,0,0,0,49,'',[ minilines(54,16,0,0,0,0,0,[ mini_line(54,12,4,0,0,0,[ str_block(0,54,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,54,12,4,0,-1,0,0,0,0,0, "sender")]) ]) ])]). text('black',626,39,1,0,1,72,16,763,12,4,0,0,0,0,2,72,16,0,0,"",0,0,0,0,51,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,12,4,0,0,0,[ str_block(0,72,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,72,12,4,0,-1,0,0,0,0,0, "receiver")]) ]) ])]). poly('black','',2,[ 666,305,505,335],0,1,1,765,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 664,326,503,356],0,1,1,767,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 665,346,504,376],0,1,1,768,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 438,343,277,373],0,1,1,777,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 436,367,275,397],0,1,1,779,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ text('black',370,110,1,0,1,20,33,728,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,136,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]), text('black',370,126,1,0,1,20,33,725,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,152,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]), text('black',370,143,1,0,1,20,33,722,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,169,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]) ], 822,0,0,[ ]). group([ text('black',592,121,1,0,1,20,33,830,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,147,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]), text('black',592,137,1,0,1,20,33,829,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,163,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]), text('black',592,154,1,0,1,20,33,828,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,180,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]) ], 827,0,0,[ ]). poly('black','',2,[ 506,73,568,91],0,1,1,837,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 557,99,574,83],0,1,1,838,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 565,81,572,104],0,1,1,839,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',734,378,1,0,1,74,27,1541,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,391,'',[ 734,378,734,378,806,394,987.688,-156.434,156.434,987.688,-203,-68,733,377,807,395],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "nack (0)")]) ]) ])]). text('black',735,399,1,0,1,74,27,1542,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,412,'',[ 735,399,735,399,807,415,987.688,-156.434,156.434,987.688,-203,-68,734,398,808,416],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "nack (1)")]) ]) ])]). text('black',736,419,1,0,1,74,27,1543,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,432,'',[ 736,419,736,419,808,435,987.688,-156.434,156.434,987.688,-203,-68,735,418,809,436],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "nack (2)")]) ]) ])]). text('black',518,65,1,0,1,74,32,1596,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,78,'',[ 518,65,518,65,590,81,974.37,224.951,-224.951,974.37,0,-13,517,64,591,82],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "retr (0)")]) ]) ])]). text('black',513,101,1,0,1,74,32,1598,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,114,'',[ 513,101,513,101,585,117,974.37,224.951,-224.951,974.37,0,-13,512,100,586,118],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "retr (1)")]) ]) ])]). text('black',515,154,1,0,1,74,32,1601,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,167,'',[ 515,154,515,154,587,170,974.37,224.951,-224.951,974.37,0,-13,514,153,588,171],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "retr (5)")]) ]) ])]). text('black',517,177,1,0,1,74,34,1607,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,190,'',[ 517,177,517,177,589,193,965.926,258.819,-258.819,965.926,0,-15,516,176,590,194],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "retr (6)")]) ]) ])]). text('black',516,198,1,0,1,74,34,1612,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,211,'',[ 516,198,516,198,588,214,965.926,258.819,-258.819,965.926,0,-15,515,197,589,215],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "retr (7)")]) ]) ])]). text('black',516,221,1,0,1,74,34,1615,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,234,'',[ 516,221,516,221,588,237,965.926,258.819,-258.819,965.926,0,-15,515,220,589,238],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "retr (8)")]) ]) ])]). text('black',301,67,1,0,1,73,31,1618,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,80,'',[ 301,67,301,67,373,83,978.148,207.912,-207.912,978.148,0,-12,300,66,374,84],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "data (0)")]) ]) ])]). text('black',296,101,1,0,1,73,31,1620,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,114,'',[ 296,101,296,101,368,117,978.148,207.912,-207.912,978.148,0,-12,295,100,369,118],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "data (1)")]) ]) ])]). text('black',293,160,1,0,1,74,32,1623,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,173,'',[ 293,160,293,160,365,176,974.37,224.951,-224.951,974.37,0,-13,292,159,366,177],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "data (8)")]) ]) ])]). text('black',288,199,1,0,1,100,36,1628,13,3,0,0,0,0,2,99,16,0,0,"",0,1,0,0,212,'',[ 288,199,288,199,387,215,978.148,207.912,-207.912,978.148,0,-12,287,198,388,216],[ minilines(99,16,0,0,0,0,0,[ mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-4,0,0,0,0,0, "refresh (8)")]) ]) ])]). group([ text('black',359,266,1,0,1,20,33,1641,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,292,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]), text('black',359,282,1,0,1,20,33,1640,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,308,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]), text('black',359,299,1,0,1,20,33,1639,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,325,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]) ], 1638,0,0,[ ]). text('black',493,326,1,0,1,74,27,1643,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,339,'',[ 493,326,493,326,565,342,987.688,-156.434,156.434,987.688,-203,-68,492,325,566,343],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "nack (0)")]) ]) ])]). text('black',509,413,1,0,1,74,27,1646,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,426,'',[ 509,413,509,413,581,429,987.688,-156.434,156.434,987.688,-203,-68,508,412,582,430],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "nack (7)")]) ]) ])]). text('black',510,439,1,0,1,74,27,1647,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,452,'',[ 510,439,510,439,582,455,987.688,-156.434,156.434,987.688,-203,-68,509,438,583,456],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "nack (8)")]) ]) ])]). arc('black','',0,1,1,0,416,40,467,91,442,136,492,136,0,102,102,-7616,3776,1652,0,1,8,3,0,0,0,'1','8','3',0,[ ]). poly('black','',2,[ 505,475,505,757],0,2,1,1199,0,0,0,0,0,1,0,'2',0,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ 505,475,505,475,505,757,1000,0,0,1017.73,0,0],[ ]). poly('black','',2,[ 666,474,666,759],0,2,1,1198,0,0,0,0,0,1,0,'2',0,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ 666,474,666,474,666,759,1000,0,0,1007.02,0,0],[ ]). poly('black','',2,[ 505,522,665,570],0,1,1,1197,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ box('black','',676,536,746,554,0,1,1,1196,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 690,536,690,554],0,1,1,1195,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), box('black','',676,536,690,554,0,1,1,1194,0,0,0,0,0,'1',0,[ ]), box('black','',690,536,704,554,0,1,1,1193,0,0,0,0,0,'1',0,[ ]), box('black','',704,536,718,554,0,1,1,1192,0,0,0,0,0,'1',0,[ ]), box('black','',718,536,732,554,0,1,1,1191,0,0,0,0,0,'1',0,[ ]), box('black','',732,536,746,554,0,1,1,1190,0,0,0,0,0,'1',0,[ ]) ], 1189,0,0,[ ]). poly('black','',2,[ 505,575,665,623],0,1,1,1188,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ box('black','',676,616,746,634,0,1,1,1184,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 690,616,690,634],0,1,1,1183,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), box('black','',676,616,690,634,0,1,1,1182,0,0,0,0,0,'1',0,[ ]), box('black','',690,616,704,634,0,1,1,1181,0,0,0,0,0,'1',0,[ ]), box('black','',704,616,718,634,0,1,1,1180,0,0,0,0,0,'1',0,[ ]), box('black','',718,616,732,634,0,1,1,1179,0,0,0,0,0,'1',0,[ ]), box('black','',732,616,746,634,0,1,1,1178,0,0,0,0,0,'1',0,[ ]) ], 1177,0,0,[ ]). text('black',679,617,1,0,1,9,16,1176,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,630,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]). text('black',693,617,1,0,1,9,16,1175,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,630,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "2")]) ]) ])]). text('black',707,617,1,0,1,9,16,1174,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,630,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "3")]) ]) ])]). text('black',721,617,1,0,1,9,16,1173,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,630,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-2,0,0,0,0,0, "4")]) ]) ])]). group([ group([ box('black','',676,557,746,575,0,1,1,1128,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 690,557,690,575],0,1,1,1127,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), box('black','',676,557,690,575,0,1,1,1126,0,0,0,0,0,'1',0,[ ]), box('black','',690,557,704,575,0,1,1,1125,0,0,0,0,0,'1',0,[ ]), box('black','',704,557,718,575,0,1,1,1124,0,0,0,0,0,'1',0,[ ]), box('black','',718,557,732,575,0,1,1,1123,0,0,0,0,0,'1',0,[ ]), box('black','',732,557,746,575,0,1,1,1122,0,0,0,0,0,'1',0,[ ]) ], 1121,0,0,[ ]), text('black',680,558,1,0,1,9,16,1120,13,3,0,0,0,0,2,9,16,0,0,"",0,0,0,0,571,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 1119,0,0,[ ]). poly('black','',2,[ 276,472,276,751],0,2,1,1118,0,0,0,0,0,1,0,'2',0,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ 276,472,276,472,276,751,1000,0,0,1028.67,0,0],[ ]). poly('black','',2,[ 437,471,437,758],0,2,1,1117,0,0,0,0,0,0,0,'2',0,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ ]). poly('black','',2,[ 276,481,338,499],0,1,1,1116,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 327,507,344,491],0,1,1,1115,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 335,489,342,512],0,1,1,1114,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 275,515,337,533],0,1,1,1113,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 326,541,343,525],0,1,1,1112,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 334,523,341,546],0,1,1,1111,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 277,579,339,597],0,1,1,1110,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 328,605,345,589],0,1,1,1109,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 336,587,343,610],0,1,1,1108,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 276,613,436,655],0,1,1,1107,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 437,680,276,710],0,1,1,1106,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',261,453,1,0,1,54,16,1105,12,4,0,0,0,0,2,54,16,0,0,"",0,0,0,0,465,'',[ minilines(54,16,0,0,0,0,0,[ mini_line(54,12,4,0,0,0,[ str_block(0,54,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,54,12,4,0,-1,0,0,0,0,0, "sender")]) ]) ])]). text('black',398,450,1,0,1,72,16,1104,12,4,0,0,0,0,2,72,16,0,0,"",0,0,0,0,462,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,12,4,0,0,0,[ str_block(0,72,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,72,12,4,0,-1,0,0,0,0,0, "receiver")]) ]) ])]). text('black',484,450,1,0,1,54,16,1103,12,4,0,0,0,0,2,54,16,0,0,"",0,0,0,0,462,'',[ minilines(54,16,0,0,0,0,0,[ mini_line(54,12,4,0,0,0,[ str_block(0,54,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,54,12,4,0,-1,0,0,0,0,0, "sender")]) ]) ])]). text('black',626,452,1,0,1,72,16,1102,12,4,0,0,0,0,2,72,16,0,0,"",0,0,0,0,464,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,12,4,0,0,0,[ str_block(0,72,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,72,12,4,0,-1,0,0,0,0,0, "receiver")]) ]) ])]). poly('black','',2,[ 666,662,505,692],0,1,1,1101,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ text('black',301,509,1,0,1,20,33,1091,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,535,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]), text('black',301,525,1,0,1,20,33,1090,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,551,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]), text('black',301,542,1,0,1,20,33,1089,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,568,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]) ], 1088,0,0,[ ]). group([ text('black',594,537,1,0,1,20,33,1087,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,563,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]), text('black',594,553,1,0,1,20,33,1086,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,579,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]), text('black',594,570,1,0,1,20,33,1085,26,7,0,0,0,0,2,20,33,0,0,"",0,0,0,0,596,'',[ minilines(20,33,0,0,0,0,0,[ mini_line(20,26,7,0,0,0,[ str_block(0,20,26,7,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,195840,20,26,7,0,-8,0,0,0,0,0, ".")]) ]) ])]) ], 1084,0,0,[ ]). poly('black','',2,[ 506,491,568,509],0,1,1,1083,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 557,517,574,501],0,1,1,1082,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 565,499,572,522],0,1,1,1081,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',722,736,1,0,1,74,27,1459,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,749,'',[ 722,736,722,736,794,752,987.688,-156.434,156.434,987.688,-203,-68,721,735,795,753],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "nack (0)")]) ]) ])]). text('black',485,756,1,0,1,145,39,1552,13,3,0,0,0,0,2,144,16,0,0,"",0,1,0,0,769,'',[ 485,756,485,756,629,772,987.688,-156.434,156.434,987.688,-203,-68,484,755,630,773],[ minilines(144,16,0,0,0,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-4,0,0,0,0,0, "nack (0,1,2,3,4)")]) ]) ])]). text('black',519,484,1,0,1,73,31,1558,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,497,'',[ 519,484,519,484,591,500,978.148,207.912,-207.912,978.148,0,-12,518,483,592,501],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "retr (0)")]) ]) ])]). text('black',517,522,1,0,1,74,33,1573,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,535,'',[ 517,522,517,522,589,538,970.296,241.922,-241.922,970.296,0,-14,516,521,590,539],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "retr (1)")]) ]) ])]). text('black',513,573,1,0,1,74,33,1576,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,586,'',[ 513,573,513,573,585,589,970.296,241.922,-241.922,970.296,0,-14,512,572,586,590],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "retr (4)")]) ]) ])]). text('black',302,479,1,0,1,73,31,1583,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,492,'',[ 302,479,302,479,374,495,978.148,207.912,-207.912,978.148,0,-12,301,478,375,496],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "data (0)")]) ]) ])]). text('black',295,511,1,0,1,73,31,1587,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,524,'',[ 295,511,295,511,367,527,978.148,207.912,-207.912,978.148,0,-12,294,510,368,528],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "data (1)")]) ]) ])]). text('black',290,572,1,0,1,73,31,1590,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,585,'',[ 290,572,290,572,362,588,978.148,207.912,-207.912,978.148,0,-12,289,571,363,589],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "data (8)")]) ]) ])]). text('black',289,611,1,0,1,100,36,1593,13,3,0,0,0,0,2,99,16,0,0,"",0,1,0,0,624,'',[ 289,611,289,611,388,627,978.148,207.912,-207.912,978.148,0,-12,288,610,389,628],[ minilines(99,16,0,0,0,0,0,[ mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-4,0,0,0,0,0, "refresh (8)")]) ]) ])]). arc('black','',0,1,1,0,418,454,469,505,444,550,494,550,0,102,102,-7616,3776,1669,0,1,8,3,0,0,0,'1','8','3',0,[ ]). poly('black','',2,[ 667,367,506,397],0,1,1,2575,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',738,440,1,0,1,74,27,2576,13,3,0,0,0,0,2,72,16,0,0,"",0,1,0,0,453,'',[ 738,440,738,440,810,456,987.688,-156.434,156.434,987.688,-203,-68,737,439,811,457],[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-4,0,0,0,0,0, "nack (3)")]) ]) ])]). tgif-QPL-4.2.5/rmcast/doc/manual/tgwb.tex0000644000076400007640000026555411225226450020013 0ustar williamwilliam%% LyX 1.3 created this file. For more info, see http://www.lyx.org/. %% Do not edit unless you really know what you are doing. \documentclass[english]{article} \usepackage[T1]{fontenc} \usepackage[latin1]{inputenc} \usepackage{a4wide} \usepackage{color} \usepackage{graphicx} \makeatletter %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands. \newcommand{\noun}[1]{\textsc{#1}} %% Because html converters don't know tabularnewline \providecommand{\tabularnewline}{\\} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Textclass specific LaTeX commands. \newenvironment{lyxcode} {\begin{list}{}{ \setlength{\rightmargin}{\leftmargin} \setlength{\listparindent}{0pt}% needed for AMS classes \raggedright \setlength{\itemsep}{0pt} \setlength{\parsep}{0pt} \normalfont\ttfamily}% \item[]} {\end{list}} \AtBeginDocument{ \renewcommand{\labelitemi}{\(\cdot\)} } \usepackage{babel} \makeatother \begin{document} \title{The Reliable Multicast Library (RML) and Tangram II Whiteboard Developer Documentation} \author{Jorge Allyson Azevedo, Milena Scanferla, Daniel Sadoc\\ \{allyson,milena,sadoc\}@land.ufrj.br} \maketitle \section{Introduction} The main goal of this article is to explain some topics about what a programmer needs to know in order to make source code changes in the Reliable Multicast Library (RML) and in the Tangram II Whiteboard. We will also give comments about problems found and the solutions adopted while developing the RML and the Tangram II \cite{key-30} Whiteboard tool - including references to books, newsgroups or articles that may be useful for the interested readers. In the following section we will take a look at general characteristics of IP multicast. Then, the reliable multicast approach used in the implemented RML will be describe. We will introduce the library, and show a sample program that makes use of it - a chat. After that, a more complex example - the Tangram II Whiteboard (TGWB). In the Appendix, we will describe the operating system interprocess communication (IPC) resources that which have been used. % \begin{figure}[hbpt] \begin{center}\includegraphics[% width=1.0\columnwidth]{screencapt.eps}\end{center} \caption{TGWB Screenshot} \end{figure} \section{IP Multicast } \subsection{Introduction} Quoting from the Multicast HOWTO \cite{key-33}: {}``... multicast is a need ... Well, at least in some scenarios. If you have information (a lot of information, usually) that should be transmitted to various (but usually not all) hosts over an internet, then Multicast is the answer. One common situation in which it is used is when distributing real time audio and video to the set of hosts which have joined a distributed conference. Multicast is much like radio or TV in the sense that only those who have tuned their receivers (by selecting a particular frequency they are interested on) receive the information. That is: you hear the channel you are interested in, but not the others.'' \subsubsection{Multicast Addressing} The range of IP addresses is divided into \char`\"{}classes\char`\"{} based on the high order bits of a 32 bits IP address: \\ \texttt{\textit{\textcolor{black}{0~~~~~~~~~~~~~~~~~~~~~~~~~~ 31~~~~~~~~~ Address Range:}}} \texttt{\textit{\textcolor{black}{+-+-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-+}}} \texttt{\textit{\textcolor{black}{|0|~~~~~~ Class A Address~~~~~ |~~~~ 0.0.0.0 - 127.255.255.255}}} \texttt{\textit{\textcolor{black}{+-+-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-+}}} \texttt{\textit{\textcolor{black}{+-+-+-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-+}}} \texttt{\textit{\textcolor{black}{|1 0|~~~~ Class B Address~~~~~ |~~ 128.0.0.0 - 191.255.255.255}}} \texttt{\textit{\textcolor{black}{+-+-+-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-+}}} \texttt{\textit{\textcolor{black}{+-+-+-+-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-+}}} \texttt{\textit{\textcolor{black}{|1 1 0|~~ Class C Address~~~~~ |~~ 192.0.0.0 - 223.255.255.255}}} \texttt{\textit{\textcolor{black}{+-+-+-+-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-+}}} \texttt{\textit{\textcolor{black}{+-+-+-+-+-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-+}}} \texttt{\textit{\textcolor{black}{|1 1 1 0|~ MULTICAST Address~~ |~~ 224.0.0.0 - 239.255.255.255}}} \texttt{\textit{\textcolor{black}{+-+-+-+-+-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-+}}} \texttt{\textit{\textcolor{black}{+-+-+-+-+-+-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-+}}} \texttt{\textit{\textcolor{black}{|1 1 1 1 0|~~~~ Reserved~~~~~~ |~~ 240.0.0.0 - 247.255.255.255}}} \texttt{\textit{\textcolor{black}{+-+-+-+-+-+-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-+}}}~\\ The multicast addresses start with {}``1110''. Among the multicast addresses, the remaining 28 bits identify the multicast group. There are some special addresses that should not be used by common applications: % \begin{table}[hbpt] \begin{center}\begin{tabular}{|c|c|} \hline Address& Function\tabularnewline \hline \hline 224.0.0.1& All hosts in the LAN\tabularnewline \hline 224.0.0.2& All routers in the LAN\tabularnewline \hline 224.0.0.4& All routers DVMRP in the LAN\tabularnewline \hline 224.0.0.5& All routers OSPF in the LAN\tabularnewline \hline 224.0.0.6& All routers OSPF designated in the LAN\tabularnewline \hline 224.0.0.13& All the PIM routers in the LAN\tabularnewline \hline \end{tabular}\end{center} \caption{\label{mcast special addresses}Multicast special addresses} \end{table} The interval from 224.0.0.0 to 224.0.0.255 is reserved to local purposes (local administrative tasks) - to see some of these address purposes, refer to table \ref{mcast special addresses}. Similarly, the interval from 239.0.0.0 to 239.255.255.255 is also reserved for administrative tasks - but not necessarily local tasks. So, the interval that may be used by general multicast applications is from 225.0.0.0 to 238.255.255.255. \subsubsection{Multicast Group} A multicast group is composed by the set of hosts in a network which share data via multicast. This group is identified by a multicast address. When a host sends a packet to the multicast address, this packet is received by all the multicast group members. The transmission of a packet from one sender to multiple receivers is accomplished by a single send operation. A single packet is sent from the sender host - there is no need to send multiple copies of this packet, as would be needed if unicast were used. The receivers may join and leave the multicast group in a dynamic way. The network devices, specially the routers, have to determine which of their interfaces have a multicast member connected to them. \subsubsection{Levels of conformance} Hosts can be in three different levels of conformance with the Multicast specification, according to the requirements they meet: \begin{itemize} \item \textbf{Level 0} is the \char`\"{}no support for IP Multicasting\char`\"{} level. Lots of hosts and routers in the Internet are in this state, as multicast support is not mandatory in IPv4 (it is, however, in IPv6). Not too much explanation is needed here: hosts in this level can neither send nor receive multicast packets. They must ignore the ones sent by other multicast hosts. \item \textbf{Level 1} is the \char`\"{}support for sending but not receiving multicast IP datagrams\char`\"{} level. Thus, note that it is not necessary to join a multicast group to be able to send datagrams to it. Very few additions are needed in the IP module to make a \char`\"{}Level 0\char`\"{} host \char`\"{}Level 1-compliant\char`\"{}. \item \textbf{Level 2} is the \char`\"{}full support for IP multicasting\char`\"{} level. Level 2 hosts must be able to both send and receive multicast traffic. They must know the way to join and leave multicast groups and to propagate this information to multicast routers. Thus, they must include an Internet Group Management Protocol (IGMP) implementation in their TCP/IP stack. \end{itemize} The Multicast Reliable Library was developed considering that the hosts are in level 2 of conformance. \subsubsection{Some benefits of Multicast} Some benefits of multicast over unicast are presented below\cite{key-35}: \begin{enumerate} \item Optimized use of the network - the intelligent use of the network resources avoids unnecessary replication of data. So, the links are better used, through a better architecture of data distribution. \item Distributed application support - the multicast technology is directly focused on distributed applications. Multimedia applications like distance learning and video conferencing may be used in the network in an efficient way. \item Scalability - services that use multicast can be accessed by many hosts, and may accept new members at any time. \item Availability of the network resources - congestion is reduced, because no replicated data is sent through a single link in the network, so the availability of the network resources is increased. \end{enumerate} \subsection{Configuration under Linux } This section will not explain multicast configuration in details. We just want to give some tips needed to set up a basic system in a local network area. If you want further information see the Multicast HOWTO \cite{key-33}. Multicast transmission through different networks is more complex and you must have routers with multicast support between those networks. \subsubsection{Does your system have support for IP Multicast? } Some configurations are needed to use IP Multicast. First of all, the network cards have to be enabled to receive multicast data. Most network cards modules automatically set the MULTICAST flag. In GNU/Linux systems, you can check whether your network interface has multicast support by typing the following command: \begin{quotation} \texttt{\footnotesize ifconfig -a}{\footnotesize \par} \end{quotation} An ifconfig output example follows: \begin{verse} \texttt{\footnotesize eth0 }{\footnotesize \par} \texttt{\footnotesize Link encap:Ethernet HWaddr 00:50:BF:06:89:47}~\\ \texttt{\footnotesize inet addr:192.168.1.2 Bcast:192.168.1.255 Mask:255.255.255.0 }~\\ \texttt{\footnotesize UP BROADCAST RUNNING} \texttt{\textbf{\footnotesize MULTICAST}} \texttt{\footnotesize MTU:1500 Metric:1 }~\\ \texttt{\footnotesize RX packets:12438583 errors:0 dropped:0 overruns:0 frame:0 }~\\ \texttt{\footnotesize TX packets:6498370 errors:0 dropped:0 overruns:0 carrier:0 }~\\ \texttt{\footnotesize collisions:0 txqueuelen:100 }~\\ \texttt{\footnotesize RX bytes:1100375580 (1049.3 Mb) }~\\ \texttt{\footnotesize TX bytes:2158372342 (2058.3 Mb) }~\\ \texttt{\footnotesize Interrupt:10 Base address:0x7000}{\footnotesize \par} \texttt{\footnotesize lo }{\footnotesize \par} \texttt{\footnotesize Link encap:Local Loopback }~\\ \texttt{\footnotesize inet addr:127.0.0.1 Mask:255.0.0.0 }~\\ \texttt{\footnotesize UP LOOPBACK RUNNING MTU:16436 Metric:1 }~\\ \texttt{\footnotesize RX packets:8361666 errors:0 dropped:0 overruns:0 frame:0 }~\\ \texttt{\footnotesize TX packets:8361666 errors:0 dropped:0 overruns:0 carrier:0 }~\\ \texttt{\footnotesize collisions:0 txqueuelen:0 }~\\ \texttt{\footnotesize RX bytes:1830657956 (1745.8 Mb) }~\\ \texttt{\footnotesize TX bytes:1830657956 (1745.8 Mb)}{\footnotesize \par} \end{verse} Note the MULTICAST flag at \textbf{eth0}. That flag is missed at \textbf{lo} (the loopback interface). You must have root privileges to enable the MULTICAST flag. To enable that flag you have to issue the following command: \begin{verse} \texttt{\footnotesize ifconfig multicast}{\footnotesize \par} \end{verse} Where \textbf{interface\_name} must be replaced by the name of the interface you want to set the MULTICAST flag. This may be useful if you want to enable multicast on a \textbf{lo} interface because that allows you to do some tests using multicast transmission even if you don't have any real network interface. The next step is to set up the route that the multicast packets will follow. To add this route, as root user, issue the following command: \begin{verse} \texttt{\footnotesize route add -net 224.0.0.0 netmask 240.0.0.0 dev }{\footnotesize \par} \end{verse} Where \textbf{interface\_name} must be replaced by the name of the interface to which you want to send the multicast packets. Again, if you are testing on a single machine this interface will be the \textbf{lo.} To test your configuration try: \begin{verse} \texttt{\footnotesize ping 224.0.0.1}{\footnotesize \par} \end{verse} Every machine in your local network that has multicast enabled should answer this ping. \section{Reliable Multicast } \subsection{Introduction} Multicast is supported by the transport layer through the UDP protocol. As each packet may get a different path from source to destiny, packets may come out of order at the receiver host. To solve this problem, it is necessary to have a packet ordering algorithm. Besides the problem of ordering, there is also the possibility of packet loss. This loss makes the protocol unreliable. To solve these problems, which are directly related to the UDP protocol, it is necessary to create an application-level mechanism to guarantee the reliable transmission of data. There are some ways to implement the reliable multicast mechanism. For instance, the responsibility of recovering loss packets can be directed to the receiver or the sender of the data. Here, we will describe three classes of reliable multicast protocols, according to {[}FIXME{]}: \begin{enumerate} \item Sender Initiated Approach - based on confirmations (acknowledgments or ACKs) sent by receivers and processed by the senders; \item Receiver Initiated Approach - the receiver detects the loss of packets. The receiver sends negative acknowledgments (NACKs) to the sender via a unicast connection. The sender replies with retransmissions. \item Enhanced Receiver Initiated Approach - the receiver detects the loss of packets. The receiver sends negative acknowledgments (NACKs) to the group via a multicast connection. \end{enumerate} \subsubsection{Sender Initiated Approach} Every time a member receives a packet he sends a confirmation (ACK) to the sender. The sender maintains a list of all the group members. When the sender sends a packet, he starts a timer for that packet, and waits for ACKs from the group members. As soon as the timer expires, if the sender haven't received an ACK from some member, this packet is retransmitted. The timer is then restarted. \subsubsection*{Advantages and disadvantages} The main advantage of this approach is that when the sender receives a confirmation (ACK), he is sure that the packet was in fact received. The main disadvantage of this approach is that for each data packet sent, the sender will receive an ACK from each receiver of the multicast session, which may cause congestion. \subsubsection*{Summary} \begin{enumerate} \item every time the sender transmits or retransmits a data packet he starts a timer for this packet and wait for the ACKs from the receivers; \item every time the receiver receives a data packet he sends a confirmation (ACK) to the sender in a unicast connection. \end{enumerate} \subsubsection{Receiver Initiated Approach} In this approach, the receiver has the responsibility of detecting the packet losses. When the receiver doesn't receive a data packet, he sends a negative acknowledgment (NACK) to the sender, via a unicast connection. The sender will retransmit the data packet when he receives a NACK. The packet loss is detected when a receiver receives a packet with sequence number (sn) i + 1 without having received the packet with sn i. For instance, if the receiver receives packets with sn 0, 1 and 3, he will know that packet with sn 2 was lost. \subsubsection*{Advantages and disadvantages} In general, the loss probability of a packet is smaller than the success probability. So, few NACK packets will be sent through the network. The disadvantage of this approach is that just the sender of the message will be notified that a packet was lost, and only he may retransmit the data packet. \subsubsection*{Summary} \begin{enumerate} \item every time the receiver detects a packet loss he sends a negative acknowledgment (NACK) to the sender, via a unicast connection, and starts a timer to wait for a retransmission. \item every time the sender receives a NACK packet he sends a retransmission to the group via multicast connection. \end{enumerate} \subsubsection{Enhanced Receiver Initiated Approach} That's a variation of the receiver initiated approach. When a loss is detected, a timer is scheduled. If the timer expires and a NACK for that packet has not been received, the receiver multicasts the request message to the group. If a NACK was received before the timer has expired, the receiver will not send the request message, because he knows that a retransmission request has already been sent by some other member. \subsubsection*{Advantages and disadvantages} The advantage of this approach is that it limits the number of NACKs which will be sent through the network. The disadvantage is that when the loss probability is high, there will be many NACK packets in the network. Each member of the group will receive all the NACKs sent. This may consume a lot of processing time. \subsubsection*{Summary} \begin{enumerate} \item every time the receiver detects a packet loss, he starts a timer to send a NACK packet. \begin{enumerate} \item If he receives a NACK for the same packet which was lost, the transmission of the NACK is canceled (NACK suppression). \item Else, when the timer expires, he sends a NACK via multicast to the group.\\ \\ In both cases, another timer is started, in order to wait for retransmissions. If a retransmission is received, this timer is canceled, and there is nothing else to be done. The data was finally successfully received with success. Else, the timer to send a NACK packet is restarted. We go back to item 1. \end{enumerate} \item every time a member receives a NACK packet, he schedules the retransmission of the requested packet. \end{enumerate} \section{The Reliable Multicast Library (RML)} In this section we will describe how the Reliable Multicast Library works. In section 4.1, definitions will be given. In section 4.2 the mechanisms of how new members join and leave the group will be explained. Then, we will describe how lost packets are recovered in section 4.3. In section 4.4 we show the implementation of the Event List. Finally, we summarize the RML messages and actions in section 4.5. \subsection{Definitions} Before starting the description of the RML protocol, it is important to define some terms that will be used: \begin{itemize} \item \textbf{Multicast Session}: a multicast session is the period of time when a multicast group is active. A multicast group is active if we have at least one member on it. \item \textbf{ACK}: a special packet, the acknowledgment (ACK) packet, is used to confirm the receiving of data. For instance, in the TCP protocol, the sender always waits for confirmations sent by the receivers via ACKs. \item \textbf{NACK}: a special packet, the negative acknowledgment (NACK) packet, is used to inform that data was lost. If a receiver finds out that data was lost, he may send NACKs to the sender in order to advertise this problem, and request retransmissions. \item \textbf{Timers}: the time that a member waits in order to execute a specific action (event). This time may be random, with an uniform or exponential distribution. \item \textbf{Event List}: list containing all the events that will be executed. When the timer for a specific event expires, this event is removed from the event list and then executed. \item \textbf{Cache:} structure maintained by the multicast members which stores the last messages received from every member of the multicast session. \end{itemize} \subsection{Multicast Session Members Management} May anyone join a multicast session at any time? What does a new member need to get in order to become a member of a multicast session? What about the exit procedure? If a member wants to leave the group, may he go away immediately? Or should he wait a bit before exiting? This section will answer this questions. Let's start with the join procedure. If every member of the multicast group entered the session always at the same time, the join procedure would be very simple. The problem is that, in practice, a new member may want to join the session a long time after the session has started. If that happens, this member may not be able to get into a consistent state just requesting retransmissions to the older members of the group. That's because the size of the cache of the other members of the group is finite. The data requested by the new member may not be any more in the cache of the older members. During a session, each member maintains a certain quantity of data in his own cache. When this cache gets full, new data replaces the oldest. If a new member enters the group a long time after the session has started, it may happen that he won't be able to receive the older data, since it has been replaced in all the current members caches. For some applications, that may not be a problem. But for drawing applications, such as the TGWB, in which there is a dependency between the data, this problem must be regarded with attention. For instance, the first message received by a member, in a drawing tool, may instruct the application that a rectangle must be drawn. In the future, another message may instruct that the color of this same rectangle must be changed. Thus, the later command only may be executed after the first one has already been executed. In other words, it makes no sense try to change a color of an inexistent rectangle. In order to solve this problem the following mechanism was implemented: when a new member wants to enter the group, he gets, via TCP, the current state of the multicast session from an older member. The current state is composed by all the elements that this member must have in order to join the group, including the cache of the older member. In more details, when a new member wants to join the group, he sends a {}``join request'' message to the multicast group, starts a timer and waits for an {}``accept'' message. This {}``accept'' message will contain information (address and port) of a member of the group. The new member will connect, via TCP, to this member and get his current state. Then, this new member may be considered a member of the group, as the others. If this timer expires before the new member receives an \char`\"{}accept\char`\"{} message, he considers himself the first member of the group. When an old member of the group receives a {}``join request'' message, he starts another timer, waiting to send an {}``accept'' message. If an {}``accept'' message is received before the timer expires, this member suppresses his transmission, and stops his timer. Otherwise, if the timer expires, he sends the {}``accept'' message. This mechanism minimizes the number of {}``accept'' messages sent by the old members of the group, since when one member detects that another one has already sent an {}``accept'', he cancels his own transmission. To see more details about how this mechanism of joining the group is implemented, please consult the subsection titled {}``Thread 5 - Current State Server Thread'', in section 7.1. Now, let's see what happens when a member wants to leave the group. Suppose a member wants to leave the group. First, he sends a {}``leave group'' message to all the members of the group to advertise his intention. Then, he starts a timer and when this timer expires, the member in fact leaves the group. During this latency period, he is still able to send eventual retransmissions. When the other members of the group receive the {}``leave group'' message, they turn off the {}``active'' bit in their cache related to the member who sent the {}``leave group'' message. \subsection{Loss Detection and Data Recovery } Every data message transmitted by the protocol is identified by its sequence number. When a data message is received from the application to be transmitted for the multicast group, a header is added to indicate the proper sequence number (sn). Afterward the data message is transmitted for the group. \subsubsection{The Cache Structure} Every member has a cache structure where he stores some information about the members, this cache has an entry for each member of the multicast session. In the figure \ref{rml cache strucuture} we can see the cache structure. Each cache entry has some fields that we will describe below: \begin{itemize} \item \textbf{number\_of\_nodes:} number of data packets received from the member \item \textbf{active:} indicates whether a member is currently active in the multicast session \item \textbf{first:} a pointer to the first packet of the packet list - the packet list stores the last data packets received from the member \item \textbf{sm\_info:} is a structure composed by \emph{member\_id} and \emph{member\_status} \end{itemize} The structure sm\_info, as described, is composed by: \begin{itemize} \item \textbf{member\_id}: member identification structure composed by the member IP address and the process ID (PID) \item \textbf{member\_status:} is a structure that stores the current member status, e.g., the first and the last sn received \end{itemize} Finally, member\_status is composed by: \begin{itemize} \item \textbf{first\_rcv:} the sequence number (sn) of the first packet received from the member \item \textbf{last\_rcv:} the sn of the last packet received from the member \item \textbf{last\_seq\_rcv:} the sn of of the last in-order packet received from the member \item \textbf{last\_identified}: \textbf{}the greatest sn of the member packet list \item \textbf{window\_size:} the maximum size of the NACK window, i.e, the maximum number of NACKs that we can send in a specific time \item \textbf{window\_mask}: \textbf{}it is an array to identify the sn of the lost packets. Where 1 means that we are going to send a NACK for that packet and 2 means that we are waiting for the retransmission for that packet \item \textbf{window\_ini:} the position of the smallest sn represented in the window\_mask. \item \textbf{nak\_list:} the list of NACKs that have been sent. This list controls the number of NACKs sent by each sn. \end{itemize} % \begin{figure}[hbpt] \begin{center}\includegraphics[% width=1.0\columnwidth]{cache.eps}\end{center} \caption{\label{rml cache strucuture}RML Cache structure} \end{figure} \subsubsection{Loss Detection} When a member of the multicast group receives a data packet, he checks the packet sequence number and the sender identification. Then, the member tries to match the sender identification with some \emph{member\_id} in his cache. If he is successful in that matching, the sender is already in the cache. Otherwise a node for the new member must be inserted in the cache. After that, the member has to check whether or not the received packet is in sequence. If the sequence number (sn) is in order, i.e., \texttt{sn=last\_seq\_rcv+1}, the packet is inserted in the cache and passed to the application. If the sequence number is not in sequence, the member has found out that packets were lost - a gap was detected. Detected the loss, it is necessary to execute the procedures for recovering the lost packets. The data packet received out of order is inserted and kept in the cache. It will be released to the application after all lost data have been recovered. The recovery procedure consists of requesting retransmissions for the lost data packets, in other words, to send NACK messages for the multicast group. For instance, as it can be seen in figure \ref{rml cache strucuture}, if the losses of data packets 2 and 3 were detected, then the member is supposed to send requests for retransmission of those data packets. Any member of the multicast session that has the requested data is able to retransmit it. In that way, the retransmission responsibility is distributed. The loss detection discussed before can fail when the lost packet is the last packet transmitted by the sender. Suppose that a member A has sent his last data packet with sn=10 and that member B has lost that packet. Member B is unable to detect the loss until he receives a new data packet from member A. But we have supposed that A will not send new packets. In that situation, there must be another way of detecting the loss. To solve that problem, members send a {}`` refresh message'' periodically indicating the sn of the last packet sent. When a member receives the {}``refresh message'', he is able to identify the lost packets and to start the recovering procedures. In our example, member B would receive a {}``refresh message'' from member A and then would be able to detect and recover the lost packet. \subsubsection{Sending NACKs} Suppose a scenario where a member of the multicast group sends a data packet to the other members, and all the other members lose that packet. Now, suppose that a NACK packet is sent by every member immediately after the loss is detected. That action may cause an unnecessary traffic in the network. That problem is called NACK implosion\cite{key-36}. One solution is to wait for a random time T\emph{\footnotesize nack} before sending a NACK message. As other members of the multicast group might have lost the same data message, and considering that T\emph{\footnotesize nack} is random, there will be a member who will choose a smaller timer and send the NACK message before the others. If before T\emph{\footnotesize nack} expires the member receives a NACK message or a retransmission of the lost data, the transmission of the NACK message will be canceled. So, if we choose an efficient way to determine T\emph{\footnotesize nack} we will have a great probability of suppressing the sending of duplicated NACK messages through the network. Besides the implosion of NACKs, another problem that may happen related to the sending of NACK messages is that the member may request more data than he is able to handle. In fact, this two problems are similar to the ones faced in the unicast case. The congestion control, used in the TCP, is implemented in order to avoid network congestion. The flow control, also used in the TCP, tries to get rid of the buffer overflow in the client application. More information about TCP mechanisms can be found in chapter 3 of \cite{key-3}. As described in the last paragraph, the NACK suppression algorithm tries to solve a problem analog to the one solved by the congestion control in the unicast case. In that way, the congestion control and NACK suppression algorithm attempt to avoid a network core congestion while the unicast and multicast flow control attempt to prevent the overflow that may happen at the network hosts (end systems) buffers. RML implements a simple flow control: the amount of NACKs sent should not exceed the amount of data that the member expecting this packets may process at once. % \begin{figure}[hbpt] \begin{center}\includegraphics{flowcontrol.eps}\end{center} \caption{\label{rml flow control}RML Flow Control} \end{figure} Two possible scenarios for flow control are illustrated in figure \ref{rml flow control}. Suppose that packets with sn from 0 to 8 were transmitted by the sender. Those packets were lost by the receiver. The receiver detects the loss when he receives a refresh message from the sender. Then there are two ways of dealing with that loss. The first approach, which we call \emph{Naive Approach}, is, in fact, an approach with no flow control. The problem with this approach is that the receiver will send a large amount of NACK messages and it may happen that the amount of retransmission received in response to those NACKs may be greater than the cache space available. Thus, old data packets, that have not already been sent to the application, will be replaced by new ones. In figure \ref{rml flow control} the packet with sn 0 was lost. The receiver has a cache with five slots. It may be seen that data packets from 1 to 5 were first stored in the cache. Note that those packets were not sent to the application because the packet with sn 0 is missed. Then, packets from 6 to 8 were received and replaced packets 1, 2 and 3. After that, the receiver must send NACKs to recover packets from 0 to 3. We can see that it is not useful to replace packets that have not already been sent to the application. In the second approach, which we call \emph{Flow Control Approach}, when a loss is detected the receiver only send NACKs for a certain amount of packets, i.e., the amount he is able to handle. In addition, the receiver requests those retransmissions in only one NACK message. Note in figure \ref{rml flow control} that the first NACK sent requests retransmissions for packets with sn 0 to 4 because there were five free slots in the cache. The second NACK requests only the retransmission of packet 0 because there was only one free slot in the cache at that time. Using the Flow Control Approach two NACKs were sent, while in the Naive Approach they were thirteen. % \begin{figure}[hbpt] \begin{center}\includegraphics[% width=1.0\columnwidth]{packet_types.eps}\end{center} \caption{\label{rml packet types}RML Packet Types} \end{figure} The RML uses the \emph{window\_mask}, \emph{window\_size} and \emph{window\_ini} parameters to bound the NACK transmission. The \emph{window\_size} has a value of 64, i.e., we can request at most 64 retransmissions per NACK message. The \emph{window\_size} value was chosen just for implementation purposes. With that value we can represent the \emph{window\_mask} using only two integers in the NACK packets, as shown in figure \ref{rml nack mask}. The \emph{window\_ini} points to the first position in the \emph{window\_mask} array. The NACK packet is mounted using those parameters. In figure \ref{rml packet types}, there is a description of the packet structures used in RML. The NACK packet is composed by a set of fields, among them we have : \begin{itemize} \item \textbf{base\_sn:} the value of the sn of the first NACK in the \emph{window\_mask} \item \textbf{window\_size:} the value of \emph{window\_size} of the cache, default is 64 \item \textbf{hmask:} an integer that represents the higher part of the NACK mask \item \textbf{lmask:} an integer that represents the lower part of the NACK mask \end{itemize} % \begin{figure}[hbpt] \begin{center}\includegraphics{nack_mask.eps}\end{center} \caption{\label{rml nack mask}RML NACK mask} \end{figure} Suppose a NACK message from member M has arrived with \emph{base\_sn=5, window\_size=64, hmask=1} and \emph{lmask=3.} To find out which retransmission has been requested by member M we have to translate \emph{hmask} and \emph{lmask} to their binary representation. This translation is shown in figure \ref{rml nack mask}. The requests can be identified using the position of the bits with value of 1 plus the \emph{base\_sn}. In our scenario, the requests are for the packets with sn 5 (0+5), 6 (1+5) and 37 (32+5). After sending a NACK message, the member waits for a retransmission during a random period of time, called T\emph{\footnotesize wait}. If the requested retransmission is not received after T\emph{\footnotesize wait} units of time, a new NACK message is sent. The maximum number of NACKs is limited by {\small the MAX\_NAK} parameter, which the user may set in the rmcast.config file (see section 5.3 to learn about RML configuration). If MAX\_NAK is reached, i.e., a data packet couldn't be recovered - the application is then suspended. \subsubsection{Data Retransmission} In the RML each member maintains in his cache the last N data packets he has received from other members. Thus, any member of the multicast group is able to answer to a request for retransmission of the last N messages he has received from each other member. This mechanism distributes the responsibility of retransmission among all the members of the multicast session, but it may create a lot of traffic if every member answers to a NACK message. As was explained in section 4.3.3, we use random timers to avoid this traffic problem. Suppose a member A receives a NACK message from member B regarding a specific lost packet P from member C. If the packet P is stored in A's cache, then member A schedules a random timer T\emph{\footnotesize ret} to wait before sending a retransmission. There are two situations that may occur before T\emph{\footnotesize ret} timed out: \begin{enumerate} \item a retransmission of the packet P is received: the A's retransmission is aborted because another member has already answered the request. \item a NACK message regarding the same packet P is received: the NACK message is ignored because the retransmission is already scheduled. \end{enumerate} If T\emph{\footnotesize ret} expires and neither (1) nor (2) has occurred, then the retransmission is sent. \subsection{The Event List } A common activity of the reliable multicast library (RML) is to schedule an event to happen some time in the future. Almost every action that is taken by the RML is not executed immediately when it is requested. Instead, events are scheduled in order to perform the tasks. When a loss of packets is detected, for example, an event is scheduled to send a negative acknowledgment (NACK) after a certain period of time. If, before the timeout, the member receives a retransmission of the lost packet or if the member receives a NACK for the considered packet, then the sending of the NACK is canceled. In the last case, the sending of the NACK is suppressed because another member has just sent the NACK. In order to reduce the network traffic, a member just sends a message after waiting to see if this message was just sent by another member. The key point here is to keep the work distributed but avoiding redundancy. The event list of the Reliable Multicast Protocol is an implementation of a conventional delta list \cite{key-37}. The list is a chain of event nodes. The event nodes are stored in increasing order of when the event occurs. Each event node contains the information needed to execute the event - the event type, described below, and some other information, depending on the event type - as well as the time in the future that the event should take place. The time stored in each event is relative to the preceding event. For example, suppose there are five events scheduled for 4, 6, 6, 13 and 17 time units in the future. This would result in the event list illustrated in figure \ref{rml simple event list}. Notice that the third event record contains a 0 because it occurs 0 time units after the second event. % \begin{figure}[hbpt] \begin{center}\includegraphics{simple_event_list.eps}\end{center} \caption{\label{rml simple event list}RML Event List - a simple example} \end{figure} The first event node is the next one that will be executed. When an event is inserted at the head of the list, an operating system alarm signal is scheduled to fire after the time indicated at the header node of the list. When the alarm fires, the event node is processed and removed. All the subsequent events that have time of 0 are also executed and removed. Then the alarm is restarted. To schedule a new event, the event manager walks down the list and inserts a record for the new event in the appropriate location, being careful to adjust the relative time of both the new and the event immediately following the new event. Deleting an event from the event list is implemented in an analogous way. The event nodes are divided into five types: \begin{itemize} \item NAK\_SND\_WAIT- used to schedule a sending of a negative acknowledgment; \item RET\_RCV\_WAIT- used to wait for retransmissions; \item RET\_SND\_WAIT- created to schedule a sending of a retransmission; \item REF\_SND\_WAIT- used to schedule a refresh; \item LEV\_GRP\_WAIT- specifies the time between a user requests to go away from the group and the actual moment when the user leaves the group. \end{itemize} Suppose there is one NAK\_SND\_WAIT event scheduled for 4 time units in the future, in order to send a NACK to a packet initially sent by member M1. Suppose also that there is one REF\_SND\_WAIT scheduled for 6 time units in the future, and a RET\_SND\_WAIT for 17 time units in the future. This retransmission refers to packet 4 of member M2. This would result in the event list illustrated in figure \ref{rml detailed event list}. Note that the NAK\_SND\_WAIT event node contains a pointer to the cache entry of member M1. The cache entry of M1 will contain the information about what packets from member M1 were lost. When the event NAK\_SND\_WAIT fires, searching the cache we will find out which packets of member M1 were lost, and then send a NACK message to request these packets. On the other hand, the REF\_SND\_WAIT does not require any other information. Finally, the RET\_SND\_WAIT schedules a retransmission, and to identify the message to be retransmitted we need both the member id of the message and its sequence number. % \begin{figure}[hbpt] \begin{center}\includegraphics[% width=1.0\columnwidth]{eventlist.eps}\end{center} \caption{\label{rml detailed event list}RML Event List - a more detailed example} \end{figure} Figure \ref{rml event handlers} depicts how the different events are handled. % \begin{figure}[hbpt] \begin{center}\includegraphics[% width=1.0\columnwidth]{fleventlist.eps}\end{center} \caption{\label{rml event handlers}RML Event Handlers} \end{figure} \subsection{RML log generation} The RML offers the option of log generation. The log file name is configured through the LOG\_FILE option (see section 5.3 for further information about RML parameters configuration). The file will be created at the current directory and the host name and process ID will be appended to the file name provided in the LOG\_FILE option. Suppose LOG\_FILE=\emph{log} and the application that uses the RML is called from the \emph{/tmp} directory at the \emph{machine01}. Then, the log file name will be \emph{/tmp/log.machine01.137}, where \emph{137} is the process ID of the application. A log file sample is showed below: \texttt{\scriptsize \hfill{}}~\\ \texttt{\scriptsize host: receiverhost}~\\ \texttt{\scriptsize ip: 192.168.1.2}~\\ \texttt{\scriptsize pid: 18348}~\\ \texttt{\scriptsize -{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-}~\\ \texttt{\scriptsize time snd/rcv/loss type sender\_ip~ sender\_pid requested\_ip~ requested\_pid sn~ {[}\{base\_sn\} \{win\_size\} \{hmask\} \{lmask\}{]}}~\\ \texttt{\scriptsize -{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-}~\\ \texttt{\scriptsize 51800783466~~ L~~ RF~~ 192.168.1.1~ 13893~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -1}~\\ \texttt{\scriptsize 51808642569~~ L~~ DT~~ 192.168.1.1~ 13893~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 0}~\\ \texttt{\scriptsize 51810314729~~ S~~ RF~~ 192.168.1.2~ 18348~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -1}~\\ \texttt{\scriptsize 51829942926~~ R~~ DT~~ 192.168.1.1~ 13893~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 48}~\\ \texttt{\scriptsize 51829947209~~ S~~ NK~~ 192.168.1.2~ 18348~ 192.168.1.1~~~~~~~~~ 13893~~~~~~~~~~ -1~~~~~~~~~ 64~~~~ 29280~ 235372671}~\\ {\scriptsize \par} The header of the log file is composed by the host name, ip address and process ID. Then a short description of the log structure is presented. After that, each line describe a packet that was received or sent by the member. The fields are: \begin{itemize} \item \textbf{time:} indicates the time when the packet was received or sent \item \textbf{snd/rcv/loss:} indicates if the packet was sent (S), received (R) or received but lost because of loss simulation (L). \item \textbf{type:} indicates the packet type, i.e., NACK(NK), data(DT), retransmission(RT), refresh(RF), join accept(JA), join request(JR), leave group(LG) and unknown(UN). \item \textbf{sender\_ip:} indicates the IP address of the sender \item \textbf{sender\_pid:} indicates the process ID of the sender \item \textbf{requested\_ip:} this field appears when a NACK or a retransmission packet is received. If the NACK is requesting the retransmission from packets sent by member C, this field indicates C's IP address. \item \textbf{requested\_pid:} this field only appears when a NACK or a retransmission packet is received. If the NACK is requesting the retransmission from packets sent by member C, this field indicates C's process ID. \item \textbf{sn:} this field has different meanings depending on the packet type. When the packet is data or retransmission, this field indicates the sequence number of the packet. When the packet is a refresh message, this field indicates the sequence number of the last data packet sent by the member identified by sender\_ip and sender\_pid. This field does not appear for the remaining packet types. \item \textbf{base sn:} indicates the value of the sequence number of the first retransmission requested in the NACK packet. \item \textbf{win size:} indicates the window size of the NACK packet \item \textbf{hmask:} an integer that represents the higher part of the NACK mask \item \textbf{lmask:} an integer that represents the lower part of the NACK mask \end{itemize} There is a simple shell script, called rmcastplot.bash, that can be used to generate statistics and plots from the RML log files. If you run rmcastplot.bash with no arguments it will show a short help: \paragraph{\texttt{\textmd{\footnotesize -{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-}}~\protect \\ \texttt{\textmd{\footnotesize Usage:}}~\protect \\ \texttt{\textmd{\footnotesize rmcastplot.bash {[}awk\_script\_dir{]} {[}tgif|png{]}}}~\protect \\ \texttt{\textmd{\footnotesize ~}}~\protect \\ \texttt{\textmd{\footnotesize max\_num\_pack\_sent: maximum number of sent packets}}~\protect \\ \texttt{\textmd{\footnotesize xyrange: {[}XMIN:XMAX{]}{[}YMIN:YMAX{]} gnuplot style}}~\protect \\ \texttt{\textmd{\footnotesize member1.log: full path to member log}}~\protect \\ \texttt{\textmd{\footnotesize member2\_log: full path to member log}}~\protect \\ \texttt{\textmd{\footnotesize awk\_script\_dir: optional parameter. Full path to directory where rmlog.awk script is found}}~\protect \\ \texttt{\textmd{\footnotesize tgif or png: optional parameter. Changes gnuplot output to generate Tgif files or PNG files}}~\protect \\ \texttt{\textmd{\footnotesize -{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-}}} \paragraph{\texttt{\textmd{\footnotesize ~}}} Suppose there are two members using an RML based application. They generate two log files: log.senderhost.13893 and log.receiverhost.18348. For instance, rmcastplot.bash script can be executed with the following line command: \begin{center}\texttt{\footnotesize \hfill{}}~\\ \texttt{\footnotesize rmcastplot.bash 100 {[}0:15{]}{[}0:5{]} log.senderhost.13893 log.receiverhost.18348}~\\ \texttt{\footnotesize \hfill{}}\end{center}{\footnotesize \par} The script outputs some statistics at the standard input: \texttt{\footnotesize \hfill{}}{\footnotesize \par} \texttt{\footnotesize -{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-}{\footnotesize \par} \texttt{\footnotesize Member 1 Name:~ senderhost}{\footnotesize \par} \texttt{\footnotesize Member 1 IP:~ 192.168.1.1}{\footnotesize \par} \texttt{\footnotesize Member 1 PID: 13893}{\footnotesize \par} \texttt{\footnotesize Member 2 Name:~ receiverhost}{\footnotesize \par} \texttt{\footnotesize Member 2 IP:~ 192.168.1.2}{\footnotesize \par} \texttt{\footnotesize Member 2 PID: 18348}{\footnotesize \par} \texttt{\footnotesize -{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-}{\footnotesize \par} \texttt{\footnotesize ~ Data related to}{\footnotesize \par} \texttt{\footnotesize ~ log.senderhost.13893 -> 192.168.1.2:18348}{\footnotesize \par} \texttt{\footnotesize -{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-}{\footnotesize \par} \texttt{\footnotesize Data sent:~~~ 101}{\footnotesize \par} \texttt{\footnotesize Data received from 192.168.1.2:18348~~ 1}{\footnotesize \par} \texttt{\footnotesize NACKs sent:~~~~ 0}{\footnotesize \par} \texttt{\footnotesize NACKs received from 192.168.1.2:18348~~~ 5}{\footnotesize \par} \texttt{\footnotesize Refresh sent:~ 9}{\footnotesize \par} \texttt{\footnotesize Refresh received from 192.168.1.2:18348 16}{\footnotesize \par} \texttt{\footnotesize Retrans sent:~ 51}{\footnotesize \par} \texttt{\footnotesize Retrans received from 192.168.1.2:18348 0}{\footnotesize \par} \texttt{\footnotesize Total simulated loss:~~ 0}{\footnotesize \par} \texttt{\footnotesize Data loss with simulation from 192.168.1.2:18348~~~ 0}{\footnotesize \par} \texttt{\footnotesize NACKs lost by simulation from 192.168.1.2:18348~~~ 0}{\footnotesize \par} \texttt{\footnotesize Refresh lost by simulation from 192.168.1.2:18348~~~ 0}{\footnotesize \par} \texttt{\footnotesize Retrans lost by simulation from 192.168.1.2:18348~~~ 0}{\footnotesize \par} \texttt{\footnotesize Packets identified:~ 517}{\footnotesize \par} \texttt{\footnotesize -{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-}{\footnotesize \par} \texttt{\footnotesize ~}{\footnotesize \par} \texttt{\footnotesize -{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-}{\footnotesize \par} \texttt{\footnotesize ~ Data related to}{\footnotesize \par} \texttt{\footnotesize ~ log.receiverhost.18348 -> 192.168.1.1:13893}{\footnotesize \par} \texttt{\footnotesize -{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-}{\footnotesize \par} \texttt{\footnotesize Data sent:~~~ 1}{\footnotesize \par} \texttt{\footnotesize Data received from 192.168.1.1:13893~~ 65}{\footnotesize \par} \texttt{\footnotesize NACKs sent:~~~~ 5}{\footnotesize \par} \texttt{\footnotesize NACKs received from 192.168.1.1:13893~~~ 0}{\footnotesize \par} \texttt{\footnotesize Refresh sent:~ 7}{\footnotesize \par} \texttt{\footnotesize Refresh received from 192.168.1.1:13893 11}{\footnotesize \par} \texttt{\footnotesize Retrans sent:~ 0}{\footnotesize \par} \texttt{\footnotesize Retrans received from 192.168.1.1:13893 36}{\footnotesize \par} \texttt{\footnotesize Total simulated loss:~~ 54}{\footnotesize \par} \texttt{\footnotesize Data loss with simulation from 192.168.1.1:13893~~~ 36}{\footnotesize \par} \texttt{\footnotesize NACKs lost by simulation from 192.168.1.1:13893~~~ 0}{\footnotesize \par} \texttt{\footnotesize Refresh lost by simulation from 192.168.1.1:13893~~~ 3}{\footnotesize \par} \texttt{\footnotesize Retrans lost by simulation from 192.168.1.1:13893~~~ 15}{\footnotesize \par} \texttt{\footnotesize Packets identified:~ 453 }{\footnotesize \par} \texttt{\footnotesize -{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-{}-}{\footnotesize \par} \hfill{} Besides those statistics, if you have gnuplot\cite{key-38} installed in your system, some plots will be generated. One of those plots is showed in figure \ref{log plot}. % \begin{figure}[hbpt] \begin{center}\includegraphics{log_plot.eps}\end{center} \caption{\label{log plot}Log plotted with the rmcastplot.bash script} \end{figure} \subsection{Summary} Figure \ref{rml actions on receiving packets} summarizes the RML behavior on receiving each packet type. % \begin{figure}[hbpt] \begin{center}\includegraphics[% width=1.0\textwidth, height=1.0\textwidth]{actions_on_receiving_packets.eps}\end{center} \caption{\label{rml actions on receiving packets}Actions taken on receiving each packet type} \end{figure} \section{A simple example: the chat program } In this section we will describe a simple chat application that uses the RML. We hope that this simple example may be used to show how to develop an application based on our RML. \subsection{Minimal requirements to create an Reliable Multicast based application} The development of a Reliable Multicast application has some requirements as follow: \begin{itemize} \item A multicast enabled environment (see section 2 to learn about that); \item The Reliable Multicast Library - the librmcast.a file; \item The Reliable Multicast Header - the rmcast.h file; \item C language develop environment - gcc, make, c libraries etc. \end{itemize} \subsection{Getting and installing the Reliable Multicast Library} To get the Reliable Multicast Library do the following: \begin{enumerate} \item Download the RML source code from our project page at \emph{}\\ \emph{http://www.land.ufrj.br/tools/rmcast} \item Gunzip and untar the package. After that the RelMulticast directory will be created. \item Change to RelMulticast directory. \item Type make and see if the \textbf{librmcast.a} is compiled without errors. This may be flawless for most users. \end{enumerate} To compile an application with librmcast.a you should use the following options with gcc: \begin{quote} -I -L -lrmcast \end{quote} For instance, we have an application called rmchat in the examples/rmchat directory, to compile that application we should issue the command: \begin{quote} gcc rmchat.c -I../.. -L../.. -lpthread -lm -lrmcast -o rmchat \end{quote} Inside the RelMulticast directory you will find some useful files such as README, INSTALL etc. Those files contain the most updated instructions to compile the RML, please take a look at them. \subsection{The Reliable Multicast Library configuration} There are two ways for an application to customize the Reliable Multicast Library options: \begin{enumerate} \item Calling the \textbf{RM\_setOption(int OPTION\_ID, void {*}OPTION\_VALUE)} function, where: \\ \\ OPTION\_ID: indicates what option you want to set. You can found the option list in the rmcast.h header file. \\ OPTION\_VALUE: the value you want to set the option to \\ \\ \textbf{Example:} \\ \texttt{... }~\\ \texttt{/{*} Setting REFRESH\_TIMER {*}/ }~\\ \texttt{int refresh\_timer=10; }~\\ \texttt{}~\\ \texttt{RM\_setOption(REFRESH\_TIMER,(void {*}) refresh\_timer); }~\\ \texttt{... } \item Calling \textbf{RM\_readConfigFile(char {*}filename)}. This function will tell the Reliable Multicast Library to read the user's options from \textbf{filename}. \\ \\ \textbf{Example:} \\ \\ \texttt{...}~\\ \texttt{/{*} Read the config file from /etc/rmcast.config {*}/ }~\\ \texttt{char config\_file{[}50{]}; }~\\ \texttt{}~\\ \texttt{strcpy(config\_file,\char`\"{}/etc/rmcast.config\char`\"{}); }~\\ \texttt{}~\\ \texttt{RM\_readConfigFile(config\_file); }~\\ \texttt{...} \\ \end{enumerate} NOTE: There is a constant, RM\_USE\_CURRENT\_CONFIG, that can replace functions parameters. In those situations, the RM\_USE\_CURRENT\_CONFIG will indicate that the current values (which may have been set either by calling RM\_setOption or RM\_readConfigFile) must be used. For instance, when we call the RM\_joinGroup() function we are supposed to pass as parameters the IP Multicast address and port number. If we have already read those options from rmcast.config file, just replace the parameters with the RM\_USE\_CURRENT\_CONFIG constant.\\ The rmcast.config file contain some options that can be customized by the users. A rmcast.config file example follows (lines beginning with a \"{ }\#\"{ } are comments): \begin{quote} \texttt{\footnotesize \#Reliable Multicast Library configuration file}{\footnotesize \par} \texttt{\footnotesize \#Reliable Multicast Library version }~\\ \texttt{\footnotesize RM\_VERSION=1.0}{\footnotesize \par} \texttt{\footnotesize \#Transmission mode: 0 multicast (default), 1 unicast }~\\ \texttt{\footnotesize TRANSMISSION\_MODE=0}{\footnotesize \par} \texttt{\footnotesize \#Multicast or Unicast IP address to send data (destination IP) }~\\ \texttt{\footnotesize DEST\_IP=225.1.2.3}{\footnotesize \par} \texttt{\footnotesize \#Multicast or Unicast port to send data (destination port) }~\\ \texttt{\footnotesize DEST\_PORT=5000}{\footnotesize \par} \texttt{\footnotesize \#Time to live for the packets setting (1 indicates local network) }~\\ \texttt{\footnotesize TTL=1}{\footnotesize \par} \texttt{\footnotesize \#Inter-packet sleep timer - timer between transmissions of packets }~\\ \texttt{\footnotesize \#( in microseconds) }~\\ \texttt{\footnotesize MICROSLEEP=10}{\footnotesize \par} \texttt{\footnotesize \#Log file path - NULL disable logging (default) }~\\ \texttt{\footnotesize LOG\_FILE=NULL}{\footnotesize \par} \texttt{\footnotesize \#Random Timers Distribution: 0 uniform 1 exponential }~\\ \texttt{\footnotesize TIMER\_DISTRIBUTION=0}{\footnotesize \par} \texttt{\footnotesize \#Lower bound for timer generation (in milliseconds) }~\\ \texttt{\footnotesize TIMER\_LOWER=200}{\footnotesize \par} \texttt{\footnotesize \#Upper bound for timer generation (in milliseconds) }~\\ \texttt{\footnotesize TIMER\_UPPER=1000}{\footnotesize \par} \texttt{\footnotesize \#Max number of naks that can be sent for each packet. 100 (default) }~\\ \texttt{\footnotesize MAX\_NAK=100}{\footnotesize \par} \texttt{\footnotesize \# We will be able to retransmit the last MAX\_MEMBER\_CACHE\_SIZE }~\\ \texttt{\footnotesize \# packets from each member of the multicast group, i.e., we will store the}~\\ \texttt{\footnotesize \# last MAX\_MEMBER\_CACHE\_SIZE PACKETS from each member}~\\ \texttt{\footnotesize \# of the multicast group in the cache. 4000 (default) }~\\ \texttt{\footnotesize \# }~\\ \texttt{\footnotesize \# WARNING: if you set MAX\_MEMBER\_CACHE\_SIZE to low values }~\\ \texttt{\footnotesize \# the protocol may fail!! }~\\ \texttt{\footnotesize \# }~\\ \texttt{\footnotesize MAX\_MEMBER\_CACHE\_SIZE=4000 }{\footnotesize \par} \texttt{\footnotesize \#Enable support for new users 1 enabled (default), 0 disabled }~\\ \texttt{\footnotesize NEW\_USER\_SUPPORT=0}{\footnotesize \par} \texttt{\footnotesize \#Show transmission statistics: 0 disabled (default) 1 enabled }~\\ \texttt{\footnotesize STATISTICS=0}{\footnotesize \par} \texttt{\footnotesize \#Time between sending of refresh messages (seconds) }~\\ \texttt{\footnotesize REFRESH\_TIMER=10}{\footnotesize \par} \texttt{\footnotesize \#Loss simulation: 0 disabled (default) any float number > 0 enabled}{\footnotesize \par} \texttt{\footnotesize \# A note about loss simulation: }~\\ \texttt{\footnotesize \# When loss simulation is enabled (LOSS\_PROB > 0) we always loose }~\\ \texttt{\footnotesize \# the first 10 received packets, and the first received data packet - }~\\ \texttt{\footnotesize \# that is, the first burst of received packets. }~\\ \texttt{\footnotesize \# After that, packets are lost according to LOSS\_PROB. }~\\ \texttt{\footnotesize \# Example: LOSS\_PROB=30 }~\\ \texttt{\footnotesize \# The first 10 received packets will be lost. }~\\ \texttt{\footnotesize \# Then, 30\% of the packets will be lost }~\\ \texttt{\footnotesize LOSS\_PROB=0}{\footnotesize \par} \texttt{\footnotesize \# Time to wait, in microseconds, before leaving the multicast group. }~\\ \texttt{\footnotesize LEAVE\_GROUP\_WAIT\_TIME = 5000000}{\footnotesize \par} \texttt{\footnotesize \# Size of the buffer of the receiver host }~\\ \texttt{\footnotesize \# (maximum size of a message that may be processed by }~\\ \texttt{\footnotesize \# the receiver host).}~\\ \texttt{\footnotesize RCV\_BUFFER\_SIZE = 10000}{\footnotesize \par} \end{quote} To retrieve the current value of an option from the RML you must call the \textbf{RM\_getOption(int OPTION,void {*}OPTION\_VALUE)} function\textbf{.} \subsection{The Reliable Multicast Chat (rmchat) application} This is a simple chat application and was written just for testing the RML. The fully commented source code can be found in the examples/rmchat directory. You can compile the program by typing \texttt{\textcolor{black}{make}} in that directory. \subsubsection{The program} Every user that initiates the program is prompted for a username - this username will be the users identity in the group. After that they will receive all the messages from every user already connected to the chat group (if any). You can also type messages in the prompt and send them to the group by pressing the return key. Note that there is no need for a chat server because we are using multicast. Users must know the IP address and port to join the chat group. You can set this address and port through the rmcast.config file as we have seen in the previous section. We have implemented only two simple commands in the rmchat: \begin{enumerate} \item \textbf{send -} by typing \texttt{\textcolor{black}{send}} on the prompt you will be asked for the number of packets to send to the group. This command was implemented to perform simple tests with the application. \item \textbf{exit} - this command is used to terminate the application. \end{enumerate} \subsubsection{Source code comments} This section is supposed to be read along with the source code of rmchat, available at examples/rmchat/rmchat.c. The very first thing we have to do when we are writing an application is to include the \textbf{rmcast.h} header file. Next we define BUFFSIZE - the maximum message size. We also declare an integer global variable to identify the socket we will use to send and receive data. The following step is to read the configuration file, calling the \textbf{RM\_readConfigFile} function. Then, we have to initialize the RML calling the \textbf{RM\_initialize} function. After that we join the multicast group calling the \textbf{RM\_joinGroup} function. At this point we are using the RM\_USE\_CURRENT\_CONFIG as discussed in section 4.3. The \textbf{RM\_joinGroup} function returns the socket identifier that we will need to send and receive data from the network. Interactive network applications are supposed to simultaneously receive and send data through the network. To implement that feature we usually create separated threads to deal with those tasks. In the rmchat we have created, calling the pthread\_create function, the \emph{}\textbf{Receive thread} to receive packets from the network, while the main thread will get the user messages and will send them to the multicast group. You can easily see in the Receive thread code that there is a loop where we just call \textbf{RM\_recv} function to retrieve data from the network. The data received is then showed on the screen. In the main program we are reading the messages typed by the user and checking whether they are a command or a simple message. If it is a simple message, we just call the \textbf{RM\_sendto} function to send the data to the multicast group. Otherwise, if the \textbf{exit} command is issued, we break the loop and prepare to terminate the application. We use the \textbf{RM\_getOption} to retrieve the current IP address and port from the RML just to report it to the user. In addition we cancel the Receive thread using the pthread\_cancel() function. Finally we call the \textbf{RM\_leaveGroup} function to finish the RML and our program. This function is \noun{very important} because it cleans up the system resources that we were using such as the message queue. See section 7.3 for further information on message queues. Again, we recommend that you take a look at the source code to better understand the application. \subsection{RML functions quick reference} In this section will go through the user functions available in the Reliable Multicast Library. \begin{itemize} \item \textbf{RM\_readConfigFile(char {*}filename)} - read the configuration file identified by \emph{filename}. See section 4.3 for the config file format and options. \item \textbf{RM\_setOption(int opt, void {*}optvalue)} - set the option identified by \emph{opt} with the value in \emph{optvalue}. You can use setOption to set the RML instead of reading the config file. \item \textbf{RM\_getOption(int opt, void {*}optvalue)} - returns the current value \emph{optvalue} of the option identified by \emph{opt}. \item \textbf{RM\_initialize(void *callbackterm( void ))} - initializes the RML structures and defines the callback function that will be used when finishing the application \item \textbf{RM\_getCurStatus(char {*}group, int port, CurStatus {*}c)} - get the current status from a member of the multicast group. \item \textbf{RM\_sendCurStatus(int connfd, char {*}buff, int buffsize)} - send the current status to a new member of the multicast group. \item \textbf{RM\_joinGroup(char {*}group, int port)} - join the multicast group identified by the IP address in \emph{group} and the port in \emph{port}. Returns the socket identifier that will be used in the RM\_sendto and RM\_recv functions. \item \textbf{RM\_sendto(int socket, void {*}buffer, int buffsize)} - sends up to \emph{buffsize} bytes of data from \emph{buffer} using the socket identifier \emph{socket}. Returns 1 on success and 0 if an error occurs. \item \textbf{RM\_recv(int socket, void {*}buffer, int buffsize)} - receives up to \emph{buffsize} bytes of data, and stores them into \emph{buffer} using the socket identifier \emph{socket}. Returns the number of bytes received on success and -1 when an error occurs. \item \textbf{RM\_leaveGroup(int sock,char {*} group)} - sends a message indicating that we are leaving the multicast group identified by \emph{group}, cleans all the system resources being used and closes the socket identified by \emph{socket}. You must call this function before terminating the application. Returns 1 on success and 0 on failure. \end{itemize} \section{A more advanced application: the Tangram II Whiteboard} \subsection{About Tangram II Whiteboard (TGWB)} Quoting from the tgif manual, {}``tgif (Tangram2 Graphic Interface Facility) is a Xlib based interactive 2-D drawing facility under X11''. The tgif tool is a powerful vector based drawing tool. The user draws objects, i.e., rectangles, lines, circles and splines, over a drawing area. Objects may be transformed - for instance, rotated, translated and flipped. New objects may be constructed by grouping other objects. In the next section, we will describe a whiteboard tool which was developed over tgif - TGWB (Tangram II Whiteboard). The tgwb allows simultaneous modifications in drawings by users in a group. It is a versatile multicast distributed tool. \subsection{Getting and installing TGWB} To get the TGWB, follow the steps below: \begin{enumerate} \item get tgif at http://bourbon.usc.edu:8001/tgif/ \item read the README.tgwb file and follow the instructions described there. \end{enumerate} \subsection{What features make TGWB different} There are two main points that make the TGWB application different from the previously described chat. At a given time, a user may want to send to the group huge amounts of data (for example, a screenshot). This message must be segmented into smaller packets before being sent to the group (note that, for simplicity, in the chat application we were assuming that the user would not send very large amounts of data in the messages). One of the reasons segmentation is needed is the fact that there is a maximum segment size which network routers support. To see other reason for doing segmentation, the interested read should consult chapter 1 of \cite{key-3}. Figure \ref{tgwb layers} presents the TGWB layers. A second feature that makes the TWGB tool different from the chat is the fact that we need to assure global consistency among the users of the TGWB tool. Imagine that two users change the color of a rectangle at the same time: user A changes the color of the rectangle to red, and B to blue. What must user C see? A blue or a red rectangle? What about A and B? This problem, and others, are solved using a {}``total ordering mechanism'', which is based in the use of the undo/redo commands (rollback-recovery strategy). Consult \cite{key-24} for a complete explanation about this subject. \subsection{The life cycle of a packet in the TGWB} The packets life cycle begins when a user draws an object over the tgif drawing area. As mentioned above, an object may be a circle, a rectangle, a text box or any other drawing primitive described on the tgif manual. Please, see tgif man pages, tgif FAQ \cite{key-2} and tgif tutorial for more information about tgif. Now, the object must be delivered to the members of the multicast group. This is done via the RML functions. However, before being delivered the object is first divided into segments - see the \emph{Segment()} call in wb.c. The segment size is chosen in a way that the more common objects (rectangles, circles and text boxes) fit in one segment and, at the same time, the maximum transfer unit (MTU) is greater then the segment size. All the RML functions available for the applications have the RM\_ prefix. So, in order to send a tgif object to the network, \emph{RM\_sendto()} is called, passing as parameters the multicast destination group and the object data. You may see the definition of the function \emph{SendWBData()} in wb.c. The \emph{RM\_sendto()} function (and all the other functions that may be called by an application) is defined in the rmcast.c file. \emph{RM\_sendto()} calls \emph{rmcastSendPackets()}, which is defined in rminternals.c, and that in turns makes a \textit{\textcolor{black}{sendto(2)}} system call (the number two between parenthesis refers to the section two of man of sendto - to see the man info, type \texttt{man 2 sendto} at the Linux prompt. Please, note that this number may vary according to the operating system). In general, the functions defined in rmcast.c call functions defined in rminternals.c. Then, functions in rminternals.c make system calls. Concerning the syntax, note that the functions in rmcast.c have the prefix {}``RM\_'' and the functions in rminternals.c have the prefix {}``rmcast''. At this point we have segmented the object data into packets, appended all needed headers and the packet was sent. That's what happens at the sender side. Now, let's see the receiver side. All the members of the multicast group, communicating among themselves using the TGWB, receive messages from all the other members\textit{\textcolor{black}{.}} \textit{\textcolor{black}{\emph{At the application level, the}}} \textit{\textcolor{black}{RM\_recv()}} \textit{\textcolor{black}{\emph{function is used to get messages in order, without gaps, from the other members of the group}}}\textit{\textcolor{black}{.}} \textcolor{black}{The} \emph{RM\_recv()} function makes a \textit{\textcolor{black}{msgrcv(2)}} system call to get messages from a message queue. Note that this is an exception to the general explanation given two paragraphs above. Read the following section in order to get more information about how the message queue works, and why it is used here. When a packet arrives from the network, the \textit{\textcolor{black}{recvfrom(2)}} system call is responsible for receiving it. We make a \textit{\textcolor{black}{recvfrom(2)}} system call in the \emph{rmcastReceivePackets()} function, defined in rminternals.c. The received message is then processed, inserted in the cache and, if it is in fact the expected message, we put it in the message queue. The message queue was the interprocess communication mechanism that we have chosen in order to store the in-order without-gaps messages that will be read by the application. Figure \ref{tgwb architecture} show the Tangram II Whiteboard architecture. % \begin{figure}[hbpt] \begin{center}\includegraphics{layers.eps}\end{center} \caption{\label{tgwb layers}TGWB Layers} \end{figure} % \begin{figure}[hbpt] \begin{center}\includegraphics[% width=1.0\columnwidth, height=1.0\textwidth, angle=90]{wbarch.eps}\end{center} \caption{\label{tgwb architecture}TGWB Architecture} \end{figure} \section{More about the Tangram II Whiteboard} \subsection{The TGWB threads} UNIX/Linux offers a lot of interprocess communication mechanisms. If you run tgwb under Linux, and type \texttt{ps -aux | grep tgwb}, you will probably see something like: \begin{quotation} \texttt{{[}anonymous@salinas anonymous{]}\$ ps -axu | grep tgwb } \texttt{anonymous 2820 1.7 0.8 12780 1992 pts/4 S 16:25 tgwb } \texttt{anonymous 2821 0.1 0.8 12780 1992 pts/4 S 16:25 tgwb } \texttt{anonymous 2822 0.0 0.8 12780 1992 pts/4 S 16:25 tgwb } \texttt{anonymous 2823 0.0 0.8 12780 1992 pts/4 S 16:25 tgwb } \texttt{anonymous 2824 0.0 0.8 12780 1992 pts/4 S 16:25 tgwb } \texttt{anonymous 2825 0.0 0.8 12780 1992 pts/4 S 16:25 tgwb } \texttt{anonymous 2827 1.0 0.2 1700 592 pts/4 S 16:25 grep tgwb} \end{quotation} We see here that tgwb generates six processes. That's because under Linux the pthreads library generates one process per thread (please, see Appendix), plus one extra thread, which corresponds to the {}``thread manager''. We will briefly describe the first five threads generated by TGWB - the last one, the {}``thread manager'' is created internally by Linux Threads to handle thread creation and termination \cite{key-4}. thread 1. responsible for receiving ordered, without gaps messages - that is, reliable messages; thread 2. responsible for receiving possible out of order, with gaps messages - that is, messages from the network; thread 3. responsible for (a) processing the local user actions, such as drawing objects and writing texts, (b) processing remote user commands which arrive from the message queue and (c) sending local commands to the other users. That is the {}``main'' thread; thread 4. responsible for signal handling. We will call this thread the {}``signal handler'' thread; thread 5. responsible for sending the current state, via TCP, to the new users who eventually would like to join the group. We will call this thread as the {}``current state server'' thread. These threads, and the relations between them, are represented in figure \ref{tgwb architecture}. \subsection*{Thread 1 - Reliable messages receiver thread} This thread, implemented in the tgwb, stays in a loop waiting for reliable messages. When a reliable message is received, it is inserted in a buffer, and also an 'a' is written into a pipe. This 'a' will signal the main thread that there is data available from the network. \subsection*{Thread 2 - Raw messages receiver thread} Implemented under the RML, this thread is responsible for receiving raw data from the network. Depending on the type of the message (for instance, data, negative acknowledgment and refresh messages) we take the appropriate actions. Please, see section 4.3 for more details about this. \subsection*{Thread 3 - Main thread} This thread is implemented in the TGWB mainloop.c file. This thread remains sleeping until it is wakened up by one of the following events: (1) an X event is generated by the local user; (2) a {}``reliable message'' arrives from the network. Lets start by (1). When an user drags the mouse in order to draw an object this event is inserted in the X event-list. This list is managed by the X-server using a FIFO policy. As soon as the mentioned user command gets on the top of this list, the command is executed and sent to the other members of the group. Now, let's analyze (2). A pipe is used to perform the communication between the main thread and the {}``reliable messages receiver thread''. When a {}``reliable message'' arrives from the network an 'a' character is written in the pipe by the {}``reliable messages receiver thread''. The main thread then reads this 'a' from the pipe, and the command received from the network is locally processed. At this point it's interesting to talk a little about the history of tgwb. In former versions of TGWB, we made a busy wait loop in order to wait for events from both the local user and the network, that is, a busy wait for (1) and (2). That is not efficient, and when someone call the command \texttt{top}, from the shell prompt, TGWB usually appears as the first element of the list, consuming near 100\% of the CPU cycles. To solve this problem, we introduced the use of pipes \cite{key-22} in the mainloop of TGWB. Please, refer to figure \ref{tgwb mainloop} for a scheme of the TGWB mainloop. The mainloop of TGWB waits for (1) or (2) calling: \begin{lyxcode} status~=~select(nfds,~\&fdset,~NULL,~NULL,~\&timeout); \end{lyxcode} When we get (1), \emph{XNextEvent(mainDisplay, pXEvent)} is called, and the X event generated by the local user is processed. When we get (2), \emph{SendCommandToSelf(CMDID\_DATA\_IN\_MBUFF, 0)} is called, and the {}``reliable message'' which arrived from the network is processed. Besides (1) and (2), the main thread may also get a request for packing the tgwb current state. When we receive 'c' via the pipe, which signals this request, we call \emph{HandleNewUserRequest()} and the request is attended. Our approach to solve this problem is discussed at session 7.2. % \begin{figure}[hbpt] \begin{flushleft}\includegraphics{mainloop.eps}\end{flushleft} \caption{\label{tgwb mainloop}TGWB mainloop routine} \end{figure} \subsection*{Thread 4 - Signal handler thread} We will give a brief explanation about the difference between synchronous and asynchronous signals. As signal handling is a very broad topic, please refer to \cite{key-18}\cite{key-23} for more details. Signals may be generated synchronously or asynchronously. A synchronous (sync) signal pertains to a specific action in the program, and is delivered (unless blocked) during that action. Errors generate signals synchronously, and so do explicit requests by a process to generate a signal for that same process. Asynchronous (async) signals are generated by events outside the control of the process that receives them. These signals arrive at unpredictable times during execution. External events generate signals asynchronously, and so do explicit requests that apply to some other process. A given type of signal is either typically synchronous or typically asynchronous. For example, signals for errors are typically synchronous because errors generate signals synchronously. But any type of signal can be generated synchronously or asynchronously with an explicit request. In the Reliable Multicast Library, a dedicated thread was created to wait for all the generated signals. Such a thread just loops on a sigwait subroutine call and handles the signals. That is a typical schema for programs that handle signals with threads \cite{key-6} and an example can be found at \cite{key-17}. That kind of procedure handles the signals synchronously because this is the safest programming style. \subsection*{Thread 5 - Current State Server Thread} This thread is responsible for the so called {}``support for new members'' in the RML. In other words, this thread is responsible for provisioning to new members the capacity for joining a TGWB session at any time. Suppose that a new member A wants to join the multicast group. This member will try to get the {}``current state'' of the group, and just after that he will enter. In more details, we follow the steps below: (1) First, member A send a packet of type JOIN\_REQUEST to the group. (2) Then, member A waits for an JOIN\_ACCEPT packet from any member of the group. If member A doesn't receive any message, and gets a timeout, he will start to send/receive packets to/from the multicast group as he was the first member in that TGWB session. (3) When a JOIN\_ACCEPT packet is received from a member B, member A will try to connect to B via TCP, and retrieve his {}``current state''. After receiving the current state, A will make a call to RM\_joinGroup() and at this moment member A becomes an actual member of the group. It implies that besides being able to talk with the other members of the group, member A is promoted to a {}``current state server''. A {}``current state server'' is a server that waits for connections in a specific port, and when a new client connects to this port, the {}``current state server'' provides the {}``current state'' to this client. \subsection{Solving the busy wait problem} Processes (and threads), during its execution time, may be in several operating states. Among the states, we will focus on the two extreme ones: busy wait, when the process occupies almost 100\% of the CPU, or sleeping, when it practically does not use system resources. See chapter 3 of \cite{key-23} for more details about process (and threads) states. In former versions of tgwb, the mainloop of the program worked using busy wait. In tgwb version 4.1.40, if we ran tgwb and typed {}``top'' at the Linux shell prompt, we would get: \begin{lyxcode} PID~~~\%CPU~\%MEM~TIME~COMMAND~ 27490~81.3~2.5~~0:26~tgwb \end{lyxcode} Note that tgwb was occupying 81.3\% of the CPU time. And this occurred even when we were not drawing or writing anything on the canvas - the simple fact of opening the tgwb was responsible for that. We started trying to solve the problem using the \textit{\textcolor{black}{select(2)}} system call. Using \textit{\textcolor{black}{select(2)}} we would be able to {}``sleep'' waiting for data to arrive either from the network or from commands sent by the local user. Instead of having something like: \begin{lyxcode} while(1) \{ ~~if~(~data~received~from~the~network~) ~~~~~do~this; ~~else~if~(~there~is~an~X~event~to~be~processed~) ~~~~~do~that; ~~else ~~~~~do~nothing; \} \end{lyxcode} We would like to get: \begin{lyxcode} while(1) \{ ~~select~(...);~/{*}~sleep~waiting~for~data~from~the~network ~~~~~~~~~~~~~~~~~~~or~for~an~X~event~{*}/ ~~if~(~data~received~from~the~network~) ~~~~~do~this; ~~else~if~(~there~is~an~X~event~to~be~processed~) ~~~~~do~that; \} \end{lyxcode} First we tried to do this by making the {}``reliable messages receiver thread'' write a character into a conventional file when a message arrived from the networking, and the select would watch the file to see if characters become available for reading. The select would return if there were some character on the file or there were an pending X event. The problem is that select() doesn't work with conventional files. After finding out this problem, instead of using conventional files we started working with a pipe. An important reference that we used was \cite{key-34}. Follows below a piece of a message from William Cheng, who is the tgif's main developer :\\ \texttt{Basically, you create a pipe to send notification characters to yourself! So, when tgwb starts, a pipe is created and its 2 endpoints (file descriptors) are stored in an array. In GetAnXEvent(), you need to do a select() call. This call will wait for 3 conditions: (1) an X events has arrived; (2) the pipe contains some data; and (3) a timeout has occurred. The timeout is there just case something goes wrong. I would set a very large timeout, for example, 15 seconds.} \texttt{In ReceivePacket(), instead of calling SendCommandToSelf(), }~\\ \texttt{it should write 1 byte to the pipe! That's it!} \texttt{In GetAnXEvent(), if select() returns with the pipe having some data, you should read 1 bytes and then calls SendCommandToSelf(). } \texttt{(Well, calling HandleDataInMBuff() directly would be fine too.)}~\\ Note that we call the \emph{SendCommadToSelf()} function when we receive a command from the network. This function, which is also called in menu.c, is used to put X events in the X internal queue. Using this functionality, when we receive a data from the network it is processed and then the resulting action is put in the X queue, and then treated as any other X event. Now, if we run tgwb and type {}``top'' at the Linux shell prompt, we get: \begin{lyxcode} PID~\%CPU~\%MEM~TIME~COMMAND~ 26919~0.0~0.6~0:00~bash~ 27049~0.0~0.7~0:00~tgwb~ 27050~0.0~0.7~0:00~tgwb~ 27051~0.0~0.7~0:00~tgwb~ 27052~0.0~0.7~0:00~tgwb~ 27053~0.0~0.7~0:00~tgwb \end{lyxcode} Note that the \%CPU (percentage of total CPU time) of tgwb now is almost 0. \section{Appendix - Interprocess Communication Resources} In order to implement the reliable multicast library we have used a lot of interprocess communication resources. The operating system and interprocess communication resources used were: \begin{enumerate} \item threads; \item mutexes; \item message queues; \item pipes; \item sockets (TCP and UDP); \item signals. \end{enumerate} We will give here a brief introduction to these topics. The interested reader should consult \cite{key-25,key-26}. \subsection{Threads} When we have a lot of tasks to do, we try to do different tasks at the same time. This tasks are the human analogy to what threads are for computer programs. In our Reliable Multicast Library (RML) we have used mainly the following pthread system calls: \begin{itemize} \item pthread\_create \item pthread\_join \item pthread\_exit \end{itemize} To get more info about pthreads, please refer to the man pages of this functions, and \cite{key-4,key-27,key-28} \subsection{Mutexes} In order to synchronize threads we have to use mutexes. We can't, for example, change the value of a variable at two distinct points at the same time because this may generate an inconsistency. In the RML, we used the system calls: \begin{itemize} \item pthread\_mutex\_lock \item pthread\_mutex\_unlock \end{itemize} in order to protect some critical points of the program - mainly the ones that work with the cache and the event list, which are the global structures accessed by more than one thread. \subsection{Message Queues} The message queues are a first in first out (FIFO) operating system mechanism that are used to pass data between different thread/processes. They are an important IPC mechanism. Among the message queue functions used, we may focus: \begin{itemize} \item msgget - int msgget ( key\_t key, int msgflg ) \item msgctl - int msgctl ( int msqid, int cmd, struct msqid\_ds {*}buf ) \item msgsnd - int msgsnd ( int msqid, struct msgbuf {*}msgp, size\_t msgsz, int msgflg ) \item msgrcv - ssize\_t msgrcv ( int msqid, struct msgbuf {*}msgp, size\_t msgsz, long msgtyp, int msgflg ) \end{itemize} The first important concept to understand is the concept of a {}``key''. Keys are numbers used to identify an IPC resource in UNIX, in an analogy to the fact that file names are used to identify files. It's the key that allows that an IPC resource be shared between different threads and processes, similarly to the fact that the file names allow that a file be referenced by any program running in the operating system. The function \emph{msgget} receives as first parameter a key, and return an identifier for the object which is analogous to the {}``file descriptor'' in the case of files. The last parameter, \emph{msgflg}, must be set to IPC\_CREAT when we want to create a new object. It's necessary to make a logical OR of IPC\_CREAT with the values of table \ref{message queue permissions} depending on the permissions wanted for the created object. % \begin{table}[hbpt] \begin{center}\begin{tabular}{c} \begin{tabular}{|c|c|} \hline octal value& meaning\tabularnewline \hline \hline 0400& read permited for the owner of the object\tabularnewline \hline 0200& write permited for the owner of the object\tabularnewline \hline 0040& read permited for the group\tabularnewline \hline 0020& write permited for the group\tabularnewline \hline 0004& read permited for all\tabularnewline \hline 0002& write permited for all\tabularnewline \hline \end{tabular}\tabularnewline \end{tabular}\end{center} \caption{\label{message queue permissions}Message queue permissions} \end{table} The functions \emph{msgsnd} and \emph{msgrcv} are used to send/receive messages to/from the queue. The \emph{msgctl} function is used to set control properties of the queue. Please, refer to the man pages of this functions for more details about them. \subsection{Pipes} The pipes, as the message queues, are used to transmit data between processes/threads. The difference between pipes and message queues is that pipes work with characters (we write/read characters to/from the pipe) while message queues work with messages of variable sizes. The main pipe system call used was: \begin{itemize} \item pipe \end{itemize} \subsection{Sockets} Sockets are IPC mechanisms that may be used to send/receive messages between two hosts. Please, consult \cite{key-29} in order to get more information about sockets. \subsection{Signals} Please, see the comments about the {}``signal handler thread'', in section 7.1. \begin{thebibliography}{10} \bibitem{key-30}\textcolor{black}{Tangram II web site: http://www.land.ufrj.br} \bibitem{key-33}\textcolor{black}{Multicast HOWTO available at http://www.linuxdoc.org/HOWTO/Multicast-HOWTO.html } \bibitem{key-2}Cheng, W.C. Tangram Graphical Interface Facility \\ \\ TGWB has been integrated with TGIF since version 4.1.29 released on April 18,2000. \bibitem{key-3}Kurose, J.F. and Ross, K.W., Computer Networking - A Top-Down Approach Featuring the Internet. \bibitem{key-4}Leroy, X. The Linux Threads library - an implementation of the Posix 1003.1c thread package for Linux. \\ http://pauillac.inria.fr/\textasciitilde{}xleroy/linuxthreads/ \bibitem{key-6}http://www.unet.univie.ac.at/aix/aixprggd/genprogc/signal\_mgmt.htm \bibitem{key-17}http://support.entegrity.com/private/doclib/docs/osfhtm/develop/apgstyle/Apgsty83.htm \bibitem{key-18}http://www.gnu.org/manual/glibc-2.2.3/html\_node/libc\_458.html \bibitem{key-22}http://www-h.eng.cam.ac.uk/help/tpl/graphics/X/signals.html \bibitem{key-23}Stallings, William. Operating Systems, Internals and Design Principles. Prentice Hall. \bibitem{key-24}C. E. F. Brito, E. Souza e Silva and W. Cheng. Reliable Multicast Communication and the Implementation of TGWB, a Shared Vector-based Whiteboard Tool. Technical Report. \bibitem{key-25}Haviland, Keith. Unix System Programming. Addison Wesley Publishing Company. \bibitem{key-26}Stevens, Richard. Advanced Programming in the UNIX Environment. Addison Wesley Professional Computing Series. \bibitem{key-27}Nichols, Bradford et al. Pthreads Programming. O'Reilly. \bibitem{key-28}Kleiman, Steve et al. Programming with Threads. \bibitem{key-29}Stevens, Richard. UNIX Network Programming. Prentice Hall. \bibitem{key-34}http://www-h.eng.cam.ac.uk/help/tpl/graphics/X/signals.html \bibitem{key-35}RNP: http://www.rnp.br/multicast/multicast-beneficios.html \bibitem{key-36}A.Erramilli and R.P Sing. {}``A Reliable and Eficient Multicast Protocol for Broadband Broadcast Networks Proccedings of ACM SIGCOMM 87, pp. 343-352, August 1987. \bibitem{key-37}Peterson, Larry et al. {}``Computer Networks: A Systems Approach''. \bibitem{key-38}http://www.gnuplot.info \end{thebibliography} \begin{lyxcode} \end{lyxcode} \end{document} tgif-QPL-4.2.5/rmcast/doc/manual/screencapt.obj0000644000076400007640000160512211077130422021135 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,0,0,0,16,1,8,1,1,0,0,1,0,1,0,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,0,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/screencapt.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(41,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 53052, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 42649, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#6b6d6b", 27046, 28086, 27046, 27392, 27904, 27392, 1, "#dedbde", 57213, 56172, 57213, 56832, 56064, 56832, 1, "#dedfde", 57213, 57213, 57213, 56832, 57088, 56832, 1, "#e6e3e6", 59293, 58253, 59293, 58880, 58112, 58880, 1, "#b5b6b5", 46810, 46810, 46810, 46336, 46592, 46336, 1, "#adaaad", 44730, 43690, 44730, 44288, 43520, 44288, 1, "#c5c6c5", 50971, 50971, 50971, 50432, 50688, 50432, 1, "#7baae6", 31207, 43690, 59293, 31488, 43520, 58880, 1, "#29394a", 10402, 14563, 18724, 10496, 14592, 18944, 1, "#d6d7d6", 55132, 55132, 55132, 54784, 55040, 54784, 1, "#8c8e8c", 36408, 36408, 36408, 35840, 36352, 35840, 1, "#526d94", 20804, 28086, 38488, 20992, 27904, 37888, 1, "#737173", 29126, 29126, 29126, 29440, 28928, 29440, 1, "#efebef", 61374, 60333, 61374, 61184, 60160, 61184, 1, "#e6e7e6", 59293, 59293, 59293, 58880, 59136, 58880, 1, "#3a4963", 14563, 18724, 24965, 14848, 18688, 25344, 1, "#d6d2d6", 55132, 54092, 55132, 54784, 53760, 54784, 1, "#cecece", 53052, 53052, 53052, 52736, 52736, 52736, 1, "#3a393a", 14563, 14563, 14563, 14848, 14592, 14848, 1, "#cecace", 53052, 52011, 53052, 52736, 51712, 52736, 1, "#526994", 20804, 27046, 38488, 20992, 26880, 37888, 1, "#c5c2c5", 50971, 49931, 50971, 50432, 49664, 50432, 1, "#bdbebd", 48891, 48891, 48891, 48384, 48640, 48384, 1, "#4a6994", 18724, 27046, 38488, 18944, 26880, 37888, 1, "#bdbabd", 48891, 47850, 48891, 48384, 47616, 48384, 1, "#4a698c", 18724, 27046, 36408, 18944, 26880, 35840, 1, "#4a658c", 18724, 26005, 36408, 18944, 25856, 35840, 1, "#7b7d7b", 31207, 32247, 31207, 31488, 32000, 31488, 1, "#425d7b", 16643, 23925, 31207, 16896, 23808, 31488, 1 ]). script_frac("0.6"). fg_bg_colors('white','white'). page(1,"",1,''). xpm('black','',16,32,668,381,0,31,2,0,0,0,652,349,0,0,0,0,0,0,[ "``", "white", 10000, 10000, 10000, "a1", "#000000", 0, 0, 0, "a3", "#6b6d6b", 4126, 4285, 4126, "a4", "#dedbde", 8730, 8571, 8730, "a5", "#dedfde", 8730, 8730, 8730, "a6", "#e6e3e6", 9047, 8888, 9047, "a7", "#b5b6b5", 7142, 7142, 7142, "a8", "#adaaad", 6825, 6666, 6825, "a9", "#c5c6c5", 7777, 7777, 7777, "b0", "#7baae6", 4761, 6666, 9047, "b1", "#29394a", 1587, 2222, 2857, "b2", "#d6d7d6", 8412, 8412, 8412, "b3", "#8c8e8c", 5555, 5555, 5555, "b4", "#526d94", 3174, 4285, 5872, "b5", "#737173", 4444, 4444, 4444, "b6", "#efebef", 9365, 9206, 9365, "b7", "#e6e7e6", 9047, 9047, 9047, "b8", "#3a4963", 2222, 2857, 3809, "b9", "#d6d2d6", 8412, 8253, 8412, "c0", "#cecece", 8095, 8095, 8095, "c1", "#3a393a", 2222, 2222, 2222, "c2", "#cecace", 8095, 7936, 8095, "c3", "#526994", 3174, 4126, 5872, "c4", "#c5c2c5", 7777, 7618, 7777, "c5", "#bdbebd", 7460, 7460, 7460, "c6", "#4a6994", 2857, 4126, 5872, "c7", "#bdbabd", 7460, 7301, 7460, "c8", "#4a698c", 2857, 4126, 5555, "c9", "#4a658c", 2857, 3968, 5555, "d0", "#7b7d7b", 4761, 4920, 4761, "d1", "#425d7b", 2539, 3650, 4761],[ "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a3``````````````````````````````````````````````````````````````````````````````````````````````````````a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a3a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````a4a4````````````````a6``````````````a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a3a5a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7``a5a5a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````a4a4``````````````a8a9a6````````````a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a4a3a5a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a5a5a3``````````````````````````````````````````````b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b0b1``````````````````````````````````````````````````````````````````````````````````````````````````````a3````````````", "````````b2b2````````````a8a8b3a9a6``````````b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2a3a5a7a3``````````````````````a7a3``a7a3``````````````````````a7a3``a7a3``````````````````````a7a3``a5a5a3``````````````````````````````````````````````b0b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b1a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a3````````````", "````````b2b2``````````a8``b5a6``a9a6````````b2b2b2b2b2b2a1a1b2b2b2b2b2a1b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2a3a5a7a3``b6b6b6b6b6b6b6b6b6b6a7a3``a7a3``b6b6b6b6b6b6b6b6b6b6a7a3``a7a3``b6b6b6b6b6b6b6b6b6b6a7a3``a5a5a3``````````````````````````````````````````````b0b4b4````````````````a6``````````````b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b1a5a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7``a5a5a3````````````", "````````b2b2````````b5a8a8a8b5a8a8b3a6``````b2b2b2b2b2b2a1``a1b2b2b2a1a1b2b2b2b2a3a3a3a3a3a3a3a3b2b2b2b2b2b2b2a3a3b2b2b2a3a3a3b2b2b2b2b2b2b2b2b2b2b2b2a3a3a3a3b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2a3a5a7a3``b7b7b7b7b7b7b7b7b7b7a7a3``a7a3``b7a1a1a1a1a1a1a1a1b7a7a3``a7a3``b7b7a1b7b7b7b7a1b7b7a7a3``a5a5a3``````````````````````````````````````````````b0b4b4``````````````a8a9a6````````````b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b1a5a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a5a5a3````````````", "````````b2b2``````a8a8``a8``b3a9````a9a6````b2b2b2b2b2b2a1````a1a1a1``a1b2b2b2b2b2b2b2a3a3b2b2b2b2b2b2b2b2b2b2b2b2b2b2a3a3b2b2b2b2b2b2b2b2b2b2b2b2b2a3a3b2b2a3a3b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2b2a3a5a7a3``a5a5a5a5a5a5a5a5a5a5a7a3``a7a3``a5a1a1a1a1a1a1a1a1a5a7a3``a7a3``a5a1a1a1a5a5a1a1a1a5a7a3``a5a5a3``````````````````````````````````````````````b0b4b4````````````a8a8b3a9a6``````````b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b4b8b4b1a5a7a3``````````````````````a7a3``a7a3``````````````````````a7a3``a7a3``````````````````````a7a3``a5a5a3````````````", "````````b9b9````a8``a8a8a8``a8a6a9````a9a6``````````````a1a7``a7``a7``a1b9b9b9b9b9b9b9a3a3b9b9b9b9a3a3b9a3a3b9a3a3b9a3a3a3a3b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9a3a3b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9a3a5a7a3``a4a4a4a1a1a1a1a4a4a4a7a3``a7a3``a4a1a1a4a4a4a4a1a1a4a7a3``a7a3``a4a4a1a1a1a1a1a1a4a4a7a3``a5a5a3``````````````````````````````````````````````b0b4b4``````````a8``b5a6``a9a6````````b4b4b4b4b4b4a1a1b4b4b4b4b4a1b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b1a5a7a3``b6b6b6b6b6b6b6b6b6b6a7a3``a7a3``b6b6b6b6b6b6b6b6b6b6a7a3``a7a3``b6b6b6b6b6b6b6b6b6b6a7a3``a5a5a3````````````", "````````b9b9``a8````a8``a8``a8``a6a9````a9a6a7a7a7a7a7a7a1a7``a7``a7``a1b9b9b9b9b9b9b9a3a3b9b9b9a3a3b9a3a3a3b9a3a3b9b9a3a3b9b9b9b9b9b9b9b9b9b9a3a3b9b9b9a3a3a3b9b9b9a3a3b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9a3a5a7a3``b2b2b2a1a1a1a1b2b2b2a7a3``a7a3``b2a1a1b2b2b2b2a1a1b2a7a3``a7a3``b2b2b2a1a1a1a1b2b2b2a7a3``a5a5a3``````````````````````````````````````````````b0b4b4````````b5a8a8a8b5a8a8b3a6``````b4b4b4b4b4b4a1``a1b4b4b4a1a1b4b4b4b4````````````````b4b4b4b4b4b4b4````b4b4b4``````b4b4b4b4b4b4b4b4b4b4b4b4````````b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b4b1a5a7a3``b7b7b7b7b7b7b7b7b7b7a7a3``a7a3``b7a1a1a1a1a1a1a1a1b7a7a3``a7a3``b7b7a1b7b7b7b7a1b7b7a7a3``a5a5a3````````````", "````````b9b9a6b5a8a8a8a8a8a8b5a8a8a8a8a8b3a8a1a1a1a1a1a1a1a7a7a1a7a1a7a1b9b9b9b9b9b9b9a3a3b9b9b9a3a3b9b9a3a3b9a3a3b9b9a3a3b9b9b9b9b9b9b9b9a3a3a3b9b9b9b9b9b9a3a3b9b9b9a3a3a3b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9b9a3a5a7a3``c0c0c0a1a1a1a1c0c0c0a7a3``a7a3``c0a1a1c0c0c0c0a1a1c0a7a3``a7a3``c0c0c0a1a1a1a1c0c0c0a7a3``a5a5a3``````````````````````````````````````````````b0b4b4``````a8a8``a8``b3a9````a9a6````b4b4b4b4b4b4a1````a1a1a1``a1b4b4b4b4b4b4b4````b4b4b4b4b4b4b4b4b4b4b4b4b4b4````b4b4b4b4b4b4b4b4b4b4b4b4b4````b4b4````b4b4b4b4b4b4b4b4b4b4b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b0b4b4b1a5a7a3``a5a5a5a5a5a5a5a5a5a5a7a3``a7a3``a5a1a1a1a1a1a1a1a1a5a7a3``a7a3``a5a1a1a1a5a5a1a1a1a5a7a3``a5a5a3````````````", "````````c0c0``a6a9``````````a8a6c1````a6a9``c0c0c0c0c0c0a1a7a1a1a1a1a1a1c0c0c0c0c0c0c0a3a3c0c0c0a3a3c0c0a3a3c0a3a3c0c0a3a3c0c0c0c0c0c0c0a3a3c0c0c0c0c0c0c0c0a3a3c0c0c0c0c0a3a3c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0a3a5a7a3``c2c2c2a1a1a1a1c2c2c2a7a3``a7a3``c2a1a1c2c2c2c2a1a1c2a7a3``a7a3``c2c2a1a1a1a1a1a1c2c2a7a3``a5a5a3``````````````````````````````````````````````b0c3c3````a8``a8a8a8``a8a6a9````a9a6``````````````a1a7``a7``a7``a1c3c3c3c3c3c3c3````c3c3c3c3````c3````c3````c3````````c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3````c3c3c3c3c3c3c3c3c3c3c3c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3c3b8c3b1a5a7a3``a4a4a4a1a1a1a1a4a4a4a7a3``a7a3``a4a1a1a4a4a4a4a1a1a4a7a3``a7a3``a4a4a1a1a1a1a1a1a4a4a7a3``a5a5a3````````````", "````````c0c0````a6a9````b5a6a8b3b3``a6a9````c0c0c0c0c0c0a1a1a1c0c0c0a1a1c0c0c0c0c0c0c0a3a3c0c0c0a3a3c0c0a3a3c0a3a3c0c0a3a3c0c0c0c0c0c0c0c0a3a3a3c0c0c0c0c0c0a3a3c0c0c0a3a3a3c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0a3a5a7a3``c4c4c4c4c4c4c4c4c4c4a7a3``a7a3``c4a1a1a1a1a1a1a1a1c4a7a3``a7a3``c4a1a1a1c4c4a1a1a1c4a7a3``a5a5a3``````````````````````````````````````````````b0c3c3``a8````a8``a8``a8``a6a9````a9a6a7a7a7a7a7a7a1a7``a7``a7``a1c3c3c3c3c3c3c3````c3c3c3````c3``````c3````c3c3````c3c3c3c3c3c3c3c3c3c3````c3c3c3c3````c3c3c3````c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3c3b1a5a7a3``b2b2b2a1a1a1a1b2b2b2a7a3``a7a3``b2a1a1b2b2b2b2a1a1b2a7a3``a7a3``b2b2b2a1a1a1a1b2b2b2a7a3``a5a5a3````````````", "````````c0c0``````a6a9a9b5``a8````a6a9``````c0c0c0c0c0c0a1a1c0c0c0c0c0a1c0c0c0c0c0c0c0a3a3c0c0c0a3a3c0a3a3a3c0a3a3c0c0a3a3c0c0c0c0c0c0c0c0c0c0a3a3c0a3a3c0c0a3a3c0c0a3a3c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0a3a5a7a3``c5c5c5c5c5c5c5c5c5c5a7a3``a7a3``c5a1a1a1a1a1a1a1a1c5a7a3``a7a3``c5c5a1c5c5c5c5a1c5c5a7a3``a5a5a3``````````````````````````````````````````````b0c6c6a6b5a8a8a8a8a8a8b5a8a8a8a8a8b3a8a1a1a1a1a1a1a1a7a7a1a7a1a7a1c6c6c6c6c6c6c6````c6c6c6````c6c6````c6````c6c6````c6c6c6c6c6c6c6c6``````c6c6c6c6````c6c6c6c6c6``````c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6c6b1a5a7a3``c0c0c0a1a1a1a1c0c0c0a7a3``a7a3``c0a1a1c0c0c0c0a1a1c0a7a3``a7a3``c0c0c0a1a1a1a1c0c0c0a7a3``a5a5a3````````````", "````````c0c0````````a6a8a6``a8``a6a9````````c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0a3a3c0c0c0c0a3a3c0a3a3c0a3a3c0c0a3a3c0c0c0c0c0c0c0c0c0c0c0c0c0c0a3a3a3a3c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0c0a3a5a7a3``c7c7c7c7c7c7c7c7c7c7a7a3``a7a3``c7c7c7c7c7c7c7c7c7c7a7a3``a7a3``c7c7c7c7c7c7c7c7c7c7a7a3``a5a5a3``````````````````````````````````````````````b0c8c8``a6a9``````````a8a6c1````a6a9``c8c8c8c8c8c8a1a7a1a1a1a1a1a1c8c8c8c8c8c8c8````c8c8c8````c8c8````c8````c8c8````c8c8c8c8c8c8c8````c8c8c8c8c8````c8c8c8c8c8c8c8c8````c8c8c8c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b0c8c8b1a5a7a3``c2c2c2a1a1a1a1c2c2c2a7a3``a7a3``c2a1a1c2c2c2c2a1a1c2a7a3``a7a3``c2c2a1a1a1a1a1a1c2c2a7a3``a5a5a3````````````", "````````c2c2``````````a6a9``a8a6a9``````````c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2a3a3c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2a3a5a7a3a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a3a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a3a7a7a7a7a7a7a7a7a7a7a7a7a3``a5a5a3``````````````````````````````````````````````b0c8c8````a6a9````b5a6a8b3b3``a6a9````c8c8c8c8c8c8a1a1a1c8c8c8a1a1c8c8c8c8c8c8c8````c8c8c8````c8c8````c8````c8c8````c8c8c8c8c8c8c8c8``````c8c8````c8c8c8c8c8c8c8``````c8c8c8c8c8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8c8b8c8b1a5a7a3``c4c4c4c4c4c4c4c4c4c4a7a3``a7a3``c4a1a1a1a1a1a1a1a1c4a7a3``a7a3``c4a1a1a1c4c4a1a1a1c4a7a3``a5a5a3````````````", "````````c2c2````````````a6a9b3a9````````````c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2a3a3c2c2a3a3c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2a3a5a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a5a5a3``````````````````````````````````````````````b0c8c8``````a6a9a9b5``a8````a6a9``````c8c8c8c8c8c8a1a1c8c8c8c8c8a1c8c8c8c8c8c8c8````c8c8c8````c8``````c8````c8c8````c8c8c8c8c8c8c8c8c8c8````c8````c8c8c8c8c8c8````c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8b1a5a7a3``c5c5c5c5c5c5c5c5c5c5a7a3``a7a3``c5a1a1a1a1a1a1a1a1c5a7a3``a7a3``c5c5a1c5c5c5c5a1c5c5a7a3``a5a5a3````````````", "````````c2c2``````````````a6a8``````````````c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2a3a3a3a3c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2c2a3a5````````````````````````````````````````````````````````````````````````````````````````````````a5a5a3``````````````````````````````````````````````b0c8c8````````a6a8a6``a8``a6a9````````c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8````c8c8c8c8````c8````c8````c8c8````c8c8c8c8c8c8c8c8c8c8c8c8c8````````````c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8c8b1a5a7a3``c7c7c7c7c7c7c7c7c7c7a7a3``a7a3``c7c7c7c7c7c7c7c7c7c7a7a3``a7a3``c7c7c7c7c7c7c7c7c7c7a7a3``a5a5a3````````````", "````````a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a5a3``````````````````````````````````````````````b0c9c9``````````a6a9``a8a6a9``````````c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9````c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b0c9c9b1a5a7a3a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a3a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a3a7a7a7a7a7a7a7a7a7a7a7a7a3``a5a5a3````````````", "````````a7a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````d0a3a5a3``````````````````````````````````````````````b0c9c9````````````a6a9b3a9````````````c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9````c9c9````c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9c9b8c9b1a5a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a7a3a3a3a3a3a3a3a3a3a3a3a3a3a3``a5a5a3````````````", "````````a7a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0c9c9``````````````a6a8``````````````c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9````````c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9c9b1a5````````````````````````````````````````````````````````````````````````````````````````````````a5a5a3````````````", "````````a7a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5a1a1c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1a1c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5a1a1a1c5c5c5c5a1a1a1c5c5c5c5a1a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5a1c5a1c5c5a1c5a1c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5a1a1a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5a1c5c5a1c5a1c5c5c5c5c5c5a1c5c5a1a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5a1a1c5c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5a1c5c5a1c5c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5a1c5c5a1c5a1c5c5c5c5c5c5a1c5c5a1a1c5c5c5c5c5a1a1c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5a1c5a1a1a1c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5a1a1c5c5c5c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5a1c5c5a1c5c5a1c5c5c5c5a1c5c5a1a1c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5a1a1c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1a1c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5a1c5c5c5a1c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5a1a1c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1a1c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5a1a1a1c5c5c5c5a1a1a1c5c5c5c5a1a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5a1c5a1c5c5a1c5a1c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5a1c5c5c5a1c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5a1a1a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5a1c5c5a1c5a1c5c5c5c5c5c5a1c5c5a1a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1a1a1a1c5c5a1c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5a1c5c5a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1a1c5c5c5c5a1a1a1a1c5c5c5a1c5a1c5c5c5c5a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5a1a1c5c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5a1c5c5a1c5c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5a1c5c5a1c5a1c5c5c5c5c5c5a1c5c5a1a1c5c5c5c5c5a1a1c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5a1c5a1a1a1c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5a1a1c5c5c5c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5a1c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5a1c5c5a1c5c5a1c5c5c5c5a1c5c5a1a1c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5a1a1c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1a1c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5a1c5c5c5a1c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5a1c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5a1c5c5c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5a1c5c5c5a1c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5a1c5c5a1c5c5c5a1a1a1a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1a1a1c5a1c5a1c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5a1a1a1c5c5c5c5a1a1a1c5c5c5c5c5a1c5c5c5a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5a1c5c5c5c5c5a1a1a1a1c5c5c5a1c5c5c5a1c5c5c5a1a1c5c5c5c5a1a1a1c5a1c5c5c5a1c5c5c5c5c5a1a1a1c5a1c5a1c5a1a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1a1a1a1c5c5a1c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5a1c5c5a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1a1c5c5c5c5a1a1a1a1c5c5c5a1c5a1c5c5c5c5a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5a1c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5a1c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5a1c5c5c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5a1c5c5a1c5c5c5a1a1a1a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1a1a1c5a1c5a1c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5a1a1a1c5c5c5c5a1a1a1c5c5c5c5c5a1c5c5c5a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5a1c5c5c5c5c5a1a1a1a1c5c5c5a1c5c5c5a1c5c5c5a1a1c5c5c5c5a1a1a1c5a1c5c5c5a1c5c5c5c5c5a1a1a1c5a1c5a1c5a1a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a7a3d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a1a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0d1a3d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3``````````````````````````````````````````````b0a1a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1a1c5a1c5c5a1c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5a1c5a1c5a1c5a1c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5c5a1a1c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5a1c5a1c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5a1a1a1a1c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1a1c5a1c5c5c5a1a1a1c5c5a1a1a1c5c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1a1c5c5a1a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5a1a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5a1c5c5a1c5c5a1d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5a1d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1a1a1c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1c5c5c5a1c5c5c5c5a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5a1c5c5c5a1a1a1a1c5c5c5a1c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1a1a1a1c5c5a1c5c5a1d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1a1c5a1c5c5a1c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5a1c5a1c5a1c5a1c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5c5a1a1c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5a1c5a1c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5a1a1a1a1c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5a1c5c5a1c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1a1c5c5a1a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5a1a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1a1c5c5a1c5c5c5a1c5c5c5c5a1c5c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5a1c5c5a1c5c5a1d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5a1a1c5a1c5c5a1c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1a1a1c5a1c5c5c5a1c5c5c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5a1a1a1c5a1c5a1c5c5c5a1c5c5c5a1a1c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5c5c5a1a1c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5c5a1a1a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5a1a1a1c5a1c5c5c5a1c5c5c5c5a1c5c5c5a1a1c5a1c5c5c5a1a1a1c5a1c5a1a1c5c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1a1a1c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1c5c5c5a1c5c5c5c5a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5a1a1c5a1c5c5a1c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1a1a1c5a1c5c5c5a1c5c5c5c5c5a1a1a1c5c5c5c5a1a1c5a1c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5a1a1a1c5a1c5a1c5c5c5a1c5c5c5a1a1c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5c5c5a1a1c5a1c5c5c5a1a1a1c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5d0a3a5a3````````````", "````````a5a3d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5a1a1a1c5c5a1c5c5c5a1c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5a1c5c5c5a1c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5a1c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5a1c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5a1c5a1c5c5c5c5c5a1c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1c5c5c5c5c5a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5a1a1a1c5c5a1a1a1c5a1c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5a1c5a1c5c5c5c5c5a1c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1c5c5c5c5c5a1a1a1a1a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1a1c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1a1c5c5c5c5a1a1a1a1c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5a1c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5a1a1c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1a1c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1a1c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1a1c5c5c5c5a1a1a1a1c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5a1c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1a1c5c5c5a1a1c5a1c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5a1a1c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5a1a1c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5c5a1a1c5a1a1a1a1a1a1a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5c5a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5a1c5c5c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1a1a1a1a1a1c5c5a1c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5a1c5c5c5c5c5a1c5c5c5a1c5a1a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1a1a1a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5a1c5c5c5c5a1c5a1c5c5a1c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5c5a1a1c5a1a1a1a1a1a1a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5a1c5c5c5c5a1a1a1c5c5a1c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5c5a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5a1a1a1a1a1a1c5c5c5a1c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5c5a1c5a1c5a1c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1a1a1a1a1a1c5c5a1c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1a1a1c5a1c5c5c5a1c5a1c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1a1a1a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5a1a1a1a1a1a1a1c5c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5a1a1a1a1c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5a1c5a1c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5a1c5c5c5c5a1c5c5a1c5c5a1a1a1a1a1a1c5c5c5a1c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1c5c5c5c5c5a1c5c5c5c5a1a1a1a1a1a1a1c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1a1a1a1a1a1a1c5c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5a1a1a1a1c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5a1c5c5a1a1a1a1a1a1c5a1a1a1a1a1c5c5c5a1a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5a1a1a1a1a1c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5a1c5a1c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1a1c5a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5a1c5a1c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1a1a1a1a1c5c5a1a1a1a1a1c5c5c5a1a1a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5a1c5a1c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5a1c5c5a1a1a1a1a1a1c5a1a1a1a1a1c5c5c5a1a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5a1a1a1a1a1c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5a1c5a1c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5a1a1a1a1a1a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5a1c5c5a1a1a1a1a1a1c5a1c5c5c5c5c5c5c5a1a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1a1a1a1a1c5c5a1a1a1a1a1c5c5c5a1a1a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1c5a1c5a1c5a1c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5a1c5c5a1a1a1a1a1a1c5a1c5c5c5c5c5c5c5a1a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``````````````````````````````````````````````````````````````````````````d0a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0``d0a1``````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``````````````````````````````d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3``d0a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5``d0a1``````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``````````````````````````````````````````````````````````````````````````d0a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``````````````````````````````d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````a1a1``````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1````a1````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````a1a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````a1````a1````c5``c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1````a1````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````a1````c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1````a1````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````a1``````c5``c5c5c5c5a1a1a1a1a1c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1````a1````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````a1````````c5``c5c5c5a1a1a1a1a1a1a1c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1````a1````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1````a1````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````a1``````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1````a1````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````a1a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````a1a1a1a1````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1````a1````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5a1a1a1a1a1c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1a1a1c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1````a1````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5a1a1a1a1a1a1a1c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1````a1````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````a1a1a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1````````````````c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1````````````````c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1````````````````c5``````````````````````````````d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5``d0a1``````````````````````````````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a3a5a3````````````", "````````a5a3``d0a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1````````````````````c5``````````````````````````````d0a1a3a5a3````````````", "````````a5a3``d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1``````````````````````````````a1````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``````````````````````````````````````````````````````````````````````````d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````a1a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````a1````a1````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5d0a1````a1````a1````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5a1a1c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5d0a1````a1````a1````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````a1a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5a1a1c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5d0a1````a1````a1````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````a1````a1````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````a1````a1````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5d0a1````a1````a1````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````a1a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5a1a1c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5d0a1````a1````a1````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5a1a1c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5d0a1````a1````a1````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````a1````a1````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````a1a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1``````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1a1a1``````````````````````````````a1a1a1a1a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1``````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1a1a1``````````````````````````````a1a1a1a1a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0``d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``d0a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5``d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1``````````````````````````````a1a1a1a1a1a1a1````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1``````````````````````````````a1a1a1a1a1a1a1````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1``````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1a1``````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````a1a1a1a1``````````````````````````````````````````````a1a1````````````````````````````````````````````````````````a1a1a1a1a1``````````a1``````````````````````````````````````````````````````````````````````````a1a1a1a1a1``````````````````````````````````````````a1````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````a1``````````````````````````````````````````````````````a1a1``````````a1a1``````````````````````````````````````````````````````````````````````````````a1a1``````````a1a1``````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1a1``````````````````a1a1``````````````````````````````````````````````````````````````````````a1a1``````````````````a1a1``````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5``d0a1````````````````````````````````````````a1``````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````a1``````````````````````````````````````````````````````````````````````a1``````````````````````a1````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``d0a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1````````````````````````````````````a1a1a1a1``````````````````````````````````````````````a1a1````````````````````````````````````````````````````````a1a1a1a1a1``````````a1``````````````````````````````````````````````````````````````````````````a1a1a1a1a1``````````````````````````````````````````a1````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``d0a1````````````````````````````````````````a1````````````````````````````````````````````````a1``````````````````````````````````````````````````````a1a1``````````a1a1``````````````````````````````````````````````````````````````````````````````a1a1``````````a1a1``````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````````````````````a1``````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``````````````````````````````````````````````````````````````````````````d0a1````````````````````````````````````````a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1a1``````````````````a1a1``````````````````````````````````````````````````````````````````````a1a1``````````````````a1a1``````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````a1a1``````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````a1``````````````````````````````````````````````````````````````````````a1``````````````````````a1````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````a1````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````a1````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````````````````````a1``````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5a1a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1``````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````a1a1``````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1``````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````a1````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1````````````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````````````````````a1``````````````````````````a1````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````a1````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1``````````````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5a1a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1``````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1````````````````````````````````````````````````````````````a1``````````````````````a1``````````````````````````````````````````````````````````````````````a1``````````````````````a1````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1``````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1````````````````````````````````````````````````````````````a1a1``````````````````a1a1``````````````````````````````````````````````````````````````````````a1a1``````````````````a1a1````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1````````````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````````````````````a1``````````````````````````a1````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````a1a1``````````a1a1``````````````````````````````````````````````````````````````````````````````a1a1``````````a1a1``````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1``````````````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1``````````````````````a1a1a1a1a1a1a1a1a1a1a1``````````````a1``````````````a1``a1``````````a1``````````````a1``````````````a1``````````````a1``````````a1a1a1a1a1``````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````a1a1a1a1a1``````````a1``````````````a1``````````````a1``````````````a1``````````a1``a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1````````````````````````````````````````````````````````````a1``````````````````````a1``````````````````````````````````````````````````````````````````````a1``````````````````````a1````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1````````````````````````````````````````````````````````````a1a1``````````````````a1a1``````````````````````````````````````````````````````````````````````a1a1``````````````````a1a1````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````a1a1``````````a1a1``````````````````````````````````````````````````````````````````````````````a1a1``````````a1a1``````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1``````````````````````a1a1a1a1a1a1a1a1a1a1a1``````````````a1``````````````a1``a1``````````a1``````````````a1``````````````a1``````````````a1``````````a1a1a1a1a1``````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````a1a1a1a1a1``````````a1``````````````a1``````````````a1``````````````a1``````````a1``a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1``````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1``````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````a1a1a1a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````a1a1a1a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1``````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1``````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````a1a1a1a1a1a1a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1``````````````````````````````a1a1a1a1a1a1a1``````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1a1c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````a1a1a1a1``````````````````````````````````````````````a1a1````````````````````````````````````````````a1a1````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````a1````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````a1a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````a1a1a1a1``````````````````````````````````````````````a1a1````````````````````````````````````````````a1a1````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````a1````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````a1``````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````a1``````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````a1a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````a1``````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1``````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````a1a1``````a1``````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````a1``a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5a1a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````a1``````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````a1a1a1````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````a1a1a1````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1``````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````a1a1``````a1``````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````a1``a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````a1a1a1a1a1``````````````````````````a1a1a1a1a1````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````a1a1a1````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````a1a1a1````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````a1a1a1a1a1``````````````````````````a1a1a1a1a1````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1``````````````a1``````````````a1``````````````a1``````````````a1````````a1a1``a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``a1a1````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5a1c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1``````````````a1``````````````a1``````````````a1``````````````a1````````a1a1``a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``a1a1````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1``````````````a1````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a1````````a1``````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````a1a1a1``````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5a1c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a1````````a1``````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````a1``````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````a1a1a1``````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````a1``````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````a1a1a1a1````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````a1``````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````a1``````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``````````````````````````````d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1c5c5c5c5a1c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5``a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````````a1``````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5``c5``c5``c5``c5``c5``c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1````a1a1a1a1````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1c5c5c5c5c5a1c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````a1a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1a1a1``````````````````````````````a1a1a1a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``````````````````````````````d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1c5c5c5c5a1c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1``````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5d0a1````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1``````````````````````````````````````````````````````````````````````a1a1a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1a1a1``````````````````````````````a1a1a1a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5a1a1a1a1a1a1a1c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````a1a1a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1``````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5a1a1a1a1a1c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5a1a1a1a1a1a1a1c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5a1a1a1a1a1c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5a1c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5a1c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1````````````````````````````````````````a1a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1````````````````````````````````````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a3a5a3````````````````````````````````````````````````a5a3a1``````````````````````````````d0``````````````````````````````d0``````````````````````````````d0``````````````````````````````d0a1``````````````````````````````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5````d0a1c5``````````````````````````````d0a1c5``````````````````d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``````````````````````````````d0a1a1d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0``c5a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1c5c5c5c5c5c5c5c5c5c5c5d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1a3a5a3````````````````````````````````````````````````a5a3a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0c5a1``````````````````````````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1````````````````````````````````````````a1``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1c5c5c5c5c5c5c5c5a1c5c5d0``c5c5c5c5c5c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0``c5c5a1c5c5c5c5c5c5c5c5a1c5c5d0c5a1``````````````````````````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1````````````````````````````````````````````````a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1c5c5c5c5c5c5a1a1a1c5c5d0``c5c5c5c5c5c5c5c5a1a1a1c5c5c5d0``c5c5c5a1a1a1c5c5c5c5c5c5c5c5d0``c5c5a1a1a1c5c5c5c5c5c5a1c5c5d0c5c5a1``````````````````a1``````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``````````````````````````````d0``````````````````````````````d0``````````````````````````````d0``````````````````````````````d0a1``````````````````````````````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5````d0a1c5``````````````````````````````d0a1c5``````````````````````````````````````d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``````````````````````````````d0a1a1d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0``c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1c5c5c5c5c5a1c5c5a1c5c5d0``c5c5c5c5c5c5c5a1c5c5a1c5c5c5d0``c5c5c5a1c5c5a1c5c5c5c5c5c5c5d0``c5c5a1c5c5a1c5c5c5c5c5a1c5c5d0c5c5a1``````````````a1a1a1``````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0c5a1``````````````````````````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1c5c5c5a1a1c5c5c5a1c5c5d0``c5c5c5c5c5a1a1c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5a1a1c5c5c5c5c5d0``c5c5a1c5c5c5a1a1c5c5c5a1c5c5d0c5c5c5a1````````````````a1````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5a1a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5a1a1c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``c5c5a1c5c5c5c5c5c5c5c5a1c5c5d0``c5c5c5c5c5c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0``c5c5a1c5c5c5c5c5c5c5c5a1c5c5d0c5a1``````````````````````````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1c5a1a1c5c5c5c5c5a1c5c5d0``c5c5c5a1a1c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5a1a1c5c5c5d0``c5c5a1c5c5c5c5c5a1a1c5a1c5c5d0c5c5c5a1````````````````a1````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``c5c5a1c5c5c5c5c5c5a1a1a1c5c5d0``c5c5c5c5c5c5c5c5a1a1a1c5c5c5d0``c5c5c5a1a1a1c5c5c5c5c5c5c5c5d0``c5c5a1a1a1c5c5c5c5c5c5a1c5c5d0c5c5a1``````````````````a1``````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1a1c5c5c5c5c5c5c5a1c5c5d0``c5c5a1c5c5c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5c5c5a1c5c5d0``c5c5a1c5c5c5c5c5c5c5a1a1c5c5d0c5c5c5a1````````````````a1````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5a1a1a1a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5a1a1a1a1c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``c5c5a1c5c5c5c5c5a1c5c5a1c5c5d0``c5c5c5c5c5c5c5a1c5c5a1c5c5c5d0``c5c5c5a1c5c5a1c5c5c5c5c5c5c5d0``c5c5a1c5c5a1c5c5c5c5c5a1c5c5d0c5c5a1``````````````a1a1a1``````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1a1c5c5c5c5c5c5c5a1c5c5d0``c5c5a1c5c5c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5c5c5a1c5c5d0``c5c5a1c5c5c5c5c5c5c5a1a1c5c5d0c5c5c5c5a1``````````````a1``````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``c5c5a1c5c5c5a1a1c5c5c5a1c5c5d0``c5c5c5c5c5a1a1c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5a1a1c5c5c5c5c5d0``c5c5a1c5c5c5a1a1c5c5c5a1c5c5d0c5c5c5a1````````````````a1````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5a1a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5a1a1c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1c5a1a1c5c5c5c5c5a1c5c5d0``c5c5c5a1a1c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5a1a1c5c5c5d0``c5c5a1c5c5c5c5c5a1a1c5a1c5c5d0c5c5c5c5a1``````````a1a1a1a1````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5a1a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5a1a1c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``c5c5a1c5a1a1c5c5c5c5c5a1c5c5d0``c5c5c5a1a1c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5a1a1c5c5c5d0``c5c5a1c5c5c5c5c5a1a1c5a1c5c5d0c5c5c5a1````````````````a1````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1c5c5c5a1a1c5c5c5a1c5c5d0``c5c5c5c5c5a1a1c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5a1a1c5c5c5c5c5d0``c5c5a1c5c5c5a1a1c5c5c5a1c5c5d0c5c5c5c5c5a1``````````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``c5c5a1a1c5c5c5c5c5c5c5a1c5c5d0``c5c5a1c5c5c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5c5c5a1c5c5d0``c5c5a1c5c5c5c5c5c5c5a1a1c5c5d0c5c5c5a1````````````````a1````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5a1a1a1a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5a1a1a1a1c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1c5c5c5c5c5a1c5c5a1c5c5d0``c5c5c5c5c5c5c5a1c5c5a1c5c5c5d0``c5c5c5a1c5c5a1c5c5c5c5c5c5c5d0``c5c5a1c5c5a1c5c5c5c5c5a1c5c5d0c5c5c5c5c5a1``````````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``c5c5a1a1c5c5c5c5c5c5c5a1c5c5d0``c5c5a1c5c5c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5c5c5a1c5c5d0``c5c5a1c5c5c5c5c5c5c5a1a1c5c5d0c5c5c5c5a1``````````````a1``````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5a1a1a1c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1c5c5c5c5c5c5a1a1a1c5c5d0``c5c5c5c5c5c5c5c5a1a1a1c5c5c5d0``c5c5c5a1a1a1c5c5c5c5c5c5c5c5d0``c5c5a1a1a1c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5a1``````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``c5c5a1c5a1a1c5c5c5c5c5a1c5c5d0``c5c5c5a1a1c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5a1a1c5c5c5d0``c5c5a1c5c5c5c5c5a1a1c5a1c5c5d0c5c5c5c5a1``````````a1a1a1a1````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5a1a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5a1a1c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5a1c5c5c5c5c5c5c5c5a1c5c5d0``c5c5c5c5c5c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0``c5c5a1c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``c5c5a1c5c5c5a1a1c5c5c5a1c5c5d0``c5c5c5c5c5a1a1c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5a1a1c5c5c5c5c5d0``c5c5a1c5c5c5a1a1c5c5c5a1c5c5d0c5c5c5c5c5a1``````````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5a1c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5a1c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````", "````````a5a3a1``c5c5a1c5c5c5c5c5a1c5c5a1c5c5d0``c5c5c5c5c5c5c5a1c5c5a1c5c5c5d0``c5c5c5a1c5c5a1c5c5c5c5c5c5c5d0``c5c5a1c5c5a1c5c5c5c5c5a1c5c5d0c5c5c5c5c5a1``````````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5d0d0d0a1c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1c5d0d0d0d0d0d0d0d0d0d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1a1````````````````````````````````c5a3a5a3````````````", "````````a5a3a1``c5c5a1c5c5c5c5c5c5a1a1a1c5c5d0``c5c5c5c5c5c5c5c5a1a1a1c5c5c5d0``c5c5c5a1a1a1c5c5c5c5c5c5c5c5d0``c5c5a1a1a1c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5a1``````````````````````a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````", "````````a5a3a1``c5c5a1c5c5c5c5c5c5c5c5a1c5c5d0``c5c5c5c5c5c5c5c5c5c5a1c5c5c5d0``c5c5c5a1c5c5c5c5c5c5c5c5c5c5d0``c5c5a1c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3``````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````d0a3a5a3````````````", "````````a5a3a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5``c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1a1d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3a1d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5d0d0d0a1c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1a1````````````````````````````````c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0``c5d0a3a5a3````````````", "````````a5a3a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5``c5a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````", "````````a5a3``````````````````````````````````````````````````````````````````````````````````````a1````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5a1a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5a1a1a1c5a1c5a1c5a1c5a1c5a1c5c5d0c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1c5a1c5a1a1a1c5a1c5a1c5a1c5c5d0c5c5c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1c5a1c5a1c5a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5a1a1a1c5a1c5a1c5a1c5a1c5a1c5c5d0c5c5a1c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5a1c5c5a1a1a1c5c5c5a1c5a1c5c5a1c5c5c5c5a1a1a1c5c5c5a1c5a1a1c5c5``c5c5a1c5a1c5a1c5a1a1a1c5a1c5a1c5a1c5c5d0c5c5a1c5c5c5c5c5c5c5c5a1c5a1c5a1c5c5c5a1a1c5a1c5c5c5c5c5c5a1c5a1c5c5a1c5c5c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5``c5c5a1c5a1c5a1c5a1c5a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5c5c5a1c5c5c5a1a1a1c5c5c5c5a1a1a1c5c5c5a1c5a1c5c5a1a1a1c5c5c5a1c5a1c5c5a1c5c5c5c5a1a1a1c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1c5c5a1a1c5c5c5a1a1c5a1c5a1c5a1c5a1a1a1c5c5a1c5c5a1c5c5a1c5c5c5c5d0a1``c5a1c5a1a1a1c5a1c5a1c5a1c5a1c5a1c5c5d0c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5c5a1c5c5a1a1c5a1a1c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5``c5c5a1c5a1c5a1c5a1a1a1c5a1c5a1c5a1c5c5d0c5c5a1c5c5c5c5c5c5c5c5a1a1c5c5a1c5c5a1c5c5a1a1c5c5c5c5c5c5a1a1c5a1a1c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5``c5c5a1c5a1c5a1c5a1c5a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5c5a1c5c5a1a1c5a1a1c5a1c5c5a1c5c5c5a1c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1a1a1a1c5c5a1c5c5a1c5a1c5c5a1a1c5a1a1c5c5c5c5c5a1c5a1c5c5a1c5c5a1c5c5c5c5d0a1``c5a1c5a1a1a1c5a1c5a1c5a1c5a1c5a1c5c5d0c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5``c5c5a1c5a1c5a1c5a1a1a1c5a1c5a1c5a1c5c5d0c5c5a1c5c5c5a1a1a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5``c5c5a1c5a1c5a1c5a1c5a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5a1a1a1a1c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5a1a1a1c5a1c5a1c5a1c5a1c5a1c5c5d0c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1c5a1c5a1a1a1c5a1c5a1c5a1c5c5d0c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1c5a1c5a1c5a1c5a1a1a1c5a1c5c5d0c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1c5a1a1a1a1c5a1c5c5c5a1c5a1c5c5c5c5a1a1a1c5c5a1c5a1c5a1c5c5c5c5c5d0a1``c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1a1a1a1a1c5c5a1c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5a1c5c5c5a1c5``c5c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5a1c5c5c5a1c5c5``c5c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5c5c5a1c5c5a1a1a1a1a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1a1a1a1a1c5c5a1c5c5a1c5c5a1c5c5a1a1a1a1a1c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5a1a1a1c5a1c5a1c5a1c5a1c5a1c5c5d0c5c5c5a1c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1c5a1c5a1a1a1c5a1c5a1c5a1c5c5d0c5c5c5a1c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1c5a1c5a1c5a1c5a1a1a1c5a1c5c5d0c5c5c5a1c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5a1a1c5c5c5c5a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1c5a1c5c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5a1c5c5a1c5a1c5a1c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5c5c5a1c5c5a1c5c5c5c5c5c5a1c5c5c5c5c5c5a1c5c5c5a1c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1c5c5a1a1c5c5c5a1a1c5a1c5a1c5a1c5a1a1a1c5c5a1c5c5a1c5c5a1c5c5c5c5d0a1``c5a1c5a1a1a1c5a1c5a1c5a1c5a1c5a1c5c5d0c5c5a1c5c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1c5a1c5a1a1a1c5a1c5a1c5a1c5c5d0c5c5a1c5c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1c5a1c5a1c5a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5a1a1c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1c5a1c5c5a1c5a1c5c5a1a1c5a1c5c5c5a1c5c5a1c5c5c5a1c5a1c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5a1c5c5c5a1a1c5c5a1c5c5c5a1c5c5a1c5c5a1a1c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5a1c5c5a1c5c5a1c5c5c5a1c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5a1a1a1a1c5c5a1c5c5a1c5a1c5c5a1a1c5a1a1c5c5c5c5c5a1c5a1c5c5a1c5c5a1c5c5c5c5d0a1``c5a1c5a1a1a1c5a1c5a1c5a1c5a1c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1c5a1c5a1a1a1c5a1c5a1c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1c5a1c5a1c5a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5a1c5c5c5a1c5c5a1a1c5c5c5a1a1c5a1c5a1c5c5c5c5a1a1a1a1c5c5a1c5a1c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5c5a1a1a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5a1a1a1c5a1c5c5a1c5c5c5a1c5c5c5a1a1c5a1c5c5c5c5c5c5a1c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1a1a1a1a1c5c5c5c5c5a1a1a1c5c5c5c5a1a1a1c5c5c5a1c5c5c5c5a1a1a1c5c5c5a1c5c5a1c5c5a1c5c5c5a1a1a1c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1c5a1a1a1a1c5a1c5c5c5a1c5a1c5c5c5c5a1a1a1c5c5a1c5a1c5a1c5c5c5c5c5d0a1``c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5a1a1a1c5a1a1a1c5a1a1a1c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1a1a1a1a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1c5a1c5c5c5c5a1c5c5c5a1c5a1c5c5c5a1c5c5a1c5c5a1c5a1c5a1c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1c5a1c5c5a1c5a1c5c5a1a1c5a1c5c5c5a1c5c5a1c5c5c5a1c5a1c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5a1c5c5c5a1c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5a1c5c5c5a1c5c5a1a1c5c5c5a1a1c5a1c5a1c5c5c5c5a1a1a1a1c5c5a1c5a1c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5a1c5c5c5a1c5c5c5a1a1a1c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5````````````````````````````````````````````````````````````````````````````````````````````````````````````c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5````````````````````````````````````````````````````````````````````````````````````````````````````````````c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5````````````````````````````````````````````````````````````````````````````````````````````````````````````c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5d0c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5a1c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3``d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5a1a1a1a1a1a1a1a1a1a1a1a1a1c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5``c5d0a3a5a3````````````````````````````````````````````````a5a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a5a3````````````", "````````a5a3``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````c5d0a3a5a3````````````````````````````````````````````````````````````````````````````````````a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a3``````````````````````````````````````a3````````````", "````````a5a3``d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a1``c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5c5d0a3a5a3````````````````````````````````````````````````a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3````````````", "````````a5a3a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1a1d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0d0a3a5a3````````````````````````````````````````````````a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3````````````", "````````a5a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a5a3````````````````````````````````````````````````a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3````````````", "````````````````````````````````````````````a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a3``````````````````````````````````````a3````````````````````````````````````````````````a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a5a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3````````````", "````````a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``````````````````````````````````````````````a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3````````````", "````````a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3``a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a7a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "``````a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````"],[ ]). tgif-QPL-4.2.5/rmcast/doc/manual/mainloop.eps0000644000076400007640000001605610122646341020644 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 113 572 476 763 %%Title: mainloop %%CreationDate: Fri Apr 12 14:25:56 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 56 dict def tgifdict begin /tgifarrowtipdict 8 dict def tgifarrowtipdict /mtrx matrix put /TGAT % tgifarrowtip { tgifarrowtipdict begin /dy exch def /dx exch def /h exch def /w exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate dy dx atan rotate 0 0 moveto w neg h lineto w neg h neg lineto savematrix setmatrix end } def /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /tgifreencsmalldict 12 dict def /tgifReEncodeSmall { tgifreencsmalldict begin /newcodesandnames exch def /newfontname exch def /basefontname exch def /basefontdict basefontname findfont def /newfont basefontdict maxlength dict def basefontdict { exch dup /FID ne { dup /Encoding eq { exch dup length array copy newfont 3 1 roll put } { exch newfont 3 1 roll put } ifelse } { pop pop } ifelse } forall newfont /FontName newfontname put newcodesandnames aload pop newcodesandnames length 2 idiv { newfont /Encoding get 3 1 roll put} repeat newfontname newfont definefont pop end } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def /NewCenturySchlbk-Roman-vec [ 8#250 /dieresis ] def /NewCenturySchlbk-Roman /NewCenturySchlbk-Roman-8 NewCenturySchlbk-Roman-vec tgifReEncodeSmall end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 113 572 476 763 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % TEXT NP 0 SG GS 1 W 221 130 M GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (select\(\) system call) SH GR GR % BOX 0 SG GS 10 SM GS NP 215 99 M 360 99 L 360 147 L 215 147 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 388 215 M 388 279 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 388 129 M 388 215 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 356 128 M 0 205 atan DU cos 8.000 MU 561 exch SU exch sin 8.000 MU 128 exch SU L TGSM 1 W S GR GS TGSM NP 561 128 8.000 3.000 205 0 TGAT 1 SG CP F 0 SG NP 561 128 8.000 3.000 205 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 391 254 M GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (received a request to pack) SH GR 0 17 RM GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS ( the current state ) SH GR GR % TEXT NP 0 SG GS 1 W 397 177 M GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (\(2\) received \250reliable ) SH GR 0 17 RM GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (message\250 from the net) SH GR GR % TEXT NP 0 SG GS 1 W 397 119 M GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (\(1\) X event received) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 388 201 M 0 169 atan DU cos 8.000 MU 557 exch SU exch sin 8.000 MU 201 exch SU L TGSM 1 W S GR GS TGSM NP 557 201 8.000 3.000 169 0 TGAT 1 SG CP F 0 SG NP 557 201 8.000 3.000 169 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 389 278 M 0 169 atan DU cos 8.000 MU 558 exch SU exch sin 8.000 MU 278 exch SU L TGSM 1 W S GR GS TGSM NP 558 278 8.000 3.000 169 0 TGAT 1 SG CP F 0 SG NP 558 278 8.000 3.000 169 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 586 185 M GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (Process the command received and) SH GR 0 17 RM GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (send to self an X event which ) SH GR 0 17 RM GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (instructs how this command must) SH GR 0 17 RM GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (be executed.) SH GR GR % BOX 0 SG GS 10 SM GS NP 577 170 M 834 170 L 834 242 L 577 242 L CP S GR GR % TEXT NP 0 SG GS 1 W 579 133 M GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (XNextEvent\(mainDisplay, pXEvent\);) SH GR GR % BOX 0 SG GS 10 SM GS NP 577 106 M 834 106 L 834 154 L 577 154 L CP S GR GR % TEXT NP 0 SG GS 1 W 584 291 M GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (HandleNewUserRequest\(\);) SH GR GR % BOX 0 SG GS 10 SM GS NP 578 260 M 835 260 L 835 308 L 578 308 L CP S GR GR % TEXT NP 0 SG GS 1 W 479 375 M GS 0 SG /NewCenturySchlbk-Roman-8 FF [14 0 0 -14 0 0] MS (Note that after \(2\) we will always get \(1\) in the future.) SH GR GR % BOX 0 SG GS 10 SM GS NP 205 53 M 845 53 L 845 387 L 205 387 L CP S GR GR % TEXT NP 0 SG GS 1 W 395 80 M GS 0 SG /NewCenturySchlbk-Roman-8 FF [18 0 0 -18 0 0] MS (Main loop of the whiteboard) SH GR GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Fri Apr 12 14:25:56 2002 %%DocumentFonts: NewCenturySchlbk-Roman %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/fleventlist.eps0000644000076400007640000003334510122646341021365 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 41 332 470 749 %%Title: fleventlist %%CreationDate: Tue May 21 09:54:26 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 56 dict def tgifdict begin /tgifarrowtipdict 8 dict def tgifarrowtipdict /mtrx matrix put /TGAT % tgifarrowtip { tgifarrowtipdict begin /dy exch def /dx exch def /h exch def /w exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate dy dx atan rotate 0 0 moveto w neg h lineto w neg h neg lineto savematrix setmatrix end } def /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /tgifreencsmalldict 12 dict def /tgifReEncodeSmall { tgifreencsmalldict begin /newcodesandnames exch def /newfontname exch def /basefontname exch def /basefontdict basefontname findfont def /newfont basefontdict maxlength dict def basefontdict { exch dup /FID ne { dup /Encoding eq { exch dup length array copy newfont 3 1 roll put } { exch newfont 3 1 roll put } ifelse } { pop pop } ifelse } forall newfont /FontName newfontname put newcodesandnames aload pop newcodesandnames length 2 idiv { newfont /Encoding get 3 1 roll put} repeat newfontname newfont definefont pop end } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def /Courier-vec [ 8#264 /acute ] def /Courier /Courier-8 Courier-vec tgifReEncodeSmall end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 41 332 470 749 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % POLY/OPEN-SPLINE 0 SG GS NP 80 128 M 0 144 atan DU cos 8.000 MU 224 exch SU exch sin 8.000 MU 128 exch SU L TGSM 1 W S GR GS TGSM NP 224 128 8.000 3.000 144 0 TGAT 1 SG CP F 0 SG NP 224 128 8.000 3.000 144 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 96 112 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (NAK_SND_WAIT) SH GR GR % BOX 0 SG GS 10 SM GS NP 240 96 M 480 96 L 480 160 L 240 160 L CP S GR GR % TEXT NP 0 SG GS 1 W 256 115 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (search in the cache the) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (record of the member M1) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (whose messages were lost) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 488 128 M 0 64 atan DU cos 8.000 MU 552 exch SU exch sin 8.000 MU 128 exch SU L TGSM 1 W S GR GS TGSM NP 552 128 8.000 3.000 64 0 TGAT 1 SG CP F 0 SG NP 552 128 8.000 3.000 64 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 579 100 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (send a NACK requesting) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (a retransmission of the) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (packets lost, and add) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (a RET_RCV_WAIT to the) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (event list) SH GR GR % BOX 0 SG GS 10 SM GS NP 562 79 M 802 79 L 802 177 L 562 177 L CP S GR GR % TEXT NP 0 SG GS 1 W 101 152 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (parameters:) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (member M1) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 80 273 M 0 144 atan DU cos 8.000 MU 224 exch SU exch sin 8.000 MU 273 exch SU L TGSM 1 W S GR GS TGSM NP 224 273 8.000 3.000 144 0 TGAT 1 SG CP F 0 SG NP 224 273 8.000 3.000 144 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 96 257 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (RET_RCV_WAIT) SH GR GR % TEXT NP 0 SG GS 1 W 79 298 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (parameters:) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (member M1) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (sequence number sn) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 344 197 M 234 273 L 344 353 L 458 276 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 345 251 M GS GS 0 /Courier-8 FF [14 0 0 -14 0 0] MS (the number) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (the number) SH GR 0 16 RM GS GS 0 /Courier-8 FF [14 0 0 -14 0 0] MS (of NACKs just sent) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (of NACKs just sent) SH GR 0 16 RM GS GS 0 /Courier-8 FF [14 0 0 -14 0 0] MS (is equal to the) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (is equal to the) SH GR 0 16 RM GS GS 0 /Courier-8 FF [14 0 0 -14 0 0] MS (maximum) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (maximum) SH GR 0 16 RM GS GS 0 /Courier-8 FF [14 0 0 -14 0 0] MS (allowed?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (allowed?) SH GR 0 16 RM GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % POLY/OPEN-SPLINE 0 SG GS NP 470 274 M 0 64 atan DU cos 8.000 MU 534 exch SU exch sin 8.000 MU 274 exch SU L TGSM 1 W S GR GS TGSM NP 534 274 8.000 3.000 64 0 TGAT 1 SG CP F 0 SG NP 534 274 8.000 3.000 64 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 495 259 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (no) SH GR GR % TEXT NP 0 SG GS 1 W 556 276 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (re-schedule a NAK_SND_WAIT) SH GR GR % BOX 0 SG GS 10 SM GS NP 554 242 M 794 242 L 794 306 L 554 306 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 345 358 M 345 391 L 2 0 atan DU cos 8.000 MU 345 exch SU exch sin 8.000 MU 393 exch SU L TGSM 1 W S GR GS TGSM NP 345 393 8.000 3.000 0 2 TGAT 1 SG CP F 0 SG NP 345 393 8.000 3.000 0 2 TGAT CP F GR % TEXT NP 0 SG GS 1 W 300 434 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (do nothing) SH GR GR % BOX 0 SG GS 10 SM GS NP 232 399 M 472 399 L 472 463 L 232 463 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 80 533 M 0 144 atan DU cos 8.000 MU 224 exch SU exch sin 8.000 MU 533 exch SU L TGSM 1 W S GR GS TGSM NP 224 533 8.000 3.000 144 0 TGAT 1 SG CP F 0 SG NP 224 533 8.000 3.000 144 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 96 517 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (RET_SND_WAIT) SH GR GR % TEXT NP 0 SG GS 1 W 77 555 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (parameters:) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (member M1) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (sequence number sn) SH GR GR % TEXT NP 0 SG GS 1 W 241 524 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (send a retransmission of) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (the requested packet, if) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (possible) SH GR GR % BOX 0 SG GS 10 SM GS NP 230 503 M 470 503 L 470 567 L 230 567 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 85 656 M 0 144 atan DU cos 8.000 MU 229 exch SU exch sin 8.000 MU 656 exch SU L TGSM 1 W S GR GS TGSM NP 229 656 8.000 3.000 144 0 TGAT 1 SG CP F 0 SG NP 229 656 8.000 3.000 144 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 101 640 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (REF_SND_WAIT) SH GR GR % TEXT NP 0 SG GS 1 W 82 678 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (parameters:) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (none) SH GR GR % TEXT NP 0 SG GS 1 W 246 646 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (identify the sn of the ) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (last message sent to the ) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (multicaast group by) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (the local member) SH GR GR % BOX 0 SG GS 10 SM GS NP 235 626 M 475 626 L 475 706 L 235 706 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 487 662 M 0 64 atan DU cos 8.000 MU 551 exch SU exch sin 8.000 MU 662 exch SU L TGSM 1 W S GR GS TGSM NP 551 662 8.000 3.000 64 0 TGAT 1 SG CP F 0 SG NP 551 662 8.000 3.000 64 0 TGAT CP F GR % BOX 0 SG GS 10 SM GS NP 565 612 M 833 612 L 833 715 L 565 715 L CP S GR GR % TEXT NP 0 SG GS 1 W 579 637 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (send a refresh message to) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (the group containing the sn) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (of the last message sent,) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (or -1 if the member haven\264t) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (sent any message) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 84 774 M 0 144 atan DU cos 8.000 MU 228 exch SU exch sin 8.000 MU 774 exch SU L TGSM 1 W S GR GS TGSM NP 228 774 8.000 3.000 144 0 TGAT 1 SG CP F 0 SG NP 228 774 8.000 3.000 144 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 100 758 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (LEV_GRP_WAIT) SH GR GR % TEXT NP 0 SG GS 1 W 81 796 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (parameters:) SH GR 0 16 RM GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (none) SH GR GR % TEXT NP 0 SG GS 1 W 276 784 M GS 0 SG /Courier-8 FF [14 0 0 -14 0 0] MS (shut down and exit) SH GR GR % BOX 0 SG GS 10 SM GS NP 237 749 M 477 749 L 477 813 L 237 813 L CP S GR GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Tue May 21 09:54:26 2002 %%DocumentFonts: Courier %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/screencapt.eps0000644000076400007640000036351510122646341021162 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%Creator: GIMP PostScript file plugin V 1.12 by Peter Kirchgessner %%Title: /export/home/allyson/autotools/RelMulticast/doc/manual/screencapt.eps %%CreationDate: Wed Jan 28 15:09:43 2004 %%DocumentData: Clean7Bit %%LanguageLevel: 2 %%Pages: 1 %%BoundingBox: 14 14 942 653 %%EndComments %%BeginProlog % Use own dictionary to avoid conflicts 10 dict begin %%EndProlog %%Page: 1 1 % Translate for offset 14.173228 14.173228 translate % Translate to begin of first scanline 0.000000 638.000000 translate 927.000000 -638.000000 scale % Image geometry 927 638 8 % Transformation matrix [ 927 0 0 638 0 0 ] currentfile /ASCII85Decode filter /RunLengthDecode filter %%BeginData: 123989 ASCII Bytes image q*l%//Ol`07NbJ`oQeH"@YrVHQpmI:2"k3E*5 gZa:TJa9<$!6`=N"4[DK!:94UbNnI!UoitK`HH?tJa7mQWp9Z.kOJ;8p$r'NrUKoVqsaa2!8IMM !!)BU!6a]o#GeKflc"$hU4MW]l`'1MbNJEiRe?4NRf2dVReuUVb5_P>li3FNli3FOlN#-+joCSA F9%R#jp-!Wk2q>=gYRMDJ``up!6aQkpR:gArL3cPrL3ZM!m:SsrqcZqqs49Nqs49Nr9F@+r8n!B qfDh&puVg'IcfdGFPGZ'k(2ZojoETflh?kAli!:Pli!:MlN560!;u0]Rf2RNRf2OPbP^K-c,IYD G/_GLo]?0rIY$X4k,@DBbNJ3cReH(ARf)IQb5g5pqZ$Woli!:Nli!:NlN#-+jp0/M`H6:B`RFJA !H`dAk(2ZmjoETflh?kAlh?kGlN560!;u0\RfD^ORf2OPbPC9$FF!iI!n3*OrcJ2&"*B"SP5]P' j+6?Dk,RPDbNJ3cRe?"BReuCPb5g5pqZ$Wolhm4Olhm4MlN#-(joKRLrT411N->2Bs5jE*Iccgm F9(?Pk(2ZojoETflh?k@lhR"HlN560!;l*VRf)IObPC9$FF!lJ&*&%be`2+#k2pc7k1b!*dt-Y4 k,IJCbNJ0kRec7LRe5qCRel=Ob5g)lqZ$Wnlh?kGlN#-(joKRLroOaOI!jK)IWX`7FFNB,FF;Pg k(2ZnjoETflN!CLlN!CGlhd.IlN560!;bjRReu4IbPC0!FF!lG%_HhWj5Y]4j5Y61j5Y61J`D=A W8dm$kN2c5q;q[Go]H%>qW7k&!7h5R5PkHWk4tJCjoEU#irO7Iro4L#FJ@gUJTTr4FFN91FFJf$ J`EZg!6aQf!1N`G!1NQBqjRBD!m:QDq<%RCqW7e$q;VKtH2ch6X`UT'j+2=4j)fb1j)fa$j+66h irI:#joEBrRK1>#joCkGjoCkCk4tJCjoW^+df\#7qZ-HSqjRBD!6b2u!H`Vdisr25WoN,jFQ;D' IcKI1IY$O1j/:o;bP^K&`VGr&`V/EoRec(GRe>h=Reu4Kb5_P;k5CbEjoEU#irO7Iro4KrFI_CM H$&*,FFN91FFJf$J`E]h!6b<&pR:gu@Dq;q[Gp?)+q_Drn\.2FEF=5FEHBrFFN*'FFJetJ_m<]!6b;upQYC0!0m<;!0m38rKR??rKR6k`Mg O\+qs+13crs4"Hs5rIU!!*&ujoM4VJ\?WJJ \Aq6#CN9Gk2l[A]Dh[.!<<&\!M]UF]n*kJ]tqAfI%pZ'k.:Tns8M-]UAoeXJ\?WJ_S$2%UAsBaZ! 5/C0^&J'5]`@oB!!)Z)!s$$J!<0\2!;*r)!<'S4!5/C2]`8&g]`8'0]`8'.^&J(`]sGBWI%pZ'j oG#%"9Lgb!<<&\!M]Vn^&%fh]`8'$^&J'5]`A#E!!(T`!s$"7!;X;.!<0Y3!;sP0!<'V1!<'V2! <0Y3!<0Y3!;X;5!5/BG]`>_Gqn<"0!PJL0]`8')]`S8J]`A&FrW)T(!!)u2!W]n6rOi12h7Wdgq n2t0q7Ze.J\C6[#^iBHk2s8U!<<&\!M]Vk]`S8J]`A#E!!(T`!s$$J!;aA1!56)F!<'S2!<0Y6! 56&Grk/R;]tFEZ]`>_Gr4N(1qRm+6]`>aZ!5/C0]`\>K]`8'1^&J*)]`8'1]`8'&]`8'2]`J2I! <'S2!8YaZ!;aA/!<'S2!<'S2! <0Y6!56&Grk/R;]tFEZ]`>_Gr4N(1qRm+6]`>aZ!5/C0]`\>K]`8'1^&J*3^&A$1^&J'9]`>aZ! 58@3!PJL4^&A$1^&J'5]`A&F!s$$J!<'S8!56&G]`8'2^&J*2^&A$2]`8'3]`8'3^&A$2]`S8J! !*#3!!*#3rW)r2!!%S`Zb6TkUAsBaZ!;aA/!<'S2!<'S2!<0Y6!56&Grk/R;]tFEZ]`>_Gr4N(1qRm+6]`>aZ!5/C0] `\>K]`8'1^&J*3^&A$1^&J'9]`>aZ!58@3!PJL4^&A$1^&J'5]`A&F!s$$J!<'S8!56&G]`8'2^ &J*2^&A$2]`8'3]`8'3^&A$2]`S8J!!*#3!!*#3rW)r2!!%S`kIh.KUAsB<])Vj2roO6Us8K\9! 56&G]tFFE]b(7X]`8&G]`>aZ!!'^G!56&Grk/^?]tFCG]`8&G!56&Grk/X=]tFEZ]`8&G]`@rC! !)r1!!)u2!!*#3!s$$J!<0Y3!<0\3!!0b5qRlk/mC`Z']tFEZ!<0Y8!5/BG]`A&F'*,_Z!56&G! 56&G]tFEZ]`>aZ!<0Y:!56&G]tFCGrk/C6]tFFE]at1W]`8&G]`>aZ!56&G]tFFF]`S8J]`A&F! s$$J!<0Y@!56&G!56&G]tFEZ]`A&F!s$$J!.hhi]a&qZs5rGDmc4aZ!56&Grk/gB]tFEZ]`>aZ!56&G]tFFE]b(7X]`8&G] `>aZ!!'^G!56&Grk/^?]tFCG]`8&G!56&Grk/X=]tFEZ]`8&G]`@rC!!)r1!!)u2!!*#3!s$$J! <0Y3!<0\3!!0b5qRlk/mC`Z']tFEZ!<0Y8!5/BG]`A&F'*,_Z!56&G!56&G]tFEZ]`>aZ!<0Y:! 56&G]tFCGrk/C6]tFFE]at1W]`8&G]`>aZ!56&G]tFFF]`S8J]`A&F!s$$J!<0Y@!56&G!56&G] tFEZ]`A&F!s$$J!.hiH]a0"[s5rIU!!*&ujoM4Vqn3(3]tFFE]`S8J]`A&F!s$$J!<0Y3!;jGaZ!<0Y6!56&Grk/C6]tFFC]`8'1]`8'2]`8'3]`S8J]`A&F!!)o0!!)l/!!)E"" TZ6L!5/C3]`eDL!56&Grk/C6]tFFF]aOnS]`>aZ!56&G]tFFF]`S8J]`A&F!s$$J!<0Y3!<'S5! 56&Grk/C6]tFF@]`S8J]`A&F!!)o0!s$$J!<0Y9!56&G]tFFF]`S8J]`aZ!<0Y9!56&G]tFFF]`S8J]`@lA!s$$J!<'S5! 56&Grk/C6]tFFF]`8'0]aOnS]`>aZ!56&G]tFFF]`S8J]`A&F!s$$J!;jG0!;sM1!<'S2!<0Y6! 56&Grk/:3qn2t0qRlk/mC`Z']tFEZ!<0Y8!5/BG]`A&F!s$$J!<0Y?!56&G]tFEZ]`>aZ!<0Y6! 56&Grk/C6]tFFF]`8'2]`S8J]`A&F!s$$J!;O50!56&Grk/:3qn3(3]tFFF]`nJM]`>aZ!<0Y6! 56&GJ\C6[#^iBHk2s8U!<<&\!M]Vk]`S8J]`A#E!s$$J!<0Y6!56&Grk/:3rk871s1J[<]tFEZ] `>aZquHc1!!*#3!s$$J!;jG0!;sM1!<'S2!<0Y6!56&Grk/:3r4N45]tFCGrOi12mC`u0]tFEZ] `>_G]tFEZ]`A&F!s$$J!<0Y>!56&G]tFEZ]`>aZquHc1!!*#3!s$$J!<0Y3!<'S5!56&Grk/:3r k8=3rOr.0rk/@5]`A#Er;cl2!!*#3"TZ6L!56)D!<9_4!.hhi]a&qZs5rGDmd'lL!aZ!<0Y8!56&G]tO=Drk8=3qn3(3]tFFE]`S8J]`A&F!s$$J! <0Y3!<0\1!<9_aZquHc1!!%S`kIh.KU AsB<])Vj2roO6Us80J3!56&GrOi:5]tFFF]`S8J]`A&F!s$$J!<0Y?!56&G]tFEZ]`>aZ!;jG0! <0Y6!56&Gqn2t0r4N(1rOi12rk/C6]tFFF]`8'1]`eDL!56&Grk/:3mC`u0]tFEZ]`>_G]tFEZ] `A&F!s$$J!<0Y?!56&G]tFEZ]`>aZ!;jG0!<0Y6!56&Grk/:3rOi:5]tFFF]`8'1]`S8J]`A&F! !*#3!W]n6rk/:3rk/C6]tFFF]`nJM]`>aZ!;jG0!.hhi]a&qZs5rGDlgk72qtgBnroO6Us8K\3! ;aA5!56&G]tFFF]aOnS]`>aZ!56&G]tFFF]`nJM]`>aZ!;O5-!;sM4!56&GrOi:5]tFFF]`S8J] `A&F!s$$J!<0Y?!56&G]tFEZ]`>aZ!;jG0!<0Y6!56&Gqn2t0r4N(1rOi12rk/C6]tFFF]`8'1] `eDL!56&Grk/:3mC`u0]tFEZ]`>_G]tFEZ]`A&F!s$$J!<0Y?!56&G]tFEZ]`>aZ!;jG0!<0Y6! 56&Grk/:3rOi:5]tFFF]`8'1]`S8J]`A&F!!*#3!W]n6rk/:3rk/C6]tFFF]`nJM]`>aZ!;jG0! .hiH]a0"[s5rIU!!*&ujoM4Vqn3(3]tFFE]`S8J]`A&F!s$$J!<0Y6!56&Grk/^?]tFEZ]`>aZ! 56&Grk/X=]tFEZ]`8&G]`@rC!!)r1!!)u2!!*#3!s$$J!<0Y3!;sM6!5/BG]`A&F!!)E"!s$$J! <0Y3!<0Y6!56&Grk/sF]tFEZ]`8&G]`>aZ!56&G]tFFF]a4\P]`>aZ!!'\4rOi12rOi:5]tFFF] a4\P]`>aZ!56&Grk/:3rOi12rOi12rk/a@]tFCG]tFEZ]`>aZ!<0Y6!56&GJ\AD'#CN9Gk2lZ,P 5b=Z!<<&\!M]Vn]`8'0]`8'2]`J2I!<0YI!56&G]tFEZ]`>aZ!!'^G!56&G]tFFF]`nJM]`>aZ! ;sM4!56&GrOi:5]tFFF]`S8J]`A&F!s$$J!<0Y?!56&G]tFEZ]`>aZ!<0Y=!56&G]tFCG]tFFC] `8'1]`8'2]`8'3]`S8J]`A&F!!)r1"TZ49]tFFF]`8'"]`S8J]`A&F!!*#3!s$$J!<0YF!56&G] tFCG]tFEZ]`>aZ!56&Grk/U<]tFEZ]`8&G!<'S2!<'S5!56&Grk/U<]tFEZ]`>aZ!<0Y3!<'S2! <'S2!<0Y@!56&G!56&G]tFEZ]`A&F!s$$J!.hiH]a0"[s5rIU!!*&ujoM4Vrk/C6]tFFF^&7s1] `8'3]`S8J]`A&F!!*#3rW!8aZ!<0\2!<'V2!!Kt8]tFFC]`8'1]`8'1^&A$1^&A$0] `8'3^&J*2]`8'"]`S8J]`A&F!!*#3!!*#3rW)o1rr!56&G]tFEZ]`A&FrW)o1rr_G!<0Y3!<0\2!<'V2!<0Y6! 56&Grk871rk/:3rk/C6]tFFF]`8'3^&A!<]`>_G]tFEZ]`A&FrW)o1rr<28!56&Gqn2t0r4N(1r 4W(0rOr11r4N(1rk8=3rOi12mC`T%]tFFF]`8'3]`8'3^&A$1^&J'>]`>aZ!56&G]tFFF^&A$1^ &J'7]`>_Gr4W%/rk/:3rk/:3rk8=3rOr11!PJL4]`8'1^&A!9]`>_G]`8'3]`8'3^&A$2]`8%`^ $!'7I%pZ'k.:Tns8M-]UAt,(!!(3U!!)l/!!(oi!!)B!!!&+o!!%S`Zb6TkUAsBurrA4qrr@V`Zb6TkUAsBu!0Y%q!.hiH]a0"[s5rIU!!*&ujoM4VJ \?WJJ\Aq6#CN9Gk2l[Dk5P5Y!<<&\!M]UF]n*kJ]tqAfI%pZ'k.:Tns8M-]UAoeXJ\?WJ_S$2%U AsBqs+13drs*qGs5rGDs5s=X! #'hn9!in%A]$bJ!fRiOoaZ!:mf'!8k Hi!:RT$!6`(R!9(Tn!56&Gj1YBkpUpP,kIgiqr4N(1n\"o&n\"o&lFm,rl+I&spq6Y-o">#'r4N (1pq6Y-n\#3UUAsB<])Vj2roO6Us7s>.!;F/,!:.;u!;=)+!;sM1!:mf'!8kHi!:[Z'!5/BV]`8 '2]`8&l]`8&k]`8'2]`8'-]`8&q^&J*2]`8&j]`8&u]`8'2]`8&j]`8'']`8'1]`8'-]`8'']a& qZs5rGDs5jIZaSPu;roO6Us7s>.!;F/,!:.;u!;=)+!;sM1!:mf'!8kHi!:[Z'!5/BV]`8'2]`8 &l]`8&k]`8'2]`8'-]`8&q^&J*2]`8&j]`8&u]`8'2]`8&j]`8'']`8'1]`8'-]`8'&]a0"[s5r IU!!*&ujoM4Vq7Qb.qRlt2]tFFF^&A$%]`8'.^&J'9]`>aZ!58@3o=Y,(qRuk.rk/:3rk/:3rk8 :2rk/:3rk/=4^&A$%]`J2I!<'S:!5/BG!5/BG^&A$2]`S8J!!)u2rr<)5!<0\2!:d`&!<'S9!56 &G]`>aZrW)r2!s$"7!<'V1!<0Y4!58=2!PJL4^&A$1^&J*&]`8'-^&A$2]`8'3^&A$2]`J2I!;! l*!5/C3]`8'3^&A$2]`8'3]`S8J]`A&Frr<)5!<0\2!<9b3!<9b3!:d`&!;aA2!5/@4rOr11rOr 11rk/:3rk8:2rk/:3o">#'r4N(1rk8:2rk/L9]tFEZ!!)f-#CN9Gk2l[DjocTPqZ-ZqjoM4Vq7Q b.qRlt2]tFFF^&A$%]`8'.^&J'9]`>aZ!58@3o=Y,(qRuk.rk/:3rk/:3rk8:2rk/:3rk/=4^&A $%]`J2I!<'S:!5/BG!5/BG^&A$2]`S8J!!)u2rr<)5!<0\2!:d`&!<'S9!56&G]`>aZrW)r2!s$ "7!<'V1!<0Y4!58=2!PJL4^&A$1^&J*&]`8'-^&A$2]`8'3^&A$2]`J2I!;!l*!5/C3]`8'3^&A $2]`8'3]`S8J]`A&Frr<)5!<0\2!<9b3!<9b3!:d`&!;aA2!5/@4rOr11rOr11rk/:3rk8:2rk/ :3o">#'r4N(1rk8:2rk/L9]tFEZ!!)c,#^iBHk2s8U!<<&\!M]Vi]`8'/]`nJM]`>aZ!<0Y3!:m f'!;aA9!56&G!56&G]tFF:]`8'0]`8'3]`S8J]`A&F!s$$J!<0Y6!56&Grk/C6]tFF9]`8'3]`8 '3^&J*4^&J*4]`8'3]b(7X]`8&G]`>aZ!56&G!56&Grk/:3o">#'rOiF9]tFCG]tFFF]a=bQ]`8 &G]`>aZ!<0Y@!56&G!56&G]tFEZ]`A&F"ou?M!56&Go">#'q7Qb.rk/L9]tFEZ]`A&F"9?-K!!) T'!W]n6rk/C6]tFFF]`S8J]`A&F%04)T!56&G]tFCG]tFFF]`nJM]`>aZ!<0Y3!:dc&!;sP1!<9 _7!56&Grk/C6]tFFF]`nJM]`>aZ!<0Y6!56&Go">#'r4N14]tFFF]a=bQ]`>aZ!!'^G!;X;5I%p Z'joGGDrqc]rs8M-]UAt&&!!)l/"ou?M!56&Grk/:3o">#'qRm49]tFCG]tFEZ]`@W:!!)o0!!* #3!s$$J!<0Y6!56&Grk/C6]tFFF]`S8J]`@T9!!*#3!!*#3rrE)4rrE)4!!*#3&HKMX!!'^G!56 &G]tFCG]tFFF]`8'']`8'2]a"PN]`8&G]`A&F$37cQ!!'^G!56&Grk/a@]tFCG]tFEZ]`>aZ!<0 Y9!56&G]tFF:]`8'.]`8'3]`nJM]`>aZ!<0Y7!56&G!:mf)!5/C3]`S8J]`A&F!s$$J!<0Y@!56 &G]tFEZ]`8&G]`A&F"ou?M!56&Grk/:3n\+r&r4W+1s1JL7]tFFF]`S8J]`A&F"ou?M!56&Grk/ C6]tFF:]`8'1]`S8J]`A&F$37cQ!56&G!56&Gpq6r\UAsB<])Vj2roO6Us7sA+!<0Y9!56&G]tF FF]`8''^&%g0]`8'3]`nJM]`>aZ!:mf'!;F//!56&Grk/C6]tFFF]`S8J]`A&F!s$$J!:d`&!<0 Y3!<0Y3!<0Y3!;aA2!56&Grk/C6]tFFF]`S8J]`A&F!!)T'quH`0!!*#3!!*#3!s$$J!<0Y6!56 &Grk/C6]tFFF]`nJM]`>aZ!<0Y6!56&Gn%A]$q7Qb.rk/L9]tFEZ]`A&F!s$$J!:d`,!56&G]tF FC]`S8J]`A&F"ou?M!56&Grk/:3qn316]tFEZ]`A&F!!)K$rrE&3!!*#3!s$$J!<0Y6!56&Gqn2 t0qn3(3]tFF:^%qa/]`8'3]`nJM]`>aZ!<0Y3!;X;5I%pZ'joGGDrqc]rs8M-]UAt&&quH`0"ou ?M!56&Grk/:3o"Fo#s1JC4rk/L9]tFEZ]`@W:!!)c,!s$$J!<0Y6!56&Grk/C6]tFFF]`S8J]`@ T9!!*#3!!*#3!!*#3!!)l/!s$$J!<0Y6!56&Grk/C6]tFFF]`8''^&.m0]`8'3]`8'3]`S8J]`A &F!s$$J!<0Y6!56&Grk/L9]tFEZ]`A&F!s$$J!:RT$!;X;.!<0Y9!56&G]tFFF]`S8J]`@T9"ou ?M!56&Gqn3(3]tFFF]`nJM]`>aZ!<0Y3!;jG6!56&G]tFFF]`8'$^&J*3]`8'3]`S8J]`A&F!s$ $J!;jG0!;jG3!56&Go"Fl"s1JC4rk/L9]tFEZ]`A&F!!)f-#^iBHk2s8U!<<&\!M]Vi]`8'/]`e DL]`>aZquH<$!!)l/!!*#3"ou?M!56&Go">#'qRuh-s1JL7]tFFF]`8'3]`S8J]`A&F!s$$J!:d c#!<0Y3!<0Y3!<'V0!<9_4!<0Y6!56&Grk/@5]tO=Do">#'qRlk/rk/:3rk/C6]tFFF]`J2I^&. m1]`8'3]`eDL]`>aZquH`0rrDT&!!)i.!!*#3"ou?M!56&Grk/C6]tFF9]`8'3]`J2I!<0\1!<0 Y5!5/C3]`S8J]`A&F!!*#3r;cl2!W]pIquH,t!s$$J!<0Y5!56)D!<9_4!;jG0!<0\1!<9_4!:m f'!;sM3!56)D!<9_7!56&Grk/:3q7R#\UAsB.!;aA4!56&G]tO=Do"> #'qRlk/rk/L9]tFEZ]`@W:!!)l/r;cl2!s$$J!<0Y3!<0Y6!56&Grk/C6]tFF9^&.m0]`8'3]`8 '2^&7s2]`8'3]`S8J]`A&F!W]pIquH<$!!)l/!!*#3!!*#3!s$$J!<0Y5!56)D!<9_4!<0Y8!56 &G]tO=Drk8=3n\"o&q7Qb.rk/L9]tFEZ]`A&F!s$$J!:d`&!<0Y5!5/C3^&7s1]`J2I!<0Y6!56 &Grk/:3rk871s1JI6]tO=DmC`T%]tFFF]`J2I^&.m1]`8'0]`8'3^&7s2]`8'']`8'1]`J2I^&. m1]`S8J]`A&F!!)f-#^iBHk2s8U!<<&\!M]Vi]`8'/]`nJM]`>aZ!:IN#!;aA/!<0Y9!56&G]tF F:]`8'0]`8'3]`8'3]`J2I!<0Y3!<0Y6!56&Grk/C6]tFF:]`8'1]`S8J]`A&F!!*#3!!*#3!s$ $J!<0Y6!56&Grk/C6]tFF6]`8'/]`8'3]`8'3]`S8J]`A&F!s$$J!;jG0!<0Y9!56&G]tFF@]`8 '']`8'.]`8'3]`nJM]`>aZ!<0Y6!56&Gn\"o&rk/I8]`>aZ!<0Y3!<0Y5!5/C3]`S8J]`A&F!s$ $J!<0Y9!56&G]tFF6]`8'2]`S8J]`A&F!s$$J!;jG0!;jG3!56&Grk/C6]tFF:]`8'1]`S8J]`@ rC!s$$J!<0Y3!;X;5I%pZ'joGGDrqc]rs8M-]UAt&&!!)l/"ou?M!56&Gm_&T#qRlk/rk/L9]tF EZ]`@W:!!)o0!!*#3!!*#3!W]n6rk/:3rk/C6]tFFF]`S8J]`@W:!!)r1!s$$J!<0Y3!<0Y3!<0 Y6!56&Grk/C6]tFFF]`S8J]`@K6!!)l/!!*#3!!*#3!s$$J!<0Y6!56&Gqn2t0rk/L9]tFEZ]`@ i@!!)T'!!)i.!!*#3"ou?M!56&Grk/C6]tFF9]`8'3]`eDL!56&Grk/:3rk/@5]`A&F!s$$J!<0 Y6!56&Grk/L9]tFEZ]`@K6!!)u2!s$$J!<0Y6!56&Gqn2t0qn3(3]tFFF]`S8J]`@W:!!)r1!s$ $J!;jG3!56&Grk/:3pq6r\UAsB<])Vj2roO6Us7s>.!;aA5!56&G]tFFF]`8'']`8'/]a=bQ]`8 &G]`>aZ!:mf'!;jG0!<0Y3!<0Y5!5/C3]`8'3]a=bQ]`>aZ!!'^G!:mf'!;sM4!56&Grk/:3rk/ :3rk/C6]tFFF]a=bQ]`>aZ!!'^G!<0Y3!:mf'!;aA/!<0Y3!<0Y=!56&G!56&G]tFFF]`S8J]`A &F"ou?M!56&Grk/L9]tFEZ]`@T9!!)u2!s$$J!<0Y9!56&G]tFFF]`S8J]`@T9!!)u2rrE)4!!* #3!!)u2!!)u2$37cQ!56&G!56&Grk/L9]tFEZ]`A&F!!)T'!!)u2$37cQ!!'^G!56&Grk/C6]tF FF]`nJM]`>aZ!<0Y6!56&Go">#'r4N14]tFFF]a=bQ]`>aZ!!'^G!;X;5I%pZ'joGGDrqc]rs8M -]UAt&&!!)l/"ou?M!56&Grk/:3o">#'qRm49]tFCG]tFEZ]`@W:!!)o0!!*#3!!*#3!W]n6rk/ :3rk/X=]tFEZ]`8&G]`@W:!!)r1!s$$J!<0Y3!<0Y3!<0Y6!56&Grk/X=]tFEZ]`8&G]`A&F!!) T'!!)l/!!*#3!!*#3$37cQ!!'^G!56&Grk/C6]tFFF]`nJM]`>aZ!<0Y9!56&G]tFF9]`8'2]`S 8J]`A&F"ou?M!56&Grk/C6]tFF9]`8'2^&J*4]`8'3]`8'2]`8'2]a=bQ]`>aZ!!'^G!<0Y9!56 &G]tFFF]`8'']`8'2]a=bQ]`8&G]`>aZ!<0Y6!56&Grk/L9]tFEZ]`A&F!s$$J!:mf'!;sM4!56 &Grk/X=]tFEZ]`8&G]`@i@#^iBHk2s8U!<<&\!M]Vi]`8'/]`S8J]`A&FrW)K%qZ-W/rr<>aZ!!)W(!!)r1!s$$J!<0Y3!<'V1!!Bn7]`A &F!!*#3rr<)5!<0\2!:d`&!;aA/!<'V1!<0Y6!5/@4rOr11rk/:3rk8=3!PJL4^&A$1^&J*$^&7 s0^&A$2]`8'3^&A$2]`8'&]`8'1]`8'3^&A!4]`A&F!!)u2!!*#3rr<)5!<0\2!!^+:]`8&G^&A $$^&7s1]`S8J!!)u2rW)o1rW)r2!!*#3rW!&6!5/C']`8'1]`8'3^&A$2]`nJM]`>_G!;O54I%p Z'joGGDrqc]rs8M-]UAt&&!!)l/!s$$J!<0\2!:dc"!<0\3!!p7<]tFEZ]`8'(^&.m0^&A!4]`A &F!!)r1rW)o1rr<59!56&G!;!l(!;sM4!56&Grk/:3rOr11"2+]J!<0Y3!<0\3!!0b5rk8:2n\" o&qRlk/rOr11rk/C6]`8'2^&A$2]`8'3^&J'5]`A&FrW)o1rrDN$r;cf0rW)r2!!*#3rW)r2!!) Q&!!)r1!!*#3rVuu4!<0Y3!<'S2!<0\3!!0b5rk8:2#/(#M!!'^GrW)H$r;ci1!s$"7!<'V1!<' V1!<0Y3!<0\2!!Bn7]`@W:!!)r1!!*#3rW)r2"ou?M!5/@4pUpi[UAsB<])Vj2roO6Us/!C/!5, uF!8+sb!/J5f!85$c!5Q8J!;4#1I%pZ'joGGDrqc]rs8M-]UAq('!!'[F!!(Zb!!%ef!!(]c!!' gJ!!)Z)#^iBHk2s8U!<<&\!M]Uk]`8&I]`8'3]`8&b]`8%j]`8'3]`8&c]`8&J]`8'*]a&qZs5r GDs5s=X!$lJUE#r^jH?\s5rGDs5jG+@f$0*roO3TJUE#rJUG 4[#GV7\k.:Tns8M-\U4N>qs+144rr@H&!!g33s5rGDs5s=X!-F!<9 _6HiSQOrs-63s5rGDs5jG&J,96GroO6Us7X,+!;aD/!.qoa!!0b5`4Z-Nf=_.alFm/ss1SC3s1J C4rk/=4^&7re]`8'1^#8tk^#;Zb]`NQ]I,=l/]qYPhk.:Tns8M-]UAsr#!!)l/!W]n6K>%9b!PJ KO]`8&b]`J2I!:7B!!<'S2!<0Y5!5/C3]`J2I!<0Y3!8tQj!85'E!<9_6HiSQOrs-63s5rGDs5s =X!_Gg:[Of]`@E4rW)u3!!*#3!W]n6rk/@5]`A&F!!)#lrrDi-!!)u2!!* #3r;ci1!!)u2!W]pIqZ-W/i;ink!djuqhuK!5/Bd]`J2I!:7Du!<9_4!<0Y5!5/C3]`J2I!<0Y3!91 ]l!;X=e!<9ak9`Md-HiSQNrs6<4s5rIU!!*&ujoM4Vp:UG+qRlk/rk/:3be=#V!PJKI^&J'5]`? $brW(Wb!W]n6l+I,u]`A&F!W]n6rk/@5]`A&F!!)&m!!)`+!!)u2!s$$J!<'S5!56&GrOi:5]tF FA^#8tk]`NQ]I,Fr/]qYPhjoGGDrqc]rs8M-]UAsr#!!)l/!!*#3!!(6Vrr<)5!5?/H!!0b5jh: Zor4W+1r4W+1n\+o%ft@Fe]`@<1!W]n6rk/@5]`A&F!W]n6rk/:3j1PEmpV#Mcs1RAbs1JJ]!.< Z'#ecu4k2s8U!<<&\!M]Vf]`8'/^&%fU^&J*4^&A#H^&J'5]`@$)rW)u3rW)?!rW(Zc!!*#3!!) ;t!W]n6rk/@5]`A&F!W]n6rk/:3jh:ZootCA*rk/C6]tFFE]`\>K]`8'3]`S8J]`@lAi;ink!dj uqhu)rk8 :2s1SC3!keTIr;bunrrDZ(rrE&3!s$$J!<'S6!56&G!<0Y6!56&Gq7Y_es1JJ]!.<](#JHl3k2l [Dk5P5Y!<<&\!M]Vf]`8'*]`8&Z]`8'3]`\>K!5/BJ^&J'5]`@-,rrE&3r;ci1rrDN$!!(ukq#L ?+q#L*$rW)r2rW)u3rW!#5!58=2k.UcpoY'2`s1RAbs1JJ]!._G]tFEZ]`@lAi;ink!djuqhuaZ!<'SaZ!56)C!<0 [j!<9_6HiSQOrs-63s5rGDs5s=X!*jh:Zon%A]$qn2t0r4W+1rOr11n%J `$qn3(3]`8&t^&J'5]`@-,rrE)4rrE)4rrE)4rrD/orrD;s!!)Z)!!)Z)k5ak^rrDT&i;inkiCs 9b!djuqhZ!kpUAsB<])Vj2roO6Us7X,+!;4#*!9Cfn!:[Z%!;aA/!;jG0!<'S2!:7B!!;sM1!<0 Y3!:%8t!!0b5i4T9o]`8&G!91Zo!56&Gl+I&sp:UG+`kDBPm_&l+]tFEZ!56&GrOiR=]tFEZ]`> _G]tFFA^#8tk]`NQ]I,Fr/]qYPhjoGGDrqc]rs8M-]UAsr#!!)]*!!))n!!)N%!!)l/!!)o0!!) u2!!)B!!!)r1!!*#3!!);trr<)5!9Cin!<9b4!<9b4!<9b4!9Urs!56&Gl+I&sp:UG+`kDBPn%I Z[s1RAbs1JJ]!._G]tFFE]aFhR]`>aZ!5/BG]`@lAi;ink!djuqhuK!5/ C2]`8'3^&J'5]`@K6!!)u2!!)u2!!);trr<)5!9:cm!"$==!56&G!5/@4m_&T#q7Qk1]tFF/]`8 '/]`8&Q^&J*!^#8tk^#;Zb]`NQ]I,=l/]qYPhk.:Tns8M-]UAsr#!!)]*!!)>urW)o1!!)Q&!!) l/rW)l0!!*#3!s$$J!:IN#!<'S2!<'S2!:%8t!!0b5hn9-m]tFCGm(NAuqRlt2]tFF/]`8'3]`8 '3]`8&S^&J)s]`8'3^&J*4]`8'2]`S8J]`A&FrrE)4!!)i.i;ink!djuqhuurW)o1!!)Q&!!)l/rW)l0!!*#3!s$$J!:IN#!<'S2!<'S2!:%8t!!0 b5j1YHm!PJL3]`S8J!!)K$rW)f.!s$$J!9_#q!<0Y3!<0Y3!6MqS!:%8V!<9ak9`Md-HiSQNrs6 <4s5rIU!!*&ujoM4Vp:UG+ot:>*m(NE!"MFd8]tOCFo">#'q7Qb.r4W(0rk8=3m_/T"s1JC4rOr 11lb3;u_nH$Lq7Ze.kIgiqrk/@5]`A&F!!(3U!!)2q!!)u2!s$$J!<'S5!56&GrOi:5]tFFA^#8 tk]`NQ]I,Fr/]qYPhjoGGD"K2n/!<<&\!M]Vf]`8'*]`8'!^&J'8]`8&G^&A$&]`8'.]`8'1^&A $2^&J*#^&A$3]`8'2^&A#t^&J)j^&A$1^&A$"^&A$-^&J)q]`8'3]`J2I!<0Y3!6`%U!9h,T!<9 ak9`Md-HiSQNrs6<4s5rIU!!*&ujoM4Vp:UG+ot:>*e%G_]q7Qb.^:j4?c+O5[]`>_GhRs!k]`8 '3^&J'5]`?Yjh9UQs1RAbs1JJ]!.gQ/!W]n6qRlk/qRu_*`Ou6Oqn3%2]`@*+rr<&4quG$UqZ,Zi"TZ49]tFEE^#8 th]`8'3]`8'3]`8'3]`J2I^&A$3]`8'3]`8'0]`NQ]I,Fr/]qYPhjoGGDrqc]rs8M-]UAt2*!)3 C*"&-DA9`D^,9YJ.99`Md-9YF-r]`8'/^%q`J]`8'0]`J2I!9:cm!!'_1!7&:T!9:`r!5/BG]`> "Ei;ieh!!*#3!!*#3!!*#3!W]pIrW)u3!!*#3!!)o0!djuqhZ!kpUAsB<])Vj2roO6Us8BV2!<0 \1!<0Y6!56&Gpq6Y-q7Qb.qRlk/r4N(1`Ou6Oqn3(3]tFF,^&J'5]`=qCrW)o1!!'%4i;ink!!* #3!!*#3!!*#3!!*#3rr<)5!<0\3!<0Y3!;sM3HiSQOrs-63s5rGDs5s=X!d[rrClgrrC]bq#K ruq#LH.!!*#3!!*#3rW)o1!!)l/rrE&3!!)r1!djuqhZ!kpUAsB<])Vj2roO6Us6mW$!9Lm$!5/ BG!5/BG!56)@!;*r)!<0Y3!<0Y6!56&GmC`K"pUp\0]`>_Gl+R)s!PJKp]`8'0]`J2I!:[\f!:[ Z%!;F2,!;!ne!:IQ#!:RVs!:dbu!<0Y3!<0Y6!5/@4r4N(1qRlt2]tFFF]`8'2]`NQ]I,Fr/]qY PhjoGGD">Vq5!<<&\!M]V_]`:af]a=bQ!5/BG!5/BG^%_U"]`8'3]`8'3]`S8J]`@H5!!)c,"9? +8]`@<1rr<)5!9:`p!56&GrOi12n\+5gn@\f%pV$S,o=a;em_/W#n%JMsn\+_urk/:3rk/C6]`8 '1]`8'/]`S8J]`A&F!!)u2!djuqhZ!kpUAsB<])Vj2roO6Us6mYt!8tNj!;aA/!;F2*!<0Y3!<0 Y6!56&GmC`K"pUp\0]`>_Gl+R)s!PJKp]`8'0]`J2I!5?/H!8Y?g!;=,&!<'S2!<'V,!;jJ*!:d bu!<'S6!56&G!;jG0!;aA/!<0\3!<0Y3!<0Y5HiSQOrs-63s5rGDs5s=X!K!5/Bs^&J'5]`@*+!s$$J!<'S2!5H5I!8Y?g!;= ,&!<'S2!<'V,!;jJ*!:dbu!<'S6!56&G!;jG0!;aA/!<0\3!<0Y3!<0Y5HiSQNrs6<4s5rIU!!* &ujoM4Vqn2t0lb*8un@\f%qRlt2]tFFB]`8'-]`8'3]`8'3]`8'3]`S8J]`@H5!!)c,"9?+8]`@ <1rr<)5!9Llo!;sM4!56&Ga1VHQqRlt2]tFF(^&J)s]`8'$^%hZu^%h[+^&J*/]`8'/]`8'2]`J 2I!;jG2HiSQOrs-63s5rGDs5jIR]))L-roO6Us80J09^B@l9^o^q!;aA2!56&GqRlk/pq6Y-rk/ :3rk/:3rk/C6]tFF5]`8',]`\>K!5/Bs^&J'5]`@-,!!*#3!!)u2!!(*R!!)l/!s$$J!8tQj!9q /s!:RVs!:dbu!;sP1!;aA/!;aA/!<'S4!5/C0]`NQ]I,=l/]qYPhk.:Tns8M-]UAt/)!W]pIqZ$ W0quH`0r;ci1!!)/p!!)l/!!)c,qu?`1quH]/r;cB$!!)c,"9?+8]`@<1rr<)5!9Llo!<'S2!<0 Y3!:[\t!8+se!56&Gik>?lkIgiqn%JMsn\+_us1JL7]`8'/]`8'/]`8'0]`J2I!;sM3HiSQOrs- 63s5rGDs5jG$GP_C?roO6Us89P39YJ.:9E;d(9`Da(9`D^*9]j"g!;aA/!;F2)!!'_1!<'V0!:d `&!;F/0!5/BG!9q2s!!0b5jh1WorOi12rOi12n\+_ufY%@e]tFF*^&J)q]`8'$^%hZu^%h[.]`S 8J!!)l/!!)l/!!)o0!W]n6r4N/Z!._Gl+R)s!PJKp]`8'2^&%fL]`8'2^&%fj]`8 &o]`8'$^%hZu^%h[-]`J2I^&7s2]`8'/]`8'/]`S8J]`A#E!djuqhu]`>_G]`> aZp]/aU!!)c,!W]n6l+R)s!PJKr^&.m.^&A$%^%26^^&J*2^&J)?^#8th]`8'3]`8'3^&%g+]`S 8J]`@rC!djuqhu_Grk/A\!.<](#JHl3k2l[Dk5P5Y!<<&\!M]Vl]`Lm@^&( J(]hJ:9rCm4(!)2dno`34Lo`40grr@V`a1^F3rOi12rk/:3rk/:3rk/:3rk/:3rk840"2+]J!<0 Y5HiSQNrs6<4s5rIU!!*&ujoM4Vqn2t0lb*8uj1YHmJ\?WJl+Q$Ur4N(1rk/:3rk/:3rk/:3rk/ :3rk/:3rk8=3r4N/Z!.<](#JHl3k2l[Dk5P5Y!<<&\!M]Vk]`:al]`:ad^&J(`]n*l]^#8th]`8 '3]`8'3]`8'3]`8'3]`8'3]`8'3^&J*1]`NQ]I,=l/]qYPhk.:Tns8M-]UAoeXJ\?WJkIgqE!.< ](#JHl3k2l[Dk5P5Y!<<&\!M]UF]n*kJ^$!'1HiSQNrs6<4s5rIU!!*&ujoM4VJ\?WJJ\C6[!IO n(rs-63s5rGDs5s=X!gC!;O5-!:%6!s*Oh5rr<% Nrr<%Nrr<%[rrKh5o=YEW!2BMUjoGGD"OHuB!<<&\"/>gC!;O5-!:%6!s*Oh5rr<%Nrr<%Nrr<% ZrrKh5o=YHX!2BMUk.:Tns8M-_UAoT@pq?\-lb*B"HiWO5!!%WN!!%WN!!&)[!PSO)]a/ucUAsB gC!;O8+!:@H $s*Oh5rr<%Nrr<%Nrr<%ZrrKh5o=YHX!2BMUk.:Tns8M-_UAoT@pq?P)n%Af&HiWO5!!%WN!!%W N!!&)[!PSO1]`8'/]a/ucUAsBg#u!rmWJm/I%crr;uuL]7JWs8N'!LAq5Rrr;u uPlCcts89S0!;jG8HiTo@k2l[Dk5P5Y!<<&\"/>gC!;O8(!:[Z's*Oh5rr<&us8N(Srr`?%rr<% Rrr<&us8N(_rrKh5r4W(0qn3;`!2BMUk.:Tns8M-_UAoT@pq?G&o">,)HiWO5"p"]'!<<'!M#RG Trr2ruLAqGXs8N*!rrA>a!PSO3^&.m.]a/ucUAsB#ot:G,HiWO5"p"]'!<<'!M#RGTrr2ruLAq5RrVlitPlCcts7gC!;O8#!;4#,s*Oh5rrrK'rrE*!!/UXT!<2uu!/CLR!<)ot!0dE`^&R];$%)` Is5rIU!!*&ujo_@XHiWrTqZ-)u!rmWJm/I7is8N*!rrC.?!!'n9!!*#u!!(%=!!'n9!!*#u!!(% =!!(@F!PSO)]a/ucUAsB!!'n9!W`9#rW("=!!'n9!W`9#r;aq=!!(@F!PSO)]a/ucUAsB*>!5ea;!<<)u!6>*>!5ea;!<<)t!6G0?!7(TF^&R] ;$%)`Is5rIU!!*&ujo_@XHiWrTr;cl2rrDT&!rmWJm/I%c_Z'T9_Z'T9_Z'T9_Z'T9_Z'T9ci4$ Zs7gC!;O8+!<9b4!:d`(s*Oh5rr<&9rr<&9rr<&9rr<&9rr<& 9rr<&ErrKh5o=YHX!2BMUk.:Tns8M-_UAoT@pq?Y,rOi12n\##(HiWO5!!'n9!!'n9!!'n9!!'n 9!!'n9!!(@F!PSO)]a/ucUAsBgC!;O8-!;sP1!:mf)s*Oh5rr<&Yrr<&Yrr<&Yrr<&Yrr<&Yrr<&Yrr<&Yrr<&Yrr<& Yrr<&Yrr<&Yrr<&errBb&HjB_Hs5rIU!!*&ujo_@XHiWrT!!)l/rrDZ(!rmWJm/I%cir8uYir8u Yir8uYir8uYir8uYir8uYir8uYir8uYir8uYir8uYir8uYn,MhV#,;.[joGGD"ELIg C!;O5-!;aD/!;!l*s*Oh5rr<&Yrr<&Yrr<&Yrr<&Yrr<&Yrr<&Yrr<&Yrr<&Yrr<&Yrr<&Yrr<& Yrr<&es6fpmUAsB<])Vj2roO+HiWO5!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)T i!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)Ti!!)T i!!)Ti!!*#u!57t'$%)`Is5rIU!!*&ujo_@XHiWTJrrD`*!rmWJm/I%co)A[io)A[io)A[io)A[ io)A[io)A[io)A[io)A[io)A[io)A[io)A[io)A[io)A[io)A[io)A[io)A[io)A[io)A[io)A[ io)A[io)A[io)A[io)Agms8Te4o=YEW!2BMUjoGGD"OHuB!<<&\"/>gC!:IQ#!;4#,s*Oh5rr<& irr<&irr<&irr<&irr<&irr<&irr<&irr<&irr<&irr<&irr<&irr<&irr<&irr<&irr<&irr<& irr<&irr<&irr<&irr<&irr<&irr<&irr<&irr<&urrKh5o=YHX!2BMUk.:Tns8M-_UAoT@mC`K "ot:G,HiWO5JH16$NW9*ns7gC!:@H"!;4#,s*Oh5s+(0$!0$s Z^&R];$%)`Is5rIU!!*&ujo_@XHiW*g C!8tNks*X)3qYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpN qqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpN qqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpN qqYpNqqYpNqqYpNqrr3#4s75bLHiWR6!!%TMJcC`0!PSO)]a9&dUAsB <])Vj2roO6Us4t?hHiWR6!!%TMJcCc1!PSO)]a/ucUAsB[joM4Vn@ei%n@\jM!:Bd d!.k0$s,I$Z^&R];$%)`Is5rIU!!*&ujoM4Vn@ei%n@\jM!:Tsd!5ea9!5ea9!5ea9!5ea9!5ea 9!71ZG^&R];#^cWHs5rGDs5s=X!'O!:Bdd !.k0$s,R*[^&R];#^cWHs5rGDs5s=X!'O!:Bdd!.k0$s,I$Z^&R];$%)`I s5rIU!!*&ujoM4Vh7Wi:!:Bgd!5ea9!5ea9!5ea9!5ea9!5ea9!71ZG^&R];#^cWHs5rGDs5s=X !s8M-]UAt)'lN$dp!IOn7rr<%Ms+130rrKh5o=YHX!2BMUk.:Tns8M-]UAt)'!!)E"!!)l/ !IOn7rr<%Ms+131rrKh5o=YEW!2BMUjoGGDrqc]rs8M-]UAt)'!!)E"!!)l/!IOn7rr<%Ms+130 rrKh5o=YHX!2BMUk.:Tns8M-]UAt)'!!)E"!!)l/!IOn'O!:Bdd!.k0$s,R*[ ^&R];#^cWHs5rGDs5s=X!'O!:Bdd!.k0$s,I$Z^&R];$%)`Is5rIU !!*&ujoM4VpUpP,rk8=3r4W+1oXt9Q!:Bgd!5ea9!5ea9!5ea9!5ea9!5ea9!71ZG^&R];#^cWH s5rGDs5s=X!*p:UG+p:UKS!:Bdd!.k0$s,I$p^&PeG^&PeG^&PeG^&PeG]qYPhjoGGDrqc]rs8M-] UAso"!!)`+!!)`+!IOn7rr<%Ms+13/rtrHL^&PeG^&PeG^&PeG^&Pd?s5rIU!!*&ujoM4VotCA* pq?\-!PJL.]`EK\mJd.dJcC<$NrKs0s1SHGs1SHGs1SHGs1SHGs.]PUjoGGDrqc]rs8M-]UAso" rrDi-rr<)5!;O5.HiWR6!!%TMJcC`0)86'`s1SHGs1SHGs1SHGs1SH,s5rIU!!*&ujoM4Vo=b/( r4W+1rk/:3pq6]U!:Bdd!.k0$s,I$p^&PeG^&PeG^&PeG^&PeG]qYPhjoGGDrqc]rs8M-]UAshu rrDu1rrE&3!!)f-!IOn7rr<%Ms+13/rtrHL^&PeG^&PeG^&PeG^&Pd?s5rIU!!*&ujoM4Vn\+i# rk840qRloW!:Bdd!.k0$s,R*r^&PeG^&PeG^&PeG^&PeG^&Oi,k2l[Dk5P5Y!<<&\!M]Va^&.m0 ^&.m,]`EK\mJd.dJcC<$NW0m0s1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAsDi!!)f-!IOn7 rr<%Ms+130rtiBK^&PeG^&PeG^&PeG^&Pd?s5rGDs5s=X!*p:UG+p:UKS!:Bdd!.k0$s,?sp^&PeG^&PeG^&PeG^&PeG]qYPhk.:Tns8M-]UAsr# !!)Z)!!)c,!IOn7rr<%Ms+131rtrHL^&PeG^&PeG^&PeG^&PeGUAsBUF7rr2ss8O);rr=&s8O);rr=&s8O);rr=&*<6$YrVlj;rr2ss8M-]UAsbsquH`0quHT,!IOn7rr<&Xs8Eube9r#C:f`;^^g s1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAsDi!!)f-!IOn7rr<%Ms+130rtiBK^&PeG^&PeG ^&PeG^&Pd?s5rGDs5s=X!eD4!!'n9!!'n9!!'n9!!'n9!!(=E )86'`s1SHGs1SHGs1SHGs1SH,s5rIU!!*&ujoM4Vh7Wi:!:Bdd!.k0$s,I$p^&PeG^&PeG^&PeG ^&PeG]qYPhjoGGDrqc]rs8M-]UAs&_!IOn7rr<%Ms+13/rtrHL^&PeG^&PeG^&PeG^&Pd?s5rIU !!*&ujoM4Vh7Wi:!:Bdd!.t7G*.e-UrtrHL^&PeG^&PeG^&PeG^&PeGUAsB!IOn7rr<%Ms+13/ rtrHL^&PeG^&PeG^&PeG^&Pd?s5rIU!!*&ujoM4VotCA*q7Z\+pq6]U!:Bgd!5ea9!5ea9!5ea9 !5ea9!5ea9!71Z^^&PeG^&PeG^&PeG^&PeG^&Oi,k2l[Dk5P5Y!<<&\!M]Ve^&J*.^&.m*]`EK\ mJm1d_Z'T9_Z'T9_Z'T9_Z'T9_Z'T9cMncqs1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAso" !!)`+!!)`+!IOn7rr<%Ms+130rtiBK^&PeG^&PeG^&PeG^&Pd?s5rGDs5jGV!hTJmroO6Us7O&* !;=)+!;=),HiWR6!!%TMJcC]/(qos_s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]Vf]`8'*^&J*, ]`EK\mJd.dJcC<$NrKs0s1SHGs1SHGs1SHGs1SHGs.]PUjoGGD"P?6A!<<&\!M]Vf]`8'*^&J*, ]`EK\mJd.dJcC<$NW0m0s1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAsr#!!)Z)!!)c,!IOn7 rr<%Ms+130rtiBK^&PeG^&PeG^&PeG^&Pd?s5rGDs5jH)W;?SproO6Us7X,+!;*r)!;F/-HiWR6 !!%TMJcC]/(qos_s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]Vg]`8'']`8'-]`EK\mJd.dJcC<$ NrKs0s1SHGs1SHGs1SHGs1SHGs.]PUjoGGD"=O!A!<<&\!M]Vg]`8'']`8'-]`EK\mJd.dJcC<$ NW0m0s1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAsu$!!)T'!!)f-!IOn7rr<%Ms+130rtiBK ^&PeG^&PeG^&PeG^&Pd?s5rGDG?+i]qtgBnroO6Us7a2,!:mf'!;O5.HiWR6!!%TMJcC]/(qos_ s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]Vg]`8'']`8'-]`EK\mJd.dJcC<$NrKs0s1SHGs1SHG s1SHGs1SHGs.]PUjoCpA"OHuB!<<&\!M]Vg]`8'']`8'-]`EK\mJd.dJcC<$NW0m0s1SHGs1SHG s1SHGs1SHGs.]PUk.:Tns8M-]UAsu$!!)T'!!)f-!IOn7rr<&9s,6r/s2"^O^&PeG^&PeG^&PeG ^&PeG]qYPhjoCoqrqc]rs8M-]UAsu$!!)T'!!)f-!IOn7rr<&9s,6r/s1nXO^&PeG^&PeG^&PeG ^&PeG]qYPhk.:Tns8M-]UAsu$!!)T'!!)f-!IOn9s8;r8rr<%Zrr<&lrr<&9rr<&9rr<&FrtrHL ^&PeG^&PeG^&PeG^&PeGUAsB*pUpTT !:Bdd!5ea9!07'Z!.k0ertrHL^&PeG^&PeG^&PeG^&PeGUAsBbCds1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAso"!!)`+ !!)`+!IOn7rr<&9rr<%Zrr<%Ms2"^O^&PeG^&PeG^&PeG^&PeG]qYPhjoCoqrqc]rs8M-]UAso" !!)`+!!)`+!IOn7rr<&9rr<%Zrr<%Ms1nXO^&PeG^&PeG^&PeG^&PeG]qYPhk.:Tns8M-]UAsu$ quHQ+rrDc+!IOn7rr<&9rr<%Zrr<%Ms2+dQ^&PeG^&PeG^&PeG^&PeG^&Oi,k2lZ6GQ.I?!<<&\ !M]Vg^&.m+^&J*+]`EK\mJd.d_Z'T9NrK(ZJcERd)86'`s1SHGs1SHGs1SHGs1SH,s5rIU!!*&u joM4Vot:G-]`8'1^&J*)]`EK\mJd.d_Z'T9NrK(ZJcEpn!!)fo(VTj^s1SHGs1SHGs1SHGs1P0, k2lZ6GQ.I?!<<&\!M]Ve]`S8J!!)r1rrD])!IOn7rr<&9rr<%Zrr<%Ms3(EB!;HL1^&PeG^&PeG ^&PeG^&PeG]qYPhk.:Tns8M-]UAso"!!*#3quH<$!IOn7rr<&9rr<%Zrr<%Ms2+dQ^&PeG^&PeG ^&PeG^&PeG^&Oi,k2lZ6GQ.I?!<<&\!M]Ve]`8'3^&.m$]`EK\mJd.d_Z'T9NrK(ZJcERd)86'` s1SHGs1SHGs1SHGs1SH,s5rIU!!*&ujoM4Vh7Wi:!:Bdd!5ea9!6G3?]#jsP!.k1#s8E#us8E!" rr<&ts8N';rrE)4s1SHGs1SHGs1SHGs1SHGUAsBP!!%TMec5UKs8W&u!ri6#rVult*<-!=s1SHGs1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]VM ]`EK\mJm1d_uB]:aSu:Ps8KURrr<&lrr<&9rr<&9rr<&XrriE&!<<'!rr2rur;Zcs)?7DM^&PeG ^&PeG^&PeG^&PeGUAsBbCds1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAt,( !!))n!IOn7rr<&9rr<&?rrBXrs8KUgrr<%Ms2"^O^&PeG^&PeG^&PeG^&PeG]qYPhk.:V`s"XY- !<<&\!M]Vk]`8&n]`EK\mJd.d_Z'T9aSu7Oli6sqiVrlXJcEOc(qos_s1SHGs1SHGs1SHGs1P0, k2s8U!<<&\!M]Vk]`8&n]`EK\rr;BdqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqu6Wrrr:-P kl:XnjSo2[rVlitqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNq qYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYqK7s8Te4^&PeG^&PeG^&PeG ^&PeGUAsB<])Vj1qZ-]sroO6Us80J0!9CfoHiX0GmK!+`!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq !!)or!!*#ub.?g:rjq1j!!)ut!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq !!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!*#u)86'` s1SHGs1SHGs1SHGs1SH,s5rIU!!*&ujoM4Vqn2t0m_/W#q7QfV!:Bdd!5ea9!<2uu]!)/5]''(n !.k0drtiBK^&PeG^&PeG^&PeG^&Pd?s5rIU!<<&q!jK7h>dDarr2rurVll/q#:?*JcF-t(qos_s1SHGs1SHGs1SHGs1SH,s5rIU!<32S8,E;droO6U s7s>.!;4#*!;jG0!;aA0HiX0G!!)Qh!!'n9!!*#u!4p#HrW(dSr4;n-!!)ut!4qt*!4ma]d/Ous s1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAt&&!!)Z)rrDu1!!)o0"+1+Ks8E#hrr<&9rr<&u rrBX$s7a)*rrE&u!4qn(!4ma]dJk#rs1SHGs1SHGs1SHGs1SHGUAsB<])_j6EiAj8s8M-]UAt&& !!)Z)rrDu1!!)o0"+1+Ks8E#hrr<&9rr<&urrBX$s7a)*rrE&u!4qn(!4ma]d/Orrs1SHGs1SHG s1SHGs1SHGUAsB<])Vj2roO6Us7s>.!;X>(!<'S2!;jG1HiWR6!!'n9!!*#u!4nj'p:C8'!!*#u !4qn(!4ma]df1/ts1SHGs1SHGs1SHGs1SHGs.]PUk.:Wn"=O!A!<<&\!M]Vi]`8'.^%h[,]`8'0 ]`EK\mJd.d_Z'T9rr2u0T`=_srr2rurr2u0pAY-(JcF-t)86'`s1SHGs1SHGs1SHGs1SH,s5rIU !!*&ujoM4Vq7ZP'ot:>*qn3#X!:Bdd!5ea9!<2uu\tfbCds1SHGs1SHGs1SHGs1SHGs.]PU k.:Tns8M-]UAs&_!IOn7rr<&9rr<&?rrBY#s7X%arr<%Ms2"^O^&PeG^&PeG^&PeG^&PeG]qYPh k.:Wnrqc]rs8M-]UAs&_!IOn7rr<&9rr<&?rrBY#s7X%arr<%Ms1nXO^&PeG^&PeG^&PeG^&PeG ]qYPhk.:Tns8M-]UAs&_!IOn7rr<&9rr<&?rrBY&s7X%^rr<%Ms2+dQ^&PeG^&PeG^&PeG^&PeG ^&Oi,k2s8Us8Mlr!<<&\!M]VM]`EK\mJd.d_Z'T9aSu7Oo`+Wri;WcWJcERd)86'`s1SHGs1SHG s1SHGs1SH,s5rIU!!*&ujoM4Vh7Wi:!:Bdd!5ea9!6G0?](c6u]&!Ad!.k0drtiBK^&PeG^&PeG ^&PeG^&Pd?s5rIU!<<&q!!l_Z'T9_Z'T9cMncqs1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAsr# !W]pIquH6"!IOn7rr<&9rr<&?rrBY/s7X%Urr<%Ms2"^O^&PeG^&PeG^&PeG^&PeG]qYPhk.:Wn rqc]rs8M-]UAsr#!W]pIquH6"!IOn7rr<&9rr<&?rrBY/s7X%Urr<%Ms1nXO^&PeG^&PeG^&PeG ^&PeG]qYPhk.:Tns8M-]UAsu$!!)i.r;cK'!IOn7rr<&9rr<&?rrK_2p:AcR!!%TM_Z(Ids1SHG s1SHGs1SHGs1SHGs.]PUk.:Wnrqc]rs8M-]UAsu$!!)i.r;cK'!IOn7rr<&9rr<&?rrK_2p:AcR !!%TM_>bCds1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAsu$!!)]*quHQ+!IOn7rr<&9rr<&? s7a+Prr<%Ms2"^O^&PeG^&PeG^&PeG^&PeG]qYPhk.:Wnrqc]rs8M-]UAsu$!!)]*quHQ+!IOn7 rr<&9rr<&?s7a+Prr<%Ms1nXO^&PeG^&PeG^&PeG^&PeG]qYPhk.:Tns8M-]UAt#%!!)K$rW)l0 !IOn7rr<&9rr<&=s89IRrr<%Ms2+dQ^&PeG^&PeG^&PeG^&PeG^&Oi,k2s8Us8Mlr!<<&\!M]Vh ]`8'$^&A$0]`EK\mJd.d_Z'T9`rGtJcMmkEJcERd)86'`s1SHGs1SHGs1SHGs1SH,s5rIU!!*&u joM4Vpq6Y-o"Fu%qRloW!:Bdd!5ea9!65'=]$(*R!.k0drtiBK^&PeG^&PeG^&PeG^&Pd?s5rIU !<33!5PkH\roO6Us7j8-!:mi%!;aA0HiWR6!!'n9!!(%=s16DR!!%TM_#G7bs1SHGs1SHGs1SHG s1SHGUAsB<])Vj2roO6Us7s>.!;*u(!;=),HiWR6!!'n9!!&&Z!!%TM_Z(Ids1SHGs1SHGs1SHG s1SHGs.]PUk.:Wn"T'tO!<<&\!M]Vi]`8')^&A$*]`EK\mJd.d_Z'T9NrK(ZJcERd)86'`s1SHG s1SHGs1SHGs1SH,s5rIU!!*&ujoM4Vq7Qb.pq?V+o=Y0P!:Bdd!5ea9!07'Z!.k0drtiBK^&PeG ^&PeG^&PeG^&Pd?s5rIU!<30D!rDutroO6Us7s>.!;O8+!;!l)HiWR6!!'n9!!&&Z!!%TM_#G7b s1SHGs1SHGs1SHGs1SHGUAsB<])Vj2roO6Us8'D/!;X>.!:RT%HiWa;q>eG5!!&&Z!!)]l!!'n9 !!'n9!!(@F(qos_s1SHGs1SHGs1SHGs1SH,s5rIU!<<&q!b=bs1SHGs1SHGs1SHGs1SHGUAsB<])_m1qZ-]s roO6Us80J0!:mi'!;4#+HiWR6!!'n9Mu\G/_#G7bs1SHGs1SHGs1SHGs1SHGUAsB<])Vj2roO6U s89P1!:RW$!;F/-HiWR6!!%TMJcCc1(qos_s1SHGs1SHGs1SHGs1SH,s5rIU!<<&q![n ]`EK\mJd.dJcC<$NW0g.s1SHGs1SHGs1SHGs1SHGUAsB<])_m1qZ-]sroO6Us89Rr!;O5.HiWR6 !!%TMJcC]/(qos_s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]VM]`EK\mJd.dJcC<$NrKs0s1SHG s1SHGs1SHGs1SHGs.]PUk.:Wnrqc]rs8M-]UAs&_!IOn7rr<%Ms+130ru&NM^&PeG^&PeG^&PeG ^&PeGUAsB<])Vj2roO6Us4t?hHiWR6!!%TMJcC`0(VTj^s1SHGs1SHGs1SHGs1P0,k2s8Us8Mlr !<<&\!M]VM]`EK\mJd.dJcC<$N;ja.s1SHGs1SHGs1SHGs1SHGUAsB<])Vj2roO6Us4t?hHiWR6 rrBq9!!'n9!!'n9!!'n9!!'n9!!(@F(qos_s1SHGs1SHGs1SHGs1SH,s5rIU!<<&q!K]`8'%]`EK\ n,N=d_Z'T9_Z'T9_Z'T9_Z']bh: rYtqbk;q],S7rZ(h8rZ(q;r#G_9qAer'(VTj^s1SHGs1SHGs1SHGs1P0,k2s8Us8Mlr !<<&\!M]Vd]`8'1^&J*']`EK\mJd.dJcC<$rr2ss8O)@Urr>?9s2P'=*<,s?*<6$YqYpO8p\t45 r;Z[7rVlj;qu?R6rr2sbh:q],Y9q]#V9q],V8q],V8rZ(q;qAfM7rZ(q;rYtq*p:UG+p:UKS!:Bdd!7UrJ62U]Z62gi^63$u^62^c^ 621EX5lgra63$u`62po`5lgra63$u_63$u]6%o:9*;oj7*<-!:*<-!8*<6'9*!$$9*<-!8*<-!; *<-!7*<-!;*<-!;*!$$<*9R8=^&PeG^&PeG^&PeG^&PeG^&Oi,k2s8U!<<&\!M]Ve]`8'+]`8'+ ]`EK\mJd.ddf9;4r;Qa_qYpO]rr2sarr2saqYpO]rr2sap](7Zrr2sarr2sarr2sarVum`rVlj` rVlj`JcCT,(VTj^s1SHGs1SHGs1SHGs1P0,k2s8Us8Mlr!<<&\!M]Ve]`8'+]`8'+]`EK\mJd.d df9;4r;Qa_qYpO]rr2sarr2saqYpO]rr2sap](7Zrr2sarr2sarr2sarVum`rVlj`rVlj`JcCQ+ (qos_s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]Ve]`8'*]`8',]`EK\mJm1dd/X,3rr2saq>UNs s8PCarr>@^s8#%Urr>@arr>@]rr>@`rr>@_s8G=^s8#%$rr<&9rr<&9rr<&FrtrHL^&PeG^&PeG ^&PeG^&PeGUAsB<])_m1qZ-]sroO6Us7O&*!;4#*!;F/-HiWR6rrCFGs$?Ya!($G\!s&B$62pla 62U]Y621BZ62pla62LT]62gf`62^c^62^cZ6,rp)!5ea9!5ea9!7(T^^&PeG^&PeG^&PeG^&PeG ^&Oi,k2s8U!<<&\!M]Vf]`8'.^&%g(]`EK\mJd.de,KD6rVlj`rr2saqZ$IZrr2saqu6X^nG`PU s$?V`r'C;]!($G\r]u,8M>nC*s1SHGs1SHGs1SHGs1SHGUAsB<])_j68ckUbs8M-]UAsr#!!)i. qZ-B(!IOn7rr<&Jrr>@`rr>@arr>@]s851^rr>@^rr>@SrrPLd62gi]62gf`62CQ[6%T&lrtrHL ^&PeG^&PeG^&PeG^&Pd?s5rIU!!*&ujoM4Vp:UG+q7Z\+p:UKS!:Bdd!7UrJ62gf`62pla62pld 63$sNrVlj`rr2sarr2sarr2sanc&YVs$?Ya!($S`!($S`!($P_!($S`!'u29MZ4O,s1SHGs1SHG s1SHGs1SHGs.]PUk.:Wn"P?6A!<<&\!M]Vf]`8'.^&.m(]`EK\mJd.de,KD6rVlj`rr2sarr3'd s8PC`rr>@arr>@arr>@arr>@TrrPLd62pla62gf`62gf`62^`_62gf`6%T&mru&NM^&PeG^&PeG ^&PeG^&PeGUAsB<])Vj2roO6Us7X,+!;jJ,!;4#+HiWR6!!(LJr'C8\r^$M_qa(5]r^$J^r'C#U !($P_q`t5^qa(8^r'>o6M#S:)s1SHGs1SHGs1SHGs1SHGUAsB<])_j6EiAj8s8M-]UAsr#!!)o0 qZ-<&!IOn7rr<&Js851\s8G=_s8,+]s8G=^s851Urr>@_s8,(^s8,+^s8506s+gUk^&PeG^&PeG ^&PeG^&PeG]qYPhk.:Tns8M-]UAsu$rrE&3rW)r2rrD])!IOn7rr<%Ms+131rtrHL^&PeG^&PeG ^&PeG^&PeGUAsB<])_j6-i!Q=s8M-]UAsu$rrE&3rW)r2rrD])!IOn7rr<%Ms+130ru&NM^&PeG ^&PeG^&PeG^&PeGUAsB<])Vj2roO6Us7a2-!58@3m(EFI!:Bdd!.k0$s,I$p^&PeG^&PeG^&PeG ^&PeG]qYPhk.:Wn"D[i2!<<&\!M]Vg]`A,HrW);u!IOn7rr<%Ms+13/rtrHL^&PeG^&PeG^&PeG ^&Pd?s5rIU!!*&ujoM4Vq7Z\+lFd4G!:Bdd!.k0$s,R*r^&PeG^&PeG^&PeG^&PeG^&Oi,k2s8U rrg[FqZ-ZqjoM4Vq7Z\+lFd4G!:Bdd!.k0$s,I$r^&PeG^&PeG^&PeG^&PeG^&Oi,k2s8U!<<&\ !M]Vg]`8&r]`EK\mJd.dXT/&]JcC<$li.d7s1SHGs1SHGs1SHGs1SHGUAsB<])_m1qZ-]sroO6U s7a2,!9h)sHiWR6!!',#pd'K2JcG$8(qos_s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]Vg]`8&r ]`EK\pAagdqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNq qYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNq qYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNqqYpNq qYpNqqYpNqqYqK7s8Te4^&PeG^&PeG^&PeG^&PeGUAsB<])_m1qZ-]sroO6Us7a2,!9h)sHiWm? p&Osh!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq !!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq !!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq!!)lq !!)lq!!*#u)86'`s1SHGs1SHGs1SHGs1SH,s5rIU!!*&ujoM4Vh7Wi:!:Bdd!.k0$s7QEi*9[>% *4c(c^&PeG^&PeG^&PeG^&PeG]qYPhk.:Wnrqc]rs8M-]UAs&_!IOn7rr<%Ms+14Cs83l"rr=%K rtrHL^&PeG^&PeG^&PeG^&Pd?s5rIU!!*&ujoM4Vh7Wi:!:Bdd!.k0$s7ZKm*<6'=*9[>%*4l.e ^&PeG^&PeG^&PeG^&PeG^&Oi,k2s8Us8Mlr!<<&\!M]VM]`EK\mJd.dJcC<$pAb.4s8W*=kPkN% \c3P\s1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAs&_!IOn7rr<%Ms+14Es8O);rr=&K]`8'%]`EK\mJm1d_Z'T9_Z'T9 _Z'T9_Z'T9p&G"2rVuj:rr;s;!<<$'O!:Bdd!.k0$s,?sp^&PeG^&PeG^&PeG^&PeG]qYPhk.:Tns8M-] UAsl!!!)l/!s$$J!;=),HiWR6!!%TMJcCc1(qos_s1SHGs1SHGs1SHGs1SH,s5rIU!<<&q!]`EK\mJd.dJcC<$NW0m0s1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-] UAsl!!!)i.rW)Z*!IOn7rr<%Ms+130rtiBK^&PeG^&PeG^&PeG^&Pd?s5rIU!<<&q!- !;=),HiWR6!!%TMJcC`0)86'`s1SHGs1SHGs1SHGs1SH,s5rIU!!*&ujoM4Vot:>*qRue,p:UKS !:Bdd!.k0$s,I$p^&PeG^&PeG^&PeG^&PeG]qYPhk.:Wnrqc]rs8M-]UAso"!!)l/quHH(!IOn7 rr<%Ms+13/rtrHL^&PeG^&PeG^&PeG^&Pd?s5rIU!!*&ujoM4Vot:>*pq?Y,p:UKS!:Bdd!.k0$ s,R*r^&PeG^&PeG^&PeG^&PeG^&Oi,k2s8Us8Mlr!<<&\!M]Ve]`8'-^&A$*]`EK\mJd.dJcC<$ NW0m0s1SHGs1SHGs1SHGs1SHGs.]PUk.:Tns8M-]UAso"!!)`+!!)`+!IOn7rr<%Ms+130rtiBK ^&PeG^&PeG^&PeG^&Pd?s5rIU!<<'S!eLFProO6Us7O&*!;=)+!;=),HiWR6!!%TMJcC]/(qos_ s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]Ve]`8'*]`8',]`EK\n,N=d_Z'T9_Z'T9_Z'T9_Z'T9 _Z'T9ci4iqs1SHGs1SHGs1SHGs1SHGs.]PUk.:Wnrqc]rs8M-]UAso"!!)]*!!)c,!IOn9s8;r7 rr<&9rr<&9rr<&9rr<&9rr<&Eru&NM^&PeG^&PeG^&PeG^&PeGUAsB<])Vj2roO6Us7X,+!;4&* !;F/-HiWR6!!%TMJcC`0(VTj^s1SHGs1SHGs1SHGs1P0,k2s8Us8Mlr!<<&\!M]Vf]`8'*^&J*, ]`EK\mJd.dJcC<$N;ja.s1SHGs1SHGs1SHGs1SHGUAsB<])Vj2roO6Us7X,+!;O8,!;4#+HiWR6 !!%TMJcF=$rZ&TN(qos_s1SHGs1SHGs1SHGs1SH,s5rIU!<<&q!)qA]M8rYtqbk;q],P6 rZ(Y3"s![C*<6$Yrr3$>ruCt:rZ(h8(qos_s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]Vg^&J)s ]`EK\mJd.dJcC<$hZ*Noqu6X9r;Qa:rr2s^F6pAY=:s8O)=ruD";!$(n9 rZ(n:(qos_s1SHGs1SHGs1SHGs1SH,s5rIU!6tN?!e=s8O)&rr=&9rrO2?*;'7K^&PeG^&PeG^&PeG ^&PeG^&Oi,k2s8U!<<&\!M]VM]`EK\mJd.d^]+96o)A[io`+mjqYpNqir8uYJcG!7!$(e6!$(q: !$)"<"!%@@*<#m;*<,s<*<,s<*<#p:*:s11*;og:*<,s<*;oj:*;ogQ^&PeG^&PeG^&PeG^&PeG ]qYPhk.:W<"A/`f!<<&\!M]VM]`EK\mJd.d^]+96o)A[io`+mjqYpNqir8uYJcG!7!$(e6!$(q: !$)"<"!%@@*<#m;*<,s<*<,s<*<#p:*:s11*;og:*<,s<*;oj:*;faQ^&PeG^&PeG^&PeG^&PeG ]qYPhk.:Tns8M-]UAs&_!IOn7rr<&Hs82lhrr<&srr<&orr<&irr<&qrr<&crr<&orr<%Ms6BX_ *;oj6*<-!;*<#p7*<-!;*;oj9*;0@0*<6'<*!$$<*<-!<*;ogR^&PeG^&PeG^&PeG^&PeG^&Oi, k2s8UbllZhqZ-ZqjoM4Vh7Wi:!:Bdd!7CiE!;-9k!;uis!;QQo!:p-i!;c]q!:9^c!;QQo!.k18 s8c*H[/UuVs1SHGs1SHG s1SHGs1SHGs.]PUk.:W<"OHuB!<<&\!M]Vf^%26t]`EK\mJd.dci3tFr;Q`srr2rur;Q`sr;Q`s q#:UEpq>UEprr2ruq#:.!:RT$!;X;/HiWa;q>enB!!)rs!!*#u!!*#u !W`6#r;Q`srr2rur;Q`srVlitrVlitr;Q`sqYpNqr;Zcsrr3$"rrE#t!!*#u!!*#u!!)rs!!)rs !!*#u!!*#u!!*#u!!(mU!!'n9!!'n9!!(@F(qos_s1SHGs1SHGs1SHGs1SH,s5rIU!6tN?!)r#GY7rZ(q;q],Y9qAfJ6(qos_s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]Vj]`8'"]`8'/ ]`EK\mJd.dJcC<$hZ!Qqrr2s"3rVlp=ruCt: "!%@@*<#mC*<.#YruD(=*<#mS^&PeG^&PeG^&PeG^&PeG]qYPhk.:Tns8M-]UAt)'!!)E"!!)l/ !IOn7s8N)9rr<&9rr<&9rr<&9rr<&Vrr=&bh:!$(q:!$)"bh:!$(q:!Z_7?r#GY7!$(k8(qos_s1SHG s1SHGs1SHGs1P0,k2s8U!<<&\!M]Vj]`8'"]`8'/]`EK\mJd.dJcC<$hZ!Qqqu6X9r;Qa:rr2s< qu6X9lMgi(qu6X9r;R!As8O)=ru<$Vrr=&:rtrHL^&PeG^&PeG^&PeG^&PeGUAsB<])^+TjoGJ^ roO6Us8'D/!:@H"!;aA0HiWR6!!%TMJcFU,!$(n9!$(q:!$)"UF7qYpO8rr2s"3qYpO8rr2s.!:RT$!;X;/ HiWR6!!'S0!!*#u!!*#u!!*#u!!*#u!!)ut#QXl)s8N*!rrDfn!!*#u!s&B$!<)p(!<<'!s8N*! rr@WMPQ)H4s1SHGs1SHGs1SHGs1SHGUAsB<])Vj1joGJ^roO6Us7s>.!:RT$!;X;/HiWR6!!'S0 !!*#u!!*#u!!*#u!!*#u!!)ut#QXl)s8N*!rrDfn!!*#u!s&B$!<)p(!<<'!s8N*!rr@WMP5cB4 s1SHGs1SHGs1SHGs1SHGUAsB<])Vj2roO6Us7j;-!;!o(!;O5.HiWR6!!'S0!!)ut!W`6#r;Qj! s8N)trs/W)!<<'!s8N)orr<&srrN3#!<)p)!<<'!s8N*!rrE)n!<3#t!!*&u!<)rs!!*&u!<3#t !.k0]rtrHL^&PeG^&PeG^&PeG^&PeGUAsB<])^+TjoGJ^roO6Us7j;-!;!o(!;O5.HiWR6!!'S0 !!)ut!W`6#r;Qj!s8N)trs/W)!<<'!s8N)orr<&srrN3#!<)p)!<<'!s8N*!rrE)n!<3#t!!*&u !<)rs!!*&u!<3#t!.k0\ru&NM^&PeG^&PeG^&PeG^&PeGUAsB<])Vj2roO6Us7X.t!;=),HiWR6 !!'S0!!*#u!s&B$!;uj!!<<'!rVm-'rrE*!!<<'!q#:!lr;QfurrE#t!!*#u!W`6#rVu]o !ri9#rW!!!!<)ot!;lcr!;uln!:Tpf!5ea9!5ea9!7CiH*#QBh^&PeG^&PeG^&PeG^&PeGUAsB< ])Vj1joGJ^roO6Us4t?hHiWX8r;a_7!!)lqr;cis!!)rs!W`9#quHZp!!)]l!!)rs!W`6#rVlit rr3$"rrE#tq>^Ts!<<#u!WN/urr<&rrr<&ss7u`arr<&9rr<&9rr<&Hs8EuU^&PeG^&PeG^&PeG ^&PeG^&Oi,k2s8U!<<&\!M]VM]`EK\mJd.d\c2X0qu6Wrr;R!%s8N*!rr<&srr<&lrr<&srrN3# !<)ot!;uis!;6?r!<3'!!<3&trr<&rrr<&srr<%Ms0_kC^&PeG^&PeG^&PeG^&PeG]qYPhk.:Tn roO4]s8M-]UAs&_!IOn7rr<&0rr<&rrr<&srs&Q(rrE*!!!)rs!!)]l!!)rs!W`6#rVlitr;Q`s p&>3rrrE'!rrE#t!!)or!!)rs!!%TM[/UuVs1SHGs1SHGs1SHGs1SHGUAsB<])Vj2roO6Us4t?h HiWR6!!'S0!!)lq!!*#u!!*#u!!*#urrE#t!!)Zk!!*#u!!*#u!s&B$!;lcr!;-u!IOn7rr<%M s+130rtiBK^&PeG^&PeG^&PeG^&Pd?s5rIU!!*#\!ffo!IOn7rr<%Ms+131rtrHL^&PeG ^&PeG^&PeG^&PeGUAsB<])^+TjoGJ^roO6Us80M+!:%5uHiWR6!!%TMJcC`0)86'`s1SHGs1SHG s1SHGs1SH,s5rIU!!*&ujoM4Vr4W+1"MFd8]`@<1!IOn7rr<%ms8E#qs8N(Ms+14FrtiBK^&PeG ^&PeG^&PeG^&Pd?s5rIU!6tN*!V;Fs1SHGs1SHGs1SHGs1SHGUAsB<])Vj2roO6U s80J0!;sP1!<9b4!<'V2!;sP1!;sM2HiWR6!!'M.!!)orrW)rtq>gKo!!)ut!!)ut!!)`ms%J"D M#S=*s1SHGs1SHGs1SHGs1SHGs.]PUk.:W!5ea9!5ea9!7(T^^&PeG^&PeG^&PeG^&PeG^&Oi,k2s8U!<<&\!M]VM ]`EK\rVlito)A[iMuW$8JcD5>(VTj^s1SHGs1SHGs1SHGs1P0,k2s8Uc2PK]`8'0]`8'.]`EK\mJd.dNrS<:JcD/<(VTj^s1SHGs1SHGs1SHGs1P0,k2s8Uc2Qi+!<<&\ !M]Vm]`8'+]`\>K]`8'0]`8'.]`EK\mJd.dNrS<:JcD,;(qos_s1SHGs1SHGs1SHGs1P0,k2s8U !<<&\!M]Vm]`8'+]`A,HrW)l0!!)f-!IOn7rr<%Zs6!(,s-s$*^&PeG^&PeG^&PeG^&PeG^&Oi, k2s8Uc2Qi+!<<&\!M]Vm]`8'+]`A,HrW)l0!!)f-!IOn7rr<%Zs6!(,s-is*^&PeG^&PeG^&PeG ^&PeG^&Oi,k2s8U!<<&\!M]Vm]`8'*^&7s0]`8',]`EK\mJd.dNrS99JcD2=(VTj^s1SHGs1SHG s1SHGs1P0,k2s8Uc2Qi+!<<&\!M]Vm]`8'*^&7s0]`8',]`EK\mJd.dNrS99JcD/<(qos_s1SHG s1SHGs1SHGs1P0,k2s8U!<<&\!M]Vm]`8',]`8'-]`8',]`EK\mJd.dNrT&Orr;@ZJcD8?(qos_ s1SHGs1SHGs1SHGs1SH,s5rIU!6tN*!!5ea9!5ea9!7(T^ ^&PeG^&PeG^&PeG^&PeG^&Oi,k2s8U!<<&\!M]Vl]`8'1^&J*1^&7s&]`EK\mJd.dL&^O6JcD;@ (VTj^s1SHGs1SHGs1SHGs1P0,k2s8Uc2Qi+!<<&\!M]Vl]`8'1^&J*1^&7s&]`EK\mJd.dL&^O6 JcD8?(qos_s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]Vl]`8'2]`8'/^&A!4]`@](qos_s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]Vk ]`J2I!;O8*!!'_0!;jG1HiWR6!!%]PnP"N6S,X>=s1SHGs1SHGs1SHGs1SHGs.]PUk.:WJcD#8(VTj^s1SHGs1SHGs1SHGs1P0,k2s8Uc2Qi+!<<&\!M]VM]`EK\ mJd.dK)bU>JcCu7(qos_s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]VM]`EK\o)JOd_Z'T9_Z0L, a8Z,>_Z'T9_Z'T9ci4iqs1SHGs1SHGs1SHGs1SHGs.]PUk.:Wf^Y!!(CGs%J"DOoH93 s1SHGs1SHGs1SHGs1SHGs.]PUk.:W\;) s1SHGs1SHGs1SHGs1SHGUAsB<])^+TjoGJ^roO6Us4t?hHiWR6!!(II!!)ut!!)3^!!%TMJcFO* (qos_s1SHGs1SHGs1SHGs1P0,k2s8U!<<&\!M]VM]`EK\mJd.ddf0FMs8N*!qu?`srW)rtrW)rt quHcsqZ-TpquHcsq>c*HJcG?A(qos_s1SHGs1SHGs1SHGs1SH,s5rIU!6tN*!UEp rr2rurr2ruq#CUEprr2rurr2ruq#C_GrOi5Z!:Bdd!.k0$s,R*r^&PeG ^&PeG^&PeG^&PeG^&Oi,k2s8Uc2Qi+!<<&\!M]Vm^&J*3]`8'&]`eDL]`>_GrOi5Z!:Bdd!.k0$ s,I'J]a+V4s5rIU!!*&ujoM4VrOi@7]`>aZ!:d`&!<0\3!<'S3HiWR6!!%TMJcC`0(VTj^s1SHG s1SHGs1SHGs1P0,k2s8Uc2Qi+!<<&\!M]Vm]`eDL!56&Gn\"o&rk8=3rOi5Z!:Bdd!.k0$s,I$Y ^%210HiTo@k2s8U!<<&\!M]Vj]`J2I!:d`(!56)E!<0Y4HiWX8r;a_7!!'n9!!'n9!!'n9!!'n9 !!(@Fn@]&,UAsB<])^+TjoGJ^roO6Us8'D1!5/C&]`J2I^&7s1]`EK\n,N=d_Z'T9_Z'T9_Z'T9 _Z'T9_Z'T9cMmpYs7!IOn7rr<%Ms+131rrKh5o=YEW!2BMUk.:Wtp:UKS!:Bdd!.k0$s,R*[^&R];#^cWHs5rIU!6tN*!tp:UKS!:Bdd !.k0$s,I$Z^&S)Fq>gK-$%)`Is5rIU!!*&ujoM4Vm(NE!oXt9Q!:Bdd!.k0$s,R*[^&R];#^cWH s5rIU!6tN*!'O!:Bgd!5ea9!5ea9!5ea9!5ea9!5ea9!71ZG^&S)Fq>gK-#^cWHs5rIU!6tN*!'O!:Bgd!5ea9!5ea9!5ea9!5ea9!5ea9!7(TF^&S#DrW)i/$%)`Is5rIU!!*&u joM4Vh7Wi:!:Bdd!.k0$s,R*[^&S&EquHZ.#^cWHs5rIU!6tN*![s8K\3!;F/0I/gmn!;X;3 !56'n]`@R%!!%S`XM"i=^&Pcn!58F(]`WW^^&R6.5^WRFs1SHGs1SHGs1SHGs1SHGs1SHGs1SHG s1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHG^&R];"+1(KI.P#Xs1P0,k2s8U!<<&\ !ho\po=Y0Ps7K]mTkS]`8'3]`EN\rk/:3pUp]Ws1Q)Gq7Qq3]tJg,!:^!g!.hhc]a"PN s1Nd[^&R];"+1*^s5q![HiUk[^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG ^&PeG^&PeG^&PeG^&PeG^&PdZs7[s8K\6!56&GqRm,]s1Q)G]tFFD]`eDL]mRKnnG`IgJ\A.u#6;I;]mKgn s8'D/!;jG3HiUk[k.O$-!58EGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHG s1SHGs1SHGs1SHGs1SHGs1Q,Gr4N(1q7QlX!!%E<]a=_PUAsB<])Vj2roOBY!<9aG!;jJ/!<9_5 I/j#UrW)r2!IXqH^&A$-]`WZ^]tOCFqn3.5]tJg,!:^!g!.hhc]a"PNs1Nd[^&R];"+1*^s5q![ HiX2[s1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHG s1SHGs7[s8K\6!56&GqRm,]s1Q)G]tFFD]`eDL]mRKnnG`IgJ\A2!#6;I;]mKgns8'D/!;jG3 HiUk[k.O$-!58EGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHG s1SHGs1SHGs1Q,Gr4N(1q7QlX!!%E<]a4YOUAsB<])^+TjoGJ^roOK\!<9aG!5/@4r4N45]tJgn rk8=3r4N(1rk/>[s8K\3!;sP1!<0Y7I/gmn!;sP1!!g1;]tJg,]`@s0!!)ip!!%S`X1\`<^&Pcn !58F1^&A$/]`WW^^&R6.5^WRFs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHG s1SHGs1SHGs1SHGs1SHGs1SHG^&S#DrW)i/"+1(KI.P#Xs1P0,k2s8U!<<&\"el"s]tFFF^&J*3 ]`\>K]mTkX^&J*3]`8'3]`EN\rk/:3rk8=3r4N5\s1Q)Grk8=3rk/L9]tJg,]`A!1rrDlp!!%S` XM"i=^&Pcn!58F0^&J*0]`WW^^&R6.5^WS3^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG ^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&S#DrrDo/"+1(KI.P#Ws1P0,k2s8Uc2Qi+!<<&\ #,2+t]tFCGqRm+6]tJgn]tFFB]`8'3]`EN\rk/:3qRm+6]tJgn]tFFB^&J*4]`WYq]`@s0!!)ip !!%S`X1\`<^&Pcn!58F2^&7s.]`WW^^&R6.5^WS3^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG ^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&S#Dr;cc/"+1(KI.P#Xs1P0,k2s8U!<<&\ #bh>!]tFEZ!!)r1"9?-KI/j2ZrrDu1!!*#3!IXqH]`8'1^&J*3]```_]tFFD^&J';]`>aZI(d2n qu6Wrq>UEpJ\A.u#6;I;]mKgns89S0!;jG3HiUk[k.O$-!58EGs1SHGs1SHGs1SHGs1SHGs1SHG s1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1Q,Gr4W(0qn3)Z!!%E<]a4YOUAsB< ])^+TjoGJ^roOEZ!<9aG!!)l/#6;HNI/gmn!;aA/!<0Y4I/j2Z!!)l/#6;HNI/gmn!;aD/!<9_4 I/^eZ!;uis!;c]q!.hh`]a"PNs1Nd[^&S#DrW)i/"+1*^s5q![HiUk[^&PeG^&PeG^&PeG^&PeG ^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PdZs89S0!;jG3HiO.oo=YJ1 ]qYPhk.:Tns8M-bU&b5,]`8'/]a"PN]mTjn]`@oB!!*#3!IXqH]`8'/]a"PN]mTjn]`@oBrrE)4 "+7eq!;lcr!;ZWp!.hhb]a"PNs1Nd[^&S&Er;c`."+1*^s5q![HiX2[s1SHGs1SHGs1SHGs1SHG s1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs89S/!;sM4HiO.oo=YG0 ]qYPhk.:W_G!;sM5!56'ns8K_3!;sM1!<0Y4I/j2Z!!)r1rrE&3"FU6_ ]`@uDrr<28!56'nrk/:3r;Q`sqYpNqJ\A(s#6;I;]mKgns80M0!;jG3HiUk[k.O$-!<9b4^&PeG ^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeGr4W+1 qRluY!!%E<]a=_PUAsB<])Vj2roOEZ!<9aG!!)l/#6;HNI/gmn!;aA/!<0Y4I/j2Z!!)l/#6;HN I/gmn!;aD/!<9_4I/^eZ!;uis!;c]q!.hha]a"PNs1Nd[^&S#DrW)i/"+1*^s5q![HiUk[^&PeG ^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PdZs89S0 !;jG3HiO.oo=YG0]qYPhk.:W!]tFEZ!!)r1"9?-KI/j2ZrrDu1 !!*#3!IXqH]`8'1^&J*3]```_]tFFD^&J'8]`>aZI/^eZ!;uis!;c]q!.hha]a"PNs1Nd[^&RuC rrDr0"+1*^s5q![HiX2[s1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHGs1SHG s1SHGs1SHGs1SHGs1SHGs89S1!;aA2HiO.oo=YG0]qYPhk.:W[s8K\6!56&GqRm,]s1Q)G]tFFD]`S8J]mTdl!!)`m!!%S`WP&N:^&Pcn !58F(]`WW^^&R6.5^WS3^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG ^&PeG^&PeG^&PeG^&PeG^&R];"+1(KI.P#Xs1P0,k2s8U!<<&\"el"s]tFFF^&J*3]`\>K]mTkX ^&J*3]`8'3]`EN\rk/:3rk8=3r4N5\s1Q)Grk8=3rk/C6]tJgm]`8'2s8E#qrr<%M]rSgO!58EG HiUk[qRlk/qn3)Z!58Ep]g-rF^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG ^&PeG^&PeG^&PeG^&PeG^&PeG]tOID]`8'.]`WW^!.=CO#lhT4s5rIU!<30fk2l[DroOBY!<9aG !;jJ/!<9_5I/j#UrW)r2!IXqH^&A$-]`WZ^]tOCFqn3(3]tJgl]`8'+rr<%M]rA[M!58EGHiUk[ o=Y6R!58Ep]g-rF^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG ^&PeG^&PeG^&PeG]tOI;]`WW^!.=CO$3.]5s5rIU!!*&ujoqIZs1Q)Gr4N=8]tFEZ]mTkV]`S8J ]`A&F!IXqH]`S8J]`@oB#CQQb]`>aZ!;sM4!56'nrOi12pAY*mJ\A(s#6;I;]mKgns7[s8K_2!;X;1I/gmnrW)i/!s$$J I/U_Y!;?Em!.hh`]a"PNs1Nd[^&R];"+1*^s5q![HiUk[^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG ^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PdZs7[s8K\3!;F/0I/gmn !;X;1!56'nrOi12pAY*mJ\A(s#6;I;]mKgns7E !.k0$s+14:rs4"Hs5rIU!!*&ujoD-,!.b-D!'Isp^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG ^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&PeG^&Pe7!:RT*UAsB<])_m1joGJ^roO6Us4G!dHiX1t ]n*kJ^$WK=I%pZ'k.:Tns8M-\U=T>E!.k0$s+14;rs*qGs5rIU!<<&\!,]tJfS]`\;J]`@]aZI#krDs1Q)G^&A!3^&A!3^&A!7]`>aZI#krDs1Q)G^&A!3^&A!3^&A!7]`>aZ I#krIs*UR@k2s8U!<<&\!M]VH]``]_s1JF)]`S8J]mPmS"96'J!;*r,!56'nO1bYq]tFF<]`S8J ]mPpT#lf:Hs5rIU!<<&\!_G]`>_G]`>aZI#krH s1Q)G]`>_G^&A!;]`>_G]`>aZI#krLs1Q)G]`>_G]`>_G^&A!7]`>aZI#krIs*UR@k2s8U!<<&\ !M]VH]`ic`s1JEGrVur3rVur3rW!)7!56'no">#'n\"o&rOi12i4T*jn%A]$lFd?#]tFEZrVur3 rVur3rW!2:!56'n]tFFB]`8'-]`8')]`8'/]`8&D]`eAK]`>bF!!'_3!!'_3!!g1;]tJg,]`@oB !!)Z)!!)Z)!!)l/!!'dI#lf:Hs5rIU!<<&\!_G]`>_G]`>aZI#krHs1Q)G]`>_G^&A!;]`>_G]`>aZI#krLs1Q)G]`>_G]`>_G^&A!7]`>aZ I#krIs*UR@k2s8U!<<&\!M]Vm^&7s)]`8'!]`ic`s1JEGrW!A?!5/BG!5/BG!56'no">#'n\"o& rOi12i4T*jf=_Ii]tFEZ!5/BGrW!A?!5/BG!56'n]tFCGr4W+1lFm2tr4W+1]"JOP]tFEZ!5/BG !5/BGrW!5;!56'n]tFCGr4W+1oXt5)oY(8)r4W+1^V'pQI%pZ'k.:WbF!"?O@]`>_G]`>_G]tJfS]a4YO ]`>_G]`>bF!!p7<]`>_G]tJfS]aXqS]`>_G]`>_G]`>bF!!Kt8]tJfS]a=^dUAsB<])Vj2roO6U s8BV2!<0Y3!;F/,!:7B&HiX2[!58@3%(uYS!5/BG!5/BG]mTgmrrE#2rW)r2!!*#3rW)o1rW)u3 rW)u3#QVQO!5/BG]`A#ErW)r2!!*#3!!*#3rW)o1#6;HN!5/BG^&A$1^&J*3]`J2I^&7s1^&A$- ^&A!;s1Q)G]`>_G^&A!?]`>_G]`>aZI(d2n!;sP1!<0\2!<0Y9!56&G]`8'/^&J*1^&J*3^&A$2 ]`S8J!!*#3!!*#3!!(?Y%0+#S!5/BG!5/BG!58@3#e^5O]mRN,!!)r1rrE&3rW)o1rr<)5!<0\2 !;aD/!;sP1!<0\2!<0Y6!5/@4rk/:3rk/:3e@c.fI%pZ'k.:WbF!"?O@]`>_G]`>_G]tJfS]a4YO]`>_G]`>bF !!p7<]`>_G]tJfS]aXqS]`>_G]`>_G]`>bF!!Kt8]tJfS]a=^dUAsB<])Vj2roO6Us8BV2!<0Y7 !56&G!<0\3!!^+:]`>_G^&A$3]`nJM]`>aZ!<'S7HiX2[!58@3'tjU\!5/BG!5/BG]mRN,!56&G ]tFFF]`nJM]`>aZ!<0Y6!56&Grk/C6]tFFF]aOnS]`8&G!!'\4]tFFF]`S8J]`A&F!s$$J!<0Y3 !<0Y:!56&G!56&Grk/U<]tFEZ]`>aZ!;sM4!56&Grk/:3qn2t0rk/U;]tFEZ!5/BGrW!D@!5/BG !56'n]tFEZ!<0Y8!5/BG]`A&F$37cQ!56&G!56&Gqn3%2]`A&F"TZ49]tFFF]a=bQ]`8&G]`>aZ !<0Y3!7/=es1Q)G]`>_G]`>_G^&A!<]`>aZI(d2n]`A&F"TZ49]tFFF]a=bQ]`>aZ!!'^G!<0Y3 !;jG2!5/C3]`eDL!56&Grk/X=]tFCG]tFEZ]`A&F!!(N^#lf:Hs5rIU!6tO0!p0L_roO6Us8BV2 !<0Y4!58=2!PJL4]`J2I!<'V1!<9_8!5/BG!;sM6HiX2[!58@3!58@3!58@3"MFfK]mPmS"TQ0K !58@3!58@3!58@3"MFfK]mPmS"TQ0K!58@3!58@3!58@3"MFfK]mPmS$3,CIs5rIU!!*&ujoM4V rOr.0s1Jg@]tFEZ!56&G!5/@4r4N@9]`>aZ!56&GrOiA^!<9_4^&A!B]`>_G]`>_G]`>aZI(d2n r4N(1rk/L9]tFEZ]`A&F!s$$J!;jG3!56&Grk/U<]tFEZ]`>aZ!<0Y6!56&Grk/C6]tFFF]`S8J ]`A&F!!*#3!!*#3!s$$J!;sM1!<'S2!<0Y3!<0Y3!;jG0!<0Y;s1Q)G]`>_G^&A!@]`>_G]`>aZ I(d2n]`A&F!W]n6qn316]tFEZ]`A&F!!)o0!W]n6rk/I8]`>aZ!<0Y6!56&Grk/C6]tFFF]`8&Y ]aXqS]`>_G]`>_G]`>bF!"$==]tJg,]`>_Grk/I8]`>aZ!<0Y6!56&Grk/C6]tFFF]`8'0]`J2I !<0Y8!5/BG]`A&F!s$$J!<0Y6!56&Grk/:3e@c.fI%pZ'k.:W_Gr4N5\!<9_4oXt>,]tJfS]`\;J]`@],]tJfS]a=^dUAsB<])Vj2roO6Us8BV2!<0Y4!58=2!PJL4]`J2I!<'V1!<9_8!5/BG!;sM6 HiX2[!58@3!58@3!58@3"MFfK]mTgmrrE&3quHc1!W]pIquHc1!!)o0!s$$J!<0Y_G]tFFF^&7s2]`S8J]`A&F!!)o0$37cQ!5/BG]`>aZquHc1!!*#3 !s$$J!<0Y3!7/=]s1Q)G^&A!3^&A!3^&A!E]`>aZI(d2n]tFEZ!56&G]tFFF]`S8J]`A&F!W]pI quHW-$37cQ!5/BG]`>aZquHc1!!*#3!s$$J!<0Y3!7\[fs*UR@k2s8Uc2Qi+!<<&\!M]Vm]`8'3 ]aXtT!56&G]`>aZ!!'\4rk/C6]tFFF]`J2I!;jG4HiX2[!;*r,!56'nO1bYq]tFF<]`S8J]mPmS "96'J!;*r,!56'nO1bl"I%pZ'k.:Tns8M-]UAt2*!!*#3!W]n6rOi12rk/@5]`A&F$37cQ!56&G ]`>_Gr4N5\!<9_4oXt>,]tJgk]`S8J]`@rC!s$$J!;jG0!;jG3!56&Grk/U<]tFEZ]`>aZ!<0Y3 !<0Y5!5/C3]`8'0]`8'3]`8'3]`8'-]`S8J]`A&F!!)u2!!)c,!!*#3"96'J!;*r:!56'n]tFEZ ]`>_G]tFEZ]`A&F"ou?M!56&Grk/:3qn3@;]tFEZ!56&G]tFFC]`8'3]`S8J]`A&F!!(?Y"96'J !;*r:!56'n]tFEZ]`>_G]tFEZ]`A&F!s$$J!<0Y6!56&GpUpq7]tFEZ!56&G]tFFC]`8'3]`S8J ]`A&F!!(N^#lf:Hs5rIU!6tN*!aZ!5/BG]`8&G!<0Y6!56&Grk/@5]`@rC"FL4L]`@]<$imuSI(d2n]tFEZ]`A&F "ou?M!56&Grk/C6]tFFF]`eDL]`>_GrOiL;]tFEZ]`>aZ!<0Y3!<'S2!<'S2!<0Y5!5/C2]`8'3 ]`8'3]aOnS]`>aZ!56&G]tFFD]`8'3]`8'0]`8'3]`\;J]`@]<"ou?MI(d2nrk/:3rk/C6]tFFF ]`nJM]`>aZ!<0Y3!;jG0!<0Y3!<0Y6!56&Grk/C6]tFFF]a"PN]`>aZ!!(?Y"96'J!;*r/!56'n ]tFFF]`8'3]`S8J]`A&F$37cQ!56&G!56&Grk/:3qn2t0rk/:3rk/C6]tFFF]`S8J]`A&F#6;HN !56&G!7\[fs*UR@k2s8Uc2Qi+!<<&\!M]VH]``]_s1JF)]`S8J]mPmS"96'J!;*r,!56'nO1bYq ]tFF<]`S8J]mPmS$3,CIs5rIU!!*&ujoM4VrOi12rk/F7]tFCGrk8=3"2+]J!<'V0!<9_6!5/C0 ]``]_s1JF)]`S8J]mTgmrrE#2rW)r2!!*#3rW)o1rW)r2rW)o1"ou?M!56&Grk8:2r4N(1r4W(0 s1JC4rOi12rOr11rOr42rk/@5]tO@Erk8:2q7Zb-"96'J!;*r/!56'n]tFFF]`8'3]`8'3^&A!9 ]`>_G]tFFF]`8'0]`8'3]`8'3]`8'3^&A$2]`8'3]`8'3^&J'5]`?Bl"96'J!;*r/!56'n]tFFF ]`8'3]`8'3^&A$1^&J'5]`A&FrW)f.!!*#3!!*#3!!*#3rW)r2!!*#3!!*#3rr<)5!7\[fs*UR@ k2s8Uc2U'2joGG\joM4VfY%E8!<9_4oXt>,]tJfS]`\;J]`@],]tJfS ]a=^dUAsB<])Vj2roO6Us4G!fHiX2[!;*r,!56'nO1bYq]tFF<]`S8J]mPmS"96'J!;*r,!56'n OM(r"I%pZ'k.:W,]tJfS]`\;J]`@]< !s$$JI#krIs*UR@k2s8U!<<&\!M]VH]``]_s1JF)]`S8J]mPmS"96'J!;*r,!56'nO1bYq]tFF< ]`S8J]mPpT#lf:Hs5rIU!6tN*!,]tJfS]`\;J]`@],]tJfT]a4XcUAsB<])^+TjoGJ^roO6Us4G!dHiX38]`Fk2s8Uc2Qi+!<<&\!M[8Ys+13$s2+dBHiTo@k2s8U!<<&\!2>%XJ\?WJ_7^'RUAsB< ])^+TjoGJ^roO9V^&NYsJ\?WJ_n?A(!2BMUk.:Tns8M-]U:l-XJcC<$_uC!i!2BMUk.:TnroO4] s8M-^U:pSX]n*kJ]u.MiHiTo@k2s8U!<<&\!i!C.J\?WJJ\B"8#^cWHs5rIU!6kX4k2l[DroO?X ^&PdZJUE#rJUGOd%0+#SHiTo@k2s8U!<<&\!i!C.J\?WJJ\B"8#^cWHs5rIU!6kZ/6081IroOBY ^&PdZI";9K!.b-m!"HXA]tJdnUAsB<])Vj2roO?X^&PdZJUE#rJUGRe$idoRHiTo@k2s8Uc2Zo- 5lgrajp%Qns1Q*n!.k0$s+14+s7!]3!58EG]mKgSs5rIU!!*&ujoqKms1Q*nJH16$JH3jn%))\S ]mKgSs5rIU!6tQ+!^QhdroOEZ^&PdZHiS`tJcC<$h>[Jgo)B5J!58EG]mKgSs5rIU!!*&ujp%Qn s1Q*n!.k0$s+14,s7!]2!58EG]mKgSs5rIU!6kZ/6081IroOEZ^&PdZHiS`tJcC<$h>[Mhs7[Mhs7l*<,s<*<,s?*<6$Yo`"n2 o`"n2mJd/+qu6al*<,s<*<,s?*<6$Yo`"n2o`"n2mJd/+qu6a*<6$Ys8O)rZ(n:rYu(@ *<-uurVuj:q#:=6r;Qa:rr2s*<6$Ys8O)UF7qYpO8q#:=6rr2s*<.#UrrX8@ruD%<"!%@@ *<,s<*:j+0*<,s<*<#m;*<,s?*<6$Yrr3'?s8O)9rr=&UF7 JcDAB!PSO4^%qa-]aoJj^&PdZHiTo@k2s8U!<<&\#bo$4]tJdns8W$;s8NBFs8O)=ruD(=*<#p; *<,s<*<,s?*<6$Yrr2sbk;!$(k8r>bk;!$)"<"!%@@*<,s? *<6$Yrr3'?s8O)9rrX8@ruD%bk;"!%@@*<,s>*<6': *<#m;*.e-_rrKh5rOr+/r4NSf!58EG]mKgSs5rIU!'gJF!*<.#XrrsJCruD(=*<,s?*<6$Yrr2sUF7r;Qa:rr2s*<.#UrrX8@ruD%<"!%@@*<,s<*:j+0*<,s<*<#m;*<,s?*<6$Yrr3'? s8O)9rr=&UF7JcDDC!PSO4^%qa-]afDi^&PdZHiTo@k2s8U 5Q9dG!<<&\#bo$4]tJdns8W'<#6,\C*<6$YrVlj;r;Zd:rVuj:rr2sUF7rr2s< rVlj;rr2sUF7r;Za9"90A@*<-!<*!-'Zrr;s;r;Qa:JcDAB!PSO)]aoJj^&PdZHiTo@ k2s8U!<<&\#bo$4]tJdnruD%<"s![C*<6$Yrr3$>ruD%<"s![C*<6$Yrr3'?s8O)!PSO) ]afDi^&PdZHiTo@k2s8U8,hWO!<<&\#,8g2]tJdnnc&S/JcC<$JcG0UF7rr2s< rVlj;rr2sUF7r;Za9"90A@*<-!<*!-'Zrr;s;r;Qa:JcDDC!PSO)]afDi^&PdZHiTo@ k2s8U5Q3qL!<<&\#,8g2]tJdno)A\0JcC<$JcG-;!PSO)]aoJj^&PdZHiTo@k2s8U!<<&\#,8g2 ]tJdnnc&S/JcC<$JcG3=!PSO)]afDi^&PdZHiTo@k2s8U8He0AjoGG\jp%Qns1Q*n!;$3j*.e-@ s+14:rrKh5o=YZ^!58EG]mKgSs5rIU!!*&ujp%Qns1Q*n!:p-i*.e-@s+14[JgnU(fH^&PdZHiTo@k2s8U!<<&\#,8g2 ]tJdnoD\e1JcC<$JcG-;!PSO)]afDi^&PdZHiTo@k2s8U7g)-?joGG\jp%Qns1Q*n!.k0$s+14+ s6fps^&PdZHiTo@k2s8U!<<&\#,8g2]tJdnJcC<$JcFU,!57oM%04*A]tJdnUAsB<])YA#joGJ^ roOEZ^&PdZHiS`tJcC<$h>cuX%KO3B]tJdnUAsB<])Vj2roOEZ^&PdZHiS`tJcC<$hZ*$E%))\S ]mKgSs5rIU!([%N!airrYsps%Mt_!)3(c!)2t`!)3@k!)3Cl!)3Cl!)37h !)2n^"&/ap9\TLH9_eVf9S*5=rrKh5o=YZ^!58EG]mKgSs5rIU!!*&ujp7]ps1Q*n!<<)u9_&,_ 9]l?T9`+hl9`P,dqu6Xiq#:=fq#:Lks8Pdm9_8;_9`=tk9`=tk9`"eh9_/2c9`P,dqu6XiiVrmO q#:=fJcDPG!PSO)]afDi^&PdZHiTo@k2s8U8,hWO!<<&\#,8g2]tJdnr_*@m9`G(k9`G%l9`G%o 9`P,drr;skrr3'os%H,Xrr>ajs8G[ps%NGd9`G%r9`P,ds%H,crrYsps%N=i!DNOm9`>"k9`"bh 9`+ho9`P,ds8Pdhs8G^ls8G^krrPmo9`>"j9EbAhs%H,crr>als8Pdhrrl*r9`P,drVujjrVumk !WPjms8G^krr>`Ds.fSp^&R];%t"Ajs1Q*n!2BMUk.:Tns8M-gU:pT?]mKh[9`P,dec,VCqu6al s8Pd_rr>acrr>a`rr>akrr>alrr>alrr>ahrr>a^rrYsps%M/H!)31f!).tDV#LJ/s7ajs8G[ps%NGd9`G%r9`P,ds%H,crrYsps%N=i!DNOm9`>"k 9`"bh9`+ho9`P,ds8Pdhs8G^ls8G^krrPmo9`>"j9EbAhs%H,crr>als8Pdhrrl*r9`P,drVujj rVumk!WPjms8G^krr>`Ds.oYq^&R];%X\8is1Q*n!2BMUk.:UhroO4]s8M-gU:pT?]mKh[9`P,d qu6als8Pdlrru0ss%NIm9`G%o9`P,drr2slo`"nbqu6als8Pdlrru0ss%NIm9`G%p9`P,d9_n\j 9`P,drVljkq#:=fqu6^ks8W'lq#:Fis8PdlrrYsps%N:h"&/ap9`G%r9`P,ds8Pdfrs;C!s%NIm 9`P,drr3'os8PdlrrYsps%NFl"&/ap9S*5=rrKh5o=YZ^!58EG]mKgSs5rIU!!*&ujpn-!s1Q*n !<5ams%NIm9`G%o9`P,drr30rs8Pdms%NFl#>G0t9MGKd9`+hi9`+hi9`+i*9`P,d9`P,ds8Pdm s%H,ds%NIm9`If_rrYsps%NCk"&/ap9`+hi9`+hn9`P,ds%N4f"&/ap9`G%p9`P,d9`+i$9`P,d 9`P,ds8Pdms%NIm9`+ki9F(Sk9`Ifds%NFl$;CL"9`P,d9`P,drr3'os8PcDs.oYq^&R];%X\8i s1Q*n!2BMUk.:UhroO4]s8M-gU:pT?]mKh[9`P,drr;pjrr3$ns%NFl"&/ap9`G%o9`P,drr2sl o`"nbqu6als8Pdlrru0ss%NIm9`G%p9`P,d9_n\j9`P,dr;ZdjqYpOhqu6jos8Pdms%N7g"&/ap 9`G%o9`P,dqYpXks8PdlrrYsps%NFls%N:h#u(C!9`P,ds8PdlrrYsps%NFl!_iXor(R.j!).tD U]1A.s7abrr>airrYsps%NFl##,'s9`P,drr3*ps8Pbdq>UOjs8Pdkrr>afrr>airrPmos8G^e rrYsps%NFl"&/ap9`"bk9`P,drr30rs8Pdms%N4f#u(C!9`P,ds8PdlrrYsps%NFl"&/ap9`G%o 9`P,dJcDPG!PSO)]afDi^&PdZHiTo@k2s8U:]BJW!<<&\%\gZ:]tJdns%NIm9`P,drr2slrr3$n s%NFl"&/ap9`G%o9`P,drr2slo`"nbqu6als8Pdlrru0ss%NIm9`G%q9`P,ds%N:h"&/ap9`"bh 9`+hi9`+hl9`P,drr2slqYpXks8PdlrrYsps%N:h"&/ap9`G%o9`P,dr;Qajqu6srs8Pdms%NIm 9`G%o9`P,drr3'os8Pdirr>`Ds.fSp^&R];%t"Ajs1Q*n!2BMUk.:Tns8M-gU:pT?]mKh[9`P,d rr;pjrr3$ns%NFl"&/ap9`G%o9`P,drr2slo`"nbqu6als8Pdlrru0ss%NIm9`G%p9`P,d9_n\j 9`P,dr;ZdjqYpOhqu6jos8Pdms%N7g"&/ap9`G%o9`P,dqYpXks8PdlrrYsps%NFls%N:h#u(C! 9`P,ds8PdlrrYsps%NFl!_iXor(R.j!).tDV#LJ/s7b9`+hl9`P,drr30rs8Pdms%NFl"\esr9`If_rrYsps%N:h!)3:i!)3:i"&/ap9`G%l9`"bk 9`P,drr3'os8PdhrrYsps%NFl"&/ap9`4nj9`+hr9`P,ds8Pdms%NFl"&/ap9`G%o9`P,dqu6Xi JcDPG!PSO)]afDi^&PdZHiTo@k2s8U;uYn[!<<&\$_k?7]tJdns%NIm9`G(k9EG/err2slrVljk rr;skrr3'os%H,_rr>airr>ais8Pans%NFl##,'s9`P,drr3'os8Pdlrr>ajrrc$qs%H,bs8Pdf s8>Xirr>ajrr>ajrr>als8G^krr>ahs8Pans%NFl"&/ap9`G(l9`"bn9`P,ds8Pdls8G^js8Pan s%NFlr_3=k"&/ap9S*5@rrKh5o=YZ^!58EG]mKgSs5rIU!!*&ujpn-!s1Q*n!<5ams%NIm9`G%l 9`=tk9`=tn9`P,drr33ss8Pbds8Pdbrr>airrYsps%NFl##,'s9`P,drr30rs8Pdms%N=i"&/ap 9`=tn9`P,dqYpOhrVljkrr2slrVljkqu6als8PdlrrYsps%N:h"&/ap9`G%u9`P,ds8Pdms%N=i #u(C!9`P,ds8PdlrsDI"s%NIm9MGKd9`G%o9`P,dJcDPG!PSO)]afDi^&PdZHiTo@k2s8U<;u"\ !<<&\#,8g2]tJdnir9!PJcC<$JcG]K!PSO)]aoJj^&PdZHiTo@k2s8U!<<&\$_k?7]tJdns%NIm 9`G(k9EG/err2slrVljkrr;skrr3'os%H,_rr>airr>ais8Pans%NFl##,'s9`P,drr3'os8Pdl rr>ajrrc$qs%H,bs8Pdfs8>Xirr>ajrr>ajrr>als8G^krr>ahs8Pans%NFl"&/ap9`G(l9`"bn 9`P,ds8Pdls8G^js8Pans%NFlr_3=k"&/ap9S*5ArrKh5o=YW]!58EG]mKgSs5rIU!5AY&k2l[D roOEZ^&PdZHiW1+!).tDJcC<$rVlo3s7rr>`Ds+13$s8Dru^&R];% t"Ajs1Q*n!2BMUk.:Tns8M-bU:pT?]mKh>rr>`Ds+13$s8N$!^&R];%X\8is1Q*n!2BMUk.:W.s 5jAK!<<&\#,8g2]tJdnJcC<$JcFR+!PSO)]aoJj^&PdZHiTo@k2s8U!<<&\#,8g2]tJdnir9!PJ cC<$JcG`L!PSO)]afDi^&PdZHiTo@k2s8U>Q[Mhs7cuX%KO3B]tJdnUAsB<] )Vj2roOEZ^&PdZHiS`tJcC<$hZ*$E%))\S]mKgSs5rIU!6tN*!gK-%t"Ajs1Q*n! 2BMUk.:Tns8M-bU:pT?]mKg2s+13$s5*bV^&R];%X\8is1Q*n!2BMUk.:WgK-%X\8is1Q*n!2BMUk.:WcpD%DDeT]mKgSs 5rIU!!*&ujp%Qns1Q*n!.k0$s+14,rrBb&Hjp(hs1Q*n!2BMUk.:WV!!56)2rrN26^$>Ut!;4$VI$f9]s7O(>rr<&r]a9&dUAsB<] )Vj2roO9V^&NYsJ\?WJ`4ZG(!2BMUk.:Wp(R=##7otA*>!!)o0#^cWHs5rIU!6tN*!"FL3_^&RH4"FL3_^&RH4!IOn?]`EK\JcD5>!PSO+]`A)J]`EK\qn3;`!2BMUk.:Tns8M-aU :pT?]`@DH!<;])!<;E!"FL3_^&RH4"FL3_^&RH4!IOn?]`*q7QfV!;4#+HiX0G!!%TMTDnr*s7O&*s 6[N"!;sM1!<0YA!56&G!56&G]tFEZ]`8'#]`EK\qn3;`!2BMUk.:Tns8M-bU:pT?]`-!<0Y6!5/@4rOr42!PJL$]`EK\qn38_!2BMUk.:W<"Qi#4!<<&\#,8g2]tFDnpq6_/]`@lA! <;])!WTk#*!CWh]tOIA^&J*3^&J*0]``]_]tOI=]`8'.]`EK\ot:BR!<2uu!.k0BrrKh5ot:A*l b3;urk/:3rk/C6]tFFF]`S8J]`A&F!!)H#!IOnE]a9&dUAsB<])Vj2roOEZ^&PdZ!.=OS!!)f-! <;])!WTk#9E]_C]tOIA^&J*3^&J*0]``]_]tOI=]`8'.]`EK\ot:BR!<2uu!.k0CrrKh5ot:A*m CiN"r4N(1rk/dA]tFCG]tFEZ]`>aZ!!)H#!IOnE]a/ucUAsB<])^+U5m$0Ks8M-bU:pT?]`"FL3_^&RoArrE&3rrDr0"FL3_^&Rf>!!)f-!IOn?]`EK\rr2ruJcDAB! PSO+]`A)s]`J2I^&.m1]`8'3]`S8J]`A&F!!)H#!IOnE]a9&dUAsB<])Vj2roOEZ^&PdZ!.=RT! W]n6q7Qe.oXt;*^$SJrHiUjns7sA.!<0\3!;jG4HiUjns7O&*!;X;/HiWiQ!IOnHrr<%Ms.KAm^ &Rc=!<;AurrE&3!!*#3!s$$J!<0Y6!56&Grk/:3m_&XK!;jG8HiTo@k2s8Ublm/p5lgrajp%Qns 1Q)GI/1GU!<0Y3!;aA/s7Eu*s1Re>"FL3_^&RoAqZ-K+"FL3_^&Rf>!!)f-!IOn?]`EK\rr2ruJ cDAB!PSO+]`A*#]`8'2]`S8J]`@rC!!*#3!s$$J!<0Y3!:IN$HiX&W$%)`Is5rIU!!*&ujp%Qns 1Q)GI/(AV!5/C.]`A*)]`J/Hm7[Y1!56)Gq7Ze.rk8=3qn3,[!56)Gp:UG+pq6]U!;4#+HiX0G! !%TMT`5&+s7O&*s672u!56)D!<9_4!<0Y6!56&Grk/:3m_&XK!;jG8HiTo@k2s8Uc2Qi+!<<&\# ,8g2]tFDnq7Qb.rk/:3qRln/oXt;*^$QdBHiUjns7sA.!<0\3!;jG4HiUjns7X,+!;O5.HiWiQ! IOnHrr<%Ms.B;l^&Rc=!<;K#!!)u2!s$$J!<0Y6!56&Grk/O:]tFEZ]`8'#]`EK\qn3;`!2BMUk .:Tns8M-bU:pT?]`6+`Srl#)A^&PdZ!.=1I!<;])!WTk#*!CWh]tOI4]``]_]tOI4] `EK\ot:BR!<2uu!.k0BrrKh5ot:A*^qBbr!;jG9HiU1s`PnhW!7h(f#-,B:]tFDnmC`N"oXt;*^ $SJrHiUjns6RE%HiUjns6RE"HiWiQ!IOnHrr<%Ms.KAm^&Rc=!<9jJ!IOnE]a/ucWn#)-WW: 6+`Srl#&@^&PdZ!:0[W]`A)uHijA^^&RDG!s$$Js6G%4!;4#*I"Au!]`A**]`A)IHiO0D]a9&dW n#)-WW3%Lrl#)A^&PdZ!.=1I!<;])!WTk#9E]_C]tOI4]``]_]tOI4]`EK\ot:BR!<2uu!.k0Cr rKh5ot:A*^qBbr!;jG8HiU1s`PnhWc2QQ#!7h(f!iis6gV)hOs1RXss1RXsot>qVQiH`l]`@rC$% )`Qe]#M-!!(RK`&ec*MhWkJF`]n*kJ]u.MiHiU1s`PnhW!7h(f!iis6J\ ?WJJ\B"8#^cWPe]#M-!6tMH!&ec*MhWkJF`]n*kJ]u.MiHiU1s`PnhW!7h(f!iis6J\?WJJ\B"8#^cWPe] #M-!6tMH! M[F`U^#/ec*MiWW3%Lrl"l;JH16$JH3Ic#--4m`Mrp_rN?5%ec!JYeH!R>s+13$s53kHec*MjWW ;/]ec!JWWe$mqU4K&sU&`1'WW:TK`<*%>!<$+&!7gPW!31V4J`_OGhrXphn&5I1!5#iCec!JYeH !R>s+13$s5]7ISF]AL4#`UTu.!;t[T!33'h`;lohk(2ZGk2>A%ea^WYWW3%uc2$4I!. b-$!5/C.hZ!TFWe%d5]7ITP])]h?WrE(tc%2U?U4K&>U4E;q!.b-a!;k#ls+13$s+13=s7+Y=`; ut=]DmH,kKNu,^Wh9~> %%EndData showpage %%Trailer end %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/wbarch.eps0000644000076400007640000006003010122646342020264 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 24 475 498 791 %%Title: wbarch %%CreationDate: Tue May 21 10:36:49 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 56 dict def tgifdict begin /tgifarrowtipdict 8 dict def tgifarrowtipdict /mtrx matrix put /TGAT % tgifarrowtip { tgifarrowtipdict begin /dy exch def /dx exch def /h exch def /w exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate dy dx atan rotate 0 0 moveto w neg h lineto w neg h neg lineto savematrix setmatrix end } def /tgifarcdict 8 dict def tgifarcdict /mtrx matrix put /TGAN % tgifarcn { tgifarcdict begin /endangle exch def /startangle exch def /yrad exch def /xrad exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate xrad yrad scale 0 0 1 startangle endangle arc savematrix setmatrix end } def /TGAR % tgifarc { tgifarcdict begin /endangle exch def /startangle exch def /yrad exch def /xrad exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate xrad yrad scale 0 0 1 startangle endangle arcn savematrix setmatrix end } def /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 24 475 498 791 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % BOX 0 SG GS 10 SM GS NP 91 192 M 219 192 L 219 542 L 91 542 L CP S GR GR % TEXT NP 0 SG GS 1 W 155 256 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (main) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (main) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (thread) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (thread) SH GR GR % BOX 0 SG GS 10 SM GS NP 230 192 M 358 192 L 358 320 L 230 320 L CP S GR GR % TEXT NP 0 SG GS 1 W 294 240 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (reliable) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (reliable) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (message) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (message) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (receiver) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (receiver) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (thread) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (thread) SH GR GR % BOX 0 SG GS 10 SM GS NP 400 192 M 528 192 L 528 320 L 400 320 L CP S GR GR % TEXT NP 0 SG GS 1 W 464 240 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (raw) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (raw) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (message) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (message) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (receiver) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (receiver) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (thread) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (thread) SH GR GR % BOX 0 SG GS 10 SM GS NP 546 192 M 674 192 L 674 320 L 546 320 L CP S GR GR % TEXT NP 0 SG GS 1 W 610 240 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (signal) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (signal) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (handler) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (handler) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (thread) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (thread) SH GR GR % BOX 0 SG GS 10 SM GS NP 693 192 M 821 192 L 821 320 L 693 320 L CP S GR GR % TEXT NP 0 SG GS 1 W 757 240 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (current) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (current) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (state server) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (state server) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (thread) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (thread) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 514 336 M 514 353 L 0 -32 atan DU cos 8.000 MU 482 exch SU exch sin 8.000 MU 353 exch SU L TGSM 1 W S GR GS TGSM NP 482 353 8.000 3.000 -32 0 TGAT 1 SG CP F 0 SG NP 482 353 8.000 3.000 -32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 346 352 M 313 352 L -17 0 atan DU cos 8.000 MU 313 exch SU exch sin 8.000 MU 335 exch SU L TGSM 1 W S GR GS TGSM NP 313 335 8.000 3.000 0 -17 TGAT 1 SG CP F 0 SG NP 313 335 8.000 3.000 0 -17 TGAT CP F GR % TEXT NP 0 SG GS 1 W 542 80 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (event list and cache) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (event list and cache) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 469 215 M -122 0 atan DU cos 8.000 MU exch sin 8.000 MU RM -122 0 atan DU cos 8.000 MU 469 exch SU exch sin 8.000 MU 93 exch SU L TGSM 1 W S GR GS TGSM NP 469 215 8.000 3.000 0 122 TGAT 1 SG CP F 0 SG NP 469 215 8.000 3.000 0 122 TGAT CP F GR GS TGSM NP 469 93 8.000 3.000 0 -122 TGAT 1 SG CP F 0 SG NP 469 93 8.000 3.000 0 -122 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 601 92 M 123 0 atan DU cos 8.000 MU exch sin 8.000 MU RM 123 0 atan DU cos 8.000 MU 601 exch SU exch sin 8.000 MU 215 exch SU L TGSM 1 W S GR GS TGSM NP 601 92 8.000 3.000 0 -123 TGAT 1 SG CP F 0 SG NP 601 92 8.000 3.000 0 -123 TGAT CP F GR GS TGSM NP 601 215 8.000 3.000 0 123 TGAT 1 SG CP F 0 SG NP 601 215 8.000 3.000 0 123 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS [8 8] 0 SD NP 762 324 M 678 492 L 0 -242 atan DU cos 8.000 MU 436 exch SU exch sin 8.000 MU 492 exch SU L TGSM 1 W S [] 0 SD GR GS TGSM NP 436 492 8.000 3.000 -242 0 TGAT 1 SG CP F 0 SG NP 436 492 8.000 3.000 -242 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS [8 8] 0 SD NP 168 505 M 147 505 L -215 0 atan DU cos 8.000 MU 147 exch SU exch sin 8.000 MU 290 exch SU L TGSM 1 W S [] 0 SD GR GS TGSM NP 147 290 8.000 3.000 0 -215 TGAT 1 SG CP F 0 SG NP 147 290 8.000 3.000 0 -215 TGAT CP F GR % BOX 0 SG GS 10 SM GS NP 411 42 M 693 42 L 693 106 L 411 106 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 403 39 M 701 39 L 701 109 L 403 109 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS [8 8] 0 SD NP 266 328 M 487 480 L 0 -49 atan DU cos 8.000 MU 438 exch SU exch sin 8.000 MU 480 exch SU L TGSM 1 W S [] 0 SD GR GS TGSM NP 438 480 8.000 3.000 -49 0 TGAT 1 SG CP F 0 SG NP 438 480 8.000 3.000 -49 0 TGAT CP F GR % RCBOX 0 SG GS GS NP 417 470 M 433 470 433 504 16 AR 433 488 L 433 504 303 504 16 AR 319 504 L 303 504 303 470 16 AR 303 486 L 303 470 433 470 16 AR CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 337 471 M 337 505 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 367 470 M 367 504 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 400 470 M 400 505 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 352 335 M 480 335 L 480 367 L 352 367 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 352 335 M 352 367 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 384 335 M 384 367 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 416 335 M 416 367 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 448 335 M 448 367 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS [8 8] 0 SD NP 728 516 M 0 -528 atan DU cos 8.000 MU 200 exch SU exch sin 8.000 MU 516 exch SU L TGSM 1 W S [] 0 SD GR GS TGSM NP 200 516 8.000 3.000 -528 0 TGAT 1 SG CP F 0 SG NP 200 516 8.000 3.000 -528 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 578 531 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (X event generated) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (X event generated) SH GR GR % TEXT NP 0 SG GS 1 W 644 404 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (new user) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (new user) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (entered the) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (entered the) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (group) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (group) SH GR GR % TEXT NP 0 SG GS 1 W 771 552 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (X event queue) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (X event queue) SH GR GR % POLY/OPEN-SPLINE 0 SG GS [12 4] 0 SD NP 300 489 M 0 -95 atan DU cos 8.000 MU 205 exch SU exch sin 8.000 MU 489 exch SU L TGSM 1 W S [] 0 SD GR GS TGSM NP 205 489 8.000 3.000 -95 0 TGAT 1 SG CP F 0 SG NP 205 489 8.000 3.000 -95 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 487 435 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (new data) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (new data) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS ( available) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS ( available) SH GR GR % TEXT NP 0 SG GS 1 W 184 436 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (select) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (select) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (system) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (system) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (call) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (call) SH GR GR % BOX 0 SG GS 10 SM GS NP 743 419 M 785 419 L 785 531 L 743 531 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 743 438 M 787 438 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 742 463 M 786 463 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 742 486 M 786 486 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 742 507 M 786 507 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 184 476 M 184 521 L TGSM 7 W S 1 W GR % POLY/OPEN-SPLINE 0 SG GS NP 110 184 M 124 170 L 231 170 L 241 161 L 250 171 L 334 171 L 347 186 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 236 156 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (tgwb threads) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (tgwb threads) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 411 184 M 422 169 L 748 169 L 759 159 L 769 169 L 805 169 L 816 183 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 716 154 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (rmcast internal threads) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (rmcast internal threads) SH GR GR % ARC 0 SG GS GS NP 575 293 60 60 145 40 TGAR S GR GR GS TGSM NP 625 327 8.000 3.000 67 -99 TGAT 1 SG CP F 0 SG NP 625 327 8.000 3.000 67 -99 TGAT CP F GR % TEXT NP 0 SG GS 1 W 598 369 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (send signals to) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (send signals to) SH GR GR % BOX 0 SG GS 10 SM GS NP 47 5 M 883 5 L 883 560 L 47 560 L CP S GR GR % TEXT NP 0 SG GS 1 W 465 30 M GS GS 0 /Courier-Bold FF [34 0 0 -34 0 0] MS (Tangram II Whiteboard Architechture) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (Tangram II Whiteboard Architechture) SH GR GR % BOX 0 SG GS 10 SM GS NP 235 365 M 271 365 L 271 445 L 235 445 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 235 384 M 273 384 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 234 405 M 272 405 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 234 425 M 272 425 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 251 325 M 35 0 atan DU cos 8.000 MU 251 exch SU exch sin 8.000 MU 360 exch SU L TGSM 1 W S GR GS TGSM NP 251 360 8.000 3.000 0 35 TGAT 1 SG CP F 0 SG NP 251 360 8.000 3.000 0 35 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 252 452 M 252 462 L 0 -28 atan DU cos 8.000 MU 224 exch SU exch sin 8.000 MU 462 exch SU L TGSM 1 W S GR GS TGSM NP 224 462 8.000 3.000 -28 0 TGAT 1 SG CP F 0 SG NP 224 462 8.000 3.000 -28 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 415 382 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (message queue) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (message queue) SH GR GR % TEXT NP 0 SG GS 1 W 276 411 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (whiteboard) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (message) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (buffer) SH GR GR % TEXT NP 0 SG GS 1 W 340 462 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (pipe) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 228 100 M 88 168 atan DU cos 8.000 MU 396 exch SU exch sin 8.000 MU 188 exch SU L TGSM 1 W S GR GS TGSM NP 396 188 8.000 3.000 168 88 TGAT 1 SG CP F 0 SG NP 396 188 8.000 3.000 168 88 TGAT CP F GR % BOX 0 SG NP 400 190 M 413 190 L 413 196 L 400 196 L CP F GS 10 SM GS NP 400 190 M 413 190 L 413 196 L 400 196 L CP S GR GR % TEXT NP 0 SG GS 1 W 403 208 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (udp) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (socket) SH GR GR % BOX 0 SG NP 808 190 M 821 190 L 821 196 L 808 196 L CP F GS 10 SM GS NP 808 190 M 821 190 L 821 196 L 808 196 L CP S GR GR % TEXT NP 0 SG GS 1 W 765 210 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (tcp) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (socket) SH GR GR % TEXT NP 0 SG GS 1 W 143 72 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (external) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS ( data) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 245 75 M 220 79 L 238 87 L 214 86 L 225 97 L 201 91 L 202 104 L 186 95 L 177 106 L 169 95 L 153 104 L 154 91 L 130 97 L 141 86 L 117 87 L 135 79 L 110 75 L 135 70 L 117 62 L 141 63 L 130 52 L 154 58 L 153 45 L 169 54 L 177 43 L 186 54 L 202 45 L 201 58 L 225 52 L 214 63 L 238 62 L 220 70 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 178 80 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % TEXT NP 0 SG GS 1 W 805 97 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (new) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (new) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (member) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (member) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 874 101 M 849 105 L 867 113 L 843 112 L 854 123 L 830 117 L 831 130 L 815 121 L 806 132 L 798 121 L 782 130 L 783 117 L 759 123 L 770 112 L 746 113 L 764 105 L 739 101 L 764 96 L 746 88 L 770 89 L 759 78 L 783 84 L 782 71 L 798 80 L 806 69 L 815 80 L 831 71 L 830 84 L 854 78 L 843 89 L 867 88 L 849 96 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 807 106 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % POLY/OPEN-SPLINE 0 SG GS NP 837 125 M 61 -19 atan DU cos 8.000 MU 818 exch SU exch sin 8.000 MU 186 exch SU L TGSM 1 W S GR GS TGSM NP 818 186 8.000 3.000 -19 61 TGAT 1 SG CP F 0 SG NP 818 186 8.000 3.000 -19 61 TGAT CP F GR % TEXT NP 0 SG GS 1 W 291 77 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (control) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS ( pckts) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 389 80 M 364 84 L 382 92 L 358 91 L 369 102 L 345 96 L 346 109 L 330 100 L 321 111 L 313 100 L 297 109 L 298 96 L 274 102 L 285 91 L 261 92 L 279 84 L 254 80 L 279 75 L 261 67 L 285 68 L 274 57 L 298 63 L 297 50 L 313 59 L 321 48 L 330 59 L 346 50 L 345 63 L 369 57 L 358 68 L 382 67 L 364 75 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 322 85 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % POLY/OPEN-SPLINE 0 SG GS NP 409 188 M -76 -72 atan DU cos 8.000 MU 337 exch SU exch sin 8.000 MU 112 exch SU L TGSM 1 W S GR GS TGSM NP 337 112 8.000 3.000 -72 -76 TGAT 1 SG CP F 0 SG NP 337 112 8.000 3.000 -72 -76 TGAT CP F GR % BOX 0 SG NP 91 190 M 104 190 L 104 196 L 91 196 L CP F GS 10 SM GS NP 91 190 M 104 190 L 104 196 L 91 196 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 134 102 M 88 -34 atan DU cos 8.000 MU exch sin 8.000 MU RM 100 190 L TGSM 1 W S GR GS TGSM NP 134 102 8.000 3.000 34 -88 TGAT 1 SG CP F 0 SG NP 134 102 8.000 3.000 34 -88 TGAT CP F GR % TEXT NP 0 SG GS 1 W 94 212 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (udp) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (socket) SH GR GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Tue May 21 10:36:49 2002 %%DocumentFonts: Courier-Bold %%+ Courier %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/layers.eps0000644000076400007640000000775510122646341020333 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 34 666 153 757 %%Title: layers %%CreationDate: Thu May 9 14:06:29 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 51 dict def tgifdict begin /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 34 666 153 757 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % BOX 0 SG GS 10 SM GS NP 64 64 M 270 64 L 270 221 L 64 221 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS 64 98 TR [1.609 0.000 0.000 1.000 0 0] CO 64 NE 98 NE TR GS NP 64 98 M 192 98 L TGSM 1 W S GR GR % POLY/OPEN-SPLINE 0 SG GS 64 126 TR [1.609 0.000 0.000 1.000 0 0] CO 64 NE 126 NE TR GS NP 64 126 M 192 126 L TGSM 1 W S GR GR % POLY/OPEN-SPLINE 0 SG GS 64 192 TR [1.609 0.000 0.000 1.000 0 0] CO 64 NE 192 NE TR GS NP 64 192 M 192 192 L TGSM 1 W S GR GR % TEXT NP 0 SG GS 1 W 165 84 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (whiteboard) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (whiteboard) SH GR GR % TEXT NP 0 SG GS 1 W 166 148 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (segmentation) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (segmentation) SH GR GR % TEXT NP 0 SG GS 1 W 165 181 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (reliable multicast) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (reliable multicast) SH GR GR % TEXT NP 0 SG GS 1 W 165 212 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (IP multicast) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (IP multicast) SH GR GR % POLY/OPEN-SPLINE 0 SG GS 65 159 TR [1.609 0.000 0.000 1.000 0 0] CO 65 NE 159 NE TR GS NP 65 159 M 193 159 L TGSM 1 W S GR GR % TEXT NP 0 SG GS 1 W 167 117 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (global consistency) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (global consistency) SH GR GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Thu May 9 14:06:29 2002 %%DocumentFonts: Courier %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/layers.obj0000644000076400007640000000564411077130422020307 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,0,0,0,16,0,9,1,1,0,0,0,0,1,1,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,0,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/layers.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 50971, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 40569, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). page(1,"",1,''). box('black','',64,64,270,221,0,1,1,0,0,0,0,0,0,'1',0,[ ]). poly('black','',2,[ 64,98,192,98],0,1,1,1,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 64,98,64,98,192,98,1609.38,0,0,1000,0,0],[ ]). poly('black','',2,[ 64,126,192,126],0,1,1,4,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 64,126,64,126,192,126,1609.38,0,0,1000,0,0],[ ]). poly('black','',2,[ 64,192,192,192],0,1,1,5,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 64,192,64,192,192,192,1609.38,0,0,1000,0,0],[ ]). text('black',165,71,1,1,1,90,16,10,13,3,0,0,0,0,2,90,16,0,0,"",0,0,0,0,84,'',[ minilines(90,16,0,0,1,0,0,[ mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, "whiteboard")]) ]) ])]). text('black',166,135,1,1,1,108,16,13,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,148,'',[ minilines(108,16,0,0,1,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "segmentation")]) ]) ])]). text('black',165,168,1,1,1,162,16,16,13,3,0,0,0,0,2,162,16,0,0,"",0,0,0,0,181,'',[ minilines(162,16,0,0,1,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,162,13,3,0,-2,0,0,0,0,0, "reliable multicast")]) ]) ])]). text('black',165,199,1,1,1,108,16,19,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,212,'',[ minilines(108,16,0,0,1,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-2,0,0,0,0,0, "IP multicast")]) ]) ])]). poly('black','',2,[ 65,159,193,159],0,1,1,23,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 65,159,65,159,193,159,1609.38,0,0,1000,0,0],[ ]). text('black',167,104,1,1,1,162,16,25,13,3,0,0,0,0,2,162,16,0,0,"",0,0,0,0,117,'',[ minilines(162,16,0,0,1,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,162,13,3,0,-1,0,0,0,0,0, "global consistency")]) ]) ])]). tgif-QPL-4.2.5/rmcast/doc/manual/flowcontrol.eps0000644000076400007640000007450710122646341021403 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 107 361 471 772 %%Title: flowcontrol %%CreationDate: Tue May 21 09:42:57 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 56 dict def tgifdict begin /tgifarrowtipdict 8 dict def tgifarrowtipdict /mtrx matrix put /TGAT % tgifarrowtip { tgifarrowtipdict begin /dy exch def /dx exch def /h exch def /w exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate dy dx atan rotate 0 0 moveto w neg h lineto w neg h neg lineto savematrix setmatrix end } def /tgifarcdict 8 dict def tgifarcdict /mtrx matrix put /TGAN % tgifarcn { tgifarcdict begin /endangle exch def /startangle exch def /yrad exch def /xrad exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate xrad yrad scale 0 0 1 startangle endangle arc savematrix setmatrix end } def /TGAR % tgifarc { tgifarcdict begin /endangle exch def /startangle exch def /yrad exch def /xrad exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate xrad yrad scale 0 0 1 startangle endangle arcn savematrix setmatrix end } def /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 107 361 471 772 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % POLY/OPEN-SPLINE 0 SG GS [20 4 4 4] 0 SD NP 192 424 M 836 424 L TGSM 1 W S [] 0 SD GR % TEXT NP 0 SG GS 223 279 TR [-0.000 -1.000 1.000 -0.000 -24 -8] CO 223 NE 279 NE TR GR GS 1 W 223 279 TR [-0.000 -1.000 1.000 -0.000 -24 -8] CO 0 12 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (Naive Approach) SH GR GR % BOX GS 234 289 TR [-0.000 -1.000 1.000 -0.000 -38 -12] CO 234 NE 289 NE TR 0 SG GS 10 SM GS NP 234 289 M 370 289 L 370 314 L 234 314 L CP TGSM S GR GR GR % TEXT NP 0 SG GS 234 734 TR [-0.000 -1.000 1.000 -0.000 -24 -8] CO 234 NE 734 NE TR GR GS 1 W 234 734 TR [-0.000 -1.000 1.000 -0.000 -24 -8] CO 0 12 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (Approach with Flow Control) SH GR GR % BOX GS 242 631 TR [-0.000 -1.824 1.000 -0.000 -38 100] CO 242 NE 631 NE TR 0 SG GS 10 SM GS NP 242 631 M 378 631 L 378 656 L 242 656 L CP TGSM S GR GR GR % POLY/OPEN-SPLINE 0 SG GS 504 62 TR [1.000 0.000 0.000 1.107 0 0] CO 504 NE 62 NE TR GS NP 505 62 M 505 379 L TGSM 2 W S 1 W GR GR % POLY/OPEN-SPLINE 0 SG GS 665 61 TR [1.000 0.000 0.000 1.100 0 0] CO 665 NE 61 NE TR GS NP 666 61 M 666 380 L TGSM 2 W S 1 W GR GR % POLY/OPEN-SPLINE 0 SG GS NP 505 103 M 665 151 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 117 M 746 117 L 746 135 L 676 135 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 690 117 M 690 135 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 117 M 690 117 L 690 135 L 676 135 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 690 117 M 704 117 L 704 135 L 690 135 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 704 117 M 718 117 L 718 135 L 704 135 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 718 117 M 732 117 L 732 135 L 718 135 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 732 117 M 746 117 L 746 135 L 732 135 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 505 156 M 665 204 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 506 176 M 666 224 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 504 197 M 664 245 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 504 221 M 664 269 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 193 M 746 193 L 746 211 L 676 211 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 690 193 M 690 211 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 193 M 690 193 L 690 211 L 676 211 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 690 193 M 704 193 L 704 211 L 690 211 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 704 193 M 718 193 L 718 211 L 704 211 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 718 193 M 732 193 L 732 211 L 718 211 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 732 193 M 746 193 L 746 211 L 732 211 L CP S GR GR % TEXT NP 0 SG GS 1 W 679 207 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (1) SH GR GR % TEXT NP 0 SG GS 1 W 693 207 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (2) SH GR GR % TEXT NP 0 SG GS 1 W 707 207 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (3) SH GR GR % TEXT NP 0 SG GS 1 W 721 207 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (4) SH GR GR % TEXT NP 0 SG GS 1 W 735 207 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (5) SH GR GR % BOX 0 SG GS 10 SM GS NP 676 217 M 746 217 L 746 235 L 676 235 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 690 217 M 690 235 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 217 M 690 217 L 690 235 L 676 235 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 690 217 M 704 217 L 704 235 L 690 235 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 704 217 M 718 217 L 718 235 L 704 235 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 718 217 M 732 217 L 732 235 L 718 235 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 732 217 M 746 217 L 746 235 L 732 235 L CP S GR GR % TEXT NP 0 SG GS 1 W 679 231 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (6) SH GR GR % TEXT NP 0 SG GS 1 W 693 231 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (2) SH GR GR % TEXT NP 0 SG GS 1 W 707 231 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (3) SH GR GR % TEXT NP 0 SG GS 1 W 721 231 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (4) SH GR GR % TEXT NP 0 SG GS 1 W 736 230 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (5) SH GR GR % BOX 0 SG GS 10 SM GS NP 676 241 M 746 241 L 746 259 L 676 259 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 690 241 M 690 259 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 241 M 690 241 L 690 259 L 676 259 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 690 241 M 704 241 L 704 259 L 690 259 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 704 241 M 718 241 L 718 259 L 704 259 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 718 241 M 732 241 L 732 259 L 718 259 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 732 241 M 746 241 L 746 259 L 732 259 L CP S GR GR % TEXT NP 0 SG GS 1 W 679 255 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (6) SH GR GR % TEXT NP 0 SG GS 1 W 693 255 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (7) SH GR GR % TEXT NP 0 SG GS 1 W 707 255 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (3) SH GR GR % TEXT NP 0 SG GS 1 W 721 255 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (4) SH GR GR % TEXT NP 0 SG GS 1 W 734 255 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (5) SH GR GR % BOX 0 SG GS 10 SM GS NP 676 264 M 746 264 L 746 282 L 676 282 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 690 264 M 690 282 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 264 M 690 264 L 690 282 L 676 282 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 690 264 M 704 264 L 704 282 L 690 282 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 704 264 M 718 264 L 718 282 L 704 282 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 718 264 M 732 264 L 732 282 L 718 282 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 732 264 M 746 264 L 746 282 L 732 282 L CP S GR GR % TEXT NP 0 SG GS 1 W 679 278 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (6) SH GR GR % TEXT NP 0 SG GS 1 W 693 278 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (7) SH GR GR % TEXT NP 0 SG GS 1 W 707 278 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (8) SH GR GR % TEXT NP 0 SG GS 1 W 721 278 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (4) SH GR GR % TEXT NP 0 SG GS 1 W 735 278 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (5) SH GR GR % BOX 0 SG GS 10 SM GS NP 676 143 M 746 143 L 746 161 L 676 161 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 690 143 M 690 161 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 143 M 690 143 L 690 161 L 676 161 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 690 143 M 704 143 L 704 161 L 690 161 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 704 143 M 718 143 L 718 161 L 704 161 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 718 143 M 732 143 L 732 161 L 718 161 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 732 143 M 746 143 L 746 161 L 732 161 L CP S GR GR % TEXT NP 0 SG GS 1 W 680 157 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (1) SH GR GR % POLY/OPEN-SPLINE 0 SG GS 276 59 TR [1.000 0.000 0.000 1.032 0 0] CO 276 NE 59 NE TR GS NP 276 59 M 276 399 L TGSM 2 W S 1 W GR GR % POLY/OPEN-SPLINE 0 SG GS 437 58 TR [1.000 0.000 0.000 1.006 0 0] CO 437 NE 58 NE TR GS NP 437 58 M 437 407 L TGSM 2 W S 1 W GR GR % POLY/OPEN-SPLINE 0 SG GS NP 276 68 M 338 86 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 327 94 M 344 78 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 335 76 M 342 99 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 275 105 M 337 123 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 326 131 M 343 115 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 334 113 M 341 136 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 277 166 M 339 184 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 328 192 M 345 176 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 336 174 M 343 197 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 276 200 M 436 242 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 437 250 M 276 280 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 261 52 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (sender) SH GR GR % TEXT NP 0 SG GS 1 W 398 49 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (receiver) SH GR GR % TEXT NP 0 SG GS 1 W 484 49 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (sender) SH GR GR % TEXT NP 0 SG GS 1 W 626 51 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (receiver) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 666 305 M 505 335 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 664 326 M 503 356 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 665 346 M 504 376 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 438 343 M 277 373 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 436 367 M 275 397 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 370 136 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 370 152 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 370 169 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 592 147 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 592 163 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 592 180 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 506 73 M 568 91 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 557 99 M 574 83 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 565 81 M 572 104 L TGSM 1 W S GR % TEXT NP 0 SG GS 734 378 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 734 NE 378 NE TR GR GS 1 W 734 378 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nack \(0\)) SH GR GR % TEXT NP 0 SG GS 735 399 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 735 NE 399 NE TR GR GS 1 W 735 399 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nack \(1\)) SH GR GR % TEXT NP 0 SG GS 736 419 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 736 NE 419 NE TR GR GS 1 W 736 419 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nack \(2\)) SH GR GR % TEXT NP 0 SG GS 518 65 TR [0.974 0.225 -0.225 0.974 0 -13] CO 518 NE 65 NE TR GR GS 1 W 518 65 TR [0.974 0.225 -0.225 0.974 0 -13] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retr \(0\)) SH GR GR % TEXT NP 0 SG GS 513 101 TR [0.974 0.225 -0.225 0.974 0 -13] CO 513 NE 101 NE TR GR GS 1 W 513 101 TR [0.974 0.225 -0.225 0.974 0 -13] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retr \(1\)) SH GR GR % TEXT NP 0 SG GS 515 154 TR [0.974 0.225 -0.225 0.974 0 -13] CO 515 NE 154 NE TR GR GS 1 W 515 154 TR [0.974 0.225 -0.225 0.974 0 -13] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retr \(5\)) SH GR GR % TEXT NP 0 SG GS 517 177 TR [0.966 0.259 -0.259 0.966 0 -15] CO 517 NE 177 NE TR GR GS 1 W 517 177 TR [0.966 0.259 -0.259 0.966 0 -15] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retr \(6\)) SH GR GR % TEXT NP 0 SG GS 516 198 TR [0.966 0.259 -0.259 0.966 0 -15] CO 516 NE 198 NE TR GR GS 1 W 516 198 TR [0.966 0.259 -0.259 0.966 0 -15] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retr \(7\)) SH GR GR % TEXT NP 0 SG GS 516 221 TR [0.966 0.259 -0.259 0.966 0 -15] CO 516 NE 221 NE TR GR GS 1 W 516 221 TR [0.966 0.259 -0.259 0.966 0 -15] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retr \(8\)) SH GR GR % TEXT NP 0 SG GS 301 67 TR [0.978 0.208 -0.208 0.978 0 -12] CO 301 NE 67 NE TR GR GS 1 W 301 67 TR [0.978 0.208 -0.208 0.978 0 -12] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (data \(0\)) SH GR GR % TEXT NP 0 SG GS 296 101 TR [0.978 0.208 -0.208 0.978 0 -12] CO 296 NE 101 NE TR GR GS 1 W 296 101 TR [0.978 0.208 -0.208 0.978 0 -12] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (data \(1\)) SH GR GR % TEXT NP 0 SG GS 293 160 TR [0.974 0.225 -0.225 0.974 0 -13] CO 293 NE 160 NE TR GR GS 1 W 293 160 TR [0.974 0.225 -0.225 0.974 0 -13] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (data \(8\)) SH GR GR % TEXT NP 0 SG GS 288 199 TR [0.978 0.208 -0.208 0.978 0 -12] CO 288 NE 199 NE TR GR GS 1 W 288 199 TR [0.978 0.208 -0.208 0.978 0 -12] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (refresh \(8\)) SH GR GR % TEXT NP 0 SG GS 1 W 359 292 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 359 308 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 359 325 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 493 326 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 493 NE 326 NE TR GR GS 1 W 493 326 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nack \(0\)) SH GR GR % TEXT NP 0 SG GS 509 413 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 509 NE 413 NE TR GR GS 1 W 509 413 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nack \(7\)) SH GR GR % TEXT NP 0 SG GS 510 439 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 510 NE 439 NE TR GR GS 1 W 510 439 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nack \(8\)) SH GR GR % ARC 0 SG GS GS NP 467 91 51 51 119 67 TGAR S GR GR GS TGSM NP 493 135 8.000 3.000 88 -51 TGAT 1 SG CP F 0 SG NP 493 135 8.000 3.000 88 -51 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS 505 475 TR [1.000 0.000 0.000 1.018 0 0] CO 505 NE 475 NE TR GS NP 505 475 M 505 757 L TGSM 2 W S 1 W GR GR % POLY/OPEN-SPLINE 0 SG GS 666 474 TR [1.000 0.000 0.000 1.007 0 0] CO 666 NE 474 NE TR GS NP 666 474 M 666 759 L TGSM 2 W S 1 W GR GR % POLY/OPEN-SPLINE 0 SG GS NP 505 522 M 665 570 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 536 M 746 536 L 746 554 L 676 554 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 690 536 M 690 554 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 536 M 690 536 L 690 554 L 676 554 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 690 536 M 704 536 L 704 554 L 690 554 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 704 536 M 718 536 L 718 554 L 704 554 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 718 536 M 732 536 L 732 554 L 718 554 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 732 536 M 746 536 L 746 554 L 732 554 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 505 575 M 665 623 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 616 M 746 616 L 746 634 L 676 634 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 690 616 M 690 634 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 616 M 690 616 L 690 634 L 676 634 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 690 616 M 704 616 L 704 634 L 690 634 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 704 616 M 718 616 L 718 634 L 704 634 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 718 616 M 732 616 L 732 634 L 718 634 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 732 616 M 746 616 L 746 634 L 732 634 L CP S GR GR % TEXT NP 0 SG GS 1 W 679 630 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (1) SH GR GR % TEXT NP 0 SG GS 1 W 693 630 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (2) SH GR GR % TEXT NP 0 SG GS 1 W 707 630 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (3) SH GR GR % TEXT NP 0 SG GS 1 W 721 630 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (4) SH GR GR % BOX 0 SG GS 10 SM GS NP 676 557 M 746 557 L 746 575 L 676 575 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 690 557 M 690 575 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 676 557 M 690 557 L 690 575 L 676 575 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 690 557 M 704 557 L 704 575 L 690 575 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 704 557 M 718 557 L 718 575 L 704 575 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 718 557 M 732 557 L 732 575 L 718 575 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 732 557 M 746 557 L 746 575 L 732 575 L CP S GR GR % TEXT NP 0 SG GS 1 W 680 571 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (1) SH GR GR % POLY/OPEN-SPLINE 0 SG GS 276 472 TR [1.000 0.000 0.000 1.029 0 0] CO 276 NE 472 NE TR GS NP 276 472 M 276 751 L TGSM 2 W S 1 W GR GR % POLY/OPEN-SPLINE 0 SG GS NP 437 471 M 437 758 L TGSM 2 W S 1 W GR % POLY/OPEN-SPLINE 0 SG GS NP 276 481 M 338 499 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 327 507 M 344 491 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 335 489 M 342 512 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 275 515 M 337 533 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 326 541 M 343 525 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 334 523 M 341 546 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 277 579 M 339 597 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 328 605 M 345 589 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 336 587 M 343 610 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 276 613 M 436 655 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 437 680 M 276 710 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 261 465 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (sender) SH GR GR % TEXT NP 0 SG GS 1 W 398 462 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (receiver) SH GR GR % TEXT NP 0 SG GS 1 W 484 462 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (sender) SH GR GR % TEXT NP 0 SG GS 1 W 626 464 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (receiver) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 666 662 M 505 692 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 301 535 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 301 551 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 301 568 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 594 563 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 594 579 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % TEXT NP 0 SG GS 1 W 594 596 M GS 0 SG /Courier-Bold FF [34 0 0 -34 0 0] MS (.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 506 491 M 568 509 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 557 517 M 574 501 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 565 499 M 572 522 L TGSM 1 W S GR % TEXT NP 0 SG GS 722 736 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 722 NE 736 NE TR GR GS 1 W 722 736 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nack \(0\)) SH GR GR % TEXT NP 0 SG GS 485 756 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 485 NE 756 NE TR GR GS 1 W 485 756 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nack \(0,1,2,3,4\)) SH GR GR % TEXT NP 0 SG GS 519 484 TR [0.978 0.208 -0.208 0.978 0 -12] CO 519 NE 484 NE TR GR GS 1 W 519 484 TR [0.978 0.208 -0.208 0.978 0 -12] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retr \(0\)) SH GR GR % TEXT NP 0 SG GS 517 522 TR [0.970 0.242 -0.242 0.970 0 -14] CO 517 NE 522 NE TR GR GS 1 W 517 522 TR [0.970 0.242 -0.242 0.970 0 -14] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retr \(1\)) SH GR GR % TEXT NP 0 SG GS 513 573 TR [0.970 0.242 -0.242 0.970 0 -14] CO 513 NE 573 NE TR GR GS 1 W 513 573 TR [0.970 0.242 -0.242 0.970 0 -14] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retr \(4\)) SH GR GR % TEXT NP 0 SG GS 302 479 TR [0.978 0.208 -0.208 0.978 0 -12] CO 302 NE 479 NE TR GR GS 1 W 302 479 TR [0.978 0.208 -0.208 0.978 0 -12] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (data \(0\)) SH GR GR % TEXT NP 0 SG GS 295 511 TR [0.978 0.208 -0.208 0.978 0 -12] CO 295 NE 511 NE TR GR GS 1 W 295 511 TR [0.978 0.208 -0.208 0.978 0 -12] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (data \(1\)) SH GR GR % TEXT NP 0 SG GS 290 572 TR [0.978 0.208 -0.208 0.978 0 -12] CO 290 NE 572 NE TR GR GS 1 W 290 572 TR [0.978 0.208 -0.208 0.978 0 -12] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (data \(8\)) SH GR GR % TEXT NP 0 SG GS 289 611 TR [0.978 0.208 -0.208 0.978 0 -12] CO 289 NE 611 NE TR GR GS 1 W 289 611 TR [0.978 0.208 -0.208 0.978 0 -12] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (refresh \(8\)) SH GR GR % ARC 0 SG GS GS NP 469 505 51 51 119 67 TGAR S GR GR GS TGSM NP 495 549 8.000 3.000 88 -51 TGAT 1 SG CP F 0 SG NP 495 549 8.000 3.000 88 -51 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 667 367 M 506 397 L TGSM 1 W S GR % TEXT NP 0 SG GS 738 440 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 738 NE 440 NE TR GR GS 1 W 738 440 TR [0.988 -0.156 0.156 0.988 -203 -68] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nack \(3\)) SH GR GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Tue May 21 09:42:57 2002 %%DocumentFonts: Courier %%+ Courier-Bold %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/logs.tbz20000644000076400007640000001240310122646341020054 0ustar williamwilliamBZh91AY&SY@k PDÿ„ę Âÿđ țÿÿș`>ûÜŠ qđ  ŒúîH€{ê4Ôc"‰Tva–Á ­2 Š‚„E*„č1;ńèȘžÈ'è©ć4ŃŠ„•% i€& Ą„ÂiĄ€L©ïS)F€3H€R*€M2h©IšhŠaM=2iêAêhzF!„Țš"MÒ§èŁÔژMÔ2@Phż“‹SđĒa¶"8źłćVSĂfŽHJˆ”""œóú4ôŚ5ĘUźé„È"òdT X­qUJ…Æ’X°"ƒĂČq4v‰„!B„!B„!B„!B„!ÏkZ-«PŃŁF4h‘B„#;‘à’Ż%ËŹ–ä©AȚAšBGz’;ےJŚŽű$’”‚Gy*Pw@ÌÆÄ•«’;ÈHïŽòT ï ÒA$—ĄfŠuȘŰł0Í4 Đ€ê“ N©0€Â’ÔšSł“ł0€â“ŠM©0ÁHo{»F•PqIć'”–€ê“íIô€úRaIJ}{äúÎçÒ©”'TœS|ÛKă[ô”¶c~úï«e›,ÙfË6YČÙÎfóv–if™='§œì{ÒzOIé='€ôžžőúç§«Ő%ŠfÓf–ÎŒäœ-«Òș«i›LÚfÓ6›ZÎo7i“ÒzOIéî{Äôž“2bOI‰=%Êő•= ê—=cۚž­Tôőv§€ôșȘœ’Bnœ+Ś=$“ÒvOOUŐWȘI='dôž‚âú‹ê^.U…ÜŻ”!^Ç”='€Äž˜ŹUëœ.ȘŹMb§$䛓ZjCÆ«•>Ié.wîțź}I‰_<Ÿ@úRúÔܝ““ZâòȘÍâzJ˜ŸòïS—_I'dą'„BI$M:čß]0ÂŰi$‰D󻊩%U(‰,șUU$ë’t'k„< ǖqWìçNźÜtۋ­ÿÆhtÍđCfr{ut*źFÌóSXú{™čœ·Ž­u êȘëŁu·ăÊÓGLcSi„ÏeNmPÂ'wC»Û·Żƒ§«Țy8pRëæíŸ2Îèt…vXcŠBȘÜźÙÌ©Ț7ƒŸšÓE].{o1^qéĆ "]‡șSÌ2B`ÍÒ ©në“]ŃVșòÆău”š3—Láșr €ôhŃŒ‡kŁ^ië‹4™žĄ„›ï{°m9j…gm/cŐ|ÖÔ”%Ąj·x¶›I5Mqń$ôÆÙ*IR9*„Ö©I U ‚hm?Éù @Ç$’I$@$’I" @ $‘ "I$‘ " @‚I$’I @ $‘III$ˆ$ˆ$ˆ$ˆ ’ @ "I$’I$’I$@†±ík”>g7/ëëX5ŒfMo;ѝÍéVț” [Ü)bčï0@zÏz«ÏÁPöæÜȚŃÙÆ©żȘ^9{Ę46Đ+-őŚÛJK±|S.v«`»«Ç].d5.ÏNÜï *ç$vń'¶roK#sUqșŹœÛ镎óžŒć}Á4dÍêêŸٗ7–M"”Ržš·Wč « yfecSËuI|ś_vá7WR'­VMVŠTń&Tęń$“>Hh €! @€B B@! @!  ˆ‚öńȘ•Wń+߉ŠșŒ;ŸƒË2âS=ÓryșŹæAJŸ±«[3{­ö`ŚŁ°ćj)â\Œ—eŠ2W3Êë«q”r%SS{žÙÌÌŚ¶oMާ gXHfIì@ÉÚóMEQ$æ§òÆZ/VXhïz“‡À}ƒÌŠâA„‘t‰")YÒìegk3â}š¶…§‰á}o©änlËUÚŚ0§ï{Öœ­ûȚòzÆb’©!>?žŚsìcĘűJSÁÖŠ'Źa»tʁWYÜ3V_:•4Čfy oSÜŒf…\í,W–ˆ˜ˆIXȚÔ·Š‹Š•1j1ȚT–xJ-â’ÌŽ]œ˜țïÚ€©Ä„}[ÒôÀæȘK…+‹$@üËaĂb`Ê}Ynnê+0 Š·YVë­ŁșYŠhÏCɌkÔfźâĆZŠ‚–D3¶ZT%ń‰0A‹Őqӆś\…Ò0€Jb VőJƆȘM€C˜wRź4Úą+¶p¶”MÍËoŻ…^CgS—œ1 <‚w »$‘ ÎÄĐXQó!ŹÈ JšÆV3ŒTW”šHäKȘ>:YšùڗŃwČŽö`y|Ę>1!êÊK”b¶(>dXÂç.śžÇr&ÖÔfۘn8l\’æ$XȚ0DD^"!Zț„âü@'Ù_”Ž5cçűC;5ČùiÉ·%…F^|@z«œȚ“ÊBw^Ł•NÊË­|tÙ©/†<ŹȘđ"ú‘ï݌™żżŠ"<ü~1‹0EÔa$1rBËș„$BfŽJUI… J%ÊR„$ÀN!6ŽÌȚűŹÉ[RÓŽ%X‰ź a kbT‰šIą…Ș ÚćĘÁj‘Ș‘ź șCJ…B|yœ@+HҊE—CŒDC"žęéIŽ“UŸčă~;]B·ò•}Ž(J© Ž-4GÌ`Uh[«’űż* ïQ¶3ÂÔp1~ Ő ì «ÖììÀ·/5 švePïȘŹRZҟbXÎüŒ+·é”t]6ú”OÉ]­ăxxC,€ź‚HŒh©»uV[răTŸ8àÎxc|a »VÄí Á1Ć|\AșŚ2€€ž­H)%â·Œ%P’kÆâH›ôèˆÂIU(rĆËœ°-TŸsÖœ/y–î]’„E@’U"0LR©]‹raÖæĘŰĘÍÍï{Țśœï{óçÇżBçȚÙG-ùł{C9ŸDœÏۑ—›ìéŒŹ"^ÓöΆÔő€êz’ș•.tŒüűìéÈ#c”H.Ț€QŹČ-íȚ7ŒvjöBjЅÁa«N!&Ș.:Æo“H’––"Ă»C€Łé’”RSĂÔ]ö2"·^!Ÿ‚Ź™Ši"Ï"=bxR"|&:44OçEj˜ q4ʌ•QÎú>K)Ż‰æ†œ0.Ł0$±Ć€WšÎÉ!‚,$fŁ[êüäŃŻxM‹˜“€oN]Ô NQŽÔŻ2Ž]FîæÂŚöÉv†-YÃë5ĘzűwĂàMÇzH~?„\»>?o Ț,),äl4lÀaêőJ,KŠCcY•ŠGXÔűőBÎ\zűŸ ˜ùÚϏW5œTȘ•ϝË\ȘÌ»•œl Đ&mXé‹D§DX<đÜŠłđBűùąŹj-ćóČÖANŠ­D”gƑ‰[·Ô-›neʅf­AÊÔiMcźï\ŹgíAÚ*äȘˆOcŰív?ŒÂšû7Pn‡ByR%HV0OB}æiéT`–Æ -LWXÒр286Ê_˜¶¶ ±Ç Ą 7R˜Üší°â©káI«k<êEß-5Q¶3°ˆˆXkg[}RCc6ìĘŠç2•ô‹=„tÍMRŰ §ŐŒn±š­b˜7±ƒźÇ3ŠÄćÇŹîíÁˆ“ƒyrăXš”Fą‘fŁą!±”=Ą”ąEGšƒoR$ÊmGÁß^źà<#9«ćÆàńVš(rìX $uÛgą{Üę­™ÛĄÔKÆêHš!+pkŚ,ۃo•“3èüŃ_XVUÜßU@śŠ’€œÂ f}Ké›"F ȶ°ĐAć( Žg&e,I“ˆÓêswbŰ%& °j_Šæî„B• eWjâ.ź]e°„yŒpâ±[Á—†äč èÍ ŐÏrNŰÍ+ŒšÎÛxÙŐđűêï{A>șêÏ}†ł3vȚžt°Ú•}w€u Òś†–@$ !Uę˜‹ëáêđó»¶œ© NȘö72hHłé!'ȘÀSnŻzï:–B;ŹAF-Őfuy»ÀaÒ3{áb@ĆđŁ€=čĐ G… 2# 0IqŠ8EïˆQŒF"íGq}OÚçX PŻSȘ5B­ ™ÏVÙžêŹąĘœȘ\šÛ{ÓœÓRĄùB’<ôĐ­éÆ—ôòŽ–bŰŒ€ïœÎyńëŸ5‹ +[Ÿ{ œ~și- &šoÏWćŐ\șă­Ü C_¶Šz‚mvȚœ ő±%F8 Üt[èŃ6+@qÌŹ‚6EÌÔłÇœȘS%oê :öyÇvìY*Űžăa—nŠ‘JTBbIô]æ ;gІtƒ%zž§xźÒ7kNvçeM››eVu'4Y° Țí›y$eÆŰ( ȅé萍úç/«{QŰœ;&w~©'7u™îłĂČÒ§w=słÂnW/ƒ&©!yŠù菳$֙!N‡Œ0%+Ž•}U[ɐäÊŚo]+,Pѕđ5_wŻWÇß„-ŃDìâF%vź™3Îv©1CŽvG&·…ć ö恎òAQŚWÂgžÒ8m*ç‚Ê·Nœtæ-X*țHÏłéìÛ‘ìŻŸŽâêœŰ%*%B‚€o:è}«Nœê‡;iòʐ5nŹ ±ÀEÈ,\ƒ& `’„ˆkĆâ#lb1¶_5]·fËrJûŒFđ^]đx*B;±ŽŁ„–ĘpœÊązŽ^>ì§U[Ó«‹Fś|ÖȘđé}$ œćíÎśăčxÄ«•" ö.A’Sč)nPDóU-ł#„‰Eł‰"QŒ@} ű‹ȘȘ5›hïXÇŠ†aąÉž3wrôhKŁ,ô“:ę*°É€NMw ’MíúŻn4€őȚOw^±okŸnSËôsœb„vhŻa—^•,‡3]Ž8#v±ln5{š1]}s;ü­ŸŃžg)ȘVœËj©æč(ù©™ŻäąSQ› ·ôzuQç Y ߚXì3Ó__œoŹgHÜôŚMô·|Î֝!f”șŽKߣö}ìŽĘï9ôgŚW”‰HàŽ‹**‚3§ ta)ćö*Òœ©éȚg tK¶nÜy˜]]AŠŚ}ż.Ö“m5Ęo œjҊ:XqV"ÂĄ,yáë·J–»­Ź WD8âTOÍVąÀűXđàĂ0x€`™|ß7ÙÇ ‰ÜÛŚ>ÊsĘ5ÏљźĆŰFj·g5ȚŚHxéa4»șŻąa̶i ĂŚDÏwv—EvI6­92ÊÄBæ(t=śl)hYą#Đâ[ć«‹"vj î'66}»=àyZšȘlž’ŒœlFËŚŒæë èȁ*˜-GŽ’Ckkâ xśŸÍ?#1‰FD aXQ(L‡që’·N~f0ËÉ^ Țs›ÁrîX+Ry|A*ő„(u{óž«ç“*Äq« ‘*CaŚ~ șYO»ßć%@ÔG{8œ«L8űžR§Œ#“^Æ1u•™Őԁaă^Ì8čÒźÛÍGCQƒ·RÈ!bÂ>ĐÇaŒíìY˜ùńmàŻÄÓÚÙ6ńË„y›Ùƒ+B$Î ÇLÊš:„ò[›ÂpuNÔ^ŹÁCq1kœ‹4Č6ēm5ńńĘè 6žòŁQôOȘ„‹z„ă Hâű+æ œËï^m=TM&Ôê‰ÓŠ7C`’„°Hb{šŽ–6DšÏ^ùćčœ 19 < "Đf1*,! ˜q‹vSÜŽ”枣s­nő„$€šI„CozŽ„“êòùzcșȚnî4šuÍC!6©#MuÂ3­ÉË:ëŒæ«’/]öÎJáVHÛK—VĆYR')D›óÆ/]]ŽZZOz‰é\MせU]Ș‘iă)Ôd†T©„ŐäáŹev>Sź*+ć°§ëĆŽG*N‹ź«°û3‡ 5+wu^pèíËJú—Đ˜Wç­=ÉćRjá2 Ÿjt0â‰Ș‰Ą]‘j‘ èÌÍ.‹]dć9 ӔĆSŽ«fŠÍÛŐœq\č2uWc&±K:éc”M4ÛrŁI°wŠ”"›±A·›6*XÀâ,X*T ’Y›Śa#`_ł•𙀰ĘeșŹÎ ëŐÍÉ{7KjèpČ­Ù6zRfr…S˜üGg§|gŐïŠ_EÚSꙑ Šú6śx¶·Ä \begin_inset Text \layout Standard Address \end_inset \begin_inset Text \layout Standard Function \end_inset \begin_inset Text \layout Standard 224.0.0.1 \end_inset \begin_inset Text \layout Standard All hosts in the LAN \end_inset \begin_inset Text \layout Standard 224.0.0.2 \end_inset \begin_inset Text \layout Standard All routers in the LAN \end_inset \begin_inset Text \layout Standard 224.0.0.4 \end_inset \begin_inset Text \layout Standard All routers DVMRP in the LAN \end_inset \begin_inset Text \layout Standard 224.0.0.5 \end_inset \begin_inset Text \layout Standard All routers OSPF in the LAN \end_inset \begin_inset Text \layout Standard 224.0.0.6 \end_inset \begin_inset Text \layout Standard All routers OSPF designated in the LAN \end_inset \begin_inset Text \layout Standard 224.0.0.13 \end_inset \begin_inset Text \layout Standard All the PIM routers in the LAN \end_inset \end_inset \layout Caption \begin_inset LatexCommand \label{mcast special addresses} \end_inset Multicast special addresses \end_inset The interval from 224.0.0.0 to 224.0.0.255 is reserved to local purposes (local administrative tasks) - to see some of these address purposes, refer to table \begin_inset LatexCommand \ref{mcast special addresses} \end_inset . Similarly, the interval from 239.0.0.0 to 239.255.255.255 is also reserved for administrative tasks - but not necessarily local tasks. So, the interval that may be used by general multicast applications is from 225.0.0.0 to 238.255.255.255. \layout Subsubsection Multicast Group \layout Standard A multicast group is composed by the set of hosts in a network which share data via multicast. This group is identified by a multicast address. When a host sends a packet to the multicast address, this packet is received by all the multicast group members. The transmission of a packet from one sender to multiple receivers is accomplis hed by a single send operation. A single packet is sent from the sender host - there is no need to send multiple copies of this packet, as would be needed if unicast were used. \layout Standard The receivers may join and leave the multicast group in a dynamic way. The network devices, specially the routers, have to determine which of their interfaces have a multicast member connected to them. \layout Subsubsection Levels of conformance \layout Standard Hosts can be in three different levels of conformance with the Multicast specification, according to the requirements they meet: \layout Itemize \series bold Level 0 \series default is the "no support for IP Multicasting" level. Lots of hosts and routers in the Internet are in this state, as multicast support is not mandatory in IPv4 (it is, however, in IPv6). Not too much explanation is needed here: hosts in this level can neither send nor receive multicast packets. They must ignore the ones sent by other multicast hosts. \layout Itemize \series bold Level 1 \series default is the "support for sending but not receiving multicast IP datagrams" level. Thus, note that it is not necessary to join a multicast group to be able to send datagrams to it. Very few additions are needed in the IP module to make a "Level 0" host "Level 1-compliant". \layout Itemize \series bold Level 2 \series default is the "full support for IP multicasting" level. Level 2 hosts must be able to both send and receive multicast traffic. They must know the way to join and leave multicast groups and to propagate this information to multicast routers. Thus, they must include an Internet Group Management Protocol (IGMP) implementa tion in their TCP/IP stack. \layout Standard The Multicast Reliable Library was developed considering that the hosts are in level 2 of conformance. \layout Subsubsection Some benefits of Multicast \layout Standard Some benefits of multicast over unicast are presented below \begin_inset LatexCommand \cite{key-35} \end_inset : \layout Enumerate Optimized use of the network - the intelligent use of the network resources avoids unnecessary replication of data. So, the links are better used, through a better architecture of data distributi on. \layout Enumerate Distributed application support - the multicast technology is directly focused on distributed applications. Multimedia applications like distance learning and video conferencing may be used in the network in an efficient way. \layout Enumerate Scalability - services that use multicast can be accessed by many hosts, and may accept new members at any time. \layout Enumerate Availability of the network resources - congestion is reduced, because no replicated data is sent through a single link in the network, so the availabili ty of the network resources is increased. \layout Subsection Configuration under Linux \layout Standard This section will not explain multicast configuration in details. We just want to give some tips needed to set up a basic system in a local network area. If you want further information see the Multicast HOWTO \begin_inset LatexCommand \cite{key-33} \end_inset . Multicast transmission through different networks is more complex and you must have routers with multicast support between those networks. \layout Subsubsection Does your system have support for IP Multicast? \layout Standard Some configurations are needed to use IP Multicast. First of all, the network cards have to be enabled to receive multicast data. Most network cards modules automatically set the MULTICAST flag. In GNU/Linux systems, you can check whether your network interface has multicast support by typing the following command: \layout Quotation \family typewriter \size footnotesize ifconfig -a \layout Standard An ifconfig output example follows: \layout Verse \family typewriter \size footnotesize eth0 \layout Verse \family typewriter \size footnotesize Link encap:Ethernet HWaddr 00:50:BF:06:89:47 \newline inet addr:192.168.1.2 Bcast:192.168.1.255 Mask:255.255.255.0 \newline UP BROADCAST RUNNING \series bold MULTICAST \series default MTU:1500 Metric:1 \newline RX packets:12438583 errors:0 dropped:0 overruns:0 frame:0 \newline TX packets:6498370 errors:0 dropped:0 overruns:0 carrier:0 \newline collisions:0 txqueuelen:100 \newline RX bytes:1100375580 (1049.3 Mb) \newline TX bytes:2158372342 (2058.3 Mb) \newline Interrupt:10 Base address:0x7000 \layout Verse \family typewriter \size footnotesize lo \layout Verse \family typewriter \size footnotesize Link encap:Local Loopback \newline inet addr:127.0.0.1 Mask:255.0.0.0 \newline UP LOOPBACK RUNNING MTU:16436 Metric:1 \newline RX packets:8361666 errors:0 dropped:0 overruns:0 frame:0 \newline TX packets:8361666 errors:0 dropped:0 overruns:0 carrier:0 \newline collisions:0 txqueuelen:0 \newline RX bytes:1830657956 (1745.8 Mb) \newline TX bytes:1830657956 (1745.8 Mb) \layout Standard Note the MULTICAST flag at \series bold eth0 \series default . That flag is missed at \series bold lo \series default (the loopback interface). You must have root privileges to enable the MULTICAST flag. To enable that flag you have to issue the following command: \layout Verse \family typewriter \size footnotesize ifconfig multicast \layout Standard Where \series bold interface_name \series default must be replaced by the name of the interface you want to set the MULTICAST flag. This may be useful if you want to enable multicast on a \series bold lo \series default interface because that allows you to do some tests using multicast transmission even if you don't have any real network interface. The next step is to set up the route that the multicast packets will follow. To add this route, as root user, issue the following command: \layout Verse \family typewriter \size footnotesize route add -net 224.0.0.0 netmask 240.0.0.0 dev \layout Standard Where \series bold interface_name \series default must be replaced by the name of the interface to which you want to send the multicast packets. Again, if you are testing on a single machine this interface will be the \series bold lo. \series default To test your configuration try: \layout Verse \family typewriter \size footnotesize ping 224.0.0.1 \layout Standard Every machine in your local network that has multicast enabled should answer this ping. \layout Section Reliable Multicast \layout Subsection Introduction \layout Standard Multicast is supported by the transport layer through the UDP protocol. As each packet may get a different path from source to destiny, packets may come out of order at the receiver host. To solve this problem, it is necessary to have a packet ordering algorithm. Besides the problem of ordering, there is also the possibility of packet loss. This loss makes the protocol unreliable. To solve these problems, which are directly related to the UDP protocol, it is necessary to create an application-level mechanism to guarantee the reliable transmission of data. \layout Standard There are some ways to implement the reliable multicast mechanism. For instance, the responsibility of recovering loss packets can be directed to the receiver or the sender of the data. \layout Standard Here, we will describe three classes of reliable multicast protocols, according to [FIXME]: \layout Enumerate Sender Initiated Approach - based on confirmations (acknowledgments or ACKs) sent by receivers and processed by the senders; \layout Enumerate Receiver Initiated Approach - the receiver detects the loss of packets. The receiver sends negative acknowledgments (NACKs) to the sender via a unicast connection. The sender replies with retransmissions. \layout Enumerate Enhanced Receiver Initiated Approach - the receiver detects the loss of packets. The receiver sends negative acknowledgments (NACKs) to the group via a multicast connection. \layout Subsubsection Sender Initiated Approach \layout Standard Every time a member receives a packet he sends a confirmation (ACK) to the sender. The sender maintains a list of all the group members. When the sender sends a packet, he starts a timer for that packet, and waits for ACKs from the group members. As soon as the timer expires, if the sender haven't received an ACK from some member, this packet is retransmitted. The timer is then restarted. \layout Subsubsection* Advantages and disadvantages \layout Standard The main advantage of this approach is that when the sender receives a confirmat ion (ACK), he is sure that the packet was in fact received. The main disadvantage of this approach is that for each data packet sent, the sender will receive an ACK from each receiver of the multicast session, which may cause congestion. \layout Subsubsection* Summary \layout Enumerate every time the sender transmits or retransmits a data packet he starts a timer for this packet and wait for the ACKs from the receivers; \layout Enumerate every time the receiver receives a data packet he sends a confirmation (ACK) to the sender in a unicast connection. \layout Subsubsection Receiver Initiated Approach \layout Standard In this approach, the receiver has the responsibility of detecting the packet losses. When the receiver doesn't receive a data packet, he sends a negative acknowledg ment (NACK) to the sender, via a unicast connection. The sender will retransmit the data packet when he receives a NACK. \layout Standard The packet loss is detected when a receiver receives a packet with sequence number (sn) i + 1 without having received the packet with sn i. For instance, if the receiver receives packets with sn 0, 1 and 3, he will know that packet with sn 2 was lost. \layout Subsubsection* Advantages and disadvantages \layout Standard In general, the loss probability of a packet is smaller than the success probability. So, few NACK packets will be sent through the network. The disadvantage of this approach is that just the sender of the message will be notified that a packet was lost, and only he may retransmit the data packet. \layout Subsubsection* Summary \layout Enumerate every time the receiver detects a packet loss he sends a negative acknowledgment (NACK) to the sender, via a unicast connection, and starts a timer to wait for a retransmission. \layout Enumerate every time the sender receives a NACK packet he sends a retransmission to the group via multicast connection. \layout Subsubsection Enhanced Receiver Initiated Approach \layout Standard That's a variation of the receiver initiated approach. When a loss is detected, a timer is scheduled. If the timer expires and a NACK for that packet has not been received, the receiver multicasts the request message to the group. If a NACK was received before the timer has expired, the receiver will not send the request message, because he knows that a retransmission request has already been sent by some other member. \layout Subsubsection* Advantages and disadvantages \layout Standard The advantage of this approach is that it limits the number of NACKs which will be sent through the network. The disadvantage is that when the loss probability is high, there will be many NACK packets in the network. Each member of the group will receive all the NACKs sent. This may consume a lot of processing time. \layout Subsubsection* Summary \layout Enumerate every time the receiver detects a packet loss, he starts a timer to send a NACK packet. \begin_deeper \layout Enumerate If he receives a NACK for the same packet which was lost, the transmission of the NACK is canceled (NACK suppression). \layout Enumerate Else, when the timer expires, he sends a NACK via multicast to the group. \newline \newline In both cases, another timer is started, in order to wait for retransmissions. If a retransmission is received, this timer is canceled, and there is nothing else to be done. The data was finally successfully received with success. Else, the timer to send a NACK packet is restarted. We go back to item 1. \end_deeper \layout Enumerate every time a member receives a NACK packet, he schedules the retransmission of the requested packet. \layout Section The Reliable Multicast Library (RML) \layout Standard In this section we will describe how the Reliable Multicast Library works. In section 4.1, definitions will be given. In section 4.2 the mechanisms of how new members join and leave the group will be explained. Then, we will describe how lost packets are recovered in section 4.3. In section 4.4 we show the implementation of the Event List. Finally, we summarize the RML messages and actions in section 4.5. \layout Subsection Definitions \layout Standard Before starting the description of the RML protocol, it is important to define some terms that will be used: \layout Itemize \series bold Multicast Session \series default : a multicast session is the period of time when a multicast group is active. A multicast group is active if we have at least one member on it. \layout Itemize \series bold ACK \series default : a special packet, the acknowledgment (ACK) packet, is used to confirm the receiving of data. For instance, in the TCP protocol, the sender always waits for confirmations sent by the receivers via ACKs. \layout Itemize \series bold NACK \series default : a special packet, the negative acknowledgment (NACK) packet, is used to inform that data was lost. If a receiver finds out that data was lost, he may send NACKs to the sender in order to advertise this problem, and request retransmissions. \layout Itemize \series bold Timers \series default : the time that a member waits in order to execute a specific action (event). This time may be random, with an uniform or exponential distribution. \layout Itemize \series bold Event List \series default : list containing all the events that will be executed. When the timer for a specific event expires, this event is removed from the event list and then executed. \layout Itemize \series bold Cache: \series default structure maintained by the multicast members which stores the last messages received from every member of the multicast session. \layout Subsection Multicast Session Members Management \layout Standard May anyone join a multicast session at any time? What does a new member need to get in order to become a member of a multicast session? What about the exit procedure? If a member wants to leave the group, may he go away immediately? Or should he wait a bit before exiting? This section will answer this questions. \layout Standard Let's start with the join procedure. If every member of the multicast group entered the session always at the same time, the join procedure would be very simple. The problem is that, in practice, a new member may want to join the session a long time after the session has started. If that happens, this member may not be able to get into a consistent state just requesting retransmissions to the older members of the group. That's because the size of the cache of the other members of the group is finite. The data requested by the new member may not be any more in the cache of the older members. \layout Standard During a session, each member maintains a certain quantity of data in his own cache. When this cache gets full, new data replaces the oldest. If a new member enters the group a long time after the session has started, it may happen that he won't be able to receive the older data, since it has been replaced in all the current members caches. \layout Standard For some applications, that may not be a problem. But for drawing applications, such as the TGWB, in which there is a dependency between the data, this problem must be regarded with attention. For instance, the first message received by a member, in a drawing tool, may instruct the application that a rectangle must be drawn. In the future, another message may instruct that the color of this same rectangle must be changed. Thus, the later command only may be executed after the first one has already been executed. In other words, it makes no sense try to change a color of an inexistent rectangle. \layout Standard In order to solve this problem the following mechanism was implemented: when a new member wants to enter the group, he gets, via TCP, the current state of the multicast session from an older member. The current state is composed by all the elements that this member must have in order to join the group, including the cache of the older member. \layout Standard In more details, when a new member wants to join the group, he sends a \begin_inset Quotes eld \end_inset join request \begin_inset Quotes erd \end_inset message to the multicast group, starts a timer and waits for an \begin_inset Quotes eld \end_inset accept \begin_inset Quotes erd \end_inset message. This \begin_inset Quotes eld \end_inset accept \begin_inset Quotes erd \end_inset message will contain information (address and port) of a member of the group. The new member will connect, via TCP, to this member and get his current state. Then, this new member may be considered a member of the group, as the others. If this timer expires before the new member receives an "accept" message, he considers himself the first member of the group. \layout Standard When an old member of the group receives a \begin_inset Quotes eld \end_inset join request \begin_inset Quotes erd \end_inset message, he starts another timer, waiting to send an \begin_inset Quotes eld \end_inset accept \begin_inset Quotes erd \end_inset message. If an \begin_inset Quotes eld \end_inset accept \begin_inset Quotes erd \end_inset message is received before the timer expires, this member suppresses his transmission, and stops his timer. Otherwise, if the timer expires, he sends the \begin_inset Quotes eld \end_inset accept \begin_inset Quotes erd \end_inset message. This mechanism minimizes the number of \begin_inset Quotes eld \end_inset accept \begin_inset Quotes erd \end_inset messages sent by the old members of the group, since when one member detects that another one has already sent an \begin_inset Quotes eld \end_inset accept \begin_inset Quotes erd \end_inset , he cancels his own transmission. \layout Standard To see more details about how this mechanism of joining the group is implemented , please consult the subsection titled \begin_inset Quotes eld \end_inset Thread 5 - Current State Server Thread \begin_inset Quotes erd \end_inset , in section 7.1. \layout Standard Now, let's see what happens when a member wants to leave the group. Suppose a member wants to leave the group. First, he sends a \begin_inset Quotes eld \end_inset leave group \begin_inset Quotes erd \end_inset message to all the members of the group to advertise his intention. Then, he starts a timer and when this timer expires, the member in fact leaves the group. During this latency period, he is still able to send eventual retransmissions. When the other members of the group receive the \begin_inset Quotes eld \end_inset leave group \begin_inset Quotes erd \end_inset message, they turn off the \begin_inset Quotes eld \end_inset active \begin_inset Quotes erd \end_inset bit in their cache related to the member who sent the \begin_inset Quotes eld \end_inset leave group \begin_inset Quotes erd \end_inset message. \layout Subsection Loss Detection and Data Recovery \layout Standard Every data message transmitted by the protocol is identified by its sequence number. When a data message is received from the application to be transmitted for the multicast group, a header is added to indicate the proper sequence number (sn). Afterward the data message is transmitted for the group. \layout Subsubsection The Cache Structure \layout Standard Every member has a cache structure where he stores some information about the members, this cache has an entry for each member of the multicast session. In the figure \begin_inset LatexCommand \ref{rml cache strucuture} \end_inset we can see the cache structure. Each cache entry has some fields that we will describe below: \layout Itemize \series bold number_of_nodes: \series default number of data packets received from the member \layout Itemize \series bold active: \series default indicates whether a member is currently active in the multicast session \layout Itemize \series bold first: \series default a pointer to the first packet of the packet list - the packet list stores the last data packets received from the member \layout Itemize \series bold sm_info: \series default is a structure composed by \emph on member_id \emph default and \emph on member_status \layout Standard The structure sm_info, as described, is composed by: \layout Itemize \series bold member_id \series default : member identification structure composed by the member IP address and the process ID (PID) \layout Itemize \series bold member_status: \series default is a structure that stores the current member status, e.g., the first and the last sn received \layout Standard Finally, member_status is composed by: \layout Itemize \series bold first_rcv: \series default the sequence number (sn) of the first packet received from the member \layout Itemize \series bold last_rcv: \series default the sn of the last packet received from the member \layout Itemize \series bold last_seq_rcv: \series default the sn of of the last in-order packet received from the member \layout Itemize \series bold last_identified \series default : \series bold \series default the greatest sn of the member packet list \layout Itemize \series bold window_size: \series default the maximum size of the NACK window, i.e, the maximum number of NACKs that we can send in a specific time \layout Itemize \series bold window_mask \series default : \series bold \series default it is an array to identify the sn of the lost packets. Where 1 means that we are going to send a NACK for that packet and 2 means that we are waiting for the retransmission for that packet \layout Itemize \series bold window_ini: \series default the position of the smallest sn represented in the window_mask. \layout Itemize \series bold nak_list: \series default the list of NACKs that have been sent. This list controls the number of NACKs sent by each sn. \layout Standard \begin_inset Float figure wide false collapsed false \layout Standard \align center \begin_inset Graphics filename cache.eps display monochrome width 100col% \end_inset \layout Caption \begin_inset LatexCommand \label{rml cache strucuture} \end_inset RML Cache structure \end_inset \layout Subsubsection Loss Detection \layout Standard When a member of the multicast group receives a data packet, he checks the packet sequence number and the sender identification. Then, the member tries to match the sender identification with some \emph on member_id \emph default in his cache. If he is successful in that matching, the sender is already in the cache. Otherwise a node for the new member must be inserted in the cache. After that, the member has to check whether or not the received packet is in sequence. \layout Standard If the sequence number (sn) is in order, i.e., \family typewriter sn=last_seq_rcv+1 \family default , the packet is inserted in the cache and passed to the application. If the sequence number is not in sequence, the member has found out that packets were lost - a gap was detected. Detected the loss, it is necessary to execute the procedures for recovering the lost packets. The data packet received out of order is inserted and kept in the cache. It will be released to the application after all lost data have been recovered. \layout Standard The recovery procedure consists of requesting retransmissions for the lost data packets, in other words, to send NACK messages for the multicast group. For instance, as it can be seen in figure \begin_inset LatexCommand \ref{rml cache strucuture} \end_inset , if the losses of data packets 2 and 3 were detected, then the member is supposed to send requests for retransmission of those data packets. Any member of the multicast session that has the requested data is able to retransmit it. In that way, the retransmission responsibility is distributed. \layout Standard The loss detection discussed before can fail when the lost packet is the last packet transmitted by the sender. Suppose that a member A has sent his last data packet with sn=10 and that member B has lost that packet. Member B is unable to detect the loss until he receives a new data packet from member A. But we have supposed that A will not send new packets. In that situation, there must be another way of detecting the loss. To solve that problem, members send a \begin_inset Quotes eld \end_inset refresh message \begin_inset Quotes erd \end_inset periodically indicating the sn of the last packet sent. When a member receives the \begin_inset Quotes eld \end_inset refresh message \begin_inset Quotes erd \end_inset , he is able to identify the lost packets and to start the recovering procedures. In our example, member B would receive a \begin_inset Quotes eld \end_inset refresh message \begin_inset Quotes erd \end_inset from member A and then would be able to detect and recover the lost packet. \layout Subsubsection Sending NACKs \layout Standard Suppose a scenario where a member of the multicast group sends a data packet to the other members, and all the other members lose that packet. Now, suppose that a NACK packet is sent by every member immediately after the loss is detected. That action may cause an unnecessary traffic in the network. That problem is called NACK implosion \begin_inset LatexCommand \cite{key-36} \end_inset . One solution is to wait for a random time T \size footnotesize \emph on nack \size default \emph default before sending a NACK message. As other members of the multicast group might have lost the same data message, and considering that T \size footnotesize \emph on nack \size default \emph default is random, there will be a member who will choose a smaller timer and send the NACK message before the others. If before T \size footnotesize \emph on nack \size default \emph default expires the member receives a NACK message or a retransmission of the lost data, the transmission of the NACK message will be canceled. So, if we choose an efficient way to determine T \size footnotesize \emph on nack \size default \emph default we will have a great probability of suppressing the sending of duplicated NACK messages through the network. \layout Standard Besides the implosion of NACKs, another problem that may happen related to the sending of NACK messages is that the member may request more data than he is able to handle. In fact, this two problems are similar to the ones faced in the unicast case. The congestion control, used in the TCP, is implemented in order to avoid network congestion. The flow control, also used in the TCP, tries to get rid of the buffer overflow in the client application. More information about TCP mechanisms can be found in chapter 3 of \begin_inset LatexCommand \cite{key-3} \end_inset . As described in the last paragraph, the NACK suppression algorithm tries to solve a problem analog to the one solved by the congestion control in the unicast case. In that way, the congestion control and NACK suppression algorithm attempt to avoid a network core congestion while the unicast and multicast flow control attempt to prevent the overflow that may happen at the network hosts (end systems) buffers. RML implements a simple flow control: the amount of NACKs sent should not exceed the amount of data that the member expecting this packets may process at once. \layout Standard \begin_inset Float figure wide false collapsed false \layout Standard \align center \begin_inset Graphics filename flowcontrol.eps display monochrome \end_inset \layout Caption \begin_inset LatexCommand \label{rml flow control} \end_inset RML Flow Control \end_inset \layout Standard Two possible scenarios for flow control are illustrated in figure \begin_inset LatexCommand \ref{rml flow control} \end_inset . Suppose that packets with sn from 0 to 8 were transmitted by the sender. Those packets were lost by the receiver. The receiver detects the loss when he receives a refresh message from the sender. Then there are two ways of dealing with that loss. The first approach, which we call \emph on Naive Approach \emph default , is, in fact, an approach with no flow control. The problem with this approach is that the receiver will send a large amount of NACK messages and it may happen that the amount of retransmission received in response to those NACKs may be greater than the cache space available. Thus, old data packets, that have not already been sent to the application, will be replaced by new ones. In figure \begin_inset LatexCommand \ref{rml flow control} \end_inset the packet with sn 0 was lost. The receiver has a cache with five slots. It may be seen that data packets from 1 to 5 were first stored in the cache. Note that those packets were not sent to the application because the packet with sn 0 is missed. Then, packets from 6 to 8 were received and replaced packets 1, 2 and 3. After that, the receiver must send NACKs to recover packets from 0 to 3. We can see that it is not useful to replace packets that have not already been sent to the application. \layout Standard In the second approach, which we call \emph on Flow Control Approach \emph default , when a loss is detected the receiver only send NACKs for a certain amount of packets, i.e., the amount he is able to handle. In addition, the receiver requests those retransmissions in only one NACK message. Note in figure \begin_inset LatexCommand \ref{rml flow control} \end_inset that the first NACK sent requests retransmissions for packets with sn 0 to 4 because there were five free slots in the cache. The second NACK requests only the retransmission of packet 0 because there was only one free slot in the cache at that time. Using the Flow Control Approach two NACKs were sent, while in the Naive Approach they were thirteen. \layout Standard \begin_inset Float figure wide false collapsed false \layout Standard \align center \begin_inset Graphics filename packet_types.eps display monochrome width 100col% \end_inset \layout Caption \begin_inset LatexCommand \label{rml packet types} \end_inset RML Packet Types \end_inset \layout Standard The RML uses the \emph on window_mask \emph default , \emph on window_size \emph default and \emph on window_ini \emph default parameters to bound the NACK transmission. The \emph on window_size \emph default has a value of 64, i.e., we can request at most 64 retransmissions per NACK message. The \emph on window_size \emph default value was chosen just for implementation purposes. With that value we can represent the \emph on window_mask \emph default using only two integers in the NACK packets, as shown in figure \begin_inset LatexCommand \ref{rml nack mask} \end_inset . The \emph on window_ini \emph default points to the first position in the \emph on window_mask \emph default array. The NACK packet is mounted using those parameters. In figure \begin_inset LatexCommand \ref{rml packet types} \end_inset , there is a description of the packet structures used in RML. The NACK packet is composed by a set of fields, among them we have : \layout Itemize \series bold base_sn: \series default the value of the sn of the first NACK in the \emph on window_mask \layout Itemize \series bold window_size: \series default the value of \emph on window_size \emph default of the cache, default is 64 \layout Itemize \series bold hmask: \series default an integer that represents the higher part of the NACK mask \layout Itemize \series bold lmask: \series default an integer that represents the lower part of the NACK mask \layout Standard \begin_inset Float figure wide false collapsed false \layout Standard \align center \begin_inset Graphics filename nack_mask.eps display monochrome \end_inset \layout Caption \begin_inset LatexCommand \label{rml nack mask} \end_inset RML NACK mask \end_inset \layout Standard Suppose a NACK message from member M has arrived with \emph on base_sn=5, window_size=64, hmask=1 \emph default and \emph on lmask=3. \emph default To find out which retransmission has been requested by member M we have to translate \emph on hmask \emph default and \emph on lmask \emph default to their binary representation. This translation is shown in figure \begin_inset LatexCommand \ref{rml nack mask} \end_inset . The requests can be identified using the position of the bits with value of 1 plus the \emph on base_sn \emph default . In our scenario, the requests are for the packets with sn 5 (0+5), 6 (1+5) and 37 (32+5). \layout Standard After sending a NACK message, the member waits for a retransmission during a random period of time, called T \size footnotesize \emph on wait \size default \emph default . If the requested retransmission is not received after T \size footnotesize \emph on wait \size default \emph default units of time, a new NACK message is sent. The maximum number of NACKs is limited by \size small the MAX_NAK \size default parameter, which the user may set in the rmcast.config file (see section 5.3 to learn about RML configuration). If MAX_NAK is reached, i.e., a data packet couldn't be recovered - the applicatio n is then suspended. \layout Subsubsection Data Retransmission \layout Standard In the RML each member maintains in his cache the last N data packets he has received from other members. Thus, any member of the multicast group is able to answer to a request for retransmission of the last N messages he has received from each other member. This mechanism distributes the responsibility of retransmission among all the members of the multicast session, but it may create a lot of traffic if every member answers to a NACK message. As was explained in section 4.3.3, we use random timers to avoid this traffic problem. \layout Standard Suppose a member A receives a NACK message from member B regarding a specific lost packet P from member C. If the packet P is stored in A's cache, then member A schedules a random timer T \size footnotesize \emph on ret \size default \emph default to wait before sending a retransmission. There are two situations that may occur before T \size footnotesize \emph on ret \size default \emph default timed out: \layout Enumerate a retransmission of the packet P is received: the A's retransmission is aborted because another member has already answered the request. \layout Enumerate a NACK message regarding the same packet P is received: the NACK message is ignored because the retransmission is already scheduled. \layout Standard If T \size footnotesize \emph on ret \size default \emph default expires and neither (1) nor (2) has occurred, then the retransmission is sent. \layout Subsection The Event List \layout Standard A common activity of the reliable multicast library (RML) is to schedule an event to happen some time in the future. Almost every action that is taken by the RML is not executed immediately when it is requested. Instead, events are scheduled in order to perform the tasks. When a loss of packets is detected, for example, an event is scheduled to send a negative acknowledgment (NACK) after a certain period of time. If, before the timeout, the member receives a retransmission of the lost packet or if the member receives a NACK for the considered packet, then the sending of the NACK is canceled. In the last case, the sending of the NACK is suppressed because another member has just sent the NACK. In order to reduce the network traffic, a member just sends a message after waiting to see if this message was just sent by another member. The key point here is to keep the work distributed but avoiding redundancy. \layout Standard The event list of the Reliable Multicast Protocol is an implementation of a conventional delta list \begin_inset LatexCommand \cite{key-37} \end_inset . The list is a chain of event nodes. The event nodes are stored in increasing order of when the event occurs. Each event node contains the information needed to execute the event - the event type, described below, and some other information, depending on the event type - as well as the time in the future that the event should take place. The time stored in each event is relative to the preceding event. For example, suppose there are five events scheduled for 4, 6, 6, 13 and 17 time units in the future. This would result in the event list illustrated in figure \begin_inset LatexCommand \ref{rml simple event list} \end_inset . Notice that the third event record contains a 0 because it occurs 0 time units after the second event. \layout Standard \begin_inset Float figure wide false collapsed false \layout Standard \align center \begin_inset Graphics filename simple_event_list.eps display monochrome \end_inset \layout Caption \begin_inset LatexCommand \label{rml simple event list} \end_inset RML Event List - a simple example \end_inset \layout Standard The first event node is the next one that will be executed. When an event is inserted at the head of the list, an operating system alarm signal is scheduled to fire after the time indicated at the header node of the list. When the alarm fires, the event node is processed and removed. All the subsequent events that have time of 0 are also executed and removed. Then the alarm is restarted. \layout Standard To schedule a new event, the event manager walks down the list and inserts a record for the new event in the appropriate location, being careful to adjust the relative time of both the new and the event immediately following the new event. Deleting an event from the event list is implemented in an analogous way. \layout Standard The event nodes are divided into five types: \layout Itemize NAK_SND_WAIT- used to schedule a sending of a negative acknowledgment; \layout Itemize RET_RCV_WAIT- used to wait for retransmissions; \layout Itemize RET_SND_WAIT- created to schedule a sending of a retransmission; \layout Itemize REF_SND_WAIT- used to schedule a refresh; \layout Itemize LEV_GRP_WAIT- specifies the time between a user requests to go away from the group and the actual moment when the user leaves the group. \layout Standard Suppose there is one NAK_SND_WAIT event scheduled for 4 time units in the future, in order to send a NACK to a packet initially sent by member M1. Suppose also that there is one REF_SND_WAIT scheduled for 6 time units in the future, and a RET_SND_WAIT for 17 time units in the future. This retransmission refers to packet 4 of member M2. This would result in the event list illustrated in figure \begin_inset LatexCommand \ref{rml detailed event list} \end_inset . Note that the NAK_SND_WAIT event node contains a pointer to the cache entry of member M1. The cache entry of M1 will contain the information about what packets from member M1 were lost. When the event NAK_SND_WAIT fires, searching the cache we will find out which packets of member M1 were lost, and then send a NACK message to request these packets. On the other hand, the REF_SND_WAIT does not require any other information. Finally, the RET_SND_WAIT schedules a retransmission, and to identify the message to be retransmitted we need both the member id of the message and its sequence number. \layout Standard \begin_inset Float figure wide false collapsed false \layout Standard \align center \begin_inset Graphics filename eventlist.eps display monochrome width 100col% \end_inset \layout Caption \begin_inset LatexCommand \label{rml detailed event list} \end_inset RML Event List - a more detailed example \end_inset \layout Standard Figure \begin_inset LatexCommand \ref{rml event handlers} \end_inset depicts how the different events are handled. \layout Standard \begin_inset Float figure wide false collapsed false \layout Standard \align center \begin_inset Graphics filename fleventlist.eps display monochrome width 100col% \end_inset \layout Caption \begin_inset LatexCommand \label{rml event handlers} \end_inset RML Event Handlers \end_inset \layout Subsection RML log generation \layout Standard The RML offers the option of log generation. The log file name is configured through the LOG_FILE option (see section 5.3 for further information about RML parameters configuration). The file will be created at the current directory and the host name and process ID will be appended to the file name provided in the LOG_FILE option. Suppose LOG_FILE= \emph on log \emph default and the application that uses the RML is called from the \emph on /tmp \emph default directory at the \emph on machine01 \emph default . Then, the log file name will be \emph on /tmp/log.machine01.137 \emph default , where \emph on 137 \emph default is the process ID of the application. \layout Standard A log file sample is showed below: \layout Standard \family typewriter \size scriptsize \hfill \newline host: receiverhost \newline ip: 192.168.1.2 \newline pid: 18348 \newline -------------------------------------------------------------------------------- ----------------------------------- \newline time snd/rcv/loss type sender_ip\SpecialChar ~ sender_pid requested_ip\SpecialChar ~ requested_pid sn\SpecialChar ~ [{base_sn} {win_size} {hmask} {lmask}] \newline -------------------------------------------------------------------------------- ----------------------------------- \newline 51800783466\SpecialChar ~ \SpecialChar ~ L\SpecialChar ~ \SpecialChar ~ RF\SpecialChar ~ \SpecialChar ~ 192.168.1.1\SpecialChar ~ 13893\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ -1 \newline 51808642569\SpecialChar ~ \SpecialChar ~ L\SpecialChar ~ \SpecialChar ~ DT\SpecialChar ~ \SpecialChar ~ 192.168.1.1\SpecialChar ~ 13893\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 0 \newline 51810314729\SpecialChar ~ \SpecialChar ~ S\SpecialChar ~ \SpecialChar ~ RF\SpecialChar ~ \SpecialChar ~ 192.168.1.2\SpecialChar ~ 18348\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ -1 \newline 51829942926\SpecialChar ~ \SpecialChar ~ R\SpecialChar ~ \SpecialChar ~ DT\SpecialChar ~ \SpecialChar ~ 192.168.1.1\SpecialChar ~ 13893\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 48 \newline 51829947209\SpecialChar ~ \SpecialChar ~ S\SpecialChar ~ \SpecialChar ~ NK\SpecialChar ~ \SpecialChar ~ 192.168.1.2\SpecialChar ~ 18348\SpecialChar ~ 192.168.1.1\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 13893\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ -1\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 64\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 29280\SpecialChar ~ 235372671 \newline \layout Standard The header of the log file is composed by the host name, ip address and process ID. Then a short description of the log structure is presented. After that, each line describe a packet that was received or sent by the member. The fields are: \layout Itemize \series bold time: \series default indicates the time when the packet was received or sent \layout Itemize \series bold snd/rcv/loss: \series default indicates if the packet was sent (S), received (R) or received but lost because of loss simulation (L). \layout Itemize \series bold type: \series default indicates the packet type, i.e., NACK(NK), data(DT), retransmission(RT), refresh(R F), join accept(JA), join request(JR), leave group(LG) and unknown(UN). \layout Itemize \series bold sender_ip: \series default indicates the IP address of the sender \layout Itemize \series bold sender_pid: \series default indicates the process ID of the sender \layout Itemize \series bold requested_ip: \series default this field appears when a NACK or a retransmission packet is received. If the NACK is requesting the retransmission from packets sent by member C, this field indicates C's IP address. \layout Itemize \series bold requested_pid: \series default this field only appears when a NACK or a retransmission packet is received. If the NACK is requesting the retransmission from packets sent by member C, this field indicates C's process ID. \layout Itemize \series bold sn: \series default this field has different meanings depending on the packet type. When the packet is data or retransmission, this field indicates the sequence number of the packet. When the packet is a refresh message, this field indicates the sequence number of the last data packet sent by the member identified by sender_ip and sender_pid. This field does not appear for the remaining packet types. \layout Itemize \series bold base sn: \series default indicates the value of the sequence number of the first retransmission requested in the NACK packet. \layout Itemize \series bold win size: \series default indicates the window size of the NACK packet \layout Itemize \series bold hmask: \series default an integer that represents the higher part of the NACK mask \layout Itemize \series bold lmask: \series default an integer that represents the lower part of the NACK mask \layout Standard There is a simple shell script, called rmcastplot.bash, that can be used to generate statistics and plots from the RML log files. If you run rmcastplot.bash with no arguments it will show a short help: \layout Paragraph \family typewriter \series medium \size footnotesize -------------------------------------------------------------------------------- --------------------- \newline Usage: \newline rmcastplot.bash [awk_scri pt_dir] [tgif|png] \newline \SpecialChar ~ \newline max_num_pack_sent: maximum number of sent packets \newline xyrange: [XMIN:XMAX][YMIN:YMAX] gnuplot style \newline member1.log: full path to member log \newline member2_log: full path to member log \newline awk_script_dir: optional parameter. Full path to directory where rmlog.awk script is found \newline tgif or png: optional parameter. Changes gnuplot output to generate Tgif files or PNG files \newline -------------------------------------------------------------------------------- --------------------- \layout Paragraph \family typewriter \series medium \size footnotesize \SpecialChar ~ \layout Standard Suppose there are two members using an RML based application. They generate two log files: log.senderhost.13893 and log.receiverhost.18348. For instance, rmcastplot.bash script can be executed with the following line command: \layout Standard \align center \family typewriter \size footnotesize \hfill \newline rmcastplot.bash 100 [0:15][0:5] log.senderhost.13893 log.receiverhost.18348 \newline \hfill \layout Standard The script outputs some statistics at the standard input: \layout Standard \family typewriter \size footnotesize \hfill \layout Standard \family typewriter \size footnotesize -------------------------------------------------- \layout Standard \family typewriter \size footnotesize Member 1 Name:\SpecialChar ~ senderhost \layout Standard \family typewriter \size footnotesize Member 1 IP:\SpecialChar ~ 192.168.1.1 \layout Standard \family typewriter \size footnotesize Member 1 PID: 13893 \layout Standard \family typewriter \size footnotesize Member 2 Name:\SpecialChar ~ receiverhost \layout Standard \family typewriter \size footnotesize Member 2 IP:\SpecialChar ~ 192.168.1.2 \layout Standard \family typewriter \size footnotesize Member 2 PID: 18348 \layout Standard \family typewriter \size footnotesize -------------------------------------------------- \layout Standard \family typewriter \size footnotesize \SpecialChar ~ Data related to \layout Standard \family typewriter \size footnotesize \SpecialChar ~ log.senderhost.13893 -> 192.168.1.2:18348 \layout Standard \family typewriter \size footnotesize -------------------------------------------------- \layout Standard \family typewriter \size footnotesize Data sent:\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 101 \layout Standard \family typewriter \size footnotesize Data received from 192.168.1.2:18348\SpecialChar ~ \SpecialChar ~ 1 \layout Standard \family typewriter \size footnotesize NACKs sent:\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 0 \layout Standard \family typewriter \size footnotesize NACKs received from 192.168.1.2:18348\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 5 \layout Standard \family typewriter \size footnotesize Refresh sent:\SpecialChar ~ 9 \layout Standard \family typewriter \size footnotesize Refresh received from 192.168.1.2:18348 16 \layout Standard \family typewriter \size footnotesize Retrans sent:\SpecialChar ~ 51 \layout Standard \family typewriter \size footnotesize Retrans received from 192.168.1.2:18348 0 \layout Standard \family typewriter \size footnotesize Total simulated loss:\SpecialChar ~ \SpecialChar ~ 0 \layout Standard \family typewriter \size footnotesize Data loss with simulation from 192.168.1.2:18348\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 0 \layout Standard \family typewriter \size footnotesize NACKs lost by simulation from 192.168.1.2:18348\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 0 \layout Standard \family typewriter \size footnotesize Refresh lost by simulation from 192.168.1.2:18348\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 0 \layout Standard \family typewriter \size footnotesize Retrans lost by simulation from 192.168.1.2:18348\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 0 \layout Standard \family typewriter \size footnotesize Packets identified:\SpecialChar ~ 517 \layout Standard \family typewriter \size footnotesize -------------------------------------------------- \layout Standard \family typewriter \size footnotesize \SpecialChar ~ \layout Standard \family typewriter \size footnotesize -------------------------------------------------- \layout Standard \family typewriter \size footnotesize \SpecialChar ~ Data related to \layout Standard \family typewriter \size footnotesize \SpecialChar ~ log.receiverhost.18348 -> 192.168.1.1:13893 \layout Standard \family typewriter \size footnotesize -------------------------------------------------- \layout Standard \family typewriter \size footnotesize Data sent:\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 1 \layout Standard \family typewriter \size footnotesize Data received from 192.168.1.1:13893\SpecialChar ~ \SpecialChar ~ 65 \layout Standard \family typewriter \size footnotesize NACKs sent:\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 5 \layout Standard \family typewriter \size footnotesize NACKs received from 192.168.1.1:13893\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 0 \layout Standard \family typewriter \size footnotesize Refresh sent:\SpecialChar ~ 7 \layout Standard \family typewriter \size footnotesize Refresh received from 192.168.1.1:13893 11 \layout Standard \family typewriter \size footnotesize Retrans sent:\SpecialChar ~ 0 \layout Standard \family typewriter \size footnotesize Retrans received from 192.168.1.1:13893 36 \layout Standard \family typewriter \size footnotesize Total simulated loss:\SpecialChar ~ \SpecialChar ~ 54 \layout Standard \family typewriter \size footnotesize Data loss with simulation from 192.168.1.1:13893\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 36 \layout Standard \family typewriter \size footnotesize NACKs lost by simulation from 192.168.1.1:13893\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 0 \layout Standard \family typewriter \size footnotesize Refresh lost by simulation from 192.168.1.1:13893\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 3 \layout Standard \family typewriter \size footnotesize Retrans lost by simulation from 192.168.1.1:13893\SpecialChar ~ \SpecialChar ~ \SpecialChar ~ 15 \layout Standard \family typewriter \size footnotesize Packets identified:\SpecialChar ~ 453 \layout Standard \family typewriter \size footnotesize -------------------------------------------------- \layout Standard \hfill \layout Standard Besides those statistics, if you have gnuplot \begin_inset LatexCommand \cite{key-38} \end_inset installed in your system, some plots will be generated. One of those plots is showed in figure \begin_inset LatexCommand \ref{log plot} \end_inset . \layout Standard \begin_inset Float figure wide false collapsed false \layout Standard \align center \begin_inset Graphics filename log_plot.eps display monochrome \end_inset \layout Caption \begin_inset LatexCommand \label{log plot} \end_inset Log plotted with the rmcastplot.bash script \end_inset \layout Subsection Summary \layout Standard Figure \begin_inset LatexCommand \ref{rml actions on receiving packets} \end_inset summarizes the RML behavior on receiving each packet type. \layout Standard \begin_inset Float figure wide false collapsed false \layout Standard \align center \begin_inset Graphics filename actions_on_receiving_packets.eps display monochrome width 100text% height 100text% \end_inset \layout Caption \begin_inset LatexCommand \label{rml actions on receiving packets} \end_inset Actions taken on receiving each packet type \end_inset \layout Section A simple example: the chat program \layout Standard In this section we will describe a simple chat application that uses the RML. We hope that this simple example may be used to show how to develop an application based on our RML. \layout Subsection Minimal requirements to create an Reliable Multicast based application \layout Standard The development of a Reliable Multicast application has some requirements as follow: \layout Itemize A multicast enabled environment (see section 2 to learn about that); \layout Itemize The Reliable Multicast Library - the librmcast.a file; \layout Itemize The Reliable Multicast Header - the rmcast.h file; \layout Itemize C language develop environment - gcc, make, c libraries etc. \layout Subsection Getting and installing the Reliable Multicast Library \layout Standard To get the Reliable Multicast Library do the following: \layout Enumerate Download the RML source code from our project page at \emph on \newline http://www.land.ufrj.br/tools/rmcast \layout Enumerate Gunzip and untar the package. After that the RelMulticast directory will be created. \layout Enumerate Change to RelMulticast directory. \layout Enumerate Type make and see if the \series bold librmcast.a \series default is compiled without errors. This may be flawless for most users. \layout Standard To compile an application with librmcast.a you should use the following options with gcc: \layout Quote -I -L -lrmcast \layout Standard For instance, we have an application called rmchat in the examples/rmchat directory, to compile that application we should issue the command: \layout Quote gcc rmchat.c -I../.. -L../.. -lpthread -lm -lrmcast -o rmchat \layout Standard Inside the RelMulticast directory you will find some useful files such as README, INSTALL etc. Those files contain the most updated instructions to compile the RML, please take a look at them. \layout Subsection The Reliable Multicast Library configuration \layout Standard There are two ways for an application to customize the Reliable Multicast Library options: \layout Enumerate Calling the \series bold RM_setOption(int OPTION_ID, void *OPTION_VALUE) \series default function, where: \newline \newline OPTION_ID: indicates what option you want to set. You can found the option list in the rmcast.h header file. \newline OPTION_VALUE: the value you want to set the option to \newline \newline \series bold Example: \series default \newline \family typewriter ... \newline /* Setting REFRESH_TIMER */ \newline int refresh_timer=10; \newline \newline RM_setOption(REFRESH_TIMER,(void *) refresh_timer); \newline ... \layout Enumerate Calling \series bold RM_readConfigFile(char *filename) \series default . This function will tell the Reliable Multicast Library to read the user's options from \series bold filename \series default . \newline \newline \series bold Example: \series default \newline \newline \family typewriter ... \newline /* Read the config file from /etc/rmcast.config */ \newline char config_file[50]; \newline \newline strcpy(config_file,"/etc/rmcast.config"); \newline \newline RM_readConfigFile(config_file); \newline ... \family default \newline \layout Standard NOTE: There is a constant, RM_USE_CURRENT_CONFIG, that can replace functions parameters. In those situations, the RM_USE_CURRENT_CONFIG will indicate that the current values (which may have been set either by calling RM_setOption or RM_readConfig File) must be used. For instance, when we call the RM_joinGroup() function we are supposed to pass as parameters the IP Multicast address and port number. If we have already read those options from rmcast.config file, just replace the parameters with the RM_USE_CURRENT_CONFIG constant. \newline \layout Standard The rmcast.config file contain some options that can be customized by the users. A rmcast.config file example follows (lines beginning with a \i \"{ } #\i \"{ } are comments): \layout Quote \family typewriter \size footnotesize #Reliable Multicast Library configuration file \layout Quote \family typewriter \size footnotesize #Reliable Multicast Library version \newline RM_VERSION=1.0 \layout Quote \family typewriter \size footnotesize #Transmission mode: 0 multicast (default), 1 unicast \newline TRANSMISSION_MODE=0 \layout Quote \family typewriter \size footnotesize #Multicast or Unicast IP address to send data (destination IP) \newline DEST_IP=225.1.2.3 \layout Quote \family typewriter \size footnotesize #Multicast or Unicast port to send data (destination port) \newline DEST_PORT=5000 \layout Quote \family typewriter \size footnotesize #Time to live for the packets setting (1 indicates local network) \newline TTL=1 \layout Quote \family typewriter \size footnotesize #Inter-packet sleep timer - timer between transmissions of packets \newline #( in microseconds) \newline MICROSLEEP=10 \layout Quote \family typewriter \size footnotesize #Log file path - NULL disable logging (default) \newline LOG_FILE=NULL \layout Quote \family typewriter \size footnotesize #Random Timers Distribution: 0 uniform 1 exponential \newline TIMER_DISTRIBUTION=0 \layout Quote \family typewriter \size footnotesize #Lower bound for timer generation (in milliseconds) \newline TIMER_LOWER=200 \layout Quote \family typewriter \size footnotesize #Upper bound for timer generation (in milliseconds) \newline TIMER_UPPER=1000 \layout Quote \family typewriter \size footnotesize #Max number of naks that can be sent for each packet. 100 (default) \newline MAX_NAK=100 \layout Quote \family typewriter \size footnotesize # We will be able to retransmit the last MAX_MEMBER_CACHE_SIZE \newline # packets from each member of the multicast group, i.e., we will store the \newline # last MAX_MEMBER_CACHE_SIZE PACKETS from each member \newline # of the multicast group in the cache. 4000 (default) \newline # \newline # WARNING: if you set MAX_MEMBER_CACHE_SIZE to low values \newline # the protocol may fail!! \newline # \newline MAX_MEMBER_CACHE_SIZE=4000 \layout Quote \family typewriter \size footnotesize #Enable support for new users 1 enabled (default), 0 disabled \newline NEW_USER_SUPPORT=0 \layout Quote \family typewriter \size footnotesize #Show transmission statistics: 0 disabled (default) 1 enabled \newline STATISTICS=0 \layout Quote \family typewriter \size footnotesize #Time between sending of refresh messages (seconds) \newline REFRESH_TIMER=10 \layout Quote \family typewriter \size footnotesize #Loss simulation: 0 disabled (default) any float number > 0 enabled \layout Quote \family typewriter \size footnotesize # A note about loss simulation: \newline # When loss simulation is enabled (LOSS_PROB > 0) we always loose \newline # the first 10 received packets, and the first received data packet - \newline # that is, the first burst of received packets. \newline # After that, packets are lost according to LOSS_PROB. \newline # Example: LOSS_PROB=30 \newline # The first 10 received packets will be lost. \newline # Then, 30% of the packets will be lost \newline LOSS_PROB=0 \layout Quote \family typewriter \size footnotesize # Time to wait, in microseconds, before leaving the multicast group. \newline LEAVE_GROUP_WAIT_TIME = 5000000 \layout Quote \family typewriter \size footnotesize # Size of the buffer of the receiver host \newline # (maximum size of a message that may be processed by \newline # the receiver host). \newline RCV_BUFFER_SIZE = 10000 \layout Standard To retrieve the current value of an option from the RML you must call the \series bold RM_getOption(int OPTION,void *OPTION_VALUE) \series default function \series bold . \layout Subsection The Reliable Multicast Chat (rmchat) application \layout Standard This is a simple chat application and was written just for testing the RML. The fully commented source code can be found in the examples/rmchat directory. You can compile the program by typing \family typewriter \color black make \family default \color default in that directory. \layout Subsubsection The program \layout Standard Every user that initiates the program is prompted for a username - this username will be the users identity in the group. After that they will receive all the messages from every user already connected to the chat group (if any). You can also type messages in the prompt and send them to the group by pressing the return key. Note that there is no need for a chat server because we are using multicast. Users must know the IP address and port to join the chat group. You can set this address and port through the rmcast.config file as we have seen in the previous section. \layout Standard We have implemented only two simple commands in the rmchat: \layout Enumerate \series bold send - \series default by typing \family typewriter \color black send \family default \color default on the prompt you will be asked for the number of packets to send to the group. This command was implemented to perform simple tests with the application. \layout Enumerate \series bold exit \series default - this command is used to terminate the application. \layout Subsubsection Source code comments \layout Standard This section is supposed to be read along with the source code of rmchat, available at examples/rmchat/rmchat.c. \layout Standard The very first thing we have to do when we are writing an application is to include the \series bold rmcast.h \series default header file. Next we define BUFFSIZE - the maximum message size. We also declare an integer global variable to identify the socket we will use to send and receive data. \layout Standard The following step is to read the configuration file, calling the \series bold RM_readConfigFile \series default function. Then, we have to initialize the RML calling the \series bold RM_initialize \series default function. After that we join the multicast group calling the \series bold RM_joinGroup \series default function. At this point we are using the RM_USE_CURRENT_CONFIG as discussed in section 4.3. The \series bold RM_joinGroup \series default function returns the socket identifier that we will need to send and receive data from the network. \layout Standard Interactive network applications are supposed to simultaneously receive and send data through the network. To implement that feature we usually create separated threads to deal with those tasks. In the rmchat we have created, calling the pthread_create function, the \emph on \series bold \emph default Receive thread \series default to receive packets from the network, while the main thread will get the user messages and will send them to the multicast group. \layout Standard You can easily see in the Receive thread code that there is a loop where we just call \series bold RM_recv \series default function to retrieve data from the network. The data received is then showed on the screen. \layout Standard In the main program we are reading the messages typed by the user and checking whether they are a command or a simple message. If it is a simple message, we just call the \series bold RM_sendto \series default function to send the data to the multicast group. Otherwise, if the \series bold exit \series default command is issued, we break the loop and prepare to terminate the application. We use the \series bold RM_getOption \series default to retrieve the current IP address and port from the RML just to report it to the user. In addition we cancel the Receive thread using the pthread_cancel() function. \layout Standard Finally we call the \series bold RM_leaveGroup \series default function to finish the RML and our program. This function is \noun on very important \noun default because it cleans up the system resources that we were using such as the message queue. See section 7.3 for further information on message queues. Again, we recommend that you take a look at the source code to better understan d the application. \layout Subsection RML functions quick reference \layout Standard In this section will go through the user functions available in the Reliable Multicast Library. \layout Itemize \series bold RM_readConfigFile(char *filename) \series default - read the configuration file identified by \emph on filename \emph default . See section 4.3 for the config file format and options. \layout Itemize \series bold RM_setOption(int opt, void *optvalue) \series default - set the option identified by \emph on opt \emph default with the value in \emph on optvalue \emph default . You can use setOption to set the RML instead of reading the config file. \layout Itemize \series bold RM_getOption(int opt, void *optvalue) \series default - returns the current value \emph on optvalue \emph default of the option identified by \emph on opt \emph default . \layout Itemize \series bold int RM_initialize(void) \series default - initializes the RML structures and defines the callback function that will be used when finishing the application \layout Itemize \series bold RM_getCurStatus(char *group, int port, CurStatus *c) \series default - get the current status from a member of the multicast group. \layout Itemize \series bold RM_sendCurStatus(int connfd, char *buff, int buffsize) \series default - send the current status to a new member of the multicast group. \layout Itemize \series bold RM_joinGroup(char *group, int port) \series default - join the multicast group identified by the IP address in \emph on group \emph default and the port in \emph on port \emph default . Returns the socket identifier that will be used in the RM_sendto and RM_recv functions. \layout Itemize \series bold RM_sendto(int socket, void *buffer, int buffsize) \series default - sends up to \emph on buffsize \emph default bytes of data from \emph on buffer \emph default using the socket identifier \emph on socket \emph default . Returns 1 on success and 0 if an error occurs. \layout Itemize \series bold RM_recv(int socket, void *buffer, int buffsize) \series default - receives up to \emph on buffsize \emph default bytes of data, and stores them into \emph on buffer \emph default using the socket identifier \emph on socket \emph default . Returns the number of bytes received on success and -1 when an error occurs. \layout Itemize \series bold RM_leaveGroup(int sock,char * group) \series default - sends a message indicating that we are leaving the multicast group identified by \emph on group \emph default , cleans all the system resources being used and closes the socket identified by \emph on socket \emph default . You must call this function before terminating the application. Returns 1 on success and 0 on failure. \layout Section A more advanced application: the Tangram II Whiteboard \layout Subsection About Tangram II Whiteboard (TGWB) \layout Standard Quoting from the tgif manual, \begin_inset Quotes eld \end_inset tgif (Tangram2 Graphic Interface Facility) is a Xlib based interactive 2-D drawing facility under X11 \begin_inset Quotes erd \end_inset . The tgif tool is a powerful vector based drawing tool. The user draws objects, i.e., rectangles, lines, circles and splines, over a drawing area. Objects may be transformed - for instance, rotated, translated and flipped. New objects may be constructed by grouping other objects. \layout Standard In the next section, we will describe a whiteboard tool which was developed over tgif - TGWB (Tangram II Whiteboard). The tgwb allows simultaneous modifications in drawings by users in a group. It is a versatile multicast distributed tool. \layout Subsection Getting and installing TGWB \layout Standard To get the TGWB, follow the steps below: \layout Enumerate get tgif at http://bourbon.usc.edu:8001/tgif/ \layout Enumerate read the README.tgwb file and follow the instructions described there. \layout Subsection What features make TGWB different \layout Standard There are two main points that make the TGWB application different from the previously described chat. \layout Standard At a given time, a user may want to send to the group huge amounts of data (for example, a screenshot). This message must be segmented into smaller packets before being sent to the group (note that, for simplicity, in the chat application we were assuming that the user would not send very large amounts of data in the messages). One of the reasons segmentation is needed is the fact that there is a maximum segment size which network routers support. To see other reason for doing segmentation, the interested read should consult chapter 1 of \begin_inset LatexCommand \cite{key-3} \end_inset . Figure \begin_inset LatexCommand \ref{tgwb layers} \end_inset presents the TGWB layers. \layout Standard A second feature that makes the TWGB tool different from the chat is the fact that we need to assure global consistency among the users of the TGWB tool. Imagine that two users change the color of a rectangle at the same time: user A changes the color of the rectangle to red, and B to blue. What must user C see? A blue or a red rectangle? What about A and B? This problem, and others, are solved using a \begin_inset Quotes eld \end_inset total ordering mechanism \begin_inset Quotes erd \end_inset , which is based in the use of the undo/redo commands (rollback-recovery strategy). Consult \begin_inset LatexCommand \cite{key-24} \end_inset for a complete explanation about this subject. \layout Subsection The life cycle of a packet in the TGWB \layout Standard The packets life cycle begins when a user draws an object over the tgif drawing area. As mentioned above, an object may be a circle, a rectangle, a text box or any other drawing primitive described on the tgif manual. Please, see tgif man pages, tgif FAQ \begin_inset LatexCommand \cite{key-2} \end_inset and tgif tutorial for more information about tgif. \layout Standard Now, the object must be delivered to the members of the multicast group. This is done via the RML functions. However, before being delivered the object is first divided into segments - see the \emph on Segment() \emph default call in wb.c. The segment size is chosen in a way that the more common objects (rectangles, circles and text boxes) fit in one segment and, at the same time, the maximum transfer unit (MTU) is greater then the segment size. \layout Standard All the RML functions available for the applications have the RM_ prefix. So, in order to send a tgif object to the network, \emph on RM_sendto() \emph default is called, passing as parameters the multicast destination group and the object data. You may see the definition of the function \emph on SendWBData() \emph default in wb.c. The \emph on RM_sendto() \emph default function (and all the other functions that may be called by an application) is defined in the rmcast.c file. \emph on RM_sendto() \emph default calls \emph on rmcastSendPackets() \emph default , which is defined in rminternals.c, and that in turns makes a \shape italic \color black sendto(2) \shape default \color default system call (the number two between parenthesis refers to the section two of man of sendto - to see the man info, type \family typewriter man 2 sendto \family default at the Linux prompt. Please, note that this number may vary according to the operating system). \layout Standard In general, the functions defined in rmcast.c call functions defined in rminterna ls.c. Then, functions in rminternals.c make system calls. Concerning the syntax, note that the functions in rmcast.c have the prefix \begin_inset Quotes eld \end_inset RM_ \begin_inset Quotes erd \end_inset and the functions in rminternals.c have the prefix \begin_inset Quotes eld \end_inset rmcast \begin_inset Quotes erd \end_inset . \layout Standard At this point we have segmented the object data into packets, appended all needed headers and the packet was sent. That's what happens at the sender side. Now, let's see the receiver side. \layout Standard All the members of the multicast group, communicating among themselves using the TGWB, receive messages from all the other members \shape italic \color black . \emph on At the application level, the \emph default RM_recv() \emph on function is used to get messages in order, without gaps, from the other members of the group \emph default . \shape default The \emph on \color default RM_recv() \emph default function makes a \shape italic \color black msgrcv(2) \shape default \color default system call to get messages from a message queue. Note that this is an exception to the general explanation given two paragraphs above. Read the following section in order to get more information about how the message queue works, and why it is used here. \layout Standard When a packet arrives from the network, the \shape italic \color black recvfrom(2) \shape default \color default system call is responsible for receiving it. We make a \shape italic \color black recvfrom(2) \shape default \color default system call in the \emph on rmcastReceivePackets() \emph default function, defined in rminternals.c. The received message is then processed, inserted in the cache and, if it is in fact the expected message, we put it in the message queue. The message queue was the interprocess communication mechanism that we have chosen in order to store the in-order without-gaps messages that will be read by the application. \layout Standard Figure \begin_inset LatexCommand \ref{tgwb architecture} \end_inset show the Tangram II Whiteboard architecture. \layout Standard \begin_inset Float figure wide false collapsed false \layout Standard \align center \begin_inset Graphics filename layers.eps display monochrome \end_inset \layout Caption \begin_inset LatexCommand \label{tgwb layers} \end_inset TGWB Layers \end_inset \begin_inset Float figure wide false collapsed false \layout Standard \align center \begin_inset Graphics filename wbarch.eps display monochrome width 100col% height 100text% rotateAngle 90 \end_inset \layout Caption \begin_inset LatexCommand \label{tgwb architecture} \end_inset TGWB Architecture \end_inset \layout Section More about the Tangram II Whiteboard \layout Subsection The TGWB threads \layout Standard UNIX/Linux offers a lot of interprocess communication mechanisms. If you run tgwb under Linux, and type \family typewriter ps -aux | grep tgwb \family default , you will probably see something like: \layout Quotation \family typewriter [anonymous@salinas anonymous]$ ps -axu | grep tgwb \layout Quotation \family typewriter anonymous 2820 1.7 0.8 12780 1992 pts/4 S 16:25 tgwb \layout Quotation \family typewriter anonymous 2821 0.1 0.8 12780 1992 pts/4 S 16:25 tgwb \layout Quotation \family typewriter anonymous 2822 0.0 0.8 12780 1992 pts/4 S 16:25 tgwb \layout Quotation \family typewriter anonymous 2823 0.0 0.8 12780 1992 pts/4 S 16:25 tgwb \layout Quotation \family typewriter anonymous 2824 0.0 0.8 12780 1992 pts/4 S 16:25 tgwb \layout Quotation \family typewriter anonymous 2825 0.0 0.8 12780 1992 pts/4 S 16:25 tgwb \layout Quotation \family typewriter anonymous 2827 1.0 0.2 1700 592 pts/4 S 16:25 grep tgwb \layout Standard We see here that tgwb generates six processes. That's because under Linux the pthreads library generates one process per thread (please, see Appendix), plus one extra thread, which corresponds to the \begin_inset Quotes eld \end_inset thread manager \begin_inset Quotes erd \end_inset . We will briefly describe the first five threads generated by TGWB - the last one, the \begin_inset Quotes eld \end_inset thread manager \begin_inset Quotes erd \end_inset is created internally by Linux Threads to handle thread creation and terminatio n \begin_inset LatexCommand \cite{key-4} \end_inset . \layout Standard thread 1. responsible for receiving ordered, without gaps messages - that is, reliable messages; \layout Standard thread 2. responsible for receiving possible out of order, with gaps messages - that is, messages from the network; \layout Standard thread 3. responsible for (a) processing the local user actions, such as drawing objects and writing texts, (b) processing remote user commands which arrive from the message queue and (c) sending local commands to the other users. That is the \begin_inset Quotes eld \end_inset main \begin_inset Quotes erd \end_inset thread; \layout Standard thread 4. responsible for signal handling. We will call this thread the \begin_inset Quotes eld \end_inset signal handler \begin_inset Quotes erd \end_inset thread; \layout Standard thread 5. responsible for sending the current state, via TCP, to the new users who eventually would like to join the group. We will call this thread as the \begin_inset Quotes eld \end_inset current state server \begin_inset Quotes erd \end_inset thread. \layout Standard These threads, and the relations between them, are represented in figure \begin_inset LatexCommand \ref{tgwb architecture} \end_inset . \layout Subsection* Thread 1 - Reliable messages receiver thread \layout Standard This thread, implemented in the tgwb, stays in a loop waiting for reliable messages. When a reliable message is received, it is inserted in a buffer, and also an 'a' is written into a pipe. This 'a' will signal the main thread that there is data available from the network. \layout Subsection* Thread 2 - Raw messages receiver thread \layout Standard Implemented under the RML, this thread is responsible for receiving raw data from the network. Depending on the type of the message (for instance, data, negative acknowledgme nt and refresh messages) we take the appropriate actions. Please, see section 4.3 for more details about this. \layout Subsection* Thread 3 - Main thread \layout Standard This thread is implemented in the TGWB mainloop.c file. This thread remains sleeping until it is wakened up by one of the following events: \layout Standard (1) an X event is generated by the local user; \layout Standard (2) a \begin_inset Quotes eld \end_inset reliable message \begin_inset Quotes erd \end_inset arrives from the network. \layout Standard Lets start by (1). When an user drags the mouse in order to draw an object this event is inserted in the X event-list. This list is managed by the X-server using a FIFO policy. As soon as the mentioned user command gets on the top of this list, the command is executed and sent to the other members of the group. \layout Standard Now, let's analyze (2). A pipe is used to perform the communication between the main thread and the \begin_inset Quotes eld \end_inset reliable messages receiver thread \begin_inset Quotes erd \end_inset . When a \begin_inset Quotes eld \end_inset reliable message \begin_inset Quotes erd \end_inset arrives from the network an 'a' character is written in the pipe by the \begin_inset Quotes eld \end_inset reliable messages receiver thread \begin_inset Quotes erd \end_inset . The main thread then reads this 'a' from the pipe, and the command received from the network is locally processed. \layout Standard At this point it's interesting to talk a little about the history of tgwb. In former versions of TGWB, we made a busy wait loop in order to wait for events from both the local user and the network, that is, a busy wait for (1) and (2). That is not efficient, and when someone call the command \family typewriter top \family default , from the shell prompt, TGWB usually appears as the first element of the list, consuming near 100% of the CPU cycles. To solve this problem, we introduced the use of pipes \begin_inset LatexCommand \cite{key-22} \end_inset in the mainloop of TGWB. \layout Standard Please, refer to figure \begin_inset LatexCommand \ref{tgwb mainloop} \end_inset for a scheme of the TGWB mainloop. The mainloop of TGWB waits for (1) or (2) calling: \layout LyX-Code status = select(nfds, &fdset, NULL, NULL, &timeout); \layout Standard When we get (1), \emph on XNextEvent(mainDisplay, pXEvent) \emph default is called, and the X event generated by the local user is processed. When we get (2), \emph on SendCommandToSelf(CMDID_DATA_IN_MBUFF, 0) \emph default is called, and the \begin_inset Quotes eld \end_inset reliable message \begin_inset Quotes erd \end_inset which arrived from the network is processed. Besides (1) and (2), the main thread may also get a request for packing the tgwb current state. When we receive 'c' via the pipe, which signals this request, we call \emph on HandleNewUserRequest() \emph default and the request is attended. Our approach to solve this problem is discussed at session 7.2. \layout Standard \begin_inset Float figure wide false collapsed false \layout Standard \align left \begin_inset Graphics filename mainloop.eps display monochrome \end_inset \layout Caption \begin_inset LatexCommand \label{tgwb mainloop} \end_inset TGWB mainloop routine \end_inset \layout Subsection* Thread 4 - Signal handler thread \layout Standard We will give a brief explanation about the difference between synchronous and asynchronous signals. As signal handling is a very broad topic, please refer to \begin_inset LatexCommand \cite{key-18} \end_inset \begin_inset LatexCommand \cite{key-23} \end_inset for more details. Signals may be generated synchronously or asynchronously. A synchronous (sync) signal pertains to a specific action in the program, and is delivered (unless blocked) during that action. Errors generate signals synchronously, and so do explicit requests by a process to generate a signal for that same process. \layout Standard Asynchronous (async) signals are generated by events outside the control of the process that receives them. These signals arrive at unpredictable times during execution. External events generate signals asynchronously, and so do explicit requests that apply to some other process. \layout Standard A given type of signal is either typically synchronous or typically asynchronous. For example, signals for errors are typically synchronous because errors generate signals synchronously. But any type of signal can be generated synchronously or asynchronously with an explicit request. \layout Standard In the Reliable Multicast Library, a dedicated thread was created to wait for all the generated signals. Such a thread just loops on a sigwait subroutine call and handles the signals. That is a typical schema for programs that handle signals with threads \begin_inset LatexCommand \cite{key-6} \end_inset and an example can be found at \begin_inset LatexCommand \cite{key-17} \end_inset . \family roman Th \family default at \family roman kind of procedure \family default handles the signals \family roman synchronously \family default because this is the safest programming style. \layout Subsection* Thread 5 - Current State Server Thread \layout Standard This thread is responsible for the so called \begin_inset Quotes eld \end_inset support for new members \begin_inset Quotes erd \end_inset in the RML. In other words, this thread is responsible for provisioning to new members the capacity for joining a TGWB session at any time. \layout Standard Suppose that a new member A wants to join the multicast group. This member will try to get the \begin_inset Quotes eld \end_inset current state \begin_inset Quotes erd \end_inset of the group, and just after that he will enter. In more details, we follow the steps below: \layout Standard (1) First, member A send a packet of type JOIN_REQUEST to the group. \layout Standard (2) Then, member A waits for an JOIN_ACCEPT packet from any member of the group. \layout Standard If member A doesn't receive any message, and gets a timeout, he will start to send/receive packets to/from the multicast group as he was the first member in that TGWB session. \layout Standard (3) When a JOIN_ACCEPT packet is received from a member B, member A will try to connect to B via TCP, and retrieve his \begin_inset Quotes eld \end_inset current state \begin_inset Quotes erd \end_inset . After receiving the current state, A will make a call to RM_joinGroup() and at this moment member A becomes an actual member of the group. It implies that besides being able to talk with the other members of the group, member A is promoted to a \begin_inset Quotes eld \end_inset current state server \begin_inset Quotes erd \end_inset . \layout Standard A \begin_inset Quotes eld \end_inset current state server \begin_inset Quotes erd \end_inset is a server that waits for connections in a specific port, and when a new client connects to this port, the \begin_inset Quotes eld \end_inset current state server \begin_inset Quotes erd \end_inset provides the \begin_inset Quotes eld \end_inset current state \begin_inset Quotes erd \end_inset to this client. \layout Subsection Solving the busy wait problem \layout Standard Processes (and threads), during its execution time, may be in several operating states. Among the states, we will focus on the two extreme ones: busy wait, when the process occupies almost 100% of the CPU, or sleeping, when it practically does not use system resources. See chapter 3 of \begin_inset LatexCommand \cite{key-23} \end_inset for more details about process (and threads) states. \layout Standard In former versions of tgwb, the mainloop of the program worked using busy wait. In tgwb version 4.1.40, if we ran tgwb and typed \begin_inset Quotes eld \end_inset top \begin_inset Quotes erd \end_inset at the Linux shell prompt, we would get: \layout LyX-Code PID %CPU %MEM TIME COMMAND \layout LyX-Code 27490 81.3 2.5 0:26 tgwb \layout LyX-Code \layout Standard Note that tgwb was occupying 81.3% of the CPU time. And this occurred even when we were not drawing or writing anything on the canvas - the simple fact of opening the tgwb was responsible for that. We started trying to solve the problem using the \shape italic \color black select(2) \shape default \color default system call. Using \shape italic \color black select(2) \shape default \color default we would be able to \begin_inset Quotes eld \end_inset sleep \begin_inset Quotes erd \end_inset waiting for data to arrive either from the network or from commands sent by the local user. Instead of having something like: \layout LyX-Code while(1) \layout LyX-Code { \layout LyX-Code if ( data received from the network ) \layout LyX-Code do this; \layout LyX-Code else if ( there is an X event to be processed ) \layout LyX-Code do that; \layout LyX-Code else \layout LyX-Code do nothing; \layout LyX-Code } \layout Standard We would like to get: \layout LyX-Code while(1) \layout LyX-Code { \layout LyX-Code select (...); /* sleep waiting for data from the network \layout LyX-Code or for an X event */ \layout LyX-Code \layout LyX-Code if ( data received from the network ) \layout LyX-Code do this; \layout LyX-Code else if ( there is an X event to be processed ) \layout LyX-Code do that; \layout LyX-Code } \layout Standard First we tried to do this by making the \begin_inset Quotes eld \end_inset reliable messages receiver thread \begin_inset Quotes erd \end_inset write a character into a conventional file when a message arrived from the networking, and the select would watch the file to see if characters become available for reading. The select would return if there were some character on the file or there were an pending X event. The problem is that select() doesn't work with conventional files. After finding out this problem, instead of using conventional files we started working with a pipe. An important reference that we used was \begin_inset LatexCommand \cite{key-34} \end_inset . \layout Standard Follows below a piece of a message from William Cheng, who is the tgif's main developer : \newline \layout Standard \family typewriter Basically, you create a pipe to send notification characters to yourself! So, when tgwb starts, a pipe is created and its 2 endpoints (file descriptors) are stored in an array. In GetAnXEvent(), you need to do a select() call. This call will wait for 3 conditions: (1) an X events has arrived; (2) the pipe contains some data; and (3) a timeout has occurred. The timeout is there just case something goes wrong. I would set a very large timeout, for example, 15 seconds. \layout Standard \family typewriter In ReceivePacket(), instead of calling SendCommandToSelf(), \newline it should write 1 byte to the pipe! That's it! \layout Standard \family typewriter In GetAnXEvent(), if select() returns with the pipe having some data, you should read 1 bytes and then calls SendCommandToSelf(). \layout Standard \family typewriter (Well, calling HandleDataInMBuff() directly would be fine too.) \newline \layout Standard Note that we call the \emph on SendCommadToSelf() \emph default function when we receive a command from the network. This function, which is also called in menu.c, is used to put X events in the X internal queue. Using this functionality, when we receive a data from the network it is processed and then the resulting action is put in the X queue, and then treated as any other X event. \layout Standard Now, if we run tgwb and type \begin_inset Quotes eld \end_inset top \begin_inset Quotes erd \end_inset at the Linux shell prompt, we get: \layout LyX-Code PID %CPU %MEM TIME COMMAND \layout LyX-Code 26919 0.0 0.6 0:00 bash \layout LyX-Code 27049 0.0 0.7 0:00 tgwb \layout LyX-Code 27050 0.0 0.7 0:00 tgwb \layout LyX-Code 27051 0.0 0.7 0:00 tgwb \layout LyX-Code 27052 0.0 0.7 0:00 tgwb \layout LyX-Code 27053 0.0 0.7 0:00 tgwb \layout Standard Note that the %CPU (percentage of total CPU time) of tgwb now is almost 0. \layout Section Appendix - Interprocess Communication Resources \layout Standard In order to implement the reliable multicast library we have used a lot of interprocess communication resources. The operating system and interprocess communication resources used were: \layout Enumerate threads; \layout Enumerate mutexes; \layout Enumerate message queues; \layout Enumerate pipes; \layout Enumerate sockets (TCP and UDP); \layout Enumerate signals. \layout Standard We will give here a brief introduction to these topics. The interested reader should consult \begin_inset LatexCommand \cite{key-25,key-26} \end_inset . \layout Subsection Threads \layout Standard When we have a lot of tasks to do, we try to do different tasks at the same time. This tasks are the human analogy to what threads are for computer programs. In our Reliable Multicast Library (RML) we have used mainly the following pthread system calls: \layout Itemize pthread_create \layout Itemize pthread_join \layout Itemize pthread_exit \layout Standard To get more info about pthreads, please refer to the man pages of this functions , and \begin_inset LatexCommand \cite{key-4,key-27,key-28} \end_inset \layout Subsection Mutexes \layout Standard In order to synchronize threads we have to use mutexes. We can't, for example, change the value of a variable at two distinct points at the same time because this may generate an inconsistency. In the RML, we used the system calls: \layout Itemize pthread_mutex_lock \layout Itemize pthread_mutex_unlock \layout Standard in order to protect some critical points of the program - mainly the ones that work with the cache and the event list, which are the global structures accessed by more than one thread. \layout Subsection Message Queues \layout Standard The message queues are a first in first out (FIFO) operating system mechanism that are used to pass data between different thread/processes. They are an important IPC mechanism. Among the message queue functions used, we may focus: \layout Itemize msgget - int msgget ( key_t key, int msgflg ) \layout Itemize msgctl - int msgctl ( int msqid, int cmd, struct msqid_ds *buf ) \layout Itemize msgsnd - int msgsnd ( int msqid, struct msgbuf *msgp, size_t msgsz, int msgflg ) \layout Itemize msgrcv - ssize_t msgrcv ( int msqid, struct msgbuf *msgp, size_t msgsz, long msgtyp, int msgflg ) \layout Standard The first important concept to understand is the concept of a \begin_inset Quotes eld \end_inset key \begin_inset Quotes erd \end_inset . Keys are numbers used to identify an IPC resource in UNIX, in an analogy to the fact that file names are used to identify files. It's the key that allows that an IPC resource be shared between different threads and processes, similarly to the fact that the file names allow that a file be referenced by any program running in the operating system. \layout Standard The function \emph on msgget \emph default receives as first parameter a key, and return an identifier for the object which is analogous to the \begin_inset Quotes eld \end_inset file descriptor \begin_inset Quotes erd \end_inset in the case of files. The last parameter, \emph on msgflg \emph default , must be set to IPC_CREAT when we want to create a new object. It's necessary to make a logical OR of IPC_CREAT with the values of table \begin_inset LatexCommand \ref{message queue permissions} \end_inset depending on the permissions wanted for the created object. \layout Standard \begin_inset Float table wide false collapsed false \layout Standard \align center \begin_inset Tabular \begin_inset Text \layout Standard \begin_inset Tabular \begin_inset Text \layout Standard octal value \end_inset \begin_inset Text \layout Standard meaning \end_inset \begin_inset Text \layout Standard 0400 \end_inset \begin_inset Text \layout Standard read permited for the owner of the object \end_inset \begin_inset Text \layout Standard 0200 \end_inset \begin_inset Text \layout Standard write permited for the owner of the object \end_inset \begin_inset Text \layout Standard 0040 \end_inset \begin_inset Text \layout Standard read permited for the group \end_inset \begin_inset Text \layout Standard 0020 \end_inset \begin_inset Text \layout Standard write permited for the group \end_inset \begin_inset Text \layout Standard 0004 \end_inset \begin_inset Text \layout Standard read permited for all \end_inset \begin_inset Text \layout Standard 0002 \end_inset \begin_inset Text \layout Standard write permited for all \end_inset \end_inset \end_inset \end_inset \layout Caption \begin_inset LatexCommand \label{message queue permissions} \end_inset Message queue permissions \end_inset The functions \emph on msgsnd \emph default and \emph on msgrcv \emph default are used to send/receive messages to/from the queue. The \emph on msgctl \emph default function is used to set control properties of the queue. Please, refer to the man pages of this functions for more details about them. \layout Subsection Pipes \layout Standard The pipes, as the message queues, are used to transmit data between processes/th reads. The difference between pipes and message queues is that pipes work with characters (we write/read characters to/from the pipe) while message queues work with messages of variable sizes. \layout Standard The main pipe system call used was: \layout Itemize pipe \layout Subsection Sockets \layout Standard Sockets are IPC mechanisms that may be used to send/receive messages between two hosts. Please, consult \begin_inset LatexCommand \cite{key-29} \end_inset in order to get more information about sockets. \layout Subsection Signals \layout Standard Please, see the comments about the \begin_inset Quotes eld \end_inset signal handler thread \begin_inset Quotes erd \end_inset , in section 7.1. \layout Bibliography \bibitem {key-30} \color black Tangram II web site: http://www.land.ufrj.br \layout Bibliography \bibitem {key-33} \color black Multicast HOWTO available at http://www.linuxdoc.org/HOWTO/Multicast-HOWTO.html \layout Bibliography \bibitem {key-2} Cheng, W.C. Tangram Graphical Interface Facility \newline \newline TGWB has been integrated with TGIF since version 4.1.29 released on April 18,2000. \layout Bibliography \bibitem {key-3} Kurose, J.F. and Ross, K.W., Computer Networking - A Top-Down Approach Featuring the Internet. \layout Bibliography \bibitem {key-4} Leroy, X. The Linux Threads library - an implementation of the Posix 1003.1c thread package for Linux. \newline http://pauillac.inria.fr/~xleroy/linuxthreads/ \layout Bibliography \bibitem {key-6} http://www.unet.univie.ac.at/aix/aixprggd/genprogc/signal_mgmt.htm \layout Bibliography \bibitem {key-17} http://support.entegrity.com/private/doclib/docs/osfhtm/develop/apgstyle/Apgsty83.h tm \layout Bibliography \bibitem {key-18} http://www.gnu.org/manual/glibc-2.2.3/html_node/libc_458.html \layout Bibliography \bibitem {key-22} http://www-h.eng.cam.ac.uk/help/tpl/graphics/X/signals.html \layout Bibliography \bibitem {key-23} Stallings, William. Operating Systems, Internals and Design Principles. Prentice Hall. \layout Bibliography \bibitem {key-24} C. E. F. Brito, E. Souza e Silva and W. Cheng. Reliable Multicast Communication and the Implementation of TGWB, a Shared Vector-based Whiteboard Tool. Technical Report. \layout Bibliography \bibitem {key-25} Haviland, Keith. Unix System Programming. Addison Wesley Publishing Company. \layout Bibliography \bibitem {key-26} Stevens, Richard. Advanced Programming in the UNIX Environment. Addison Wesley Professional Computing Series. \layout Bibliography \bibitem {key-27} Nichols, Bradford et al. Pthreads Programming. O'Reilly. \layout Bibliography \bibitem {key-28} Kleiman, Steve et al. Programming with Threads. \layout Bibliography \bibitem {key-29} Stevens, Richard. UNIX Network Programming. Prentice Hall. \layout Bibliography \bibitem {key-34} http://www-h.eng.cam.ac.uk/help/tpl/graphics/X/signals.html \layout Bibliography \bibitem {key-35} RNP: http://www.rnp.br/multicast/multicast-beneficios.html \layout Bibliography \bibitem {key-36} A.Erramilli and R.P Sing. \begin_inset Quotes eld \end_inset A Reliable and Eficient Multicast Protocol for Broadband Broadcast Networks Proccedings of ACM SIGCOMM 87, pp. 343-352, August 1987. \layout Bibliography \bibitem {key-37} Peterson, Larry et al. \begin_inset Quotes eld \end_inset Computer Networks: A Systems Approach \begin_inset Quotes erd \end_inset . \layout Bibliography \bibitem {key-38} http://www.gnuplot.info \layout LyX-Code \layout LyX-Code \the_end tgif-QPL-4.2.5/rmcast/doc/manual/packet_types.obj0000644000076400007640000010074411077130422021500 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,0,0,0,64,0,9,3,1,1,0,0,0,1,0,'Courier-Bold',1,80640,0,0,0,10,0,0,1,1,0,16,0,0,2,4,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/packet_types.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 50971, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 40569, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). page(1,"member info",1,''). box('blue','',16,48,144,112,0,1,1,108,0,0,0,0,0,'1',0,[ ]). text('black',48,67,1,0,1,63,17,109,12,4,0,0,0,0,2,63,17,0,0,"",0,0,0,0,80,'',[ minilines(63,17,0,0,0,0,0,[ mini_line(63,13,4,0,0,0,[ str_block(0,36,12,4,0,-1,0,0,0,[ str_seg('blue','Courier-Bold',1,80640,36,12,4,0,-1,0,0,0,0,0, "char")]), str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, " ip")]) ]) ])]). box('blue','',144,48,272,112,0,1,1,110,0,0,0,0,0,'1',0,[ ]). text('black',176,67,1,0,1,63,17,111,12,4,0,0,0,0,2,63,17,0,0,"",0,0,0,0,80,'',[ minilines(63,17,0,0,0,0,0,[ mini_line(63,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('blue','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, " pid")]) ]) ])]). text('black',16,19,1,0,1,81,16,112,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,32,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "MEMBER_ID")]) ]) ])]). box('magenta','',16,176,176,240,0,1,1,113,0,0,0,0,0,'1',0,[ ]). text('black',48,195,1,0,1,117,17,114,12,4,0,0,0,0,2,117,17,0,0,"",0,0,0,0,208,'',[ minilines(117,17,0,0,0,0,0,[ mini_line(117,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('magenta','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('magenta','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, " first_rcv")]) ]) ])]). box('magenta','',176,176,320,240,0,1,1,115,0,0,0,0,0,'1',0,[ ]). text('black',192,195,1,0,1,108,17,116,12,4,0,0,0,0,2,108,17,0,0,"",0,0,0,0,208,'',[ minilines(108,17,0,0,0,0,0,[ mini_line(108,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('magenta','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('magenta','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, " last_rcv")]) ]) ])]). text('black',16,147,1,0,1,117,16,117,13,3,0,0,0,0,2,117,16,0,0,"",0,0,0,0,160,'',[ minilines(117,16,0,0,0,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-2,0,0,0,[ str_seg('magenta','Courier',0,80640,117,13,3,0,-2,0,0,0,0,0, "MEMBER_STATUS")]) ]) ])]). box('magenta','',320,176,496,240,0,1,1,118,0,0,0,0,0,'1',0,[ ]). text('black',336,195,1,0,1,144,17,119,12,4,0,0,0,0,2,144,17,0,0,"",0,0,0,0,208,'',[ minilines(144,17,0,0,0,0,0,[ mini_line(144,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('magenta','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,117,13,3,0,-1,0,0,0,[ str_seg('magenta','Courier',0,80640,117,13,3,0,-1,0,0,0,0,0, " last_seq_rcv")]) ]) ])]). box('magenta','',496,176,697,240,0,1,1,120,0,0,0,0,0,'1',0,[ ]). text('black',512,195,1,0,1,171,17,121,12,4,0,0,0,0,2,171,17,0,0,"",0,0,0,0,208,'',[ minilines(171,17,0,0,0,0,0,[ mini_line(171,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('magenta','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('magenta','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, " last_identified")]) ]) ])]). box('blue','',24,304,248,368,0,1,1,122,0,0,0,0,0,'1',0,[ ]). text('black',56,323,1,0,1,171,17,123,12,4,0,0,0,0,2,171,17,0,0,"",0,0,0,0,336,'',[ minilines(171,17,0,0,0,0,0,[ mini_line(171,13,4,0,0,0,[ str_block(0,81,12,4,0,-1,0,0,0,[ str_seg('blue','Courier-Bold',1,80640,81,12,4,0,-1,0,0,0,0,0, "MEMBER_ID")]), str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, " member_id")]) ]) ])]). box('magenta','',248,304,536,368,0,1,1,124,0,0,0,0,0,'1',0,[ ]). text('black',264,323,1,0,1,243,17,125,12,4,0,0,0,0,2,243,17,0,0,"",0,0,0,0,336,'',[ minilines(243,17,0,0,0,0,0,[ mini_line(243,13,4,0,0,0,[ str_block(0,117,12,4,0,-1,0,0,0,[ str_seg('magenta','Courier-Bold',1,80640,117,12,4,0,-1,0,0,0,0,0, "MEMBER_STATUS")]), str_block(0,126,13,3,0,-2,0,0,0,[ str_seg('magenta','Courier',0,80640,126,13,3,0,-2,0,0,0,0,0, " member_status")]) ]) ])]). text('black',16,271,1,0,1,63,16,126,12,4,0,0,0,0,2,63,16,0,0,"",0,0,0,0,283,'',[ minilines(63,16,0,0,0,0,0,[ mini_line(63,12,4,0,0,0,[ str_block(0,63,12,4,0,-1,0,0,0,[ str_seg('CadetBlue','Courier-Bold',1,80640,63,12,4,0,-1,0,0,0,0,0, "SM_INFO")]) ]) ])]). box('CadetBlue','',14,293,545,381,0,1,1,1017,0,0,0,0,0,'1',0,[ ]). box('CadetBlue','',6,9,905,395,0,1,1,1021,0,0,1,0,0,'1',0,[ ]). text('CadetBlue',905,399,1,2,1,612,16,1023,12,4,0,0,0,0,2,612,16,0,0,"",0,0,0,0,411,'',[ minilines(612,16,0,0,2,0,0,[ mini_line(612,12,4,0,0,0,[ str_block(0,612,12,4,0,-4,0,0,0,[ str_seg('CadetBlue','Courier-Bold',1,80640,612,12,4,0,-4,0,0,0,0,0, "That is the current known information about a specific group member.")]) ]) ])]). box('black','',23,468,151,532,0,1,1,852,0,0,0,0,0,'1',0,[ ]). text('black',55,487,1,0,1,72,17,853,12,4,0,0,0,0,2,72,17,0,0,"",0,0,0,0,500,'',[ minilines(72,17,0,0,0,0,0,[ mini_line(72,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, " size")]) ]) ])]). box('black','',151,468,279,532,0,1,1,854,0,0,0,0,0,'1',0,[ ]). text('black',174,487,1,0,1,90,17,855,12,4,0,0,0,0,2,90,17,0,0,"",0,0,0,0,500,'',[ minilines(90,17,0,0,0,0,0,[ mini_line(90,13,4,0,0,0,[ str_block(0,36,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,36,12,4,0,-1,0,0,0,0,0, "char")]), str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, " *data")]) ]) ])]). text('black',23,439,1,0,1,72,16,856,13,3,0,0,0,0,2,72,16,0,0,"",0,0,0,0,452,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "CurState")]) ]) ])]). group([ box('green','',24,591,152,655,0,1,1,932,0,0,0,0,0,'1',0,[ ]), text('black',56,610,1,0,1,63,17,933,12,4,0,0,0,0,2,63,17,0,0,"",0,0,0,0,623,'',[ minilines(63,17,0,0,0,0,0,[ mini_line(63,13,4,0,0,0,[ str_block(0,45,12,4,0,-8,0,0,0,[ str_seg('green','Courier-Bold',1,80640,45,12,4,0,-8,0,0,0,0,0, "char ")]), str_block(0,18,13,3,0,-1,0,0,0,[ str_seg('green','Courier',0,80640,18,13,3,0,-1,0,0,0,0,0, "ip")]) ]) ])]), box('green','',152,591,280,655,0,1,1,934,0,0,0,0,0,'1',0,[ ]), text('black',175,610,1,0,1,72,17,935,12,4,0,0,0,0,2,72,17,0,0,"",0,0,0,0,623,'',[ minilines(72,17,0,0,0,0,0,[ mini_line(72,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('green','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,45,13,3,0,-2,0,0,0,[ str_seg('green','Courier',0,80640,45,13,3,0,-2,0,0,0,0,0, " port")]) ]) ])]), text('black',24,562,1,0,1,72,16,936,13,3,0,0,0,0,2,72,16,0,0,"",0,0,0,0,575,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('green','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "GROUP_ID")]) ]) ])]) ], 1047,0,0,[ ]). group([ box('cyan','',374,590,502,654,0,1,1,940,0,0,0,0,0,'1',0,[ ]), text('black',406,610,1,0,1,63,16,941,12,4,0,0,0,0,2,63,16,0,0,"",0,0,0,0,622,'',[ minilines(63,16,0,0,0,0,0,[ mini_line(63,12,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('cyan','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,36,12,4,0,0,0,0,0,[ str_seg('cyan','Courier-Bold',1,80640,36,12,4,0,0,0,0,0,0,0, " min")]) ]) ])]), box('cyan','',502,590,630,654,0,1,1,942,0,0,0,0,0,'1',0,[ ]), text('black',525,610,1,0,1,63,16,943,12,4,0,0,0,0,2,63,16,0,0,"",0,0,0,0,622,'',[ minilines(63,16,0,0,0,0,0,[ mini_line(63,12,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('cyan','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,36,12,4,0,-1,0,0,0,[ str_seg('cyan','Courier-Bold',1,80640,36,12,4,0,-1,0,0,0,0,0, " max")]) ]) ])]), text('black',374,562,1,0,1,45,16,944,12,4,0,0,0,0,2,45,16,0,0,"",0,0,0,0,574,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,12,4,0,0,0,[ str_block(0,45,12,4,0,0,0,0,0,[ str_seg('cyan','Courier-Bold',1,80640,45,12,4,0,0,0,0,0,0,0, "TIMER")]) ]) ])]) ], 1053,0,0,[ ]). text('black',23,678,1,0,1,81,16,880,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,691,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "USER_INFO")]) ]) ])]). group([ box('black','',258,771,370,835,0,1,1,1005,0,0,0,0,0,'1',0,[ ]), text('black',273,792,1,0,1,90,17,1006,12,4,0,0,0,0,2,90,17,0,0,"",0,0,0,0,805,'',[ minilines(90,17,0,0,0,0,0,[ mini_line(90,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,63,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-2,0,0,0,0,0, " socket")]) ]) ])]), box('black','',23,771,180,835,0,1,1,883,0,0,0,0,0,'1',0,[ ]), text('black',40,794,1,0,1,126,17,884,12,4,0,0,0,0,2,126,17,0,0,"",0,0,0,0,807,'',[ minilines(126,17,0,0,0,0,0,[ mini_line(126,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,99,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-1,0,0,0,0,0, " cache_size")]) ]) ])]), box('black','',180,771,258,835,0,1,1,1003,0,0,0,0,0,'1',0,[ ]), text('black',198,793,1,0,1,54,17,1004,12,4,0,0,0,0,2,54,17,0,0,"",0,0,0,0,806,'',[ minilines(54,17,0,0,0,0,0,[ mini_line(54,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, " sn")]) ]) ])]) ], 1114,0,0,[ ]). group([ box('cyan','',23,707,205,771,0,1,1,876,0,0,0,0,0,'1',0,[ ]), text('black',37,727,1,0,1,162,16,877,12,4,0,0,0,0,2,162,16,0,0,"",0,0,0,0,739,'',[ minilines(162,16,0,0,0,0,0,[ mini_line(162,12,4,0,0,0,[ str_block(0,108,12,4,0,0,0,0,0,[ str_seg('cyan','Courier-Bold',1,80640,108,12,4,0,0,0,0,0,0,0, "struct TIMER")]), str_block(0,54,12,4,0,-1,0,0,0,[ str_seg('cyan','Courier-Bold',1,80640,54,12,4,0,-1,0,0,0,0,0, " timer")]) ]) ])]), box('green','',205,707,449,771,0,1,1,878,0,0,0,0,0,'1',0,[ ]), text('black',218,727,1,0,1,216,17,879,12,4,0,0,0,0,2,216,17,0,0,"",0,0,0,0,740,'',[ minilines(216,17,0,0,0,0,0,[ mini_line(216,13,4,0,0,0,[ str_block(0,144,12,4,0,-8,0,0,0,[ str_seg('green','Courier-Bold',1,80640,144,12,4,0,-8,0,0,0,0,0, "struct GROUP_ID ")]), str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('green','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "group_id")]) ]) ])]), box('blue','',449,707,636,771,0,1,1,881,0,0,0,0,0,'1',0,[ ]), text('black',456,729,1,0,1,171,17,882,12,4,0,0,0,0,2,171,17,0,0,"",0,0,0,0,742,'',[ minilines(171,17,0,0,0,0,0,[ mini_line(171,13,4,0,0,0,[ str_block(0,90,12,4,0,-8,0,0,0,[ str_seg('blue','Courier-Bold',1,80640,90,12,4,0,-8,0,0,0,0,0, "MEMBER_ID ")]), str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "member_id")]) ]) ])]) ], 1121,0,0,[ ]). box('CadetBlue','',7,437,907,860,0,1,1,1122,0,0,0,0,0,'1',0,[ ]). text('CadetBlue',473,865,1,0,1,441,16,1126,12,4,0,0,0,0,2,441,16,0,0,"",0,0,0,0,877,'',[ minilines(441,16,0,0,0,0,0,[ mini_line(441,12,4,0,0,0,[ str_block(0,441,12,4,0,-8,0,0,0,[ str_seg('CadetBlue','Courier-Bold',1,80640,441,12,4,0,-8,0,0,0,0,0, "That is the own information of the group member. ")]) ]) ])]). page(2,"packets msgs",1,''). group([ box('black','',10,62,121,96,0,1,1,2305,0,0,0,1,0,'1',0,[ 10,62,10,62,121,126,1000,0,0,531.25,0,0],[ ]), text('black',27,70,1,0,1,81,17,2304,12,4,0,0,0,0,2,81,17,0,0,"",0,0,0,0,83,'',[ minilines(81,17,0,0,0,0,0,[ mini_line(81,13,4,0,0,0,[ str_block(0,45,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,45,12,4,0,-8,0,0,0,0,0, "char ")]), str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, "type")]) ]) ])]), box('black','',121,62,322,96,0,1,1,2303,0,0,0,1,0,'1',0,[ 121,62,121,62,322,126,1000,0,0,531.25,0,0],[ ]), text('black',141,70,1,0,1,171,17,2302,12,4,0,0,0,0,2,171,17,0,0,"",0,0,0,0,83,'',[ minilines(171,17,0,0,0,0,0,[ mini_line(171,13,4,0,0,0,[ str_block(0,90,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,90,12,4,0,-8,0,0,0,0,0, "MEMBER_ID ")]), str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "sender_id")]) ]) ])]), text('black',337,71,1,0,1,135,17,2301,12,4,0,0,0,0,2,135,17,0,0,"",0,0,0,0,84,'',[ minilines(135,17,0,0,0,0,0,[ mini_line(135,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, " packet_size")]) ]) ])]), box('black','',322,62,479,96,0,1,1,2300,0,0,0,1,0,'1',0,[ 322,62,322,62,479,126,1000,0,0,531.25,0,0],[ ]), box('black','',479,62,764,96,0,1,1,2299,0,0,0,1,0,'1',0,[ 479,62,479,62,611,126,2159.09,0,0,531.25,0,0],[ ]), text('black',499,72,1,0,1,261,17,2298,12,4,0,0,0,0,2,261,17,0,0,"",0,0,0,0,85,'',[ minilines(261,17,0,0,0,0,0,[ mini_line(261,13,4,0,0,0,[ str_block(0,162,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,162,12,4,0,-8,0,0,0,0,0, "union PACKET_DATA ")]), str_block(0,99,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-1,0,0,0,0,0, "packet_data")]) ]) ])]) ], 2297,0,0,[ ]). text('black',10,36,1,0,1,54,16,2309,12,4,0,0,0,0,2,54,16,0,0,"",0,0,0,0,48,'',[ minilines(54,16,0,0,0,0,0,[ mini_line(54,12,4,0,0,0,[ str_block(0,54,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,54,12,4,0,-1,0,0,0,0,0, "PACKET")]) ]) ])]). poly('black','',2,[ 480,97,59,191],0,2,1,2311,0,0,5,0,0,0,0,'2',0,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ ]). poly('black','',2,[ 765,96,923,189],0,3,1,2312,0,0,5,0,0,0,0,'3',0,0, "0","",[ 0,12,5,0,'12','5','0'],[0,12,5,0,'12','5','0'],[ ]). group([ text('black',91,302,1,0,1,252,17,2235,12,4,0,0,0,0,2,252,17,0,0,"",0,0,0,0,315,'',[ minilines(252,17,0,0,0,0,0,[ mini_line(252,13,4,0,0,0,[ str_block(0,81,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,81,12,4,0,-1,0,0,0,0,0, "MEMBER_ID")]), str_block(0,171,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,171,13,3,0,-1,0,0,0,0,0, " original_sender_id")]) ]) ])]), text('black',377,302,1,0,1,207,17,2236,12,4,0,0,0,0,2,207,17,0,0,"",0,0,0,0,315,'',[ minilines(207,17,0,0,0,0,0,[ mini_line(207,13,4,0,0,0,[ str_block(0,108,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,108,12,4,0,-8,0,0,0,0,0, "DATA_PACKET ")]), str_block(0,99,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-2,0,0,0,0,0, "data_packet")]) ]) ])]), text('black',73,274,1,0,1,135,16,2237,12,4,0,0,0,0,2,135,16,0,0,"",0,0,0,0,286,'',[ minilines(135,16,0,0,0,0,0,[ mini_line(135,12,4,0,0,0,[ str_block(0,135,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,135,12,4,0,-1,0,0,0,0,0, "RETRANSM_PACKET")]) ]) ])]), text('black',91,370,1,0,1,243,17,2238,12,4,0,0,0,0,2,243,17,0,0,"",0,0,0,0,383,'',[ minilines(243,17,0,0,0,0,0,[ mini_line(243,13,4,0,0,0,[ str_block(0,81,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,81,12,4,0,-1,0,0,0,0,0, "MEMBER_ID")]), str_block(0,162,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,162,13,3,0,-1,0,0,0,0,0, " request_member_id")]) ]) ])]), text('black',381,370,1,0,1,54,17,2239,12,4,0,0,0,0,2,54,17,0,0,"",0,0,0,0,383,'',[ minilines(54,17,0,0,0,0,0,[ mini_line(54,13,4,0,0,0,[ str_block(0,36,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,36,12,4,0,-8,0,0,0,0,0, "int ")]), str_block(0,18,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,18,13,3,0,-1,0,0,0,0,0, "sn")]) ]) ])]), text('black',75,342,1,0,1,90,16,2240,12,4,0,0,0,0,2,90,16,0,0,"",0,0,0,0,354,'',[ minilines(90,16,0,0,0,0,0,[ mini_line(90,12,4,0,0,0,[ str_block(0,90,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,90,12,4,0,-1,0,0,0,0,0, "NAK_PACKET")]) ]) ])]), box('black','',73,432,312,466,0,1,1,2241,0,0,0,1,0,'1',0,[ 73,432,73,432,312,496,1000,0,0,531.25,0,0],[ ]), text('black',91,441,1,0,1,207,17,2242,12,4,0,0,0,0,2,207,17,0,0,"",0,0,0,0,454,'',[ minilines(207,17,0,0,0,0,0,[ mini_line(207,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,180,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,180,13,3,0,-2,0,0,0,0,0, " sn_of_last_msg_sent")]) ]) ])]), text('black',73,415,1,0,1,126,16,2243,12,4,0,0,0,0,2,126,16,0,0,"",0,0,0,0,427,'',[ minilines(126,16,0,0,0,0,0,[ mini_line(126,12,4,0,0,0,[ str_block(0,126,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,126,12,4,0,-1,0,0,0,0,0, "REFRESH_PACKET")]) ]) ])]), text('black',77,487,1,0,1,162,16,2244,12,4,0,0,0,0,2,162,16,0,0,"",0,0,0,0,499,'',[ minilines(162,16,0,0,0,0,0,[ mini_line(162,12,4,0,0,0,[ str_block(0,162,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,162,12,4,0,-1,0,0,0,0,0, "JOIN_ACCEPT_PACKET")]) ]) ])]), box('black','',59,192,924,549,0,1,1,2245,0,0,0,0,0,'1',0,[ ]), text('black',91,514,1,0,1,72,17,2246,12,4,0,0,0,0,2,72,17,0,0,"",0,0,0,0,527,'',[ minilines(72,17,0,0,0,0,0,[ mini_line(72,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,45,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-2,0,0,0,0,0, " port")]) ]) ])]), text('black',91,229,1,0,1,54,17,2247,12,4,0,0,0,0,2,54,17,0,0,"",0,0,0,0,242,'',[ minilines(54,17,0,0,0,0,0,[ mini_line(54,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, " sn")]) ]) ])]), text('black',182,229,1,0,1,117,17,2248,12,4,0,0,0,0,2,117,17,0,0,"",0,0,0,0,242,'',[ minilines(117,17,0,0,0,0,0,[ mini_line(117,13,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, " data_size")]) ]) ])]), text('black',72,201,1,0,1,99,16,2249,12,4,0,0,0,0,2,99,16,0,0,"",0,0,0,0,213,'',[ minilines(99,16,0,0,0,0,0,[ mini_line(99,12,4,0,0,0,[ str_block(0,99,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,99,12,4,0,-1,0,0,0,0,0, "DATA_PACKET")]) ]) ])]), text('black',326,229,1,0,1,90,17,2250,12,4,0,0,0,0,2,90,17,0,0,"",0,0,0,0,242,'',[ minilines(90,17,0,0,0,0,0,[ mini_line(90,13,4,0,0,0,[ str_block(0,36,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,36,12,4,0,-1,0,0,0,0,0, "BYTE")]), str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, " *data")]) ]) ])]), box('black','',78,505,187,539,0,1,1,2251,0,0,0,0,0,'1',0,[ ]), group([ box('black','',70,219,166,253,0,1,1,2255,0,0,0,1,0,'1',0,[ 70,219,70,219,166,258,1000,0,0,871.795,0,0],[ ]), box('black','',166,219,310,253,0,1,1,2254,0,0,0,1,0,'1',0,[ 166,219,166,219,310,258,1000,0,0,871.795,0,0],[ ]), box('black','',310,219,438,253,0,1,1,2253,0,0,0,1,0,'1',0,[ 310,219,310,219,438,258,1000,0,0,871.795,0,0],[ ]) ], 2252,0,0,[ ]), group([ box('black','',73,291,359,325,0,1,1,2258,0,0,0,1,0,'1',0,[ 73,291,73,291,359,355,1000,0,0,531.25,0,0],[ ]), box('black','',359,291,595,325,0,1,1,2257,0,0,0,1,0,'1',0,[ 359,291,359,291,595,355,1000,0,0,531.25,0,0],[ ]) ], 2256,0,0,[ ]), box('black','',75,360,361,394,0,1,1,2259,0,0,0,1,0,'1',0,[ 75,360,75,360,361,424,1000,0,0,531.25,0,0],[ ]), box('black','',361,360,445,394,0,1,1,2260,0,0,0,1,0,'1',0,[ 361,360,361,360,445,424,1000,0,0,531.25,0,0],[ ]), text('black',465,370,1,0,1,99,17,2262,12,4,0,0,0,0,2,99,17,0,0,"",0,0,0,0,383,'',[ minilines(99,17,0,0,0,0,0,[ mini_line(99,13,4,0,0,0,[ str_block(0,36,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,36,12,4,0,-8,0,0,0,0,0, "int ")]), str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "base_sn")]) ]) ])]), box('black','',445,360,573,394,0,1,1,2263,0,0,0,1,0,'1',0,[ 445,360,445,360,529,424,1523.81,0,0,531.25,0,0],[ ]), box('black','',726,360,818,394,0,1,1,2264,0,0,0,1,0,'1',0,[ 734,360,734,360,818,424,1095.24,0,0,531.25,-8,0],[ ]), box('black','',573,360,726,394,0,1,1,2265,0,0,0,1,0,'1',0,[ 573,360,573,360,657,424,1821.43,0,0,531.25,0,0],[ ]), box('black','',818,360,909,394,0,1,1,2266,0,0,0,1,0,'1',0,[ 818,360,818,360,902,424,1083.33,0,0,531.25,0,0],[ ]), text('black',578,370,1,0,1,144,17,2267,12,4,0,0,0,0,2,144,17,0,0,"",0,0,0,0,383,'',[ minilines(144,17,0,0,0,0,0,[ mini_line(144,13,4,0,0,0,[ str_block(0,36,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,36,12,4,0,-8,0,0,0,0,0, "int ")]), str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "windows_size")]) ]) ])]), text('black',729,370,1,0,1,81,17,2268,12,4,0,0,0,0,2,81,17,0,0,"",0,0,0,0,383,'',[ minilines(81,17,0,0,0,0,0,[ mini_line(81,13,4,0,0,0,[ str_block(0,36,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,36,12,4,0,-8,0,0,0,0,0, "int ")]), str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "hmask")]) ]) ])]), text('black',822,370,1,0,1,81,17,2269,12,4,0,0,0,0,2,81,17,0,0,"",0,0,0,0,383,'',[ minilines(81,17,0,0,0,0,0,[ mini_line(81,13,4,0,0,0,[ str_block(0,36,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,36,12,4,0,-8,0,0,0,0,0, "int ")]), str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "lmask")]) ]) ])]) ], 2363,0,0,[ ]). box('black','',5,1,936,567,0,2,1,2370,0,0,0,0,0,'2',0,[ ]). page(3,"cache",1,''). group([ box('red','',19,75,307,139,0,1,1,229,0,0,0,0,0,'1',0,[ ]), text('black',51,94,1,0,1,198,17,230,12,4,0,0,0,0,2,198,17,0,0,"",0,0,0,0,107,'',[ minilines(198,17,0,0,0,0,0,[ mini_line(198,13,4,0,0,0,[ str_block(0,108,12,4,0,-8,0,0,0,[ str_seg('red','Courier-Bold',1,80640,108,12,4,0,-8,0,0,0,0,0, "DATA_PACKET ")]), str_block(0,90,13,3,0,-2,0,0,0,[ str_seg('red','Courier',0,80640,90,13,3,0,-2,0,0,0,0,0, " data_pckt")]) ]) ])]), text('black',19,47,1,0,1,90,16,233,12,4,0,0,0,0,2,90,16,0,0,"",0,0,0,0,59,'',[ minilines(90,16,0,0,0,0,0,[ mini_line(90,12,4,0,0,0,[ str_block(0,90,12,4,0,-1,0,0,0,[ str_seg('pink','Courier-Bold',1,80640,90,12,4,0,-1,0,0,0,0,0, "CACHE_NODE")]) ]) ])]), text('black',19,175,1,0,1,72,16,248,12,4,0,0,0,0,2,72,16,0,0,"",0,0,0,0,187,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,12,4,0,0,0,[ str_block(0,72,12,4,0,-1,0,0,0,[ str_seg('green','Courier-Bold',1,80640,72,12,4,0,-1,0,0,0,0,0, "NAK_LIST")]) ]) ])]), box('green','',19,203,115,267,0,1,1,336,0,0,0,0,0,'1',0,[ ]), text('black',51,223,1,0,1,54,16,337,12,4,0,0,0,0,2,54,16,0,0,"",0,0,0,0,235,'',[ minilines(54,16,0,0,0,0,0,[ mini_line(54,12,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('green','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,27,12,4,0,0,0,0,0,[ str_seg('green','Courier-Bold',1,80640,27,12,4,0,0,0,0,0,0,0, " sn")]) ]) ])]), box('green','',115,203,259,267,0,1,1,338,0,0,0,0,0,'1',0,[ ]), text('black',131,223,1,0,1,99,16,339,12,4,0,0,0,0,2,99,16,0,0,"",0,0,0,0,235,'',[ minilines(99,16,0,0,0,0,0,[ mini_line(99,12,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('green','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,72,12,4,0,-1,0,0,0,[ str_seg('green','Courier-Bold',1,80640,72,12,4,0,-1,0,0,0,0,0, " counter")]) ]) ])]), box('black','',20,328,243,392,0,1,1,456,0,0,0,0,0,'1',0,[ ]), text('black',52,347,1,0,1,171,17,457,12,4,0,0,0,0,2,171,17,0,0,"",0,0,0,0,360,'',[ minilines(171,17,0,0,0,0,0,[ mini_line(171,13,4,0,0,0,[ str_block(0,36,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,36,12,4,0,-8,0,0,0,0,0, "int ")]), str_block(0,135,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,135,13,3,0,-2,0,0,0,0,0, "number_of_nodes")]) ]) ])]), box('black','',20,392,149,456,0,1,1,458,0,0,0,0,0,'1',0,[ ]), text('black',45,411,1,0,1,90,17,459,12,4,0,0,0,0,2,90,17,0,0,"",0,0,0,0,424,'',[ minilines(90,17,0,0,0,0,0,[ mini_line(90,13,4,0,0,0,[ str_block(0,36,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,36,12,4,0,-8,0,0,0,0,0, "int ")]), str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "active")]) ]) ])]), text('black',20,299,1,0,1,45,16,460,13,3,0,0,0,0,2,45,16,0,0,"",0,0,0,0,312,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "CACHE")]) ]) ])]), group([ box('pink','',307,75,579,139,0,1,1,231,0,0,0,0,0,'1',0,[ ]), text('black',323,95,1,0,1,225,16,232,12,4,0,0,0,0,2,225,16,0,0,"",0,0,0,0,107,'',[ minilines(225,16,0,0,0,0,0,[ mini_line(225,12,4,0,0,0,[ str_block(0,180,12,4,0,-8,0,0,0,[ str_seg('pink','Courier-Bold',1,80640,180,12,4,0,-8,0,0,0,0,0, "struct SCACHE_NODE ")]), str_block(0,45,12,4,0,-1,0,0,0,[ str_seg('pink','Courier-Bold',1,80640,45,12,4,0,-1,0,0,0,0,0, "*next")]) ]) ])]), box('green','',259,203,435,267,0,1,1,340,0,0,0,0,0,'1',0,[ ]), text('black',275,223,1,0,1,135,16,341,12,4,0,0,0,0,2,135,16,0,0,"",0,0,0,0,235,'',[ minilines(135,16,0,0,0,0,0,[ mini_line(135,12,4,0,0,0,[ str_block(0,27,12,4,0,-1,0,0,0,[ str_seg('green','Courier-Bold',1,80640,27,12,4,0,-1,0,0,0,0,0, "int")]), str_block(0,108,12,4,0,0,0,0,0,[ str_seg('green','Courier-Bold',1,80640,108,12,4,0,0,0,0,0,0,0, " hasReceived")]) ]) ])]), box('green','',435,203,691,267,0,1,1,342,0,0,0,0,0,'1',0,[ ]), text('black',451,223,1,0,1,234,16,343,12,4,0,0,0,0,2,234,16,0,0,"",0,0,0,0,235,'',[ minilines(234,16,0,0,0,0,0,[ mini_line(234,12,4,0,0,0,[ str_block(0,153,12,4,0,-8,0,0,0,[ str_seg('green','Courier-Bold',1,80640,153,12,4,0,-8,0,0,0,0,0, "struct SNAK_LIST ")]), str_block(0,81,12,4,0,-1,0,0,0,[ str_seg('green','Courier-Bold',1,80640,81,12,4,0,-1,0,0,0,0,0, "*previous")]) ]) ])]), text('black',707,223,1,0,1,198,16,371,12,4,0,0,0,0,2,198,16,0,0,"",0,0,0,0,235,'',[ minilines(198,16,0,0,0,0,0,[ mini_line(198,12,4,0,0,0,[ str_block(0,153,12,4,0,-8,0,0,0,[ str_seg('green','Courier-Bold',1,80640,153,12,4,0,-8,0,0,0,0,0, "struct SNAK_LIST ")]), str_block(0,45,12,4,0,-1,0,0,0,[ str_seg('green','Courier-Bold',1,80640,45,12,4,0,-1,0,0,0,0,0, "*next")]) ]) ])]), box('green','',691,203,916,267,0,1,1,393,0,0,0,0,0,'1',0,[ ]), box('CadetBlue','',243,328,424,392,0,1,1,486,0,0,0,0,0,'1',0,[ ]), text('black',267,347,1,0,1,135,17,487,12,4,0,0,0,0,2,135,17,0,0,"",0,0,0,0,360,'',[ minilines(135,17,0,0,0,0,0,[ mini_line(135,13,4,0,0,0,[ str_block(0,72,12,4,0,-8,0,0,0,[ str_seg('CadetBlue','Courier-Bold',1,80640,72,12,4,0,-8,0,0,0,0,0, "SM_INFO ")]), str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('CadetBlue','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "sm_info")]) ]) ])]), box('pink','',424,328,608,392,0,1,1,492,0,0,0,0,0,'1',0,[ ]), text('black',449,348,1,0,1,153,16,493,12,4,0,0,0,0,2,153,16,0,0,"",0,0,0,0,360,'',[ minilines(153,16,0,0,0,0,0,[ mini_line(153,12,4,0,0,0,[ str_block(0,99,12,4,0,-8,0,0,0,[ str_seg('pink','Courier-Bold',1,80640,99,12,4,0,-8,0,0,0,0,0, "CACHE_NODE ")]), str_block(0,54,12,4,0,-1,0,0,0,[ str_seg('pink','Courier-Bold',1,80640,54,12,4,0,-1,0,0,0,0,0, "*first")]) ]) ])]), box('pink','',608,328,792,392,0,1,1,500,0,0,0,0,0,'1',0,[ ]), text('black',633,348,1,0,1,144,16,501,12,4,0,0,0,0,2,144,16,0,0,"",0,0,0,0,360,'',[ minilines(144,16,0,0,0,0,0,[ mini_line(144,12,4,0,0,0,[ str_block(0,99,12,4,0,-8,0,0,0,[ str_seg('pink','Courier-Bold',1,80640,99,12,4,0,-8,0,0,0,0,0, "CACHE_NODE ")]), str_block(0,45,12,4,0,-1,0,0,0,[ str_seg('pink','Courier-Bold',1,80640,45,12,4,0,-1,0,0,0,0,0, "*last")]) ]) ])]), box('pink','',792,328,1042,392,0,1,1,502,0,0,0,0,0,'1',0,[ ]), text('black',813,347,1,0,1,225,16,503,12,4,0,0,0,0,2,225,16,0,0,"",0,0,0,0,359,'',[ minilines(225,16,0,0,0,0,0,[ mini_line(225,12,4,0,0,0,[ str_block(0,99,12,4,0,-8,0,0,0,[ str_seg('pink','Courier-Bold',1,80640,99,12,4,0,-8,0,0,0,0,0, "CACHE_NODE ")]), str_block(0,126,12,4,0,0,0,0,0,[ str_seg('pink','Courier-Bold',1,80640,126,12,4,0,0,0,0,0,0,0, "*last_inserted")]) ]) ])]), box('green','',149,392,343,456,0,1,1,571,0,0,0,0,0,'1',0,[ ]), text('black',171,415,1,0,1,162,17,574,12,4,0,0,0,0,2,162,17,0,0,"",0,0,0,0,428,'',[ minilines(162,17,0,0,0,0,0,[ mini_line(162,13,4,0,0,0,[ str_block(0,81,12,4,0,-8,0,0,0,[ str_seg('green','Courier-Bold',1,80640,81,12,4,0,-8,0,0,0,0,0, "NAK_LIST ")]), str_block(0,81,13,3,0,-2,0,0,0,[ str_seg('green','Courier',0,80640,81,13,3,0,-2,0,0,0,0,0, "*nak_list")]) ]) ])]), box('black','',344,394,565,457,0,1,1,581,0,0,0,0,0,'1',0,[ ]), text('black',373,415,1,0,1,171,17,584,12,4,0,0,0,0,2,171,17,0,0,"",0,0,0,0,428,'',[ minilines(171,17,0,0,0,0,0,[ mini_line(171,13,4,0,0,0,[ str_block(0,126,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,126,12,4,0,-8,0,0,0,0,0, "struct SCACHE ")]), str_block(0,45,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-2,0,0,0,0,0, "*next")]) ]) ])]) ], 1261,0,0,[ ]) ], 1296,0,0,[ ]). box('CadetBlue','',9,25,1064,517,0,1,1,1297,0,0,0,0,0,'1',0,[ ]). text('CadetBlue',901,530,1,0,1,162,16,1299,12,4,0,0,0,0,2,162,16,0,0,"",0,0,0,0,542,'',[ minilines(162,16,0,0,0,0,0,[ mini_line(162,12,4,0,0,0,[ str_block(0,162,12,4,0,-1,0,0,0,[ str_seg('CadetBlue','Courier-Bold',1,80640,162,12,4,0,-1,0,0,0,0,0, "Cache informations")]) ]) ])]). page(4,"event",1,''). text('black',23,20,1,0,1,90,16,603,12,4,0,0,0,0,2,90,16,0,0,"",0,0,0,0,32,'',[ minilines(90,16,0,0,0,0,0,[ mini_line(90,12,4,0,0,0,[ str_block(0,90,12,4,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,80640,90,12,4,0,-1,0,0,0,0,0, "EVENT_LIST")]) ]) ])]). box('blue','',23,48,211,112,0,1,1,604,0,0,0,0,0,'1',0,[ ]). text('black',36,67,1,0,1,171,17,605,12,4,0,0,0,0,2,171,17,0,0,"",0,0,0,0,80,'',[ minilines(171,17,0,0,0,0,0,[ mini_line(171,13,4,0,0,0,[ str_block(0,90,12,4,0,-8,0,0,0,[ str_seg('blue','Courier-Bold',1,80640,90,12,4,0,-8,0,0,0,0,0, "MEMBER_ID ")]), str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "member_id")]) ]) ])]). box('black','',211,48,325,112,0,1,1,606,0,0,0,0,0,'1',0,[ ]). text('black',332,68,1,0,1,144,17,607,12,4,0,0,0,0,2,144,17,0,0,"",0,0,0,0,81,'',[ minilines(144,17,0,0,0,0,0,[ mini_line(144,13,4,0,0,0,[ str_block(0,45,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,45,12,4,0,-8,0,0,0,0,0, "long ")]), str_block(0,99,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-1,0,0,0,0,0, "timer_value")]) ]) ])]). box('black','',325,48,481,112,0,1,1,608,0,0,0,0,0,'1',0,[ ]). text('black',222,67,1,0,1,99,17,609,12,4,0,0,0,0,2,99,17,0,0,"",0,0,0,0,80,'',[ minilines(99,17,0,0,0,0,0,[ mini_line(99,13,4,0,0,0,[ str_block(0,45,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,45,12,4,0,-8,0,0,0,0,0, "char ")]), str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "action")]) ]) ])]). box('black','',481,48,557,112,0,1,1,610,0,0,0,0,0,'1',0,[ ]). text('black',488,69,1,0,1,54,17,611,12,4,0,0,0,0,2,54,17,0,0,"",0,0,0,0,82,'',[ minilines(54,17,0,0,0,0,0,[ mini_line(54,13,4,0,0,0,[ str_block(0,36,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,36,12,4,0,-8,0,0,0,0,0, "int ")]), str_block(0,18,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,18,13,3,0,-1,0,0,0,0,0, "sn")]) ]) ])]). text('black',562,69,1,0,1,234,17,612,12,4,0,0,0,0,2,234,17,0,0,"",0,0,0,0,82,'',[ minilines(234,17,0,0,0,0,0,[ mini_line(234,13,4,0,0,0,[ str_block(0,63,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,63,12,4,0,-8,0,0,0,0,0, "struct ")]), str_block(0,171,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,171,13,3,0,-1,0,0,0,0,0, "timeval time_of_day")]) ]) ])]). box('black','',557,48,810,112,0,1,1,613,0,0,0,0,0,'1',0,[ ]). group([ text('black',34,138,1,0,1,261,17,646,12,4,0,0,0,0,2,261,17,0,0,"",0,0,0,0,151,'',[ minilines(261,17,0,0,0,0,0,[ mini_line(261,13,4,0,0,0,[ str_block(0,171,12,4,0,-8,0,0,0,[ str_seg('black','Courier-Bold',1,80640,171,12,4,0,-8,0,0,0,0,0, "struct SEVENT_LIST ")]), str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, "EVENT_LIST")]) ]) ])]), box('black','',23,112,296,176,0,1,1,667,0,0,0,0,0,'1',0,[ ]) ], 1303,0,0,[ ]). box('CadetBlue','',5,11,884,217,0,1,1,1741,0,0,0,0,0,'1',0,[ ]). text('CadetBlue',683,221,1,0,1,198,16,1742,12,4,0,0,0,0,2,198,16,0,0,"",0,0,0,0,233,'',[ minilines(198,16,0,0,0,0,0,[ mini_line(198,12,4,0,0,0,[ str_block(0,198,12,4,0,0,0,0,0,[ str_seg('CadetBlue','Courier-Bold',1,80640,198,12,4,0,0,0,0,0,0,0, "Event List Information")]) ]) ])]). tgif-QPL-4.2.5/rmcast/doc/manual/nack_mask.eps0000644000076400007640000002440510122646341020752 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 46 648 322 776 %%Title: nack_mask %%CreationDate: Tue May 14 16:47:30 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 53 dict def tgifdict begin /tgifarrowtipdict 8 dict def tgifarrowtipdict /mtrx matrix put /TGAT % tgifarrowtip { tgifarrowtipdict begin /dy exch def /dx exch def /h exch def /w exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate dy dx atan rotate 0 0 moveto w neg h lineto w neg h neg lineto savematrix setmatrix end } def /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 46 648 322 776 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % TEXT NP 0 SG GS 1 W 188 99 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (1) SH GR GR % TEXT NP 0 SG GS 1 W 184 203 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (3) SH GR GR % TEXT NP 0 SG GS 1 W 156 42 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (Decimal Form) SH GR GR % TEXT NP 0 SG GS 1 W 343 42 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (Binary Form) SH GR GR % TEXT NP 0 SG GS 1 W 85 99 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (hmask) SH GR GR % TEXT NP 0 SG GS 1 W 85 203 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (lmask) SH GR GR % BOX 0 SG GS 10 SM GS NP 148 50 M 571 50 L 571 253 L 148 253 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 247 51 M 247 254 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 148 149 M 571 149 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 315 92 M GS 0 SG /Courier FF [24 0 0 -24 0 0] MS (...) SH GR GR % BOX 0 SG GS 10 SM GS NP 263 72 M 288 72 L 288 104 L 263 104 L CP S GR GR % TEXT NP 0 SG GS 1 W 276 93 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (0) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (0) SH GR GR % BOX 0 SG GS 10 SM GS NP 290 72 M 315 72 L 315 104 L 290 104 L CP S GR GR % TEXT NP 0 SG GS 1 W 302 93 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (0) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (0) SH GR GR % BOX 0 SG GS 10 SM GS NP 361 73 M 386 73 L 386 105 L 361 105 L CP S GR GR % TEXT NP 0 SG GS 1 W 374 94 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (0) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (0) SH GR GR % BOX 0 SG GS 10 SM GS NP 388 73 M 413 73 L 413 105 L 388 105 L CP S GR GR % TEXT NP 0 SG GS 1 W 400 94 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (0) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (0) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 262 109 M 262 120 L 441 120 L 441 110 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 286 136 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (32 positions) SH GR GR % TEXT NP 0 SG GS 1 W 420 66 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (32) SH GR GR % TEXT NP 0 SG GS 1 W 394 66 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (33) SH GR GR % TEXT NP 0 SG GS 1 W 296 66 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (62) SH GR GR % TEXT NP 0 SG GS 1 W 269 66 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (63) SH GR GR % TEXT NP 0 SG GS 1 W 463 65 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (position number) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 460 62 M 0 -18 atan DU cos 8.000 MU 442 exch SU exch sin 8.000 MU 62 exch SU L TGSM 1 W S GR GS TGSM NP 442 62 8.000 3.000 -18 0 TGAT 1 SG CP F 0 SG NP 442 62 8.000 3.000 -18 0 TGAT CP F GR % BOX 0 SG GS 10 SM GS NP 415 73 M 440 73 L 440 105 L 415 105 L CP S GR GR % TEXT NP 0 SG GS 1 W 428 94 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (1) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (1) SH GR GR % TEXT NP 0 SG GS 1 W 367 66 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (34) SH GR GR % TEXT NP 0 SG GS 1 W 315 200 M GS 0 SG /Courier FF [24 0 0 -24 0 0] MS (...) SH GR GR % BOX 0 SG GS 10 SM GS NP 263 180 M 288 180 L 288 212 L 263 212 L CP S GR GR % TEXT NP 0 SG GS 1 W 276 201 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (0) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (0) SH GR GR % BOX 0 SG GS 10 SM GS NP 290 180 M 315 180 L 315 212 L 290 212 L CP S GR GR % TEXT NP 0 SG GS 1 W 302 201 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (0) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (0) SH GR GR % BOX 0 SG GS 10 SM GS NP 361 181 M 386 181 L 386 213 L 361 213 L CP S GR GR % TEXT NP 0 SG GS 1 W 374 202 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (0) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (0) SH GR GR % BOX 0 SG GS 10 SM GS NP 388 181 M 413 181 L 413 213 L 388 213 L CP S GR GR % TEXT NP 0 SG GS 1 W 400 202 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (1) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (1) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 262 217 M 262 228 L 441 228 L 441 218 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 286 244 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (32 positions) SH GR GR % TEXT NP 0 SG GS 1 W 424 174 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (0) SH GR GR % TEXT NP 0 SG GS 1 W 396 174 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (1) SH GR GR % TEXT NP 0 SG GS 1 W 296 174 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (30) SH GR GR % TEXT NP 0 SG GS 1 W 269 174 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (31) SH GR GR % TEXT NP 0 SG GS 1 W 463 173 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (position number) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 460 170 M 0 -18 atan DU cos 8.000 MU 442 exch SU exch sin 8.000 MU 170 exch SU L TGSM 1 W S GR GS TGSM NP 442 170 8.000 3.000 -18 0 TGAT 1 SG CP F 0 SG NP 442 170 8.000 3.000 -18 0 TGAT CP F GR % BOX 0 SG GS 10 SM GS NP 415 181 M 440 181 L 440 213 L 415 213 L CP S GR GR % TEXT NP 0 SG GS 1 W 428 202 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (1) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (1) SH GR GR % TEXT NP 0 SG GS 1 W 370 174 M GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (2) SH GR GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Tue May 14 16:47:30 2002 %%DocumentFonts: Courier %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/cache.eps0000644000076400007640000006451110122646341020070 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 51 213 532 761 %%Title: cache %%CreationDate: Tue May 14 17:12:03 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 88 dict def tgifdict begin /tgifellipsedict 6 dict def tgifellipsedict /mtrx matrix put /TGEL % tgifellipse { tgifellipsedict begin /yrad exch def /xrad exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate xrad yrad scale 0 0 1 0 360 arc savematrix setmatrix end } def /tgifarrowtipdict 8 dict def tgifarrowtipdict /mtrx matrix put /TGAT % tgifarrowtip { tgifarrowtipdict begin /dy exch def /dx exch def /h exch def /w exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate dy dx atan rotate 0 0 moveto w neg h lineto w neg h neg lineto savematrix setmatrix end } def /tgifpatdict 10 dict def /tgifpatbyte { currentdict /retstr get exch pat i cellsz mod get put } def /tgifpatproc { 0 1 widthlim {tgifpatbyte} for retstr /i i 1 add def } def /TGPF % tgifpatfill { tgifpatdict begin /h exch def /w exch def /lty exch def /ltx exch def /cellsz exch def /pat exch def /widthlim w cellsz div cvi 1 sub def /retstr widthlim 1 add string def /i 0 def tgiforigctm setmatrix ltx lty translate w h true [1 0 0 1 0 0] {tgifpatproc} imagemask ltx neg lty neg translate end } def /pat3 <8000000008000000> def /pat4 <8800000022000000> def /pat5 <8800220088002200> def /pat6 <8822882288228822> def /pat7 def /pat8 <77dd77dd77dd77dd> def /pat9 <77ffddff77ffddff> def /pat10 <77ffffff77ffffff> def /pat11 <7fffffff7fffffff> def /pat12 <8040200002040800> def /pat13 <40a00000040a0000> def /pat14 def /pat15 def /pat16 def /pat17 <038448300c020101> def /pat18 <081c22c180010204> def /pat19 <8080413e080814e3> def /pat20 <8040201008040201> def /pat21 <8844221188442211> def /pat22 <77bbddee77bbddee> def /pat23 def /pat24 <7fbfdfeff7fbfdfe> def /pat25 <3e1f8fc7e3f1f87c> def /pat26 <0102040810204080> def /pat27 <1122448811224488> def /pat28 def /pat29 <83070e1c3870e0c1> def /pat30 def /pat31 <7cf8f1e3c78f1f3e> def /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 51 213 532 761 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % POLY/OPEN-SPLINE 0 SG GS NP 195 658 M 29 0 atan DU cos 8.000 MU 195 exch SU exch sin 8.000 MU 687 exch SU L TGSM 1 W S GR GS TGSM NP 195 687 8.000 3.000 0 29 TGAT 1 SG CP F 0 SG NP 195 687 8.000 3.000 0 29 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 305 471 M 0 62 atan DU cos 8.000 MU 367 exch SU exch sin 8.000 MU 471 exch SU L TGSM 1 W S GR GS TGSM NP 367 471 8.000 3.000 62 0 TGAT 1 SG CP F 0 SG NP 367 471 8.000 3.000 62 0 TGAT CP F GR % OVAL 0 SG GS NP 389 470 17 17 TGEL CP EC NP pat26 8 368 448 40 48 TGPF GR GS GS NP 389 470 17 17 TGEL S GR GR % OVAL 0 SG GS NP 495 471 17 17 TGEL CP EC NP pat26 8 472 448 48 48 TGPF GR GS GS NP 495 471 17 17 TGEL S GR GR % OVAL 0 SG GS NP 598 470 17 17 TGEL CP EC NP pat12 8 576 448 48 48 TGPF GR GS GS NP 598 470 17 17 TGEL S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 410 470 M 0 62 atan DU cos 8.000 MU 472 exch SU exch sin 8.000 MU 470 exch SU L TGSM 1 W S GR GS TGSM NP 472 470 8.000 3.000 62 0 TGAT 1 SG CP F 0 SG NP 472 470 8.000 3.000 62 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 515 470 M 0 62 atan DU cos 8.000 MU 577 exch SU exch sin 8.000 MU 470 exch SU L TGSM 1 W S GR GS TGSM NP 577 470 8.000 3.000 62 0 TGAT 1 SG CP F 0 SG NP 577 470 8.000 3.000 62 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 304 630 M 0 62 atan DU cos 8.000 MU 366 exch SU exch sin 8.000 MU 630 exch SU L TGSM 1 W S GR GS TGSM NP 366 630 8.000 3.000 62 0 TGAT 1 SG CP F 0 SG NP 366 630 8.000 3.000 62 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 621 470 M 661 470 L 25 0 atan DU cos 8.000 MU 661 exch SU exch sin 8.000 MU 495 exch SU L TGSM 1 W S GR GS TGSM NP 661 495 8.000 3.000 0 25 TGAT 1 SG CP F 0 SG NP 661 495 8.000 3.000 0 25 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 626 500 M 700 500 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 636 506 M 688 506 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 651 512 M 669 512 L TGSM 1 W S GR % OVAL 0 SG GS GS NP 385 628 17 17 TGEL S GR GR % OVAL 0 SG GS GS NP 491 629 17 17 TGEL S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 406 628 M 0 62 atan DU cos 8.000 MU 468 exch SU exch sin 8.000 MU 628 exch SU L TGSM 1 W S GR GS TGSM NP 468 628 8.000 3.000 62 0 TGAT 1 SG CP F 0 SG NP 468 628 8.000 3.000 62 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 516 628 M 556 628 L 25 0 atan DU cos 8.000 MU 556 exch SU exch sin 8.000 MU 653 exch SU L TGSM 1 W S GR GS TGSM NP 556 653 8.000 3.000 0 25 TGAT 1 SG CP F 0 SG NP 556 653 8.000 3.000 0 25 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 521 658 M 595 658 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 531 667 M 583 667 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 546 677 M 564 677 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 104 381 M 305 381 L 305 413 L 104 413 L CP S GR GR % TEXT NP 0 SG GS 1 W 125 402 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (number_of_nodes: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (3) SH GR GR % BOX 0 SG GS 10 SM GS NP 104 418 M 305 418 L 305 450 L 104 450 L CP S GR GR % TEXT NP 0 SG GS 1 W 125 439 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (active: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (1) SH GR GR % BOX 0 SG GS 10 SM GS NP 104 454 M 305 454 L 305 486 L 104 486 L CP S GR GR % TEXT NP 0 SG GS 1 W 125 475 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (first) SH GR GR % BOX 0 SG GS 10 SM GS NP 107 525 M 297 525 L 297 557 L 107 557 L CP S GR GR % TEXT NP 0 SG GS 113 527 TR [0.945 0.000 0.000 1.000 -2 0] CO 113 NE 527 NE TR GR GS 1 W 113 527 TR [0.945 0.000 0.000 1.000 -2 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS ( member_id ) SH GR 0 14 RM GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (\(ip: 192.168.0.2, pid: 123\)) SH GR GR % BOX 0 SG GS 10 SM GS NP 107 570 M 296 570 L 296 602 L 107 602 L CP 2 W [2 2] 0 SD S GR GR % TEXT NP 0 SG GS 111 578 TR [0.940 0.000 0.000 1.000 -1 0] CO 111 NE 578 NE TR GR GS 1 W 111 578 TR [0.940 0.000 0.000 1.000 -1 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS ( member_status) SH GR GR % TEXT NP 0 SG GS 1 W 108 510 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (sm_info) SH GR GR % BOX 0 SG GS 10 SM GS NP 104 491 M 305 491 L 305 612 L 104 612 L CP 2 W S GR GR % BOX 0 SG GS 10 SM GS NP 104 616 M 305 616 L 305 648 L 104 648 L CP S GR GR % TEXT NP 0 SG GS 1 W 125 637 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nak_list) SH GR GR % BOX 0 SG GS 10 SM GS NP 97 374 M 313 374 L 313 655 L 97 655 L CP 3 W S GR GR % BOX 0 SG GS 10 SM GS NP 105 697 M 306 697 L 306 729 L 105 729 L CP S GR GR % TEXT NP 0 SG GS 1 W 126 718 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (number_of_nodes: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (1) SH GR GR % BOX 0 SG GS 10 SM GS NP 105 734 M 306 734 L 306 766 L 105 766 L CP S GR GR % TEXT NP 0 SG GS 1 W 126 755 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (active: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (1) SH GR GR % BOX 0 SG GS 10 SM GS NP 105 770 M 306 770 L 306 802 L 105 802 L CP S GR GR % TEXT NP 0 SG GS 1 W 126 791 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (first) SH GR GR % BOX 0 SG GS 10 SM GS NP 108 841 M 298 841 L 298 873 L 108 873 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 108 886 M 297 886 L 297 918 L 108 918 L CP S GR GR % TEXT NP 0 SG GS 129 894 TR [0.940 0.000 0.000 1.000 -1 0] CO 129 NE 894 NE TR GR GS 1 W 129 894 TR [0.940 0.000 0.000 1.000 -1 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS ( member_status) SH GR GR % TEXT NP 0 SG GS 1 W 109 826 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (sm_info) SH GR GR % BOX 0 SG GS 10 SM GS NP 105 807 M 306 807 L 306 928 L 105 928 L CP 2 W S GR GR % BOX 0 SG GS 10 SM GS NP 105 932 M 306 932 L 306 964 L 105 964 L CP S GR GR % TEXT NP 0 SG GS 1 W 126 953 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nak_list) SH GR GR % BOX 0 SG GS 10 SM GS NP 98 690 M 314 690 L 314 971 L 98 971 L CP 3 W S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 305 786 M 0 62 atan DU cos 8.000 MU 367 exch SU exch sin 8.000 MU 786 exch SU L TGSM 1 W S GR GS TGSM NP 367 786 8.000 3.000 62 0 TGAT 1 SG CP F 0 SG NP 367 786 8.000 3.000 62 0 TGAT CP F GR % OVAL 0 SG GS NP 389 785 17 17 TGEL CP EC NP pat26 8 368 760 40 48 TGPF GR GS GS NP 389 785 17 17 TGEL S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 408 785 M 448 785 L 25 0 atan DU cos 8.000 MU 448 exch SU exch sin 8.000 MU 810 exch SU L TGSM 1 W S GR GS TGSM NP 448 810 8.000 3.000 0 25 TGAT 1 SG CP F 0 SG NP 448 810 8.000 3.000 0 25 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 413 815 M 487 815 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 423 824 M 475 824 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 438 834 M 456 834 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 306 946 M 0 62 atan DU cos 8.000 MU 368 exch SU exch sin 8.000 MU 946 exch SU L TGSM 1 W S GR GS TGSM NP 368 946 8.000 3.000 62 0 TGAT 1 SG CP F 0 SG NP 368 946 8.000 3.000 62 0 TGAT CP F GR % OVAL 0 SG GS GS NP 388 944 17 17 TGEL S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 405 944 M 445 944 L 25 0 atan DU cos 8.000 MU 445 exch SU exch sin 8.000 MU 969 exch SU L TGSM 1 W S GR GS TGSM NP 445 969 8.000 3.000 0 25 TGAT 1 SG CP F 0 SG NP 445 969 8.000 3.000 0 25 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 410 974 M 484 974 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 420 983 M 472 983 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 384 506 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (0) SH GR GR % TEXT NP 0 SG GS 1 W 490 504 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (1) SH GR GR % TEXT NP 0 SG GS 1 W 592 505 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (4) SH GR GR % TEXT NP 0 SG GS 1 W 380 668 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (2) SH GR GR % TEXT NP 0 SG GS 1 W 488 667 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (3) SH GR GR % TEXT NP 0 SG GS 1 W 384 824 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (0) SH GR GR % TEXT NP 0 SG GS 1 W 386 986 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (1) SH GR GR % TEXT NP 0 SG GS 116 842 TR [0.945 0.000 0.000 1.000 -2 0] CO 116 NE 842 NE TR GR GS 1 W 116 842 TR [0.945 0.000 0.000 1.000 -2 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS ( member_id ) SH GR 0 14 RM GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (\(ip: 192.168.0.3, pid: 125\)) SH GR GR % TEXT NP 0 SG GS 1 W 375 632 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (2x) SH GR GR % TEXT NP 0 SG GS 1 W 481 633 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (1x) SH GR GR % TEXT NP 0 SG GS 1 W 380 948 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (1x) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 195 976 M 29 0 atan DU cos 8.000 MU 195 exch SU exch sin 8.000 MU 1005 exch SU L TGSM 1 W S GR GS TGSM NP 195 1005 8.000 3.000 0 29 TGAT 1 SG CP F 0 SG NP 195 1005 8.000 3.000 0 29 TGAT CP F GR % TEXT NP 0 SG GS 1 W 317 592 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % POLY/OPEN-SPLINE 0 SG GS NP 159 1007 M 233 1007 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 169 1016 M 221 1016 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 184 1026 M 202 1026 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 103 65 M 304 65 L 304 97 L 103 97 L CP S GR GR % TEXT NP 0 SG GS 1 W 124 86 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (number_of_nodes: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (1) SH GR GR % BOX 0 SG GS 10 SM GS NP 103 102 M 304 102 L 304 134 L 103 134 L CP S GR GR % TEXT NP 0 SG GS 1 W 124 123 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (active: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (1) SH GR GR % BOX 0 SG GS 10 SM GS NP 103 138 M 304 138 L 304 170 L 103 170 L CP S GR GR % TEXT NP 0 SG GS 1 W 124 159 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (first) SH GR GR % BOX 0 SG GS 10 SM GS NP 106 209 M 296 209 L 296 241 L 106 241 L CP S GR GR % BOX 0 SG GS 10 SM GS NP 106 254 M 295 254 L 295 286 L 106 286 L CP S GR GR % TEXT NP 0 SG GS 127 262 TR [0.940 0.000 0.000 1.000 -1 0] CO 127 NE 262 NE TR GR GS 1 W 127 262 TR [0.940 0.000 0.000 1.000 -1 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS ( member_status) SH GR GR % TEXT NP 0 SG GS 1 W 107 194 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (sm_info) SH GR GR % BOX 0 SG GS 10 SM GS NP 103 175 M 304 175 L 304 296 L 103 296 L CP 2 W S GR GR % BOX 0 SG GS 10 SM GS NP 103 300 M 304 300 L 304 332 L 103 332 L CP S GR GR % TEXT NP 0 SG GS 1 W 124 321 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (nak_list) SH GR GR % BOX 0 SG GS 10 SM GS NP 96 58 M 312 58 L 312 339 L 96 339 L CP 3 W S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 303 154 M 0 62 atan DU cos 8.000 MU 365 exch SU exch sin 8.000 MU 154 exch SU L TGSM 1 W S GR GS TGSM NP 365 154 8.000 3.000 62 0 TGAT 1 SG CP F 0 SG NP 365 154 8.000 3.000 62 0 TGAT CP F GR % OVAL 0 SG GS NP 387 153 17 17 TGEL CP EC NP pat26 8 368 128 40 48 TGPF GR GS GS NP 387 153 17 17 TGEL S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 406 153 M 446 153 L 25 0 atan DU cos 8.000 MU 446 exch SU exch sin 8.000 MU 178 exch SU L TGSM 1 W S GR GS TGSM NP 446 178 8.000 3.000 0 25 TGAT 1 SG CP F 0 SG NP 446 178 8.000 3.000 0 25 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 411 183 M 485 183 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 421 192 M 473 192 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 436 202 M 454 202 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 382 192 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (0) SH GR GR % TEXT NP 0 SG GS 114 210 TR [0.945 0.000 0.000 1.000 -2 0] CO 114 NE 210 NE TR GR GS 1 W 114 210 TR [0.945 0.000 0.000 1.000 -2 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS ( member_id ) SH GR 0 14 RM GS 0 SG /Courier FF [12 0 0 -12 0 0] MS (\(ip: 192.168.0.1, pid: 225\)) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 195 340 M 29 0 atan DU cos 8.000 MU 195 exch SU exch sin 8.000 MU 369 exch SU L TGSM 1 W S GR GS TGSM NP 195 369 8.000 3.000 0 29 TGAT 1 SG CP F 0 SG NP 195 369 8.000 3.000 0 29 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 305 315 M 404 315 L 25 0 atan DU cos 8.000 MU 404 exch SU exch sin 8.000 MU 340 exch SU L TGSM 1 W S GR GS TGSM NP 404 340 8.000 3.000 0 25 TGAT 1 SG CP F 0 SG NP 404 340 8.000 3.000 0 25 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 369 345 M 443 345 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 379 354 M 431 354 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 394 364 M 412 364 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 592 849 M GS 0 SG /Courier-BoldOblique FF [12 0 0 -12 0 0] MS (Legend:) SH GR GR % OVAL 0 SG GS NP 610 878 17 17 TGEL CP EC NP pat26 8 584 856 48 48 TGPF GR GS GS NP 610 878 17 17 TGEL S GR GR % OVAL 0 SG GS NP 610 924 17 17 TGEL CP EC NP pat12 8 584 904 48 40 TGPF GR GS GS NP 610 924 17 17 TGEL S GR GR % OVAL 0 SG GS GS NP 610 971 17 17 TGEL S GR GR % TEXT NP 0 SG GS 1 W 642 881 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Packet received in sequence.) SH GR GR % TEXT NP 0 SG GS 1 W 644 923 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Packet received out of order) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (\(gap detected\).) SH GR GR % TEXT NP 0 SG GS 1 W 643 975 M GS 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (n) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS ( NACKs for this packet ) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (have just been sent.) SH GR GR % TEXT NP 0 SG GS 1 W 601 975 M GS 0 SG /Courier-BoldOblique FF [14 0 0 -14 0 0] MS (nx) SH GR GR % BOX 0 SG GS 10 SM GS NP 575 822 M 941 822 L 941 1019 L 575 1019 L CP 2 W S GR GR % BOX 0 SG GS 10 SM GS NP 701 535 M 943 535 L 943 760 L 701 760 L CP 2 W [2 2] 0 SD S GR GR % BOX 0 SG GS 10 SM GS NP 725 572 M 914 572 L 914 749 L 725 749 L CP S GR GR % TEXT NP 0 SG GS 765 540 TR [0.940 0.000 0.000 1.000 -1 0] CO 765 NE 540 NE TR GR GS 1 W 765 540 TR [0.940 0.000 0.000 1.000 -1 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (member_status) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 724 648 M 914 648 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 726 621 M 914 621 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 724 674 M 914 674 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 725 700 M 915 700 L TGSM 1 W S GR % TEXT NP 0 SG GS 743 576 TR [0.940 0.000 0.000 1.000 -1 0] CO 743 NE 576 NE TR GR GS 1 W 743 576 TR [0.940 0.000 0.000 1.000 -1 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (first_rcv: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (0) SH GR GR % TEXT NP 0 SG GS 743 602 TR [0.940 0.000 0.000 1.000 -1 0] CO 743 NE 602 NE TR GR GS 1 W 743 602 TR [0.940 0.000 0.000 1.000 -1 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (last_rcv: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (4 ) SH GR GR % TEXT NP 0 SG GS 743 626 TR [0.940 0.000 0.000 1.000 -1 0] CO 743 NE 626 NE TR GR GS 1 W 743 626 TR [0.940 0.000 0.000 1.000 -1 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (last_seq_rcv: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (1) SH GR GR % TEXT NP 0 SG GS 743 653 TR [0.940 0.000 0.000 1.000 -1 0] CO 743 NE 653 NE TR GR GS 1 W 743 653 TR [0.940 0.000 0.000 1.000 -1 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (last_identified: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (4) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 724 726 M 914 726 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 726 598 M 914 598 L TGSM 1 W S GR % TEXT NP 0 SG GS 743 678 TR [0.940 0.000 0.000 1.000 -1 0] CO 743 NE 678 NE TR GR GS 1 W 743 678 TR [0.940 0.000 0.000 1.000 -1 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (window_size: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (5) SH GR GR % TEXT NP 0 SG GS 743 704 TR [0.940 0.000 0.000 1.000 -1 0] CO 743 NE 704 NE TR GR GS 1 W 743 704 TR [0.940 0.000 0.000 1.000 -1 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (window_mask: ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (00110) SH GR GR % TEXT NP 0 SG GS 743 729 TR [0.940 0.000 0.000 1.000 -1 0] CO 743 NE 729 NE TR GR GS 1 W 743 729 TR [0.940 0.000 0.000 1.000 -1 0] CO 0 13 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (window_ini:) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS ( 2) SH GR GR % POLY/OPEN-SPLINE 0 SG GS [4 4] 0 SD NP 296 602 M 600 602 L 700 758 L TGSM 2 W S [] 0 SD 1 W GR % POLY/OPEN-SPLINE 0 SG GS [4 4] 0 SD NP 295 570 M 602 570 L 702 535 L TGSM 2 W S [] 0 SD 1 W GR % POLY/OPEN-SPLINE 0 SG GS NP 438 992 M 456 992 L TGSM 1 W S GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Tue May 14 17:12:03 2002 %%DocumentFonts: Courier-BoldOblique %%+ Courier-Oblique %%+ Courier %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/actions_on_receiving_packets.obj0000644000076400007640000006470011077130422024707 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,0,384,1,16,0,9,1,1,2,2,1,0,1,0,'Courier-Bold',1,103680,0,0,0,10,0,0,1,1,0,16,0,0,1,2,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/actions_on_receiving_packets.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 50971, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 40569, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). page(1,"",1,''). text('black',217,75,1,1,1,44,20,0,15,5,0,0,0,0,2,44,20,0,0,"",0,0,0,0,90,'',[ minilines(44,20,0,0,1,0,0,[ mini_line(44,15,5,0,0,0,[ str_block(0,44,15,5,0,0,0,0,0,[ str_seg('black','Courier-Bold',1,115200,44,15,5,0,0,0,0,0,0,0, "NACK")]) ]) ])]). text('black',411,42,5,1,1,154,95,12,15,4,0,0,0,0,2,154,95,0,0,"",0,0,0,0,57,'',[ minilines(154,95,0,0,1,0,0,[ mini_line(66,15,4,0,0,0,[ str_block(0,66,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,66,15,4,0,-2,0,0,0,0,0, "Are we")]) ]), mini_line(77,15,4,0,0,0,[ str_block(0,77,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,77,15,4,0,-1,0,0,0,0,0, "waiting")]) ]), mini_line(99,15,4,0,0,0,[ str_block(0,99,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,99,15,4,0,-1,0,0,0,0,0, "to send a")]) ]), mini_line(154,15,4,0,0,0,[ str_block(0,154,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,154,15,4,0,-2,0,0,0,0,0, "NACK for these")]) ]), mini_line(77,15,4,0,0,0,[ str_block(0,77,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,77,15,4,0,-2,0,0,0,0,0, " pckts?")]) ]) ])]). group([ polygon('black','',5,[ 411,20,313,96,411,173,509,96,411,20],0,1,1,0,14,0,0,0,0,0,'1',0, "00",[ ]), box('black','',318,26,504,167,0,1,0,15,0,0,0,0,0,'1',0,[ attr("", "auto_center_attr", 0, 1, 0, text('black',411,24,1,1,1,144,16,16,13,3,0,0,0,0,2,144,16,0,0,"",0,0,0,0,37,'',[ minilines(144,16,0,0,1,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('black',411,88,1,1,1,0,16,17,13,3,0,0,0,0,2,0,16,0,0,"",0,0,0,0,101,'',[ minilines(0,16,0,0,1,0,0,[ mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])])) ]) ], 18,0,0,[ ]). box('black','',544,53,782,140,0,1,1,24,0,0,0,0,0,'1',0,[ ]). text('black',556,61,4,0,1,220,76,33,15,4,0,0,0,0,2,220,76,0,0,"",0,0,0,0,76,'',[ minilines(220,76,0,0,0,0,0,[ mini_line(198,15,4,0,0,0,[ str_block(0,198,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,198,15,4,0,-1,0,0,0,0,0, "Cancel the sending")]) ]), mini_line(220,15,4,0,0,0,[ str_block(0,220,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,220,15,4,0,-1,0,0,0,0,0, "of the NACK and wait")]) ]), mini_line(143,15,4,0,0,0,[ str_block(0,143,15,4,0,-10,0,0,0,[ str_seg('black','Courier',0,103680,143,15,4,0,-10,0,0,0,0,0, "to receive a ")]) ]), mini_line(165,15,4,0,0,0,[ str_block(0,165,15,4,0,-5,0,0,0,[ str_seg('black','Courier',0,103680,165,15,4,0,-5,0,0,0,0,0, "retransmission.")]) ]) ])]). poly('black','',2,[ 509,96,543,96],1,1,1,41,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 411,175,411,212],1,1,1,47,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',411,244,4,1,1,154,76,56,15,4,0,0,0,0,2,154,76,0,0,"",0,0,0,0,259,'',[ minilines(154,76,0,0,1,0,0,[ mini_line(110,15,4,0,0,0,[ str_block(0,110,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,110,15,4,0,-1,0,0,0,0,0, "Is there a")]) ]), mini_line(99,15,4,0,0,0,[ str_block(0,99,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,99,15,4,0,-1,0,0,0,0,0, "scheduled")]) ]), mini_line(154,15,4,0,0,0,[ str_block(0,154,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,154,15,4,0,-1,0,0,0,0,0, "retransmission")]) ]), mini_line(11,15,4,0,0,0,[ str_block(0,11,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,11,15,4,0,-2,0,0,0,0,0, "?")]) ]) ])]). group([ polygon('black','',5,[ 411,210,311,281,411,353,511,281,411,210],0,1,1,0,61,0,0,0,0,0,'1',0, "00",[ ]), box('black','',316,215,506,348,0,1,0,58,0,0,0,0,0,'1',0,[ attr("", "auto_center_attr", 0, 1, 0, text('black',411,214,1,1,1,144,16,60,13,3,0,0,0,0,2,144,16,0,0,"",0,0,0,0,227,'',[ minilines(144,16,0,0,1,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('black',411,273,1,1,1,0,16,59,13,3,0,0,0,0,2,0,16,0,0,"",0,0,0,0,286,'',[ minilines(0,16,0,0,1,0,0,[ mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])])) ]) ], 57,0,0,[ ]). text('black',410,414,4,1,1,99,76,77,15,4,0,0,0,0,2,99,76,0,0,"",0,0,0,0,429,'',[ minilines(99,76,0,0,1,0,0,[ mini_line(55,15,4,0,0,0,[ str_block(0,55,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,55,15,4,0,-2,0,0,0,0,0, "Do we")]) ]), mini_line(88,15,4,0,0,0,[ str_block(0,88,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,88,15,4,0,-2,0,0,0,0,0, "have the")]) ]), mini_line(99,15,4,0,0,0,[ str_block(0,99,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,99,15,4,0,-1,0,0,0,0,0, "requested")]) ]), mini_line(88,15,4,0,0,0,[ str_block(0,88,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,88,15,4,0,-2,0,0,0,0,0, "packets?")]) ]) ])]). group([ polygon('black','',5,[ 410,389,323,458,410,527,497,458,410,389],0,1,1,0,82,0,0,0,0,0,'1',0, "00",[ ]), box('black','',327,394,493,522,0,1,0,79,0,0,0,0,0,'1',0,[ attr("", "auto_center_attr", 0, 1, 0, text('black',410,393,1,1,1,144,16,81,13,3,0,0,0,0,2,144,16,0,0,"",0,0,0,0,406,'',[ minilines(144,16,0,0,1,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('black',410,450,1,1,1,0,16,80,13,3,0,0,0,0,2,0,16,0,0,"",0,0,0,0,463,'',[ minilines(0,16,0,0,1,0,0,[ mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])])) ]) ], 78,0,0,[ ]). poly('black','',2,[ 410,353,410,390],1,1,1,84,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). box('black','',530,413,730,502,0,1,1,93,0,0,0,0,0,'1',0,[ ]). text('black',539,421,4,0,1,176,76,94,15,4,0,0,0,0,2,176,76,0,0,"",0,0,0,0,436,'',[ minilines(176,76,0,0,0,0,0,[ mini_line(132,15,4,0,0,0,[ str_block(0,132,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,132,15,4,0,-2,0,0,0,0,0, "Schedule the")]) ]), mini_line(154,15,4,0,0,0,[ str_block(0,154,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,154,15,4,0,-1,0,0,0,0,0, "retransmission")]) ]), mini_line(176,15,4,0,0,0,[ str_block(0,176,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,176,15,4,0,-1,0,0,0,0,0, "of the requested")]) ]), mini_line(88,15,4,0,0,0,[ str_block(0,88,15,4,0,-5,0,0,0,[ str_seg('black','Courier',0,103680,88,15,4,0,-5,0,0,0,0,0, "packets.")]) ]) ])]). poly('black','',2,[ 495,458,529,458],1,1,1,97,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 9,623,194,623],1,3,1,123,2,0,0,0,0,0,0,'3',0,0, "","",[ 0,12,5,0,'12','5','0'],[0,12,5,0,'12','5','0'],[ ]). text('black',8,599,1,0,1,154,20,124,15,5,0,0,0,0,2,154,20,0,0,"",0,0,0,0,614,'',[ minilines(154,20,0,0,0,0,0,[ mini_line(154,15,5,0,0,0,[ str_block(0,154,15,5,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,115200,154,15,5,0,-1,0,0,0,0,0, "retransmission")]) ]) ])]). box('black','',202,577,445,660,0,1,1,125,0,0,0,0,0,'1',0,[ ]). text('black',211,592,3,0,1,220,57,126,15,4,0,0,0,0,2,220,57,0,0,"",0,0,0,0,607,'',[ minilines(220,57,0,0,0,0,0,[ mini_line(198,15,4,0,0,0,[ str_block(0,198,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,198,15,4,0,-1,0,0,0,0,0, "Cancel a scheduled")]) ]), mini_line(198,15,4,0,0,0,[ str_block(0,198,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,198,15,4,0,-2,0,0,0,0,0, "retransmission for")]) ]), mini_line(220,15,4,0,0,0,[ str_block(0,220,15,4,0,-5,0,0,0,[ str_seg('black','Courier',0,103680,220,15,4,0,-5,0,0,0,0,0, "that packet, if any.")]) ]) ])]). poly('black','',2,[ 323,663,323,700],1,1,1,157,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 321,976,321,1013],1,1,1,166,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',81,1032,1,0,1,55,20,170,15,5,0,0,0,0,2,55,20,0,0,"",0,0,0,0,1047,'',[ minilines(55,20,0,0,0,0,0,[ mini_line(55,15,5,0,0,0,[ str_block(0,55,15,5,0,-10,0,0,0,[ str_seg('black','Courier-Bold',1,115200,55,15,5,0,-10,0,0,0,0,0, "data ")]) ]) ])]). box('black','',206,1014,474,1105,0,1,1,183,0,0,0,0,0,'1',0,[ ]). text('black',216,1023,4,0,1,242,76,184,15,4,0,0,0,0,2,242,76,0,0,"",0,0,0,0,1038,'',[ minilines(242,76,0,0,0,0,0,[ mini_line(198,15,4,0,0,0,[ str_block(0,198,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,198,15,4,0,-1,0,0,0,0,0, "Insert the data in")]) ]), mini_line(154,15,4,0,0,0,[ str_block(0,154,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,154,15,4,0,-1,0,0,0,0,0, "the cache, and")]) ]), mini_line(187,15,4,0,0,0,[ str_block(0,187,15,4,0,-10,0,0,0,[ str_seg('black','Courier',0,103680,187,15,4,0,-10,0,0,0,0,0, "cancel any event ")]) ]), mini_line(242,15,4,0,0,0,[ str_block(0,242,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,242,15,4,0,-1,0,0,0,0,0, "related to this packet")]) ]) ])]). poly('black','',2,[ 321,1105,321,1142],1,1,1,205,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). box('black','',434,1159,630,1242,0,1,1,209,0,0,0,0,0,'1',0,[ ]). text('black',462,1179,2,0,1,143,38,210,15,4,0,0,0,0,2,143,38,0,0,"",0,0,0,0,1194,'',[ minilines(143,38,0,0,0,0,0,[ mini_line(143,15,4,0,0,0,[ str_block(0,143,15,4,0,-10,0,0,0,[ str_seg('black','Courier',0,103680,143,15,4,0,-10,0,0,0,0,0, "Send data to ")]) ]), mini_line(132,15,4,0,0,0,[ str_block(0,132,15,4,0,-5,0,0,0,[ str_seg('black','Courier',0,103680,132,15,4,0,-5,0,0,0,0,0, "application.")]) ]) ])]). poly('black','',2,[ 399,1199,433,1199],1,1,1,212,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 321,1255,321,1292],1,1,1,215,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',518,70,1,0,1,11,20,314,15,5,0,0,0,0,2,11,20,0,0,"",0,0,0,0,85,'',[ minilines(11,20,0,0,0,0,0,[ mini_line(11,15,5,0,0,0,[ str_block(0,11,15,5,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,103680,11,15,5,0,-1,0,0,0,0,0, "Y")]) ]) ])]). text('black',422,176,1,0,1,11,20,317,15,5,0,0,0,0,2,11,20,0,0,"",0,0,0,0,191,'',[ minilines(11,20,0,0,0,0,0,[ mini_line(11,15,5,0,0,0,[ str_block(0,11,15,5,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,103680,11,15,5,0,-1,0,0,0,0,0, "N")]) ]) ])]). box('black','',203,701,467,825,0,1,1,337,0,0,0,0,0,'1',0,[ ]). text('black',211,708,6,0,1,253,114,338,15,4,0,0,0,0,2,253,114,0,0,"",0,0,0,0,723,'',[ minilines(253,114,0,0,0,0,0,[ mini_line(198,15,4,0,0,0,[ str_block(0,198,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,198,15,4,0,-1,0,0,0,0,0, "Cancel a scheduled")]) ]), mini_line(209,15,4,0,0,0,[ str_block(0,209,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,209,15,4,0,-1,0,0,0,0,0, "event of sending of")]) ]), mini_line(209,15,4,0,0,0,[ str_block(0,209,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,209,15,4,0,-2,0,0,0,0,0, "NACK or waiting for")]) ]), mini_line(176,15,4,0,0,0,[ str_block(0,176,15,4,0,-10,0,0,0,[ str_seg('black','Courier',0,103680,176,15,4,0,-10,0,0,0,0,0, "retransmission, ")]) ]), mini_line(253,15,4,0,0,0,[ str_block(0,253,15,4,0,-4,0,0,0,[ str_seg('black','Courier',0,103680,253,15,4,0,-4,0,0,0,0,0, "related to this packet,")]) ]), mini_line(77,15,4,0,0,0,[ str_block(0,77,15,4,0,-5,0,0,0,[ str_seg('black','Courier',0,103680,77,15,4,0,-5,0,0,0,0,0, "if any.")]) ]) ])]). poly('black','',2,[ 323,826,323,863],1,1,1,339,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 125,98,308,98],1,3,1,400,2,0,0,0,0,0,0,'3',0,0, "","",[ 0,12,5,0,'12','5','0'],[0,12,5,0,'12','5','0'],[ ]). poly('black','',2,[ 34,1060,193,1060],1,3,1,402,2,0,0,0,0,0,0,'3',0,0, "","",[ 0,12,5,0,'12','5','0'],[0,12,5,0,'12','5','0'],[ ]). group([ text('black',324,888,3,1,1,99,57,151,15,4,0,0,0,0,2,99,57,0,0,"",0,0,0,0,903,'',[ minilines(99,57,0,0,1,0,0,[ mini_line(55,15,4,0,0,0,[ str_block(0,55,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,55,15,4,0,-2,0,0,0,0,0, "Do we")]) ]), mini_line(99,15,4,0,0,0,[ str_block(0,99,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,99,15,4,0,-2,0,0,0,0,0, "have this")]) ]), mini_line(77,15,4,0,0,0,[ str_block(0,77,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,77,15,4,0,-2,0,0,0,0,0, "packet?")]) ]) ])]), group([ polygon('black','',5,[ 322,863,242,919,322,975,402,919,322,863],0,1,1,0,278,0,0,0,0,0,'1',0, "00",[ ]), box('black','',246,867,398,971,0,1,0,275,0,0,0,0,0,'1',0,[ attr("", "auto_center_attr", 0, 1, 0, text('black',322,866,1,1,1,144,16,277,13,3,0,0,0,0,2,144,16,0,0,"",0,0,0,0,879,'',[ minilines(144,16,0,0,1,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('black',322,910,1,1,1,0,16,276,13,3,0,0,0,0,2,0,16,0,0,"",0,0,0,0,923,'',[ minilines(0,16,0,0,1,0,0,[ mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])])) ]) ], 274,0,0,[ ]) ], 686,0,0,[ ]). text('black',505,432,1,0,1,11,20,696,15,5,0,0,0,0,2,11,20,0,0,"",0,0,0,0,447,'',[ minilines(11,20,0,0,0,0,0,[ mini_line(11,15,5,0,0,0,[ str_block(0,11,15,5,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,103680,11,15,5,0,-1,0,0,0,0,0, "Y")]) ]) ])]). text('black',417,358,1,0,1,11,20,698,15,5,0,0,0,0,2,11,20,0,0,"",0,0,0,0,373,'',[ minilines(11,20,0,0,0,0,0,[ mini_line(11,15,5,0,0,0,[ str_block(0,11,15,5,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,103680,11,15,5,0,-1,0,0,0,0,0, "N")]) ]) ])]). text('black',329,979,1,0,1,11,20,700,15,5,0,0,0,0,2,11,20,0,0,"",0,0,0,0,994,'',[ minilines(11,20,0,0,0,0,0,[ mini_line(11,15,5,0,0,0,[ str_block(0,11,15,5,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,103680,11,15,5,0,-1,0,0,0,0,0, "N")]) ]) ])]). group([ text('black',323,1166,3,1,1,99,57,199,15,4,0,0,0,0,2,99,57,0,0,"",0,0,0,0,1181,'',[ minilines(99,57,0,0,1,0,0,[ mini_line(66,15,4,0,0,0,[ str_block(0,66,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,66,15,4,0,-2,0,0,0,0,0, "Is the")]) ]), mini_line(66,15,4,0,0,0,[ str_block(0,66,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,66,15,4,0,-1,0,0,0,0,0, "packet")]) ]), mini_line(99,15,4,0,0,0,[ str_block(0,99,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,99,15,4,0,-2,0,0,0,0,0, "in order?")]) ]) ])]), group([ polygon('black','',5,[ 321,1143,241,1199,321,1255,401,1199,321,1143],0,1,1,0,204,0,0,0,0,0,'1',0, "00",[ ]), box('black','',245,1147,397,1251,0,1,0,201,0,0,0,0,0,'1',0,[ attr("", "auto_center_attr", 0, 1, 0, text('black',321,1146,1,1,1,144,16,203,13,3,0,0,0,0,2,144,16,0,0,"",0,0,0,0,1159,'',[ minilines(144,16,0,0,1,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('black',321,1190,1,1,1,0,16,202,13,3,0,0,0,0,2,0,16,0,0,"",0,0,0,0,1203,'',[ minilines(0,16,0,0,1,0,0,[ mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])])) ]) ], 200,0,0,[ ]) ], 708,0,0,[ ]). group([ box('black','',216,1293,458,1378,0,1,1,218,0,0,0,0,0,'1',0,[ ]), text('black',229,1299,4,0,1,220,76,219,15,4,0,0,0,0,2,220,76,0,0,"",0,0,0,0,1314,'',[ minilines(220,76,0,0,0,0,0,[ mini_line(209,15,4,0,0,0,[ str_block(0,209,15,4,0,-5,0,0,0,[ str_seg('black','Courier',0,103680,209,15,4,0,-5,0,0,0,0,0, "A gap was detected.")]) ]), mini_line(220,15,4,0,0,0,[ str_block(0,220,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,220,15,4,0,-1,0,0,0,0,0, "Schedule the sending")]) ]), mini_line(176,15,4,0,0,0,[ str_block(0,176,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,176,15,4,0,-2,0,0,0,0,0, "of NACKs for the")]) ]), mini_line(132,15,4,0,0,0,[ str_block(0,132,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,132,15,4,0,-2,0,0,0,0,0, "lost packets")]) ]) ])]) ], 712,0,0,[ ]). text('black',328,1257,1,0,1,11,20,716,15,5,0,0,0,0,2,11,20,0,0,"",0,0,0,0,1272,'',[ minilines(11,20,0,0,0,0,0,[ mini_line(11,15,5,0,0,0,[ str_block(0,11,15,5,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,103680,11,15,5,0,-1,0,0,0,0,0, "N")]) ]) ])]). text('black',408,1172,1,0,1,11,20,717,15,5,0,0,0,0,2,11,20,0,0,"",0,0,0,0,1187,'',[ minilines(11,20,0,0,0,0,0,[ mini_line(11,15,5,0,0,0,[ str_block(0,11,15,5,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,103680,11,15,5,0,-1,0,0,0,0,0, "Y")]) ]) ])]). text('black',628,887,1,0,1,132,20,778,15,5,0,0,0,0,2,132,20,0,0,"",0,0,0,0,902,'',[ minilines(132,20,0,0,0,0,0,[ mini_line(132,15,5,0,0,0,[ str_block(0,132,15,5,0,-10,0,0,0,[ str_seg('black','Courier-Bold',1,115200,132,15,5,0,-10,0,0,0,0,0, "leave group ")]) ]) ])]). box('black','',793,867,989,950,0,1,1,779,0,0,0,0,0,'1',0,[ ]). text('black',823,889,2,0,1,154,38,780,15,4,0,0,0,0,2,154,38,0,0,"",0,0,0,0,904,'',[ minilines(154,38,0,0,0,0,0,[ mini_line(154,15,4,0,0,0,[ str_block(0,154,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,154,15,4,0,-2,0,0,0,0,0, "Deactivate the")]) ]), mini_line(77,15,4,0,0,0,[ str_block(0,77,15,4,0,-5,0,0,0,[ str_seg('black','Courier',0,103680,77,15,4,0,-5,0,0,0,0,0, "member.")]) ]) ])]). text('black',627,1040,1,0,1,132,20,781,15,5,0,0,0,0,2,132,20,0,0,"",0,0,0,0,1055,'',[ minilines(132,20,0,0,0,0,0,[ mini_line(132,15,5,0,0,0,[ str_block(0,132,15,5,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,115200,132,15,5,0,-1,0,0,0,0,0, "join request")]) ]) ])]). box('black','',794,1017,990,1100,0,1,1,782,0,0,0,0,0,'1',0,[ ]). text('black',816,1039,2,0,1,165,38,783,15,4,0,0,0,0,2,165,38,0,0,"",0,0,0,0,1054,'',[ minilines(165,38,0,0,0,0,0,[ mini_line(121,15,4,0,0,0,[ str_block(0,121,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,121,15,4,0,-1,0,0,0,0,0, "Send a join")]) ]), mini_line(165,15,4,0,0,0,[ str_block(0,165,15,4,0,-5,0,0,0,[ str_seg('black','Courier',0,103680,165,15,4,0,-5,0,0,0,0,0, "accept message.")]) ]) ])]). poly('black','',2,[ 621,912,780,912],1,3,1,793,2,0,0,0,0,0,0,'3',0,0, "","",[ 0,12,5,0,'12','5','0'],[0,12,5,0,'12','5','0'],[ ]). poly('black','',2,[ 623,1065,782,1065],1,3,1,794,2,0,0,0,0,0,0,'3',0,0, "","",[ 0,12,5,0,'12','5','0'],[0,12,5,0,'12','5','0'],[ ]). text('black',657,595,1,0,1,88,20,864,15,5,0,0,0,0,2,88,20,0,0,"",0,0,0,0,610,'',[ minilines(88,20,0,0,0,0,0,[ mini_line(88,15,5,0,0,0,[ str_block(0,88,15,5,0,-10,0,0,0,[ str_seg('black','Courier-Bold',1,115200,88,15,5,0,-10,0,0,0,0,0, "refresh ")]) ]) ])]). text('black',877,576,5,1,1,110,95,865,15,4,0,0,0,0,2,110,95,0,0,"",0,0,0,0,591,'',[ minilines(110,95,0,0,1,0,0,[ mini_line(55,15,4,0,0,0,[ str_block(0,55,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,55,15,4,0,-2,0,0,0,0,0, "Do we")]) ]), mini_line(88,15,4,0,0,0,[ str_block(0,88,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,88,15,4,0,-2,0,0,0,0,0, "have the")]) ]), mini_line(110,15,4,0,0,0,[ str_block(0,110,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,110,15,4,0,-1,0,0,0,0,0, "advertised")]) ]), mini_line(77,15,4,0,0,0,[ str_block(0,77,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,77,15,4,0,-2,0,0,0,0,0, "packet?")]) ]), mini_line(0,15,4,0,0,0,[ str_block(0,0,15,4,0,0,0,0,0,[ str_seg('black','Courier',0,103680,0,15,4,0,0,0,0,0,0,0, "")]) ]) ])]). group([ polygon('black','',5,[ 875,556,791,619,875,681,960,619,875,556],0,1,1,0,870,0,0,0,0,0,'1',0, "00",[ ]), box('black','',795,560,956,677,0,1,0,867,0,0,0,0,0,'1',0,[ attr("", "auto_center_attr", 0, 1, 0, text('black',875,559,1,1,1,144,16,869,13,3,0,0,0,0,2,144,16,0,0,"",0,0,0,0,572,'',[ minilines(144,16,0,0,1,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('black',875,610,1,1,1,0,16,868,13,3,0,0,0,0,2,0,16,0,0,"",0,0,0,0,623,'',[ minilines(0,16,0,0,1,0,0,[ mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])])) ]) ], 866,0,0,[ ]). poly('black','',2,[ 875,681,875,708],1,1,1,871,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 624,622,783,622],1,3,1,872,2,0,0,0,0,0,0,'3',0,0, "","",[ 0,12,5,0,'12','5','0'],[0,12,5,0,'12','5','0'],[ ]). text('black',884,681,1,0,1,11,20,873,15,5,0,0,0,0,2,11,20,0,0,"",0,0,0,0,696,'',[ minilines(11,20,0,0,0,0,0,[ mini_line(11,15,5,0,0,0,[ str_block(0,11,15,5,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,103680,11,15,5,0,-1,0,0,0,0,0, "N")]) ]) ])]). group([ box('black','',755,708,995,800,0,1,1,876,0,0,0,0,0,'1',0,[ ]), text('black',768,715,4,0,1,220,76,875,15,4,0,0,0,0,2,220,76,0,0,"",0,0,0,0,730,'',[ minilines(220,76,0,0,0,0,0,[ mini_line(209,15,4,0,0,0,[ str_block(0,209,15,4,0,-5,0,0,0,[ str_seg('black','Courier',0,103680,209,15,4,0,-5,0,0,0,0,0, "A gap was detected.")]) ]), mini_line(220,15,4,0,0,0,[ str_block(0,220,15,4,0,-1,0,0,0,[ str_seg('black','Courier',0,103680,220,15,4,0,-1,0,0,0,0,0, "Schedule the sending")]) ]), mini_line(176,15,4,0,0,0,[ str_block(0,176,15,4,0,-2,0,0,0,[ str_seg('black','Courier',0,103680,176,15,4,0,-2,0,0,0,0,0, "of NACKs for the")]) ]), mini_line(143,15,4,0,0,0,[ str_block(0,143,15,4,0,-5,0,0,0,[ str_seg('black','Courier',0,103680,143,15,4,0,-5,0,0,0,0,0, "lost packets.")]) ]) ])]) ], 874,0,0,[ ]). page(2,"",1,''). poly('black','',2,[ 99,341,371,341],1,1,1,241,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',168,315,1,0,1,162,16,242,13,3,0,0,0,0,2,162,16,0,0,"",0,0,0,0,328,'',[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,162,13,3,0,-2,0,0,0,0,0, "leave group packet")]) ]) ])]). box('black','',383,296,579,379,0,1,1,243,0,0,0,0,0,'1',0,[ ]). text('black',418,321,2,0,1,126,32,244,13,3,0,0,0,0,2,126,32,0,0,"",0,0,0,0,334,'',[ minilines(126,32,0,0,0,0,0,[ mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,126,13,3,0,-1,0,0,0,0,0, "Deactivate the")]) ]), mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-4,0,0,0,0,0, "member.")]) ]) ])]). poly('black','',2,[ 100,467,372,467],1,1,1,245,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',169,441,1,0,1,171,16,246,13,3,0,0,0,0,2,171,16,0,0,"",0,0,0,0,454,'',[ minilines(171,16,0,0,0,0,0,[ mini_line(171,13,3,0,0,0,[ str_block(0,171,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,171,13,3,0,-2,0,0,0,0,0, "join request packet")]) ]) ])]). box('black','',384,422,580,505,0,1,1,247,0,0,0,0,0,'1',0,[ ]). text('black',419,447,2,0,1,135,32,248,13,3,0,0,0,0,2,135,32,0,0,"",0,0,0,0,460,'',[ minilines(135,32,0,0,0,0,0,[ mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-1,0,0,0,0,0, "Send a join")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,135,13,3,0,-4,0,0,0,0,0, "accept message.")]) ]) ])]). poly('black','',2,[ 96,66,368,66],1,1,1,251,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',165,40,1,0,1,126,16,252,13,3,0,0,0,0,2,126,16,0,0,"",0,0,0,0,53,'',[ minilines(126,16,0,0,0,0,0,[ mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,126,13,3,0,-2,0,0,0,0,0, "refresh packet")]) ]) ])]). text('black',465,36,5,1,1,90,80,260,13,3,0,0,0,0,2,90,80,0,0,"",0,0,0,0,49,'',[ minilines(90,80,0,0,1,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "Do we")]) ]), mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "have the")]) ]), mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, "advertised")]) ]), mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-3,0,0,0,0,0, "packet?")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])]). group([ polygon('black','',5,[ 463,11,383,67,463,123,543,67,463,11],0,1,1,0,265,0,0,0,0,0,'1',0, "00",[ ]), box('black','',387,15,539,119,0,1,0,262,0,0,0,0,0,'1',0,[ attr("", "auto_center_attr", 0, 1, 0, text('black',463,14,1,1,1,144,16,264,13,3,0,0,0,0,2,144,16,0,0,"",0,0,0,0,27,'',[ minilines(144,16,0,0,1,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('black',463,58,1,1,1,0,16,263,13,3,0,0,0,0,2,0,16,0,0,"",0,0,0,0,71,'',[ minilines(0,16,0,0,1,0,0,[ mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])])) ]) ], 261,0,0,[ ]). box('black','',382,161,578,244,0,1,1,297,0,0,0,0,0,'1',0,[ ]). text('black',395,170,4,0,1,180,64,298,13,3,0,0,0,0,2,180,64,0,0,"",0,0,0,0,183,'',[ minilines(180,64,0,0,0,0,0,[ mini_line(171,13,3,0,0,0,[ str_block(0,171,13,3,0,-5,0,0,0,[ str_seg('black','Courier',0,80640,171,13,3,0,-5,0,0,0,0,0, "A gap was detected!")]) ]), mini_line(180,13,3,0,0,0,[ str_block(0,180,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,180,13,3,0,-1,0,0,0,0,0, "Schedule the sending")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,135,13,3,0,-1,0,0,0,0,0, "of NACKs to the")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,162,13,3,0,-4,0,0,0,0,0, "remaining packets.")]) ]) ])]). poly('black','',2,[ 463,128,463,155],1,1,1,299,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). tgif-QPL-4.2.5/rmcast/doc/manual/mainloop.obj0000644000076400007640000001243111077130422020616 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,128,0,0,16,0,9,1,1,0,0,0,0,1,0,'NewCenturySchlbk-Roman',0,103680,0,0,0,10,0,0,1,1,0,16,0,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/mainloop.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 53052, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 42649, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). page(1,"",1,''). group([ text('black',221,116,1,0,1,122,17,0,14,3,0,0,0,0,2,122,17,0,0,"",0,0,0,0,130,'',[ minilines(122,17,0,0,0,0,0,[ mini_line(122,14,3,0,0,0,[ str_block(0,122,14,3,0,-1,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,122,14,3,0,-1,0,0,0,0,0, "select() system call")]) ]) ])]), box('black','',215,99,360,147,0,1,1,2,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 388,215,388,279],0,1,1,8,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 388,129,388,215],0,1,1,9,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 356,128,561,128],1,1,1,10,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), text('black',391,240,2,0,1,167,34,11,14,3,0,0,0,0,2,167,34,0,0,"",0,0,0,0,254,'',[ minilines(167,34,0,0,0,0,0,[ mini_line(167,14,3,0,0,0,[ str_block(0,167,14,3,0,-1,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,167,14,3,0,-1,0,0,0,0,0, "received a request to pack")]) ]), mini_line(115,14,3,0,0,0,[ str_block(0,115,14,3,0,-2,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,115,14,3,0,-2,0,0,0,0,0, " the current state ")]) ]) ])]), text('black',397,163,2,0,1,146,34,16,14,3,0,0,0,0,2,146,34,0,0,"",0,0,0,0,177,'',[ minilines(146,34,0,0,0,0,0,[ mini_line(137,14,3,0,0,0,[ str_block(0,137,14,3,0,-2,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,137,14,3,0,-2,0,0,0,0,0, "(2) received \250reliable ")]) ]), mini_line(146,14,3,0,0,0,[ str_block(0,146,14,3,0,0,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,146,14,3,0,0,0,0,0,0,0, "message\250 from the net")]) ]) ])]), text('black',397,105,1,0,1,132,17,18,14,3,0,0,0,0,2,132,17,0,0,"",0,0,0,0,119,'',[ minilines(132,17,0,0,0,0,0,[ mini_line(132,14,3,0,0,0,[ str_block(0,132,14,3,0,-1,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,132,14,3,0,-1,0,0,0,0,0, "(1) X event received")]) ]) ])]), poly('black','',2,[ 388,201,557,201],1,1,1,26,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 389,278,558,278],1,1,1,30,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), text('black',586,171,4,0,1,230,68,32,14,3,0,0,0,0,2,230,68,-1,0,"",0,0,0,0,185,'',[ minilines(230,68,-1,0,0,0,0,[ mini_line(230,14,3,0,0,0,[ str_block(0,230,14,3,0,-1,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,230,14,3,0,-1,0,0,0,0,0, "Process the command received and")]) ]), mini_line(192,14,3,0,0,0,[ str_block(0,192,14,3,0,-2,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,192,14,3,0,-2,0,0,0,0,0, "send to self an X event which ")]) ]), mini_line(223,14,3,0,0,0,[ str_block(0,223,14,3,0,0,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,223,14,3,0,0,0,0,0,0,0, "instructs how this command must")]) ]), mini_line(78,14,3,-1,0,0,[ str_block(0,78,14,3,-1,-1,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,78,14,3,-1,-1,0,0,0,0,0, "be executed.")]) ]) ])]), box('black','',577,170,834,242,0,1,1,34,0,0,0,0,0,'1',0,[ ]), text('black',579,119,1,0,1,249,17,35,14,3,0,0,0,0,2,249,17,0,0,"",0,0,0,0,133,'',[ minilines(249,17,0,0,0,0,0,[ mini_line(249,14,3,0,0,0,[ str_block(0,249,14,3,0,-1,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,249,14,3,0,-1,0,0,0,0,0, "XNextEvent(mainDisplay, pXEvent);")]) ]) ])]), box('black','',577,106,834,154,0,1,1,37,0,0,0,0,0,'1',0,[ ]), text('black',584,277,1,0,1,179,17,42,14,3,0,0,0,0,2,179,17,0,0,"",0,0,0,0,291,'',[ minilines(179,17,0,0,0,0,0,[ mini_line(179,14,3,0,0,0,[ str_block(0,179,14,3,0,-1,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,179,14,3,0,-1,0,0,0,0,0, "HandleNewUserRequest();")]) ]) ])]), box('black','',578,260,835,308,0,1,1,45,0,0,0,0,0,'1',0,[ ]), text('black',479,361,1,0,1,350,17,54,14,3,0,0,0,0,2,350,17,0,0,"",0,0,0,0,375,'',[ minilines(350,17,0,0,0,0,0,[ mini_line(350,14,3,0,0,0,[ str_block(0,350,14,3,0,-1,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,80640,350,14,3,0,-1,0,0,0,0,0, "Note that after (2) we will always get (1) in the future.")]) ]) ])]), box('black','',205,53,845,387,0,1,1,56,0,0,0,0,0,'1',0,[ ]), text('black',395,62,1,0,1,235,22,57,18,4,0,0,0,0,2,235,22,0,0,"",0,0,0,0,80,'',[ minilines(235,22,0,0,0,0,0,[ mini_line(235,18,4,0,0,0,[ str_block(0,235,18,4,0,-1,0,0,0,[ str_seg('black','NewCenturySchlbk-Roman',0,103680,235,18,4,0,-1,0,0,0,0,0, "Main loop of the whiteboard")]) ]) ])]) ], 150,0,0,[ ]). tgif-QPL-4.2.5/rmcast/doc/manual/eventlist.obj0000644000076400007640000002701511077130422021021 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,0,0,0,16,0,9,1,1,2,0,1,0,1,0,'Courier-Bold',1,138240,0,0,0,10,0,0,1,1,0,16,0,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/eventlist.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 50971, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 40569, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). page(1,"",1,''). box('black','',148,246,323,353,0,1,1,44,0,0,0,0,0,'1',0,[ ]). poly('black','',2,[ 149,274,234,274],0,1,1,48,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 149,274,149,274,234,274,2058.82,0,0,1000,0,0],[ ]). poly('black','',2,[ 147,301,232,301],0,1,1,50,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 147,301,147,301,232,301,2058.82,0,0,1000,0,0],[ ]). poly('black','',2,[ 148,329,233,329],0,1,1,51,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 148,329,148,329,233,329,2058.82,0,0,1000,0,0],[ ]). text('black',235,253,1,1,1,81,16,58,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,266,'',[ minilines(81,16,0,0,1,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "member_id")]) ]) ])]). text('black',235,279,1,1,1,171,16,62,13,3,0,0,0,0,2,171,16,0,1,"",0,0,0,0,292,'',[ minilines(171,16,0,1,1,0,0,[ mini_line(171,13,3,0,1,0,[ str_block(0,63,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-8,0,0,0,0,0, "action ")]), str_block(0,108,13,3,0,1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,108,13,3,0,1,0,0,0,0,0, "NAK_SND_WAIT")]) ]) ])]). text('black',235,306,1,1,1,117,16,64,13,3,0,0,0,0,2,117,16,0,0,"",0,0,0,0,319,'',[ minilines(117,16,0,0,1,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,108,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-8,0,0,0,0,0, "timer_value ")]), str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-2,0,0,0,0,0, "4")]) ]) ])]). text('black',235,333,1,1,1,117,16,66,13,3,0,0,0,0,2,117,16,0,0,"",0,0,0,0,346,'',[ minilines(117,16,0,0,1,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,36,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,36,13,3,0,-3,0,0,0,0,0, "sn (")]), str_block(0,81,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,81,13,3,0,-3,0,0,0,0,0, "not used)")]) ]) ])]). box('black','',363,245,538,352,0,1,1,82,0,0,0,0,0,'1',0,[ ]). poly('black','',2,[ 364,273,449,273],0,1,1,83,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 364,273,364,273,449,273,2058.82,0,0,1000,0,0],[ ]). poly('black','',2,[ 362,300,447,300],0,1,1,84,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 362,300,362,300,447,300,2058.82,0,0,1000,0,0],[ ]). poly('black','',2,[ 363,328,448,328],0,1,1,85,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 363,328,363,328,448,328,2058.82,0,0,1000,0,0],[ ]). text('black',450,252,1,1,1,162,16,86,13,3,0,0,0,0,2,162,16,0,0,"",0,0,0,0,265,'',[ minilines(162,16,0,0,1,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,90,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-8,0,0,0,0,0, "member_id ")]), str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,72,13,3,0,-1,0,0,0,0,0, "not used")]) ]) ])]). text('black',450,278,1,1,1,171,16,87,13,3,0,0,0,0,2,171,16,0,1,"",0,0,0,0,291,'',[ minilines(171,16,0,1,1,0,0,[ mini_line(171,13,3,0,1,0,[ str_block(0,63,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-8,0,0,0,0,0, "action ")]), str_block(0,108,13,3,0,1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,108,13,3,0,1,0,0,0,0,0, "REF_SND_WAIT")]) ]) ])]). text('black',450,305,1,1,1,117,16,88,13,3,0,0,0,0,2,117,16,0,0,"",0,0,0,0,318,'',[ minilines(117,16,0,0,1,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,108,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-8,0,0,0,0,0, "timer_value ")]), str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-1,0,0,0,0,0, "6")]) ]) ])]). text('black',450,332,1,1,1,117,16,89,13,3,0,0,0,0,2,117,16,0,0,"",0,0,0,0,345,'',[ minilines(117,16,0,0,1,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,36,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,36,13,3,0,-3,0,0,0,0,0, "sn (")]), str_block(0,81,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,81,13,3,0,-3,0,0,0,0,0, "not used)")]) ]) ])]). box('black','',581,244,756,351,0,1,1,90,0,0,0,0,0,'1',0,[ ]). poly('black','',2,[ 582,272,667,272],0,1,1,91,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 582,272,582,272,667,272,2058.82,0,0,1000,0,0],[ ]). poly('black','',2,[ 580,299,665,299],0,1,1,92,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 580,299,580,299,665,299,2058.82,0,0,1000,0,0],[ ]). poly('black','',2,[ 581,327,666,327],0,1,1,93,0,0,0,0,0,1,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ 581,327,581,327,666,327,2058.82,0,0,1000,0,0],[ ]). text('black',668,251,1,1,1,81,16,94,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,264,'',[ minilines(81,16,0,0,1,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "member_id")]) ]) ])]). text('black',668,277,1,1,1,171,16,95,13,3,0,0,0,0,2,171,16,0,1,"",0,0,0,0,290,'',[ minilines(171,16,0,1,1,0,0,[ mini_line(171,13,3,0,1,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "action")]), str_block(0,117,13,3,0,1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,117,13,3,0,1,0,0,0,0,0, " RET_SND_WAIT")]) ]) ])]). text('black',668,304,1,1,1,117,16,96,13,3,0,0,0,0,2,117,16,0,0,"",0,0,0,0,317,'',[ minilines(117,16,0,0,1,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,108,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-8,0,0,0,0,0, "timer_value ")]), str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-1,0,0,0,0,0, "7")]) ]) ])]). text('black',668,331,1,1,1,36,16,97,13,3,0,0,0,0,2,36,16,0,0,"",0,0,0,0,344,'',[ minilines(36,16,0,0,1,0,0,[ mini_line(36,13,3,0,0,0,[ str_block(0,27,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,27,13,3,0,-8,0,0,0,0,0, "sn ")]), str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-2,0,0,0,0,0, "2")]) ]) ])]). poly('black','',2,[ 328,297,360,297],1,1,1,100,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 546,298,578,298],1,1,1,101,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 763,297,816,297,816,329],0,1,1,105,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 799,346,831,346],0,1,1,106,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 783,330,847,330],0,1,1,107,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). box('black','',152,404,324,451,0,2,1,1773,0,0,0,0,0,'2',0,[ ]). text('black',194,420,1,0,1,81,16,1775,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,433,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,81,13,3,0,-3,0,0,0,0,0, "member M1")]) ]) ])]). box('black','',151,488,323,535,0,2,1,1779,0,0,0,0,0,'2',0,[ ]). text('black',193,504,1,0,1,81,16,1780,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,517,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,81,13,3,0,-2,0,0,0,0,0, "member M2")]) ]) ])]). oval('black','',384,406,424,446,26,1,1,1784,0,0,0,0,0,'1',0,[ ]). oval('black','',472,407,512,447,26,1,1,1787,0,0,0,0,0,'1',0,[ ]). oval('black','',560,408,600,448,12,1,1,1788,0,0,0,0,0,'1',0,[ ]). oval('black','',383,487,423,527,26,1,1,1789,0,0,0,0,0,'1',0,[ ]). oval('black','',475,487,515,527,26,1,1,1790,0,0,0,0,0,'1',0,[ ]). oval('black','',561,485,601,525,26,1,1,1791,0,0,0,0,0,'1',0,[ ]). poly('black','',3,[ 603,427,635,427,635,459],0,1,1,1795,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 619,475,651,475],0,1,1,1796,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 603,459,667,459],0,1,1,1797,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 610,501,642,501,642,533],0,1,1,1801,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 626,549,658,549],0,1,1,1802,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 610,533,674,533],0,1,1,1803,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 335,427,367,427],1,1,1,1805,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 433,427,465,427],1,1,1,1806,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 519,427,551,427],1,1,1,1807,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 521,506,553,506],1,1,1,1808,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 433,507,465,507],1,1,1,1809,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 335,509,367,509],1,1,1,1810,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 241,454,241,483],1,1,1,1830,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). arc('black','',0,1,1,0,98,261,184,347,175,261,175,433,0,172,172,6080,10880,1835,0,1,8,3,0,0,0,'1','8','3',0,[ ]). arc('black','',0,1,1,0,67,157,255,345,92,251,162,509,0,376,376,9600,5824,1858,0,1,8,3,0,0,0,'1','8','3',0,[ ]). arc('black','',0,1,1,0,-480,194,348,1339,82,254,610,251,1,1656,2290,6912,-2368,1862,0,0,8,3,0,0,0,'1','8','3',0,[ ]). rcbox('black','',135,380,700,569,0,1,1,3,16,1864,0,0,0,0,'1',0,[ ]). rcbox('black','',138,231,857,367,0,1,1,3,16,1866,0,0,0,0,'1',0,[ ]). text('black',759,375,1,0,1,90,16,1876,13,3,0,0,0,0,2,90,16,0,0,"",0,0,0,0,388,'',[ minilines(90,16,0,0,0,0,0,[ mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-2,0,0,0,0,0, "event list")]) ]) ])]). text('black',643,573,1,0,1,45,16,1878,13,3,0,0,0,0,2,45,16,0,0,"",0,0,0,0,586,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "cache")]) ]) ])]). text('black',272,139,1,0,1,345,25,1885,20,5,0,0,0,0,2,345,25,0,0,"",0,0,0,0,159,'',[ minilines(345,25,0,0,0,0,0,[ mini_line(345,20,5,0,0,0,[ str_block(0,345,20,5,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,138240,345,20,5,0,-1,1,0,0,0,0, "Event List Organization")]) ]) ])]). box('black','',29,125,903,601,0,3,1,1890,0,0,0,0,0,'3',0,[ ]). tgif-QPL-4.2.5/rmcast/doc/manual/log_plot.eps0000644000076400007640000231133410122646341020644 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: -1 524 350 793 %%Title: log_plot %%CreationDate: Wed May 15 14:32:51 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 59 dict def tgifdict begin /tgifxpmdict 4 dict def /tgifbwpicstr 1 string def /tgifcolorpicstr 3 string def /tgifsetpixels { tgifxpmdict begin /pixels exch def end } def /tgifsetpix { tgifxpmdict begin pixels 3 1 roll putinterval end } def /tgifcolorspot { tgifxpmdict begin /index exch def pixels index 3 mul 3 getinterval aload pop 255 mul cvi tgifcolorpicstr 2 3 -1 roll put 255 mul cvi tgifcolorpicstr 1 3 -1 roll put 255 mul cvi tgifcolorpicstr 0 3 -1 roll put tgifcolorpicstr end } def /tgifnewcolorspot { tgifxpmdict begin /index exch def pixels index 3 mul 3 getinterval aload pop setrgbcolor end } def /tgifcolordict 4 dict def /colorimage where { pop } { /colorimage { tgifcolordict begin pop pop pop pop pop /ih exch def /iw exch def /x 0 def /y 0 def 1 1 ih { pop 1 1 iw { pop currentfile tgifbwpicstr readhexstring pop 0 get tgifnewcolorspot x y moveto 1 0 rlineto 0 1 rlineto -1 0 rlineto closepath fill /x x 1 add def } for /y y 1 add def /x 0 def } for end } def } ifelse /tgiftranscolorspot { tgifxpmdict begin /index exch def pixels index 3 mul 3 getinterval aload pop dup 0 lt { pop pop pop false } { setrgbcolor true } ifelse end } def /tgiftranscolorimage { tgifcolordict begin pop pop pop pop pop /ih exch def /iw exch def /x 0 def /y 0 def 1 1 ih { pop 1 1 iw { pop currentfile tgifbwpicstr readhexstring pop 0 get tgiftranscolorspot { x y moveto 1 0 rlineto 0 1 rlineto -1 0 rlineto closepath fill } if /x x 1 add def } for /y y 1 add def /x 0 def } for end } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: -1 524 350 793 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % XPM GS 0 0 TR 1.000 1.000 SC 0 RO 622 474 8 [1 0 0 1 0 0] {currentfile tgifbwpicstr readhexstring pop} IM ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffff0000000000ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffff000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 00000000ffffffffffff ffffffffffffffffffffffff00ffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffff00ffffff00ffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffff000000ffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffff00ffffffffff000000ffffffff000000 ffffffffffff00ffffffff000000ffffffffffffffffffffffffffffffffff00ffffff00 ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffff00ffffffffff0000ffffffffff0000ffffffff00ffffff00ffff00ffffff 00ffffffff0000ffffff00ffffff00ffffff0000ffffffffffffffffffffff0000ffff00 ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ff0000ffffffff000000ffffffff000000ffffffff000000ffffffff0000ffffffff00ff ffff00ffffff000000ffffff00ff0000ffffff00ff0000ffffffff000000ffffffff0000 0000ffff0000000000ffffff0000ffffffffffff00ffffffff00ffffff00ffffffffffff 00ffffff00ff00ffffff00ffffff00ffffff0000ffffffffffffffffffffff00ff00ff00 ffffff000000ffffff00ffff00ffffffff00000000ffffffffffffffffffff00000000ff ffff000000ffffff00ff0000ffffff0000000000ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 00ffff00ffff00ffffff00ffff00ffffff00ffff00ffffff00ffffffff00ffffffff00ff ffff00ffff00ffffff00ffff0000ffff00ffff0000ffff00ffff00ffffff00ffff00ffff ffffffffffff00ffffffffffffffffffffffffff00ffffffffff000000ffffffffff0000 ffffff00ffff00ffffffff000000ffffffffffffffffffffffffffffffffff00ffff0000 ffffffffffff00ffff00ff00ffffffff00ffffffffffffffffffffffffff00ffffffffff ff00ffffff00ffff0000ffff00ffffffff00ffffffffffffffffffff0000000000000000 0000000000000000000000000000000000000000000000000000ffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffff0000000000ffff00ffffffffffff0000000000ffffffff00ffffffff00ff ffff00ffff0000000000ffff00ffffffffffff00ffffff00ffff00ffffff00ffffff0000 00ffffffffff00ffffffffff0000ffffffffffff00ffffffff00ffffff00ffffffffffff 00ffff0000000000ffff00ffffff00ffffff0000ffffffffffffffffffffff00ffffff00 ffffff00000000ffff0000ffffffffffff000000ffffffffffffffffffffff000000ffff ff0000000000ffff00ffffff00ffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffff00ffffffffffff00ffffff00ffff00ffffffffffffffff00ffffffffff00 ff00ffffff00ffffffffffff00ffffffffffff00ffffff00ffff00ffffff00ffffffffff ff00ffffffff00ff00ffffff0000ffffffffffff00ffffffff00ffffff00ffff00ffffff 00ffffffffff00ffffff00ffffff00ffffff0000ffffffffffffffffffffff00ffffff00 ffff00ffffff00ffff00ff00ffffffffffffffff00ffffffffffffffffffffffffff00ff ff00ffffffffffff00ffffff00ffffffff00ff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffff000000ffffffff000000ffffffff000000ffffffff000000ffffffffff 00ffffffffff000000ffffff00ffffffffffff00ffffff00ffffff000000ffffff000000 00ffffffffffff00ffffffffffffffffffffff000000ffffffff000000ffffffff000000 ffffffffffff00ffffffff000000ffffffffffffffffffffffffffffffffff00ffffff00 ffffff00000000ffff00ffff00ffffff00000000ffffffffffffffffffff00000000ffff ffff000000ffffff00ffffff00ffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffff00ffffffffff000000ffffffff000000ffffffff000000ffffffff000000ffff ffffffffffffffffffffffffffffff00ffffff00ffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffff00ffffffffff000000ffff ffff000000ffffffffffff00ffffffff000000ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffff00ffffffffff0000ffff ffffff0000ffffffff00ffffff00ffff00ffffff00ffff00ffffff00ffff00ffffff00ff ffff0000ffffffffffffffffffffff0000ffff00ffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffff00ffffffffff0000ffffffffff0000ffffffff00ffffff00ff ff00ffffff00ffffffff0000ffffff00ffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000 0000ffffff000000ffffff00ff0000ffffffff0000ff00ffffff000000ffffff00ff0000 ffffff00ff0000ffffffff000000ffffffff00000000ffff0000000000ffffff0000ffff ffffffff00ffffffffffffffff00ffff00ffffff00ffff00ffffff00ffffffffffff00ff ffff0000ffffffffffffffffffffff00ff00ff00ffffff000000ffffff00ffff00ffffff ff00000000ffffffffffffffffff00ff0000ffffffff000000ffffffff000000ffffffff 000000ffffffff0000ffffffff00ffffff00ffffff000000ffffffff0000ff00ffffffff ffffffffffffff00ffffffff00ff0000ffffffff000000ffffff0000ff00ffffffffffff ffffffff00ff0000ffffffff000000ffffffff000000ffffffff000000ffffffff0000ff ffffff00ffffff00ffffff000000ffffff00ff0000ffffff00ff0000ffffffff000000ff ffffff00000000ffff0000000000ffffff0000ffffffffffff00ffffffff00ffffff00ff ffffffffff00ffffff00ff00ffffff00ffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffff00ffffff00ffff0000ffff00ffff00ffff0000ffff00ffffff00ffff0000ffff 00ffff0000ffff00ffff00ffffff00ffff00ffffffffffffffff00ffffffffffffffffff ffffffff00ffffffffffff0000ffffffff000000ffffffff00000000ffffffff0000ffff ffffffffffffffffffffffffffffff00ffff0000ffffffffffff00ffff00ff00ffffffff 00ffffffffffffffffffffffffff0000ffff00ffff00ffffff00ffff00ffffff00ffff00 ffffff00ffffffff00ffffffff00ffffff00ffff00ffffff00ffff00ffff0000ffffffff ffffffffffff000000ffffff0000ffff00ffff00ffffff00ffff00ff00ff00ffffffffff ffffffff0000ffff00ffff00ffffff00ffff00ffffff00ffff00ffffff00ffffffff00ff ffffff00ffffff00ffff00ffffff00ffff0000ffff00ffff0000ffff00ffff00ffffff00 ffff00ffffffffffffffff00ffffffffffffffffffffffffff00ffffffffff000000ffff ffffff0000ffffff00ffff00ffffffff000000ffffffffffffffffff00ff00ff00ff00ff 00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ff00ffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000 00ffffff0000000000ffff00ffffff00ffff00ffffff00ffff0000000000ffff00ffffff ffffff00ffffff00ffff00ffffff00ffffff000000ffffffffff00ffffffffff0000ffff ffffffff00ffffffffffffffff00ffff00ffffff00ffffffffffff00ffffffffffff00ff ffff0000ffffffffffffffffffffff00ffffff00ffffff00000000ffff0000ffffffffff ff000000ffffffffffffffffffff00ffffffffffff0000000000ffff00ffffffffffff00 00000000ffffffff00ffffffff00ffffff00ffff0000000000ffff00ffffff00ffffffff ffffffffffffff00ffffffff00ffffffffffff00ffffff00ffff00ff00ff00ffffffffff ffffffff00ffffffffffff0000000000ffff00ffffffffffff0000000000ffffffff00ff ffffff00ffffff00ffff0000000000ffff00ffffffffffff00ffffff00ffff00ffffff00 ffffff000000ffffffffff00ffffffffff0000ffffffffffff00ffffffff00ffffff00ff ffffffffff00ffff0000000000ffff00ffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffff00ffffffffffff00ffffff00ffff00ffff0000ffff00ffffffffffff00ffffff ffffff00ffffff00ffff00ffffff00ffffffffffff00ffffffff00ff00ffffff0000ffff ffffffff00ffffffff00ffffff00ffff00ffffff00ffffffffff00ffffff00ffffff00ff ffff0000ffffffffffffffffffffff00ffffff00ffff00ffffff00ffff00ff00ffffffff ffffffff00ffffffffffffffffff00ffffffffffff00ffffffffffff00ffffff00ffff00 ffffffffffffffff00ffffffffff00ff00ffffff00ffffffffffff00ffff0000ffffffff ffffffffffffff00ffffffff00ffffffffffff00ffffff00ffff00ff00ff00ffffffffff ffffffff00ffffffffffff00ffffffffffff00ffffff00ffff00ffffffffffffffff00ff ffffffff00ff00ffffff00ffffffffffff00ffffffffffff00ffffff00ffff00ffffff00 ffffffffffff00ffffffff00ff00ffffff0000ffffffffffff00ffffffff00ffffff00ff ff00ffffff00ffffffffff00ffffff00ffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000 00ffffffff000000ffffff00ffffff00ffffff0000ff00ffffff000000ffffff00ffffff ffffff00ffffff00ffffff000000ffffff00000000ffffffffffff00ffffffffffffffff ffffff000000ffffffff000000ffffffff000000ffffffff0000ffffffffff000000ffff ffffffffffffffffffffffffffffff00ffffff00ffffff00000000ffff00ffff00ffffff 00000000ffffffffffffffffffff00ffffffffffffff000000ffffffff000000ffffffff 000000ffffffff000000ffffffffff00ffffffffff000000ffffffff0000ff00ffffffff ffffffffffffff00ffffffff00ffffffffffffff000000ffffff00ff00ff00ffffffffff ffffffff00ffffffffffffff000000ffffffff000000ffffffff000000ffffffff000000 ffffffffff00ffffffffff000000ffffff00ffffffffffff00ffffff00ffffff000000ff ffff00000000ffffffffffff00ffffffffffffffffffffff000000ffffffff000000ffff ffff000000ffffffffffff00ffffffff000000ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffff00ffffffffff000000ffffffff00 0000ffffffff000000ffffffff000000ffffffffffffffffffffffffffffffffff000000 00ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffff00ffffffffff0000ffffffffff0000ffffffff00ffffff00ffff00ff ffff00ffff00ffffff00ffff00ffffff00ffffff0000ffffffffffffffffffffff00ffff ff00ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00000000ffffff000000ffffff00ff0000ffffff ff0000ff00ffffff000000ffffff00ff0000ffffff00ff0000ffffffff000000ffffffff 00000000ffff0000000000ffffff0000ffffffffffff00ffffffffffffffff00ffff00ff ffff00ffff00ffffff00ffffffffffff00ffffff0000ffffffffffffffffffffff00ffff ff00ffffff000000ffffff0000000000ffff00ff0000ffffffff000000ffffff00ff0000 ffffffff00000000ffff0000ff00ffffffff0000ffffffffff00000000ffffff00000000 ffffff0000ffffffffff000000ffffff00ff0000ffffffffffffffffffffff00000000ff ffff000000ffffff00ff0000ffffff0000000000ffffffffffffffffffffffffffffffff ffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffff00ffffff00ffff0000ffff00ffff 00ffff0000ffff00ffffff00ffff0000ffff00ffff0000ffff00ffff00ffffff00ffff00 ffffffffffffffff00ffffffffffffffffffffffffff00ffffffffffff0000ffffffff00 0000ffffffff00000000ffffffff0000ffffffffffffffffffffffffffffffffff000000 00ffffff00ffffff00ffffffff00ffffffff0000ffff00ffffffffffff00ffff0000ffff 00ffff00ffffffffffff00ff00ff00ffffffff00ffffffff00ffffffffffff00ffffffff ffffffff00ffffffff00ffffff00ffff0000ffff00ffffffffffffffffff00ffffffffff ff00ffffff00ffff0000ffff00ffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffff00ff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff000000ffffff0000000000ffff00ffffff00ffff 00ffffff00ffff0000000000ffff00ffffffffffff00ffffff00ffff00ffffff00ffffff 000000ffffffffff00ffffffffff0000ffffffffffff00ffffffffffffffff00ffff00ff ffff00ffffffffffff00ffffffffffff00ffffff0000ffffffffffffffffffffff00ff00 ffffffff0000000000ffffffff00ffffffff00ffffffffffffff00000000ffff00ffffff 00ffffff000000ffffff00ff00ff00ffffffff00ffffffffff000000ffffffff000000ff ffffffff00ffffffff00ffffff00ffff00ffffff00ffffffffffffffffffff000000ffff ff0000000000ffff00ffffff00ffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffff00ffffffffffff00ffffff00ffff 00ffff0000ffff00ffffffffffff00ffffffffffff00ffffff00ffff00ffffff00ffffff ffffff00ffffffff00ff00ffffff0000ffffffffffff00ffffffff00ffffff00ffff00ff ffff00ffffffffff00ffffff00ffffff00ffffff0000ffffffffffffffffffffff00ffff 00ffffff00ffffffffffffffff00ff00ffff00ffffffffffff00ffffff00ffff00ffffff 00ffffffffffff00ffff00ff00ff00ffffffff00ffffffffffffffff00ffffffffffff00 ffffffff00ffffffff00ffffff00ffff00ffffff00ffffffffffffffffffffffffff00ff ff00ffffffffffff00ffffff00ffffffff00ff00ffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00000000ffffffff000000ffffff00ffffff00ffff ff0000ff00ffffff000000ffffff00ffffffffffff00ffffff00ffffff000000ffffff00 000000ffffffffffff00ffffffffffffffffffffff000000ffffffff000000ffffffff00 0000ffffffff0000ffffffffff000000ffffffffffffffffffffffffffffffffff00ffff ff00ffffff000000ffffffffffff00ffffff00ffffffffffffff00000000ffff00ffffff 00ffff00000000ffffff00ff00ff00ffffff000000ffffff00000000ffffff00000000ff ffffff000000ffffffff000000ffffff00ffffff00ffffffffffffffffff00000000ffff ffff000000ffffff00ffffff00ffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffff00ffffffffff000000ffffffff000000 ffffffffffff00ffffffff000000ffffffffffffffffffffffffffffffffff00000000ff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffff00ffffffffff000000ffff ffff000000ffffffff000000ffffffff000000ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffff00ffffffffff0000ffffffffff0000ffffffff00ffffff00ffff00ffffff 00ffffffff0000ffffff00ffffff00ffffff0000ffffffffffffffffffffff00ffffff00 ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffff00ff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffff00ffffffffff0000ffffffffff0000ffffffff00ffffff00ff ff00ffffff00ffff00ffffff00ffff00ffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ff0000ffffffff000000ffffffff000000ffffffff000000ffffffff0000ffffffff00ff ffff00ffffff000000ffffff00ff0000ffffff00ff0000ffffffff000000ffffffff0000 0000ffff0000000000ffffff0000ffffffffffff00ffffffff00ffffff00ffffffffffff 00ffffff00ff00ffffff00ffffff00ffffff0000ffffffffffffffffffffff00ffffff00 ffffff000000ffffff0000000000ffff00ff0000ffffffff000000ffffff00ff0000ffff ffff00000000ffff0000ff00ffffffff0000ffffffffff00000000ffffff00000000ffff ff0000ffffffffff000000ffffff00ff0000ffffffffffffffffffff00ff0000ffffffff 000000ffffffff000000ffffffff000000ffffffff0000ffffffff00ffffff00ffffff00 0000ffffffff0000ff00ffffffffffffffffffffff00ffffffff00ff0000ffffffff0000 00ffffff0000ff00ffffffffffffffffffffff00000000ffffff000000ffffff00ff0000 ffffffff0000ff00ffffff000000ffffff00ff0000ffffff00ff0000ffffffff000000ff ffffff00000000ffff0000000000ffffff0000ffffffffffff00ffffffffffffffff00ff ff00ffffff00ffff00ffffff00ffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 00ffff00ffff00ffffff00ffff00ffffff00ffff00ffffff00ffffffff00ffffffff00ff ffff00ffff00ffffff00ffff0000ffff00ffff0000ffff00ffff00ffffff00ffff00ffff ffffffffffff00ffffffffffffffffffffffffff00ffffffffff000000ffffffffff0000 ffffff00ffff00ffffffff000000ffffffffffffffffffffffffffffffffff00000000ff ffff00ffffff00ffffffff00ffffffff0000ffff00ffffffffffff00ffff0000ffff00ff ff00ffffffffffff00ff00ff00ffffffff00ffffffff00ffffffffffff00ffffffffffff ffff00ffffffff00ffffff00ffff0000ffff00ffffffffffffffffff0000ffff00ffff00 ffffff00ffff00ffffff00ffff00ffffff00ffffffff00ffffffff00ffffff00ffff00ff ffff00ffff00ffff0000ffffffffffffffffffff000000ffffff0000ffff00ffff00ffff ff00ffff00ff00ff00ffffffffffffffffff00ffffffffffff00ffffff00ffff0000ffff 00ffff00ffff0000ffff00ffffff00ffff0000ffff00ffff0000ffff00ffff00ffffff00 ffff00ffffffffffffffff00ffffffffffffffffffffffffff00ffffffffffff0000ffff ffff000000ffffffff00000000ffffffff0000ffffffffffffffffff000000ff000000ff 000000ff000000ff000000ff000000ff000000ff000000ff0000ffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffff0000000000ffff00ffffffffffff0000000000ffffffff00ffffffff00ff ffff00ffff0000000000ffff00ffffffffffff00ffffff00ffff00ffffff00ffffff0000 00ffffffffff00ffffffffff0000ffffffffffff00ffffffff00ffffff00ffffffffffff 00ffff0000000000ffff00ffffff00ffffff0000ffffffffffffffffffffff00ff00ffff ffff0000000000ffffffff00ffffffff00ffffffffffffff00000000ffff00ffffff00ff ffff000000ffffff00ff00ff00ffffffff00ffffffffff000000ffffffff000000ffffff ffff00ffffffff00ffffff00ffff00ffffff00ffffffffffffffffff00ffffffffffff00 00000000ffff00ffffffffffff0000000000ffffffff00ffffffff00ffffff00ffff0000 000000ffff00ffffff00ffffffffffffffffffffff00ffffffff00ffffffffffff00ffff ff00ffff00ff00ff00ffffffffffffffffffff000000ffffff0000000000ffff00ffffff 00ffff00ffffff00ffff0000000000ffff00ffffffffffff00ffffff00ffff00ffffff00 ffffff000000ffffffffff00ffffffffff0000ffffffffffff00ffffffffffffffff00ff ff00ffffff00ffffffffffff00ffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffff00ffffffffffff00ffffff00ffff00ffffffffffffffff00ffffffffff00 ff00ffffff00ffffffffffff00ffffffffffff00ffffff00ffff00ffffff00ffffffffff ff00ffffffff00ff00ffffff0000ffffffffffff00ffffffff00ffffff00ffff00ffffff 00ffffffffff00ffffff00ffffff00ffffff0000ffffffffffffffffffffff00ffff00ff ffff00ffffffffffffffff00ff00ffff00ffffffffffff00ffffff00ffff00ffffff00ff ffffffffff00ffff00ff00ff00ffffffff00ffffffffffffffff00ffffffffffff00ffff ffff00ffffffff00ffffff00ffff00ffffff00ffffffffffffffffff00ffffffffffff00 ffffffffffff00ffffff00ffff00ffffffffffffffff00ffffffffff00ff00ffffff00ff ffffffffff00ffff0000ffffffffffffffffffffff00ffffffff00ffffffffffff00ffff ff00ffff00ff00ff00ffffffffffffffffffffffffff00ffff00ffffffffffff00ffffff 00ffff00ffff0000ffff00ffffffffffff00ffffffffffff00ffffff00ffff00ffffff00 ffffffffffff00ffffffff00ff00ffffff0000ffffffffffff00ffffffff00ffffff00ff ff00ffffff00ffffffffff00ffffff00ffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffff000000ffffffff000000ffffffff000000ffffffff000000ffffffffff 00ffffffffff000000ffffff00ffffffffffff00ffffff00ffffff000000ffffff000000 00ffffffffffff00ffffffffffffffffffffff000000ffffffff000000ffffffff000000 ffffffffffff00ffffffff000000ffffffffffffffffffffffffffffffffff00ffffff00 ffffff000000ffffffffffff00ffffff00ffffffffffffff00000000ffff00ffffff00ff ff00000000ffffff00ff00ff00ffffff000000ffffff00000000ffffff00000000ffffff ff000000ffffffff000000ffffff00ffffff00ffffffffffffffffff00ffffffffffffff 000000ffffffff000000ffffffff000000ffffffff000000ffffffffff00ffffffffff00 0000ffffffff0000ff00ffffffffffffffffffffff00ffffffff00ffffffffffffff0000 00ffffff00ff00ff00ffffffffffffffffff00000000ffffffff000000ffffff00ffffff 00ffffff0000ff00ffffff000000ffffff00ffffffffffff00ffffff00ffffff000000ff ffff00000000ffffffffffff00ffffffffffffffffffffff000000ffffffff000000ffff ffff000000ffffffff0000ffffffffff000000ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffff00ffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffff0000ffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffff00ff00ffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffff00ffff00ffffffffffffffffff000000000000ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000 00000000ffffffffffff ffffffffffffffff0000000000ffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffff00ffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffff00ffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffff000000ffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffff00ffffff00ffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffff00ffffffffffffff000000ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffff0000ffffffffffffff00ff000000000000ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000 00000000ffffffffffff ffffffffffffffffffffffff00ffffffffffffff000000ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffff00ffffff00ffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffff000000ffffffffffffffffff0000ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffff000000ffffffffffffffffff00ffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffff00ffffff00ffffffffffffffff00ffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffff00ffffffffffffffff00ffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffff000000ffffffffffffffffff000000000000ffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000 00000000ffffffffffff ffffffffffffffff00ffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffff00ffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffff0000000000ffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffff00ffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffff0000ffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffff00ffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff000000ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff000000ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff000000ffffffffff ffffffffffffffffffff00ffffffffffffffffffff000000000000000000ff000000ff00 0000ff000000ff000000ff000000ff000000ff000000ff00000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 0000ff000000ff000000ff000000ff000000ff000000ff000000ff000000ff000000ff00 0000ff000000ff000000ff000000ff000000ff000000ff000000ff000000ff000000ff00 0000ff000000ff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000 00000000ff00ffffffff ffffffffffffffffffff00ffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff000000ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff000000ffffffffff ffffffffffffffffffff00ffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff0000ffffffffffff ffffffffffffffffff000000ffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff0000ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffffff000000ffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffff00ffffff00ffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffff00ffff0000ffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff000000ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff000000ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff000000ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffff00ffffffffffff ffffffffffffffff00ff00ff00ffffffffffffffff000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 000000000000000000000000000000000000000000000000000000000000000000000000 00000000ffffffffffff ffffffffffffffff0000ffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffff00ffffff00ffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffff000000ffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff000000ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff000000ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffffff000000ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff000000ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff0000ffffffff00ffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff0000ffffffff00ffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffff ffff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffff0000ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffff00ffff0000ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff00ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ff00ff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ff00ff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff000000ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffff00ff00ff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffff000000ffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff 00ffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff0000ffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000 0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffff0000ffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff 0000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffff00ffffff00ffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffff00ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffff00ffffff00ffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffff00ffffffff00ffffff00ffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff00ffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffff000000ffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffff0000000000ffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff 00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffff000000ffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffff000000ffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffff000000ffffffff000000ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffff000000ffffff0000000000ffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000ffffff ffffff00ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff ffffffffffffffffffff GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Wed May 15 14:32:51 2002 %%DocumentFonts: %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/actions_on_receiving_packets.eps0000644000076400007640000005503710122646341024731 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 2 15 561 782 %%Title: actions_on_receiving_packets %%CreationDate: Tue May 21 10:00:23 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 53 dict def tgifdict begin /tgifarrowtipdict 8 dict def tgifarrowtipdict /mtrx matrix put /TGAT % tgifarrowtip { tgifarrowtipdict begin /dy exch def /dx exch def /h exch def /w exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate dy dx atan rotate 0 0 moveto w neg h lineto w neg h neg lineto savematrix setmatrix end } def /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 2 15 561 782 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % TEXT NP 0 SG GS 1 W 217 90 M GS GS 0 /Courier-Bold FF [20 0 0 -20 0 0] MS (NACK) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier-Bold FF [20 0 0 -20 0 0] MS (NACK) SH GR GR % TEXT NP 0 SG GS 1 W 411 57 M GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (Are we) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (Are we) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (waiting) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (waiting) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (to send a) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (to send a) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (NACK for these) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (NACK for these) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS ( pckts?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS ( pckts?) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 411 20 M 313 96 L 411 173 L 509 96 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 411 101 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % BOX 0 SG GS 10 SM GS NP 544 53 M 782 53 L 782 140 L 544 140 L CP S GR GR % TEXT NP 0 SG GS 1 W 556 76 M GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (Cancel the sending) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (of the NACK and wait) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (to receive a ) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (retransmission.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 509 96 M 0 34 atan DU cos 8.000 MU 543 exch SU exch sin 8.000 MU 96 exch SU L TGSM 1 W S GR GS TGSM NP 543 96 8.000 3.000 34 0 TGAT 1 SG CP F 0 SG NP 543 96 8.000 3.000 34 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 411 175 M 37 0 atan DU cos 8.000 MU 411 exch SU exch sin 8.000 MU 212 exch SU L TGSM 1 W S GR GS TGSM NP 411 212 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 411 212 8.000 3.000 0 37 TGAT CP F GR % TEXT NP 0 SG GS 1 W 411 259 M GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (Is there a) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (Is there a) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (scheduled) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (scheduled) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (retransmission) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (retransmission) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (?) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 411 210 M 311 281 L 411 353 L 511 281 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 411 286 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % TEXT NP 0 SG GS 1 W 410 429 M GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (Do we) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (Do we) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (have the) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (have the) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (requested) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (requested) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (packets?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (packets?) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 410 389 M 323 458 L 410 527 L 497 458 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 410 463 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % POLY/OPEN-SPLINE 0 SG GS NP 410 353 M 37 0 atan DU cos 8.000 MU 410 exch SU exch sin 8.000 MU 390 exch SU L TGSM 1 W S GR GS TGSM NP 410 390 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 410 390 8.000 3.000 0 37 TGAT CP F GR % BOX 0 SG GS 10 SM GS NP 530 413 M 730 413 L 730 502 L 530 502 L CP S GR GR % TEXT NP 0 SG GS 1 W 539 436 M GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (Schedule the) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (retransmission) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (of the requested) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (packets.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 495 458 M 0 34 atan DU cos 8.000 MU 529 exch SU exch sin 8.000 MU 458 exch SU L TGSM 1 W S GR GS TGSM NP 529 458 8.000 3.000 34 0 TGAT 1 SG CP F 0 SG NP 529 458 8.000 3.000 34 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 9 623 M 0 185 atan DU cos 12.000 MU 194 exch SU exch sin 12.000 MU 623 exch SU L TGSM 3 W S 1 W GR GS TGSM NP 194 623 12.000 5.000 185 0 TGAT 1 SG CP F 0 SG NP 194 623 12.000 5.000 185 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 8 614 M GS 0 SG /Courier-Bold FF [20 0 0 -20 0 0] MS (retransmission) SH GR GR % BOX 0 SG GS 10 SM GS NP 202 577 M 445 577 L 445 660 L 202 660 L CP S GR GR % TEXT NP 0 SG GS 1 W 211 607 M GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (Cancel a scheduled) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (retransmission for) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (that packet, if any.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 323 663 M 37 0 atan DU cos 8.000 MU 323 exch SU exch sin 8.000 MU 700 exch SU L TGSM 1 W S GR GS TGSM NP 323 700 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 323 700 8.000 3.000 0 37 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 321 976 M 37 0 atan DU cos 8.000 MU 321 exch SU exch sin 8.000 MU 1013 exch SU L TGSM 1 W S GR GS TGSM NP 321 1013 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 321 1013 8.000 3.000 0 37 TGAT CP F GR % TEXT NP 0 SG GS 1 W 81 1047 M GS 0 SG /Courier-Bold FF [20 0 0 -20 0 0] MS (data ) SH GR GR % BOX 0 SG GS 10 SM GS NP 206 1014 M 474 1014 L 474 1105 L 206 1105 L CP S GR GR % TEXT NP 0 SG GS 1 W 216 1038 M GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (Insert the data in) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (the cache, and) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (cancel any event ) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (related to this packet) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 321 1105 M 37 0 atan DU cos 8.000 MU 321 exch SU exch sin 8.000 MU 1142 exch SU L TGSM 1 W S GR GS TGSM NP 321 1142 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 321 1142 8.000 3.000 0 37 TGAT CP F GR % BOX 0 SG GS 10 SM GS NP 434 1159 M 630 1159 L 630 1242 L 434 1242 L CP S GR GR % TEXT NP 0 SG GS 1 W 462 1194 M GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (Send data to ) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (application.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 399 1199 M 0 34 atan DU cos 8.000 MU 433 exch SU exch sin 8.000 MU 1199 exch SU L TGSM 1 W S GR GS TGSM NP 433 1199 8.000 3.000 34 0 TGAT 1 SG CP F 0 SG NP 433 1199 8.000 3.000 34 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 321 1255 M 37 0 atan DU cos 8.000 MU 321 exch SU exch sin 8.000 MU 1292 exch SU L TGSM 1 W S GR GS TGSM NP 321 1292 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 321 1292 8.000 3.000 0 37 TGAT CP F GR % TEXT NP 0 SG GS 1 W 518 85 M GS 0 SG /Courier-Bold FF [18 0 0 -18 0 0] MS (Y) SH GR GR % TEXT NP 0 SG GS 1 W 422 191 M GS 0 SG /Courier-Bold FF [18 0 0 -18 0 0] MS (N) SH GR GR % BOX 0 SG GS 10 SM GS NP 203 701 M 467 701 L 467 825 L 203 825 L CP S GR GR % TEXT NP 0 SG GS 1 W 211 723 M GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (Cancel a scheduled) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (event of sending of) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (NACK or waiting for) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (retransmission, ) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (related to this packet,) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (if any.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 323 826 M 37 0 atan DU cos 8.000 MU 323 exch SU exch sin 8.000 MU 863 exch SU L TGSM 1 W S GR GS TGSM NP 323 863 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 323 863 8.000 3.000 0 37 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 125 98 M 0 183 atan DU cos 12.000 MU 308 exch SU exch sin 12.000 MU 98 exch SU L TGSM 3 W S 1 W GR GS TGSM NP 308 98 12.000 5.000 183 0 TGAT 1 SG CP F 0 SG NP 308 98 12.000 5.000 183 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 34 1060 M 0 159 atan DU cos 12.000 MU 193 exch SU exch sin 12.000 MU 1060 exch SU L TGSM 3 W S 1 W GR GS TGSM NP 193 1060 12.000 5.000 159 0 TGAT 1 SG CP F 0 SG NP 193 1060 12.000 5.000 159 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 324 903 M GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (Do we) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (Do we) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (have this) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (have this) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (packet?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (packet?) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 322 863 M 242 919 L 322 975 L 402 919 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 322 923 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % TEXT NP 0 SG GS 1 W 505 447 M GS 0 SG /Courier-Bold FF [18 0 0 -18 0 0] MS (Y) SH GR GR % TEXT NP 0 SG GS 1 W 417 373 M GS 0 SG /Courier-Bold FF [18 0 0 -18 0 0] MS (N) SH GR GR % TEXT NP 0 SG GS 1 W 329 994 M GS 0 SG /Courier-Bold FF [18 0 0 -18 0 0] MS (N) SH GR GR % TEXT NP 0 SG GS 1 W 323 1181 M GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (Is the) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (Is the) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (packet) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (packet) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (in order?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (in order?) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 321 1143 M 241 1199 L 321 1255 L 401 1199 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 321 1203 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % BOX 0 SG GS 10 SM GS NP 216 1293 M 458 1293 L 458 1378 L 216 1378 L CP S GR GR % TEXT NP 0 SG GS 1 W 229 1314 M GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (A gap was detected.) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (Schedule the sending) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (of NACKs for the) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (lost packets) SH GR GR % TEXT NP 0 SG GS 1 W 328 1272 M GS 0 SG /Courier-Bold FF [18 0 0 -18 0 0] MS (N) SH GR GR % TEXT NP 0 SG GS 1 W 408 1187 M GS 0 SG /Courier-Bold FF [18 0 0 -18 0 0] MS (Y) SH GR GR % TEXT NP 0 SG GS 1 W 628 902 M GS 0 SG /Courier-Bold FF [20 0 0 -20 0 0] MS (leave group ) SH GR GR % BOX 0 SG GS 10 SM GS NP 793 867 M 989 867 L 989 950 L 793 950 L CP S GR GR % TEXT NP 0 SG GS 1 W 823 904 M GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (Deactivate the) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (member.) SH GR GR % TEXT NP 0 SG GS 1 W 627 1055 M GS 0 SG /Courier-Bold FF [20 0 0 -20 0 0] MS (join request) SH GR GR % BOX 0 SG GS 10 SM GS NP 794 1017 M 990 1017 L 990 1100 L 794 1100 L CP S GR GR % TEXT NP 0 SG GS 1 W 816 1054 M GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (Send a join) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (accept message.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 621 912 M 0 159 atan DU cos 12.000 MU 780 exch SU exch sin 12.000 MU 912 exch SU L TGSM 3 W S 1 W GR GS TGSM NP 780 912 12.000 5.000 159 0 TGAT 1 SG CP F 0 SG NP 780 912 12.000 5.000 159 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 623 1065 M 0 159 atan DU cos 12.000 MU 782 exch SU exch sin 12.000 MU 1065 exch SU L TGSM 3 W S 1 W GR GS TGSM NP 782 1065 12.000 5.000 159 0 TGAT 1 SG CP F 0 SG NP 782 1065 12.000 5.000 159 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 657 610 M GS 0 SG /Courier-Bold FF [20 0 0 -20 0 0] MS (refresh ) SH GR GR % TEXT NP 0 SG GS 1 W 877 591 M GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (Do we) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (Do we) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (have the) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (have the) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (advertised) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (advertised) SH GR 0 19 RM GS GS 0 /Courier FF [18 0 0 -18 0 0] MS (packet?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [18 0 0 -18 0 0] MS (packet?) SH GR 0 19 RM GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 875 556 M 791 619 L 875 681 L 960 619 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 875 623 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % POLY/OPEN-SPLINE 0 SG GS NP 875 681 M 27 0 atan DU cos 8.000 MU 875 exch SU exch sin 8.000 MU 708 exch SU L TGSM 1 W S GR GS TGSM NP 875 708 8.000 3.000 0 27 TGAT 1 SG CP F 0 SG NP 875 708 8.000 3.000 0 27 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 624 622 M 0 159 atan DU cos 12.000 MU 783 exch SU exch sin 12.000 MU 622 exch SU L TGSM 3 W S 1 W GR GS TGSM NP 783 622 12.000 5.000 159 0 TGAT 1 SG CP F 0 SG NP 783 622 12.000 5.000 159 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 884 696 M GS 0 SG /Courier-Bold FF [18 0 0 -18 0 0] MS (N) SH GR GR % BOX 0 SG GS 10 SM GS NP 755 708 M 995 708 L 995 800 L 755 800 L CP S GR GR % TEXT NP 0 SG GS 1 W 768 730 M GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (A gap was detected.) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (Schedule the sending) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (of NACKs for the) SH GR 0 19 RM GS 0 SG /Courier FF [18 0 0 -18 0 0] MS (lost packets.) SH GR GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Tue May 21 10:00:23 2002 %%DocumentFonts: Courier %%+ Courier-Bold %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/simple_event_list.eps0000644000076400007640000001241310122646342022545 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 9 695 322 767 %%Title: simple_event_list %%CreationDate: Tue May 14 18:48:54 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 53 dict def tgifdict begin /tgifarrowtipdict 8 dict def tgifarrowtipdict /mtrx matrix put /TGAT % tgifarrowtip { tgifarrowtipdict begin /dy exch def /dx exch def /h exch def /w exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate dy dx atan rotate 0 0 moveto w neg h lineto w neg h neg lineto savematrix setmatrix end } def /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 9 695 322 767 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % BOX 0 SG GS 10 SM GS NP 44 66 M 108 66 L 108 98 L 44 98 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 76 66 M 76 98 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 140 66 M 204 66 L 204 98 L 140 98 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 172 66 M 172 98 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 236 66 M 300 66 L 300 98 L 236 98 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 268 66 M 268 98 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 332 66 M 396 66 L 396 98 L 332 98 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 364 66 M 364 98 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 428 66 M 492 66 L 492 98 L 428 98 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 460 66 M 460 98 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 108 82 M 0 32 atan DU cos 8.000 MU 140 exch SU exch sin 8.000 MU 82 exch SU L TGSM 1 W S GR GS TGSM NP 140 82 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 140 82 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 204 82 M 0 32 atan DU cos 8.000 MU 236 exch SU exch sin 8.000 MU 82 exch SU L TGSM 1 W S GR GS TGSM NP 236 82 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 236 82 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 300 82 M 0 32 atan DU cos 8.000 MU 332 exch SU exch sin 8.000 MU 82 exch SU L TGSM 1 W S GR GS TGSM NP 332 82 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 332 82 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 396 82 M 0 32 atan DU cos 8.000 MU 428 exch SU exch sin 8.000 MU 82 exch SU L TGSM 1 W S GR GS TGSM NP 428 82 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 428 82 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 493 82 M 525 82 L 525 114 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 509 130 M 541 130 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 493 119 M 557 119 L TGSM 1 W S GR % TEXT NP 0 SG GS 1 W 56 87 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (4) SH GR GR % TEXT NP 0 SG GS 1 W 154 87 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (2) SH GR GR % TEXT NP 0 SG GS 1 W 249 88 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (0) SH GR GR % TEXT NP 0 SG GS 1 W 345 87 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (7) SH GR GR % TEXT NP 0 SG GS 1 W 439 87 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (4) SH GR GR % BOX 0 SG GS 10 SM GS NP 20 47 M 570 47 L 570 169 L 20 169 L CP 2 W S GR GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Tue May 14 18:48:54 2002 %%DocumentFonts: Courier %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/packet_types.eps0000644000076400007640000002447210122646341021522 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 1 471 528 793 %%Title: packet_types %%CreationDate: Tue May 14 16:38:03 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 51 dict def tgifdict begin /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 1 471 528 793 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % BOX GS 10 62 TR [1.000 0.000 0.000 0.531 0 0] CO 10 NE 62 NE TR 0 SG GS 10 SM GS NP 10 62 M 121 62 L 121 126 L 10 126 L CP TGSM S GR GR GR % TEXT NP 0 SG GS 1 W 27 83 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (char ) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS (type) SH GR GR % BOX GS 121 62 TR [1.000 0.000 0.000 0.531 0 0] CO 121 NE 62 NE TR 0 SG GS 10 SM GS NP 121 62 M 322 62 L 322 126 L 121 126 L CP TGSM S GR GR GR % TEXT NP 0 SG GS 1 W 141 83 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (MEMBER_ID ) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS (sender_id) SH GR GR % TEXT NP 0 SG GS 1 W 337 84 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (int) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS ( packet_size) SH GR GR % BOX GS 322 62 TR [1.000 0.000 0.000 0.531 0 0] CO 322 NE 62 NE TR 0 SG GS 10 SM GS NP 322 62 M 479 62 L 479 126 L 322 126 L CP TGSM S GR GR GR % BOX GS 479 62 TR [2.159 0.000 0.000 0.531 0 0] CO 479 NE 62 NE TR 0 SG GS 10 SM GS NP 479 62 M 611 62 L 611 126 L 479 126 L CP TGSM S GR GR GR % TEXT NP 0 SG GS 1 W 499 85 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (union PACKET_DATA ) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS (packet_data) SH GR GR % TEXT NP 0 SG GS 1 W 10 48 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (PACKET) SH GR GR % POLY/OPEN-SPLINE 0 SG GS [4 4] 0 SD NP 480 97 M 59 191 L TGSM 2 W S [] 0 SD 1 W GR % POLY/OPEN-SPLINE 0 SG GS [4 4] 0 SD NP 765 96 M 923 189 L TGSM 3 W S [] 0 SD 1 W GR % TEXT NP 0 SG GS 1 W 91 315 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (MEMBER_ID) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS ( original_sender_id) SH GR GR % TEXT NP 0 SG GS 1 W 377 315 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (DATA_PACKET ) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS (data_packet) SH GR GR % TEXT NP 0 SG GS 1 W 73 286 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (RETRANSM_PACKET) SH GR GR % TEXT NP 0 SG GS 1 W 91 383 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (MEMBER_ID) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS ( request_member_id) SH GR GR % TEXT NP 0 SG GS 1 W 381 383 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (int ) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS (sn) SH GR GR % TEXT NP 0 SG GS 1 W 75 354 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (NAK_PACKET) SH GR GR % BOX GS 73 432 TR [1.000 0.000 0.000 0.531 0 0] CO 73 NE 432 NE TR 0 SG GS 10 SM GS NP 73 432 M 312 432 L 312 496 L 73 496 L CP TGSM S GR GR GR % TEXT NP 0 SG GS 1 W 91 454 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (int) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS ( sn_of_last_msg_sent) SH GR GR % TEXT NP 0 SG GS 1 W 73 427 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (REFRESH_PACKET) SH GR GR % TEXT NP 0 SG GS 1 W 77 499 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (JOIN_ACCEPT_PACKET) SH GR GR % BOX 0 SG GS 10 SM GS NP 59 192 M 924 192 L 924 549 L 59 549 L CP S GR GR % TEXT NP 0 SG GS 1 W 91 527 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (int) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS ( port) SH GR GR % TEXT NP 0 SG GS 1 W 91 242 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (int) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS ( sn) SH GR GR % TEXT NP 0 SG GS 1 W 182 242 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (int) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS ( data_size) SH GR GR % TEXT NP 0 SG GS 1 W 72 213 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (DATA_PACKET) SH GR GR % TEXT NP 0 SG GS 1 W 326 242 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (BYTE) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS ( *data) SH GR GR % BOX 0 SG GS 10 SM GS NP 78 505 M 187 505 L 187 539 L 78 539 L CP S GR GR % BOX GS 70 219 TR [1.000 0.000 0.000 0.872 0 0] CO 70 NE 219 NE TR 0 SG GS 10 SM GS NP 70 219 M 166 219 L 166 258 L 70 258 L CP TGSM S GR GR GR % BOX GS 166 219 TR [1.000 0.000 0.000 0.872 0 0] CO 166 NE 219 NE TR 0 SG GS 10 SM GS NP 166 219 M 310 219 L 310 258 L 166 258 L CP TGSM S GR GR GR % BOX GS 310 219 TR [1.000 0.000 0.000 0.872 0 0] CO 310 NE 219 NE TR 0 SG GS 10 SM GS NP 310 219 M 438 219 L 438 258 L 310 258 L CP TGSM S GR GR GR % BOX GS 73 291 TR [1.000 0.000 0.000 0.531 0 0] CO 73 NE 291 NE TR 0 SG GS 10 SM GS NP 73 291 M 359 291 L 359 355 L 73 355 L CP TGSM S GR GR GR % BOX GS 359 291 TR [1.000 0.000 0.000 0.531 0 0] CO 359 NE 291 NE TR 0 SG GS 10 SM GS NP 359 291 M 595 291 L 595 355 L 359 355 L CP TGSM S GR GR GR % BOX GS 75 360 TR [1.000 0.000 0.000 0.531 0 0] CO 75 NE 360 NE TR 0 SG GS 10 SM GS NP 75 360 M 361 360 L 361 424 L 75 424 L CP TGSM S GR GR GR % BOX GS 361 360 TR [1.000 0.000 0.000 0.531 0 0] CO 361 NE 360 NE TR 0 SG GS 10 SM GS NP 361 360 M 445 360 L 445 424 L 361 424 L CP TGSM S GR GR GR % TEXT NP 0 SG GS 1 W 465 383 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (int ) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS (base_sn) SH GR GR % BOX GS 445 360 TR [1.524 0.000 0.000 0.531 0 0] CO 445 NE 360 NE TR 0 SG GS 10 SM GS NP 445 360 M 529 360 L 529 424 L 445 424 L CP TGSM S GR GR GR % BOX GS 734 360 TR [1.095 0.000 0.000 0.531 -8 0] CO 734 NE 360 NE TR 0 SG GS 10 SM GS NP 734 360 M 818 360 L 818 424 L 734 424 L CP TGSM S GR GR GR % BOX GS 573 360 TR [1.821 0.000 0.000 0.531 0 0] CO 573 NE 360 NE TR 0 SG GS 10 SM GS NP 573 360 M 657 360 L 657 424 L 573 424 L CP TGSM S GR GR GR % BOX GS 818 360 TR [1.083 0.000 0.000 0.531 0 0] CO 818 NE 360 NE TR 0 SG GS 10 SM GS NP 818 360 M 902 360 L 902 424 L 818 424 L CP TGSM S GR GR GR % TEXT NP 0 SG GS 1 W 578 383 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (int ) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS (windows_size) SH GR GR % TEXT NP 0 SG GS 1 W 729 383 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (int ) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS (hmask) SH GR GR % TEXT NP 0 SG GS 1 W 822 383 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (int ) SH 0 SG /Courier FF [14 0 0 -14 0 0] MS (lmask) SH GR GR % BOX 0 SG GS 10 SM GS NP 5 1 M 936 1 L 936 567 L 5 567 L CP 2 W S GR GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Tue May 14 16:38:03 2002 %%DocumentFonts: Courier %%+ Courier-Bold %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/tgwb.pdf0000644000076400007640000132705110434752600017756 0ustar williamwilliam%PDF-1.2 7 0 obj << /Type/Encoding /Differences[0/x0/x1/x2/x3/x4/x5/x6/x7/x8/x9/xa/xb/xc/xd/xe/xf/x10/x11/x12/x13/x14/x15/x16/x17/x18/x19/x1a/x1b/x1c/x1d/x1e/x1f/x20/x21/x22/x23/x24/x25/x26/x27/x28/x29/x2a/x2b/x2c/x2d/x2e/x2f/x30/x31/x32/x33/x34/x35/x36/x37/x38/x39/x3a/x3b/x3c/x3d/x3e/x3f/x40/x41/x42/x43/x44/x45/x46/x47/x48/x49/x4a/x4b/x4c/x4d/x4e/x4f/x50/x51/x52/x53/x54/x55/x56/x57/x58/x59/x5a/x5b/x5c/x5d/x5e/x5f/x60/x61/x62/x63/x64/x65/x66/x67/x68/x69/x6a/x6b/x6c/x6d/x6e/x6f/x70/x71/x72/x73/x74/x75/x76/x77/x78/x79/x7a/x7b/x7c/x7d/x7e/x7f/x80/x81/x82/x83/x84/x85/x86/x87/x88/x89/x8a/x8b/x8c/x8d/x8e/x8f/x90/x91/x92/x93/x94/x95/x96/x97/x98/x99/x9a/x9b/x9c/x9d/x9e/x9f/xa0/xa1/xa2/xa3/xa4/xa5/xa6/xa7/xa8/xa9/xaa/xab/xac/xad/xae/xaf/xb0/xb1/xb2/xb3/xb4/xb5/xb6/xb7/xb8/xb9/xba/xbb/xbc/xbd/xbe/xbf/xc0/xc1/xc2/xc3/xc4/xc5/xc6/xc7/xc8/xc9/xca/xcb/xcc/xcd/xce/xcf/xd0/xd1/xd2/xd3/xd4/xd5/xd6/xd7/xd8/xd9/xda/xdb/xdc/xdd/xde/xdf/xe0/xe1/xe2/xe3/xe4/xe5/xe6/xe7/xe8/xe9/xea/xeb/xec/xed/xee/xef/xf0/xf1/xf2/xf3/xf4/xf5/xf6/xf7/xf8/xf9/xfa/xfb/xfc/xfd/xfe/xff] >> endobj 16 0 obj << /Filter[/FlateDecode] /Length 2121 >> stream xÚ”X[—Û¶~ïŻĐÉuvĆŻ~Ê:ÎeÓű8MuêŻ°"$!K*AZȚÖęïÁ (z-ç$mŸ,€Á`0ŚC-’8I»…ŸŁáüGàŸ‡‹Ôż.ŰŃçë/ż QÆ©XŹ· ™Æ”XŹȘ*.ČĆúƛhœŚË•2úY·FĘ·Œz9¶ƒÙ(7ĐòGsß«ț‘wŃÏ/Œ[ÒBu MÖËȄռW$€Ńír•đśíú‡E^Çy¶X„oÇk_ïÍ ï=‡U=‹xĄß-Ó<Ò­=ÂLzŠ[ÏžșC†A Æv(űËoӅĄ9Ú¶Êâ lK«žȘü%?Ű~‡öÀٛ¶}tp†ÿ‹ŠH7ö)yôÒŽșSŽûśê¶șo•ß+ŁȘ3șć=Ő .eŽ!łÀÉpِqMȚü·ą{ź^à”#~Đę?_”àȘxÜöżÄśœ?É8A§ÈX–țô œŃTŒă͇QÔŚ4I“$'«ćBd±ÌŒŐą1(‘„qU{1bč"IąÛn)“hèA›qsöZ¶šășÀădŠJÏùÖ2:(Óá,‹vV”4ł[‡œqÄ„zH“V™ˆ°miÔïí$ĆكÛGłaV…ŠV‘’wÚ«wh8öSê€ÎÀu§uó䚇Î.!$'’`Œ‰‹‡†’ ł}ăe9„ń đ ȘU ‚cżŃŽł±^­&,‘mÉ­ńzŁPҞ9ÎՃ«YőàrȘ\LՃ _=8ùDàzY„S9ᕷ^#*§§¶MŐTújŠ—«ŹNŁŚ(ó?«ą“i1…ó$R­Ă„ÈêhgȚ±ùžÚۃ/Ż2™Ç9 `áÁ‘œ­}éÆ Ż=n:ێ˜mŽ{43öP—cÔhÒÀt;°"+H&NÀm8)éșÙV‰Î’“łp'8Ë/Țˆ·4™ÜT1èàفBm[âYŐt›vl&%z ˆ » Æ?B: Łżîúbt:}r»ȚŽGôF!!qÌBí8Z >óqvPè„GbŠ4íŒNoǖæ[#Ù锔(êÈÙ°Ùkiï #rY "đ]:i[*o*žpšpÂïŸ(Až«đfqJ)àńƒ‡S\ ,\”ÓPÚZ’qiŽÓîUKDź«^m@kă (nąSd EćˆTc™{ĐÜé{zŠHêYŹèȚ‹ÁûŚšô%)EĆÂabGHź‘ÀćłwÙ0;‡L „žMo˜„…)ësaŠrv̐àžüp­ŸÜß2Œ@źû! očœĆœHŠbąB…/WĂ*èS֜z8 ˆˆi^Vè ącą†3Ü/śOY))A «Ż;bÀœ?i,H%l©·IĄ­HêškȘ=rțd>kÄž©1őaiì[èł°%ܒˆ_oIDK:ț·ŃČ?Km{ëł6 é‘Í_[\~ÿ śzęŠŒIß>[źJ Ę%iǘ€EùÓ8 hÀNƒfÓ!*ܶƔNȘHń­fôŽ#Éw;aÓm 1ìő˜\ƒKêȘ đŃrÄĆ'!«°­À?„Tț;_æí@˒fʈu±1ő‰SMO œÜۆšgۂĄW;˜pźòÍÖ„Ò{·ÌĄŽÁœł°'GśŸ_€Ÿ•e*Œ0Ę[ç{ ˜Úłœ= RíLEÓi„Y•yȚœŠÀĂÒ2꜈Ł'ŹGoC|^ušX±ÀìgZEg†‘=ńC‚QYXV™È qÛŃH/2ÊÉ뉳7@‘óX`G î cœ)è8,O;–őÎ4šiC}âÞӬ‚‡gz)N€{Eúü*>‚„_Źé|ŹáË€t olÇmG „ŠZÎo™‡#©)0R­Mś„5Ąó–PGœòvă†oj`\ÿƒEt4RDaâtçt )ŸÈv>Í<͆íӞeNĆ4]8Œd+ 6|gŸ_Üś Ëha6Ż^HïМIxau‹Ę’o€e–DGßۍ­ê‰Œíő?GđÚ#-áFž©^ÓdÊńĐčlÛΟőąK†ŽÀŸ›*_6èoÖü óŸá«SLÀr)-öš”LƒÌlúÖéü7/윁 ŹrvAćhŚ”(ÀEU/C“  3èG‹á~1á~x6òđęïœđvÎS đéߑЁÛșÿł/H=û‘ŁÇo8œVŒ–=g0*’æ_SXƒŰ0‘Œ¶ŽúbÓ*<đ-ï• |„Ń!P0Ù›Ęž·è3Ô0ƒûXEƒLŸ2€’‘Š•~æwżY_űí§œœ‚/9Tk^•qMßú ű`#$x9Oá“ï†äá ŸiŃYŸęôąIz]Çęšq”șZęÊWżOp!П(>$°Wök ){ĂC0@ hÛ>à§sšE ÿˊ‘–qšçáÿß© ô6eőg˜)󾔓à«?NpVÆiüA’àž™ŸƍO‘V—Y‹ÿÑyŠœ„ˆój&űêü[sĆJ;ĂOšX «R$±Èű7čK—üćżźSŠ, endstream endobj 18 0 obj << /F1 8 0 R /F2 9 0 R /F3 10 0 R /F4 11 0 R /F5 12 0 R /F6 13 0 R /F7 14 0 R >> endobj 6 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 18 0 R >> endobj 21 0 obj << /Length 68 /Filter/FlateDecode /Name/Im1 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -14 -14] /Resources<< /ProcSet[/PDF/ImageB] /XObject 22 0 R >> >> stream xœ+T0Đ32Č472T0AdNr.WĄ‚‰±©ž± XÀÈÜÜ\ÏÈRÁÌPÏÌÒÔB™€ê™+žäs!Č(“ endstream endobj 22 0 obj << /R7 23 0 R >> endobj 23 0 obj << /Subtype/Image /ColorSpace/DeviceGray /Width 927 /Height 638 /BitsPerComponent 8 /Filter/FlateDecode /DecodeParms<< /Predictor 15 /Columns 927 >> /Length 15749 >> stream xœíè.Y}ßÏăö‚•VRB@vùkÀD ‰˜ŹĄ?ć~§‰žÖą”%źĄ•Zi++B xCéȚ?%b)ĄR4ĘÒJÁ†”%Č>ß/Ž ÒĐ[›”v„șxœ”€›ŠaƒÆoż3s~ÿšsfÎÌ|ÎyȚŻ{żÏó̏3sžy?ïó9sfΙĂ7Űȃ ԎÒòÊ^ôßvăŒ¶ìšŰÓ·ž;>8LŒŠa™€ƒšïÿŽ»èK?6ł`.ÿç'æ§ęsŚr~ćĂ8E©°TÒkțÈłèٗÏß,˜ËsŻ\’úëŻț ;|ïúĂ (J†„’~/_Íüż—ŸhÉNAˆ„b~yŠ?Ąèj,ö§W̐šŸęł=û?ű©Ÿ_ČS""æż“ŸȚnÌ}»|œíá/śț„ą„X,)ûöđáÓì-úûsőŻÿțkĂŒ—ÿ-‘űW_ònöńçÿț/.‘u`sÿćÁEŸ–ŸȚbÎ| œæč‡ÿśàO(J‡Ć’Žț3Äûšæ7_`Ÿ~Ń/°—ț°ŸÙ^Q° sÄÔfț„ą$X,©ò'ś­Šæ5żză]żțÁgżőÆȚŚ+ٗÀï} HȚEź˜rî8Ïń'ʝƒÊú­±Č©æŸ~„ę—ț«?ÔüîG^üvŁôƈ‰ùûĂ85ŒòYÏ=üŒQż@ŃęX,©žKá3|ń›ÆÍŸŒO~űÆ{ûÒgê&ûűwȚË>ü’w `~ÿĄàąÏŒÉț0N Ż|Öę‡ïđążöčP”‹%•w™ó 5ûóŻûKPs}F1żú Ÿ|ő_T‹übZ|ű~śÖŚo@Q:,–TúsX"Ö4ŐüĘ˟xĂțćś æÊŒb~FNkșyĆŽÖŒÿđßûÿđ„ĂbIÙsÚ2čâ·Ć ÉŻĘžÖdŻùÚČś°_{É;‡?° đ#ękž˜oR.üöĂw‡óÏ玠èŸ,–”}Ć»YCMöĆÏłŚÿ—Ț 5Śe<ê_ę"Ÿ|•VúOòÓ™>śòő:9ś'„ĂbI'ü)ù“ęù_\˜W0{Ôó’'ùSE7`±€ț>ő­»/à‹żÿšŸ[Ž+0Éó‹Ć<üł_ùŠîÁrIÔüîțÖ /y:źÍb1Ż"ńŠîÁ&țÛ°?ÁF,śç ćìÍûżÿƒ?Ąh;ŒŸ]}“±ÏĄĄ nnżòżÉüțgBŃ$}æśçĆȚÙKžęy©ùŠÖÍ%üÙŁ?ÿűóđg3ÀŸ Áęyțlűł!ž?Ÿ?›țlˆŃŸßyțlŸ?;vìŽęû1};Ęń:•ü,Òvl˜)ߎúÂ1Őq|ŃśëìzXInFŸÍDꀌŠęÈĘłŒoXÜŸÏ ę?„ąĘ°lâ›zŽ~đúóÈfĂŽƒ*”8ȘƒzdšjUC˜Ł8TG7;‹…Éú†Àęù”Ąÿ§ògÆĄ±fág°7țäćĄ(ÇΧœæ%žQèu˅±6ȚOvölO^™™UŠ•čòÛè‹bôç>?ôÿŽę)“©ĄsL€+đ3 €ăOq™™ÛRym†ŃŸß~ńĐÿsą~돟rMŠ$ĆÏ`Gû“J9ńHÆłłà‰‡Ü‹/wÌXêlÈüI6ÁèÏÎŒń“GCÿù'Ăπö!U/0ŚĐxŠ}7OÝ&Œuá‹'‘‡ËÆÆÙžgŸr/f#Ű§ö‹àݧánŁ?ŻŸé=ÿ”ż_SĂ@û-~4ÄÏ9ˆd Éę«l˜ 3ż?ă„~€?țœáŸAàțŸ[2oìŠŻê_aóûŹ(ßŰ5‡ÂțÄÏ`p|CÌń' üÙđgsț|vï܀e8ț„ą”cÄÏœ3qۍŸ{g ,ăƒ5„ŹßțhśÔo›çŸ óÏæ€?țlűł!àÏæđûSt ß;ŹjÓyWœwÿÈܛVTną»›Ű|gl%ČČ~w©3;6Ă»ŁPÿ! /űŠN䅩ą!N~%}¶ÿ«ÍRSr‘‰žù;swń­ÄÔ ßȚČË€ì.đç ÿóglBŃűú4đ§ÙWÀ»#}\ïț`˜/‰Tł{Ícä`3ìtąŚ •HL9#Śž–Kœ{ŻOû ńj/êĆż'3žĘú’Ëőó”?|Śț„ąU)šäÏ.žáq ”‰OëßÓśæ€áGDö%4ö ÍtwÖY›8êßËśŹUxjkŐĐČ2èçš €ŰH8ƒæšzśÿXęŠÖšhìü3ší|fêŰÌQSÛc(±›3qäp{śUӓQ5Û·ys%ßÎÜ~•*™¶Uś ‡+SçŸPŽ6EÓâ'?TŸo>­Š>XÍ€š|O2ö€1‰ÙqŚÖò)ö©á„šÉ:QëQő%ę[ÊŻíÉźvp­<2+”'ƒFCÍôű9}Ą(E“ë·žŹxŸžg u|§ŐTč*8'ČăźíËgèś—ŁŠóőœ·`vœyôÍśóH dŐo'!„ èf矎š]Ž4 ©=[afąÉ3ŻFĄ•}kê™ŃÒNŸ­È•+>ÿ„ąȚmsțišémŻ^‡eG”]g žX}#s4oĄ~äH7<ŃÖ>Š%~>NZŒ”‰ȘÍdł›Ê©ùőŹœŒYđdW«C…[ûÜ+æ^ù‘ò”ßNùŠVąè†ś9Gd歔Ùß,’wœ<Æ6ŸŠ.X1q ›ùłÀÁőŐ+VĘáČ2Y”?Ąh`ćć»SlćÏ"ÇÖWŻXw3ÈÉdÍț„ąȚuŚô'zÛWŽÓÿŠÖÆOš‚ÛwV:ȚÇű Ր€è()ú—‘çòÎ&ŚyâÂő'„JŠą\Rű“<Śj>1čüYIŠ2úț€J1EęțìŽò}Žß)ČȚȘjȘB-m'čY “ióM)UW—RçŸz\ŸoăOțœÂëAŃ2țTûsê·I`úÆń”őæ«©uMh•Ž4„2ïKPÓ8KQÙQr.éÿiùsXuˆ„NęŠæeauECíC|wGă[êeŁÌĘ䦏­`ì+Čb\M­?àV-öY;JQSŻż­YçŸfÿOłQHLéíCb19E7”šą>Ș]š…KÖđQ'±bcŸïcš>BS„­üö%äLÛHÆźŠŐ4*BÖŚ™sțiöÿÔź«(êŚWŹlíźš “§±iÔ«èäę ¶ÿ—ĐŽJžwCViÜYą?}[đŸÊ»«…ëeáÆ_q晙|¶b]tèf_ÿôöÿäű,©ČDEQ”g”SRtڟÁ|[ëÍwŠJÛ}ę™ÏŒÒÖŹsŰú%ž­È>ÚĄ”ćmčû‡Œ»"ì«hğùÔ«šŚŸ#â‰Mf±`ꀕŽùsYmÈóe"+ś€M;[aÖä?ÎYçŸvÿÏ@Ìtg“QÔšă΀E}ț”uyY+7CJ[í*ôôÙÊBvȚ,ŠÜpfokJÍ©Qoł Ÿ­űĆTr.êÿ©Zm‡7ărèäÙYŃpęö ß?$·ššhć'ZÚŠPVÍáă‚ÚPêVRȘÚÆ,țùĄń2Ń=ŽâĐžˆ1q«ßăâr‹cP"Šê§mKê·Ő+šîωŻ1SMísóÏebêYš_§ò”TđśX șŒHòp–8ÿ űSNŸÉ~ŠÊoœìŒĆÈRŠFîïcGńŠԝű9ŃÚ7UȚ†ÖšșZ&«üÁC–˜;Ț1 èe·é»Á˜*_“ú}–žż=ÎŹú­'~RPTƒXăibîȘV4!~Š,yê·°ÊÛàZ«Ț­iî‰mŻŠ”RŻ uÓÏVă'ÇWż--šh’?#­/FžçŁŒMZmMv*m;çO)ZüüSVs§.†BŃà6ăStąęV֙Ăí·Fq9œżčŰîFŻò€Ô†\9Eœ}”sŃőO­ęVÜÜÇÂí·Pt’Í]vęÓÊsœÇ{]òÎVIŚo3źZù†ą~6SŽ‚ń‡@OKăűł%.ï\MŻVD’ąŠ?Ÿ]=S`.7SVț|ăo~엠(q’eFüLIpûÎą\b8g‡Ę'č?żôȚÏ܀ąâ—TúóöôžžíË‡”h JrqnNߟ#üùŸŚœő­ż€ÊŸ“%éńjRáâÜ<»Œ”țüńßyà­ż€š?'[ÔĄ&Âț|χ٠(Z!éț ]í€Șæ î?ìÏ/ü€ÇŸP”țț3üž8 5Éì?ìOu}ŠV”ÿúo΂šdöŸíO(J}ÿyțôé 5Éì_ˆ)*ź ț„ąŽśï—4ìOWȚ¶ß!œȚÿž»ßăûs1e§Ś$Bьęožż€:zFÔÿïÄp4śUsëï?Š©z§§ùŠŠïóïï—4êOKNšȚÿÆ9ÄÔąbȘ?Ąhòț·Î_Òž?M=Ąfxÿ»¶ŠdBŃÔęoUۇ©čô@,UłÂęÏò'„ŒÿÌë+žKfk”&8š¶ûțçg`BŃÜęoȘhöőOWΔZă‘>;ÉŹëŸP”rú,ŠQT  &™ôaÊțŸPŽźôÙśś9Ćí\5±Œűò‹KkÆ·ÿ'­jč_ÒŰęń¶œP“Ìòƒ3ÇÓÿŠÖŽÜ/iŽY5‰.wÆê|ę?ĄhEËę’Æęi·©jbzőéđű ńțŸP”ìôäű ž]êŐlLo;ÙÿSE©NÏ?ĄKRÓ7ŹÉ1ïúŠ%Š_ÒÌńMü žÆŒoőžyę3„ó>?§Çä ”¶v°ë“äO(ZțLÙÔ€BŠ?S¶EÉ0áϔ§űÇ„‡šÛ“âO(ZđgCÀŸÍ6üÙ©țtpxTIź˜ÛïjnO–?Ąh dűSż™șłÔ<8ęvĄæöäúŠ’'ƟGï; Șčt ł„?‡LŸéO(J?}Č?íŸJ[r„ęùŰGpü E+ ·}È3Ô€B۟ŻúőŸ”AQÊò'Z(ńçÇ6ӟP”„üé5·§š? èÀŸ 6üÙđgsÀŸ öçkđ‚ąȒ?ăË7ôčÌșżŠRNűÙkúŠîüÙđgsÀŸ 6üÙđgsÀŸ 6GŠ?ÇG^1+ Ô€ÁBQÒäùÓûDWšI…ț„ąŽYo|\-Û<ęÊă›@ŃíÓcüĄ†Hyț'­ űł!ÂțTÏÿ„ąU6D۟êùŸPŽ*àφûS=ÿŠVüÙaȘçBŃȘHó§;VjÏQ$š4Hyț'­ŠDƞ 5©q}ŠÖÁțäÏq­đjSćéWó'Ę+=âgC ~6üÙđgsÀŸ 6üÙđgsÀŸ 6üÙđgsÀŸ 6ÇzțÄŐČÍÓŻìO(ș}zÄφÈèÿ EëțlˆŒțŸPŽàφÈèÿ EëțlˆŒțŸPŽàφÈèÿ EëțlˆœțŸPŽ Đ?»!rźŻx7E©±Òű&xZ$ńëŸQ (™ôš!VŸŠnüÙđgsÀŸ 6üÙđgs$ûÓÛ Ï“@MäùŠVüÙđgs$úsž\vTïfšIƒBŃ*ȊŸüQèÖŃŃ[Júüű E‰§Ïđ§&ąĄ'J[*äúŠ’'ŁęV?_é &ArÛoĄ(yÒęi6'hSP“ ™ț„ąô?țlŽÙŚWÔ4Ô€ÂČë+P” đgCÀŸÍ6D۟ŻeÿôoBŃ čžŽf,ôçA}äsxßêĘ/æÂű Eś|ŚŽ>íCŐâíC5s]'2ÿʇ?kĆŃòüŚáÏșńKŠûêÄ[Űâț„šIŽŸÌŒ ­ ôȌŸP”>ńÓŒ›j$3~BQú€ÇÏ_Ż$šI…ÜűÙEI“?uPÚ$;~ê@QŠäĆOĆ€šè-žyú9ńSE П?(mÉŒŸÎó?Ł@Q:̍Ÿ šI…pütžÿŠ’ńł%‚ńÓyțg(JÄÏvÇOçùŸQ (?["?çFąt˜węSjR!?çJ (iČâgÖhŒPs{ČŻBQê€ÇϜŃńŽÈźBQòé3â'z;'3~BQú$ÇOô$Ofü„ąôIŸP“>yńŠV@jüòÙïP“yńŠV@rü„š?Ąh äĆOu”lO5Ï횙?Ą(ièÇÏłțƔ/OMÏZ„Žű E3XíüłŰŐČ^»ć«HƖ„Ÿ ùëŸPŽ‚ôû”ßÊBđlx^ÏČ{|ù°d˜wOÌorú†îč…«òlÜÏ=.đ°?=ĆYő…r0~zûBŃ Űïú§(EùŸțß(­őűùąÄvÖăé…úr?b3Ú|æî·>ÂńÓÛÿŠÒ'=~żÛD?zš”ą”U„-cÌ'€*tŐ߯)±ú֏BÍû«˜`üôśÿ„ąôIŽŸĆGK•%c?Ą©iO>ĂV“Y‚†Ô4J㠚ŐŽ=áűéïÿ Eɓ?K–ȘŐNœÚœž¶>Ó%Mš ÙËm5-č«&?Cę?Ą(uÒăgOŚż‹Œ–*ÏæÏĜŸ1áLÌž§Ż§2jKȘ°Ö—ß;3ӛő&Qș3±àŒ ê%?§ûBQ’dĆOÜmBŹëŸ6P”"yńSQ“?æźÂ«M•§Ï»țiE П?(mɰ(~* (æÆOM5Ő9ОčۖeńSEɀűÙˆŸÍŃjüÍnmŸÏ8ôŚ;ú—±ßŚőëá*3~†€ą»àQ”ù%-áÏĘź–=}ëi6OĐșź–ź 9Ź5źéÓr"~†€ąÓ[#œ«èáŰ`ü앜%hU„mŻ&îàj^eŸ†€ąûàQ”ìű} Őds­LÍŸțcščrü„ą+ă*Úäù§Ò0SĐ ŐŒokߚ=ÿ<]EŽŸ|*CĐșÔti=~ò©RŽńűÉg€ ڞšÍĆO>ădm>~òyI‚Öźfš°ęhkțd§ąhZüŽ{"™Ô &KŽ=5ïsŸ–œùW h€ÄÏ5=oùĄ9Ì{ïߞžś•‚ąM :ìzf~)Œ ['~BŃJȚgÇOuËæz„m Ü\BTĐêKÛ@a{•äO(J‘9ńłżgS= *5YLĐÚŐ ¶Óț„ąDIkż5: òÛ©kP“_IrڞšĄű Ek!©ęV(7łÌœGYÍa+țœűu֜yșŽ$ÇO(Z !I}țŽz 9©«̊#hő„mnü„ąäɉŸțkz5ĘŸ tԌćÄŽv5ÓÏ?Ąh%džúFŹ[ă‰ȘÉ&G…Ôy*A«ŽdŹÌŒóO(J›ŹóOŁÀPł@oÁB”ĄI„ ăÚŒ7đüNÁ9».š>?~2(ZzŚeÓÏiż=š3I—¶©čŽ֖*.•s‚ńÓyț'­„€űi=*òhÌ#Źæ!mÌsQûՔ;]çbƊ„ă§ûüO(ZińÓjÜž^6¶&ۇ„š)šś[ö>«“3?ĘçBŃ:ȌŸ?2CM—:ÔÔ.‡ĘrśY›šáűé>ÿŠVAjüë{jEŐȘiJéÙgęjŠűé>ÿŠÖAZüôR”šŽ”ž}ÖŠf8~úžÿéŠR#1~ÆšPMŸ”ž}ÖŻfđúg(J‡ń“łȚÓ"Wëí °¶_Ž”öőÏ(PÔ ĘëŸQȘ*mĂRČź–bül[QÒă­ĐÛ>șNŃ»Mv`Íű Ewtüœ©gpޚű Ü­I>~BŃ\(ÇÏrj&HɖçyoèÇO(š ńű9ßh©‚xڞšôâçNXQâńsÎhă‚ÉúMíjÖ?çpșŠ6?s€\ŽO"Ž?OMŃôűÙ9YæĐ{Z$Wł[Œ}îśsœ>3~BŃśŹĆQ“?9rŻ«e…öčśÏqĘëŸPtáÆ6JŸ?”ʐ«'J[2€·ßBŃJH‰ŸȚ±%P“ éńŠVBRüt›úô+©č,ù<šS3őùÙP”* ńÓ{„LÍ[GMOrü„ą”?;oJ)'Ô$Cjü„ąŐvę3Ô€BFûm(J†ÄëŸ1 &ÒÛoŁ@Q:Ź?—žšïĘ\Xaú•ă'Ę>=âgK ~6Î?ÛçŸÍűÙˆŸÍűÙˆŸÍűÙˆŸÍűč=gŒĘK\3qœÄÏœXKŃŒűéj8ë_ürÄURK—Ș9?ĄhÛ+š?‡“Fc\țŽÈ*ŻVYé{-üz$ščÉőO(š—~kEłâçxW”Ł'JÛRMQę‘ćŒ7.Ö§‡•˜žŒ©Ç|ćxnü„ą™lźhNüœŹȚP3ÄNš:üéj*”i»6d€”ÓÙńŠfČ”ą3â'łć„š!žšątTÒŰziyԔéűČÒń“AŃT6WtNüŽä,Łæù™ëw«Ńžź qôï©IŠŽ*GȘșW3Èìű EÙZќű©YS\ÍsĄdƒjšr_ÔG•fim(?Ąh.›+š?u őÏeÔśt>æ‰șĐŠû*7ĂÒs±ÆĆžTN˄lڟ‚jŚÛds€l7ÍúŁŐàÌlu‘?Ąh&›+:3~–WSŠ%JŚs«ô”JbŁt>żsűNJKèȄŸP”(óâ§>QŹ·àčq¶ręsĐtJO[i>qźÊfsęl\mËeIü„ą$Ó§ÇOăqtŹôhRR©Đ;„ŠŁKŸYm=”ÆùΕ  ÆÏ7țæÇ~ ŠÖHrü4Ő\ćlE«ĘŰÓźœŁšȘ =ż`æÇÓ#?żôȚÏxŸÏË?ô/P”"ÙńÓ.k‹”ö1łŐ@¶#ő]Šs5{hI`Zc‰ŒŸï{Ę[ƒț„ą”IŸĂM`_q5›$áűùăżó€û|^(JŸäűÙ;o_šIˆ`ü|χ}ÏφąôI‹ŸöŠÔ€B8~~á'mBŃ*ȈŸĄMl©æčűpș'$1‚ńÓw}ŠÖ@òùgššÚCpűÜȚ·zÇÏț„ą{Ÿ§·ßAmh’HżûaqôÌ Čâg(:ÉVŠbüĄ 8îÌ\_ÍŒűŠN±•ąˆŸ :đšœæùŐ»~1ˆŸÛ°ąˆŸë# S«W‘ŃûšˆŸ±™ą™ăśájÙÌȚŒFŻù{Æ ‹ÉŽŸPtÛ)š;~Ÿš9ƙ.šŃkțÌê]żŒüű E籕ąYę?ûžPsŠ3vÏPŃW*ąhfü„ąsÙLŃ•ÆżŐ[ĐÚ@KéÏôáEŻyŁ7Ÿ#æŒęϊŸPtVúmÍżoPŁ„Ò%śüŠ’'#~jŁ„– ,';~BQêdĆO­?/Ô€Hvü„ąÔ™?Ą&QfÇO(J•œö[Qê_ &ErÛoĄ(yÒă§6Ű8Ô$Inü„ąä™?íÏP“ ÁűùZöæ_ą52'~šxZ$•ôóă'ƒą4Ó§ÇOSÌÒŁ„‚äBŃ HŽŸĄ“šč˜ű#8ÒɌŸPt5J):kü[ÜmRőޜÀœš;8E:śé:łâ'-FyEóâ§w@Fš9ûqtȚćȚÙòż±ÎŒű E‹RZQŒ»'ƒ șšêŠkőŹ:mŸžŒKyf,ϊŸPŽ<ĆÍ?Ț Ԝ˹ÚđIt$ô?č5€Šő+¶węț„ąĆ)­(ÆÚĄ‰Q%Òæ„{Z* …­ßŸa è\Š+șȚűCžZ6čŠRËTsš}ę*AÍ{I'+…ü E'W)­(éűioœ>8ă%§n‡ –šá^űN©j֞˜ë1?œÏÿ EçR\Q:㶠㔛z]™ ©ëßU8äɊl7ĐZôi[MȚM_”Ƈì)ă§śùŸA èLŠ+J*~N©’· ȘźÁDa{ŚÿüÏ PtwäàŚdâ'O" ʱ¶3>ęCMë7‚ÄŽœß<ÈW3ŸAčá„§TD8‹¶wœÏÿ Ewç,dÏĘăgÿȘڃìZœÜžŻÿƖ·H0~úžÿŠÒ!9~vFČ5z#„©é.‘óÖÚ2 _ÖTiË ÇOśùŸ ŠÖ@jüŽ/fkÓ[—¶ę‹WMsù„šM’sęŠVAZüôŒ3.g9jÎ-ÈìZ‹W]S=S‰ÌZÏŒÚĐRĆwHŸsęŠfłGúÄű™„æŒÌđRČ?ççă ŁYAk'àïĄùN:5}uh­$ȈŸPŽ’â§ś1b&îŁBFü„ąu?Ąf€ÇO(Z ˆŸí€űÙˆŸûÁoêò,ôâ•ë‹{ÀÆȘŚ>â矔WńsGB=ŽBœŒœ ‡ăÿpüZ8Ąèê”VńsOT·ę)u#Ț»š„zLïQ“¶‡ï3ög èúWtœű‰Ț‚“«ž%'Szûô5e`šáűYğPtr•ÒŠ"~î ïŽdwę Ś†Źő”ӗ‰ț+ß`ìA(ș>ĆĆùçŽℚi­?Ș©ŽŸđç6”Vô$ă'™Ź ŐŽ–kÚs¶ą-?“yO<~’ÉZqEŚžÿv Ô!Ónž6șș·„ÄÍdÌŒ›l”Ź-Eie¶ź«%Ö(oîúٜąV”?ĄèW”Đę·!ì» ùíÒcżm/ą—ż›ÚY~ Ûo)ùŠæ?7éäG©Çtčl”Är[̓ܐy+”úŰΜŐ9ńŠVAbüd[ôæőŁ—ą3ÔŽ—«ŹTŸĂV ćôóÏ(Z‰ń3ÂÊO‹ä›Rj2±mC[Mùq\|uû8éjŠs čAïț—æłôgìĄÂÖïÏ P4šÿÍÒ_Ÿ…%%0ZȘ±!œŽ=€šé,ÿy¶ŰçŸ1 (։ŸćՔ”–áiȘ0gč!—\ȚŸèzŚȘšÈùçƒoțPŽBÒÏ?ƒŹȚ„ŻWÎèÇjXFUÍі „Ç©+cžÆVÚÂçŸ2(Z%äă'H&?Ï/ h…Ÿ ƒHüœębČz.ę9î>ăúg(J&}Ąűž””=!5OŁž ÆÏ§»Ek€PütÄ#„æ©j)ăgżŠVH©óOfCHÍSŃČìù'ƒą(vți±š§-fáóO (șĆÎ?m æăçÍ'áÏ:™?Eß$šI†Hü|ôÉiBQzLÇÏĐŐlŠjžv[BìüSś'­ˆÉűÙw ôT3Ž‘ÁVZd%ŐŹđjYbü„ąó yęStEâí™PvPčŠÒötŠÛÄű EëaúüS#Ő«§JȚŠÔ<9Ăńóæ”LPŽBÚoőaȚŽASćl:j–»ŹRŻBŃzȈŸL+b”čšy"rŠ^ÿ„ąŐ?ćłŻŽ™P“ 3â'„MVüTÉȘùÔ _2›?Ą(mâ§Öœà“ŽšѩՆöTóTǔʉŸPŽ âgLšô/Çńù‘ăÌÔÿ[ù0óäjR!ӟP”>9ńÓq\K5i?Ą(uæÔo­~IP“ łë·P”*ƒ€Œą3^úJń'ő§éœ( ü Ei2JȘ†űOđ§Ę0Oæi‘'Ÿ>TŰNùŠ’MϋÜN=í·Ő*lŃ~[-ąJ€n†?«%TŰÂŸŐ‚ëŸ *láÏj?ś'4üÙaȚbŸ€?kțlˆHü|Œ= E+äâҚÖK‚?ŸMÚ„ÂÁ™łÌŸÚöűÜȚ·z¶š?ßÁâż2Ú"ȚAš&ž<Îș+w‹ŒÎæÜ\éă› Ž­ŠPaÛû“ŸŸĂ’ćö™Ó>±ńßltÇóëo{tșÔÚsœĆKìéì}Àœó„1țJÛTH¶w·>Á„?­*đ™Ó7;GÓ&íÙûóâČ·›1Śc-^&©ł7ö›Æs|0”¶‰Đ.l”ë+œ?UŻ•Łáż~ț0­+ꎱ>üśçBIsę‰Ò6 څ­ßŸĂmFJ±ńźŁŃŸȘ7ËàO}h…SQ”ž€ „mŽ [Ż?Ç!ü€ą|D?ĄšŒiTT&9EmI;qËä’J eű„m څ­ÇŸb\źšW–žŒË™(qćú7Ù(©êÍÒ€ ¶€Kôg IewżtąŽB»°uüÉBQ5©Śˆ:QËIƟȘŸIA-I”.[HȘö–æO”¶Đ.lmŠ\ŃNMšg,örvȘțTăKl$©ì ˜âO”¶“Đ.lËúSč⟈&„.)Ci›í¶lęöęIźJT̟§Ą&í¶lûĐšèAÜ|ÒšąÄ›ŠŐoOПä ÛąŚW˜t€QA©7Ék:Ò–va{užùd±ûüNŽĂęC(m ]Ű^Ÿńè“„îïc§Ą(qIKƟÀNCMڅíuüdO–ș?ž†ąÄ%-u; 5i¶züŽnĄÏfۃ’ŽUA{I/»stșÔ:sÌĆË$uöæô+|<ƒ?ƒì?‹}eàe‘€Ąg>êțDi›í¶Ÿìr#ę;Ą‡=EnżČdÿleŁÂö*s|́ŸöœìہžÔę‰Ò¶nxa[ΟŃêÀ:<áÉń gȟ(mëær©?}ä Ûą=ó Ù`ç%ęyÂƉl<±4~vFY4ÈoËùC6T6–ű“BùB€˜#‘sűłčl,đ'‰ü9Œ$ČQÀŸęĘ&òożC‰lˆlÀŸíd#äOëqöśȘ—æOùo?cőŹì› ™•úü9QŸ8?„a†ÿçMN(æôNqŸ žË—‘œUłôçŃŰ<ü™• jț,WÚôg0ÿ~5EŸ8Ï%BŠ-.Ï% Š7–?ËeEˆi?_ûsìeÄŽ\òÎ C†àÏ@6ÈùsQi;țÎÆ›æÇźgj†úIˆ…¶ž¶źXC$?ŻqeUz\Œšö§Ü‡ìÙÊŒË;=+č‡qڟêÛtÆ·(˜• ?™qà™êá Ngƒš?當jû“ț6üBBKĆ΍tü„ÿjû·PüM`îCl”1ßrvŽ6ŸuțŒeŁ|V”?ć淚ąƒKćŸD‘yäShą™Pęvfi+}äú“Y^ șWšš3čbȚŽ?Ő~ăŠ0wž{3üč^Vâő[íê"˜țÔ7·Ł1 ‘Püœ[ڊzšđžüÄżŁÏŸâŁÖŐ&™YÙs™îO_ÌúĆ3æ$mččŚEțŒeĂòžń-JeeҟČÄŐśÀś’ÌFПłKÛζ#c֌?ŐșæoSÿ±j;•țtłá5FÀŸÆ^—ű31ÚN g%Ł}ˆ©r ț€œˆ?甶OÈ7á1Ë1Vi {ÔXÙ_żőfĂu„ż pW›Ń’š• ûüłXVBțLț$™€ö!–^ÚÆÚoZ}©đžŹ w*MBû­› íGÏęiÀNòŃÜ`ÚaLË“ÛŚÚoËe%Ô>”üI2žšl ~¶— űłl,ö'{ü‰t5 “ űłl,ś§3sc 2è_ÖN6ÊûóŒhțÒđäű„łQŽöés$ČáóçíäÔƒ"—ęyÂƍlžțÌńméà` ąŽ­šKǟí%°Œî“3ÇŚDiKڟ{T&@1nßŃę‰Ò¶nxakű՜šč4ę‰Ò¶fda ¶‚íOšY1BÌ»êùŸœą;Œ7 JđÄüÙʟòùeƒ?ïì10‡ăčϟ(mëD+lûóÏG/5âYôq"cđ'JÛŃƄ?+äÂjûč}'äOšIžxaëÔoĄ(}.Œ“…?«$^ŰÚíCPŽàφˆ‹i]ÿTŠžĘëÿ§ŃŻÈÿÌ4±)sŠowgăÛœqA,”™(5ÛŐ6Dœț”KĆöƒ©ĘŹ4MŸ? š‰ÒÖO¶?Çc2b©Őp˜Ä’3ë Šj«ÊŁk&”;æÈYæb”eÓt*G*—æ ű“€?™OMoj7+-“ëO%úń›잊ƒx˙•NŹŠžŸÒ53}gśŒ9vÆÌd­ Ș$ęücțDiKœ9ő[?™m Ț?هޅf!ê5ŠéOÏæuŐ'#ÍéúłÇEü‰Ò–:ńÂÖ_żešˆgc)xÏ>˜:ź?ćFÆćr*ÁŸŒ©"ŚUT|Ösi$k^P!iŚDšßąŽ„LŒ°šß*g9GΠɕ§š±]«šcür<ɚ”KڍŸ{Q'ê·(m)/l_ŸäÏ@ÙŠHó§]#2ëVáŚÜŁ”m;í‹9’Ń>„Ò–:ńÂÖő§8»ż§$bÌm ¶gF]Qى@N™MgC[;_eœI™¶]MVm§2—2)OÖŸąKę‰Ò–q1ßșț)8‘ŁT9ŚWPÚ'.æë7Żg…ęÙțń©ùśANrÄĆüùűęńГ"łę 9é1UżĆęńŐqawŒNô'ìIűł9ÎÜ_-ńÂvČ}Đ#}üšIžxa»©?yjƍŸ?Ą!Ⅽǟ0fû(f,ŸìúM}r’ K­­\ïgŰŃ#Oi«>bïÛ·ĘxNRV­ę??È[/l]*C€áűÓYä™`š-ßo%ÿvă9ńnŠ)rü‰Ò–8™ś'Œéú0Ž7śŽ>Ă>æăŃ{dHöë«O|%ț;‘©‚Òóz±ÜŃSÎvőä"™Ú°™í†Éđ'J[êÄĆü…@üԍiÌ`v š)ÊĚò“Š”PĐMö”!…¶#w»*9{jt€–Cfd»aÒę‰Ò–<óüÙăő§sŒb+Kń5șÉŽŰ#ŽĆœíêł} ü‰Ò¶&fú“ŸOŒ‡»˜?'JÜ)Éœ?=6d»mEçŐoQÚÒdQęvĄ?ŚXßLænĆ;Çö”WʶáO”¶dYæOùą‰”áOk©ăSs7)%n۟'S#š]żEiKž˜oÔoŸ’ÇZÌvËÌáiÚ;òËâWk0Zä”WłQÀŰź§Ä ”(Ž,êląŽ„G\ÌżyÿPÛÇȘfŐoQÚÒ$.æeæęń šz(vÿÔܟž˜ßË|>%üÙSńÏŹűł!âb> ֍ûăAâbŸÏÿŹűł!Šâ'ÆOšűł!âb^`ü„ú€?bČęțŹ űł!âbŸțŹűł!âbŸțŹűł!àÏæ€?".æđg}ÀŸ öĄæ€?".æż?ëțlˆž˜_‚?ëțlˆž˜ß‡?ëțlˆž˜Ÿƒ?ëțlŽ5üÙđgsÀŸ óYűł>àφ@ûmsÀŸ úmsÀŸ űÙđgCÄĆüđg}ÀŸ țŸÍ6ú—5üÙˆŸÍ6âgsÀŸ 6üÙšß6üÙˆŸÍ6D\Ì ÖüÙšß6üÙq1ÿ.üYđgCÄĆ|üYđgC ~ÛđgCÄĆü{đg}ÀŸ úmsÀŸ űÙđgC ę¶9àφˆ‹ùËđg}ÀŸ ó.üYđgCÀŸÍ6üÙđgCÀŸÍ6üÙđgCÀŸÍqqì?ëțlŽƒ3țŹ–xa Vȅ=ك?«%^ŰŸrqnNßFę¶^â…-üY!hjˆxa VüÙhjűł!àÏæ€?țlűł!àÏæ€?țlŽAÒnü|dđgŐÀŸÍ1J:Ž·'üY3ńÂțŹ^ävܞđgÍÄ [űłBD•ší ÖLŒ°…?+íC /láÏ ?íCÍ6üÙđgCLùóûüY?Ą!?›ă'4ÆOh§K/cđg­`ü„æ€?".fïÏǞVŠȚÜ>ƒ đg­LùÓh:wWUàő'JÛ* ŚoAœžțDi[)đgƒžțŐ6üÙRLűłàφÄÏÎżöQŸœŐŽł–hYšÈr3<Ą;§À9âAtL‚?›!äÏűV6~PÌ/üćăŹ%úTbȚ+çhŒć6GŃő'JÛőYč°uüék’?·üù˜gwđçi\­»ŰΟ(mŚfí–š?í{tKŠšù!Ï:ŻAi›ÆÚbŸ›sBțl_ÍŐƄ?·&AÒțÄńè™/ÁЁ?wdęűyóIűsSŠ%\èł"üI” ÛëúíŁOúę©’çúS͓čŠvÆ=k'ĄhȘ?‡ĂĄêŽĘpÄź_áObŹ]Ű^ÇOVܟlű=ujÀ@s rĂ'©hZ‘;˜n0ç0ŐĆ'‡4†Őœò'JÛk¶áűÙ©ôđgI’NYÆ#ÈęiŒ9ŹíOšaíÂ6?Wó§ú„œ€ą©M ƒ‚Œ±2țŒš .`í¶ŸìÒŁšŸțì ՈàOm*vʏižžšk¶ÁëŸ ę EƒäùÓx›}țS3ÁŸ=(m}Ź]ۆęÙżŹáO-W'©hN“ŒhRàóÛoú„mˆ” ÛџżuÿzÖëŠvGő eœKڟzè>{óúłYß§źæÚ…íèÏgźç<nÊț|őóìțÛXfi .`í–ûóyÆîëŠrŻó2·äę v3ĆI*șŸ?3K[űsk‹đ§Ivütv‰;Nëû3ŻŽ]rÂɗ¶đgslïO“ìűéì jJàÏæ€?țlűł!ֶ磌= nüÙ[ûÓ@MEo{Śéu›±DËÚ©<À”Ôdr€?śc}~…±WHESŒ ǎł–(NçiÆíć¶ô'JÛŐY谝áO@ڟ) Ž]Èș…íĘç{ üÙóü H6üÙđgsÀŸ áóç© Éß*đg;xüù¶œóbű„mŐ8țdś­5^Ű#[ ƒł${őXÌąŽm͟ܠ?d,ț/ï’-ÎïYӃ/żń JÛ ¶ęęCă Dśÿê6ùłùżŐȚö4»…Ò¶BŒ…-îï»6è§ŰCÖrű“<Ž?‡áMCi[!ȚÂö.ëïșæìSöÒż°~žÀ"^bWb߯5_Ò¶>|…í]&üÙ;ԎÒ„mmx Ûk{ČĂ'śÈ X™w읰”»Ăkû]€ŒÍe~{ÿŁÈVÖàgî.ȚÄÿșÊ[Đ endstream endobj 24 0 obj << /Filter[/FlateDecode] /Length 176 >> stream xÚœPÁ ‚@ŒśsÔĂźûÖĘÍí(ŠT§hĄCtł“ŹțżTB‚.u™a†yï ‚ e= @-ßș àÛџ„Ï©Ž66„ƒąšM0čTÈ+łŠÔX~v vAȘ`č5p;1\0M–Á%/=”·ŠđY†M|Š”ò\¶Ž{g•7Eqșì뫿usLĘß~;HižŐ`cœTŚVŸÔxnĘ8{i endstream endobj 25 0 obj << /F4 11 0 R >> endobj 26 0 obj << /Im1 21 0 R >> endobj 20 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 25 0 R /XObject 26 0 R >> endobj 29 0 obj << /Type/Encoding /Differences[0/minus/periodcentered/multiply/asteriskmath/divide/diamondmath/plusminus/minusplus/circleplus/circleminus/circlemultiply/circledivide/circledot/circlecopyrt/openbullet/bullet/equivasymptotic/equivalence/reflexsubset/reflexsuperset/lessequal/greaterequal/precedesequal/followsequal/similar/approxequal/propersubset/propersuperset/lessmuch/greatermuch/precedes/follows/arrowleft/arrowright/arrowup/arrowdown/arrowboth/arrownortheast/arrowsoutheast/similarequal/arrowdblleft/arrowdblright/arrowdblup/arrowdbldown/arrowdblboth/arrownorthwest/arrowsouthwest/proportional/prime/infinity/element/owner/triangle/triangleinv/negationslash/mapsto/universal/existential/logicalnot/emptyset/Rfractur/Ifractur/latticetop/perpendicular/aleph/A/B/C/D/E/F/G/H/I/J/K/L/M/N/O/P/Q/R/S/T/U/V/W/X/Y/Z/union/intersection/unionmulti/logicaland/logicalor/turnstileleft/turnstileright/floorleft/floorright/ceilingleft/ceilingright/braceleft/braceright/angbracketleft/angbracketright/bar/bardbl/arrowbothv/arrowdblbothv/backslash/wreathproduct/radical/coproduct/nabla/integral/unionsq/intersectionsq/subsetsqequal/supersetsqequal/section/dagger/daggerdbl/paragraph/club/diamond/heart/spade/arrowleft 161/minus/periodcentered/multiply/asteriskmath/divide/diamondmath/plusminus/minusplus/circleplus/circleminus 173/circlemultiply/circledivide/circledot/circlecopyrt/openbullet/bullet/equivasymptotic/equivalence/reflexsubset/reflexsuperset/lessequal/greaterequal/precedesequal/followsequal/similar/approxequal/propersubset/propersuperset/lessmuch/greatermuch/precedes/follows/arrowleft/spade] >> endobj 32 0 obj << /Encoding 29 0 R /Type/Font /Subtype/Type1 /Name/F8 /FontDescriptor 31 0 R /BaseFont/ILEQQA+CMSY10 /FirstChar 33 /LastChar 196 /Widths[1000 500 500 1000 1000 1000 777.8 1000 1000 611.1 611.1 1000 1000 1000 777.8 275 1000 666.7 666.7 888.9 888.9 0 0 555.6 555.6 666.7 500 722.2 722.2 777.8 777.8 611.1 798.5 656.8 526.5 771.4 527.8 718.7 594.9 844.5 544.5 677.8 762 689.7 1200.9 820.5 796.1 695.6 816.7 847.5 605.6 544.6 625.8 612.8 987.8 713.3 668.3 724.7 666.7 666.7 666.7 666.7 666.7 611.1 611.1 444.4 444.4 444.4 444.4 500 500 388.9 388.9 277.8 500 500 611.1 500 277.8 833.3 750 833.3 416.7 666.7 666.7 777.8 777.8 444.4 444.4 444.4 611.1 777.8 777.8 777.8 777.8 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 777.8 277.8 777.8 500 777.8 500 777.8 777.8 777.8 777.8 0 0 777.8 777.8 777.8 1000 500 500 777.8 777.8 777.8 777.8 777.8 777.8 777.8 777.8 777.8 777.8 777.8 777.8 1000 1000 777.8 777.8 1000 777.8] >> endobj 33 0 obj << /Filter[/FlateDecode] /Length 2617 >> stream xÚ”Ûvܶńœ_±GOÜc/Cà-oȘS§jìT'VӇȘÔ.€e”\Ș$%Uçäă;/›FȘcà`0˜Ì»ŠÂ(ZĘ­hűž‡áżÿ»_„ț°Z-lu_Œúæc¶*Â"]]Ęź€ čÚš4ÌăŐŐwÿ~‰Ś›D$ą_֛8ÉTđáPvĂ>đpŸÛ”a2VEÀx°Ża„iÃ2Ibÿ­ÿyő—ŐŸźțŸ–č$ł”˜{·áż'țŒ{Ę, 31ąûî«ĐÍE˜fKÊôuÎ>ÿíÓŐƇó/W…’"­â…PK •ĆÛZš0ę=Ł4LČ áw_ƒpœ‡‰ű•Ò Hł"…ïŸt§Û'œăLA‡Ö8…Š]*§K•œ]—±ŒBőÿȌțšŠț'*”9QœÚk”BőZdÁ㥯¶eŚ#H%[ŒîŁëËÖŹŠ,aŠa0 °€ ń(O=%!fJ‚ą%žŠÙ(ŸP‘#ètæ`Q1"x~8°ŒLȘ "»ŽŸ“Oç?žPŸ=Ï”X”Ł&0eŠŰW `ŠtŠ‘…©)EœPŠ#èŽä$–ǝR €ôș}œZ쉟°â”°j„É€L%Ădd+€™Îmz1¶uB-Ž §'`ž"Ë>AŁé«Eߥßțüù§Kț|…–,Ÿìé)Ùł&0!ś#ăÌbn<@GŽ'9Ą%GĐS›G°#jË*úë—ˏŸvÔoю=ۗčX–9 ă&0ÓïŽm•sJĄ°ÛPzB;Ž Sڈ`š…2\v­AA;ĘUwÇȧ:7'ő+ łŒűj§Ô F˜ XÀÌ#ŽÈzŽ5őÌI°dYÍ)–'4æ(z*ô(‚ŚA…àSt&ćlæòâ3ëbddŻp<˃/zJț|„ÉÆ|Eą%°5[md}XÁ5)æçòæ Ù$âoŚ„’àłWÆÉYq&ęâìÍĆÒB ,„iáËPBV\nB°NҀ‹Ă8žm›šŚœź ?û†\F‚6€ét<¶ÔP MźcłEŒć3DđđŰČ܍)BEp=C*w5Đ]ßBńÈTO”Đ}ÙĘwŚkŰ­šśĂOƱÓÚLšÆYskPöÀ/OKÛUâLjčśŰ,AÄÓ·șSîùnqŠ=ƒŠ“àKUW‡Č=ŒàŐÓNÁ‹HŸ¶Ò¶PÊhŚ1±¶—Jj:5łž€Š.@$`:‡źaÈű*pămÓò҂Zi3i‘§n{ȚB­BŽz j*Û D€șłœïÌ!mäÁ—†TP èæĄű©bźôӎ€+Ô%śôqCÖa„iClQ 'ÒGĘ2™ył6éEL\11Ú=@„HœŃcÀi XæŸȚC蛏©ëIY4ۛ›ÜB•5>ûű.†ń=vnŒèi­nrÛҞc?9—"“Üùń*±#4\Îdw œ€€—ÌFMvșç ú޶0ÎLcÉĂPáèç5RmïűŒŻ¶Ę3ĘnÏí&ŹìÊȚl|ȘÊÖÉU§&ĄJfV(%ó€AčŚ_GRĄ\ˆhïç%#Ö(ê #Za‡K̒<űû(ȘفbóŹÓÇ]7Z{(IÄ{r C­€FTäüȉqłÇđ]œĄ'I%‰)}3„”ü«"hŹó†yIÉ2NÌ}Âdj€d­Š”&6ŃqÒR)ú„,Lü‡uÇźźșźąf=æĐˆc9e5GV—â’u4G“šQ„,©4îă}°ùЊJœ1š2NYnўU·Ÿ;č$Țđ”êxwđNäYcÒiKNŽCŒ=g^ü ’Í.ĐČÓ3d&‡Háj‘A`i, g‡Őj?Űàˊ”•ÏȘidź°móPiCî‰ˆ[šcȚ›xgŸqÉŒìŰ>è,Ę'ò€ ^uk‚íŃ+Xˆ–IPfŚÆŹ,ÇŸŸą"ßš[ăjŰSöâ<űWƒĄ1ËăŽMô )òÛô„Xœ%7±yDwÁŁ)țÜœËbÁˆő5D ƒ$hÇç,âœ9Qu Łč`yàà(MêòžŐӜ8€D.\ÿl“‰”­ Ż*È “ÂĐVZ­yșĂä!Á^đ ÙȆgĂ|Ä 4/ÄYnSh>Jæ€A7ŸáÍc’âÚoșˆ(Œ”;|^ /Öç]óŚê?V­ź «­†Ž |”ÖęÛ^Pńù<žÏ“0NđŁ_(•kĄÄ釶႕óbŽÓĘêz“DyMŻPĆaȊ\8UJXG–ÁÆAœtŹĆ_æBĆ*N..y“Ó:šóŒ—Ü%ąg"űÔôæŒNÄ0Ć N9Č(Ż3G( 9šÄźwGÖΔ©UnȚŚ•±5UŰ łź‡ÎžŒ\räŰ4A#mÎÒ)ƒÌ/îž Ű-ûŠ}áöš‹Ë'Ćłë r{͉ûÆ/P »K+Ôæ‘g»|JŻŚűóÄžù„?ç&ă/æĘŐ{țÏĂĄ<’3 w~ù5`ŽùzĘÄ«. #CáÔUxNÈŽÙŁ‰V…9“?LBDpÓúb°ùy©…œeć4Ό© ź·"1-vuéÉ;”6 ”Àžśh ÓLqÊi"üzΛ‚+Jőçővz΋?]ĆS煖§đœW ăœRšàlbÇÂx-NđÖű—/@€.ĄlȚB™[3ó·»=ŽŰUÜ”eʝń7ÙLÊ>)ûjϗśžĘ—ö«™Š§î;5M%ÎȘȚôăss‹ÓÜŸ˜ \žĐ+&üâŠ)@üm.1á‡}*–Ù°qædôŸMóšđóČ„n_æN|«ŸĘ“Qć5”„5àĄ˜[xA#cŸÌNż{Ž”±«ÙË{çYźì>ûäč-vt6ź{Ő #Țp5_ČçœœŐ VBđóaGaÌ, ÿÿHÚ?| endstream endobj 34 0 obj << /F7 14 0 R /F4 11 0 R /F6 13 0 R /F8 32 0 R >> endobj 28 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 34 0 R >> endobj 38 0 obj << /Filter[/FlateDecode] /Length 2378 >> stream xÚ­X[sÛ:~ß_á9OòÌZ•H]ęČÓËiOöÄmŠuŠ;Óô‘h›'Č€Ő%‰śŚ/.”­Èéd§Ę‡D$‚ |<ó\ϛmgôùÀŸÓ?ÿĘ=Kęs6û…­oÖŻȚ'łÔMŁÙz3“Ąë‡łEč‰?[żûæÜˆ@ÌżŻÿ9û}=97FǍp“tŒńRßÏ„ïèbŸŒÀ!!ŻȚ§“R7ŒfńšvŸĄït;áü¶é‹‚‡m_Śó…HœȘé˜Č©\\ńw?±ÓÉTۙrûK+@XЅ;_„žGќ—oȚUmŚŽćŽŻßÒ©V!u[ŰQWń——«nGÖYđuŸïŠ!Ę©ŐeW`/€ÓèLÖ >gRŚšOFèÇÂYïô„œ”C¶»ČœvÓN3ÓŐ;ەŠț«2ćm˜G!śęœoiő9’îćń•"șÒ¶©úmŹ$FÚdà9uSŐj«:mÉ;c9M ¶W©ÊńŽéi$ètÓÂćƒ(†ËóÿŽ‹oyï6™2+ú\zőæ§ž(‘—·Há|À›à0pVȘT[œŚÌĂËWM…J‚aČ œEJçÆčű°șș™óÌì낶DN7\ 6š’ŚAUÓđpęöê9*œŐv*Ăcî\vž3ć˜Yïì-Vcłçł.Œő@XŒ4·jŹ)űĆ[¶D>xx…!ûFYU¶&Ś ÄÆ`JŐ ï€™4ÄÚ°ŃĂÓńZ1Š8F0”Ú„Ă /ŰîźçMżWeŠ]ŽęX,˜M„ˆÈ&\ß æ°/ôœ/ՏO$†ŰT—"" ć€H§Âw5öÓ1°XW&$ÛʓCȎćI+ȚfêÀ_!‰ăĂ>f_—„5 êF·ÖÈâ’T燠(ęæ'ߗOPôGç™ô\?Æ 7f7ńĘ!òĂ#æOugöæ?š˜€·ë[ÍŒ7~Ép€Á:?Ì kï€(Sg1a2öšEa¶Ç2yIn4‘ «ú&Ó-󚣄+“·Ìҗ%àeÛą«Ÿ…tŁëž‚#/c:6'WűHü€#H ÀT˜òźe>z<€Y§è:|c$ÀMrژÂFÀ‰íŽéŠ7ڗűQĆôÎt:ëz=Ńç\ęÜŽ]cn{ÔßęEÇ"rCiĂè%Ç1żt Ÿ…üšê‘M‘`SolS/PüaЀÁ$hD 6ÓlŽČ*Șíi” €=7»âÀłMEÂ348S†ƒó‘jgYh€&%Š d,ŰëÜ(™#ŽîÂÜÙŒ‹ò˜ìšVMÉЈ{KÂś€˜s ÂéF—Ù‘kO{8;æĐłg¶7ÄqJ ,ò,ÚNé#À$FܚJó$7S<Àà/{Oìč’ +_öžó—LêÖŠł†iHh‘FPú4ś†cfœkpăIʃ[3Œ3źÙűâ‰Ê»h ¶ÙŁ ±ŒŠä…e‚gNQ#~”T[=JępțV{MÎlolvP֗V>úÚŻÚ]zˆÁ‹v1żžûŸP ŁÌӐ1ŁŻŒ‡ŽäčŸŚ}‘gÁ{ÀË·ș”ásc—śaąLŒÁÙ3EŻIGTÌ?`2ù<Ì úIgön^„rŒŽ#­tZˆ¶B3 ‘›GTÇÂŚ‚șœæ‚nŰ\ ‚ő ”RLŽíÆur(-\ÿX*ĆŰn€Ê3Ś‚bŽŃ \Ö=áÌźmŽć^ì&‰…k5·U‰5ɶoűCH€9Őq%_9—Œ_*vÖ\v§Đ7ÒČ(˜<j§RžWŐń@?օ2v}2%o˜š”Zƒoź;°"Âo$„óuž‚Vô—ćéT%ĐRšđ‡ï› ˆwűđRTŸÔÎÔlŃĆŽŒ,”ÎÉ­đE+ț¶TÌĂ3P%ß[՚ÌČÚšžHőWaë{Uđü )C<ÉŃÀKJL`Cٓ ·ŒÏŰïŸąâFY…œÎ#O[Ÿ} “YäàMCœ;w¶^¶]OL·ł9uZËi©q(żŽÁ©”íœ:Hö€Iđ¶g È©ÿ8Fąëc,©óźâ¶ĂöüągâäQ°“ƒ?~«À΁Ôț­ÔŽÛ–LCyqŠćtÜž@ę4‰E„ŹŚ»|Œ,ż*ț:# „ăÁŽĐœœ7 ę˜àÙ€,Ș(=ęÈŠ4}&,PŐä-';RàIQ4ń]b7‹iZ0*qúu„€ŠĆ%lux‰łȘ˜8ĘŰ6ÀiuÄő=‡zȚÚRTßU—ęXŒ"‰ĐÜ·À`u}‰ž¶ŸxûúËúy݇G ŐùXÀ$óáăő«K4à(" N±‚K\śÀ6ꚱxNœ;^{Űi\·»^:oÖBgü=B7…”­ my0-č’Ip=śL·6ARtQęSÛX …,zxQPŁüp,Ž2 <Ëźă=ÿ‘1Ćncˆ„:ć đ8vcŽłÁÚÜÀÁ!„éB•LĘ$àßXP¶¶ŠU ,€IuoaG?*œéÛÿÿl©ësOîˊĐM™zIőȚșU/GÇ ŸłöÇW•ç =ozË7ï—^ŽLÒe?WŁ qÛÒOüąÄő±Aêô‘19 ya„Ú»%ÌÜáÏ;oÏźŻŹÏŸ^żŁĐĄéçë/>~@x‰1ŽlXÚŹÖŚK?ô<äÎJCï—-ęsœ?ÿ‹eŐ*»Ó]»ôE “0‘Ö0MS5íÒăYȚTu­ó„ZĘĂr_—7Úë„w~ÆzrF€ ”Ì?q PctóÜ!ž”Ád}dîÿĘë^ș\úžśă«ß: šĂÄîŸq|<Èbu{3?—ő »ĆBb Œ0yNBê‘ę”Ă ÖàöŰ7 “ÌàGĐš-œÇŰ©/Ę  œ@?Ś.c»s,bZ(–<Û9ęíżô‰Ÿ endstream endobj 39 0 obj << /F8 32 0 R /F6 13 0 R /F4 11 0 R /F5 12 0 R /F9 37 0 R >> endobj 36 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 39 0 R >> endobj 42 0 obj << /Filter[/FlateDecode] /Length 2483 >> stream xÚœYm“Û¶țȚ_Ąo„f,†HŒv:c;vêú%GžŠ“Ëtp$qŽ"U‚òćț}ś"EÉqë€ęr°‹°û샅n…Q4ÛÎèó†?1țčż:úz6;ŸúlùÍËb–…E6[nf‰ ób¶HL˜Çłć·?oÊú~ŸHužze7oš•­xàMÓîìê~țóòołh¶ˆă°HiRY»ŽuìzĘȚÄ* a”0æ±·Ößßš4„±h<ÛĐìïĆțśßżöôùkî}űűîĘ«w߉‰ćǛŰ$Ú`Wo]Ś–«›űr'~ä ۧëüMźMlŒ‘”mÓú›ˆ{ë¶9ܚ»*h>űXŸÄ›ÖîĘMtčÄòw[beÛ¶tí”EVMU•Ÿlćî—ĘŃUźŸŠßŸûî±sț&ÎudÒŹHeW·Aœ%i˜‹3ïn眅"LÌÙ©țߌLfEq3[š$ )ۑ"ƒïšÎÍ:Š‚n'·ßÌs,_=úĂrŸPEÜF:”[ێš“ŃX'a€aŸhĐu»hș*,—ć"ç‹Dë`č;do°„ç±}éœ[vœH‡©{U3] Ü ÉÂÒÛáX žPy@É1WYpÏG+kìtźĘە»Ëöț1ÏuĐYe?W&8zÚű.‹C„ÆQĘY4ńiÖq­"Z\+ A™ÜŻOîG»¶f†‹àŽBÎLČ(hĘĄkîĘĄâ#«QŒqŹS«Ùđ—E†±iúmàPŽń4Oì<`ÇÖYă‰_LßÛ"ŰÆ± ÓtLè“<ŚI1-)2HQJÇkeăšsGiäXrônsŹž]nđ ìXÎ1žOKGàÇȃ}ôH­©Yd/ĂdB>ûU˜ QRûló+ gżè$Gr)ŃE` ńYđ౟'Ăč”Öòő ĆZ@͝çæŃSČ`srF2ŃÚÚ#Ś•xZTrŸPËŐ,GâèÙșëŠțŁìï”ÏŒ7ȧčÓ:š ź„2ÖŠà|ŰȚc2Oˆ!`DJ ŹĘ/·|ç2ёDP-˜ĂÆń ‚~vÛ;i K„ÓàĂĐĄ§h úRkäȘâ©BEÚgÜs"tzXšupŸ†iÇ:áę<áQëùÛÊőĐqđъFύ0QöŹG;űż‘ĄÊUš9sßRÉqcq*î°ŚpTÎÀűJ;‘%Ń ƒÊđvPżŽAUhČÿœBá\ê’Băt ˜$6c łBAÂ< ĄP…ąlÊhD»’P¶ăáYĄsN[2Kx4 “bÌŁȚՈ°X <âX*†ÒqĐ6'HSa‚§[[ֈ3Ű3ńg<ŸČÁ’mĆ$’ c TˆákY†$CT C{Nû2‘aą)‚Pr Z­ËA&±ŠUՄÔ 7L,]Rƙ[玷}ÆÔpá$Ûck;b@ÊÒöń–B:ÉBŽÙ\9Ζű‹ÁDÛ>òîśPqŽ&śö‡ÌúCj.;ł€žgH!ÄœÙśȘžAŒëùè‚•ܘkVô»æX łÁ-òÀ{ëÍőL‡ç”8éYœ„:b ÙZh:™ž/â Ęź*ćR6&x{^N„3 țŠçX„ûçšÆGd«4xĆilŠür\Qd'ź,ćxS%2:gdä`<˜”ÛŽ_CțŁ\J{ĂśèI•+©YÔmŻÄčʱü4ùă·ïyäĐ6_đŹŁüLƒ§žeÎöTSÎŻ'j$èl]ś™Ëäë€ŻAO…Ü_ÛíXŒi›=·<àˆrÚtςȚš˜±ś8Ï“ÙŁHŻ\™čm*§ J,Áő!|Û59 ŽŹˆŰ?ĐhĘʕŸNđ•]ă;đOZèńĆ;Uh±©†—†é1YŸcû'È«5Čž–óȚR–Á0?Pȋ§‹!Wf«ÏRœLôldûđ”•ožĆ–Ą!À„*ïźŹÊźdč5ŠgYĐÉIÚ⠈ƒÜÚÛ{œBÇ0fޘ€8Cóбn%ŻÉžéčùZe8š&ł^šâÿDбáòD)_SĐX—€—ź"ŽÌ;•ćÔEc J•Iæ±í!󞰐pĄĆ±đăbdlEn'kÛú3Iw8T@/ÈD‹J*ìJHÜ1‰Ûșô{!φIu{Ž­TÎő€4ځ(éÊ—ń8Bú]ÛÎę"śÉÙïSŒ•ćì<•eò„À!ź?0žeUđÇțapü2Ä! >ζ…𓄆Ž‹Œę’RžeSeí;[ݰ8Vy1¶Lü ™Q/€šhoü!MŒˆh†ìmOł Ż©ËzűÊÖ,=œšÉ„0ŚŚôÍEd˜­Ìé2lډ Ök,Ld‹#áՈ1Ąę&O‚‡yż!ʗP8ŚùU[…Ùm{đŹ*ëœóçëžéʝ–œ|I`W+`"ńăà„Ÿ^Ÿúń틟żź|z¶œiš‚ČÙ"5*ŒùÈqxfkT]ő%ŐHùńką4”eWrêcśéÎqșB„‚îŹïuè _© Û=%ŹçÁÛ@RóOPPm) àíÙT#K?EœçŻęíœÇęé’„ŸżÌŽo9ÁŸ­„Ô:ÈÏyH@}ùu7ÂùYțOż5꞊ÛR_À üáìŠN ‡ș“0ÀȂ?ü\ŠČÉeą”ë ßüDS‡èĆeÓÆ»Öhțášá”œć/Q»-țô›Fą?ùŒ#Ÿ(Ç»ł 'œI"vè“?•V,sÿXśżÉ@àW Bސe©$bâ tàzqŸg*â(”Çś‚#(ŒÎÂ<•jûK )żšwHè€e’D˜•9ËTeÒ DPaÁŸ L2aXÔ8AäL!‚C ’őO`±/ _üû‰áBž=‡=€~Pa‘ń=/ٛ[xxŒB†OÄl&Ä<ÆÉWFV)ƒZd1„8ĄSŠW#û‡|iTŻ endstream endobj 43 0 obj << /F9 37 0 R /F4 11 0 R /F6 13 0 R /F3 10 0 R /F5 12 0 R >> endobj 41 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 43 0 R >> endobj 46 0 obj << /Filter[/FlateDecode] /Length 2173 >> stream xÚ”ËrÛ6đȚŻĐ­ÔÔbH|MOi›tÒÌäĐxЇșXą,6éT\ÿ}ś€èÄIۋ»‹}?°ŠÂ(ZĘ­èïgțbüù°žûv”šąțpęâu¶*Ă2[]ïWq±Úè,,âŐőOż*ŒĂxœ‰c]ï«fWuë*TđŠ©ûÚôՎ?_Țßw­ÙźUÖ\ÿòâ”nàšx”‰‹PDóŐÇu’Uśžqôő©Â• ÿȘÜź7ƛ]”­jFތ'Đśp-ì~ Łś€!hc;Ąœm››Héîdúșmxï&x‰È?ŸœY G-ô>Ș Ś­Šàzș‹âźDĘDOŠnÖIôđ èˆĐqpŹmÏ«vÏÿæxä_§“àźkÏśŒ7ӅEČ<űíP5€Űq3Ź­Pg’Ł– ĐÒošœéz>&ٱ}Ë2nF!SČ?˜žÍIœLӈs<à™©é†"!zì4Źu·Ę”'Țg‘`áôPš%=€%°|lÁbp7Y>QrâÀČúûŸî*+LÖûrjH–qĐj‘ƒ,|$!›o{Țt~™ ȍÿŠ—xŒé€+€UrwX‘LÉŰp€#pŸCmù|ȘUŸÎuUߙƞêb”‘EÎ1áp¶@ű'lG€0°ÈüH…wÌŒ“€aQÎË”J‚ĘÇuŠQFXśæź뉱u°«­A5ù\J`Öu΁«"@*)zê©àv&QS85Š‘Ü`Țq'â ę ń’»x)ŒxÉçɉòßEșD/]\1ÔŸCläI`ÏȚ™+ÇPî<3Ś—FÁ&}àȚlŚăMŸ‚źYp&úƒ•"%cQ*"ER!ńÀȘQ…©o”sŽŸLŐšû8 vЧT›-$æ•NæDĆƅK°Ùh X?ԔaćĆŁShÁ€7%Ž`{ʉ§ŠŽwHp€ź„ű;ûzkìÀĄ”`ê«ĆŽțpš·šKŒ|ûdÿ‘?¶æl+)đpzô˜‹˜ÚŒAƞÿț|:(…xĘ«ë/+ăXžÇ RQç@ZćĄâ€Ă YŻàŻt‚QíWcUNÀĘž*'yÊÚ…3mJö±üÙvŒ5Š%90üÇ^«čż#ÖpÔ!QR.ś­»›üv™Ì·g%5– țâ €\ȘI)Âsö(Àw&ûęWZk0QV† s˜|ȚD#°g"„bŚ8l&sŸ /†,ï•@UÒd^ RÒAÁ™ë$”rx)öŠ”’ ÿ}:źWò-T7qœŠJăMM”]ŁD‡„Fۧ&ۧŠQđ+‹ RpLŸ€[WŠ7À ŠșN§±0yőkv. EëI7ĐńÎÁšcï„[±őm}ŻR|ˆ) ĄwUą7wä˞qŽ­…Ź• /Jé Î,ałÎ§Nțìž}Ș,”5IMS/‚ȚwÍŒæ $ɑs\ xSʁĂL(Č$M‹ŽŐîî$ՁÏo‚wžWázҒŒäzȚ«Ćêû±‡5ìMžk©‰kČŽP„ÆJ(R‰(ü]^›ćE …ź–¶Cé`!Ű {NVÎ1ž·ò„‘]VUĐ :ŸÖòÏîCț_ÂCćńŁ+ŸJdȘ–V˜ß)jr(k"œé?á„"Ÿ’ûtűEQ˜ê?Ő­ #@üߌKyV%0óUMՙ#JžžN-ŃÎĆaÉśÖűi7©łƒ#0s5a šŒ ÜdÁK-eąÇ›ìy»­žș ܅\' Ț·ÂâŸz`XÁË]ò”%© lP\Ęræ;äAź<0ßđŁ ASőìXHș’ęŻĘ±ëțÓIś'źÂ,4Ț©‡šez^ęy¶ęŽŹÌ«ÊĐ–Üh'„ [I 6h”8À]–·©ńŁiû; ŒiFÆËńÄđß<¶ńŠÜAÆôaŽJ€Ù©mŽLoàƈăà‡ŸŰń{à˜û3,ù‰©ùjđÓš 3ęÌßö»ÇŽtĘc&ćÓŽX>6üwY"ž°rŽ\ă8â @Nă\:érŻ(Đóń|Òx­Ł&‚áƒw㏠_—Ż[Œ-ž—wȘȚ#ú\žG>XąÍ.ÌLï~ȚŒÎ#È JƒWÍ ŒLŸô3DŽRú3Ókyœ•Ń•łoW˜„'”ę‘z֊H=ò@c°—›±ò@áߛ‘9űYæbŚțQWž/ÌÒ” X~ó©vçŁ<^æ»7ÈtáR#.„,ć1•?8çÊ}đ=șNRžńèP^/._ˆŒæ%<„rÀ )$t‘M^żź8ïœÍÔ ä&ȚcGA–Ú±›Y7|K©Tâ>u©&e§ č$żÙóžá?/`°e{,=awD6ĐM5»aÈ:ą„fmï(ge#èDêEJŸŹUć­ŒĆ-ETŒòăčȏîűî.o\ì\ö¶Œ&CDNÀD§9àâ"aŚ»ÊìM#ś»7ë±AÂŻ[Śâ;CëȚDZKÒöìĄę«3r’dÈĐ&!5sQÍ3ò7ÿM(Œ endstream endobj 47 0 obj << /F6 13 0 R /F4 11 0 R >> endobj 45 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 47 0 R >> endobj 50 0 obj << /Filter[/FlateDecode] /Length 2601 >> stream xÚ­YK“ŁFŸïŻĐEŽ(Šæ6Ïlxgì۰;‡í=ĐRu«vôš¶ęë7_RÇÚsP•YÌ/ŸÚ$q’l7ôű;?柟\ęŽÙ,Yż»}óŃlȘž2›Û‡MZnvÚÄeșčęț_Ń»mŠąĂŚ­ŃQĘâûX?Úa»ËJ|ŃŃÁ 5Òd šßțăÍG=­»ƒĘÒÍ.-㏀„oŰ`ȚœÖW%ńⰊșžn§§Ÿ«ś[eą#Óű™ńXüæäyr§YZRG°CÜç~»ƒwÛ3…ßë§wHńț“0>Ęd·gw:ńr—‘œ°ŽîÈDă±ïΏGŒțFźœ’àÊteŠš”#Č<ăOډ·;­R–ˆ2•hž/„ąLIÆ'_ߞ°œŒ û©„ äu_ß»“Łí~çÍy*:șÇă ^$EÖ^vàKâÛtIühđ$Æ/áćD·ÜÍŚÌéšO5Ií ʒȘ(^HePŠ L–FfęSc\)P0’Č•AâOü**‚·Țî­ûŠÜ–ŚȘęÌÄjŒé$ ŽAèșŠfé-UÊwĘwípnpA`©ńĄAțˆ…L`OPÉro‡Á”<8șÆÆl%fm%*ËŠÖÿćÜ4uÏ{žękfކ=`–ÄiGŚyœ)Z;ËaŁ $¶,K8 ]OÏ·eq…‰śLt°ŁĘ€źY,ÀÁcŰ~ő‹ cĘ3gæĆŠ[ö"»Nš,ù ™f&í?ïgăW qŁ‹unŠXe$‹»šŸÛŸ(;ŁŃ{†ô?ŽÎérZ/°9đH͏ùűHțĐő<Dz턉|ŸÉyA6 ó2țÒû5†™·G/Łw9țș…TMâÓŁ@ńȚ; ˜:AŽ„ùôՖ*AF&.Öêÿ™€82:)$ÈàúÇ€ŒÌpnćM=uzSűZzLô…J<2,f›TǙŠĐŻ4x‚]ŠâŠŁ†ȚÂRI"‰2âg{rőę‰ŸŠèÇÀÍÀägwߌaî.úùÇÏì Ă@’‹4.Őär”Öb—JcŽé’ÊË$’ÂèÁûȚÍÉ!Æ”ŽłYYLFçăâWp\üœŽ;m9 YLȘć\«Óè8E+‚*ă`É:Î ŚSPÉ‹Ìc…?'-l”›”6ÂńiŁŹP°‘âQöŰđÒX†GĘșĄA;+RÎí`nș;ȶV^V@˜ö?“=Ű»ÁĐÉRrùu+«P~[5ć”@Fśč–ÎŚŚ ÁëT»–m0ÈiĆőz]f:ń†•.qïcè>U#S.Ń;đtĘËÆ`‚\ŻËŻ8ç‡éYŒđx§ă,ęćtÓú•Ê tšDĂ$uˆWĆaŚ<lc©RëQŹ”bk…y!„*C`@ĆÓ|veț…‰>:öüe‘›š–{SFîț°‹5Ž8~iÀős•Œ[ĄŠŻ)źȚ3|Ùy·>Ï𒇡ă\ŒDŸŸč@(â’Ëh0 ôàËŸ_›Ć„éÏŐśwą>š&Ôï0(žȘRüž*œĄ?‰–œâ„PŸ2Ž@3J‰ÓĐJ±àyŽ\ >›'Îlú±ö3­ÖùíèűČôĐ5rŒŃöÍàV Ód»kÁ`ž{xûêÚ©œk'H$!ŐEkI@•V/¶° “pŽP—Uô gÇk}•eŹ Däx °„;aT`ŻRL­6>4)I•h žÄ 9ÖЁGÉ&ŒcŹÊ%1Æčš.vÊœKÂW'ź—OșB6ۗ€ ï^̍œ‡èûüeæÓxàùç`ìžô™Èć+I+kCńĘÊùbۍ”Š:òFæ^]^ÁGžd±Ș^ƒ€óĘ6K%ë Ąò8Żf@dIJ„<¶+»wő‰{P©NæSbăɖ](d܏Íä 3È7îà ©śŸ  «ËqëM‘‰ńș”GÂÈj=°äŸ‘aż/çièg7|Ą7QŠŒăsž“WŹN2ƒNÔ7Ég_WAZpûțŸ<ČöFź…ŠK9¶4OœóS{gà]žńî5śáóĄÚéV”śÛŒ{ȋÔï^n”`û22쐈çŸ*G‘ùđ-ል‹ôUpœ9z™Æš|ÆŁIFđXLx4éG`kícŰ<.4#Ž Ê=ÖŒ ș Q“\߁ “Q#…Ś‚^Æ!_$P4“!úsmˆoSmˆo̊ •ŠÚç…lŐZŠiÔ;€éî, ÿ©-nž-Ib‚yìBRç„ńU.[Ö„se¶îàpĘ8aŸ8@éP‡B Aì=ÓF7Xa'mæòĘhłóšćnëX’©Ö‘ŐpüœûeœŐ”bĄlôŰü…„j‹3û"À(ćÿœú‹8!ÿ§fùß*Ö5æÿkHäv3æ$ ąÎÉQ*€1¶đ…ĄàąÜûŠôNJ”X*jđĘŐzä7źÄaJ[‰‰Ae\Q–Ńݜ˜Í˖Sóˆ„K\JnLJT 'ÔÛČșl}z‹IÙ/šMMPśxòĄïż†—0án^!skęQŒŸnr›òUž™9ßC˜àíÛ5Tt™@pȚg,Żt9©H±4Ç1l °/ÇwVjQEäH‚|æVȚe`ÂàIÜ`Ą”“©i±“ŹQÍő(ÁƒșèᆍÌPzę§Ïćßqӟ\AûJž/ʫۊJ<îźH“8e'^\Őàßț?„Û endstream endobj 51 0 obj << /F6 13 0 R /F4 11 0 R /F3 10 0 R /F5 12 0 R /F8 32 0 R >> endobj 49 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 51 0 R >> endobj 54 0 obj << /Filter[/FlateDecode] /Length 3408 >> stream xڕ˒ă¶ńžŻPćbNՎÌűÊ%Uk{]Nì8•U•Ù°"4C›"e‚ÚńűëÓ/€ E­“ úĘhpïăxśŽŁŚ·üš >~Ùìęûn·œúöđć»|—$û:ßN»€Ú=Șb_%»ĂŚÿŽÔ>}xL’TE?\»©=j;=<·v%T&Ӛă$ʗF/mŚ ózKë1ĂR č”,†_ŻÆâ »'|‰ÚŚYˆđ{3}aq3Ud'=NŰ,óô̝ÄMn±íčÏÚJ/ê™iöۆŒŠ€êŒű€­&^.ÌÚȚ"gÈč»`đÆoâ\O-BôĂÄœÂțĐÀyYh`8r­ŰŃ2g€[sçLš”“q\Ă! d2ÜüùjeöhŰä€C[<šik=·ÄČßy*`æĐ5ÌÌ|-N™A~Fe†b{+ÀÀș/,ÈŒŁŸZł˜^«ęĘÜÁvÔGä*f‹ńMĄ 0‚ŒÓęȘ8! 8ʖ ±o#QBڇ8S};Ą™Ș3țFOš[Â[ô8ńŁ“2Ž=bČìčŐ Üæ°f"gčâBù–ôÎìŻÁĂrüu"•$–•Ì2ç@„A'Rè[łèŽkțú:¶dgyM†/1(Œa%KâX”aś0áŹ[öžđ¶ 'šŽfÄNțűő*îâ“<€$ŠX€pžĂ 4œőÒ3ŒŚ`ž&˜[ß,ɉ`(|ËsŽB8]»ŽuYô蝠 —NÀ2—Ą\¶ꟀœZäì”rç!ó|#Ś‚Qe„šQŠŠˆÄęćâț¶ĆyĂTTł7L3ń†Đoˆ”B LùAx0œ8@‡R ăÎ$ő_L à]ޱ«Ăù™íèhÚOH/ $n™ŚÒ”ÍŽv…žą?Ț±üVÒ=Šô\–6b"§†ĄŰj`KœžæqŒŽŁwźh@~ÏYȘX`4‹ ÿîĄăC û¶œó*ˆN—KÙeBH”Șapf6Ì!§©"à!Îç—Dì=‡ê·W=ń‚yԌ„ê…í°mŹkŻȚjÀòLïZo(:|ûÓ[œZÇÌ>xż<·GUă\rK5gűÖüjŒSœÆôÇWîÂ&ŸäȰ‘ÌcÙ«X9K­ƒt?8eŁCA€>84š' §’FöŠ©äVŁ'ŠŠ `rŽźéćH-ŰFOyN–—Î Š#­œŁšX G@țpz Ô5 ëBâÓnÆB±Ț°%łgKĐR9ÀđxÓ üŹ3yB;ŻÇéÎф6gĄ2p‡š ń ’Ÿ:™09N&ĂÛ q ă;RNŚ UÜm ᣗMX=ËâĐŃÄéLÇŒ»-çÆùw@RÔĄ°RIÒڝ<°‡3kì šÂ™*ôf†CŹŐ‹é!ĐCÀĐDHì–NŁN“ƒ„IĂùŹû†û‡Ÿ{•eežSÏ;1ż™ăłˆMq9Ś]ž|łÊÁW  Á>șn‰…rK‘Mč_ cRVłœ‰ÈِtÎńDc™ČK-Đ-ęòà*:&ËŠńU26óçèMù‰Űæ4ÎAĂA4HsƋïNž‚$„pÈáR5ÉZđÜ3tlŽÒÍÊ-ïKž[ÆOCŚ łĘ„%f5ŽŠÖžčë—¶üA«łìŚ4Á3ž5Ì<„æĆț|ö:KÚNOü ©Â‚ Źű<P Š„0ĄôGEèwĆ„âÈśA2ƒ] śO­æŸĂWÿD'śf5}ÿpÄ.’š“瀚WçewÉŽŸÆáÌ-ĘojÀędÍÂŃÁ§”Ëžœč}ĄÒž ‡™Áș@ÿeôÊúŁ]•ÂçÊf™uy€«#Í„‹ÍRPà3̌ĆÎË·O(٧˜ cÊûČycŸBDŠpìź €?LôƒńÏńv3eaûÉäp­Æ@jȚĄê€Uî•Y±2gąÌ懰s„»ŰĆæ˜čN™9“›)ƅ\x˜Æ.Vü§ń‰È*$ą— Ì+Aw–šőYì#ęvàëmÛp!s[*+äHĄ“+č+,ÌŐcg#mWƒÎ-V.rź…òhëàX±i~»ŽŁ‘țExPÊêæ°ș)ž ń”âtćüőgVë?;‡D:-Î{4a‹œàžÛł5ĘićçèówkozÇéQm€ÎCZȚUĐUčqi†™Ę~-Ü+“ç$ń±w?Ž7—§áÒ(Ä7ŸÍš†?đÎ”[ZŽ7Άêƒžpń?Í`.Š$› ‘\4äé|Œr>úD'ßÜÉö9 oU˜À‰Úëć‚Țϕ†:ŹsÒŃW|Mš†‹€ |ÍûAIô#rę„”F&¶'aŐȘüæĄÏož ïU(%ŠeÊq@%·lM‹P…*]çĄ8ęÜöíčęĘ,ŃŠy¶ëpÀ*•ˆoˆ3ÍĘș‚ËÎ)—ò‡Ű»G1É:6MSlz•„Ú\Țá›66KDۛáòfRa†Â:€țĐÛ źé0űÚĐ|NÂUÛ§°Ț蝐WČá9ƒw’.úŒqźIą3 ŽđŽ+:PсĆo ú_'cےdŒ?4ó•n9ńû™ÏÒùûôæÔ‚ƒOàțˆœ±»Oœ7C‡cuČĄ˜˜DЧ­čă„Đ‘C^”*­ÙëÇàÚ0Ă"oçòtdïá„Âß9Oy䯯ÖEčśsòÿȚŒŸÂ+GÆâ…4Śú‚”UTî“;RűsRlÇŚ’ Y$1æÁt#ç‹!7†z‹­ÏĆôő±.æ«ZĘsć+Œüۋ8z„„K<ëÜ.žŽÓ7Tźv€” IÌ;(çĂLìÜŒč`úöź…0Œćf—ÛnŠ.ž +i8LSËŚQ©˜­\»a>Ź ©ò a\Eîzʇèš+gxu&{(Ê@CœY=1łNqû»ŻûÓìî±ò€čZV-ĆGąu%ËžZÈÏ_ëĐąŽ/œ†ĆZűžÈÚ-ér ‘| †Ę;ńqćjü1Ś)pmÉ;bŸ’çû œêŽÇW‘ûÍsgii•ž;śÄźÒj«Dœ|»ŸÎ3üUțą@»@›n髟+úZäAÆÆ”Fó*k]GÙçyj¶Ű€‹·“,LŰ6…ùŃ]f—{ížyê ŹY|0ȚL_ž‡Uà“_5ÌìŠg”ź pë<>?Ą‚ŸȘ˜˜ŽÜW„üV•ÉoUßV~—úšą¶ÿ§Š ûùZ Îûÿ2Çá!Ăßè7«ŚÏüRUÓ2ß?:$îȘP%ÉìZđCTmâ«Û$žșMÜżĐy)ł‡Ž»(⻊”xa,±Ż2a»ÔbšO v“SY&cèWÊRtglWIćź1)B/Éáß«TÀžê–čȘ6–ÿ€[”|ì čƒ\Ë­K&I1gp©8}ÔNíțûæđÿę°śö°KÓi,“xŸ(âA”ÀćțçûÓhšï endstream endobj 55 0 obj << /F5 12 0 R /F4 11 0 R >> endobj 53 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 55 0 R >> endobj 60 0 obj << /Filter[/FlateDecode] /Length 2397 >> stream xÚÍˎăžńžŻđQFÚ\‰ą^ä°Ù™ &$ €ÒACkÓĘÂŰRG’ÇÛùúԋőX,ÆèsiS$«XUŹ7{Ș0ÜÉ4S „Žeʝ«ŸzÿuÿçÍžŒ6»(REB,<1Žcl‚§¶čŒ(ÜęĘÇtĂéDćÁ«h ˆLÜh?”ûmü©ƒżśíeß_ZËÈF©:*rç„í×-1ÿ €©VÎűí‰$M‚çČăAɛöpHKă ŁMŚgë†ÏòÛőMkGڜ-Ł©jÁč쫊ôxl4—žż{?ŁȘ»ƒéLĂ:e;-˜óńÚŃ—xąš]OLĂ:ߏ[„Ë‚gžŠSS:5eYÀosdLLe—S:Űő ہ>SšCFŸjȚ8@<„±ybqÁ—æŸ+%ôîK鬝Áî…B;Ś©”ź‚Î6Áč)Ô/íÓ§%`)À'K ôQnFH©=:VÏțčìyž,B°\«Ó‰Ś¶Û·•\OÉÇ©Á“źïˆèś_ç$Đ-äƒljŠ`Ùä*çË~ĐFOOÊhGFŁù5š űà…±m›ăcŽE#;ïææ…‘2É&pŒùč ńŽ @ŰCÀÌ Kț3Èč”{[±ùX–Ƕ9Ï|ÂÜ ßN‚iźČì& ސćŸPr QĆà»3‘”sŃÂ8xàŻeEBKÇ“•ì/m+6{zć)>yTĂȘž nf—°Gìò e˜ç*-n’Ą FÖvęB€șP:‚L/ì+JÉD!Bif· FTdŐ3*(ź /ì'D?yÓ©r(v3ük(ÇĘÎÙ{èàTșe2 r^Ì ç¶żA+Ń:TIzË {ĘùcĘâ†MĄbăLDŰsđc*đ·oΜÌ4K]+|Ÿ2Ê(=됂X~Ț&!ú”ê0?=‰ŃŠ~Շ%& . "Ùőeéy…N3U Ûp›œČqnČäE€q'ü ßcđ€»?ÜÍìŸÙÏöcd? ^ß0ąèÔžœèkoz„D=o8D“©*rVę-bĆőé, Șƒ8Œ ­y/Y’ÎB_œű9“ ŠjĐ2™NźœŸ~âEH«Áf;ùš#,Y*í[jÛЙ{Âûűô^R†à§Oï¶ox/EȘôM‘Țƒœß +ń óL™Ì7ȄăüűJœ$.ąÉm—°Â€°xbȚ©@]OÁFՓ’á€fpäˆ\ltłc*œÛ蝄$ԁÍŐllïÉ^Ś(1SMÀ«ș/îąUì©x‘„…ä*ś·đ·mKÉń“:„žmÈ)Ž’»LŁ`«€_Ȋ1)‚SÓÉ!łêLÁ}ë(ű‡tû`CÄ?g[֝ĂRör·DŒw·î É\Á”¶O<€ą~ùV 1%Oxš ÔșŁę€8šÇ[:Á!ŃŒGhœź’ÄÍßȘÂ&'Č…>[­•Ÿ/wHŐŒFŻSàoЇ`ÊÜą†# §…U]-< ”ya1Y.ŹúéEÔêΐf.Œpk_ {”t™äŹ—{ț†,CœĄÀtŠb}“ÄFÈșüüˆAa­ÀÏ҉°ÀbžSk-œäˆT:?§C§&[ČÈôÒȚ*žÓÖŒÁIŽÚœ!”Üä &‡ìiv7§żć„őæŒ0vÀdÄ̎§íĘXăP é-tlŒŐ‹W ©Cà€‹ÏŸ5ÀJÿÒPY™ÇÁ{ÛÛ}/M;_Žów đC5ŸÙhòká܈V§YŽkÚ%Dxz…áU—=„5ŽFäÜÙ5‹ìțœ wŰqQÚíŒC0 G/üu(„űX}1Zż/HuÈœĆCÎt›Œ‹ÛO'­T˜,ÁMUŸIGĐe„ˆÛŠŠ\@GŃś•ępÇ&^;ÚŹw1Š/6©xń$òú0ïE™\…fًZiŻ&CŚ™1>»R~x·ÂŰ&Á§#WÖźÜvûșËÇËIækț‹țw w“Pêń?`„Úę9èáu@GŚ…ZEË:>I§„Fqđ7l—_«N–©%‘5ś`2Ëa&ÉF4”œòÌJśÁ=\qtçW.ö2 >©v¶ewL_3Œsò蕔—PDwü,8ÄǙ1órZŸ kŚÄtr0~iòŸ \L­›~,<Ł•’g­wŒȘž–ę["pN“t…TĆőÀăhÒ&ˆŸžZ!wEz†ÛöššŰF3ÉâyUȚMæŒO‡tÜ ‚IöÎ,0Łzy9UŁóÉ3–©żĆ“)`XoœÀŃ Ûùêa@$ƒ'‹tweȕ‡\B[SÏcsĄțg^đCŽ."1|]„ł‡’ŽśqâH YŰÂ3Žv ]òŚSùÂߜR 쁜=Đ?„ïš‘[Èó‰àÄ>Ą. Êùq „€K”E_Uâ+.4> endobj 57 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 61 0 R >> endobj 64 0 obj << /Length 3739 /Filter/FlateDecode /Name/Im2 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -51 -213] /Resources<< /ProcSet[/PDF/ImageB/Text] /Font 65 0 R >> >> stream xœí[ˎœĆ&RVÿ*K"±š€“`’ț§î ĄsÉÄ™xRYĂt4LÏŰs±Qž€"b$òaĂ"»<@”Eš]¶I–YæòșęŐ=ӞqÛłÔnŚésȘΩ:ś*ßeŒ—28)§ÿÛÁÖŹ“œÖȚ*vżìM|ŠgŻwÚč^{&ŒČœvlV˞¶ÓĘî‡ۚ^›ˆÇ{Ą\FÔ@Ô^ś^êȍ%V&uÚæ€ĐœČ ó.€%S!…7|o”9ńźç˜ąžè]ćmEÒ»]ŸĐ‚ÁŠáq ŒłàLo ‹”ÆôÂł`do„­ă­.ÈĐé Á{šê8­ŠQ"ô ((ć{­†%ò…‰‚Q˜Ì,H±Ő}ÔœóÛíî‚ę>h“ŽGŚ„YÀđ@"):ÒȘ—Ś»”ő7ÙáțŃ€[{‡iȚ­ęŠiß­œ|ó:ĘÚ+żß­œ¶vęúkȚ|ńĆ”l„_źïíÍv@òÒKĘú+ì'zîó/€ÿößß­_9>íó—ăőđő»%Ÿ·ŚŒŻK>żÆß\9^Ÿ.ù`ŠŻđ5ZòùŠű+,û`Š›ß{êĘ«ëì­î­K«· úBŐ»Æd*À‰žÌZ*q”DöNa,dÏ]ouBx˜”0~ôí?ž{æó}ń·Aù>ûìł>柭/żx-<ęż'„'ÿúę§~QMń*,ČBÎUT+–@‚Ăk‚”Üqđì'1á 4e™ą8⥩ÉăȘŽBZŃÇĐ_éTPi—žÓpJȚžŠYW(EîV€uțÌc“¶•«˜ÛȚą(!ï†hÁœÀ ('>Z“ç àF”‰śjŽÂHȚÏ e…ïn¶n€$…Ź›YáđçÈç#-4ŻAVšȚû’śr5RaŽ€È€ą2't:ú‰Œƒ€Bsq#1ZÔCŃd$a!Îà€À‘±` BUa*­i[Àl€xo‘Ńł€*Ì!Î o}ŒO#~ŠP†”C†PóÏ9ăŻÔeœç~…@V䞅>ŃŁV«óç1 ŁČœ'X!ÚłÔ‘@±”œU€ČÆ7vœ—–žÆ!Plæ’ôșŒcűäd*†°œ¶žÎPÆy ą(ĆÉZê A‡^ K€!„ ™‡ò{f9SÏK@B•ìz8+Ïł— œ”†‡ł§c"§úW!"úÊÁI­F Š3Đ)ž-­î*$)Ke·‚”ÇáGRćÍZ†=Œ€űÍ7ÌBą”‰z[Û›čSœÚ"€Á uJKGZX ä›üdˆf«Œ f@D,ÎȚì€!C…?Ò Qžé {á$sŰƒiś'1-„F%dÌœÚżoÍŰËĘÚosœG$ـ )œbÈV„™!}ušmÌșçwfLöoïmßȚĘO걫ƒÚÔTRÓăîyEżżș0_ùTĐ.‚OMÉȌ|nnNïMNaO9,ŽT:±'NČ'á ­șö€FtHìmOś‡”Á4üŹ"ÒŰl©e]N]“Œ¶•Đ(«‘ÎBMaJŽ6Łÿf“xŽÓqȚ!Çlÿ rȐ5àœç§wźÁ±=Đ}èòÏٝéűULï]­"œ .EáŒÊśû˜qܕŃę(ŽHĐÌ4r0”Gș0-H[Ó&ôƊ*sùàpóđè€-'ë4È)‰CI f·§»Û{<‰ÿą&ÉÊȘ&ú„Ϝ}Ίî±\àăŚ*ąÇz—Œsó“Û;ÓF±Ô”AFF śÔxS‹)±‘Ÿ‡óeŠA6s‚oŚ Ê·,N??VŸq:’),LüŻâTZ«Í|'É;Îń‰#} |ZGœȘSÉìi7é¶Q»êó ą EO…ò˜¶† âĂÜÚI„@j1gˆ+í_cˆNô!PŻ‘Ë‹jˆËíPĝV‡ĆÙ,šaă>ÊÖ D]„Ï6ČÎQljpŠBIwPç0D„oÊé8ÁĐŒ!ÚEŸéą€\C đP”čŚČx ±ˆ‰6Âěƒ€ŹPy¶x ń€Ă5 ekłBÙ]m3'#°”\ÆC›čbä&r™ Ó C—Y€hzh3 k…ŠŐ%òxh3WŒÊcžaAŠs^Cmܓkˆ3Ż!.›zPńsPĄ‘Lp8Ÿà+dg€äPë“ §FSŹ8òz;l•D.H5\ŸŹH+8ő ˆâG ”Ćé’j k§ÍV<ą i”~vŽçB#W2©ß$lo\…Č)0F-p%‡! îo†”}švá¶b‚'ä“}ˆ—ŸąàąDʇUiCœ%íÈ}±YŠŹ™ČÒè^1=ÌúÂŁo.cRI„]Șÿ ‡šèf†:NkP“ą@– x2ƒpŽòțșF“Nf. Fć2ϰ GÒÉEÙȘndÈΉŒëF' Üi â‘VÆ~C–ČŃç ):čmé’ N‰GT'ošŁ”Ić"`ĄÒ<7§rŚł@vλĂÉŰ-Ù`ÆÈü)ćH™?§ ¶šŐPŚšŐ™ˆ§ÙˆŁŽVÙű“ŠŸF°Š4#:Ô‚~‘ô Ő†+F4Â!pÖÂxd<ԓ;6Bôż*ț9(KÓtȓíÀĂòbOŠb vΛÂçÜŐ^ĄÇ™ˆ\R,V{ȘV{&U{Kö•Ç\ˆZ:€ČS~Úlìüț‰OÓfPśjD šż„ä/żâà8ߌáÜŠtdîHđ6ŠČÍcŠX{TÈÜ;‘‡%UP~%‰‰n Ö èèô „xÓp ^P€CȘ;žFăl±ę±à ȘŚ7L* `.VŠ i:?°0(ąí&çŽö1THjàĂQ+ XŽč"~”"-óIb.„O)kke…"-łÇGôEpGiÊé5”(4Q°Äà©ÍŸŠäPëÁbkł€T/VQ™{Ž šæ­Gč"Ólgiike< Wśvi‘–Ń­Òœ“pteąÏS€™Œ„„|ߟŐ-IEȘ]TŠê:ăcęDZ¶B†"M™w“È”€Š•VÀĆ<ŠÔh«PąDƒ"”TQ+`Ö@(í@. é~-Û@€ŠAô2€|‡|PšżÓughÈë8-@éNàš9œW™@ˆxŻTWÈcJw2 ŁČ˜gX✚âÈOŸh(Đ.§r —[ ŠR}&é§@vHdœ)Ï2ț§lI'<•+»Đ§d)Cju¶ iI'$U•&gÂŃśH.ÎÈ_æHËS*ìé8jXò±F•2OPJZ!.ëČ^©òƒîÀ:Ÿ­ëĂ?ÄćCą‡„vI:*r:*K:Ú&ŠđȚ±–š™ą4p“N,fŠÒhÊ|›t/!6Ù^Ìć‰GX_[gÓU|ŃÚÙi )Ö:č‹H%łL˜$S€)zmQ!čN^‘6  0PSi‘żűĐšrÄë~„FNï7 Ò?o*QŽRžR  ”…#e6&^ó bŻ*äŒJY4„è€RTđèŐߘ|8Ù_«ș@âÍ©…‘PgcÖ@-©7ˆ6Ÿ§łTY @K”xÓór@źÁH“:C§5ˆ"C”ä±V-3(Èèëy ŠÂEÁ(\–ä8óYœât)§éiÀ“ÇąôXôÒjĐ­Ö>rë„‘NÀŻe^èTlțć…Ó°‘­üž/äuœhDŁŚEBąIi“šeûÒž­`TQò B,1Ž’)&ă(łeÖÁŸ<œĐwŸ—Rïn bÄ+>Ę ÆéșÖ ‚•ÖfY7Ń*FæŒÌPÇiF6br;leźÙœ4nd+•Ë<Â[«Vßô Šîú©ì/qúææÖ'“CTÒ[“éœÉ˜MwÙÁäîŃdwkÒÏő?elA„Îè"ŃȚŃ!ÛÛf{ûăÉ>ùxáìÙÆ”*~žy‡'‡“­ĂÉűœ«ę՟惆äîQÒő­±{"©…æl§ÆûÍ/Żß8`Û{ûìđŁé»“xŠ̂9ȘŒ€àŁÍ{öńŃÁ!û`2!)wûÓ$ŠÖŹ„Üęô”žJlę Íœ')7Yé-k€ągȘ!5(–œÁçNSC}NÁ ÒiÆPö- m~ï249œ3ÔßV(jőÇ6’@z€ąč}Ž6”–Ź‹Țj CANŽ â>Ä8èœì}}S3ë€T>Ș~†ÄŹÙŃ­ • tÏÒ"eHFŠ39ÄZ€ ÉHIpGOmdÄÒ<>L̐óćźK$锃ЧžčʉMÂÛû[śNébŃk€zU07őš ŒšRŽoŸ€·łčtBű`•ź­f'g,#ŒA:Ì‹]2«„$'›9yo1*#*JŒk&Ža!ÓíédŒŽÇ ·ƒ^䓮6,èD†Ìé„W””:‘ ć Q6•NêęéîxïțíƒéïOkHÓ3SșoIȘSö(#Ìežs¶yđəsr.Ä)*ÒÎËmŸuÊóNw§ŚÎP:&›gq°Û˜Q•ïĆg~NêŰ­.Oęèœ+œ™đČSŸ€ CwgùYÊű[rZ<֕™2u‡3$Òùűo,PzS Û9Ęqć+kd«Ú+ë !Č·șÿ‰+‰ö endstream endobj 65 0 obj << /R9 66 0 R /R7 67 0 R /R8 68 0 R >> endobj 67 0 obj << /BaseFont/Courier /Type/Font /Subtype/Type1 >> endobj 68 0 obj << /BaseFont/Courier-Oblique /Type/Font /Subtype/Type1 >> endobj 66 0 obj << /BaseFont/Courier-BoldOblique /Type/Font /Subtype/Type1 >> endobj 69 0 obj << /Filter[/FlateDecode] /Length 183 >> stream xÚœQ»‚@ìęŠ)âŽ{q€%"ÆWĄčÎXąh 1"üż<4ÄÄÆmf3»ł»łYpÆ92Ža҅Dç·Ù9đmëOÄŚš~(| Ê{&‚FAœ@2Ï ÍáNs‰ű‚Őg "ë&! ìÂp&9>ê·ČšÒȑoí cû·DR֖ š/êtk]đÏу;l„lq endstream endobj 70 0 obj << /F4 11 0 R >> endobj 71 0 obj << /Im2 64 0 R >> endobj 63 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 70 0 R /XObject 71 0 R >> endobj 75 0 obj << /Filter[/FlateDecode] /Length 3846 >> stream xڕZK“ă¶ŸçWèÈ©š‘I€ÏTć0ëÄ©c'OU^8Gb­D*$”łóïĘĘ_ƒ)Î&čH$Đh4€~|Ęà&Ü†áæ°‘żżâoú‰űçój돛Í|臧ï~ˆ7ƶH7O/›(ß<Äé66Oț5ŽŐʃMłàÒ”w& vŐțÚU=7æÁKÛĄ·«víIƒ/w&ȘźnܞșáypjûA•;Šü,”Cżœ{Hâ4xr„ûr(=Œ 3"?š§ȘżHËTíUù¶/`ĐvûJ„ȘUÌșé«n ż=ęmó@«Ž6QŽ-YbÙ+“Ç:Óeà7Kƒđ/Kàîä9V$rLŽżÖ§žže‡”Œ«NUÙWÊ{hőÜlP^.§zWuÛ §|XnyC«»ÆMŰ~:–,6T<-œT›˜Ï‘tŐ~+ëŽâmcĘ©Ź[¶^Šűù‘őîûŃ~źúŸ<°"ó€#"HGg&Ÿž:#“ˆ]{œĐágaüp—›ƒDż†ČÙU:uكE=àW6xЃÂKÏÆËZê#+žÍ’àShăƒlœÍÒÀs›“Nłšg™ZuĐ6öbô,6@ÿjD™oDbmàlĐ'ŠÏäȅ•›p_ ՎŒFç„ùtŒ3Ÿ«3P­ïĐX«(ęőr‘ć¶b2°]7@‘5ÖiR7xc …NYȘaó€ 𚫊§ĆȘ·8—džßÀóVűÓJ©æZ`MDÒzR ÇrX=ÄcÙÏv+skĂfäȚaÇè8žOJÊș‹!șîA)ö–ôđ±qJPj—œ]Éë}»#—0ڂ““$ /~‘ŐłQ?Ś'š…û6ăêYíÉü»úù:|Û­ŰPì›WÆȘJ˜˜:ˆÇîÚC-ÂŃkÒiWh{a—Č>áéÚȘUöšæ§^ÙÔĐzäć·ÈĘ>AâÆŐ<«îÄqąN"ÎDs«Ž]íù/žÆswȘÇĂO%țDéRYq*JÇLŃ'ĂĔç0ڱîA†0șKzZ.…Û^ëṌš?EĄÎ/NĐ‰ŽŠ°"ZîÛC‘đe.2·ç…[?Íă9íEjMđӍu9nȘïôzmTă‹O}Đ7…vȘ"Éžj­(ho”ÀCJX⯩^ßQcX_±ą é]ŚžŃ{ë%šûq‹Î=莝óđÌ-KOXÄăîY>|á ‚ŸšV™ȘW$^ÊŹìÖR“À8ŠkGÛŚĂU€Æ=‹‘óÆČ©ò đo2ČtŠO†ÜCÙht5ž{0i˜JM›C?żȚdą)âv‰ę“„J ëÛÓĘ,3ú/Hhƒ”áŹ.ì€ vDd[ž*\Ï§Đ°Ÿ‡H^ÈœÙI‡.ÔSo„Ț‹g- ŒüюŚˆëf/°LŹÜŃ7ű—áwšgĄ§]’0kæÍ°Eđo82".Ńż‡ÂčBŻ©ÂH#KËèÏ[,o&k€ÂD¶;A—bum[íÙ«őËÛ ôNÔ.q;ŠWìlG|K@š<֒ „™»”b»nȘąȚ6! ßáĄúZž/'[Öź"ù€?`Âë‰íÈÆăźŠb™ÔP‚l¶‡Ü0W†‡pÒ”đàÜűQ€§lâ°Ò­ÎÀ֎T!9Oq†6žœĄ”Žś XG#tюAŃÚ’–œęî‡tÌòt›MČÍ ™>ȚÚ-áÀ(JÂà24ÁflîÁbJuùÖæÂAă_Šń/•ęćż~W5„żœÂûxę7GȍH.b—.$Đx€œòä:‰ÜÏžș€"ŸI$yèĐÎŰǚJŹjàB>Î0ŹÉőHH $]ău ©ËKűq9­'­#„3Ë`.˜5 ~–Ă~œq?ƒ˜Ò /ńÇYN&YÎ-OnKâ â°ȘÏ€’”>A›éôuö“Û<Ÿ«}]•űQjĐt–…F.3čț»$ƒqm’vž„á/Ò°ł <<ûźŒÊڙŠÁÿ”iÈČÉdIÂŐ$tGÉTșŁ-͐ŰǙ;úŒăë ›ÌKn»Ï$KN Yž_cF ŁFÎùÙË,3C[qĄ…’ôżFĆoÊìM…áŻX™ˆąÌD3eœ<D7€CEpC˜ž8…ân}źđô3Ì&ÛÛia¶IŽ …GSî>/íŰDÛ<Óț9/€pá Š矊…:K~yđšHŃY@‘ŻY”J-\ŠÂd3û'n ÿ$Őâ9„9ڇŁâd~]à.$Æ21 êËł>čôk,HÆäŒš€Ô±w„,/ŚZÛbÛÄ|{ÓTû]Ÿ‡óÓy“1{Á‚Č~kŁ-—ă|łT„fÉZxÉZ€ŸŚc‹^E–Ô„êU;čhGfuÖ±ŹLÚ±ÔŠh4qNŽš<5HƘ‰SŐ(IÜ őŒRô‹ąàăË;ŸÇWÂ$[ÛđlkÿË~Çnż«Ż—ËÄ©[’­íZ¶L$xUêđښúkÍ„Ä$„c±ÈŽ-Mú“«j&ĐĂ{œv’ołâäqê7çÈ-ăt"™Dž©r4€›§ú5ïžbuŚ›ćIđKËŐ«,‘“ SœÎoT9%+ń­”—”Šó|ARævŐ§±ÿïÎuS!€Țtb·iüíƒ& Aÿ˜†™Ü©œ)Ä1€“c0pcÔqè*ÄÎB<|9+őPÔÉA·ăąx㐿 =çH­Ž|EaWr=SL'#‡œĆÛÜÎÁ…«Cȑƒ;ÿFTw …púP±Ăê2ŽŃh.„ Y3Ɣíčí€Ç Â(Œ8,ÛȘhP—s–ÓŽh°ßÚȘő"‹gfS*Ă+ʶ䉓'wN%OVl™Gi„&.Ć7ícĄ'àÚàÉ1uó).Ï,Š)È+ž$à…!Òšá…Ëę;蚰bkN șŃÒMö"bqY©>ڧČÓA-±Z¶ęŠÒ4§l8QIŃۧș6źf)¶ȚË­EžhyŽmșm\”ou$œ‹wí‰u‚Ò€k{e’N%êÄ㠁„ïÿéʎ‰ßűŸóŽł:‘41:6ïiÀțŸ,”­•zR}źîFă$:’Đ-Š8+J€˜GJÁžnQŽÉ§^g»ą“Œś «I¶„€]Vgduô6t5 Òł ƒƒ`kzèDnê;‹ö„‡ç+ÉfeĆÜí„p*s.2ÇĄ„7twšœ+ż{WG[äF?AىqĘPŰ<—îX‰NŸŻÉV±1ŻMÊąç ^ŸlêțŹŐS­ÄÆ—öÚhí¶Ö~z槑íČ ôÿkü›@bD© ś»źVŸ nZŽgEÛźÎ3ŸÜẩÈÓŚőășč•íœ[ÓGÂR;_ï$KÄAhuhŹÒűąèû(ÊŒÖ3yi~›í±ÜlN{,ŻĂP/ëYŠT2LŰ] Mô/Cúv-ê—ń\hN Ž”·2·°Ìß!zÁ"èaQNàŸóÀ4ŁGT™t)ÂÀÉN‹G~ܰŒĂșĂÔkĆpÍđeŸ8,ÜuQ±‹›g‘–{ŐÈT6)ő6I†”žš„țO^‚’VŸőކțÓ^W’Z2-ê_?ę3ŚĘƒcùNu™I‘réŠRqeYêïàÉS[3„bćčœ6^țÖ꜊S.wèŠx;j-Q(§|©úș«ȘęìVtd?Žtì§Œoș;ăAÿKá`ŒÒ 8--{¶IÈłńÊ}+-z‚"ÖzśêœŽ)”dŚ ÛI Ę!“g+ő”Vsó±ÌÖăUÊü0Së<[šuźžƒ) 3_{J6|”Pš·Éœ«h~łâbŠĆ…nàlòÛ}à‰p5%ČŸwŁŻ•Ö0 BțSűCŻ9țŒ;jŠûț”tN6t‰jèĘÒƖĄrßpín<œ]‚‡c !LŚ9{ùb§ńíi­ïĘÜg'Ó&.~bŃYč;Ozr}Ëô—ÒáȘŚDíe§‘ÛÏÄY^yÛQ,źNâ*ô Êcf€•ešź™U‡ćonŰȘò€€?҃ç u—MDă aì”±žužM1 sșVżččÇu;čwŒăšdJű"©ÇiöNÙaœomąéáÏeęE±ï#±Ÿcáïx”»ă2«L)w%1șFŠ€ …&à—>AI ‰”‚e[Êfœ}q6@ĐVL9š9M“‡~àu7hˆŃŃCxüÄ îGbŽ/ AO4šŠ™îŽf*DîSŠÈĘ”1KüQ>rP)<ßșbŠ^Uuđ1™›jç™|#Ă ^n™șˆ—#·4ŁŻ6ÎÁ3?~uđ&_ùV$[~5ÆÓŽ=œș°ŠWÆï}„â>4IóYŒJ3ż>íŐX˜PJ ű-w)fšM_ƍŸ”Ąœ'€š qŠRÁgI7ÊҞ€æye̒ •hè}6wăy•Pwúg…Ò”ó“ÀjžÎ|"ńś|#X䳏ÌPÖèÊo‚…\1—©œćźZUk℗źșœĆąKo˜‰—Üzs#ç»â\ @m1‹Gôfń7NŸŒô`nb,«ĐLîuÉ©‡^€‘ïHhvÿ2”û@1LVĂ-ű<"D±0Ìf§*+çG,ö˜\POjńqńÿšqfRŠ0>(D«ä0Ă΄éòË9LàąiD ż)ĂáÈېûLê;cš| Ìœ0”Ćlțe€\Z ‹Û­lúN+[Ő$ÈNÆčîLæ} #·]íbæÙW”vÂjž%zǎyl”ß~_9„œąôâOđ_ŚŚüá’^æsđŒG4ž]qÓí§á)țD~â’ăŐÛïèÆKEÎKFŸ•Ìwž…#ÄÈȘÿòôÿ}üáicLÌ5ó‡, ·Q,[E3fîƒá?üUïŽ8 endstream endobj 76 0 obj << /F4 11 0 R /F6 13 0 R /F12 74 0 R /F10 58 0 R >> endobj 73 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 76 0 R >> endobj 79 0 obj << /Length 2358 /Filter/FlateDecode /Name/Im3 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -107 -361] /Resources<< /ProcSet[/PDF/Text] /Font 80 0 R >> >> stream xœ”Yَ\·}ïŻžo™Ô «XÜí `Űϛì‡Áhd)Ńb·ëśsŠËm^M»5ƒÀËôrÈ[Źőöï‹5Ì92-Vÿßܜߜ\$|–lbOțțà«‘ÜòyGËűïíÎ.ÿÜIކœ[Xl6◶;¶őë'ïv?ùëçqyđűúîęòíÍîŻÿŽK4)úćæ5ĐČÇżűKɄ—àČń–›ś»«ĘŸęó~ùæ·ßoïȚ\ßügśś›Ę8I””, ”˜M†]1dăòÈ0IZœsÆRXś0ë©&±àCY\r&°+&uc–Ïo?œYțńîăçćo?|:||·š''à…‚&ÒjQ°ŃI”—P4'ł ÆûĆqö&©sû',ú7çRp‘RT2NAí€Č±±€†èőM ›J(xÆBœÇÆh2ŚMՇ0ŐŽ€R4ŽP$#6,"ŰUžZ\ì )Ś-q(JeËțIYùێN 'ž|»ăvíiLdg’;ƒńɝÁdÖô˜bÆHŰà‘ŽƒÓ8Ł|ŸrDÖ­^ß! ‘§Ű!ąFqÆFœëFźąP7сČAsf@ƄjM=ÊÙ}ĄD#„ÊśÆŽ*ëNï¶ńÆșÛžî4ąĆf†š‘™!j\GœŻĘtŹĘÚì°S"44xÁÖÊ}yEŚ{±]Á]ńń„»Ț;„ Ą»’ă§țú—›ïj9ŻźJ‘ ËùêàŒÄp4úŸ-}èțöĆŽ>æ „9šĆajĄ˜žÀÆöh„óŃоȏĐ8–›W;D§śÚŁ#ɉ'Ą+{ż N]z"8ő‹3Á™ÖàLA=8SPÎôŒà œùÁ‰•Šc]O–J„“É_ ‹éèÆhŽ„ŁŃŸ˜Gc êјƒZ4栍èyŃp?ìgŃH—6.g=ræ‚ÆćlFmŒ«/}8ŚÛóÁ>őÉ>”Ń>”Ù>=1lü­+ÌTéYȚ†Áé I Ö ,éŽo°šjCƒ0„àŠșč}”7YŸ p}OƐò·ÄŃppÇÌ;xBÜCVRbŁm- œĄí›}0Ą¶”ÄIAàm>* ;ˆîSžV[ˆÎžš4*kł-Ïó`yàÒ$ÁHć"ܓ•łqPšą;!••R„&ے`áxč>N”Ì€}‰ ęq©&’ \ĄËHBâv8x›Áá\9˜ĘJŸêéŰD‡Ę-“ 4ŰÔÉW}^ HFÉæêüwê@đ+smáHšŸR}QÔÉUíț*-ŃIš)©ûDÉ%•țžÿđêț ù„ĂYŐ€i–IGÜË«ĂęĘ=ÔÏázOÒ(…Ÿ@뛾DaÄ`/êP\gcŁ„9’dT™äșȘh„3dU,g𔹚YŠśUANŒíâ°Gmƒ‡ÈXq­ŸÈž4ÎĆÓY;F#2P'š–„6 Â1Eç.ڊC#ŒA%• $F­+튜żĂ xŽŒÜŽˆ˜JzGƒ1‹ȚN€rt(IőŃÚÂ+ÓFÓĐuQ/$•hĂ)Œ2—Zèę)+ŃZ\9Èz‹Sëó«źpŸŸ†œćRCz1ćÛò­@܈wÿ`ú݌ endstream endobj 80 0 obj << /R7 81 0 R /R8 82 0 R >> endobj 81 0 obj << /BaseFont/Courier-Bold /Type/Font /Subtype/Type1 >> endobj 82 0 obj << /BaseFont/Courier /Type/Font /Subtype/Type1 >> endobj 83 0 obj << /Filter[/FlateDecode] /Length 184 >> stream xÚœQ» Aëꊔ»ĆźûoK'Ÿ e;±=ÄÇĄ(țŸç"‚ˆ6 3™ÀÀhcĄ€~EO°wŰŸuGÀ·«?>’™ƒó0Pæ©(hbšFÁ†±ÜŁ>Ű{tsL?;Ўő”ÀšÄ5lÒĐì‹ŰĐÔ»s‘nČËi%•ś^ű–TD$f“qe€»\șD\ïʉN~.ˆó)ßÉEąÿöv„s€) ÖhKewë^z<ąk7íl endstream endobj 84 0 obj << /F4 11 0 R >> endobj 85 0 obj << /Im3 79 0 R >> endobj 78 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 84 0 R /XObject 85 0 R >> endobj 88 0 obj << /Length 973 /Filter/FlateDecode /Name/Im4 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -1 -471] /Resources<< /ProcSet[/PDF/Text] /Font 89 0 R >> >> stream xœ­V]oÛF|篞ǀ€·w{·śń(;j›v™/EPŠ„8j,ɖíŻï)Rąé ȘaűA<·Ü™ăÒĜ„óßᏫeÁä\ôV=F- ­~-ۑ‹Î)ˆÉ;ĆÁPHAEKltR›yq àuqW8Čb Ś”ż_-ŐiYü< *P ąÊÏEó@ٌ‰ÿpB^.‹WW_Šőșü'âț3‰‚SćŹxuÿÏí>?OȘ·o†=%&ìZÜÎWłùŠZÌŰAuï(XëՉ&ńìń-ă«ûAAcɋK»Šêvzőu~_mÿî‡1’“Đ o#f]xcSLÈ'<‚ă 0ÄQ“y› 5CßV‹őJœœ—Ő›Q92 %kìn°Ę\łéęt@։O)Axš"Nd|SșŁàŁJ€Ó}ț…Â3ŒĄm_‹ù;!Ö&ăr2șž<Żö ÉÜ2Ú=AińÖÔžŁ§ÛÌïŸÍ·śŐrŸüôáFÚáà™áP&kÏ­ WĂYLÒd-śfčœ«șjttŠ: )D Î+¶Úg3!•ąöÌÔ*C, ł«•qD,lWŐúsu3ÍÄmŻł2žÚŸ„”o7űĘț~™Œ/;˜›‰E‹S'XŒK)Ő°ßÿx{QÎÎÆïËÇu2ڒ űûxJ ˆÿTž$9$„âvœybödà`»ËŁx”ȁÄb3úŰ”§ÚÀîw…8\]=ž”v“ClŹăsúg9țèŐOm–6[‚ȚSbl‡qÊőŃŰÄżŰöŽÀĆî4@žÈ o­`“Í-ê“4 ÉŚûȚŹ  =PD]w pâ˜û ÎE«Æ «±˜§6‘‹ &"—”H‹‘ĐŒÛĂüò™pM<]ż’Ű„ÌĂ­ćú çĘȚÔú”àuúŁTú4ĘΫF_͆tLőÛŐźÁš2o@@ŰÁčÓaŒv…`D‘G…XkÎȚŸRęrőtXô„üÿżt<,VłőĂöiŁ@ŹoaÇGț—ćtûuh]$’ööű27m™zC/É,gˆ(Ă ™âÖX\É6ì}(țȚb° endstream endobj 89 0 obj << /R7 90 0 R /R8 91 0 R >> endobj 90 0 obj << /BaseFont/Courier-Bold /Type/Font /Subtype/Type1 >> endobj 91 0 obj << /BaseFont/Courier /Type/Font /Subtype/Type1 >> endobj 92 0 obj << /Filter[/FlateDecode] /Length 2096 >> stream xÚ”X[łÛ¶~ïŻà#5cÁ$‚€güà$u&IieòĐd28tȚ"’òśŚw»àERśŒûB,Ćb±ŰËD‰H’è1òÍŚÔ̟?ïïö~Eë©_ì^ŸŐQ)JíŽQZD[mD‘F»ŻțÛö°ÙȘ$•Űl”2ń›ăèzì*ă±Čă S€ĂŸ"îĘȚŐ62‰«ˆOűsF38XÄßżÙHùĘ@c7 èpÆBFŸíßod»q ÎcߝˆJš "‚Ș?o ;’°·-)=8Ö”ßüșû6ڂÒh›ŠąÌüžkÔU©žÆ…”ŽÛŽ;.ƒ;^ąębĐöîÜŰœ#Î[=•€…:ŒDèęŸĘZÀ/‰Ò—Țʏ@…gŸqäćˆÀyęÀœó’:[† țÍûBΛÍ`§?Yäő§ea‹OőXßĐR›°.1húĆ`…i{{Ü€,oìz_O~…4“~/8¶đÿŰûܔA|6Ï@zOËBž±'e+Žm–ÈxBP#=[϶À1öù„Ì”y˜íHíìÊ èH“ûǶ6…R ›Â“>‹XÔA–AĆțƒăŒ{ pśDùÍ«-@L›'1v ăUŸŒÓiÿ4ÔíăŐ|HNšÆM‡ć=Šï~łÈ…WH™tÄô§ÈY8šs=„JÚȚ<òVuĂ#5§vV äŰzr`1˜„©ŠžÄș^cŹê~„RAùàŻ»gÿ óïđ[$R+ ù|›Ìi[ U*3Ńțœüæ€ŁŻșèÿÛ_ìąÔdBxE+Ș>”Ï*Ț4ú9ÂïțFÖț»wÁ=Ç:1î°ÿă™Șîđ|C.U€€(š–'BzÍ|œ‚Š€%Q\łVE”(…Ô\ ŸêöĐ=ęvČĂûëšiR‘SÉŒ’ ]źe őżĘŒD˜œÙđ]K‘‰ĐĆZLĘÖŚR2ĄxŸmoOP–û°A̙:$Kšx‡ŐÆ#‘©f™LÉ Ă2?A|ç%%Ÿ$ȘæÙ§í8ŠČáK͇ äpÛ\­ŒyPCĆ6Iž‡*źsŸ LÌ|aâ|ζ,“ÛSzŒl[ÚzZ€BëćÖŻkU’ĆgJ­X°=Aú›k­ÉÊûfÉKaô'™Eë-͋Lé(1uƒ‡f‰Šÿćń=êI5ˆútn܉ §ŒÊT)Šr™Sϗžvò<Û  ;_U  đFE—t?ŁRöWx{8śnÔęے2Æ|Bpć3źœP9AMšz!5ą!B=ÀŐjZÚ=’ëKĘ2ë„K‹ĂퟫK};b€xÓK#U0”*©`ś„§Œˆ ͘ś}Ą„Ä›}J4OC™±ăœ ކiÉ%,š@Đ 7Á'êQ(uUïHšIQäłRàk"Ye…?:© 4d°Ÿ·>Ąo {C0HB{-M-Ż€őù[pNÈȚ_,` 8€T g:ż”ŠË ,OjŃ J€ ˆüŃQ„ÙzŐ[Ä{ äƒö}}&ûa‡dĐfbí(ŰŰiì/û–ˆj́ššĆ@ùD킠ZśÄÖ,nߝŠXečdkÏÆȘ4Í«|Łi\sÁˆ€šwŠÓćCeçêyőŹ"Ćä2*iæÏł~‘ZźŻžHÌ4SKŸÂ3ìà~ÚWŚn©K‘„:3aœEfĆœűs]bÁĄ„–7ę)–ȓ„,ćœˆ/ț Û}&–™òY6œgzÍ6p% ÚtcË\ źm)—EmyœûL ™țyéËJ‘…|wexŸsÁÀ±ÇÜŃ^š‘LNÏD ûg3šIłçX3L«đxo š À¶ÓE$Ô«ők•^ŚÒé-‹-RՏMÁ‚Տw=V-€ ÎțŒNg”yù,3Í3›û–‚û„ùL–§ 7»6˜^,ż5ŸÈj ŰĐ~îŐúńrž21ŐUKÍL06€!z1„îj…pÜȘ„áwÔTj@!ćKéfù'‘,•âë_ś(ŸÎ°âčŒčڈĄùmŽv…yœËŸNošžńüœ«IZŠ\ńž?ËŚJÜÈÈæWĆ‚Œ»ç‰O§țÁ$‡Ju‰XŒ}"ÏÍ˰x!ÁïŽûű»Cć˜'dï<<ìöÄđŽW€șFw4Á[ßÒ.ĄöћqÁï€_‰;Ț&üŒ*zu-)Ÿțw«–KŁ^ϗ„P­‘:ßÖ=iöP·¶ÿHô*6ű‘zkÄŠ*æ0Òá·OđXŚxŹ« ­Ÿ—<ïk hÀg‰H”W;UwÆ_țidX  endstream endobj 93 0 obj << /F4 11 0 R /F10 58 0 R /F8 32 0 R /F6 13 0 R >> endobj 94 0 obj << /Im4 88 0 R >> endobj 87 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 93 0 R /XObject 94 0 R >> endobj 97 0 obj << /Length 748 /Filter/FlateDecode /Name/Im5 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -46 -648] /Resources<< /ProcSet[/PDF/Text] /Font 98 0 R >> >> stream xœ”–MSA†ïó+æf8lÛóy„üšČô€æfy@ŒfA‚–ćż·g&6°)HQĄ·§ß™ž·Ÿì•E`ΑÉbùÿsÒŽŻőśÜ\ⅾ>>éíáÜ<m„œŸ™¶š,ĄD PČ眙ŃÁü›éŰćàmçžœ“13)J­LGe9ČÍ>pÍú8{qzČ菗öŐćȘ?è’$‰łĂĆĆńêO ~šż1dÈĆv€AšJ|폯ż™î[3[Öà3órnŽ ƒs)ˆę­‡X ’œćÄ (èD·­Ë0ÚŐ©ù yïL@ ła†˜mż‰èJ]Av©™C5ÁĐXłHr­;DJÖ}:MۍŽ(é 8,­€rÒz*ÂČI'SČBYÉ&—lLȘá};ÍĂîÙëî”rÔŠĘF‘Ǎx$Ò[܃nˆàIvè&uFöRt‹¶uł{„.c҃4]bK7{TDž}èȘ»‚€șՈŽÀ‹‘ŁöوHą#Œ’›Œ”=Ț߆‚r6êä¶íi”—Ś‹Ÿ‹Ë‹ëÛóœNźWcdęëBƒW@ƒPŒŒ-XŃĐyݧÖF¶`Xgúâü0k&a鏳AZćaöâWÿùtuÓ6bĆSŽÂÙCòe* Ê Ź#Ë:ćçZV§”óTŠ ćÒÊÍڔ ,=«ű|àÒ:·zÆ}űIŽDÚöĘĄ°Ž‘ąŹĐŰei7↮E炞l»z­źć!4đ‡łÂôö9ž„?AK)ôwđgșkțLëüQ]œż§äȚÀŸą+qö »æÏX—&ùÙÊwțˆ?jjó4ąÍD$«›Rx<‚wĆ«ÿ&Pl˜©ÒÖË―jö†•öÖâ°G „üz8P͍ÉĐwèS’·“îvŒd8Ÿÿ\»ĆŸ=űi͟;~ÚæŸÓèÙđ2XzɛM2ÿ endstream endobj 98 0 obj << /R7 99 0 R >> endobj 99 0 obj << /BaseFont/Courier /Type/Font /Subtype/Type1 >> endobj 101 0 obj << /Filter[/FlateDecode] /Length 2591 >> stream xÚ”kÜ¶ń{…ŸE‹zć•HœüíDž›ÄpÓZ W<‰{«z%]DéÎțś™%íĂ.Ł_–Ôp8$ç=łÁ.Ú킇€†żđ°üÄűóń*ôÇ űÖ­ÿäßàł,ËuÄy<†ù‘,üPÀ\bJwkÖuöD»űe^쌄ÏĐYŽÚ‚W#…ÎÄIÀzk>5€SË» >@d‹† ČÜŐaBŰplچŠ8śˆòYxą‚b¶Ń4R„Œ™œF± ŸùçŻïo~<çÏV°éÁmy4ƒi-0“§áóĄ!{óSY*âÍĐ‘\†oBΎ Ősí$ŠłR9!Őó(G­rp"Az€ČÒ*ŒqŒĂIì·Ÿ`ä¶Ÿ*2 *YyđfèžÔ öq|F‚űĂ@Ÿ!2ôÁ;ĞG#^ąkSóȚń0{ͅ7đő8ô`X-'†˜E©”ùÿ}zô șćp`xžLöxĂĂJûĘÉŠ…wI/ù.±}|‘òkOùÁ ’zČ*ôźżąbŁâ”cș†Ë§ÉőÒĆˆ›ÍŚžđvŒü}Ä#…Pè›ÎÈæ3öŠŹßǞ#ž$ žvó,Îź#m^Jdûâ=n„€Őӑ92KÒ%aÆKą‚\UŸ+Ipû^A•_æ_>Äτkö™‹Èߚ rČWš$‡"\AM–ę"ĆÚ ÇŃ ­uĆź“š(O1è—%‡Æ:uÏk’ÇifˇąmŸD°W›mźw~{ÂZû„ĂY3lÀęÀÉ;@D•A7Fêžö4ŠóĄP©+ž€]VęêÏâêfmgOgO€è%’ÆYTrg$ùŻY!SVč.ąT‘/N—Vî ?ùâ0qPđì\RHâ/‘;'"'’JS”úÊÙ~{óБ_Z ÄśDVâò鶄Ÿóœ ˜íŁË‰pÖȘöœȘ6“8J5§Ń{ÆœŽÇŒQș˜ŁŸæ4ș4F@Û Ö_Ł“ìlăőJc“[$ïE­îÂÄĂf [œÇ@uĆY)6ŸÊ©ï±"‘˜Ô"i œĆ4Žâ XGE,ć#IÊő3– ?KŚpDZčÌđ™±ï°ĐáN‹hő<:Šƒ,qȚk:^±ÜăèЕ Yżé`$˰‚ëúÖ^O ŃÙąâjΜ _`?Ó€©XZæáͱ„1Öi^ÈgZÄ#Hl1ll‚pïCJĄ–“ž!»ÚÄÍ|ä'[MÜÿÁć"CÉêńóŐűû<ŚŻ;•TÙÒHÂÈ”Á»> «bzÊJïčkœžÚœPíx쇚-!•L1»i[Y9ĄŃžŽÎĂÈM)ÁÀÒ+'DśŚ%uÙÓÔčŽò°¶#$ŒÒcĐÒžędÚÇŁ0©BŸD$hPë~E~țZê#ôČd© 3ĂCîvW)ÎÚș/ù ÚEAaęnö  ïŚ$è[u1Ś1ívÀšž?$1]z•„"FÔeȘ@Ÿ{mr‘ŠHŐï±!ż Œd_†Êž<ËÀW·»đX°4_çpasš9•Vú2ÍU|%ž‰Ù3ŽÍWŠ\=»™f…‚ai1#Ńœ§*ÔRìf詖(qäŠÎœ^ï[’OÍ­ÇkâÄKÜđÔlŒZcrȚU–Ű6‡<†ú>țĄž.ęÂtš»:ŚËê|ÜC©˜żNV-ÖՉÊ.eŽR'€ŸÆbÄđéÒUÓ»ä|îƒÜì?‰@Ÿy+aŽ=ËßLĂßu öȚ#—:3Ç «ž*{ÒghW9ûđQV„èœ[τzőąț~Cki—›?šÄ%ohˆ¶y Ùg±ŸšĆęéwìüZ§ endstream endobj 102 0 obj << /F4 11 0 R /F10 58 0 R /F12 74 0 R /F13 100 0 R /F6 13 0 R /F5 12 0 R >> endobj 103 0 obj << /Im5 97 0 R >> endobj 96 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 102 0 R /XObject 103 0 R >> endobj 106 0 obj << /Length 450 /Filter/FlateDecode /Name/Im6 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -9 -695] /Resources<< /ProcSet[/PDF/Text] /Font 107 0 R >> >> stream xœT»Ž1ÌęwƒkÜÛí !!Lv":8bƒ#áś)ÏÂŰŁ VZm°žrUuÙnû5&iU8Šț›?ž/AÈ̋Æ?ăâûÀ©RU*}9Ș̱:iÎ9țț>ƒû1°JÍÀëƒ/Č*ubSMÈÁŰ9æŁŁ —Épö~čVòšo&,˜ü6`ïç,ԌoæóƄ͛ ČwädN‰oï!K!Č9J1Rd…ÜARQÈZ7~Ÿ6úÈÔFYÁH6ôûęZk˜”I–ł“x>„§¶gÎČwݶȘQö2éjSœҍŰ3óTa ûtśj[i„–œtœÄɎéF?í™:UÈ>ĘœZîÈuÖáX;€Û.Ț»`ÍÛg+ei€Öu ÿ7äÊúçȚï†ŹîZŽ»țG:ë5Ź [Ÿ«yü|‰o—đæSŚÎXxèeM‰ûkJ©H\.áéd燱hŐæ'9Y>`ÉHŒ‡ï!áOŠ–ž| §t^~†lqŸNbf”gűtń»%<"šă%-ęéìw»ÜJϟëȑû€dÒï©]/ęcű {Żù endstream endobj 107 0 obj << /R7 108 0 R >> endobj 108 0 obj << /BaseFont/Courier /Type/Font /Subtype/Type1 >> endobj 109 0 obj << /Filter[/FlateDecode] /Length 2745 >> stream xÚ”YK“Û6ŸïŻĐ‘Se)$ŸČ'g=Ne;ى*9$)LA#ź)R!)çßożÀśT­gœj4€FŁŃęusăï|sżĄæ{n†Ÿ>źRßl6Ó©ßíży­7Ù.‹7ûă&H7[ïÒ`łő»w¶mkîíÍ6ôSÏ;Û`7ónT♱+Ș{ëjh­ćNqä¶;-śFkčZžüïkÛčétLÿ€ęGÙŒȘ»“ÛțlÏ8ôáf ż¶ÙĘlu{û“,ț­LŒSêŐĆxaXÈȚüčÿçf :6Û Űe˜„ C>Oše){Á cy˜ÄŻ›üïPŽ]S|žvöÀèrÇ ß'b.Ź,Xб‡ku0Uțx“*oG’z—i–$&Iű4 ș„ùš˜”ä‡?eŃJŻ>2SçžïlY˜„ćá·ŚČ+rĂÜ©śsSăÁ —Ś%sЁê—Ûâ|)íYźÁtEMôžßÈp“Ś•-uą«‘E¶ì +xt.Ö0Ëź2ćęźü?éê>,ÒÜhH‚!Ćp“߀'ŚÉšœxPU|ƒm狚L–ÌČ[#ŒmW7x$JĆŽąÊkZșGü_7ŽHdqò<œ`y<űܰè‚tÎ%F’\I~mPäÄœ[“ِ'Ïæ€€^nț+ŚŃ~ZŠÈ~đ«cƜć&”òœÊÚžŒžjŠÙÏ6óOEêrßíÀČú~fSP5œâ żŐűÔw/†ÎàŽ,ÿÊùˆŃł”Ѷ>[Q5û•éńÙú…ùœÛê Ś*ä$+,ì@M…dź-7Šćöź­,ĆNÚ§o9ÔŒ†łôĐxB­†Ąă”»6ÖM'NBš?wkOő”<È Ă. ÿùȚ„4čE3O|qŁœ#Ëa{ÓBêÊnä ml šćńőË&'™h‘= œKcs+~è“ĆAÊ(ŽŒŚèòjôă ÈòÙ »Á»K”Ś^/âŹ[YŻ#GMkŚùĂő'§‚dæZžŚòÁ͖t|`;òžÚÓČ[@ޱ}€Œ%±œ4,J©]ź_I§±çzÀއĘș|I¶Ł°S[ZûŚu° OEjĘŽőpfŰGÆ$d  ‡Öç†Ăìbʶf’łSa ńa!țV§ŸšŠÇEȚ€WšŠwł†b@ǝi:§ŽȚp<Ÿ§šŒü‰q1{ÈÚ>pgâ›ábŃíàüł© Mlx2LS~lyìÀà°âȊ‹‹ŰcŒ)y‘­Pčq û„°Ó/‚ŻżÖčIÆ)A"/;æÆui Ó Ą”çĐ©Ê|ço™OŚ{Œ–ČT-+8–Oę)ƒĄTL™(ś€–Wx<o"u`:àûzOÇÁz>ąƒS• 9u‰=7ÊùlæLË睰3G~:ÖȚ+[Z)hŸȘö—ű"óŽM}æÁ~áÊÒŸVšșŠŁÚÎ=•ƒYŽ?" p—ő}}mG‰œAa 7—čy4ŠSaž”KM2JÚÈa±Cń©8ŒàŠzm=Š )‰9‡Ó~ûŹp‹eŽ/ë„Ń.x UŽă#üĄŽšŹûD=H«]š'Ÿ{ùæę/ï^œÿí&|ïćû-Ë|mĘÙ\ídêF۰uÙáÀăm@°°ś#C§Zæ#èÔú!ìț,æòśŻšíŽz–f†™w·ûśw(ì?~%ő+êŃąž°ŻĄIÂ@ù 7`}՞‹¶ÇŃ~Í3ÆŃ.ÔÏ:ă0ÏžvęX韊Lđ5ϟF;?ëüĂÌ»ÛŚÿ«ùƒÏ‡{úŠ'‹üÈĄț/<Ùh揷żŸÿțîçéÉ0™ô™èŠÈ­ 9ä  $șQ)だa„oXAG’„7˜ÚέUóűœÔLż‚q`XD°·öî›úzáH6vÏÆ„…}źhòîJĆIž—s}ž8ì†H»v‚©Ž#ŹÖÎV„í'*ˆđ 2pćü—I1Cjf«ÉI‘Ž’ŹŽ*y' éÌčìhوA;ô$ƒæ2àŹžÇ Ì40tJm°n¶«À€°Œ'?`ìáeáĘKr|oŠl†y.âĂoŰ>ˆ„Ù S"Ź@–Ąòƒźò}*öÇd] fȘˆSœĐs(H{Œžč'șEśštżŠ/œ+Ć3Ćc1$tb)02$‚(ž‹Æ“êŁőJ©oöeî…{í„U(ȘWâVk7ćvN5ïœj"ŁQQ ôĆE)$O.ÏeçOŃâ‘OsCXff˜űV-¶äï'TS”zq ‡Xêèż.1ă~Č.ŠVëbÊK†șX_ò2Ęä#Z".­ì?Îp]Q,Šb{~5ûúY­!“șwm˜BđÇËty(Í#ÿeŐ§Ëg‚Dz&˜Èï'‹%“ĆâćbončTBó†31Ąoò F‘k'‹­Î9˜/êÎĂ©pyä^ê$v)žżòŸ€Èńlj3ÒÈ ~^ìdbrțóČÿƞáfđßÈŰ«Ć!NL}ޟŹ“öăù ĐQǁśSĆŁ€üÈ}ÇAÚ $ÄH€ŽŽ'nۅD˜uàô c1rUuÇtźhdź©\ü˜î#ŠșăЀ©özŻ‹Š"èîĆrÄńšƒFò8:PM0ą7'3ïúbűÈ@Ł}°xg]yș옌Ÿ›Ç”1źȘšdŽtŚ#rțz%ȚÊöß©‡ŠÁŰ,‚ąB&9ž>âv†zÀ^R»Gš€Ć±\˜Éß\ÏhĂçûŐ${š_‡^*)Žœčû&pâZĐìËüQjŻ€ÛüSŠ”ăÆy9_éj]_Ç7  ŸŽ7Û$đw'IAŽ Áÿöù endstream endobj 110 0 obj << /F4 11 0 R /F8 32 0 R >> endobj 111 0 obj << /Im6 106 0 R >> endobj 105 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 110 0 R /XObject 111 0 R >> endobj 114 0 obj << /Length 2670 /Filter/FlateDecode /Name/Im7 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -14 -451] /Resources<< /ProcSet[/PDF/ImageB/Text] /Font 115 0 R >> >> stream xœíZK\G6ˆŐ]±`$/Jȃœ ©źśC$ń+™?F1ŠYŠg’LÔ=–gÆAâà…1J$ûÀ&‹l đ–ìXțß©ŚœĘ=Ӗ; B-Ëò[§ÏłÎŁNŐ­»Lp„ąW’ ú7Œ§âƧÙï:Év;ÁȚêŽS\G˔ škfTàV*аęî:p/Ïđ` SȚ;î ›v>‚ Ê™SÛÈŁ7/wаBà&ȘIXUŠ3â/:Ù „%ŰÇĘĘÎpm5"†ïă);»Őźyæyđ–m}Ôe+%“•gÄKÓOÓîÌtgú۝ę[»ÛŻl}Úm(ͭȞmHLd[ÛʙÛăĂĘ;{ŒFŚBÏVk.<, ëĘ7/Ęșțîù[7ȚÜÜÊš 6dà1DƖËà]"9ܝBôg·'śvč[Ç]ŒŸp7‹, A[9Ëò`}pf€‡cá”wçĘ;ŰÙțàBŒ°Ő]퀀'<Ź"[Âär]ąäˆrpä2ÂMRˈ(hrSŽ‘L•± ¶A2VêŒA€e,ÏMÒJȚVW.$oGígœœ8߯s8ÜÏÍŃ⎛ȭGÜź"Ś.\üCÄęBD„žKE!p5Œ>:€iprÜQ=Ájz«ò(P‚(,2.!™@AW!)KsÆńè2+ÉUŹÚnBDlhĄxL%Țćæ…čĂ,hC™;víÂÖ27źŒV+»Ù/ČԖ ù™„óŐ͋N6\zTáÌI5ߥč4đهW č#8ÉŁ4 ’܁șàB+Ìf$uQž{òÒG©fŻJ+”v„lx€H*J6HŐǸ.`ßë"فŰC„Z5ćV$Ćt‡DVM’1.Â`â$-ačêɧÒrè°(I”ĐXGeƒd,(ƒőJ9óą©„Śdp…Ȱ’;Zș)E”WšÀ`€ÛÚ G%—kŸ….§éj«§@iW†Y$Ș™©§ìČlĄ€]̏I’ÚSîfńæ;‘b›­”83òûPNa 4ȘŠÀ,!–ŒR!Ú{nÁJ:Ź`Z›ÀPwQüU»èhFPÚVmX$€ A4ą<ČÆÀXê)ze<îšÒk9Ì[1.‘zwmíû€»ń*Ûëî2Š©tvâ—?~țđb|é›1țŒț“_ô ß«äűsŒ‡ogrpùÛ ™ƒŸț•É‰Ë %Ÿ„NüòG­Ű­iŸ\Ż;.›Š€Žš«i‘t"èš7Ôé„PZ:hCăæž§3Ä2F«g±sŽ $]PĄqhă" ą5iĘ8(K!œŒ2NÍaÖą@zœ3‡y;fö\kjáҊŚv](}ˆ”ÔÿW”¶AYśdëŹÚW!Ő>T".eÓ^*™Ùzû€ hu!ŠăéÊ  ›ä(ȘUòȘzĐWUhUéÂaΈážl-Íë J9ș™Ę“•üž‚Bç7ÏYPL˜/(j©ű€fæ„úȘV’Ęš„[N6eûËËž<©yțć.k†?ZÆćëšÛËž$Đû”VĂćR-•łûŹ” łșÏB‹ƒNE))‰~ÚCd0ôÉ= ê†ttdXûšTÆă|źïdĄœN{ÂÊ Ž‹ˆÔWˆ\ZÖ8('Ò±Ê(ăÔX%%BŐș0˜łbžÏZOû–žő¶}–ŽŰżÏzqÖûíڎáYïș}FöŽN‚ûs&‹° Ą&=@+M‹Súűf„M‚ »Mm4tŠT!“!ëB,GőJÏČ2Űv9l»PŒxș.a±cŁ«0é0˜„łZćÖMhź“NŠŻß0Ășv‡:̰ ŽÍ ƒ“¶€Č-Źíg |ʍŰő;G'r°=YÓ FÄüČ|Ü]T űQ È€”1ÍÄŹfRÂżNŚŰ(g4[‘T*/Òô72­°ç]PL›tăeMčWÈŒb«‘B1&­„"ë‰N#" W Q-⑈’ëű Ę@­ç&k^ì;Œ:ŁČàÇEL‰ nè ôˆ9‚çùœŽ-ú“țjțČÿĆÒAKäYôĂ(nł=—ÏIkŁ@Ąą#4đȘCƒ $ôpgò=¶Mș`?=7iŽ*$k·*­Ńôœ Vái‡6íšź…<đ08WEéüÛ# ć1±ƒ=ăźA ÂÚHŠéŠ…HAíè}'#ŃÚ:ƒ*ŠŸ žhŠ‘ÔÒÙkœź| -uąsÜèfꊀh<‘U@ tiËæËF\kșï^V %u&{υtâߏ‘ż,mcdțĐŸĐG Œ4Ò5”to,"Æz3P{|B4čÔi iíDȚß[Y•–Ìu”(nŃ$)ŸoZFć('膉Š;6‘N ‘ ú1íêóęÎ ‘*Æt…% ˧ą”*ĐĆÀLœ‰_°2aȚ±‚Gc%û=ß6fÍÊ^eĄ^ŸN8A^;xÊ6€ôđ í CšÁŰ.RgQ!ɗ’š‡ Eˆ ),ĘcMdŽû‹,0)7À»’Œ™Z‹t?„òïÇ€MAƒ-'H¶#łìíL2i1/cê›ŻwSxä0vUÓÈ„…^@‹À Ò3 FMŒŃ&Àn€i…ä»}“À9Ș„5čÆVĄe œO—|*d’!qÀöÎ۞‰FûO·•ŠŒ6L:ДćqŃr’”ĘG@ČeMB±Œ)UÆyWș‚D§àt•Ôąkő&_ÜùlgïMvÓœAgQjàÁ ŹDù’ńvwf|{üÉNŸG‡đ<_ÛK‹@nC±ă óBâö+pcżȚÿűöȚîïoŚ+‡ézÓ͚3é Ț3-ŹŠ‹dÓÎaEP B«ȘÁLÖ«aˆK!< YDâŠí?IŠÍ»„”2]ÍșÚę­nŒt endstream endobj 115 0 obj << /R7 116 0 R /R8 117 0 R /R9 118 0 R >> endobj 116 0 obj << /BaseFont/Courier /Type/Font /Subtype/Type1 >> endobj 117 0 obj << /BaseFont/Courier-Oblique /Type/Font /Subtype/Type1 >> endobj 118 0 obj << /BaseFont/Courier-Bold /Type/Font /Subtype/Type1 >> endobj 120 0 obj << /Filter[/FlateDecode] /Length 1797 >> stream xÚÍ]sÛ6ì}żBô]„ˆEJčÛC¶4œŽY·„ÙSĘË)2k±%M’“uœęś%ÙČ{ĘÒl·Ì„fМ‰„u„ș(ZùôÉèłźHŠd ÓeĆÊ,o~ÏÖőÊÌ>\œö^^}MÈДLÒŰڒ€QèŰÚ!ƒxæs.€Ó^ÇlUĘpgJÓd]Q•šÆ¶C|Í=Œ%VÌŐʈEJRâ(dŐ<Œ"ÓŽ„î,Ń”•g‘Ő-}íH @)Ű?Êx@Ź\9d™­TŽDÍ«06‹țäŠÚÜ-‰Œj Gúܚê_üűêúìüâ%ÄQéAG©6g­1¶&ńqómŐævӀx·(JÀŻł‘?»™ù ŐŠŁ”őuրőźG 2ßêêÊRÈPè|’:!E|œ_~,V+„$ŁS:oLÖÙJÖČë䛩Á”Ő6eeÄEWÍGągćbg‡dËȘuB(VlÏU7•=;7mK€óÓ]íb«ܓIHÈÊŹź‰Z.ŹÊ!èUá7q b°NÀâÉB±‡ÂmTÉÆ1ȚˆŠxŁC#ĆȚmÜÁUë$śÌßÒ-àáp "-‘B B…WŐ,†ž^*v,äŽÄćĄ%)ŒkśȘÈ]æDĘmCĐŠ5m3Đ„ p”<[Q ű¶©Ö#ÿTyÁáîśÊuëzȘč€ïéÛčòzÉŐ<àœÁë,_„ ùT¶TA$“uŒÆL._ Űt4o=ù)ցÜńÓ{š.öPD]nźÏü=ő$ŁŐG.nÁ kÀ#œĆPŒW”Œ{„ÛŸ/?’Aąă!AHG¶1UÉ\&w0öÎÀK%Ú7°n„I@."œ€Ò ±R=`t™d-”‹ïőh—^ÿGÛŒd€săŠ(ÇÎ\é© Ő¶@A>€9|đTŹ ÇXŸ•`4Šx0­ă-Śv3z &NÎx*]›b»ê œu±è…ò$’Éź4ȘâțÿwPŚź°m)âŹ-GMț9Ö¶„é>֖& @ekź‹Ú™ćÖ`(q6淍iĄ^,#jàjKK‹ŰûO7YkźÛòO"|z,Êë¶űĂôëć:kïûĆÊ.>ŠÉÿƋ1OÂPCŹ•ăTČ ûŰ㙯€áÎ  *4fźcè>?dÊM”±J­1È=œrMćŠAnÆ 'úȘ^.Œ,\j‘:1ï>ŻŻèő”čü%}EšJ‘ ćôœüûú‚\ÍÜmń Ö"œ*üöͶ‡l iĆûcăD ކJB Q±b`Bșœ"Š#-”Țë }=”GKG—&[à|iEőPśpZŐXäŽkŠđÍ«uMăWkë°Ę`=ĂnŠûą H7Đhh°Ì'0<ԄÊ‹†ê2pR'Ś{c`ÎO°Ą9nòoÚP Ąà6p H9LÿmȚnđih-D‚Uk!RÚźÙä}} Äo ÚčùÍ,°§Âđ{rÛĄÇHNÖœ@0e&ˑmIâVĐô"†‘weD©q‡bśű 1šq’șč™lĂÈڃcu»Ïuœ—m‡MÛg\<¶ûáÚŹíÆÄ‚9’$`šÍjáșW֘ă'=—đ”Œę;ÆńRxèžÌ…;‚wžVjœiD€;;±OȚ^á0” lâvŹ'tœeÔAĐȘGJą)a ;‹žX†Țçzâóˆ|źXśŒ~JӀË'ùiÜčĘ&śü„Ò@§ûțŒ#Úù {yȘ·\ƒ‹1ép5gïæłŽuŚiDœœÏˆˆț;ÌtłéˆŽČ”!wò æușűdÂÖ{“Æ9»©ŸœŠ5jŸYő“„ \à;ïÙb„ őű“rzkg7ƒùá#ÖDÎö“[@LՁ`‰>HìI@uČŚßœű0"pϋÀŒÙÛ€ÿf­‰"{Y—ÍĄ :ŽG]“•íșh[|"CŸL»űs %r ű3ÄŃĐlőĘȘWżV…»oYž›ș›łŚ'Vąząì'1 ^ԕÉPK*v„șkȘM a|…‰d…–îÿ;›òŸ€™ęćíóÆYAGNŸçqç0žîĆ8N‚˜*`[5êü'òÓŰ4‡G̝ńŒ†CéêI†;Ç9|żmœí>gùô ''ožç2ßBrWó°ŻŁ\4ù›ż­L endstream endobj 121 0 obj << /F4 11 0 R /F5 12 0 R /F10 58 0 R /F14 119 0 R /F8 32 0 R /F6 13 0 R >> endobj 122 0 obj << /Im7 114 0 R >> endobj 113 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 121 0 R /XObject 122 0 R >> endobj 125 0 obj << /Length 1310 /Filter/FlateDecode /Name/Im8 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -41 -332] /Resources<< /ProcSet[/PDF/Text] /Font 126 0 R >> >> stream xœ„WÙrÛF|ÇWì[ì*iłś‘—”â(ź”Še–óš‚IH„C6FÖćÓ»8I*‡ÁrÙŠłĐÎôtśđ aTo',ü™ÿ°.A•rF’‡„“7ű›'ŒŒLžŚÔ9K$—Š EŠD G=cd—ŒGö}ą•ŁÊ‹“Lƒˆ0ÔydNĆ©vˆÜá·,?û%QTjäÄ"æŸŚùi•|c‰„ÎjČșKșJ9ђzï ±á…Ț“U‘<{{őêöę۟ożúuő|ő)č^%ïÎĐí,5ÆÉމ?[Až6ÔrNê ő/șW w°4€†;4YZŻ·$/I»ÍÈ:]ă_| ډUŽŹ^'Ïêl]ŐRĘĆŽ"+>f5yß—<{ŰVM5MzŸ5ä!«3Č«šÏș‚°Ü+êćŹŐ\JA™>”KÍ©QOf L‘C@—ž]ÔH)45˜Q+5 Ob/Ë IÉÛ«Ż€Đ—}ÖŽyyÜÊÏÚ:-›"ošŒ*ûІV~NŚdmÛwAÒđ¶Í&kw˜.­ĄšA2ŽN˜q~„ôÔ}Æü`Đ$–§›ăÏiY›ŐÍÇĆÎ'eš†žȚÂZOńź‰ȚCä˜ȚǙ&D8ujFQaĄZžĐû[ϞEoŁ,UÒÆ¶Ì! }čôTw] I™áèĐæ7Ł*Ś)ś1ڔCKTbܐ„"jőÖÎÚ9æh'iš“sÁ©Čł^lKŠešÙŁfŁ“• ĘEcć܁}Ž“Ë±‘ŽˆńišNŸd­tgËSì·vąáÂłKi(â—Wì|FtôúúĂí˛ßΊ!g)ä,˜\GĂf»oÉŠz(㦒ìkȚceqÁ„¶™‘9ÇÛÁ»äou„ą endstream endobj 126 0 obj << /R7 127 0 R >> endobj 127 0 obj << /BaseFont/Courier /Type/Font /Encoding 128 0 R /Subtype/Type1 >> endobj 128 0 obj << /Type/Encoding /Differences[180/acute] >> endobj 129 0 obj << /Filter[/FlateDecode] /Length 189 >> stream xÚœQË Â0Œû{LIșm„­ïƒ’›x­EŽëăûm*R/"zÙa†ÙفÎ8‡è? ę[u đíêO̧š(ÀÁă-Ú9ŒÖt‡…†űłÏD¶›"fB°[a­‡uŹ2mŒ é.żVő|ß'șG=D$óéÄ H’•Šd%•š\œ$É`UnYuŠK;‚Äțí‘)‘aĘ^ Î6í…zéńŒîÜw9lČ endstream endobj 130 0 obj << /F4 11 0 R >> endobj 131 0 obj << /Im8 125 0 R >> endobj 124 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 130 0 R /XObject 131 0 R >> endobj 134 0 obj << /Filter[/FlateDecode] /Length 1950 >> stream xÚœXëoÛ6ÿŸżÂß&”*Šzƀź]‡ŹkQlÖą ĆblĄzx”Ü4ĂțűĘńH‰zŽÜ ț`QäĘńż»#”ò\Ï[íVêń+=†?†g_źVßÀúóĆăÉ*uÓhuqłâĄËÂŐ&ˆÜ„­.žżw>űżŸŒűmőËĆddŒzÆÀw“Ôf”âŸŁh;‘_‡3”đűEĐSǑë§+Ovûą]o:<ˆ2§—ìpXoüŰ™Tˑs»”^ŁÇë§k xöß§‘Öbûw2«ÛȘhÛąŃ|‡l‹Ś~∎ۊÖĐoEń —Eî*‹7€ć†17 •Șç7DÛí l BK”2œšwòčN‘s#›ŠFcíŽOZ°&;z»Æń+Q­ęŠ6đ/$ÉxöÈli”1NE‹<2&RÆu^lłNçÜyöŁœżÁgàdy.EÛșŁèȘRύű)šTŠ|«ÄwÙVŒY°bŸÓÔć`‰Ìh€á=0Œ…—y0łÈçÁ„„À`ûBK—bC°"-­HŰÀÛI pƃ˜€ĂƒÈR„„3\¶qf‘Ç3ŐPá Wg8Ăćgűfp†c…łXá,V8Cˆ3Ú”± EyÒ{ńތłÀ9ÈFù ÓÈ{ț€`cnŽžUêÈcMŽËhò¶èôšnè™ÉʱȹòŠŽž·…r”ûŸH„ê°Ą'%ețfj8Ț\ŒÓUìŠ1⊈üAˆD›ïń[Öï/<-†d涐{Γ*û|U«+({ŻìĘOžÀœ'Ÿï ćì„y…sÊ”Ì…ˆ§|kê}v B"ŻòB^âŹïŒïvĆ͇zwiëì›\ip¶Ț0/Â4ù\TĐ,•h žÆDC˜^8‡Ä4B^ŒíŠ^ą !© ăÛWçŻÏȚŸzúöòę;ŸĂ!‰ÙŐGô–ȚʕbÙ˖3ŒČ7G„éÒíIOL!œ!r#â—ąŁyՋd "قHż9Ss Łisèà‘őąeV‰NHW-sçĆWv)bÛ5òŽ^o©XáPV … jß©]I=Źc8wÓżP,ÇF{ ÀrOuŸí1žíBüšcw8vc†b†oz_Đ­(I†ß«đæőŻöÚÄÁŃśMôŃ]6P_"°ÜĐĄàÏŁ>Ž7x– bUh„ffĐQC2œđŠ7–ÈŽ-}C֚žȘZăËč^;J> endobj 133 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 135 0 R >> endobj 138 0 obj << /Filter[/FlateDecode] /Length 1308 >> stream xÚ”XIoÛFŸśWđ8 gáæœ€î’ž-\=Ä9Œ„‘D˜"U’Č«țúŸ73EQ–+[ÎÁœć-ßÛ>RńȚÜ3ŸìŁûĂđÏęÁÓϞŚWę0~•z1Mco<ó$ŁÒóeDæ?}%y9§”.ŠșZ”uC™HR1òCÿ|rÂRNY”PFùK„LF߯żz~Beìù)•‘±ăŸüϘ Œ‰Ű˜ű€….@ÍĆÈçQ°ÉhOČҝ=è©ĘÍȘriWCĐ> SI†¶~»üűčîč,‰IpLđݜń„c7zVézŃókŠÇEOđlj Č|Ł›JőĐsÈžȚ‘=Ńő0ăČQčó›-ŚčjZcyYŚ.WÁ‘jٜ]=fÍąg*+ ëśčjÈă„]ĘmÎá ÖđÜ.Ôêm\üĄ&śșq.Č)ôN6ËôŽk x òrZ` MĆklìTÛE4ò¶ő8iÊf€DŚìŽÛź>DŠìÂræÙI1:FŠŻąÄČ-[Úő N _lj[·OÌù“œż–·žMéžáč]ÏÁqú<Ńłˆ^ȉĄ|RÜ-‡<„íŐŹŰśđLÁÏáB/Ś9\°đTZ”Ą8-Ÿż’^JÓżăÀ45Ö>èÜÉÒei»Ź­nČIęxJșœŰŒxLÊ5l‚”,ԈGäaÄąíÉŒÀûő*/›Żœ}ł‡YæòÛMdEÏTe…êMĘè„óV—K-9xYžÛŐd]âd’Šđ]ÊMCÓ\șÂi  -%ùœ[BHRÎđ)Ú8qéÌă2«­Tœ(ŰŁ‰jŠgÜ@Æ»Û@ÈùșrÊ)”© =ç|†Î ÒÓ$1X$ –Xę?ŚË„Ș6ûĆđ­ŒČ„ŐžÊ:,pŒnöŻźÛœÀÍő»pÁ‚Ää!++{\öiÙ&+æv«Őć.vwonlÀ žlV`5&څ)w-ôfźmí·»Ćpył °4uĘۛ.( ™șŠ(śúŚś6­ÈT?˜Lćˆ/”ë“~Ű y§¶öÛ^2ëšo8țț„”™ ÉuVdK|e‰ż€ț^g•^êbÔgf0J-@žTŰź 6xȚèíg=țO¶ń šIèùÆkßu·\òžáȚt™’œ&iOóÒ\ÚïE­ LÈŽĘXbȘÊ„˜'u ìrʍ2lxż©s­Ș¶Gmÿ—ëŠ%CŐ܎Ÿ?c^DByúąŒtšÛÚí Ńï IŸdwŸ̝żGî9\.Q–Șîí“ësF^öąH;ÍÿéÏZMuu8Pćâ­ąŒá[LŒ(ÊN󣫉*æk5ße‡h‡GŸlsò|2yçFĘbqÛIWrxŃ·ïyĘLè óàq.ń“яY@™e?–Œę»ÿ˜ț1 endstream endobj 139 0 obj << /F9 37 0 R /F4 11 0 R /F5 12 0 R /F3 10 0 R /F8 32 0 R >> endobj 137 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 139 0 R >> endobj 142 0 obj << /Length 64 /Filter/FlateDecode /Name/Im9 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 1 -524] /Resources<< /ProcSet[/PDF/ImageB] /XObject 143 0 R >> >> stream xœ+T0Đ32Č472T0AdNr.WĄ‚Ą©‘±ž)XÀĐĐÌ@Ï Ä62Č0Ś30)Ń2WpÉç BO‡= endstream endobj 143 0 obj << /R7 144 0 R >> endobj 144 0 obj << /Subtype/Image /ColorSpace/DeviceGray /Width 622 /Height 474 /BitsPerComponent 8 /Filter/FlateDecode /DecodeParms<< /Predictor 15 /Columns 622 >> /Length 3705 >> stream xœíʋzÛšFaéț/Ú­ă @€~}±Țęì™&q°@«òŠł>@e%7è„È Bä!rƒčAˆÜ ôÍm}țƒöpȘ_n€†ÓyW7ŠĂčŒ‹šÿÈ Űy„•ÈÍö:ŚśpȚ=†[ƒÜžż 7†;iž0·çè#űąú˜źźóĂ»Çp›ÜZ)ÔśpȚ=†#·łÆcžôí$čazä֑ôz'ŸâúőŃûÉśêœé°FȚMő^Vëö.ÈmÙÜÖĆùŚ;ąoKŸę|ŽșŃ=? ·[[«{í ÿćôòțäû¶ßśleY^·ńźcï€țÿÆdnśßwôœ:7Z?śàËČ4ï<‘›ÔûŠâ_‚~Wąíćéó ›ï{ —~0ę^ÖrŠNšŻôą#ÇâĘhă)5`dqÈÍŰgčŸÿxčù7ńĂü&ć>˜ÆźnÎ(‘«Ûw°Ć)Ï d]œë™ÿÛâĐüÉMÂ_îűĆêśűœćê”ćFč8.NU‰ÜŸÿJ_3ęƒXÜÛšü‹0óYŃÄs7ÿš”űq9Ïł–Ű^w|°ìƒ©{u{88C:ƒù ™?čAÜ Dn"7Ę/·ÍA'f‘yÏ*ń€;žùo€†u*9šc˟țîæÉŒîš;šisËlmȚëò^¶n•|ûÛ wČùtùŽŰ»0·ŰțÊs=Öđ“ć@ï_ÄßäȘĘȘȚŻúüo€Í(ț-.Țk:iŁææż!őÛäù\wœO–o-‘ó„öœùîPő~ŐĂ»§o`ȚMÜK^;bŻ#Êę/u֒§ŽO±ę•ïČ~?čl2@ï_ż§?CTn}öŽćőQƒ7€p^n-śP” țJ$ŽłÆžč-îïMÿiEż”<çÓá~Őæ>Šr«čĂi1lnńę•àčÛë–Țï⊠ ïłæ¶  Gvèí~Uâč›;J4·.vÄ ›FDn"7‘„ÈÍÖfÉkè:xư»…¶űŸ,?OŃ[VŸæö.ÈÍV]n­[hÁ[êó”违C!·6oĄ…ïdüœămwę>zœœúoí8oxïś|Ÿ/3ÍÜObííó’[“à SőÚâÿaîoJżĂrîvqȚŻsßËóĆ?êÜ43]D¶­’ë–ü"¶.ȚBûŒĘìWœl ïÏÏ-úNđöąššfź źn§Y#IÉ¶ĐŒ,țËĘ_ÛKôûRÓÌF”“ č5éf -á{hΕÖčș­țs¶ÈĘúčń“XčAˆÜ Dnê.·Ü‹ì‚OG_é/«ś‘{óćÚí üś­m‡¶7xóBföŐꎄŸÜÒČ«ÔúWêŻûûńáż&ó śÓćûjŽE™[_„^ű6ĆIÛAçÿ\–|_­Ćčm¶uÖđëàkŐÛAßśËçÆ™ÓàȚÏŰȘžŽÿ“ ßÀŒ›$~rÁ;êsśŐž_Éÿ?:Șôêö9PwŻçőQxÆŒ›űç(łäÿ6 ¶`źÙjštäêæŻ„ś«ȚWkqan›č;Ÿț•zȚy=m;šeÒu?—ćLÇ»‡ÓöŐZ\—[țU{ńđW©~;èłv—nŐN:ńÜÍ%ü!ç+śŐ ]æEn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒP$7çŻê'7˜ÚææțÈ Š6čEț«^€‘0·ŐÿÏÔ=Ń ž1ęrû}Ž«ŹńRBä!ȚwƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAˆÜ Dn"7‘„È Bä!rƒčAh“Ûș,à‹€‘0·ç/ŒÆwYÜCìÁôó{ĄŚú ·nls[?ę?Oÿûd=kŁ·ž1Ęùêv‹YÜÏĘ ”ez‡ë„ÉżïFn0En"7ílbŠŒŚ>žčAˆÜ Dn"7íęy·ŃÏÔëűGŸĆm„È BäĄĘŸUûL}ÿ,ŐĐłžrƒčAˆÜ ŽÿsŠ#Ÿ)çO<‹!7‘„È BäĄęÜ>S;‹;!7‘„È Bč {Šüău·Bn"7‘„È B%č zŠÂŁsśBn"7‘„ŠròLmyÄYÜ čAˆÜ Dn"7•ć6à™ŠńxłžrƒčAˆÜ T˜ÛpgjwBžčAˆÜ Dn*Ím°3•:Ú±fq?ä!rƒčAˆÜ TœÛPg*}Ź#Íâ†È Bä!rƒPyn©Ü‘Ž3‹;"7‘„È B䥊܆9Sùăe·Dn"7‘„jräLíćłž'rƒčAˆÜ DnȘÊmˆ3”Œ#ÌâŠÈ Bä!rƒP]nœ©’#ìwEn"7‘„*sëțL•_ïłž-rƒčAh“Ûș,à‹‘Ûw‹Üșæöü…śAüöĘ"·źĆLsču~ŠJźïYÜWțÁôïŸ#ęÀčuˍ)~Aăê[±çnácßĐ)rëÛ&·ç?rÏĘș>SćÇÖó,nŹö}·ŸOčuŽÜ Dn"7ŐçÖń™Ș9Č~gqgä!rƒčAš!·nÏTĘqő:‹[#7‘„È B-čuzŠjȘÏYÜčAˆÜ Dn"75ćÖć™Ș?Šgqsä!rƒčAš-·ÏTËő7‹»#7‘„È BäĄÆÜș;SmÇÓÛ,nÜ Dn"7”æÖٙj=šŸfqä!rƒčAˆÜ Ԝ[WgȘęXzšĆÈÍò8°ƒÜ,;ÈÍò8°Ł=·ŽÎԑ#ég3 ·nf1rëf3 ·nf1ƒčusŠŽG/ł˜čő2‹)[/ł˜čő2‹)[/ł˜Â‘Ü:9SGąÝÜ:™ĆÈ­“ÝÜ:™ĆćÖƙ:~ =ÌbäÖÇ,&An}ÌbäÖÇ,&An}ÌbÇrëàLYÁőł˜čäf4J›Ń(q0·ËϔÍę_=‹i›Ę(ŰEnvŁ`čٍ‚]äf7 vÍíâ3euïôŠAnŠă ÜLÇA虎ƒŒĂč]zŠìî›Ț$ÈÍz$d›őHÈ 7두q<· ϔć=ӛč0RÈ턱Bn'Œ…r;a,€ävÙ™Čœ_z ·sFCč3ą¶čĆY0†č g“ÛșTçfćE•ÓÛùLźnËRrĂőQúJ·lóŹì^‹Y‡­Ï'rûüâ±æÿ•œăȘûáo4yeòZăƒÏĘ śòmŻnÆupu;ßÎŐmźçnäv¶Ï»/~«>كËdÓœÀ67䀘­ÿlóUû>ÿ!·§Ùæ«FnŸé&,őuÉÍ5ʄ„È-4ߌužkKnžùfŹCnóÍX‡Ü¶&œČˆ»{EnoNY„ÜbfœłÂên–’ÛnjsV ·ž)'}:ż3rûšrÒ§#·„)'}¶Ïą’ÛƜł>č%Í9ëS}—”ܶ&ö‰È-cÒiŸˆÜrfśYœM ·­Yç}r˛vâ§ŰțlčyŠű)ÈmÇŽ?ƒ»˜ä5ïÌí‘ÛźygnÎ[Jr‹›xêÆÈ­ÀÄS7Fn%fž»%É-aæč["·"3ÏĘP°Œä–2őä͐[Ą©'o%\DrKš{ö6È­ŰÜł7±YBrK›|úÈ­ÂäÓ?n»€ä–1ûü"·*łÏÿ(r«2ûüŠ,čćLż‡[„éàˆŰâ‘[+ЎÜȘ±ÍąKGny,A+rkÀ4ÊEn ,A#rkÂŽ!·&ŹA“ÄȑÛĄč5b€Üv± őÈ­«P-čd䶏ešEn° •Ò FnûX†JävëP%ł\äV€ušBn±5Èí ąBn±È­+QŽÜc%Še—ŠÜаĆÈÍKQ(żPäV†„(Dn&X‹";ËDn…X‹"äf„Ć(AnFXŒ{‹DnĆX}äf†ŐŰ”»DäVŒŐŰEn†XŽû DnćXŽäfŠőÈ*Xr«Àzd‘›1$ŁdqÈ­ ’AnÖX r3NJ$- čUaE’șË­ïáȘÖËô–·źl@r«ÜĂ5æ¶.Ë#űąĘ1ő<\áxĆśÚśl­‡[ÊÆ s{țÂûÀò˜șź4·Â…-=ŒÒYßÎzžöÜ~ßÚwWćV¶Č…·+~*œÛČń..’›skŃ@±0·ÿŸàŐ~Fù“â—ŠĂ]t·„Ăęnïü‚Ürú~uŐs·șdâŻLSpAƒčAˆÜ DnŠæfüȘÁüEÈE1„ŁÙ śššÙˆ§ Wu:b75~OÄü-Û<Œă”œíkąf#ž2\ĘéHäf|FMOií[‹»Ăfü›k}śat:ŒśÄß˚ÓÏÍöŒÚ>˜źÆ»Ï »źLíNÇŠu§#š›í~–ù3­Ć:ßnŸ:ŒNšÙéűôaä}tKĆé=włeț`Úwnf#ž‘[ʈ‚WŠÖ—#ó'śĘ>˜Ÿ‡Čń5ŽÙéX7ÌŁà{xß :ä!rƒčAè_ž«Ó endstream endobj 145 0 obj << /Filter[/FlateDecode] /Length 1209 >> stream xÚ”VÛnă6}ïWèQ"Ząš[°(m.HëhȘ·¶(Y¶”ĄDUąÖÍ~}‡ʖœ.‚&Û‰ə33‡ă$œc~wű;|Bęy>+ęÉqȚ»őQț Šyž§4rÇł8‚‘ăGALÒÌ)gqßäΔt~ùo|,·ÌÉIž8ĆÚ CJąŽR’ÄNqę›{[oÆŸò@čù„ç3ÆÜ„Ühs;!•ȘVžș«ŐGjk7ôMÉ„”ȶži(ûșSȚƏÎMńžiÛc°™ä±1>Ӝ°Äêùàsï*„êV›œÆ.oW8šÛAq!ö htÊÜÇJÔüIT(~…Ș”8]ÖO=ï_Žősà|0 p 3ćæöÂËš+”ĂÔĘTê—ÙÈü Xœź0“•<ÚÊÜ”Bz4žÛÍć›PüX8Q@ÂÔńY“á ÉŃY3FI–)_Ł­|…>îí{|XąĆƒûÒú[‚4sWvșîeƒ#б™ÔƒJ»ŸȘRY ßXuźî0Űă Ć`ăÖl•ê.‹ĘnG„—ŒëțyêJzqàJ1, œ8t5Äolë ;’$2ĐŚ±;(ߍí—șłž”¶vÆÖى«x„f ”ég <ˆźżÈœZ«ȘŸò‚[ŒæÉu’Q«șX%æƒÌžLXŠ ő‡b&ïÍ©$$1&z—ƒò[ȚNWòŒ+læJčï65 KÍíìuSʅŽÉ Ä~Úb]ßœi6‘ †ÊźŚküë(™dNf€‘€BJ룿!MÂO9&ÎHb”ê/eÓŐÂ0œ­ XŽ —ȘŸ—ę`†șĆwh;íšs?L~ą˜ë,܉j0ښlz‹Аżt^tœČk*}‘ŃٌTŽÂŻhĐ;eŸęw€đȘZ¶SrNŻÈ #xŃŠËŃÒ ž*V{ NÖČdbXŻ—Ÿd8}«6eyùMȚą)Obx;)bäß°lÿÜ'îśxŻżü0sđëeKçaœ5°j `!>dmY]èiìîŠ<„žoMŽ?{6Ê 1žëÿîÀ)%Œ…&‘`QÓ%ìCjym7!Œ \ę͛ÒdqŹÎ˓șÆ †ĆÌńŚÙçrŸMŃ3 1ù‹ó ŚĂ0V'#\Ń@í}ă€æŠ>”™,ûÆÆúMŹÄż'dA6Hțr>Ú·źĐF_4'!ƙœœDφțŸjóŽčő'< ’9ćĂôP:A6ń?ˆĄæ™Ą*ȱ§A9­Ç™ÚȘŒhĂ­ôńæêúáæ'ś?ÿZhjŸZ.Q«R%9òb+uÙÒ49\BÓbŰjcŚY§W—z)GÆû nšO-ŃEЏ„-q-Ńi‡çYÚ1Âé,hS.pẏiyÏâúbŽBÍ‹|Æ)WûŁ‚=kBm#HS’e¶ LƒĂ¶„œ7˜ìßL3,46ЁcAœŒ‡Š3łVœ­ȚےPŠSÓ `iŰÔŸJÖČ…”§śž%›úKőæ~ÖČđ›W ő ŸŸ†đ„3쟂łOśwÿÂ#ƒI endstream endobj 146 0 obj << /F4 11 0 R /F5 12 0 R /F10 58 0 R /F6 13 0 R >> endobj 147 0 obj << /Im9 142 0 R >> endobj 141 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 146 0 R /XObject 147 0 R >> endobj 150 0 obj << /Length 2023 /Filter/FlateDecode /Name/Im10 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -2 -15] /Resources<< /ProcSet[/PDF/Text] /Font 151 0 R >> >> stream xœ”YMÛ6œûWđ–ÈČüț8iZEÛiö’ŁêŐîș”œËIß7$%R^'iŽ-‚…ćьLÎ<ŸyŁŒc‚+œ’LĐżöËz·ìgüĘŹȚ­ ŚVK•nŽŚëûárőĘžIɕe—Ś«-™‘ ™7’koŰćnőôՋ—ż>»ü śč,Bó(,“[GŠ«ŐÓ‡ž}ìÉśBsĄSì.Гpÿc·9nö7ÉÁqŃs‡ăúę뒋Ž\ç.Žv}w`ÇÛ~Hż„h'^ì~ęśqűžnÿtčzœRܘà4ûˆțŽż Ö/ځiśl·òÎq#aPRqǶŐC(ƒ€EXluč]œ=QkE>Z Ãc6(îœfJR"$;ôđüzEf .%ś†JS±P‘—Ę~Ęo))]%„Óț[=œ»NwSČ:$”2ÿìIJđĄ_ś›=ëęńĐí‡Ęf6w{SÊWÊÒ|·;l?!TĘ>6 I­"Ÿ&+êĐú KKȚ¶‘‘GËuÂèÂĐZŰdZZ±šh—ŠźmČ+àÔÂ3F \ÇÆS ‰j5YÊâÆ.+ł‚陣€ĂŸêüË@UÄĄJçáì‘Ö·ęŐûmőù3/qzRä&`”3·zXêÆ”æÆŠł!čULygGCÙ čN'Ă&*™hüR‰i2yCłBJ:rvšőîț~»YwÇSYŃë,ćÓA‚^GŒ›,”;AàKv&OÄpm«…TšPM3^;&ÛăNûŠŒÔI]#F» †ZJSąì)›UËŒŒßûŻìĂČĆOĐh@Îh˜Vˆ`éĘ?‰žoH7ŐÈù|ž0ûÀȘƒ…țQ2 Ń'K•Y;ƒÊö"•ЧÎlł­G«}oiìBĐą» ŃthKă«CÄŻ4AŸŠ6čœ}ےxî%‰4 ű ‹±Â‚&„ÄčÔ ŁK!»í*bmšDćäóï†ÀłŽQöiM•p™6LäĂC ušÊtbŹąq•NöxkžÓ jáѧdĐŒ’cž”OęԃÏž›=ÿUš9œš§ÁHtJH©æ”ç)u’‡Ÿé͒U§T1ŻSșÇB$òH"ēü`ìG§ż`7Ę=Űl`Wę±_ƒŻűiJÚ nzę”g5bĂa|9G¶íĘ0Șçßç”¶–Š6Y>§rŃêii9Éos [9št(% §jòÚö„ś›ĂĘûûF FC E$jnü(G dNDížšËČïÖÇͰü9(íúʟꁏiśrXŃćÀPZá_wÀU™yÛ­ö#%æ­˜Č—GiZjMMŠ6ÉȘŽŃ2ˆȘőșż?Č]? ĘM?uŹÚÒ4nĄŃIeCo B4–Id•4ÛćÌS(źèhT ÆîÄȘEd-ŒĆâĐ9F–Ž93YêêđdbűÂç'D ©m””.PW·,vŃT€]L$iˆsŒ-CűőĄnÙčśôÆȚČ–ÇŸćęÚÙVÒ]}ÀŽČp:ûÏwTP‘ȧčśêGŐŁhšÆ°çÆsäĐ?Ș§ÂèX;ìÿĘÓ&|œúŁEó endstream endobj 151 0 obj << /R7 152 0 R /R8 153 0 R >> endobj 152 0 obj << /BaseFont/Courier-Bold /Type/Font /Subtype/Type1 >> endobj 153 0 obj << /BaseFont/Courier /Type/Font /Subtype/Type1 >> endobj 154 0 obj << /Filter[/FlateDecode] /Length 228 >> stream xÚœQÁJ1œûsLIg’ÉîÆ[K­š'!7ńP–t]JwÛș țœÉÁ‹ˆ^æńȚŒ7&€:˜áșÀgĄ\ößȘwżț‰ù”hí*öTn:G–+ &;”sVهö‹›!ŹGžÿنUXlŒö„z͔æ6<+ë±é»—s”ÊZ+/„bf±”ŠíԏĂsî1mśÒT"…ŽC œcûŚ~è Û6»žŠé˜Y-R°q*Ž)+oG©Dùná*üÛ?źĂ:WՄšx>€Ą/ïű}ń€@~N endstream endobj 155 0 obj << /F4 11 0 R >> endobj 156 0 obj << /Im10 150 0 R >> endobj 149 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 155 0 R /XObject 156 0 R >> endobj 159 0 obj << /Filter[/FlateDecode] /Length 1702 >> stream xÚ­WĘs›Fï_Á$=2‚rƉ#„jmË#áÌtąŒŁ“Eƒ@ÈźûŚwśöűŠÓ€é ìĘííțvo?î4Ó0MíA“żôk>~ŸöÎțŠi?°ő}0œ:ÚۏŽ`«ÙŠayÚÀŸ„>3ËĐżżj“ Łă} 9ÜđÇmȚË0IâôAێËʝÀĂéšîZÆhŹ™’wqœ.D9?”q–źXœê6g%ìŰü6˜ÍoÖłg8öŰŁn[,‹7ŽúF-Ò-î±wWw“•NŠÚVx†ï*MÛcĄ–3iÈÀvdžëhË2Æźdxډ\œËUSpÛ“95ŽsŒärGa) >í’šLZŽÍžu@•q`±'„©Î}ŠXˌț`»Ą|0ìwĘ·ŐÎą0%b›ӍÚŽìšá,‰‹ČBU!o,’[lÛfù> ‹ÒŰŃh'ȑvŰÊŽD/ś6î”LéȚsÜÀ™șë°09 šŻ Æ”Sƒć¶ŒôÁÄR˩̑“Y7VÔIHH“?Ăę!Ą#N-«Í„ÀG’Ë0zŹŸŃ.wÙR”„ M,&ÓĆdùË:˜]O4őfűroœ–Ž˜‹m.ŠĘșŒś"ż°Ì·íX鉿ùg+ö(ƒWȘX})r„żmk?5§ÊŒÊgÎčaQTóMès•ŃĂ±Ăn%rqu †CH=LăDŹX„)» 1ÖÛSpì›ĘÒjfUq=Ül GŽÊëÌ*ęyIó2ŽÒ•è28Żƒba¶%ŽÚ O]ÊMđxži@u—°QdĂdUmû’‚ê”cŽYS6ä9Ă$\_šôÊÓł?ŽÒ0˜ź3ä NÜă'<’]łô§RŻłÛu‚*ČćÆi—±@ŠőœìțHa'X‘‚Â8„Ć"Û ąê^„|*oqGš8ïćqUrÀÙ>țKƎ\„CßûUœđ=Ùé°ĐŒM‡œ«Ș^Șlh™y »c›Ł –E Û,I2Žă© »á 걩PMU}ˆÓ”Ò¶ÓàjXÉ6ŚűQłčÒeûœ +ęü?]œșŚĄátŹyÆŰ“šnF.¶/ Ę\7\žëŽR‡ő­ԛŽyHÉí‚ćČÓVMÊ6ś{e>ÂĄ4%cl8ŁȘ5~š,–pƒż»Ú*RäaZìăąPX,¶Ï6p§X&<&L‚·?ŐŒb± an„ŸŃŒEżcJ\ "{ńîfy=["ŽőőüĂäąJÇ>,ȘűżK[“XšQ]‹pKț E ©MX† Öźú”łQĘ:OőaČ ÖłÛ Î]Ă2žaśÇ·<ÈJèȘ—Îw Âÿ„ëvŸ.\Ó4{@ń^œș!‰Ő̖ ȘN#”„ŃWQČê$!©Cl=k„Ž ‘©(ŸČükÊ žș°zŽt–BęR„3â đâ[‡È‚ÙÌ܃.Ùü%g+HŹl{jP7ä^ŻXeŽ ë8ÊĄ‡@òmŠ źg—‹ùòj2č…ĘÿđĐâp›Ńp=ƒyƒóȚ—ÖO‰¶” endstream endobj 160 0 obj << /F4 11 0 R /F6 13 0 R /F11 59 0 R /F9 37 0 R >> endobj 158 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 160 0 R >> endobj 163 0 obj << /Filter[/FlateDecode] /Length 2150 >> stream xÚœY[oâJ~ß_ÁQŽ’Yo`)+‘ ™ĂčÈd/YĄŽiÀ'Ÿ ۄaęVuUÛ\Ìdöeç!n—««ŸștU5Ó°LËj,êń•ŐÿŒŐRż5‡[ݧŸn{ ßìùéąá9f·Śhyłk7Š_țe\ŒÒełŐvmcF’VkQŹhŐ‡cÜ?FD˜‡čxŐ|Qș\† o1ær!6QńÒlț{ú·†ŐhőLŻŁ”ŒŸÎn‡ŁÁ•Ä_mÇôéóĆX$ó4&9Ó0–YNë/a^dáëŠÓäsłe[ڰèÓ& iÆ{lzÈë4‘IŠh‚ŻtL‡wƒńìËp2ݟŠĂ‡û+«É(Ęʌ€œŠ›dÎźI™V 8òÉR&2ˆLÛò*Ł(Ìe&óŒÆ„dôđ<_9Vˆ§őúÿâéń@ŰV-Š;ńƒD%›űUăILo9A(Vą Z Xś+çG±8Â.E°ÒIŒÉÂ䚆ÓèźÿśÙ}ÿźÁKûŸYśìßGăUȚ)=3Yd"ÉăQ+Ű"gȘŒÜ]ƒłnú7żf“á?'À.öMâÜ]d:Ł”ÍŽËSO–Jc0: JÍË,ĘŹ/išÒäćöÈ>Çȋ4“•Ź3Ű>2I}zìß|L'$śÔ[p|ž.~Ć$‡Lb‹’#ÖtHÊÇđŹ_I‡‹s¶>śÇśĂûݟYŁÚ„v˜üŰ:EątK‹wmd~NciÆ:K‹4H9őb±c_Š0úí·ŸZà—)~éÊ«?Ąƒ€Êé|ł^§ÙńqKä–lòČšêb©6ÏOÜÌyfÔûù ôûÁóìi0'PDÆÓÚj:YiśńAËóČTćÔ­Ò#?Șì„ʓšƒŒk2íOĄÈo&”ˆ°»èČPl„LÊJ5/;„±ća‘ÉŒÌü<K™kTçKëxp;L~Ÿ© ”Ș¶Ëä,(ገȘż9äç#/ˆdÇĄŽR]śëô_ąx䬓ąÙgiÁÎĐwűĐF”XϝŒ•öhĘ6æ” 8z˜Lfă‡ëCŽÁșî‰h+vč֑æòĂ#č3]úlKG6á»ÖÍeûR{v~^ÀáÆč(ÄŸȚ:W«NjeŹĂÙŚńș)—ș Öâ5ÏYȚ_: PććIs‚^˜•#œÖ%‚ ÍȘC  `–łê?DŒŽ€ÎßrÕkÛ2ę_cSßÓ Ÿù- ïZ><ÛUÁțXÁI<+ÏÏ!UĄŃžÜАbáì iA–r%čԊe;€xŻòł9áÔŁAÿû`öuüđô8{î§Șю+zŽ-őïŹ“đ?ȶŻ;ą‹ĆÙ9†ȟW‡<Đđ òT‡XŠC…Š”śűqw­‚Í7V;Ż»kĂ)֗æ©/Ç7ßgŚO··ŰíÊ áJ§-ûđÓ­Śè™œȚČZŽgÂ-Ëîš^ÆífŚ1 \««ŠÎPŸ7ߐDQp\«g›,ƒ _ úòȚl{NôŠ~A>Žń™ź©ŹâšÆ5\•âÆw#ZìP$Ž?($ƗM΁)Ż·);:„źÓ1.űByán¶”ĆƒR©îèHć«ó”lÛì”óĂ#^±.ߑ) ! .8à/D}oÚNÇ菞Ô>ś]gwÓńYćb“ÊÂc\młŁa™ô±Ę`ćè}ÛÇeËń2”Mʓ펩ôž~ÛË(€ńÉő=ăź:TűńF%ź^Œ,šźe{2‹ő:æ Y.ʶ ŒË_a»sížj{źcaN»ŽêŠk„HF„4ăŸtځ śl‘O°Œm…d–?(ž~H*$ WX<ÔˊUAJ˜Ž"GàŽMíHǜ<-ŽŰ 2°yșÉŰé9°7ÁÇ0šđ+Š„_Ü5˜ș ,ÒÄH .$”ŽüúXûÀ óN&Ükvxn°™úu†6$ȘԐŚê‡‹=ÁȘ,3őEs-8ČŠhĐĘꄟӚOl»ŒźŚ3á­Őîxf—ZA,Țäù­U^űźéz;Ńźër=ĂՑŃG9ßj·M“:§Młș­ƒÙuKĂÏŠ%‡Á;.AUËs;êv@+Bƒ«0 ‹P8ńzźÏźzćZdâŻ@ŒŚ˜3ŠȘrąŸˆXoKkąÍǟ©#œJ#Ć.ë’o6źGlÎÉR\‘ê“Ł=]œźî˜-ŻWÎJHæ@çŽhiÔ)tѱB)ćVW$s=:Öú97’ł‘ED™óú̄™ l@—ș0Uááv!m`źČ^0kêۂ,t9Sț…t« č.C‚ĆZy )vP”\éI[Ą Kà ŒXź·€ŻžTƱXö8Ź@6Pa#Jźîś(°*¶,ë=L7 Fpl·4ùÙ0»yû¶=ŁÎ(q ŐÇśșŠbKŐRQ#"Ü"Ê t㇏ŰoÁ3ùUWü|Đc~ő?ź§ &Q˜b[Ÿm™¶§ÌqÜچő§ÿœąrÇ endstream endobj 164 0 obj << /F9 37 0 R /F4 11 0 R /F6 13 0 R /F5 12 0 R /F11 59 0 R >> endobj 162 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 164 0 R >> endobj 168 0 obj << /Filter[/FlateDecode] /Length 3196 >> stream xÚ­ZY“ÛÆ~ÏŻà#š2aƒëŃVŽ.%¶”’Ö•JČ)–.áÇź6ż>} frmiŁbĐ3=W}‚«À‚ŐƊ?ńĂț„űs‘úŚŐêÿ`ęńúû+”*ü"]]ïWqà‡ÙjŁR?WŚț—úë_ÿeőæz±Č„›ŠüŒpÙzĘìÖäȚùgKÄ~± hÔí:ÊŒ§ő&N”7PûT5wÏ/†Ó,a-vJK>Ëjځ% ]ζ‘-46ïÔ”ÇÓÀÄ'ÜW;òËcUŚ<ävœșŒ/û{„w¶c·ĆYrÜ<#o7œQNqèÁ­/ڐs?æłä•Ê<[ÜŸsŻO,ږŽ„$<če‘3±Ó„t—u šI#XÖÄsĐLêeŚHÄ]Ă ;yE„ăîžEŰÊá; d€|}XŁúTuy[kȚo9đxę蛀!šÇJT‡5ß RH;`ÔNžË_Ùɒ]5L3—2ÒAHSq2iŐlëq§ÍÖôFqȘü$ü ”ęà–°ŰÄY᫔o"„Ą)[ŸœŽ_k0I˜{ïôçÉæq’qP#o?țzuőńí?ßđž ?ÄÊćȚ±ü\ĆÒŃđŁîûòNxûêżf©żŻóÈ,PÖ}Ëì;œ­é҈Ü0±"Ó9è;Ű3Jv‰…»șœ-Ń&ƒą˜@őșŠÁ„٧ŐNó<ŐțiŠȘ±Ś3\ Lb~™śĆ.óˆĘ‡á`\ ƙ(“œèôVW恰+‡Ò3>Š "puĘ"Ï#aEĄŚúĝ€·@!%…wŃKh †Û6(©»±P!‘Œ Ț¶Źk™;ș„š(ü$D}űć.òZfœȘjœW$û±ÙŠșÂFę`Š}l7iœáyÚOlaVd€dÙ€dHĄû…gՀö”5€Gè$ž"‡ț̔é\Š{y.ppéÓčœ'ÊîŰhÚwêę°Hk Ä;Ú(\LN@§ŽĂÌÏsśÔż”‚ž͞CëĄBuERÀțš{ƒ„—ЁŸŠö žÀOÄŸ8Gûaqá z?đÒâü„s`,\“74ùwłfăkӏ‹~î p@‘–Š Çâ‰!êqCܞ9J[ëĂˆI,—sȘ‚,ržœć'U9Șț`Ś€Iś#ȧÜqCŒ5f(ŠÔÊö±ˆüđ9[‘R Žv&¶^Yű™ŃȚ°ł9ÛêâW°›9&e9E†K€Î§r:Ő€·%)p-1+[ž"Jk€FÙf&j‡„ț©(n"@˜Jy2Vb掰ĄgjêC°4àL#Śää"âĐfĆjJțŠ%‘-áËF=ąÈ!űûš…hBxÉü˜Ta§ÆŰ‘gą—ȘÁ:uiÇó3Ÿ°LOëȚwà|1ŽÌ#7›_êDT|Ę-3<ûuÉćœ“”<ÂXÆ{© gő')űB§œčA€”dź@ 6;ĘőÔ,N“Ś“•œboêšŐ)žîœ`Ő9JÄA f J^AÁ]UÛuxśüÚé=ˆüÊÏd„èąLí|’#nÓæÂwSœÌ ŸÛ‡ ëœ}á9č$›€¶vLùxłę>èzȘÆȚ/nü{?W·]Ù=Ą‹yéŠïŻr'Ä„Č~@šŃ-ÜD*úŠÏç…êÛ Äf`äe‡ŸWrïŚöšòšÁÖ.KsčòSe?nDi 5Ă()LŠœŚ ‘Èór{Qà~ &يvŃLùʔÏìîΟÿ„~hȘqŸűÛ"ńŁ™„ ęĘ‚PÌ!ń*m·@Ÿ9 ż™3ÈŰŁŃșIcZŠúo)ś8F#țč[NŠ@%tčA8ăǰNŠ_űá$C@čw[Ą?* ït<ŹS8[=^@Bäöș7ŠÈ6pŹÀvƒÛç2Wdƒ.Ë> endobj 166 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 169 0 R >> endobj 172 0 obj << /Filter[/FlateDecode] /Length 3129 >> stream xÚ”YYÜž~ÏŻèG”1­%êò‹aŻ8Áî&ÆȚÀcj‰ĘŁ 3žüúÔEI}8딓—&ĆŁȘXüêbŻ<ŚóVû5ïž™țÜ_ęÛjő[_Ę\żMV©›F«›Ę*]ź6:r”șyęÉčő”żț|óŚŐ››.ž1š6jßMÒćÆ?ÿëś¶lȚuíxžuòu œ»Ź[o‚$qžíqô >RÏ)œxæïŽĘp»FźŚoőÄA„±%+šo`];È{‰3ÜîÔk?rÆj(óŹxqăÙČ0ÍڏĄŒőm ^°Ć=Oܟœÿ;{#|7JčiHÌłąèLßă2Ć'A•7ë"F%Č ûn*ùŸǏĘ8EYS01a üőđU&tŹ6ÄŸȘ ±kÜőFëÀù`†±kzæ"ì|§o‰_ŽȘčÇCŒŐ©Ÿ:+f&‚=–UĆŽ¶DAè=«6pű~űdŹÎÈw=ÍêŒ,RzÓCË;DŽw&ÀíìÆ&ʶéĘ#4țÊSύ‚ïAùŒq’ęvcí‘BáÔûû5ồpŚ©ó€CmYđșgÛ˜Nf‘ˆg‰đ\_țۜ[ƒŻŚ gkđÓÈAIzìÆâ[Pê)pÂÄŐČofpJ4*» đ4":íŽIِń•šîrq„»ź­Ïû«ƒ#΀§Óc„ź—Êš±/›=ȘQ PęŻŐżÔSîJiW[c2`1ùœ93?tă„Ćx ‹țŠ›¶qÆœV΋çc0vńŽäÎî(, ‡çŚŚ,+$ÈÆûÜ5Ćű<ńEnš©3Ž]œ’€ŽÉGä`Ài)ˆ`…b7ËăB„ĂȚ"™ä…žH‘7rFąX‡Î<”à•Ș'Ùg6—ƒÉčÎÙEgĂYá / °˜h„äh4aRn7ü9””čšó‘<zs„íšAzŠŐüŰ(ÄdDæŠșd;ăȚˆ0u;2­žűĆ â·DêĘJćźù’Ő‡Šä =ń±›łp Ú1ŠéïÚABC 7 ‘dȘzJmJNUéEp‡©Țìkč/Ò1&Sö)‡Ôà#ICđqȖ•]D 'ä-ìX‰Ç€FN„YiÊ*íRčušv0öoŽÌ>Œ±ž B˜Cb‹utą©֞ŒœÛÔ,n˜Örq-țq’“‹NŸČŸkI^œéùßR†Ž…'V6VïŃEJÄËE|KDÄ„±Se]>@Á%ć'șÀ>=Ó:bjë{˜’ï đk#Ôxób)x̞]ŒZ3«XRÊlcLAÀXŒÙ:űô8P}ПYŐS"N»’$œ$èôŸH–‚ÉOâ/Ą(űŒIk—ÉPhŒukűOŃ=ŠÎO,±ÓI˜ûŠ!'[­e%„m‚ŠûI)—/ŠçGn%ûÏôvĆU…$Żá\ԙžMËÓ6Táî;A ô1Á†ŒG>©‡SJ~<đÄa@ûI&cŚÎÛr?vÂLÉ*p­œ™zà.‹œ‡DHM*q{œÍž58öŹük@ۂę§Ä0ûFJ7ź“)n?ž‚oúˆĂï^-ÊÀxȘ5—ĄCn,Ąƒ*SKdaÇ:ž*ÔiZž'‹|À5öaë,t[‚ žę}ŐnłŠûxIš&Gs 5Ú(A!Žź :6CćŸ–sąđ0œÏŽÈÈŒŻł}Ù»žĂTj·<° .zhö_©)ùŃ/©+.##_č™êd•7Ëùč0«„‡!ó9H(ëì`đ„ПäèOöOœĆy-çNx“êaŸ“Ș6Ąíą!bê*ÚĄ!4n«2°M Ήs+œŁ$‰"2nú‰°ęž%Â3à᝭ŹÌžéĐlq|’śĆ1/Xióbù’”bâÎW/x€ó„›:tí¶25ž;Č”Iä±_ą‰(æd.!’ŽŐüßA˜Nÿ•Dôۍ œc”Ét…éx ,ŻœźČŻń)ˆèGGȚ5”wŰ<œâ€l"ëÜ Z»Ó‹Šfjp_cSŽŚ IŒ1òuuŃ=NȚ‚ŚźȘmÆÿìl@Ï-â]Jê'^čx6˜ę¶0v~Čțg?)ő™I““ÆĄŒ`IÔ r˜/‡*k8Â]șˆćMrvo+Ö~œKŸśÿ••UŽV›Xy¶đòËEÎ_țĄęu endstream endobj 173 0 obj << /F8 32 0 R /F6 13 0 R /F4 11 0 R /F10 58 0 R /F3 10 0 R /F5 12 0 R >> endobj 171 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 173 0 R >> endobj 176 0 obj << /Length 300 /Filter/FlateDecode /Name/Im11 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -34 -666] /Resources<< /ProcSet[/PDF/Text] /Font 177 0 R >> >> stream xœŃÍNĂ0 đ»ŸÂÇq˜‰óćôŠ„$}źëFQ?Ž”hâíq;6•+Ê!‰ûkăzDCÖfbÍ4–›ČKȚ§èđ Œ5|‘„mf"‹ÁxòœĐ%ÇSïŠ_nĐY#$ŰBŒL†í”ĐLîjŰeÄ~‰~+K„ ·PŚÊ€ àž\púdêč.[|ÈáțMP(IÀ|—ŒQJYBńžÄg˜·°:Ôc”í‹Óî.ÿ„”'Žjpí"æ;X ŐĄ­ș±럛ë«.Z\sąm˜Ő©jêbÛTŰ~5c]Ă8Y„,>(œ0±3}~ę‹sŰhní,ą3!‘»Ävä#ß*SìEŹÿL?$6jv™#š~[4XöĘPcŐ•ß·F6đ„žzë endstream endobj 177 0 obj << /R7 178 0 R >> endobj 178 0 obj << /BaseFont/Courier /Type/Font /Subtype/Type1 >> endobj 179 0 obj << /Filter[/FlateDecode] /Length 3029 >> stream xÚ”ZK“ÛžŸçWèȘjD űÊmÇ'Ț­]ï€\©­MAc‘Ô’”gœ_Ÿ~5gìȘ\†dh4Ę_?4«(ŒąŐ~Eïù1ÿQűçăUêßW«ćҗ·/^'+„Â"YĘîV*_mLæjuûêŚ ÍzŁ”6ÁíÁź7q–Çz'oŐçê(ŻĘŸ&(ùóTVë8 >źcۑ‡ê–ÇFÇèöûś/ŚżĘțíĆkł*Â"ĆĘ7 ”ZmTÆ9 @Ûê€ –:–đǎs‘‡E|ę<°ûș˜p°-ż•ü8¶ç·m_"Ă{áWÊŒx$iđo[BÀYŸÖÈWVŽN°q_ï–Ìêv/ìz[†ëŃQđÈҀ(0gŹ»Önńô+9±" À‰K”?ówŒ})EÂĆQÊÂ%"\eACÛ~Əĝž§–üšêŽClŽŁő°ŒlśÇ‰;“Gû0ò3"1dă^ž¶Ț~(Bè‹ó#áÔŚM=֟èÎxúÖU_‹Ź€Íʁ„4Đ”|.¶|!óQiïsyDœÆIđÓіƒ;Ú`/€Ž€H§roš{ĂŻŚJÁć ϟ™òkü›;ćörśńB~m…y*‹(q‡<Ԕ·PrĆ '˜@Çsç퉳¶oËăV7Ź 6”-4ÄÙY>E%H9ˆ RÎ}+YHSrœ Ÿ 4čœRùHƒíAžÒ±M»9Mj>óułŰûbùça„<‹dđ rȚÍéU+ÁE2±”Ș :˔ÿt9%)EVkJ–oŠ­Òàó‰.¶šf[LM;»ąć €‰ÛûÒÀÓ0r€@ö›žSŸe#;cYUê©ïšÓÈ a\űʙ+ ˆÒm7J˜»ŁÈíBûtù”Pó@Cáś3oQ@ąÿÌCeUAp䎙u‹t șßx@â&±=Ę­çŹÀűPù4d d超eGôÄL8"ك:üô\ј„ŒÉ3âà[-Žiu*«“ÇŽ `Ÿć ÁŸœy"Ü{œă,“t4Ì ÉéäÚܰ§ÈÍÒÎsłyöB4Bšk‰ŸÒpÍSÚÄBÎ.OÙĘE:ކ‡âÎŰæç„țț@Ż%gŒŠ /¶'w6Ž3 ›?•cșTŽÈœ©ĂW·Țèœ;k‘’ é,C‘ú Ă~êÂÛeU Ìh˜©Wxá¶SAkőčÜîëŽ †iŸïœ‹ŁÊkń<@Ô0Î%ó@‰Ž‘ÂÎd»F&̗‹dȘLÊő$Öc© îëń@5ۗ§AèlĔ~Xî~â{Ùű"Ÿ;ž(+€Ëő-J†$Ká':ŒÌ·ZJœil„û\nŸșóK ĐîRŸeuyˋț{œ]Ép`~:mŠgŠÓ`ZÖlͰïÏÍšÆ˜Ïe ù ‰$ŐXčvü$û!™gpÀz–Á!á.–È<ÌŽßÏöLŰ[ÀȚQš’Đ[-|œ)+mĐÖQg}šìÉ©.č€Ï‚IÎÜäÓ±l§a/GŸYàő6˜€í†}_žÏ/œö]L€tŒƒ'đÎE°ëŽÇÎkÔØËûŻe5”€ëÒÂĄÜW’TV2æ·Ü€Ôdî€ÓÜeËÛié.ó’ù` ]Ó)ÚvęÇA"Œ€FàôŚ™ÄJBÄà<ÜœP*dûÇœ3#ï©őf ęh…Ëho d}/710 §K>mžő”y­'H·Ł§±ù2€Æ X\a.y€Ć;ò”źy¶§hđ·<_đsž‚ÂșDžû‘xąȚ’Ì”CMA„Æ Ÿôv#58 vŸ0u Ăș žtœ4ȚŻó˜óÎÂOÒăg—ß*ŁòÛÀFčӇúf}š, ÓÌg7G> endobj 181 0 obj << /Im11 176 0 R >> endobj 175 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 180 0 R /XObject 181 0 R >> endobj 184 0 obj << /Length 2866 /Filter/FlateDecode /Name/Im12 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -24 -475] /Resources<< /ProcSet[/PDF/Text] /Font 185 0 R >> >> stream xœ”ZKočŸśŻàÍȚƒß<&@,6ÆÆŁ¶€ìŒdόŹäßç+ČùhÙ^;>ŒșșHëùU”? %”NA“Püo|Ű'-­Țˆç‰Äę€Ä_&­”ŒÚ MZIG‘Vk]J‹Ó<œßíôqČÒ8C:o5țœ?Š?]Oű{AÆàÄőû©œG"LLÂÛ SJâú8œ>îî~șțŚteeĐÖqùâúfz}č;Í»~ÿçëé—Éy#)B:ï­€.]ùőEŒMą‘ő҆ Œ YŹÓ|žßœ;Ì|Ž–ÆS€”dÇù|ȚĘæśW_d8ÍûùțÓ|bŽïč[ ÖH/îæÿwÓÎÈDŠßmśœĆÎç)śƒïEÆx™Üž—Ń8ÖévŻóęíĂîĐ$Śá…äw»‡›Cü‹ï_ îÿŸfU’zđ”ęÓé4?\ČàD2’JkÁΗĘeçùŽš P0țś„›H»(_A[™Œ8vŠ‹Fq˜ˆRBÀwÂŹŒ9"WŰJ>|IIoW+ƒcûŠś93l\‘Ž6ŒÌIèë8€Ű(‡Nń ™$5i;]iŻ FŻÎà’TÁ”"îÖ”#1HŻ“¶X~ț»‹Ăęù"à›bżÛßÍʂd#D:Y%cVd!­üw0VeÔ$‘Ü3'IćËÒ,0‘ËJì”j­mkÇsŠ$“Ík g—°îÖ)ësÿŚ”dA…LÓE) aŃRÓIăCA3©0"\B]‰í-[ÇNX$ÛŽrFA0ș­°ê+ŠÄȚAA†3’”/çT`78‡pR ŠJ„šÏź‘ c^ !|[Êx\"aÛÒźžČbłąŽÆì„™…ŚĂUP‡+Gqć†gΜV직‚•č„­(vE1pŃA醝»`ćy?…ŸŹŒB9 0Ó@·0BŹ”€ä”Œ­‡ôÇ"6íÈΒʗć¶ęˆą.VyȚOw°jÔ 8kŃrZ<”.àJ sƒö;„^éM«Sú^ÙŃŁ‡ŹÄuĘ&n*BN2ÎčâĂ42æŠÊ9úćÒ|2rźÜ™*aà!E‘ՙeĆĆ8-źžÊÀő•è QsÆBS b©6ăB^)5ŒlLÀșfĄ‡ÊÉÆĄD”‡ LÓâhëÚmg$ÄŠM&_„aÆ?E·óĂ|”Ì(@ĐD§ §c ù0?‹§s™Whű"àęeb›ù4߈K*_Dą·§Ç§ù€“đŐH;8ż­Â||šŸ:Űy‹ȘyŒĐ’2- /ú„‚p5v^ö·J©r Næ+=6NZâ-kčQjÍ+Úșv#tRYáx«Xï7»Ëź5ÂÎê”NĆîÓîțP;Ò+B‚K1`(ăcQìy>ÌûÜEŽ…ő?çË|üé՗{”ęîpl0Ö”ˆ@1쎐YƒêXÄp*±Ÿ‡{c4óÙ»Q›BÎŻ %[(ü!Éi#čÂe3âY(+ź%C\-gŽ\(œ+5źBÉ\Àz~ž,Œ mă-‚ž5 àTvíłíq!.ź)…Âo”ÉžżˆvxŽÇ„;eŸpWŁĐl[ŠxÂaHłFć6”‘`«€ôäƒ>TQ]òÔ¶é…ČÀFĆÆ)ƒ•Ëíó;QšÂsï)ŽÒŻFÊźî†#KEwraEἑűrHčÂFš2„‘'A•dW•ÏJŒßæÛ™Ü* S)‡͕ÆqżCŚtÏéMÿçŐÀ™ž2čĆß Áč‡óÒŁ „j/\űÎŚGà Ë +öś0Qn„ÈŰäx>†GÀŰÁż -g7 8Öóv8ÖĄ83Łö%ƒżsŒx€¶8tDۖnÓ(Ș„îËĄX ù—éɌތPÎâò8ž 9t§žcW(O(d…Ź`§“ï†DźŸ€WČxÀfô)"pČĐĆșŚ»‡ÛÓî(~țYüăîț2ż{ܝnÄO{~Űß]žNœrđ qˆfQ Ă-ŒZ D=Q5FSçÆÎălLٰ‡:€ĘÄÌ"M§č<Ć4ʚK­YTyïQœÊ ±„ŽÒŠĆc:{Pæ„0Úë…3§”ždÓ@).łu­'6bÁpϜ5Ń(H­%ÁA™!vÂRd9“.äŹĂΚMÙżS€iT m]»­È"L*č œçl5—ŃfGW\ÚÌsĆq-FI|nśČ”ÖŃè«éő»§śï“^MŒ}HĄ™Keő‡ûƒkÂ#ut}X‘€ˆŒâiKâ©SSkBĆńŽg.ÈZčŐ™° 'O€GöÌÄÓÊĄ ŚŁŠŐKÌOž‡ò@ó@Hkp(Fêšś%òżÍžu*ÍY Æ/ęéæĂgŰćqÿÛ|–K"JèśEț&Ï֙-'g°ù€êŠ?]ö_—űÊ ¶ó‘s·-mțw©VŒê”(ˆïUŚ:ÔÉÄ#1ôҊ-é šÄțălÁe7đ$  R€Ê%pû °M⁄†_‡—. yąe€0…áÏŽŃ%(öÎm¶Ìă\ <‹:nyú¶ 6@Aőôx À 7a۝ …ÎÂúŒ/š8Ær70ŠŹĄ$ăp-u»<„«7Ż ŹjgäAMÒ~”Orƒôł à( BČ ™&0ÀÍrvœ”|6Žg‘Á]SŽA3`âšÀÎS•Üś©†hg5c5yșA‰›ÉëșWÔ{ßmöjš'pÏ.8œHkÿ€3^~:Ÿ+íaöZ40jĐ'àƒÈĐĄÊŒA“Ö g UȘ'0șć (ÚyjhÛà_ŸÄĂӕ4†o›V/9¶Ę GImÆksëŻGÍpÙ!3*ŻČ4ę¶]ș –ƒš•š,ʒUȚníz§îőÚwyî gÎX§"żÈ•Gä’ìŸêxžäŻ< ¶*f cÊŁˆ<ÈčÒr_chëÚöÿHŸ…/żÍXș7Ă3{¶+ń·țžTKçûkîIÛ'!óèŸxOo`ʔ‘ tRF]ćHĐć»ÔòEhÛÒMq i€(”ü^üËô_‹jZ· endstream endobj 185 0 obj << /R7 186 0 R /R8 187 0 R >> endobj 186 0 obj << /BaseFont/Courier /Type/Font /Subtype/Type1 >> endobj 187 0 obj << /BaseFont/Courier-Bold /Type/Font /Subtype/Type1 >> endobj 188 0 obj << /Filter[/FlateDecode] /Length 217 >> stream xÚœQM‹Â0ŒçW̱=$朌ŠíȚ,źąž„ÀOĆ/Ćęÿ&Ú"‚—eQo`23oB`”Űà “Ü„ńó”ÿ”ŸBŹŽŠ)DŹ© ș(œńhś*é:eĘaÇŠ5œYwîȚŒcV5SQĆ{Rœ«X·€ Š{bŒXšĆßڄÁXP›Ú#ŹAȚNÉUa€D}găĘæśŽÊ”s.#țÈcKÉÂä«čQĂS›łÏ¶»óȘ='á2ÌđȚö«MłńĐ%YCr-ÍćC>Z]v| endstream endobj 189 0 obj << /F4 11 0 R >> endobj 190 0 obj << /Im12 184 0 R >> endobj 183 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 189 0 R /XObject 190 0 R >> endobj 193 0 obj << /Filter[/FlateDecode] /Length 2460 >> stream xÚœYY“ÛÆ~ÏŻàCȘV‰€\ÒKŹ8rm"Ć.‡)čJ«‡!9K‡v·*?Ț} ’k%NąbÎ‡‹À‚Ć~AŸïű3ț„űóéêèß‹ùÖŚëoÔ"ÔŸÒ‹őĘ"Ì+űYžXûÁK—«0Èsï]ĘŰćJ%‰g6đ œșﰟzĘA&ÖË<đL”oÌbï†ȚđìûCŃYÙjšĘòăúŻ/Țċ0ôóÙź@šp±ŠÔÀفwĆȚš8€Đűîękli`ÚXłk™Š^ä~ž ŠfŸÊˆÆ?ÿ~óӋ·E”Œ2ŻXźąžßJÙŠĆ^äț”uǍúżÊĂ=p6ۜšFRok[ÙČ­Gœì«bkșąź˜îŃnqô`Șą=¶țr„ŁÀ»čă=8UśŒČé+íöśnőŐÎ6Ü$qś9žÎéEôg2Őt ”Ś!ÍÇIgYa8šB‡~š.ÚrÉăH{+ƒJˆA„ÿâÏŸ±'n‘(gÚÌs_)!ńyÒ9:vî‹ČdQ@Ił)čŚZŒ/„œ¶>ÚîPT{/‹O(Č}IûËúż5ÚÉiăÔÏh)Šü,!?˜Șźußț©5eQŃÁ0üń|rVN Êyèż ĐĆì"„ŽČ(àć yn~&#QščÉ<„qŚŸĐÜü‡Ì%/٘©łLž`:NáÿœćS§Œ§à«±T_Ÿ„țú,ăÿ˧Ì'u;°êaÈPüo1üm$Y©ÜÏ4 ;ˆÂèț~™EÂDìđKA&F|7Ž#±”·•mLg[î¶Ć7Ą3Bh‹ÀŒ€À3YčaˆÜšŸò·Ű|ËHß?°͐Ș 1Ô+‹McšGVé OäŠČÀ«+ˍ©\Ű=Áê†{̀ŚȚz§ÒšÖÌFyÄÁńoN'ąa«]ńp»€i SöBq`fșÆLéÊÒûCÁa‰—m늱-ÓŹ+ —!ŠÁŹ`eÀîÛ œž8q4•ÙÛ†C t:ïâƒÄX·i á6~d2;Ûn›bĂ'ș`ĄtÓv<ŠÏ+˜âx0éôœă IŒNXŽâI$íÎJÓJúÄۖ:Q’l~Ú$ŸžG^ŃòÂ-Źa9`Ր1TŠ€H˜LdƒöÔĐ`ïz8tHá@’‡])RL% F˜i|!#°Í"ç$€?Ä}ÚÙ]ź§P0P•GwšRobm±!9`öźFO #˜ȚÚâ3GsŻđ!‹vŠÂîŒ;pJS{ƒAśÁöAw-Żű#Îą"e{cË ,ĘźW—š9:ò"JČČ+ră,ɍ‰Üە„íd) N;ùâÙȃ4ŒGùXۏ…œűXŰącáȚaĘÛäű0wM}”›;HÊTYJëî1c­›OŻÎooź†ž-$é”ÛĂYÒ6n=s»äæ˜H-8H`Ł”ISb?đ4…„ÙąeáÙ4dńmï€Waz…kv€B(żĐ8wïg»íd šëu}Ü7E7ŰWÆæ‘€đ‡/„ÇÁÆëÎČM±Œ8Љș©vb|$ÄeŠiŠb /w-Ÿ‹Ń čóKo{YÊțc·ȚÄšă »W‹€Íyo4Ó(^öD.žqòęŃÀű ŐpÏB„„Ž)ąń(ÁÏtÖŃ• T˜ŠŒÖŁźYŠrOuíŹ'űŸ ÄśaY[ì+?`‚ĂŃN…ÈŻ§óùs<Ź,‡ ć±/Ê”ę‚ú¶tăQźBȘ8žc aÊA˜ŠæŚ2šoÛCPdôÆ0í`ę9O~. /_ÿùŒqRń­ D"pÜûɝIt»”liT‡v=Ƈ'<€ëÄRŽESâÙ)Oćę\Őlì›ș?‰†P<+Ń܅hw!ŽĘiP‘ÏHâÜi&bÍž*ŻáS wć⎎ Œoí”q+*–ű„ǁp@QLd’ŒaDFkG•fŰ|3±­Ïi 3‹}‘ù!‚GPRf"žš)…”—?+țü8†-èM‚]Ș%ì,Á€É›‡G‹/œYŹézŽÊÆDN'±W!Cq—ìÎú"oŽ*›Df\玊–&śț`ČWS“I\őPcA±xĐZ%qæ’ûóŒ<06ŸJ­xÔHvßóƒíÍƘpșlk^a*ț>3ÏæŹ1Țt¶Èąjë qˆ6…äßTVÄ|9ڟiOÛ>uw={˜Iù‹D8Éș5ćeŻ.ßÄnœhà?fӓž„Đó)ÀçÚ9tš3NΠc–ÀŸ”TqÂÙtÜtgŃ*`Ę`š…8ìBmHjÂŻfaÙ %ÉBŸù€YÈȘjeYÍßʅ:ÊʓšÍQ-„țÙ„ śâ©òv¶SÉÀRwA)_sz–ŻÊąíĐè“È}Ši0œÖ€a„Ÿd„òpę3ê«1AĆÔ[fÊ7 Ÿ77opÁśŒUêŸČŰ>b-R|#[qĐê*^šÖ=m ”Łx`ÍțȘĄ0Őź”ÇČ&‰`ix’·–;`•„ŠTBĆq6.Ÿ‘-„š}°ÛŸs2È4ïÖ#Çú‰‡À‹šțę’GŐŠ}€"ù=ÿôŒ^/ąHû:YŹÒ0đCMČDٌ˜û'èżęʐ1 endstream endobj 194 0 obj << /F3 10 0 R /F5 12 0 R /F4 11 0 R /F11 59 0 R >> endobj 192 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 194 0 R >> endobj 197 0 obj << /Length 748 /Filter/FlateDecode /Name/Im13 /Type/XObject /Subtype/Form /BBox[0 0 2384 3370] /FormType 1 /Matrix[1 0 0 1 -113 -572] /Resources<< /ProcSet[/PDF/Text] /Font 198 0 R >> >> stream xœ­TMoÓ@ŒûWŒź„ïśźž! â#H=ôâș›Æ`Ç­œiÚÄÏdŒNœP8 €ąHńóìdöÍŒwGÂ[Á©?ÇU›ôߛì.SLjÉEzqü»jéŐ"{ńّeÎjZ,łé4'.Ìr‡WŠm–Ą UŒÌ/Ïhxbh©*›ælń-{łÈ>e‚)㌀-HêL Ԗ$ g™$”f…1· šÙ?d^Ź0†„œA}{šX٘ŠÀ}IrəőǠʱć,^r>ą (.”b…Ÿ+MúÓÔ­dÆę áÎyš(ÎŽCe™úyêٓ|Ü3/-ć:ùЇ*ÔśášJtńn†H±ŁÛČú>zá™6ċśYNqšÚô}XGb=Ë$“VyAZŒÖJZ\gùe.`ëÌüŁM]^5Àƒ2oĂ0”7á-ûźM€ëÁ„kƝu;Ž śăßíčæ|C”O}S蠟+wŒdÎ=EJ”c\„ï —GȚœrÒŁš§ÀæőtÊ0Ä~_9Rf˜”ż!5*Ú33ńï 6]îHÚ)GOJ DZ foLϘš}WÁÆ)]ۖëëƒßxxš!€\aê—x?ûș]ŐŐjŒQ^݇ŰoȘ8ĐȘۂ·fâv3ŒùÈŻ…‡PmbžfxN9àŠsöŁćFq2ŒćEÜąGĆn;œxuáŽX\vLfșúĆyxˆoFő—y[ÖëŚőp۔ÏéöbȘžœœSș& [Œ“;+K{Kÿ“2‡Hz0:ŹV™”œCłšp¶_‡Đž†y\°żèŃc\—c ÿŸ02…lhÇ1–"É9ï°!âȘŒT.cèiÚ Û@Ûșišl¶ćă@7!Ò4êő:„i艛>°YČ.8ó1Ö&^Ś^rĐì”ú{ÍŒ˜vȚ‘h‘ö Y59ûnRÓu·Ô-“€3†«źì{çSöîš endstream endobj 198 0 obj << /R8 199 0 R >> endobj 199 0 obj << /BaseFont/GATSNW+NewCenturySchlbk-Roman /FontDescriptor 200 0 R /Type/Font /FirstChar 32 /LastChar 168 /Widths[278 0 0 0 0 0 0 0 333 333 0 0 278 0 278 0 0 556 556 0 0 0 0 0 0 0 0 278 0 0 0 0 0 0 0 0 778 722 0 0 833 0 0 0 0 944 815 0 667 0 722 0 0 815 0 0 704 0 0 0 0 0 0 0 0 556 556 444 574 500 333 537 611 315 0 593 315 889 611 500 574 556 444 463 389 611 537 778 537 537 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 333] /Encoding/WinAnsiEncoding /Subtype/Type1 >> endobj 200 0 obj << /Type/FontDescriptor /FontName/GATSNW+NewCenturySchlbk-Roman /FontBBox[-6 -206 913 737] /Flags 4 /Ascent 737 /CapHeight 737 /Descent -206 /ItalicAngle 0 /StemV 136 /MissingWidth 1000 /CharSet(/y/n/c/X/M/o/d/N/p/e/dieresis/D/q/f/P/E/r/g/s/h/R/t/i/H/u/semicolon/v/k/U/w/l/a/x/m/b/parenleft/parenright/comma/period/space/one/two) /FontFile3 201 0 R >> endobj 201 0 obj << /Subtype/Type1C /Filter/FlateDecode /Length 4077 >> stream xœWy\ŚŸŸ˜™*‹•›JŹ&©”Z—j­·”n”ŠZDQ€HŁ@X°É ʇ5v ÖPA„`m-ÚÖȚZmŸn[íkő”Ö3ôđ>Ÿw"è«mïçĘÏgțHæÌ9sÎwûę†EXÌ#X,ÖâC±áòèÈűwę‚BE’W\„aŸáæĄ•Ìó,féÜÏĂYê("`,Đeo€8*ÈUì#9ê&zyőșő‚Ż”n#/â0±‡ŰBŹ'\ˆœÄⱏx‰p%Ț!6+‰w GŰOl"ŽNÄjx8HŒAxÎÄn“8D8Ïó k–`‹;"XJŹĆˆDk>˛uožÿŒN¶€ÄŸgqÄâœćvK=É'{šEÔCú$žižÏžxțĂí r­««iëuÖßۄÙ.·M·5ÙȚ_ű❠w/Ì–~öïÏŠț–hĂt!ŃóžUÙl8 í8hTg•æš@·¶\ŐĆ«ŚŁ4qÙj“jęàæKû“AâBw àŠ) ‹óó ò ù„ù„ „nŽź Š”‰œ{CÎ 4xí§5†~Ȇ$ÔÙ7Śkz]ŹGBq5ÙS­„f'+OòmôÌ߯YżȚwŰPÈrĐ.…„žê.VúđQ:ćGù)”xYbXŹÏ"*ß@ęB!Ő@YcęÀ@»4ƒ¶ÄȘŰȘU(8FŁ7f§8=žr`v ÜHOłkă»"=Z]Àà期¶a\Ǚ„FVŚű Žf3‹á*ŽÄ!8ü=@oóü >­‡n~Ț֜”“•ÁOˆËJ'é&čNŚŹ5\q<śznœ­FËÿc5\8u¶ïW#ÏfÚ ˜Ši‹á2+8 ś_žź­ÜjÒ +ÉÁú”E¶R‘ÀGڈžĐM©ÎRcÔŐê‚^ ]֐C <ł1zą{ôŠöWćžYBŰmŠ$ę"kÛ*Š«ŐU|HĂíp5—€)@:$dćÌ„„BxӔBʂà!Úæ·=łûŒ&Z°Ąaă\&Ź#o–fúòĂ©;  „±ákłh!ì1Që c[\J3‡(˜ö?+- $Œš^i9ÓA…S>iY[yńæē[Ó üVЉ Z©Ó„E7y”&THą3m–6Lvą‘YÿÙÈlXÄDsÍZÄBŽì,5+hőœypÙZÈFóù>W{w#{ÄőwppđÿÚĂ„=WŻc‰\KaìGXÆ0á.›YšäÀĘ*Kcš!§ô†Ő/SùšĆBßé°ŚçcÈț x ą‹WÓßĘÚh›é IőÓŻbÀ–Ž0ûFŰ0ڌ—HŰDžé”‘ôÌŒŚČ?┌f(ŠqùÉò4SMâÿšÖ iêRwł4áxźPű@è„ź}tš‡ßÓœăĐęŒóït_ĄW<Ö=|‰ê<Ò#4€o?„/BȚë@óœEČĂA|hŐÁ™0ìCÏ Žhśž=ÂÏ!\ÿ‚oŠb2·Œ,ĘŻ0ì!› €Ńœ<žæ_‘ †êok­A‚oŚÁçï~bșÛÇȘœćæž °AÖߖźË;Oç9 œ°A­­ëhôžÁ}[xZș„o3]7§°eĐțíÙű‡-'œòMËÜÆ‹Â)r |R9Üvÿ∑YƒÁń„Ź cnș]ՈÄ[ž†ĆűŐŹ᎙!ާČxˆÏTRC*ŐȚ9ɐÜi#zŸgxÁ,ę˜|‡ÍĆ ßń»àŐrp‘Í| —ŃČÛ«à3—șjÏűhÙăXP˜} Œ=•w‚Čüș‚ÊČs4Š•r @/«ó­ )W-ógÇ.Ÿ ŹWAïŐ<xGÖb#L0°ȚÖæđ4Ów‘g :K4Őęș ë+2Ùč9™éüŒÔlPĐa§ä흍MúQOęÖ}žQžb^˜oȘŰJ‡nò™DĂżă[ŁÂś0œg€lŠ7l1Á1ł"1ÀíЖ óàçhIț˜T†șk]†Ëàű"ht§żÆčl†ôgaíGPžxdÜ)“ ·è46.̱€„ÔûĆEçy—É_†Œ^Xááőf3˜˜Í°ThZd&t±ĘÄô|쀙I»na-ő‹2ż‘š±ô&“śÊŁÂCę\ă6z?"‹ÓJ•ĆčĆ ž†%j4ehbšejIŸ m‚7…dæj?ÿu€Ž‚q€±T5‚ɞƎ.)m7Ń);őnŐFÚHâ˜zxŸÌzđ=†œfC/łcöbÇô=])œfŒ{ÌŻšŚ+żhșxêBWû鹀ßqŽ€QȚĄojé îp?èæ±IÂ3WCï>žæöW=ĐóWWăąÆŻ…ßBïïÂź.¶û…€ŸsÜòČóRTÊÂÌ2PÚZ*źäßÍŻÊïŹké:>†Ž&igMmiq (Ùù ș0Ș:č ĐMšú–źˆSț’űTßă|»­ŻDíù ÁùPçę֎ágÓő=Wűi3A1šÊĄíŠ†ŹŠhÉW§d±ùXÓ@gmĂ`>ŁNäWúYŁŁ0ë›YÂÈ8AdžXŹ—{îŠ#Gțî_ÒËoŒiLKN±ż§~ŽPâČùđÈœ(ž:ą#u}}!ï'œÜ?ÿŸ?©KÚȏȘ-9TáYfïV@Œ:Z\hCOëùžöä-Ż!ș,¶ú8­#ÿTđ§qUpÆ4ÎŸêŻ țÏŰ]*űŃȘ0àEŁŚÿ߂ïÙz|ݰŽô#mĂ &ێœŽ{IcöR.ü™3JöCJC|«ŒJŹÚ_äa_Ž,»ß·@ïùhEû’YûRÂ"€€ÖœœHűĐ>ú;ÿÓ;4p…fbܧ!čö#Ž‡~úëd”ô‰ëfË%v–‚Z AC^ș€€X•gôùӀï«ÉțČ~d̉äcž1\ܚXśÖłîa€Ü±àĄ—ˆJEÏyïߚAûßB%ۛ©–Wû䣠t•76tvàFă<‚*W·œœQvÜ o9¶\Y“Q™Ęô4l†«pŠÀO0cfA ŒșÈl'ÌĂÙ?6^J1,Ś+ó dŠ8™LÚŃȚÙÜÜŃ!k6§ÿçÓáQł`śÌMxƒäżË'üĄaűn‰æC^hz=«3Ą[ÿ"Ăn™âžd˜—T˜8Îúï;0W‚Wqƒà„„HÊ-œô2țL=u0[ žf„$†ÄxûÉŒ@(•%k’ërÔà< G)ä€í™{4”…ò*y‹hP>†=ț~KÿeLKWb=ł]ςƒĐšƒHX›]œS Šč5Ć}ŒJ=RˆKÈP™V ߞYiŻ#árűKËÇZmàšàJRW—"Wd%d&âRöOLOÏz€I839L:őïűá"5>  m…Ê‚ ÉMVd…đâİFOŸ[[.:‡–CwûțŃ‹Æ†OJžzT-n§:Ș2’ʔ„Lۅđ酘-[hÁđFŰÓ;™|Î_7,2 l˔ÄIœÄ[Á;À„9d ą;óűž†“żcê+ÜłÎpt‹ÚGž—Hê€ïïŸ „–__v ^ëxż|LaÖÍBÈôCg5Tg«r‹@)·¶Žš“wJäâČ”§—†—Êì7Ą€5°0G5‹qYqŻV"Ä”€šÓ*ęàšăpÚ  Ëv ˆjjt€«ÒŁ#x-]„"25;13…ÿHő,8ƒíó8y†(ęÓH?­xÜl$Ÿű€yΞšÿț.,n‡;‹í:x>Tt„Ÿ iöȘ<€Ë­Ć›îQșöÆú¶ŠÌÊÔJ~†*·Đő}”ƒíșÔÄj^]‚* œ ę©ćń’tŻ8Úźïu‰Żđà’=ON\Ҟ5òìB=Ș›bMϘZ[U™E™YYčÙJ~BFVn: „©ugűŻÜà€ĂÙI'exv`äńHŸçOwœźoëŻç·WöȘżŹ0KtVTđ,áà0î)mSe3à–ꑟžŽl«JOJU&&'đŸę֏Ș,3ŽEífùЊÉî슎N_ çz{DĄ%ҐžpÀÍC±>‘”ƒÌ•2ïá"xûÊŽ='B.ˆh”7kŽ-òÆ><öܟîáC+pÊ€ĂgYpŚ0ûîż ä—ÓÔ_ «a5PĄqڐóï.š¶Čș[feMÿ ÙTŁ endstream endobj 202 0 obj << /Filter[/FlateDecode] /Length 2346 >> stream xÚ”k“Û¶ń{…Ÿ4ŠfN4A‚ŻtúáÎçKÜ&ŚŽ–'ž±<ˆÄĘq,‘ IùŹüúì $őÈtš¶_`±Xbß»˜~Ìg4|ÇĂűQűù|úśÙìűèÍò杞ć~žÌ–ł(ôóh¶Đ‰Ÿ©ÙòöƒwßÌĂÔ{Ÿš/ą ń6¶ŃÍaž{Š6›ĂŻၷòÂŐܟ/tyŚ ÚU;@Ì<Áš:ś-™@ß"Ł”M»eHÿ$‡Šf»ĆßïëȘ0}ŐÔ|r CêÙ~&Țó[ÙĄ“8ٚȘvÄZkÊùÇćßf „ę\Ă ü<&îL —‰’L~ “U­ĘTfœÈÖvyŽŻZ[Űê ^ʶIćpNb{??áuÙüšx„+ÏŽ-RM<țOê=ŽÍöäj5rœ2ÇMû™X%*f(†XQ/Ì žxäÉŽŠèéÂbUĄ¶ê{+X\©“}rŹżdtŒ5àœ0haÁŸV âcaé(ń–Ž–ÓXz€±‘?VXOČ ST„)ŃSDž()*ËÖDÿM‘Đ{&'Ă]ł”Mmy†ÌŽĆ3śt›/ï”Ò äÎvaĐíYGĆ~’É6^&Ńą ‰ìqÒ=Yș@”Ą#mwtï$!SbđŸÛłł!șىż›¶ămӝP)è¶ëyŚnìÖ:śBę”.qÌ'Ąw °űęV\/]Ê观àÏ #J[ ŒW?œăIq(6¶CżŠ#o9ÏBŻáˆß5›/Î9è$Gƒù‡»œšXž$ hRŻÜ¶ä#’FÈd'J]ŠN1ő\ČÛùGÀ‹Bö±H %Èôȧ~ ą #êdŒoєȚOk: ‘ !Ê>pjpá•òžo%ĄšˆwÙo`xè dú TÆéƒ~<æŻLŹ‚rÒôš”vb—vČ3‚t 5RpŰęN0ăËÛâ’(„2("ù–šŒ^ț·UÛÔżB?Ëg‹0|•Ó•șȚô{°–8ŒœżòЁ…ęÊ«J 5úж§…öîßęđƒÀ'Óoú bÀŸ_Íÿr궋_CH?ćÊ'ÌòÁ$1Ń>Bàƒą,`é\Ip2iêëXŒÿęœęÚżțbkž'Șæ¶êvs@k»ìȚóÖü,€$Ê]€Ąü w@qÛòʕ«%C„D ŒśŒ>Ê zŽ”mMoćÄy90/Cä ŁÌOÒ©LSC˜Æ’ÂTKAŸ„ÿ…žDf°íò a™Á„Ìç\f*Í| Ăom]ŸâÈ»œ§à oíæaćœúńöÍí§[ŒęőRí]zsÿéǛwwwTÒG^p.ͅPŸ0GGeŁLŁPIÊSźhPg•ź:­t1™=U\“â~ê _źČ 9xJőŹÊB(ogˆśÏœ(Š?ĂʊgĆŸm‡<„8èÊÓÚő‘«&À˜ÔȘ—óò‹ہ<ńŸTxż<–çÉQYŹŐ±~Ż«ĄŃëW€…=:ŽwȘNÍ5 3?Òbźß“ĘÄt“śöùžÉżæ°Čs胈êÊ»àát3çálxS.FqçÔà"ù*9êś°á)ÙL@šÿŰ·ŹĄVh3đ ɎČÄlNÁœ^Ì€ IÁŒ` öÊȘ+ö”ž6œÛ€î©ú<ü_ežçiˆeŒ+•!ÆBg‰Ÿłb;{ùf á¶™ęó?ûĂÍŠŒ€‚J Dă”ÔqWIą±šè[VŠ€ĘËőE ™šȘíÿ(ƒÆ31 °Ż ngŸæîÄ9$uéÊ K' 4&9Ąă»Ęæ À†Qń…FZo];Ô&CMüÇj ÈŚ!twȘ§TAȚæŽæGÄ\.ęÓoœè`ę endstream endobj 203 0 obj << /F4 11 0 R /F11 59 0 R /F10 58 0 R /F5 12 0 R >> endobj 204 0 obj << /Im13 197 0 R >> endobj 196 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 203 0 R /XObject 204 0 R >> endobj 207 0 obj << /Filter[/FlateDecode] /Length 2915 >> stream xÚ”YĘoÛ8żżÂ/Ć)@âꃒìîSšŠEöšnŻIŃšbĄŰtŹ­-ùD9npÿüÍÌo(Ë)·ž“‡ĂùzĂpđ0á†íOÄ?ߏBÿ1ìn}}ûò­Œ‡ălp;$ńpœ ÎL6EƒÛ7_ƒó“ł$΂‡òń$Î[ńgŽüńŽ:9c@ő ˜ź|šŠæ„ĂhËvn›nkF[ËI±X<1È0tȚÔUœvÖ öêQ[ü4(°!ś†'gÆDÁۓQŹÛÒÀț(–«…==ùvûëà,2ñĄ!ŽSčžt|8˜ń&žŰŠ©&AŃXśˆó(Ű;xśÆ€X; [rqđ`+Û­ÒÜ9~2JŸSœŻŚ-ŠJä&Ś!ÍEžL&—!G}m$ Ž‘˜­66)*L˜Ó‘ÇôŒMńč§ yąb„ćâYoHÊĄ‡Ű«E9)[|5ößkëÚĄđÏÚHúÚžâ=Q•đ$ >ÙEYÜ/,ÀŚëEKâw-ߗśMŃ<±¶Ob‚xS;%4\…đÚyc‹)–6Ìsáđ1!žbљ5°!üTL‚'€tOMčÙ ì§ŠE ‘ȚŹ!NRg:fFMvœńü5ßËdQ°šEƒőÊở€Ą›ˆî–GŹï›zʖ•ĆśDx••ŸÓla?Ղđ.‡·óąĘ3+\„œŚ€™œŸæ}?ÜÁìČÀ·ÈŒ1WMęĐK§û˜ŸÌÀ æđŹÈ,ÍŸa‚ûÈŁz7>&êíZôČ›Yœf*‰!-ŽżæßŰÍÆd °ï„Çą‘n#t'vșæ˜À°NꉩeŽ»“|qBV5J0b;/u‹·‹9ÍQ湌—eőuĐÏŠœ|›yæeçĂ<‘Í·Ț3ò4H1œažX7 ù„ì&ži%hńڍmO’0HNKJENÛfet4LÆz_+ΒÎêăÌÖX·‰Ô•+Ćáy™&" žžűlăVi܅qèÖ+Ęߎ{{+»Áž„]Č Čä)5ŽöE,ß<(«œc>]żbv„K52ÓÙ0•ș™șÓăEÆÆlojôŠ4êMóȚMç–&leŽűXșČźD©±I$8ń*îBčKîsMӝ§ä&ĆȘà˜Ë– ĘÔ„§+“‡Ûw_^cæŹăƒššžF‚$t9 ·ćÒ>Ío:ˆ‰‡FC@&©CœOöîà9pEȚ|(č˜H‚uˆË(dźg^ą ” +öđ$U3dèž9`śŠ”8ÏŒ6O:ŃłlûL€ÇÙYÙ'đœ8ÏĄXïŰs`kÆhFöQ˜'Â'°L\ÒežłV˜KÇ^|ÏuŻČK3=Ò6tÏ4†Ę2|Y7Š;”mQ.œœ”!ÍYĐŐ Ê91ő{ŽŸp­ćœÄ6 ák!ÆșyuÜî‚èîfò¶l\{ŠùĄàèšË[iRNvÌG|gí[5@5‰/!AèżțvőáśO—ÿü|ys«H”Žs_èÀ䂻ܯžÛÛč­țł> «LP+ĐČ/}„™sFșžžüx ,čP¶{ĄYS/»ȘIÊ;:EWŃuś1ÏȚçŠ ,TxÎÙRšuŐß[,4vb”ÆJçíü±€đPęÉâ9ŐÍ$(Ê€>ĐbÄ€ź*;iQ)ˆïŃűĂcY`r{ńŃWíčŃ GàÆ¶Miœńń‚už‰ŹŽÚEVŽyyœkšR,EÌÈ\k—ă4˜‘Q&nM8rĘc pYÀìHFc PńŰh”Í3IÒ㔊‡ß9/œc[» XĆŒ*·”I«è(h¶Ź—OLù@ŒtŽÁŚŽĆyÂ:NÚuĄŹX*óƑ?Soóä(ž’ˆZwȘŻK©pŁÔÛ8͔ WNęšB rÚèÛ6”‹ĆwÌŽK$,íŠR__ńtżNŠÄœ(Ęîèòf4>♫óčnFâ0čG­íźéČDáĘ~ßÜ€ČF Ìí4—Àą˜ßŃôÇٜ~@‹JKŠ;Ž8‡Zçbc;(ü©âlÔOAŒ Eoîʐ‚"JÜ-ƕÚQÉn`WAŸòDă;/l$<1ĘÎuÛ3țOÖÒš2âvĆŹœÍúgŸ« 9›!wĆ3ŹČŸ ž'ç·çGžÓېÄ»©m3ËÍóa|B‚ ÚëŠ^ =śkś€†û*<1äRń“«,śû§łęêcŚ:'­|H§æàĐż%ž»“S\†šT၌Ä>xbŰɚ­BśPšVtjȚ”š·CČY‘FæFȚ‘«Vjж;I$Ê/ ™IƒóeMđcNŰ ű%Û^–Đ?ĂsÈd­©€™çQièË 8B ‰Úmc—ÖŁ[śŠòŐ+^Yç6ț`±ïąèös‘¶‚ô'ëâ!ŠĆČÖŸü ˜Faű‚‡"WèÛy\|ü|ȘK F·°vEBÔw,ć‡ÄHh\5Ț»·Ot•>«șĆ!xN`’OTź/1§žł^7QŒI2êà oRĆ y3̃€cù˜ÚŸFá·œZWû òí/4ŽÂ„ê”ÖD«žńȘCjȚO’­éjpUzö‰ĐD#f`‰b–üę‰ŃÎhČ`Źöas/EšJŸaËąŹș'6€:tŁŻ* Żę>rÿ°”ƒÉÓVĆ»ŒU±ùóŽUfâ™h©%-·ÈŐ ŁĄ O”ޜőú „ͅUíŠ]?Ž}Ÿnă^[ݶAÎW©] }_JH\ÿИ8·‹E§ŽćȘUfúLÀÙ֋©:nŃ^ȚțŐ ąš €&ŽÆƒ336ĂÜ ^œĄ›RtxA.„>śĆőć5ÏššŒșŸÄìâ·ëëóo[ą87ă8Łh˜`SąšqŸŠ3ÀŒÊvrLÚŁ_bÔ>Ԓ‹$öâ]#òZ û/Íô±ą"ŒżPe.^`'ą„ €\1Ń(-Ž›çąj>GŸ1z€)·MČpˆ gű`vńU °<œ‡c?m ¶ú Č…tq{C>є­3ß"OZ4}ÁÌäm–3óIšB(O&ÛâžočŒqVHaŽîăQłMŐÛmTĄ›Œ't“Ÿ)>óÌWÊđș•__ž;±x’‘VU$Ë8 t—d#T s”íœodț8uy]4^x„ŸłìÚŰÙ[œ‡)ĆŸ4†ÀYșE“ϒéę‘•ń.ŸˆÎ(zéÏÂâŸá̄fhÆ•łhDȄčc m­ű?ż~|‰o„ôO?ô±ö±ŸÿrŐ n#1„ëû*OŠE[ìn/šŠ|ô•GœìüI©Ż ±>­2šČŸȚIRèęIÙǧmIÙ흟€í”Ąśœ7Ÿź`]šcûí(±7ògJ‰…XLw߃æJ_ü@ő1uˆȚ#™\‰gƒÿ_ NÇÙ·ÛÌ˅ĆăßAțÒz84ÙNW6C8ż €Ą&žĄ“gL;KˆfA„PÈFÁzd”łŃN «ęźÒęąÉxÇ.œà&ížaƒĐÓ8ìòÈi˜Ça°¶j±čŐŁîuĆ)Ù§Ïq˜íqXŽ?ć𧜣@Î:ÿćÒòźƔïXI9)+‚—'áQÇțÛ)èt: endstream endobj 208 0 obj << /F4 11 0 R /F5 12 0 R /F11 59 0 R /F10 58 0 R >> endobj 206 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 208 0 R >> endobj 211 0 obj << /Filter[/FlateDecode] /Length 2267 >> stream xÚ”XK“ÛÆŸçWP‡”@ŚÂc’ÒiőČ7É:Șˆ.m•éĂ,8\"3œ•ÊOżfriى“ 9Lśô»żÆ(‰“dô0ążoùïű“âÏ狻NI_/^ŒOÓŃ<ž—ŁĆz€Čx6MTÏÒŃâíŃżÆ?-țô✠'&™ŠáD–Æs>ńi<Ë"3žäyÆÙ4êö͊›úó8+ęKŚá=śčŽȚ-țś’Ï“žÌIźĂŠnÌ2J—cș,MҔλÒVšÄȘä킶­iL㯓"SŃ2Šăx9~…OEôâț·1;^tíêöÖ]ϋ•vZ¶únËŹÜÆđVkÜĄë?ÓćłY<›/gêÈJ·üÇæ‹i/żyA,&OxÔk/üč4œ©LęĆŹNe+žÊFbłŽˆËِÿȘóT”}Ć2 ΰmMc KÁÒAž«—ÛjûuE nĘ Ćźï*c­ŚàŚ%ÔN$ÌÊ8UĂ3żÓïëȚ‚č*8€1‚UčŸÆûq›‚Y)șž7šîÜ#Á#Ż·ú3…Ÿ0ŒčLČ€7M­ïĂŻ¶ ˜~0€]EŚöŒă6œŃ+ KǕ͹C_;aŠ™C…Ç7șŚ•cą<Ș[Ì=“ą?NÒĄ ŹÌŁȘk‘.›E†–źîZĘđÛe’+±TMđžVšÿDfÙë{‘xĆ€`űŠŐ†ž8à]h`—+x1M!VgG}Òƃ’ŒéQ;֗·Œ}T’#1È_ÌŰ_ĆXË'nœX=PLÁ…4HŐmć°f+°u#~ƒs”ȘÈĘ Ć{éwçdęŰhX•òșKíĐćÉÓžăαÆ€SčŠźŚœ Žš„ĘȚńB’HEŒÌd)dxVNŻùoƒß$•2rɉÖéȚ™Ő°ƒöR6 [ŠÒ°Òü·«Ć9šT€kŒ"ĐłȚîȜ]ï4§>sìÍÜÛV†ÉÙÄyЛś–đ fùáÇtúS̅*d>”ú=¶ęźi:Tû`™$nbŠÓžfńv”ń"% + “Â۟êj€<ŒòCő%Ütą±ő*yĘ0•ŠłèčŒÙêșćŐ ·DŃĐJ%—Vàń’{ÁHPÈrß^k[WșiŻž­tŽ1Œ‚Š!cȚtÛ-xcŃ}„fêË9[‹vvsTYpÉÌüïĘYM €äYđ—vÏ­Oăg_Wđr‚y°~š>J€Šś 5Ł'bűhúLq„§9ŹŒÎ— Ó#§2€ ìI­"šŰÙ~ĆțżàíeôÉ4ÍՑGę; oÌ[ûŠœ}œ_Ż„dU6wÍ#Ë0ˆU?€Źë6ž«‹yF'œćû}«RߓUš…žŹÒTJż7ÒŠ’Àj>Ë"§ űj1žÊóșŸ_4JHÖû¶âfDŚ’9ń*?î ~ i>S±ù62 8<;·Î€?‚äd*„8/TćŠQ0ÌíȚ‰š§È#J7¶ăڅĐJA †ö¶ŒHśq%\<™›BÉ…•P,î˜ĆŃ|łriËïYűłŠf*ÀœŠGw©àțcoöÌò2úA€bšx€ +ŻŹnjǃâ,Pæ4ÌXp*@łd>ya8ƒg{âɘ‰î1Œ ›—ÁægSzYì^ós5îń0ÆŹÚËÍ0À­ȚŰ}ă©‚‡$ đ•‡flì\,š«#ńÿ‘ÁŰńĘčÏnBt©Đ{ëÏĄn /;ìF',é±CŸ€)čG!yĆ WúE)‹—I"ÍLÛÍâ)à§'ÄÓsbrĂ%â"ùωË@œțž›łßCœÿvâŻ~«â62íYÆ„ő3}_Éô.3W&óVH§%$,lÇčM…ŒÈaŹ zœóX©·•èOb–?ÇÌő@*'y†ó$Ê?C 3ŸGŚ»–)úè€9RNŁ ÿp}šșT°`‰ _•vœq6ömźò1œ…1 Ž=±ß֛ećE ErEeÀ7ŠêÆHcqòŠûA ŸßÁÉ-ő(…‚ćdSßś+>„œ†AaŁń?đŽoQÔ_ńŻé„ %ńm‡+öÔ^Ud€)`rù‘7 } łĐ§ƒB>TĄg}lh><ŰGÀ»Û“Ê>*zIJ/ ž} ÉĆ;™ÿĐ Â'źÿźÂœ^Œ2Èü~?MüÀ‹Êæé 3_ÿđoËX‚e endstream endobj 212 0 obj << /F11 59 0 R /F4 11 0 R /F10 58 0 R /F3 10 0 R >> endobj 210 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 212 0 R >> endobj 215 0 obj << /Filter[/FlateDecode] /Length 1652 >> stream xÚ”XK“Û6 ŸśWèV9ckő dč=5I·“6;M3îäÍìĐ2mł«‡#JÙ8żŸAJČŚ©SŻs1A űÚń=ßw֎~ŁĄÿ đçț(śÇy‚êóùŐ5sfȚ,qæ+'òœ`êLX℁3ùȚ ŒŃ‡ùïÎŻóƒo<Ÿ;,ôÒÙP¶ÙԂ/ŐÏ{ßn‡ęx’xÓHožüx/[ŒÂ©Û6âłxČiâ%±Ț4:i@/[„űZŒ&Qč[Ń>ʐÀOŒxȘwg'-oćv4 Sś„‰ÇfzÓűŽœ°ȘŽÊęMiF&toĘù‹7H2——KŠÖß/ß܎žl*$"ŁDLN›Ú +č.yźHe2–ĂÀ›Ńê»Qșpšaș2ϑŠÜ”ü„žțFԂűæ.j)Vđ% 65Æcê.ÛŹ‘UIKMeƍPÂȶ2S&, ÜùFìí_QX+MÔD«MŐæ†ŸU„jó†&ïƒpLT}Đ^]ÇNÎĆXì•|ziȘ}Mœ`4 ‚Á§u%“FÒR/"wÎD±ï>˜xDlæn8N> 8œ„òȘĄy”"FĂŐœ2dEăČ#ÁpÇÄê7őîPʌò֏"ˆ …ÈHś»òÆèa,‘PŒ0T# ‘žĄ»R=2ˆĂĄbJŸ)hćđXÒ©»ŃˆSp<Î4…læy”ȚŃDŸ-ŒŽ@sLHa2Ó{kîȘȘ‰ÈȘb èefÛșZŚŒĐ™ùî+ó‰Ș5ëoE.ù"7›ÜÀËŒ«†6-5‡€é|î­OŽő·îÛ›Ś·#Ș»îЀî-%Nè¶J,©P .Ë|GrI VUžWšó Ë5±¶ä$MÔČ” :ăyź~:łÀŻźÓț~Šœ †œM|‘?! żVìĂÔ5uß+[ï2űmÄMK}/ ÏČ­ŚŽÆęSAí_ÌŽÈśœđʰ 4­iâłlŽCæ!łąZ‹†2 šj“7Č\Uÿ«¶ĄčÙZM6ć‚+ŁT‹ֆN@ŁĘ%ąź@­ŚŻ"RŒ’†łjKœvwsù0ś}l8łDüá°24XyCMÇIŹÄ"ŽĐĘZ7’ÚŐźÔ7抟JùĘèë%șJ……ƒJEQłO«ĂÄ BaAwĄxÆËô54„*â3/ ↝ô‡JĘτ± ¶ț,@3ÏÛăŰšĂÎ|ś0pm J/446#ë”>Íčj$œ..”/•čűԁź¶€ –…XN‹ j|2N±À5J  ž źE)jŹ|Ú»$0Rle¶Ăy‡0ś‡ÙŁ!CT‚jĄÁï ‹,`^xö 4mw9t—SóbščËY1/8 Žš­mËÇö0Šœ”x~ŸßŁoZ ?À»·:©*X@e”ÄK6§ÙŁ gŠ«ńsÖ(EŚ8M&4twéP°*5pĄșa@ŠȘŁŸ73ÙlŹ„”ˆh/EƒoaŸy‚:ČŁĄ”2ĘŠíFRŃÓ ·pĘÁì:ŻÚ}L⩆N¶­-Üò,ƒŚÍő…-ł=ÜÏLр·–…gśž1ôh;5hiŽĘ›î•5Ężô+ëy{à„·È|cșÈț…íœĐúV„ž’ŐÊŽŽÒtž{Lșłë^żșFÿÔMö¶æíàBv¶è./„*LĂș±}jg‰A\ŹŽCЖ+0ŸA-yÉ2èŚŁ«ÀțœùGeŠS ă”­Ík Ï/Œ„„”mȘm҄Ț+te±„‹»n€…śmśêÍ ÜsQï7u)*ˆÆWjÌčÁ šŃù\Ę4ĆЌ7°=șĂV+ăQ{IxĄyôÓsk YšuŚMlGd‚šƒ0XżuiŒŚOĄĘčŚ^ĂőčcâÈîùƒPk8ëŰô䐖— @êŸćœQĂČ&ÿOŚ»uëúÀGi~Ï揰lB&ż[šŽy¶hMSxѐÌföNùżQé5Áqeÿ ùJ`șő“ÙÀșóúL¶VșÌ»^F}ÿêwÊŁ$˜yéY7ÿ@Ì«łOˆ–3Ž`¶ó xĘzâSЀŚû§}В€wA….h(c7' đóŠ`^RCïŽTâ.I5ì 1ïB±uBhlXâLЁo;ąèx<űÆRt‘ endstream endobj 216 0 obj << /F4 11 0 R /F5 12 0 R /F8 32 0 R >> endobj 214 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 216 0 R >> endobj 219 0 obj << /Filter[/FlateDecode] /Length 2530 >> stream xÚœYë“Ûž ÿȚżÂß*ÏìÊ©çN§3—ô6Ę^ï’I|“Îd3­L{u«‡+Éqśțú(Q–}M¶/ Hü€Œđ\Ï[ìúó†>㏏?OgGX,ŠK_­W·Á"uÓh±Ț.üdqDnâ/ÖúäŹŐòZ&ÒčśdĐv=vB§šöËk‘8MÛgőRÄNODySçjÏD}ƒßÀ9Ô+łzË;ï‰uhŻ œfKߌæî=á=áꚟ»ŒÓŰùA=w4Ÿ”Šèő1ŐNőgƒ-“:”á›ćçő_Ś ·żžö}7 ”ĆF‘ĆöÖ©à+»wŻ©ŃȘź9Žčą^ÁÓ?ÿtś·«é­„óŚYÙìžiĄĐßGf°ÍòȚ eÜB„KžŻłJṵć1’Ăf7?7ńè\-ç(f€ĆŒë„1C €6h±ńQd˜8YY6Èű8ĐÓLŹĆC 6F`púA«…ą©îΟ™Lôš«ŸOUÓź›-U‹ąDZ‘ôQZ•m:>ÖhìÛF_mźșNuWç/ł+ȘąÌÚ…òSÒBüj‘…ÇĐÓPÖۓĐ0w€mŸ\3à3‰”0›/!€N«¶(YźaFÈ晾ćpDÛ”YETíĄź‹zG,@±Š—Ibґ„p2EŐf=­‘Ò鞻^U€~àŠÒ^I&EÎöPç}Ńhț«[ß\@äč~°đ4uŐívpmšdtRșIÈ­ÊUńEßiGŒ3țŽ>#Š}ò©^”LCŁlÛKp`H2–|Û0ŐȘțĐÖL]ÓŰšńÈÛđÚ6Ü P€ź[C畜€%Ÿ—œÀp|,rdő+Œ˜Œ’—ČĘ6ĘMH}đ«9CÒpĘ@żQ]ȚûŸiŃ?ÁXêk_`-J<ëxčvoš êu #Ÿ.3 ,àșš] CŚăęŻpwzC"v…ĄAd}éTÚEÒƒ—$xd"\LÌH!]Ìn<ŽĐâÿțúęśß-áŹq(”Ă$™4b{|â``‘ƒQśŠŰf4T«#őőEúÆĐÉÇŸqW0W+ŽűŹ}Š5Ä.tȘìiۖ†\^‘g%QŸ}ÖêKćL$:=*Dhž'h|YÂOVŽv ­‚ìĄdAŸb[Ź7dŠ0ÖÔ'ìŒčVEځńu4zD燠ÖÏ”ŹÖöZpsȚńMDŠïŚ/ˆ țGÄÁâžđ=ߍb8r”žAŒš@‘AI‡~čűpJ˜xn$€Đ^EšòŐFc7 a4Ž]Oô>ôZ€Ÿ»PßĘˆȚ<œ^9l`&ˆÀŁmÇ *•iŚÍïfÀk[Öhœćƒ\śK8>Æ;ŽąÁŠA499ž4¶ùË!Ü€ÄȘ-F·ÛżšÂ#–œ;á^›“U™źŰg€]šbES9Ÿ7șe\”äüž»y‘łÆwb»TÇ@F&ż˜0ŸP ûJ'+G)NmC7eš2t>è’$ܧôœ§%€­ú™yžZçÎlń’žŽśXŚKőaq­•bU©‹źb*.3ălÆeGì ĆJ1<‚!ă3‚˜<HsȚ~‘njhà±éz]òòĆàhÏ«:8ÈCÉ>ï“}&%1șÓŽeÒą†ĂWę șŽŽšÁ»Vż gœiÇîĆÆôkœkÄÎőC±«łòß{ÖńMÁM•:±ÖŒ©*źjČUŸńúŽ‹Ț•&àŠ7ć…öX…Œ2°m©|!v}–QąÊ`”‘B<ń{S¶î^loV%ŰB Bž ^Ùò?Ÿ7·yT•`€dŻ]c±.«čX`ĘiŹî,'ŠhŠȘcAĐ< ożżY­ŽÇŁ[nîaÛțâ>Žżq’oKYÈÈ1ÔBŠoÒZû#(‘ëZ°'žóç·hJŚo±ÇN†]pÁ`ęEI.ÆS'ŁțLȚBWÿܰq›v·Bź1r] û]ӛjÛâ@ć>êêdUțw bŒç5bòó%/<`4Rż~TőŽ5ęŁûÚ„ÖL=ȚŽÙț‘+Â` wdhȘĘf9g>·zI^”›€€ÏsțđóûżȚ°ĆÀ’ăk-[kíæ{š6źÚnÏóWęźŰțqÎnęæă+cżüŹČVő`čű_˜18_dńÍĘ­ys)ÊѕNúϓ ]8șH‰źUÚmžBÄ»|·o v$~r% ±t_hîp™ŸŸŰŚĄ”RžœÌßę Á4 endstream endobj 220 0 obj << /F4 11 0 R /F10 58 0 R /F5 12 0 R /F8 32 0 R /F3 10 0 R >> endobj 218 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 220 0 R >> endobj 223 0 obj << /Filter[/FlateDecode] /Length 1501 >> stream xÚĆXÛnÛ8}߯đÛÊ@M]š›ûæ€I/iS#q7Úą`dF""‰%%MöÛwšĄl%qĄE”À>Űąš5gæpæH3‡8Î,u‡ŚxŰÿčúïöàìÙl6áÖŁ}êϖdÎ673Ï#Ëh¶đC»łÍ«/ÖÿÛüÛæĘìdóä!G›‰ÏZ%kțbŸ ÔłȚ‘SąGźĆÊ-N]Èș6WÏÈy—eQ” Wxáœ7s/Čîç^lIu+Ê­xXĄŐf{–ŹŻ€¶»/őŹc­ȘJI–ÌœĐÊpæTÛqÖŽÊ,äXMÆ;DÎláșdtžż-őCÁ‰’7äàÇ>xQLƒŒooüž+©x˜ÇԂĐxpű ô"€ >wƒśąsŽęĄO]˜WœmkŒ–‹kĆÔ^Yà+ń(Š*çG”ŹČD3yƒŚ›țkm!kaà:%nÒé§á… Ă|;B‹„"z#»„ÒœËdhvFYçOSœŽíŠ”"ÏYBD©#7ÊțûGȚ…$¶ìŒ_}ší‰9rᆇŁIX<Ÿżż'­æK[Š;Á űΛ‰úW©4ĘÚ)/‘ibŚ"-YțœH §!žL1…ïŸ"ŠhĆȚz€ąn«J§6[C AxȘDÓ^s‘$Ȱ+%îæA`±†Û[ 7„V„Ăql%”-ëƒÊȚò;=âčŹlV„5ź•s{”;‰©ŽAüÄ ôEÊ}‰Çc°·~’ÉŽÔîŽDȘÔ.ȍćv íÂ#pŻiÚ7EțœÄ(lč&„ï~ś©Í§âŠáyâZŽăÚ[?Æ”È ©)IXĄùÙȚÚÏ+»©™bU& qŸ ;ë>#żíșÏžăw‰~»Îšăóˆć°ÏSlÔș‚z Ào<ûXu1æ Ș–rj]>Ô /ĐȚÔpÀ‚mÂtjœâ#Ú­Ą$êam–^+Ă{‘pŒï xB&EČèšúâșăQۛk§‚„ubާæx[Rj€a°»v)۟ ‡Ü̈·©> ~˜ż2wgš 8ŸàȚ뜣é‡6ü ¶'ÊąĐL‡Ú–˜~1X0țE=Đet8u—Ń‘ßŒŸ:2Ée&ƒSÜäèŻźW'T‹kVsŁź2ŃpÜ_’)cŠíËVNs<ŃÎŽÓčщŁËÛ€Œ”,M[wœńŒîÍß0;‘CđzőĂE“ ʧR7Û={NJŰ E!0]0łÒéŰnEĘGőȘ\çüÏŚíu.êl·;ŽźÂB†e|úàđtüÎúČ1­ ìv)ˆˆ ú r©…ŸYÛ»NI”I—wàű 8!JżęlöC‰VČìÙśhí>h0ń(hĄ.rq@Œđșö"‡šQšûČÕĐĆcB<©ÈTww\bÌÏuü"+“y/„ۂÚÚ"xc6Xż/ÖM/ńÊ·>țyÁĄÒNçőö$WŸółœ èčŠ4ì8ƒ§Ï=bLÜĂf2ĄNƒáƒ_}éچó'd§ÏÈ3†ŽàőțEGkŻ[ł‡Ÿmû§Í‰NoN°eH`dŁ;źæÿł¶ q@|ŁőÜq±70ż8_żÄè=‘}ȘŹÈ”ȋNï™hw"œ?[\w}†—ü«CęDÈzČÄÓX|ŰÒŽŻăo`Ÿ"' 8ąŐ@rúśk\5. `űŐńœ•čŒoűĂ»N—Ą™žs©0Z6Fè˧đęGđÊœœȚ­Ö(©f±çÄŻwÌÇ@Đ"mQ9PŹăÇLxûúűăsGŠlT•Ù1Ô§ Q<Ł WmÚöOv—q4içű4"žIóÆĆíÀŒ{Żæ NĄ™âđž)őđ‹ą­ł6ü.bąÔ@gß§ű=d§„ äț3Ž Xȝ9ˆˆÈăJv`~ű«Êeïű7ò·œšôĄ ^­|üèâ:ÄĆŒPÿ ą?ț„/ËY endstream endobj 224 0 obj << /F4 11 0 R >> endobj 222 0 obj << /ProcSet[/PDF/Text/ImageC] /Font 224 0 R >> endobj 31 0 obj << /Type/FontDescriptor /CapHeight 850 /Ascent 850 /Descent -200 /FontBBox[-29 -960 1116 775] /FontName/ILEQQA+CMSY10 /ItalicAngle -14.035 /StemV 85 /FontFile 30 0 R /Flags 68 >> endobj 30 0 obj << /Filter[/FlateDecode] /Length1 724 /Length2 601 /Length3 533 /Length 1113 >> stream xÚSU ÖuLÉOJuËÏ+Ń5Ô3ŽRpö Ž44P0Ô3àRUu.JM,ÉÌÏsI,I”R0ŽŽ4Tp,MW04U00·22°25çâRUpÎ/š,ÊLÏ(QĐpÖ©2WpÌM-ÊLNÌSđM,ÉHÍ’œ˜ŁœŸœ™ZR©§ à˜“ŁÒRŹ”ZœZT–šąÇĆeh𐒙\ą”šž™Ç„r”g^ZŸ‚9D8„Ž&U–ZT t—‚Нš @WŠäçćT*€€ŠqéûćmKș…dgaqșán„99~‰č ăÁ…!Ÿ˜›™S U‘Ÿ[PZ’Z€à›Ÿ’Z”‡ź4<â8ßԔÌÒ\tYϒĜÌdÇŒôœT]C=cSˆDf±[fEjJ@fIr†BZbNq*X<5/Ę)Àà;DßÓÇ50ĐQ”ـÄÌŒ’Ê‚T„r0ßÁSQf…Bށž!P!ÂX±h¶čæ%ç§dæ„+—$æ„$„À0]ćä”_Q­kd© kiLj††f ææŠ”š Có2 KS=]L ,Œ źL.-*JÍ+' aüŽL`(„ŠV€&s͞#šÉŻ#«ę5áˁ«Já»Nœ»ča–zÔ&CIżóM“ƒX›òęŠÇž;w\[çóŽ™gîÉß4œ0·Ńš3çŰ›ûțÊ;—ńn‘ŸY¶ÆŰ(ù$ǝśgśúŽ0œeXœWҞìË1ÿJԗĆ]aKuŹčŚÿz]XęáȚüßU- ûĘŁÒ%6· tœ 6”š,˜Ő`ŃïśÇN|+ȘèKgȚśdȘq;ś)yA«æW§ïpșq3ÇÉzĄșí]ŁÏKœ&jč۟uù~xÙ?˰ «ä*ŒÖûó wOÙ­č\v»Âwv%ß|ùáđț3Ù:YłY}î|vÿżßżĂśXŻ©çd?/°yÊa^Ż:ïËÛæ-łw^fyŽás˜Òì”ò“íß[ïàӞûùśĐôż|‹g—뜊û…•š;șûăùÄàą} [ŠŸŻŠŰŚŁ˜»ś~ăź¶m7 {–ő?Òéúhr=<ÿÉ©šȘŸ qKÏűĘź<°:­Ïÿw}ÔŒ­žè8ÛŰwÆÿ”·Ă›îK3€?'”lóqf<|mżlśáăekê¶Ï™ȘŹóßVÜÙütĘ­SGq3ČÿÎéŸź­î°òûć ӏä`ĘÛ€ÏęÜ©îŻÉƒô v[#¶¶7 ;łźęÌűQàáù&UƒłŸŽŻźęíÄ!R5cçœÏXÔÖù™gż’ ±[ôțł ëQ†ÏKE\ٖôä?ó«u7+5§)ˆluȘÊfś=dôŠòŽÛŚbł/)5îwʎïYàșˆserèß۝– "?ś?žń-`ëÁÄæŐ»#„ÔK–ü.?S±áœűOU—`ƉW“òs€æöȚôć1 p0, HÎIM,*ÉÏM,Êæâg+d endstream endobj 225 0 obj << /Filter[/FlateDecode] /Length 292 >> stream xÚœÒ=NĂ@†a!ŠH[àčë”MüÓ`)€„ €Pq €AK°"qź$'ń\ș°v˜Ï?ò„Šx ǶȞwąxĄ#CFC™ŃqHá"ŃY@‘‰ub(‰R&ôĐ…AŹMFò8e™ÜMÿŒòôȘ–…ò) ”GÁe€üâž>Ț?_”ż\]“ü\ô—Ć 1s-*±?âŒÙž3·W̍šżä¶eȚ 6bfÙÂÜrëYn ·\ĂÚrly+vąqÚłłI;Ÿ4Ț€†|RÁzČuqïûˆÒqòÜÿ;vžńŹîùĘïȘòĂïźœĂčžórç8ζ›s9ÌóGô@ôA'ôB7ôCGôìșŽŃĘŃ{€}À^tû±ö„V·…zű€lîŒ endstream endobj 226 0 obj << /Filter[/FlateDecode] /Length 290 >> stream xڜұNĂ0`‘<Đ7 ś8v’&ÎB„*щFŹT(ŻŐȘ/Ț c†Èǝêš'`îđ ‰ìÄțÿˊ©Î m äN—\€ÓRWÒ"ŚÎA™9íJxŽđ©-Ž©€–CUștż¶<<«y­’{ÈŹJnÁæ™JꌜŸ?©d~wôșȚ=ÖŚ#ú ù"[òM:ÒŻÈ ę٧Ł !Č&-éVdæ±g±ÇM<}•D‘†|kĄęŰë.…sÄ^:C€Ó=?:ț „Łÿûï<ăYćùćœűžòȚœƒÌEæ%słmBȚŃ.îûà^žî‰ûâȚÚĐă&ô:æŸčwîŸç  s± sÂóÂsŁnj”üPâr endstream endobj 227 0 obj << /Filter[/FlateDecode] /Length 306 >> stream xÚŐÔMN„0đ"ɐt!7pȚ,í|ŽÌfHFM†…‰ź<€ștĄŃ­ĂŃ8 G`ɂP+“y}ÆÆŻ_!]Àûÿ1Ê­A )ačFĂ©+ZÏÄL‚6ZšÜ)x-”XÌAșSçsĄÔ‡ ·|SòìrĂł-Źrž•—đüôrÏłÍŐ(·Ț/Ës`ă‘Zk‡=áÔ3qŽ,v«è”»a[¶sl’qKq ­R€»ŰÆÈ>B iÙYÈzŠlRdK˜ »ÙFȁ…hÙkˆŐ:Èdæqˆ áä;…Űț†ì?đoïFżÎäç %> stream xÚ36¶Đ3·P0Đ30P02-tÍô,ÍŒ,LA3s3=C…C…B#cs*4ł0Ö34DѐœËćäÉ„ź`l„ïĄ`iÁ„ïé«PRTšÊ„ïàŹ`äCžž. XÀÿ†úÿ0ț?đÿó(1tp”"[Źrčzr’ucë endstream endobj 229 0 obj << /Filter[/FlateDecode] /Length 196 >> stream xÚíË; Â@ЁÊŹÀηçCÌ|Úš` A+ –ŠÖŠtYł”,!eŠà81AÒê}Íč\^€$a a ąˆHAŽ„(D† € | {'˜*FŽæNšpțń°;â8Át Bcș­0MVp9_˜ÆëpŚëšÌ茭”E,B7û‚ lìÁ?Ó ©Çœ†ßńhcÔ lĄh!śÈ<ŒGꁔ胩`Č(š€P“.àE‚7O+ Í] endstream endobj 230 0 obj << /Filter[/FlateDecode] /Length 336 >> stream xڍÔ1NĂ0€aWŠŒte@Ê»NLŠ“,D* ‘ &Œ Ű’‘-W SŻQ‘ Ž[†(æĆŽš)~öƒ3üČ^Ź€D€:QÇJ$DÉBššH č€ Ï…R$ô[ĆĄòυû'ŸÌž28ćț$1śłkx}y{äțòæ$Ú2»ÆŠÚź5댚 ȘđŹ)/tőى.ôô1ĘQÍr«C§ŠÔ ‹Ș<ŁöĘ©őÜšiFŽ™mĘjl˜Ú­Ö†YčŐÙL明 ădÂt)A&L›d25zT&̖"ŠŠÈ„YQd2•ă2a<’0L—’„aڜ$ÌÔè=Â0[šđ[ӄaV4aŠ’&ÌäíUq–UćD­4Q›Éž>íaTƎÚÙ Ž„ƒđWEĂæƒúé†ă.ŚĘÜ>æŸ++~™ńÛoZ€ endstream endobj 231 0 obj << /Filter[/FlateDecode] /Length 337 >> stream xÚĆÔAN„0ĐNX4aĂèìŽ3ÈŠÉš‰,LtćÔ„ ź!ńbő&x–,È|ÛĐOÒÉžrJÒ>BĄíÿ?€čäɆ .Kž„ìb%x.YzčæRYÊć†=KöÆÒUÆŚzźŸÒ<ă"™żńôîÊpùÈr.o™z(ïŰÇûçKžÜĘ_1©ï·ć5#ŠQ0MY“™"k @k')Pæ9‰ŹcÛ îÎ=qR9Ś…łŠ‘#gӏnżÍb^żû™«ôéœ;ËììÔ7Oç=ŠrÔÎ ćtÈ”q;Ô@cÊ!@.#˜æ7sOÀûMšcT?hʖúśvŹźđč°íb§\Çgrt6ïÉhêŹț`Ęś“è·ź>»-(›óva|űgè„”jűèFë$}ÖAùšÜȘ`h‰'C]©đŠ ~+“( endstream endobj 232 0 obj << /Filter[/FlateDecode] /Length 216 >> stream xÚíÓ1 ÂP à‚…Á\ÀŚ>ZÓś&Ą*ŰAĐÉšŁƒąłGŻÔÁƒxG‡blő” "Š.&ŸȐ!HŽ \îșàù\ÖĄ†\€Yđ`€\ű00…șRÜGpłFéq!î†FÌ€Dæt@IæD]˜Ïc愜&ˆ,ßbԂÄ(ÊzƒK:]ÇJ*D©AD«š+ih­x©y2cÒLÍUÁłč.HOž-čyÉ]ÉꇮKæśhŸ'•Lÿüó·ÌŸś‘‰aߘ^ßüČvÄú"Ȍq endstream endobj 233 0 obj << /Filter[/FlateDecode] /Length 501 >> stream xڕԱŽœ0`# $Útö „59–ÒJH—DÊ‘rU I™"Q"„:èRȚ+!„à5îÄ @çÂbâcČÇȅá[Vóì<ÛÇûLÈXJ‘ÜÄy*^Ÿ’qžˆ<=Äy.ČC'©űœˆo"żIcčÒ|Čü€·żűô5Œ=…»FÓpśN$R†»Ó{ńăûÏ/áîöĂk‘˜gûxz#c>€2 Ќźka` ÌŐ±—šĄòńNă èjúj`.Êÿtà, ‘†Çuàš TÜAwĆx"*k@]@9̖ èsP°Ÿƒ•@ôkàęìSÿ"x2çĐÎö©lő?Ő4ó€}všȘÔœó0Űç“ÍG@ÓÚ8|žژ†â ĆFđšÆŃê ÊyÀ># ŹšqNq,@iŽ- Űž €qúuđ`ă&Æi7§z 7Ž š Y‚:ű·Óxoă<,A`Ž­L㭍ßîÀ4ȚPÓó:DxXÏÄŃ#š Ê%`XÏTW#è `î |»/(Nż GϰcIqÚç€MPœ°Ăźč<;ęőŃv§ę§6Bg'hUlEsêò  i è`hŠăqa°Đ„oOáĘ_;Ű]ć endstream endobj 234 0 obj << /Filter[/FlateDecode] /Length 310 >> stream xڕѱN„@Đ%$Ûđîü€ ÈÂA#—S).ŃÊPK Ö\ëGmá‡Pű”[ÆÙ].Ń;- /ËìÌÎ,ȘŹćȘ„TŠ)šJźj8ÍrY+PE.Ó T^ËLÁCÏ R%ÏjHéÙGżgÜ?ńM˓;(*ž\CYđ€ĘÂëËÛ#O67ŃÚ/ÛK@Ôé… œ#cU76 q‡cdq ÉYàLőÔ 2ÒĐæŸC=Úä†ìcÄA ąEJŠożjącíĄÖIx©üżíœ=sÒ`Î>rń™uNúęCìí/ʂ;?đőÌŸŻƒț(Í©ĆO© 9łCÙȚîŰń‡%ïs©ó±űnΔŠ>NÂiMęLç$őgșÀhàˆlÔ4îû@ûÛi^&š°ęïԀĐüȘć·_}3z endstream endobj 235 0 obj << /Filter[/FlateDecode] /Length 304 >> stream xÚćÓ?N„@đ!$Óp„}Àa`…ÄÄdŐ(Ć&Zy”ŽĐhÍz3Ì^o@9Ɔń}ÀțQbŽłšß„đfűŸDĄÊsÒJkŠf*Ëè0œȘ<Š8Ó*O)ÍùQF·!=PœLaÍśLÇJGŸßžč—óBŚ”&2ž P‡2(ôôű|'ƒùć aĘ/‹SČëc‹kiÄń ŽŰćŐÿrŒp{ÔBôè2<ÛűÀŃÄÈJÛș€æ)pĐgj+b«’á<Łòőd@L€ń†ól±vGpŽcˆoawŸOžƒóőKÇ!w?š.:?ÌmÎHŸFòç› Vh„Œă\š©ÁžŒWSòÿW]Ë«Öç1€}±ąìP őŸÙFxŠ” yVÈ«yäžâ endstream endobj 236 0 obj << /Filter[/FlateDecode] /Length 287 >> stream xÚ”‘1NÄ0EœÚ"’›!sې­v”€D $š8PR€ N$ŠœÖH{‘Ę€Le˜‰#ąC.žŹńÏüï‹sXc-8oÊ'…3+źtƕàĘÊ xáziÂ)X>>8c˟Їgœ­t~Áêü΂Ϋx{}Òùöö ŸÇku DƒȘ ‰Z•P-Šš©_R—!u) )Ò!#Ú!ášh\':"?d) Ƈ%C!ËžëŠKˆú/ŽéwHŻ˜‰„3}D6żąĄțÓÍCLÊÔ3d^␎5ył6Œ0Äê6œ˜ŐEÏÚèà1účîl9ë‡,氖TjŹçŒŠÄÆüôU„ï>ߝfŒ endstream endobj 237 0 obj << /Filter[/FlateDecode] /Length 305 >> stream xÚćŃœN„@đč\r$[èÈŒ€°p͑œšHaą• –mâ“m||J ČăÎîAN/~tBÁoÙì0ü'GAžŁ €Ä8 ȏŁ8ÈLČeÇžÈÍV†·>`’Æliî„L9ÿxâæ^ŹK^ă"á9F2ayOÏw"\_ž ŻĘČ> stream xڝŃ1N…@à%$Ûpæ.à‚ò*ÈS)LŽòjiĄŃúŃy­IŒȚ;Š żł$™éWLjțͧ|p͂“”06>, > stream xÚ­‘1NĂ@EŚÚ’sï°Ś‰ăĕ„) â@‰tHqD˞ʖĂG˜r ËĂÌzMH$kYÏłÒÌüÿ]”U:/•N”V“yșXšăI^ŠșREQŠyźŠi•æ…șÍՃ*òE:™*MO9›ńç~ËÍ}Ž\EÙ”*u”«ȘˆČՅzz|Ÿ‹Čćć‰Ê©ÊŐ©Bw@Ž;ĄŰ€8B"i_v҆ŻV {ĄÆŠ&¶4ąavGŰ ¶5ˆìŰKšïŰ1Ăo é˔ÿÇqîáŸC=‡zż|8_Dö‰\Śže~ÄÜ ű&yà;ćÄL(7GÊ‘ŰŚ.ŰߙüÀŰ3ô”QŒÂéh (Y'Q°nf ÌŰ߇Îg'€ËÛ,ïłëé]:Œcł6nYośŰêÀÓËú3Ç>?gœ·nü|żŚëŰșP°ÎȚë¶ń$C†|š„ä“o°ć:¶Mä`ű?ÒE ŃÙ*șú/N@3 endstream endobj 240 0 obj << /Filter[/FlateDecode] /Length 236 >> stream xÚíÓ±jĂ0Đ Zü >èĐ)Ȕ&Č„†Žx€S? íŰ!Ą™“-żćOé'dô |=Y1ŠĄC¶ænyÇqîĐlą„sš€R8É„”86Òć8”čtwhw,ŸiÜàÔ°gš8ËŒ~ˆy)Č4FdKÔJ‰Ź\áçvś.Čùú5ڱ,Ÿ|A!Ș΀? é@‡_šț7i„‡aÄ ą"ȚZÀ‘ŸÒ ’€‡‚êQÀęžêa€%ò-4cpFÓâŠĂm‡ż I?Ò~W\ áú ìùÔŒyH<ÄèƒX”âù!”Ÿ endstream endobj 241 0 obj << /Filter[/FlateDecode] /Length 166 >> stream xÚՏ1Â0 EÚKđ/€›žMÚNH$2 ÁÄ #æfășŒȘ†TˆĄˆ‘[Ïҗÿ—e¶ŠŠ Š”BšQa0łTæ`U’ְƧ8jœĄóŒŰBƶ–‰ÇĂIVN&{°‘ÉeœnƒëćVË€Ú. Ł~I·DžßO‚ïDđ­hŸ2ìÏà áÇŽÄâƒ.Țű?GÌ}/ŠńŻqɕ“»'Áÿì endstream endobj 242 0 obj << /Filter[/FlateDecode] /Length 145 >> stream xÚ323Đł0Q0Đ30P06Ńł0UĐ5Ół4W024Ó3°T0łÊX(€**Zê+Ą™„螁)Іä\.'O.ęp#3.}C.}O_…’ąÒT.}§gC ÂőtQűÿŁțÀ†ú hűÿ‡á†QLuÌ`àƒ<0ŹQ—«'W ¶wÉ endstream endobj 243 0 obj << /Filter[/FlateDecode] /Length 274 >> stream xÚíÒ±JÄ@à9Rl“GȀ…•›l’»M@\8L!hćš„…ąuÒYúŸJ:_Cđb—bčßYs W”ȰĆ7ËüŐo«B›g:Ë8·șȘű`©kËv‘ëÊpYäÚXŸ1|Ï6/u]p&S”6ćÖÁőZ5*œb“•*=ăeĄÒ朞nUșș8f#žŰœ0ŒC—kj‘œ§(ˆÜ@ôa#èA‘§o<ă=Y'èڀC,1œ“”#‡q>BŸî°Ć} $ź«}Hž 7‚Ù›`>a0ìŒl°đș> stream xÚíѱNĂ0àC*yÉ#䀝pâÄub a©€D$˜x€¶#ˆÎíÆkùQx„ŽŹü8 Č1önùNș[î_JZËčÌs.*YŚ|m€­XŚ•Ž%ëȐȘâ­âwÖ&n­8­K+•țs°yëFdŻlŒÈٔ"kžűócżÙúùŽUœÇ±čg‡c ű–\ Y‘;đ 7à ß逧ŸŁ[‡văÍíŹG „^E\ęą°8cyÆőHŠ‘NĂ]đoèÓïèŁŽŸ1s"J5ńЈ—ɉ—Ÿ endstream endobj 245 0 obj << /Filter[/FlateDecode] /Length 267 >> stream xÚ­‘=nĂ0 …ed ĆG/PYŽ$'ž$-PÚ)h;vHÎòŃ|Áه@ „Đ(\tŹ$àÓ/EŸg«Zm*ĐJk0Vm<”FŐìÚ©”kjUZű(áŠÖÊ8ĐÔ­3Joç/ȚżäŸ‘Ć\%‹gšœ,šžœż?e±=@IëûČyÄ aŁSĐ.a1G›”1»đ7RæAü+~}ÄIÌ0ϓk˜*șcȘ6՞łŹ #$Íü€ ëÉêČÖ&Ÿečâ> stream xÚŐŃœJÄ@đ )Ûä2śn6Ÿ—Àá©`Š­|”ŽPŽÎúfy”<•)BƝl8Žƒ“«w›ß™Ùü§HYŚš€R˜źeUáUȘR™ä˜WJÖ%晭Öű’à;æE&U…ÊȚ2Ëe–œ|òü&¶ˆŸ°,D|u"âf‡Ÿ_Ż"Ț>Ü Śźln‘FMF™ôŸ€î žP26 ™ Ș–FŸ E4yŒEg›i-‹ÎöèBFŽ gDŒpÁ>°ĐÇüSŒȚYLp Àț—=ìüúgӘƒšŁ Ă<ä|HžaôČà„Źx&ŻIń(†]ćÀ«ì6Úöc\‡Ü”g}OĐÎèÀŁ{l»|ț'LŽB§ß îńűtfV5 endstream endobj 247 0 obj << /Filter[/FlateDecode] /Length 206 >> stream xÚĘÏ; A àX-LăÌœ}Ì>+Á8… •­ –ŠÖÎ <‚W±łô ¶k§°ł ą Àæƒ?RDƑTzÒóP…2°Ë,AĆ!J1Tôœű8Ç Ëdą—yœI?ü8ÏDS wȝp»łș‡ËĆj*Üfż…>çgÔm€œ.ŽÍlƐëXžŐvlŃ0PÀem€ §Òs©9><ŃÉìɎÈèjÉlˆ^nÖȚlütę?BùŃ Ș,8ß-wé) endstream endobj 248 0 obj << /Filter[/FlateDecode] /Length 307 >> stream xÚuбJÄ@à9SÒäȚ ón6·›»\8L!he+š„pŠÖÉq/ßdaÊáÆ™€Đ+$đÁÂììÿÇmŹ)Wh”žÚ˜ȘÂË™­GçŒ)+ônk /ŸŁłkł±šŸ/±Őùç·dŚ$ù#zŸä·ž.“ŒčĂÏŻŚ$ßĘ_a!çùŰ\#3Ô#1A<w° :śO4Š< @ÔÊ±ŁžŐo±§ƒè8‰ô-țł­ÚՓ™Žv±ÚëÈô2ÀlÊ4,XČޚ2âI>‰Îz {}dò–5łŐGú„fe­ŹŸÎÔ ă™Ń5àžœș,áW«È‚4ąœÆû‹TÿR,+ùQڐR*•jÊ€S͝ŽKnšäáL_  endstream endobj 249 0 obj << /Filter[/FlateDecode] /Length 209 >> stream xÚŐŃ; Â@Đ‹À69‚s7›lܘJńŠŽòjiĄh­7đJ ^Do»-BÆIÒD±°qŠ7 óiFéŽP€|%âÚURR‹H‚Š*Xù°… D€ŠARšèycčჄ{ îM s/™Â~wXso0‚OuU&#@<#šït?™ż™ŐŽ5ӚŚRSz*e…YiÊ( {ó韚łkÌúŻÚ>fMŽŠ0„ż4đNÿbx#OÇ iZye.iY€¶áă„Ïțą, endstream endobj 250 0 obj << /Filter[/FlateDecode] /Length 229 >> stream xÚíÒ;jĂ@àqeŰ&GĐ\ +­Ž^I•Á° CRùIÊ qmß WÚ.ŚűJ'ƒŰß#™\8MZ3Í7ÌŁ™™€F—%':I8ÍuQđœÉtiÙč.3¶YȘMÎφßŰ:i›p"a­ÓÆ\N<œȘY„â ;§â;«âjÍïÛÏæl$?§Ő‚ŃM4đ- j‚'AG#ôÍ­{Až€ïȚđo„ëèźc8J-8ˆ€ïz4żžŸhçŃ >{tc„ˆ"0’Ż č3hZïxa@Că3€™RËJ=žhńŹI endstream endobj 251 0 obj << /Filter[/FlateDecode] /Length 284 >> stream xÚuĐżJÄ0Àń”…,Ć'èïìŸkZÛ©p*ŰAđ&À»ŃAŃMl7Ç{„€ĂœFć^ n7”țü%`*M†|~À—ˆ2 ‹â0Ž!IĂRÀùtˆ :J«,\ưMà DNŚ2ˆi‹Ž ażxxäëšGśç<ș<ćQ} /ÏŻ;­ï.!Ąyë+`Œ580œ–02™+‘éKlșJąÔh~; _ ŸAŻpTđ N  .áƒ0(ìÿbt†8* Beƒâ5ZBŁQÈ Oh#À^ƒąż'ű}œÁĂO Š>Ű Öę úÌÀÆ È(y»AûÖÌQÈgèÎțÁ1èĘEè/·0ű‹ üșæ›*ŽŃ{ endstream endobj 252 0 obj << /Filter[/FlateDecode] /Length 354 >> stream xÚuÒ=NĂ0ÀqW*e œ ŸùhӐL‘ Hd@‚‰#¶JÎÆŰ+uè5Rőé–!Êă=Û©ˆ«&ËïIqô—í$_YÆŁ Šx<ò„_Íą<ˆcž\ă˜ód¶fùORünÁ#|ÓyÌckÉË»»,Ęđ™§©Țó> endobj 8 0 obj << /Type/Font /Name/F1 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[469.76 469.76 470.08 469.76 469.76 469.76 704.4 470.08 469.76 469.76 260.84 417.53 260.84 260.84 417.53 417.53 313.07 313.07 313.07 521.99 521.99 469.76 939.52 0 365.3 260.84 286.95 547.79 521.67 521.67 782.51 782.51 469.76 260.84 469.76 783.15 469.76 783.15 730.92 260.84 365.3 365.3 469.76 730.92 260.84 313.07 260.84 469.76 469.76 469.76 469.76 469.76 469.76 469.76 469.76 469.76 469.76 469.76 260.84 260.84 730.92 730.92 730.92 443.64 730.92 704.4 665.43 678.69 717.66 639.31 613.2 737.35 704.4 338.78 482.62 730.52 587.08 861.09 704.4 730.92 639.31 730.92 691.54 521.99 678.69 704.4 704.4 965.56 704.4 704.4 574.22 260.84 469.76 260.84 574.22 730.92 260.84 469.76 521.99 417.53 521.99 417.53 286.95 469.76 521.99 260.84 286.95 495.88 260.84 783.15 521.99 469.76 521.99 495.88 365.3 370.52 365.3 521.99 495.88 678.69 495.88 495.88 417.53 469.76 260.84 469.76 574.22 156.37 704.4 704.4 678.69 678.69 717.66 639.31 639.31 737.35 587.08 587.08 587.08 704.4 704.4 743.77 730.92 691.54 691.54 521.99 521.99 521.99 678.69 678.69 704.4 704.4 704.4 574.22 574.22 574.22 808.86 338.78 521.99 417.53 469.76 469.76 417.53 417.53 617.01 417.53 417.53 469.76 260.84 359.07 315.68 521.99 521.99 521.99 469.76 365.3 365.3 370.52 370.52 370.52 365.3 365.3 521.99 521.99 495.88 417.53 417.53 417.53 548.11 260.84 443.64 600.34 704.4 704.4 704.4 704.4 704.4 704.4 848.24 678.69 639.31 639.31 639.31 639.31 338.78 338.78 338.78 338.78 717.66 704.4 730.92 730.92 730.92 730.92 730.92 952.7 730.92 704.4 704.4 704.4 704.4 704.4 587.08 1044.3 469.76 469.76 469.76 469.76 469.76 469.76 678.69 417.53 417.53 417.53 417.53 417.53 260.84 260.84 260.84 313.07 469.76 521.99 469.76 469.76 469.76 469.76 469.76 730.92 469.76 521.99 521.99 521.99 521.99 495.88 521.99 469.76] /FontBBox[-104.4 -476.4 1148.4 1001.7] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 253 0 R >> endobj 254 0 obj << /Filter[/FlateDecode] /Length 210 >> stream xÚ͑= Â@F,Ûx„ÌÜ?7YS QÁ-­<€ZZ(Z'GËQ> stream xÚÍŃM ‚@Àq„…0›Žà»@󡣓«À rÔȘTËE­őh„#žt!Mo^™Đ DűÁĂ7Ă_Ï3źS\J0’G)ÌąTò̀VŠ'ŒŽž1pRp…X+ű))cn’ż3Ç Ë &žÉÄÆ-1Qlá~{œ™ÈwKP8ÆbŸ”¶öB€ ë;Ș©È3DG;íé‚Ńòšüđë9*G]"Mˆtb=ï ôƒVȘț]0Ü7âGe(%Łx”ŃïÓRdÊÍÖÛż–ʐ, endstream endobj 256 0 obj << /Filter[/FlateDecode] /Length 155 >> stream xÚ]‹1 1ESçÿ&3ٕ5íȘ` A+ۀZZ(ÚçÁăxY<ÂČkTlœóùĂW±ńdˆ0"SŽÈTC°ÏÁÈ»(±aìÁLŠdPÆy6äÿ>Ö;]mWYÔv–mĂÇĂi«mœ#_Ă·† IQE…Ìg’jRÿCőxÓĄ‹mlć!OčËMźr–‹èiĐËj:ç endstream endobj 257 0 obj << /Filter[/FlateDecode] /Length 113 >> stream xÚ327Ôł4R0Đ30P°0Đ36PĐ5rL <3sK ˜‰BŠĄBĄ‚Ąmź`„P&Іä\.'O.ęp $—Ÿ˜ôôU()*MćÒw pV0ò!\O…‡ Ä~x€ËՓ+(ą endstream endobj 258 0 obj << /Filter[/FlateDecode] /Length 386 >> stream xÚ”ÒœJÄ@à=ź€É Ù0Ț%„À©` A+@--­3VÚćîU)}…HŠk/ŰDXvœęÉáO-Ç·IvfgvČ4rQėQç|?ĄEÆł( ҄§y,s~ó;ž.“`±àęȘȚŠ?w\Ęș«Ò /é;7<„Oܰ<㶏7nž:?âjm–ć1GÄnN€(+4F_xïˆŻψ[é#Š‚ *Úăè±z Ű+ô„Va Ô #ÁW`Ą +P˜-„òA 6tŒ5ŒˆsŠYÀ£T-|àXPˆ ôŰUއ 6„ù€•s€7|ązŸ„™AnôFXK ń Âù߂٧ ÿ6—dëż0'ÜA0[…˜êS„ÂÔȚt7ȘTśç…jŚÛsÓĂC§·]·¶ÏàÙÎo {êrwđ'ÔÚ ę}ïŰ13 LÏŠ™™:™™É*=QŽ1Š'жȘasOJśâ »“è† endstream endobj 259 0 obj << /Filter[/FlateDecode] /Length 287 >> stream xÚuÒ1jĂ0`-9‚ß*ËNb7“!mĄ íÔŽ;ŽŽłœuÌrĘÀWđÔŹ†,ż>E*IŸ'$ĐÏS±\Šë5H!%,„HSžJ©XAŸÉÄz…ÌDžÁk ç™X i)mçö—wŸ­xòLçxrOGxR=ÀŚçśO¶7 kSV·€4JZŠÖ{1.Œ"/úЋßÀ‹–č۱Ú`ßžˆ›Ò TŠRĆuç`Än1ŁwpÂ>š188âzpÀ)đ Ed6v„ZcŰŰ çQŁaa҈5(xga€Đ”Ç ·p҈f Žș‡áEt烋hőaÿńsF­0š1…g”ȘŚíYŹôña& ~Wń§?‚tO endstream endobj 260 0 obj << /Filter[/FlateDecode] /Length 233 >> stream xÚœÒ=‚0à’.ï––p#AMd0ŃÉšŁƒFg8GńŒ ”ۖ€ÆŸMž|Žx_2ž‘4J(N K`ÊÔÀ!Ć$I Í  ΐò˜p ĂiV;ö'\”8Ú©}8Z©-8*ŚpœÜŽ8*6s`jÖcč€OJ9ˆBc erÙ u„.VÚ&ڶmh…Ż•žkcSiïčk'ÚΞ «ÿȚȚû!ú“ž/Œïï/^ŸŚæ`ss ĘülźÖÚíĄ7œˆÀí­ Ç^Ÿ=#Ó»ïțCęxYâíŻąšO endstream endobj 261 0 obj << /Filter[/FlateDecode] /Length 192 >> stream xÚćË1 Â@Đ‹À6!s7»1‰Šą‚)­<€ZZ(Úo`á…ìŒFÀ h—"ÌwÄFÁÈÀ>üÛĐôRČÆZŠ­q)”;òE‘3ILI74±Ł„Ł uRgą„Ź\WfIűœXŹu–ë`.=Œ„ąƒ|B»í~„ƒl: 'ùó!ἔú”:ŹÀżpyq,Őÿ7X/ œQ7ù„Úă+*ošZüÀĘç eÁ”C5…ÒëQźgOâŚ+ endstream endobj 262 0 obj << /Filter[/FlateDecode] /Length 282 >> stream xÚ}ÒÁJĂ@à =ö’G茀I65MB *˜ƒ '@=zPô&€àŃC1ŻRïB_Ą Đk —–]ÿm=˜€›9,ßÀ,ÌìNš%~RhŽ8ôEFGÉ1„Ł‘/“ȏĘ z€$ü,"TÓŒăæÛ>)xpƒ:\ „Ć%=?œÜó`ruJù>-Έ±R#6 ‘Őÿ„țäHę64úqëĘ3újhæÍ,úXT9€zmj IiÓƒl­ZbuK5Ú_Y”Á «$©ZRh?·J;Z•vM”ÔmÍËm–ùșGőpŐŃÆ[ôHșUÔ ïHcyz„ż1òșRxłÏj¶6Œ1Oïń€űyÁŻŽy endstream endobj 263 0 obj << /Filter[/FlateDecode] /Length 311 >> stream xÚeĐÏJĂ@đ čä2/`’m›ț9Ș‚9zòP=7„/ßä{„=æ2ÎnK”–À/|Ëì0łćlš-K.ČąàČÈÌŠŻŠú3<[šlYđ|5ÉÊż~çÙÔdsÅ~‹É$[ü»ńüŻë8Òș8żÓ’8Żïùóăë5ÎŚŚl4ïc}Ă2’ Kié(R ,ÆH`ѧÒ7è+vŁ”€ˆ:”Ć·Úa{ŰyCŐț±?18:€?¶Śą­Œ©ł‹ŒoMzKГ DĄ`$"š•Û‚·EЉ)ԑA:z58jÄ9…ŰÙz;/ö’Ğٟ˜ž™8Ùi9ú”q/€æ°Š7Ò}·žĐF!.#$;$]eS€șĆ©.š€Kńm?țúŸFź endstream endobj 264 0 obj << /Filter[/FlateDecode] /Length 245 >> stream xÚuÍOJÄ0đH…,œčAßl›1ӎ«Àš`‚źÜ ŁKŠî„VŒXŽòŒAĘeQúùҊà ~äKȚ»9ÉmEe^–dËÜŹéh%Ą&[›ŒźÈZ“Wkș3ôHöXî†J9¶’ßŐïŽĘƒȚ6șž‘:]\H‰.šKz~zčŚĆöꔌä96g„ ŻZ1í3đà†8`LÁŸ@îȚÀœĄđíŸìŸęއ6 ügŻÄQEûƒűâ]TMœI4€ÓŽyò4Ó»h7ÛțŰ)üĄßłEç:©_Š›ŒŒEÎÂë!…ôcP·ŁJFƐeïŹÏ}ę -ÌÖ endstream endobj 265 0 obj << /Filter[/FlateDecode] /Length 238 >> stream xÚĆĐMjÂ@à1– ƒŽ70ïÌD'“•‚­Đ,]yuéÂÒn<Wz‘Áeò^_’R”.]ÈÀȚïŰ^W„ŽÒșZ/1Ź6*u€±ČÖĐsFč4?§c•Ä—ó•f2šqžŒȚ9EFÙ>?Ÿ–2N^Áp\‡Ù`“ˆP\YT+ńòdö <û]„ì[ˆAH[ÖÓQxÊ7(ˆò>6ˆČ¶š}:y|<38‰”âfƒÿÏ'țmRoXÚÿĘùhżÁ¶//ê š‰>—7Ș{}ηsț9Êäôă±F endstream endobj 266 0 obj << /Filter[/FlateDecode] /Length 227 >> stream xڝżJÄ@‡Û\ȚÀy7ł·›œVSÁ‚Vśj)œąu¶>Ò>J|ƒ)·ù9ëyˆ­,|ìæÏ7ÁŚ–O‰-3y¶ÎŃÉJÚü™łĄĄœmjșwôDŸqÖŚÄú‚~Ś«żwfәj«uŠșÒSuŚôòüú`ȘÍÍ99ÍûŰ]0ô‚©X €}DˆàÓn^`æiáŽÄXŠcÄR2Æö€Űï1òĐ#‰?€ąűŸ{GĆblșƒjà#ŁT5dəUwÚ©xÊ'| Æö]òY(z1—čę0ÆÁ° endstream endobj 267 0 obj << /Filter[/FlateDecode] /Length 235 >> stream xÚœÏ1jĂ0`AƒÁï‘%ÇČ<Ր6tÊڌRš5QéĆ|”B/àlŒ•_6ÁnŚB$űà!=é:‹\“RÒ\ „h– 0€„čĄ,O„ÖôŠè@©QÂd$±LD–üîxĘóEÉă-îńx…+<.Śôń~Üńx±y"…z(ËgrX¶ûkŚë흔gŰČÖĆŹÜ~ș>à€kŸ° }Â&ò֑ïę.F«óšÚÿÂțíđÎôćéÓ$uqKŰgFò6ôSt&:aą‹}Č?–aȚ¶,‚Îą—/KțrŠ%c: endstream endobj 268 0 obj << /Filter[/FlateDecode] /Length 230 >> stream xÚuÏAJÄ0àÈ,ČéÜ`ȚL_&iGWŁ‚]șò:ˁQtĘÎ òĂ ùCáű‚Ű1S`ç=Ż4Ź)\zKŠŃ»Č gO/JïBAŹ;êqœú}ăio·•ÍuÎæ·:bóêŽȚ^ßw6ßȚ_‘Ś<Æêš0œAÌFĐő™àˆ™`†Ł sŽÒgJZą;ˆÂȁpśC[CJiÓ`ÂüáŽÈż4'ê‰vąŐwG­-„EÊ֒kĘț Ć“à_ú™z.èÍR±7•}ű 7·đ endstream endobj 269 0 obj << /Filter[/FlateDecode] /Length 176 >> stream xÚœĐ; A бŠńæÎw?L%Ź N!hćÔÒBŃzsŽ=Šâ<€lÌ`±Ú/x!!I‚ČŒ2[ÂÄrÊÀçVy Ep*°·pï­rŽÒ8UžßĘQVQê-ÏIœä©ă .çëAêj=Ëő§Œs zŽ‘‡HíđŽô5˜Z‚nSÁÔL“@ê@€=ÔBˆú‹/ÿVÔü˜ôŸčˆró>—ú endstream endobj 270 0 obj << /Filter[/FlateDecode] /Length 290 >> stream xڕÁJÄ0†§ôPÈ„ûBóŠiízȘŹ ö° '@= UôșíČ/Ö}“>Â{(' "(LàKBțÿŸłŸPŠ’Zi-ÏŽ* yZ–Z­KiêBՕ4ŠPŐč|*äëŚ]óźȘR™ú‡ćńElZ‘?°Pä·Źy»•ïoÏ"ßÜ]ɂßáÙ^Kâ…٘†!ìR q>Ùư E|ŠŽ·«9„pÎh$DfŰĐÔăÄlțÍà 9!3ä»Z„\7fÆ|ârÉÿž ôŹá>™Ÿé@üÍȚÿ6ž™'€Ë€À -3AbœÁ{G6Ę‘9u æü'ăoe·ś^Ÿ€óè“ź›žé挫»Ùi‚ˆ,đŒâŠśŸ3ÿ endstream endobj 271 0 obj << /Filter[/FlateDecode] /Length 147 >> stream xÚœ‹;Â0 †‹2 ùű$Ž ‰ČÈ€FܛŃCŐâȘȘö·ü/NȚfFČDž ë=̊€ÈfÂن„g7dMRFҏ‰íÒ/NWš žŁöÀm”źìđq^ÀŐûȘ[YÖŰÎDŠ=/óap4êșŸhT#b€1œóš‰TăÁŠÀá 2ÒĄ± endstream endobj 272 0 obj << /Filter[/FlateDecode] /Length 180 >> stream xÚŐÏœAđ…d`^àöË}ŰöŰBBćŽRAš7#ś$ȚB!7æJl~ÙügÿSŹó^YFQb”ő9kTæÁŸHS§â –6àžác0|Y_čô{§XËŒæęÄŐxÆáÖ9 6ŽOmDê`Yuńrëá•«Ą9żłäÔ endstream endobj 273 0 obj << /Filter[/FlateDecode] /Length 128 >> stream xÚŐK9Â@ ÚÎŻ˜à”—\ېpJ ùûQ„%”‚'03Í\©SÎ Â"Ű«b­nj€Z8 Ú>qÓàŠx"yÓeˆłÍçßÇőAƒQŒűŽâÁ'툜kŒSN[xj_k;ÌĄT‹J(S(óżiZ•jíÎRž˜ß endstream endobj 274 0 obj << /Filter[/FlateDecode] /Length 226 >> stream xÚćĐ1NÄ0P/.VrłGđ\ǓMHš,- ‘‰­8lčj‡p„H”\Á]Š(Ÿ T€8côțhŠqÍ„«*òÎ{Z{ÇL‡,Ą ȘÎĘqNÚĘÓ Ó-Ueîj&/Ż(d\~żžȚ›McČ+Ù3Ù菘Źč û»‡É6—'ĒżbsJ“†’ERzPJÏêÇćdÛYϓbÓ Ÿ°xG iԏoèCšÚôVŃŸ~JEt+ +ĐÙZˆÂŸÒąűż5ÊoŽę2)5śšæú-s֘íȘç7Ü endstream endobj 275 0 obj << /Filter[/FlateDecode] /Length 180 >> stream xÚÍÎ; Â@à‰[¶ńÎÜĘ!»Iș@Tp A+ –жÆx%;Ïá-R„]G,TŒ€ |đÏÆÙL•23وpH,:CȘ,Đf€rÂ5ámAȘÈŃpYËmś}±ÚÊÚKœä=©§Œ"”ŸáaÜH]ÏGHœ_я1ˆÄą…Šœ·}öÒЊ :1ˆ"„^¶y M<łńmòŁű_;țNéàS9ńrńĘÇÙ endstream endobj 276 0 obj << /Filter[/FlateDecode] /Length 234 >> stream xڝĐ1N„@`6$ÓpȚÀ­ŰʚHaą•PK Ö`ŒŰó&’‚đûăJâÆÎLòM^23ïă϶֗’Ù,“ÓÌ:''9‹J|álčïčòàäY|îlQIÆćKg«üűÆę“Ù7&œă9“^ńˆI›ky}y{4éțæ\ëCÙ\Đ”PLAL‡:€Ÿèé†VaŹuŽ1%:%˜ck ҁ†?ö-đźJ»UȘĘâîŻÁbđ?^[zí~ś=$é™jł&dæPGéÄ)b9Qą9ë:i_oèDôû7Ìecnż2ÈÙ, endstream endobj 277 0 obj << /Filter[/FlateDecode] /Length 166 >> stream xÚ3¶0Đ3łT0Đ30P06Đ34TĐ5rLŒM őŒ LŒ őÌ R  Œ őŒ @ĐÄ(lŠȘ#9—ËɓK?šŽKßš„KßÓWĄ€š4•Kß)ÀYÁȇp=]ț°ÿág`ÀÌÀ~ű {Ăvy†?lö ÿŰêț±€đÿF >üáÿÿŒh˜™öűĐ^F8ærőä áɉ٠endstream endobj 278 0 obj << /Filter[/FlateDecode] /Length 238 >> stream xÚUÍÁJÄ0àÙ-DÒŸÁf^À4ijëÉÂȘ`‚ž|őèAŃ«[êk…}ŽzÙsŽ{(§ì”đfű‡ßTÚ:4ÚtF[‹G5șÒêąÆ’żêï->ĄłVÛ żČČș.ț_Ü=Ê„—ù-çd~É™û+|y~}ùòú yëwŁ?GêŐ&BČȚȘĄ 4ŠŠâ›H|uŸì€hœ·™${3+ŠmĂŠ=š8@@ÜœŽ HiA4 sąqÎqhxÁZ”ÓOČ?žç‹;ȚYÇ=(Ї«q‘fáM”łŰ„,Ê /o~łBˆë endstream endobj 279 0 obj << /Filter[/FlateDecode] /Length 181 >> stream xÚÍË1Â0 Đ nYž‚/@ÓŽ) H$2 ÁÄ€‘+„‰kő.\¶UŒ„ŠĄœYzÒ·ż3›Ș"ٌÔ(D 98È ȘMQć;„#X‡Êć`xlÆëQśc{„—zĂ=©\‘Ú/á|șì„.WS@Îmô3ˆ Qˆ"ĄJtŹŠ"6|±íüŻâŚű•Z{Ô°wȘÕœĂ˜*zAŻÉƒmDŸ„p QΜ\‚\Őț endstream endobj 280 0 obj << /Filter[/FlateDecode] /Length 226 >> stream xÚ]ÍÁjÂ@Е„œä Ξ٠›·€Vj„őÔh=zhћüŸàŻűęo^/),;ÎF\­ÌÌf˜La H!%€dęKÓ%tȘD–Ă—‚oĐF‰<IĄ”&ûń9çÒ'ŽÇ“ ­đ€|…ĆÏrƓáû͗±|ÆbÇŰœ Cʟlq·r^ë=Z ž,ֈû`ćĘVű,pmqWà†ìy=,‚±#›ŰUWm—êjԐ.ú bçt“”Öû;_ŒÛ·ÖŰK/<7›êQŸ|\òé:Çæ endstream endobj 281 0 obj << /Filter[/FlateDecode] /Length 268 >> stream xÚeÍÁJĂ@Đ =ö’2?àf7M7őšŠæ ŐS?@=zPô&$âű ꕂę…Ї\SrIaÉ8kÛ$DfæÁ03ÌXiĄ5H!%dǁ’":pąÄDB(1ŽàNÁ#„Z‰(IĄGéȚÉíŸ&ܟÓ"ś/i‡ûÉXčuÚ84€Rí­ÛVgCąS¶fyÇ ërÖJÏzqk•öíæöŸeÇŒńóÏ7\‘lïącL:”őĘ€äG…öêÛZ ŹÆ”òó„ßüHLT endstream endobj 282 0 obj << /Filter[/FlateDecode] /Length 229 >> stream xÚUÏ1jĂ0Æq… -9BȚ*ëEr›-4…vÊjh3fhigû=BŻ"萱WĐ2z0~ę*ŐCôàȚw„±+ČÆZrÖ0Ó cńäVlü’ü’MyG/LŻäJ6ŽÉbŒcsËŚĆóIo*]p§‹=NtQ=ĐûÛÇQ›Ç-1öŒVś^f-A‘@ß"m}Q1ń#Ă$~J?éfńK.ó‘žaAÚ%Q†ÄôSĐ%fà21±h›%BšțA*„*1ҁPő€]*ÖȘUÿ}#Łw•~ú™*Ą” endstream endobj 283 0 obj << /Filter[/FlateDecode] /Length 225 >> stream xÚœ»ŠÂ@†#)Óär^`'3:ČUÀ]Á‚V>€ZZ(n»öĆÜ7É#€Lò{2oh+ßpæúŸÏ€ŸÒ$€€Rd”Ô–>F> stream xÚ3±°Ô31S0Đ30P°0Đ36PĐ5rLL őL ÌLôLLR  Œ őŒ @ĐÌ (lŽȘ#9—ËɓK?šŽKßš„KßÓWĄ€š4•Kß)ÀYÁȇp=]țÿ?ÿÿÿțÿÿÿń ~Ä üÿ@XˆùĂ `ú“ù sčzrœÔ' endstream endobj 285 0 obj << /Filter[/FlateDecode] /Length 296 >> stream xÚ]ĐÁJĂ@à -–@_ Đ}7Ùv[(Ș‚9zòÔŁEoB^…|_% àEđ"úń–ÐńŸ–"ÊČÌîìîÌúÙÜúÔ$6IÌ4±nnvoüÄÙԙt:¶Ț›sgźÌdæŹ›#M±ŒûśÄÙ„^æ:>EžŽ‘ąăüÈÜ\ß^èxyŒgâM˜ïŠ€‰k•—j@]ŰôˆČ. ¶`EßÌćĘ's”őđDïÌMŽę'æ¶ÿ(( T!dè?„ìV’Ç[ú[š5ËőÂpK”`©@  „t=@!hÂ4hëTèˆï…P€nu0ú"nÎÂł€ŸŸx%Œ@—*˜_Z<ś†?à‡Z)­©„RÀTĂ_ôAźO~ÒIę endstream endobj 286 0 obj << /Filter[/FlateDecode] /Length 268 >> stream xÚ­ĐKJÄ@Đ4sÁș€t~d Ìb@W@]șPtH<Gđ*q5KŻńYv HY„ ˜„4ŒŠ ~Ęi±6i‘‰"È"cŚp’đe!MŹÉ-äYlÒn-<@RX“ÆńɋŰdÙ~ĆÍœȚÔ:Œæ<^pŠë-<=>ßépsy –ăß°>ƒ‰ˆJW‘+O]ă”RÈx‚/±ĐâÔû„Rń(Æ© §a^áŽ#§œ ïÒŁkih„ҍ%WŒG\ć–û,€ÓêïB'šö0 %­<áM:ÿđÊ#—2wGŒÆ—đIÔ7#Q'ûyˆŐìăžRÇ?Dżˆ\@šÏk}ő "> endstream endobj 287 0 obj << /Filter[/FlateDecode] /Length 280 >> stream xÚuMJĆ0…o預I—lÀŽyŠć9*<ì@Б P‡§à–:s‘·8«PzŒiE|ŠŸpósÏčÇźŽ­U©ËRÙR›Jòf””FŚ•Ș«•¶VĘuÏśFW„Š«^ŻtUíÿžŸ›VW|*Š3~"Šö\=><ƊbsqŹ ŚKٞ(€ $OĐčH±Ć”ĄÇ˜Ă»A"4AbŸY0æœûBÖ9~ÚS:ƒöÄæÿ‚~!6űn?c$?ƒu)°bCïÄțvÄN_ Ïx!ô“$r K#ABŽ‘țƘ}#C>ŰóŒ3†w NƒœlńăÙĆxBŒ‡óì‹û2>Äi+.?Èæû endstream endobj 288 0 obj << /x7b 254 0 R /x7d 255 0 R /x2c 256 0 R /x2e 257 0 R /x40 258 0 R /x41 259 0 R /x44 260 0 R /x4a 261 0 R /x4d 262 0 R /x53 263 0 R /x61 264 0 R /x62 265 0 R /x63 266 0 R /x64 267 0 R /x65 268 0 R /x66 269 0 R /x67 270 0 R /x69 271 0 R /x6a 272 0 R /x6c 273 0 R /x6d 274 0 R /x6e 275 0 R /x6f 276 0 R /x72 277 0 R /x73 278 0 R /x75 279 0 R /x76 280 0 R /x79 281 0 R /x7a 282 0 R /x30 283 0 R /x31 284 0 R /x32 285 0 R /x35 286 0 R /x39 287 0 R >> endobj 9 0 obj << /Type/Font /Name/F2 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[489.46 489.46 489.46 489.46 489.46 489.46 733.85 489.46 489.46 489.46 271.92 435.08 271.92 271.92 435.08 435.08 326.31 326.31 326.31 543.85 543.85 489.46 978.93 0 380.69 271.92 299.12 571.04 543.85 543.85 815.77 815.77 489.46 271.92 489.46 815.77 489.46 815.77 761.39 271.92 380.69 380.69 489.46 761.39 271.92 326.31 271.92 489.46 489.46 489.46 489.46 489.46 489.46 489.46 489.46 489.46 489.46 489.46 271.92 271.92 761.39 761.39 761.39 462.27 761.39 733.85 693.23 707 747.62 666.04 638.85 768.1 733.85 353.15 502.89 761.04 611.66 897 733.85 761.39 666.04 761.39 720.43 543.85 707 733.85 733.85 1005.77 733.85 733.85 598.23 271.92 489.46 271.92 598.23 761.39 271.92 489.46 543.85 435.08 543.85 435.08 299.12 489.46 543.85 271.92 299.12 516.66 271.92 815.77 543.85 489.46 543.85 516.66 380.69 386.13 380.69 543.85 516.66 707 516.66 516.66 435.08 489.46 271.92 489.46 598.23 163.15 733.85 733.85 707 707 747.62 666.04 666.04 768.1 611.66 611.66 611.66 733.85 733.85 774.81 761.39 720.43 720.43 543.85 543.85 543.85 707 707 733.85 733.85 733.85 598.23 598.23 598.23 842.62 353.15 543.85 435.08 489.46 489.46 435.08 435.08 654.64 435.08 435.08 489.46 271.92 387.35 329.03 543.85 543.85 543.85 489.46 380.69 380.69 386.13 386.13 386.13 380.69 380.69 543.85 543.85 516.66 435.08 435.08 435.08 571.04 271.92 462.27 625.43 733.85 733.85 733.85 733.85 733.85 733.85 883.58 707 666.04 666.04 666.04 666.04 353.15 353.15 353.15 353.15 747.62 733.85 761.39 761.39 761.39 761.39 761.39 992.35 761.39 733.85 733.85 733.85 733.85 733.85 611.66 1087.7 489.46 489.46 489.46 489.46 489.46 489.46 707 435.08 435.08 435.08 435.08 435.08 271.92 271.92 271.92 326.31 489.46 543.85 489.46 489.46 489.46 489.46 489.46 761.39 489.46 543.85 543.85 543.85 543.85 516.66 543.85 489.46] /FontBBox[-108.8 -478.2 1196.8 1005.1] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 288 0 R >> endobj 289 0 obj << /Filter[/FlateDecode] /Length 274 >> stream xÚ”‘AJĂ@†S fao`ßLg&iS7 UÁ,]yuéBŃ­æh9JސeáęΟ8P ]Jű3!ÉŒïË}‘ź7bSkĆY›f9óë°WH¶:çŁ"ÏÓ|%ÏNȚć­Ì /gOßééŐlKł|”Ì™ć­8nć|ŒŸ˜ćöțJž—ć”huàĐc ?șS  4áŃP)& *ú@7i犆,5čTTä[‘Œh‚žL ]d mwhf©#ó‘ê hòđ»‡țÏÏžöĘč8gœ™óśż>Ht4űą7úŁGú€WúźéțÙaèÁ.ìĂNìĆnìǎì9tmÌMi~#Žkš endstream endobj 290 0 obj << /Filter[/FlateDecode] /Length 270 >> stream xÚ”ŃOJĂ@đțł07°ïN2ÓL7-T…f!èÊšKŠnmŒYŽ’#dÙEyÏù:• K ?†Œś}…-őąą\ç9čJ;Gçvá?•47„ź•EĄ G†^Èș =Ï ÉŐÆî<<«u­Č{Ye2Öżêz{}RÙúö’pÇúŠRNŒOŻőș­pżòf»TxŸóÔ 4°eiWA7óR––LYö0x}ˆ,ƒΎÚӁ“ ‹&żëaô&ÿ3ÎgÎțsŻfyÜÙïÏ!“˜òBnÈ9"OäŠ|cÖÈœ = ô‚~ĐúBoèŻęîœą_u]«»/łE{“ endstream endobj 291 0 obj << /Filter[/FlateDecode] /Length 138 >> stream xÚ360Ő3±P0Đ30P°0Ö33UĐ”Đ36S024‰››èYš)€**ëY+Ą‰‰±ž±Іä\.'O.ępC3.}Sc.}O_…’ąÒT.}§gC ÂőtQű!ÿ€ęsc#ń0?`ÿ!ÿŸh@È$.WOź@šRb endstream endobj 292 0 obj << /Filter[/FlateDecode] /Length 109 >> stream xڝŠ1ƒ@ ©ęŠ}Ï>ë Ś’DâŠHĄâ@Iÿ‡(-;ÍŒŽæÎ©°6‡zÍ1ĂDY 1e6Á€ű"æÈ”CNNœüDžÚBa€% T)”7¶uŸ)ޟ~ęÏòDuoô*Ô{N endstream endobj 293 0 obj << /Filter[/FlateDecode] /Length 353 >> stream xڕÓ1nƒ0`G ‘X|û5R RÚJešÔN=@Û±C«v†(sn©ß{ہ(-ȘèłĂÏûĆĄŠV2Ta(ăX­y•©8‘i–š(•Éf­ąDŸźä‡LŻ#•™W͕†‘JâÉ/ïț¶đƒgč ęà^fk?(äŚçś›loäÊìi[ÜÊ#,ęËł*çÍò‹î™˜uÇűE·l9ë†y]łĆŹ5c·±«“w+­śúdOcHôrìÚč7ÖŒqîŒč”»un…DçscìY—cśÎ”ńÂú8öŃÙÜ|0ƒŽȚKò~jmísòț(čG 2ŸșÜĄ9YÀ$É­Š ÎGf°È ÚûÓ5zAÆ&’q4XcÜ©+òŽ\‚śT4uʄÔwêĘ`NUwƒ9Xœ»E·ÂVZct8çnJČgŹ9êËžÍÿ_ûw…ÿôìËű9 endstream endobj 294 0 obj << /Filter[/FlateDecode] /Length 360 >> stream xÚ͓±N„@†çBAČ /`rû. w°\#É©‰&ZùjiĄŃú0ŸŰú&<•[ÆÙeśÀxčZ ű&ÌÎ ÿüšÍZä%—BJ^Tą(űyV ”â*WBćŒŹ ±‘ü)ăŻŒ,7"S\Ò­d.ÊŐï/lÛ°ôW’„7ŒZłŽčćïoÏ,ĘȚ]òŒâ1lź8ÒŐC‚h,”ˆ{Kìˆ4QŒšˆŰÚ|š{@›JŻP_€M«)<›æJ DœMso Uu}°łì9zv–:Kš*¶ G†șD8Î8ÌȕŁÒnrGÆÎh?6Łvù¶sÒùQæÔMԞ"ûMț”Giw‚Ži0ŃA”c€ŠOô}ŰÌDŸȚˆ_a«…Mc¶?ÄÁ}\âÈ c–ÁMû:8ŹÛŚiôNÄEĐcˆĐ;ÖÄÎoëdŽm=Œ„ŹÛÁË~ ûW$A„ ÄèAvʰûÒżƒ endstream endobj 295 0 obj << /Filter[/FlateDecode] /Length 129 >> stream xÚ310Ńł4R0Đ30P02Ő3°TĐ”Đ36S06łĐ30Q037Ś35VH1T(T061Òł4U0B3 S=KT Éč\Nž\úá &†\ú F\úžŸ %E„©\úNÎ @QOŚÓE/űÿƒÿĂ(9THü±ÉćêÉoóü endstream endobj 296 0 obj << /Filter[/FlateDecode] /Length 178 >> stream xÚíË1‚0àŽŠ'`ó]ÀŚÖÂŁŹš‰Ltòêè ŃŁyÀÈ@@ˆ-‰!FÜüÿá}ÿđˆ$† H”ŽÆ`bP’H (Ž1Ò°Wp‚š±"MÉD˜Œ>ìŽ<”\l.–`Š\Ű\ÎŚézȘÙÏiçÀڌëș‚:oÏ? öU‡Ń(ߣè!ï8Ü{žydÌĄò(> stream xڍÔ=NĂ0ÀqW"yéò.€ă4ßąą€D$˜802€`N€\Źœ‰à±C”`?gAű;’Ÿ” ËI*óLÈ€ČLä%\Ô"+!•2UeU‰"ƒŚ> ©€Ű6 ÍUօh~żńòÎś-Ož!MKžÜCœćIû_Ÿßo<Ù?Ț@jìŰȚcl3㘘‘ăžpíxúŸf^9jsŁÿ˜Łê}”ŹCCXłrđò’ĆÈÈË+Ă~ŽG<áÄÓArƓćŁÂçv ÍŻc…ÔËOĆĂCwŽj^ÈïZțô‡IÚ endstream endobj 298 0 obj << /Filter[/FlateDecode] /Length 231 >> stream xÚíÒ= Â0àW Ađ‚iÓ ‚Pì èäÔŃAŃMšGëQ<‚c‡B,m+AÁ͗ć{äś=âč6”92ÊrN=ŸrÂw逡đ<êrÜŰžGáö©ă ˆš­nXïHk…žOŹú}b…s<N[b‹1ÚY^€á!†”i!èjZiuSyËÖÈÚJ)4”$„.P*†łÒ†J7è(%”jÔTJk?Ó»{“ŠêȚÜŃU_*tăŃ!Ę”Ìçîæ1Ғ„L­H–§ÈżŸSńŐ?™†dy _'F endstream endobj 299 0 obj << /Filter[/FlateDecode] /Length 311 >> stream xÚ”Óœnƒ0à‹:yÉڍ{§üLHi+•ĄR:őڎZ”R·0ö±xŃ‚‰1¶äŒÉú Č}ÜٙHù6ØÇ1JÉw Țˆ„§3!žL0IS~+ńMà'Šä\`LO’ïű6qgŒ~°}ÉąÌ%‹1ŁŸ|ÂïŻŸwíw(h|–ś§ÔÔÙ`{cyeŽdŃśÓlívìŽ;ž2ÆÉ“+˜]ÓB“DžqKűœ1V,lÿŸ­c;æÂûöżŚV~*+oV>; aÎyhŐBŚĆÔK{cčđŒ§hÇćçufŚV­Ç}û*§îŚœ çdĂ2ț3>àqćșSëą_{Ü@Ű­őEŁł€ź”©JMŠĘSÿ;]Æ @Mna„†©A ŰCɞÿìé|À endstream endobj 300 0 obj << /Filter[/FlateDecode] /Length 193 >> stream xÚíÒ? Â0đ– Bà»€ùck’N…Ș`A' ŽŠÎŠx±zàèP[b@ÁĄźâû–ß7|ۓ"&’#ŒẢ@_‘H€äŒ$ ‘.aÍaçÍê)É0zʶ8Ә.A1L§ 8Šz‡ęqƒi6AÓ]Őc(‚çĄöJ­ lY ÙF¶@Šët MÏéšÔ© ÍÉ© uČ/ÊœòO:{]Ú yŻëśČ^öݟTćȚ9m-<Ńxńę‡f endstream endobj 301 0 obj << /Filter[/FlateDecode] /Length 487 >> stream xÚ„Ô1ŽÓ@àÉZb$7>Bæ8özăÊ«$\ AĆ€’”cùbÎMæSNayxïÍóL’4Űҟ?Ÿ”"żì)Ëj›Ś{UäEĄÊ:ßUê”ÿ(Ëò1Ú«z·Ë·•úVȘŸȘ,öÛ|W«îzÿ”?Öçżùú#}iÓÍUVeșù ȚTéŠęš~ÿúó=ĘŒ|z«@[ÿ”}§\Ò 7 ŸțœskH'}oȘÆĂ`2„#V{zË ŹÓ H&†A`}"p+Ì,Àt «‚c˜ëöDKpôoEĐx€jžŻ‚!±êg\Òt jšVèpFÚzšGÚz$0 n ?šmĘPMhځȘœźBB€u–Ž”d€G%›#Ì`㊠·°Â11=8č€=cÂ֖áÀĐÙfÆŻ€a€ȘÓ-ĐűiÿÍu€­é‹đ4íÈ`Čc„țȁ¶î,ƒ"$ %m0LâA"> stream xڕĐÍJĂ@đ 9Tö’>@Áy7óŃ Ș`‚ž|ő(šè”ĘGËŁì#ì1‡qŠ›B ő 9ü˜dföż)‹•ź—hŽ1˜çșšđ*«ô2Ç2/užcQfșZák†ŸXšLŚ5~ŠȘÖĆőéÄ˻ڎ*}ÆÊšôËJ„í~ęŒ©tóxƒŚĄlo‘š‹ˆÈSp):€XŽÀŽĐxhÈ Üà{~ ‰ž#;#/mäM':8݇Ę~^ävŒ‚Dÿ–“‹mPJŃAČïłúùváÜdÊòű)›òt§\6>v~’8û[w,śwŹ=IÒ-Èț XŸ7.`=wĐô €y‰ă)#Ś €’ öśĄ.ö4rà>ńêźUOżCök endstream endobj 303 0 obj << /Filter[/FlateDecode] /Length 273 >> stream xÚĘŃÁJÄ0à  čô:/`šn7I{ZXìApO>€zô (xkm„àqKăLÚ.*źàI°œ|d2ùÇFŚ6V›O §}‰ÖUÚŚè*«kƒw>ą]–Úäߛ…vćç·jĘšüUù%VK•7WűüôrŻòőőŽ—Í9†műë~ęŒđoĐ„#v#z€U=;eœ@è$ƒvś‘…ތ6ìaĆa€Œ š.€9ƒïê’rÂöq0Ąÿ đ8ÚÏĄçož#ż†c‰A%s˜”êo;nČđGđšRaÆ žbŽ+ÎKRq‚ > stream xÚ”Ń1N„@ÆńG(HŠáû.àË, ÉȘ‰&Zy”ŽĐhœÏ›7á”>ß&šlk(~™ /äęqumś{ÎmžsYZWńEQÙ}ÉΕ¶ÜČÛ¶jű©àWvycëŠs}\U[·ę;ńűbÉŰ5&»á]eČî–ßß>žMvž»äBÏ˱»bàDà) ŃQôŽh#>űc,C$ }$“Ny’”‘ŽżĐ±@żÍxEçC<3&" ŸțŸEgđ+4vĐ +ƒî‡~E·mu3 ęđ„ARàSó$@ˆc écB¶œö—ș-­œŸ+á!æș3śß_ń  endstream endobj 305 0 obj << /Filter[/FlateDecode] /Length 275 >> stream xÚŐŃœNĂ0đ‹2TòBß ś8IìvȘT@"L<0"sühy”<‚ÇQ»€±„P‘˜ɐŸ#Ÿ?țg ŁŚ6ËRWÏ «]‰”sș°hW”^|*đëȘÔΠŒÎ\h[~­x|QÛFćhk•ßàȘRys‹ïoÏ*ßȚ]bÁăiŰ\!É3@ëćà nFűÿà&t°qHFì`'èaÓ-]"?~!ÓpF$8@FälŠ|öĐW¶>ˆăŠ}DrDś >"= ű üpú:ńÊ1„1–~N,FÜ㍁· „°äq)ù@ú<3Á‹dö@!!Żźuÿ ƒšìF endstream endobj 306 0 obj << /Filter[/FlateDecode] /Length 273 >> stream xڅ±NĂ0†/òPÉK!ś8Ic:U* ‘ &ÖHбæ†7óŁÜ#dôć8(D °eČćłîÿ\YšÒąl%Ö”±O*oNkŽ^îZWżÆ‡ ŃźŒqk,eZfìj^qżŚÛFwè*]\Ąóșhźńùée§‹íÍ9Êmó~l.9‰čƒ…`ÈÄäÄAq·$YĐ3)aĂœąAŠcFéÔóđ‰–Č#FhĂœŁSß |ÌńŚHO€ÙÿŃęŠlBű É_ˆĐOÀ”–ûރ˜`jGńÂAô,™_E–âQ%ƒĆYyƒƒôșĄ)ŽŰć ]QJ.FőeŁo߯Kț endstream endobj 307 0 obj << /Filter[/FlateDecode] /Length 198 >> stream xÚŐб Â@ ЇÊ}A7óȚ]œóz„Ș`A'?@…nöÓú)ꄎÄxUAșé`QÊp©Pr)Q)ź ö-W”Œč5hbÍ7!îQE†ë„ËHžQ ëKR&Vš‡LÌĐj&Ò9§-ÉbŒĄ«e:A"*ęšèžłȈ K~žvșTĂÙYÁ€Ê»…ś2ïŒKnü§yĐXfTWp1jőÿKśŻ]6MÙòĐ> endstream endobj 308 0 obj << /Filter[/FlateDecode] /Length 359 >> stream xÚ„’ÏJÄ0ƧôP脟Aç̶Ûۋ…UÁ=zòș =(zȚ>ZeĄÇ–Ž3IeALi€É|óe&MʛM‡…) Ź*S·xč.;So°Y·Šï°ź+S­ń„ÄwŹûÊ4%òŽma6ç!Ïoév—źž°éÓŐvòĘĘăçÇŚkșÚ>\c)s?ĘĘ 3EÌń[Űó  O0đ˜X ä d#a`„…ƒ,MBæ)™pVƄ€Œ,©ȘŒ?œ”đžëú|L>?“śŁTLȚ/“óŸ31$ș$s"qŒó*ŻäüB;šČđÀ|Êyű…ùłÀ8PÒšU«ùČÀ8âOǘy_ˆO·‘xôôÿŁ9}‰!J$Ë4iȚhTÒGÇ#ìa8áò†žOcæôŒŸ|Ÿ9vőچkœyÌ\„Àâ['çrśGúąś €zżd ©I‘ ôv—>~Đ«Ž* endstream endobj 309 0 obj << /Filter[/FlateDecode] /Length 206 >> stream xÚíŃœ Â@ àHEáĄyŻŚŸ‹íTš vtòÔŃAŃčúf}Ąc‡ÂyW«(ê*&CŸ „+x4@Á…@ßça?ä>Ą %—’.‘À•‹[”Òă‚Pè€(à= ,7,I™ł@"æL0ô™“Nqż;Ź™“̆èêțÚŠ#TyW™ÈŸ@uƒúœ­Y ÀźQ˜ł ÎńŃȘqRy«†ƒNï[iŽăz[„JˆŃzőșÜú5%\ă-Ű8eó N{Í endstream endobj 310 0 obj << /Filter[/FlateDecode] /Length 162 >> stream xÚ360Ő3±P0Đ30P06Ö31SĐ”Đ36S023Ś33W0ł4Ń32SH1T(T02Č  €ĐÜÀHÏÌECr.—“'—~ž‚‘—Ÿ‡‚… —Ÿ§ŻBIQi*—ŸS€ł‚!ázș(ü?đÿĂûÿä?üaàă ìX1L€€Źś?™űûLüˆÿ̀pčzrvŒÏÆ endstream endobj 311 0 obj << /Filter[/FlateDecode] /Length 131 >> stream xÚíË1 B1Đtžb.àf6ٟŽ_SZy”ŽPô~ËBűŹDœ3ŒbŠQI3„E ÊŃ0ÍŹ†Đ‹Ârâ"Űw8!ÄÀ©‡ŽZ‰ìí°;ÒPÉo ù%ȒŻ+\ÎŚùa=CŚökÖ9ÆÛäîܧG3țę䟄•6O—!°Ź endstream endobj 312 0 obj << /Filter[/FlateDecode] /Length 248 >> stream xÚíÒ±JÆ0đ+ß b!śŠÍŚ4ô› Ÿ ftòÔŃAŃ9:ùZ_€Đ1CńŒŽ ‚ž9˜[òËq—ćż±Țž+SUèŹiŚžßšÚcÛzătź6ő/-Ț`ë\îW\걯oŸ \\Ëmć9ÚÊÊò'Ëp‚w·śWČܞ ż†…á©W4ąWˆ”_F3&M=3Æ„ 3úb#ČGzX% K(A}1Æ t"ŰăĘĆÀ»3v5 đÌPăć;‘ńôâï|F‘ĄżĂ*Łû"#țăπÓÄâÄÁr~ yäÙλ| endstream endobj 313 0 obj << /Filter[/FlateDecode] /Length 203 >> stream xÚíŃ= Â@à )"‹˜#d.àf“ęQ«@T0… •PK EëèÍö(9‚„…0.‰ÄBàŒæ{Ć«Æ$‚(ž(%WûC. êĄæ:E„$—)nÜŁÖ)…‹Ò 7Ł·ÁzÇò‚Ć+4†Ć3ԊĆƏ‡Ó–ĆùbŒ‰ëM-&H6€Ê'Č!”5îQ+@PŁÊÎ~ Yì€* KĐ [Dt…ÒĄ›=Ń)[Ę s€ȚüüńžŚÜ čŻ`ӂ-~< € endstream endobj 314 0 obj << /Filter[/FlateDecode] /Length 258 >> stream xڔѱN„@à!$ÛđÌ žÀ± \uÉ©‰&ZĘš„…FköŃx’‚Üű»wlÔäJCÈÇf3łł?ÖluÛpĄ‹‚«J›šŻÊZ7ÛČĐĂÆ–șȚòsÉolìŽ\à1u«ÍæwĆÓ«Úw*?°mT~ǶVywÏïŸ/*ß?\s‰őiÙĘ°È‘v"Nd ÈKD=\`'ê)C,c]*3Al.Ô»ïjŒß(Í  Kæfoê&oâ&4—!qŁ7ȚÈĄœà€ óÒEé$ꗗΠsźsŸę{ŻpïłłÏ' 9­č­9†\ڜGäĂ3„đw?ÿӂJqê¶S_Ç endstream endobj 315 0 obj << /Filter[/FlateDecode] /Length 271 >> stream xÚÍÒ±NĂ0àł*Ւ—Gșűü_šÒÙ6 łÎać­kńŹrΏŸ9·ĄĆș^ÙU…%>Łg‡r5um]8*č2›ÎwŰxS\cŠènđőćíŃ›Û ,y}Xv—HƒŠ˜Eœ8à`Àw&XÁBš žÈéúH=í`- ÚCÎP‚,J}&h"~LXŒˆ3Ô1†đ;žÛżÇ)ę<Ś|ä9„K JOLMarȘcŒęxÎ]€GŁKĆŐ é%cH$™)*íĆu4nú‘~­Saź:łęlFšg endstream endobj 316 0 obj << /Filter[/FlateDecode] /Length 193 >> stream xÚŐÏO ‚Pđă!zĄč@ϧoü· Ź A­:@”lQÔ.šŁyàÄŚ3ŃÂÄÀoű>˜Ć%\ .F19Î2.$‘óL/’\Fx ń‚2#žŠ(ôPò$ÿ98œYQČ`”°`1± Üàíz?± Ű.0ÔyˆćUćuf à5đĐÖàk_àhÚpíÊêÀՕgúqȚ;y~5XY U;œß«Zæˆö  Ÿ•­J¶{%ÍÈh endstream endobj 317 0 obj << /Filter[/FlateDecode] /Length 279 >> stream xÚUбNĂ0`[*yÉ#ô^'ÁNÚL‘ Hd@‚©k%`dÁœôÍ̛o¶UßN‘ZEú’ÓÉwìłË† [„O_ÓUYÛ„#Ś8[zòUië†^Jz'W5¶^QÇŚ+ëŻ/O<ż™ugò ygò{Șj“wôùńőjòő㠕š§Č»%9šö—…Őì‡E)”ăÔŒŚ4™Œšy!ÍĄ•#ìE4“"Č;©àśżę™m2C;’±ÁƒÒIt8`aRőŒ¶Zđ3ȚĂÙ)OÌŠXB2¶·rLƂ07$qą3ÇkrHkÙw_JjŃÂä6&‡ Là8HĆüž‡˜rÆ:Fç9Ș–łž—4à_Ì]gžțȘRҙ endstream endobj 318 0 obj << /Filter[/FlateDecode] /Length 203 >> stream xÚÍŃ= Â0đW„,ÁwÓÔŠ]Ș‚<€::(:·Đ‹Ő›ôŠń5TT\$đ yË?ČŻx8@Á…@/äÊÇ^sùAT7BêûŚîЗ}(è„RrĄž7V[kæ.Qz̝ąRÌŐ3<ìæÆóRU7O=Fc2cÒo¶Ț{y±zđü`i-Źč5”Bme-ÀIჷù?·„_-(çnᘠ”%$ć Ă6% ĐĄ_è’9$d昔M4[\»J> endstream endobj 319 0 obj << /Filter[/FlateDecode] /Length 204 >> stream xÚíŃœ Â0đ“•,]ïLÓŠ‰: ~€|utPÜôŃò(}ÇÒóbQ| żƒû‡ƒł‰’œ*©j-3‹íÄʎFÓ5Ò€˜eZêW nјT*‹Š_f9a^ˍä"^ ”"žđވó)îw‡”ˆł!&ÜŚm>Br!Q}R ?âÊ ‚Ać_qùŒâ ÎăüŒł‡ ˆšT-ˆ *»ÀŸŠŁŸ|ń=!žƒłQ ^Šrbœ‹ù ò; endstream endobj 320 0 obj << /Filter[/FlateDecode] /Length 262 >> stream xÚ…ĐœJÄ@à )Ûä2/àfó{—*p*˜BĐê@--…+„œÜ‹Ć7É#€L±ì:ł+š  S|L1żŐVÉ2G%•ÂŒ’ȘÁłŹ–›«Č…eQÊŠÆû Ÿ°Ê¶ČVÈQV™Ź›uĆĘŁŰu"Ęc‹ôŠˆŽ»Æ—çŚ‘înÎ1ŁÜ§Ę@bG€ÿ4Yk@[֞Ȑ ”=ČühÈÈ۫ɑMŰȚÎäĶlk§…3͛zïHjÖȱHC~8#ûNòB'gűmÈÒb‘30Î!0±Žsxߟ<8'8Ž^ćœAő^pjàK~k Xé>ŽôęíŻ“”S»P\vâö;Ar endstream endobj 321 0 obj << /Filter[/FlateDecode] /Length 288 >> stream xڅ1N…@†‡`ò’-äÌ\vÁg…yj"…‰V@--4Zƒ7ă({J Â8;‹F…âc';?ÿWïvm –>”xČŚ¶ÁșźŽiĐY§Ï|,ńk[kkŃđëœŐ¶ú”đđŹ*î±qȘžæËȘènđíőęI‡Û ,ùĘ%@¶€ÿ‘†„ÈïˆF šrț†ž|»±çŽ4Ń 9}0ȈWh…ĘšF.ŒNé’ɜŽ0”‘^èጜ80٘ ˜(€m. r„/öqmŒÿMùÿzÒg9ށs§<Ò·1Đś1pebÉÈDԉ%ƒ:±dP'–”Š,)Mƒd ’!pÈ„!°Ę áù›êȘSwŸ•}Ű endstream endobj 322 0 obj << /Filter[/FlateDecode] /Length 328 >> stream xÚ…ÒœNĂ0à‹2DòȚ ~'ÍO;E* ‘ &@ u"©úbé›ä2f°bîÎ)„„<|ČìóÏΗZe©ÔJk™æJŻäyȘW*Idž-T©e¶ÈÔȘ‰|‘yČT…–4Š,Sșüòđ,Ö”ˆïe‘ŠűZ–„ˆëùöúț$âőí…LpîŠő„€Èöÿ9A`íƒv‡úšolKš‡ëhG†(5h5‘sDČ"+; #ِ˜5€%Ă/;” ÙÏnQ*hÇúÖ'± €őNlSè4l&rnŰ6•Sł#èÆy6 ŹșŃŃ Œč3ßmƒßíÂSûèÔĄúĂfȚwĐÎçÌîg·d_awĐ.r¶Ą„3Ű”À9 Űvœ„ŽGéĐˆÒ UËv>Ûóż°f€5P±ÖłŹžȘĆĘ'WyӐ endstream endobj 323 0 obj << /Filter[/FlateDecode] /Length 159 >> stream xÚ35±Ôł0W0Đ30P°0Ö33UĐ”Đ36S01łĐ31R031Ń30WH1T(T0¶0Ń3*B3S#= Éč\Nž\úá@\ú æ\úžŸ %E„©\úNÎ †@>„ëéąđÿÿÿ‡ÿÿɃ`’Dț“ÀdˆüÁ$ÿ0€HL’€†ąr”€ ÙÀžH.WOź@KŒZ endstream endobj 324 0 obj << /Filter[/FlateDecode] /Length 333 >> stream xÚ}Ń;NÄ0Љ\$r“6]|œ„8»Ùj„$R AĆ€’ÒvńŃÂM|„”.ą ă±ű ĄH~ògÆ3NgvșßȘZŚ”êjĘìÔIŻÛ2»VwÚŁë­șoԓ2ŠŐí©ȘéÛt§Ú˜wò0ÈêVu­Ź.Ő¶—Őp„^ž_duž>S Íăt8Wˆ.AôžäÄ ˆ F–(ę ăč_h„ś9Mü\"x7":NˆĂ8èm(lДݰ"Q^ŠÏ ùdĄìÿ⟘RÆćÌ22t‘ü/ŠÀüA±ČÈč\Ï$Œ €‘<°Rï|ÁȚsÊ1‚Y0.eМ±{ÆÀ áYqŒO™™Ê§uW2Ӟ±ÈPŚk†«`–”ĄÇfJf]gèy Ődüšé0B±F–ˆÌ™"6ßéÿD^ òæ(‡M‹ endstream endobj 325 0 obj << /Filter[/FlateDecode] /Length 333 >> stream xڍŃ;NĂ@Đq,ĆÒÉ ’čț€ib)€„ $š8PR€ %>š;źá#žL±Úaf“ „xYkv>;EŸ‰ë Ó8M1ÏâúÏČ2ź.°HùTc™çqZáS†Ż˜—V`Êż’ÿÖ'7_Ìź5É…In°Ú˜€œĆś·g“ìî.1ăł?¶WHt€†Q!c`ïhd֎†ÈBäškBGQ82àlD4À§ ”ìùÎVR1ŁČaęOüœ¶Ö's ©·ô„ˆțàêșÀ*Ò.‘ƒ„`ĄF™Hꘑg24ăCŹ -Ą‘ŻàSŸĐè«sgÂVžéĆù3Ò.ށclٌK„nr‚Äž2›`™ÿ ś,,șP;ë"íł_kŚCŁï)őzȚX OÇ[Ț­f—MûœËúù]ű«>ÏÀ qæș5śßÔêg> endstream endobj 326 0 obj << /Filter[/FlateDecode] /Length 241 >> stream xÚœĐœNĂ0đJ"yÉ#ä^ ŽÓ8v:E* ‘ &Š`NŁŸXò&~"—VśG‚ ˆ‰»á§NśQë­l,)©U•Ô†ÖŹ Ő„’MŠȚH­éč€=ik€mHÓ%›Ÿ OŻbډâ‘j+Š[Č[Qtwôțöń"ŠĘę•çšËîšN—HN‡ qá ô áaኍp^ ‡îKôOp€ L٘±3 9lYßłŽŰk‚G˜°1…;çl€Ÿ…=ëpçx„)áœÁœ -ëĄë!ț7Á&pőÇűöÿÖațN<| ŻŠ^ endstream endobj 327 0 obj << /Filter[/FlateDecode] /Length 311 >> stream xÚ­ŃÍJÄ0à”șĄWo0MíßöTXìAГ =( {Û>Z}“>B–Œ“IWüO¶‡@f2?UÙêuF•Ńy 'y­›ʶĐUuYjÓÀ}OP–….NÁĐ_ŚFŻDÜ=ȘMŻČ[š •]BÓȘŹż‚—猕mźÏ §s8öçàvˆűn]BŒY!șÈ:‘àèĄOâ@H]`@Fâ@@Fz±cèœÇRnbäŚ!"âh)P:ź:ĆÁ·‚8Jîvą6cÄYp–+¶.őŹ9ńcÏțÀêÄwö9eƘäWÄBô›Őù‰«!撆$Đq#ú¶MzvꘙnÒR-ĆŃRś:Țf:Ó\pà)áÈk€X?Aș :‚FEÉŐEŻn>ą=kJ endstream endobj 328 0 obj << /Filter[/FlateDecode] /Length 338 >> stream xڍһNĂ0àăFj%ä Zżč@n]©€D$˜x`dÁš†‰Ś o’GȘ!òá·Í­U”á‹uû\’&ë ÈUD‘Jâ 8QÇqä§*°*T–$A”«ûX=©$öTEx2Œ{_Ü=ÊM-Ă[•Š2ŒTùZ†ő•zy~}áæúLĆX»e}ź˜yŹQ&"ôDh=-­žŐmčkx$„Â%śÂ%w „—Üúìi©UqÈ/˜šÈ\\ödÒЖ7ënaiśé|ƒ&2ŒŠƒ)…Dżmàƒ{ÄĆ;|ÜȚp-!OKږŽ#Bf_0Í0 Î#lwiÿMw{4čŸÌv,sƒŠùűÍzČ`•‡vőč©4fFhwžiÍfÒh™™;ŠO+m ŰÚżÀcûO %òą–7Ÿ\CÆ endstream endobj 329 0 obj << /Filter[/FlateDecode] /Length 256 >> stream xÚ­Ò;NÄ0àŹRXrłGÈ\çAì$U€$R AĆ€’bWPÇŃ^ÌÜ$GHčŠqüŻD‚‚DÁXšO.<ă±,óJ”%"IH–BJșH•(.IfJT)U‰Ž ç”ö”«Rä%n©RŠêlj§WŸkxüHRńű–ÊŒÇÍœȚ_xŒ»żąÔí±mź©·>úÔ hU̜ ÛšA«=VO}>l7uë@h.Ìóč‘ç†Ú2\yÂXOŽ'ôydWd†+2Ć-ŠŁQ+˜3žÙ ä‚Ó4Öè˜54ûà݌ÿ‰ đrOfêïĂoțđy@Šœ endstream endobj 330 0 obj << /Filter[/FlateDecode] /Length 370 >> stream xÚ]’MN„@…‹éd0,fn0ôd@ù›Íű“ÈÂDW@]șĐèvàh„À’éòQ ‹NêUżś KQYè8Šc&QyĄÏ“<*.uăTê> endobj 10 0 obj << /Type/Font /Name/F3 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[549.87 549.87 549.87 549.87 549.87 549.87 830.21 549.87 549.87 549.87 305.48 488.77 305.48 305.48 488.77 488.77 379.38 379.38 379.38 610.97 610.97 549.87 1099.74 0 427.68 305.48 336.03 641.51 610.97 610.97 916.45 916.45 549.87 335.03 549.87 916.45 549.87 916.45 855.35 305.48 427.68 427.68 549.87 855.35 305.48 366.58 305.48 549.87 549.87 549.87 549.87 549.87 549.87 549.87 549.87 549.87 549.87 549.87 305.48 305.48 855.35 855.35 855.35 519.32 855.35 830.21 781.68 794.26 842.78 721.59 691.04 864.34 859.75 404.92 567.84 860.75 660.49 1043.04 859.75 825.81 751.13 825.81 817.28 610.97 764.71 844.98 830.21 1135.69 830.21 830.21 672.06 305.48 549.87 305.48 672.06 855.35 305.48 549.87 610.97 488.77 610.97 500.04 336.03 549.87 610.97 305.48 336.03 580.42 305.48 916.45 610.97 549.87 610.97 580.42 446.34 433.79 427.68 610.97 580.42 794.26 580.42 580.42 488.77 549.87 305.48 549.87 672.06 183.29 830.21 830.21 794.26 794.26 842.78 721.59 721.59 864.34 660.49 660.49 660.49 859.75 859.75 873.33 825.81 817.28 817.28 610.97 610.97 610.97 764.71 764.71 844.98 844.98 830.21 672.06 672.06 672.06 954.79 404.92 610.97 501.66 549.87 549.87 488.77 488.77 761.24 500.04 500.04 549.87 305.48 463.62 369.63 610.97 610.97 610.97 549.87 446.34 446.34 433.79 433.79 433.79 427.68 427.68 610.97 610.97 580.42 488.77 488.77 488.77 641.51 335.03 519.32 702.61 830.21 830.21 830.21 830.21 830.21 830.21 995.52 794.26 721.59 721.59 721.59 721.59 404.92 404.92 404.92 404.92 842.78 859.75 825.81 825.81 825.81 825.81 825.81 1117.71 855.35 844.98 844.98 844.98 844.98 830.21 690.04 1221.93 549.87 549.87 549.87 549.87 549.87 549.87 794.26 488.77 500.04 500.04 500.04 500.04 305.48 305.48 305.48 366.58 549.87 610.97 549.87 549.87 549.87 549.87 549.87 855.35 549.87 610.97 610.97 610.97 610.97 580.42 610.97 553.61] /FontBBox[-122.2 -532.8 1344.2 1012.9] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 331 0 R >> endobj 332 0 obj << /Filter[/FlateDecode] /Length 155 >> stream xÚ334Đł4S0Đ30P°0Ń36T055Ń30W054Śł4V035Đ31VH1T(T016Ö33R0BK3=c3T Éč\Nž\úá Æf\ú \úžŸ %E„©\úNÎ †@>„ëéąđùÿÿ ?êÿ7|`àÿ/đ€ńÁá ęÿ>ÈÿÀűaÿÿ?ìž\=čí5/Č endstream endobj 333 0 obj << /Filter[/FlateDecode] /Length 210 >> stream xڝ+Â@@q$k8s¶íö·«šHš …%$š&ÎEz‘é ÀU4ŠàÈ>3bvȚs”–Ą[Ú6˜@șŒ”Ż€ńÀUŸT„ź'C¶@)-”6?ŁC˜Ż•Í^ĉ°VàaÍ@+a%s8Ï;aƋ18<·c2ą”šGPčŠ鉔#eH·†VÚ2Ș)˜ >ȘAÂŒáțæúCÿ/~ÿùœh/"u,ĂJEÔ¶¶ŹĘùgMGqr&ÇR*ЉXŸđ Śę endstream endobj 334 0 obj << /Filter[/FlateDecode] /Length 209 >> stream xڝ±A@ŐÛűóövŚĘ­$‡Ä*­„‚P+źPȚ7]~cÄœN!ÆÚEA'ûš)f眖1\[\ˆ —š*QÜÆ Žæ"ƊčN`.aJnîYŁyÛ~­Ì–,ÍX4iY4ŁX” ałȚ.X”Žș ĘÆŹÂaAx$<^+Âëo'śRĘłśäH€éäA€*0}q…on”űęçs"\Ä·Cé•ò·Ą·uÚÁ߅T>êì ë’Y?căæăՔ endstream endobj 335 0 obj << /Filter[/FlateDecode] /Length 224 >> stream xÚUĐ=‚0p7’.wK+ŽŐ ăG"ƒ‰N@4:;z-Nâ ^èđK[^߇sNš)©ÍS™hš&Vê„ìÜJcÉh' ]4ĘÉȘ™œRĘ2&•ʍ#Î7±ÊE|"ŁDŒŁÔŠ8ßÓóńșŠxuX“îöĂ6ßPÛÍTKđû‚Ô([P „ Î@ق4!š2đkÁ4šȚ żê@yżĆ@8‚ùàpÿ?͉8­/‚Kâč\_<·Âù6čiŐLÄ6Ç?«±6x endstream endobj 336 0 obj << /Filter[/FlateDecode] /Length 216 >> stream xÚUĐ=‚0`7“.wû#Ž…‰5‘ÁD' Žč– 'é :2*öu(íđć%}}?Zk*Kà”s(rš XeŠŠ TĄšT …ŠeWP|MŚűt„Ì)ŚóŒËÔ agœ°=䊰æŻçûFX}܀˜b ›-€îŸ-bŸòŒ‰ÇuˆE†Êă€C,2€·D Ò> stream xÚ͎11 ‘èüŠęNœűâžœ‰HPń €8ż§ ':^ÀN5ĆH›ÌŰ‘cDU΂M*ÊîHCbWXV¶WÁ )•KFìž;›ț$—;Âąöš™B;àùxĘ(ŒÇ Òę«m‹UßúęÏ,iŚèôà§i endstream endobj 338 0 obj << /Filter[/FlateDecode] /Length 116 >> stream xÚ͋± B1 ©=Ć[ÇNL·H%è3?Ń1wŐ—ĘÙÂ"ĐÌbXæjm”Á‹±ŻpQÜĄ”q-aD°ÛÏrŸŃÔ) Fi‡V(ő=æÇóJi:ŹĄŁżÙ7X ^íÚv:Ÿ…i endstream endobj 339 0 obj << /Filter[/FlateDecode] /Length 119 >> stream xÚ]‹;Â@ SûïńÚfż e‹HPq €‚>GO"hÈŒjFz)%Â"ȞwŠÖŒpÄ9DŽZŒ“áźĆŰd™ÏŹysč=©«äźBź‡'WŒ_Ÿčî|€.țŐzÄÔŹì›?~‘N•.3oŒ endstream endobj 340 0 obj << /Filter[/FlateDecode] /Length 153 >> stream xÚUËœ Â@ †á«=…'đٗûIy qT ” èł#°Š;Ét Ehűžê->—%A&fŹ=U‚UÈ{tì)EŒu€q+x@qL> *śÿŰìĄ)`Ś( vŽ.€- <Ï;°Ír‚2ö7Ë;mŐäŃg­éÌëg0CrŸ{}èSïÚéM/zU˜Xœ…F4 endstream endobj 341 0 obj << /Filter[/FlateDecode] /Length 185 >> stream xÚ3±ŽÔł°P0Đ30P03Đ32V060Ô34R016Ö33R076Ń37UH1T(T067Ö3¶T0Bš,ŠŽä\.'O.ępcC.}c3.}O_…’ąÒT.}§g š'„ëéąđÿOężÿ?ìqâö?ő‡˜ÿÔ70ț©ghš©a:`SÁöAŠ@î‹CĘÆÿ°ÿûÿA‚Al H€€€€dÈ,|vÜÂćêÉLvI endstream endobj 342 0 obj << /Filter[/FlateDecode] /Length 123 >> stream xÚ377Ś3”T0Đ30P03Đ32VĐ”0Ń36T074Đ33U053Ó34RH1T(T035Đ31V0B(EGr.—“'—~ž‚© —Ÿ˜ôôU()*MćÒw pV0ò!\O…ÿÿÿŸÿÿÿÏŁPÀĐô—«'W r—z endstream endobj 343 0 obj << /Filter[/FlateDecode] /Length 151 >> stream xÚ]‹» 1oÛë]ßǐYH8@‚ˆ€ùu@ ŽČ…ž2N\ěài‚qȚ“dbÆqI…àÈqIŸÆá&55î(ީʐ3 ‰û+¶h"Ű ƒ] «ÀÆ%žO—=Űf5EÉțÓ8Ă€­šùź5ÉŒzӇ>tĄÓ§ŸôĄIïz՛Â<Âúš"4 endstream endobj 344 0 obj << /Filter[/FlateDecode] /Length 115 >> stream xÚ327Ś37T0Đ30P°0Ń36TĐ54Ò30Q0Ž4Ò37R°4Ó36SH1T(T04°Đ3*B(ECr.—“'—~ž‚%—ŸˆđôU()*MćÒw pV0ò!\O…Ç pĐĐđžËՓ+”5ô endstream endobj 345 0 obj << /Filter[/FlateDecode] /Length 231 >> stream xÚ]Đ1NÄ0ĐȚ‡ so’ž!Ò. â°%Zöää6€#w i i6Rdó-O…Fݘ/ę)&7FV)©JfšŽł"—ÆPź”,2*u.ËșßĐ#éRKmHa zețŻrś ¶V€·€7"œ€J‹Ô^ŃóÓËN€Ûë3BjăjÏÉ{`?đËŸà>à“œÁ;;‚ÓÈŻŃ8œƒ…M0łFÖAÏh!:rÁ>Z`aÌ0ÀÈ:èY-K Ž\°śn |„ž…M0łFÖA Ž,š‰ +nțCL† endstream endobj 346 0 obj << /Filter[/FlateDecode] /Length 126 >> stream xڍ‹1 A E­sŠ3I&îì¶«‚SZy”ŽPŽÏ]ś : băՃÿŹ. aôÎY1Wcqè`\ nʋ‚“â •žœ}ž3wö]/4VJ ”6È„șĆęö8SwKhó·ÖЈ˜}1Ćó~+ZWÚżÄJ> endstream endobj 347 0 obj << /Filter[/FlateDecode] /Length 161 >> stream xÚ327Ś37T0Đ30P°0Ń36TĐ520Ń37S€R&F†zŠæ )† … †Fz&Š @hfdŠgl‚Š%9—ËɓK?\ÁЀKßCÁԈKßÓWĄ€š4•Kß)ÀYÁȇp=]h8Ààƒ űO„ëƒ†Ç ÿĄđĂ?‡țűqà灏@•Çô˜€ËՓ+ÚțZÌ endstream endobj 348 0 obj << /Filter[/FlateDecode] /Length 130 >> stream xÚ377Ś3”T0Đ30P03Đ32V042Đ31U074Đ33U063Ô36UH1T(T03Ê+Ą‘‰ž%šŽä\.'O.ępS.}#.}O_…’ąÒT.}§gC ÂőtQh`űèFA­…:‚ËՓ+ÆŠ- endstream endobj 349 0 obj << /Filter[/FlateDecode] /Length 180 >> stream xÚUŒ=‚@„©·âïû +Ę&š‰[˜hćÔÒDÖpœWĄó$¶K‡ Ù'H((ŸIf23J)*cà”óATÓ(„fTjĐ‰Š±†ƒ€Ëu=P\P!'ƒę‰€–°Ȅ°Ș0»†Ûő~$,ĘÌAt~°v6.ǒYț1E0’›2šLS Á Ț`î3|öކ-"oĐó/úsíčÿ|cíXč~YZČęIx\{ endstream endobj 350 0 obj << /Filter[/FlateDecode] /Length 109 >> stream xÚUË;ƒ0„aê=Ü`=^ƒ[.H•@ÊAäț!ąbțê+&„ VƒJ›2·ÔÔšæ/‹ÔLlXŠš3x–šî‡ő-]ś„™ž ”ž2ăŰż/qĘÒߟXTśÉXäńBAd endstream endobj 351 0 obj << /Filter[/FlateDecode] /Length 191 >> stream xÚ]Œ= Â@„So•ű.àfČkș@Tp A+ –B­ă ô^%]!WR€Ę`!ä eűŸbFJI…Fƒ>”ù Eęź„ą‚ƒ4UV¶ 〠ʋdœrń7YnHdˆ·oBÏLaż;ʉ͆À;ÿšA›àčIĐ­±e6q”-ńa3ŹlŽw{ÂÂ^°|ÓĂ̆˜ÿÀń;Iê:aê|9†·7ibĘŚ'2]]Ń endstream endobj 352 0 obj << /Filter[/FlateDecode] /Length 126 >> stream xÚ]‹;1 DSûsÇΏž]@"T()@P“»îA–]QFSŒ7šdÆ”BXV8äXą­8JNĆQ”5@æšTNúû8ßhhäO™üFŸíń|Œźä‡Ă:óÛă4ö>őîȚÎęwńËNÛFÇĂÚ'œ endstream endobj 353 0 obj << /Filter[/FlateDecode] /Length 147 >> stream xÚm‹± Â0DćŸâ&űțÎw§ á *JŠ X :Ö` Œ%šșWܓî\Óp•ÀÎB”æÒCCĆÎÁ7œĆÚąCYŚ,’ŁȚČV?—Ő–ÚHf‰RÉLĄB&ΰß6dÚù6ûGăçt€ąx}ÉœÏ1 óì/Śtč§[ŸgzĐ$Òâ OĂ endstream endobj 354 0 obj << /Filter[/FlateDecode] /Length 266 >> stream xڍĐ1NĂ@…áÔ{ æŹŚY{œ©‚Hž@‚Š@J Ôæ«€ŁäÔM"Y捱‚ĐaŸ,Ë3û;ÇèËHÁ‡@)űi€Ăiš|“š©łÏ„œ|èŠ€;JłìSIAî<+}Œż>čŸu‹ÖWTgWœQSčą=§‡ûÇ„+ÇTÊóđ۞3òź[ęđ{őƒ{¶|ćúÆ[Óg^«/2Ńò@6ÀčL4ÜÍeìdąaßɈ‰†lX=Mô:š|_CȚ""ë/‘ ‘ś‘‘»w<Çxź!SȚk–ĄfBL0ÔLq‹gžÆQs 5_ÔLCÍ5ËP3EÍÛëN[wù|† endstream endobj 355 0 obj << /Filter[/FlateDecode] /Length 386 >> stream xÚUбJĂPà@†@–€::(ș!CGÁWčĄCG_!RĄkÄ%Â%żçÏmÊG†üçœ?OÓ(IUƱšÆŃ8UÙ8g*›äQ~šČô0Ê&ê6Qjz”GÓDĆòäqĆÉÿ/nîęùÂ]«IîÎŐ4óG‹ őôű|çæ—'*‘wûș8Uš żwĘ;4ĐĘq ôn_ Àˆ.ԟXmĄkŹ€ŠĐ+hà”ÔŸBă@Ü:Î z‰măÖĐ6lńpwzÖ>°šœĄ”+ŹíȚÒÚÀæÉDæŁÆ0«șâ k‰‡ìś!ń}ß •ę%ŒGâÁûZ*śJŒDVŒgŽü»‚ÖhZa”Š.Œ ő|k–Ó‡żšć˜°ŁĄ)ŒŰÉ3cI]ŃÓÒÚ +Ùźæ@‡ńÖj§»ÓłÊöƒfoh•íÛœ„Ím8Yæè5•=€œa/—ʞRśf9Œƒćđ.–Ă;”»{)…=űg ÿêK«F endstream endobj 356 0 obj << /Filter[/FlateDecode] /Length 191 >> stream xÚŐÎ;‚@` Ć&ÛpæîY`+ÔD ­<€ZZhŽo¶Gń”dÇ%űą”s'ù&23Y„‹#L1ŒûŠdÊô±DÂ^ ”P,Ó \„R°D 7vGš”o!Ž(_‚Ò”+žœŻÊóő €Ë},æ€X4ˆŐÈiISlB;5x/14Ű%ƒ7ʃ—țGKžș§-;± ŒçȚĐśęöl}lˆ©ŒĐęę[ș(èæÓô endstream endobj 357 0 obj << /Filter[/FlateDecode] /Length 192 >> stream xÚĆÍœ Â0đH†@–>BïL“~Äv­ ftrÔŃAŃM°Ÿ™’Gè˜ĄôŒ vVŒ~ü;.ËĄ BJP±)Œ;tŹEâ)rĄìœ@«TÄ~ŚśDIĄłÏ‹Ę‘—†Gȏ<2KžœŻ•«)ű©éą™b͐ZĊ8b±en€.lI hïnd >±ŠžGóОÀm[†.@ëiŸ yđ‹GąĄèڊ„„űÜđő ŽÌŸ endstream endobj 358 0 obj << /Filter[/FlateDecode] /Length 180 >> stream xÚ355Ő31R0Đ30P04Ò30QЅPІæz–Æ f–zf† )† … ŠŠz– @hnh gfŠȘ#9—ËɓK?\ÁĈKßCÁԒKßÓWĄ€š4•Kß)ÀYÁȇp=]țÿÿÀüÿÀÿÿ ęțÿcÿĂàÿù@òAę yà?ˆlD"™Ą$PÍ?öÿšG2*I]óiMț† ûy Û‘I.WOź@8ê‹ endstream endobj 359 0 obj << /Filter[/FlateDecode] /Length 227 >> stream xÚćŃ?nÂ0pŁ ‘Œű~šc'䏗"QÈP &@;2P”[%ܛő(9‚GQŸ‚Ôąvì†=űś€ïœáč) e ÒJk2čÒSșŸÚN•­©ČȘ =:PĘäÊæ€ă­VUyʱÛóyËł-U%ÏVTZž”ôúòöÌłùúLŹÇČ]à:ž X1€ț]űˆ =ëĘ ĂÌáańŸ “?À§WÒóè3‚8uEô=.À#HÇÆóÆL'żĂ7ˆ>A8ę‹sL2vó|ÙòÍoSà endstream endobj 360 0 obj << /Filter[/FlateDecode] /Length 219 >> stream xڍÌOjÂPđ‚đxÁč@_Ț˜?&Pšł(èÊšKJ»T<@ŻđœB »|ŽÍBZÊđ[|ó1t;š™Œ6†‚XsL/ÜŃ& À$:ô)Jb1͘–äGŹęŒL—ŽÂżӅêeʛo”7€0Q^öN«ÏčòzŁ>±ä*fBȚ¶„SłEšŻO8ŸPžß°îl}Č^Cé8ÿìÄAzü*ÜʱüʁÜ;± ‹Č)Ú6›J›ó“đÀIäò{›Ț»î„Wo™_æłÚt endstream endobj 361 0 obj << /Filter[/FlateDecode] /Length 262 >> stream xÚmбjĂ0`-~ß T–[v&CÚB=Ú©ĐvìĐÒź”ĄĐGÈ«d˘W0tÈȘ’ĆĄ«”@,\ß ÿppwE¶`e œqsÉÄ.DÊxrQ2) œÉžŒ‚”)ËJඋ4eĆhâń….kš<@žÓä$§I} ïoÏ4YȚ]‚°ùë+@Ä ąùÇŚÁ†L ÛÆŁo+Çaíó»ŽûÎ秋;ćłQ3ǶśùîCÇJûT:8b> stream xÚ•Đœ‚0đ’.>‚ś–ha“ű‘È`ą“ ŽáŃú(<‚#áÄH\€ ż4é]ÿœX&BBJP!ÌT d&LD˜€‰#Ą8)ž‚‘4Èv™Äm†Ç _dÜ?€–Ü߀ŽčŸmá~{œčżŰ-A”{Úf+`í7EûfL0Ž Ë±˜[dˆćÔńœ8*ÏQû4Łì_šźő{vuŚv!,Eby‹‹û±Èû'+Ș«©K3ȉlHê(:Űż€ę.ÄχUąôhșšőü3òśßCËŚßżdù Č endstream endobj 363 0 obj << /Filter[/FlateDecode] /Length 276 >> stream xÚ”ĐœJÄ@đ‘+¶čGÈŒ€›Í·©NSZÙ zćŠÖŸÀWJçkXŰÆ.BÈ8;YĆV¶ű±ËÌîÎżJSë tÖ9,M3<ÌJ›dXÎæB}dËoŒĂą–‚Ź*ËmUüìžÙ™Mcâ+ÌkŸa™˜ž9LJûÇ­‰7Çèśó¶9Aæ Ú ˜{ˆF`)ÈÙÓ<.žïûŚÀûˆ'îZf&öĆ| t0ÍH=ó†%ûûÒÍ<|!—|3BX+ä™~Ó*à‘ÿ üőzˆ”đë҉鎁Ò$ȚIsy%Mé4łÒŸÉçÉișkÒŹ[òÉwŸŽ`áéać‘S&sژËO„C„ endstream endobj 364 0 obj << /Filter[/FlateDecode] /Length 218 >> stream xÚ”ŃÏ ‚0ÀńI0‚^ èśíșÙ!Ź Az€êŰĄš›PæŁô;ˆkÎ á-> •íś5”> 0Âű’p&Ü#,9•DHa@„G‚‘ÀęvęŽőĆጣÓ=ˆÓ5ˆÓx·ëę„iŽ]Śëj/ékźò·ÂQyúÎR*ČĄ!w EÏ œŠg‹4©˜^–‘!ł ~đîw€ț@Ç~_lȚŽb«§Mš œf%ÛÌÔ=uZ„떭Q«ŒțxăĘÉ$ endstream endobj 365 0 obj << /Filter[/FlateDecode] /Length 202 >> stream xÚuб PșòśRh)m'“Ș‰ &:č6QGÎöÓú)|BÇ XĄX<†ž»' JÒ(ĄNh –ÊA€I 9'Yg7Œ“dŹ—(ɄßqșâJâűĂńČÇrûó‚ăjż‚ńTș­\úD€|4z™>Rc&Z‡rtŽ>Ä€¶hË2ˆQ3ŽÇàè,˜rßJż}vCÙwű1ęoąśè­Ł©ít‘›ő/x#ńá ź endstream endobj 366 0 obj << /Filter[/FlateDecode] /Length 189 >> stream xڭϱ Â0ààà§ž0MÓæêVš ftòÔŃAŃčàŁù$Ć'§’xMERQpđ>žđ\P+ €qƒX ™J%”ÌRĄŹcہF P–‡(4v7V[^-!Íx4MšöÇ ŠùbšÛь5Ő”ŹtUß1珌őŒ'ïÙ{ Œ}ńê­_Ú2Ô~ôX{«FÆȚmߟ™pËț }ì_Z–“tTȚ•O _<'(ü endstream endobj 367 0 obj << /Filter[/FlateDecode] /Length 270 >> stream xÚ­Ń;NÄ0`ݶXÉÍrƒÌpœ—Ș‘HJ HHÉŃ|”!eŠ(ĂŰq"­DIR|±lOÆżm]ȘȘ­Ž†ČVY —…QY6ϕŐ`źje2xÉàŒć”9h~mQ*[ïx~“§FŠOP™ȚÉdÚÜĂçÇŚ«LOŚàÇ˰č"-!Ń Ž3ăÄȚ#Z7!M{ż‘†#M©Oˆ.OwH]KțSpç]€Śs!̞»‰Š_deFÁ@祿á&iéőŸü,ű?DšK#.’ú3‰6Âi7BnÉ%Š3ë–Ɩçp ©æŹw4ț„ ï!ȚÊÖ±Œmäă/ü#@‘ endstream endobj 368 0 obj << /Filter[/FlateDecode] /Length 147 >> stream xÚ͐;1C‡vNá 0ùl2›mHJ Ô\%Ź€b»xraÉr:IVŹEŁâL ]uĐ6HôŰ;œ ê%$ŰÁšTą~6vGî3›-bdłDlÙä.çëMżžÁ ùóDTè© ĘêJ„ZËä?1èÿ;wŒś»?ŸçEæÍÇœ endstream endobj 369 0 obj << /Filter[/FlateDecode] /Length 131 >> stream xÚՏ± 1?Ÿ*¶Îwgû Ґ ą $x1”Fg%’§v”ÁLte1‹ÀË35–„ ›ĂKâl8+DŹÒêsçìżÓ•úJás [äBĄîpż=.úę Úű‹un’±[ŸÇŚóÿŚ<Š^Ž©tűÇB€ endstream endobj 370 0 obj << /Filter[/FlateDecode] /Length 183 >> stream xÚŐË= Â@à…Â69BȚܟ$»‹U *˜BĐÊš„…ą­»7đJéŒÆ/»T>WlŒ€ |Ăct!œ%”‚ ]Àđ]„qÂi°ź&‡†=”čƁŠqZ kŸëŻ.WP.g`F\6s8N[.ëĆtÜïÙL€ZÆŰ„ őƒ?§}|„UżèRd>šËđB˜á•°Â”ïûsBű`)!Oȧ _>ÂÄéę endstream endobj 371 0 obj << /Filter[/FlateDecode] /Length 263 >> stream xÚ]Ń1NĆ0 P1 eéê Šęż L•> Ń &Œ ˜NĐ+ő‹ĄŚűR/Àß:T Qì%ŽR_-Ćvâcd{…J*…[-ë-^ԍT;4M#BmvČmđ„ÆwԗZ¶U|ù7Ëx~û^TOŰQĘ„oŸ_ŻąÚ?\cc û€àÜ=Ű\á„FKùĂNìÀ–€ïÈՒK OìÌNìÀ–dLO.–Œiə=°ß,ž]òGuNì> stream xÚ332Ńł0U0Đ30P06Ó34VĐ54Ò30Q05·Đ34S037Ń35RH1T(T05Ê)Ą™…™ž©ȘŽä\.'O.ępS.} \úžŸ %E„©\úNÎ †@>„ëéąÀÀÀ ÿÿ2ùÁțÿÿÿțeò^ò˜<Av`ò˜ü&?€Éÿêÿ3H0€ ÉćêÉX•” endstream endobj 373 0 obj << /Filter[/FlateDecode] /Length 263 >> stream xÚuŃœJÄ@à[¶É#d:+7»Éf“ƒĂ…SÁ‚V>€w„…{ÁWč|…+ۀM–ŒÎ"9Č3 óM100se„Ö …”Ą28U©JSˆTƒ)ŽÈSX)x„2SB)”Š4"7ăûŸŹxrfΓ+È žTŚđòôșæÉòæ͇±ș€ @Š6 š ÍĘŹE°„ïp>'QF„śI,BÂbˆ3†ŰœMÂΝaƒžś`[ăŻ;‹?c41~yĐFű1† ûšDÇșÚœ9<ÂfïĆöù»/šh]ŒmÜĂEÿh:‹-ŁśZg]ÿÛèRjüČâ·4šfÿ endstream endobj 374 0 obj << /Filter[/FlateDecode] /Length 259 >> stream xÚUбN„@à%Ämšmd^ÀeáŰ#É©ÉQ˜hćš„…F ß ßß;.!;.łW,3Ɨż˜)țČšE•ƒRÂF‹lçY.dșź„Î@—…P9SH́aČOŸź&úSŸá„ŸÉ1Ż0\ómŒíÌŁ­ ÍÒ5ț­8~Óòû“Œ2‘ endstream endobj 375 0 obj << /Filter[/FlateDecode] /Length 267 >> stream xÚ­ŃÁJÄ0à.+,a_`ĄóЉmV{ôްzô èmĄÙ7ëŁôrì!tœf„ž„)’ücŒáj ‚ ZđëźJÍe F źèő Ś^$ŒƒV‚W%úLYqŁŠ‡7¶«Y±U±âŽdEęŸ_ŻŹŰ=Ęž?oë;@ôęˆ]–Ì†91,đDô9vG·„ć±m°_zŽTŸđ8CæžȘ©ÇS=âÉûëû%Ń#.'șM€ Źș-áVmàrŠ \ۆèÿČ%0œYșüžčIc)ž31ł”`̓ąpùOÖÔh琊fÄîköü pJÛ endstream endobj 376 0 obj << /Filter[/FlateDecode] /Length 192 >> stream xÚÍĐ;‚@Đ!&ÛpçîÏea+ÔD ­<€ZZhކŁz`a—beçLń2Ć|26“|áPr)Q.ΕæÒ U†k‡65<ŃxRxĆÄIźÊ6mfybÇÇ +J&hLR&Ê-Țo3Ćn‰Ș­CYźÚȩê*‚Œ& zÎ<ŻŰóž&ž&B0~eŰ>Ęïë·ś·ô—AŐ‘'Š0ćŸéŸKțŚß°uÉöíá endstream endobj 377 0 obj << /Filter[/FlateDecode] /Length 331 >> stream xÚ­ŃMJÄ0đ ƒûÁŸ ˜ŠÓi;…QÁ.]yuéÂŻ]±ÜxÓŁDŒ@e6Y„>_b»šž”$ü$$ïÿÒ4ń€)-äR€ €ĄI Éz%’nBž‡$–b€±–‘ˆVżź\ßńm΃+ˆ—<8ƒ4æA~OÏ·<Ű^CHûŸm~ˆ†ŃBTÌ·ŒZh'ž#ŽȘ4Űd4 Ö%ê™ÁŠŽO Ž[ÏĐișÓc&DeŽŁĐ3ą.ÇŠń ”QŽyGÍtHćś”„îaöŻ _Ÿ>üÙđó]}Tí+U«g-#(ĄąŹ(Ęf6ž/$pŽÇCÜă;%X?âć©"Ź}Êú€6¶•í{ń°±]qöiAü@eQ=”ŁŹÙŰÒ°?™ą+¶cn1lciYaÁá§9żüĄȘ‘1 endstream endobj 378 0 obj << /Filter[/FlateDecode] /Length 245 >> stream xڕѱnƒ0àC H^x„Ü ÔˆífŠ”ŽR*”S éŰĄU;ÇÆŁôÒ͑îÁ$ŒT1çĂ:s?¶”–›•T k#Ëo[UÒ*4v-u…‡?ĐÜ© *zl©€ŃˎŚw±kDń‚ÚŠâőFÍ#~}~ż‰bśŽÇ’j.›;€$„àHXMfdGO.@pdÛ-ûłbO9ëł„]™\iÔŸùîeŽvšx^ŸŽržÁ-ż§¶Ń.›rÍù&]”sÎćțŚüZ{X˜±§Ùè>(7Üę?Ú§çѐüș0Ź6e}îÄ}#žÿ I. endstream endobj 379 0 obj << /Filter[/FlateDecode] /Length 281 >> stream xÚUÏÁJĂ@à {é”!ónłIЧBU0AO>€zô (ôd#ŸŰú&y„ç2ζ„Ž,|03ûOUUÖ]anóقđČŹmQą[”–Ö Ču/ŸŁs•­Ìő5„łMu:ńüfV­Éž°lLv‡uaČö??Ÿ^M¶zžÆPïÊöeˆ…ÄG À71_§’а”Žúxò"=ę‰ ô#Â;~EF:Û3‰È°eŁ#Ę2bĆk“{ˆ°á eˆyˆXł‹X‹6I€ 0Ìu]đ‰Ò†Ăęb<0‘žÌöŒ‰FçœçQ8 •šŹ_ŸÏÄó,’ˆSŻ©ÒAó-'6·­yü!‘Ô endstream endobj 380 0 obj << /Filter[/FlateDecode] /Length 175 >> stream xÚ372Ò30U0Đ30P06Ó34VĐ5Š˜(˜™›è™ÁšC…B3c =c  4ł0Ó35CՑœËćäÉ„ź`jÌ„ïĄ`j΄ïé«PRTšÊ„ïàŹ`äCžž. @@ČÿĂđÿÄÁÿÿÿÿ‘hQÿ8ÚAÔŽ~0ՁJÍS'°Rò`ê€=˜z€•úŠ~ŒêC=z jy4ŠËՓ+4«Dà endstream endobj 381 0 obj << /Filter[/FlateDecode] /Length 215 >> stream xÚćÌ1NĂ@ĐQDÚ&7ÀÿYï:Ț”]EJ@©r’’-vNÀ•èr KŽŽhŒ„ț°Ž%ąœMń4ĆL–:OŰhcx攝ńtÀčö–}–j—đÆò#{Ÿè4g’YŁœ;_Ü?šE©â5;§âv…ŠË[~~zÙȘxq·dúPË+&"tDçU@} ĐŒićÈś?æ š_êÁû‰OA3öo‚6&‚nD‚Ÿ1d. t•#ŽÔŐź§ĄqOGQO.êșT«_A‰eŽ endstream endobj 382 0 obj << /Filter[/FlateDecode] /Length 262 >> stream xÚuĐ1jĂ@Đ* Ûèš d”’„•U œą"T>@’2EBRK7È|矂Á…[72,;iSì‡ax ŸaÊŒ‹ €Č\È źæJ€s(S)TȘÌE‘Ás o J $Ő_êm<œòeÓ%Oî šxÒÜĂÇûç O–ڐÒlÇæ ;ÆÎŐŹEìĂÎ0Db«ź;5-Ič&»QtŹ­òä#ț;ò8Y{òà:łä֕îú"5čv4bíÊŹtši=[=Ù”]7őÉ7¶îâŁoŽŸìŁƒç0Ûú†Vź}ƒxÒ”çôÉKțŚßgî/Éoțű ‘ €b endstream endobj 383 0 obj << /Filter[/FlateDecode] /Length 330 >> stream xÚuŃÍJÄ0à,=,æÒł t^À4ĘnÛ-ˆÀ=ù*ž<(z5û&û*}ƒ}…ÀöÚe/Y('Y*nЄ„/0&™DN ‘„ …”0™ YÂiš‹$…rVˆŒ„Œ˜ŠlO ŒA™§"—`g‘H‘g‡ŻüąæńÌ$o +y\ßÂÇûç3/î.!ĄóțX_ca,ìûK†)Ô#D=îhoLj&êI†ÔU?R=„€. …ż„œ â\ĄÍÚšÔTŰQÖö@Ń Ą­g펛{jCÜĐMK§m㉊[ŃM §”öDĆ­uˆ•ÓČőDĆ-ÛqݜÆ=“DŽȘșÀ—"«ù—êG;O瀍UsF±[O'€••>ŠŰOGƒZúÛ&üO&pŸˆûiOUćDŃ­§ȚJ9QŽń„‘ë©•ë3òëšßŹÎ' endstream endobj 384 0 obj << /Filter[/FlateDecode] /Length 309 >> stream xÚ]ŃœjĂ0p…êGĐœ@eÙű#™ i őPh§ź…¶cĄ-ílœI^%Đ!c^ÁĐ!kBŒźw’:žű' Òqÿ«ò…šg •֐ćJ/à"͔ΡJ”* («\<§đćŒTE šVێn<œFË&J šąäÆę›[űüűz‰’ćĘ%€töÇæ ŒžSó_3ìEkĐHŠhp-ŃÆdŁ•ÁšÜÏжd?Ć!Ű#9Lđ<°Và‹ąĘ7NSokč JgŚÎęyë=óöœïŽb,đšzŹđï#xícìßy›yśȚužy îžčAï– ‘+.@Ê`͑§ă܆?‘#3NÏč‚Gډá,ûí:18a[Cł Î%GÒ|ű]7Ńę/ WÊ endstream endobj 385 0 obj << /Filter[/FlateDecode] /Length 253 >> stream xÚÍŃ;jĂ@à. Ûèš d”’ÖźNQ’T>@âÒEBRË7ÉUÔ„ô\žup#Ăą?#i y\ Lń1 ó€1Ù\ÍRÒJkJR„3ș1iȘŒŠÂd*Oé)Ąg2‰VENšŁ˜*/~v<źćą’ń’òčŒo(72źnéőćm%ăĆę%%œiuEB@#Äoˆ€6°%àB‹ ÛEȚÒąázW[ېëgaq˜§o¶àÈ:ž»óîÙNȚ- Qăœ—DȚČ·‰șłuŻ Ęàaê0zl'ŸȚă  vƒŰ{·ƒwȚhtămÊÿ­ż“ŸSțU^Wòá șI~A endstream endobj 386 0 obj << /Filter[/FlateDecode] /Length 266 >> stream xÚUĐ1NĂ0€aG"yÉú.€ăŽŽÓN‘ Hd@‚‰#挍‘#p• ź‘#dìőńȚ‹h©-}’-û—ćXz·‰àśœ[źàŹ\: Ș‚ó5Ä:žj %> stream xÚmÌOJ1đ)ł(a. ä]ÀLŠÉü UÁYvćZ—.]'ĐEŻ5œI„ ˏ>3ZŠ<űÁśÁśŽ1ąë@ )A5ąRp±ĐBĐF‰NƒÖ”hZŰTđ șnE[L§#ÚúśbęĖ+@uŹŒeX9ÜÁëËÛ#+—śWP„ü‡k Ï )Ë ‘„‘‚Ć`#Gßcžqœÿ@9†>m‚è?\"f‰‘'f©Ăù4+~ڎnzàèD˜ęćx"#ÌƒŁž Î~ìcÿŸ?Ÿóg˜᜜—ìf`«Oóû™8 endstream endobj 388 0 obj << /Filter[/FlateDecode] /Length 209 >> stream xÚ­Ž1 Â@E•+‹(ž s7»!7U *˜BĐÊš„…ą­1Gó&9BJ‹!ăź!„ ofæÿŻ”QRH a$dÓ¶i©…I 6±Đ1œ!2J źfJŠXw?ö'žć<ŰA$y°đ _Ăőr;ò ÛÌAÙčóà˜ˆz]ÔűwTŸĆƒŽü'á°š PbŸ^>zv‡Œf? ï‹ț„Ăăg”]'Úx­sŸ󉋑ž@Ššï~IH=fŁW)ńeηoÔȚæ‡ endstream endobj 389 0 obj << /Filter[/FlateDecode] /Length 212 >> stream xڍÎ1NĂ@PR"m7HæŹŚÌŰÖ6X ±E€P恒"Ž‹>grĆ9,N`Qm±ÚÏhèĐè3ÒŚŃ,dŽ1ĄΙÎ/DKbŹ.˜D ]VtŸÓŽžb͖L)­źŠż‰íŁZ:•mˆs•Ę[•č=íŸT¶\_QșșŸŐ]ÂIDô‚6Ì㠇p†©_ÄÉP‡o}&Ęqú œ&qÔ&ÇÿÔțfFໟo0ô5>‡~śÔ{HęsŒùËôO„ŸEuăÔĘ––Š endstream endobj 390 0 obj << /Filter[/FlateDecode] /Length 212 >> stream xڭα Â0àt*d±oàœ€iÒ&±UÁ‚N>€: *:Ûâ‹őQúŽJÏĊĐQÀÇĘć~„“pÆ9̉&‘d<%Š,A'š) {g‰` śŠ‚3­†»#ÍrnAr.A„4ÌWpœÜ4ÌÖ3¶îË|ˆű4ˆ-€•ù4țGë[jb)›“Aż L;ÂÂ4c{Í”zê»źȚž”âKéđ~ŠțR}±‡ê{·r1 (u~Ç >šÁÚ{llpșÈéæ&té| endstream endobj 391 0 obj << /Filter[/FlateDecode] /Length 211 >> stream xÚ]ŽAnÂ@ EA,FšMŽ_€ÉÀ8ĐŹ"ŃVj•ÊŠ@—]€è:‰8W +źÔ ĐĘTćŚUČ(ŰzČżd›™cČÆZšČ±»Â63©#æÔÌæŽ™Đ–ÜCjXf%y–™yz»±țЋB'+rSŒËtRŒÒ~śùź“ĆÛ#MDwČx"x\Àᚷ*Ä!j#·êšC]Jțh€Z8UM- ÿ1èCzÜSśT=âšA|œÜűń9Ÿ}ŒŻ6 GÔ!–dbę\èć/đ‰‡K endstream endobj 392 0 obj << /Filter[/FlateDecode] /Length 166 >> stream xÚ360Ő3±P0Đ30P04Ò30QЅPÆ&–zƆ f–zf† )† … ÆÆæzFf @hnh gfŠȘ#9—ËɓK?\ÁȂKßCÁԒKßÓWĄ€š4•Kß)ÀYÁȇp=]țÿoüđÿCÁÿvÿTü?đ(ÁÌüęÁ?öÿHĆ ÌpLŽ~JńæÿŰá˜ËՓ+Ć»ž endstream endobj 393 0 obj << /Filter[/FlateDecode] /Length 269 >> stream xڍAJÄ@E[2húÔìtb'é€ÌBЕP—.Ę $àŒRċä.Ú] E—éÌb`p!úTę_”ni (©ZȘŽ‹ÂHS‚6č4 Ž.eUĂ}O ËZÖ9ščȘZËČ8°Ü=òMÇł[81<»„ČâYw/ÏŻ<Û\ŸA>ëì΁ˆpMVۍŃçHńô>xaÓSŚźĆô˶(pÁÔûű?Ű;B†(Da{Äx"tcDűcáwž~»G;Ă1ÖĈŒĄgŒm玝ڞ†d"Čëđ‘_°ŠgÂtÙ Žd$rɜb·.„}ä#€ $ÇùEÇo~OŸŰp endstream endobj 394 0 obj << /Filter[/FlateDecode] /Length 185 >> stream xÚĆÍ1 Â0àJ‡J{ß|MÚ$6‹…Ș`A' ŽŠÎíŃzĐ±C Šé,Ÿ>x~žy )…˜#U0e1R‚ÍP% S‰B‘ÁžJ0ć@]€JQČïÆáLrMą=pFą5ˆ”Dz·ëęDą|»wŐŻU/Á„ÖÚÒëYwšŸëț8+ż5ʜăìQ”fTÔYi†¶uĐéÛfò6èțÓ&°uXzȚÜkç#YiČ{?€đU endstream endobj 395 0 obj << /Filter[/FlateDecode] /Length 148 >> stream xÚ327Ś37T0Đ30P02Ń3°TĐ54Ò30r ô, Ì̌ôL,R  Œ Íô,€jĐÌÜDÏÔUGr.—“'—~ž‚Ą—Ÿ‡‚©—Ÿ§ŻBIQi*—ŸS€ł‚!ázș(ü©?đAțÀ~Šÿÿęá?ÀC?űA\ȘŁì`€ËՓ+‘„ endstream endobj 396 0 obj << /Filter[/FlateDecode] /Length 169 >> stream xÚœ‹;Â0D7‘O@čˆqœM@ÂT()@pÄŃrĄ”."G”h^3O3„Źž!”\J, qEXhe9)ÔÒđÚą”z\^PWš7e Ő Śôę9œYë˜ŰŁVLʱ.™pŒ]ï'&Úí“uSuKŒąÏc$“|ôżፇ±ț—.À#„†‰yæéé©ë}ŸùaæÙÊ±Ę ‡­ź endstream endobj 397 0 obj << /Filter[/FlateDecode] /Length 222 >> stream xÚ”Í1nÂ0`Ł ©,DŽÀ»@;Š]gŠD‹D$:őÀÈ@Ő΀:öJÙz zƒŒ"Ìû©*àÈÒ'=ùęÿłÙ“r–ŽÒšČ\é‚MŠtNV[ć rȚ)ëhahMč7ÊkÂs…WÎÜ&æ+9ȘdúFč–鄏—i5„śÏ„LGłg2<ÿŐ uIAÜҀî>EtMۖż{đ †Ű+™nĂŽˆę‚đ"fú=æĄfz5/Ç$dŽŽ€č/êÏìÂÿĘú̆9”mêDˆRˆ r\ÉŚ8kÚk endstream endobj 398 0 obj << /Filter[/FlateDecode] /Length 129 >> stream xÚ327Ś37T0Đ30P02Ń3°TĐ54Ò30r ô, Ì,ÌôLÍR  Œ Íô,€jĐÌÒBÏÌUGr.—“'—~ž‚Ą—Ÿ‡‚)ôôU()*MćÒw pV0ò!\O…?ü`èÿ?ƒę`?À\źž\VÔyf endstream endobj 399 0 obj << /Filter[/FlateDecode] /Length 199 >> stream xÚŐĐ1 Â0àH‡Js„>p6MÚŰŽ‹…Ș`A' ŽŠn…êÍz”!c‡âłE/ oűűùyĂ{qr‚àB@ žH`,.èDńDƒjû(€œ„h-xƒhG© ôçÆîH3Cę-DŠúK5őÍ .çëúÙzČÍŻhæĐ0˰ò°ÒÁ›ÛÊʇwG2L«Œ(Ń cU4}ŽČł‡vÔé`íąMßșXł_2Źœ?°;ą{!SBrBŸ„ C7OïÊ, endstream endobj 400 0 obj << /Filter[/FlateDecode] /Length 175 >> stream xÚ355Ő31R0Đ30P02Ń3°TĐ54Ò30Q054Śł4V016Ö33RH1T(T0±4Öł0Q0BS=3sTÉč\Nž\úá &†\ú Ææ\úžŸ %E„©\úNÎ @QOŚÓEáÿțÿ ü˜A$ÿ Égÿ ŸáOęû†?ÿA$#˜dțÿCFČcüIț`ÿÿżÁŽ$—«'W ^¶‘ endstream endobj 401 0 obj << /Filter[/FlateDecode] /Length 204 >> stream xڍŽ= Â@…ceŰ&­]ænV]“l%űŠŽòjiĄ(Űiđbz“!ć‹Ï%QD+űf†áœyÚ™Š€€RÔŐRjŚMÇF&}Òș/ă„ÖÚœgćêuęRʶb˜‰hIœDDSêe3:ì ç#êžœ^ł1Á6À(œ3ănCFM~žČ qg àòŒòT8€ÀéÍĄU!Źÿƒ†ƒś/>ȋóó?ÎŐ·êoéœ8čm€ŒÎ‡ÜŒÂp•^L2±xMĄg endstream endobj 402 0 obj << /Filter[/FlateDecode] /Length 217 >> stream xڝαnÂ0`GL-T?Bîê8±š)„`â c‡"˜oÖGÉ#0f8qŰéĘ@'}ÒétwżsNÙŽÒJ«ôȚJmŐ{N;ć'`QU Û~ÀúBy ±*ă•ńÿV6ßbڈ| V‹|ΈŒYÀ~wűùtùEèÿÚf(»Œ˜> stream xڝŽ; Â@†‹À6ńBænvłÉ&‚0L!hćÔRPŃÖGç±RzŒ!eА1 ŃNű`˜ùr€àB€Ò\*è{Â硆@†| ÀWŠkÖöàG’GÌhq}IV['Ì]‚/˜;…@17™ÁńpÚ07ž@ÖûkMÆ@„EHY»Bșg€N5ÄÒŠ6Ę1wè9RŠYę„éć…ŻôöÏű2Hûʁ‰lr ‡źŠP+«ŠäÎÔ­o…UĂÈțBæ•­Öl’°Ć(J΂ endstream endobj 404 0 obj << /Filter[/FlateDecode] /Length 166 >> stream xÚ3¶4Ô35W0Đ30P02Ń3°TĐ54Ò30Q063Ô36U016Ö33RH1T(T066Ś32S0BS=3sTÉč\Nž\úá F\ú Ææ\úžŸ %E„©\úNÎ †@>„ëéąđCțÁù9™ †?țH±  ÿűĂüżàûÿ(˜ŸșűĐL~8ærőä śv3 endstream endobj 405 0 obj << /Filter[/FlateDecode] /Length 219 >> stream xÚU̱JÄ@Đ')ƒÖjó~ÀÉÌÎ$aȘ„UÁ‚V~€ZnĄhœ [lé/]đGČ0eŠÀsteA§žîuÁkWłŃưkŽu|čôÚv>hgÙûZ7-?[~eg¶-›tŸ ș­ÿ7žÖj5šê‘—ȘnÙU wüțöńąȘŐę۔qžfĄ3] nŸdÄ^">eBq2#ÿ“%$‚m™P*P‰‘rDÊÒ΄2Q/ČMÆŸ“H]zü(e>)Žú\Š>ûÓîçĘ *Đau3š‡odv endstream endobj 406 0 obj << /Filter[/FlateDecode] /Length 177 >> stream xÚ­Î1 Â0àˆC!§xđ%yiÓv+UÁ ‚N@=€8x­l^ĂÍŐŃĄ$FìPqp‘Ÿoűy<űuQ`^‚D)AÊ”ą,AS†€ÀHBÊ`„` ZiT9ÈCuúù±ÜđÚr±2\L #.ìö»Ăš‹z6û»Ú„[p_.çŽ$85Ń#ș2æXË··?`ż„Ÿ©Â©©Â±qq śž >q|lùü |„Œ endstream endobj 407 0 obj << /Filter[/FlateDecode] /Length 174 >> stream xÚ355Ő31R0Đ30P02Ń3°TЅPІæz–Æ &ÆÆzfF )† … &–Æz& @hbjźgnˆȘ#9—ËɓK?\ÁĐKßCÁۂKßÓWĄ€š4•Kß)ÀY(ê ázș(üáÿÿCŸÿ*ùÿÿùˆì€“0H ÛțAHöÿäțłÿï`oűÏü_‚áÿ?@òCüĂ 4ËՓ+9™# endstream endobj 408 0 obj << /Filter[/FlateDecode] /Length 204 >> stream xÚUÌ= Â@àˆ‚°EŒÎÜümČŠ1L!hćÔÒBŃÖ īۄô v¶›ˎ‹Ù 2đ ȚŒïrű`SÛ—Q;„nčXèŃæ:Ôç°t`,)W]5Œù4àÿ‹5‰bÍÁ ‰5+™Àn»_+žÀQčŒÉ #œ_ò&æfŃÂą-Z(úą‰â òÖń„©áC⟚ Ț+ÒLâ-œjòè\ŃQH#ÌôÙÀ CĄțWœțÉ4d”Ù –€; endstream endobj 409 0 obj << /Filter[/FlateDecode] /Length 252 >> stream xÚUÎ=JÄ@đ@ÀÀ4#X٘ÿœ|˜™dA\XL!hćÔÒBŃ.ìșxœÁ^%V–^!baÙf…0ϙDá?^ńà„q,BIĄCŠŽh»CeJHEI ™ÒEDŚ€T,’ŒB“$‘B„ĂĆù›ä,8#)YpD;) òcșœč»dÁädŸ"Ó»šăTŽ_:Cjê”ÇÍVÇ^Ăń =ęA{(Ńè!pQΟ,Oÿ˜c}ŒŽdżŒk”:ó?,EËŽà/UQđW‹nÙŐȚŁF=‚·űc” wlŰÀCOăâ~f0/zÚOŽȘoŸ––Đì0g§ßyjÎE endstream endobj 410 0 obj << /Filter[/FlateDecode] /Length 239 >> stream xÚUΜNĂ0`G Uò@ĄśuœÄNÓ)R HtâhGlH>ŠŽŒR6F^!RÖJ, E9îÈ@ëŸÏ?òÏsSy°ÆZÈ cÌÆĆ[oêž"7~ëÀ-JS;°Ü]YšȘ8Žž»ŚË ł[pčÎź ŹtźáéńyŁłćÍ9đmá”ŠšđĐ>Ą6Ć!Ą."±„ôJ;¶„O¶‹bóÆî›)û=mÄłÈö§â ˆćàÇю›ű§D‘‡Zòô/©äé'ìÏ ~Ń »ăÿ‘Țy"m9R*”ń‹źÁęDȘU )nêË Wż$šą endstream endobj 411 0 obj << /Filter[/FlateDecode] /Length 241 >> stream xÚ]ËOJĂ@đ”…Y$G𻀓Lfòoă@U0‹‚ź<@uéąE·Š„Èz•îČì .ÜFÜ€æó«N"–?xđ^„<‰!äa‘âa‘Hx&@ć’g T$xœÂŁ€9š$ç))‰ÌžÌN.łg6)Xđ2gÁ-ĒĆ^ŻO,˜Ü] ț[‹kpœrëüь±ńZÛËÎÇî͌-Æžșx°ŹđËČ<ČĆËŸÜőèÊ`Ł7–ö\śxDç•s†=ŁőêĘ@ud3 -kCŒLIt? q ÜOąz'êšŰûDŁ vS°ûoAè endstream endobj 412 0 obj << /Filter[/FlateDecode] /Length 226 >> stream xÚUÎ1NĂ@PǑ°ŽčA2`œö,±Ü)€ÄHPqH™DZlqÁW1PPr‹Źš¶XíWhôŠÿ„/ÖZČ&%•ą\KUÒY–K„‰ËBê’tžÉó‚ž2z&.XrIȘ?Í,—ùÿĆăVŹHˆ3‘Ț/Ejnéőe·éúî’ú֌Ń\QEńQćăű“/žÓoŰùOoîbö­A= &Ą Ó#ű$ÀÍFvĐ­ÚjTĂa2 S8ŸÀčÖÍ`íĘ żƒ¶Âg ŒGđqÔÿ0ŚFÜ‚:wź endstream endobj 413 0 obj << /Filter[/FlateDecode] /Length 205 >> stream xÚ”1 Â@EcŰ&GÈ\ÀÍźÉnbˆ ŠŽČÔÒBŃZĆÂkéMæ)-–Œk¶JZxĂ/†ùÿ'Ă!Ï2\ˆ5—1ôĘJTÊS Z žÄ°‘°‡d čJAŰљæJ_ŹwŹ(YŽ„X±h *eQ9ƒăáŽeQ1ŽÚÉr d|BBÏâZćHŸ ±)@“Ó_9ʰ:ÓÓ‰Đáa±jq%Ș  = ïèzy±†àÇ_kŒ Ód3!ùh‚ÚwÉ]MŸ^Ű€d‹7ÏPßț endstream endobj 414 0 obj << /Filter[/FlateDecode] /Length 147 >> stream xÚŐËœ Â0`Śo nžÿž§Š@ÂT ” èQ2BJ D°)ŸâN:©kN †AöSëŰÄYb0,{‹ŒŻŰE˜’Kú}ìŽÔfÒ[žDz‰Hç.çët»žÁ–ț©yŽáŐôĂłx]Ąš^șïö/î“țŠ”Ń"Óæ ÓÈŽŠ endstream endobj 415 0 obj << /Filter[/FlateDecode] /Length 259 >> stream xÚuαNĂ@ à‹2Dș%ż—€č€ÉT©€D$˜x`dÁ\31òŒJ$^ŁU_ c†SÌï–„:Ę'Ùgûì»Î”-ź(È·źléŹ\žÂ“ś”k–Ôԅó=”ôLU·tŸŁ§iη§śOvĘÛüŽȘÊæWTŚ6ïŻéőćíŃæë›s*Ăț‚dL……#á٘ ‡lÈxD’w2%Œ—óÌĂ_J€FÓ?°ŸîùCSG"0ˆA8€)cŠŹÀvì'ïJ æDÉ@X ?ɈùȓÙÈ·òĄ€ ÊŁ,0ÊæóhŒá­2(Ű5Â=Á^öööç‡ŸÉ endstream endobj 416 0 obj << /Filter[/FlateDecode] /Length 253 >> stream xÚuĐÁJÄ0àH…\ú0Ml“vO…UÁ=íUP{XŃsăűJ{ó5Čoo9”Æ™” "Rűʐ̟dšÍFtH!%ÔFšΗ_Ł[Ń*0ZŠŠ†'h.”Đ-HüLg„6ż;ś|;đj”æŐ è–WĂ-ŒŸŒ=ój{w 넟 †<șxdcœ›s_ž©č ă”čŻ8Ÿ9?"źŒÌčâ<­†‰Ô±’!S"GBA”ˆ‹GșŒ`TúrʒÚR@ʋöáX9&XâDŰq…őÄ1東>(ù“Î8-Äû…_>Ó ą„ixœ żűę7Óű֐ endstream endobj 417 0 obj << /Filter[/FlateDecode] /Length 216 >> stream xڕÎ= Â@`ÁBŰK8pł‰›M‚à˜BĐÊš„…ą`i#xÁă€rAÁV±Y!$îóR:Œâ1#ƒ€û> .9’‹€*¶Ă…$©î耔ÄO#›Š$„˕GÂŹò$w|c8aYȘzÌꐫ˜vi>[Œ™Őè5É6ùĂeYé/kPú’‚èWpgp°5CúbiHĐŐàîà. [°uC ’À] nà. 1ۃ2(äçóó_èą9†îÖYÿ ÁDà endstream endobj 418 0 obj << /Filter[/FlateDecode] /Length 249 >> stream xÚ•ÏœJÄ@đ=Rl“GÈŒ€›„Ęl6•p*˜BĐÊ8--îĐz§łô|ÁÂŚ8čŰlàÈ8s'ÈÙÉÂv>țźëLP™ȘLàÄzS[pź1ŸßTÆYž«a¶kë âçƒ7?îX>èEŻË[°V——ĐŽșìŻàqętŻËĆőÔ\ÊțFą/L‘Ț1ć»9&„öäB!D˜ŒpĂ!ú/iÎlfÌóq,O>ĘńŽ8ń6bű_&̐~Pțąț°PP{â1ÒŠdJ&ŒÊЗS†ČrKœś“RŽCű â-â$Q‰{6U_ôúæjƒÒá endstream endobj 419 0 obj << /Filter[/FlateDecode] /Length 267 >> stream xÚmĐ=JÄPđYR^“#d.àKb>· Ź ŠŽÚ6 –ŠÖɞÀ#x•XyÿȚ eŠć“,‚ ˃ßcàÍŒ™ÉÖk[UÛ8掰IÊÇ+ËK[&\ä±ÍR~Jű•łËÄæ%ÇzŠȘ°yqšńűb6‰¶œæ&șćŒ4QsÇïoÏ&ÚÜ_qąń1lźYdš!ŽÈDd ż!C7Avˆ'Cë|éÛC L Ą2†2`ŹeÔą;e8„_ç)u ę‚~\úô%(”šÖz3-uGÀÿĐ"tŽțšAĂŒ€č(æòăü‘vßCçXAÇòà|çCV“î 'ĘH íÙÜ4æáRżŃy endstream endobj 420 0 obj << /Filter[/FlateDecode] /Length 222 >> stream xڕпŠÂ@pëm|„Ì žÙ͟œMĐ;ž‚V¶‚Z^Ąh­Ę•y„{•X„ôöÈ hAg),œ|L3Q’HkAI„À(„Đ Ô!DVKK ddaźa Q eüŠÖ$VĘŸ˜ęˆ~&ü „±đż!¶Âφ°^mÂ)?bö Dt%łgŠMŰ=™2.G<»?ÄS1„ó.ȄIâ•čl‰‰3sbȘ†’ùerŠËxÄ”ár'%ê†cwgû€xĆî úțâ+ăyôš endstream endobj 421 0 obj << /Filter[/FlateDecode] /Length 286 >> stream xÚUŽżJA‡'<Ùæ^@žyśîŒIˆ ^ĐÊ6 –ŠÖH‘ŚJȋLȚ`í¶Xîç$,|»ĂÌoö+Çc;qfłŒ‹Úæ_ŻČjl“s]e¶,ű9ç7.Żr[5œé©G”­êÿ‰§W3mMúÈEeÒ;ź“¶3țxÿ|1éôțšs­e{ĂBŠMCKŸô‘„ –â;lĆqÀNŸ‘àN èŽ+“Dá"ÍșĄnq„•xêb t‘(Î;Ÿ(Ö€„ŁdÿŠg©Áb kŚ9Òőžæ;ôÄ[€x Źy„.€pAÛ1~џ@»= ĂaŸ ó&ægŚ©©OT2D!Ț[%?B~1·­yűŒ Ę endstream endobj 422 0 obj << /Filter[/FlateDecode] /Length 255 >> stream xÚuĐÁJÄ0àH…\ö2/`ÚÚŠíž «‚=zòș =(zn}ł<ÊŸ@Ž=”Ž“í* Jà ™dțTÛ­m[ÊmžSYÛą€Óu«\c›‚j—ÛȘ€‡‚ž©:+Źk(—U·”uőïŽû'œëuvG„ÓÙčFgę5œŸŒ=êlwsN…ÔkÙ_Ï)ƒĄ„QuX’É`Nç &ł€† ăw`üÀ~edöûêè?Ô_ÄȚÄK#ŁB$tŹÔd˜ÔlRËf–'’ cúÄÓFˆŚáìż0"DÖÁ;ÉqDbùNúAą‚ƒÁc@FÆ€N‹Š_"§Ą/{}û €XÓż endstream endobj 423 0 obj << /x7e 332 0 R /x28 333 0 R /x29 334 0 R /x3c 335 0 R /x3e 336 0 R /x5b 337 0 R /x5d 338 0 R /x5f 339 0 R /x27 340 0 R /x2a 341 0 R /x2b 342 0 R /x2c 343 0 R /x2e 344 0 R /x2f 345 0 R /x3a 346 0 R /x3b 347 0 R /x3d 348 0 R /x11 349 0 R /x2d 350 0 R /x10 351 0 R /x4 352 0 R /x22 353 0 R /x23 354 0 R /x25 355 0 R /x1c 356 0 R /x1b 357 0 R /x1d 358 0 R /x1e 359 0 R /x3f 360 0 R /x41 361 0 R /x42 362 0 R /x43 363 0 R /x44 364 0 R /x45 365 0 R /x46 366 0 R /x47 367 0 R /x48 368 0 R /x49 369 0 R /x4a 370 0 R /x4b 371 0 R /x4c 372 0 R /x4d 373 0 R /x4e 374 0 R /x4f 375 0 R /x50 376 0 R /x51 377 0 R /x52 378 0 R /x53 379 0 R /x54 380 0 R /x55 381 0 R /x56 382 0 R /x57 383 0 R /x58 384 0 R /x59 385 0 R /x5a 386 0 R /x61 387 0 R /x62 388 0 R /x63 389 0 R /x64 390 0 R /x65 391 0 R /x66 392 0 R /x67 393 0 R /x68 394 0 R /x69 395 0 R /x6a 396 0 R /x6b 397 0 R /x6c 398 0 R /x6d 399 0 R /x6e 400 0 R /x6f 401 0 R /x70 402 0 R /x71 403 0 R /x72 404 0 R /x73 405 0 R /x74 406 0 R /x75 407 0 R /x76 408 0 R /x77 409 0 R /x78 410 0 R /x79 411 0 R /x7a 412 0 R /x30 413 0 R /x31 414 0 R /x32 415 0 R /x33 416 0 R /x34 417 0 R /x35 418 0 R /x36 419 0 R /x37 420 0 R /x38 421 0 R /x39 422 0 R >> endobj 11 0 obj << /Type/Font /Name/F4 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[499.88 499.88 499.88 499.88 499.88 499.88 749.82 499.88 499.88 499.88 277.71 444.34 277.71 277.71 444.34 444.34 333.25 333.25 333.25 555.42 555.42 499.88 999.76 0 388.79 277.71 305.48 583.19 555.42 555.42 833.13 833.13 499.88 277.71 499.88 833.13 499.88 833.13 777.59 277.71 388.79 388.79 499.88 777.59 277.71 333.25 277.71 499.88 499.88 499.88 499.88 499.88 499.88 499.88 499.88 499.88 499.88 499.88 277.71 277.71 777.59 777.59 777.59 472.11 777.59 749.82 708.16 722.05 763.7 680.39 652.62 784.53 749.82 361.02 513.76 777.59 624.85 916.44 749.82 777.59 680.39 777.59 735.93 555.42 722.05 749.82 749.82 1027.53 749.82 749.82 610.96 277.71 499.88 277.71 610.96 777.59 277.71 499.88 555.42 444.34 555.42 444.34 305.48 499.88 555.42 277.71 305.48 527.65 277.71 833.13 555.42 499.88 555.42 527.65 391.57 394.35 388.79 555.42 527.65 722.05 527.65 527.65 444.34 499.88 277.71 499.88 610.96 166.63 749.82 749.82 722.05 722.05 763.7 680.39 680.39 784.53 624.85 624.85 624.85 749.82 749.82 791.47 777.59 735.93 735.93 555.42 555.42 555.42 722.05 722.05 749.82 749.82 749.82 610.96 610.96 610.96 860.9 361.02 555.42 444.34 499.88 499.88 444.34 444.34 674.84 444.34 444.34 499.88 277.71 402.68 336.03 555.42 555.42 555.42 499.88 391.57 391.57 394.35 394.35 394.35 388.79 388.79 555.42 555.42 527.65 444.34 444.34 444.34 583.19 277.71 472.11 638.73 749.82 749.82 749.82 749.82 749.82 749.82 902.56 722.05 680.39 680.39 680.39 680.39 361.02 361.02 361.02 361.02 763.7 749.82 777.59 777.59 777.59 777.59 777.59 1013.64 777.59 749.82 749.82 749.82 749.82 749.82 624.85 1110.84 499.88 499.88 499.88 499.88 499.88 499.88 722.05 444.34 444.34 444.34 444.34 444.34 277.71 277.71 277.71 333.25 499.88 555.42 499.88 499.88 499.88 499.88 499.88 777.59 499.88 555.42 555.42 555.42 555.42 527.65 555.42 499.88] /FontBBox[-111.1 -478.2 1222.1 1005.1] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 423 0 R >> endobj 424 0 obj << /Filter[/FlateDecode] /Length 250 >> stream xڝ‘±NĂ0†ƒ2DòÒG蜎ŹN• Hd@‚‰”0v(‚čćÍò(ś3D9*E°0|’ÏwgĘ}^ŐÁÖkrÖ9òÎÙ:Đeuíì:PȚ?ßLč}Œ!Żq ›[3‘AéôÌ;‘–EŸ”œeT†‚„_(K–Ná K Ž,'%“‰ń"2ä‘‘,"œX ·3N›ßÉÇòÓÿŚûó90[š3ÍĘç}úüŒgÚ;y˜œÀ ÁœÁÂ%œÂíäźáîńcfîóô š0« endstream endobj 425 0 obj << /Filter[/FlateDecode] /Length 246 >> stream xڝ‘żjA‡Oź8ŰæÁyśöÏéb%hč" •m IiĄhíùfś(ó–âd&{Kˆ`#ËÇ20»Ìï›Úí§`Ž101Ú99Ÿ§Œ·ÚŐj§C€/ [pÁjcÁđ±ÆxÆwo>7jȚšj͝Șz“&U5ï°ßŸU5_.ÀrËæJ",˜Ó1x$<Ï/CŠ$Œ„·œ„Ó G€N˜!á0r.#—ą'Gș&H·DĄ_>țÓÂČHś$éęŁÿïçÈțæLsK†”GČ„œ)wò Nč8j{gyt(.Ć©žÇâșëĘËdê”Q«ï4Ą endstream endobj 426 0 obj << /Filter[/FlateDecode] /Length 123 >> stream xÚ364Ò31R0Đ30P°0Đ36PĐ5rLŒŒ ô,Ì M ôLR   Ml3 „2Qt$çr9yré‡%čô=À€§ŻBIQi*—ŸS€ł‚!ázș(ü°{Àw€­‰40`{ÀśĂŽËՓ+e| n endstream endobj 427 0 obj << /Filter[/FlateDecode] /Length 109 >> stream xڍ‹± Â@D­ś+æ öfïŽÛÆŒ"Tù”ŽPôÿ]°Jç > stream xÚ摿 Â0ÆŻt(dé#x/`’Ó?‹BU0ƒ “ ŽŠÎíŁőQúŽJă5ĆA‚łžßćûàBb5ă©FÉ„DE=ÁiD˜ĄNŒ3Ću†§ŻšcIìO"Őgâxačaâ@>&6daÂlń~{œ™ÈwKŒHÒŹĐZûj¶X8!ĄúYĐúÖ¶tă9_Kš=ÛPąò]° Êđ ƒ‚Éw4žC8ôő hŃ\ąŽúŻ9œz lmŰț N< endstream endobj 429 0 obj << /Filter[/FlateDecode] /Length 221 >> stream xÚĘÒœ Â0à+ … öïLÓ`[ ąàŰAĐÉPGE7!}Ž>JÁŃ!x^üÜ\t0ä»$w„$N€ÊPI„Pó˜b'⩋©Ö2U˜dZÆź#ÜaȘŽL4*îOŸeʶb˜‹pɛ"œȚÇ|†‡ęq#Âá|„Ǐ0#,Xą+À „ž[€&@‹šŚŒă[đȘ:Ÿ3ü \΂šòŰmFY{Ágp!*‚7p:8‡6§›Kˁk^OOęàтđƒûüűŻôùéÌG“\,n^XgÊ endstream endobj 430 0 obj << /Filter[/FlateDecode] /Length 311 >> stream xڍÒÍj„0đB.ûæȘq깞„m őPhOœ.Ž=öĐҞUúbî›ärô ڙD»«‚tùMˆđ“4ÊŒ0ä‚G b~`ńT„Ž–€{/ŽùkÀ?űuČśÒ˜ |’ —łù/ïìP0ÿś1ÿ·0żxà_ŸßoÌ?<Țđ{Ó·|À’%ŸÔ\MŸVćn v+őàlš{„Ź )€IÇIòć(ù'5©QÚIu źŃÏYĘ$»Łű$§Ő;:4iwÖ0ȘCÙFîP”(Ë(żPc€P`TÒH’J-:çB )'èhŐ$—TÖBŒ©^Ë!рêŽlŽ"”Z‰.A3—ąË‚%IÒšT^ÇW^ÇW~T=èÁæ8QĐsŐő/±»‚=ęLä z endstream endobj 431 0 obj << /Filter[/FlateDecode] /Length 255 >> stream xÚ„Ò±nƒ0àC ©Œ°Čq/cÀ0Eą­T†Jí”H:vHÔJْGăQò= S8Ș:b ,ßI‡ùïdU–> stream xÚƒ±NÄ0 †]uš”„śÍ ĐŠko;é‰H0±"# ˜[ȚŹÒGđŰ!J°“\vșôsbÿŽü{SëòTIU*%Uj-O4­lÏtÙ¶ČÙèrœ–”|Ę3eËVéČŃÇÏbډêŽòDuE)ąêźćûÛǓšv7çČŠ8„Ę…tôAîÜ@ÿ €ç,–`&È ÁHÌ|Ë”’Đé=P #"l}©”!)…”ܐú.à cÀr«(œo<`Ë€Ô€?‚Œđ700.ü„!€ę üsXú_ayF|Ű`ń7@„8»À*jłŠĂ4*ŽwVfŃ|‰ŠLm1ç>‘ì`Ąƒč6Ă`śœcX€©@ö5·ĐcXڃ°6)/RÎÀ«Ő{đíP\vâö lPÏĂ endstream endobj 433 0 obj << /Filter[/FlateDecode] /Length 246 >> stream xÚĆÒœ Â0đ+…,>‚śŠI±i?À‚Nź‚::(:ëŁőQú;HcjÓD‰N6ËïÒÂĘ?!ee Œòû\Œ‡! qH#Ž;ŽGŒŁ&™Z"QÛŃûíŒSŹŐ9ÌŐ€ <Ÿ.{Œ—äȘnÊtŠđü€”yŁź‘gWŁžÌeöüăkUĐђŽ*àȘUÂHë=­ șZÒêæ·Ê:źrÏUŸŽqTŸü]żżyó„¶W9ž=Í<·śv2à;s«ÌTí€íôM"*§FEhĂÖjäŠÎ&±~!™„dőŠÈ• endstream endobj 434 0 obj << /Filter[/FlateDecode] /Length 217 >> stream xڍҜ‚0à’>Ćœ€„ù™QLtr5QGî:ùZű&ő Hk8ˆVÄvù.čëïE~ÌŒ8ă|΄€‘0Á"î±Đƒ0òX `'àˆæf†±ađ^±=Đ$„îÚäQwnRš›.à|ș쩛,' L\…éH5ُĄÔ’h­:CäˆĄÚÆ ńèÆóś/È{áhĘ…(ȆčđÿhȘÚuTśŠŠÔ'ŽQBt‹ÂÆæči!C\ńÁ ț ą@H‚ @°% ~ÎRșzŁ›„ endstream endobj 435 0 obj << /Filter[/FlateDecode] /Length 324 >> stream xÚÍÒ=NĂ0đušäĆGˆ/€ăšæc‹T@"LŹ•€‘ssź”p…ÁcËæ=»ùšű˜I‡üÜÚ~źßżȘ¶Rm…’J‰BI­Ć™ÆA)*}NŻąÒ2ÏĆăFŒˆČĐČʅÂO©Ž,ô銇g¶kXvóXvSXÖ܈·Śś'–ín/ÄÇqŰ\ pï? ąđžŁ€Ž4 Ö–ÔĄ’DżA9Hđû=j =   ÔŽ ŐăfȚ’:œ†“Qí*4Ö€–GKqn,€€ž›aĄš„Ő N…g %–“vł’ïjŁÜ/ ÇŁ*đ?Ôâ„C;+ùKń_Ò=/ŁúoòTńÆŁÒŁì€Ű-7upîȘ›:mcśG͉˜S“1MÜÁ~LXÈUHĘʎIä!“”ÎÚš *hŰUĂîŸí‚ç· endstream endobj 436 0 obj << /Filter[/FlateDecode] /Length 123 >> stream xÚ31ŽĐł°P0Đ30P06Đ34TĐ5rLŒ- őLŒÌ̍ôL R  ŒM őŒ  €ĐÌ(lŠȘ#9—ËɓK?šŽKßš„KßÓWĄ€š4•Kß)ÀYÁȇp=]pÿ€h”ÀCà :.WOź@·ŐòŸ endstream endobj 437 0 obj << /Filter[/FlateDecode] /Length 172 >> stream xÚ337Ő37S0Đ30P01Đ34UĐ5rLÌ ôŒ,Ì̍ôL R  LlC 4ł ›ąêHÎćròäÒȘăÒś*áÒśôU()*MćÒw pV0ò!\O àÿÿżęÿăÿÿŁ4ú~úŒnÀO?ÀA@ŁŃhFęJÿÒ? ô(ĘĄÿ00‚㕁™ ÍćêÉÚȅf endstream endobj 438 0 obj << /Filter[/FlateDecode] /Length 291 >> stream xڍӿN„0Àń’.éÂ#đ{Këńçn"95‘ÁD'WutĐèL7^ ćE Ÿ#ĄöŚSŁáGžČôCÚá›_Șd’ˆm RH ‘*†e’j#Ò$驈<(x†]șIÒ~ÉÖțŽÿ_čâûœ‡·ö/íæWđúòöÈĂęő(ëós`Ì3niæÖŒ@ûqSęÀ3Ú|° 1À5 ęĘÚGtÍŐŃhVˆz «+ ôźÎ'0`Đ1hȖ`°ź/(`]g(`]Kƒêe`]Ië|¶n HŰ !#aƒúâhż34Șu;ƒfUÏ óÊcĐ3΁„› ƒĂŸÀ= ęûJŽ™Ăû_|~ƒ_äüæ mi endstream endobj 439 0 obj << /Filter[/FlateDecode] /Length 202 >> stream xÚ37łĐ36V0Đ30P06Đ34TĐ5rLÌ Œô̌Ì̍ôL R  al 4ł2MQu$çr9yré‡Őqé{•pé{ú*”•Šré;8+ùź§‹üÿÿÂà‡1a †zCțPìÿÿ üÆ?vă3”q€ÊxÀe|`HÀ`(@?°0šÍ@·›{ĐĘ śÌ_pŸBęö0Æ(ƒưÿŐțű2ÀéX—«'W uE” endstream endobj 440 0 obj << /Filter[/FlateDecode] /Length 365 >> stream xÚœ’KNĂ0†myɛ!Ÿ‰›>V• Hd+,Y€`‡ÔH\,U/’Ț Ë,J‡yž”šKòżqfÆÎïżœLÒÂ;Ÿzïf>Ísw–{ŸSW”yzž»Ó©{čWä9'ă]–ăt|Xòđl•Íî1ŃfژcłêÆœœŸ?Ùlq{áFKX]:èŐűRJóŰ+%S-BLPkPdž­ 5\Ś)šM0—j)»ĄÄ:’—#îß9*¶ÜŸWËđAÀp€.@B+đm€x€Fö«ącš˜0 ő èÿ„ûö|âÛń±,ƒb€Ą& YjR›ž‹òϓ°\ąâ pÛ:ZÁ'\cÖ°ąclő6tŒZŁ:30§eŽXíł5h›ho€ŸűVś> stream xÚ­ŃÁN„0à!=ôȏÀŒ€ĐÒž §MVMä`ą'`őèAŁgx4|“ő 8r0ŒSZJnkIšošNÓțŠHËUȘ•j9;,Œ±Őv—§—Ÿ4ŸbĄŒĘfżmÉËćïŽă‹ÇƅI6ŁZȚTòáûŃè endstream endobj 442 0 obj << /Filter[/FlateDecode] /Length 327 >> stream xÚmĐOJÄ0đ„€…nz„涝0팫QÁ.]yuéBŃu?˜‹ŒÈ€èȋÒç—D ¶‹äćęiÜșŰÖ¶*ȘÊ6Uáœ=w 6¶ź]Q5¶ÙșąźíÓÊŸÚőĆȘŰźmĆSčąqˌǗtߊćï„ć Ż€e{kßß>žÓrwiWŒcŰ^Y•ËdTZ>!œRĘą”Ê frf0©îš F#33‘Ț ÏEČ @&ҝ˜#b țp8±[ÀÇۄÊ"IÄt$Ü!>»Í"Š}Ś#ˆŒDuœß.L€rHńW?;3 ò35‘xŠP;ÒG_2zŠĐÈ/ó9‘üÌòàuŰÒ€ĂzžO?:—쇟pŸÁżĂ‰4Â|ÆO$Hư‚,”FÎ.;AzĘŠśßs*G endstream endobj 443 0 obj << /Filter[/FlateDecode] /Length 185 >> stream xÚ3·0Ò32R0Đ30P01Đ34UĐ5rL̍ôÌMÌ̌ôLÌR  Ì,ôL- €ĐÌÈ4DՑœËćäÉ„TÇ„ïT„ïé«PRTšÊ„ïàŹ`äCžž.  @‚(ăÿ ő$äAŒÿ8ìÁŒ ÿÁŒF#„ń‡ŁÂű‡…ŃaüÇÇ`‡2űĄŒbÿĄŒŁ j2~€q .WOź@f·X endstream endobj 444 0 obj << /Filter[/FlateDecode] /Length 393 >> stream xڝÓANƒ@à!,HŰpæÒNmiș"©šÈÂDW@]șĐè źEĂEè XČ ó|ÿ ŰÖ6©±M^ßśü”ŠUŽ\Èi4ÊÏ„Œ°?J]ÎŁÙ\ÆËYŽPòYÉ7ÎÔZŽEŁ<ÈmŒ8źŃÀö€Ü}lŹr·Dő ƒ*ǃÊQ%Œ<«æçß=§Ęù9Öpš’Q8©§W#:'m^‰đ&ŃŚ_TbԐ“úßOî·Á endstream endobj 445 0 obj << /Filter[/FlateDecode] /Length 253 >> stream xÚ}Đ=NĆ0 `W*e Gš/@šđúC'€Ht@âM@0§G37É:všjÜä P†O¶ìŰrS·Š«Ńkqgsx~!A‡ÍΙŸÇșqŠíńÙá6֙Ë­ŒșsŠkv<œêę «G©Ó՝”èjžÇśÏ]íźŃIœÂáy…’™8@¶1xŠ@ČŽd<æLłâ „Œ§Œižá”üoVžÚ6á"Áÿ±@"s‚àlTü Êű5ű&Pš@yd<’æÁ‘òo– ™Û§D€‚(ă/Y#€WrÙ(dË2ȱŒdxRČ?éÛAŸÏDÆc endstream endobj 446 0 obj << /Filter[/FlateDecode] /Length 250 >> stream xÚĆŃÍJĂ@đ)K!/ d^ÀÍȘ`=őȘGŠȚŸX}“>BŽ–ÿIK!"xÙρٝ-]źm Ÿm-Ÿ9•Ó6çrátQđćG.r§cƒS§K7œ±yPËVekä©ì)*kWüüôrŻČćÍ[Äû°œdéńDżâś„ŁGˆȚ@M”Cn¶ ég BÏ –@݁PJEèt|ì@7Ÿp2Čęú&Őż”4?¶;4_GÁ†ÁȚćcÎ>ÆĄŁ]ÓaqO”ű ŸæC*X‰Çúv‰xuŐȘÛ/v?>Ł endstream endobj 447 0 obj << /Filter[/FlateDecode] /Length 240 >> stream xÚ­AJĆ0†§dQÈŠW˜ ˜&%m_W-O»tćÔ„ EŚŻàÂk7éČì"tœŽ‚Œœ>űɟòï:s8 5Öą·ÆŐxQ‰hŃ7ÎŽúڙŠĂ'‡Żè+gê­ßÊmsțâńEG]>ˆO—7bŃćx‹ïoÏș<Ț]ąœËń ™I1ń Đ€‚˜ńTČú(Â)-À K–6ÎꏔÿRœSÎk–È_4,#vÂ?1%Ÿ“v*Nă7ΡBâ€9 œx–.=Ó*AŸÒQĆ|ë[lĘe@¶Á’GúzÔś?&™Ä† endstream endobj 448 0 obj << /Filter[/FlateDecode] /Length 239 >> stream xÚĆѱjĂ0à ZÒ7èœ@eYXv¶@ÚB=š©v,$!«GóŁè4zQĆ„Ž`È">NâîԘZ-,k„5ŚZU–ï ‚–íšȘćXËoïŰÖFiĂ»ŐF5æÿÍ‡\uČ|Ež,Ÿ"Ëî™ûÏwYź^îčB<†Ę'Ź("΁ΒüHžęm&Ò,ˆ¶ 'ҀŠ\à‘–Gé+9ƒ8Uf§WüH_Là~˜ÿ….€›dȘ€\źÿ%·‚Žàr›)ćŠ#%šûà0àI`Bű¶"“Ü2Q>vrę p\» endstream endobj 449 0 obj << /Filter[/FlateDecode] /Length 243 >> stream xÚu±NĂ0†ÏÊ`ÉKóœÀ±iÒÀ©€D$˜xèˆTÌÉŁùQò7zˆ|œ ąeš-}òŻ;ŸŸküÆú+tÖ9Ü8ë=^\Jh±nœm·X7ȚnŻńŐă;Ö”Œtr«ÿ~ŒŒ™]oȘgé3ŐœŽ˜ȘÀÏŻœ©v7è%/±żE栙xˆ `MVÄŁšșXP‚aV4' š˜á@Eæ$Ę€3e ‡rážpőGȜdì Ï©ŠÇާÔG†#![-]±MeæčœaàètL–qAvTIQ–)ˆăÏÖ  #ńSLæź7OßÇ·Ü endstream endobj 450 0 obj << /Filter[/FlateDecode] /Length 187 >> stream xÚĆÌ= Â@à1‚-â Ì\ÀÍn6?€±ˆ ŠŽòj)šh+9šGÉö!ăD Òh#> stream xڕ‘ANĂ0E'êą’79B};MÒv•š€DHtĆ€%RA°NžÙ%GÈ2‹*Ă·­ ÔńâiìùóżČÊÍșÒÖX«ŚÖ8§ŻòܚmźË”3». gȘR?;ęŠKëÌvŁ-V]±ù#yzUûVehTÙzTÖȚ돶Ï•íź”CËöF‹ĐJŸXFJNÔ ßLuOL'’aÉ4%2.˜Æ…LÉĐ <,Çg°GśüžF #á`+BûH©Ż±:Ž) ĂtÈEÔ«ˆ4SêMțæ]Ä*8P [È6“ âSđLŒŃqŁ™Ą†äęÄÎ(àŸörf<%aôŽàŃßn‰Hő|ÎR3< Ż„GxMê¶U‡ožŠŠ endstream endobj 452 0 obj << /Filter[/FlateDecode] /Length 187 >> stream xÚŐË1 Â@Đ )ÛäàfwÉ.Ic *ž… •PK E;!-Gń–)$ë$©Š„8S<>óÇš„§Á„Ʊ€ ÎWMȘžÖž“xD­­Ą«Î†Û+,‹7Ôcń‚*,¶K<Ÿ.{«)JÊ}Ž3t·Ü9Ś|ćÙÓüŒÚëš lˆˆ @@€aćąŒ· {xÄšÇï \ D8 zGțOÀșù›[¶~!5 endstream endobj 453 0 obj << /Filter[/FlateDecode] /Length 150 >> stream xÚ”‹1Â0 E=ûű$Ži ™"È€FÌT⌠UƒQ21ńę–o?Oœ˜Jˆ 3Ulœ§±ÓR‘ÌœaOuăITLŸ™Č˜ZÊę ›„v§ڕ*hӚź—Ûmł™“Ó>ÔŽ üÈ=äî/ˆÊFß KœȘŁæŽ±…‚bÿ  .nßÇ{}/ endstream endobj 454 0 obj << /Filter[/FlateDecode] /Length 239 >> stream xÚĆѱNĂ0à«,QÉKW&z/€c78Ș%D€`êFÌ1o–GÉ#dÌŐžÿ-0 Ž”-}:ëîlË>”Šrl”\Ză_ș\±ŻVÆYźÖ+ă=ż8~g_:Û<«·ĂߊʛȚ4șŰæ<]<ä]4üùńőȘ‹ÍÓ-»KŰÜqŠuJi$:Ê$ìON€óc Kdö5è€î[P`šƒq †ô-ˆrĐ Ü(p-ŃZ`D­PÿâŒĐó‚èB8šB§„è ˜8Üșèđ†v/$ZsèTțšă_ô}ٟw2 endstream endobj 455 0 obj << /Filter[/FlateDecode] /Length 127 >> stream xÚ364Ò31R0Đ30P01Đ34UĐ5rLŒ, ő ,Ì,ŒôLMR  ŒL ô,M €ĐÌ(l‰Ș#9—ËɓK?šŽKßš„KßÓWĄ€š4•Kß)ÀYÁȇp=]ț7Ű700`â?@üo`,€ËՓ+đ$„ˆ endstream endobj 456 0 obj << /Filter[/FlateDecode] /Length 225 >> stream xÚíѱŠÂ@à )Ûä2/p›]ł1—* \Š­l”ŒCÁÊ”ó”_$°„EÈÜh ±ìeöû‡™jò$“ •T ’:ĆÍÁ`źi4Łe7ĆčÆ_üÌÙéąâgRn珳„è•"󜈿yDÄćźÿ6 ś†}ԜÛXööâ9Ÿ{„‚ö`Żù‹žvAĘÆmXù.:ÌUáŒÊV~SÄœšòšŠt3č+ûÌCˀj9>2dF-#fńŒÓŸy'Üî|x…⫣»_ endstream endobj 457 0 obj << /Filter[/FlateDecode] /Length 182 >> stream xÚŐË= Â@à )Ûä™ žìS ‰‚)­l”T,Äőh9ŠG°L!YGSôÎox“jĂû%—äÊbOQ0h3Í”BcO-źîŃZÍeŠ’ÖX:gʏՖć%sê11Š ć‡Ó†‰|Z ąÜÆrˆțæêÀ7źś !źqŽ«Űč{Ű> stream xÚ„ĐœjĂ0đ3Züčˆ,9țš'CÚB=’)ĐvìВÌčGóŁű4zčžêž!Č!~:ĐęŻ(3ł(Ńkqas8Ï€š°Èœ© Ì gÊ?~c^;󔣕•WÎTćő‹ś/œluș•{:}“+:mWžûÙêtč~F'őX¶/ÈÜÇÌÄ'€FĄˆRhNp ÙrącÄÜÍh$äćqŻÈ+fŻšÄ] ą.a"ąÜț€čśĂÔËÈÔgh>ž2œ9†Ž3 -ٛÿIt‘àÔefăők«7ż©:Ìà endstream endobj 459 0 obj << /Filter[/FlateDecode] /Length 243 >> stream xÚ”ĐOJ1đWF…č€Đw3ILŠ.UÁYtćÔ„‹Ę Łő(=B—.†<żT,âșQfń›À yߌ8ŻÏm Ÿm-Ÿ8cô4p˜:m={ouűȚò‚ƒwÚ86űüúŻWîŐŹSő-U}…Uws~Z>?šzv}ÎçścwÁÒÇm)Q$Z–h Q 8ź @Č òJCą<ț’šmą‰$:N?Š?ú5ę=?ż7țŸÙnĘŒ|»R"‚ČÍ1G9tB}PHPO(K2›j‡Èÿ€æWP—șydi a endstream endobj 460 0 obj << /Filter[/FlateDecode] /Length 250 >> stream xڔѱNĂ0ĐłŠÉćr?€c;…©R‰ H0ń-# ˜cț,ü‰ùƒŒN9źIa@šÈĂóIgûîÎNLćĐkŃ[ă—ÖšEÀpZ·@n>ađ„±%ZY•lęÏ#ëœȘuq'‰șž’]ÔŚűòüzŻ‹ŐÍ9:‰§°Ÿ@æ6çb‚żwüFÜ4d]źh€œ,Ą‡†uÀ%(JBRÔΟé„l$țÌÿžžçœŻ’&v抩ű]+œÛ6›ŠŠ”Œ`žŹ…JŽË°Č-—#ăÿDò#{З”Ÿę I9 endstream endobj 461 0 obj << /Filter[/FlateDecode] /Length 178 >> stream xÚœÎ1 Â@ĐO …-ôq.àfŚìFS‰‰‚)­l”ąh'šŁæ–ČqTkxđ‡?0ÆÆ2쑒JQš€ÖÔÖ ™Ž–¶KÆhYZiÚRki"R<Æò:țŸXnD’‰`Î=Œč"‚lBûĘa-‚dš’æüŠÙȘâ\8à8ąäš1č,JÜ0(á>šżi>čx­kq>SčOúÿà?~!F™˜ĘʙŠQ endstream endobj 462 0 obj << /Filter[/FlateDecode] /Length 242 >> stream xÚUŽAJÄ@E+d1Л!u;ĘŠ'aVŁ‚YșrÛ .]( î&Ț,G©#d9‹`ùˑixôïú]ÿ§Ôú.qđ!p >źùìąçv}ê8­Łï6üù…[ÜÛÈ'őŃśĘÿÏn7žæ>Ś\Ăâšá†ß^ߟ\ł»œà}”Ă%«”KVąŒQž R-”§­{òš*ùÓPšÎ'2ęaošá!Ld€Ê@*ŃÖP‰•‚ő…X|YŽ<ČêdÀHm*Ó?XÙN`>ą<Áj0Üò kŠ#ÜK0€•D+©&Ș„>*îjpwßź4‘- endstream endobj 463 0 obj << /Filter[/FlateDecode] /Length 184 >> stream xÚœĐ? Â0đ Y<‚ïæomq­ ftr-šŁƒą{ÖŁä;„Æ €‹‹~á%_†/™)žYĄäRą& \ ›)TŒÈ”æFăEá͒ŽJZyŠyöőâ|c„eâD9&vaÂîńùx]™(kT4ŁĘ`èçÁMâ'èFÚ7ÒDê>Ò@|"ą‡đÄÌcš: MÚVÁ%ŽúP}Hè‡ u ;¶”ìűżÓM endstream endobj 464 0 obj << /Filter[/FlateDecode] /Length 183 >> stream xÚŐË= Â@†á e[»ÌÜ?v7± DSZy”ŽPŽ•=ZŽâRnv‹4ö2ĆĂ ß8mxaQr)ŃHź,Î4EŽvźčVhŒâÎâQá­Ő\:”tÆ)žëțÇáÌȘš‰=í˜Xӄ‰zƒ·ëęÄD”] ąțdœÄäË!”üЃ2”#ț’¶ÇłG1}ɒ‡GòY$? Są(ˆ  Ț$? ĂÈV5ÛœHÍÇù endstream endobj 465 0 obj << /Filter[/FlateDecode] /Length 231 >> stream xÚ}ÍÁJĂ@ài{XŰË>BæLvÓMĆS *˜ƒ '@=öPŃs òZ-}‘ű9ö°düw+’"ÈÂ|Ìì u5ÏŽmn-—š—|á€çjQæÎȟ»űÿâx͕/s[ČĆóăêüây„—.ž°§‹;Źèąčçś·W],źÙĄ?”Í ‘ąÿ(Ù‰€IlA Ô/*È0“t   5 9‚#ŰD6=@"ő@=@ü!a>#[Ó&”Šì”ILĘ4KPą§ú/ÈHF “12;Łú¶Ńß*íR endstream endobj 466 0 obj << /Filter[/FlateDecode] /Length 294 >> stream xڍĐÍJĂ@đ‰öČŚȚ2/`Ÿš6 Ș`=ùêуąW(ŰŚ ôEâì1‡ńŸ€9€ x۝ßîÎ2»ł#opàG˜Ÿ bN֑wqŒœUÈÏ!żqȊŒő’‘ÍqŒíćôÆÓ«ÚfÊDžòïąülÇïŸ/ÊßȚ_sˆő°Ìn˜ÈȘˆrŒÿȘ„TJWdozi‘äörŒ@•#ą!Ę©… -Ɩ֝ȑʖ*!KšȄހ†pT’ÔùD–|“Ètêą’^Ő$šÒŸ^ùI }čEzćÚ@{š„MZêCŻùIBóŒÒz”3fœ ÔżpGQŻîĆhÄêțHùT]!9ș7š†Ź35]ż„"GHĘfêáíS(Ž endstream endobj 467 0 obj << /Filter[/FlateDecode] /Length 258 >> stream xÚ}ϱNÄ0 `Ÿ:EHy€úh“^zˆ…JHt8 &@0śĐœXïMú;D5“h„~rc;v}č.6Žma-Wű^đčžëMU8Ë~í–ógÇo\ûȘ°[ŒȚăwę»âéUo[]>"O—wHŃe»ăśÏ]nïŻÙ!Na{ĂD+ééô?„Œ„<È^ÉÔé3» C&ƒ€€‘ä LÔ@ F™źLä,B'Ížș…>1DV‘1ES:C›L”§“P±Ӏă9  Phƒk Ú`ƒzL–Ï‘f&Ź2vX ĂcäˆiȀ°T \CËó7ú¶ŐßülÓ endstream endobj 468 0 obj << /Filter[/FlateDecode] /Length 283 >> stream xÚ}ĐÁJÄ0àìöÈ%ĐŒ€mÚm»ìĆÀȘ`‚ž|őèAŃs {èk”ì‹Ô7豇ĐűOZdWAù20“&ßmą"Q:ÒZ„ž·ê"MtŽĘ©ŒHŁD«l“PÂsąȚTž„‘N•Æ)đÌ~—<œŠ})âG$Šű9".ïÔÇû狈śśW*A<‡ć”bŒ9ËŰL,tźłŽ8é©AűÜșHž ô +gÁ `n#šˆj8Â,ô}żf:€öG<”l<œ-—ž”§_‡æ˜ù úž`™;aZâ‚3š3űŒœ °&‹ù‰¶ČÔf$X8VžaÁyú™ÎcD}É=Ł$ZÚ<țÄè›#ŠÀ#nJńđ ëŸY’ endstream endobj 469 0 obj << /Filter[/FlateDecode] /Length 146 >> stream xÚ353Ò36S0Đ30P°4Đ36QĐ5rLLÌ őÌÍÌLŒôL R  Œ- őLŒ €ĐÌ(l‚Ș#9—ËɓK?šŽKßš„KßÓWĄ€š4•Kß)ÀYÁȇp=]țÿÿcÿçÿÿ âˆh€Ä ÁÀ€…°a€)a.ÀćêÉ”©Óä endstream endobj 470 0 obj << /Filter[/FlateDecode] /Length 289 >> stream xÚmĐżN„@đ!mhéې?' W‘œšHaą• –MźƒÄăQxÊ)67~łš3 ä—Ì2»;M»ÉÏ[[æei›2ݶöŹBQŁšòî¶ő&ŻKûTÙW[7UȚnm‰§m°\Ÿîx|1»Áè3Ć ZL1ÜÚś·gSìî.m…ú»źŹeÂČRgą‘…ˆ2v0bŒf2/#ŸïgAo7‰0ìa:%â(„DStÛEțępÎÔ„WEŽÆàpb ʏèœ{ŃűèȘsäMÔ)S©g=čÄi:áP]uŃÔ2êäß@=„ȘÓA…1b,kŻ"> stream xڅ=NÄ0…'Já•·ÛĆÀqBț¶ŠŽ€D €„â@Ii»ÍŃr”Áćњ' ŠôIŁŒśüfÊ*7Ś•¶ÆZ]Z“íôUNCMCfšZWEn «_2꼋23ŐN[ú*ČőoÇó›Üw2}"LïI"ÓîA~|œÊtžŃÍóŰĘjïAyô@Zô=€BŸ8 ?Dˆ ęa:@'H{tsd6#üÏ o0fe:8zÏiÄqfÄb&œëčń ČđÄ ŁĐSŹm1Ž]”‹Ś…œ9'h·+ϰč \Ò”ÌA1{ńCˆÿpłrZž%%SńŠ}ÂNÜdTŒ#]è’dÈ!*Üčć›ó^ŽšGyŚÉÇoôđțæ endstream endobj 472 0 obj << /Filter[/FlateDecode] /Length 224 >> stream xÚ­Đż Â0đ‚ƒ’ĆŐÍ{Ó€M‹N‚À‚N>€::( nVúböMú;”jžŻ ÄĆËđ㠗#IzÒII„ÈWRkh ž–Ł€BăIŁh§éHf€ćАČ+ ì¶ižŰÄ$îÆö wa[„-é|șì…;YMIیÍèiëńŒ?ˆĂT lP€dàŃ Su˜ČÇ5C&ż2fŠàĐfȘ.Sö™ąfÌä7&ĂÍR4h3U—)ûL1fòš“á})H@ 8żëę/ÿ$Æèïˆy$Ö/]?c endstream endobj 473 0 obj << /Filter[/FlateDecode] /Length 275 >> stream xÚ„ĐœNĂ@ `Gʒ”Ûùž\Bțș©€D†J0ńÀÈ©[›…7é#dôŐűœ •Dú$ëìłÏe•»Ë œóKïČ-^äÔdꩱ*rWx|Îđ ‹2sŐœü•”őWłëLú(y&œ““v{üxÿ|1éîț3‰—°»Abæ™È2DÀą|j€źÔ”ššVíƒWȘUYlùމx%5-.}í&áIŠZéœ ÏpÉgh€öÍ܋če‘!>ΝúàhƒC„ĆőŸÆz> stream xÚ}бNĂ0ૌHć„k¶úHœŠîT©€D$˜x`d”­~Ž<ŠyƒŽ7D9~·”€P€OșÈgßęłșÌÎkc3kÍÌfĆœ•(æ(ŠÌÍM]•YeÍca^L5+Čza,ŸmŐüžăáYŻßăœÎŻqDç͍y{}ÒùêöšwesiDZłH  ô€?ˆX˜ÖŸ•’ĐJ7‘àÄOĆ;Ą„PŠžÒ~/:RE7%B.êÛèwPŸLąțHVрy(ń4…D Óé$(Š“%˜hĘÓΖ⻎F{1ŐȚűîű—žêoężv?wÛ;Á)n­ŸspL‚ ûíŽĆɅŠŰc#„ÓÆËmڂä1ë«Fß}—ŐĘ\ endstream endobj 475 0 obj << /Filter[/FlateDecode] /Length 240 >> stream xÚ„ĐÁJĂ@àjÀÂ̘yn’mȱ—ȘBsôäšGŠ^Mƒ‡ŸV%ŸAŽ9„Ygf…h ^œ…~vf6·FÏ-$:IÀ&Ú˜ äóT/`é>+à!…gȊTÔKǞçż'îŸÔșTńő©xC-*.ŻáőćíQĆë› H)ûX^§ŁÂÖˆźC›ŃcńD<ÏÄ„wËŸŚŽŹÁČܑSĆ!Ä©s}„ĄsĘJŹŰ¶Bul-Ł4BȚíĆ.mœ+¶ùáÖ[±“Q> stream xÚU=jĂ@…gQ!ŁF­:íąG–íJà$§Ê’”)p°ŽŠŁì¶œBhòvƒàƒYœśx3«vYܶ¶*ȘÊźȘąȚڛ%†5†șŰŹmÛ,‹ŠČo”ęŽÍȘ.Ú­­đ”°5ëkÇëGČë“òș€|„$)û'ûęőóž”»ę­1ŸÆțȚŠ ©°LD 'êXFą”e8șˆçH&ĂS,3ń”ŠsÇ!p<űܜè@wf~ÁT+*)xuÈq”ÊÀž"${2ła&úł˜QŠržI[‘6Î sm+#}1Ș!è18‘‘ĄC`śbÌĆŃbè„ÁcŰ Fá"! tJAŸ&ôțéCŠűl [gcȘ›ÆáVȚ„ë1uȚèF‘öL”s§ę±—àœ<ôÉóLö… endstream endobj 477 0 obj << /x28 424 0 R /x29 425 0 R /x2e 426 0 R /x2d 427 0 R /x1c 428 0 R /x1b 429 0 R /x41 430 0 R /x42 431 0 R /x43 432 0 R /x44 433 0 R /x45 434 0 R /x47 435 0 R /x49 436 0 R /x4c 437 0 R /x4d 438 0 R /x50 439 0 R /x51 440 0 R /x52 441 0 R /x53 442 0 R /x54 443 0 R /x57 444 0 R /x61 445 0 R /x62 446 0 R /x63 447 0 R /x64 448 0 R /x65 449 0 R /x66 450 0 R /x67 451 0 R /x68 452 0 R /x69 453 0 R /x6b 454 0 R /x6c 455 0 R /x6d 456 0 R /x6e 457 0 R /x6f 458 0 R /x70 459 0 R /x71 460 0 R /x72 461 0 R /x73 462 0 R /x74 463 0 R /x75 464 0 R /x76 465 0 R /x77 466 0 R /x78 467 0 R /x79 468 0 R /x31 469 0 R /x32 470 0 R /x33 471 0 R /x34 472 0 R /x35 473 0 R /x36 474 0 R /x37 475 0 R /x38 476 0 R >> endobj 12 0 obj << /Type/Font /Name/F5 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[562.36 562.36 562.36 562.36 562.36 562.36 849.33 562.36 562.36 562.36 312.42 499.88 312.42 312.42 499.88 499.88 393.42 393.42 393.42 624.85 624.85 562.36 1124.73 0 437.39 312.42 343.67 656.09 624.85 624.85 937.27 937.27 562.36 342.51 562.36 937.27 562.36 937.27 874.79 312.42 437.39 437.39 562.36 874.79 312.42 374.91 312.42 562.36 562.36 562.36 562.36 562.36 562.36 562.36 562.36 562.36 562.36 562.36 312.42 312.42 874.79 874.79 874.79 531.12 874.79 849.33 799.57 812.3 862.06 738.25 707 884.04 879.41 418.88 580.88 880.57 675.76 1066.87 879.41 844.7 768.33 844.7 838.92 624.85 782.22 864.37 849.33 1161.75 849.33 849.33 687.33 312.42 562.36 312.42 687.33 874.79 312.42 546.74 624.85 499.88 624.85 513.18 343.67 562.36 624.85 312.42 343.67 593.61 312.42 937.27 624.85 562.36 624.85 593.61 459.38 443.64 437.39 624.85 593.61 812.3 593.61 593.61 499.88 562.36 312.42 562.36 687.33 187.45 849.33 849.33 812.3 812.3 862.06 738.25 738.25 884.04 675.76 675.76 675.76 879.41 879.41 893.3 844.7 838.92 838.92 624.85 624.85 624.85 782.22 782.22 864.37 864.37 849.33 687.33 687.33 687.33 981.24 418.88 624.85 514.92 546.74 546.74 499.88 499.88 783.95 513.18 513.18 562.36 312.42 480.79 378.03 624.85 624.85 624.85 562.36 459.38 459.38 443.64 443.64 443.64 437.39 437.39 624.85 624.85 593.61 499.88 499.88 499.88 656.09 342.51 531.12 718.57 849.33 849.33 849.33 849.33 849.33 849.33 1018.27 812.3 738.25 738.25 738.25 738.25 418.88 418.88 418.88 418.88 862.06 879.41 844.7 844.7 844.7 844.7 844.7 1143.24 874.79 864.37 864.37 864.37 864.37 849.33 705.85 1249.69 546.74 546.74 546.74 546.74 546.74 546.74 812.3 499.88 513.18 513.18 513.18 513.18 312.42 312.42 312.42 374.91 562.36 624.85 562.36 562.36 562.36 562.36 562.36 874.79 562.36 624.85 624.85 624.85 624.85 593.61 624.85 573.93] /FontBBox[-125 -544.8 1375 1013.9] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 477 0 R >> endobj 478 0 obj << /Filter[/FlateDecode] /Length 218 >> stream xڕ; 1@!{Áč€ÙdAđn!hćÔÒBŃNPo¶GɶŽg] ”“Œ&„ÌŒg­“Zƒ’JV}i5t’ž•ȚƒqFÎXéș°Ń°‡ś‹âăœ—ÎțțYïÄ(ń ’DÄ3è§s8N[cĐ|/ŻéˆQFT§G“°Eść g HÒ ©ŠTĂÓ@|q rŠĄdˆÙŚË•ÿù™đ9œw•Ky{œeJ16dO¶-œo/źà.â.źăF.-zƒ˜ŠbùĆhÀ• endstream endobj 479 0 obj << /Filter[/FlateDecode] /Length 217 >> stream xڕK Â0@!^ à\À4IŁ5 UÁ.]yuéBѝ „ӛô]v1ÇTđł“ŒM™yOëK ‚ =ÁUŐÓÜT—+ a yۅ”„Œ^c őÏ—Ő–E1ó— ó§Đ˜Ïà°?n˜ÍG é^^ă1Ž-¶,Šo3âŒù‹6"ŃÂ{ï5ŽDm‚ö⾞›Ț“œhŸ)êßTțç{ÂçđÜ{-„íäPʔb‰óŹ=Éœü©‚Zšˆș2ژș^Șf“˜-ï±É5 endstream endobj 480 0 obj << /Filter[/FlateDecode] /Length 121 >> stream xÚe‹;Â@ D©}Šč@Œ^oÖY·$¶ˆJ éstÂŻ@™)FOŁWŒeM'C“4łFtEٍZËî8GÜ`Ć8dźÉËûWNWê+…#rGa‡LĄxÜÇ …~żFœùƒuƒiőÎw–ùꎭtxMß# endstream endobj 481 0 obj << /Filter[/FlateDecode] /Length 209 >> stream xÚ]NÁ ‚@–Đ?ˆù‚uŐ]W/Ź Aș Ő±CQçìτ~ÄOđèaqÓ”ÊÀcȚÌŒ7OHNŁe „O}‰~S!q”§RàÙĂrߣB"k‹sAC9Tœź$I‰{Ä@w‹$nșĂÇęy!nČ_ĄŚòžŠkԍŁK­Ź?ÔÓíàŁŹ:{+«BPV °tr€…¶ Ïæ€EKČ `R6N© xęŹșÎÌÌÖÜ…Ńö.ÆŻs6?Ì·Q‚qȘ.3Ù€äđĘRví endstream endobj 482 0 obj << /Filter[/FlateDecode] /Length 165 >> stream xÚ36ŽÔ36W0Đ30P°0Ń36TĐ520Ń37S025Òł4Q041Ń35QH1T(T04łĐ33V0BcKbT-Éč\Nž\úá@M\ú F–\úžŸ %E„©\úNÎ †@>„ëéąđĄæ€LO ‚A`űđÿÁÿÿ€aËÿžÿ<ÿdțÉü±ùQóáσ?ÿ<ÿĂćêÉgț: endstream endobj 483 0 obj << /Filter[/FlateDecode] /Length 124 >> stream xÚ36ŽÔ36W0Đ30P°0Ń36TĐ54Ò30Q021Đł4P041Ń35QH1T(T045Ó3”T0B(EGr.—“'—~ž‚Ą1—Ÿ˜ôôU()*MćÒw pV0ò!\O…$88àÄ; ńĄ‚ËՓ+° _ endstream endobj 484 0 obj << /Filter[/FlateDecode] /Length 260 >> stream xÚ]бN„@àÖlCkÇŒ€ËȚ±°lErj"…‰V>€giáćLì°ĂŽW2Ąà5$Œt„sțU6ƙ̗L11‰Ń2KII„(UrÓĆ6ŐÒZJT"3K&ÖÒ$ŽßĐ iÈԐâ¶ÖJŁÿ<>‹]!ąŠˆn(‹ETÜÒńđú$ąĘĘ%mxÿY‹+:q}Ođ>> stream xÚ36ŽÔ36W0Đ30P°0Ń36TĐ54Ò30Q021Đł4P016Ö33RH1T(T045Ó3”T0BS=3sTÉč\Nž\úá †Æ\ú Ææ\úžŸ %E„©\úNÎ †@>„ëéąđĄâ€DG€x$>Tüÿ âVÏćêÉțj<ą endstream endobj 486 0 obj << /Filter[/FlateDecode] /Length 109 >> stream xڅ‹;Â0©śïë꘍ʐp€”)‚Èę±”*3ŐăĆÙ2„E Æ’ĄQ8źÎ:À"s­x+ž(«Aș5Űc?Œf„'ìHéŠB©Ęđꏄń~‚öȚȝqű]=~æ“p endstream endobj 487 0 obj << /Filter[/FlateDecode] /Length 189 >> stream xÚŐĐœ Â0đ!‹àœ€iҏ4 UÁ‚N>€::(:Wߏä”țMȘKEÜÍ?î™ÈÊ4b%•â0–*ă©„ŠÙšP† kdbxŻùÄIj„6Ź\˜ÌJŁû»Ł(Jl9¶"Xrâ,W|9_"(Ö3Öź”㜁†r7û’†Àƒ0êjw=U Œ„Ș}ëłń™7„źî ‚śȚ‰_֔“?_ìȚùĘÖjÿíOĆą›'–˂ endstream endobj 488 0 obj << /Filter[/FlateDecode] /Length 211 >> stream xÚŐŃ­Â@ đ‚ć ·Ÿ·lw‡ZÂG P< HpìŃö(<rbYé  (ZńËżIkȘ’Ú ’Ja?‘jˆœž/U‚&”Ò&š­–©ÆMŒ{4ƒDš·Z©ăśőNŒœˆVšcÍ0”"rs<N[cä©{F7Aą .eŁ$ÊĄ“Ă™#4șt‚Æ- ąMĐŸ”‡5t f•·ö†ȚËĂʛyùBv ŰúeiY^„ò[áQáGœÿ/Ž à}RLXȚƔĐ endstream endobj 489 0 obj << /Filter[/FlateDecode] /Length 221 >> stream xڕͱjĂ0à3 Zúșˆ,ےbOi ńPhŠ<@Ú±CC2GvâGđè!X9%$„C(•àƒățŸłŠTM‰ZiN«ČÂYQ*mĐžFÍ-șÚ)ëđŁÀo4șQ¶BÍß5”rĆïÆöK,;‘o°2"_Ą­EȚœá~wűùòę žŻcś‚ĄOM’F€Œ9$Dá䙅?N°€–ś à㖎îc#„(„!eúŒ!Éű6˜$’2Svç‰9É;í?àścÌőńe7|ú€ŸÈ„»â”ë3CŒĘŃ endstream endobj 490 0 obj << /Filter[/FlateDecode] /Length 274 >> stream xÚ}ŃAN„0à7aAÒL †wK RˊdÔD&șòê҅FŚt2Ûp–,ÈÔ>: iÄ6mŸ·húśU«Šç .ŠË/dÎĆ%jYqĄPiĆK…/ßńJçŒÊQž©*͕\žx~cû†eOšJ–Ęa©YÖÜăçÇŚ+ËöŚ(]íËæ­”Sê6ă֘„âUôQˆnł !ÚœjíÓR]ˆq‰G}ÆPCìњ}k"ÛytsD‡oÛ8Űfíà9Ž„ŰŽKœ5!±ÓŒ ÜHÿÄHHîu3BL ,Đ"”“ĐùŸ—ÔRÖ_8ÀáHEŰÌh @ìïęì¶a?őx˜ endstream endobj 491 0 obj << /Filter[/FlateDecode] /Length 285 >> stream xÚœ‘=NÄ0…'JÉMŽčŽłY{“jW H€@‚Š%ê 7n’#€LeÇ@.>í7?oȘÒèÒąŃÆ 3zSâÙf«M;[éj‹źrÚ:|(đ]]iW ‘ł+Œvö·âțI•ߥ­T~…¶VysŻ/o*?Țœc!q› dfŠyæ`? ;€t@܃\Ç <ÀȚ?q1śBQy ·)‹2öšIŸyŽ3[àäK€dZ±Ÿæ‡=ĐÂxÍÚżL8$ú'.őBę…ăW+Fažá›aȚáŰ‚=: ~}Pđïx.ÓìX$iSšęï3 û8ŃŒŸˆiȚWâ)ËÈ<Ù·BêČQ·Ÿ„Vœ endstream endobj 492 0 obj << /Filter[/FlateDecode] /Length 215 >> stream xÚ”Ń= pš$,=‚ïRè°™TMì`ą“PGÎöh„Gpì`DZJ#]œ„_ȚÀŚÿ)Ć©LQÆ ”§0ć e(&)ă dFóÎ %ŁJ3S(Asáï۟HQ’x"#ń rIâr ŚËíHâb3nj[– @ížkʉ{‘sŠu…uƒąÎaՁő‰Ź/sBëÛlűVى”Š|xdh­Ç?DöŚęĄÿțÁț_öÿíòèu9čüäç[…Cțź^Â^Ó?Č,Éö>š(K endstream endobj 493 0 obj << /Filter[/FlateDecode] /Length 201 >> stream xÚ}б Â0à@‡@_á^À4iMâ\Ì è䚣ƒą»ĐÁŚRú"úJcMZhjő2|9ž»áWBĐXٌA,)aÈ#ÊF 8ŁR€T#*"Űr84V=9–THcł'‰&á„$á„"Ą^ÀéxȚ‘0YN€Wœkő­A/悍©y`ËËQ8Jăsę&3©#ûƒùz–‚Đoê‘fĄs%kÈûx¶0î™#őڔ^Jčăf)véâȚÈÉL“ŐțyO endstream endobj 494 0 obj << /Filter[/FlateDecode] /Length 179 >> stream xÚ”Đ; Â@Đí[y„č€ûßIêšà‚V@--íÓyM2EȚdȒŰ9S<æ“*͌Á„Lj˜KƄDĆL˜f%\2m@މ2‹ńÄáLsGùŹą| 6„ÜmàvœŸ(Ï· mJ·҇Ć‰ŻŸ˜ő<e Šš#šQHÇĂÿą iU!ÓŒ[>ń–Ż żđÿĄûítćèîф ü endstream endobj 495 0 obj << /Filter[/FlateDecode] /Length 280 >> stream xÚœŃ1NÄ0ЉRŹäfčŽ“]{“ÊÒ) â@I‚-GÉRаv{“(Qzìæ,{Źù”:ÈZŁ’JĄQČ<àMy”ȘÆêx…FS© Ÿű‰§Ș”u‰Šś©PÒèőŚqnDț‚F‹üu-òæżż~ȚE~~șƂëkÙÜ!”)]Ź#òÖtû!Ҟá!%hX>et QÀ—ù˜áöD—ÈűMWűgĘżĄu=Нu᜞i;#]?æ¶ŰQ\ț-„5ÁÍHˆci·HFtÄiŹ'æ§ú8ŐlűŒĐ~˜Čˆè`LgÎkN0dšôcÊ;?æžQĆż9q߈ç?șÛ^Ù endstream endobj 496 0 obj << /Filter[/FlateDecode] /Length 122 >> stream xÚ316Ó30P0@ŠĄ±‚źĄ‘ž‰‚±„螉„‚™č‰ž©‘BŠĄB!PȚPÏŰTšZÁÌÂLÏÔ UGr.—“'—~ž‚±—Ÿ‡‚©9—Ÿ§ŻBIQi*—ŸS€ł‚!ázș(0 ÿ ì†:Fś—«'W ‘”Ź endstream endobj 497 0 obj << /Filter[/FlateDecode] /Length 279 >> stream xÚ}ŃON„0đG0bŰpȚ,íđŚ$Ł&ĂÂDW@]șĐèæf„G`ɂLíĐŻ ù•äőœ~œ”J𚄐’óJšœ/ÔFȂ›"ȘäȘ.DčágĆoÜÈZHĆÒŸUS‰Čú]ńôo»8{Ž5q¶ăÒ~»;țxÿ|‰łíę5+»vË(4 Ń0CdŒŃ©z`4@"`I€9Š{`o€°Ő¶ÚaJĘŁö!°DÀìÿL   û À)Q»âäŒ\/:'ŚźŐ‘ía{ ^j=p;ËœȚà@ëóâÛ.~ű"„M– endstream endobj 498 0 obj << /Filter[/FlateDecode] /Length 163 >> stream xÚĘĐ;Â0P§Bò)æŹ?‰7€ á *” è}4ŽÂRR ŒÓDŃ3ÍÓH»ÍpcÈihÒ%“)16–t¶LeąźÈYì Žp&kźÁ&ÇÏíA¶^Ș ȘFȘ\-•_â|șì„jWS˜Ôső3ˆ”ĂGbĆ?ä.~Òœ ž žŃóÌ<2]ŃŠ~]ń9śrębÒI endstream endobj 499 0 obj << /Filter[/FlateDecode] /Length 271 >> stream xÚ}Ò=jĂ0Àq-:‚ß*K‰ż2’êĄĐN=@Û1CJ;ÛC©ŻeÈEìhÔ`€>”!€R°ŠŸ„Гb#y*@p!`sč†čâ")҂o$äEÊłŒJ8à™”Œ(ïC^æ<ËÿżyÙÓmM“g(SšÜCVĐ€~€śÏ7šlw qÿ·­o„Ć5·"Gísáš¶=1V—ü"ŽŁÇoÒ ;R!;ŸmŒd3ì™”&ö9`ûTùTŰźŸƒ•ő9ađ8GƒíǀÛ»ÌBöÌÄł–SREș ©ʆœÈ8OCvWhĘç‡lÙ5öqÀèL70CeÈiv.šš3”ę%œ«éÓŐEŽS endstream endobj 500 0 obj << /Filter[/FlateDecode] /Length 281 >> stream xÚeŃAN„0€á‡$štáÜ@Ț,… l45&șòê҅F·ÊÂè”8 Gè’Ą>x-8™vóœ4ęmQ–2/PI„p­eČÆó$•jƒE–ÉTĄÎ72Kń)ÁW,’R*Š¶.ŽÌôțÇ±­Dü@‡"Ța–‹žșĆś·goïź0Ą™ÇêBk{ڌÀ¶†/ÒÊ.­ąăVŒŸ'Œß±8Ąph©8ÁPq„'ôTœ0Pq‚„"ƒŠŒf8PšAETdP‘a„uàЀC Ÿ ŒÎę‚SÆÇ GôXŒÆŁ=€ńè> stream xÚ”‘żNĂ0‡/Êä„k7îpœ&q’)R‰ He‑R7úhy”> stream xÚ3·0Őł4R0Đ30P06Ó34VĐ54Ò30Q074Đ33U037Ń35RH1T(„± €ĐÌÂLÏÔ UGr.—“'—~ž‚©—Ÿ‡‚©9—Ÿ§ŻBIQi*—ŸS€ł‚!ázș(0€Àÿÿ`ŠB1B(†úÿ ìÿ?0ۃš ò ê?P ˆbu€™zÀˆB1IĄ˜‚jÔZˆ# N;â Ć ĄäÁŠA`đQWb§ž\=čÏś endstream endobj 503 0 obj << /Filter[/FlateDecode] /Length 255 >> stream xÚ„Đ=nÂ0đy@òBoÀ»@ÛŚ™*Ń"‘ĄR™z`DąU+ukŽĐ#ć(9BFdcüQTÂĐ [Š~OŽíś·V’É9ăNJ‰1ȚÊ ă%êą`’Łș›°BâJà+jQ2ꐻ©J͔űœcčĄÓŠæ/š4ÍçXžoő„ïokšOŸPž:”Ő#‚ÄZÛŁ’¶žê>ÀžŸ<, #ŽË 9G›őŚĄwàéÒÔFK­îSómˆzŒ†1iC~"GìàëìÓ{ Ïò' ț‡ï ő & É̍ÏÙfû€>čÇ`ëa:ëGK::«èâąńQ1 endstream endobj 504 0 obj << /Filter[/FlateDecode] /Length 286 >> stream xÚeϱNĂ0àł2Dò’GÈœŽ“6n:”* ‘‰N<02€`ŽûfŚ7Iß lągŁ!é“.—ŰÿïY-ĐkŃYS-đȘZ»ÆÚ9SVègj‡Ï%ŸamkÓŹŃÊł*­qőß?ž^őźŐĆ#.+]ÜaœÖE{ïŸ/șŰ=\c)óÏŰȚ À_Äù‰ =Ò 4$(:gÜ+ês>+ą bǓ"ß1‹<{ žxœífO›hÍdM}x%Șšlˆäö(tԋ:‹ bČArJ6ŠhXOŃ0lć\•AŁS”!^îÿ9‡JĘ&ęVc/©ĐeJ§Ł]ŸR"rJ)dΆĐ"g/ôm«śß:Üß endstream endobj 505 0 obj << /Filter[/FlateDecode] /Length 180 >> stream xÚćŃ1 Â0àn…,^῀/IÛ$í$T;:č êè èlĆÁky”ĄŁC1Š)z<>~űßôL–Q* HĚdŒ±ŒH$0‰&“A눒{‰Œ€\Ú$€ąß‹Ę‘ćăšŒń”fŒXârŸÏWSH—»XÌđ ül m0j‚m9qÚć­”ÂĘ¶Öœï»śém ;ʶ~”^[ę­uû†aÙŒ`ë/yŸ/L endstream endobj 506 0 obj << /Filter[/FlateDecode] /Length 218 >> stream xÚíѱnÂ0à‹2 yáz/€c“à8P©Ú‰h@0ê‹„oâGȘqü1ȘT†n{î;ßù{_è‰eŁáÜi›óh\hS±Ï­¶–]‰ț˜?,očŹ ]•lp\攳/Ț7jV«lĆΩì…'^eő’ś»ĂZełŚ9[ÔśČ^0„(ÆoÓ@DÂŽčŁ=țăÏ€&B€ô'$ôűÚ8ăèH ć:ź4•n %<ő8%‚K țcŽ(‰ÂTD‹ÒšçZœĘĘëˆ} endstream endobj 507 0 obj << /Filter[/FlateDecode] /Length 292 >> stream xÚuŃ=nƒ0Àq#$+7ï5v>LHi+•ĄR:őmÇ­Ú™Dčč G`d@ŒŸś D –đσ„żí4ÉÌb ÖX ‹•±\ SștÆ9H6+ł^Àłƒ7HíÆX–F’„&qÓOŻz[èű‘öèűÖ©Ž‹{űxÿ|Ńńvw ŽÖĂČž„Tˆ’ïfÄ6ŹQŒšÆœ 'ű„æ/*AIđ5ĄđP„ŠĐ0N‚ń@hÇ)rDŸĐ1A„=Łg„*dpb ‚_ŽjmsO JlJG Jä?râ*”žF”%G䟀ƒŃ7æz5GÌ šE#Ԉ=ńT|È-NĐxŃúçè‚sôüŒ”Ÿ-ôĂ ’k endstream endobj 508 0 obj << /Filter[/FlateDecode] /Length 225 >> stream xÚuÏ1NÄ0ĐQXr“#d.€ăÄvv©- ‘‰­8PR€ NŽ6GńRnÌłH ČôʱfțÈ!lÍöŠŹ±–\gG—MkʧàćjÉ;gș–^z§`ĂÚ+Çû`șÍ߉ç7œïuęDŸŐő=荼ûúüűzŐőțń†©OeK‰‹”xȘÄ Çr*s9CT 1awvŹ~ŒevȘČóMé· QBĆ1»@ÉûCž*Î9ŒæŒkNîțčgAîÏry„âx݁ Ef(ٙž’Oé»^Ÿàč†| endstream endobj 509 0 obj << /Filter[/FlateDecode] /Length 219 >> stream xڔΜ Â0đł‚Bûö^À4©ml?À‚N>€::(șȘÖGń::„Äkuh'‘ƒ\ÈĘęU?æƒ> .! ödÀEˆQ"x QÊG ·)Će€‚J%1WČ>±ÙłqÊü5†æÏ1Š™Ÿ.đt<ï˜?^NPRÿjÓ)Z°ÖűâŁTÿQW2—Ì I6èQƒkáąÁł·Ą†«ÍșĆÿŹSxoUt óȘđƒÛj·:erdoĘw6Ç5”łĘ|4Œv3híćà=ą Ăf)[=š>‘ endstream endobj 510 0 obj << /Filter[/FlateDecode] /Length 209 >> stream xڕÎ1jĂ@Đ1* ÛèțÈjW»«Ć•ÁI *qćV`§L‘ÔVnæŁ ä*UMV–!€4>üŹŃë5Œ6źÒÖáΖÚxűuŽđÎéȘÄŃ⟎:D˜tȚ]Ćÿ‡7”­U±‡ Șx‚‹ȘšŸńùńőȘŠíË=lÊsŹ #mX:ÊXZ":Q3,„Đg#Ą[&űBž8Ï5íJZNüLÓ-Žä‰ó•‘x93P—I~!}3p#ŽùžöeÓҜSëÄê±V»_}‚Ÿ endstream endobj 511 0 obj << /Filter[/FlateDecode] /Length 214 >> stream xÚ”; Â@@G¶Đè\ÀÍn>“Ű(DSZy”ŽPŽ9ZŽ’#€ŽÄYmüuâû``>!/’Ą‡J*…Iía_»RùHʕn€‘ 7śžš8hIÒŻ띈áŹĐ…3Ă N2ÇăáŽNŒŁæü‘&Źùe©|çőÎêOäÏ,ĄÍÌĄÉ„ïœB]@z±ê €„e ÛÔĂü‰Yïđ_Š}ìb6)mcĆn%{6ŰsXÁč Àśjńî2+šÄ4ËÀà> endstream endobj 512 0 obj << /Filter[/FlateDecode] /Length 216 >> stream xÚ]ΜjĂ@ `1·xÍfœ@ÏwŸłăNü@=’)ĐvìĐÒB†BïŃü(ś5+Êś’à$Ue­+4Út”¶l©GßXĘôÎéșÄW‹è}„ë%‰{:ùńòźÖ­*Žè–ȘxșÚ>ăŚçś›*Öû Z©oe»Eà—8BF Ą~f4Ì8œ(áîÔÏčkâœă"fB—qŸ^ ùà/giN SdȚ/ÈJ†>aNć‚!ûĂ*4r,LˆGÈIíZu8P}L endstream endobj 513 0 obj << /Filter[/FlateDecode] /Length 177 >> stream xڜ̜AAà…d`^Àìźęqo#7‰-$T„‚ĐŠG[orC!wlühTšor’sÆ8MFĄ"„ĐxÒ»șGÊą”Ž|}æÉy\iÜąU99ƒ©>ÏÈëśĆr#Ê är‚.2Lqż;Ź…,gCÔ)?b!sՎ\C3ò rŐ:;P0 îÔp|rM'ÁPŒ8Çÿ€oŸüșę/Ä8ˆù ŸÙÎő endstream endobj 514 0 obj << /Filter[/FlateDecode] /Length 280 >> stream xڅĐMJĆ0đ oQÈŠ@è\ÀŽyM?\ž v!èÊíu)šèúćhń&ă șìB:NRtc ?’&óÏ4MçLßbeȘ ëÖŰO¶¶5œĆŠqŠêĐčÆŽȚ[|ÆÆvæŽÆJȚ¶ĘŚÿ)č{Ô»Q—·èj]^J‚.Ç+|}y{Đćîú ­ÌŚéxŽ,ϊÙĂ1àG0«ž`Ê  œeÄ BÁŸÇè@^,țqĘù­$ Ó“™äĆ4dą‡‚éC>ˆ©­ŐśdX=€v‡dȘ%-ZÄÈh7ô)Ș4Vi( <y)…=ˆ~Ż~ ż\WăNO^NL”‹ŠÏé™CNń–’“żàr&}1ê›/ŠKÖ endstream endobj 515 0 obj << /Filter[/FlateDecode] /Length 178 >> stream xÚĆË1 Â@Đ aà\ÀÉn6™lȘ@Tp A+ –ŠÖ±óZ‚ń–‹ë›ˆXŠóáÁÿ0Ź e%I‰šIi쫘d‚ŹŠsdÔ2.n0Í )FÂč!Vï‹”(­ˆæ˜1 Ú î¶û•ˆÊéUèŻj‡èÁ‡ƒ/ȚjĘ/=AàZÁKœïP98ÖvęӞ‡ÂAѰjèÿ(@ûđ©Y1{m‡è endstream endobj 516 0 obj << /Filter[/FlateDecode] /Length 151 >> stream xÚ­Ë1Â0 Đ 6/\á_'NÚŽY Hd@‚‰@Gì•#0f@” .íÀ†ęÛN» †ó,s±l Ű:°©áCÍ^pœaKËĄ€É]‰a_Ž?'j"é=ʐ^Ł €ăŚË­%ĘlÈiìÇžÄ{–Ò4='_5҇y›oșî7•îI„Śż©AŃ*Òî™H‹Ä endstream endobj 517 0 obj << /Filter[/FlateDecode] /Length 191 >> stream xÚÍ˱ Â0ĐCtnÈčp.vb'R‰HP1P"‚ æQÁÄ8  ĄDșW|ę2Oč$$N„C-žĐ8”q­PšŒ—%ȘČà*ĆMŠ”RsĄ0ì±$ÉeńùłȚ±ȘfÉ EÁ’êœ%őOÇó–%ŐbŒiȏXOĐû›óȚśu€/ŻźÛ”{ÿáȚyŰżp ìՂY€žeą'‚Ȍ`o.=gĄï \WÇŠ5[ȚöéÚ( endstream endobj 518 0 obj << /Filter[/FlateDecode] /Length 219 >> stream xÚ”ĐœnÂ@ pG"ʒ”[ü\•LH|HdšÔN}`d”sé›ćQò3œ8Îf@ˆvìò“lÿíÁdH76«Z›g¶ÒŠFG€m…Ԑv„;‹GtuœTÓHmŁÉ>nljŃ©òk§Ê șF•Ę+~žŸöȘ\Œ-ŃÆúVv+ B˜à'Ńÿ§#ŒüȘOyêsÉìđÍöČő#ŠŹÏŰ©`Ç9;ˆgé@.JÒ»&‘c‡TLŰń&Ä_e=ÀłjĘ©ś+zś· endstream endobj 519 0 obj << /Filter[/FlateDecode] /Length 125 >> stream xÚ͋1Â0]ß+öœï|Éa· Hž@‚Š%țNa‰Dą ?`gš)ÖŽ°­!,sVĂJKeMđìÜ;.Š;’w\ dÆKfŚßÇùFC„xBJwè3ĆșÇóńșR#tîoÖ >Ą……ïĐڟŁm„ă2€. endstream endobj 520 0 obj << /Filter[/FlateDecode] /Length 213 >> stream xÚĘÍ1nÂ@Đoč°ŽÍÁ“dœëĘ”ă* ‘ â@I‘(HVì.ŚČ”‹ű.)P†%TĄÈ˜ê}éÏLćŸ”Ń€•Öd e,=š\iG•7Ê{rÖȘ"§Ą7ȘŒW.§Đ&çŒ*Êż띘Ô"[QYˆlN¶YęJïû­È&‹)™Ż±~!ŽžKyŒyDôƒ˜{ŽAG€4hűD#{ôÍ8ރŃC󐌧H2~…”»p#zæ.čU˝Œ_ߍ€x\æ?‰Y-–guäz endstream endobj 521 0 obj << /Filter[/FlateDecode] /Length 172 >> stream xÚĆË1 1…á Bà\ÀIȓMÖjaU0… •PK Eë”óZ‚ń–Á°Q<€<űà/žăŠ<Ł&­‘Ɓ)H[tÆR1DËLźÀ”Á–Ÿ"ăPçY[’óߏŐV6AȘ%ÚJȘ)ȗ*Ìđ°?n€jæ#4čßƘD:Ő D„nö"{‹œ>Ą}ˆs6Š^ÊB?AĄț°ę0ęQ€ÎàW9 rńŽÇž endstream endobj 522 0 obj << /Filter[/FlateDecode] /Length 205 >> stream xڕ= Â@F'€l“#8płÉnț*!*ž… •PK Ekçh9Jސ2EÈșș +x0ó͛4WŒÈPp!Pf<–8.ŠIÉË•”Ț۟X„YŽCłh…2g‘^ăőr;ČšÚÌŃN”kőÍ3CŠ…À’,áwê=SOšóMR˜6 &4ÿfméQ=1œGd #“đ/s\Ÿ»ő}Ęù87ç9XçÙÇżßòő[j¶}Ùà‡Ź endstream endobj 523 0 obj << /Filter[/FlateDecode] /Length 212 >> stream xÚ­Î1 Â0àW Ú軀išŽ©. UÁ‚N@]ŐŁő(Ąc‡ĐűȘƒąnJàƒ?đ'żV=ž(\”}ìJńDcÜ\†)Ć”Äuˆ;Œ”æĄDAGSOőȚ*«-K3,1JX0ĆX± ›áaܰ 0€üˆÙ-Tpź đÉ\Ò)éČÎ' g{i°öâŐæÍ§ŚÆ»üàÇkŚ—żrȚś<¶ùŠȚé–Neh‹, CRŁȘ[ÿÀę*›dlq€ȘȚ: endstream endobj 524 0 obj << /Filter[/FlateDecode] /Length 223 >> stream xÚ­Î1jĂ@Đq\¶ˆ č€W«]i„*%«ŰU»tac·ă…\L艎 R…ĐdŒ˜žLšógŸ7^6Ś‰Ă…5©Î=zc”Í0uN{‹Û˜yÙ°(ëè]Ą]ń+ò±We„âwLsŻ0s*źȚđt<ïT\źŸ1‘y«äž#n!j‰k˜5İüŹ©‡ËWMʄÛ@í”; ftÆ=P=:—4…[Ł«đĂĘMù5ü|”âŰçÚ €§ŽŠ–@àQlàI@RÌü_€{Ők„6ߣčÎ endstream endobj 525 0 obj << /Filter[/FlateDecode] /Length 164 >> stream xÚ”Ë1 Â@ĐÙJŰ&Gp.àî$;›ÊÜBĐÊš„…ą”/¶Gl,q‚(ˆ”Íû|űŸ g> stream xÚUÌ1NĂ@ПXZK[ÄGÈ\€ő:łv”€[D‚ŠeŠDĄ%$ÎćŠsű)SX;LäŠâ3úÿ‡š]íÉ;ï‰W1]U çżr5S`v͂^+Ú/ÙńŠ4M!ÔźYțoŒlí:Úò™žČ惊m7tŰżżÙręxKúăïHșâwÀĜÓߜL'ƒù”dŸEL6ú™(\%!S˜§™ÂG\śÀìÒ”S镮Z9ŁĐx!‚|ÔfŁ/ƜjÀà˜ Šó ș“iȚçÉȚGûôBB]  endstream endobj 527 0 obj << /Filter[/FlateDecode] /Length 174 >> stream xÚ­Ë= Â@à± {‚”s'»;k’«šà‚V@--+ÍŃr”Á2EÈș  y|Ćæ“‘R(IJԆ€ĆĄÒ$ rÆÄSÜ*< K~CRΉóśĆf/ '’5j+’9ŽX$n§ăy'’b9Az_ĘęĘ7_êŐS@Ż š ˆáEnRțÜąꑇqì+È} ß1sbőA†« endstream endobj 528 0 obj << /Filter[/FlateDecode] /Length 172 >> stream xÚĆÎ1 1Đ»i<‚s'É&›ŹŐÂȘ` A+ –ŠÖëŃ֛xË-–Ä,"(ŰËÀƒÿĂX]°Ó$YJҖ•бÊXČÊp6!Ł5یvŠŽ”»‚•%™Î˜œ­û^lXy2Ši‡Â/é|șìQT«)©”_ŃÏ(BŒM űa 1@Ù„Î_ voĶ·~À(Őnéă+ ’wBßšpîqęK‡- endstream endobj 529 0 obj << /Filter[/FlateDecode] /Length 219 >> stream xÚeË1NÄ0ĐżJɍÇqŒPEì‚D $š8PR€ ÎJ\kÉȚ „‹ÈŸÙE͓F3l0ǖ­±–7ö„*gŹç&S9öum‚㻊čńhcÍȚ7&,?nÔȘSć ûF•\/UÙ]òóÓËœ*WWkźżbwÆD:ęw"‘!îĘÁ^Țc‚°•Ś(đ ’GÙąĄNp«SóœC>”?fŽYìáb„q1 €NŽ;x ­fP(ÿëFÏn‹ÙĄûoŐy§ź?1Źô endstream endobj 530 0 obj << /Filter[/FlateDecode] /Length 257 >> stream xÚuÎ=NĂ@ూ°ŽE|ÏXŻíȘ•HžˆJ ÔkÉEźć(qnàr +ĂŹS` 4#}zƓ^•+™oPI„0ÓRŐx“fRi,k-ëužË"ĂŚ?°,•Ź*T|ZodQțmŒŒ‹m#’g,ŽH0/EÒìđëóûM$ÛÇ[L9_bs‡kÛĂș€ÆŠxrŹńźf-ëÌìłŹó_!/ÌÆ#Đ@ÔČöäfûèÔÚăEă ­éˆ†đŰÇ{oŚÇ!ŃžÚQŽ0ˆÆ5ëŰ똅hŒb'ˆ˜„Œ‘={íŻŒ•–ÎÏȂ„ąÎ{œ_Ü7âéŽwÇ endstream endobj 531 0 obj << /Filter[/FlateDecode] /Length 238 >> stream xÚeÍ=NĂ@à±\lŽBò<`œ^Ż7ĄÁR ‘ â@IJjGÊܛì\Nay›Ą4ŸögȚŒ`ƒÙXŽÆZtȚŰ[Œ)±ëLéĐW• ßKüÂÚˏC™FïkÖÿoŸzÛêâ}­‹'ŹÖșhwžÿ>|èbû|„ÜŻídV—ŽĐŠ&hƜ95Ä}6tąŠLÓł8€'‘’TA-fâč(áÙărîłE”Œ€B2Ï_ÁœœÙOwÒÉC3;iæ(aⳄ‰OÒLŹ€™&ٕś—êÇVżüÙá›2 endstream endobj 532 0 obj << /Filter[/FlateDecode] /Length 261 >> stream xÚeĐ1JÄ@àYRŠ™#俀“ÉL2Fƒ» ŠŽòjiĄ(Ű%žĆ^+Ë^drƒ”S„üțÁÈÚ|đàœæYee©@I„@çRÁ‰Vč<”PX+3 č1ÒjxÊàŠ\K„ê`M)My4y|á뚧<œÂđŽŸ…ś·gžźï6Qț‰ő0&&Æț;2Dçƒ=ÙàȚO䁏pë‘Ü‘ ÆÛ)&ČSBÆAŐŻ‘'‡È7äj ęj@’9rdęì%9±ÍlD"‹mĆb—,șjqhțˆ‹n¶';ܓms Y”ĘÍÆÁ > stream xÚUαjĂ0€á3 Züčš,Eȃ§ŠŽ…z(ŽS ÉŰĄ„cèàŚșń#hô r=;R >8ďź¶F·-m șF[‡7v­GïkĘlĐ;§›5î,~ 7­źčŻÿŠ·w”íTőŠÎ«êĘFUĘ~}~ïU”}ŸC+óeìî‘@Îe‚@‡Iàtä˜Ń‰Çœ~˜ ž/XXŃp†[’ÀfXÒLr Ą/H5łJ U‚tAŸ“j‚žq RĆ@9Ą—4ôćÂŒȚêĄS/żŚbtY endstream endobj 534 0 obj << /Filter[/FlateDecode] /Length 209 >> stream xÚ”± Â0†S ìÔ{ÓŽMÒtqš vtòÔŃAŃM€ÖGé#ttœ1Dq•ƒn8îÿ~™ ŠpÆ9Íb ăD0žƒŒ3–§ RÍR »Ž TÎ2 ܎R úób{ EIŁ €9 %Ê%œO—=ŠŐb»wk94 6$0Xß čzÆxHÌĂÇêv`=ilB‡ÆbèP°íżQYôŸ@,Èÿđë„C—ʆìđÎÜZ™Đ97gé|;sŚÁ« :/éú ï>Šœ endstream endobj 535 0 obj << /Filter[/FlateDecode] /Length 147 >> stream xÚĘÏ1 Â@Đ”Sü 8;ëL’MÜBĐÊš„ ą}źæQŒ„ĘșÁ*A><ű SüȘ1Ž5„E5`f,‹Ł ÖÈqž@ۆ­…”Ô•°éűcą.‘ßA•ü •‘OkÜźś#ùn3G(ę[Ó9?sŸóc`RxôçÆœ‡Ăë(»œû–‰¶.LÁą endstream endobj 536 0 obj << /Filter[/FlateDecode] /Length 256 >> stream xÚmÏÁJÄ0àYz°äÒko0M·IO…UÁ=ùî=( {kÀËŁôrŒP:NX |0™ùÇôZÚ•T ;%·-ž7[©4e€œÀź”Č”žođ”6ČëQń댒șęęăńIìFQ?`ۋúőx‹Ż/oQïî.±áúTŽWHaC‘ q(bÈbš<Äy pôŽ€uÓ„«V(Ą"ÈĄűƒ?žŠńóA }ù7%Ńz?&"QÜ0!cæ"Q1~`çŁr͘„H ^B—Đ<1ž§Ò;QNg‰‚Öœ|IÄDHÌ ŸàŹ|Ì?ˆëQ܈ŸW endstream endobj 537 0 obj << /Filter[/FlateDecode] /Length 261 >> stream xÚ}ĐÍJÄ0đÙ-ìBÍtçLÛíWz±°*ۃ '@=zPôșÛGëŁôzÌĄÌ8Ăą ˆ~2™Ì?US:_cæČ KïrûÒe-VyăÚë»ÂăsŽoXÖ­k*ÌdŐőȚ•țś§WsèMúˆEkÒ[Ź*“öwűńțùbÒĂęæČ?oûkä˜xK<@D Ć.p ;‚ËĐ1$óV‰âiőZ’-^,AÂ, Xúb+aŽ„Q^›ĄSNŠę>%-fœÆÚ€‡XÙăú˜:aÜ ƒ`û7ë3–‡”Ô ›AÂÄăIÇíHI D É%ŸŒä7ÌMoŸÌeŹË endstream endobj 538 0 obj << /Filter[/FlateDecode] /Length 210 >> stream xڕÏ; Â@àtÂ69‚s7›ì&nȘ€p A+ –ŠÖ )r-ƋÄ€LłżM‚X8ÌÀ 3áXq‘àBŒž/iä\( ƒ˜Çš"©čÔŽóéH*–\+mFĄàJö'¶61Ìېò™· P1Ï,é|șì™7YM©íšOifÔ4M™ÜZ‹Ž9ŒĂtŹuÇ –°€9|À'Ì k­a5„‰”ŒZ lÎáŠ0ƒź”Z+X&đj-pŐ >a Đùę/țŽÂ†/ÙܰőÁőÆ endstream endobj 539 0 obj << /Filter[/FlateDecode] /Length 251 >> stream xڅϱJÄ@à  Û€œîæÜì]țčêàT0…pV>€ZZ( v‰ovŸÉ‚/pv[„Œ3'œˆ…,|°ìÌ?łŸm,tÖ9 Î.k<]6Ö­Đ;oi…Ą&[Ț-đ›ÆÛĐą“ÂÒ6ô»ăöÁl:SĘ`ƚêœ7Uw…ÏO/śŠÚlÏp!śïkwŽÌL±çD1ç"ŒIBМ(„2Wz!cĄ$à?F-ŽÚ;@žb–$Ż%~=É ž€èS˜IĂp 8?De·†čÊ?ú @1HüìMăßyÚńš#€})‹$…&ę–tö‰ś9'sљë/ONž endstream endobj 540 0 obj << /x28 478 0 R /x29 479 0 R /x5f 480 0 R /x2a 481 0 R /x2c 482 0 R /x2e 483 0 R /x2f 484 0 R /x3a 485 0 R /x2d 486 0 R /x1c 487 0 R /x1b 488 0 R /x3f 489 0 R /x41 490 0 R /x43 491 0 R /x44 492 0 R /x45 493 0 R /x46 494 0 R /x47 495 0 R /x49 496 0 R /x4b 497 0 R /x4c 498 0 R /x4d 499 0 R /x4e 500 0 R /x4f 501 0 R /x50 502 0 R /x52 503 0 R /x53 504 0 R /x54 505 0 R /x55 506 0 R /x56 507 0 R /x61 508 0 R /x62 509 0 R /x63 510 0 R /x64 511 0 R /x65 512 0 R /x66 513 0 R /x67 514 0 R /x68 515 0 R /x69 516 0 R /x6a 517 0 R /x6b 518 0 R /x6c 519 0 R /x6d 520 0 R /x6e 521 0 R /x6f 522 0 R /x70 523 0 R /x71 524 0 R /x72 525 0 R /x73 526 0 R /x74 527 0 R /x75 528 0 R /x76 529 0 R /x77 530 0 R /x78 531 0 R /x79 532 0 R /x7a 533 0 R /x30 534 0 R /x31 535 0 R /x32 536 0 R /x33 537 0 R /x34 538 0 R /x35 539 0 R >> endobj 13 0 obj << /Type/Font /Name/F6 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[574.86 574.86 574.86 574.86 574.86 574.86 869.23 574.86 574.86 574.86 319.37 510.99 319.37 319.37 510.99 510.99 411.01 411.01 411.01 638.73 638.73 574.86 1149.72 0 447.11 319.37 351.3 670.67 638.73 638.73 958.1 958.1 574.86 349.91 574.86 958.1 574.86 958.1 894.23 319.37 447.11 447.11 574.86 894.23 319.37 383.24 319.37 574.86 574.86 574.86 574.86 574.86 574.86 574.86 574.86 574.86 574.86 574.86 319.37 319.37 894.23 894.23 894.23 542.92 894.23 869.23 817.86 830.35 881.73 755.37 723.43 903.95 899.78 436 594.3 901.17 691.5 1091.4 899.78 863.68 785.92 863.68 862.29 638.73 799.8 884.51 869.23 1188.6 869.23 869.23 702.61 319.37 574.86 319.37 702.61 894.23 319.37 558.89 638.73 510.99 638.73 526.95 351.3 574.86 638.73 319.37 351.3 606.8 319.37 958.1 638.73 574.86 638.73 606.8 473.5 453.5 447.11 638.73 606.8 830.35 606.8 606.8 510.99 574.86 319.37 574.86 702.61 191.62 869.23 869.23 830.35 830.35 881.73 755.37 755.37 903.95 691.5 691.5 691.5 899.78 899.78 913.67 863.68 862.29 862.29 638.73 638.73 638.73 799.8 799.8 884.51 884.51 869.23 702.61 702.61 702.61 1010.86 436 638.73 529.04 558.89 558.89 510.99 510.99 810.22 526.95 526.95 574.86 319.37 501.96 386.43 638.73 638.73 638.73 574.86 473.5 473.5 453.5 453.5 453.5 447.11 447.11 638.73 638.73 606.8 510.99 510.99 510.99 670.67 349.91 542.92 734.54 869.23 869.23 869.23 869.23 869.23 869.23 1041.41 830.35 755.37 755.37 755.37 755.37 436 436 436 436 881.73 899.78 863.68 863.68 863.68 863.68 863.68 1169.16 894.23 884.51 884.51 884.51 884.51 869.23 722.05 1277.47 558.89 558.89 558.89 558.89 558.89 558.89 830.35 510.99 526.95 526.95 526.95 526.95 319.37 319.37 319.37 383.24 574.86 638.73 574.86 574.86 574.86 574.86 574.86 894.23 574.86 638.73 638.73 638.73 638.73 606.8 638.73 597.08] /FontBBox[-127.7 -548.4 1404.7 1014.2] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 540 0 R >> endobj 541 0 obj << /Filter[/FlateDecode] /Length 190 >> stream xÚ]Ë= Â@`ƒ…a[;çn6kv7©À-­<€ZZ( všÊky”!ć’qÄI#óï=Ł3™;PR)Đ*“Κ°rl!3Nșln„±°OáÚhYd è\NQÿœìŽbêEȝŠd ֈįàrŸD2]πVÿ«~ˆlbl:_oł@Ź&9«ÈœH`€e+ Űe é±7éł@†Ź&V‘;{d e+ÂĐm=1ˆ…›!šč endstream endobj 542 0 obj << /Filter[/FlateDecode] /Length 174 >> stream xÚUË1 Â0à‚ƒà;ÁKb’Š„Ș`A' ŽŠÎ*œXĆĄŚđ=@đ™èú~>űÿᙱÆÌ‚@!@jFC*pŹÀƒYFZÌì$A„•ᣍE+ÿ?¶V”Œo@ Æ 2ÆË%œO—=ăĆj Òïß,g@Ô8ą§WuôŒ~ô†‘ F_u’ nIŒĐ©8jŻŃ+ šöwŻêhȱyÉÖ.ö‹Ü endstream endobj 543 0 obj << /Filter[/FlateDecode] /Length 123 >> stream xÚ352Ńł0W0Đ30P020Ń37SĐ54Ò30Q066Ś32S042Đ31UH1T(T046Ò35PA(UKr.—“'—~ž‚Ą!—Ÿ˜ôôU()*MćÒw pVń!\O… 04!4(Hxű€ËՓ+ĐĘ!— endstream endobj 544 0 obj << /Filter[/FlateDecode] /Length 157 >> stream xڍË1 Â@Đ”K8pvgłÙ€3D·ŽòjiĄh€›Ł˜xÇIc%óàó?Lî•:rœ TDœ±'0xŠŒăÈxAϑJFŚ_È2Šțçćp†:Ę#—`ژE°iƒ·ëę¶Ț.ûț­i‰Ú‰¶ąŠz3ȘąчšțëŐÈs.2•v`Fm?6Ò©À*ÁîŚ7c endstream endobj 545 0 obj << /Filter[/FlateDecode] /Length 118 >> stream xÚ]‹;Â@ D“Ö§˜xíÍ~œ6€Ä‘’Š%ô=FtÌL1Żx9&¶ ah1.Ԅ‹!ćÊU“đ(ž)žˆ6ČÄ[„ăđg\45 w(œ‘)ŽŻí}§0-šóÛŸźïŸóôțéÔhĘ˜łś endstream endobj 546 0 obj << /Filter[/FlateDecode] /Length 216 >> stream xÚUËœj„@àY,„iÌx_`ÇùSŚj“@,I•6°›2Ć.Iœă›é›ű–âä΄äÂÇ9n.5;”ÀçPp&ì…d\ƒÎKV („fȂ‹€+šȘdșŽWȂ)œę8ÓșĄÙ(EłÈ%͚Wűčę~ŃŹ~{ęż6O`­í b„80-[æ ÓÊűNŽ.Đ9úiW"O‹ÄÈČ2')Ę0=‘±ĂĘAn‹qމ‹'ÌÉâ‰Í”"& 2BvˆO~ŁÏ }ÿą”± endstream endobj 547 0 obj << /Filter[/FlateDecode] /Length 238 >> stream xÚU1nĂ0 Ex0 ĆG/PYRćԙ$-Ú)H:vhŃÎvnæŁè3fÈŰZx")}~Čr^ŚO`Ž1°6Ú=ƒuÚxš<]ŽjN» NŸÀŚVŚűŹ­Śnó_qü”ÛF–đF–{šŹ,›WűùțęćömœOió ˜„ŒŁ9Gc…c†„» CŽęŒbÁeÆ/jARH ©S a ô3ȘÆ{Ž Äž,·ˆj=œ“KșAęéžș#[0Θ &—cËă”ËxOFÂbȰăŐ/IPŒ–j4€|iäûÆ\Č endstream endobj 548 0 obj << /Filter[/FlateDecode] /Length 245 >> stream xÚuÏœJÄ@đWD¶Ik·ón>6_BàT0… • –Š‚]Nl|ŹÁ‰,đfÏÔɍq»òÔtPŰ«Ì*ÏȘËG`}ÙëÛoąôÓQ endstream endobj 549 0 obj << /Filter[/FlateDecode] /Length 188 >> stream xÚUË1 Â0àˆ‚Ć#ôż€i’&i;Ș‚<€::(:[oæQz„Ž‚”UÿFyđÁ{đŽT,‰3Î!5,20’qZ+Æc0\2©a/àJÇ,ÀÛĄ˜Lÿ»#Í- ·%4\‚4Ž+žœŻæëtęSíššQSB~xoM=q-Ry2€ôܐ‡§AŠž{Ï gˆ<=cÄy&Hí Ê“!%R’uŽt_2G–n^Ș.Ő5 endstream endobj 550 0 obj << /Filter[/FlateDecode] /Length 195 >> stream xÚUΜ Â0đ”…,>‚śæË€ÖIš ftrÔŃAŃÙúf>JĄc‡bLÓŠA~ÜwđWB’lŒ0)#b .“ 3NČv'ˆPpæp)8QöÖVÊ%óÿÓçÓLŠPSœ…ÇęyÁ4ß-Ą»QŻÀÔ()MŐśÛ™ÈXbÏ7xšÀÈSƞ*°đ”—ç0žbà=u4`“ŐÈa“U°ÉzÚdŽcê@Ÿ+x­ńțF”Éă endstream endobj 551 0 obj << /Filter[/FlateDecode] /Length 276 >> stream xÚU˱NĂ0à€‚Œ„Ÿč>Ž%iY©P‰ H0±R#ÖÒ*_ŰŹfń=d_Cž°žŸś·gÏn/Áfë+ 5$= ć“òHú$=»oœ2>­J2#úî=)IÈłâé’ôŰiĒÔۀU’Zè«ê” ”±ÊmgÛîĘŽÛ”ő§AÚ¶MïWçș †Ö0@jœżQçPžő–!R°s"ÒXÿL„Ò^’vVhąƒ:"ćüD]TI'á*"ŻB/D/:Òől^ł»:€âO endstream endobj 552 0 obj << /Filter[/FlateDecode] /Length 252 >> stream xÚUÎÍJÄ0đ,)TBĄ/PŰyÓ4ęڅÂÂȘ°=zòÔŁEo+ŸŰ>JĄÇBÆI?$đ#ó‡aț„.äź%•‚JIĂ5%jeVË}N™–ș„— ȚĄ(kYg èUș’yńăùM[‘>AŸé J-Òö>?Ÿ^Ez|žŒæylo ÛXë<'ĄŒEèű  ÇhCÇâ dhf\€f»2nmŽp0 1&8††8w8|3‹ƒ?yfÜzâćŚ;Êz$~.l.đÇĘJHĘ&šY˜X*ÙŰF3&¶WIÏ șʚÇșž#uAü”⼏€ŒȘ` endstream endobj 553 0 obj << /Filter[/FlateDecode] /Length 256 >> stream xÚ]ÏMN„P đǐ É[È €đĂÇÀ 3j2,LtćÔ„ źyłòZï(İdAú·0ń3M~MÛ4M‹MnȘ-%&IšÊM–Ò™t’šŠBҖÊ47›šRzŠŒŹÍ¶ DąÌ*“U7îŸôźŐńe”ŽśTd:nŻéőćíQÇ»› J„>–í%cđôžŹ:”Rà™Éï• Ç†hĄ_èx ‡Š5,ŠÀ §űˆq ÍL ôȘc *bŒ*dL*`9î ƒ'đ ì7î?ĂB'ÓŸĂáźƒÿÏLÛf ÙFƒžˆ­RÍü^Ç+ćß­/ô!X_”úöÉHÒè endstream endobj 554 0 obj << /Filter[/FlateDecode] /Length 204 >> stream xÚ]Í»‚0àIW7Î XÚÚr™HPLtòÔŃAŁ3đf> ÀÈ@Àr)MÌIŸäÿsNŽä‚„PB)0!ˆ°fœP2ą„3đ)'\Á„ÄWËj|&țNźœ€Ű»À&ÀȚ$Ă^z„śësÇ^rÚBŸÇ˜î A9”Ș7oœ*.&ÊŰȘVefOT­Ę„]kwuŚ.4a©© źŠ2ĚҐiŸ†N“Ï3֌­igrśšoš'QȚ§űüÜeȘ endstream endobj 555 0 obj << /Filter[/FlateDecode] /Length 241 >> stream xÚUĐ=NÄ0`G)VrłGđ\Çq~Ű­,- ‘ *” š3虏â#žt2LbŽYdé“üF¶žŠł­>\ƒŃÆ@ĘXĘžâÈĄ·œnZèŐ¶ƒŚ> =6úЂáó7ęÿäć]žY=C[Ëê:+«áŸ>żßduzŒN‡|n! çĄPˆKs>—”ö8ï(©Íšđ'»§è6ƒĂ”UÆM?bÌ:òމ„!;ÒtaAèłDć&wA\ˆ[œć.XŹ–Ä-ΊŹZŒY·Čăą_EZ~(Űi^ÄTČ^ìXȚËÛ`“ –°ònOżÔ}Ù endstream endobj 556 0 obj << /Filter[/FlateDecode] /Length 223 >> stream xÚ]αJ1à )Òì#쌀Ù$›ÜYyp*ž… •í‚Z܉‚{•Ż•G™GH™bÙ8«œˆ |óÿĆÀçőù6­3Ú<łNÁórèŐaO§lx|Śé•ûwòžSÛ^”ŰŐȚ`·Rm‹Ż/oÏȘĘȚ]ąćțSû+,S]š$ùI%‚€2.3 ’4ÉTQź˜TgŠah“ką&~S˜±ä†ŽH ‰YÒæ] Ì;Èś $”3#&昁†1A".ìe‘ù«jźI]śêț š|Ą endstream endobj 557 0 obj << /Filter[/FlateDecode] /Length 246 >> stream xÚ]αJÄ@àY¶l“GÈŒ€›d͞găÁ©` Á«lj)DQ°3ył<Ê<–[„Œł'Q‘oűáï»=ĂÊVּȍǓÚÙȘAßÈrž©œuk|ÁÆŐÖKYfS7֝ÿ;yx6û֔śxêMyƒŸ6e{‹oŻïOŠÜß]bÊß±œBæ:æű—9Át€[™~Ą•ᇑx΅ ńš„E‘ŠYM1 …< …@»ÄgÌi:9+Ą •Đv+tŃ [Đ<}Ź œ=êȘY#P7˜ș ˆœąšą|•-9™ëÖŸš”u endstream endobj 558 0 obj << /Filter[/FlateDecode] /Length 215 >> stream xÚmÌ=j1àY6 ÂčA2ˆV?+ŻĘŹÁIÀ*I•Ű)]8ŰmŹÜLG19Á–[œ܅0|Ć{đÆÛVÍ;ÖJk6Î*ŻùÁX„[öÚ«ù‚[k”ïxkxÏźsÊ-X—kS3ûgČÙÉUÍ;;#›5»™l >ČYœ>riĂ5†'bƅz 4Eą‘š肾LÇÄáTˆó"ČHëˆTGąiqW|U™è6O€}_ęD „(-:Ń@$Æò§Œ{Ä*Ëç ß~_'eȚ endstream endobj 559 0 obj << /Filter[/FlateDecode] /Length 262 >> stream xÚ]ÏMJ1àj2Đ„ŸÀÀÔLÿfșa`T°‚ź<€ștĄèN˜đ`/’#d™E‘2m€àƒ·xPO7zŹTUáșRM‹§M3šAŁź{uÖbŚÔJśűXă vșW}UŒ”źTŚț«<<Ëí(Ë{lY^Łîd9ȚàÛëû“,··XÇüÇKdö1[ńÉcÿ03S"(äˆ3Ȉ§„IXń…ˆïr"ÉgèHA_iÛžĘŠÒ†ˆÙŰŃïÆŒi‚œÉÀŠÉAìÈ«QȚ}ȚcÁÿ endstream endobj 560 0 obj << /Filter[/FlateDecode] /Length 198 >> stream xÚ]Ë=ŽÂ0à•‚䂜Á2À±g“˜4 ń#‘ *Ànčh‘šçf> 5%rÈÄz_óôôRJäÄ ’JĄÎI±&©LČ\š3E’RüŃxD2†Ő&Ӊ€üírűóBÄ{€oŻ1Ő".6ű:ÿŠxŸ] śP‹%Zđe`Ąl\Ë3Û©;œÎóÁ€=ƒOöFìÌŰ5š˜«nźČźa¶Ûô떏êgd/CĂ+|Ęaúï{^Ź ±{C7yd endstream endobj 561 0 obj << /Filter[/FlateDecode] /Length 234 >> stream xÚUÍÁJÄ0àd‚lȚÀ0MÓŽu/.Ź ö ž§}őèAŃk7ûfńMzòÜceâD‘ïç?üLíŒčhÁkĄuÆ”p^:c=Ԟw„©[x,á|ł6m –ÎW•iÜÿĆĂłÚvȘŰC”VĆ-T*ș;x{}RĆöț Jê?”»ԓÆIG8œ1ŒŒ±>F>rèQgVDŰ =ψpÈ$‚„Ű'ž"ț"…Ìń™8Î2‰ÏL˜5~#œ–lÒł\L«Yg–‹‘8!N—ăffČłÌćxHʟRú@uөʶđ{1 endstream endobj 562 0 obj << /Filter[/FlateDecode] /Length 204 >> stream xÚUÍ=ÊÂ@àY¶lă2pł»ÙÄt‚?` áłČÔÒBŃVĘÊkć(9–’1«ä“0đÀËŒĂdÆÊb„J*……•©ÆĄ6RYÌò\jƒÖh™p§ńˆ¶ĐČPÆŠ©ÌMÿb{“R$kŽJ$ Ls‘”K<Ÿ.{‘LțŠšÛüć ›ˆàöd/ˆ=xˆjŰŻ€UžČÊ3rÎsș;ß]=hÚő‡˜X€ójLj!ȘnwêáìȚŃüˆ:^?}âP ÄŒ«7yd’O endstream endobj 563 0 obj << /Filter[/FlateDecode] /Length 228 >> stream xÚUŽ1nÂ@EÇraiÁsŹŚȚĆÆ!R\ %H()@Ąfsn‚Ä%(?ł")ĐHovŽóÿüIìŽegăź±Ÿá—Ș¶.p茝j«+;iù»â-ûź”Ąc§Œ·MęŹűژyoÊ{oÊwö)û%ÿìökSÎ?^čÒù1ö š\)œ) D!"ĐA©ŸÇ,"ÿÇ-Ç Š‹èdL"Hw ąšE«<šf êŒ1Ç.ÀŻÈŽz§ˆTĄ{ n™ĐaÈESąyfr& s„$Ț( æ­7Ÿwn{ endstream endobj 564 0 obj << /Filter[/FlateDecode] /Length 228 >> stream xÚUÌÁJÄ0à,-Ą°/ t^À4IÓMaU°AOûêуąàaĄí›ćQú9æ0tœVDdàƒțùëTëA+­Á[e=\«ŽƒÆîŐŸgj<<xŚxć h>WŚjgÿ<œÊC'«#Ô­Źî ȚÉȘ»‡śÏYźÁpț‰Ę ĐHTÌąŸ‹$źæ<.LądÚrá«$3$Ž#“o"“EîeÓJ91…ZI ”ÎyțxI›…ŒŠ•Ó/™č2.dHÉ â i[€(J€$z$^@yÛÉÇoÁT‡ endstream endobj 565 0 obj << /Filter[/FlateDecode] /Length 240 >> stream xÚ]ÏÍj„0`ƃKÁyÆhtڜ„m őPhOûm=ìÒBoŽo–GÉ#xô N'îZŰ2đÁd˜ŸÔe„š=h„5ŠT”†;~ÒêÒ*ÛÀźšTiᜀ»W•ͱ32Íż–·OqèD~cDț5Û=ĂŚùûC䇗{(8ż€Ę-9ÉD)Ò%Hs`”1ÓHŸwHŽ˜!_‰–4 ™90ecûGÏű+=oBwË@4ÜL.,+éÆ,7ŠlƒżpĆśŒ#°2Bǧąû‘„>Ê-áő„SL„\$xę]°ŸÎ endstream endobj 566 0 obj << /Filter[/FlateDecode] /Length 192 >> stream xÚ]Ëœ Â0`GHn[Çv*"~$R AĆ@I‚g3’(SD†‹ôôééIwč6bZ€R‚ÊŽÈ%L”Ҁ1č°Xe„žÁIÁ2• ŽCʶ"3/Ç _T<=€¶<Ę@źyZmá~{œyșŰ-A…MłZbW"¶ŒŒ‚ŠçW⛕Ű>pÌ# Ÿ];Xś’Ț€ŒŁ!éąiŁ1yEsÒDOâŁ>Ž8–xöĂ~ęĘ|]ńęlŁ\ endstream endobj 567 0 obj << /Filter[/FlateDecode] /Length 280 >> stream xÚUÎÍJÄ@ đ -†B_`Ąy§ßÛV{ôäšGŠȚ:‹_«ÒG˜cĄ1ŁîA~ É?MY›źĆÜä9¶„)[ŒNȚcSöŠïp[ÔŠìń©ÀWŹ›ÖŽæò¶UgȘîÿÄă‹> :{ÀȘÓÙ 6•Ά[|ûxÖÙáî ©Ëá ™—ˆ˜g%X8ò °cŰđą\Ì.Ą˜ç”Bžö«0źÀ–űäQž@XˆÎp${˜Y&ț ÏŸqaò۝ č’)8Æű[’)ń#IŸIú‚MŰsèBRȞa‘ÈĐÉgèRŠxN%hV4Á8 ÉŽłpŽP€Vè“mD_ìRÒŚƒŸÿóS endstream endobj 568 0 obj << /Filter[/FlateDecode] /Length 259 >> stream xÚ]ÏÁJĂ@à 9öÒŸAæÜlČILO…Ș`‚ž|ő(TŃsӓŻđEòsÌĄôwF‹Yű`śŸ­ËÊ·ç|\„ÖWŸéQXr]•>”Ü•/—üXđ W1úŠä «‰­íż+ÏnĘčüžcăòkźŁË»~{}rùúö‚ Ęÿl»Kd.@Ÿ D‚=ŃB0ÎÆ€!“†íŽ@‰°Ó‰‘țòa %G䛠ŒÆ°QzCÛcJDëő5Ą™‘™ L6Ë^țĐbà”OcgYÉ)z7±.©}+Ƙ)ĂJÏh+œ+=%4i™h9$:Ż»êÜĘ_Ë« endstream endobj 569 0 obj << /Filter[/FlateDecode] /Length 258 >> stream xÚ]ÏAJÄ0à”. Ùôö]À4mÚI baT° AWÀ™„ ą;ÁÌ æJ=Je„ń%’*!ŒyïO[7LIàŒsŰpV žŹkĆT M+™Ź`S5Źî`WÁ;ˆNČŠŽG5‚Uíż'/Żt;Đò„ ć=HNËá>?ŸöŽÜ>Ț@…ő_9܂sÎjÄdZ3ô í9œHęq# endstream endobj 570 0 obj << /Filter[/FlateDecode] /Length 236 >> stream xÚ]Î=JĆ@à #Ûä™ žÙìۍZž Šž•PK EëěƛÌRn±dœ}A0f˜?oŸșDŁÁÆí<^HÉ\ŁwV‹­±Úz|iđmŽ—f‰Ö¶zçNFžßÔŸWőîŒȘïŃ[UśűùńőȘêęáÉŚŽżEž xúòÄL<&Ÿ·d‰|Ăr€ŰÏráŠ]ąą°J y,(”‹P%:!œó ˑbć'1ČÌÇòٗń\%:’«‰i€)[2Š1Hu„‚i‚’‰ cš!=™Wwœzü“aÁô endstream endobj 571 0 obj << /Filter[/FlateDecode] /Length 234 >> stream xÚmÍMJÄ@à Y!GH]ÀNw~ƞQÁ,„™•P—.wéÁ‹ć(ńYfRV%Œ#Ăúk^CȚ+łB»+4ÚŽyŠKƒ—üd־ȅÎțźg‹oX8«AùVčÓč;ùćéUmj•>baTzeźÒú?Ț?_TșÙȚ ćŒÄú)ègșêF€Šüp Œ zű‚°FˆșHˆ'ˆÛŠ|Âô‰oš«<1QÛyú&â°0…BČ313Ì$L?S‘” I“@Œ°?ÔÉÀÂčâ“ö#ǝcs”±ș«ŐîżZÚ endstream endobj 572 0 obj << /Filter[/FlateDecode] /Length 264 >> stream xÚ]ÎMJÄ@à Yz“čAêv:żfVQÁ,]yu)šèNHæf}”Ą–œyÖšŽ4|tĘUŻ)k۝łłÎqá:[|Š-·ćŠ.­+č-j[nù±àWź«Ê¶%;=mŐÙȘûśćáÙì“ßs՚üš›ÊäĂ żż}<™|w{Á…Ö?ćpÉ@Hđ‘B$X‰ÂIüs&Ê^»˜°öâÖasDœöŸ™_/úCÇûÏX0S*êuQ„ß›§L…TÖdMdIŚXB†X€Ç^æQń8Č?%†Ÿû‹Đ<‰DXR%d2aîe}/Ÿ§Q<éȚ™4 F](ÓˆčÌĘâxÄD endstream endobj 573 0 obj << /Filter[/FlateDecode] /Length 259 >> stream xÚ]Î=NÄ0à‰RDr“#d.€ăü-I”Ń) â@I‚:Ț›ÄE|„”)ą<&ĄZdé“ßűGŻ)kÛ^łłÎqQ:[7|„#ŚqSv¶kùPÔ¶ìű”àź]g›ŠźCŐÚȘęśäćƜ“?sU›üž›ÊäĂ}~ż™üôxÅæż8Ü22|"X), &"AH€‡dĄ‡Ò)"e7eÙI•y'»`Ú9"\"œâ{=őœȚ#e!YÒYIÉJŽŁ5ˆÎ‰·B©VĂșŁM±ì€ÊŒ1eòłqF8 AFĆCŃ=­$šcę($)ƒxÒB#$D€h{ˆčÌÓ/JĐž2 endstream endobj 574 0 obj << /x7c 541 0 R /x2b 542 0 R /x2e 543 0 R /x3a 544 0 R /x2d 545 0 R /x41 546 0 R /x42 547 0 R /x43 548 0 R /x49 549 0 R /x4c 550 0 R /x4d 551 0 R /x52 552 0 R /x53 553 0 R /x54 554 0 R /x55 555 0 R /x61 556 0 R /x64 557 0 R /x65 558 0 R /x67 559 0 R /x6c 560 0 R /x6e 561 0 R /x72 562 0 R /x73 563 0 R /x76 564 0 R /x30 565 0 R /x31 566 0 R /x32 567 0 R /x33 568 0 R /x34 569 0 R /x35 570 0 R /x37 571 0 R /x38 572 0 R /x39 573 0 R >> endobj 14 0 obj << /Type/Font /Name/F7 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 0 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87] /FontBBox[-52.5 -430.2 577.5 923.1] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 574 0 R >> endobj 575 0 obj << /Filter[/FlateDecode] /Length 199 >> stream xÚuŽ=Â0 F‹*eáű€qJšű‘è€FÌq1ś&Ą#C…q&$”·XŽżśč5Z0Ú@gŽÁÓiC‹ÚyyŻ] {„XÚ y~lufovG5-TČ«d ÎȘ€XÁć|=šdșžÊÆb\ç\EüŒ˜rŽˆ;ôŽ©ŽéŐŁȘOՄž·→éȚòhé¶ÄÛđ3\•üÍ ™. ‰N€ąn H )#•ê\- ”ù适u endstream endobj 576 0 obj << /Filter[/FlateDecode] /Length 193 >> stream xÚuŽ;Â0 †AČp|’8!M;ńè€Fìć\ÉGé; ‚Ûˆ ù[,?ŸßY”h@K­!ŚÒN`ŒÚI›ƒMQZ©śÒY8 œÁx”AsùÌÈÜüœìObV ”̄Z3B•kž^nGĄf›9 ś±-đ”êȘQAuA͈š!œôN(0śêš™iË3Òkiț§q3^Őß?ńgÒ*XÄ:–ČšT]ŽÄÁÄČÛCA„: endstream endobj 577 0 obj << /Filter[/FlateDecode] /Length 192 >> stream xÚU± Â@ EQDș†đÎùr‰”Š(€D $š()@P‡Ńʁâ>­ÍD†J€7"]G™JŸ†„Ÿł|^ČŒW,Fx˜ ś‰p·æe4·#0©núSz•YÍĐ,ÍÔlí1íÔîĄČÛÆŸtđ endstream endobj 578 0 obj << /Filter[/FlateDecode] /Length 115 >> stream xڕ‹;‚@E©ß*î|ó>ĂŽ€‰S˜hćÀÒB;`áéè8·:č9Ń•Ő ,Sá”qR‰ì.ÿ«N‰ŁcT|…ę Y—ălûdxS[(> stream xÚUN1Â0 LĆP) OÀ/H‭ԩR‰ H0ń`dÁLÀ—üžÀŰŐÄĐY'ùlߝˀ=8ăTÎxÁD(J4U eáóp@8CšŃžT%ą©ńO°?é6j»_i»‚PhŚpœÜŽÚ¶›9`â?đ`Š> stream xÚƎ1 B1DÓ {Šč€›Ęù›Ž_SZy”ŽPŽśšȚDŠpfš7009)«AXZ3{ÂT%sȘ˜ć"Ü9'gXXÒíĆžÚïfą±QÜőžâ Ù(¶5ź—Û‘âž™C;ż±-paò|ü1áëL?FËFÛ€Śkđ endstream endobj 581 0 obj << /Filter[/FlateDecode] /Length 129 >> stream xÚƎ; AD;îSÔìéža~éî N häÔĐ@Yó9ž  "ˆ°^%/(šLÌCEAĆ +Ó(Ą"X+H9K 8źđ%‰fèB.^Șÿ™/<4vXe·AôìÚóí~f7ìFŰâom:>éDÏÇ?ۉŸÎ€Śś/šÜo˜ endstream endobj 582 0 obj << /Filter[/FlateDecode] /Length 116 >> stream xÚ]‹; AD'îSÔ¶§«ç“ÉȘà‚F@ 7śèŽ˜m=(xU•S3TSwLtÓ\ ”6Lɔčx"5jź°A3Myőž>dî/đ*ń€QꈜkčKœO[pű_ûŸ6a•ß&û.ç/bȚ% endstream endobj 583 0 obj << /Filter[/FlateDecode] /Length 129 >> stream xÚ}Œ1Â@ ©ęŠę@|çs|QÚ@$ź@‚Š%(ôțZ^‡h!fȘŐjŚTX"Çé;E#Æ1Ck“ZdéXGÁąÆ&ˆŐʉ5Mg …=z kމBÙ`șȚN†íRó+–fw_üÁ0ûęÍχgKcĄĘh<4ò endstream endobj 584 0 obj << /Filter[/FlateDecode] /Length 141 >> stream xÚ]‹1Â0èîûÎwNì@@ÂTŽ‘€’œÀ—ò”{%%–ÒĄ©vg76Ê ,] § Â1Ąi‡4·Ćš"§șź„NYôÿsŸQŸÉŸ J~W-ùŒÇóńș’ïkÔ6O1o`6ĆMŒÎÜ·òĄ Îf6··Ń6Óńné*˜ endstream endobj 585 0 obj << /Filter[/FlateDecode] /Length 117 >> stream xÚ356Ô34R0Đ30P0Ž4Ő37VĐ54Ő30S0Ê™(虘*€**›ê™*!”‰Ș%9—ËɓK?\Á’KßDxú*”•Šré;8+ùź§‹ÂÁ††8hh8ŰÀćêÉęx> endstream endobj 586 0 obj << /Filter[/FlateDecode] /Length 126 >> stream xÚm‹± 1D­ś+æn“Ífs\{z` A+?@--”łß_»/Ӏ`ĄÎÀÀcfL…%!rŒÁžWtb Ž5)#'aëqÜ jl‚Űœ”pŃŻËéJc„pÄ@a‹ÔČî0ß ă~ iüÆșÁâÜțőJ‡8Ù3u endstream endobj 587 0 obj << /Filter[/FlateDecode] /Length 126 >> stream xÚm‹1Â0C30ęSű?ßi”k[$2 ÁÄ€‘;G A,Ֆ‡gÙ©Ł2ÀÔ ) æ€9 öÔȚ-k 8WÄDÍŹ9DÓáïqŒÈXÄZ+~ÓZńe‹ûíq?î&°ńˌ§s+śŁŚZ_KYÚÊșÈț țè3Ÿ endstream endobj 588 0 obj << /Filter[/FlateDecode] /Length 117 >> stream xÚU‹;Â@ DSPùsŻí]çÓæ#±T(S$ =Gg„(Eæ5ó€ÊjA'Žvź ɔœ%áNđV,ˆek Rhœ­=^3ő™Âfźp ù†mę~(ôśZ|Ś<âW]Ș#„ӔéńP‰m endstream endobj 589 0 obj << /Filter[/FlateDecode] /Length 168 >> stream xÚ356Ô34R0Đ30P06Đ34TĐ54Ő30S0±0Ôł0P030Ò32UH1T(T015Ô3łT0B3Cs=cCTÉč\Nž\úá@Q.}C.}O_…’ąÒT.}§gÂőtQűüǟÿÍj°bæ5ÿÙüá$âÿă?ű‡ŒMïùæ? üCžùÏ{vŹűO}ÿ.WOź@Û>o” endstream endobj 590 0 obj << /Filter[/FlateDecode] /Length 241 >> stream xÚ]ËAJÄ0`† č@ĄÿL“v:mĄPìb@W@]șPt'4sł^$GÈ2‹ŸÆüd'ońŒŠÖRW €RP+©5ÜhŐÈș‡C§e§à۶ȩáUĂ-=𘶫d_ę»ŒŒóÓÄËç8óòšŠ—ÓŸ>żßxyzŒ{ȘÓž°vÆ|}n âòLž!vÂț$ ÁL˜è‚Š \F†vfèV†aĘa@"O ŽŒ‰%3†…„ÄD—hƒC`>ÌíWf·ëŽ\ ń»xR$źž7^íÖÎÄíĘìspàśúƒ'™Œ endstream endobj 591 0 obj << /Filter[/FlateDecode] /Length 184 >> stream xÚeËA ‚@ÆńYÂlæŸ 4Îst2+ÈEP«P-[” \x-Ł‹x„Yș2S2DżĆÿƒçKäè‚àB€ÆèsĄÀ NžD8 œÁó‘«)ˆú”tčTęę‰F1uvőJx.uâ5\/·#uąÍ°î6ăT:4Âî{±ĄÔúË2SYéÀ›={ ˍ±‹!’€êD‡zŠïeçÁòa9ùù6]ÆtûU9 endstream endobj 592 0 obj << /Filter[/FlateDecode] /Length 180 >> stream xÚmޱ 1 †+.ÒĆŐ1/`ÛŽœȚčž Ț è䚣ƒąàÖWő2v8Ԕ;á!!ÿŸżpšĐ‚Qƀ3 æX(À‡ JÁXe 8!\Á» ‚ðTÿNjŹ©`RoÀŁÔÍî·ÇYêz·„è!(~ÈûŸ'ÍűŠêłpŠq’ëFîż%hD endstream endobj 593 0 obj << /Filter[/FlateDecode] /Length 213 >> stream xڍŽ=NĂ@…,ai|ƒÌXïŹŚȚt‘Hž@‚Š%R%5DčŰĆG˜Ò…ća–Ÿ‚ŸâIïœymC–<:ë†ÖRÄ«ÆY" ]gcÀŽąm_·<Ù6ąÓëBŽÁÿM<ż™uoê'ôKSßahLĘßă~wx5őúáIő·ìoPxQIșs˜`RÆ"_2 «ń‹ô>A’ >d†ă'‘ȘáLù~œšăŁfsGîKíV™±ÒżŐX Nwlt œ±€’u'›ÛȚ<~,à endstream endobj 594 0 obj << /Filter[/FlateDecode] /Length 182 >> stream xڍÎ1 1ЈVAđs“Ìn’EŰjU0… •PK E;!{4âRZ5C,ÖNÂ#L1óż)Q`J(h„Č0ɟ¶VTŹ*Da`pmPŰ)šô,VąÄߍʑ7ŽË-”ŠË%häÒ­àrŸžlÖ3 9n-EÆúI/a±eìüœț‘<ÇYÿ"ƒàß],iÿÔÙŁ;t/~QFš)—ò©Gîӏԏ/ß|`uŰ endstream endobj 595 0 obj << /Filter[/FlateDecode] /Length 155 >> stream xÚ356Ô34R0Đ30P06Đ34TĐ54Ő30S0±4Ół0S030Ò32UH1T(T013Ó37Q0B3Cs=cCTÉč\Nž\úá Æ†\ú &@ÒÓWĄ€š4•Kß)ÀYćp=]ű€˜ šÿ śń?>ÄÍÌÀŒ‰‘ćÁêÿ#ăG@|fÀL\źž\FàrV endstream endobj 596 0 obj << /Filter[/FlateDecode] /Length 154 >> stream xÚ356Ô34R0Đ30P04Ő30SЅP&†z fFzFŠ )† … &ffzæ& @hfhźglˆȘ#9—ËɓK?\ÁېKßCÁHzú*”•Šré;8+€űź§‹Bò~Űÿ?€?âüˆ 0&F–«ÿO70țÿÇÀ€À >—«'W æő€– endstream endobj 597 0 obj << /Filter[/FlateDecode] /Length 211 >> stream xÚuÎÍjĂ0 à@Sö‚éæX‰“Žè6˜…íÔh{ÜaŁ='„/–Gń#äèCšf'PŰaˆ!~Šœ$eš€R˜+I„OsÒ+’+…%U2'<~Ł.H–kT>J]IęŰ‰éÎwEúŽ:©Ùâéç|éæăÉŚsi^‘ísÍĘ8Š`ô\ô0> stream xÚ356Ô34R0Đ30P04Ő30SЅP&–fzf fFzFŠ )† … &†z hfhźglˆȘ#9—ËɓK?\ÁۈKßCÁĐKßÓWĄ€š4•Kß)ÀYćp=]ű?02°?`€aÿCę?~’0&&Ő (Ææ.WOź@“żj· endstream endobj 599 0 obj << /Filter[/FlateDecode] /Length 121 >> stream xÚ”» Â@D‰·Ši€œęÜ-rj‰  ą $™ 蛏Edçž7É FS\Y Â"h„=c­…%=8!ÆVpQÜá9ŰÈĐ »Nç”•Ò æ”vÈJ©î1<žWJíĄĂè­=VÓ|^ïć:ûąm„ă1|g: endstream endobj 600 0 obj << /Filter[/FlateDecode] /Length 201 >> stream xÚUÍ; Â@€áa s!s7;yADSZy”ŽPŽÉĆâMr„)S,źŸâße˜(@‰>(©J"Â#©b”‰‚Xùҏà„p…0BÏAńÄ8“țo/"˅wàWám Dáć[žßgáe»%tĘgŸ‚ÒmlË©ș&CO2&Sł«ŰHӇi‡čšÚT±ŠèŐŹä¶űÏfc§çòNʊȘgȚƒfĐĘą™–éI鶖ćĐOŚb‹ężƒ\ endstream endobj 601 0 obj << /Filter[/FlateDecode] /Length 135 >> stream xÚ356Ô34R0Đ30P06Đ34TĐ54Ő30S0±0Ôł0P030Ò32UH1T(T015Ô3łT0B3Cs=cCTÉč\Nž\úá@Q.}C.}O_…’ąÒT.}§gÂőtQh`üÿ‡Aüö4Ç žp*òYž\=číè…9 endstream endobj 602 0 obj << /Filter[/FlateDecode] /Length 168 >> stream xÚ356Ô34R0Đ30P04Ő30SЅP&–fzf fFzFŠ )† … &†z hfhźglˆȘ#9—ËɓK?\ÁۈKßCÁĐKßÓWĄ€š4•Kß)ÀYćp=]êÿ1€±ę8~(ÿŁŽù?Ž?ìÿÁ0xüqûĂÇ!űńńö‡Û!űc?ÿGà?öüÿ?AŒìærőä ’‘ endstream endobj 603 0 obj << /Filter[/FlateDecode] /Length 192 >> stream xÚ356Ô34R0Đ30P06Đ34TĐ54Ő30S0±0Ôł0P030Ò32UH1T(T015Ô3łT0B3Cs=cCTÉč\Nž\úá@Q.}C.}O_…’ąÒT.}§gÂőtQh°ÀÂ`€A‚ű°|èÿcÆí@|ŠCńc ~ƁűțQƒÀlűË@đæâ(nâ#`Ü À†ÿò?ÔpčzrH6z© endstream endobj 604 0 obj << /Filter[/FlateDecode] /Length 173 >> stream xÚ”Ž± Â0E(Ü°Â-ÀÙg;ŽÒE$\ AĆ@I‚š ó(!%’É„`tzĆ/țę—YB2 Qkđ™ŐH.#ôxÊŃÎ` BçAwç]ŽÎü6ö'Y©v`ŒT+pVȘ°†ëćv”ȘÚ́șüao1­ÇFŒbą§ŸŚć#5ć3”=ăԊIzęțÍ [ŒËûƒ {±{ÊeÛ-;o endstream endobj 605 0 obj << /Filter[/FlateDecode] /Length 175 >> stream xڍ̱A1àŠt±Ï 8íi{{Y/$LفŰúȘĄc蜆Ä Í7üÍțÊ’ZƒŐH#ȘP{pȚcíÀkƒŠ‚Áœőè-h~žjŽô}±=È&H”3‘jŽ€ K8Ÿ.{©šŐJ~Ć0!YˆƕSŒ SÌęïŹ-DŠÊûî•>ߕ{Ța9ńnâ}îțMôXśg9ręCéyu endstream endobj 606 0 obj << /Filter[/FlateDecode] /Length 201 >> stream xÚ}Î= 1à‹…4Áč€ÙLČŽü·Žòj)š(ŰíÍŁx„--ʉXX(<’7LéH“EŁA*”ńŰsFaI€„ȚXmKܰxĘśhâxg”óߍőN*•ŻĐ9•ϰ°*Żæx:ž·*-ÆH1żc5A†a`€Lh ˜…Šæ:rFáȚ<~‘^ӿԐnÚòŠ-Ž>±fášÖ Í.Â>àNƒńä;$Č0wž-!dŹŠ•ZŸ IŠć endstream endobj 607 0 obj << /Filter[/FlateDecode] /Length 225 >> stream xÚUÎ1NĂ@@ѱ\Dڂä‘2`=cŻœtH!Hž@‚А”‘ J:Šp‚\iâ#LéÂÊd0 hőŠŃÎ~m]±çÉaš=GŒ­È3ch6}ĆžeüÀPČŻ#’&DÊÿ/ȚśnĘșâ Ë;WăáóžsĆúćÙæß±Ę ÂW7’êM2§{ى2í)W™Ì&Ă$ڱËUćۜLš«ô "0—rč@&ÚC§ ”†­,T3ł]Ìț°Ț$łË,`•ìFÀZ7Ö<§•žÇÖœ^Üsrz endstream endobj 608 0 obj << /Filter[/FlateDecode] /Length 145 >> stream xÚ356Ô34R0Đ30P06Đ34TĐ54Ő30S0±0Ôł0P030Ò32UH1T(T015Ô3łT0B3Cs=cCTÉč\Nž\úá@Q.}C.}O_…’ąÒT.}§gÂőtQh```a@ì?ìĐqÿû#ÿŰÿĄ9f`ü󏁎A|.WOź@TÓ. endstream endobj 609 0 obj << /Filter[/FlateDecode] /Length 164 >> stream xÚ356Ô34R0Đ30P04Ő30SĐ56Đ34T0±4Ół0S030Ò32UH1T(T0±0Ôł0PA3c#=c3TÉč\Nž\úá ÆF\ú &@ÒÓWĄ€š4•Kß)ÀYÁȇp=]Ű0 ăőÿűiŽíÿ€ńû?ò?@ÿƒ> stream xÚU˱ Â0€á: YòœđšKÚP§BU0ƒ “ ŽŠÎ |źÒ©o±ƒ[‹Ôp|?Ü%А$(AĄaąA<՘jĐBąL`Op‚8%LtŁ•D„ęĘ‘ć†E[P’EKˆÛmVp9_,ÊŚ3 ¶û4sžs; ž ~ș¶·7ï4Ù+üçW‹ÛŹżžqí> stream xÚ}Ë=‚0p6“.=Bÿ°ôœH@ƒLtòèè Ń™Ás)‰çNБPA41/ż—Œáù’S.€Qƀû”)˜JF9oŠh @1A…;GđN}”TȘń#= H#w R w ^ŚzçÓeÜhïögê98aă|+Ź-z7kŻ„”ù?Š&Űü«Ìßê2'ƒôAêű>–T€IȘp0y† 6ƒ›Ź%u†m^aÜŁ endstream endobj 612 0 obj << /Filter[/FlateDecode] /Length 206 >> stream xÚUÌMŠÂ@àà ĐGèș€źü©«@FÁ,„™•P—.Ę ¶æb=7ÉČtQ;tD†â[Œ*ê„1*Œ@+­!Ö Ƙ*A2E5ՐéHE)l€šČh7NTŒÿ?6{^”<\»-— ËœŽç‹ŸoèȏćŒ0#—ÒÉ?"q٧šèÉŸšeŒÚsÔÇJŻÎœæÚësĘß­đ?óŹòąëwdMNȚ\ÇH; „ ȚșÌ%ÿ}3;w- endstream endobj 613 0 obj << /Filter[/FlateDecode] /Length 184 >> stream xڕË; Â@€á„mr„ÌÜGkŹQÁ-­<€ZZ(ZGÉĆÌMö)·łŹ"–2|3üĆä© "N9‘S.aâN6“ސ yB“ΐ‚ìH1„©űę۟H„ÛAš¶‚LŠÖpœÜŽ„U›9Űv©p:ß ”śa۔}lÆwÙGŠąźÂźÆPŚhÄÆj[끚§ œĆˆęŸt€űôżÆ&KE¶/œ§ˆÒ endstream endobj 614 0 obj << /Filter[/FlateDecode] /Length 212 >> stream xÚ]Î1NĂ@ЍRDÚ&ŸçYïnvŚé"% á Ș(‘’êŰòĆÜć>”.ą>ąæëżűÒÄ”3Γ5ÖRˆÆŐŽrŃŰD!%SJÖéŐщ‚w&Öd‘äjłv/ïzŚèê@~Ł« NWÍ#}œ?ßt”{ÚÓwÿ©Í J­Rê·^Šą†Ń±—áx•–E:˜±ä9,Xn0-Ąda·pa –fÂy áLK(„à2«q —Źh%«țț)ô}ٟżCçtź endstream endobj 615 0 obj << /Filter[/FlateDecode] /Length 194 >> stream xÚUË=N1à·IÉ G`.€Śłk{“6 HPć@™"ˆŽ“=šâ#lIy3 4hôIóó&ôlč#g#,ôÀÁșHÙn˜|Ç6 ôÁt$Ł<9-ßGûÿïłMŠĘSÏŠ}ŠncÚôBß_§OÓn_w€Ûô;ŠGșà\'ÜŚ‚UÍXȘŠæ3T–2™o&™GȐI5ȚM2êmùguSŽ/ÒÌYFŃ °È4ŹQ›ș0OÉŒ]3čU= endstream endobj 616 0 obj << /Filter[/FlateDecode] /Length 189 >> stream xÚ}ŒM Â0„S…Čho ïŠIÒźZš f!èÊšKŠîD{4Ôć[”Ô€u#ˆ<Ÿ7 ÌL &"àŒs)ăfƒ$č`9É#„pp†DJ–%ÀÍI‘±X|7ö'Z)î 4\AbŸZĂőr;Ò°ÚÌÁúÁȘg§Iù țŁk̉F 21űè4.z­‹áŽ(»úĂë”ÉÔ}.°˜ží;ßïÙ] äD·wOÓ„ąÛ7&ìyƒ endstream endobj 617 0 obj << /Filter[/FlateDecode] /Length 184 >> stream xÚm? Â0Ć#„,=‚ßÌż&© UÁ ‚N@ęzłx“Ąc!†Șƒ ßđxŒśL!™T ˜PŠf0•† ÚHf+ĐJ2SÂAŠÒ2-A$éÂ2[ü6ö'Ú8Êw  ć+Pćn ŚËíHył™ƒLțmĘąÏ1’ Ÿ„`Ÿèa‚èïˆŰÆ8}ÿá›”±OŽ` ÄŚ„‡œžŒÒ~–~Ò—Ż‘.ĘŸBśY« endstream endobj 618 0 obj << /Filter[/FlateDecode] /Length 192 >> stream xÚuŒ= Â@…R({;çnv’Í&6SDSZy”ŽPŹ4Ț,GÉRZ„Ź›hP†oàń~ą$š€R*I„Š€2š§F& dážđ„ÚkTî Ć2€~cwi&ü-†$ü%jśł^ÎŚƒđÓő [ę‘Ù­…»ƒûŒț“ßžŚ0ä €Ë–1pń(8·%?mŐáčlËà^çWßléz…ëç\Œ»=p»àöĄl^ƒXdbóÿsw endstream endobj 619 0 obj << /Filter[/FlateDecode] /Length 189 >> stream xÚmŒ= Â@…GR¶ńŸ žÙMČŹÀ‚V¶”ŽPŽ6Țl2G°L!Ž+ÚŸá+>˜ś\a”ÍaŽ1(¶†ÖiăŁXíG(s«]…Ć„ńÚĆßxeá”/~ۃšÔ*Û ŻT¶@>RYœÄùtÙ«lȚÂFÿh=ƒ„1 „ü „;"Ÿ5Üo›pečă&ĘJ"‚T„“/7yą•…kGaЧŒž‡ŰlžÔci°šŚjęNìNŰ endstream endobj 620 0 obj << /Filter[/FlateDecode] /Length 161 >> stream xÚ„Í1Â0 @QłæŸź4é^@"LŹHÀȂœGkoÒ#tì„I„@ÀŠŹ7|ɖœ‹LÌè˜Dp*ž8`釁-YÁ3–ȧĘ4A*rò}±?™:šb‹¶2ĆK1E\áőr;šą^Ï0ś3ăU›^ï€:èôIËÉڍšöŸ€àKîߝŽ0É?Țr›E4›Ҟ‰" endstream endobj 621 0 obj << /Filter[/FlateDecode] /Length 238 >> stream xÚ]ޱNĂ@ †ĘVJ„š7ż—»\r„H$n@*Œ XK ÆÁ“\æŽ*ԁÊúdÙțÿ_źŐ¶DŁAgŽ”xTÖ”n> stream xڕË1 Â0àW„,!ï&yiăbĄ*˜AĐÉšŁƒąłWó(=‚ă„híÒ.‚ü|üüĂïrRdŃ(cœ2ÇmSŻ‚GoŹČ„g,©`°‰§‰Ê©ÿ۟D…Țan…^aABÇ5^/·ŁĐŐfŽÍng\ ÜS‚ȏ™ Hüy2@ù•=%Yòè%Yv”ÿƒŹÈ5ˆeÛ7mÈs endstream endobj 623 0 obj << /Filter[/FlateDecode] /Length 141 >> stream xڝ‹11 /ąó+ö8qœ]{€D $šxPR‚>_ŁâY!Pœè۝bweGÇÎĄwŹs‰ìBN=’,X'ÁMÂᚓzÖ4ę8^hÈdđìÁ“Í[Üźś3Ùa·„Žțźy…úŹŐLiËÊŹvæCi7?)éŸj™Ö™ö/­Śvb endstream endobj 624 0 obj << /Filter[/FlateDecode] /Length 193 >> stream xÚ}ËK Â0àh…lz„ÎL“>bi *ۅ + .](șnœ™Ț€GèÒĆ@œPđ±‘ácű3ČD ƒR‚Ê„Ô0êW:Ń"Ś e,â ö NæJäÜh5‰úę±;òČâŃ’˜GKHȘ\ÎŚÊő \îc5‡Š¶–™†à_ÌĂâ‹ËæNï7âY,|‹ÓÀbZ”Æ"ĐfAoH7Ÿ:uĂő[§FÓ4O‚a3ècí›Ë|QńÍ ővF endstream endobj 625 0 obj << /Filter[/FlateDecode] /Length 129 >> stream xÚƋ± B1CC{Sx.wś“Kÿ‰HP1PR€ Ïšlùą&À–‹gÙyPVƒ°\Ű sÍ,ŽäÎ%őÎŰ2ŽŠ ’8çŸív-<èïăpбRÜĂ Ć5’RŹÜźśĆq»ÀÄoŹKŽÙóÂ'­çŸn! |ibZUÚœ5™N endstream endobj 626 0 obj << /Filter[/FlateDecode] /Length 169 >> stream xÚ356Ô34R0Đ30PĐ54Ő30ƒQŠFfz–æ &F†zŠæ )† … Š&Fz@Ć@hblŠgfŒŠ%9—ËɓK?\ÁیKßCÁȒKßÓWĄ€š4•Kß)ÀYÁȇp=]üăÿÀĐ`ÁüA€H00~h’>È1>űđÁŽHŰ3űđĄžFüç§Ń Ăx@€‡á‚‹qčzrDm… endstream endobj 627 0 obj << /Filter[/FlateDecode] /Length 156 >> stream xÚ356Ô34R0Đ30P04Ő30SЅP&–fz@ÊÈPÏÔ\!ĆPĄPÁÄÂPÏÂ@MŒÍô̌Qu$çr9yré‡+qé{(Yré{ú*”•Šré;8+ùź§‹Có †ÿ ő ö üƒńƒüöò?űÿÈÿGÂö€cÆ Œđ.WOź@ÒxLĄ endstream endobj 628 0 obj << /Filter[/FlateDecode] /Length 185 >> stream xÚm= 1„łX,€ńú.`țÙÊeU0… •PK Ek/öŒIްćbÜŹ• )†7óŐ’I‚ N0„`$-Œ•Ì`”dv ; GЅdƁhÏhǜțmlŽò”o@9Ê  ÊęΧ˞òj5ÙúŻő3ˆńM†ű"}lHŽ5éa˜dˆŚ>cÀ{ ć#Öe/Ö$Í_„_RÊ„|‹ìúauŒÄMüŽ“öèÜÓőctZ› endstream endobj 629 0 obj << /Filter[/FlateDecode] /Length 193 >> stream xڍ1 Â@E' l‘Ü@çnv“Í&‚(D·ŽòjiĄh+9šGJč…lœš•ZÈđțđÿŸ,•\&(ž(3.4%űP *$/h%’g9î$QiÍs…‚F넫ü#Č=°Ò°xƒ©dń•b±YâùtÙłž\M‘źæ%Í áÚuP€„1ôˆĐz”oƒ»o#ڱęæĆ€©ȚÜ~P‘§zúąÊ”yŻmÛGœ–>YΎGțżï67lę{”}A endstream endobj 630 0 obj << /Filter[/FlateDecode] /Length 212 >> stream xڕÍÁjÂ@à Â"ô„™pł»ÙlÌEA[h‚ž|őèAћàűfyÁcÒí$éĄz(ł|0 ÿüYj”udŽ1”m-œ7ș0”č ‹œŒł:Ëiké@ŸzÈȄàŽÏE6{5+UČŠ4UÉyŻ’rA§ăy§’ÙrNVön-ß(V“)G ?áč@~4Ü_čšȚ‘9>o5rŻă‰Üÿ‹^GęhłćTuä MGÛÖö~Â9VĄÉț~"êœT«/TNĘ endstream endobj 631 0 obj << /Filter[/FlateDecode] /Length 163 >> stream xڍ‹= 1…gم@/`1p’Ùüž[ «‚)­<€ZZ(Z›Â{€…QD;y|<ŸÏ&źQ“Öh41ăˆi¶aj4ښɍqÇxDë˜|‹:ÇOȚü>¶Ù©6y•ju+UXâùtÙKŐ­ŠÈÙ_fś!ˆX€ æJYLn ź}‚Ô§âMù…űeP|xșœč~l§W‰ endstream endobj 632 0 obj << /Filter[/FlateDecode] /Length 179 >> stream xÚU‹=‚@„ßf ’m8‚ï.û¶š‰[˜hćĐÒBŁ5xź„7!ń”V<”1ó53“ÏY-”A%•ÂÜI3Ă©vRe˜ÚLfSŁ„Ëń ńŒ6ÓÒ:T!żśÏ(Oąđ"ÙŁIEČF3‰ßàőr;Š€Ű.P‡ț­~‰”=°XęˆqșGôpz2ą:ŠȘ&/ˆšæ4Œ[CmDiÙű8@7P‰•»7˟> endstream endobj 633 0 obj << /Filter[/FlateDecode] /Length 169 >> stream xÚ}Ë1 Â@Đ )Ûx…耓ÙĘìÆ:*˜BĐÊVPK EûÜÀ+y”=BÊâžA•á}űđÇYMÚ 3Z&­qš±ÇÂzò]aˆ n5°`O.nă9W>?6{UŐ*_Ą)U>CłžăéxȚ©ŒZŒQÇțŹőć"AČ߀5àKßÿíż»Łd7xK»šIJœ”\“ m€5­ŐòSëp# endstream endobj 634 0 obj << /Filter[/FlateDecode] /Length 147 >> stream xÚ356Ô34R0Đ30P04Ő30SЅP&–fz@ÊÈPÏÔ\!ĆPĄPÁÄÂPÏÂ@MŒÍô̌Qu$çr9yré‡+qé{(Yré{ú*”•Šré;8+ùź§‹C}ƒ=ƒ}ƒ<2țaÿ‡Büˆ?Èÿ? ÿƒáÿgàaűÀށËՓ+€6P endstream endobj 635 0 obj << /Filter[/FlateDecode] /Length 181 >> stream xÚ]Ë1 Â0àn…,9Bÿ ˜äoÒڂPš vtòêè èVèĐĄŚȘô"ő;chQßđŒH"Ă€`ˆ0ȉT‚, BdŃNWPČ8aŁdÌbùû8^H^~°+áS‹-Üo3áùn h»«Ć <Úzÿ†j\ŒŐXNČĄÔÙ 'AŻßÁËĄOmhçű”6MăÔŸ6uZ«Ÿ†L›±Òd]ędéc~ endstream endobj 636 0 obj << /Filter[/FlateDecode] /Length 174 >> stream xÚ356Ô34R0Đ30P04Ő30SЅP&–fz@ÊÈPÏÔ\!ĆPĄPÁÄÂPÏÂ@MŒÍô̌Qu$çr9yré‡+qé{(Yré{ú*”•Šré;8+ùź§‹BÿFö 0 â?űÿŸęĂÿÿüžț?ÿ9ù|\À&ÿ§ Íț+Ž@°âûŠGêÿ1€`æ` 2™ËՓ+ș‘Vi endstream endobj 637 0 obj << /Filter[/FlateDecode] /Length 194 >> stream xÚUŒÁ ‚@†=Âì#8/ĐșŁ«éI°‚<uêȘc‡ąÎ |-˱7èŰap[1|0ßÏüű(Đ)€_ D˜a d*BIPŠ`G„ šEƒ4ŁüP„țăpfiÆÜœI™»/fn¶Ûő~bnș]4[BÁ‹©e[“‘ȚÉyPÇÒvIșČI—œtín ïГțäĂȚgOCcnȘŠ4/ĘÎy%-Œ6 k€w¶ÊŰî „W› endstream endobj 638 0 obj << /Filter[/FlateDecode] /Length 211 >> stream xÚ]ËAjÂP`Á…đ69B柌‰/‰‚ˆšEĄ]y€¶K-ș"žpé•"^$čAÜœĆàt^ÓÒ"ĂÇÏÿĂ$ÔƒŃÆÀÄhDÇÖè™;E=•ˆQ'Œ!|€MP§30rik›ĘœŒźUQȘh%łŠÁZ•O°ùÜŸ«šx^Jïkč„APîčÊÍĆÎćnGyçŃ-ôș-ńŻŃ…űűărüӞD@|]Űs^țOŐë<țvn˜ö­83†’Țˆ©˜š©«˜ÔC©^Ÿ —" endstream endobj 639 0 obj << /Filter[/FlateDecode] /Length 190 >> stream xÚ]L; Â@|baŰÆÖ.ïnvóY”ü€)­<€ZZ( vÒxŹt^#GHù q jĄÎ0ĂL1“DVې6†#Ł­ćźMŽq;§{1ÇĄŐI7–śGN»ˆMÍOüYŹwj”Ș`Ćá@ł—§s>N[Œc¶uŚt‘—Ń·rT^ŽČ“Łèߐ<š‚{K mAć ÊĄ ž2G"-\«6šôAĆ”]@ÿšÿ=5MŐò }PR endstream endobj 640 0 obj << /Filter[/FlateDecode] /Length 201 >> stream xڍŽ= Â@…,„mÌ œ žÙI6»v‚?` A+ –‚ŠÖQ,Œ–Ț$G˜2EÈž«ÚÉđSŒśŸ,E‰ (©èLą…^Ș$"hc€Ő`ĐÊa° Ì,(wF[©“ßÄj+†čˆ—ôE<Š8ŸÁńpڈx8șÿęæcàČ >w© ÚT-Ș‚ȘNH4žSY”»’iwgRź^\čŽ>Üž‰Úì’òœp}:}ÿkËáwęŸśđ>ȚËûyO1ÉĆâ p‚ endstream endobj 641 0 obj << /Filter[/FlateDecode] /Length 153 >> stream xڄ˱ Â0P+î<Ć-ÀÙçs„ á *J ô‘<ðș„ Fÿ5_úżfBŠ0hr‚Ő ƒĐ™àHpN‚±0D8"Ëïăpvmv~‘_CŠÎç Üźś“óív4ô±æ%ôOíڗ/«jőmőe”łjFEK™ëLŐ3©Ü*»ĘÔqć endstream endobj 642 0 obj << /Filter[/FlateDecode] /Length 220 >> stream xÚUÍ=jĂ@à* Ûhoàč@V»úY„38 XE ©|€$e@6I-…\l»\CG˜RĆČăÁ6ÏđȚ0m팫Đk±iëđΔÆzlŒ7]ƒȚuŠvűîđ€MćLÛĄ•őuej{ńö©¶œ*śXĘ«r'mUöÏűuüțPćöćäKì‘§ E(hœfÈ( ÓĂ›1霝q„ ~ßàłx”è ČÌłƒ æŒ8‰ž"^ bZ‡ ń4˃”3ĆŹçu‚0&˜àv$kőÔ«ŚR­yG endstream endobj 643 0 obj << /Filter[/FlateDecode] /Length 222 >> stream xÚUÎÁJÄ0à){rqßÀyÓL›6ȚvìAГàîQšąç űby”>Âì-‡Òqș] a’ù‡ijČTĄłÎĄo,Œ­%Bß¶6xl)ۚpOűŸ"ÛtzZŹŻț'ȚȚͶ3ć+VwŠ|D_›Č{ÂŻÏïƒ)·Ï;$­—Č»G‰žàš3ʘĄà€ÓMìÓqpéÈ*ÿ9Iv"|1ô"©— XbÁąy«ćŽú&Qÿ‡čw-’Ő‹éìGgăE^ŻŽ·ĐLÜD—úyÖyă> stream xÚuË1NĂ@ĐEABچ#09ëŻœ˜*RB€žˆ*j”PR€ N"_ÌčIö.]Œ2| „HÁŒ^ńÿhÊÀŽsòÎ{ Ț1Ó-—ÎG**v•§Èw.0m˜Țš(ÙĆ{òŰrâùÇúŐNk›=Ą”قŠÜfő’>Ț?_l6]͈‘żcę@Ș#ŃӅšüèÇąĘàYô˜D[8ÀžJr\'‘›$ę`’€ƒă4I h`ƘKógvȊț_=î1żíŒ¶_œć endstream endobj 645 0 obj << /Filter[/FlateDecode] /Length 198 >> stream xڍÎ1 Â0à”B{ƒŸ ˜Ÿ€mê&T;:yuTtnœY:yzƒŒŠ1Ęäń ȚÿóҘ3."$)ă bdœC"%ː(˜HaĂá‰à,ÍíÈX°Xț&Ö;š4ZÒhfŻiTÌát> stream xÚUÎÁJÄ@ à”„čŽo`^ÀiÒN;Ț «‚=zÚP ]Ńóșì‹ÍŁÌ#äŰCé˜ș‹ á;$äo¶\#Y"t­e7 Yft]gœĂŽœmßśèj¶­GÒꜷźțżńș3›ÁT[ŹoMőˆź1Őđ„Ÿ_ïŠÚ<ß!kn‡{L󕀘I `\h΄Š"’\GŠœ:D CJrŒ8-*’C.™‚Ő} HRBšÊLći†łćÏéâšóUű5•úŁ\ÿIń=ê1™ôźnhźBóőbóò™“w– endstream endobj 647 0 obj << /Filter[/FlateDecode] /Length 189 >> stream xڅË1 Â@ĐHŠÀ6zçnv’MÖNˆ n!hćÔRPŃZ‚ȕâMr„)-ÄqC"šÿóŠ_ü$F‰(©èDąAŹ$"è4•FCŠFÆ„èeb@čŠÚH}?Ö;‘Yź Šp:ĄĂéxȚŠ0[ŒĘnŠ@ÁLžçőŒŸLœ€+Up”g.‰9w:ŽOü źÓ'ŸŚFÄT»WoL\¶nNȚș~đ[Á“˜Z±|°©‘‚ endstream endobj 648 0 obj << /Filter[/FlateDecode] /Length 213 >> stream xÚeN»nÂ@\Dt üû9ßÚg HĄâHJ€K”ÔńcæOî¶ta±x“­FÚíÌNY„u}i)àKá,úȘČÁcEÁ„o„èsČe@ŚOćƒőùłăp4‹Úd{Ìg&Û /LVońëóûĘd‹Ś%RÏÿhœBiæ|ƒw0ä̜Šçۜ’k„ĘŽ“‹tOPí*­KÂ1͛š>ő ŒĄ;ûœSŠCé`$·P]oúWÿ'€š]4KûiOłźÍî4—zé endstream endobj 649 0 obj << /Filter[/FlateDecode] /Length 227 >> stream xÚUαNĂ@ `‡ •NHô êàrN.č•*È€D§>0"Ò„ovrà ÆĐ ë<űśß6d©FgCßZ xÙ8K„ŸëlđŰQ° á#á úšlĐét>X_ÿżxx6›ȚT;Ź—ŠșEߘȘżĂ·Śś'Smt?źę5JZłÀO0ă f΋aŸbÚ’ĘAŰ2Î˓™L?àŻòä ŁbTZ'È aj„3˜àV ŸÓ\4çˆ]V)æß)œbÁéCAÉY{1,Ž[äŻBŰÜôfû Kkvf endstream endobj 650 0 obj << /x28 575 0 R /x29 576 0 R /x3c 577 0 R /x7c 578 0 R /x3e 579 0 R /x5b 580 0 R /x5d 581 0 R /x5f 582 0 R /x21 583 0 R /x2c 584 0 R /x2e 585 0 R /x3a 586 0 R /x3d 587 0 R /x2d 588 0 R /x23 589 0 R /x25 590 0 R /x41 591 0 R /x42 592 0 R /x43 593 0 R /x44 594 0 R /x45 595 0 R /x46 596 0 R /x47 597 0 R /x48 598 0 R /x49 599 0 R /x4b 600 0 R /x4c 601 0 R /x4d 602 0 R /x4e 603 0 R /x4f 604 0 R /x50 605 0 R /x52 606 0 R /x53 607 0 R /x54 608 0 R /x55 609 0 R /x56 610 0 R /x57 611 0 R /x58 612 0 R /x59 613 0 R /x5a 614 0 R /x61 615 0 R /x62 616 0 R /x63 617 0 R /x64 618 0 R /x65 619 0 R /x66 620 0 R /x67 621 0 R /x68 622 0 R /x69 623 0 R /x6b 624 0 R /x6c 625 0 R /x6d 626 0 R /x6e 627 0 R /x6f 628 0 R /x70 629 0 R /x71 630 0 R /x72 631 0 R /x73 632 0 R /x74 633 0 R /x75 634 0 R /x76 635 0 R /x77 636 0 R /x78 637 0 R /x79 638 0 R /x7a 639 0 R /x30 640 0 R /x31 641 0 R /x32 642 0 R /x33 643 0 R /x34 644 0 R /x35 645 0 R /x36 646 0 R /x37 647 0 R /x38 648 0 R /x39 649 0 R >> endobj 37 0 obj << /Type/Font /Name/F9 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 0 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12] /FontBBox[-53.1 -430.2 584.1 923.1] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 650 0 R >> endobj 651 0 obj << /Filter[/FlateDecode] /Length 232 >> stream xڝÎ1JÄ@àÂ"0{aßœL’™M„ÀȘ` Á­<€ZZ(Ú ‹€đZ.ëAČxŰ„x䶅A+ùùŠŸÇƒßšJ—žŒ6†2k”łtœ»\{KÎ8]y* «KG·=P±ÈtáÈH|Uê…ßÿččWËF„ŚT•^P•«Žč€§Çç;•.ŻN)“jsFzщqŒGŸĂ‹œۉ­hE"fŒqÎ`1ÔbÍèE‡`”QŒł€'sđ0©ƒ~ČșȚŁMô”{DòoŰțò)vї"–c@šóF­ŸÙi1” endstream endobj 652 0 obj << /Filter[/FlateDecode] /Length 231 >> stream xڕÎAJĂP`‚đ(ä…Î|yÉKúUÁ,„șò¶KŠî z-‹)x7Y ÿ0ÉŠ A~ŸĆżæÏ\aCIÎ:GIj]FçižÚ2#Œő%ŸÙÓ"Ą'òÓÄúœRÁNËŁ“‡G3«M|OȚ™ű†ŠÔÄő-œ<ż.M<›_R‚ź”Ÿ"‘9@ŒR팕tFœ#kűü‡őNz§ȘŒÆȘ`ëŸłR»«mïœwŠÚHń*–öo ,;ŰÂl n'ÂÜ©„> stream xÚ]‹=‚P ćžâ»ûv7ëûi_A‚•PK ‰Ț_ Ąé&™I1Čg‹À3kFg.\Q­ Óbœ wĆ ‡„Vƒ`‹ÿ—Û“úJá OÎp uÄ{ț<(ôÓșűȘu@óŁmöŽtȘtù endstream endobj 654 0 obj << /Filter[/FlateDecode] /Length 159 >> stream xÚ360Ó3”T0Đ30P07Ò32WĐ520Ń37S02ČĐł0U°4Ó36SH1T(T04…šBcC=C#4Éč\Nž\úá †Æ\ú FŠ\úžŸ %E„©\úNÎ †@>„ëéąđÇâÇŽÀă‡Çÿÿ;țÏB‰ÿÿ,țTüùńăÇǏÿŃÿCț‡ę.WOź@Á.;— endstream endobj 655 0 obj << /Filter[/FlateDecode] /Length 113 >> stream xÚ360Ó3”T0Đ30P04°Đ31TĐ54Ò30Q024Ół0T°4Ó36SH1T(„É(À•ąêHÎćròäÒW°äÒśžŸ %E„©\úNÎ †@>„ëéąđ±áC446nàrőä đŐû endstream endobj 656 0 obj << /Filter[/FlateDecode] /Length 264 >> stream xÚ]Ń1N…@Æqëœ{—…ïčÉS)LŽòjiĄŃšwŽÀq¶äԄÂü)Œ3Ć/3É|Í€‘5ÎikŹŐQlląŻăcČ­Ž66qȘO‡ÄœRęéO:kâHÛ”sæ”ü;yęPç\…/:q*|Đ7æúûëç]…ç§[­3c~§—­æ«żL;a€zh %T@&Ì;…0Á°#tĐCj(Ą‚2a†©€E`„hÁC %TkČPÓÎ" ĐA ŽàĄ„ Ȅy§&ےWF蠇<ÔPBd ’Œ"oč 0B ŽàĄ†* uŸ«ç_[ÁĘ endstream endobj 657 0 obj << /Filter[/FlateDecode] /Length 144 >> stream xڍŒ± Â0Dƒè<Ć-Àśÿ¶ă6€„ $š()@P&`%€LÄùXrGĆ=é€WÜyŽT·`b†đœ‚`&Ž8Àł8'T78 .ÖQăÀ™à=Eś39œM—ŒĘCą±kűÜiƒÛő~2¶Û. ًŠ%tЧVca2Nő„äŁïțŃW…|0šY%łû…MR  endstream endobj 658 0 obj << /Filter[/FlateDecode] /Length 133 >> stream xÚ373Ó3±P0Đ30P04°Đ31T042Đ31U077Đł°P063Ô36UH1T(T033+B#=Kt-Éč\Nž\úá ŠŠ\ú F\úžŸ %E„©\úNÎ †@>„ëéąđƒ˜>€)†ÿ`đnÄVč0eÇćêÉ mŒ endstream endobj 659 0 obj << /Filter[/FlateDecode] /Length 117 >> stream xÚU‹1Â0SFśŠ}Áù|g;v@âŠHĄâ@I‚ž§Çą`wši-O\„EP[DŹÂ„Âlb-Đ$Üڈ4+·é-Âjÿ‡Ëf§p†F Gd Ÿàő|ß(Ìë]úwúŸaèü2ÒÁéŽ`Ï„ endstream endobj 660 0 obj << /Filter[/FlateDecode] /Length 302 >> stream xڍĐAN„0` ‰MșH/`Ą#X55‘Ć$șòê҅FŚ aÁ” s‘/Đć,đ=\ `,/ù^Zxż—\$,äaÈ.VS@HžG’Ç)“i„`ςœ±8yoӊ+­ŽÏ<œÒuFƒG&#ܱXÒ Û°śÏŹïŻ™€ę°ÍnXËéŹXÇ7.h”§żÀș«-)k°ŽÄʂź%l‰==xF Ž='»ïź;r?êc;èÏhF¶ƒjȘqp©‰Î±ŠÖ9Ž…”ì¶/»ŻeOú‚8úZŽ%}ÛKfŽŁ¶ÿ‹Ńÿ+ÆùŰ~]ˆé[Û\ă”Ú(ŒŁhŒjpÚF«Ę,”Âß$•ińs•göxmí[§7ùœÍèĂèĆ㊠endstream endobj 661 0 obj << /Filter[/FlateDecode] /Length 302 >> stream xÚuŃMJÄ0đ)]Č©7è»À€IlătăÀš`žr-êR舂 Ąs­Š)x,»(/itŠL ż|ŽáćßT Ê2`”1˜‹ÄŒç‚Kșà ™ "™-šäpÏaRHzœĂžń”&búÍĘ#Yć$ŸTűN$‰ó+x~zy ńj}çĂ4?­ö>ûÙŹ@ÚšeHSöGf —‘Jw_·;úà|ł uWXޚÒ:ąÿQŽć!j†m„§L}șaëR›«ÔzLïśê—Îîđđ–ŽhJïcÁKeP§lÆńÆđx€0ALxU&K€eQK{ké°j a‚Đ”–fŸïÆüOU9j‹ś9đ5đa ¶–mh©#‹=R+r‘“ë—Z”Ç endstream endobj 662 0 obj << /Filter[/FlateDecode] /Length 306 >> stream xÚmѱNĂ0ДHDòĐź ščÀIÚÆM%T€`‑k›ȘC7Ÿ)Ą?‰ȘÁòqvJ’ƟNÖÉșsMčƒÏ}ÎFîψ@đ(1Žű81‹žà)€WbÄ'űŽfAÈ'ŁnÍă [ÄÌ{€0dȚ Lóâ[xûxfȚâîÊ«4Ÿ€H\E§Žì„(.2MŽ…&ĂÔ"6˜hlLŽÇ jŸ9@uÜF6”.Ê~›ČĄ †úŐ_ŠCæXX]0_aŸl“éÚȘMÒ@M­‰uMï›èUŰšqj”RăÔ >[”„ÔôőJwűĂ9ĘWĐÎ òt©Q'Ž”žî*° őü‡ï\ÿ§ZïÉ œ=»ŠÁÙ¶Cꊕ]ÇìțÜܧs endstream endobj 663 0 obj << /Filter[/FlateDecode] /Length 240 >> stream xÚ]αNĂ0`K*y)o{ÛI¶J-Hd@‚‰h;"‚9ĘûJlyąŒ€ły°l\_$lî†OżN§»¶ź˜h€3ÎAq&+ž’ńԍb‚VpŠŰ x%«jàĄ[)YûocśB7-ŸĄ‘ŽŒ3Zvđńțy ćæq "dŒĘ-űPn­/Ű ƒèŒóLùÎ8"芾±Ż)F§LÈ2"CÆIŻ “àÖ;ÓGŒO™2ƌ9’@Â›„ŒęĂö3ă#™1c@ŸȊžeÄ,§ MHïÈ„Rè]GŸ~ÉáW© endstream endobj 664 0 obj << /Filter[/FlateDecode] /Length 283 >> stream xÚUĐ?NĂ0pC€Fò@n@ßp7:%R‰ H0q`dÁšæh9Jސ1CćÇg»jÚdűٖŸę>WzŁ*CZiM„VfCw™Q:§ÊUa­ÊUaè#Ło*KŁò-iüć¶TEyYńț%w­Lßš(dúDE%Óö™~ț>eș{č§ ó0mˆg!Dd=ą ÔÌSÂă XóŒòÀź=ÖѰ'††ùŒ}X ô šëٟâXùÍóÜw…»n=cÍ §·l#Œ> stream xڅŃ;NĂ@`‡HŽŽE|<`íĆŻĐ)€„ $š8PR€ Ć†&%WB€àáŠsaíÏÌڀxHÈ+}Úőì<ìÂd:™QŹă˜Lšê,„­$Ś&ĄY\èŰPŸ3ÓčĄsCW”çÛ:ć`~Š$ŐEöăÊÙ„Z”*:„,SŃ!ćFEćĘ\ß^šhqŒGČï·ć>èFh˜'ŻZ3ž>˙ ˜&Àò_ͱÚj`í#>śŃíh} D;Ć:ä«S‰wTŽZjlÂsŰQÏŰŃ9v%É’ë“;Iùì€űE=Pę7€xùÆÒu‹Ç~7XĄĂÌĘÜÊÌmŐĂí2o wö Û0+†gX¶,ŻnÂŚ`čRSÁąźî9ÿŒ±ĐxĄàŸU„:yŒh/ endstream endobj 666 0 obj << /Filter[/FlateDecode] /Length 275 >> stream xÚ]ŃAN„0Æń$ĘÌÜ`Ț,…e7Éš‰,LtćÔ„ ]ĂŃ8 Gè’áù•‚ †À/]4ôÿjòL•)i„5e„JJșIR„32F«Č€Âd*Oé-ĄO2iȘŒ&śeĄòbżăőC^*żPĄeü@č‘qőHß_?ï2Ÿ<ĘR‚”_VwÄŁ"`;+΋Ë> stream xÚ]Đ=NĂ0ÀńT"yÉò.€ă€±Ę­R‰ H0q€ÂȂ9A{%*źQÄ2fˆòxÏùÂ$R~ń<ÿmìZŠ”T Œ’Ù ÎÒLȘì*—Vƒ±čÔܧđ4Ÿ+șÍÚHmü/vb[ˆäŽÉh+’â^ž_DČœ9‡”ÖęČžlŸțu„-#V=GÄÓÌ7±ùˇO9ńCđÁ¶œĄ‘#ˆžÀ5=»‰łäÙÌŃÁÂcɄÈ4!î{>™żfšë}$æźĂ@sŚĄÛž<†JځÒu5}W=Qő±ÌŃÏeö܅Œ'ą č‹wEAXEèNÚ'FqYˆÛ_Š;Z endstream endobj 668 0 obj << /Filter[/FlateDecode] /Length 236 >> stream xÚ]Đ1NĂ0àD*yÉú.PÇ1±Ó ©€D$˜802Ž‚9U;0r„ÂĐsÀ 2fšòóÒ„Úź=|ï·lKïYŁ„Ő€€Rd•Ô4Ë”T•Z˒ÏÊBMÏ9-ÉZ-‹9)Țvn„±á‹§W±šDöHƈì–L)ČêŽȚVï/"[Ü_QÎyˆŐ5Ąúuš”Kf Œl€æÛqéł ©OìuFőŸÿœę§bŽ8ŃĆh<ü|1‡„/1Q4’8Ú F¶=)>MÈŸî+őàN»ÚgŸ( >Ò é8çsÄM%țƒ°K‡ endstream endobj 669 0 obj << /Filter[/FlateDecode] /Length 254 >> stream xÚmбNĆ `H‡&,}„žB--[“«&v0ŃÉPGÎôŃîŁđwthŠh‰%†„|g8„ÿșk..tšK WČćą­oôCÇU Ż>@‹ OŻ{źúăÆË;;MŹyÆÖ܃Â{z€ŻÏï7֜o@âÇéÜBHy!„üśS:gk‹šă_\çăQ簈9ÁyŒ9Îȃ˜łqkBàrào—„ÒƒæX1Iš(B4ëßđ‰6ÔeŽŰÊŽŃŁÊëÙa<걞ÎcÌëÙ@LŽXφ"Àmˆ­8;ș†ì„Đćv7±§_š‰f endstream endobj 670 0 obj << /Filter[/FlateDecode] /Length 188 >> stream xÚUб Â0àˆC!KÁ{Ó€MÒ8Ș‚|utPtn­ÒGèŰĄ#ržrđqÿppw™3B[BJĐN(s• ©A/2á4Ű\ “ÂIÁŽ6Âæ CYg…±ÿÇ /+ž ËyČʶpż=Î<)wKP!b”?2Æ~đC4b€'fHGHKÔHCx„}™ ObŠŒD„ DŒôÄ éˆi‰iˆpŹgĄ{ ńuĆś/N5ò† endstream endobj 671 0 obj << /Filter[/FlateDecode] /Length 326 >> stream xÚ]ÒœNĂ0đT*eIß ś8ÊG3E* è€+02€`N2uÌ+YêŚpÉ $›‡(Ç9Í‰ŹłÿÁw’ć]0Ï›Ù6„.sCžr\f{íBD„ó]xsà"Çgž 6­`0?˜ßxęĐśĘz†0Đ­{đCĘ:<ÀśŚÏ»níŻÁĄ|‰‡@©miŚzUŁ„¶„ŰÉšzqs&Ą”ŽÚÆ€ßQć±”•NJ0šyIHIŠčŽ€šOBRN*2HE:(ϔÌIYW¶VœÚx­gŰ$s5$ÙNÚ(%Ö IRÙ *C 'qÌ;UJr)M:kämŒĐy“T“bR‰\âB'ä5Š^%Š„Tü“ž»èšÄ{4š”Ł0—2Tłt=RŐȘ…’Ü(­șŸ L”u§óšú"ęö ?ę°°Æ€ endstream endobj 672 0 obj << /Filter[/FlateDecode] /Length 315 >> stream xÚ]ŃAjƒ@à‘,)xR睌©WÒêąĐźz€¶Ë.ZÚ”BYæJ^CÉÌ΅űśÍŒ1Š <ŸóȚ?ËàFű!—BJďù”ż2àqŠ…äŃ2Ⴟùü“Çr)€Ï%(ŽDOŒ~8ëԙżĐŒ3à!Őô‘ęŒ;óőÓ-ś©7mzÇŃ1`ŒM13@Kh튊tîĄQHۀCNÈŠšó ­ÆŽÂț„Ä š4 eó›ÆE­ŃșŰ+lO° ÜÎFa0C©àè zŻ·°Ń€…­BrÓèäpđ2äـFKX šV‰&žRh(˜Ët6As1 Őš lMÒ&ț  a)”@c3ĆL>żJÀ gÔS(§pîSçùk<§ endstream endobj 673 0 obj << /Filter[/FlateDecode] /Length 240 >> stream xÚeϱNĂ0P‡H­äĄùƒö~Çqc;‘ Hd@‚‰€Ž ș¶ùŽ|J>Ác‡ÈÇáąÖVćáùNw§;cQYBJ0Rš5ÜVJÈŹRÂRÎÖB+űšà ŒQąn@Ò3Ú€ïŸ|Óńò ŽæćhËËî~Ÿw[^n^űv€GÆŰÜŰ?{DWà°$Vèi†8žń7D3ìÂ!Š?3Qe1”ÿ›I‰ŒXÜę…ń}NóöÌă”Ó/à ‚–nÒ sĈ"Æ„ŹbƔ6fH9Äô)ĂȀ?ÁX~ ìűë/X{E endstream endobj 674 0 obj << /Filter[/FlateDecode] /Length 277 >> stream xÚUбNÄ0 ĐT 'eÉ'Ô?@šöźÍĘTé‰H0ńÀȂ9Ęű­HüH%~ lȘÛáJhSœDČ»¶:èÊ‚ŃÆÀnŻË=œo]nÁV•¶»Óu%Œœö_[ĘÔÿ3žć±“Ć=ԍ,źĄ>Èą»·Śś'Yo/ Äs> stream xÚeÏKNĂ0`ŁH‰äč™ gëŽ,È VXČÁ:^Źć$„]–ÆŠš-ÈÒgG3ă™Ș2Í甧yNu™–5W*-*RŐ,­f€æłTtWĐ#MgJÊùÔŐ$­§û·rŃÈì†&”Ì.H2k.éùéć^f‹«SrńOۜ€•+âO`ÛëŚw~Fÿ,1„@„1„aB˜Ä9jŰÍC»”gĐăŻ+ödߖŻ_”łOŒWp# "ö°Ł­…"±€1»‘uvą œƒŚxíŽŰuiżțùáłÎhÏ5wˆ·šdcǃ”shmŚò–¶ÓXÆ1Ű(0Wt"Mü.Úžœäy#Żżè-Ï endstream endobj 676 0 obj << /Filter[/FlateDecode] /Length 235 >> stream xÚ]Ë1NĂ0`G"yÉò.€c‡ŰNŠJ$< ÁĊ;€`n7FźT©Ś0â=DyŰN›ś†Oÿ/ęZHvÙgœƒè9S=\ˆ–ńôбAƒÒ“-Œx%:ÖÀę«^1©țMžwtchóRĐæ€Ščƒś·-m6śWà[łDs ŽÄ;3ž)‘ %ă t`ś 88ÁÏÂ/Î+Ï)òtÂ)đœđ‰Séù 8 T[Ł«RÆ0P§ŰœuÊ1gŸrÈÁ’Q€Ì9«”)§Lq9UʘSGŽ1ń K2èĄ"ŸB endstream endobj 677 0 obj << /Filter[/FlateDecode] /Length 278 >> stream xÚ]Đ=NĂ@àE)¶ń<`ꯝT–Hž@‚Š%ZlD‘2W2J‘kq§saÍ0»kĐ&ÚâÓŁ}oŠlź ±ŠcH–©*R8›ç*™ĂBk•Ɛ™Ò)<$đ yžȘl1ż"‰UźVîŸäȘ’Ńh-Ł+ĐKUŚđúòö(ŁŐÍ9$<»±ș€Vˆșâjjąæ"jŃò…$˜í?'Ìî4ŹęÏh!ާ>ƒ%Oό5öĄOÇ „]éÓ2œcÏÔ>ŠŚ·ă‡Ąc¶„ŠȚŽl“‰”cs@`ÁĐQZFæĂłôdÙ3-ߏéjút˜†}9r|nkr# ó1ßzf1Íće%o è\Ă endstream endobj 678 0 obj << /Filter[/FlateDecode] /Length 311 >> stream xÚeŃ=NÄ0`ŻRDrnKÔ8v6? aŽ€Ž) â@I‚ÚÛQæJÛć–r€KeđÚë ŒF}ݘŚLUmh‘F#)ËhY‹uAùšpž2Ê7€(3š§ä…“wRńœf)azJÎh‘{7Ïox[ă䉔Nv$ŻpRߓϏŻWœlnŚÙÆú– öBè€ĂQ‘ŐÙžŰÇ0­ú)8H˜'ˆțkŽ §éWÒiŽÚkÓ`…œf­ÎÓt-ĄŐ œæFĘŚxŽâ“ÄIłpšŹZ-é4‚Qł(Rb°ŠfĄDçi’JŽžFPąń4hĆNWV–pș”FíąoP0jĆ žŃÊ uîK‚ }šÈ©·ÒÿíăEÂ(ű#i.ŠŽË“nŒđ]‚łÈ endstream endobj 679 0 obj << /Filter[/FlateDecode] /Length 297 >> stream xÚeŃœJĆ0đ”ČÔŃAèyÓäÚ/ W;:ùêè è܂CÇûJ•ŸH‹/P· „Ç4'^(ÀÉɟ“,>*)€„8*‡S”2†\ ™BšĆ"Ù“‚WÈ2)ò€YižŠ$]ßx|ỒGÆ<ș$ăQy ïoÏ<ÚĘ]‚2g:–W€3cf쟚Íf!âä#ÖH~gcłè!älʍĆ"Ă©"ő‚č<’ŐàìŹmՐĆȚiÛ`Q'ÎcÛÇ#$=RûÎÍÚéOíĄȚ[śùvvŒlœAm™ĂÚŸ?­uȘZ›K#ùƒœuÀȚæïœ ŽÖ=ŽË˜0$͌t`ÛP`í]đÁțršp“Gż±gæKjæ[ÙÁ òë’ßÿz2 endstream endobj 680 0 obj << /Filter[/FlateDecode] /Length 234 >> stream xÚ]ËAJĂ@Æń„Yf“#ô]ÀÉLgbš)UÁ,„șr-­KÁŠBBčŰËM^`–łæ™NE>űÁń•JŠș)€%WÂ(žX!k(U%j Fkqč„œ‚Y‹RƒœgÊJTêßeśÂ7-/A^܁^ńąœ‡ś·g^l¶Ś æ>g{D!čtfꟐFŸ" 'Ȑb8ásbè36Ò†SČ3xŒű ûŁÏ±§_\Ž čŠ°‘Ù«ä‡)òY3ÂH·šïp Äዣ=àdĘșÔ3 9ćÈo[țđ vö‹? endstream endobj 681 0 obj << /Filter[/FlateDecode] /Length 234 >> stream xÚ]Î1NÄ0ĐŹRXr“”t™ àŰÙŰIȘ•HŽT(‘ő&ąàZA\$Ü`JVÌxĄŃ+~1ó§ÔšBJPČ„‚ÓąȁČÔÂT`j#ށ;°^Wą0 i*%…ŃÿVnű¶ćù 5Ï/A7> stream xÚ]Ë1nÂ0`W /]Ùű/PǎM±—Fą 5zèŰT$&HÔ„ÇJ¶#GÈèÁÊÈJôô OOό°Ž€’”ŽÂ(zJŽÌx"&ŠŒÖâ9„”ą iă„V$cțŚÛËê‹Osž|PêxòFÚò$_ĐśvśÉ“éò•T엚Ï(<łh_†hđ‹zšș~ÇÂc`țlX5Y4|uŒ(ÎpĆą‡;œ[Q?À D7Źlvß öíĄïy0x>Ïùû Ÿy„“ endstream endobj 683 0 obj << /Filter[/FlateDecode] /Length 251 >> stream xÚ]ËżJÄ@đ]RD¶Ikwß ˜l4›? §‚)­ŹE-ORòbɛäRN±ä3—Ë”ß0ƘX‡EA:Ԛb‡IL'§Iš 2fȘŒÒ< MJ/1í(IL˜f€§dÓ/5ÿ.Ïoj[Șè‘Î2ʒ)TTȚŃçÇŚ«Š¶śWOû0ËkbæQLˆżŰ™#VŽĂJîèW*Gëđ[0äD_ŐàÎ pc%Ű%Æ=6` lŰĂ0s9zè|Ž?3ÖG=Ă6p €Ű#ǰàńp‘/ô3ç{Ÿ+Û™ȘjžźĐ°șQ èìûę€'@ZcÀÔM©~͘äŃ endstream endobj 684 0 obj << /Filter[/FlateDecode] /Length 217 >> stream xÚmË1NĂ0`WyaÍÖÿuìŰ„öB„Ú‰#€N+.–l#GÈűQF !$ôô OOÏ­‚òŽÒšŒöÊZVNé@n”VkCÎZu^уĄgČ.(kH§üŹ/śOr[ËòŽȘ ËČ^–ő-œŸŒ=Êr»»$“úw­ŻˆŒQx Zä8!bŽ8eˆăYˆĂ— DżAȚ6SÂEÛô‡xE–4Éìó_ï@›Äw˜ŠŁï1tÌnjG±`°Œźćț茀‘ endstream endobj 685 0 obj << /Filter[/FlateDecode] /Length 247 >> stream xÚmĐÍJĂ@đĆÀRšG茀›Ę|l(ȘBsì© =(zb饯•ąđrìaé8;êĄź ü†ÿÀÀ0©22Ż@I„à<É€Șši#K YšJ“€©Ji4Üix„,/dĄAQU:—YòwçöAÌŻ -EŒ€Âˆžč†ç§—{Ïo.@SțŽÍ% â~FôcbśAl:" ˆ3âÀL;9%ą±ĂÒ3ő˜Ú§gZ‹C̰ÿᱣvèóæXÿĂÈqâs`BËD>{fê30ő=ÓCÿ kŃ~:Ö»_FcK„±ut51Ž„žjÄò #$I’ endstream endobj 686 0 obj << /Filter[/FlateDecode] /Length 257 >> stream xÚ]ÏÍJÄ0đ– Ahß yÓdûA„…UÁ„őäìzVŃs·(ìkőæk|9æ2Nêv üÈ`˜™șY œäRHÉk-”æ— Ő ­()Ą©XUą]đâ/ó_Òk)êê_Ëö™­;V>òȘećojVvśüíőꉕëÍ5W”cwĂí njHŸrô™‰ĐŐ#„ž0œpD›ă!0 äéOé&R4û™qo'2aæpąÀáL|&Wű€ Ű|)`fˆă'1^pÖuûG1+ű h&zˆébĐÒGŸ"|ĐL0Qàbêa·{ű`Ò endstream endobj 687 0 obj << /Filter[/FlateDecode] /Length 254 >> stream xÚUϱJÄ@à„EÈ f^ÀÍær›\àààT0… • –Šv$•Í=Ԋ‚ݱòŠ!ădÎeàƒżűá+YŚ €RP*č,àlč’ȘWČ. \—R—đĂ3Źt%«_Ć”Rûû'±kDvĆZdW k‘5Śđúòö(ČĘÍ9äœcs„ áxĐÁ‘zŒŽ­‡utÆAęÌpH1ïHAj™­m)èF†Æv ÿŰLŃLL¶EGòÓò<ƒ<êH> stream xڅË1NĂ0`P‡J^âäżÎÇd)R[$2 •‰#R@íVUpźÄÖkžê^7QŒĘLLè}Ă{Ă«žV¶!VÌtcTUҕ6ŠȘŽUș€ÚČ2œ”ôNÚ°j˜RêkŁŹțûx~óVO€YśdkQŽŽțŰŒŠbŸZPś8Û%…ƒ—Á_D2őŸ ÿÈĐOà89ÏöŃŸGŸÈŸG—“dˆŠèG|”'È%n%fÒÍŰíζë;瑜€#üCqڊÇ_úҕđ endstream endobj 689 0 obj << /Filter[/FlateDecode] /Length 232 >> stream xڕαNĂ0`E ‘<àGà^ Ž;n:E* ‘ &;Á"^«ˆŚê €[‡(?\Kšg}–nžûÏj݊i„5ÍŹWÆÒ,7^•†Ź[(kÈZ9K†ÖdËB9Gš_éç*wÇ3ś+±ŹEvG6ÙÍùŻŻéùéćQd˛s2܇¶Ÿ ;¶aŻŽl‹UŚđhœJŒ•ÄĐ€ŰOÆ=Û±o¶R|ČŻAțÂ>: úš șš 6ŃŃÙíArpŒQ ÉgHŽ7I8&é$~ïoŒY†tqY‹Û/bz endstream endobj 690 0 obj << /Filter[/FlateDecode] /Length 275 >> stream xÚUÍÏJĂ@đ„‹Ű=Ùy7ÛüY›‹…Ș`‚ž|ő(DQđPLûŸÒЇ}…_`zÛÒq6ą~đ1Ì|yQÊY J*ZÉ4ƒŁ4—Ș„ŒÌä,=ÓČĐp7…GÈłLêÏńTI] /nÄąÉ dZ$P”"©.áùéć^$‹«S˜rțŐvÁČ=“Ű3Đö4L Xyք5cÆÌhLawPä^k™ șèێ»xăùrużș˜{Ę>č=țì~e#Oè xabB<Œ˜ùÚłòÂvnl›öMę±TŠ1ËڐqÿŰzĆàš><۝g‹!á'FdcÜP7Aq^‰ëWœïI endstream endobj 691 0 obj << /Filter[/FlateDecode] /Length 198 >> stream xÚUÍżApr…d`^ÀȚÎč]wń'q…„Ê TjwQ(œÒ$ Żqâ肝]|żæ+fŸHk§ €RÄȅЌb©Rh)”IŒÔkˆĐÈAÙŽQIŁÿ/æ+ŃËD8LD8Š0Ăvł[а7éÚîk6€ÏœòŹü|J«ËÈ#–;…SuööjìćŐÙÓk°»Śa„·gäčÜ)Źj])ž9g .TłŽt<ŃĄA„}”'1ÌÄô ÒPˆ4 endstream endobj 692 0 obj << /Filter[/FlateDecode] /Length 296 >> stream xÚUÎAJĂ@à–,R†B.P:ïN2Mš€PT…f!èÊšKŠîiWĘz„” œÆˆˆ»,óœITZfńńóÿ*1M!Ai$B “H3HC)€„( E<G /D±Hf˜M‘ÈóÏl‘3ÿâ ó—ŠÌÏoàíőę‰ù‹ÛKæîÎü 4§>56.öJćàśĄnČÍ?śs…_jƒĂLÇÊӃČ6r= șŰT™îwó]Uj§•Đ%Ux«NŸ&ôN€”iŁȘh[©Bršáç֜Vš[Śš]ȘłûV•‘ƒű§ 5ÍȘÓ”š%neĂKt?lši>Ő,ó¶u+ßÚpăđŚ‘-!ϕUæȘ4‹š‡ ёè€ì:gw?É7â endstream endobj 693 0 obj << /Filter[/FlateDecode] /Length 250 >> stream xÚUΜJÄ@đmò;/àækóqUàT0… Ő=€ZZ(Ú ;ኔŸR$ĆœFŽ{\·EÈ8I=~0ț“€‘ Öš €\«8„ËHOI’ć*LADZJ#x áô:V膀G'™ÊÂó‹Ç±)…ż ÿâ\űćŒż}< sœ–ËZ^Ă(iEhĘÁ1xj{[àá»$»zđpßxă€dëŠ`żX—5łÄ'eő'UdÙY‰tqf/qd Ę_»EƒĂąGͧ39ÌZÇzüZIŐOŰKÚ±íłÇÙ=v”5v†:‰–È7„xűĐ”ŠŠ endstream endobj 694 0 obj << /Filter[/FlateDecode] /Length 212 >> stream xÚ]Î;jĂ@`†möš d”«]ÙRcƒUì*HRșHHș€et1é&:–*„$pa†f`^©Ń*ÏI+­ÉèL9C/‰S:'—[•9rÖȘUBŸ†ŸÉf©rŽ4‡KŚjmžF>ÎbSŠűl"â=·‹ž<ĐïÏߗˆ7Ç72\Ïeč% † €•è°Ä5BÔ7Ή¶—húg]1k.“Șá!ŰXÌnŁ0œ ËY/YÂG5|qEwiŃ ćŁăiÿ/§WÀ Äź§;á›{é endstream endobj 695 0 obj << /Filter[/FlateDecode] /Length 249 >> stream xÚ]Î1N„@à!$ÓÌ œwŰa'Y5‘ÂD+ –­gŒĆ–{%6^ƒ#PRžÆ…ŐæKȚŸÿ%ÿ:MTYBą’ÄsșJ2u–CVjUdi­ò<Šđrˆšč.”.ț~<<óMĆă{ÈR_ĂZóžș·Śś'on/€ÒʟŐ%`g;㰑”pű%¶Ÿż#čwžu†Ü9ې I`ĂPzCr8™<śFłŰGXϊĆN ›•èÜŻ­D6Æ;„Žê`DÚȚK;kÛIÒŽfҒČA‡NîGw!ùQ‹Ń֒âlž8-öNJŃn’1óO~Uń»áÙ endstream endobj 696 0 obj << /Filter[/FlateDecode] /Length 230 >> stream xÚ]Î1jĂ0` -:‚ÿ T–-ٕ'—Ž…z(ŽSĐfÌĐÒB7;äbÉM|„^„„`(?ßđ†ÇûMĘJے’JQ©Ź4%ĘTÊÈۆL«„5dŽ–ME%}’¶”4†TžF[©íÿÎûŽoz^Œ‘źxńD”æEÿLß_?[^l^î© ùû2‡…-˜~'œÜŽ!óÌN€-9Ò9êNČăp1.áÄU‚E0,ùjÎSÌĘjІÇłÆ ÁÉ'çéiĂ+{x±± ]ù([čH ÌÂ'IwĆ{țúïʝ{ endstream endobj 697 0 obj << /Filter[/FlateDecode] /Length 202 >> stream xÚUË= Â0ÆńJ!KĐśŠI“~M?À‚N@ûŠƒŁWȘ8x Ć ÔÍĄӈCxàÿá‘!§Q Œ2©€‚C/””e SNSR‡°ä°‘%TfÀôd”Đ„ÛĆšô ÌAŒA€$(&°ÛîW$èOÀuÿČB“7ÖȚĘĆÇéZăóxźńzń+çVć,+ç€Á3*ĂœƒRèwZÜ?ȘćcèZ4Ïâmđ-jCnq7”•Ai^-dTÙŸc™ę endstream endobj 698 0 obj << /Filter[/FlateDecode] /Length 219 >> stream xÚU̱JAà )¶čŒAæܛÛĘds•ŒBĐÊPK!Šv‘–ŸRźò5âLi±Üïą Ă7đĂ̟xćsKì™)2…äč„Ä­_DJ1úe Û†(ÆìÒX'-ČÏÍÿ›{·î\}MaćêsŠș» zz|Ÿsőúò„Í?±;%`"ű2È ŁÇ ;Œa 3Űb†êÏŹT )SeŽe0Véż1‚­vìÇĂÀhŻJžWŻjÙüšâ sUĄ—wìäV>Ë\dìŐwÖč«osÜxÍ endstream endobj 699 0 obj << /Filter[/FlateDecode] /Length 197 >> stream xÚ]Ì= Â@`ÁBŰ&GÈ\ÀÍîÎȘ›*à˜BĐÊš„…ąuŽČôJ+^Cđ)SÇA·PgŸæï!©-(©8+QCÛX©RÀJLĄ«­4),5lÀžT*Šż‹Nąûm,ÖąŸ‹dƊd I>ĘvżI:Íùó!P]P•QùćΊÀ3 DG:4Œšôńd­ fQP±8(ăżùÇÛŐ7O'OgO‘§Ű?łKĘ«ą,©âوÄ(łKäˆ? endstream endobj 700 0 obj << /Filter[/FlateDecode] /Length 242 >> stream xÚUËAJÄ0`J,Ì ÚÿŠé$i§› Ł‚]șòêRPŃ­YÍNŻfźŃ/w]„üŠ"ȃïńO˂k‚ sĆeÇ3ĆEZ‡*AIɋÜćđȘšx©A„(]ò2ÿÿž} ‹†f7 +š]€œÓŹč„—çŚ{š-źN!û0›3@‚è]„ŸîŃ%?¶í“ĘÀśÀÖ¶6Ùvu ț1mW3ƒ]ȚÒeWh&"4ăKïGźțˆŒaÛ wûÙ»tâÓ1G6ŽődăYÏȚ=ۑ#$_ë 35ÚëéyCŻÉW’ä endstream endobj 701 0 obj << /Filter[/FlateDecode] /Length 228 >> stream xÚUËAJĂ@ÆńHÙäó.àdŠ3m&«@U0 AW=€ștQŃ”Ż'è•Yä)œ@țƐç«Q°<űÁȚçV„ò%h„5x§Źë„Sșçòœ”jœ„;°eĄÿòčUĄ sčx~›Zä[°Väś`œÈëűxÿ|ùæń śœő-PF#Æ5Ž„ÉŰ3§3홼§&éê“CCĂ/Èd{Pî) ŒbhÁɌ8ęÎ1Št˜ęŁĆQ‡AÎ.‘L+Œ2~ń,NÙHHiË`Ê Ąž«ĆÓ7$’”› endstream endobj 702 0 obj << /Filter[/FlateDecode] /Length 263 >> stream xÚUÎ;NĂ@`G."młGđ\€őú”1•­.HĆ€’uQPæJƒ\űćN·ĆÊĂ€hŠO#ęó0&Wi Zi eźČ.Ò\éK0„Q…<˔Iá)W0:Uiš+/j‘œO<Ÿˆe#â(ވo!+EÜÜÁûÛÇłˆ—śWp?”Í5$"‡>$ż¶”ۓ«08Zê™ĂD;ŃYȕ :$»îƒĘˆûgCÈÈíH1äëhö …Ž!w‡¶#ó?fÔŁ9ą—:gNòÈ]ÄÙíDwÆŚÄŽáur"BčùÀÈ>ôrÿéÖHaûĘós8·ă}Ä·PÜ4bő‰ÀÉż endstream endobj 703 0 obj << /Filter[/FlateDecode] /Length 245 >> stream xÚUË=JÄ@ÆńÍ ŠpnŒp’ìLŸš Ź ›BĐÊš„…ąíưEșőJq-ör€›"ŒŻ‘Ćˆ<đƒńšHŠ8_ű>šD œ/”đSƒX€””"ZÀCÏ ąTÄ!űăT‹8űÿžb«œyw Sæ­A&ÌËŻáőćí‘y«› Æ>f~ d\ł$mëSȘ¶‡=ńϏ=ș;2=RèlfHgóŽt1ïGv=Ő6T¶Dïć„5qò țaÓîÈ`ÓÙN;prʁŁSŽKËđacuÜlŹžwX”vƒŐaû…5Ż9šŹË]ćìöźžn endstream endobj 704 0 obj << /Filter[/FlateDecode] /Length 265 >> stream xÚ]бJAà„+"Ûì#ÜŒ€{»čĘxVšà‚V¶‚ZZ(Zç Żt"Żń‹/pv[,7îmš |đ3 ż­œČ–ŽÒš*«JCÇsłP•!§ȘNɖ„ZÌéÁĐ3ÙčQî„tœ…ÓʖÿVîŸÄȘĆ-•N—äŹ(ê+z}y{ĆêúŒLÌûXŸKf„Œò&_`?ùَìÀędŚqO› ƒdËžËÓgÜ%0$f{„·òSxÉ|~`HÌț2â%BȚG$d<Úäàæ(‚*Â}bù–èk4Ü%8ҎŒ3Úű 6ń-lBÎŰù%c‹5ٟŽŒEˆ‹ZÜ||rĐí endstream endobj 705 0 obj << /Filter[/FlateDecode] /Length 245 >> stream xÚUÎ1NÄ0PŁ‘Üűž à8±ÙlȘH H€@‚j”[,‚:Ó„äJ‹RpD{Óčˆ2Œ Čô€‘ÿśŰÛ­©°ÆZŰXS9žŹŒ± ű«ÚÔ%xçÌŠ‚çŽàšÚxÎòù»ęŚx:È]'‹=8'‹;p[Ytśđöúț"‹ĘĂ5”<ÿŽĘ ĐÒ.‚‚Š‚Š<"Č€„Ù7’ž˜‘òS†«Š9źšź-ifŐHÜcbÏbæÄ˜Šá rŒ‰=ˆ™cb 3rìœ^‘c_žô4 gs ùȘpQăç$4ŽAŽ8ŃăÿՒêŽCȚvòńhA–Ú endstream endobj 706 0 obj << /Filter[/FlateDecode] /Length 248 >> stream xÚ]ÏÁJĂ@à†{IȚ ónf»Éڞ UÁ{òÔŁPEoBZòbí›ì#ÌqKÇ©1BĂÀ30ĂüAœ\jD0žĐ”+뎱ĐÔssp êÚ‹wš­Őn(ćN7nČòüŠÖ­ȘžÀ:UĘCs­Șö>?Ÿ^U”~Œ#ęж·À3bö‰Đ{!§-Ç2 ‡UDŠ.L,ű3GŽłțL:rÊFbÆá\B1P2t‰_±Ç ‡ŽÛ ;æ]°§=s20§Â闌ҁ˜ÿS Ą€^" ԍxŠŁ€dà9cąoy+Ì:‰,WIĘ”jó$ĘŰ endstream endobj 707 0 obj << /Filter[/FlateDecode] /Length 202 >> stream xÚ]Ë=nÂ@†á(mCëŽč@ÖłöźȘH„HqDȘ Ą€ ‰ÒćX{ß .·°Foƒ>=Ć[|Țąi[@ƒă,<Û çkS[š<W·…=”ź5„äUUa\swùÚée§óO(Zżƒś:ïÖpű9nuŸÜŒ‚ć–ìV@DaòǞˆźld1#X`*Łš Èú†țő'’(.“ßÉĂd&źÉŁ“čˆÉB É‹è“ł EșœŁRê”è·NܞŽœO endstream endobj 708 0 obj << /Filter[/FlateDecode] /Length 310 >> stream xÚUÎMJĂ@đ”! 2p2i>šBp *˜… + .](ș ŠÒE—9BŻé„Whńănś|Łndàś1ÿ"Ur±J*%Ș\f©8ÊJ™fąÈgRÍDY(™gâ6"/ærž ĆŻŹJY”ÿ7nîƒe$Ś"«‚ä\ó i.ÄÓăó],/ODÊőoٜ "ˆ€h?bÖŠ%ŠlMšaJĐAH–0$C8ĄƒăÓ±Û2ï=zŽù`zGäˆèÁĂx Ô?Äm'xŹmˆ/ ±íÌ+ÚŚ8ąĄŠ ü/­8čèĂ_*»h33f0bŹfLÇŒń$­>QÍMŹ!vhÆòDmžÙ~ń­ö@dÚ„Á§Vž~…ÍàĄ7Ld=bô"Țś4ł'ΚàêÓMáZ endstream endobj 709 0 obj << /Filter[/FlateDecode] /Length 276 >> stream xÚmÏMJĂ@đ” C!(æ]ÀɄt& Ș`‚ź<€ștĄèNˆÁE—=BŻRèÂkŽ7è2‹Çü}cA)ȃŒá}Íź*2ÚȘœ.NçY;ŐŠ$gžôÓ3Mm©ËœŒ„›9mĘqÇꓚ7*»ŁbŠČ+Č„Êškz}y{TÙüæœrÉisAÇ l#áł?ž€k?Fß {`ˆ]`ű",ja™V>BČòC€€<ÄIÍcŒ[áęDìeòí»°–mè18Ju  o©à“À(Ôęÿ2ű—~Àűűù[v€úDۧZ۶ŒÄŒ@Ț`Țő žj°ćuÙšÛou„ăg endstream endobj 710 0 obj << /Filter[/FlateDecode] /Length 264 >> stream xÚeÏMJĆ0đ> Ù€7è\À4ęHjA<ìBЕP—‚ŠźEȚÂcxĐâEïYvQ'‘Ș ùÁ’ù(9ë:àŒsš%+k8ȘxĂZ ìX+@ ΚîJx‚Šź™Ź€ă>‚UŸÜ>mOŠŒ&ĆŽ%)úKxy~œ'Ćöê|ę[ögàpexædĆÈV˜èÀcd˜ÈûšƒˆM#3]ȑIEÌąvžtïłžsB&”1ű{hßhô|[äĂwŁˆÍ‘YÍ©™6ŰW''Ô É!5;›Đ/ê†$ûÄÁ3?œáS”B«%ÚÂpÿ ™śÎóž\ÿ˜’1$ endstream endobj 711 0 obj << /Filter[/FlateDecode] /Length 264 >> stream xÚeϱJÄ@à )")L{]æÜÛ%Ùäź œ ŠÎÊPK EÁBÈW\é+)ŸÆś)§ùĘ1…Dű`†™aÆYŁçs2ÚČfŠsK'YĄmFÎćڔT8ŁóŒn-=Pž;]”d|łB»âÏÈÍ}Œšăé5ee<œ ç­/ééńù.ž.–§d}>€őĄȚÁ 8á#°Rá­Rì „HšûŒűŸÆl…·_VžcY0yMAŸ0"DÜ'BАû î€ő˜à?ę!ï…Ő@ČB òM$€àÔÓ »Jh8‘—ŹÁ[„àMï;?|wȘ·ÊßÜEžűŒŽŻŸi”ì3 endstream endobj 712 0 obj << /Filter[/FlateDecode] /Length 271 >> stream xÚ]ÏOJÄ0đ ]Čé@ÈóŠét’™YF»tćÔ„ ą[;C/VoÒ#Œe„ŸŻőE?x/ |ŸÏœĘíÈYç([9»öt–›ćäęÚș /˜2zĄužÛ°"''lƒőáߗû'œ/uzGyĐéùNËkz{}Ôéțæœ2™żÇò‚,èŐ3Àj 4B…!ú€WèL§À+Ž/Ń@8ąsXȚ‚‡‰Xè'Ą›0›…pą*n·œáötHž‘p“ ‰ž1šč)„C#Ș?Æ|jd1c˜ˆ8šŃOÄ3btÉ/lF A:Dh*źÇ"”tàOÈU+Ą™•‘ÌȘúi€/K}û€$ŚK endstream endobj 713 0 obj << /Filter[/FlateDecode] /Length 258 >> stream xÚ]ÏÁJĂ@à=˜>€4ónvÍîÖ\ T…æ ۓ œ6•‚}­ÖŸHêì1‡eÆMj*–țĂÏÌh)xžƒàB€TŠk§™á2#?ËÁhÁU^@™œ4?æÜpm*śOl\ČôȜ„Đ#––7đöúțÈÒńí%HŸw±ŒJTÓIHß8é ! Oürì‹Ă&jܰ‰Ęó…-0˜ÙŠ‚YMdqÛČ&Úâ†hKąMËcą%&D‘c€.éiŠÛQyê–őÌ[>ZÂ=Gìˆ> endobj 58 0 obj << /Type/Font /Name/F10 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[510.99 510.99 459.89 510.99 510.99 510.99 812.58 459.89 510.99 510.99 306.59 459.89 306.59 306.59 459.89 459.89 361.02 361.02 361.02 562.09 562.09 510.99 1021.97 0 408.79 306.59 332.14 613.18 562.09 587.63 881.45 894.23 510.99 306.59 510.99 817.58 510.99 817.58 766.48 306.59 408.79 408.79 510.99 766.48 306.59 357.69 306.59 510.99 510.99 510.99 510.99 510.99 510.99 510.99 510.99 510.99 510.99 510.99 306.59 306.59 766.48 766.48 766.48 510.99 766.48 743.15 703.72 715.38 754.82 678.17 652.62 773.42 743.15 385.46 524.87 768.7 627.07 896.45 743.15 766.48 678.17 766.48 729.27 562.09 715.38 743.15 743.15 998.64 743.15 743.15 613.18 306.59 510.99 306.59 613.18 766.48 306.59 510.99 459.89 459.89 510.99 459.89 306.59 459.89 510.99 306.59 306.59 459.89 255.49 817.58 562.09 510.99 510.99 459.89 421.56 408.79 332.14 536.54 459.89 664.28 463.78 485.44 408.79 510.99 306.59 510.99 613.18 204.39 743.15 743.15 715.38 715.38 754.82 678.17 678.17 773.42 627.07 627.07 627.07 743.15 743.15 780.36 766.48 729.27 729.27 562.09 562.09 562.09 715.38 715.38 743.15 743.15 743.15 613.18 613.18 613.18 845.35 385.46 510.99 459.89 510.99 510.99 459.89 459.89 510.99 459.89 459.89 459.89 255.49 255.49 319.37 562.09 562.09 562.09 510.99 421.56 421.56 408.79 408.79 408.79 332.14 332.14 536.54 536.54 485.44 408.79 408.79 408.79 562.09 306.59 510.99 768.91 743.15 743.15 743.15 743.15 743.15 743.15 882.56 715.38 678.17 678.17 678.17 678.17 385.46 385.46 385.46 385.46 754.82 743.15 766.48 766.48 766.48 766.48 766.48 984.76 766.48 743.15 743.15 743.15 743.15 743.15 627.07 1073.07 510.99 510.99 510.99 510.99 510.99 510.99 715.38 459.89 459.89 459.89 459.89 459.89 306.59 306.59 306.59 306.59 510.99 562.09 510.99 510.99 510.99 510.99 510.99 715.38 510.99 536.54 536.54 536.54 536.54 485.44 510.99 536.54] /FontBBox[-107.3 -478.2 1180.3 1005.1] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 714 0 R >> endobj 715 0 obj << /Filter[/FlateDecode] /Length 222 >> stream xڍŽÁJĂ@†*‹à#8/àfw“N„Ș`=ù­GŠȚ„Æ7ËĄÒG豇ĄżŽ‚x’ę;‡™ï›ŠÊ7”‚DmŒ–rCă«(UYzMąú©Ê2Êł$­|ÛJà«[~ëż;‹'7ë\ń )čâVT]ŃÍćőćíŃł»+‰œżÇîZ€5aŸÁ2쎰=ÁæĂ;zCnû‰Ù±Ù©íșmÉ„mV#ÁHûű!‡MțAțk„Çáΰ:\Š‚"ê(„šÌ`̘Ä0æ1’©ö•ÍxŹĘMçî?DŸȘæ endstream endobj 716 0 obj << /Filter[/FlateDecode] /Length 217 >> stream xڍM Â0„[„ xÁwӀƎAđìBЕP—.Ę zŻÔŁx—.>Ç\ž’Ì"™™/ęŰé4!ŁĄÔ鞄ź5©v–z.ûXŸzĘśŽ±Ž§Ű;edp’ Śä'ČȚ©QźąƱŠf䜊ò9§­ŠF‹1YűÊæș Ś„Cá@űzábȏ?[Ì ~ŐXB–+Kć ä1g»TSžR]^_"ÏŸÄ«V͘Àæ0Z”áH ”Ű€ÇÔ4WË7!-ŁÆ endstream endobj 717 0 obj << /Filter[/FlateDecode] /Length 116 >> stream xÚ„‹1ƒ0©ïûÎöŸ–€„‹HPń€$eŠ òŽ„tŽÌV#íDč±%xö"ÆQ·Êąńƒ@M9*^_$a)ßČd­œŠç‡șLn’Ą‘\~`[orĘtG(țŚÜcŻź±Ói>—ș endstream endobj 718 0 obj << /Filter[/FlateDecode] /Length 131 >> stream xÚ͎± 1­'»*¶Îç{ûìOp€á È©°Dąv7™`„Ičd‹@%r6ÌăȚKà"°bœ ǀ34g–iÍEyПËaą±’ßC{òkX"_7ž^n'òăvĐűu‰»ëÜ'Ęìùűÿč/çæO«J» „‰i endstream endobj 719 0 obj << /Filter[/FlateDecode] /Length 131 >> stream xÚ͎;Â0DW)śs֟ŚN@ÂT()‚ śÍC$„7`Ț4ŻiRì„dxńj«ÁD TB†“džLˆ9‹ïár‰2ÄßĆùÆcewBTv;XbWśxܟWvăa°ű[ë:ú€Ísûÿ6ąŻÏo+_03„ endstream endobj 720 0 obj << /Filter[/FlateDecode] /Length 192 >> stream xÚ”± †édÂÒGđ^@ „@™šTMd0ŃÉPGÎòš}ŒÆź.>€čäËę$ÇgêFŽ”P Ź”†…·B[hŒźÛZa,œ*ž‚öN4T*ŚÖÂŚż/ŽȚ. 5—°†Ë°…ûíqæČß-ĄJyŠaˆÈ"âÈâ3XšœY—P`ÄŚ,Łü+ƌažÀ"ëò"τżÍètș7–ÿߊ~NÈy™ ‘+Ȗüńuàû¶îš endstream endobj 721 0 obj << /Filter[/FlateDecode] /Length 191 >> stream xÚ”1!EÙʄÆ#8XX`©6Y5‘ÂD+ –­ćš{ ăł•ŰLò2üdxV7ąő „Rà”Đ–Á ă ±^ű\ë„upźá&xŃPč|«EĐÿ‰Ó•ś‘Ë#Ăćœć2îàq^žìś+šó<Žq ©CLlVP°ŠÄ:LÈCÁ{žń™łŒoUÀș„ÈXąu‡êÊĘÒ;JLŒęœä… źŠ5òÇ7‘~{ìÙ endstream endobj 722 0 obj << /Filter[/FlateDecode] /Length 119 >> stream xÚe‹;Â@ D·ö)æńÚëÍ:iHlJ "è9z>tdžŠxM›2waádhT:ΊÜ:»ą±Âjž+^°Ț9śOœüïq{ÒP)^aFńˆB±žđ?ŠĂyę§uoaé&ë@‡J— KÉ endstream endobj 723 0 obj << /Filter[/FlateDecode] /Length 136 >> stream xڅŒ; ADûu{Š{>늫‚™.šĄÁŠæsŽ=JßÄF.ˆőązP•4òągï!­r٘‹ČšXY"k‹“`€ćäń&kæ'“ă…șBîr$%W¶ž]ïgrĘn‰—-ŸZV0ûŠÙŸTüÆìńĆô±bìÍh]hÿ^”<4 endstream endobj 724 0 obj << /Filter[/FlateDecode] /Length 166 >> stream xÚUË= Â0ÆńW/9B‡śùjSpȘ ftòêè èÖ!7đJ=JĐ±Ch-ê"żéÏĂS+ü‚”PŠŽWÂy2…„„ܖ"Śä”Š łŠiç…ËIM~ëÿćtĆ* <’¶(·dJ”aGûó‚ČÚŻHOęÍ°Šźnł†GÙ"4ĐBcü€‘l`OŒÏúŹ[6uŹ!ÍÒ<œnȚ·m7W endstream endobj 725 0 obj << /Filter[/FlateDecode] /Length 187 >> stream xÚuN; A  s+É ffçłłÛ8°*8… •PK E[őh{Ż`%S,»nÔFPBBòòȚKŹ24żfæ endstream endobj 726 0 obj << /Filter[/FlateDecode] /Length 138 >> stream xÚ352Ńł0W0Đ30P06Ó34V03Đ32V0±0Ôł0P054Śł4VH1T(T011Ő3*BSs=sC Éč\Nž\úá Ææ\ú Æ\úžŸ %E„©\úNÎ †@>„ëéąđÿÿÿÿÿłS‹8ÀÀÀ Á€PŃ(t8—«'W UGžæ endstream endobj 727 0 obj << /Filter[/FlateDecode] /Length 159 >> stream xÚ]Ëœ Â0@aKžČ2BŠ[€łÏq$Ș. b €A—"°RFń)),BúȘW<§-† *úsr] ÆÖhH+ŽNW ĐP]UšìÿsŒˆ& yČBn@!ăî·ÇYÈf·šú—qC›ÊŸèű„}ő,±lä#ó\ŒŠTv ÖČ<ËÏ,ÖQì?:.È endstream endobj 728 0 obj << /Filter[/FlateDecode] /Length 121 >> stream xÚ352Ńł0W0Đ30P0Ž4Ò37RĐ54Ò30Q062Ő32T042Đ31UH1T(T046Ò35PA(UKr.—“'—~ž‚Ą!—Ÿ˜ôôU()*MćÒw pVń!\O…$4(0ÀAƒÂ„ž\=čÆ(! endstream endobj 729 0 obj << /Filter[/FlateDecode] /Length 233 >> stream xÚUË=JĆ@`!E`š,!wN&3Ix*˜BĐÊ<--­cÈÜRȓ,!eАńÜ+/ >8N™șrdŽ1dÎrșź­Î-„Ó.%[Y]ZzIéòÚéą&ƒž*Óuöÿq~S§V%ϔç*č'[Ș€} ÏŻW•œo(Eÿ«í-yïŚo°\]˜ȚFfbzf8˜ìB6!«Đ€EèÀ,x02ÓAÏ LÀ„`"° 1X…,BfÁƒ‘™zf`&»MˆÁ*4`:0 țÂÈLLÏ LÀ„?ŒșkŐÓ/aĄà endstream endobj 730 0 obj << /Filter[/FlateDecode] /Length 132 >> stream xÚ}‹; AûïöLwÏìhș*ہ ‘邏hŸGÛŁÌMü ˆű*z•5ńŹ rŒčrQLE9&˜fVARá\pôSÎ/’7ú•ÎÔ:…=D(Źa ßàzč(ŽÛžÖߌ—šuìL>0v”Țÿđ» •ÓîÉ*BI endstream endobj 731 0 obj << /Filter[/FlateDecode] /Length 174 >> stream xÚuË1 €a™Gèđ. ćY 4éT5‘ÁD' ŽĘ:ô^‰Łp„ŽDÄóMÿđë™¶)€ŽR SÔFè*Ո AÍPèg@c…©@fș¶Íïł?±Î±ršXčeYéÖpœÜŽŹì6sÀܟt ûĐúbà_Ÿíۧű_> Ïš‘7OI"‰&ú€‘?x(†–ô$Nâ=Č„cÛÇ,T endstream endobj 732 0 obj << /Filter[/FlateDecode] /Length 129 >> stream xÚ352Ńł0W0Đ30P06Ó34V0Ž0Đ3łP0±0ÔłŠYšë™X*€**˜˜˜ê™ŐĄ‘Ą™ž…!ȘŽä\.'O.ępcs.} (—Ÿ§ŻBIQi*—ŸS€ł‚!ázș(4000p0 °Ű űAÓ.WOź@!ÙCč endstream endobj 733 0 obj << /Filter[/FlateDecode] /Length 117 >> stream xÚU˱Â0 Ќ•żâŸÀql7$k‰ •`‑ȘĘùtZ±ÀĘô€»^ËÂ"(ƐŠp.p3Î uá*ž'Œ`^·ŹÍÂjÿ‡Û“†Fń ­Oè)¶óŽ<(ç=Òê/Ûïșđ“ÍtltùŰQ‹ endstream endobj 734 0 obj << /Filter[/FlateDecode] /Length 142 >> stream xÚmŒM Â@ …»žSŒd’ù±í¶*8 AW@]șPê~Œ™Ć“H[A(ï‘Dš*ÁÄ áŠ‚À‹')žŠè1“@źÆAp†g!qà!ßńÿd2M2v]œ;­Ń^źGc›Í2űGÓ}æŹ9š‹)ÆĘ7œOÒiścüĘkŸÍ2™í <3WŸ endstream endobj 735 0 obj << /Filter[/FlateDecode] /Length 268 >> stream xڅżJ1‡gÉÁBšłŽ2ófÿgwáààTp A+@--íG|±őMÒÙni.Îܝà5Jàƒ!É|ż™ŠŹmŚbnó]nË {g+‡uÓÚ¶@Ś9Û8Œ-đ«Ÿ”u9Ÿ¶+m_îÿžčŚ«AgŚXU:;GŚèlžÀ§Çç;­.O°àz[§ŚËH1˜ż0)Á+­ }ÌiHÉύ‹Ł„Æ`ˆȚ‚é] î@ż ~nćq$Œ ÁŒá1ÛŰƶŻĄèÙ(ÆĄ€•Q”QZ}ă„ŸÛGȃß`’œ4Ÿ˜DÒ+™#•‰æâ56^I}úïrdúlĐWßĆyÁ  endstream endobj 736 0 obj << /Filter[/FlateDecode] /Length 271 >> stream xÚUÍ;jÄ0€aƒeÔšĘÎsÈoY[6 ÄE ©r€$eŠ„¶ł–œ˜â#šœÂXËq ÌèoÊZêr™çP)YTpsTČRPëBê”VČQđVÀ'Ôu#íÒku)ćÿ‹Ś~êyöUËłP ÏúGűțúyçÙéé š·±żâ”:{&Šó(ĂÜèÁ+sŁÈ]]7•ˆX> stream xڍ1NÄ0E'JÉMްsÛ8Ùlei‰HPŃZJ Ô1âbٛÌ\șˆÖŒÙm萄'ćńż7VŽ[TR)ŽŁÔ#^h#•E;ìä¶ÇAiz|Öű†ÖhÙó[>ƒ¶Òìțn<œŠę$șGŒìEw‹œĘt‡ïŸ/ąÛß_a™Oăt9‡™ò ÊZÊ 4”ԔÁUtŹr ”É „6“O›š|t xš Íž‡” xHí_iCđ]dÌ鄚MIù/~7Ê.žá"–Ÿ}Éđ%8·"6šĄ!¶j‰ę\1MÈÎ۞€{p#@«sLŽÄÍ$~;7€V endstream endobj 738 0 obj << /Filter[/FlateDecode] /Length 281 >> stream xÚuÍÍJÄ0đ”ZBÙ\=°ÛvÛ…Ć…]{ôäUP‚Š‚‡ĆMÙËŸIÀC= ‰W$đËL˜ù§š–ISC–dP™Íáäp•Mž4Ìò2™Îá>‡g(«:©sÈè̊&)šżwbՊôŠF€P"m/áőćíA€««5äÔÚö ì°ŽhuL(I°ÀÁ-šÀ!wŽÎ"Ê=ÿ‹‰wź}”bfâˆ$Jí›0îѰ„ŠűíțÛĄőì 'ĐłGÏ82àFbû!Q?mˆac7}łDŽ!AŽ-r ü$ŹâVęàћêhD)d1ÓïáÄŚì˜ù=;eŃÀ¶,iaAŸśqȚŠë/IæŻż endstream endobj 739 0 obj << /Filter[/FlateDecode] /Length 205 >> stream xÚmË; Â@à‰Â6zƒÌÜl6›˜QđŠŽòjiĄh'>næQ> stream xÚ};Â0D— ä‚Ü ìplă„€Ąà#‘ *” hŁ-GᔑÁkH"dùÙ#íÎh"„y2AÁ…@©žĐ8ú<:‘< ĆU„‰gÔqÊ' {b©čJ7ö'6ËXžĂqÊÂF’…ÙŻ—Û‘…łÍId¶À`h,ú:ô‡ićżJÂ#°x,ȘŠśíœ[swȂŒ"ûŠ‚,șŠ–.íȚ5V/ŻŠż€zŰx”˃PšQàjÙ yń­ê¶ÌŰö À"ž\ endstream endobj 741 0 obj << /Filter[/FlateDecode] /Length 240 >> stream xڝ=N1FgY EnÒŠË\Ż{7N…@b‹HPq€„’Y:Ž”GÉRN±Ê0ă"ZdéÉăŸńś\ÏąMstÖ9 ő/dĆ-0&o“ĂÆG;[àÆă3ÆXÛFÎÊhBČ!ęœ±~2ËÖTæŠșĆ:˜Ș]áëËÛŁ©–wWè„>–í521ÁxçÀ=œwÀđp(d>”ŒËŸ€`?U\ò»íèùâ“™G Ê(ćÿPüv9ĄÓö§'s‚ŒœJò #Mš1Ńôń蓜«‰eAâS’šŒIț`KæŠ5śß/Ë; endstream endobj 742 0 obj << /Filter[/FlateDecode] /Length 204 >> stream xڝÏ= Â0đˆ‚/ ű.`ŸLÚ …Ș`A' ŽŠn=Zâ;k’RAq’ÀŒÉ{%$Ń10ž+K`Âa€æD3ˆ˜ BÁžĂ €ŠÍčqIDòùbwÄčÁt SéÇÔŹàrŸ0ÍŚ3đuSš9Ő!”y†žŸuœź­Æ¶ăš‘§ž9JÏ=u> stream xÚ352Ńł0W0Đ30P2 ,t ô LL,ő,LÌ ŒôŒLR  LÌ,őÌM €ĐÌĐDÏÈUGr.—“'—~ž‚±%—Ÿ‡‚©!—Ÿ§ŻBIQi*—ŸS€łˆázș(4000đ1‚‰±ęáÿÿ0ńŸDüĂ țÉ …N00à °)†˜‚Íx(qD4A€|„@bL\źž\ ËĄá endstream endobj 744 0 obj << /Filter[/FlateDecode] /Length 165 >> stream xڍ= Â@…§„irçÎÎź»ÉŠ n!hćŒ„…ą} Œ›Ä&h 3đńȚc~œ±ì3Ą(%§„6,–ŹŚì…R1l•šnd]ƙ&‰jË&nœŻXT'ZyT;rUŰÓățŒ *kj}oÆ*˜Á°Ú ê€i&àŐąAńžÿ`ÿ†û+ă?&Ą‚E_tHŸȘËpđű–đŻç endstream endobj 745 0 obj << /Filter[/FlateDecode] /Length 246 >> stream xڍĐÁJÄ0àY*čžoàŒ€ișIÛ„UÁôäž{ô (x(Ž}ł>JĄÇJÇivô&2äÿ“nœö9m ÚL'odb t…ŐȚa–8œ)pŸà;ș4Śy‚FVfœ¶țï‰Ś7”-Uü‚Ö«űS«âr‡Ÿ_oŸî0‘ęq[Ț#ÏŃTńßÄ=ʉbfŠh.hŒâ††kîhžćžú@-t5Ôń™öÄX <V Ńż™à"â °Zh—YûûúđZą>g‘T!_·$mŽ™CúĐ#4 Ę€ćzékHš•üOêĄTÏ?SšŸ` endstream endobj 746 0 obj << /Filter[/FlateDecode] /Length 145 >> stream xÚ352Ńł0W0Đ30P2 ,t ô LL,ő,LÌ ŒôŒLR  LÌ,őÌM €ĐÌĐDÏÈUGr.—“'—~ž‚±%—Ÿ‡‚©!—Ÿ§ŻBIQi*—ŸS€łˆázș(40țg`b`űÇÀ€ Àb?äÿ°Ł:Ž;AÛàN_rčzr9AĄo endstream endobj 747 0 obj << /Filter[/FlateDecode] /Length 131 >> stream xÚ352Ńł0W0Đ30P°0Ń36TĐ54Ò30Q011Ő33W030Ò32UH1T(T063Ô36U0B3C=#KTÉč\Nž\úá Æ\ú І\úžŸ %E„©\úNÎ >„ëéąĐÀÀÀ€@üÿìÿ vŒÍĘ\źž\3Š‰ endstream endobj 748 0 obj << /Filter[/FlateDecode] /Length 144 >> stream xÚ352Ńł0W0Đ30P06Ó34VĐ54Ò30Q0±0Ôł0P030Ò32UH1T(T011Ő3ȘB3C=#KTÉč\Nž\úá Ææ\ú І\úžŸ %E„©\úNÎ >„ëéąĐÀ ÿÿ?2ûĂÿĐ@âD&‰qpčzróÁz endstream endobj 749 0 obj << /Filter[/FlateDecode] /Length 202 >> stream xÚ352Ńł0W0Đ30P2 ,t ô LL,ő,LÌ ŒôŒLR  LÌ,őÌM €ĐÌĐDÏÈUGr.—“'—~ž‚±%—Ÿ‡‚©!—Ÿ§ŻBIQi*—ŸS€łˆázș(4ÈÿÿÀÄÀÿÿ„`ÿ€ĄH0}rœÿ·`‰ÿy‰„0ąàŸ Œš56@ÂFÔXÔÀQ'đF0‰zFTąDÿÉ&€~cû A€Ćž\=č&ÁĄK endstream endobj 750 0 obj << /Filter[/FlateDecode] /Length 210 >> stream xÚUÏ1 Â0àšC%KW7Ÿ0McZȘ‚<€::( NZđbz“zÇbMSÒR|Œÿ‡7<qŒJA­TÀĐe„ràbD>e„y°sáÜdìUă»œ0ŃŒŰpcg#x.vâ%œO—=vąŐŠ\Æx‰'mdć•tIGuY+Ïd6š€ZsWšĐ0Ńô RcBUńhòȘx€ÍՐiĂWÓSüjșŠŒÉâ#‰Z%ÏŐ„7<ńú`ŸŚ endstream endobj 751 0 obj << /Filter[/FlateDecode] /Length 190 >> stream xÚƐ= Â@F'XÛx„ÌÜìf“l¶ ŠŽòjiĄhíxł=JŽ`i—MáÏdàÁ70đœ)óBÖ•T +%sƒÓ°Q‹ÒJ«±Ò…Ìî5žĐ8+ ‡*Lejiêï‹ĘQ4­È¶hŒÈ–X¶+ŒœŻ‘5ëꐇŰΑ ˜z€”cêFäòipㄈ™ܙę’1wÿEŹńÓï]> stream xÚ­ż 1 Æ]\óöŸmïn:8ì è䚣ƒąàæ=šäxCńL+‚.Nűрɜ%V^ä(č”HOYâHi. WòÜą“šk‹[…4ÆrGœNźËï‰ÍžŐž‰5Žs&æh~§ăyÇDœœ`Ì_©ŸbP”ЏèE@K5ž„AáqÚ썐„ÇO€–}Í&©$JòÉ(Z†hâ!.DżĘ?ŃÀ”ŁÛȘO€›y¶z7í°É endstream endobj 753 0 obj << /Filter[/FlateDecode] /Length 216 >> stream xڕбnÂ0PGŒär?€ă8v S+(*•©ĐvìP3śi|J>!Ł'Ž‹-•0 ȘČô|>Ùw';cŐrZi êæisőBu ŽÚ(ăàł†°]Ł–4ŻÖŽȘ±ś/>ŸćÊËêl-«-8#+ÿ ‡ęńKV«·5pÖ§Ł9 !NŃ2:#ä-' eÈF/QÂèù4ÚOžțvz?UÀ[ćŰ%uŒĘCœ„-~3eÈ'“ÜÍó_‡h/‰őÏü Ä!;$3ä|ȑˆ.ʍ—»+‘”ÎÍ endstream endobj 754 0 obj << /Filter[/FlateDecode] /Length 258 >> stream xÚuÏœJÄ@đŰæáæÜ|ç’*p*˜BĐÊvAŻŒBŃ:±Čô•ò(ó)SgŁ ČđƒÙ™™-łÂÖ;Jl’PQÛŽŠsœI*ȘÆîJȘÒÂf =ŠôDE–ÚRkőTymóúś‹‡ŁÙw&Ÿ§Œ4ń5•艻zy~=˜x{A©Æ_awIÂŃÌLn7p“‡7 7¶'„_àž7‘Á"Ł żáżhvb­VzeÜ*ìӌVxB(|Z֑–ˌ”{ ÌPtšűŸ ę0aćĘŚ„ÿá7 ű…Đkle` XżxB>óĂŁQŚű˜!lź:sś ” endstream endobj 755 0 obj << /Filter[/FlateDecode] /Length 147 >> stream xÚ352Ńł0W0Đ30P2 ,t ô LL,ő,LÌ ŒôŒLR  LÌ,őÌM €ĐÌĐDÏÈUGr.—“'—~ž‚±%—Ÿ‡‚©!—Ÿ§ŻBIQi*—ŸS€łˆázș(400001`Ìÿÿ7à'ځĥÿ@âß '00C‰F$.—«'W xŸÔ§ endstream endobj 756 0 obj << /Filter[/FlateDecode] /Length 183 >> stream xÚŐË= Â@à mr„ÌÜĘlțLˆ ŠŽòjiĄh-G™#€ŽB@`óÁ{Œ—șDŻrŽÚډ„¶À4Êucfv)^"ŒÏ•ì0s™Ž“ŸĂùŠȘZ™&±2;L2őŸŚU™ê°ÆHòë ¶Đt€e đíԏ>ęœ>>b0»àw@,†ÄśbËTwMڈ!ˆÀÄ=xâŸ8B ʈImkuü“ûÙ? endstream endobj 757 0 obj << /Filter[/FlateDecode] /Length 210 >> stream xڍ˜ Â0†ál-Atu(ő܀i“Ú‚(űftòÔŃAŃMHÀ+óNŒGńÿŠ‚|đÀyá(!YZÎ8‡X0.Ąê Ï@qĆÒ .˜P0a2«±TwKDÂjòóc2§mMŁ1ȘF}P‚Fz«ćzFŁö°źêû©»`Kx$–xx äĘ{ß#âö‹ƒèęć±…çÒWw7mÎS…l*OꗡßűôÖĂb: A9oó):ÍCżé_5y‰!NkڟÛčYÚÓtt@iŒz endstream endobj 758 0 obj << /Filter[/FlateDecode] /Length 250 >> stream xÚUαNĂ0àK3Dò@ßîpŚIă©R‰ •`âhGHPqȚ,’G`ì`9§‰*déóùäłÿRYŻQI„Keń¶ĐR4v%kƒ•ÒR—ž/đMećșDĆ«*ŒÔöÿÄë›Ű6"Á•ù#–…È›~~|DŸ}șĂx>›{ìÁĂ”ƒ\9h#\=ÊBB”2!„”xg:Ê(8Ïô~ÉŽÌĐȚ0ŠùU˜üLx”Ì„tæÒ»Ü›f7ó{ń桎ÄßúïHLàb–nŒÆ CzŽÛwäłĐ“_†țÈ G—X8 Xc5öÄC#žÿ·Ű endstream endobj 759 0 obj << /Filter[/FlateDecode] /Length 218 >> stream xÚmÌ;N1àq¶ˆäfč@ŒöÚûȘŰ *” Rïæf>Šr‘ą]y–È\„ł`:Q\ç“y'ȱŠű]Ì?OEq“$`•Ł€=šËe„ïFęô"‚± endstream endobj 760 0 obj << /Filter[/FlateDecode] /Length 208 >> stream xڝÎ; Â@àńA„-Ì Ì\ÀÍîșy5 QÁ‚V@--m5Gó(9‚„…ÌšMI'Čđ-Sü3 4#\”Š ĂúÓ±ä±ÀP(źÜI<ą(ÊJÍUÒLl,͘żÁQÂü’ùÙϧ˞ùéjŠvźÇl†čk AŻAnĄ?(ŒèuĄEW7܊yö©e^ujšmł_À’ÿ” ÊŰrêÍŐ 0țç€gW5lĄȘš-iÜû„Ű> stream xڍŽ1jĂ@EGšlă#h.Őjw„Ș€œ€Uì*ˆ]ŠHHêŒnŠŁšK«Ò…ÈdVwfàÁÿÿWYŻm «mÀ‡ÒjăŃŚz[ê*àĄÄtMĐŸA#çÓ”œMŒœ«¶SĆ+:§Š șZĘż>żȘhwk,ć?żĘ3ò 9ń1AB ˜€N M+Á˜G> stream xڕÎ1źÂ0 `—HY8Ÿi’6…N ȚCz`âÀȂ™rł„GèŰĄŠq( ÛC–>ÉĂoÿÖdr6E%•Â4—:Ɖ6Reh••łse€±xĐxÆ,/äÔąâÉu&Mń™ŰŸÄČÉÓB$h”HÊ5^/·ŁH–› {ż–żHÔDžš†šč/i‡Œ‹€…śà»@óœfԁŻÇž™xw§Ê;b!û" Äÿ$zÇȘžŠúŁŚ.ŒlĂóșŻ1àB àjÈĆL3ȘbUŠí˜Đ endstream endobj 763 0 obj << /Filter[/FlateDecode] /Length 220 >> stream xÚuÎ=jĂ@à.ÛèyÈjWZę€2ŰDE ©Üì”)’ÚòÍö(s•[OF„Rd>væ1MlßÁYçzë{ÜúÊș€ĐȚÙźAšŒm:œ<Ț~țN_škÛV7ŽŻf3˜rș1ćê֔Ă#>Ț?_LčyÚÂkÿĘ;Ȝ Ӛe€‚ŻD9ÏD+Nٜń” 1ßH<đZ‰gaD‘ ăÂE!%ŃjῂN…ł…Ë/ă‚FÍĐĐDŸh*4/ć‘Hz Da‰zÎ –+ÙÜæù §Uz| endstream endobj 764 0 obj << /Filter[/FlateDecode] /Length 177 >> stream xÚœÎ= ÂP đ‡Â[zsó>ûj'Ą*ŰAĐÉšŁƒąû;ZÔŃAŒŻuP%äùCBrăh\ "„ĐzÒGڐrèŹ%oĐ+C&ǝÆ#ÚČ WąŠć”#S~nląȘ…Ü ”B.0ŚBÖK<Ÿ.{!«Ő»ù9Ö3dnÓÀÜ$€Àwà[Çu"Y€6ÛI'$±ă•}ö{í4YśKúFŸ‰y-ÖĂH±} endstream endobj 765 0 obj << /Filter[/FlateDecode] /Length 268 >> stream xÚ}±JÄ@†'l±°M!ón6č$—TSÁ‚V¶‚ZZ( vÉq/–{“€/°eŠpżł±ò Yöc†ęÿfËŒ°ő–uŽ„t _䅳ăҕ¶nžŰll•ósÆo\ԙ­‡Sm [æg–§WłëLúÀ…3é —•I»[țxÿ|1éîî’3éÛîŠ,łö S4Fˆè$—ąhX”ŚĂ/ú蓓úö-DÖ"ÂÔcÿ‚dB$*ÆLŽ"'êá#ÀiA?hsa—PQ/6J&A<¶˜ô Û«œÈÔApP‚œ€áx†őaŐ œ8F™Ż'…!^ó–> Œ€ĂÌæș3ś?qœÁc endstream endobj 766 0 obj << /Filter[/FlateDecode] /Length 180 >> stream xÚœËM Â0à) YŰ#t.`šÄ€¶«BU0 AW@]șPtĘÍŁôžÀ˜4 ¶‚3đ=ȚÀ(!i9EFC.(“8Ą˜ąe…T(Üs<ĄŹ&Ž”ÈÜ\RQ}~쎀Ń$ßąä$_ąrê^ÎŚɛő }UÏŃ€ÖZÉ·Šśń“]æ5±s‘sà„`zkuçm»ÚiïΚ7~3ù·20?/Ý,4Ù<6Çâ endstream endobj 767 0 obj << /Filter[/FlateDecode] /Length 156 >> stream xÚœË=Â0 àˆŃ—è»Îo›vȘT@"L@°śh…ctjHU0°bëȚłœÇ„‡b„P:¶SmX9žÜłŚ(ŽcSaŻq‚ő–m•¶0[śę±;RHna5É%rC2Źp9_$›ő © c sÄ.öń^nÙÛ«îń·VÔI֋€}ŠĘŽBLÄÇ ™6€ś«R endstream endobj 768 0 obj << /Filter[/FlateDecode] /Length 186 >> stream xÚ͏= A …#Â4Á\Àٝ™ę»eUp A+ –ŠöëÍ^d …lŒ,"ö>ÈËË+^jísŒucâ”ń8ŽÖkŸąËŒv)f&Ńv„ƒ{tÆi#Ï2>‘5ꊬwȘ *ZĄÍT4ĂŐ0 »˜jÔò æ[ÚY endstream endobj 769 0 obj << /Filter[/FlateDecode] /Length 221 >> stream xڝÌϊÂ0đéìÄŸÎ ˜Š1­æ$űìAГWA=zPôȘĘ7ëŁű=Hș3•uő*ù&ù&ŃFöșš€RHWe±k© ۑ=ƒ©ÒR'žŽq‡&”ț ą“ÆFjûȚXmĆ Ń;VDLbeS<ì fCäüˆÙóVY:ßÈśhž°€Ú+ŐŹôèŐùÄ= n!qmqŁOg"çŃđ‰:óÍàɒțÁ•węÜy• ț֗?LQq".§úđĐű§š‰q&æżwìŻ“ endstream endobj 770 0 obj << /Filter[/FlateDecode] /Length 138 >> stream xÚʋ; AD;îÄ#X°§ç»N&«‚y54P4ŸŁy0aĘŐÄœ‚UđàTtAæ TT‘TœÇÌ:рČ4±ßœžˆ“ĆAłDí›l—Ǐă…ÛÂæŰl-›ČĆęö8łiwK țŐČB„iś$šüąè^„JD çłńșđț K Àˆ endstream endobj 771 0 obj << /Filter[/FlateDecode] /Length 186 >> stream xÚœ‹;Â0DŚr‘ÈMސœŽăŰùT‘H€@‚Š%:$|Žp“Áć–E49éÍΎÆj#ë •T č–ÊüÌêF65K[á)Ç+Z*È…,őlrŒˆźÙÙ‹Rdęï·ÇYdĘn‰yÈSìWèž „ä#d' Ÿ`DläoąPD‘OFąÄ§©oglęëżt|ˆ\ìž‹ æ8ÀtO±îĆțSÀ›‚ endstream endobj 772 0 obj << /Filter[/FlateDecode] /Length 175 >> stream xÚœÎK Â@ àĆÂ,ìš 8ïécUš ÎBЕP—.]wŽæQzO`MíBœ€ |!?âŽćEŽ’K‰Jsiq6 '/JŽZq—ăAámixaQR[cxŠ/ö'V{&vh+4~ŚËíÈDœ™#„~XęCÒŠ]€8ŒÈ Dä  zŸÜČj{›¶"»œ}ÿÛ)œ9…Ÿ>9[z¶}ۄG endstream endobj 773 0 obj << /Filter[/FlateDecode] /Length 203 >> stream xÚ}Ž= Â@…GRÛäÎÜì&›«@T0… •­ –ŠÖƛć(s„”)$ășA‚ <æÁÌ{_™„š€Rh2©3œêP*ƒ&™É4Fj§xÔxùîʎ‰"™„ż‡ł(Jì0ŠE°Â(AčÆÛő~A±™Ł¶Ÿ·ćčő˜˜ÀJ9u>œÆÔz­Gßˆ& Dź©¶ČŻ™iÿdnpč…ÿ2Čw0|T6]” „œ«ŸÈUșr‡á€ZùÁËRlßąëŠ@ endstream endobj 774 0 obj << /Filter[/FlateDecode] /Length 224 >> stream xÚ„ŽAnÂ0EšɋäÍ\ ŽíŰÄl@JAjH°âÀȋ"ș->Gá]vÆŰ R«ź*uFzÒițÿFink\”Š OJYn j+čš•äŠÆÄ7Ôă Ż аc#žź~œl_YÓČrƒŐ„•/h4+Û%ï{V6«g”AśČŁË/A )Á  ű Èʔàty$đ_ ü5ĄQRêę7 Âę ÂÛ”ôÎ]űÏìYÄđźF(D±ƒ”žg]ț…ÆùOt7¶hÙúŃuč— endstream endobj 775 0 obj << /Filter[/FlateDecode] /Length 232 >> stream xÚ­ÏÁJ1à”=čÔ7p^Àl6›ŽÙS *˜ƒ`O>€öXPŃs§o¶Č°Ç–Ž“ ő&Hàƒ dț?ÎX挠•ÖĐźTÓ”1^yÎtȘó`MŁÜ^xÛ”Ê[Đ|VN+ÛțzòŒ—›(ë'°ŹïÁYYÇűxÿÜÉzóx<ćoŠ*1$:àIˆË€“"`Z$v\žŰáŠČ0` ž„, gyOőGłÇo{Êæ’RKúžœr«j熄-7eûùé";ïü?9MœùÓ<—wQnżIÒȚz endstream endobj 776 0 obj << /Filter[/FlateDecode] /Length 182 >> stream xÚ­ËM Â0à'„ ôv.`šŽé UÁ,]yuéBŃ”=€‡ÊQ<†‹âDś2đ1ï “%F–)©ùU šŻ© ™RËR‘IŽÌ ÚhÚ“É YhR~LšÊ<ùęXïDeEŒąŽńŒÒ\ÄvNÇĂi+âj1&íó;Ú Ő-vCàŽ.pC\`Wś<țŸͻ_ۅܰ‹>ŒžœáQQ üâՉ©ËGű”è endstream endobj 777 0 obj << /Filter[/FlateDecode] /Length 205 >> stream xÚUË; Â@à )¶Éœ žÙWÜt` A+ –ŠÖY+KŻo’#XZˆăˆÊđ 3đÿ…őȘ š•ÖŹČûÆ*íŃAƒȚU\ÜĄ+ ć=jïœŰÿÆj+‡”̗èŹÌ§è2ŻgxŰ72ÎGhűÿŒő)ŠË@ÜXÇZ«›8ŃC€ôâGJ”E"ŠQ uśîś(G€#wFəc|ŽŹKŸà]kèÊŐČ{ o‚őx5—.%9©ćâ·†\Ž endstream endobj 778 0 obj << /Filter[/FlateDecode] /Length 174 >> stream xڕŽ= A …c%Ì%Ìœ?gv”]œBĐÊVPK EëĘŁíQâ ¶ŽXŒQ l–Œđ^HôAsŽÚZ”ŃNp茶Cˆ:Ë1QśOŒÓQŒR1Š7ÿMìŽȘHÊlp•Y`ȔIKŒœŻeŠŐèL3ä3qʐ4lżxï:]é€wűČŠ’iP!7òË Ä-ôˆĐ'æz@jžÔú Ț­È endstream endobj 779 0 obj << /Filter[/FlateDecode] /Length 171 >> stream xÚĆÎ; Â@à mŒÂ\À}ÎæQą‚[Zy”ŽPŽvŽ–Łä–)‚ëÆ4æÎÀś3㠊"%”m„BXŒá”E hŽp9œ4\K+ ­™™^/Œö\5—°—~ śÛăÌeœ[BÜúqô+ yϞÄҎU)íŁï4ŒțjûcȘ($ĂoĆą@C„ækËTŽO:F|íùț>ȘŒu endstream endobj 780 0 obj << /Filter[/FlateDecode] /Length 204 >> stream xÚUË» Â@ àŠHڐ đ\.čË«Bâ!‘ *J tQ Êb° #PR C’[úüےĂÀȘ$­ŽŽ:…Ą(mÁŠF%<_…1l}8€R‡ č­1* ț?6{9΀·“Jo&’^¶€ÓńŒ“Țx9ŸśzÍŠp(ș‚áÊżpúĘȚz5}zÈ`C7$‡î =*‘*ȘJê!ĘÉiž!óÀ~KÎ<óAKÂŒ’Q‹ËŒĘK‹`PPuŸT„r–ÉŐI^‘Ö endstream endobj 781 0 obj << /Filter[/FlateDecode] /Length 197 >> stream xڅË; Â@ĐDÂêÎÜl’ÍÇFÁž… •PK EÁ.z0œ‰Ç°ÇՀ‹62Û3I€ežĄ’JaI„±]–D%2B™dž qƒșË\ŁČĄăXŠŃśÇb-úFsÔĄÆ§"0Ümś+ô§Ž[SŽfˆL@ÁK(ûrëńŁńÇ{‹ï­/o]Ÿ­ppzÎș—śˆ­qÍW«~óÇS·ÉÄÔgá<땏LbdÄì Cƒ endstream endobj 782 0 obj << /Filter[/FlateDecode] /Length 227 >> stream xÚUÏjÂ@ÆG{PßÀyn6ÙÍżSÁ*˜CĄžúm#y±<ŠàŃC˜élŠűÍÌ7û}›ÄNçm Êh |‰bmșÂê\Zé$ĂïwèÒBg )g­NăgÇŚV-J~ą-TžF›Ș°|ÇĂțűŁÂĆÇFČÿ­ć[è`RĂ Æÿè5ń…#’·4%ŸV§9ńÍŒßggâ,Ä"h<­żvțńĘÛnčG%)WÚúű nˆùQk ÖPÁĐOœŠV„ÚüŃ”…“ endstream endobj 783 0 obj << /Filter[/FlateDecode] /Length 254 >> stream xÚ]ΜJÄ@đŐ‘mź”2/àækś’€xpz` A+@--‹#—KȚ$°čâ˜q6·Dp~Ì–1‰Vy‘Š"à6*à2Ir•ĐEȘr :‰•Éà%†wĐËBe"ꄉ”Nÿ­<żÉu)Ă'H ȚŃ2,ïáóăëU†ë‡ˆ9cy ”@q*D%űm-ÜMłC@c…‹#C…> HŽÉŁ©”4Ô őÔ::òòc5±pìŻ-Wăpa9_!áÄÙĉÄÄÔ3ęLcig<‹ïűá{±ă˱ȚZŸÂfŽ +ŽbÇż‚‡fô˜}ÀÈM)ÖBŰ" endstream endobj 784 0 obj << /Filter[/FlateDecode] /Length 229 >> stream xڝżjĂ0‡e<Žä|/PÙČ%GžùőPHŠŹ†6c†–fNB_Ì}“{L.êi0Íœ8~ßÙÂ(7‡\ć9§Žƒ“Ś`ȘZÍ-TÚšą† Ÿ` ­Źïő§**ĘÿïGčld¶‡ÒÊìl)łæ ŸżN™-·+ĐŸełBê#Nœ‘.b$DŠ·šŸá˜Œ ł[ŒCJ1ö șà™ș€Ž[Æ/Qß^=`Âѱ‡x‘Ÿ"†2ŠS 2„(dæôìÁFì,ٗÍÿv 7ÜĘ„ÈÇ endstream endobj 785 0 obj << /Filter[/FlateDecode] /Length 162 >> stream xÚĆË1Â0 …á̙8»NâŠiY Hd@‚‰ @0·ă(=BÆNWe@\[ßđKvΞÊ–Ź…ł%y‡©cČȚç ç‰g8:\eq€• (ó?/‡łźą6;p©Í 9kŚž]ï'mȘÍNzÌž@ßő©OőšęxŠFš:œD'Ąû:=ÚŻû?i”ššŻZ/ŁȚŸ1­6 endstream endobj 786 0 obj << /Filter[/FlateDecode] /Length 251 >> stream xÚeϱNÄ0 `W7TÊÒGš_€ŽÉ„œȚtҐ`ș”02€`nïÍ"ń"~„ŒȘ–C$Ò'9ȓ?¶ÛamëCg]‡WÎÛ:`hśvŚ`ë‚ő{|vű†Á;ÛHŻìÖ·vțN<œšcoȘnSĘaăMŐßăÇû狩ŽŚè€ț-ûä”3ń#­%Í%€ Qž2Šć GžhbŽĂ™™†L@!! Ìœ•/…/I? ëŹ2°Ț§0)™°n„E™s!•B<’ŚLâ.aÖà©b©_y…V ( JÇ T ń LđéšÛȚ<~EężG endstream endobj 787 0 obj << /Filter[/FlateDecode] /Length 244 >> stream xÚUĐÍJÄ0đ)=rńœ0ęJșíiaU°AO{ÔăVôÜűf_dĄÇ–'ÓȘHàù˜Ițń•łí [èZ[¶x%+E‡źéìÆcS:[uűRâ]UZ/ge4ukëöĆóÁìz“ï±ö&żC_›ŒżÇś·W“ïź±”ù2ío§”‰ tž€ Ł %Êæ„hË ·<*O-Đ L,đÊš"‰pŽœR2b‚ âQ.úAŚâîÏ1üÖj+Baú„yá+ò•IA%‰”!v ëëaI€Ù4ć)æŐäúæ¶7ßEÊV endstream endobj 788 0 obj << /Filter[/FlateDecode] /Length 204 >> stream xڕË; Â@àƀ-Ì2płÙlb¶|€)­<€ZZ(Z›Ü,GÉRАŒłÈ-ùg˜Ti‘Ï@ )Fi`+!5h“ˆ\CkĄ œbž‚ÎŒ˜„ ©3•‰Dÿ~/|Qđè‰áŃRĆŁb śÛăÌŁĆn 1ćO,V€Ű=b덄š<ąśŻ€èBG;'š§ŁFąđˆȚwŒKHt–vîhžDŽÊâYՈęViwhŻRČ "căohÇŚßżâčZ endstream endobj 789 0 obj << /Filter[/FlateDecode] /Length 229 >> stream xڄαjĂ0à3 Zòčˆ,+’ăL7…z($SVCÛ±CKČ쟙Ą/r ±Cđő”–@ČÁ:Ęę'o.—hŽ1èJ—8—ŠYĄ+Vzé±0V[Ż9~ łčöÒ+§°…^žë‰—wU7*ÛáÂ«ì œUYóŒûÏÛÊêÍærÿ»6k \#”Žù>މĐBóf‘42!JN?eYTq›‡–d  2sžđ7|GŸ"đO8ƒg’ ŻCÛł$ìȘQ¶„aB!ț@fŠ4TÄ=0qH™ÔcٶżÒËĆ endstream endobj 790 0 obj << /Filter[/FlateDecode] /Length 262 >> stream xÚmÎÏJÄ0đ‰=ré#t^Àô·=V{ôä” {܃ąçÍŸYe|ƒs('UAA?H˜Éś5emșæ&ϱîLŃᄌä=Ömov ¶EmÊŸ |Áș,L#łrÚȘ3UśwăéšśŁÎ±jtv‹M„łńß^ß:Ûß_a!śŻëxÌn ^!&ö(b@lSK ìŠU±–XđI æ”ŃÀD'früƒ œ7%œ(ȐÒ@B’ÊGÉȘ¶2 A š˜ç ü/ÎÿàŸ™AjÌ(…„Mó ŸJSK>– %Dź!œC …8Tc1é›Q?|{œA endstream endobj 791 0 obj << /Filter[/FlateDecode] /Length 201 >> stream xڕË= Â@`CŠÀ69‚s7Ùd7ÙT‚?` A+[A--­ŐÊkć(ë RŠÇٕA,|ŒaF%’ëbÇ 5މ YÁs™<)`+à2\Ń-M–jžêîÇfÏF%‹V*Í@„,*çp:žw,-Æ šj9;"šzß±ZWCx†Ž}ƒűČ<ą -}ąv s!*WËÍâY|âćZžaKăèwš‡ß˜Ë*ț˃`Ӓ-ßä à endstream endobj 792 0 obj << /Filter[/FlateDecode] /Length 237 >> stream xÚ}O±jĂ0œ ! ĆŸĐûÊ–-9òH[š‡B;e Ž3ŽŽsÜ?ó§Ü'xÔ|•OC(”"xèNï=œçkgÂ+SU肱oÓŠêĐ”Ùxl­3u‡oßŃŐÖűÄM§m‚iÂoĆëIïz]î±ńș|DßèČÂÏŻŁ.wÏwhӜÇț9*&áL pC€5EE“Š+ąbą-4žy<ŒÌtà7óô'E€’"k§b^ŃEĆ5Íń[Êÿ.7ÙÉ«đD!Zqč:+æÿÕ,!%sö[zH#é&-„onŸdŃœ~ù żl endstream endobj 793 0 obj << /Filter[/FlateDecode] /Length 263 >> stream xÚmMJÄ@…+déMސș€ßÎtV Ł‚YÎÊí€ștĄè:ÉÍú(u„^f1LY€áƒWTŚ{Ï4¶;ŹtUagumńR&Հ]?èÁŸît3àSŻŰ5”6Č+Żo­níߏ/j?Șò[ŁÊ[4­*Ç;|ûxVćțț kŃ_rŒF^S&ö pt(èÓšź…üœœŸx‰˜iföŽ0Ó1‰HżđÀ/’ˆ%Bű “8“ăÄ`M€˜ˆž dApÈr<úÚpű XąŃÒĆžN‚{wÊÒĂO”Kč Š-Ɔi•HÒ7“æłcR7Ł:|qęșÓ endstream endobj 794 0 obj << /x28 715 0 R /x29 716 0 R /x7c 717 0 R /x5b 718 0 R /x5d 719 0 R /x7b 720 0 R /x7d 721 0 R /x5f 722 0 R /x21 723 0 R /x27 724 0 R /x2a 725 0 R /x2b 726 0 R /x2c 727 0 R /x2e 728 0 R /x2f 729 0 R /x3a 730 0 R /x3b 731 0 R /x3d 732 0 R /x2d 733 0 R /x22 734 0 R /x24 735 0 R /x25 736 0 R /x40 737 0 R /x26 738 0 R /x41 739 0 R /x42 740 0 R /x43 741 0 R /x44 742 0 R /x45 743 0 R /x46 744 0 R /x47 745 0 R /x48 746 0 R /x49 747 0 R /x4c 748 0 R /x4d 749 0 R /x4e 750 0 R /x4f 751 0 R /x50 752 0 R /x52 753 0 R /x53 754 0 R /x54 755 0 R /x55 756 0 R /x57 757 0 R /x58 758 0 R /x61 759 0 R /x62 760 0 R /x63 761 0 R /x64 762 0 R /x65 763 0 R /x66 764 0 R /x67 765 0 R /x68 766 0 R /x69 767 0 R /x6a 768 0 R /x6b 769 0 R /x6c 770 0 R /x6d 771 0 R /x6e 772 0 R /x6f 773 0 R /x70 774 0 R /x71 775 0 R /x72 776 0 R /x73 777 0 R /x74 778 0 R /x75 779 0 R /x76 780 0 R /x77 781 0 R /x78 782 0 R /x79 783 0 R /x30 784 0 R /x31 785 0 R /x32 786 0 R /x33 787 0 R /x34 788 0 R /x35 789 0 R /x36 790 0 R /x37 791 0 R /x38 792 0 R /x39 793 0 R >> endobj 59 0 obj << /Type/Font /Name/F11 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 0 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87 524.87] /FontBBox[-52.5 -430.2 577.5 923.1] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 794 0 R >> endobj 795 0 obj << /Filter[/FlateDecode] /Length 199 >> stream xÚ]Íœ Â0`€C!KW7ï ˜Ÿ&­q*T3:ùêè (ž©tš|Žű3ˆŃ*vËç ‡›‰…Š)FÌ»Đæ3‰ˆ1Ađ§æ VżLß'ÒwÄßd¶DčBd q‘!p†ˆÁfœ] ’{PőoU}đ.sȚDÎ7éC#Ÿ‘‘–•.łÒŸ™œĘUŽŻ˜ĘÁwŹiŚđgԎ&đ…k.ŸÁĄx„§ÊՖÍûęÒŽáç‡C…&/-œj\ endstream endobj 796 0 obj << /Filter[/FlateDecode] /Length 192 >> stream xÚmË1 Â0à!‹Gđ]À411Ú©„*ŰAĐÉšŁƒą› Ò‹œȚDo1Cé3ĆED??üÏ$ZX RH JŽ„N` „P LbĆĂѶìA'J 2œ±VŒÍÏËöÀó‚ÇZ/@+K8Ÿ.{ç«)ŽęS‹PÓErRć3êÔYÓ«YĘśÌśsipsÙ3@"lʃǗ(èüŐd%ŐŹ$ÒaE/|Q‰îÚCÏR€ˆÏ Ÿ~—1ní endstream endobj 797 0 obj << /Filter[/FlateDecode] /Length 204 >> stream xÚ]‹;ŽÂ0EQDrĂxÀ±±1€ŠĆGš#AĆ€’AÙۋŰHہKo ÓĄ«S\é](n.H1æȘ€Ą\JЅáSZ™·°“pUHź ˆ8m ŸèŻd{`łŠć–ÿ€’,Ż~á|șìY>[Íáęÿo” ’K‘Z‡”y|őƒ ƒ`}Ź+œín»›C€gäuôëd€uJx'Â4ÒûąùđČ …€!o[rŰÆŸŁĘ”!)‘bϖ[ÿÏȘo endstream endobj 798 0 obj << /Filter[/FlateDecode] /Length 208 >> stream xÚuÌ= Â@`Á"°ÍȚ@çnv7ÉÊ6 ț€)­<€ZZ( RXz%ĆÂk$x€łÆ V2_1ȚL ­–€’ŹAH@ „(Đ–ŒŃ"ìÒJіt kHș1V‹Èț^,7l3AȘËü …†ùń”ö»ĂšùƒÙ”Ëߏš*P„šźš[\Źț*ÛÈ9Č3ž  Î .NÜCÛCËCăÍQòșùrú”Ü9!?"u^Hs\ Ü dOdwdúgÙÇlțê"pÛ endstream endobj 799 0 obj << /Filter[/FlateDecode] /Length 236 >> stream xÚUͱNĂ0àHZYH^3 ä^Çź“8Y@* ‘©X‘€‘R'ÔȘ ŒR:ÁcžoĐńËæÔxA§oű„ûïȘN‹FƒR‚©ĆŹ…3-…RP+%:1ąÖđšà*ĘwiŒ4ą©ț7žÙŒgćÌ:VȚ@eXÙßÂÛëû+ç‹KP”ÇŰ_A°]2 CŽ‹6Ń6JŁÉÈùÌsœzŸÿY;ț•ž"O\~žàé ¶Q> stream xÚUË1jĂ0†aQąDÿ*K–ąb0uI[ˆ‡@3ćmÇ)d8!cŻô·KŻaèAÇ,ûîĄhËG±+‹“šklÏuÔ6¶tĆMë»]Àn©ńĘ»żŒ§Hî+Č<üq‚ endstream endobj 801 0 obj << /Filter[/FlateDecode] /Length 186 >> stream xÚUË1 Â0†áˆC%ˆȚ ę/`š4ijAȘ‚\ êè èjGGŻdqđ/àŰĄPSbùx†wűD%”BL 0à”0"–d(ApI$‡ƒ#*I5R’Hü?¶œ(ìo ˆ°żÎ°Ż–p>]öŰOVSšÛКA‘ćZ{(}vÇđê\Ń èȚ2ÚêźSŠźSi·_é‘QÖ<«hLŹO#łtŁČ?čń6đ\áő‡ŸlW endstream endobj 802 0 obj << /Filter[/FlateDecode] /Length 183 >> stream xÚUË1 Â0`ÁAÈÒ#ű_À4“ŠvȘ‚\ êè è,âĆZr‘/P·„±I'ßû–7<K#0Ê€Œr3Î("đDR 1Ąá„p…h.)K€ő•"Ą"ú/$S$<Š$܀à$T[žßgf»%`ż‡©V`?ƖȚË{{coâtȚȧ Œ3ušÁ©OÇ ŹSX(:({m//›\7FźL„Mž/Y+ČÿŠșs endstream endobj 803 0 obj << /Filter[/FlateDecode] /Length 242 >> stream xÚUËżJÄ@đ‹ƒmÒZ™y7û'lä6œ ŠÎÊPK E[śäŠ”y„‹{śk·EÈ:—4ÊÀù˜o*e„Ô …”p!…)áÜHĄTZ‹JBiʰžŒ‚5Z ’ŠŽVTćÿÇŸjxń„æĆ-ƋæȚß>žy±Z_Á1ϱč†Á„1d© őŸM‹ž¶#čێYÏZ2°ŽŒŹ;Èl1ä±Î'ÏÈĄ^f‘öń(RÑùlp#ùƒŃÿŚ=Śûß§ÙïÉĘd‹Ńcêščńnó™ă˜Ÿ^:LlÉè„é+!żiűę/X™‹ endstream endobj 804 0 obj << /x61 795 0 R /x63 796 0 R /x65 797 0 R /x69 798 0 R /x6b 799 0 R /x6e 800 0 R /x72 801 0 R /x74 802 0 R /x77 803 0 R >> endobj 74 0 obj << /Type/Font /Name/F12 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[548.48 548.48 493.63 548.48 548.48 548.48 865.76 493.63 548.48 548.48 329.09 493.63 329.09 329.09 493.63 493.63 385.32 385.32 385.32 603.32 603.32 548.48 1096.95 0 438.78 329.09 356.51 658.17 603.32 630.75 946.12 959.84 548.48 329.09 548.48 877.56 548.48 877.56 822.72 329.09 438.78 438.78 548.48 822.72 329.09 383.93 329.09 548.48 548.48 548.48 548.48 548.48 548.48 548.48 548.48 548.48 548.48 548.48 329.09 329.09 822.72 822.72 822.72 548.48 822.72 796.33 754.68 767.87 809.52 727.25 699.83 829.83 796.33 412.4 562.71 823.76 672.41 960.88 796.33 822.72 727.25 822.72 782.1 603.32 767.87 796.33 796.33 1070.57 796.33 796.33 658.17 329.09 548.48 329.09 658.17 822.72 329.09 548.48 493.63 493.63 548.48 493.63 329.09 493.63 548.48 329.09 329.09 493.63 274.24 877.56 603.32 548.48 548.48 493.63 452.49 438.78 356.51 575.9 493.63 713.02 494.67 521.05 438.78 548.48 329.09 548.48 658.17 219.39 796.33 796.33 767.87 767.87 809.52 727.25 727.25 829.83 672.41 672.41 672.41 796.33 796.33 836.95 822.72 782.1 782.1 603.32 603.32 603.32 767.87 767.87 796.33 796.33 796.33 658.17 658.17 658.17 906.03 412.4 548.48 493.63 548.48 548.48 493.63 493.63 548.48 493.63 493.63 493.63 274.24 274.24 342.8 603.32 603.32 603.32 548.48 452.49 452.49 438.78 438.78 438.78 356.51 356.51 575.9 575.9 521.05 438.78 438.78 438.78 603.32 329.09 548.48 815.77 796.33 796.33 796.33 796.33 796.33 796.33 946.64 767.87 727.25 727.25 727.25 727.25 412.4 412.4 412.4 412.4 809.52 796.33 822.72 822.72 822.72 822.72 822.72 1056.34 822.72 796.33 796.33 796.33 796.33 796.33 672.41 1151.8 548.48 548.48 548.48 548.48 548.48 548.48 767.87 493.63 493.63 493.63 493.63 493.63 329.09 329.09 329.09 329.09 548.48 603.32 548.48 548.48 548.48 548.48 548.48 767.87 548.48 575.9 575.9 575.9 575.9 521.05 548.48 575.9] /FontBBox[-115.2 -507 1267.2 1007.5] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 804 0 R >> endobj 805 0 obj << /Filter[/FlateDecode] /Length 118 >> stream xÚ]‹11 O”~Ć~ǎs1nHJŠCĐót"]ƒ˜­f€őր°6Â&Xçê\.Á–»ja5Ü3j– éGû»\45J§t@ĄÔŽx=ßwJÓi íŸhÛá3tVĂKĄ}Łó’Ç endstream endobj 806 0 obj << /Filter[/FlateDecode] /Length 242 >> stream xÚmĐœNĂ0`W*yÉ#ű^Çù1n§H$< ÁÔFÌéđ}•ŒA_Á[WK"ŽƉą>ʝNw:„/7 žP žI8Ë ^ŹAć9W”Űđ"‡‡ žá|s)AűűëŽ&îŸèVÓt2Łé5ȒŠú^_Țișœœ_Őż©ŸDdˆfŠKbșŐ ír†ÏEàkÄi?ñ©#Ț›Șç`b˜a=•p”MmDŚß4ćĘràĘÂc ‰0„Ï q?pôԁfààoźŠTˆ–ęăz’@›˜ŽŒÿŸ]żÌùUc蕊w?f> stream xÚUĐœjĂ0đ3.Žä|/PYțT<ÒêĄĐL}€¶c†”v+8oWòæŚ0űâMƒ°ĘuˆŃđă@șÓęu]K•Ł’JaVI­ń>ÍeŸE]ÔČĐXU”L5~€xDeR+ô§ÚfČ,Ś/Țbڊä ËB$ÏXŠ"i_đûëçS$»Śô5—í#ÎÀƚœ[ÀșÀ92b‰ ÛÆ331sfbbiÛÆ331KHXÆÄ ÄÄ 'jvî©u Ź endstream endobj 808 0 obj << /Filter[/FlateDecode] /Length 237 >> stream xÚmбJÄ@à)¶É#ÜŒ€›ìĆĘKȘ•SÁ‚V¶‚Z * bÎ'čWŃ'žW,ź=ž&K~7Z˜è0Ì|ü ÓLč§ŐÔPŠČŒLźLN»:WyA…-U9!ĐSșÒtG…¶Ę& e‹‰2fxqy#g•LÏÉj™“ ł:Ą‡ûÇk™ÎNšË?±:$h…QĐÿêżšv?žÿ{Q›ž·X1>eÏçX0ŸŒÇXÇĘóœoŰüš7Źk·bmÆË>Y°¶#NJzèŒȚáœsÛšŸ˜‡żÿQUòì 4‡' endstream endobj 809 0 obj << /Filter[/FlateDecode] /Length 243 >> stream xÚUбN†0đ†&]xnsČ*-$F’OMd0ŃÉPăä Ń6_‹ÄÁŚ`ûVÆ„cÚ»á—ÿpĂę­UòŹ%•‚ÂHká4ŚRW`”‘Șcj™[xÊá ŹȘ„.@­kȘB–exńű*­È Ô"»2Y{ ïŸÏ";Ü]–śŰ^‹G¶ÎĘź sÈÄo‡"ȘħâÄyìs Ûé;ŸĄ!ÆÔgJlj9öY"Y@ßCCŒ©Ï”ŽûÌ1±DȀț…N|FNL;.`ȚYțYÖv»őÄ/ǶÎ~ŽN\·âțś« endstream endobj 810 0 obj << /Filter[/FlateDecode] /Length 295 >> stream xÚUÏ1NĂ0`W"yéÀò_ÇiHœL‘ Hd@ąFlHÉÆŰ#ô*ĘzHș¶b1R•Ÿg›Ą‡OŽ”—śŒŃêȘ&­ŽŠY©ŒĄË,WyE&/•źš,k•zÎ荌źU>#SV3Uç_<œÊy+ÓG*r™ȚQ‘ÉŽœ§śÏ™ÎźÉĘĂ”œĄ^D,DuÎ(bË}ÇûÆòșcہ†-ΐđìțqLyç^ÇŒǘ—ŽˆW`œpXŒM sô_ìXWÚ3\xöQ öŰÀ1:Ą^țÓûè__‘íàÿŸCE°±ž%BÁ i cƒPбpćQŃĆ|‹©Űm1»-oTœZțv-G‹^ĂÄ śœ"o[čű€"ś endstream endobj 811 0 obj << /Filter[/FlateDecode] /Length 198 >> stream xÚ]Ë=‚@`‰…dZ:æ.»žÀZ‘ű“Haą•PK &v`ç±¶ôaË)#D,t^ŸŒŒbTœr‘‚àB@”đ4…ń§”T\kPJò$†ƒ„3LŽæ2ŃF%š«èścbłœ…;ˆŠ,\Á$faŸ†ëćvdál3ÙîÏÌ@6@*‡H#ƒ”gïXm3ô«ąîž†:[R3xôœȚś"üśh•=CTuȘ‚Œ-èe3zb@~ă՚†É8Hè![ælûȘIu‡ endstream endobj 812 0 obj << /Filter[/FlateDecode] /Length 174 >> stream xÚ”Ë1 Â@…á•‘EÌœ 8Ùd™ìŠą‚[Zy”ŽPŽŒx1â1R Ź Š’^yđÁ_<2 -B„ ÍĐ&”҄ZCfS$‚M{ e‘ šzYN˜ëöcœ“…“ń Ž•ń (•±›ĂńpÚÊžXŒ!©û•nyÏąMŐÀ?â1Ș)#æț `î]nÌ]eî4țț&üę•*ôćY+Ä9urù țφ endstream endobj 813 0 obj << /Filter[/FlateDecode] /Length 165 >> stream xÚ3¶ŽÔ3”T0Đ30P04Ö3¶PĐ52Ó37W066Ń3”P030Ò32UH1T(T062Ô32PA3#K=#TÉč\Nž\úá F&\ú &æ\úžŸ %E„©\úNÎ †@>„ëéąđÿüÔCü ôŒțđÿÿÁÿÿ#ę‹țà@?ț±ÿąÿÌÿ7>țÿ€ęÿy.WOź@yÈ endstream endobj 814 0 obj << /x5f 805 0 R /x41 806 0 R /x4b 807 0 R /x4d 808 0 R /x4e 809 0 R /x58 810 0 R /x65 811 0 R /x68 812 0 R /x74 813 0 R >> endobj 100 0 obj << /Type/Font /Name/F13 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[513.76 513.76 513.76 513.76 513.76 513.76 770.49 513.76 513.76 513.76 285.42 456.68 285.42 285.42 456.68 456.68 342.51 342.51 342.51 570.85 570.85 513.76 1027.53 0 399.59 285.42 313.97 599.39 570.85 570.85 856.27 856.27 513.76 285.42 513.76 856.27 513.76 856.27 799.19 285.42 399.59 399.59 513.76 799.19 285.42 342.51 285.42 513.76 513.76 513.76 513.76 513.76 513.76 513.76 513.76 513.76 513.76 513.76 285.42 285.42 799.19 799.19 799.19 485.22 799.19 770.49 727.75 742.1 784.84 699.21 670.67 806.28 770.49 370.9 527.96 799.03 642.13 941.75 770.49 799.19 699.21 799.19 756.3 570.85 742.1 770.49 770.49 1055.91 770.49 770.49 627.93 285.42 513.76 285.42 627.93 799.19 285.42 513.76 570.85 456.68 570.85 457.07 313.97 513.76 570.85 285.42 313.97 542.31 285.42 856.27 570.85 513.76 570.85 542.31 401.91 405.3 399.59 570.85 542.31 742.1 542.31 542.31 456.68 513.76 285.42 513.76 627.93 171.25 770.49 770.49 742.1 742.1 784.84 699.21 699.21 806.28 642.13 642.13 642.13 770.49 770.49 813.38 799.19 756.3 756.3 570.85 570.85 570.85 742.1 742.1 770.49 770.49 770.49 627.93 627.93 627.93 884.66 370.9 570.85 456.68 513.76 513.76 456.68 456.68 693.12 457.07 457.07 513.76 285.42 413.87 345.36 570.85 570.85 570.85 513.76 401.91 401.91 405.3 405.3 405.3 399.59 399.59 570.85 570.85 542.31 456.68 456.68 456.68 599.39 285.42 485.22 656.48 770.49 770.49 770.49 770.49 770.49 770.49 927.55 742.1 699.21 699.21 699.21 699.21 370.9 370.9 370.9 370.9 784.84 770.49 799.19 799.19 799.19 799.19 799.19 1041.72 799.19 770.49 770.49 770.49 770.49 770.49 642.13 1141.7 513.76 513.76 513.76 513.76 513.76 513.76 742.1 456.68 457.07 457.07 457.07 457.07 285.42 285.42 285.42 342.51 513.76 570.85 513.76 513.76 513.76 513.76 513.76 799.19 513.76 570.85 570.85 570.85 570.85 542.31 570.85 513.76] /FontBBox[-114.2 -482.6 1256.2 1009.8] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 814 0 R >> endobj 815 0 obj << /Filter[/FlateDecode] /Length 128 >> stream xÚœN± 1K‡tSx.w—„äÛ$R AĆ@I‚>›ÿGÀvcɖ‚Č„E e`+XȘ¶ˆX”‹`••„àąžĂăÔӝ9GöÛ9ßhŹäOĐL~‡˜ÈŚ=žŚ•üxXC»ÛșAsÍ}ĐÓ_ćŸÓęm+gΛUú endstream endobj 816 0 obj << /Filter[/FlateDecode] /Length 129 >> stream xÚœM» 1»úMáxÉûä”H€@‚Š€’‚ô™ |*À¶dYČćdÂąˆ#ÌÙ3‰Æê0íypôY8Îq\ ƒrj㯜M&‡3…Â’)Źá‰BÙà:ĘNÆíÒò'–%jW»7š=îŐśűu]iUhśȚëdȘ endstream endobj 817 0 obj << /Filter[/FlateDecode] /Length 166 >> stream xڍ1 Â@EìŠń sgw6łYS QÁ-­<€ZZ(ÚëÍâM<‚Æ vVa>Ăÿ>/VLГś™ê€öA©…bƒubòS<0žQ8P“ĐÛ„$T…żÉțm·Ă àV(\^ăőr;‚k7sdËż˜šZê§ĐwĄŻR»™vȘÏzô»ûH Óžÿæ­éû!sŁˈÆ5ș–°Ì°ęÀč„, endstream endobj 818 0 obj << /Filter[/FlateDecode] /Length 167 >> stream xڍŽ1Â0 ES1 ćű8qš4t- ‘ &@@0·œYčIÁ„qĆÆTùËò·ôő~È ÉEk!–dst|á1”PDB»‚šàž–ŹLŒsś9_u•Ž9óÚìÀmÒśçE›ê°ÿłimĂjÁjÎíŒ?sÇüš ^Ôđń ű­Æ-·|úińnd QžB—z›ôń œ*ƒż endstream endobj 819 0 obj << /Filter[/FlateDecode] /Length 116 >> stream xÚ]‹1Â@ CëWìâłû m‰+"AĆ€’"ˆôyzNŠhŰifŠNY Â"ćlhՄ=àÙ9zŽł+žŠ źÆęR9dÿ{<Ț4Jw˜Sș (•ßÏüą4\ĐÚ[––fŚüVÎ…n+~êž endstream endobj 820 0 obj << /Filter[/FlateDecode] /Length 114 >> stream xÚ356Ô34R0Đ30P0ްÔ3ČPĐ54Ś32T062Ół4Q042Đ31UH1T(T046Ś33S0B(UKr.—“'—~ž‚—ŸˆđôU()*MćÒw pV0ò!\O…Í @Đx˜ËՓ+æŒa endstream endobj 821 0 obj << /Filter[/FlateDecode] /Length 163 >> stream xڕË1 Â@ĐR˜&Gp.àìÎf6k*!*ž… •PK Ek âYċx„” ☍ŰÉ͇ÿ}ÎÄ-Y‹ž©pŰc›“”BȗX&ÛÇă…•m“„rśsYn Š`èÌƃ‰SÜïk0ŐlˆÜôO#T}šÖȘ·Ö„uju’W–<»É}ÔÇä{~ęûń5ŚLőŹ ăó7#ç‡r endstream endobj 822 0 obj << /Filter[/FlateDecode] /Length 122 >> stream xÚ]‹» 1D‰·Ši€”gíó'=@ÂD„ (àj»ÂÀș„7Ń{Ò JƒWïÁRŐ ÖÌjD°€5"ÒŽf\‰ČŠßƒW–żËć.cwF·‡ âÚŻçû&n> stream xÚU‹1Â0S_•'ì Î{ö‘8m H€â %Eéyz,šŰifŠ=$S‹ ’ȝÒa}TöđD”ŒèԁX +’»šƒ•.kNÿ‡ù)c‘pG€„ \BčâęÚÆÛVû—ć„OÓ6ßU‘s‘i;ƒ endstream endobj 824 0 obj << /Filter[/FlateDecode] /Length 169 >> stream xÚ356Ô34R0Đ30€ș†æzF† &†z fFzFŠ )† …0!43ŽÔ31CѐœËćäÉ„ź`dÁ„ïĄ`lÆ„ïé«PRTšÊ„ïàŹ`äCžž. öű˜ùCă‡ő @|ˆ|šÿ`đĄțÿ@à Äad=? æ€Ì™} dÈNĘ ì@nárőä Z!jÙ endstream endobj 825 0 obj << /Filter[/FlateDecode] /Length 157 >> stream xÚ356Ô34R0Đ30P04Ś32TЅP&†z fFzFŠ )† … &f&zŠ– @hfh©gb†Ș#9—ËɓK?\ÁȜKßCÁیKßÓWĄ€š4•Kß)ÀYÁȇp=] ÈfűPÿ ÿSűPÿÿ*îbvf@Ă0q°šÿqûÿ Ì bsčzrÂÒq endstream endobj 826 0 obj << /Filter[/FlateDecode] /Length 193 >> stream xÚ]Í= Â0à‚ƒ’„«ƒĐwÓ$mÓĄ*˜AĐÉšŁƒą«-x±ö&9BFi|m\”đ‘śxIÄ)À(cÀS*8LĘgœf $T$päpXÆ4Ɂá“<§±ü8œIĄHž‘’p ‘$ĄÚÀíz?‘°Ű.€cîR”„*šÁó+ŻÓĆÆÖÚŰ=Ń@›všÍÛG6Żč6éYmjT!ŻtFXŁ öÎĐçZd‡nWżłùÒœÿûd„ÈîÌu] endstream endobj 827 0 obj << /Filter[/FlateDecode] /Length 130 >> stream xÚ356Ô34R0Đ30P06Ń31TĐ54Ś32T0±0Ôł0P030Ò32UH1T(T011Ś3¶T0B3CK=3TÉč\Nž\úá Ff\ú Æ@ÒÓWĄ€š4•Kß)ÀYÁȇp=]˜ÿ@Æêi…0`ĂhÀËՓ+3ug endstream endobj 828 0 obj << /Filter[/FlateDecode] /Length 178 >> stream xÚUÍ1Â0 ĐÌYè ê ÄiÚ©R‰ H0q`D{nÀ•@ œqł1 U‹¶žì?XΚA „{B#t›‘…PFiĄ3X l ÍQä ê6XˆÔü_ÌWŒČ\Î@ç\Ž 1\Ú1ì¶û%—Ő€èsí\é"V2ÆbÆ\ì"ЉèžÎȚ­umĘéWÚșńüRDŻÀ; 8ò?‰ujGżŸˆ-Ÿ~€‚ő endstream endobj 829 0 obj << /Filter[/FlateDecode] /Length 187 >> stream xÚm̱‚0à& ˜.ŹnȚ XzŠŹš‰ &:ùêè ŃJ\|,|±‚ƒÆ4_Ò?wÿE T …”€±PÓ !B„șKZ*Ą"8 œ!L!$=hĄőwcâiÆęš„û+bîgkž^nG9 ć>f 0Ź”ŒMˆg sm“;¶)Jò$©TĂŹìw»ușńțç€pś„}Ï0æV‘ńêqÛÚ_f|ûŒ·q… endstream endobj 830 0 obj << /Filter[/FlateDecode] /Length 197 >> stream xÚUËœ Â0†áł\Dr“r `ljă*âO"T ” šÁ°RČI$ €@9ș§ùôêČTK`,ă3-m‚ƒÔHŁŃX#ł­.€±žŐx@ŁYäûłY*‡ùÿÇf/ƕPkLŒPsL‡BU <Ï;ĄÆË jżżłšbÇîO=€ŐȚ‹čŽqò\Đk> stream xÚ356Ô34R0Đ30P04Ś32TЅP&––z† fFzFŠ )† … &†z hfh©gb†Ș#9—ËɓK?\ÁȂKßCÁیKßÓWĄ€š4•Kß)ÀYÁȇp=]û‡:ÜÿĄ^àÿ‡ú4Ă@[ț10ƒ1ˆÍćêÉíwo endstream endobj 832 0 obj << /Filter[/FlateDecode] /Length 185 >> stream xÚU‹= Â@…'lŰÆ#8płłníÄ0… •PK Ek#čXÀ‹ÌRŠźŽ‘áăńńȚ€c2äĐk1%“9Qn‰d}xrfšă‘đ‚>ó&ą•óckhòÿq8ëyĄ“=ș\'kt©NŠ Țźś“NæÛ’űW‹%6Qà\ÂPđł‹ùùVü ŠCš8Ž’ žXšUĆćŁâH:%Ä?”ì{JÙŚÈĐÀ :Ő ^zśȘžN endstream endobj 833 0 obj << /Filter[/FlateDecode] /Length 177 >> stream xÚ356Ô34R0Đ30€ș†æzF† &†z fFzFŠ )† …0!43ŽÔ31CѐœËćäÉ„ź`dÁ„ïĄ`lÆ„ïé«PRTšÊ„ïàŹ`äCžž. őÿ?0ŰCpÿÀ‡-ű?üP`țđƒˆ ~0?0űÁÿÁà‡ü0¶ÿĂÁÿ°` ž<Őń1;Pó 9ó€æț©ÿÀćêÉ‘bmÎ endstream endobj 834 0 obj << /Filter[/FlateDecode] /Length 169 >> stream xÚ356Ô34R0Đ30P0łĐł0VĐ54Ś32T011Ś3¶T014Òł4WH1T(T06·Đ35S0Bc=C TÉč\Nž\úá FF\ú FŠ\úžŸ %E„©\úNÎ †@>„ëéąđżAæË† ìüghüßÒűÿ3±Ł"ˆ`ăÿ#ÿ€*ŰuőòücùßPĂćêÉZœCî endstream endobj 835 0 obj << /Filter[/FlateDecode] /Length 185 >> stream xÚu̱ Â0à „L}„{“\ÚÆ Zì è䚣ƒą›KȚÌŸI!c‡bL­‹ Çqś_– J(…I*RÂ!„&ÌÈtÍ(-t†Â3Š9‰\aW†Æ"5߉ę‰%—;Ô9—+L —ćŻ—Û‘Ëb3G s?– ômä|Ăzmà«ÿlćZ˜č˜sA=aîᙳȚŸEáŠ3űĄßÙÏmÈ=ƒ{ű7ĐÂ<«cŸ,ùöő9zb endstream endobj 836 0 obj << /Filter[/FlateDecode] /Length 174 >> stream xÚU‹1‚0†H0éàô]ÀG_ TÔD<€::htŐâÉzâ ™ZQăÿ}Ë7ü©"$ …€”0“0!’ I4Ș’˜kŰœ@ć)ê DOąÒôÿ±;òČâń€âńdÊăj—óőÀăr=êû›ŐŒqŽ”,jŠÈú öÚ›đ­eżoíĘ4cÖČ c‘cCon|QńÍ &< endstream endobj 837 0 obj << /Filter[/FlateDecode] /Length 154 >> stream xÚ356Ô34R0Đ30€ș†æzF† Іf ÊÌÀHÏÈT!ĆPĄ&T§`fh©gb†ą!9—ËɓK?\ÁۀKßCÁیKßÓWĄ€š4•Kß)ÀYÁȇp=]êÿÿa°‡à țÛ°ÿùaÀüç3>šùÁÄüj~ÈC±=ižù cƒŰ\źž\2©q[ endstream endobj 838 0 obj << /Filter[/FlateDecode] /Length 144 >> stream xÚ356Ô34R0Đ30P0łĐł0VĐ54Ś32T011Ś3¶T03ŽÔ31SH1T(T06·Đ35S0B3c3=33TÉč\Nž\úá FF\ú@Ő\úžŸ %E„©\úNÎ †@>„ëéąđżÿÏ?fùÿ5°ÿa`Ą l3Éš € .WOź@ÖŸh1 endstream endobj 839 0 obj << /Filter[/FlateDecode] /Length 192 >> stream xÚ}‹œ Â@„R‡ O û^n/?&Š?` A+[A-…â|1}Ł+ŻÓ=SÙÈò±3ĂL‘$J*…Ô—š°Wż8Ï„"L•–:Áá ăŒdŠĐ_JčŒÓßĆö ƅŚš3Î1JEX,đrŸîE8^NŰڶ˜bő~[05ățqćJhńÚÖĘœ·Ź+»Ö‡ÖmŒu#î`œ7™wÜőó`^ÌÓVȘ €Çk1+Äêőyp endstream endobj 840 0 obj << /Filter[/FlateDecode] /Length 132 >> stream xÚœ‹œ B1ƒą»)Œ—»ËĄ}€D $š()@Đg5&{„bl’]8ze5‹ *'ĂB—lА•ł ‰±E\w/ŹҜtĆ!ę>Î7 č,’ÛÁ'reçău%7Öжû,ÔùT‡Y§6Šś©ĂĐÒőíŽ-tü|5}Ÿ endstream endobj 841 0 obj << /Filter[/FlateDecode] /Length 147 >> stream xÚ356Ô34R0Đ30€ș†æzF† Іf ÊÄĐHÏÒ\!ĆPĄ&T§`bl ghą!9—ËɓK?\ÁۀKßCÁȔKßÓWĄ€š4•Kß)ÀYÁȇp=]š›üa`lša``°i``y`À#ó BNæÁ;0~űŁŽdÜP!ÇÂ`ÀĂ 6—«'W {·G– endstream endobj 842 0 obj << /Filter[/FlateDecode] /Length 145 >> stream xÚ356Ô34R0Đ30€ș†æzF† Іf ÊÄĐHÏÒ\!ĆPĄ&T§`bl ghą!9—ËɓK?\ÁۀKßCÁȔKßÓWĄ€š4•Kß)ÀYÁȇp=]jŰÿ00ÿa``űÓÄ?Ôü`bț5?äĄŰž4ÜÀ|€…hƒŰ\źž\ûDN1 endstream endobj 843 0 obj << /Filter[/FlateDecode] /Length 160 >> stream xÚ356Ô34R0Đ30P05Ô33RĐ54Ś32T013Ń3”T014Òł4WH1T(„± €ĐÄŰ@ÏĐUGr.—“'—~ž‚‘ —Ÿ‡‚‘)—Ÿ§ŻBIQi*—ŸS€ł‚!ázș(üoüÿ‡Áțƒüț6ìț37țolțˆŰÿ?@CÌÿ@€€j€*êș€z&Íárőä }E` endstream endobj 844 0 obj << /Filter[/FlateDecode] /Length 183 >> stream xÚ356Ô34R0Đ30€șF&z– &†z@ÊĐHÏÒ\!ĆPĄ&‚fŠÆzæš:’sčœ<čôĂŒ,žô=Œ€§ŻBIQi*—ŸS€ł‚!ázș(4Tđ`P`țÀÀÀűĄĄàóƒü ~Èÿcû? ü ŠËƒ0P?łő1(űÁÀđáĐŒ@sXÈűaÿŸ n`țÿ‚Al.WOź@ć pw endstream endobj 845 0 obj << /Filter[/FlateDecode] /Length 183 >> stream xڍŒ= 1…[(9Ć\ÀüŻ»i,VSZy”ŽPŽ6{łe ĘČ1;±áƒyđȚWjÉ€Á„m˜‘0QF0+ ÔšF*f+8H8ƒ±– "ĘŽÔŹźŸ&ûmć;P–òèšr·†ëćv€ŒÙÌAŠü‰nŃ?±'€H>ƌ`žôŃc™G?(2!śÚÔńł<ƒođFßaŒГq|’I?]:ș}j§†I endstream endobj 846 0 obj << /Filter[/FlateDecode] /Length 158 >> stream xڅË1 Â@Đ Ê"€”ó_ÀÙÍÆ$mTp A+ –Š‚eŽæQrY]‰…V2<țÿĆ䙰X6R°Lșp„piàÄrU`/8ÁMçL<—–òścwT”Wz [(œ„Í•ö+\ÎŚƒÒőz‰»›~Žf|o)%АšE7 É!y¶Ąőż€ÿ5”¶ôńîjáŐæv4NŰ endstream endobj 847 0 obj << /Filter[/FlateDecode] /Length 178 >> stream xÚU‹; Â@ż@`Yđ)ț žÏyì“Đ;,\7 ~#ńˆü/ŰwĄï'ßašŸplĘČę.6O endstream endobj 848 0 obj << /Filter[/FlateDecode] /Length 161 >> stream xÚuË=Â0 àT*eáőp~œPX Hd@‚‰#v­Gá™™ŠŹO~OČ=44j ŠAk`š—s Ò<: 'Wp€ŃÌA§ń^ăŒ~?ŽÙ©`œT +UŰÂęö8KŐî–`RÏ5Ź Ö‘‡É8% Q|}òż»qŻ€ÙS URv…àÈÇźâŰŚ,ŚAîß`u_† endstream endobj 849 0 obj << /Filter[/FlateDecode] /Length 143 >> stream xÚ356Ô34R0Đ30€ș†æzF† Іf ÊÄĐHÏÒ\!ĆPĄ&T§`bl ghą!9—ËɓK?\ÁۀKßCÁȔKßÓWĄ€š4•Kß)ÀYÁȇp=]êț0Ű1Ԁpƒ=CÍûdâ@| æ‡|CÍ–? ÿAžÁ‚…ËՓ+ï4N endstream endobj 850 0 obj << /Filter[/FlateDecode] /Length 158 >> stream xÚ356Ô34R0Đ30P04Ś32TЅP&––z@ÊĐHÏÒ\!ĆPĄPÁÄÂPÏÂ@MŒ ô -Pu$çr9yré‡+Ypé{(™ré{ú*”•Šré;8+ùź§‹B?ƒƒŰ?ê~cûƒțۆăòípüŸŸÛ䞈Ű#đƒúÿËՓ+ńmUh endstream endobj 851 0 obj << /Filter[/FlateDecode] /Length 166 >> stream xÚ356Ô34R0Đ30P04Ś32TЅP&––z@ÊĐHÏÒ\!ĆPĄPÁÄÂPÏÂ@MŒ ô -Pu$çr9yré‡+Ypé{(™ré{ú*”•Šré;8+ùź§‹Bƒ|ƒ?ƒŰÿÿ(@Æț(űđÿ<(űđá€ÿ8`űáÇ1(vS„`~Æű™áűŸ|û.WOź@”êW~ endstream endobj 852 0 obj << /Filter[/FlateDecode] /Length 203 >> stream xÚ]ËMjÂPà…Rw`î|y1ŸQ@[đ :rêĐAK;¶ mUâBź;ÈĐAéí5IĄÈáƒs'sF Zi Î+o`hœVAƒAiȚXrXx?ò*  9ŁÌ©q~sYmć$Êt 6—é ÜXŠńȚß>62Ì§`x·3>=!ÜkȘ°ȚUxi”x)Jünôń'é €Ç?ÒĄsb_»^ęËčsdaÉîöìđŸO(Űg B$Bùć➆{ endstream endobj 853 0 obj << /Filter[/FlateDecode] /Length 183 >> stream xÚUŒ=‚@…ŚPlă˜ žìÀ"R‘ &naą•PK ÖNÂĆèŒGے‚0ź?…Ηyy/™yYŠ ĐJkH2ÌU‚`ŠFeLT‘Ăá &Ő g =_ûś±?ÉÊÊxI&ăŐ[íź—ÛQÆŐfèó'Ú4B /ß­™šæŐC@>$îÆÄ."nKâæNübÄ4L}Èԍ;r‘méDsw‹ßń$—VnŸ·żFe endstream endobj 854 0 obj << /Filter[/FlateDecode] /Length 187 >> stream xڍN= Â0-8rę.`~š4M§–Ș`A' ŽŠÎ„tđZéMz„ŽŒMJA7y<>|ï'æ ł(ŠžÀ‚ÁrżŹL—Í|§ëvÜ· m4:|)öx endstream endobj 855 0 obj << /Filter[/FlateDecode] /Length 150 >> stream xÚ„K9Â@ •‘_áà]g7^ÒŰ *” è#Qđ<ŸăBšš™™bM„„$ÏȚÓTÙGšHâR(ÆÄĄ&•šŁÒ^èDA…CEŸ§eŐßÇîˆMF·„RĐ-)$tyE—óő€źYÏšoó7æ9uëîցœ=Á Ź+ÀF`7űLȘ-ÆĆ€Țà"ăæ ”VZä endstream endobj 856 0 obj << /Filter[/FlateDecode] /Length 199 >> stream xÚU‹1nƒ@DmŽ Gà_À YQYČ)‘’*H\ș°ew–l*_k}“=é( i2óš§Ń”k6”ë<§’”3ŽâJ&ëŹ.kr\këè‹é@–ź+ʧșÂiçț?>śjӚ샌UÙ •ÊšW:Ï;•mȚ¶Ä“ÿjóDc„^Ź;‘zû‹l!%Z‰‡„_wÌű…Đ 1Æô)ș5Âu#ŒCŒ>A—~‡kđ7ń—›ˆÔsŁȚQS]€ endstream endobj 857 0 obj << /Filter[/FlateDecode] /Length 196 >> stream xÚUͱ Â0PG."čÉÜ8±c;I…@ÂT ” èRàÍ1+žcŠ(‡hĐœæëtśu.žń,-ž‘0ÍW”Q\W`Dƕƒ€3(!yU@Æèœ—ĆÿĆțÄjËÒHĆÒä%Kíź—Û‘„őf"äoŽ ŸÉ̓€%qÛP‡sŰì^Ű!șƁb#I2 ÄŰSÄhܶ#ÿDOڑ‹0ș74<śdŠB[Z¶ęĐ]É endstream endobj 858 0 obj << /Filter[/FlateDecode] /Length 183 >> stream xÚuË1‚@P:’m8s—v] Ò &R˜hćÔÒBŁ”&\ ÂE8%qę gò’?3™©fÉ1)©i# ӄ3™”eȘÈr&„#ӅŒI€ÎHĄ­¶ÒÚߏĂY䅈ö[­I'"*6t»ȚO"Ê· bÌăX,É aćú rĘW 54P‚?zŐę AŐAëF54P‚žçÍœo=‘v”žăăYŹ ±{@”iè endstream endobj 859 0 obj << /Filter[/FlateDecode] /Length 184 >> stream xÚuÌ=Â0 à  •Čp|òŚ$U'€`âÀȂ žV*FźĐ#02aÒ21 ËÓłmSƕÉ„«žÓĐO 7 Œ3Üæà€æÚÂJÁŒÒ<Ï@Æq©ăÎę^,7ŹđL,@&&fLű)ìw‡5Ćl*æoô#$ „¶’ ń/‚ é6û'Z!œayošĐȘX_±ŠĐ*ŁéćÿwŸ€ś"çwÙŰłùÏ4_k endstream endobj 860 0 obj << /Filter[/FlateDecode] /Length 198 >> stream xÚUÌA ‚@àżf!ÌŠ#ű_ ŃŃqTˆ+ÈEP«P-[”ÎÁ‹]Ä#žtęAŒoóïEĄ2@_ű>FRèÇĄJąÒJD)j™ „q/ń„J"Ń·ŃQ(’ű±;òŒàȚĆœ%† śŠ^ÎŚśòő „íßZ̑Z—Ê{ëÓșŠÍLs35YCdUDŹ€!d.€SÄd,FőGóSőjCőœ°WŹ™8-Œ:p_QI|QđÍìÈWK endstream endobj 861 0 obj << /Filter[/FlateDecode] /Length 177 >> stream xÚmË1‚0`C“.ÿ¶Ú j"ƒ‰N@4:ăž’Ț„#8:ž :˜űȚ·Œá™X Q(Œ6ąQŹ…V€­&#«2Ą-míI«Hd …]­‰Ešü>Ö;^”\ź(Ò\Î(Nč,çt<œ¶\‹1©nłœP8Žë|Ăà2xUËĐűxv<ò^}F ܀;py»ÀzíÀÿhÁm>-ùòQb endstream endobj 862 0 obj << /Filter[/FlateDecode] /Length 185 >> stream xÚU± Â0†Y\ĘŒ0É„IÚNBU0ƒ “ ŽŠź…Òk߀àè ēBQî_îżÿûÏ„(р–ZƒCé ÌS+-‚őVș<Òz8!\Áą‘EšÆ»TæÙ?qŒˆ2uc…Ú@š ¶pż=ÎB•»% íĂVY|łĆ“MzÆÛ*©cĘÄ.‰-ę(rÈocÒO9%)ÿbł/Rń.6t%ęæIÔ0RTKćHïÄ:ˆę~PXÿ endstream endobj 863 0 obj << /Filter[/FlateDecode] /Length 206 >> stream xÚUŒ1jĂ@EGšXŰÆGđ\ +­ŽZYŰD…!źÜl—)ì.`-șۘ\ÄGPéBägCÀțk^ń_UZc ÎMžse/űĄtÆYvȚ™Șaoă<ï-żłł…ijÎă|UšYęÿ±{ÓóVg.œÎ^žœéŹ]ńńătĐÙüuÁ6úŸ¶Ka€óŠWšÈŁ’oöèS„ő‹ÜI!=ș€N@òIWąh€-" DŸĐÇHˆ©Q…Û$ SĄ'Ąó`TĐÏ­^ÿp°Z endstream endobj 864 0 obj << /x5b 815 0 R /x5d 816 0 R /x7b 817 0 R /x7d 818 0 R /x5f 819 0 R /x2e 820 0 R /x2f 821 0 R /x3a 822 0 R /x2d 823 0 R /x44 824 0 R /x46 825 0 R /x4b 826 0 R /x4c 827 0 R /x4e 828 0 R /x52 829 0 R /x53 830 0 R /x54 831 0 R /x61 832 0 R /x62 833 0 R /x63 834 0 R /x64 835 0 R /x65 836 0 R /x68 837 0 R /x69 838 0 R /x6b 839 0 R /x6c 840 0 R /x6d 841 0 R /x6e 842 0 R /x6f 843 0 R /x70 844 0 R /x71 845 0 R /x72 846 0 R /x73 847 0 R /x74 848 0 R /x75 849 0 R /x76 850 0 R /x77 851 0 R /x79 852 0 R /x7a 853 0 R /x30 854 0 R /x31 855 0 R /x32 856 0 R /x33 857 0 R /x34 858 0 R /x35 859 0 R /x36 860 0 R /x37 861 0 R /x38 862 0 R /x39 863 0 R >> endobj 119 0 obj << /Type/Font /Name/F14 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 0 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12 531.12] /FontBBox[-53.1 -430.2 584.1 923.1] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 864 0 R >> endobj 865 0 obj << /Filter[/FlateDecode] /Length 227 >> stream xÚ]Ë1JÄ@à‘iöù/àd&™É&ÍVSZy”ÜbEÁ.ŰyÁ«€Žó él#6#„yÎ7»țǏǟ©T𜀐’ÒLš”ŽU"€&3υÊÈšč(RșUŽ&Łę’ôg’BùáÇ͊/+_“6<>'­y\]ĐĂęă——'€|juJ€ĘKWOmË©ïŃÎ—ÙÆŚ=áš[ë=ž'ț ęBS[|ŁęDWnm‹¶~ÀzßĐÏ-á7°źÛ–À‘”¶{b!:ÆùYĆŻ~?°ć_ endstream endobj 866 0 obj << /Filter[/FlateDecode] /Length 186 >> stream xÚ355Ś33Q0Đ30P0±Đ3ŽPĐ54Ò30Q054Śł4V050Őł°TH1T(T01łÔ37U0Bš,ŠŽä\.'O.ępcK.}c.}O_…’ąÒT.}§gC ÂőtQ`90ńƒęÿč?üÿÿ€ˆÿ| ąNœĂB<ƒö`â2ńNü 0ÌE’EÖöFüGŸ°àÄ!Ń"ۀźÿÁò„àrőä @ Ą) endstream endobj 867 0 obj << /Filter[/FlateDecode] /Length 129 >> stream xÚ360Ò34U0Đ30P0±Đ3ŽPĐ54Ò30Q023ŃłŽT050Őł°TH1T(T024Ół0T0BSCs=KcTÉč\Nž\úá †\ú &Æ\úžŸ %E„©\úNÎ †@>„ëéąÀ?Űüá§+Ú±šËՓ+ł’_© endstream endobj 868 0 obj << /Filter[/FlateDecode] /Length 227 >> stream xÚmϱŠÂ@à…+Ûű™žÍźÙ›Jˆ ŠŽČîźŒâ-„äA|}‚{…t¶‚Í KÆ5JŒæ˜żűŠ'#&5pÆ9Ḧ́†WŃe\Bk P\1Ă»€/ˆg2îF‰‹ĂÇÆÛ'MRÌAIŒA†4H'°ü^}Đ ™@ž|éH·„xŽ_b*Ö¶ÂÚÜ5;ÄrńLh‹šC†§ŠÇ;ÖÇęČƒ-ĐĂMƒûmveÖ žì3‡Ÿ&&üśhÉÜùšÂwlŚä}CÈ :Jéì ő= € endstream endobj 869 0 obj << /Filter[/FlateDecode] /Length 225 >> stream xÚUËœNĂ0`G,yÉ#änL8vóÓtȘT@"x@L  2'úZ‘x»uÍèÁÊ„ŚŠt€Oç §±„¶-m T-ŚK»ĐŠ‚șiŽ]@mjĘźàÉÂÔv©W%˜S~êżÇă«ÚtȘx€ȘTĆm°»ƒĘûÇł*6śW`O;ÎîDFN!Y'‰ú”è}ˆŽèÇhÏ⚝ą9ë2ÖË_甄$žÁ±g1șf§œu룒S–ąIpŽ/,F/ŰIČî>8Ÿu=Qô€˜}ĄHÏQĘtjû 2€âĘ endstream endobj 870 0 obj << /Filter[/FlateDecode] /Length 223 >> stream xÚĐœjĂ0à” -y„Üš,ےSO†Žz($SVCÚ±CK;Ç&/æGčàŃƒÉ‰Ü«BČfùĐꜣ]°À”ŰL’ŰzûàĂäì>ŻïËÓëőuÉ6űŽó ä—.Ò+t”ŸÒęïÔŠR» ÂïȚŽ endstream endobj 871 0 obj << /Filter[/FlateDecode] /Length 180 >> stream xÚ­= 1…W,”4¶vΜ$fČÉV‚?` A+ –Š‚Çő–)âlĆÂN>x0ïœk– •òš= őU=U}; G ČX:P> stream xڍÏ; 1àXÒ€”Ûč€ÙِHR >À-­<€ZZ( v«ÇČô{Ë‹1Ù|€`̐™ŸtQ 4€”™ŽT-h‹Bf Q ca™ÁŽ o%`žZZaÍçÄbÍú9Kç 4KÇ Kó ì¶ûKûÓdĄnÊ|„Â» śÎQßòźâțR{ëE]òČâ”ôùślł­ÙSêÄ`;wZśOoéeńșęiòË2ÊŁîé%ü±ąWBzwzúcۇSŰ(głˆ›Æ endstream endobj 873 0 obj << /Filter[/FlateDecode] /Length 162 >> stream xÚ3”4Đł4W0Đ30P06Ó34VĐ54Ò30Q055Ń30W050Őł°TH1T(T054Śł4V0B(EGr.—“'—~ž‚‰1—Ÿ˜ôôU()*MćÒw pV0ò!\O… €’ÿŰPhÿÿ țB?ü&ÿ+Ì“ò ’BڃÈ\äù`°’ @/üÀÀP%č\=čË Ęj endstream endobj 874 0 obj << /Filter[/FlateDecode] /Length 235 >> stream xÚ]Í1jĂ0`—  Í ’wÊ’k9ÖCÚB<„¶SĐvìВźUr’\Ć7èČșdQ@èEБӄßăççńr~KyŒ2iF™„›v ÉhÊA0A Ż>@ä9ć)07"•Tç/ïdR‘dو$SÈ2’T3X|~œ‘dòtÜć6VśE ëš”é!6Ś:FÔă4ăŁßÖk­k”Eç>žBÜ—ˆżkÄ­Sy7 ‚M‰ëÎĄW± šŸU±qÚŰ`{û“WȚŐλ> stream xÚ”Ï1nÂ@P# €-Â<ÈzŚö»  .HĆ %Eą€}“\….eźà.­‘ŹùxŚ4 úғ~1#ęDGR§€€RÆReôšC©b2™’Ą&ٌL3Úiz#“$R‡€ú=“YtQÄ"Á–â™VG"ÈŚôńțčÁbóLșïCÍ_ÈóJÔȚ`3š‡ź·}r~±•1.Œ 89όc‰?F=Ǐó—ŃűűfŽSűÎ9Ł›pÉàq7Fkurž­ÇÂZOœSkălęÿÒęç~ńM±ÌĆëŒćv endstream endobj 876 0 obj << /x61 865 0 R /x65 866 0 R /x69 867 0 R /x6d 868 0 R /x6e 869 0 R /x6f 870 0 R /x70 871 0 R /x72 872 0 R /x74 873 0 R /x76 874 0 R /x79 875 0 R >> endobj 167 0 obj << /Type/Font /Name/F15 /Subtype/Type3 /FirstChar 0 /LastChar 255 /Widths[413.23 413.23 413.23 413.23 413.23 413.23 613.18 413.23 413.23 413.23 235.5 368.8 235.5 319.37 494.32 494.32 377.69 377.69 377.69 610.96 610.96 552.64 1105.29 0 436 302.15 424.34 1046.41 802.03 1024.19 1313.01 1535.18 552.64 319.37 552.64 902.56 552.64 902.56 844.24 319.37 436 436 552.64 844.24 319.37 377.69 319.37 552.64 552.64 552.64 552.64 552.64 552.64 552.64 552.64 552.64 552.64 552.64 319.37 319.37 844.24 844.24 844.24 523.48 844.24 813.69 770.65 785.92 828.96 741.49 712.33 851.18 813.69 405.46 566.53 842.85 683.17 988.65 813.69 844.24 741.49 844.24 799.8 610.96 785.92 813.69 813.69 1105.29 813.69 813.69 669.28 319.37 552.64 319.37 669.28 844.24 319.37 613.18 579.86 590.97 624.29 557.64 535.43 640.95 613.18 302.15 424.34 635.4 513.21 746.48 613.18 635.4 557.64 635.4 602.08 457.67 590.97 613.18 613.18 835.35 613.18 613.18 502.1 552.64 319.37 552.64 669.28 202.73 813.69 813.69 785.92 785.92 828.96 741.49 741.49 851.18 683.17 683.17 683.17 813.69 813.69 858.12 844.24 799.8 799.8 610.96 610.96 610.96 785.92 785.92 813.69 813.69 813.69 669.28 669.28 669.28 930.33 405.46 624.29 494.32 613.18 613.18 590.97 590.97 624.29 557.64 557.64 640.95 513.21 513.21 513.21 613.18 613.18 646.51 635.4 602.08 602.08 457.67 457.67 457.67 590.97 590.97 613.18 613.18 613.18 502.1 502.1 502.1 702.05 319.37 523.48 698.44 813.69 813.69 813.69 813.69 813.69 813.69 974.76 785.92 741.49 741.49 741.49 741.49 405.46 405.46 405.46 405.46 828.96 813.69 844.24 844.24 844.24 844.24 844.24 1091.4 844.24 813.69 813.69 813.69 813.69 813.69 683.17 1194.15 613.18 613.18 613.18 613.18 613.18 613.18 735.38 590.97 557.64 557.64 557.64 557.64 302.15 302.15 302.15 302.15 624.29 613.18 635.4 635.4 635.4 635.4 635.4 824.24 635.4 613.18 613.18 613.18 613.18 613.18 513.21 902] /FontBBox[-153.5 -478.2 1688.5 1005.1] /FontMatrix[0.001 0 0 0.001 0 0] /Encoding 7 0 R /CharProcs 876 0 R >> endobj 1 0 obj << /Creator( TeX output 2005.12.19:1143) /Producer(dvipdfm 0.13.2c, Copyright \251 1998, by Mark A. Wicks) /CreationDate(D:20051219114329-03'00') >> endobj 5 0 obj << /Type/Page /Resources 6 0 R /Contents[15 0 R 4 0 R 16 0 R 17 0 R] /Parent 878 0 R >> endobj 19 0 obj << /Type/Page /Resources 20 0 R /Contents[15 0 R 4 0 R 24 0 R 17 0 R] /Parent 878 0 R >> endobj 878 0 obj << /Type/Pages /Count 2 /Kids[5 0 R 19 0 R] /Parent 877 0 R >> endobj 27 0 obj << /Type/Page /Resources 28 0 R /Contents[15 0 R 4 0 R 33 0 R 17 0 R] /Parent 879 0 R >> endobj 35 0 obj << /Type/Page /Resources 36 0 R /Contents[15 0 R 4 0 R 38 0 R 17 0 R] /Parent 879 0 R >> endobj 879 0 obj << /Type/Pages /Count 2 /Kids[27 0 R 35 0 R] /Parent 877 0 R >> endobj 40 0 obj << /Type/Page /Resources 41 0 R /Contents[15 0 R 4 0 R 42 0 R 17 0 R] /Parent 880 0 R >> endobj 44 0 obj << /Type/Page /Resources 45 0 R /Contents[15 0 R 4 0 R 46 0 R 17 0 R] /Parent 880 0 R >> endobj 880 0 obj << /Type/Pages /Count 2 /Kids[40 0 R 44 0 R] /Parent 877 0 R >> endobj 48 0 obj << /Type/Page /Resources 49 0 R /Contents[15 0 R 4 0 R 50 0 R 17 0 R] /Parent 881 0 R >> endobj 52 0 obj << /Type/Page /Resources 53 0 R /Contents[15 0 R 4 0 R 54 0 R 17 0 R] /Parent 881 0 R >> endobj 881 0 obj << /Type/Pages /Count 2 /Kids[48 0 R 52 0 R] /Parent 877 0 R >> endobj 877 0 obj << /Type/Pages /Count 8 /Kids[878 0 R 879 0 R 880 0 R 881 0 R] /Parent 3 0 R >> endobj 56 0 obj << /Type/Page /Resources 57 0 R /Contents[15 0 R 4 0 R 60 0 R 17 0 R] /Parent 883 0 R >> endobj 62 0 obj << /Type/Page /Resources 63 0 R /Contents[15 0 R 4 0 R 69 0 R 17 0 R] /Parent 883 0 R >> endobj 883 0 obj << /Type/Pages /Count 2 /Kids[56 0 R 62 0 R] /Parent 882 0 R >> endobj 72 0 obj << /Type/Page /Resources 73 0 R /Contents[15 0 R 4 0 R 75 0 R 17 0 R] /Parent 884 0 R >> endobj 77 0 obj << /Type/Page /Resources 78 0 R /Contents[15 0 R 4 0 R 83 0 R 17 0 R] /Parent 884 0 R >> endobj 884 0 obj << /Type/Pages /Count 2 /Kids[72 0 R 77 0 R] /Parent 882 0 R >> endobj 86 0 obj << /Type/Page /Resources 87 0 R /Contents[15 0 R 4 0 R 92 0 R 17 0 R] /Parent 885 0 R >> endobj 95 0 obj << /Type/Page /Resources 96 0 R /Contents[15 0 R 4 0 R 101 0 R 17 0 R] /Parent 885 0 R >> endobj 885 0 obj << /Type/Pages /Count 2 /Kids[86 0 R 95 0 R] /Parent 882 0 R >> endobj 104 0 obj << /Type/Page /Resources 105 0 R /Contents[15 0 R 4 0 R 109 0 R 17 0 R] /Parent 886 0 R >> endobj 112 0 obj << /Type/Page /Resources 113 0 R /Contents[15 0 R 4 0 R 120 0 R 17 0 R] /Parent 886 0 R >> endobj 123 0 obj << /Type/Page /Resources 124 0 R /Contents[15 0 R 4 0 R 129 0 R 17 0 R] /Parent 886 0 R >> endobj 886 0 obj << /Type/Pages /Count 3 /Kids[104 0 R 112 0 R 123 0 R] /Parent 882 0 R >> endobj 882 0 obj << /Type/Pages /Count 9 /Kids[883 0 R 884 0 R 885 0 R 886 0 R] /Parent 3 0 R >> endobj 132 0 obj << /Type/Page /Resources 133 0 R /Contents[15 0 R 4 0 R 134 0 R 17 0 R] /Parent 888 0 R >> endobj 136 0 obj << /Type/Page /Resources 137 0 R /Contents[15 0 R 4 0 R 138 0 R 17 0 R] /Parent 888 0 R >> endobj 888 0 obj << /Type/Pages /Count 2 /Kids[132 0 R 136 0 R] /Parent 887 0 R >> endobj 140 0 obj << /Type/Page /Resources 141 0 R /Contents[15 0 R 4 0 R 145 0 R 17 0 R] /Parent 889 0 R >> endobj 148 0 obj << /Type/Page /Resources 149 0 R /Contents[15 0 R 4 0 R 154 0 R 17 0 R] /Parent 889 0 R >> endobj 889 0 obj << /Type/Pages /Count 2 /Kids[140 0 R 148 0 R] /Parent 887 0 R >> endobj 157 0 obj << /Type/Page /Resources 158 0 R /Contents[15 0 R 4 0 R 159 0 R 17 0 R] /Parent 890 0 R >> endobj 161 0 obj << /Type/Page /Resources 162 0 R /Contents[15 0 R 4 0 R 163 0 R 17 0 R] /Parent 890 0 R >> endobj 890 0 obj << /Type/Pages /Count 2 /Kids[157 0 R 161 0 R] /Parent 887 0 R >> endobj 165 0 obj << /Type/Page /Resources 166 0 R /Contents[15 0 R 4 0 R 168 0 R 17 0 R] /Parent 891 0 R >> endobj 170 0 obj << /Type/Page /Resources 171 0 R /Contents[15 0 R 4 0 R 172 0 R 17 0 R] /Parent 891 0 R >> endobj 891 0 obj << /Type/Pages /Count 2 /Kids[165 0 R 170 0 R] /Parent 887 0 R >> endobj 887 0 obj << /Type/Pages /Count 8 /Kids[888 0 R 889 0 R 890 0 R 891 0 R] /Parent 3 0 R >> endobj 174 0 obj << /Type/Page /Resources 175 0 R /Contents[15 0 R 4 0 R 179 0 R 17 0 R] /Parent 893 0 R >> endobj 182 0 obj << /Type/Page /Resources 183 0 R /Contents[15 0 R 4 0 R 188 0 R 17 0 R] /Parent 893 0 R >> endobj 893 0 obj << /Type/Pages /Count 2 /Kids[174 0 R 182 0 R] /Parent 892 0 R >> endobj 191 0 obj << /Type/Page /Resources 192 0 R /Contents[15 0 R 4 0 R 193 0 R 17 0 R] /Parent 894 0 R >> endobj 195 0 obj << /Type/Page /Resources 196 0 R /Contents[15 0 R 4 0 R 202 0 R 17 0 R] /Parent 894 0 R >> endobj 894 0 obj << /Type/Pages /Count 2 /Kids[191 0 R 195 0 R] /Parent 892 0 R >> endobj 205 0 obj << /Type/Page /Resources 206 0 R /Contents[15 0 R 4 0 R 207 0 R 17 0 R] /Parent 895 0 R >> endobj 209 0 obj << /Type/Page /Resources 210 0 R /Contents[15 0 R 4 0 R 211 0 R 17 0 R] /Parent 895 0 R >> endobj 895 0 obj << /Type/Pages /Count 2 /Kids[205 0 R 209 0 R] /Parent 892 0 R >> endobj 213 0 obj << /Type/Page /Resources 214 0 R /Contents[15 0 R 4 0 R 215 0 R 17 0 R] /Parent 896 0 R >> endobj 217 0 obj << /Type/Page /Resources 218 0 R /Contents[15 0 R 4 0 R 219 0 R 17 0 R] /Parent 896 0 R >> endobj 221 0 obj << /Type/Page /Resources 222 0 R /Contents[15 0 R 4 0 R 223 0 R 17 0 R] /Parent 896 0 R >> endobj 896 0 obj << /Type/Pages /Count 3 /Kids[213 0 R 217 0 R 221 0 R] /Parent 892 0 R >> endobj 892 0 obj << /Type/Pages /Count 9 /Kids[893 0 R 894 0 R 895 0 R 896 0 R] /Parent 3 0 R >> endobj 3 0 obj << /Type/Pages /Count 34 /Kids[877 0 R 882 0 R 887 0 R 892 0 R] /MediaBox[0 0 595 842] >> endobj 15 0 obj << /Length 1 >> stream endstream endobj 17 0 obj << /Length 1 >> stream endstream endobj 4 0 obj << /Length 33 >> stream 1.00028 0 0 1.00028 72 769.82 cm endstream endobj 897 0 obj << >> endobj 898 0 obj null endobj 899 0 obj << >> endobj 2 0 obj << /Type/Catalog /Pages 3 0 R /Outlines 897 0 R /Threads 898 0 R /Names 899 0 R >> endobj xref 0 900 0000000000 65535 f 0000348220 00000 n 0000354085 00000 n 0000353730 00000 n 0000353935 00000 n 0000348384 00000 n 0000003361 00000 n 0000000009 00000 n 0000138511 00000 n 0000151084 00000 n 0000167588 00000 n 0000196496 00000 n 0000215739 00000 n 0000236245 00000 n 0000248416 00000 n 0000353835 00000 n 0000001069 00000 n 0000353885 00000 n 0000003264 00000 n 0000348487 00000 n 0000020007 00000 n 0000003422 00000 n 0000003710 00000 n 0000003743 00000 n 0000019691 00000 n 0000019940 00000 n 0000019973 00000 n 0000348672 00000 n 0000025409 00000 n 0000020085 00000 n 0000127128 00000 n 0000126933 00000 n 0000021701 00000 n 0000022652 00000 n 0000025343 00000 n 0000348777 00000 n 0000028000 00000 n 0000270202 00000 n 0000025471 00000 n 0000027923 00000 n 0000348963 00000 n 0000030696 00000 n 0000028062 00000 n 0000030619 00000 n 0000349068 00000 n 0000033049 00000 n 0000030758 00000 n 0000033005 00000 n 0000349254 00000 n 0000035863 00000 n 0000033111 00000 n 0000035786 00000 n 0000349359 00000 n 0000039451 00000 n 0000035925 00000 n 0000039407 00000 n 0000349642 00000 n 0000042063 00000 n 0000292967 00000 n 0000317319 00000 n 0000039513 00000 n 0000041984 00000 n 0000349747 00000 n 0000046685 00000 n 0000042125 00000 n 0000046089 00000 n 0000046284 00000 n 0000046144 00000 n 0000046210 00000 n 0000046362 00000 n 0000046618 00000 n 0000046651 00000 n 0000349933 00000 n 0000050751 00000 n 0000321985 00000 n 0000046763 00000 n 0000050683 00000 n 0000350038 00000 n 0000053895 00000 n 0000050813 00000 n 0000053390 00000 n 0000053434 00000 n 0000053505 00000 n 0000053571 00000 n 0000053828 00000 n 0000053861 00000 n 0000350224 00000 n 0000057614 00000 n 0000053973 00000 n 0000055162 00000 n 0000055206 00000 n 0000055277 00000 n 0000055343 00000 n 0000057513 00000 n 0000057580 00000 n 0000350329 00000 n 0000061550 00000 n 0000057692 00000 n 0000058657 00000 n 0000058690 00000 n 0000326689 00000 n 0000058756 00000 n 0000061422 00000 n 0000061515 00000 n 0000350516 00000 n 0000065301 00000 n 0000061630 00000 n 0000062298 00000 n 0000062333 00000 n 0000062400 00000 n 0000065220 00000 n 0000065265 00000 n 0000350624 00000 n 0000070552 00000 n 0000065382 00000 n 0000068279 00000 n 0000068338 00000 n 0000068405 00000 n 0000068480 00000 n 0000341061 00000 n 0000068552 00000 n 0000070424 00000 n 0000070516 00000 n 0000350732 00000 n 0000072678 00000 n 0000070633 00000 n 0000072163 00000 n 0000072198 00000 n 0000072283 00000 n 0000072345 00000 n 0000072608 00000 n 0000072642 00000 n 0000351028 00000 n 0000074851 00000 n 0000072759 00000 n 0000074784 00000 n 0000351136 00000 n 0000076376 00000 n 0000074915 00000 n 0000076298 00000 n 0000351327 00000 n 0000082052 00000 n 0000076440 00000 n 0000076725 00000 n 0000076760 00000 n 0000080664 00000 n 0000081948 00000 n 0000082016 00000 n 0000351435 00000 n 0000084934 00000 n 0000082133 00000 n 0000084375 00000 n 0000084422 00000 n 0000084494 00000 n 0000084561 00000 n 0000084863 00000 n 0000084897 00000 n 0000351626 00000 n 0000086860 00000 n 0000085015 00000 n 0000086792 00000 n 0000351734 00000 n 0000089228 00000 n 0000086924 00000 n 0000089149 00000 n 0000351925 00000 n 0000092667 00000 n 0000346256 00000 n 0000089292 00000 n 0000092563 00000 n 0000352033 00000 n 0000096025 00000 n 0000092731 00000 n 0000095935 00000 n 0000352321 00000 n 0000099921 00000 n 0000096089 00000 n 0000096609 00000 n 0000096644 00000 n 0000096711 00000 n 0000099815 00000 n 0000099884 00000 n 0000352429 00000 n 0000103637 00000 n 0000100002 00000 n 0000103089 00000 n 0000103136 00000 n 0000103203 00000 n 0000103275 00000 n 0000103566 00000 n 0000103600 00000 n 0000352620 00000 n 0000106321 00000 n 0000103718 00000 n 0000106253 00000 n 0000352728 00000 n 0000114985 00000 n 0000106385 00000 n 0000107354 00000 n 0000107389 00000 n 0000107923 00000 n 0000108292 00000 n 0000112458 00000 n 0000114879 00000 n 0000114948 00000 n 0000352919 00000 n 0000118125 00000 n 0000115066 00000 n 0000118056 00000 n 0000353027 00000 n 0000120600 00000 n 0000118189 00000 n 0000120531 00000 n 0000353218 00000 n 0000122447 00000 n 0000120664 00000 n 0000122391 00000 n 0000353326 00000 n 0000125195 00000 n 0000122511 00000 n 0000125116 00000 n 0000353434 00000 n 0000126869 00000 n 0000125259 00000 n 0000126835 00000 n 0000128354 00000 n 0000128720 00000 n 0000129084 00000 n 0000129464 00000 n 0000129674 00000 n 0000129944 00000 n 0000130354 00000 n 0000130765 00000 n 0000131055 00000 n 0000131630 00000 n 0000132014 00000 n 0000132392 00000 n 0000132753 00000 n 0000133132 00000 n 0000133499 00000 n 0000133958 00000 n 0000134268 00000 n 0000134508 00000 n 0000134727 00000 n 0000135075 00000 n 0000135376 00000 n 0000135717 00000 n 0000136091 00000 n 0000136371 00000 n 0000136752 00000 n 0000137035 00000 n 0000137338 00000 n 0000137696 00000 n 0000138124 00000 n 0000140459 00000 n 0000140743 00000 n 0000141026 00000 n 0000141255 00000 n 0000141442 00000 n 0000141902 00000 n 0000142263 00000 n 0000142570 00000 n 0000142836 00000 n 0000143192 00000 n 0000143577 00000 n 0000143896 00000 n 0000144208 00000 n 0000144509 00000 n 0000144818 00000 n 0000145122 00000 n 0000145372 00000 n 0000145736 00000 n 0000145957 00000 n 0000146211 00000 n 0000146413 00000 n 0000146713 00000 n 0000146967 00000 n 0000147275 00000 n 0000147515 00000 n 0000147827 00000 n 0000148082 00000 n 0000148382 00000 n 0000148724 00000 n 0000149027 00000 n 0000149326 00000 n 0000149553 00000 n 0000149923 00000 n 0000150265 00000 n 0000150619 00000 n 0000153039 00000 n 0000153387 00000 n 0000153731 00000 n 0000153943 00000 n 0000154126 00000 n 0000154553 00000 n 0000154987 00000 n 0000155190 00000 n 0000155442 00000 n 0000155841 00000 n 0000156146 00000 n 0000156531 00000 n 0000156798 00000 n 0000157359 00000 n 0000157726 00000 n 0000158073 00000 n 0000158413 00000 n 0000158762 00000 n 0000159109 00000 n 0000159381 00000 n 0000159814 00000 n 0000160094 00000 n 0000160330 00000 n 0000160535 00000 n 0000160857 00000 n 0000161134 00000 n 0000161466 00000 n 0000161811 00000 n 0000162078 00000 n 0000162431 00000 n 0000162708 00000 n 0000162986 00000 n 0000163322 00000 n 0000163684 00000 n 0000164086 00000 n 0000164319 00000 n 0000164726 00000 n 0000165133 00000 n 0000165448 00000 n 0000165833 00000 n 0000166245 00000 n 0000166575 00000 n 0000167019 00000 n 0000169580 00000 n 0000169809 00000 n 0000170093 00000 n 0000170376 00000 n 0000170674 00000 n 0000170964 00000 n 0000171160 00000 n 0000171350 00000 n 0000171543 00000 n 0000171770 00000 n 0000172029 00000 n 0000172226 00000 n 0000172451 00000 n 0000172640 00000 n 0000172945 00000 n 0000173145 00000 n 0000173380 00000 n 0000173584 00000 n 0000173838 00000 n 0000174021 00000 n 0000174286 00000 n 0000174486 00000 n 0000174707 00000 n 0000175047 00000 n 0000175507 00000 n 0000175772 00000 n 0000176038 00000 n 0000176292 00000 n 0000176593 00000 n 0000176886 00000 n 0000177222 00000 n 0000177525 00000 n 0000177875 00000 n 0000178167 00000 n 0000178443 00000 n 0000178706 00000 n 0000179050 00000 n 0000179271 00000 n 0000179476 00000 n 0000179733 00000 n 0000180070 00000 n 0000180312 00000 n 0000180649 00000 n 0000180982 00000 n 0000181323 00000 n 0000181589 00000 n 0000181994 00000 n 0000182313 00000 n 0000182668 00000 n 0000182917 00000 n 0000183206 00000 n 0000183542 00000 n 0000183946 00000 n 0000184329 00000 n 0000184656 00000 n 0000184996 00000 n 0000185300 00000 n 0000185583 00000 n 0000185869 00000 n 0000186155 00000 n 0000186440 00000 n 0000186680 00000 n 0000187023 00000 n 0000187282 00000 n 0000187504 00000 n 0000187747 00000 n 0000188043 00000 n 0000188246 00000 n 0000188519 00000 n 0000188768 00000 n 0000189046 00000 n 0000189337 00000 n 0000189628 00000 n 0000189868 00000 n 0000190161 00000 n 0000190412 00000 n 0000190660 00000 n 0000190938 00000 n 0000191264 00000 n 0000191577 00000 n 0000191892 00000 n 0000192192 00000 n 0000192471 00000 n 0000192692 00000 n 0000193025 00000 n 0000193352 00000 n 0000193642 00000 n 0000193965 00000 n 0000194306 00000 n 0000194602 00000 n 0000194962 00000 n 0000195291 00000 n 0000198482 00000 n 0000198806 00000 n 0000199126 00000 n 0000199323 00000 n 0000199506 00000 n 0000199784 00000 n 0000200079 00000 n 0000200464 00000 n 0000200793 00000 n 0000201185 00000 n 0000201505 00000 n 0000201796 00000 n 0000202194 00000 n 0000202391 00000 n 0000202637 00000 n 0000203002 00000 n 0000203278 00000 n 0000203717 00000 n 0000204056 00000 n 0000204457 00000 n 0000204716 00000 n 0000205183 00000 n 0000205510 00000 n 0000205834 00000 n 0000206148 00000 n 0000206461 00000 n 0000206778 00000 n 0000207039 00000 n 0000207421 00000 n 0000207682 00000 n 0000207906 00000 n 0000208219 00000 n 0000208420 00000 n 0000208719 00000 n 0000208975 00000 n 0000209286 00000 n 0000209603 00000 n 0000209927 00000 n 0000210179 00000 n 0000210495 00000 n 0000210753 00000 n 0000211010 00000 n 0000211315 00000 n 0000211683 00000 n 0000212015 00000 n 0000212372 00000 n 0000212592 00000 n 0000212955 00000 n 0000213313 00000 n 0000213611 00000 n 0000213960 00000 n 0000214324 00000 n 0000214638 00000 n 0000215027 00000 n 0000217710 00000 n 0000218002 00000 n 0000218293 00000 n 0000218488 00000 n 0000218771 00000 n 0000219010 00000 n 0000219208 00000 n 0000219542 00000 n 0000219754 00000 n 0000219937 00000 n 0000220200 00000 n 0000220485 00000 n 0000220780 00000 n 0000221128 00000 n 0000221487 00000 n 0000221776 00000 n 0000222051 00000 n 0000222304 00000 n 0000222658 00000 n 0000222854 00000 n 0000223207 00000 n 0000223444 00000 n 0000223789 00000 n 0000224144 00000 n 0000224500 00000 n 0000224759 00000 n 0000225088 00000 n 0000225448 00000 n 0000225702 00000 n 0000225994 00000 n 0000226360 00000 n 0000226659 00000 n 0000226952 00000 n 0000227235 00000 n 0000227523 00000 n 0000227813 00000 n 0000228064 00000 n 0000228418 00000 n 0000228670 00000 n 0000228895 00000 n 0000229160 00000 n 0000229453 00000 n 0000229652 00000 n 0000229939 00000 n 0000230185 00000 n 0000230464 00000 n 0000230750 00000 n 0000231047 00000 n 0000231285 00000 n 0000231577 00000 n 0000231825 00000 n 0000232071 00000 n 0000232364 00000 n 0000232695 00000 n 0000233007 00000 n 0000233342 00000 n 0000233638 00000 n 0000233921 00000 n 0000234142 00000 n 0000234472 00000 n 0000234807 00000 n 0000235091 00000 n 0000235416 00000 n 0000238189 00000 n 0000238453 00000 n 0000238701 00000 n 0000238898 00000 n 0000239129 00000 n 0000239321 00000 n 0000239611 00000 n 0000239923 00000 n 0000240242 00000 n 0000240504 00000 n 0000240773 00000 n 0000241123 00000 n 0000241449 00000 n 0000241779 00000 n 0000242057 00000 n 0000242372 00000 n 0000242669 00000 n 0000242989 00000 n 0000243278 00000 n 0000243614 00000 n 0000243886 00000 n 0000244194 00000 n 0000244472 00000 n 0000244774 00000 n 0000245076 00000 n 0000245390 00000 n 0000245656 00000 n 0000246010 00000 n 0000246343 00000 n 0000246675 00000 n 0000246985 00000 n 0000247293 00000 n 0000247631 00000 n 0000247964 00000 n 0000250400 00000 n 0000250673 00000 n 0000250940 00000 n 0000251206 00000 n 0000251395 00000 n 0000251663 00000 n 0000251868 00000 n 0000252071 00000 n 0000252261 00000 n 0000252464 00000 n 0000252679 00000 n 0000252870 00000 n 0000253070 00000 n 0000253270 00000 n 0000253461 00000 n 0000253703 00000 n 0000254018 00000 n 0000254276 00000 n 0000254530 00000 n 0000254817 00000 n 0000255073 00000 n 0000255302 00000 n 0000255530 00000 n 0000255815 00000 n 0000256025 00000 n 0000256220 00000 n 0000256495 00000 n 0000256704 00000 n 0000256946 00000 n 0000257212 00000 n 0000257459 00000 n 0000257708 00000 n 0000257983 00000 n 0000258282 00000 n 0000258501 00000 n 0000258739 00000 n 0000258989 00000 n 0000259247 00000 n 0000259527 00000 n 0000259785 00000 n 0000260071 00000 n 0000260339 00000 n 0000260602 00000 n 0000260860 00000 n 0000261126 00000 n 0000261389 00000 n 0000261624 00000 n 0000261936 00000 n 0000262174 00000 n 0000262389 00000 n 0000262656 00000 n 0000262859 00000 n 0000263102 00000 n 0000263332 00000 n 0000263591 00000 n 0000263858 00000 n 0000264144 00000 n 0000264381 00000 n 0000264634 00000 n 0000264877 00000 n 0000265098 00000 n 0000265353 00000 n 0000265601 00000 n 0000265869 00000 n 0000266154 00000 n 0000266418 00000 n 0000266693 00000 n 0000266920 00000 n 0000267214 00000 n 0000267510 00000 n 0000267784 00000 n 0000268056 00000 n 0000268353 00000 n 0000268616 00000 n 0000268903 00000 n 0000269204 00000 n 0000272186 00000 n 0000272492 00000 n 0000272797 00000 n 0000272985 00000 n 0000273218 00000 n 0000273405 00000 n 0000273743 00000 n 0000273961 00000 n 0000274168 00000 n 0000274359 00000 n 0000274735 00000 n 0000275111 00000 n 0000275491 00000 n 0000275805 00000 n 0000276162 00000 n 0000276539 00000 n 0000276888 00000 n 0000277225 00000 n 0000277535 00000 n 0000277863 00000 n 0000278125 00000 n 0000278525 00000 n 0000278914 00000 n 0000279228 00000 n 0000279579 00000 n 0000279937 00000 n 0000280246 00000 n 0000280598 00000 n 0000280983 00000 n 0000281354 00000 n 0000281662 00000 n 0000281970 00000 n 0000282253 00000 n 0000282578 00000 n 0000282869 00000 n 0000283190 00000 n 0000283521 00000 n 0000283849 00000 n 0000284134 00000 n 0000284440 00000 n 0000284789 00000 n 0000285061 00000 n 0000285431 00000 n 0000285755 00000 n 0000286041 00000 n 0000286364 00000 n 0000286668 00000 n 0000286944 00000 n 0000287237 00000 n 0000287508 00000 n 0000287824 00000 n 0000288126 00000 n 0000288463 00000 n 0000288782 00000 n 0000289121 00000 n 0000289440 00000 n 0000289762 00000 n 0000290038 00000 n 0000290422 00000 n 0000290772 00000 n 0000291110 00000 n 0000291448 00000 n 0000291793 00000 n 0000292125 00000 n 0000294956 00000 n 0000295252 00000 n 0000295543 00000 n 0000295733 00000 n 0000295938 00000 n 0000296143 00000 n 0000296409 00000 n 0000296674 00000 n 0000296867 00000 n 0000297077 00000 n 0000297317 00000 n 0000297578 00000 n 0000297790 00000 n 0000298023 00000 n 0000298218 00000 n 0000298525 00000 n 0000298731 00000 n 0000298979 00000 n 0000299182 00000 n 0000299373 00000 n 0000299589 00000 n 0000299931 00000 n 0000300276 00000 n 0000300609 00000 n 0000300964 00000 n 0000301243 00000 n 0000301528 00000 n 0000301842 00000 n 0000302120 00000 n 0000302364 00000 n 0000302603 00000 n 0000302923 00000 n 0000303142 00000 n 0000303347 00000 n 0000303565 00000 n 0000303841 00000 n 0000304125 00000 n 0000304389 00000 n 0000304658 00000 n 0000304948 00000 n 0000305280 00000 n 0000305501 00000 n 0000305758 00000 n 0000306042 00000 n 0000306366 00000 n 0000306658 00000 n 0000306940 00000 n 0000307223 00000 n 0000307513 00000 n 0000307807 00000 n 0000308058 00000 n 0000308400 00000 n 0000308654 00000 n 0000308884 00000 n 0000309144 00000 n 0000309439 00000 n 0000309651 00000 n 0000309911 00000 n 0000310160 00000 n 0000310437 00000 n 0000310735 00000 n 0000311041 00000 n 0000311297 00000 n 0000311576 00000 n 0000311824 00000 n 0000312069 00000 n 0000312347 00000 n 0000312618 00000 n 0000312919 00000 n 0000313247 00000 n 0000313550 00000 n 0000313786 00000 n 0000314111 00000 n 0000314429 00000 n 0000314707 00000 n 0000315010 00000 n 0000315346 00000 n 0000315621 00000 n 0000315932 00000 n 0000316269 00000 n 0000319304 00000 n 0000319577 00000 n 0000319843 00000 n 0000320121 00000 n 0000320403 00000 n 0000320713 00000 n 0000321012 00000 n 0000321272 00000 n 0000321529 00000 n 0000321845 00000 n 0000323956 00000 n 0000324148 00000 n 0000324464 00000 n 0000324793 00000 n 0000325104 00000 n 0000325421 00000 n 0000325790 00000 n 0000326062 00000 n 0000326310 00000 n 0000326549 00000 n 0000328659 00000 n 0000328861 00000 n 0000329064 00000 n 0000329304 00000 n 0000329545 00000 n 0000329735 00000 n 0000329923 00000 n 0000330160 00000 n 0000330356 00000 n 0000330545 00000 n 0000330788 00000 n 0000331019 00000 n 0000331286 00000 n 0000331490 00000 n 0000331742 00000 n 0000332003 00000 n 0000332274 00000 n 0000332488 00000 n 0000332747 00000 n 0000332998 00000 n 0000333241 00000 n 0000333500 00000 n 0000333748 00000 n 0000333976 00000 n 0000334194 00000 n 0000334460 00000 n 0000334666 00000 n 0000334887 00000 n 0000335106 00000 n 0000335340 00000 n 0000335597 00000 n 0000335854 00000 n 0000336086 00000 n 0000336338 00000 n 0000336573 00000 n 0000336790 00000 n 0000337022 00000 n 0000337262 00000 n 0000337539 00000 n 0000337796 00000 n 0000338057 00000 n 0000338281 00000 n 0000338554 00000 n 0000338824 00000 n 0000339081 00000 n 0000339339 00000 n 0000339611 00000 n 0000339862 00000 n 0000340121 00000 n 0000340401 00000 n 0000343047 00000 n 0000343348 00000 n 0000343608 00000 n 0000343811 00000 n 0000344112 00000 n 0000344411 00000 n 0000344708 00000 n 0000344962 00000 n 0000345246 00000 n 0000345482 00000 n 0000345791 00000 n 0000346090 00000 n 0000349545 00000 n 0000348592 00000 n 0000348882 00000 n 0000349173 00000 n 0000349464 00000 n 0000350931 00000 n 0000349852 00000 n 0000350143 00000 n 0000350435 00000 n 0000350840 00000 n 0000352224 00000 n 0000351244 00000 n 0000351543 00000 n 0000351842 00000 n 0000352141 00000 n 0000353633 00000 n 0000352537 00000 n 0000352836 00000 n 0000353135 00000 n 0000353542 00000 n 0000354017 00000 n 0000354040 00000 n 0000354062 00000 n trailer << /Size 900 /Root 2 0 R /Info 1 0 R >> startxref 354183 %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/fleventlist.obj0000644000076400007640000003001611077130422021336 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,0,0,0,32,0,9,1,1,0,0,1,0,1,0,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,0,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/fleventlist.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 50971, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 40569, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). page(1,"",1,''). poly('black','',2,[ 80,128,224,128],1,1,1,15,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',96,99,1,0,1,108,16,16,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,112,'',[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "NAK_SND_WAIT")]) ]) ])]). box('black','',240,96,480,160,0,1,1,18,0,0,0,0,0,'1',0,[ ]). text('black',256,102,3,0,1,216,48,19,13,3,0,0,0,0,2,216,48,0,0,"",0,0,0,0,115,'',[ minilines(216,48,0,0,0,0,0,[ mini_line(207,13,3,0,0,0,[ str_block(0,207,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,207,13,3,0,-1,0,0,0,0,0, "search in the cache the")]) ]), mini_line(207,13,3,0,0,0,[ str_block(0,207,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,207,13,3,0,-3,0,0,0,0,0, "record of the member M1")]) ]), mini_line(216,13,3,0,0,0,[ str_block(0,216,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,216,13,3,0,-2,0,0,0,0,0, "whose messages were lost")]) ]) ])]). poly('black','',2,[ 488,128,552,128],1,1,1,26,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',579,87,5,0,1,207,80,28,13,3,0,0,0,0,2,207,80,0,0,"",0,0,0,0,100,'',[ minilines(207,80,0,0,0,0,0,[ mini_line(198,13,3,0,0,0,[ str_block(0,198,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,198,13,3,0,-1,0,0,0,0,0, "send a NACK requesting")]) ]), mini_line(207,13,3,0,0,0,[ str_block(0,207,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,207,13,3,0,-1,0,0,0,0,0, "a retransmission of the")]) ]), mini_line(189,13,3,0,0,0,[ str_block(0,189,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,189,13,3,0,-1,0,0,0,0,0, "packets lost, and add")]) ]), mini_line(189,13,3,0,0,0,[ str_block(0,189,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,189,13,3,0,-1,0,0,0,0,0, "a RET_RCV_WAIT to the")]) ]), mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-2,0,0,0,0,0, "event list")]) ]) ])]). box('black','',562,79,802,177,0,1,1,35,0,0,0,0,0,'1',0,[ ]). text('black',101,139,2,0,1,99,32,39,13,3,0,0,0,0,2,99,32,0,0,"",0,0,0,0,152,'',[ minilines(99,32,0,0,0,0,0,[ mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-4,0,0,0,0,0, "parameters:")]) ]), mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,81,13,3,0,-3,0,0,0,0,0, "member M1")]) ]) ])]). poly('black','',2,[ 80,273,224,273],1,1,1,49,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',96,244,1,0,1,108,16,50,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,257,'',[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "RET_RCV_WAIT")]) ]) ])]). text('black',79,285,3,0,1,162,48,56,13,3,0,0,0,0,2,162,48,0,0,"",0,0,0,0,298,'',[ minilines(162,48,0,0,0,0,0,[ mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-4,0,0,0,0,0, "parameters:")]) ]), mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,81,13,3,0,-3,0,0,0,0,0, "member M1")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,162,13,3,0,-1,0,0,0,0,0, "sequence number sn")]) ]) ])]). polygon('black','',5,[ 344,197,234,273,344,353,458,276,344,197],0,1,1,0,63,0,0,0,0,0,'1',0, "00",[ ]). box('black','',258,212,433,360,0,1,0,64,0,0,0,0,0,'1',0,[ attr("", "auto_center_attr", 0, 1, 0, text('black',345,211,1,1,1,144,16,65,13,3,0,0,0,0,2,144,16,0,0,"",0,0,0,0,224,'',[ minilines(144,16,0,0,1,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "the number", 1, 0, 0, text('black',345,238,6,1,1,162,96,66,13,3,0,0,0,0,2,162,96,0,0,"",0,0,0,0,251,'',[ minilines(162,96,0,0,1,0,0,[ mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, "the number")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,162,13,3,0,-2,0,0,0,0,0, "of NACKs just sent")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,135,13,3,0,-1,0,0,0,0,0, "is equal to the")]) ]), mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,0,0,0,0,0,0, "maximum")]) ]), mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-3,0,0,0,0,0, "allowed?")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])])) ]). poly('black','',2,[ 470,274,534,274],1,1,1,109,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',495,246,1,0,1,18,16,110,13,3,0,0,0,0,2,18,16,0,0,"",0,0,0,0,259,'',[ minilines(18,16,0,0,0,0,0,[ mini_line(18,13,3,0,0,0,[ str_block(0,18,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,18,13,3,0,-1,0,0,0,0,0, "no")]) ]) ])]). text('black',556,263,1,0,1,234,16,116,13,3,0,0,0,0,2,234,16,0,0,"",0,0,0,0,276,'',[ minilines(234,16,0,0,0,0,0,[ mini_line(234,13,3,0,0,0,[ str_block(0,234,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,234,13,3,0,-1,0,0,0,0,0, "re-schedule a NAK_SND_WAIT")]) ]) ])]). box('black','',554,242,794,306,0,1,1,117,0,0,0,0,0,'1',0,[ ]). poly('black','',3,[ 345,358,345,391,345,393],1,1,1,119,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',300,421,1,0,1,90,16,124,13,3,0,0,0,0,2,90,16,0,0,"",0,0,0,0,434,'',[ minilines(90,16,0,0,0,0,0,[ mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, "do nothing")]) ]) ])]). box('black','',232,399,472,463,0,1,1,125,0,0,0,0,0,'1',0,[ ]). poly('black','',2,[ 80,533,224,533],1,1,1,129,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',96,504,1,0,1,108,16,130,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,517,'',[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "RET_SND_WAIT")]) ]) ])]). text('black',77,542,3,0,1,162,48,133,13,3,0,0,0,0,2,162,48,0,0,"",0,0,0,0,555,'',[ minilines(162,48,0,0,0,0,0,[ mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-4,0,0,0,0,0, "parameters:")]) ]), mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-3,0,0,0,[ str_seg('black','Courier',0,80640,81,13,3,0,-3,0,0,0,0,0, "member M1")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,162,13,3,0,-1,0,0,0,0,0, "sequence number sn")]) ]) ])]). text('black',241,511,3,0,1,216,48,138,13,3,0,0,0,0,2,216,48,0,0,"",0,0,0,0,524,'',[ minilines(216,48,0,0,0,0,0,[ mini_line(216,13,3,0,0,0,[ str_block(0,216,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,216,13,3,0,-1,0,0,0,0,0, "send a retransmission of")]) ]), mini_line(216,13,3,0,0,0,[ str_block(0,216,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,216,13,3,0,-1,0,0,0,0,0, "the requested packet, if")]) ]), mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "possible")]) ]) ])]). box('black','',230,503,470,567,0,1,1,139,0,0,0,0,0,'1',0,[ ]). poly('black','',2,[ 85,656,229,656],1,1,1,148,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',101,627,1,0,1,108,16,149,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,640,'',[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "REF_SND_WAIT")]) ]) ])]). text('black',82,665,2,0,1,99,32,150,13,3,0,0,0,0,2,99,32,0,0,"",0,0,0,0,678,'',[ minilines(99,32,0,0,0,0,0,[ mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-4,0,0,0,0,0, "parameters:")]) ]), mini_line(36,13,3,0,0,0,[ str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, "none")]) ]) ])]). text('black',246,633,4,0,1,225,64,151,13,3,0,0,0,0,2,225,64,0,0,"",0,0,0,0,646,'',[ minilines(225,64,0,0,0,0,0,[ mini_line(207,13,3,0,0,0,[ str_block(0,207,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,207,13,3,0,-8,0,0,0,0,0, "identify the sn of the ")]) ]), mini_line(225,13,3,0,0,0,[ str_block(0,225,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,225,13,3,0,-8,0,0,0,0,0, "last message sent to the ")]) ]), mini_line(171,13,3,0,0,0,[ str_block(0,171,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,171,13,3,0,-1,0,0,0,0,0, "multicaast group by")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "the local member")]) ]) ])]). box('black','',235,626,475,706,0,1,1,152,0,0,0,0,0,'1',0,[ ]). poly('black','',2,[ 487,662,551,662],1,1,1,164,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). box('black','',565,612,833,715,0,1,1,166,0,0,0,0,0,'1',0,[ ]). text('black',579,624,5,0,1,243,80,168,13,3,0,0,0,0,2,243,80,0,0,"",0,0,0,0,637,'',[ minilines(243,80,0,0,0,0,0,[ mini_line(225,13,3,0,0,0,[ str_block(0,225,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,225,13,3,0,-1,0,0,0,0,0, "send a refresh message to")]) ]), mini_line(243,13,3,0,0,0,[ str_block(0,243,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,243,13,3,0,-1,0,0,0,0,0, "the group containing the sn")]) ]), mini_line(225,13,3,0,0,0,[ str_block(0,225,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,225,13,3,0,-4,0,0,0,0,0, "of the last message sent,")]) ]), mini_line(243,13,3,0,0,0,[ str_block(0,243,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,243,13,3,0,-2,0,0,0,0,0, "or -1 if the member haven\264t")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "sent any message")]) ]) ])]). poly('black','',2,[ 84,774,228,774],1,1,1,180,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',100,745,1,0,1,108,16,181,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,758,'',[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "LEV_GRP_WAIT")]) ]) ])]). text('black',81,783,2,0,1,99,32,182,13,3,0,0,0,0,2,99,32,0,0,"",0,0,0,0,796,'',[ minilines(99,32,0,0,0,0,0,[ mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-4,0,0,0,0,0, "parameters:")]) ]), mini_line(36,13,3,0,0,0,[ str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, "none")]) ]) ])]). text('black',276,771,1,0,1,162,16,191,13,3,0,0,0,0,2,162,16,0,0,"",0,0,0,0,784,'',[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,162,13,3,0,-2,0,0,0,0,0, "shut down and exit")]) ]) ])]). box('black','',237,749,477,813,0,1,1,192,0,0,0,0,0,'1',0,[ ]). tgif-QPL-4.2.5/rmcast/doc/manual/diagram.eps0000644000076400007640000005277110122646341020436 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 4 62 596 774 %%Title: diagram %%CreationDate: Tue May 14 15:02:15 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 53 dict def tgifdict begin /tgifarrowtipdict 8 dict def tgifarrowtipdict /mtrx matrix put /TGAT % tgifarrowtip { tgifarrowtipdict begin /dy exch def /dx exch def /h exch def /w exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate dy dx atan rotate 0 0 moveto w neg h lineto w neg h neg lineto savematrix setmatrix end } def /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 4 62 596 774 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % TEXT NP 0 SG GS 1 W 101 90 M GS GS 0 /Courier-Bold FF [14 0 0 -14 0 0] MS (NACK) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (NACK) SH GR GR % TEXT NP 0 SG GS 1 W 277 70 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (Are we) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (Are we) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (waiting) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (waiting) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (to send a) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (to send a) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (NACK for this) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (NACK for this) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS ( pckt?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS ( pckt?) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 277 45 M 197 101 L 277 157 L 357 101 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 277 105 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % BOX 0 SG GS 10 SM GS NP 405 57 M 601 57 L 601 140 L 405 140 L CP S GR GR % TEXT NP 0 SG GS 1 W 414 80 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Cancel the sending) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (of the NACK and wait) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (to receive a ) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retransmission.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 365 101 M 0 34 atan DU cos 8.000 MU 399 exch SU exch sin 8.000 MU 101 exch SU L TGSM 1 W S GR GS TGSM NP 399 101 8.000 3.000 34 0 TGAT 1 SG CP F 0 SG NP 399 101 8.000 3.000 34 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 276 163 M 37 0 atan DU cos 8.000 MU 276 exch SU exch sin 8.000 MU 200 exch SU L TGSM 1 W S GR GS TGSM NP 276 200 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 276 200 8.000 3.000 0 37 TGAT CP F GR % TEXT NP 0 SG GS 1 W 277 243 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (Is there a) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (Is there a) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (scheduled) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (scheduled) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (retransmission) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (retransmission) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (?) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 275 205 M 195 261 L 275 317 L 355 261 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 275 265 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % TEXT NP 0 SG GS 1 W 273 395 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (Do we) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (Do we) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (have the) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (have the) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (requested) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (requested) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (packet?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (packet?) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 275 361 M 195 417 L 275 473 L 355 417 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 275 421 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % POLY/OPEN-SPLINE 0 SG GS NP 276 319 M 37 0 atan DU cos 8.000 MU 276 exch SU exch sin 8.000 MU 356 exch SU L TGSM 1 W S GR GS TGSM NP 276 356 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 276 356 8.000 3.000 0 37 TGAT CP F GR % BOX 0 SG GS 10 SM GS NP 409 376 M 605 376 L 605 459 L 409 459 L CP S GR GR % TEXT NP 0 SG GS 1 W 418 399 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Schedule a) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retransmission) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (of the requested) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (packet.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 364 416 M 0 34 atan DU cos 8.000 MU 398 exch SU exch sin 8.000 MU 416 exch SU L TGSM 1 W S GR GS TGSM NP 398 416 8.000 3.000 34 0 TGAT 1 SG CP F 0 SG NP 398 416 8.000 3.000 34 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 9 527 M 0 159 atan DU cos 8.000 MU 168 exch SU exch sin 8.000 MU 527 exch SU L TGSM 1 W S GR GS TGSM NP 168 527 8.000 3.000 159 0 TGAT 1 SG CP F 0 SG NP 168 527 8.000 3.000 159 0 TGAT CP F GR % TEXT NP 0 SG GS 1 W 23 514 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (retransmission) SH GR GR % BOX 0 SG GS 10 SM GS NP 175 489 M 365 489 L 365 572 L 175 572 L CP S GR GR % TEXT NP 0 SG GS 1 W 184 520 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Cancel a scheduled) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retransmission for) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (that packet, if any.) SH GR GR % TEXT NP 0 SG GS 1 W 268 816 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (Do we) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (Do we) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (have this) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (have this) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (packet?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (packet?) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 273 575 M 37 0 atan DU cos 8.000 MU 273 exch SU exch sin 8.000 MU 612 exch SU L TGSM 1 W S GR GS TGSM NP 273 612 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 273 612 8.000 3.000 0 37 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 273 890 M 37 0 atan DU cos 8.000 MU 273 exch SU exch sin 8.000 MU 927 exch SU L TGSM 1 W S GR GS TGSM NP 273 927 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 273 927 8.000 3.000 0 37 TGAT CP F GR % TEXT NP 0 SG GS 1 W 81 959 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (data ) SH GR GR % BOX 0 SG GS 10 SM GS NP 179 928 M 399 928 L 399 1011 L 179 1011 L CP S GR GR % TEXT NP 0 SG GS 1 W 189 952 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Insert the data in) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (the cache, and) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (cancel any event ) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (related to this packet) SH GR GR % TEXT NP 0 SG GS 1 W 270 1096 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (Is the) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (Is the) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (packet) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (packet) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (in order?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (in order?) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 272 1057 M 192 1113 L 272 1169 L 352 1113 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 272 1117 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % POLY/OPEN-SPLINE 0 SG GS NP 273 1015 M 37 0 atan DU cos 8.000 MU 273 exch SU exch sin 8.000 MU 1052 exch SU L TGSM 1 W S GR GS TGSM NP 273 1052 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 273 1052 8.000 3.000 0 37 TGAT CP F GR % BOX 0 SG GS 10 SM GS NP 413 1077 M 609 1077 L 609 1160 L 413 1160 L CP S GR GR % TEXT NP 0 SG GS 1 W 441 1112 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Send data to ) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (application.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 362 1111 M 0 34 atan DU cos 8.000 MU 396 exch SU exch sin 8.000 MU 1111 exch SU L TGSM 1 W S GR GS TGSM NP 396 1111 8.000 3.000 34 0 TGAT 1 SG CP F 0 SG NP 396 1111 8.000 3.000 34 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 271 1173 M 37 0 atan DU cos 8.000 MU 271 exch SU exch sin 8.000 MU 1210 exch SU L TGSM 1 W S GR GS TGSM NP 271 1210 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 271 1210 8.000 3.000 0 37 TGAT CP F GR % BOX 0 SG GS 10 SM GS NP 189 1211 M 385 1211 L 385 1294 L 189 1294 L CP S GR GR % TEXT NP 0 SG GS 1 W 202 1233 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (A gap was detected!) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Schedule the sending) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (of NACKs to the) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (remaining packets) SH GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 270 773 M 190 829 L 270 885 L 350 829 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 270 833 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % TEXT NP 0 SG GS 1 W 375 87 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Y) SH GR GR % TEXT NP 0 SG GS 1 W 288 179 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (N) SH GR GR % BOX 0 SG GS 10 SM GS NP 176 616 M 392 616 L 392 726 L 176 726 L CP S GR GR % TEXT NP 0 SG GS 1 W 179 638 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Cancel a scheduled) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (event of sending of) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (NACK or waiting for) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (retransmission, ) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (related to this packet,) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (if any.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 273 734 M 37 0 atan DU cos 8.000 MU 273 exch SU exch sin 8.000 MU 771 exch SU L TGSM 1 W S GR GS TGSM NP 273 771 8.000 3.000 0 37 TGAT 1 SG CP F 0 SG NP 273 771 8.000 3.000 0 37 TGAT CP F GR % TEXT NP 0 SG GS 1 W 709 359 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (leave group ) SH GR GR % BOX 0 SG GS 10 SM GS NP 861 327 M 1057 327 L 1057 410 L 861 410 L CP S GR GR % TEXT NP 0 SG GS 1 W 896 365 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Deactivate the) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (member.) SH GR GR % TEXT NP 0 SG GS 1 W 713 522 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (join request) SH GR GR % BOX 0 SG GS 10 SM GS NP 862 477 M 1058 477 L 1058 560 L 862 560 L CP S GR GR % TEXT NP 0 SG GS 1 W 897 515 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Send a join) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (accept message.) SH GR GR % TEXT NP 0 SG GS 1 W 732 80 M GS 0 SG /Courier-Bold FF [14 0 0 -14 0 0] MS (refresh ) SH GR GR % TEXT NP 0 SG GS 1 W 943 72 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (Do we) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (Do we) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (have the) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (have the) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (advertised) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (advertised) SH GR 0 16 RM GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (packet?) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (packet?) SH GR 0 16 RM GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % POLYGON/CLOSED-SPLINE 0 SG NP 941 34 M 861 90 L 941 146 L 1021 90 L CP GS GR GS S GR % TEXT NP 0 SG GS 1 W 941 94 M GS GS 0 0 AD GR 2 DI NE 0 RM GR GR % BOX 0 SG GS 10 SM GS NP 860 184 M 1056 184 L 1056 267 L 860 267 L CP S GR GR % TEXT NP 0 SG GS 1 W 873 206 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (A gap was detected!) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (Schedule the sending) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (of NACKs to the) SH GR 0 16 RM GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (remaining packets.) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 941 151 M 27 0 atan DU cos 8.000 MU 941 exch SU exch sin 8.000 MU 178 exch SU L TGSM 1 W S GR GS TGSM NP 941 178 8.000 3.000 0 27 TGAT 1 SG CP F 0 SG NP 941 178 8.000 3.000 0 27 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 9 98 M 0 183 atan DU cos 8.000 MU 192 exch SU exch sin 8.000 MU 98 exch SU L TGSM 1 W S GR GS TGSM NP 192 98 8.000 3.000 183 0 TGAT 1 SG CP F 0 SG NP 192 98 8.000 3.000 183 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 9 972 M 0 159 atan DU cos 8.000 MU 168 exch SU exch sin 8.000 MU 972 exch SU L TGSM 1 W S GR GS TGSM NP 168 972 8.000 3.000 159 0 TGAT 1 SG CP F 0 SG NP 168 972 8.000 3.000 159 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 696 92 M 0 159 atan DU cos 8.000 MU 855 exch SU exch sin 8.000 MU 92 exch SU L TGSM 1 W S GR GS TGSM NP 855 92 8.000 3.000 159 0 TGAT 1 SG CP F 0 SG NP 855 92 8.000 3.000 159 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 687 370 M 0 159 atan DU cos 8.000 MU 846 exch SU exch sin 8.000 MU 370 exch SU L TGSM 1 W S GR GS TGSM NP 846 370 8.000 3.000 159 0 TGAT 1 SG CP F 0 SG NP 846 370 8.000 3.000 159 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 691 532 M 0 159 atan DU cos 8.000 MU 850 exch SU exch sin 8.000 MU 532 exch SU L TGSM 1 W S GR GS TGSM NP 850 532 8.000 3.000 159 0 TGAT 1 SG CP F 0 SG NP 850 532 8.000 3.000 159 0 TGAT CP F GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Tue May 14 15:02:15 2002 %%DocumentFonts: Courier %%+ Courier-Bold %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/cache1.obj0000644000076400007640000006202011077130422020123 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,0,0,1,16,0,9,1,1,1,0,0,0,1,0,'Courier-Bold',1,138240,0,5,0,10,0,0,1,1,0,16,0,0,1,1,1,0,1088,1408,1,0,2880,1). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/cache1.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 50971, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 40569, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). page(1,"",1,''). poly('black','',2,[ 195,658,195,687],1,1,1,875,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 305,471,367,471],1,1,1,882,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). oval('black','',372,453,406,487,26,1,1,883,0,0,0,0,0,'1',1,[ ]). oval('black','',478,454,512,488,26,1,1,885,0,0,0,0,0,'1',1,[ ]). oval('black','',581,453,615,487,12,1,1,887,0,0,0,0,0,'1',1,[ ]). poly('black','',2,[ 410,470,472,470],1,1,1,889,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 515,470,577,470],1,1,1,892,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 304,630,366,630],1,1,1,894,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 621,470,661,470,661,495],1,1,1,895,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 626,500,700,500],0,1,1,896,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 636,506,688,506],0,1,1,899,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 651,512,669,512],0,1,1,900,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). oval('black','',368,611,402,645,0,1,1,919,0,0,0,0,0,'1',0,[ ]). oval('black','',474,612,508,646,0,1,1,920,0,0,0,0,0,'1',0,[ ]). poly('black','',2,[ 406,628,468,628],1,1,1,922,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 516,628,556,628,556,653],1,1,1,924,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 521,658,595,658],0,1,1,925,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 531,667,583,667],0,1,1,926,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 546,677,564,677],0,1,1,927,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ box('black','',104,381,305,413,0,1,1,615,0,0,0,0,0,'1',0,[ ]), text('black',125,389,1,0,1,162,16,651,13,3,0,0,0,0,2,162,16,0,0,"",0,0,0,0,402,'',[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,153,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,153,13,3,0,-8,0,0,0,0,0, "number_of_nodes: ")]), str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-2,0,0,0,0,0, "3")]) ]) ])]) ], 671,0,0,[ ]). group([ box('black','',104,418,305,450,0,1,1,677,0,0,0,0,0,'1',0,[ ]), text('black',125,426,1,0,1,81,16,676,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,439,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,72,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-8,0,0,0,0,0, "active: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 675,0,0,[ ]). group([ box('black','',104,454,305,486,0,1,1,744,0,0,0,0,0,'1',0,[ ]), text('black',125,462,1,0,1,45,16,743,13,3,0,0,0,0,2,45,16,0,0,"",0,0,0,0,475,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-2,0,0,0,0,0, "first")]) ]) ])]) ], 742,0,0,[ ]). box('black','',107,525,297,557,0,1,1,749,0,0,0,0,0,'1',0,[ ]). text('black',113,527,2,0,1,179,30,748,13,3,0,0,0,0,2,189,30,0,0,"",0,1,0,0,541,'',[ 113,527,113,527,302,557,945.274,0,0,1000,-2,0,112,526,303,558],[ minilines(189,30,0,0,0,0,0,[ mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,135,13,3,0,-8,0,0,0,0,0, " member_id ")]) ]), mini_line(189,11,3,0,0,0,[ str_block(0,189,11,3,0,-3,0,0,0,[ str_seg('black','Courier',0,69120,189,11,3,0,-3,0,0,0,0,0, "(ip: 192.168.0.2, pid: 123)")]) ]) ])]). box('black','',107,570,296,602,0,2,1,755,8,0,0,0,0,'2',0,[ ]). text('black',111,578,1,0,1,144,16,754,13,3,0,0,0,0,2,153,16,0,0,"",0,1,0,0,591,'',[ 111,578,111,578,264,594,940.299,0,0,1000,-1,0,110,577,265,595],[ minilines(153,16,0,0,0,0,0,[ mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,153,13,3,0,-2,0,0,0,0,0, " member_status")]) ]) ])]). text('black',108,497,1,0,1,63,16,761,13,3,0,0,0,0,2,63,16,0,0,"",0,0,0,0,510,'',[ minilines(63,16,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "sm_info")]) ]) ])]). box('black','',104,491,305,612,0,2,1,763,0,0,0,0,0,'2',0,[ ]). group([ box('black','',104,616,305,648,0,1,1,775,0,0,0,0,0,'1',0,[ ]), text('black',125,624,1,0,1,72,16,774,13,3,0,0,0,0,2,72,16,0,0,"",0,0,0,0,637,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-2,0,0,0,0,0, "nak_list")]) ]) ])]) ], 773,0,0,[ ]). box('black','',97,374,313,655,0,3,1,808,0,0,0,0,0,'3',0,[ ]). group([ box('black','',105,697,306,729,0,1,1,1061,0,0,0,0,0,'1',0,[ ]), text('black',126,705,1,0,1,162,16,1060,13,3,0,0,0,0,2,162,16,0,0,"",0,0,0,0,718,'',[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,153,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,153,13,3,0,-8,0,0,0,0,0, "number_of_nodes: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 1059,0,0,[ ]). group([ box('black','',105,734,306,766,0,1,1,1058,0,0,0,0,0,'1',0,[ ]), text('black',126,742,1,0,1,81,16,1057,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,755,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,72,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-8,0,0,0,0,0, "active: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 1056,0,0,[ ]). group([ box('black','',105,770,306,802,0,1,1,1055,0,0,0,0,0,'1',0,[ ]), text('black',126,778,1,0,1,45,16,1054,13,3,0,0,0,0,2,45,16,0,0,"",0,0,0,0,791,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-2,0,0,0,0,0, "first")]) ]) ])]) ], 1053,0,0,[ ]). box('black','',108,841,298,873,0,1,1,1052,0,0,0,0,0,'1',0,[ ]). group([ box('black','',108,886,297,918,0,1,1,1049,0,0,0,0,0,'1',0,[ ]), text('black',129,894,1,0,1,135,16,1048,13,3,0,0,0,0,2,144,16,0,0,"",0,1,0,0,907,'',[ 129,894,129,894,273,910,940.299,0,0,1000,-1,0,128,893,274,911],[ minilines(144,16,0,0,0,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-2,0,0,0,0,0, " member_status")]) ]) ])]) ], 1047,0,0,[ ]). text('black',109,813,1,0,1,63,16,1046,13,3,0,0,0,0,2,63,16,0,0,"",0,0,0,0,826,'',[ minilines(63,16,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "sm_info")]) ]) ])]). box('black','',105,807,306,928,0,2,1,1045,0,0,0,0,0,'2',0,[ ]). group([ box('black','',105,932,306,964,0,1,1,1044,0,0,0,0,0,'1',0,[ ]), text('black',126,940,1,0,1,72,16,1043,13,3,0,0,0,0,2,72,16,0,0,"",0,0,0,0,953,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-2,0,0,0,0,0, "nak_list")]) ]) ])]) ], 1042,0,0,[ ]). box('black','',98,690,314,971,0,3,1,1041,0,0,0,0,0,'3',0,[ ]). poly('black','',2,[ 305,786,367,786],1,1,1,1072,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). oval('black','',372,768,406,802,26,1,1,1073,0,0,0,0,0,'1',1,[ ]). poly('black','',3,[ 408,785,448,785,448,810],1,1,1,1078,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 413,815,487,815],0,1,1,1079,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 423,824,475,824],0,1,1,1080,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 438,834,456,834],0,1,1,1081,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 306,946,368,946],1,1,1,1094,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). oval('black','',371,927,405,961,0,1,1,1095,0,0,0,0,0,'1',0,[ ]). poly('black','',3,[ 405,944,445,944,445,969],1,1,1,1098,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 410,974,484,974],0,1,1,1099,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 420,983,472,983],0,1,1,1100,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',384,494,1,0,1,9,16,1418,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,506,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "0")]) ]) ])]). text('black',490,492,1,0,1,9,16,1422,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,504,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,-1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,-1,0,0,0,0,0, "1")]) ]) ])]). text('black',592,493,1,0,1,9,16,1424,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,505,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "4")]) ]) ])]). text('black',380,656,1,0,1,9,16,1427,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,668,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "2")]) ]) ])]). text('black',488,655,1,0,1,9,16,1430,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,667,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "3")]) ]) ])]). text('black',384,812,1,0,1,9,16,1433,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,824,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "0")]) ]) ])]). text('black',386,974,1,0,1,9,16,1435,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,986,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,-1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,-1,0,0,0,0,0, "1")]) ]) ])]). text('black',116,842,2,0,1,179,30,1497,13,3,0,0,0,0,2,189,30,0,0,"",0,1,0,0,856,'',[ 116,842,116,842,305,872,945.274,0,0,1000,-2,0,115,841,306,873],[ minilines(189,30,0,0,0,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-8,0,0,0,0,0, " member_id ")]) ]), mini_line(189,11,3,0,0,0,[ str_block(0,189,11,3,0,-3,0,0,0,[ str_seg('black','Courier',0,69120,189,11,3,0,-3,0,0,0,0,0, "(ip: 192.168.0.3, pid: 125)")]) ]) ])]). text('black',375,620,1,0,1,18,16,1535,12,4,0,0,0,0,2,18,16,0,1,"",0,0,0,1,632,'',[ minilines(18,16,0,1,0,0,0,[ mini_line(18,12,4,0,1,0,[ str_block(0,18,12,4,0,1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,18,12,4,0,1,0,0,0,0,0, "2x")]) ]) ])]). text('black',481,621,1,0,1,18,16,1538,12,4,0,0,0,0,2,18,16,0,1,"",0,0,0,1,633,'',[ minilines(18,16,0,1,0,0,0,[ mini_line(18,12,4,0,1,0,[ str_block(0,18,12,4,0,1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,18,12,4,0,1,0,0,0,0,0, "1x")]) ]) ])]). text('black',380,936,1,0,1,18,16,1546,12,4,0,0,0,0,2,18,16,0,1,"",0,0,0,1,948,'',[ minilines(18,16,0,1,0,0,0,[ mini_line(18,12,4,0,1,0,[ str_block(0,18,12,4,0,1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,18,12,4,0,1,0,0,0,0,0, "1x")]) ]) ])]). poly('black','',2,[ 195,976,195,1005],1,1,1,1600,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). box('black','',300,574,334,597,0,1,0,1626,0,0,0,0,0,'1',1,[ attr("", "auto_center_attr", 0, 1, 0, text('black',317,573,1,1,1,240,25,1627,20,5,0,0,0,0,2,240,25,0,0,"",0,0,0,0,593,'',[ minilines(240,25,0,0,1,0,0,[ mini_line(240,20,5,0,0,0,[ str_block(0,240,20,5,0,-2,0,0,0,[ str_seg('black','Courier-Bold',1,138240,240,20,5,0,-2,1,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('black',317,572,1,1,1,0,25,1628,20,5,0,0,0,0,2,0,25,0,0,"",0,0,0,0,592,'',[ minilines(0,25,0,0,1,0,0,[ mini_line(0,20,5,0,0,0,[ str_block(0,0,20,5,0,0,0,0,0,[ str_seg('black','Courier-Bold',1,138240,0,20,5,0,0,1,0,0,0,0, "")]) ]) ])])) ]). group([ poly('black','',2,[ 159,1007,233,1007],0,1,1,1604,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 169,1016,221,1016],0,1,1,1605,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 184,1026,202,1026],0,1,1,1606,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 2845,0,0,[ ]). group([ box('black','',103,65,304,97,0,1,1,2881,0,0,0,0,0,'1',0,[ ]), text('black',124,73,1,0,1,162,16,2880,13,3,0,0,0,0,2,162,16,0,0,"",0,0,0,0,86,'',[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,153,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,153,13,3,0,-8,0,0,0,0,0, "number_of_nodes: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 2879,0,0,[ ]). group([ box('black','',103,102,304,134,0,1,1,2878,0,0,0,0,0,'1',0,[ ]), text('black',124,110,1,0,1,81,16,2877,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,123,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,72,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-8,0,0,0,0,0, "active: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 2876,0,0,[ ]). group([ box('black','',103,138,304,170,0,1,1,2875,0,0,0,0,0,'1',0,[ ]), text('black',124,146,1,0,1,45,16,2874,13,3,0,0,0,0,2,45,16,0,0,"",0,0,0,0,159,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-2,0,0,0,0,0, "first")]) ]) ])]) ], 2873,0,0,[ ]). box('black','',106,209,296,241,0,1,1,2872,0,0,0,0,0,'1',0,[ ]). group([ box('black','',106,254,295,286,0,1,1,2871,0,0,0,0,0,'1',0,[ ]), text('black',127,262,1,0,1,135,16,2870,13,3,0,0,0,0,2,144,16,0,0,"",0,1,0,0,275,'',[ 127,262,127,262,271,278,940.299,0,0,1000,-1,0,126,261,272,279],[ minilines(144,16,0,0,0,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-2,0,0,0,0,0, " member_status")]) ]) ])]) ], 2869,0,0,[ ]). text('black',107,181,1,0,1,63,16,2868,13,3,0,0,0,0,2,63,16,0,0,"",0,0,0,0,194,'',[ minilines(63,16,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "sm_info")]) ]) ])]). box('black','',103,175,304,296,0,2,1,2867,0,0,0,0,0,'2',0,[ ]). group([ box('black','',103,300,304,332,0,1,1,2866,0,0,0,0,0,'1',0,[ ]), text('black',124,308,1,0,1,72,16,2865,13,3,0,0,0,0,2,72,16,0,0,"",0,0,0,0,321,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-2,0,0,0,0,0, "nak_list")]) ]) ])]) ], 2864,0,0,[ ]). box('black','',96,58,312,339,0,3,1,2863,0,0,0,0,0,'3',0,[ ]). poly('black','',2,[ 303,154,365,154],1,1,1,2862,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). oval('black','',370,136,404,170,26,1,1,2861,0,0,0,0,0,'1',1,[ ]). poly('black','',3,[ 406,153,446,153,446,178],1,1,1,2860,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 411,183,485,183],0,1,1,2859,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 421,192,473,192],0,1,1,2858,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 436,202,454,202],0,1,1,2857,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',382,180,1,0,1,9,16,2850,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,192,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "0")]) ]) ])]). text('black',114,210,2,0,1,179,30,2848,13,3,0,0,0,0,2,189,30,0,0,"",0,1,0,0,224,'',[ 114,210,114,210,303,240,945.274,0,0,1000,-2,0,113,209,304,241],[ minilines(189,30,0,0,0,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-8,0,0,0,0,0, " member_id ")]) ]), mini_line(189,11,3,0,0,0,[ str_block(0,189,11,3,0,-3,0,0,0,[ str_seg('black','Courier',0,69120,189,11,3,0,-3,0,0,0,0,0, "(ip: 192.168.0.1, pid: 225)")]) ]) ])]). poly('black','',2,[ 195,340,195,369],1,1,1,2884,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 305,315,404,315,404,340],1,1,1,2933,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 369,345,443,345],0,1,1,2934,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 379,354,431,354],0,1,1,2935,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 394,364,412,364],0,1,1,2936,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ text('black',592,838,1,0,1,49,14,1547,11,3,0,0,0,0,2,49,14,0,0,"",0,0,0,1,849,'',[ minilines(49,14,0,0,0,0,0,[ mini_line(49,11,3,0,0,0,[ str_block(0,49,11,3,0,-2,0,0,0,[ str_seg('black','Courier-BoldOblique',3,69120,49,11,3,0,-2,0,0,0,0,0, "Legend:")]) ]) ])]), oval('black','',593,861,627,895,26,1,1,1550,0,0,0,0,0,'1',1,[ ]), oval('black','',593,907,627,941,12,1,1,1552,0,0,0,0,0,'1',1,[ ]), oval('black','',593,954,627,988,0,1,1,1555,0,0,0,0,0,'1',0,[ ]), text('black',642,868,1,0,1,252,16,1559,13,3,0,0,0,0,2,252,16,0,0,"",0,0,0,1,881,'',[ minilines(252,16,0,0,0,0,0,[ mini_line(252,13,3,0,0,0,[ str_block(0,252,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,252,13,3,0,-4,0,0,0,0,0, "Packet received in sequence.")]) ]) ])]), text('black',644,910,2,0,1,252,32,1563,13,3,0,0,0,0,2,252,32,0,0,"",0,0,0,1,923,'',[ minilines(252,32,0,0,0,0,0,[ mini_line(252,13,3,0,0,0,[ str_block(0,252,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,252,13,3,0,-1,0,0,0,0,0, "Packet received out of order")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,135,13,3,0,-4,0,0,0,0,0, "(gap detected).")]) ]) ])]), text('black',643,962,2,0,1,216,32,1566,13,3,0,0,0,0,2,216,32,0,0,"",0,0,0,1,975,'',[ minilines(216,32,0,0,0,0,0,[ mini_line(216,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-1,0,0,0,0,0, "n")]), str_block(0,207,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,207,13,3,0,-8,0,0,0,0,0, " NACKs for this packet ")]) ]), mini_line(180,13,3,0,0,0,[ str_block(0,180,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,180,13,3,0,-4,0,0,0,0,0, "have just been sent.")]) ]) ])]), text('black',601,963,1,0,1,18,16,1570,12,4,0,0,0,0,2,18,16,0,1,"",0,0,0,1,975,'',[ minilines(18,16,0,1,0,0,0,[ mini_line(18,12,4,0,1,0,[ str_block(0,18,12,4,0,1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,18,12,4,0,1,0,0,0,0,0, "nx")]) ]) ])]), box('black','',575,822,941,1019,0,2,1,1574,0,0,0,0,0,'2',1,[ ]) ], 2946,0,0,[ ]). group([ box('black','',701,535,943,760,0,2,1,1642,8,0,0,0,0,'2',1,[ ]), box('black','',725,572,914,749,0,1,1,1646,0,0,0,0,0,'1',0,[ ]), text('black',765,540,1,0,1,110,16,1647,13,3,0,0,0,0,2,117,16,0,0,"",0,1,0,0,553,'',[ 765,540,765,540,882,556,940.299,0,0,1000,-1,0,764,539,883,557],[ minilines(117,16,0,0,0,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,117,13,3,0,-2,0,0,0,0,0, "member_status")]) ]) ])]), poly('black','',2,[ 724,648,914,648],0,1,1,1684,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 726,621,914,621],0,1,1,1687,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 724,674,914,674],0,1,1,1688,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 725,700,915,700],0,1,1,1690,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), text('black',743,576,1,0,1,102,16,1698,13,3,0,0,0,0,2,108,16,0,0,"",0,1,0,0,589,'',[ 743,576,743,576,851,592,940.299,0,0,1000,-1,0,742,575,852,593],[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,99,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-8,0,0,0,0,0, "first_rcv: ")]), str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-1,0,0,0,0,0, "0")]) ]) ])]), text('black',743,602,1,0,1,102,16,1701,13,3,0,0,0,0,2,108,16,0,0,"",0,1,0,0,615,'',[ 743,602,743,602,851,618,940.299,0,0,1000,-1,0,742,601,852,619],[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,90,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-8,0,0,0,0,0, "last_rcv: ")]), str_block(0,18,13,3,0,-8,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,18,13,3,0,-8,0,0,0,0,0, "4 ")]) ]) ])]), text('black',743,626,1,0,1,127,16,1704,13,3,0,0,0,0,2,135,16,0,0,"",0,1,0,0,639,'',[ 743,626,743,626,878,642,940.299,0,0,1000,-1,0,742,625,879,643],[ minilines(135,16,0,0,0,0,0,[ mini_line(135,13,3,0,0,0,[ str_block(0,126,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,126,13,3,0,-8,0,0,0,0,0, "last_seq_rcv: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]), text('black',743,653,1,0,1,152,16,1707,13,3,0,0,0,0,2,162,16,0,0,"",0,1,0,0,666,'',[ 743,653,743,653,905,669,940.299,0,0,1000,-1,0,742,652,906,670],[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,153,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,153,13,3,0,-8,0,0,0,0,0, "last_identified: ")]), str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-2,0,0,0,0,0, "4")]) ]) ])]), poly('black','',2,[ 724,726,914,726],0,1,1,1730,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 726,598,914,598],0,1,1,1733,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), text('black',743,678,1,0,1,118,16,1735,13,3,0,0,0,0,2,126,16,0,0,"",0,1,0,0,691,'',[ 743,678,743,678,869,694,940.299,0,0,1000,-1,0,742,677,870,695],[ minilines(126,16,0,0,0,0,0,[ mini_line(126,13,3,0,0,0,[ str_block(0,117,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,117,13,3,0,-8,0,0,0,0,0, "window_size: ")]), str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-1,0,0,0,0,0, "5")]) ]) ])]), text('black',743,704,1,0,1,152,16,1738,13,3,0,0,0,0,2,162,16,0,0,"",0,1,0,0,717,'',[ 743,704,743,704,905,720,940.299,0,0,1000,-1,0,742,703,906,721],[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,117,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,117,13,3,0,-8,0,0,0,0,0, "window_mask: ")]), str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,45,13,3,0,-1,0,0,0,0,0, "00110")]) ]) ])]), text('black',743,729,1,0,1,110,16,1741,13,3,0,0,0,0,2,117,16,0,0,"",0,1,0,0,742,'',[ 743,729,743,729,860,745,940.299,0,0,1000,-1,0,742,728,861,746],[ minilines(117,16,0,0,0,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,99,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-4,0,0,0,0,0, "window_ini:")]), str_block(0,18,13,3,0,-2,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,18,13,3,0,-2,0,0,0,0,0, " 2")]) ]) ])]) ], 2973,0,0,[ ]). poly('black','',3,[ 296,602,600,602,700,758],0,2,1,2977,0,0,5,0,0,0,0,'2',1,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ ]). poly('black','',3,[ 295,570,602,570,702,535],0,2,1,2988,0,0,5,0,0,0,0,'2',1,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ ]). poly('black','',2,[ 438,992,456,992],0,1,1,3511,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). tgif-QPL-4.2.5/rmcast/doc/manual/log_plot.obj0000644000076400007640000221022511077130422020622 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,0,0,0,16,1,9,1,1,0,0,1,0,1,0,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,0,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/log_plot.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 50971, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 40569, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). page(1,"",1,''). xpm('black','',0,0,622,474,0,2,2,0,0,0,622,474,0,0,0,0,0,0,[ "``", "white", 10000, 10000, 10000, "a2", "#000000", 0, 0, 0],[ "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````a2a2a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````a2a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````a2````````````````a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2````````````", "````````````````````````a2````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````a2``````a2````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````a2a2a2``````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````a2````````````````````````````````````````````a2``````````````````````````a2``````````a2a2a2````````a2a2a2````````````a2````````a2a2a2``````````````````````````````````a2``````a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````a2``````````a2a2``````````a2a2````````a2``````a2````a2``````a2````````a2a2``````a2``````a2``````a2a2``````````````````````a2a2````a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2a2````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2````````a2``````a2``````a2a2a2``````a2``a2a2``````a2``a2a2````````a2a2a2````````a2a2a2a2````a2a2a2a2a2``````a2a2````````````a2````````a2``````a2````````````a2``````a2``a2``````a2``````a2``````a2a2``````````````````````a2``a2``a2``````a2a2a2``````a2````a2````````a2a2a2a2````````````````````a2a2a2a2``````a2a2a2``````a2``a2a2``````a2a2a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2````a2````a2``````a2````a2``````a2````a2``````a2````````a2````````a2``````a2````a2``````a2````a2a2````a2````a2a2````a2````a2``````a2````a2````````````````a2``````````````````````````a2``````````a2a2a2``````````a2a2``````a2````a2````````a2a2a2``````````````````````````````````a2````a2a2````````````a2````a2``a2````````a2``````````````````````````a2````````````a2``````a2````a2a2````a2````````a2````````````````````a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2``````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````a2a2a2a2a2````a2````````````a2a2a2a2a2````````a2````````a2``````a2````a2a2a2a2a2````a2````````````a2``````a2````a2``````a2``````a2a2a2``````````a2``````````a2a2````````````a2````````a2``````a2````````````a2````a2a2a2a2a2````a2``````a2``````a2a2``````````````````````a2``````a2``````a2a2a2a2````a2a2````````````a2a2a2``````````````````````a2a2a2``````a2a2a2a2a2````a2``````a2````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````a2````````````a2``````a2````a2````````````````a2``````````a2``a2``````a2````````````a2````````````a2``````a2````a2``````a2````````````a2````````a2``a2``````a2a2````````````a2````````a2``````a2````a2``````a2``````````a2``````a2``````a2``````a2a2``````````````````````a2``````a2````a2``````a2````a2``a2````````````````a2``````````````````````````a2````a2````````````a2``````a2````````a2``a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2a2``````````a2``````````a2a2a2``````a2````````````a2``````a2``````a2a2a2``````a2a2a2a2````````````a2``````````````````````a2a2a2````````a2a2a2````````a2a2a2````````````a2````````a2a2a2``````````````````````````````````a2``````a2``````a2a2a2a2````a2````a2``````a2a2a2a2````````````````````a2a2a2a2````````a2a2a2``````a2``````a2``````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````a2````````````````````````````````````````````a2``````````````````````````a2``````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2a2``````````````````````````````````a2``````a2``````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````a2````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````a2````````````````````````````````````````````a2``````````````````````````a2``````````a2a2a2````````a2a2a2````````````a2````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````a2````````````````````````````````````````````a2``````````a2a2``````````a2a2````````a2``````a2````a2``````a2````a2``````a2````a2``````a2``````a2a2``````````````````````a2a2````a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````a2``a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````a2``````````a2a2``````````a2a2````````a2``````a2````a2``````a2````````a2a2``````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2a2``````a2a2a2``````a2``a2a2````````a2a2``a2``````a2a2a2``````a2``a2a2``````a2``a2a2````````a2a2a2````````a2a2a2a2````a2a2a2a2a2``````a2a2````````````a2````````````````a2````a2``````a2````a2``````a2````````````a2``````a2a2``````````````````````a2``a2``a2``````a2a2a2``````a2````a2````````a2a2a2a2``````````````````a2``a2a2````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2````````a2``````a2``````a2a2a2````````a2a2``a2``````````````````````a2````````a2``a2a2````````a2a2a2``````a2a2``a2````````````````````a2``a2a2````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2````````a2``````a2``````a2a2a2``````a2``a2a2``````a2``a2a2````````a2a2a2````````a2a2a2a2````a2a2a2a2a2``````a2a2````````````a2````````a2``````a2````````````a2``````a2``a2``````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````a2``````a2````a2a2````a2````a2````a2a2````a2``````a2````a2a2````a2````a2a2````a2````a2``````a2````a2````````````````a2``````````````````````````a2````````````a2a2````````a2a2a2````````a2a2a2a2````````a2a2``````````````````````````````````a2````a2a2````````````a2````a2``a2````````a2``````````````````````````a2a2````a2````a2``````a2````a2``````a2````a2``````a2````````a2````````a2``````a2````a2``````a2````a2````a2a2````````````````````a2a2a2``````a2a2````a2````a2``````a2````a2``a2``a2``````````````````a2a2````a2````a2``````a2````a2``````a2````a2``````a2````````a2````````a2``````a2````a2``````a2````a2a2````a2````a2a2````a2````a2``````a2````a2````````````````a2``````````````````````````a2``````````a2a2a2``````````a2a2``````a2````a2````````a2a2a2``````````````````a2``a2``a2``a2``a2``a2``a2``a2``a2``a2``a2``a2``a2``a2``a2``a2``a2````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2``````a2a2a2a2a2````a2``````a2````a2``````a2````a2a2a2a2a2````a2````````````a2``````a2````a2``````a2``````a2a2a2``````````a2``````````a2a2````````````a2````````````````a2````a2``````a2````````````a2````````````a2``````a2a2``````````````````````a2``````a2``````a2a2a2a2````a2a2````````````a2a2a2````````````````````a2````````````a2a2a2a2a2````a2````````````a2a2a2a2a2````````a2````````a2``````a2````a2a2a2a2a2````a2``````a2``````````````````````a2````````a2````````````a2``````a2````a2``a2``a2``````````````````a2````````````a2a2a2a2a2````a2````````````a2a2a2a2a2````````a2````````a2``````a2````a2a2a2a2a2````a2````````````a2``````a2````a2``````a2``````a2a2a2``````````a2``````````a2a2````````````a2````````a2``````a2````````````a2````a2a2a2a2a2````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````a2````````````a2``````a2````a2````a2a2````a2````````````a2````````````a2``````a2````a2``````a2````````````a2````````a2``a2``````a2a2````````````a2````````a2``````a2````a2``````a2``````````a2``````a2``````a2``````a2a2``````````````````````a2``````a2````a2``````a2````a2``a2````````````````a2``````````````````a2````````````a2````````````a2``````a2````a2````````````````a2``````````a2``a2``````a2````````````a2````a2a2``````````````````````a2````````a2````````````a2``````a2````a2``a2``a2``````````````````a2````````````a2````````````a2``````a2````a2````````````````a2``````````a2``a2``````a2````````````a2````````````a2``````a2````a2``````a2````````````a2````````a2``a2``````a2a2````````````a2````````a2``````a2````a2``````a2``````````a2``````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2a2````````a2a2a2``````a2``````a2``````a2a2``a2``````a2a2a2``````a2````````````a2``````a2``````a2a2a2``````a2a2a2a2````````````a2``````````````````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2``````````a2a2a2``````````````````````````````````a2``````a2``````a2a2a2a2````a2````a2``````a2a2a2a2````````````````````a2``````````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2a2``````````a2``````````a2a2a2````````a2a2``a2``````````````````````a2````````a2``````````````a2a2a2``````a2``a2``a2``````````````````a2``````````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2a2``````````a2``````````a2a2a2``````a2````````````a2``````a2``````a2a2a2``````a2a2a2a2````````````a2``````````````````````a2a2a2````````a2a2a2````````a2a2a2````````````a2````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````a2````````````````````````````````````````````a2``````````````````````````a2``````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2a2``````````````````````````````````a2a2a2a2````````````````````````a2``````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````a2````````````````````````````````````````````a2``````````a2a2``````````a2a2````````a2``````a2````a2``````a2````a2``````a2````a2``````a2``````a2a2``````````````````````a2``````a2``````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2a2``````a2a2a2``````a2``a2a2````````a2a2``a2``````a2a2a2``````a2``a2a2``````a2``a2a2````````a2a2a2````````a2a2a2a2````a2a2a2a2a2``````a2a2````````````a2````````````````a2````a2``````a2````a2``````a2````````````a2``````a2a2``````````````````````a2``````a2``````a2a2a2``````a2a2a2a2a2````a2``a2a2````````a2a2a2``````a2``a2a2````````a2a2a2a2````a2a2``a2````````a2a2``````````a2a2a2a2``````a2a2a2a2``````a2a2``````````a2a2a2``````a2``a2a2``````````````````````a2a2a2a2``````a2a2a2``````a2``a2a2``````a2a2a2a2a2``````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````a2``````a2````a2a2````a2````a2````a2a2````a2``````a2````a2a2````a2````a2a2````a2````a2``````a2````a2````````````````a2``````````````````````````a2````````````a2a2````````a2a2a2````````a2a2a2a2````````a2a2``````````````````````````````````a2a2a2a2``````a2``````a2````````a2````````a2a2````a2````````````a2````a2a2````a2````a2````````````a2``a2``a2````````a2````````a2````````````a2````````````````a2````````a2``````a2````a2a2````a2``````````````````a2````````````a2``````a2````a2a2````a2````````a2````````````````````````````````````````````````a2``a2``a2````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2``````a2a2a2a2a2````a2``````a2````a2``````a2````a2a2a2a2a2````a2````````````a2``````a2````a2``````a2``````a2a2a2``````````a2``````````a2a2````````````a2````````````````a2````a2``````a2````````````a2````````````a2``````a2a2``````````````````````a2``a2````````a2a2a2a2a2````````a2````````a2``````````````a2a2a2a2````a2``````a2``````a2a2a2``````a2``a2``a2````````a2``````````a2a2a2````````a2a2a2``````````a2````````a2``````a2````a2``````a2````````````````````a2a2a2``````a2a2a2a2a2````a2``````a2````````a2``````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````a2````````````a2``````a2````a2````a2a2````a2````````````a2````````````a2``````a2````a2``````a2````````````a2````````a2``a2``````a2a2````````````a2````````a2``````a2````a2``````a2``````````a2``````a2``````a2``````a2a2``````````````````````a2````a2``````a2````````````````a2``a2````a2````````````a2``````a2````a2``````a2````````````a2````a2``a2``a2````````a2````````````````a2````````````a2````````a2````````a2``````a2````a2``````a2``````````````````````````a2````a2````````````a2``````a2````````a2``a2````````````````````````````````````````````````a2````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2a2````````a2a2a2``````a2``````a2``````a2a2``a2``````a2a2a2``````a2````````````a2``````a2``````a2a2a2``````a2a2a2a2````````````a2``````````````````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2``````````a2a2a2``````````````````````````````````a2``````a2``````a2a2a2````````````a2``````a2``````````````a2a2a2a2````a2``````a2````a2a2a2a2``````a2``a2``a2``````a2a2a2``````a2a2a2a2``````a2a2a2a2````````a2a2a2````````a2a2a2``````a2``````a2``````````````````a2a2a2a2````````a2a2a2``````a2``````a2``````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````a2````````````````````````````````````````````a2``````````````````````````a2``````````a2a2a2````````a2a2a2````````````a2````````a2a2a2``````````````````````````````````a2a2a2a2````````````````````````a2``````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````a2````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````a2````````````````````````````````````````````a2``````````````````````````a2``````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````a2``````````a2a2``````````a2a2````````a2``````a2````a2``````a2````````a2a2``````a2``````a2``````a2a2``````````````````````a2``````a2``````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````a2``a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````a2````````````````````````````````````````````a2``````````a2a2``````````a2a2````````a2``````a2````a2``````a2````a2``````a2````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2a2````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2````````a2``````a2``````a2a2a2``````a2``a2a2``````a2``a2a2````````a2a2a2````````a2a2a2a2````a2a2a2a2a2``````a2a2````````````a2````````a2``````a2````````````a2``````a2``a2``````a2``````a2``````a2a2``````````````````````a2``````a2``````a2a2a2``````a2a2a2a2a2````a2``a2a2````````a2a2a2``````a2``a2a2````````a2a2a2a2````a2a2``a2````````a2a2``````````a2a2a2a2``````a2a2a2a2``````a2a2``````````a2a2a2``````a2``a2a2````````````````````a2``a2a2````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2````````a2``````a2``````a2a2a2````````a2a2``a2``````````````````````a2````````a2``a2a2````````a2a2a2``````a2a2``a2``````````````````````a2a2a2a2``````a2a2a2``````a2``a2a2````````a2a2``a2``````a2a2a2``````a2``a2a2``````a2``a2a2````````a2a2a2````````a2a2a2a2````a2a2a2a2a2``````a2a2````````````a2````````````````a2````a2``````a2````a2``````a2````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2````a2````a2``````a2````a2``````a2````a2``````a2````````a2````````a2``````a2````a2``````a2````a2a2````a2````a2a2````a2````a2``````a2````a2````````````````a2``````````````````````````a2``````````a2a2a2``````````a2a2``````a2````a2````````a2a2a2``````````````````````````````````a2a2a2a2``````a2``````a2````````a2````````a2a2````a2````````````a2````a2a2````a2````a2````````````a2``a2``a2````````a2````````a2````````````a2````````````````a2````````a2``````a2````a2a2````a2``````````````````a2a2````a2````a2``````a2````a2``````a2````a2``````a2````````a2````````a2``````a2````a2``````a2````a2````a2a2````````````````````a2a2a2``````a2a2````a2````a2``````a2````a2``a2``a2``````````````````a2````````````a2``````a2````a2a2````a2````a2````a2a2````a2``````a2````a2a2````a2````a2a2````a2````a2``````a2````a2````````````````a2``````````````````````````a2````````````a2a2````````a2a2a2````````a2a2a2a2````````a2a2``````````````````a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2``````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````a2a2a2a2a2````a2````````````a2a2a2a2a2````````a2````````a2``````a2````a2a2a2a2a2````a2````````````a2``````a2````a2``````a2``````a2a2a2``````````a2``````````a2a2````````````a2````````a2``````a2````````````a2````a2a2a2a2a2````a2``````a2``````a2a2``````````````````````a2``a2````````a2a2a2a2a2````````a2````````a2``````````````a2a2a2a2````a2``````a2``````a2a2a2``````a2``a2``a2````````a2``````````a2a2a2````````a2a2a2``````````a2````````a2``````a2````a2``````a2``````````````````a2````````````a2a2a2a2a2````a2````````````a2a2a2a2a2````````a2````````a2``````a2````a2a2a2a2a2````a2``````a2``````````````````````a2````````a2````````````a2``````a2````a2``a2``a2````````````````````a2a2a2``````a2a2a2a2a2````a2``````a2````a2``````a2````a2a2a2a2a2````a2````````````a2``````a2````a2``````a2``````a2a2a2``````````a2``````````a2a2````````````a2````````````````a2````a2``````a2````````````a2````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````a2````````````a2``````a2````a2````````````````a2``````````a2``a2``````a2````````````a2````````````a2``````a2````a2``````a2````````````a2````````a2``a2``````a2a2````````````a2````````a2``````a2````a2``````a2``````````a2``````a2``````a2``````a2a2``````````````````````a2````a2``````a2````````````````a2``a2````a2````````````a2``````a2````a2``````a2````````````a2````a2``a2``a2````````a2````````````````a2````````````a2````````a2````````a2``````a2````a2``````a2``````````````````a2````````````a2````````````a2``````a2````a2````````````````a2``````````a2``a2``````a2````````````a2````a2a2``````````````````````a2````````a2````````````a2``````a2````a2``a2``a2``````````````````````````a2````a2````````````a2``````a2````a2````a2a2````a2````````````a2````````````a2``````a2````a2``````a2````````````a2````````a2``a2``````a2a2````````````a2````````a2``````a2````a2``````a2``````````a2``````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2a2``````````a2``````````a2a2a2``````a2````````````a2``````a2``````a2a2a2``````a2a2a2a2````````````a2``````````````````````a2a2a2````````a2a2a2````````a2a2a2````````````a2````````a2a2a2``````````````````````````````````a2``````a2``````a2a2a2````````````a2``````a2``````````````a2a2a2a2````a2``````a2````a2a2a2a2``````a2``a2``a2``````a2a2a2``````a2a2a2a2``````a2a2a2a2````````a2a2a2````````a2a2a2``````a2``````a2``````````````````a2``````````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2a2``````````a2``````````a2a2a2````````a2a2``a2``````````````````````a2````````a2``````````````a2a2a2``````a2``a2``a2``````````````````a2a2a2a2````````a2a2a2``````a2``````a2``````a2a2``a2``````a2a2a2``````a2````````````a2``````a2``````a2a2a2``````a2a2a2a2````````````a2``````````````````````a2a2a2````````a2a2a2````````a2a2a2````````a2a2``````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````````a2a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````a2``a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````a2````a2``````````````````a2a2a2a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2a2a2a2````````````", "````````````````a2a2a2a2a2````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````a2a2a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````a2``````a2````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````````````a2``````````````a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````````a2a2``````````````a2``a2a2a2a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2``a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2a2a2a2````````````", "````````````````````````a2``````````````a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````a2``````a2````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````a2a2a2``````````````````a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````a2a2a2``````````````````a2````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````a2``````a2````````````````a2````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````````````a2````````````````a2``````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````a2a2a2``````````````````a2a2a2a2a2a2````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2a2a2a2````````````", "````````````````a2````````````````````````a2``````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````a2````````````````````````a2``````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````a2a2a2a2a2````````````````a2````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````````a2````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````a2a2````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````````a2````````````````````a2````````````````````````````````````````````````````````````````````````````a2a2a2````````````````````````````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2``````````", "````````````````````a2````````````````````a2a2a2a2a2a2a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2a2a2``a2``a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2a2a2a2``a2````````", "````````````````````a2````````````````````a2````````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2``````````", "````````````````````a2````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2````````````", "``````````````````a2a2a2``````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````a2````````````", "``````````````````a2a2a2``````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````a2``````a2````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2a2``````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2a2````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````a2````a2a2````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````a2a2a2``````````````````````````````````````````````````````````````````````````a2a2a2````````````````````````````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````a2a2a2``````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````a2a2a2``````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````a2a2a2````````````````````````````````````````````````````````````````````````````a2````````````", "````````````````a2``a2``a2````````````````a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2````````````", "````````````````a2a2````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````a2``a2``````````````````````````````````````````````````````````````````````````````````````````", "````````````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````", "``````````````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````a2````````````````````````````````````````````````````````````````````````````````````", "``````````````````````````````````````a2``````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2````````a2``````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2````````a2``````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2````````````a2a2````````````````````````````````````````````````````````````````````````````````````", "``````````````````````````````````````a2````a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````a2````a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````a2``a2````````````````````````````````````````````````````````````````````````````````````", "``````````````````````````````````````a2``a2``a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````a2``a2``a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````a2````a2````````````````````````````````````````````````````````````````````````````````````", "``````````````````````````````````````a2a2````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````a2a2````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````a2a2a2a2a2``````````````````````````````````````````````````````````````````````````````````", "``````````````````````````````````````a2``````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````a2``````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````a2````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2````````a2a2a2``````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2``````a2a2a2a2a2````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````a2a2a2````````````a2````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````", "````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````````"],[ ]). tgif-QPL-4.2.5/rmcast/doc/manual/eventlist.eps0000644000076400007640000004441310122646341021041 0ustar williamwilliam%!PS-Adobe-3.0 EPSF-3.0 %%BoundingBox: 14 451 510 723 %%Title: eventlist %%CreationDate: Tue May 14 18:46:01 2002 %%Creator: Tgif-4.1.41 by William Chia-Wei Cheng (william@cs.UCLA.edu) %%ProducedBy: (unknown) %%Pages: 1 %%DocumentFonts: (atend) %%EndComments %%BeginProlog /tgifdict 91 dict def tgifdict begin /tgifellipsedict 6 dict def tgifellipsedict /mtrx matrix put /TGEL % tgifellipse { tgifellipsedict begin /yrad exch def /xrad exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate xrad yrad scale 0 0 1 0 360 arc savematrix setmatrix end } def /tgifarrowtipdict 8 dict def tgifarrowtipdict /mtrx matrix put /TGAT % tgifarrowtip { tgifarrowtipdict begin /dy exch def /dx exch def /h exch def /w exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate dy dx atan rotate 0 0 moveto w neg h lineto w neg h neg lineto savematrix setmatrix end } def /tgifarcdict 8 dict def tgifarcdict /mtrx matrix put /TGAN % tgifarcn { tgifarcdict begin /endangle exch def /startangle exch def /yrad exch def /xrad exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate xrad yrad scale 0 0 1 startangle endangle arc savematrix setmatrix end } def /TGAR % tgifarc { tgifarcdict begin /endangle exch def /startangle exch def /yrad exch def /xrad exch def /y exch def /x exch def /savematrix mtrx currentmatrix def x y translate xrad yrad scale 0 0 1 startangle endangle arcn savematrix setmatrix end } def /tgifpatdict 10 dict def /tgifpatbyte { currentdict /retstr get exch pat i cellsz mod get put } def /tgifpatproc { 0 1 widthlim {tgifpatbyte} for retstr /i i 1 add def } def /TGPF % tgifpatfill { tgifpatdict begin /h exch def /w exch def /lty exch def /ltx exch def /cellsz exch def /pat exch def /widthlim w cellsz div cvi 1 sub def /retstr widthlim 1 add string def /i 0 def tgiforigctm setmatrix ltx lty translate w h true [1 0 0 1 0 0] {tgifpatproc} imagemask ltx neg lty neg translate end } def /pat3 <8000000008000000> def /pat4 <8800000022000000> def /pat5 <8800220088002200> def /pat6 <8822882288228822> def /pat7 def /pat8 <77dd77dd77dd77dd> def /pat9 <77ffddff77ffddff> def /pat10 <77ffffff77ffffff> def /pat11 <7fffffff7fffffff> def /pat12 <8040200002040800> def /pat13 <40a00000040a0000> def /pat14 def /pat15 def /pat16 def /pat17 <038448300c020101> def /pat18 <081c22c180010204> def /pat19 <8080413e080814e3> def /pat20 <8040201008040201> def /pat21 <8844221188442211> def /pat22 <77bbddee77bbddee> def /pat23 def /pat24 <7fbfdfeff7fbfdfe> def /pat25 <3e1f8fc7e3f1f87c> def /pat26 <0102040810204080> def /pat27 <1122448811224488> def /pat28 def /pat29 <83070e1c3870e0c1> def /pat30 def /pat31 <7cf8f1e3c78f1f3e> def /TGMAX { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse } def /TGMIN { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse } def /TGSW { stringwidth pop } def /bd { bind def } bind def /GS { gsave } bd /GR { grestore } bd /NP { newpath } bd /CP { closepath } bd /CHP { charpath } bd /CT { curveto } bd /L { lineto } bd /RL { rlineto } bd /M { moveto } bd /RM { rmoveto } bd /S { stroke } bd /F { fill } bd /TR { translate } bd /RO { rotate } bd /SC { scale } bd /MU { mul } bd /DI { div } bd /DU { dup } bd /NE { neg } bd /AD { add } bd /SU { sub } bd /PO { pop } bd /EX { exch } bd /CO { concat } bd /CL { clip } bd /EC { eoclip } bd /EF { eofill } bd /IM { image } bd /IMM { imagemask } bd /ARY { array } bd /SG { setgray } bd /RG { setrgbcolor } bd /SD { setdash } bd /W { setlinewidth } bd /SM { setmiterlimit } bd /SLC { setlinecap } bd /SLJ { setlinejoin } bd /SH { show } bd /FF { findfont } bd /MS { makefont setfont } bd /AR { arcto 4 {pop} repeat } bd /CURP { currentpoint } bd /FLAT { flattenpath strokepath clip newpath } bd /TGSM { tgiforigctm setmatrix } def /TGRM { savematrix setmatrix } def end %%EndProlog %%Page: 1 1 %%PageBoundingBox: 14 451 510 723 tgifdict begin /tgifsavedpage save def 1 SM 1 W 0 SG 72 0 MU 72 11 MU TR 72 128 DI 100.000 MU 100 DI DU NE SC GS /tgiforigctm matrix currentmatrix def % BOX 0 SG GS 10 SM GS NP 148 246 M 323 246 L 323 353 L 148 353 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS 149 274 TR [2.059 0.000 0.000 1.000 0 0] CO 149 NE 274 NE TR GS NP 149 274 M 234 274 L TGSM 1 W S GR GR % POLY/OPEN-SPLINE 0 SG GS 147 301 TR [2.059 0.000 0.000 1.000 0 0] CO 147 NE 301 NE TR GS NP 147 301 M 232 301 L TGSM 1 W S GR GR % POLY/OPEN-SPLINE 0 SG GS 148 329 TR [2.059 0.000 0.000 1.000 0 0] CO 148 NE 329 NE TR GS NP 148 329 M 233 329 L TGSM 1 W S GR GR % TEXT NP 0 SG GS 1 W 235 266 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (member_id) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (member_id) SH GR GR % TEXT NP 0 SG GS 1 W 235 292 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (action ) TGSW AD /Courier-Oblique FF [14 0 0 -14 0 0] MS (NAK_SND_WAIT) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (action ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (NAK_SND_WAIT) SH GR GR % TEXT NP 0 SG GS 1 W 235 319 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (timer_value ) TGSW AD /Courier-Oblique FF [14 0 0 -14 0 0] MS (4) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (timer_value ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (4) SH GR GR % TEXT NP 0 SG GS 1 W 235 346 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (sn \() TGSW AD /Courier-Oblique FF [14 0 0 -14 0 0] MS (not used\)) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (sn \() SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (not used\)) SH GR GR % BOX 0 SG GS 10 SM GS NP 363 245 M 538 245 L 538 352 L 363 352 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS 364 273 TR [2.059 0.000 0.000 1.000 0 0] CO 364 NE 273 NE TR GS NP 364 273 M 449 273 L TGSM 1 W S GR GR % POLY/OPEN-SPLINE 0 SG GS 362 300 TR [2.059 0.000 0.000 1.000 0 0] CO 362 NE 300 NE TR GS NP 362 300 M 447 300 L TGSM 1 W S GR GR % POLY/OPEN-SPLINE 0 SG GS 363 328 TR [2.059 0.000 0.000 1.000 0 0] CO 363 NE 328 NE TR GS NP 363 328 M 448 328 L TGSM 1 W S GR GR % TEXT NP 0 SG GS 1 W 450 265 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (member_id ) TGSW AD /Courier-Oblique FF [14 0 0 -14 0 0] MS (not used) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (member_id ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (not used) SH GR GR % TEXT NP 0 SG GS 1 W 450 291 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (action ) TGSW AD /Courier-Oblique FF [14 0 0 -14 0 0] MS (REF_SND_WAIT) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (action ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (REF_SND_WAIT) SH GR GR % TEXT NP 0 SG GS 1 W 450 318 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (timer_value ) TGSW AD /Courier-Oblique FF [14 0 0 -14 0 0] MS (6) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (timer_value ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (6) SH GR GR % TEXT NP 0 SG GS 1 W 450 345 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (sn \() TGSW AD /Courier-Oblique FF [14 0 0 -14 0 0] MS (not used\)) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (sn \() SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (not used\)) SH GR GR % BOX 0 SG GS 10 SM GS NP 581 244 M 756 244 L 756 351 L 581 351 L CP S GR GR % POLY/OPEN-SPLINE 0 SG GS 582 272 TR [2.059 0.000 0.000 1.000 0 0] CO 582 NE 272 NE TR GS NP 582 272 M 667 272 L TGSM 1 W S GR GR % POLY/OPEN-SPLINE 0 SG GS 580 299 TR [2.059 0.000 0.000 1.000 0 0] CO 580 NE 299 NE TR GS NP 580 299 M 665 299 L TGSM 1 W S GR GR % POLY/OPEN-SPLINE 0 SG GS 581 327 TR [2.059 0.000 0.000 1.000 0 0] CO 581 NE 327 NE TR GS NP 581 327 M 666 327 L TGSM 1 W S GR GR % TEXT NP 0 SG GS 1 W 668 264 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (member_id) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (member_id) SH GR GR % TEXT NP 0 SG GS 1 W 668 290 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (action) TGSW AD /Courier-Oblique FF [14 0 0 -14 0 0] MS ( RET_SND_WAIT) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (action) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS ( RET_SND_WAIT) SH GR GR % TEXT NP 0 SG GS 1 W 668 317 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (timer_value ) TGSW AD /Courier-Oblique FF [14 0 0 -14 0 0] MS (7) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (timer_value ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (7) SH GR GR % TEXT NP 0 SG GS 1 W 668 344 M GS GS 0 /Courier FF [14 0 0 -14 0 0] MS (sn ) TGSW AD /Courier-Oblique FF [14 0 0 -14 0 0] MS (2) TGSW AD GR 2 DI NE 0 RM 0 SG /Courier FF [14 0 0 -14 0 0] MS (sn ) SH 0 SG /Courier-Oblique FF [14 0 0 -14 0 0] MS (2) SH GR GR % POLY/OPEN-SPLINE 0 SG GS NP 328 297 M 0 32 atan DU cos 8.000 MU 360 exch SU exch sin 8.000 MU 297 exch SU L TGSM 1 W S GR GS TGSM NP 360 297 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 360 297 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 546 298 M 0 32 atan DU cos 8.000 MU 578 exch SU exch sin 8.000 MU 298 exch SU L TGSM 1 W S GR GS TGSM NP 578 298 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 578 298 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 763 297 M 816 297 L 816 329 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 799 346 M 831 346 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 783 330 M 847 330 L TGSM 1 W S GR % BOX 0 SG GS 10 SM GS NP 152 404 M 324 404 L 324 451 L 152 451 L CP 2 W S GR GR % TEXT NP 0 SG GS 1 W 194 433 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (member M1) SH GR GR % BOX 0 SG GS 10 SM GS NP 151 488 M 323 488 L 323 535 L 151 535 L CP 2 W S GR GR % TEXT NP 0 SG GS 1 W 193 517 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (member M2) SH GR GR % OVAL 0 SG GS NP 404 426 20 20 TGEL CP 1 SG F 0 SG NP 404 426 20 20 TGEL CP EC NP pat26 8 376 400 56 48 TGPF GR GS GS NP 404 426 20 20 TGEL S GR GR % OVAL 0 SG GS NP 492 427 20 20 TGEL CP 1 SG F 0 SG NP 492 427 20 20 TGEL CP EC NP pat26 8 464 400 56 56 TGPF GR GS GS NP 492 427 20 20 TGEL S GR GR % OVAL 0 SG GS NP 580 428 20 20 TGEL CP 1 SG F 0 SG NP 580 428 20 20 TGEL CP EC NP pat12 8 552 400 56 56 TGPF GR GS GS NP 580 428 20 20 TGEL S GR GR % OVAL 0 SG GS NP 403 507 20 20 TGEL CP 1 SG F 0 SG NP 403 507 20 20 TGEL CP EC NP pat26 8 376 480 56 56 TGPF GR GS GS NP 403 507 20 20 TGEL S GR GR % OVAL 0 SG GS NP 495 507 20 20 TGEL CP 1 SG F 0 SG NP 495 507 20 20 TGEL CP EC NP pat26 8 472 480 48 56 TGPF GR GS GS NP 495 507 20 20 TGEL S GR GR % OVAL 0 SG GS NP 581 505 20 20 TGEL CP 1 SG F 0 SG NP 581 505 20 20 TGEL CP EC NP pat26 8 552 480 56 48 TGPF GR GS GS NP 581 505 20 20 TGEL S GR GR % POLY/OPEN-SPLINE 0 SG GS NP 603 427 M 635 427 L 635 459 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 619 475 M 651 475 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 603 459 M 667 459 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 610 501 M 642 501 L 642 533 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 626 549 M 658 549 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 610 533 M 674 533 L TGSM 1 W S GR % POLY/OPEN-SPLINE 0 SG GS NP 335 427 M 0 32 atan DU cos 8.000 MU 367 exch SU exch sin 8.000 MU 427 exch SU L TGSM 1 W S GR GS TGSM NP 367 427 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 367 427 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 433 427 M 0 32 atan DU cos 8.000 MU 465 exch SU exch sin 8.000 MU 427 exch SU L TGSM 1 W S GR GS TGSM NP 465 427 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 465 427 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 519 427 M 0 32 atan DU cos 8.000 MU 551 exch SU exch sin 8.000 MU 427 exch SU L TGSM 1 W S GR GS TGSM NP 551 427 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 551 427 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 521 506 M 0 32 atan DU cos 8.000 MU 553 exch SU exch sin 8.000 MU 506 exch SU L TGSM 1 W S GR GS TGSM NP 553 506 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 553 506 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 433 507 M 0 32 atan DU cos 8.000 MU 465 exch SU exch sin 8.000 MU 507 exch SU L TGSM 1 W S GR GS TGSM NP 465 507 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 465 507 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 335 509 M 0 32 atan DU cos 8.000 MU 367 exch SU exch sin 8.000 MU 509 exch SU L TGSM 1 W S GR GS TGSM NP 367 509 8.000 3.000 32 0 TGAT 1 SG CP F 0 SG NP 367 509 8.000 3.000 32 0 TGAT CP F GR % POLY/OPEN-SPLINE 0 SG GS NP 241 454 M 29 0 atan DU cos 8.000 MU 241 exch SU exch sin 8.000 MU 483 exch SU L TGSM 1 W S GR GS TGSM NP 241 483 8.000 3.000 0 29 TGAT 1 SG CP F 0 SG NP 241 483 8.000 3.000 0 29 TGAT CP F GR % ARC 0 SG GS GS NP 184 347 86 86 -95 -261 TGAR S GR GR GS TGSM NP 177 433 8.000 3.000 171 15 TGAT 1 SG CP F 0 SG NP 177 433 8.000 3.000 171 15 TGAT CP F GR % ARC 0 SG GS GS NP 255 345 188 188 -150 -239 TGAR S GR GR GS TGSM NP 164 509 8.000 3.000 329 182 TGAT 1 SG CP F 0 SG NP 164 509 8.000 3.000 329 182 TGAT CP F GR % ARC 0 SG GS GS NP 348 1339 828 1145 -108 -71 TGAN S GR GR % RCBOX 0 SG GS GS NP 684 380 M 700 380 700 569 16 AR 700 553 L 700 569 135 569 16 AR 151 569 L 135 569 135 380 16 AR 135 396 L 135 380 700 380 16 AR CP [12 4] 0 SD S GR GR % RCBOX 0 SG GS GS NP 841 231 M 857 231 857 367 16 AR 857 351 L 857 367 138 367 16 AR 154 367 L 138 367 138 231 16 AR 138 247 L 138 231 857 231 16 AR CP [12 4] 0 SD S GR GR % TEXT NP 0 SG GS 1 W 759 388 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (event list) SH GR GR % TEXT NP 0 SG GS 1 W 643 586 M GS 0 SG /Courier FF [14 0 0 -14 0 0] MS (cache) SH GR GR % TEXT NP 0 SG GS 1 W 272 159 M GS 0 SG /Courier-Bold FF [24 0 0 -24 0 0] MS (Event List Organization) DU TGSW EX SH GS CURP M 0 2 RM NE 0 RL S GR GR GR % BOX 0 SG GS 10 SM GS NP 29 125 M 903 125 L 903 601 L 29 601 L CP 3 W S GR GR GR tgifsavedpage restore end showpage %%Trailer %MatchingCreationDate: Tue May 14 18:46:01 2002 %%DocumentFonts: Courier-Bold %%+ Courier-Oblique %%+ Courier %%EOF tgif-QPL-4.2.5/rmcast/doc/manual/Makefile0000644000076400007640000000051210434444335017750 0ustar williamwilliam all: latex tgwb.tex && bibtex tgwb && latex tgwb.tex && latex tgwb.tex && dvips -o tgwb.ps -t a4 tgwb.dvi && gv tgwb.ps pdf: latex tgwb.tex && bibtex tgwb && latex tgwb.tex && latex tgwb.tex && dvipdfm -o tgwb.pdf -p a4 tgwb.dvi && acroread tgwb.pdf clean: \rm -f *.toc *.aux *.dvi *.ps *.pdf *.lof *.log *.lot *.bbl *.blg tgif-QPL-4.2.5/rmcast/doc/manual/cache.obj0000644000076400007640000006201611077130422020047 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,0,0,1,16,0,9,1,1,1,0,0,0,1,0,'Courier-Bold',1,138240,0,5,0,10,0,0,1,1,0,16,0,0,1,1,1,0,1088,1408,1,0,2880,1). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/cache.obj,v 1.3 2008/10/20 16:25:54 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 50971, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 40569, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). page(1,"",1,''). poly('black','',2,[ 195,658,195,687],1,1,1,875,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 305,471,367,471],1,1,1,882,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). oval('black','',372,453,406,487,26,1,1,883,0,0,0,0,0,'1',1,[ ]). oval('black','',478,454,512,488,26,1,1,885,0,0,0,0,0,'1',1,[ ]). oval('black','',581,453,615,487,12,1,1,887,0,0,0,0,0,'1',1,[ ]). poly('black','',2,[ 410,470,472,470],1,1,1,889,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 515,470,577,470],1,1,1,892,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 304,630,366,630],1,1,1,894,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 621,470,661,470,661,495],1,1,1,895,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 626,500,700,500],0,1,1,896,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 636,506,688,506],0,1,1,899,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 651,512,669,512],0,1,1,900,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). oval('black','',368,611,402,645,0,1,1,919,0,0,0,0,0,'1',0,[ ]). oval('black','',474,612,508,646,0,1,1,920,0,0,0,0,0,'1',0,[ ]). poly('black','',2,[ 406,628,468,628],1,1,1,922,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 516,628,556,628,556,653],1,1,1,924,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 521,658,595,658],0,1,1,925,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 531,667,583,667],0,1,1,926,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 546,677,564,677],0,1,1,927,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ box('black','',104,381,305,413,0,1,1,615,0,0,0,0,0,'1',0,[ ]), text('black',125,389,1,0,1,162,16,651,13,3,0,0,0,0,2,162,16,0,0,"",0,0,0,0,402,'',[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,153,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,153,13,3,0,-8,0,0,0,0,0, "number_of_nodes: ")]), str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-2,0,0,0,0,0, "3")]) ]) ])]) ], 671,0,0,[ ]). group([ box('black','',104,418,305,450,0,1,1,677,0,0,0,0,0,'1',0,[ ]), text('black',125,426,1,0,1,81,16,676,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,439,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,72,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-8,0,0,0,0,0, "active: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 675,0,0,[ ]). group([ box('black','',104,454,305,486,0,1,1,744,0,0,0,0,0,'1',0,[ ]), text('black',125,462,1,0,1,45,16,743,13,3,0,0,0,0,2,45,16,0,0,"",0,0,0,0,475,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-2,0,0,0,0,0, "first")]) ]) ])]) ], 742,0,0,[ ]). box('black','',107,525,297,557,0,1,1,749,0,0,0,0,0,'1',0,[ ]). text('black',113,527,2,0,1,179,30,748,13,3,0,0,0,0,2,189,30,0,0,"",0,1,0,0,541,'',[ 113,527,113,527,302,557,945.274,0,0,1000,-2,0,112,526,303,558],[ minilines(189,30,0,0,0,0,0,[ mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,135,13,3,0,-8,0,0,0,0,0, " member_id ")]) ]), mini_line(189,11,3,0,0,0,[ str_block(0,189,11,3,0,-3,0,0,0,[ str_seg('black','Courier',0,69120,189,11,3,0,-3,0,0,0,0,0, "(ip: 192.168.0.2, pid: 123)")]) ]) ])]). box('black','',107,570,296,602,0,2,1,755,8,0,0,0,0,'2',0,[ ]). text('black',111,578,1,0,1,144,16,754,13,3,0,0,0,0,2,153,16,0,0,"",0,1,0,0,591,'',[ 111,578,111,578,264,594,940.299,0,0,1000,-1,0,110,577,265,595],[ minilines(153,16,0,0,0,0,0,[ mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,153,13,3,0,-2,0,0,0,0,0, " member_status")]) ]) ])]). text('black',108,497,1,0,1,63,16,761,13,3,0,0,0,0,2,63,16,0,0,"",0,0,0,0,510,'',[ minilines(63,16,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "sm_info")]) ]) ])]). box('black','',104,491,305,612,0,2,1,763,0,0,0,0,0,'2',0,[ ]). group([ box('black','',104,616,305,648,0,1,1,775,0,0,0,0,0,'1',0,[ ]), text('black',125,624,1,0,1,72,16,774,13,3,0,0,0,0,2,72,16,0,0,"",0,0,0,0,637,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-2,0,0,0,0,0, "nak_list")]) ]) ])]) ], 773,0,0,[ ]). box('black','',97,374,313,655,0,3,1,808,0,0,0,0,0,'3',0,[ ]). group([ box('black','',105,697,306,729,0,1,1,1061,0,0,0,0,0,'1',0,[ ]), text('black',126,705,1,0,1,162,16,1060,13,3,0,0,0,0,2,162,16,0,0,"",0,0,0,0,718,'',[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,153,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,153,13,3,0,-8,0,0,0,0,0, "number_of_nodes: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 1059,0,0,[ ]). group([ box('black','',105,734,306,766,0,1,1,1058,0,0,0,0,0,'1',0,[ ]), text('black',126,742,1,0,1,81,16,1057,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,755,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,72,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-8,0,0,0,0,0, "active: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 1056,0,0,[ ]). group([ box('black','',105,770,306,802,0,1,1,1055,0,0,0,0,0,'1',0,[ ]), text('black',126,778,1,0,1,45,16,1054,13,3,0,0,0,0,2,45,16,0,0,"",0,0,0,0,791,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-2,0,0,0,0,0, "first")]) ]) ])]) ], 1053,0,0,[ ]). box('black','',108,841,298,873,0,1,1,1052,0,0,0,0,0,'1',0,[ ]). group([ box('black','',108,886,297,918,0,1,1,1049,0,0,0,0,0,'1',0,[ ]), text('black',129,894,1,0,1,135,16,1048,13,3,0,0,0,0,2,144,16,0,0,"",0,1,0,0,907,'',[ 129,894,129,894,273,910,940.299,0,0,1000,-1,0,128,893,274,911],[ minilines(144,16,0,0,0,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-2,0,0,0,0,0, " member_status")]) ]) ])]) ], 1047,0,0,[ ]). text('black',109,813,1,0,1,63,16,1046,13,3,0,0,0,0,2,63,16,0,0,"",0,0,0,0,826,'',[ minilines(63,16,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "sm_info")]) ]) ])]). box('black','',105,807,306,928,0,2,1,1045,0,0,0,0,0,'2',0,[ ]). group([ box('black','',105,932,306,964,0,1,1,1044,0,0,0,0,0,'1',0,[ ]), text('black',126,940,1,0,1,72,16,1043,13,3,0,0,0,0,2,72,16,0,0,"",0,0,0,0,953,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-2,0,0,0,0,0, "nak_list")]) ]) ])]) ], 1042,0,0,[ ]). box('black','',98,690,314,971,0,3,1,1041,0,0,0,0,0,'3',0,[ ]). poly('black','',2,[ 305,786,367,786],1,1,1,1072,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). oval('black','',372,768,406,802,26,1,1,1073,0,0,0,0,0,'1',1,[ ]). poly('black','',3,[ 408,785,448,785,448,810],1,1,1,1078,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 413,815,487,815],0,1,1,1079,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 423,824,475,824],0,1,1,1080,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 438,834,456,834],0,1,1,1081,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 306,946,368,946],1,1,1,1094,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). oval('black','',371,927,405,961,0,1,1,1095,0,0,0,0,0,'1',0,[ ]). poly('black','',3,[ 405,944,445,944,445,969],1,1,1,1098,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 410,974,484,974],0,1,1,1099,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 420,983,472,983],0,1,1,1100,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',384,494,1,0,1,9,16,1418,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,506,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "0")]) ]) ])]). text('black',490,492,1,0,1,9,16,1422,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,504,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,-1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,-1,0,0,0,0,0, "1")]) ]) ])]). text('black',592,493,1,0,1,9,16,1424,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,505,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "4")]) ]) ])]). text('black',380,656,1,0,1,9,16,1427,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,668,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "2")]) ]) ])]). text('black',488,655,1,0,1,9,16,1430,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,667,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "3")]) ]) ])]). text('black',384,812,1,0,1,9,16,1433,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,824,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "0")]) ]) ])]). text('black',386,974,1,0,1,9,16,1435,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,986,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,-1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,-1,0,0,0,0,0, "1")]) ]) ])]). text('black',116,842,2,0,1,179,30,1497,13,3,0,0,0,0,2,189,30,0,0,"",0,1,0,0,856,'',[ 116,842,116,842,305,872,945.274,0,0,1000,-2,0,115,841,306,873],[ minilines(189,30,0,0,0,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-8,0,0,0,0,0, " member_id ")]) ]), mini_line(189,11,3,0,0,0,[ str_block(0,189,11,3,0,-3,0,0,0,[ str_seg('black','Courier',0,69120,189,11,3,0,-3,0,0,0,0,0, "(ip: 192.168.0.3, pid: 125)")]) ]) ])]). text('black',375,620,1,0,1,18,16,1535,12,4,0,0,0,0,2,18,16,0,1,"",0,0,0,1,632,'',[ minilines(18,16,0,1,0,0,0,[ mini_line(18,12,4,0,1,0,[ str_block(0,18,12,4,0,1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,18,12,4,0,1,0,0,0,0,0, "2x")]) ]) ])]). text('black',481,621,1,0,1,18,16,1538,12,4,0,0,0,0,2,18,16,0,1,"",0,0,0,1,633,'',[ minilines(18,16,0,1,0,0,0,[ mini_line(18,12,4,0,1,0,[ str_block(0,18,12,4,0,1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,18,12,4,0,1,0,0,0,0,0, "1x")]) ]) ])]). text('black',380,936,1,0,1,18,16,1546,12,4,0,0,0,0,2,18,16,0,1,"",0,0,0,1,948,'',[ minilines(18,16,0,1,0,0,0,[ mini_line(18,12,4,0,1,0,[ str_block(0,18,12,4,0,1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,18,12,4,0,1,0,0,0,0,0, "1x")]) ]) ])]). poly('black','',2,[ 195,976,195,1005],1,1,1,1600,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). box('black','',300,574,334,597,0,1,0,1626,0,0,0,0,0,'1',1,[ attr("", "auto_center_attr", 0, 1, 0, text('black',317,573,1,1,1,240,25,1627,20,5,0,0,0,0,2,240,25,0,0,"",0,0,0,0,593,'',[ minilines(240,25,0,0,1,0,0,[ mini_line(240,20,5,0,0,0,[ str_block(0,240,20,5,0,-2,0,0,0,[ str_seg('black','Courier-Bold',1,138240,240,20,5,0,-2,1,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('black',317,572,1,1,1,0,25,1628,20,5,0,0,0,0,2,0,25,0,0,"",0,0,0,0,592,'',[ minilines(0,25,0,0,1,0,0,[ mini_line(0,20,5,0,0,0,[ str_block(0,0,20,5,0,0,0,0,0,[ str_seg('black','Courier-Bold',1,138240,0,20,5,0,0,1,0,0,0,0, "")]) ]) ])])) ]). group([ poly('black','',2,[ 159,1007,233,1007],0,1,1,1604,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 169,1016,221,1016],0,1,1,1605,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 184,1026,202,1026],0,1,1,1606,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 2845,0,0,[ ]). group([ box('black','',103,65,304,97,0,1,1,2881,0,0,0,0,0,'1',0,[ ]), text('black',124,73,1,0,1,162,16,2880,13,3,0,0,0,0,2,162,16,0,0,"",0,0,0,0,86,'',[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,153,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,153,13,3,0,-8,0,0,0,0,0, "number_of_nodes: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 2879,0,0,[ ]). group([ box('black','',103,102,304,134,0,1,1,2878,0,0,0,0,0,'1',0,[ ]), text('black',124,110,1,0,1,81,16,2877,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,123,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,72,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-8,0,0,0,0,0, "active: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]) ], 2876,0,0,[ ]). group([ box('black','',103,138,304,170,0,1,1,2875,0,0,0,0,0,'1',0,[ ]), text('black',124,146,1,0,1,45,16,2874,13,3,0,0,0,0,2,45,16,0,0,"",0,0,0,0,159,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-2,0,0,0,0,0, "first")]) ]) ])]) ], 2873,0,0,[ ]). box('black','',106,209,296,241,0,1,1,2872,0,0,0,0,0,'1',0,[ ]). group([ box('black','',106,254,295,286,0,1,1,2871,0,0,0,0,0,'1',0,[ ]), text('black',127,262,1,0,1,135,16,2870,13,3,0,0,0,0,2,144,16,0,0,"",0,1,0,0,275,'',[ 127,262,127,262,271,278,940.299,0,0,1000,-1,0,126,261,272,279],[ minilines(144,16,0,0,0,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-2,0,0,0,0,0, " member_status")]) ]) ])]) ], 2869,0,0,[ ]). text('black',107,181,1,0,1,63,16,2868,13,3,0,0,0,0,2,63,16,0,0,"",0,0,0,0,194,'',[ minilines(63,16,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "sm_info")]) ]) ])]). box('black','',103,175,304,296,0,2,1,2867,0,0,0,0,0,'2',0,[ ]). group([ box('black','',103,300,304,332,0,1,1,2866,0,0,0,0,0,'1',0,[ ]), text('black',124,308,1,0,1,72,16,2865,13,3,0,0,0,0,2,72,16,0,0,"",0,0,0,0,321,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-2,0,0,0,0,0, "nak_list")]) ]) ])]) ], 2864,0,0,[ ]). box('black','',96,58,312,339,0,3,1,2863,0,0,0,0,0,'3',0,[ ]). poly('black','',2,[ 303,154,365,154],1,1,1,2862,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). oval('black','',370,136,404,170,26,1,1,2861,0,0,0,0,0,'1',1,[ ]). poly('black','',3,[ 406,153,446,153,446,178],1,1,1,2860,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 411,183,485,183],0,1,1,2859,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 421,192,473,192],0,1,1,2858,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 436,202,454,202],0,1,1,2857,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',382,180,1,0,1,9,16,2850,12,4,0,0,0,0,2,9,16,0,0,"",0,0,0,1,192,'',[ minilines(9,16,0,0,0,0,0,[ mini_line(9,12,4,0,0,0,[ str_block(0,9,12,4,0,0,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,9,12,4,0,0,0,0,0,0,0, "0")]) ]) ])]). text('black',114,210,2,0,1,179,30,2848,13,3,0,0,0,0,2,189,30,0,0,"",0,1,0,0,224,'',[ 114,210,114,210,303,240,945.274,0,0,1000,-2,0,113,209,304,241],[ minilines(189,30,0,0,0,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,144,13,3,0,-8,0,0,0,0,0, " member_id ")]) ]), mini_line(189,11,3,0,0,0,[ str_block(0,189,11,3,0,-3,0,0,0,[ str_seg('black','Courier',0,69120,189,11,3,0,-3,0,0,0,0,0, "(ip: 192.168.0.1, pid: 225)")]) ]) ])]). poly('black','',2,[ 195,340,195,369],1,1,1,2884,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 305,315,404,315,404,340],1,1,1,2933,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 369,345,443,345],0,1,1,2934,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 379,354,431,354],0,1,1,2935,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 394,364,412,364],0,1,1,2936,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ text('black',592,838,1,0,1,49,14,1547,11,3,0,0,0,0,2,49,14,0,0,"",0,0,0,1,849,'',[ minilines(49,14,0,0,0,0,0,[ mini_line(49,11,3,0,0,0,[ str_block(0,49,11,3,0,-2,0,0,0,[ str_seg('black','Courier-BoldOblique',3,69120,49,11,3,0,-2,0,0,0,0,0, "Legend:")]) ]) ])]), oval('black','',593,861,627,895,26,1,1,1550,0,0,0,0,0,'1',1,[ ]), oval('black','',593,907,627,941,12,1,1,1552,0,0,0,0,0,'1',1,[ ]), oval('black','',593,954,627,988,0,1,1,1555,0,0,0,0,0,'1',0,[ ]), text('black',642,868,1,0,1,252,16,1559,13,3,0,0,0,0,2,252,16,0,0,"",0,0,0,1,881,'',[ minilines(252,16,0,0,0,0,0,[ mini_line(252,13,3,0,0,0,[ str_block(0,252,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,252,13,3,0,-4,0,0,0,0,0, "Packet received in sequence.")]) ]) ])]), text('black',644,910,2,0,1,252,32,1563,13,3,0,0,0,0,2,252,32,0,0,"",0,0,0,1,923,'',[ minilines(252,32,0,0,0,0,0,[ mini_line(252,13,3,0,0,0,[ str_block(0,252,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,252,13,3,0,-1,0,0,0,0,0, "Packet received out of order")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,135,13,3,0,-4,0,0,0,0,0, "(gap detected).")]) ]) ])]), text('black',643,962,2,0,1,216,32,1566,13,3,0,0,0,0,2,216,32,0,0,"",0,0,0,1,975,'',[ minilines(216,32,0,0,0,0,0,[ mini_line(216,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-1,0,0,0,0,0, "n")]), str_block(0,207,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,207,13,3,0,-8,0,0,0,0,0, " NACKs for this packet ")]) ]), mini_line(180,13,3,0,0,0,[ str_block(0,180,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,180,13,3,0,-4,0,0,0,0,0, "have just been sent.")]) ]) ])]), text('black',601,963,1,0,1,18,16,1570,12,4,0,0,0,0,2,18,16,0,1,"",0,0,0,1,975,'',[ minilines(18,16,0,1,0,0,0,[ mini_line(18,12,4,0,1,0,[ str_block(0,18,12,4,0,1,0,0,0,[ str_seg('black','Courier-BoldOblique',3,80640,18,12,4,0,1,0,0,0,0,0, "nx")]) ]) ])]), box('black','',575,822,941,1019,0,2,1,1574,0,0,0,0,0,'2',1,[ ]) ], 2946,0,0,[ ]). group([ box('black','',701,535,943,760,0,2,1,1642,8,0,0,0,0,'2',1,[ ]), box('black','',725,572,914,749,0,1,1,1646,0,0,0,0,0,'1',0,[ ]), text('black',765,540,1,0,1,110,16,1647,13,3,0,0,0,0,2,117,16,0,0,"",0,1,0,0,553,'',[ 765,540,765,540,882,556,940.299,0,0,1000,-1,0,764,539,883,557],[ minilines(117,16,0,0,0,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,117,13,3,0,-2,0,0,0,0,0, "member_status")]) ]) ])]), poly('black','',2,[ 724,648,914,648],0,1,1,1684,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 726,621,914,621],0,1,1,1687,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 724,674,914,674],0,1,1,1688,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 725,700,915,700],0,1,1,1690,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), text('black',743,576,1,0,1,102,16,1698,13,3,0,0,0,0,2,108,16,0,0,"",0,1,0,0,589,'',[ 743,576,743,576,851,592,940.299,0,0,1000,-1,0,742,575,852,593],[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,99,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-8,0,0,0,0,0, "first_rcv: ")]), str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-1,0,0,0,0,0, "0")]) ]) ])]), text('black',743,602,1,0,1,102,16,1701,13,3,0,0,0,0,2,108,16,0,0,"",0,1,0,0,615,'',[ 743,602,743,602,851,618,940.299,0,0,1000,-1,0,742,601,852,619],[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,90,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-8,0,0,0,0,0, "last_rcv: ")]), str_block(0,18,13,3,0,-8,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,18,13,3,0,-8,0,0,0,0,0, "4 ")]) ]) ])]), text('black',743,626,1,0,1,127,16,1704,13,3,0,0,0,0,2,135,16,0,0,"",0,1,0,0,639,'',[ 743,626,743,626,878,642,940.299,0,0,1000,-1,0,742,625,879,643],[ minilines(135,16,0,0,0,0,0,[ mini_line(135,13,3,0,0,0,[ str_block(0,126,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,126,13,3,0,-8,0,0,0,0,0, "last_seq_rcv: ")]), str_block(0,9,13,3,0,-3,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-3,0,0,0,0,0, "1")]) ]) ])]), text('black',743,653,1,0,1,152,16,1707,13,3,0,0,0,0,2,162,16,0,0,"",0,1,0,0,666,'',[ 743,653,743,653,905,669,940.299,0,0,1000,-1,0,742,652,906,670],[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,153,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,153,13,3,0,-8,0,0,0,0,0, "last_identified: ")]), str_block(0,9,13,3,0,-2,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-2,0,0,0,0,0, "4")]) ]) ])]), poly('black','',2,[ 724,726,914,726],0,1,1,1730,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 726,598,914,598],0,1,1,1733,0,0,0,0,0,0,0,'1',1,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), text('black',743,678,1,0,1,118,16,1735,13,3,0,0,0,0,2,126,16,0,0,"",0,1,0,0,691,'',[ 743,678,743,678,869,694,940.299,0,0,1000,-1,0,742,677,870,695],[ minilines(126,16,0,0,0,0,0,[ mini_line(126,13,3,0,0,0,[ str_block(0,117,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,117,13,3,0,-8,0,0,0,0,0, "window_size: ")]), str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,9,13,3,0,-1,0,0,0,0,0, "5")]) ]) ])]), text('black',743,704,1,0,1,152,16,1738,13,3,0,0,0,0,2,162,16,0,0,"",0,1,0,0,717,'',[ 743,704,743,704,905,720,940.299,0,0,1000,-1,0,742,703,906,721],[ minilines(162,16,0,0,0,0,0,[ mini_line(162,13,3,0,0,0,[ str_block(0,117,13,3,0,-8,0,0,0,[ str_seg('black','Courier',0,80640,117,13,3,0,-8,0,0,0,0,0, "window_mask: ")]), str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,45,13,3,0,-1,0,0,0,0,0, "00110")]) ]) ])]), text('black',743,729,1,0,1,110,16,1741,13,3,0,0,0,0,2,117,16,0,0,"",0,1,0,0,742,'',[ 743,729,743,729,860,745,940.299,0,0,1000,-1,0,742,728,861,746],[ minilines(117,16,0,0,0,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,99,13,3,0,-4,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-4,0,0,0,0,0, "window_ini:")]), str_block(0,18,13,3,0,-2,0,0,0,[ str_seg('black','Courier-Oblique',2,80640,18,13,3,0,-2,0,0,0,0,0, " 2")]) ]) ])]) ], 2973,0,0,[ ]). poly('black','',3,[ 296,602,600,602,700,758],0,2,1,2977,0,0,5,0,0,0,0,'2',1,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ ]). poly('black','',3,[ 295,570,602,570,702,535],0,2,1,2988,0,0,5,0,0,0,0,'2',1,0, "0","",[ 0,10,4,0,'10','4','0'],[0,10,4,0,'10','4','0'],[ ]). poly('black','',2,[ 438,992,456,992],0,1,1,3511,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). tgif-QPL-4.2.5/rmcast/doc/manual/wbarch.obj0000644000076400007640000004527411077130423020262 0ustar williamwilliam%TGIF 4.1.41 state(0,37,100.000,0,0,0,16,0,10,1,1,0,0,2,0,1,1,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,0,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/rmcast-qpl/doc/manual/wbarch.obj,v 1.3 2008/10/20 16:25:55 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49931, 50971, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 22885, 40569, 40569, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 10402, 19764, 18724, 12079, 20303, 20303, 1 ]). script_frac("0.6"). fg_bg_colors('DarkSlateGray','white'). page(1,"",1,''). box('black','',91,192,219,542,0,1,1,11,0,0,0,0,0,'1',0,[ ]). text('black',155,243,2,1,1,54,32,12,13,3,0,0,0,0,2,54,32,0,0,"",0,0,0,0,256,'',[ minilines(54,32,0,0,1,0,0,[ mini_line(36,13,3,0,0,0,[ str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, "main")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "thread")]) ]) ])]). box('black','',230,192,358,320,0,1,1,22,0,0,0,0,0,'1',0,[ ]). text('black',294,227,4,1,1,72,64,21,13,3,0,0,0,0,2,72,64,0,0,"",0,0,0,0,240,'',[ minilines(72,64,0,0,1,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "reliable")]) ]), mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "message")]) ]), mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "receiver")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "thread")]) ]) ])]). box('black','',400,192,528,320,0,1,1,25,0,0,0,0,0,'1',0,[ ]). text('black',464,227,4,1,1,72,64,24,13,3,0,0,0,0,2,72,64,0,0,"",0,0,0,0,240,'',[ minilines(72,64,0,0,1,0,0,[ mini_line(27,13,3,0,0,0,[ str_block(0,27,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,27,13,3,0,0,0,0,0,0,0, "raw")]) ]), mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "message")]) ]), mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "receiver")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "thread")]) ]) ])]). box('black','',546,192,674,320,0,1,1,28,0,0,0,0,0,'1',0,[ ]). text('black',610,227,3,1,1,63,48,27,13,3,0,0,0,0,2,63,48,0,0,"",0,0,0,0,240,'',[ minilines(63,48,0,0,1,0,0,[ mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-2,0,0,0,0,0, "signal")]) ]), mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "handler")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "thread")]) ]) ])]). box('black','',693,192,821,320,0,1,1,31,0,0,0,0,0,'1',0,[ ]). text('black',757,227,3,1,1,108,48,30,13,3,0,0,0,0,2,108,48,0,0,"",0,0,0,0,240,'',[ minilines(108,48,0,0,1,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-2,0,0,0,0,0, "current")]) ]), mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "state server")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "thread")]) ]) ])]). poly('black','',3,[ 514,336,514,353,482,353],1,1,1,67,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 346,352,313,352,313,335],1,1,1,82,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',542,67,1,1,1,180,16,86,13,3,0,0,0,0,2,180,16,0,0,"",0,0,0,0,80,'',[ minilines(180,16,0,0,1,0,0,[ mini_line(180,13,3,0,0,0,[ str_block(0,180,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,180,13,3,0,-1,0,0,0,0,0, "event list and cache")]) ]) ])]). poly('black','',2,[ 469,215,469,93],3,1,1,89,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',2,[ 601,92,601,215],3,1,1,90,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 762,324,678,492,436,492],1,1,1,103,0,0,2,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 168,505,147,505,147,290],1,1,1,107,0,0,2,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ box('black','',411,42,693,106,0,1,1,85,0,0,0,0,0,'1',0,[ ]), box('black','',403,39,701,109,0,1,1,91,0,0,0,0,0,'1',0,[ ]) ], 113,0,0,[ ]). poly('black','',3,[ 266,328,487,480,438,480],1,1,1,123,0,0,2,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). group([ rcbox('black','',303,470,433,504,0,1,1,0,16,93,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 337,471,337,505],0,1,1,94,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 367,470,367,504],0,1,1,97,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 400,470,400,505],0,1,1,98,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 132,0,0,[ ]). group([ box('black','',352,335,480,367,0,1,1,3,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 352,335,352,367],0,1,1,7,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 384,335,384,367],0,1,1,8,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 416,335,416,367],0,1,1,9,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 448,335,448,367],0,1,1,10,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 142,0,0,[ ]). poly('black','',2,[ 728,516,200,516],1,1,1,166,0,0,2,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',578,518,1,1,1,153,16,163,13,3,0,0,0,0,2,153,16,0,0,"",0,0,0,0,531,'',[ minilines(153,16,0,0,1,0,0,[ mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,153,13,3,0,-1,0,0,0,0,0, "X event generated")]) ]) ])]). text('black',644,391,3,1,1,99,48,188,13,3,0,0,0,0,2,99,48,0,0,"",0,0,0,0,404,'',[ minilines(99,48,0,0,1,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "new user")]) ]), mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,99,13,3,0,-1,0,0,0,0,0, "entered the")]) ]), mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "group")]) ]) ])]). text('black',771,539,1,1,1,117,16,198,13,3,0,0,0,0,2,117,16,0,0,"",0,0,0,0,552,'',[ minilines(117,16,0,0,1,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,117,13,3,0,-1,0,0,0,0,0, "X event queue")]) ]) ])]). poly('black','',2,[ 300,489,205,489],1,1,1,205,0,0,3,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',487,422,2,1,1,90,32,214,13,3,0,0,0,0,2,90,32,0,0,"",0,0,0,0,435,'',[ minilines(90,32,0,0,1,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "new data")]) ]), mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, " available")]) ]) ])]). text('black',184,423,3,1,1,54,48,219,13,3,0,0,0,0,2,54,48,0,0,"",0,0,0,0,436,'',[ minilines(54,48,0,0,1,0,0,[ mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-2,0,0,0,0,0, "select")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,0,0,0,0,0,0, "system")]) ]), mini_line(36,13,3,0,0,0,[ str_block(0,36,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,36,13,3,0,-2,0,0,0,0,0, "call")]) ]) ])]). group([ box('black','',743,419,785,531,0,1,1,191,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 743,438,787,438],0,1,1,192,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 742,463,786,463],0,1,1,195,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 742,486,786,486],0,1,1,196,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 742,507,786,507],0,1,1,197,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 227,0,0,[ ]). poly('black','',2,[ 184,476,184,521],0,7,1,252,0,0,0,0,0,0,0,'7',0,0, "0","",[ 0,22,9,0,'22','9','0'],[0,22,9,0,'22','9','0'],[ ]). poly('black','',7,[ 110,184,124,170,231,170,241,161,250,171,334,171,347,186],0,1,1,264,0,0,0,0,0,0,0,'1',0,0, "00","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',236,143,1,1,1,108,16,268,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,156,'',[ minilines(108,16,0,0,1,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,108,13,3,0,-2,0,0,0,0,0, "tgwb threads")]) ]) ])]). poly('black','',7,[ 411,184,422,169,748,169,759,159,769,169,805,169,816,183],0,1,1,271,0,0,0,0,0,0,0,'1',0,0, "00","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',716,141,1,1,1,207,16,272,13,3,0,0,0,0,2,207,16,0,0,"",0,0,0,0,154,'',[ minilines(207,16,0,0,1,0,0,[ mini_line(207,13,3,0,0,0,[ str_block(0,207,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,207,13,3,0,-2,0,0,0,0,0, "rmcast internal threads")]) ]) ])]). arc('black','',0,1,1,0,515,233,575,293,525,327,625,327,0,120,120,-9280,7104,291,0,1,8,3,0,0,0,'1','8','3',0,[ ]). text('black',598,356,1,1,1,135,16,294,13,3,0,0,0,0,2,135,16,0,0,"",0,0,0,0,369,'',[ minilines(135,16,0,0,1,0,0,[ mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,135,13,3,0,-1,0,0,0,0,0, "send signals to")]) ]) ])]). box('black','',47,5,883,560,0,1,1,298,0,0,0,0,0,'1',0,[ ]). text('black',465,4,1,1,1,700,33,300,26,7,0,0,0,0,2,700,33,0,0,"",0,0,0,0,30,'',[ minilines(700,33,0,0,1,0,0,[ mini_line(700,26,7,0,0,0,[ str_block(0,700,26,7,0,-1,0,0,0,[ str_seg('black','Courier-Bold',1,195840,700,26,7,0,-1,0,0,0,0,0, "Tangram II Whiteboard Architechture")]) ]) ])]). group([ box('black','',235,365,271,445,0,1,1,309,0,0,0,0,0,'1',0,[ ]), poly('black','',2,[ 235,384,273,384],0,1,1,310,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 234,405,272,405],0,1,1,313,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('black','',2,[ 234,425,272,425],0,1,1,314,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 319,0,0,[ ]). poly('black','',2,[ 251,325,251,360],1,1,1,320,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). poly('black','',3,[ 252,452,252,462,224,462],1,1,1,321,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',415,369,1,1,1,117,16,330,13,3,0,0,0,0,2,117,16,0,0,"",0,0,0,0,382,'',[ minilines(117,16,0,0,1,0,0,[ mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,117,13,3,0,-1,0,0,0,0,0, "message queue")]) ]) ])]). text('black',276,398,3,0,1,90,48,333,13,3,0,0,0,0,2,90,48,0,0,"",0,0,0,0,411,'',[ minilines(90,48,0,0,0,0,0,[ mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, "whiteboard")]) ]), mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "message")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "buffer")]) ]) ])]). text('black',340,449,1,0,1,36,16,340,13,3,0,0,0,0,2,36,16,0,0,"",0,0,0,0,462,'',[ minilines(36,16,0,0,0,0,0,[ mini_line(36,13,3,0,0,0,[ str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, "pipe")]) ]) ])]). poly('black','',2,[ 228,100,396,188],1,1,1,344,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). box('DarkSlateGray','',400,190,413,196,1,1,1,345,0,0,0,0,0,'1',0,[ ]). text('DarkSlateGray',403,195,2,0,1,54,32,350,13,3,0,0,0,0,2,54,32,0,0,"",0,0,0,0,208,'',[ minilines(54,32,0,0,0,0,0,[ mini_line(27,13,3,0,0,0,[ str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, "udp")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-2,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,54,13,3,0,-2,0,0,0,0,0, "socket")]) ]) ])]). box('DarkSlateGray','',808,190,821,196,1,1,1,375,0,0,0,0,0,'1',0,[ ]). text('DarkSlateGray',765,197,2,0,1,54,32,377,13,3,0,0,0,0,2,54,32,0,0,"",0,0,0,0,210,'',[ minilines(54,32,0,0,0,0,0,[ mini_line(27,13,3,0,0,0,[ str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, "tcp")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-2,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,54,13,3,0,-2,0,0,0,0,0, "socket")]) ]) ])]). group([ text('black',143,59,2,0,1,72,32,342,13,3,0,0,0,0,2,72,32,0,0,"",0,0,0,0,72,'',[ minilines(72,32,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,72,13,3,0,-2,0,0,0,0,0, "external")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, " data")]) ]) ])]), group([ polygon('DarkSlateGray','',33,[ 245,75,220,79,238,87,214,86,225,97,201,91,202,104,186,95, 177,106,169,95,153,104,154,91,130,97,141,86,117,87,135,79, 110,75,135,70,117,62,141,63,130,52,154,58,153,45,169,54, 177,43,186,54,202,45,201,58,225,52,214,63,238,62,220,70, 245,75],0,1,1,0,353,0,0,0,0,0,'1',0, "000000000",[ ]), box('DarkSlateGray','',117,48,240,102,0,1,0,354,0,0,0,0,0,'1',0,[ attr("", "auto_center_attr", 0, 1, 0, text('DarkSlateGray',177,46,1,1,1,144,16,355,13,3,0,0,0,0,2,144,16,0,0,"",0,0,0,0,59,'',[ minilines(144,16,0,0,1,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('DarkSlateGray',178,67,1,1,1,0,16,356,13,3,0,0,0,0,2,0,16,0,0,"",0,0,0,0,80,'',[ minilines(0,16,0,0,1,0,0,[ mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])])) ]) ], 357,0,0,[ ]) ], 385,0,0,[ ]). text('black',805,84,2,1,1,54,32,399,13,3,0,0,0,0,2,54,32,0,0,"",0,0,0,0,97,'',[ minilines(54,32,0,0,1,0,0,[ mini_line(27,13,3,0,0,0,[ str_block(0,27,13,3,0,0,0,0,0,[ str_seg('black','Courier',0,80640,27,13,3,0,0,0,0,0,0,0, "new")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "member")]) ]) ])]). group([ polygon('DarkSlateGray','',33,[ 874,101,849,105,867,113,843,112,854,123,830,117,831,130,815,121, 806,132,798,121,782,130,783,117,759,123,770,112,746,113,764,105, 739,101,764,96,746,88,770,89,759,78,783,84,782,71,798,80, 806,69,815,80,831,71,830,84,854,78,843,89,867,88,849,96, 874,101],0,1,1,0,398,0,0,0,0,0,'1',0, "000000000",[ ]), box('DarkSlateGray','',746,74,869,128,0,1,0,395,0,0,0,0,0,'1',0,[ attr("", "auto_center_attr", 0, 1, 0, text('DarkSlateGray',806,72,1,1,1,144,16,397,13,3,0,0,0,0,2,144,16,0,0,"",0,0,0,0,85,'',[ minilines(144,16,0,0,1,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('DarkSlateGray',807,93,1,1,1,0,16,396,13,3,0,0,0,0,2,0,16,0,0,"",0,0,0,0,106,'',[ minilines(0,16,0,0,1,0,0,[ mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])])) ]) ], 394,0,0,[ ]). poly('DarkSlateGray','',2,[ 837,125,818,186],1,1,1,400,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('black',291,64,2,0,1,63,32,441,13,3,0,0,0,0,2,63,32,0,0,"",0,0,0,0,77,'',[ minilines(63,32,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,63,13,3,0,-2,0,0,0,0,0, "control")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-2,0,0,0,[ str_seg('black','Courier',0,80640,54,13,3,0,-2,0,0,0,0,0, " pckts")]) ]) ])]). group([ polygon('DarkSlateGray','',33,[ 389,80,364,84,382,92,358,91,369,102,345,96,346,109,330,100, 321,111,313,100,297,109,298,96,274,102,285,91,261,92,279,84, 254,80,279,75,261,67,285,68,274,57,298,63,297,50,313,59, 321,48,330,59,346,50,345,63,369,57,358,68,382,67,364,75, 389,80],0,1,1,0,440,0,0,0,0,0,'1',0, "000000000",[ ]), box('DarkSlateGray','',261,53,384,107,0,1,0,437,0,0,0,0,0,'1',0,[ attr("", "auto_center_attr", 0, 1, 0, text('DarkSlateGray',321,51,1,1,1,144,16,439,13,3,0,0,0,0,2,144,16,0,0,"",0,0,0,0,64,'',[ minilines(144,16,0,0,1,0,0,[ mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "auto_center_attr")]) ]) ])])), attr("label=", "", 1, 0, 0, text('DarkSlateGray',322,72,1,1,1,0,16,438,13,3,0,0,0,0,2,0,16,0,0,"",0,0,0,0,85,'',[ minilines(0,16,0,0,1,0,0,[ mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]) ])])) ]) ], 436,0,0,[ ]). poly('DarkSlateGray','',2,[ 409,188,337,112],1,1,1,466,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). box('DarkSlateGray','',91,190,104,196,1,1,1,473,0,0,0,0,0,'1',0,[ ]). poly('DarkSlateGray','',2,[ 134,102,100,190],2,1,1,476,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]). text('DarkSlateGray',94,199,2,0,1,54,32,484,13,3,0,0,0,0,2,54,32,0,0,"",0,0,0,0,212,'',[ minilines(54,32,0,0,0,0,0,[ mini_line(27,13,3,0,0,0,[ str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, "udp")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-2,0,0,0,[ str_seg('DarkSlateGray','Courier',0,80640,54,13,3,0,-2,0,0,0,0,0, "socket")]) ]) ])]). tgif-QPL-4.2.5/rmcast/configure.in0000644000076400007640000000210611225226450016573 0ustar williamwilliam# -*- Autoconf -*- # Process this file with autoconf to produce a configure script. AC_PREREQ(2.57) AC_INIT(rmcast,2.0.0,support@land.ufrj.br) AC_CONFIG_AUX_DIR(config) AC_CONFIG_SRCDIR([src/rmcache.h]) AM_CONFIG_HEADER([config.h]) AM_INIT_AUTOMAKE # Checks for programs. #AC_PROG_AWK AC_PROG_CC AC_PROG_LIBTOOL # Checks for libraries. AC_CHECK_LIB([m], [pow]) AC_CHECK_LIB([pthread], [pthread_create]) # Checks for header files. AC_HEADER_STDC AC_CHECK_HEADERS([arpa/inet.h netdb.h netinet/in.h]) # Checks for typedefs, structures, and compiler characteristics. AC_C_CONST AC_C_INLINE AC_TYPE_SIZE_T AC_CHECK_DECLS([sys_siglist]) AC_HEADER_TIME AC_STRUCT_TM # Checks for library functions. AC_FUNC_CLOSEDIR_VOID AC_FUNC_FORK AC_FUNC_MALLOC AC_FUNC_REALLOC AC_FUNC_SELECT_ARGTYPES AC_FUNC_SETVBUF_REVERSED AC_TYPE_SIGNAL AC_CHECK_FUNCS([alarm bzero gethostbyname gethostname gettimeofday inet_ntoa memset pow putenv select setlocale socket strchr strdup strerror strstr]) AC_OUTPUT(Makefile src/Makefile mcastproxy/Makefile rmchat/Makefile) tgif-QPL-4.2.5/rmcast/configure0000755000076400007640000272337311566506151016222 0ustar williamwilliam#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.61 for rmcast 2.0.0. # # Report bugs to . # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, # 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi # PATH needs CR # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset else as_unset=false fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) as_nl=' ' IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. case $0 in *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 { (exit 1); exit 1; } fi # Work around bugs in pre-3.0 UWIN ksh. for as_var in ENV MAIL MAILPATH do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. for as_var in \ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ LC_TELEPHONE LC_TIME do if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then eval $as_var=C; export $as_var else ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var fi done # Required to use basename. if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi # Name of the executable. as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # CDPATH. $as_unset CDPATH if test "x$CONFIG_SHELL" = x; then if (eval ":") 2>/dev/null; then as_have_required=yes else as_have_required=no fi if test $as_have_required = yes && (eval ": (as_func_return () { (exit \$1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = \"\$1\" ); then : else exitcode=1 echo positional parameters were not saved. fi test \$exitcode = 0) || { (exit 1); exit 1; } ( as_lineno_1=\$LINENO as_lineno_2=\$LINENO test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" && test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; } ") 2> /dev/null; then : else as_candidate_shells= as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. case $as_dir in /*) for as_base in sh bash ksh sh5; do as_candidate_shells="$as_candidate_shells $as_dir/$as_base" done;; esac done IFS=$as_save_IFS for as_shell in $as_candidate_shells $SHELL; do # Try only shells that exist, to save several forks. if { test -f "$as_shell" || test -f "$as_shell.exe"; } && { ("$as_shell") 2> /dev/null <<\_ASEOF if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi : _ASEOF }; then CONFIG_SHELL=$as_shell as_have_required=yes if { "$as_shell" 2> /dev/null <<\_ASEOF if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi : (as_func_return () { (exit $1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = "$1" ); then : else exitcode=1 echo positional parameters were not saved. fi test $exitcode = 0) || { (exit 1); exit 1; } ( as_lineno_1=$LINENO as_lineno_2=$LINENO test "x$as_lineno_1" != "x$as_lineno_2" && test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; } _ASEOF }; then break fi fi done if test "x$CONFIG_SHELL" != x; then for as_var in BASH_ENV ENV do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var done export CONFIG_SHELL exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} fi if test $as_have_required = no; then echo This script requires a shell more modern than all the echo shells that I found on your system. Please install a echo modern shell, or manually run the script under such a echo shell if you do have one. { (exit 1); exit 1; } fi fi fi (eval "as_func_return () { (exit \$1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = \"\$1\" ); then : else exitcode=1 echo positional parameters were not saved. fi test \$exitcode = 0") || { echo No shell found that supports shell functions. echo Please tell autoconf@gnu.org about your system, echo including any error possibly output before this echo message } as_lineno_1=$LINENO as_lineno_2=$LINENO test "x$as_lineno_1" != "x$as_lineno_2" && test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || { # Create $as_me.lineno as a copy of $as_myself, but with $LINENO # uniformly replaced by the line number. The first 'sed' inserts a # line-number line after each line using $LINENO; the second 'sed' # does the real work. The second script uses 'N' to pair each # line-number line with the line containing $LINENO, and appends # trailing '-' during substitution so that $LINENO is not a special # case at line end. # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the # scripts with optimization help from Paolo Bonzini. Blame Lee # E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 { (exit 1); exit 1; }; } # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in -n*) case `echo 'x\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. *) ECHO_C='\c';; esac;; *) ECHO_N='-n';; esac if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir fi echo >conf$$.file if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p=: else test -d ./-p && rmdir ./-p as_mkdir_p=false fi if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" # Check that we are running under the correct shell. SHELL=${CONFIG_SHELL-/bin/sh} case X$ECHO in X*--fallback-echo) # Remove one level of quotation (which was required for Make). ECHO=`echo "$ECHO" | sed 's,\\\\\$\\$0,'$0','` ;; esac echo=${ECHO-echo} if test "X$1" = X--no-reexec; then # Discard the --no-reexec flag, and continue. shift elif test "X$1" = X--fallback-echo; then # Avoid inline document here, it may be left over : elif test "X`($echo '\t') 2>/dev/null`" = 'X\t' ; then # Yippee, $echo works! : else # Restart under the correct shell. exec $SHELL "$0" --no-reexec ${1+"$@"} fi if test "X$1" = X--fallback-echo; then # used as fallback echo shift cat </dev/null 2>&1 && unset CDPATH if test -z "$ECHO"; then if test "X${echo_test_string+set}" != Xset; then # find a string as large as possible, as long as the shell can cope with it for cmd in 'sed 50q "$0"' 'sed 20q "$0"' 'sed 10q "$0"' 'sed 2q "$0"' 'echo test'; do # expected sizes: less than 2Kb, 1Kb, 512 bytes, 16 bytes, ... if (echo_test_string=`eval $cmd`) 2>/dev/null && echo_test_string=`eval $cmd` && (test "X$echo_test_string" = "X$echo_test_string") 2>/dev/null then break fi done fi if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then : else # The Solaris, AIX, and Digital Unix default echo programs unquote # backslashes. This makes it impossible to quote backslashes using # echo "$something" | sed 's/\\/\\\\/g' # # So, first we look for a working echo in the user's PATH. lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for dir in $PATH /usr/ucb; do IFS="$lt_save_ifs" if (test -f $dir/echo || test -f $dir/echo$ac_exeext) && test "X`($dir/echo '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`($dir/echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then echo="$dir/echo" break fi done IFS="$lt_save_ifs" if test "X$echo" = Xecho; then # We didn't find a better echo, so look for alternatives. if test "X`(print -r '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`(print -r "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then # This shell has a builtin print -r that does the trick. echo='print -r' elif (test -f /bin/ksh || test -f /bin/ksh$ac_exeext) && test "X$CONFIG_SHELL" != X/bin/ksh; then # If we have ksh, try running configure again with it. ORIGINAL_CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} export ORIGINAL_CONFIG_SHELL CONFIG_SHELL=/bin/ksh export CONFIG_SHELL exec $CONFIG_SHELL "$0" --no-reexec ${1+"$@"} else # Try using printf. echo='printf %s\n' if test "X`($echo '\t') 2>/dev/null`" = 'X\t' && echo_testing_string=`($echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then # Cool, printf works : elif echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && test "X$echo_testing_string" = 'X\t' && echo_testing_string=`($ORIGINAL_CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then CONFIG_SHELL=$ORIGINAL_CONFIG_SHELL export CONFIG_SHELL SHELL="$CONFIG_SHELL" export SHELL echo="$CONFIG_SHELL $0 --fallback-echo" elif echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo '\t') 2>/dev/null` && test "X$echo_testing_string" = 'X\t' && echo_testing_string=`($CONFIG_SHELL "$0" --fallback-echo "$echo_test_string") 2>/dev/null` && test "X$echo_testing_string" = "X$echo_test_string"; then echo="$CONFIG_SHELL $0 --fallback-echo" else # maybe with a smaller string... prev=: for cmd in 'echo test' 'sed 2q "$0"' 'sed 10q "$0"' 'sed 20q "$0"' 'sed 50q "$0"'; do if (test "X$echo_test_string" = "X`eval $cmd`") 2>/dev/null then break fi prev="$cmd" done if test "$prev" != 'sed 50q "$0"'; then echo_test_string=`eval $prev` export echo_test_string exec ${ORIGINAL_CONFIG_SHELL-${CONFIG_SHELL-/bin/sh}} "$0" ${1+"$@"} else # Oops. We lost completely, so just stick with echo. echo=echo fi fi fi fi fi fi # Copy echo and quote the copy suitably for passing to libtool from # the Makefile, instead of quoting the original, which is used later. ECHO=$echo if test "X$ECHO" = "X$CONFIG_SHELL $0 --fallback-echo"; then ECHO="$CONFIG_SHELL \\\$\$0 --fallback-echo" fi tagnames=${tagnames+${tagnames},}CXX tagnames=${tagnames+${tagnames},}F77 exec 7<&0 &1 # Name of the host. # hostname on some systems (SVR3.2, Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` # # Initializations. # ac_default_prefix=/usr/local ac_clean_files= ac_config_libobj_dir=. LIBOBJS= cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME='rmcast' PACKAGE_TARNAME='rmcast' PACKAGE_VERSION='2.0.0' PACKAGE_STRING='rmcast 2.0.0' PACKAGE_BUGREPORT='support@land.ufrj.br' ac_unique_file="src/rmcache.h" # Factoring default headers for most tests. ac_includes_default="\ #include #ifdef HAVE_SYS_TYPES_H # include #endif #ifdef HAVE_SYS_STAT_H # include #endif #ifdef STDC_HEADERS # include # include #else # ifdef HAVE_STDLIB_H # include # endif #endif #ifdef HAVE_STRING_H # if !defined STDC_HEADERS && defined HAVE_MEMORY_H # include # endif # include #endif #ifdef HAVE_STRINGS_H # include #endif #ifdef HAVE_INTTYPES_H # include #endif #ifdef HAVE_STDINT_H # include #endif #ifdef HAVE_UNISTD_H # include #endif" ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir localstatedir includedir oldincludedir docdir infodir htmldir dvidir pdfdir psdir libdir localedir mandir DEFS ECHO_C ECHO_N ECHO_T LIBS build_alias host_alias target_alias INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE build build_cpu build_vendor build_os host host_cpu host_vendor host_os SED GREP EGREP LN_S ECHO AR RANLIB DSYMUTIL NMEDIT CPP CXX CXXFLAGS ac_ct_CXX CXXDEPMODE am__fastdepCXX_TRUE am__fastdepCXX_FALSE CXXCPP F77 FFLAGS ac_ct_F77 LIBTOOL LIBOBJS LTLIBOBJS' ac_subst_files='' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS CPP CXX CXXFLAGS CCC CXXCPP F77 FFLAGS' # Initialize some variables set by options. ac_init_help= ac_init_version=false # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. # (The list follows the same order as the GNU Coding Standards.) bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datarootdir='${prefix}/share' datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' pdfdir='${docdir}' psdir='${docdir}' libdir='${exec_prefix}/lib' localedir='${datarootdir}/locale' mandir='${datarootdir}/man' ac_prev= ac_dashdash= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval $ac_prev=\$ac_option ac_prev= continue fi case $ac_option in *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=*) datadir=$ac_optarg ;; -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | --dataroo | --dataro | --datar) ac_prev=datarootdir ;; -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) datarootdir=$ac_optarg ;; -disable-* | --disable-*) ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid feature name: $ac_feature" >&2 { (exit 1); exit 1; }; } ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'` eval enable_$ac_feature=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) docdir=$ac_optarg ;; -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) ac_prev=dvidir ;; -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) dvidir=$ac_optarg ;; -enable-* | --enable-*) ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid feature name: $ac_feature" >&2 { (exit 1); exit 1; }; } ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'` eval enable_$ac_feature=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) ac_prev=htmldir ;; -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | --ht=*) htmldir=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localedir | --localedir | --localedi | --localed | --locale) ac_prev=localedir ;; -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) localedir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst | --locals) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) ac_prev=pdfdir ;; -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) pdfdir=$ac_optarg ;; -psdir | --psdir | --psdi | --psd | --ps) ac_prev=psdir ;; -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) psdir=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid package name: $ac_package" >&2 { (exit 1); exit 1; }; } ac_package=`echo $ac_package | sed 's/[-.]/_/g'` eval with_$ac_package=\$ac_optarg ;; -without-* | --without-*) ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid package name: $ac_package" >&2 { (exit 1); exit 1; }; } ac_package=`echo $ac_package | sed 's/[-.]/_/g'` eval with_$ac_package=no ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) { echo "$as_me: error: unrecognized option: $ac_option Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; } ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid variable name: $ac_envvar" >&2 { (exit 1); exit 1; }; } eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` { echo "$as_me: error: missing argument to $ac_option" >&2 { (exit 1); exit 1; }; } fi # Be sure to have absolute directory names. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 { (exit 1); exit 1; }; } done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. If a cross compiler is detected then cross compile mode will be used." >&2 elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || { echo "$as_me: error: Working directory cannot be determined" >&2 { (exit 1); exit 1; }; } test "X$ac_ls_di" = "X$ac_pwd_ls_di" || { echo "$as_me: error: pwd does not report name of working directory" >&2 { (exit 1); exit 1; }; } # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. ac_confdir=`$as_dirname -- "$0" || $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$0" : 'X\(//\)[^/]' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || echo X"$0" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` srcdir=$ac_confdir if test ! -r "$srcdir/$ac_unique_file"; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2 { (exit 1); exit 1; }; } fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2 { (exit 1); exit 1; }; } pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then srcdir=. fi # Remove unnecessary trailing slashes from srcdir. # Double slashes in file names in object file debugging info # mess up M-x gdb in Emacs. case $srcdir in */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; esac for ac_var in $ac_precious_vars; do eval ac_env_${ac_var}_set=\${${ac_var}+set} eval ac_env_${ac_var}_value=\$${ac_var} eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} eval ac_cv_env_${ac_var}_value=\$${ac_var} done # # Report the --help message. # if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF \`configure' configures rmcast 2.0.0 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] --docdir=DIR documentation root [DATAROOTDIR/doc/rmcast] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF Program names: --program-prefix=PREFIX prepend PREFIX to installed program names --program-suffix=SUFFIX append SUFFIX to installed program names --program-transform-name=PROGRAM run sed PROGRAM on installed program names System types: --build=BUILD configure for building on BUILD [guessed] --host=HOST cross-compile to build programs to run on HOST [BUILD] _ACEOF fi if test -n "$ac_init_help"; then case $ac_init_help in short | recursive ) echo "Configuration of rmcast 2.0.0:";; esac cat <<\_ACEOF Optional Features: --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors --enable-shared[=PKGS] build shared libraries [default=yes] --enable-static[=PKGS] build static libraries [default=yes] --enable-fast-install[=PKGS] optimize for fast installation [default=yes] --disable-libtool-lock avoid locking (might break parallel builds) Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-gnu-ld assume the C compiler uses GNU ld [default=no] --with-pic try to use only PIC/non-PIC objects [default=use both] --with-tags[=TAGS] include additional configurations [automatic] Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L if you have libraries in a nonstandard directory LIBS libraries to pass to the linker, e.g. -l CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I if you have headers in a nonstandard directory CPP C preprocessor CXX C++ compiler command CXXFLAGS C++ compiler flags CXXCPP C++ preprocessor F77 Fortran 77 compiler command FFLAGS Fortran 77 compiler flags Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to . _ACEOF ac_status=$? fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d "$ac_dir" || continue ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" || { ac_status=$?; continue; } # Check for guested configure. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive elif test -f "$ac_srcdir/configure"; then echo && $SHELL "$ac_srcdir/configure" --help=recursive else echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF rmcast configure 2.0.0 generated by GNU Autoconf 2.61 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF exit fi cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by rmcast $as_me 2.0.0, which was generated by GNU Autoconf 2.61. Invocation command line was $ $0 $@ _ACEOF exec 5>>config.log { cat <<_ASUNAME ## --------- ## ## Platform. ## ## --------- ## hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. echo "PATH: $as_dir" done IFS=$as_save_IFS } >&5 cat >&5 <<_ACEOF ## ----------- ## ## Core tests. ## ## ----------- ## _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;; 2) ac_configure_args1="$ac_configure_args1 '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi ac_configure_args="$ac_configure_args '$ac_arg'" ;; esac done done $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; } $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; } # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? # Save into config.log some information that might help in debugging. { echo cat <<\_ASBOX ## ---------------- ## ## Cache variables. ## ## ---------------- ## _ASBOX echo # The following way of writing the cache mishandles newlines in values, ( for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( *) $as_unset $ac_var ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( *${as_nl}ac_space=\ *) sed -n \ "s/'\''/'\''\\\\'\'''\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" ;; #( *) sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) echo cat <<\_ASBOX ## ----------------- ## ## Output variables. ## ## ----------------- ## _ASBOX echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac echo "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then cat <<\_ASBOX ## ------------------- ## ## File substitutions. ## ## ------------------- ## _ASBOX echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac echo "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then cat <<\_ASBOX ## ----------- ## ## confdefs.h. ## ## ----------- ## _ASBOX echo cat confdefs.h echo fi test "$ac_signal" != 0 && echo "$as_me: caught signal $ac_signal" echo "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF #define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer explicitly selected file to automatically selected ones. if test -n "$CONFIG_SITE"; then set x "$CONFIG_SITE" elif test "x$prefix" != xNONE; then set x "$prefix/share/config.site" "$prefix/etc/config.site" else set x "$ac_default_prefix/share/config.site" \ "$ac_default_prefix/etc/config.site" fi shift for ac_site_file do if test -r "$ac_site_file"; then { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5 echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special # files actually), so we avoid doing that. if test -f "$cache_file"; then { echo "$as_me:$LINENO: loading cache $cache_file" >&5 echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { echo "$as_me:$LINENO: creating cache $cache_file" >&5 echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in $ac_precious_vars; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val=\$ac_cv_env_${ac_var}_value eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} { echo "$as_me:$LINENO: former value: $ac_old_val" >&5 echo "$as_me: former value: $ac_old_val" >&2;} { echo "$as_me:$LINENO: current value: $ac_new_val" >&5 echo "$as_me: current value: $ac_new_val" >&2;} ac_cache_corrupted=: fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) ac_configure_args="$ac_configure_args '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; then { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5 echo "$as_me: error: changes in the environment can compromise the build" >&2;} { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} { (exit 1); exit 1; }; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ac_aux_dir= for ac_dir in config "$srcdir"/config; do if test -f "$ac_dir/install-sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" break elif test -f "$ac_dir/install.sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break elif test -f "$ac_dir/shtool"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/shtool install -c" break fi done if test -z "$ac_aux_dir"; then { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5 echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;} { (exit 1); exit 1; }; } fi # These three variables are undocumented and unsupported, # and are intended to be withdrawn in a future Autoconf release. # They can cause serious problems if a builder's source tree is in a directory # whose full name contains unusual characters. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. ac_config_headers="$ac_config_headers config.h" am__api_version="1.9" # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. { echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; } if test -z "$INSTALL"; then if test "${ac_cv_path_install+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in ./ | .// | /cC/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi done done ;; esac done IFS=$as_save_IFS fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a # value for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. INSTALL=$ac_install_sh fi fi { echo "$as_me:$LINENO: result: $INSTALL" >&5 echo "${ECHO_T}$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { echo "$as_me:$LINENO: checking whether build environment is sane" >&5 echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6; } # Just in case sleep 1 echo timestamp > conftest.file # Do `set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` if test "$*" = "X"; then # -L didn't work. set X `ls -t $srcdir/configure conftest.file` fi rm -f conftest.file if test "$*" != "X $srcdir/configure conftest.file" \ && test "$*" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". { { echo "$as_me:$LINENO: error: ls -t appears to fail. Make sure there is not a broken alias in your environment" >&5 echo "$as_me: error: ls -t appears to fail. Make sure there is not a broken alias in your environment" >&2;} { (exit 1); exit 1; }; } fi test "$2" = conftest.file ) then # Ok. : else { { echo "$as_me:$LINENO: error: newly created file is older than distributed files! Check your system clock" >&5 echo "$as_me: error: newly created file is older than distributed files! Check your system clock" >&2;} { (exit 1); exit 1; }; } fi { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. test "$program_suffix" != NONE && program_transform_name="s&\$&$program_suffix&;$program_transform_name" # Double any \ or $. echo might interpret backslashes. # By default was `s,x,x', remove it if useless. cat <<\_ACEOF >conftest.sed s/[\\$]/&&/g;s/;s,x,x,$// _ACEOF program_transform_name=`echo $program_transform_name | sed -f conftest.sed` rm -f conftest.sed # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= { echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5 echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} fi if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then # We used to keeping the `.' as first argument, in order to # allow $(mkdir_p) to be used without argument. As in # $(mkdir_p) $(somedir) # where $(somedir) is conditionally defined. However this is wrong # for two reasons: # 1. if the package is installed by a user who cannot write `.' # make install will fail, # 2. the above comment should most certainly read # $(mkdir_p) $(DESTDIR)$(somedir) # so it does not work when $(somedir) is undefined and # $(DESTDIR) is not. # To support the latter case, we have to write # test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir), # so the `.' trick is pointless. mkdir_p='mkdir -p --' else # On NextStep and OpenStep, the `mkdir' command does not # recognize any option. It will interpret all options as # directories to create, and then abort because `.' already # exists. for d in ./-p ./--version; do test -d $d && rmdir $d done # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists. if test -f "$ac_aux_dir/mkinstalldirs"; then mkdir_p='$(mkinstalldirs)' else mkdir_p='$(install_sh) -d' fi fi for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_AWK+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_AWK="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then { echo "$as_me:$LINENO: result: $AWK" >&5 echo "${ECHO_T}$AWK" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$AWK" && break done { echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6; } set x ${MAKE-make}; ac_make=`echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF # GNU make sometimes prints "make[1]: Entering...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; *) eval ac_cv_prog_make_${ac_make}_set=no;; esac rm -f conftest.make fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } SET_MAKE= else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null # test to see if srcdir already configured if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5 echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;} { (exit 1); exit 1; }; } fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi # Define the identity of the package. PACKAGE='rmcast' VERSION='2.0.0' cat >>confdefs.h <<_ACEOF #define PACKAGE "$PACKAGE" _ACEOF cat >>confdefs.h <<_ACEOF #define VERSION "$VERSION" _ACEOF # Some tools Automake needs. ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} install_sh=${install_sh-"$am_aux_dir/install-sh"} # Installed binaries are usually stripped using `strip' when the user # run `make install-strip'. However `strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the `STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { echo "$as_me:$LINENO: result: $STRIP" >&5 echo "${ECHO_T}$STRIP" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_STRIP="strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5 echo "${ECHO_T}$ac_ct_STRIP" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi fi INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s" # We need awk for the "check" target. The system "awk" is bad on # some platforms. # Always define AMTAR for backward compatibility. AMTAR=${AMTAR-"${am_missing_run}tar"} am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' # Checks for programs. #AC_PROG_AWK ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}gcc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="gcc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}cc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $# != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH See \`config.log' for more details." >&5 echo "$as_me: error: no acceptable C compiler found in \$PATH See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } # Provide some information about the compiler. echo "$as_me:$LINENO: checking for C compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (ac_try="$ac_compiler --version >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler --version >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -v >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -v >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -V >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -V >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. { echo "$as_me:$LINENO: checking for C compiler default output file name" >&5 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; } ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # # List of possible output files, starting from the most likely. # The algorithm is not robust to junk in `.', hence go to wildcards (a.*) # only as a last resort. b.out is created by i960 compilers. ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out' # # The IRIX 6 linker writes into existing files which may not be # executable, retaining their permissions. Remove them first so a # subsequent execution test works. ac_rmfiles= for ac_file in $ac_files do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done rm -f $ac_rmfiles if { (ac_try="$ac_link_default" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link_default") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. for ac_file in $ac_files '' do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not # safe: cross compilers may not add the suffix if given an `-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. break;; * ) break;; esac done test "$ac_cv_exeext" = no && ac_cv_exeext= else ac_file='' fi { echo "$as_me:$LINENO: result: $ac_file" >&5 echo "${ECHO_T}$ac_file" >&6; } if test -z "$ac_file"; then echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { echo "$as_me:$LINENO: error: C compiler cannot create executables See \`config.log' for more details." >&5 echo "$as_me: error: C compiler cannot create executables See \`config.log' for more details." >&2;} { (exit 77); exit 77; }; } fi ac_exeext=$ac_cv_exeext # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { echo "$as_me:$LINENO: checking whether the C compiler works" >&5 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; } # FIXME: These cross compiler hacks should be removed for Autoconf 3.0 # If not cross compiling, check that we can run a simple program. if test "$cross_compiling" != yes; then if { ac_try='./$ac_file' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else { { echo "$as_me:$LINENO: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&5 echo "$as_me: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi fi fi { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } rm -f a.out a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { echo "$as_me:$LINENO: checking whether we are cross compiling" >&5 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; } { echo "$as_me:$LINENO: result: $cross_compiling" >&5 echo "${ECHO_T}$cross_compiling" >&6; } { echo "$as_me:$LINENO: checking for suffix of executables" >&5 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; } if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done else { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&5 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi rm -f conftest$ac_cv_exeext { echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5 echo "${ECHO_T}$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT { echo "$as_me:$LINENO: checking for suffix of object files" >&5 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; } if test "${ac_cv_objext+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.o conftest.obj if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile See \`config.log' for more details." >&5 echo "$as_me: error: cannot compute suffix of object files: cannot compile See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_objext" >&5 echo "${ECHO_T}$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; } if test "${ac_cv_c_compiler_gnu+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_compiler_gnu=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; } GCC=`test $ac_compiler_gnu = yes && echo yes` ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; } if test "${ac_cv_prog_cc_g+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cc_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 CFLAGS="" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cc_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; } if test "$ac_test_CFLAGS" = set; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi { echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5 echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; } if test "${ac_cv_prog_cc_c89+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_prog_cc_c89=no ac_save_CC=$CC cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #include #include /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); static char *e (p, i) char **p; int i; { return p[i]; } static char *f (char * (*g) (char **, int), char **p, ...) { char *s; va_list v; va_start (v,p); s = g (p, va_arg (v,int)); va_end (v); return s; } /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has function prototypes and stuff, but not '\xHH' hex character constants. These don't provoke an error unfortunately, instead are silently treated as 'x'. The following induces an error, until -std is added to get proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an array size at least. It's necessary to write '\x00'==0 to get something that's true only with -std. */ int osf4_cc_array ['\x00' == 0 ? 1 : -1]; /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters inside strings and character constants. */ #define FOO(x) 'x' int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);}; int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); int argc; char **argv; int main () { return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cc_c89=$ac_arg else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) { echo "$as_me:$LINENO: result: none needed" >&5 echo "${ECHO_T}none needed" >&6; } ;; xno) { echo "$as_me:$LINENO: result: unsupported" >&5 echo "${ECHO_T}unsupported" >&6; } ;; *) CC="$CC $ac_cv_prog_cc_c89" { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5 echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;; esac ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo done .PHONY: am__doit END # If we don't find an include directive, just comment out the code. { echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5 echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6; } am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # We grep out `Entering directory' and `Leaving directory' # messages which can occur if `w' ends up in MAKEFLAGS. # In particular we don't look at `^make:' because GNU make might # be invoked under some other name (usually "gmake"), in which # case it prints its new name instead of `make'. if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then am__include=include am__quote= _am_result=GNU fi # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then am__include=.include am__quote="\"" _am_result=BSD fi fi { echo "$as_me:$LINENO: result: $_am_result" >&5 echo "${ECHO_T}$_am_result" >&6; } rm -f confinc confmf # Check whether --enable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then enableval=$enable_dependency_tracking; fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= AMDEP_FALSE='#' else AMDEP_TRUE='#' AMDEP_FALSE= fi depcc="$CC" am_compiler_list= { echo "$as_me:$LINENO: checking dependency style of $depcc" >&5 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6; } if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CC_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CC_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi { echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then am__fastdepCC_TRUE= am__fastdepCC_FALSE='#' else am__fastdepCC_TRUE='#' am__fastdepCC_FALSE= fi # Check whether --enable-shared was given. if test "${enable_shared+set}" = set; then enableval=$enable_shared; p=${PACKAGE-default} case $enableval in yes) enable_shared=yes ;; no) enable_shared=no ;; *) enable_shared=no # Look at the argument we got. We use all the common list separators. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then enable_shared=yes fi done IFS="$lt_save_ifs" ;; esac else enable_shared=yes fi # Check whether --enable-static was given. if test "${enable_static+set}" = set; then enableval=$enable_static; p=${PACKAGE-default} case $enableval in yes) enable_static=yes ;; no) enable_static=no ;; *) enable_static=no # Look at the argument we got. We use all the common list separators. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then enable_static=yes fi done IFS="$lt_save_ifs" ;; esac else enable_static=yes fi # Check whether --enable-fast-install was given. if test "${enable_fast_install+set}" = set; then enableval=$enable_fast_install; p=${PACKAGE-default} case $enableval in yes) enable_fast_install=yes ;; no) enable_fast_install=no ;; *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for pkg in $enableval; do IFS="$lt_save_ifs" if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done IFS="$lt_save_ifs" ;; esac else enable_fast_install=yes fi # Make sure we can run config.sub. $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5 echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;} { (exit 1); exit 1; }; } { echo "$as_me:$LINENO: checking build system type" >&5 echo $ECHO_N "checking build system type... $ECHO_C" >&6; } if test "${ac_cv_build+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_build_alias=$build_alias test "x$ac_build_alias" = x && ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` test "x$ac_build_alias" = x && { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5 echo "$as_me: error: cannot guess build type; you must specify one" >&2;} { (exit 1); exit 1; }; } ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5 echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;} { (exit 1); exit 1; }; } fi { echo "$as_me:$LINENO: result: $ac_cv_build" >&5 echo "${ECHO_T}$ac_cv_build" >&6; } case $ac_cv_build in *-*-*) ;; *) { { echo "$as_me:$LINENO: error: invalid value of canonical build" >&5 echo "$as_me: error: invalid value of canonical build" >&2;} { (exit 1); exit 1; }; };; esac build=$ac_cv_build ac_save_IFS=$IFS; IFS='-' set x $ac_cv_build shift build_cpu=$1 build_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: build_os=$* IFS=$ac_save_IFS case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac { echo "$as_me:$LINENO: checking host system type" >&5 echo $ECHO_N "checking host system type... $ECHO_C" >&6; } if test "${ac_cv_host+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "x$host_alias" = x; then ac_cv_host=$ac_cv_build else ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5 echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;} { (exit 1); exit 1; }; } fi fi { echo "$as_me:$LINENO: result: $ac_cv_host" >&5 echo "${ECHO_T}$ac_cv_host" >&6; } case $ac_cv_host in *-*-*) ;; *) { { echo "$as_me:$LINENO: error: invalid value of canonical host" >&5 echo "$as_me: error: invalid value of canonical host" >&2;} { (exit 1); exit 1; }; };; esac host=$ac_cv_host ac_save_IFS=$IFS; IFS='-' set x $ac_cv_host shift host_cpu=$1 host_vendor=$2 shift; shift # Remember, the first character of IFS is used to create $*, # except with old shells: host_os=$* IFS=$ac_save_IFS case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac { echo "$as_me:$LINENO: checking for a sed that does not truncate output" >&5 echo $ECHO_N "checking for a sed that does not truncate output... $ECHO_C" >&6; } if test "${lt_cv_path_SED+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Loop through the user's path and test for sed and gsed. # Then use that list of sed's as ones to test for truncation. as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for lt_ac_prog in sed gsed; do for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$lt_ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$lt_ac_prog$ac_exec_ext"; }; then lt_ac_sed_list="$lt_ac_sed_list $as_dir/$lt_ac_prog$ac_exec_ext" fi done done done IFS=$as_save_IFS lt_ac_max=0 lt_ac_count=0 # Add /usr/xpg4/bin/sed as it is typically found on Solaris # along with /bin/sed that truncates output. for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do test ! -f $lt_ac_sed && continue cat /dev/null > conftest.in lt_ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >conftest.in # Check for GNU sed and select it if it is found. if "$lt_ac_sed" --version 2>&1 < /dev/null | grep 'GNU' > /dev/null; then lt_cv_path_SED=$lt_ac_sed break fi while true; do cat conftest.in conftest.in >conftest.tmp mv conftest.tmp conftest.in cp conftest.in conftest.nl echo >>conftest.nl $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break cmp -s conftest.out conftest.nl || break # 10000 chars as input seems more than enough test $lt_ac_count -gt 10 && break lt_ac_count=`expr $lt_ac_count + 1` if test $lt_ac_count -gt $lt_ac_max; then lt_ac_max=$lt_ac_count lt_cv_path_SED=$lt_ac_sed fi done done fi SED=$lt_cv_path_SED { echo "$as_me:$LINENO: result: $SED" >&5 echo "${ECHO_T}$SED" >&6; } { echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5 echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; } if test "${ac_cv_path_GREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Extract the first word of "grep ggrep" to use in msg output if test -z "$GREP"; then set dummy grep ggrep; ac_prog_name=$2 if test "${ac_cv_path_GREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_path_GREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in *GNU*) ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; *) ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" echo 'GREP' >> "conftest.nl" "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break ac_count=`expr $ac_count + 1` if test $ac_count -gt ${ac_path_GREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_GREP_found && break 3 done done done IFS=$as_save_IFS fi GREP="$ac_cv_path_GREP" if test -z "$GREP"; then { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} { (exit 1); exit 1; }; } fi else ac_cv_path_GREP=$GREP fi fi { echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5 echo "${ECHO_T}$ac_cv_path_GREP" >&6; } GREP="$ac_cv_path_GREP" { echo "$as_me:$LINENO: checking for egrep" >&5 echo $ECHO_N "checking for egrep... $ECHO_C" >&6; } if test "${ac_cv_path_EGREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 then ac_cv_path_EGREP="$GREP -E" else # Extract the first word of "egrep" to use in msg output if test -z "$EGREP"; then set dummy egrep; ac_prog_name=$2 if test "${ac_cv_path_EGREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_path_EGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in *GNU*) ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; *) ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" echo 'EGREP' >> "conftest.nl" "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break ac_count=`expr $ac_count + 1` if test $ac_count -gt ${ac_path_EGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_EGREP_found && break 3 done done done IFS=$as_save_IFS fi EGREP="$ac_cv_path_EGREP" if test -z "$EGREP"; then { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} { (exit 1); exit 1; }; } fi else ac_cv_path_EGREP=$EGREP fi fi fi { echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5 echo "${ECHO_T}$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" # Check whether --with-gnu-ld was given. if test "${with_gnu_ld+set}" = set; then withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes else with_gnu_ld=no fi ac_prog=ld if test "$GCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. { echo "$as_me:$LINENO: checking for ld used by $CC" >&5 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6; } case $host in *-*-mingw*) # gcc leaves a trailing carriage return which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [\\/]* | ?:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the pathname of ld ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD="$ac_prog" ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test "$with_gnu_ld" = yes; then { echo "$as_me:$LINENO: checking for GNU ld" >&5 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6; } else { echo "$as_me:$LINENO: checking for non-GNU ld" >&5 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6; } fi if test "${lt_cv_path_LD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -z "$LD"; then lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD="$ac_dir/$ac_prog" # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &5 echo "${ECHO_T}$LD" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;} { (exit 1); exit 1; }; } { echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6; } if test "${lt_cv_prog_gnu_ld+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 &5 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld { echo "$as_me:$LINENO: checking for $LD option to reload object files" >&5 echo $ECHO_N "checking for $LD option to reload object files... $ECHO_C" >&6; } if test "${lt_cv_ld_reload_flag+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_ld_reload_flag='-r' fi { echo "$as_me:$LINENO: result: $lt_cv_ld_reload_flag" >&5 echo "${ECHO_T}$lt_cv_ld_reload_flag" >&6; } reload_flag=$lt_cv_ld_reload_flag case $reload_flag in "" | " "*) ;; *) reload_flag=" $reload_flag" ;; esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in darwin*) if test "$GCC" = yes; then reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' else reload_cmds='$LD$reload_flag -o $output$reload_objs' fi ;; esac { echo "$as_me:$LINENO: checking for BSD-compatible nm" >&5 echo $ECHO_N "checking for BSD-compatible nm... $ECHO_C" >&6; } if test "${lt_cv_path_NM+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$NM"; then # Let the user override the test. lt_cv_path_NM="$NM" else lt_nm_to_check="${ac_tool_prefix}nm" if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. tmp_nm="$ac_dir/$lt_tmp_nm" if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then # Check to see if the nm accepts a BSD-compat flag. # Adding the `sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in */dev/null* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" break ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" break ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but continue # so that we can try to find one that supports BSD flags ;; esac ;; esac fi done IFS="$lt_save_ifs" done test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm fi fi { echo "$as_me:$LINENO: result: $lt_cv_path_NM" >&5 echo "${ECHO_T}$lt_cv_path_NM" >&6; } NM="$lt_cv_path_NM" { echo "$as_me:$LINENO: checking whether ln -s works" >&5 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6; } LN_S=$as_ln_s if test "$LN_S" = "ln -s"; then { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } else { echo "$as_me:$LINENO: result: no, using $LN_S" >&5 echo "${ECHO_T}no, using $LN_S" >&6; } fi { echo "$as_me:$LINENO: checking how to recognize dependent libraries" >&5 echo $ECHO_N "checking how to recognize dependent libraries... $ECHO_C" >&6; } if test "${lt_cv_deplibs_check_method+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_file_magic_cmd='$MAGIC_CMD' lt_cv_file_magic_test_file= lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. # `unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path # which responds to the $file_magic_cmd with a given extended regex. # If you have `file' or equivalent on your system and you're not sure # whether `pass_all' will *always* work, you probably want this one. case $host_os in aix[4-9]*) lt_cv_deplibs_check_method=pass_all ;; beos*) lt_cv_deplibs_check_method=pass_all ;; bsdi[45]*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' lt_cv_file_magic_cmd='/usr/bin/file -L' lt_cv_file_magic_test_file=/shlib/libc.so ;; cygwin*) # func_win32_libid is a shell function defined in ltmain.sh lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' ;; mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' lt_cv_file_magic_cmd='$OBJDUMP -f' fi ;; darwin* | rhapsody*) lt_cv_deplibs_check_method=pass_all ;; freebsd* | dragonfly*) if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then case $host_cpu in i*86 ) # Not sure whether the presence of OpenBSD here was a mistake. # Let's accept both of them until this is cleared up. lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` ;; esac else lt_cv_deplibs_check_method=pass_all fi ;; gnu*) lt_cv_deplibs_check_method=pass_all ;; hpux10.20* | hpux11*) lt_cv_file_magic_cmd=/usr/bin/file case $host_cpu in ia64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so ;; hppa*64*) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - PA-RISC [0-9].[0-9]' lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl ;; *) lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9].[0-9]) shared library' lt_cv_file_magic_test_file=/usr/lib/libc.sl ;; esac ;; interix[3-9]*) # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' ;; irix5* | irix6* | nonstopux*) case $LD in *-32|*"-32 ") libmagic=32-bit;; *-n32|*"-n32 ") libmagic=N32;; *-64|*"-64 ") libmagic=64-bit;; *) libmagic=never-match;; esac lt_cv_deplibs_check_method=pass_all ;; # This must be Linux ELF. linux* | k*bsd*-gnu) lt_cv_deplibs_check_method=pass_all ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' fi ;; newos6*) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' lt_cv_file_magic_cmd=/usr/bin/file lt_cv_file_magic_test_file=/usr/lib/libnls.so ;; nto-qnx*) lt_cv_deplibs_check_method=unknown ;; openbsd*) if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' fi ;; osf3* | osf4* | osf5*) lt_cv_deplibs_check_method=pass_all ;; rdos*) lt_cv_deplibs_check_method=pass_all ;; solaris*) lt_cv_deplibs_check_method=pass_all ;; sysv4 | sysv4.3*) case $host_vendor in motorola) lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` ;; ncr) lt_cv_deplibs_check_method=pass_all ;; sequent) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' ;; sni) lt_cv_file_magic_cmd='/bin/file' lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" lt_cv_file_magic_test_file=/lib/libc.so ;; siemens) lt_cv_deplibs_check_method=pass_all ;; pc) lt_cv_deplibs_check_method=pass_all ;; esac ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) lt_cv_deplibs_check_method=pass_all ;; esac fi { echo "$as_me:$LINENO: result: $lt_cv_deplibs_check_method" >&5 echo "${ECHO_T}$lt_cv_deplibs_check_method" >&6; } file_magic_cmd=$lt_cv_file_magic_cmd deplibs_check_method=$lt_cv_deplibs_check_method test -z "$deplibs_check_method" && deplibs_check_method=unknown # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # Check whether --enable-libtool-lock was given. if test "${enable_libtool_lock+set}" = set; then enableval=$enable_libtool_lock; fi test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then case `/usr/bin/file conftest.$ac_objext` in *ELF-32*) HPUX_IA64_MODE="32" ;; *ELF-64*) HPUX_IA64_MODE="64" ;; esac fi rm -rf conftest* ;; *-*-irix6*) # Find out which ABI we are using. echo '#line 4304 "configure"' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then if test "$lt_cv_prog_gnu_ld" = yes; then case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" ;; *N32*) LD="${LD-ld} -melf32bmipn32" ;; *64-bit*) LD="${LD-ld} -melf64bmip" ;; esac else case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -32" ;; *N32*) LD="${LD-ld} -n32" ;; *64-bit*) LD="${LD-ld} -64" ;; esac fi fi rm -rf conftest* ;; x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ s390*-*linux*|sparc*-*linux*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then case `/usr/bin/file conftest.o` in *32-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_i386" ;; ppc64-*linux*|powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) LD="${LD-ld} -m elf_s390" ;; sparc64-*linux*) LD="${LD-ld} -m elf32_sparc" ;; esac ;; *64-bit*) case $host in x86_64-*kfreebsd*-gnu) LD="${LD-ld} -m elf_x86_64_fbsd" ;; x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; ppc*-*linux*|powerpc*-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*) LD="${LD-ld} -m elf64_s390" ;; sparc*-*linux*) LD="${LD-ld} -m elf64_sparc" ;; esac ;; esac fi rm -rf conftest* ;; *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. SAVE_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS -belf" { echo "$as_me:$LINENO: checking whether the C compiler needs -belf" >&5 echo $ECHO_N "checking whether the C compiler needs -belf... $ECHO_C" >&6; } if test "${lt_cv_cc_needs_belf+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_cv_cc_needs_belf=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 lt_cv_cc_needs_belf=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu fi { echo "$as_me:$LINENO: result: $lt_cv_cc_needs_belf" >&5 echo "${ECHO_T}$lt_cv_cc_needs_belf" >&6; } if test x"$lt_cv_cc_needs_belf" != x"yes"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf CFLAGS="$SAVE_CFLAGS" fi ;; sparc*-*solaris*) # Find out which ABI we are using. echo 'int i;' > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then case `/usr/bin/file conftest.o` in *64-bit*) case $lt_cv_prog_gnu_ld in yes*) LD="${LD-ld} -m elf64_sparc" ;; *) if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then LD="${LD-ld} -64" fi ;; esac ;; esac fi rm -rf conftest* ;; esac need_locks="$enable_libtool_lock" ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; } # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then if test "${ac_cv_prog_CPP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Double quotes because CPP needs to be expanded for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" do ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then break fi done ac_cv_prog_CPP=$CPP fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi { echo "$as_me:$LINENO: result: $CPP" >&5 echo "${ECHO_T}$CPP" >&6; } ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details." >&5 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { echo "$as_me:$LINENO: checking for ANSI C header files" >&5 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; } if test "${ac_cv_header_stdc+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_header_stdc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi fi { echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 echo "${ECHO_T}$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then cat >>confdefs.h <<\_ACEOF #define STDC_HEADERS 1 _ACEOF fi # On IRIX 5.3, sys/types and inttypes.h are conflicting. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ inttypes.h stdint.h unistd.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then eval "$as_ac_Header=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_Header=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_header in dlfcn.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## ----------------------------------- ## ## Report this to support@land.ufrj.br ## ## ----------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu if test -z "$CXX"; then if test -n "$CCC"; then CXX=$CCC else if test -n "$ac_tool_prefix"; then for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CXX"; then ac_cv_prog_CXX="$CXX" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CXX=$ac_cv_prog_CXX if test -n "$CXX"; then { echo "$as_me:$LINENO: result: $CXX" >&5 echo "${ECHO_T}$CXX" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$CXX" && break done fi if test -z "$CXX"; then ac_ct_CXX=$CXX for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_CXX"; then ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CXX="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CXX=$ac_cv_prog_ac_ct_CXX if test -n "$ac_ct_CXX"; then { echo "$as_me:$LINENO: result: $ac_ct_CXX" >&5 echo "${ECHO_T}$ac_ct_CXX" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$ac_ct_CXX" && break done if test "x$ac_ct_CXX" = x; then CXX="g++" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac CXX=$ac_ct_CXX fi fi fi fi # Provide some information about the compiler. echo "$as_me:$LINENO: checking for C++ compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (ac_try="$ac_compiler --version >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler --version >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -v >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -v >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -V >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -V >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { echo "$as_me:$LINENO: checking whether we are using the GNU C++ compiler" >&5 echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6; } if test "${ac_cv_cxx_compiler_gnu+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_compiler_gnu=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_cxx_compiler_gnu=$ac_compiler_gnu fi { echo "$as_me:$LINENO: result: $ac_cv_cxx_compiler_gnu" >&5 echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6; } GXX=`test $ac_compiler_gnu = yes && echo yes` ac_test_CXXFLAGS=${CXXFLAGS+set} ac_save_CXXFLAGS=$CXXFLAGS { echo "$as_me:$LINENO: checking whether $CXX accepts -g" >&5 echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6; } if test "${ac_cv_prog_cxx_g+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_save_cxx_werror_flag=$ac_cxx_werror_flag ac_cxx_werror_flag=yes ac_cv_prog_cxx_g=no CXXFLAGS="-g" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cxx_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 CXXFLAGS="" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cxx_werror_flag=$ac_save_cxx_werror_flag CXXFLAGS="-g" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cxx_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cxx_werror_flag=$ac_save_cxx_werror_flag fi { echo "$as_me:$LINENO: result: $ac_cv_prog_cxx_g" >&5 echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6; } if test "$ac_test_CXXFLAGS" = set; then CXXFLAGS=$ac_save_CXXFLAGS elif test $ac_cv_prog_cxx_g = yes; then if test "$GXX" = yes; then CXXFLAGS="-g -O2" else CXXFLAGS="-g" fi else if test "$GXX" = yes; then CXXFLAGS="-O2" else CXXFLAGS= fi fi ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu depcc="$CXX" am_compiler_list= { echo "$as_me:$LINENO: checking dependency style of $depcc" >&5 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6; } if test "${am_cv_CXX_dependencies_compiler_type+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CXX_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CXX_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CXX_dependencies_compiler_type=none fi fi { echo "$as_me:$LINENO: result: $am_cv_CXX_dependencies_compiler_type" >&5 echo "${ECHO_T}$am_cv_CXX_dependencies_compiler_type" >&6; } CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then am__fastdepCXX_TRUE= am__fastdepCXX_FALSE='#' else am__fastdepCXX_TRUE='#' am__fastdepCXX_FALSE= fi if test -n "$CXX" && ( test "X$CXX" != "Xno" && ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || (test "X$CXX" != "Xg++"))) ; then ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu { echo "$as_me:$LINENO: checking how to run the C++ preprocessor" >&5 echo $ECHO_N "checking how to run the C++ preprocessor... $ECHO_C" >&6; } if test -z "$CXXCPP"; then if test "${ac_cv_prog_CXXCPP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Double quotes because CXXCPP needs to be expanded for CXXCPP in "$CXX -E" "/lib/cpp" do ac_preproc_ok=false for ac_cxx_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || test ! -s conftest.err }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then break fi done ac_cv_prog_CXXCPP=$CXXCPP fi CXXCPP=$ac_cv_prog_CXXCPP else ac_cv_prog_CXXCPP=$CXXCPP fi { echo "$as_me:$LINENO: result: $CXXCPP" >&5 echo "${ECHO_T}$CXXCPP" >&6; } ac_preproc_ok=false for ac_cxx_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer to if __STDC__ is defined, since # exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #ifdef __STDC__ # include #else # include #endif Syntax error _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || test ! -s conftest.err }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { echo "$as_me:$LINENO: error: C++ preprocessor \"$CXXCPP\" fails sanity check See \`config.log' for more details." >&5 echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu fi ac_ext=f ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&5' ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_f77_compiler_gnu if test -n "$ac_tool_prefix"; then for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$F77"; then ac_cv_prog_F77="$F77" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_F77="$ac_tool_prefix$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi F77=$ac_cv_prog_F77 if test -n "$F77"; then { echo "$as_me:$LINENO: result: $F77" >&5 echo "${ECHO_T}$F77" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$F77" && break done fi if test -z "$F77"; then ac_ct_F77=$F77 for ac_prog in g77 xlf f77 frt pgf77 cf77 fort77 fl32 af77 xlf90 f90 pgf90 pghpf epcf90 gfortran g95 xlf95 f95 fort ifort ifc efc pgf95 lf95 ftn do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_F77"; then ac_cv_prog_ac_ct_F77="$ac_ct_F77" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_F77="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_F77=$ac_cv_prog_ac_ct_F77 if test -n "$ac_ct_F77"; then { echo "$as_me:$LINENO: result: $ac_ct_F77" >&5 echo "${ECHO_T}$ac_ct_F77" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$ac_ct_F77" && break done if test "x$ac_ct_F77" = x; then F77="" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac F77=$ac_ct_F77 fi fi # Provide some information about the compiler. echo "$as_me:$LINENO: checking for Fortran 77 compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (ac_try="$ac_compiler --version >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler --version >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -v >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -v >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -V >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -V >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } rm -f a.out # If we don't use `.F' as extension, the preprocessor is not run on the # input file. (Note that this only needs to work for GNU compilers.) ac_save_ext=$ac_ext ac_ext=F { echo "$as_me:$LINENO: checking whether we are using the GNU Fortran 77 compiler" >&5 echo $ECHO_N "checking whether we are using the GNU Fortran 77 compiler... $ECHO_C" >&6; } if test "${ac_cv_f77_compiler_gnu+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF program main #ifndef __GNUC__ choke me #endif end _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_f77_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_compiler_gnu=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_f77_compiler_gnu=$ac_compiler_gnu fi { echo "$as_me:$LINENO: result: $ac_cv_f77_compiler_gnu" >&5 echo "${ECHO_T}$ac_cv_f77_compiler_gnu" >&6; } ac_ext=$ac_save_ext ac_test_FFLAGS=${FFLAGS+set} ac_save_FFLAGS=$FFLAGS FFLAGS= { echo "$as_me:$LINENO: checking whether $F77 accepts -g" >&5 echo $ECHO_N "checking whether $F77 accepts -g... $ECHO_C" >&6; } if test "${ac_cv_prog_f77_g+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else FFLAGS=-g cat >conftest.$ac_ext <<_ACEOF program main end _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_f77_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_f77_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_prog_f77_g=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_prog_f77_g" >&5 echo "${ECHO_T}$ac_cv_prog_f77_g" >&6; } if test "$ac_test_FFLAGS" = set; then FFLAGS=$ac_save_FFLAGS elif test $ac_cv_prog_f77_g = yes; then if test "x$ac_cv_f77_compiler_gnu" = xyes; then FFLAGS="-g -O2" else FFLAGS="-g" fi else if test "x$ac_cv_f77_compiler_gnu" = xyes; then FFLAGS="-O2" else FFLAGS= fi fi G77=`test $ac_compiler_gnu = yes && echo yes` ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers! # find the maximum length of command line arguments { echo "$as_me:$LINENO: checking the maximum length of command line arguments" >&5 echo $ECHO_N "checking the maximum length of command line arguments... $ECHO_C" >&6; } if test "${lt_cv_sys_max_cmd_len+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else i=0 teststring="ABCD" case $build_os in msdosdjgpp*) # On DJGPP, this test can blow up pretty badly due to problems in libc # (any single argument exceeding 2000 bytes causes a buffer overrun # during glob expansion). Even if it were fixed, the result of this # check would be larger than it should be. lt_cv_sys_max_cmd_len=12288; # 12K is about right ;; gnu*) # Under GNU Hurd, this test is not required because there is # no limit to the length of command line arguments. # Libtool will interpret -1 as no limit whatsoever lt_cv_sys_max_cmd_len=-1; ;; cygwin* | mingw*) # On Win9x/ME, this test blows up -- it succeeds, but takes # about 5 minutes as the teststring grows exponentially. # Worse, since 9x/ME are not pre-emptively multitasking, # you end up with a "frozen" computer, even though with patience # the test eventually succeeds (with a max line length of 256k). # Instead, let's just punt: use the minimum linelength reported by # all of the supported platforms: 8192 (on NT/2K/XP). lt_cv_sys_max_cmd_len=8192; ;; amigaos*) # On AmigaOS with pdksh, this test takes hours, literally. # So we just punt and use a minimum line length of 8192. lt_cv_sys_max_cmd_len=8192; ;; netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` elif test -x /usr/sbin/sysctl; then lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` else lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs fi # And add a safety zone lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` ;; interix*) # We know the value 262144 and hardcode it with a safety zone (like BSD) lt_cv_sys_max_cmd_len=196608 ;; osf*) # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not # nice to cause kernel panics so lets avoid the loop below. # First set a reasonable default. lt_cv_sys_max_cmd_len=16384 # if test -x /sbin/sysconfig; then case `/sbin/sysconfig -q proc exec_disable_arg_limit` in *1*) lt_cv_sys_max_cmd_len=-1 ;; esac fi ;; sco3.2v5*) lt_cv_sys_max_cmd_len=102400 ;; sysv5* | sco5v6* | sysv4.2uw2*) kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` if test -n "$kargmax"; then lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` else lt_cv_sys_max_cmd_len=32768 fi ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` if test -n "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \ = "XX$teststring") >/dev/null 2>&1 && new_result=`expr "X$teststring" : ".*" 2>&1` && lt_cv_sys_max_cmd_len=$new_result && test $i != 17 # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring done teststring= # Add a significant safety factor because C++ compilers can tack on massive # amounts of additional arguments before passing them to the linker. # It appears as though 1/2 is a usable value. lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` fi ;; esac fi if test -n $lt_cv_sys_max_cmd_len ; then { echo "$as_me:$LINENO: result: $lt_cv_sys_max_cmd_len" >&5 echo "${ECHO_T}$lt_cv_sys_max_cmd_len" >&6; } else { echo "$as_me:$LINENO: result: none" >&5 echo "${ECHO_T}none" >&6; } fi # Check for command to grab the raw symbol name followed by C symbol from nm. { echo "$as_me:$LINENO: checking command to parse $NM output from $compiler object" >&5 echo $ECHO_N "checking command to parse $NM output from $compiler object... $ECHO_C" >&6; } if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # These are sane defaults that work on at least a few old systems. # [They come from Ultrix. What could be older than Ultrix?!! ;)] # Character class describing NM global symbol codes. symcode='[BCDEGRST]' # Regexp to match symbols that can be accessed directly from C. sympat='\([_A-Za-z][_A-Za-z0-9]*\)' # Transform an extracted symbol line into a proper C declaration lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^. .* \(.*\)$/extern int \1;/p'" # Transform an extracted symbol line into symbol name and symbol address lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" # Define system-specific variables. case $host_os in aix*) symcode='[BCDT]' ;; cygwin* | mingw* | pw32*) symcode='[ABCDGISTW]' ;; hpux*) # Its linker distinguishes data from code symbols if test "$host_cpu" = ia64; then symcode='[ABCDEGRST]' fi lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" ;; linux* | k*bsd*-gnu) if test "$host_cpu" = ia64; then symcode='[ABCDGIRSTW]' lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (lt_ptr) \&\2},/p'" fi ;; irix* | nonstopux*) symcode='[BCDEGRST]' ;; osf*) symcode='[BCDEGQRST]' ;; solaris*) symcode='[BDRT]' ;; sco3.2v5*) symcode='[DT]' ;; sysv4.2uw2*) symcode='[DT]' ;; sysv5* | sco5v6* | unixware* | OpenUNIX*) symcode='[ABDT]' ;; sysv4) symcode='[DFNSTU]' ;; esac # Handle CRLF in mingw tool chain opt_cr= case $build_os in mingw*) opt_cr=`echo 'x\{0,1\}' | tr x '\015'` # option cr in regexp ;; esac # If we're using GNU nm, then use its standard symbol codes. case `$NM -V 2>&1` in *GNU* | *'with BFD'*) symcode='[ABCDGIRSTW]' ;; esac # Try without a prefix undercore, then with it. for ac_symprfx in "" "_"; do # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. symxfrm="\\1 $ac_symprfx\\2 \\2" # Write the raw and C identifiers. lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" # Check to see that the pipe works correctly. pipe_works=no rm -f conftest* cat > conftest.$ac_ext <&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # Now try to grab the symbols. nlist=conftest.nm if { (eval echo "$as_me:$LINENO: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\"") >&5 (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" else rm -f "$nlist"T fi # Make sure that we snagged all the symbols we need. if grep ' nm_test_var$' "$nlist" >/dev/null; then if grep ' nm_test_func$' "$nlist" >/dev/null; then cat < conftest.$ac_ext #ifdef __cplusplus extern "C" { #endif EOF # Now generate the symbol file. eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | grep -v main >> conftest.$ac_ext' cat <> conftest.$ac_ext #if defined (__STDC__) && __STDC__ # define lt_ptr_t void * #else # define lt_ptr_t char * # define const #endif /* The mapping between symbol names and symbols. */ const struct { const char *name; lt_ptr_t address; } lt_preloaded_symbols[] = { EOF $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (lt_ptr_t) \&\2},/" < "$nlist" | grep -v main >> conftest.$ac_ext cat <<\EOF >> conftest.$ac_ext {0, (lt_ptr_t) 0} }; #ifdef __cplusplus } #endif EOF # Now try linking the two files. mv conftest.$ac_objext conftstm.$ac_objext lt_save_LIBS="$LIBS" lt_save_CFLAGS="$CFLAGS" LIBS="conftstm.$ac_objext" CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext}; then pipe_works=yes fi LIBS="$lt_save_LIBS" CFLAGS="$lt_save_CFLAGS" else echo "cannot find nm_test_func in $nlist" >&5 fi else echo "cannot find nm_test_var in $nlist" >&5 fi else echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 fi else echo "$progname: failed program was:" >&5 cat conftest.$ac_ext >&5 fi rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. if test "$pipe_works" = yes; then break else lt_cv_sys_global_symbol_pipe= fi done fi if test -z "$lt_cv_sys_global_symbol_pipe"; then lt_cv_sys_global_symbol_to_cdecl= fi if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then { echo "$as_me:$LINENO: result: failed" >&5 echo "${ECHO_T}failed" >&6; } else { echo "$as_me:$LINENO: result: ok" >&5 echo "${ECHO_T}ok" >&6; } fi { echo "$as_me:$LINENO: checking for objdir" >&5 echo $ECHO_N "checking for objdir... $ECHO_C" >&6; } if test "${lt_cv_objdir+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else rm -f .libs 2>/dev/null mkdir .libs 2>/dev/null if test -d .libs; then lt_cv_objdir=.libs else # MS-DOS does not allow filenames that begin with a dot. lt_cv_objdir=_libs fi rmdir .libs 2>/dev/null fi { echo "$as_me:$LINENO: result: $lt_cv_objdir" >&5 echo "${ECHO_T}$lt_cv_objdir" >&6; } objdir=$lt_cv_objdir case $host_os in aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test "X${COLLECT_NAMES+set}" != Xset; then COLLECT_NAMES= export COLLECT_NAMES fi ;; esac # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. Xsed='sed -e 1s/^X//' sed_quote_subst='s/\([\\"\\`$\\\\]\)/\\\1/g' # Same as above, but do not quote variable references. double_quote_subst='s/\([\\"\\`\\\\]\)/\\\1/g' # Sed substitution to delay expansion of an escaped shell variable in a # double_quote_subst'ed string. delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' # Sed substitution to avoid accidental globbing in evaled expressions no_glob_subst='s/\*/\\\*/g' # Constants: rm="rm -f" # Global variables: default_ofile=libtool can_build_shared=yes # All known linkers require a `.a' archive for static linking (except MSVC, # which needs '.lib'). libext=a ltmain="$ac_aux_dir/ltmain.sh" ofile="$default_ofile" with_gnu_ld="$lt_cv_prog_gnu_ld" if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. set dummy ${ac_tool_prefix}ar; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_AR+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$AR"; then ac_cv_prog_AR="$AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_AR="${ac_tool_prefix}ar" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AR=$ac_cv_prog_AR if test -n "$AR"; then { echo "$as_me:$LINENO: result: $AR" >&5 echo "${ECHO_T}$AR" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_AR"; then ac_ct_AR=$AR # Extract the first word of "ar", so it can be a program name with args. set dummy ar; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_AR+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_AR"; then ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_AR="ar" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_AR=$ac_cv_prog_ac_ct_AR if test -n "$ac_ct_AR"; then { echo "$as_me:$LINENO: result: $ac_ct_AR" >&5 echo "${ECHO_T}$ac_ct_AR" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_AR" = x; then AR="false" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac AR=$ac_ct_AR fi else AR="$ac_cv_prog_AR" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. set dummy ${ac_tool_prefix}ranlib; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_RANLIB+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$RANLIB"; then ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi RANLIB=$ac_cv_prog_RANLIB if test -n "$RANLIB"; then { echo "$as_me:$LINENO: result: $RANLIB" >&5 echo "${ECHO_T}$RANLIB" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_RANLIB"; then ac_ct_RANLIB=$RANLIB # Extract the first word of "ranlib", so it can be a program name with args. set dummy ranlib; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_RANLIB"; then ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_RANLIB="ranlib" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB if test -n "$ac_ct_RANLIB"; then { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5 echo "${ECHO_T}$ac_ct_RANLIB" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_RANLIB" = x; then RANLIB=":" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac RANLIB=$ac_ct_RANLIB fi else RANLIB="$ac_cv_prog_RANLIB" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { echo "$as_me:$LINENO: result: $STRIP" >&5 echo "${ECHO_T}$STRIP" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_STRIP="strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5 echo "${ECHO_T}$ac_ct_STRIP" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi old_CC="$CC" old_CFLAGS="$CFLAGS" # Set sane defaults for various variables test -z "$AR" && AR=ar test -z "$AR_FLAGS" && AR_FLAGS=cru test -z "$AS" && AS=as test -z "$CC" && CC=cc test -z "$LTCC" && LTCC=$CC test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS test -z "$DLLTOOL" && DLLTOOL=dlltool test -z "$LD" && LD=ld test -z "$LN_S" && LN_S="ln -s" test -z "$MAGIC_CMD" && MAGIC_CMD=file test -z "$NM" && NM=nm test -z "$SED" && SED=sed test -z "$OBJDUMP" && OBJDUMP=objdump test -z "$RANLIB" && RANLIB=: test -z "$STRIP" && STRIP=: test -z "$ac_objext" && ac_objext=o # Determine commands to create old-style static archives. old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' old_postinstall_cmds='chmod 644 $oldlib' old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" ;; *) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" ;; esac old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" fi for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` # Only perform the check for file, if the check method requires it case $deplibs_check_method in file_magic*) if test "$file_magic_cmd" = '$MAGIC_CMD'; then { echo "$as_me:$LINENO: checking for ${ac_tool_prefix}file" >&5 echo $ECHO_N "checking for ${ac_tool_prefix}file... $ECHO_C" >&6; } if test "${lt_cv_path_MAGIC_CMD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD="$MAGIC_CMD" lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/${ac_tool_prefix}file; then lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD="$lt_cv_path_MAGIC_CMD" if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org EOF fi ;; esac fi break fi done IFS="$lt_save_ifs" MAGIC_CMD="$lt_save_MAGIC_CMD" ;; esac fi MAGIC_CMD="$lt_cv_path_MAGIC_CMD" if test -n "$MAGIC_CMD"; then { echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5 echo "${ECHO_T}$MAGIC_CMD" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test -z "$lt_cv_path_MAGIC_CMD"; then if test -n "$ac_tool_prefix"; then { echo "$as_me:$LINENO: checking for file" >&5 echo $ECHO_N "checking for file... $ECHO_C" >&6; } if test "${lt_cv_path_MAGIC_CMD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else case $MAGIC_CMD in [\\/*] | ?:[\\/]*) lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. ;; *) lt_save_MAGIC_CMD="$MAGIC_CMD" lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" for ac_dir in $ac_dummy; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. if test -f $ac_dir/file; then lt_cv_path_MAGIC_CMD="$ac_dir/file" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` MAGIC_CMD="$lt_cv_path_MAGIC_CMD" if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : else cat <&2 *** Warning: the command libtool uses to detect shared libraries, *** $file_magic_cmd, produces output that libtool cannot recognize. *** The result is that libtool may fail to recognize shared libraries *** as such. This will affect the creation of libtool libraries that *** depend on shared libraries, but programs linked with such libtool *** libraries will work regardless of this problem. Nevertheless, you *** may want to report the problem to your system manager and/or to *** bug-libtool@gnu.org EOF fi ;; esac fi break fi done IFS="$lt_save_ifs" MAGIC_CMD="$lt_save_MAGIC_CMD" ;; esac fi MAGIC_CMD="$lt_cv_path_MAGIC_CMD" if test -n "$MAGIC_CMD"; then { echo "$as_me:$LINENO: result: $MAGIC_CMD" >&5 echo "${ECHO_T}$MAGIC_CMD" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi else MAGIC_CMD=: fi fi fi ;; esac case $host_os in rhapsody* | darwin*) if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_DSYMUTIL+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$DSYMUTIL"; then ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi DSYMUTIL=$ac_cv_prog_DSYMUTIL if test -n "$DSYMUTIL"; then { echo "$as_me:$LINENO: result: $DSYMUTIL" >&5 echo "${ECHO_T}$DSYMUTIL" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_DSYMUTIL"; then ac_ct_DSYMUTIL=$DSYMUTIL # Extract the first word of "dsymutil", so it can be a program name with args. set dummy dsymutil; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_DSYMUTIL+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_DSYMUTIL"; then ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL if test -n "$ac_ct_DSYMUTIL"; then { echo "$as_me:$LINENO: result: $ac_ct_DSYMUTIL" >&5 echo "${ECHO_T}$ac_ct_DSYMUTIL" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_DSYMUTIL" = x; then DSYMUTIL=":" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac DSYMUTIL=$ac_ct_DSYMUTIL fi else DSYMUTIL="$ac_cv_prog_DSYMUTIL" fi if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. set dummy ${ac_tool_prefix}nmedit; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_NMEDIT+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$NMEDIT"; then ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi NMEDIT=$ac_cv_prog_NMEDIT if test -n "$NMEDIT"; then { echo "$as_me:$LINENO: result: $NMEDIT" >&5 echo "${ECHO_T}$NMEDIT" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_NMEDIT"; then ac_ct_NMEDIT=$NMEDIT # Extract the first word of "nmedit", so it can be a program name with args. set dummy nmedit; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_NMEDIT+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_NMEDIT"; then ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_NMEDIT="nmedit" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT if test -n "$ac_ct_NMEDIT"; then { echo "$as_me:$LINENO: result: $ac_ct_NMEDIT" >&5 echo "${ECHO_T}$ac_ct_NMEDIT" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_NMEDIT" = x; then NMEDIT=":" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac NMEDIT=$ac_ct_NMEDIT fi else NMEDIT="$ac_cv_prog_NMEDIT" fi { echo "$as_me:$LINENO: checking for -single_module linker flag" >&5 echo $ECHO_N "checking for -single_module linker flag... $ECHO_C" >&6; } if test "${lt_cv_apple_cc_single_mod+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_apple_cc_single_mod=no if test -z "${LT_MULTI_MODULE}"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the # link flags. echo "int foo(void){return 1;}" > conftest.c $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ -dynamiclib ${wl}-single_module conftest.c if test -f libconftest.dylib; then lt_cv_apple_cc_single_mod=yes rm -rf libconftest.dylib* fi rm conftest.c fi fi { echo "$as_me:$LINENO: result: $lt_cv_apple_cc_single_mod" >&5 echo "${ECHO_T}$lt_cv_apple_cc_single_mod" >&6; } { echo "$as_me:$LINENO: checking for -exported_symbols_list linker flag" >&5 echo $ECHO_N "checking for -exported_symbols_list linker flag... $ECHO_C" >&6; } if test "${lt_cv_ld_exported_symbols_list+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_ld_exported_symbols_list=no save_LDFLAGS=$LDFLAGS echo "_main" > conftest.sym LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_cv_ld_exported_symbols_list=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 lt_cv_ld_exported_symbols_list=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LDFLAGS="$save_LDFLAGS" fi { echo "$as_me:$LINENO: result: $lt_cv_ld_exported_symbols_list" >&5 echo "${ECHO_T}$lt_cv_ld_exported_symbols_list" >&6; } case $host_os in rhapsody* | darwin1.[0123]) _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; darwin1.*) _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; darwin*) # if running on 10.5 or later, the deployment target defaults # to the OS version, if on x86, and 10.4, the deployment # target defaults to 10.4. Don't you love it? case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in 10.0,*86*-darwin8*|10.0,*-darwin[91]*) _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; 10.[012]*) _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 10.*) _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; esac ;; esac if test "$lt_cv_apple_cc_single_mod" = "yes"; then _lt_dar_single_mod='$single_module' fi if test "$lt_cv_ld_exported_symbols_list" = "yes"; then _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' else _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}" fi if test "$DSYMUTIL" != ":"; then _lt_dsymutil="~$DSYMUTIL \$lib || :" else _lt_dsymutil= fi ;; esac enable_dlopen=no enable_win32_dll=no # Check whether --enable-libtool-lock was given. if test "${enable_libtool_lock+set}" = set; then enableval=$enable_libtool_lock; fi test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes # Check whether --with-pic was given. if test "${with_pic+set}" = set; then withval=$with_pic; pic_mode="$withval" else pic_mode=default fi test -z "$pic_mode" && pic_mode=default # Use C for the default configuration in the libtool script tagname= lt_save_CC="$CC" ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu # Source file extension for C test sources. ac_ext=c # Object file extension for compiled C test sources. objext=o objext=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(){return(0);}' # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $rm conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $rm -r conftest* lt_prog_compiler_no_builtin_flag= if test "$GCC" = yes; then lt_prog_compiler_no_builtin_flag=' -fno-builtin' { echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-fno-rtti -fno-exceptions" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:7362: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:7366: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_rtti_exceptions=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6; } if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" else : fi fi lt_prog_compiler_wl= lt_prog_compiler_pic= lt_prog_compiler_static= { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; } if test "$GCC" = yes; then lt_prog_compiler_wl='-Wl,' lt_prog_compiler_static='-static' case $host_os in aix*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' fi ;; amigaos*) # FIXME: we need at least 68020 code to build shared libraries, but # adding the `-m68020' flag to GCC prevents building anything better, # like `-m68040'. lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic='-DDLL_EXPORT' ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic='-fno-common' ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. lt_prog_compiler_can_build_shared=no enable_shared=no ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic=-Kconform_pic fi ;; hpux*) # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic='-fPIC' ;; esac ;; *) lt_prog_compiler_pic='-fPIC' ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) lt_prog_compiler_wl='-Wl,' if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static='-Bstatic' else lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' fi ;; darwin*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files case $cc_basename in xlc*) lt_prog_compiler_pic='-qnocommon' lt_prog_compiler_wl='-Wl,' ;; esac ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). lt_prog_compiler_pic='-DDLL_EXPORT' ;; hpux9* | hpux10* | hpux11*) lt_prog_compiler_wl='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? lt_prog_compiler_static='${wl}-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) lt_prog_compiler_wl='-Wl,' # PIC (with -KPIC) is the default. lt_prog_compiler_static='-non_shared' ;; newsos6) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; linux* | k*bsd*-gnu) case $cc_basename in icc* | ecc*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-static' ;; pgcc* | pgf77* | pgf90* | pgf95*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-fpic' lt_prog_compiler_static='-Bstatic' ;; ccc*) lt_prog_compiler_wl='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static='-non_shared' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='-Wl,' ;; *Sun\ F*) # Sun Fortran 8.3 passes all unrecognized flags to the linker lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' lt_prog_compiler_wl='' ;; esac ;; esac ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static='-non_shared' ;; rdos*) lt_prog_compiler_static='-non_shared' ;; solaris*) lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' case $cc_basename in f77* | f90* | f95*) lt_prog_compiler_wl='-Qoption ld ';; *) lt_prog_compiler_wl='-Wl,';; esac ;; sunos4*) lt_prog_compiler_wl='-Qoption ld ' lt_prog_compiler_pic='-PIC' lt_prog_compiler_static='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec ;then lt_prog_compiler_pic='-Kconform_pic' lt_prog_compiler_static='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_pic='-KPIC' lt_prog_compiler_static='-Bstatic' ;; unicos*) lt_prog_compiler_wl='-Wl,' lt_prog_compiler_can_build_shared=no ;; uts4*) lt_prog_compiler_pic='-pic' lt_prog_compiler_static='-Bstatic' ;; *) lt_prog_compiler_can_build_shared=no ;; esac fi { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic" >&5 echo "${ECHO_T}$lt_prog_compiler_pic" >&6; } # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic"; then { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_pic_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_pic_works=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic -DPIC" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:7652: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:7656: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_pic_works" >&6; } if test x"$lt_cv_prog_compiler_pic_works" = xyes; then case $lt_prog_compiler_pic in "" | " "*) ;; *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; esac else lt_prog_compiler_pic= lt_prog_compiler_can_build_shared=no fi fi case $host_os in # For platforms which do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic= ;; *) lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" ;; esac # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_static_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_static_works=no save_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works=yes fi else lt_cv_prog_compiler_static_works=yes fi fi $rm -r conftest* LDFLAGS="$save_LDFLAGS" fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_static_works" >&6; } if test x"$lt_cv_prog_compiler_static_works" = xyes; then : else lt_prog_compiler_static= fi { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_c_o+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:7756: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:7760: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o=yes fi fi chmod u+w . 2>&5 $rm conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files $rm out/* && rmdir out cd .. rmdir conftest $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o" >&6; } hard_links="nottested" if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then # do not overwrite the value of need_locks provided by the user { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; } hard_links=yes $rm conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6; } if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; } runpath_var= allow_undefined_flag= enable_shared_with_static_runtimes=no archive_cmds= archive_expsym_cmds= old_archive_From_new_cmds= old_archive_from_expsyms_cmds= export_dynamic_flag_spec= whole_archive_flag_spec= thread_safe_flag_spec= hardcode_libdir_flag_spec= hardcode_libdir_flag_spec_ld= hardcode_libdir_separator= hardcode_direct=no hardcode_minus_L=no hardcode_shlibpath_var=unsupported link_all_deplibs=unknown hardcode_automatic=no module_cmds= module_expsym_cmds= always_export_symbols=no export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list include_expsyms= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ` (' and `)$', so one must not match beginning or # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', # as well as any symbol that contains `d'. exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. extract_expsyms_cmds= # Just being paranoid about ensuring that cc_basename is set. for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` case $host_os in cygwin* | mingw* | pw32*) # FIXME: the MSVC++ port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++. if test "$GCC" != yes; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++) with_gnu_ld=yes ;; openbsd*) with_gnu_ld=no ;; esac ld_shlibs=yes if test "$with_gnu_ld" = yes; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='${wl}' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec='${wl}--rpath ${wl}$libdir' export_dynamic_flag_spec='${wl}--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else whole_archive_flag_spec= fi supports_anon_versioning=no case `$LD -v 2>/dev/null` in *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[3-9]*) # On AIX/PPC, the GNU linker is very broken if test "$host_cpu" != ia64; then ld_shlibs=no cat <&2 *** Warning: the GNU linker, at least up to release 2.9.1, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to modify your PATH *** so that a non-GNU linker is found, and then restart. EOF fi ;; amigaos*) archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes # Samuel A. Falvo II reports # that the semantics of dynamic libraries on AmigaOS, at least up # to version 4, is to share data among multiple programs linked # with the same dynamic library. Since this doesn't match the # behavior of shared libraries on other platforms, we can't use # them. ld_shlibs=no ;; beos*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then allow_undefined_flag=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' else ld_shlibs=no fi ;; cygwin* | mingw* | pw32*) # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec='-L$libdir' allow_undefined_flag=unsupported always_export_symbols=no enable_shared_with_static_runtimes=yes export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file (1st line # is EXPORTS), use it as is; otherwise, prepend... archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs=no fi ;; interix[3-9]*) hardcode_direct=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='${wl}-rpath,$libdir' export_dynamic_flag_spec='${wl}-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | k*bsd*-gnu) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then tmp_addflag= case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; esac case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; *) tmp_sharedflag='-shared' ;; esac archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' if test $supports_anon_versioning = yes; then archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ $echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' fi link_all_deplibs=no else ld_shlibs=no fi ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then ld_shlibs=no cat <&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. EOF elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) ld_shlibs=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' else ld_shlibs=no fi ;; esac ;; sunos4*) archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct=yes hardcode_shlibpath_var=no ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs=no fi ;; esac if test "$ld_shlibs" = no; then runpath_var= hardcode_libdir_flag_spec= export_dynamic_flag_spec= whole_archive_flag_spec= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) allow_undefined_flag=unsupported always_export_symbols=yes archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. hardcode_minus_L=yes if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct=unsupported fi ;; aix[4-9]*) if test "$host_cpu" = ia64; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag="" else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to AIX nm, but means don't demangle with GNU nm if $NM -V 2>&1 | grep 'GNU' > /dev/null; then export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' else export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # need to do runtime linking. case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then aix_use_runtimelinking=yes break fi done ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds='' hardcode_direct=yes hardcode_libdir_separator=':' link_all_deplibs=yes if test "$GCC" = yes; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`${CC} -print-prog-name=collect2` if test -f "$collect2name" && \ strings "$collect2name" | grep resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L=yes hardcode_libdir_flag_spec='-L$libdir' hardcode_libdir_separator= fi ;; esac shared_flag='-shared' if test "$aix_use_runtimelinking" = yes; then shared_flag="$shared_flag "'${wl}-G' fi else # not using gcc if test "$host_cpu" = ia64; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test "$aix_use_runtimelinking" = yes; then shared_flag='${wl}-G' else shared_flag='${wl}-bM:SRE' fi fi fi # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols=yes if test "$aix_use_runtimelinking" = yes; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag='-berok' # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" else if test "$host_cpu" = ia64; then hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' allow_undefined_flag="-z nodefs" archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag=' ${wl}-bernotok' allow_undefined_flag=' ${wl}-berok' # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec='$convenience' archive_cmds_need_lc=yes # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; amigaos*) archive_cmds='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes # see comment about different semantics on the GNU ld section ld_shlibs=no ;; bsdi[45]*) export_dynamic_flag_spec=-rdynamic ;; cygwin* | mingw* | pw32*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. hardcode_libdir_flag_spec=' ' allow_undefined_flag=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=".dll" # FIXME: Setting linknames here is a bad hack. archive_cmds='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. old_archive_From_new_cmds='true' # FIXME: Should let the user specify the lib program. old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' fix_srcfile_path='`cygpath -w "$srcfile"`' enable_shared_with_static_runtimes=yes ;; darwin* | rhapsody*) case $host_os in rhapsody* | darwin1.[012]) allow_undefined_flag='${wl}-undefined ${wl}suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[012]) allow_undefined_flag='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 10.*) allow_undefined_flag='${wl}-undefined ${wl}dynamic_lookup' ;; esac fi ;; esac archive_cmds_need_lc=no hardcode_direct=no hardcode_automatic=yes hardcode_shlibpath_var=unsupported whole_archive_flag_spec='' link_all_deplibs=yes if test "$GCC" = yes ; then output_verbose_link_cmd='echo' archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" else case $cc_basename in xlc*) output_verbose_link_cmd='echo' archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' module_expsym_cmds='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' ;; *) ld_shlibs=no ;; esac fi ;; dgux*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; freebsd1*) ld_shlibs=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly*) archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; hpux9*) if test "$GCC" = yes; then archive_cmds='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' else archive_cmds='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' fi hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' hardcode_libdir_separator=: hardcode_direct=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes export_dynamic_flag_spec='${wl}-E' ;; hpux10*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' hardcode_libdir_separator=: hardcode_direct=yes export_dynamic_flag_spec='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes fi ;; hpux11*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then case $host_cpu in hppa*64*) archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' hardcode_libdir_separator=: case $host_cpu in hppa*64*|ia64*) hardcode_libdir_flag_spec_ld='+b $libdir' hardcode_direct=no hardcode_shlibpath_var=no ;; *) hardcode_direct=yes export_dynamic_flag_spec='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test "$GCC" = yes; then archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else archive_cmds='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_ld='-rpath $libdir' fi hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator=: link_all_deplibs=yes ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi hardcode_libdir_flag_spec='-R$libdir' hardcode_direct=yes hardcode_shlibpath_var=no ;; newsos6) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator=: hardcode_shlibpath_var=no ;; openbsd*) if test -f /usr/libexec/ld.so; then hardcode_direct=yes hardcode_shlibpath_var=no if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' hardcode_libdir_flag_spec='${wl}-rpath,$libdir' export_dynamic_flag_spec='${wl}-E' else case $host_os in openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-R$libdir' ;; *) archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec='${wl}-rpath,$libdir' ;; esac fi else ld_shlibs=no fi ;; os2*) hardcode_libdir_flag_spec='-L$libdir' hardcode_minus_L=yes allow_undefined_flag=unsupported archive_cmds='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' old_archive_From_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' ;; osf3*) if test "$GCC" = yes; then allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' fi hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test "$GCC" = yes; then allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' else allow_undefined_flag=' -expect_unresolved \*' archive_cmds='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec='-rpath $libdir' fi hardcode_libdir_separator=: ;; solaris*) no_undefined_flag=' -z text' if test "$GCC" = yes; then wlarc='${wl}' archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' else wlarc='' archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' fi hardcode_libdir_flag_spec='-R$libdir' hardcode_shlibpath_var=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands `-z linker_flag'. GCC discards it without `$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test "$GCC" = yes; then whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' else whole_archive_flag_spec='-z allextract$convenience -z defaultextract' fi ;; esac link_all_deplibs=yes ;; sunos4*) if test "x$host_vendor" = xsequent; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi hardcode_libdir_flag_spec='-L$libdir' hardcode_direct=yes hardcode_minus_L=yes hardcode_shlibpath_var=no ;; sysv4) case $host_vendor in sni) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' reload_cmds='$CC -r -o $output$reload_objs' hardcode_direct=no ;; motorola) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' hardcode_shlibpath_var=no ;; sysv4.3*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no export_dynamic_flag_spec='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ld_shlibs=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag='${wl}-z,text' archive_cmds_need_lc=no hardcode_shlibpath_var=no runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We can NOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag='${wl}-z,text' allow_undefined_flag='${wl}-z,nodefs' archive_cmds_need_lc=no hardcode_shlibpath_var=no hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' hardcode_libdir_separator=':' link_all_deplibs=yes export_dynamic_flag_spec='${wl}-Bexport' runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec='-L$libdir' hardcode_shlibpath_var=no ;; *) ld_shlibs=no ;; esac fi { echo "$as_me:$LINENO: result: $ld_shlibs" >&5 echo "${ECHO_T}$ld_shlibs" >&6; } test "$ld_shlibs" = no && can_build_shared=no # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc" in x|xyes) # Assume -lc should be added archive_cmds_need_lc=yes if test "$enable_shared" = yes && test "$GCC" = yes; then case $archive_cmds in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; } $rm conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl pic_flag=$lt_prog_compiler_pic compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag allow_undefined_flag= if { (eval echo "$as_me:$LINENO: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } then archive_cmds_need_lc=no else archive_cmds_need_lc=yes fi allow_undefined_flag=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $rm conftest* { echo "$as_me:$LINENO: result: $archive_cmds_need_lc" >&5 echo "${ECHO_T}$archive_cmds_need_lc" >&6; } ;; esac fi ;; esac { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; } library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=".so" postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" if test "$GCC" = yes; then case $host_os in darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; *) lt_awk_arg="/^libraries:/" ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then # if the path contains ";" then we assume it to be the separator # otherwise default to the standard path separator (i.e. ":") - it is # assumed that no part of a normal pathname contains ";" but that should # okay in the real world where ";" in dirpaths is itself problematic. lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'` else lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi # Ok, now we have the path, separated by spaces, we can step through it # and add multilib dir if necessary. lt_tmp_lt_search_path_spec= lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` for lt_sys_path in $lt_search_path_spec; do if test -d "$lt_sys_path/$lt_multi_os_dir"; then lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" else test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk ' BEGIN {RS=" "; FS="/|\n";} { lt_foo=""; lt_count=0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { lt_foo="/" $lt_i lt_foo; } else { lt_count--; } } } } if (lt_foo != "") { lt_freq[lt_foo]++; } if (lt_freq[lt_foo] == 1) { print lt_foo; } }'` sys_lib_search_path_spec=`echo $lt_search_path_spec` else sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" fi need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='${libname}${release}${shared_ext}$major' ;; aix[4-9]*) version_type=linux need_lib_prefix=no need_version=no hardcode_into_libs=yes if test "$host_cpu" = ia64; then # AIX 5 supports IA64 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line `#! .'. This would cause the generated library to # depend on `.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then : else can_build_shared=no fi ;; esac # AIX (on Power*) has no versioning support, so currently we can not hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. if test "$aix_use_runtimelinking" = yes; then # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' else # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='${libname}${release}.a $libname.a' soname_spec='${libname}${release}${shared_ext}$major' fi shlibpath_var=LIBPATH fi ;; amigaos*) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; beos*) library_names_spec='${libname}${shared_ext}' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32*) version_type=windows shrext_cmds=".dll" need_version=no need_lib_prefix=no case $GCC,$host_os in yes,cygwin* | yes,mingw* | yes,pw32*) library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \${file}`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" ;; mingw*) # MinGW DLLs use traditional 'lib' prefix soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH printed by # mingw gcc, but we are running on Cygwin. Gcc prints its search # path with ; separators, and with drive letters. We can handle the # drive letters (cygwin fileutils understands them), so leave them, # especially as we might pass files found there to a mingw objdump, # which wouldn't understand a cygwinified path. Ahh. sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' ;; esac ;; *) library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' ;; esac dynamic_linker='Win32 ld.exe' # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' soname_spec='${libname}${release}${major}$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd1*) dynamic_linker=no ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[123]*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; gnu*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' if test "X$HPUX_IA64_MODE" = X32; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" fi sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555. postinstall_cmds='chmod 555 $lib' ;; interix[3-9]*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test "$lt_cv_prog_gnu_ld" = yes; then version_type=linux else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. linux* | k*bsd*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Append ld.so.conf contents to the search path if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsdelf*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; nto-qnx*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; openbsd*) version_type=sunos sys_lib_dlsearch_path_spec="/usr/lib" need_lib_prefix=no # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. case $host_os in openbsd3.3 | openbsd3.3.*) need_version=yes ;; *) need_version=no ;; esac library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then case $host_os in openbsd2.[89] | openbsd2.[89].*) shlibpath_overrides_runpath=no ;; *) shlibpath_overrides_runpath=yes ;; esac else shlibpath_overrides_runpath=yes fi ;; os2*) libname_spec='$name' shrext_cmds=".dll" need_lib_prefix=no library_names_spec='$libname${shared_ext} $libname.a' dynamic_linker='OS/2 ld.exe' shlibpath_var=LIBPATH ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test "$with_gnu_ld" = yes; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no export_dynamic_flag_spec='${wl}-Blargedynsym' runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec ;then version_type=linux library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' soname_spec='$libname${shared_ext}.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=freebsd-elf need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes if test "$with_gnu_ld" = yes; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' shlibpath_overrides_runpath=no else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' shlibpath_overrides_runpath=yes case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; uts4*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6; } test "$dynamic_linker" = no && can_build_shared=no if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" fi sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" fi sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test "$GCC" = yes; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; } hardcode_action= if test -n "$hardcode_libdir_flag_spec" || \ test -n "$runpath_var" || \ test "X$hardcode_automatic" = "Xyes" ; then # We can hardcode non-existant directories. if test "$hardcode_direct" != no && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, )" != no && test "$hardcode_minus_L" != no; then # Linking always hardcodes the temporary library directory. hardcode_action=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action=unsupported fi { echo "$as_me:$LINENO: result: $hardcode_action" >&5 echo "${ECHO_T}$hardcode_action" >&6; } if test "$hardcode_action" = relink; then # Fast installation is not supported enable_fast_install=no elif test "$shlibpath_overrides_runpath" = yes || test "$enable_shared" = no; then # Fast installation is not necessary enable_fast_install=needless fi striplib= old_striplib= { echo "$as_me:$LINENO: checking whether stripping libraries is possible" >&5 echo $ECHO_N "checking whether stripping libraries is possible... $ECHO_C" >&6; } if test -n "$STRIP" && $STRIP -V 2>&1 | grep "GNU strip" >/dev/null; then test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" test -z "$striplib" && striplib="$STRIP --strip-unneeded" { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } else # FIXME - insert some real tests, host_os isn't really good enough case $host_os in darwin*) if test -n "$STRIP" ; then striplib="$STRIP -x" old_striplib="$STRIP -S" { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi ;; *) { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } ;; esac fi if test "x$enable_dlopen" != xyes; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown else lt_cv_dlopen=no lt_cv_dlopen_libs= case $host_os in beos*) lt_cv_dlopen="load_add_on" lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32*) lt_cv_dlopen="LoadLibrary" lt_cv_dlopen_libs= ;; cygwin*) lt_cv_dlopen="dlopen" lt_cv_dlopen_libs= ;; darwin*) # if libdl is installed we need to link against it { echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6; } if test "${ac_cv_lib_dl_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_dl_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6; } if test $ac_cv_lib_dl_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else lt_cv_dlopen="dyld" lt_cv_dlopen_libs= lt_cv_dlopen_self=yes fi ;; *) { echo "$as_me:$LINENO: checking for shl_load" >&5 echo $ECHO_N "checking for shl_load... $ECHO_C" >&6; } if test "${ac_cv_func_shl_load+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Define shl_load to an innocuous variant, in case declares shl_load. For example, HP-UX 11i declares gettimeofday. */ #define shl_load innocuous_shl_load /* System header to define __stub macros and hopefully few prototypes, which can conflict with char shl_load (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef shl_load /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char shl_load (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_shl_load || defined __stub___shl_load choke me #endif int main () { return shl_load (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_func_shl_load=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_func_shl_load=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_func_shl_load" >&5 echo "${ECHO_T}$ac_cv_func_shl_load" >&6; } if test $ac_cv_func_shl_load = yes; then lt_cv_dlopen="shl_load" else { echo "$as_me:$LINENO: checking for shl_load in -ldld" >&5 echo $ECHO_N "checking for shl_load in -ldld... $ECHO_C" >&6; } if test "${ac_cv_lib_dld_shl_load+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char shl_load (); int main () { return shl_load (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_dld_shl_load=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dld_shl_load=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_dld_shl_load" >&5 echo "${ECHO_T}$ac_cv_lib_dld_shl_load" >&6; } if test $ac_cv_lib_dld_shl_load = yes; then lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" else { echo "$as_me:$LINENO: checking for dlopen" >&5 echo $ECHO_N "checking for dlopen... $ECHO_C" >&6; } if test "${ac_cv_func_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Define dlopen to an innocuous variant, in case declares dlopen. For example, HP-UX 11i declares gettimeofday. */ #define dlopen innocuous_dlopen /* System header to define __stub macros and hopefully few prototypes, which can conflict with char dlopen (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef dlopen /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_dlopen || defined __stub___dlopen choke me #endif int main () { return dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_func_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_func_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5 echo "${ECHO_T}$ac_cv_func_dlopen" >&6; } if test $ac_cv_func_dlopen = yes; then lt_cv_dlopen="dlopen" else { echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6; } if test "${ac_cv_lib_dl_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_dl_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dl_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6; } if test $ac_cv_lib_dl_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" else { echo "$as_me:$LINENO: checking for dlopen in -lsvld" >&5 echo $ECHO_N "checking for dlopen in -lsvld... $ECHO_C" >&6; } if test "${ac_cv_lib_svld_dlopen+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lsvld $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlopen (); int main () { return dlopen (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_svld_dlopen=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_svld_dlopen=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_svld_dlopen" >&5 echo "${ECHO_T}$ac_cv_lib_svld_dlopen" >&6; } if test $ac_cv_lib_svld_dlopen = yes; then lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" else { echo "$as_me:$LINENO: checking for dld_link in -ldld" >&5 echo $ECHO_N "checking for dld_link in -ldld... $ECHO_C" >&6; } if test "${ac_cv_lib_dld_dld_link+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldld $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dld_link (); int main () { return dld_link (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_dld_dld_link=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dld_dld_link=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_dld_dld_link" >&5 echo "${ECHO_T}$ac_cv_lib_dld_dld_link" >&6; } if test $ac_cv_lib_dld_dld_link = yes; then lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" fi fi fi fi fi fi ;; esac if test "x$lt_cv_dlopen" != xno; then enable_dlopen=yes else enable_dlopen=no fi case $lt_cv_dlopen in dlopen) save_CPPFLAGS="$CPPFLAGS" test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" save_LDFLAGS="$LDFLAGS" wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" save_LIBS="$LIBS" LIBS="$lt_cv_dlopen_libs $LIBS" { echo "$as_me:$LINENO: checking whether a program can dlopen itself" >&5 echo $ECHO_N "checking whether a program can dlopen itself... $ECHO_C" >&6; } if test "${lt_cv_dlopen_self+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then : lt_cv_dlopen_self=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext < #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif #ifdef __cplusplus extern "C" void exit (int); #endif void fnord() { int i=42;} int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; /* dlclose (self); */ } else puts (dlerror ()); exit (status); } EOF if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; esac else : # compilation failed lt_cv_dlopen_self=no fi fi rm -fr conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_dlopen_self" >&5 echo "${ECHO_T}$lt_cv_dlopen_self" >&6; } if test "x$lt_cv_dlopen_self" = xyes; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" { echo "$as_me:$LINENO: checking whether a statically linked program can dlopen itself" >&5 echo $ECHO_N "checking whether a statically linked program can dlopen itself... $ECHO_C" >&6; } if test "${lt_cv_dlopen_self_static+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then : lt_cv_dlopen_self_static=cross else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_status=$lt_dlunknown cat > conftest.$ac_ext < #endif #include #ifdef RTLD_GLOBAL # define LT_DLGLOBAL RTLD_GLOBAL #else # ifdef DL_GLOBAL # define LT_DLGLOBAL DL_GLOBAL # else # define LT_DLGLOBAL 0 # endif #endif /* We may have to define LT_DLLAZY_OR_NOW in the command line if we find out it does not work in some platform. */ #ifndef LT_DLLAZY_OR_NOW # ifdef RTLD_LAZY # define LT_DLLAZY_OR_NOW RTLD_LAZY # else # ifdef DL_LAZY # define LT_DLLAZY_OR_NOW DL_LAZY # else # ifdef RTLD_NOW # define LT_DLLAZY_OR_NOW RTLD_NOW # else # ifdef DL_NOW # define LT_DLLAZY_OR_NOW DL_NOW # else # define LT_DLLAZY_OR_NOW 0 # endif # endif # endif # endif #endif #ifdef __cplusplus extern "C" void exit (int); #endif void fnord() { int i=42;} int main () { void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); int status = $lt_dlunknown; if (self) { if (dlsym (self,"fnord")) status = $lt_dlno_uscore; else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; /* dlclose (self); */ } else puts (dlerror ()); exit (status); } EOF if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5 (eval $ac_link) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && test -s conftest${ac_exeext} 2>/dev/null; then (./conftest; exit; ) >&5 2>/dev/null lt_status=$? case x$lt_status in x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; esac else : # compilation failed lt_cv_dlopen_self_static=no fi fi rm -fr conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_dlopen_self_static" >&5 echo "${ECHO_T}$lt_cv_dlopen_self_static" >&6; } fi CPPFLAGS="$save_CPPFLAGS" LDFLAGS="$save_LDFLAGS" LIBS="$save_LIBS" ;; esac case $lt_cv_dlopen_self in yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; *) enable_dlopen_self=unknown ;; esac case $lt_cv_dlopen_self_static in yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; *) enable_dlopen_self_static=unknown ;; esac fi # Report which library types will actually be built { echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6; } { echo "$as_me:$LINENO: result: $can_build_shared" >&5 echo "${ECHO_T}$can_build_shared" >&6; } { echo "$as_me:$LINENO: checking whether to build shared libraries" >&5 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6; } test "$can_build_shared" = "no" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test "$enable_shared" = yes && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[4-9]*) if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then test "$enable_shared" = yes && enable_static=no fi ;; esac { echo "$as_me:$LINENO: result: $enable_shared" >&5 echo "${ECHO_T}$enable_shared" >&6; } { echo "$as_me:$LINENO: checking whether to build static libraries" >&5 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6; } # Make sure either enable_shared or enable_static is yes. test "$enable_shared" = yes || enable_static=yes { echo "$as_me:$LINENO: result: $enable_static" >&5 echo "${ECHO_T}$enable_static" >&6; } # The else clause should only fire when bootstrapping the # libtool distribution, otherwise you forgot to ship ltmain.sh # with your package, and you will get complaints that there are # no rules to generate ltmain.sh. if test -f "$ltmain"; then # See if we are running on zsh, and set the options which allow our commands through # without removal of \ escapes. if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi # Now quote all the things that may contain metacharacters while being # careful not to overquote the AC_SUBSTed values. We take copies of the # variables and quote the copies for generation of the libtool script. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ SED SHELL STRIP \ libname_spec library_names_spec soname_spec extract_expsyms_cmds \ old_striplib striplib file_magic_cmd finish_cmds finish_eval \ deplibs_check_method reload_flag reload_cmds need_locks \ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_c_name_address \ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ old_postinstall_cmds old_postuninstall_cmds \ compiler \ CC \ LD \ lt_prog_compiler_wl \ lt_prog_compiler_pic \ lt_prog_compiler_static \ lt_prog_compiler_no_builtin_flag \ export_dynamic_flag_spec \ thread_safe_flag_spec \ whole_archive_flag_spec \ enable_shared_with_static_runtimes \ old_archive_cmds \ old_archive_from_new_cmds \ predep_objects \ postdep_objects \ predeps \ postdeps \ compiler_lib_search_path \ compiler_lib_search_dirs \ archive_cmds \ archive_expsym_cmds \ postinstall_cmds \ postuninstall_cmds \ old_archive_from_expsyms_cmds \ allow_undefined_flag \ no_undefined_flag \ export_symbols_cmds \ hardcode_libdir_flag_spec \ hardcode_libdir_flag_spec_ld \ hardcode_libdir_separator \ hardcode_automatic \ module_cmds \ module_expsym_cmds \ lt_cv_prog_compiler_c_o \ fix_srcfile_path \ exclude_expsyms \ include_expsyms; do case $var in old_archive_cmds | \ old_archive_from_new_cmds | \ archive_cmds | \ archive_expsym_cmds | \ module_cmds | \ module_expsym_cmds | \ old_archive_from_expsyms_cmds | \ export_symbols_cmds | \ extract_expsyms_cmds | reload_cmds | finish_cmds | \ postinstall_cmds | postuninstall_cmds | \ old_postinstall_cmds | old_postuninstall_cmds | \ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) # Double-quote double-evaled strings. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" ;; *) eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; esac done case $lt_echo in *'\$0 --fallback-echo"') lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` ;; esac cfgfile="${ofile}T" trap "$rm \"$cfgfile\"; exit 1" 1 2 15 $rm -f "$cfgfile" { echo "$as_me:$LINENO: creating $ofile" >&5 echo "$as_me: creating $ofile" >&6;} cat <<__EOF__ >> "$cfgfile" #! $SHELL # `$echo "$cfgfile" | sed 's%^.*/%%'` - Provide generalized library-building support services. # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP) # NOTE: Changes made to this file will be lost: look at ltmain.sh. # # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 # Free Software Foundation, Inc. # # This file is part of GNU Libtool: # Originally by Gordon Matzigkeit , 1996 # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # A sed program that does not truncate output. SED=$lt_SED # Sed that helps us avoid accidentally triggering echo(1) options like -n. Xsed="$SED -e 1s/^X//" # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # The names of the tagged configurations supported by this script. available_tags= # ### BEGIN LIBTOOL CONFIG # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # An echo program that does not interpret backslashes. echo=$lt_echo # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A C compiler. LTCC=$lt_LTCC # LTCC compiler flags. LTCFLAGS=$lt_LTCFLAGS # A language-specific compiler. CC=$lt_compiler # Is the compiler the GNU C compiler? with_gcc=$GCC # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD # Whether we need hard or soft links. LN_S=$lt_LN_S # A BSD-compatible nm program. NM=$lt_NM # A symbol stripping program STRIP=$lt_STRIP # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL" # Used on cygwin: object dumper. OBJDUMP="$OBJDUMP" # Used on cygwin: assembler. AS="$AS" # The name of the directory that contains temporary libtool files. objdir=$objdir # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl # Object file suffix (normally "o"). objext="$ac_objext" # Old archive suffix (normally "a"). libext="$libext" # Shared library suffix (normally ".so"). shrext_cmds='$shrext_cmds' # Executable file suffix (normally ""). exeext="$exeext" # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic pic_mode=$pic_mode # What is the maximum length of a command? max_cmd_len=$lt_cv_sys_max_cmd_len # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o # Must we lock files when doing compilation? need_locks=$lt_need_locks # Do we need the lib prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec # Library versioning type. version_type=$version_type # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Commands used to build and install an old-style archive. RANLIB=$lt_RANLIB old_archive_cmds=$lt_old_archive_cmds old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds # Commands used to build and install a shared archive. archive_cmds=$lt_archive_cmds archive_expsym_cmds=$lt_archive_expsym_cmds postinstall_cmds=$lt_postinstall_cmds postuninstall_cmds=$lt_postuninstall_cmds # Commands used to build a loadable module (assumed same as above if empty) module_cmds=$lt_module_cmds module_expsym_cmds=$lt_module_expsym_cmds # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_predep_objects # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs=$lt_compiler_lib_search_dirs # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method == file_magic. file_magic_cmd=$lt_file_magic_cmd # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # Same as above, but a single script fragment to be evaled but not shown. finish_eval=$lt_finish_eval # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm in a C name address pair global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # This is the shared library runtime path variable. runpath_var=$runpath_var # This is the shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist. hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec # If ld is used when linking, flag to hardcode \$libdir into # a binary during linking. This must work even if \$libdir does # not exist. hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=$hardcode_automatic # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="$variables_saved_for_relink" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs # Compile-time system search path for libraries sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Run-time system search path for libraries sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec # Fix the shell variable \$srcfile for the compiler. fix_srcfile_path=$lt_fix_srcfile_path # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms # Symbols that must always be exported. include_expsyms=$lt_include_expsyms # ### END LIBTOOL CONFIG __EOF__ case $host_os in aix3*) cat <<\EOF >> "$cfgfile" # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. if test "X${COLLECT_NAMES+set}" != Xset; then COLLECT_NAMES= export COLLECT_NAMES fi EOF ;; esac # We use sed instead of cat because bash on DJGPP gets confused if # if finds mixed CR/LF and LF-only lines. Since sed operates in # text mode, it properly converts lines to CR/LF. This bash problem # is reportedly fixed, but why not run on old versions too? sed '$q' "$ltmain" >> "$cfgfile" || (rm -f "$cfgfile"; exit 1) mv -f "$cfgfile" "$ofile" || \ (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" else # If there is no Makefile yet, we rely on a make rule to execute # `config.status --recheck' to rerun these tests and create the # libtool script then. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` if test -f "$ltmain_in"; then test -f Makefile && make "$ltmain" fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC="$lt_save_CC" # Check whether --with-tags was given. if test "${with_tags+set}" = set; then withval=$with_tags; tagnames="$withval" fi if test -f "$ltmain" && test -n "$tagnames"; then if test ! -f "${ofile}"; then { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not exist" >&5 echo "$as_me: WARNING: output file \`$ofile' does not exist" >&2;} fi if test -z "$LTCC"; then eval "`$SHELL ${ofile} --config | grep '^LTCC='`" if test -z "$LTCC"; then { echo "$as_me:$LINENO: WARNING: output file \`$ofile' does not look like a libtool script" >&5 echo "$as_me: WARNING: output file \`$ofile' does not look like a libtool script" >&2;} else { echo "$as_me:$LINENO: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&5 echo "$as_me: WARNING: using \`LTCC=$LTCC', extracted from \`$ofile'" >&2;} fi fi if test -z "$LTCFLAGS"; then eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`" fi # Extract list of available tagged configurations in $ofile. # Note that this assumes the entire list is on one line. available_tags=`grep "^available_tags=" "${ofile}" | $SED -e 's/available_tags=\(.*$\)/\1/' -e 's/\"//g'` lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," for tagname in $tagnames; do IFS="$lt_save_ifs" # Check whether tagname contains only valid characters case `$echo "X$tagname" | $Xsed -e 's:[-_ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890,/]::g'` in "") ;; *) { { echo "$as_me:$LINENO: error: invalid tag name: $tagname" >&5 echo "$as_me: error: invalid tag name: $tagname" >&2;} { (exit 1); exit 1; }; } ;; esac if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "${ofile}" > /dev/null then { { echo "$as_me:$LINENO: error: tag name \"$tagname\" already exists" >&5 echo "$as_me: error: tag name \"$tagname\" already exists" >&2;} { (exit 1); exit 1; }; } fi # Update the list of available tags. if test -n "$tagname"; then echo appending configuration tag \"$tagname\" to $ofile case $tagname in CXX) if test -n "$CXX" && ( test "X$CXX" != "Xno" && ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || (test "X$CXX" != "Xg++"))) ; then ac_ext=cpp ac_cpp='$CXXCPP $CPPFLAGS' ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_cxx_compiler_gnu archive_cmds_need_lc_CXX=no allow_undefined_flag_CXX= always_export_symbols_CXX=no archive_expsym_cmds_CXX= export_dynamic_flag_spec_CXX= hardcode_direct_CXX=no hardcode_libdir_flag_spec_CXX= hardcode_libdir_flag_spec_ld_CXX= hardcode_libdir_separator_CXX= hardcode_minus_L_CXX=no hardcode_shlibpath_var_CXX=unsupported hardcode_automatic_CXX=no module_cmds_CXX= module_expsym_cmds_CXX= link_all_deplibs_CXX=unknown old_archive_cmds_CXX=$old_archive_cmds no_undefined_flag_CXX= whole_archive_flag_spec_CXX= enable_shared_with_static_runtimes_CXX=no # Dependencies to place before and after the object being linked: predep_objects_CXX= postdep_objects_CXX= predeps_CXX= postdeps_CXX= compiler_lib_search_path_CXX= compiler_lib_search_dirs_CXX= # Source file extension for C++ test sources. ac_ext=cpp # Object file extension for compiled C++ test sources. objext=o objext_CXX=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" # Code to be used in simple link tests lt_simple_link_test_code='int main(int, char *[]) { return(0); }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $rm conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $rm -r conftest* # Allow CC to be a program name with arguments. lt_save_CC=$CC lt_save_LD=$LD lt_save_GCC=$GCC GCC=$GXX lt_save_with_gnu_ld=$with_gnu_ld lt_save_path_LD=$lt_cv_path_LD if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx else $as_unset lt_cv_prog_gnu_ld fi if test -n "${lt_cv_path_LDCXX+set}"; then lt_cv_path_LD=$lt_cv_path_LDCXX else $as_unset lt_cv_path_LD fi test -z "${LDCXX+set}" || LD=$LDCXX CC=${CXX-"c++"} compiler=$CC compiler_CXX=$CC for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` # We don't want -fno-exception wen compiling C++ code, so set the # no_builtin_flag separately if test "$GXX" = yes; then lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' else lt_prog_compiler_no_builtin_flag_CXX= fi if test "$GXX" = yes; then # Set up default GNU C++ configuration # Check whether --with-gnu-ld was given. if test "${with_gnu_ld+set}" = set; then withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes else with_gnu_ld=no fi ac_prog=ld if test "$GCC" = yes; then # Check if gcc -print-prog-name=ld gives a path. { echo "$as_me:$LINENO: checking for ld used by $CC" >&5 echo $ECHO_N "checking for ld used by $CC... $ECHO_C" >&6; } case $host in *-*-mingw*) # gcc leaves a trailing carriage return which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; esac case $ac_prog in # Accept absolute paths. [\\/]* | ?:[\\/]*) re_direlt='/[^/][^/]*/\.\./' # Canonicalize the pathname of ld ac_prog=`echo $ac_prog| $SED 's%\\\\%/%g'` while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do ac_prog=`echo $ac_prog| $SED "s%$re_direlt%/%"` done test -z "$LD" && LD="$ac_prog" ;; "") # If it fails, then pretend we aren't using GCC. ac_prog=ld ;; *) # If it is relative, then search for the first ld in PATH. with_gnu_ld=unknown ;; esac elif test "$with_gnu_ld" = yes; then { echo "$as_me:$LINENO: checking for GNU ld" >&5 echo $ECHO_N "checking for GNU ld... $ECHO_C" >&6; } else { echo "$as_me:$LINENO: checking for non-GNU ld" >&5 echo $ECHO_N "checking for non-GNU ld... $ECHO_C" >&6; } fi if test "${lt_cv_path_LD+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -z "$LD"; then lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do IFS="$lt_save_ifs" test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then lt_cv_path_LD="$ac_dir/$ac_prog" # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 &5 echo "${ECHO_T}$LD" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -z "$LD" && { { echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5 echo "$as_me: error: no acceptable ld found in \$PATH" >&2;} { (exit 1); exit 1; }; } { echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5 echo $ECHO_N "checking if the linker ($LD) is GNU ld... $ECHO_C" >&6; } if test "${lt_cv_prog_gnu_ld+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # I'd rather use --version here, but apparently some GNU lds only accept -v. case `$LD -v 2>&1 &5 echo "${ECHO_T}$lt_cv_prog_gnu_ld" >&6; } with_gnu_ld=$lt_cv_prog_gnu_ld # Check if GNU C++ uses GNU ld as the underlying linker, since the # archiving commands below assume that GNU ld is being used. if test "$with_gnu_ld" = yes; then archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir' export_dynamic_flag_spec_CXX='${wl}--export-dynamic' # If archive_cmds runs LD, not CC, wlarc should be empty # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to # investigate it a little bit more. (MM) wlarc='${wl}' # ancient GNU ld didn't support --whole-archive et. al. if eval "`$CC -print-prog-name=ld` --help 2>&1" | \ grep 'no-whole-archive' > /dev/null; then whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else whole_archive_flag_spec_CXX= fi else with_gnu_ld=no wlarc= # A generic and very simple default shared library creation # command for GNU C++ for the case where it uses the native # linker, instead of GNU ld. If possible, this setting should # overridden to take advantage of the native linker features on # the platform it is being used on. archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' fi # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' else GXX=no with_gnu_ld=no wlarc= fi # PORTME: fill in a description of your system's C++ link characteristics { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; } ld_shlibs_CXX=yes case $host_os in aix3*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aix[4-9]*) if test "$host_cpu" = ia64; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag="" else aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # need to do runtime linking. case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do case $ld_flag in *-brtl*) aix_use_runtimelinking=yes break ;; esac done ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds_CXX='' hardcode_direct_CXX=yes hardcode_libdir_separator_CXX=':' link_all_deplibs_CXX=yes if test "$GXX" = yes; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`${CC} -print-prog-name=collect2` if test -f "$collect2name" && \ strings "$collect2name" | grep resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct_CXX=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L_CXX=yes hardcode_libdir_flag_spec_CXX='-L$libdir' hardcode_libdir_separator_CXX= fi ;; esac shared_flag='-shared' if test "$aix_use_runtimelinking" = yes; then shared_flag="$shared_flag "'${wl}-G' fi else # not using gcc if test "$host_cpu" = ia64; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test "$aix_use_runtimelinking" = yes; then shared_flag='${wl}-G' else shared_flag='${wl}-bM:SRE' fi fi fi # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols_CXX=yes if test "$aix_use_runtimelinking" = yes; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag_CXX='-berok' # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds_CXX="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" else if test "$host_cpu" = ia64; then hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib' allow_undefined_flag_CXX="-z nodefs" archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_cxx_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag_CXX=' ${wl}-bernotok' allow_undefined_flag_CXX=' ${wl}-berok' # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec_CXX='$convenience' archive_cmds_need_lc_CXX=yes # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; beos*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then allow_undefined_flag_CXX=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' else ld_shlibs_CXX=no fi ;; chorus*) case $cc_basename in *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; cygwin* | mingw* | pw32*) # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec_CXX='-L$libdir' allow_undefined_flag_CXX=unsupported always_export_symbols_CXX=no enable_shared_with_static_runtimes_CXX=yes if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file (1st line # is EXPORTS), use it as is; otherwise, prepend... archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs_CXX=no fi ;; darwin* | rhapsody*) archive_cmds_need_lc_CXX=no hardcode_direct_CXX=no hardcode_automatic_CXX=yes hardcode_shlibpath_var_CXX=unsupported whole_archive_flag_spec_CXX='' link_all_deplibs_CXX=yes allow_undefined_flag_CXX="$_lt_dar_allow_undefined" if test "$GXX" = yes ; then output_verbose_link_cmd='echo' archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" module_expsym_cmds_CXX="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" if test "$lt_cv_apple_cc_single_mod" != "yes"; then archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" fi else case $cc_basename in xlc*) output_verbose_link_cmd='echo' archive_cmds_CXX='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' module_cmds_CXX='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' module_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' ;; *) ld_shlibs_CXX=no ;; esac fi ;; dgux*) case $cc_basename in ec++*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; ghcx*) # Green Hills C++ Compiler # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; freebsd[12]*) # C++ shared libraries reported to be fairly broken before switch to ELF ld_shlibs_CXX=no ;; freebsd-elf*) archive_cmds_need_lc_CXX=no ;; freebsd* | dragonfly*) # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF # conventions ld_shlibs_CXX=yes ;; gnu*) ;; hpux9*) hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' hardcode_libdir_separator_CXX=: export_dynamic_flag_spec_CXX='${wl}-E' hardcode_direct_CXX=yes hardcode_minus_L_CXX=yes # Not in the search PATH, # but as the default # location of the library. case $cc_basename in CC*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aCC*) archive_cmds_CXX='$rm $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "[-]L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes; then archive_cmds_CXX='$rm $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; hpux10*|hpux11*) if test $with_gnu_ld = no; then hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' hardcode_libdir_separator_CXX=: case $host_cpu in hppa*64*|ia64*) ;; *) export_dynamic_flag_spec_CXX='${wl}-E' ;; esac fi case $host_cpu in hppa*64*|ia64*) hardcode_direct_CXX=no hardcode_shlibpath_var_CXX=no ;; *) hardcode_direct_CXX=yes hardcode_minus_L_CXX=yes # Not in the search PATH, # but as the default # location of the library. ;; esac case $cc_basename in CC*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; aCC*) case $host_cpu in hppa*64*) archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | grep "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes; then if test $with_gnu_ld = no; then case $host_cpu in hppa*64*) archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; interix[3-9]*) hardcode_direct_CXX=no hardcode_shlibpath_var_CXX=no hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' export_dynamic_flag_spec_CXX='${wl}-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in CC*) # SGI C++ archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' ;; *) if test "$GXX" = yes; then if test "$with_gnu_ld" = no; then archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` -o $lib' fi fi link_all_deplibs_CXX=yes ;; esac hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_CXX=: ;; linux* | k*bsd*-gnu) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | grep "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' hardcode_libdir_flag_spec_CXX='${wl}--rpath,$libdir' export_dynamic_flag_spec_CXX='${wl}--export-dynamic' # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; icpc*) # Intel C++ with_gnu_ld=yes # version 8.0 and above of icpc choke on multiply defined symbols # if we add $predep_objects and $postdep_objects, however 7.1 and # earlier do not add the objects themselves. case `$CC -V 2>&1` in *"Version 7."*) archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 8.0 or newer tmp_idyn= case $host_cpu in ia64*) tmp_idyn=' -i_dynamic';; esac archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' ;; esac archive_cmds_need_lc_CXX=no hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' export_dynamic_flag_spec_CXX='${wl}--export-dynamic' whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' ;; pgCC* | pgcpp*) # Portland Group C++ compiler archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir' export_dynamic_flag_spec_CXX='${wl}--export-dynamic' whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' ;; cxx*) # Compaq C++ archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec_CXX='-rpath $libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 no_undefined_flag_CXX=' -zdefs' archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' hardcode_libdir_flag_spec_CXX='-R$libdir' whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' # Not sure whether something based on # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 # would be better. output_verbose_link_cmd='echo' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' ;; esac ;; esac ;; lynxos*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; m88k*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; mvs*) case $cc_basename in cxx*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' wlarc= hardcode_libdir_flag_spec_CXX='-R$libdir' hardcode_direct_CXX=yes hardcode_shlibpath_var_CXX=no fi # Workaround some broken pre-1.5 toolchains output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' ;; openbsd2*) # C++ shared libraries are fairly broken ld_shlibs_CXX=no ;; openbsd*) if test -f /usr/libexec/ld.so; then hardcode_direct_CXX=yes hardcode_shlibpath_var_CXX=no archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' export_dynamic_flag_spec_CXX='${wl}-E' whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' fi output_verbose_link_cmd='echo' else ld_shlibs_CXX=no fi ;; osf3*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' hardcode_libdir_separator_CXX=: # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; cxx*) allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && echo ${wl}-set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes && test "$with_gnu_ld" = no; then allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; osf4* | osf5*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' hardcode_libdir_separator_CXX=: # Archives containing C++ object files must be created using # the KAI C++ compiler. old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; RCC*) # Rational C++ 2.4.1 # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; cxx*) allow_undefined_flag_CXX=' -expect_unresolved \*' archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ echo "-hidden">> $lib.exp~ $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname -Wl,-input -Wl,$lib.exp `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~ $rm $lib.exp' hardcode_libdir_flag_spec_CXX='-rpath $libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. # # There doesn't appear to be a way to prevent this compiler from # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld" | grep -v "ld:"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list' ;; *) if test "$GXX" = yes && test "$with_gnu_ld" = no; then allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_CXX=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "\-L"' else # FIXME: insert proper C++ library support ld_shlibs_CXX=no fi ;; esac ;; psos*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; lcc*) # Lucid # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; solaris*) case $cc_basename in CC*) # Sun C++ 4.2, 5.x and Centerline C++ archive_cmds_need_lc_CXX=yes no_undefined_flag_CXX=' -zdefs' archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' hardcode_libdir_flag_spec_CXX='-R$libdir' hardcode_shlibpath_var_CXX=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands `-z linker_flag'. # Supported since Solaris 2.6 (maybe 2.5.1?) whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' ;; esac link_all_deplibs_CXX=yes output_verbose_link_cmd='echo' # Archives containing C++ object files must be created using # "CC -xar", where "CC" is the Sun C++ compiler. This is # necessary to make sure instantiated templates are included # in the archive. old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' ;; gcx*) # Green Hills C++ Compiler archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' # The C++ compiler must be used to create the archive. old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' ;; *) # GNU C++ compiler with Solaris linker if test "$GXX" = yes && test "$with_gnu_ld" = no; then no_undefined_flag_CXX=' ${wl}-z ${wl}defs' if $CC --version | grep -v '^2\.7' > /dev/null; then archive_cmds_CXX='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd="$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" else # g++ 2.7 appears to require `-G' NOT `-shared' on this # platform. archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. output_verbose_link_cmd="$CC -G $CFLAGS -v conftest.$objext 2>&1 | grep \"\-L\"" fi hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir' case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' ;; esac fi ;; esac ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag_CXX='${wl}-z,text' archive_cmds_need_lc_CXX=no hardcode_shlibpath_var_CXX=no runpath_var='LD_RUN_PATH' case $cc_basename in CC*) archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We can NOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. # For security reasons, it is highly recommended that you always # use absolute paths for naming shared libraries, and exclude the # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. # So that behaviour is only enabled if SCOABSPATH is set to a # non-empty value in the environment. Most likely only useful for # creating official distributions of packages. # This is a hack until libtool officially supports absolute path # names for shared libraries. no_undefined_flag_CXX='${wl}-z,text' allow_undefined_flag_CXX='${wl}-z,nodefs' archive_cmds_need_lc_CXX=no hardcode_shlibpath_var_CXX=no hardcode_libdir_flag_spec_CXX='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' hardcode_libdir_separator_CXX=':' link_all_deplibs_CXX=yes export_dynamic_flag_spec_CXX='${wl}-Bexport' runpath_var='LD_RUN_PATH' case $cc_basename in CC*) archive_cmds_CXX='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_CXX='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac ;; vxworks*) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; *) # FIXME: insert proper C++ library support ld_shlibs_CXX=no ;; esac { echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5 echo "${ECHO_T}$ld_shlibs_CXX" >&6; } test "$ld_shlibs_CXX" = no && can_build_shared=no GCC_CXX="$GXX" LD_CXX="$LD" cat > conftest.$ac_ext <&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # Parse the compiler output and extract the necessary # objects, libraries and library flags. # Sentinel used to keep track of whether or not we are before # the conftest object file. pre_test_object_deps_done=no # The `*' in the case matches for architectures that use `case' in # $output_verbose_cmd can trigger glob expansion during the loop # eval without this substitution. output_verbose_link_cmd=`$echo "X$output_verbose_link_cmd" | $Xsed -e "$no_glob_subst"` for p in `eval $output_verbose_link_cmd`; do case $p in -L* | -R* | -l*) # Some compilers place space between "-{L,R}" and the path. # Remove the space. if test $p = "-L" \ || test $p = "-R"; then prev=$p continue else prev= fi if test "$pre_test_object_deps_done" = no; then case $p in -L* | -R*) # Internal compiler library paths should come after those # provided the user. The postdeps already come after the # user supplied libs so there is no need to process them. if test -z "$compiler_lib_search_path_CXX"; then compiler_lib_search_path_CXX="${prev}${p}" else compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}" fi ;; # The "-l" case would never come before the object being # linked, so don't bother handling this case. esac else if test -z "$postdeps_CXX"; then postdeps_CXX="${prev}${p}" else postdeps_CXX="${postdeps_CXX} ${prev}${p}" fi fi ;; *.$objext) # This assumes that the test object file only shows up # once in the compiler output. if test "$p" = "conftest.$objext"; then pre_test_object_deps_done=yes continue fi if test "$pre_test_object_deps_done" = no; then if test -z "$predep_objects_CXX"; then predep_objects_CXX="$p" else predep_objects_CXX="$predep_objects_CXX $p" fi else if test -z "$postdep_objects_CXX"; then postdep_objects_CXX="$p" else postdep_objects_CXX="$postdep_objects_CXX $p" fi fi ;; *) ;; # Ignore the rest. esac done # Clean up. rm -f a.out a.exe else echo "libtool.m4: error: problem compiling CXX test program" fi $rm -f confest.$objext compiler_lib_search_dirs_CXX= if test -n "$compiler_lib_search_path_CXX"; then compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` fi # PORTME: override above test on systems where it is broken case $host_os in interix[3-9]*) # Interix 3.5 installs completely hosed .la files for C++, so rather than # hack all around it, let's just trust "g++" to DTRT. predep_objects_CXX= postdep_objects_CXX= postdeps_CXX= ;; linux*) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 # # The more standards-conforming stlport4 library is # incompatible with the Cstd library. Avoid specifying # it if it's in CXXFLAGS. Ignore libCrun as # -library=stlport4 depends on it. case " $CXX $CXXFLAGS " in *" -library=stlport4 "*) solaris_use_stlport4=yes ;; esac if test "$solaris_use_stlport4" != yes; then postdeps_CXX='-library=Cstd -library=Crun' fi ;; esac ;; solaris*) case $cc_basename in CC*) # The more standards-conforming stlport4 library is # incompatible with the Cstd library. Avoid specifying # it if it's in CXXFLAGS. Ignore libCrun as # -library=stlport4 depends on it. case " $CXX $CXXFLAGS " in *" -library=stlport4 "*) solaris_use_stlport4=yes ;; esac # Adding this requires a known-good setup of shared libraries for # Sun compiler versions before 5.6, else PIC objects from an old # archive will be linked into the output, leading to subtle bugs. if test "$solaris_use_stlport4" != yes; then postdeps_CXX='-library=Cstd -library=Crun' fi ;; esac ;; esac case " $postdeps_CXX " in *" -lc "*) archive_cmds_need_lc_CXX=no ;; esac lt_prog_compiler_wl_CXX= lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX= { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; } # C++ specific cases for pic, static, wl, etc. if test "$GXX" = yes; then lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='-static' case $host_os in aix*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_CXX='-Bstatic' fi ;; amigaos*) # FIXME: we need at least 68020 code to build shared libraries, but # adding the `-m68020' flag to GCC prevents building anything better, # like `-m68040'. lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | os2* | pw32*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic_CXX='-DDLL_EXPORT' ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic_CXX='-fno-common' ;; *djgpp*) # DJGPP does not support shared libraries at all lt_prog_compiler_pic_CXX= ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic_CXX=-Kconform_pic fi ;; hpux*) # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) ;; *) lt_prog_compiler_pic_CXX='-fPIC' ;; esac ;; *) lt_prog_compiler_pic_CXX='-fPIC' ;; esac else case $host_os in aix[4-9]*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_CXX='-Bstatic' else lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' fi ;; chorus*) case $cc_basename in cxch68*) # Green Hills C++ Compiler # _LT_AC_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" ;; esac ;; darwin*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files case $cc_basename in xlc*) lt_prog_compiler_pic_CXX='-qnocommon' lt_prog_compiler_wl_CXX='-Wl,' ;; esac ;; dgux*) case $cc_basename in ec++*) lt_prog_compiler_pic_CXX='-KPIC' ;; ghcx*) # Green Hills C++ Compiler lt_prog_compiler_pic_CXX='-pic' ;; *) ;; esac ;; freebsd* | dragonfly*) # FreeBSD uses GNU C++ ;; hpux9* | hpux10* | hpux11*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' if test "$host_cpu" != ia64; then lt_prog_compiler_pic_CXX='+Z' fi ;; aCC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_CXX='+Z' ;; esac ;; *) ;; esac ;; interix*) # This is c89, which is MS Visual C++ (no shared libs) # Anyone wants to do a port? ;; irix5* | irix6* | nonstopux*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_static_CXX='-non_shared' # CC pic flag -KPIC is the default. ;; *) ;; esac ;; linux* | k*bsd*-gnu) case $cc_basename in KCC*) # KAI C++ Compiler lt_prog_compiler_wl_CXX='--backend -Wl,' lt_prog_compiler_pic_CXX='-fPIC' ;; icpc* | ecpc*) # Intel C++ lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-static' ;; pgCC* | pgcpp*) # Portland Group C++ compiler. lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-fpic' lt_prog_compiler_static_CXX='-Bstatic' ;; cxx*) # Compaq C++ # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX='-non_shared' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C++ 5.9 lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' lt_prog_compiler_wl_CXX='-Qoption ld ' ;; esac ;; esac ;; lynxos*) ;; m88k*) ;; mvs*) case $cc_basename in cxx*) lt_prog_compiler_pic_CXX='-W c,exportall' ;; *) ;; esac ;; netbsd* | netbsdelf*-gnu) ;; osf3* | osf4* | osf5*) case $cc_basename in KCC*) lt_prog_compiler_wl_CXX='--backend -Wl,' ;; RCC*) # Rational C++ 2.4.1 lt_prog_compiler_pic_CXX='-pic' ;; cxx*) # Digital/Compaq C++ lt_prog_compiler_wl_CXX='-Wl,' # Make sure the PIC flag is empty. It appears that all Alpha # Linux and Compaq Tru64 Unix objects are PIC. lt_prog_compiler_pic_CXX= lt_prog_compiler_static_CXX='-non_shared' ;; *) ;; esac ;; psos*) ;; solaris*) case $cc_basename in CC*) # Sun C++ 4.2, 5.x and Centerline C++ lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' lt_prog_compiler_wl_CXX='-Qoption ld ' ;; gcx*) # Green Hills C++ Compiler lt_prog_compiler_pic_CXX='-PIC' ;; *) ;; esac ;; sunos4*) case $cc_basename in CC*) # Sun C++ 4.x lt_prog_compiler_pic_CXX='-pic' lt_prog_compiler_static_CXX='-Bstatic' ;; lcc*) # Lucid lt_prog_compiler_pic_CXX='-pic' ;; *) ;; esac ;; tandem*) case $cc_basename in NCC*) # NonStop-UX NCC 3.20 lt_prog_compiler_pic_CXX='-KPIC' ;; *) ;; esac ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) case $cc_basename in CC*) lt_prog_compiler_wl_CXX='-Wl,' lt_prog_compiler_pic_CXX='-KPIC' lt_prog_compiler_static_CXX='-Bstatic' ;; esac ;; vxworks*) ;; *) lt_prog_compiler_can_build_shared_CXX=no ;; esac fi { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_CXX" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_CXX" >&6; } # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic_CXX"; then { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_pic_works_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_pic_works_CXX=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:12634: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:12638: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works_CXX=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_pic_works_CXX" >&6; } if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then case $lt_prog_compiler_pic_CXX in "" | " "*) ;; *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; esac else lt_prog_compiler_pic_CXX= lt_prog_compiler_can_build_shared_CXX=no fi fi case $host_os in # For platforms which do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic_CXX= ;; *) lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" ;; esac # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_static_works_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_static_works_CXX=no save_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works_CXX=yes fi else lt_cv_prog_compiler_static_works_CXX=yes fi fi $rm -r conftest* LDFLAGS="$save_LDFLAGS" fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works_CXX" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_static_works_CXX" >&6; } if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then : else lt_prog_compiler_static_CXX= fi { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_c_o_CXX+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o_CXX=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:12738: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:12742: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o_CXX=yes fi fi chmod u+w . 2>&5 $rm conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files $rm out/* && rmdir out cd .. rmdir conftest $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_CXX" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_CXX" >&6; } hard_links="nottested" if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then # do not overwrite the value of need_locks provided by the user { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; } hard_links=yes $rm conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6; } if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; } export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' case $host_os in aix[4-9]*) # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to AIX nm, but means don't demangle with GNU nm if $NM -V 2>&1 | grep 'GNU' > /dev/null; then export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' else export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' fi ;; pw32*) export_symbols_cmds_CXX="$ltdll_cmds" ;; cygwin* | mingw*) export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;/^.*[ ]__nm__/s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' ;; linux* | k*bsd*-gnu) link_all_deplibs_CXX=no ;; *) export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; esac exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' { echo "$as_me:$LINENO: result: $ld_shlibs_CXX" >&5 echo "${ECHO_T}$ld_shlibs_CXX" >&6; } test "$ld_shlibs_CXX" = no && can_build_shared=no # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc_CXX" in x|xyes) # Assume -lc should be added archive_cmds_need_lc_CXX=yes if test "$enable_shared" = yes && test "$GCC" = yes; then case $archive_cmds_CXX in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; } $rm conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl_CXX pic_flag=$lt_prog_compiler_pic_CXX compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag_CXX allow_undefined_flag_CXX= if { (eval echo "$as_me:$LINENO: \"$archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 (eval $archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } then archive_cmds_need_lc_CXX=no else archive_cmds_need_lc_CXX=yes fi allow_undefined_flag_CXX=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $rm conftest* { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_CXX" >&5 echo "${ECHO_T}$archive_cmds_need_lc_CXX" >&6; } ;; esac fi ;; esac { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; } library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=".so" postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='${libname}${release}${shared_ext}$major' ;; aix[4-9]*) version_type=linux need_lib_prefix=no need_version=no hardcode_into_libs=yes if test "$host_cpu" = ia64; then # AIX 5 supports IA64 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line `#! .'. This would cause the generated library to # depend on `.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then : else can_build_shared=no fi ;; esac # AIX (on Power*) has no versioning support, so currently we can not hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. if test "$aix_use_runtimelinking" = yes; then # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' else # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='${libname}${release}.a $libname.a' soname_spec='${libname}${release}${shared_ext}$major' fi shlibpath_var=LIBPATH fi ;; amigaos*) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; beos*) library_names_spec='${libname}${shared_ext}' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32*) version_type=windows shrext_cmds=".dll" need_version=no need_lib_prefix=no case $GCC,$host_os in yes,cygwin* | yes,mingw* | yes,pw32*) library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \${file}`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" ;; mingw*) # MinGW DLLs use traditional 'lib' prefix soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH printed by # mingw gcc, but we are running on Cygwin. Gcc prints its search # path with ; separators, and with drive letters. We can handle the # drive letters (cygwin fileutils understands them), so leave them, # especially as we might pass files found there to a mingw objdump, # which wouldn't understand a cygwinified path. Ahh. sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' ;; esac ;; *) library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' ;; esac dynamic_linker='Win32 ld.exe' # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' soname_spec='${libname}${release}${major}$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd1*) dynamic_linker=no ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[123]*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; gnu*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' if test "X$HPUX_IA64_MODE" = X32; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" fi sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555. postinstall_cmds='chmod 555 $lib' ;; interix[3-9]*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test "$lt_cv_prog_gnu_ld" = yes; then version_type=linux else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. linux* | k*bsd*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Append ld.so.conf contents to the search path if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsdelf*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; nto-qnx*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; openbsd*) version_type=sunos sys_lib_dlsearch_path_spec="/usr/lib" need_lib_prefix=no # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. case $host_os in openbsd3.3 | openbsd3.3.*) need_version=yes ;; *) need_version=no ;; esac library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then case $host_os in openbsd2.[89] | openbsd2.[89].*) shlibpath_overrides_runpath=no ;; *) shlibpath_overrides_runpath=yes ;; esac else shlibpath_overrides_runpath=yes fi ;; os2*) libname_spec='$name' shrext_cmds=".dll" need_lib_prefix=no library_names_spec='$libname${shared_ext} $libname.a' dynamic_linker='OS/2 ld.exe' shlibpath_var=LIBPATH ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test "$with_gnu_ld" = yes; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no export_dynamic_flag_spec='${wl}-Blargedynsym' runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec ;then version_type=linux library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' soname_spec='$libname${shared_ext}.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=freebsd-elf need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes if test "$with_gnu_ld" = yes; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' shlibpath_overrides_runpath=no else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' shlibpath_overrides_runpath=yes case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; uts4*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6; } test "$dynamic_linker" = no && can_build_shared=no if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" fi sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" fi sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test "$GCC" = yes; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; } hardcode_action_CXX= if test -n "$hardcode_libdir_flag_spec_CXX" || \ test -n "$runpath_var_CXX" || \ test "X$hardcode_automatic_CXX" = "Xyes" ; then # We can hardcode non-existant directories. if test "$hardcode_direct_CXX" != no && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, CXX)" != no && test "$hardcode_minus_L_CXX" != no; then # Linking always hardcodes the temporary library directory. hardcode_action_CXX=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action_CXX=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action_CXX=unsupported fi { echo "$as_me:$LINENO: result: $hardcode_action_CXX" >&5 echo "${ECHO_T}$hardcode_action_CXX" >&6; } if test "$hardcode_action_CXX" = relink; then # Fast installation is not supported enable_fast_install=no elif test "$shlibpath_overrides_runpath" = yes || test "$enable_shared" = no; then # Fast installation is not necessary enable_fast_install=needless fi # The else clause should only fire when bootstrapping the # libtool distribution, otherwise you forgot to ship ltmain.sh # with your package, and you will get complaints that there are # no rules to generate ltmain.sh. if test -f "$ltmain"; then # See if we are running on zsh, and set the options which allow our commands through # without removal of \ escapes. if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi # Now quote all the things that may contain metacharacters while being # careful not to overquote the AC_SUBSTed values. We take copies of the # variables and quote the copies for generation of the libtool script. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ SED SHELL STRIP \ libname_spec library_names_spec soname_spec extract_expsyms_cmds \ old_striplib striplib file_magic_cmd finish_cmds finish_eval \ deplibs_check_method reload_flag reload_cmds need_locks \ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_c_name_address \ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ old_postinstall_cmds old_postuninstall_cmds \ compiler_CXX \ CC_CXX \ LD_CXX \ lt_prog_compiler_wl_CXX \ lt_prog_compiler_pic_CXX \ lt_prog_compiler_static_CXX \ lt_prog_compiler_no_builtin_flag_CXX \ export_dynamic_flag_spec_CXX \ thread_safe_flag_spec_CXX \ whole_archive_flag_spec_CXX \ enable_shared_with_static_runtimes_CXX \ old_archive_cmds_CXX \ old_archive_from_new_cmds_CXX \ predep_objects_CXX \ postdep_objects_CXX \ predeps_CXX \ postdeps_CXX \ compiler_lib_search_path_CXX \ compiler_lib_search_dirs_CXX \ archive_cmds_CXX \ archive_expsym_cmds_CXX \ postinstall_cmds_CXX \ postuninstall_cmds_CXX \ old_archive_from_expsyms_cmds_CXX \ allow_undefined_flag_CXX \ no_undefined_flag_CXX \ export_symbols_cmds_CXX \ hardcode_libdir_flag_spec_CXX \ hardcode_libdir_flag_spec_ld_CXX \ hardcode_libdir_separator_CXX \ hardcode_automatic_CXX \ module_cmds_CXX \ module_expsym_cmds_CXX \ lt_cv_prog_compiler_c_o_CXX \ fix_srcfile_path_CXX \ exclude_expsyms_CXX \ include_expsyms_CXX; do case $var in old_archive_cmds_CXX | \ old_archive_from_new_cmds_CXX | \ archive_cmds_CXX | \ archive_expsym_cmds_CXX | \ module_cmds_CXX | \ module_expsym_cmds_CXX | \ old_archive_from_expsyms_cmds_CXX | \ export_symbols_cmds_CXX | \ extract_expsyms_cmds | reload_cmds | finish_cmds | \ postinstall_cmds | postuninstall_cmds | \ old_postinstall_cmds | old_postuninstall_cmds | \ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) # Double-quote double-evaled strings. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" ;; *) eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; esac done case $lt_echo in *'\$0 --fallback-echo"') lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` ;; esac cfgfile="$ofile" cat <<__EOF__ >> "$cfgfile" # ### BEGIN LIBTOOL TAG CONFIG: $tagname # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc_CXX # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # An echo program that does not interpret backslashes. echo=$lt_echo # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A C compiler. LTCC=$lt_LTCC # LTCC compiler flags. LTCFLAGS=$lt_LTCFLAGS # A language-specific compiler. CC=$lt_compiler_CXX # Is the compiler the GNU C compiler? with_gcc=$GCC_CXX # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD_CXX # Whether we need hard or soft links. LN_S=$lt_LN_S # A BSD-compatible nm program. NM=$lt_NM # A symbol stripping program STRIP=$lt_STRIP # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL" # Used on cygwin: object dumper. OBJDUMP="$OBJDUMP" # Used on cygwin: assembler. AS="$AS" # The name of the directory that contains temporary libtool files. objdir=$objdir # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl_CXX # Object file suffix (normally "o"). objext="$ac_objext" # Old archive suffix (normally "a"). libext="$libext" # Shared library suffix (normally ".so"). shrext_cmds='$shrext_cmds' # Executable file suffix (normally ""). exeext="$exeext" # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic_CXX pic_mode=$pic_mode # What is the maximum length of a command? max_cmd_len=$lt_cv_sys_max_cmd_len # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX # Must we lock files when doing compilation? need_locks=$lt_need_locks # Do we need the lib prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static_CXX # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec_CXX # Library versioning type. version_type=$version_type # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Commands used to build and install an old-style archive. RANLIB=$lt_RANLIB old_archive_cmds=$lt_old_archive_cmds_CXX old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX # Commands used to build and install a shared archive. archive_cmds=$lt_archive_cmds_CXX archive_expsym_cmds=$lt_archive_expsym_cmds_CXX postinstall_cmds=$lt_postinstall_cmds postuninstall_cmds=$lt_postuninstall_cmds # Commands used to build a loadable module (assumed same as above if empty) module_cmds=$lt_module_cmds_CXX module_expsym_cmds=$lt_module_expsym_cmds_CXX # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_predep_objects_CXX # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects_CXX # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps_CXX # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_CXX # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_CXX # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method == file_magic. file_magic_cmd=$lt_file_magic_cmd # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag_CXX # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_CXX # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # Same as above, but a single script fragment to be evaled but not shown. finish_eval=$lt_finish_eval # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm in a C name address pair global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # This is the shared library runtime path variable. runpath_var=$runpath_var # This is the shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action_CXX # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist. hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX # If ld is used when linking, flag to hardcode \$libdir into # a binary during linking. This must work even if \$libdir does # not exist. hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct_CXX # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L_CXX # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=$hardcode_automatic_CXX # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="$variables_saved_for_relink" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs_CXX # Compile-time system search path for libraries sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Run-time system search path for libraries sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec # Fix the shell variable \$srcfile for the compiler. fix_srcfile_path=$lt_fix_srcfile_path # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols_CXX # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds_CXX # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms_CXX # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_CXX # ### END LIBTOOL TAG CONFIG: $tagname __EOF__ else # If there is no Makefile yet, we rely on a make rule to execute # `config.status --recheck' to rerun these tests and create the # libtool script then. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` if test -f "$ltmain_in"; then test -f Makefile && make "$ltmain" fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC=$lt_save_CC LDCXX=$LD LD=$lt_save_LD GCC=$lt_save_GCC with_gnu_ldcxx=$with_gnu_ld with_gnu_ld=$lt_save_with_gnu_ld lt_cv_path_LDCXX=$lt_cv_path_LD lt_cv_path_LD=$lt_save_path_LD lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld else tagname="" fi ;; F77) if test -n "$F77" && test "X$F77" != "Xno"; then ac_ext=f ac_compile='$F77 -c $FFLAGS conftest.$ac_ext >&5' ac_link='$F77 -o conftest$ac_exeext $FFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_f77_compiler_gnu archive_cmds_need_lc_F77=no allow_undefined_flag_F77= always_export_symbols_F77=no archive_expsym_cmds_F77= export_dynamic_flag_spec_F77= hardcode_direct_F77=no hardcode_libdir_flag_spec_F77= hardcode_libdir_flag_spec_ld_F77= hardcode_libdir_separator_F77= hardcode_minus_L_F77=no hardcode_automatic_F77=no module_cmds_F77= module_expsym_cmds_F77= link_all_deplibs_F77=unknown old_archive_cmds_F77=$old_archive_cmds no_undefined_flag_F77= whole_archive_flag_spec_F77= enable_shared_with_static_runtimes_F77=no # Source file extension for f77 test sources. ac_ext=f # Object file extension for compiled f77 test sources. objext=o objext_F77=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t return end " # Code to be used in simple link tests lt_simple_link_test_code="\ program t end " # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $rm conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $rm -r conftest* # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${F77-"f77"} compiler=$CC compiler_F77=$CC for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` { echo "$as_me:$LINENO: checking if libtool supports shared libraries" >&5 echo $ECHO_N "checking if libtool supports shared libraries... $ECHO_C" >&6; } { echo "$as_me:$LINENO: result: $can_build_shared" >&5 echo "${ECHO_T}$can_build_shared" >&6; } { echo "$as_me:$LINENO: checking whether to build shared libraries" >&5 echo $ECHO_N "checking whether to build shared libraries... $ECHO_C" >&6; } test "$can_build_shared" = "no" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) test "$enable_shared" = yes && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[4-9]*) if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then test "$enable_shared" = yes && enable_static=no fi ;; esac { echo "$as_me:$LINENO: result: $enable_shared" >&5 echo "${ECHO_T}$enable_shared" >&6; } { echo "$as_me:$LINENO: checking whether to build static libraries" >&5 echo $ECHO_N "checking whether to build static libraries... $ECHO_C" >&6; } # Make sure either enable_shared or enable_static is yes. test "$enable_shared" = yes || enable_static=yes { echo "$as_me:$LINENO: result: $enable_static" >&5 echo "${ECHO_T}$enable_static" >&6; } GCC_F77="$G77" LD_F77="$LD" lt_prog_compiler_wl_F77= lt_prog_compiler_pic_F77= lt_prog_compiler_static_F77= { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; } if test "$GCC" = yes; then lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_static_F77='-static' case $host_os in aix*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_F77='-Bstatic' fi ;; amigaos*) # FIXME: we need at least 68020 code to build shared libraries, but # adding the `-m68020' flag to GCC prevents building anything better, # like `-m68040'. lt_prog_compiler_pic_F77='-m68020 -resident32 -malways-restore-a4' ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries lt_prog_compiler_pic_F77='-DDLL_EXPORT' ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic_F77='-fno-common' ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. lt_prog_compiler_can_build_shared_F77=no enable_shared=no ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic_F77=-Kconform_pic fi ;; hpux*) # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_F77='-fPIC' ;; esac ;; *) lt_prog_compiler_pic_F77='-fPIC' ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) lt_prog_compiler_wl_F77='-Wl,' if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_F77='-Bstatic' else lt_prog_compiler_static_F77='-bnso -bI:/lib/syscalls.exp' fi ;; darwin*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files case $cc_basename in xlc*) lt_prog_compiler_pic_F77='-qnocommon' lt_prog_compiler_wl_F77='-Wl,' ;; esac ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). lt_prog_compiler_pic_F77='-DDLL_EXPORT' ;; hpux9* | hpux10* | hpux11*) lt_prog_compiler_wl_F77='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_F77='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? lt_prog_compiler_static_F77='${wl}-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) lt_prog_compiler_wl_F77='-Wl,' # PIC (with -KPIC) is the default. lt_prog_compiler_static_F77='-non_shared' ;; newsos6) lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' ;; linux* | k*bsd*-gnu) case $cc_basename in icc* | ecc*) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-static' ;; pgcc* | pgf77* | pgf90* | pgf95*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_pic_F77='-fpic' lt_prog_compiler_static_F77='-Bstatic' ;; ccc*) lt_prog_compiler_wl_F77='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static_F77='-non_shared' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' lt_prog_compiler_wl_F77='-Wl,' ;; *Sun\ F*) # Sun Fortran 8.3 passes all unrecognized flags to the linker lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' lt_prog_compiler_wl_F77='' ;; esac ;; esac ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl_F77='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static_F77='-non_shared' ;; rdos*) lt_prog_compiler_static_F77='-non_shared' ;; solaris*) lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' case $cc_basename in f77* | f90* | f95*) lt_prog_compiler_wl_F77='-Qoption ld ';; *) lt_prog_compiler_wl_F77='-Wl,';; esac ;; sunos4*) lt_prog_compiler_wl_F77='-Qoption ld ' lt_prog_compiler_pic_F77='-PIC' lt_prog_compiler_static_F77='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec ;then lt_prog_compiler_pic_F77='-Kconform_pic' lt_prog_compiler_static_F77='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_pic_F77='-KPIC' lt_prog_compiler_static_F77='-Bstatic' ;; unicos*) lt_prog_compiler_wl_F77='-Wl,' lt_prog_compiler_can_build_shared_F77=no ;; uts4*) lt_prog_compiler_pic_F77='-pic' lt_prog_compiler_static_F77='-Bstatic' ;; *) lt_prog_compiler_can_build_shared_F77=no ;; esac fi { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_F77" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_F77" >&6; } # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic_F77"; then { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_F77 works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_pic_works_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_pic_works_F77=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic_F77" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:14336: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:14340: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works_F77=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works_F77" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_pic_works_F77" >&6; } if test x"$lt_cv_prog_compiler_pic_works_F77" = xyes; then case $lt_prog_compiler_pic_F77 in "" | " "*) ;; *) lt_prog_compiler_pic_F77=" $lt_prog_compiler_pic_F77" ;; esac else lt_prog_compiler_pic_F77= lt_prog_compiler_can_build_shared_F77=no fi fi case $host_os in # For platforms which do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic_F77= ;; *) lt_prog_compiler_pic_F77="$lt_prog_compiler_pic_F77" ;; esac # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl_F77 eval lt_tmp_static_flag=\"$lt_prog_compiler_static_F77\" { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_static_works_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_static_works_F77=no save_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works_F77=yes fi else lt_cv_prog_compiler_static_works_F77=yes fi fi $rm -r conftest* LDFLAGS="$save_LDFLAGS" fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works_F77" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_static_works_F77" >&6; } if test x"$lt_cv_prog_compiler_static_works_F77" = xyes; then : else lt_prog_compiler_static_F77= fi { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_c_o_F77+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o_F77=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:14440: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:14444: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o_F77=yes fi fi chmod u+w . 2>&5 $rm conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files $rm out/* && rmdir out cd .. rmdir conftest $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_F77" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_F77" >&6; } hard_links="nottested" if test "$lt_cv_prog_compiler_c_o_F77" = no && test "$need_locks" != no; then # do not overwrite the value of need_locks provided by the user { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; } hard_links=yes $rm conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6; } if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; } runpath_var= allow_undefined_flag_F77= enable_shared_with_static_runtimes_F77=no archive_cmds_F77= archive_expsym_cmds_F77= old_archive_From_new_cmds_F77= old_archive_from_expsyms_cmds_F77= export_dynamic_flag_spec_F77= whole_archive_flag_spec_F77= thread_safe_flag_spec_F77= hardcode_libdir_flag_spec_F77= hardcode_libdir_flag_spec_ld_F77= hardcode_libdir_separator_F77= hardcode_direct_F77=no hardcode_minus_L_F77=no hardcode_shlibpath_var_F77=unsupported link_all_deplibs_F77=unknown hardcode_automatic_F77=no module_cmds_F77= module_expsym_cmds_F77= always_export_symbols_F77=no export_symbols_cmds_F77='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list include_expsyms_F77= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ` (' and `)$', so one must not match beginning or # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', # as well as any symbol that contains `d'. exclude_expsyms_F77='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. extract_expsyms_cmds= # Just being paranoid about ensuring that cc_basename is set. for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` case $host_os in cygwin* | mingw* | pw32*) # FIXME: the MSVC++ port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++. if test "$GCC" != yes; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++) with_gnu_ld=yes ;; openbsd*) with_gnu_ld=no ;; esac ld_shlibs_F77=yes if test "$with_gnu_ld" = yes; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='${wl}' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec_F77='${wl}--rpath ${wl}$libdir' export_dynamic_flag_spec_F77='${wl}--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then whole_archive_flag_spec_F77="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else whole_archive_flag_spec_F77= fi supports_anon_versioning=no case `$LD -v 2>/dev/null` in *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[3-9]*) # On AIX/PPC, the GNU linker is very broken if test "$host_cpu" != ia64; then ld_shlibs_F77=no cat <&2 *** Warning: the GNU linker, at least up to release 2.9.1, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to modify your PATH *** so that a non-GNU linker is found, and then restart. EOF fi ;; amigaos*) archive_cmds_F77='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_minus_L_F77=yes # Samuel A. Falvo II reports # that the semantics of dynamic libraries on AmigaOS, at least up # to version 4, is to share data among multiple programs linked # with the same dynamic library. Since this doesn't match the # behavior of shared libraries on other platforms, we can't use # them. ld_shlibs_F77=no ;; beos*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then allow_undefined_flag_F77=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds_F77='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' else ld_shlibs_F77=no fi ;; cygwin* | mingw* | pw32*) # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, F77) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec_F77='-L$libdir' allow_undefined_flag_F77=unsupported always_export_symbols_F77=no enable_shared_with_static_runtimes_F77=yes export_symbols_cmds_F77='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file (1st line # is EXPORTS), use it as is; otherwise, prepend... archive_expsym_cmds_F77='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs_F77=no fi ;; interix[3-9]*) hardcode_direct_F77=no hardcode_shlibpath_var_F77=no hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir' export_dynamic_flag_spec_F77='${wl}-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds_F77='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds_F77='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | k*bsd*-gnu) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then tmp_addflag= case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers whole_archive_flag_spec_F77='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; esac case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 whole_archive_flag_spec_F77='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; *) tmp_sharedflag='-shared' ;; esac archive_cmds_F77='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' if test $supports_anon_versioning = yes; then archive_expsym_cmds_F77='$echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ $echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' fi link_all_deplibs_F77=no else ld_shlibs_F77=no fi ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds_F77='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then ld_shlibs_F77=no cat <&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. EOF elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs_F77=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) ld_shlibs_F77=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then hardcode_libdir_flag_spec_F77='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' else ld_shlibs_F77=no fi ;; esac ;; sunos4*) archive_cmds_F77='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct_F77=yes hardcode_shlibpath_var_F77=no ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs_F77=no fi ;; esac if test "$ld_shlibs_F77" = no; then runpath_var= hardcode_libdir_flag_spec_F77= export_dynamic_flag_spec_F77= whole_archive_flag_spec_F77= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) allow_undefined_flag_F77=unsupported always_export_symbols_F77=yes archive_expsym_cmds_F77='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. hardcode_minus_L_F77=yes if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct_F77=unsupported fi ;; aix[4-9]*) if test "$host_cpu" = ia64; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag="" else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to AIX nm, but means don't demangle with GNU nm if $NM -V 2>&1 | grep 'GNU' > /dev/null; then export_symbols_cmds_F77='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' else export_symbols_cmds_F77='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # need to do runtime linking. case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then aix_use_runtimelinking=yes break fi done ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds_F77='' hardcode_direct_F77=yes hardcode_libdir_separator_F77=':' link_all_deplibs_F77=yes if test "$GCC" = yes; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`${CC} -print-prog-name=collect2` if test -f "$collect2name" && \ strings "$collect2name" | grep resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct_F77=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L_F77=yes hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_libdir_separator_F77= fi ;; esac shared_flag='-shared' if test "$aix_use_runtimelinking" = yes; then shared_flag="$shared_flag "'${wl}-G' fi else # not using gcc if test "$host_cpu" = ia64; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test "$aix_use_runtimelinking" = yes; then shared_flag='${wl}-G' else shared_flag='${wl}-bM:SRE' fi fi fi # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols_F77=yes if test "$aix_use_runtimelinking" = yes; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag_F77='-berok' # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF program main end _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_f77_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_F77='${wl}-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds_F77="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" else if test "$host_cpu" = ia64; then hardcode_libdir_flag_spec_F77='${wl}-R $libdir:/usr/lib:/lib' allow_undefined_flag_F77="-z nodefs" archive_expsym_cmds_F77="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF program main end _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_f77_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_F77='${wl}-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag_F77=' ${wl}-bernotok' allow_undefined_flag_F77=' ${wl}-berok' # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec_F77='$convenience' archive_cmds_need_lc_F77=yes # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds_F77="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; amigaos*) archive_cmds_F77='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_minus_L_F77=yes # see comment about different semantics on the GNU ld section ld_shlibs_F77=no ;; bsdi[45]*) export_dynamic_flag_spec_F77=-rdynamic ;; cygwin* | mingw* | pw32*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. hardcode_libdir_flag_spec_F77=' ' allow_undefined_flag_F77=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=".dll" # FIXME: Setting linknames here is a bad hack. archive_cmds_F77='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. old_archive_From_new_cmds_F77='true' # FIXME: Should let the user specify the lib program. old_archive_cmds_F77='lib -OUT:$oldlib$oldobjs$old_deplibs' fix_srcfile_path_F77='`cygpath -w "$srcfile"`' enable_shared_with_static_runtimes_F77=yes ;; darwin* | rhapsody*) case $host_os in rhapsody* | darwin1.[012]) allow_undefined_flag_F77='${wl}-undefined ${wl}suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then allow_undefined_flag_F77='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[012]) allow_undefined_flag_F77='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 10.*) allow_undefined_flag_F77='${wl}-undefined ${wl}dynamic_lookup' ;; esac fi ;; esac archive_cmds_need_lc_F77=no hardcode_direct_F77=no hardcode_automatic_F77=yes hardcode_shlibpath_var_F77=unsupported whole_archive_flag_spec_F77='' link_all_deplibs_F77=yes if test "$GCC" = yes ; then output_verbose_link_cmd='echo' archive_cmds_F77="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" module_cmds_F77="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" archive_expsym_cmds_F77="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" module_expsym_cmds_F77="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" else case $cc_basename in xlc*) output_verbose_link_cmd='echo' archive_cmds_F77='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' module_cmds_F77='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds archive_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' module_expsym_cmds_F77='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' ;; *) ld_shlibs_F77=no ;; esac fi ;; dgux*) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_shlibpath_var_F77=no ;; freebsd1*) ld_shlibs_F77=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' hardcode_libdir_flag_spec_F77='-R$libdir' hardcode_direct_F77=yes hardcode_shlibpath_var_F77=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2*) archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_F77=yes hardcode_minus_L_F77=yes hardcode_shlibpath_var_F77=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly*) archive_cmds_F77='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec_F77='-R$libdir' hardcode_direct_F77=yes hardcode_shlibpath_var_F77=no ;; hpux9*) if test "$GCC" = yes; then archive_cmds_F77='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' else archive_cmds_F77='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' fi hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir' hardcode_libdir_separator_F77=: hardcode_direct_F77=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_F77=yes export_dynamic_flag_spec_F77='${wl}-E' ;; hpux10*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then archive_cmds_F77='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_F77='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir' hardcode_libdir_separator_F77=: hardcode_direct_F77=yes export_dynamic_flag_spec_F77='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_F77=yes fi ;; hpux11*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then case $host_cpu in hppa*64*) archive_cmds_F77='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds_F77='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_F77='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_F77='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec_F77='${wl}+b ${wl}$libdir' hardcode_libdir_separator_F77=: case $host_cpu in hppa*64*|ia64*) hardcode_libdir_flag_spec_ld_F77='+b $libdir' hardcode_direct_F77=no hardcode_shlibpath_var_F77=no ;; *) hardcode_direct_F77=yes export_dynamic_flag_spec_F77='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_F77=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test "$GCC" = yes; then archive_cmds_F77='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else archive_cmds_F77='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_ld_F77='-rpath $libdir' fi hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_F77=: link_all_deplibs_F77=yes ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else archive_cmds_F77='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi hardcode_libdir_flag_spec_F77='-R$libdir' hardcode_direct_F77=yes hardcode_shlibpath_var_F77=no ;; newsos6) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_F77=yes hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_F77=: hardcode_shlibpath_var_F77=no ;; openbsd*) if test -f /usr/libexec/ld.so; then hardcode_direct_F77=yes hardcode_shlibpath_var_F77=no if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir' export_dynamic_flag_spec_F77='${wl}-E' else case $host_os in openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) archive_cmds_F77='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_F77='-R$libdir' ;; *) archive_cmds_F77='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec_F77='${wl}-rpath,$libdir' ;; esac fi else ld_shlibs_F77=no fi ;; os2*) hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_minus_L_F77=yes allow_undefined_flag_F77=unsupported archive_cmds_F77='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' old_archive_From_new_cmds_F77='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' ;; osf3*) if test "$GCC" = yes; then allow_undefined_flag_F77=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else allow_undefined_flag_F77=' -expect_unresolved \*' archive_cmds_F77='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' fi hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_F77=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test "$GCC" = yes; then allow_undefined_flag_F77=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_F77='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_F77='${wl}-rpath ${wl}$libdir' else allow_undefined_flag_F77=' -expect_unresolved \*' archive_cmds_F77='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' archive_expsym_cmds_F77='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec_F77='-rpath $libdir' fi hardcode_libdir_separator_F77=: ;; solaris*) no_undefined_flag_F77=' -z text' if test "$GCC" = yes; then wlarc='${wl}' archive_cmds_F77='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' else wlarc='' archive_cmds_F77='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' archive_expsym_cmds_F77='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' fi hardcode_libdir_flag_spec_F77='-R$libdir' hardcode_shlibpath_var_F77=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands `-z linker_flag'. GCC discards it without `$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test "$GCC" = yes; then whole_archive_flag_spec_F77='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' else whole_archive_flag_spec_F77='-z allextract$convenience -z defaultextract' fi ;; esac link_all_deplibs_F77=yes ;; sunos4*) if test "x$host_vendor" = xsequent; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. archive_cmds_F77='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_F77='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_direct_F77=yes hardcode_minus_L_F77=yes hardcode_shlibpath_var_F77=no ;; sysv4) case $host_vendor in sni) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_F77=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. archive_cmds_F77='$LD -G -o $lib $libobjs $deplibs $linker_flags' reload_cmds_F77='$CC -r -o $output$reload_objs' hardcode_direct_F77=no ;; motorola) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_F77=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' hardcode_shlibpath_var_F77=no ;; sysv4.3*) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var_F77=no export_dynamic_flag_spec_F77='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var_F77=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ld_shlibs_F77=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag_F77='${wl}-z,text' archive_cmds_need_lc_F77=no hardcode_shlibpath_var_F77=no runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds_F77='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_F77='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We can NOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag_F77='${wl}-z,text' allow_undefined_flag_F77='${wl}-z,nodefs' archive_cmds_need_lc_F77=no hardcode_shlibpath_var_F77=no hardcode_libdir_flag_spec_F77='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' hardcode_libdir_separator_F77=':' link_all_deplibs_F77=yes export_dynamic_flag_spec_F77='${wl}-Bexport' runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds_F77='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_F77='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_F77='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) archive_cmds_F77='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_F77='-L$libdir' hardcode_shlibpath_var_F77=no ;; *) ld_shlibs_F77=no ;; esac fi { echo "$as_me:$LINENO: result: $ld_shlibs_F77" >&5 echo "${ECHO_T}$ld_shlibs_F77" >&6; } test "$ld_shlibs_F77" = no && can_build_shared=no # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc_F77" in x|xyes) # Assume -lc should be added archive_cmds_need_lc_F77=yes if test "$enable_shared" = yes && test "$GCC" = yes; then case $archive_cmds_F77 in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; } $rm conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl_F77 pic_flag=$lt_prog_compiler_pic_F77 compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag_F77 allow_undefined_flag_F77= if { (eval echo "$as_me:$LINENO: \"$archive_cmds_F77 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 (eval $archive_cmds_F77 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } then archive_cmds_need_lc_F77=no else archive_cmds_need_lc_F77=yes fi allow_undefined_flag_F77=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $rm conftest* { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_F77" >&5 echo "${ECHO_T}$archive_cmds_need_lc_F77" >&6; } ;; esac fi ;; esac { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; } library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=".so" postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='${libname}${release}${shared_ext}$major' ;; aix[4-9]*) version_type=linux need_lib_prefix=no need_version=no hardcode_into_libs=yes if test "$host_cpu" = ia64; then # AIX 5 supports IA64 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line `#! .'. This would cause the generated library to # depend on `.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then : else can_build_shared=no fi ;; esac # AIX (on Power*) has no versioning support, so currently we can not hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. if test "$aix_use_runtimelinking" = yes; then # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' else # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='${libname}${release}.a $libname.a' soname_spec='${libname}${release}${shared_ext}$major' fi shlibpath_var=LIBPATH fi ;; amigaos*) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; beos*) library_names_spec='${libname}${shared_ext}' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32*) version_type=windows shrext_cmds=".dll" need_version=no need_lib_prefix=no case $GCC,$host_os in yes,cygwin* | yes,mingw* | yes,pw32*) library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \${file}`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" ;; mingw*) # MinGW DLLs use traditional 'lib' prefix soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH printed by # mingw gcc, but we are running on Cygwin. Gcc prints its search # path with ; separators, and with drive letters. We can handle the # drive letters (cygwin fileutils understands them), so leave them, # especially as we might pass files found there to a mingw objdump, # which wouldn't understand a cygwinified path. Ahh. sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' ;; esac ;; *) library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' ;; esac dynamic_linker='Win32 ld.exe' # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' soname_spec='${libname}${release}${major}$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd1*) dynamic_linker=no ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[123]*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; gnu*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' if test "X$HPUX_IA64_MODE" = X32; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" fi sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555. postinstall_cmds='chmod 555 $lib' ;; interix[3-9]*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test "$lt_cv_prog_gnu_ld" = yes; then version_type=linux else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. linux* | k*bsd*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Append ld.so.conf contents to the search path if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsdelf*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; nto-qnx*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; openbsd*) version_type=sunos sys_lib_dlsearch_path_spec="/usr/lib" need_lib_prefix=no # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. case $host_os in openbsd3.3 | openbsd3.3.*) need_version=yes ;; *) need_version=no ;; esac library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then case $host_os in openbsd2.[89] | openbsd2.[89].*) shlibpath_overrides_runpath=no ;; *) shlibpath_overrides_runpath=yes ;; esac else shlibpath_overrides_runpath=yes fi ;; os2*) libname_spec='$name' shrext_cmds=".dll" need_lib_prefix=no library_names_spec='$libname${shared_ext} $libname.a' dynamic_linker='OS/2 ld.exe' shlibpath_var=LIBPATH ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test "$with_gnu_ld" = yes; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no export_dynamic_flag_spec='${wl}-Blargedynsym' runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec ;then version_type=linux library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' soname_spec='$libname${shared_ext}.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=freebsd-elf need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes if test "$with_gnu_ld" = yes; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' shlibpath_overrides_runpath=no else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' shlibpath_overrides_runpath=yes case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; uts4*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6; } test "$dynamic_linker" = no && can_build_shared=no if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" fi sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" fi sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test "$GCC" = yes; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; } hardcode_action_F77= if test -n "$hardcode_libdir_flag_spec_F77" || \ test -n "$runpath_var_F77" || \ test "X$hardcode_automatic_F77" = "Xyes" ; then # We can hardcode non-existant directories. if test "$hardcode_direct_F77" != no && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, F77)" != no && test "$hardcode_minus_L_F77" != no; then # Linking always hardcodes the temporary library directory. hardcode_action_F77=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action_F77=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action_F77=unsupported fi { echo "$as_me:$LINENO: result: $hardcode_action_F77" >&5 echo "${ECHO_T}$hardcode_action_F77" >&6; } if test "$hardcode_action_F77" = relink; then # Fast installation is not supported enable_fast_install=no elif test "$shlibpath_overrides_runpath" = yes || test "$enable_shared" = no; then # Fast installation is not necessary enable_fast_install=needless fi # The else clause should only fire when bootstrapping the # libtool distribution, otherwise you forgot to ship ltmain.sh # with your package, and you will get complaints that there are # no rules to generate ltmain.sh. if test -f "$ltmain"; then # See if we are running on zsh, and set the options which allow our commands through # without removal of \ escapes. if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi # Now quote all the things that may contain metacharacters while being # careful not to overquote the AC_SUBSTed values. We take copies of the # variables and quote the copies for generation of the libtool script. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ SED SHELL STRIP \ libname_spec library_names_spec soname_spec extract_expsyms_cmds \ old_striplib striplib file_magic_cmd finish_cmds finish_eval \ deplibs_check_method reload_flag reload_cmds need_locks \ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_c_name_address \ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ old_postinstall_cmds old_postuninstall_cmds \ compiler_F77 \ CC_F77 \ LD_F77 \ lt_prog_compiler_wl_F77 \ lt_prog_compiler_pic_F77 \ lt_prog_compiler_static_F77 \ lt_prog_compiler_no_builtin_flag_F77 \ export_dynamic_flag_spec_F77 \ thread_safe_flag_spec_F77 \ whole_archive_flag_spec_F77 \ enable_shared_with_static_runtimes_F77 \ old_archive_cmds_F77 \ old_archive_from_new_cmds_F77 \ predep_objects_F77 \ postdep_objects_F77 \ predeps_F77 \ postdeps_F77 \ compiler_lib_search_path_F77 \ compiler_lib_search_dirs_F77 \ archive_cmds_F77 \ archive_expsym_cmds_F77 \ postinstall_cmds_F77 \ postuninstall_cmds_F77 \ old_archive_from_expsyms_cmds_F77 \ allow_undefined_flag_F77 \ no_undefined_flag_F77 \ export_symbols_cmds_F77 \ hardcode_libdir_flag_spec_F77 \ hardcode_libdir_flag_spec_ld_F77 \ hardcode_libdir_separator_F77 \ hardcode_automatic_F77 \ module_cmds_F77 \ module_expsym_cmds_F77 \ lt_cv_prog_compiler_c_o_F77 \ fix_srcfile_path_F77 \ exclude_expsyms_F77 \ include_expsyms_F77; do case $var in old_archive_cmds_F77 | \ old_archive_from_new_cmds_F77 | \ archive_cmds_F77 | \ archive_expsym_cmds_F77 | \ module_cmds_F77 | \ module_expsym_cmds_F77 | \ old_archive_from_expsyms_cmds_F77 | \ export_symbols_cmds_F77 | \ extract_expsyms_cmds | reload_cmds | finish_cmds | \ postinstall_cmds | postuninstall_cmds | \ old_postinstall_cmds | old_postuninstall_cmds | \ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) # Double-quote double-evaled strings. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" ;; *) eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; esac done case $lt_echo in *'\$0 --fallback-echo"') lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` ;; esac cfgfile="$ofile" cat <<__EOF__ >> "$cfgfile" # ### BEGIN LIBTOOL TAG CONFIG: $tagname # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc_F77 # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_F77 # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # An echo program that does not interpret backslashes. echo=$lt_echo # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A C compiler. LTCC=$lt_LTCC # LTCC compiler flags. LTCFLAGS=$lt_LTCFLAGS # A language-specific compiler. CC=$lt_compiler_F77 # Is the compiler the GNU C compiler? with_gcc=$GCC_F77 # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD_F77 # Whether we need hard or soft links. LN_S=$lt_LN_S # A BSD-compatible nm program. NM=$lt_NM # A symbol stripping program STRIP=$lt_STRIP # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL" # Used on cygwin: object dumper. OBJDUMP="$OBJDUMP" # Used on cygwin: assembler. AS="$AS" # The name of the directory that contains temporary libtool files. objdir=$objdir # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl_F77 # Object file suffix (normally "o"). objext="$ac_objext" # Old archive suffix (normally "a"). libext="$libext" # Shared library suffix (normally ".so"). shrext_cmds='$shrext_cmds' # Executable file suffix (normally ""). exeext="$exeext" # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic_F77 pic_mode=$pic_mode # What is the maximum length of a command? max_cmd_len=$lt_cv_sys_max_cmd_len # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o_F77 # Must we lock files when doing compilation? need_locks=$lt_need_locks # Do we need the lib prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static_F77 # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_F77 # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_F77 # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_F77 # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec_F77 # Library versioning type. version_type=$version_type # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Commands used to build and install an old-style archive. RANLIB=$lt_RANLIB old_archive_cmds=$lt_old_archive_cmds_F77 old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_F77 # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_F77 # Commands used to build and install a shared archive. archive_cmds=$lt_archive_cmds_F77 archive_expsym_cmds=$lt_archive_expsym_cmds_F77 postinstall_cmds=$lt_postinstall_cmds postuninstall_cmds=$lt_postuninstall_cmds # Commands used to build a loadable module (assumed same as above if empty) module_cmds=$lt_module_cmds_F77 module_expsym_cmds=$lt_module_expsym_cmds_F77 # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_predep_objects_F77 # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects_F77 # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps_F77 # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_F77 # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_F77 # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_F77 # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method == file_magic. file_magic_cmd=$lt_file_magic_cmd # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag_F77 # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_F77 # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # Same as above, but a single script fragment to be evaled but not shown. finish_eval=$lt_finish_eval # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm in a C name address pair global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # This is the shared library runtime path variable. runpath_var=$runpath_var # This is the shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action_F77 # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist. hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_F77 # If ld is used when linking, flag to hardcode \$libdir into # a binary during linking. This must work even if \$libdir does # not exist. hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_F77 # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_F77 # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct_F77 # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L_F77 # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var_F77 # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=$hardcode_automatic_F77 # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="$variables_saved_for_relink" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs_F77 # Compile-time system search path for libraries sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Run-time system search path for libraries sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec # Fix the shell variable \$srcfile for the compiler. fix_srcfile_path=$lt_fix_srcfile_path # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols_F77 # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds_F77 # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms_F77 # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_F77 # ### END LIBTOOL TAG CONFIG: $tagname __EOF__ else # If there is no Makefile yet, we rely on a make rule to execute # `config.status --recheck' to rerun these tests and create the # libtool script then. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` if test -f "$ltmain_in"; then test -f Makefile && make "$ltmain" fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC="$lt_save_CC" else tagname="" fi ;; GCJ) if test -n "$GCJ" && test "X$GCJ" != "Xno"; then # Source file extension for Java test sources. ac_ext=java # Object file extension for compiled Java test sources. objext=o objext_GCJ=$objext # Code to be used in simple compile tests lt_simple_compile_test_code="class foo {}" # Code to be used in simple link tests lt_simple_link_test_code='public class conftest { public static void main(String[] argv) {}; }' # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $rm conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $rm -r conftest* # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${GCJ-"gcj"} compiler=$CC compiler_GCJ=$CC for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` # GCJ did not exist at the time GCC didn't implicitly link libc in. archive_cmds_need_lc_GCJ=no old_archive_cmds_GCJ=$old_archive_cmds lt_prog_compiler_no_builtin_flag_GCJ= if test "$GCC" = yes; then lt_prog_compiler_no_builtin_flag_GCJ=' -fno-builtin' { echo "$as_me:$LINENO: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 echo $ECHO_N "checking if $compiler supports -fno-rtti -fno-exceptions... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_rtti_exceptions=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-fno-rtti -fno-exceptions" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:16660: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:16664: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_rtti_exceptions=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_rtti_exceptions" >&6; } if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then lt_prog_compiler_no_builtin_flag_GCJ="$lt_prog_compiler_no_builtin_flag_GCJ -fno-rtti -fno-exceptions" else : fi fi lt_prog_compiler_wl_GCJ= lt_prog_compiler_pic_GCJ= lt_prog_compiler_static_GCJ= { echo "$as_me:$LINENO: checking for $compiler option to produce PIC" >&5 echo $ECHO_N "checking for $compiler option to produce PIC... $ECHO_C" >&6; } if test "$GCC" = yes; then lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_static_GCJ='-static' case $host_os in aix*) # All AIX code is PIC. if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_GCJ='-Bstatic' fi ;; amigaos*) # FIXME: we need at least 68020 code to build shared libraries, but # adding the `-m68020' flag to GCC prevents building anything better, # like `-m68040'. lt_prog_compiler_pic_GCJ='-m68020 -resident32 -malways-restore-a4' ;; beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) # PIC is the default for these OSes. ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). # Although the cygwin gcc ignores -fPIC, still need this for old-style # (--disable-auto-import) libraries ;; darwin* | rhapsody*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files lt_prog_compiler_pic_GCJ='-fno-common' ;; interix[3-9]*) # Interix 3.x gcc -fpic/-fPIC options generate broken code. # Instead, we relocate shared libraries at runtime. ;; msdosdjgpp*) # Just because we use GCC doesn't mean we suddenly get shared libraries # on systems that don't support them. lt_prog_compiler_can_build_shared_GCJ=no enable_shared=no ;; sysv4*MP*) if test -d /usr/nec; then lt_prog_compiler_pic_GCJ=-Kconform_pic fi ;; hpux*) # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_GCJ='-fPIC' ;; esac ;; *) lt_prog_compiler_pic_GCJ='-fPIC' ;; esac else # PORTME Check for flag to pass linker flags through the system compiler. case $host_os in aix*) lt_prog_compiler_wl_GCJ='-Wl,' if test "$host_cpu" = ia64; then # AIX 5 now supports IA64 processor lt_prog_compiler_static_GCJ='-Bstatic' else lt_prog_compiler_static_GCJ='-bnso -bI:/lib/syscalls.exp' fi ;; darwin*) # PIC is the default on this platform # Common symbols not allowed in MH_DYLIB files case $cc_basename in xlc*) lt_prog_compiler_pic_GCJ='-qnocommon' lt_prog_compiler_wl_GCJ='-Wl,' ;; esac ;; mingw* | cygwin* | pw32* | os2*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). ;; hpux9* | hpux10* | hpux11*) lt_prog_compiler_wl_GCJ='-Wl,' # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but # not for PA HP-UX. case $host_cpu in hppa*64*|ia64*) # +Z the default ;; *) lt_prog_compiler_pic_GCJ='+Z' ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? lt_prog_compiler_static_GCJ='${wl}-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) lt_prog_compiler_wl_GCJ='-Wl,' # PIC (with -KPIC) is the default. lt_prog_compiler_static_GCJ='-non_shared' ;; newsos6) lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; linux* | k*bsd*-gnu) case $cc_basename in icc* | ecc*) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-static' ;; pgcc* | pgf77* | pgf90* | pgf95*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_pic_GCJ='-fpic' lt_prog_compiler_static_GCJ='-Bstatic' ;; ccc*) lt_prog_compiler_wl_GCJ='-Wl,' # All Alpha code is PIC. lt_prog_compiler_static_GCJ='-non_shared' ;; *) case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' lt_prog_compiler_wl_GCJ='-Wl,' ;; *Sun\ F*) # Sun Fortran 8.3 passes all unrecognized flags to the linker lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' lt_prog_compiler_wl_GCJ='' ;; esac ;; esac ;; osf3* | osf4* | osf5*) lt_prog_compiler_wl_GCJ='-Wl,' # All OSF/1 code is PIC. lt_prog_compiler_static_GCJ='-non_shared' ;; rdos*) lt_prog_compiler_static_GCJ='-non_shared' ;; solaris*) lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' case $cc_basename in f77* | f90* | f95*) lt_prog_compiler_wl_GCJ='-Qoption ld ';; *) lt_prog_compiler_wl_GCJ='-Wl,';; esac ;; sunos4*) lt_prog_compiler_wl_GCJ='-Qoption ld ' lt_prog_compiler_pic_GCJ='-PIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; sysv4 | sysv4.2uw2* | sysv4.3*) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; sysv4*MP*) if test -d /usr/nec ;then lt_prog_compiler_pic_GCJ='-Kconform_pic' lt_prog_compiler_static_GCJ='-Bstatic' fi ;; sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_pic_GCJ='-KPIC' lt_prog_compiler_static_GCJ='-Bstatic' ;; unicos*) lt_prog_compiler_wl_GCJ='-Wl,' lt_prog_compiler_can_build_shared_GCJ=no ;; uts4*) lt_prog_compiler_pic_GCJ='-pic' lt_prog_compiler_static_GCJ='-Bstatic' ;; *) lt_prog_compiler_can_build_shared_GCJ=no ;; esac fi { echo "$as_me:$LINENO: result: $lt_prog_compiler_pic_GCJ" >&5 echo "${ECHO_T}$lt_prog_compiler_pic_GCJ" >&6; } # # Check to make sure the PIC flag actually works. # if test -n "$lt_prog_compiler_pic_GCJ"; then { echo "$as_me:$LINENO: checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works" >&5 echo $ECHO_N "checking if $compiler PIC flag $lt_prog_compiler_pic_GCJ works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_pic_works_GCJ+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_pic_works_GCJ=no ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="$lt_prog_compiler_pic_GCJ" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. # The option is referenced via a variable to avoid confusing sed. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:16950: $lt_compile\"" >&5) (eval "$lt_compile" 2>conftest.err) ac_status=$? cat conftest.err >&5 echo "$as_me:16954: \$? = $ac_status" >&5 if (exit $ac_status) && test -s "$ac_outfile"; then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings other than the usual output. $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_pic_works_GCJ=yes fi fi $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_pic_works_GCJ" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_pic_works_GCJ" >&6; } if test x"$lt_cv_prog_compiler_pic_works_GCJ" = xyes; then case $lt_prog_compiler_pic_GCJ in "" | " "*) ;; *) lt_prog_compiler_pic_GCJ=" $lt_prog_compiler_pic_GCJ" ;; esac else lt_prog_compiler_pic_GCJ= lt_prog_compiler_can_build_shared_GCJ=no fi fi case $host_os in # For platforms which do not support PIC, -DPIC is meaningless: *djgpp*) lt_prog_compiler_pic_GCJ= ;; *) lt_prog_compiler_pic_GCJ="$lt_prog_compiler_pic_GCJ" ;; esac # # Check to make sure the static flag actually works. # wl=$lt_prog_compiler_wl_GCJ eval lt_tmp_static_flag=\"$lt_prog_compiler_static_GCJ\" { echo "$as_me:$LINENO: checking if $compiler static flag $lt_tmp_static_flag works" >&5 echo $ECHO_N "checking if $compiler static flag $lt_tmp_static_flag works... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_static_works_GCJ+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_static_works_GCJ=no save_LDFLAGS="$LDFLAGS" LDFLAGS="$LDFLAGS $lt_tmp_static_flag" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then # The linker can only warn and ignore the option if not recognized # So say no if there are warnings if test -s conftest.err; then # Append any errors to the config.log. cat conftest.err 1>&5 $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 if diff conftest.exp conftest.er2 >/dev/null; then lt_cv_prog_compiler_static_works_GCJ=yes fi else lt_cv_prog_compiler_static_works_GCJ=yes fi fi $rm -r conftest* LDFLAGS="$save_LDFLAGS" fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_static_works_GCJ" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_static_works_GCJ" >&6; } if test x"$lt_cv_prog_compiler_static_works_GCJ" = xyes; then : else lt_prog_compiler_static_GCJ= fi { echo "$as_me:$LINENO: checking if $compiler supports -c -o file.$ac_objext" >&5 echo $ECHO_N "checking if $compiler supports -c -o file.$ac_objext... $ECHO_C" >&6; } if test "${lt_cv_prog_compiler_c_o_GCJ+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_prog_compiler_c_o_GCJ=no $rm -r conftest 2>/dev/null mkdir conftest cd conftest mkdir out echo "$lt_simple_compile_test_code" > conftest.$ac_ext lt_compiler_flag="-o out/conftest2.$ac_objext" # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins # with a dollar sign (not a hyphen), so the echo should work correctly. lt_compile=`echo "$ac_compile" | $SED \ -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's:$: $lt_compiler_flag:'` (eval echo "\"\$as_me:17054: $lt_compile\"" >&5) (eval "$lt_compile" 2>out/conftest.err) ac_status=$? cat out/conftest.err >&5 echo "$as_me:17058: \$? = $ac_status" >&5 if (exit $ac_status) && test -s out/conftest2.$ac_objext then # The compiler can only warn and ignore the option if not recognized # So say no if there are warnings $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then lt_cv_prog_compiler_c_o_GCJ=yes fi fi chmod u+w . 2>&5 $rm conftest* # SGI C++ compiler will create directory out/ii_files/ for # template instantiation test -d out/ii_files && $rm out/ii_files/* && rmdir out/ii_files $rm out/* && rmdir out cd .. rmdir conftest $rm conftest* fi { echo "$as_me:$LINENO: result: $lt_cv_prog_compiler_c_o_GCJ" >&5 echo "${ECHO_T}$lt_cv_prog_compiler_c_o_GCJ" >&6; } hard_links="nottested" if test "$lt_cv_prog_compiler_c_o_GCJ" = no && test "$need_locks" != no; then # do not overwrite the value of need_locks provided by the user { echo "$as_me:$LINENO: checking if we can lock with hard links" >&5 echo $ECHO_N "checking if we can lock with hard links... $ECHO_C" >&6; } hard_links=yes $rm conftest* ln conftest.a conftest.b 2>/dev/null && hard_links=no touch conftest.a ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no { echo "$as_me:$LINENO: result: $hard_links" >&5 echo "${ECHO_T}$hard_links" >&6; } if test "$hard_links" = no; then { echo "$as_me:$LINENO: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} need_locks=warn fi else need_locks=no fi { echo "$as_me:$LINENO: checking whether the $compiler linker ($LD) supports shared libraries" >&5 echo $ECHO_N "checking whether the $compiler linker ($LD) supports shared libraries... $ECHO_C" >&6; } runpath_var= allow_undefined_flag_GCJ= enable_shared_with_static_runtimes_GCJ=no archive_cmds_GCJ= archive_expsym_cmds_GCJ= old_archive_From_new_cmds_GCJ= old_archive_from_expsyms_cmds_GCJ= export_dynamic_flag_spec_GCJ= whole_archive_flag_spec_GCJ= thread_safe_flag_spec_GCJ= hardcode_libdir_flag_spec_GCJ= hardcode_libdir_flag_spec_ld_GCJ= hardcode_libdir_separator_GCJ= hardcode_direct_GCJ=no hardcode_minus_L_GCJ=no hardcode_shlibpath_var_GCJ=unsupported link_all_deplibs_GCJ=unknown hardcode_automatic_GCJ=no module_cmds_GCJ= module_expsym_cmds_GCJ= always_export_symbols_GCJ=no export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' # include_expsyms should be a list of space-separated symbols to be *always* # included in the symbol list include_expsyms_GCJ= # exclude_expsyms can be an extended regexp of symbols to exclude # it will be wrapped by ` (' and `)$', so one must not match beginning or # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', # as well as any symbol that contains `d'. exclude_expsyms_GCJ='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if # the symbol is explicitly referenced. Since portable code cannot # rely on this symbol name, it's probably fine to never include it in # preloaded symbol tables. # Exclude shared library initialization/finalization symbols. extract_expsyms_cmds= # Just being paranoid about ensuring that cc_basename is set. for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` case $host_os in cygwin* | mingw* | pw32*) # FIXME: the MSVC++ port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++. if test "$GCC" != yes; then with_gnu_ld=no fi ;; interix*) # we just hope/assume this is gcc and not c89 (= MSVC++) with_gnu_ld=yes ;; openbsd*) with_gnu_ld=no ;; esac ld_shlibs_GCJ=yes if test "$with_gnu_ld" = yes; then # If archive_cmds runs LD, not CC, wlarc should be empty wlarc='${wl}' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH hardcode_libdir_flag_spec_GCJ='${wl}--rpath ${wl}$libdir' export_dynamic_flag_spec_GCJ='${wl}--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | grep 'no-whole-archive' > /dev/null; then whole_archive_flag_spec_GCJ="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' else whole_archive_flag_spec_GCJ= fi supports_anon_versioning=no case `$LD -v 2>/dev/null` in *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... *\ 2.11.*) ;; # other 2.11 versions *) supports_anon_versioning=yes ;; esac # See if GNU ld supports shared libraries. case $host_os in aix[3-9]*) # On AIX/PPC, the GNU linker is very broken if test "$host_cpu" != ia64; then ld_shlibs_GCJ=no cat <&2 *** Warning: the GNU linker, at least up to release 2.9.1, is reported *** to be unable to reliably create shared libraries on AIX. *** Therefore, libtool is disabling shared libraries support. If you *** really care for shared libraries, you may want to modify your PATH *** so that a non-GNU linker is found, and then restart. EOF fi ;; amigaos*) archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_minus_L_GCJ=yes # Samuel A. Falvo II reports # that the semantics of dynamic libraries on AmigaOS, at least up # to version 4, is to share data among multiple programs linked # with the same dynamic library. Since this doesn't match the # behavior of shared libraries on other platforms, we can't use # them. ld_shlibs_GCJ=no ;; beos*) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then allow_undefined_flag_GCJ=unsupported # Joseph Beckenbach says some releases of gcc # support --undefined. This deserves some investigation. FIXME archive_cmds_GCJ='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' else ld_shlibs_GCJ=no fi ;; cygwin* | mingw* | pw32*) # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, GCJ) is actually meaningless, # as there is no search path for DLLs. hardcode_libdir_flag_spec_GCJ='-L$libdir' allow_undefined_flag_GCJ=unsupported always_export_symbols_GCJ=no enable_shared_with_static_runtimes_GCJ=yes export_symbols_cmds_GCJ='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' # If the export-symbols file already is a .def file (1st line # is EXPORTS), use it as is; otherwise, prepend... archive_expsym_cmds_GCJ='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then cp $export_symbols $output_objdir/$soname.def; else echo EXPORTS > $output_objdir/$soname.def; cat $export_symbols >> $output_objdir/$soname.def; fi~ $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else ld_shlibs_GCJ=no fi ;; interix[3-9]*) hardcode_direct_GCJ=no hardcode_shlibpath_var_GCJ=no hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' export_dynamic_flag_spec_GCJ='${wl}-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. archive_cmds_GCJ='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' archive_expsym_cmds_GCJ='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | k*bsd*-gnu) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then tmp_addflag= case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95*) # Portland Group f77 and f90 compilers whole_archive_flag_spec_GCJ='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 tmp_addflag=' -i_dynamic -nofor_main' ;; ifc* | ifort*) # Intel Fortran compiler tmp_addflag=' -nofor_main' ;; esac case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 whole_archive_flag_spec_GCJ='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive' tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; *) tmp_sharedflag='-shared' ;; esac archive_cmds_GCJ='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' if test $supports_anon_versioning = yes; then archive_expsym_cmds_GCJ='$echo "{ global:" > $output_objdir/$libname.ver~ cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ $echo "local: *; };" >> $output_objdir/$libname.ver~ $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' fi link_all_deplibs_GCJ=no else ld_shlibs_GCJ=no fi ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds_GCJ='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' fi ;; solaris*) if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then ld_shlibs_GCJ=no cat <&2 *** Warning: The releases 2.8.* of the GNU linker cannot reliably *** create shared libraries on Solaris systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.9.1 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. EOF elif $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs_GCJ=no fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) case `$LD -v 2>&1` in *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) ld_shlibs_GCJ=no cat <<_LT_EOF 1>&2 *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify *** your PATH or compiler configuration so that the native linker is *** used, and then restart. _LT_EOF ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then hardcode_libdir_flag_spec_GCJ='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`' archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib' archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib' else ld_shlibs_GCJ=no fi ;; esac ;; sunos4*) archive_cmds_GCJ='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' wlarc= hardcode_direct_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; *) if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' archive_expsym_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' else ld_shlibs_GCJ=no fi ;; esac if test "$ld_shlibs_GCJ" = no; then runpath_var= hardcode_libdir_flag_spec_GCJ= export_dynamic_flag_spec_GCJ= whole_archive_flag_spec_GCJ= fi else # PORTME fill in a description of your system's linker (not GNU ld) case $host_os in aix3*) allow_undefined_flag_GCJ=unsupported always_export_symbols_GCJ=yes archive_expsym_cmds_GCJ='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. hardcode_minus_L_GCJ=yes if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. hardcode_direct_GCJ=unsupported fi ;; aix[4-9]*) if test "$host_cpu" = ia64; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' no_entry_flag="" else # If we're using GNU nm, then we don't want the "-C" option. # -C means demangle to AIX nm, but means don't demangle with GNU nm if $NM -V 2>&1 | grep 'GNU' > /dev/null; then export_symbols_cmds_GCJ='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' else export_symbols_cmds_GCJ='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$2 == "T") || (\$2 == "D") || (\$2 == "B")) && (substr(\$3,1,1) != ".")) { print \$3 } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we # need to do runtime linking. case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) for ld_flag in $LDFLAGS; do if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then aix_use_runtimelinking=yes break fi done ;; esac exp_sym_flag='-bexport' no_entry_flag='-bnoentry' fi # When large executables or shared objects are built, AIX ld can # have problems creating the table of contents. If linking a library # or program results in "error TOC overflow" add -mminimal-toc to # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. archive_cmds_GCJ='' hardcode_direct_GCJ=yes hardcode_libdir_separator_GCJ=':' link_all_deplibs_GCJ=yes if test "$GCC" = yes; then case $host_os in aix4.[012]|aix4.[012].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ collect2name=`${CC} -print-prog-name=collect2` if test -f "$collect2name" && \ strings "$collect2name" | grep resolve_lib_name >/dev/null then # We have reworked collect2 : else # We have old collect2 hardcode_direct_GCJ=unsupported # It fails to find uninstalled libraries when the uninstalled # path is not listed in the libpath. Setting hardcode_minus_L # to unsupported forces relinking hardcode_minus_L_GCJ=yes hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_libdir_separator_GCJ= fi ;; esac shared_flag='-shared' if test "$aix_use_runtimelinking" = yes; then shared_flag="$shared_flag "'${wl}-G' fi else # not using gcc if test "$host_cpu" = ia64; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else if test "$aix_use_runtimelinking" = yes; then shared_flag='${wl}-G' else shared_flag='${wl}-bM:SRE' fi fi fi # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. always_export_symbols_GCJ=yes if test "$aix_use_runtimelinking" = yes; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. allow_undefined_flag_GCJ='-berok' # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" archive_expsym_cmds_GCJ="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" else if test "$host_cpu" = ia64; then hardcode_libdir_flag_spec_GCJ='${wl}-R $libdir:/usr/lib:/lib' allow_undefined_flag_GCJ="-z nodefs" archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an empty executable. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then lt_aix_libpath_sed=' /Import File Strings/,/^$/ { /^0/ { s/^0 *\(.*\)$/\1/ p } }' aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` # Check for a 64-bit object if we didn't find anything. if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi hardcode_libdir_flag_spec_GCJ='${wl}-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. no_undefined_flag_GCJ=' ${wl}-bernotok' allow_undefined_flag_GCJ=' ${wl}-berok' # Exported symbols can be pulled into shared objects from archives whole_archive_flag_spec_GCJ='$convenience' archive_cmds_need_lc_GCJ=yes # This is similar to how AIX traditionally builds its shared libraries. archive_expsym_cmds_GCJ="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' fi fi ;; amigaos*) archive_cmds_GCJ='$rm $output_objdir/a2ixlibrary.data~$echo "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$echo "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$echo "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$echo "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_minus_L_GCJ=yes # see comment about different semantics on the GNU ld section ld_shlibs_GCJ=no ;; bsdi[45]*) export_dynamic_flag_spec_GCJ=-rdynamic ;; cygwin* | mingw* | pw32*) # When not using gcc, we currently assume that we are using # Microsoft Visual C++. # hardcode_libdir_flag_spec is actually meaningless, as there is # no search path for DLLs. hardcode_libdir_flag_spec_GCJ=' ' allow_undefined_flag_GCJ=unsupported # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. shrext_cmds=".dll" # FIXME: Setting linknames here is a bad hack. archive_cmds_GCJ='$CC -o $lib $libobjs $compiler_flags `echo "$deplibs" | $SED -e '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. old_archive_From_new_cmds_GCJ='true' # FIXME: Should let the user specify the lib program. old_archive_cmds_GCJ='lib -OUT:$oldlib$oldobjs$old_deplibs' fix_srcfile_path_GCJ='`cygpath -w "$srcfile"`' enable_shared_with_static_runtimes_GCJ=yes ;; darwin* | rhapsody*) case $host_os in rhapsody* | darwin1.[012]) allow_undefined_flag_GCJ='${wl}-undefined ${wl}suppress' ;; *) # Darwin 1.3 on if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' else case ${MACOSX_DEPLOYMENT_TARGET} in 10.[012]) allow_undefined_flag_GCJ='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; 10.*) allow_undefined_flag_GCJ='${wl}-undefined ${wl}dynamic_lookup' ;; esac fi ;; esac archive_cmds_need_lc_GCJ=no hardcode_direct_GCJ=no hardcode_automatic_GCJ=yes hardcode_shlibpath_var_GCJ=unsupported whole_archive_flag_spec_GCJ='' link_all_deplibs_GCJ=yes if test "$GCC" = yes ; then output_verbose_link_cmd='echo' archive_cmds_GCJ="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" module_cmds_GCJ="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" archive_expsym_cmds_GCJ="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" module_expsym_cmds_GCJ="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" else case $cc_basename in xlc*) output_verbose_link_cmd='echo' archive_cmds_GCJ='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring' module_cmds_GCJ='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags' # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds archive_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' module_expsym_cmds_GCJ='sed -e "s,#.*,," -e "s,^[ ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}' ;; *) ld_shlibs_GCJ=no ;; esac fi ;; dgux*) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_shlibpath_var_GCJ=no ;; freebsd1*) ld_shlibs_GCJ=no ;; # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor # support. Future versions do this automatically, but an explicit c++rt0.o # does not break anything, and helps significantly (at the cost of a little # extra space). freebsd2.2*) archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' hardcode_libdir_flag_spec_GCJ='-R$libdir' hardcode_direct_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; # Unfortunately, older versions of FreeBSD 2 do not have this feature. freebsd2*) archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_GCJ=yes hardcode_minus_L_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; # FreeBSD 3 and greater uses gcc -shared to do shared libraries. freebsd* | dragonfly*) archive_cmds_GCJ='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec_GCJ='-R$libdir' hardcode_direct_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; hpux9*) if test "$GCC" = yes; then archive_cmds_GCJ='$rm $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' else archive_cmds_GCJ='$rm $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' fi hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' hardcode_libdir_separator_GCJ=: hardcode_direct_GCJ=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_GCJ=yes export_dynamic_flag_spec_GCJ='${wl}-E' ;; hpux10*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_GCJ='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' hardcode_libdir_separator_GCJ=: hardcode_direct_GCJ=yes export_dynamic_flag_spec_GCJ='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_GCJ=yes fi ;; hpux11*) if test "$GCC" = yes -a "$with_gnu_ld" = no; then case $host_cpu in hppa*64*) archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds_GCJ='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_GCJ='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) archive_cmds_GCJ='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac fi if test "$with_gnu_ld" = no; then hardcode_libdir_flag_spec_GCJ='${wl}+b ${wl}$libdir' hardcode_libdir_separator_GCJ=: case $host_cpu in hppa*64*|ia64*) hardcode_libdir_flag_spec_ld_GCJ='+b $libdir' hardcode_direct_GCJ=no hardcode_shlibpath_var_GCJ=no ;; *) hardcode_direct_GCJ=yes export_dynamic_flag_spec_GCJ='${wl}-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. hardcode_minus_L_GCJ=yes ;; esac fi ;; irix5* | irix6* | nonstopux*) if test "$GCC" = yes; then archive_cmds_GCJ='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else archive_cmds_GCJ='$LD -shared $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_ld_GCJ='-rpath $libdir' fi hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_GCJ=: link_all_deplibs_GCJ=yes ;; netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else archive_cmds_GCJ='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF fi hardcode_libdir_flag_spec_GCJ='-R$libdir' hardcode_direct_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; newsos6) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_GCJ=yes hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_GCJ=: hardcode_shlibpath_var_GCJ=no ;; openbsd*) if test -f /usr/libexec/ld.so; then hardcode_direct_GCJ=yes hardcode_shlibpath_var_GCJ=no if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' export_dynamic_flag_spec_GCJ='${wl}-E' else case $host_os in openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) archive_cmds_GCJ='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_GCJ='-R$libdir' ;; *) archive_cmds_GCJ='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' hardcode_libdir_flag_spec_GCJ='${wl}-rpath,$libdir' ;; esac fi else ld_shlibs_GCJ=no fi ;; os2*) hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_minus_L_GCJ=yes allow_undefined_flag_GCJ=unsupported archive_cmds_GCJ='$echo "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$echo "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~$echo DATA >> $output_objdir/$libname.def~$echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~$echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' old_archive_From_new_cmds_GCJ='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' ;; osf3*) if test "$GCC" = yes; then allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' else allow_undefined_flag_GCJ=' -expect_unresolved \*' archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' fi hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' hardcode_libdir_separator_GCJ=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag if test "$GCC" = yes; then allow_undefined_flag_GCJ=' ${wl}-expect_unresolved ${wl}\*' archive_cmds_GCJ='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' hardcode_libdir_flag_spec_GCJ='${wl}-rpath ${wl}$libdir' else allow_undefined_flag_GCJ=' -expect_unresolved \*' archive_cmds_GCJ='$LD -shared${allow_undefined_flag} $libobjs $deplibs $linker_flags -msym -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib' archive_expsym_cmds_GCJ='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; echo "-hidden">> $lib.exp~ $LD -shared${allow_undefined_flag} -input $lib.exp $linker_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && echo -set_version $verstring` -update_registry ${output_objdir}/so_locations -o $lib~$rm $lib.exp' # Both c and cxx compiler support -rpath directly hardcode_libdir_flag_spec_GCJ='-rpath $libdir' fi hardcode_libdir_separator_GCJ=: ;; solaris*) no_undefined_flag_GCJ=' -z text' if test "$GCC" = yes; then wlarc='${wl}' archive_cmds_GCJ='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $CC -shared ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$rm $lib.exp' else wlarc='' archive_cmds_GCJ='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' archive_expsym_cmds_GCJ='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~ $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp' fi hardcode_libdir_flag_spec_GCJ='-R$libdir' hardcode_shlibpath_var_GCJ=no case $host_os in solaris2.[0-5] | solaris2.[0-5].*) ;; *) # The compiler driver will combine and reorder linker options, # but understands `-z linker_flag'. GCC discards it without `$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) if test "$GCC" = yes; then whole_archive_flag_spec_GCJ='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' else whole_archive_flag_spec_GCJ='-z allextract$convenience -z defaultextract' fi ;; esac link_all_deplibs_GCJ=yes ;; sunos4*) if test "x$host_vendor" = xsequent; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. archive_cmds_GCJ='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_GCJ='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_direct_GCJ=yes hardcode_minus_L_GCJ=yes hardcode_shlibpath_var_GCJ=no ;; sysv4) case $host_vendor in sni) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_GCJ=yes # is this really true??? ;; siemens) ## LD is ld it makes a PLAMLIB ## CC just makes a GrossModule. archive_cmds_GCJ='$LD -G -o $lib $libobjs $deplibs $linker_flags' reload_cmds_GCJ='$CC -r -o $output$reload_objs' hardcode_direct_GCJ=no ;; motorola) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_direct_GCJ=no #Motorola manual says yes, but my tests say they lie ;; esac runpath_var='LD_RUN_PATH' hardcode_shlibpath_var_GCJ=no ;; sysv4.3*) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var_GCJ=no export_dynamic_flag_spec_GCJ='-Bexport' ;; sysv4*MP*) if test -d /usr/nec; then archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_shlibpath_var_GCJ=no runpath_var=LD_RUN_PATH hardcode_runpath_var=yes ld_shlibs_GCJ=yes fi ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) no_undefined_flag_GCJ='${wl}-z,text' archive_cmds_need_lc_GCJ=no hardcode_shlibpath_var_GCJ=no runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds_GCJ='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_GCJ='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) # Note: We can NOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. no_undefined_flag_GCJ='${wl}-z,text' allow_undefined_flag_GCJ='${wl}-z,nodefs' archive_cmds_need_lc_GCJ=no hardcode_shlibpath_var_GCJ=no hardcode_libdir_flag_spec_GCJ='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`' hardcode_libdir_separator_GCJ=':' link_all_deplibs_GCJ=yes export_dynamic_flag_spec_GCJ='${wl}-Bexport' runpath_var='LD_RUN_PATH' if test "$GCC" = yes; then archive_cmds_GCJ='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' else archive_cmds_GCJ='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' archive_expsym_cmds_GCJ='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; uts4*) archive_cmds_GCJ='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' hardcode_libdir_flag_spec_GCJ='-L$libdir' hardcode_shlibpath_var_GCJ=no ;; *) ld_shlibs_GCJ=no ;; esac fi { echo "$as_me:$LINENO: result: $ld_shlibs_GCJ" >&5 echo "${ECHO_T}$ld_shlibs_GCJ" >&6; } test "$ld_shlibs_GCJ" = no && can_build_shared=no # # Do we need to explicitly link libc? # case "x$archive_cmds_need_lc_GCJ" in x|xyes) # Assume -lc should be added archive_cmds_need_lc_GCJ=yes if test "$enable_shared" = yes && test "$GCC" = yes; then case $archive_cmds_GCJ in *'~'*) # FIXME: we may have to deal with multi-command sequences. ;; '$CC '*) # Test whether the compiler implicitly links with -lc since on some # systems, -lgcc has to come before -lc. If gcc already passes -lc # to ld, don't add -lc before -lgcc. { echo "$as_me:$LINENO: checking whether -lc should be explicitly linked in" >&5 echo $ECHO_N "checking whether -lc should be explicitly linked in... $ECHO_C" >&6; } $rm conftest* echo "$lt_simple_compile_test_code" > conftest.$ac_ext if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 (eval $ac_compile) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } 2>conftest.err; then soname=conftest lib=conftest libobjs=conftest.$ac_objext deplibs= wl=$lt_prog_compiler_wl_GCJ pic_flag=$lt_prog_compiler_pic_GCJ compiler_flags=-v linker_flags=-v verstring= output_objdir=. libname=conftest lt_save_allow_undefined_flag=$allow_undefined_flag_GCJ allow_undefined_flag_GCJ= if { (eval echo "$as_me:$LINENO: \"$archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\"") >&5 (eval $archive_cmds_GCJ 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } then archive_cmds_need_lc_GCJ=no else archive_cmds_need_lc_GCJ=yes fi allow_undefined_flag_GCJ=$lt_save_allow_undefined_flag else cat conftest.err 1>&5 fi $rm conftest* { echo "$as_me:$LINENO: result: $archive_cmds_need_lc_GCJ" >&5 echo "${ECHO_T}$archive_cmds_need_lc_GCJ" >&6; } ;; esac fi ;; esac { echo "$as_me:$LINENO: checking dynamic linker characteristics" >&5 echo $ECHO_N "checking dynamic linker characteristics... $ECHO_C" >&6; } library_names_spec= libname_spec='lib$name' soname_spec= shrext_cmds=".so" postinstall_cmds= postuninstall_cmds= finish_cmds= finish_eval= shlibpath_var= shlibpath_overrides_runpath=unknown version_type=none dynamic_linker="$host_os ld.so" sys_lib_dlsearch_path_spec="/lib /usr/lib" need_lib_prefix=unknown hardcode_into_libs=no # when you set need_version to no, make sure it does not cause -set_version # flags to be left without arguments need_version=unknown case $host_os in aix3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. soname_spec='${libname}${release}${shared_ext}$major' ;; aix[4-9]*) version_type=linux need_lib_prefix=no need_version=no hardcode_into_libs=yes if test "$host_cpu" = ia64; then # AIX 5 supports IA64 library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with # the line `#! .'. This would cause the generated library to # depend on `.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[01] | aix4.[01].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' echo '#endif'; } | ${CC} -E - | grep yes > /dev/null; then : else can_build_shared=no fi ;; esac # AIX (on Power*) has no versioning support, so currently we can not hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. if test "$aix_use_runtimelinking" = yes; then # If using run time linking (on AIX 4.2 or later) use lib.so # instead of lib.a to let people know that these are not # typical AIX shared libraries. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' else # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. library_names_spec='${libname}${release}.a $libname.a' soname_spec='${libname}${release}${shared_ext}$major' fi shlibpath_var=LIBPATH fi ;; amigaos*) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`$echo "X$lib" | $Xsed -e '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $rm /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; beos*) library_names_spec='${libname}${shared_ext}' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; bsdi[45]*) version_type=linux need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" # the default ld.so.conf also contains /usr/contrib/lib and # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow # libtool to hard-code these into programs ;; cygwin* | mingw* | pw32*) version_type=windows shrext_cmds=".dll" need_version=no need_lib_prefix=no case $GCC,$host_os in yes,cygwin* | yes,mingw* | yes,pw32*) library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds postinstall_cmds='base_file=`basename \${file}`~ dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i;echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ chmod a+x \$dldir/$dlname' postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ dlpath=$dir/\$dldll~ $rm \$dlpath' shlibpath_overrides_runpath=yes case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec="/usr/lib /lib/w32api /lib /usr/local/lib" ;; mingw*) # MinGW DLLs use traditional 'lib' prefix soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"` if echo "$sys_lib_search_path_spec" | grep ';[c-zC-Z]:/' >/dev/null; then # It is most probably a Windows format PATH printed by # mingw gcc, but we are running on Cygwin. Gcc prints its search # path with ; separators, and with drive letters. We can handle the # drive letters (cygwin fileutils understands them), so leave them, # especially as we might pass files found there to a mingw objdump, # which wouldn't understand a cygwinified path. Ahh. sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` else sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` fi ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' ;; esac ;; *) library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' ;; esac dynamic_linker='Win32 ld.exe' # FIXME: first we should search . and the directory the executable is in shlibpath_var=PATH ;; darwin* | rhapsody*) dynamic_linker="$host_os dyld" version_type=darwin need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${versuffix}$shared_ext ${libname}${release}${major}$shared_ext ${libname}$shared_ext' soname_spec='${libname}${release}${major}$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' ;; dgux*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; freebsd1*) dynamic_linker=no ;; freebsd* | dragonfly*) # DragonFly does not have aout. When/if they implement a new # versioning mechanism, adjust this. if test -x /usr/bin/objformat; then objformat=`/usr/bin/objformat` else case $host_os in freebsd[123]*) objformat=aout ;; *) objformat=elf ;; esac fi version_type=freebsd-$objformat case $version_type in freebsd-elf*) library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' need_version=no need_lib_prefix=no ;; freebsd-*) library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' need_version=yes ;; esac shlibpath_var=LD_LIBRARY_PATH case $host_os in freebsd2*) shlibpath_overrides_runpath=yes ;; freebsd3.[01]* | freebsdelf3.[01]*) shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; *) # from 4.6 on, and DragonFly shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; esac ;; gnu*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes ;; hpux9* | hpux10* | hpux11*) # Give a soname corresponding to the major version so that dld.sl refuses to # link against other versions. version_type=sunos need_lib_prefix=no need_version=no case $host_cpu in ia64*) shrext_cmds='.so' hardcode_into_libs=yes dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' if test "X$HPUX_IA64_MODE" = X32; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" fi sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; hppa*64*) shrext_cmds='.sl' hardcode_into_libs=yes dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; *) shrext_cmds='.sl' dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555. postinstall_cmds='chmod 555 $lib' ;; interix[3-9]*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes ;; irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) if test "$lt_cv_prog_gnu_ld" = yes; then version_type=linux else version_type=irix fi ;; esac need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= ;; *) case $LD in # libtool.m4 will add one of these switches to LD *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") libsuff= shlibsuff= libmagic=32-bit;; *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") libsuff=32 shlibsuff=N32 libmagic=N32;; *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") libsuff=64 shlibsuff=64 libmagic=64-bit;; *) libsuff= shlibsuff= libmagic=never-match;; esac ;; esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" hardcode_into_libs=yes ;; # No shared lib support for Linux oldld, aout, or coff. linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; # This must be Linux ELF. linux* | k*bsd*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no # This implies no fast_install, which is unacceptable. # Some rework will be needed to allow for fast_install # before this can be enabled. hardcode_into_libs=yes # Append ld.so.conf contents to the search path if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '` sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on # powerpc, because MkLinux only supported shared libraries with the # GNU dynamic linker. Since this was broken with cross compilers, # most powerpc-linux boxes support dynamic linking these days and # people can always --disable-shared, the test was removed, and we # assume the GNU/Linux dynamic linker is in use. dynamic_linker='GNU/Linux ld.so' ;; netbsdelf*-gnu) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='NetBSD ld.elf_so' ;; netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | grep __ELF__ >/dev/null; then library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes ;; newsos6) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; nto-qnx*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; openbsd*) version_type=sunos sys_lib_dlsearch_path_spec="/usr/lib" need_lib_prefix=no # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. case $host_os in openbsd3.3 | openbsd3.3.*) need_version=yes ;; *) need_version=no ;; esac library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' shlibpath_var=LD_LIBRARY_PATH if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then case $host_os in openbsd2.[89] | openbsd2.[89].*) shlibpath_overrides_runpath=no ;; *) shlibpath_overrides_runpath=yes ;; esac else shlibpath_overrides_runpath=yes fi ;; os2*) libname_spec='$name' shrext_cmds=".dll" need_lib_prefix=no library_names_spec='$libname${shared_ext} $libname.a' dynamic_linker='OS/2 ld.exe' shlibpath_var=LIBPATH ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no soname_spec='${libname}${release}${shared_ext}$major' library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" ;; rdos*) dynamic_linker=no ;; solaris*) version_type=linux need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes # ldd complains unless libraries are executable postinstall_cmds='chmod +x $lib' ;; sunos4*) version_type=sunos library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes if test "$with_gnu_ld" = yes; then need_lib_prefix=no fi need_version=yes ;; sysv4 | sysv4.3*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) shlibpath_overrides_runpath=no need_lib_prefix=no export_dynamic_flag_spec='${wl}-Blargedynsym' runpath_var=LD_RUN_PATH ;; siemens) need_lib_prefix=no ;; motorola) need_lib_prefix=no need_version=no shlibpath_overrides_runpath=no sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' ;; esac ;; sysv4*MP*) if test -d /usr/nec ;then version_type=linux library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' soname_spec='$libname${shared_ext}.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) version_type=freebsd-elf need_lib_prefix=no need_version=no library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH hardcode_into_libs=yes if test "$with_gnu_ld" = yes; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' shlibpath_overrides_runpath=no else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' shlibpath_overrides_runpath=yes case $host_os in sco3.2v5*) sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" ;; esac fi sys_lib_dlsearch_path_spec='/usr/lib' ;; uts4*) version_type=linux library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' soname_spec='${libname}${release}${shared_ext}$major' shlibpath_var=LD_LIBRARY_PATH ;; *) dynamic_linker=no ;; esac { echo "$as_me:$LINENO: result: $dynamic_linker" >&5 echo "${ECHO_T}$dynamic_linker" >&6; } test "$dynamic_linker" = no && can_build_shared=no if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec" fi sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec" fi sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" variables_saved_for_relink="PATH $shlibpath_var $runpath_var" if test "$GCC" = yes; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi { echo "$as_me:$LINENO: checking how to hardcode library paths into programs" >&5 echo $ECHO_N "checking how to hardcode library paths into programs... $ECHO_C" >&6; } hardcode_action_GCJ= if test -n "$hardcode_libdir_flag_spec_GCJ" || \ test -n "$runpath_var_GCJ" || \ test "X$hardcode_automatic_GCJ" = "Xyes" ; then # We can hardcode non-existant directories. if test "$hardcode_direct_GCJ" != no && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one ## test "$_LT_AC_TAGVAR(hardcode_shlibpath_var, GCJ)" != no && test "$hardcode_minus_L_GCJ" != no; then # Linking always hardcodes the temporary library directory. hardcode_action_GCJ=relink else # We can link without hardcoding, and we can hardcode nonexisting dirs. hardcode_action_GCJ=immediate fi else # We cannot hardcode anything, or else we can only hardcode existing # directories. hardcode_action_GCJ=unsupported fi { echo "$as_me:$LINENO: result: $hardcode_action_GCJ" >&5 echo "${ECHO_T}$hardcode_action_GCJ" >&6; } if test "$hardcode_action_GCJ" = relink; then # Fast installation is not supported enable_fast_install=no elif test "$shlibpath_overrides_runpath" = yes || test "$enable_shared" = no; then # Fast installation is not necessary enable_fast_install=needless fi # The else clause should only fire when bootstrapping the # libtool distribution, otherwise you forgot to ship ltmain.sh # with your package, and you will get complaints that there are # no rules to generate ltmain.sh. if test -f "$ltmain"; then # See if we are running on zsh, and set the options which allow our commands through # without removal of \ escapes. if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi # Now quote all the things that may contain metacharacters while being # careful not to overquote the AC_SUBSTed values. We take copies of the # variables and quote the copies for generation of the libtool script. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ SED SHELL STRIP \ libname_spec library_names_spec soname_spec extract_expsyms_cmds \ old_striplib striplib file_magic_cmd finish_cmds finish_eval \ deplibs_check_method reload_flag reload_cmds need_locks \ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_c_name_address \ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ old_postinstall_cmds old_postuninstall_cmds \ compiler_GCJ \ CC_GCJ \ LD_GCJ \ lt_prog_compiler_wl_GCJ \ lt_prog_compiler_pic_GCJ \ lt_prog_compiler_static_GCJ \ lt_prog_compiler_no_builtin_flag_GCJ \ export_dynamic_flag_spec_GCJ \ thread_safe_flag_spec_GCJ \ whole_archive_flag_spec_GCJ \ enable_shared_with_static_runtimes_GCJ \ old_archive_cmds_GCJ \ old_archive_from_new_cmds_GCJ \ predep_objects_GCJ \ postdep_objects_GCJ \ predeps_GCJ \ postdeps_GCJ \ compiler_lib_search_path_GCJ \ compiler_lib_search_dirs_GCJ \ archive_cmds_GCJ \ archive_expsym_cmds_GCJ \ postinstall_cmds_GCJ \ postuninstall_cmds_GCJ \ old_archive_from_expsyms_cmds_GCJ \ allow_undefined_flag_GCJ \ no_undefined_flag_GCJ \ export_symbols_cmds_GCJ \ hardcode_libdir_flag_spec_GCJ \ hardcode_libdir_flag_spec_ld_GCJ \ hardcode_libdir_separator_GCJ \ hardcode_automatic_GCJ \ module_cmds_GCJ \ module_expsym_cmds_GCJ \ lt_cv_prog_compiler_c_o_GCJ \ fix_srcfile_path_GCJ \ exclude_expsyms_GCJ \ include_expsyms_GCJ; do case $var in old_archive_cmds_GCJ | \ old_archive_from_new_cmds_GCJ | \ archive_cmds_GCJ | \ archive_expsym_cmds_GCJ | \ module_cmds_GCJ | \ module_expsym_cmds_GCJ | \ old_archive_from_expsyms_cmds_GCJ | \ export_symbols_cmds_GCJ | \ extract_expsyms_cmds | reload_cmds | finish_cmds | \ postinstall_cmds | postuninstall_cmds | \ old_postinstall_cmds | old_postuninstall_cmds | \ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) # Double-quote double-evaled strings. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" ;; *) eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; esac done case $lt_echo in *'\$0 --fallback-echo"') lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` ;; esac cfgfile="$ofile" cat <<__EOF__ >> "$cfgfile" # ### BEGIN LIBTOOL TAG CONFIG: $tagname # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc_GCJ # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_GCJ # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # An echo program that does not interpret backslashes. echo=$lt_echo # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A C compiler. LTCC=$lt_LTCC # LTCC compiler flags. LTCFLAGS=$lt_LTCFLAGS # A language-specific compiler. CC=$lt_compiler_GCJ # Is the compiler the GNU C compiler? with_gcc=$GCC_GCJ # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD_GCJ # Whether we need hard or soft links. LN_S=$lt_LN_S # A BSD-compatible nm program. NM=$lt_NM # A symbol stripping program STRIP=$lt_STRIP # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL" # Used on cygwin: object dumper. OBJDUMP="$OBJDUMP" # Used on cygwin: assembler. AS="$AS" # The name of the directory that contains temporary libtool files. objdir=$objdir # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl_GCJ # Object file suffix (normally "o"). objext="$ac_objext" # Old archive suffix (normally "a"). libext="$libext" # Shared library suffix (normally ".so"). shrext_cmds='$shrext_cmds' # Executable file suffix (normally ""). exeext="$exeext" # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic_GCJ pic_mode=$pic_mode # What is the maximum length of a command? max_cmd_len=$lt_cv_sys_max_cmd_len # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o_GCJ # Must we lock files when doing compilation? need_locks=$lt_need_locks # Do we need the lib prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static_GCJ # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_GCJ # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_GCJ # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_GCJ # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec_GCJ # Library versioning type. version_type=$version_type # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Commands used to build and install an old-style archive. RANLIB=$lt_RANLIB old_archive_cmds=$lt_old_archive_cmds_GCJ old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_GCJ # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_GCJ # Commands used to build and install a shared archive. archive_cmds=$lt_archive_cmds_GCJ archive_expsym_cmds=$lt_archive_expsym_cmds_GCJ postinstall_cmds=$lt_postinstall_cmds postuninstall_cmds=$lt_postuninstall_cmds # Commands used to build a loadable module (assumed same as above if empty) module_cmds=$lt_module_cmds_GCJ module_expsym_cmds=$lt_module_expsym_cmds_GCJ # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_predep_objects_GCJ # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects_GCJ # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps_GCJ # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_GCJ # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_GCJ # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_GCJ # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method == file_magic. file_magic_cmd=$lt_file_magic_cmd # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag_GCJ # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_GCJ # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # Same as above, but a single script fragment to be evaled but not shown. finish_eval=$lt_finish_eval # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm in a C name address pair global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # This is the shared library runtime path variable. runpath_var=$runpath_var # This is the shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action_GCJ # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist. hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_GCJ # If ld is used when linking, flag to hardcode \$libdir into # a binary during linking. This must work even if \$libdir does # not exist. hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_GCJ # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_GCJ # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct_GCJ # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L_GCJ # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var_GCJ # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=$hardcode_automatic_GCJ # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="$variables_saved_for_relink" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs_GCJ # Compile-time system search path for libraries sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Run-time system search path for libraries sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec # Fix the shell variable \$srcfile for the compiler. fix_srcfile_path=$lt_fix_srcfile_path # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols_GCJ # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds_GCJ # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms_GCJ # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_GCJ # ### END LIBTOOL TAG CONFIG: $tagname __EOF__ else # If there is no Makefile yet, we rely on a make rule to execute # `config.status --recheck' to rerun these tests and create the # libtool script then. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` if test -f "$ltmain_in"; then test -f Makefile && make "$ltmain" fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC="$lt_save_CC" else tagname="" fi ;; RC) # Source file extension for RC test sources. ac_ext=rc # Object file extension for compiled RC test sources. objext=o objext_RC=$objext # Code to be used in simple compile tests lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' # Code to be used in simple link tests lt_simple_link_test_code="$lt_simple_compile_test_code" # ltmain only uses $CC for tagged configurations so make sure $CC is set. # If no C compiler was specified, use CC. LTCC=${LTCC-"$CC"} # If no C compiler flags were specified, use CFLAGS. LTCFLAGS=${LTCFLAGS-"$CFLAGS"} # Allow CC to be a program name with arguments. compiler=$CC # save warnings/boilerplate of simple test code ac_outfile=conftest.$ac_objext echo "$lt_simple_compile_test_code" >conftest.$ac_ext eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_compiler_boilerplate=`cat conftest.err` $rm conftest* ac_outfile=conftest.$ac_objext echo "$lt_simple_link_test_code" >conftest.$ac_ext eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err _lt_linker_boilerplate=`cat conftest.err` $rm -r conftest* # Allow CC to be a program name with arguments. lt_save_CC="$CC" CC=${RC-"windres"} compiler=$CC compiler_RC=$CC for cc_temp in $compiler""; do case $cc_temp in compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; \-*) ;; *) break;; esac done cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"` lt_cv_prog_compiler_c_o_RC=yes # The else clause should only fire when bootstrapping the # libtool distribution, otherwise you forgot to ship ltmain.sh # with your package, and you will get complaints that there are # no rules to generate ltmain.sh. if test -f "$ltmain"; then # See if we are running on zsh, and set the options which allow our commands through # without removal of \ escapes. if test -n "${ZSH_VERSION+set}" ; then setopt NO_GLOB_SUBST fi # Now quote all the things that may contain metacharacters while being # careful not to overquote the AC_SUBSTed values. We take copies of the # variables and quote the copies for generation of the libtool script. for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \ SED SHELL STRIP \ libname_spec library_names_spec soname_spec extract_expsyms_cmds \ old_striplib striplib file_magic_cmd finish_cmds finish_eval \ deplibs_check_method reload_flag reload_cmds need_locks \ lt_cv_sys_global_symbol_pipe lt_cv_sys_global_symbol_to_cdecl \ lt_cv_sys_global_symbol_to_c_name_address \ sys_lib_search_path_spec sys_lib_dlsearch_path_spec \ old_postinstall_cmds old_postuninstall_cmds \ compiler_RC \ CC_RC \ LD_RC \ lt_prog_compiler_wl_RC \ lt_prog_compiler_pic_RC \ lt_prog_compiler_static_RC \ lt_prog_compiler_no_builtin_flag_RC \ export_dynamic_flag_spec_RC \ thread_safe_flag_spec_RC \ whole_archive_flag_spec_RC \ enable_shared_with_static_runtimes_RC \ old_archive_cmds_RC \ old_archive_from_new_cmds_RC \ predep_objects_RC \ postdep_objects_RC \ predeps_RC \ postdeps_RC \ compiler_lib_search_path_RC \ compiler_lib_search_dirs_RC \ archive_cmds_RC \ archive_expsym_cmds_RC \ postinstall_cmds_RC \ postuninstall_cmds_RC \ old_archive_from_expsyms_cmds_RC \ allow_undefined_flag_RC \ no_undefined_flag_RC \ export_symbols_cmds_RC \ hardcode_libdir_flag_spec_RC \ hardcode_libdir_flag_spec_ld_RC \ hardcode_libdir_separator_RC \ hardcode_automatic_RC \ module_cmds_RC \ module_expsym_cmds_RC \ lt_cv_prog_compiler_c_o_RC \ fix_srcfile_path_RC \ exclude_expsyms_RC \ include_expsyms_RC; do case $var in old_archive_cmds_RC | \ old_archive_from_new_cmds_RC | \ archive_cmds_RC | \ archive_expsym_cmds_RC | \ module_cmds_RC | \ module_expsym_cmds_RC | \ old_archive_from_expsyms_cmds_RC | \ export_symbols_cmds_RC | \ extract_expsyms_cmds | reload_cmds | finish_cmds | \ postinstall_cmds | postuninstall_cmds | \ old_postinstall_cmds | old_postuninstall_cmds | \ sys_lib_search_path_spec | sys_lib_dlsearch_path_spec) # Double-quote double-evaled strings. eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$double_quote_subst\" -e \"\$sed_quote_subst\" -e \"\$delay_variable_subst\"\`\\\"" ;; *) eval "lt_$var=\\\"\`\$echo \"X\$$var\" | \$Xsed -e \"\$sed_quote_subst\"\`\\\"" ;; esac done case $lt_echo in *'\$0 --fallback-echo"') lt_echo=`$echo "X$lt_echo" | $Xsed -e 's/\\\\\\\$0 --fallback-echo"$/$0 --fallback-echo"/'` ;; esac cfgfile="$ofile" cat <<__EOF__ >> "$cfgfile" # ### BEGIN LIBTOOL TAG CONFIG: $tagname # Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: # Shell to use when invoking shell scripts. SHELL=$lt_SHELL # Whether or not to build shared libraries. build_libtool_libs=$enable_shared # Whether or not to build static libraries. build_old_libs=$enable_static # Whether or not to add -lc for building shared libraries. build_libtool_need_lc=$archive_cmds_need_lc_RC # Whether or not to disallow shared libs when runtime libs are static allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_RC # Whether or not to optimize for fast installation. fast_install=$enable_fast_install # The host system. host_alias=$host_alias host=$host host_os=$host_os # The build system. build_alias=$build_alias build=$build build_os=$build_os # An echo program that does not interpret backslashes. echo=$lt_echo # The archiver. AR=$lt_AR AR_FLAGS=$lt_AR_FLAGS # A C compiler. LTCC=$lt_LTCC # LTCC compiler flags. LTCFLAGS=$lt_LTCFLAGS # A language-specific compiler. CC=$lt_compiler_RC # Is the compiler the GNU C compiler? with_gcc=$GCC_RC # An ERE matcher. EGREP=$lt_EGREP # The linker used to build libraries. LD=$lt_LD_RC # Whether we need hard or soft links. LN_S=$lt_LN_S # A BSD-compatible nm program. NM=$lt_NM # A symbol stripping program STRIP=$lt_STRIP # Used to examine libraries when file_magic_cmd begins "file" MAGIC_CMD=$MAGIC_CMD # Used on cygwin: DLL creation program. DLLTOOL="$DLLTOOL" # Used on cygwin: object dumper. OBJDUMP="$OBJDUMP" # Used on cygwin: assembler. AS="$AS" # The name of the directory that contains temporary libtool files. objdir=$objdir # How to create reloadable object files. reload_flag=$lt_reload_flag reload_cmds=$lt_reload_cmds # How to pass a linker flag through the compiler. wl=$lt_lt_prog_compiler_wl_RC # Object file suffix (normally "o"). objext="$ac_objext" # Old archive suffix (normally "a"). libext="$libext" # Shared library suffix (normally ".so"). shrext_cmds='$shrext_cmds' # Executable file suffix (normally ""). exeext="$exeext" # Additional compiler flags for building library objects. pic_flag=$lt_lt_prog_compiler_pic_RC pic_mode=$pic_mode # What is the maximum length of a command? max_cmd_len=$lt_cv_sys_max_cmd_len # Does compiler simultaneously support -c and -o options? compiler_c_o=$lt_lt_cv_prog_compiler_c_o_RC # Must we lock files when doing compilation? need_locks=$lt_need_locks # Do we need the lib prefix for modules? need_lib_prefix=$need_lib_prefix # Do we need a version for libraries? need_version=$need_version # Whether dlopen is supported. dlopen_support=$enable_dlopen # Whether dlopen of programs is supported. dlopen_self=$enable_dlopen_self # Whether dlopen of statically linked programs is supported. dlopen_self_static=$enable_dlopen_self_static # Compiler flag to prevent dynamic linking. link_static_flag=$lt_lt_prog_compiler_static_RC # Compiler flag to turn off builtin functions. no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_RC # Compiler flag to allow reflexive dlopens. export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_RC # Compiler flag to generate shared objects directly from archives. whole_archive_flag_spec=$lt_whole_archive_flag_spec_RC # Compiler flag to generate thread-safe objects. thread_safe_flag_spec=$lt_thread_safe_flag_spec_RC # Library versioning type. version_type=$version_type # Format of library name prefix. libname_spec=$lt_libname_spec # List of archive names. First name is the real one, the rest are links. # The last name is the one that the linker finds with -lNAME. library_names_spec=$lt_library_names_spec # The coded name of the library, if different from the real name. soname_spec=$lt_soname_spec # Commands used to build and install an old-style archive. RANLIB=$lt_RANLIB old_archive_cmds=$lt_old_archive_cmds_RC old_postinstall_cmds=$lt_old_postinstall_cmds old_postuninstall_cmds=$lt_old_postuninstall_cmds # Create an old-style archive from a shared archive. old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_RC # Create a temporary old-style archive to link instead of a shared archive. old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_RC # Commands used to build and install a shared archive. archive_cmds=$lt_archive_cmds_RC archive_expsym_cmds=$lt_archive_expsym_cmds_RC postinstall_cmds=$lt_postinstall_cmds postuninstall_cmds=$lt_postuninstall_cmds # Commands used to build a loadable module (assumed same as above if empty) module_cmds=$lt_module_cmds_RC module_expsym_cmds=$lt_module_expsym_cmds_RC # Commands to strip libraries. old_striplib=$lt_old_striplib striplib=$lt_striplib # Dependencies to place before the objects being linked to create a # shared library. predep_objects=$lt_predep_objects_RC # Dependencies to place after the objects being linked to create a # shared library. postdep_objects=$lt_postdep_objects_RC # Dependencies to place before the objects being linked to create a # shared library. predeps=$lt_predeps_RC # Dependencies to place after the objects being linked to create a # shared library. postdeps=$lt_postdeps_RC # The directories searched by this compiler when creating a shared # library compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_RC # The library search path used internally by the compiler when linking # a shared library. compiler_lib_search_path=$lt_compiler_lib_search_path_RC # Method to check whether dependent libraries are shared objects. deplibs_check_method=$lt_deplibs_check_method # Command to use when deplibs_check_method == file_magic. file_magic_cmd=$lt_file_magic_cmd # Flag that allows shared libraries with undefined symbols to be built. allow_undefined_flag=$lt_allow_undefined_flag_RC # Flag that forces no undefined symbols. no_undefined_flag=$lt_no_undefined_flag_RC # Commands used to finish a libtool library installation in a directory. finish_cmds=$lt_finish_cmds # Same as above, but a single script fragment to be evaled but not shown. finish_eval=$lt_finish_eval # Take the output of nm and produce a listing of raw symbols and C names. global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe # Transform the output of nm in a proper C declaration global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl # Transform the output of nm in a C name address pair global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address # This is the shared library runtime path variable. runpath_var=$runpath_var # This is the shared library path variable. shlibpath_var=$shlibpath_var # Is shlibpath searched before the hard-coded library search path? shlibpath_overrides_runpath=$shlibpath_overrides_runpath # How to hardcode a shared library path into an executable. hardcode_action=$hardcode_action_RC # Whether we should hardcode library paths into libraries. hardcode_into_libs=$hardcode_into_libs # Flag to hardcode \$libdir into a binary during linking. # This must work even if \$libdir does not exist. hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_RC # If ld is used when linking, flag to hardcode \$libdir into # a binary during linking. This must work even if \$libdir does # not exist. hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_RC # Whether we need a single -rpath flag with a separated argument. hardcode_libdir_separator=$lt_hardcode_libdir_separator_RC # Set to yes if using DIR/libNAME${shared_ext} during linking hardcodes DIR into the # resulting binary. hardcode_direct=$hardcode_direct_RC # Set to yes if using the -LDIR flag during linking hardcodes DIR into the # resulting binary. hardcode_minus_L=$hardcode_minus_L_RC # Set to yes if using SHLIBPATH_VAR=DIR during linking hardcodes DIR into # the resulting binary. hardcode_shlibpath_var=$hardcode_shlibpath_var_RC # Set to yes if building a shared library automatically hardcodes DIR into the library # and all subsequent libraries and executables linked against it. hardcode_automatic=$hardcode_automatic_RC # Variables whose values should be saved in libtool wrapper scripts and # restored at relink time. variables_saved_for_relink="$variables_saved_for_relink" # Whether libtool must link a program against all its dependency libraries. link_all_deplibs=$link_all_deplibs_RC # Compile-time system search path for libraries sys_lib_search_path_spec=$lt_sys_lib_search_path_spec # Run-time system search path for libraries sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec # Fix the shell variable \$srcfile for the compiler. fix_srcfile_path=$lt_fix_srcfile_path # Set to yes if exported symbols are required. always_export_symbols=$always_export_symbols_RC # The commands to list exported symbols. export_symbols_cmds=$lt_export_symbols_cmds_RC # The commands to extract the exported symbol list from a shared archive. extract_expsyms_cmds=$lt_extract_expsyms_cmds # Symbols that should not be listed in the preloaded symbols. exclude_expsyms=$lt_exclude_expsyms_RC # Symbols that must always be exported. include_expsyms=$lt_include_expsyms_RC # ### END LIBTOOL TAG CONFIG: $tagname __EOF__ else # If there is no Makefile yet, we rely on a make rule to execute # `config.status --recheck' to rerun these tests and create the # libtool script then. ltmain_in=`echo $ltmain | sed -e 's/\.sh$/.in/'` if test -f "$ltmain_in"; then test -f Makefile && make "$ltmain" fi fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu CC="$lt_save_CC" ;; *) { { echo "$as_me:$LINENO: error: Unsupported tag name: $tagname" >&5 echo "$as_me: error: Unsupported tag name: $tagname" >&2;} { (exit 1); exit 1; }; } ;; esac # Append the new tag name to the list of available tags. if test -n "$tagname" ; then available_tags="$available_tags $tagname" fi fi done IFS="$lt_save_ifs" # Now substitute the updated list of available tags. if eval "sed -e 's/^available_tags=.*\$/available_tags=\"$available_tags\"/' \"$ofile\" > \"${ofile}T\""; then mv "${ofile}T" "$ofile" chmod +x "$ofile" else rm -f "${ofile}T" { { echo "$as_me:$LINENO: error: unable to update list of available tagged configurations." >&5 echo "$as_me: error: unable to update list of available tagged configurations." >&2;} { (exit 1); exit 1; }; } fi fi # This can be used to rebuild libtool when needed LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' # Prevent multiple expansion # Checks for libraries. { echo "$as_me:$LINENO: checking for pow in -lm" >&5 echo $ECHO_N "checking for pow in -lm... $ECHO_C" >&6; } if test "${ac_cv_lib_m_pow+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lm $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char pow (); int main () { return pow (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_m_pow=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_m_pow=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_m_pow" >&5 echo "${ECHO_T}$ac_cv_lib_m_pow" >&6; } if test $ac_cv_lib_m_pow = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_LIBM 1 _ACEOF LIBS="-lm $LIBS" fi { echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6; } if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lpthread $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char pthread_create (); int main () { return pthread_create (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_pthread_pthread_create=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_pthread_pthread_create=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6; } if test $ac_cv_lib_pthread_pthread_create = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_LIBPTHREAD 1 _ACEOF LIBS="-lpthread $LIBS" fi # Checks for header files. { echo "$as_me:$LINENO: checking for ANSI C header files" >&5 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; } if test "${ac_cv_header_stdc+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #include #include int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_header_stdc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi fi { echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 echo "${ECHO_T}$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then cat >>confdefs.h <<\_ACEOF #define STDC_HEADERS 1 _ACEOF fi for ac_header in arpa/inet.h netdb.h netinet/in.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## ----------------------------------- ## ## Report this to support@land.ufrj.br ## ## ----------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done # Checks for typedefs, structures, and compiler characteristics. { echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6; } if test "${ac_cv_c_const+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { /* FIXME: Include the comments suggested by Paul. */ #ifndef __cplusplus /* Ultrix mips cc rejects this. */ typedef int charset[2]; const charset cs; /* SunOS 4.1.1 cc rejects this. */ char const *const *pcpcc; char **ppc; /* NEC SVR4.0.2 mips cc rejects this. */ struct point {int x, y;}; static struct point const zero = {0,0}; /* AIX XL C 1.02.0.0 rejects this. It does not let you subtract one const X* pointer from another in an arm of an if-expression whose if-part is not a constant expression */ const char *g = "string"; pcpcc = &g + (g ? g-g : 0); /* HPUX 7.0 cc rejects these. */ ++pcpcc; ppc = (char**) pcpcc; pcpcc = (char const *const *) ppc; { /* SCO 3.2v4 cc rejects this. */ char *t; char const *s = 0 ? (char *) 0 : (char const *) 0; *t++ = 0; if (s) return 0; } { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ int x[] = {25, 17}; const int *foo = &x[0]; ++foo; } { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ typedef const int *iptr; iptr p = 0; ++p; } { /* AIX XL C 1.02.0.0 rejects this saying "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ struct s { int j; const int *ap[3]; }; struct s *b; b->j = 5; } { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ const int foo = 10; if (!foo) return 0; } return !cs[0] && !zero.x; #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_c_const=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_c_const=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5 echo "${ECHO_T}$ac_cv_c_const" >&6; } if test $ac_cv_c_const = no; then cat >>confdefs.h <<\_ACEOF #define const _ACEOF fi { echo "$as_me:$LINENO: checking for inline" >&5 echo $ECHO_N "checking for inline... $ECHO_C" >&6; } if test "${ac_cv_c_inline+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_c_inline=no for ac_kw in inline __inline__ __inline; do cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #ifndef __cplusplus typedef int foo_t; static $ac_kw foo_t static_foo () {return 0; } $ac_kw foo_t foo () {return 0; } #endif _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_c_inline=$ac_kw else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext test "$ac_cv_c_inline" != no && break done fi { echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5 echo "${ECHO_T}$ac_cv_c_inline" >&6; } case $ac_cv_c_inline in inline | yes) ;; *) case $ac_cv_c_inline in no) ac_val=;; *) ac_val=$ac_cv_c_inline;; esac cat >>confdefs.h <<_ACEOF #ifndef __cplusplus #define inline $ac_val #endif _ACEOF ;; esac { echo "$as_me:$LINENO: checking for size_t" >&5 echo $ECHO_N "checking for size_t... $ECHO_C" >&6; } if test "${ac_cv_type_size_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default typedef size_t ac__type_new_; int main () { if ((ac__type_new_ *) 0) return 0; if (sizeof (ac__type_new_)) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_type_size_t=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_type_size_t=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5 echo "${ECHO_T}$ac_cv_type_size_t" >&6; } if test $ac_cv_type_size_t = yes; then : else cat >>confdefs.h <<_ACEOF #define size_t unsigned int _ACEOF fi { echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5 echo $ECHO_N "checking whether sys_siglist is declared... $ECHO_C" >&6; } if test "${ac_cv_have_decl_sys_siglist+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { #ifndef sys_siglist (void) sys_siglist; #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_have_decl_sys_siglist=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_have_decl_sys_siglist=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5 echo "${ECHO_T}$ac_cv_have_decl_sys_siglist" >&6; } if test $ac_cv_have_decl_sys_siglist = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_DECL_SYS_SIGLIST 1 _ACEOF else cat >>confdefs.h <<_ACEOF #define HAVE_DECL_SYS_SIGLIST 0 _ACEOF fi { echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6; } if test "${ac_cv_header_time+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include #include int main () { if ((struct tm *) 0) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_header_time=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_header_time=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5 echo "${ECHO_T}$ac_cv_header_time" >&6; } if test $ac_cv_header_time = yes; then cat >>confdefs.h <<\_ACEOF #define TIME_WITH_SYS_TIME 1 _ACEOF fi { echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5 echo $ECHO_N "checking whether struct tm is in sys/time.h or time.h... $ECHO_C" >&6; } if test "${ac_cv_struct_tm+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include int main () { struct tm tm; int *p = &tm.tm_sec; return !p; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_struct_tm=time.h else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_struct_tm=sys/time.h fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5 echo "${ECHO_T}$ac_cv_struct_tm" >&6; } if test $ac_cv_struct_tm = sys/time.h; then cat >>confdefs.h <<\_ACEOF #define TM_IN_SYS_TIME 1 _ACEOF fi # Checks for library functions. ac_header_dirent=no for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include <$ac_hdr> int main () { if ((DIR *) 0) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then eval "$as_ac_Header=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_Header=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 _ACEOF ac_header_dirent=$ac_hdr; break fi done # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. if test $ac_header_dirent = dirent.h; then { echo "$as_me:$LINENO: checking for library containing opendir" >&5 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6; } if test "${ac_cv_search_opendir+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_func_search_save_LIBS=$LIBS cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char opendir (); int main () { return opendir (); ; return 0; } _ACEOF for ac_lib in '' dir; do if test -z "$ac_lib"; then ac_res="none required" else ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_search_opendir=$ac_res else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext if test "${ac_cv_search_opendir+set}" = set; then break fi done if test "${ac_cv_search_opendir+set}" = set; then : else ac_cv_search_opendir=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 echo "${ECHO_T}$ac_cv_search_opendir" >&6; } ac_res=$ac_cv_search_opendir if test "$ac_res" != no; then test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi else { echo "$as_me:$LINENO: checking for library containing opendir" >&5 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6; } if test "${ac_cv_search_opendir+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_func_search_save_LIBS=$LIBS cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char opendir (); int main () { return opendir (); ; return 0; } _ACEOF for ac_lib in '' x; do if test -z "$ac_lib"; then ac_res="none required" else ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_search_opendir=$ac_res else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext if test "${ac_cv_search_opendir+set}" = set; then break fi done if test "${ac_cv_search_opendir+set}" = set; then : else ac_cv_search_opendir=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 echo "${ECHO_T}$ac_cv_search_opendir" >&6; } ac_res=$ac_cv_search_opendir if test "$ac_res" != no; then test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi fi { echo "$as_me:$LINENO: checking whether closedir returns void" >&5 echo $ECHO_N "checking whether closedir returns void... $ECHO_C" >&6; } if test "${ac_cv_func_closedir_void+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_closedir_void=yes else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header_dirent> #ifndef __cplusplus int closedir (); #endif int main () { return closedir (opendir (".")) != 0; ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_closedir_void=no else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_closedir_void=yes fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_closedir_void" >&5 echo "${ECHO_T}$ac_cv_func_closedir_void" >&6; } if test $ac_cv_func_closedir_void = yes; then cat >>confdefs.h <<\_ACEOF #define CLOSEDIR_VOID 1 _ACEOF fi { echo "$as_me:$LINENO: checking for pid_t" >&5 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6; } if test "${ac_cv_type_pid_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default typedef pid_t ac__type_new_; int main () { if ((ac__type_new_ *) 0) return 0; if (sizeof (ac__type_new_)) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_type_pid_t=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_type_pid_t=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5 echo "${ECHO_T}$ac_cv_type_pid_t" >&6; } if test $ac_cv_type_pid_t = yes; then : else cat >>confdefs.h <<_ACEOF #define pid_t int _ACEOF fi for ac_header in vfork.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## ----------------------------------- ## ## Report this to support@land.ufrj.br ## ## ----------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_func in fork vfork do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Define $ac_func to an innocuous variant, in case declares $ac_func. For example, HP-UX 11i declares gettimeofday. */ #define $ac_func innocuous_$ac_func /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef $ac_func /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $ac_func (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$ac_func || defined __stub___$ac_func choke me #endif int main () { return $ac_func (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then eval "$as_ac_var=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_var=no" fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_var'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done if test "x$ac_cv_func_fork" = xyes; then { echo "$as_me:$LINENO: checking for working fork" >&5 echo $ECHO_N "checking for working fork... $ECHO_C" >&6; } if test "${ac_cv_func_fork_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_fork_works=cross else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { /* By Ruediger Kuhlmann. */ return fork () < 0; ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_fork_works=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_fork_works=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5 echo "${ECHO_T}$ac_cv_func_fork_works" >&6; } else ac_cv_func_fork_works=$ac_cv_func_fork fi if test "x$ac_cv_func_fork_works" = xcross; then case $host in *-*-amigaos* | *-*-msdosdjgpp*) # Override, as these systems have only a dummy fork() stub ac_cv_func_fork_works=no ;; *) ac_cv_func_fork_works=yes ;; esac { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} fi ac_cv_func_vfork_works=$ac_cv_func_vfork if test "x$ac_cv_func_vfork" = xyes; then { echo "$as_me:$LINENO: checking for working vfork" >&5 echo $ECHO_N "checking for working vfork... $ECHO_C" >&6; } if test "${ac_cv_func_vfork_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_vfork_works=cross else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Thanks to Paul Eggert for this test. */ $ac_includes_default #include #ifdef HAVE_VFORK_H # include #endif /* On some sparc systems, changes by the child to local and incoming argument registers are propagated back to the parent. The compiler is told about this with #include , but some compilers (e.g. gcc -O) don't grok . Test for this by using a static variable whose address is put into a register that is clobbered by the vfork. */ static void #ifdef __cplusplus sparc_address_test (int arg) # else sparc_address_test (arg) int arg; #endif { static pid_t child; if (!child) { child = vfork (); if (child < 0) { perror ("vfork"); _exit(2); } if (!child) { arg = getpid(); write(-1, "", 0); _exit (arg); } } } int main () { pid_t parent = getpid (); pid_t child; sparc_address_test (0); child = vfork (); if (child == 0) { /* Here is another test for sparc vfork register problems. This test uses lots of local variables, at least as many local variables as main has allocated so far including compiler temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should reuse the register of parent for one of the local variables, since it will think that parent can't possibly be used any more in this routine. Assigning to the local variable will thus munge parent in the parent process. */ pid_t p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); /* Convince the compiler that p..p7 are live; otherwise, it might use the same hardware register for all 8 local variables. */ if (p != p1 || p != p2 || p != p3 || p != p4 || p != p5 || p != p6 || p != p7) _exit(1); /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent from child file descriptors. If the child closes a descriptor before it execs or exits, this munges the parent's descriptor as well. Test for this by closing stdout in the child. */ _exit(close(fileno(stdout)) != 0); } else { int status; struct stat st; while (wait(&status) != child) ; return ( /* Was there some problem with vforking? */ child < 0 /* Did the child fail? (This shouldn't happen.) */ || status /* Did the vfork/compiler bug occur? */ || parent != getpid() /* Did the file descriptor bug occur? */ || fstat(fileno(stdout), &st) != 0 ); } } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_vfork_works=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_vfork_works=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5 echo "${ECHO_T}$ac_cv_func_vfork_works" >&6; } fi; if test "x$ac_cv_func_fork_works" = xcross; then ac_cv_func_vfork_works=$ac_cv_func_vfork { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} fi if test "x$ac_cv_func_vfork_works" = xyes; then cat >>confdefs.h <<\_ACEOF #define HAVE_WORKING_VFORK 1 _ACEOF else cat >>confdefs.h <<\_ACEOF #define vfork fork _ACEOF fi if test "x$ac_cv_func_fork_works" = xyes; then cat >>confdefs.h <<\_ACEOF #define HAVE_WORKING_FORK 1 _ACEOF fi for ac_header in stdlib.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## ----------------------------------- ## ## Report this to support@land.ufrj.br ## ## ----------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done { echo "$as_me:$LINENO: checking for GNU libc compatible malloc" >&5 echo $ECHO_N "checking for GNU libc compatible malloc... $ECHO_C" >&6; } if test "${ac_cv_func_malloc_0_nonnull+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_malloc_0_nonnull=no else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #if defined STDC_HEADERS || defined HAVE_STDLIB_H # include #else char *malloc (); #endif int main () { return ! malloc (0); ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_malloc_0_nonnull=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_malloc_0_nonnull=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_malloc_0_nonnull" >&5 echo "${ECHO_T}$ac_cv_func_malloc_0_nonnull" >&6; } if test $ac_cv_func_malloc_0_nonnull = yes; then cat >>confdefs.h <<\_ACEOF #define HAVE_MALLOC 1 _ACEOF else cat >>confdefs.h <<\_ACEOF #define HAVE_MALLOC 0 _ACEOF case " $LIBOBJS " in *" malloc.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS malloc.$ac_objext" ;; esac cat >>confdefs.h <<\_ACEOF #define malloc rpl_malloc _ACEOF fi for ac_header in stdlib.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## ----------------------------------- ## ## Report this to support@land.ufrj.br ## ## ----------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done { echo "$as_me:$LINENO: checking for GNU libc compatible realloc" >&5 echo $ECHO_N "checking for GNU libc compatible realloc... $ECHO_C" >&6; } if test "${ac_cv_func_realloc_0_nonnull+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_realloc_0_nonnull=no else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #if defined STDC_HEADERS || defined HAVE_STDLIB_H # include #else char *realloc (); #endif int main () { return ! realloc (0, 0); ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_realloc_0_nonnull=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_realloc_0_nonnull=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_realloc_0_nonnull" >&5 echo "${ECHO_T}$ac_cv_func_realloc_0_nonnull" >&6; } if test $ac_cv_func_realloc_0_nonnull = yes; then cat >>confdefs.h <<\_ACEOF #define HAVE_REALLOC 1 _ACEOF else cat >>confdefs.h <<\_ACEOF #define HAVE_REALLOC 0 _ACEOF case " $LIBOBJS " in *" realloc.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS realloc.$ac_objext" ;; esac cat >>confdefs.h <<\_ACEOF #define realloc rpl_realloc _ACEOF fi for ac_header in sys/select.h sys/socket.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## ----------------------------------- ## ## Report this to support@land.ufrj.br ## ## ----------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done { echo "$as_me:$LINENO: checking types of arguments for select" >&5 echo $ECHO_N "checking types of arguments for select... $ECHO_C" >&6; } if test "${ac_cv_func_select_args+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else for ac_arg234 in 'fd_set *' 'int *' 'void *'; do for ac_arg1 in 'int' 'size_t' 'unsigned long int' 'unsigned int'; do for ac_arg5 in 'struct timeval *' 'const struct timeval *'; do cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #ifdef HAVE_SYS_SELECT_H # include #endif #ifdef HAVE_SYS_SOCKET_H # include #endif int main () { extern int select ($ac_arg1, $ac_arg234, $ac_arg234, $ac_arg234, $ac_arg5); ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_func_select_args="$ac_arg1,$ac_arg234,$ac_arg5"; break 3 else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext done done done # Provide a safe default value. : ${ac_cv_func_select_args='int,int *,struct timeval *'} fi { echo "$as_me:$LINENO: result: $ac_cv_func_select_args" >&5 echo "${ECHO_T}$ac_cv_func_select_args" >&6; } ac_save_IFS=$IFS; IFS=',' set dummy `echo "$ac_cv_func_select_args" | sed 's/\*/\*/g'` IFS=$ac_save_IFS shift cat >>confdefs.h <<_ACEOF #define SELECT_TYPE_ARG1 $1 _ACEOF cat >>confdefs.h <<_ACEOF #define SELECT_TYPE_ARG234 ($2) _ACEOF cat >>confdefs.h <<_ACEOF #define SELECT_TYPE_ARG5 ($3) _ACEOF rm -f conftest* { echo "$as_me:$LINENO: checking for function prototypes" >&5 echo $ECHO_N "checking for function prototypes... $ECHO_C" >&6; } if test "$ac_cv_prog_cc_c89" != no; then { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } cat >>confdefs.h <<\_ACEOF #define PROTOTYPES 1 _ACEOF cat >>confdefs.h <<\_ACEOF #define __PROTOTYPES 1 _ACEOF else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi { echo "$as_me:$LINENO: checking whether setvbuf arguments are reversed" >&5 echo $ECHO_N "checking whether setvbuf arguments are reversed... $ECHO_C" >&6; } if test "${ac_cv_func_setvbuf_reversed+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_func_setvbuf_reversed=no cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include # ifdef PROTOTYPES int (setvbuf) (FILE *, int, char *, size_t); # endif int main () { char buf; return setvbuf (stdout, _IOLBF, &buf, 1); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include # ifdef PROTOTYPES int (setvbuf) (FILE *, int, char *, size_t); # endif int main () { char buf; return setvbuf (stdout, &buf, _IOLBF, 1); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then # It compiles and links either way, so it must not be declared # with a prototype and most likely this is a K&R C compiler. # Try running it. if test "$cross_compiling" = yes; then : # Assume setvbuf is not reversed when cross-compiling. else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { /* This call has the arguments reversed. A reversed system may check and see that the address of buf is not _IOLBF, _IONBF, or _IOFBF, and return nonzero. */ char buf; if (setvbuf (stdout, _IOLBF, &buf, 1) != 0) return 1; putchar ('\r'); return 0; /* Non-reversed systems SEGV here. */ ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_setvbuf_reversed=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi ac_cv_func_setvbuf_reversed=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_func_setvbuf_reversed" >&5 echo "${ECHO_T}$ac_cv_func_setvbuf_reversed" >&6; } if test $ac_cv_func_setvbuf_reversed = yes; then cat >>confdefs.h <<\_ACEOF #define SETVBUF_REVERSED 1 _ACEOF fi { echo "$as_me:$LINENO: checking return type of signal handlers" >&5 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6; } if test "${ac_cv_type_signal+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include #include int main () { return *(signal (0, 0)) (0) == 1; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_type_signal=int else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_type_signal=void fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5 echo "${ECHO_T}$ac_cv_type_signal" >&6; } cat >>confdefs.h <<_ACEOF #define RETSIGTYPE $ac_cv_type_signal _ACEOF for ac_func in alarm bzero gethostbyname gethostname gettimeofday inet_ntoa memset pow putenv select setlocale socket strchr strdup strerror strstr do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Define $ac_func to an innocuous variant, in case declares $ac_func. For example, HP-UX 11i declares gettimeofday. */ #define $ac_func innocuous_$ac_func /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. Prefer to if __STDC__ is defined, since exists even on freestanding compilers. */ #ifdef __STDC__ # include #else # include #endif #undef $ac_func /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $ac_func (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$ac_func || defined __stub___$ac_func choke me #endif int main () { return $ac_func (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then eval "$as_ac_var=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_var=no" fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_var'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done ac_config_files="$ac_config_files Makefile src/Makefile mcastproxy/Makefile rmchat/Makefile" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure # scripts and configure runs, see configure's option --config-cache. # It is not useful on other systems. If it contains results you don't # want to keep, you may remove or edit it. # # config.status only pays attention to the cache file if you give it # the --recheck option to rerun configure. # # `ac_cv_env_foo' variables (set or unset) will be overridden when # loading this file, other *unset* `ac_cv_foo' will be assigned the # following values. _ACEOF # The following way of writing the cache mishandles newlines in values, # but we know of no workaround that is simple, portable, and efficient. # So, we kill variables containing newlines. # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. ( for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( *) $as_unset $ac_var ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) # `set' does not quote correctly, so add quotes (double-quote # substitution turns \\\\ into \\, and sed turns \\ into \). sed -n \ "s/'/'\\\\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" ;; #( *) # `set' quotes correctly as required by POSIX, so do not add quotes. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) | sed ' /^ac_cv_env_/b end t clear :clear s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ t end s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then test "x$cache_file" != "x/dev/null" && { echo "$as_me:$LINENO: updating cache $cache_file" >&5 echo "$as_me: updating cache $cache_file" >&6;} cat confcache >$cache_file else { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5 echo "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi rm -f confcache test "x$prefix" = xNONE && prefix=$ac_default_prefix # Let make expand exec_prefix. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' DEFS=-DHAVE_CONFIG_H ac_libobjs= ac_ltlibobjs= for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue # 1. Remove the extension, and $U if already installed. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' ac_i=`echo "$ac_i" | sed "$ac_script"` # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR # will be set to the directory where LIBOBJS objects are built. ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext" ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo' done LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCXX\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"am__fastdepCXX\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi : ${CONFIG_STATUS=./config.status} ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5 echo "$as_me: creating $CONFIG_STATUS" >&6;} cat >$CONFIG_STATUS <<_ACEOF #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. # Compiler output produced by configure, useful for debugging # configure, is in config.log if it exists. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi # PATH needs CR # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset else as_unset=false fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) as_nl=' ' IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. case $0 in *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 { (exit 1); exit 1; } fi # Work around bugs in pre-3.0 UWIN ksh. for as_var in ENV MAIL MAILPATH do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. for as_var in \ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ LC_TELEPHONE LC_TIME do if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then eval $as_var=C; export $as_var else ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var fi done # Required to use basename. if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi # Name of the executable. as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # CDPATH. $as_unset CDPATH as_lineno_1=$LINENO as_lineno_2=$LINENO test "x$as_lineno_1" != "x$as_lineno_2" && test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || { # Create $as_me.lineno as a copy of $as_myself, but with $LINENO # uniformly replaced by the line number. The first 'sed' inserts a # line-number line after each line using $LINENO; the second 'sed' # does the real work. The second script uses 'N' to pair each # line-number line with the line containing $LINENO, and appends # trailing '-' during substitution so that $LINENO is not a special # case at line end. # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the # scripts with optimization help from Paolo Bonzini. Blame Lee # E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 { (exit 1); exit 1; }; } # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in -n*) case `echo 'x\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. *) ECHO_C='\c';; esac;; *) ECHO_N='-n';; esac if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir fi echo >conf$$.file if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p=: else test -d ./-p && rmdir ./-p as_mkdir_p=false fi if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 # Save the log message, to keep $[0] and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by rmcast $as_me 2.0.0, which was generated by GNU Autoconf 2.61. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ on `(hostname || uname -n) 2>/dev/null | sed 1q` " _ACEOF cat >>$CONFIG_STATUS <<_ACEOF # Files that config.status was made for. config_files="$ac_config_files" config_headers="$ac_config_headers" config_commands="$ac_config_commands" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF ac_cs_usage="\ \`$as_me' instantiates files from templates according to the current configuration. Usage: $0 [OPTIONS] [FILE]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit -q, --quiet do not print progress messages -d, --debug don't remove temporary files --recheck update $as_me by reconfiguring in the same conditions --file=FILE[:TEMPLATE] instantiate the configuration file FILE --header=FILE[:TEMPLATE] instantiate the configuration header FILE Configuration files: $config_files Configuration headers: $config_headers Configuration commands: $config_commands Report bugs to ." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF ac_cs_version="\\ rmcast config.status 2.0.0 configured by $0, generated by GNU Autoconf 2.61, with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" Copyright (C) 2006 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='$ac_pwd' srcdir='$srcdir' INSTALL='$INSTALL' _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # If no file are specified by the user, then we need to provide default # value. By we need to know if files were specified by the user. ac_need_defaults=: while test $# != 0 do case $1 in --*=*) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` ac_shift=: ;; *) ac_option=$1 ac_optarg=$2 ac_shift=shift ;; esac case $ac_option in # Handling of the options. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) echo "$ac_cs_version"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift CONFIG_FILES="$CONFIG_FILES $ac_optarg" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg" ac_need_defaults=false;; --he | --h) # Conflict between --help and --header { echo "$as_me: error: ambiguous option: $1 Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; };; --help | --hel | -h ) echo "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) { echo "$as_me: error: unrecognized option: $1 Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; } ;; *) ac_config_targets="$ac_config_targets $1" ac_need_defaults=false ;; esac shift done ac_configure_extra_args= if $ac_cs_silent; then exec 6>/dev/null ac_configure_extra_args="$ac_configure_extra_args --silent" fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF if \$ac_cs_recheck; then echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6 CONFIG_SHELL=$SHELL export CONFIG_SHELL exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion fi _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX echo "$ac_log" } >&5 _ACEOF cat >>$CONFIG_STATUS <<_ACEOF # # INIT-COMMANDS # AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # Handling of arguments. for ac_config_target in $ac_config_targets do case $ac_config_target in "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; "mcastproxy/Makefile") CONFIG_FILES="$CONFIG_FILES mcastproxy/Makefile" ;; "rmchat/Makefile") CONFIG_FILES="$CONFIG_FILES rmchat/Makefile" ;; *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 echo "$as_me: error: invalid argument: $ac_config_target" >&2;} { (exit 1); exit 1; }; };; esac done # If the user did not use the arguments to specify the items to instantiate, # then the envvar interface is used. Set only those that are not. # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason against having it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: # after its creation but before its name has been assigned to `$tmp'. $debug || { tmp= trap 'exit_status=$? { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status ' 0 trap '{ (exit 1); exit 1; }' 1 2 13 15 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || { echo "$me: cannot create a temporary directory in ." >&2 { (exit 1); exit 1; } } # # Set up the sed scripts for CONFIG_FILES section. # # No need to generate the scripts if there are no CONFIG_FILES. # This happens for instance when ./config.status config.h if test -n "$CONFIG_FILES"; then _ACEOF ac_delim='%!_!# ' for ac_last_try in false false false false false :; do cat >conf$$subs.sed <<_ACEOF SHELL!$SHELL$ac_delim PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim PACKAGE_NAME!$PACKAGE_NAME$ac_delim PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim PACKAGE_STRING!$PACKAGE_STRING$ac_delim PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim exec_prefix!$exec_prefix$ac_delim prefix!$prefix$ac_delim program_transform_name!$program_transform_name$ac_delim bindir!$bindir$ac_delim sbindir!$sbindir$ac_delim libexecdir!$libexecdir$ac_delim datarootdir!$datarootdir$ac_delim datadir!$datadir$ac_delim sysconfdir!$sysconfdir$ac_delim sharedstatedir!$sharedstatedir$ac_delim localstatedir!$localstatedir$ac_delim includedir!$includedir$ac_delim oldincludedir!$oldincludedir$ac_delim docdir!$docdir$ac_delim infodir!$infodir$ac_delim htmldir!$htmldir$ac_delim dvidir!$dvidir$ac_delim pdfdir!$pdfdir$ac_delim psdir!$psdir$ac_delim libdir!$libdir$ac_delim localedir!$localedir$ac_delim mandir!$mandir$ac_delim DEFS!$DEFS$ac_delim ECHO_C!$ECHO_C$ac_delim ECHO_N!$ECHO_N$ac_delim ECHO_T!$ECHO_T$ac_delim LIBS!$LIBS$ac_delim build_alias!$build_alias$ac_delim host_alias!$host_alias$ac_delim target_alias!$target_alias$ac_delim INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim INSTALL_DATA!$INSTALL_DATA$ac_delim CYGPATH_W!$CYGPATH_W$ac_delim PACKAGE!$PACKAGE$ac_delim VERSION!$VERSION$ac_delim ACLOCAL!$ACLOCAL$ac_delim AUTOCONF!$AUTOCONF$ac_delim AUTOMAKE!$AUTOMAKE$ac_delim AUTOHEADER!$AUTOHEADER$ac_delim MAKEINFO!$MAKEINFO$ac_delim install_sh!$install_sh$ac_delim STRIP!$STRIP$ac_delim INSTALL_STRIP_PROGRAM!$INSTALL_STRIP_PROGRAM$ac_delim mkdir_p!$mkdir_p$ac_delim AWK!$AWK$ac_delim SET_MAKE!$SET_MAKE$ac_delim am__leading_dot!$am__leading_dot$ac_delim AMTAR!$AMTAR$ac_delim am__tar!$am__tar$ac_delim am__untar!$am__untar$ac_delim CC!$CC$ac_delim CFLAGS!$CFLAGS$ac_delim LDFLAGS!$LDFLAGS$ac_delim CPPFLAGS!$CPPFLAGS$ac_delim ac_ct_CC!$ac_ct_CC$ac_delim EXEEXT!$EXEEXT$ac_delim OBJEXT!$OBJEXT$ac_delim DEPDIR!$DEPDIR$ac_delim am__include!$am__include$ac_delim am__quote!$am__quote$ac_delim AMDEP_TRUE!$AMDEP_TRUE$ac_delim AMDEP_FALSE!$AMDEP_FALSE$ac_delim AMDEPBACKSLASH!$AMDEPBACKSLASH$ac_delim CCDEPMODE!$CCDEPMODE$ac_delim am__fastdepCC_TRUE!$am__fastdepCC_TRUE$ac_delim am__fastdepCC_FALSE!$am__fastdepCC_FALSE$ac_delim build!$build$ac_delim build_cpu!$build_cpu$ac_delim build_vendor!$build_vendor$ac_delim build_os!$build_os$ac_delim host!$host$ac_delim host_cpu!$host_cpu$ac_delim host_vendor!$host_vendor$ac_delim host_os!$host_os$ac_delim SED!$SED$ac_delim GREP!$GREP$ac_delim EGREP!$EGREP$ac_delim LN_S!$LN_S$ac_delim ECHO!$ECHO$ac_delim AR!$AR$ac_delim RANLIB!$RANLIB$ac_delim DSYMUTIL!$DSYMUTIL$ac_delim NMEDIT!$NMEDIT$ac_delim CPP!$CPP$ac_delim CXX!$CXX$ac_delim CXXFLAGS!$CXXFLAGS$ac_delim ac_ct_CXX!$ac_ct_CXX$ac_delim CXXDEPMODE!$CXXDEPMODE$ac_delim am__fastdepCXX_TRUE!$am__fastdepCXX_TRUE$ac_delim _ACEOF if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then break elif $ac_last_try; then { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} { (exit 1); exit 1; }; } else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed` if test -n "$ac_eof"; then ac_eof=`echo "$ac_eof" | sort -nru | sed 1q` ac_eof=`expr $ac_eof + 1` fi cat >>$CONFIG_STATUS <<_ACEOF cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof /@[a-zA-Z_][a-zA-Z_0-9]*@/!b _ACEOF sed ' s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g s/^/s,@/; s/!/@,|#_!!_#|/ :n t n s/'"$ac_delim"'$/,g/; t s/$/\\/; p N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n ' >>$CONFIG_STATUS >$CONFIG_STATUS <<_ACEOF CEOF$ac_eof _ACEOF ac_delim='%!_!# ' for ac_last_try in false false false false false :; do cat >conf$$subs.sed <<_ACEOF am__fastdepCXX_FALSE!$am__fastdepCXX_FALSE$ac_delim CXXCPP!$CXXCPP$ac_delim F77!$F77$ac_delim FFLAGS!$FFLAGS$ac_delim ac_ct_F77!$ac_ct_F77$ac_delim LIBTOOL!$LIBTOOL$ac_delim LIBOBJS!$LIBOBJS$ac_delim LTLIBOBJS!$LTLIBOBJS$ac_delim _ACEOF if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 8; then break elif $ac_last_try; then { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} { (exit 1); exit 1; }; } else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed` if test -n "$ac_eof"; then ac_eof=`echo "$ac_eof" | sort -nru | sed 1q` ac_eof=`expr $ac_eof + 1` fi cat >>$CONFIG_STATUS <<_ACEOF cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof /@[a-zA-Z_][a-zA-Z_0-9]*@/!b end _ACEOF sed ' s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g s/^/s,@/; s/!/@,|#_!!_#|/ :n t n s/'"$ac_delim"'$/,g/; t s/$/\\/; p N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n ' >>$CONFIG_STATUS >$CONFIG_STATUS <<_ACEOF :end s/|#_!!_#|//g CEOF$ac_eof _ACEOF # VPATH may cause trouble with some makes, so we remove $(srcdir), # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and # trailing colons and then remove the whole line if VPATH becomes empty # (actually we leave an empty line to preserve line numbers). if test "x$srcdir" = x.; then ac_vpsub='/^[ ]*VPATH[ ]*=/{ s/:*\$(srcdir):*/:/ s/:*\${srcdir}:*/:/ s/:*@srcdir@:*/:/ s/^\([^=]*=[ ]*\):*/\1/ s/:*$// s/^[^=]*=[ ]*$// }' fi cat >>$CONFIG_STATUS <<\_ACEOF fi # test -n "$CONFIG_FILES" for ac_tag in :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS do case $ac_tag in :[FHLC]) ac_mode=$ac_tag; continue;; esac case $ac_mode$ac_tag in :[FHL]*:*);; :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5 echo "$as_me: error: Invalid tag $ac_tag." >&2;} { (exit 1); exit 1; }; };; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac ac_save_IFS=$IFS IFS=: set x $ac_tag IFS=$ac_save_IFS shift ac_file=$1 shift case $ac_mode in :L) ac_source=$1;; :[FH]) ac_file_inputs= for ac_f do case $ac_f in -) ac_f="$tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, # because $ac_f cannot contain `:'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5 echo "$as_me: error: cannot find input file: $ac_f" >&2;} { (exit 1); exit 1; }; };; esac ac_file_inputs="$ac_file_inputs $ac_f" done # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input="Generated from "`IFS=: echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure." if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { echo "$as_me:$LINENO: creating $ac_file" >&5 echo "$as_me: creating $ac_file" >&6;} fi case $ac_tag in *:-:* | *:-) cat >"$tmp/stdin";; esac ;; esac ac_dir=`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` { as_dir="$ac_dir" case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 echo "$as_me: error: cannot create directory $as_dir" >&2;} { (exit 1); exit 1; }; }; } ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix case $ac_mode in :F) # # CONFIG_FILE # case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= case `sed -n '/datarootdir/ { p q } /@datadir@/p /@docdir@/p /@infodir@/p /@localedir@/p /@mandir@/p ' $ac_file_inputs` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF cat >>$CONFIG_STATUS <<_ACEOF ac_datarootdir_hack=' s&@datadir@&$datadir&g s&@docdir@&$docdir&g s&@infodir@&$infodir&g s&@localedir@&$localedir&g s&@mandir@&$mandir&g s&\\\${datarootdir}&$datarootdir&g' ;; esac _ACEOF # Neutralize VPATH when `$srcdir' = `.'. # Shell code in configure.ac might set extrasub. # FIXME: do we really want to maintain this feature? cat >>$CONFIG_STATUS <<_ACEOF sed "$ac_vpsub $extrasub _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s&@configure_input@&$configure_input&;t t s&@top_builddir@&$ac_top_builddir_sub&;t t s&@srcdir@&$ac_srcdir&;t t s&@abs_srcdir@&$ac_abs_srcdir&;t t s&@top_srcdir@&$ac_top_srcdir&;t t s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t s&@builddir@&$ac_builddir&;t t s&@abs_builddir@&$ac_abs_builddir&;t t s&@abs_top_builddir@&$ac_abs_top_builddir&;t t s&@INSTALL@&$ac_INSTALL&;t t $ac_datarootdir_hack " $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&5 echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&2;} rm -f "$tmp/stdin" case $ac_file in -) cat "$tmp/out"; rm -f "$tmp/out";; *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;; esac ;; :H) # # CONFIG_HEADER # _ACEOF # Transform confdefs.h into a sed script `conftest.defines', that # substitutes the proper values into config.h.in to produce config.h. rm -f conftest.defines conftest.tail # First, append a space to every undef/define line, to ease matching. echo 's/$/ /' >conftest.defines # Then, protect against being on the right side of a sed subst, or in # an unquoted here document, in config.status. If some macros were # called several times there might be several #defines for the same # symbol, which is useless. But do not sort them, since the last # AC_DEFINE must be honored. ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* # These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where # NAME is the cpp macro being defined, VALUE is the value it is being given. # PARAMS is the parameter list in the macro definition--in most cases, it's # just an empty string. ac_dA='s,^\\([ #]*\\)[^ ]*\\([ ]*' ac_dB='\\)[ (].*,\\1define\\2' ac_dC=' ' ac_dD=' ,' uniq confdefs.h | sed -n ' t rset :rset s/^[ ]*#[ ]*define[ ][ ]*// t ok d :ok s/[\\&,]/\\&/g s/^\('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p s/^\('"$ac_word_re"'\)[ ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p ' >>conftest.defines # Remove the space that was appended to ease matching. # Then replace #undef with comments. This is necessary, for # example, in the case of _POSIX_SOURCE, which is predefined and required # on some systems where configure will not decide to define it. # (The regexp can be short, since the line contains either #define or #undef.) echo 's/ $// s,^[ #]*u.*,/* & */,' >>conftest.defines # Break up conftest.defines: ac_max_sed_lines=50 # First sed command is: sed -f defines.sed $ac_file_inputs >"$tmp/out1" # Second one is: sed -f defines.sed "$tmp/out1" >"$tmp/out2" # Third one will be: sed -f defines.sed "$tmp/out2" >"$tmp/out1" # et cetera. ac_in='$ac_file_inputs' ac_out='"$tmp/out1"' ac_nxt='"$tmp/out2"' while : do # Write a here document: cat >>$CONFIG_STATUS <<_ACEOF # First, check the format of the line: cat >"\$tmp/defines.sed" <<\\CEOF /^[ ]*#[ ]*undef[ ][ ]*$ac_word_re[ ]*\$/b def /^[ ]*#[ ]*define[ ][ ]*$ac_word_re[( ]/b def b :def _ACEOF sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS echo 'CEOF sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail grep . conftest.tail >/dev/null || break rm -f conftest.defines mv conftest.tail conftest.defines done rm -f conftest.defines conftest.tail echo "ac_result=$ac_in" >>$CONFIG_STATUS cat >>$CONFIG_STATUS <<\_ACEOF if test x"$ac_file" != x-; then echo "/* $configure_input */" >"$tmp/config.h" cat "$ac_result" >>"$tmp/config.h" if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then { echo "$as_me:$LINENO: $ac_file is unchanged" >&5 echo "$as_me: $ac_file is unchanged" >&6;} else rm -f $ac_file mv "$tmp/config.h" $ac_file fi else echo "/* $configure_input */" cat "$ac_result" fi rm -f "$tmp/out12" # Compute $ac_file's index in $config_headers. _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $ac_file | $ac_file:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $ac_file" >`$as_dirname -- $ac_file || $as_expr X$ac_file : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X$ac_file : 'X\(//\)[^/]' \| \ X$ac_file : 'X\(//\)$' \| \ X$ac_file : 'X\(/\)' \| . 2>/dev/null || echo X$ac_file | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'`/stamp-h$_am_stamp_count ;; :C) { echo "$as_me:$LINENO: executing $ac_file commands" >&5 echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "depfiles":C) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # So let's grep whole file. if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then dirpart=`$as_dirname -- "$mf" || $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$mf" : 'X\(//\)[^/]' \| \ X"$mf" : 'X\(//\)$' \| \ X"$mf" : 'X\(/\)' \| . 2>/dev/null || echo X"$mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`$as_dirname -- "$file" || $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$file" : 'X\(//\)[^/]' \| \ X"$file" : 'X\(//\)$' \| \ X"$file" : 'X\(/\)' \| . 2>/dev/null || echo X"$file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` { as_dir=$dirpart/$fdir case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 echo "$as_me: error: cannot create directory $as_dir" >&2;} { (exit 1); exit 1; }; }; } # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done ;; esac done # for ac_tag { (exit 0); exit 0; } _ACEOF chmod +x $CONFIG_STATUS ac_clean_files=$ac_clean_files_save # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || { (exit 1); exit 1; } fi tgif-QPL-4.2.5/rmcast/README0000644000076400007640000000201011112562556015141 0ustar williamwilliamReliable Multicast Library: RML The RML is a C library developed under QPL. It is intended to guarantee reliable transmission over IP Multicast. We try to develop it in a way that it can be used in a large set of applications. The library runs on GNU/Linux and only require a full functional IP Multicast network to work properly. We provide a simple multicast chat application to test the library and you can found it in the rmchat directory. That is the simple way to learn how to build a multicast application with the Reliable Multicast Library. The Tangram-II Whiteboard (TGWB) is an application built on tgif that uses RML. Further information about TGWB can be found at README.tgwb file. You can download tgif at http://bourbon.usc.edu/tgif/index.html. Documentation is available in the doc/ directory. See AUTHORS for authors' emails and/or homepages. See LICENSE.QPL for information about QPL. See INSTALL file for information on compiling the librmcast. Enjoy it. RML team at LAND (http://www.land.ufrj.br) tgif-QPL-4.2.5/rmcast/NEWS0000644000076400007640000000000010372733175014761 0ustar williamwilliamtgif-QPL-4.2.5/chinput.c0000644000076400007640000000000011602233314014572 0ustar williamwilliamtgif-QPL-4.2.5/wb_buff.c0000644000076400007640000003654311602233313014556 0ustar williamwilliam/* * Author: Magnos Martinello, in April, 1999. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb_buff.c,v 1.5 2009/10/02 15:31:24 william Exp $ */ /* * TODO: rever a rotina de insercao. Analisar o buffer como sendo circular. * */ #define _INCLUDE_FROM_WB_BUFF_C_ #include "tgifdefs.h" #include "wb_buff.e" #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #include #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ #include #include /* Structure of each component from the buffer */ typedef struct item_s { void *data; int size; struct item_s *prev; struct item_s *next; } item_t; /******************************************************************* Header: - Maximum number of items in the buffer - Size of each item - Number of items in the buffer - SORTED/UNSORTED insertion - Pointer to first item of the queue - Pointer to last item of the queue (Item is inserted in the start pointer and removed from the end pointer) - Function to compare two items of the buffer *******************************************************************/ typedef struct { int n; int option; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) pthread_mutex_t *mp; #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ item_t *start; item_t *end; int (*compar)(const void *, const void *); } header_t; #define INITMAXTABLE 100 int MAXTABLE=INITMAXTABLE; /* Maximum number of active buffers */ header_t **table=NULL; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) pthread_mutex_t table_mp; #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ #ifndef TRUE #define TRUE 1 #define FALSE 0 #endif /*********************************************************************** * This function creates a new buffer and returns its descriptor as * * an integer * **********************************************************************/ int buff_init (int trash1, int trash2, int option, int (*compar)(const void *, const void *)) { header_t *header; int aux; static int last_used_desc = INITMAXTABLE - 1; static int is_first = TRUE; /* If option is invalid then return error */ if (((option & SORTED)==SORTED) && ((option & UNSORTED)==UNSORTED)) return(-1); /* If insertion is sorted and no comparison function has been assigned, then return error */ if ((option == SORTED) && (compar == NULL)) return(-1); if (is_first) { if ((table = (header_t**)malloc(MAXTABLE*sizeof(header_t*))) == NULL) { fprintf(stderr,"Allocation error. (buff_init)\n"); exit(1); } is_first = FALSE; } /* Looks for an empty position in the Descriptor Table */ #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_lock(&table_mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ aux = last_used_desc; last_used_desc = (last_used_desc + 1) % MAXTABLE; while ((table[last_used_desc] != NULL) && (aux != last_used_desc)) last_used_desc = (last_used_desc + 1) % MAXTABLE; if (!(table[last_used_desc] == NULL)){ last_used_desc = MAXTABLE; MAXTABLE += 10; table=(header_t**)realloc(table,MAXTABLE*sizeof(header_t*)); } #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_unlock(&table_mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ /* Create a new header and store its pointer in the descriptor table */ header = (header_t *) malloc (sizeof(header_t)); if (header == NULL) return(-1); memset(header, 0, sizeof(header_t)); table[last_used_desc] = header; /* Set values for attributes in the header */ header->n = 0; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX header->mp = malloc(sizeof(pthread_mutex_t)); if (header->mp == NULL) return(-1); memset(header->mp, 0, sizeof(pthread_mutex_t)); pthread_mutex_init(header->mp, NULL); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ header->option = option; header->compar = compar; header->start = header->end = NULL; return last_used_desc; } void buff_cleanup () { if (table != NULL) free(table); table = NULL; } /*********************************************************************** * This function inserts a new item in the buffer specified by its * * descriptor. The insertion may be sorted or not, depending on the * * option set during the buffer initialization. It returns a negative * * integer if the insertion wasn't successful. * **********************************************************************/ int buff_ins (int bd, const void *buffer) { header_t *header; item_t *item, *newitem, *auxitem; if (table[bd] == NULL) return(-1); header = table[bd]; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_lock(header->mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ /* Create the new item */ newitem = (item_t *) malloc (sizeof(item_t)); if (newitem == NULL) return(-1); memset(newitem, 0, sizeof(item_t)); newitem->size = strlen((char*)buffer)+1; newitem->data = (int*)malloc (newitem->size); if (newitem->data == NULL) return(-1); strcpy((char*)(newitem->data), (char*)buffer); /* Unsorted insertion or empty buffer */ if (((header->option & UNSORTED) == UNSORTED) || (header->n == 0)){ newitem->prev = header->start; if (newitem->prev != NULL) newitem->prev->next = newitem; header->start = newitem; if (header->end == NULL) header->end=newitem; } else /* Sorted buffer */ if ((header->option & SORTED) == SORTED){ /* Search position where new item will be inserted according to comparison function previously specified */ /* Search is made from begining to end and from end to begining */ item = header->end; auxitem = header->start; while (((item != header->start) && (header->compar(item->data,buffer)<= 0)) && ((auxitem != header->end) && (header->compar(auxitem->data,buffer)>0))){ item = item->next; auxitem = auxitem->prev; } /* Decide wich pointer points to the correct position */ if (header->compar(auxitem->data, buffer)<=0) { item = auxitem; } else { if (item->prev!=NULL) item = item->prev; } /* front insertion */ if (item == header->start) { if (header->compar(header->start->data,buffer) < 0) { header->n++; newitem->next = NULL; newitem->prev = header->start; header->start->next = newitem; header->start = newitem; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_unlock(header->mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ return(0); } } /* rear insertion */ if (header->compar(buffer, header->end->data) < 0) { newitem->next = header->end; newitem->prev = NULL; header->end->prev = newitem; header->end = newitem; header->n++; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_unlock(header->mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ return(0); } /* is duplicated? */ if ((header->option & DUPLICATED) != DUPLICATED) if (header->compar(item->data, buffer)==0){ #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_unlock(header->mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ return(-1); } /* Set pointers */ if (item->next!=NULL) (item->next)->prev = newitem; newitem->next = item->next; newitem->prev = item; item->next = newitem; } header->n++; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_unlock(header->mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ return(0); } /*********************************************************************** * This function removes an item from the buffer especified by its * * descriptor. The data stored in the item is copied to a pointer * * especified by the user. It returns a negative integer if an error * * occurs * **********************************************************************/ int buff_rem (int bd, void **buffer) { header_t *header; int buffsize =0; if (table[bd] == NULL) return(-1); header = table[bd]; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_lock(header->mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ if (header->n == 0){ #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_unlock(header->mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ return(-1); } if ((*buffer = malloc(header->end->size * sizeof(char)))==NULL) { fprintf(stderr,"Allocation error. (buff_rem)\n"); exit(1); } buffsize = header->end->size; memcpy(*buffer, header->end->data, header->end->size); header->end = header->end->next; header->n--; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_unlock(header->mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ return(buffsize); } /*********************************************************************** * This function disposes memory occupied by the buffer. * **********************************************************************/ int buff_destroy (int bd) { item_t *item=NULL, *next_item=NULL; int i; if (table[bd] == NULL) return(-1); item = table[bd]->end; for (i = 0; item!=NULL; i++, item=next_item) { next_item = item->next; free(item->data); free(item); } #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_destroy(table[bd]->mp); free(table[bd]->mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ free(table[bd]); table[bd] = NULL; return(0); } /*********************************************************************** * This function makes all items avaiable for insertion * **********************************************************************/ int buff_empty (int bd) { header_t *header; int aux; if (table[bd] == NULL) return(-1); header = table[bd]; aux = header->n; if ( aux == buff_emptyn(bd,aux) ) { return(0); } else return(-1); } /*********************************************************************** * This function makes the first n items avaiable for insertion. It * * returns the number of items disposed. * **********************************************************************/ int buff_emptyn (int bd, int n) { header_t *header; int nitems, i; if (table[bd] == NULL) return(-1); header = table[bd]; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_lock(header->mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ nitems = header->n; i = 0; while ( (header->n > 0) && (i < n)) { i++; header->n--; free(header->end->data); free(header->end); header->end = header->end->next; if (header->end == header->start) { header->start=NULL; } } #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #ifdef PTHREAD_MUTEX pthread_mutex_unlock(header->mp); #endif /* PTHREAD_MUTEX */ #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ return((nitemsn; } /*********************************************************************** * This function concatenates two buffers, creating a new unsorted * * insertion buffer * **********************************************************************/ int buff_conc (int bd1, int bd2) { header_t *hd1, *hd2; item_t *item; int nbd, i, j; char *buffer=NULL; if ( (table[bd1] == NULL) || (table[bd2] == NULL)) return(-1); hd1 = table[bd1]; hd2 = table[bd2]; nbd = buff_init (0, 0, UNSORTED, hd1->compar); item = hd1->end; i = 0; for (j=0;j<2;j++) { i = 0; if (j==0) item = hd1->end; else item = hd2->end; while ((i < (j==0?hd1->n:hd2->n))) { if (item == NULL) { fprintf(stderr,"Internal error. (buff_conc)\n"); exit(1); } buffer = (char*) malloc (item->size); if (buffer == NULL) return(-1); memset(buffer, 0, item->size); memcpy(buffer, item->data, item->size); buff_ins(nbd, buffer); item = item->next; i++; } } if (buffer) free (buffer); return(nbd); } /*********************************************************************** * This function sorts a buffer according to a comparison function * * pointed to by compar * **********************************************************************/ /* int buff_sort (int bd, int (*compar)(const void *, const void *)) { header_t *header; char *buffer; int i, n; item_t *item; if (table[bd] == NULL) return(-1); header = table[bd]; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) pthread_mutex_lock(header->mp); #endif if ((header->option & SORTED) == SORTED){ #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) pthread_mutex_unlock(header->mp); #endif return(0); } if (header->compar == NULL){ #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) pthread_mutex_unlock(header->mp); #endif return(-1); } n = header->n; buffer = (char*) malloc (n * header->size); if (buffer == NULL) return(-1); memset(buffer, 0, n*header->size); i = 0; item = header->end; while (i < n){ memcpy(buffer + i * header->size, item->data, header->size); item = item->next; i++; } qsort (buffer, n, header->size, compar); i = 0; item = header->end; while (i < n){ memcpy(item->data, buffer + i * header->size, header->size); item = item->next; i++; } free (buffer); #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) pthread_mutex_unlock(header->mp); #endif return(0); } */ int buff_show(int bd) { int i; item_t *item = (table[bd])->end; fprintf(stderr,"Buffer info (descriptor: %d):\n",bd); fprintf(stderr,"\tn: %d\n\toption: %d\n\tstart: %p\n\tend: %p\n", (table[bd])->n, (table[bd])->option, (table[bd])->start, (table[bd])->end); fprintf(stderr,"\tDados: \n"); for (i=0; i<(table[bd])->n; i++) { fprintf(stderr,"\t%s (this: %p prev: %p next: %p) -> \n",(char*)item->data, item,item->prev,item->next); item = item->next; } fprintf(stderr,"\tis the first\n"); return (0); } tgif-QPL-4.2.5/text.e0000644000076400007640000001462711602233313014131 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/text.e,v 1.17 2011/05/16 16:22:00 william Exp $ */ #ifndef _TEXT_E_ #define _TEXT_E_ extern int textDrawn; extern int curTextModified; extern int textVSpace; extern int textJust; extern int textCursorShown; extern int textCursorH; extern int editingText; extern int curTextIsNew; extern int editTextSize; extern int readingTextObject; extern float scriptFraction; extern char scriptFractionStr[]; extern int deleteNextCharWithDelKey; extern int lengthLimit256InInsertChar; #ifdef _INCLUDE_FROM_TEXT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TEXT_C_*/ /* DynStr routines */ extern void FreeDynStrBuf ARGS_DECL((struct DynStrRec *)); extern void DynStrCpy ARGS_DECL((struct DynStrRec *Dest, struct DynStrRec *Src)); extern struct DynStrRec * NewDynStr ARGS_DECL((void)); extern struct DynStrRec * DynStrDup ARGS_DECL((struct DynStrRec *)); extern void DynStrSet ARGS_DECL((struct DynStrRec *, char*)); /* Str routines */ extern void FreeStr ARGS_DECL((struct StrRec *)); extern void FreeStrList ARGS_DECL((struct StrRec *)); extern struct StrRec * NewStr ARGS_DECL((void)); /* text routines */ extern void SetTextHighlight ARGS_DECL((void)); extern void SaveCursorPositionInCurText ARGS_DECL((void)); extern void RestoreCursorPositionInCurText ARGS_DECL((void)); extern void InvalidateTextCache ARGS_DECL((struct TextRec *)); extern void TellTextCursorPosition ARGS_DECL((int *pnX, int *pnY)); extern void BlurText ARGS_DECL((Window, GC, int XOff, int YOff, int W, int H)); extern void InitText ARGS_DECL((void)); extern void CleanUpText ARGS_DECL((void)); extern void NewCurText ARGS_DECL((void)); extern void FreeTextObj ARGS_DECL((struct ObjRec *)); extern void SetEditTextSizeValue ARGS_DECL((int edit_text_size)); extern void UpdateTextInfoChoices ARGS_DECL((int forced)); extern int RestoreEditTextSize ARGS_DECL((struct ObjRec *, int restore)); extern int ShouldRightMarginBeActive ARGS_DECL((void)); extern void SetRightMarginActive ARGS_DECL((void)); extern int CreateTextObj ARGS_DECL((int nDeactivateIM, int nRedraw)); extern int AtBeginningOfInheritedAttrValue ARGS_DECL((struct ObjRec *, StrBlockInfo*, int)); extern void HighLightJustDrawnText ARGS_DECL((void)); extern void DelSelText ARGS_DECL((void)); extern void SwitchTextCurAndEndStrBlocks ARGS_DECL((void)); extern int FixHighlightedStrBlockDepths ARGS_DECL((void)); extern int SwitchToSingleByteFont ARGS_DECL((StrSegInfo*)); extern int SwitchToDoubleByteFont ARGS_DECL((StrSegInfo*)); extern void HandleInputFromBuffer ARGS_DECL((char*)); extern void HandleTextFromBuffer ARGS_DECL((XKeyEvent*, char*, KeySym, int has_ch)); extern int HandleDoubleByteUTF8Chars ARGS_DECL((char *buf, int has_ch)); extern void DrawText ARGS_DECL((XEvent *)); extern void InsertHexOctalChar ARGS_DECL((void)); extern void InsertSymbol ARGS_DECL((void)); extern void EditTextInAttr ARGS_DECL((struct AttrRec *)); extern void DumpOneStr ARGS_DECL((FILE*, int FontIndex, int DoubleByte, int DoubleByteModBytes, char*)); extern void DrawTextObj ARGS_DECL((Window, int XOff, int YOff, struct ObjRec *)); extern int ReadMiniLines ARGS_DECL((FILE *, StrBlockInfo*, MiniLinesInfo**)); extern void ReadTextObj ARGS_DECL((FILE *, char *Inbuf, struct ObjRec **)); extern void UpdCurTextBBox ARGS_DECL((void)); extern void AdjustCurText ARGS_DECL((int XOff, int YOff)); extern void PrepareZoomCurText ARGS_DECL((int *AbsXc, int *AbsYc)); extern void PreZoomCurText ARGS_DECL((void)); extern void PostZoomCurText ARGS_DECL((int AbsXc, int AbsYc)); extern void HighLightText ARGS_DECL((struct ObjRec *ObjPtr, StrBlockInfo *pStartStrBlock, int start_index, StrBlockInfo *pEndStrBlock, int end_index)); extern int FindTextInCurTextObj ARGS_DECL((char *str_to_match, int str_len, int case_sensitive, StrBlockInfo **ppStartStrBlock, int *pn_start_index, StrBlockInfo **ppEndStrBlock, int *pn_end_index)); extern int SetScriptFractionValue ARGS_DECL((char*)); extern void SetScriptFraction ARGS_DECL((void)); extern void InsertThinSpace ARGS_DECL((void)); extern void InsertVerticalOffset ARGS_DECL((void)); extern void RemoveVerticalOffset ARGS_DECL((void)); extern void InsertRightSuperscript ARGS_DECL((void)); extern void InsertRightSubscript ARGS_DECL((void)); extern void InsertLeftSuperscript ARGS_DECL((void)); extern void InsertLeftSubscript ARGS_DECL((void)); extern void InsertCenterSuperscript ARGS_DECL((void)); extern void InsertCenterSubscript ARGS_DECL((void)); extern int RefreshEditTextMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateEditTextMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int ChangeEditTextProperty ARGS_DECL((long lWhich, int nValue)); extern void PasteMiniLinesAtCursor ARGS_DECL((struct ObjRec *)); extern int MouseInCurText ARGS_DECL((XEvent*)); extern int MouseOnCurTextBoundary ARGS_DECL((XEvent*)); extern void MoveEditText ARGS_DECL((XEvent*)); extern void MoveEditTextBox ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TEXT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TEXT_C_*/ #endif /*_TEXT_E_*/ tgif-QPL-4.2.5/stretch.e0000644000076400007640000001630711602233313014616 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/stretch.e,v 1.28 2011/05/16 16:21:59 william Exp $ */ #ifndef _STRETCH_E_ #define _STRETCH_E_ extern int stretchableText; extern int compoundObjWithTextStretchableForPSE; extern int rotationIncrement; extern int autoRotatePivot; extern int rotatePivotAbsXYValid; extern int rotatePivotAbsX; extern int rotatePivotAbsY; #ifdef _INCLUDE_FROM_STRETCH_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_STRETCH_C_*/ extern int PtInPolyMark ARGS_DECL((struct ObjRec *, int XOff, int YOff, int NumPts, IntPoint *, int *Index)); extern int RetractedArrowAttr ARGS_DECL((struct ObjRec *)); extern int AutoRetractedArrowAttr ARGS_DECL((struct ObjRec *, int CheckVCount)); extern int AutoCenterAttr ARGS_DECL((struct ObjRec *)); extern void CenterObjInOBBox ARGS_DECL((struct ObjRec *TextObjPtr, struct BBRec OBBox, struct BBRec *OBBoxReturn)); extern struct SelRec * PtInSelMark ARGS_DECL((int XOff, int YOff, int * Corner)); extern int HasOnReshape ARGS_DECL((struct ObjRec *, struct AttrRec **)); extern int GetVlistIndexFromStretchStructuredSplineInfo ARGS_DECL(( StretchStructuredSplineInfo*, int ss_index)); extern void SetIPTInfoForStretchPoly ARGS_DECL((int index, int n, IntPoint*, StretchStructuredSplineInfo*)); extern void SetIPTInfoForStretchPolygon ARGS_DECL((int index, int n, IntPoint*, StretchStructuredSplineInfo*)); extern void SetVsAndVs2ForStretchStructSpline ARGS_DECL(( StretchStructuredSplineInfo*, int dx, int dy, int *pn_num_vs, IntPoint *vs, int *pn_num_vs2, IntPoint *vs2)); extern void FixUpSmoothAndSmooth2ForStretchStructSpline ARGS_DECL(( int num_vs, char *smooth, int num_vs2, char *smooth2)); extern void EraseHighLightForHinge ARGS_DECL((StretchStructuredSplineInfo*, int dx, int dy, int draw_dashed_line, int draw_vertices)); extern void EraseHighLightForSmooth ARGS_DECL((StretchStructuredSplineInfo*, int dx, int dy, int draw_dashed_line, int draw_vertices)); extern void EraseHighLightForStretchStructSpline ARGS_DECL(( StretchStructuredSplineInfo*, int dx, int dy, int draw_dashed_line, int draw_vertices)); extern XPoint *DupVs ARGS_DECL((int *pn_return, XPoint *vs, int n)); extern void MoveATransformedPoint ARGS_DECL((struct ObjRec *, IntPoint*, int abs_dx, int abs_dy)); extern void UpdateObjForStretchStructSpline ARGS_DECL((struct ObjRec *, int n, IntPoint *vs, int abs_dx, int abs_dy, StretchStructuredSplineInfo*)); extern void ShearObj ARGS_DECL((struct ObjRec *, int Corner, double dXShear, double dYShear, double dXScale, double dYScale, int *RealLtX, int *RealLtY)); extern void StretchSel ARGS_DECL((int XGridOff, int YGridOff, struct ObjRec *, int Corner)); extern void ScaleAnEPSObj ARGS_DECL((struct ObjRec *, float * Scale)); extern void ScaleAllSelObj ARGS_DECL((void)); extern void PreciseScaleEverything ARGS_DECL((void)); extern void ScaleObjLikeScaleEverything ARGS_DECL((struct ObjRec *, double Scale, int Redraw)); extern void SizeAllSelObj ARGS_DECL((int AbsW, int AbsH)); extern void SizeAnObj ARGS_DECL((struct ObjRec *ObjPtr, struct ObjRec *TopOwner, int AbsW, int AbsH)); extern void SizeAllSelToGivenWidthHeight ARGS_DECL((int AbsW, int AbsH)); extern void SizeAllSelToGivenWidth ARGS_DECL((int AbsW)); extern void SizeAllSelToGivenHeight ARGS_DECL((int AbsH)); extern void FlipObjHorizontal ARGS_DECL((struct ObjRec *)); extern void FlipIconHorizontal ARGS_DECL((struct ObjRec *)); extern void FlipObjVertical ARGS_DECL((struct ObjRec *)); extern void FlipIconVertical ARGS_DECL((struct ObjRec *)); extern void SetRotatePivot ARGS_DECL((void)); extern void SetRotatePivotByObject ARGS_DECL((struct ObjRec *)); extern void RotateObjForLayout ARGS_DECL((struct ObjRec *, double, int)); extern void RotateObj ARGS_DECL((struct ObjRec *, int Corner, int AngleDelta, int *RealLtX, int *RealLtY)); extern void RotateObjClockWise ARGS_DECL((struct ObjRec *)); extern void RotateIconClockWise ARGS_DECL((struct ObjRec *)); extern void RotateObjCounter ARGS_DECL((struct ObjRec *)); extern void RotateIconCounter ARGS_DECL((struct ObjRec *)); extern void FlipHorizontal ARGS_DECL((void)); extern void FlipVertical ARGS_DECL((void)); extern void RotateClockWise ARGS_DECL((void)); extern void RotateCounter ARGS_DECL((void)); extern void SetTextRotation ARGS_DECL((char*)); extern void SetRotationIncrement ARGS_DECL((char*)); extern void SetSelCTM ARGS_DECL((int nTransformed, struct XfrmMtrxRec *)); extern void RotateShearSel ARGS_DECL((int XGridOff, int YGridOff, struct ObjRec *, int Corner)); extern TgMenu *CreateFlipRotateMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern void HighLightRotatePivot ARGS_DECL((int dir)); extern int PtInRotatePivot ARGS_DECL((int mouse_x, int mouse_y)); extern TgMenu *CreateMoveStdRotatePivotMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern void RefreshAutoRotatePivotMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateAutoRotatePivotMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int AutoRotatePivotMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void ResetRotatePivotValidInfo ARGS_DECL((void)); extern int ReadRotatePivotInfo ARGS_DECL((char*)); extern void ContinueMoveRotatePivot ARGS_DECL((int OrigX, int OrigY)); extern void ToggleAutoRotatePivot ARGS_DECL((void)); extern void SpecifyRotatePivot ARGS_DECL((void)); extern void ResetRotatePivot ARGS_DECL((void)); extern void NextPolyRotationPivot ARGS_DECL((void)); extern void MoveRotationPivotToArcCenter ARGS_DECL((void)); extern void MoveRotatePivot ARGS_DECL((int Corner)); extern void AutoRotatePivotSubMenu ARGS_DECL((int index)); #ifdef _INCLUDE_FROM_STRETCH_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_STRETCH_C_*/ #endif /*_STRETCH_E_*/ tgif-QPL-4.2.5/navigate.c0000644000076400007640000014750611602233312014743 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/navigate.c,v 1.12 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_NAVIGATE_C_ #include "tgifdefs.h" #include "cmdids.h" #include "attr.e" #include "auxtext.e" #include "button.e" #include "choice.e" #include "choose.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "exec.e" #include "file.e" #include "font.e" #include "mainloop.e" #include "mainmenu.e" #include "menu.e" #include "menuinfo.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "raster.e" #include "rect.e" #include "remote.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "stk.e" #include "strtbl.e" #include "util.e" #include "xpixmap.e" int navigatingBackAndForth=FALSE; int inHyperSpace=FALSE; int inSlideShow=FALSE; int visibleGridInSlideShow=FALSE; int slideShowInfoValid=FALSE; char *slideShowBorderColor=NULL; int slideShowXOffset=0; int slideShowYOffset=0; int autoHyperSpaceOnRemote=TRUE; int allowLaunchInHyperSpace=FALSE; int navigateRefresh=FALSE; int goHyperSpaceInSlideShow=FALSE; static int validHotListFileName=FALSE; static char *hotListFileName=NULL; struct NavigateRec { struct StkRec *stk; struct NavigateRec *next, *prev; char *full_fname; char *doc_name; int cur_page_num, orig_x, orig_y, zoom_scale, zoomed_in; }; static struct NavigateRec *firstNavigate=NULL, *lastNavigate=NULL; static struct NavigateRec *curNavigate=NULL; static struct NavigateRec *firstSessionHistory=NULL, *lastSessionHistory=NULL; static struct URLCacheRec *firstURLCache=NULL, *lastURLCache=NULL; static int maxURLCache=(-1), curURLCache=0; static int lineWidthIndexInSlideShow=4; static int makeUnsavableInSlideShow=FALSE; static int ignoreSlideShowOffsetsInFile=TRUE; static int hideWindowsInSlideShow=TRUE; static int savedSlideShowXOffset=0; static int savedSlideShowYOffset=0; static int savedSlideShowOffsets=FALSE; int ParseXYSpec(spec, pnx, pny) char *spec; int *pnx, *pny; { char *psz_dx=NULL, *psz_dy=NULL, *psz_dup_spec=NULL; int dx, dy; UtilTrimBlanks(spec); if (*spec == '\0') return FALSE; if ((psz_dup_spec=UtilStrDup(spec)) == NULL) return FailAllocMessage(); if ((psz_dx=strtok(psz_dup_spec, " ,\t\n\r")) == NULL || sscanf(psz_dx, "%d", &dx) != 1) { sprintf(gszMsgBox, TgLoadString(STID_ERR_IN_PARSE_STR_FOR_2_VAL), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(psz_dup_spec); return FALSE; } psz_dy = strtok(NULL, " ,\t\n\r"); if (psz_dy == NULL) { dy = dx; } else { if (sscanf(psz_dy, "%d", &dy) != 1) { sprintf(gszMsgBox, TgLoadString(STID_ERR_IN_PARSE_STR_FOR_2_VAL), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(psz_dup_spec); return FALSE; } } if (pnx != NULL) *pnx = dx; if (pny != NULL) *pny = dy; free(psz_dup_spec); return TRUE; } static int ParseWHSpecError(spec, psz_dup_spec, rc) char *spec; char *psz_dup_spec; int rc; { if (!rc) { sprintf(gszMsgBox, TgLoadString(STID_ERR_IN_PARSE_STR_FOR_2_VAL), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } UtilFree(psz_dup_spec); return rc; } int ParseWHSpec(spec, pnw, pnh) char *spec; int *pnw, *pnh; { char *psz_h=NULL, *psz_dup_spec=NULL; int w=0, h=0; UtilTrimBlanks(spec); if (*spec == '\0') return FALSE; if ((psz_dup_spec=UtilStrDup(spec)) == NULL) return FailAllocMessage(); UtilStrLower(psz_dup_spec); if ((psz_h=strchr(psz_dup_spec, 'x')) == NULL) { if ((psz_h=strchr(psz_dup_spec, ' ')) == NULL) { return ParseWHSpecError(spec, psz_dup_spec, FALSE); } *psz_h++ = '\0'; } else { *psz_h++ = '\0'; } UtilTrimBlanks(psz_dup_spec); UtilTrimBlanks(psz_h); if (!GetDimension(psz_dup_spec, FALSE, &w)) { return ParseWHSpecError(spec, psz_dup_spec, FALSE); } if (!GetDimension(psz_h, FALSE, &h)) { return ParseWHSpecError(spec, psz_dup_spec, FALSE); } if (pnw != NULL) *pnw = w; if (pnh != NULL) *pnh = h; free(psz_dup_spec); return TRUE; } void CleanUpSlideShowInfo() { if (slideShowBorderColor != NULL) UtilFree(slideShowBorderColor); slideShowBorderColor = NULL; slideShowXOffset = slideShowYOffset = 0; slideShowInfoValid = FALSE; } static void InsertNavigate(pnr_prev, pnr_next, pnr) struct NavigateRec *pnr_prev, *pnr_next, *pnr; { pnr->prev = pnr_prev; pnr->next = pnr_next; if (pnr_prev == NULL) { firstNavigate = pnr; } else { pnr_prev->next = pnr; } if (pnr_next == NULL) { lastNavigate = pnr; } else { pnr_next->prev = pnr; } } static void DeleteNavigate(pnr) struct NavigateRec *pnr; { if (pnr->full_fname != NULL) free(pnr->full_fname); if (pnr->doc_name != NULL) free(pnr->doc_name); free(pnr); } static void ClearNavigateRecords(pnr) struct NavigateRec *pnr; { struct NavigateRec *pnr_next; for (; pnr != NULL; pnr=pnr_next) { pnr_next = pnr->next; DeleteNavigate(pnr); } lastNavigate = curNavigate; if (lastNavigate == NULL) firstNavigate = NULL; } static void ClearSessionHistory() { struct NavigateRec *pnr, *pnr_prev; for (pnr=lastSessionHistory; pnr != NULL; pnr=pnr_prev) { pnr_prev = pnr->prev; if (pnr->full_fname != NULL) free(pnr->full_fname); if (pnr->doc_name != NULL) free(pnr->doc_name); free(pnr); } lastSessionHistory = firstSessionHistory = NULL; } static void FreeAnURLCache(url_cache) struct URLCacheRec *url_cache; { if (url_cache == NULL) return; if (url_cache->remote_buf != NULL) free(url_cache->remote_buf); if (url_cache->content_type != NULL) free(url_cache->content_type); if (url_cache->simple_url_name != NULL) free(url_cache->simple_url_name); free(url_cache); } static void CleanUpURLCache() { struct URLCacheRec *next_cache; for ( ; firstURLCache != NULL; firstURLCache=next_cache) { next_cache = firstURLCache->next; FreeAnURLCache(firstURLCache); } curURLCache = 0; firstURLCache = lastURLCache = NULL; } void CleanUpNavigate() { curNavigate = NULL; ClearNavigateRecords(firstNavigate); if (hotListFileName != NULL) free(hotListFileName); hotListFileName = NULL; validHotListFileName = FALSE; ClearSessionHistory(); CleanUpURLCache(); CleanUpSlideShowInfo(); savedSlideShowXOffset = 0; savedSlideShowYOffset = 0; savedSlideShowOffsets = FALSE; } void InitNavigate() { char *c_ptr=NULL, spec[MAXSTRING]; visibleGridInSlideShow = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "VisibleGridInSlideShow")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { visibleGridInSlideShow = TRUE; } goHyperSpaceInSlideShow = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "GoHyperSpaceInSlideShow")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { goHyperSpaceInSlideShow = TRUE; } lineWidthIndexInSlideShow = 4; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "LineWidthIndexInSlideShow")) != NULL) { lineWidthIndexInSlideShow = atoi(c_ptr); if (lineWidthIndexInSlideShow < 0 || lineWidthIndexInSlideShow >= maxLineWidths) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "LineWidthIndexInSlideShow", c_ptr, 4); lineWidthIndexInSlideShow = 4; } } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"SlideShowWindowOffsets")) != NULL) { UtilStrCpyN(spec, sizeof(spec), c_ptr); UtilTrimBlanks(spec); if (ParseXYSpec(spec, &slideShowXOffset, &slideShowYOffset)) { slideShowInfoValid = TRUE; savedSlideShowXOffset = slideShowXOffset; savedSlideShowYOffset = slideShowYOffset; savedSlideShowOffsets = TRUE; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "SlideShowWindowOffsets", spec, "0,0"); fprintf(stderr, "\n"); } } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"SlideShowBorderColor")) != NULL) { int new_alloc=0; UtilStrCpyN(spec, sizeof(spec), c_ptr); UtilTrimBlanks(spec); if (QuickFindColorIndex(NULL, spec, &new_alloc, FALSE) == INVALID) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_COLORXPM_GET), TOOL_NAME, "SlideShowBorderColor", spec); fprintf(stderr, "\n"); return; } if (slideShowBorderColor != NULL) UtilFree(slideShowBorderColor); slideShowBorderColor = UtilStrDup(spec); if (slideShowBorderColor == NULL) FailAllocMessage(); slideShowInfoValid = TRUE; } makeUnsavableInSlideShow = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MakeUnsavableInSlideShow")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { makeUnsavableInSlideShow = TRUE; } ignoreSlideShowOffsetsInFile = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "IgnoreSlideShowOffsetsInFile")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { ignoreSlideShowOffsetsInFile = FALSE; } hideWindowsInSlideShow = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "HideWindowsInSlideShow")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { hideWindowsInSlideShow = FALSE; } } static void InitURLCache() { if (maxURLCache == (-1)) { char *c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MaxNavigateCacheBuffers"); maxURLCache = 40; if (c_ptr != NULL) { maxURLCache = atoi(c_ptr); if (maxURLCache < 0) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "MaxNavigateCacheBuffers", c_ptr, 40); maxURLCache = 40; } } curURLCache = 0; firstURLCache = lastURLCache = NULL; } } static char *SimpleURLName(psz_url) char *psz_url; { char *c_ptr=strchr(psz_url, '#'); if (c_ptr != NULL) { char *return_buf; *c_ptr = '\0'; return_buf = UtilStrDup(psz_url); *c_ptr = '#'; return return_buf; } return UtilStrDup(psz_url); } static void UnlinkURLCache(url_cache) struct URLCacheRec *url_cache; { if (url_cache == NULL) return; if (url_cache->prev == NULL) { firstURLCache = url_cache->next; } else { url_cache->prev->next = url_cache->next; } if (url_cache->next == NULL) { lastURLCache = url_cache->prev; } else { url_cache->next->prev = url_cache->prev; } url_cache->prev = url_cache->next = NULL; curURLCache--; } static void InsertURLCache(prev_url, next_url, url_cache) struct URLCacheRec *prev_url, *next_url, *url_cache; { url_cache->prev = prev_url; url_cache->next = next_url; if (prev_url == NULL) { firstURLCache = url_cache; } else { prev_url->next = url_cache; } if (next_url == NULL) { lastURLCache = url_cache; } else { next_url->prev = url_cache; } curURLCache++; } void UpdateLRU(url_cache) struct URLCacheRec *url_cache; { UnlinkURLCache(url_cache); InsertURLCache(lastURLCache, NULL, url_cache); } struct URLCacheRec *FindURLCache(psz_url, update_lru) char *psz_url; int update_lru; { char *simple_url_name=NULL; struct URLCacheRec *url_cache; if (PRTGIF) return NULL; simple_url_name = SimpleURLName(psz_url); InitURLCache(); if (simple_url_name == NULL) return NULL; for (url_cache=lastURLCache; url_cache != NULL; url_cache=url_cache->prev) { if (strcmp(simple_url_name, url_cache->simple_url_name) == 0) { free(simple_url_name); if (!navigatingBackAndForth) { /* * Should get HEAD of the URL to see if Last-modified has changed. */ } if (update_lru) UpdateLRU(url_cache); return url_cache; } } free(simple_url_name); return NULL; } void UpdateURLCache(psz_url, psz_remote_buf, psz_content_type, remote_buf_sz, is_html) char *psz_url, *psz_remote_buf, *psz_content_type; int remote_buf_sz, is_html; { char *simple_url_name=NULL; struct URLCacheRec *url_cache; if (PRTGIF) return; simple_url_name = SimpleURLName(psz_url); InitURLCache(); if (simple_url_name == NULL) return; for (url_cache=lastURLCache; url_cache != NULL; url_cache=url_cache->prev) { if (strcmp(simple_url_name, url_cache->simple_url_name) == 0) { break; } } if (url_cache != NULL) { UnlinkURLCache(url_cache); FreeAnURLCache(url_cache); } else { if (curURLCache >= maxURLCache) { url_cache = firstURLCache; UnlinkURLCache(url_cache); FreeAnURLCache(url_cache); } } url_cache = (struct URLCacheRec*)malloc(sizeof(struct URLCacheRec)); if (url_cache == NULL) { FailAllocMessage(); free(simple_url_name); return; } memset(url_cache, 0, sizeof(struct URLCacheRec)); url_cache->remote_buf_sz = remote_buf_sz; url_cache->is_html = is_html; url_cache->remote_buf = UtilStrDup(psz_remote_buf); url_cache->content_type = UtilStrDup(psz_content_type); url_cache->simple_url_name = simple_url_name; InsertURLCache(lastURLCache, NULL, url_cache); } static int InitHotListFileName() { if (!validHotListFileName) { char *c_ptr; hotListFileName = NULL; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"HotListFileName")) != NULL) { hotListFileName = UtilStrDup(c_ptr); } else { int len=strlen(homeDir)+strlen(TOOL_NAME)+20; hotListFileName = (char*)malloc((len+1)*sizeof(char)); if (hotListFileName == NULL) FailAllocMessage(); sprintf(hotListFileName, "%s%c.%s_hotlist", homeDir, DIR_SEP, TOOL_NAME); } } validHotListFileName = TRUE; return TRUE; } void BeforeNavigate() { if (curFileDefined && curNavigate != NULL) { curNavigate->cur_page_num = curPageNum; curNavigate->orig_x = drawOrigX; curNavigate->orig_y = drawOrigY; curNavigate->zoom_scale = zoomScale; curNavigate->zoomed_in = zoomedIn; } } static void AddToSessionHistory(cur_pnr) struct NavigateRec *cur_pnr; { struct NavigateRec *pnr; pnr = (struct NavigateRec *)malloc(sizeof(struct NavigateRec)); if (pnr == NULL) FailAllocMessage(); memset(pnr, 0, sizeof(struct NavigateRec)); pnr->prev = lastSessionHistory; pnr->next = NULL; pnr->stk = NULL; pnr->full_fname = (cur_pnr->full_fname==NULL ? NULL : UtilStrDup(cur_pnr->full_fname)); pnr->doc_name = (cur_pnr->doc_name==NULL ? NULL : UtilStrDup(cur_pnr->doc_name)); if (lastSessionHistory == NULL) { firstSessionHistory = pnr; } else { lastSessionHistory->next = pnr; } lastSessionHistory = pnr; } void CommitNavigate() /* add a navigation record at the end */ { int len; if (curNavigate == NULL) { ClearNavigateRecords(firstNavigate); } else if (curNavigate != lastNavigate) { ClearNavigateRecords(curNavigate->next); } if (!curFileDefined) return; curNavigate = (struct NavigateRec *)malloc(sizeof(struct NavigateRec)); if (curNavigate == NULL) FailAllocMessage(); memset(curNavigate, 0, sizeof(struct NavigateRec)); curNavigate->stk = NULL; curNavigate->next = curNavigate->prev = NULL; curNavigate->full_fname = curNavigate->doc_name = NULL; curNavigate->cur_page_num = 1; curNavigate->orig_x = curNavigate->orig_y = 0; curNavigate->zoom_scale = 0; curNavigate->zoomed_in = FALSE; len = strlen(curDir)+1+strlen(curFileName); curNavigate->full_fname = (char*)malloc((len+1)*sizeof(char)); if (curNavigate->full_fname == NULL) FailAllocMessage(); sprintf(curNavigate->full_fname, "%s%c%s", curDir, DIR_SEP, curFileName); if (firstPage != NULL && firstPage->name != NULL) { curNavigate->doc_name = UtilStrDup(firstPage->name); } else { curNavigate->doc_name = NULL; } AddARecentlyUsedFile(curNavigate->full_fname); curNavigate->stk = topStk; InsertNavigate(lastNavigate, NULL, curNavigate); curNavigate = lastNavigate; AddToSessionHistory(curNavigate); } static void PostNavigate(pnr) struct NavigateRec *pnr; { struct AttrRec *exec_attr=FindFileAttrWithName("auto_exec="); if (exec_attr != NULL) { ClearObjCachesInAllPages(); DoExecLoop(NULL, exec_attr); } else if (pnr != NULL) { ScrollToSpecifiedOrigin(pnr->cur_page_num, pnr->orig_x, pnr->orig_y, pnr->zoom_scale, pnr->zoomed_in); ClearObjCachesInAllPages(); } } static void NavigateTo(full_fname, do_not_save, force_load) char *full_fname; int do_not_save, force_load; { if (force_load) navigateRefresh = TRUE; if (FileIsRemote(full_fname)) { char *buf=NULL, *content_type=NULL, final_url[MAXPATHLENGTH+1]; int rc, buf_sz=0, is_html=FALSE; *final_url = '\0'; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); rc = LoadRemoteFileInMem(full_fname, &buf, &content_type, &buf_sz, &is_html, force_load, final_url, sizeof(final_url)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (rc && buf != NULL) { navigatingBackAndForth = TRUE; if (*final_url != '\0') { LoadRemoteFileFromMem(final_url, buf, content_type, buf_sz, is_html); } else { LoadRemoteFileFromMem(full_fname, buf, content_type, buf_sz, is_html); } navigatingBackAndForth = FALSE; } else if (do_not_save) { SetFileModified(TRUE); } if (content_type != NULL) FreeRemoteBuf(content_type); if (buf != NULL) FreeRemoteBuf(buf); } else { int obj_file=FALSE, gzipped=FALSE; navigatingBackAndForth = TRUE; obj_file = FileNameHasExtension(full_fname, OBJ_FILE_TYPE, &gzipped, NULL); if (!LoadFile(full_fname, obj_file, obj_file && gzipped)) { if (do_not_save) { SetFileModified(TRUE); } } navigatingBackAndForth = FALSE; } navigateRefresh = FALSE; } void NavigateBack() { int do_not_save=FALSE; struct NavigateRec nr; if (curNavigate != NULL && curNavigate->stk != NULL && curNavigate->stk == topStk && (curNavigate->prev == NULL || (curNavigate->prev != NULL && curNavigate->prev->stk != topStk))) { /* curNavigate->stk = NULL; */ /* if (curFileDefined) curNavigate = curNavigate->prev; */ PopIcon(); return; } while (!DirIsRemote(curDir) && fileModified && !IsFiletUnSavable()) { XBell(mainDisplay, 0); switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_BACK), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: do_not_save=TRUE; SetFileModified(FALSE); break; case MB_ID_CANCEL: return; } } if (!DirIsRemote(curDir) && fileModified && IsFiletUnSavable()) { do_not_save = TRUE; SetFileModified(FALSE); } MakeQuiescent(); if (curNavigate == NULL || (curFileDefined && curNavigate->prev == NULL)) { MsgBox(TgLoadString(STID_NOTHING_TO_GO_BACK_TO), TOOL_NAME, INFO_MB); if (do_not_save) SetFileModified(TRUE); return; } BeforeNavigate(); if (curFileDefined) curNavigate = curNavigate->prev; memcpy(&nr, curNavigate, sizeof(struct NavigateRec)); NavigateTo(curNavigate->full_fname, do_not_save, FALSE); PostNavigate(&nr); SetCurChoice(curChoiceBeforeMakeQuiescent); } void NavigateForward() { int do_not_save=FALSE; struct NavigateRec nr; while (!DirIsRemote(curDir) && fileModified && !IsFiletUnSavable()) { XBell(mainDisplay, 0); switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_FORWARD), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: do_not_save=TRUE; SetFileModified(FALSE); break; case MB_ID_CANCEL: return; } } if (!DirIsRemote(curDir) && fileModified && IsFiletUnSavable()) { do_not_save = TRUE; SetFileModified(FALSE); } MakeQuiescent(); if (curNavigate == lastNavigate) { MsgBox(TgLoadString(STID_NOTHING_TO_GO_FORWARD_TO), TOOL_NAME, INFO_MB); if (do_not_save) SetFileModified(TRUE); return; } BeforeNavigate(); if (curFileDefined) curNavigate = curNavigate->next; memcpy(&nr, curNavigate, sizeof(struct NavigateRec)); NavigateTo(curNavigate->full_fname, do_not_save, FALSE); PostNavigate(&nr); SetCurChoice(curChoiceBeforeMakeQuiescent); } void AdjustNavigate() { while (curNavigate != NULL && curNavigate->stk != NULL && curNavigate->stk == topStk) { curNavigate->stk = NULL; if (curNavigate->prev == NULL || (curNavigate->prev != NULL && curNavigate->prev->stk != topStk)) { if (curFileDefined && curNavigate->prev != NULL) { curNavigate = curNavigate->prev; } return; } else { curNavigate = curNavigate->prev; } } sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_FIND_RECORD_IN_FUNC), "AdjustNavigate()"); FatalUnexpectedError(gszMsgBox, TgLoadString(STID_FURTHER_NAVIGATE_MAY_CRASH)); } void NavigateRefresh() { if (!curFileDefined) { MsgBox(TgLoadString(STID_CANT_REFRESH_UNDEFINED_FILE), TOOL_NAME, INFO_MB); return; } while (!DirIsRemote(curDir) && fileModified && !IsFiletUnSavable()) { XBell(mainDisplay, 0); switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_RELOAD), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: SetFileModified(FALSE); break; case MB_ID_CANCEL: return; } } if (!DirIsRemote(curDir) && fileModified && IsFiletUnSavable()) { SetFileModified(FALSE); } NavigateTo(curNavigate->full_fname, TRUE, TRUE); PostNavigate(NULL); } static char **ReadHotListFile(pn_count) int *pn_count; { FILE *fp; char **ppsz_buf=NULL, *buf; int num_lines=0; if (pn_count != NULL) *pn_count = 0; if (!InitHotListFileName() || hotListFileName==NULL) { sprintf(gszMsgBox, TgLoadString(STID_HOT_LIST_FILE_UNDEF_PLS_SPEC), TOOL_NAME, "HotListFileName"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } if ((ppsz_buf=(char**)malloc((num_lines+1)*sizeof(char*))) == NULL) { FailAllocMessage(); return NULL; } if ((fp=fopen(hotListFileName, "r")) == NULL) { ppsz_buf[num_lines] = NULL; return ppsz_buf; } while ((buf=UtilGetALine(fp)) != NULL) { if ((ppsz_buf=(char**)realloc(ppsz_buf, ((++num_lines)+1)*sizeof(char*))) == NULL) { FailAllocMessage(); return NULL; } ppsz_buf[num_lines-1] = buf; } ppsz_buf[num_lines] = NULL; if ((num_lines & 0x1) != 0) { ppsz_buf[num_lines-1] = NULL; sprintf(gszMsgBox, TgLoadString(STID_MALFORMED_NAMED_HOT_LIST_FILE), hotListFileName); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } fclose(fp); if (pn_count != NULL) *pn_count = (num_lines>>1); return ppsz_buf; } static DspList *HotListListing(ppsz_buf, pn_count) char **ppsz_buf; int *pn_count; { int i; char **s_ptr; DspList *pdl, *dsp_ptr; *pn_count = 0; for (s_ptr=ppsz_buf; *s_ptr != NULL; s_ptr=(&s_ptr[2])) { (*pn_count)++; } pdl = (DspList*)malloc((*pn_count)*sizeof(DspList)); if (pdl == NULL) FailAllocMessage(); memset(pdl, 0, (*pn_count)*sizeof(DspList)); for (i=(*pn_count)-1, dsp_ptr=pdl, s_ptr=ppsz_buf; *s_ptr != NULL; i--, dsp_ptr++, s_ptr=(&s_ptr[2])) { if (**s_ptr == '\0') { UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), s_ptr[1]); dsp_ptr->directory = FALSE; /* use file name as title */ } else { UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), s_ptr[0]); dsp_ptr->directory = TRUE; /* file has a title */ } UtilStrCpyN(dsp_ptr->pathstr, sizeof(dsp_ptr->pathstr), s_ptr[1]); dsp_ptr->next = (i==0 ? NULL : &dsp_ptr[1]); } return pdl; } static DspList *HistoryListing(pn_count) int *pn_count; { int i; struct NavigateRec *pnr; DspList *pdl, *dsp_ptr; *pn_count = 0; for (pnr=lastSessionHistory; pnr != NULL; pnr=pnr->prev) { (*pn_count)++; } if (*pn_count == 0) return NULL; pdl = (DspList*)malloc((*pn_count)*sizeof(DspList)); if (pdl == NULL) FailAllocMessage(); memset(pdl, 0, (*pn_count)*sizeof(DspList)); for (i=0, dsp_ptr=pdl, pnr=firstSessionHistory; pnr != NULL; i++, dsp_ptr++, pnr=pnr->next) { if (pnr->doc_name == NULL) { UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), pnr->full_fname); dsp_ptr->directory = FALSE; /* use file name as title */ } else { UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), pnr->doc_name); dsp_ptr->directory = TRUE; /* file has a title */ } UtilStrCpyN(dsp_ptr->pathstr, sizeof(dsp_ptr->pathstr), pnr->full_fname); dsp_ptr->next = (i==(*pn_count)-1 ? NULL : &dsp_ptr[1]); } return pdl; } struct HotListInfoRec { char **ppsz_buf; }; #define GOTO_BUTTON 101 #define DELETE_BUTTON 102 #define CLOSE_BUTTON 103 static int GetHotListEntries(p_dsp_ptr, p_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, p_void) DspList **p_dsp_ptr; char ***p_entries, *cur_buf; int *pn_num_entries, *pn_marked_index; struct CheckArrayRec **pp_check_array; void *p_void; { struct HotListInfoRec *p_hlinfo=(struct HotListInfoRec *)p_void; p_hlinfo->ppsz_buf = ReadHotListFile(NULL); if (p_hlinfo->ppsz_buf == NULL) { return FALSE; } else if (*p_hlinfo->ppsz_buf == NULL) { MsgBox(TgLoadString(STID_HOT_LIST_FILE_IS_EMPTY), TOOL_NAME, INFO_MB); free(p_hlinfo->ppsz_buf); p_hlinfo->ppsz_buf = NULL; return FALSE; } else { *p_dsp_ptr = HotListListing(p_hlinfo->ppsz_buf, pn_num_entries); ignoreDirectoryFlag = TRUE; *p_entries = MakeNameDspItemArray(*pn_num_entries, *p_dsp_ptr); ignoreDirectoryFlag = FALSE; } return TRUE; } static int HotListAfterLoop(p_dsp_ptr, p_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, btn_id, selected_index, p_void) DspList **p_dsp_ptr; char ***p_entries, *cur_buf; int *pn_num_entries, *pn_marked_index, btn_id, selected_index; struct CheckArrayRec **pp_check_array; void *p_void; { int i, modified=FALSE, something_deleted=FALSE, goto_something=FALSE; int navigated_to=FALSE; struct HotListInfoRec *p_hlinfo=(struct HotListInfoRec *)p_void; char **s_ptr; switch (btn_id) { case GOTO_BUTTON: goto_something=TRUE; break; case DELETE_BUTTON: something_deleted=TRUE; break; } for (s_ptr=p_hlinfo->ppsz_buf, i=0; *s_ptr != NULL; s_ptr=(&s_ptr[2]), i++) { if (something_deleted && i == (*pn_marked_index)) { sprintf(gszMsgBox, TgLoadString(STID_Q_DEL_NAMED_FROM_HOT_LIST), (**s_ptr == '\0' ? s_ptr[1] : *s_ptr)); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB)==MB_ID_YES) { *s_ptr[0] = *s_ptr[1] = '\0'; modified = TRUE; continue; } } if (*s_ptr[0] == '\0') { if (strcmp((*p_entries)[i], s_ptr[1]) != 0) { free(*s_ptr); if (((*s_ptr)=UtilStrDup((*p_entries)[i])) == NULL) { FailAllocMessage(); } modified = TRUE; } } else { if (strcmp((*p_entries)[i], *s_ptr) != 0) { free(*s_ptr); if (((*s_ptr)=UtilStrDup((*p_entries)[i])) == NULL) { FailAllocMessage(); } modified = TRUE; } } } if (modified || something_deleted) { FILE *fp; if ((fp=fopen(hotListFileName, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), hotListFileName); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { for (s_ptr=p_hlinfo->ppsz_buf; *s_ptr != NULL; s_ptr=(&s_ptr[2])) { if (!(**s_ptr == '\0' && *s_ptr[1] == '\0')) { fprintf(fp, "%s\n%s\n", *s_ptr, s_ptr[1]); } } fclose(fp); } } free(*p_dsp_ptr); free(**p_entries); free(*p_entries); *p_entries = NULL; if (goto_something) { int do_not_save=FALSE, canceled=FALSE; while (!canceled && !DirIsRemote(curDir) && fileModified && !IsFiletUnSavable()) { switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_OPEN_ANO), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: do_not_save=TRUE; SetFileModified(FALSE); break; case MB_ID_CANCEL: canceled=TRUE; break; } } if (!canceled && !DirIsRemote(curDir) && fileModified && IsFiletUnSavable()) { do_not_save = TRUE; SetFileModified(FALSE); } if (!canceled) { for (i=0, s_ptr=p_hlinfo->ppsz_buf; *s_ptr != NULL; s_ptr=(&s_ptr[2]), i++) { if (i == (*pn_marked_index)) { NavigateTo(s_ptr[1], do_not_save, FALSE); CommitNavigate(); navigated_to = TRUE; break; } } } } for (s_ptr=p_hlinfo->ppsz_buf; *s_ptr != NULL; s_ptr++) free(*s_ptr); free(p_hlinfo->ppsz_buf); p_hlinfo->ppsz_buf = NULL; if (something_deleted) { if (modified) { (*pn_marked_index)--; } } else if (!goto_something) { (*pn_marked_index) = (*pn_num_entries)-1; } if ((*pn_marked_index) < 0) (*pn_marked_index) = INVALID; if (navigated_to) { PostNavigate(NULL); } return TRUE; } static int GetHistoryEntries(p_dsp_ptr, p_entries, pn_num_entries, pn_marked_index, cur_buf, p_void) DspList **p_dsp_ptr; char ***p_entries, *cur_buf; int *pn_num_entries, *pn_marked_index; void *p_void; { *p_dsp_ptr = HistoryListing(pn_num_entries); if (*p_dsp_ptr == NULL) { MsgBox(TgLoadString(STID_SESSION_HIST_NOT_ESTABLISHED), TOOL_NAME, INFO_MB); return FALSE; } else { ignoreDirectoryFlag = TRUE; *p_entries = MakeNameDspItemArray(*pn_num_entries, *p_dsp_ptr); ignoreDirectoryFlag = FALSE; if (*pn_marked_index == INVALID) { *pn_marked_index = (*pn_num_entries)-1; } } return TRUE; } static int HistoryAfterLoop(p_dsp_ptr, p_entries, pn_num_entries, pn_marked_index, cur_buf, btn_id, selected_index, p_void) DspList **p_dsp_ptr; char ***p_entries, *cur_buf; int *pn_num_entries, *pn_marked_index, btn_id, selected_index; void *p_void; { int goto_something=(btn_id == GOTO_BUTTON), navigated_to=FALSE; free(*p_dsp_ptr); free(**p_entries); free(*p_entries); *p_entries = NULL; if (goto_something) { int do_not_save=FALSE, canceled=FALSE; while (!canceled && !DirIsRemote(curDir) && fileModified && !IsFiletUnSavable()) { switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_OPEN_ANO), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: do_not_save=TRUE; SetFileModified(FALSE); break; case MB_ID_CANCEL: canceled=TRUE; break; } } if (!canceled && !DirIsRemote(curDir) && fileModified && IsFiletUnSavable()) { do_not_save = TRUE; SetFileModified(FALSE); } if (!canceled) { int i; struct NavigateRec *pnr; pnr = firstSessionHistory; for (i=0; pnr != NULL; pnr=pnr->next, i++) { if (i == (*pn_marked_index)) { NavigateTo(pnr->full_fname, do_not_save, FALSE); CommitNavigate(); navigated_to = TRUE; break; } } } } if (navigated_to) { PostNavigate(NULL); } return TRUE; } static void SelectForNavigate(TopStr, Which) char *TopStr; int Which; /* either NAVIGATE_HOTLIST or NAVIGATE_HISTORY */ { char win_name[128]; struct HotListInfoRec hlinfo; memset(&hlinfo, 0, sizeof(struct HotListInfoRec)); ResetNamesInfo(); NamesSetTitle(TopStr); NamesSetDefaultBtnId(GOTO_BUTTON, GOTO_BUTTON); NamesSetEntries(NULL, NULL, 0, NULL, TRUE, INVALID, 0); switch (Which) { case NAVIGATE_HOTLIST: NamesAddButton(TgLoadCachedString(CSTID_GOTO), GOTO_BUTTON); NamesAddButton(TgLoadCachedString(CSTID_DELETE), DELETE_BUTTON); NamesAddButton(TgLoadCachedString(CSTID_CLOSE), BUTTON_CANCEL); NamesSetStyle(NAMES_EDIT_NAME, NAMES_LOOP_MANY); NamesSetCallback((GetEntriesFunc*)GetHotListEntries, (AfterLoopFunc*)HotListAfterLoop, NULL); sprintf(win_name, TgLoadString(STID_TOOL_HOT_LIST), TOOL_NAME); break; case NAVIGATE_HISTORY: NamesAddButton(TgLoadCachedString(CSTID_GOTO), GOTO_BUTTON); NamesAddButton(TgLoadCachedString(CSTID_CLOSE), BUTTON_CANCEL); NamesSetStyle(NAMES_COMPLEX_SELECT_NAME, NAMES_LOOP_MANY); NamesSetCallback((GetEntriesFunc*)GetHistoryEntries, (AfterLoopFunc*)HistoryAfterLoop, NULL); sprintf(win_name, TgLoadString(STID_TOOL_HOT_LIST), TOOL_NAME); break; default: return; } Names(win_name, NULL, NULL, 0, &hlinfo); } void NavigateHotList() { MakeQuiescent(); if (!InitHotListFileName() || hotListFileName==NULL) { sprintf(gszMsgBox, TgLoadString(STID_HOT_LIST_FILE_UNDEF_PLS_SPEC), TOOL_NAME, "HotListFileName"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } SelectForNavigate(TgLoadString(STID_HOT_LIST_DOTS), NAVIGATE_HOTLIST); SetCurChoice(curChoiceBeforeMakeQuiescent); } void NavigateAddToHotList() { int len=strlen(curDir)+1+strlen(curFileName), num_entries=0; char **s_ptr, **ppsz_buf, *full_fname; FILE *fp; if (!curFileDefined) { MsgBox(TgLoadString(STID_CANT_ADD_UNDEF_TO_HOT_LIST), TOOL_NAME, INFO_MB); return; } if ((full_fname=(char*)malloc((len+1)*sizeof(char))) == NULL) { FailAllocMessage(); return; } sprintf(full_fname, "%s%c%s", curDir, DIR_SEP, curFileName); if ((ppsz_buf=ReadHotListFile(&num_entries)) == NULL) return; if ((fp=fopen(hotListFileName, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), hotListFileName); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(full_fname); return; } for (s_ptr=ppsz_buf; *s_ptr != NULL; s_ptr=(&s_ptr[2])) { if (strcmp(s_ptr[1], full_fname) == 0) { char **s_ptr1; if (s_ptr[2] != NULL) { for (s_ptr1=ppsz_buf; s_ptr1 != s_ptr; s_ptr1++) { fprintf(fp, "%s\n", *s_ptr1); } for (s_ptr1=(&s_ptr[2]); *s_ptr1 != NULL; s_ptr1++) { fprintf(fp, "%s\n", *s_ptr1); } } else { for (s_ptr1=ppsz_buf; s_ptr1 != s_ptr; s_ptr1++) { fprintf(fp, "%s\n", *s_ptr1); } } fprintf(fp, "%s\n", (firstPage->name==NULL ? "" : firstPage->name)); fprintf(fp, "%s\n", full_fname); break; } } if (*s_ptr == NULL) { for (s_ptr=ppsz_buf; *s_ptr != NULL; s_ptr++) { fprintf(fp, "%s\n", *s_ptr); } fprintf(fp, "%s\n", (firstPage->name==NULL ? "" : firstPage->name)); fprintf(fp, "%s\n", full_fname); num_entries++; } for (s_ptr=ppsz_buf; *s_ptr != NULL; s_ptr++) free(*s_ptr); free(ppsz_buf); fclose(fp); free(full_fname); Msg(TgLoadString(STID_HOT_LIST_FILE_UPDATED)); } void NavigateSessionHistory() { MakeQuiescent(); SelectForNavigate(TgLoadString(STID_SESSION_HISTORY_DOTS), NAVIGATE_HISTORY); SetCurChoice(curChoiceBeforeMakeQuiescent); } void ToggleHyperSpace(KeepSelected) int KeepSelected; { inHyperSpace = !inHyperSpace; if (inHyperSpace) { if (!KeepSelected) MakeQuiescent(); Msg(TgLoadString(STID_ENTER_HYPERSPACE_DOTS)); } else { ShowCursor(); Msg(TgLoadString(STID_LEAVING_HYPERSPACE_DOTS)); } UpdatePinnedMenu(MENU_NAVIGATE); RedrawDummyWindow1(); } void NextSlide() { struct ObjRec *obj_ptr=FindTopLevelObjWithType("page_defaultplay"); if (obj_ptr != NULL) { struct AttrRec *exec_attr=FindObjAttrWithName(obj_ptr, "exec="); struct AttrRec *attr_ptr=FindObjAttrWithName(obj_ptr, "finished="); if (exec_attr != NULL && attr_ptr != NULL) { char *attr_value=attr_ptr->attr_value.s; if (strcmp(attr_value, "0") == 0) { DoExecLoop(obj_ptr, exec_attr); /* * if (!userAbortExec) { * ReplaceAttrFirstValue(obj_ptr, attr_ptr, "1"); * } */ return; } } } NextPage(); } void PrevSlide() { struct ObjRec *obj_ptr=FindTopLevelObjWithType("page_defaultrewind"); if (obj_ptr != NULL) { struct AttrRec *exec_attr=FindObjAttrWithName(obj_ptr, "exec="); struct AttrRec *attr_ptr=FindObjAttrWithName(obj_ptr, "finished="); if (exec_attr != NULL && attr_ptr != NULL) { char *attr_value=attr_ptr->attr_value.s; if (strcmp(attr_value, "0") == 0) { DoExecLoop(obj_ptr, exec_attr); /* * if (!userAbortExec) { * ReplaceAttrFirstValue(obj_ptr, attr_ptr, "1"); * } */ return; } } } PrevPage(); } struct SlideShowInfoRec { int saved_in_hyperspace; int saved_fill, saved_pen; int saved_line_width, saved_line_style, saved_cur_dash; }; static struct SlideShowInfoRec gstSlideShow; static void HideAllWindowsForSlideShow() { int i=0; if (canvasWindowOnly || !hideWindowsInSlideShow) return; XUnmapWindow(mainDisplay, titleWindow); if (menubarWindow != None) XUnmapWindow(mainDisplay, menubarWindow); if (!noChoiceWindow) XUnmapWindow(mainDisplay, msgWindow); if (!noChoiceWindow) XUnmapWindow(mainDisplay, choiceWindow); XUnmapWindow(mainDisplay, hRuleWindow); XUnmapWindow(mainDisplay, vRuleWindow); XUnmapWindow(mainDisplay, colorWindow); XUnmapWindow(mainDisplay, colorDummyWindow); XUnmapWindow(mainDisplay, vSBarWindow); XUnmapWindow(mainDisplay, pageWindow); XUnmapWindow(mainDisplay, pageDummyWindow); XUnmapWindow(mainDisplay, hSBarWindow); XUnmapWindow(mainDisplay, dummyWindow1); XUnmapWindow(mainDisplay, dummyWindow2); if (!noChatWindow) XUnmapWindow(mainDisplay, chatWindow); if (!noStatusWindow) { XUnmapWindow(mainDisplay, userRedrawWindow); XUnmapWindow(mainDisplay, statusWindow); for (i=0; i < MAX_STATUS_BTNS; i++) { XUnmapWindow(mainDisplay, statusSubWindow[i]); } } if (!noModeWindow) XUnmapWindow(mainDisplay, modeWindow); } static void ShowAllWindowsForSlideShow() { int i=0; if (canvasWindowOnly || !hideWindowsInSlideShow) return; XMapWindow(mainDisplay, titleWindow); if (menubarWindow != None) XMapWindow(mainDisplay, menubarWindow); if (!noChoiceWindow) XMapWindow(mainDisplay, msgWindow); if (!noChoiceWindow) XMapWindow(mainDisplay, choiceWindow); XMapWindow(mainDisplay, hRuleWindow); XMapWindow(mainDisplay, vRuleWindow); XMapWindow(mainDisplay, colorWindow); XMapWindow(mainDisplay, colorDummyWindow); XMapWindow(mainDisplay, vSBarWindow); XMapWindow(mainDisplay, pageWindow); XMapWindow(mainDisplay, pageDummyWindow); XMapWindow(mainDisplay, hSBarWindow); XMapWindow(mainDisplay, dummyWindow1); XMapWindow(mainDisplay, dummyWindow2); if (!noChatWindow) XMapWindow(mainDisplay, chatWindow); if (!noStatusWindow) { XMapWindow(mainDisplay, userRedrawWindow); XMapWindow(mainDisplay, statusWindow); for (i=0; i < MAX_STATUS_BTNS; i++) { XMapWindow(mainDisplay, statusSubWindow[i]); } } if (!noModeWindow) XMapWindow(mainDisplay, modeWindow); } static void StartSlideShow() { struct AttrRec *exec_attr=FindFileAttrWithName("start_slide_show="); gstSlideShow.saved_in_hyperspace = inHyperSpace; gstSlideShow.saved_fill = objFill; gstSlideShow.saved_pen = penPat; gstSlideShow.saved_line_width = lineWidth; gstSlideShow.saved_line_style = lineStyle; gstSlideShow.saved_cur_dash = curDash; objFill = NONEPAT; penPat = SOLIDPAT; lineStyle = LS_PLAIN; curDash = 0; lineWidth = lineWidthIndexInSlideShow; if (!goHyperSpaceInSlideShow) { SetCurChoice(FREEHAND); } if (slideShowBorderColor != NULL) { int new_alloc=FALSE, index=0; index = QuickFindColorIndex(NULL, slideShowBorderColor, &new_alloc, FALSE); if (index != INVALID) { XSetWindowBackground(mainDisplay, mainWindow, colorPixels[index]); } } else if (myFileBgColorStr != NULL && myFileBgPixel != INVALID) { XSetWindowBackground(mainDisplay, mainWindow, myFileBgPixel); } if (goHyperSpaceInSlideShow && !inHyperSpace) { ToggleHyperSpace(FALSE); } FixPageNumbersForSlideShow(); ClearObjCachesInAllPages(); HideAllWindowsForSlideShow(); HidePopupMenusForSlideShow(); RecordWBSlideShow(TRUE); if (exec_attr != NULL) { DoExecLoop(NULL, exec_attr); } } static void EndSlideShow() { XSetWindowBackground(mainDisplay, mainWindow, myBgPixel); RecordWBSlideShow(FALSE); ShowAllWindowsForSlideShow(); ShowPopupMenusForSlideShow(); ClearObjCachesInAllPages(); if (gstSlideShow.saved_in_hyperspace != inHyperSpace) { ToggleHyperSpace(FALSE); } objFill = gstSlideShow.saved_fill; penPat = gstSlideShow.saved_pen; lineWidth = gstSlideShow.saved_line_width; lineStyle = gstSlideShow.saved_line_style; curDash = gstSlideShow.saved_cur_dash; ShowFill(); ShowPen(); ShowLineWidth(); ShowLineStyle(); ShowDash(); UpdatePinnedMenu(MENU_FILL); UpdatePinnedMenu(MENU_PEN); UpdatePinnedMenu(MENU_LINEWIDTH); UpdatePinnedMenu(MENU_LINESTYLE); UpdatePinnedMenu(MENU_LINEDASH); MakeQuiescent(); } static void ToggleSlideShow() { int need_to_restore_cur_choice=FALSE; if (!inSlideShow) { if (pageLayoutMode == PAGE_TILE) { switch (MsgBox(TgLoadString(STID_CANT_SLIDESHOW_IN_TILED_PAGE), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SetUnSavableFile(TRUE); break; case MB_ID_NO: return; case MB_ID_CANCEL: return; } PageLayoutSubMenu(PAGE_STACK); if (pageLayoutMode != PAGE_STACK) return; } else { if (fileModified && !IsFiletUnSavable() && ((curFileDefined && !DirIsRemote(curDir)) || !curFileDefined)) { XBell(mainDisplay, 0); switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_SLIDE), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: break; case MB_ID_CANCEL: return; } } if (!IsFiletUnSavable() && (makeUnsavableInSlideShow || NeedToFixPageNumbersForSlideShow())) { if (!makeUnsavableInSlideShow) { sprintf(gszMsgBox, TgLoadString(STID_Q_PAGE_NUM_MOD_IN_SLIDE_YNC), TOOL_NAME); switch (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB)) { case MB_ID_YES: break; case MB_ID_NO: return; case MB_ID_CANCEL: return; } } SetUnSavableFile(TRUE); } } MakeQuiescent(); need_to_restore_cur_choice = TRUE; } inSlideShow = !inSlideShow; if (inSlideShow) { Msg(TgLoadString(STID_ENTERING_SLIDESHOW_DOTS)); StartSlideShow(); } else { ShowCursor(); Msg(TgLoadString(STID_LEAVING_SLIDESHOW_DOTS)); EndSlideShow(); } RedrawDummyWindow1(); if (need_to_restore_cur_choice) SetCurChoice(curChoiceBeforeMakeQuiescent); } void EnterSlideShow() { if (!inSlideShow) ToggleSlideShow(); } void LeaveSlideShow() { if (inSlideShow) ToggleSlideShow(); } void SetSlideShowBorderColor() { char spec[MAXSTRING]; int new_alloc=0; *spec = '\0'; if (Dialog(TgLoadString(STID_ENTER_A_COLOR_FOR_SLIDE_BRDR), TgLoadString(STID_PRESS_ENTER_FOR_DEF_COLOR), spec) == INVALID) { return; } UtilTrimBlanks(spec); if (*spec == '\0') { if (slideShowBorderColor != NULL) UtilFree(slideShowBorderColor); slideShowBorderColor = NULL; Msg(TgLoadString(STID_SLIDE_WILL_USE_DEF_BRDR_COLOR)); if (slideShowXOffset == 0 && slideShowYOffset == 0) { slideShowInfoValid = FALSE; } return; } if (QuickFindColorIndex(NULL, spec, &new_alloc, FALSE) == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (slideShowBorderColor != NULL) UtilFree(slideShowBorderColor); slideShowBorderColor = UtilStrDup(spec); if (slideShowBorderColor == NULL) FailAllocMessage(); slideShowInfoValid = TRUE; sprintf(gszMsgBox, TgLoadString(STID_SLIDE_BRDR_COLOR_SET_TO_NAMED), slideShowBorderColor); Msg(gszMsgBox); } void SetSlideShowWindowOffsets() { char spec[MAXSTRING]; *spec = '\0'; sprintf(gszMsgBox, TgLoadString(STID_ENTER_XY_OFFSET_FOR_SLIDE_WIN), slideShowXOffset, slideShowYOffset); if (Dialog(gszMsgBox, NULL, spec) == INVALID) return; UtilTrimBlanks(spec); if (*spec == '\0') return; if (ParseXYSpec(spec, &slideShowXOffset, &slideShowYOffset)) { sprintf(gszMsgBox, TgLoadString(STID_SLIDE_WIN_XY_OFFSETS_SET_TO), slideShowXOffset, slideShowYOffset); Msg(gszMsgBox); savedSlideShowXOffset = slideShowXOffset; savedSlideShowYOffset = slideShowYOffset; savedSlideShowOffsets = TRUE; } slideShowInfoValid = TRUE; } void ToggleVisibleGridInSlideShow() { visibleGridInSlideShow = (!visibleGridInSlideShow); Msg(TgLoadString(visibleGridInSlideShow ? STID_GRID_BE_VISIBLE_IN_SLIDE : STID_GRID_NOT_BE_VISIBLE_IN_SLIDE)); } void GoHyperSpaceInSlideShow() { if (goHyperSpaceInSlideShow) return; goHyperSpaceInSlideShow = TRUE; Msg(TgLoadString(STID_GO_HYPERSPACE_IN_SLIDE)); if (inSlideShow) { if (!inHyperSpace) { inSlideShow = FALSE; ToggleHyperSpace(FALSE); inSlideShow = TRUE; } } } void FreehandModeInSlideShow() { if (!goHyperSpaceInSlideShow) return; goHyperSpaceInSlideShow = FALSE; Msg(TgLoadString(STID_DONT_GO_HYPERSPACE_IN_SLIDE)); if (inSlideShow) { if (inHyperSpace) { ToggleHyperSpace(FALSE); } SetCurChoice(FREEHAND); } } int RefreshSlideShowModeMenu(menu) TgMenu *menu; { int ok=TRUE; /* GoHyperSpaceInSlideShow */ ok &= TgSetMenuItemRadioById(menu, CMDID_GOHYPERSPACEINSLIDESHOW, goHyperSpaceInSlideShow); /* FreehandModeInSlideShow */ ok &= TgSetMenuItemRadioById(menu, CMDID_FREEHANDMODEINSLIDESHOW, !goHyperSpaceInSlideShow); /* ColorMenu */ if (goHyperSpaceInSlideShow) { ok &= TgEnableMenuItemById(menu, MENU_COLOR, FALSE); } return ok; } TgMenu *CreateSlideShowModeMenu(parent_menu, X, Y, menu_info, status_str_xlated) TgMenu *parent_menu; int X, Y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, X, Y, menu_info, FALSE); if (menu != NULL) { if (!RefreshSlideShowModeMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshSlideShowModeMenu); } return menu; } int SlideShowModeMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(slideShowModeMenuInfo.create_proc)(NULL, X, Y, &slideShowModeMenuInfo, INVALID); activeMenu = INVALID; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } int RefreshSlideShowMenu(menu) TgMenu *menu; { int ok=TRUE; /* SlideShow */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLESLIDESHOW, inSlideShow); /* VisibleGridInSlideShow */ ok &= TgSetMenuItemCheckById(menu, CMDID_VISIBLEGRIDINSLIDESHOW, visibleGridInSlideShow); /* GoHyperSpaceInSlideShow */ ok &= TgSetMenuItemRadioById(menu, CMDID_GOHYPERSPACEINSLIDESHOW, goHyperSpaceInSlideShow); /* FreehandModeInSlideShow */ ok &= TgSetMenuItemRadioById(menu, CMDID_FREEHANDMODEINSLIDESHOW, !goHyperSpaceInSlideShow); if (inSlideShow) { ok &= TgEnableMenuItemById(menu, CMDID_GOHYPERSPACEINSLIDESHOW, FALSE); ok &= TgEnableMenuItemById(menu, CMDID_FREEHANDMODEINSLIDESHOW, FALSE); } return ok; } TgMenu *CreateSlideShowMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshSlideShowMenu(menu)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int ReadSlideShowInfo(buf) char *buf; { if (!importingFile) { int x=0, y=0; char color_str[40], *psz=FindChar((int)'(', buf); *color_str = '\0'; psz = ParseStr(psz, (int)',', color_str, sizeof(color_str)); InitScan(psz, "\t\n, []"); if (GETINT("slideshow_info", x, "x offset") == INVALID || GETINT("slideshow_info", y, "y offset") == INVALID) { return FALSE; } CleanUpSlideShowInfo(); UtilTrimBlanks(color_str); if (*color_str != '\0') { slideShowBorderColor = UtilStrDup(color_str); if (slideShowBorderColor == NULL) FailAllocMessage(); } if (!ignoreSlideShowOffsetsInFile) { slideShowXOffset = x; slideShowYOffset = y; } else if (savedSlideShowOffsets) { slideShowXOffset = savedSlideShowXOffset; slideShowYOffset = savedSlideShowYOffset; } slideShowInfoValid = TRUE; } return TRUE; } void RefreshNavigateMenu(menu) TgMenu *menu; { TgMenuItem *menu_item=FindMenuItemByCmdId(menu, CMDID_TOGGLEHYPERSPACE); TgMenuItem stMenuItem; if (menu_item == NULL) return; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = inHyperSpace; TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem); } TgMenu *CreateNavigateMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { TgMenuItem *menu_item=FindMenuItemByCmdId(menu, CMDID_TOGGLEHYPERSPACE); TgMenuItem stMenuItem; if (menu_item == NULL) return TgDestroyMenu(menu, TRUE); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = inHyperSpace; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int NavigateMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(navigateMenuInfo.create_proc)(NULL, X, Y, &navigateMenuInfo, INVALID); activeMenu = MENU_NAVIGATE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } tgif-QPL-4.2.5/arc.c0000644000076400007640000024165211602233310013705 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/arc.c,v 1.9 2011/05/16 16:21:56 william Exp $ */ #define _INCLUDE_FROM_ARC_C_ #include "tgifdefs.h" #include "arc.e" #include "attr.e" #include "auxtext.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "grid.e" #include "mainloop.e" #include "mark.e" #include "msg.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "poly.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "special.e" #include "spline.e" #include "strtbl.e" #include "util.e" #include "xpixmap.e" #define EXPAND_BBOX(bbox,x,y) \ if ((x)<(bbox)->ltx) (bbox)->ltx=(x); if ((y)<(bbox)->lty) (bbox)->lty=(y); \ if ((x)>(bbox)->rbx) (bbox)->rbx=(x); if ((y)>(bbox)->rby) (bbox)->rby=(y) int arcDrawn=FALSE; /* * 0 degree is horizontal in the direction of the X axis. * Positive angles measures counter-clockwise from 0 degree. * Negative angles measures clockwise from 0 degree. * Angle1 means the start angle. * Angle2 means the amount between angle1 and the real angle2. */ static int ArcDirection(xc, yc, x1, y1, x2, y2) int xc, yc, x1, y1, x2, y2; { register int dx, dy; register double theta1, theta2; dx = x1-xc; dy = y1-yc; theta1 = (dx==0) ? ((dy>=0) ? M_PI/2.0 : -M_PI/2.0) : atan2 ((double)(dy), (double)(dx)); theta2 = (x2==xc) ? ((y2>=yc) ? M_PI/2.0 : -M_PI/2.0) : atan2 ((double)(y2-yc), (double)(x2-xc)); if (theta1 < 0) theta1 += 2*M_PI; if (theta2 < 0) theta2 += 2*M_PI; if (theta2 > theta1) { if (theta2-theta1 >= 2*M_PI-theta2+theta1) { return ARC_CCW; } else { return ARC_CW; } } else if (theta1 > theta2) { if (theta1-theta2 >= 2*M_PI-theta1+theta2) { return ARC_CW; } else { return ARC_CCW; } } else { return ARC_CCW; } } void PointsToArc(xc, yc, x1, y1, x2, y2, dir, int_degree, ltx, lty, w, h, angle1, angle2) int xc, yc, x1, y1, x2, y2, dir, int_degree; int *ltx, *lty, *w, *h, *angle1, *angle2; /* Only good if the points are part of a circle, not an oval */ { register int dx, dy, radius; double tmp_theta; dx = x1-xc; dy = y1-yc; radius = (int)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); if (ltx != NULL) *ltx = xc-radius; if (lty != NULL) *lty = yc-radius; if (w != NULL) *w = (radius<<1); if (h != NULL) *h = (radius<<1); if (int_degree) { int theta1, theta2, d_theta; tmp_theta = (dx==0) ? ((dy>=0) ? M_PI/2.0 : -M_PI/2.0) : atan2 ((double)(dy),(double)(dx)); theta1 = (int)(tmp_theta/M_PI*(-180.0)); tmp_theta = (x2==xc) ? ((y2>=yc) ? M_PI/2.0 : -M_PI/2.0) : atan2 ((double)(y2-yc),(double)(x2-xc)); theta2 = (int)(tmp_theta/M_PI*(-180.0)); /* NOTE: *angle1 must be between -180 degrees and +180 degrees */ if (angle1 != NULL) *angle1 = theta1*64; d_theta = theta2-theta1; switch (dir) { case ARC_CCW: if (d_theta < 0) d_theta = 360 + d_theta; break; case ARC_CW: if (d_theta > 0) d_theta = d_theta - 360; break; } if (d_theta == 0) d_theta = 360; if (angle2 != NULL) *angle2 = (d_theta<<6); } else { double theta1, theta2, d_theta; tmp_theta = (dx==0) ? ((dy>=0) ? M_PI/2.0 : -M_PI/2.0) : atan2 ((double)(dy),(double)(dx)); theta1 = tmp_theta/M_PI*(-180.0); tmp_theta = (x2==xc) ? ((y2>=yc) ? M_PI/2.0 : -M_PI/2.0) : atan2 ((double)(y2-yc),(double)(x2-xc)); theta2 = tmp_theta/M_PI*(-180.0); /* NOTE: *angle1 must be between -180 degrees and +180 degrees */ if (angle1 != NULL) *angle1 = (int)(theta1*64.0); d_theta = theta2-theta1; switch (dir) { case ARC_CCW: if (d_theta < 0) d_theta = 360.0 + d_theta; break; case ARC_CW: if (d_theta > 0) d_theta = d_theta - 360.0; break; } if (fabs(d_theta) < INT_TOL) d_theta = (double)360.0; if (angle2 != NULL) *angle2 = (int)(d_theta*64.0); } } void ArcRealX2Y2(ArcPtr, RealX2, RealY2) register struct ArcRec *ArcPtr; int *RealX2, *RealY2; { register double angle_in_radian; int w=ArcPtr->w, h=ArcPtr->h; angle_in_radian = (ArcPtr->angle1+ArcPtr->angle2)*M_PI/180/64; *RealX2 = ArcPtr->xc + round((w/2)*cos(angle_in_radian)); *RealY2 = ArcPtr->yc - round((h/2)*sin(angle_in_radian)); } static double GetRadianInArc(arc_ptr, x, y) struct ArcRec *arc_ptr; int x, y; /* x and y are abs */ { return ((double)atan2((double)((arc_ptr->yc-y)*arc_ptr->w), (double)((x-arc_ptr->xc)*arc_ptr->h))); } #define RETREAT (0.8) void GetArcArrowInfo(obj_ptr, ptip_vs1, ptail_vs1, vs1, pa_angle1, ptip_vs2, ptail_vs2, vs2, pa_angle2) struct ObjRec *obj_ptr; IntPoint *ptip_vs1, *ptail_vs1, *vs1, *ptip_vs2, *ptail_vs2, *vs2; int *pa_angle1, *pa_angle2; /* * if want to get a_angle1 and a_angle2, this function must be * called in the following fashion (cannot omit the second call): * * a_angle1 = arc_ptr->angle1; * a_angle2 = arc_ptr->angle2; * GetArcArrowInfo(*, *, *, *, &a_angle1, *, *, *, &a_angle2); * arc_ptr->a_angle1 = a_angle1; * arc_ptr->a_angle2 = a_angle2; */ { struct ArcRec *arc_ptr=obj_ptr->detail.a; int style=arc_ptr->style, a_angle1, a_angle2, angle90, angle360; int x1, y1, x2, y2, int_dx, int_dy, x, y, angle1, angle2, dir, w, h, aw, ah; double dx, dy, angle_in_radian, theta1, theta2; IntPoint tip_vs1, tail_vs1, tip_vs2, tail_vs2; if (style == LS_PLAIN) return; angle90 = (90<<6); angle360 = (360<<6); dir = arc_ptr->dir; x1 = arc_ptr->x1; y1 = arc_ptr->y1; angle1 = a_angle1 = arc_ptr->angle1; angle2 = a_angle2 = arc_ptr->angle2; w = arc_ptr->w; h = arc_ptr->h; aw = arc_ptr->aw; ah = arc_ptr->ah; /* the arrow should appear at angle1 */ theta1 = 0.0; tip_vs1.x = x1; tip_vs1.y = y1; if ((style & LS_LEFT) && obj_ptr->ctm != NULL) { TransformPointThroughCTM(x1-obj_ptr->x, y1-obj_ptr->y, obj_ptr->ctm, &x, &y); tip_vs1.x = x+obj_ptr->x; tip_vs1.y = y+obj_ptr->y; } switch (dir) { case ARC_CCW: theta1=(double)(angle1-(angle90)); break; case ARC_CW: theta1=(double)(angle1+(angle90)); break; } dx = -((double)w)*cos(theta1*M_PI/180.0/64.0); dy = ((double)h)*sin(theta1*M_PI/180.0/64.0); int_dx = round(dx); int_dy = round(dy); tail_vs1.x = x1+int_dx; tail_vs1.y = y1+int_dy; if ((style & LS_LEFT) && obj_ptr->ctm != NULL) { TransformPointThroughCTM(x1+int_dx-obj_ptr->x, y1+int_dy-obj_ptr->y, obj_ptr->ctm, &x, &y); tail_vs1.x = x+obj_ptr->x; tail_vs1.y = y+obj_ptr->y; } if (int_dx==0 && int_dy==0) { if ((style & LS_LEFT) && vs1 != NULL) { if (obj_ptr->ctm == NULL) { vs1[0].x = vs1[1].x = vs1[2].x = vs1[3].x = x1; vs1[0].y = vs1[1].y = vs1[2].y = vs1[3].y = y1; } else { TransformPointThroughCTM(x1-obj_ptr->x, y1-obj_ptr->y, obj_ptr->ctm, &x, &y); vs1[0].x = vs1[1].x = vs1[2].x = vs1[3].x = x+obj_ptr->x; vs1[0].y = vs1[1].y = vs1[2].y = vs1[3].y = y+obj_ptr->y; } } } else { double sin_val, cos_val, len; dx = (double)(tail_vs1.x - tip_vs1.x); dy = (double)(tail_vs1.y - tip_vs1.y); len = (double)sqrt(dx*dx+dy*dy); sin_val = dy/len; cos_val = dx/len; if ((style & LS_LEFT) && vs1 != NULL) { vs1[0].x = tip_vs1.x; vs1[0].y = tip_vs1.y; vs1[1].x = round(tip_vs1.x + aw*cos_val - ah*sin_val); vs1[1].y = round(tip_vs1.y + aw*sin_val + ah*cos_val); vs1[2].x = round(tip_vs1.x + aw*cos_val + ah*sin_val); vs1[2].y = round(tip_vs1.y + aw*sin_val - ah*cos_val); vs1[3].x = vs1[0].x; vs1[3].y = vs1[0].y; } if ((style & LS_LEFT) && (pa_angle1 != NULL || pa_angle2 != NULL)) { x = round(tip_vs1.x + aw*cos_val*RETREAT); y = round(tip_vs1.y + aw*sin_val*RETREAT); if (obj_ptr->ctm == NULL) { angle_in_radian = GetRadianInArc(arc_ptr, x, y); } else { int tmp_x, tmp_y; ReverseTransformPointThroughCTM(x-obj_ptr->x, y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); x = tmp_x+obj_ptr->x; y = tmp_y+obj_ptr->y; angle_in_radian = GetRadianInArc(arc_ptr, x, y); } angle_in_radian = angle_in_radian*180.0/M_PI*64.0; a_angle1 = round(angle_in_radian); } } theta2 = 0.0; ArcRealX2Y2(arc_ptr, &x2, &y2); tip_vs2.x = x2; tip_vs2.y = y2; if ((style & LS_RIGHT) && obj_ptr->ctm != NULL) { TransformPointThroughCTM(x2-obj_ptr->x, y2-obj_ptr->y, obj_ptr->ctm, &x, &y); tip_vs2.x = x+obj_ptr->x; tip_vs2.y = y+obj_ptr->y; } switch (dir) { case ARC_CCW: theta2=(double)((angle1+angle2)+(angle90)); break; case ARC_CW: theta2=(double)((angle1+angle2)-(angle90)); break; } dx = -((double)w)*cos(theta2*M_PI/180.0/64.0); dy = ((double)h)*sin(theta2*M_PI/180.0/64.0); int_dx = round(dx); int_dy = round(dy); tail_vs2.x = x2+int_dx; tail_vs2.y = y2+int_dy; if ((style & LS_RIGHT) && obj_ptr->ctm != NULL) { TransformPointThroughCTM(x2+int_dx-obj_ptr->x, y2+int_dy-obj_ptr->y, obj_ptr->ctm, &x, &y); tail_vs2.x = x+obj_ptr->x; tail_vs2.y = y+obj_ptr->y; } if (int_dx==0 && int_dy==0) { if ((style & LS_RIGHT) && vs2 != NULL) { if (obj_ptr->ctm == NULL) { vs2[0].x = vs2[1].x = vs2[2].x = vs2[3].x = x2; vs2[0].y = vs2[1].y = vs2[2].y = vs2[3].y = y2; } else { TransformPointThroughCTM(x2-obj_ptr->x, y2-obj_ptr->y, obj_ptr->ctm, &x, &y); vs2[0].x = vs2[1].x = vs2[2].x = vs2[3].x = x+obj_ptr->x; vs2[0].y = vs2[1].y = vs2[2].y = vs2[3].y = y+obj_ptr->y; } } } else { double sin_val, cos_val, len; dx = tail_vs2.x - tip_vs2.x; dy = tail_vs2.y - tip_vs2.y; len = (double)sqrt(dx*dx+dy*dy); sin_val = dy/len; cos_val = dx/len; if ((style & LS_RIGHT) && vs2 != NULL) { vs2[0].x = tip_vs2.x; vs2[0].y = tip_vs2.y; vs2[1].x = round(tip_vs2.x + aw*cos_val - ah*sin_val); vs2[1].y = round(tip_vs2.y + aw*sin_val + ah*cos_val); vs2[2].x = round(tip_vs2.x + aw*cos_val + ah*sin_val); vs2[2].y = round(tip_vs2.y + aw*sin_val - ah*cos_val); vs2[3].x = vs2[0].x; vs2[3].y = vs2[0].y; } if (pa_angle1 != NULL || pa_angle2 != NULL) { int delta64; if (style & LS_RIGHT) { x = round(tip_vs2.x + aw*cos_val*RETREAT); y = round(tip_vs2.y + aw*sin_val*RETREAT); if (obj_ptr->ctm == NULL) { angle_in_radian = GetRadianInArc(arc_ptr, x, y); } else { int tmp_x, tmp_y; ReverseTransformPointThroughCTM(x-obj_ptr->x, y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); x = tmp_x+obj_ptr->x; y = tmp_y+obj_ptr->y; angle_in_radian = GetRadianInArc(arc_ptr, x, y); } angle_in_radian = angle_in_radian*180.0/M_PI*64.0; } else { angle_in_radian = angle1+angle2; while (angle_in_radian > angle360) angle_in_radian -= angle360; while (angle_in_radian < (-angle360)) angle_in_radian += angle360; } delta64 = round(angle_in_radian)-(a_angle1); switch(dir) { case ARC_CCW: if (delta64 < 0) delta64 += (angle360); break; case ARC_CW: if (delta64 > 0) delta64 -= (angle360); break; } while (delta64 > angle360) delta64 -= angle360; while (delta64 < (-angle360)) delta64 += angle360; if (delta64 == 0 && angle2 != 0) delta64 = (angle360); a_angle2 = delta64; } } if (pa_angle1 != NULL) *pa_angle1 = a_angle1; if (pa_angle2 != NULL) *pa_angle2 = a_angle2; if (ptip_vs1 != NULL) memcpy(ptip_vs1, &tip_vs1, sizeof(IntPoint)); if (ptail_vs1 != NULL) memcpy(ptail_vs1, &tail_vs1, sizeof(IntPoint)); if (ptip_vs2 != NULL) memcpy(ptip_vs2, &tip_vs2, sizeof(IntPoint)); if (ptail_vs2 != NULL) memcpy(ptail_vs2, &tail_vs2, sizeof(IntPoint)); } void CalcArcOBBox(ObjPtr) struct ObjRec *ObjPtr; { struct ArcRec *arc_ptr=ObjPtr->detail.a; if (ObjPtr->ctm == NULL) { int theta1, theta2, real_x2, real_y2; int dir=arc_ptr->dir, ltx=arc_ptr->ltx, lty=arc_ptr->lty; int w=arc_ptr->w, h=arc_ptr->h, pass_theta1=FALSE, coverage=0, angle; struct BBRec obbox; memcpy(&obbox, &ObjPtr->obbox, sizeof(struct BBRec)); ObjPtr->x = arc_ptr->xc; ObjPtr->y = arc_ptr->yc; theta1 = (arc_ptr->angle1)/64; theta2 = theta1 + (arc_ptr->angle2)/64; ArcRealX2Y2(arc_ptr, &real_x2, &real_y2); if (arc_ptr->fill == NONEPAT) { /* don't counter the center of the arc */ obbox.ltx = min(arc_ptr->x1,real_x2); obbox.lty = min(arc_ptr->y1,real_y2); obbox.rbx = max(arc_ptr->x1,real_x2); obbox.rby = max(arc_ptr->y1,real_y2); } else { obbox.ltx = min(arc_ptr->xc,min(arc_ptr->x1,real_x2)); obbox.lty = min(arc_ptr->yc,min(arc_ptr->y1,real_y2)); obbox.rbx = max(arc_ptr->xc,max(arc_ptr->x1,real_x2)); obbox.rby = max(arc_ptr->yc,max(arc_ptr->y1,real_y2)); } if (theta2 < -180) theta2 += 360; if (theta2 > 180) theta2 -= 360; if (theta1 < 0) theta1 += 360; if (theta2 < 0) theta2 += 360; if (theta1 == theta2) { coverage = 0xf; } else if (dir == ARC_CCW) { angle = 0; while (angle < theta2 || !pass_theta1) { if (angle >= theta1 && !pass_theta1) { pass_theta1 = TRUE; if (theta2 > theta1 && angle >= theta2) break; if (theta2 < theta1) angle -= 360; } if (pass_theta1) coverage |= 1 << (((angle+360)/90) % 4); angle = (angle == 360) ? 0 : (angle+90); } } else { angle = 360; while (angle > theta2 || !pass_theta1) { if (angle <= theta1 && !pass_theta1) { pass_theta1 = TRUE; if (theta2 < theta1 && angle <= theta2) break; if (theta2 > theta1) angle += 360; } if (pass_theta1) coverage |= 1 << ((angle/90) % 4); angle = (angle == 0) ? 360 : (angle-90); } } if (coverage & 0x1) { EXPAND_BBOX(&obbox,(int)(ltx+w),(int)(lty+h/2)); } if (coverage & 0x2) { EXPAND_BBOX(&obbox,(int)(ltx+w/2),lty); } if (coverage & 0x4) { EXPAND_BBOX(&obbox,ltx,(int)(lty+h/2)); } if (coverage & 0x8) { EXPAND_BBOX(&obbox,(int)(ltx+w/2),(int)(lty+h)); } memcpy(&ObjPtr->obbox, &obbox, sizeof(struct BBRec)); } else { IntPoint abs_obj_obbox_vs[5]; GetTransformedOBBoxAbsVs(ObjPtr, abs_obj_obbox_vs); ObjPtr->obbox.ltx = min(min(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), min(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); ObjPtr->obbox.rbx = max(max(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), max(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); ObjPtr->obbox.lty = min(min(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), min(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); ObjPtr->obbox.rby = max(max(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), max(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); } } void CalcArcBBox(obj_ptr, obbox, bbox) struct ObjRec *obj_ptr; struct BBRec obbox, *bbox; /* given good obbox, figure out bbox */ { struct ArcRec *arc_ptr=obj_ptr->detail.a; int i, half_w=(arc_ptr->width>>1); int ltx=obbox.ltx-half_w, lty=obbox.lty-half_w; int rbx=obbox.rbx+half_w, rby=obbox.rby+half_w; IntPoint vs1[4], vs2[4]; GetArcArrowInfo(obj_ptr, NULL, NULL, vs1, NULL, NULL, NULL, vs2, NULL); if (arc_ptr->style & LS_LEFT) { for (i=0; i < 4; i++) { if (vs1[i].x < ltx) ltx = vs1[i].x; if (vs1[i].y < lty) lty = vs1[i].y; if (vs1[i].x > rbx) rbx = vs1[i].x; if (vs1[i].y > rby) rby = vs1[i].y; } } if (arc_ptr->style & LS_RIGHT) { for (i=0; i < 4; i++) { if (vs2[i].x < ltx) ltx = vs2[i].x; if (vs2[i].y < lty) lty = vs2[i].y; if (vs2[i].x > rbx) rbx = vs2[i].x; if (vs2[i].y > rby) rby = vs2[i].y; } } bbox->ltx = min(ltx, obbox.ltx-(arc_ptr->width>>1)); bbox->lty = min(lty, obbox.lty-(arc_ptr->width>>1)); bbox->rbx = max(rbx, obbox.rbx+(arc_ptr->width>>1)); bbox->rby = max(rby, obbox.rby+(arc_ptr->width>>1)); } static void DumpArcPSPath(FP, xc, yc, xr, yr, dir, a1, a2, outline, blank1, blank2) FILE *FP; int xc, yc, xr, yr, dir, a1, a2, outline; char *blank1, *blank2; { #ifdef INVERT_CTM_BUG if (preDumpSetup) PSUseMinRadius(); #endif /* INVERT_CTM_BUG */ if (preDumpSetup) PSUseArc(); fprintf(FP, "%s%s\n", blank1, gPsCmd[PS_NEWPATH]); if (outline) fprintf(FP, "%s%1d %1d %s\n", blank2, xc, yc, gPsCmd[PS_MOVETO]); #ifdef INVERT_CTM_BUG switch (dir) { case ARC_CCW: fprintf(FP, "%s%1d %1d %1d %s %1d %s %1d %1d TGAR\n", blank2, xc, yc, xr, "tgif_min_radius", yr, "tgif_min_radius", a1, a2); break; case ARC_CW: fprintf(FP, "%s%1d %1d %1d %s %1d %s %1d %1d TGAN\n", blank2, xc, yc, xr, "tgif_min_radius", yr, "tgif_min_radius", a1, a2); break; } #else switch (dir) { case ARC_CCW: fprintf(FP, "%s%1d %1d %1d %1d %1d %1d TGAR\n", blank2, xc, yc, xr, yr, a1, a2); break; case ARC_CW: fprintf(FP, "%s%1d %1d %1d %1d %1d %1d TGAN\n", blank2, xc, yc, xr, yr, a1, a2); break; } #endif if (outline) { fprintf(FP, "%s%1d %1d %s\n", blank2, xc, yc, gPsCmd[PS_LINETO]); } } static void DumpArcArrows(FP, obj_ptr) FILE *FP; struct ObjRec *obj_ptr; { struct ArcRec *arc_ptr=obj_ptr->detail.a; int style=arc_ptr->style, aw=arc_ptr->aw, ah=arc_ptr->ah, pen=arc_ptr->pen; int trans_pat=obj_ptr->trans_pat, color_index=obj_ptr->color; IntPoint tip_vs1, tail_vs1, tip_vs2, tail_vs2; char *aw_spec=arc_ptr->aw_spec, *ah_spec=arc_ptr->ah_spec; GetArcArrowInfo(obj_ptr, &tip_vs1, &tail_vs1, NULL, NULL, &tip_vs2, &tail_vs2, NULL, NULL); if (obj_ptr->ctm == NULL) { if (style & LS_LEFT) { DumpArrow(FP, &tail_vs1, &tip_vs1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } if (style & LS_RIGHT) { DumpArrow(FP, &tail_vs2, &tip_vs2, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } } else { if (style & LS_LEFT) { DumpArrow(FP, &tail_vs1, &tip_vs1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } if (style & LS_RIGHT) { DumpArrow(FP, &tail_vs2, &tip_vs2, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } } } static void DumpArcPath(FP, ObjPtr, xc, yc, xr, yr, dir, angle1, angle2, width, pen, dash, trans_pat) FILE *FP; struct ObjRec *ObjPtr; int xc, yc, xr, yr, dir, angle1, angle2, width, pen, dash, trans_pat; { register int i; int w_is_int=TRUE; char *width_spec=ObjPtr->detail.a->width_spec; double dw=GetWidthInDouble(width, width_spec, &w_is_int); fprintf(FP, " %s\n", gPsCmd[PS_GSAVE]); if (!colorDump && useGray && pen > BACKPAT) { GrayCheck(pen); fprintf(FP, " %s %s\n", GrayStr(pen), gPsCmd[PS_SETGRAY]); } DumpArcPSPath(FP,xc,yc,xr,yr,dir,angle1,angle2,FALSE," "," "); if (ObjPtr->ctm != NULL) { fprintf(FP, " %s\n", &(gPsCmd[PS_TGIFSETMATRIX])[1]); } if (w_is_int) { if (width != 1) { fprintf(FP, " %1d %s\n", width, gPsCmd[PS_SETLINEWIDTH]); } } else { fprintf(FP, " %.3f %s\n", dw, gPsCmd[PS_SETLINEWIDTH]); } if (dash != 0) { fprintf(FP, " ["); for (i = 0; i < dashListLength[dash]-1; i++) { fprintf(FP, "%1d ", (int)(dashList[dash][i])); } fprintf(FP, "%1d] 0 %s\n", (int)(dashList[dash][dashListLength[dash]-1]), gPsCmd[PS_SETDASH]); } switch (pen) { case SOLIDPAT: fprintf(FP, " %s\n", gPsCmd[PS_STROKE]); break; case BACKPAT: if (!trans_pat) { fprintf(FP, " 1 %s %s 0 %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_STROKE], gPsCmd[PS_SETGRAY]); } break; default: if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); fprintf(FP, " %s\n", gPsCmd[PS_FLATTENPATH]); DumpPatFill(FP, pen, ObjPtr->bbox, 6, TRUE); } else { fprintf(FP, " %s\n", gPsCmd[PS_STROKE]); } } fprintf(FP, " %s\n", gPsCmd[PS_GRESTORE]); } void DumpArcObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { register struct ArcRec *arc_ptr=ObjPtr->detail.a; int fill, trans_pat, width, pen, dash, color_index; int xc, yc, xr, yr, dir, angle1, angle2, style, a_angle1, a_angle2; int x1, y1, aw, ah; trans_pat = ObjPtr->trans_pat; fill = arc_ptr->fill; width = arc_ptr->width; aw = arc_ptr->aw; ah = arc_ptr->ah; pen = arc_ptr->pen; dash = arc_ptr->dash; style = arc_ptr->style; xc = arc_ptr->xc; yc = arc_ptr->yc; x1 = arc_ptr->x1; y1 = arc_ptr->y1; xr = (int)(arc_ptr->w/2); yr = (int)(arc_ptr->h/2); dir = arc_ptr->dir; angle1 = -round(((double)arc_ptr->angle1)/64.0); angle2 = -round(((double)arc_ptr->angle2)/64.0) + angle1; a_angle1 = -round(((double)arc_ptr->a_angle1)/64.0); a_angle2 = -round(((double)arc_ptr->a_angle2)/64.0) + a_angle1; if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } fprintf(FP, "%% ARC\n"); if (ObjPtr->ctm != NULL) { float m[6]; fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); m[CTM_SX] = ((float)ObjPtr->ctm->m[CTM_SX])/((float)1000.0); m[CTM_SY] = ((float)ObjPtr->ctm->m[CTM_SY])/((float)1000.0); m[CTM_SIN] = ((float)ObjPtr->ctm->m[CTM_SIN])/((float)1000.0); m[CTM_MSIN] = ((float)ObjPtr->ctm->m[CTM_MSIN])/((float)1000.0); fprintf(FP, " %1d %1d %s\n", ObjPtr->x, ObjPtr->y, gPsCmd[PS_TRANSLATE]); fprintf(FP, " [%.3f %.3f %.3f %.3f %1d %1d] %s\n", m[CTM_SX], m[CTM_SIN], m[CTM_MSIN], m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY], gPsCmd[PS_CONCAT]); fprintf(FP, " %1d %s %1d %s %s\n", ObjPtr->x, gPsCmd[PS_NEG], ObjPtr->y, gPsCmd[PS_NEG], gPsCmd[PS_TRANSLATE]); } color_index = ObjPtr->color; DumpRGBColorLine(FP, color_index, 0, TRUE); switch (fill) { case NONEPAT: break; case SOLIDPAT: DumpArcPSPath(FP,xc,yc,xr,yr,dir,angle1,angle2,TRUE,""," "); fprintf(FP, " %s\n", gPsCmd[PS_FILL]); break; case BACKPAT: if (!trans_pat) { DumpArcPSPath(FP,xc,yc,xr,yr,dir,angle1,angle2,TRUE,""," "); fprintf(FP, " %s 1 %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 3, TRUE); } break; default: fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); if (!trans_pat) { DumpArcPSPath(FP, xc, yc, xr, yr, dir, angle1, angle2, TRUE, " "," "); fprintf(FP, " %s 1 %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 3, TRUE); } DumpArcPSPath(FP,xc,yc,xr,yr,dir,angle1,angle2,TRUE," "," "); fprintf(FP, " %s %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_CLIP], gPsCmd[PS_NEWPATH]); DumpPatFill(FP, fill, ObjPtr->bbox, 3, TRUE); } else { GrayCheck(fill); fprintf(FP, " %s %s\n", GrayStr(fill), gPsCmd[PS_SETGRAY]); DumpArcPSPath(FP,xc,yc,xr,yr,dir,angle1,angle2,TRUE," "," "); fprintf(FP, " %s\n", gPsCmd[PS_FILL]); } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); break; } if (pen == NONEPAT) { if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); return; } fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if ((colorDump || !useGray) && pen > BACKPAT && !trans_pat) { if (style == LS_PLAIN) { DumpArcPath(FP, ObjPtr, xc, yc, xr, yr, dir, angle1, angle2, width, BACKPAT, 0, trans_pat); } else { DumpArcPath(FP, ObjPtr, xc, yc, xr, yr, dir, a_angle1, a_angle2, width, BACKPAT, 0, trans_pat); } DumpRGBColorLine(FP, color_index, 3, TRUE); } if (style == LS_PLAIN) { DumpArcPath(FP, ObjPtr, xc, yc, xr, yr, dir, angle1, angle2, width, pen, dash, trans_pat); } else { DumpArcPath(FP,ObjPtr,xc,yc,xr,yr,dir,a_angle1,a_angle2, width, pen, dash, trans_pat); } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); if (style != LS_PLAIN && !(pen == BACKPAT && trans_pat)) { DumpArcArrows(FP,ObjPtr); } if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); } int NeedsToCacheArcObj(ObjPtr) struct ObjRec *ObjPtr; { return (ObjPtr->ctm != NULL); } static int arcXYMagInitialized=FALSE; static double arcXMag[6], arcYMag[6]; static void MakeArcRotatedVs(obj_ptr, oval_vs, angle1, angle2, rotated_n, rotated_vlist) struct ObjRec *obj_ptr; IntPoint *oval_vs; int angle1, angle2, *rotated_n; XPoint **rotated_vlist; { struct ArcRec *arc_ptr=obj_ptr->detail.a; XPoint *sv=NULL; IntPoint *pv=NULL, *cntrlv=NULL; int i=0, sn=0, cntrln=0, v_index=0, cur_index=0, angle=0; int num_vs=0, angle90=(90<<6), angle360=(360<<6), seen_angle1=FALSE; int cx=arc_ptr->xc, cy=arc_ptr->yc; double hw=(double)(arc_ptr->w>>1), hh=(double)(arc_ptr->h>>1); int start_angle=angle90-angle360, end_angle=angle360; IntPoint first_pt; memset(&first_pt, 0, sizeof(IntPoint)); if (angle1 > angle2) { angle = angle2; angle2 = angle1; angle1 = angle; } while (start_angle > angle1) start_angle -= angle360; while (end_angle < angle2) end_angle += angle360; for (angle=start_angle; angle <= end_angle; angle+=angle90) { /* the quadrant being considered is angle-angle90 to angle */ double angle_in_quadrant; /* 0 < angle_in_quadrant <= 90.0 degrees */ if (seen_angle1) { if (angle >= angle2) { angle_in_quadrant = ((double)(angle2-(angle-angle90)))/64.0; if (angle_in_quadrant < 20.0) { num_vs++; } else if (angle_in_quadrant < 35.0) { num_vs += 2; } else if (angle_in_quadrant < 50.0) { num_vs += 3; } else if (angle_in_quadrant < 65.0) { num_vs += 4; } else if (angle_in_quadrant < 80.0) { num_vs += 5; } else { num_vs += 6; } break; } else { num_vs += 6; } } else { if (angle >= angle1) { angle_in_quadrant = ((double)(angle1-(angle-angle90)))/64.0; if (angle_in_quadrant < 10.0) { num_vs += 7; } else if (angle_in_quadrant < 25.0) { num_vs += 6; } else if (angle_in_quadrant < 40.0) { num_vs += 5; } else if (angle_in_quadrant < 55.0) { num_vs += 4; } else if (angle_in_quadrant < 70.0) { num_vs += 3; } else if (angle_in_quadrant < 80.0) { num_vs += 2; } else { num_vs++; } if (angle >= angle2) { angle_in_quadrant = ((double)(angle2-(angle-angle90)))/64.0; if (angle_in_quadrant < 20.0) { num_vs -= 5; } else if (angle_in_quadrant < 35.0) { num_vs -= 4; } else if (angle_in_quadrant < 50.0) { num_vs -= 3; } else if (angle_in_quadrant < 65.0) { num_vs -= 2; } else if (angle_in_quadrant < 80.0) { num_vs--; } break; } seen_angle1 = TRUE; } } } *rotated_n = 0; *rotated_vlist = (XPoint*)malloc((num_vs+5)*sizeof(XPoint)); pv = (IntPoint*)malloc((num_vs+5)*sizeof(IntPoint)); if (*rotated_vlist == NULL || pv == NULL) FailAllocMessage(); memset(*rotated_vlist, 0, (num_vs+5)*sizeof(XPoint)); memset(pv, 0, (num_vs+5)*sizeof(IntPoint)); cur_index = 0; seen_angle1 = FALSE; for (angle=start_angle, v_index=0; angle <= end_angle; angle+=angle90, v_index+=6) { /* the quadrant being considered is angle-angle90 to angle */ double angle_in_quadrant; /* 0 < angle_in_quadrant <= 90.0 degrees */ int count=(-1); double sin_val, cos_val; if (v_index >= 24) v_index = 0; if (seen_angle1) { if (angle >= angle2) { angle_in_quadrant = ((double)(angle2-(angle-angle90)))/64.0; if (angle_in_quadrant < 20.0) { count = 1; } else if (angle_in_quadrant < 35.0) { count = 2; } else if (angle_in_quadrant < 50.0) { count = 3; } else if (angle_in_quadrant < 65.0) { count = 4; } else if (angle_in_quadrant < 80.0) { count = 5; } else { count = 6; } for (i=1; i < count; i++) { pv[cur_index].x = oval_vs[v_index+i].x; pv[cur_index].y = oval_vs[v_index+i].y; cur_index++; } sin_val = cos((double)(angle2*M_PI/180.0/64.0)); cos_val = sin((double)(angle2*M_PI/180.0/64.0)); pv[cur_index].x = cx + round(hw*sin_val); pv[cur_index].y = cy - round(hh*cos_val); cur_index++; break; } else { for (i=1; i < 7; i++) { pv[cur_index].x = oval_vs[v_index+i].x; pv[cur_index].y = oval_vs[v_index+i].y; cur_index++; } } } else { if (angle >= angle1) { angle_in_quadrant = ((double)(angle1-(angle-angle90)))/64.0; if (angle_in_quadrant < 10.0) { count = 7; } else if (angle_in_quadrant < 25.0) { count = 6; } else if (angle_in_quadrant < 40.0) { count = 5; } else if (angle_in_quadrant < 55.0) { count = 4; } else if (angle_in_quadrant < 70.0) { count = 3; } else if (angle_in_quadrant < 80.0) { count = 2; } else { count = 1; } sin_val = cos((double)(angle1*M_PI/180.0/64.0)); cos_val = sin((double)(angle1*M_PI/180.0/64.0)); pv[0].x = first_pt.x = cx + round(hw*sin_val); pv[0].y = first_pt.y = cy - round(hh*cos_val); for (i=1; i < count; i++) { pv[i].x = oval_vs[(v_index+7-(count-i)) % 24].x; pv[i].y = oval_vs[(v_index+7-(count-i)) % 24].y; } cur_index += count; if (angle >= angle2) { angle_in_quadrant = ((double)(angle2-(angle-angle90)))/64.0; if (angle_in_quadrant < 20.0) { cur_index -= 6; } else if (angle_in_quadrant < 35.0) { cur_index -= 5; } else if (angle_in_quadrant < 50.0) { cur_index -= 4; } else if (angle_in_quadrant < 65.0) { cur_index -= 3; } else if (angle_in_quadrant < 80.0) { cur_index -= 2; } else { cur_index--; } sin_val = cos((double)(angle2*M_PI/180.0/64.0)); cos_val = sin((double)(angle2*M_PI/180.0/64.0)); pv[cur_index].x = cx + round(hw*sin_val); pv[cur_index].y = cy - round(hh*cos_val); cur_index++; break; } seen_angle1 = TRUE; } } } if (num_vs != cur_index) { fprintf(stderr, "num_vs (%1d) != cur_index (%1d)\n", num_vs, cur_index); } pv[num_vs].x = cx; pv[num_vs].y = cy; for (i=0; i < num_vs+1; i++) { int x, y; if (i == 0) { TransformPointThroughCTM(first_pt.x-obj_ptr->x, first_pt.y-obj_ptr->y, obj_ptr->ctm, &x, &y); first_pt.x = x + obj_ptr->x; first_pt.y = y + obj_ptr->y; } TransformPointThroughCTM(pv[i].x-obj_ptr->x, pv[i].y-obj_ptr->y, obj_ptr->ctm, &x, &y); pv[i].x = x + obj_ptr->x; pv[i].y = y + obj_ptr->y; (*rotated_vlist)[i].x = (short)OFFSET_X(pv[i].x); (*rotated_vlist)[i].y = (short)OFFSET_Y(pv[i].y); } if (num_vs == 1) { /* well, the real way to do this is to use a mid-point */ sn = 2; sv = (XPoint*)malloc((num_vs+1)*sizeof(XPoint)); if (sv == NULL) FailAllocMessage(); memset(sv, 0, (num_vs+1)*sizeof(XPoint)); sv[0].x = (short)(OFFSET_X(first_pt.x)); sv[0].y = (short)(OFFSET_Y(first_pt.y)); sv[1].x = (short)(OFFSET_X(pv[0].x)); sv[1].y = (short)(OFFSET_Y(pv[0].y)); } else { sv = MakeIntSplinePolyVertex(&sn, &cntrln, &cntrlv, drawOrigX, drawOrigY, num_vs, pv); } if (sv == NULL) { FailAllocMessage(); } else { XPoint *new_sv=(XPoint*)malloc((sn+3)*sizeof(XPoint)); if (new_sv == NULL) FailAllocMessage(); memset(new_sv, 0, (sn+3)*sizeof(XPoint)); for (i=0; i < sn; i++) { new_sv[i].x = sv[i].x; new_sv[i].y = sv[i].y; } new_sv[sn].x = (*rotated_vlist)[num_vs].x; new_sv[sn].y = (*rotated_vlist)[num_vs].y; new_sv[sn+1].x = new_sv[0].x; new_sv[sn+1].y = new_sv[0].y; free(sv); sv = new_sv; } free(*rotated_vlist); *rotated_n = sn; *rotated_vlist = sv; free(pv); if (cntrlv != NULL) free(cntrlv); } static void MakeCachedArc(ObjPtr) struct ObjRec *ObjPtr; { struct ArcRec *arc_ptr=ObjPtr->detail.a; IntPoint tmp_vs[25]; struct BBRec obbox; int i, cx, cy, a_angle1, a_angle2; double hw, hh; /* half w and half h */ if (!arcXYMagInitialized) { int j; for (i=0, j=0; i < 90; i+=15, j++) { arcXMag[j] = cos((double)(((double)i)*M_PI/180.0)); arcYMag[j] = sin((double)(((double)i)*M_PI/180.0)); } arcXYMagInitialized = TRUE; } if (ObjPtr->ctm == NULL) return; a_angle1 = arc_ptr->angle1; a_angle2 = arc_ptr->angle2; if (arc_ptr->style != LS_PLAIN) { GetArcArrowInfo(ObjPtr, NULL, NULL, NULL, &a_angle1, NULL, NULL, NULL, &a_angle2); } arc_ptr->a_angle1 = a_angle1; arc_ptr->a_angle2 = a_angle2; cx = arc_ptr->xc; cy = arc_ptr->yc; obbox.ltx = cx-(arc_ptr->w>>1); obbox.lty = cy-(arc_ptr->h>>1); obbox.rbx = cx+(arc_ptr->w>>1); obbox.rby = cy+(arc_ptr->h>>1); hw = (double)(arc_ptr->w>>1); hh = (double)(arc_ptr->h>>1); for (i=0; i < 24; i++) { double dx, dy; switch (i) { case 0: tmp_vs[0].x=obbox.rbx; tmp_vs[0].y=cy; break; case 6: tmp_vs[6].x=cx; tmp_vs[6].y=obbox.lty; break; case 12: tmp_vs[12].x=obbox.ltx; tmp_vs[12].y=cy; break; case 18: tmp_vs[18].x=cx; tmp_vs[18].y=obbox.rby; break; default: if (i < 6) { dx = (hw*arcXMag[i % 6]); dy = (hh*arcYMag[i % 6]); tmp_vs[i].x=cx+round(dx); tmp_vs[i].y=cy-round(dy); } else if (i < 12) { dx = (hw*arcXMag[(24-i) % 6]); dy = (hh*arcYMag[(24-i) % 6]); tmp_vs[i].x=cx-round(dx); tmp_vs[i].y=cy-round(dy); } else if (i < 18) { dx = (hw*arcXMag[i % 6]); dy = (hh*arcYMag[i % 6]); tmp_vs[i].x=cx-round(dx); tmp_vs[i].y=cy+round(dy); } else { dx = (hw*arcXMag[(24-i) % 6]); dy = (hh*arcYMag[(24-i) % 6]); tmp_vs[i].x=cx+round(dx); tmp_vs[i].y=cy+round(dy); } break; } } tmp_vs[24].x=tmp_vs[0].x; tmp_vs[24].y=tmp_vs[0].y; if (arc_ptr->rotated_vlist != NULL) free(arc_ptr->rotated_vlist); if (arc_ptr->rotated_asvlist != NULL) free(arc_ptr->rotated_asvlist); arc_ptr->rotated_vlist = arc_ptr->rotated_asvlist = NULL; arc_ptr->rotated_n = arc_ptr->rotated_asn = 0; MakeArcRotatedVs(ObjPtr, tmp_vs, arc_ptr->angle1, arc_ptr->angle1+arc_ptr->angle2, &arc_ptr->rotated_n, &arc_ptr->rotated_vlist); if (arc_ptr->style != LS_PLAIN) { MakeArcRotatedVs(ObjPtr, tmp_vs, arc_ptr->a_angle1, arc_ptr->a_angle1+arc_ptr->a_angle2, &arc_ptr->rotated_asn, &arc_ptr->rotated_asvlist); } } void DrawArcObj(window, XOff, YOff, ObjPtr) Window window; int XOff, YOff; struct ObjRec *ObjPtr; { struct ArcRec *arc_ptr=ObjPtr->detail.a; int i, ltx, lty, w, h, angle1, angle2; int fill, trans_pat, width, pen, dash, pixel, real_x_off, real_y_off; XPoint tmp_v[4]; IntPoint vs1[4], vs2[4]; XGCValues values; if (NeedsToCacheArcObj(ObjPtr) && arc_ptr->rotated_vlist==NULL) { MakeCachedArc(ObjPtr); } if (userDisableRedraw) return; real_x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<>zoomScale)<ltx-real_x_off); lty = ZOOMED_SIZE(arc_ptr->lty-real_y_off); w = ZOOMED_SIZE(arc_ptr->ltx+arc_ptr->w-real_x_off)-ltx; h = ZOOMED_SIZE(arc_ptr->lty+arc_ptr->h-real_y_off)-lty; angle1 = arc_ptr->angle1; angle2 = arc_ptr->angle2; trans_pat = ObjPtr->trans_pat; fill = arc_ptr->fill; width = arc_ptr->width; pen = arc_ptr->pen; dash = arc_ptr->dash; pixel = colorPixels[ObjPtr->color]; if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } if (fill != NONEPAT) { values.foreground = GetDrawingBgPixel(fill, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[fill]; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple, &values); if (ObjPtr->ctm != NULL) { XFillPolygon(mainDisplay, window, drawGC, arc_ptr->rotated_vlist, arc_ptr->rotated_n+2, Complex, CoordModeOrigin); } else { XFillArc(mainDisplay, window, drawGC, ltx, lty, w, h, angle1, angle2); } } if (pen == NONEPAT) return; values.foreground = GetDrawingBgPixel(pen, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[pen]; values.line_width = ZOOMED_SIZE(width); #ifdef NO_THIN_LINE if (values.line_width < 1) values.line_width = 1; #else #ifdef THIN_OVAL_AND_ARC if (values.line_width <= 1) values.line_width = 0; #endif #endif if (dash != 0) { XSetDashes(mainDisplay, drawGC, 0, dashList[dash], dashListLength[dash]); values.line_style = LineOnOffDash; } else { values.line_style = LineSolid; } XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | GCLineStyle, &values); GetArcArrowInfo(ObjPtr, NULL, NULL, vs1, NULL, NULL, NULL, vs2, NULL); if (arc_ptr->style & LS_LEFT) { for (i=0; i < 3; i++) { tmp_v[i].x = (short)ZOOMED_SIZE(vs1[i].x-real_x_off); tmp_v[i].y = (short)ZOOMED_SIZE(vs1[i].y-real_y_off); } tmp_v[3].x = tmp_v[0].x; tmp_v[3].y = tmp_v[0].y; XFillPolygon(mainDisplay, window, drawGC, tmp_v, 4, Convex, CoordModeOrigin); } if (arc_ptr->style & LS_RIGHT) { for (i=0; i < 3; i++) { tmp_v[i].x = (short)ZOOMED_SIZE(vs2[i].x-real_x_off); tmp_v[i].y = (short)ZOOMED_SIZE(vs2[i].y-real_y_off); } tmp_v[3].x = tmp_v[0].x; tmp_v[3].y = tmp_v[0].y; XFillPolygon(mainDisplay, window, drawGC, tmp_v, 4, Convex, CoordModeOrigin); } if (ObjPtr->ctm != NULL) { if (arc_ptr->style == LS_PLAIN) { XDrawLines(mainDisplay, window, drawGC, arc_ptr->rotated_vlist, arc_ptr->rotated_n, CoordModeOrigin); } else { XDrawLines(mainDisplay, window, drawGC, arc_ptr->rotated_asvlist, arc_ptr->rotated_asn, CoordModeOrigin); } } else { if (arc_ptr->style == LS_PLAIN) { XDrawArc(mainDisplay, window, drawGC, ltx, lty, w, h, angle1, angle2); } else { XDrawArc(mainDisplay, window, drawGC, ltx, lty, w, h, arc_ptr->a_angle1, arc_ptr->a_angle2); } } } struct ObjRec *CreateArcObj(xc, yc, x1, y1, x2, y2, dir, ltx, lty, w, h, angle1, angle2, CreateAbsolute) int xc, yc, x1, y1, x2, y2, dir, ltx, lty, w, h, angle1, angle2; int CreateAbsolute; { struct ArcRec *arc_ptr; struct ObjRec *obj_ptr; arc_ptr = (struct ArcRec *)malloc(sizeof(struct ArcRec)); if (arc_ptr == NULL) FailAllocMessage(); memset(arc_ptr, 0, sizeof(struct ArcRec)); arc_ptr->fill = objFill; arc_ptr->width = curWidthOfLine[lineWidth]; arc_ptr->aw = curArrowHeadW[lineWidth]; arc_ptr->ah = curArrowHeadH[lineWidth]; UtilStrCpyN(arc_ptr->width_spec, sizeof(arc_ptr->width_spec), curWidthOfLineSpec[lineWidth]); UtilStrCpyN(arc_ptr->aw_spec, sizeof(arc_ptr->aw_spec), curArrowHeadWSpec[lineWidth]); UtilStrCpyN(arc_ptr->ah_spec, sizeof(arc_ptr->ah_spec), curArrowHeadHSpec[lineWidth]); arc_ptr->pen = penPat; arc_ptr->dash = curDash; arc_ptr->style = lineStyle; if (CreateAbsolute) { arc_ptr->xc = xc; arc_ptr->yc = yc; arc_ptr->x1 = x1; arc_ptr->y1 = y1; arc_ptr->x2 = x2; arc_ptr->y2 = y2; arc_ptr->ltx = xc-(w>>1); arc_ptr->lty = yc-(h>>1); } else { arc_ptr->xc = ABS_X(xc); arc_ptr->yc = ABS_Y(yc); arc_ptr->x1 = ABS_X(x1); arc_ptr->y1 = ABS_Y(y1); arc_ptr->x2 = ABS_X(x2); arc_ptr->y2 = ABS_Y(y2); arc_ptr->ltx = ABS_X(xc-(w>>1)); arc_ptr->lty = ABS_Y(yc-(h>>1)); } arc_ptr->dir = dir; arc_ptr->w = (arc_ptr->xc-arc_ptr->ltx)<<1; arc_ptr->h = (arc_ptr->yc-arc_ptr->lty)<<1; arc_ptr->angle1 = arc_ptr->a_angle1 = angle1; arc_ptr->angle2 = arc_ptr->a_angle2 = angle2; arc_ptr->rotated_n = 0; arc_ptr->rotated_vlist = NULL; arc_ptr->rotated_asn = 0; arc_ptr->rotated_asvlist = NULL; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); obj_ptr->detail.a = arc_ptr; obj_ptr->type = OBJ_ARC; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->id = objId++; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->locked = FALSE; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; obj_ptr->invisible = FALSE; obj_ptr->trans_pat = transPat; AdjObjSplineVs(obj_ptr); AdjObjBBox(obj_ptr); AddObj(NULL, topObj, obj_ptr); return obj_ptr; } static int Colinear(Ax, Ay, Dx, Dy, Cx, Cy) double Ax, Ay, Dx, Dy, Cx, Cy; /* returns TRUE if point D is between A and C and A, D, C are colinear */ { double len_ad=(double)0, len_dc=(double)0, len_ac=(double)0; double dx=(double)0, dy=(double)0; dx = Ax-Cx; dy = Ay-Cy; len_ac = (double)sqrt(dx*dx+dy*dy); dx = Ax-Dx; dy = Ay-Dy; len_ad = (double)sqrt(dx*dx+dy*dy); dx = Cx-Dx; dy = Cy-Dy; len_dc = (double)sqrt(dx*dx+dy*dy); return (fabs(len_ad+len_dc-len_ac) < INT_TOL); } static int SegmentIntersects(Ax, Ay, Bx, By, Cx, Cy, Dx, Dy) int Ax, Ay, Bx, By; double Cx, Cy, Dx, Dy; /* returns TRUE if line segments AB and CD intersects */ { int AB_horizontal=(Ay==By), CD_horizontal=(fabs(Cy-Dy)>1)); sprintf(buf, "r=%s\ndegree=%1d", r_buf, abs(angle2>>6)); } else { char *cl_or_r=(curChoice==DRAWEDGEARC ? "cl" : "r"); if (!show_measure_cursor) { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, saved_x, saved_y); } *pdx = saved_x - OrigX; *pdy = saved_y - OrigY; *pradius = (int)(sqrt((double)(((double)(*pdx))*((double)(*pdx)) + ((double)(*pdy))*((double)(*pdy))))); *pw = *ph = ((*pradius)<<1); PixelToMeasurementUnit(r_buf, ABS_SIZE(*pradius)); PixelToMeasurementUnit(x_buf, ABS_X(saved_x)); PixelToMeasurementUnit(y_buf, ABS_Y(saved_y)); sprintf(buf, "%s=%s\nx=%s\ny=%s", cl_or_r, r_buf, x_buf, y_buf); } if (show_measure_cursor) { ShowMeasureCursor(saved_x, saved_y, buf, TRUE); } if (end_show_measure_cursor) { EndShowMeasureCursor(saved_x, saved_y, buf, TRUE); } } static void ContinueArc(OrigX, OrigY) int OrigX, OrigY; { int grid_x, grid_y, first_x=0, first_y=0, cx=0, cy=0; int end_x, end_y, saved_x, saved_y, dx, dy, radius; int done=FALSE, drawing_arc=FALSE; int dir=INVALID, ltx, lty, w, h, angle1, angle2=0; char buf[80], r_buf[80], x_buf[80], y_buf[80]; char *cl_or_r=(curChoice==DRAWEDGEARC ? "cl" : "r"); struct ObjRec *obj_ptr; XEvent input, ev; SetXorDrawGC(xorColorPixels[colorIndex]); grid_x = saved_x = OrigX; grid_y = saved_y = OrigY; XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, saved_x, saved_y); PixelToMeasurementUnit(r_buf, 0); PixelToMeasurementUnit(x_buf, ABS_X(grid_x)); PixelToMeasurementUnit(y_buf, ABS_Y(grid_y)); sprintf(buf, "%s=%s\nx=%s\ny=%s", cl_or_r, r_buf, x_buf, y_buf); StartShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonPressMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } if (curChoice == DRAWEDGEARC) { Msg(TgLoadCachedString(CSTID_SPECIFY_ARC_END)); SetMouseStatus(TgLoadCachedString(CSTID_SET_ARC_END), TgLoadCachedString(CSTID_CANCEL), TgLoadCachedString(CSTID_CANCEL)); } else { Msg(TgLoadCachedString(CSTID_SPECIFY_ARC_START)); SetMouseStatus(TgLoadCachedString(CSTID_SET_ARC_START), TgLoadCachedString(CSTID_CANCEL), TgLoadCachedString(CSTID_CANCEL)); } while (!done) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); SetXorDrawGC(xorColorPixels[colorIndex]); } else if (input.type == ButtonPress) { if (input.xbutton.button != Button1 || drawing_arc) { XUngrabPointer(mainDisplay, CurrentTime); HighLightInContinueArc(drawing_arc, OrigX, OrigY, saved_x, saved_y, ltx, lty, &w, &h, angle1, angle2, &dx, &dy, &radius, FALSE, TRUE, buf); done = TRUE; if (input.xbutton.button != Button1) { angle2 = 0; } Msg(""); break; } /* drawing_arc is FALSE here */ HighLightInContinueArc(drawing_arc, OrigX, OrigY, saved_x, saved_y, ltx, lty, &w, &h, angle1, angle2, &dx, &dy, &radius, TRUE, FALSE, buf); XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, saved_x, saved_y); first_x = saved_x; first_y = saved_y; drawing_arc = TRUE; if (OrigX == grid_x && OrigY == grid_y) { /* fake it as if the 1st point is ok but not the 2nd point */ XUngrabPointer(mainDisplay, CurrentTime); grid_x = first_x; grid_y = first_y; done = TRUE; } if (curChoice == DRAWEDGEARC) { Msg(TgLoadCachedString(CSTID_SPECIFY_ARC_THIRD)); SetMouseStatus(TgLoadCachedString(CSTID_SET_ARC_THIRD), TgLoadCachedString(CSTID_CANCEL), TgLoadCachedString(CSTID_CANCEL)); } else { Msg(TgLoadCachedString(CSTID_SPECIFY_ARC_END)); SetMouseStatus(TgLoadCachedString(CSTID_SET_ARC_END), TgLoadCachedString(CSTID_CANCEL), TgLoadCachedString(CSTID_CANCEL)); } PixelToMeasurementUnit(r_buf, ABS_SIZE(radius)); sprintf(buf, "r=%s\ndegree=0", r_buf); ShowMeasureCursor(saved_x, saved_y, buf, TRUE); if (done) { PixelToMeasurementUnit(r_buf, ABS_SIZE(radius)); sprintf(buf, "r=%s\ndegree=0", r_buf); EndShowMeasureCursor(saved_x, saved_y, buf, TRUE); } } else if (input.type == MotionNotify || input.type == KeyPress || input.type == KeyRelease) { if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { XUngrabPointer(mainDisplay, CurrentTime); HighLightInContinueArc(drawing_arc, OrigX, OrigY, saved_x, saved_y, ltx, lty, &w, &h, angle1, angle2, &dx, &dy, &radius, FALSE, TRUE, buf); done = TRUE; angle2 = 0; Msg(""); } } if (done) { break; } HighLightInContinueArc(drawing_arc, OrigX, OrigY, saved_x, saved_y, ltx, lty, &w, &h, angle1, angle2, &dx, &dy, &radius, TRUE, FALSE, buf); if (input.type == KeyPress || input.type == KeyRelease) { end_x = saved_x; end_y = saved_y; } else { end_x = input.xmotion.x; end_y = input.xmotion.y; } if (shiftForDiagMouseMove && DiagEventCheck(&input)) { if (input.type == KeyRelease) { end_x = input.xkey.x; end_y = input.xkey.y; } else { DiagGridXY(OrigX, OrigY, &end_x, &end_y); } } GridXY(end_x, end_y, &grid_x, &grid_y); if (grid_x != saved_x || grid_y != saved_y) { if (drawing_arc) { if (curChoice == DRAWEDGEARC) { /* finished with the endpoints of the arc */ if (dir != INVALID) { XDrawArc(mainDisplay, drawWindow, drawGC, ltx, lty, w, h, angle1, angle2); } saved_x = grid_x; saved_y = grid_y; if (!GetCenter(OrigX, OrigY, first_x, first_y, grid_x, grid_y, &cx, &cy, &dir)) { dir = INVALID; } else { ltx = cx; lty = cy; w = 0; h = 0; angle1 = angle2 = 0; PointsToArc(cx, cy, OrigX, OrigY, first_x, first_y, dir, TRUE, <x, <y, &w, &h, &angle1, &angle2); XDrawArc(mainDisplay, drawWindow, drawGC, ltx, lty, w, h, angle1, angle2); } } else { /* finished with the center and the first point on the arc */ if (dir == INVALID) { dir = ArcDirection(OrigX, OrigY, first_x, first_y, grid_x, grid_y); ltx = OrigX; lty = OrigY; w = 0; h = 0; angle1 = angle2 = 0; if (dir == ARC_CW) { Msg(TgLoadCachedString(CSTID_SPECIFY_ARC_END_CW)); } else { Msg(TgLoadCachedString(CSTID_SPECIFY_ARC_END_CCW)); } } XDrawArc(mainDisplay, drawWindow, drawGC, ltx, lty, w, h, angle1, angle2); saved_x = grid_x; saved_y = grid_y; PointsToArc(OrigX, OrigY, first_x, first_y, saved_x, saved_y, dir, TRUE, <x, <y, &w, &h, &angle1, &angle2); XDrawArc(mainDisplay, drawWindow, drawGC, ltx, lty, w, h, angle1, angle2); } } else { /* looking for the first point on the arc */ XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, saved_x, saved_y); saved_x = grid_x; saved_y = grid_y; XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, saved_x, saved_y); } } HighLightInContinueArc(drawing_arc, OrigX, OrigY, saved_x, saved_y, ltx, lty, &w, &h, angle1, angle2, &dx, &dy, &radius, TRUE, FALSE, buf); MarkRulers(grid_x, grid_y); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } SetMouseStatus(NULL, NULL, NULL); if (angle2 == 0 || dir == INVALID) { Msg(TgLoadString(STID_NO_ARC_CREATED)); } else { if (curChoice == DRAWEDGEARC) { obj_ptr = CreateArcObj(cx, cy, OrigX, OrigY, first_x, first_y, dir, ltx, lty, w, h, angle1, angle2, FALSE); } else { obj_ptr = CreateArcObj(OrigX, OrigY, first_x, first_y, saved_x, saved_y, dir, ltx, lty, w, h, angle1, angle2, FALSE); } RecordNewObjCmd(); DrawArcObj(drawWindow, drawOrigX, drawOrigY, topObj); arcDrawn = TRUE; SetFileModified(TRUE); } XSync(mainDisplay, False); } void DrawArc(input) XEvent *input; { XButtonEvent *button_ev; int mouse_x, mouse_y, grid_x, grid_y; if (input->type != ButtonPress) return; button_ev = &(input->xbutton); if (button_ev->button == Button1) { mouse_x = button_ev->x; mouse_y = button_ev->y; GridXY(mouse_x, mouse_y, &grid_x, &grid_y); SaveStatusStrings(); ContinueArc(grid_x, grid_y); RestoreStatusStrings(); } } void SaveArcObj(FP, ObjPtr) FILE *FP; register struct ObjRec *ObjPtr; { register struct ArcRec *arc_ptr=ObjPtr->detail.a; if (fprintf(FP, "arc('%s','',", colorMenuItems[ObjPtr->color]) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,", arc_ptr->fill, arc_ptr->width, arc_ptr->pen, arc_ptr->dash, arc_ptr->ltx, arc_ptr->lty, arc_ptr->xc, arc_ptr->yc, arc_ptr->x1, arc_ptr->y1, arc_ptr->x2, arc_ptr->y2, arc_ptr->dir, arc_ptr->w, arc_ptr->h, arc_ptr->angle1, arc_ptr->angle2) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,'%s','%s','%s',%1d,", ObjPtr->id, ObjPtr->rotation, arc_ptr->style, arc_ptr->aw, arc_ptr->ah, ObjPtr->locked, ObjPtr->ctm!=NULL, ObjPtr->invisible, arc_ptr->width_spec, arc_ptr->aw_spec, arc_ptr->ah_spec, ObjPtr->trans_pat) == EOF) { writeFileFailed = TRUE; } if (ObjPtr->ctm != NULL && fprintf(FP, "[\n %1d,%1d,%1d,%1d,%1d,%1d,%g,%g,%g,%g,%1d,%1d],", ObjPtr->x, ObjPtr->y, ObjPtr->orig_obbox.ltx, ObjPtr->orig_obbox.lty, ObjPtr->orig_obbox.rbx, ObjPtr->orig_obbox.rby, ObjPtr->ctm->m[CTM_SX], ObjPtr->ctm->m[CTM_SIN], ObjPtr->ctm->m[CTM_MSIN], ObjPtr->ctm->m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY]) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, " "); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } void ReadArcObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { register struct ArcRec *arc_ptr; char color_str[40], bg_color_str[40], * s; char width_spec[40], aw_spec[40], ah_spec[40]; int fill, trans_pat=FALSE, width=0, pen, dash, ltx, lty, w, h, id=0; int rotation, new_alloc, style, locked=FALSE; int aw=origArrowHeadW[0], ah=origArrowHeadH[0]; int xc, yc, x1, y1, x2, y2, dir, angle1, angle2; int invisible=FALSE, transformed=FALSE; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_str, sizeof(color_str)); if (fileVersion >= 37) { s = ParseStr(s, (int)',', bg_color_str, sizeof(bg_color_str)); } InitScan(s, ", \t\n"); style = LS_PLAIN; rotation = 0; *width_spec = *aw_spec = *ah_spec = '\0'; if (fileVersion <= 8) { *ObjPtr = NULL; sprintf(gszMsgBox, TgLoadString(STID_INVALID_ARC_VERSION), fileVersion); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return; } else if (fileVersion <= 13) { if (GETINT("arc", fill, "fill") == INVALID || GETINT("arc", width, "width") == INVALID || GETINT("arc", pen, "pen") == INVALID || GETINT("arc", dash, "dash") == INVALID || GETINT("arc", ltx, "ltx") == INVALID || GETINT("arc", lty, "lty") == INVALID || GETINT("arc", xc, "xc") == INVALID || GETINT("arc", yc, "yc") == INVALID || GETINT("arc", x1, "x1") == INVALID || GETINT("arc", y1, "y1") == INVALID || GETINT("arc", x2, "x2") == INVALID || GETINT("arc", y2, "y2") == INVALID || GETINT("arc", dir, "direction") == INVALID || GETINT("arc", w, "width") == INVALID || GETINT("arc", h, "height") == INVALID || GETINT("arc", angle1, "angle1") == INVALID || GETINT("arc", angle2, "angle2") == INVALID || GETINT("arc", id, "id") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 15) { if (GETINT("arc", fill, "fill") == INVALID || GETINT("arc", width, "width") == INVALID || GETINT("arc", pen, "pen") == INVALID || GETINT("arc", dash, "dash") == INVALID || GETINT("arc", ltx, "ltx") == INVALID || GETINT("arc", lty, "lty") == INVALID || GETINT("arc", xc, "xc") == INVALID || GETINT("arc", yc, "yc") == INVALID || GETINT("arc", x1, "x1") == INVALID || GETINT("arc", y1, "y1") == INVALID || GETINT("arc", x2, "x2") == INVALID || GETINT("arc", y2, "y2") == INVALID || GETINT("arc", dir, "direction") == INVALID || GETINT("arc", w, "width") == INVALID || GETINT("arc", h, "height") == INVALID || GETINT("arc", angle1, "angle1") == INVALID || GETINT("arc", angle2, "angle2") == INVALID || GETINT("arc", id, "id") == INVALID || GETINT("arc", rotation, "rotation") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 16) { if (GETINT("arc", fill, "fill") == INVALID || GETINT("arc", width, "width") == INVALID || GETINT("arc", pen, "pen") == INVALID || GETINT("arc", dash, "dash") == INVALID || GETINT("arc", ltx, "ltx") == INVALID || GETINT("arc", lty, "lty") == INVALID || GETINT("arc", xc, "xc") == INVALID || GETINT("arc", yc, "yc") == INVALID || GETINT("arc", x1, "x1") == INVALID || GETINT("arc", y1, "y1") == INVALID || GETINT("arc", x2, "x2") == INVALID || GETINT("arc", y2, "y2") == INVALID || GETINT("arc", dir, "direction") == INVALID || GETINT("arc", w, "width") == INVALID || GETINT("arc", h, "height") == INVALID || GETINT("arc", angle1, "angle1") == INVALID || GETINT("arc", angle2, "angle2") == INVALID || GETINT("arc", id, "id") == INVALID || GETINT("arc", rotation, "rotation") == INVALID || GETINT("arc", style, "style") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 25) { if (GETINT("arc", fill, "fill") == INVALID || GETINT("arc", width, "width") == INVALID || GETINT("arc", pen, "pen") == INVALID || GETINT("arc", dash, "dash") == INVALID || GETINT("arc", ltx, "ltx") == INVALID || GETINT("arc", lty, "lty") == INVALID || GETINT("arc", xc, "xc") == INVALID || GETINT("arc", yc, "yc") == INVALID || GETINT("arc", x1, "x1") == INVALID || GETINT("arc", y1, "y1") == INVALID || GETINT("arc", x2, "x2") == INVALID || GETINT("arc", y2, "y2") == INVALID || GETINT("arc", dir, "direction") == INVALID || GETINT("arc", w, "width") == INVALID || GETINT("arc", h, "height") == INVALID || GETINT("arc", angle1, "angle1") == INVALID || GETINT("arc", angle2, "angle2") == INVALID || GETINT("arc", id, "id") == INVALID || GETINT("arc", rotation, "rotation") == INVALID || GETINT("arc", style, "style") == INVALID || GETINT("arc", aw, "arrow head w") == INVALID || GETINT("arc", ah, "arrow head h") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 32) { if (GETINT("arc", fill, "fill") == INVALID || GETINT("arc", width, "width") == INVALID || GETINT("arc", pen, "pen") == INVALID || GETINT("arc", dash, "dash") == INVALID || GETINT("arc", ltx, "ltx") == INVALID || GETINT("arc", lty, "lty") == INVALID || GETINT("arc", xc, "xc") == INVALID || GETINT("arc", yc, "yc") == INVALID || GETINT("arc", x1, "x1") == INVALID || GETINT("arc", y1, "y1") == INVALID || GETINT("arc", x2, "x2") == INVALID || GETINT("arc", y2, "y2") == INVALID || GETINT("arc", dir, "direction") == INVALID || GETINT("arc", w, "width") == INVALID || GETINT("arc", h, "height") == INVALID || GETINT("arc", angle1, "angle1") == INVALID || GETINT("arc", angle2, "angle2") == INVALID || GETINT("arc", id, "id") == INVALID || GETINT("arc", rotation, "rotation") == INVALID || GETINT("arc", style, "style") == INVALID || GETINT("arc", aw, "arrow head w") == INVALID || GETINT("arc", ah, "arrow head h") == INVALID || GETINT("arc", locked, "locked") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 34) { if (GETINT("arc", fill, "fill") == INVALID || GETINT("arc", width, "width") == INVALID || GETINT("arc", pen, "pen") == INVALID || GETINT("arc", dash, "dash") == INVALID || GETINT("arc", ltx, "ltx") == INVALID || GETINT("arc", lty, "lty") == INVALID || GETINT("arc", xc, "xc") == INVALID || GETINT("arc", yc, "yc") == INVALID || GETINT("arc", x1, "x1") == INVALID || GETINT("arc", y1, "y1") == INVALID || GETINT("arc", x2, "x2") == INVALID || GETINT("arc", y2, "y2") == INVALID || GETINT("arc", dir, "direction") == INVALID || GETINT("arc", w, "width") == INVALID || GETINT("arc", h, "height") == INVALID || GETINT("arc", angle1, "angle1") == INVALID || GETINT("arc", angle2, "angle2") == INVALID || GETINT("arc", id, "id") == INVALID || GETINT("arc", rotation, "rotation") == INVALID || GETINT("arc", style, "style") == INVALID || GETINT("arc", aw, "arrow head w") == INVALID || GETINT("arc", ah, "arrow head h") == INVALID || GETINT("arc", locked, "locked") == INVALID || GETINT("arc", transformed, "transformed") == INVALID || GETINT("arc", invisible, "invisible") == INVALID || GETSTR("arc", width_spec, "width_spec") == INVALID || GETSTR("arc", aw_spec, "aw_spec") == INVALID || GETSTR("arc", ah_spec, "ah_spec") == INVALID) { return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); UtilRemoveQuotes(aw_spec); UtilRemoveQuotes(ah_spec); } else { if (GETINT("arc", fill, "fill") == INVALID || GETINT("arc", width, "width") == INVALID || GETINT("arc", pen, "pen") == INVALID || GETINT("arc", dash, "dash") == INVALID || GETINT("arc", ltx, "ltx") == INVALID || GETINT("arc", lty, "lty") == INVALID || GETINT("arc", xc, "xc") == INVALID || GETINT("arc", yc, "yc") == INVALID || GETINT("arc", x1, "x1") == INVALID || GETINT("arc", y1, "y1") == INVALID || GETINT("arc", x2, "x2") == INVALID || GETINT("arc", y2, "y2") == INVALID || GETINT("arc", dir, "direction") == INVALID || GETINT("arc", w, "width") == INVALID || GETINT("arc", h, "height") == INVALID || GETINT("arc", angle1, "angle1") == INVALID || GETINT("arc", angle2, "angle2") == INVALID || GETINT("arc", id, "id") == INVALID || GETINT("arc", rotation, "rotation") == INVALID || GETINT("arc", style, "style") == INVALID || GETINT("arc", aw, "arrow head w") == INVALID || GETINT("arc", ah, "arrow head h") == INVALID || GETINT("arc", locked, "locked") == INVALID || GETINT("arc", transformed, "transformed") == INVALID || GETINT("arc", invisible, "invisible") == INVALID || GETSTR("arc", width_spec, "width_spec") == INVALID || GETSTR("arc", aw_spec, "aw_spec") == INVALID || GETSTR("arc", ah_spec, "ah_spec") == INVALID || GETINT("arc", trans_pat, "trans_pat") == INVALID) { return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); UtilRemoveQuotes(aw_spec); UtilRemoveQuotes(ah_spec); } if (dir == ARC_CCW && angle2 < 0) { sprintf(gszMsgBox, TgLoadString(STID_WARN_INCONSIST_ARC_DIR)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } SetFileModified(TRUE); dir = ARC_CW; } else if (dir == ARC_CW && angle2 > 0) { sprintf(gszMsgBox, TgLoadString(STID_WARN_INCONSIST_ARC_DIR)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } SetFileModified(TRUE); dir = ARC_CCW; } if (fileVersion <= 16 && width <= 6) { aw = origArrowHeadW[width]; ah = origArrowHeadH[width]; width = origWidthOfLine[width]; } if (fileVersion <= 32) { sprintf(width_spec, "%1d", width); sprintf(aw_spec, "%1d", aw); sprintf(ah_spec, "%1d", ah); } fill = UpgradePenFill(fill); pen = UpgradePenFill(pen); *ObjPtr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (*ObjPtr == NULL) FailAllocMessage(); memset(*ObjPtr, 0, sizeof(struct ObjRec)); arc_ptr = (struct ArcRec *)malloc(sizeof(struct ArcRec)); if (arc_ptr == NULL) FailAllocMessage(); memset(arc_ptr, 0, sizeof(struct ArcRec)); (*ObjPtr)->trans_pat = trans_pat; arc_ptr->fill = fill; arc_ptr->width = width; arc_ptr->aw = aw; arc_ptr->ah = ah; UtilStrCpyN(arc_ptr->width_spec, sizeof(arc_ptr->width_spec), width_spec); UtilStrCpyN(arc_ptr->aw_spec, sizeof(arc_ptr->aw_spec), aw_spec); UtilStrCpyN(arc_ptr->ah_spec, sizeof(arc_ptr->ah_spec), ah_spec); arc_ptr->pen = pen; arc_ptr->dash = dash; arc_ptr->style = style; arc_ptr->xc = xc; arc_ptr->yc = yc; arc_ptr->x1 = x1; arc_ptr->y1 = y1; arc_ptr->x2 = x2; arc_ptr->y2 = y2; arc_ptr->dir = dir; arc_ptr->ltx = ltx; arc_ptr->lty = lty; arc_ptr->w = w; arc_ptr->h = h; arc_ptr->angle1 = arc_ptr->a_angle1 = angle1; arc_ptr->angle2 = arc_ptr->a_angle2 = angle2; arc_ptr->rotated_n = 0; arc_ptr->rotated_vlist = NULL; arc_ptr->rotated_asn = 0; arc_ptr->rotated_asvlist = NULL; (*ObjPtr)->detail.a = arc_ptr; (*ObjPtr)->type = OBJ_ARC; (*ObjPtr)->color = QuickFindColorIndex(*ObjPtr, color_str, &new_alloc, TRUE); UtilStrCpyN((*ObjPtr)->color_str, sizeof((*ObjPtr)->color_str), color_str); (*ObjPtr)->dirty = FALSE; (*ObjPtr)->id = id; (*ObjPtr)->rotation = rotation; (*ObjPtr)->locked = locked; (*ObjPtr)->ctm = NULL; (*ObjPtr)->invisible = invisible; if (fileVersion >= 33 && transformed) { int real_x=0, real_y=0; struct BBRec orig_obbox; char inbuf[MAXSTRING+1]; struct XfrmMtrxRec *ctm; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, "); ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ctm == NULL) FailAllocMessage(); if (GETINT("arc", real_x, "real_x") == INVALID || GETINT("arc", real_y, "real_y") == INVALID || GETINT("arc", orig_obbox.ltx, "orig_obbox.ltx") == INVALID || GETINT("arc", orig_obbox.lty, "orig_obbox.lty") == INVALID || GETINT("arc", orig_obbox.rbx, "orig_obbox.rbx") == INVALID || GETINT("arc", orig_obbox.rby, "orig_obbox.rby") == INVALID || GETDBL("arc", ctm->m[CTM_SX], "CTM_SX") == INVALID || GETDBL("arc", ctm->m[CTM_SIN], "CTM_SIN") == INVALID || GETDBL("arc", ctm->m[CTM_MSIN], "CTM_MSIN") == INVALID || GETDBL("arc", ctm->m[CTM_SY], "CTM_SY") == INVALID || GETINT("arc", ctm->t[CTM_TX], "CTM_TX") == INVALID || GETINT("arc", ctm->t[CTM_TY], "CTM_TY") == INVALID) { return; } (*ObjPtr)->ctm = ctm; if (ctm != NULL) { memcpy(&(*ObjPtr)->orig_obbox, &orig_obbox, sizeof(struct BBRec)); (*ObjPtr)->x = real_x; (*ObjPtr)->y = real_y; GetTransformedOBBoxOffsetVs(*ObjPtr, (*ObjPtr)->rotated_obbox); } } AdjObjSplineVs(*ObjPtr); AdjObjBBox(*ObjPtr); } void SetArcPropMask(ObjPtr, plMask, plSkip, pProp) struct ObjRec *ObjPtr; long *plMask, *plSkip; struct PropertiesRec *pProp; { struct ArcRec *arc_ptr=ObjPtr->detail.a; SetCTMPropertyMask(ObjPtr->ctm, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_COLOR, ObjPtr->color, colorMenuItems[ObjPtr->color], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_WIDTH, arc_ptr->width, arc_ptr->width_spec, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_AW, arc_ptr->aw, arc_ptr->aw_spec, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_AH, arc_ptr->ah, arc_ptr->ah_spec, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TRANSPAT, ObjPtr->trans_pat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_FILL, arc_ptr->fill, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_PEN, arc_ptr->pen, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_DASH, arc_ptr->dash, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_ARROW_STYLE, arc_ptr->style, NULL, plMask, plSkip, pProp); } void FreeArcObj(ObjPtr) struct ObjRec *ObjPtr; { if (ObjPtr->detail.a->rotated_vlist != NULL) { free(ObjPtr->detail.a->rotated_vlist); } if (ObjPtr->detail.a->rotated_asvlist != NULL) { free(ObjPtr->detail.a->rotated_asvlist); } free(ObjPtr->detail.a); free(ObjPtr); } static int ParseArcSpec(spec, seperator, radius, dir, theta1, theta2, error_str) char *spec, *error_str; int seperator, *radius, *dir, *theta1, *theta2; { char *s, buf[MAXSTRING], tmp_buf[MAXSTRING]; strcpy(tmp_buf, spec); s = ParseStr(tmp_buf, seperator, buf, sizeof(buf)); if (*s != '\0') { UtilTrimBlanks(buf); if (!GetDimension(buf, TRUE, radius)) *s = '\0'; } if (*s == '\0') { strcpy(error_str, TgLoadString(STID_INVALID_ARC_SPEC_RADIUS)); return FALSE; } s = ParseStr(s, seperator, buf, sizeof(buf)); UtilTrimBlanks(buf); switch (*buf) { case '+': *dir = ARC_CW; break; case '-': *dir = ARC_CCW; break; default: *s = '\0'; break; } if (*s == '\0') { strcpy(error_str, TgLoadString(STID_INVALID_ARC_SPEC_DIR)); return FALSE; } s = ParseStr(s, seperator, buf, sizeof(buf)); if (*s == '\0') { strcpy(error_str, TgLoadString(STID_INVALID_ARC_SPEC_THETA1)); return FALSE; } UtilTrimBlanks(buf); UtilTrimBlanks(s); *theta1 = atoi(buf); *theta2 = atoi(s); return TRUE; } void MakePreciseArc() { int r = 0, dir = 0, x1, y1, x2, y2, theta1, theta2, angle2=0; char spec[MAXSTRING], error_str[MAXSTRING]; double angle_in_radian; struct ObjRec *obj_ptr; *spec = '\0'; Dialog(TgLoadString(STID_ARC_SPEC), NULL, spec); UtilTrimBlanks(spec); if (*spec == '\0') return; TieLooseEnds(); SetCurChoice(NOTHING); if (topSel!=NULL) { HighLightReverse(); RemoveAllSel(); } if (!ParseArcSpec(spec, (int)',', &r, &dir, &theta1, &theta2, error_str) && !ParseArcSpec(spec, (int)' ', &r, &dir, &theta1, &theta2, error_str)) { sprintf(gszMsgBox, error_str, spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (r < 1) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CREATE_ARC_WITH_RAD1), TOOL_NAME, r); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } switch (dir) { case ARC_CCW: theta1 += 90; theta2 += 90; break; case ARC_CW: theta1 = -theta1+90; theta2 = -theta2+90; break; } angle_in_radian = theta1 * M_PI / 180; x1 = round(r*cos(angle_in_radian)); y1 = -round(r*sin(angle_in_radian)); angle_in_radian = theta2 * M_PI / 180; x2 = round(r*cos(angle_in_radian)); y2 = -round(r*sin(angle_in_radian)); while (theta1 < 0) theta1 += 360; while (theta2 > theta1) theta2 -= 360; while (theta2 < theta1) theta2 += 360; switch (dir) { case ARC_CCW: angle2 = theta2-theta1; if (angle2 == 0) angle2 = 360; break; case ARC_CW: angle2 = theta2-theta1-360; break; } obj_ptr = CreateArcObj(0, 0, x1, y1, x2, y2, dir, -r, -r, r*2, r*2, theta1*64, angle2*64, FALSE); PlaceTopObj(obj_ptr, NULL, NULL); SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; } void PreciseRotateAnArc() { } tgif-QPL-4.2.5/shortcut.c0000644000076400007640000012312711602233312015011 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/shortcut.c,v 1.47 2011/06/09 16:11:42 cvsps Exp $ */ #define _INCLUDE_FROM_SHORTCUT_C_ #include "tgifdefs.h" #include "cmdids.h" #include "choice.e" #include "msg.e" #include "setup.e" #include "shortcut.e" #include "strtbl.e" #include "tangram2.e" #include "util.e" /* * Note: the num_args field in shortCutXlateTbl is used by the shortcut * mechanism. This includes the call_one_arg_shortcut() internal * command. */ /* do not translate -- program constants */ static struct ShortCutRec shortCutXlateTbl[] = { /* Control Keys */ { 'a', CNTRL_ONLY, "SelectAll()", 0, CMDID_SELECTALL }, { 'b', CNTRL_ONLY, "Back()", 0, CMDID_BACK }, { 'c', CNTRL_ONLY, "CopyToCutBuffer()", 0, CMDID_COPY }, { 'd', CNTRL_ONLY, "Duplicate()", 0, CMDID_DUPLICATE }, { 'e', CNTRL_ONLY, "PushCurChoice()", 0, CMDID_PUSHCURCHOICE }, { 'f', CNTRL_ONLY, "Front()", 0, CMDID_FRONT }, { 'g', CNTRL_ONLY, "Group()", 0, CMDID_GROUP }, { 'i', CNTRL_ONLY, "Instantiate()", 0, CMDID_INSTANTIATE }, { 'k', CNTRL_ONLY, "Pop()", 0, CMDID_POP }, { 'l', CNTRL_ONLY, "AlignObjs()", 0, CMDID_ALIGNOBJS }, { 'n', CNTRL_ONLY, "New()", 0, CMDID_NEW }, { 'o', CNTRL_ONLY, "Open()", 1, CMDID_OPEN }, { 'p', CNTRL_ONLY, "Print()", 0, CMDID_PRINT }, { 'q', CNTRL_ONLY, "Quit()", 0, CMDID_QUIT }, { 'r', CNTRL_ONLY, "Redraw()", 0, CMDID_REDRAW }, { 's', CNTRL_ONLY, "Save()", 0, CMDID_SAVE }, { 't', CNTRL_ONLY, "AlignToGrid()", 0, CMDID_ALIGNTOGRID }, { 'u', CNTRL_ONLY, "UnGroup()", 0, CMDID_UNGROUP }, { 'v', CNTRL_ONLY, "PasteFromCutBuffer()", 0, CMDID_PASTE }, { 'w', CNTRL_ONLY, "DrawText()", 0, CMDID_DRAWTEXT }, { '\0', 0, "Delete()", 0, CMDID_DELETE }, { 'y', CNTRL_ONLY, "Redo()", 0, CMDID_REDO }, { 'z', CNTRL_ONLY, "Undo()", 0, CMDID_UNDO }, { ',', CNTRL_ONLY, "ScrollLeft()", 0, CMDID_SCROLLLEFT }, { '.', CNTRL_ONLY, "ScrollRight()", 0, CMDID_SCROLLRIGHT }, { '-', CNTRL_ONLY, "PrintWithCmd()", 0, CMDID_PRINTWITHCMD }, { '1', CNTRL_ONLY, "ScreenCapture()", 0, CMDID_SCREENCAPTURE }, { '2', CNTRL_ONLY, "FullScreenCapture()", 0, CMDID_FULLSCREENCAPTURE }, /* Meta Keys */ { 'a', META_ONLY, "AttachAttrs()", 0, CMDID_ATTACHATTRS }, { 'b', META_ONLY, "Probe()", 0, CMDID_PROBE }, { 'c', META_ONLY, "RotateCounter()", 0, CMDID_ROTATECOUNTER }, { 'd', META_ONLY, "-Grid()", 0, CMDID_DECGRID }, { 'e', META_ONLY, "AnimateSend()", 0, CMDID_ANIMATESEND }, { 'f', META_ONLY, "AnimateFlash()", 0, CMDID_ANIMATEFLASH }, { 'g', META_ONLY, "ToggleGrid()", 0, CMDID_TOGGLEGRID }, { 'h', META_ONLY, "FlipHorizontal()", 0, CMDID_FLIPHORIZONTAL }, { 'i', META_ONLY, "+Grid()", 0, CMDID_INCGRID }, { 'j', META_ONLY, "HideAttrName()", 0, CMDID_HIDEATTRNAME }, { 'k', META_ONLY, "SelectMode()", 0, CMDID_SELECTMODE }, { 'l', META_ONLY, "DistributeObjs()", 0, CMDID_DISTRIBUTEOBJS }, { 'm', META_ONLY, "Move/JustfyAttr()", 0, CMDID_MOVEJUSTIFYATTR }, { 'n', META_ONLY, "ShowAttrName()", 0, CMDID_SHOWATTRNAME }, { 'o', META_ONLY, "ZoomOut()", 0, CMDID_ZOOMOUT }, { 'p', META_ONLY, "Import()", 0, CMDID_IMPORT }, { 'q', META_ONLY, "DrawPoly()", 0, CMDID_DRAWPOLY }, { 'r', META_ONLY, "DrawBox()", 0, CMDID_DRAWBOX }, { 's', META_ONLY, "Solve()", 0, CMDID_SOLVE }, { 't', META_ONLY, "DetachAttrs()", 0, CMDID_DETACHATTRS }, { 'u', META_ONLY, "Animate()", 0, CMDID_ANIMATE }, { 'v', META_ONLY, "FlipVertical()", 0, CMDID_FLIPVERTICAL }, { 'w', META_ONLY, "RotateClockWise()", 0, CMDID_ROTATECLOCKWISE }, { 'x', META_ONLY, "Escape()", 0, CMDID_ESCAPE }, { 'y', META_ONLY, "Simulate()", 0, CMDID_SIMULATE }, { 'z', META_ONLY, "ZoomIn()", 0, CMDID_ZOOMIN }, { '9', META_ONLY, "SpecifyAnArc()", 0, CMDID_SPECIFYANARC }, { '0', META_ONLY, "Update()", 0, CMDID_UPDATE }, { ',', META_ONLY, "ScrollUp()", 0, CMDID_SCROLLUP }, { '.', META_ONLY, "ScrollDown()", 0, CMDID_SCROLLDOWN }, { '-', META_ONLY, "ShowAttr()", 0, CMDID_SHOWATTR }, { '{', META_ONLY, "AlignObjsTop()", 0, CMDID_ALIGNOBJSTOP }, { '+', META_ONLY, "AlignObjsMiddle()", 0, CMDID_ALIGNOBJSMIDDLE }, { '}', META_ONLY, "AlignObjsBottom()", 0, CMDID_ALIGNOBJSBOTTOM }, { '[', META_ONLY, "AlignObjsLeft()", 0, CMDID_ALIGNOBJSLEFT }, { '=', META_ONLY, "AlignObjsCenter()", 0, CMDID_ALIGNOBJSCENTER }, { ']', META_ONLY, "AlignObjsRight()", 0, CMDID_ALIGNOBJSRIGHT }, { '"', META_ONLY, "MakeRegPolygon()", 0, CMDID_MAKEREGPOLYGON }, { '%', META_ONLY, "SetReduction()", 0, CMDID_SETREDUCTION }, { ':', META_ONLY, "DefaultZoom()", 0, CMDID_DEFAULTZOOM }, { '`', META_ONLY, "ZoomWayOut()", 0, CMDID_ZOOMWAYOUT }, { '~', META_ONLY, "SaveSelectedAs()", 0, CMDID_SAVESELECTEDAS }, { ';', META_ONLY, "CutBit/Pixmap()", 0, CMDID_CUTBITPIXMAP }, { '_', META_ONLY, "AbutHorizontal()", 0, CMDID_ABUTHORIZONTAL }, { '|', META_ONLY, "AbutVertical()", 0, CMDID_ABUTVERTICAL }, { '#', META_ONLY, "BreakUpText()", 1, CMDID_BREAKUPTEXT }, { '^', META_ONLY, "ScrollToOrig()", 0, CMDID_SCROLLTOORIG }, { '@', META_ONLY, "ToggleMoveMode()", 0, CMDID_TOGGLEMOVEMODE }, { '$', META_ONLY, "SelectVertexMode()", 0, CMDID_SELECTVERTEXMODE }, { '&', META_ONLY, "AlignToPage()", 0, CMDID_ALIGNTOPAGE }, { '*', META_ONLY, "ChangeDomain()", 0, CMDID_CHANGEDOMAIN }, { '(', META_ONLY, "ImportEPSFile()", 1, CMDID_IMPORTEPSFILE }, { ')', META_ONLY, "PreciseScale()", 0, CMDID_PRECISESCALE }, { '<', META_ONLY, "Lock()", 0, CMDID_LOCK }, { '>', META_ONLY, "UnLock()", 0, CMDID_UNLOCK }, /* Control Meta Keys */ { 'a', CNTRL_META, "AddPoint()", 0, CMDID_ADDPOINT }, { 'b', CNTRL_META, "Bold()", 0, CMDID_BOLD }, { 'c', CNTRL_META, "Center()", 0, CMDID_CENTER }, { 'd', CNTRL_META, "DeletePoint()", 0, CMDID_DELETEPOINT }, { 'e', CNTRL_META, "DrawRCBox()", 0, CMDID_DRAWRCBOX }, { 'f', CNTRL_META, "InvertXBitmap()", 0, CMDID_INVERTXBITMAP }, { 'g', CNTRL_META, "ToggleSnap()", 0, CMDID_TOGGLESNAP }, { 'h', CNTRL_META, "HideAttr()", 0, CMDID_HIDEATTR }, { 'i', CNTRL_META, "MakeIconic()", 0, CMDID_MAKEICONIC }, { 'j', CNTRL_META, "UnMakeIconic()", 0, CMDID_UNMAKEICONIC }, { 'k', CNTRL_META, "ToggleBW/ColorPS()", 0, CMDID_TOGGLEBWCOLORPS }, { 'l', CNTRL_META, "Left()", 0, CMDID_LEFT }, { 'm', CNTRL_META, "MakeSymbolic()", 0, CMDID_MAKESYMBOLIC }, { 'n', CNTRL_META, "UnMakeSymbolic()", 0, CMDID_UNMAKESYMBOLIC }, { 'o', CNTRL_META, "Roman()", 0, CMDID_ROMAN }, { 'p', CNTRL_META, "BoldItalic()", 0, CMDID_BOLDITALIC }, { 'q', CNTRL_META, "DrawPolygon()", 0, CMDID_DRAWPOLYGON }, { 'r', CNTRL_META, "Right()", 0, CMDID_RIGHT }, { 's', CNTRL_META, "SaveNew()", 1, CMDID_SAVENEW }, { 't', CNTRL_META, "Italic()", 0, CMDID_ITALIC }, { 'u', CNTRL_META, "UpdateSymbols()", 0, CMDID_UPDATESYMBOLS }, { 'v', CNTRL_META, "DrawOval()", 0, CMDID_DRAWOVAL }, { 'w', CNTRL_META, "ToggleLineType()", 0, CMDID_TOGGLELINETYPE }, { 'x', CNTRL_META, "CyclePrintFormat()", 0, CMDID_CYCLEPRINFORMAT }, { 'y', CNTRL_META, "Push()", 0, CMDID_PUSH }, { 'z', CNTRL_META, "DrawArc()", 0, CMDID_DRAWARC }, { '.', CNTRL_META, "ImportXBitmap()", 0, CMDID_IMPORTXBITMAP }, { ',', CNTRL_META, "ImportXPixmap()", 0, CMDID_IMPORTXPIXMAP }, { '-', CNTRL_META, "ToggleGridSystem()", 0, CMDID_TOGGLEGRIDSYSTEM }, { '=', CNTRL_META, "FindAgain()", 0, CMDID_FINDAGAIN }, { '5', CNTRL_META, "InsertRightSubscript()", 0, CMDID_INSERTRIGHTSUBSCRIPT }, { '6', CNTRL_META, "InsertRightSuperscript()", 0, CMDID_INSERTRIGHTSUPERSCRIPT }, { '7', CNTRL_META, "ToggleEqAttrShown()", 0, CMDID_TOGGLEEQATTRSHOWN }, { '8', CNTRL_META, "ToggleSlideShow()", 0, CMDID_TOGGLESLIDESHOW }, { '9', CNTRL_META, "FindNoCase()", 0, CMDID_FINDNOCASE }, { '0', CNTRL_META, "FindCaseSensitive()", 0, CMDID_FINDCASESENSITIVE }, /* Miscellaneous */ { '\0', 0, "DrawCornerOval()", 0, CMDID_DRAWCORNEROVAL }, { '\0', 0, "DrawCenterOval()", 0, CMDID_DRAWCENTEROVAL }, { '\0', 0, "DrawEdgeOval()", 0, CMDID_DRAWEDGEOVAL }, { '\0', 0, "DrawEdgeArc()", 0, CMDID_DRAWEDGEARC }, { '\0', 0, "ScrollPageUp()", 0, CMDID_SCROLLPAGEUP }, { '\0', 0, "ScrollPageDown()", 0, CMDID_SCROLLPAGEDOWN }, { '\0', 0, "ScrollPageLeft()", 0, CMDID_SCROLLPAGELEFT }, { '\0', 0, "ScrollPageRight()", 0, CMDID_SCROLLPAGERIGHT }, { '\0', 0, "FlushUndoBuffer()", 0, CMDID_FLUSHUNDOBUFFER }, { '\0', 0, "PrintMsgBuffer()", 0, CMDID_PRINTMSGBUFFER }, { '\0', 0, "SaveOrigin()", 0, CMDID_SAVEORIGIN }, { '\0', 0, "RestoreImageWH()", 0, CMDID_RESTOREIMAGEWH }, { '\0', 0, "UpdateEPS()", 0, CMDID_UPDATEEPS }, { '\0', 0, "ToggleMapShown()", 0, CMDID_TOGGLEMAPSHOWN }, { '\0', 0, "ToggleUseGrayScale()", 0, CMDID_TOGGLEUSEGRAYSCALE }, { '\0', 0, "FreeHandMode()", 0, CMDID_FREEHANDMODE }, { '\0', 0, "SaveSymInLibrary()", 0, CMDID_SAVESYMINLIBRARY }, { '\0', 0, "CenterAnEndPoint()", 0, CMDID_CENTERANENDPOINT }, { '\0', 0, "CenterAVertex()", 0, CMDID_CENTERAVERTEX }, { '\0', 0, "NextPage()", 0, CMDID_NEXTPAGE }, { '\0', 0, "PrevPage()", 0, CMDID_PREVPAGE }, { '\0', 0, "NamePages()", 0, CMDID_NAMEPAGES }, { '\0', 0, "GotoPage()", 1, CMDID_GOTOPAGE }, { '\0', 0, "AddPageBefore()", 0, CMDID_ADDPAGEBEFORE }, { '\0', 0, "AddPageAfter()", 0, CMDID_ADDPAGEAFTER }, { '\0', 0, "DeleteCurPage()", 0, CMDID_DELETECURPAGE }, { '\0', 0, "TogglePageLineShown()", 0, CMDID_TOGGLEPAGELINESHOWN }, { '\0', 0, "SpecifyDrawingSize()", 0, CMDID_SPECIFYDRAWINGSIZE }, { '\0', 0, "PrintOnePage()", 0, CMDID_PRINTONEPAGE }, { '\0', 0, "ToggleNamedAttrShown()", 1, INVALID }, { '\0', 0, "AttachFileAttrs()", 0, CMDID_ATTACHFILEATTRS }, { '\0', 0, "DetachFileAttrs()", 0, CMDID_DETACHFILEATTRS }, { '\0', 0, "EditFileAttrs()", 0, CMDID_EDITFILEATTRS }, { '\0', 0, "PrintSelectedObjs()", 0, CMDID_PRINTSELECTEDOBJS }, { '\0', 0, "InputPolyPts()", 0, CMDID_INPUTPOLYPTS }, { '\0', 0, "InputPolygonPts()", 0, CMDID_INPUTPOLYGONPTS }, { '\0', 0, "EditAttrs()", 0, CMDID_EDITATTRS }, { '\0', 0, "ConvertIntSpline()", 0, CMDID_CONVERTINTSPLINE }, { '\0', 0, "PasteFromFile()", 0, CMDID_PASTEFROMFILE }, { '\0', 0, "ToggleShowMeasurement()", 0, CMDID_TOGGLESHOWMEASUREMENT }, { '\0', 0, "SetMeasureUnit()", 0, CMDID_SETMEASUREUNIT }, { '\0', 0, "Cut()", 0, CMDID_CUT }, { '\0', 0, "ToggleSmoothHinge()", 0, CMDID_TOGGLESMOOTHHINGE }, { '\0', 0, "ToggleShowMenubar()", 0, CMDID_TOGGLESHOWMENUBAR }, { '\0', 0, "ToggleShowStatus()", 0, CMDID_TOGGLESHOWSTATUS }, { '\0', 0, "BrowseXBitmap()", 0, CMDID_BROWSEXBITMAP }, { '\0', 0, "BrowseXPixmap()", 0, CMDID_BROWSEXPIXMAP }, { '\0', 0, "SpecifyPaperSize()", 0, CMDID_SPECIFYPAPERSIZE }, { '\0', 0, "ToggleOneMotionSelMove()", 0, CMDID_TOGGLEONEMOTIONSELMOVE }, { '\0', 0, "GoBack()", 0, CMDID_GOBACK }, { '\0', 0, "GoForward()", 0, CMDID_GOFORWARD }, { '\0', 0, "RefreshCurrent()", 0, CMDID_REFRESHCURRENT }, { '\0', 0, "HotList()", 0, CMDID_HOTLIST }, { '\0', 0, "AddCurrentToHotList()", 0, CMDID_ADDCURRENTTOHOTLIST }, { '\0', 0, "SessionHistory()", 0, CMDID_SESSIONHISTORY }, { '\0', 0, "ToggleHyperSpace()", 0, CMDID_TOGGLEHYPERSPACE }, { '\0', 0, "EmbedEPSFile()", 0, CMDID_EMBEDEPSFILE }, { '\0', 0, "SetSelLineWidth()", 0, CMDID_SETSELLINEWIDTH }, { '\0', 0, "AddColor()", 0, CMDID_ADDCOLOR }, { '\0', 0, "ImportAttrs()", 0, CMDID_IMPORTATTRS }, { '\0', 0, "ExportAttrs()", 0, CMDID_EXPORTATTRS }, { '\0', 0, "MergeWithTable()", 0, CMDID_MERGEWITHTABLE }, { '\0', 0, "ExportToTable()", 0, CMDID_EXPORTTOTABLE }, { '\0', 0, "DeletePages()", 0, CMDID_DELETEPAGES }, { '\0', 0, "PrintOneFilePerPage()", 0, CMDID_PRINTONEFILEPERPAGE }, { '\0', 0, "ImportGIFFile()", 0, CMDID_IMPORTGIFFILE }, { '\0', 0, "SetExportPixelTrim()", 0, CMDID_SETEXPORTPIXELTRIM }, { '\0', 0, "ToggleColorLayers()", 0, CMDID_TOGGLECOLORLAYERS }, { '\0', 0, "ToggleStretchableText()", 0, CMDID_TOGGLESTRETCHABLETEXT }, { '\0', 0, "BreakUpBit/Pixmap()", 0, CMDID_BREAKUPBITPIXMAP }, { '\0', 0, "LayoutOnArc()", 0, CMDID_LAYOUTONARC }, { '\0', 0, "PreciseRotate()", 0, CMDID_PRECISEROTATE }, { '\0', 0, "JoinPoly()", 0, CMDID_JOINPOLY }, { '\0', 0, "CutPoly()", 0, CMDID_CUTPOLY }, { '\0', 0, "GetBoundingBox()", 0, CMDID_GETBOUNDINGBOX }, { '\0', 0, "SetTemplate()", 0, CMDID_SETTEMPLATE }, { '\0', 0, "MakeGray()", 0, CMDID_MAKEGRAY }, { '\0', 0, "InvertColor()", 0, CMDID_INVERTCOLOR }, { '\0', 0, "InterpolateColor()", 0, CMDID_INTERPOLATECOLOR }, { '\0', 0, "BrightenDarken()", 0, CMDID_BRIGHTENDARKEN }, { '\0', 0, "ChangeSaturation()", 0, CMDID_CHANGESATURATION }, { '\0', 0, "ChangeHue()", 0, CMDID_CHANGEHUE }, { '\0', 0, "ContrastEnhance()", 0, CMDID_CONTRASTENHANCE }, { '\0', 0, "ColorBalance()", 0, CMDID_COLORBALANCE }, { '\0', 0, "Gamma()", 0, CMDID_GAMMA }, { '\0', 0, "EdgeDetect()", 0, CMDID_EDGEDETECT }, { '\0', 0, "Emboss()", 0, CMDID_EMBOSS }, { '\0', 0, "ReduceColors()", 0, CMDID_REDUCECOLORS }, { '\0', 0, "ReduceToPixmapColors()", 0, CMDID_REDUCETOPIXMAPCOLORS }, { '\0', 0, "SetDefaultColorLevels()", 0, CMDID_SETDEFAULTCOLORLEVELS }, { '\0', 0, "ReduceToDefaultColors()", 0, CMDID_REDUCETODEFAULTCOLORs }, { '\0', 0, "DefaultErrorDiffuse()", 0, CMDID_DEFAULTERRORDIFFUSE }, { '\0', 0, "Spread()", 0, CMDID_SPREAD }, { '\0', 0, "Sharpen()", 0, CMDID_SHARPEN }, { '\0', 0, "Blur3()", 0, CMDID_BLUR3 }, { '\0', 0, "Blur5()", 0, CMDID_BLUR5 }, { '\0', 0, "Blur7()", 0, CMDID_BLUR7 }, { '\0', 0, "RunBggen()", 0, CMDID_RUNBGGEN }, { '\0', 0, "CircularBggen()", 0, CMDID_CIRCULARBGGEN }, { '\0', 0, "SimpleRectBggen()", 0, CMDID_SIMPLERECTBGGEN }, { '\0', 0, "RegenerateImage()", 0, CMDID_REGENERATEIMAGE }, { '\0', 0, "CropImage()", 0, CMDID_CROPIMAGE }, { '\0', 0, "GetColor()", 0, CMDID_GETCOLOR }, { '\0', 0, "ReplaceColor()", 0, CMDID_REPLACECOLOR }, { '\0', 0, "FloodFill()", 0, CMDID_FLOODFILL }, { '\0', 0, "CreateContour()", 0, CMDID_CREATECONTOUR }, { '\0', 0, "Subtract()", 0, CMDID_SUBTRACT }, { '\0', 0, "AlphaCombine()", 0, CMDID_ALPHACOMBINE }, { '\0', 0, "XorColors()", 0, CMDID_XORCOLORS }, { '\0', 0, "ImportOtherFile()", 0, CMDID_IMPORTOTHERFILE }, { '\0', 0, "ImportOtherFileType()", 1, INVALID }, { '\0', 0, "BrowseOther()", 0, CMDID_BROWSEOTHER }, { '\0', 0, "BrowseOtherType()", 1, INVALID }, { '\0', 0, "ToggleShowCrossHair()", 0, CMDID_TOGGLESHOWCROSSHAIR }, { '\0', 0, "SetShapeShadow()", 0, CMDID_SETSHAPESHADOW }, { '\0', 0, "NoTransform()", 0, CMDID_NOTRANSFORM }, { '\0', 0, "About()", 0, CMDID_ABOUT }, { '\0', 0, "Copyright()", 0, CMDID_COPYRIGHT }, { '\0', 0, "SetSelFontSize()", 0, CMDID_SETSELFONTSIZE }, { '\0', 0, "ZoomInAtCursor()", 0, CMDID_ZOOMINATCURSOR }, { '\0', 0, "CenterAtCursor()", 0, CMDID_CENTERATCURSOR }, { '\0', 0, "SetEditTextSize()", 0, CMDID_SETEDITTEXTSIZE }, { '\0', 0, "SetTextRotation()", 0, CMDID_SETTEXTROTATION }, { '\0', 0, "SetRotationIncrement()", 0, CMDID_SETROTATIONINCREMENT }, { '\0', 0, "CurrentVersionInfo()", 0, CMDID_CURRENTVERSIONINFO }, { '\0', 0, "LatestReleaseInfo()", 0, CMDID_LATESTRELEASEINFO }, { '\0', 0, "VectorWarp()", 0, CMDID_VECTORWARP }, { '\0', 0, "ConnectPins()", 0, CMDID_CONNECTPINS }, { '\0', 0, "PasteCompoundText()", 0, CMDID_PASTECOMPOUNDTEXT }, { '\0', 0, "CopyProperties()", 0, CMDID_COPYPROPERTIES }, { '\0', 0, "SaveProperties()", 0, CMDID_SAVEPROPERTIES }, { '\0', 0, "PasteProperties()", 0, CMDID_PASTEPROPERTIES }, { '\0', 0, "RestoreProperties()", 0, CMDID_RESTOREPROPERTIES }, { '\0', 0, "RotateShearMode()", 0, CMDID_ROTATESHEARMODE }, { '\0', 0, "ChangeAllSelFill()", 0, CMDID_CHANGEALLSELFILL }, { '\0', 0, "ChangeAllSelPen()", 0, CMDID_CHANGEALLSELPEN }, { '\0', 0, "ChangeAllSelLineWidth()", 0, CMDID_CHANGEALLSELLINEWIDTH }, { '\0', 0, "ChangeAllSelLineStyle()", 0, CMDID_CHANGEALLSELLINESTYLE }, { '\0', 0, "ChangeAllSelLineType()", 0, CMDID_CHANGEALLSELLINETYPE }, { '\0', 0, "ChangeAllSelLineDash()", 0, CMDID_CHANGEALLSELLINEDASH }, { '\0', 0, "ChangeAllSelFont()", 0, CMDID_CHANGEALLSELFONT }, { '\0', 0, "ChangeAllSelFontSize()", 0, CMDID_CHANGEALLSELFONTSIZE }, { '\0', 0, "ChangeAllSelFontStyle()", 0, CMDID_CHANGEALLSELFONTSTYLE }, { '\0', 0, "ChangeAllSelFontJust()", 0, CMDID_CHANGEALLSELFONTJUST }, { '\0', 0, "ChangeAllSelColor()", 0, CMDID_CHANGEALLSELCOLOR }, { '\0', 0, "LanscapeMode()", 0, CMDID_LANDSCAPEMODE }, { '\0', 0, "PortraitMode()", 0, CMDID_PORTRAITMODE }, { '\0', 0, "SetWhereToPrint()", 0, CMDID_SETWHERETOPRINT }, { '\0', 0, "SetHoriAlign()", 0, CMDID_SETHORIZONTALALIGN }, { '\0', 0, "SetVertAlign()", 0, CMDID_SETVERTICALALIGN }, { '\0', 0, "SetMoveMode()", 0, CMDID_SETMOVEMODE }, { '\0', 0, "SetStretchTextMode()", 0, CMDID_SETSTRETCHTEXTMODE }, { '\0', 0, "CreateShape()", 0, CMDID_CREATESHAPE }, { '\0', 0, "SetPageLayoutMode()", 0, CMDID_SETPAGELAYOUTMODE }, { '\0', 0, "SetTransPatMode()", 0, CMDID_SETTRANSPATMODE }, { '\0', 0, "ToggleShowMode()", 0, CMDID_TOGGLESHOWMODE }, { '\0', 0, "SetSlideShowBorderColor()", 0, CMDID_SETSLIDESHOWBRDRCOLOR }, { '\0', 0, "SetSlideShowWindowOffsets()", 0, CMDID_SETSLIDESHOWWINOFFSETS }, { '\0', 0, "ExportXPixmapDeckToGIF()", 0, CMDID_EXPORTXPMDECKTOGIF }, { '\0', 0, "ImportGIFToXPixmapDeck()", 0, CMDID_IMPORTGIFTOXPMDECK }, { '\0', 0, "InsertThinSpace()", 0, CMDID_INSERTTHINSPACE }, { '\0', 0, "InsertVerticalOffset()", 0, CMDID_INSERTVERTICALOFFSET }, { '\0', 0, "RemoveVerticalOffset()", 0, CMDID_REMOVEVERTICALOFFSET }, { '\0', 0, "InsertLeftSuperscript()", 0, CMDID_INSERTLEFTSUPERSCRIPT }, { '\0', 0, "InsertLeftSubscript()", 0, CMDID_INSERTLEFTSUBSCRIPT }, { '\0', 0, "InsertCenterSuperscript()", 0, CMDID_INSERTCENTERSUPERSCRIPT }, { '\0', 0, "InsertCenterSubscript()", 0, CMDID_INSERTCENTERSUBSCRIPT }, { '\0', 0, "SetScriptFraction()", 0, CMDID_SETSCRIPTFRACTION }, { '\0', 0, "FakeUserAgent()", 1, CMDID_FAKEUSERAGENT }, { '\0', 0, "FakeReferer()", 1, CMDID_FAKEREFERER }, { '\0', 0, "ToggleKeepAlive()", 0, CMDID_TOGGLEKEEPALIVE }, { '\0', 0, "SizeToWidest()", 0, CMDID_SIZETOWIDEST }, { '\0', 0, "SizeToNarrowest()", 0, CMDID_SIZETONARROWEST }, { '\0', 0, "SizeToTallest()", 0, CMDID_SIZETOTALLEST }, { '\0', 0, "SizeToShortest()", 0, CMDID_SIZETOSHORTEST }, { '\0', 0, "SizeToGivenWidthHeight()", 0, CMDID_SIZETOGIVENWIDTHHEIGHT }, { '\0', 0, "SizeToGivenWidth()", 0, CMDID_SIZETOGIVENWIDTH }, { '\0', 0, "SizeToGivenHeight()", 0, CMDID_SIZETOGIVENHEIGHT }, { '\0', 0, "ExecCmdsFromFile()", 1, CMDID_EXECCMDSFROMFILE }, { '\0', 0, "StartExecCmdsFromFile()", 0, CMDID_STARTEXECCMDSFROMFILE }, { '\0', 0, "CopyPlainTextAsObject()", 0, CMDID_COPYPLAINTEXTASOBJECT }, { '\0', 0, "SetTextFillPatternColor()", 0, CMDID_SETTEXTFILLPATTERNCOLOR }, { '\0', 0, "AlignDirect()", 0, CMDID_ALIGNDIRECT }, { '\0', 0, "DistributeDirect()", 0, CMDID_DISTRIBUTEDIRECT }, { '\0', 0, "ToggleVisibleGridInSlideShow()",0,CMDID_VISIBLEGRIDINSLIDESHOW }, { '\0', 0, "ChangeScrollMode()", 0, CMDID_CHANGESCROLLMODE }, { '\0', 0, "SetAltEditTextBgColor()", 0, CMDID_SETALTEDITTEXTBGCOLOR }, { '\0', 0, "SetAltEditTextHighlightColor()", 0, CMDID_SETALTEDITTEXTHIGHLIGHTCOLOR }, { '\0', 0, "ToggleAltEditTextBgColor()", 0, CMDID_TOGGLEALTEDITTEXTBGCOLOR }, { '\0', 0, "ChangeAllSelFontUnderline()",0,CMDID_CHANGEALLSELFONTUNDERLINE }, { '\0', 0, "ChangeAllSelFontOverline()",0,CMDID_CHANGEALLSELFONTOVERLINE }, { '\0', 0, "EditPageFileNames()", 0, CMDID_EDITPAGEFILENAMES }, { '\0', 0, "ExportHalfToneBitmap()", 0, CMDID_EXPORTHALFTONEBITMAP }, { '\0', 0, "ExportThresholdBitmap()", 0, CMDID_EXPORTTHRESHOLDBITMAP }, { '\0', 0, "SetExportBitmapThreshold()", 1, CMDID_SETEXPORTBITMAPTHRESHOLD }, { '\0', 0, "PreciseScaleEverything()", 0, CMDID_PRECISESCALEEVERYTHING }, { '\0', 0, "SetPaperColor()", 0, CMDID_SETPAPERCOLOR }, { '\0', 0, "DelayedFullScreenCapture()", 0, CMDID_DELAYEDFULLSCREENCAPTURE }, { '\0', 0, "ToggleHideDuringCapture()", 0, CMDID_TOGGLEHIDEDURINGCAPTURE }, { '\0', 0, "EditDomainPaths()", 0, CMDID_EDITDOMAINPATHS }, { '\0', 0, "SelectDefaultDomain()", 0, CMDID_SELECTDEFAULTDOMAIN }, { '\0', 0, "AddADomain()", 0, CMDID_ADDADOMAIN }, { '\0', 0, "DeleteADomain()", 0, CMDID_DELETEADOMAIN }, { '\0', 0, "ReloadDomainInfoFromX()", 0, CMDID_RELOADDOMAININFOFROMX }, { '\0', 0, "ImportPNGFile()", 0, CMDID_IMPORTPNGFILE }, { '\0', 0, "EditIndexedAttrInEditor()", 0, CMDID_EDITATTRINEDITOR }, { '\0', 0, "GetProperty()", 0, CMDID_GETPROPERTY }, { '\0', 0, "PeekDimension()", 0, CMDID_PEEKDIMENSION }, { '\0', 0, "SetHtmlExportTemplate()", 0, CMDID_SETHTMLEXPORTTEMPLATE }, { '\0', 0, "PrintPages()", 0, CMDID_PRINTPAGES }, { '\0', 0, "GoHyperSpaceInSlideShow()",0, CMDID_GOHYPERSPACEINSLIDESHOW }, { '\0', 0, "FreehandModeInSlideShow()",0, CMDID_FREEHANDMODEINSLIDESHOW }, { '\0', 0, "OpenARecentlyUsedFile()", 0, CMDID_RECENTLYUSEDFILES }, { '\0', 0, "MoveEditTextBox()", 0, CMDID_MOVEEDITTEXTBOX }, { '\0', 0, "ReplaceGraphic()", 0, CMDID_REPLACEGRAPHIC }, { '\0', 0, "ToggleShowMeasurementInTooltip()", 0, CMDID_TOGGLESHOWMEASUREMENTINTT }, { '\0', 0, "ImportJPEGFile()", 0, CMDID_IMPORTJPEGFILE }, { '\0', 0, "ToggleAutoEPSPreviewBitmap()", 0, CMDID_TOGGLEAUTOEPSPREVIEWBITMAP }, { '\0', 0, "CreateThumbnails()", 0, CMDID_CREATETHUMBNAILS }, { '\0', 0, "ConnectTwoPortsByAWire()", 0, CMDID_CONNECT2PORTSBYWIRE }, { '\0', 0, "RenameSignalNameForAPort()", 0, CMDID_RENAMESIGNAMEFORAPORT }, { '\0', 0, "ClearSignalNameForAPort()", 0, CMDID_CLEARSIGNAMEFORAPORT }, { '\0', 0, "ToggleShowWireSignalName()", 0, CMDID_TOGGLESHOWWIRESIGNALNAME }, { '\0', 0, "ToggleShowChoicebar()", 0, CMDID_TOGGLESHOWCHOICEBAR }, { '\0', 0, "MergePortsWithAnObject()", 0, CMDID_MERGEPORTSWITHANOBJECT }, { '\0', 0, "RenumberObjectIds()", 0, CMDID_RENUMBER_OBJECT_IDS }, { '\0', 0, "RepeatConnectTwoPortsByAWire()", 0, CMDID_REPEATCONNECT2PORTSBYWIRE }, { '\0', 0, "ConnectPortsToBroadcastWire()", 0, CMDID_CONNECTPORTSTOBROADCAST }, { '\0', 0, "ImportMultipageTextFile()", 0, CMDID_IMPORTMULTIPAGETEXTFILE }, { '\0', 0, "SetMarginsForImportMultipageTextFile()", 0, CMDID_SETMARGINSONIMPORTTEXT }, { '\0', 0, "ToggleWordWrapDuringImportMultipageTextFile()", 0, CMDID_TOGGLEWORDWRAPONIMPORTTEXT }, { '\0', 0, "HandleDataInMBuff()", 0, CMDID_DATA_IN_MBUFF }, { '\0', 0, "BenchMark()", 0, CMDID_BENCHMARK }, { '\0', 0, "ConvertToBezier()", 0, CMDID_CONVERTTOBEZIER }, { '\0', 0, "SetBezierConvertNumSegs()", 1, CMDID_SETBEZIERCONVERTNUMSEGS }, { '\0', 0, "AddSquareTickMarks()", 0, CMDID_ADDSQUARETICKMARKS }, { '\0', 0, "AddTriangleTickMarks()", 0, CMDID_ADDTRIANGLETICKMARKS }, { '\0', 0, "AddCircleTickMarks()", 0, CMDID_ADDCIRCLETICKMARKS }, { '\0', 0, "AddXTickMarks()", 0, CMDID_ADDXTICKMARKS }, { '\0', 0, "AddDiamondTickMarks()", 0, CMDID_ADDDIAMONDTICKMARKS }, { '\0', 0, "AddBowtieTickMarks()", 0, CMDID_ADDBOWTIETICKMARKS }, { '\0', 0, "AddInvTriangleTickMarks()", 0, CMDID_ADDINVTRIANGLETICKMARKS }, { '\0', 0, "AddPlusTickMarks()", 0, CMDID_ADDPLUSTICKMARKS }, { '\0', 0, "AddHourGlassTickMarks()", 0, CMDID_ADDHOURGLASSTICKMARKS }, { '\0', 0, "SetTickMarkSize()", 1, CMDID_SETTICKMARKSIZE }, { '\0', 0, "ToggleShowChat()", 0, CMDID_TOGGLESHOWCHAT }, { '\0', 0, "SavePagesAs()", 0, CMDID_SAVEPAGESAS }, { '\0', 0, "ImportPPMFile()", 0, CMDID_IMPORTPPMFILE }, { '\0', 0, "AddPageBeforeCopyAll()", 0, CMDID_ADDPAGEBEFORECOPYALL }, { '\0', 0, "AddPageAfterCopyAll()", 0, CMDID_ADDPAGEAFTERCOPYALL }, { '\0', 0, "InsertHexOctalChar()", 0, CMDID_INSERTHEXOCTALCHAR }, { '\0', 0, "ResetInputMethod()", 0, CMDID_RESETINMETHOD }, { '\0', 0, "ImportPBMFile()", 0, CMDID_IMPORTPBMFILE }, { '\0', 0, "ImportPGMFile()", 0, CMDID_IMPORTPGMFILE }, { '\0', 0, "EditIndexedAttrGroupInEditor()", 0, CMDID_EDITATTRGROUPINEDITOR }, { '\0', 0, "LinkExtJPEGFile()", 0, CMDID_LINKEXTJPEGFILE }, { '\0', 0, "NextSlide()", 0, CMDID_NEXTSLIDE }, { '\0', 0, "PrevSlide()", 0, CMDID_PREVSLIDE }, { '\0', 0, "SetObjectShadowColor()", 0, CMDID_SETOBJSHADOWCOLOR }, { '\0', 0, "SetObjectShadowOffsets()", 0, CMDID_SETOBJSHADOWOFFSETS }, { '\0', 0, "AddObjectShadow()", 0, CMDID_ADDOBJSHADOW }, { '\0', 0, "RemoveObjectShadow()", 0, CMDID_REMOVEOBJSHADOW }, { '\0', 0, "CopyDoubleByteString()", 0, CMDID_COPYUTF8 }, { '\0', 0, "PasteDoubleByteString()", 0, CMDID_PASTEUTF8 }, { '\0', 0, "ReduceToMobileWebSafeColors()", 0, CMDID_REDUCETOMOBILEWEBCOLORS }, { '\0', 0, "CreatePixmapFromSelected()", 0, CMDID_CREATEPIXMAPFROMSEL }, { '\0', 0, "ToggleAutoRotatePivot()", 0, CMDID_TOGGLEROTATEPIVOT }, { '\0', 0, "SpecifyRotatePivot()", 0, CMDID_SPECIFYROTATEPIVOT }, { '\0', 0, "ResetRotatePivot()", 0, CMDID_RESETROTATEPIVOT }, { '\0', 0, "NextPolyRotationPivot()", 0, CMDID_NEXTPOLYROTATEPIVOT }, { '\0', 0, "MoveRotationPivotToArcCenter()", 0, CMDID_MOVEROTATEPIVOTARCCNTR }, { '\0', 0, "MoveRotatePivotCenter()", 0, CMDID_MOVEROTATEPIVOTCENTER }, { '\0', 0, "MoveRotatePivotLeftTop()", 0, CMDID_MOVEROTATEPIVOTLT }, { '\0', 0, "MoveRotatePivotRightTop()", 0, CMDID_MOVEROTATEPIVOTRT }, { '\0', 0, "MoveRotatePivotLeftBottom()", 0, CMDID_MOVEROTATEPIVOTLB }, { '\0', 0, "MoveRotatePivotRightBottom()", 0, CMDID_MOVEROTATEPIVOTRB }, { '\0', 0, "MoveRotatePivotLeft()", 0, CMDID_MOVEROTATEPIVOTLEFT }, { '\0', 0, "MoveRotatePivotRight()", 0, CMDID_MOVEROTATEPIVOTRIGHT }, { '\0', 0, "MoveRotatePivotTop()", 0, CMDID_MOVEROTATEPIVOTTOP }, { '\0', 0, "MoveRotatePivotBottom()", 0, CMDID_MOVEROTATEPIVOTBOTTOM }, { '\0', 0, "ChooseRotatePivot()", 0, CMDID_CHOOSEROTATEPIVOT }, { '\0', 0, "ChooseColor()", 0, CMDID_COLORWHEEL }, { '\0', 0, "ExtendSegment()", 0, CMDID_EXTENDSEGMENT }, { '\0', 0, "InsertSymbol()", 0, CMDID_INSERTSYMBOL }, { '\0', 0, "ToggleRightMargin()", 0, CMDID_TOGGLERIGHTMARGIN }, { '\0', 0, "SpecifyRightMargin()", 0, CMDID_SPECIFYRIGHTMARGIN }, { '\0', 0, "ToggleTighterStructuredSplines()", 0, CMDID_TOGGLETIGHTERSPLINES }, { '\0', 0, "ToggleFloodReplaceColorThreshold()", 0, CMDID_TOGGLEFLOODREPLACECOLORTHRESH }, { '\0', 0, "SetFloodReplaceColorThreshold()", 0, CMDID_SETFLOODREPLACECOLORTHRESH }, { '\0', 0, "RemoveTransparentPixel()", 0, CMDID_REMOVETRANSPIXEL }, { '\0', 0, "ReplaceColorWithTrans()", 0, CMDID_REPLACECOLORWITHTRANS }, { '\0', 0, "MakeBoxObjFromBoundingBox()", 0, CMDID_NEWRECTFROMBOUNDINGBOX }, { '\0', 0, "MakeRCBoxObjFromBoundingBox()", 0, CMDID_NEWRCBOXFROMBOUNDINGBOX }, { '\0', 0, "MakeOvalObjFromBoundingBox()", 0, CMDID_NEWOVALFROMBOUNDINGBOX }, { '\0', 0, "", 0, 0 } }; static int maxShortCuts=0; static int shortCutIndex[256]; static char *shortCutArgs[256]; typedef struct tagFuncKeyShortCutInfo { char code; unsigned int state; char *name; char *arg; } FuncKeyShortCutInfo; static FuncKeyShortCutInfo funcKeyInfo[13]; static int shortCutCmdIdIndex[MAXCMDIDS-CMDID_BASE]; static int FunctionKeySpec(buf, pn_code, pn_index_return) char *buf; int *pn_code, *pn_index_return; { int value=0; char *colon_ptr=strchr(buf, ':'); if (colon_ptr == NULL) return FALSE; *colon_ptr = '\0'; if (buf[0] != 'F' || sscanf(&buf[1], "%d", &value) != 1) { *colon_ptr = ':'; return FALSE; } *colon_ptr++ = ':'; if (value < 1 || value > 12) return FALSE; *pn_code = value; *pn_index_return = (int)(colon_ptr-buf); return TRUE; } void InitShortCut() { int i=0, num_cmdids=MAXCMDIDS-CMDID_BASE; char *c_ptr=NULL; for (i=0; i < 256; i++) { shortCutIndex[i] = INVALID; shortCutArgs[i] = NULL; } memset(funcKeyInfo, 0, 13*sizeof(FuncKeyShortCutInfo)); maxShortCuts = 0; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ShortCuts")) != NULL) { int j=0, precise_match=0, ok=0, len=0; unsigned int code=0; char *saved_c_ptr=NULL, *tmp_c_ptr=NULL, *buf=NULL; len = strlen(c_ptr); if ((buf=(char *)malloc((len+1)*sizeof(char))) == NULL) { FailAllocMessage(); return; } while (*c_ptr!=':' && *c_ptr!='!' && *c_ptr!='<' && *c_ptr!='\0') c_ptr++; while (*c_ptr != '\0') { saved_c_ptr = c_ptr; precise_match = FALSE; ok = TRUE; if ((*c_ptr==':' || *c_ptr=='!') && strncmp(&c_ptr[1],"",5)==0) { precise_match = TRUE; strcpy(buf, &c_ptr[6]); } else if (strncmp(c_ptr,"",5)==0) { strcpy(buf, &c_ptr[5]); } else { ok = FALSE; } if (ok) { tmp_c_ptr = buf; while (*tmp_c_ptr != ')' && *tmp_c_ptr != '\n' && *tmp_c_ptr != '\0') { tmp_c_ptr++; } if (*tmp_c_ptr == '\0') { ok = FALSE; } else { int func_index=0; if (*tmp_c_ptr == '\n') { *tmp_c_ptr = '\0'; } else { *(++tmp_c_ptr) = '\0'; } code = buf[0]&0xff; if (buf[0] != '\0' && buf[1] == ':' && ((code>0x20 && code<=0x7f) || (code>0xa0 && code<=0xff))) { int found=TRUE; char *paren_ptr=NULL; if ((paren_ptr=strchr(&buf[2], '(')) == NULL) { fprintf(stderr, TgLoadString(STID_INVALID_SHORTCUT_ENTRY_SKIP), buf); fprintf(stderr, "\n"); continue; } len = paren_ptr-(&buf[2]); for (j=0; *(shortCutXlateTbl[j].name) != '\0'; j++) { if (strncmp(shortCutXlateTbl[j].name, &buf[2], len) == 0 && shortCutXlateTbl[j].name[len] == '(') { if (shortCutXlateTbl[j].num_args != 0) { shortCutArgs[code] = (char*)malloc( (strlen(&buf[len+2])+1)*sizeof(char)); if (shortCutArgs[code] == NULL) FailAllocMessage(); strcpy(shortCutArgs[code], ++paren_ptr); } if (shortCutIndex[code] != INVALID) { fprintf(stderr, TgLoadString(STID_DUP_SHORTCUT_ENTRY_FOR_CHAR), code); fprintf(stderr, "\n"); } shortCutIndex[code] = j; if (!precise_match) { if (*buf>='a' && *buf<='z') { code = *buf-'a'+'A'; if (shortCutIndex[code] != INVALID) { fprintf(stderr, TgLoadString( STID_DUP_SHORTCUT_ENTRY_FOR_CHAR), code); fprintf(stderr, "\n"); } shortCutIndex[code] = j; } else if (*buf>='A' && *buf<='Z') { code = *buf-'A'+'a'; if (shortCutIndex[code] != INVALID) { fprintf(stderr, TgLoadString( STID_DUP_SHORTCUT_ENTRY_FOR_CHAR), code); fprintf(stderr, "\n"); } shortCutIndex[code] = j; } } maxShortCuts++; break; } } if (*(shortCutXlateTbl[j].name) == '\0') { if (cmdLineTgrm2) { int num_args=0; int index=ValidTangram2CmdName(&buf[2], len, &num_args); if (index != 0) { if (num_args != 0) { shortCutArgs[code] = (char*)malloc( (strlen(&buf[len+2])+1)*sizeof(char)); if (shortCutArgs[code] == NULL) { FailAllocMessage(); } strcpy(shortCutArgs[code], ++paren_ptr); } if (shortCutIndex[code] != INVALID) { fprintf(stderr, TgLoadString( STID_DUP_SHORTCUT_ENTRY_FOR_CHAR), code); fprintf(stderr, "\n"); } shortCutIndex[code] = index; if (!precise_match) { if (*buf>='a' && *buf<='z') { code = *buf-'a'+'A'; if (shortCutIndex[code] != INVALID) { fprintf(stderr, TgLoadString( STID_DUP_SHORTCUT_ENTRY_FOR_CHAR), code); fprintf(stderr, "\n"); } shortCutIndex[code] = index; } else if (*buf>='A' && *buf<='Z') { code = *buf-'A'+'a'; if (shortCutIndex[code] != INVALID) { fprintf(stderr, TgLoadString( STID_DUP_SHORTCUT_ENTRY_FOR_CHAR), code); fprintf(stderr, "\n"); } shortCutIndex[code] = index; } } maxShortCuts++; } else { found = FALSE; } } else { found = FALSE; } } if (!found) { fprintf(stderr, TgLoadString(STID_INVALID_SHORTCUT_ENTRY_SKIP), buf); fprintf(stderr, "\n"); } } else if (FunctionKeySpec(buf, (int*)&code, &func_index)) { int found=FALSE; char *paren_ptr=NULL; if ((paren_ptr=strchr(&buf[func_index], '(')) == NULL) { fprintf(stderr, TgLoadString(STID_INVALID_SHORTCUT_ENTRY_SKIP), buf); fprintf(stderr, "\n"); continue; } len = paren_ptr-(&buf[func_index]); for (j=0; *(shortCutXlateTbl[j].name) != '\0'; j++) { if (strncmp(shortCutXlateTbl[j].name, &buf[func_index], len) == 0 && shortCutXlateTbl[j].name[len] == '(') { if (funcKeyInfo[code].name != NULL) { fprintf(stderr, TgLoadString(STID_DUP_SHORTCUT_FUNCTION_KEY), code); fprintf(stderr, "\n"); } funcKeyInfo[code].code = shortCutXlateTbl[j].code; funcKeyInfo[code].state = shortCutXlateTbl[j].state; funcKeyInfo[code].name = UtilStrDup(shortCutXlateTbl[j].name); if (funcKeyInfo[code].name == NULL) { FailAllocMessage(); } if (shortCutXlateTbl[j].num_args != 0) { funcKeyInfo[code].arg = (char*)malloc( (strlen(&buf[len+func_index])+1)*sizeof(char)); if (funcKeyInfo[code].arg == NULL) { FailAllocMessage(); } strcpy(funcKeyInfo[code].arg, ++paren_ptr); } found = TRUE; break; } } if (!found) { fprintf(stderr, TgLoadString(STID_INVALID_SHORTCUT_ENTRY_SKIP), buf); fprintf(stderr, "\n"); } } else { fprintf(stderr, TgLoadString(STID_INVALID_SHORTCUT_ENTRY_SKIP), buf); fprintf(stderr, "\n"); } } } if (ok) { while (*c_ptr!=')' && *c_ptr!='\0') c_ptr++; while (*c_ptr!=':' && *c_ptr!='!' && *c_ptr!='<' && *c_ptr!='\0') { c_ptr++; } } else { fprintf(stderr, TgLoadString(STID_INVALID_SHORTCUT_ENTRY), saved_c_ptr); fprintf(stderr, "\n"); break; } } free(buf); } for (i=0; i < num_cmdids; i++) { shortCutCmdIdIndex[i] = INVALID; } for (i=0; *(shortCutXlateTbl[i].name) != '\0'; i++) { int cmdid=shortCutXlateTbl[i].cmdid; if (cmdid != INVALID) { int index=cmdid-CMDID_BASE; if (shortCutCmdIdIndex[index] == INVALID) { shortCutCmdIdIndex[index] = i; } else { fprintf(stderr, TgLoadString(STID_WARN_DUP_CMDID), cmdid); fprintf(stderr, "\n"); } } } } void CleanUpShortCut() { register int i; for (i=0; i < 256; i++) { if (shortCutArgs[i] != NULL) { free(shortCutArgs[i]); } } for (i=0; i < 13; i++) { UtilFree(funcKeyInfo[i].name); UtilFree(funcKeyInfo[i].arg); } } int FetchShortCut(c, code, state, name, args, args_sz) int c, args_sz; char *code, **name, *args; unsigned int *state; { if (shortCutIndex[c] == INVALID) return FALSE; if (cmdLineTgrm2 && (shortCutIndex[c] & CMDID_TANGRAM2_BASE) != 0) { /* for tangram-II, just do it */ int num_args=0; if (FetchTangram2ShortCutNumArgs(shortCutIndex[c]-CMDID_TANGRAM2_BASE, &num_args) && num_args > 0) { strcpy(args, shortCutArgs[c]); } else { *args = '\0'; } DoTangram2ShortCut(shortCutIndex[c]-CMDID_TANGRAM2_BASE, args); return FALSE; } *code = shortCutXlateTbl[shortCutIndex[c]].code; *state = shortCutXlateTbl[shortCutIndex[c]].state; *name = shortCutXlateTbl[shortCutIndex[c]].name; if (shortCutXlateTbl[shortCutIndex[c]].num_args == 0) { *args = '\0'; } else { strcpy(args, shortCutArgs[c]); } return TRUE; } int FetchFuncKeyShortCut(c, code, state, name, args, args_sz) int c, args_sz; char *code, **name, *args; unsigned int *state; { int index=0; char buf[MAXSTRING]; switch (c) { case XK_F1: index=1; break; case XK_F2: index=2; break; case XK_F3: index=3; break; case XK_F4: index=4; break; case XK_F5: index=5; break; case XK_F6: index=6; break; case XK_F7: index=7; break; case XK_F8: index=8; break; case XK_F9: index=9; break; case XK_F10: index=10; break; case XK_F11: index=11; break; case XK_F12: index=12; break; default: return FALSE; } if (curChoice == DRAWTEXT) { sprintf(buf, "DrawTextFuncKey_F%1d", index); if (XGetDefault(mainDisplay, TOOL_NAME, buf) != NULL) { return FALSE; } } if (funcKeyInfo[index].name == NULL) return FALSE; *code = funcKeyInfo[index].code; *state = funcKeyInfo[index].state; *name = funcKeyInfo[index].name; if (funcKeyInfo[index].arg == NULL) { *args = '\0'; } else { strcpy(args, funcKeyInfo[index].arg); } return TRUE; } int FetchCmdById(nCmdId, code, state, name, args) int nCmdId; char *code, **name, *args; unsigned int *state; { int cmd_index=nCmdId-CMDID_BASE, table_index=INVALID; if (nCmdId >= MAXCMDIDS || shortCutCmdIdIndex[cmd_index] == INVALID) { return FALSE; } table_index = shortCutCmdIdIndex[cmd_index]; if (shortCutXlateTbl[table_index].num_args != 0) { strcpy(args, "-1"); } *code = shortCutXlateTbl[table_index].code; *state = shortCutXlateTbl[table_index].state; *name = shortCutXlateTbl[table_index].name; return TRUE; } int ValidShortCut(name, num_args, code, state) char *name, *code; int num_args; unsigned int *state; { int j, len=strlen(name); if (len <= 2) return FALSE; for (j=0; *(shortCutXlateTbl[j].name) != '\0'; j++) { if (num_args == ((int)shortCutXlateTbl[j].num_args) && strncmp(shortCutXlateTbl[j].name, name, len-2) == 0 && shortCutXlateTbl[j].name[len] == '(' && shortCutXlateTbl[j].name[len+1] == ')') { *code = shortCutXlateTbl[j].code; *state = shortCutXlateTbl[j].state; return TRUE; } } return FALSE; } tgif-QPL-4.2.5/color.e0000644000076400007640000001061111602233311014246 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/color.e,v 1.12 2011/05/16 16:21:57 william Exp $ */ #ifndef _COLOR_E_ #define _COLOR_E_ extern int maxColors; extern int defaultColorIndex; extern int colorIndex; extern char myFgColorStr[]; extern char myBgColorStr[]; extern char myRubberBandColorStr[]; extern char * * colorMenuItems; extern int * colorPixels; extern int * xorColorPixels; extern int * colorLayerOn; extern XColor * tgifColors; extern XColor * tgifRequestedColors; extern XColor myBgColor; extern int maxRGB; extern int colorDump; extern int useLocalRGBTxt; extern int printUsingRequestedColor; extern int colorLayers; extern int needToRedrawColorWindow; extern int initColorDontReload; extern int gnUpdatePixelObjCount; extern char defaultBgColorStr[]; extern int defaultBgColorIndex; extern char altEditTextBgColorStr[]; extern int altEditTextBgIndex; extern char altEditTextHighlightColorStr[]; extern int altEditTextHighlightIndex; extern int useAltEditTextBgColor; extern char pngExportTransparentColor[]; #ifdef _INCLUDE_FROM_COLOR_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_COLOR_C_*/ extern void DefaultColorArrays ARGS_DECL((int Entries, int **ForePixels, int **Valid, int **InitRV, char ***StatusStr)); extern int GetDrawingBgPixel ARGS_DECL((int index, int pixel)); extern int GetDrawingFgPixel ARGS_DECL((int index, int pixel)); extern void GetDrawingFgColorStr ARGS_DECL((int index, int pixel, char *color_buf, int buf_sz)); extern int TgifParseColor ARGS_DECL((char*, XColor*)); extern int ParseAndAllocColorByName ARGS_DECL((char*, XColor*, unsigned short *, unsigned short *, unsigned short *)); extern void RecalcXorPixels ARGS_DECL((void)); extern void InitColor ARGS_DECL((void)); extern void RedrawColorWindow ARGS_DECL((void)); extern int OneColorObject ARGS_DECL((struct ObjRec *, int *ColorIndex)); extern int ChangeObjColor ARGS_DECL((struct ObjRec *, int ColorIndex)); extern void ChangeAllSelColor ARGS_DECL((int ColorIndex, int HighLight)); extern void RefreshColorMenu ARGS_DECL((TgMenu*)); extern void SetUpColorMenuPixmap ARGS_DECL((int **ForeColors, int **InitRV, Pixmap **, int *Rows, int *Cols)); extern TgMenu *CreateColorMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int ColorMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void CleanUpColors ARGS_DECL((void)); extern void ColorEventHandler ARGS_DECL((XEvent*)); extern void RedrawColorDummyWindow ARGS_DECL((void)); extern void ColorDummyEventHandler ARGS_DECL((XEvent*)); extern int UpdatePixel ARGS_DECL((struct ObjRec *)); extern void UpdateXPmObjects ARGS_DECL((struct ObjRec *)); extern int FlushColormap ARGS_DECL((void)); extern void AddColor ARGS_DECL((void)); extern void ChooseColor ARGS_DECL((void)); extern void SetAltEditTextBgColor ARGS_DECL((void)); extern void SetAltEditTextHighlightColor ARGS_DECL((void)); extern void ToggleAltEditTextBgColor ARGS_DECL((void)); extern void SaveColors ARGS_DECL((FILE*)); extern int ReadColors ARGS_DECL((FILE*, char*)); extern void DumpRGBColorLine ARGS_DECL((FILE *FP, int ColorIndex, int Indent, int EndOfLine)); #ifdef _INCLUDE_FROM_COLOR_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_COLOR_C_*/ #endif /*_COLOR_E_*/ tgif-QPL-4.2.5/frontend.pl0000644000076400007640000000272511602233311015145 0ustar williamwilliam% % Author: William Chia-Wei Cheng (bill.cheng@acm.org) % % Copyright (C) 2001-2009, William Chia-Wei Cheng. % % This file may be distributed under the terms of the Q Public License % as defined by Trolltech AS of Norway and appearing in the file % LICENSE.QPL included in the packaging of this file. % % THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING % THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR % PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, % INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING % FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, % NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION % WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/frontend.pl,v 1.6 2011/05/16 16:26:57 william Exp $ % % The main predicate exported is: interface/9. :- abolish(foreign_file/2). :- abolish(foreign/3). foreign_file('frontend11.o', ['MainLoop','Animate','UpdAttrVal']). foreign('MainLoop', c, interface(+string, +string, -string, -string, -string, -string, -string, -string, -string)). foreign('Animate', c, interface_animate(+string, +string, +string, +string, -string)). foreign('UpdAttrVal', c, interface_updattr(+string, +string, +string, +string, -string)). :- load_foreign_files(['frontend11.o'], ['-lXext','-lX11','-ldl','-lm','-lsocket','-lnsl','-lgen']), abolish(foreign_file/2), abolish(foreign/3). tgif-QPL-4.2.5/grid.e0000644000076400007640000001436111602233311014063 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/grid.e,v 1.10 2011/05/16 16:21:57 william Exp $ */ #ifndef _GRID_E_ #define _GRID_E_ extern int gridSystem; extern int snapOn; extern int xyEnglishGrid; extern int xyMetricGrid; extern int pageStyle; extern int whereToPrint; extern int moveMode; extern int gridShown; extern int mapShown; extern int usePaperSizeStoredInFile; extern int oneMotionSelectMove; extern int queryZoomInPoint; extern int shiftForDiagMouseMove; extern int useRecentForDiagMouseMove; extern int defRightMargin; extern int defRightMarginEnabled; extern int rightMargin; extern int rightMarginEnabled; extern int rightMarginActive; #ifdef _INCLUDE_FROM_GRID_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_GRID_C_*/ extern void RedrawGridLines ARGS_DECL((Window)); extern void DrawGridLines ARGS_DECL((Window, int LtX, int LtY, int W, int H)); extern void RedrawPageLines ARGS_DECL((Window)); extern void DrawPageLines ARGS_DECL((Window, int LtX, int LtY, int W, int H)); extern void ToggleRightMargin ARGS_DECL((void)); extern void SpecifyRightMargin ARGS_DECL((void)); extern void ToggleGridSystem ARGS_DECL((void)); extern void IncGrid ARGS_DECL((void)); extern void DecGrid ARGS_DECL((void)); extern void ToggleGridShown ARGS_DECL((void)); extern void ToggleSnapOn ARGS_DECL((void)); extern void ToggleColorPostScript ARGS_DECL((void)); extern void ToggleMoveMode ARGS_DECL((void)); extern void ToggleMapShown ARGS_DECL((void)); extern void ToggleUseGray ARGS_DECL((void)); extern void SetMeasureUnit ARGS_DECL((void)); extern void ToggleShowMenubar ARGS_DECL((void)); extern void ToggleShowStatus ARGS_DECL((void)); extern void ToggleShowChoicebar ARGS_DECL((void)); extern void ToggleShowMode ARGS_DECL((void)); extern void SetWhereToPrint ARGS_DECL((int nIndex)); extern void ToggleWhereToPrint ARGS_DECL((void)); extern void ToggleOneMotionSelectMove ARGS_DECL((void)); extern void ToggleColorLayers ARGS_DECL((void)); extern void ToggleStretchableText ARGS_DECL((void)); extern void ToggleTransPatMode ARGS_DECL((void)); extern void DefaultZoom ARGS_DECL((void)); extern void ZoomIn ARGS_DECL((void)); extern void ZoomInAtCursor ARGS_DECL((int AbsX, int AbsY)); extern void ZoomWayOut ARGS_DECL((void)); extern void ZoomOut ARGS_DECL((void)); extern void CenterAtCursor ARGS_DECL((int AbsX, int AbsY)); extern void PreciseZoom ARGS_DECL((int ZoomedIn, int ZoomScale, int Force)); extern void SetPSPageWidthHeight ARGS_DECL((void)); extern void ResetOnePageSize ARGS_DECL((void)); extern int UpdPageStyle ARGS_DECL((int)); extern void ChangePageStyle ARGS_DECL((int PageStyle)); extern int RefreshPageStyleMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreatePageStyleMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int PageStyleMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void RefreshExportFormatMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateExportFormatMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int ExportFormatMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int RefreshShowHideMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateShowHideMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int RefreshLayoutMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateLayoutMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int LayoutMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int GridSize ARGS_DECL((void)); extern void GridXY ARGS_DECL((int X, int Y, int *GridX, int *GridY)); extern int ControlKeyPressedEvent ARGS_DECL((XEvent *ev)); extern int DiagEventCheck ARGS_DECL((XEvent *ev)); extern void DiagGridXY ARGS_DECL((int OrigX, int OrigY, int *X, int *Y)); extern void CleanUpGrids ARGS_DECL((void)); extern void MoveModeSubMenu ARGS_DECL((int Index)); extern void RefreshMoveModeMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateMoveModeMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int MoveModeMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void StretchableTextModeSubMenu ARGS_DECL((int Index)); extern void RefreshStretchableTextModeMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateStretchableTextModeMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int StretchableTextModeMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void RefreshTransPatModeMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateTransPatModeMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int TransPatModeMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int RefreshGridMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateGridMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int GridMenu ARGS_DECL((int X, int Y, int TrackMenubar)); #ifdef _INCLUDE_FROM_GRID_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_GRID_C_*/ #endif /*_GRID_E_*/ tgif-QPL-4.2.5/launch-demo-1.obj0000644000076400007640000001002011602233312016003 0ustar williamwilliam%TGIF 2.12-p16 state(0,27,100,0,0,0,8,1,0,2,0,0,0,1,0,1,0,0,0,3,1,0,0,10,0,0,1,1,0,16,1). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/launch-demo-1.obj,v 1.1 2004/09/14 05:26:24 william Exp $ % %W% % group([ text('green',88,64,0,0,3,5,0,0,1,241,118,388,1,18,4,0,2,0,0,[ "Modify the ""dir"" attributes.", "Hold down the key", "and click the middle button on", "any one of these objects to see", "LAUNCH and WART demoes."]), text('green',64,64,0,0,3,1,0,0,1,16,22,390,1,18,4,0,0,0,0,[ "1)"]), text('green',64,88,0,0,3,1,0,0,1,16,22,392,1,18,4,0,0,0,0,[ "2)"]) ], 404,0,[ ]). group([ polygon('yellow',9,[ 209,232,211,234,211,250,195,250,195,258,193,256,193,248,209,248, 209,232],1,1,1,0,475,0,0,0,[ ]), polygon('yellow',8,[ 209,232,193,232,193,224,177,240,193,256,193,248,209,248,209,232],2,1,1,0,436,0,0,0,[ ]) ], 537,0,[ attr("warp_to=", "launch-demo", 1, 1, 0, text('yellow',192,256,0,0,3,1,1,0,1,178,22,28,1,18,4,0,0,0,0,[ "warp_to=launch-demo"])) ]). group([ text('green',88,312,0,0,3,8,0,0,1,246,190,648,1,18,4,0,2,0,0,[ "To get a fancier look. Select an", "object and type m.", "Then use left button to get a", "popup menu; select an attribute;", "click right button to hide the", "attribute or click the middle", "button to hide the attribute", "name."]), text('green',64,312,0,0,3,1,0,0,1,16,22,649,1,18,4,0,0,0,0,[ "3)"]) ], 647,0,[ ]). group([ rcbox('#8888ff',464,248,560,328,7,1,1,0,16,228,0,0,[ ]), text('#8888ff',512,256,2,0,5,1,1,0,2,45,29,229,0,24,5,0,0,0,0,[ "xdvi"]) ], 227,0,[ attr("name=", "example", 1, 1, 0, text('red',512,288,2,0,5,1,1,0,1,166,29,230,0,24,5,0,0,0,0,[ "name=example"])), attr("dir=", "/u/tangram/u/william/X11/TGIF2", 1, 1, 0, text('yellow',512,328,0,0,3,1,1,0,1,289,22,231,1,18,4,0,0,0,0,[ "dir=/u/tangram/u/william/X11/TGIF2"])), attr("launch=", "cd $(dir); xdvi -expert $(name) &", 1, 1, 0, text('yellow',512,224,0,0,3,1,1,0,1,323,22,232,1,18,4,0,0,0,0,[ "launch=cd $(dir); xdvi -expert $(name) &"])) ]). group([ rcbox('#ff8888',464,88,560,168,0,1,0,0,16,93,0,0,[ ]), xbm('#ff8888',480,96,544,136,0,82,0,32,20,0,0,0,0,0,0,0,0,0, "","", "00000000000000000000000021bf810421840088218400882244fe5022448050 23c4802022448050242480502424fc88200480883f8481040000800000008000 0000fe00000000000000000000000000",[ ]) ], 247,0,[ attr("launch=", "cd $(dir); latex $(name)", 1, 1, 0, text('yellow',512,64,0,0,3,1,1,0,1,246,22,23,1,18,4,0,0,0,0,[ "launch=cd $(dir); latex $(name)"])), attr("dir=", "/u/tangram/u/william/X11/TGIF2", 1, 1, 0, text('yellow',512,168,0,0,3,1,1,0,1,289,22,34,1,18,4,0,0,0,0,[ "dir=/u/tangram/u/william/X11/TGIF2"])), attr("name=", "example", 1, 1, 0, text('blue',512,128,2,0,5,1,1,0,1,166,29,54,0,24,5,0,0,0,0,[ "name=example"])) ]). group([ polygon('cyan',5,[ 502,448,493,480,547,480,556,448,502,448],2,1,0,0,1465,0,0,0,[ ]), polygon('cyan',5,[ 493,480,484,512,538,512,547,480,493,480],2,1,0,0,1466,0,0,0,[ ]), poly('cyan',2,[ 502,448,556,448],0,1,1,1467,0,0,0,0,8,3,0,[ ]), poly('cyan',2,[ 484,512,538,512],0,1,1,1468,0,0,0,0,8,3,0,[ ]), poly('cyan',3,[ 502,448,484,464,493,480],0,1,1,1469,1,2,0,0,8,3,0,[ ]), poly('cyan',3,[ 484,512,502,496,493,480],0,1,1,1470,1,2,0,0,8,3,0,[ ]), poly('cyan',3,[ 556,448,538,464,547,480],0,1,1,1471,1,2,0,0,8,3,0,[ ]), poly('cyan',3,[ 538,512,556,496,547,480],0,1,1,1472,1,2,0,0,8,3,0,[ ]) ], 1464,0,[ attr("page=", "1", 1, 1, 0, text('magenta',520,452,2,2,5,1,1,0,1,82,29,1473,0,24,5,0,0,0,0,[ "page=1"])), attr("dir=", "/u/tangram/u/william/X11/TGIF2", 1, 1, 0, text('yellow',520,512,0,0,3,1,1,0,1,289,22,1474,1,18,4,0,0,0,0,[ "dir=/u/tangram/u/william/X11/TGIF2"])), attr("launch=", "cd $(dir);", 1, 1, 0, text('yellow',512,384,0,0,3,3,1,0,1,370,66,1475,1,18,4,0,0,0,0,[ "launch=cd $(dir);", "dvips -N -n 1 -p $(page) $(name) > $(tmpfile);", "xterm -geom 40x8+200+400 -e gs $(tmpfile) &"])), attr("name=", "example", 1, 1, 0, text('green',524,476,2,0,5,1,1,0,1,166,29,1476,0,24,5,0,0,0,0,[ "name=example"])), attr("tmpfile=", "/tmp/tgif.ps", 1, 1, 0, text('yellow',520,536,0,0,3,1,1,0,1,151,22,1551,1,18,4,0,0,0,0,[ "tmpfile=/tmp/tgif.ps"])) ]). tgif-QPL-4.2.5/names.e0000644000076400007640000000622511602233312014242 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/names.e,v 1.6 2011/05/16 16:21:58 william Exp $ */ #ifndef _NAMES_E_ #define _NAMES_E_ extern char curDomainName[]; extern char curDomainPath[]; extern char curDir[]; extern char curLocalDir[]; extern char curSymDir[]; extern int doubleClickInterval; extern int importFromLibrary; extern int importingFromExec; extern int curDirIsLocal; extern int ignoreDirectoryFlag; /* use to be ignoreDirectoryFlagInMakeNameDspItemArray; */ #ifdef _INCLUDE_FROM_NAMES_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_NAMES_C_*/ extern void ParseSymPath ARGS_DECL((char*)); extern void InitNames ARGS_DECL((void)); extern void UpdateDirInfo ARGS_DECL((void)); extern void UpdateSymInfo ARGS_DECL((void)); extern void CleanUpNames ARGS_DECL((void)); extern int DirInSymPath ARGS_DECL((char *DirName)); extern char **MakeNameDspItemArray ARGS_DECL((int Entries, DspList*)); extern int SelectFileName ARGS_DECL((char *MsgStr, char *SelStr)); extern int SelectFileNameToPaste ARGS_DECL((char *MsgStr, char *SelStr)); extern int SelectFileNameToImport ARGS_DECL((char *MsgStr, char *ExtStr, char *SelStr)); extern int GetSymbolPath ARGS_DECL((char *SymName, int Pin, char *PathName)); extern int NameInCurDir ARGS_DECL((char *FileName)); extern void ChangeDomain ARGS_DECL((void)); extern int SelectSymDir ARGS_DECL((char *SelStr)); extern int SelectFromLibrary ARGS_DECL((char *MsgStr, char *ExtStr, char *SelStr, char *PathStr)); extern void SetCurDir ARGS_DECL((char *FileName)); extern void SetCurSymDir ARGS_DECL((char *FileName)); extern void SetCurImportDir ARGS_DECL((char *FileName)); extern void CopyDomainInfoToIni ARGS_DECL((void)); extern void EditDomainPaths ARGS_DECL((void)); extern void SelectDefaultDomain ARGS_DECL((void)); extern void AddADomain ARGS_DECL((void)); extern void DeleteADomain ARGS_DECL((void)); extern void ReloadDomainInfoFromX ARGS_DECL((void)); extern int RefreshDomainMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateDomainMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); #ifdef _INCLUDE_FROM_NAMES_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_NAMES_C_*/ #endif /*_NAMES_E_*/ tgif-QPL-4.2.5/pngtrans.c0000644000076400007640000004103211602233312014764 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/pngtrans.c,v 1.11 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_PNGTRANS_C_ #include "tgifdefs.h" #if (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) #include #endif /* (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ #include "dialog.e" #include "pngtrans.e" #include "msg.e" #include "strtbl.e" #include "util.e" static int gnDebugPngParse=0; static unsigned char pngHeader[8] = { 0x89, 0x50, 0x4e, 0x47, 0x0d, 0x0a, 0x1a, 0x0a }; static int PngShowOrPrintMsg(buf, use_msgbox) char *buf; int use_msgbox; { if (gnDebugPngParse > 0) { return ShowOrPrintMsg(buf, use_msgbox); } return FALSE; } static int VerifyPngHeader(fp) FILE *fp; { unsigned char buf[8]; if (fread(buf, sizeof(char), 8, fp) != 8) { strcpy(gszMsgBox, TgLoadString(STID_BADPNG_SHORT_HEADER)); return PngShowOrPrintMsg(gszMsgBox, TRUE); } if (memcmp(pngHeader, buf, 8) != 0) { strcpy(gszMsgBox, TgLoadString(STID_BADPNG_BAD_HEADER)); return PngShowOrPrintMsg(gszMsgBox, TRUE); } return TRUE; } static int ReadPngDWord(pvalue32, fp) uint32_t *pvalue32; FILE *fp; { unsigned char buf[4]; uint32_t value32=(uint32_t)0; int bytes_read=fread(buf, sizeof(char), 4, fp); if (bytes_read != 4) { return bytes_read; } value32 += (uint32_t)(buf[0]); value32 <<= 8; value32 += (uint32_t)(buf[1]); value32 <<= 8; value32 += (uint32_t)(buf[2]); value32 <<= 8; value32 += (uint32_t)(buf[3]); *pvalue32 = value32; return 4; } static int ReadPngShortWord(pvalue16, fp) uint16_t *pvalue16; FILE *fp; { unsigned char buf[2]; uint16_t value16=(uint16_t)0; int bytes_read=fread(buf, sizeof(char), 2, fp); if (bytes_read != 2) { return bytes_read; } value16 += (uint16_t)(buf[0]); value16 <<= 8; value16 += (uint16_t)(buf[1]); *pvalue16 = value16; return 2; } static void PngHexDump(buf, len, pn_index, pn_line_num) unsigned char *buf; unsigned int len; int *pn_index, *pn_line_num; { int index=(*pn_index), line_num=(*pn_line_num); while (len > 0) { if (index == 0) { fprintf(stdout, "%06x: ", line_num<<4); } fprintf(stdout, "%02x ", (int)(unsigned int)(*buf)); index++; if (index == 8) { fprintf(stdout, " "); } else if (index == 16) { index = 0; line_num++; fprintf(stdout, "\n"); } len--; buf++; } *pn_index = index; *pn_line_num = line_num; } static int DoInflateForPng(in_buf, v32_length) unsigned char *in_buf; uint32_t v32_length; { #if (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) int ret=0, has_left_over=FALSE, index=0, line_num=0; int bytes_left=(int)(unsigned int)v32_length; unsigned int block_sz=0x4000; unsigned int have=0; z_stream strm; unsigned char in[0x4000], out[0x4000]; /* allocate inflate state */ memset(&strm, 0, sizeof(strm)); strm.zalloc = Z_NULL; strm.zfree = Z_NULL; strm.opaque = Z_NULL; strm.avail_in = 0; strm.next_in = Z_NULL; ret = inflateInit(&strm); if (ret != Z_OK) { return FALSE; } do { int bytes_to_read=min(block_sz, bytes_left); if (bytes_to_read == 0) break; memcpy(in, in_buf, bytes_to_read); bytes_left -= bytes_to_read; in_buf += bytes_to_read; strm.avail_in = bytes_to_read; strm.next_in = in; /* run inflate() on input until output buffer not full */ do { strm.avail_out = block_sz; strm.next_out = out; ret = inflate(&strm, Z_NO_FLUSH); if (ret == Z_STREAM_ERROR) return FALSE; switch (ret) { case Z_NEED_DICT: ret = Z_DATA_ERROR; /* and fall through */ case Z_DATA_ERROR: case Z_MEM_ERROR: (void)inflateEnd(&strm); return FALSE; } have = block_sz - strm.avail_out; if (gnDebugPngParse > 1) PngHexDump(out, have, &index, &line_num); } while (strm.avail_out == 0); /* done when inflate() says it's done */ } while (ret != Z_STREAM_END); if (has_left_over) { (void)inflateEnd(&strm); return FALSE; } /* clean up and return */ inflateEnd(&strm); if (ret == Z_STREAM_END) { return TRUE; } return FALSE; #else /* ~(!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ return FALSE; #endif /* (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ } static void SetPngFileTransColor(pphi, red, green, blue) PngHeaderInfo *pphi; unsigned int red, green, blue; { pphi->trans_color_pixel_found = TRUE; pphi->trans_color_pixel_red = (unsigned char)(red & 0x00ff); pphi->trans_color_pixel_green = (unsigned char)(green & 0x00ff); pphi->trans_color_pixel_blue = (unsigned char)(blue & 0x00ff); } static int ReadChunk(pphi, psz_chunk_type, v32_length, fp) PngHeaderInfo *pphi; char *psz_chunk_type; uint32_t v32_length; FILE *fp; { int i=0; uint32_t bytes_read=0, bytes_left=v32_length; uint16_t v16=(uint16_t)0; if (gnDebugPngParse > 0) { /* debug, do not translate */ fprintf(stdout, "%s: length = %1d (0x%08x)\n", psz_chunk_type, (int)(unsigned int)v32_length, (int)(unsigned int)v32_length); fflush(stdout); } if (strncmp(psz_chunk_type, "IHDR", 4) == 0) { if (v32_length == 13) { if ((bytes_read=ReadPngDWord(&pphi->image_w, fp)) != 4) return FALSE; if ((bytes_read=ReadPngDWord(&pphi->image_h, fp)) != 4) return FALSE; if ((bytes_read=fread(&pphi->bit_depth, sizeof(char), 1, fp)) != 1) return FALSE; if ((bytes_read=fread(&pphi->color_type, sizeof(char), 1, fp)) != 1) return FALSE; if ((bytes_read=fread(&pphi->compression_method, sizeof(char), 1, fp)) != 1) return FALSE; if ((bytes_read=fread(&pphi->filter_method, sizeof(char), 1, fp)) != 1) return FALSE; if ((bytes_read=fread(&pphi->interlace_method, sizeof(char), 1, fp)) != 1) return FALSE; pphi->valid = TRUE; if (gnDebugPngParse > 0) { /* debug, do not translate */ fprintf(stdout, "Width = %1d (0x%08x), Height = %1d (0x%08x), Color type = %1d, Bit depth = %1d, Compression = %1d, Filter = %1d, Interlace = %1d\n", (int)(unsigned int)pphi->image_w, (int)(unsigned int)pphi->image_w, (int)(unsigned int)pphi->image_h, (int)(unsigned int)pphi->image_h, (int)(unsigned int)pphi->color_type, (int)(unsigned int)pphi->bit_depth, (int)(unsigned int)pphi->compression_method, (int)(unsigned int)pphi->filter_method, (int)(unsigned int)pphi->interlace_method); } switch (pphi->color_type) { case 0: break; /* Greyscale, allowed bit depths are 1, 2, 4, 8, 16 */ case 2: break; /* Truecolor, allowed bit depths are 8, 16 */ case 3: break; /* Indexed-colour, allowed bit depths are 1, 2, 4, 8 */ case 4: /* don't know how to handle Greyscale with alpha */ case 6: /* don't know how to handle Truecolour with alpha */ if (gnDebugPngParse > 0) { /* debug, do not translate */ fprintf(stdout, "Transparent color type unsupported.\n"); } return FALSE; } return TRUE; } else { if (gnDebugPngParse > 0) { /* debug, do not translate */ fprintf(stdout, "Unexpected IHDR chunk size: %1d (0x%08x).\n", (int)(unsigned int)v32_length, (int)(unsigned int)v32_length); } strcpy(gszMsgBox, TgLoadString(STID_BADPNG_BAD_HEADER)); return PngShowOrPrintMsg(gszMsgBox, TRUE); } } else if (strncmp(psz_chunk_type, "IDAT", 4) == 0) { if (pphi->valid && pphi->compression_method == 0) { if (gnDebugPngParse > 0) { unsigned char *buf=(unsigned char *)malloc(v32_length); if (buf == NULL) FailAllocMessage(); if ((bytes_read=fread(buf, sizeof(char), v32_length, fp)) != v32_length) return FALSE; if (!DoInflateForPng(buf, v32_length)) { /* debug, do not translate */ fprintf(stdout, "DoInflateForPng() failed.\n"); fflush(stdout); return FALSE; } free(buf); return TRUE; } } } else if (strncmp(psz_chunk_type, "PLTE", 4) == 0) { if (pphi->valid && v32_length % 3 == 0) { int num_entries=v32_length/3; unsigned char *psz=NULL; pphi->palette = (unsigned char *)malloc(v32_length); if (pphi->palette == NULL) FailAllocMessage(); if ((bytes_read=fread(pphi->palette, sizeof(char), v32_length, fp)) != v32_length) return FALSE; pphi->palette_sz = v32_length; if (gnDebugPngParse > 0) { psz = pphi->palette; for (i=0; i < num_entries; i++) { /* debug, do not translate */ fprintf(stdout, "%04d: %02x%02x%02x\n", i, (int)psz[0], (int)psz[1], (int)psz[2]); psz = &psz[3]; } } return TRUE; } else { strcpy(gszMsgBox, TgLoadString(STID_BADPNG_BAD_PALETTE_LEN)); return PngShowOrPrintMsg(gszMsgBox, TRUE); } } else if (strncmp(psz_chunk_type, "tRNS", 4) == 0) { if (pphi->valid && pphi->color_type == 0 && v32_length == 2) { /* Greyscale, allowed bit depths are 1, 2, 4, 8, 16 */ if ((bytes_read=ReadPngShortWord(&v16, fp)) != 2) return FALSE; switch (pphi->bit_depth) { case 1: v16 = ((v16 & 0x0001) == 0x0001) ? 0x00ff : 0; break; case 2: v16 = v16 & 0x0003; v16 = v16 | ((v16<<2)&0x000c) | ((v16<<4)&0x0030) | ((v16<<6)&0x00c0); break; case 4: v16 = v16 & 0x000f; v16 = v16 | ((v16<<4)&0x00f0); break; case 8: v16 = v16 & 0x00ff; break; case 16: v16 = (v16>>8) & 0x00ff; break; default: return FALSE; } SetPngFileTransColor(pphi, (unsigned int)v16, (unsigned int)v16, (unsigned int)v16); return TRUE; } else if (pphi->valid && pphi->color_type == 2 && v32_length == 6) { /* Truecolor, allowed bit depths are 8, 16 */ uint16_t v16r=(uint16_t)0, v16g=(uint16_t)0, v16b=(uint16_t)0; if ((bytes_read=ReadPngShortWord(&v16r, fp)) != 2) return FALSE; if ((bytes_read=ReadPngShortWord(&v16b, fp)) != 2) return FALSE; if ((bytes_read=ReadPngShortWord(&v16g, fp)) != 2) return FALSE; switch (pphi->bit_depth) { case 8: v16r = v16r & 0x00ff; v16g = v16g & 0x00ff; v16b = v16b & 0x00ff; break; case 16: v16 = (v16>>8) & 0x00ff; break; default: return FALSE; } SetPngFileTransColor(pphi, (unsigned int)v16r, (unsigned int)v16g, (unsigned int)v16b); return TRUE; } else if (pphi->valid && pphi->color_type == 3 && v32_length == 1) { /* Indexed-colour, allowed bit depths are 1, 2, 4, 8 */ unsigned char palette_index='\0', *psz=NULL; if ((bytes_read=fread(&palette_index, sizeof(char), 1, fp)) != 1) return FALSE; if (pphi->palette == NULL || palette_index >= pphi->palette_sz) return FALSE; psz = &pphi->palette[palette_index*3]; /* * the bit_depth is used to control the number of entries in the * palette, not the number of bits in RGB */ switch (pphi->bit_depth) { case 1: break; case 2: break; case 4: break; case 8: break; default: return FALSE; } SetPngFileTransColor(pphi, (unsigned int)psz[0], (unsigned int)psz[1], (unsigned int)psz[2]); return TRUE; } else { if (gnDebugPngParse > 0) { /* debug, do not translate */ fprintf(stdout, "Transparent color type unsupported.\n"); } return FALSE; } } if (fseek(fp, (long)bytes_left, SEEK_CUR) != 0) { return FALSE; } return TRUE; } static int ProcessChunk(pphi) PngHeaderInfo *pphi; { uint32_t v32_length=(uint32_t)0, v32_crc=(uint32_t)0; int bytes_read=0; char sz_chunk_type[5]; FILE *fp=pphi->fp; if ((bytes_read=ReadPngDWord(&v32_length, fp)) == 0) return FALSE; if (bytes_read != 4) { sprintf(gszMsgBox, TgLoadString(STID_BADPNG_BAD_CHUNK_LEN), bytes_read); return PngShowOrPrintMsg(gszMsgBox, TRUE); } if ((bytes_read=fread(sz_chunk_type, sizeof(unsigned char), 4, fp)) != 4) { strcpy(gszMsgBox, TgLoadString(STID_BADPNG_SHORT_CHUNK_TYPE)); return PngShowOrPrintMsg(gszMsgBox, TRUE); } sz_chunk_type[4] = '\0'; if (!ReadChunk(pphi, sz_chunk_type, v32_length, fp)) return FALSE; if ((bytes_read=ReadPngDWord(&v32_crc, fp)) != 4) { strcpy(gszMsgBox, TgLoadString(STID_BADPNG_SHORT_CRC)); return PngShowOrPrintMsg(gszMsgBox, TRUE); } return TRUE; } /* ----------------------- ParseTransColor() ----------------------- */ int ParseTransColor(char *buf, unsigned char *puch_trans_color_pixel_r, unsigned char *puch_trans_color_pixel_g, unsigned char *puch_trans_color_pixel_b) { char buf_r[5], buf_g[5], buf_b[5]; int r=0, g=0, b=0; if (*buf != '#' || strlen(buf) != 7) { return FALSE; } buf_r[0] = '0'; buf_r[1] = '0'; buf_r[2] = buf[1]; buf_r[3] = buf[2]; buf_r[4] = '\0'; buf_g[0] = '0'; buf_g[1] = '0'; buf_g[2] = buf[3]; buf_g[3] = buf[4]; buf_g[4] = '\0'; buf_b[0] = '0'; buf_b[1] = '0'; buf_b[2] = buf[5]; buf_b[3] = buf[6]; buf_b[4] = '\0'; if (sscanf(buf_r, "%x", &r) != 1) return FALSE; if (sscanf(buf_g, "%x", &g) != 1) return FALSE; if (sscanf(buf_b, "%x", &b) != 1) return FALSE; *puch_trans_color_pixel_r = (unsigned char)(r & 0x0ff); *puch_trans_color_pixel_g = (unsigned char)(g & 0x0ff); *puch_trans_color_pixel_b = (unsigned char)(b & 0x0ff); return TRUE; } /* ----------------------- ResetPngHeaderInfo() ----------------------- */ void ResetPngHeaderInfo(pphi) PngHeaderInfo *pphi; { memset(pphi, 0, sizeof(PngHeaderInfo)); } /* ----------------------- SetPngHeaderInfoForTransColor() ----------------------- */ void SetPngHeaderInfoForTransColor(pphi, trans_color_pixel_r, trans_color_pixel_g, trans_color_pixel_b) PngHeaderInfo *pphi; unsigned char trans_color_pixel_r, trans_color_pixel_g, trans_color_pixel_b; { ResetPngHeaderInfo(pphi); pphi->valid = TRUE; pphi->trans_color_pixel_found = TRUE; pphi->trans_color_pixel_red = trans_color_pixel_r; pphi->trans_color_pixel_green = trans_color_pixel_g; pphi->trans_color_pixel_blue = trans_color_pixel_b; } /* ----------------------- PngFileGetTransColorInit() ----------------------- */ int PngFileGetTransColorInit(pphi, fname) PngHeaderInfo *pphi; char *fname; { ResetPngHeaderInfo(pphi); pphi->fp = fopen(fname, "r"); if (pphi->fp == NULL) return FailToOpenMessage(fname, "r", NULL); UtilStrCpyN(pphi->fname, sizeof(pphi->fname), fname); return TRUE; } /* ----------------------- PngFileGetTransColor() ----------------------- */ int PngFileGetTransColor(pphi) PngHeaderInfo *pphi; /* * returns TRUE if transparent pixel found * returns FALSE if there is a problem parsing the PNG file or if it does not contain transparent pixels */ { if (!VerifyPngHeader(pphi->fp)) { if (pphi->fp != NULL) fclose(pphi->fp); ResetPngHeaderInfo(pphi); return FALSE; } while (ProcessChunk(pphi)) ; if (pphi->fp != NULL) { fclose(pphi->fp); pphi->fp = NULL; } if (pphi->valid && pphi->palette_sz > 0 && pphi->palette != NULL) { free(pphi->palette); } pphi->palette = NULL; return (pphi->valid && pphi->trans_color_pixel_found); } tgif-QPL-4.2.5/edit.e0000644000076400007640000001162111602233311014057 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/edit.e,v 1.23 2011/05/16 16:21:57 william Exp $ */ #ifndef _EDIT_E_ #define _EDIT_E_ extern struct SelRec *outerSelForFind; extern struct SelRec *innerSelForFind; extern int ignoreObjectShadowInfoInFile; extern int objShadowXOffset; extern int objShadowYOffset; extern char objShadowColorStr[]; extern int pngExportHasTransparentColor; #ifdef _INCLUDE_FROM_EDIT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_EDIT_C_*/ extern void CleanOuterInnerSelForFind ARGS_DECL((void)); extern void CleanUpEdit ARGS_DECL((void)); extern void InitEdit ARGS_DECL((void)); extern int CanPerformImageProc ARGS_DECL((void)); extern void ConvertIntSpline ARGS_DECL((void)); extern void ConvertToBezier ARGS_DECL((void)); extern int SetBezierConvertNumSegsValue ARGS_DECL((char*)); extern void SetBezierConvertNumSegs ARGS_DECL((char*)); extern void ToggleSmoothHinge ARGS_DECL((void)); extern void DoBreakUpText ARGS_DECL((char *spec, int forced_justify)); extern void BreakUpText ARGS_DECL((char *spec)); extern void SetTextFillPatternColor ARGS_DECL((void)); extern void MakeRegularPolygon ARGS_DECL((void)); extern int DeleteStructuredSplinePoint ARGS_DECL((int index, struct PolyRec *, struct PolygonRec *)); extern void DeletePoint ARGS_DECL((void)); extern void AddPoint ARGS_DECL((void)); extern void FlushUndoBuffer ARGS_DECL((void)); extern void RestoreImageWH ARGS_DECL((void)); extern void CutMaps ARGS_DECL((void)); extern void BreakUpMaps ARGS_DECL((void)); extern void RemoveTransparentPixel ARGS_DECL((void)); extern void LayoutOnArc ARGS_DECL((void)); extern void PreciseRotate ARGS_DECL((void)); extern void RotateAllSelObj ARGS_DECL((double degrees)); extern void NoTransform ARGS_DECL((void)); extern void SetEditTextSize ARGS_DECL((void)); extern void FindCaseSensitive ARGS_DECL((void)); extern void FindNoCase ARGS_DECL((void)); extern void FindAgain ARGS_DECL((void)); extern int RefreshEditMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateEditMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int EditMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void FrontProc ARGS_DECL((void)); extern void BackProc ARGS_DECL((void)); extern void AlignObjsTop ARGS_DECL((void)); extern void AlignObjsMiddle ARGS_DECL((void)); extern void AlignObjsBottom ARGS_DECL((void)); extern void AlignObjsLeft ARGS_DECL((void)); extern void AlignObjsCenter ARGS_DECL((void)); extern void AlignObjsRight ARGS_DECL((void)); extern void AbutHorizontal ARGS_DECL((void)); extern void AbutVertical ARGS_DECL((void)); extern void RefreshArrangeMenu ARGS_DECL((TgMenu*)); extern int ArrangeMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int RefreshPropertiesMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreatePropertiesMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int PropertiesMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void UpdateSymbols ARGS_DECL((void)); extern void SizeToWidest ARGS_DECL((void)); extern void SizeToNarrowest ARGS_DECL((void)); extern void SizeToTallest ARGS_DECL((void)); extern void SizeToShortest ARGS_DECL((void)); extern void SizeToGivenWidthHeight ARGS_DECL((void)); extern void SizeToGivenWidth ARGS_DECL((void)); extern void SizeToGivenHeight ARGS_DECL((void)); extern void SetObjectShadowColor ARGS_DECL((void)); extern void SetObjectShadowOffsets ARGS_DECL((void)); extern void AddObjectShadow ARGS_DECL((void)); extern void RemoveObjectShadow ARGS_DECL((void)); extern int ReadObjectShadowInfo ARGS_DECL((char*)); extern void ExtendSegment ARGS_DECL((void)); extern void ToggleTighterStructuredSplines ARGS_DECL((void)); extern int RefreshPolySplineMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreatePolySplineMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); #ifdef _INCLUDE_FROM_EDIT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_EDIT_C_*/ #endif /*_EDIT_E_*/ tgif-QPL-4.2.5/pin.sym0000644000076400007640000000071011602233312014302 0ustar williamwilliamstate(0,14,100,0,0,0,16,1,4,2,2,0,0,0,0,1,1,1,0,5,0,0,0,10,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/pin.sym,v 1.1 2004/06/18 23:20:01 william Exp $ % sym([ box('yellow',96,96,128,128,0,0,0,76,0,0,[ ]), box('yellow',108,108,116,116,2,0,1,77,0,0,[ ]) ],[ attr("name=", "", 1, 1, 0, text('green',112,88,1,0,4,1,1,0,1,55,19,78,0,15,4,0,0,0,[ "name="])), attr("num=", "", 1, 1, 0, text('green',112,72,1,0,4,1,1,0,1,44,19,79,0,15,4,0,0,0,[ "num="])) ]). tgif-QPL-4.2.5/Tgif.tmpl-cygwin0000644000076400007640000000513711602233313016060 0ustar williamwilliamXCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-cygwin,v 1.19 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif XCOMM MOREDEFINES = -D_HAS_STREAMS_SUPPORT -DENABLE_NLS -D_TGIF_DBG LOCALEDIR = /usr/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -DUSE_XT_INITIALIZE -D_NO_RAND48 -D_NO_IDNLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM DEPLIBS = $(DEPXLIB) DEPLIBS = $(DEPXMULIB) $(DEPXTOOLLIB) $(DEPXLIB) XCOMM LOCAL_LIBRARIES = $(XLIB) LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM Windows 2000 w/ CgyWin+XFree86+Exceed XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM tgif-QPL-4.2.5/move.c0000644000076400007640000026551211602233312014111 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/move.c,v 1.34 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_MOVE_C_ #include "tgifdefs.h" #include "arc.e" #include "attr.e" #include "choice.e" #include "cmd.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "exec.e" #include "grid.e" #include "mainloop.e" #include "mark.e" #include "move.e" #include "msg.e" #include "names.e" #include "obj.e" #include "oval.e" #include "poly.e" #include "raster.e" #include "rcbox.e" #include "rect.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "spline.e" #include "stretch.e" #include "strtbl.e" int oneMotionTimeout=200; int minMoveInterval=0; static void MovePoly(ObjPtr, Dx, Dy) register struct ObjRec *ObjPtr; register int Dx, Dy; { register int i; for (i=0; i < ObjPtr->detail.p->n; i++) { ObjPtr->detail.p->vlist[i].x += Dx; ObjPtr->detail.p->vlist[i].y += Dy; } } static void MovePolygon(ObjPtr, Dx, Dy) register struct ObjRec *ObjPtr; register int Dx, Dy; { register int i; for (i=0; i < ObjPtr->detail.g->n; i++) { ObjPtr->detail.g->vlist[i].x += Dx; ObjPtr->detail.g->vlist[i].y += Dy; } } static void MoveArc(ObjPtr, Dx, Dy) struct ObjRec *ObjPtr; register int Dx, Dy; { register struct ArcRec *arc_ptr=ObjPtr->detail.a; arc_ptr->xc += Dx; arc_ptr->yc += Dy; arc_ptr->x1 += Dx; arc_ptr->y1 += Dy; arc_ptr->x2 += Dx; arc_ptr->y2 += Dy; arc_ptr->ltx += Dx; arc_ptr->lty += Dy; } void MoveObj(ObjPtr, Dx, Dy) struct ObjRec *ObjPtr; int Dx, Dy; { struct ObjRec *ptr=NULL; int saved_undoing_or_redoing=undoingOrRedoing; ObjPtr->x += Dx; ObjPtr->y += Dy; ObjPtr->bbox.ltx += Dx; ObjPtr->bbox.lty += Dy; ObjPtr->bbox.rbx += Dx; ObjPtr->bbox.rby += Dy; ObjPtr->obbox.ltx += Dx; ObjPtr->obbox.lty += Dy; ObjPtr->obbox.rbx += Dx; ObjPtr->obbox.rby += Dy; MoveRotatedObjCache(ObjPtr, Dx, Dy); switch (ObjPtr->type) { case OBJ_POLY: MoveAttrs(ObjPtr->fattr, Dx, Dy); MovePoly(ObjPtr, Dx, Dy); /* fake the undoingOrRedoing so that no */ /* actual auto-adjusting is done */ undoingOrRedoing = TRUE; AdjObjSplineVs(ObjPtr); undoingOrRedoing = saved_undoing_or_redoing; break; case OBJ_BOX: MoveAttrs(ObjPtr->fattr, Dx, Dy); break; case OBJ_OVAL: MoveAttrs(ObjPtr->fattr, Dx, Dy); break; case OBJ_TEXT: ObjPtr->detail.t->baseline_y += Dy; break; case OBJ_POLYGON: MoveAttrs(ObjPtr->fattr, Dx, Dy); MovePolygon(ObjPtr, Dx, Dy); AdjObjSplineVs(ObjPtr); break; case OBJ_ARC: MoveAttrs(ObjPtr->fattr, Dx, Dy); MoveArc(ObjPtr, Dx, Dy); AdjObjSplineVs(ObjPtr); break; case OBJ_RCBOX: MoveAttrs(ObjPtr->fattr, Dx, Dy); break; case OBJ_XBM: MoveAttrs(ObjPtr->fattr, Dx, Dy); break; case OBJ_XPM: MoveAttrs(ObjPtr->fattr, Dx, Dy); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: MoveAttrs(ObjPtr->fattr, Dx, Dy); for (ptr=ObjPtr->detail.r->first; ptr != NULL; ptr=ptr->next) { MoveObj(ptr, Dx, Dy); } break; } } void MoveAllSelObjects(Dx, Dy) register int Dx, Dy; { register struct SelRec *sel_ptr; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (!sel_ptr->obj->locked) { MoveObj(sel_ptr->obj, Dx, Dy); } } if (numObjLocked != 0) Msg(TgLoadCachedString(CSTID_LOCKED_OBJS_NOT_MOVED)); } static void MarkObjectsForMove() { register struct ObjRec *obj_ptr; register struct SelRec *sel_ptr; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->marked = FALSE; } for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { sel_ptr->obj->marked = TRUE; } } static int EndPtInObjList(XOff, YOff, FirstObjPtr) int XOff, YOff; struct ObjRec *FirstObjPtr; /* XOff and YOff are screen offsets */ { register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; int found=FALSE, saved_fill=0, saved_trans_pat=FALSE; for (obj_ptr=FirstObjPtr; obj_ptr != NULL; obj_ptr=obj_ptr->next) { for (attr_ptr=obj_ptr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown && XOff >= OFFSET_X(attr_ptr->obj->bbox.ltx)-3 && YOff >= OFFSET_Y(attr_ptr->obj->bbox.lty)-3 && XOff <= OFFSET_X(attr_ptr->obj->bbox.rbx)+3 && YOff <= OFFSET_Y(attr_ptr->obj->bbox.rby)+3) { return TRUE; } } if (XOff >= OFFSET_X(obj_ptr->bbox.ltx)-3 && YOff >= OFFSET_Y(obj_ptr->bbox.lty)-3 && XOff <= OFFSET_X(obj_ptr->bbox.rbx)+3 && YOff <= OFFSET_Y(obj_ptr->bbox.rby)+3) { switch (obj_ptr->type) { case OBJ_TEXT: if (FindGoodText(XOff,YOff,obj_ptr)) return TRUE; break; case OBJ_XBM: if (FindGoodXBm(XOff,YOff,obj_ptr)) return TRUE; break; case OBJ_XPM: if (FindGoodXPm(XOff,YOff,obj_ptr)) return TRUE; break; case OBJ_BOX: saved_trans_pat = obj_ptr->trans_pat; saved_fill = obj_ptr->detail.b->fill; obj_ptr->detail.b->fill = SOLIDPAT; found = FindGoodBox(XOff,YOff,obj_ptr); obj_ptr->detail.b->fill = saved_fill; obj_ptr->trans_pat = saved_trans_pat; if (found) return TRUE; break; case OBJ_OVAL: saved_trans_pat = obj_ptr->trans_pat; saved_fill = obj_ptr->detail.o->fill; obj_ptr->detail.o->fill = SOLIDPAT; found = FindGoodOval(XOff,YOff,obj_ptr); obj_ptr->detail.o->fill = saved_fill; obj_ptr->trans_pat = saved_trans_pat; if (found) return TRUE; break; case OBJ_POLY: if (FindGoodPoly(XOff,YOff,obj_ptr)) return TRUE; break; case OBJ_POLYGON: saved_trans_pat = obj_ptr->trans_pat; saved_fill = obj_ptr->detail.g->fill; obj_ptr->detail.g->fill = SOLIDPAT; found = FindGoodPolygon(XOff,YOff,obj_ptr); obj_ptr->detail.g->fill = saved_fill; obj_ptr->trans_pat = saved_trans_pat; if (found) return TRUE; break; case OBJ_ARC: if (FindGoodArc(XOff,YOff,obj_ptr)) return TRUE; break; case OBJ_RCBOX: saved_trans_pat = obj_ptr->trans_pat; saved_fill = obj_ptr->detail.rcb->fill; obj_ptr->detail.rcb->fill = SOLIDPAT; found = FindGoodRCBox(XOff,YOff,obj_ptr); obj_ptr->detail.rcb->fill = saved_fill; obj_ptr->trans_pat = saved_trans_pat; if (found) return TRUE; break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: if (EndPtInObjList(XOff,YOff,obj_ptr->detail.r->first)) { return TRUE; } break; case OBJ_PIN: if (EndPtInObjList(XOff,YOff,GetPinObj(obj_ptr)->detail.r->first)) { return TRUE; } } } } return FALSE; } int EndPtInSelected(XOff, YOff) int XOff, YOff; /* XOff and YOff are screen offsets */ { register struct SelRec *sel_ptr; register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; int found, saved_fill=0, saved_trans_pat=FALSE; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; if (obj_ptr->locked) continue; for (attr_ptr=obj_ptr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown && XOff >= OFFSET_X(attr_ptr->obj->bbox.ltx)-3 && YOff >= OFFSET_Y(attr_ptr->obj->bbox.lty)-3 && XOff <= OFFSET_X(attr_ptr->obj->bbox.rbx)+3 && YOff <= OFFSET_Y(attr_ptr->obj->bbox.rby)+3) { return TRUE; } } if (XOff >= OFFSET_X(obj_ptr->bbox.ltx)-3 && YOff >= OFFSET_Y(obj_ptr->bbox.lty)-3 && XOff <= OFFSET_X(obj_ptr->bbox.rbx)+3 && YOff <= OFFSET_Y(obj_ptr->bbox.rby)+3) { switch (obj_ptr->type) { case OBJ_TEXT: if (FindGoodText(XOff,YOff,obj_ptr)) return TRUE; break; case OBJ_XBM: if (FindGoodXBm(XOff,YOff,obj_ptr)) return TRUE; break; case OBJ_XPM: if (FindGoodXPm(XOff,YOff,obj_ptr)) return TRUE; break; case OBJ_BOX: saved_trans_pat = obj_ptr->trans_pat; saved_fill = obj_ptr->detail.b->fill; obj_ptr->detail.b->fill = SOLIDPAT; found = FindGoodBox(XOff,YOff,obj_ptr); obj_ptr->detail.b->fill = saved_fill; obj_ptr->trans_pat = saved_trans_pat; if (found) return TRUE; break; case OBJ_OVAL: saved_trans_pat = obj_ptr->trans_pat; saved_fill = obj_ptr->detail.o->fill; obj_ptr->detail.o->fill = SOLIDPAT; found = FindGoodOval(XOff,YOff,obj_ptr); obj_ptr->detail.o->fill = saved_fill; obj_ptr->trans_pat = saved_trans_pat; if (found) return TRUE; break; case OBJ_POLY: if (FindGoodPoly(XOff,YOff,obj_ptr)) return TRUE; break; case OBJ_POLYGON: saved_trans_pat = obj_ptr->trans_pat; saved_fill = obj_ptr->detail.g->fill; obj_ptr->detail.g->fill = SOLIDPAT; found = FindGoodPolygon(XOff,YOff,obj_ptr); obj_ptr->detail.g->fill = saved_fill; obj_ptr->trans_pat = saved_trans_pat; if (found) return TRUE; break; case OBJ_ARC: if (FindGoodArc(XOff,YOff,obj_ptr)) return TRUE; break; case OBJ_RCBOX: saved_trans_pat = obj_ptr->trans_pat; saved_fill = obj_ptr->detail.rcb->fill; obj_ptr->detail.rcb->fill = SOLIDPAT; found = FindGoodRCBox(XOff,YOff,obj_ptr); obj_ptr->detail.rcb->fill = saved_fill; obj_ptr->trans_pat = saved_trans_pat; if (found) return TRUE; break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: if (EndPtInObjList(XOff,YOff,obj_ptr->detail.r->first)) { return TRUE; } break; case OBJ_PIN: if (EndPtInObjList(XOff,YOff,GetPinObj(obj_ptr)->detail.r->first)) { return TRUE; } break; } } } return FALSE; } static int ConstrainedMoveAllSel(Dx, Dy, ltx, lty, rbx, rby) register int Dx, Dy; int *ltx, *lty, *rbx, *rby; { struct ObjRec *obj_ptr=NULL; int something_stretched=FALSE; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (!obj_ptr->marked && obj_ptr->type==OBJ_POLY && !obj_ptr->locked) { struct PolyRec *poly_ptr=obj_ptr->detail.p; IntPoint *v=obj_ptr->detail.p->vlist; int num_pts=obj_ptr->detail.p->n; int x_off=0, y_off=0, move_first=FALSE, move_last=FALSE; int move_2nd=FALSE, move_2nd_to_last=FALSE; int possibly_move_3rd=FALSE, possibly_move_3rd_to_last=FALSE; if (obj_ptr->ctm == NULL) { x_off = OFFSET_X(v[0].x); y_off = OFFSET_Y(v[0].y); move_first = EndPtInSelected(x_off, y_off); x_off = OFFSET_X(v[num_pts-1].x); y_off = OFFSET_Y(v[num_pts-1].y); move_last = EndPtInSelected(x_off, y_off); } else { int tmp_x, tmp_y; TransformPointThroughCTM(v[0].x-obj_ptr->x, v[0].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); tmp_x += obj_ptr->x; tmp_y += obj_ptr->y; x_off = OFFSET_X(tmp_x); y_off = OFFSET_Y(tmp_y); move_first = EndPtInSelected(x_off, y_off); TransformPointThroughCTM(v[num_pts-1].x-obj_ptr->x, v[num_pts-1].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); tmp_x += obj_ptr->x; tmp_y += obj_ptr->y; x_off = OFFSET_X(tmp_x); y_off = OFFSET_Y(tmp_y); move_last = EndPtInSelected(x_off, y_off); } if (move_first && poly_ptr->curved == LT_STRUCT_SPLINE && v[0].x == v[1].x && v[0].y == v[1].y) { move_2nd = TRUE; if (num_pts > 4 && v[2].x == v[3].x && v[2].y == v[3].y && v[4].x == v[3].x && v[4].y == v[3].y) { possibly_move_3rd = TRUE; } } if (move_last && poly_ptr->curved == LT_STRUCT_SPLINE && v[num_pts-1].x == v[num_pts-2].x && v[num_pts-1].y == v[num_pts-2].y) { move_2nd_to_last = TRUE; if (num_pts > 4 && v[num_pts-3].x == v[num_pts-4].x && v[num_pts-3].y == v[num_pts-4].y && v[num_pts-5].x == v[num_pts-4].x && v[num_pts-5].y == v[num_pts-4].y) { possibly_move_3rd_to_last = TRUE; } } if (move_first || move_last) { PrepareToReplaceAnObj(obj_ptr); if (obj_ptr->ctm != NULL) { /* Remove the transformations! */ int i; for (i=0; i < num_pts; i++) { int tmp_x, tmp_y; TransformPointThroughCTM(v[i].x-obj_ptr->x, v[i].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); v[i].x = tmp_x+obj_ptr->x; v[i].y = tmp_y+obj_ptr->y; } free(obj_ptr->ctm); obj_ptr->ctm = NULL; UpdPolyBBox(obj_ptr, num_pts, v); } if (something_stretched) { if (obj_ptr->bbox.ltx < *ltx) *ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < *lty) *lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > *rbx) *rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > *rby) *rby = obj_ptr->bbox.rby; } else { *ltx = obj_ptr->bbox.ltx; *lty = obj_ptr->bbox.lty; *rbx = obj_ptr->bbox.rbx; *rby = obj_ptr->bbox.rby; } something_stretched = TRUE; if (move_first && move_last) { MoveObj(obj_ptr, Dx, Dy); } else { int index=INVALID, seg_dx=0, seg_dy=0; int cur_seg_dx=0, cur_seg_dy=0; if (move_first) { if (num_pts > 2) { if (possibly_move_3rd) { /* only for LT_STRUCT_SPLINE */ index = 3; cur_seg_dx = v[index-3].x - v[index].x; cur_seg_dy = v[index-3].y - v[index].y; seg_dx = v[index].x - v[index+3].x; seg_dy = v[index].y - v[index+3].y; } else { index = 1; cur_seg_dx = v[index-1].x - v[index].x; cur_seg_dy = v[index-1].y - v[index].y; seg_dx = v[index].x - v[index+1].x; seg_dy = v[index].y - v[index+1].y; } } v[0].x += Dx; v[0].y += Dy; if (move_2nd) { v[1].x += Dx; v[1].y += Dy; } } else { if (num_pts > 2) { if (possibly_move_3rd_to_last) { /* only for LT_STRUCT_SPLINE */ index = num_pts-4; cur_seg_dx = v[index+3].x - v[index].x; cur_seg_dy = v[index+3].y - v[index].y; seg_dx = v[index].x - v[index-3].x; seg_dy = v[index].y - v[index-3].y; } else { index = num_pts-2; cur_seg_dx = v[index+1].x - v[index].x; cur_seg_dy = v[index+1].y - v[index].y; seg_dx = v[index].x - v[index-1].x; seg_dy = v[index].y - v[index-1].y; } } v[num_pts-1].x += Dx; v[num_pts-1].y += Dy; if (move_2nd_to_last) { v[num_pts-2].x += Dx; v[num_pts-2].y += Dy; } } if (poly_ptr->curved == LT_STRUCT_SPLINE) { if (possibly_move_3rd_to_last) { if (cur_seg_dy==0 && cur_seg_dx!=0 && (seg_dy!=0 || (seg_dy==0 && Dx==0))) { v[index-1].y += Dy; v[index].y += Dy; v[index+1].y += Dy; } else if (cur_seg_dx==0 && cur_seg_dy!=0 && (seg_dx!=0 || (seg_dx==0 && Dy==0))) { v[index-1].x += Dx; v[index].x += Dx; v[index+1].x += Dx; } } } else { if (num_pts>2 && cur_seg_dy==0 && cur_seg_dx!=0 && (seg_dy!=0 || (seg_dy==0 && Dx==0))) { v[index].y += Dy; } else if (num_pts>2 && cur_seg_dx==0 && cur_seg_dy!=0 && (seg_dx!=0 || (seg_dx==0 && Dy==0))) { v[index].x += Dx; } } } AdjObjSplineVs(obj_ptr); if (obj_ptr->detail.p->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, num_pts, v); } else { UpdPolyBBox(obj_ptr, obj_ptr->detail.p->intn, obj_ptr->detail.p->intvlist); } if (AutoCenterAttr(obj_ptr)) { struct AttrRec *attr_ptr=obj_ptr->fattr; int modified=FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { struct BBRec bbox; CenterObjInOBBox(attr_ptr->obj, obj_ptr->obbox, &bbox); if (bbox.ltx < *ltx) *ltx = bbox.ltx; if (bbox.lty < *lty) *lty = bbox.lty; if (bbox.rbx > *rbx) *rbx = bbox.rbx; if (bbox.rby > *rby) *rby = bbox.rby; modified = TRUE; } } if (modified) AdjObjBBox(obj_ptr); } if (obj_ptr->bbox.ltx < *ltx) *ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < *lty) *lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > *rbx) *rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > *rby) *rby = obj_ptr->bbox.rby; RecordReplaceAnObj(obj_ptr); } } } MoveAllSelObjects(Dx, Dy); return something_stretched; } void MoveAllSel(Dx, Dy) register int Dx, Dy; { int ltx=0, lty=0, rbx=0, rby=0; struct SubCmdRec *sub_cmd=NULL; sub_cmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (sub_cmd == NULL) FailAllocMessage(); memset(sub_cmd, 0, sizeof(struct SubCmdRec)); sub_cmd->detail.move.dx = Dx; sub_cmd->detail.move.dy = Dy; if (moveMode==CONST_MOVE && !justDupped) { MarkObjectsForMove(); StartCompositeCmd(); PrepareToRecord(CMD_MOVE, topSel, botSel, numObjSelected); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); if (ConstrainedMoveAllSel(Dx, Dy, <x, <y, &rbx, &rby)) { ltx = min(ltx,min(selLtX,selLtX+Dx)); lty = min(lty,min(selLtY,selLtY+Dy)); rbx = max(rbx,max(selRbX,selRbX+Dx)); rby = max(rby,max(selRbY,selRbY+Dy)); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); } else { RedrawAreas(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1)+Dx, selLtY-GRID_ABS_SIZE(1)+Dy, selRbX+GRID_ABS_SIZE(1)+Dx, selRbY+GRID_ABS_SIZE(1)+Dy); } EndCompositeCmd(); } else { MoveAllSelObjects(Dx, Dy); PrepareToRecord(CMD_MOVE, topSel, botSel, numObjSelected); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); RedrawAreas(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1)+Dx, selLtY-GRID_ABS_SIZE(1)+Dy, selRbX+GRID_ABS_SIZE(1)+Dx, selRbY+GRID_ABS_SIZE(1)+Dy); } free(sub_cmd); } void MoveAnObj(ObjPtr, TopOwner, Dx, Dy) struct ObjRec *ObjPtr, *TopOwner; int Dx, Dy; /* This function is meant to be called from within an internal command */ { if (execCurDepth <= 0) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "MoveAnObj() called not from an internal command!", NULL); return; #endif /* _TGIF_DBG */ } if (ObjPtr == TopOwner) { struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; int ltx=ObjPtr->bbox.ltx, lty=ObjPtr->bbox.lty; int rbx=ObjPtr->bbox.rbx, rby=ObjPtr->bbox.rby; struct SubCmdRec *sub_cmd=NULL; topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); memset(topSel, 0, sizeof(struct SelRec)); topSel->next = topSel->prev = NULL; topSel->obj = ObjPtr; UpdSelBBox(); sub_cmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (sub_cmd == NULL) FailAllocMessage(); memset(sub_cmd, 0, sizeof(struct SubCmdRec)); sub_cmd->detail.move.dx = Dx; sub_cmd->detail.move.dy = Dy; MoveAllSelObjects(Dx, Dy); PrepareToRecord(CMD_MOVE, topSel, botSel, numObjSelected); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), ltx-GRID_ABS_SIZE(1)+Dx, lty-GRID_ABS_SIZE(1)+Dy, rbx+GRID_ABS_SIZE(1)+Dx, rby+GRID_ABS_SIZE(1)+Dy); free(sub_cmd); free(topSel); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); } else { int ltx=TopOwner->bbox.ltx, lty=TopOwner->bbox.lty; int rbx=TopOwner->bbox.rbx, rby=TopOwner->bbox.rby; PrepareToReplaceAnObj(TopOwner); MoveAttrs(ObjPtr->fattr, Dx, Dy); MoveObj(ObjPtr, Dx, Dy); if (ObjPtr->bbox.ltx < ltx) ltx = ObjPtr->bbox.ltx; if (ObjPtr->bbox.lty < lty) lty = ObjPtr->bbox.lty; if (ObjPtr->bbox.rbx > rbx) rbx = ObjPtr->bbox.rbx; if (ObjPtr->bbox.rby > rby) rby = ObjPtr->bbox.rby; while (ObjPtr != TopOwner) { ObjPtr = ObjPtr->tmp_parent; AdjObjBBox(ObjPtr); if (ObjPtr->bbox.ltx < ltx) ltx = ObjPtr->bbox.ltx; if (ObjPtr->bbox.lty < lty) lty = ObjPtr->bbox.lty; if (ObjPtr->bbox.rbx > rbx) rbx = ObjPtr->bbox.rbx; if (ObjPtr->bbox.rby > rby) rby = ObjPtr->bbox.rby; } RecordReplaceAnObj(TopOwner); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); UpdSelBBox(); } } typedef struct tagRubberRec { struct BBRec obbox; XPoint *sv, *pv; int sn; int radius; /* for rcbox */ XPoint *v; /* for oval, poly or polygon */ int num_pts, curved, intn; /* for oval, poly or polygon */ IntPoint *cntrlv, *polyv; /* for poly or polygon */ char *smooth; /* for poly or polygon */ int ltx, lty, w, h, angle1, angle2, fill; /* for arc */ int saved_xc, saved_yc, saved_x1, saved_y1; /* for arc */ int saved_x2, saved_y2, saved_ltx, saved_lty; /* for arc */ int xc, yc, x1, y1, x2, y2; /* for arc */ } RubberInfo; static void FreeRubberInfo(pInnerObj, pRubberInfo) struct ObjRec *pInnerObj; RubberInfo *pRubberInfo; { switch (pInnerObj->type) { case OBJ_ARC: if (pInnerObj->ctm != NULL) { free(pRubberInfo->sv); free(pRubberInfo->pv); } break; case OBJ_RCBOX: case OBJ_OVAL: if (pInnerObj->ctm != NULL) { free(pRubberInfo->sv); free(pRubberInfo->pv); } break; case OBJ_POLY: case OBJ_POLYGON: if (pRubberInfo->sv != NULL) free(pRubberInfo->sv); if (pRubberInfo->polyv != NULL) free(pRubberInfo->polyv); if (pRubberInfo->smooth != NULL) free(pRubberInfo->smooth); if (pRubberInfo->curved == LT_INTSPLINE && pRubberInfo->cntrlv != NULL) { free(pRubberInfo->cntrlv); } break; } } static void SetRubberInfo(pInnerObj, pRubberInfo) struct ObjRec *pInnerObj; RubberInfo *pRubberInfo; { int i=0, n=0; IntPoint *vs=NULL; char *smooth=NULL; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; switch (pInnerObj->type) { case OBJ_BOX: case OBJ_XBM: case OBJ_XPM: case OBJ_TEXT: if (pInnerObj->ctm == NULL) { pRubberInfo->obbox.ltx = OFFSET_X(pInnerObj->obbox.ltx); pRubberInfo->obbox.lty = OFFSET_Y(pInnerObj->obbox.lty); pRubberInfo->obbox.rbx = OFFSET_X(pInnerObj->obbox.rbx); pRubberInfo->obbox.rby = OFFSET_Y(pInnerObj->obbox.rby); } else { /* no need to do anything here, everything is computed */ } break; case OBJ_RCBOX: if (pInnerObj->ctm == NULL) { pRubberInfo->obbox.ltx = OFFSET_X(pInnerObj->obbox.ltx); pRubberInfo->obbox.lty = OFFSET_Y(pInnerObj->obbox.lty); pRubberInfo->obbox.rbx = OFFSET_X(pInnerObj->obbox.rbx); pRubberInfo->obbox.rby = OFFSET_Y(pInnerObj->obbox.rby); pRubberInfo->radius = pInnerObj->detail.rcb->radius; } else { pRubberInfo->sn = pInnerObj->detail.rcb->rotated_n; pRubberInfo->sv = (XPoint*)malloc(pRubberInfo->sn*sizeof(XPoint)); pRubberInfo->pv = (XPoint*)malloc(pRubberInfo->sn*sizeof(XPoint)); if (pRubberInfo->sv == NULL || pRubberInfo->pv == NULL) { FailAllocMessage(); } for (i=0; i < pRubberInfo->sn; i++) { pRubberInfo->pv[i].x = pInnerObj->detail.rcb->rotated_vlist[i].x; pRubberInfo->pv[i].y = pInnerObj->detail.rcb->rotated_vlist[i].y; } } break; case OBJ_ARC: if (pInnerObj->ctm == NULL) { struct ObjRec *arc_obj_ptr=DupObj(pInnerObj); struct ArcRec *arc_ptr=arc_obj_ptr->detail.a; pRubberInfo->fill = arc_ptr->fill; pRubberInfo->ltx = OFFSET_X(arc_ptr->ltx); pRubberInfo->lty = OFFSET_Y(arc_ptr->lty); pRubberInfo->w = OFFSET_X(arc_ptr->ltx+arc_ptr->w)-pRubberInfo->ltx; pRubberInfo->h = OFFSET_Y(arc_ptr->lty+arc_ptr->h)-pRubberInfo->lty; pRubberInfo->angle1 = arc_ptr->angle1; pRubberInfo->angle2 = arc_ptr->angle2; pRubberInfo->xc = OFFSET_X(arc_ptr->xc); pRubberInfo->yc = OFFSET_Y(arc_ptr->yc); pRubberInfo->x1 = OFFSET_X(arc_ptr->x1); pRubberInfo->y1 = OFFSET_Y(arc_ptr->y1); ArcRealX2Y2(arc_ptr, &pRubberInfo->x2, &pRubberInfo->y2); pRubberInfo->x2 = OFFSET_X(pRubberInfo->x2); pRubberInfo->y2 = OFFSET_Y(pRubberInfo->y2); pRubberInfo->saved_xc = pRubberInfo->xc; pRubberInfo->saved_yc = pRubberInfo->yc; pRubberInfo->saved_x1 = pRubberInfo->x1; pRubberInfo->saved_y1 = pRubberInfo->y1; pRubberInfo->saved_x2 = pRubberInfo->x2; pRubberInfo->saved_y2 = pRubberInfo->y2; pRubberInfo->saved_ltx = pRubberInfo->ltx; pRubberInfo->saved_lty = pRubberInfo->lty; FreeArcObj(arc_obj_ptr); } else { pRubberInfo->sn = pInnerObj->detail.a->rotated_n; pRubberInfo->sv = (XPoint*)malloc((pRubberInfo->sn+2)*sizeof(XPoint)); pRubberInfo->pv = (XPoint*)malloc((pRubberInfo->sn+2)*sizeof(XPoint)); if (pRubberInfo->sv == NULL || pRubberInfo->pv == NULL) { FailAllocMessage(); } for (i=0; i < pRubberInfo->sn+2; i++) { pRubberInfo->pv[i].x = pInnerObj->detail.a->rotated_vlist[i].x; pRubberInfo->pv[i].y = pInnerObj->detail.a->rotated_vlist[i].y; } } break; case OBJ_OVAL: if (pInnerObj->ctm == NULL) { pRubberInfo->num_pts = 13; pRubberInfo->obbox.ltx = OFFSET_X(pInnerObj->obbox.ltx); pRubberInfo->obbox.lty = OFFSET_Y(pInnerObj->obbox.lty); pRubberInfo->obbox.rbx = OFFSET_X(pInnerObj->obbox.rbx); pRubberInfo->obbox.rby = OFFSET_Y(pInnerObj->obbox.rby); } else { pRubberInfo->sn = pInnerObj->detail.o->rotated_n; pRubberInfo->sv = (XPoint*)malloc(pRubberInfo->sn*sizeof(XPoint)); pRubberInfo->pv = (XPoint*)malloc(pRubberInfo->sn*sizeof(XPoint)); if (pRubberInfo->sv == NULL || pRubberInfo->pv == NULL) { FailAllocMessage(); } for (i=0; i < pRubberInfo->sn; i++) { pRubberInfo->pv[i].x = pInnerObj->detail.o->rotated_vlist[i].x; pRubberInfo->pv[i].y = pInnerObj->detail.o->rotated_vlist[i].y; } } break; case OBJ_POLY: poly_ptr = pInnerObj->detail.p; pRubberInfo->curved = poly_ptr->curved; if (pRubberInfo->curved == LT_STRUCT_SPLINE) { n = poly_ptr->ssn; vs = poly_ptr->ssvlist; smooth = poly_ptr->ssmooth; } else { n = poly_ptr->n; vs = poly_ptr->vlist; smooth = poly_ptr->smooth; } pRubberInfo->num_pts = n; pRubberInfo->polyv = (IntPoint*)malloc((pRubberInfo->num_pts+1)*sizeof(IntPoint)); if (pRubberInfo->polyv == NULL) FailAllocMessage(); if (pRubberInfo->curved != LT_INTSPLINE && smooth != NULL) { pRubberInfo->smooth = (char*)malloc((n+1)*sizeof(char)); if (pRubberInfo->smooth == NULL) FailAllocMessage(); } if (pInnerObj->ctm == NULL) { for (i=0; i < pRubberInfo->num_pts; i++) { pRubberInfo->polyv[i].x = vs[i].x; pRubberInfo->polyv[i].y = vs[i].y; if (pRubberInfo->smooth != NULL) { pRubberInfo->smooth[i] = smooth[i]; } } } else { for (i=0; i < pRubberInfo->num_pts; i++) { int x=0, y=0; TransformPointThroughCTM(vs[i].x-pInnerObj->x, vs[i].y-pInnerObj->y, pInnerObj->ctm, &x, &y); pRubberInfo->polyv[i].x = x+pInnerObj->x; pRubberInfo->polyv[i].y = y+pInnerObj->y; if (pRubberInfo->smooth != NULL) { pRubberInfo->smooth[i] = smooth[i]; } } } if (pRubberInfo->curved != LT_INTSPLINE) { pRubberInfo->sv = MakeMultiSplinePolyVertex(pRubberInfo->curved, &pRubberInfo->sn, pRubberInfo->smooth, drawOrigX, drawOrigY, pRubberInfo->num_pts, pRubberInfo->polyv); } else { pRubberInfo->sv = MakeIntSplinePolyVertex(&pRubberInfo->sn, &pRubberInfo->intn, &pRubberInfo->cntrlv, drawOrigX, drawOrigY, pRubberInfo->num_pts, pRubberInfo->polyv); } break; case OBJ_POLYGON: polygon_ptr = pInnerObj->detail.g; pRubberInfo->curved = polygon_ptr->curved; if (pRubberInfo->curved == LT_STRUCT_SPLINE) { n = polygon_ptr->ssn; vs = polygon_ptr->ssvlist; smooth = polygon_ptr->ssmooth; } else { n = polygon_ptr->n; vs = polygon_ptr->vlist; smooth = polygon_ptr->smooth; } pRubberInfo->num_pts = n; pRubberInfo->polyv = (IntPoint*)malloc((pRubberInfo->num_pts+1)*sizeof(IntPoint)); if (pRubberInfo->polyv == NULL) FailAllocMessage(); if (pRubberInfo->curved != LT_INTSPLINE && smooth != NULL) { pRubberInfo->smooth = (char*)malloc((pRubberInfo->num_pts+1)*sizeof(char)); if (pRubberInfo->smooth == NULL) FailAllocMessage(); } if (pInnerObj->ctm == NULL) { for (i=0; i < pRubberInfo->num_pts; i++) { pRubberInfo->polyv[i].x = vs[i].x; pRubberInfo->polyv[i].y = vs[i].y; if (pRubberInfo->smooth != NULL) { pRubberInfo->smooth[i] = smooth[i]; } } } else { for (i=0; i < pRubberInfo->num_pts; i++) { int x=0, y=0; TransformPointThroughCTM(vs[i].x-pInnerObj->x, vs[i].y-pInnerObj->y, pInnerObj->ctm, &x, &y); pRubberInfo->polyv[i].x = x+pInnerObj->x; pRubberInfo->polyv[i].y = y+pInnerObj->y; if (pRubberInfo->smooth != NULL) { pRubberInfo->smooth[i] = smooth[i]; } } } if (pRubberInfo->curved != LT_INTSPLINE) { pRubberInfo->sv = MakeMultiSplinePolygonVertex(pRubberInfo->curved, &pRubberInfo->sn, pRubberInfo->smooth, drawOrigX, drawOrigY, pRubberInfo->num_pts, pRubberInfo->polyv); } else { pRubberInfo->sv = MakeIntSplinePolygonVertex(&pRubberInfo->sn, &pRubberInfo->intn, &pRubberInfo->cntrlv, drawOrigX, drawOrigY, pRubberInfo->num_pts, pRubberInfo->polyv); } break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: pRubberInfo->obbox.ltx = OFFSET_X(pInnerObj->obbox.ltx); pRubberInfo->obbox.lty = OFFSET_Y(pInnerObj->obbox.lty); pRubberInfo->obbox.rbx = OFFSET_X(pInnerObj->obbox.rbx); pRubberInfo->obbox.rby = OFFSET_Y(pInnerObj->obbox.rby); break; } } static void DrawInnerRubberObj(pInnerObj, pRubberInfo, dx, dy) struct ObjRec *pInnerObj; RubberInfo *pRubberInfo; int dx, dy; { int i=0; switch (pInnerObj->type) { case OBJ_BOX: case OBJ_XBM: case OBJ_XPM: case OBJ_TEXT: if (pInnerObj->ctm == NULL) { SelBox(drawWindow, revDefaultGC, pRubberInfo->obbox.ltx+dx, pRubberInfo->obbox.lty+dy, pRubberInfo->obbox.rbx+dx, pRubberInfo->obbox.rby+dy); } else { XPoint obj_obbox_vs[5]; for (i=0; i < 5; i++) { obj_obbox_vs[i].x = pInnerObj->rotated_obbox[i].x+dx; obj_obbox_vs[i].y = pInnerObj->rotated_obbox[i].y+dy; } XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_obbox_vs, 5, CoordModeOrigin); } break; case OBJ_RCBOX: if (pInnerObj->ctm == NULL) { SetRCBoxVertex( pRubberInfo->obbox.ltx+dx, pRubberInfo->obbox.lty+dy, pRubberInfo->obbox.rbx+dx, pRubberInfo->obbox.rby+dy, pRubberInfo->radius); MyRCBox(drawWindow, revDefaultGC, pRubberInfo->obbox.ltx, pRubberInfo->obbox.lty, pRubberInfo->obbox.rbx, pRubberInfo->obbox.rby, pRubberInfo->radius); } else { for (i=0; i < pRubberInfo->sn; i++) { pRubberInfo->sv[i].x = pRubberInfo->pv[i].x + dx; pRubberInfo->sv[i].y = pRubberInfo->pv[i].y + dy; } XDrawLines(mainDisplay, drawWindow, revDefaultGC, pRubberInfo->sv, pRubberInfo->sn, CoordModeOrigin); } break; case OBJ_ARC: if (pInnerObj->ctm == NULL) { if (!(pRubberInfo->fill == NONEPAT || (pInnerObj->trans_pat && pRubberInfo->fill == BACKPAT))) { XDrawLine(mainDisplay, drawWindow, revDefaultGC, pRubberInfo->xc, pRubberInfo->yc, pRubberInfo->x1, pRubberInfo->y1); XDrawLine(mainDisplay, drawWindow, revDefaultGC, pRubberInfo->xc, pRubberInfo->yc, pRubberInfo->x2, pRubberInfo->y2); } XDrawArc(mainDisplay, drawWindow, revDefaultGC, pRubberInfo->ltx, pRubberInfo->lty, pRubberInfo->w, pRubberInfo->h, pRubberInfo->angle1, pRubberInfo->angle2); } else { for (i=0; i < pRubberInfo->sn+2; i++) { pRubberInfo->sv[i].x = pRubberInfo->pv[i].x + dx; pRubberInfo->sv[i].y = pRubberInfo->pv[i].y + dy; } if (!(pRubberInfo->fill == NONEPAT || (pInnerObj->trans_pat && pRubberInfo->fill == BACKPAT))) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, pRubberInfo->sv, pRubberInfo->sn+2, CoordModeOrigin); } else { XDrawLines(mainDisplay, drawWindow, revDefaultGC, pRubberInfo->sv, pRubberInfo->sn, CoordModeOrigin); } } break; case OBJ_OVAL: if (pInnerObj->ctm == NULL) { struct BBRec o_bbox; o_bbox.ltx = pRubberInfo->obbox.ltx+dx; o_bbox.lty = pRubberInfo->obbox.lty+dy; o_bbox.rbx = pRubberInfo->obbox.rbx+dx; o_bbox.rby = pRubberInfo->obbox.rby+dy; MyOval(drawWindow, revDefaultGC, o_bbox); } else { for (i=0; i < pRubberInfo->sn; i++) { pRubberInfo->sv[i].x = pRubberInfo->pv[i].x + dx; pRubberInfo->sv[i].y = pRubberInfo->pv[i].y + dy; } XDrawLines(mainDisplay, drawWindow, revDefaultGC, pRubberInfo->sv, pRubberInfo->sn, CoordModeOrigin); } break; case OBJ_POLY: case OBJ_POLYGON: XDrawLines(mainDisplay, drawWindow, revDefaultGC, pRubberInfo->sv, pRubberInfo->sn, CoordModeOrigin); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: SelBox(drawWindow, revDefaultGC, pRubberInfo->obbox.ltx+dx, pRubberInfo->obbox.lty+dy, pRubberInfo->obbox.rbx+dx, pRubberInfo->obbox.rby+dy); break; } } static void UpdateInnerRubberObj(pInnerObj, pRubberInfo, dx, dy) struct ObjRec *pInnerObj; RubberInfo *pRubberInfo; int dx, dy; { int i=0, n=0; IntPoint *vs=NULL; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; switch (pInnerObj->type) { case OBJ_ARC: if (pInnerObj->ctm == NULL) { pRubberInfo->xc = pRubberInfo->saved_xc+dx; pRubberInfo->yc = pRubberInfo->saved_yc+dy; pRubberInfo->x1 = pRubberInfo->saved_x1+dx; pRubberInfo->y1 = pRubberInfo->saved_y1+dy; pRubberInfo->x2 = pRubberInfo->saved_x2+dx; pRubberInfo->y2 = pRubberInfo->saved_y2+dy; pRubberInfo->ltx = pRubberInfo->saved_ltx+dx; pRubberInfo->lty = pRubberInfo->saved_lty+dy; } break; case OBJ_POLY: case OBJ_POLYGON: if (pRubberInfo->sv != NULL) { free(pRubberInfo->sv); pRubberInfo->sv = NULL; } switch (pInnerObj->type) { case OBJ_POLY: poly_ptr = pInnerObj->detail.p; if (poly_ptr->curved == LT_STRUCT_SPLINE) { n = poly_ptr->ssn; vs = poly_ptr->ssvlist; } else { n = poly_ptr->n; vs = poly_ptr->vlist; } if (pInnerObj->ctm == NULL) { for (i=0; i < pRubberInfo->num_pts; i++) { pRubberInfo->polyv[i].x = vs[i].x+ABS_SIZE(dx); pRubberInfo->polyv[i].y = vs[i].y+ABS_SIZE(dy); } } else { for (i=0; i < pRubberInfo->num_pts; i++) { int x=0, y=0; TransformPointThroughCTM(vs[i].x-pInnerObj->x, vs[i].y-pInnerObj->y, pInnerObj->ctm, &x, &y); pRubberInfo->polyv[i].x = x+pInnerObj->x+ABS_SIZE(dx); pRubberInfo->polyv[i].y = y+pInnerObj->y+ABS_SIZE(dy); } } if (pRubberInfo->curved != LT_INTSPLINE) { pRubberInfo->sv = MakeMultiSplinePolyVertex(pRubberInfo->curved, &pRubberInfo->sn, pRubberInfo->smooth, drawOrigX, drawOrigY, pRubberInfo->num_pts, pRubberInfo->polyv); } else { free(pRubberInfo->cntrlv); pRubberInfo->sv = MakeIntSplinePolyVertex(&pRubberInfo->sn, &pRubberInfo->intn, &pRubberInfo->cntrlv, drawOrigX, drawOrigY, pRubberInfo->num_pts, pRubberInfo->polyv); } break; case OBJ_POLYGON: polygon_ptr = pInnerObj->detail.g; if (polygon_ptr->curved == LT_STRUCT_SPLINE) { n = polygon_ptr->ssn; vs = polygon_ptr->ssvlist; } else { n = polygon_ptr->n; vs = polygon_ptr->vlist; } if (pInnerObj->ctm == NULL) { for (i=0; i < pRubberInfo->num_pts; i++) { pRubberInfo->polyv[i].x = vs[i].x+ABS_SIZE(dx); pRubberInfo->polyv[i].y = vs[i].y+ABS_SIZE(dy); } } else { for (i=0; i < pRubberInfo->num_pts; i++) { int x=0, y=0; TransformPointThroughCTM(vs[i].x-pInnerObj->x, vs[i].y-pInnerObj->y, pInnerObj->ctm, &x, &y); pRubberInfo->polyv[i].x = x+pInnerObj->x+ABS_SIZE(dx); pRubberInfo->polyv[i].y = y+pInnerObj->y+ABS_SIZE(dy); } } if (pRubberInfo->curved != LT_INTSPLINE) { pRubberInfo->sv = MakeMultiSplinePolygonVertex(pRubberInfo->curved, &pRubberInfo->sn, pRubberInfo->smooth, drawOrigX, drawOrigY, pRubberInfo->num_pts, pRubberInfo->polyv); } else { free(pRubberInfo->cntrlv); pRubberInfo->sv = MakeIntSplinePolygonVertex(&pRubberInfo->sn, &pRubberInfo->intn, &pRubberInfo->cntrlv, drawOrigX, drawOrigY, pRubberInfo->num_pts, pRubberInfo->polyv); } break; } break; } } static void MoveSubObjEventCheck(ev, pn_move_sub_obj) XEvent *ev; int *pn_move_sub_obj; { if (ev->type == MotionNotify) { *pn_move_sub_obj = (ev->xmotion.state & ControlMask) && (!(ev->xmotion.state & ShiftMask)); } else if (ev->type == KeyPress || ev->type == KeyRelease) { char s[80]; KeySym key_sym; XLookupString(&(ev->xkey), s, sizeof(s), &key_sym, NULL); if (key_sym == XK_Control_L || key_sym == XK_Control_R) { *pn_move_sub_obj = (ev->type == KeyPress); } } } void MoveAnAttr(attr_ptr, attr_owner_obj, dx, dy) struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj; int dx, dy; { struct ObjRec *text_obj_ptr=attr_ptr->obj; int ltx, lty, rbx, rby; if (attr_owner_obj == NULL) { attr_owner_obj = GetTopOwner(attr_ptr->owner); } ltx = attr_owner_obj->bbox.ltx; lty = attr_owner_obj->bbox.lty; rbx = attr_owner_obj->bbox.rbx; rby = attr_owner_obj->bbox.rby; PrepareToReplaceAnObj(attr_owner_obj); MoveObj(text_obj_ptr, dx, dy); RecursivelyAdjObjBBox(attr_ptr->owner, attr_ptr->owner, attr_owner_obj); RecordReplaceAnObj(attr_owner_obj); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), attr_owner_obj->bbox.ltx-GRID_ABS_SIZE(1), attr_owner_obj->bbox.lty-GRID_ABS_SIZE(1), attr_owner_obj->bbox.rbx+GRID_ABS_SIZE(1), attr_owner_obj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } void MoveSel(OrigX, OrigY, ObjPtr, down_button_ev) int OrigX, OrigY; struct ObjRec *ObjPtr; XButtonEvent *down_button_ev; { int sel_ltx=0, sel_lty=0, sel_rbx=0, sel_rby=0; int ruler_ltx=0, ruler_lty=0, ruler_rbx=0, ruler_rby=0; int moving=TRUE, dx=0, dy=0, grid_x=OrigX, grid_y=OrigY; int can_move_sub_obj=FALSE, move_sub_obj=FALSE, no_no_lock_sel=FALSE; char buf[80], x_buf[80], y_buf[80]; XEvent ev; Time down_click_time=(Time)0; RubberInfo rubber_info; if (down_button_ev != NULL) { down_click_time = down_button_ev->time; } if (numObjSelected == numObjLocked || ObjPtr->locked) { no_no_lock_sel = TRUE; } XFlush(mainDisplay); XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } if (ObjPtr->type == OBJ_TEXT && ObjPtr->detail.t->attr != NULL) { can_move_sub_obj = TRUE; SetStringStatus(TgLoadString(STID_HINT_CTL_MOVE_ATTR_ONLY)); } if (!move_sub_obj && !no_no_lock_sel) { sel_ltx = OFFSET_X(selNoLockLtX)-1; sel_lty = OFFSET_Y(selNoLockLtY)-1; sel_rbx = OFFSET_X(selNoLockRbX)+1; sel_rby = OFFSET_Y(selNoLockRbY)+1; } ruler_ltx = OFFSET_X(selNoLockObjLtX); ruler_lty = OFFSET_Y(selNoLockObjLtY); ruler_rbx = OFFSET_X(selNoLockObjRbX); ruler_rby = OFFSET_Y(selNoLockObjRbY); if (!move_sub_obj && !no_no_lock_sel) { SelBox(drawWindow, revDefaultGC, sel_ltx, sel_lty, sel_rbx, sel_rby); } PixelToMeasurementUnit(x_buf, 0); PixelToMeasurementUnit(y_buf, 0); if (VerboseMeasureTooltip()) { sprintf(buf, "dx=%s dy=%s", x_buf, y_buf); } else { sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); } StartShowMeasureCursor(OrigX, OrigY, buf, TRUE); BeginIntervalRulers(ruler_ltx, ruler_lty, ruler_rbx, ruler_rby); memset(&rubber_info, 0, sizeof(RubberInfo)); SetRubberInfo(ObjPtr, &rubber_info); DrawInnerRubberObj(ObjPtr, &rubber_info, 0, 0); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, moveCursor, CurrentTime); } dx = dy = 0; while (moving) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { Time release_time=input.xbutton.time; XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); moving = FALSE; EndIntervalRulers(grid_x, grid_y); PixelToMeasurementUnit(x_buf, ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, ABS_SIZE(dy)); if (VerboseMeasureTooltip()) { sprintf(buf, "dx=%s dy=%s", x_buf, y_buf); } else { sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); } EndShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (!move_sub_obj && !no_no_lock_sel) { SelBox(drawWindow, revDefaultGC, sel_ltx+dx, sel_lty+dy, sel_rbx+dx, sel_rby+dy); } DrawInnerRubberObj(ObjPtr, &rubber_info, dx, dy); dx = grid_x - OrigX; dy = grid_y - OrigY; if (oneMotionSelectMove && down_button_ev != NULL && (release_time-down_click_time) < oneMotionTimeout) { dx = dy = 0; } else if (!oneMotionSelectMove && down_button_ev != NULL && (release_time-down_click_time) < minMoveInterval) { dx = dy = 0; } } else if (input.type == MotionNotify || input.type == KeyPress || input.type == KeyRelease) { int x=0, y=0, saved_move_sub_obj=move_sub_obj; PixelToMeasurementUnit(x_buf, ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, ABS_SIZE(dy)); if (VerboseMeasureTooltip()) { sprintf(buf, "dx=%s dy=%s", x_buf, y_buf); } else { sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); } ShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (input.type == KeyPress || input.type == KeyRelease) { x = grid_x; y = grid_y; } else { x = input.xmotion.x; y = input.xmotion.y; } if (shiftForDiagMouseMove && DiagEventCheck(&input)) { if (useRecentDupDistance && justDupped && useRecentForDiagMouseMove) { DiagGridXY(OrigX-ZOOMED_SIZE(dupDx), OrigY-ZOOMED_SIZE(dupDy), &x, &y); } else { DiagGridXY(OrigX, OrigY, &x, &y); } } else if (can_move_sub_obj) { MoveSubObjEventCheck(&input, &move_sub_obj); } GridXY(x, y, &grid_x, &grid_y); /* erase */ DrawInnerRubberObj(ObjPtr, &rubber_info, dx, dy); if (!saved_move_sub_obj && !no_no_lock_sel) { SelBox(drawWindow, revDefaultGC, sel_ltx+dx, sel_lty+dy, sel_rbx+dx, sel_rby+dy); } dx = grid_x - OrigX; dy = grid_y - OrigY; if ((dx != 0 || dy != 0) && (numObjSelected == numObjLocked || ObjPtr->locked)) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); EndIntervalRulers(grid_x, grid_y); PixelToMeasurementUnit(x_buf, ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, ABS_SIZE(dy)); if (VerboseMeasureTooltip()) { sprintf(buf, "dx=%s dy=%s", x_buf, y_buf); } else { sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); } ShowMeasureCursor(grid_x, grid_y, buf, TRUE); EndShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (!move_sub_obj && !no_no_lock_sel) { SelBox(drawWindow, revDefaultGC, sel_ltx+dx, sel_lty+dy, sel_rbx+dx, sel_rby+dy); } MsgBox(TgLoadString(STID_LOCKED_OBJS_CANT_BE_MOVED), TOOL_NAME, INFO_MB); return; } PixelToMeasurementUnit(x_buf, ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, ABS_SIZE(dy)); if (VerboseMeasureTooltip()) { sprintf(buf, "dx=%s dy=%s", x_buf, y_buf); } else { sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); } DrawIntervalRulers(ruler_ltx+dx, ruler_lty+dy, ruler_rbx+dx, ruler_rby+dy, buf); if (!move_sub_obj && !no_no_lock_sel) { SelBox(drawWindow, revDefaultGC, sel_ltx+dx, sel_lty+dy, sel_rbx+dx, sel_rby+dy); } ShowMeasureCursor(grid_x, grid_y, buf, TRUE); UpdateInnerRubberObj(ObjPtr, &rubber_info, dx, dy); DrawInnerRubberObj(ObjPtr, &rubber_info, dx, dy); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } FreeRubberInfo(ObjPtr, &rubber_info); if (dx != 0 || dy != 0) { if (numObjSelected == numObjLocked || ObjPtr->locked) { MsgBox(TgLoadString(STID_LOCKED_OBJS_CANT_BE_MOVED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); dx = ABS_SIZE(dx); dy = ABS_SIZE(dy); if (numObjSelected == numObjLocked) { HighLightForward(); return; } if (can_move_sub_obj && move_sub_obj) { MoveAnAttr(ObjPtr->detail.t->attr, NULL, dx, dy); } else { MoveAllSel(dx, dy); } HighLightForward(); UpdSelBBox(); if (justDupped) { dupDx += dx; dupDy += dy; } SetFileModified(TRUE); } if (can_move_sub_obj) { ShowCurChoiceMouseStatus(curChoice, 0, FALSE); } } static int IsSmoothForStructuredSpline(vlist_index, n, vlist) int vlist_index, n; IntPoint *vlist; { int i=0, j=0, num_hinge_vs=(n+2)/3; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert((n+2)%3 == 0, "invalid n in IsSmoothForStructuredSpline()", NULL); #endif /* _TGIF_DBG */ for (i=0, j=0; i < num_hinge_vs; i++, j+=3) { if (vlist_index > j+1) continue; if (i == 0) { if (vlist_index == j) { return FALSE; } return (vlist[0].x != vlist[1].x || vlist[0].y != vlist[1].y); } else if (i == num_hinge_vs-1) { if (vlist_index == j) { return FALSE; } return (vlist[n-1].x != vlist[n-2].x || vlist[n-1].y != vlist[n-2].y); } else { if (vlist_index == j) { return FALSE; } return (vlist[j-1].x != vlist[j].x || vlist[j-1].y != vlist[j].y); } } return FALSE; } void FinishMoveVertexForStretchStructSpline(vsel_ptr, abs_dx, abs_dy, psssi) struct VSelRec *vsel_ptr; int abs_dx, abs_dy; StretchStructuredSplineInfo *psssi; { struct ObjRec *obj_ptr=NULL; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; int was_smooth_point=(!psssi->hinge), vlist_index=0; obj_ptr = vsel_ptr->obj; switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; break; } if (was_smooth_point) { vlist_index = GetVlistIndexFromStretchStructuredSplineInfo(psssi, vsel_ptr->v_index[0]); } if (poly_ptr != NULL) { UpdateObjForStretchStructSpline(obj_ptr, poly_ptr->n, poly_ptr->vlist, abs_dx, abs_dy, psssi); if (was_smooth_point && !IsSmoothForStructuredSpline(vlist_index, poly_ptr->n, poly_ptr->vlist)) { if (!psssi->prev_valid) { /* first poly point */ vsel_ptr->v_index[0] -= 1; } else if (!psssi->next_valid) { /* last poly point */ /* merge with next point, so don't need to do anything */ } else { if (!psssi->earlier_smooth_selected) { vsel_ptr->v_index[0] -= 2; } else { /* merge with next point, so don't need to do anything */ } } SetIPTInfoForStretchPoly(vsel_ptr->v_index[0], poly_ptr->n, poly_ptr->vlist, psssi); } } else if (polygon_ptr != NULL) { UpdateObjForStretchStructSpline(obj_ptr, polygon_ptr->n, polygon_ptr->vlist, abs_dx, abs_dy, psssi); if (was_smooth_point && !IsSmoothForStructuredSpline(vlist_index, polygon_ptr->n, polygon_ptr->vlist)) { if (psssi->orig_hinge_index == 0 || psssi->orig_hinge_index == polygon_ptr->n-1) { vsel_ptr->v_index[0] = 0; } else if (!psssi->earlier_smooth_selected) { if (vsel_ptr->v_index[0] == 1) { vsel_ptr->v_index[0] -= 1; } else { vsel_ptr->v_index[0] -= 2; } } SetIPTInfoForStretchPolygon(vsel_ptr->v_index[0], polygon_ptr->n, polygon_ptr->vlist, psssi); } } } void MoveAllSelVs(abs_dx, abs_dy) int abs_dx, abs_dy; { int i; IntPoint *v=NULL; struct ObjRec *obj_ptr=NULL; struct VSelRec *vsel_ptr=NULL; int n=0, ltx=selLtX, lty=selLtY, rbx=selRbX, rby=selRbY; StartCompositeCmd(); for (vsel_ptr=botVSel; vsel_ptr != NULL; vsel_ptr=vsel_ptr->prev) { int auto_retracted_arrow=FALSE, curved=(-1); struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; StretchStructuredSplineInfo *psssi=NULL; obj_ptr = vsel_ptr->obj; switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; curved = poly_ptr->curved; if (curved == LT_STRUCT_SPLINE) { v = poly_ptr->ssvlist; n = poly_ptr->ssn; psssi = (StretchStructuredSplineInfo*)(obj_ptr->userdata); if (psssi == NULL) { psssi = (StretchStructuredSplineInfo*)malloc( sizeof(StretchStructuredSplineInfo)); if (psssi == NULL) FailAllocMessage(); memset(psssi, 0, sizeof(StretchStructuredSplineInfo)); obj_ptr->userdata = vsel_ptr->obj->userdata = psssi; SetIPTInfoForStretchPoly(vsel_ptr->v_index[0], poly_ptr->n, poly_ptr->vlist, psssi); } } else { v = poly_ptr->vlist; n = poly_ptr->n; } auto_retracted_arrow = AutoRetractedArrowAttr(obj_ptr, TRUE); break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; curved = polygon_ptr->curved; if (curved == LT_STRUCT_SPLINE) { v = polygon_ptr->ssvlist; n = polygon_ptr->ssn; psssi = (StretchStructuredSplineInfo*)(obj_ptr->userdata); if (psssi == NULL) { psssi = (StretchStructuredSplineInfo*)malloc( sizeof(StretchStructuredSplineInfo)); if (psssi == NULL) FailAllocMessage(); memset(psssi, 0, sizeof(StretchStructuredSplineInfo)); obj_ptr->userdata = vsel_ptr->obj->userdata = psssi; SetIPTInfoForStretchPolygon(vsel_ptr->v_index[0], polygon_ptr->n, polygon_ptr->vlist, psssi); } } else { v = polygon_ptr->vlist; n = polygon_ptr->n; } break; } PrepareToReplaceAnObj(obj_ptr); if (obj_ptr->ctm == NULL) { for (i=0; i < vsel_ptr->n; i++) { vsel_ptr->x[i] += abs_dx; vsel_ptr->y[i] += abs_dy; v[vsel_ptr->v_index[i]].x += abs_dx; v[vsel_ptr->v_index[i]].y += abs_dy; } } else { for (i=0; i < vsel_ptr->n; i++) { int x=0, y=0, x2=0, y2=0; /* * vsel_ptr->x[i] += abs_dx; * vsel_ptr->y[i] += abs_dy; */ ReverseTransformPointThroughCTM(vsel_ptr->x[i]+abs_dx-obj_ptr->x, vsel_ptr->y[i]+abs_dy-obj_ptr->y, obj_ptr->ctm, &x, &y); v[vsel_ptr->v_index[i]].x = x + obj_ptr->x; v[vsel_ptr->v_index[i]].y = y + obj_ptr->y; TransformPointThroughCTM(x, y, obj_ptr->ctm, &x2, &y2); vsel_ptr->x[i] = x2 + obj_ptr->x; vsel_ptr->y[i] = y2 + obj_ptr->y; } } if (curved == LT_STRUCT_SPLINE) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(obj_ptr->userdata != NULL, "obj_ptr is NULL in MoveAllSelVs()", NULL); #endif /* _TGIF_DBG */ FinishMoveVertexForStretchStructSpline(vsel_ptr, abs_dx, abs_dy, psssi); free(psssi); obj_ptr->userdata = NULL; } AdjObjSplineVs(obj_ptr); if (auto_retracted_arrow) { for (i=0; i < vsel_ptr->n; i++) { if (vsel_ptr->v_index[i] == 1) { vsel_ptr->x[i] = v[1].x; vsel_ptr->y[i] = v[1].y; } } } switch (obj_ptr->type) { case OBJ_POLY: if (obj_ptr->detail.p->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, n, v); } else { UpdPolyBBox(obj_ptr, obj_ptr->detail.p->intn, obj_ptr->detail.p->intvlist); } break; case OBJ_POLYGON: if (obj_ptr->detail.g->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, n, v); } else { UpdPolyBBox(obj_ptr, obj_ptr->detail.g->intn, obj_ptr->detail.g->intvlist); } break; } RecordReplaceAnObj(obj_ptr); } EndCompositeCmd(); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } static struct ObjRec *tmpTopObj=NULL, *tmpBotObj=NULL; #define FORWARD 0 #define REVERSE 1 static void EndMoveVsForStructuredSpline(obj_ptr, abs_dx, abs_dy) struct ObjRec *obj_ptr; int abs_dx, abs_dy; { StretchStructuredSplineInfo *psssi= (StretchStructuredSplineInfo*)(obj_ptr->userdata); if (psssi != NULL) { if (psssi->sv != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, psssi->sv, psssi->sn, CoordModeOrigin); free(psssi->sv); psssi->sv = NULL; } if (psssi->sv2 != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, psssi->sv2, psssi->sn2, CoordModeOrigin); free(psssi->sv2); psssi->sv2 = NULL; } EraseHighLightForStretchStructSpline(psssi, abs_dx, abs_dy, FALSE, TRUE); } } static void EndMoveVs(abs_dx, abs_dy) int abs_dx, abs_dy; { int i=0; struct ObjRec *obj_ptr=NULL, *next_obj=NULL; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; for (obj_ptr=tmpTopObj; obj_ptr != NULL; obj_ptr = next_obj) { next_obj = obj_ptr->next; switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; if (poly_ptr->vlist != NULL) { free(poly_ptr->vlist); poly_ptr->vlist = NULL; } if (poly_ptr->svlist != NULL) { free(poly_ptr->svlist); poly_ptr->svlist = NULL; } if (poly_ptr->curved == LT_INTSPLINE && poly_ptr->intvlist != NULL) { free(poly_ptr->intvlist); poly_ptr->intvlist = NULL; } else if (poly_ptr->curved == LT_STRUCT_SPLINE) { EndMoveVsForStructuredSpline(obj_ptr, 0, 0); for (i=0; i < poly_ptr->ssn; i++) { if (poly_ptr->ssmooth[i]) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(poly_ptr->ssvlist[i].x), OFFSET_Y(poly_ptr->ssvlist[i].y)); } else { MARKHR(drawWindow, revDefaultGC, OFFSET_X(poly_ptr->ssvlist[i].x), OFFSET_Y(poly_ptr->ssvlist[i].y)); } } } free(poly_ptr); break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; if (polygon_ptr->vlist != NULL) { free(polygon_ptr->vlist); polygon_ptr->vlist = NULL; } if (polygon_ptr->svlist != NULL) { free(polygon_ptr->svlist); polygon_ptr->svlist = NULL; } if (polygon_ptr->curved == LT_INTSPLINE && polygon_ptr->intvlist != NULL) { free(polygon_ptr->intvlist); polygon_ptr->intvlist = NULL; } else if (polygon_ptr->curved == LT_STRUCT_SPLINE) { EndMoveVsForStructuredSpline(obj_ptr, 0, 0); for (i=0; i < polygon_ptr->ssn; i++) { if (polygon_ptr->ssmooth[i]) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(polygon_ptr->ssvlist[i].x), OFFSET_Y(polygon_ptr->ssvlist[i].y)); } else { MARKHR(drawWindow, revDefaultGC, OFFSET_X(polygon_ptr->ssvlist[i].x), OFFSET_Y(polygon_ptr->ssvlist[i].y)); } } } free(polygon_ptr); break; } free(obj_ptr); } } static void PrepareToMoveVs() { struct VSelRec *vsel_ptr=NULL; tmpTopObj = tmpBotObj = NULL; for (vsel_ptr=botVSel; vsel_ptr != NULL; vsel_ptr=vsel_ptr->prev) { struct ObjRec *obj_ptr=NULL; struct PolyRec *poly_ptr=NULL, *poly_copy=NULL; struct PolygonRec *polygon_ptr=NULL, *polygon_copy=NULL; XPoint *sv=NULL; IntPoint *polyv=NULL, *polyssv=NULL, *cntrlv=NULL; int i=0, num_pts=0, sn=0, curved=(-1), intn=0, ssn=0; char *smooth=NULL, *ssmooth=NULL; StretchStructuredSplineInfo *psssi=NULL; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); obj_ptr->prev = NULL; obj_ptr->next = tmpTopObj; obj_ptr->ctm = NULL; if (tmpTopObj == NULL) { tmpBotObj = obj_ptr; } else { tmpTopObj->prev = obj_ptr; } tmpTopObj = obj_ptr; obj_ptr->type = vsel_ptr->obj->type; switch (vsel_ptr->obj->type) { case OBJ_POLY: poly_copy = (struct PolyRec *)malloc(sizeof(struct PolyRec)); if (poly_copy == NULL) FailAllocMessage(); memset(poly_copy, 0, sizeof(struct PolyRec)); obj_ptr->detail.p = poly_copy; poly_ptr = vsel_ptr->obj->detail.p; curved = poly_copy->curved = poly_ptr->curved; num_pts = poly_copy->n = poly_ptr->n; if (curved == LT_STRUCT_SPLINE) { ssn = poly_copy->ssn = poly_ptr->ssn; } polyv = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (polyv == NULL) FailAllocMessage(); if (curved == LT_STRUCT_SPLINE) { polyssv = (IntPoint*)malloc((ssn+2)*sizeof(IntPoint)); if (polyssv == NULL) FailAllocMessage(); } if (curved == LT_STRUCT_SPLINE || ((curved == LT_STRAIGHT || curved == LT_SPLINE) && poly_ptr->smooth != NULL)) { if (poly_ptr->smooth != NULL) { smooth = (char*)malloc((num_pts+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); } if (curved == LT_STRUCT_SPLINE) { ssmooth = (char*)malloc((ssn+2)*sizeof(char)); if (ssmooth == NULL) FailAllocMessage(); } } if (vsel_ptr->obj->ctm == NULL) { for (i=0; i < num_pts; i++) { polyv[i].x = poly_ptr->vlist[i].x; polyv[i].y = poly_ptr->vlist[i].y; if (smooth != NULL) smooth[i] = poly_ptr->smooth[i]; } if (curved == LT_STRUCT_SPLINE) { for (i=0; i < ssn; i++) { polyssv[i].x = poly_ptr->ssvlist[i].x; polyssv[i].y = poly_ptr->ssvlist[i].y; if (ssmooth != NULL) ssmooth[i] = poly_ptr->ssmooth[i]; } } } else { int x, y; for (i=0; i < num_pts; i++) { TransformPointThroughCTM( poly_ptr->vlist[i].x-vsel_ptr->obj->x, poly_ptr->vlist[i].y-vsel_ptr->obj->y, vsel_ptr->obj->ctm, &x, &y); polyv[i].x = x+vsel_ptr->obj->x; polyv[i].y = y+vsel_ptr->obj->y; if (smooth != NULL) smooth[i] = poly_ptr->smooth[i]; } if (curved == LT_STRUCT_SPLINE) { for (i=0; i < ssn; i++) { TransformPointThroughCTM( poly_ptr->ssvlist[i].x-vsel_ptr->obj->x, poly_ptr->ssvlist[i].y-vsel_ptr->obj->y, vsel_ptr->obj->ctm, &x, &y); polyssv[i].x = x+vsel_ptr->obj->x; polyssv[i].y = y+vsel_ptr->obj->y; if (ssmooth != NULL) ssmooth[i] = poly_ptr->ssmooth[i]; } } } if (curved != LT_INTSPLINE) { if (curved == LT_STRUCT_SPLINE) { sv = MakeMultiSplinePolyVertex(curved, &sn, ssmooth, drawOrigX, drawOrigY, ssn, polyssv); poly_copy->ssvlist = polyssv; poly_copy->ssmooth = ssmooth; poly_copy->ssn = ssn; } else { sv = MakeMultiSplinePolyVertex(curved, &sn, smooth, drawOrigX, drawOrigY, num_pts, polyv); } } else { sv = MakeIntSplinePolyVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, num_pts, polyv); } poly_copy->vlist = polyv; poly_copy->smooth = smooth; poly_copy->svlist = sv; poly_copy->sn = sn; if (curved == LT_STRUCT_SPLINE) { for (i=0; i < ssn; i++) { if (ssmooth[i]) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(polyssv[i].x), OFFSET_Y(polyssv[i].y)); } else { MARKHR(drawWindow, revDefaultGC, OFFSET_X(polyssv[i].x), OFFSET_Y(polyssv[i].y)); } } } break; case OBJ_POLYGON: polygon_copy = (struct PolygonRec *)malloc(sizeof(struct PolygonRec)); if (polygon_copy == NULL) FailAllocMessage(); memset(polygon_copy, 0, sizeof(struct PolygonRec)); obj_ptr->detail.g = polygon_copy; polygon_ptr = vsel_ptr->obj->detail.g; curved = polygon_copy->curved = polygon_ptr->curved; num_pts = polygon_copy->n = polygon_ptr->n; if (curved == LT_STRUCT_SPLINE) { ssn = polygon_copy->ssn = polygon_ptr->ssn; } polyv = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (polyv == NULL) FailAllocMessage(); if (curved == LT_STRUCT_SPLINE) { polyssv = (IntPoint*)malloc((ssn+2)*sizeof(IntPoint)); if (polyssv == NULL) FailAllocMessage(); } if (curved == LT_STRUCT_SPLINE || ((curved == LT_STRAIGHT || curved == LT_SPLINE) && polygon_ptr->smooth != NULL)) { if (polygon_ptr->smooth != NULL) { smooth = (char*)malloc((num_pts+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); } if (curved == LT_STRUCT_SPLINE) { ssmooth = (char*)malloc((ssn+1)*sizeof(char)); if (ssmooth == NULL) FailAllocMessage(); } } if (vsel_ptr->obj->ctm == NULL) { for (i=0; i < num_pts; i++) { polyv[i].x = polygon_ptr->vlist[i].x; polyv[i].y = polygon_ptr->vlist[i].y; if (smooth != NULL) smooth[i] = polygon_ptr->smooth[i]; } if (curved == LT_STRUCT_SPLINE) { for (i=0; i < ssn; i++) { polyssv[i].x = polygon_ptr->ssvlist[i].x; polyssv[i].y = polygon_ptr->ssvlist[i].y; if (ssmooth != NULL) ssmooth[i] = polygon_ptr->ssmooth[i]; } } } else { int x, y; for (i=0; i < num_pts; i++) { TransformPointThroughCTM( polygon_ptr->vlist[i].x-vsel_ptr->obj->x, polygon_ptr->vlist[i].y-vsel_ptr->obj->y, vsel_ptr->obj->ctm, &x, &y); polyv[i].x = x+vsel_ptr->obj->x; polyv[i].y = y+vsel_ptr->obj->y; if (smooth != NULL) smooth[i] = polygon_ptr->smooth[i]; } if (curved == LT_STRUCT_SPLINE) { for (i=0; i < num_pts; i++) { TransformPointThroughCTM( polygon_ptr->ssvlist[i].x-vsel_ptr->obj->x, polygon_ptr->ssvlist[i].y-vsel_ptr->obj->y, vsel_ptr->obj->ctm, &x, &y); polyssv[i].x = x+vsel_ptr->obj->x; polyssv[i].y = y+vsel_ptr->obj->y; if (ssmooth != NULL) ssmooth[i] = polygon_ptr->ssmooth[i]; } } } if (curved != LT_INTSPLINE) { if (curved == LT_STRUCT_SPLINE) { sv = MakeMultiSplinePolygonVertex(curved, &sn, ssmooth, drawOrigX, drawOrigY, ssn, polyssv); polygon_copy->ssvlist = polyssv; polygon_copy->ssmooth = ssmooth; polygon_copy->ssn = ssn; } else { sv = MakeMultiSplinePolygonVertex(curved, &sn, smooth, drawOrigX, drawOrigY, num_pts,polyv); } } else { sv = MakeIntSplinePolygonVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, num_pts,polyv); } polygon_copy->vlist = polyv; polygon_copy->smooth = smooth; polygon_copy->svlist = sv; polygon_copy->sn = sn; if (curved == LT_STRUCT_SPLINE) { for (i=0; i < ssn; i++) { if (ssmooth[i]) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(polyssv[i].x), OFFSET_Y(polyssv[i].y)); } else { MARKHR(drawWindow, revDefaultGC, OFFSET_X(polyssv[i].x), OFFSET_Y(polyssv[i].y)); } } } break; } if (curved == LT_STRUCT_SPLINE) { psssi = (StretchStructuredSplineInfo*)malloc( sizeof(StretchStructuredSplineInfo)); if (psssi == NULL) FailAllocMessage(); memset(psssi, 0, sizeof(StretchStructuredSplineInfo)); #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(obj_ptr->userdata == NULL, "obj_ptr is not NULL in PrepareToMoveVs()", NULL); #endif /* _TGIF_DBG */ obj_ptr->userdata = vsel_ptr->obj->userdata = psssi; if (poly_ptr != NULL) { SetIPTInfoForStretchPoly(vsel_ptr->v_index[0], num_pts, polyv, psssi); } else if (polygon_ptr != NULL) { SetIPTInfoForStretchPolygon(vsel_ptr->v_index[0], num_pts, polyv, psssi); } SetVsAndVs2ForStretchStructSpline(psssi, 0, 0, &psssi->num_vs, psssi->vs, &psssi->num_vs2, psssi->vs2); FixUpSmoothAndSmooth2ForStretchStructSpline(psssi->num_vs, psssi->smooth, psssi->num_vs2, psssi->smooth2); if (psssi->prev_valid) { psssi->sv = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &psssi->sn, psssi->smooth, drawOrigX, drawOrigY, psssi->num_vs, psssi->vs); psssi->saved_sv = DupVs(&psssi->saved_sn, psssi->sv, psssi->sn); } if (psssi->next_valid) { psssi->sv2 = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &psssi->sn2, psssi->smooth2, drawOrigX, drawOrigY, psssi->num_vs2, psssi->vs2); psssi->saved_sv2 = DupVs(&psssi->saved_sn2, psssi->sv2, psssi->sn2); } EraseHighLightForStretchStructSpline(psssi, 0, 0, FALSE, TRUE); } } } static void MarkVsForStructuredSplines(Dir, abs_dx, abs_dy) int Dir, abs_dx, abs_dy; { struct ObjRec *obj_ptr=NULL; switch (Dir) { case FORWARD: obj_ptr = tmpBotObj; break; case REVERSE: obj_ptr = tmpTopObj; break; } while (obj_ptr != NULL) { StretchStructuredSplineInfo *psssi= (StretchStructuredSplineInfo*)(obj_ptr->userdata); if (psssi != NULL) { switch (Dir) { case REVERSE: /* erase */ if (psssi->sv != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, psssi->sv, psssi->sn, CoordModeOrigin); free(psssi->sv); psssi->sv = NULL; } if (psssi->sv2 != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, psssi->sv2, psssi->sn2, CoordModeOrigin); free(psssi->sv2); psssi->sv2 = NULL; } EraseHighLightForStretchStructSpline(psssi, abs_dx, abs_dy, TRUE, TRUE); break; case FORWARD: /* draw */ SetVsAndVs2ForStretchStructSpline(psssi, abs_dx, abs_dy, &psssi->num_vs, psssi->vs, &psssi->num_vs2, psssi->vs2); FixUpSmoothAndSmooth2ForStretchStructSpline(psssi->num_vs, psssi->smooth, psssi->num_vs2, psssi->smooth2); if (psssi->prev_valid) { psssi->sv = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &psssi->sn, psssi->smooth, drawOrigX, drawOrigY, psssi->num_vs, psssi->vs); XDrawLines(mainDisplay, drawWindow, revDefaultGC, psssi->sv, psssi->sn, CoordModeOrigin); } if (psssi->next_valid) { psssi->sv2 = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &psssi->sn2, psssi->smooth2, drawOrigX, drawOrigY, psssi->num_vs2, psssi->vs2); XDrawLines(mainDisplay, drawWindow, revDefaultGC, psssi->sv2, psssi->sn2, CoordModeOrigin); } EraseHighLightForStretchStructSpline(psssi, abs_dx, abs_dy, TRUE, TRUE); break; } if (psssi->hinge) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(psssi->ipt.hinge_pt.x+abs_dx), OFFSET_Y(psssi->ipt.hinge_pt.y+abs_dy)); } else if (psssi->earlier_smooth_selected) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(psssi->ipt.earlier_smooth_pt.x+abs_dx), OFFSET_Y(psssi->ipt.earlier_smooth_pt.y+abs_dy)); } else { MARKHO(drawWindow, revDefaultGC, OFFSET_X(psssi->ipt.later_smooth_pt.x+abs_dx), OFFSET_Y(psssi->ipt.later_smooth_pt.y+abs_dy)); } } switch (Dir) { case FORWARD: obj_ptr = obj_ptr->prev; break; case REVERSE: obj_ptr = obj_ptr->next; break; } } } static void HighLightVs(Dir, abs_dx, abs_dy) int Dir, abs_dx, abs_dy; { int i=0, n=0, curved=(-1); struct ObjRec *obj_ptr=NULL; IntPoint *v=NULL; char *smooth=NULL; switch (Dir) { case FORWARD: obj_ptr = tmpBotObj; break; case REVERSE: obj_ptr = tmpTopObj; break; } while (obj_ptr != NULL) { switch (obj_ptr->type) { case OBJ_POLY: curved = obj_ptr->detail.p->curved; if (curved == LT_STRUCT_SPLINE) { n = obj_ptr->detail.p->ssn; v = obj_ptr->detail.p->ssvlist; smooth = obj_ptr->detail.p->ssmooth; } else { n = obj_ptr->detail.p->n; v = obj_ptr->detail.p->vlist; smooth = obj_ptr->detail.p->smooth; } if (curved != LT_INTSPLINE && smooth != NULL) { if (curved == LT_STRUCT_SPLINE) { /* nothing to do here */ } else { for (i=0; i < n; i++) { if (smooth[i]) { MARKO(drawWindow, revDefaultGC, OFFSET_X(v[i].x), OFFSET_Y(v[i].y)); } else { MARK(drawWindow, revDefaultGC, OFFSET_X(v[i].x), OFFSET_Y(v[i].y)); } } } } else { for (i=0; i < n; i++) { MARK(drawWindow, revDefaultGC, OFFSET_X(v[i].x), OFFSET_Y(v[i].y)); } } if (curved == LT_STRUCT_SPLINE) { /* nothing to do here */ } else { XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_ptr->detail.p->svlist, obj_ptr->detail.p->sn, CoordModeOrigin); } break; case OBJ_POLYGON: curved = obj_ptr->detail.g->curved; if (curved == LT_STRUCT_SPLINE) { n = obj_ptr->detail.g->ssn; v = obj_ptr->detail.g->ssvlist; smooth = obj_ptr->detail.g->ssmooth; } else { n = obj_ptr->detail.g->n; v = obj_ptr->detail.g->vlist; smooth = obj_ptr->detail.g->smooth; } if (obj_ptr->detail.g->curved != LT_INTSPLINE && smooth != NULL) { if (curved == LT_STRUCT_SPLINE) { /* nothing to do */ } else { for (i=0; i < obj_ptr->detail.g->n-1; i++) { if (smooth[i]) { MARKO(drawWindow, revDefaultGC, OFFSET_X(v[i].x), OFFSET_Y(v[i].y)); } else { MARK(drawWindow, revDefaultGC, OFFSET_X(v[i].x), OFFSET_Y(v[i].y)); } } } } else { for (i=0; i < obj_ptr->detail.g->n-1; i++) { MARK(drawWindow, revDefaultGC, OFFSET_X(v[i].x), OFFSET_Y(v[i].y)); } } if (curved == LT_STRUCT_SPLINE) { /* nothing to do here */ } else { XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_ptr->detail.g->svlist, obj_ptr->detail.g->sn, CoordModeOrigin); } break; } switch (Dir) { case FORWARD: obj_ptr = obj_ptr->prev; break; case REVERSE: obj_ptr = obj_ptr->next; break; } } } static void MarkVs(Dir, Dx, Dy) int Dir, Dx, Dy; /* Dx and Dy are screen offsets */ { register int i, x, y; register struct VSelRec *vsel_ptr=NULL; switch (Dir) { case FORWARD: vsel_ptr = botVSel; break; case REVERSE: vsel_ptr = topVSel; break; } while (vsel_ptr != NULL) { char *smooth=NULL; int curved=(-1); switch (vsel_ptr->obj->type) { case OBJ_POLY: smooth = vsel_ptr->obj->detail.p->smooth; curved = vsel_ptr->obj->detail.p->curved; break; case OBJ_POLYGON: smooth = vsel_ptr->obj->detail.g->smooth; curved = vsel_ptr->obj->detail.g->curved; break; } for (i=0; i < vsel_ptr->n; i++) { if (!(vsel_ptr->obj->type==OBJ_POLYGON && vsel_ptr->obj->detail.g->n-1==vsel_ptr->v_index[i])) { x = OFFSET_X(vsel_ptr->x[i])+Dx; y = OFFSET_Y(vsel_ptr->y[i])+Dy; if (curved == LT_STRUCT_SPLINE || ((curved == LT_STRAIGHT || curved == LT_SPLINE) && smooth != NULL)) { if (curved == LT_STRUCT_SPLINE) { /* nothing to do here */ } else { if (smooth[vsel_ptr->v_index[i]]) { if (curved == LT_STRUCT_SPLINE) { MARKHO(drawWindow, revDefaultGC, x, y); } else { MARKO(drawWindow, revDefaultGC, x, y); } } else { if (curved == LT_STRUCT_SPLINE) { MARKHR(drawWindow, revDefaultGC, x, y); } else { MARK(drawWindow, revDefaultGC, x, y); } } } } else { MARK(drawWindow, revDefaultGC, x, y); } MARKV(drawWindow, revDefaultGC, x, y); } } switch (Dir) { case FORWARD: vsel_ptr = vsel_ptr->prev; break; case REVERSE: vsel_ptr = vsel_ptr->next; break; } } } static void GetSelectedVsBBox(pBBox) struct BBRec *pBBox; { int found=FALSE, ltx=0, lty=0, rbx=0, rby=0; struct VSelRec *vsel_ptr=NULL; vsel_ptr = botVSel; while (vsel_ptr != NULL) { int i=0; for (i=0; i < vsel_ptr->n; i++) { if (!(vsel_ptr->obj->type==OBJ_POLYGON && vsel_ptr->obj->detail.g->n-1==vsel_ptr->v_index[i])) { int x=OFFSET_X(vsel_ptr->x[i]); int y=OFFSET_Y(vsel_ptr->y[i]); if (found) { if (x < ltx) ltx = x; if (x > rbx) rbx = x; if (y < lty) lty = y; if (y > rby) rby = y; } else { found = TRUE; ltx = rbx = x; lty = rby = y; } } } vsel_ptr = vsel_ptr->prev; } if (found) { pBBox->ltx = ltx; pBBox->lty = lty; pBBox->rbx = rbx; pBBox->rby = rby; } } void MoveSelVs(OrigX, OrigY) int OrigX, OrigY; { int x=0, y=0, i=0; struct ObjRec *obj_ptr=NULL; struct VSelRec *vsel_ptr=NULL; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; IntPoint *pv=NULL; int moving=TRUE, dx=0, dy=0, num_pts=0, curved=FALSE; int grid_x=OrigX, grid_y=OrigY, abs_dx_from_orig=0, abs_dy_from_orig=0; int saved_grid_x=OrigX, saved_grid_y=OrigY; struct BBRec ruler_bbox; char buf[80], x_buf[80], y_buf[80]; XEvent ev; XFlush(mainDisplay); XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } HighLightReverse(); PrepareToMoveVs(); MarkVsForStructuredSplines(FORWARD, 0, 0); HighLightVs(FORWARD, 0, 0); MarkVs(FORWARD, 0, 0); memset(&ruler_bbox, 0, sizeof(struct BBRec)); GetSelectedVsBBox(&ruler_bbox); PixelToMeasurementUnit(x_buf, 0); PixelToMeasurementUnit(y_buf, 0); sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); if (VerboseMeasureTooltip()) { sprintf(buf, "dx=%s dy=%s", x_buf, y_buf); } else { sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); } StartShowMeasureCursor(grid_x, grid_y, buf, TRUE); BeginIntervalRulers(ruler_bbox.ltx, ruler_bbox.lty, ruler_bbox.rbx, ruler_bbox.rby); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, moveCursor, CurrentTime); } while (moving) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); EndIntervalRulers(grid_x, grid_y); PixelToMeasurementUnit(x_buf, ABS_SIZE(grid_x-OrigX)); PixelToMeasurementUnit(y_buf, ABS_SIZE(grid_y-OrigY)); if (VerboseMeasureTooltip()) { sprintf(buf, "dx=%s dy=%s", x_buf, y_buf); } else { sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); } EndShowMeasureCursor(grid_x, grid_y, buf, TRUE); MarkRulers(grid_x, grid_y); moving = FALSE; dx = grid_x - OrigX; dy = grid_y - OrigY; MarkVs(REVERSE, dx, dy); MarkVsForStructuredSplines(REVERSE, ABS_SIZE(dx), ABS_SIZE(dy)); HighLightVs(REVERSE, ABS_SIZE(dx), ABS_SIZE(dy)); EndMoveVs(ABS_SIZE(dx), ABS_SIZE(dy)); if (dx != 0 || dy != 0) { MoveAllSelVs(ABS_SIZE(dx), ABS_SIZE(dy)); HighLightForward(); SetFileModified(TRUE); } else { HighLightForward(); } } else if (input.type == MotionNotify || input.type == KeyPress || input.type == KeyRelease) { PixelToMeasurementUnit(x_buf, ABS_SIZE(grid_x-OrigX)); PixelToMeasurementUnit(y_buf, ABS_SIZE(grid_y-OrigY)); if (VerboseMeasureTooltip()) { sprintf(buf, "dx=%s dy=%s", x_buf, y_buf); } else { sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); } ShowMeasureCursor(grid_x, grid_y, buf, TRUE); /* erase */ MarkVs(REVERSE, grid_x-OrigX, grid_y-OrigY); MarkVsForStructuredSplines(REVERSE, ABS_SIZE(grid_x-OrigX), ABS_SIZE(grid_y-OrigY)); HighLightVs(REVERSE, ABS_SIZE(grid_x-OrigX), ABS_SIZE(grid_x-OrigX)); if (input.type == KeyPress || input.type == KeyRelease) { x = saved_grid_x; y = saved_grid_y; } else { x = input.xmotion.x; y = input.xmotion.y; } if (shiftForDiagMouseMove && DiagEventCheck(&input)) { if (useRecentDupDistance && justDupped && useRecentForDiagMouseMove) { DiagGridXY(OrigX-ZOOMED_SIZE(dupDx), OrigY-ZOOMED_SIZE(dupDy), &x, &y); } else { DiagGridXY(OrigX, OrigY, &x, &y); } } GridXY(x, y, &grid_x, &grid_y); dx = grid_x - saved_grid_x; dy = grid_y - saved_grid_y; saved_grid_x = grid_x; saved_grid_y = grid_y; abs_dx_from_orig = ABS_SIZE(grid_x-OrigX); abs_dy_from_orig = ABS_SIZE(grid_y-OrigY); for (vsel_ptr=botVSel, obj_ptr=tmpBotObj; vsel_ptr != NULL; vsel_ptr=vsel_ptr->prev, obj_ptr=obj_ptr->prev) { switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; curved = poly_ptr->curved; num_pts = poly_ptr->n; pv = poly_ptr->vlist; for (i=0; i < vsel_ptr->n; i++) { pv[vsel_ptr->v_index[i]].x += ABS_SIZE(dx); pv[vsel_ptr->v_index[i]].y += ABS_SIZE(dy); } if (poly_ptr->svlist != NULL) { free(poly_ptr->svlist); poly_ptr->svlist = NULL; } switch (curved) { case LT_STRAIGHT: case LT_SPLINE: poly_ptr->svlist = MakeMultiSplinePolyVertex( curved, &(poly_ptr->sn), poly_ptr->smooth, drawOrigX, drawOrigY, num_pts, pv); break; case LT_STRUCT_SPLINE: /* nothing to do here */ break; case LT_INTSPLINE: if (poly_ptr->intvlist != NULL) { free(poly_ptr->intvlist); poly_ptr->intvlist = NULL; } poly_ptr->svlist = MakeIntSplinePolyVertex( &(poly_ptr->sn), &(poly_ptr->intn), &(poly_ptr->intvlist), drawOrigX, drawOrigY, num_pts, pv); break; } break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; curved = polygon_ptr->curved; num_pts = polygon_ptr->n; pv = polygon_ptr->vlist; for (i=0; i < vsel_ptr->n; i++) { pv[vsel_ptr->v_index[i]].x += ABS_SIZE(dx); pv[vsel_ptr->v_index[i]].y += ABS_SIZE(dy); } if (polygon_ptr->svlist != NULL) { free(polygon_ptr->svlist); polygon_ptr->svlist = NULL; } switch (curved) { case LT_STRAIGHT: case LT_SPLINE: polygon_ptr->svlist = MakeMultiSplinePolygonVertex(curved, &(polygon_ptr->sn), polygon_ptr->smooth, drawOrigX, drawOrigY, num_pts, pv); break; case LT_STRUCT_SPLINE: /* nothing to do here */ break; case LT_INTSPLINE: if (polygon_ptr->intvlist != NULL) { free(polygon_ptr->intvlist); polygon_ptr->intvlist = NULL; } polygon_ptr->svlist = MakeIntSplinePolygonVertex(&(polygon_ptr->sn), &(polygon_ptr->intn), &(polygon_ptr->intvlist), drawOrigX, drawOrigY, num_pts, pv); break; } break; } } /* draw */ MarkVsForStructuredSplines(FORWARD, abs_dx_from_orig, abs_dy_from_orig); HighLightVs(FORWARD, abs_dx_from_orig, abs_dy_from_orig); MarkVs(FORWARD, grid_x-OrigX, grid_y-OrigY); PixelToMeasurementUnit(x_buf, abs_dx_from_orig); PixelToMeasurementUnit(y_buf, abs_dy_from_orig); if (VerboseMeasureTooltip()) { sprintf(buf, "dx=%s dy=%s", x_buf, y_buf); } else { sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); } DrawIntervalRulers(ruler_bbox.ltx+abs_dx_from_orig, ruler_bbox.lty+abs_dy_from_orig, ruler_bbox.rbx+abs_dx_from_orig, ruler_bbox.rby+abs_dy_from_orig, buf); ShowMeasureCursor(grid_x, grid_y, buf, TRUE); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } } tgif-QPL-4.2.5/tdgtbase.e0000644000076400007640000000577611602233313014747 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtbase.e,v 1.7 2011/05/16 16:21:59 william Exp $ */ #ifndef _TDGTBASE_E_ #define _TDGTBASE_E_ #include "tidget.h" #include "list.e" #define TDGTBASE_DEF_H_PAD 4 #define TDGTBASE_DEF_V_PAD 4 #define TDGTCMD_CAN_HANDLE_FOCUS_CHANGE 1 #define TDGTCMD_REMOVE_FOCUS 2 struct tagTdgtBase; typedef int (TdgtBaseKeyPressEvHandlerCallbackFunc)ARGS_DECL(( struct tagTdgtBase *, XEvent*)); typedef void (TdgtBaseWmDeleteEvHandlerCallbackFunc)ARGS_DECL(( struct tagTdgtBase *)); typedef int (TdgtBaseFocusCallbackFunc)ARGS_DECL(( struct tagTdgtBase *, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); /* * A base tidget is a container of which other tidgets can sit on top. */ typedef struct tagTdgtBase { TidgetInfo *pti; /* callback functions */ TdgtBaseKeyPressEvHandlerCallbackFunc *pf_key_press_ev_handler_callback; TdgtBaseWmDeleteEvHandlerCallbackFunc *pf_wm_delete_ev_handler_callback; TdgtBaseFocusCallbackFunc *pf_focus_callback; } TdgtBase; #ifdef _INCLUDE_FROM_TDGTBASE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TDGTBASE_C_*/ extern void TdgtBaseReset ARGS_DECL((TdgtBase*)); extern TdgtBase *CreateTdgtBase ARGS_DECL((Window parent_win, TidgetInfo *parent_tidgetinfo, int ctl_id, int x, int y, int w, int h, int h_pad, int v_pad, int state, char *caption)); extern int TdgtBaseSetText ARGS_DECL((TdgtBase*, char *str)); extern char *TdgtBaseGetText ARGS_DECL((TdgtBase*)); extern int TdgtBaseSetState ARGS_DECL((TdgtBase*, int)); extern int TdgtBaseGetState ARGS_DECL((TdgtBase*)); extern int TdgtBaseAddChild ARGS_DECL((TdgtBase*, TidgetInfo*)); extern void TdgtBaseWillHandleKeyPressEvents ARGS_DECL((TdgtBase*, TdgtBaseKeyPressEvHandlerCallbackFunc*)); extern void TdgtBaseSetWmDeleteCallback ARGS_DECL((TdgtBase*, TdgtBaseWmDeleteEvHandlerCallbackFunc*)); extern void TdgtBaseSetFocusCallback ARGS_DECL((TdgtBase*, TdgtBaseFocusCallbackFunc*)); extern int InitTdgtBase ARGS_DECL((void)); extern void CleanUpTdgtBase ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TDGTBASE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TDGTBASE_C_*/ #endif /*_TDGTBASE_E_*/ tgif-QPL-4.2.5/rect.c0000644000076400007640000017543211602233312014101 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/rect.c,v 1.6 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_RECT_C_ #include "tgifdefs.h" #include "arc.e" #include "color.e" #include "dialog.e" #include "drawing.e" #include "file.e" #include "msg.e" #include "poly.e" #include "ps.e" #include "rect.e" #include "setup.e" #include "spline.e" #include "strtbl.e" void DumpRectPath(FP, LtX, LtY, RbX, RbY, Indent, LastLF) FILE *FP; int LtX, LtY, RbX, RbY, Indent; { register int i; if (psUseShortHand) { for (i=0; i < Indent; i++) fprintf(FP, " "); fprintf(FP, "%s %1d %1d %s %1d %1d %s %1d %1d %s %1d %1d %s %s", gPsCmd[PS_NEWPATH], LtX, LtY, gPsCmd[PS_MOVETO], RbX, LtY, gPsCmd[PS_LINETO], RbX, RbY, gPsCmd[PS_LINETO], LtX, RbY, gPsCmd[PS_LINETO], gPsCmd[PS_CLOSEPATH]); } else { for (i=0; i < Indent; i++) fprintf(FP, " "); fprintf(FP, "%s\n", gPsCmd[PS_NEWPATH]); for (i=0; i < Indent; i++) fprintf(FP, " "); fprintf(FP, " %1d %1d %s ", LtX, LtY, gPsCmd[PS_MOVETO]); fprintf(FP, "%1d %1d %s ", RbX, LtY, gPsCmd[PS_LINETO]); fprintf(FP, "%1d %1d %s ", RbX, RbY, gPsCmd[PS_LINETO]); fprintf(FP, "%1d %1d %s\n", LtX, RbY, gPsCmd[PS_LINETO]); for (i=0; i < Indent; i++) fprintf(FP, " "); fprintf(FP, "%s", gPsCmd[PS_CLOSEPATH]); } fprintf(FP, "%s", (LastLF ? "\n" : " ")); } void SetPoint(pt, x, y) IntPoint *pt; int x, y; { pt->x = x; pt->y = y; } void ClipRect(bbox, w, h) struct BBRec *bbox; int w, h; { if (bbox->ltx < 0) { bbox->rbx += bbox->ltx; bbox->ltx = 0; } if (bbox->lty < 0) { bbox->rby += bbox->lty; bbox->lty = 0; } if (bbox->rbx >= w) { bbox->rbx = w - 1; } if (bbox->rby >= h) { bbox->rby = h - 1; } } int CompareRect(pBBox1, pBBox2) struct BBRec *pBBox1, *pBBox2; { return memcmp(pBBox1, pBBox2, sizeof(struct BBRec)); } void SetRotateVs(vs, ltx, lty, rbx, rby) XPoint *vs; /* array of 5 points */ int ltx, lty, rbx, rby; { vs[0].x = vs[4].x = ltx; vs[0].y = vs[4].y = lty; vs[1].x = rbx; vs[1].y = lty; vs[2].x = rbx; vs[2].y = rby; vs[3].x = ltx; vs[3].y = rby; } void SetBBRec(bbox, ltx, lty, rbx, rby) struct BBRec *bbox; int ltx, lty, rbx, rby; { if (ltx <= rbx) { bbox->ltx = ltx; bbox->rbx = rbx; } else { bbox->ltx = rbx; bbox->rbx = ltx; } if (lty <= rby) { bbox->lty = lty; bbox->rby = rby; } else { bbox->lty = rby; bbox->rby = lty; } } void ConcatCTM(ctm, orig_ctm, new_ctm) struct XfrmMtrxRec *ctm, *orig_ctm, *new_ctm; /* Note: CTM_SX, CTM_SIN, CTM_MSIN, and CTM_SY are scaled 1000 times */ /* while CTM_TX and CTM_TY are not scaled */ { new_ctm->m[0] = ((double)(ctm->m[0]*orig_ctm->m[0] + ctm->m[1]*orig_ctm->m[2]))/1000.0; new_ctm->m[1] = ((double)(ctm->m[0]*orig_ctm->m[1] + ctm->m[1]*orig_ctm->m[3]))/1000.0; new_ctm->m[2] = ((double)(ctm->m[2]*orig_ctm->m[0] + ctm->m[3]*orig_ctm->m[2]))/1000.0; new_ctm->m[3] = ((double)(ctm->m[2]*orig_ctm->m[1] + ctm->m[3]*orig_ctm->m[3]))/1000.0; new_ctm->t[CTM_TX] = round(((double)(ctm->t[CTM_TX]*orig_ctm->m[0] + ctm->t[CTM_TY]*orig_ctm->m[2]))/1000.0) + orig_ctm->t[CTM_TX]; new_ctm->t[CTM_TY] = round(((double)(ctm->t[CTM_TX]*orig_ctm->m[1] + ctm->t[CTM_TY]*orig_ctm->m[3]))/1000.0) + orig_ctm->t[CTM_TY]; } void TransformDoublePointThroughCTM(X, Y, ctm, NewX, NewY) double X, Y, *NewX, *NewY; struct XfrmMtrxRec *ctm; { *NewX = (X*((double)ctm->m[0]) + Y*((double)ctm->m[2]))/1000.0 + (double)ctm->t[CTM_TX]; *NewY = (X*((double)ctm->m[1]) + Y*((double)ctm->m[3]))/1000.0 + (double)ctm->t[CTM_TY]; } void TransformPointThroughCTM(X, Y, ctm, NewX, NewY) int X, Y, *NewX, *NewY; struct XfrmMtrxRec *ctm; { double x=(double)0, y=(double)0; x = ((double)(((double)X)*ctm->m[0]+((double)Y)*ctm->m[2])) / 1000.0 + (double)(ctm->t[CTM_TX]); y = ((double)(((double)X)*ctm->m[1]+((double)Y)*ctm->m[3])) / 1000.0 + (double)(ctm->t[CTM_TY]); *NewX = round(x); *NewY = round(y); } void ReverseTransformDoublePointThroughCTM(X, Y, ctm, NewDx, NewDy) double X, Y, *NewDx, *NewDy; struct XfrmMtrxRec *ctm; /* * [ a b 0 ] * Let ctm = [ c d 0 ] * [ e f 1 ] * * d(X-e) - c(Y-f) * *NewX = ----------------- * ad - bc * * b(X-e) - a(Y-f) * *NewY = ----------------- * bc - ad */ { double ad_bc=ctm->m[0]*ctm->m[3]-ctm->m[1]*ctm->m[2]; double term_1=X-((double)(ctm->t[CTM_TX])); double term_2=Y-((double)(ctm->t[CTM_TY])); *NewDx = ((double)1000.0) * ((double)(ctm->m[3]*term_1 - ctm->m[2]*term_2)) / ((double)ad_bc); *NewDy = ((double)1000.0) * ((double)(ctm->m[0]*term_2 - ctm->m[1]*term_1)) / ((double)(ad_bc)); } void ReverseTransformPointThroughCTM(X, Y, ctm, NewX, NewY) int X, Y, *NewX, *NewY; struct XfrmMtrxRec *ctm; { double x=(double)0, y=(double)0; ReverseTransformDoublePointThroughCTM(((double)X), ((double)Y), ctm, &x, &y); *NewX = round(x); *NewY = round(y); } void TransformObjectV(ObjPtr, VIn, VOut) struct ObjRec *ObjPtr; IntPoint *VIn, *VOut; { int x, y; TransformPointThroughCTM(VIn->x-ObjPtr->x, VIn->y-ObjPtr->y, ObjPtr->ctm, &x, &y); VOut->x = x + ObjPtr->x; VOut->y = y + ObjPtr->y; } void ReversedTransformObjectV(ObjPtr, VIn, VOut) struct ObjRec *ObjPtr; IntPoint *VIn, *VOut; { int x, y; ReverseTransformPointThroughCTM(VIn->x-ObjPtr->x, VIn->y-ObjPtr->y, ObjPtr->ctm, &x, &y); VOut->x = x + ObjPtr->x; VOut->y = y + ObjPtr->y; } void TransformOffsetBBoxThroughCTM(bbox, ctm, vs) struct BBRec *bbox; struct XfrmMtrxRec *ctm; IntPoint *vs; /* array of 5 points */ { int x, y; TransformPointThroughCTM(bbox->ltx, bbox->lty, ctm, &x, &y); vs[0].x = vs[4].x = x; vs[0].y = vs[4].y = y; TransformPointThroughCTM(bbox->rbx, bbox->lty, ctm, &x, &y); vs[1].x = x; vs[1].y = y; TransformPointThroughCTM(bbox->rbx, bbox->rby, ctm, &x, &y); vs[2].x = x; vs[2].y = y; TransformPointThroughCTM(bbox->ltx, bbox->rby, ctm, &x, &y); vs[3].x = x; vs[3].y = y; } void GetTransformedOBBoxOffsetVs(ObjPtr, Vs) struct ObjRec *ObjPtr; XPoint *Vs; /* array of 5 points */ { int x, y; struct BBRec obbox; IntPoint vs[5]; if (ObjPtr->ctm == NULL) return; obbox.ltx = ObjPtr->orig_obbox.ltx - ObjPtr->x; obbox.lty = ObjPtr->orig_obbox.lty - ObjPtr->y; obbox.rbx = ObjPtr->orig_obbox.rbx - ObjPtr->x; obbox.rby = ObjPtr->orig_obbox.rby - ObjPtr->y; TransformOffsetBBoxThroughCTM(&obbox, ObjPtr->ctm, vs); x = OFFSET_X(vs[0].x + ObjPtr->x); y = OFFSET_Y(vs[0].y + ObjPtr->y); Vs[0].x = Vs[4].x = x; Vs[0].y = Vs[4].y = y; x = OFFSET_X(vs[1].x + ObjPtr->x); y = OFFSET_Y(vs[1].y + ObjPtr->y); Vs[1].x = x; Vs[1].y = y; x = OFFSET_X(vs[2].x + ObjPtr->x); y = OFFSET_Y(vs[2].y + ObjPtr->y); Vs[2].x = x; Vs[2].y = y; x = OFFSET_X(vs[3].x + ObjPtr->x); y = OFFSET_Y(vs[3].y + ObjPtr->y); Vs[3].x = x; Vs[3].y = y; } void GetTransformedOBBoxAbsVs(ObjPtr, Vs) struct ObjRec *ObjPtr; IntPoint *Vs; /* array of 5 points */ { int x, y; struct BBRec obbox; IntPoint vs[5]; if (ObjPtr->ctm == NULL) return; obbox.ltx = ObjPtr->orig_obbox.ltx - ObjPtr->x; obbox.lty = ObjPtr->orig_obbox.lty - ObjPtr->y; obbox.rbx = ObjPtr->orig_obbox.rbx - ObjPtr->x; obbox.rby = ObjPtr->orig_obbox.rby - ObjPtr->y; TransformOffsetBBoxThroughCTM(&obbox, ObjPtr->ctm, vs); x = vs[0].x + ObjPtr->x; y = vs[0].y + ObjPtr->y; Vs[0].x = Vs[4].x = x; Vs[0].y = Vs[4].y = y; x = vs[1].x + ObjPtr->x; y = vs[1].y + ObjPtr->y; Vs[1].x = x; Vs[1].y = y; x = vs[2].x + ObjPtr->x; y = vs[2].y + ObjPtr->y; Vs[2].x = x; Vs[2].y = y; x = vs[3].x + ObjPtr->x; y = vs[3].y + ObjPtr->y; Vs[3].x = x; Vs[3].y = y; } void SetCTM(ObjPtr, ctm) struct ObjRec *ObjPtr; struct XfrmMtrxRec *ctm; /* ObjPtr->ctm must be NULL */ { IntPoint abs_obj_obbox_vs[5]; struct XfrmMtrxRec new_ctm; int ltx, lty, rbx, rby; if (ObjPtr->ctm != NULL) { MsgBox(TgLoadString(STID_ERR_SETCTM_CALLED_CTM_NONNULL), TOOL_NAME, INFO_MB); free(ObjPtr->ctm); } memcpy(&ObjPtr->orig_obbox, &ObjPtr->obbox, sizeof(struct BBRec)); if (ObjPtr->type == OBJ_TEXT) { memcpy(&ObjPtr->detail.t->orig_bbox, &ObjPtr->bbox, sizeof(struct BBRec)); } ObjPtr->ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ObjPtr->ctm == NULL) FailAllocMessage(); ObjPtr->ctm->m[CTM_SX] = ObjPtr->ctm->m[CTM_SY] = (double)1000; ObjPtr->ctm->m[CTM_SIN] = ObjPtr->ctm->m[CTM_MSIN] = (double)0; ObjPtr->ctm->t[CTM_TX] = ObjPtr->ctm->t[CTM_TY] = 0; ConcatCTM(ObjPtr->ctm, ctm, &new_ctm); memcpy(ObjPtr->ctm, &new_ctm, sizeof(struct XfrmMtrxRec)); GetTransformedOBBoxAbsVs(ObjPtr, abs_obj_obbox_vs); ltx = min(min(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), min(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); rbx = max(max(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), max(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); lty = min(min(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), min(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); rby = max(max(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), max(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); ObjPtr->obbox.ltx = ltx; ObjPtr->obbox.lty = lty; ObjPtr->obbox.rbx = rbx; ObjPtr->obbox.rby = rby; GetTransformedOBBoxOffsetVs(ObjPtr, ObjPtr->rotated_obbox); } void ExpandExtents(pBBox, pnLtX, pnLtY, pnRbX, pnRbY) struct BBRec *pBBox; int *pnLtX, *pnLtY, *pnRbX, *pnRbY; { if (pBBox->ltx < (*pnLtX)) (*pnLtX) = pBBox->ltx; if (pBBox->lty < (*pnLtY)) (*pnLtY) = pBBox->lty; if (pBBox->rbx > (*pnRbX)) (*pnRbX) = pBBox->rbx; if (pBBox->rby > (*pnRbY)) (*pnRbY) = pBBox->rby; } void ExpandBBox(pBBox, pBBoxToExpand) struct BBRec *pBBox, *pBBoxToExpand; { if (pBBox->ltx < pBBoxToExpand->ltx) pBBoxToExpand->ltx = pBBox->ltx; if (pBBox->lty < pBBoxToExpand->lty) pBBoxToExpand->lty = pBBox->lty; if (pBBox->rbx > pBBoxToExpand->rbx) pBBoxToExpand->rbx = pBBox->rbx; if (pBBox->rby > pBBoxToExpand->rby) pBBoxToExpand->rby = pBBox->rby; } void InflateBBox(pBBoxIn, dx, dy, pBBoxOut) struct BBRec *pBBoxIn, *pBBoxOut; int dx, dy; { int ltx=pBBoxIn->ltx+dx, lty=pBBoxIn->lty+dy; int rbx=pBBoxIn->rbx-dx, rby=pBBoxIn->rby-dy; SetBBRec(pBBoxOut, ltx, lty, rbx, rby); } void OffsetBBox(pBBoxIn, dx, dy, pBBoxOut) struct BBRec *pBBoxIn, *pBBoxOut; int dx, dy; { int ltx=pBBoxIn->ltx+dx, lty=pBBoxIn->lty+dy; int rbx=pBBoxIn->rbx+dx, rby=pBBoxIn->rby+dy; SetBBRec(pBBoxOut, ltx, lty, rbx, rby); } int BBoxIntersect(Rect1, Rect2) struct BBRec Rect1, Rect2; { if (Rect1.ltx < Rect2.ltx) { if (Rect1.lty < Rect2.lty) { return (Rect1.rbx >= Rect2.ltx && Rect1.rby >= Rect2.lty); } else { return (Rect1.rbx >= Rect2.ltx && Rect1.lty <= Rect2.rby); } } else { if (Rect1.lty < Rect2.lty) { return (Rect1.ltx <= Rect2.rbx && Rect1.rby >= Rect2.lty); } else { return (Rect1.ltx <= Rect2.rbx && Rect1.lty <= Rect2.rby); } } } int IntersectRect(BBox1, BBox2, BBox3) struct BBRec BBox1, BBox2, *BBox3; /* returns the intersection of BBox1 and BBox2 in BBox3 */ { if (BBoxIntersect(BBox1, BBox2)) { BBox3->ltx = max(BBox1.ltx,BBox2.ltx); BBox3->lty = max(BBox1.lty,BBox2.lty); BBox3->rbx = min(BBox1.rbx,BBox2.rbx); BBox3->rby = min(BBox1.rby,BBox2.rby); return TRUE; } return FALSE; } void UnionRect(p_bbox1, p_bbox2, p_union_bbox) struct BBRec *p_bbox1, *p_bbox2, *p_union_bbox; { p_union_bbox->ltx = min(p_bbox1->ltx, p_bbox2->ltx); p_union_bbox->lty = min(p_bbox1->lty, p_bbox2->lty); p_union_bbox->rbx = max(p_bbox1->rbx, p_bbox2->rbx); p_union_bbox->rby = max(p_bbox1->rby, p_bbox2->rby); } int Inside(BBox1, BBox2) struct BBRec BBox1, BBox2; /* returns TRUE if BBox1 is inside BBox2 */ { return (BBox1.ltx >= BBox2.ltx && BBox1.lty >= BBox2.lty && BBox1.rbx <= BBox2.rbx && BBox1.rby <= BBox2.rby); } int PointInBBox(X, Y, Rect) int X, Y; struct BBRec Rect; { return (X >= Rect.ltx && Y >= Rect.lty && X <= Rect.rbx && Y <= Rect.rby); } int PointInIntPolygon(X, Y, NumPts, IV) int X, Y, NumPts; IntPoint *IV; { register double x1, x2, y1, y2; double m, y_int; int n, count=0; x2 = (double)IV[0].x; y2 = (double)IV[0].y; for (n=0; n < NumPts-1; n++) { x1 = x2; y1 = y2; x2 = (double)(IV[n+1].x); y2 = (double)(IV[n+1].y); if (x2 == x1) { if (X == x1 && Y >= min(y1,y2) && Y <= max(y1,y2)) count++; continue; } if (x2 > x1) { if (X >= x2 || X < x1) continue; } else { if (X > x1 || X <= x2) continue; } m = (y1 - y2) / (x1 - x2); y_int = m * X + (y1 - m * x1); if (Y <= y_int) { if (fabs(X-x1) < INT_TOL) { double x3=(double)((n == 0) ? IV[NumPts-2].x : IV[n-1].x); if ((x2 > X && X > x3) || (x3 > X && X > x2)) count++; } else { count++; } } } return (count & 0x1); } int PointInPolygon(X, Y, NumPts, V) int X, Y, NumPts; XPoint *V; { register double x1, x2, y1, y2; double m, y_int; int n, count=0; x2 = (double)V[0].x; y2 = (double)V[0].y; for (n=0; n < NumPts-1; n++) { x1 = x2; y1 = y2; x2 = (double)(V[n+1].x); y2 = (double)(V[n+1].y); if (x2 == x1) { if (X == x1 && Y >= min(y1,y2) && Y <= max(y1,y2)) count++; continue; } if (x2 > x1) { if (X >= x2 || X < x1) continue; } else { if (X > x1 || X <= x2) continue; } m = (y1 - y2) / (x1 - x2); y_int = m * X + (y1 - m * x1); if (Y <= y_int) { if (fabs(X-x1) < INT_TOL) { double x3=(double)((n == 0) ? V[NumPts-2].x : V[n-1].x); if ((x2 > X && X > x3) || (x3 > X && X > x2)) count++; } else { count++; } } } return (count & 0x1); } int PointOnPoly(X, Y, NumPts, V, W) int X, Y, NumPts, W; XPoint *V; { register double x1, x2, y1, y2; double x_int, y_int, dx, dy, abs_dx, abs_dy, real_w; int n, horizontal; x2 = (double)V[0].x; y2 = (double)V[0].y; for (n=0; n < NumPts-1; n++) { x1 = x2; y1 = y2; x2 = (double)(V[n+1].x); y2 = (double)(V[n+1].y); if (V[n].x==V[n+1].x && V[n].y==V[n+1].y) continue; dx = x2 - x1; abs_dx = fabs(dx); dy = y2 - y1; abs_dy = fabs(dy); horizontal = (abs_dx >= abs_dy); if (horizontal) { if (x2 >= x1) { if (X < x1 || X > x2) continue; } else { if (X < x2 || X > x1) continue; } real_w = (double)sqrt(abs_dx*abs_dx+abs_dy*abs_dy)*((double)W)/abs_dx; } else { if (y2 >= y1) { if (Y < y1 || Y > y2) continue; } else { if (Y < y2 || Y > y1) continue; } real_w = (double)sqrt(abs_dx*abs_dx+abs_dy*abs_dy)*((double)W)/abs_dy; } if (abs_dx >= abs_dy) { /* kind of a horizontal segment */ y_int = y1+(((double)X)-x1)*dy/dx; if ((double)fabs((double)Y-y_int) <= (real_w+4)) return TRUE; } else { /* kind of a vertical segment */ x_int = x1+(((double)Y)-y1)*dx/dy; if ((double)fabs((double)X-x_int) <= (real_w+4)) return TRUE; } } return FALSE; } int FindGoodText(XOff, YOff, TextObj) int XOff, YOff; struct ObjRec *TextObj; /* XOff and YOff are screen offsets */ { if (colorLayers && TextObj->tmp_parent == NULL && !ObjInVisibleLayer(TextObj)) { return FALSE; } if (TextObj->ctm == NULL) { return TRUE; } else { return PointInPolygon(XOff, YOff, 5, TextObj->rotated_obbox); } } int FindGoodXBm(XOff, YOff, XBmObj) int XOff, YOff; struct ObjRec *XBmObj; /* XOff and YOff are screen offsets */ { struct BBRec bbox; if (colorLayers && XBmObj->tmp_parent == NULL && !ObjInVisibleLayer(XBmObj)) { return FALSE; } bbox.ltx = OFFSET_X(XBmObj->obbox.ltx)-3; bbox.lty = OFFSET_Y(XBmObj->obbox.lty)-3; bbox.rbx = OFFSET_X(XBmObj->obbox.rbx)+3; bbox.rby = OFFSET_Y(XBmObj->obbox.rby)+3; if (XBmObj->ctm == NULL) { return PointInBBox(XOff, YOff, bbox); } else { return PointInPolygon(XOff, YOff, 5, XBmObj->rotated_obbox); } } int FindGoodXPm(XOff, YOff, XPmObj) int XOff, YOff; struct ObjRec *XPmObj; /* XOff and YOff are screen offsets */ { struct BBRec bbox; if (colorLayers && XPmObj->tmp_parent == NULL && !ObjInVisibleLayer(XPmObj)) { return FALSE; } bbox.ltx = OFFSET_X(XPmObj->obbox.ltx)-3; bbox.lty = OFFSET_Y(XPmObj->obbox.lty)-3; bbox.rbx = OFFSET_X(XPmObj->obbox.rbx)+3; bbox.rby = OFFSET_Y(XPmObj->obbox.rby)+3; if (XPmObj->ctm == NULL) { return PointInBBox(XOff, YOff, bbox); } else { return PointInPolygon(XOff, YOff, 5, XPmObj->rotated_obbox); } } int FindGoodBox(XOff, YOff, BoxObj) int XOff, YOff; struct ObjRec *BoxObj; /* XOff and YOff are screen offsets */ { struct BBRec bbox; int w; if (colorLayers && BoxObj->tmp_parent == NULL && !ObjInVisibleLayer(BoxObj)) { return FALSE; } bbox.ltx = OFFSET_X(BoxObj->obbox.ltx)-3; bbox.lty = OFFSET_Y(BoxObj->obbox.lty)-3; bbox.rbx = OFFSET_X(BoxObj->obbox.rbx)+3; bbox.rby = OFFSET_Y(BoxObj->obbox.rby)+3; if (!PointInBBox(XOff, YOff, bbox)) return FALSE; if (BoxObj->ctm == NULL) { if (!(BoxObj->detail.b->fill == NONEPAT || (BoxObj->detail.b->fill == BACKPAT && BoxObj->trans_pat))) { return TRUE; } w = HALF_W(BoxObj->detail.b->width); bbox.ltx = OFFSET_X(BoxObj->obbox.ltx+w)+3; bbox.lty = OFFSET_Y(BoxObj->obbox.lty+w)+3; bbox.rbx = OFFSET_X(BoxObj->obbox.rbx-w)-3; bbox.rby = OFFSET_Y(BoxObj->obbox.rby-w)-3; return (!PointInBBox(XOff, YOff, bbox)); } else { if (!(BoxObj->detail.b->fill == NONEPAT || (BoxObj->detail.b->fill == BACKPAT && BoxObj->trans_pat))) { if (PointInPolygon(XOff, YOff, 5, BoxObj->rotated_obbox)) { return TRUE; } } return PointOnPoly(XOff, YOff, 5, BoxObj->rotated_obbox, ZOOMED_HALF_W(BoxObj->detail.b->width)); } } int FindGoodRCBox(XOff, YOff, RCBoxObj) int XOff, YOff; struct ObjRec *RCBoxObj; /* XOff and YOff are screen offsets */ { struct RCBoxRec *rcbox_ptr=RCBoxObj->detail.rcb; int fill=rcbox_ptr->fill, trans_pat=RCBoxObj->trans_pat; if (colorLayers && RCBoxObj->tmp_parent == NULL && !ObjInVisibleLayer(RCBoxObj)) { return FALSE; } if (RCBoxObj->ctm == NULL) { register struct BBRec *obbox; register struct BBRec bbox; int w, r; obbox = &(RCBoxObj->obbox); bbox.ltx = OFFSET_X(obbox->ltx)-3; bbox.lty = OFFSET_Y(obbox->lty)-3; bbox.rbx = OFFSET_X(obbox->rbx)+3; bbox.rby = OFFSET_Y(obbox->rby)+3; if (!PointInBBox(XOff, YOff, bbox)) return FALSE; if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { return TRUE; } r = rcbox_ptr->radius; w = HALF_W(rcbox_ptr->width); bbox.ltx = OFFSET_X(obbox->ltx+w)+3; bbox.lty = OFFSET_Y(obbox->lty+r)+3; bbox.rbx = OFFSET_X(obbox->rbx-w)-3; bbox.rby = OFFSET_Y(obbox->rby-r)-3; if (PointInBBox(XOff, YOff, bbox)) { return FALSE; } else { bbox.ltx = OFFSET_X(obbox->ltx+r)+3; bbox.lty = OFFSET_Y(obbox->lty+w)+3; bbox.rbx = OFFSET_X(obbox->rbx-r)-3; bbox.rby = OFFSET_Y(obbox->rby-w)-3; return (!PointInBBox(XOff, YOff, bbox)); } } else if (rcbox_ptr->rotated_vlist != NULL) { if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (PointInPolygon(XOff, YOff, rcbox_ptr->rotated_n, rcbox_ptr->rotated_vlist)) { return TRUE; } } return PointOnPoly(XOff, YOff, rcbox_ptr->rotated_n, rcbox_ptr->rotated_vlist, ZOOMED_HALF_W(rcbox_ptr->width)); } return FALSE; } int FindGoodOval(XOff, YOff, OvalObj) int XOff, YOff; struct ObjRec *OvalObj; /* XOff and YOff are screen offsets */ { struct OvalRec *oval_ptr=OvalObj->detail.o; int w, ltx, lty, rbx, rby, fill=oval_ptr->fill, trans_pat=OvalObj->trans_pat; if (colorLayers && OvalObj->tmp_parent == NULL && !ObjInVisibleLayer(OvalObj)) { return FALSE; } ltx = OFFSET_X(OvalObj->obbox.ltx); lty = OFFSET_Y(OvalObj->obbox.lty); rbx = OFFSET_X(OvalObj->obbox.rbx); rby = OFFSET_Y(OvalObj->obbox.rby); if (ltx==rbx && lty==rby) return FALSE; if (OvalObj->ctm == NULL) { double cx, cy, rx, ry, tmp_x, tmp_y, x1=0.0, x2=0.0, y1=0.0, y2=0.0; cx = ((double)(ltx+rbx)/2.0); cy = ((double)(lty+rby)/2.0); rx = ((double)(rbx-ltx)/2.0); ry = ((double)(rby-lty)/2.0); if (rx >= ry) { /* flat oval */ tmp_y = (double)sqrt(fabs((double)(ry*ry*(1 - (((double)XOff)-cx)*(((double)XOff)-cx)/rx/rx)))); y1 = cy - tmp_y; y2 = cy + tmp_y; } else { /* tall oval */ tmp_x = (double)sqrt(fabs((double)(rx*rx*(1 - (((double)YOff)-cy)*(((double)YOff)-cy)/ry/ry)))); x1 = cx - tmp_x; x2 = cx + tmp_x; } if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (rx >= ry) { /* flat oval */ if (YOff >= y1-4 && y2+4 >= YOff) return TRUE; } else { /* tall oval */ if (XOff >= x1-4 && x2+4 >= XOff) return TRUE; } } w = ZOOMED_HALF_W(oval_ptr->width)+4; if (rx >= ry) { return ((fabs((double)(YOff-y1))<=w) || (fabs((double)(YOff-y2))<=w)); } else { return ((fabs((double)(XOff-x1))<=w) || (fabs((double)(XOff-x2))<=w)); } } else if (oval_ptr->rotated_vlist != NULL) { if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (PointInPolygon(XOff, YOff, oval_ptr->rotated_n, oval_ptr->rotated_vlist)) { return TRUE; } } return PointOnPoly(XOff, YOff, oval_ptr->rotated_n, oval_ptr->rotated_vlist, ZOOMED_HALF_W(oval_ptr->width)); } return FALSE; } int FindGoodPoly(XOff, YOff, PolyObj) int XOff, YOff; struct ObjRec *PolyObj; /* XOff and YOff are screen offsets */ { double len, sin, cos, aw, ah; XPoint tmp_v[4], *sv=NULL; struct PolyRec *poly_ptr=PolyObj->detail.p; int sn=0, dx, dy, fill=poly_ptr->fill, trans_pat=PolyObj->trans_pat; if (colorLayers && PolyObj->tmp_parent == NULL && !ObjInVisibleLayer(PolyObj)) { return FALSE; } if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (PolyObj->ctm == NULL) { sn = poly_ptr->sn; sv = poly_ptr->svlist; sv[sn].x = sv[0].x; sv[sn].y = sv[0].y; if (PointInPolygon(XOff, YOff, sn+1, sv)) return TRUE; } else if (poly_ptr->rotated_vlist != NULL) { sn = poly_ptr->rotated_n; sv = poly_ptr->rotated_vlist; sv[sn].x = sv[0].x; sv[sn].y = sv[0].y; if (PointInPolygon(XOff, YOff, sn+1, sv)) return TRUE; } } if (poly_ptr->style == LS_PLAIN) { if (PolyObj->ctm == NULL) { if (PointOnPoly(XOff, YOff, poly_ptr->sn, poly_ptr->svlist, ZOOMED_HALF_W(poly_ptr->width))) return TRUE; } else if (poly_ptr->rotated_vlist != NULL) { if (PointOnPoly(XOff, YOff, poly_ptr->rotated_n, poly_ptr->rotated_vlist, ZOOMED_HALF_W(poly_ptr->width))) return TRUE; } } else { if (PolyObj->ctm == NULL) { if (PointOnPoly(XOff, YOff, poly_ptr->asn, poly_ptr->asvlist, ZOOMED_HALF_W(poly_ptr->width))) return TRUE; } else if (poly_ptr->rotated_vlist != NULL) { if (PointOnPoly(XOff, YOff, poly_ptr->rotated_n, poly_ptr->rotated_vlist, ZOOMED_HALF_W(poly_ptr->width))) return TRUE; } } if (PolyObj->ctm == NULL) { sv = poly_ptr->svlist; sn = poly_ptr->sn; } else if (poly_ptr->rotated_vlist == NULL) { return FALSE; } else { sv = poly_ptr->rotated_vlist; sn = poly_ptr->rotated_n; } aw = poly_ptr->aw; ah = poly_ptr->ah; dx = (int)(sv[1].x - sv[0].x); dy = (int)(sv[1].y - sv[0].y); if ((poly_ptr->style & LS_LEFT) && (dx != 0 || dy != 0)) { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin = ((double)dy) / len; cos = ((double)dx) / len; tmp_v[0].x = tmp_v[3].x = OFFSET_X(sv[0].x); tmp_v[0].y = tmp_v[3].y = OFFSET_Y(sv[0].y); tmp_v[1].x = OFFSET_X(round(sv[0].x+aw*cos-ah*sin)); tmp_v[1].y = OFFSET_Y(round(sv[0].y+aw*sin+ah*cos)); tmp_v[2].x = OFFSET_X(round(sv[0].x+aw*cos+ah*sin)); tmp_v[2].y = OFFSET_Y(round(sv[0].y+aw*sin-ah*cos)); if (PointInPolygon(XOff, YOff, 4, tmp_v)) return TRUE; } dx = (int)(sv[sn-1].x - sv[sn-2].x); dy = (int)(sv[sn-1].y - sv[sn-2].y); if ((poly_ptr->style & LS_RIGHT) && (dx != 0 || dy != 0)) { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin = ((double)dy) / len; cos = ((double)dx) / len; tmp_v[0].x = tmp_v[3].x = OFFSET_X(sv[sn-1].x); tmp_v[0].y = tmp_v[3].y = OFFSET_Y(sv[sn-1].y); tmp_v[1].x = OFFSET_X(round(sv[sn-1].x-aw*cos+ah*sin)); tmp_v[1].y = OFFSET_Y(round(sv[sn-1].y-aw*sin-ah*cos)); tmp_v[2].x = OFFSET_X(round(sv[sn-1].x-aw*cos-ah*sin)); tmp_v[2].y = OFFSET_Y(round(sv[sn-1].y-aw*sin+ah*cos)); if (PointInPolygon(XOff, YOff, 4, tmp_v)) return TRUE; } return FALSE; } int FindGoodPolygon(XOff, YOff, PolygonObj) int XOff, YOff; struct ObjRec *PolygonObj; /* XOff and YOff are screen offsets */ { struct PolygonRec *polygon_ptr=PolygonObj->detail.g; int fill=polygon_ptr->fill, trans_pat=PolygonObj->trans_pat; if (colorLayers && PolygonObj->tmp_parent == NULL && !ObjInVisibleLayer(PolygonObj)) { return FALSE; } if (PolygonObj->ctm == NULL) { if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (PointInPolygon(XOff, YOff, polygon_ptr->sn, polygon_ptr->svlist)) { return TRUE; } } return PointOnPoly(XOff, YOff, polygon_ptr->sn, polygon_ptr->svlist, ZOOMED_HALF_W(polygon_ptr->width)); } else if (polygon_ptr->rotated_vlist != NULL) { if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (PointInPolygon(XOff, YOff, polygon_ptr->rotated_n, polygon_ptr->rotated_vlist)) { return TRUE; } } return PointOnPoly(XOff, YOff, polygon_ptr->rotated_n, polygon_ptr->rotated_vlist, ZOOMED_HALF_W(polygon_ptr->width)); } return FALSE; } static int PointInFlatPie(Y,dir,angle,ov_int_y1,ov_int_y2,rad_int_y1,rad_int_y2) int Y, dir, angle; double ov_int_y1, ov_int_y2, rad_int_y1, rad_int_y2; { switch (dir) { case ARC_CCW: switch ((angle+360)%360) { case 0: if (ov_int_y2 > rad_int_y1) { if (Y>=rad_int_y2 && rad_int_y1>=Y) return TRUE; } else if (ov_int_y2 > rad_int_y2) { if (Y>=rad_int_y2 && ov_int_y2>=Y) return TRUE; } break; case 90: if (ov_int_y1 < rad_int_y2) { if (Y>=rad_int_y2 && rad_int_y1>=Y) return TRUE; } else if (ov_int_y1 < rad_int_y1) { if (Y>=ov_int_y1 && rad_int_y1>=Y) return TRUE; } break; case 180: if (ov_int_y1 < rad_int_y1) { if (Y>=rad_int_y1 && rad_int_y2>=Y) return TRUE; } else if (ov_int_y1 < rad_int_y2) { if (Y>=ov_int_y1 && rad_int_y2>=Y) return TRUE; } break; case 270: if (ov_int_y2 > rad_int_y2) { if (Y>=rad_int_y1 && rad_int_y2>=Y) return TRUE; } else if (ov_int_y2 > rad_int_y1) { if (Y>=rad_int_y1 && ov_int_y2>=Y) return TRUE; } break; } break; case ARC_CW: switch ((angle+360)%360) { case 0: if (ov_int_y1 < rad_int_y1) { if (Y>=rad_int_y1 && rad_int_y2>=Y) return TRUE; } else if (ov_int_y1 < rad_int_y2) { if (Y>=ov_int_y1 && rad_int_y2>=Y) return TRUE; } break; case 90: if (ov_int_y1 < rad_int_y2) { if (Y>=rad_int_y2 && rad_int_y1>=Y) return TRUE; } else if (ov_int_y1 < rad_int_y1) { if (Y>=ov_int_y1 && rad_int_y1>=Y) return TRUE; } break; case 180: if (ov_int_y2 > rad_int_y1) { if (Y>=rad_int_y2 && rad_int_y1>=Y) return TRUE; } else if (ov_int_y2 > rad_int_y2) { if (Y>=rad_int_y2 && ov_int_y2>=Y) return TRUE; } break; case 270: if (ov_int_y2 > rad_int_y2) { if (Y>=rad_int_y1 && rad_int_y2>=Y) return TRUE; } else if (ov_int_y2 > rad_int_y1) { if (Y>=rad_int_y1 && ov_int_y2>=Y) return TRUE; } break; } break; } return FALSE; } static int PointInTallPie(X,dir,angle,ov_int_x1,ov_int_x2,rad_int_x1,rad_int_x2) int X, dir, angle; double ov_int_x1, ov_int_x2, rad_int_x1, rad_int_x2; { switch (dir) { case ARC_CCW: switch ((angle+360)%360) { case 0: if (ov_int_x2 > rad_int_x2) { if (X>=rad_int_x1 && rad_int_x2>=X) return TRUE; } else if (ov_int_x2 > rad_int_x1) { if (X>=rad_int_x1 && ov_int_x2>=X) return TRUE; } break; case 90: if (ov_int_x2 > rad_int_x1) { if (X>=rad_int_x2 && rad_int_x1>=X) return TRUE; } else if (ov_int_x2 > rad_int_x2) { if (X>=rad_int_x2 && ov_int_x2>=X) return TRUE; } break; case 180: if (ov_int_x1 < rad_int_x2) { if (X>=rad_int_x2 && rad_int_x1>=X) return TRUE; } else if (ov_int_x1 < rad_int_x1) { if (X>=ov_int_x1 && rad_int_x1>=X) return TRUE; } break; case 270: if (ov_int_x1 < rad_int_x1) { if (X>=rad_int_x1 && rad_int_x2>=X) return TRUE; } else if (ov_int_x1 < rad_int_x2) { if (X>=ov_int_x1 && rad_int_x2>=X) return TRUE; } break; } break; case ARC_CW: switch ((angle+360)%360) { case 0: if (ov_int_x2 > rad_int_x2) { if (X>=rad_int_x1 && rad_int_x2>=X) return TRUE; } else if (ov_int_x2 > rad_int_x1) { if (X>=rad_int_x1 && ov_int_x2>=X) return TRUE; } break; case 90: if (ov_int_x1 < rad_int_x1) { if (X>=rad_int_x1 && rad_int_x2>=X) return TRUE; } else if (ov_int_x1 < rad_int_x2) { if (X>=ov_int_x1 && rad_int_x2>=X) return TRUE; } break; case 180: if (ov_int_x1 < rad_int_x2) { if (X>=rad_int_x2 && rad_int_x1>=X) return TRUE; } else if (ov_int_x1 < rad_int_x1) { if (X>=ov_int_x1 && rad_int_x1>=X) return TRUE; } break; case 270: if (ov_int_x2 > rad_int_x1) { if (X>=rad_int_x2 && rad_int_x1>=X) return TRUE; } else if (ov_int_x2 > rad_int_x2) { if (X>=rad_int_x2 && ov_int_x2>=X) return TRUE; } break; } break; } return FALSE; } static int XInPieRange(X, dir, angle, cx, rx) int X, dir, angle; double cx, rx; { switch (dir) { case ARC_CCW: switch ((angle+360)%360) { case 0: case 90: return (X>=cx && cx+rx>=X); case 180: case 270: return (X>=cx-rx && cx>=X); } break; case ARC_CW: switch ((angle+360)%360) { case 0: case 270: return (X>=cx && cx+rx>=X); case 90: case 180: return (X>=cx-rx && cx>=X); } break; } return FALSE; } static int YInPieRange(Y, dir, angle, cy, ry) int Y, dir, angle; double cy, ry; { switch (dir) { case ARC_CCW: switch ((angle+360)%360) { case 0: case 270: return (Y>=cy && cy+ry>=Y); case 90: case 180: return (Y>=cy-ry && cy>=Y); } break; case ARC_CW: switch ((angle+360)%360) { case 0: case 90: return (Y>=cy-ry && cy>=Y); case 180: case 270: return (Y>=cy && cy+ry>=Y); } break; } return FALSE; } int FindGoodArc(XOff, YOff, ArcObj) int XOff, YOff; struct ObjRec *ArcObj; /* XOff and YOff are screen offsets */ { struct ArcRec *arc_ptr=ArcObj->detail.a; int w, h, ltx, lty, rbx, rby, aw, ah, dx, dy, theta=0; double cx, cy, rx, ry, tmp_x, tmp_y, x=0.0, y=0.0; double ov_int_x1=0.0, ov_int_x2=0.0; double ov_int_y1=0.0, ov_int_y2=0.0; double rad_int_x1=0.0, rad_int_x2=0.0; double rad_int_y1=0.0, rad_int_y2=0.0; double len, sine, cosine; int fill=arc_ptr->fill, angle1, angle2, trans_pat=ArcObj->trans_pat; int arc_x1, arc_y1, arc_x2, arc_y2, theta1, theta2; int pass_theta1, just_pass_theta1, angle, dir, full_circle; XPoint tmp_v[4]; if (colorLayers && ArcObj->tmp_parent == NULL && !ObjInVisibleLayer(ArcObj)) { return FALSE; } if (ArcObj->ctm != NULL) { if (arc_ptr->rotated_vlist == NULL) { return FALSE; } if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (PointInPolygon(XOff, YOff, arc_ptr->rotated_n+2, arc_ptr->rotated_vlist)) { return TRUE; } } return PointOnPoly(XOff, YOff, arc_ptr->rotated_n, arc_ptr->rotated_vlist, ZOOMED_HALF_W(arc_ptr->width)); } ltx = OFFSET_X(arc_ptr->ltx); lty = OFFSET_Y(arc_ptr->lty); rbx = OFFSET_X(arc_ptr->ltx+arc_ptr->w); rby = OFFSET_Y(arc_ptr->lty+arc_ptr->h); if (ltx==rbx && lty==rby) return FALSE; rx = (rbx-ltx)/2; ry = (rby-lty)/2; cx = (double)(OFFSET_X(arc_ptr->xc)); cy = (double)(OFFSET_Y(arc_ptr->yc)); arc_x1 = OFFSET_X(arc_ptr->x1); arc_y1 = OFFSET_Y(arc_ptr->y1); dir = arc_ptr->dir; theta1 = (int)(arc_ptr->angle1)/64; theta2 = theta1 + (int)(arc_ptr->angle2)/64; ArcRealX2Y2 (arc_ptr, &arc_x2, &arc_y2); arc_x2 = OFFSET_X(arc_x2); arc_y2 = OFFSET_Y(arc_y2); if (theta2 < -180) theta2 += 360; if (theta2 > 180) theta2 -= 360; if (theta1 < 0) theta1 += 360; if (theta2 <= 0) theta2 += 360; angle1 = arc_ptr->angle1; angle2 = arc_ptr->angle2; full_circle = (abs(angle2) == 64*360); if (rx >= ry) { /* flat oval */ tmp_y = (double)sqrt(fabs((double)(ry*ry*(1 - (((double)XOff)-cx)*(((double)XOff)-cx)/rx/rx)))); ov_int_y1 = cy - tmp_y; ov_int_y2 = cy + tmp_y; } else { /* tall oval */ tmp_x = (double)sqrt(fabs((double)(rx*rx*(1 - (((double)YOff)-cy)*(((double)YOff)-cy)/ry/ry)))); ov_int_x1 = cx - tmp_x; ov_int_x2 = cx + tmp_x; } w = ZOOMED_HALF_W(arc_ptr->width)+4; if (rx >= ry) { /* flat oval */ if (fabs(arc_x1-cx) < INT_TOL) { switch (theta1) { case 90: rad_int_y1 = cy - 1/INT_TOL; break; case 270: rad_int_y1 = cy + 1/INT_TOL; break; default: fprintf(stderr, "theta1 = %1d (flat)\n", theta1); break; } } else { rad_int_y1 = cy + (XOff-cx)*(arc_y1-cy)/(arc_x1-cx); } if (fabs(arc_x2-cx) < INT_TOL) { switch (theta2) { case 90: rad_int_y2 = cy - 1/INT_TOL; break; case 270: rad_int_y2 = cy + 1/INT_TOL; break; default: fprintf(stderr, "theta2 = %1d (flat)\n", theta2); break; } } else { rad_int_y2 = cy + (XOff-cx)*(arc_y2-cy)/(arc_x2-cx); } } else { /* tall oval */ if (fabs(arc_y1-cy) < INT_TOL) { switch (theta1) { case 0: case 360: rad_int_x1 = cx + 1/INT_TOL; break; case 180: rad_int_x1 = cx - 1/INT_TOL; break; default: fprintf(stderr, "theta1 = %1d (tall)\n", theta1); break; } } else { rad_int_x1 = cx + (YOff-cy)*(arc_x1-cx)/(arc_y1-cy); } if (fabs(arc_y2-cy) < INT_TOL) { switch (theta2) { case 0: case 360: rad_int_x2 = cx + 1/INT_TOL; break; case 180: rad_int_x2 = cx - 1/INT_TOL; break; default: fprintf(stderr, "theta2 = %1d (tall)\n", theta2); break; } } else { rad_int_x2 = cx + (YOff-cy)*(arc_x2-cx)/(arc_y2-cy); } } if (dir == ARC_CCW) { angle = 0; pass_theta1 = FALSE; just_pass_theta1 = FALSE; while (angle < theta2 || !pass_theta1) { if (angle >= theta1 && !pass_theta1) { pass_theta1 = TRUE; just_pass_theta1 = TRUE; if (theta2 > theta1 && angle >= theta2 && !full_circle) { /* theta1 and theta2 are in the same quadrant */ if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (rx >= ry) { /* flat oval */ if (PointInFlatPie(YOff, dir, angle, ov_int_y1, ov_int_y2, rad_int_y1, rad_int_y2)) { return TRUE; } } else { /* tall oval */ if (PointInTallPie(XOff, dir, angle, ov_int_x1, ov_int_x2, rad_int_x1, rad_int_x2)) { return TRUE; } } } if (rx >= ry) { /* flat oval */ switch ((angle+360)%360) { case 0: case 270: return (XOff>=arc_x1 && arc_x2>=XOff && (fabs((double)(YOff-ov_int_y2)) <= w)); case 90: case 180: return (XOff>=arc_x2 && arc_x1>=XOff && (fabs((double)(YOff-ov_int_y1)) <= w)); } } else { /* tall oval */ switch ((angle+360)%360) { case 0: case 90: return (YOff>=arc_y2 && arc_y1>=YOff && (fabs((double)(XOff-ov_int_x2)) <= w)); case 180: case 270: return (YOff>=arc_y1 && arc_y2>=YOff && (fabs((double)(XOff-ov_int_x1)) <= w)); } } } if (theta2 <= theta1) angle -= 360; if (angle > theta2) angle -= 360; } if (just_pass_theta1) { just_pass_theta1 = FALSE; if (rx >= ry) { /* flat oval */ switch ((angle+360)%360) { case 0: y = cy; break; case 90: y = cy-ry; break; case 180: y = cy; break; case 270: y = cy+ry; break; } if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (XInPieRange(XOff, dir, angle, cx, rx) && PointInFlatPie (YOff, dir, angle, ov_int_y1, ov_int_y2, rad_int_y1, y)) { return TRUE; } } switch ((angle+360)%360) { case 0: if (XOff>=arc_x1 && cx+rx>=XOff && (fabs((double)(YOff-ov_int_y2)) <= w)) { return TRUE; } break; case 90: if (XOff>=cx && arc_x1>=XOff && (fabs((double)(YOff-ov_int_y1)) <= w)) { return TRUE; } break; case 180: if (XOff>=cx-rx && arc_x1>=XOff && (fabs((double)(YOff-ov_int_y1)) <= w)) { return TRUE; } break; case 270: if (XOff>=arc_x1 && cx>=XOff && (fabs((double)(YOff-ov_int_y2)) <= w)) { return TRUE; } break; } } else { /* tall oval */ switch ((angle+360)%360) { case 0: x = cx+rx; break; case 90: x = cx; break; case 180: x = cx-rx; break; case 270: x = cx; break; } if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (YInPieRange(YOff, dir, angle, cy, ry) && PointInTallPie(XOff, dir, angle, ov_int_x1, ov_int_x2, rad_int_x1, x)) { return TRUE; } } switch ((angle+360)%360) { case 0: if (YOff>=cy && arc_y1>=YOff && (fabs((double)(XOff-ov_int_x2)) <= w)) { return TRUE; } break; case 90: if (YOff>=cy-ry && arc_y1>=YOff && (fabs((double)(XOff-ov_int_x2)) <= w)) { return TRUE; } break; case 180: if (YOff>=arc_y1 && cy>=YOff && (fabs((double)(XOff-ov_int_x1)) <= w)) { return TRUE; } break; case 270: if (YOff>=arc_y1 && cy+ry>=YOff && (fabs((double)(XOff-ov_int_x1)) <= w)) { return TRUE; } break; } } } else if (pass_theta1) { /* see if point is in the quadrant */ if (rx >= ry) { /* flat oval */ if (XInPieRange(XOff, dir, angle, cx, rx)) { if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { switch ((angle+360)%360) { case 90: case 180: if (YOff>=ov_int_y1 && cy>=YOff) return TRUE; break; case 0: case 270: if (YOff>=cy && ov_int_y2>=YOff) return TRUE; break; } } switch ((angle+360)%360) { case 0: case 270: if (fabs((double)(YOff-ov_int_y2)) <= w) return TRUE; break; case 90: case 180: if (fabs((double)(YOff-ov_int_y1)) <= w) return TRUE; break; } } } else { /* tall oval */ if (YInPieRange(YOff, dir, angle, cy, ry)) { if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { switch ((angle+360)%360) { case 0: case 90: if (XOff>=cx && ov_int_x2>=XOff) return TRUE; break; case 180: case 270: if (XOff>=ov_int_x1 && cx>=XOff) return TRUE; break; } } switch ((angle+360)%360) { case 0: case 90: if (fabs((double)(XOff-ov_int_x2)) <= w) return TRUE; break; case 180: case 270: if (fabs((double)(XOff-ov_int_x1)) <= w) return TRUE; break; } } } } angle = (angle == 360) ? 0 : (angle+90); } if (rx >= ry) { /* flat oval */ switch ((angle+360)%360) { case 0: y = cy+ry; break; case 180: y = cy-ry; break; case 90: case 270: y = cy; break; } if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (XInPieRange(XOff, dir, angle, cx, rx) && PointInFlatPie(YOff, dir, angle, ov_int_y1, ov_int_y2, y, rad_int_y2)) { return TRUE; } } switch ((angle+360)%360) { case 0: if (XOff>=cx && arc_x2>=XOff && (fabs((double)(YOff-ov_int_y2)) <= w)) { return TRUE; } break; case 90: if (XOff>=arc_x2 && cx+rx>=XOff && (fabs((double)(YOff-ov_int_y1)) <= w)) { return TRUE; } break; case 180: if (XOff>=arc_x2 && cx>=XOff && (fabs((double)(YOff-ov_int_y1)) <= w)) { return TRUE; } break; case 270: if (XOff>=cx-rx && arc_x2>=XOff && (fabs((double)(YOff-ov_int_y2)) <= w)) { return TRUE; } break; } } else { /* tall oval */ switch ((angle+360)%360) { case 0: case 180: x = cx; break; case 90: x = cx+rx; break; case 270: x = cx-rx; break; } if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (YInPieRange(YOff, dir, angle, cy, ry) && PointInTallPie(XOff, dir, angle, ov_int_x1, ov_int_x2, x, rad_int_x2)) { return TRUE; } } switch ((angle+360)%360) { case 0: if (YOff>=arc_y2 && cy+ry>=YOff && (fabs((double)(XOff-ov_int_x2)) <= w)) { return TRUE; } break; case 90: if (YOff>=arc_y2 && cy>=YOff && (fabs((double)(XOff-ov_int_x2)) <= w)) { return TRUE; } break; case 180: if (YOff>=cy-ry && arc_y2>=YOff && (fabs((double)(XOff-ov_int_x1)) <= w)) { return TRUE; } break; case 270: if (YOff>=cy && arc_y2>=YOff && (fabs((double)(XOff-ov_int_x1)) <= w)) { return TRUE; } break; } } } else { angle = 360; pass_theta1 = FALSE; just_pass_theta1 = FALSE; while (angle > theta2 || !pass_theta1) { if (angle <= theta1 && !pass_theta1) { pass_theta1 = TRUE; just_pass_theta1 = TRUE; if (theta2 < theta1 && angle <= theta2 && !full_circle) { /* theta1 and theta2 are in the same quadrant */ if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (rx >= ry) { if (PointInFlatPie(YOff, dir, angle, ov_int_y1, ov_int_y2, rad_int_y1, rad_int_y2)) { return TRUE; } } else { if (PointInTallPie(XOff, dir, angle, ov_int_x1, ov_int_x2, rad_int_x1, rad_int_x2)) { return TRUE; } } } if (rx >= ry) { /* flat oval */ switch ((angle+360)%360) { case 0: case 90: return (XOff>=arc_x1 && arc_x2>=XOff && (fabs((double)(YOff-ov_int_y1)) <= w)); case 180: case 270: return (XOff>=arc_x2 && arc_x1>=XOff && (fabs((double)(YOff-ov_int_y2)) <= w)); } } else { /* tall oval */ switch ((angle+360)%360) { case 0: case 270: return (YOff>=arc_y1 && arc_y2>=YOff && (fabs((double)(XOff-ov_int_x2)) <= w)); case 90: case 180: return (YOff>=arc_y2 && arc_y1>=YOff && (fabs((double)(XOff-ov_int_x1)) <= w)); } } } if (theta2 >= theta1) angle += 360; if (angle <= theta2) angle += 360; } if (just_pass_theta1) { just_pass_theta1 = FALSE; if (rx >= ry) { /* flat oval */ switch ((angle+360)%360) { case 0: y = cy; break; case 90: y = cy-ry; break; case 180: y = cy; break; case 270: y = cy+ry; break; } if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (XInPieRange(XOff, dir, angle, cx, rx) && PointInFlatPie(YOff, dir, angle, ov_int_y1, ov_int_y2, rad_int_y1, y)) { return TRUE; } } switch ((angle+360)%360) { case 0: if (XOff>=arc_x1 && cx+rx>=XOff && (fabs((double)(YOff-ov_int_y1)) <= w)) { return TRUE; } break; case 90: if (XOff>=arc_x1 && cx>=XOff && (fabs((double)(YOff-ov_int_y1)) <= w)) { return TRUE; } break; case 180: if (XOff>=cx-rx && arc_x1>=XOff && (fabs((double)(YOff-ov_int_y2)) <= w)) { return TRUE; } break; case 270: if (XOff>=cx && arc_x1>=XOff && (fabs((double)(YOff-ov_int_y2)) <= w)) { return TRUE; } break; } } else { /* tall oval */ switch ((angle+360)%360) { case 0: x = cx+rx; break; case 90: x = cx; break; case 180: x = cx-rx; break; case 270: x = cx; break; } if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (YInPieRange(YOff, dir, angle, cy, ry) && PointInTallPie(XOff, dir, angle, ov_int_x1, ov_int_x2, rad_int_x1, x)) { return TRUE; } } switch ((angle+360)%360) { case 0: if (YOff>=arc_y1 && cy>=YOff && (fabs((double)(XOff-ov_int_x2)) <= w)) { return TRUE; } break; case 90: if (YOff>=cy-ry && arc_y1>=YOff && (fabs((double)(XOff-ov_int_x1)) <= w)) { return TRUE; } break; case 180: if (YOff>=cy && arc_y1>=YOff && (fabs((double)(XOff-ov_int_x1)) <= w)) { return TRUE; } break; case 270: if (YOff>=arc_y1 && cy+ry>=YOff && (fabs((double)(XOff-ov_int_x2)) <= w)) { return TRUE; } break; } } } else if (pass_theta1) { /* see if point is in the quadrant */ if (rx >= ry) { /* flat oval */ if (XInPieRange(XOff, dir, angle, cx, rx)) { if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { switch ((angle+360)%360) { case 0: case 90: if (YOff>=ov_int_y1 && cy>=YOff) return TRUE; break; case 180: case 270: if (YOff>=cy && ov_int_y2>=YOff) return TRUE; break; } } switch ((angle+360)%360) { case 0: case 90: if (fabs((double)(YOff-ov_int_y1)) <= w) return TRUE; break; case 180: case 270: if (fabs((double)(YOff-ov_int_y2)) <= w) return TRUE; break; } } } else { /* tall oval */ if (YInPieRange(YOff, dir, angle, cy, ry)) { if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { switch ((angle+360)%360) { case 0: case 270: if (XOff>=cx && ov_int_x2>=XOff) return TRUE; break; case 90: case 180: if (XOff>=ov_int_x1 && cx>=XOff) return TRUE; break; } } switch ((angle+360)%360) { case 0: case 270: if (fabs((double)(XOff-ov_int_x2)) <= w) return TRUE; break; case 90: case 180: if (fabs((double)(XOff-ov_int_x1)) <= w) return TRUE; break; } } } } angle = (angle == 0) ? 360 : (angle-90); } if (rx >= ry) { /* flat oval */ switch ((angle+360)%360) { case 0: y = cy-ry; break; case 180: y = cy+ry; break; case 90: case 270: y = cy; break; } if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (XInPieRange(XOff, dir, angle, cx, rx) && PointInFlatPie(YOff, dir, angle, ov_int_y1, ov_int_y2, y, rad_int_y2)) { return TRUE; } } switch ((angle+360)%360) { case 0: if (XOff>=cx && arc_x2>=XOff && (fabs((double)(YOff-ov_int_y1)) <= w)) { return TRUE; } break; case 90: if (XOff>=cx-rx && arc_x2>=XOff && (fabs((double)(YOff-ov_int_y1)) <= w)) { return TRUE; } break; case 180: if (XOff>=arc_x2 && cx>=XOff && (fabs((double)(YOff-ov_int_y2)) <= w)) { return TRUE; } break; case 270: if (XOff>=arc_x2 && cx+rx>=XOff && (fabs((double)(YOff-ov_int_y2)) <= w)) { return TRUE; } break; } } else { /* tall oval */ switch ((angle+360)%360) { case 0: case 180: x = cx; break; case 90: x = cx-rx; break; case 270: x = cx+rx; break; } if (!(fill == NONEPAT || (fill == BACKPAT && trans_pat))) { if (YInPieRange(YOff, dir, angle, cy, ry) && PointInTallPie(XOff, dir, angle, ov_int_x1, ov_int_x2, x, rad_int_x2)) { return TRUE; } } switch ((angle+360)%360) { case 0: if (YOff>=cy-ry && arc_y2>=YOff && (fabs((double)(XOff-ov_int_x2)) <= w)) { return TRUE; } break; case 90: if (YOff>=arc_y2 && cy>=YOff && (fabs((double)(XOff-ov_int_x1)) <= w)) { return TRUE; } break; case 180: if (YOff>=arc_y2 && cy+ry>=YOff && (fabs((double)(XOff-ov_int_x1)) <= w)) { return TRUE; } break; case 270: if (YOff>=cy && arc_y2>=YOff && (fabs((double)(XOff-ov_int_x2)) <= w)) { return TRUE; } break; } } } w = ZOOMED_SIZE(arc_ptr->w); h = ZOOMED_SIZE(arc_ptr->h); aw = ZOOMED_SIZE(arc_ptr->aw); if (aw == 0) aw = 1; ah = ZOOMED_SIZE(arc_ptr->ah); if (ah == 0) ah = 1; if ((arc_ptr->style & LS_LEFT) && (angle2%(360<<6) != 0)) { /* the arrow should appear at angle1 */ switch (dir) { case ARC_CCW: theta = (int)(angle1/64)-90; break; case ARC_CW: theta = (int)(angle1/64)+90; break; } dx = -round(w*cos(((double)theta)*M_PI/180.0)); dy = round(h*sin(((double)theta)*M_PI/180.0)); if (dx == 0 && dy == 0) { sine = cosine = ((double)0.0); tmp_v[0].x = tmp_v[1].x = tmp_v[2].x = tmp_v[3].x = arc_x1; tmp_v[0].y = tmp_v[1].y = tmp_v[2].y = tmp_v[3].y = arc_y1; } else { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sine = dy/len; cosine = dx/len; tmp_v[0].x = tmp_v[3].x = arc_x1; tmp_v[0].y = tmp_v[3].y = arc_y1; tmp_v[1].x = round(arc_x1 + aw*cosine - ah*sine); tmp_v[1].y = round(arc_y1 + aw*sine + ah*cosine); tmp_v[2].x = round(arc_x1 + aw*cosine + ah*sine); tmp_v[2].y = round(arc_y1 + aw*sine - ah*cosine); } if (PointInPolygon(XOff, YOff, 4, tmp_v)) return TRUE; } if ((arc_ptr->style & LS_RIGHT) && (angle2%(360<<6) != 0)) { switch (dir) { case ARC_CCW: theta = (int)((angle1+angle2)/64)-90; break; case ARC_CW: theta = (int)((angle1+angle2)/64)+90; break; } dx = -round(w*cos(((double)theta)*M_PI/180.0)); dy = round(h*sin(((double)theta)*M_PI/180.0)); if (dx == 0 && dy == 0) { sine = cosine = ((double)0.0); tmp_v[0].x = tmp_v[1].x = tmp_v[2].x = tmp_v[3].x = arc_x2; tmp_v[0].y = tmp_v[1].y = tmp_v[2].y = tmp_v[3].y = arc_y2; } else { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sine = dy/len; cosine = dx/len; tmp_v[0].x = tmp_v[3].x = arc_x2; tmp_v[0].y = tmp_v[3].y = arc_y2; tmp_v[1].x = round(arc_x2 - aw*cosine + ah*sine); tmp_v[1].y = round(arc_y2 - aw*sine - ah*cosine); tmp_v[2].x = round(arc_x2 - aw*cosine - ah*sine); tmp_v[2].y = round(arc_y2 - aw*sine + ah*cosine); } if (PointInPolygon(XOff, YOff, 4, tmp_v)) return TRUE; } return FALSE; } int FindGoodObj(XOff, YOff, FirstObj, SubObj, ImmediateChildObj) int XOff, YOff; struct ObjRec *FirstObj, **SubObj, **ImmediateChildObj; /* XOff and YOff are screen offsets */ { register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; *SubObj = NULL; for (obj_ptr=FirstObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { obj_ptr->tmp_child = NULL; if (ImmediateChildObj != NULL) *ImmediateChildObj = obj_ptr; if (colorLayers && !ObjInVisibleLayer(obj_ptr)) { continue; } for (attr_ptr=obj_ptr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown && XOff >= OFFSET_X(attr_ptr->obj->bbox.ltx)-3 && YOff >= OFFSET_Y(attr_ptr->obj->bbox.lty)-3 && XOff <= OFFSET_X(attr_ptr->obj->bbox.rbx)+3 && YOff <= OFFSET_Y(attr_ptr->obj->bbox.rby)+3) { *SubObj = attr_ptr->obj; return TRUE; } } if (XOff >= OFFSET_X(obj_ptr->bbox.ltx)-3 && YOff >= OFFSET_Y(obj_ptr->bbox.lty)-3 && XOff <= OFFSET_X(obj_ptr->bbox.rbx)+3 && YOff <= OFFSET_Y(obj_ptr->bbox.rby)+3) { struct ObjRec *next_level_child=NULL, *visible_obj=NULL; switch (obj_ptr->type) { case OBJ_TEXT: if (FindGoodText(XOff, YOff, obj_ptr)) return TRUE; break; case OBJ_XBM: if (FindGoodXBm(XOff, YOff, obj_ptr)) return TRUE; break; case OBJ_XPM: if (FindGoodXPm(XOff, YOff, obj_ptr)) return TRUE; break; case OBJ_BOX: if (FindGoodBox(XOff, YOff, obj_ptr)) return TRUE; break; case OBJ_RCBOX: if (FindGoodRCBox(XOff, YOff, obj_ptr)) return TRUE; break; case OBJ_OVAL: if (FindGoodOval(XOff, YOff, obj_ptr)) return TRUE; break; case OBJ_POLY: if (FindGoodPoly(XOff, YOff, obj_ptr)) return TRUE; break; case OBJ_POLYGON: if (FindGoodPolygon(XOff, YOff, obj_ptr)) return TRUE; break; case OBJ_ARC: if (FindGoodArc(XOff, YOff, obj_ptr)) return TRUE; break; case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: if (colorLayers) { struct ObjRec *tmp_obj; for (tmp_obj=obj_ptr->detail.r->first; tmp_obj != NULL; tmp_obj=tmp_obj->next) { tmp_obj->tmp_parent = obj_ptr; } } if (FindGoodObj(XOff, YOff, obj_ptr->detail.r->first, SubObj, &next_level_child)) { obj_ptr->tmp_child = next_level_child; return TRUE; } break; case OBJ_PIN: visible_obj = GetPinObj(obj_ptr); if (colorLayers) { struct ObjRec *tmp_obj; visible_obj->tmp_parent = obj_ptr; for (tmp_obj=visible_obj->detail.r->first; tmp_obj != NULL; tmp_obj=tmp_obj->next) { tmp_obj->tmp_parent = visible_obj; } } obj_ptr->tmp_child = visible_obj; if (FindGoodObj(XOff, YOff, visible_obj->detail.r->first, SubObj, &next_level_child)) { visible_obj->tmp_child = next_level_child; return TRUE; } break; } } } if (ImmediateChildObj != NULL) *ImmediateChildObj = NULL; return FALSE; } tgif-QPL-4.2.5/cursor.e0000644000076400007640000000553411602233311014455 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/cursor.e,v 1.6 2011/05/16 16:21:57 william Exp $ */ #ifndef _CURSOR_E_ #define _CURSOR_E_ extern Cursor nullCursor; extern Cursor cornerCursor; extern Cursor handCursor; extern Cursor defaultCursor; extern Cursor watchCursor; extern Cursor drawCursor; extern Cursor freehandCursor; extern Cursor vertexCursor; extern Cursor rotateCursor; extern Cursor rotatingCursor; extern Cursor horiShearCursor; extern Cursor vertShearCursor; extern Cursor moveCursor; extern Cursor textCursor; extern Cursor hyperSpaceCursor; extern Cursor magCursor; extern Cursor floodCursor; extern Cursor dripCursor; extern int watchCursorOnMainWindow; #ifdef _INCLUDE_FROM_CURSOR_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_CURSOR_C_*/ extern void SetTextCursor ARGS_DECL((Window)); extern void SetNullCursor ARGS_DECL((Window)); extern void SetWatchCursor ARGS_DECL((Window)); extern void SetDrawCursor ARGS_DECL((Window)); extern void SetFreeHandCursor ARGS_DECL((Window)); extern void SetVertexCursor ARGS_DECL((Window)); extern void SetRotateCursor ARGS_DECL((Window)); extern void SetRotatingCursor ARGS_DECL((Window)); extern void SetHoriShearCursor ARGS_DECL((Window)); extern void SetVertShearCursor ARGS_DECL((Window)); extern void SetMoveCursor ARGS_DECL((Window)); extern void SetHyperSpaceCursor ARGS_DECL((Window)); extern void SetFloodFillCursor ARGS_DECL((Window)); extern void SetDripCursor ARGS_DECL((Window)); extern void SetHandCursor ARGS_DECL((Window)); extern void SetDefaultCursor ARGS_DECL((Window)); extern void ShowCursor ARGS_DECL((void)); extern void CreateCursor ARGS_DECL((void)); extern void PutCursor ARGS_DECL((Window, int X, int Y, int Foreground)); extern void CleanUpCursors ARGS_DECL((void)); extern Cursor NewFontCursor ARGS_DECL((char*)); extern void SetWindowCursor ARGS_DECL((Window, Cursor)); extern void DeleteFontCursor ARGS_DECL((Cursor)); #ifdef _INCLUDE_FROM_CURSOR_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_CURSOR_C_*/ #endif /*_CURSOR_E_*/ tgif-QPL-4.2.5/missing0000755000076400007640000002557711602233316014407 0ustar williamwilliam#! /bin/sh # Common stub for a few missing GNU programs while installing. scriptversion=2006-05-10.23 # Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006 # Free Software Foundation, Inc. # Originally by Fran,cois Pinard , 1996. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301, USA. # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. if test $# -eq 0; then echo 1>&2 "Try \`$0 --help' for more information" exit 1 fi run=: sed_output='s/.* --output[ =]\([^ ]*\).*/\1/p' sed_minuso='s/.* -o \([^ ]*\).*/\1/p' # In the cases where this matters, `missing' is being run in the # srcdir already. if test -f configure.ac; then configure_ac=configure.ac else configure_ac=configure.in fi msg="missing on your system" case $1 in --run) # Try to run requested program, and just exit if it succeeds. run= shift "$@" && exit 0 # Exit code 63 means version mismatch. This often happens # when the user try to use an ancient version of a tool on # a file that requires a minimum version. In this case we # we should proceed has if the program had been absent, or # if --run hadn't been passed. if test $? = 63; then run=: msg="probably too old" fi ;; -h|--h|--he|--hel|--help) echo "\ $0 [OPTION]... PROGRAM [ARGUMENT]... Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an error status if there is no known handling for PROGRAM. Options: -h, --help display this help and exit -v, --version output version information and exit --run try to run the given command, and emulate it if it fails Supported PROGRAM values: aclocal touch file \`aclocal.m4' autoconf touch file \`configure' autoheader touch file \`config.h.in' autom4te touch the output file, or create a stub one automake touch all \`Makefile.in' files bison create \`y.tab.[ch]', if possible, from existing .[ch] flex create \`lex.yy.c', if possible, from existing .c help2man touch the output file lex create \`lex.yy.c', if possible, from existing .c makeinfo touch the output file tar try tar, gnutar, gtar, then tar without non-portable flags yacc create \`y.tab.[ch]', if possible, from existing .[ch] Send bug reports to ." exit $? ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) echo "missing $scriptversion (GNU Automake)" exit $? ;; -*) echo 1>&2 "$0: Unknown \`$1' option" echo 1>&2 "Try \`$0 --help' for more information" exit 1 ;; esac # Now exit if we have it, but it failed. Also exit now if we # don't have it and --version was passed (most likely to detect # the program). case $1 in lex|yacc) # Not GNU programs, they don't have --version. ;; tar) if test -n "$run"; then echo 1>&2 "ERROR: \`tar' requires --run" exit 1 elif test "x$2" = "x--version" || test "x$2" = "x--help"; then exit 1 fi ;; *) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 elif test "x$2" = "x--version" || test "x$2" = "x--help"; then # Could not run --version or --help. This is probably someone # running `$TOOL --version' or `$TOOL --help' to check whether # $TOOL exists and not knowing $TOOL uses missing. exit 1 fi ;; esac # If it does not exist, or fails to run (possibly an outdated version), # try to emulate it. case $1 in aclocal*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." touch aclocal.m4 ;; autoconf) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." touch configure ;; autoheader) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`acconfig.h' or \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}` test -z "$files" && files="config.h" touch_files= for f in $files; do case $f in *:*) touch_files="$touch_files "`echo "$f" | sed -e 's/^[^:]*://' -e 's/:.*//'`;; *) touch_files="$touch_files $f.in";; esac done touch $touch_files ;; automake*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." find . -type f -name Makefile.am -print | sed 's/\.am$/.in/' | while read f; do touch "$f"; done ;; autom4te) echo 1>&2 "\ WARNING: \`$1' is needed, but is $msg. You might have modified some files without having the proper tools for further handling them. You can get \`$1' as part of \`Autoconf' from any GNU archive site." file=`echo "$*" | sed -n "$sed_output"` test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` if test -f "$file"; then touch $file else test -z "$file" || exec >$file echo "#! /bin/sh" echo "# Created by GNU Automake missing as a replacement of" echo "# $ $@" echo "exit 0" chmod +x $file exit 1 fi ;; bison|yacc) echo 1>&2 "\ WARNING: \`$1' $msg. You should only need it if you modified a \`.y' file. You may need the \`Bison' package in order for those modifications to take effect. You can get \`Bison' from any GNU archive site." rm -f y.tab.c y.tab.h if test $# -ne 1; then eval LASTARG="\${$#}" case $LASTARG in *.y) SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'` if test -f "$SRCFILE"; then cp "$SRCFILE" y.tab.c fi SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'` if test -f "$SRCFILE"; then cp "$SRCFILE" y.tab.h fi ;; esac fi if test ! -f y.tab.h; then echo >y.tab.h fi if test ! -f y.tab.c; then echo 'main() { return 0; }' >y.tab.c fi ;; lex|flex) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a \`.l' file. You may need the \`Flex' package in order for those modifications to take effect. You can get \`Flex' from any GNU archive site." rm -f lex.yy.c if test $# -ne 1; then eval LASTARG="\${$#}" case $LASTARG in *.l) SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'` if test -f "$SRCFILE"; then cp "$SRCFILE" lex.yy.c fi ;; esac fi if test ! -f lex.yy.c; then echo 'main() { return 0; }' >lex.yy.c fi ;; help2man) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a dependency of a manual page. You may need the \`Help2man' package in order for those modifications to take effect. You can get \`Help2man' from any GNU archive site." file=`echo "$*" | sed -n "$sed_output"` test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` if test -f "$file"; then touch $file else test -z "$file" || exec >$file echo ".ab help2man is required to generate this page" exit 1 fi ;; makeinfo) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a \`.texi' or \`.texinfo' file, or any other file indirectly affecting the aspect of the manual. The spurious call might also be the consequence of using a buggy \`make' (AIX, DU, IRIX). You might want to install the \`Texinfo' package or the \`GNU make' package. Grab either from any GNU archive site." # The file to touch is that specified with -o ... file=`echo "$*" | sed -n "$sed_output"` test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` if test -z "$file"; then # ... or it is the one specified with @setfilename ... infile=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'` file=`sed -n ' /^@setfilename/{ s/.* \([^ ]*\) *$/\1/ p q }' $infile` # ... or it is derived from the source name (dir/f.texi becomes f.info) test -z "$file" && file=`echo "$infile" | sed 's,.*/,,;s,.[^.]*$,,'`.info fi # If the file does not exist, the user really needs makeinfo; # let's fail without touching anything. test -f $file || exit 1 touch $file ;; tar) shift # We have already tried tar in the generic part. # Look for gnutar/gtar before invocation to avoid ugly error # messages. if (gnutar --version > /dev/null 2>&1); then gnutar "$@" && exit 0 fi if (gtar --version > /dev/null 2>&1); then gtar "$@" && exit 0 fi firstarg="$1" if shift; then case $firstarg in *o*) firstarg=`echo "$firstarg" | sed s/o//` tar "$firstarg" "$@" && exit 0 ;; esac case $firstarg in *h*) firstarg=`echo "$firstarg" | sed s/h//` tar "$firstarg" "$@" && exit 0 ;; esac fi echo 1>&2 "\ WARNING: I can't seem to be able to run \`tar' with the given arguments. You may want to install GNU tar or Free paxutils, or check the command line arguments." exit 1 ;; *) echo 1>&2 "\ WARNING: \`$1' is needed, and is $msg. You might have modified some files without having the proper tools for further handling them. Check the \`README' file, it often tells you about the needed prerequisites for installing this package. You may also peek at any GNU archive site, in case some other package would contain this missing \`$1' program." exit 1 ;; esac exit 0 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: tgif-QPL-4.2.5/Tgif.tmpl-osf10000644000076400007640000000466311602233313015433 0ustar williamwilliamXCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-osf1,v 1.12 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/lib/nls DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_NO_IDNLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) XCOMM SYS_LIBRARIES = -ldl -lm -lz SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM OSF1 V4.0 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM tgif-QPL-4.2.5/drawing.e0000644000076400007640000001342411602233311014570 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/drawing.e,v 1.11 2011/05/16 16:21:57 william Exp $ */ #ifndef _DRAWING_E_ #define _DRAWING_E_ extern int disableRedraw; extern int intrCheckInterval; extern int pasteInDrawTextMode; extern int pasteFromFileInDrawTextMode; extern int pasteCompoundTextInDrawTextMode; extern char pasteFromFileName[]; extern int copyInDrawTextMode; extern int copyDoubleByteStringInDrawTextMode; extern int numRedrawBBox; extern int numClipRecs; extern int clipOrdering; extern XRectangle clipRecs[]; extern int checkBBox; extern int btn1Warp; extern int userDisableRedraw; extern int executingCommands; extern int escPressedWhileExecutingCommands; extern int gnDisableShortcuts; /* used by ExecCmdsFromFile() */ extern int enableMouseWheel; extern int btn2PopupMainMenu; #ifdef _INCLUDE_FROM_DRAWING_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_DRAWING_C_*/ extern void SetXorDrawGC ARGS_DECL((int xor_pixel)); extern void SetDefaultDrawWinClipRecs ARGS_DECL((void)); extern void SetDefaultIconWinClipRecs ARGS_DECL((void)); extern void ShowInterrupt ARGS_DECL((int)); extern int HideInterrupt ARGS_DECL((void)); extern void RedrawDummyWindow1 ARGS_DECL((void)); extern void RedrawDummyWindow2 ARGS_DECL((void)); extern void DummiesEventHandler ARGS_DECL((XEvent*)); extern int KeyPressEventIsEscape ARGS_DECL((XKeyEvent*)); extern int ESCPressed ARGS_DECL((void)); extern int CheckInterrupt ARGS_DECL((int check_esc)); extern void DrawClippedPixmap ARGS_DECL((Pixmap, Window, GC, int PixmapW, int PixmapH, int LtX, int LtY)); extern void FillClippedRectangle ARGS_DECL((Window, GC, int LtX, int LtY, int OrigW, int OrigH)); extern int ObjInVisibleLayer ARGS_DECL((struct ObjRec *)); extern int DrawObj ARGS_DECL((Window, struct ObjRec *)); extern void DrawPaperBoundary ARGS_DECL((Window)); extern void RedrawAnArea ARGS_DECL((struct ObjRec *BotObj, int LtX, int LtY, int RbX, int RbY)); extern void RedrawAreas ARGS_DECL((struct ObjRec *BotObj, int LtX1, int LtY1, int RbX1, int RbY1, int LtX2, int LtY2, int RbX2, int RbY2)); extern int RedrawDuringScrolling ARGS_DECL((void)); extern void RedrawAreaFromCache ARGS_DECL((double start_frac, int scroll_all_the_way)); extern void RedrawDrawWindow ARGS_DECL((struct ObjRec *BotObj)); extern Pixmap DrawAllOnPixmap ARGS_DECL((int *LtX, int *LtY, int *W, int *H, int nRedraw)); extern void ClearAndRedrawDrawWindow ARGS_DECL((void)); extern void ClearAndRedrawDrawWindowNoCurT ARGS_DECL((void)); /* use to be ClearAndRedrawDrawWindowDontDrawCurText */ extern int BeginExecAnimate ARGS_DECL((void)); extern void EndExecAnimate ARGS_DECL((void)); extern void CleanUpDrawingWindow ARGS_DECL((void)); extern int ShortHand ARGS_DECL((XEvent *)); extern int ExecuteCmdById ARGS_DECL((int nCmdId, int nIndex)); extern int CallShortCut ARGS_DECL((char *Name, int argc, char *argv[], char *Code, unsigned int State)); extern int SomethingDirty ARGS_DECL((void)); extern void EditIndexedAttrInEditor ARGS_DECL((int index)); extern void EditIndexedAttrGroupInEditor ARGS_DECL((int index)); extern TgMenu *CreateEditAttrInEditorMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern TgMenu *CreateEditAttrGroupInEditorMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern void GetProperty ARGS_DECL((int index)); extern TgMenu *CreateGetPropertyMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern void PeekDimension ARGS_DECL((int index)); extern TgMenu *CreatePeekDimensionMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int RefreshContextMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateContextMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int RefreshEditTextContextMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateEditTextContextMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int ContextMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void HandleMotionForPortInDrawWindow ARGS_DECL((int mouse_x, int mouse_y)); extern int HandlePressForPortInDrawWindow ARGS_DECL((int cancel)); extern int DrawingEventHandler ARGS_DECL((XEvent *)); #ifdef _INCLUDE_FROM_DRAWING_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_DRAWING_C_*/ #endif /*_DRAWING_E_*/ tgif-QPL-4.2.5/License0000777000076400007640000000000011602233315015731 2LICENSE.QPLustar williamwilliamtgif-QPL-4.2.5/xprtfltr.c0000644000076400007640000004023111602233314015017 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xprtfltr.c,v 1.6 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_XPRTFLTR_C_ #include "tgifdefs.h" #include "expfdefs.h" #include "color.e" #include "dialog.e" #include "drawing.e" #include "file.e" #include "grid.e" #include "msg.e" #include "names.e" #include "obj.e" #include "page.e" #include "ps.e" #include "raster.e" #include "setup.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "xbitmap.e" #include "xprtfltr.e" #ifndef _NO_DL_SUPPORT #define CLOSE_DL(handle) dlclose(handle) #define OPEN_DL(path,flag) dlopen((path),(flag)) #define GET_DL_SYM(handle,symbol) dlsym((handle),(symbol)) #ifndef RTLD_NOW #define OPEN_DL_MODE 1 #else /* RTLD_NOW */ #define OPEN_DL_MODE (RTLD_NOW|RTLD_GLOBAL) #endif /* ~RTLD_NOW */ #else /* _NO_DL_SUPPORT */ #define CLOSE_DL(handle) #define OPEN_DL(path,flag) NULL #define GET_DL_SYM(handle,symbol) NULL #define OPEN_DL_MODE 0 #endif /* ~_NO_DL_SUPPORT */ int gnMaxExportFilters=0; Pixmap *gaExportFilterBitmaps=NULL; TgEFInfo *gpTgEFInfo=NULL; /* --------------------- Utility Functions --------------------- */ static int GetSharedLibVersion(pszPath) char *pszPath; { char *psz=UtilStrRChr(pszPath, DIR_SEP), *psz1=NULL; int nReturn=0; if (psz == NULL) { psz = pszPath; } else { psz++; } if ((psz=strchr(psz, '.')) == NULL) return 0; if ((psz=strchr(++psz, '.')) == NULL) return 0; if ((psz1=strchr(++psz, '.')) != NULL) { *psz1 = '\0'; nReturn = atoi(psz); *psz1 = '.'; } else { nReturn = atoi(psz); } return nReturn; } static long TgEFSendMsg(pTgEFInfo, nUserInfo, nMsg, nArg, pvArg) TgEFInfo *pTgEFInfo; int nUserInfo; /* if TRUE, use &pTgEFInfo->pTgEFUserInfo, else use NULL */ int nMsg; /* one of TGEF_MSG_* */ int nArg; void *pvArg; { if (nUserInfo) { return (pTgEFInfo->pfnTgEFMain)(&pTgEFInfo->pTgEFUserInfo, nMsg, nArg, pvArg); } else { return (pTgEFInfo->pfnTgEFMain)(NULL, nMsg, nArg, pvArg); } } /* --------------------- Global Routines --------------------- */ void CleanUpExportFilters() { int i=0; for (i=0; i < gnMaxExportFilters; i++) { if (gaExportFilterBitmaps[i] != None) { XFreePixmap(mainDisplay, gaExportFilterBitmaps[i]); } } if (gpTgEFInfo != NULL) { for (i=0; i < gnMaxExportFilters; i++) { TgEFInfo *pTgEFInfo=(&gpTgEFInfo[i]); if (pTgEFInfo != NULL) { if (pTgEFInfo->pSharedLibHandle != NULL) { TGEF_MAIN *pfnTgEFMain=pTgEFInfo->pfnTgEFMain; if (pfnTgEFMain != NULL) { TgEFSendMsg(pTgEFInfo, TRUE, TGEF_MSG_UNLOAD, 0, NULL); TgEFSendMsg(pTgEFInfo, FALSE, TGEF_MSG_CLEANUP, 0, NULL); } CLOSE_DL(pTgEFInfo->pSharedLibHandle); } if (pTgEFInfo->pszSharedLibPath != NULL) { UtilFree(pTgEFInfo->pszSharedLibPath); } } } free(gpTgEFInfo); } gpTgEFInfo = NULL; } static int SharedLibLoadFailed(pTgEFInfo, pszSharedLibPath, nNeedUnload) TgEFInfo *pTgEFInfo; char *pszSharedLibPath; int nNeedUnload; /* * This is called when TGEF_MSG_LOAD failed for one reason or another. */ { if (nNeedUnload) { TgEFSendMsg(pTgEFInfo, TRUE, TGEF_MSG_UNLOAD, 0, NULL); } TgEFSendMsg(pTgEFInfo, FALSE, TGEF_MSG_CLEANUP, 0, NULL); CLOSE_DL(pTgEFInfo->pSharedLibHandle); return FALSE; } static int LoadSharedLib(pszSharedLibPath) char *pszSharedLibPath; { TgEFInfo *pTgEFInfo=(&gpTgEFInfo[gnMaxExportFilters]); int nSharedLibVersion=0; long lReturn=0L; pTgEFInfo->pszSharedLibPath = UtilStrDup(pszSharedLibPath); if (pTgEFInfo->pszSharedLibPath == NULL) { FailAllocMessage(); } pTgEFInfo->nSharedLibVersion = GetSharedLibVersion(pTgEFInfo->pszSharedLibPath); if (pTgEFInfo->nSharedLibVersion == 0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SHARELIB_VER_IN_FILE), pszSharedLibPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } pTgEFInfo->pSharedLibHandle = OPEN_DL(pszSharedLibPath, OPEN_DL_MODE); if (pTgEFInfo->pSharedLibHandle == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_LOAD_SHARELIB), pszSharedLibPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } pTgEFInfo->pfnTgEFMain = (TGEF_MAIN*)GET_DL_SYM(pTgEFInfo->pSharedLibHandle, TGEF_MAIN_NAME); if (pTgEFInfo->pfnTgEFMain == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_GET_ENTRY_PT_IN_SHARELIB), TGEF_MAIN_NAME, pszSharedLibPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } lReturn = TgEFSendMsg(pTgEFInfo, FALSE, TGEF_MSG_INIT, 0, NULL); if (lReturn != TGEF_STATUS_OK) { sprintf(gszMsgBox, TgLoadString(STID_SHARELIB_TGEF_MSG_INIT_FAIL), pszSharedLibPath, lReturn); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); CLOSE_DL(pTgEFInfo->pSharedLibHandle); return FALSE; } nSharedLibVersion = TgEFSendMsg(pTgEFInfo, FALSE, TGEF_MSG_GET_PROTOCOL_VERSION, 0, NULL); if (nSharedLibVersion != pTgEFInfo->nSharedLibVersion) { sprintf(gszMsgBox, TgLoadString(STID_SHARELIB_CNFLCT_PROTOCOL_VER), nSharedLibVersion, pszSharedLibPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); CLOSE_DL(pTgEFInfo->pSharedLibHandle); return FALSE; } switch (nSharedLibVersion) { case 1: memset(&pTgEFInfo->detail.stProtocolInfo_1, 0, sizeof(TgEFProtocolInfo_1)); pTgEFInfo->detail.stProtocolInfo_1.dpy = mainDisplay; pTgEFInfo->detail.stProtocolInfo_1.win = mainWindow; pTgEFInfo->detail.stProtocolInfo_1.pfnMsgBox = (NLFN*)MsgBox; pTgEFInfo->detail.stProtocolInfo_1.pfnDialog = (NLFN*)Dialog; pTgEFInfo->detail.stProtocolInfo_1.pfnFailAllocMessage = (NLFN*)FailAllocMessage; pTgEFInfo->detail.stProtocolInfo_1.pfnUtilCopyFile = (NLFN*)UtilCopyFile; pTgEFInfo->detail.stProtocolInfo_1.pfnObjInVisibleLayer = (NLFN*)ObjInVisibleLayer; pTgEFInfo->detail.stProtocolInfo_1.pfnUtilStrDup = (NLFN*)UtilStrDup; pTgEFInfo->detail.stProtocolInfo_1.pfnUtilFree = (VDFN*)UtilFree; pTgEFInfo->detail.stProtocolInfo_1.pfnMsg = (VDFN*)Msg; pTgEFInfo->detail.stProtocolInfo_1.pfnSetStringStatus = (VDFN*)SetStringStatus; pTgEFInfo->detail.stProtocolInfo_1.pfnUtilTrimBlanks = (VDFN*)UtilTrimBlanks; pTgEFInfo->detail.stProtocolInfo_1.pfnDynStrSet = (VDFN*)DynStrSet; strcpy(pTgEFInfo->detail.stProtocolInfo_1.sz_sl_path, pszSharedLibPath); pTgEFInfo->detail.stProtocolInfo_1.bm_bits = NULL; pTgEFInfo->detail.stProtocolInfo_1.bm_width = 0; pTgEFInfo->detail.stProtocolInfo_1.bm_height = 0; lReturn = TgEFSendMsg(pTgEFInfo, TRUE, TGEF_MSG_LOAD, 0, &pTgEFInfo->detail.stProtocolInfo_1); if (lReturn != TGEF_STATUS_OK) { sprintf(gszMsgBox, TgLoadString(STID_SHARELIB_TGEF_MSG_LOAD_FAIL), pszSharedLibPath, lReturn); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return SharedLibLoadFailed(pTgEFInfo, pszSharedLibPath, FALSE); } if (pTgEFInfo->detail.stProtocolInfo_1.bm_bits == None) { sprintf(gszMsgBox, TgLoadString(STID_SHARELIB_TGEF_MSG_LOAD_FAIL), pszSharedLibPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return SharedLibLoadFailed(pTgEFInfo, pszSharedLibPath, TRUE); } gaExportFilterBitmaps[gnMaxExportFilters] = XCreateBitmapFromData(mainDisplay, mainWindow, pTgEFInfo->detail.stProtocolInfo_1.bm_bits, pTgEFInfo->detail.stProtocolInfo_1.bm_width, pTgEFInfo->detail.stProtocolInfo_1.bm_height); if (gaExportFilterBitmaps[gnMaxExportFilters] == None) { sprintf(gszMsgBox, TgLoadString(STID_ALLOC_BMP_FAIL_FOR_SHARELIB), pszSharedLibPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return SharedLibLoadFailed(pTgEFInfo, pszSharedLibPath, TRUE); } break; default: sprintf(gszMsgBox, TgLoadString(STID_UNSUP_PROTOCOL_VER_SHARELIB), nSharedLibVersion, pszSharedLibPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); CLOSE_DL(pTgEFInfo->pSharedLibHandle); return FALSE; } return TRUE; } int InitExportFilters() { char *psz=NULL; gnMaxExportFilters = 0; if ((psz=XGetDefault(mainDisplay, TOOL_NAME, "MaxExportFilters")) != NULL) { int nMax=atoi(psz); if (nMax <= 0) { sprintf(gszMsgBox, TgLoadString(STID_BAD_XDEF_MUST_BE_GT_0), TOOL_NAME, "MaxExportFilters", psz); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { int i=0; gpTgEFInfo = (TgEFInfo*)malloc(nMax*sizeof(TgEFInfo)); if (gpTgEFInfo == NULL) FailAllocMessage(); memset(gpTgEFInfo, 0, nMax*sizeof(TgEFInfo)); gaExportFilterBitmaps = (Pixmap*)malloc(nMax*sizeof(Pixmap)); if (gaExportFilterBitmaps == NULL) FailAllocMessage(); memset(gaExportFilterBitmaps, 0, nMax*sizeof(Pixmap)); for (i=0; i < nMax; i++) { char szBuf[80]; int nOK=TRUE; sprintf(szBuf, "ExportFilter%1d", i); if ((psz=XGetDefault(mainDisplay, TOOL_NAME, szBuf)) == NULL) { nOK = FALSE; sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_XDEF_CONT_LOOK_FLTR), TOOL_NAME, szBuf); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) != MB_ID_YES) { break; } } else { UtilTrimBlanks(psz); nOK = LoadSharedLib(psz); } if (nOK) { gnMaxExportFilters++; } } if (gnMaxExportFilters > 0) { whereToPrintPixmap = (Pixmap*)realloc(whereToPrintPixmap, (MAXDEFWHERETOPRINT+gnMaxExportFilters)*sizeof(Pixmap)); if (whereToPrintPixmap == NULL) FailAllocMessage(); for (i=0; i < gnMaxExportFilters; i++) { whereToPrintPixmap[MAXDEFWHERETOPRINT+i] = gaExportFilterBitmaps[i]; } maxWhereToPrint += gnMaxExportFilters; } } } return TRUE; } /* do not translate -- program constants */ static char *gpszColorExportName[MAXDEFWHERETOPRINT] = { "Printer", "EPS", "PS", "XPM", "ASCII", "EPSI", "GIF/ISMAP", "HTML/USEMAP", "PDF", "TiffEPSI", "PNG", "JPEG", "PPM", "NetList" }; static char *gpszBWExportName[MAXDEFWHERETOPRINT] = { "Printer", "EPS", "PS", "XBM", "ASCII", "EPSI", "GIF/ISMAP", "HTML/USEMAP", "PDF", "TiffEPSI", "PNG", "JPEG", "PBM", "NetList" }; static char *gpszColorExportExt[MAXDEFWHERETOPRINT] = { NULL, EPSF_FILE_EXT, PS_FILE_EXT, XPM_FILE_EXT, TEXT_FILE_EXT, EPSF_FILE_EXT, "gif", "html", "pdf", EPSF_FILE_EXT, "png", "jpg", "ppm", NETLIST_FILE_EXT }; static char *gpszBWExportExt[MAXDEFWHERETOPRINT] = { NULL, EPSF_FILE_EXT, PS_FILE_EXT, XBM_FILE_EXT, TEXT_FILE_EXT, EPSF_FILE_EXT, "gif", "html", "pdf", EPSF_FILE_EXT, "png", "jpg", "pbm", NETLIST_FILE_EXT }; int GetExportIndex(nWhereToPrint, nMode) int nWhereToPrint, nMode; { if (nMode == 0) { } else if (nMode > 0 ){ nWhereToPrint = (nWhereToPrint+1) % maxWhereToPrint; } else if (nMode < 0 ){ nWhereToPrint = (nWhereToPrint+maxWhereToPrint-1) % maxWhereToPrint; } return nWhereToPrint; } char *GetExportName(nWhereToPrint, nMode) int nWhereToPrint, nMode; { TgEFInfo *pTgEFInfo=NULL; nWhereToPrint = GetExportIndex(nWhereToPrint, nMode); if (nWhereToPrint < MAXDEFWHERETOPRINT) { if (nWhereToPrint == NETLIST_FILE && preDumpSetup) { /* do not translate -- program constants */ return "Component"; } else if (colorDump) { return gpszColorExportName[nWhereToPrint]; } else { return gpszBWExportName[nWhereToPrint]; } } if (gpTgEFInfo == NULL) return TgLoadCachedString(CSTID_PARANED_UNKNOWN); pTgEFInfo = (&gpTgEFInfo[nWhereToPrint-MAXDEFWHERETOPRINT]); switch (pTgEFInfo->nSharedLibVersion) { case 1: if (colorDump) { return pTgEFInfo->detail.stProtocolInfo_1.color_format_name; } else { return pTgEFInfo->detail.stProtocolInfo_1.bw_format_name; } } return TgLoadCachedString(CSTID_PARANED_UNKNOWN); } char *GetExportExt(nWhereToPrint) int nWhereToPrint; { TgEFInfo *pTgEFInfo=NULL; if (nWhereToPrint < MAXDEFWHERETOPRINT) { if (nWhereToPrint == NETLIST_FILE && preDumpSetup) { return COMP_FILE_EXT; } else if (colorDump) { return gpszColorExportExt[nWhereToPrint]; } else { return gpszBWExportExt[nWhereToPrint]; } } if (gpTgEFInfo == NULL) return TgLoadCachedString(CSTID_PARANED_UNKNOWN); pTgEFInfo = (&gpTgEFInfo[nWhereToPrint-MAXDEFWHERETOPRINT]); switch (pTgEFInfo->nSharedLibVersion) { case 1: if (colorDump) { return pTgEFInfo->detail.stProtocolInfo_1.color_ext; } else { return pTgEFInfo->detail.stProtocolInfo_1.bw_ext; } } return TgLoadCachedString(CSTID_PARANED_UNKNOWN); } int GetExportFilterCapability(nWhereToPrint) int nWhereToPrint; { TgEFInfo *pTgEFInfo=(&gpTgEFInfo[nWhereToPrint-MAXDEFWHERETOPRINT]); switch (pTgEFInfo->nSharedLibVersion) { case 1: return pTgEFInfo->detail.stProtocolInfo_1.capability; } return 0; } static int ExportVectorFile_1(pTgEFInfo, pDumpFile, nPageNumInFileName, nPrintingPageNum, nPrintingFirstPageNum, nPrintingPageRow, nPrintingPageCol) TgEFInfo *pTgEFInfo; FILE *pDumpFile; int nPageNumInFileName, nPrintingPageNum, nPrintingFirstPageNum; int nPrintingPageRow, nPrintingPageCol; { long lReturn=0L; TgEFProtocolInfo_1 *pProtocolInfo_1=(&pTgEFInfo->detail.stProtocolInfo_1); pProtocolInfo_1->fp = pDumpFile; pProtocolInfo_1->color_dump = colorDump; pProtocolInfo_1->color_layers = colorLayers; pProtocolInfo_1->printing_page_num = nPrintingPageNum; pProtocolInfo_1->printing_first_page_num = nPrintingFirstPageNum; pProtocolInfo_1->printing_page_row = nPrintingPageRow; pProtocolInfo_1->printing_page_col = nPrintingPageCol; pProtocolInfo_1->page_layout_mode = pageLayoutMode; pProtocolInfo_1->last_page_num = lastPageNum; pProtocolInfo_1->top_obj = topObj; pProtocolInfo_1->bot_obj = botObj; pProtocolInfo_1->write_file_failed = FALSE; lReturn = TgEFSendMsg(pTgEFInfo, TRUE, TGEF_MSG_DO_EXPORT, 0, &pTgEFInfo->detail.stProtocolInfo_1); if (lReturn != TGEF_STATUS_OK) { sprintf(gszMsgBox, TgLoadString(STID_SHARELIB_TGEF_MSG_DO_EXPORT_F), pTgEFInfo->pszSharedLibPath, lReturn); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (pProtocolInfo_1->write_file_failed) writeFileFailed = TRUE; return TRUE; } int ExportVectorFile(pDumpFile, nPageNumInFileName, nPrintingPageNum, nPrintingFirstPageNum, nPrintingPageRow, nPrintingPageCol) FILE *pDumpFile; int nPageNumInFileName, nPrintingPageNum, nPrintingFirstPageNum; int nPrintingPageRow, nPrintingPageCol; { TgEFInfo *pTgEFInfo=(&gpTgEFInfo[whereToPrint-MAXDEFWHERETOPRINT]); switch (pTgEFInfo->nSharedLibVersion) { case 1: return ExportVectorFile_1(pTgEFInfo, pDumpFile, nPageNumInFileName, nPrintingPageNum, nPrintingFirstPageNum, nPrintingPageRow, nPrintingPageCol); } return FALSE; } tgif-QPL-4.2.5/mainmenu.e0000644000076400007640000000505111602233312014744 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/mainmenu.e,v 1.6 2011/05/16 16:21:58 william Exp $ */ #ifndef _MAINMENU_E_ #define _MAINMENU_E_ typedef int (ENUMPOPUPMENUFN)ARGS_DECL((int, Window, void*)); extern int pinnedMainMenu; extern int mainMenuPinDistance; extern Window mainMenuWindow; extern int numStacking; extern Window * stackingWins; extern int titledPinnedMenu; extern int btn3PopupModeMenu; #ifdef _INCLUDE_FROM_MAINMENU_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_MAINMENU_C_*/ extern void InitMainMenu ARGS_DECL((void)); extern void CleanUpMainMenu ARGS_DECL((void)); extern void SaveMainWinPosition ARGS_DECL((unsigned int X, unsigned int Y)); extern void MoveMainMenuWindow ARGS_DECL((unsigned int X, unsigned int Y)); extern void GetPopupXY ARGS_DECL((Window, int *px, int *py)); extern void GetPopupWH ARGS_DECL((Window, int *pw, int *ph)); extern void SaveStackingOrder ARGS_DECL((void)); extern Window TgRealizePinnedMenuWindow ARGS_DECL((TgMenu*, int X, int Y, int W, int H)); extern int TgWindowIsPinnedMenu ARGS_DECL((Window, int Index)); extern int TgHandlePinnedMenuEvent ARGS_DECL((Window, int Index, XEvent*)); extern void UpdatePinnedMenu ARGS_DECL((int Index)); extern void UpdateAllPinnedMenus ARGS_DECL((void)); extern void UseWireMenuItemInModeItem ARGS_DECL((int connecting)); extern void DestroyPinnedMenu ARGS_DECL((int Index)); extern void HidePopupMenusForSlideShow ARGS_DECL((void)); extern void ShowPopupMenusForSlideShow ARGS_DECL((void)); extern void EnumPopupMenuWindow ARGS_DECL((ENUMPOPUPMENUFN*, void*)); #ifdef _INCLUDE_FROM_MAINMENU_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_MAINMENU_C_*/ #endif /*_MAINMENU_E_*/ tgif-QPL-4.2.5/special.c0000644000076400007640000030771611602233312014566 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/special.c,v 1.19 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_SPECIAL_C_ #include "tgifdefs.h" #include "cmdids.h" #include "animate.e" #include "attr.e" #include "auxtext.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cutpaste.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "edit.e" #include "exec.e" #include "file.e" #include "font.e" #include "grid.e" #include "group.e" #include "list.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "menuinfo.e" #include "miniline.e" #include "msg.e" #include "move.e" #include "names.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "poly.e" #include "raster.e" #include "rect.e" #include "remote.e" #include "ruler.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "special.e" #include "stk.e" #include "stretch.e" #include "strtbl.e" #include "tangram2.e" #include "text.e" #include "util.e" #include "version.e" #include "wb.e" int placingTopObj=FALSE; int connectingPortsByWire=FALSE; int connectingPortsFromInternalCommand=TRUE; char gszAttrSeparator[]= "// -------- attribute separator (please do not modify or delete) -------- // "; static int showWireSignalName=TRUE; static int gnPinWarning=FALSE; static struct ObjRec *CreatePinObj(obj_ptr1, obj_ptr2, sym_count) struct ObjRec *obj_ptr1, *obj_ptr2; int sym_count; { struct ObjRec *obj_ptr=NULL; struct ObjRec *saved_top_obj=topObj; struct ObjRec *saved_bot_obj=botObj; int cx1, cy1, cx2, cy2; curPage->top = topObj = NULL; curPage->bot = botObj = NULL; if (sym_count == 1) { topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topObj = botObj = obj_ptr1; topSel->obj = obj_ptr1; topSel->next = topSel->prev = NULL; numObjSelected = 1; GroupSingleObj(TRUE); obj_ptr = topSel->obj; RemoveAllSel(); } else { if (obj_ptr2->fattr != NULL) { obj_ptr = obj_ptr2; obj_ptr2 = obj_ptr1; obj_ptr1 = obj_ptr; } cx1 = ((obj_ptr1->obbox.ltx+obj_ptr1->obbox.rbx)>>1); cy1 = ((obj_ptr1->obbox.lty+obj_ptr1->obbox.rby)>>1); cx2 = ((obj_ptr2->obbox.ltx+obj_ptr2->obbox.rbx)>>1); cy2 = ((obj_ptr2->obbox.lty+obj_ptr2->obbox.rby)>>1); MoveObj(obj_ptr2, cx1-cx2, cy1-cy2); obj_ptr1->next = obj_ptr2; obj_ptr1->prev = NULL; obj_ptr2->next = NULL; obj_ptr2->prev = obj_ptr1; CreateGroupObj(obj_ptr1, obj_ptr2); obj_ptr = topObj; } AdjObjBBox(obj_ptr); obj_ptr->type = OBJ_PIN; curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; if (!gnPinWarning) { gnPinWarning = TRUE; strcpy(gszMsgBox, TgLoadString(STID_WARN_PIN_NOT_SUPPORTED)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, STOP_MB); } } return obj_ptr; } struct ObjRec *ReadSymbol(FP, FileType) FILE *FP; int FileType; { register struct AttrRec *attr_ptr; struct ObjRec *obj_ptr, *obj_ptr1=NULL, *obj_ptr2=NULL; int read_status, sym_count=0; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); importingFile = TRUE; /* ignore 'state' info but set fileVersion */ readingPageNum = loadedCurPageNum = 0; foundGoodStateObject = FALSE; while ((read_status=ReadObj(FP, &obj_ptr)) == TRUE) { if (obj_ptr != NULL) { if (obj_ptr->type == OBJ_SYM) { int done=FALSE; UnlockAnObj(obj_ptr); obj_ptr->type = OBJ_ICON; attr_ptr = obj_ptr->lattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->prev) { attr_ptr->inherited = TRUE; } if (FileType == SYM_FILE_TYPE) { done = TRUE; } else { if (obj_ptr1 == NULL) { obj_ptr1 = obj_ptr; } else if (obj_ptr2 == NULL) { obj_ptr2 = obj_ptr; } if (++sym_count >= 2) { obj_ptr = CreatePinObj(obj_ptr1, obj_ptr2, sym_count); done = TRUE; } } if (done) { importingFile = FALSE; SetDefaultCursor(mainWindow); ShowCursor(); return obj_ptr; } } else { FreeObj(obj_ptr); } } } importingFile = FALSE; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } obj_ptr = NULL; if (read_status == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FILE_VER_ABORT_READ_SYMBOL), fileVersion, TOOL_NAME, homePageURL); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (FileType == PIN_FILE_TYPE && sym_count == 1) { obj_ptr = CreatePinObj(obj_ptr1, obj_ptr2, sym_count); } SetDefaultCursor(mainWindow); ShowCursor(); return obj_ptr; } struct ObjRec *GetObjRepresentation(PathName, SymName, FileType) char *PathName, *SymName; int FileType; { char file_name[MAXPATHLENGTH], *rest=NULL; char tmp_filename[MAXPATHLENGTH], tmp_filefullpath[MAXPATHLENGTH]; int short_name, tmp_linenum; struct ObjRec *obj_ptr; FILE *fp; sprintf(file_name, "%s%c%s.%s", PathName, DIR_SEP, SymName, SYM_FILE_EXT); if ((short_name=IsPrefix(bootDir, file_name, &rest))) ++rest; if ((fp=fopen(file_name, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), (short_name ? rest : file_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } strcpy(tmp_filefullpath, scanFileFullPath); strcpy(tmp_filename, scanFileName); tmp_linenum = scanLineNum; UtilStrCpyN(scanFileFullPath, sizeof(scanFileFullPath), file_name); strcpy(scanFileName, (short_name ? rest : file_name)); scanLineNum = 0; if ((obj_ptr=ReadSymbol(fp, FileType)) != NULL) { obj_ptr->id = objId++; obj_ptr->dirty = FALSE; strcpy(obj_ptr->detail.r->s, SymName); obj_ptr->detail.r->rotate = ROTATE0; obj_ptr->detail.r->flip = NO_FLIP; obj_ptr->detail.r->deck_index = (-1); obj_ptr->detail.r->pin_connected = 0; obj_ptr->detail.r->first_conn = obj_ptr->detail.r->last_conn = NULL; AdjObjBBox(obj_ptr); } strcpy(scanFileFullPath, tmp_filefullpath); strcpy(scanFileName, tmp_filename); scanLineNum = tmp_linenum; fclose(fp); return obj_ptr; } unsigned int PlaceTopObj(ObjPtr, savedTopObj, savedBotObj) struct ObjRec *ObjPtr, *savedTopObj, *savedBotObj; { int x, y, grid_x, grid_y, dx, dy, placing=TRUE; int cursor_x, cursor_y, orig_x, orig_y, obj_ltx, obj_lty, obj_rbx, obj_rby; int grid_obj_ltx, grid_obj_lty, grid_dx=0, grid_dy=0; Window root_win, child_win; int root_x, root_y, first_time=TRUE; unsigned int status, button_pressed=Button1; XEvent input, ev; RedrawMsg(TRUE); XFlush(mainDisplay); XSync(mainDisplay, False); placingTopObj = TRUE; if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } obj_ltx = OFFSET_X(ObjPtr->obbox.ltx); obj_lty = OFFSET_Y(ObjPtr->obbox.lty); obj_rbx = OFFSET_X(ObjPtr->obbox.rbx); obj_rby = OFFSET_Y(ObjPtr->obbox.rby); GridXY(obj_ltx, obj_lty, &grid_obj_ltx, &grid_obj_lty); dx = dy = 0; if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonPressMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } if (XCheckMaskEvent(mainDisplay, PointerMotionMask, &input)) { first_time = FALSE; cursor_x = input.xmotion.x; cursor_y = input.xmotion.y; while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &input)) { cursor_x = input.xmotion.x; cursor_y = input.xmotion.y; } GridXY(cursor_x, cursor_y, &orig_x, &orig_y); grid_dx = orig_x-grid_obj_ltx; grid_dy = orig_y-grid_obj_lty; SelBox(drawWindow, revDefaultGC, obj_ltx+grid_dx, obj_lty+grid_dy, obj_rbx+grid_dx, obj_rby+grid_dy); } while (placing) { XNextEvent(mainDisplay, &input); if (first_time) { first_time = FALSE; XQueryPointer(mainDisplay, drawWindow, &root_win, &child_win, &root_x, &root_y, &cursor_x, &cursor_y, &status); GridXY(cursor_x, cursor_y, &orig_x, &orig_y); grid_dx = orig_x-grid_obj_ltx; grid_dy = orig_y-grid_obj_lty; SelBox(drawWindow, revDefaultGC, obj_ltx+grid_dx, obj_lty+grid_dy, obj_rbx+grid_dx, obj_rby+grid_dy); } if (input.type == Expose || input.type == VisibilityNotify) { /* SelBox(drawWindow, revDefaultGC, obj_ltx+grid_dx, obj_lty+grid_dy, obj_rbx+grid_dx, obj_rby+grid_dy); */ if (savedTopObj != NULL && savedBotObj != NULL) { struct ObjRec *saved_top_obj=topObj, *saved_bot_obj=botObj; curPage->top = topObj = NULL; curPage->bot = botObj = NULL; curPage->top = topObj = savedTopObj; curPage->bot = botObj = savedBotObj; placingTopObj = FALSE; RedrawDrawWindow(botObj); placingTopObj = TRUE; curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; } ExposeEventHandler(&input, TRUE); SelBox(drawWindow, revDefaultGC, obj_ltx+grid_dx, obj_lty+grid_dy, obj_rbx+grid_dx, obj_rby+grid_dy); } else if (input.type == ButtonPress) { XUngrabPointer(mainDisplay, CurrentTime); button_pressed = input.xbutton.button; placing = FALSE; SelBox(drawWindow, revDefaultGC, obj_ltx+grid_dx+dx, obj_lty+grid_dy+dy, obj_rbx+grid_dx+dx, obj_rby+grid_dy+dy); grid_dx = ABS_SIZE(grid_dx+dx); grid_dy = ABS_SIZE(grid_dy+dy); MoveObj(ObjPtr, grid_dx, grid_dy); numRedrawBBox = 0; ShowInterrupt(1); placingTopObj = FALSE; ObjPtr->tmp_parent = NULL; DrawObj(drawWindow, ObjPtr); HideInterrupt(); } else if (input.type == MotionNotify) { int anywhere=(input.xmotion.state & (ShiftMask | ControlMask)); int saved_snap=snapOn; x = input.xmotion.x; y = input.xmotion.y; if (anywhere) snapOn = FALSE; GridXY(x, y, &grid_x, &grid_y); if (anywhere) snapOn = saved_snap; SelBox(drawWindow, revDefaultGC, obj_ltx+grid_dx+dx, obj_lty+grid_dy+dy, obj_rbx+grid_dx+dx, obj_rby+grid_dy+dy); dx = grid_x - orig_x; dy = grid_y - orig_y; SelBox(drawWindow, revDefaultGC, obj_ltx+grid_dx+dx, obj_lty+grid_dy+dy, obj_rbx+grid_dx+dx, obj_rby+grid_dy+dy); MarkRulers(grid_x, grid_y); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } XSync(mainDisplay, True); placingTopObj = FALSE; return button_pressed; } static int UnMakeIconicOnInstantiate(obj_ptr) struct ObjRec *obj_ptr; { register struct AttrRec *attr_ptr; for (attr_ptr=obj_ptr->lattr; attr_ptr!=NULL; attr_ptr=attr_ptr->prev) { if (*attr_ptr->attr_name.s=='\0' && (strcmp(attr_ptr->attr_value.s, "unmakeiconic_on_instantiate")==0 || strcmp(attr_ptr->attr_value.s, "unmakeiconic_on_instantiate_delete_attrs")==0)) { return TRUE; } } return FALSE; } static int UnMakeIconicOnInstantiateDeleteAttrs(obj_ptr) struct ObjRec *obj_ptr; { register struct AttrRec *attr_ptr; for (attr_ptr=obj_ptr->lattr; attr_ptr!=NULL; attr_ptr=attr_ptr->prev) { if (*attr_ptr->attr_name.s=='\0' && strcmp(attr_ptr->attr_value.s, "unmakeiconic_on_instantiate_delete_attrs")==0) { return TRUE; } } return FALSE; } static void DeleteUnMakeIconicOnInstantiateText() { struct SelRec *sel_ptr; struct ObjRec *text_obj_ptr=NULL; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { if (sel_ptr->obj->type == OBJ_TEXT) { struct DynStrRec *dyn_str_ptr=GetTextFirstDynStr(sel_ptr->obj); if (strcmp(dyn_str_ptr->s, "unmakeiconic_on_instantiate") == 0) { text_obj_ptr = sel_ptr->obj; break; } } } if (text_obj_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_NAMED_OBJ_IN_FUNC), "unmakeiconic_on_instantiate", "DeleteUnMakeIconicOnInstantiateText()"); TgAssert(FALSE, gszMsgBox, NULL); XFlush(mainDisplay); XSync(mainDisplay, False); return; } MakeQuiescent(); topSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->next = NULL; topSel->obj = text_obj_ptr; topSel->prev = NULL; botSel = topSel; UpdSelBBox(); HighLightForward(); DelAllSelObj(); } void Instantiate() { char file_name[MAXPATHLENGTH], *rest=NULL, msg[MAXSTRING]; char sym_name[MAXPATHLENGTH], path_name[MAXPATHLENGTH]; char ext_str[MAXPATHLENGTH]; char tmp_filename[MAXPATHLENGTH], tmp_filefullpath[MAXPATHLENGTH]; int short_name=FALSE, file_type=INVALID, tmp_linenum=0, len=0, ext_len=0; struct ObjRec *obj_ptr=NULL; FILE *fp=NULL; XEvent ev; MakeQuiescent(); if (*curDomainName == '\0') { strcpy(msg, TgLoadString(STID_SEL_A_SYM_TO_INSTAN_IN_NONE)); } else { sprintf(msg, TgLoadString(STID_SEL_A_SYM_TO_INSTAN_IN_DOMAIN), curDomainName); } if (SelectFromLibrary(msg, SYM_FILE_EXT, sym_name, path_name) == INVALID) { return; } if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } sprintf(file_name, "%s%c%s", path_name, DIR_SEP, sym_name); len = strlen(sym_name); sprintf(ext_str, ".%s", SYM_FILE_EXT); ext_len = strlen(ext_str); if (len > ext_len && strcmp(ext_str, &sym_name[len-ext_len]) == 0) { sym_name[len-ext_len] = '\0'; file_type = SYM_FILE_TYPE; } else { sprintf(ext_str, ".%s", PIN_FILE_EXT); ext_len = strlen(ext_str); if (len > ext_len && strcmp(ext_str, &sym_name[len-ext_len]) == 0) { sym_name[len-ext_len] = '\0'; file_type = PIN_FILE_TYPE; } } if ((short_name=IsPrefix(bootDir, file_name, &rest))) ++rest; if (file_type == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_CANT_INSTAN_FILE_UNKNOWN_EXT), (short_name ? rest : file_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if ((fp=fopen(file_name, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), (short_name ? rest : file_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } strcpy(tmp_filefullpath, scanFileFullPath); strcpy(tmp_filename, scanFileName); tmp_linenum = scanLineNum; UtilStrCpyN(scanFileFullPath, sizeof(scanFileFullPath), file_name); strcpy(scanFileName, (short_name ? rest : file_name)); scanLineNum = 0; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if ((obj_ptr=ReadSymbol(fp, file_type)) != NULL) { char *psz=NULL; struct AttrRec *name_attr=NULL; sprintf(msg, TgLoadCachedString(CSTID_INSTANTIATING_FILE_DOTS), (short_name ? rest : file_name)); SetStringStatus(msg); obj_ptr->id = objId++; obj_ptr->dirty = FALSE; strcpy(obj_ptr->detail.r->s, sym_name); obj_ptr->detail.r->rotate = ROTATE0; obj_ptr->detail.r->flip = NO_FLIP; obj_ptr->detail.r->deck_index = (-1); obj_ptr->detail.r->pin_connected = 0; obj_ptr->detail.r->first_conn = obj_ptr->detail.r->last_conn = NULL; name_attr = FindAttrWithName(obj_ptr, "name=", NULL); if (name_attr != NULL && (psz=strstr(name_attr->attr_value.s, "%d")) != NULL && (strstr(++psz, "%d")) == NULL) { sprintf(gszMsgBox, name_attr->attr_value.s, obj_ptr->id-1); DynStrSet(&name_attr->attr_value, gszMsgBox); UpdAttr(name_attr); UpdTextBBox(name_attr->obj); } AssignNewObjIds(obj_ptr); AddObj(NULL, topObj, obj_ptr); AdjObjBBox(obj_ptr); PlaceTopObj(obj_ptr, NULL, NULL); SelectTopObj(); if (UnMakeIconicOnInstantiate(obj_ptr)) { StartCompositeCmd(); RecordNewObjCmd(); UnMakeIconic(); if (UnMakeIconicOnInstantiateDeleteAttrs(obj_ptr)) { gnDeleteAttrsWhileUngrouping = TRUE; UngroupSelObj(TRUE, TRUE); gnDeleteAttrsWhileUngrouping = FALSE; } else { UngroupSelObj(TRUE, TRUE); DeleteUnMakeIconicOnInstantiateText(); } EndCompositeCmd(); } else { RecordNewObjCmd(); } SetFileModified(TRUE); justDupped = FALSE; } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_FND_SYM_IN_NAMED_TO_INST), (short_name ? rest : file_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } fclose(fp); strcpy(scanFileFullPath, tmp_filefullpath); strcpy(scanFileName, tmp_filename); scanLineNum = tmp_linenum; SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); Msg(""); if (topSel != NULL && topSel == botSel && topSel->obj->type == OBJ_ICON) { /* something has been instantiated */ char *psz=NULL; struct AttrRec *name_attr=NULL, *exec_attr=NULL; name_attr = FindAttrWithName(topSel->obj, "name=", NULL); if (name_attr != NULL && (psz=strstr(name_attr->attr_value.s, "%d")) != NULL && (strstr(++psz, "%d")) == NULL) { sprintf(gszMsgBox, name_attr->attr_value.s, obj_ptr->id-1); DynStrSet(&name_attr->attr_value, gszMsgBox); UpdAttr(name_attr); UpdTextBBox(name_attr->obj); AdjObjBBox(name_attr->obj); AdjObjCache(name_attr->obj); } exec_attr = FindAttrWithName(topSel->obj, "on_instantiate=", NULL); if (exec_attr != NULL) { DoExecLoop(topSel->obj, exec_attr); } } /* * Need to check for pins. */ } int ObjIsAPort(obj_ptr) struct ObjRec *obj_ptr; { struct AttrRec *attr_ptr=NULL; attr_ptr = FindAttrWithName(obj_ptr, "type=", NULL); if (attr_ptr != NULL && strcmp(attr_ptr->attr_value.s, "port") == 0) { /* * if this is not called from ConnectTwoPortsByAWire() but from * an internal command, "type=port" is enough for a point */ if (connectingPortsFromInternalCommand) return TRUE; if (FindAttrWithName(obj_ptr, "signal_name=", NULL) != NULL && FindAttrWithName(obj_ptr, "name=", NULL) != NULL) { struct ObjRec *owner_obj=obj_ptr->tmp_parent, *tmp_obj=NULL; owner_obj = obj_ptr->tmp_parent; if (owner_obj == NULL) { /* obj_ptr is a top-level object */ return (obj_ptr->type == OBJ_ICON || obj_ptr->type == OBJ_SYM); } else { if (owner_obj->type == OBJ_ICON || owner_obj->type == OBJ_SYM) { if (FindAttrWithName(owner_obj, "name=", NULL) == NULL) { return FALSE; } } else { if (owner_obj->type == OBJ_GROUP) { attr_ptr = FindAttrWithName(owner_obj, "type=", NULL); if (attr_ptr != NULL && strcmp(attr_ptr->attr_value.s, "tgBroadcastWire") == 0) { return TRUE; } } return FALSE; } } for (tmp_obj=owner_obj->tmp_parent; tmp_obj != NULL; tmp_obj=tmp_obj->tmp_parent) { if (tmp_obj->type == OBJ_ICON || tmp_obj->type == OBJ_SYM) { return FALSE; } } return TRUE; } } return FALSE; } static int DoConnectTwoPorts() { int poly_created=FALSE; XGCValues values; MakeQuiescent(); ResetWiringNodeInfo(); connectingPortsByWire = TRUE; connectingPortsFromInternalCommand = FALSE; UseWireMenuItemInModeItem(TRUE); values.line_width = 3; XChangeGC(mainDisplay, revGrayGC, GCLineWidth, &values); SetCurChoice(DRAWPOLY); gstWiringInfo.num_ports_to_connect = 2; drawPolyHighlightedNode = NULL; SetStringStatus(TgLoadString(STID_DRAW_AN_EDGE_BETWEEN_PORTS)); polyDrawn = FALSE; for (;;) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ConfigureNotify) { Reconfigure(FALSE); } else if (input.xany.window == drawWindow) { polyDrawn = FALSE; DrawingEventHandler(&input); if (curChoice == DRAWPOLY) { if (polyDrawn) { break; } else if (gstWiringInfo.num_ports_to_connect == (-1)) { break; } } else { polyDrawn = FALSE; break; } } } gstWiringInfo.num_ports_to_connect = 0; poly_created = polyDrawn; values.line_width = 1; XChangeGC(mainDisplay, revGrayGC, GCLineWidth, &values); connectingPortsByWire = FALSE; connectingPortsFromInternalCommand = TRUE; SetCurChoice(NOTHING); RedrawModeWindow(); UseWireMenuItemInModeItem(FALSE); UpdatePinnedMenu(MENU_MODE); return poly_created; } static void AddWireAttributes(poly_obj_ptr, signal_name, p_obbox, auto_center) struct ObjRec *poly_obj_ptr; char *signal_name; struct BBRec *p_obbox; int auto_center; { struct ObjRec *text_obj_ptr=NULL; PrepareToReplaceAnObj(poly_obj_ptr); AddAttrByNameAndValue(poly_obj_ptr, "signal_name=", signal_name); poly_obj_ptr->fattr->shown = TRUE; poly_obj_ptr->fattr->nameshown = FALSE; UpdAttr(poly_obj_ptr->fattr); text_obj_ptr = poly_obj_ptr->fattr->obj; if (auto_center) { CenterObjInOBBox(text_obj_ptr, *p_obbox, NULL); memcpy(p_obbox, &text_obj_ptr->obbox, sizeof(struct BBRec)); poly_obj_ptr->fattr->shown = FALSE; } else { MoveObj(text_obj_ptr, p_obbox->ltx-text_obj_ptr->obbox.ltx, p_obbox->lty-text_obj_ptr->obbox.lty); } AddAttrByNameAndValue(poly_obj_ptr, "type=", "tgWire"); text_obj_ptr = poly_obj_ptr->fattr->obj; MoveObj(text_obj_ptr, p_obbox->ltx-text_obj_ptr->obbox.ltx, p_obbox->rby-text_obj_ptr->obbox.lty); AdjObjBBox(poly_obj_ptr); RecordReplaceAnObj(poly_obj_ptr); } typedef struct tagChangeConnectionViewInfo { /* only change view if do_change_view is TRUE */ int do_change_view; int change_to_connect_view; struct ObjRec *conn_view_obj, *disconn_view_obj; int conn_fill, conn_pen, disconn_fill, disconn_pen; /* _TANGRAM_II stuff */ struct ObjRec *port_obj; char *signal_name; } ChangeConnectionViewInfo; static int ChangeConnectionView(pravci) ReplAttrValueCallbackInfo *pravci; { ChangeConnectionViewInfo *pccvi=( (ChangeConnectionViewInfo*)pravci->pv_userdata); if (pccvi == NULL) return FALSE; if (pccvi->do_change_view) { if (pccvi->change_to_connect_view) { ChangeObjFill(pccvi->disconn_view_obj, NONEPAT); ChangeObjPen(pccvi->disconn_view_obj, NONEPAT); ChangeObjFill(pccvi->conn_view_obj, pccvi->conn_fill); ChangeObjPen(pccvi->conn_view_obj, pccvi->conn_pen); } else { ChangeObjFill(pccvi->conn_view_obj, NONEPAT); ChangeObjPen(pccvi->conn_view_obj, NONEPAT); ChangeObjFill(pccvi->disconn_view_obj, pccvi->disconn_fill); ChangeObjPen(pccvi->disconn_view_obj, pccvi->disconn_pen); } } if (cmdLineTgrm2) { Tangram2UpdateInitAttr(pccvi->port_obj, pccvi->signal_name); } return TRUE; } static int HasConnAndDisConnViewObjSubObjs(obj_ptr, pccvi) struct ObjRec *obj_ptr; ChangeConnectionViewInfo *pccvi; { struct ObjRec *subobj=NULL; if (obj_ptr == NULL) return FALSE; if (obj_ptr->type != OBJ_SYM && obj_ptr->type != OBJ_ICON && obj_ptr->type != OBJ_GROUP) { return FALSE; } for (subobj=obj_ptr->detail.r->first; subobj != NULL; subobj=subobj->next) { struct AttrRec *attr_ptr=FindAttrWithName(subobj, "view=", NULL); if (attr_ptr != NULL) { char *psz_fill=NULL, *psz_pen=NULL, buf[MAXSTRING]; UtilStrCpyN(buf, sizeof(buf), attr_ptr->attr_value.s); psz_fill = strchr(buf, ','); if (psz_fill != NULL) { *psz_fill++ = '\0'; psz_pen = strchr(psz_fill, ','); if (psz_pen != NULL) *psz_pen++ = '\0'; } if (psz_fill != NULL && psz_pen != NULL) { int fill=0, pen=0, ok=TRUE; UtilTrimBlanks(buf); UtilTrimBlanks(psz_fill); UtilTrimBlanks(psz_pen); if (sscanf(psz_fill, "%d", &fill) != 1) ok = FALSE; if (sscanf(psz_pen, "%d", &pen) != 1) ok = FALSE; if (ok) { fill = fill % MAXPATTERNS; pen = pen % MAXPATTERNS; if (ok && UtilStrICmp(buf, "conn") == 0) { pccvi->conn_fill = fill; pccvi->conn_pen = pen; pccvi->conn_view_obj = subobj; } else if (ok && UtilStrICmp(buf, "disconn") == 0) { pccvi->disconn_fill = fill; pccvi->disconn_pen = pen; pccvi->disconn_view_obj = subobj; } } } } } return (pccvi->conn_view_obj != NULL && pccvi->disconn_view_obj != NULL); } static int SetPortSignalName(port_obj, attr_ptr, attr_owner_obj, new_signal_name) struct ObjRec *port_obj, *attr_owner_obj; struct AttrRec *attr_ptr; char *new_signal_name; { if (attr_ptr != NULL && strcmp(new_signal_name, attr_ptr->attr_value.s) != 0) { char *old_signal_name=attr_ptr->attr_value.s; ChangeConnectionViewInfo ccvi; memset(&ccvi, 0, sizeof(ChangeConnectionViewInfo)); if ((*old_signal_name == '\0' || *new_signal_name == '\0') && HasConnAndDisConnViewObjSubObjs(attr_ptr->owner, &ccvi)) { ccvi.do_change_view = TRUE; if (*old_signal_name == '\0') { /* the port will become connected */ ccvi.change_to_connect_view = TRUE; } else { /* the port will become disconnected */ ccvi.change_to_connect_view = FALSE; } } ccvi.port_obj = port_obj; ccvi.signal_name = new_signal_name; SetReplaceAttrValueCallback( (ReplAttrValueCallback*)ChangeConnectionView, &ccvi); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, new_signal_name); SetReplaceAttrValueCallback(NULL, NULL); RecursivelyAdjObjBBox(attr_ptr->owner, attr_ptr->owner, attr_owner_obj); return TRUE; } return FALSE; } static void DoNameWire(automatic) int automatic; { struct AttrRec *first_attr_ptr=NULL, *last_attr_ptr=NULL; struct ObjRec *first_attr_owner_obj=NULL, *last_attr_owner_obj=NULL; struct BBRec bbox; char signal_name[MAXSTRING], *existing_signal_name=NULL; int need_to_clear=FALSE, need_to_redraw=FALSE; int do_prompt=TRUE, must_prompt=FALSE; memcpy(&bbox, &topObj->bbox, sizeof(struct BBRec)); first_attr_ptr = FindAttrWithName(gstWiringInfo.first_port_obj, "signal_name=", &first_attr_owner_obj); while (first_attr_owner_obj != NULL && first_attr_owner_obj->tmp_parent != NULL) { first_attr_owner_obj = first_attr_owner_obj->tmp_parent; } last_attr_ptr = FindAttrWithName(gstWiringInfo.last_port_obj, "signal_name=", &last_attr_owner_obj); while (last_attr_owner_obj != NULL && last_attr_owner_obj->tmp_parent != NULL) { last_attr_owner_obj = last_attr_owner_obj->tmp_parent; } if (first_attr_ptr == NULL && last_attr_ptr == NULL) return; if (first_attr_ptr != NULL && last_attr_ptr != NULL) { if (strcmp(first_attr_ptr->attr_value.s, last_attr_ptr->attr_value.s) != 0) { if (*first_attr_ptr->attr_value.s == '\0' && *last_attr_ptr->attr_value.s == '\0') { must_prompt = TRUE; } else if (*first_attr_ptr->attr_value.s == '\0') { existing_signal_name = last_attr_ptr->attr_value.s; } else if (*last_attr_ptr->attr_value.s == '\0') { existing_signal_name = first_attr_ptr->attr_value.s; } else { sprintf(gszMsgBox, TgLoadString(STID_Q_CNFLCT_SIG_NAME_OKAY_TO_CLR), first_attr_ptr->attr_value.s, gstWiringInfo.first_port_name, last_attr_ptr->attr_value.s, gstWiringInfo.last_port_name); switch (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB)) { case MB_ID_YES: need_to_clear = TRUE; must_prompt = TRUE; break; case MB_ID_NO: case MB_ID_CANCEL: return; } } } else { existing_signal_name = first_attr_ptr->attr_value.s; } } else if (first_attr_ptr == NULL) { if (*last_attr_ptr->attr_value.s != '\0') { existing_signal_name = last_attr_ptr->attr_value.s; } } else { if (*first_attr_ptr->attr_value.s != '\0') { existing_signal_name = first_attr_ptr->attr_value.s; } } StartCompositeCmd(); if (need_to_clear) { if (SetPortSignalName(gstWiringInfo.first_port_obj, first_attr_ptr, first_attr_owner_obj, "")) { UnionRect(&bbox, &first_attr_owner_obj->bbox, &bbox); need_to_redraw = TRUE; } if (SetPortSignalName(gstWiringInfo.last_port_obj, last_attr_ptr, last_attr_owner_obj, "")) { UnionRect(&bbox, &last_attr_owner_obj->bbox, &bbox); need_to_redraw = TRUE; } } if (do_prompt) { struct ObjRec *signal_name_obj=NULL; struct BBRec obbox; XEvent ev; int show_wire_signal_name=(!automatic && showWireSignalName); *signal_name = '\0'; if (existing_signal_name != NULL) { UtilStrCpyN(signal_name, sizeof(signal_name), existing_signal_name); } UtilTrimBlanks(signal_name); if (must_prompt || !automatic) { Dialog(TgLoadString(STID_PLS_ENT_SIG_NAME), NULL, signal_name); UtilTrimBlanks(signal_name); } if (*signal_name == '\0') { if (need_to_clear) { sprintf(gszMsgBox, TgLoadString(STID_SIGNAL_NAMES_CLEARED), gstWiringInfo.first_port_name, gstWiringInfo.last_port_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } EndCompositeCmd(); if (need_to_redraw) { SetFileModified(TRUE); justDupped = FALSE; RedrawAnArea(botObj, bbox.ltx-QUARTER_INCH-GRID_ABS_SIZE(1), bbox.lty-QUARTER_INCH-GRID_ABS_SIZE(1), bbox.rbx+QUARTER_INCH+GRID_ABS_SIZE(1), bbox.rby+QUARTER_INCH+GRID_ABS_SIZE(1)); } return; } if (show_wire_signal_name) { unsigned int button_pressed=Button1; SaveStatusStrings(); sprintf(gszMsgBox, TgLoadString(STID_PLACING_NAMED_SIGNAL), signal_name); SetStringStatus(gszMsgBox); button_pressed = PasteString(signal_name, FALSE, FALSE); RestoreStatusStrings(); if (button_pressed != Button1) show_wire_signal_name = FALSE; memcpy(&obbox, &topObj->obbox, sizeof(struct BBRec)); signal_name_obj = topObj; UnlinkObj(signal_name_obj); FreeObj(signal_name_obj); XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } } else { memcpy(&obbox, &topObj->obbox, sizeof(struct BBRec)); } AddWireAttributes(topObj, signal_name, &obbox, !show_wire_signal_name); UnionRect(&bbox, &topObj->bbox, &bbox); if (SetPortSignalName(gstWiringInfo.first_port_obj, first_attr_ptr, first_attr_owner_obj, signal_name)) { UnionRect(&bbox, &first_attr_owner_obj->bbox, &bbox); need_to_redraw = TRUE; } if (SetPortSignalName(gstWiringInfo.last_port_obj, last_attr_ptr, last_attr_owner_obj, signal_name)) { UnionRect(&bbox, &last_attr_owner_obj->bbox, &bbox); need_to_redraw = TRUE; } } EndCompositeCmd(); if (need_to_redraw) { SetFileModified(TRUE); justDupped = FALSE; RedrawAnArea(botObj, bbox.ltx-QUARTER_INCH-GRID_ABS_SIZE(1), bbox.lty-QUARTER_INCH-GRID_ABS_SIZE(1), bbox.rbx+QUARTER_INCH+GRID_ABS_SIZE(1), bbox.rby+QUARTER_INCH+GRID_ABS_SIZE(1)); if (topSel!=NULL) HighLightForward(); } } void ConnectTwoPortsByAWire() { StartCompositeCmd(); if (DoConnectTwoPorts()) { DoNameWire(FALSE); } EndCompositeCmd(); } void RepeatConnectTwoPortsByAWire() { StartCompositeCmd(); while (DoConnectTwoPorts()) { DoNameWire(TRUE); if (topSel!=NULL) { HighLightReverse(); RemoveAllSel(); } } EndCompositeCmd(); } static void AddObjToAnchor(anchor, obj_ptr) struct ObjRec *anchor, *obj_ptr; { obj_ptr->prev = NULL; obj_ptr->next = anchor->detail.r->first; anchor->detail.r->first->prev = obj_ptr; anchor->detail.r->first = obj_ptr; AdjObjOBBox(anchor); } static void AddBroadcastWireAttributes(poly_obj_ptr, signal_name, p_obbox, auto_center) struct ObjRec *poly_obj_ptr; char *signal_name; struct BBRec *p_obbox; int auto_center; { struct ObjRec *text_obj_ptr=NULL; PrepareToReplaceAnObj(poly_obj_ptr); AddAttrByNameAndValue(poly_obj_ptr, "broadcast_signal_name=", signal_name); poly_obj_ptr->fattr->shown = TRUE; poly_obj_ptr->fattr->nameshown = FALSE; UpdAttr(poly_obj_ptr->fattr); text_obj_ptr = poly_obj_ptr->fattr->obj; if (auto_center) { CenterObjInOBBox(text_obj_ptr, *p_obbox, NULL); memcpy(p_obbox, &text_obj_ptr->obbox, sizeof(struct BBRec)); poly_obj_ptr->fattr->shown = FALSE; } else { MoveObj(text_obj_ptr, p_obbox->ltx-text_obj_ptr->obbox.ltx, p_obbox->lty-text_obj_ptr->obbox.lty); } AdjObjBBox(poly_obj_ptr); RecordReplaceAnObj(poly_obj_ptr); } static void DoNameBroadcastWire(signal_name, signal_name_diff) char *signal_name; int signal_name_diff; { struct ObjRec *obj_ptr=NULL, *signal_name_obj=NULL; struct AttrRec *attr_ptr=NULL; struct BBRec bbox, obbox; int show_wire_signal_name=showWireSignalName; int already_has_broadcast_signal_name=FALSE; XEvent ev; memset(&obbox, 0, sizeof(obbox)); memcpy(&bbox, &topObj->bbox, sizeof(struct BBRec)); StartCompositeCmd(); attr_ptr = FindAttrWithName(topObj, "broadcast_signal_name=", NULL); if (attr_ptr != NULL) { already_has_broadcast_signal_name = TRUE; if (strcmp(attr_ptr->attr_value.s, signal_name) != 0) { ReplaceAttrFirstValue(topObj, attr_ptr, signal_name); UnionRect(&bbox, &topObj->bbox, &bbox); } } for (obj_ptr=topObj->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ObjIsAPort(obj_ptr)) { struct ObjRec *attr_owner_obj=NULL; attr_ptr = FindAttrWithName(obj_ptr, "signal_name=", &attr_owner_obj); while (attr_owner_obj != NULL && attr_owner_obj->tmp_parent != NULL) { attr_owner_obj = attr_owner_obj->tmp_parent; } if (SetPortSignalName(obj_ptr, attr_ptr, attr_owner_obj, "")) { UnionRect(&bbox, &attr_owner_obj->bbox, &bbox); } } } if (show_wire_signal_name && !already_has_broadcast_signal_name) { unsigned int button_pressed=Button1; SaveStatusStrings(); sprintf(gszMsgBox, TgLoadString(STID_PLACING_NAMED_SIGNAL), signal_name); SetStringStatus(gszMsgBox); button_pressed = PasteString(signal_name, FALSE, FALSE); RestoreStatusStrings(); if (button_pressed != Button1) show_wire_signal_name = FALSE; memcpy(&obbox, &topObj->obbox, sizeof(struct BBRec)); signal_name_obj = topObj; UnlinkObj(signal_name_obj); FreeObj(signal_name_obj); XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } } else { memcpy(&obbox, &topObj->obbox, sizeof(struct BBRec)); } if (!already_has_broadcast_signal_name) { AddBroadcastWireAttributes(topObj, signal_name, &obbox, !show_wire_signal_name); UnionRect(&bbox, &topObj->bbox, &bbox); } for (obj_ptr=topObj->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ObjIsAPort(obj_ptr)) { struct ObjRec *attr_owner_obj=NULL; struct AttrRec *attr_ptr=NULL; attr_ptr = FindAttrWithName(obj_ptr, "signal_name=", &attr_owner_obj); while (attr_owner_obj != NULL && attr_owner_obj->tmp_parent != NULL) { attr_owner_obj = attr_owner_obj->tmp_parent; } if (SetPortSignalName(obj_ptr, attr_ptr, attr_owner_obj, signal_name)) { UnionRect(&bbox, &attr_owner_obj->bbox, &bbox); } } } EndCompositeCmd(); SetFileModified(TRUE); justDupped = FALSE; RedrawAnArea(botObj, bbox.ltx-QUARTER_INCH-GRID_ABS_SIZE(1), bbox.lty-QUARTER_INCH-GRID_ABS_SIZE(1), bbox.rbx+QUARTER_INCH+GRID_ABS_SIZE(1), bbox.rby+QUARTER_INCH+GRID_ABS_SIZE(1)); if (topSel!=NULL) HighLightForward(); } static void TrySetCommonSignalName(attr_ptr, pszSignalName, szSignalName, pnSignalNameDiff) struct AttrRec *attr_ptr; char *pszSignalName; int szSignalName, *pnSignalNameDiff; { if (*pnSignalNameDiff) { /* already see multiple signal names */ } else if (*attr_ptr->attr_value.s == '\0') { /* nothing to do */ } else if (*pszSignalName == '\0') { UtilStrCpyN(pszSignalName, szSignalName, attr_ptr->attr_value.s); } else if (strcmp(pszSignalName, attr_ptr->attr_value.s) != 0) { (*pnSignalNameDiff) = TRUE; *pszSignalName = '\0'; } } static int CheckPortsAndBroadcastObj(ppAnchor, pnAnchorIsPoly, pnNumPorts, pszSignalName, szSignalName, pnSignalNameDiff, pnAlreadyHasBroadcastSignalName) struct ObjRec **ppAnchor; int *pnAnchorIsPoly, *pnNumPorts, szSignalName, *pnSignalNameDiff; int *pnAlreadyHasBroadcastSignalName; char *pszSignalName; { int num_ports=0, anchor_is_poly=FALSE, ok=TRUE, signal_name_diff=FALSE; int already_has_broadcast_signal_name=FALSE; struct ObjRec *anchor=NULL; struct SelRec *sel_ptr=NULL; *pszSignalName = '\0'; for (sel_ptr=botSel; ok && sel_ptr != NULL; sel_ptr=sel_ptr->prev) { struct AttrRec *attr_ptr=NULL; switch (sel_ptr->obj->type) { case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: case OBJ_PIN: if ((attr_ptr=FindAttrWithName(sel_ptr->obj, "type=", NULL)) != NULL) { if (strcmp(attr_ptr->attr_value.s, "port") == 0) { if ((attr_ptr=FindAttrWithName(sel_ptr->obj, "signal_name=", NULL)) != NULL) { TrySetCommonSignalName(attr_ptr, pszSignalName, szSignalName, &signal_name_diff); num_ports++; } } else if (strcmp(attr_ptr->attr_value.s, "tgBroadcastWire") == 0) { anchor = sel_ptr->obj; anchor_is_poly = FALSE; if ((attr_ptr=FindAttrWithName(sel_ptr->obj, "broadcast_signal_name=", NULL)) != NULL) { TrySetCommonSignalName(attr_ptr, pszSignalName, szSignalName, &signal_name_diff); already_has_broadcast_signal_name = TRUE; } } else { return FALSE; } } else { return FALSE; } break; case OBJ_POLY: if (anchor == NULL) { anchor = sel_ptr->obj; anchor_is_poly = TRUE; } else { return FALSE; } break; default: return FALSE; break; } } if (anchor == NULL || num_ports == 0) { return FALSE; } *pnNumPorts = num_ports; *ppAnchor = anchor; *pnAnchorIsPoly = anchor_is_poly; *pnSignalNameDiff = signal_name_diff; *pnAlreadyHasBroadcastSignalName = already_has_broadcast_signal_name; return TRUE; } void ConnectPortsToBroadcastWire() { struct ObjRec *anchor=NULL; struct SelRec *sel_ptr=NULL; int num_ports=0, anchor_is_poly=FALSE, signal_name_diff=FALSE; int sel_ltx=selLtX, sel_lty=selLtY, sel_rbx=selRbX, sel_rby=selRbY; int already_has_broadcast_signal_name=FALSE; char existing_signal_name[MAXSTRING], new_signal_name[MAXSTRING]; *existing_signal_name = '\0'; if (!CheckPortsAndBroadcastObj(&anchor, &anchor_is_poly, &num_ports, existing_signal_name, sizeof(existing_signal_name), &signal_name_diff, &already_has_broadcast_signal_name)) { MsgBox(TgLoadString(STID_SEL_ONE_NONE_PORT_PLUS_BRDCST), TOOL_NAME, INFO_MB); return; } *new_signal_name = '\0'; if (*existing_signal_name == '\0') { if (signal_name_diff) { /* conflicting signal names */ sprintf(gszMsgBox, TgLoadString(STID_CONFLICT_SIG_NAME_ENT_NEW)); } else { /* all ports have no signal names */ sprintf(gszMsgBox, TgLoadString(STID_PLS_ENT_SIG_NAME)); } } else { UtilStrCpyN(new_signal_name, sizeof(new_signal_name), existing_signal_name); sprintf(gszMsgBox, TgLoadString(STID_PLS_ENT_SIG_NAME)); } if (!(*new_signal_name != '\0' && already_has_broadcast_signal_name)) { UtilTrimBlanks(new_signal_name); Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), new_signal_name); UtilTrimBlanks(new_signal_name); if (*new_signal_name == '\0') { return; } } StartCompositeCmd(); HighLightReverse(); if (anchor_is_poly) { struct SelRec *saved_top_sel=NULL, *saved_bot_sel=NULL; struct ObjRec *text_obj_ptr=NULL; struct BBRec obbox; int saved_num_obj_selected=0; char name[40]; PrepareToReplaceAnObj(anchor); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { if (sel_ptr->obj == anchor) { UnlinkSel(sel_ptr, &topSel, &botSel); numObjSelected--; break; } } saved_top_sel = topSel; saved_bot_sel = botSel; saved_num_obj_selected = numObjSelected; topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->obj = anchor; topSel->next = topSel->prev = NULL; numObjSelected = 1; GroupSingleObj(FALSE); topSel = saved_top_sel; botSel = saved_bot_sel; numObjSelected = saved_num_obj_selected; AddObjIntoSel(topObj, NULL, topSel, &topSel, &botSel); numObjSelected++; anchor = topObj; memcpy(&obbox, &anchor->obbox, sizeof(struct BBRec)); AddAttrByNameAndValue(anchor, "type=", "tgBroadcastWire"); text_obj_ptr = anchor->fattr->obj; MoveObj(text_obj_ptr, obbox.ltx-text_obj_ptr->obbox.ltx, obbox.rby-text_obj_ptr->obbox.lty); AdjObjBBox(anchor); sprintf(name, "tgAutoObj%d", anchor->id); memcpy(&obbox, &anchor->obbox, sizeof(struct BBRec)); AddAttrByNameAndValue(anchor, "name=", name); text_obj_ptr = anchor->fattr->obj; MoveObj(text_obj_ptr, obbox.ltx-text_obj_ptr->obbox.ltx, obbox.rby-text_obj_ptr->obbox.lty); AdjObjBBox(anchor); RecordReplaceAnObj(anchor); } PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { if (sel_ptr->obj != anchor) { UnlinkObj(sel_ptr->obj); AddObjToAnchor(anchor, sel_ptr->obj); } } RemoveAllSel(); UnlinkObj(anchor); AddObj(NULL, topObj, anchor); topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->obj = anchor; topSel->prev = NULL; botSel->next = NULL; AdjObjBBox(anchor); UpdSelBBox(); RecordCmd(CMD_MANY_TO_ONE, NULL, topSel, botSel, 1); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; DoNameBroadcastWire(new_signal_name, signal_name_diff); EndCompositeCmd(); } #define DO_RENAME_SIGNAL_NAME 99 #define DO_CLEAR_SIGNAL_NAME 999 static void DoNameOrClearAPort(which) int which; { struct AttrRec *first_attr_ptr=NULL; struct ObjRec *first_attr_owner_obj=NULL; int ltx=0, lty=0, rbx=0, rby=0; char signal_name[MAXSTRING]; ChangeConnectionViewInfo ccvi; memset(&ccvi, 0, sizeof(ChangeConnectionViewInfo)); first_attr_ptr = FindAttrWithName(gstWiringInfo.first_port_obj, "signal_name=", &first_attr_owner_obj); while (first_attr_owner_obj != NULL && first_attr_owner_obj->tmp_parent != NULL) { first_attr_owner_obj = first_attr_owner_obj->tmp_parent; } if (first_attr_ptr == NULL) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "first_attr_ptr is NULL in DoNameOrClearAPort()", NULL); return; #endif /* _TGIF_DBG */ } *signal_name = '\0'; if (which == DO_CLEAR_SIGNAL_NAME && *first_attr_ptr->attr_value.s == '\0') { /* already cleared */ return; } if (which == DO_RENAME_SIGNAL_NAME) { UtilStrCpyN(signal_name, sizeof(signal_name), first_attr_ptr->attr_value.s); sprintf(gszMsgBox, TgLoadString(STID_PLS_ENT_SIG_NAME_FOR_PORT), gstWiringInfo.first_port_name); if (Dialog(gszMsgBox, NULL, signal_name) == INVALID) return; UtilTrimBlanks(signal_name); } if (strcmp(signal_name, first_attr_ptr->attr_value.s) == 0) { return; } ltx = first_attr_owner_obj->bbox.ltx; lty = first_attr_owner_obj->bbox.lty; rbx = first_attr_owner_obj->bbox.rbx; rby = first_attr_owner_obj->bbox.rby; if (HasConnAndDisConnViewObjSubObjs(first_attr_ptr->owner, &ccvi)) { ccvi.do_change_view = TRUE; if (*signal_name != '\0') { /* the port will become connected */ ccvi.change_to_connect_view = TRUE; } else { /* the port will become disconnected */ ccvi.change_to_connect_view = FALSE; } } ccvi.port_obj = gstWiringInfo.first_port_obj; ccvi.signal_name = signal_name; SetReplaceAttrValueCallback( (ReplAttrValueCallback*)ChangeConnectionView, &ccvi); ReplaceAttrFirstValue(first_attr_owner_obj, first_attr_ptr, signal_name); SetReplaceAttrValueCallback(NULL, NULL); RecursivelyAdjObjBBox(first_attr_ptr->owner, first_attr_ptr->owner, first_attr_owner_obj); SetFileModified(TRUE); justDupped = FALSE; RedrawAreas(botObj, ltx-QUARTER_INCH-GRID_ABS_SIZE(1), lty-QUARTER_INCH-GRID_ABS_SIZE(1), rbx+QUARTER_INCH+GRID_ABS_SIZE(1), rby+QUARTER_INCH+GRID_ABS_SIZE(1), first_attr_owner_obj->bbox.ltx-QUARTER_INCH-GRID_ABS_SIZE(1), first_attr_owner_obj->bbox.lty-QUARTER_INCH-GRID_ABS_SIZE(1), first_attr_owner_obj->bbox.rbx+QUARTER_INCH+GRID_ABS_SIZE(1), first_attr_owner_obj->bbox.rby+QUARTER_INCH+GRID_ABS_SIZE(1)); } static void DoRenameOrClearSignalNameForAPort(which) int which; { int naming=TRUE; ShowCurChoiceMouseStatus(DRAWPOLY, 0, FALSE); SetHandCursor(drawWindow); while (naming) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ConfigureNotify) { Reconfigure(FALSE); } else if (input.xany.window == drawWindow && input.type == ButtonPress) { if (input.xbutton.button == Button1) { if (drawPolyHighlightedNode != NULL) { HandlePressForPortInDrawWindow(FALSE); DoNameOrClearAPort(which); drawPolyHighlightedNode = NULL; SetWiringNodeInfo(NULL, NULL, NULL, TRUE); SetHandCursor(drawWindow); ShowCurChoiceMouseStatus(DRAWPOLY, 0, FALSE); } } else { XUngrabPointer(mainDisplay, CurrentTime); naming = FALSE; HandlePressForPortInDrawWindow(TRUE); } } else if (input.xany.window == drawWindow && input.type == MotionNotify) { XEvent ev; HandleMotionForPortInDrawWindow(input.xmotion.x, input.xmotion.y); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { XUngrabPointer(mainDisplay, CurrentTime); naming = FALSE; HandlePressForPortInDrawWindow(TRUE); } } } SetDefaultCursor(drawWindow); } static void RenameOrClearSignalNameForAPort(which) int which; { XGCValues values; MakeQuiescent(); ResetWiringNodeInfo(); connectingPortsByWire = TRUE; connectingPortsFromInternalCommand = FALSE; gstWiringInfo.num_ports_to_connect = which; drawPolyHighlightedNode = NULL; values.line_width = 3; XChangeGC(mainDisplay, revGrayGC, GCLineWidth, &values); SaveStatusStrings(); DoRenameOrClearSignalNameForAPort(which); RestoreStatusStrings(); values.line_width = 1; XChangeGC(mainDisplay, revGrayGC, GCLineWidth, &values); gstWiringInfo.num_ports_to_connect = 0; connectingPortsByWire = FALSE; connectingPortsFromInternalCommand = TRUE; ResetWiringNodeInfo(); drawPolyHighlightedNode = NULL; } void RenameSignalNameForAPort() { RenameOrClearSignalNameForAPort(DO_RENAME_SIGNAL_NAME); } void ClearSignalNameForAPort() { RenameOrClearSignalNameForAPort(DO_CLEAR_SIGNAL_NAME); } static int CheckPortsAndObj(ppAnchor, pnNumPorts) struct ObjRec **ppAnchor; int *pnNumPorts; { int num_ports=0, ok=TRUE; struct ObjRec *anchor=NULL; struct SelRec *sel_ptr=NULL; for (sel_ptr=botSel; ok && sel_ptr != NULL; sel_ptr=sel_ptr->prev) { struct AttrRec *attr_ptr=NULL; switch (sel_ptr->obj->type) { case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: case OBJ_PIN: if ((attr_ptr=FindAttrWithName(sel_ptr->obj, "type=", NULL)) != NULL) { if (strcmp(attr_ptr->attr_value.s, "port") == 0 && FindAttrWithName(sel_ptr->obj, "signal_name=", NULL) != NULL) { num_ports++; } else if (anchor == NULL) { anchor = sel_ptr->obj; } else { return FALSE; } } else if (anchor == NULL) { anchor = sel_ptr->obj; } else { return FALSE; } break; default: return FALSE; break; } } if (anchor == NULL || num_ports == 0) { return FALSE; } *pnNumPorts = num_ports; *ppAnchor = anchor; return TRUE; } void MergePortsWithAnObject() { int num_ports=0; int sel_ltx=selLtX, sel_lty=selLtY, sel_rbx=selRbX, sel_rby=selRbY; struct ObjRec *anchor=NULL; struct SelRec *sel_ptr=NULL; if (!CheckPortsAndObj(&anchor, &num_ports)) { MsgBox(TgLoadString(STID_SEL_ONE_NONE_PORT_PLUS_COMP), TOOL_NAME, INFO_MB); return; } HighLightReverse(); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { if (sel_ptr->obj != anchor) { UnlinkObj(sel_ptr->obj); AddObjToAnchor(anchor, sel_ptr->obj); } } RemoveAllSel(); UnlinkObj(anchor); AddObj(NULL, topObj, anchor); topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->obj = anchor; topSel->prev = NULL; botSel->next = NULL; AdjObjBBox(anchor); UpdSelBBox(); RecordCmd(CMD_MANY_TO_ONE, NULL, topSel, botSel, 1); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } static void RenumberObjId(obj_ptr) struct ObjRec *obj_ptr; { struct AttrRec *attr_ptr=NULL; struct ObjRec *sub_obj=NULL; obj_ptr->id = objId++; switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: for (sub_obj=obj_ptr->detail.r->last; sub_obj != NULL; sub_obj=sub_obj->prev) { RenumberObjId(sub_obj); } break; } for (attr_ptr=obj_ptr->lattr; attr_ptr != NULL; attr_ptr=attr_ptr->prev) { RenumberObjId(attr_ptr->obj); } } void RenumberObjectIds() { struct PageRec *page_ptr=NULL; if (gstWBInfo.do_whiteboard) { MsgBox(TgLoadString(STID_RENUMBER_OBJ_IDS_IN_WB), TOOL_NAME, INFO_MB); return; } if (!OkToFlushUndoBuffer(TgLoadString(STID_RENUMBER_OBJ_IDS_CAUSE_FLUSH))) { return; } MakeQuiescent(); CleanUpCmds(); objId = 0; for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next) { struct ObjRec *obj_ptr=NULL; for (obj_ptr=page_ptr->bot; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { RenumberObjId(obj_ptr); } } MsgBox(TgLoadString(STID_RENUMBER_OBJ_IDS_DONE), TOOL_NAME, INFO_MB); SetFileModified(TRUE); } void MakeSymbolic() { int ltx=selLtX, lty=selLtY, rbx=selRbX, rby=selRbY; struct ObjRec *obj_ptr=NULL; if (curChoice == VERTEXMODE) { MsgBox(TgLoadString(STID_CANT_MAKESYMBOLIC_VERTEX_MODE), TOOL_NAME, INFO_MB); return; } else if (topSel == NULL || topSel != botSel) { MsgBox(TgLoadString(STID_SEL_ONLY_ONE_FOR_MAKESYMBOLIC), TOOL_NAME, INFO_MB); return; } obj_ptr = topSel->obj; if (obj_ptr->type == OBJ_SYM) return; if (obj_ptr->type == OBJ_PIN) { MsgBox(TgLoadString(STID_PIN_CANT_MADE_INTO_SYMBOL), TOOL_NAME, INFO_MB); return; } HighLightReverse(); PrepareToReplaceAnObj(obj_ptr); /* * Need to check for pins. */ if (obj_ptr->type != OBJ_GROUP && obj_ptr->type != OBJ_ICON) { GroupSingleObj(FALSE); obj_ptr = topSel->obj; if (obj_ptr->fattr != NULL) { Msg(TgLoadCachedString(CSTID_ATTR_PROMOTED_TO_NEW_SYMBOL)); } } obj_ptr->type = OBJ_SYM; AdjObjBBox(obj_ptr); UpdSelBBox(); RecordReplaceAnObj(obj_ptr); UpdSelBBox(); RedrawAnArea(botObj, ltx-QUARTER_INCH-GRID_ABS_SIZE(1), lty-QUARTER_INCH-GRID_ABS_SIZE(1), rbx+QUARTER_INCH+GRID_ABS_SIZE(1), rby+QUARTER_INCH+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; Msg(TgLoadString(STID_SEL_OBJ_IS_NOW_SYMBOLIC)); } void UnMakeSymbolic() { register struct ObjRec *obj_ptr; register int ltx=0, lty=0, rbx=0, rby=0; struct SelRec *sel_ptr=topSel; int modified=FALSE; StartCompositeCmd(); for ( ; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; if (obj_ptr->type == OBJ_SYM) { PrepareToReplaceAnObj(obj_ptr); obj_ptr->type = OBJ_GROUP; AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); if (modified) { if (obj_ptr->bbox.ltx < ltx) ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < lty) lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > rbx) rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > rby) rby = obj_ptr->bbox.rby; } else { ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; modified = TRUE; } } } EndCompositeCmd(); if (modified) { HighLightReverse(); UpdSelBBox(); RedrawAnArea(botObj, ltx-QUARTER_INCH-GRID_ABS_SIZE(1), lty-QUARTER_INCH-GRID_ABS_SIZE(1),rbx+QUARTER_INCH+GRID_ABS_SIZE(1), rby+QUARTER_INCH+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } } int MakeIconic(sym_path, record_cmd) char *sym_path; int record_cmd; { char icon_name[MAXPATHLENGTH], file_name[MAXPATHLENGTH]; char icon_full_name[MAXPATHLENGTH], *rest=NULL, *psz=NULL; char sym_ext_str[MAXSTRING]; FILE *fp=NULL; int len, short_name, sym_ext_len, ltx, lty, rbx, rby, no_name=FALSE; if (topSel == NULL || topSel != botSel) { MsgBox(TgLoadString(STID_SEL_ONLY_ONE_FOR_MAKEICONIC), TOOL_NAME, INFO_MB); return FALSE; } if (sym_path == NULL) { *icon_name = '\0'; Dialog(TgLoadString(STID_ENTER_NAME_FOR_THE_ICON), NULL, icon_name); len = strlen(icon_name); if (*icon_name == '\0') { Msg(TgLoadString(STID_NAME_NOT_SPEC_ICON_NOT_CREATE)); return FALSE; } } else { strncpy(icon_name, sym_path, sizeof(icon_name)-1); icon_name[sizeof(icon_name)-1] = '\0'; len = strlen(icon_name); } sprintf(sym_ext_str, ".%s", SYM_FILE_EXT); sym_ext_len = strlen(sym_ext_str); if (FileNameHasExtension(icon_name, OBJ_FILE_TYPE, NULL, NULL)) { MsgBox(TgLoadString(STID_CANT_SAVE_OBJ_ICON_NOT_CREATE), TOOL_NAME, INFO_MB); return FALSE; } else if (FileNameHasExtension(icon_name, SYM_FILE_TYPE, NULL, NULL)) { strcpy(icon_full_name, icon_name); if ((psz=UtilStrRChr(icon_name, '.')) != NULL) { *psz = '\0'; } else { TgAssert(FALSE, TgLoadString(STID_CANT_FIND_DOT_IN_ICON_NAME_MI), NULL); return FALSE; } } else if (FileNameHasExtension(icon_name, PIN_FILE_TYPE, NULL, NULL)) { MsgBox(TgLoadString(STID_CANT_SAVE_PIN_ICON_NOT_CREATE), TOOL_NAME, INFO_MB); return FALSE; } else { strcpy(icon_full_name, icon_name); strcat(icon_full_name, sym_ext_str); } if (no_name) { MsgBox(TgLoadString(STID_NO_FILE_NAME_FILE_NOT_SAVED), TOOL_NAME, INFO_MB); return FALSE; } if (sym_path == NULL) { sprintf(file_name, "%s%c%s", curDir, DIR_SEP, icon_full_name); } else { strcpy(file_name, icon_full_name); } if (!OkayToCreateFile(file_name)) return FALSE; if ((short_name=IsPrefix(bootDir, file_name, &rest))) ++rest; if ((fp=fopen(file_name, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_FOR_WRITE_ICON_CRET), (short_name ? rest : file_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (sym_path == NULL) { if (!DirInSymPath(curDir)) UpdateSymInfo(); } sprintf(gszMsgBox, TgLoadCachedString(CSTID_CREATING_FILE_DOTS), (short_name ? rest : file_name)); Msg(gszMsgBox); SetStringStatus(gszMsgBox); ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; if (record_cmd) { PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); } if (topSel->obj->type == OBJ_GROUP || topSel->obj->type == OBJ_SYM || topSel->obj->type == OBJ_ICON || topSel->obj->type == OBJ_PIN) { JustMoveSelToTop(); } else { GroupSingleObj(FALSE); if (topSel->obj->fattr != NULL) { Msg(TgLoadCachedString(CSTID_ATTR_PROMOTED_TO_NEW_ICON)); } } topSel->obj->type = OBJ_SYM; strcpy(topSel->obj->detail.r->s, icon_name); topSel->obj->detail.r->rotate = ROTATE0; topSel->obj->detail.r->flip = NO_FLIP; topSel->obj->detail.r->deck_index = (-1); /* * Need to check for pins. * Need to handle the case where connection objects need to be dupped! */ topSel->obj->detail.r->pin_connected = 0; topSel->obj->detail.r->first_conn = topSel->obj->detail.r->last_conn = NULL; writeFileFailed = FALSE; Save(fp, topSel->obj, 0, 1); if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(file_name); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_NAMED_FILE_CREATED), (short_name ? rest : file_name)); Msg(gszMsgBox); } fclose(fp); if (record_cmd) { HighLightReverse(); } topSel->obj->type = OBJ_ICON; topSel->obj->id = objId++; Msg(TgLoadString(STID_SEL_OBJ_IS_NOW_ICONIC)); AdjObjBBox(topSel->obj); UpdSelBBox(); if (record_cmd) { RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); ltx = min(ltx,selLtX); lty = min(lty,selLtY); rbx = max(rbx,selRbX); rby = max(rby,selRbY); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } return TRUE; } void UnMakeIconic() { register struct ObjRec *obj_ptr; struct SelRec *sel_ptr; struct AttrRec *attr_ptr; int modified=FALSE; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; /* * Need to check for pins. */ if (obj_ptr->type == OBJ_ICON) { modified = TRUE; PrepareToReplaceAnObj(obj_ptr); obj_ptr->type = OBJ_GROUP; attr_ptr = obj_ptr->fattr; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { attr_ptr->inherited = FALSE; } AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); } } EndCompositeCmd(); if (modified) { Msg(TgLoadString(STID_SEL_OBJS_ARE_NOW_GROUP)); UpdSelBBox(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; } HighLightForward(); } typedef struct ImportAttrLineRec { char *s; struct ImportAttrLineRec *next, *prev; } *ImportAttrLineRecPtr; static struct ImportAttrLineRec *firstLine=NULL, *lastLine=NULL; static int numLines=0, nextX=0, nextY=0; static CVList gLineList; static void AddLine(buf) char *buf; { struct ImportAttrLineRec *line_ptr; line_ptr = (struct ImportAttrLineRec *)malloc( sizeof(struct ImportAttrLineRec)); if (line_ptr == NULL) FailAllocMessage(); line_ptr->s = buf; line_ptr->next = NULL; line_ptr->prev = lastLine; if (lastLine == NULL) { firstLine = line_ptr; } else { lastLine->next = line_ptr; } lastLine = line_ptr; numLines++; } static void FreeImportLines() { struct ImportAttrLineRec *next_line=NULL; for ( ; firstLine != NULL; firstLine=next_line) { next_line = firstLine->next; if (firstLine->s != NULL) free(firstLine->s); free(firstLine); } lastLine = NULL; numLines = 0; } static void ImportAnAttr(obj_ptr, attr_line_num, fname) struct ObjRec *obj_ptr; int attr_line_num; char *fname; { int ok=TRUE; char *c_ptr; if (firstLine == NULL) return; if ((c_ptr=strchr(firstLine->s, '=')) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_LINE_SKIP_NOT_AN_ATTR), attr_line_num, fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else { *c_ptr = '\0'; if (strchr(firstLine->s, '!') != NULL || strchr(firstLine->s, '.') != NULL) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_LINE_SKIP_ILLEGAL_CHAR), attr_line_num, fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } *c_ptr = '='; } if (ok) { char saved_ch='\0', *attr_name=NULL; struct AttrRec *attr_ptr=NULL; struct TextRec *text_ptr=NULL; MiniLineInfo *pMiniLine=NULL, *pFirstMiniLine=NULL, *pLastMiniLine=NULL; struct ImportAttrLineRec *line_ptr; int move_next_y=FALSE, underline_on=FALSE, single_font_text=FALSE; int sz_unit=INVALID, double_byte=INVALID, font=INVALID, style=INVALID; int color_index=INVALID, saved_color_index=INVALID, overline_on=FALSE; c_ptr++; saved_ch = (*c_ptr); *c_ptr = '\0'; attr_name = UtilStrDup(firstLine->s); if (attr_name == NULL) FailAllocMessage(); *c_ptr = saved_ch; if ((attr_ptr=FindAttrWithName(obj_ptr, attr_name, NULL)) == NULL) { attr_ptr = AddAttrByNameAndValue(obj_ptr, attr_name, c_ptr); attr_ptr->shown = TRUE; attr_ptr->obj->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(attr_ptr->obj->color_str, sizeof(attr_ptr->obj->color_str), colorMenuItems[colorIndex]); } MoveObj(attr_ptr->obj, nextX-attr_ptr->obj->x, nextY-attr_ptr->obj->y); text_ptr = attr_ptr->obj->detail.t; pFirstMiniLine = pLastMiniLine = text_ptr->minilines.first; move_next_y = TRUE; } else { MiniLineInfo *pNextMiniLine=NULL; single_font_text = SingleFontText(attr_ptr->obj->detail.t, &sz_unit, &double_byte, &font, &style, &underline_on, &overline_on) && SingleColorText(attr_ptr->obj->detail.t, &color_index); if (single_font_text) { saved_color_index = colorIndex; PushCurFont(); colorIndex = color_index; curFont = font; curSzUnit = sz_unit; curStyle = style; SetCanvasFont(); } DynStrSet(&attr_ptr->attr_value, c_ptr); text_ptr = attr_ptr->obj->detail.t; text_ptr->cached_zoom = 0; if (text_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, text_ptr->cached_bitmap); } text_ptr->cached_bitmap = None; for (pMiniLine=text_ptr->minilines.first->next; pMiniLine != NULL; pMiniLine=pNextMiniLine) { pNextMiniLine = pMiniLine->next; FreeMiniLine(pMiniLine); } pFirstMiniLine = pLastMiniLine = text_ptr->minilines.last = text_ptr->minilines.first; text_ptr->minilines.first->next = text_ptr->minilines.first->prev = NULL; text_ptr->lines = 1; UpdAttr(attr_ptr); } free(attr_name); for (line_ptr=firstLine->next; line_ptr!=NULL; line_ptr=line_ptr->next) { CreateMiniLineFromString(line_ptr->s, &pFirstMiniLine, &pLastMiniLine); text_ptr->lines++; } if (single_font_text) { colorIndex = saved_color_index; PopCurFont(); } text_ptr->minilines.first = pFirstMiniLine; text_ptr->minilines.last = pLastMiniLine; text_ptr->baseline_y = attr_ptr->obj->y+pFirstMiniLine->asc; RecalcTextMetrics(text_ptr, attr_ptr->obj->x, text_ptr->baseline_y); UpdTextBBox(attr_ptr->obj); if (move_next_y) { nextY += attr_ptr->obj->obbox.rby-attr_ptr->obj->obbox.lty; } } FreeImportLines(); } void ImportAttrs() { char fname[MAXPATHLENGTH+1], *rest, *buf; XEvent ev; int short_name, ltx, lty, rbx, rby, line_num=0, attr_line_num=1; int empty_line=TRUE; FILE *fp; struct ObjRec *obj_ptr; if (topSel == NULL || topSel != botSel) { MsgBox(TgLoadString(STID_SEL_ONE_OBJ_FOR_IMPORTATTRS), TOOL_NAME, INFO_MB); return; } if (SelectFileNameToImport(TgLoadString(STID_SEL_TEXT_FILE_OF_ATTR_TO_IMP), TEXT_FILE_EXT, fname) == INVALID) { return; } else if (FileIsRemote(fname)) { MsgBox(TgLoadString(STID_CANT_IMPORT_REMOTE_TEXT_FILE), TOOL_NAME, INFO_MB); return; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } if ((short_name=IsPrefix(bootDir, fname, &rest))) ++rest; if ((fp=fopen(fname, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), (short_name ? rest : fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } obj_ptr = topSel->obj; ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); HighLightReverse(); PrepareToReplaceAnObj(obj_ptr); nextX = obj_ptr->obbox.ltx; nextY = obj_ptr->obbox.rby; while ((buf=UtilGetALine(fp)) != NULL) { line_num++; if (empty_line) { empty_line = FALSE; attr_line_num = line_num; } if (*buf == '\0') { ImportAnAttr(obj_ptr, attr_line_num, fname); empty_line = TRUE; } else { AddLine(buf); } } ImportAnAttr(obj_ptr, attr_line_num, fname); fclose(fp); AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); SetDefaultCursor(mainWindow); ShowCursor(); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), obj_ptr->bbox.ltx-GRID_ABS_SIZE(1), obj_ptr->bbox.lty-GRID_ABS_SIZE(1), obj_ptr->bbox.rbx+GRID_ABS_SIZE(1), obj_ptr->bbox.rby+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } #define INA_SKIP 0 /* skip this attribute */ #define INA_OK 1 /* import this attribute */ #define INA_MALFORMED 2 /* illegal attribute */ #define INA_NEW 3 /* import this new attribute */ static int OkayToImportNamedAttr(num_restricted, ppsz_restricted) int num_restricted; char **ppsz_restricted; { int i=0, found=FALSE, rc=INA_OK; char *psz=NULL, saved_ch='\0'; if (firstLine == NULL || firstLine->s == NULL) return INA_SKIP; psz = strchr(firstLine->s, '='); if (psz == NULL) { sprintf(gszMsgBox, TgLoadString(STID_BAD_LINE_MAY_HAVE_DEL_EQUAL), firstLine->s); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return INA_MALFORMED; } saved_ch = *(++psz); *psz = '\0'; for (i=0; i < num_restricted; i++) { char *attr_name=ppsz_restricted[i]; if (strcmp(attr_name, firstLine->s) == 0) { found = TRUE; break; } } *psz = saved_ch; if (!found) { rc = INA_SKIP; *psz = '\0'; sprintf(gszMsgBox, TgLoadString(STID_ATTR_NAME_CHANGED_IMPORT_Q), firstLine->s); switch (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB)) { case MB_ID_YES: rc = INA_NEW; break; case MB_ID_NO: break; case MB_ID_CANCEL: break; } *psz = saved_ch; } return rc; } typedef struct tagLineInfo { int status; int attr_line_num; int num_lines; struct ImportAttrLineRec *first, *last; } LineInfo; static void CreateLineInfo(status, attr_line_num) int status, attr_line_num; { LineInfo *pli=(LineInfo*)malloc(sizeof(LineInfo)); if (pli == NULL) FailAllocMessage(); memset(pli, 0, sizeof(LineInfo)); pli->status = status; pli->attr_line_num = attr_line_num; pli->num_lines = numLines; pli->first = firstLine; pli->last = lastLine; firstLine = lastLine = NULL; numLines = 0; ListAppend(&gLineList, pli); } static void DoImportNamedAttrs(fp, num_restricted, ppsz_restricted, pn_ok_count, pn_skip_count, pn_bad_count) FILE *fp; int num_restricted, *pn_ok_count, *pn_skip_count, *pn_bad_count; char **ppsz_restricted; { char *buf=NULL; int bad_count=0, skip_count=0, ok_count=0, status=0; int line_num=0, attr_line_num=1, just_read_separator=TRUE; CVListInit(&gLineList); while ((buf=UtilGetALine(fp)) != NULL) { line_num++; if (just_read_separator) { just_read_separator = FALSE; attr_line_num = line_num; } if (strstr(buf, gszAttrSeparator) != NULL) { status = OkayToImportNamedAttr(num_restricted, ppsz_restricted); switch (status) { case INA_SKIP: skip_count++; FreeImportLines(); break; case INA_OK: ok_count++; CreateLineInfo(status, attr_line_num); break; case INA_MALFORMED: bad_count++; FreeImportLines(); break; case INA_NEW: ok_count++; CreateLineInfo(status, attr_line_num); break; } just_read_separator = TRUE; } else { AddLine(buf); } } if (!just_read_separator) { status = OkayToImportNamedAttr(num_restricted, ppsz_restricted); switch (status) { case INA_SKIP: skip_count++; FreeImportLines(); break; case INA_OK: ok_count++; CreateLineInfo(status, attr_line_num); break; case INA_MALFORMED: bad_count++; FreeImportLines(); break; case INA_NEW: ok_count++; CreateLineInfo(status, attr_line_num); break; } } if (pn_ok_count != NULL) *pn_ok_count = ok_count; if (pn_skip_count != NULL) *pn_skip_count = skip_count; if (pn_bad_count != NULL) *pn_bad_count = bad_count; } int ImportNamedAttrs(fp, obj_ptr, num_restricted, ppsz_restricted, fname) FILE *fp; struct ObjRec *obj_ptr; int num_restricted; char **ppsz_restricted, *fname; { int ltx=0, lty=0, rbx=0, rby=0, bad_count=0, skip_count=0, ok_count=0; CVListElem *elem=NULL; ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; DoImportNamedAttrs(fp, num_restricted, ppsz_restricted, &ok_count, &skip_count, &bad_count); if (bad_count > 0) { sprintf(gszMsgBox, TgLoadString(STID_CANT_IMPORT_ATTR_GROUP_RETRY), TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (ListEmpty(&gLineList)) return TRUE; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); HighLightReverse(); PrepareToReplaceAnObj(obj_ptr); nextX = obj_ptr->obbox.ltx; nextY = obj_ptr->obbox.rby; for (elem=ListFirst(&gLineList); elem != NULL; elem=ListNext(&gLineList, elem)) { LineInfo *pli=(LineInfo*)(elem->obj); if (pli != NULL) { int attr_line_num=pli->attr_line_num; firstLine = pli->first; lastLine = pli->last; numLines = pli->num_lines; ImportAnAttr(obj_ptr, attr_line_num, fname); } elem->obj = NULL; } ListUnlinkAll(&gLineList); AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); SetDefaultCursor(mainWindow); ShowCursor(); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), obj_ptr->bbox.ltx-GRID_ABS_SIZE(1), obj_ptr->bbox.lty-GRID_ABS_SIZE(1), obj_ptr->bbox.rbx+GRID_ABS_SIZE(1), obj_ptr->bbox.rby+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; return TRUE; } void ExportAttrs() { char fname[MAXPATHLENGTH+1], full_fname[MAXPATHLENGTH+1]; char *c_ptr, *dot_ptr, *rest; int short_name; FILE *fp; struct AttrRec *attr_ptr; if (topSel == NULL || topSel != botSel) { MsgBox(TgLoadString(STID_SEL_ONE_OBJ_FOR_EXPORTATTRS), TOOL_NAME, INFO_MB); return; } else if (topSel->obj->lattr == NULL) { MsgBox(TgLoadString(STID_SEL_OBJ_HAS_NO_ATTR_TO_EXPORT), TOOL_NAME, INFO_MB); return; } sprintf(gszMsgBox, TgLoadString(STID_WORKING_DIRECTORY_IS), (curDirIsLocal ? curDir : curLocalDir)); *fname = '\0'; Dialog(TgLoadString(STID_ENTER_TXT_FILE_TO_EXPORT_CRES), gszMsgBox, fname); if (*fname == '\0') return; if (*fname == DIR_SEP) { strcpy(full_fname, fname); } else { sprintf(full_fname, "%s%c%s", curDirIsLocal ? curDir : curLocalDir, DIR_SEP, fname); } if ((c_ptr=UtilStrRChr(full_fname, (int)DIR_SEP)) == NULL) { if ((dot_ptr=UtilStrRChr(full_fname, (int)'.')) == NULL) { sprintf(&full_fname[strlen(full_fname)], ".%s", TEXT_FILE_EXT); } else { if (strcmp(&dot_ptr[1], TEXT_FILE_EXT) != 0) { sprintf(&dot_ptr[strlen(dot_ptr)], ".%s", TEXT_FILE_EXT); } } } else { if ((dot_ptr=UtilStrRChr(c_ptr, (int)'.')) == NULL) { sprintf(&c_ptr[strlen(c_ptr)], ".%s", TEXT_FILE_EXT); } else { if (strcmp(&dot_ptr[1], TEXT_FILE_EXT) != 0) { sprintf(&dot_ptr[strlen(dot_ptr)], ".%s", TEXT_FILE_EXT); } } } if (!OkayToCreateFile(full_fname)) return; if ((short_name=IsPrefix(bootDir, full_fname, &rest))) ++rest; if ((fp=fopen(full_fname, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), (short_name ? rest : full_fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_WRITING_ATTR_TO_NAMED_FILE), (short_name ? rest : full_fname)); Msg(gszMsgBox); writeFileFailed = FALSE; for (attr_ptr=topSel->obj->lattr; !writeFileFailed && attr_ptr != NULL; attr_ptr=attr_ptr->prev) { MiniLineInfo *pMiniLine=NULL; if (attr_ptr != topSel->obj->lattr) fprintf(fp, "\n"); if (fprintf(fp, "%s%s\n", attr_ptr->attr_name.s, attr_ptr->attr_value.s) == EOF) { writeFileFailed = TRUE; } if (!writeFileFailed && (pMiniLine=attr_ptr->obj->detail.t->minilines.first) != NULL) { for (pMiniLine=pMiniLine->next; !writeFileFailed && pMiniLine != NULL; pMiniLine=pMiniLine->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); if (fprintf(fp, "%s\n", tmp_buf) == EOF) { writeFileFailed = TRUE; } if (need_to_free_tmp_buf) UtilFree(tmp_buf); if (writeFileFailed) break; } } } if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(full_fname); } else { sprintf(gszMsgBox, TgLoadString(STID_ATTR_EXPORTED_TO_NAMED_FILE), (short_name ? rest : full_fname)); Msg(gszMsgBox); } fclose(fp); } static int GetMergeSpec(obj_ptr, attr_name, pn_val, distance) struct ObjRec *obj_ptr; char *attr_name; int *pn_val, distance; { struct AttrRec *attr_ptr=FindAttrWithName(obj_ptr, attr_name, NULL); char *c_ptr; double val; if (attr_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_ATTR_FOR_MERGEWTBL), attr_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (distance && ((c_ptr=strstr(attr_ptr->attr_value.s, "in")) != NULL || (c_ptr=strstr(attr_ptr->attr_value.s, "In")) != NULL || (c_ptr=strstr(attr_ptr->attr_value.s, "IN")) != NULL)) { char saved_ch=(*c_ptr); *c_ptr = '\0'; if (sscanf(attr_ptr->attr_value.s, "%lf", &val) != 1) { *c_ptr = saved_ch; sprintf(gszMsgBox, TgLoadString(STID_MALFORMED_ATTR_FOR_MERGEWTBL), attr_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } *c_ptr = saved_ch; val = val * ((double)PIX_PER_INCH); *pn_val = round(val); } else if (distance && ((c_ptr=strstr(attr_ptr->attr_value.s, "cm")) != NULL || (c_ptr=strstr(attr_ptr->attr_value.s, "Cm")) != NULL || (c_ptr=strstr(attr_ptr->attr_value.s, "CM")) != NULL)) { char saved_ch=(*c_ptr); *c_ptr = '\0'; if (sscanf(attr_ptr->attr_value.s, "%lf", &val) != 1) { *c_ptr = saved_ch; sprintf(gszMsgBox, TgLoadString(STID_MALFORMED_ATTR_FOR_MERGEWTBL), attr_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } *c_ptr = saved_ch; val = val * ((double)ONE_CM); *pn_val = round(val); } else { if (sscanf(attr_ptr->attr_value.s, "%d", pn_val) != 1) { sprintf(gszMsgBox, TgLoadString(STID_MALFORMED_ATTR_FOR_MERGEWTBL), attr_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } return TRUE; } void MergeWithTable() { char fname[MAXPATHLENGTH+1], *rest, paper_size_spec[80], *spec, **col_names; char *buf, *c_ptr, *val_ptr; XEvent ev; int i, short_name, columns_in_file, ok=TRUE, line_num, user_placement; int left_margin=0, top_margin=0, v_pitch=0, h_pitch=0, strip_double_quotes; int num_cols=0, num_rows=0, paper_w=0, paper_h=0, x, y, r, c; int tab_separated=TRUE; FILE *fp; struct ObjRec *template_obj; if (topSel == NULL || topSel != botSel) { MsgBox(TgLoadString(STID_SEL_ONE_OBJ_FOR_MERGEWTBL), TOOL_NAME, INFO_MB); return; } /* do not translate -- program constants */ template_obj = topSel->obj; user_placement = (FindAttrWithName(template_obj, "USER_PLACEMENT", NULL) != NULL); strip_double_quotes = (FindAttrWithName(template_obj, "STRIP_DOUBLE_QUOTES", NULL) != NULL); if (!user_placement) { /* do not translate -- program constants */ if (!(GetMergeSpec(template_obj, "LEFT_MARGIN=", &left_margin, TRUE) && GetMergeSpec(template_obj, "TOP_MARGIN=", &top_margin, TRUE) && GetMergeSpec(template_obj, "V_PITCH=", &v_pitch, TRUE) && GetMergeSpec(template_obj, "H_PITCH=", &h_pitch, TRUE) && GetMergeSpec(template_obj, "NUM_COLS=", &num_cols, FALSE) && GetMergeSpec(template_obj, "NUM_ROWS=", &num_rows, FALSE) && GetMergeSpec(template_obj, "PAPER_WIDTH=", &paper_w, TRUE) && GetMergeSpec(template_obj, "PAPER_HEIGHT=", &paper_h, TRUE))) { return; } } while (!DirIsRemote(curDir) && fileModified && !IsFiletUnSavable()) { XBell(mainDisplay, 0); switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_MERGE), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: SetFileModified(FALSE); break; case MB_ID_CANCEL: return; } } if (firstCmd != NULL) { if (MsgBox(TgLoadString(STID_Q_MERGEWTBL_CANT_UNDO_PROCEED), TOOL_NAME, YNC_MB) != MB_ID_YES) { return; } CleanUpCmds(); } if (SelectFileNameToImport(TgLoadString(STID_SEL_TEXT_FILE_FOR_MERGEWTBL), TEXT_FILE_EXT, fname) == INVALID) { return; } else if (FileIsRemote(fname)) { MsgBox(TgLoadString(STID_CANT_MERGE_W_REMOTE_TEXT_FILE), TOOL_NAME, INFO_MB); return; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } if ((short_name=IsPrefix(bootDir, fname, &rest))) ++rest; if ((fp=fopen(fname, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), (short_name ? rest : fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if ((spec=UtilGetALine(fp)) == NULL) { fclose(fp); sprintf(gszMsgBox, TgLoadString(STID_FIND_COL_NAMES_IN_FILE_ABORT), (short_name ? rest : fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } columns_in_file = 1; val_ptr = spec; c_ptr = strchr(val_ptr, '\t'); if (c_ptr == NULL && (c_ptr=strchr(val_ptr, ';')) != NULL) { tab_separated = FALSE; Msg(TgLoadCachedString(CSTID_SEMICOLON_USED_AS_SEPARATOR)); } else { Msg(TgLoadCachedString(CSTID_TAB_USED_AS_SEPARATOR)); } while (val_ptr != NULL) { if (c_ptr != NULL) *c_ptr = '\0'; if (*val_ptr == '\0') { free(spec); fclose(fp); sprintf(gszMsgBox, TgLoadString(STID_MALFORMED_COL_NAMES_ABORT_MRG), (short_name ? rest : fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (c_ptr == NULL) break; *c_ptr++ = (tab_separated ? '\t' : ';'); val_ptr = c_ptr; c_ptr = strchr(val_ptr, tab_separated ? '\t' : ';'); columns_in_file++; } col_names = (char**)malloc((columns_in_file+1)*sizeof(char*)); if (col_names == NULL) { free(spec); fclose(fp); FailAllocMessage(); return; } col_names[columns_in_file] = NULL; i = 0; val_ptr = spec; for (c_ptr=strchr(val_ptr, tab_separated ? '\t' : ';'); val_ptr != NULL; i++) { int len; if (c_ptr != NULL) *c_ptr = '\0'; if (!tab_separated) { UtilTrimBlanks(val_ptr); if (strip_double_quotes && *val_ptr == '"') { len = strlen(val_ptr); if (val_ptr[len-1] == '"') { val_ptr[len-1] = '\0'; val_ptr++; } } } len = strlen(val_ptr); if ((col_names[i]=(char*)malloc((len+2)*sizeof(char))) == NULL) { FailAllocMessage(); columns_in_file = i; for (i=0; i < columns_in_file; i++) { if (col_names[i] != NULL) { free(col_names[i]); } } free(col_names); free(spec); fclose(fp); return; } sprintf(col_names[i], "%s=", val_ptr); if (FindAttrWithName(template_obj, col_names[i], NULL) == NULL) { free(col_names[i]); col_names[i] = NULL; } if (c_ptr == NULL) break; *c_ptr++ = (tab_separated ? '\t' : ';'); val_ptr = c_ptr; c_ptr = strchr(val_ptr, tab_separated ? '\t' : ';'); } free(spec); MakeQuiescent(); UnlinkObj(template_obj); NewProc(); if (pageLayoutMode == PAGE_TILE) { PageLayoutSubMenu(PAGE_STACK); while (lastPageNum > 1) { DeleteCurPage(); } } if (!user_placement) { sprintf(paper_size_spec, "%1d x %1d", paper_w, paper_h); if (!SetPaperSize(paper_size_spec)) { return; } printMag = (float)100.0; UpdPageStyle(PORTRAIT); } UpdDrawWinBBox(); AdjSplineVs(); RedrawScrollBars(); RedrawRulers(); RedrawTitleWindow(); SaveStatusStrings(); if (user_placement) { strcpy(gszMsgBox, TgLoadString(STID_LF_BTN_PLACE_MRG_OTHER_CANCEL)); Msg(gszMsgBox); SetStringStatus(gszMsgBox); } line_num = 1; x = left_margin; y = top_margin; r = c = 0; while (ok && (buf=UtilGetALine(fp)) != NULL) { struct ObjRec *obj_ptr=DupObj(template_obj); if (obj_ptr == NULL) { ok = FALSE; free(buf); break; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_PROCESSING_OBJ_NUMBER), line_num); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); AddObj(NULL, topObj, obj_ptr); AdjObjBBox(obj_ptr); MoveObj(obj_ptr, x-obj_ptr->obbox.ltx, y-obj_ptr->obbox.lty); line_num++; i = 0; val_ptr = buf; replaceAttrFirstValueRedraw = FALSE; for (c_ptr=strchr(val_ptr, tab_separated ? '\t' : ';'); val_ptr != NULL; i++) { struct AttrRec *attr_ptr; if (c_ptr != NULL) *c_ptr = '\0'; if (col_names[i] != NULL && (attr_ptr=FindAttrWithName(obj_ptr, col_names[i], NULL)) != NULL) { if (!tab_separated) UtilTrimBlanks(val_ptr); if (strip_double_quotes && *val_ptr == '"') { int len=strlen(val_ptr); if (val_ptr[len-1] == '"') { val_ptr[len-1] = '\0'; ReplaceAttrFirstValue(obj_ptr, attr_ptr, &val_ptr[1]); val_ptr[len-1] = '"'; } else { ReplaceAttrFirstValue(obj_ptr, attr_ptr, val_ptr); } } else { ReplaceAttrFirstValue(obj_ptr, attr_ptr, val_ptr); } } if (c_ptr == NULL) break; *c_ptr++ = (tab_separated ? '\t' : ';'); val_ptr = c_ptr; c_ptr = strchr(val_ptr, tab_separated ? '\t' : ';'); } replaceAttrFirstValueRedraw = TRUE; UnlinkObj(obj_ptr); if (firstCmd != NULL) CleanUpCmds(); if (i+1 != columns_in_file) { ok = FALSE; sprintf(gszMsgBox, TgLoadString(STID_MALFORMED_TBL_LINE_ABORT_MRG), line_num, (short_name ? rest : fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); FreeObj(obj_ptr); ClearAndRedrawDrawWindow(); } else { struct AttrRec *attr_ptr=NULL; int saved_history_depth=historyDepth; AdjObjBBox(obj_ptr); AddObj(NULL, topObj, obj_ptr); if (user_placement) { if ((attr_ptr=FindAttrWithName(obj_ptr, "name=", NULL)) != NULL) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_PLACING_NAMED_OBJ), attr_ptr->attr_value.s); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); } if (PlaceTopObj(obj_ptr, NULL, NULL) == Button3) { Msg(TgLoadString(STID_OPERATION_CANCEL_BY_USER)); ok = FALSE; } AssignNewObjIds(obj_ptr); } numRedrawBBox = 0; obj_ptr->tmp_parent = NULL; DrawObj(drawWindow, obj_ptr); /* do not translate -- program constants */ if ((attr_ptr=FindAttrWithName(obj_ptr, "EXEC_AFTER_MERGE=", NULL)) != NULL) { char name[MAXSTRING+1]; struct AttrRec *next_attr_ptr=NULL; if (*attr_ptr->attr_value.s != '\0') { sprintf(name, "%s=", attr_ptr->attr_value.s); if ((next_attr_ptr=FindAttrWithName(obj_ptr, name, NULL)) != NULL) { int saved_intr_check_interval=intrCheckInterval; intrCheckInterval = 1; ShowInterrupt(1); if (!DoExec(next_attr_ptr, obj_ptr)) { ok = FALSE; } while (HideInterrupt() > 0) ; intrCheckInterval = saved_intr_check_interval; } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_FND_NAMED_ATTR_ABORT_MRG), attr_ptr->attr_value.s); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } } attr_ptr = next_attr_ptr; } else if ((attr_ptr=FindAttrWithName(obj_ptr, EXEC_ATTR, NULL)) != NULL) { int saved_intr_check_interval=intrCheckInterval; intrCheckInterval = 1; ShowInterrupt(1); if (!DoExec(attr_ptr, obj_ptr)) { ok = FALSE; } while (HideInterrupt() > 0) ; intrCheckInterval = saved_intr_check_interval; } if (saved_history_depth != historyDepth) RestoreDefaultHistoryDepth(); if (firstCmd != NULL) CleanUpCmds(); if (ok && !user_placement) { c++; if (c >= num_cols) { c = 0; x = left_margin; r++; if (r >= num_rows) { r = 0; y = top_margin; AddPageAfter(); } else { y += v_pitch; } } else { x += h_pitch; } } } free(buf); } fclose(fp); RestoreStatusStrings(); sprintf(gszMsgBox, TgLoadString(STID_NUM_OBJECTS_GENERATED), line_num-1); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); FreeObj(template_obj); for (i=0; i < columns_in_file; i++) { if (col_names[i] != NULL) { free(col_names[i]); } } free(col_names); if (firstCmd != NULL) CleanUpCmds(); SetFileModified(TRUE); justDupped = FALSE; } void ExportToTable() { char msg[MAXSTRING+1], fname[MAXPATHLENGTH+1], full_fname[MAXPATHLENGTH+1]; char *c_ptr, *dot_ptr, *rest=NULL, *spec, *spec_copy, **col_names=NULL, *buf; int short_name, total, i, num_exported, buf_sz, ok=TRUE; FILE *fp; struct AttrRec *spec_attr=NULL; MiniLineInfo *pMiniLine=NULL; struct SelRec *sel_ptr=NULL; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } /* do not translate -- program constants */ strcpy(msg, "!.TABLE_ATTRS="); spec_attr = FindAttrWithName(NULL, msg, NULL); if (spec_attr == NULL) { MsgBox(TgLoadString(STID_CANT_FND_TABLE_ATTRS_FILE_ATT), TOOL_NAME, INFO_MB); return; } sprintf(gszMsgBox, TgLoadString(STID_WORKING_DIRECTORY_IS), (curDirIsLocal ? curDir : curLocalDir)); *fname = '\0'; Dialog(TgLoadString(STID_ENTER_TXT_FILE_TO_EXPORT_CRES), gszMsgBox, fname); if (*fname == '\0') return; if (*fname == DIR_SEP) { strcpy(full_fname, fname); } else { sprintf(full_fname, "%s%c%s", curDirIsLocal ? curDir : curLocalDir, DIR_SEP, fname); } if ((c_ptr=UtilStrRChr(full_fname, (int)DIR_SEP)) == NULL) { if ((dot_ptr=UtilStrRChr(full_fname, (int)'.')) == NULL) { sprintf(&full_fname[strlen(full_fname)], ".%s", TEXT_FILE_EXT); } else { if (strcmp(&dot_ptr[1], TEXT_FILE_EXT) != 0) { sprintf(&dot_ptr[strlen(dot_ptr)], ".%s", TEXT_FILE_EXT); } } } else { if ((dot_ptr=UtilStrRChr(c_ptr, (int)'.')) == NULL) { sprintf(&c_ptr[strlen(c_ptr)], ".%s", TEXT_FILE_EXT); } else { if (strcmp(&dot_ptr[1], TEXT_FILE_EXT) != 0) { sprintf(&dot_ptr[strlen(dot_ptr)], ".%s", TEXT_FILE_EXT); } } } if (!OkayToCreateFile(full_fname)) return; if ((short_name=IsPrefix(bootDir, full_fname, &rest))) ++rest; if ((fp=fopen(full_fname, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), (short_name ? rest : full_fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_WRITING_ATTRS_IN_TBL_FORM_TO), (short_name ? rest : full_fname)); Msg(gszMsgBox); writeFileFailed = FALSE; total = 0; for (pMiniLine=spec_attr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); total += strlen(tmp_buf)+1; if (need_to_free_tmp_buf) UtilFree(tmp_buf); } if ((spec=(char*)malloc((total+1)*sizeof(char))) == NULL) { FailAllocMessage(); fclose(fp); return; } c_ptr = spec; for (pMiniLine=spec_attr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { int len=0, need_to_free_tmp_buf=FALSE; char *tmp_buf=NULL; if (pMiniLine == spec_attr->obj->detail.t->minilines.first) { char *attr_value=NULL; tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); attr_value = UtilStrDup(tmp_buf); if (attr_value == NULL) FailAllocMessage(); ParseAttrStr(tmp_buf, NULL, 0, attr_value, strlen(attr_value)+1); if (need_to_free_tmp_buf) UtilFree(tmp_buf); need_to_free_tmp_buf = TRUE; tmp_buf = attr_value; } else { tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); } len = strlen(tmp_buf); strcpy(c_ptr, tmp_buf); if (need_to_free_tmp_buf) UtilFree(tmp_buf); c_ptr += len; *c_ptr++ = ','; } *c_ptr = '\0'; if ((spec_copy=UtilStrDup(spec)) == NULL) { FailAllocMessage(); free(spec); fclose(fp); return; } total = 0; for (c_ptr=strtok(spec_copy, " ,;\t\n\r"); c_ptr != NULL; c_ptr=strtok(NULL, " ,;\t\n\r")) { total++; } free(spec_copy); buf_sz = 0x400; spec_copy = UtilStrDup(spec); col_names = (char**)malloc((total+1)*sizeof(char*)); buf = (char*)malloc((buf_sz+2)*sizeof(char)); if (spec_copy == NULL || col_names == NULL || buf == NULL) { FailAllocMessage(); if (col_names != NULL) free(col_names); if (spec_copy != NULL) free(spec_copy); if (buf != NULL) free(buf); free(spec); fclose(fp); return; } col_names[total] = NULL; i = 0; for (c_ptr=strtok(spec_copy, " ,;\t\n\r"); c_ptr != NULL && !writeFileFailed; c_ptr=strtok(NULL, " ,;\t\n\r"), i++) { int len=strlen(c_ptr); if ((col_names[i]=(char*)malloc((len+2)*sizeof(char))) == NULL) { FailAllocMessage(); for (total=0; total < i; total++) free(col_names[i]); free(col_names); free(spec_copy); free(buf); free(spec); fclose(fp); return; } if (fprintf(fp, "%s%s", (i==0 ? "" : "\t"), c_ptr) == EOF) { writeFileFailed = TRUE; } sprintf(col_names[i], "%s=", c_ptr); } fprintf(fp, "\n"); num_exported = 0; SaveStatusStrings(); for (sel_ptr=botSel; ok && sel_ptr != NULL; sel_ptr=sel_ptr->prev) { int percent=(i*10000/numObjSelected)/100, col; int something_exported=FALSE, cur_len=0; sprintf(gszMsgBox, TgLoadCachedString(CSTID_PROGRESS_PERCENT), percent); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); for (col=0; ok && col < total; col++) { int len; struct AttrRec *attr_ptr=FindAttrWithName(sel_ptr->obj, col_names[col], NULL); if (attr_ptr != NULL) something_exported = TRUE; sprintf(gszMsgBox, "%s%s", (col==0 ? "" : "\t"), (attr_ptr==NULL ? "": attr_ptr->attr_value.s)); len = strlen(gszMsgBox); while (len+cur_len >= buf_sz) { buf_sz += 0x400; buf = (char*)realloc(buf, (buf_sz+2)*sizeof(char)); if (buf == NULL) { FailAllocMessage(); ok = FALSE; break; } } if (ok) { sprintf(&buf[cur_len], gszMsgBox); cur_len += len; } } buf[cur_len] = '\0'; if (something_exported) { num_exported++; if (fprintf(fp, "%s\n", buf) == EOF) { writeFileFailed = TRUE; ok = FALSE; } } } RestoreStatusStrings(); sprintf(gszMsgBox, TgLoadString(STID_NUM_OBJECTS_EXPORTED), num_exported); Msg(gszMsgBox); for (i=0; i < total; i++) free(col_names[i]); free(col_names); free(spec_copy); if (buf != NULL) free(buf); free(spec); fclose(fp); if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(full_fname); } else { sprintf(gszMsgBox, TgLoadString(STID_ATTRS_EXPORTED_TO_TBL_FILE), (short_name ? rest : full_fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } void ToggleShowWireSignalName() { showWireSignalName = !showWireSignalName; sprintf(gszMsgBox, TgLoadString(showWireSignalName ? STID_WILL_SHOW_WIRE_SIGNAL_NAME : STID_WILL_HIDE_WIRE_SIGNAL_NAME)); Msg(gszMsgBox); } int RefreshPortMenu(menu) TgMenu *menu; { int ok=TRUE; /* Show Wire Signal Name */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLESHOWWIRESIGNALNAME, showWireSignalName); return ok; } TgMenu *CreatePortMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshPortMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshPortMenu); } return menu; } void RefreshSpecialMenu(menu) TgMenu *menu; { } int SpecialMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(specialMenuInfo.create_proc)(NULL, X, Y, &specialMenuInfo, FALSE); activeMenu = MENU_SPECIAL; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } void CleanUpSpecial() { } int InitSpecial() { char *c_ptr=NULL; showWireSignalName = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ShowWireSignalName")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { showWireSignalName = FALSE; } return TRUE; } tgif-QPL-4.2.5/tgifdefs.h0000644000076400007640000001040711602233313014733 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgifdefs.h,v 1.10 2011/05/16 16:22:00 william Exp $ */ #ifndef _TGIFDEFS_H_ #define _TGIFDEFS_H_ #ifdef HAVE_CONFIG_H #include "config.h" #endif /* HAVE_CONFIG_H */ #include #include #include #include #include #include #include #include #include #include #ifdef HAVE_GETTIMEOFDAY #undef _NO_GETTIMEOFDAY #endif /* HAVE_GETTIMEOFDAY */ #ifdef _NO_GETTIMEOFDAY #include #endif /* _NO_GETTIMEOFDAY */ #ifdef isc /* SunSoft/Interactive UNIX */ #include #include #endif /* isc */ #if !defined(FD_SET) #include #endif /* !defined(FD_SET) */ #ifdef HAVE_CONFIG_H /* * If HAVE_CONFIG_H is defined, it means that "configure" (and not imake) * should be used to build tgif. */ #ifdef HAVE_SYS_DIR_H #include #define DIR_ENTRY struct direct #else /* ~HAVE_SYS_DIR_H */ #ifdef HAVE_DIRENT_H #include #define DIR_ENTRY struct dirent #else /* ~HAVE_DIRENT_H */ #include "vms_comp.h" #define DIR_ENTRY struct dirent #endif /* HAVE_DIRENT_H */ #endif /* HAVE_SYS_DIR_H */ #else /* ~HAVE_CONFIG_H */ /* * If HAVE_CONFIG_H is not defined, it means that tgif should * be built with imake (and not with "configure"). */ #ifdef VMS #include "vms_comp.h" #define DIR_ENTRY struct dirent #else /* ~VMS */ #ifdef ibm #include #define DIR_ENTRY struct direct #else /* ~ibm */ #ifdef apollo #include #define DIR_ENTRY struct direct #else /* ~apollo */ #ifdef NeXT #include #define DIR_ENTRY struct direct #else /* ~NeXT */ #ifdef luna88k #include #define DIR_ENTRY struct direct #else /* ~luna88k */ #ifdef sequent #include #define DIR_ENTRY struct direct #else /* ~sequent */ #include #define DIR_ENTRY struct dirent #endif /* sequent */ #endif /* luna88k */ #endif /* NeXT */ #endif /* apollo */ #endif /* ibm */ #endif /* VMS */ #endif /* HAVE_CONFIG_H */ #ifdef __NetBSD__ #if !defined(__ELF__) && !defined(mips) #define _DL_EXPORT_UNDERSCORE #else /* ~(!defined(__ELF__) && !defined(mips)) */ #ifdef _DL_EXPORT_UNDERSCORE #undef _DL_EXPORT_UNDERSCORE #endif /* _DL_EXPORT_UNDERSCORE */ #endif /* !defined(__ELF__) && !defined(mips) */ #endif /* __NetBSD__ */ #ifdef NOT_DEFINED /* * On some Mac OS X systems, libdl.dylib exists but there is no . * Not sure if someone deleted or it's a problem with the * system. */ #ifdef HAVE_LIBDL #undef _NO_DL_SUPPORT #endif /* HAVE_LIBDL */ #endif /* NOT_DEFINED */ #ifndef _NO_DL_SUPPORT #include #ifndef RTLD_GLOBAL #define RTLD_GLOBAL 0 #endif /* ~RTLD_GLOBAL */ #endif /* ~_NO_DL_SUPPORT */ #include #include #include #include #include #include #include #include #include #ifdef HAVE_STDINT_H #include #endif /* HAVE_STDINT_H */ #ifdef _ENABLE_NLS #ifndef ENABLE_NLS #define ENABLE_NLS #endif /* ~ENABLE_NLS */ #endif /* _ENABLE_NLS */ #ifndef _NO_LOCALE_SUPPORT #ifdef ENABLE_NLS #include #endif /* ENABLE_NLS */ #endif /* ~_NO_LOCALE_SUPPORT */ #include #include #include #include #include #ifndef _NO_LOCALE_SUPPORT #include #endif /* ~_NO_LOCALE_SUPPORT */ #include "const.h" #include "types.h" #endif /*_TGIFDEFS_H_*/ tgif-QPL-4.2.5/spline.e0000644000076400007640000000670111602233312014430 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/spline.e,v 1.25 2011/05/16 16:21:59 william Exp $ */ #ifndef _SPLINE_E_ #define _SPLINE_E_ extern int intSplineTension; extern int splineTol; extern int tighterStructSplines; extern double splineFactor3; extern double splineFactor4; extern double curveToFactor; #ifdef _INCLUDE_FROM_SPLINE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_SPLINE_C_*/ extern int ReadSplineTightness ARGS_DECL((char*)); extern void CalcAutoRetractedArrowAttrBend ARGS_DECL((int Style, int X0, int Y0, int X2, int Y2, int *X1, int *Y1)); extern IntPoint *GetStructuredSplinePolyTickMarkVs ARGS_DECL((int *pn_N, struct ObjRec *, struct PolyRec *, struct PolygonRec *)); extern IntPoint *GetStructuredSplinePolygonTickMarkVs ARGS_DECL((int *pn_N, int NumVs, IntPoint *Vs)); extern IntPoint *MakeStructuredSplinePolyVertex ARGS_DECL((int *pn_N, char **ppszSmooth, int NumVs, IntPoint *Vs)); extern IntPoint *MakeStructuredSplinePolygonVertex ARGS_DECL((int *pn_N, char **ppszSmooth, int NumVs, IntPoint *Vs)); extern XPoint *MakeSplinePolyVertex ARGS_DECL((int Level, int Curved, int *N, int XOff, int YOff, int NumVs, IntPoint *)); extern XPoint *MakeMultiSplinePolyVertex ARGS_DECL((int Curved, int *N, char *Smooth, int XOff, int YOff, int NumVs, IntPoint *)); extern XPoint *MakeSplinePolygonVertex ARGS_DECL((int Level, int Curved, int *N, int XOff, int YOff, int NumVs, IntPoint *)); extern XPoint *MakeMultiSplinePolygonVertex ARGS_DECL((int Curved, int *N, char *Smooth, int XOff, int YOff, int NumVs, IntPoint*)); extern XPoint *MakeIntSplinePolyVertex ARGS_DECL((int *N, int *CntrlN, IntPoint **CntrlVs, int XOff, int YOff, int NumVs, IntPoint *)); extern XPoint *MakeIntSplinePolygonVertex ARGS_DECL((int *N, int *CntrlN, IntPoint **CntrlVs, int XOff, int YOff, int NumVs, IntPoint*)); extern XPoint *MakeDoubleIntSplinePolygonVertex ARGS_DECL((int *N, int *CntrlN, DoublePoint**CntrlVs, int XOff, int YOff, int NumVs, DoublePoint*)); extern void DumpCurvedPolyPoints ARGS_DECL((FILE*, int Curved, int NumPts, IntPoint*, int Indent)); extern void DumpCurvedPolygonPoints ARGS_DECL((FILE*, int Curved, int NumPts, IntPoint*, int Indent)); extern void DumpMultiCurvedPolyPoints ARGS_DECL((FILE*, char *Smooth, int Style, int Curved, int NumPts, IntPoint*, int Indent)); extern void DumpMultiCurvedPolygonPoints ARGS_DECL((FILE*, char *Smooth, int Curved, int NumPts, IntPoint*, int Indent)); #ifdef _INCLUDE_FROM_SPLINE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_SPLINE_C_*/ #endif /*_SPLINE_E_*/ tgif-QPL-4.2.5/ChangeLog0000644000076400007640000024123711602233310014545 0ustar williamwilliam-----------------------> tgif-4.2.4 => tgif-4.2.5 <----------------------- 1) Fix a crashing bug when copying a string with non-simple text (e.g., has superscript or subscript). -----------------------> tgif-4.2.3 => tgif-4.2.4 <----------------------- 1) Fix a bug that caused a crash during a Patse operation after the CopyPlainTextAsObject() command has been executed. 2) Fix a crashing bug with GetBoundingBox() when the current linetype is "structured splines". 3) Fix a few compiler-related bugs so that tgif can be compiled under Solaris. A new compiler option (_NO_XUTF8FUNCTIONS) is added so that the Xutf8TextListToTextProperty() is not referenced. 4) Further fix the license problem with "nkf.e", "chinput.e", and "cli_xcin.e". Thanks to Carlo U. Segre for pointing out the additional problems. -----------------------> tgif-4.2.2 => tgif-4.2.3 <----------------------- 1) Fix a bug with pasting garbage characters from Windows under cygwin. This used to cause file corruption. 2) Fix a bug with double-byte characters or international characters when eglibc is used. Thanks to Gunter Frenz , Hiroshi TSUTSUI , and Klaus Koepernik for pointing out the problem and Hiroshi TSUTSUI for the patch. 3) Allow Tgif.EnableTrueColorImages to be set to "true" only if tgif is compiled with zlib support. Also, starting with this version, if one has a TrueColor display, Tgif.EnableTrueColorImages is set to "true" by default. 4) Add support a new built-in double-byte input method, tgchgb, to support the input of gb2312 encoded simplified Chinese characters using a graphical zhu-yin-fu-hao keypad (would also accept pinyin directly). This input method is activated by typing when a double-byte chinese font is selected. On Windows systems, may be used by a Windows input method. If this is the case, one should type instead. 5) Allow Flood Fill and Replace Color to use a threshold value. Add new X defaults, Tgif.EnableThresholdFloodReplaceColor and Tgif.FloodReplaceColorThreshold to set default values for this feature. 6) Better support for transparent pixels for X11 pixmap objects. 7) Add -D_NO_LOCALE_SUPPORT to CFLAGS in Makefile.am so that, by default, tgif will be compiled without locale support if the configure script is used to build tgif. 8) Add a new X default, Tgif.NoOrientationIfPdfSetPageDevice, so that the "%%Orientation:" line is not used in the PostScript file if "setpagedevice" is active when exporting a PS/EPS/PDF file. 9) Add "eq4-2x-nowin-jpg.sym" to be used instead of "eq4-2x-jpg.sym" to run silently (i.e., no popup window). This should get around the problem that on cygwin, sometimes a popup window will not close by itself. 10) Add new X defaults, Tgif.PNGExportHasTransparentColor, Tgif.PNGExportTransparentColor, and Tgif.PpmToPngWithTransparentColor to suppor the generation of transparent PNG files. 11) Add new X defaults, Tgif.UseStdPalette8, Tgif.UseStdPalette27, Tgif.UseStdPalette64, Tgif.UseStdPalette216/Tgif.UseMobileWebSafePalette, Tgif.UseOpenOfficeGalaxyPalette, and Tgif.UseOpenOfficeGooglePalette to use a standard 8-color, 27-color, 64-color, 216-color, 53-color, and 80-color palette as the startup colors for tgif. Also added Tgif.AdditionalColors to take effect if any of these X defaults are used. 12) Add a new X default, Tgif.DefaultColor, so that the default tgif color can be specified using a color name. 13) Obsolete the Tgif.DeleteCmdAsCut X default. Now Cntrl+x is bound to the Cut command. To delete something without cutting it into the cut buffer, one can use the key on the keyboard or select Delete from the Edit Menu. 14) Fix a license problem. The files, "nkf.c", "chinput.c", and "cli_xcin.c" do not have compatible license with the QPL license. Therefore, starting with this release, they will be removed (and replaced by empty files) from the QPL distribution of tgif (and -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN must be used in MISCDEFINES in Tgif.tmpl to avoid compiler errors). These files will only be available in the free-of-charge distribution of tgif. Thanks to Carlo U. Segre for pointing out the problem. -----------------------> tgif-4.2.1 => tgif-4.2.2 <----------------------- 1) Fix a bug with parsing Tgif.AdditionalFonts. Thanks to Thomas Sefzick for pointing out the bug. 2) Fix a bug with copying and pasting in cygwin. By default, tgif no longer uses the old style X cut buffer. 3) Fix a bug with copying UTF-8 characters in cygwin. 4) Fix a bug when Tgif.EnableTrueColorImages is set to "true" and positions of true color (i.e., ppm_true) objects do not show up correctly. 5) In printing/exporting to a PS/EPS/PDF file, if a text object is simple (i.e., single line with no superscript, subscript, or horizontal thin space) and it has a background fill pattern, generate PostScript code to draw a horizontally tighter boundingbox. 6) Add InsertSymbol() under the Text submenu of the Edit Menu. 7) Add a very simple right-margin feature when entering text. This is far from a full-featured right-margin. It is only activated under the following conditions: text cursor is at the last position in the text object being edited (i.e., appending to the current text object), text object is not transformed, text is left-justified, text cursor is not inside a superscript or a subscript, no zoom, and Tgif.EditTextSize is not used. Tgif.RightMargin can be used to specify the right margin. Tgif.EnableRightMargin can be used to enable this feature. Add EnableRightMargin() and SpecifyRightMargin() under the Show/Hide submenu of the Layout Menu. 8) Add overline for text objects. 9) Add "eq4jpg.sym" and "eq4-2x-jpg.sym" to be used instead of "eq4xpm.sym" if "eq4xpm.sym" gives you an all-black or all-white image. The problem was that there is a bug in ImageMagick's "convert" when converting EPS file to a PPM file. With "eq4jpg.sym" and "eq4-2x-jpg.sym", "convert" will be called to convert an EPS file to a JPEG file with "-scale 25% -density 576" as commandline parameters. These two new symbol files are best used with Tgif.EnableTrueColorImages set to "true". 10) Remove Tgif.TighterStructuredSplines from the documentation since this X default is invalid. 11) Add the following internal commands: set_selected_text_overline() -----------------------> tgif-4.2 => tgif-4.2.1 <----------------------- 1) Fix a bug with rotated circles. 2) Fix a bug with c not working on Mac OS X. 3) Fix a bug in Imakefile which would fail to install some icon files during "make install". -----------------------> tgif-4.1.45 => tgif-4.2 <----------------------- 1) Fix bugs with copy and paste. Thanks to Dr. Ing. Dieter Jurzitza for pointing out the bug and helping to find the problem. 2) Fix a bug with the pstoepsi() internal command so that tgif does not crash if pbmtoxbm is not installed. Thanks to Yannick Morvan for pointing out the bug. 3) Fix a bug with pinned shape menu. The problem was that text cannot be entered immediately after a shape is created, Thanks to Paul Lew for pointing out the bug. 4) Fix a crashing bug which happens when Tgif.DefFixedWidthFont is used and a non-existent double-byte font is specified in the X resource file. 5) Fix a bug with Tgif.DeleteCmdAsCut. It was not handled like the way it said in the man pages. 6) Incorporate the following patches from the Fedora RPM package (tgif-4.1.45-5.fc8.src.rpm): tgif-4.1.35-overthespot_fix.patch tgif-4.1.44-xim-bad-focus.patch tgif-4.1.45-fontcheck.patch tgif-QPL-4.1.45-open-with-mode.patch tgif.gif tgif-4.1.41.ja.po (in po/ja) tgif-4.1ja9.tar.gz (in po/ja) tgif-wrapper.sh (in po/ja) tgif.desktop (in po/ja) tgif.spec (in po/ja) The following patch is not applied since it did not look correct. tgif-textcursor-a-urasim.patch I don't understand why the most-significant-bit is cleared no matter what. The original code in tgif right below this patch suppose to handle the situation correctly. 7) Fix a bug with composing international characters. In newer Linux releases, UTF8 characters are used by default when international characters are composed. These UTF8 characters are often multi-byte characters so they needed to be converted to single-byte in order to use X11 fonts. To get this to work, tgif loads "libidn" dynamically and calls functions in "libidn" to do the conversion. If your system does not have "libidn", you can use the -D_NO_IDNLIB compiler option so that tgif will not attempt to load "libidn". 8) Fix typos in "tgif.pl". Thanks to Carlo Segre for pointingn out the bugs. 9) Fix various mistakes in "tgif.man". Thanks to Shigeharu TAKENO for the patch. 10) Rename the Tgif.IconPixmap X default to Tgif.WMIconPixmap. If this is not done, Xtoolkit will interpret this X default and display an error message. Thanks to Dr. Ing. Dieter Jurzitza for pointing out the problem. 11) Export in the SVG (Scalable Vector Graphics) format. This requires "uniconvertor" (which is part of the "uniconvertor" package) and "pstoedit" (which is part of the "pstoedit" package). One known limitation of "uniconvertor" is that it cannot convert bitmap/pixmap patterns/objects. 12) Add support for user-specified rotation pivot. 13) Add support for "structured splines" where cubic Bezier curves are used. The Tgif.SplineRubberband X default became obsolete. 14) Add "eq4png.sym" to be used instead of "eq4xpm.sym" if "eq4xpm.sym" gives you an all-black or all-white image. The problem was that there is a bug in ImageMagick's "convert" when converting EPS file to a PPM file. With "eq4png.sym", "convert" will be called to convert an EPS file to a PNG file. 15) Integrate the Tangram Whiteboard feature into tgif on Linux machines. This feature used to be experimental (enabled if compiled with the -D_TGIF_WB2 option). Now the authors of the Reliable IP-multicast Library (distributed in the "rmcast" subdirectory of tgif) believe that "rmcast" is mature enough, the interface to "rmcast" is now enabled by default (but not activated unless you run tgif with the "-tgwb2" commandlinen optoin). If you want to try this feature, you might want to make sure that your network interface card has multicast turned on (using "ifconfig multicast") and your firewall is not blocking the multicast port used by the whiteboard (default address is 225.1.2.3). You can try adding "... -p udp -d 225.1.2.0/24 -s 127.0.0.1 -j ACCEPT" to /etc/sysconfig/iptables. The "libz" and "libpthread" libraries are required to interface with the "rmcast" library. Therefore, "-lz -lpthread" must be used in Tgif.tmpl. If your system does not have "libz", you can use the -D_NO_LIBZ compiler option and remove "-lz" from Tgif.tmpl. If your system does not have "libpthread", you can remove "-DPTHREAD" and "-lpthread" from Tgif.tmpl. Thanks to Jorge Allyson Azevedo and other members of the research group lead by Professor Edmundo de Souze e Silva at the Federal University of Rio de Janeiro. 16) Add a new X default, Tgif.EnableTrueColorImages, so that on TrueColor displays, X11 pixmap and JPEG objects can have all the colors. Internally, tgif stores them as deflated (using zlib) PPM files. Therefore, this feature requires zlib and pbmplus to be installed on your system. 17) Add a new X default, Tgif.CustomPatternDir, so that tgif can replace the default patterns for fills and pens with custom ones. Thanks to Daniel Bauer for the patch. 18) Add a new X default, Tgif.ReportMissingFonts, so that tgif can report missing fonts when it starts. 19) Add new X defaults, Tgif.@@@ConvFromUTF8 and Tgif.@@@ConvToUTF8, where @@@ is the name of a double-byte font, to convert between UTF8-encoded strings and strings of the named double-byte font. The specified commands are used in the new Copy and Paste Double Byte (UTF8) Strings operations under the Edit Menu. 20) Add a new X default, Tgif.DefaultLatin1FontCharEncoding, so that the 4 default fonts (Times, Courier, Helvetica, and NewCentury) can use character encoding other than iso8859-1. Newer Linux systems seem to have only a small number of font sizes available for these fonts. The scalable and pre-installed version of these fonts are all iso10646-1 encoded. This is best for creating new tgif files. There may be a slight compatibity problem with existing tgif files because the iso10646-1 fonts seem to be taller than their iso8859-1 counterparts. 21) Add Tgif.tmpl-dragonfly (identical to Tgif.tmpl-netbsd) for DragonFly BSD. 22) Enable printing for X11 pixmap objects having too many colors (as long as it does not have transparent pixels). 23) Add "configure" to the distribution so that on systems that does not have "imake", a "Makefile" can be created by running "./configure". This is new and has only been tested on a few platforms. If this does not work on certain systems, please send an e-mail to the author. Thanks! 24) Add a dependency in the tgif.spec file to declare that tgif depends on the xorg-x11-fonts-ISO8859-1-75dpi, ghostscript, and netpbm-progs packages. If you install tgif using an RPM file, you must have these three packages installed before you can install tgif. 25) Add the following internal commands: random_permute_lines_in_attr() find_obj_names_on_all_pages(,) -----------------------> tgif-4.1.44 => tgif-4.1.45 <----------------------- 1) Fix a bug with the create_arc_obj() internal command. Thanks to Jack Tucker for pointing out the bug. 2) Fix a bug with measurements in the ruler window when Tgif.ShowMeasure is active. Thanks to Olin Johnson for pointing out the bug. 3) Fix a bug with "tgif -print -pdf". Thanks to Rob for pointing out the problem. 4) Fix a bug with copy and paste in cygwin. Thanks to Tobias Naehring for fixing the bug. 5) Move tgif's web server to a standard web server port (80). The new tgif home page is now at: http://bourbon.usc.edu/tgif/ 6) Please note that as of 5/16/2006, postings to tgif related groups at Yahoo!Groups are restricted to members only. This is done to cut down SPAM. The affected groups are at: http://groups.yahoo.com/group/tgif4-discuss http://groups.yahoo.com/group/tgif4-howto http://groups.yahoo.com/group/tgif4-bugs http://groups.yahoo.com/group/tgif4-develop If you have registered as a member in a group above, you can now only post via the web interface or by sending an e-mail from your registered e-mail address. Sorry about this inconvenience. But there have been just too much SPAM on these lists. 7) Use the X Selections mechanism to perform copy and paste. 8) Add support for linking to an external JPEG file to save file size (under File->Import). Some editing operations cannot be performed on these linked JPEG objects. However, these objects do not have the color limitation of X11 pixmap objects. Therefore, when they are exported in the PS/EPS formation, they will have a lot more colors. 9) The standard Linux distribution now use Xtoolkit by default (this is done by including -DUSE_XT_INITIALIZE in the MISCDEFINES line and -lXt in the SYS_LIBRARIES line of Tgif.tmpl-linux). One advantage of this is that now it's easy to override X defaults. For example, one can use: tgif -xrm "Tgif.Foreground: red" 10) Add support for Tgif.PSDistillerNoImageCompress so that images in a generated PostScript file will not be compressed by a distiller program such as ps2pdf. Thanks to Dirk Farin for supplying the PostScript code. Please use Tgif.PSDistillerNoImageCompress with care. It has been noticed that generated EPS file may not work well with LaTeX. 11) Add support for Tgif.AdditionalPSSetup (and -pssetup commandline option) so that a user can add additiional user specified PostScript code in the PostScript file header (right before %%EndSetup). 12) Support a new commandline option "-noshowpageineps" so that the "showpage" PostScript command is not generated when printing/exporting in the EPS format when tgif is run with "-print".. 13) Add support for Tgif.PSFontNeedCharSubs and Tgif.PSCharSubs.* so that some characters in the non-ASCII portion of a non-iso8859-1 font can be replaced by user specified PostScript characters. Thanks to Peter Dembinski for the suggestion. 14) Add a new X default, Tgif.DrawTextFuncKey_F#, so that a function key can be associated with a list of internal commands (and activiated only in the text drawing mode). 15) Add the following internal commands: set_selected_text_style() objs_bbox_intersect(,,) delete_all_attr_from_selected_objs() -----------------------> tgif-4.1.43 => tgif-4.1.44 <----------------------- 1) Fix a bug with imagemap generation. Thanks to Jerry Nicholls for the patch. 2) Replace "eq4.sym" and "eq4-2x.sym". These new LaTeX equation symbols do *not* use pstoepsi, ps2epsi, etc. It only requires "latex", "dvips", and "gs" to function. 3) Add the following new internal command: pstoepsi(,,) -----------------------> tgif-4.1.42 => tgif-4.1.43 <----------------------- 1) Fix key problem with Mac OS X (Darwin). The Apple Command Key is mapped to Mod2Mask by default. This will be treated as the (or ) key in tgif. 2) Fix a bug with importing an EPS file generated by ps2epsi. Thanks to Ambrose Li for the patch. 3) Fix tgif to be able to import an EPS file with an 8 bit-per-sample preview bitmap (such as the ones generated by ps2epsi). 4) Get tgif to work with out-of-the-box xcin on Red Hat Linux. Thanks to Ambrose Li for all the help. 5) Add support a new built-in double-byte input method, tgtwb5, to support the input of big5 encoded traditional Chinese characters using a graphical zhu-yin-fu-hao keypad. This input method is activated by typing when a double-byte chinese font is selected. 6) Add chat to tgwb. 7) Support a new commandline option "-sbim xim" to use XIM as the input method for single-byte fonts. This is useful if the X Keyboard Extension is used in inputing international characters (with dead keys). Thanks to Daniel Sadoc Menasche for the contribution. 8) Add a new X default, Tgif.IgnoreSlideShowOfffsetsInFile, so that the slideshow offsets stored in a file can be ignored in the slideshow mode. The reason for this is that the offsets mainly depends on the display and not on the content of the file. The slideshow offsets should be set using the Tgif.SlideShowWindowOffset X default. 9) Add a new LaTeX equation symbol file "eq4-lyx-ps2epsi.sym" in the release to edit the equation with LyX. Thanks to Ed Gatzke for the contribution. 10) Update "ru.po". Thanks to Andrew W. Nosenko for the update. 11) Add -D__EMX__ in Tgif.tmpl-cygwin to fix the problem with calling stat() on pathnames that begins with "//". Thanks to Dr. Ing. Dieter Jurzitza for pointing out the problem. 12) Add support for importing tgif files with the import_file() internal command. 13) Add the following new internal commands: shuffle_obj_to_bottom() set_file_unsavable() -----------------------> tgif-4.1.41 => tgif-4.1.42 <----------------------- 1) Tgif's home has moved from University of Maryland to University of Southern California. The new tgif home page is now: http://bourbon.usc.edu:8001/tgif/ 2) If there's no domain resources specified in the X resource file, tgif will use the library path specified when tgif is compiled as the default. This is the directory where the equation symbols are installed. Thanks to A. Sengupta for pointing out the problem. 3) For Red Hat 7.2, /usr/bin/xpmtoppm cannot handle input file whose format is XPM version 1. Suport for a new compiler option, -D_XPM3TOPPM, is added so that tgif can generate XPM format version 3 by default. This is has the same effect as setting Tgif.XPmOutputVersion to 3 and Tgif.UseXPmVersion1ForImageMap to false. 4) Add more information in the tooltip when Tgif.MeasureTooltipVerbose is set to true. 5) Add a new LaTeX equation symbol file "eq4xpm.sym" in the release. Instead of generating and embedding an EPS file, this new object will generate and embed an XPM file with additional controls. Please open this file with tgif for more details and check out http://bourbon.usc.edu:8001/tgif/faq/eq4xpm.html. Thanks to Kai Sattler for the contribution. 6) Fix a bug in tgwb when a text object is being edited. 7) Obsolete the Tgif.LandscapePdfSetPageDevice X default (because the name was misleading) and add support for a new X default, Tgif.PdfSetPageDevice. As mentioned in the release notes for tgif-4.1.39, the use of this should not be necessary in the future (and is considered a bug in ps2pdf). The old commandline option, "-nolandpdfspd" is also obsolete and is replaced by "-pdfspd=yes" and "-pdfspd=no". 8) Add a new X default, Tgif.NoModeWindow, so that tgif can start without a mode window. 9) Add a new X default, Tgif.MakeUnsavableInSlideShow, so that the current file will be made unsavable when slideshow mode is entered. (If the current file contains auto page numbering objects, the file will be made unsavable regardless of the setting of this X default.) 10) Update the Reliable IP-multicast Library (distributed in the rmcast subdirectory of this distribution). The new version allows point-to-point connection between 2 whiteboards. Please see the updated README.tgwb file. Thanks to the team members of the research group lead by Professor Edmundo de Souze e Silva at the Federal University of Rio de Janeiro. -----------------------> tgif-4.1.40 => tgif-4.1.41 <----------------------- 1) A QPL version of this distribution of tgif is simultaneously released. 2) Update the output of the About command in the Help Menu to show that tgif's new mailing list address is tgif4-announce at yahoogroups.com. 3) Fix a bug with "on_resize=" attribute when multiple objects have the same name. Thanks to Alan M Stephenson for pointing out the problem. 4) Fix a bug with Tgif.DeleteCmdAsCut. Thanks to Ralphe Neill for pointing out the problem. 5) Fix a bug with the select_each_obj_and_exec() internal command. Thanks to Dan McMahilll for pointing out the problem. 6) Fix a uninitialized variable bug. This causes things to fail when running tgif with -print -eps commandline options. Thanks to Dan McMahilll for pointing out the problem. 7) Remove a redundant "a4" string in the generates PS file if A4 paper is requested by using the Tgif.PSA4PaperSize X default. This seems to causes ghostscript to generate problematic pnm file. Thanks to AMAKAWA Shuhei for the patch. 8) Add horizontal scroll for mouse wheel. When the key is held down, the mouse wheel can now scroll horizintall. Thanks to Shin-ichi KANNO for the patch. 9) Add a compiler option -D_DONT_REENCODE in Tgif.tmpl* so that a list of PostScript fonts for which reencoding is not allowed can be specified at compile time. Please see the explanation on Tgif.DontReencode in the X DEFAULTS section of the man pages regarding the format of this option. Tgif.DontReencode has precedence over -D_DONT_REENCODE. At run time, if you just want to add fonts to the list specified by -D_DONT_REENCODE, you should use the new Tgif.AdditionalDontReencode X default. A commandline option, -listdontreencode, is added to print out the value of the -D_DONT_REENCODE compiler option used in compiling tgif. 10) Add ConvertToBezier in the Poly/Polygon submenu of the Edit Menu to convert a spline object to a Bezier curve. Thanks to Jurgen Rusch for the conversion script. 11) Add a bunch of commands for adding tick marks to a poly/polygon/spline object. 12) New Tgif.tmpl-darwin file for Darwin/Mac OS X (with XFree86). Thanks to Eric Cronin for providing it. 13) Update tgwb (the tgif-based whiteboard application) to use a new Reliable IP-multicast Library (distributed in the rmcast subdirectory of this distribution). Thanks to the team members of the research group lead by Professor Edmundo de Souze e Silva at the Federal University of Rio de Janeiro. This update fix the problem with large objects mentioned in the README.tgwb file in prior releases. However, it still has the problem that there is no privison made for joining a whileboard in session (escept for selecting New from the File Menu of a tgwb to clear all whiteboards). Please see the updated README.tgwb file. 14) Add a new X default, Tgif.UseXPmVersion1ForXPmDeck, so that when converting a deck of X11 pixmap objects to a GIF animation file, the XPM version specified by Tgif.XPmOutputVersion X default can be used (instead of using version 1 XPM format). 15) Add new X defaults, Tgif.SlideShowWindowOffsets and Tgif.SlideShowBorderColor, so that when converting to set the initial window offsets and border color for the slideshow mode. 16) Add the following new internal commands: edit_attr_in_text_mode() -----------------------> tgif-4.1.39 => tgif-4.1.40 <----------------------- 1) Fix a crashing bug in Specify An Arc when the input is something like "0.9,-,10,20". Thanks to Adrian Bridgett and Jano van Hemert for pointing out the problem. 2) Fix a uninitialized variable bug. This causes crashes sometimes when running tgif with -print -xbm commandline options. Thanks to Alexander Tenbusch for pointing out the problem. 3) Fix a bug with exporting landscape TiffEPSI files. Thanks to Geert Carron for pointing out the bug. 4) Fix a bug with displaying text objects when Color Layers are used and some colors are turned off. Thanks to Johan Vromans for pointing out the bug. 5) Add scroll support for mouse wheel. By default, mouse wheel up is mapped to Button4 and mouse wheel down is mapped to Button5. A new X default, Tgif.EnableMouseWheel, is added so that this can be turned off. Some mouse wheel can generate Button2 events, and this may interfere with scrolling; therefore, another X default, Tgif.Btn2PopupMainMenu, is added so that Button2 events will not popup the Main Menu in the canvas window. Thanks to Juha Takala for providing the information. 6) New Tgif.tmpl-cgywin file. Thanks to Simon Moore for providing it. 7) New Tgif.tmpl-uw7 file. Thanks to Ron Record for providing it. 8) Add a new X default, Tgif.DeleteCmdAsCut so that x can be used Cut selected objects. (Pressing the key on the keyboard will still perform a regular Delete in this case.) -----------------------> tgif-4.1.38 => tgif-4.1.39 <----------------------- 1) Add a new X default, Tgif.LandscapePdfSetPageDevice. Currently, when exporting landscape PDF files, tgif will use a PostScript "setpagedevice" command to rotate the generated PostScript file 270 degrees before calling ps2pdf. This should not be necessary (and is considered a bug in ps2pdf). In the future, this X default can be used to turn off the generation of the "setpagedevice" command when ps2pdf can handle landscape PostScript files correctly. A new commandline option, -nolandpdfspd, to be used in conjunction with -print is also added for the same purpose. Thanks to Johan Vromans for the suggestion. -----------------------> tgif-4.1.37 => tgif-4.1.38 <----------------------- 1) Fix a bug in Print Selected Objects that imported EPS objects are not exporte. Thanks to Ralphe Neill for pointing out the problem. 2) For a tgif file in landscape mode, generate the correct (rotated) PDF file. Thanks to Johan Vromans and Goeran Hanke for the solutions. 3) Update ja.po. Thanks to Jun Nishii for the patch. 4) Add a README file in the spice subdirectory to include some notes on the ports and components feature of tgif. 5) Add a compiler option -D_PRTGIF_USE_ISO_LATIN_1_ALWAYS to always use ISO 8859-1 character set for single-byte characters when running tgif with the -print commandline option. Please only use this if you are sure that you will *never* use other encoding. You can selectively turn off reencoding by using either the Tgif.DontReencode X default or the -dontreencode commandline option. Thanks to Ambrose Li for the patch. -----------------------> tgif-4.1.36 => tgif-4.1.37 <----------------------- 1) Fix a bug that may cause seg faults when reading tgif files. Thanks to Hiroei IMAI for the patch. -----------------------> tgif-4.1.35 => tgif-4.1.36 <----------------------- 1) Fix a bug in Latest Release Info under the Help Menu. Thanks to Dr. Ing. Dieter Jurzitza for pointing out the bug. 2) Fix a bug in handling the Edit Attribute in Editor Context Menu when the edit_attrs_in_context_menu attribute is used. Thanks to Ana Paula for pointing out the problem. -----------------------> tgif-4.1.34 => tgif-4.1.35 <----------------------- 1) Fix a bug with Copy and Paste operations in edit text mode for mixed text objects when the Edit Text Size is non-zero. Thanks to Heiko Scheit for pointing out the problem. 2) Propagate certain DSC comments, such as %%DocumentFonts, %%LanguageLevel, %%Extensions, %%DocumentNeededFonts, and %%DocumentNeedResources, of imported EPS files when printing/exporting in PS/EPS formats. Please note that this does not work with embedded EPS files (until the next major release when a new file format is introduced). Thanks to Johan Vromans for pointing out the problem. 3) Support the use of tempnam() instead of mktemp() due to some security considerations. On systems that do support tempnam(), the _DONT_USE_MKTEMP compiler option can be used to use tempnam() instead of mktemp(). Tgif.tmpl-linux (which is identical to the default Tgif.tmpl), Tgif.tmpl-freebsd, Tgif.tmpl-openbsd, and Tgif.tmpl-netbsd uses -D_DONT_USE_MKTEMP by default. Thanks to Adrian Bridgett for pointing out the problem. 4) Add new X defaults: Tgif.TmpDirInHomeDir and Tgif.TmpDir. Together with the _TMP_DIR_IN_HOME_DIR compiler option, the temporary directory can be specified in a flexible way. 5) Add Create Thumbnails in the Browse submenu of the Import submenu of the File Menu. Add new X defaults, Tgif.ThumbnailGeometry, Tgif.ThumbnailPadding, Tgif.ThumbnailXGap, Tgif.ThumbnailYGap, Tgif.ThumbnailX, and Tgif.ThumbnailY to control the size and placement of the thumbnails. 6) Modify CutPoly() so that it can be used to cut polylines/polygons into segments in select mode. 7) New Tgif.tmpl-sco file. Thanks to Jason Moore for providing it. 8) Add Ports and Signals submenu to the Special Menu. Please see the CONNECTING OBJECTS section of the man pages for details. The symbol files in the spice directory is updated to use the new port symbol. 9) A new License file is included in this release. -----------------------> tgif-4.1.33 => tgif-4.1.34 <----------------------- 1) Fix a crashing bug in drawing linearly transformed arc objects. Apparently, this bug has been around for a long time. Thanks to Hari Radhakrishnan for pointing out the problem. 2) Support the JPEG export format. Add new X defaults, Tgif.XpmToJpeg and Tgif.JpegFileExtension. The default value them are "xpmtoppm %s | cjpeg" and "jpg", respectively. 3) Add a new X default, Tgif.AutoEPSPreviewBitmap, to enable the automatic generation of a preview bitmap when importing a PS/EPS file, if the file does not contain a preview bitmap. (This can be turned on and off from the Import submenu of the File Menu.) The feature also uses a new X default, Tgif.PsToXbm, so that the default PS/EPS to XBM filter can be overridden. The default value for Tgif.PsToXbm is: gs -q -dNOPAUSE -sDEVICE=pbm -sOutputFile=- -- "%s" | pbmtoxbm Please note that the above command usually generates a bitmap that's much larger than image in the file. Tgif automatically trims out the blank space similar to the way pbmtoepsi works. Thanks to Ed Vigmond for the suggestion. -----------------------> tgif-4.1.32 => tgif-4.1.33 <----------------------- 1) Fix a bug that was introduced in tgif-4.1.30 (see item 3 of tgif-4.1.29 => tgif-4.1.30 below). This bug only happens if you are printing black and white PS file with UseGrayScale enabled. Thanks to Dr Milos Ercegovac for pointing out the problem. 2) Fix a JoinPoly() bug in vertex mode. -----------------------> tgif-4.1.31 => tgif-4.1.32 <----------------------- 1) Fix a bug that was introduced in tgif-4.1.30 (see item 2 of tgif-4.1.29 => tgif-4.1.30 below). Thanks to Geert Carron for pointing out the problem. -----------------------> tgif-4.1.30 => tgif-4.1.31 <----------------------- 1) Fix a typo that cause link problems on Linux. 2) Add a new X default, Tgif.AutoWrapMenubar, so that menubar will automatically wrap around. If Tgif.MinimalMenubar is set to false, menubar will always wrap around automatically. -----------------------> tgif-4.1.29 => tgif-4.1.30 <----------------------- 1) There's a bug with measure tooltip that certain X servers would generate extra Expose events while others would not. The result is that rubber-banding does not work when measure tooltip is enabled. The simple solution here is to make the default value of Tgif.UseMeasureTooltip to be false. Also, the default values of both Tgif.MeasureTooltipXFollowMouse and MeasureTooltipYFollowMouse have been changed to false, also. Thanks to Helmut Jarausch for pointing out the problem. 2) Fix a bug with exporting text objects in PS format when the text object is scales or sheared such that its width or height is 0. This bug is detectable by gs6.0. Thanks to Ingo Jankowski for pointing out the problem. 3) Fix a bug with printing text objects in black&white PS file with UseGrayScale enabled. Thanks to Jurgen Rusch for pointing out the problem. 4) To build "tgwb", instead of using Imakefile.tgwb, use a new and easier to maintain file called Target.tmpl. 5) Add -usexlib commandline option to force tgif to ignore the -DUSE_XT_INITIALIZE compile option and use Xlib only. This is useful when the system resource file for tgif is not installed properly or messed up and needs to be bypassed. 6) Add a new X default, Tgif.NoMinWinSize, so that tgif can be started without a minimum size when it is set to true (which is the default value). The problem with the previous tgif is that, by having a minimum window size, some window managers will show the wrong window size when tgif is being resized. 7) Support the importing of JPEG files in the Import submenu of the File Menu. Add a new X default, Tgif.JpegToXpm, so that the import filter can be replaced. By default, it is set to "djpeg -gif -color 222 %s | giftopnm | ppmtoxpm". -----------------------> tgif-4.1.28 => tgif-4.1.29 <----------------------- 1) Fix a bug with mouse action status in the color window if Use Color Layers is selected in the Layout Menu. Thanks to Hal Snyder for pointing out the problem. 2) Add French locale in the distribution. Thanks to Roland Baudin for the contribution. 3) Add ImageProc context submenu for an XPM object. 4) Add Get Property context submenu. 5) If an object has an attribute called "edit_attrs_in_context_menu=", the values (starting from the 2nd line and separated by linebreaks) of this attribute are treated as attribute names. The named attributes will be visible in the Edit Attribute In Editor submenu of the Context Menu. 6) Add Replace Graphic in the Special Menu. After you have selected a graphical object and copy it into the cut buffer, you can select another object and select Replace Graphic to replace the graphical part of the selected object by what's in the cut buffer. All attributes of the object will be preserved. 7) Add tooltip support for Show Measurement. Thanks to Raphael Dechenaux for the contribution. The following new X defaults are supported (with their default values shown): Tgif.UseMeasureTooltip: true Tgif.MeasureTooltipXFollowMouse: true Tgif.MeasureTooltipYFollowMouse: true Tgif.MeasureTooltipHorizontalPosition: left Tgif.MeasureTooltipVerticalPosition: top Please see the man pages for details. 8) Add README.tgwb and Imakefile.tgwb to make tgif into "tgwb", which is a vector-drawing coorporative whiteboard application based on tgif. Tgwb is tested on Linux and Solaris platforms, and it requires IP-multicast. Thanks to the team members of the research group lead by Professor Edmundo de Souze e Silva at the Federal University of Rio de Janeiro. (Please note that the current release of tgwb has a few known bugs. The major ones being that (1) it uses fixed size buffers in communication; therefore, when you operate on a large object, you may get an error message saying that the operation is canceled. (2) There is no privison made for joining a whileboard in session; the way to get around this problem is to select New from the File Menu of a tgwb to clear all whiteboards.) -----------------------> tgif-4.1.27 => tgif-4.1.28 <----------------------- 1) Fix a bug in undoing and redoing delete operations. -----------------------> tgif-4.1.26 => tgif-4.1.27 <----------------------- 1) Fix a divide-by-zero bug in creating an arc (of the 2nd kind). Thanks to Christoph Kukulies for pointing out the problem. 2) Fix a crashing bug in exiting tgif. Thanks to Wolfgang Glunz for pointing out the problem. 3) Fix a menuing bug in using tgif with the NetManage PC X Server. Thanks to Wolfgang Glunz for pointing out the problem. 4) Fix a bug in exporting to PDF format. With the previous implementation, the PDF file may be generated in the wrong directory. The Tgif.PsToPdf X default now must contain 2 "%s" substrings. The new default value for it is "ps2pdf %s %s". 5) Fix a bug in exporting to GIF format using Print One File Per Page when page file names are specified. Thanks to Hal Snyder for pointing out the problem. 6) The current implementation of the whiteboard has a buffer size limitation. When the buffer size is exceeded, tgif will now print an error message and cancel the operation that causes the buffer overflow. -----------------------> tgif-4.1.25 => tgif-4.1.26 <----------------------- 1) Fix a bug with special characters in the page file name. Thanks to Kyle Bateman for pointing out the problem. 2) Fix NLS bugs for status line. Thanks to Jun Nishii for the patch. 3) Fix an offset problem for obj file generated by pstoedit. Thanks to Wolfgang Glunz for pointing out the problem. 4) Precise Scale Everything now flushes undo buffer and cannot be undone. Thanks to Heiko Scheit for pointing out the problem. 5) Add context menu for the edit text box (Move Edit Text Box can be select to move the edit text box). 6) Add Recently Used Files submenu under the File Menu. The size can be controlled by the Tgif.MaxRecentFiles X default. 7) Include "tgif.spec.in" for creating RPM files. Thanks to Tomasz Kloczko and Roberto A. Oppedisano for the contribution. 8) Assign Cntrl+1 and Cntrl+2 to Screen Capture and Full Screen Capture. 9) In a multipage drawing, will not change drawing mode when moving from page to page. 10) Freehand drawing mode will be entered automatically when entering slideshow mode. The can be overridden with the Tgif.GoHyperSpaceInSlideShow X default. A new X default, Tgif.LineWidthIndexInSlideShow, is added to override the default line width of 4 in slideshow mode. 11) Add a new X default, Tgif.ResetOriginOnAdvancePage, so that tgif can be forced to scroll to the left-top corner of the page with no zoom when pages are advanced. 12) Add a new X default, Tgif.FreeHandCursor, to override the default pencil curosr in the freehand drawing mode. -----------------------> tgif-4.1.24 => tgif-4.1.25 <----------------------- 1) Fix a crashing bug in Insert Right Superscript/Subscript when the text cursor is immediately to the right of a right superscript/subscript string segment. Thanks to Helmut Jarausch for pointing out the problem. -----------------------> tgif-4.1.23 => tgif-4.1.24 <----------------------- 1) Fix a couple of bugs in Print Pages. 2) Fix a bug in "-print -html/-gif -o". Thanks to Eddy De Greef for pointing out the problem. 3) Assign Alt+Cntrl+5 to Insert Right Subscript. 4) Fix Precise Scale Everything to scale line widths, arrow widths, and arrow heights. 5) Add NLS support for the status line. Thanks to Jun Nishii for the patch. 6) New Tgif.tmpl-openbsd. Thanks to Hal Snyder for providing the patch. -----------------------> tgif-4.1.22 => tgif-4.1.23 <----------------------- 1) Fix a bug in handling rotated text object exported from the gnuplot tgif terminal. Thanks to Leana Golubchik for pointing out the problem. 2) Fix a bug in handling the if() internal command when "!*" is used. Thanks to Marko Schuetz for pointing out the problem. 3) If a file contains only one page, Print One File Per Page will still produce a file with file name containing the page number. 4) Add a "-merge" commandline option to merge a list of obj files. 5) Add "Print Pages" to the File and Page Menu. 6) Print One File Page will now prompt to see if the user wants to print only selected pages. 7) Update po/ja/ja.po. Thanks to Jun Nishii for the udpate. 8) Change all Tgif.tmpl* files to use a default of _USE_PS_ADOBE_STRING=\"3.0/3.0\" -----------------------> tgif-4.1.21 => tgif-4.1.22 <----------------------- 1) Fix a crashing bug with right click on an non-existant text object. Thanks to Helmut Jarausch for pointing out the problem. 2) Make Import GIF To X Pixmap Desk under the GIF Animation Submenu of the File Menu work with gifsicle-1.16.1. Thanks to Francis Ngoh for pointing out the problem. 3) Fix a RTLD_NOW not-defined bug for FreeBSD 2.2.2. Thanks to Naofumi TSUJII for the patch. 4) Force non-condensed PS export if the file contains an XPM or an EPS object. 5) Add the following new internal commands: delete_eps_child() delete_xbm_child() delete_xpm_child() -----------------------> tgif-4.1.20 => tgif-4.1.21 <----------------------- 1) Fix a crashing bug with pasting compound object into a modified text object in text mode. 2) Fix a crashing bug with "-print -raw http://...". 3) Fix cursorkey bug. Thanks to Stefan Schippers for pointing out the bug. 4) Fix arrow problems with rotated interpolated splines. Thanks to Heiko Scheit for pointing out the problem. -----------------------> tgif-4.1.19 => tgif-4.1.20 <----------------------- 1) Fix a crashing bug with rotated arcs with very small angles. Thanks to Rainer Krienke for pointing out this ancient bug. 2) Fix a crashing bug when redrawing is interrupted immediately after objects are transformed. -----------------------> tgif-4.1.18 => tgif-4.1.19 <----------------------- 1) Fix a crashing bug with the "Edit Attribute In Editor" context menu when selected attribute has it's name not shown. Thanks to Mohammad Bahathir Hashim for pointing out the problem. -----------------------> tgif-4.1.17 => tgif-4.1.18 <----------------------- 1) Fix a crashing bug with PreciseScaleEverything(). 2) Fix a bug in locating a linked EPS file. Thanks to Ralphe Neill for pointing out the problem. 3) Fix a bug with downloading HTTP URL's. It was waiting when it doesn't need to. 4) Fix a bug with when zoomed all the way in. Thanks to Kyle Bateman for pointing out the problem. 5) Fix a crashing bug with entering into text mode under certain text editing sequence. 6) Fix a crashing bug with "-print -gif" when a tgif file contains XPM objects. Thanks to Eddy De Greef for pointing out the problem. 7) Make a file containing auto page numbering objects unsavable after it has been displayed in the slideshow mode. 8) Polyline drawn in the FreeHand mode will always be drawn with straight line segments. Also, use the current linewidth for creating polylines in the freehand mode. This makes creating polylines in the freehand mode more natural. Thanks to Thomas P. Witelski for the suggestion. -----------------------> tgif-4.1.16 => tgif-4.1.17 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a color bug with a depth 1 display. Thanks to Martin Butkus for the patch. 2) Fix incorrect %%Pages: line in generated PS/EPS files when PrintOnePage() or PageOneFilePerPage() is used. Thanks to Dietrich Bartel for pointing out the problem. 3) Fix an offset problem for obj file generated by external tools, such as pstoedit. Thanks to Wolfgang Glunz for pointing out the problem. 4) Fix a coordinate problem with polygon objects when exporting HTML files. Thanks to Peter Marquardt for pointing out the problem. 5) Fix a bug in locating a linked EPS file. Thanks to Ralphe Neill for pointing out the problem. 6) Move all user strings to a new file, "strtbl.c". Now all user strings (in menues, messageboxes, and dialogboxes) are either in "menuinfo.c" or "strtbl.c". This makes creating localized version of tgif easier. 7) Rename the compiler option _ENABLE_NLS to ENABLE_NLS. 8) Add context menu. If there's an object under the mouse when right-clicked, a context menu is popped up. If there isn't, Mode Menu is popped up. As a consequence, Tgif.Btn3PopupModeMenu is obsolete now. A new X default, Tgif.Editor, is added to specify a text editor to use for editing attributes (when "Edit Attribute in Editor" submenu of the context menu is used). 9) Add "Set HTML Export Template" to the File Menu. Print/export in HTML format will use the template file if it is set. Please see HTML EXPORT TEMPLATE section of the man pages for details. 10) Add a new compiler option, _PS_SEVENBIT_DOUBLEBYTE_TEXT, to allow the generation of JIS PostScript files. Thanks to Kan Sasaki for the patch. 11) Add new X defaults, Tgif.MenuRowsBeforeScroll and Tgif.MenuColsBeforeScroll to control the size of scrollable menus. 12) Add a new X default, Tgif.UndoRedoRestoreDrawingMode, to restore the drawing mode just before an undo/redo operation. 13) Add a new X default, Tgif.ProducedBy, to specify a text editor to use for editing attributes. 14) Allows the default PostScript fonts to be replaced. Please see the information about Tgif.HasAlternateDefaultFonts and related X defaults in the X DEFAULTS section of the man pages for details. Thanks to Victor Wagner for pointing out the problem with the previous implementation. 15) Switch the shortcuts for Undo() and Animate(). Now Cntrl+z is Undo() and Alt+u is Animate(). Also switch the shortcuts for Redo() and ChangeDomain(). Now Cntrl+y is Redo() and Alt+* is ChangeDomain(). -----------------------> tgif-4.1.15 => tgif-4.1.16 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a seg fault bug in InsertRightSuperscript(). Thanks to Shiou-Jhy Ja for pointing out the problem. 2) Fix color bugs with a depth 1 display. Thanks to Martin Butkus for pointing out the problem. 3) Fix a bug with inserting super/subscript while edit text size is non-zero. Thanks to Heiko Scheit for pointing out the problem. 4) Fix some grid lines redraw problems. 5) Fix bugs with TrueColor display for various commands in the ImageProc Menu. 6) Fix a bug with font names when the "-print" commandline argument is used. Thanks to Ambrose Li for pointing out the problem. 7) Add screen capture under the File Menu. 8) Add a new X default, Tgif.DomainInIni, to allow domain info to be stored in ~/.Tgif/domain.ini. This enables all the menu items in the Domain Submenu of the File Menu. 9) Add a new LaTeX equation symbol files "eq4-epstool.sym" in the release. Thanks to LECORDIER Bertrand for the contribution. 10) Assign Alt+Cntrl+6 shortcut key for InsertRightSuperscript(). -----------------------> tgif-4.1.14 => tgif-4.1.15 <----------------------- Here's a short list of added features/bug fixes. 1) Fix problems with multipage files that have imported complex EPS files. Thanks to Dietrich Bartel for pointing out the problem. 2) Fix problems with moving the text cursor with the cursor keys when the text object has a large vertical spacing. Thanks to Tyson Tuttle for pointing out the problem. 3) Switch 2 pairs of the default shortcut keys. Now c is Copy() and v is Paste(). ChangeDomain() now becomes y and Push() becomes y. 4) Support point sizes in Tgif.FontSizes. 5) Change the default value for the Tgif.DontCondensePSFile X default to "true" due to the problem that many EPS files generated by other tools are not compatible with the previous default value of this X default. -----------------------> tgif-4.1.13 => tgif-4.1.14 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug that the initial import directory is the root directory on Solaris and some other machines. -----------------------> tgif-4.1.12 => tgif-4.1.13 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug that importing a XBM/XPM/GIF file changes the working directory. Thanks to Ralphe Neill for pointing out the problem. -----------------------> tgif-4.1.11 => tgif-4.1.12 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a seg fault bug with creating a rotated text. Thanks to Ralphe Neill for pointing out the problem. 2) Fix some grid lines redraw problems. -----------------------> tgif-4.1.10 => tgif-4.1.11 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug with importing EPS file that doesn't have a preview bitmap. Thanks to Marlene Busch for pointing out the problem. 2) To support LaTeX equations better, 3 new LaTeX equation symbol files "eq4.sym", "eq4-ps2epsi.sym", and "eq4-2x.sym" are included in this release. The only difference between "eq4.sym" and "eq4-ps2epsi.sym" is that "eq4.sym" uses "pstoepsi" and "eq4-ps2epsi.sym" uses ghostscript's "ps2epsi". The "eq4-2x.sym" uses the latest "pbmtoepsi" (which uses the new [ -scale value ] command line option) from "netpbm-20may1999" and the latest "pstoepsi" (which knows how to handle the [ -2x ] command line option) to run ghostscript at the 144dpi resolution for generating the preview bitmap. This makes LaTex equations looks good in both X and PS/EPS! Also, all 3 symbol files do not require "simple.tex" which was needed in the old LaTeX Equation package. To obtain the latest "pstoepsi" and "netpbm-20may1999", please visit . 3) Added ToggleEqAttrShown() under the Attribute Submenu of the Special Menu to toggle the "eq=" attribute for the LaTeX equation object. ToggleEqAttrShown() can also be accessed via the 7 keyboard shortcut. -----------------------> tgif-4.1.9 => tgif-4.1.10 <----------------------- Here's a short list of added features/bug fixes. 1) Fix the bug that after you import an EPS file, the current file name is changed to the name of the EPS file. Thanks to Geert Carron for pointing out the bug. 2) Fix a locale bug for HP-UX and fix Tgif.tmpl-hpux. 3) Set the default value of Tgif.UsePsAdobeString back to "false", and the default value of Tgif.MinimalEPS back to "true". Added support to handle compiler options _USE_PS_ADOBE_STRING and _MINIMAL_EPS. -----------------------> tgif-4.1.8 => tgif-4.1.9 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug in handling the importing of PS files generated by xv. Thanks to Michal Bulik for pointing out the problem. 2) Fix locale bugs. Thanks to Atsushi Shimizu for pointing out the problems. 3) Fix a bug with "-print -gif". Thanks to David Richerby for pointing out the problem. 4) Fix a bug in printing/exporting condensed PS/EPS files when the drawing contains certain EPS files (such as the ones generated by Adobe Illustrator). Thanks to Ambrose Li for the patch. 5) Fix a memory hogging bug when objects are moved. Thanks to Robert Schwebel for pointing out the problem and Jason White for looking into the problem. 6) Fix a bug in the File Open dialogbox that if SetDir is pressed when something is selected, a bad directory name is used. Thanks to Andreas Scherbaum for pointing out the problem. 7) Fix a bug so that the actual directory will be used when the user select "../" from a file dialogbox. Thanks to Andreas Scherbaum for pointing out the problem. 8) Fix bugs with panning using and zooming using . Thanks to Kyle Bateman for pointing out the problems. 9) When in the edit text mode, dragging , will now move the edit text (but not the object being edited). Thanks to Shinichiro Shiratake for pointing out the problem with editing text at the left or top edge of the paper. 10) Allow text objects to be broken into lines in BreakUpText(). 11) Set the default stretchable text mode to TRUE. 12) Set the default value of Tgif.UsePaperSizeStoredInFile to TRUE. 13) Set the default print-in-color mode to TRUE (when the "-print" command line option is not used). 14) Remove the concept of a current import directory. 15) New Tgif.tmpl-os2 for OS/2. Also fix some OS/2 dependent stuff. Thanks to Alexander Mai for the patch. 16) Add new X defaults, Tgif.PsRegMarksInTiledPageMode and Tgif.PsRegMarksGray to draw small crosshairs at the corners defining the clipping regions when printing/exporting PS/EPS files in the tiled page mode. 17) Add a new X default, Tgif.PSFontAliases to allow fake font names in Tgif.AdditionalFonts. Using this X default, different encodings of the same PS font can be used. Please see the ADDITIONAL FONTS section of the man pages for details. Thanks to Johan Vromans for many helpful suggestions. 18) Add the following new internal command: set_allow_interrupt() size_named_obj_absolute(,,) get_named_obj_bbox(,,,, ) -----------------------> tgif-4.1.7 => tgif-4.1.8 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a seg fault bug where tgif can't ever start on machines with small amount of virtual memory. This bug was introduced in tgif-4.1.5. The solution is to move some huge data structures inside the experimental #ifdef _TGIF_WB2 sections. Thanks to Dan McMahilll and Doug Robinson for pointing out the problem. 2) Fix bugs with undefined XFontSet on X11R4 Ultrix machines. Thanks to Jason White for pointing out the problem. -----------------------> tgif-4.1.6 => tgif-4.1.7 <----------------------- Here's a short list of added features/bug fixes. 1) Fix bugs in using the wrong export file name when the obj file is gzipped. -----------------------> tgif-4.1.5 => tgif-4.1.6 <----------------------- Here's a short list of added features/bug fixes. 1) Fix typos in "menuinfo.c" and "const.h". -----------------------> tgif-4.1.4 => tgif-4.1.5 <----------------------- Here's a short list of added features/bug fixes. 1) Fix bugs with breaking multiple text objects. Thanks to Kouya SHIMURA for the patch. 2) Add NLS support for menus (can be turned on by the _ENABLE_NLS compiler define). A new X default, Tgif.MenuFontSet is added to have menus in a native language. A new X default, Tgif.LocaleDir, is added to override the compile time locale directory specified in Tgif.tmpl. Japanese menu support is provided in the po/ja subdirectory. Thanks to Jun Nishii for the patch. Please see po/README for more information about the tgifintl release. 3) Fix bugs with overthespot for the xim input method. Thanks to Shoji Matsumoto for the patch. 4) Open/Save/Import gzipped obj files. Add Tgif.GUnZipCmd and Tgif.GZipCmd X defaults so that the user can override the default "gunzip -c" and "gzip -c" commands. 5) Add the following internal commands to make it a little easier for third party code to drive tgif. Please see the updated man pages for the details of these commands. "Testdrive.c" is updated to show how some of these internal commands can be used to create and manipulate objects from the test driver when Animate() is selected from the Return Submenu of the File Menu. select_top_obj() delete_selected_obj() set_selected_obj_rcb_radius() set_selected_text_vspace() set_selected_text_just() set_selected_text_font() set_selected_text_size() set_selected_text_underline() copy_string_to_cut_buffer() delete_attr_from_selected_obj() select_from_ini_section(,,<section>,<ini_path>) create_text_obj(<abs_x>,<abs_baseline_y>,<string>) create_box_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) create_corner_oval_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) create_center_oval_obj(<abs_x>,<abs_y>,<radius>) create_edge_oval_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) create_rcbox_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) create_arc_obj(<abs_x>,<abs_y>,<radius>,<dir>,<angle1>,<angle2>) create_first_vertex(<abs_x>,<abs_y>) create_next_vertex(<abs_x>,<abs_y>) create_poly_obj() create_polygon_obj() start_create_group_obj() create_group_obj() -----------------------> tgif-4.1.3 => tgif-4.1.4 <----------------------- Here's a short list of added features/bug fixes. 1) Fix bugs with truncated text objects in exporting to GIF files where that are rotated text objects. 2) Fix bugs with underlined text. Sometimes, a thick line is used to draw the underline. 3) Add PS support the following 8-bit ISO-Latin-1 characters: "onesuperior", "onequarter", "onehalf", and "threequarters". Thanks to Antonio Miguel Corbi Bellot <acorbi at altea.dlsi.ua.es> for pointing out the problem. -----------------------> tgif-4.1.2 => tgif-4.1.3 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug with opening files in a non-existent directory. Thanks to Andreas Scherbaum <ads at htl.de> for pointing out the problem. 2) Add the following internal commands: append_line_into_attr(<attr_name>,<string>) insert_line_into_attr(<attr_name>,<string>,<line_number>) clear_attr(<attr_name>) -----------------------> tgif-4.1.1 => tgif-4.1.2 <----------------------- Here's a short list of added features/bug fixes. 1) Fix another bug with the File Menu flashing. Thanks to Andrew Sapuntzakis <andrewsa at cc701.comm.mot.com> for pointing out the problem. 2) Fix a bug with CopyProperties(). Thanks to Kouya SHIMURA <kouya at flab.fujitsu.co.jp> for the patch. 3) Fix bugs when no file name and only a file extension is specified as an input file name. Thanks to Holger Huesing <H.Huesing at tu-bs.de> for the patch. 4) Fix a locale bug. Should not #include <local.h> if _NO_LOCALE_SUPPORT is defined. Thanks to Ralphe Neill <ran at oberon.sub.net.au> for pointing out the problem. 5) Fix a problem with exporting XPM/GIF files under certain TrueColor visuals of Hummingbird's eXceed server. The fix is to compute the color table for the exported XPM/GIF file from the pixels in the actual image for TrueColor visuals if the new X default, Tgif.UseImagePixelsForTrueColorExport, is set to true. Thanks to Jurgen Rusch <rusch at natlab.research.philips.com> for pointing out the problem. 6) Fix a bug with UpdateSymbols(). Thanks to sven wilhelmsson <sven.wilhelmsson at swipnet.se> for the patch. -----------------------> tgif-4.1 => tgif-4.1.1 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a locale bug for non-X11R6 systems. Thanks to Miroslav Flidr <flidr at ori.zcu.cz> for pointing out the problem. 2) Fix a bug that if Tgif.NoMenubar is set to "true", some popup menus in the choice window doesn't work. Thanks to Hiroto Kagotani <kagotani at in.it.okayama-u.ac.jp> for pointing out the problem. 3) Fix a bug with the File Menu flashing. Thanks to Andrew Sapuntzakis <andrewsa at cc701.comm.mot.com> for pointing out the problem. -----------------------> tgif-4.0.18 => tgif-4.1 <----------------------- Here's a short list of added features/bug fixes. 1) Strings in text objects can now be underlined. 2) Fix a seg fault bug which happens if the .mailcap file is not present when downloading an URL. Thanks to Frank Koeck <Frank.Koeck at mpi-hd.mpg.de> for the patch. 3) Fix various bugs with edit text size. Thanks to Jeremy H. Brown <jhbrown at ai.mit.edu> for pointing out the problems. 4) Fix a bad status for the rotate/shear mode. Thanks to Dave Bodenstab <imdave at mcs.net> for the patch. 5) Fix negative offsets bug in SetSlideShowWindowOffsets(). 6) Reduce repaint when editing text objects. 7) Add EditPageFileNames() under the StackedPage Menu so that each page in a multipage drawing can have its own print/export file name when PrintOneFilePerPage() is invoked. -----------------------> tgif-4.0.17 => tgif-4.0.18 <----------------------- Here's a short list of added features/bug fixes. 1) Fix problems with internal commands to work better with non-simple (multi-color, multi-font, etc.) attributes. Thanks to Daniel Ratton Figueiredo <ratton at land.ufrj.br> for pointing out the problem. 2) Fix problems with menus with wm2. Thanks to <dshawhan at nyx.net> for pointing out the problem. 3) Fix a bug that creating a new text object when the edit text size is non-zero results in the font size of the text object being 0. Thanks to Jeremy H. Brown <jhbrown at ai.mit.edu> for pointing out the problem. 4) Fix page number bugs (as specified in the MULTIPAGE DRAWING section of tgif's man pages) in slideshow mode. 5) Allows the moving of individual attributes directly in select mode. -----------------------> tgif-4.0.16 => tgif-4.0.17 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug in clicking over the font size button in the Choice Window. 2) By default, don't use EUC PS fonts in printing/export PS files that contains Japanese characters. Thanks to Shinta Sato <shinta at crimson.q.t.u-tokyo.ac.jp> for the patch. -----------------------> tgif-4.0.15 => tgif-4.0.16 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug with Tgif.RubberBandColor that it leaves ghost images during editing text objects when one moves the text cursor with cursor keys. Thanks to Shinichiro Shiratake <shinichiro.shiratake at toshiba.co.jp> for pointing out the problems. 2) Rename SetTextBackgroundColor() in the Text Submenu of the Edit Menu to SetTextFillPatternColor() since this operation only changes the fill pattern color of a text object and not the background color. Also, since text doesn't reallly have a background color (but only has a fill pattern color), the fix to set the default background color in 4.0 patchlevel 15 is invalid. Now the current color is used as the fill pattern color for new text objects. Thanks to Shinichiro Shiratake <shinichiro.shiratake at toshiba.co.jp> for pointing out the problems. -----------------------> tgif-4.0.14 => tgif-4.0.15 <----------------------- Here's a short list of added features/bug fixes. 1) Fix the default background color for new text objects. Used to be that the first color is used. Now the background color of tgif is used as the default background color for text objects. 2) Add SetAltEditTextBgColor(), SetAltEditTextHighlightColor() and UseAltEditTextBgColor() under the Properties Menu so that an alternate background and highlight color can be used when editing/creating text objects. Thanks to Ralphe Neill <ran at oberon.sub.net.au> for the suggestion. -----------------------> tgif-4.0.13 => tgif-4.0.14 <----------------------- Here's a short list of added features/bug fixes. 1) Add Tgif.LightGrayColor and Tgif.DarkGrayColor so that the user can change the colors for the backgrounds and shadows of butons, menus, etc. 2) Split the Attribute submenu under the Special Menu into Attribute and FileAttribute submenus. -----------------------> tgif-4.0.12 => tgif-4.0.13 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug with stretching grouped objects that contain text objects. Also fix a bug with the TransPattern Menu. Thanks to Shinichiro Shiratake <shinichiro.shiratake at toshiba.co.jp> for pointing out the problems. 2) Improve scrolling and zooming. Allow smooth and jump scrolling of the canvas window. 3) Add visible-grid control in slideshow mode. -----------------------> tgif-4.0.11 => tgif-4.0.12 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a hanging bug with executing the lauch() internal command. Thanks to Leana Golubchik <leana at cs.umd.edu> for pointing out the problem. -----------------------> tgif-4.0.10 => tgif-4.0.11 <----------------------- Here's a short list of added features/bug fixes. 1) Obsolete Tgif.StripEPSComments and Tgif.StripCondensedPSComments X defaults. Turns out that it's not always okay to strip PostScript comments (an Adobe Illustrator 6.0 generated EPS file may have data that looks like a PostScript comment). So these values should alway be false. -----------------------> tgif-4.0.9 => tgif-4.0.10 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a hanging bug when choosing a non-existant font. If you specify additional fonts with Tgif.AdditionalFonts and a font doesn't exist on your machine, tgif would normally bring up a message box saying that the font is not available. If you re-expose tgif's main window at this time, you may get a second message box and hangs tgif. Thanks to Helmut Jarausch <jarausch at IGPM.Rwth-Aachen.DE> for pointing out the problem. -----------------------> tgif-4.0.8 => tgif-4.0.9 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a compatibility bug. If "file.obj" is produced by tgif-3.x, text objects in PostScript file are not positioned correctly for "tgif -print -ps file.obj". This is not a problem if tgif is run interactively (without "-print"). Thanks to Dan McMahill <mcmahill at mtl.mit.edu> for pointing out the problem. 2) Fix bugs in flipping grouped objects with text subobjects horizontally and vertically. Thanks to Stephan Shuichi Haupt <stephan at bios.t.u-tokyo.ac.jp> for pointing out the problem. -----------------------> tgif-4.0.7 => tgif-4.0.8 <----------------------- Here's a short list of added features/bug fixes. 1) Fix formating bug in DistributeObjsDirect(). Thanks to TSUKADA Satoru <tsukada at tcd.hitachi.co.jp> for the patch. 2) Fix a bug in retriving URL's. Sometimes, the last byte of the file is not retrieved (which doesn't usualy cause any problems for text files because the last byte is a <LF>). -----------------------> tgif-4.0.6 => tgif-4.0.7 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a crashing bug which can happen when you paste complex text objects at the text cursor. Thanks to TSUKADA Satoru <tsukada at tcd.hitachi.co.jp> for the patch. 2) Fix a bug in inserting <CR> in an text object. Sometimes, the <End> key will bring you to the wrong place after inserting <CR>. Thanks to TSUKADA Satoru <tsukada at tcd.hitachi.co.jp> for the patch. 3) Fix a bunch of bugs related to the handling of double-byte fonts. Thanks to TSUKADA Satoru <tsukada at tcd.hitachi.co.jp> for the patch. 4) Use the portable locale ("C") by default. Thanks to Gregor Zych <zych at pool.informatik.rwth-aachen.de> for the suggestion. 5) Add a new drawing mode to create arcs such that the user can specify the endpoints of an arc while tgif determines automatically the center of the circle on which the arc lies. Thanks to Dick Wesseling <ftu at fi.uu.nl> for the patch and suggestion. 6) Add 3 alignment submenus and 1 distribution submenu. Using these submenus, one can specify alignments directly while aligning objects, aligning objects to grid, aligning objects to page, and distribute objects. Thanks to Dick Wesseling <ftu at fi.uu.nl> for the suggestion. 7) Update "tgif.pl" Prolog code to document the new tgif file format (file version 37). -----------------------> tgif-4.0.5 => tgif-4.0.6 <----------------------- Here's a short list of added features/bug fixes. 1) Fix divide by zero bugs which causes a seg fault on OSF1 (apparently, this doesn't crash on either Solaris or Linux). 2) Handles <ESC> correctly when creating objects. Thanks to Dick Wesseling <ftu at fi.uu.nl> for pointing out the problem. 3) Add the following files: Tgif.tmpl-osf1 Also moved some code around so tgif will compile under Digital UNIX (OSF1). -----------------------> tgif-4.0.4 => tgif-4.0.5 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug that generates bad a GIF file when running tgif with "-print -gif" commandline arguments. Thanks to Dick Wesseling <ftu at fi.uu.nl> for pointing out this problem. 2) Support more tgif file name extensions. Allow ".tgo" to also be a tgif object file name extension and ".tgs" to also be a tgif symbol file name extension. -----------------------> tgif-4.0.3 => tgif-4.0.4 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a seg fault bug when Tgif.ShowFontSizeInPoints is used. Thanks to Levente NOVAK <novak at jaguar.dote.hu> for pointing out this problem (and a few other problems). 2) Allow URL's while importing XPM/XBM/GIF and other files (to specify an URL, type '/' in the file dialogbox before typing the URL). 3) Fix problems reading files generated by tgif-2.13J and tgif-2.16J. Thanks to TSUKADA Satoru <tsukada at tcd.hitachi.co.jp> for the patch. 4) Use auto _DL_EXPORT_UNDERSCORE determination on NetBSD. Thanks to Dan McMahill <mcmahill at mtl.mit.edu> for the patch. 5) Accept "cm" and "in" specifications in SpecifyAnArc() and SizeToGivenWidthHeight(). Thanks to Levente NOVAK <novak at jaguar.dote.hu> for pointing out the problems. -----------------------> tgif-4.0.2 => tgif-4.0.3 <----------------------- Here's a short list of added features/bug fixes. 1) Fix crashing bugs with super/subscripts. Thanks to Levente NOVAK <novak at jaguar.dote.hu> for pointing out the problem. 2) Make tgif compile under HP-UX. On an HP 9000/735, /bin/cc does not like "#define extern extern" which appears in all the .e files. 3) Add "#include <locale.h>" if _NO_LOCALE_SUPPORT is defined in "convxim.c". Thanks to Ralphe Neill <ran at oberon.sub.net.au> for pointing out the problem. 4) Fix offset into the tiff image is incorrect when exporting in the TiffEPSI format. Thanks for Leana Golubchik <leana at cs.umd.edu> for pointing out the problem. 5) Handle window manager Delete's properly. Thanks to Dick Wesseling <ftu at fi.uu.nl> for the patch. 6) Don't repaint so much when pasting. Thanks to Francis Ngoh <fngoh at ti.com> for pointing out the problem. 7) Fix the following problems when dealing with inputing Japanese characters. a) The File Modified flag was not set when inputing Japanese characters. b) After switching to a single-byte font, tgif was still talking to the input method. c) If Tgif.PreeditType is set to overthespot, the kinput2's window position was wrong. Thanks to TAKAHASHI Hitoshi <thitoshi at ne.scphys.kyoto-u.ac.jp> pointing out the problems. 8) Add the following files: Tgif.tmpl-netbsd Tgif.tmpl-irix Tgif.tmpl-hpux -----------------------> tgif-4.0.1 => tgif-4.0.2 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a ``Fatal Unexpected Error'' when the Edit Menu is pinned and certain text cursor movement is performed when a text object is being edited. 2) Tgif.BoldMsgFont by default will now use the value of Tgif.MsgFont if Tgif.MsgFont is specified. 3) RTLD_GLOBAL, used in "xprtfltr.c", is not defined on FreeeBSD. Thanks to Dan McMahill <mcmahill at mtl.mit.edu> for pointing out the problem. 4) Add the following files to the distribution: Tgif.tmpl-linux Tgif.tmpl-solaris Tgif.tmpl-freebsd -----------------------> tgif-4.0 => tgif-4.0.1 <----------------------- Here's a short list of added features/bug fixes. 1) Tgif.MinimalEPS was not behaving and documented properly. Thanks to Koppa Vesa <Vesa.Koppa at nmp.nokia.com> for pointing out the problems. 2) Fix a few missing items in make.common and Makefile.noimake. Thanks to Koppa Vesa <Vesa.Koppa at nmp.nokia.com> for pointing out the problems. 3) Fix a few minor compiler warnings. for pointing out the problems. 4) Fix a few missing defines for certain machines. Thanks to Francis Ngoh <fngoh at ti.com> for pointing out the problems. 1) Support the _TGIF_WB2 compile option. Attempting to phase out _TGIF_WB. -----------------------> tgif-4.0 <----------------------- I'm happy to announce the availability of version 4.0 of tgif. This release is an alpha release. So it's probably a good idea not to use it on anything too serious. Please send bug reports to bill.cheng at acm.org as soon as you see bugs so I can release patches to fix major bugs. Unfortunately, I will be out of e-mail reach until 12/31, so I won't be able to respond until probably the next year. I apologize for that. Although version 4.0 is backward-compatible with old versions of tgif, the file format is not forward-compatible (you won't be able to read files generated by this version of tgif with an older versions of tgif). The tgif-4.0 source code is available at the following places for anonymous ftp (binaries are not available yet at the time of this release, please check the tgif current release and download page for availability): ftp://bourbon.cs.umd.edu/pub/tgif/tgif-4.0.tar.gz (primary) ftp://ftp.cs.ucla.edu/pub/tgif/tgif-4.0.tar.gz (1,098.938 bytes - running 'sum tgif-4.0.tar.gz' should get: 16385 1074) Here's a short list of the main features added in version 4.0. 1) 3-D look. 2) Allow a text object to have multiple font faces, sizes, styles, and colors. 3) Allow superscripts and subscripts in text objects. 4) Support double-byte fonts and their input methods such as kinput2 for Japanese and xcin and chinput for Chinese. 5) Slide show mode for multipage drawings using left and right cursor keys to advance pages. 6) Import/export GIF animation - requires gifsicle <URL:http://www.lcdf.org/gifsicle/> version 1.9.1 or newer. 7) Export PDF files - requires ps2pdf from the ghostscript 5.x distribution <URL:http://www.cs.wisc.edu/~ghost/>. 8) Copy/paste object properties (such as color, linewidth, etc.) ABOUT TGIF: Tgif is an Xlib-based 2-D drawing tool. It's also a hyper-graphics (or hyper-structured-graphics) browser on the World-Wide-Web. Its hyper-text home page is <URL:http://bourbon.cs.umd.edu:8001/tgif/> and its hyper-graphics home page is <URL:http://bourbon.cs.umd.edu:8001/tgif/index.obj>. (Please note that the Content-type of a tgif file sent by the httpd at bourbon.cs.umd.edu:8001 is applications/x-tgif.) Tgif is free-of-charge, but please read the Copyright file in the distribution (or select Copyright from the Help Menu in tgif) for restrictions. (Please note that tgif is NEITHER an html viewer NOR an html editor. It is also NOT directly related to GIF nor Transparent GIF.) TGIF RESOURCES: Home Page: http://bourbon.cs.umd.edu:8001/tgif/ FAQ: http://bourbon.cs.umd.edu:8001/tgif/faq/ Current Release & Download: http://bourbon.cs.umd.edu:8001/tgif/current.html Join to Mailing List: kragen-tgif-subscribe at kragen.dnaco.net Mailing List: kragen-tgif at kragen.dnaco.net Bug Reports Send To: bill.cheng at acm.org Happy New Year! /* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/HISTORY,v 1.114 2011/06/28 02:12:04 william Exp $ */ �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/shape.c������������������������������������������������������������������������������0000644�0000764�0000764�00000114600�11602233312�014232� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/shape.c,v 1.8 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_SHAPE_C_ #include "tgifdefs.h" #include "cmdids.h" #include "arc.e" #include "attr.e" #include "auxtext.e" #include "box.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "grid.e" #include "group.e" #include "mainloop.e" #include "menu.e" #include "menuinfo.e" #include "move.e" #include "msg.e" #include "navigate.e" #include "obj.e" #include "oval.e" #include "page.e" #include "pattern.e" #include "poly.e" #include "polygon.e" #include "raster.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "shape.e" #include "spline.e" #include "strtbl.e" #include "text.e" #include "util.e" int numShapes=MAXSHAPES; int curShape=(-1); int shapeShadowInResource=FALSE; int shapeShadowDx=0; int shapeShadowDy=0; /* ----------------------- String Functions ----------------------- */ static struct MouseStatusStrRec shapeDescMouseStatus[] = { /* * note: the m field is used for the localized strings */ { N_("Create a box"), NULL, NULL }, { N_("Create a parallelegram"), NULL, NULL }, { N_("Create a trapezoid"), NULL, NULL }, { N_("Create a rhombus"), NULL, NULL }, { N_("Create a rounded-corner box"), NULL, NULL }, { N_("Create an octagon"), NULL, NULL }, { N_("Create a cross"), NULL, NULL }, { N_("Create an oval"), NULL, NULL }, { N_("Create a word box"), NULL, NULL }, { N_("Create a hexagon"), NULL, NULL }, { N_("Create a triangle"), NULL, NULL }, { N_("Create a blast box"), NULL, NULL }, { N_("Create a star"), NULL, NULL }, { N_("Create a disk"), NULL, NULL }, { N_("Create a right arrow"), NULL, NULL }, { N_("Create a up arrow"), NULL, NULL }, { N_("Create a fat right arrow"), NULL, NULL }, { N_("Create a fat up arrow"), NULL, NULL }, { N_("Create a right tab"), NULL, NULL }, { N_("Create a up tab"), NULL, NULL }, { NULL, NULL, NULL } }; static void CleanUpShapeDescMouseStatusStrings() { int index=0; for (index=0; index < MAXCHOICES; index++) { UtilFree(shapeDescMouseStatus[index].m); shapeDescMouseStatus[index].m = NULL; } } static char *GetShapeDesc(index) int index; /* returned string has been translated */ { if (shapeDescMouseStatus[index].m == NULL) { shapeDescMouseStatus[index].m = UtilStrDup(_(shapeDescMouseStatus[index].l)); if (shapeDescMouseStatus[index].m == NULL) FailAllocMessage(); } return shapeDescMouseStatus[index].m; } /* ----------------------- Create Shape Functions ----------------------- */ static IntPoint *gpVertices=NULL; static int gnNumVs=0; static XPoint *gpRubberVertices=NULL; static int gnNumSplineVs=0; static char *gpnSmooth=NULL; static int gnOrigX=0, gnOrigY=0, gnEndX=0, gnEndY=0; static struct BBRec gShapeBBox; static int CreatePolygonShape(num_pts, has_smooth) int num_pts, has_smooth; { gpVertices = (IntPoint*)malloc(num_pts*sizeof(IntPoint)); if (gpVertices == NULL) return FailAllocMessage(); memset(gpVertices, 0, num_pts*sizeof(IntPoint)); if (has_smooth) { gpnSmooth = (char*)malloc(num_pts*sizeof(char)); if (gpnSmooth == NULL) { free(gpVertices); gpVertices = NULL; return FailAllocMessage(); } memset(gpnSmooth, 0, num_pts*sizeof(char)); } gnNumVs = num_pts; return TRUE; } static int CreateOvalShape() { gpVertices = NULL; gpnSmooth = NULL; gnNumVs = gnNumSplineVs = 0; memset(&gShapeBBox, 0, sizeof(struct BBRec)); return TRUE; } static int CreateDiskShape() { gpVertices = NULL; gpnSmooth = NULL; gnNumVs = gnNumSplineVs = 0; memset(&gShapeBBox, 0, sizeof(struct BBRec)); return TRUE; } static int StartCreateShape(orig_x, orig_y) int orig_x, orig_y; { gnOrigX = gnEndX = orig_x; gnOrigY = gnEndY = orig_y; switch (curShape) { case SHAPE_BOX: return CreatePolygonShape(5, FALSE); case SHAPE_PARALLEL: return CreatePolygonShape(5, FALSE); case SHAPE_TRAPEZOID: return CreatePolygonShape(5, FALSE); case SHAPE_RHOMBUS: return CreatePolygonShape(5, FALSE); case SHAPE_RCBOX: return CreatePolygonShape(13, TRUE); case SHAPE_OCTAGON: return CreatePolygonShape(9, FALSE); case SHAPE_CROSS: return CreatePolygonShape(13, FALSE); case SHAPE_OVAL: return CreateOvalShape(); case SHAPE_WORDS: return CreatePolygonShape(16, TRUE); case SHAPE_HEXAGON: return CreatePolygonShape(7, FALSE); case SHAPE_TRIANGLE: return CreatePolygonShape(4, FALSE); case SHAPE_BLAST: return CreatePolygonShape(34, FALSE); case SHAPE_STAR: return CreatePolygonShape(12, FALSE); case SHAPE_DISK: return CreateDiskShape(); case SHAPE_RIGHTARROW: return CreatePolygonShape(8, FALSE); case SHAPE_UPARROW: return CreatePolygonShape(8, FALSE); case SHAPE_FATRIGHTARROW: return CreatePolygonShape(8, FALSE); case SHAPE_FATUPARROW: return CreatePolygonShape(8, FALSE); case SHAPE_RIGHTTAB: return CreatePolygonShape(6, FALSE); case SHAPE_UPTAB: return CreatePolygonShape(6, FALSE); } return FALSE; } static void EndCreateShape() { if (gpVertices != NULL) free(gpVertices); gpVertices = NULL; if (gpRubberVertices != NULL) free(gpRubberVertices); gpRubberVertices = NULL; if (gpnSmooth != NULL) free(gpnSmooth); gpnSmooth = NULL; gnNumVs = gnNumSplineVs = 0; } /* ----------------------- HighLight Calc Functions ----------------------- */ #define SHAPE_ANGLE (((double)15.0)*M_PI/((double)180.0)) static double TangentOfAngle() { static int nInitialized=FALSE; static double dval=(double)0.0; if (nInitialized) return dval; nInitialized = TRUE; dval = ((double)sin(SHAPE_ANGLE)) / ((double)cos(SHAPE_ANGLE)); return dval; } static void CalcRegularPolygonVs(sides, vertex_at_right, start_degree, scale, start_index, index_step) int sides, vertex_at_right, start_degree, start_index, index_step; double scale; /* if (vertex_at_right), easy */ /* if (!vertex_at_right && start_degree == 0) self-determined */ /* if (!vertex_at_right && start_degree != 0) start_degree is the */ /* real start angle in degrees */ { int i, w=gnEndX-gnOrigX, h=gnEndY-gnOrigY, index=start_index; int xc=((gnEndX+gnOrigX)>>1), yc=((gnEndY+gnOrigY)>>1); double inc=((double)2.0)*M_PI/((double)sides), radius, rx, ry; double angle=(vertex_at_right ? (double)0.0 : inc/((double)2.0)); if (vertex_at_right) { radius = (double)0.5; angle = (double)0.0; } else { angle = inc/((double)2.0); radius = (((sides%4)==0) ? (double)(cos(angle)/2.0) : (double)0.5); if (start_degree != 0) { angle = ((double)start_degree)*M_PI/((double)180.0); } } rx = radius*((double)w)*scale; ry = radius*((double)h)*scale; for (i=0; i < sides; i++, angle += inc, index += index_step) { double dw=rx*((double)cos(angle)); double dh=ry*((double)sin(angle)); gpVertices[index].x = xc + round(dw); gpVertices[index].y = yc + round(dh); } gpVertices[index].x = gpVertices[start_index].x; gpVertices[index].y = gpVertices[start_index].y; gnNumVs = sides+1; } static void CalcBoxShapeVs() { gpVertices[0].x = gnOrigX; gpVertices[0].y = gnOrigY; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY; gpVertices[2].x = gnEndX; gpVertices[2].y = gnEndY; gpVertices[3].x = gnEndX; gpVertices[3].y = gnOrigY; gpVertices[4].x = gpVertices[0].x; gpVertices[4].y = gpVertices[0].y; } static void CalcParallelShapeVs() { int h=gnEndY-gnOrigY, dx; double dval; dval = ((double)h) * TangentOfAngle(); dx = (int)round(dval); gpVertices[0].x = gnOrigX+dx; gpVertices[0].y = gnOrigY; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY; gpVertices[2].x = gnEndX-dx; gpVertices[2].y = gnEndY; gpVertices[3].x = gnEndX; gpVertices[3].y = gnOrigY; gpVertices[4].x = gpVertices[0].x; gpVertices[4].y = gpVertices[0].y; } static void CalcTrapezoidShapeVs() { int h=gnEndY-gnOrigY, dx; double dval; dval = ((double)h) * TangentOfAngle(); dx = (int)round(dval); gpVertices[0].x = gnOrigX; gpVertices[0].y = gnOrigY; gpVertices[1].x = gnOrigX+dx; gpVertices[1].y = gnEndY; gpVertices[2].x = gnEndX-dx; gpVertices[2].y = gnEndY; gpVertices[3].x = gnEndX; gpVertices[3].y = gnOrigY; gpVertices[4].x = gpVertices[0].x; gpVertices[4].y = gpVertices[0].y; } static void CalcRhombusShapeVs() { int cx=((gnOrigX+gnEndX)>>1), cy=((gnOrigY+gnEndY)>>1); gpVertices[0].x = cx; gpVertices[0].y = gnOrigY; gpVertices[1].x = gnOrigX; gpVertices[1].y = cy; gpVertices[2].x = cx; gpVertices[2].y = gnEndY; gpVertices[3].x = gnEndX; gpVertices[3].y = cy; gpVertices[4].x = gpVertices[0].x; gpVertices[4].y = gpVertices[0].y; } static void CalcRCBoxShapeVs() { int w=gnEndX-gnOrigX, h=gnEndY-gnOrigY; if (abs(w) >= (rcbRadius<<1) && abs(h) >= (rcbRadius<<1)) { int dx=(w>0 ? rcbRadius : -rcbRadius), dy=(h>0 ? rcbRadius : -rcbRadius); gpVertices[0].x = gnOrigX; gpVertices[0].y = gnOrigY+dy; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY-dy; gpVertices[2].x = gnOrigX; gpVertices[2].y = gnEndY; gpVertices[3].x = gnOrigX+dx; gpVertices[3].y = gnEndY; gpVertices[4].x = gnEndX-dx; gpVertices[4].y = gnEndY; gpVertices[5].x = gnEndX; gpVertices[5].y = gnEndY; gpVertices[6].x = gnEndX; gpVertices[6].y = gnEndY-dy; gpVertices[7].x = gnEndX; gpVertices[7].y = gnOrigY+dy; gpVertices[8].x = gnEndX; gpVertices[8].y = gnOrigY; gpVertices[9].x = gnEndX-dx; gpVertices[9].y = gnOrigY; gpVertices[10].x = gnOrigX+dx; gpVertices[10].y = gnOrigY; gpVertices[11].x = gnOrigX; gpVertices[11].y = gnOrigY; gpVertices[12].x = gpVertices[0].x; gpVertices[12].y = gpVertices[0].y; gnNumVs = 13; memset(gpnSmooth, 0, gnNumVs*sizeof(char)); gpnSmooth[2] = gpnSmooth[5] = gpnSmooth[8] = gpnSmooth[11] = TRUE; } else { gpVertices[0].x = gnOrigX; gpVertices[0].y = gnOrigY; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY; gpVertices[2].x = gnEndX; gpVertices[2].y = gnEndY; gpVertices[3].x = gnEndX; gpVertices[3].y = gnOrigY; gpVertices[4].x = gpVertices[0].x; gpVertices[4].y = gpVertices[0].y; gnNumVs = 5; memset(gpnSmooth, 0, gnNumVs*sizeof(char)); } } static void CalcOctagonShapeVs() { CalcRegularPolygonVs(8, FALSE, 0, (double)1.0, 0, 1); } static void CalcCrossShapeVs() { int w=gnEndX-gnOrigX, h=gnEndY-gnOrigY; int dx=(int)(w/3), dy=(int)(h/3); gpVertices[0].x = gnOrigX; gpVertices[0].y = gnOrigY+dy; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY-dy; gpVertices[2].x = gnOrigX+dx; gpVertices[2].y = gnEndY-dy; gpVertices[3].x = gnOrigX+dx; gpVertices[3].y = gnEndY; gpVertices[4].x = gnEndX-dx; gpVertices[4].y = gnEndY; gpVertices[5].x = gnEndX-dx; gpVertices[5].y = gnEndY-dy; gpVertices[6].x = gnEndX; gpVertices[6].y = gnEndY-dy; gpVertices[7].x = gnEndX; gpVertices[7].y = gnOrigY+dy; gpVertices[8].x = gnEndX-dx; gpVertices[8].y = gnOrigY+dy; gpVertices[9].x = gnEndX-dx; gpVertices[9].y = gnOrigY; gpVertices[10].x = gnOrigX+dx; gpVertices[10].y = gnOrigY; gpVertices[11].x = gnOrigX+dx; gpVertices[11].y = gnOrigY+dy; gpVertices[12].x = gpVertices[0].x; gpVertices[12].y = gpVertices[0].y; } static void CalcOvalShapeVs() { CalcBBox(gnOrigX, gnOrigY, gnEndX, gnEndY, &(gShapeBBox.ltx), &(gShapeBBox.lty), &(gShapeBBox.rbx), &(gShapeBBox.rby)); } static void CalcWordsShapeVs() { int w=gnEndX-gnOrigX, h=gnEndY-gnOrigY; int min_h=(rcbRadius<<1)+rcbRadius; int min_w=min_h+(rcbRadius>>1); if (abs(w) >= min_w && abs(h) >= min_h) { int dx=(w>0 ? rcbRadius : -rcbRadius), dy=(h>0 ? rcbRadius : -rcbRadius); int dy2=(dy<<1); gpVertices[0].x = gnOrigX; gpVertices[0].y = gnOrigY+dy; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY-dy2; gpVertices[2].x = gnOrigX; gpVertices[2].y = gnEndY-dy; gpVertices[3].x = gnOrigX+dx; gpVertices[3].y = gnEndY-dy; gpVertices[4].x = gnOrigX+dx+(dx>>1); gpVertices[4].y = gnEndY-dy; gpVertices[5].x = gnOrigX+dx+(dx>>1); gpVertices[5].y = gnEndY; gpVertices[6].x = gnOrigX+(dx<<1)+(dx>>1); gpVertices[6].y = gnEndY-dy; gpVertices[7].x = gnEndX-dx; gpVertices[7].y = gnEndY-dy; gpVertices[8].x = gnEndX; gpVertices[8].y = gnEndY-dy; gpVertices[9].x = gnEndX; gpVertices[9].y = gnEndY-dy2; gpVertices[10].x = gnEndX; gpVertices[10].y = gnOrigY+dy; gpVertices[11].x = gnEndX; gpVertices[11].y = gnOrigY; gpVertices[12].x = gnEndX-dx; gpVertices[12].y = gnOrigY; gpVertices[13].x = gnOrigX+dx; gpVertices[13].y = gnOrigY; gpVertices[14].x = gnOrigX; gpVertices[14].y = gnOrigY; gpVertices[15].x = gpVertices[0].x; gpVertices[15].y = gpVertices[0].y; gnNumVs = 16; memset(gpnSmooth, 0, gnNumVs*sizeof(char)); gpnSmooth[2] = gpnSmooth[8] = gpnSmooth[11] = gpnSmooth[14] = TRUE; } else { gpVertices[0].x = gnOrigX; gpVertices[0].y = gnOrigY; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY; gpVertices[2].x = gnEndX; gpVertices[2].y = gnEndY; gpVertices[3].x = gnEndX; gpVertices[3].y = gnOrigY; gpVertices[4].x = gpVertices[0].x; gpVertices[4].y = gpVertices[0].y; gnNumVs = 5; memset(gpnSmooth, 0, gnNumVs*sizeof(char)); } } static void CalcHexagonShapeVs() { CalcRegularPolygonVs(6, TRUE, 0, (double)1.0, 0, 1); } static void CalcTriangleShapeVs() { gpVertices[0].x = ((gnOrigX+gnEndX)>>1); gpVertices[0].y = gnOrigY; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY; gpVertices[2].x = gnEndX; gpVertices[2].y = gnEndY; gpVertices[3].x = gpVertices[0].x; gpVertices[3].y = gpVertices[0].y; } static void CalcBlastShapeVs() { CalcRegularPolygonVs(16, TRUE, 0, (double)1.0, 0, 2); CalcRegularPolygonVs(16, FALSE, 0, (double)0.66, 1, 2); gnNumVs = 33; } static void CalcStarShapeVs() { int i; IntPoint vs[5]; CalcRegularPolygonVs(5, FALSE, -90, (double)1.0, 0, 2); CalcRegularPolygonVs(5, FALSE, 90, (double)0.375, 1, 2); for (i=0; i < 5; i++) { memcpy(&vs[i], &gpVertices[((i<<1)+7) % 10], sizeof(IntPoint)); } for (i=0; i < 5; i++) { memcpy(&gpVertices[(i<<1)+1], &vs[i], sizeof(IntPoint)); } gnNumVs = 11; } static void CalcDiskShapeVs() { CalcBBox(gnOrigX, gnOrigY, gnEndX, gnEndY, &(gShapeBBox.ltx), &(gShapeBBox.lty), &(gShapeBBox.rbx), &(gShapeBBox.rby)); } static void CalcRightArrowShapeVs() { int w=gnEndX-gnOrigX, h=gnEndY-gnOrigY; int dx=(w>>1), dy=(h>>2); gpVertices[0].x = gnOrigX; gpVertices[0].y = gnOrigY+dy; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY-dy; gpVertices[2].x = gnOrigX+dx; gpVertices[2].y = gnEndY-dy; gpVertices[3].x = gnOrigX+dx; gpVertices[3].y = gnEndY; gpVertices[4].x = gnEndX; gpVertices[4].y = gnOrigY+(h>>1); gpVertices[5].x = gnOrigX+dx; gpVertices[5].y = gnOrigY; gpVertices[6].x = gnOrigX+dx; gpVertices[6].y = gnOrigY+dy; gpVertices[7].x = gpVertices[0].x; gpVertices[7].y = gpVertices[0].y; } static void CalcUpArrowShapeVs() { int w=gnEndX-gnOrigX, h=gnEndY-gnOrigY; int dx=(w>>2), dy=(h>>1); gpVertices[0].x = gnOrigX; gpVertices[0].y = gnEndY-dy; gpVertices[1].x = gnOrigX+dx; gpVertices[1].y = gnEndY-dy; gpVertices[2].x = gnOrigX+dx; gpVertices[2].y = gnEndY; gpVertices[3].x = gnEndX-dx; gpVertices[3].y = gnEndY; gpVertices[4].x = gnEndX-dx; gpVertices[4].y = gnEndY-dy; gpVertices[5].x = gnEndX; gpVertices[5].y = gnEndY-dy; gpVertices[6].x = gnOrigX+(w>>1); gpVertices[6].y = gnOrigY; gpVertices[7].x = gpVertices[0].x; gpVertices[7].y = gpVertices[0].y; } static void CalcFatRightArrowShapeVs() { int w=gnEndX-gnOrigX, h=gnEndY-gnOrigY; int dx=(w>>1), dy=(h>>3); gpVertices[0].x = gnOrigX; gpVertices[0].y = gnOrigY+dy; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY-dy; gpVertices[2].x = gnOrigX+dx; gpVertices[2].y = gnEndY-dy; gpVertices[3].x = gnOrigX+dx; gpVertices[3].y = gnEndY; gpVertices[4].x = gnEndX; gpVertices[4].y = gnOrigY+(h>>1); gpVertices[5].x = gnOrigX+dx; gpVertices[5].y = gnOrigY; gpVertices[6].x = gnOrigX+dx; gpVertices[6].y = gnOrigY+dy; gpVertices[7].x = gpVertices[0].x; gpVertices[7].y = gpVertices[0].y; } static void CalcFatUpArrowShapeVs() { int w=gnEndX-gnOrigX, h=gnEndY-gnOrigY; int dx=(w>>3), dy=(h>>1); gpVertices[0].x = gnOrigX; gpVertices[0].y = gnEndY-dy; gpVertices[1].x = gnOrigX+dx; gpVertices[1].y = gnEndY-dy; gpVertices[2].x = gnOrigX+dx; gpVertices[2].y = gnEndY; gpVertices[3].x = gnEndX-dx; gpVertices[3].y = gnEndY; gpVertices[4].x = gnEndX-dx; gpVertices[4].y = gnEndY-dy; gpVertices[5].x = gnEndX; gpVertices[5].y = gnEndY-dy; gpVertices[6].x = gnOrigX+(w>>1); gpVertices[6].y = gnOrigY; gpVertices[7].x = gpVertices[0].x; gpVertices[7].y = gpVertices[0].y; } static void CalcRightTabShapeVs() { int w=gnEndX-gnOrigX, h=gnEndY-gnOrigY; int dx=(int)(w/3), dy=(h>>1); gpVertices[0].x = gnOrigX; gpVertices[0].y = gnOrigY; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY; gpVertices[2].x = gnEndX-dx; gpVertices[2].y = gnEndY; gpVertices[3].x = gnEndX; gpVertices[3].y = gnOrigY+dy; gpVertices[4].x = gnEndX-dx; gpVertices[4].y = gnOrigY; gpVertices[5].x = gpVertices[0].x; gpVertices[5].y = gpVertices[0].y; } static void CalcUpTabShapeVs() { int w=gnEndX-gnOrigX, h=gnEndY-gnOrigY; int dx=(w>>1), dy=(int)(h/3); gpVertices[0].x = gnOrigX; gpVertices[0].y = gnOrigY+dy; gpVertices[1].x = gnOrigX; gpVertices[1].y = gnEndY; gpVertices[2].x = gnEndX; gpVertices[2].y = gnEndY; gpVertices[3].x = gnEndX; gpVertices[3].y = gnOrigY+dy; gpVertices[4].x = gnOrigX+dx; gpVertices[4].y = gnOrigY; gpVertices[5].x = gpVertices[0].x; gpVertices[5].y = gpVertices[0].y; } /* ----------------------- HighLight Shape Functions ----------------------- */ static int CalcCreateShapeVs(end_x, end_y) int end_x, end_y; { gnEndX = end_x; gnEndY = end_y; if (gnEndX == gnOrigX || gnEndY == gnOrigY) return FALSE; switch (curShape) { case SHAPE_BOX: CalcBoxShapeVs(); break; case SHAPE_PARALLEL: CalcParallelShapeVs(); break; case SHAPE_TRAPEZOID: CalcTrapezoidShapeVs(); break; case SHAPE_RHOMBUS: CalcRhombusShapeVs(); break; case SHAPE_RCBOX: CalcRCBoxShapeVs(); break; case SHAPE_OCTAGON: CalcOctagonShapeVs(); break; case SHAPE_CROSS: CalcCrossShapeVs(); break; case SHAPE_OVAL: CalcOvalShapeVs(); break; case SHAPE_WORDS: CalcWordsShapeVs(); break; case SHAPE_HEXAGON: CalcHexagonShapeVs(); break; case SHAPE_TRIANGLE: CalcTriangleShapeVs(); break; case SHAPE_BLAST: CalcBlastShapeVs(); break; case SHAPE_STAR: CalcStarShapeVs(); break; case SHAPE_DISK: CalcDiskShapeVs(); break; case SHAPE_RIGHTARROW: CalcRightArrowShapeVs(); break; case SHAPE_UPARROW: CalcUpArrowShapeVs(); break; case SHAPE_FATRIGHTARROW: CalcFatRightArrowShapeVs(); break; case SHAPE_FATUPARROW: CalcFatUpArrowShapeVs(); break; case SHAPE_RIGHTTAB: CalcRightTabShapeVs(); break; case SHAPE_UPTAB: CalcUpTabShapeVs(); break; } return TRUE; } #define NO_GENERATE 0 #define GENERATE 1 static void HighLightCreateShape(end_x, end_y, generate, pn_need_to_draw) int end_x, end_y, generate, *pn_need_to_draw; { if (generate) { *pn_need_to_draw = CalcCreateShapeVs(end_x, end_y); if (*pn_need_to_draw && gpVertices != NULL) { int saved_draw_orig_x=drawOrigX, saved_draw_orig_y=drawOrigY; int saved_zoomed_in=zoomedIn, saved_zoom_scale=zoomScale; if (gpRubberVertices != NULL) free(gpRubberVertices); gnNumSplineVs = 0; drawOrigX = drawOrigY = 0; zoomedIn = FALSE; zoomScale = 0; if (gpnSmooth == NULL) { gpRubberVertices = MakePolygonVertex(drawOrigX, drawOrigY, gnNumVs, gpVertices); gnNumSplineVs = gnNumVs; } else { gpRubberVertices = MakeMultiSplinePolygonVertex(LT_SPLINE, &gnNumSplineVs, gpnSmooth, drawOrigX, drawOrigY, gnNumVs, gpVertices); } if (gpRubberVertices == NULL) FailAllocMessage(); drawOrigX = saved_draw_orig_x; drawOrigY = saved_draw_orig_y; zoomedIn = saved_zoomed_in; zoomScale = saved_zoom_scale; } } if (*pn_need_to_draw) { int w, h, diam_y, radius_y, side_h; switch (curShape) { case SHAPE_OVAL: XDrawArc(mainDisplay, drawWindow, revDefaultGC, gShapeBBox.ltx, gShapeBBox.lty, gShapeBBox.rbx-gShapeBBox.ltx, gShapeBBox.rby-gShapeBBox.lty, 0, 360<<6); break; case SHAPE_DISK: w = gShapeBBox.rbx-gShapeBBox.ltx; h = gShapeBBox.rby-gShapeBBox.lty; radius_y = (int)(h/6); diam_y = (radius_y<<1); side_h = h-diam_y; XDrawArc(mainDisplay, drawWindow, revDefaultGC, gShapeBBox.ltx, gShapeBBox.lty, w, diam_y, 0, 360<<6); XDrawArc(mainDisplay, drawWindow, revDefaultGC, gShapeBBox.ltx, gShapeBBox.rby-diam_y, w, diam_y, 180<<6, 180<<6); XDrawLine(mainDisplay, drawWindow, revDefaultGC, gShapeBBox.ltx, gShapeBBox.lty+radius_y, gShapeBBox.ltx, gShapeBBox.rby-radius_y); XDrawLine(mainDisplay, drawWindow, revDefaultGC, gShapeBBox.rbx, gShapeBBox.lty+radius_y, gShapeBBox.rbx, gShapeBBox.rby-radius_y); break; default: if (gpVertices != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, gpRubberVertices, gnNumSplineVs, CoordModeOrigin); } break; } } } /* ----------------------- Generate Object Functions ----------------------- */ static struct AttrRec *GenerateInvisibleBox() { int w, h, saved_text_just=textJust, attr_w, attr_h, attr_ltx, attr_lty; int saved_fill=objFill, saved_trans_pat=transPat; struct BBRec bbox; struct BoxRec *box_ptr; struct AttrRec *attr_ptr, *label_attr=NULL; textJust = JUST_C; memcpy(&bbox, &gShapeBBox, sizeof(struct BBRec)); w = bbox.rbx-bbox.ltx; h = bbox.rby-bbox.lty; switch (curShape) { case SHAPE_WORDS: if (gnEndY >= gnOrigY) { bbox.rby -= rcbRadius; } else { bbox.lty += rcbRadius; } break; case SHAPE_TRIANGLE: if (gnEndY >= gnOrigY) { bbox.lty += (int)(h/3); } else { bbox.rby -= (int)(h/3); } break; case SHAPE_DISK: bbox.lty += (int)(h/3); break; case SHAPE_RIGHTARROW: case SHAPE_FATRIGHTARROW: case SHAPE_RIGHTTAB: if (gnEndX >= gnOrigX) { bbox.rbx -= (w>>2); } else { bbox.ltx += (w>>2); } break; case SHAPE_UPARROW: case SHAPE_FATUPARROW: case SHAPE_UPTAB: if (gnEndY >= gnOrigY) { bbox.lty += (h>>2); } else { bbox.rby -= (h>>2); } break; } if (bbox.rbx-bbox.ltx >= 12) { bbox.ltx += 4; bbox.rbx -= 4; } if (bbox.rby-bbox.lty >= 12) { bbox.lty += 4; bbox.rby -= 4; } CreateBoxObj(bbox.ltx, bbox.lty, bbox.rbx, bbox.rby, FALSE); box_ptr = topObj->detail.b; box_ptr->fill = NONEPAT; box_ptr->pen = NONEPAT; objFill = NONEPAT; transPat = FALSE; AddAttrByNameAndValue(topObj, "", "auto_center_attr"); attr_ptr = topObj->fattr; if (attr_ptr != NULL) { attr_ptr->shown = FALSE; UpdAttr(attr_ptr); AdjObjBBox(attr_ptr->obj); attr_w = attr_ptr->obj->obbox.rbx-attr_ptr->obj->obbox.ltx; attr_h = attr_ptr->obj->bbox.rby-attr_ptr->obj->bbox.lty; attr_ltx = ((topObj->obbox.ltx+topObj->obbox.rbx)>>1)-(attr_w>>1); attr_lty = topObj->bbox.lty; MoveObj(attr_ptr->obj, attr_ltx-attr_ptr->obj->obbox.ltx, attr_lty-attr_ptr->obj->obbox.lty); } AddAttrByNameAndValue(topObj, "label=", ""); transPat = saved_trans_pat; objFill = saved_fill; label_attr = FindAttrWithName(topObj, "label=", NULL); if (label_attr != NULL) { label_attr->nameshown = FALSE; label_attr->shown = TRUE; UpdAttr(label_attr); AdjObjBBox(label_attr->obj); attr_w = label_attr->obj->obbox.rbx-label_attr->obj->obbox.ltx; attr_h = label_attr->obj->bbox.rby-label_attr->obj->bbox.lty; attr_ltx = ((topObj->obbox.ltx+topObj->obbox.rbx)>>1)-(attr_w>>1); attr_lty = ((topObj->obbox.lty+topObj->obbox.rby)>>1)-(attr_h>>1); MoveObj(label_attr->obj, attr_ltx-label_attr->obj->obbox.ltx, attr_lty-label_attr->obj->obbox.lty); } AdjObjBBox(topObj); textJust = saved_text_just; return label_attr; } static void GenerateShadow() { struct ObjRec *obj_ptr; struct SelRec *tmp_top_sel=NULL, *tmp_bot_sel=NULL; SelAllObj(FALSE, FALSE); JustDupSelObj(&tmp_top_sel, &tmp_bot_sel); /* * At this point, the objects pointed by tmp_top_sel and * tmp_bot_sel are dangling. */ if (tmp_top_sel != tmp_bot_sel) { CreateGroupObj(tmp_top_sel->obj, tmp_bot_sel->obj); } else { obj_ptr = tmp_top_sel->obj; obj_ptr->next = topObj; obj_ptr->prev = NULL; if (topObj == NULL) { botObj = obj_ptr; } else { topObj->prev = obj_ptr; } topObj = obj_ptr; } RemoveAllSel(); UpdSelBBox(); /* move the new object to the bottom */ obj_ptr = topObj; UnlinkObj(topObj); obj_ptr->next = NULL; obj_ptr->prev = botObj; if (botObj == NULL) { topObj = obj_ptr; } else { botObj->next = obj_ptr; } botObj = obj_ptr; ChangeObjTransPat(obj_ptr, NO_TRANSPAT_MODE); ChangeObjFill(obj_ptr, SOLIDPAT); ChangeObjPen(obj_ptr, SOLIDPAT); MoveObj(obj_ptr, shapeShadowDx, shapeShadowDy); } static struct AttrRec *GenerateShape() { struct ObjRec *saved_top_obj, *saved_bot_obj, *tmp_top_obj, *tmp_bot_obj; int w, h, diam_y, radius_y, side_h, saved_cur_spline, saved_line_style; struct AttrRec *label_attr=NULL; struct BBRec bbox; saved_top_obj = topObj; saved_bot_obj = botObj; curPage->top = curPage->bot = topObj = botObj = NULL; switch (curShape) { case SHAPE_OVAL: CreateOvalObj(&gShapeBBox, FALSE); break; case SHAPE_DISK: saved_cur_spline = curSpline; saved_line_style = lineStyle; curSpline = LT_STRAIGHT; lineStyle = LS_PLAIN; w = gShapeBBox.rbx-gShapeBBox.ltx; h = gShapeBBox.rby-gShapeBBox.lty; radius_y = (int)(h/6); diam_y = (radius_y<<1); side_h = h-diam_y; if (penPat != NONEPAT) { int saved_pen=penPat; penPat = NONEPAT; CreateBoxObj(gShapeBBox.ltx, gShapeBBox.lty+radius_y, gShapeBBox.rbx, gShapeBBox.rby-radius_y, FALSE); penPat = saved_pen; } bbox.ltx = gShapeBBox.ltx; bbox.lty = gShapeBBox.lty; bbox.rbx = bbox.ltx+w; bbox.rby = bbox.lty+diam_y; CreateOvalObj(&bbox, FALSE); CreateArcObj(gShapeBBox.ltx+(w>>1), gShapeBBox.rby-radius_y, gShapeBBox.ltx, gShapeBBox.rby-radius_y, gShapeBBox.ltx+w, gShapeBBox.rby-radius_y, ARC_CCW, gShapeBBox.ltx, gShapeBBox.rby-diam_y, w, diam_y, 180<<6, 180<<6, FALSE); ResetCreatePoly(); AddPtToCreatePoly(gShapeBBox.ltx, gShapeBBox.lty+radius_y); AddPtToCreatePoly(gShapeBBox.ltx, gShapeBBox.rby-radius_y); CreatePolyObj(2, FALSE); ResetCreatePoly(); AddPtToCreatePoly(gShapeBBox.rbx, gShapeBBox.lty+radius_y); AddPtToCreatePoly(gShapeBBox.rbx, gShapeBBox.rby-radius_y); CreatePolyObj(2, FALSE); curSpline = saved_cur_spline; lineStyle = saved_line_style; break; default: CalcBBox(gnOrigX, gnOrigY, gnEndX, gnEndY, &(gShapeBBox.ltx), &(gShapeBBox.lty), &(gShapeBBox.rbx), &(gShapeBBox.rby)); if (gpVertices != NULL) { int i; saved_cur_spline = curSpline; curSpline = LT_STRAIGHT; ResetCreatePolygon(); for (i=0; i < gnNumVs; i++) { AddPtToCreatePolygon(gpVertices[i].x, gpVertices[i].y); } CreatePolygonObj(gnNumVs, FALSE); if (gpnSmooth != NULL) { struct PolygonRec *polygon_ptr=topObj->detail.g; if (polygon_ptr->smooth == NULL) { polygon_ptr->smooth = (char*)malloc((gnNumVs+1)*sizeof(char)); if (polygon_ptr->smooth == NULL) FailAllocMessage(); memset(polygon_ptr->smooth, 0, (gnNumVs+1)*sizeof(char)); } for (i=0; i < gnNumVs; i++) { polygon_ptr->smooth[i] = gpnSmooth[i]; } AdjObjSplineVs(topObj); UpdPolyBBox(topObj, polygon_ptr->n, polygon_ptr->vlist); AdjObjBBox(topObj); } curSpline = saved_cur_spline; } break; } if (shapeShadowDx != 0 || shapeShadowDy != 0) { GenerateShadow(); } label_attr = GenerateInvisibleBox(); /* * Use the next two functions to set selLtX, etc. to be used * in CreateGroupObj(). */ SelAllObj(FALSE, FALSE); RemoveAllSel(); tmp_top_obj = topObj; tmp_bot_obj = botObj; curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; CreateGroupObj(tmp_top_obj, tmp_bot_obj); return label_attr; } /* ----------------------- Event Loop ----------------------- */ #define START_SHOW 0 #define MOTION_SHOW 1 #define END_SHOW 2 static void DoCursor(x, y, w, h, which) int x, y, w, h, which; { char w_buf[80], h_buf[80], x_buf[80], y_buf[80]; PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(w))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(h))); PixelToMeasurementUnit(x_buf, ABS_X(x)); PixelToMeasurementUnit(y_buf, ABS_Y(y)); sprintf(gszMsgBox, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); switch (which) { case START_SHOW: StartShowMeasureCursor(x, y, gszMsgBox, TRUE); break; case MOTION_SHOW: ShowMeasureCursor(x, y, gszMsgBox, TRUE); break; case END_SHOW: EndShowMeasureCursor(x, y, gszMsgBox, TRUE); break; } } static void ContinueCreateShape(orig_x, orig_y) int orig_x, orig_y; { int done=FALSE, something_created=FALSE, grid_x=orig_x, grid_y=orig_y; int need_to_draw=FALSE; struct AttrRec *label_attr=NULL; BeginIntervalRulers(orig_x, orig_y, orig_x, orig_y); DoCursor(orig_x, orig_y, 0, 0, START_SHOW); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonReleaseMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } if (!StartCreateShape(orig_x, orig_y)) { Msg(TgLoadString(STID_CREATE_A_SHAPE_FAILED)); return; } HighLightCreateShape(grid_x, grid_y, GENERATE, &need_to_draw); while (!done) { XEvent input, ev; XNextEvent(mainDisplay, &input); switch (input.type) { case Expose: ExposeEventHandler(&input, TRUE); break; case VisibilityNotify: ExposeEventHandler(&input, TRUE); break; case MotionNotify: HighLightCreateShape(grid_x, grid_y, NO_GENERATE, &need_to_draw); DoCursor(grid_x, grid_y, grid_x-orig_x, grid_y-orig_y, MOTION_SHOW); GridXY(input.xmotion.x, input.xmotion.y, &grid_x, &grid_y); if (input.xmotion.state & (ShiftMask | ControlMask)) { int w=grid_x-orig_x, h=grid_y-orig_y, pos_w=TRUE, pos_h=TRUE; if (w < 0) { w = (-w); pos_w = FALSE; } if (h < 0) { h = (-h); pos_h = FALSE; } if (w > h) { grid_x = (pos_w ? orig_x+h : orig_x-h); } else { grid_y = (pos_h ? orig_y+w : orig_y-w); } } DoCursor(grid_x, grid_y, grid_x-orig_x, grid_y-orig_y, MOTION_SHOW); HighLightCreateShape(grid_x, grid_y, GENERATE, &need_to_draw); DrawIntervalRulers(orig_x, orig_y, grid_x, grid_y, NULL); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; break; case KeyPress: if (KeyPressEventIsEscape(&input.xkey)) { done = TRUE; } break; case ButtonRelease: if (grid_x != orig_x && grid_y != orig_y) { something_created = TRUE; } done = TRUE; break; } } XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); done = TRUE; DoCursor(grid_x, grid_y, grid_x-orig_x, grid_y-orig_y, END_SHOW); HighLightCreateShape(grid_x, grid_y, NO_GENERATE, &need_to_draw); EndIntervalRulers(grid_x, grid_y); if (something_created) { label_attr = GenerateShape(); numRedrawBBox = 0; topObj->tmp_parent = NULL; DrawObj(drawWindow, topObj); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; } EndCreateShape(); if (something_created && label_attr != NULL) { EditTextInAttr(label_attr); } } static void DoCreateShape() { unsigned int button; int mouse_x=0, mouse_y=0; Msg(TgLoadCachedString(CSTID_DRAG_MOUSE_CREATE_SHAPE_DOTS)); SetMouseStatus(GetShapeDesc(curShape), TgLoadCachedString(CSTID_CANCEL), TgLoadCachedString(CSTID_CANCEL)); button = DrawWindowLoop(&mouse_x, &mouse_y, cornerCursor, TRUE); if (button == Button1) { int grid_x=0, grid_y=0; GridXY(mouse_x, mouse_y, &grid_x, &grid_y); ContinueCreateShape(grid_x, grid_y); } else { Msg(TgLoadCachedString(CSTID_CREATE_A_SHAPE_ABORTED)); } } static void CreateShape() { int force_no_shadow=FALSE, saved_dx=shapeShadowDx, saved_dy=shapeShadowDy; MakeQuiescent(); if ((objFill == NONEPAT || (objFill == BACKPAT && transPat)) && (shapeShadowDx != 0 || shapeShadowDy != 0)) { sprintf(gszMsgBox, TgLoadString(objFill==NONEPAT ? STID_CREATE_SHADOW_SHAPE_NO_FILL : STID_CREATE_SHADOW_SHAPE_TRAN_FILL)); switch (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB)) { case MB_ID_YES: force_no_shadow = TRUE; break; case MB_ID_NO: break; default: return; } } if (force_no_shadow) { shapeShadowDx = shapeShadowDy = 0; } SaveStatusStrings(); DoCreateShape(); RestoreStatusStrings(); if (force_no_shadow) { shapeShadowDx = saved_dx; shapeShadowDy = saved_dy; } } /* ----------------------- Init and Clean Up ----------------------- */ void CleanUpShape() { CleanUpShapeDescMouseStatusStrings(); } void InitShape() { char *c_ptr; shapeShadowInResource = FALSE; shapeShadowDx = shapeShadowDy = 0; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ShapeShadowSpec")) != NULL) { if (ParseXYSpec(c_ptr, &shapeShadowDx, &shapeShadowDy)) { shapeShadowInResource = TRUE; } } } /* ----------------------- Menu Functions ----------------------- */ void ShapeSubMenu(nIndex) int nIndex; { if (nIndex < 0 || nIndex >= MAXSHAPES) return; curShape = nIndex; CreateShape(); curShape = (-1); } void RefreshShapeMenu(menu) TgMenu *menu; { } TgMenu *CreateShapeMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { int i=0; TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); stMenuInfo.items = (TgMenuItemInfo*)malloc( (MAXSHAPES+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (MAXSHAPES+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < MAXSHAPES; item_info++, i++) { item_info->menu_str = (char*)(Pixmap*)(&shapePixmap[i]); item_info->shortcut_str = NULL; sprintf(gszMsgBox, "%s", GetShapeDesc(i)); item_info->status_str = UtilStrDup(gszMsgBox); if (item_info->status_str == NULL) FailAllocMessage(); item_info->submenu_info = NULL; item_info->cmdid = CMDID_CREATESHAPE; } stMenuInfo.items[MAXSHAPES].cmdid = INVALID; /* the status_str has been translated in GetShapeDesc() */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < MAXSHAPES; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (MAXSHAPES+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, 8); } return menu; } int ShapeMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(shapeMenuInfo. create_proc)(NULL, X, Y, &shapeMenuInfo, INVALID); activeMenu = MENU_SHAPE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } /* ----------------------- Public Functions ----------------------- */ void SetShapeShadow() { char spec[MAXSTRING+1]; *spec = '\0'; sprintf(gszMsgBox, TgLoadString(STID_ENTER_XY_OFFSET_FOR_SHP_SHDW), shapeShadowDx, shapeShadowDy); Dialog(gszMsgBox, NULL, spec); if (ParseXYSpec(spec, &shapeShadowDx, &shapeShadowDy)) { sprintf(gszMsgBox, TgLoadString(STID_SHAPE_SHDW_XY_OFFSETS_SET_TO), shapeShadowDx, shapeShadowDy); Msg(gszMsgBox); } } ��������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/wb_buff.e����������������������������������������������������������������������������0000644�0000764�0000764�00000002325�11602233313�014547� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Magnos Martinello, <magnos@land.ufrj.br> in April, 1999. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb_buff.e,v 1.2 2008/10/16 21:13:03 william Exp $ */ #ifndef _WB_BUFF_E_ #define _WB_BUFF_E_ /* Comentario Principal */ #define DUPLICATED 4 #define SORTED 2 #define UNSORTED 1 #ifdef _INCLUDE_FROM_WB_BUFF_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_WB_BUFF_C_*/ extern int buff_show(int bd); extern int buff_init ARGS_DECL(( int n, int size, int option, int (*compar)(const void *, const void *))); extern void buff_cleanup ARGS_DECL((void)); extern int buff_ins ARGS_DECL((int bd, const void *buffer)); extern int buff_rem ARGS_DECL((int bd, void **buffer)); extern int buff_destroy ARGS_DECL((int bd)); extern int buff_empty ARGS_DECL((int bd)); extern int buff_emptyn ARGS_DECL((int bd, int n)); extern int buff_items ARGS_DECL((int bd)); extern int buff_conc ARGS_DECL((int bd1, int bd2)); extern int buff_sort ARGS_DECL(( int bd, int (*compar)(const void *, const void *))); #ifdef _INCLUDE_FROM_WB_BUFF_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_WB_BUFF_C_*/ #endif /*_WB_BUFF_E_*/ �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/page.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000223522�11602233312�014052� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/page.c,v 1.15 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_PAGE_C_ #include "tgifdefs.h" #include "expfdefs.h" #include "attr.e" #include "auxtext.e" #include "button.e" #include "cmd.e" #include "choice.e" #include "choose.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "font.e" #include "grid.e" #include "mark.e" #include "mainloop.e" #include "mainmenu.e" #include "menu.e" #include "menuinfo.e" #include "move.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "raster.e" #include "rect.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "stk.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "wb.e" #include "xpixmap.e" #include "xprtfltr.e" #include "xbm/leftend.xbm" struct PageRec *firstPage=NULL, *lastPage=NULL, *curPage=NULL; int curPageNum=1, lastPageNum=1; int paperRow=1, paperCol=1; int pageLayoutMode=PAGE_STACK; int pageLineShownInTileMode=TRUE; static int pageWindowFirstIndex=1; static int gnPageNumOnTab=TRUE; static int DrawAHorizontalTab(page_num, page_ptr, x, y, on_top, skip) int page_num, x, y, on_top, skip; struct PageRec *page_ptr; { char s[20]; XPoint v[5]; int w=0, num_digits=0, x_offset, y_offset; int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); if (gnPageNumOnTab) { sprintf(s, "%1d", page_num); num_digits = strlen(s); w = (num_digits+2)*rulerFontWidth; } else { /* not implemented yet */ if (page_ptr->name == NULL) { } else { } w = (num_digits+2)*rulerFontWidth; } if (skip) return w; v[0].x = v[4].x = x; v[0].y = v[4].y = y-1; v[1].x = x+rulerFontWidth; v[1].y = y+2+rulerFontHeight; v[2].x = x+w; v[2].y = y+2+rulerFontHeight; v[3].x = x+w+rulerFontWidth; v[3].y = y-1; XSetForeground(mainDisplay, defaultGC, (on_top ? myBgPixel: bg_pixel)); XFillPolygon(mainDisplay, pageWindow, defaultGC, v, 5, Convex, CoordModeOrigin); XSetForeground(mainDisplay, defaultGC, myFgPixel); if (on_top) { XDrawLines(mainDisplay, pageWindow, defaultGC, v, 4, CoordModeOrigin); XSetForeground(mainDisplay, defaultGC, myBgPixel); XDrawLines(mainDisplay, pageWindow, defaultGC, &v[3], 2, CoordModeOrigin); XSetForeground(mainDisplay, defaultGC, myFgPixel); } else { XDrawLines(mainDisplay, pageWindow, defaultGC, v, 5, CoordModeOrigin); } y_offset = ((rulerFontHeight-7)>>1)+1; x_offset = (rulerFontWidth>>1)+rulerFontWidth; XDrawString(mainDisplay, pageWindow, defaultGC, x+x_offset, y+1+rulerFontAsc, s, num_digits); XSetForeground(mainDisplay, defaultGC, myFgPixel); return w; } static int MaxPageTabsWidth() { int i=0, total=0; for (i=1; i <= lastPageNum; i++) { total += DrawAHorizontalTab(i, NULL, 0, 0, FALSE, TRUE); } return total; } static int PageTabsVisible(pn_last_tab_visible) int *pn_last_tab_visible; { int i=0, total=pageWindowW-(scrollBarW<<2)-1; int last_tab_visible=pageWindowFirstIndex; for (i=pageWindowFirstIndex; i <= lastPageNum; i++) { total -= DrawAHorizontalTab(i, NULL, 0, 0, FALSE, TRUE); if (total < 0) { break; } last_tab_visible = i; } if (pn_last_tab_visible != NULL) { *pn_last_tab_visible = last_tab_visible; } if (curPageNum >= pageWindowFirstIndex && curPageNum <= last_tab_visible) { return TRUE; } return FALSE; } static void MakePageTabsVisible(last_tab_visible) int last_tab_visible; { int total=pageWindowW-(scrollBarW<<2)-1; if (MaxPageTabsWidth() <= total) { pageWindowFirstIndex = 1; return; } if (curPageNum < pageWindowFirstIndex) { while (pageWindowFirstIndex > 1) { pageWindowFirstIndex--; if (PageTabsVisible(NULL)) { return; } } } else if (curPageNum >= pageWindowFirstIndex && curPageNum <= last_tab_visible) { return; } else { while (pageWindowFirstIndex <= lastPageNum) { pageWindowFirstIndex++; if (PageTabsVisible(NULL)) { return; } } #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pageWindowFirstIndex > lastPageNum, "pageWindowFirstIndex > lastPageNum in MakePageTabsVisible()", NULL); #endif /* _TGIF_DBG */ pageWindowFirstIndex = curPageNum; } } void RedrawPageWindow() { int i=0, x=0, y=1; struct PageRec *page_ptr=NULL; XClearArea(mainDisplay, pageWindow, 0, 0, pageWindowW, scrollBarW+(brdrW<<1), FALSE); XDrawRectangle(mainDisplay, pageWindow, defaultGC, 0, 0, pageWindowW-1, scrollBarW+(brdrW<<1)-1); if (pageLayoutMode == PAGE_TILE) return; x = 1 + (leftend_width<<2); XSetFont(mainDisplay, defaultGC, rulerFontPtr->fid); for (i=1, page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next, i++) { if (i >= pageWindowFirstIndex) { int w=0; if (i == curPageNum) { w = DrawAHorizontalTab(i, page_ptr, x, y, TRUE, TRUE); } else { w = DrawAHorizontalTab(i, page_ptr, x, y, FALSE, FALSE); } x += w; } } x = 1 + (leftend_width<<2); for (i=1, page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next, i++) { if (i >= pageWindowFirstIndex) { int w=0; if (i == curPageNum) { w = DrawAHorizontalTab(i, page_ptr, x, y, TRUE, FALSE); break; } else { w = DrawAHorizontalTab(i, page_ptr, x, y, FALSE, TRUE); } x += w; } } XSetFont(mainDisplay, defaultGC, defaultFontPtr->fid); y = (threeDLook ? (windowPadding>>1) : brdrW); for (i=0, x=y; i < 4; i++, x += leftend_width) { XSetTSOrigin(mainDisplay, rasterGC, x, y); XSetStipple(mainDisplay, rasterGC, scrollPixmap[i]); XFillRectangle(mainDisplay, pageWindow, rasterGC, x, y, leftend_width, leftend_height); if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, x, y, x+leftend_height, y+leftend_height); TgDrawThreeDButton(mainDisplay, pageWindow, textMenuGC, &bbox, TGBS_RAISED, 1, FALSE); } } XSetTSOrigin(mainDisplay, rasterGC, 0, 0); } void MakeCurPageTabVisible() { int last_tab_visible=(-1); if (pageLayoutMode == PAGE_TILE) return; if (!PageTabsVisible(&last_tab_visible)) { MakePageTabsVisible(last_tab_visible); } } void GotoPageNum(new_page_num) int new_page_num; { int i=1; struct PageRec *page_ptr=NULL; if (new_page_num <= 0 || curPage == NULL) return; curPage->draw_orig_x = drawOrigX; curPage->draw_orig_y = drawOrigY; curPage->zoom_scale = zoomScale; curPage->zoomed_in = zoomedIn; for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next, i++) { if (i == new_page_num) { break; } } curPageNum = new_page_num; curPage = page_ptr; topObj = curPage->top; botObj = curPage->bot; if (curPage->draw_orig_x != drawOrigX || curPage->draw_orig_y != drawOrigY || curPage->zoom_scale != zoomScale || curPage->zoomed_in != zoomedIn) { if (!PRTGIF) AdjSplineVs(); if (!PRTGIF) AdjCaches(); curPage->draw_orig_x = drawOrigX; curPage->draw_orig_y = drawOrigY; curPage->zoom_scale = zoomScale; curPage->zoomed_in = zoomedIn; } MakeCurPageTabVisible(); } static int curChoiceBeforePageChange=NOTHING; void SetCurPage(page_number) int page_number; { int need_to_redraw=TRUE; if (pageLayoutMode == PAGE_TILE) return; MakeQuiescent(); if (gstWBInfo.do_whiteboard) { /* No warning! Just clear the whiteboard! */ RecordWBClearAll(); } else { PrepareToRecord(CMD_GOTO_PAGE, NULL, NULL, curPageNum); } GotoPageNum(page_number); if (!gstWBInfo.do_whiteboard) { RecordCmd(CMD_GOTO_PAGE, NULL, NULL, NULL, curPageNum); } if (resetOriginOnAdvancePage) { int saved_x=0, saved_y=0, saved_zoom_scale=0, saved_zoomed_in=0; GetOrigin(&saved_x, &saved_y, &saved_zoom_scale, &saved_zoomed_in); SetOrigin(0, 0, 0, FALSE); if (ScrollToOrigin()) { /* scrolled or un-zoomed */ need_to_redraw = FALSE; } SetOrigin(saved_x, saved_y, saved_zoom_scale, saved_zoomed_in); } if (need_to_redraw) { ClearAndRedrawDrawWindow(); } RedrawTitleWindow(); MakeCurPageTabVisible(); ShowPage(); SetCurChoice(curChoiceBeforePageChange); if (gstWBInfo.do_whiteboard && topObj != NULL) { #ifdef _TGIF_WB2_NO_DELAY_BUG sleep(1); #endif /* ~_TGIF_WB2_NO_DELAY_BUG */ /* * In slideshow mode, SelAllObj() will *not* select anything! * Since we really want the objects to be selected (because * we want to record them), we must set ignore_slideshow * to TRUE when we call SelAllObj(). */ SelAllObj(FALSE, TRUE); PrepareToRecord(CMD_NEW, NULL, NULL, 0); RecordCmd(CMD_NEW, NULL, topSel, botSel, numObjSelected); RemoveAllSel(); } } static void HandleClickInPageWindow(button_ev) XButtonEvent *button_ev; { int i, index=(int)(button_ev->x / scrollBarW), total, offset; struct PageRec *page_ptr; if (button_ev->x <= 0) { index = 0; } else { index = (int)((button_ev->x-1) / scrollBarW); } switch (index) { case SCROLL_LEFTEND: pageWindowFirstIndex = 1; RedrawPageWindow(); break; case SCROLL_LEFT: if (pageWindowFirstIndex > 1) { if (button_ev->state & (ShiftMask | ControlMask)) { pageWindowFirstIndex -= 10; if (pageWindowFirstIndex < 1) pageWindowFirstIndex = 1; } else { pageWindowFirstIndex--; } RedrawPageWindow(); } break; case SCROLL_RIGHT: if (pageWindowFirstIndex < lastPageNum) { if (button_ev->state & (ShiftMask | ControlMask)) { pageWindowFirstIndex += 10; if (pageWindowFirstIndex > lastPageNum) { pageWindowFirstIndex = lastPageNum; } } else { pageWindowFirstIndex++; } RedrawPageWindow(); } break; case SCROLL_RIGHTEND: total = pageWindowW-(scrollBarW<<2)-1; pageWindowFirstIndex = lastPageNum; for (i=lastPageNum, page_ptr=lastPage; page_ptr != NULL; page_ptr=page_ptr->prev, i--) { int w=DrawAHorizontalTab(i, page_ptr, 0, 0, FALSE, TRUE); total -= w; if (total > 0) { pageWindowFirstIndex = i; } else { break; } } RedrawPageWindow(); break; default: offset = button_ev->x-(scrollBarW<<2)-1; for (i=1, page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next, i++) { if (i >= pageWindowFirstIndex) { int w=DrawAHorizontalTab(i, page_ptr, 0, 0, FALSE, TRUE); if (w >= offset) { /* int start=(((rulerFontWidth<<1)-7)>>1)+rulerFontWidth; */ if (page_ptr != curPage) { curChoiceBeforePageChange = curChoice; SetCurPage(i); } break; } offset -= w; } } break; } } static void HandleMotionInPageWindow(motion_ev) XMotionEvent *motion_ev; { int i=0, index=0, offset=0, left_stid=0; struct PageRec *page_ptr=NULL; if (motion_ev->x <= 0) { index = 0; } else { index = (int)((motion_ev->x-1) / scrollBarW); } switch (index) { case SCROLL_LEFTEND: case SCROLL_LEFT: case SCROLL_RIGHT: case SCROLL_RIGHTEND: if (motion_ev->state & (ShiftMask | ControlMask)) { switch (index) { case SCROLL_LEFTEND: left_stid = CSTID_SHIFT_ALL_TABS_RIGHT; break; case SCROLL_LEFT: left_stid = CSTID_SHIFT_10_TABS_RIGHT; break; case SCROLL_RIGHT: left_stid = CSTID_SHIFT_10_TABS_LEFT; break; case SCROLL_RIGHTEND: left_stid = CSTID_SHIFT_ALL_TABS_LEFT; break; } } else { switch (index) { case SCROLL_LEFTEND: left_stid = CSTID_SHIFT_ALL_TABS_RIGHT; break; case SCROLL_LEFT: left_stid = CSTID_SHIFT_TABS_RIGHT; break; case SCROLL_RIGHT: left_stid = CSTID_SHIFT_TABS_LEFT; break; case SCROLL_RIGHTEND: left_stid = CSTID_SHIFT_ALL_TABS_LEFT; break; } } SetMouseStatus(TgLoadCachedString(left_stid), TgLoadCachedString(CSTID_PAGE_MENU), TgLoadCachedString(CSTID_PARANED_NONE)); break; default: offset = motion_ev->x-(scrollBarW<<2)-1; for (i=1, page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next, i++) { if (i >= pageWindowFirstIndex) { int w=DrawAHorizontalTab(i, page_ptr, 0, 0, FALSE, TRUE); if (w >= offset) { /* int start=(((rulerFontWidth<<1)-7)>>1)+rulerFontWidth; */ if (page_ptr->name == NULL) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_GOTO_GIVEN_PAGE), i); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_GOTO_GIVEN_PAGE_WITH_NAME), i, page_ptr->name); } SetStringStatus(gszMsgBox); break; } offset -= w; } } if (page_ptr == NULL) { SetMouseStatus(TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PAGE_MENU), TgLoadCachedString(CSTID_PARANED_NONE)); } break; } } void RedrawPageDummyWindow() { XClearWindow(mainDisplay, pageDummyWindow); if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, pageDummyWindowW, scrollBarW); TgDrawThreeDButton(mainDisplay, pageDummyWindow, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); } } void PageDummyEventHandler(input) XEvent *input; { if (input->type == Expose) { XEvent ev; while (XCheckWindowEvent(mainDisplay,pageDummyWindow,ExposureMask,&ev)) ; RedrawPageDummyWindow(); } else if (input->type == EnterNotify) { SetMouseStatusToAllNone(); } } static void FreePage(page_ptr) struct PageRec *page_ptr; { topObj = page_ptr->top; botObj = page_ptr->bot; DelAllObj(); if (page_ptr->name != NULL) free(page_ptr->name); if (page_ptr->page_file_name != NULL) free(page_ptr->page_file_name); free(page_ptr); topObj = NULL; botObj = NULL; } static void InitPageOnlyOnce() { static int initialized=FALSE; if (initialized) return; initialized = TRUE; if (PRTGIF) return; } void InitPage() /* given lastPageNum, allocate enough pages */ { int i; InitPageOnlyOnce(); while (firstPage != NULL) { curPage = firstPage->next; FreePage(firstPage); firstPage = curPage; } firstPage = lastPage = curPage = NULL; for (i=1; i <= lastPageNum; i++) { curPage = (struct PageRec *)malloc(sizeof(struct PageRec)); if (curPage == NULL) FailAllocMessage(); memset(curPage, 0, sizeof(struct PageRec)); curPage->layer_on = TRUE; curPage->name = NULL; curPage->page_file_name = NULL; curPage->top = curPage->bot = topObj = botObj = NULL; curPage->next = NULL; curPage->prev = lastPage; curPage->draw_orig_x = drawOrigX; curPage->draw_orig_y = drawOrigY; curPage->zoom_scale = zoomScale; curPage->zoomed_in = zoomedIn; if (firstPage == NULL) { firstPage = curPage; } else { lastPage->next = curPage; } lastPage = curPage; } curPageNum = (lastPageNum > 0 ? 1 : 0); curPage = (lastPageNum > 0 ? firstPage : NULL); } void NextPage() { if (pageLayoutMode == PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_DO_NEXTPAGE_IN_TILED), TOOL_NAME, INFO_MB); return; } if (curPageNum == lastPageNum) { if (!inSlideShow) { MsgBox(TgLoadString(STID_ALREADY_AT_LAST_PAGE), TOOL_NAME, INFO_MB); } return; } curChoiceBeforePageChange = curChoice; SetCurPage(curPageNum+1); } void PrevPage() { if (pageLayoutMode == PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_DO_PREVPAGE_IN_TILED), TOOL_NAME, INFO_MB); return; } if (curPageNum == 1) { if (!inSlideShow) { MsgBox(TgLoadString(STID_ALREADY_AT_FIRST_PAGE), TOOL_NAME, INFO_MB); } return; } curChoiceBeforePageChange = curChoice; SetCurPage(curPageNum-1); } static int leadingChars=(-1); static char formatStr[20]; static DspList *pageNameDspPtr=NULL; static DspList *PageNameListing(pn_entries) int *pn_entries; { int i; DspList *dsp_ptr=NULL; struct PageRec *page_ptr=NULL; for (leadingChars=1, i=lastPageNum; ;leadingChars++, i /= 10) { if (i < 10) { break; } } sprintf(formatStr, "%%%1dd %%s", leadingChars++); pageNameDspPtr = (DspList*)malloc(lastPageNum*sizeof(DspList)); if (pageNameDspPtr == NULL) FailAllocMessage(); memset(pageNameDspPtr, 0, lastPageNum*sizeof(DspList)); for (i=1, dsp_ptr=pageNameDspPtr, page_ptr=firstPage; i <= lastPageNum; i++, dsp_ptr++, page_ptr=page_ptr->next) { sprintf(gszMsgBox, formatStr, i, ((page_ptr->name == NULL) ? "" : page_ptr->name)); UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), gszMsgBox); dsp_ptr->directory = FALSE; dsp_ptr->next = ((i == lastPageNum) ? NULL : &dsp_ptr[1]); } *pn_entries = lastPageNum; return pageNameDspPtr; } static int EditOrSelectPageNames(TopStr, Which, entries, num_entries) char *TopStr, **entries; int Which; /* either PAGE_GOTO or PAGE_NAME */ int num_entries; { int marked_index=curPageNum-1, rc=INVALID; char win_name[128]; ResetNamesInfo(); NamesSetTitle(TopStr); NamesAddButton(TgLoadCachedString(CSTID_OK), BUTTON_OK); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); NamesSetEntries(NULL, entries, num_entries, NULL, TRUE, marked_index, leadingChars); if (Which==PAGE_NAME) { /* ignore double-click and <CR> */ NamesSetDefaultBtnId(INVALID, INVALID); sprintf(win_name, TgLoadString(STID_TOOL_NAME_PAGES), TOOL_NAME); NamesSetStyle(NAMES_EDIT_NAME, NAMES_LOOP_ONCE); if (Names(win_name, NULL, NULL, 0, NULL) == BUTTON_OK) { rc = TRUE; } } else { int selected_index=INVALID; sprintf(win_name, TgLoadString(STID_TOOL_GOTO_PAGE), TOOL_NAME); NamesSetStyle(NAMES_COMPLEX_SELECT_NAME, NAMES_LOOP_ONCE); if (Names(win_name, &selected_index, NULL, 0, NULL) != INVALID) { return selected_index; } } return rc; } void GotoPage(psz_page_num) char *psz_page_num; { int index=(-1); if (pageLayoutMode == PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_DO_GOTOPAGE_IN_TILED), TOOL_NAME, INFO_MB); return; } curChoiceBeforePageChange = curChoice; MakeQuiescent(); if (psz_page_num != NULL && strcmp(psz_page_num, "-1") != 0) { index = atoi(psz_page_num); } else { int num_entries=0; DspList *dsp_ptr; char **entries=NULL; dsp_ptr = PageNameListing(&num_entries); ignoreDirectoryFlag = TRUE; entries = MakeNameDspItemArray(num_entries, dsp_ptr); ignoreDirectoryFlag = FALSE; index = EditOrSelectPageNames(TgLoadString(STID_GOTO_PAGE_DOTS), PAGE_GOTO, entries, num_entries); free(dsp_ptr); free(*entries); free(entries); if (index++ == (-1)) { Msg(TgLoadString(STID_NO_PAGE_SELECTED)); return; } } if (index < 1 || index > lastPageNum) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_PAGE_NUMBER), index); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (psz_page_num == NULL && index == curPageNum) { sprintf(gszMsgBox, TgLoadString(STID_ALREADY_AT_GIVEN_PAGE), curPageNum); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } SetCurPage(index); sprintf(gszMsgBox, TgLoadString(STID_CUR_PAGE_IS_GIVEN_PAGE_NUM), curPageNum); Msg(gszMsgBox); } void NamePages() { int i, num_entries=0; DspList *dsp_ptr; char **entries=NULL; if (pageLayoutMode == PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_DO_NAMEPAGES_IN_TILED), TOOL_NAME, INFO_MB); return; } MakeQuiescent(); dsp_ptr = PageNameListing(&num_entries); ignoreDirectoryFlag = TRUE; entries = MakeNameDspItemArray(num_entries, dsp_ptr); ignoreDirectoryFlag = FALSE; if (EditOrSelectPageNames(TgLoadString(STID_EDIT_PAGE_NAMES_DOTS), PAGE_NAME, entries, num_entries)) { int modified=FALSE; struct PageRec *page_ptr; for (page_ptr=firstPage, i=0; page_ptr!=NULL; page_ptr=page_ptr->next, i++) { int blank_str=BlankStr(&(entries[i])[leadingChars]); if (page_ptr->name == NULL) { if (!blank_str) { modified = TRUE; page_ptr->name = UtilStrDup(&(entries[i])[leadingChars]); if (page_ptr->name == NULL) FailAllocMessage(); } } else { if (blank_str || strcmp(page_ptr->name, &(entries[i])[leadingChars]) != 0) { modified = TRUE; UtilFree(page_ptr->name); if (blank_str) { page_ptr->name = NULL; } else { page_ptr->name = UtilStrDup(&(entries[i])[leadingChars]); if (page_ptr->name == NULL) FailAllocMessage(); } } } } if (modified) { SetFileModified(TRUE); RedrawTitleWindow(); } } free(dsp_ptr); free(*entries); free(entries); Msg(""); SetCurChoice(curChoiceBeforeMakeQuiescent); } static DspList *PageFileNameListing(pn_entries) int *pn_entries; { int i; DspList *dsp_ptr=NULL; struct PageRec *page_ptr=NULL; for (leadingChars=1, i=lastPageNum; ;leadingChars++, i /= 10) { if (i < 10) { break; } } sprintf(formatStr, "%%%1dd %%s", leadingChars++); pageNameDspPtr = (DspList*)malloc(lastPageNum*sizeof(DspList)); if (pageNameDspPtr == NULL) FailAllocMessage(); memset(pageNameDspPtr, 0, lastPageNum*sizeof(DspList)); for (i=1, dsp_ptr=pageNameDspPtr, page_ptr=firstPage; i <= lastPageNum; i++, dsp_ptr++, page_ptr=page_ptr->next) { char *psz=NULL; sprintf(gszMsgBox, formatStr, i, ((page_ptr->page_file_name == NULL) ? "" : page_ptr->page_file_name)); UtilTrimBlanks(&gszMsgBox[leadingChars]); if ((psz=strchr(&gszMsgBox[leadingChars], ' ')) != NULL) *psz = '\0'; UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), gszMsgBox); dsp_ptr->directory = FALSE; dsp_ptr->next = ((i == lastPageNum) ? NULL : &dsp_ptr[1]); } *pn_entries = lastPageNum; return pageNameDspPtr; } void EditPageFileNames() { int i, num_entries=0; DspList *dsp_ptr=NULL; char **entries=NULL; if (pageLayoutMode == PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_EDITPAGEFNAME_IN_TILED), TOOL_NAME, INFO_MB); return; } MakeQuiescent(); dsp_ptr = PageFileNameListing(&num_entries); ignoreDirectoryFlag = TRUE; entries = MakeNameDspItemArray(num_entries, dsp_ptr); ignoreDirectoryFlag = FALSE; if (EditOrSelectPageNames(TgLoadString(STID_EDIT_PAGE_FILE_NAMES_DOTS), PAGE_NAME, entries, num_entries)) { int modified=FALSE; struct PageRec *page_ptr=NULL; char *psz=NULL; for (page_ptr=firstPage, i=0; page_ptr!=NULL; page_ptr=page_ptr->next, i++) { int blank_str=BlankStr(&(entries[i])[leadingChars]); if (page_ptr->page_file_name == NULL) { if (!blank_str) { modified = TRUE; page_ptr->page_file_name = UtilStrDup(&(entries[i])[leadingChars]); if (page_ptr->page_file_name == NULL) FailAllocMessage(); if ((psz=strchr(page_ptr->page_file_name, ' ')) != NULL) { char truncated_name[MAXSTRING]; *psz = *truncated_name = '\0'; UtilStrCpyN(truncated_name, sizeof(truncated_name), page_ptr->page_file_name); *psz = ' '; sprintf(gszMsgBox, TgLoadString(STID_PAGE_FNAME_NO_SPACE_TRUNC), page_ptr->page_file_name, truncated_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(page_ptr->page_file_name, truncated_name); } } } else { if (blank_str || strcmp(page_ptr->page_file_name, &(entries[i])[leadingChars]) != 0) { modified = TRUE; UtilFree(page_ptr->page_file_name); if (blank_str) { page_ptr->page_file_name = NULL; } else { page_ptr->page_file_name = UtilStrDup(&(entries[i])[leadingChars]); if (page_ptr->page_file_name == NULL) FailAllocMessage(); if ((psz=strchr(page_ptr->page_file_name, ' ')) != NULL) { char truncated_name[MAXSTRING]; *psz = *truncated_name = '\0'; UtilStrCpyN(truncated_name, sizeof(truncated_name), page_ptr->page_file_name); *psz = ' '; sprintf(gszMsgBox, TgLoadString(STID_PAGE_FNAME_NO_SPACE_TRUNC), page_ptr->page_file_name, truncated_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(page_ptr->page_file_name, truncated_name); } } } } } if (modified) { SetFileModified(TRUE); RedrawTitleWindow(); } } free(dsp_ptr); free(*entries); free(entries); Msg(""); SetCurChoice(curChoiceBeforeMakeQuiescent); } int OkToFlushUndoBuffer(msg_prefix) char *msg_prefix; { if (firstCmd != NULL) { int len=strlen(msg_prefix), rc=0; char *buf=(char*)malloc((len+MAXSTRING)*sizeof(char)); if (buf == NULL) FailAllocMessage(); XBell(mainDisplay, 0); sprintf(buf, "%s\n\n%s", msg_prefix, TgLoadString(STID_OK_TO_FLUSH_UNDO_AND_PROCEED)); rc = MsgBox(buf, TOOL_NAME, YNC_MB); UtilFree(buf); if (rc == MB_ID_YES) { CleanUpCmds(); return TRUE; } return FALSE; } return TRUE; } #define BEFORE_CUR_PAGE 0 #define AFTER_CUR_PAGE 1 typedef struct tagAddPageCopyAllInfo { struct ObjRec *top_obj; struct ObjRec *bot_obj; } AddPageCopyAllInfo; static void AddPage(AfterCurPage, papcai) int AfterCurPage; AddPageCopyAllInfo *papcai; { int n; struct PageRec *page_ptr=NULL; struct AttrRec *attr_ptr=NULL; if (pageLayoutMode == PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_DO_ADDPAGE_IN_TILED), TOOL_NAME, INFO_MB); return; } if (firstCmd != NULL) { sprintf(gszMsgBox, TgLoadString(AfterCurPage ? STID_ADD_PAGE_AFTER_GIVEN_FLUSH : STID_ADD_PAGE_BEFORE_GIVEN_FLUSH), curPageNum); if (!OkToFlushUndoBuffer(gszMsgBox)) { return; } CleanUpCmds(); } n = (AfterCurPage ? curPageNum : curPageNum-1); MakeQuiescent(); for (curPageNum=1, curPage=firstPage; curPageNum <= n; curPageNum++) { curPage=curPage->next; } page_ptr = (struct PageRec *)malloc(sizeof(struct PageRec)); if (page_ptr == NULL) FailAllocMessage(); memset(page_ptr, 0, sizeof(struct PageRec)); page_ptr->layer_on = TRUE; page_ptr->top = page_ptr->bot = topObj = botObj = NULL; page_ptr->next = curPage; page_ptr->name = NULL; page_ptr->page_file_name = NULL; page_ptr->draw_orig_x = drawOrigX; page_ptr->draw_orig_y = drawOrigY; page_ptr->zoom_scale = zoomScale; page_ptr->zoomed_in = zoomedIn; if (curPage == NULL) { page_ptr->prev = lastPage; lastPage->next = page_ptr; lastPage = page_ptr; } else { page_ptr->prev = curPage->prev; if (curPage->prev == NULL) { firstPage = page_ptr; } else { curPage->prev->next = page_ptr; } curPage->prev = page_ptr; } curPage = page_ptr; lastPageNum++; topObj = curPage->top; botObj = curPage->bot; if (papcai != NULL) { struct ObjRec *obj_ptr=NULL; struct SelRec *top_sel=NULL, *bot_sel=NULL; for (obj_ptr=papcai->bot_obj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; AddObjIntoSel(obj_ptr, NULL, topSel, &topSel, &botSel); } DupTheseObjects(topSel, botSel, &top_sel, &bot_sel); RemoveAllSel(); curPage->top = topObj = top_sel->obj; curPage->bot = botObj = bot_sel->obj; topSel = top_sel; botSel = bot_sel; RemoveAllSel(); } ClearAndRedrawDrawWindow(); RedrawTitleWindow(); SetFileModified(TRUE); MakeCurPageTabVisible(); ShowPage(); if (papcai == NULL && !cmdLineMerge) { if ((attr_ptr=FindAttrWithName(tgifObj, "template=", NULL)) != NULL) { char file_name[MAXPATHLENGTH]; if (*attr_ptr->attr_value.s == DIR_SEP) { UtilStrCpyN(file_name, sizeof(file_name), attr_ptr->attr_value.s); } else { sprintf(file_name, "%s%c%s", bootDir, DIR_SEP, attr_ptr->attr_value.s); } importingFile = TRUE; if (ImportGivenFile(file_name, TRUE, TRUE)) { sprintf(gszMsgBox, TgLoadString(STID_NAMED_TEMPLATE_LOADED), attr_ptr->attr_value.s); Msg(gszMsgBox); } else { sprintf(gszMsgBox, TgLoadString(STID_PROB_LOADING_NAMED_TEMPLATE), file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } importingFile = FALSE; } } sprintf(gszMsgBox, TgLoadString(STID_GIVEN_PAGE_NUM_ADDED), curPageNum); Msg(gszMsgBox); SetCurChoice(curChoiceBeforeMakeQuiescent); } void AddPageBefore() { if (gstWBInfo.do_whiteboard) { MsgBox(TgLoadString(STID_ADDPAGEBEFORE_IN_WB), TOOL_NAME, INFO_MB); return; } AddPage(BEFORE_CUR_PAGE, NULL); } void AddPageAfter() { if (gstWBInfo.do_whiteboard) { MsgBox(TgLoadString(STID_ADDPAGEAFTER_IN_WB), TOOL_NAME, INFO_MB); return; } AddPage(AFTER_CUR_PAGE, NULL); } void AddPageBeforeCopyAll() { AddPageCopyAllInfo apcai; if (gstWBInfo.do_whiteboard) { MsgBox(TgLoadString(STID_ADDPAGEBEFORE_IN_WB), TOOL_NAME, INFO_MB); return; } memset(&apcai, 0, sizeof(AddPageCopyAllInfo)); apcai.top_obj = topObj; apcai.bot_obj = botObj; AddPage(BEFORE_CUR_PAGE, &apcai); } void AddPageAfterCopyAll() { AddPageCopyAllInfo apcai; if (gstWBInfo.do_whiteboard) { MsgBox(TgLoadString(STID_ADDPAGEAFTER_IN_WB), TOOL_NAME, INFO_MB); return; } memset(&apcai, 0, sizeof(AddPageCopyAllInfo)); apcai.top_obj = topObj; apcai.bot_obj = botObj; AddPage(AFTER_CUR_PAGE, &apcai); } void DeleteCurPage() { int n; struct PageRec *page_ptr=NULL; if (pageLayoutMode == PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_DO_DELETEPAGE_IN_TILED), TOOL_NAME, INFO_MB); return; } if (lastPageNum == 1) { MsgBox(TgLoadString(STID_CANT_DEL_ONLY_PAGE_IN_STACKED), TOOL_NAME, INFO_MB); return; } if (firstCmd != NULL || topObj != NULL) { sprintf(gszMsgBox, TgLoadString(STID_DELETE_GIVEN_PAGE_CAUSE_FLUSH), curPageNum); if (!OkToFlushUndoBuffer(gszMsgBox)) { return; } CleanUpCmds(); } n = curPageNum; SetFileModified(TRUE); MakeQuiescent(); if (curPage == firstPage) { page_ptr = firstPage = curPage->next; firstPage->prev = NULL; } else if (curPage == lastPage) { page_ptr = lastPage = curPage->prev; lastPage->next = NULL; curPageNum--; } else { curPage->next->prev = curPage->prev; curPage->prev->next = curPage->next; page_ptr = curPage->next; } FreePage(curPage); curPage = page_ptr; lastPageNum--; topObj = curPage->top; botObj = curPage->bot; ClearAndRedrawDrawWindow(); RedrawTitleWindow(); MakeCurPageTabVisible(); ShowPage(); sprintf(gszMsgBox, TgLoadString(STID_GIVEN_PAGE_NUM_DELETED), n); Msg(gszMsgBox); SetCurChoice(curChoiceBeforeMakeQuiescent); } void TogglePageLineShown() { if (pageLayoutMode == PAGE_STACK) { MsgBox(TgLoadString(STID_CANT_TPLS_IN_STACKED), TOOL_NAME, INFO_MB); return; } pageLineShownInTileMode = !pageLineShownInTileMode; ClearAndRedrawDrawWindow(); } static int JustSpecifyDrawingSize() { char spec[MAXSTRING+1], *c_ptr, *part_1; int cols=0, rows=0; *spec = '\0'; if (Dialog(TgLoadString(STID_ENTER_DRAW_SIZE_SPEC_WH), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), spec) == INVALID) { return FALSE; } if ((part_1=strtok(spec, " ,xX")) == NULL) return FALSE; if ((c_ptr=strtok(NULL, " ,xX")) == NULL) { MsgBox(TgLoadString(STID_BAD_DRAW_SIZE_SPEC_WH), TOOL_NAME, INFO_MB); return FALSE; } else { cols = atoi(part_1); rows = atoi(c_ptr); } if (cols > 0 && rows > 0 && (cols*rows >= lastPageNum)) { if (cols*rows < lastPageNum) { sprintf(gszMsgBox, TgLoadString(STID_BAD_DRAW_SIZE_SPEC_W_TIMES_H), lastPageNum); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { paperCol = cols; paperRow = rows; return TRUE; } } else if (cols == 0 || rows == 0) { MsgBox(TgLoadString(STID_BAD_DRAW_SIZE_SPEC_WH), TOOL_NAME, INFO_MB); return FALSE; } else if (cols*rows < lastPageNum) { sprintf(gszMsgBox, TgLoadString(STID_BAD_DRAW_SIZE_SPEC_W_TIMES_H), lastPageNum); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { MsgBox(TgLoadString(STID_INVALID_DRAW_SIZE_SPEC), TOOL_NAME, INFO_MB); } return FALSE; } void SpecifyDrawingSize() { if (pageLayoutMode != PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_DO_SPECDRAWSIZE_IN_TILED), TOOL_NAME, INFO_MB); return; } if (JustSpecifyDrawingSize()) { UpdPageStyle(pageStyle); RedrawScrollBars(); UpdDrawWinBBox(); AdjSplineVs(); ClearAndRedrawDrawWindow(); ShowPage(); } } void PrintOnePage() { int x=0, y=0; switch (pageLayoutMode) { case PAGE_TILE: switch (whereToPrint) { case XBM_FILE: case TEXT_FILE: case NETLIST_FILE: case GIF_FILE: case HTML_FILE: case PNG_FILE: case JPEG_FILE: case PPM_FILE: sprintf(gszMsgBox, TgLoadString(STID_CANT_PRINTONEPAGE_IN_FORMAT), GetExportName(whereToPrint, EXPORT_THIS)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; default: break; } MakeQuiescent(); sprintf(gszMsgBox, " %s", TgLoadString(STID_OTHER_BTN_CANCEL_PRINTONEPAGE)); TwoLineMsg(TgLoadString(STID_BTN1_SEL_PAGE_TO_PRINT), gszMsgBox); SetMouseStatus(TgLoadString(STID_SELECT_A_PAGE_TO_PRINT), TgLoadCachedString(CSTID_CANCEL), TgLoadCachedString(CSTID_CANCEL)); if (PickAPoint(&x, &y, handCursor) != Button1) { Msg(TgLoadString(STID_OPERATION_CANCEL_BY_USER)); } else if (x>=0 && x<ZOOMED_SIZE(drawWinW) && y>=0 && y<ZOOMED_SIZE(drawWinH)) { int abs_x=ABS_X(x), abs_y=ABS_Y(y); int col=(int)(abs_x / onePageWidth); int row=(int)(abs_y / onePageHeight); if (col >= paperCol || row >= paperRow) { MsgBox(TgLoadString(STID_MUST_SEL_A_PT_ON_THE_PAPER), TOOL_NAME, INFO_MB); } else { DumpOnePageInTileMode(row, col); } } else { sprintf(gszMsgBox, TgLoadString(STID_MUST_SEL_A_PT_IN_TOOL_WIN), TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } SetCurChoice(curChoiceBeforeMakeQuiescent); break; case PAGE_STACK: MakeQuiescent(); DumpOnePageInStackMode(); SetCurChoice(curChoiceBeforeMakeQuiescent); break; } } int GetDimension(Spec, nNonPosReturnOK, pnNumPixels) char *Spec; int nNonPosReturnOK, *pnNumPixels; { char *c_ptr; double val; /* do not translate -- program constants */ if ((c_ptr=strstr(Spec, "in")) != NULL || (c_ptr=strstr(Spec, "In")) != NULL || (c_ptr=strstr(Spec, "IN")) != NULL) { *c_ptr = '\0'; val = atof(Spec) * ((double)PIX_PER_INCH); *pnNumPixels = round(val); if (!nNonPosReturnOK && *pnNumPixels <= 0) return FALSE; } else if ((c_ptr=strstr(Spec, "cm")) != NULL || (c_ptr=strstr(Spec, "Cm")) != NULL || (c_ptr=strstr(Spec, "CM")) != NULL) { *c_ptr = '\0'; val = atof(Spec) * ((double)ONE_CM); *pnNumPixels = round(val); if (!nNonPosReturnOK && *pnNumPixels <= 0) return FALSE; } else if (sscanf(Spec, "%d", pnNumPixels) != 1) { return FALSE; } else { if (!nNonPosReturnOK && *pnNumPixels <= 0) return FALSE; } return TRUE; } int GetDimensionInDouble(Spec, nNonPosReturnOK, pd_num_pixels) char *Spec; int nNonPosReturnOK; double *pd_num_pixels; { char *c_ptr=NULL; double dval=(double)0; /* do not translate -- program constants */ if ((c_ptr=strstr(Spec, "in")) != NULL || (c_ptr=strstr(Spec, "In")) != NULL || (c_ptr=strstr(Spec, "IN")) != NULL) { *c_ptr = '\0'; dval = atof(Spec) * ((double)PIX_PER_INCH); *pd_num_pixels = dval; if (!nNonPosReturnOK && dval < (double)0) return FALSE; } else if ((c_ptr=strstr(Spec, "cm")) != NULL || (c_ptr=strstr(Spec, "Cm")) != NULL || (c_ptr=strstr(Spec, "CM")) != NULL) { *c_ptr = '\0'; dval = atof(Spec) * ((double)ONE_CM); *pd_num_pixels = dval; if (!nNonPosReturnOK && dval < (double)0) return FALSE; } else if (sscanf(Spec, "%lf", pd_num_pixels) != 1) { return FALSE; } else { if (!nNonPosReturnOK && dval < (double)0) return FALSE; } return TRUE; } int SetPaperSize(Spec) char *Spec; { int ok=TRUE; char *c_ptr; UtilTrimBlanks(Spec); /* do not translate -- program constants */ if (UtilStrICmp(Spec, "letter") == 0) { onePageWidth = (85*PIX_PER_INCH)/10; onePageHeight = 11*PIX_PER_INCH; SetPSPageWidthHeight(); } else if (UtilStrICmp(Spec, "legal") == 0) { onePageWidth = (85*PIX_PER_INCH)/10; onePageHeight = 14*PIX_PER_INCH; SetPSPageWidthHeight(); } else if (UtilStrICmp(Spec, "a4") == 0) { onePageWidth = (825*PIX_PER_INCH)/100; onePageHeight = (117*PIX_PER_INCH)/10; SetPSPageWidthHeight(); } else if ((c_ptr=strstr(Spec, " x ")) == NULL && (c_ptr=strstr(Spec, " X ")) == NULL) { ok = FALSE; } else { int w_in_pixel, h_in_pixel; *c_ptr = '\0'; UtilTrimBlanks(&c_ptr[3]); if (GetDimension(Spec, FALSE, &w_in_pixel) && GetDimension(&c_ptr[3], FALSE, &h_in_pixel)) { onePageWidth = w_in_pixel; onePageHeight = h_in_pixel; SetPSPageWidthHeight(); } else { ok = FALSE; } } if (ok) { if (mainWindow != None) { sprintf(gszMsgBox, TgLoadString(STID_NEW_PAPER_SIZE_IS_GIVEN), (float)(((float)onePageWidth)/((float)PIX_PER_INCH)), (float)(((float)onePageHeight)/((float)PIX_PER_INCH)), (float)(((float)onePageWidth)/((float)ONE_CM)), (float)(((float)onePageHeight)/((float)ONE_CM))); Msg(gszMsgBox); } } else { if (mainWindow == None) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF), TOOL_NAME, "InitialPaperSize", Spec); fprintf(stderr, "%s\n", gszMsgBox); } else { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_PAPER_SIZE_SPEC), Spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } return ok; } static void GetCurPaperSizeSpec(buf) char *buf; { char w_str[MAXSTRING], h_str[MAXSTRING]; float w=((float)onePageWidth)*printMag/((float)100.0); float h=((float)onePageHeight)*printMag/((float)100.0); float unit=(float)0.0, w_val=(float)0.0, h_val=(float)0.0; switch (gridSystem) { case ENGLISH_GRID: unit = (float)PIX_PER_INCH; switch (pageStyle) { case PORTRAIT: w_val = w/unit; h_val = h/unit; break; case LANDSCAPE: w_val = h/unit; h_val = w/unit; break; } FormatFloat(&w_val, w_str); FormatFloat(&h_val, h_str); /* do not translate -- program constants */ sprintf(buf, "%s in x %s in", w_str, h_str); break; case METRIC_GRID: unit = (float)ONE_CM; switch (pageStyle) { case PORTRAIT: w_val = w/unit; h_val = h/unit; break; case LANDSCAPE: w_val = h/unit; h_val = w/unit; break; } FormatFloat(&w_val, w_str); FormatFloat(&h_val, h_str); /* do not translate -- program constants */ sprintf(buf, "%s cm x %s cm", w_str, h_str); break; } } void SpecifyPaperSize() { char buf[MAXSTRING+1], spec[MAXSTRING+1]; GetCurPaperSizeSpec(gszMsgBox); sprintf(buf, TgLoadString(STID_CUR_PAPER_SIZE_IS_GIVEN), gszMsgBox); *spec = '\0'; if (Dialog(TgLoadString(STID_ENTER_PAPER_SIZE_WH), buf, spec) == INVALID) { return; } MakeQuiescent(); if (SetPaperSize(spec)) { UpdPageStyle(pageStyle); SetFileModified(TRUE); ClearAndRedrawDrawWindow(); } SetCurChoice(curChoiceBeforeMakeQuiescent); } void FreePageSpec(pspi) SpecifyPagesInfo *pspi; { if (pspi->page_specified != NULL) free(pspi->page_specified); } int ParsePagesSpec(spec, pspi) char *spec; SpecifyPagesInfo *pspi; /* if return TRUE, must call FreePageSpec(pspi) */ { char *dup_spec=NULL, *c_ptr=NULL; int i, ok=TRUE; UtilTrimBlanks(spec); if (*spec == '\0') return FALSE; if ((pspi->page_specified=(int*)malloc(lastPageNum*sizeof(int))) == NULL) { FailAllocMessage(); return FALSE; } if ((dup_spec=UtilStrDup(spec)) == NULL) { free(pspi->page_specified); FailAllocMessage(); return FALSE; } if (strcmp(dup_spec, "*") == 0) { for (i=0; i < lastPageNum; i++) pspi->page_specified[i] = TRUE; pspi->num_pages_specified = lastPageNum; } else { for (i=0; i < lastPageNum; i++) pspi->page_specified[i] = FALSE; if (*dup_spec == '*') *dup_spec = ' '; for (c_ptr=strtok(dup_spec, " ,\t"); ok && c_ptr != NULL; c_ptr=strtok(NULL, " ,\t")) { char *dash_ptr=strchr(c_ptr, '-'); if (dash_ptr == NULL) { int page_num=atoi(c_ptr); if (page_num > 0 && page_num <= lastPageNum) { if (!pspi->page_specified[page_num-1]) { pspi->num_pages_specified++; } pspi->page_specified[page_num-1] = TRUE; } else { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_PAGE_NUM_IS_OUT_OF_RNG), page_num); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } } else { int start_page_num, end_page_num; *dash_ptr = '\0'; start_page_num = atoi(c_ptr); end_page_num = atoi(&dash_ptr[1]); *dash_ptr = '-'; if (start_page_num <= 0 || start_page_num > lastPageNum) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_PAGE_NUM_IS_OUT_OF_RNG), start_page_num); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else if (end_page_num <= 0 || end_page_num > lastPageNum) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_PAGE_NUM_IS_OUT_OF_RNG), end_page_num); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else if (start_page_num > end_page_num) { sprintf(gszMsgBox, TgLoadString(STID_MALFORMED_SPECIFICATION_STR), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else { for (i=start_page_num; i <= end_page_num; i++) { if (!pspi->page_specified[i-1]) pspi->num_pages_specified++; pspi->page_specified[i-1] = TRUE; } } } } } free(dup_spec); if (!ok) FreePageSpec(pspi); return ok; } void DeletePages() { char spec[MAXSTRING+1]; SpecifyPagesInfo spi; if (pageLayoutMode == PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_DO_DELETEPAGES_IN_TILED), TOOL_NAME, INFO_MB); return; } if (lastPageNum == 1) { MsgBox(TgLoadString(STID_CANT_DEL_ONLY_PAGE_IN_STACKED), TOOL_NAME, INFO_MB); return; } *spec = '\0'; Dialog(TgLoadString(STID_SPECIFY_PAGES_TO_DEL_EX), NULL, spec); UtilTrimBlanks(spec); if (*spec == '\0') return; memset(&spi, 0, sizeof(SpecifyPagesInfo)); if (!ParsePagesSpec(spec, &spi)) return; MakeQuiescent(); if (spi.num_pages_specified == lastPageNum) { MsgBox(TgLoadString(STID_CANT_DEL_ALL_PAGES), TOOL_NAME, INFO_MB); } else if (spi.num_pages_specified > 0) { sprintf(gszMsgBox, TgLoadString(spi.num_pages_specified > 1 ? STID_DELETE_A_PAGE_CAUSE_FLUSH : STID_DELETE_PAGES_PAGE_CAUSE_FLUSH)); if (firstCmd == NULL || OkToFlushUndoBuffer(gszMsgBox)) { struct PageRec *page_ptr; int page_num; for (page_num=lastPageNum; page_num > 0; page_num--) { if (spi.page_specified[page_num-1]) { GotoPageNum(page_num); if (curPage == firstPage) { page_ptr = firstPage = curPage->next; firstPage->prev = NULL; } else if (curPage == lastPage) { page_ptr = lastPage = curPage->prev; lastPage->next = NULL; curPageNum--; } else { curPage->next->prev = curPage->prev; curPage->prev->next = curPage->next; page_ptr = curPage->next; } FreePage(curPage); curPage = page_ptr; lastPageNum--; topObj = curPage->top; botObj = curPage->bot; } } CleanUpCmds(); ClearAndRedrawDrawWindow(); RedrawTitleWindow(); ShowPage(); sprintf(gszMsgBox, TgLoadString(spi.num_pages_specified > 1 ? STID_MANY_PAGES_DELETED : STID_ONE_PAGE_DELETED), spi.num_pages_specified); Msg(gszMsgBox); SetFileModified(TRUE); } } FreePageSpec(&spi); SetCurChoice(curChoiceBeforeMakeQuiescent); } void SavePagesAs() { char spec[MAXSTRING+1]; SpecifyPagesInfo spi; if (pageLayoutMode == PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_DO_SAVEPAGESAS_IN_TILED), TOOL_NAME, INFO_MB); return; } if (lastPageNum == 1) { SaveNewFile(FALSE, NULL); return; } *spec = '\0'; Dialog(TgLoadString(STID_SPECIFY_PAGES_TO_SAVE_EX), NULL, spec); UtilTrimBlanks(spec); if (*spec == '\0') return; memset(&spi, 0, sizeof(SpecifyPagesInfo)); if (!ParsePagesSpec(spec, &spi)) return; MakeQuiescent(); if (spi.num_pages_specified == lastPageNum) { SaveNewFile(FALSE, NULL); } else if (spi.num_pages_specified > 0) { SavePages(&spi); } FreePageSpec(&spi); SetCurChoice(curChoiceBeforeMakeQuiescent); } void PrintPages() { char spec[MAXSTRING]; if (pageLayoutMode == PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_PRINT_PAGES_IN_TILED), TOOL_NAME, INFO_MB); return; } /* only allows PRINTER, PS_FILE, PDF_FILE, or export filter formats */ switch (whereToPrint) { case LATEX_FIG: case XBM_FILE: case TEXT_FILE: case NETLIST_FILE: case EPSI_FILE: case GIF_FILE: case HTML_FILE: case TIFFEPSI_FILE: case PNG_FILE: case JPEG_FILE: case PPM_FILE: case SVG_FILE: sprintf(gszMsgBox, TgLoadString(STID_CANT_PRINT_PAGES_IN_FORMAT), GetExportName(whereToPrint, EXPORT_THIS)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; default: break; } strcpy(spec, "*"); Dialog(TgLoadString(STID_SPECIFY_PAGES_TO_PRINT_EX), NULL, spec); UtilTrimBlanks(spec); if (*spec == '\0') return; MakeQuiescent(); memset(&gPagesToPrintSpec, 0, sizeof(SpecifyPagesInfo)); if (!ParsePagesSpec(spec, &gPagesToPrintSpec)) return; DumpPages(); FreePageSpec(&gPagesToPrintSpec); SetCurChoice(curChoiceBeforeMakeQuiescent); } void PrintOneFilePerPage() { char spec[MAXSTRING]; if (pageLayoutMode == PAGE_TILE) { MsgBox(TgLoadString(STID_CANT_DO_POFPP_IN_TILED), TOOL_NAME, INFO_MB); return; } else if (whereToPrint == PRINTER) { MsgBox(TgLoadString(STID_CANT_DO_POFPP_TO_PRINTER), TOOL_NAME, INFO_MB); return; } strcpy(spec, "*"); Dialog(TgLoadString(STID_SPECIFY_PAGES_TO_PRINT_EX), NULL, spec); UtilTrimBlanks(spec); if (*spec == '\0') return; MakeQuiescent(); memset(&gPagesToPrintSpec, 0, sizeof(SpecifyPagesInfo)); if (!ParsePagesSpec(spec, &gPagesToPrintSpec)) return; DumpOneFilePerPage(); FreePageSpec(&gPagesToPrintSpec); SetCurChoice(curChoiceBeforeMakeQuiescent); } int StackedPageMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(stackedPageMenuInfo.create_proc)(NULL, X, Y, &stackedPageMenuInfo, FALSE); activeMenu = MENU_STACKEDPAGE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } int TiledPageMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(tiledPageMenuInfo.create_proc)(NULL, X, Y, &tiledPageMenuInfo, FALSE); activeMenu = MENU_TILEDPAGE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } int RefreshPageMenu(menu) TgMenu *menu; { int ok=TRUE; ok &= TgEnableMenuItemByIndex(menu, PAGE_STACK, (pageLayoutMode==PAGE_STACK)); ok &= TgEnableMenuItemByIndex(menu, PAGE_TILE, (pageLayoutMode!=PAGE_STACK)); return ok; } TgMenu *CreatePageMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshPageMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshPageMenu); } return menu; } int PageMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { switch (pageLayoutMode) { case PAGE_STACK: return StackedPageMenu(X, Y, TrackMenubar); case PAGE_TILE: return TiledPageMenu(X, Y, TrackMenubar); } return INVALID; } void DelAllPages() { register struct PageRec *next_page=NULL; for (curPage=firstPage; curPage != NULL; curPage=next_page) { next_page = curPage->next; FreePage(curPage); } lastPageNum = 0; firstPage = lastPage = curPage = NULL; InitPage(); } static int AnyObjOnPageBoundary() { register struct ObjRec *obj_ptr; int ltx, lty, rbx, rby, next_page_x, next_page_y; for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { ltx = obj_ptr->obbox.ltx; lty = obj_ptr->obbox.lty; rbx = obj_ptr->obbox.rbx; rby = obj_ptr->obbox.rby; if (ltx < 0 || lty < 0 || rbx >= onePageWidth*paperCol || rby >= onePageHeight*paperRow) { MsgBox(TgLoadString(STID_OBJ_OUTSIDE_PAGE_BNRDY_SWITCH), TOOL_NAME, INFO_MB); return TRUE; } next_page_x = ((ltx % onePageWidth) == 0) ? onePageWidth * (round(ltx / onePageWidth) + 1) : onePageWidth * (((int)(ltx / onePageWidth)) + 1); next_page_y = ((lty % onePageHeight) == 0) ? onePageHeight * (round(lty / onePageHeight) + 1) : onePageHeight * (((int)(lty / onePageHeight)) + 1); if (rbx >= next_page_x || rby >= next_page_y) { MsgBox(TgLoadString(STID_OBJ_OUTSIDE_PAGE_BNRDY_SWITCH), TOOL_NAME, INFO_MB); return TRUE; } } return FALSE; } static int CalcStackPageNum(obj_ptr) struct ObjRec *obj_ptr; { int ltx, lty, col, row; ltx = obj_ptr->obbox.ltx; lty = obj_ptr->obbox.lty; col = ((ltx % onePageWidth) == 0) ? round(ltx / onePageWidth) + 1 : ((int)(ltx / onePageWidth)) + 1; row = ((lty % onePageHeight) == 0) ? round(lty / onePageHeight) + 1 : ((int)(lty / onePageHeight)) + 1; return ((row-1) * paperCol + col); } static void TileToStack() { register int i; register struct ObjRec *obj_ptr, *prev_obj; int *dx=NULL, *dy=NULL, index; struct PageRec **page_handle=NULL; struct ObjRec *saved_top_obj, *saved_bot_obj; saved_top_obj=curPage->top; saved_bot_obj=curPage->bot; curPage->top = curPage->bot = NULL; DelAllPages(); firstPage = lastPage = curPage = NULL; lastPageNum = paperCol * paperRow; InitPage(); page_handle = (struct PageRec **)malloc(lastPageNum*sizeof(struct PageRec*)); if (page_handle == NULL) FailAllocMessage(); dx = (int*)malloc(lastPageNum*sizeof(int)); dy = (int*)malloc(lastPageNum*sizeof(int)); if (dx == NULL || dy == NULL) FailAllocMessage(); for (curPage=firstPage, i=0; curPage != NULL; curPage=curPage->next, i++) { dx[i] = (i % paperCol) * onePageWidth; dy[i] = (((i % paperCol) == 0) ? round(i / paperCol): ((int)(i / paperCol))) * onePageHeight; page_handle[i] = curPage; } for (obj_ptr=saved_bot_obj; obj_ptr != NULL; obj_ptr = prev_obj) { prev_obj = obj_ptr->prev; index = CalcStackPageNum(obj_ptr)-1; curPage = page_handle[index]; AddObj(NULL, curPage->top, obj_ptr); MoveObj(obj_ptr, -(dx[index]), -(dy[index])); } curPage = firstPage; topObj = curPage->top; botObj = curPage->bot; curPageNum = 1; paperCol = paperRow = 1; free(dx); free(dy); free(page_handle); } static void StackToTile() { register struct ObjRec *obj_ptr, *prev_obj; int i, dx, dy; struct PageRec *saved_first_page, *saved_last_page; struct PageRec *tmp_page, *page_ptr; if (paperCol * paperRow < lastPageNum && !JustSpecifyDrawingSize()) return; saved_first_page = firstPage; saved_last_page = lastPage; firstPage = lastPage = NULL; lastPageNum = 1; InitPage(); tmp_page = firstPage; i = 0; for (page_ptr=saved_first_page; page_ptr != NULL; page_ptr=page_ptr->next, i++) { dx = (i % paperCol) * onePageWidth; dy = (((i % paperCol) == 0) ? round(i / paperCol): ((int)(i / paperCol))) * onePageHeight; for (obj_ptr=page_ptr->bot; obj_ptr != NULL; obj_ptr=prev_obj) { prev_obj = obj_ptr->prev; AddObj(NULL, topObj, obj_ptr); MoveObj(obj_ptr, dx, dy); } page_ptr->top = page_ptr->bot = NULL; } firstPage = saved_first_page; lastPage = saved_last_page; DelAllPages(); firstPage = lastPage = curPage = tmp_page; curPageNum = lastPageNum = 1; pageLineShownInTileMode = TRUE; topObj = curPage->top; botObj = curPage->bot; } static int PreservePageNames() { struct PageRec *page_ptr=NULL; for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next) { if (page_ptr->name != NULL && *page_ptr->name != '\0') { break; } else if (page_ptr->page_file_name != NULL && *page_ptr->page_file_name != '\0') { break; } } if (page_ptr != NULL) { if (MsgBox(TgLoadString(STID_SWTCH_TO_TILED_LOSE_ALL_NAMES), TOOL_NAME, YNC_MB) != MB_ID_YES) { return FALSE; } } return TRUE; } void PageLayoutSubMenu(index) int index; { if (pageLayoutMode == index) return; if (gstWBInfo.do_whiteboard) { MsgBox(TgLoadString(STID_CHANGE_PAGE_LAYOUT_MODE_IN_WB), TOOL_NAME, INFO_MB); return; } if (!OkToFlushUndoBuffer(TgLoadString(STID_CHNG_PAGE_LAYOUT_FLUSH))) { return; } MakeQuiescent(); switch (index) { case PAGE_STACK: if (AnyObjOnPageBoundary()) { SetCurChoice(curChoiceBeforeMakeQuiescent); return; } pageLayoutMode = index; TileToStack(); Msg(TgLoadString(STID_PAGE_LAYOUT_MODE_IS_STACKED)); break; case PAGE_TILE: if (!PreservePageNames() || !JustSpecifyDrawingSize()) { SetCurChoice(curChoiceBeforeMakeQuiescent); return; } pageLayoutMode = index; StackToTile(); Msg(TgLoadString(STID_PAGE_LAYOUT_MODE_IS_TILED)); break; } ShowPage(); ShowPageLayout(); UpdatePinnedMenu(MENU_FILE); UpdatePinnedMenu(MENU_LAYOUT); UpdatePinnedMenu(MENU_PAGELAYOUT); UpdatePinnedMenu(MENU_MAIN); switch (pageLayoutMode) { case PAGE_STACK: DestroyPinnedMenu(MENU_TILEDPAGE); break; case PAGE_TILE: DestroyPinnedMenu(MENU_STACKEDPAGE); break; } DestroyPinnedMenu(MENU_PAGE); UpdPageStyle(pageStyle); RedrawScrollBars(); UpdDrawWinBBox(); AdjSplineVs(); ClearAndRedrawDrawWindow(); RedrawTitleWindow(); SetFileModified(TRUE); SetCurChoice(curChoiceBeforeMakeQuiescent); } void RefreshPageLayoutMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == pageLayoutMode); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreatePageLayoutMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, MAXPAGELAYOUTMODES); menu_item = (&menu->menuitems[pageLayoutMode]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshPageLayoutMenu); } return menu; } int PageLayoutMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(pageLayoutMenuInfo.create_proc)(NULL, X, Y, &pageLayoutMenuInfo, INVALID); activeMenu = MENU_PAGELAYOUT; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } void PageEventHandler(input) XEvent *input; { XEvent ev; if (input->type == Expose) { while (XCheckWindowEvent(mainDisplay, pageWindow, ExposureMask, &ev)) ; RedrawPageWindow(); } else if (input->type == EnterNotify) { SetMouseStatus("", "", ""); } else if (input->type == MotionNotify) { while (XCheckWindowEvent(mainDisplay,pageWindow,PointerMotionMask,&ev)) ; if (pageLayoutMode == PAGE_TILE) { SetMouseStatus(TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PAGE_MENU), TgLoadCachedString(CSTID_PARANED_NONE)); } else { HandleMotionInPageWindow(&input->xmotion); } } else if (input->type == ButtonPress) { XButtonEvent *button_ev=(&(input->xbutton)); if (pageLayoutMode == PAGE_TILE) { if (button_ev->button == Button2) { PageMenu(button_ev->x_root, button_ev->y_root, FALSE); } } else { if (button_ev->button == Button1) { HandleClickInPageWindow(button_ev); } else if (button_ev->button == Button2) { PageMenu(button_ev->x_root, button_ev->y_root, FALSE); } } } } void CleanUpPage() { DelAllPages(); if (leftend_bits == NULL) { } } static PageInfo stPageInfo; void PushPageInfo() { stPageInfo.page_layout_mode = pageLayoutMode; stPageInfo.paper_col = paperCol; stPageInfo.paper_row = paperRow; stPageInfo.cur_page_num = curPageNum; stPageInfo.last_page_num = lastPageNum; stPageInfo.first_page = firstPage; stPageInfo.last_page = lastPage; stPageInfo.cur_page = curPage; } void PopPageInfo() { pageLayoutMode = stPageInfo.page_layout_mode; paperCol = stPageInfo.paper_col; paperRow = stPageInfo.paper_row; curPageNum = stPageInfo.cur_page_num; lastPageNum = stPageInfo.last_page_num; firstPage = stPageInfo.first_page; lastPage = stPageInfo.last_page; curPage = stPageInfo.cur_page; } void GetPageInfo(pPageInfo) PageInfo *pPageInfo; { pPageInfo->page_layout_mode = pageLayoutMode; pPageInfo->paper_col = paperCol; pPageInfo->paper_row = paperRow; pPageInfo->cur_page_num = curPageNum; pPageInfo->last_page_num = lastPageNum; pPageInfo->first_page = firstPage; pPageInfo->last_page = lastPage; pPageInfo->cur_page = curPage; } /* --------------------- FixPageNumbersForSlideShow() --------------------- */ static int FixPageNumInStrSeg(pStrSeg, attr_ptr, just_checking) StrSegInfo *pStrSeg; struct AttrRec *attr_ptr; int just_checking; { static int page_num_str_len=0, num_pages_str_len=0; static int stInitialized=FALSE; if (!stInitialized) { stInitialized = TRUE; /* do not translate -- program constants */ page_num_str_len = strlen("!(STACKED_PAGE_NUM)"); num_pages_str_len = strlen("!(STACKED_NUM_PAGES)"); } /* do not translate -- program constants */ if (strstr(pStrSeg->dyn_str.s, "!(STACKED_PAGE_NUM)") != NULL || strstr(pStrSeg->dyn_str.s, "!(STACKED_NUM_PAGES)") != NULL) { char *c_ptr=NULL, *c_ptr1=NULL; struct ObjRec *attr_owner_obj=NULL; if (just_checking) { return TRUE; } attr_owner_obj = GetTopOwner(attr_ptr->owner); while ((c_ptr=strstr(pStrSeg->dyn_str.s, "!(STACKED_PAGE_NUM)")) != NULL) { c_ptr1 = &c_ptr[page_num_str_len]; sprintf(c_ptr, "%1d", curPageNum); c_ptr = &c_ptr[strlen(c_ptr)]; while (*c_ptr1 != '\0') *c_ptr++ = *c_ptr1++; *c_ptr = '\0'; } while ((c_ptr=strstr(pStrSeg->dyn_str.s, "!(STACKED_NUM_PAGES)")) != NULL) { c_ptr1 = &c_ptr[num_pages_str_len]; sprintf(c_ptr, "%1d", lastPageNum); c_ptr = &c_ptr[strlen(c_ptr)]; while (*c_ptr1 != '\0') *c_ptr++ = *c_ptr1++; *c_ptr = '\0'; } RecursivelyAdjObjBBox(attr_ptr->owner, attr_ptr->owner, attr_owner_obj); SetFileModified(TRUE); return TRUE; } return FALSE; } static int FixPageNumInStrBlock(pStrBlock, attr_ptr, just_checking) StrBlockInfo *pStrBlock; struct AttrRec *attr_ptr; int just_checking; { int changed=FALSE; switch (pStrBlock->type) { case SB_SIMPLE: if (FixPageNumInStrSeg(pStrBlock->seg, attr_ptr, just_checking)) { if (just_checking) { return TRUE; } changed = TRUE; } break; case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->type == SB_SUPSUB_CENTER) { if (FixPageNumInStrSeg(pStrBlock->seg, attr_ptr, just_checking)) { if (just_checking) { return TRUE; } changed = TRUE; } } if (pStrBlock->sup != NULL) { if (FixPageNumInMiniLines(pStrBlock->sup, attr_ptr, just_checking)) { if (just_checking) { return TRUE; } changed = TRUE; } } if (pStrBlock->sub != NULL) { if (FixPageNumInMiniLines(pStrBlock->sub, attr_ptr, just_checking)) { if (just_checking) { return TRUE; } changed = TRUE; } } break; } return changed; } static int FixPageNumInMiniLine(pMiniLine, attr_ptr, just_checking) MiniLineInfo *pMiniLine; struct AttrRec *attr_ptr; int just_checking; { int changed=FALSE; StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (FixPageNumInStrBlock(pStrBlock, attr_ptr, just_checking)) { if (just_checking) { return TRUE; } changed = TRUE; } } return changed; } int FixPageNumInMiniLines(minilines, attr_ptr, just_checking) MiniLinesInfo *minilines; struct AttrRec *attr_ptr; int just_checking; { int changed=FALSE; MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (FixPageNumInMiniLine(pMiniLine, attr_ptr, just_checking)) { if (just_checking) { return TRUE; } changed = TRUE; } } return changed; } static int FixPageNumInAttr(AttrPtr, just_checking) struct AttrRec *AttrPtr; int just_checking; { int changed=FALSE; for ( ; AttrPtr != NULL; AttrPtr=AttrPtr->prev) { if (!AttrPtr->shown) { continue; } /* do not translate -- program constants */ if (!AttrPtr->nameshown && *AttrPtr->attr_name.s == '!' && strcmp(AttrPtr->attr_name.s, "!PAGE_NUM=") == 0) { if (FixPageNumInMiniLines(&AttrPtr->obj->detail.t->minilines, AttrPtr, just_checking)) { if (just_checking) { return TRUE; } UpdateAttr(AttrPtr->obj->detail.t, AttrPtr); changed = TRUE; } } } return changed; } static int FixPageNumInObj(ObjPtr, just_checking) struct ObjRec *ObjPtr; int just_checking; { int something_changed=FALSE; switch (ObjPtr->type) { case OBJ_POLY: case OBJ_BOX: case OBJ_OVAL: case OBJ_POLYGON: case OBJ_ARC: case OBJ_RCBOX: case OBJ_XBM: case OBJ_XPM: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { if (FixPageNumInAttr(ObjPtr->lattr, just_checking)) { if (just_checking) { return TRUE; } else { something_changed = TRUE; } } } break; case OBJ_TEXT: break; case OBJ_SYM: case OBJ_ICON: case OBJ_GROUP: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { struct ObjRec *obj_ptr=ObjPtr->detail.r->last; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = ObjPtr; if (FixPageNumInObj(obj_ptr, just_checking)) { if (just_checking) { return TRUE; } else { something_changed = TRUE; } } } if (FixPageNumInAttr(ObjPtr->lattr, just_checking)) { if (just_checking) { return TRUE; } else { something_changed = TRUE; } } } break; case OBJ_PIN: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { struct ObjRec *obj_ptr=GetPinObj(ObjPtr); obj_ptr->tmp_parent = ObjPtr; if (FixPageNumInObj(obj_ptr, just_checking)) { if (just_checking) { return TRUE; } else { something_changed = TRUE; } } if (FixPageNumInAttr(ObjPtr->lattr, just_checking)) { if (just_checking) { return TRUE; } else { something_changed = TRUE; } } } break; } if (just_checking) return FALSE; return something_changed; } void FixPageNumbersForSlideShow() { int i=0, saved_cur_page_num=curPageNum, page_num=1, num_pages_to_fix=0; int *pages_to_fix=NULL; struct PageRec *page_ptr=NULL; struct ObjRec *obj_ptr=NULL; for (page_ptr=firstPage, page_num=1; page_ptr != NULL; page_ptr=page_ptr->next, page_num++) { for (obj_ptr=page_ptr->bot; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (FixPageNumInObj(obj_ptr, TRUE)) { num_pages_to_fix++; if (pages_to_fix == NULL) { pages_to_fix = (int*)malloc(sizeof(int)); } else { pages_to_fix = (int*)realloc(pages_to_fix, num_pages_to_fix*sizeof(int)); } if (pages_to_fix == NULL) FailAllocMessage(); pages_to_fix[num_pages_to_fix-1] = page_num; break; } } } if (num_pages_to_fix == 0) { /* nothing to fix */ return; } StartCompositeCmd(); for (i=0; i < num_pages_to_fix; i++) { page_num = pages_to_fix[i]; if (page_num != curPageNum) { PrepareToRecord(CMD_GOTO_PAGE, NULL, NULL, curPageNum); GotoPageNum(page_num); RecordCmd(CMD_GOTO_PAGE, NULL, NULL, NULL, curPageNum); } if (gstWBInfo.do_whiteboard && curPageNum != saved_cur_page_num) { /* * Since the whiteboard is active, others only see * the current page. So, changes to other * pages should not be seen by other whiteboards. */ gstWBInfo.dont_serialize = TRUE; } for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { PrepareToReplaceAnObj(obj_ptr); if (FixPageNumInObj(obj_ptr, FALSE)) { RecordReplaceAnObj(obj_ptr); } else { AbortPrepareCmd(CMD_REPLACE); } } if (gstWBInfo.do_whiteboard && curPageNum != saved_cur_page_num) { gstWBInfo.dont_serialize = FALSE; } } if (curPageNum != saved_cur_page_num) { PrepareToRecord(CMD_GOTO_PAGE, NULL, NULL, curPageNum); GotoPageNum(saved_cur_page_num); RecordCmd(CMD_GOTO_PAGE, NULL, NULL, NULL, curPageNum); } EndCompositeCmd(); free(pages_to_fix); } int NeedToFixPageNumbersForSlideShow() { struct PageRec *page_ptr=NULL; struct ObjRec *obj_ptr=NULL; for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next) { for (obj_ptr=page_ptr->bot; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (FixPageNumInObj(obj_ptr, TRUE)) { return TRUE; } } } return FALSE; } static void ClearPaperColor() { myFileBgPixel = INVALID; if (myFileBgColorStr != NULL) { free(myFileBgColorStr); myFileBgColorStr = NULL; XSetWindowBackground(mainDisplay, drawWindow, myBgPixel); ClearAndRedrawDrawWindow(); RecalcXorPixels(); } } static int RemoveAllBgColorFileAttrs() /* This cannot be undone! */ { struct AttrRec *attr_ptr=NULL; int modified=FALSE; for (attr_ptr=tgifObj->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (strcmp(attr_ptr->attr_name.s, "bg_color=") == 0) { UnlinkAttr(attr_ptr); FreeTextObj(attr_ptr->obj); FreeAttr(attr_ptr); modified = TRUE; } } return modified; } void SetPaperColor() { char spec[MAXSTRING+1]; int new_alloc=FALSE, index=0; if (!OkToFlushUndoBuffer(TgLoadString(STID_SET_PAPER_COLOR_CAUSE_FLUSH))) { return; } *spec = '\0'; if (myFileBgColorStr == NULL) { Dialog(TgLoadString(STID_SPECIFY_A_PAPER_COLOR), NULL, spec); } else { sprintf(gszMsgBox, TgLoadString(STID_SPECIFY_A_PAPER_COLOR_CUR_IS), myFileBgColorStr); Dialog(gszMsgBox, TgLoadString(STID_ENTER_NONE_TO_REMOVE_COLOR), spec); } UtilTrimBlanks(spec); if (*spec == '\0') return; if (myFileBgColorStr != NULL) { if (UtilStrICmp(spec, myFileBgColorStr) == 0) { return; } } else if (UtilStrICmp(spec, "none") == 0) { return; } MakeQuiescent(); CleanUpCmds(); if (myFileBgColorStr != NULL) { if (UtilStrICmp(spec, myFileBgColorStr) == 0) { SetCurChoice(curChoiceBeforeMakeQuiescent); return; } else if (UtilStrICmp(spec, "none") == 0) { ClearPaperColor(); if (RemoveAllBgColorFileAttrs()) { Msg(TgLoadString(STID_PAPER_COLOR_REMOVED)); SetFileModified(TRUE); } SetCurChoice(curChoiceBeforeMakeQuiescent); return; } } index = QuickFindColorIndex(NULL, spec, &new_alloc, FALSE); if (index == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); SetCurChoice(curChoiceBeforeMakeQuiescent); return; } myFileBgColorStr = UtilStrDup(spec); if (myFileBgColorStr == NULL) FailAllocMessage(); if (SetFileBgColor()) { ClearAndRedrawDrawWindow(); } else { ClearPaperColor(); } RemoveAllBgColorFileAttrs(); AddAttrByNameAndValue(tgifObj, "bg_color=", spec); sprintf(gszMsgBox, TgLoadString(STID_PAPER_COLOR_SET_TO_GIVEN), spec); Msg(gszMsgBox); SetFileModified(TRUE); SetCurChoice(curChoiceBeforeMakeQuiescent); } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/big5.h�������������������������������������������������������������������������������0000644�0000764�0000764�00000003611�11602233310�013762� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * hzfont.h by Dr. Susie W. chu, March 18,1991 * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/big5.h,v 1.1 2004/06/18 23:19:08 william Exp $ */ #include <stdio.h> #ifdef undef typedef unsigned short ushort; typedef unsigned char uchar; #endif /* The following *.n are .15 means 16x15 fonts, .24 means 24x24 fonts .40 means 40x40 fonts, .48 means 48x48 fonts, .64 means 64x64 fonts For the screen display we use 16x15 font as default. (also in ROM). For the printout (laserjet,or ps) we use 24x24 font for m,l and k style. For the printout (laserjet,or ps) we use 48x48 font for s style. Big 5 code is a double byte encoding chinese scheme. The low byte ranges are 40-7e ( 63 of them) and a1-fe (94 of them). Font name range # of chars --------- ----- ---------- spcfont.n Special symbol a140 - a3bf 408 stdfont.n (a)Frequently used a440 - c67e 5401 <--- gap (b)Infrequently used c940 - f9d5 7652 (c)ETen words f9d6 - f9fe 41 -------- total 13,094 spcfsupp.n Suppliment c6a1 - c8d3 365 ascfont.n AscII half width 00 - ff 256 */ #define NSPC 408 #define NSTD1 5401 #define NSTD2 7652 #define NSTD3 41 #define NSUPP 365 #define NASCII 256 #define HISPCS 0xa1 #define HISPCE 0xa3 #define HISTD1S 0xa4 #define HISTD1E 0xc6 #define HISTD23S 0xc9 #define HISTD23E 0xf9 #define HISUPPS 0xc6 #define HISUPPE 0xc8 #define NLOWB1 63 #define NLOWB2 94 #define NLOWB 157 #define LO1S 0x40 #define LO1E 0x7e #define LO2S 0xa1 #define LO2E 0xfe #define LOSPCE 0xbf #define LOSTD1E 0x7e #define LOSTD23E 0xfe #define LOSUPPS 0xa1 #define LOSUPPE 0xd3 /* high order byte */ #define HB(code) ((code)>>8) /* low order byte */ #define LB(code) ((code)&0xff) �����������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/scroll.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000007036�11602233312�014436� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/scroll.e,v 1.6 2011/05/16 16:21:59 william Exp $ */ #ifndef _SCROLL_E_ #define _SCROLL_E_ extern int autoPan; extern int scrollingCanvas; extern int smoothScrollingCanvas; extern int resetOriginOnAdvancePage; #ifdef _INCLUDE_FROM_SCROLL_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_SCROLL_C_*/ extern int TgAnyButtonDown ARGS_DECL((Display*, Window)); extern int TgPressButtonLoop ARGS_DECL((Display*, Window, struct BBRec *, ScrollBtnCallbackInfo*)); extern int TgGetScrollHit ARGS_DECL((int x, int y, int orientation, int scroll_area_w, int scroll_area_h, double start_frac, int length, int total, int *pn_offset)); extern void TgDrawScrollBar ARGS_DECL((Display*, Window, int orientation, int x_off, int y_off, int scroll_area_w, int scroll_area_h, double start_frac, int length, int total)); extern void RedrawVScrollWindow ARGS_DECL((void)); extern void RedrawHScrollWindow ARGS_DECL((void)); extern void RedrawScrollBars ARGS_DECL((void)); extern void GetMaxScrollOrigin ARGS_DECL((int *pn_orig_x, int *pn_orig_y)); extern void ScrollTo ARGS_DECL((int XOff, int YOff)); extern void ScrollUp ARGS_DECL((XButtonEvent *)); extern void ForceScrollDown ARGS_DECL((int)); extern void ScrollDown ARGS_DECL((XButtonEvent *)); extern void ScrollLeft ARGS_DECL((XButtonEvent *)); extern void ScrollRight ARGS_DECL((XButtonEvent *)); extern void ScrollEventHandler ARGS_DECL((XEvent *)); extern void ScrollToSpecifiedOrigin ARGS_DECL((int page_num, int orig_x, int orig_y, int zoom_scale, int zoomed_in)); extern int ScrollToOrigin ARGS_DECL((void)); extern void SaveOrigin ARGS_DECL((void)); extern void SetOrigin ARGS_DECL((int x, int y, int zoom_scale, int zoomed_in)); extern void GetOrigin ARGS_DECL((int *pn_x, int *pn_y, int *pn_zoom_scale, int *pn_zoomed_in)); extern void CleanUpScrolls ARGS_DECL((void)); extern void UpdScrollWinWH ARGS_DECL((void)); extern void InitScroll ARGS_DECL((void)); extern void ChangeScrollMode ARGS_DECL((int ModeIndex)); extern int RefreshScrollModeMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateScrollModeMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); #ifdef _INCLUDE_FROM_SCROLL_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_SCROLL_C_*/ #endif /*_SCROLL_E_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/util.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000005527�11602233313�014121� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/util.e,v 1.10 2011/05/16 16:22:00 william Exp $ */ #ifndef _TGIF_UTIL_E_ #define _TGIF_UTIL_E_ #ifdef _INCLUDE_FROM_UTIL_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_UTIL_C_*/ extern void UtilFree ARGS_DECL((char *pszStr)); extern char *UtilFreeStringArray ARGS_DECL((char **ppsz, int nItems)); extern char *UtilStrDup ARGS_DECL((char *pszStr)); extern int UtilStrCpyN ARGS_DECL((char *pszDest, int nMaxDestSz, char *pszSrc)); extern int UtilStrCpy ARGS_DECL((char *pszDest, char *pszSrc)); extern void UtilLeftTrim ARGS_DECL((char *pszStr)); extern void UtilRightTrim ARGS_DECL((char *pszStr)); extern void UtilTrimBlanks ARGS_DECL((char *pszStr)); extern void UtilStrUpper ARGS_DECL((char *pszStr)); extern void UtilStrLower ARGS_DECL((char *pszStr)); extern int UtilStrNCaseCmp ARGS_DECL((char *pszStr1, char *pszStr2, int nCount)); extern int UtilStrICmp ARGS_DECL((char *pszStr1, char *pszStr2)); extern char *UtilStrRChr ARGS_DECL((char *pszStr, int int_ch)); extern char *UtilStrTok ARGS_DECL((char *pszStr, char *pszDelim, char **ppszState)); #ifdef NO_STRSTR extern char *strstr ARGS_DECL((char *pszStr, char *pszSubStr)); #endif /* NO_STRSTR */ extern int UtilShrinkName ARGS_DECL((char *pszFile)); extern void UtilRemoveQuotes ARGS_DECL((char *pszStr)); extern char *UtilGetALine ARGS_DECL((FILE *lpFile)); extern char *UtilGetAContinuedLine ARGS_DECL((FILE *lpFile)); extern int UtilCopyFile ARGS_DECL((char *pszFromFile, char *pszToFile)); extern int UtilConcatFile ARGS_DECL((char *pszFromFile1, char *pszFromFile2, char *pszToFile)); extern int UtilPathExists ARGS_DECL((char *pszPath)); extern int UtilPathIsLink ARGS_DECL((char *pszPath)); extern int UtilIsDirectory ARGS_DECL((char *pszPath)); extern int UtilCreateDirHier ARGS_DECL((char *pszDir)); extern long UtilGetMilliSecTime ARGS_DECL((long *pl_sec, long *pl_msec)); #ifdef _INCLUDE_FROM_UTIL_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_UTIL_C_*/ #endif /*_TGIF_UTIL_E_*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/slide-demo.obj�����������������������������������������������������������������������0000644�0000764�0000764�00000006060�11602233312�015504� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������state(0,17,200,0,0,0,16,1,0,1,2,0,0,1,0,1,1,1,0,4,0,0,0,10,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/slide-demo.obj,v 1.1 2004/09/14 05:26:24 william Exp $ % polygon('yellow',5,[ 176,32,176,152,368,152,368,32,176,32],1,5,10,1,131,0,0,[ ]). text('yellow',272,48,0,0,5,1,1,0,2,71,28,132,0,22,6,0,0,0,[ "A Slide"]). text('yellow',272,112,3,2,5,1,1,0,2,43,28,133,0,23,5,0,0,0,[ "Tgif"]). group([ box('yellow',48,176,80,208,0,1,0,134,0,0,[ ]), oval('yellow',60,188,68,196,1,1,1,135,0,0,[ ]) ],[ ]). text('yellow',96,183,0,1,4,1,0,0,1,227,21,136,0,17,4,0,0,0,[ "Dot is at 1 inch from the left."]). text('yellow',96,230,2,0,4,1,0,0,1,288,22,137,0,18,4,0,0,0,[ "This text is at 1.5 inch from the left."]). text('yellow',128,276,3,3,4,1,0,0,1,327,22,138,0,16,6,0,0,0,[ "This text is at 2 inches from the left."]). group([ box('yellow',96,272,112,304,0,1,0,139,0,0,[ ]), box('yellow',96,286,112,290,1,1,1,140,0,0,[ ]) ],[ ]). text('yellow',128,432,0,0,3,1,1,0,1,17,18,141,0,14,4,0,0,0,[ "2in"]). text('yellow',256,432,0,0,3,1,1,0,1,17,18,142,0,14,4,0,0,0,[ "4in"]). text('yellow',384,432,0,0,3,1,1,0,1,17,18,143,0,14,4,0,0,0,[ "6in"]). text('yellow',448,480,0,0,3,1,1,0,1,17,18,144,0,14,4,0,0,0,[ "7in"]). text('yellow',320,480,0,0,3,1,1,0,1,17,18,145,0,14,4,0,0,0,[ "5in"]). text('yellow',192,480,0,0,3,1,1,0,1,17,18,146,0,14,4,0,0,0,[ "3in"]). text('yellow',64,480,0,0,3,1,1,0,1,17,18,147,0,14,4,0,0,0,[ "1in"]). poly('yellow',2,[ 384,304,384,424],2,1,1,8,0,0,0,0,8,3,[ ]). poly('yellow',2,[ 256,304,256,424],2,1,1,10,0,0,0,0,8,3,[ ]). poly('yellow',2,[ 128,304,128,424],2,1,1,12,0,0,0,0,8,3,[ ]). poly('yellow',2,[ 448,304,448,472],2,1,1,7,0,0,0,0,8,3,[ ]). poly('yellow',2,[ 320,304,320,472],2,1,1,9,0,0,0,0,8,3,[ ]). poly('yellow',2,[ 192,304,192,472],2,1,1,11,0,0,0,0,8,3,[ ]). poly('yellow',2,[ 64,304,64,472],2,1,1,13,0,0,0,0,8,3,[ ]). text('yellow',272,80,2,0,5,1,1,0,7,145,29,154,0,24,5,0,0,0,[ "Presented by"]). text('yellow',128,496,1,0,0,1,1,0,1,15,11,167,0,9,2,0,0,0,[ "8pt"]). text('yellow',128,512,1,0,1,1,1,0,1,24,11,168,0,9,2,0,0,0,[ "10pt"]). text('yellow',128,528,1,0,2,1,1,0,1,28,14,169,0,11,3,0,0,0,[ "12pt"]). text('yellow',128,544,1,0,3,1,1,0,1,36,16,170,0,13,3,0,0,0,[ "14pt"]). text('yellow',128,560,1,0,4,1,1,0,1,44,19,171,0,15,4,0,0,0,[ "18pt"]). text('yellow',128,576,1,0,5,1,1,0,1,60,24,172,0,19,5,0,0,0,[ "24pt"]). text('yellow',256,496,1,0,0,1,1,0,1,24,11,173,1,9,2,0,0,0,[ "11pt"]). text('yellow',256,512,1,0,1,1,1,0,1,36,15,174,1,12,3,0,0,0,[ "14pt"]). text('yellow',256,528,1,0,2,1,1,0,1,40,19,175,1,14,5,0,0,0,[ "17pt"]). text('yellow',256,544,1,0,3,1,1,0,1,44,19,176,1,15,4,0,0,0,[ "20pt"]). text('yellow',256,560,1,0,4,1,1,0,1,60,24,177,1,19,5,0,0,0,[ "25pt"]). text('yellow',256,576,1,0,5,1,1,0,1,80,34,178,1,26,8,0,0,0,[ "34pt"]). text('yellow',336,624,1,0,3,1,0,0,1,180,16,179,0,13,3,0,0,0,[ "100dpi Courier Fonts"]). text('yellow',336,640,1,0,3,1,0,0,1,171,16,180,0,13,3,0,0,0,[ "75dpi Courier Fonts"]). poly('yellow',3,[ 336,632,256,632,256,616],1,1,1,181,0,0,0,0,8,3,[ ]). poly('yellow',3,[ 336,648,128,648,128,608],1,1,1,182,0,0,0,0,8,3,[ ]). ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/rcbox.c������������������������������������������������������������������������������0000644�0000764�0000764�00000107573�11602233312�014262� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/rcbox.c,v 1.12 2011/06/09 16:11:42 cvsps Exp $ */ #define _INCLUDE_FROM_RCBOX_C_ #include "tgifdefs.h" #include "attr.e" #include "auxtext.e" #include "box.e" #include "cmd.e" #include "color.e" #include "choice.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "grid.e" #include "mainloop.e" #include "mark.e" #include "msg.e" #include "obj.e" #include "pattern.e" #include "poly.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "rcbox.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "spline.e" #include "strtbl.e" #include "util.e" #include "xpixmap.e" int rcBoxDrawn=FALSE; static XSegment rcbSegs[4]; static XArc rcbArcs[4]; static int rcbArcsInitialized=FALSE; void SetRCBoxVertex(x1, y1, x2, y2, r) int x1, y1, x2, y2, r; { register int inc_x, inc_y, d=2*r; inc_x = (x2 > x1); inc_y = (y2 > y1); rcbSegs[0].x1 = (inc_x) ? (x1+r) : (x1-r); rcbSegs[0].y1 = y1; rcbSegs[0].x2 = (inc_x) ? (x2-r) : (x2+r); rcbSegs[0].y2 = y1; rcbSegs[1].x1 = x2; rcbSegs[1].y1 = (inc_y) ? (y1+r) : (y1-r); rcbSegs[1].x2 = x2; rcbSegs[1].y2 = (inc_y) ? (y2-r) : (y2+r); rcbSegs[2].x1 = (inc_x) ? (x1+r) : (x1-r); rcbSegs[2].y1 = y2; rcbSegs[2].x2 = (inc_x) ? (x2-r) : (x2+r); rcbSegs[2].y2 = y2; rcbSegs[3].x1 = x1; rcbSegs[3].y1 = (inc_y) ? (y1+r) : (y1-r); rcbSegs[3].x2 = x1; rcbSegs[3].y2 = (inc_y) ? (y2-r) : (y2+r); if (!rcbArcsInitialized) { rcbArcsInitialized = TRUE; rcbArcs[0].angle1 = 90*64; rcbArcs[0].angle2 = 90*64; rcbArcs[1].angle1 = 0; rcbArcs[1].angle2 = 90*64; rcbArcs[2].angle1 = -90*64; rcbArcs[2].angle2 = 90*64; rcbArcs[3].angle1 = -180*64; rcbArcs[3].angle2 = 90*64; } rcbArcs[0].width=rcbArcs[1].width=rcbArcs[2].width=rcbArcs[3].width=d; rcbArcs[0].height=rcbArcs[1].height=rcbArcs[2].height=rcbArcs[3].height=d; if (inc_x) { if (inc_y) { rcbArcs[0].x=x1; rcbArcs[0].y=y1; rcbArcs[1].x=x2-d; rcbArcs[1].y=y1; rcbArcs[2].x=x2-d; rcbArcs[2].y=y2-d; rcbArcs[3].x=x1; rcbArcs[3].y=y2-d; } else { rcbArcs[0].x=x1; rcbArcs[0].y=y2; rcbArcs[1].x=x2-d; rcbArcs[1].y=y2; rcbArcs[2].x=x2-d; rcbArcs[2].y=y1-d; rcbArcs[3].x=x1; rcbArcs[3].y=y1-d; } } else { if (inc_y) { rcbArcs[0].x=x2; rcbArcs[0].y=y1; rcbArcs[1].x=x1-d; rcbArcs[1].y=y1; rcbArcs[2].x=x1-d; rcbArcs[2].y=y2-d; rcbArcs[3].x=x2; rcbArcs[3].y=y2-d; } else { rcbArcs[0].x=x2; rcbArcs[0].y=y2; rcbArcs[1].x=x1-d; rcbArcs[1].y=y2; rcbArcs[2].x=x1-d; rcbArcs[2].y=y1-d; rcbArcs[3].x=x2; rcbArcs[3].y=y1-d; } } } void MyRCBox(window, gc, x1, y1, x2, y2, r) Window window; GC gc; int x1, y1, x2, y2, r; { if (abs(x1-x2) < 2*r || abs(y1-y2) < 2*r) { MyBox(window, gc, x1, y1, x2, y2); } else { XDrawSegments(mainDisplay, window, gc, rcbSegs, 4); XDrawArcs(mainDisplay, window, gc, rcbArcs, 4); } } static void MyFillRCBox(window, gc, x1, y1, x2, y2, r) Window window; GC gc; int x1, y1, x2, y2, r; { if (abs(x1-x2) < 2*r || abs(y1-y2) < 2*r) { XFillRectangle(mainDisplay, window, gc, x1, y1, x2-x1, y2-y1); } else { XFillRectangle(mainDisplay, window, gc, x1+r, y1, x2-x1-2*r, y2-y1); XFillRectangle(mainDisplay, window, gc, x1, y1+r, x2-x1, y2-y1-2*r); XFillArcs(mainDisplay, window, gc, rcbArcs, 4); } } static void DumpRCBoxPSPath(FP, ltx, lty, rbx, rby, r, blank1, blank2) FILE *FP; int ltx, lty, rbx, rby, r; char *blank1, *blank2; { if (abs(ltx-rbx) < 2*r || abs(lty-rby) < 2*r) { fprintf(FP, "%s%s\n%s%1d %1d %s ", blank1, gPsCmd[PS_NEWPATH], blank2, rbx, lty, gPsCmd[PS_MOVETO]); fprintf(FP, "%1d %1d %s ", rbx, rby, gPsCmd[PS_LINETO]); fprintf(FP, "%1d %1d %s ", ltx, rby, gPsCmd[PS_LINETO]); fprintf(FP, "%1d %1d %s\n", ltx, lty, gPsCmd[PS_LINETO]); } else { fprintf(FP, "%s%s\n%s%1d %1d %s\n", blank1, gPsCmd[PS_NEWPATH], blank2, rbx-r, lty, gPsCmd[PS_MOVETO]); fprintf(FP, "%s%1d %1d %1d %1d %1d %s\n", blank2, rbx, lty, rbx, rby, r, gPsCmd[PS_ARCTO4]); fprintf(FP, "%s%1d %1d %s\n", blank2, rbx, rby-r, gPsCmd[PS_LINETO]); fprintf(FP, "%s%1d %1d %1d %1d %1d %s\n", blank2, rbx, rby, ltx, rby, r, gPsCmd[PS_ARCTO4]); fprintf(FP, "%s%1d %1d %s\n", blank2, ltx+r, rby, gPsCmd[PS_LINETO]); fprintf(FP, "%s%1d %1d %1d %1d %1d %s\n", blank2, ltx, rby, ltx, lty, r, gPsCmd[PS_ARCTO4]); fprintf(FP, "%s%1d %1d %s\n", blank2, ltx, lty+r, gPsCmd[PS_LINETO]); fprintf(FP, "%s%1d %1d %1d %1d %1d %s\n", blank2, ltx, lty, rbx, lty, r, gPsCmd[PS_ARCTO4]); } } static void DumpRCBoxPath(FP, ObjPtr, ltx, lty, rbx, rby, r, width, pen, dash, trans_pat) FILE *FP; struct ObjRec *ObjPtr; int ltx, lty, rbx, rby, r, width, pen, dash, trans_pat; { register int i; int w_is_int=TRUE; char *width_spec=ObjPtr->detail.rcb->width_spec; double dw=GetWidthInDouble(width, width_spec, &w_is_int); fprintf(FP, " %s\n", gPsCmd[PS_GSAVE]); if (!colorDump && useGray && pen > BACKPAT) { GrayCheck(pen); fprintf(FP, " %s %s\n", GrayStr(pen), gPsCmd[PS_SETGRAY]); } DumpRCBoxPSPath(FP, ltx, lty, rbx, rby, r, " ", " "); fprintf(FP, " %s\n", gPsCmd[PS_CLOSEPATH]); if (ObjPtr->ctm != NULL) { fprintf(FP, " %s\n", &(gPsCmd[PS_TGIFSETMATRIX])[1]); } if (dash != 0) { fprintf(FP, " ["); for (i=0; i < dashListLength[dash]-1; i++) { fprintf(FP, "%1d ", (int)(dashList[dash][i])); } fprintf(FP, "%1d] 0 %s\n", (int)(dashList[dash][dashListLength[dash]-1]), gPsCmd[PS_SETDASH]); } if (w_is_int) { if (width != 1) { fprintf(FP, " %1d %s\n", width, gPsCmd[PS_SETLINEWIDTH]); } } else { fprintf(FP, " %.3f %s\n", dw, gPsCmd[PS_SETLINEWIDTH]); } switch (pen) { case SOLIDPAT: fprintf(FP, " %s\n", gPsCmd[PS_STROKE]); break; case BACKPAT: fprintf(FP, " 1 %s %s 0 %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_STROKE], gPsCmd[PS_SETGRAY]); break; default: if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); fprintf(FP, " %s\n", gPsCmd[PS_FLATTENPATH]); DumpPatFill(FP, pen, ObjPtr->bbox, 6, TRUE); } else { fprintf(FP, " %s\n", gPsCmd[PS_STROKE]); } break; } fprintf(FP, " %s\n", gPsCmd[PS_GRESTORE]); } void DumpRCBoxObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { register int ltx, lty, rbx, rby; int trans_pat, fill, width, pen, dash, color_index, r; if (ObjPtr->ctm == NULL) { ltx = ObjPtr->obbox.ltx; lty = ObjPtr->obbox.lty; rbx = ObjPtr->obbox.rbx; rby = ObjPtr->obbox.rby; } else { ltx = ObjPtr->orig_obbox.ltx; lty = ObjPtr->orig_obbox.lty; rbx = ObjPtr->orig_obbox.rbx; rby = ObjPtr->orig_obbox.rby; } trans_pat = ObjPtr->trans_pat; fill = ObjPtr->detail.rcb->fill; pen = ObjPtr->detail.rcb->pen; width = ObjPtr->detail.rcb->width; dash = ObjPtr->detail.rcb->dash; r = ObjPtr->detail.rcb->radius; if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } fprintf(FP, "%% RCBOX\n"); if (ObjPtr->ctm != NULL) { float m[6]; fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); m[CTM_SX] = ((float)ObjPtr->ctm->m[CTM_SX])/((float)1000.0); m[CTM_SY] = ((float)ObjPtr->ctm->m[CTM_SY])/((float)1000.0); m[CTM_SIN] = ((float)ObjPtr->ctm->m[CTM_SIN])/((float)1000.0); m[CTM_MSIN] = ((float)ObjPtr->ctm->m[CTM_MSIN])/((float)1000.0); fprintf(FP, " %1d %1d %s\n", ObjPtr->x, ObjPtr->y, gPsCmd[PS_TRANSLATE]); fprintf(FP, " [%.3f %.3f %.3f %.3f %1d %1d] %s\n", m[CTM_SX], m[CTM_SIN], m[CTM_MSIN], m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY], gPsCmd[PS_CONCAT]); fprintf(FP, " %1d %s %1d %s %s\n", ObjPtr->x, gPsCmd[PS_NEG], ObjPtr->y, gPsCmd[PS_NEG], gPsCmd[PS_TRANSLATE]); } color_index = ObjPtr->color; DumpRGBColorLine(FP, color_index, 0, TRUE); switch (fill) { case NONEPAT: break; case SOLIDPAT: DumpRCBoxPSPath(FP, ltx, lty, rbx, rby, r, "", " "); fprintf(FP, "%s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_FILL]); break; case BACKPAT: if (!trans_pat) { DumpRCBoxPSPath(FP, ltx, lty, rbx, rby, r, "", " "); fprintf(FP, "%s 1 %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 3, TRUE); } break; default: fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if (colorDump || !useGray) { if (!trans_pat) { DumpRCBoxPSPath(FP, ltx, lty, rbx, rby, r, " ", " "); fprintf(FP, " %s 1 %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 3, TRUE); } DumpRCBoxPSPath(FP, ltx, lty, rbx, rby, r, " ", " "); if (preDumpSetup) PSUseColorPattern(); fprintf(FP, " %s %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_EOCLIP], gPsCmd[PS_NEWPATH]); DumpPatFill(FP, fill, ObjPtr->bbox, 3, TRUE); } else { GrayCheck(fill); fprintf(FP, " %s %s\n", GrayStr(fill), gPsCmd[PS_SETGRAY]); DumpRCBoxPSPath(FP, ltx, lty, rbx, rby, r, " ", " "); fprintf(FP, " %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_FILL]); } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); break; } if (pen == NONEPAT || (pen == BACKPAT && trans_pat)) { if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); return; } fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if ((colorDump || !useGray) && pen > BACKPAT && !trans_pat) { DumpRCBoxPath(FP, ObjPtr, ltx, lty, rbx, rby, r, width, BACKPAT, 0, trans_pat); DumpRGBColorLine(FP, color_index, 3, TRUE); } DumpRCBoxPath(FP, ObjPtr, ltx, lty, rbx, rby, r, width, pen, dash, trans_pat); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); } int NeedsToCacheRCBoxObj(ObjPtr) struct ObjRec *ObjPtr; { return (ObjPtr->ctm != NULL); } static void MakeCachedRCBox(ObjPtr) struct ObjRec *ObjPtr; { struct RCBoxRec *rcbox_ptr=ObjPtr->detail.rcb; XPoint *sv=NULL; IntPoint *pv; char *smooth=NULL; struct BBRec obbox; int i, w, h, sn; int r=rcbox_ptr->radius, num_vs; if (ObjPtr->ctm == NULL) return; obbox.ltx = ObjPtr->orig_obbox.ltx - ObjPtr->x; obbox.lty = ObjPtr->orig_obbox.lty - ObjPtr->y; obbox.rbx = ObjPtr->orig_obbox.rbx - ObjPtr->x; obbox.rby = ObjPtr->orig_obbox.rby - ObjPtr->y; w = obbox.rbx - obbox.ltx; h = obbox.rby - obbox.lty; num_vs = (w < (r<<1) || h < (r<<1)) ? 5 : 13; if (rcbox_ptr->rotated_vlist != NULL) free(rcbox_ptr->rotated_vlist); rcbox_ptr->rotated_n = 0; rcbox_ptr->rotated_vlist = (XPoint*)malloc((num_vs+1)*sizeof(XPoint)); pv = (IntPoint*)malloc((num_vs+1)*sizeof(IntPoint)); if (rcbox_ptr->rotated_vlist == NULL || pv == NULL) FailAllocMessage(); if (num_vs == 13) { smooth = (char*)malloc((num_vs+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); } if (num_vs == 5) { pv[0].x = obbox.ltx; pv[0].y = obbox.lty; pv[1].x = obbox.rbx; pv[1].y = obbox.lty; pv[2].x = obbox.rbx; pv[2].y = obbox.rby; pv[3].x = obbox.ltx; pv[3].y = obbox.rby; pv[4].x = pv[0].x; pv[4].y = pv[0].y; } else { pv[0].x = obbox.ltx; pv[0].y = obbox.lty; pv[1].x = obbox.ltx+r; pv[1].y = obbox.lty; pv[2].x = obbox.rbx-r; pv[2].y = obbox.lty; pv[3].x = obbox.rbx; pv[3].y = obbox.lty; pv[4].x = obbox.rbx; pv[4].y = obbox.lty+r; pv[5].x = obbox.rbx; pv[5].y = obbox.rby-r; pv[6].x = obbox.rbx; pv[6].y = obbox.rby; pv[7].x = obbox.rbx-r; pv[7].y = obbox.rby; pv[8].x = obbox.ltx+r; pv[8].y = obbox.rby; pv[9].x = obbox.ltx; pv[9].y = obbox.rby; pv[10].x = obbox.ltx; pv[10].y = obbox.rby-r; pv[11].x = obbox.ltx; pv[11].y = obbox.lty+r; pv[12].x = pv[0].x; pv[12].y = pv[0].y; for (i=0; i < num_vs; i++) smooth[i] = FALSE; smooth[0] = smooth[3] = smooth[6] = smooth[9] = smooth[12] = TRUE; } for (i=0; i < num_vs; i++) { int x, y; TransformPointThroughCTM(pv[i].x, pv[i].y, ObjPtr->ctm, &x, &y); pv[i].x = x + ObjPtr->x; pv[i].y = y + ObjPtr->y; rcbox_ptr->rotated_vlist[i].x = (short)OFFSET_X(pv[i].x); rcbox_ptr->rotated_vlist[i].y = (short)OFFSET_Y(pv[i].y); } if (num_vs == 13) { sv = MakeMultiSplinePolygonVertex(LT_SPLINE, &sn, smooth, drawOrigX, drawOrigY, num_vs, pv); if (sv == NULL) FailAllocMessage(); free(rcbox_ptr->rotated_vlist); rcbox_ptr->rotated_n = sn; rcbox_ptr->rotated_vlist = sv; } else { rcbox_ptr->rotated_n = num_vs; } free(pv); if (smooth != NULL) free(smooth); } void DrawRCBoxObj(win, XOff, YOff, ObjPtr) Window win; int XOff, YOff; struct ObjRec *ObjPtr; { struct RCBoxRec *rcbox_ptr=ObjPtr->detail.rcb; int trans_pat, fill, pen, pixel, ltx, lty, rbx, rby, width, dash; int real_x_off, real_y_off, radius; XGCValues values; trans_pat = ObjPtr->trans_pat; pen = rcbox_ptr->pen; fill = rcbox_ptr->fill; width = rcbox_ptr->width; dash = rcbox_ptr->dash; radius = ZOOMED_SIZE(rcbox_ptr->radius); pixel = colorPixels[ObjPtr->color]; if (NeedsToCacheRCBoxObj(ObjPtr) && rcbox_ptr->rotated_vlist==NULL) { MakeCachedRCBox(ObjPtr); } if (userDisableRedraw) return; if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } real_x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); real_y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); ltx = ZOOMED_SIZE(ObjPtr->obbox.ltx - real_x_off); lty = ZOOMED_SIZE(ObjPtr->obbox.lty - real_y_off); rbx = ZOOMED_SIZE(ObjPtr->obbox.rbx - real_x_off); rby = ZOOMED_SIZE(ObjPtr->obbox.rby - real_y_off); SetRCBoxVertex(ltx, lty, rbx, rby, radius); if (fill != NONEPAT) { values.foreground = GetDrawingBgPixel(fill, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[fill]; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple, &values); if (ObjPtr->ctm != NULL) { XFillPolygon(mainDisplay, win, drawGC, rcbox_ptr->rotated_vlist, rcbox_ptr->rotated_n, Convex, CoordModeOrigin); } else { MyFillRCBox(win, drawGC, ltx, lty, rbx, rby, radius); } } if (pen != NONEPAT) { values.foreground = GetDrawingBgPixel(pen, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[pen]; values.line_width = ZOOMED_SIZE(width); #ifdef NO_THIN_LINE if (values.line_width < 1) values.line_width = 1; #else #ifdef THIN_OVAL_AND_ARC if (values.line_width <= 1) values.line_width = 0; #endif #endif if (dash != 0) { XSetDashes(mainDisplay, drawGC, 0, dashList[dash], dashListLength[dash]); values.line_style = LineOnOffDash; } else { values.line_style = LineSolid; } XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | GCLineStyle, &values); if (ObjPtr->ctm != NULL) { XDrawLines(mainDisplay, win, drawGC, rcbox_ptr->rotated_vlist, rcbox_ptr->rotated_n, CoordModeOrigin); } else { MyRCBox(win, drawGC, ltx, lty, rbx, rby, radius); } } } void CreateRCBoxObj(X1, Y1, X2, Y2, CreateAbsolute) int X1, Y1, X2, Y2, CreateAbsolute; { struct RCBoxRec *rcbox_ptr; struct ObjRec *obj_ptr; int width, w, ltx, lty, rbx, rby; rcbox_ptr = (struct RCBoxRec *)malloc(sizeof(struct RCBoxRec)); if (rcbox_ptr == NULL) FailAllocMessage(); memset(rcbox_ptr, 0, sizeof(struct RCBoxRec)); rcbox_ptr->fill = objFill; rcbox_ptr->width = width = curWidthOfLine[lineWidth]; UtilStrCpyN(rcbox_ptr->width_spec, sizeof(rcbox_ptr->width_spec), curWidthOfLineSpec[lineWidth]); rcbox_ptr->pen = penPat; rcbox_ptr->dash = curDash; rcbox_ptr->radius = rcbRadius; rcbox_ptr->rotated_n = 0; rcbox_ptr->rotated_vlist = NULL; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); if (X1 < X2) { if (Y1 < Y2) { ltx = X1; lty = Y1; rbx = X2; rby = Y2; } else { ltx = X1; lty = Y2; rbx = X2; rby = Y1; } } else { if (Y1 < Y2) { ltx = X2; lty = Y1; rbx = X1; rby = Y2; } else { ltx = X2; lty = Y2; rbx = X1; rby = Y1; } } if (CreateAbsolute) { obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = ltx; obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = lty; obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = rbx; obj_ptr->bbox.rby = obj_ptr->obbox.rby = rby; } else { obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = ABS_X(ltx); obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = ABS_Y(lty); obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = ABS_X(rbx); obj_ptr->bbox.rby = obj_ptr->obbox.rby = ABS_Y(rby); } w = HALF_W(width); obj_ptr->bbox.ltx -= w; obj_ptr->bbox.lty -= w; obj_ptr->bbox.rbx += w; obj_ptr->bbox.rby += w; obj_ptr->type = OBJ_RCBOX; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->id = objId++; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->locked = FALSE; obj_ptr->detail.rcb = rcbox_ptr; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; obj_ptr->invisible = FALSE; obj_ptr->trans_pat = transPat; AddObj(NULL, topObj, obj_ptr); } static void ContinueRCBox(OrigX, OrigY) int OrigX, OrigY; { int end_x, end_y, grid_x, grid_y, saved_x, saved_y; int done=FALSE, abort=FALSE; int radius=ZOOMED_SIZE(rcbRadius); char buf[80], w_buf[80], h_buf[80], x_buf[80], y_buf[80]; XEvent input, ev; XMotionEvent *motion_ev; SetXorDrawGC(xorColorPixels[colorIndex]); saved_x = grid_x = OrigX; saved_y = grid_y = OrigY; PixelToMeasurementUnit(w_buf, 0); PixelToMeasurementUnit(h_buf, 0); PixelToMeasurementUnit(x_buf, ABS_X(grid_x)); PixelToMeasurementUnit(y_buf, ABS_Y(grid_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); StartShowMeasureCursor(grid_x, grid_y, buf, TRUE); BeginIntervalRulers(grid_x, grid_y, grid_x, grid_y); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } SetRCBoxVertex(OrigX, OrigY, saved_x, saved_y, radius); while (!done) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); SetXorDrawGC(xorColorPixels[colorIndex]); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); MyRCBox(drawWindow,drawGC,OrigX,OrigY,saved_x,saved_y,radius); EndIntervalRulers(grid_x, grid_y); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(saved_x-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(saved_y-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(saved_x)); PixelToMeasurementUnit(y_buf, ABS_Y(saved_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); EndShowMeasureCursor(saved_x, saved_y, buf, TRUE); done = TRUE; } else if (input.type == MotionNotify) { motion_ev = &(input.xmotion); end_x = motion_ev->x; end_y = motion_ev->y; GridXY(end_x, end_y, &grid_x, &grid_y); if (motion_ev->state & (ShiftMask | ControlMask)) { int w, h, pos_w=TRUE, pos_h=TRUE; w = grid_x - OrigX; h = grid_y - OrigY; if (w < 0) { w = (-w); pos_w = FALSE; } if (h < 0) { h = (-h); pos_h = FALSE; } if (w > h) { grid_x = (pos_w ? (OrigX+h) : (OrigX-h)); } else { grid_y = (pos_h ? (OrigY+w) : (OrigY-w)); } } if (grid_x != saved_x || grid_y != saved_y) { PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(saved_x-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(saved_y-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(saved_x)); PixelToMeasurementUnit(y_buf, ABS_Y(saved_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); ShowMeasureCursor(saved_x, saved_y, buf, TRUE); MyRCBox(drawWindow,drawGC,OrigX,OrigY,saved_x,saved_y,radius); saved_x = grid_x; saved_y = grid_y; SetRCBoxVertex(OrigX, OrigY, saved_x, saved_y, radius); MyRCBox(drawWindow,drawGC,OrigX,OrigY,saved_x,saved_y,radius); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(saved_x-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(saved_y-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(saved_x)); PixelToMeasurementUnit(y_buf, ABS_Y(saved_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); ShowMeasureCursor(saved_x, saved_y, buf, TRUE); } DrawIntervalRulers(OrigX, OrigY, grid_x, grid_y, NULL); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { XUngrabPointer(mainDisplay, CurrentTime); MyRCBox(drawWindow,drawGC,OrigX,OrigY,saved_x,saved_y,radius); EndIntervalRulers(grid_x, grid_y); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(saved_x-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(saved_y-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(saved_x)); PixelToMeasurementUnit(y_buf, ABS_Y(saved_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); EndShowMeasureCursor(saved_x, saved_y, buf, TRUE); abort = TRUE; done = TRUE; } } } if (!abort && OrigX != grid_x && OrigY != grid_y) { CreateRCBoxObj(OrigX, OrigY, grid_x, grid_y, FALSE); RecordNewObjCmd(); DrawRCBoxObj(drawWindow, drawOrigX, drawOrigY, topObj); rcBoxDrawn = TRUE; SetFileModified(TRUE); } XSync(mainDisplay, False); } void DrawRCBox(input) XEvent *input; { XButtonEvent *button_ev; int mouse_x, mouse_y, grid_x, grid_y; if (input->type != ButtonPress) return; button_ev = &(input->xbutton); if (button_ev->button == Button1) { mouse_x = button_ev->x; mouse_y = button_ev->y; GridXY(mouse_x, mouse_y, &grid_x, &grid_y); ContinueRCBox(grid_x, grid_y); } } void MakeRCBoxObjFromBoundingBox() { if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (curChoice == VERTEXMODE) SetCurChoice(NOTHING); HighLightReverse(); CreateRCBoxObj(selObjLtX, selObjLtY, selObjRbX, selObjRbY, TRUE); SelectTopObj(); RecordNewObjCmd(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); justDupped = FALSE; SetFileModified(TRUE); } void SaveRCBoxObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { struct RCBoxRec *rcbox_ptr=ObjPtr->detail.rcb; if (fprintf(FP, "rcbox('%s','',", colorMenuItems[ObjPtr->color]) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,'%s',%1d,", ObjPtr->obbox.ltx, ObjPtr->obbox.lty, ObjPtr->obbox.rbx, ObjPtr->obbox.rby, rcbox_ptr->fill, rcbox_ptr->width, rcbox_ptr->pen, rcbox_ptr->dash, rcbox_ptr->radius, ObjPtr->id, ObjPtr->rotation, ObjPtr->locked, ObjPtr->ctm!=NULL, ObjPtr->invisible, rcbox_ptr->width_spec, ObjPtr->trans_pat) == EOF) { writeFileFailed = TRUE; } if (ObjPtr->ctm != NULL && fprintf(FP, "[\n %1d,%1d,%1d,%1d,%1d,%1d,%g,%g,%g,%g,%1d,%1d],", ObjPtr->x, ObjPtr->y, ObjPtr->orig_obbox.ltx, ObjPtr->orig_obbox.lty, ObjPtr->orig_obbox.rbx, ObjPtr->orig_obbox.rby, ObjPtr->ctm->m[CTM_SX], ObjPtr->ctm->m[CTM_SIN], ObjPtr->ctm->m[CTM_MSIN], ObjPtr->ctm->m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY]) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, " "); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } void ReadRCBoxObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { struct RCBoxRec *rcbox_ptr; char color_str[40], bg_color_str[40], *s, msg[MAXSTRING], width_spec[40]; int ltx, lty, rbx, rby, trans_pat=FALSE, fill, width, pen, dash, radius; int rotation, new_alloc, id=0, w, locked=FALSE; int transformed=FALSE, invisible=FALSE; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_str, sizeof(color_str)); if (fileVersion >= 37) { s = ParseStr(s, (int)',', bg_color_str, sizeof(bg_color_str)); } InitScan(s, ", \t\n"); rotation = 0; *width_spec = '\0'; if (fileVersion <= 8) { sprintf(msg, TgLoadCachedString(CSTID_FILEVER_TOO_LARGE_FOR_RCBOX), fileVersion); if (PRTGIF) { fprintf(stderr, "%s\n", msg); } else { Msg(msg); } return; } else if (fileVersion <= 13) { if (GETINT("rcbox", ltx, "ltx") == INVALID || GETINT("rcbox", lty, "lty") == INVALID || GETINT("rcbox", rbx, "rbx") == INVALID || GETINT("rcbox", rby, "rby") == INVALID || GETINT("rcbox", fill, "fill") == INVALID || GETINT("rcbox", width, "width") == INVALID || GETINT("rcbox", pen, "pen") == INVALID || GETINT("rcbox", dash, "dash") == INVALID || GETINT("rcbox", radius, "radius") == INVALID || GETINT("rcbox", id, "id") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 25) { if (GETINT("rcbox", ltx, "ltx") == INVALID || GETINT("rcbox", lty, "lty") == INVALID || GETINT("rcbox", rbx, "rbx") == INVALID || GETINT("rcbox", rby, "rby") == INVALID || GETINT("rcbox", fill, "fill") == INVALID || GETINT("rcbox", width, "width") == INVALID || GETINT("rcbox", pen, "pen") == INVALID || GETINT("rcbox", dash, "dash") == INVALID || GETINT("rcbox", radius, "radius") == INVALID || GETINT("rcbox", id, "id") == INVALID || GETINT("rcbox", rotation, "rotation") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 32) { if (GETINT("rcbox", ltx, "ltx") == INVALID || GETINT("rcbox", lty, "lty") == INVALID || GETINT("rcbox", rbx, "rbx") == INVALID || GETINT("rcbox", rby, "rby") == INVALID || GETINT("rcbox", fill, "fill") == INVALID || GETINT("rcbox", width, "width") == INVALID || GETINT("rcbox", pen, "pen") == INVALID || GETINT("rcbox", dash, "dash") == INVALID || GETINT("rcbox", radius, "radius") == INVALID || GETINT("rcbox", id, "id") == INVALID || GETINT("rcbox", rotation, "rotation") == INVALID || GETINT("rcbox", locked, "locked") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 34) { if (GETINT("rcbox", ltx, "ltx") == INVALID || GETINT("rcbox", lty, "lty") == INVALID || GETINT("rcbox", rbx, "rbx") == INVALID || GETINT("rcbox", rby, "rby") == INVALID || GETINT("rcbox", fill, "fill") == INVALID || GETINT("rcbox", width, "width") == INVALID || GETINT("rcbox", pen, "pen") == INVALID || GETINT("rcbox", dash, "dash") == INVALID || GETINT("rcbox", radius, "radius") == INVALID || GETINT("rcbox", id, "id") == INVALID || GETINT("rcbox", rotation, "rotation") == INVALID || GETINT("rcbox", locked, "locked") == INVALID || GETINT("rcbox", transformed, "transformed") == INVALID || GETINT("rcbox", invisible, "invisible") == INVALID || GETSTR("rcbox", width_spec, "width_spec") == INVALID) { return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); } else { if (GETINT("rcbox", ltx, "ltx") == INVALID || GETINT("rcbox", lty, "lty") == INVALID || GETINT("rcbox", rbx, "rbx") == INVALID || GETINT("rcbox", rby, "rby") == INVALID || GETINT("rcbox", fill, "fill") == INVALID || GETINT("rcbox", width, "width") == INVALID || GETINT("rcbox", pen, "pen") == INVALID || GETINT("rcbox", dash, "dash") == INVALID || GETINT("rcbox", radius, "radius") == INVALID || GETINT("rcbox", id, "id") == INVALID || GETINT("rcbox", rotation, "rotation") == INVALID || GETINT("rcbox", locked, "locked") == INVALID || GETINT("rcbox", transformed, "transformed") == INVALID || GETINT("rcbox", invisible, "invisible") == INVALID || GETSTR("rcbox", width_spec, "width_spec") == INVALID || GETINT("rcbox", trans_pat, "trans_pat") == INVALID) { return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); } if (ltx > rbx || lty > rby) { int tmp_ltx, tmp_lty, tmp_rbx, tmp_rby; if (!PRTGIF) Msg(TgLoadCachedString(CSTID_BAD_RCBOX_BBOX_ADJUSTED)); CalcBBox(ltx, lty, rbx, rby, &tmp_ltx, &tmp_lty, &tmp_rbx, &tmp_rby); ltx = tmp_ltx; lty = tmp_lty; rbx = tmp_rbx; rby = tmp_rby; } if (fileVersion <= 16 && width <= 6) width = origWidthOfLine[width]; if (fileVersion <= 32) { sprintf(width_spec, "%1d", width); } fill = UpgradePenFill(fill); pen = UpgradePenFill(pen); *ObjPtr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (*ObjPtr == NULL) FailAllocMessage(); memset(*ObjPtr, 0, sizeof(struct ObjRec)); rcbox_ptr = (struct RCBoxRec *)malloc(sizeof(struct RCBoxRec)); if (rcbox_ptr == NULL) FailAllocMessage(); memset(rcbox_ptr, 0, sizeof(struct RCBoxRec)); rcbox_ptr->fill = fill; rcbox_ptr->width = width; UtilStrCpyN(rcbox_ptr->width_spec, sizeof(rcbox_ptr->width_spec), width_spec); rcbox_ptr->pen = pen; rcbox_ptr->dash = dash; rcbox_ptr->radius = radius; rcbox_ptr->rotated_n = 0; rcbox_ptr->rotated_vlist = NULL; (*ObjPtr)->x = ltx; (*ObjPtr)->y = lty; (*ObjPtr)->color = QuickFindColorIndex(*ObjPtr, color_str, &new_alloc, TRUE); UtilStrCpyN((*ObjPtr)->color_str, sizeof((*ObjPtr)->color_str), color_str); (*ObjPtr)->dirty = FALSE; (*ObjPtr)->id = id; (*ObjPtr)->rotation = rotation; (*ObjPtr)->locked = locked; (*ObjPtr)->type = OBJ_RCBOX; (*ObjPtr)->obbox.ltx = ltx; (*ObjPtr)->obbox.lty = lty; (*ObjPtr)->obbox.rbx = rbx; (*ObjPtr)->obbox.rby = rby; w = HALF_W(width); (*ObjPtr)->bbox.ltx = ltx - w; (*ObjPtr)->bbox.lty = lty - w; (*ObjPtr)->bbox.rbx = rbx + w; (*ObjPtr)->bbox.rby = rby + w; (*ObjPtr)->detail.rcb = rcbox_ptr; (*ObjPtr)->ctm = NULL; (*ObjPtr)->invisible = invisible; (*ObjPtr)->trans_pat = trans_pat; if (fileVersion >= 33 && transformed) { int real_x=0, real_y=0; struct BBRec orig_obbox; char inbuf[MAXSTRING+1]; struct XfrmMtrxRec *ctm; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, "); ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ctm == NULL) FailAllocMessage(); if (GETINT("rcbox", real_x, "real_x") == INVALID || GETINT("rcbox", real_y, "real_y") == INVALID || GETINT("rcbox", orig_obbox.ltx, "orig_obbox.ltx") == INVALID || GETINT("rcbox", orig_obbox.lty, "orig_obbox.lty") == INVALID || GETINT("rcbox", orig_obbox.rbx, "orig_obbox.rbx") == INVALID || GETINT("rcbox", orig_obbox.rby, "orig_obbox.rby") == INVALID || GETDBL("rcbox", ctm->m[CTM_SX], "CTM_SX") == INVALID || GETDBL("rcbox", ctm->m[CTM_SIN], "CTM_SIN") == INVALID || GETDBL("rcbox", ctm->m[CTM_MSIN], "CTM_MSIN") == INVALID || GETDBL("rcbox", ctm->m[CTM_SY], "CTM_SY") == INVALID || GETINT("rcbox", ctm->t[CTM_TX], "CTM_TX") == INVALID || GETINT("rcbox", ctm->t[CTM_TY], "CTM_TY") == INVALID) { return; } (*ObjPtr)->ctm = ctm; if (ctm != NULL) { memcpy(&(*ObjPtr)->orig_obbox, &orig_obbox, sizeof(struct BBRec)); (*ObjPtr)->x = real_x; (*ObjPtr)->y = real_y; GetTransformedOBBoxOffsetVs(*ObjPtr, (*ObjPtr)->rotated_obbox); } } } void SetRCBoxPropMask(ObjPtr, plMask, plSkip, pProp) struct ObjRec *ObjPtr; long *plMask, *plSkip; struct PropertiesRec *pProp; { struct RCBoxRec *rcbox_ptr=ObjPtr->detail.rcb; SetCTMPropertyMask(ObjPtr->ctm, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_COLOR, ObjPtr->color, colorMenuItems[ObjPtr->color], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_WIDTH, rcbox_ptr->width, rcbox_ptr->width_spec, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TRANSPAT, ObjPtr->trans_pat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_FILL, rcbox_ptr->fill, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_PEN, rcbox_ptr->pen, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_DASH, rcbox_ptr->dash, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_RCB_RADIUS, rcbox_ptr->radius, NULL, plMask, plSkip, pProp); } void FreeRCBoxObj(ObjPtr) struct ObjRec *ObjPtr; { if (ObjPtr->detail.rcb->rotated_vlist != NULL) { free(ObjPtr->detail.rcb->rotated_vlist); } free(ObjPtr->detail.rcb); free(ObjPtr); } �������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/autoscan.log�������������������������������������������������������������������������0000644�0000764�0000764�00000000000�11602233316�015276� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgtwb5xl.c���������������������������������������������������������������������������0000644�0000764�0000764�00000401663�11602233313�014723� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgtwb5xl.c,v 1.12 2011/05/22 23:44:01 william Exp $ */ #ifndef _NO_TGTWB5 #define _INCLUDE_FROM_TGTWB5XL_C_ #include "tgifdefs.h" #include "tgtwb5xl.e" char *firstLargeTransTbl[] = { "5", "", "Punctuations", "Symbols", "1", "2", "3", "4", "Er", "", "", "", "An", "En", "Ang", "Eng", "Ai", "Ei", "Ao", "Ou", "A", "O", "E", "Eh", "Y", "W", "Yu", "", "Z", "C", "S", "", "Zh", "Ch", "Sh", "R", "J", "Q", "X", "", "G", "K", "H", "", "D", "T", "N", "L", "B", "P", "M", "F", }; char *secondLargeTransTbl[] = { "5", "", "", "", "1", "2", "3", "4", "", "", "", "", "an", "en", "ang", "eng", "ai", "ei", "ao", "ou", "a", "o", "e", "e", "i", "u", "u", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", }; char *thirdLargeTransTbl[] = { "5", "", "", "", "1", "2", "3", "4", "", "", "", "", "an", "n", "ang", "ng", "ai", "i", "ao", "u", "a", "o", "", "e", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", }; char *fourthLargeTransTbl[] = { "5", "", "", "", "1", "2", "3", "4", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", }; char *singleExtention[] = { "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "i", "u", "", "", "i", "i", "i", "", "i", "i", "i", "i", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", }; char *pinyin_et_big5[] = { "A1", "aafca3ab", "A2", "b0daaafc", "A4", "aafc", "Ai1", "aec1ab73ae4aadfcab75a3afe44d", "Ai2", "b1babd4aef63e1f4", "Ai3", "b847c4a7c647d5d9cb48cef7ca64", "Ai4", "b752c3aaa6e3c0c7c0f5b969bebcc940f957e4edd8a5e954f669eeb8ed54ef7cf4cfe44dee49", "An1", "a677be62b167bfdaaef2bbcfa3b3c44fd8c0cbc8ea75cea6decadf72dfd6f54cce50", "An2", "e0d8cfcdd875", "An3", "adcdd47bd9a3d87e", "An4", "b774aed7a9a4abf6c566b5daeeeeca43d3e0cbd8d1dbcf7dd3b0ebfed0eed4e9e8f8", "Ang1", "bbeab5cba3b5", "Ang2", "a9f9c957", "Ang3", "dc42", "Ang4", "af73eecc", "Ao1", "a557a3b1cbfccf62", "Ao2", "bcf5b1cebe43bfacb9c8ee67f7b4c652c3eff67de1bce676e6a9c16df36ce2b0eaa2e4bbe5ade757f06af0e6f26a", "Ao3", "c3cdb6fecdbdd844", "Ao4", "b6c6bf44b6f8bed2e94dd8b4caf3e9aedbe4e96a", "B1", "a374", "Ba1", "a44baec3a4daaccdaaddafb9d34aa57aa5b6d7d0a761c954c9f6", "Ba2", "a9deb65bb959e8d9d06ef1e4dbfdc9a5db6ed05adbd9", "Ba3", "a7e2b976dc6a", "Ba4", "bd7daaa8c551c5f2afd2cad3c5f4a742d666", "Ba5", "a761bd7db55daa49", "Bai1", "d954", "Bai2", "a5d5", "Bai3", "a6cac25ca8d5c4fcdae9d579f478daf7", "Bai4", "b1d1abf4d0f9e361d9c1f478cad1", "Ban1", "af5aafebb768b4b3b97ba7e6bd49ee57ddbdccc1eb78", "Ban3", "aa4faaa9c1f3a8c1afeaccc6b67ad349e3ed", "Ban4", "a562bfeca6f1a7eaa9d5b2cca972c3a4c962ccadd5e4e0c1e4bf", "Bang1", "c0b0a8b9b3c4b1f5f17deadbd157", "Bang3", "ba5db86ae2c6bb48e9e8", "Bang4", "b4cebd53c1bdb046b3c4c2e9aec7ed72dcebeaf5", "Bao1", "a55dad4dad63bdc7cf52d6ddeb55cc55", "Bao2", "b972d2fccd6e", "Bao3", "ab4fc45fb9a1b3f9bdc8b8b6e8e9ccafe4d7e4e4d8bf", "Bao4", "b3f8a9eabcc9c37ab05cc06aa753d3e5b95eeb58c5e1ecbcdbadde73d7c2efbcf26ff449", "Bei1", "ad49aa4db464a8f5b84faddab4aed453acd7bb74db7cd5b5d9c1c9b8e373f3edf2d3", "Bei3", "a55f", "Bei4", "b351b3c6ad49a8a9bdfaadbfc175af56beceaeafa7b8b548bb5fe7c8aaf5daaae44fbe58d0feeac7d5cbd674dc58cfbad3f8e2c8efc0", "Ben1", "a962b64eebe6cd49d5eb", "Ben3", "a5bbaf63ad66", "Ben4", "b2c2ca5ecaac", "Beng1", "b159c15eca5bd54dcff4dc79e15ddaed", "Beng2", "acc7", "Beng3", "db66cd66da7dd4bee04f", "Beng4", "c2dbdd7bcf6eb06ee067", "Bi1", "b947cc59d44de344e7e6", "Bi2", "bbf3", "Bi3", "a4f1b5a7a9bcbbc0a450a85dcff9cc59d3bca7adcb70e65fcf44c9f5e7e7", "Bi4", "a5b2b1cdb2a6bec0c1d7c27ab3acbbc0c175b9f4b9fab141c0c5bad1aa63addabdaaa7c8b9cdb470b940b45dbb74b0a1b0f1bae8bf7bcd71a4f1e958b844b64ef653c3cecf68e76ec2def1b9cc7ad54bd941ddd0d9f0d2a5e675edc3d06cc1a3eb7db647f4d9cdd3e0cdcefcd5b2cfc7b7f4e0e2e4d1e8c6f15df7c0dab7d8aab963decddf74e8d2caafe27de667cfddcc4cf372f7c6cf47ca5adfe5e1bfe358e3c9e857eae1ec74ee76f1d6f4caf67af97ecdb6d34bdefbe173e67ee971f14aedd6", "Bian1", "c3e4bd73c340bdbfafa2f8fbe6dbe348da78e2d6cf5fdde4de74", "Bian3", "abf3b653b0d0bdcad2f6dfcfd947e2f3", "Bian4", "ab4bc5dcb94dbfebc547a858c47ccad9a5afa8bccae7e6ece74ba4cbd971cb5aecaae0cf", "Biao1", "bcd0b343c5dfc3f0f674bda8e664e8f0f2bce149a840e2a4efecda6eea6cf4a2e4cdf9cde1e1ecb9f2c2dcadd449f0eae164f348e75bf26cf2cb", "Biao3", "aaedbff6b144e3f7d0cfee74ed46e7e0", "Biao4", "c5c0", "Bie1", "e578c5bef9bd", "Bie2", "a74ff144cbdbe1c1ee76ee6f", "Bie3", "c3a7d7a1", "Bie4", "b9fbedd6", "Bin1", "bbabc0d8b16cc262beaad979c47dc1c7c378cbacf040f4c4f767e452c9a2d9d7f37ef279f8d3", "Bin4", "c26cc64bbeaaece8c2c1f8d4f5ab", "Bing1", "a74ca642d57cd1d9", "Bing3", "bbe6a4feb85bac60aac3acb1cef4cdd4cc7def40bbd0d7aecddcd07ed2f7abccceb5", "Bing4", "a8c3af66a8d6a67db4acd8d6ef78d452", "Bo1", "acc1bcb7ade9b5d4b2dae567d2dcdeebd7b7f0d4f85bd471cf59f351cc69", "Bo2", "a742b3d5ac66aa79ab6bb769b4f1bbe9c1a1b2e4a9adb2edbae4b2f2bdb3bb4bb959e8c1b960f5cef1d0e7f4d24af64ae463f157ec61e0fbf1aef566d5c5eeacc0d0ec60d063d1b4deaadfb4e877efccf063f2a1f952d3f6f97bf2ae", "Bo3", "b65fc3b0d7b0", "Bo4", "bcbdc0bcc3b0adbdc1a3f342c1a1c0d0c4f4f2b7cee0", "Bu1", "d7e3d5aae8c2d16cf1d1", "Bu2", "a4a3", "Bu3", "b8c9aeb7ae48adf7a452e0ebe67b", "Bu4", "a4a3b3a1a5aca842a9c6a747c3afb0f0b95ae74fedcbd1cacbec", "C1", "a3a9", "Ca1", "c0bfb767ecc0", "Ca3", "f47d", "Ca4", "f5c4", "Cai1", "b271", "Cai2", "a47eb05da7f7b5f4c5d7", "Cai3", "b1c4b16daaf6b842bdf2baf9e073d4f2d9bdd4ea", "Cai4", "bdb2b5e6d4caaaf6edda", "Can1", "b0d1c05cf67c", "Can2", "b4ddc5faba46e95b", "Can3", "ba47e5a3d9a9e4fdf876", "Can4", "c0e9b447c0f6df54ea44", "Cang1", "bb61addcb7c9bfb5b3c9f6c1d861dd56", "Cang2", "c2c3f974", "Cao1", "bedec157ebd6dcd5", "Cao2", "b1e4bcd1b9cbbaa8ee5dedf1e1a6", "Cao3", "aff3e97bf55aca4a", "Cao4", "c157bedecdabf2f1", "Ce4", "a555b5a6b4fab0bcb45ab46cdf49d2c2d37cd6e1cee3dee3e5a8e3d1", "Cen1", "b0d1e1add5b7", "Cen2", "a7c2af4bd5bad348d158", "Ceng1", "e4f8", "Ceng2", "b4bfbc68e565e855def0", "Ceng4", "f34f", "Ch1", "a3a5", "Cha1", "ae74b4a1a465b3e5eaf6dcd8c9eacb43d458ea6af160", "Cha2", "ac64b9eeaff9b767e241eed0e2edd068ce51cda4", "Cha3", "ebc1", "Cha4", "b8d2a7c3ab62ae74c9fcd0aee3dccbb2c9cdd04c", "Chai1", "a9eeb3a6ae74d85b", "Chai2", "aee3b05bbeabd6c2dcd7", "Chai4", "f2e3d3d9f6d7", "Chan1", "c465d9c0f2eecba6e87ed8f8e956f5d0", "Chan2", "c4f1c2cdc149c661c5febcebc3cac460bc60b3e6bf47e573b447f1edc0d5efedf464f75ef955eaa8f7efe0f7d9cdda52ebeede78e2ccf2b0f440f4e2", "Chan3", "b2a3c3eac4c4b6d0eb41e543f6d8cbb1e1aeea4cbdd4f77ce56ff073e273edbaf7e4cafcf341", "Chan4", "c462c4f3c35f", "Chang1", "a9f7add2b273b140ec4bdb75c449adcef6d0ebf9d640daa8e3fb", "Chang2", "aaf8b160b3f5b9c1bb6ec076b87ab9dff95ab175c07cb5e7ebf8e35e", "Chang3", "b3f5bc74b4afbefbceebebf3", "Chang4", "b0dbadd2ba5ab1a3d44aef43", "Chao1", "a7dbb672b657b6d3cc70cca2d7cbb6cfeae2", "Chao2", "b4c2bce9b15fbc4aaed0e5dcf148e471", "Chao3", "a76eaaa3d2d8", "Chao4", "d366", "Che1", "a8aedacfd773", "Che3", "a7e8e1e4f7d4", "Che4", "b9fdbaabc2e1ba4db477a95cc94bd0b6dace", "Chen1", "dcd2b560bd51d7ebe7edd9c7eeafe7e1dda7d4ae", "Chen2", "b3afa849b1e1a6dab9d0a8b0ae57a7d5ae66bfdbde70d3b2e77de5e7d759d942dc71ee6af1def7bcc9afe5bd", "Chen3", "d577eaa7eed1dff1e15eebbff0f5", "Chen4", "b658bad9c5a8c468c640accfefb5f1f0f4c3efb8", "Cheng1", "bad9bcb5bf65f2ded457ecf7ebb9daa5e9daf4fed261d4bfd9d1da67edb8d4f6f559", "Cheng2", "a6a8b57ba9d3b2b1adbcb8dba765abb0c367bce1beeda5e0e64ad9b3e473d168d1d4dff4d0bad14cd5a3d9fed66dd775f55dd36fd749d957ceaee4a8dce6", "Cheng3", "b378c1fed1add547dcf0", "Cheng4", "bad9afafd457da67", "Chi1", "a659b045c3a8b7f6b6e1b3f0a3a5d3fbc55eb2c7df5decaedcf7e1dbdaabee5ad6b2f5bdd6c3dbe9e7e2ea77f96af875f7c7", "Chi2", "abf9a6c0bff0b9a3b0cda6a2bc55cbfbbdf3e357d3b3d7a8eac1d3ced07ad2c6cae1cb59d3a2aeebd1fad741dbe9e062e34ee577eea1d8f6", "Chi3", "a4d8bea6aea2a760a8d7bfc9d9ddddb6d3bfcecacedece6ad85ee04ee4a4c9adf57b", "Chi4", "a8aaafcda5b8b6bda577bf4bb3d7dcbfb1d5d2d5ccb8f555d1dee853c94ce06be460f7c2d44be6b7e0c9d0f4d5eadeceefc7dd72e5ae", "Chong1", "a552bdc4a852b2eacaddbca5cfcfd072d245f0fbcff5", "Chong2", "adabb152a6e4c2cecffad365e7c0dca3d3b5d6a1", "Chong3", "c364", "Chong4", "bdc4e0b6d96f", "Chou1", "a9e2ea6fddb1eac5f46cd4db", "Chou2", "b754a4b3c477baf7b953b859d6e8c543c3a5b1a8bb76bea9f841ecdbc357f0aaecd4d9d4daf6dbacece5e045ec50effdd1ee", "Chou3", "a4a1c1e0e2e4ccd8cce4ca7cd770", "Chou4", "afe4edc5b7cde268e57b", "Chu1", "a558aaecc4d5f0f0", "Chu2", "b0a3c078bc70be53c36fc2faafecc3dcde51f75deabedf71dfefe0bce3c1b8f9f6bdefc6f0f0e060e2c9", "Chu3", "b342b7a1c078c2a6aa53bb75b4d8e9eaed47", "Chu4", "b342c4b2af62b2d2c5f7c24ad0d4a9c5dd7ac0d3dbdce0a4ecf0c948cdcbcd4ddaa2e462de47e4f1edecd1cd", "Chua1", "d9db", "Chuai2", "e744", "Chuai3", "b4a2", "Chuai4", "bfe5e544", "Chuan1", "acefa474f4fbcb4adeb8", "Chuan2", "b6c7b2eee0a1dddcddf8ebafe5c7ebcc", "Chuan3", "b3dda6dfd3b6", "Chuan4", "a6eab3a9cb6bca40e455", "Chuang1", "b5a1b3d0bd48a777e579e1d7e1ec", "Chuang2", "a7c9bc6cbcb2e9bf", "Chuang3", "c2f4b76de2b4", "Chuang4", "b3d0c2f4b75bcbd4deaf", "Chui1", "a76aaaa4", "Chui2", "ababc2f1ba6cddb4b4d5b6abc1e8b4a8dddebd69d87cda50d45bdfc8bd78d8c2dfa1e2d5", "Chui4", "a76aaaa4ebaa", "Chun1", "ac4bddcfccd7ebcfda59f573d8c7ddc5f5aa", "Chun2", "afc2ae42be4ab245e75dc44ce27aebdeb2e5e9a3f3d3", "Chun3", "c4f8dd65ebbdd462dfd8", "Chuo1", "c257", "Chuo4", "baefbdf9c5c6d8bdb0e3d55bf259e85dd4d8dec5dc4ed15cca77d675eaabdb4de7efe9a8f5c5", "Ci1", "b2abceb8bbdba3a9ae74dbeeec6c", "Ci2", "b5fcc3e3b74fbacfb2a1bbdbafa8b2abaffddae7e8bfcf5ae959ed5bce4de8c0edf9", "Ci3", "a6b9cbbdcf75d2afe06cd6a6", "Ci4", "a6b8a8ebbde7b45aa6f8cbb5dbb4db6cc9f4d1efd3ccdaeb", "Cong1", "a55ec16fb171a777e6a6e6a7bcd7f67be776f36be670d9d9e5c4bdb5ea7aee65eed8", "Cong2", "b171c24fb246da7ad555e2a6e2ace7ebebefd4ddd4f0d54fe1c8", "Cong4", "f6e6f0a8f0e5", "Cou4", "b4eabfeadf73ddce", "Cu1", "b2caf9d2d7c8", "Cu2", "cf65cc75", "Cu4", "ab50be4cc14cc3e0e754c2d9d660a8f2bff9bdecc1cdc3ebea6be7febcd8d5c7e4f6df42e9e1f1e2", "Cuan1", "f5cdf94fe87d", "Cuan2", "f6e3f6def5c3", "Cuan4", "c2abbf79c679eabf", "Cui1", "ba52b6cab15ae151e167eaa5f369e1fcb049", "Cui2", "dcc5e1d0", "Cui3", "bd41e7f1e2a8", "Cui4", "bb41afdcbae9b17cb7f1b5d1d475b266d0c9d9e5bef5da58edb9eaefe363eaecdb51ed5a", "Cun1", "a7f8b572", "Cun2", "a673dbc6", "Cun3", "a6a4c96b", "Cun4", "a46fa654d047", "Cuo1", "b762bcbcbd52c1cee3b5e84ff565", "Cuo2", "e6afdac4f6c9dab5eecbb744e768", "Cuo3", "e2cfd74ceaccdacd", "Cuo4", "bff9b1b9aec0be56bcbccdf1adedd76bcde8d0e8f8a2e3c4", "D1", "a378", "Da1", "b766bfcab5aae5bccbded055", "Da2", "b5aab946c5b6bbdebd44a9cdf2b8e8fdcc48d6d4d3afee54eb7cf662d862cbe3d67bcfaff158", "Da3", "a5b4", "Da4", "a46a", "Dai1", "a762e2ca", "Dai3", "a4efb665", "Dai4", "a54eb161abddb355c0b9abe5ac70c24cb655ada4a46aacc5a9a7b665f7fbd4b4f8ced6ede1b7c9fbc9e0f467dc4ce06fedf2f140cf63dd73", "Dan1", "b3e6bee1a4a6afd4c2b0e858cfe0d743d7f2cff2f048f0d5e145f2c0e4f5f1f4", "Dan3", "c178af6ebcc2dcb3d350c9bfe5b8cd6cd3dbf964c964e9fe", "Dan4", "a6fda5b9b248b34abdcfbee1bc75bcaab4e1b0dcbf46e97ee4eeb0e8e4fca5dbed76df44e0f8e96cf548e4dcdb79e0bae9bbcf5ccacce649cd43cd63dbd5d878e3abe3f4e545eca5f050e9e3f6eacd4c", "Dang1", "b7edbeb4c54cc3cbed68f2aabbfdf2dfea40f2c4dd4e", "Dang3", "c0c9c4d2bed7c66df7dcf8acd0de", "Dang4", "b7edbfbabed7c0fae2eecc58dba5e07eed66d945dec2f05df061f66d", "Dao1", "a44da56fc97bcdb1c9f7dd5be0ea", "Dao3", "adcbae71bec9c3abb76fecead572eccbdef4", "Dao4", "a8ecb944adcbbd5fb573c1d0b1a5bec9f941f4b1ed43db71f6f2", "De2", "b16fbc77d5fc", "De5", "aabab16f", "Dei3", "b16f", "Deng1", "b56ebf4ff4f1f068e053ea66e55d", "Deng3", "b5a5dd75", "Deng4", "be48c0fcc3deb9b9bc6ac145e54cebd3f549", "Di1", "a743ba77a5c2d6f4f17acc77edadeed7d7bedb7de161e669", "Di2", "aababcc4ad7da866b2c3bab0bb43b2fdb9deb9bfc3e9f0f8aadebab9f740f753edc1e77bdcabd5d2e660d074ecc9f95ff0aff2ca", "Di3", "a9b3a9e8aaf3b643acbbafa1a5c2cbfbac6bcc73dbd3cbeecddbe3a3db63dc45caef", "Di4", "a661b2c4a7ccabd2bbbcb8a6aababd6cbfcdae58dabbb4d0cb41cb6ae2f8e760ee61ebc2dde8da4de2ebd0a9d7f9e5cacafad3e8d5d4d649e0e6e15ae1a5d66bea69", "Dia1", "dcdd", "Dian1", "c441c571c5f6b7bfd569d859e6b6cee7eebae25cf968d865", "Dian3", "c249a8e5b84bebfcd4e8daa9eb47", "Dian4", "b971a9b1b7b5a86cb3feb9d4befdb17dc051a6fad5e0acbfb966f065cbf5d2c4f04aedaccdd9ced2d4dee7f7e94e", "Diao1", "c04aade4a44eb649f3e7b84da570b16eeaa1daa4c44bc9ebd7a2e0eccdc9e5f4", "Diao3", "ce78", "Diao4", "bdd5b1bcb3a8a651a4ddeab4e773e04bc9b9e4e0", "Die1", "af52", "Die2", "b65ebdbabfd2bad0c57cada1b7deb3e3d2bcb5c0b5bbcdfdce53d8a2e3d7ebc0f56bdbf7cef2ce7bcee4d05dd079d2d2db45db54dbdddc78e747e7c5d944ddd1e1a4", "Ding1", "a442b076a56dcb6fadaaa86ea4b1ca45c978d84dcdc7", "Ding3", "b3bbb9a9adaae1b1e9eeee43", "Ding4", "a977ad71b076bff5dee4d448d161d9ccd57ee2f4ef45db5fd472", "Diu1", "a5e1e4b7", "Dong1", "aa46a556a94ec35dd0a4e3d9d4c0d4f8cf6ccfb5d5e8dbaaf3f0", "Dong3", "c0b4b8b3e95ce551", "Dong4", "b0caac7dade1b4c9abf0afdbcedcd1afec69eef9", "Dou1", "b3a3b0c2d3f2", "Dou3", "a4e6a7ddb07eb042aa55d0f2d977", "Dou4", "b0aba8a7b372b56bc475d75eb2e8e8c3e865d5c6d24dc5aa", "Du1", "b3a3b7feb9caec47ebdc", "Du2", "c5aabf57ac72c37cf941c270c37dc5eaf9c8c675c370ecbadeecf25ae7a6f75cf8d1f8d2f472", "Du3", "bde4b0f4b840bf77a87bec45e3fed545", "Du4", "abd7b4e7a87ba7aac1e1a7f9c5fbd6c4d868", "Duan1", "baddad42d465d46bd8cd", "Duan3", "b575", "Duan4", "ac71c25fbd76c1ebe9e4df7cf8b8dde0dfe0e2f1f762", "Dui1", "b0efe8bdded4", "Dui4", "b9efb6a4a749b850efc8f2f7ed55f0b3f658eff4f264e976", "Dun1", "b4b0c3dbbc5bb1acedabf7a3e3d5e9aaf4e8", "Dun3", "acdac4bb", "Dun4", "b979beb7acdeb677b950acdabf4ca850a779e851cd57caadcaf4c9b6cacee654d8ecf5a9df7b", "Duo1", "a668ce47cefbd3a9", "Duo2", "b9dcc54dd573e440d0ead974ddf2d469d5a7d76ad9e4db4df1c8f2ec", "Duo3", "b8faa6b7d8a6ce57f3fef3c5d6a3e063", "Duo4", "b46bbc5ab2ebb8f6a8efa946bfe2b9a4ce57e54fe56dcf4fd0c3d0c6abd7d7b2dbe7f3e3", "E1", "aafcb0fedecba3add4f3cea3ebe8a3ae", "E2", "c342b35fc35aae5aae40b8bfae6fd76dab58caa7ca78dacbb348e872cdd2d678d269dab8dac1e8e2", "E3", "e44d", "E4", "b463be6aab58b66ba4ccb94bc1eea7e3c673c345a763b46abeb5b36dcbaef5a7b0eeeba7b8b0ce4bb0d7d8dedd7eb8e3ec46e8b6d8a5f8edcce2d369d8aecac3f8ccf459cfeed2ded3c4dbe5dc47dce1dda6e3e1e968ec5ff4ba", "Ei1", "a3b0", "En1", "aea6b6e2a3b4", "En4", "ddae", "Eng1", "f1a2a3b6", "Er1", "a3b7a8e0", "Er2", "a8e0a6d3cfa5d053d36be077cbcad1e6d0c4ef6cefdfdb46d3b4d4a2ef7b", "Er3", "bab8a6d5ac7cbbe7c2e2d2adec62f0b9e47acea9c974d1f0", "Er4", "a447b64ccbb9cbd0cdfbe9c2db46d1fdd6acdbc0", "F1", "a377", "Fa1", "b56fa5efe2e5", "Fa2", "a546a5efbb40bbd6b5adaf7cd3abd2caf0b2", "Fa3", "aa6bbe76", "Fa4", "aa6bb557", "Fan1", "b566c2bdbfbbc2babc6ea67cefd9f5e5e0fee560f35af85d", "Fan2", "a45ab7d0c163a67cbfbbc473c3bfbcd4f5fcea64cda8bc5cea4feaeef645f353f3abd6dab3abf463f4f6e144e9dcedf8f079f873cb47cf5ff268", "Fan3", "a4cfaaf0e8e3", "Fan4", "bd64ad53a5c7a5c6a6c6b6bab363aa78b1ebcfdbd6cbe46fc9d2d3e9dc4ae2b3e955", "Fang1", "a4e8aadaa77baa44cba8d642dc62c943cb4b", "Fang2", "a9d0a8bea7abaad5a77be8db", "Fang3", "b358a7cfa5e9afbcadc0afe9ccc4cfd7e4dbf6c4", "Fang4", "a9f1", "Fei1", "ab44adb8b5e1b476b0d8a66de36ec050ef57f1b4f3d6f3b9d4dae3fd", "Fei2", "aaced5f3b5ccdb78e3f3", "Fei3", "adeabb42b4b4e3f2bddad55eb5e1cef9d9c6e249eabdd4cdef4b", "Fei4", "bc6fb64faacdaa6da770b7f3a9ccd2c8aae8b151d0ebcd61d2e2eff7ed75ceedd057d0d5d0efe9b6efb3f24df0bcf4f0", "Fen1", "a4c0afc9aae2aa5ea768b4d9cd6ad7f4dca8ccd0dc77cfefd364d3d8f556d5cfe8ec", "Fen2", "bc58b549a857ccded9c8d3c7f346f1e3e56ee5fdf356efb4cab7cd5ad362e3cbf874cad2eafdf663", "Fen3", "afbbecb6", "Fen4", "a5f7a9c1bec4bcaba4c0c154e0f3f45ccaaecffde8dfe9c3eaebf078", "Feng1", "adb7b8c1abcac2d7bac6ae70be57a4a5b26cb7acbfd8f65adfb1f5d3dea9d1cbd5d1cab2ed4ad467d8eff747f9b0f9cbda76", "Feng2", "b37bc15fb6becab0da49d8b0dfa7e1ea", "Feng3", "d477d7c5", "Feng4", "a95ebbf1adc4bfd8c15febb4da63", "Fiao4", "dffa", "Fo2", "a6f2cbf3", "Fong4", "cfd9", "Fou2", "d04daae6d352dcc8", "Fou3", "a75fa6ced9e1d26fe8ea", "Fu1", "a4d2bda7bcc5b9e5a5edbea2dbfab36ccf53cfeae469b679e35bdb40d3d1dad8cbaaccfdcecdd169d760df66e8e5cc54eacaf275d6f0", "Fu2", "aa41bad6a7dfaf42b2c5a5f1a9bbbfa3b454ab52a9d8d07ba5b1a7b7b5f6aadcbfe7bdbbb0cbdfecd04db265a4d2d3fad767a9ccd3bad5beb2d1d3acb5e8b2d9cbe0cf7bdf5ad758aae8d070dfa6ca6ccc6dd6cfdfb6d7b7ac74d9d2e651d64ecf52cfd5cc66ccd5ce59ceedcf47d679d77bebbee0edc95dccf7d2ead6fbe4caebadeca7efb0f3e8f57a", "Fu3", "a9b2bb47bcbebbb2a86aa9f2adc1b079b2e3b5c6b340de58e546ccb9f3f5f064be66d3f4cc72f1c4ddc4ca6bdff0d3c5dc44a4f7", "Fu4", "a4f7ad74b0fca549aafeb449b45fb0c6b3c5c2d0bdc6b8a1a94aad75bde1be74aafaad72c34cc1cce7b8ec7bd2e6d45eebcdf56eeed9e246ce60d062d7a7dfcae7b9e7c4cc54cea5dbbde6efeb50", "G1", "a37c", "Ga1", "b9c7c9ee", "Ga2", "aaeebebfd0c1", "Ga4", "a7bc", "Gai1", "b8d3abb2d0c2b8f0d375cbb4ce79d36adad2daece055e05be0d3", "Gai3", "a7ef", "Gai4", "b7a7bb5ca4a2b674b540dd76d962f047", "Gan1", "b0aea5cca47aacf1a878c0aaac61a958ccf4cbddaf69cb68a7fdcd7ad0a6df51e3e0e4e2d8f1", "Gan3", "b4b1b750bbb0b1ecbef1b57ae641cd75cd78d3e3", "Gan4", "b746c642b268d6e6caf8e0e8dbe3ba6df9a2d647f2a8d8f1", "Gang1", "ade8bffbacfbb15ebaf5a9a3a87aa6aaa7fed35ccd74d069b3aadcefdeefd9bbd2fed4b6da6b", "Gang3", "b4e4b15e", "Gang4", "ba62", "Gao1", "b0aabf7cbb49bf74afccaf6ff253b841f6cee252e2e9de5cf3a6", "Gao3", "bd5ac5cdb764ba60bfa5aa58e1f7efe2df52", "Gao4", "a769bba2d3fce870dad5de7b", "Ge1", "adf4ba71b3cec246c0c1afdea4e0cb76aab8d9fdcfb7db5dde4fe4e5", "Ge2", "aee6adb2b96abbd5b8afc066b5f0aba3bb4af4dddcd0e1eeada8e8b4dcede040b0acbbd7ceddcbccebcbef75d1ced3a8d943ea5cc2f0f87d", "Ge3", "b8afd0f8d753e9a5ec7df3c0d6cd", "Ge4", "add3a655bbccd0a8bae7", "Ge5", "add3", "Gei3", "b5b9", "Gen1", "b8f2aeda", "Gen2", "cdfe", "Gen3", "a6e1", "Gen4", "a5e5a6e1d3a3", "Geng1", "a7f3afd1a9b0b865c3bcbde9d24ee6e5f3dadba9d958", "Geng3", "b1f0afd5ae43df58f1c7ae47ef64d3f3d1c4", "Geng4", "a7f3a5e5d87d", "Gong1", "a475a4bda55ca8d1a7f0ae63aea5b060a47db047acf5c5c7aad0dffdcd74b3aaeac2dce3dd70d863a640dd5a", "Gong3", "be64abfda845a640d2acc471d1e2a47bd1b1dbbbf4a3", "Gong4", "a640a8d1b05ed050dda2", "Gou1", "a579b7bea4c4b95fac65ccfbeabae6edccdbcdc5eae6", "Gou3", "aaafce41cc63ac65ad65d6d6d051d3add7ad", "Gou4", "b0f7c1caabafba63b6fcdd62b770b8e1bbb8ee7ad0e0ce6cb96fd855e6bef2a9f3a4d0f0", "Gu1", "a968a974b664a942aa66a6f4dba3b5dda94bb347decce354c06cdbd4dc5ecd40d360e356b957ec7ec95acf54e0ccdc49ae61e555e9c6", "Gu2", "b0a9f6bc", "Gu3", "aad1a56ab9aab0a9a8a6bd5cb8eba559c5dbcb53acbab7c6afcbe14cb5fec1d4c35bc2a2edeaf053d361d7aac9e8b957cb46d5eccd60d146dd4ce242e3c3ed58eff0dd6bead3edfa", "Gu4", "ac47a954c555b6b1b9b5c044a769a6f4deccd5c0e24cd65fd4c7d544d0e3d9cfdefa", "Gua1", "a5caac41a8edbdbdbe68b5c1ef7ed1ebd3ecf3bcd067dfa2dae1dfb2e141e2dee6eaefcfe061edee", "Gua3", "b9e8d46c", "Gua4", "b1bea8f6bb6fdf68d6f1daeee047ac45ec6f", "Guai1", "a8c4", "Guai3", "a9e4cf5eac62", "Guai4", "a9c7f24ac95be973f04d", "Guan1", "a978c3f6c65bab61b4c3ace1c560bafaadbeb2f0e6b2c960f8da", "Guan3", "badec05db2f0b55fdf46d745dec7ebdd", "Guan4", "ba44b365c4e9c5f8e1e8bf64c67cab61c65bc963f6edf6f0def3f7ebf975d5e1d556d8f9f171f9ca", "Guang1", "a5faafd6aca9d1e9d2aecd59d3a4e4b4ce5bd27c", "Guang3", "bc73c278", "Guang4", "b37dd1e9edefdb52f474", "Gui1", "c26bb357c074bac0bbd3a663af5eacd4b3c8d8b5e5e2c244e5e4d0b8d6cad9ece174e1f0", "Gui3", "b0adad79b8deacd1d46fb4bec973edc2cbc1ce56c9a3ce69e7a5d177d6bfdbb9dffee146", "Gui4", "b651aedbc264b8f7e4f3de60c5edcccbcd50dae4cf40e56bf2efe5c5", "Gun3", "ba75b34fc358e36cbe40d5a5e752", "Gun4", "b4d2ed6b", "Guo1", "b3a2c1e7c1b4b3fae14fd4f4d4ade162e9f1", "Guo2", "b0eab9f6e77eef55ba51e3a2e741e2b6e1d5edc4", "Guo3", "aa47bb71bccde3e2e84be35fb274d5fed55df665ebe9", "Guo4", "b94c", "H1", "a37e", "Ha1", "aba2", "Ha2", "b5f0", "Ha3", "aba2", "Hai1", "ab79b6d9cbe8", "Hai2", "c1d9abc4c065e8b8", "Hai3", "aefceec6d657", "Hai4", "ae60a5e8c062b6d9aef3dccddaece4cf", "Han1", "b66fc24db346e977dcaceca1d0fddec3e450e17b", "Han2", "b448a774a8e7b25bc1facdd5a6bdca52ba6dd672d5c2e8a2d655", "Han3", "b3dba875c944e755f344ecc7", "Han4", "a94dba7ea6bda7f2b26bbed1bfabbed9aeabc058c9e4c376d846aec2e5c3e663d5a9ca43dabedb72d3e0be5ad7f7ef5fd141d254d5f6e0e4e3e7be67eb5fef46f170f246f2f9e875f6b9", "Hang1", "c971", "Hang2", "a6e6afe8aa43a75ce0deaeeccdcccdb3cdacd3b9ccc3d7d2e0d7e8da", "Hang3", "d3fe", "Hang4", "a6e6a859", "Hao1", "bb55ecc3ee51", "Hao2", "b8b9b240bba8c0a2c0dac4aeb8e8c07ac562b348b6e7f4a9e7dacdf3f64d", "Hao3", "a66eb071", "Hao4", "b8b9afd3af45b571c2eeb255a9fea66ef8afe650e6b8c556b952cffbd5fdde45e6bad144d1aef6aacef0edf3", "He1", "b3dca8feb646ceab", "He2", "a6f3a658a94daa65b2fcaed6b2b0a5ddbdc5a8f0c2f3bbd7ac54f7cfb255af72f2f2bb5cb8e8bbd2acf8de4ebfade7b2b6dff1eaada8ef50f5a6e0caec7df17bdb5dcc51ddfee2c2e3bbeabbeb5bf05ad2ccdd5ddde7e65dd3e6", "He4", "b650a94dc562b3dcb2fcc07ebbaeb071b77bdccae2bada74eae4cbcbde77", "He5", "a94d", "Hei1", "b6c2bc4be648", "Hei3", "b6c2", "Hen2", "b2aacedae8b2", "Hen3", "abdcacbd", "Hen4", "abeb", "Heng1", "a6ebadf3d750ebb0", "Heng2", "beeeabedbfc5f9dad2b2f4c1aeecce64f76dddf3e44bebb0d968cbbc", "Heng4", "beeed4a6e65adafb", "Hong1", "c546aba1af4dc1a9d0b1caa1d96eda48ce46ebcee7e5eeeada60e4e1", "Hong2", "acf5ac78a7bbc245ad69a5b0aa6cb052e862b6a3c664d041d354d363d247e4c2cb5edfd2d367c966cb52dadddc72eef8c9cecb6cd7cdda43db58e044e052e6dde974cd6fd07d", "Hong3", "aba1dccf", "Hong4", "c069a845e5feedfbeeed", "Hou1", "f3f8", "Hou2", "b555ab4ab3efbd6aeedbef53e2dfe4a5e6f5f56fdfdf", "Hou3", "a771", "Hou4", "abe1add4ab70a65ab06dc64dce5eb3fbd0bfdc5adafdcfac", "Hu1", "a9bfa949a547b1abe2a3c0b8da70d9dbeaf0d77cca76ca4fe570e1a1ccc7e5f0d652cbf9ccd1d47dce7ad5f5f0e2c9c1d641", "Hu2", "ad4ab4f2b3fdbdb9bd6baab0a9b7b8acc447b7e4ef4db1d8c35ba77aead1e7c1ee7debd9da70ddacf57ce5dad8c8caecf574d656e8dceb6df260ddede152f5af", "Hu3", "aaeab55be271b0e4b35ccb5c", "Hu4", "c540a4e1a4acbaadb1afb27dcc7cd2e9d343c9bcccb2b7b1a85bcc5ee46af4b3f851cce1e5eeccc8e171d4d7e16ce668eeb2df63eea6e77a", "Hua1", "aae1b5d8bc4df872ebfb", "Hua2", "b5d8b7c6a645b7e2c3cfbc4dbeecf77ef4f3c1c5b9bad4f5d840eb62", "Hua4", "b8dca4c6b565b9babeecb5d8e554e1e3d4f5e55fcce7dffce5d4f070e645", "Huai2", "c368b261abdeba69bdefcbbfcae4eb77eb76f454f266", "Huai4", "c361a7a5e7e4d165ce45f7f2f7f6", "Huan1", "c577f9c2f94ef5ddcb61f5ccf65be8ee", "Huan2", "c1d9c0f4aed9f2b4f855c1ecf660bec8f66cb1fbaca7f8b2e058bf4ad37bdb7bcb77d1b3df6ce97ceeb3e953cfc2dca5", "Huan3", "bd77b570e9ebdabae464", "Huan4", "b4abb3eaabc6b177a4dbb7d8abb7b541bac8b8e6b1fbdc4de9a6e2a1d152f4dedebde449f5c6ea7c", "Huang1", "afeeb757a877d0aac9daefbe", "Huang2", "b6c0b461b471c2aebf58c144bdc0b7d7acd3b0c4b547b94eb6aae643bd68d874e74aeedaea49c341f576d8b1f0c1d45dedb5f86fd8cef3bfd8eedfcdef52e5b2e67df34c", "Huang3", "c1c0abe9aeccb745aca9cca4e261e2bdf167de53e6b9", "Huang4", "aeccdc41", "Hui1", "a6c7b4a7bdf7abecb8d9b775bea3c0b2bc5ae7c3d95af16fde6be6f8d3dfe7c7cfa4e0d2f773f7b3cee5d86be341", "Hui2", "a65eb06ab5eeaff5d3cacf77d6a4cec8f2c7", "Hui3", "b77caeacbba3b7b4c0ecb8ecad6ba6e4d274e9e5ecfdf4d5", "Hui4", "b77cb466b6d7c3b8bc7ab74ac2a9bba3b8ecb1e2b16bbfd0bceca563bfb7e9f4c0edb3f1d17dee50f2bef546e14ae5cdedbcf072f06ef0c0ed6ee55ee5a2e659f055f2faf75bf4fce9d8dd5fe050e549e756ea5bef51f668f677d06af05ff2ef", "Hun1", "b142a9fcb8a7ec4ed55fe2e8d9e0d9d5d5f7ddbcdedf", "Hun2", "bbeeb4fdc05fb256b7e9ddccef4cd9d0f1a8f7cbedd7f149", "Hun3", "b256dee0", "Hun4", "b256b4fdde54eba1d149e1c4be40d0dcb1fb", "Huo1", "c1c5", "Huo2", "aca1cbc3dc64dfaa", "Huo3", "a4f5a5ebb9d9dc64", "Huo4", "a9cec3acc0f2a94db462bad7c04eb366c1c5c0a4f4c9ecc4f4b9f769f27cefe6c0e2cff1f174d6bac0c3da46f3beeea5d1c5cb5dd2d0d56edcd1f043f07ef245f25ff452f5e0f84ff8cf", "Huo5", "a94d", "I1", "a3b8a3b0", "Ie1", "a3ae", "J1", "a3a1", "Ji1", "bef7b0f2bf6ec15ac2ddbf45b8f1ae56c2fbc4c8a6d9bd5db0a7a95fb7eef9d6badfc146c3d5c5f9a44cc9f3a5e4ae6ac545bf59b458bc54bd42b452b551f6d2a8e4b4c1a97eae41b6d6edb0f8f4c27ef744f7f1e7d1eefbdbb5e4aeccd3c946c95cedcecdcaf4f8efdddef8e26ae5e3e7dff3f9f670f76cf7acf87ed340d0e9eef4f8e7f5df", "Ji2", "a4ceafc5b7a5a759b6b0abe6c0bbaf65c479a64eb149bfe8afe1a7a3ae41b6faa856ab45a659b4c6c2c7bd43b7aaa7c4d344f6c0b761ddfbeebda5f9e3b0e3a1cdbfee44e7fadc6bcbb8d14bce63e9eff0d3e94fe64fef79e969cfa1cadfda53cce5e4afcfbff542dfe9d3d6d464d548d76edce7e1fee26fe3a9e758e9c7eb40f4dff66ecad5d1b9d5b8d6c5e8b1eb5cd7c7", "Ji3", "b458b5b9a476c0bdafe1b475c0d9a44cb9a8cacdf0cad0e9d571ccfee7fdf7a9c950edb3c9cce5b0", "Ji4", "ad70b04fac4aacf6bbdac47ea975b148a7dea7b2c0d9beafc3b4b1aab2bda7d2ba5bbeacc34dc356bd5ec545c2c9c66bc5b4c1aac067ede4c1bbc9abacade2dbe45becc1d8a7d8fce2b8f2a6aae7dfbdded3f278eaafef72f95cf3d7f7b6c95ec9bedb53dff7e345e44ce4ddea78ed40f044f1d4f1e9f241f460f570f5f9f7f5", "Jia1", "ae61a55bb9c5a8ceb3c3ad7bcf45b350af6dd6d2cfc9dbf6ad58b8b5bfded740f5b3cd4acf6af153ecacda72dd58dea6ebb1a7a8", "Jia2", "a7a8aeb5c055dfe6b2f3af48b1aed3f7d17cdbcbdf49dff8e868d5b3e071d755d140e4a6d6b3caf6e4c4e8b3f1d2", "Jia3", "b0b2a5d2b8ebb95bcc61ad4bd97ae248e2ddecf8d8cacfd2d8f5ddd9ae4c", "Jia4", "bbf9b0b2ac5bbe72b6f9b8ebbd5bc9b2", "Jian1", "b6a1bacab0eda679adddaad3c17da66cabc1b7cebd70c271baa5bae0c4e8b5d5ccb1f179da66ddecbfa1b4e6ea4ae3b6f6b4dd5edea5f6fdd7cfc669f3c2dc65f954f7aef6abf5cfe66ceb46d959ddb8c9dbdba2dca9dfd1e8e6ef54f27ef3b7f3eaf462f8bcd55ad668efab", "Jian3", "c2b2bedfb0c5b4eec0cbb47ac3b5bbfcc650ac5ab863e6f9eeaae1d6eebff756d7d6d8aca65ff575d1c9da51c2a5d8d2f0a5f949ddc1deb9", "Jian4", "a8a3abd8b0b7baa5a5f3b6a1bacac1e4c5b2bd62bc43c4a5c5b3bde2bdeebfcfb7b7c2cbc05eb878c271b9b0c265b6a2cf74d0d0cfbdd1e5ddd4d2b6f468bceeed7daff2e7d7e25de6e2f572e75eec44ee5ef0d9f4abf956", "Jiang1", "b14ea6bfc3a6bbf8bcdfabb8c1a4d3deed4cc5b7ee6ced45d373f058cd6fe37e", "Jiang3", "c1bfbcfabdb1bcd5f3a7e743", "Jiang4", "adb0a64bc2e6b16ab14eb5bcedcfcf7af0ece1b0becad54cdbc9", "Jiao1", "b1d0a5e6bda6c5bab54abc62ada5b8f8bce5b5ebbfbcc147b4d4d374abbbc242e0fae5a9ca4df86bea4eb8e5f860f4f7ef77f86ae153e9a1eaf1edb6ee64f6c7e568f0c8", "Jiao2", "c45a", "Jiao3", "b87da8a4c3bac5cdb6d3c142b5b1abbbcbb3bbe5b2aeb9aeb6cfb8fbbbc7acbef051e4efdadef0c6e1f3e5b9d1bff7e5ecf2e2aee4f2f340dea2", "Jiao4", "b1d0a573aed5b8fbc4b1c3e2b5a2f6f5c3e7e975e943e569ced5e1f5d2abf8c9de5dd2fae150e64ef4d3", "Jie1", "b5f3b1b5acd2b6a5b4a6b0bab6d8d86ee96eb5b2d9f4ee4edbc3d478d9acdb61e7a8f57e", "Jie2", "b860bce4b3c7b1b6badca754ba49b5b2aa4ebe65b8d7aee5b7fbb050cdfcabfabd7ec0cdaedca46df04bdaf4d455c25ed0cccbd5d4d0dddabad4ef6acac6e251ca44dbc3d8e0d1eff3c0de66e0c5f543d3d6d3f0d4fadd50dde5e05fe7f8e9ade9f6eee6f9a7cccdd1b9e367efc4e572", "Jie3", "a96ab8d1a96eecfbd4e3", "Jie4", "acc9adc9a4b6a7d9c2c7a9a1acceaae3bb7cb8d1d47ad86ecd6bd3c8e2c7eb7acaa5cac9c9b2cff0d1a3d358dad2f950f2b6", "Jin1", "a4b5aaf7b854ac7aa4e7a479b5acc3ccace1aefbad6fd3d7dad4e2d3db7ed2b4d156d357e56ad564", "Jin3", "baf2b6c8c041c2d4bea8c2d1bd40c444e5d3e158e5f2d4bbe1cbdb6aceaf", "Jin4", "b669aaf1bac9b854aecabea8aefbab6cc2d1c275e1b6beb6e0dabfa7b6c8f0b0cab5f652dd48dda8cdafea68ebb5ecd3e25de4e9e763ea6eecc2ed53f045c9bbde61", "Jing1", "b867baeba8cac5e5b7fab2f4b4b9b5d7b9b8aef9c448aff0b1dcb865f5b4e352f3dbcacad4e1d5a8f1d3f3d9f6d1f8e8c9b0d561", "Jing3", "b4bac4b5a4abc056a8c0e4eabf5bbca9cdf0ed6dc964d64cece1e9baf2e4ea58", "Jing4", "b771b3bac3e8c052b9d2b262c476b377ae7cb974ab6cd0e1d748b56ae2cbd0c8e8b0df45d4d1d5c8cddfd0e4dfbce9a7d179", "Jiong1", "ced3cbf7e8cc", "Jiong3", "b57ead7edea3ccf9cd52d6e7eb75ca6ae662caa8e6bbacb3e571edd4", "Jiu1", "aac8b4aab3eeb9a7f147da47e5d6dd79c956c9f2ca42d0afd96adbaef9c4", "Jiu3", "a445a45bb073a868ad76a862adb4aac8", "Jiu4", "b44ea873b1cfc2c2b8a4a6ddac5eaab9a953e0f0f86cb45cd1b5e5aaf3ccf3f2", "Ju1", "a97ea9ebbe73aa71af6ab349aaaeadd1a8aebff7e3fad075dbedd35fdb5ed4d4d9b9db4cd4f9d2c7daa1e0d5d5fadfc6eca2f3e1cee9d963e3dee7fce07c", "Ju2", "a7bdc1f9b5e2beefb1c5bbb1aedcd1b7f17cab5dcbd6e842e876f1d5f5a4d9bed64bd644f9b5cfbed5b6dc56dea7e07be35ce7f0f3e5f5f6f7cad84aef5e", "Ju3", "c17caf78a943b2f7aa71c4d4f5d1df4cebc4e3afd9bccf40d2fdd7c3dbf8e7b7", "Ju4", "bedaa579a8e3a5a8bc40bb45add1a9dab65abff7c4dfb964acb2dbd6c1d8add0c2a3bdf5c1fcccfbad55eab2f4e4c0abd2eee3d4e17ef65fca5cd575d6decc4ecca5d6eba8acd6fecc5dd4c5d77ee8c8e9f2f0f2f4d7cd48da5ee94bda6c", "Juan1", "aebdae53c359aefec54fb0e9f7f8d5afa8add74fdff9", "Juan3", "b1b2a8f7d4afdb64eded", "Juan4", "adc2a8f7b2b2b868b96dd1a6af58b0e9ea5ddabfdedadafedc52ceb2ebdfdb4ae8b5ec72", "Jue1", "e4feb6d8e5b1", "Jue2", "a84dc4b1b5b4c0efb1b8c45ab35ab3d6bcfbc3ddbfb9b155c5ccadcfa7e0bebbf477d7c6a8a4a46eaab2b9bbe9c8f5dac3d4efc2c5a9cd69b87dede9eb54f9abf7dbd5c1e644bea1f9aad7d8c5edd852d8e0e6b5f96ef4f2f9c1f7e9d1c2cdb8d654dc69d3c0d7ced7d3e0f6e57cf0d0f7d8f85af86ed4b3d5def6f9", "Jue3", "c3dd", "Jue4", "adcf", "Jun1", "ad78a767a7a1b676e2e1cbf0ecb1d764f1cbd5c9d3cdd3d5ec59c074deea", "Jun3", "b57ee3e4", "Jun4", "ab54b5dfb070ae6db5a4b96dc0e0c240bfb8af43d673daadd64dd1b8e8c5e359e95dd5accaa3f1dcdfcee76a", "K1", "a37d", "Ka1", "a940b3d8aba2e0c7", "Ka3", "a564ab79ca61", "Ka4", "b3d8f3c1", "Kai1", "b67db47bd67ccbb4", "Kai3", "b3cdb46eb7a2b75fb3cfb05af15adce5f16deed2f3ace1f8e074", "Kai4", "b46eb75ab474ab79d1f5d271d46eeccd", "Kan1", "a55ab3f4b0c9b760acddf7ced8dc", "Kan3", "ace5a8d4a7a2ae72c265d9dcf4dcddfaefe8d4b9c942f1a9", "Kan4", "acddc0fdb0c9f545f8f9eaa9d0abe165f7a6f4a5", "Kang1", "b164ba42c152f36ee274e179", "Kang2", "a6aa", "Kang3", "ba42", "Kang4", "a4aea7dcaaa1a5eac9c2caa9cb66dc7acba7dc70", "Kao1", "c975", "Kao3", "a6d2af4eabfed1dccaf7edf6cfa2", "Kao4", "be61be52bab9", "Ke1", "acecac5fa8e8b4cac1fbad56bd4fbd57b348bdc1b661b85cb85ecfc8d2dbf2acee48cea4e0b3e5efdea8d8e8", "Ke2", "ab79b4df", "Ke3", "a569b4f7d0f8a956cc65d4c6d975e95fe0ce", "Ke4", "abc8bdd2a8e8a74aab67b3d8b7c2abf1b6dfe245bd79c34ed5dff1b2dda4cbd9cdf2", "Ken3", "aad6b0d9bec1c0b5c569f3fbe056ebfa", "Ken4", "d576d6b6dbcf", "Keng1", "a77cdac8c3f4d65ea75ca8c2def2e8a1d15bd1c6eee8", "Keng3", "d1c6", "Kong1", "aac5b153adc3e34fd554b851d5e3ebf2", "Kong3", "aea3a4d5adc3", "Kong4", "aac5b1b1eefc", "Kou1", "e1e0e1becdc3d7bcf363", "Kou3", "a466", "Kou4", "a6a9b146a56ee74db3a7f6b6dae5a746ccaae26ee6beedca", "Ku1", "adfaac5cb85dbe75dbf2ced8d1f1cbd2f3a9d05ce9c6", "Ku3", "ad57b7b1", "Ku4", "ae77bfc7bbc5f441cd7de2e0d3e7", "Kua1", "b8d8a66ace66d3a1d1d5cbba", "Kua3", "abb1cbbae4b3", "Kua4", "b8f3afe3ec6d", "Kuai1", "ce4ad87b", "Kuai3", "e3c7", "Kuai4", "a7d6b6f4b77cb85fc0ccbc44ebd7e9f8c17ae944ea61bbfbf8dbe4d3f856d5d7", "Kuan1", "bc65c662f2c1", "Kuan3", "b4daedb7b1fb", "Kuang1", "a64aaed8b5a8e046a8f1cec6cf6f", "Kuang2", "a867bba5f1db", "Kuang3", "cdea", "Kuang4", "aa70c471c36daed8b2b5f14bdbe8c252f5e7daefefc9f269e576", "Kui1", "c1abbf73b2aff377cbd1d1a7f54aeee5d378f0b1d86bf5c9f74a", "Kui2", "bbedbaccabb6b47db8aab666dd74c4dcf3b8ddc0dc55ec5ae6fcddeeefe1d9f9d850ddeff8f7f9be", "Kui3", "b3c8e069e0dfde79f0fccea1", "Kui4", "b75cbcecb9bcf558c34ab3e7c2b1dcfbf07ce5a6edbdeb44ed7ee5ebe9ccf4f4e542e5b7f560d6b7e76c", "Kun1", "a9f8b158a95bb562c043b54fe7c3d5adf3cbdb74f1b1b9a6d563d663", "Kun3", "aeb9b869d1a8b1eee8a7dcf2df40dacadff3f7cd", "Kun4", "a778b574d265", "Kuo3", "e9ab", "Kuo4", "ac41c258c1efb9f8f54ae272b5f2ce62f37af6fa", "L1", "a37b", "La1", "a9d4b0d5b3e2cf58eefdd6f7db69", "La2", "ab66c3e5c9ed", "La3", "b3e2f2d9", "La4", "c3bec4faf84ebbb6ab66db4bb8a8f3c4e2dcddb7ddeb", "La5", "b0d5", "Lai2", "a8d3b5dcb174d5e9f1b0e35dd4fbd7ecebe4f3c9d9b7d54af3e0d4a8", "Lai4", "bfe0c4eec375c5a3b7fde7ecf4bbd15f", "Lan2", "c4f5c478c2c5c4e6c464c469c4b0b0fdb450c1f1f7fcf8c2c4e3c5d3f8f3f9a4f5d9f8aef2fdf8c6", "Lan3", "c4fdc369c5f3c656c66ce949f8f6f8b0e85ff1fbf958d25f", "Lan4", "c4eac0ddc66cf953eff9eccc", "Lang1", "d86a", "Lang2", "ada6af54b459bdb8b7e3b277b77ddad6d75bdfe2d5b0df47e863cdddd171d1f9", "Lang3", "aed4e8a6dac5ceacd1a2e44ed648dcf1", "Lang4", "aef6d14ae3ac", "Lao1", "bcb4", "Lao2", "b3d2a863c0f7e5fcbc47f152d248f4f9f062f0bbe563", "Lao3", "a6d1abbea8d0d1ddcfc1f357ce4ce9c9e47bcec4d379", "Lao4", "b3d2b5b8af4fb954e16ff355e9d4e0f2", "Le4", "bcd6a955b0c7a6d8ccf8d14da57bc952d1bbc97dc9aad2e3f7afc9a4d142cda7", "Le5", "a446", "Lei1", "b0c7", "Lei2", "b970f5ecbeddb9e3c54ac3bdc15df5eded44e6aef24ff276f641f764f7d2f8f2", "Lei3", "b2d6c253c077baaaa6d4bd55c1a2e04cf2d2e5eaf04ff057daf5eaa4f973e6b4f24ff254f47cf5d8f757f97ce8bcf47bf74bf945", "Lei4", "c3feb25cb2d6beddf5e8e474e4b6f7d0f7f4f8b6", "Leng2", "b857d4f7d9b1ee55bdb7d0cdb7ab", "Leng3", "a74e", "Leng4", "b468e844b7ab", "Li1", "adf9", "Li2", "c2f7bcfebea4b1f9c658c2e7bcf9bfa9bba9c67ab270ba76f6e8af57f2d4b8c4c4f9f9cfe175ee71f5b6d5bce5faedd0eb49e5f8cdf9f7f0dcc6b3ededccf14ef9cef7d1f6dbf6dff678e17de5cbf0dbf3d1f3eef6e0c452db7af84df875d34ef7c7", "Li3", "a7f5a8bdb8ccb27ac2a7f9d8adf9af40c355ae5bab5abf43c5ddc4bfc4f9f8d7be59df55e054ce7ef8f4", "Li4", "a44fa5dfa751c452befac363a8d2bee4b2fabc46c079c472b2c9bb59c645c377c4d7c1f5c474a64fafefaedfb758ab57b567c27eb2c1a9d1b0e6c5b0b27cdbe0f1f2b7ccc4f7f455cd42f5e6f252f765f274ef67d2aaf473eabcd06bd145c976f760b07ab0acf471d2f5e2d4f848cc6cc9f1c5cff4a1d0b2eca4cfedeff2d2dad560d7a9d864df53e374e3eff056f248f272f4bef646f6baf6caf6e2f755f7bef8a9f978f9add1e4d259dceeddb9e7a4efb9f24bf843f8b3f979d164", "Lia3", "adc7", "Lian2", "b373c170bca6b747bdacbaa7c3aec549c5bfb9dde6a3a9a9ee72e155f154f569de49f2e7e5d1ede0f0dee443e6c2befcede5edf7f0fdf4d4f6dae95a", "Lian3", "c179f14ceae9e1f1dcb6f2bd", "Lian4", "bd6dc1e5c5cab7d2c3ecc0d4c0c4c46bb7aff2f0d9efea46f5fded4bee56dfb5d8a9", "Liang2", "a87db1e7b671c2b3b244b864bcd9d9cae378e847ef59", "Liang3", "a8e2adc7c352e379e3f8", "Liang4", "b671ab47bdccbdf8d867b4bdb244d479e457da4ed1a2", "Liao1", "bcba", "Liao2", "b2e1bc64bff1c0f8b9e9bcbab9b1bce3bc49c2b7f4efe556e679f863efc3f7bae3aae27be1e5f0eee1a7e1cce56ce5bfeab6eaedf067f376f553f673f551", "Liao3", "a446c141e764e5a4d442bee9e46df0c2", "Liao4", "b9f9aec6c141bf52c9d5e1e6cd53ee62e6d3", "Lie1", "aba8", "Lie4", "a643af50a648b5f5c279b1caa8e6c663f761ac7bd37edee1efd4e064ce75d3ead74adbb6dfeee8beecbdef71efa5f271", "Lin2", "aa4cc17bbe46b24fc5ecc5efc04dc143b559bfeee562bf4dbf5ae360c3e1e5fbb7f7ed73ed7ad559e9b9df69f778dee8e353ed6ff076e0fcf07af350f442f4e9", "Lin3", "bbfebecfe96fecf5dbabdcb1e36a", "Lin4", "a75bc66ec4a9b8eee9c0ec4dda65", "Ling1", "a9f0", "Ling2", "b973acc2c646b961c4d6b3aeade2b5d9b2e2b2dcad64a744baf0d5e6b2dec06fcbf1b34dd2beaa7ed757f4e1dc46ebf6c4e7cf61f9bbdedcd2e5dbdee849eefaf3c7f8c8cc64ac53e9fbcbe5cc41cc42cc52cd65d2cbcbefd676d6d8e441f5f3ccb0d4e2e8cdee53f9bcd4c2", "Ling3", "bbe2c0adcc76", "Ling4", "a54fa574cfb6", "Liu1", "b7c8", "Liu2", "bc42ac79af64b2b8af5bba68c273bd46bbbfd97ef561f365f675f6bfefcdeedcaca6f15edd46efc1dd55f2d6dbc4efacf6bedfd4f6b1dd57", "Liu3", "ac68e371e6f1b967e0e3cfd6", "Liu4", "a4bbb3b0b7c8c348c2fccbfdd6fcf379dd61dce8eebc", "Long2", "c073b6a9c5a2c456c5a4c46ec467c14bf25ded74f453f5e2f450f1fdc4eff4b8f846f844f375f8cbf8d0f750f752f9b8efb7f6d5f74d", "Long3", "c3f7c36cc362", "Long4", "dbc1d0f1f240d5b1", "Lou1", "ba4f", "Lou2", "bcd3b9c6b0fac1b2c55cdcbce76fe1bde27eede7e66ef0e4edf0f54bf7bdea79", "Lou3", "c14dba4fe15ce1a8", "Lou4", "ba7cadaec553c3f3bf62", "Lu1", "c250", "Lu2", "bf63c4aac366c4a4c46cc660c379c674f847f1f6f9b7d66af743f746c644f6fef456f1f3f247f74ff742", "Lu3", "be7cb8b8bedbbab1b3bfc372f2c5eaadf666f373e769efd7f25b", "Lu4", "b8f4b3b0bffdb3c0c553b8efb853b84cb4e2c453c64fbcaef146dc4fe275e078b6cee9f0f6fced69ca46def7bf72edbbe85ef1b3d5f1daa3ded7eaaccc74db77e753ebf5ce5af370f3d4e1dcd6b5dedee1b5e66ae7f9ee46ee5cf2abf3ddd5fbe163f0fa", "Lu:2", "c66abe5bc371f2d1e1cfe5f6e742", "Lu:3", "a766aec8bc69ab51be54b9f0c15cc1b9b0fabb4de27ef4a4d5cdd3f9cee2df65ecbbd6c0", "Lu:4", "abdfbaf1b276bc7bc26fd8e9e6fef84adb77dfd0ecbf", "Lu:an2", "c5cbc570", "Lu:an3", "f6dc", "Lu:e4", "b2a4b1b0e86ee1e6efd3", "Luan2", "c572c671c67dc665f943f96bf7e1f7dff8baf9cc", "Luan3", "a75a", "Luan4", "b6c3ee4a", "Lun1", "b1c1", "Lun2", "addbbdd7bdfcb25fb15ba8dabafab1c1d4acdef1ec43d565d84bdba1e846d9c3e3ee", "Lun3", "df41", "Lun4", "bdd7de6a", "Luo1", "c56f", "Luo2", "c3b9c1b3c5dac672c5dec659c55bc56fc57ac4d8f2f4e1e7f7e2e76dc3f1f8e3cbd3", "Luo3", "bb72ea73f5f0f2dde3cceecf", "Luo4", "b8a8c064aca5b5b8bbdcaf4fb954eff6babaaba3af5ff942dbcad6b8ef70efa1ceaa", "M1", "a376", "Ma1", "b6fdb6dcc0a8", "Ma2", "b3c2b7f2b9c0bbf2c1b0e673", "Ma3", "b0a8bfc2bd58babfde62b6dcf156f6c5e14d", "Ma4", "bd7ce6ccd858e259", "Ma5", "b9c0b6dcc1b0", "Mai2", "ae49c5b5f0b4", "Mai3", "b652e547f868", "Mai4", "bde6b3c1c1daafdfe4f4e7b1", "Man2", "c65ac443bf66c2dabaa9f54ff0e3c5c1e6a4d1abe1cae5d8f6a5f6a4", "Man3", "baa1ae5ef8b4", "Man4", "ba43baa9b0d2bdafb9f7e170c3eec167e15be672ea42dcbbe2cd", "Mang2", "a6a3a87eafedaabcaa5dcabedac9ca51d0f6cab1a841cd76e86cd160d65ddab3dfe7ef5cf4c0f878d042", "Mang3", "b2f5c1afe2a5c9f9d178dac7db5ce169", "Mao1", "bfdf", "Mao2", "a4f2ad54a5d9bbecc1e3d1d1ee69cdbbe7bae8d5d8cbd8a8d35dd7f6e55cf5a3ccdad7dcda55", "Mao3", "a566cef6aa7dad67", "Mao4", "b455ab5fbbaab654ad5ab7e8c0b7d1d1acfed8b9ddd5cfe4e2e7cdbbd7c0de41e748dfc0e85a", "Mei2", "a853b7d1acdcaa54b1f6b443b2f9be60aab4c5f0b7b0b544d8ddd0a3e2fbdc53d8abdebbd751e871ca7adf75e15fecddf44b", "Mei3", "acfca843c1e2d25adcf6d9edd8c3d1c0ea54", "Mei4", "a966b441b44bac4ed2cebe79b7e8aa7ab04cdab6e4c9de71e7ae", "Men1", "b465", "Men2", "aaf9adccb1bfe5d2ebeaeab0dbaff9c7", "Men3", "e5c8", "Men4", "b465bf54c256", "Meng2", "bb58b7f9b5dec3a9c261c0dbc263c36aecdcbf5fea7bf4b6ad6aefdacd70f2a4efeae0d6d766e8f7eb45ebd5eec4f777f960", "Meng3", "b272bb67bb53bff8c36af4c8ece7dec1", "Meng4", "b9daa973f771f178", "Mi1", "ab7dbd4e", "Mi2", "b067c0b1c1bcc46ac3fbc153c247edddf46ef7f3cbcdf5b2eec5f8c7efe4f5f2f6e1f6f1f7e6efaaf95e", "Mi3", "a6ccc3fbabdaaec5d6a9e477d9f7dfbee76bed51f6e9", "Mi4", "b14bbb65afb5afa6b356aa63a851c1c4cc57beaddce2e96de8f2f2bbdd59e2b7a6cdcea2e258e26de74cf643e147", "Mian2", "b4d6baf8af76d8b6d4ede7aaf251f27af476", "Mian3", "a74bab6abd71b0c3ae59c053b542a85cb0c1cfe2df5fc94dcde9d94dd879f1c9", "Mian4", "adb1c4d1", "Miao1", "d870", "Miao2", "ad5db479bacbf85e", "Miao3", "acedb4f9c2c6c2e4bd7aaa48ace0d9e7aa57e6da", "Miao4", "a7aebc71c15bcfc6", "Mie1", "aba7c941aacb", "Mie4", "b7c0bdb0f647c14ef642efc5dbd0dda9ee47efcbeff1f47af977", "Min2", "a5c1a9a2aab3e6e8ded0d0a2cc78ccc9e0c3ccc5ec42d35eec4acc7ed4feddc3", "Min3", "b1d3bca7b67bbbd4a9d7aa7ba5d7b543b75de0efbf49d6d0cee8ca6ee4ecf06addbce65e", "Ming2", "a9faa657bbefbbcabfc1addfbd50ba5caffab955de48e3b2e0a5cf79e240dcf3ee79e051e2bb", "Ming3", "d6aece71dd6f", "Ming4", "a952ba5c", "Miu1", "d0f3", "Miu4", "c2d5", "Mo1", "ba4e", "Mo2", "bcd2bf69bcafbda4c155c55dbcb1c2d3c4a8f5c2e172f2d7f6a2", "Mo3", "a9d9", "Mo4", "a5bdb2f6c071ba7aa853bda4b9e6adafaa5cafdfaa6aafb0ad5bc55abea5b8e7bf69ea70e4c0ccebf3b1e46ef5ebf177efbbd6afea7ef2d7e5c9cefef26dcc45c945e4b1f368f0f1d6e0dbbedbc5e14be166e1cef0c5f6a3d772dffbedd5e14d", "Mo5", "bbf2", "Mou2", "bfd1b2b6c15ba6c8cbc6e7baeededbbfefadcfa8e4b5efa4cbedce4e", "Mou3", "ac59c94ee45e", "Mu2", "bcd2e5f5", "Mu3", "a5c0af61a864a969a9e6cfbce0beabbecea8d2e4", "Mu4", "a4eca5d8b9f5aaaabc7db9d3b6d2bf70b7fcbcc7a84ead60f5addde6e8afe0bbcd56cbf8d241d3bee1b3f17ed771", "N1", "a37aa3b4", "Na2", "aeb3d1b2ced4e7e3", "Na3", "a8baadfe", "Na4", "a8baafc7a76fb35bb675b1ccae52cdb0d3d4d7decab4d7d1e8ded6d5", "Nai2", "ecd7e5ba", "Nai3", "a444a5a4b069a6bbeccea960ccedd443ca4e", "Nai4", "ad40a960eb71e8f3cf55d0d2eb6ed9f2ebe5", "Nan1", "a65fc9c6", "Nan2", "ab6ea86bc3f8b3e4b7a3cf49ddc6eba4c9cfdfd9d778", "Nan3", "b369f7d9e7bcd9f5df76d96b", "Nan4", "c3f8d8c9", "Nang1", "f8ee", "Nang2", "c56e", "Nang3", "c4e4f8eff8f5", "Nang4", "f9d4", "Nao1", "d16f", "Nao2", "bcb8c4c2bef8a94cda71ccacf2f8f7a4e960effef2b3f6eff1f9", "Nao3", "b8a3b46fb7ea", "Nao4", "be78d5ef", "Ne1", "a94f", "Ne5", "a94f", "Nei3", "be6badfedb4e", "Nei4", "a4ba", "Nen4", "b9e0", "Neng2", "afe0f0a4e8f4", "Neng4", "c0d7", "Ng1", "a3b6", "Ni2", "aa64a5a7a967add9c04fa9cbd665e3eae84ed7edf3f3f1caf3cdf8a4f944d2f3cd5de7d3d4dcd646a94fcd62d16bdbf5e0b7f3ec", "Ni3", "a741a970c0c0f2a5e8f6b1ddceeecbf4cf46f0aeefe4ccbbd06fe4d2eef6f650", "Ni4", "b066b7c4b0cebfb0aa64b845bccad8fdf6b5f6b7e17ceacfd0b4d4cc", "Nian2", "a67ec248d6dfce70", "Nian3", "b1c9bcbfc25ba9e0bdfbbd56af47edcddbf9f655f3ce", "Nian4", "a9c0b0e1d5f9f5bca4dcf5b8", "Niang2", "ae51c45d", "Niang4", "c643", "Niao3", "b3beb8cdecd0bec5dcf5e772eb73", "Niao4", "a7bf", "Nie1", "aebae845f76e", "Nie2", "d07c", "Nie4", "c45ec2ecc65cc2bfc668af49c4d9f8a5afe5c941efbfeaf4f16edca1c56ad976f9aef741c4f4cd73dd51e458eab7f458f751f9c0f6dd", "Nin2", "b17a", "Nin3", "cee6", "Ning2", "b9e7beaec0f1c07bc266daacc0bef95df76bd8d1f4b2ecd1", "Ning3", "c0be", "Ning4", "c0d7a6f0", "Niu1", "a7ac", "Niu2", "a4fb", "Niu3", "afc3a7e1b673a7d7cb63cd55d770", "Niu4", "a9ed", "Nong2", "b941bf40c177bbfabebac2aaf2ebf4e5f9b9f854", "Nong4", "a7cb", "Nou2", "f4b0ed63", "Nou4", "bfaef155dcd9f4d1", "Nu2", "a5a3be71cc56d6d9e3ca", "Nu3", "a756a9b8d2df", "Nu4", "abe3", "Nu:3", "a46bd046d7fd", "Nu:4", "a7d7d17ed3d0d1d7", "Nu:e4", "ad68bac4eba6", "Nuan3", "b778ef4eb7dcd9f6", "Nuo2", "aebfae52f5c0d57bd5ca", "Nuo3", "e9d6", "Nuo4", "bfd5c0b6c47addabd1bde0a3ece2eacb", "O1", "b3e1a3ac", "O2", "ae40", "Ou1", "bcdabf5ebcdeb9c3f0ddc5c3a3b2e1d3b0cfe665e75ff250", "Ou2", "caa1", "Ou3", "b0b8c3c2b9c3bda2ca7eda42df78eaf9", "Ou4", "b9c3e278bebe", "P1", "a375", "Pa1", "ad77b8b4b0d4d3c1d372", "Pa2", "aaa6a5b6b55dafd2aa49d7da", "Pa4", "a9c8a9accacbd7bd", "Pai1", "a9e7b0d4", "Pai2", "b1c6b550b172add6f06cd9d3", "Pai3", "f478cdeb", "Pai4", "aca3b4fbeecedfd5", "Pan1", "bcefc36bcfe3", "Pan2", "bd4cbd59c2cfafebad44ba6ec2daeda8bdedf3a3dd5cead9cefdeff8e3d2dcfde1d9dbf0", "Pan3", "cbfe", "Pan4", "a750ab71acdfaf60a9e9d7b5ccf1f94bdbe2d84ede64cb58cfb8e4cb", "Pang1", "a5e3bd53b7bc", "Pang2", "aec7c365bb48bfc0b74be3aecdf7cabedca7d3efd178eab8db59", "Pang3", "dcdfeae5", "Pang4", "ad44", "Pao1", "a9dfd74b", "Pao2", "b354a948a753b0cca9b4e8f0cfb2f5bee4c6acb6d2bd", "Pao3", "b65d", "Pao4", "aa77afa5acb6af70cc43ecb3e8d7", "Pei1", "ad46a941a7a5e85bcf42cc5fd14ed3cf", "Pei2", "b0f6bddfb3adbb70cdd6dee5d9e3d849d379", "Pei3", "daa6cef1", "Pei4", "b074a8d8a84baf5ce8aecc6ed1cfd253c5afce72d6fbc9b5", "Pen1", "bc51e9de", "Pen2", "acd6da4bdfe1", "Pen3", "cbebf07bd6fd", "Peng1", "af79b269a9e1cc7be2a7bceaca71e0d0cec2dbfce8c7eaa6", "Peng2", "aa42b45ebceabdb4bfb1b84eb4d7c450c14ff0becba2d5f2f1bdded2ec40d0d6e84cdcbdec58ef68e57ee5e9f84c", "Peng3", "b1b7d6a5", "Peng4", "b849d4b8d56bd9ae", "Pi1", "a7e5a9dca4c7bc41c552cfecb351a541cbf2a7a5ca60cd5fafc4d2efb965e8efccaed6f8dc6dece0e47ce8c9e8d3", "Pi2", "a5d6af68b5cab55caa4abb74b0e0ac73b0f1a85deeb7ab40f2bcbd7dafc4d7efb3b2c567b965e3a8cf69cbadd7afe3ebcd68d341dc66ebedec77ee66f270ccecd666f2d3f7d7", "Pi3", "a75fa4c7a5d4b56cf1f1d0a1a5f6c979c9c8d4fde7de", "Pi4", "c4b4c550bbf7b742a7beb940c27df049e9a4e9eded57d5edd95ce276f8e5e8d6f059", "Pian1", "bd67b0beabf3bda1dfcfd8bedbece8baf5ab", "Pian2", "ab4bafe2c063ebabebc5dde1ec6b", "Pian4", "a4f9c446b94d", "Piao1", "c4c6ba7de1c9ee5ff0b7dcb8ecf1ede6f6a8", "Piao2", "bf5db9e2d641", "Piao3", "ba7dd767c165bf67d5dcf470e1e1f14ff26ef6ba", "Piao4", "b2bcba7db6d1c559e1c0edbff54ee75b", "Pie1", "bf68ba4ac97e", "Pie3", "ba4a", "Pin1", "abf7abb9f2a3d263", "Pin2", "b368c378c057c649c0a7f1f5f279", "Pin3", "ab7e", "Pin4", "b875a6c9", "Ping1", "a5e2ae5cd2dde8b9ee7b", "Ping2", "a5adb27ebeccb5fbabccc4abb5d3a957ac69ccf2ceb0cf6edafce075cde5cfcccb6ed06dd0b7cbe9e34ddb5bdbb2b6bed3b1dfa9cfb0", "Ping3", "daed", "Po1", "aa69bce2a959ab40f4facfded6f8", "Po2", "b143be49ed78efe5", "Po3", "bbe1ade5a572d6db", "Po4", "af7dada2be7aacc4aa79a6b5b2cbc3e6cc6ad273e3ba", "Pou1", "ade5ca7d", "Pou2", "d568b8cfcaebd1bc", "Pou3", "ade5dec0d9abd4e0", "Pu1", "bcb3a4b2be51bc50a5b7dab1f35fccb7eda3", "Pu2", "b9b2beebb8b2bb5ab5d0a6b5c3dab2e3c0e4bf5cab6db340e3bcf0d6e472b07af4f5f359f4afe54e", "Pu3", "b4b6aefaae48c3d0ae45b7c1d650e9e8f4eae656bba7", "Pu4", "bcc9be51c272c36ee745", "Punctuations", "a141a142a143a144a145a146a147a148a149a14aa14ba14ca14da14ea14fa150a151a152a153a154a155a156a157a158a159a15aa15ba15ca15da15ea15fa160a161a162a163a164a165a166a167a168a169a16aa16ba16ca16da16ea16fa170a171a172a173a174a175a176a177a178a179a17aa17ba17ca1a1a1a2a1a3a1a4a1a5a1a6a1a7a1a8a1a9a1aaa1aba1ac", "Q1", "a3a2", "Qi1", "a443a964b4dbb1adbaa3b4cfb17eb259ac6db5d6bca1b7cbcb50e7d5d7e9d4d3f8dce14ef550d551e24ee6c5d0cece48d1e1c1c6d0e2d4a7d54ed5c3e0f5e368eaa3ec51f1c1f3dcd972", "Qi2", "a8e4b4c1bbf4a95fba58c34dace8b4d1b852f9d6aac2b154b561a7c1aa5bb558c451c55fb2a5c2c0ace9afcfb24ed7d7aa4be375f1afb04ef4bfa7a6c042d1d2db6de3dbd4c3e159f4c5e0e0ece3f4b7d3ced7ddf0adf35df3d5f567d3bdebf7d5a4cac8dee9db44d843c951d3c3def8e4dee7fbef6bf3def3dff7e7f963ed59", "Qi3", "b05fb1d2b05aa45ebaf6a7fbbd5de376c9d7d9c9d973cb7dd4e5ca55cdbccaa6", "Qi4", "a5f8aef0beb9a854b1f3abb4ace4aa5fa8b4b057c9fdbecdbd72ab45dfc2bf6cd1edb474a964f2e6f364cd79d3bdc9e1d9e8c961ebaed9e9e6acf879", "Qia1", "d574", "Qia3", "a564dc61", "Qia4", "abeaaca2ceb1d94bd5dd", "Qian1", "a464b95dbe45c3b1b26fc1bec5d2b44fa561a6e9c648c4cab75edcc2e1c7ba53eb72d049cac0cb4cc164cba1d952c9e7efe3f66ad4eedf6df243f44ef4d2f774c9d1c9e2ef49efabf256", "Qian2", "ab65bffab0aebce7c072b958b040bae3b678d57ad8c4d961ea48ccb5f1bff5d5efafcae5caf5cac5e279dfb0e8ebf3b4f6acc9b0cc46d3c6d7e1e24b", "Qian3", "bbbab24cc4fef4ade256e5afc9e2e3f0", "Qian4", "a4edba70adc5dd67d37db9d5cdc0d853dccbe5dec164eac6e366d9cee3c8e848", "Qiang1", "ba6ab5c4c2f2aacab6e6b76dc3f2f366e3d6eebeccc2e2d2d9aaf142ebe1cd7be1acb14ee2c5eea8", "Qiang2", "b16ac0f0c1a5a9cff9d9e952c0cec962e27cf5fbe970beca", "Qiang3", "b16ab76dee75eaaadcc4e168c166", "Qiang4", "b6e6f5eed476e2c4", "Qiao1", "ba56c1eabef5bcc0c3dfeda6f354e54be96bf074f1baf664f374dcece470e94aec6ad175dc57e8b7", "Qiao2", "bef4c140b9b4b3ecbef6c2bcbcaceb4cedaec3d7f06bf34eea56e142e548e558f34be9b0", "Qiao3", "a5a9aea8b473c44eb3b6ea4ee8b7", "Qiao4", "c2bcc2acab4eae6bc054bba6bcc0b4dfd173e9a9f4d8", "Qie1", "a4c1cb50", "Qie2", "ad58a6f7ca47", "Qie3", "a542", "Qie4", "a4c1c5d1a963a9c4b467aeb2e6d7c1e6abb4e1f9e7f5f3d2dbb7e368f0b5d25e", "Qin1", "bfcbab49b4dcd3daef5dbc6bdf5cf25ce86a", "Qin2", "b6d4b55eafb3b856bee0aae0ecfeecdfbeb2cdc1eb5edc74dd41e5c2d368e0dde9fdcad0cdadd3c6d7e1dca4", "Qin3", "b9eccccfd8d4e9b7ee60caabef48", "Qin4", "a847bcc3d0f7db6b", "Qing1", "b24dab43bbb4b6c9adebb242bb66b3bcc44ad4abd9e6cb67d7f0", "Qing2", "b1a1b4b8c0bab6c9c0d2d0edd5dae5e0d5de", "Qing3", "bdd0b3bce1b8", "Qing4", "bc79c16abfcbd0e1e376f0e7bf6be653cb4df76ae4bed5a2deedf2ba", "Qiong1", "cb7caac6e4a9", "Qiong2", "bd61c3a3cb7caac6e072dbbcd946ca54ea63f2c8e6bdde72d6cce076f2d5d1e0d7d5dadfe9d5dfb3", "Qiu1", "aceeaaf4a543b34cc2fec4cff5aedddfcbfadfc7d45ae6e6d8cfe75febbbc074cecfe7bdf0ccf644", "Qiu2", "a844b279a57da4b3ada9b8cae07db241aa73f7b5d7e4cddec958e6a5df5bca4dcdc8e7a3e447e453dab9e867d84eecb8d0b0c9a6c9f0b1fcd444de75d076d35ad747d75cd8d9dcc1dfe4ec79f1ccd5db", "Qiu3", "eac9", "Qu1", "b0cfa97dc558c1cdc2dfb9f2a6b1b349c2a3d7b6e5beb5f1ca5dafa3d058cc60d2e7cbdcc942ccb6cdd8e8a5ec76f3e2f85cd6e5ec71", "Qu2", "b4eba757c454c5fcf0d1c2a3f7ecc0f3f6e7f5f8edaaeaf8cefadc43eca9d6fadfc9e057e979ee6bf1e7f3fdf5d6f6e4f745f8bef951d061cee9d5f8dba7efa8", "Qu3", "a8faa6b1b0f9c654cfa6d6e5", "Qu4", "a568bdecb0f9baa3f2f3eef1da40ecb2ca6df1e1", "Quan1", "b0e9d1aad9afcebcdafad557", "Quan2", "a5fec576ac75b8e0aeb1bbcdb2acf9afbb6cdae2a8f7affef1bbd2a1e079a8dea4fcbdf4eec7ced1d4cfda68e041ec68f5caf6d4f8bdce74debee070ead2f9a3", "Quan3", "a4fce365aab6accad66ef946cb51b0e9", "Quan4", "c455a8e9d2a2d279daf3", "Que1", "afcac2f6e3c5", "Que2", "bf61", "Que4", "ab6fbd54c44eb3b6a9c4c2f6ba65dd7cabf1b4dfc1f0e1c3d14fdaccdee7e6c1f05bdad0ded6e269f5e1", "Qun1", "d7e7e45fd16e", "Qun2", "b873b8c8d167", "R1", "a3a7a3b7", "Ran2", "b54dbf55be77d7a3d7a4d7b9", "Ran3", "ac56a554be77ad5ccfd3e9cfcbe4cc49e17b", "Rang2", "c463c5a1f6f8f1eef45bc57bf1ebf46df5f1f8c4f9b6f7f7", "Rang3", "c457c45bc463f5dc", "Rang4", "c5fdf44a", "Rao2", "c4c7eafebc63bef8c2ccf0d2", "Rao3", "c25a", "Rao4", "c2b6ebd0e8ab", "Re3", "b753d86fad59", "Re4", "bcf6d9fc", "Ren2", "a448a5f4a4afa4d0d351a449cdc6e4b9", "Ren3", "a7d4b85aaff6db50d9c2d1f4d765", "Ren4", "a5f4bb7ba462b6b9b8eeb062b04dacf7a7b3d1a1a551d3ddb6b4cb60efa6c9d8cb74d7e0", "Reng1", "a5b5", "Reng2", "a4b4cb72dc7d", "Reng3", "a5b5", "Ri4", "a4e9d3d2e4d4dc73", "Rong2", "ae65ba61bfc4b7bbb5b3bab2a6a5bb54c2e8aff1ba5fdb41c0afe2cecb78d243cfc0f267d376d653f4c6effcdd44e260eb79ec63ec6ef6a9f7b7", "Rong3", "a4beaff1e9e6d85fdc44", "Rou2", "ac58b47cf1a5bfe4ebcaddd6c9a8dfd7eee2c2fdf3b6f5a2d8c6e7acf571", "Rou3", "e6dfeee1d34dde6e", "Rou4", "a6d7", "Ru2", "a670bea7c0a9aff8c4afc07dc0e1dbccf4cbefa7dae3f07df65dd1b2f0b8e4a7efdcc277ceb4eb51", "Ru3", "a8c5a6bcb064ece9a46bcbc7", "Ru4", "a44ab064bfc8c0a9aff8cf76ead0e3bdde50e0a6dd40dcd9", "Ruan2", "d8a3eccae5b5", "Ruan3", "b36ea8bfc4afd052e7abf041e6e4f27dccd2", "Rui2", "eb42e36fd4eb", "Rui3", "bfb6e9d0f075d8fbd5bd", "Rui4", "b7e7be55cdbabacdd3c2e8fbccd9cb55", "Run1", "da69", "Run4", "bcedb67ce9db", "Ruo4", "ad59ae7ae6d9b0b4f26bdc59bf78e3c0ddd8c564", "S1", "a3aa", "Sa1", "bcbbc965", "Sa3", "c578bcbbe0dccf73", "Sa4", "c2c4a4cad7d9bbe3efd6e4d6e4bc", "Sai1", "c4ceb87cd242d96c", "Sai4", "c1c9b6ebe4e6", "San1", "a454b0d1e5f7f44df6a6", "San3", "b4b2b3caf06fc158f4ed", "San4", "b4b2dc7b", "Sang1", "b3e0aee1", "Sang3", "b6daf3a8ddbae6caf162eb7b", "Sang4", "b3e0", "Sao1", "bfb4c4ccc162b76bedebdd69de52f3aef8d9", "Sao3", "b1bdb741d4b5", "Sao4", "b1bded4de6b1", "Se4", "a6e2b6ebb7e6a7a3b6dec0dfc2a8e9ecf4dbf64fe4a3ed6cdf70ea5af775e9fc", "Sen1", "b4cbe778e5dbdf69ee78e1b4edc8", "Seng1", "b9acf7a5", "Sh1", "a3a6", "Sha1", "b1fea846afbdace2b2efb7d9c354b8c6a7fcdaaff36ae8dde5d9d2a3d546e1e9e771dacd", "Sha2", "d4a3", "Sha3", "b6cc", "Sha4", "b7d9c04bb748dcd3ddf7e351e37cdb67d86c", "Shai1", "bf7a", "Shai3", "bbebf2b5", "Shai4", "c5ceaecdeef3b1fe", "Shan1", "a473aeb0ad6da7fca752acc0c3bbad51bab4bce8b65ca96baadfd073ddb5ba55c168eab1d57dda5bcfc4d6d3dcc9", "Shan3", "b07bd445dedbd9a5e7ce", "Shan4", "b5bdaeb0a6c2bed5bfafc2b5e854bab4b053b3e6c4baaab7c5ebf562e54de951d56ce1dfeeade552d7fcf2dcd3e4e4e7", "Shang1", "b0d3b6cbbcdcc2d2b4f6e2b9e74eee59f0daf6a7", "Shang3", "bde0aecea457", "Shang4", "a457a97cf5dcce73c967", "Shang5", "bb6e", "Shao1", "bf4eb579b1e9dfa5aeb4d17adfead776df4bddbeef65e466f1cdeb4b", "Shao2", "a840bbe0a8a2a463cfd0c9cacfb9", "Shao3", "a4d6", "Shao4", "a4d6b2d0adefaaf2a56cca73ca6fd7b8dabce64c", "She1", "b0f8bbadce61ed42f0e0", "She2", "b344a6deacc6ca65a4b0d960e0ae", "She3", "b1cbaad9", "She4", "aac0b35dae67af41aad9c4e1b36abef9c565cdf8d669f5d4e751f1a6f1b7ac42b8add1c8f2e8", "Shei2", "bdd6", "Shen1", "a8adb260a6f9a5d3b2d4a944ab48b0d1ae57b2f1d2c0cbc2d045dfdee04dec67ea50af7ecf5dcf6bc9d9cfcad05bca58cc50d170d2d1", "Shen2", "afabacc6", "Shen3", "a848bc66c254c26ee7dcf75acfe8ab7bd4f2ed7bcba9f754", "Shen4", "b756b5c7baafacc6b8c2a847dfb8ddd2b2e9ccbdcdece87a", "Sheng1", "a5cdc16eb3d3a4c9acb9aa40b563b2c6b0a5cd4ee0c8f1e6caa2cd64da54da64f3ef", "Sheng2", "c3b7bf49e97af4d0f8d8de68", "Sheng3", "acd9d2d6cbcee6ded466", "Sheng4", "b3d3b2b1b874b3d1dd4fadbcc1cbc96fdbeb", "Shi1", "a5a2ac49ae76b8d6c0e3b7c3b7e0abcda3a6bdbebc4eaaeba472e3b9dfade4e3d0b9da4fd6eaf6b0de69f6c6e6d6ee77f948eb6b", "Shi2", "a451a4b0a5dbaec9b9eaadb9ac42bb6bbad3ae67b4a3e3c2da41f6adb6f6d2e8f1e5e0c6e24dd9f3de63f3f6d8d3", "Shi3", "a8cfa96ca576be70a5daabcba8a8", "Shi4", "a5abac4fa8c6a540a468b6d5c3d1abc7a5dcb8d5b5f8a6a1a4f3be41c4c0b9a2a8cdbb7db375b6ddabeea54bac55a8cfc1b1b749bebdabf8b361d8bab862afe7b8fdebacdbeabc5dcae6e9f5eba8f64be0b0d969e4add0fce6fae8a4eeb0eec3f066f56cf5bae06dd272d8edd8f6dbd7dd72e7c9f8c0", "Shi5", "b0cd", "Shou1", "a6acd3a7", "Shou2", "bcf4", "Shou3", "a4e2adbaa675d953e746", "Shou4", "a8fcb0e2b9d8c37eb1c2bd47acbcbafe", "Shu1", "aed1bfe9aeedb5ceaedeb2a8bdadbccfd356a7e7efd2ce67e5cce1ddc95fcce6d0c7df59c0cfcff6d7dff3f1f2cf", "Shu2", "a8fbbcf4b251b9d1c5abb145b5e0d2edf2edd4c8d65ae461f8e2f9a5", "Shu3", "bcc6b9abc4ddb4bbb870c1a6b8beb6c1f04ce661c3c5f9c9d4e7f649f2adf772", "Shu4", "b34ebcc6bef0a7f4ad7ab870bdddb2a8aea4b166c0c6b9d6baa4b0bfa6a7e640df6fccf5dff2e0b4d8d7f1ecf36ff57d", "Shua1", "a8ead47cef6d", "Shua3", "ad41", "Shuai1", "ba4cb049eacef5c7", "Shuai3", "a5cf", "Shuai4", "b276abd3c1acce4fedd2", "Shuan1", "aeeaadacac43", "Shuan4", "b252", "Shuang1", "c2f9c1f7c45cf8bbf9b4f7b9f5c8f6f6", "Shuang3", "b26eb9d7e5e6e2b4e1d4eadc", "Shuang4", "f466", "Shui2", "bdd6db4f", "Shui3", "a4f4", "Shui4", "bba1baceb57cb8c0d174d258dff5", "Shun3", "acdedde3a76dd970ebb7", "Shun4", "b6b6b5cfc0feeb48f3c3ea76", "Shuo1", "bba1", "Shuo4", "aed2bad3c37bbcc6c5e0dcdeb276c1acabd3dd7da671e254e6d8e3b7a463d5d6dd78e67cf161", "Si1", "a571abe4b4b5b5b7a870bcb9bc72c5eebc52a3aae642e6ebd454e37af1abe6cdd3b8ddf1eed6e140cd47eb57e0c2cdefdbd2e253e340e3f1e6c8eea9f0cff6c2f87c", "Si3", "a6ba", "Si4", "a57ca6fcbde7b6e0b97da678b876aac1ab53a6f8aa72a478b2e0ecbea971d6cebe6fa8e1d25dcf4ec9fad1fbe059ee41d249", "Song1", "aa51c350b253b743a7d8db70ce65b15dea43d0dbdeeee3dd", "Song3", "c171bca3aeaadadcdcc0dd6ee1a9ef5b", "Song4", "b065a7bab97cb35ebb77", "Sou1", "b76ac442e0aabb60dd60de59c349deaeeec8dcdbf15cf55e", "Sou3", "adeeb9bec3c1c25de6bceea7f5e4", "Sou4", "b9c2", "Su1", "c4acb564b670bf71c5c8f45a", "Su2", "ab55", "Su4", "b644b374afc0b5c2b14ab6eca667b5afb7b9e8c4e1c2bdb6e448dd68e3a5eea2b6e8e9cbcd41d250e646c150e75ce5cfe853f77bf859f865dd42c9a7e25acfa9d1e3d857de4de5a5e879eadef2cde0f4", "Suan1", "bbc4b56dd2a9", "Suan3", "e8fa", "Suan4", "bae2bb5bdf48", "Sui1", "c1f6b86bea41b846d768de42d6aad267d143d163d76fde44", "Sui2", "c048b6a6f173", "Sui3", "c5e8e967f261f172f8cf", "Sui4", "b7b3b945b848c14ac047afa9c0e6bdd9ded9f060ed67ecf4f2eaf661c2e3d4bde7e8ed48edd8f05ef249f2b1f544", "Sun1", "ae5db6b8bb5edeacddbbe25fedfeeb4e", "Sun3", "b76cb5abba67f069f168", "Sun4", "bcf2e1d2", "Suo1", "c159b1f4b2efadf6ae50bf75b6dbd854d566bb62d5c4f0f7d761e456e1da", "Suo3", "a9d2afc1c2eababee6a8dcd4e1e2f163f540", "Suo4", "d7e2", "Symbols", "a1ada1aea1afa1b0a1b1a1b2a1b3a1b4a1b5a1b6a1b7a1b8a1b9a1baa1bba1bca1bda1bea1bfa1c0a1c1a1c2a1c3a1c4a1c5a1c6a1c7a1c8a1c9a1caa1cba1cca1cda1cea1cfa1d0a1d1a1d2a1d3a1d4a1d5a1d6a1d7a1d8a1d9a1daa1dba1dca1dda1dea1dfa1e0a1e1a1e2a1e3a1e4a1e5a1e6a1e7a1e8a1e9a1eaa1eba1eca1eda1eea1efa1f0a1f1a1f2a1f3a1f4a1f5a1f6a1f7a1f8a1f9a1faa1fba1fca1fda374a375a376a377a378a379a37aa37ba37ca37da37ea3a1a3a2a3a3a3a4a3a5a3a6a3a7a3a8a3a9a3aaa3aba3aca3ada3aea3afa3b0a3b1a3b2a3b3a3b4a3b5a3b6a3b7a3b8a3b9a3baa3bba3bca3bda3bea3bf", "T1", "a379", "Ta1", "a5a6a54ca66fa865b6f2eb7ccda2e6cf", "Ta3", "b6f0e247f158", "Ta4", "bdf1ba66c1cfc3a1ddadbbbdecc5c4becceedcd6bed8bbbef66bf159f16cebfdeefef3a1f6aed04fd5f0d85ae26be7dbf76fbaaacdd0ed4ef9d5", "Tai1", "ad4cad61", "Tai2", "a578bb4fa9efbbe4ad61cdd7b660c269c2cacfb1e8ceec7ce8f5ecd5f4a6cafbd2f0", "Tai4", "a4d3ba41aef5a84fdc67ed60de5eca79d856", "Tan1", "b367c579c575c5f5a77ecec0ccbed752e364b1b4", "Tan2", "bdcdbc75b7f0bce6c3d3c0c8bec2bee8c2bbb5f7d7e8ebe0ec5cf77af4ecd0cbf35ef347d4dfe5a1f2c6e9c5f6ccf867", "Tan3", "a95ab4e0b352f2e9cad8edafdb65f34ae154ede8e5abebd8e3f6", "Tan4", "b1b4b9c4bcdbbad2acb4e7eed4bcda45e6f3", "Tang1", "b4f6c3edf8e9f141e7b0", "Tang2", "b0f3bf7dadf0b6edbda3c1aeb4c5c1deb765c3edde46eb5dbac1eeb9e1fde5e8e2b5e2c1f15ff378e9d9e3b1e6c9ebc3edfdf6b3", "Tang3", "add5bdf6c56cb249a9aed55cf9bff166f7daf8aaf8b1f8f8", "Tang4", "bdebbf53f4e7e1f2", "Tao1", "b1c7c0dcb7cac5b9c3fccc71b86cead6ddb0dd6de24fdd5be37bdd45e3e6", "Tao2", "b06baee7b3b3b5e5b25ec0dcb0deacabc276c268cbd7ce42e370e4c3e860f1b5ebebec66def6ec41", "Tao3", "b051", "Tao4", "ae4d", "Te4", "af53bc7ccad6cad7e869d3e2f0c9", "Teng2", "af6bc4cbc3c3c4f0c1c3bcf0eb66ead7", "Ti1", "b1e8bdf0ade7d649", "Ti2", "c344b4a3b3dab3f6bfe1ebdbe2fddad7bd7bd377f3bbb6acf5a5d94ecdf6eee0d456ebbceea9f578d8eae2e3e7afeb4af867", "Ti3", "c5e9ca5edf57", "Ti4", "b4c0b1a7aef7b150aeadab63be4fc0a1d0d7ee4be5f3e3fcd956f4a8f1bcd552e7c2b37cf1cf", "Tian1", "a4d1b24bd0ddcc5adc5fd4ec", "Tian2", "a5d0b2a2b6f1abefc2f5accbe6d4ccfacfe5d9ebdbb0e6c3", "Tian3", "bb51a9bdcf66b5c9c053d5eee4cee7e9d562d3c9d9a7ded1", "Tian4", "d56dde6ce2d0", "Tiao1", "ac44d6bdcec9ceb9ef6f", "Tiao2", "b1f8bdd5d6d1a8d9ad7cbb6de8d4cc67d071f5bbf7b2ec55ca4cf16be066d2eb", "Tiao3", "ac44b2c0e04bce77eccf", "Tiao4", "b8f5b2b7f8fdd1d8b8d0be66daf8eab5d36d", "Tie1", "b64ba9abcca3", "Tie3", "c54ba9abf852e0fd", "Tie4", "a9abc34bd7a6", "Ting1", "c5a5c655a5c5d5b9ca4bcdaa", "Ting2", "b0b1ae78a7caab46b8bbbe5eb440d9ead76cc9efdf4de7bbe6fbdfacf5b9ddcae257e8a8d8ebdf5e", "Ting3", "aebcb8a5cb6db1f2ec5bd670d74de86fd658c96ecdee", "Ting4", "c5a5", "Tong1", "b371abf0e766d6a2cfb5e66bcfc3", "Tong2", "a650b5a3bbc9aee4bce0c0fba7cdca63b9adabd0cbbef0a2e9b3eaf3edb1ede2d6bbe9bfe9e7e677d3a6d275d268e0cbe4d0c969e0acd3ebdaeadaf0e9bdea59eafaef6ef1e8f6ecce40e04a", "Tong3", "b2ceb5a9b1edd1b6ce54df4ace6f", "Tong4", "b568dbc2ba45f749", "Tou1", "b0bdd8c1", "Tou2", "c059a7ebdea4d7f3", "Tou3", "efaecc44d359dc6ff5f5", "Tou4", "b37ae9b2", "Tou5", "c059", "Tu1", "a872f1ddd260d5a1e1a4", "Tu2", "b9cfb37eacf0ae7bb6eeb14fa559b2fed25ca745bbc6dec8dad9df7ed172dfabf1ddd1cccca8eeece459d5d3da4cdf50e3ade6abef62f577f7bbf7c9dd53e1b9e2a2f7c4", "Tu3", "a467a652d841cb7ad147", "Tu4", "a8dfa652b5e9f3e6d4cb", "Tuan1", "b4f8de7eebb2", "Tuan2", "b9cee1dec47be277dcc7e1c6f371f861e5e5", "Tuan4", "cebde7ca", "Tui1", "b1c0e761f2ce", "Tui2", "c05af2a7e8aaf1c2e9d3e0f9f352c9de", "Tui3", "bb4ccded", "Tui4", "b068b8c0ef61eb61", "Tun1", "a75de9b4d474d24bccce", "Tun2", "a4d9a779b362b6bbc176d7dbe8e1cadccdb5caa4ced7", "Tun3", "c9f8caa4e2d8", "Tun4", "bfc6eb61", "Tuo1", "b2e6a9eca6abb055d8adcbc9d1bec9eccd7ecd4be0e5cde7dbe1e4df", "Tuo2", "be6daafbb9a4aa62a6efc06bb659e9d1cc40d6e3dc5dd2d9ca57ec73cc5be2f6e4c7f7a2f965e0aed7b2d84f", "Tuo3", "a7b4bef2e5bbd549e557", "Tuo4", "a9ddb3e8ac6cf6fbf4bddbfbddfdd1fe", "U1", "a3b2a3b9a3ba", "U:1", "a3ba", "W1", "a3b9", "Wa1", "ab7ab5ecabf5badaa94bb445cf71ca48de43d2fbd6cae270", "Wa2", "abbd", "Wa3", "a5cbca5f", "Wa4", "c4fbdcdae3a6", "Wai1", "ac6e", "Wai3", "afe6", "Wai4", "a57e", "Wan1", "c657c573bddcade6b2f0bb64c9bde655", "Wan2", "a7b9aab1b978a459a6c5d04bcba3d64ad4cecac1caea", "Wan3", "b1dfb84aaebea97bb0fbae59b570bbb5b2f0d246bb64dec4db60da7bec56baedd9a1e377f1c3d0cad74eded8e864dac2dfcb", "Wan4", "b855aab1b5c3b17bc9c3e6f6cadac9badf64c945ee63d567e7f3", "Wang1", "a84ccabfa471", "Wang2", "a4fda460", "Wang3", "a9b9baf4aa50aac9b1a6c353bdfeefebca49d9a4db76db52", "Wang4", "a7d1a66bb1e6a9f4a4fde1fbcdcdd75a", "Wei1", "abc2b451b0b9b7dbdfbbdc7eb66ad26bdddbda44e2efd94fd96ddfdadc7cde5ae050e7a9e7d0ed61", "Wei2", "acb0b3f2b74ca64db0dfbafbb1a9b948adb3c1a8c4deaee9c1f2c0e5b163dd52b457c949d9f8de57dc51eee3ef74e65ccfaaf4cce861f66ff262eff4f04ef6e5", "Wei3", "a965a7c0b0b6bd6eb5e4bdd3b8abb7f5b554de6df6d6e0d4ae55f1a4d8d0aca8deb3f0a9f0b6f671c243e6c7dfafe8bbddc2d67ee0e9ddf0d24cdfa4cdb7eee7ce7cf1f7d87ad8f7df79e3e5e4e8e770d542d6b7e843f7de", "Wei4", "acb0a6eca5bcc351bdc3a8fdb0b0bfd7ad47b3debca2c1fdb14cb4f4acc8bdabf74ce7b3f6eebff2f6d6f37de6c4eae0c1baee42d8bce3e8f2d8f362db73e674ec5ef0f6f759f763bf71ec75ecde", "Wen1", "b7c5bd45eec1b6f3f3b3e2eaeeb4e267", "Wen2", "a4e5bb44afbeb041aab3b6b2ec4ccd54cdb2daa7ec4aeef2efb2e4d9e8e0e8e4", "Wen3", "c3ada76ba646cbead5d5", "Wen4", "b0ddbb44afbfa4e5a85aa7eea74bddaff46fcab9", "Weng1", "afceb6e4eb6ff6c8ec53", "Weng3", "bb63de5be1f6d266e6bfeae7dce9", "Weng4", "c27ccfd8f8eaf2b9", "Wo1", "badbadd8b4f5b8b1da73e841", "Wo3", "a7dad4d6d5a6", "Wo4", "b4a4aad7a855b4ecba57c653d8f2d5e2d451ed52da5f", "Wu1", "abceaf51a6c3a6bea664bb7ab6e3a7c5c2ebe0a9cf72e264a3b9b463a9f3cafed0c5d46ad6c8df77ef7aeb68", "Wu2", "b54ca764a75eb1efa7c5bfbeadf8b8bcbb7aa4f0a460d65ceaf0f1dfc4d3d3f5e86be866d16dd24fd66ccde1f1c5d762f869d264eda1f2fe", "Wu3", "a4ada4c8aa5abb52ab56a5eec44dbcadbc61e64be575c9aecadedee6ed71ddb3d4a4aeb8dd54cd6dd0dae9ddf656", "Wu4", "a4c5aaabb0c8b463bb7eaea9b1e0c3faa5b3c2ebb6f5a461c445b9edb063cb42d8b8f5adb0eecb57cdd1ebd2e874c9d6c9e5de7ccdf5d651dcaaca56d34fcd7ccdbed4c1d7e5dab2f3f7f4bacac4e4fae767", "X1", "a3a3", "Xi1", "a6e8a7c6a76cc4e2bc48c4ebb57db178b7cbaa52c1b5bab3c148bda5b4cfc2e7bc5ea4bcb552b4b7bfaab2a5c466b9afbb68caedbf51ae4fcfe6f94cc3d6b1e3d5d8c1d1e9caf445b258ded5ae44b26dd85ddd63cec5eab3dae8e451f151f87bd244d257e652ed5ef6f3cfdcf65cdd47f172d1a9dac0d6b4f8bff972e250e9e0f46bd677eb65cde6cebecebfd15dd16ac1c6d769db6fdcbee5dfeb6aeeb5eeb6f1d8f55cf9c3d0bed5d0d949e8f9f547e44deda7", "Xi2", "b2dfa9f5aea7ae75b1a4b740bffcc5a7bab6bb56c1b7c0cae444eef5e3fce1afeb67f7b1db4be5d5da62f0dff169d1f6d9b6e3cde6b3ea5fee4ff37bf552f679e7a4", "Xi3", "b3dfac7eb170c3a2c4cee1a2e775f8a6cf56f0bdeddcf8fef143f971c943d2a7eba9edc7dfc4e2abe9b1", "Xi4", "b2d3c0b8ab59a874c3b4a469a6c1bbd8bef9f1beb5bfcda5cdfdf8a8df62cdaee0abf151f1adde67e7cdf65cbcf3db57aabff972c96dcca7d7fbf15bd7fae05dd3fde2bfe7cfeb4decb5eea3f0bacc79ceced962e2f9f7cc", "Xia1", "bd4dbdbccac2e0e1eed5", "Xia2", "b776ae6cc1d2c1f8ab4caf55aeb5a758a945b949dac6aaadb7e5b1d7c35cac6ad6c1aca2dfa3e2f5f3badda1d27acbcfd6dceadad2bbb0a2e6c0ebbaec78ee45", "Xia4", "a455ae4cc07eb748b776ede1cb79d1f8f367f6b2", "Xian1", "a5fda550b1c8c241c5d6bee6a96bf443e9a2f75fe479aac4ef44cf5bcb49f3b2e957c96ac977c9d0ccdccae0e647f96cace6dcb9e148e3d0ee73f447f7fdd2b9", "Xian2", "bde5b6a2b6fbab77c4d0a9b6bbceb2cdbc5ff9dcb243b0e5b2ecb67eed77eba3d77de5a7f870d4e6dfbad056dbb8e6f2ea47f479f871d4a1", "Xian3", "c049c5e3c241c57ec4f6bbd1effbe06ee964b8c3ce68dd4bf1feea60ed64f7e8dae6f850d240d276eedddda3f87af8ebd7d4f242e342", "Xian4", "bfa4b27bbd75adadbecbc46db872b3b4b8a2c060b8c3b341c4c5cde4b9b7ae73d5abdabdeeb1f657e87cd262f265df56d162e5b6ebecce76", "Xiang1", "b66dacdbadbbbd63b4f0c1b8c65eb45bf9b3e6e7eb52c4ecf7eef5d2dfb9f448", "Xiang2", "b8d4b2bbadb0b5beabd6", "Xiang3", "b751c554a8c9bbe8c557f3d0f959d1d6", "Xiang4", "abd1a656acdbb9b3b6b5b648bef3c251e9b8f0cedfddeeeff0c7f0d7f541b66dced0e64df85f", "Xiao1", "aef8be50bfbdc374ae64b370c4dbc2adb576be5dadfdc5bbb1faf74ecf4aef69eca6e4f9df60b9cce263e646d26ee6a1d3b7dfeadab0e57dca41cbe2edb4cf6dd251dab4dfbfe45deaeaf0a7f457f564f7e3f947d175d4aadadbf672f0e2", "Xiao2", "bec7cf6dd342d7f1", "Xiao3", "a470bee5df4ec151eea7", "Xiao4", "aed5afbaa7b5aec4bbc3bc53a876b3cbcec1ea53e45a", "Xie1", "a8c7b7b2c3c8e7b2da74e7cddcce", "Xie2", "a8f3be63b1d7afd9bfd3a8b8b0babe65aeb5daf4c4e2c25ebc45f5e9f648d746dd71c9c0e7bece5ccedbd044d15af9a1dd6addb2debae2c3ed5f", "Xie3", "bc67a6e5", "Xie4", "c1c2b1f1acaaae68c26dbed3a8f8aa6ec3c9b8d1b150c1b6ba6babb4c062e972d9f1c1dbc0e8b7a4daf2edfcb2d8d8b7e963e9f7f263ea5ef8c3cb5fd2c9f1a1e4daef5ad44cecfbf3fcca67cab6cff8e24aec57e561d65bd95bf6d3f8c5", "Xin1", "a4dfb773a8afc17eaa59be4ec4c9f8cab2f1cd51ddf5aae4a9fdb360dc63cfe7d860e574cae3cabbe946", "Xin2", "b44de856ccdfe9aff0d8", "Xin3", "c9b3", "Xin4", "ab48c65daae4da5cf4b5eaf2c9c7cabbde76ca58", "Xing1", "bfb3ac50b556b87bc4c9b469ef58de7adebcd060d153dfe8ee7cf9b2", "Xing2", "a6e6a7ceabaca644a8b7b0a4b2bae478ef4fcbb6d278cfadd36ee87bed50", "Xing3", "acd9bff4ececd9fb", "Xing4", "a6e6bfb3a9caa9afa96da7f6adc6b1a2d3aed4d2d763d5e5", "Xiong1", "a553a5fbafdda4bfa649aca4cae2ce46cecc", "Xiong2", "b6afbab5e05c", "Xiong4", "e5c0dbdb", "Xiu1", "add7a5f0b2dbb2e7aba6cebae05aec70f3afefa2e2aae5eddb56d3aae4b8e774eeebe2ad", "Xiu3", "a6b4b14aeac8", "Xiu4", "a871c2b8c4c3b353b6e5b14aafe4f9d7d671b7cda9a6d2b5c9a7e268e7cceb69", "Xu1", "b6b7bbddb5eac5bdbc4ebc56a6a6ad45b058a653e9dfcd77e559f4acd1fccaf9cbe6ddd7ecd2f768cf64d0d8e346e6e9e7adeb53f7a1f7a8d1d5d8f3d963e6e0", "Xu2", "ae7d", "Xu3", "b35caeddb7d6aba6e048d0dfcc4ad9faeba5ebdae859d2b7d872", "Xu4", "a7c7c4f2bb57bafcb1d4b5b6a6b0abf2a8f9b3a4b442af62acaec9eecbc4dd66e2a9f2ccb97acdb9f0ace8d8d46db1e5dbd8f95bd277cca1d154df43ed7ce4b0cd45cef3e2e2", "Xuan1", "abc5b061b3d9deb1b8a9b779c0a5e4ebbfdcdce4e953d955f2bfeb7ed94aaecfeedff6c3d5ccb7dcdfc5d950ca69cccce86dd8c5eaaee7a1f2e0f475", "Xuan2", "a5c8b1dbc461ba78e6a2c27bca66cc4bd66fcfcbe17ae7d6c1d9bfa4dfed", "Xuan3", "bfefcdfad26a", "Xuan4", "acafb5baba78af74ccf0b4e8b1dbd6adddc9e5c0b962d7b1e77cef60ec54f361ceecddddd7b4edd1f758f845", "Xue1", "c1a7b975bebbe966ca7b", "Xue2", "bec7a5def8e6f4cde460ed62ed4fe950", "Xue3", "b3b7f7ab", "Xue4", "a6e5b3b7a5deab64e065ccefee7ecc5cd7b3", "Xun1", "beb1c2c8c274e2c0c548ce7defdbd64fed65f4aef0a1e765b3d4f27b", "Xun2", "b44da8b5b8dfb460a6afb9a5bcf1d2b1f0c3acacaffbabe0cecbce7dd1ecea4bc27bd04ad0bdf858e262e5b4cce8ce4fea67e9ceeb43e540", "Xun4", "b054b056a8b3bbb9aeeeb9a5abe0b453a6c4bfb8e541cbc0bcf2f1a3d3edf1da", "Ya1", "a772c0a3be7ec06ea9e3a458d9b2b7dad4ef", "Ya2", "a4faaadeb250b8c5b048a9e3ccd6cb62f3fac9b7d4c4", "Ya3", "a8c8b0d7b6aed56fc9c4cacfeb56dca6a5d4", "Ya4", "a8c8b359cdcecfebb4e3d4d5d95debe2db47aaeec959ca50cd67da6fe34bf9d3", "Yai2", "b156deddd4a9d4e4", "Yan1", "b7cfb26ab254aeefbe4dab7cafdaa961b4f3b5d2b9e4bf50e759ec49b9bdd4fcf4b4e46be2b1da6dd2b8d460ecd6f35cb5cb", "Yan2", "ace3a8a5c343c459a9b5aa75aaa2c0f9c651a9a5bae1c3b2c046a7b0e3e9c0d1d4bad877dd77e2f2e372d7eec5c9f7d5dde9f8fae8a9d15edc6ed667eb5aef4af1f8f5b1f7d3d77ad8e5", "Yan3", "b2b4ba74b1bbad6cb66eb0b3ab5ef5dec56bc64cd0e6cebbdf6acb56f7d6d951d966da4ae7a7f97dce6be5acd9b0f1fcf56ac5c4da7ccdf4f1efddf4caf1f5bfd7f5d8dad94cdb62e0d1e3f9e7c6f5a1f5b5f8abd558ebc8ef56f6cd", "Yan4", "c5e7bf50b9bdaecbb6adae62b254c676bf56abdbb3f7b578ab7cc360adf1c5e4ace3f840bfceaa75f9a9da5dc66fc5acd869f9d0f46ad845f6bbf1fcef76f849b54bcd5bce6df86dddeaf451ece6d4e9dcb5e8ede945f55bf7fec641f976d77ad978", "Yang1", "a5a1afb1ac6fc06dbbdfaa74cbf6d066cf4bca62cc47d6efe0bde0d9", "Yang2", "b7a8b6a7b4adac76a6cfa8cbaf4cbac5c1edabe2c347b77ab7d5ce52ceefe2fedbb1deb4d2b3f4fdd8dff8e4d6b1d8bb", "Yang3", "be69a5f5aef1c46fbbdfc957efd5cc62cfb4ccbfd67defd0e3e3", "Yang4", "bccbbe69ae7eba79a9c2b7d5efeed6f2", "Yao1", "ad6eb879a4d4a7afc1dca45ca65bb3e9d86dcff7dfb7d7cc", "Yao2", "b76ec1c1b3f3bbbbabc0acabbabdb9aeb263c061f3add85cedd9e566dd64d9e2deaddbfea4f8ce5db15ce4a2d2b0cf57d662f6afaad4dcf8d26cbd60dce0dd6cba6ff672", "Yao3", "ab72afb7afe6a4d4cceaaa48d2f8d6c9f7c5cabcccb3d0a5d2d3d450de4ae255f3b5cac7dd45e3cf", "Yao4", "ad6ec3c4c4a3c260c65fc563a9edeffad7c4e4c8f0a3e446d040dae0dfd3e678f34d", "Ye1", "ad43bc4ff7f9a3ae", "Ye2", "b7ddad43b7a6b278d95eeced", "Ye3", "a45db3a5a74dd4b1e2b2", "Ye4", "b77eb8adadb6a95dab7cbfd6abfbc5e2bff3ea4deda2ecebae67bee7f1acde6feee4f667ea45f165d44fd9dfe965e9ac", "Yi1", "a440b3fca6e7a8ccc2e5a5ecb4a5beb3baacd661aba9a3b8e2fceddff1e0e9b5e476ccfcf7c3d9dadc54c9c9de55e349ea57cfabd848dbbae176ea62efdeefe9f877e95e", "Yi2", "bff2bac3b2bea979a9c9abbcbbf6a669bdcbafd8b64db97eab78dbdfa85ec05bc255ddcbb2ada665ecdad6d7d1dfc96cd166cf70edc6b059d3e1d3eecb44cf51dbcdd441cea7d6abdb42e0c0ecd9cbb7cfd4d0ade4abce4dcec3dba6ccf3aeebd2bfd7bbdb43dbb3ddbfe068e265e66fe6d6eb6cef47f0ebf64cf8df", "Yi3", "a548a477a441adcab4c8a86fc3c6f2c3ada3d077b0c0d1b0ba59eb63c9e6d441dcafd0c0f8a3f3aaecf6e0bfa8b2d05ef05cd578d848d8e4d9a8f4da", "Yi4", "b74eb871a9f6c4b3a5e7af71b2a7c3c0bbf5bed0c4b6b247a7d0c16cacccbcddb668a8b6a7edb877c3b6b7b8bf7eb663b8daa67aa748b2ddacfdc5e6b1b3c574b8c7c172a6b2abb3bb69b5c5a6e7a4c2c16bd1bac2efc56dabd9a8dbc940a47ca6e3e97dbeb0e948eceeedf5d1a5e6b0c968e143d4b7e961abd4e9b5cb40cf41e9e2af4ae666eaf7f94af554e8f1dcb2d0faed5cf2c9f345ecd8ca59e66dca70ecf3dccce1bbf65ef1a2f4e6f4e3d6f6c9a9c9ddccddca68cf7ee9f9cb7bea55cfceccb4f5f7cde2da61ed5dd9a6d151d7f8d1c3d1f7d4b0d6f5d84cd9dedbf3dff6e16ee36de3a4e4c1e5dde65be75ae94cea6deeb0f2aff45eceb3e5cef37cf8ddf967", "Yin1", "a65dadb5b3b1abc3aeefaff4b9feaef4e2dad866d8a1d8fee2fadaf1dbc7eef0ec65e4a1e3d3eba2ce58f54dcfa7d468ddf6ecc6eef7f54cf6cbe1ed", "Yin2", "bbc8a775b147b25dbbc2c569c0d1c3f9abadb9dbd2a4efbdd543e7ddf0bfd4d9c955cdc2dc6cd148d27bd468d779e5f1e750efe7f864f36d", "Yin3", "a4deb6bcc1f4a4a8c57db043a776e0dbd355c169f8c1e7f2ee58e4d5dc68ed41ed56f5f4d34c", "Yin4", "a64cb6bcc1f4bdaead4ee1bae34ae978da57d150da79e1fae475", "Ying1", "c0b3ad5ec64ec0a6c561c4e5c174b7ebc678c458c4a2c5d5f44cc4eddcfcf277eadfde7df1a7e6adeefbe2f7f5e3ddc8e7bfda56eb74d463ec52f5faf651f7faf5b0", "Ying2", "c0e7aaefc3c7bfc3c4b9acd5bcfcbfa2c373e26cbec6b6f7bab7b7adefeff25ef96df45deeabf244f444f446f0a6", "Ying3", "bc76b4babf6fe5f9f6f4b072f45fcfe9d5bbd256", "Ying4", "c0b3b577ac4ddcf9efeff16ae1efe454", "Yo1", "adf2", "Yong1", "b6c4b165b96cbed6bec3f7eac173e156f360ba48f776b06ff5cbf175dcdcf5d7bbc1e8fce9e9ee52e2afebd4", "Yong2", "b6c4d871f1aad851e5e1dcfedd4de178", "Yong3", "a5c3aa61b5faab69bed6bfe3b4e9b8baa869bec3b176c173ab4de45cd155dceae6ceaf46d1a4e4ac", "Yong4", "a5cea6feeec9", "You1", "c075bc7eabd5b179cbe7a7f1f5efe0eef24ef14defcaccabefbaeff3f5ead7ab", "You2", "a5d1b4e5b943a4d7aa6fb66cb553b7dfb95cebc9acd0d7a5eb4fceeae7a2d7cad7e6ddcdbe7bc9accb4fd25bd461d2f4d75f", "You3", "a6b3a4cda8bbb2fbbcf8c24bd04ecd4fe47dcc6bd176cdc4d744e5d0", "You4", "a453a56ba5aebba4a6f6ac63b956afa7a6b3abc9a8ddabaac35eca72ce6ecd5cceaddbe6ecabcaf0cfbbd3f1", "Yu1", "b24aa8b1b7efacfaa3bade40e350c9e3cda6d6a7", "Yu2", "a9f3b472b3bdae54be6ca45fbaaea4a9b74da745acf2b7aeb94fb8b7ab5cc1d6b7ecb4fcb6a8aad8b5cdaabbbddbebc6d370a666c26abfccdaaeb5e3d8e1e34ca7b1d967ddf9acebf659dca2b3b8cafdd9bfcb69e6eee6f4bdc2bdc9decfdfa8d2a8ca53f042dad1f4aad7fed8e3da42dc5cdf7de2e6e8ace9f3eafbee6df0dcf1cef1d7f4bcf8e0f961d0acd4a5d8a4d8b2e0d7e6d1f44ff56df8ec", "Yu3", "bb50bb79ab42a4a9a6d0c0aca674aceab168c5c5bebeae46b0ebe6d5dcbacde3b1d6e940dde2deb7c94fdfccebb3d459d6bcd97bdc5bdd4aedc9f4c2efd8f0cb", "Yu4", "a87cb94ab977a5c9b1fdb0ecb3ebb755c541babbbca4af44b8ceb7d4b44abf6dbb50e0b1bfddb173c67bc67ebfd9c2a1ada7b6bfac52b7b6a8a1b14cbcf7ab5cae6ea6d6b9e1d17bdcaef7a7a8a6f866c0eee3daae4bbb79bac7d9b5bf48dac3acebdf67ee40ebd1ec48ec4ff1d9d9add5e7ea52e67af071f1c0ee4df77dd553eca3e873d252f5b7d1e7d2e1f2a2cce9f9ace467d1acdefde3b4e4fbe8e7f150f3b0f9c6f9d1e1d8d7c1e36be777ebf1", "Yuan1", "addeb257c070bbf0a97bd2d7dfebf3d8cb75ebf0d8fad9d6e3b3e3f5f6cfdfdbe3ece442e8d1f1faf469", "Yuan2", "adeca4b8adfbb6e9b6eabd74b7bdb4a9b444b04bb7e1abaea84ac1d5acb8e947efb1dcf4f258cdb4b545c4cdd346eae3e7b5cbabe7b4cabadfc5eb60d3bbccd4e25bde5fdd43da75deabe244e3bef164f4e0f5a8", "Yuan3", "bbb7cc53", "Yuan4", "b07cc440abe8ad62bbb7b444deb6ba40d964e7cbc970eeaee343e8fe", "Yue1", "acf9a4eae941e6dcda5f", "Yue4", "a4ebb656bcd6aeaebe5cb866c544a9a8c0aec4a3c65fc260c3c4e0b5bba1a647f465c5d4e9c4f5dbcda3f6f7f654b063f962efb6cd5eaab5c97cccf6dc76caf2d3cbf5fef9c5", "Yun1", "b777ba72ead5f349e16aeb64", "Yun2", "b6b3a4aaa4c3a9fbafd0aae5afc6e2beb861de65e658cfdaeac0cb4ee2bce8a3eafccab3c9b4ead4d75de0a8cce3cfe1", "Yun3", "a4b9b96be266cb65f176eb70cae9ebb6e465dc75cbb0", "Yun4", "b942c3fda5a5bcf7c4adb759c1dfd940b777f3a5dc50edf4cce0e6e3f579adfb", "Z1", "a3a8", "Za1", "b2cfa560cbdfd473e14eccc0e0c4", "Za2", "c2f8aba5af7bb0aff8cdeda9", "Zai1", "a861aee2ab76d9eeebb8", "Zai3", "a54aae5fd8e6b8fceacd", "Zai4", "a662a641b8fc", "Zan1", "c2aff4ee", "Zan2", "aba5b0afe6e1", "Zan3", "cedff6e3d4f1cef5f8b7d873f5c1d965f8b5", "Zan4", "c3d9bcc8c667c3f5c5d0f7e0f766f9b1f6ebf6d9f96f", "Zang1", "c5bcc542c5d8d27dbb4e", "Zang3", "e8ca", "Zang4", "c2c3c5a6b8aeae4e", "Zao1", "be44c156f0fedcb7", "Zao2", "c677", "Zao3", "a6adb4c7befec4a6b044ed6af2b2", "Zao4", "b379a86dc0eabeb8e1d1c4b7a85fc4bccb71f4d6f054", "Ze2", "ab68b364bedcbf41b9c9afb6d756a951e1b2b2c8f0f3d0b5d8e7dfc1f0e9f2e1b8e9f2e5", "Ze3", "abe7", "Ze4", "a4b7b0bccccac97adada", "Zei2", "b8e9", "Zen3", "abe7", "Zen4", "f2fb", "Zeng1", "b4bfbc57bca8ede3c2b9eda4e9c1eda5f779ea65", "Zeng4", "c3d8ed70", "Zh1", "a3a4", "Zha1", "b4eda4e3b3e5ddd3ac64f966cf48ea74ccbccee1e5d7f0e1", "Zha2", "a4e3a5beb2cfb968acb5e8adeed4d0f5e35ad7acf343f9a8", "Zha3", "af77b4edec7aca75d078", "Zha4", "ba5eac5dacb5b642a545b763b34ba951e3dca65cde4bafa4eecaec7ad2c6edc0", "Zhai1", "ba4bc24ebbf4d1c7", "Zhai2", "a676bb43", "Zhai3", "afb6cc68", "Zhai4", "b6c5b9ebb2bdb364ea71d6b9", "Zhan1", "b8e2aa67c2a4c0d6c04cd1d0c4b8f8d6dbd1eec2d1eaf8def853a565cbe1f676e0b9dbdaee4cf4ce", "Zhan3", "ae69b1d9b7f8c1d3ddaab9f1da7ef8d5e85ce4cce9cdf052eebbe55ae25ee9d2", "Zhan4", "a6fbbed4afb8bcc8a565b4ccc5b8b4efbaecf145c5d9eb59f358e84ad44e", "Zhang1", "b169b3b9b9fcba73bcccbcfdbabce16be5c6e468c1adf7aae1c5dcb4e160f6a1e852", "Zhang3", "aaf8b478baa6c953ef41", "Zhang4", "a456a54db162bbd9bde3b5c8a7fabaa6b9f3bf60e1a3c9e9ea7dd048", "Zhao1", "b4c2a9dbac4ca56cb5dbbc4ab078e8cfe0b8aed0cfdfeee9cc4f", "Zhao2", "b5db", "Zhao3", "a7e4aa68a4f6dba8e2d1", "Zhao4", "b7d3bbafa56cb86ea5fcbb46b640aed0d345c267acb7e4bdcfc5b4cde355f3e4ce55d97de9bc", "Zhe1", "be42c1b1d5aee177", "Zhe2", "a7e9adf5ba50c4e0c1b7c2d6bbb3ba4bc2e1e1cdb8bde6c6c947f842d5aef1c6cb73d551cff3f0edd0a7f8e1f94df273", "Zhe3", "aaccbdeaebe3", "Zhe4", "b36faefdbda9c5c2cf43a676ecfad270ee5b", "Zhe5", "b5dbbe42d5aee177", "Zhen1", "af75b077acc3ad73b0bbbad5b772bd65af7abac2bfb2b7a9ba64b645e3b8deb0de4ce2ecd065eed3f97ad8cce8d0f0abe6d0e9d7e657deb2e0a2d8d5e3bfeec0f4a7f6b8d8b3", "Zhen3", "b645aa45af6cdc48d2c1d7bfbfa6e6d2d6ecf568d2d4f7c8f35bccbacae8d347df61dad3ddc7eaddecb4", "Zhen4", "c2edb07daeb6be5fbbacaed3aa45be7dd95fd7f2d6a8ae57cde0ced6d1dadfe3d5b4e44ae5bd", "Zheng1", "aaa7a9babb5db843bc78b1c3bae5a5bfa9c3b275bffeb157bdd8c470e0b2d26deac3cc4dcfb3d4c9d742a442d2cf", "Zheng3", "bee3ac40c9a1e5b3cda9", "Zheng4", "be47a5bfc3d2ac46b5fdaf67b1c3b456", "Zhi1", "a4a7aabeb0a6c2b4a4e4aa4ba5c4a575a773aadbafd7aacfbb6aace9b1f7afada4f3cf4ca3a4ad4fecaea567dda5cffcdbf4aa7ce8e8cb5bd2f2e243d059d3dcd9d8", "Zhi2", "aabdc2bebde8adc8b4d3b0f5b4dec259abbfcbbbf0f9ee68c5add1e8d4b2def9ba54eddecf50da6ad6c7efd1e4d8e57ae9beeae8efcef0cddbcedebfe55bf748", "Zhi3", "a575abfcafc8a4eea6aea77dbc78ace9b36bace7aba4cf4ce0adcec7cb54cbafaae9dcb0dc40d2c5d1d3ca74caaaf2dad1f2d643de56", "Zhi4", "a6dca8eeaa76a7d3bb73ad50b86db4bcafb4bb78b858bde8abcfbd6fbc6dbaa2bcb0b2bfaaa5b2a9b96ec3d1ece4b569b8fef563cc6fd446aabedd49cadbd1e8c5aeb5edf0f4f7c1cbdaf84bcba4ceb6d8f4d664d67ae2d9d6e9f2f5d0bbe47ed45fe06ae850e878f257d7baf67ed5f4d2a6f47ed36ce6fdee70ced9cfa3e445ceb7ecadd0b3d6f9db55ec64d2ece042eca8", "Zhong1", "a4a4c4c1b2d7a9bec1e9b04aa7d8acd8ee6ec9b1cab8e779cf60dea1cad4d371cd58f7ed", "Zhong3", "bad8b87eb6efbfe6ade0", "Zhong4", "a4a4bad8adaba5f2b2b3d8d8b546cb64d3d3d45cd8afe6f0", "Zhou1", "a950b667a67bac77a6e0b5b0e7eab0e7ed79f64ee07ad876f1b8efa3cf7cd645e4aad2bad550e84dcbc5d4db", "Zhou2", "b662a96f", "Zhou3", "a9aaa879dee2f3ca", "Zhou4", "b1debd4ba97aacf4bfa8ab60a947edd9e2d7c3b3ce43d440e4f0cca6ad48e942e8cb", "Zhu1", "af5da6b6bdd1aee8bddeb5efaffcb2b9b8ddbbcba8dccf78eff5d0bcf255f24cd6bec3c5daf9dbc8e7d2ef7df640e3d8ef73f2d0", "Zhu2", "a6cbbf76b376c0ebf2e2b5aeaac7a5bac4bdd754b662d2f9e762d043dbeff7b0f8adf9a6d37aeac4", "Zhu3", "a544c4ddb54ec5f1b64ab25ac666b5dbecafa9d6dec9f8f0d2e0d847f8a7ce5fd35bf8f1cd46d2cd", "Zhu4", "a6edb5dba755aa60afacbe6eb5f9ac57b345c5b1cfaead52a6eebae6aa56d6e2e37dc972cf4dd6f3e0e7d2c3d777e0afd6e4d8f0dbf1dc4be5ececb0efe0cf67e7d9", "Zhua1", "a7ecbee2ef66ecf9", "Zhua3", "a4f6", "Zhuai1", "abfb", "Zhuai3", "e06d", "Zhuai4", "abfb", "Zhuan1", "b14dbf6aad42c346e157e46cf7addcc7e16de6aaedbef7b8e740f0c4", "Zhuan3", "c2e0c4da", "Zhuan4", "b6c7c1c8bd66bcb6f2fcf557b9b6deb5edd3df7b", "Zhuang1", "b8cbb2f8bccea7a9f9dbc9dcd5ce", "Zhuang3", "ae4e", "Zhuang4", "aaaca7a7bcb2f9bad659", "Zhui1", "b06cc040b4d5ab41f1b6f3ebdfa1efa9", "Zhui3", "cd44", "Zhui4", "baf3bc59c2d8ead8b46dec5de2f0e3a7f770", "Zhun1", "bdcea4d9aad2cffecdcfcabdd7c9", "Zhun3", "b7c7ade3d447d4ade362", "Zhun4", "defc", "Zhuo1", "aebbaee0b267b4cdedb2", "Zhuo2", "a8f4ad5fbf42a9e5c0deb075a860b5dbb0d6c54ec0c2b55ae7d8d0d3e5c1d97cd5bfd9b8da5ae3dfe840f7bfc9dfc9feac48e6cbeab9d255d9baf0e8ebe7d47edf6beceff4c7c9cad0ecf461", "Zi1", "b8eaaff7b4fea773abbaab74a7b6bfd4b8edaf59a3a8bdfdb264c568bafdb446dae7c068d8dbdba4eecdf5acecb7c9d3e9facd72e0a7f3cfc045e05ed9c4e4baf3e9f3f9d1f3d353d540d6c6f2db", "Zi2", "a46c", "Zi3", "a46ca54ab5b5b1eaacf3b7bad054b8e4d6d7d2f1d064d3a5c9c5cb45cb7ece49cda1d842e049", "Zi4", "a6dba672aea1ba7bd6b0b446d0e7db49db48caeed0d1d27e", "Zong1", "a976c2dcc161baeeb4c4c34ff0eff3bdf3c6e6f7e671d0d9d948da77e347e749d8e2e7b6", "Zong3", "c160e1ebb6cde670df7ae3ce", "Zong4", "c161baeabaeeb171ea72cef8", "Zou1", "b951eea4c1dde7d4b0e7d570db68b3b5f55ff3c8d9c5e369d9b4d7eadcfaf3f4f8a1f969", "Zou3", "a8ab", "Zou4", "abb5c64ab47e", "Zu1", "afb2e3c6", "Zu2", "a8acb1daa8f2b9bed56ad541ebc7d0fbdcc3e7f6", "Zu3", "b2d5afaaaafdab5bb641cfd1e4c5", "Zuan1", "c670f970", "Zuan3", "c4a1c670f940f8fcf5c1", "Zuan4", "c1c8c670f7ddf9b1", "Zui1", "b0efd470df6ee1abf8b9", "Zui3", "bc4cf046e043e1aaecc8ed5a", "Zui4", "b3ccb86fbe4becfcbfbfd9a2ed49d6eedef5ebf4e550e962", "Zun1", "b44cbfedbeeae54af4ebe564f06df862e553", "Zun3", "bcc1e4f7e54ae0f1f2f6", "Zun4", "ab54a660d1c1f857e4b2ea51", "Zuo2", "ac51a740afa4d9cbdf4fdefedfc3", "Zuo3", "a5aaa6f5f077", "Zuo4", "b0b5a740a7a4ae79dc60afaec677ac67cca9d05fcddadfdcd159", NULL }; char *pinyin_gb2312[] = { "A1", "b0a2b0a1bac7dfb9ebe7efb9", "A2", "b0a1bac7e0c4", "A3", "b0a1bac7", "A4", "b0a1bac7", "A5", "b0a2b0a1bac7", "Ai1", "b0a7b0a3b0a4b0a5b0a6dedfefcd", "Ai2", "b4f4b0a4b0a8b0a9dedf", "Ai3", "b0a5b0aab0abe0c8f6b0", "Ai4", "b0aeb0acb0adb0a5b0a6b0afe0c8e0c9e6c8e8a8ead3edc1", "An1", "b0b2b3a7b9e3b0b0b0b1dacfe2d6e8f1f0c6", "An3", "b0b3dbfbdeeeefa7", "An4", "b0b8b0b4b0b6b0b5f7f6b0b7e1ed", "Ang1", "b0b9", "Ang2", "b0ba", "Ang4", "b0bb", "Ao1", "b0bcb0be", "Ao2", "b0bdb0beb0bfcff9e0bbe2dae5dbe9e1f1faf2fcf7a1f7e9", "Ao3", "b0c0ded6e6c1", "Ao4", "b0c4b0c2b0c1b0c3dbeaded6e1aee6f1f6cb", "Ba1", "b0cdb0cbb0c5b0c9b0c8b0c6b0c7b0cab0cce1b1f4ce", "Ba2", "b0cbb0ceb0cfdcd8ddc3f7c9", "Ba3", "b0d1b0d0eed9", "Ba4", "b0d1b0d5b0d2b0d3b0d4b0d6e5b1f6d1", "Ba5", "b0c9b0d5", "Bai1", "eafe", "Bai2", "b0d7", "Bai3", "b0d9b2aeb0d8b0dab0dbdee3", "Bai4", "b0ddb0dcb0dedfc2", "Ban1", "b0e0b0e3b0e4b0e1b0dfb0e2f1a3f1ad", "Ban3", "b0e6b0e5f4b2dae6dbe0eed3", "Ban4", "b0ecb0ebb0e9b0e7b0e8b0eab0ed", "Bang1", "b0eeb0efb0f0e4ba", "Bang3", "b0f1b0f3b0f2", "Bang4", "b0f7b0f5b0f8b0f2b0f4b0f6b0f9ddf2", "Bao1", "b0fcc5dab0fbb0fab0fdb0fee6dfecd2f6b5", "Bao2", "b1a1b1a2", "Bao3", "b1a3b1a6b1a4b1a5dde1f0b1f1d9", "Bao4", "b1a8b1a9b1acb1a7b1aab1abc5d9c6d8c6d9f5c0", "Bei1", "b1afb1b3b1adb1aeb1b0dae9dbfdddc9f0c7", "Bei3", "b1b1", "Bei4", "b1bbb1b8b1b6b1b3b1b4b1b2b1b5b1b7b1b9b1bad8c3dafdddede3a3edd5f1d8f6cdf7b9", "Bei5", "b1dbdfc2", "Ben1", "b1bceadaefbc", "Ben3", "b1beb1bddbce", "Ben4", "b1bcb1bfbabbdbd0", "Beng1", "b1c0b1c1e0d4", "Beng2", "b1c2", "Beng3", "b1c1", "Beng4", "b0f6b1c1b1c3b1c4b1c5eab4", "Bi1", "b1c6", "Bi2", "b1c7dda9", "Bi3", "b1c8b1cab1cbd9c2d8b0b1c9dfc1e5feeff5f4b0", "Bi4", "b1d2b1d8c3d8b1dcb1d5b1d9b1d0b1ddb1dab1d6b1ccb1cdb1ceb1cfb1d1b1d3b1d4b1d7b1dbb7f7c3dadbfddcc5dceaddc9deb5dfd9e1f9e2d8e3b9e4e4e5a8e5f6e6bee6d4e8b5eadaeeafeee9f1d4f3d9f3ebf3f7f4c5f5cff7c2", "Bian1", "b1dfb1e0b1deecaeecd4edbef2f9f3d6f6fd", "Bian3", "b1e1b1e2d8d2eddcf1b9f1db", "Bian4", "b1e3b1e4b1e7b1e6b1e9b1e5b1e8dbcddcd0e2ede3eae7c2", "Bian5", "b1df", "Biao1", "b1eab1ebb1ecc9d7e6f4e8bceca9ecadefdaeff0f1a6f7d4", "Biao3", "b1ede6bbf1d1", "Biao4", "f7a7", "Bie1", "b1eeb1efb1f1", "Bie2", "b1f0f5bf", "Bie3", "b1f1", "Bie4", "b1f0", "Bin1", "b1f6b1f5b1f2b1f3b1f4d9cfe1d9e7cde7e3e9c4efd9", "Bin4", "e9ebb1f7ebf7f7c6f7de", "Bing1", "b2a2b1f8b1f9e9c4", "Bing3", "b1feb1fbb1fab1fcb1fdc6c1d9f7dafb", "Bing4", "b2a2b2a1def0", "Bo1", "b0e3b2a5b2a8b2a6b0feb2a3b2a4b2a7e2c4f5c0", "Bo2", "b0d9b2a9b2b5b2b4b2aeb2aab0d8b1a1b2abb2acb2adb2afb2b0b2b1b2b2b2b3c6c7d8c3d9f1ede7eee0f0bef5db", "Bo3", "f4a4f5cb", "Bo4", "b0d8b1a1e9deeafef4a4eba2", "Bo5", "b2b7e0a3", "Bu1", "e5cdeaceeedf", "Bu2", "b2bbf5b3", "Bu3", "b2b9b2b6b1a4b2b7b2b8dfb2", "Bu4", "b2bbb2bfb2bcb2bdc6d2b2beb2bab2c0eab3eed0", "Ca1", "b2f0b2c1e0ea", "Ca3", "ede5", "Cai1", "b2c2", "Cai2", "b2c6b2c5b2c4b2c3", "Cai3", "b2c9b2cab2c7b2c8", "Cai4", "b2c9b2ccb2cb", "Can1", "b2ceb2cde6ee", "Can2", "b2d0b2cfb2d1", "Can3", "b2d2f7f5", "Can4", "b2d2b2d3b2f4e5eee8b2f4d3", "Cang1", "b2d6b2d7b2d4b2d5d8f7", "Cang2", "b2d8", "Cao1", "b2d9b2da", "Cao2", "b2dbb2dce0d0e4eef3a9f4bd", "Cao3", "b2dd", "Ce4", "b2dfb2e1b2e2b2deb2e0e2fc", "Cen1", "b2ce", "Cen2", "e1afe4b9", "Ceng1", "e0e1", "Ceng2", "d4f8b2e3", "Ceng4", "b2e4", "Cha1", "b2eeb2e5b2e6b2ead4fbe0eae2c7e8beefca", "Cha2", "b2e9b2ecb2e8b2e6b2e7b2eab2ebe2aae9abe9b6e9df", "Cha3", "b2e6efeff1c3", "Cha4", "b2eec9b2b2e6b2edb2efe3e2e6b1e8bef1c3", "Chai1", "b2eeb2f0eece", "Chai2", "b2f1b2f2d9ad", "Chai4", "f0fbf2b2", "Chan1", "b2f3b2f4eae8", "Chan2", "b5a5b2f5b2f6b2f7b2f8e2dce4fde5a4e5eee6bfecf8efe2f3b8f5f0", "Chan3", "b2fab2fbb2f9d9e6dac6dddbe6f6", "Chan4", "b2fce2e3e5f1", "Chang1", "b2fdb2fed8f6ddc5e3d1e6bdf6f0", "Chang2", "b3a4b3a1b3a3b3a5ccc8b3a2b3a6c9d1dcc9e1e4e6cf", "Chang3", "b3a1b3a7b3a8e3aeeac6eba9", "Chang4", "b3a9b3aab3abdbcbe2ea", "Chao1", "b3acb3aeb3adb3b3b4c2bdcbe2f7eccc", "Chao2", "b3b1b3afb3b0b3b2eacb", "Chao3", "b3b3b3b4", "Chao4", "f1e9", "Che1", "b3b5edba", "Che3", "b3dfb3b6", "Che4", "b3b7b3b9b3b8b3badbe5", "Chen1", "b3bbded3e0c1e8a1", "Chen2", "b3c2b3bfc9f2b3c1b3bcb3bdb3beb3c0b3c8dac8e5b7", "Chen3", "edd7", "Chen4", "b3c6b3c3b3c4b3d3dadfe9b4f6b3", "Chen5", "d8f7", "Cheng1", "b3c6b3c5b3d3e0e1e8dfeeaaeef5f2c9", "Cheng2", "b3c9b3ccb3d0b3c7caa2b3cab3cbb3cfb3cdb3ced8a9b3c8dbf4e8c7ebf3eef1f1cef5a8", "Cheng3", "b3d1b3d2f1ce", "Cheng4", "b3c6b3d3", "Chi1", "b3d4f3d7b3d5dfeae0cde6caedf7f0b7f2bff3a4f7ce", "Chi2", "b3d6b3d8b3d9b3dbb3d7b3dadbe6dcafdcddf3f8f5d8", "Chi3", "b3dfb3dcb3ddb3def1ddf4f9", "Chi4", "b3e0b3e1b3e2b3e3d9d1dfb3e0b4e1dce2c1ebb7f1a1", "Chong1", "b3e4b3e5d3bfdcfbe2e7e3bff4a9f4be", "Chong2", "d6d6d6d8b3e7b3e6", "Chong3", "b3e8", "Chong4", "b3e5efa5", "Chou1", "b3e9f1ac", "Chou2", "b3efb3eab3f1b3eeb3ebb3ecb3edb3f0d9b1e0fce3b0f6c5", "Chou3", "b3f2b3f3", "Chou4", "b3f4", "Chu1", "b3f6b3f5e9cb", "Chu2", "b3fdb3f7b3f8b3f9b3fab3fbb3fcdbbbf2dcf5e9", "Chu3", "b4a6b4a2b4a1b3fee8c6e8faf1d2", "Chu4", "b4a6b4a5d0f3b4a3b4a4d8a1e2f0e3c0e7a9f7ed", "Chuai1", "b4a7def5", "Chuai3", "b4a7", "Chuai4", "b4a7e0a8e0dcebfaf5df", "Chuan1", "b4a8b4a9e7ddebb0", "Chuan2", "b4acb4abb4aae5d7f4ad", "Chuan3", "b4ade2b6", "Chuan4", "b4aeeecb", "Chuang1", "b4b4b4b0b4af", "Chuang2", "b4b2b4b1", "Chuang3", "b4b3", "Chuang4", "b4b4e2eb", "Chui1", "b4b5b4b6", "Chui2", "b4b7b4b8b4b9d7b5daefe9a2e9b3", "Chun1", "b4bab4bbf2ed", "Chun2", "b4bfb4bcb4bdb4beddbbf0c8", "Chun3", "b4c0", "Chuo1", "b4c1f5d6", "Chuo4", "b4c2e0a8eaa1f6ba", "Ci1", "b2eeb4c3b4ccdfda", "Ci2", "b4cad7c8b4c7b4c8b4c4b4c5b4c6b4c9dcebecf4f0cbf4d9", "Ci3", "b4cb", "Ci4", "b4ceb4cdb4cccbc5", "Cong1", "b4d3b4cfb4d0b4d1b4d2dccae6f5e8aee8c8", "Cong2", "b4d3b4d4e4c8e7fd", "Cou4", "b4d5e9a8eaa3ebed", "Cu1", "b4d6", "Cu2", "e1dee9e3", "Cu4", "b4d9d7e4b4d7b4d8ddfde2a7f5a1f5bef5ed", "Cuan1", "b4dad9e0dfa5efe9", "Cuan2", "d4dc", "Cuan4", "b4dbb4dcece0", "Cui1", "cba5b4ddb4deb4dfe9c1f6bf", "Cui3", "e8ad", "Cui4", "b4e2b4e0b4e1b4e3b4e4ddcddffde3b2eba5", "Cun1", "b4e5f1e5", "Cun2", "b4e6b6d7", "Cun3", "e2e2", "Cun4", "b4e7", "Cuo1", "b4e8b4e9b4eaf5e3", "Cuo2", "e1cfeff3f0eef0fbf5ba", "Cuo3", "b4e9ebe2", "Cuo4", "b4ebb4edd8c8b4ecefb1", "Da1", "b4f0b4eedec7dfd5f1d7e0aa", "Da2", "b4efb4f2b4f0b4f1e2f2e6a7edb3f3cef7b0f7b2", "Da3", "b4f2", "Da4", "b4f3", "Da5", "cbfef0e3", "Dai1", "b4fdb4f4dfbe", "Dai3", "b4feb4f5b4f6", "Dai4", "b4f3b4fab4fdb4f8b4fbb4f7b4feb4fcb4f9b5a1dca4dfb0e1b7e5cae6e6e7aae7e9f7ec", "Dan1", "b5a5b5a4b5a3b5a2b5a6d9d9e9e9edf1f0f7f1f5f3ec", "Dan3", "b5a3b5a7b5a8eae6f0e3f0f7", "Dan4", "b5abcaafb5a3b5adb5a9b5afb5aeb5aab5acb5b0ddcce0a2e5a3f0f7", "Dang1", "b5b1eef5f1c9", "Dang3", "b5b3b5b2dad4", "Dang4", "b5b1b5b2b5b4b5b5dbcaddd0e5b4edb8", "Dao1", "b5b6dfb6e2e1ebae", "Dao2", "dfb6", "Dao3", "b5bcb5bab5b9b5b8b5b7b5bb", "Dao4", "b5bdb5c0b5b9b5c1b5beb5bfe0fcece2f4ee", "De2", "b5c3b5c2efbd", "De5", "b5c4b5d8b5c3b5d7", "Dei3", "b5c3", "Deng1", "b5c7b5c6b5c5e0e2f4a3", "Deng3", "b5c8eaad", "Deng4", "b3ceb5cbb5c5b5c9b5cae1d8ede3efeb", "Di1", "cce1b5cdb5ccb5ced8b5e0d6efe1f4c6", "Di2", "b5c4b5d2b5d0b5cfb5d1b5d3b5d4b5d5d9e1ddb6e0d6eaebefe1", "Di3", "b5d6b5d7d8b5daaedbe6e8dcedc6f7bedba1", "Di4", "b5c4b5d8b5dab5dcb5dbb5ddb5d9b5dedad0e6b7e7b0e9a6eddaedfb", "Dia3", "e0c7", "Dian1", "b5dfb5e0b5e1e1dbf1b2", "Dian3", "b5e3b5e4b5e2d8bcf5da", "Dian4", "b5e7b5eab5eeb5ecb5e5b5e6b5e8b5e9b5ebb5eddae7dbe3e7e8eee4f1b0f4a1", "Diao1", "b5efb5f0b5f1b5f2b5f3f5f5f6f4", "Diao3", "c4f1", "Diao4", "b5f7b5f4b5f5b5f6eef6efa2", "Die1", "b5f8b5f9f5da", "Die2", "b5fab5fbb5fcb5fdb5fed8fddbecdca6dee9e0a9ebbaf0acf1f3f5def6f8", "Ding1", "b6a1b6a2b6a3b6a4d8eae7e0eeaef0dbf1f4f4fa", "Ding3", "b6a5b6a6f4fa", "Ding4", "b6a8b6a9edd6b6a4b6a7e0a4ebebeefa", "Diu1", "b6aaeefb", "Dong1", "b6abb6acdfcbe1b4ebb1f0b4", "Dong3", "b6adb6aeedcf", "Dong4", "b6afb6b0b6b1b6b2b6b3b6b4dbede1bcebcbebd8edcf", "Dou1", "b6bcb6b5ddfaf3fb", "Dou3", "b6b7b6b6b6b8f2bd", "Dou4", "b6c1b6bab6b7b6b9b6bbf1bc", "Du1", "b6bcb6bde0bd", "Du2", "b6c0b6c1b6d9b6beb6bfe4c2e8fcebb9f7c7f7f2", "Du3", "b6c4f3c6b6c3b6c2b6c7", "Du4", "b6c8b6c5b6c9b6c6b6c7b6cadcb6f3bc", "Duan1", "b6cb", "Duan3", "b6cc", "Duan4", "b6ceb6cfb6cdb6d0e9b2ecd1f3fd", "Dui1", "b6d1", "Dui4", "b6d4b6d3b6d2b6d8eda1edadedd4efe6", "Dun1", "b6d6b6d8b6d5b6d7ede2efe6", "Dun3", "edeff5bb", "Dun4", "b6d9b6dbb6dcb6dab6dde3e7ecc0edbb", "Duo1", "b6e0b6deb6dfdfcdf1d6", "Duo2", "b6c8b6e1eeecf5e2", "Duo3", "b6e2b6e3b6e4dfe1e7b6", "Duo4", "b6e2b6e5b6e6b6e7b6e8b6e9cdd4e3f5e8de", "E1", "b0a2e5ede6b9", "E2", "b6eeb6ecb6eab6ebb6edb6efb6f0c5b6ddadefb0", "E3", "b6f1", "E4", "b6f1b6f2b6f4b6f3b6f5b6f6d8acdaccdbd1dcc3dde0dfc0e3b5e3d5e9eeebf1efc9f0caf2a6f6f9", "E5", "dfc0", "Ei2", "dac0", "Ei3", "dac0", "Ei4", "dac0", "En1", "b6f7ddec", "En4", "def4", "Er2", "b6f8b6f9f0b9f6dc", "Er3", "b6fbb6fab6fcb6fde5c7e7edeeef", "Er4", "b6feb7a1d9a6", "Fa1", "b7a2", "Fa2", "b7a3b7a6b7a5b7a4b7a7dbd2", "Fa3", "b7a8edc0", "Fa4", "b7a2b7a9", "Fan1", "b7adb7aab7acb7abdeace1a6", "Fan2", "b7b1b7b2b7bab7b3b7aeb7afb7b0deacdec0ecdcf5ec", "Fan3", "b7b4b7b5", "Fan4", "b7b8b7b7b7b6b7bab7b9e8f3eeb2", "Fang1", "b7bdb7bcb7bbb7c1dafae8caeed5", "Fang2", "b7c0b7bfb7bbb7beb7c1f6d0", "Fang3", "b7c3b7c4b7c2e1ddf4b3", "Fang4", "b7c5", "Fei1", "b7c7b7c9e7b3b7c6b7c8e5faece9f2e3f6adf6ee", "Fei2", "b7cae4c7ebe8", "Fei3", "b7c6b7cbb7cce3ade9bcecb3f2e3f3f5f4e4", "Fei4", "b7d1b7cfb7ceb7cdb7d0dcc0e1f4efd0f0f2", "Fen1", "b7d6b7d7b7d2b7d5b7d3b7d4e7e3", "Fen2", "b7d8b7d9b7dae8fbf7f7", "Fen3", "b7db", "Fen4", "b7d6b7ddb7dcb7deb7dfb7e0d9c7e5aff6f7", "Feng1", "b7e7b7e1b7e2b7e5b7e3b7e4b7e6b7e8b7e9dbbaddd7e3e3edbf", "Feng2", "b7eab7ebb7ec", "Feng3", "b7eddff4", "Feng4", "d9bab7efb7eeb7ecddd7", "Fo2", "b7f0", "Fou3", "b7f1f3be", "Fu1", "b7f2b7f3b7f4b7f5dfbbeffbf4eff5c3f5c6", "Fu2", "b7feb8a3b7f2b8a1b7f0b7fbb8a5e6dab7f9b7fcb7f6b7f7b7f8b7fab7fdb8a2b8a4d9ebd9ecdbaedcbddcc0dcdedcf2ddb3ddcae1a5e2f6e5f5e7a6e7a8e8f5ecf0edc9edeaeeb7effbf2b6f2ddf2f0", "Fu3", "b8aeb8b8b8a8b8a9b8abb8a6b8a7b8aab8acb8adb8afded4e4e6edeb", "Fu4", "b7feb8b6b8b1b8b4b8bab8bdb8bbb8b8b8beb8b0b8b2b8b9b8b3b8b5b8b7b8bcb8bfb8c0e6e2eae7f0a5f2f3f6d6f6fb", "Fu5", "b8c0", "Ga1", "bfa7bcd0b8c2b8ecd9a4eab8", "Ga2", "b8c1b8c2d4fee6d9eec5", "Ga3", "b8c2e6d8", "Ga4", "dece", "Gai1", "b8c3daebdbf2eae0", "Gai3", "b8c4", "Gai4", "b8c5b8c7b8c6b8c8bde6d8a4eaae", "Gan1", "b8c9b8cab8cbb8ccb8cdb8cec7acdbe1dcd5decfe3efedb7f0e1f4fb", "Gan3", "b8d2b8cfb8cbb8d0b8d1dfa6e4f7e9cf", "Gan4", "b8c9b8d3e4c6e7a4eaba", "Gang1", "b8d5b8d4b8d6b8d7b8d8b8d9b8dcbfb8eeb8", "Gang3", "b8dbb8da", "Gang4", "b8d6b8dcedb0f3e0", "Gao1", "b8dfb8ddb8deb8e0b8e1b8e2d8bae9c0", "Gao3", "b8e5b8e3b8e4debbe7c9e9c2eabd", "Gao4", "b8e6b8e0dabedbacefaf", "Ge1", "b8f1b8e7b8e8b8e9b8eab8ebb8ecb8edb8eebfa9d2d9d8eedbd9e6fcf1cb", "Ge2", "b8f1b8efb8f3b8f0b8f4b8e9b8ecb8f2d8aadcaae0c3eba1ebf5efd3f2a2f7c0", "Ge3", "b8f6b8f7bacfb8f0b8c7dbc1f4b4", "Ge4", "b8f6b8f7b8f5edd1f2b4", "Gei3", "b8f8", "Gen1", "b8f9b8fa", "Gen2", "dfe7", "Gen3", "f4de", "Gen4", "d8a8dda2f4de", "Geng1", "b8fcb8fdb8fbb8fee2d9", "Geng3", "b9a1b9a2b9a3beb1dfece7aef6e1", "Geng4", "b8fc", "Gong1", "b9a4b9abb9b2b9a9b9a6baecb9a5b9acb9a7b9a8b9aab9adebc5f2bcf6a1", "Gong3", "b9aeb9afb9b0e7ee", "Gong4", "b9b2b9a9b9b1", "Gou1", "b9b5bee4b9b3b9b4d8fee7c3e8dbf3f4f7b8", "Gou3", "b9b6b9b7e1b8e8dbf3d1", "Gou4", "b9b9b9bbb9bab9b4b9b8dab8e5dce6c5eaedecb0", "Gu1", "b9c0b9bcb9bdb9beb9bfb9c1b9c2b9c3b9c7ddd4dfc9e9efecb1f0b3f2c1f4fef5fd", "Gu2", "b9c7", "Gu3", "b9c9b9c4b9c5b9c8b9c6b9c7bcd6d8c5daace3e9eaf4ebfbecb1eeadeeb9eedcf0c0f2c1f7bd", "Gu4", "b9cbb9cdb9c0b9cab9cce1c4e8f4eaf6efc0f0f3f6f1", "Gua1", "c0a8b9ceb9cfdfc9e8e9ebd2f0bb", "Gua3", "b9d1b9d0dfc9", "Gua4", "b9d2b9d3d8d4dab4", "Guai1", "b9d4dee2", "Guai3", "b9d5", "Guai4", "b9d6", "Guan1", "b9d8b9d9b9dbb9dab9d7c2dad9c4ddb8f1e6f7a4", "Guan3", "b9dcb9ddddb8", "Guan4", "b9dbb9dfb9dab9deb9e0b9e1dee8e4caeec2f0d9", "Guang1", "b9e2dfdbe8e6ebd7", "Guang3", "b9e3e1ee", "Guang4", "b9e4e8e6", "Gui1", "b9e6b9e9b9e5b9e7b9e8b9eab9ebbffee6a3f0a7f6d9", "Gui3", "b9ecb9edb9eeb9efd8d0e2d1e5b3ead0f3fe", "Gui4", "b9f3b9f0b9f1b9f2b9f4c8b2d8dbe8edeac1f7ac", "Gun3", "b9f5b9f6d9f2e7b5eddef6e7", "Gun4", "b9f7", "Guo1", "b9fdb9f9b9f8ced0dbf6dfc3e1c6f1f8f2e5", "Guo2", "b9fad9e5dee2e0feebbd", "Guo3", "b9fbb9fce2a3e9a4f2e4", "Guo4", "b9fd", "Ha1", "b9feeefe", "Ha2", "b8f2cfba", "Ha3", "b9fe", "Ha4", "b9fe", "Hai1", "bad9bfc8e0cb", "Hai2", "bbb9baa2baa1", "Hai3", "baa3ebdcf5b0", "Hai4", "baa6baa4baa5baa7", "Han1", "baa8baa9f1fcf2c0f7fd", "Han2", "baabbaafbaacbaadbab9baaabaaedaf5eacfecca", "Han3", "bab0bab1e3db", "Han4", "bababab4bab6bab2bab5bab9bab3bab7bab8ddd5defee5abf2a5", "Hang1", "babb", "Hang2", "d0d0babdbabcbfd4e7ace7f1f1fe", "Hang4", "d0d0cfefe3ec", "Hao1", "ddefdeb6e0e3", "Hao2", "bac5bac0bac1babebabfbad1e0c6e5a9f2ba", "Hao3", "bac3bac2", "Hao4", "bac3bac5bac4bac6b8e4e5b0eabbf0a9f2ab", "He1", "bac8bac7daade0c0", "He2", "bacdbacfbacebad3bacbbac9bacabaccbad0bad1bad2bad4dbc0e3d8e6fceac2eec1f2a2f2c2f4e7", "He4", "bacdbacebad8bac9bad5bac8bad6bad7cfc5dbd6", "Hei1", "badabad9e0cb", "Hen2", "badb", "Hen3", "badcbadd", "Hen4", "bade", "Heng1", "bae0badf", "Heng2", "d0d0bae2bae1bae3debfe7f1e8ec", "Heng4", "bae1", "Hng5", "badf", "Hong1", "bae4bae5bae6d9eadeb0", "Hong2", "baecbae8bae9bae7baeabaebd9e4dda6deaee3c8e3fc", "Hong3", "bae5", "Hong4", "bae5daa7deae", "Hou3", "baf0", "Hou4", "baf3baf2baeebaf1dca9e1e1e5cbf6d7", "Hu1", "baf4baf5cfb7baf6bafddffce3b1e4efe9f5ecc3", "Hu2", "bacdbafabacbbafebaf7baf8baf9bafbbafcbafdbba1e0f1e2a9e9ceecb2eccef0c9f5adf5faf7bdf0c0", "Hu3", "bba2bba3e4b0e7fa", "Hu4", "bba4bba5bba7bba2bafdbba6d9fce1b2e2efece6ece8eceff0adf0d7f3cb", "Hua1", "bbafbbaabba8bba9edb9", "Hua2", "bbaabbaebbedbba9bbabbbace6e8eefc", "Hua4", "bbafbbaabbaebbb0bbade8eb", "Huai2", "bbb3bbb1bbb2bbb4f5d7", "Huai4", "bbb5", "Huai5", "bbae", "Huan1", "bbb6e2b5", "Huan2", "bbb9bbb7bbb8dba8ddc8e0f7e4a1e5bee7d9efccf7df", "Huan3", "bbba", "Huan4", "bbbbbbbcbbc0bbc3bbbdbbbebbbfbbc1bbc2dbbcdfa7e4bde4f1e5d5f6e9", "Huang1", "bbc5bbc4ebc1", "Huang2", "bbc6bbcabbcdbbc7bbc8bbc9bbcbbbccdaf2e1e5e4d2e4eae5d8e8abf1a5f3a8f3f2f6fc", "Huang3", "bbcebbcfbbd0bbd1", "Huang4", "bbce", "Hui1", "bbd3bbd6bbd4bbd2b6e9bbd5dab6dfd4e3c4e7f5eacdf2b3f7e2", "Hui2", "bbd8bbb2bbd7dceee4a7", "Hui3", "bbd9bbdaf2b3", "Hui4", "bbe1bbe3bbddbbdbbbe6bbdfbbdcbbdebbe0bbe2bbe4bbe5c0a3dcf6dea5dfdce0b9e4abe5e7e7c0e8ededa3f3b3", "Hun1", "bbe9bbe8bbe7e3d4", "Hun2", "bbecbbeabbebe2c6e7f5", "Hun4", "bbecdabbe4e3", "Huo1", "bbedd8e5dfabefc1f1eb", "Huo2", "bacdbbee", "Huo3", "bbf0bbefe2b7eed8", "Huo4", "bacdbbf5bbf2bbf1bbf6bbedbbf4bbf3debde0ebefecf3b6", "Ji1", "c6e4bbfac6dabbf9bcb8bbfdbca4bca8c6e6bca3bbfcbbf8bca7bbf7bbfbbbfebca1bca2bca5bca6bca9d8a2d8c0d8dedbd4dcb8dfb4dfd2dff3e5ece7dce7e1eae5eaf7ecb4edb6eebfeffaf3c7f5d2", "Ji2", "bcb0bcb6bcb4bcaabcabbcafbcb1bcaeb8efbde5e1a7bcb2bcadbcacbcb3bcb5bcb9d8bdd9a5dab5ddf0deaae1d5e9aee9eaeaabf1a4f3c5", "Ji3", "bcc3b8f8bcbabcb8bccdb8efbcb7bcb9dee1eaaaf2b1f7e4", "Ji4", "bcc6bcc3cfb5bccabcccbcc7bcbcbccdbcc4f4dfbcbebcc8c6ebbcc1bcc0bcbbbcbdbcbfbcc2bcc5bcc9bccbd9cadcc1dcf9dfe2e4a9e6f7eae9f0a2f5d5f6abf6ddf6eaf7d9", "Jia1", "bcd3bcd2bccebcd1bcd0bccfc7d1d0aed9a4dde7e4a4e5c8e7ecefd8f0e8f3d5f4c2f5ca", "Jia2", "bcd0bcd4bcd5dba3eaa9eda2eef2f1caf2cc", "Jia3", "bcd9bdc7bdc9bdc5bcd7bcd6bcd8bdc1bdc2bdc3bdc4bdc6bdc8bdcabdcbd8c5d9aeded8e1b5e1e8e4d0ebb8ebcef0a8f0fd", "Jia4", "bcdbbcd9bcddbcdcbcdabcde", "Jia5", "bcd2", "Jian1", "bce4bce0bce1bda5bce6bce8bce2c7b3bcdfbce3bce5bce7bce9bceabda6ddd1ddf3def6e4d5e7cceaa7eaf9f0cff6e4f7b5", "Jian3", "bcecbcf5bcf2bcf3bcedbcf4bcebbceebcefbcf0bcf1dad9e0eee5bfe5c0e8c5eaafedfaefb5f1d0f3c8f4e5f5c2", "Jian4", "bda8bce4bcfebcfbbce0bda1bda5bcf8bcf6bda3bcf7bcf9bcfabcfcbcfdbda2bda4bda6bda7d9d4dac9e9a5eaf0eba6ebecefb5f5dd", "Jiang1", "bdabbdadbda9bdaabdacbdaedcfce7d6ede4f4f8", "Jiang3", "bdb2bdb1bdafbdb0f1f0", "Jiang4", "bdabc7bfbdb5bae7bdacbdb3bdb4e4aee7adeaf1f4dd", "Jiao1", "bdccbdbbbdbabdb8bdb9bdb6bdb7bdbcbdbdbdbebdbfd9d5dcb4dcfae6aff0d4f2d4f5d3f6de", "Jiao2", "bdc0bdc3e1bd", "Jiao3", "bdc7bdc9bdc5ded8bdc1bdc2bdc3bdc4d9aef0a8ebb8e1e8bdc6bdc8e4d0bdcabdcb", "Jiao4", "bdccd0a3bdcfbef5bdd0bdc0bdcdbdcebdd1e0dde1bde1e8f5b4", "Jie1", "bdd3bde1bddabdd7bdd6bdd4bdd2bdd5bface0aee0b5f0dc", "Jie2", "bde1bddabdd8bde0bddcbdd9bdddbddfbddbbdded9cadaa6dab5ded7e6bce6dde8eeedd9f2a1f4c9f6da", "Jie3", "bde2bde3", "Jie4", "bcdbbde2bde7bdecbde9bde5bde8bde4bde6bdeabdebf2bbf7ba", "Jie5", "bcd2bcdb", "Jin1", "bdf1bdf0bdfbbdf2bdedbdeebdefbdf3f1c6f1e6", "Jin3", "bea1bdf4bdf6bdf5bdf7dae1ddc0e2cbe2dbe8aae9c8", "Jin4", "bdf8bdfcbea1bdf6bdfbbdfabdf9bdfdbdfebea2dda3e0e4e6a1e7c6eae1eaee", "Jing1", "beadbeabbeaabea9bea6bea3bea4bea5bea7bea8beacddbce3feebe6ecba", "Jing3", "beafbeb0beaebeb1d8d9d9d3dae5e3bdebc2", "Jing4", "beadbeb9beb3beb4beb2bebbbeb6beb5bea2beb7beb8bebae2b0e5c9e5f2e6baebd6f6a6", "Jiong1", "ece7", "Jiong3", "bebcbebde5c4eac1", "Jiu1", "bebfbec0bebee0b1e3cef0aff4f1f7dd", "Jiu3", "bec5bec3bec6bec1bec2bec4", "Jiu4", "becdbec9bec8bec7becabecbbeccbeced9d6e8d1e8eaf0d5", "Ju1", "beddb3b5c7d2bed3bee3bee2bed0becfbed1bed2bed4dcdadee4e8a2e9a7efb8f1d5f4f2f6c2f7b6", "Ju2", "bed6bddbbed5e9d9efb8", "Ju3", "bed9bedab9f1bed7bed8dcece8dbe9b7f5e1f6b4", "Ju4", "beddbedfbedebee3bee7bedcbee4bee2bee0bedbbedabee5bee1bee6d9c6daaadcc4e5e1e5f0e9b0eaf8ecabeed2f1c0f4f2f5b6f6c4", "Juan1", "bee8c8a6bee9beeae4b8eec3efd4", "Juan3", "beedefc3", "Juan4", "beedbfa1c8a6beebbeecbeeedbb2e1fae8f0f6c1", "Jue1", "beefe0b5e0d9", "Jue2", "bef6bdc7bef4bef8bef5bdc5bef2bdc0bef0bef1bef3bef7d8cad8e3dadcdbc7dea7e0e5e1c8e2b1e6dee7e5e8f6e9d3ecdfefe3f5eaf5fb", "Jue3", "f5ea", "Jue4", "bef3", "Jun1", "befcbef9befdb9eabefabefbf1e4f3def7e5", "Jun4", "bfa2bfa1befabefebfa3bfa4bfa5dedc", "Ka1", "bfa7bfa6dfc7", "Ka3", "bfa8bfa9d8fbdfc7ebcc", "Kai1", "bfaabfabefb4", "Kai3", "bfaebfacbfadd8dcdbeedddce2fdeef8efc7", "Kai4", "e2e9", "Kan1", "bfb4bfafbfb0bfb1eaacede8", "Kan3", "bfb2bfb3bcf7d9a9dda8e3db", "Kan4", "bfb4c7b6e3dbeeab", "Kang1", "bfb5bfb6bfb7e3ca", "Kang2", "bfb8", "Kang4", "bfb9d8f8bfbabfbbe3caeed6", "Kao1", "e5ea", "Kao3", "bfbcbfbdbfbee8e0", "Kao4", "bfbfeafbeeed", "Ke1", "bfc6bfc2bac7bfc0bfc1bfc3bfc4bfc5e0bee7e6e9f0eea7eeddeffdf0e2f1bdf2a4f2f2f7c1", "Ke2", "bfc7bfc8f2a4", "Ke3", "bfc9bfc0bfcae1b3e9f0", "Ke4", "bfc9bfcbbfcdbfcebfcce0bee3a1e4dbe6ece7bcebb4efbef2c2", "Ken3", "bfcfbfd0bfd1bfd2f6b8", "Ken4", "f1cc", "Keng1", "bfd3bfd4efac", "Kong1", "bfd5d9c5e1c7f3ed", "Kong3", "bfd6bfd7d9c5", "Kong4", "bfd5bfd8", "Kou1", "bfd9dcd2edee", "Kou3", "bfda", "Kou4", "bfdbbfdcdea2dfb5f3d8", "Ku1", "bfdebfddbfdfd8dadca5f7bc", "Ku3", "bfe0", "Ku4", "bfe2bfe3bfe1e0b7e7ab", "Kua1", "bfe4", "Kua3", "bfe5d9a8", "Kua4", "bfe6bfe7bfe8", "Kuai3", "d8e1", "Kuai4", "bbe1bfecbfe9bfeabfebdba6dfe0e1f6e4abebda", "Kuan1", "bfedf7c5", "Kuan3", "bfee", "Kuang1", "bfefbff0bff2dab2dfd1", "Kuang2", "bff1dabf", "Kuang3", "dec5", "Kuang4", "bff6bff3bff2bff4bff5daf7dbdbe6feeadc", "Kui1", "bff7bff8bff9bffae3a6", "Kui2", "bffbbffcbffdd8b8d9e7daf3def1e0ade5d3ead2eea5f2f1", "Kui3", "bffef5cd", "Kui4", "e3b4c0a1c0a2c0a3d8d1dddee0b0f1f9f3f1", "Kun1", "c0a4c0a5e7fbefbff5abf6eff7d5", "Kun3", "c0a6e3a7e3cd", "Kun4", "c0a7", "Kuo4", "c0a8cacac0a9c0abc0aae8e9f2d2", "La1", "c0adc0acc0aec0b2e5e5", "La2", "c0adc0aeeab9edc7", "La3", "c0adc0ae", "La4", "c0adc2e4d8ddc0b0c0afc0b1f0f8", "La5", "c0b6c0b2", "Lai2", "c0b4c0b3e1c1e1e2e4b5efaa", "Lai4", "c0b5e4feeae3edf9f1aef4a5", "Lan2", "c0bcc0b6c0b7c0b8c0b9c0bac0bbc0bdc0bee1b0ecb5efe7f1dc", "Lan3", "c0c0c0c2c0c1c0bfe4ede9adeebd", "Lan4", "c0c4c0c3", "Lang1", "e0a5", "Lang2", "c0c8c0c9c0c5c0c6c0c7e3cfefb6effcf2eb", "Lang3", "c0ca", "Lang4", "c0cbc0c9ddb9ddf5e3cf", "Lao1", "c0cc", "Lao2", "c0cdc0cedfebe1c0efa9f0ecf5b2", "Lao3", "c0cfc0d0c0d1c1cae8e1eeee", "Lao4", "c2e7c2e4c0d2c0d3c0d4dfebf1ec", "Le1", "c0df", "Le4", "c0d6c0d5dfb7d8ece3eef7a6", "Le5", "c1cb", "Lei1", "c0d5c0de", "Lei2", "c0d7c0dbc0d8c0ded9fae6d0e7d0e9db", "Lei3", "c0dbc0d9c0dac0dcc0dddab3f1e7", "Lei4", "c0e0c0dbc0dec0dfc0e1f5aa", "Lei5", "e0cf", "Leng1", "c0e2", "Leng2", "c0e2c0e3dca8", "Leng3", "c0e4", "Leng4", "e3b6", "Li1", "c1a8", "Li2", "c0ebc0f6c0e5c0e8c0e6c0e7c0e9c0eac0ecc1a7ddf1debce0ace6cbe6eae7caeebef0bff2dbf3bbf6e2f7f3", "Li3", "c0edc0efc0eec0f1c1a8c0f0d9b5e3a6e5a2e5cee6b2efaef3bbf5b7f7af", "Li4", "c0fbc1a6c1a2c0fdc0fac0f8c0f6d9b3c0f7ddb0c1a5c0f2c0f3c0f4c0f5c0f9c0fcc0fec1a1c1a3c1a4d8aadbaadbdedcc2debadfbfe0a6e1fbe4e0e8c0e8dde9f6ece5edc2eebaf0ddf0dff2c3f3d2f3f6f4cff5c8f6a8", "Li5", "c1a8c1a7", "Lia3", "c1a9", "Lian2", "c1aac1acc1aec1abc1adc1afc1b0c1b1dec6e5a5eca1f1cdf3b9f6e3", "Lian3", "c1b3c1b2ddfce7f6f1cf", "Lian4", "c1b7c1b6c1b4c1b5e4f2e9ace9e7", "Liang2", "c1bfc1bcc1bac1b8c1b9c1bbdcaeddb9e9a3f5d4", "Liang3", "c1bdc1a9f7cb", "Liang4", "c1bfc1bec1c2c1c1c1b9c1c0f5d4f6a6", "Liao1", "c1c3c1cc", "Liao2", "c1c6c1c5c1c3c1c4c1c7c1c8c1c9c1cce0dae2b2e5bce7d4f0d3", "Liao3", "c1cbc1c7c1cadea4eec9", "Liao4", "c1cbc1cfc1cec1c3c1ccc1cddecdeec9", "Lie1", "dfd6", "Lie3", "c1d1dfd6", "Lie4", "c1d0c1d2c1d1c1d3c1d4d9fddbf8dee6e4a3f4f3f5f1f7e0", "Lie5", "dfd6", "Lin2", "c1d6c3d8c1d9f7ebc1dac1d5c1d7c1dbc1dcdff8e1d7e5e0eaa5eeacf4d4c1d8", "Lin3", "c1dde2dee3c1e9dd", "Lin4", "c1dcc1dec1dfddfeeca2f5ef", "Ling1", "c1e0", "Ling2", "c1eec1e3f1f6c1e4c1e9c1eac1e8c0e2c1e1c1e2c1e5c1e6c1e7dbb9dcdfe0f2e3f6e7b1e8dae8f9eab2f2c8f4e1f6ec", "Ling3", "c1eec1ecc1eb", "Ling4", "c1edc1eedfca", "Liu1", "c1efecd6", "Liu2", "c1f7c1f4c1f5c1f6c1f0c1f1c1f2c1f3e4afe5dee6f2ecbcefd6f6cc", "Liu3", "c1f8e7b8efb3", "Liu4", "c1f9c2bdc2b5c1efc1f3e5deefd6f0d2", "Lo5", "bfa9", "Long1", "c2a1", "Long2", "c2a1c1fdc1fac1fbc1fcc1fedcd7e3f1e7e7e8d0ebcaedc3f1aa", "Long3", "c1fdc2a2c2a3c2a4dbe2", "Long4", "c5aa", "Lou1", "c2a7", "Lou2", "c2a5c2a6d9cddde4e0b6f1eff2f7f7c3", "Lou3", "c2a7c2a8e1d0", "Lou4", "c2b6c2a9c2aaefcef0fc", "Lou5", "e0b6", "Lu1", "dfa3e0e0", "Lu2", "c2acc2abc2adc2aec2afdbe4e3f2e8d3e9f1ebcdf0b5f4b5f6d4", "Lu3", "c2b3c2abc2b0c2b1c2b2e9d6efe5", "Lu4", "c1f9c2b7c2b6c2bcc2bdc2ccc2b8c2b5c2b4c2b9c2bac2bbc2bedea4e4cbe4f5e5d6e8b4e9fbeaa4f0d8f3fc", "Lu5", "e9f1ebaa", "Lu:3", "c2c3c2c0c2c4c2c1c2c2c2c5c2c6d9cddedbebf6eff9f1da", "Lu:4", "c2cac2c9c2c7c2ccc2cbc2c8", "Lu:5", "c2bfe3cce9b5", "Luan2", "c2cdc2cec2cfc2d0d9f5e6aee8eff0bdf6c7", "Luan3", "c2d1", "Luan4", "c2d2", "Lue:3", "c2d3", "Lue:4", "c2d4c2d3efb2", "Lun1", "c2d5", "Lun2", "c2dbc2d6c2d7c2d9c2d8c2d5c2dae0f0", "Lun4", "c2db", "Luo1", "c2dec2e4dedb", "Luo2", "c2dec2dfc2dcc2ddc2e0c2e1c2e2e2a4e9a1ebe1efdd", "Luo3", "c2e3d9c0d9f9f1a7", "Luo4", "c2e7c2e4c2e5bfa9c0d3c2e6dcfddefbe3f8e4f0e7f3edd1f6c3", "Luo5", "c2de", "M2", "dfbc", "Ma1", "c4a6c2e9c2e8c2ecc4a8e6d6", "Ma2", "c2e9c2f0f3a1", "Ma3", "c2edc2ebc2eac2f0c2ece1ef", "Ma4", "c2ecc2eedfe9e8bf", "Ma5", "c3b4c2f0c2ef", "Mai2", "c2f1f6b2", "Mai3", "c2f2dda4", "Mai4", "c2f4c2f3c2f5c2f6dbbd", "Man1", "f2a9", "Man2", "c2f1c2f7c2f8c2f9c2fbc3a1f7a9f7b4", "Man3", "c2faf2fd", "Man4", "c2fcc2fdc2fbc2fec3a1dcace1a3e7cfecd7efdc", "Mang2", "c3a6c3a4c3a2c3a3c3a5daf8edcb", "Mang3", "c3a7e4ddf2fe", "Mao1", "c3a8", "Mao2", "c3abc3a8c3a9c3aac3acdce2eaf3ecb8f3b1f7d6", "Mao3", "c3adc3aee1b9e3f7eac4", "Mao4", "c3b3c3b0c3b1c3afc3b2d9f3e8a3eba3edaeeea6", "Me5", "c3b4f7e1", "Mei2", "c3bbc3b6c3bdc3bcc3b5c3b7c3b8c3b9c3bac3d3ddaee1d2e2ade4d8e9b9efd1f0cc", "Mei3", "c3c0c3bfc3bee4bc", "Mei4", "c3c1c3c2c3c3c3c4c3d5f1c7f7c8", "Men1", "c3c6", "Men2", "c3c5ded1eecd", "Men4", "c3c6eccbedaf", "Men5", "c3c7", "Meng1", "c3c9", "Meng2", "c3c9c3a5c3c8c3cac3cbddf9deabebfcede6f2b5f4bf", "Meng3", "c3c9c3cdc3ccdbc2e3c2f2ecf3b7f4bb", "Meng4", "c3cec3cf", "Mi1", "c3d0dfe4", "Mi2", "c3d4c3d1c3d2c3d3c3d5c3d6dec2e2a8ecf2f7e3f7e7", "Mi3", "c3d7f4cdc3d0c3d2d8c2e5f4ebdf", "Mi4", "c3d8c3dcc3d9c3dac3dbc3dddad7e0d7e3e8e5b5f4e9", "Mian2", "c3dfc3dec3e0", "Mian3", "c3e2c3e3c3e1c3e4c3e5e3e6e4c5e4cfebefededf6bc", "Mian4", "c3e6", "Miao1", "dff7", "Miao2", "c3e7c3e8c3e9f0c5", "Miao3", "c3eac3ebc3ece5e3e7bfe8c2edb5edf0", "Miao4", "c3eec3ede7d1", "Mie1", "d8bfdfe3", "Mie4", "c3f0c3eff3baf3fa", "Min2", "c3f1dce5e1bae7c5e7e4e7eb", "Min3", "c3f4c3f2c3f3c3f5c3f6e3c9e3fdedaaf6bcf7aa", "Ming2", "c3fbc3f7c3fac3f9c3cbc3f8daa4dcf8e4e9ead4eea8", "Ming3", "f5a4", "Ming4", "c3fc", "Miu4", "c3fde7d1", "Mo1", "c3fe", "Mo2", "cedec4a3c4a6c4a5c3fec4a1c4a4c4a7c4a2dad3e2c9e6c6f7e1", "Mo3", "c4a8", "Mo4", "cdf2c3bbc4a9c3b0c4aac4acc4a5bad1bad9c2f6c4a8c4abc4adc4aec4afc4b0dcd4ddebe9e2efd2eff7f1a2f1f2f5f6f5f8", "Mou1", "dfe8", "Mou2", "c4b1c4b2d9b0e7d1edf8f2d6f2faf6ca", "Mou3", "c4b3", "Mu2", "c4a3eba4", "Mu3", "c4b8c4b6c4b7c0d1c4b4c4b5", "Mu4", "c4bfc4bec4bbc4bcc4c2c4b2c4b9c4bac4bdc4c0c4c1d8efdbe9dcd9e3e5eee2", "N2", "e0c5", "N3", "e0c5", "N4", "e0c5", "Ng2", "e0c5", "Ng3", "e0c5", "Ng4", "e0c5", "Na1", "c4cfc4c7", "Na2", "c4c3efd5", "Na3", "c4c7c4c4", "Na4", "c4c7c4c9c4d8c4c5c4c6c4c8ebc7f1c4dee0", "Na5", "c4c4c4c5", "Nai3", "c4cbc4c4c4cac4ccdcb5", "Nai4", "c4cec4cdd8bed9a6ddc1e8cd", "Nan1", "e0eee0ef", "Nan2", "c4cfc4d1c4d0e0abe9aa", "Nan3", "ebeef2eff4f6", "Nan4", "c4d1", "Nang1", "c4d2e0ec", "Nang2", "c4d2e2ce", "Nang3", "dfade2ceead9", "Nao1", "d8ab", "Nao2", "c5acc4d3dfcee2aeedd0eef3f2cd", "Nao3", "c4d4c4d5dbf1e8a7", "Nao4", "c4d6c4d7", "Ne2", "c4c4", "Ne4", "c4d8c4c5daab", "Ne5", "c4d8c4c5", "Nei3", "c4c4c4d9", "Nei4", "c4dac4c7", "Nen4", "c4dbeda5", "Neng2", "c4dc", "Ni1", "c4dd", "Ni2", "c4e1c4d8c4e0c4dec4dfdbe8e2a5e2f5eeeaf6f2", "Ni3", "c4e3c4e2ecbbecf2", "Ni4", "c4e0c4e4c4e5c4e6c4e7c4f2d9a3eac7edabedfe", "Nian1", "c4e9c4e8", "Nian2", "c4ead5b3f0a4f6d3f6f3", "Nian3", "c4ebc4ecc4ede9fd", "Nian4", "d8a5c4eec4f0dbfe", "Niang2", "c4f0c4ef", "Niang4", "c4f0", "Niao3", "c4f1dce0e6d5f4c1", "Niao4", "c4e7c4f2ebe5", "Nie1", "c4f3", "Nie4", "c4f4c4f5c4f6c4f7c4f8c4f9d8bfdaeddec1e0bff2a8f4abf5e6", "Nin2", "c4faeda5", "Ning2", "c4fec4fbc4fcc4fdc5a1dcd1dfcce5b8f1f7", "Ning3", "c5a1", "Ning4", "c4fec5a1c5a2d8fa", "Niu1", "e6a4", "Niu2", "c5a3", "Niu3", "c5a6c5a4c5a5e1f0e2ee", "Niu4", "ded6", "Nong2", "c5a9c5a7c5a8d9afdfe6", "Nong4", "c5aa", "Nou4", "f1f1", "Nu2", "c5abe6dbe6e5", "Nu3", "c5ace5f3e6c0", "Nu4", "c5ad", "Nu:3", "c5aeeecf", "Nu:4", "eda4f4ac", "Nuan3", "c5af", "Nue:4", "c5b0c5b1", "Nuo2", "c4c8c5b2d9d0", "Nuo4", "c5b5c5b3c5b4def9dff6efbb", "Ou1", "c7f8c5b7c5b9c5b8c5bddaa9eab1", "Ou3", "c5bcc5bac5bbf1ee", "Ou4", "c5bbc5bde2e6", "Pa1", "c5c9dde2b0c7c5bec5bf", "Pa2", "c5c0b0c7b0d2e8cbeed9f3e1", "Pa4", "c5c2c5c1", "Pa5", "c5c3", "Pai1", "c5c4", "Pai2", "c5c5c5c6c5c7d9bd", "Pai3", "c5c5c6c8", "Pai4", "c5c9c5c8dde5dfdf", "Pan1", "c5cbb7acb0e2c5ca", "Pan2", "b0e3c5ccc5cdc5d6e3ddf3b4f5e7", "Pan4", "c5d0c5cec5cfc5d1ded5e3faf1c8f1e1", "Pang1", "b0f2c5d2e4e8", "Pang2", "c5d4c5d3b0f5b0f2e1dde5ccf3a6", "Pang3", "c5d5", "Pang4", "c5d6", "Pao1", "c5dac5d7c5ddebe3", "Pao2", "c5dac5dcc5d8c5d9c5dbdecbe1f3e2d2", "Pao3", "c5dc", "Pao4", "c5dac5ddf0e5", "Pei1", "c5dec5dff5ac", "Pei2", "c5e2c5e3c5e0c5e1efc2", "Pei4", "c5e4c5e5c5e6e0ceecb7f6ace0fa", "Pen1", "c5e7", "Pen2", "c5e8e4d4", "Pen4", "c5e7", "Peng1", "c5eac5e9c5ebc5ece0d8e2f1", "Peng2", "c5f2c5f3c5edc5eec5ecc5efc5f0c5f1c5f4dca1f3b2", "Peng3", "c5f5", "Peng4", "c5f6", "Pi1", "c5fac5fbbbb5b1d9c5f7c5f8c5f9c5fcd8a7dafce0e8e7a2eeeb", "Pi2", "c6a4c5fdc5fec6a1c6a2c6a3dae9daf0dbafdbfddcb1dcc5e8c1eebceeebf1d4f2b7f2e7f5f9", "Pi3", "b7f1c6a6c5fcc6a5d8f2dbdcdfa8dfc1e2cff1b1f1e2", "Pi4", "b1d9c6a9c6a7c6a8e4c4e6c7eea2", "Pian1", "c6acc6aab1e2c6abeafaf4e6", "Pian2", "b1e3e6e9e7c2ebddf5e4", "Pian3", "dad2", "Pian4", "c6acc6ad", "Piao1", "c6aec6afd8e2e7cef3aa", "Piao2", "c6b0c6d3e6ce", "Piao3", "c6afddb3e7cee9e8eea9", "Piao4", "c6b1c6afe0d1e6f4", "Pie1", "c6b2c6b3ebad", "Pie3", "c6b2d8afdcd6", "Pin1", "c6b4ded5e6b0", "Pin2", "c6b5c6b6c6bbe6c9f2ad", "Pin3", "c6b7e9af", "Pin4", "c6b8eaf2", "Ping1", "c6b9d9b7e6b3", "Ping2", "c6bdc6c0c6bec6bfb7ebc6bac6bbc6bcc6c1e8d2f6d2", "Po1", "c6c2b2b4c6c4c6c3c6d3dae9e3f8eab7eec7", "Po2", "b7b1c6c5dbb6f0ab", "Po3", "d8cfeedef3cd", "Po4", "c6c6c6c8c6c7c6c9c6d3e7ea", "Pou1", "c6ca", "Pou2", "d9f6dee5", "Pou3", "dee5", "Pu1", "c6ccc6cbc6cde0db", "Pu2", "b8acc6cdc6cec6cfc6d0c6d1d9e9e5a7e8b1efe4", "Pu3", "c6d5c6d2b1a4c6d4c6d7c6d3c6d6e4dfebabefe8f5eb", "Pu4", "b1a9b1a4c6ccc6d8c6d9", "Punctuations", "a1a2a1a3a1a4a1a5a1a6a1a7a1a8a1a9a1aaa1aba1aca1ada1aea1afa1b0a1b1a1b2a1b3a1b4a1b5a1b6a1b7a1b8a1b9a1baa1bba1bca1bda1bea1bfa9a8a9a9a9aaa9aba9aca9ada9aea9af", "Qi1", "c6dfc6dac6e1c6dbc6debca9c6dcc6ddc6e0c6e2c6e3ddc2e0d2e8e7e9caeca5f5e8", "Qi2", "c6e4c6ecc6e6c6efc6e7c6ebc6e5ecf7c6e8c6e8c6eac6edc6eed8c1d9b9dbdfdccedcf9ddbddeade4bfe6ebe7f7e7f9eac8f1fdf2d3f2e0f4ebf7a2f7e8e1aac6e9", "Qi3", "c6f0c6f3c6f4c6f2bbfcc6f1dcbbe1a8e7b2e8bdf4ec", "Qi4", "c6fbc6f7c6f8c6fac6f9c6ebc6f5c6dec6f6c6fcc6fdd8bddddde3e0edacedd3", "Qia1", "c6fed9a4ddd6f1ca", "Qia3", "bfa8", "Qia4", "c7a2c7a1f7c4", "Qian1", "c7a7c7a9c7a8c7aac7a3c7a4c7a5c7a6c7abd9dddae4dcb7e1a9e3a5e5b9e5bae5bdeda9", "Qian2", "c7b0c7aec7b1c7acc7adc7afdda1dee7eaf9eed4f2aff3e9f7dc", "Qian3", "c7b2c7b3c7b4e7d7ebc9", "Qian4", "c7b7c7b5c7b6c7b8cfcbd9bbdccddce7e3bbe8fd", "Qiang1", "bdabc7b9c7c0c7bac7bbc7bce3deeaa8efbaefcfefeaf2def5c4", "Qiang2", "c7bfc7bdc7bee6cde9c9", "Qiang3", "c7bfc7c0efeaf1dff4c7", "Qiang4", "c7baeaa8ecc1f5c4", "Qiao1", "c7c1c7c2c7c4c7c3c8b8d8e4e7d8edcdf5ce", "Qiao2", "c7c5c7c8c7c7bdb6c7c6c7ccdadbdcf1e1bde3bee9d4f7b3", "Qiao3", "c7c9c7c4c8b8e3b8", "Qiao4", "bfc7c7cac7cbc7ccc7cdc7cec7cfdabddadb", "Qie1", "c7d0", "Qie2", "c7d1d9a4", "Qie3", "c7d2", "Qie4", "c7d0c6f6c7d3c7d4dba7e3abe3bbe6aaeafcefc6f3e6f4f2", "Qin1", "c7d7c7d5c7d6f4c0", "Qin2", "c7dac7d8c7d9c7dbc7dcc7dddccbe0bae0dfe2dbe4dae9d5efb7f1e6f1fbf2fb", "Qin3", "c7de", "Qin4", "c7dfdeecdfc4", "Qing1", "c7e0c7e5c7e1c7e3c7e4c7e2e0f5f2dff6eb", "Qing2", "c7e9c7e6c7e7c7e8e9d1f7f4", "Qing3", "c7ebc7eadcdcf6a5", "Qing4", "c7ecc7d7ede0f3c0f3e4f4ec", "Qiong2", "c7eec7eddaf6dce4f1b7f2cbf3ccf5bcf6c6", "Qiu1", "c7f1c7efb9eac7f0e4d0e9b1f2c7f6fa", "Qiu2", "c7f3c7f2b3f0c7f4c7f5c7f6d9b4dbcfe1ece5cfe5d9eae4f2b0f2f8f4c3f7fc", "Qiu3", "f4dc", "Qu1", "c7f8c7fdc7f7c7fac7fcc7f9c7fbdab0e1abeaefeceef2d0f4f0f7f1", "Qu2", "f1b3c7fedbbedea1debee1e9e8b3ebacebd4ede1f0b6f3bdf6c4", "Qu3", "c8a1c7fac8a2c8a3dcc4", "Qu4", "c8a5c8a4e3d6eaef", "Qu5", "d0e7", "Quan1", "c8a6e3aa", "Quan2", "c8abc8a8c8aac8a7c8a9c8acc8addab9dcf5e9faeefdf2e9f3dcf7dc", "Quan3", "c8aee7b9eeb0", "Quan4", "c8afc8b0", "Que1", "c8b1c8b2e3da", "Que2", "c8b3", "Que4", "c8b7c8b4c8b5c8b6c8b8e3d7e3daeda8", "Qun1", "e5d2", "Qun2", "c8bac8b9f7e5", "Ran2", "c8bbc8bcf2c5f7d7", "Ran3", "c8bec8bddcdb", "Rang1", "c8c2", "Rang2", "c8bfecfcf0a6", "Rang3", "c8c0c8c1c8c2ecfc", "Rang4", "c8c3", "Rao2", "c8c4dce9e6ace8e3", "Rao3", "c8c5c8c6e6ac", "Rao4", "c8c6", "Re3", "c8c7c8f4dff6", "Re4", "c8c8", "Ren2", "c8cbc8cec8cac8c9", "Ren3", "c8ccdcf3effe", "Ren4", "c8cec8cfc8cdc8d1c8d2c8d0d8f0ddd8e2bfe9edf1c5", "Reng1", "c8d3", "Reng2", "c8d4", "Ri4", "c8d5", "Rong2", "c8dac8ddc8d9c8dec8d6c8d7c8d8c8dbc8dce1c9e1f5e9c5ebc0f2ee", "Rong3", "c8df", "Rou2", "c8e1c8e0f4dbf5e5f7b7", "Rou4", "c8e2", "Ru2", "c8e7c8e3c8e4c8e5c8e6deb8e0e9e5a6efa8f1e0f2ac", "Ru3", "c8e8c8e9c8ea", "Ru4", "c8ebc8ecddeae4b2e4e1e7c8", "Ruan3", "c8edc8eeebc3", "Rui2", "dea8", "Rui3", "c8ef", "Rui4", "c8f0c8f1dcc7e8c4eea3f2b8", "Run4", "c8f3c8f2", "Ruo4", "c8f4c8f5d9bcf3e8", "Sa1", "c8f6d8edeafd", "Sa3", "c8f6c8f7", "Sa4", "d8a6c8f8ebdbecaa", "Sai1", "cbbcc8fbc8f9c8fae0e7", "Sai4", "c8fcc8fb", "San1", "c8fdc8feeba7", "San3", "c9a2c9a1e2ccf4d6f6b1", "San4", "c9a2", "Sang1", "c9a5c9a3", "Sang3", "c9a4defaeddff2aa", "Sang4", "c9a5", "Sao1", "c9a6c9a7e7d2e7d8ebfdf6fe", "Sao3", "c9a8c9a9", "Sao4", "c9a8c9d2dca3ebfdf0fe", "Se4", "c9abc8fbc9aac9acd8c4efa4f0a3", "Sen1", "c9ad", "Seng1", "c9ae", "Sha1", "c9b3c9b2c9b1c9afc9b0c9b4c9b7c9bceafdefa1f0f0f4c4f6e8", "Sha3", "c9b5", "Sha4", "c9b3cfc3c9b6c9b7dffee0c4eca6f6ae", "Shai1", "c9b8f5a7", "Shai3", "c9ab", "Shai4", "c9b9", "Shan1", "c9bdf4aec9bac9bbc9bcc9bec9bfc9c0c9c8d5a4dbefdccfe4fae6a9ebfeeeccf5c7f7d4", "Shan3", "c9c1b2f4b5a7c9c2", "Shan4", "b5a5c9c6b5a7c9bbc9c3c9c4c9c5c9c7c9c8c9c9d8dfdaa8dbb7e6d3e6f3ecf8eeccf0def3b5f7ad", "Shang1", "c9ccc9cbccc0c9cae9e4ecd8f5fc", "Shang3", "c9cfc9cdc9cedbf0", "Shang4", "c9cfc9d0e7b4", "Shang5", "c9d1", "Shao1", "c9d4c9d5c7cac9d2c9d3f2d9f3e2f4b9", "Shao2", "c9d6c9d7c9d8dce6e8bc", "Shao3", "c9d9", "Shao4", "c9d9c9d4c9dcd5d9c9dbc9d3c9dadbbfe4fb", "She1", "c9ddc9dee2a6eeb4", "She2", "d5dbc9e0c9dfd9dc", "She3", "c9e1", "She4", "c9e7c9e8c9e6c9e4c9e1c9e3c9e2c9e5d8c7e4dceca8f7ea", "Shei2", "cbad", "Shen1", "b2cec9edc9eac9eec9ecc9e9c9ebc9efc9f0dab7ddb7f4d6", "Shen2", "cab2c9f1c9f5", "Shen3", "c9f3c9f2c9f4dac5dfd3e4c9eff2", "Shen4", "c9f5c9f7c9f6c9f8ddd8e9a9ebcff2d7", "Sheng1", "c9fac9f9c9fdcaa4c9fcc9fbf3cf", "Sheng2", "c9fee4c5", "Sheng3", "caa1edf2", "Sheng4", "caa2caa4caa5b3cbcaa3e1d3eac9", "Shi1", "caa6caa7caa9caaccaa8caabcaaacaadd0eadde9f5a7f6f5", "Shi2", "caaecab1cab5cab2cab6cab3caafcab0cab4dbf5ddaaecc2f6e5", "Shi3", "cab9cabccab7cabbcab8cabaf5b9", "Shi4", "cac7cac2cabfcad0cabecabdcacfcac0cad4cad3cacacac6cacdcad2cbc6cacbcac4cacecacccac1cac3cac5cac8cac9cad1d6c5dad6ddaadfb1e9f8eadbeee6f3a7f3c2f3df", "Shi5", "d6b3b3d7", "Shou1", "cad5", "Shou2", "caec", "Shou3", "cad6cad7cad8f4bc", "Shou4", "cadccadacadbcad9cadecadde1f7e7b7", "Shu1", "cae9cae4cae2cae6d9bfcae0cae8cae1cadfcae3cae5cae7ddc4def3e6ade7a3eba8ecaff1e2", "Shu2", "caeccaeacaebdbd3eff8", "Shu3", "cafdcaf4caf0caeecaedcaefcaf1caf2caf3", "Shu4", "cafdcaf5caf6caf7caf8caf9cafacafbcafccafecba1d3e1d8ade3f0e4f8ebf2", "Shua1", "cba2e0a7", "Shua3", "cba3", "Shua4", "cba2", "Shuai1", "cba5cba4", "Shuai3", "cba6", "Shuai4", "c2cacba7f3b0", "Shuan1", "cba8cba9e3c5", "Shuan4", "e4cc", "Shuang1", "cbabcbaae3f1e6d7", "Shuang3", "cbac", "Shui2", "cbad", "Shui3", "cbae", "Shui4", "cbb5cbb0cbaf", "Shun3", "cbb1", "Shun4", "cbb3cbb2cbb4", "Shuo1", "cbb5", "Shuo4", "cafdcbb6cbb7cbb8ddf4def7e5f9e9c3eee5", "Si1", "cbbecbbdcbb9cbbccbbfcbbacbbbd8cbdbccdfd0e4f9e7c1efc8f0b8f2cf", "Si3", "cbc0", "Si4", "cbc4cab3cbc6e3f4cbc2cbc1cbc3cbc5cbc7cbc8d9b9d9eee3e1e6a6e6e1ecebf1eaf3d3", "Si5", "b2de", "Song1", "cbc9daa1ddbfe1c2e1d4e2ece4c1", "Song3", "cbcacbcbe3a4f1b5", "Song4", "cbcdcbcccbcecbcfcbd0", "Sou1", "cbd2cbd1e0b2e2c8e4d1ecacefcbf2f4", "Sou3", "cbd3dbc5deb4e0d5eea4", "Sou4", "cbd3cbd4", "Su1", "cbd5cbd6f6d5", "Su2", "cbd7", "Su4", "cbd9cbd8cbdfcbf5cbdecbdccbe0cbdacbdbcbddd9eddad5ddf8e0bce3bae4b3f3f9f6a2", "Suan1", "cbe1e2a1", "Suan4", "cbe3cbe2", "Sui1", "cbe4c4f2ddb4e5a1edf5eea1", "Sui2", "cbe6cbeccbe5cbe7", "Sui3", "cbe8", "Sui4", "cbeacbeccbe9cbebcbedcbeedac7e5e4ecdd", "Sun1", "cbefdda5e1f8e2b8", "Sun3", "cbf0cbf1e9bef6c0", "Suo1", "cbf5c9afcbf4cbf2cbf3e0c2e0cae6b6e8f8eafdedfcf4c8", "Suo3", "cbf9cbf7cbf8cbf6dfef", "Symbols", "a1c0a1c1a1c2a1c3a1c4a1c5a1c6a1c7a1c8a1c9a1caa1cba1cca1cda1cea1cfa1d0a1d1a1d2a1d3a1d4a1d5a1d6a1d7a1d8a1d9a1daa1dba1dca1dda1dea1dfa1e0a1e1a1e2a1e3a1e4a1e5a1e6a1e7a1e8a1e9a1eaa1eba1eca1eda1eea1efa1f0a1f1a1f2a1f3a1f4a1f5a1f6a1f7a1f8a1f9a1faa1fba1fca1fda1fea2e5a2e6a2e7a2e8a2e9a2eaa2eba2eca2eda2eea8c5a8c6a8c7a8c8a8c9a8caa8cba8cca8cda8cea8cfa8d0a8d1a8d2a8d3a8d4a8d5a8d6a8d7a8d8a8d9a8daa8dba8dca8dda8dea8dfa8e0a8e1a8e2a8e3a8e4a8e5a8e6a8e7a8e8a8e9", "Ta1", "cbfbcbfccbfdcca4cbfae4e2e5ddeee8f5c1", "Ta3", "cbfecca1f7a3", "Ta4", "cdd8cca4e9bdcca2cca3e3cbe4f0edb3e0aa", "Tai1", "cca8cca5cca6", "Tai2", "cca8cca6cca7dba2deb7e6e6ecc6f5ccf6d8", "Tai3", "dfbe", "Tai4", "ccabccaccca9ccaaccadebc4eed1", "Tan1", "ccb0ccafccb2ccb1ccae", "Tan2", "ccb8ccb3b5afccb7ccb4ccb5ccb6dbb0e5a3eabcefc4efe2f1fb", "Tan3", "ccb9ccbaccbbecfeeee3", "Tan4", "ccbdccbcccbeccbf", "Tang1", "ccc0cccbefa6efdbf1edf4ca", "Tang2", "ccc3ccc6ccc7ccc1ccc2ccc4ccc5e2bce4e7e8a9e9ccefdbf3a5f3abf5b1", "Tang3", "ccc8ccc9cccad9cee0fb", "Tang4", "cccbcccc", "Tao1", "cccfcccdccceccd0dfb6e8baece2f7d2", "Tao2", "ccd3ccd4ccd5ccd1ccd2d8bbdffbe4ac", "Tao3", "ccd6", "Tao4", "ccd7", "Te4", "ccd8dfafecfdedabefab", "Tei1", "dfaf", "Teng2", "ccdaccd9ccdbccdcebf8", "Ti1", "cce5ccddccdeccdfcce0", "Ti2", "cce1cce2cce3cce4dce8e7b0e7bef0c3f5ae", "Ti3", "cce5", "Ti4", "cce6cce8cce7cce9cceaccebd9c3e3a9e5d1e7b0f1d3", "Tian1", "cceccced", "Tian2", "cceeccefb5e8ccf0ccf1e3d9eeb1eee4", "Tian3", "ccf2ccf3e3c3e9e5", "Tian4", "dedd", "Tiao1", "ccf4d9acecf6", "Tiao2", "b5f7ccf5ccf6dce6f2e8f3d4f6b6f6e6f7d8", "Tiao3", "ccf4f1bb", "Tiao4", "ccf7ccf8f4d0", "Tie1", "ccf9ccfbddc6", "Tie3", "ccfaccfb", "Tie4", "ccfbf7d1", "Ting1", "ccfdccfccda1ccfe", "Ting2", "cda5cda3cda2cda4dcf0dde3e6c3f2d1f6aa", "Ting3", "cda7cda6e8e8eeaeeefa", "Ting4", "e8e8", "Tong1", "cda8b6b2e0cc", "Tong2", "cdaccdafcda9b6b1cdaacdabcdadcdaed9a1d9dadbeddcede1bce4fcedc5", "Tong3", "cdb3cdb0b6b1cdb1cdb2", "Tong4", "cdaccda8cdb4e2fa", "Tou1", "cdb5", "Tou2", "cdb6cdb7f7bb", "Tou3", "eed7", "Tou4", "cdb8", "Tu1", "cdbbcdb9cdba", "Tu2", "cdbecdbccdbdcdbfcdc0ddb1ddcbf5a9", "Tu3", "cdc1cdc2eeca", "Tu4", "cdc2cdc3dca2ddcb", "Tuan1", "cdc4", "Tuan2", "cdc5ded2", "Tuan3", "eeb6", "Tuan4", "e5e8", "Tui1", "cdc6dfaf", "Tui2", "cdc7", "Tui3", "cdc8", "Tui4", "cdcbcdc9cdcaecd5", "Tun1", "cdccead5", "Tun2", "b6dacdcdcdcee2bdebe0", "Tun3", "d9db", "Tun4", "cdca", "Tuo1", "cdd0cdd1cdcfd8b1", "Tuo2", "b6e6cdd2cdd3cdd4cdd5d9a2dbe7e3fbe8dee9d2edc8eee8f5a2f5c9f6be", "Tuo3", "cdd7cdd6e2d5", "Tuo4", "cdd8c6c7cdd9e8d8f3ea", "Wa1", "cddbcddab0bccddccddde6b4", "Wa2", "cdde", "Wa3", "cddfd8f4", "Wa4", "cddfcde0ebf0", "Wa5", "cddb", "Wai1", "cde1", "Wai3", "e1cb", "Wai4", "cde2", "Wan1", "cde5cde3cde4d8e0f2ea", "Wan2", "cdeacde6cde8cde7cde9dcb9e6fd", "Wan3", "cdedcdeccdebc3e4cdeecdefcdf0cdf1ddb8ddd2e7bae7feebe4eeb5", "Wan4", "cdf2c2fbcdf3", "Wang1", "cdf4decc", "Wang2", "cdf5cdf6cdfcc3a2", "Wang3", "cdf9cdf8cdf7d8e8e3afe9fef7cd", "Wang4", "cdfbcdf5cdf9cdfacdfccdfd", "Wei1", "ceafcea3cdfecea2cea1ceaed9cbdaf1dddadeb1e1cbe5d4ecd0", "Wei2", "ceaaceaccea7cea8cea9cea5cea4cea6ceabdbd7e0ede0f8e1a1e1cde3c7e3ede4b6", "Wei3", "ceafcea8ceb0ceb2ceb1ceadceaeceb3dac3daf3e2abe4a2e6b8e7e2e8b8ecbff0f4f4baf6db", "Wei4", "ceaacebbceb4cec0cebdceb6d2c5cebfceb5ceb7ceb8ceb9cebacebccebee2aceaa6", "Wen1", "cec2cec1", "Wen2", "cec4cec5cec3cec6e3d3e8b7f6a9", "Wen3", "cec8cec7cec9d8d8", "Wen4", "cecacec6e3ebe8b7", "Weng1", "cecccecb", "Weng3", "ddee", "Weng4", "cecddeb3", "Wo1", "e0b8e0de", "Wo2", "c5b6", "Wo4", "c5b6", "Wo1", "cecececfced0ced1d9c1ddabe0b8", "Wo3", "ced2", "Wo4", "ced5e4d7ced3ced4ced6e1a2ebbfedd2f6bb", "Wu1", "ceddcedbb6f1ced7d8a3ced8ced9cedacedcdaf9dbd8ecb6", "Wu2", "cedecee2cdf6cee0cedfcee1cee3cee6dfede4b4f2daf7f9", "Wu3", "cee5cee7cee4cee9cee8cee6ceead8f5e2d0e2e4e2e8e5c3e5fceaf5f0c4", "Wu4", "cef1ceefcef0b6f1cef3ceebd8a3cef2cedaceecceedceeedae3dccce5bbe6c4e6f0e8bbecc9f0cdf0edf6c8", "Xi1", "cef7cfa3cfa2cefccfa4cef6cefdcefecfa6c0b0cfa7cfa1c6dccef4cef5cef8cef9cefacefbcfa5cfa8cfa9cfaacfabd9d2d9e2dbaddce7ddbedec9dff1e4bbe4c0e9d8ead8eca4eca8ece4f0aaf1b6f2e1f3a3f3acf4b8f4cbf4d1f4e2f5b5f5e8f7fb", "Xi2", "cfafcfb0cfaecfadcfb1daf4eaea", "Xi3", "cfb2cfb4e1e3cfb3dddfddfbe5efe7f4ecfb", "Xi4", "cfb5cfb8cfb7cfb6e2bee3d2ecf9f4aa", "Xia1", "cfb9cfbadfc8", "Xia2", "cfbfcfbbcfbccfbdcfbecfc0cfc1e1f2e5dae8a6e8d4edccf0fdf7ef", "Xia4", "cfc2cfc3cfc4bba3cfc5f3c1", "Xian1", "cfc9cfc8cfcacfc6cfc7cfcbddb2e5dfebafececf4ccf5a3f5d1", "Xian2", "cfcdcfd3cfd0cfcccfcecfcfcfd1cfd2e6b5f0c2f0ef", "Xian3", "cfd5cfd4cfb4cfcacfb3d9fedebae1fdecdef2b9f3daf5d0", "Xian4", "cfd6cfdebcfbcfdfcfd7cfdccfddcfd8cfd9cfdacfdbdcc8e1adf6b1", "Xiang1", "cfe0cfe3cfe4cfe7cfe1cfe2cfe5cfe6dcbce6f8e7bdddd9", "Xiang2", "bdb5cfeacfe9cfe8e2d4", "Xiang3", "cfeccfebcfede2c3f6dff7cf", "Xiang4", "cfeecff2cfe0cff1cff3cfefcff0f3ad", "Xiao1", "cffbcffacff4cffccff7cff5cff6cff8cff9d0a4dfd8e4ece5d0e6e7e7afe8c9e8d5f2d9f3eff7cc", "Xiao2", "cffde1c5", "Xiao3", "d0a1cffef3e3", "Xiao4", "d0a3d0a7d0a6d0a2d0a4d0a5", "Xie1", "d0a9d0a8d0aad0ab", "Xie2", "d0add0b2d2b6d0b3d0afd9c9d0acd0aed0b0d0b1dbc4dfa2e7d3f2a1", "Xie3", "d0b4d1aa", "Xie4", "bde2d0bbd0b4d0b5d0b6c6f5d0b8d0b7d0b9d0bad0bcd9f4dbc6deafe2b3e2dde4cde5ace5e2e7a5e9bfe9c7f5f3", "Xin1", "d0c2d0c4d0bdd0c0d0c1d0bed0bfd0c3dcb0eabfeca7f6ce", "Xin2", "d1b0efe2", "Xin4", "d0c5d0bed0c6d8b6", "Xing1", "d0c7d0cbd0c8d0c9d0ca", "Xing2", "d0d0d0ced0cdd0ccd0cfdaeadcfee2bcedca", "Xing3", "caa1d0d1dfa9", "Xing4", "d0d4d0cbd0d2d0d5d0d3dcf4e3ac", "Xiong1", "d0d6d0d7d0d8d0d9d0dadcba", "Xiong2", "d0dbd0dc", "Xiu1", "d0ded0ddd0dfdfdde2cae2d3f0bcf5f7f7db", "Xiu3", "cbded0e0", "Xiu4", "d0e4cbded0e3b3f4d0e1d0e2d0e5e1b6e4e5", "Xu1", "d0ebd0e8d3f5d0e9d0e6d0e7d0eadbd7e7efedb9edecf1e3", "Xu2", "d0ec", "Xu3", "d0eddabce4b0e8f2f4daf5af", "Xu4", "d0f8d0eed0f2d0f6d0f7d0f0d0f3d0efd0f1d0f4d0f5dbc3e4aae4d3ece3", "Xu5", "dea3", "Xuan1", "d0fbd0f9d0fad9d8dacedde6deefead1ecd3", "Xuan2", "d0fdd0fcd0fee4f6e8aff0e7", "Xuan3", "d1a1d1a2", "Xuan4", "c8afd0fdd1a3d1a4e3f9e4d6e9b8ecc5eddbeee7efe0", "Xue1", "d1a6cff7d1a5", "Xue2", "d1a7d1a8e0e5edb4f5bd", "Xue3", "d1a9f7a8", "Xue4", "d1aadaca", "Xun1", "d1abbbe7d1acdbf7deb9e2b4ead6f1bff5b8", "Xun2", "d1afd1b0d1b2d1add1aed1b1dba8dcf7e1bee2fee4ade4b1f6e0", "Xun4", "d1b6d1b5d1b8d1b7bfa3d1acd1b3d1b4d9e3dea6e1df", "Ya1", "d1b9d1c5d1bad1bbd1bdd1bcd1bed1c6dbebe8e2", "Ya2", "d1bfd1c0d1c1d1c2d1c3d1c4d8f3e1ace7f0edfd", "Ya3", "d1c5c6a5c7c6f0e9f1e2", "Ya4", "d1c7d1b9e5c2d1c8d4fedeebe6abebb2edbc", "Ya5", "d1bd", "Yan1", "d1ccd2f3d1c9d1cad1cbd1cdd1e0dbb3ddcee1c3e2fbe3d5e4cee6ccebd9ebe7", "Yan2", "d1d4d1d0d1cfd1d3d1d8d1d7d1d2d1d5c7a6d1ced1d1d1d6dae7dcbee3c6e5fbe9dcf3db", "Yan3", "d1ddd1dbd1d9d1dad1dcd8c9d8dfd9b2d9c8d9f0dbb1e7fceebbf7caf7faf7fc", "Yan4", "d1d0d1e9d1e7d1d8d1cad1ded1dfd1e0d1e1d1e2d1e3d1e4d1e5d1e6d1e8d8cddadde4d9eacceccdf5a6f7d0", "Yang1", "d1ebd1ead1ecd1ede3f3f7b1", "Yang2", "d1f3d1eed1efd1f4d1f0d1f1d1f2e1e0ecbeecc8f2d5", "Yang3", "d1f8d1f6d1f5d1f7", "Yang4", "d1f9eda6d1fae2f3ecc8f7b1", "Yao1", "d2aad4bcd1fbd1fcd1fdd8b2dfbae7db", "Yao2", "d2a4d2a6ccd5d2a1bdc4d1fed2a2d2a3d2a5d8b3e1e6e7f2e9f7ebc8efa2f4edf7a5", "Yao3", "d2a7d2a8e1cae8c3f1ba", "Yao4", "d2aad2abd2a9c5b1d4bfead7f0ce", "Ye1", "d2aed2acd2add2b4", "Ye2", "d2aed2afd0b0dedeeef4", "Ye3", "d2b2d2b0d2b1", "Ye4", "d2b5d2b9d2b6bba9d1cad2b3d2b4d2b7d2b8d2bad7a7d8ccdacbdafeeacaecc7", "Yi1", "d2bbd2bdd2c0d2c2d2c1d2bcd2bed2bfd2cedfdee0e6e2a2e4f4eca5f7f0", "Yi2", "d2cbd2c7d2c9d2c6d2c5c9dfd2c3d2c4d2c8d2cad2ccd2cddab1dbdddce8dfd7e1dae2c2e2f9e5c6eaddedf4f0ea", "Yi3", "d2d4d2d1d2c2d2d2ceb2b6ead2ced2cfd2d0d2d3dcd3e5c6ecbdeec6f4aff4fd", "Yi4", "d2e9d2e2d2d7d2dad2e6d2d5d2e0d2e5d2ebd2dbb0acd2c2d2ecd2ddd2e3d2d6d2edd2ead2dfd2e7d2d8d2d9d2dcd2ded2e1d2e4d2e8d8d7d8e6d8eed8fdd9abdbfcdcb2deb2dec4dec8dedadfaedfbde0c9e0e6e1bbe2f8e3a8e9ece9f3ecdaefd7efeef0f9f1aff1b4f2e6f4e8f4e0d2eee6e4e7cbd2ef", "Yin1", "d2f2d2f4d1ccd2f5d2f3d2f1d2f0d2f6dca7e0b3e4a6e4ceebb3eef7", "Yin2", "d2f8d2f7d2f9d2fadbb4dbdfdbf3e1fee2b9f6aff6b8", "Yin3", "d2fdf1abd2fbd2f3d2fcd2fedfc5f2be", "Yin4", "d3a1d2fbd2f1d8b7dce1f1bf", "Ying1", "d3a6d3a2d3a4d3a3d3a5d3a7ddbadefce0d3e2dfe7f8e8acf0d0f3bf", "Ying2", "d3aad3add3afd3aed3a8d3a9d3abd3acd9f8dce3dcfeddd3ddf6e4dee4ebe5ade9ba", "Ying3", "d3b0d3b1dbabf1a8f2a3", "Ying4", "d3a6d3b3d3b2ebf4", "Yo1", "d3fdd3b4e0a1", "Yo5", "d3b4", "Yong1", "d3b5d3b6d3b7d3b8d3b9d3badbd5dcade3bce7dfefdef7abf7d3", "Yong2", "e0af", "Yong3", "d3c0d3c2d3bfd3bbd3bed3bcd3bdd3c1d9b8f0ae", "Yong4", "d3c3d3b6", "You1", "d3c5d3c7d3c4d3c6d8fcdfcf", "You2", "d3c9d3ced3cdd3cad3c8d3cbd3ccddafddb5decce8d6e9e0f0e0f2c4f2f6f2f8f4edf6cf", "You3", "d3d0d3d1d3cfd8d5ddacebbbeef0f7ee", "You4", "d3d0d3d6d3d7d3d2d3d3d3d5d3d4d9a7e0f3e5b6e8d6f2caf7f8", "Yu1", "d3f5d3d8d3d9e6faecb6f0f6", "Yu2", "d3dad3ebd3e8d3e0d3e6d3e2d3e9d3e3d3e4d3def4a8d3dfd3dbd3dcd3ddd3e1d3e5d3e7d8aedac4ddc7deede1cee1fce2c5e6a5e8a4eaecebe9eca3f1bef2f5f3c4f4a7f6a7", "Yu3", "d3ebd3efd3e8d3ead3eed3ecd3edd3f0d8f1d9b6e0f4e0f6e2d7f0f5f1c1f6b9", "Yu4", "d3ebd3fdd3efd4a4d4a3d3f5d3f6d3f2d3ead3f1d3fed3fbb9c8d3fcdacdd3f9d3faceb5cebed3f3d3f4d3f7d3f8d4a1d4a2d4a5d4a6d6e0d8b9ddd2ddf7e2c0e3d0e5fdeac5eccfecd9ecdbedb2eedaf0c1f0d6f2e2e5f7", "Yuan1", "d4a7d4a8d4a9edf3f0b0f3ee", "Yuan2", "d4b1d4aad4add4b0d4b4d4b2d4aed4b5d4abd4acd4afd4b3dcabdcbee0f7e3e4e6c2e9daebbcf3a2f6bd", "Yuan3", "d4b6", "Yuan4", "d4bad4b8d4b9d4b7dbf9def2e6c2e8a5", "Yue1", "d4bcd4bb", "Yue4", "cbb5d4c2d4bdc0d6d4c4d4bed4bfd4c0d4c1d4c3d9dfe5aee8dde9d0ebbeeee1", "Yun1", "d4ceebb5", "Yun2", "d4b1d4c6d4c8d4c5d4c7dcbfe7a1eac0f3de", "Yun3", "d4cad4c9e1f1e9e6", "Yun4", "d4b1d4cbbef9d4cdd4ccd4ced4cfd4d0dba9e3a2e3b3e8b9ecd9", "Za1", "d4d1d4faded9dfc6", "Za2", "d4d3d4d2d4db", "Za3", "d5a6", "Zai1", "d4d4d4d6d4d5e7de", "Zai3", "d4d8d4d7d7d0e1cc", "Zai4", "d4dad4d9d4d8", "Zan1", "f4a2f4d8", "Zan2", "d4db", "Zan3", "d4dcded9eac3f4f5", "Zan4", "d4ded4dde8b6f6c9", "Zan5", "d4db", "Zang1", "d4dfd5e0eab0", "Zang3", "e6e0", "Zang4", "b2d8d4e0d4e1deca", "Zao1", "d4e2d4e3", "Zao2", "d4e4", "Zao3", "d4e7d4e5d4e6d4e8d4e9e7d8", "Zao4", "d4ecd4ead4ebd4edd4eed4efdff0", "Ze2", "d4f2d4f0d4f1d4f3d5a6d8d3dff5e0fde5c5f3d0f3e5f4b7", "Ze4", "b2e0d8c6eabe", "Zei2", "d4f4", "Zen3", "d4f5", "Zen4", "dada", "Zeng1", "d4f6d4f8d4f7e7d5eec0", "Zeng4", "d4f9d7dbe7d5eab5efad", "Zha1", "b2e9d4fcd4fad4fbd5a6deeadfb8dfeee9abf7fe", "Zha2", "d5a8d4fad4fdd4fed5a1d5a2e0a9", "Zha3", "d5a3edc4", "Zha4", "d5a8c0afd5a4d5a5d5a6d5a7d5a9d7f5dfb8dfe5f0e4f2c6", "Zhai1", "b2e0d5aad5ab", "Zhai2", "d5acd4f1b5d4", "Zhai3", "d5ad", "Zhai4", "d5aebcc0d5afedcef1a9", "Zhan1", "d5bcd5b4d5b0d5b1d5b2d5b3dadeecb9", "Zhan3", "d5b9d5b5d5b6d5b7d5b8def8", "Zhan4", "d5bcd5bed5bdb2fcd5bad5bbd5bfd5c0", "Zhang1", "d5c5d5c2d5c4d5c1d5c3dbb5e2afe6d1e8b0f3af", "Zhang3", "b3a4d5c7d5c6d8eb", "Zhang4", "d5cdd5c7d5cfd5c9d5ccd5cbd5c8d5cad5cee1a4e1d6", "Zhao1", "d7c5d5d0b3afd5d1b3b0dffaeec8", "Zhao2", "d7c5", "Zhao3", "d5d2d5d3d7a6", "Zhao4", "d5d5d5d9d5d7d5d4d5d6d5d8daafe8fef3c9", "Zhe1", "d5dbd5daf2d8", "Zhe2", "d5dcd5dbd5ddd5dedad8dfa1e9fcedddf2d8", "Zhe3", "d5dfd5e0f1def4f7", "Zhe4", "d5e2d5e1d5e3e8cff0d1", "Zhe5", "d7c5", "Zhei4", "d5e2", "Zhen1", "d5e6d5ebd5e4d5ecd5ead5e5d5e7d5e8d5e9dde8e4a5e4dae8e5e9a9e9bbebd3ecf5f3f0", "Zhen3", "d5efe7c7d5edd5eee9f4eeb3f0a1", "Zhen4", "d5f3d5f2d5f1d5f0dbdaeae2ebdef0b2", "Zheng1", "d5fdd5f9b6a1d5f7d6a2d5f5d5f4d5f6d5f8d5fae1bfe1e7eedbefa3f3ddf6eb", "Zheng3", "d5fbd5fc", "Zheng4", "d5fed5fdd6a4d6a3d6a2d5f5d5fad6a1dabaefa3", "Zhi1", "d6aed6bbd6b8d6a7d6aacacfd6afd6a5d6a6d6a8d6a9d6abd6acd6add6c0d8b4e8d9ebd5ecf3", "Zhi2", "d6b8d6b5d6b0d6b4d6b1d6b2d6b3d6b6dbfadefdf4eaf5c5f5dc", "Zhi3", "d6bbd6b8d6b9d6bdd6bcd6b7d6badcc6e1e7e5ebe8d7e9f2ecedede9f5a5", "Zhi4", "d6c1d6c6d6c2d6aad6ced6cacab6d6bed6c7d6c3d6c9d6c8d6bfd6c0d6c4d6c5d6cbd6ccd6cdd6cfdaecdba4e0f9e2e5e5e9e6efe8cee8e4e9f9eadeebf9eff4f0baf0ebf2cef5d9f5f4f6a3", "Zhong1", "d6d0d6d5d6d3d6d2d6d1d6d4e2eceff1f3aef4b1", "Zhong3", "d6d6d6d7daa3f5e0", "Zhong4", "d6d0d6d6d6d8d6dad6d9", "Zhou1", "d6ded6dcd6ddd6dbd6dfd6e0dffa", "Zhou2", "d6e1e6a8edd8", "Zhou3", "d6e2d6e3", "Zhou4", "d6e8d6e6d6e1d6e4d6e5d6e7dda7e6fbe7a7ebd0f4a6f4edf4fc", "Zhu1", "d6eed6e9d6ecd6ead6ebd6edd6efd9aadba5dcefe4a8e4f3e9c6e9cdeef9", "Zhu2", "caf5d6fed6f0d6f1d6f2f0f1f3c3f4b6f5ee", "Zhu3", "d6f7caf4d6f3d6f4d6f5d6f6e4bef1d2f7e6", "Zhu4", "d6fad7a2d7a1d6fed7a3d6f8d7a4d6f9d6fcd6fbd6fdd8f9dcd1e8ccecc4f0e6f3e7f4e3", "Zhua1", "ceced7a5", "Zhua3", "d7a6", "Zhuai1", "d7a7", "Zhuai3", "d7aa", "Zhuai4", "d2b7d7a7e0dc", "Zhuan1", "d7a8d7a9f2a7", "Zhuan3", "d7aa", "Zhuan4", "d7aab4abd7acd7abd7addff9e2cde3e7", "Zhuang1", "d7b0d7afd7aed7b1", "Zhuang3", "deca", "Zhuang4", "d7b4d7b2d7b3b4b1d9d7edb0", "Zhui1", "d7b7d7b5d7b6e6edf6bf", "Zhui4", "d7b9d7b8d7bae3b7e7c4", "Zhun1", "cdcdd7bbebc6f1b8", "Zhun3", "d7bc", "Zhuo1", "d7bfd7c0d7bdd7bed9bee4c3eccc", "Zhuo2", "d7c5d6f8bdc9dfaad7c3d7c1d7c2d7c4d7c6d7c7dac2e4b7e5aaecfaedbdefed", "Zi1", "d7cad7c9d7c8d7cbd6a8d7ccd7cdd7ced7d0dad1dfdae1d1e6dce7bbeaa2eadfefc5f4d2f4f4f5fef6a4f6b7f6f6f7da", "Zi3", "d7d3d7cfd7d0d7d1d7d2dcebe6a2e8f7eff6f1e8f3caf6a4", "Zi4", "d7d4d7d6d7d5eda7edf6", "Zong1", "d7dad7d9d7dbd7d7d7d8e8c8ebea", "Zong3", "d7dcd9cc", "Zong4", "d7ddf4d5", "Zou1", "d7dedac1daeedbb8e6e3f6ed", "Zou3", "d7df", "Zou4", "d7e0d7e1", "Zu1", "d7e2ddcf", "Zu2", "d7e3d7e5d7e4efdf", "Zu3", "d7e9d7e6d7e8d7e7d9de", "Zuan1", "d7eaf5f2", "Zuan3", "d7ebe7da", "Zuan4", "d7acd7eadfac", "Zui1", "b6d1", "Zui3", "bed7d7ecf5fe", "Zui4", "d7eed7efd7eddea9", "Zun1", "d7f0d7f1e9d7f7ae", "Zun3", "dfa4", "Zuo1", "d7f7e0dc", "Zuo2", "d7f7d7f2d7c1f3d0", "Zuo3", "d7f3d7f4b4e9", "Zuo4", "d7f7d7f6d7f9d7f8d4e4d7f5f5a1dff2ebd1e2f4ecf1dae8", NULL }; #endif /* ~_NO_TGTWB5 */ �����������������������������������������������������������������������������tgif-QPL-4.2.5/tgif.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000042355�11602233313�014073� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgif.c,v 1.17 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TGIF_C_ #include "tgifdefs.h" #include "color.e" #include "dialog.e" #include "exec.e" #include "file.e" #include "font.e" #include "grid.e" #include "mainloop.e" #include "msg.e" #include "names.e" #include "obj.e" #include "page.e" #include "raster.e" #include "setup.e" #include "strtbl.e" #include "tangram2.e" #include "util.e" #include "version.e" /* * extern int malloc_debug ARGS_DECL((int)); */ int lastFile=TRUE; short pDrawFontAsc[] = { 8, 10, 12, 14, 17, 22, 8, 10, 12, 14, 17, 22, 8, 10, 12, 14, 17, 23, 8, 10, 12, 14, 17, 22, 8, 9, 11, 13, 15, 19, 7, 9, 11, 12, 15, 20, 7, 9, 11, 13, 15, 19, 7, 9, 11, 12, 15, 20, 9, 11, 12, 14, 18, 24, 9, 11, 12, 14, 17, 24, 9, 11, 12, 14, 17, 24, 9, 11, 12, 14, 17, 24, 8, 11, 12, 14, 18, 23, 8, 11, 12, 15, 18, 24, 8, 11, 12, 14, 16, 23, 8, 11, 12, 14, 16, 24, 8, 10, 12, 14, 18, 24, 9, 14, 15, 18, 23, 30, 10, 14, 16, 17, 23, 30, 9, 13, 15, 17, 22, 30, 9, 13, 15, 18, 22, 30, 9, 12, 14, 15, 19, 26, 9, 12, 14, 15, 21, 26, 9, 12, 14, 15, 19, 26, 9, 12, 14, 15, 20, 26, 11, 14, 16, 18, 24, 31, 11, 14, 16, 18, 24, 31, 11, 14, 16, 18, 24, 31, 11, 14, 16, 18, 24, 31, 11, 14, 16, 19, 24, 32, 11, 15, 16, 19, 24, 33, 11, 14, 16, 18, 23, 32, 11, 15, 16, 19, 24, 32, 11, 12, 13, 14, 19, 27 }; short pDrawFontDes[] = { 2, 3, 3, 4, 4, 6, 2, 3, 3, 4, 4, 6, 2, 3, 3, 4, 5, 6, 2, 3, 3, 3, 4, 6, 2, 2, 3, 3, 4, 5, 2, 2, 3, 4, 5, 5, 2, 2, 3, 3, 4, 5, 2, 2, 3, 4, 5, 5, 2, 2, 3, 3, 4, 5, 2, 2, 3, 3, 5, 5, 2, 2, 3, 3, 5, 5, 2, 2, 3, 3, 5, 5, 2, 2, 3, 3, 4, 5, 2, 2, 3, 3, 4, 5, 2, 2, 3, 3, 6, 5, 2, 2, 3, 3, 6, 5, 3, 4, 4, 6, 7, 8, 3, 3, 4, 4, 6, 7, 3, 3, 4, 4, 6, 7, 3, 4, 4, 5, 6, 7, 3, 3, 4, 4, 6, 7, 2, 3, 3, 4, 5, 6, 2, 4, 3, 5, 5, 7, 2, 3, 4, 4, 5, 6, 2, 4, 4, 5, 5, 7, 2, 3, 4, 4, 5, 7, 2, 3, 4, 5, 5, 7, 2, 3, 4, 5, 5, 7, 2, 3, 4, 5, 5, 7, 2, 3, 3, 4, 5, 7, 2, 3, 3, 4, 5, 7, 2, 3, 3, 4, 5, 7, 2, 3, 3, 4, 5, 7, 4, 3, 4, 5, 5, 7 }; static void SetProgramName(FileName) char *FileName; { char *c_ptr=UtilStrRChr(FileName, DIR_SEP); if (c_ptr != NULL && *(++c_ptr) != '\0') { UtilStrCpyN(progName, sizeof(progName), c_ptr); } else { UtilStrCpyN(progName, sizeof(progName), TOOL_NAME); UtilStrLower(progName); } } static int PrTgifLoad(FileName) char *FileName; { struct ObjRec *obj_ptr=NULL; char full_name[MAXPATHLENGTH+1], gzipped_fname[MAXPATHLENGTH+1]; char tmp_filename[MAXPATHLENGTH+1], tmp_filefullpath[MAXPATHLENGTH+1]; int read_status, obj_file=TRUE; FILE *fp=NULL; int tmp_linenum=0, gzipped=FALSE; if (strcmp(FileName, "-") == 0) { return TRUE; } *gzipped_fname = '\0'; if (FileNameHasExtension(FileName, OBJ_FILE_TYPE, &gzipped, NULL)) { if (gzipped) { if (cmdLineOpenDisplay) { char *tmp_fname=NULL; if ((tmp_fname=GunzipFileIntoTemp(FileName)) == NULL) { return FALSE; } else { strcpy(gzipped_fname, FileName); strcpy(full_name, tmp_fname); free(tmp_fname); } } else { fprintf(stderr, TgLoadString(STID_TOOL_DONT_KNOW_HOW_RUN_GUNZIP), TOOL_NAME); fprintf(stderr, "\n"); fprintf(stderr, "%s\n", TgLoadString(STID_SPECIFY_DISPLAY_ON_CMD_LINE)); return FALSE; } } else { strcpy(full_name, FileName); } } else if (FileNameHasExtension(FileName, SYM_FILE_TYPE, NULL, NULL)) { strcpy(full_name, FileName); obj_file = FALSE; } else if (FileNameHasExtension(FileName, PIN_FILE_TYPE, NULL, NULL)) { strcpy(full_name, FileName); obj_file = FALSE; } else { sprintf(full_name, "%s.%s", FileName, OBJ_FILE_EXT); } if ((fp=fopen(full_name, "r")) == NULL) { fprintf(stderr, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), full_name); fprintf(stderr, "\n"); if (*gzipped_fname != '\0') unlink(full_name); return FALSE; } strcpy(tmp_filefullpath, scanFileFullPath); strcpy(tmp_filename, scanFileName); tmp_linenum = scanLineNum; UtilStrCpyN(scanFileFullPath, sizeof(scanFileFullPath), full_name); strcpy(scanFileName, full_name); scanLineNum = 0; if (!(PRTGIF && cmdLineStdOut)) { if (!cmdLineQuiet) { fprintf(stderr, TgLoadCachedString(CSTID_READING_FILE_DOTS), full_name); fprintf(stderr, "\n"); } } readingPageNum = loadedCurPageNum = 0; foundGoodStateObject = FALSE; while ((read_status=ReadObj(fp, &obj_ptr)) == TRUE) { if (obj_ptr != NULL) { AdjForOldVersion(obj_ptr); AddObj(NULL, topObj, obj_ptr); } } strcpy(scanFileFullPath, tmp_filefullpath); strcpy(scanFileName, tmp_filename); scanLineNum = tmp_linenum; fclose(fp); if (read_status == INVALID) { fprintf(stderr, TgLoadString(STID_FILE_VER_ABORT_TOOL), fileVersion, TOOL_NAME, TOOL_NAME, homePageURL); if (*gzipped_fname != '\0') unlink(full_name); return FALSE; } if (*gzipped_fname != '\0') { unlink(full_name); strcpy(full_name, gzipped_fname); } if (cmdLineOpenDisplay || *cmdLineGenParser != '\0') { char file_path[MAXPATHLENGTH+1]; if (*full_name == DIR_SEP) { strcpy(file_path, full_name); } else { sprintf(file_path, "%s%c%s", curDir, DIR_SEP, full_name); } curFileDefined = TRUE; if (obj_file) { SetCurDir(file_path); *curSymDir = '\0'; } else { SetCurSymDir(file_path); } } if (cmdLineHasPageNum) { if (cmdLinePageNum > lastPageNum) { if (lastPageNum == 1) { fprintf(stderr, TgLoadString(STID_FILE_SKIP_CONTAINS_ONE_PAGE), FileName); } else { fprintf(stderr, TgLoadString(STID_FILE_SKIP_CONTAINS_NUM_PAGE), FileName, lastPageNum); } fprintf(stderr, "\n"); return FALSE; } GotoPageNum(cmdLinePageNum); } if (cmdLineColor && colorMenuItems == NULL) { fprintf(stderr, TgLoadString(STID_FILE_NOT_CONTAIN_COLOR_ABORT), TOOL_NAME); fprintf(stderr, "\n"); return FALSE; } if (loadedCurPageNum > 0 && curPage != NULL && lastPageNum > 1) { /* * Well, it should go to loadedCurPageNum because it was the page * at which the file was saved. But we go to lastPageNum to stay * compatible with Tangram-II since it was expected for tgif to * behave this way. */ GotoPageNum(lastPageNum); } return TRUE; } static void PrTgifDump(inbuf, tile_page_err_msg_id) char *inbuf; int tile_page_err_msg_id; { if (inbuf != NULL && strcmp(inbuf, "-") != 0) { UtilStrCpyN(cmdLineOpenFile, sizeof(cmdLineOpenFile), inbuf); } if (cmdLineNoShowPageInEPS) showPageInEPS = FALSE; if (*cmdLineFileToExec != '\0') { if (!cmdLineQuiet) { fprintf(stderr, TgLoadString(STID_EXECUTING_GIVEN_SCRIPT), cmdLineFileToExec); fprintf(stderr, "\n"); } StartExecCmdsFromFile(); } else { colorDump = cmdLineColor; if (cmdLineOpenDisplay) { whereToPrint = cmdLineWhereToPrint; } if (cmdLineOneFilePerPage) { if (pageLayoutMode == PAGE_TILE) { fprintf(stderr, "%s\n", TgLoadString(tile_page_err_msg_id)); } else { if (cmdLineHasPageNum) { sprintf(cmdLinePageNumStr, "%1d", cmdLinePageNum); GotoPageNum(cmdLinePageNum); if (inbuf != NULL) Dump(inbuf); } else { cmdLineHasPageNum = TRUE; for (cmdLinePageNum=1; cmdLinePageNum <= lastPageNum; cmdLinePageNum++) { sprintf(cmdLinePageNumStr, "%1d", cmdLinePageNum); GotoPageNum(cmdLinePageNum); if (inbuf != NULL) Dump(inbuf); } cmdLineHasPageNum = FALSE; } } } else { if (inbuf != NULL) Dump(inbuf); } } *cmdLineOpenFile = '\0'; DelAllObj(); if (cmdLineColor) CleanUpColors(); if (cmdLineOpenDisplay) { CleanUp(); } } static void DoPrTgif(argc, argv, from_prtgif) int argc, from_prtgif; char *argv[]; { char inbuf[MAXSTRING+1]; int len, argc_to_be; *scanFileFullPath = *scanFileName = '\0'; scanLineNum = 0; if ((argc_to_be=ProcessPrTgifOptions(argc, argv, from_prtgif)) == INVALID) { return; } while (argc > argc_to_be) { argc--; argv++; } InitPaperSize(); InitTmpDir(); InitPatFill(); if (PRTGIF && !cmdLineOpenDisplay) { InitDontReencode(NULL); InitPSFontCharSubs(); } if (*cmdLineGenParser != '\0') { if (cmdLineTgrm2) { InitNames(); } } if (argc <= 0) { if (cmdLineStdOut) { fprintf(stderr, "\n%s\n", TgLoadString(STID_SPEC_FILE_WHEN_STDOUT_USED)); return; } else if (strcmp(cmdLineFileToExec, "-") == 0) { if (cmdLineOpenDisplay) { JustInit(NULL, NULL); Init2PatFill(); } PrTgifDump(NULL, STID_CANT_ONEFPPAGE_IN_TILED_PAGE); } else { sprintf(gszMsgBox, TgLoadString(STID_TOOL_FILE_NAME_TO_PRINT), TOOL_NAME); fprintf(stderr, "\n%s> ", gszMsgBox); fflush(stderr); while (fgets(inbuf, MAXSTRING, stdin) != NULL) { len = strlen(inbuf); if (len > 0) { if (inbuf[--len] == '\n') inbuf[len] = '\0'; if (*cmdLineGenParser != '\0') { if (cmdLineTgrm2) { if (PrTgifLoad(inbuf)) { Tangram2GenerateChain(cmdLineGenParser); DelAllObj(); } else { fprintf(stderr, "\n"); } } } else if (cmdLineDumpURL) { UrlDump(inbuf); } else if (cmdLineDosEpsFilter) { UtilStrCpyN(cmdLineOpenFile, sizeof(cmdLineOpenFile), inbuf); DosEpsFilter(inbuf); } else { if (cmdLineOpenDisplay) { JustInit(NULL, NULL); } if (PrTgifLoad(inbuf)) { PrTgifDump(inbuf, STID_CANT_ONEFPPAGE_IN_TILED_PAGE); } else { fprintf(stderr, "\n"); } } } sprintf(gszMsgBox, TgLoadString(STID_TOOL_FILE_NAME_TO_PRINT), TOOL_NAME); fprintf(stderr, "\n%s> ", gszMsgBox); fflush(stderr); } fprintf(stderr, "\n"); fflush(stderr); } } else { if (cmdLineStdOut && argc > 2) { fprintf(stderr, "\n%s\n", TgLoadString(STID_ONE_FILE_ONLY_WITH_STDOUT)); return; } for ( ; argc > 0; argc--, argv++) { lastFile = (argc == 1); if (*cmdLineGenParser != '\0') { if (cmdLineTgrm2) { if (PrTgifLoad(*argv)) { Tangram2GenerateChain(cmdLineGenParser); DelAllObj(); } else { fprintf(stderr, "\n"); } } } else if (cmdLineDumpURL) { UrlDump(*argv); if (argc > 1) { fprintf(stderr, "%s\n", TgLoadString(STID_ONE_FILE_ONLY_RAW_PLUS_H)); } break; } else if (cmdLineDosEpsFilter) { UtilStrCpyN(cmdLineOpenFile, sizeof(cmdLineOpenFile), *argv); DosEpsFilter(*argv); if (argc > 1) { fprintf(stderr, "%s\n", TgLoadString(STID_ONE_FILE_ONLY_DOSEPSFILTER)); } break; } else { if (cmdLineOpenDisplay) { JustInit(NULL, NULL); } if (PrTgifLoad(*argv)) { PrTgifDump(*argv, STID_CANT_PRTGIF_OFPP_TILED_PAGE); } else { fprintf(stderr, "\n"); } } } } if (PRTGIF && !cmdLineOpenDisplay) CleanUpFonts(); CleanUpPage(); CleanUpResiduals(); CleanUpPatFill(); CleanUpStrTable(); } /* * static * void Prompt2 (PromptStr, OpName, FileName) * char * PromptStr, * OpName, * FileName; * { * char inbuf[80]; * * printf (PromptStr); * fgets (inbuf, 80, stdin); * sscanf (inbuf, "%s%s", OpName, FileName); * } * * static * void Prompt3 (PromptStr, AttrName, ColorName, ValName) * char * PromptStr, * AttrName, * ColorName, * ValName; * { * char inbuf[80]; * * printf (PromptStr); * fgets (inbuf, 80, stdin); * sscanf (inbuf, "%s%s%s", AttrName, ColorName, ValName); * } */ static void DoTgif(argc, argv) int argc; char *argv[]; /* All these strangeness with strings are related to */ /* Prolog's foreign function interface. */ { /* * register int i; */ char op_name[80], file_name[(MAXPATHLENGTH<<1)+1]; char *sp[6], *func_strp; /* * char color_name[80], val_name[80]; * char attr_name[80], speed_name[80], id_name[80]; */ if (!ProcessTgifOptions(argc, argv, file_name, sizeof(file_name))) return; if (file_name[0] == '\0') { /* do not translate -- program constants */ MainLoop("init", "", &func_strp, &sp[0], &sp[1], &sp[2], &sp[3], &sp[4], &sp[5]); } else { /* do not translate -- program constants */ MainLoop("init", file_name, &func_strp, &sp[0], &sp[1], &sp[2], &sp[3], &sp[4], &sp[5]); } /* * for (i = 0; i < 6; i++) * if (strcmp (sp[i], "") != 0) * printf ("%s ", sp[i]); * else * break; * printf ("\n"); */ while (TRUE) { char s[80]; strcpy(s, func_strp); s[4] = '\0'; DeallocStrings(&func_strp,&sp[0],&sp[1],&sp[2],&sp[3],&sp[4],&sp[5]); /* do not translate -- program constants */ if (strcmp(s, "Quit") == 0) { *file_name = '\0'; MainLoop("quit", file_name, &func_strp, &sp[0], &sp[1], &sp[2], &sp[3], &sp[4], &sp[5]); DeallocStrings(&func_strp,&sp[0],&sp[1],&sp[2],&sp[3],&sp[4],&sp[5]); break; } Msg(TgLoadCachedString(CSTID_RETURNED_FROM_BASIC_DRIVER)); /* * Prompt2("Input an operation and a sub command.\n",op_name,file_name); * * if (strcmp(op_name, "animate") == 0) * { * Prompt3("Input poly_id, speed, color.\n", id_name, speed_name, * color_name); * Animate(file_name, id_name, speed_name, color_name, &func_strp); * printf("Animate RETURNs --> %s %s %s\n", func_strp, sp[0], sp[1]); * } * if (strcmp(op_name, "upd_attr_val") == 0) * { * Prompt3("Input attrname, color and value.\n", attr_name, color_name, * val_name); * UpdAttrVal(file_name, attr_name, color_name, val_name, &func_strp); * printf("UpdAttrVal RETURNs --> %s %s %s\n", func_strp, sp[0], sp[1]); * } */ *op_name = *file_name = '\0'; MainLoop(op_name, file_name, &func_strp, &sp[0], &sp[1], &sp[2], &sp[3], &sp[4], &sp[5]); /* * printf("RETURN --> %s ", func_strp); * for (i = 0; i < 6; i++) * if (strcmp(sp[i], "") != 0) * printf("%s ", sp[i]); * else * break; * printf("\n"); */ } } int main(argc, argv) int argc; char *argv[]; { register int i, from_prtgif; origArgC = argc; origArgV = argv; PRTGIF = FALSE; from_prtgif = FALSE; SetProgramName(*argv); for (i = 1; i < argc; i++) { /* do not translate -- program constants */ if (strcmp(argv[i], "-prtgif")==0) { PRTGIF = TRUE; from_prtgif = TRUE; break; } else if ((strcmp(argv[i], "-print")==0) || (strcmp(argv[i], "-PRINT")==0)) { PRTGIF = TRUE; break; } } /* * malloc_debug (1); */ if (PRTGIF) { DoPrTgif(argc, argv, from_prtgif); } else { DoTgif(argc, argv); } return 0; } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/mark.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000104160�11602233312�014064� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/mark.c,v 1.25 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_MARK_C_ #include "tgifdefs.h" #include "cmdids.h" #include "choice.e" #include "cmd.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "exec.e" #include "file.e" #include "mark.e" #include "msg.e" #include "obj.e" #include "oval.e" #include "pattern.e" #include "page.e" #include "poly.e" #include "polygon.e" #include "raster.e" #include "rect.e" #include "setup.e" #include "select.e" #include "spline.e" #include "stretch.e" #include "strtbl.e" #include "util.e" int somethingHighLighted=FALSE; static int tickMarkSize=8; /* --------------------- Init & Clean Up --------------------- */ void CleanUpMark() { } int InitMark() { if (!(PRTGIF && !cmdLineOpenDisplay)) { char *c_ptr=NULL; tickMarkSize = 8; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"TickMarkSize")) != NULL) { SetTickMarkSizeValue(c_ptr); } autoRotatePivot = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"AutoRotatePivot")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { autoRotatePivot = TRUE; choicePixmap[ROTATEMODE] = rotateModePixmap[!autoRotatePivot]; } } return TRUE; } /* --------------------- HighLight Functions --------------------- */ static void MarkStructuredSpline(obj_ptr, ssn, ssvs, ssmooth, curved, locked) struct ObjRec *obj_ptr; int ssn, curved, locked; char *ssmooth; IntPoint *ssvs; { int i=0; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(curved==LT_STRUCT_SPLINE, "curved != LT_STRUCT_SPLINE in MarkStructuredSpline()", NULL); #endif /* _TGIF_DBG */ if (obj_ptr->ctm == NULL) { if (ssmooth != NULL) { for (i = 0; i < ssn; i++) { if (ssmooth[i]) { MARKHO(drawWindow, locked ? revGrayGC : revDefaultGC, OFFSET_X(ssvs[i].x), OFFSET_Y(ssvs[i].y)); } else { MARKHR(drawWindow, locked ? revGrayGC : revDefaultGC, OFFSET_X(ssvs[i].x), OFFSET_Y(ssvs[i].y)); } } } else { for (i = 0; i < ssn; i++) { MARKHR(drawWindow, locked ? revGrayGC : revDefaultGC, OFFSET_X(ssvs[i].x), OFFSET_Y(ssvs[i].y)); } } } else { for (i=0; i < ssn; i++) { int x, y; TransformPointThroughCTM(ssvs[i].x-obj_ptr->x, ssvs[i].y-obj_ptr->y, obj_ptr->ctm, &x, &y); if (ssmooth != NULL && ssmooth[i]) { MARKHO(drawWindow, locked ? revGrayGC : revDefaultGC, OFFSET_X(x+obj_ptr->x), OFFSET_Y(y+obj_ptr->y)); } else { MARKHR(drawWindow, locked ? revGrayGC : revDefaultGC, OFFSET_X(x+obj_ptr->x), OFFSET_Y(y+obj_ptr->y)); } } } } static void MarkPoly(ObjPtr, NumPts, V, Smooth, Curved, Locked) struct ObjRec *ObjPtr; int NumPts, Curved, Locked; char *Smooth; IntPoint *V; { register int i; if (ObjPtr->ctm == NULL) { if (Curved != LT_INTSPLINE && Smooth != NULL) { for (i = 0; i < NumPts; i++) { if (Smooth[i]) { if (Curved == LT_STRUCT_SPLINE) { MARKHO(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(V[i].x), OFFSET_Y(V[i].y)); } else { MARKO(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(V[i].x), OFFSET_Y(V[i].y)); } } else { if (Curved == LT_STRUCT_SPLINE) { MARKHR(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(V[i].x), OFFSET_Y(V[i].y)); } else { MARK(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(V[i].x), OFFSET_Y(V[i].y)); } } } } else { for (i = 0; i < NumPts; i++) { MARK(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(V[i].x), OFFSET_Y(V[i].y)); } } } else { for (i=0; i < NumPts; i++) { int x, y; TransformPointThroughCTM(V[i].x-ObjPtr->x, V[i].y-ObjPtr->y, ObjPtr->ctm, &x, &y); if (Curved != LT_INTSPLINE && Smooth != NULL && Smooth[i]) { if (Curved == LT_STRUCT_SPLINE) { MARKHO(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(x+ObjPtr->x), OFFSET_Y(y+ObjPtr->y)); } else { MARKO(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(x+ObjPtr->x), OFFSET_Y(y+ObjPtr->y)); } } else { if (Curved == LT_STRUCT_SPLINE) { MARKHR(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(x+ObjPtr->x), OFFSET_Y(y+ObjPtr->y)); } else { MARK(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(x+ObjPtr->x), OFFSET_Y(y+ObjPtr->y)); } } } } } static void Mark4Corners(BBox, Locked, Thin) struct BBRec BBox; int Locked, Thin; { if (Locked) { MARK(drawWindow, revGrayGC, OFFSET_X(BBox.ltx), OFFSET_Y(BBox.lty)); if (!Thin) { MARK(drawWindow, revGrayGC, OFFSET_X(BBox.ltx), OFFSET_Y(BBox.rby)); MARK(drawWindow, revGrayGC, OFFSET_X(BBox.rbx), OFFSET_Y(BBox.lty)); } MARK(drawWindow, revGrayGC, OFFSET_X(BBox.rbx), OFFSET_Y(BBox.rby)); } else { MARK(drawWindow, revDefaultGC, OFFSET_X(BBox.ltx), OFFSET_Y(BBox.lty)); if (!Thin) { MARK(drawWindow, revDefaultGC, OFFSET_X(BBox.ltx), OFFSET_Y(BBox.rby)); MARK(drawWindow, revDefaultGC, OFFSET_X(BBox.rbx), OFFSET_Y(BBox.lty)); } MARK(drawWindow, revDefaultGC, OFFSET_X(BBox.rbx), OFFSET_Y(BBox.rby)); } } static void Mark8Places(BBox, Locked) struct BBRec BBox; int Locked; { register int xmid=0, ymid=0; if (ZOOMED_SIZE(BBox.rbx - BBox.ltx) == 0) { if (ZOOMED_SIZE(BBox.rby - BBox.lty) == 0) { MARK(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(BBox.ltx), OFFSET_Y(BBox.lty)); } else { if (ZOOMED_SIZE(BBox.rby - BBox.lty) >= 10) { ymid = ((BBox.lty+BBox.rby) >> 1); MARK(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(BBox.ltx), OFFSET_Y(ymid)); } Mark4Corners(BBox, Locked, TRUE); } } else if (ZOOMED_SIZE(BBox.rby - BBox.lty) == 0) { if (ZOOMED_SIZE(BBox.rbx - BBox.ltx) >= 10) { xmid = (BBox.ltx+BBox.rbx) / 2; MARK(drawWindow, Locked ? revGrayGC : revDefaultGC, OFFSET_X(xmid), OFFSET_Y(BBox.lty)); } Mark4Corners(BBox, Locked, TRUE); } else { if (ZOOMED_SIZE(BBox.rbx - BBox.ltx) >= 10) { xmid = (BBox.ltx+BBox.rbx) / 2; if (Locked) { MARK(drawWindow, revGrayGC, OFFSET_X(xmid), OFFSET_Y(BBox.lty)); MARK(drawWindow, revGrayGC, OFFSET_X(xmid), OFFSET_Y(BBox.rby)); } else { MARK(drawWindow, revDefaultGC, OFFSET_X(xmid), OFFSET_Y(BBox.lty)); MARK(drawWindow, revDefaultGC, OFFSET_X(xmid), OFFSET_Y(BBox.rby)); } } if (ZOOMED_SIZE(BBox.rby - BBox.lty) >= 10) { ymid = ((BBox.lty+BBox.rby) >> 1); if (Locked) { MARK(drawWindow, revGrayGC, OFFSET_X(BBox.ltx), OFFSET_Y(ymid)); MARK(drawWindow, revGrayGC, OFFSET_X(BBox.rbx), OFFSET_Y(ymid)); } else { MARK(drawWindow, revDefaultGC, OFFSET_X(BBox.ltx), OFFSET_Y(ymid)); MARK(drawWindow, revDefaultGC, OFFSET_X(BBox.rbx), OFFSET_Y(ymid)); } } Mark4Corners(BBox, Locked, FALSE); } } void HighLightAnObj(ObjPtr) register struct ObjRec *ObjPtr; { if (execCurDepth > 0) return; switch (ObjPtr->type) { case OBJ_POLY: if (ObjPtr->detail.p->curved == LT_STRUCT_SPLINE) { MarkStructuredSpline(ObjPtr, ObjPtr->detail.p->ssn, ObjPtr->detail.p->ssvlist, ObjPtr->detail.p->ssmooth, ObjPtr->detail.p->curved, ObjPtr->locked); } else { MarkPoly(ObjPtr, ObjPtr->detail.p->n, ObjPtr->detail.p->vlist, ObjPtr->detail.p->smooth, ObjPtr->detail.p->curved, ObjPtr->locked); } break; case OBJ_POLYGON: if (ObjPtr->detail.g->curved == LT_STRUCT_SPLINE) { MarkStructuredSpline(ObjPtr, ObjPtr->detail.g->ssn-1, ObjPtr->detail.g->ssvlist, ObjPtr->detail.g->ssmooth, ObjPtr->detail.g->curved, ObjPtr->locked); } else { MarkPoly(ObjPtr, ObjPtr->detail.g->n-1, ObjPtr->detail.g->vlist, ObjPtr->detail.g->smooth, ObjPtr->detail.g->curved, ObjPtr->locked); } break; case OBJ_BOX: case OBJ_OVAL: case OBJ_TEXT: case OBJ_ARC: case OBJ_RCBOX: case OBJ_GROUP: case OBJ_XBM: case OBJ_XPM: case OBJ_SYM: case OBJ_ICON: case OBJ_PIN: Mark8Places(ObjPtr->obbox, ObjPtr->locked); break; } } static void HighLightVertices(Dir) int Dir; { register struct VSelRec *vsel_ptr=NULL; register struct ObjRec *obj_ptr; register int i; struct SelRec *sel_ptr=NULL; if (mainDisplay == NULL || execCurDepth > 0) return; switch (Dir) { case FORWARD: vsel_ptr=botVSel; sel_ptr=botSel; break; case REVERSE: vsel_ptr=topVSel; sel_ptr=topSel; break; } while (sel_ptr != NULL) { obj_ptr = sel_ptr->obj; switch (obj_ptr->type) { case OBJ_POLY: if (obj_ptr->detail.p->curved == LT_STRUCT_SPLINE) { MarkStructuredSpline(obj_ptr, obj_ptr->detail.p->ssn, obj_ptr->detail.p->ssvlist, obj_ptr->detail.p->ssmooth, obj_ptr->detail.p->curved, obj_ptr->locked); } else { MarkPoly(obj_ptr, obj_ptr->detail.p->n, obj_ptr->detail.p->vlist, obj_ptr->detail.p->smooth, obj_ptr->detail.p->curved, obj_ptr->locked); } break; case OBJ_POLYGON: if (obj_ptr->detail.g->curved == LT_STRUCT_SPLINE) { MarkStructuredSpline(obj_ptr, obj_ptr->detail.g->ssn-1, obj_ptr->detail.g->ssvlist, obj_ptr->detail.g->ssmooth, obj_ptr->detail.g->curved, obj_ptr->locked); } else { MarkPoly(obj_ptr, obj_ptr->detail.g->n-1, obj_ptr->detail.g->vlist, obj_ptr->detail.g->smooth, obj_ptr->detail.g->curved, obj_ptr->locked); } break; } switch (Dir) { case FORWARD: sel_ptr = sel_ptr->prev; break; case REVERSE: sel_ptr = sel_ptr->next; break; } } while (vsel_ptr != NULL) { char *smooth=NULL; int curved=(-1); switch (vsel_ptr->obj->type) { case OBJ_POLY: curved = vsel_ptr->obj->detail.p->curved; if (curved == LT_STRUCT_SPLINE) { smooth = vsel_ptr->obj->detail.p->ssmooth; } else { smooth = vsel_ptr->obj->detail.p->smooth; } break; case OBJ_POLYGON: curved = vsel_ptr->obj->detail.g->curved; if (curved == LT_STRUCT_SPLINE) { smooth = vsel_ptr->obj->detail.g->ssmooth; } else { smooth = vsel_ptr->obj->detail.g->smooth; } break; } for (i = 0; i < vsel_ptr->n; i++) { if (!(vsel_ptr->obj->type==OBJ_POLYGON && vsel_ptr->obj->detail.g->n-1==vsel_ptr->v_index[i])) { if (curved != LT_INTSPLINE && curved != (-1) && smooth != NULL) { if (smooth[vsel_ptr->v_index[i]]) { if (curved == LT_STRUCT_SPLINE) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(vsel_ptr->x[i]), OFFSET_Y(vsel_ptr->y[i])); } else { MARKO(drawWindow, revDefaultGC, OFFSET_X(vsel_ptr->x[i]), OFFSET_Y(vsel_ptr->y[i])); } } else { if (curved == LT_STRUCT_SPLINE) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(vsel_ptr->x[i]), OFFSET_Y(vsel_ptr->y[i])); } else { MARK(drawWindow, revDefaultGC, OFFSET_X(vsel_ptr->x[i]), OFFSET_Y(vsel_ptr->y[i])); } } } else { MARK(drawWindow, revDefaultGC, OFFSET_X(vsel_ptr->x[i]), OFFSET_Y(vsel_ptr->y[i])); } MARKV(drawWindow, revDefaultGC, OFFSET_X(vsel_ptr->x[i]), OFFSET_Y(vsel_ptr->y[i])); } } switch (Dir) { case FORWARD: vsel_ptr = vsel_ptr->prev; break; case REVERSE: vsel_ptr = vsel_ptr->next; break; } } } static void HighLight(Dir) int Dir; { register struct SelRec *sel_ptr=NULL; register struct ObjRec *obj_ptr; if (mainDisplay == NULL || execCurDepth > 0) return; switch (Dir) { case FORWARD: sel_ptr = botSel; break; case REVERSE: sel_ptr = topSel; break; } while (sel_ptr != NULL) { obj_ptr = sel_ptr->obj; switch (obj_ptr->type) { case OBJ_POLY: if (obj_ptr->detail.p->curved == LT_STRUCT_SPLINE) { MarkStructuredSpline(obj_ptr, obj_ptr->detail.p->ssn, obj_ptr->detail.p->ssvlist, obj_ptr->detail.p->ssmooth, obj_ptr->detail.p->curved, obj_ptr->locked); } else { MarkPoly(obj_ptr, obj_ptr->detail.p->n, obj_ptr->detail.p->vlist, obj_ptr->detail.p->smooth, obj_ptr->detail.p->curved, obj_ptr->locked); } break; case OBJ_POLYGON: if (obj_ptr->detail.g->curved == LT_STRUCT_SPLINE) { MarkStructuredSpline(obj_ptr, obj_ptr->detail.g->ssn-1, obj_ptr->detail.g->ssvlist, obj_ptr->detail.g->ssmooth, obj_ptr->detail.g->curved, obj_ptr->locked); } else { MarkPoly(obj_ptr, obj_ptr->detail.g->n-1, obj_ptr->detail.g->vlist, obj_ptr->detail.g->smooth, obj_ptr->detail.g->curved, obj_ptr->locked); } break; case OBJ_BOX: case OBJ_OVAL: case OBJ_TEXT: case OBJ_GROUP: case OBJ_ARC: case OBJ_RCBOX: case OBJ_XBM: case OBJ_XPM: case OBJ_SYM: case OBJ_ICON: case OBJ_PIN: Mark8Places(obj_ptr->obbox, obj_ptr->locked); break; } switch (Dir) { case FORWARD: sel_ptr = sel_ptr->prev; break; case REVERSE: sel_ptr = sel_ptr->next; break; } } } void HighLightForward() { if (curChoice == VERTEXMODE) { HighLightVertices(FORWARD); } else { HighLight(FORWARD); if (!autoRotatePivot && curChoice == ROTATEMODE) { HighLightRotatePivot(FORWARD); } } somethingHighLighted = TRUE; } void HighLightReverse() { if (curChoice == VERTEXMODE) { HighLightVertices(REVERSE); } else { if (!autoRotatePivot && curChoice == ROTATEMODE) { HighLightRotatePivot(REVERSE); } HighLight(REVERSE); } somethingHighLighted = FALSE; } /* --------------------- AddTickMarks() --------------------- */ struct tagAddTickMarksInfo { int n; IntPoint *vs; char *smooth; } gATMI; static int CreatePolygonTickMarks(num_pts) int num_pts; { gATMI.vs = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (gATMI.vs == NULL) return FailAllocMessage(); memset(gATMI.vs, 0, (num_pts+1)*sizeof(IntPoint)); gATMI.smooth = (char*)malloc(num_pts*sizeof(char)); if (gATMI.smooth == NULL) { free(gATMI.vs); gATMI.vs = NULL; return FailAllocMessage(); } memset(gATMI.smooth, 0, num_pts*sizeof(char)); gATMI.n = num_pts; return TRUE; } static int StartCreateTickMarks(nCmdId) int nCmdId; { switch (nCmdId) { case CMDID_ADDSQUARETICKMARKS: return CreatePolygonTickMarks(5); case CMDID_ADDTRIANGLETICKMARKS: return CreatePolygonTickMarks(4); case CMDID_ADDCIRCLETICKMARKS: return TRUE; case CMDID_ADDXTICKMARKS: return CreatePolygonTickMarks(9); case CMDID_ADDDIAMONDTICKMARKS: return CreatePolygonTickMarks(5); case CMDID_ADDBOWTIETICKMARKS: return CreatePolygonTickMarks(5); case CMDID_ADDINVTRIANGLETICKMARKS: return CreatePolygonTickMarks(4); case CMDID_ADDPLUSTICKMARKS: return CreatePolygonTickMarks(9); case CMDID_ADDHOURGLASSTICKMARKS: return CreatePolygonTickMarks(5); default: break; } return FALSE; } static void EndCreateTickMarks() { if (gATMI.vs != NULL) free(gATMI.vs); if (gATMI.smooth != NULL) free(gATMI.smooth); gATMI.vs = NULL; gATMI.smooth = NULL; gATMI.n = 0; } static void CreatePolygonalTickMark() { int i=0, saved_cur_spline=curSpline; curSpline = LT_STRAIGHT; ResetCreatePolygon(); for (i=0; i < gATMI.n; i++) { AddPtToCreatePolygon(gATMI.vs[i].x, gATMI.vs[i].y); } CreatePolygonObj(gATMI.n, TRUE); curSpline = saved_cur_spline; } static void CalcSquareVs(v) IntPoint v; { int half_w=(tickMarkSize>>1); gATMI.vs[0].x = v.x-half_w; gATMI.vs[0].y = v.y-half_w; gATMI.vs[1].x = v.x+half_w; gATMI.vs[1].y = v.y-half_w; gATMI.vs[2].x = v.x+half_w; gATMI.vs[2].y = v.y+half_w; gATMI.vs[3].x = v.x-half_w; gATMI.vs[3].y = v.y+half_w; gATMI.vs[4].x = v.x-half_w; gATMI.vs[4].y = v.y-half_w; CreatePolygonalTickMark(); } static void CalcTriangleVs(v) IntPoint v; { int i=0, half_w=(tickMarkSize>>1); double d_offset=((double)tickMarkSize)*((double)3)/((double)16); int offset=round(d_offset); gATMI.vs[0].x = v.x; gATMI.vs[0].y = v.y-half_w; gATMI.vs[1].x = v.x+half_w; gATMI.vs[1].y = v.y+half_w; gATMI.vs[2].x = v.x-half_w; gATMI.vs[2].y = v.y+half_w; gATMI.vs[3].x = v.x; gATMI.vs[3].y = v.y-half_w; for (i=0; i < 4; i++) gATMI.vs[i].y -= offset; CreatePolygonalTickMark(); } static void CalcCircleVs(v) IntPoint v; { int half_w=(tickMarkSize>>1); struct BBRec obbox; obbox.ltx = v.x-half_w; obbox.lty = v.y-half_w; obbox.rbx = v.x+half_w; obbox.rby = v.y+half_w; CreateOvalObj(&obbox, TRUE); } static void CalcXVs(v) IntPoint v; { int half_w=(tickMarkSize>>1); gATMI.vs[0].x = v.x; gATMI.vs[0].y = v.y; gATMI.vs[1].x = v.x-half_w; gATMI.vs[1].y = v.y-half_w; gATMI.vs[2].x = v.x; gATMI.vs[2].y = v.y; gATMI.vs[3].x = v.x+half_w; gATMI.vs[3].y = v.y-half_w; gATMI.vs[4].x = v.x; gATMI.vs[4].y = v.y; gATMI.vs[5].x = v.x+half_w; gATMI.vs[5].y = v.y+half_w; gATMI.vs[6].x = v.x; gATMI.vs[6].y = v.y; gATMI.vs[7].x = v.x-half_w; gATMI.vs[7].y = v.y+half_w; gATMI.vs[8].x = v.x; gATMI.vs[8].y = v.y; CreatePolygonalTickMark(); } static void CalcDiamondVs(v) IntPoint v; { int half_w=(tickMarkSize>>1); gATMI.vs[0].x = v.x-half_w; gATMI.vs[0].y = v.y; gATMI.vs[1].x = v.x; gATMI.vs[1].y = v.y-half_w; gATMI.vs[2].x = v.x+half_w; gATMI.vs[2].y = v.y; gATMI.vs[3].x = v.x; gATMI.vs[3].y = v.y+half_w; gATMI.vs[4].x = v.x-half_w; gATMI.vs[4].y = v.y; CreatePolygonalTickMark(); } static void CalcBowtieVs(v) IntPoint v; { int half_w=(tickMarkSize>>1); gATMI.vs[0].x = v.x-half_w; gATMI.vs[0].y = v.y-half_w; gATMI.vs[1].x = v.x-half_w; gATMI.vs[1].y = v.y+half_w; gATMI.vs[2].x = v.x+half_w; gATMI.vs[2].y = v.y-half_w; gATMI.vs[3].x = v.x+half_w; gATMI.vs[3].y = v.y+half_w; gATMI.vs[4].x = v.x-half_w; gATMI.vs[4].y = v.y-half_w; CreatePolygonalTickMark(); } static void CalcInvTriangleVs(v) IntPoint v; { int i=0, half_w=(tickMarkSize>>1); double d_offset=((double)tickMarkSize)*((double)3)/((double)16); int offset=round(d_offset); gATMI.vs[0].x = v.x; gATMI.vs[0].y = v.y+half_w; gATMI.vs[1].x = v.x+half_w; gATMI.vs[1].y = v.y-half_w; gATMI.vs[2].x = v.x-half_w; gATMI.vs[2].y = v.y-half_w; gATMI.vs[3].x = v.x; gATMI.vs[3].y = v.y+half_w; for (i=0; i < 4; i++) gATMI.vs[i].y += offset; CreatePolygonalTickMark(); } static void CalcPlusVs(v) IntPoint v; { int half_w=(tickMarkSize>>1); gATMI.vs[0].x = v.x; gATMI.vs[0].y = v.y; gATMI.vs[1].x = v.x-half_w; gATMI.vs[1].y = v.y; gATMI.vs[2].x = v.x; gATMI.vs[2].y = v.y; gATMI.vs[3].x = v.x; gATMI.vs[3].y = v.y-half_w; gATMI.vs[4].x = v.x; gATMI.vs[4].y = v.y; gATMI.vs[5].x = v.x+half_w; gATMI.vs[5].y = v.y; gATMI.vs[6].x = v.x; gATMI.vs[6].y = v.y; gATMI.vs[7].x = v.x; gATMI.vs[7].y = v.y+half_w; gATMI.vs[8].x = v.x; gATMI.vs[8].y = v.y; CreatePolygonalTickMark(); } static void CalcHourGlassVs(v) IntPoint v; { int half_w=(tickMarkSize>>1); gATMI.vs[0].x = v.x-half_w; gATMI.vs[0].y = v.y-half_w; gATMI.vs[1].x = v.x+half_w; gATMI.vs[1].y = v.y-half_w; gATMI.vs[2].x = v.x-half_w; gATMI.vs[2].y = v.y+half_w; gATMI.vs[3].x = v.x+half_w; gATMI.vs[3].y = v.y+half_w; gATMI.vs[4].x = v.x-half_w; gATMI.vs[4].y = v.y-half_w; CreatePolygonalTickMark(); } static void CreateTickMarks(n, vs, nCmdId) int n, nCmdId; IntPoint *vs; { int i=0; for (i=0; i < n; i++) { switch (nCmdId) { case CMDID_ADDSQUARETICKMARKS: CalcSquareVs(vs[i]); break; case CMDID_ADDTRIANGLETICKMARKS: CalcTriangleVs(vs[i]); break; case CMDID_ADDCIRCLETICKMARKS: CalcCircleVs(vs[i]); break; case CMDID_ADDXTICKMARKS: CalcXVs(vs[i]); break; case CMDID_ADDDIAMONDTICKMARKS: CalcDiamondVs(vs[i]); break; case CMDID_ADDBOWTIETICKMARKS: CalcBowtieVs(vs[i]); break; case CMDID_ADDINVTRIANGLETICKMARKS: CalcInvTriangleVs(vs[i]); break; case CMDID_ADDPLUSTICKMARKS: CalcPlusVs(vs[i]); break; case CMDID_ADDHOURGLASSTICKMARKS: CalcHourGlassVs(vs[i]); break; default: break; } } } static void SetRealVertex(vs_return, i, dvs) IntPoint *vs_return; int i; DoublePoint dvs[3]; { DoublePoint m1, m2, m; m1.x = (dvs[0].x+dvs[1].x) / ((double)2); m1.y = (dvs[0].y+dvs[1].y) / ((double)2); m2.x = (dvs[1].x+dvs[2].x) / ((double)2); m2.y = (dvs[1].y+dvs[2].y) / ((double)2); m.x = (m1.x+m2.x) / ((double)2); m.y = (m1.y+m2.y) / ((double)2); vs_return[i].x = round(m.x); vs_return[i].y = round(m.y); } static IntPoint *GetSplinePolyTickMarkVs(pn_return, n, vs, smooth) int *pn_return, n; IntPoint *vs; char *smooth; { int i=0, first_hinge_index=0, write_index=0; IntPoint *vs_return=(IntPoint*)malloc(((n<<1)-1)*sizeof(IntPoint)); if (vs_return == NULL) FailAllocMessage(); memset(vs_return, 0, n*sizeof(IntPoint)); i = write_index = 0; while (i < n) { if (smooth[i]) { int j=0, last_hinge_index=i, num_vs=0; DoublePoint dvs[3]; for (last_hinge_index=i+1; smooth[last_hinge_index]; last_hinge_index++) { } num_vs = last_hinge_index-first_hinge_index+1; if (num_vs > 3) { DoublePoint *mid_pt_of_mid_segs=NULL; mid_pt_of_mid_segs = (DoublePoint*)malloc((num_vs-3)*sizeof(DoublePoint)); if (mid_pt_of_mid_segs == NULL) FailAllocMessage(); memset(mid_pt_of_mid_segs, 0, (num_vs-3)*sizeof(DoublePoint)); for (j=first_hinge_index+1; j < last_hinge_index-1; j++) { /* * These are the midpoints of imaginary line segments * the spline actually runs through. */ mid_pt_of_mid_segs[j-first_hinge_index-1].x = ((double)(vs[j].x + vs[j+1].x)) / ((double)2); mid_pt_of_mid_segs[j-first_hinge_index-1].y = ((double)(vs[j].y + vs[j+1].y)) / ((double)2); } dvs[0].x = (double)(vs[first_hinge_index].x); dvs[0].y = (double)(vs[first_hinge_index].y); dvs[1].x = (double)(vs[first_hinge_index+1].x); dvs[1].y = (double)(vs[first_hinge_index+1].y); dvs[2].x = mid_pt_of_mid_segs[0].x; dvs[2].y = mid_pt_of_mid_segs[0].y; SetRealVertex(vs_return, write_index++, dvs); vs_return[write_index].x = round(dvs[2].x); vs_return[write_index].y = round(dvs[2].y); write_index++; for (j=first_hinge_index+2; j < last_hinge_index-1; j++) { dvs[0].x = mid_pt_of_mid_segs[j-first_hinge_index-2].x; dvs[0].y = mid_pt_of_mid_segs[j-first_hinge_index-2].y; dvs[1].x = (double)(vs[j].x); dvs[1].y = (double)(vs[j].y); dvs[2].x = mid_pt_of_mid_segs[j-first_hinge_index-1].x; dvs[2].y = mid_pt_of_mid_segs[j-first_hinge_index-1].y; SetRealVertex(vs_return, write_index++, dvs); vs_return[write_index].x = round(dvs[2].x); vs_return[write_index].y = round(dvs[2].y); write_index++; } dvs[0].x = mid_pt_of_mid_segs[j-2].x; dvs[0].y = mid_pt_of_mid_segs[j-2].y; dvs[1].x = (double)(vs[last_hinge_index-1].x); dvs[1].y = (double)(vs[last_hinge_index-1].y); dvs[2].x = (double)(vs[last_hinge_index].x); dvs[2].y = (double)(vs[last_hinge_index].y); SetRealVertex(vs_return, write_index++, dvs); free(mid_pt_of_mid_segs); } else { dvs[0].x = (double)(vs[first_hinge_index].x); dvs[0].y = (double)(vs[first_hinge_index].y); dvs[1].x = (double)(vs[first_hinge_index+1].x); dvs[1].y = (double)(vs[first_hinge_index+1].y); dvs[2].x = (double)(vs[first_hinge_index+2].x); dvs[2].y = (double)(vs[first_hinge_index+2].y); SetRealVertex(vs_return, write_index++, dvs); } i = last_hinge_index; } else { vs_return[write_index].x = vs[i].x; vs_return[write_index].y = vs[i].y; first_hinge_index = i; i++; write_index++; } } *pn_return = write_index; return vs_return; } static IntPoint *GetHingedPolygonTickMarkVs(pn_return, n, vs, smooth, first_hinge_index) int *pn_return, n, first_hinge_index; IntPoint *vs; char *smooth; { int i=0, j=0; IntPoint *tmp_vs=NULL; char *tmp_smooth=NULL; IntPoint *vs_return=NULL; if (first_hinge_index == 0) { return GetSplinePolyTickMarkVs(pn_return, n-1, vs, smooth); } tmp_vs = (IntPoint*)malloc(n*sizeof(IntPoint)); if (tmp_vs == NULL) FailAllocMessage(); memset(tmp_vs, 0, n*sizeof(IntPoint)); tmp_smooth = (char*)malloc(n*sizeof(char)); if (tmp_smooth == NULL) FailAllocMessage(); memset(tmp_smooth, 0, n*sizeof(char)); i = first_hinge_index; for (j=0; i < n-1; j++, i++) { tmp_vs[j].x = vs[i].x; tmp_vs[j].y = vs[i].y; tmp_smooth[j] = smooth[i]; } for (i=0; j < n; j++, i++) { tmp_vs[j].x = vs[i].x; tmp_vs[j].y = vs[i].y; tmp_smooth[j] = smooth[i]; } vs_return = GetSplinePolyTickMarkVs(pn_return, n-1, tmp_vs, tmp_smooth); free(tmp_vs); return vs_return; } static IntPoint *GetSplinePolygonTickMarkVs(pn_return, n, vs, smooth) int *pn_return, n; IntPoint *vs; char *smooth; { int i=0, write_index=0; IntPoint *vs_return=NULL; DoublePoint *mid_pt_of_mid_segs=NULL, dvs[3]; for (i=0; i < n; i++) { if (!smooth[i]) { return GetHingedPolygonTickMarkVs(pn_return, n, vs, smooth, i); } } /* every control point is smooth */ vs_return = (IntPoint*)malloc(((n<<1)-1)*sizeof(IntPoint)); if (vs_return == NULL) FailAllocMessage(); memset(vs_return, 0, ((n<<1)-1)*sizeof(IntPoint)); write_index = 0; mid_pt_of_mid_segs = (DoublePoint*)malloc((n-1)*sizeof(DoublePoint)); if (mid_pt_of_mid_segs == NULL) FailAllocMessage(); memset(mid_pt_of_mid_segs, 0, (n-1)*sizeof(DoublePoint)); for (i=0; i < n-1; i++) { /* * These are the midpoints of imaginary line segments * the spline actually runs through. */ mid_pt_of_mid_segs[i].x = ((double)(vs[i].x + vs[i+1].x)) / ((double)2); mid_pt_of_mid_segs[i].y = ((double)(vs[i].y + vs[i+1].y)) / ((double)2); } for (i=0; i < n-1; i++) { if (i == 0) { dvs[0].x = mid_pt_of_mid_segs[n-2].x; dvs[0].y = mid_pt_of_mid_segs[n-2].y; } else { dvs[0].x = mid_pt_of_mid_segs[i-1].x; dvs[0].y = mid_pt_of_mid_segs[i-1].y; } dvs[1].x = (double)(vs[i].x); dvs[1].y = (double)(vs[i].y); dvs[2].x = mid_pt_of_mid_segs[i].x; dvs[2].y = mid_pt_of_mid_segs[i].y; SetRealVertex(vs_return, write_index++, dvs); vs_return[write_index].x = round(dvs[2].x); vs_return[write_index].y = round(dvs[2].y); write_index++; } free(mid_pt_of_mid_segs); *pn_return = write_index; return vs_return; } static int AddObjTickMarks(ObjPtr, nCmdId) struct ObjRec *ObjPtr; int nCmdId; { int n=0, vs_allocated=FALSE, num_cntrl_points=0, cntrl_vs_allocated=FALSE; IntPoint *vs=NULL, *cntrl_vs=NULL; char *smooth=NULL; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; cntrl_vs = GetPolyOrPolygonAbsVs(&num_cntrl_points, &cntrl_vs_allocated, ObjPtr); switch (ObjPtr->type) { case OBJ_POLY: poly_ptr = ObjPtr->detail.p; smooth = poly_ptr->smooth; switch (poly_ptr->curved) { case LT_STRAIGHT: n = num_cntrl_points; vs = cntrl_vs; break; case LT_SPLINE: vs = GetSplinePolyTickMarkVs(&n, num_cntrl_points, cntrl_vs, smooth); vs_allocated = TRUE; break; case LT_INTSPLINE: n = num_cntrl_points; vs = cntrl_vs; break; case LT_STRUCT_SPLINE: vs = GetStructuredSplinePolyTickMarkVs(&n, ObjPtr, poly_ptr, NULL); vs_allocated = TRUE; break; } break; case OBJ_POLYGON: polygon_ptr = ObjPtr->detail.g; smooth = polygon_ptr->smooth; switch (polygon_ptr->curved) { case LT_STRAIGHT: n = num_cntrl_points-1; vs = cntrl_vs; break; case LT_SPLINE: vs = GetSplinePolygonTickMarkVs(&n, num_cntrl_points, cntrl_vs, smooth); vs_allocated = TRUE; break; case LT_INTSPLINE: n = num_cntrl_points-1; vs = cntrl_vs; break; case LT_STRUCT_SPLINE: vs = GetStructuredSplinePolyTickMarkVs(&n, ObjPtr, NULL, polygon_ptr); vs_allocated = TRUE; break; } break; } CreateTickMarks(n, vs, nCmdId); if (vs_allocated) free(vs); if (cntrl_vs_allocated) free(cntrl_vs); return TRUE; } void AddTickMarks(nCmdId) int nCmdId; { struct SelRec *sel_ptr=NULL; struct ObjRec *saved_top_obj=topObj, *saved_bot_obj=botObj; int changed=FALSE; if (topSel == NULL) { MsgBox(TgLoadString(STID_NO_POLY_ETC_SELECTED), TOOL_NAME, INFO_MB); return; } StartCreateTickMarks(nCmdId); HighLightReverse(); curPage->top = curPage->bot = topObj = botObj = NULL; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { struct ObjRec *obj_ptr=sel_ptr->obj; if (obj_ptr->type == OBJ_POLY || obj_ptr->type == OBJ_POLYGON) { AddObjTickMarks(sel_ptr->obj, nCmdId); } } EndCreateTickMarks(); if (topObj != NULL) { struct ObjRec *obj_ptr=NULL, *new_bot_obj=botObj, *prev_obj=NULL; changed = TRUE; RemoveAllSel(); curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; StartCompositeCmd(); for (obj_ptr=new_bot_obj; obj_ptr != NULL; obj_ptr=prev_obj) { prev_obj = obj_ptr->prev; AddObj(NULL, topObj, obj_ptr); RecordNewObjCmd(); } EndCompositeCmd(); for (obj_ptr=saved_top_obj->prev; obj_ptr != NULL; obj_ptr=prev_obj) { prev_obj = obj_ptr->prev; AddObjIntoSel(obj_ptr, NULL, topSel, &topSel, &botSel); } } else { curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; } if (changed) { SetFileModified(TRUE); UpdSelBBox(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); justDupped = FALSE; } else { HighLightForward(); MsgBox(TgLoadString(STID_NO_POLY_ETC_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightForward(); } int SetTickMarkSizeValue(spec) char *spec; { int ival=0; if (sscanf(spec, "%d", &ival) != 1) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_MALFORMED_INPUT_STR), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (ival < 2) { sprintf(gszMsgBox, TgLoadString(STID_ENT_VAL_RANGE_ENTER_GE_INT), spec, 3); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } tickMarkSize = ival; return TRUE; } void SetTickMarkSize(psz_num_segs) char *psz_num_segs; { char spec[MAXSTRING+1]; *spec = '\0'; if (psz_num_segs != NULL && strcmp(psz_num_segs, "-1") != 0) { UtilStrCpyN(spec, sizeof(spec), psz_num_segs); } else { sprintf(gszMsgBox, TgLoadString(STID_ENTER_TICK_MARK_SIZE_CUR_IS), tickMarkSize); if (Dialog(gszMsgBox, NULL, spec) == INVALID) return; } UtilTrimBlanks(spec); if (*spec == '\0') return; if (SetTickMarkSizeValue(spec)) { sprintf(gszMsgBox, TgLoadString(STID_TICK_MARK_SIZE_SET_TO_INT), tickMarkSize); Msg(gszMsgBox); } } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/README.tgwb��������������������������������������������������������������������������0000644�0000764�0000764�00000000317�11602233312�014607� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: RML team at LAND (http://www.land.ufrj.br) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/README.tgwb,v 1.2 2004/09/17 22:21:12 william Exp $ */ Please see README.tgwb in the rmcast directory. �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Copyright����������������������������������������������������������������������������0000644�0000764�0000764�00000001525�11602233314�014664� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������Copyright (C) 2001-2011, William Chia-Wei Cheng This file is part of the QPL release of "tgif". This software is distributed under the terms of the Q Public License as defined by Trolltech AS of Norway and appearing in the file LICENSE.QPL included in the packaging of this software. THIS SOFTWARE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. /* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/Copyright.QPL,v 1.2 2011/05/16 16:26:57 william Exp $ */ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/chat.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000064745�11602233310�014065� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/chat.c,v 1.8 2011/05/16 16:21:56 william Exp $ */ #define _INCLUDE_FROM_CHAT_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "tidget.h" #include "button.e" #include "chat.e" #include "cmd.e" #include "color.e" #include "choose.e" #include "dialog.e" #include "file.e" #include "font.e" #include "http.e" #include "ini.e" #include "inmethod.e" #include "msg.e" #include "menu.e" #include "rect.e" #include "setup.e" #include "strtbl.e" #include "tdgtbtn.e" #include "tdgtsedt.e" #include "tdgtlist.e" #include "tidget.e" #include "util.e" #include "xpixmap.e" #include "xbm/a1.xbm" #include "xbm/bold1.xbm" #include "xbm/italic1.xbm" #define CHAT_BTN_AUTO 0 #define CHAT_BTN_BOLD 1 #define CHAT_BTN_ITALIC 2 #define CHAT_BTN_SEND 3 #define CHAT_BTN_COLOR 4 #define MAX_CHAT_BTNS 5 #define ID_CHAT_BTN_AUTO (100+CHAT_BTN_AUTO) #define ID_CHAT_BTN_BOLD (100+CHAT_BTN_BOLD) #define ID_CHAT_BTN_ITALIC (100+CHAT_BTN_ITALIC) #define ID_CHAT_BTN_SEND (100+CHAT_BTN_SEND) #define ID_CHAT_BTN_COLOR (100+CHAT_BTN_COLOR) #define ID_CHAT_LIST 105 #define ID_CHAT_EDIT 106 typedef struct tagChatInfo { SimpleWinInfo base_win_info, list_win_info, edit_win_info; SimpleWinInfo btn_win_info[MAX_CHAT_BTNS]; int just_clicked; char ini_fname[MAXPATHLENGTH]; int font_height; /* font height used for all controls */ int font_width; int gap; /* gaps between controls */ int btn_width; /* width of square buttons */ int num_lines; /* number of visible lines in the list control */ TdgtList *list_ctl; TdgtBtn *btn_ctl[MAX_CHAT_BTNS]; TdgtSmplEdit *edit_ctl; } ChatInfo; ChatInfo gstChatInfo; char *cmdLineChatNickName=NULL; static Pixmap a1Pixmap=None; static Pixmap bold1Pixmap=None; static Pixmap italic1Pixmap=None; static char *gpszChatNickName=NULL; void RedrawChatWindow() { if (PRTGIF || noChatWindow || chatWindow == None) return; /* draw a frame around the window */ if (threeDLook) { if (dialogboxUse3DBorder) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, gstChatInfo.base_win_info.w, gstChatInfo.base_win_info.h); TgDrawThreeDButton(mainDisplay, chatWindow, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); } } else { XDrawRectangle(mainDisplay, chatWindow, nameGC, 0, 0, gstChatInfo.base_win_info.w-1, gstChatInfo.base_win_info.h-1); } } static void MoveResizeChatSubWindows() { if (gstChatInfo.list_ctl != NULL) { TidgetMoveResize(gstChatInfo.list_ctl->pti, gstChatInfo.list_win_info.x, gstChatInfo.list_win_info.y, gstChatInfo.list_win_info.w, gstChatInfo.list_win_info.h); } if (gstChatInfo.btn_ctl[CHAT_BTN_SEND] != NULL) { TidgetMoveResize((gstChatInfo.btn_ctl[CHAT_BTN_SEND])->pti, gstChatInfo.btn_win_info[CHAT_BTN_SEND].x, gstChatInfo.btn_win_info[CHAT_BTN_SEND].y, gstChatInfo.btn_win_info[CHAT_BTN_SEND].w, gstChatInfo.btn_win_info[CHAT_BTN_SEND].h); } if (gstChatInfo.edit_ctl != NULL) { TidgetMoveResize(gstChatInfo.edit_ctl->pti, gstChatInfo.edit_win_info.x, gstChatInfo.edit_win_info.y, gstChatInfo.edit_win_info.w, gstChatInfo.edit_win_info.h); } } void MoveResizeChatWindow(x, y, w, h) int x, y, w, h; { XMoveResizeWindow(mainDisplay, chatWindow, x, y, w, h); MoveResizeChatSubWindows(); } static int GetChatFontStyle(pnIsBold, pnIsItalic) int *pnIsBold, *pnIsItalic; { int bold_state=TdgtBtnGetState(gstChatInfo.btn_ctl[CHAT_BTN_BOLD]); int italic_state=TdgtBtnGetState(gstChatInfo.btn_ctl[CHAT_BTN_ITALIC]); int is_bold=(bold_state != TGBS_NORMAL); int is_italic=(italic_state != TGBS_NORMAL); int font_style=INVALID; if (is_bold) { if (is_italic) { font_style = STYLE_BI; } else { font_style = STYLE_BR; } } else { if (is_italic) { font_style = STYLE_NI; } else { font_style = STYLE_NR; } } if (pnIsBold != NULL) *pnIsBold = is_bold; if (pnIsItalic != NULL) *pnIsItalic = is_italic; return font_style; } static int InitChatNickName() { char *c_ptr=NULL; if (cmdLineChatNickName != NULL) { gpszChatNickName = UtilStrDup(cmdLineChatNickName); } else { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ChatNickName")) != NULL) { gpszChatNickName = UtilStrDup(c_ptr); } } if (gpszChatNickName == NULL) { c_ptr = getenv("USER"); if (c_ptr != NULL) { gpszChatNickName = UtilStrDup(c_ptr); } else { gpszChatNickName = UtilStrDup( TgLoadCachedString(CSTID_PARANED_UNKNOWN)); } } if (gpszChatNickName == NULL) FailAllocMessage(); return TRUE; } static void GetChatNickName(buf, buf_sz) char *buf; int buf_sz; { UtilStrCpyN(buf, buf_sz, gpszChatNickName); } static int AddChatLineToListCtl(nick_name, color_index, font_style, buf) char *nick_name, *buf; int color_index, font_style; { ListItemInfo *pListItemInfo=(ListItemInfo*)malloc(sizeof(ListItemInfo)); if (pListItemInfo == NULL) FailAllocMessage(); memset(pListItemInfo, 0, sizeof(ListItemInfo)); UtilStrCpyN(pListItemInfo->nick_name, sizeof(pListItemInfo->nick_name), nick_name); pListItemInfo->color_index = color_index; pListItemInfo->font_style = font_style; pListItemInfo->buf = UtilStrDup(buf); if (pListItemInfo->buf == NULL) FailAllocMessage(); return TdgtListInsertListItemInfo(gstChatInfo.list_ctl, pListItemInfo); } static void ChatSendClicked() { char *buf=TdgtSmplEditGetText(gstChatInfo.edit_ctl); if (buf != NULL && *buf != '\0') { int saved_auto_scroll=TdgtListGetAutoScrollOnInsert(gstChatInfo.list_ctl); int rc=0; struct SubCmdRec subcmd; char *encoded_text=Base64Encode(buf); memset(&subcmd, 0, sizeof(struct SubCmdRec)); TdgtSmplEditGetTextFormatInfo(gstChatInfo.edit_ctl, &subcmd.detail.chat.tfi); subcmd.detail.chat.type = CHAT_STATE_NORMAL; GetChatNickName(subcmd.detail.chat.nick_name, sizeof(subcmd.detail.chat.nick_name)); UtilStrCpyN(subcmd.detail.chat.encoding, sizeof(subcmd.detail.chat.encoding), "base64"); TdgtListSetAutoScrollOnInsert(gstChatInfo.list_ctl, TRUE); rc = AddChatLineToListCtl(subcmd.detail.chat.nick_name, subcmd.detail.chat.tfi.color_index, subcmd.detail.chat.tfi.font_style, buf); TdgtListSetAutoScrollOnInsert(gstChatInfo.list_ctl, saved_auto_scroll); if (rc) { subcmd.detail.chat.buf = UtilStrDup(encoded_text); if (subcmd.detail.chat.buf == NULL) FailAllocMessage(); RecordWBChatALine(&subcmd); UtilFree(subcmd.detail.chat.buf); } TdgtSmplEditSetText(gstChatInfo.edit_ctl, ""); UtilFree(encoded_text); } } void ChatEventHandler(input, handling_pti) XEvent *input; TidgetInfo *handling_pti; { int keypress_event=(input->type==KeyPress), event_handled=FALSE; if (PRTGIF || noChatWindow || chatWindow == None) return; /* * If the event is a KeyPress event, either a special key is pressed * or a regular key is pressed. Special keys should be handled * by the list control and regular keys should be handled by * the edit control. */ if (input->xany.window == chatWindow) { TdgtNtfy tdgt_notify; memset(&tdgt_notify, 0, sizeof(TdgtNtfy)); if (input->type == Expose) { XEvent ev; RedrawChatWindow(); while (XCheckWindowEvent(mainDisplay, chatWindow, ExposureMask, &ev)) ; } else if (input->type == EnterNotify) { SetMouseStatus("", "", ""); if (input->xcrossing.mode == NotifyNormal && (input->xcrossing.detail == NotifyAncestor || input->xcrossing.detail == NotifyNonlinear || input->xcrossing.detail == NotifyNonlinearVirtual)) { TdgtSmplEditSetFocus(gstChatInfo.edit_ctl, TRUE); if (gnInputMethod != TGIM_NONE) { tgIMFocusIn(mainDisplay, gstChatInfo.edit_ctl->pti->tci.win); } } } else if (input->type == LeaveNotify) { if (input->xcrossing.mode == NotifyNormal && (input->xcrossing.detail == NotifyAncestor || input->xcrossing.detail == NotifyNonlinear || input->xcrossing.detail == NotifyNonlinearVirtual)) { TdgtSmplEditSetFocus(gstChatInfo.edit_ctl, FALSE); if (gnInputMethod != TGIM_NONE) { tgIMFocusOut(mainDisplay, gstChatInfo.edit_ctl->pti->tci.win); } } } else if (IsTdgtWindowNotifyEvent(chatWindow, input, &tdgt_notify)) { switch (tdgt_notify.nf_type) { case TDGTNF_EDIT_ENTERED: ChatSendClicked(); break; case TDGTNF_BTN_CLICKED: switch (tdgt_notify.ctl_id) { case ID_CHAT_BTN_SEND: ChatSendClicked(); break; case ID_CHAT_BTN_BOLD: case ID_CHAT_BTN_ITALIC: { int is_bold=FALSE, is_italic=FALSE; /* bold or italic button changed state */ int font_style=GetChatFontStyle(&is_bold, &is_italic); TdgtSmplEditSetFontStyle(gstChatInfo.edit_ctl, font_style); tgWriteProfileString("User", "Bold", (is_bold ? "1" : "0"), gstChatInfo.ini_fname); tgWriteProfileString("User", "Italic", (is_italic ? "1" : "0"), gstChatInfo.ini_fname); tgWriteProfileString(NULL, NULL, NULL, gstChatInfo.ini_fname); } break; case ID_CHAT_BTN_AUTO: { /* auto scroll changed state */ int auto_state=TdgtBtnGetState( gstChatInfo.btn_ctl[CHAT_BTN_AUTO]); int auto_scroll=(auto_state != TGBS_NORMAL); TdgtListSetAutoScrollOnInsert(gstChatInfo.list_ctl, auto_scroll); } break; } break; case TDGTNF_MULTI_BTN_CLICKED: if (tdgt_notify.ctl_id == ID_CHAT_BTN_COLOR) { int color_index=INVALID; switch (tdgt_notify.nf_arg) { /* Button[1-3] */ case Button1: color_index = (int)(long)TdgtBtnGetText( gstChatInfo.btn_ctl[CHAT_BTN_COLOR]); if (++color_index >= maxColors) color_index = 0; break; case Button2: color_index = tdgt_notify.nf_arg2; break; case Button3: color_index = (int)(long)TdgtBtnGetText( gstChatInfo.btn_ctl[CHAT_BTN_COLOR]); if (--color_index < 0) color_index = maxColors-1; break; } TdgtBtnSetText(gstChatInfo.btn_ctl[CHAT_BTN_COLOR], (char*)(long)color_index, NULL); TdgtSmplEditSetColorIndex(gstChatInfo.edit_ctl, color_index); tgWriteProfileString("User", "Color", colorMenuItems[color_index], gstChatInfo.ini_fname); tgWriteProfileString(NULL, NULL, NULL, gstChatInfo.ini_fname); } break; } event_handled = TRUE; } } else if (gstChatInfo.list_ctl != NULL && TidgetEventHandler(gstChatInfo.list_ctl->pti, input, handling_pti)) { /* this event has been handled by the list */ event_handled = TRUE; } else if (gstChatInfo.edit_ctl != NULL && TidgetEventHandler(gstChatInfo.edit_ctl->pti, input, handling_pti)) { event_handled = TRUE; } else { int i=0; for (i=0; i < MAX_CHAT_BTNS; i++) { if (gstChatInfo.btn_ctl[i] != NULL && TidgetEventHandler((gstChatInfo.btn_ctl[i])->pti, input, handling_pti)) { event_handled = TRUE; } } } if (keypress_event && !event_handled && TidgetEventHandler(gstChatInfo.edit_ctl->pti, input, handling_pti)) { } } int IsChatWindowEvent(input, ppti_handler_tidget_return) XEvent *input; TidgetInfo **ppti_handler_tidget_return; { int i=0; *ppti_handler_tidget_return = NULL; if (chatWindow == None) return FALSE; if (input->xany.window == chatWindow) return TRUE; if (gstChatInfo.list_ctl != NULL && IsTidgetEvent(gstChatInfo.list_ctl->pti, input, ppti_handler_tidget_return)) { return TRUE; } for (i=0; i < MAX_CHAT_BTNS; i++) { if (gstChatInfo.btn_ctl[i] != NULL && IsTidgetEvent((gstChatInfo.btn_ctl[i])->pti, input, ppti_handler_tidget_return)) { return TRUE; } } if (gstChatInfo.edit_ctl != NULL && IsTidgetEvent(gstChatInfo.edit_ctl->pti, input, ppti_handler_tidget_return)) { return TRUE; } return FALSE; } #define BTN_Y_MARGIN 2 int GetInitialChatWindowHeight() { int x=0, y=0; gstChatInfo.num_lines=6; if (msgFontSet == NULL && msgFontPtr == NULL) { gstChatInfo.font_height = defaultFontHeight; gstChatInfo.font_width = defaultFontWidth; } else { gstChatInfo.font_height = msgFontHeight; gstChatInfo.font_width = msgFontWidth; } gstChatInfo.btn_width = a1_width+(windowPadding<<1); /* gap */ y = gstChatInfo.gap = 4; /* list control */ gstChatInfo.list_win_info.x = gstChatInfo.gap; gstChatInfo.list_win_info.y = y; gstChatInfo.list_win_info.w = (-1); gstChatInfo.list_win_info.h = (gstChatInfo.num_lines*ROW_HEIGHT)+2+(windowPadding<<1); y += gstChatInfo.list_win_info.h; /* gap */ y += gstChatInfo.gap; /* other controls */ x = gstChatInfo.list_win_info.x; gstChatInfo.btn_win_info[CHAT_BTN_AUTO].x = x; gstChatInfo.btn_win_info[CHAT_BTN_AUTO].y = y; gstChatInfo.btn_win_info[CHAT_BTN_AUTO].w = gstChatInfo.btn_width; gstChatInfo.btn_win_info[CHAT_BTN_AUTO].h = gstChatInfo.btn_width; x += gstChatInfo.btn_width + (gstChatInfo.btn_width>>1); gstChatInfo.btn_win_info[CHAT_BTN_COLOR].x = x; gstChatInfo.btn_win_info[CHAT_BTN_COLOR].y = y; gstChatInfo.btn_win_info[CHAT_BTN_COLOR].w = gstChatInfo.btn_width; gstChatInfo.btn_win_info[CHAT_BTN_COLOR].h = gstChatInfo.btn_width; x += gstChatInfo.btn_width + 2; gstChatInfo.btn_win_info[CHAT_BTN_BOLD].x = x; gstChatInfo.btn_win_info[CHAT_BTN_BOLD].y = y; gstChatInfo.btn_win_info[CHAT_BTN_BOLD].w = gstChatInfo.btn_width; gstChatInfo.btn_win_info[CHAT_BTN_BOLD].h = gstChatInfo.btn_width; x += gstChatInfo.btn_width + 2; gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].x = x; gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].y = y; gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].w = gstChatInfo.btn_width; gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].h = gstChatInfo.btn_width; x += gstChatInfo.btn_width + (gstChatInfo.btn_width>>1); gstChatInfo.edit_win_info.x = x; gstChatInfo.edit_win_info.y = y; gstChatInfo.edit_win_info.w = (-1); gstChatInfo.edit_win_info.h = gstChatInfo.btn_width; x += gstChatInfo.btn_width + (gstChatInfo.btn_width>>1); gstChatInfo.btn_win_info[CHAT_BTN_SEND].x = (-1); gstChatInfo.btn_win_info[CHAT_BTN_SEND].y = y; gstChatInfo.btn_win_info[CHAT_BTN_SEND].w = ButtonWidth("Send", 4, NULL); gstChatInfo.btn_win_info[CHAT_BTN_SEND].h = (gstChatInfo.font_height+(BTN_Y_MARGIN<<1)+(windowPadding<<1)); y += gstChatInfo.btn_width; /* gap */ y += gstChatInfo.gap; return y; } void SetChatWindowGeom() { int x=0, y=0; gstChatInfo.base_win_info.x = (-1); gstChatInfo.base_win_info.y = (-1); gstChatInfo.base_win_info.w = chatWindowW; gstChatInfo.base_win_info.h = chatWindowH; /* gap */ y = gstChatInfo.gap; /* list control */ gstChatInfo.list_win_info.x = gstChatInfo.gap; gstChatInfo.list_win_info.y = y; gstChatInfo.list_win_info.w = gstChatInfo.base_win_info.w - (gstChatInfo.gap<<1); gstChatInfo.list_win_info.h = (gstChatInfo.num_lines*ROW_HEIGHT)+2+(windowPadding<<1); y += gstChatInfo.list_win_info.h; /* gap */ y += gstChatInfo.gap; /* other controls */ x = gstChatInfo.list_win_info.x; gstChatInfo.btn_win_info[CHAT_BTN_AUTO].x = x; gstChatInfo.btn_win_info[CHAT_BTN_AUTO].y = y; gstChatInfo.btn_win_info[CHAT_BTN_AUTO].w = gstChatInfo.btn_width; gstChatInfo.btn_win_info[CHAT_BTN_AUTO].h = gstChatInfo.btn_width; x += gstChatInfo.btn_width + (gstChatInfo.btn_width>>1); gstChatInfo.btn_win_info[CHAT_BTN_COLOR].x = x; gstChatInfo.btn_win_info[CHAT_BTN_COLOR].y = y; gstChatInfo.btn_win_info[CHAT_BTN_COLOR].w = gstChatInfo.btn_width; gstChatInfo.btn_win_info[CHAT_BTN_COLOR].h = gstChatInfo.btn_width; x += gstChatInfo.btn_width + 2; gstChatInfo.btn_win_info[CHAT_BTN_BOLD].x = x; gstChatInfo.btn_win_info[CHAT_BTN_BOLD].y = y; gstChatInfo.btn_win_info[CHAT_BTN_BOLD].w = gstChatInfo.btn_width; gstChatInfo.btn_win_info[CHAT_BTN_BOLD].h = gstChatInfo.btn_width; x += gstChatInfo.btn_width + 2; gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].x = x; gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].y = y; gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].w = gstChatInfo.btn_width; gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].h = gstChatInfo.btn_width; x += gstChatInfo.btn_width + (gstChatInfo.btn_width>>1); gstChatInfo.edit_win_info.x = x; gstChatInfo.edit_win_info.y = y; gstChatInfo.edit_win_info.w = (-1); gstChatInfo.edit_win_info.h = gstChatInfo.btn_width; x += gstChatInfo.btn_width + (gstChatInfo.btn_width>>1); gstChatInfo.btn_win_info[CHAT_BTN_SEND].x = (-1); gstChatInfo.btn_win_info[CHAT_BTN_SEND].y = y; gstChatInfo.btn_win_info[CHAT_BTN_SEND].w = ButtonWidth("Send", 4, NULL); gstChatInfo.btn_win_info[CHAT_BTN_SEND].h = gstChatInfo.btn_width; y += gstChatInfo.btn_width; gstChatInfo.btn_win_info[CHAT_BTN_SEND].x = gstChatInfo.base_win_info.w - gstChatInfo.gap - (windowPadding<<1) - gstChatInfo.btn_win_info[CHAT_BTN_SEND].w; gstChatInfo.edit_win_info.w = gstChatInfo.btn_win_info[CHAT_BTN_SEND].x - (gstChatInfo.btn_width>>1) - gstChatInfo.edit_win_info.x; /* gap */ y += gstChatInfo.gap; } void MapChatSubWindows() { int i=0; if (gstChatInfo.list_ctl != NULL) MapTidget(gstChatInfo.list_ctl->pti); for (i=0; i < MAX_CHAT_BTNS; i++) { if (gstChatInfo.btn_ctl[i] != NULL) { MapTidget((gstChatInfo.btn_ctl[i])->pti); } } if (gstChatInfo.edit_ctl != NULL) MapTidget(gstChatInfo.edit_ctl->pti); } int CreateChatSubWindows() { MouseOverStatusInfo mosi; char *buf=NULL; int new_alloc=FALSE, ival=0, font_style=STYLE_NR; int is_bold=FALSE, is_italic=FALSE, color_index=colorIndex; if ((buf=tgGetProfileString("User", "Color", gstChatInfo.ini_fname)) != NULL) { color_index = QuickFindColorIndex(NULL, buf, &new_alloc, TRUE); tgFreeProfileString(buf); } if ((buf=tgGetProfileString("User", "Bold", gstChatInfo.ini_fname)) != NULL) { if (sscanf(buf, "%d", &ival) == 1) { is_bold = ival; } else { tgWriteProfileString("User", "Bold", "0", gstChatInfo.ini_fname); tgWriteProfileString(NULL, NULL, NULL, gstChatInfo.ini_fname); } tgFreeProfileString(buf); } if ((buf=tgGetProfileString("User", "Italic", gstChatInfo.ini_fname)) != NULL) { if (sscanf(buf, "%d", &ival) == 1) { is_italic = ival; } else { tgWriteProfileString("User", "Italic", "0", gstChatInfo.ini_fname); tgWriteProfileString(NULL, NULL, NULL, gstChatInfo.ini_fname); } tgFreeProfileString(buf); } if (is_bold) { if (is_italic) { font_style = STYLE_BI; } else { font_style = STYLE_BR; } } else { if (is_italic) { font_style = STYLE_NI; } else { font_style = STYLE_NR; } } memset(&mosi, 0, sizeof(MouseOverStatusInfo)); mosi.one_line_status = TRUE; a1Pixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char*)a1_bits, a1_width, a1_height); bold1Pixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char*)bold1_bits, bold1_width, bold1_height); italic1Pixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char*)italic1_bits, italic1_width, italic1_height); gstChatInfo.list_ctl = CreateTdgtList(chatWindow, NULL, ID_CHAT_LIST, gstChatInfo.list_win_info.x, gstChatInfo.list_win_info.y, gstChatInfo.list_win_info.w, TDGTLIST_DEF_H_PAD, TDGTLIST_DEF_V_PAD, gstChatInfo.num_lines, FALSE, TRUE, TRUE); if (gstChatInfo.list_ctl == NULL) return FALSE; UtilStrCpyN(mosi.one_line_str, sizeof(mosi.one_line_str), TgLoadString(STID_TOGGLE_AUTO_SCR_IN_CHAT)); gstChatInfo.btn_ctl[CHAT_BTN_AUTO] = CreateTdgtBtn(chatWindow, NULL, ID_CHAT_BTN_AUTO, gstChatInfo.btn_win_info[CHAT_BTN_AUTO].x, gstChatInfo.btn_win_info[CHAT_BTN_AUTO].y, gstChatInfo.btn_win_info[CHAT_BTN_AUTO].w, gstChatInfo.btn_win_info[CHAT_BTN_AUTO].h, 0, 0, TGMUTYPE_BITMAP, TDGTBTN_STICKY, TGBS_LOWRED, STYLE_NR, (char*)(&a1Pixmap), &mosi); UtilStrCpyN(mosi.one_line_str, sizeof(mosi.one_line_str), TgLoadString(STID_TOGGLE_BOLD_IN_CHAT)); gstChatInfo.btn_ctl[CHAT_BTN_BOLD] = CreateTdgtBtn(chatWindow, NULL, ID_CHAT_BTN_BOLD, gstChatInfo.btn_win_info[CHAT_BTN_BOLD].x, gstChatInfo.btn_win_info[CHAT_BTN_BOLD].y, gstChatInfo.btn_win_info[CHAT_BTN_BOLD].w, gstChatInfo.btn_win_info[CHAT_BTN_BOLD].h, 0, 0, TGMUTYPE_BITMAP, TDGTBTN_STICKY, (is_bold ? TGBS_LOWRED : TGBS_NORMAL), STYLE_BR, (char*)(&bold1Pixmap), &mosi); UtilStrCpyN(mosi.one_line_str, sizeof(mosi.one_line_str), TgLoadString(STID_TOGGLE_ITALIC_IN_CHAT)); gstChatInfo.btn_ctl[CHAT_BTN_ITALIC] = CreateTdgtBtn(chatWindow, NULL, ID_CHAT_BTN_ITALIC, gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].x, gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].y, gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].w, gstChatInfo.btn_win_info[CHAT_BTN_ITALIC].h, 0, 0, TGMUTYPE_BITMAP, TDGTBTN_STICKY, (is_italic ? TGBS_LOWRED : TGBS_NORMAL), STYLE_NI, (char*)(&italic1Pixmap), &mosi); UtilStrCpyN(mosi.one_line_str, sizeof(mosi.one_line_str), TgLoadString(STID_SEND_CHAT_TEXT)); gstChatInfo.btn_ctl[CHAT_BTN_SEND] = CreateTdgtBtn(chatWindow, NULL, ID_CHAT_BTN_SEND, gstChatInfo.btn_win_info[CHAT_BTN_SEND].x, gstChatInfo.btn_win_info[CHAT_BTN_SEND].y, gstChatInfo.btn_win_info[CHAT_BTN_SEND].w, gstChatInfo.btn_win_info[CHAT_BTN_SEND].h, 0, 0, TGMUTYPE_TEXT, TDGTBTN_CLICK, TGBS_NORMAL, STYLE_NR, "Send", &mosi); mosi.one_line_status = FALSE; UtilStrCpyN(mosi.btn_str[0], sizeof(mosi.btn_str[0]), colorMouseStatus[0].l); UtilStrCpyN(mosi.btn_str[1], sizeof(mosi.btn_str[1]), colorMouseStatus[0].m); UtilStrCpyN(mosi.btn_str[2], sizeof(mosi.btn_str[2]), colorMouseStatus[0].r); gstChatInfo.btn_ctl[CHAT_BTN_COLOR] = CreateTdgtBtn(chatWindow, NULL, ID_CHAT_BTN_COLOR, gstChatInfo.btn_win_info[CHAT_BTN_COLOR].x, gstChatInfo.btn_win_info[CHAT_BTN_COLOR].y, gstChatInfo.btn_win_info[CHAT_BTN_COLOR].w, gstChatInfo.btn_win_info[CHAT_BTN_COLOR].h, 0, 0, TGMUTYPE_COLOR, TDGTBTN_CLICK, TGBS_NORMAL, INVALID, (char*)(long)color_index, &mosi); gstChatInfo.edit_ctl = CreateTdgtSmplEdit(chatWindow, NULL, ID_CHAT_EDIT, gstChatInfo.edit_win_info.x, gstChatInfo.edit_win_info.y, gstChatInfo.edit_win_info.w, TDGTSEDT_DEF_H_PAD, TDGTSEDT_DEF_V_PAD, "", font_style, color_index); if (gstChatInfo.edit_ctl == NULL) return FALSE; return TRUE; } /* --------------------- ChatInsertChatLine --------------------- */ void ChatAppendChatLine(ptfi, nick_name, encoding, buf) TextFormatInfo *ptfi; char *nick_name, *encoding, *buf; { char *clear_text=NULL; ListItemInfo *pListItemInfo=(ListItemInfo*)malloc(sizeof(ListItemInfo)); if (pListItemInfo == NULL) FailAllocMessage(); memset(pListItemInfo, 0, sizeof(ListItemInfo)); if (*encoding == '\0') { clear_text = buf; } else if (strcmp(encoding, "base64") == 0) { clear_text = Base64Decode(buf); } else { /* reject */ } UtilStrCpyN(pListItemInfo->nick_name, sizeof(pListItemInfo->nick_name), nick_name); pListItemInfo->color_index = ptfi->color_index; pListItemInfo->font_style = ptfi->font_style; pListItemInfo->buf = UtilStrDup(clear_text); if (pListItemInfo->buf == NULL) FailAllocMessage(); TdgtListInsertListItemInfo(gstChatInfo.list_ctl, pListItemInfo); UtilFree(clear_text); } /* --------------------- ChatAddUser --------------------- */ void ChatAddUser(buf) char *buf; { } /* --------------------- Init & Clean Up --------------------- */ int InitChat() { memset(&gstChatInfo, 0, sizeof(ChatInfo)); sprintf(gstChatInfo.ini_fname, "%s%cchat.ini", tgifDir, DIR_SEP); return InitChatNickName(); } void CleanUpChat() { int i=0; UtilFree(gpszChatNickName); gpszChatNickName = NULL; if (a1Pixmap != None) XFreePixmap(mainDisplay, a1Pixmap); if (bold1Pixmap != None) XFreePixmap(mainDisplay, bold1Pixmap); if (italic1Pixmap != None) XFreePixmap(mainDisplay, italic1Pixmap); a1Pixmap = bold1Pixmap = italic1Pixmap = None; if (gstChatInfo.list_ctl != NULL) { TidgetInfo *pti=((gstChatInfo.list_ctl)->pti); DestroyTidget(&pti); } for (i=0; i < MAX_CHAT_BTNS; i++) { if (gstChatInfo.btn_ctl[i] != NULL) { TidgetInfo *pti=((gstChatInfo.btn_ctl[i])->pti); DestroyTidget(&pti); } } if (gstChatInfo.edit_ctl != NULL) { TidgetInfo *pti=((gstChatInfo.edit_ctl)->pti); DestroyTidget(&pti); } } ���������������������������tgif-QPL-4.2.5/auxtext.e����������������������������������������������������������������������������0000644�0000764�0000764�00000012462�11602233310�014637� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/auxtext.e,v 1.7 2011/05/16 16:21:56 william Exp $ */ #ifndef _AUXTEXT_E_ #define _AUXTEXT_E_ extern GC rotateGC; extern Pixmap textBackingBitmap; extern Pixmap textBackingBgBitmap; extern Pixmap textBackingPixmap; extern int textBackingBitmapW; extern int textBackingBitmapH; extern int doubleQuoteDoubleQuote; extern int groupedTextEditable; extern struct SelRec * outerSel, * innerSel; #ifdef _INCLUDE_FROM_AUXTEXT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_AUXTEXT_C_*/ extern void GetStrSizeInfo ARGS_DECL((struct DynStrRec *, int *w, int *lbearing, int *rbearing)); extern int GetNumberOfMiniLines ARGS_DECL((MiniLinesInfo*)); extern int IsHex ARGS_DECL((char, int*)); extern int InputOctalString ARGS_DECL((char *pszBuf, int *pnBufSize)); extern int CharIsCntrlINS ARGS_DECL((XKeyEvent*, KeySym)); extern int CharIsShiftINS ARGS_DECL((XKeyEvent*, KeySym)); extern int CharIsCntrlShiftINS ARGS_DECL((XKeyEvent*, KeySym)); extern int CharIsESC ARGS_DECL((XKeyEvent*, char*, KeySym, int *pnHasCh)); extern int CharIsCRorLF ARGS_DECL((XKeyEvent*, char*, KeySym, int *pnHasCh)); extern int CharIsDEL ARGS_DECL((XKeyEvent*, char*, KeySym, int *pnHasCh)); extern int CharIsBS ARGS_DECL((XKeyEvent*, char*, KeySym, int *pnHasCh, int LeftIsBS)); extern int CharIsBSorDEL ARGS_DECL((XKeyEvent*, char*, KeySym, int *pnHasCh, int LeftIsBS)); extern int CharIsTAB ARGS_DECL((XKeyEvent*, char*, KeySym, int *pnHasCh)); extern int CharIsHome ARGS_DECL((XKeyEvent*, char*, KeySym, int *pnHasCh)); extern int CharIsEnd ARGS_DECL((XKeyEvent*, char*, KeySym, int *pnHasCh)); extern int CharIsCntrlSpace ARGS_DECL((XKeyEvent*, char*, KeySym, int *pnHasCh)); extern void TranslateKeys ARGS_DECL((char *, KeySym *)); extern void SetTextOBBox ARGS_DECL((struct ObjRec *, int Just, int W, int H, int LBearing, int RightExtra, int Rotate)); extern void SetTextBBox ARGS_DECL((struct ObjRec *, int Just, int W, int H, int LBearing, int RightExtra, int Rotate)); extern void SetTextOrigBBoxes ARGS_DECL((struct ObjRec *, int Just, int W, int H, int LBearing, int RightExtra, int Rotate)); extern int UpdTextBBox ARGS_DECL((struct ObjRec *)); extern int PixelOnOff ARGS_DECL((XImage *, int Col, int Row, int Scale)); extern void MakeCachedTextBitmap ARGS_DECL((struct ObjRec *)); extern void CleanOuterInnerSel ARGS_DECL((void)); extern void UpdateOuterInnerSel ARGS_DECL((struct ObjRec *)); extern struct ObjRec * FindTextObj ARGS_DECL((int XOff, int YOff, struct ObjRec *ObjToBeFound)); extern void UnlinkCurTextFromInnerSel ARGS_DECL((void)); extern void AdjAncestorsBBox ARGS_DECL((void)); extern void DumpTextObj ARGS_DECL((FILE *, struct ObjRec *)); extern int NeedToCacheMiniLines ARGS_DECL((MiniLinesInfo*)); extern int NeedsToCacheTextObj ARGS_DECL((struct ObjRec *)); extern void SaveString ARGS_DECL((FILE *, char *)); extern void SaveDoubleByteString ARGS_DECL((FILE *, char *)); extern void SaveMiniLines ARGS_DECL((FILE*, MiniLinesInfo*)); extern void CombineOverUnderYOffsets ARGS_DECL((int underline_y_offset, int overline_y_offset, int *pn_combined)); extern void UncombineOverUnderYOffsets ARGS_DECL((int combined, int *pn_underline_y_offset, int *pn_overline_y_offset)); extern void SaveTextObj ARGS_DECL((FILE *, struct ObjRec *)); extern void SaveHexString ARGS_DECL((FILE *, char *)); extern char * ReadString ARGS_DECL((char *)); extern StrSegInfo * CreateStrSegFromString ARGS_DECL((char*, StrBlockInfo*)); extern StrBlockInfo * CreateStrBlockFromString ARGS_DECL((char*, MiniLineInfo*)); extern MiniLineInfo * CreateMiniLineFromString ARGS_DECL((char*, MiniLineInfo**, MiniLineInfo**)); extern struct ObjRec * FormTextObjectFromFile ARGS_DECL((FILE *, int AbsX, int AbsBaselineY)); extern void RepaintFirstStr ARGS_DECL((struct ObjRec *, char *)); #ifdef _INCLUDE_FROM_AUXTEXT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_AUXTEXT_C_*/ #endif /*_AUXTEXT_E_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/VMS_MAKE_TGIF.COM��������������������������������������������������������������������0000644�0000764�0000764�00000012236�11602233313�015404� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������$! $! @(#)$Header: /mm2/home/cvs/bc-src/tgif/VMS_MAKE_TGIF.COM,v 1.1 2004/06/18 23:20:49 william Exp $ $! $! VAX/VMS command file to compile and link TGIF. $! $! NOTE: This command file is only to be viewed as an EXAMPLE $! on how to build TGIF on a VAX/VMS system. $! THIS COMMAND FILE MAY NOT WORK, NOR DO WHAT $! YOU THINK IT DOES. $! $! Created by Mats Bergstr"om, University of Lund. $! $! The TGIF default extension for the object files is ".obj", $! since this collides with the default VMS ".OBJ" extension $! for compiled files, the name used for TGIF object files is $! changed to ".tgif". $! Feel free to change it at any time. $! Mind the quotes below though ;-) $! $! Have a look at the document to change the defines BEFORE $! You try to run this... $! $! After unpacking TGIF there are problably some files with $! extension ".OBJ". Use the extension ".o" for all compiled $! object files created to avoid confusion! $! $ define sys sys$library $ define x11 decw$include $! $! $ compile := cc/object=*.o $! $ defs := "( ""TGIF_DIR=""""TGIF$DIR"""""" ,"- " ""TGIF_PATH=""""TGIF$DIR"""""" ,"- " ""PSFILE_MOD=0664"","- " ""OBJ_FILE_EXT=""""tgif"""""" ,"- " ""SYM_FILE_EXT=""""sym"""""" ,"- " ""EPSF_FILE_EXT=""""eps"""""" ,"- " ""PS_FILE_EXT=""""ps"""""" ,"- " ""XBM_FILE_EXT=""""xbm"""""" ,"- " ""XPM_FILE_EXT=""""xpm"""""" ,"- " ""TEXT_FILE_EXT=""""txt"""""" ,"- " ""TELEPORT_ATTR=""""warp_to="""""" ,"- " ""LAUNCH_ATTR=""""launch="""""" ,"- " ""EXEC_ATTR=""""exec="""""" ,"- " ""TMP_DIR=""""SYS$SCRATCH:"""""" ,"- " ""KEEP_WHEN_PRINT"","- " ""PRINT_CMD=""""TGIF$PRINT"""""" ,"- " ""NOTR4MODE"","- " ""_NO_LSTAT"","- " ""_NO_GETTIMEOFDAY"","- " ""A4PAPER"" )" $! $! $! Compile the stuff. $ Write sys$output "Go have a cup of coffee, this will take a while..." $! $ compile/defi='defs' ALIGN $ compile/defi='defs' ANIMATE $ compile/defi='defs' ARC $ compile/defi='defs' ATTR $ compile/defi='defs' AUXTEXT $ compile/defi='defs' BOX $ compile/defi='defs' BUTTON $ compile/defi='defs' CHOICE $ compile/defi='defs' CHOOSE $ compile/defi='defs' CMD $ compile/defi='defs' COLOR $ compile/defi='defs' CUTPASTE $ compile/defi='defs' CURSOR $ compile/defi='defs' DIALOG $ compile/defi='defs' DRAWING $ compile/defi='defs' DUP $ compile/defi='defs' EDIT $ compile/defi='defs' EPS $ compile/defi='defs' EXEC $ compile/defi='defs' EXPR $ compile/defi='defs' FILE $ compile/defi='defs' FONT $ compile/defi='defs' FTP $ compile/defi='defs' GRID $ compile/defi='defs' GROUP $ compile/defi='defs' HELP $ compile/defi='defs' HTTP $ compile/defi='defs' IMGPROC $ compile/defi='defs' IMPORT $ compile/defi='defs' MAINLOOP $ compile/defi='defs' MAINMENU $ compile/defi='defs' MARK $ compile/defi='defs' MENU $ compile/defi='defs' MOVE $ compile/defi='defs' MSG $ compile/defi='defs' NAMES $ compile/defi='defs' NAVIGATE $ compile/defi='defs' OBJ $ compile/defi='defs' OVAL $ compile/defi='defs' PAGE $ compile/defi='defs' PATTERN $ compile/defi='defs' POLY $ compile/defi='defs' POLYGON $ compile/defi='defs' PS $ compile/defi='defs' RASTER $ compile/defi='defs' RCBOX $ compile/defi='defs' RECT $ compile/defi='defs' REMOTE $ compile/defi='defs' RULER $ compile/defi='defs' SCROLL $ compile/defi='defs' SELECT $ compile/defi='defs' SETUP $ compile/defi='defs' SHAPE $ compile/defi='defs' SHORTCUT $ compile/defi='defs' SPECIAL $ compile/defi='defs' SPLINE $ compile/defi='defs' STK $ compile/defi='defs' STRETCH $ compile/defi='defs' TGIF_DBG $ compile/defi='defs' TCP $ compile/defi='defs' TEXT $ compile/defi='defs' TGIF $ compile/defi='defs' UTIL $ compile/defi='defs' VERSION $ compile/defi='defs' VMS_COMPAT $ compile/defi='defs' WB1 $ compile/defi='defs' WB2 $ compile/defi='defs' WB3 $ compile/defi='defs' XBITMAP $ compile/defi='defs' XPIXMAP $! $! $! $! $ delete/noconfirm tgif.olb; $ library/create tgif - ALIGN.o,ANIMATE.o,ARC.o,ATTR.o,AUXTEXT.o,BOX.o,BUTTON.o,CHOICE.o,- CHOOSE.o,CMD.o,COLOR.o,CUTPASTE.o,CURSOR.o,DIALOG.o,DRAWING.o,DUP.o,- EDIT.o,EPS.o,EXEC.o,EXPR.o,FILE.o,FONT.o,FTP.o,GRID.o,GROUP.o,HELP.o,HTTP.o,- IMGPROC.o,IMPORT.o,MAINLOOP.o,MAINMENU.o,MARK.o,MENU.o,MOVE.o,MSG.o,- NAMES.o,NAVIGATE.o,OBJ.o,OVAL.o,PAGE.o,PATTERN.o,POLY.o,POLYGON.o,- PS.o,RASTER.o,RCBOX.o,RECT.o,REMOTE.o,RULER.o,SCROLL.o,SELECT.o,- SETUP.o,SHAPE.o,SHORTCUT.o,SPECIAL.o,SPLINE.o,STK.o,STRETCH.o,TGIF_DBG.o,- TCP.o,TEXT.o,UTIL.o,VMS_COMP.o,WB1.o,WB2.o,WB3.o,- XBITMAP.o,XPIXMAP.o $! $ delete/noconfirm - ALIGN.o;,ANIMATE.o;,ARC.o;,ATTR.o;,AUXTEXT.o;,BOX.o;,BUTTON.o;,CHOICE.o;,- CHOOSE.o;,CMD.o;,COLOR.o;,CUTPASTE.o;,CURSOR.o;,DIALOG.o;,DRAWING.o;,DUP.o;,- EDIT.o;,EPS.o;,EXEC.o;,EXPR.o;,FILE.o;,FONT.o;,FTP.o;,GRID.o;,GROUP.o;,- HELP.o;,HTTP.o;,IMGPROC.o;,IMPORT.o;,MAINLOOP.o;,MAINMENU.o;,MARK.o;,- MENU.o;,MOVE.o;,MSG.o;,NAMES.o;,NAVIGATE.o;,OBJ.o;,OVAL.o;,PAGE.o;,- PATTERN.o;,POLY.o;,POLYGON.o;,PS.o;,RASTER.o;,RCBOX.o;,RECT.o;,REMOTE.o;,- RULER.o;,SCROLL.o;,SELECT.o;,SETUP.o;,SHAPE.o;,SHORTCUT.o;,SPECIAL.o;,- SPLINE.o;,STK.o;,STRETCH.o;,TGIF_DBG.o;,TCP.o;,TEXT.o;,UTIL.o;,VMS_COMP.o;,- WB1.o;,WB2.o;,WB3.o;,XBITMAP.o;,XPIXMAP.o; $! $! Link the stuff. NOTE "version.o" MUST be linked explicitly!!! $! $huuj: $ link tgif.o,version.o,tgif/lib,sys$input/opt sys$share:decw$xlibshr/share sys$share:vaxcrtl/share $! ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/convkinput.c�������������������������������������������������������������������������0000644�0000764�0000764�00000034633�11602233311�015340� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Yoichiro Ueno (ueno@cs.titech.ac.jp) * * Copyright (C) 1991, 1992, Yoichiro Ueno. * * Permission to use, copy, modify, and distribute this software and * its documentation for any purpose is hereby granted by the Author without * fee, provided that the above copyright notice appear in all copies and * that both the copyright notice and this permission notice appear in * supporting documentation, and that the name of the Author not be used * in advertising or publicity pertaining to distribution of the software * without specific, written prior permission. The Author makes no * representations about the suitability of this software for any purpose. * It is provided "as is" without express or implied warranty. * * THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO * EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR * OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR * PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/convkinput.c,v 1.2 2009/09/28 22:39:48 william Exp $ */ #ifndef _NO_KINPUT #define _INCLUDE_FROM_CONVKINPUT_C_ #include "tgifdefs.h" #include "choice.e" #include "convkinput.e" #include "dialog.e" #include "msg.e" #include "strtbl.e" #include "text.e" /* from kinput2/include/ConvProto.h */ #define CONV_ATTR(code,len) ((unsigned long)((code)<<16)+(len)) #define CONVATTR_INDIRECT 1 #define CONVATTR_SPOT_LOCATION 3 #define CONVATTR_INPUT_STYLE 128 #define CONVARG_OVERTHESPOT 4L #define CONV_OFF 0 #define WAIT_CONV_ON 1 #define CONV_ON 2 #define WAIT_CONV_OFF 3 #define KANJI0 0 #define KANJI1 1 #define KANJI2 2 #define KANJI3 3 #define KANJI4 4 #define KANJI5 5 #define LATIN 0 #define ESC 1 #define ESC_24 2 #define ESC_28 3 #define ESC_GL 4 #define ESC_GR 5 #define KANJI_GL 6 #define KANJI_GR 7 /* do not translate -- program constants */ #define KINPUT2_SELECTION "_JAPANESE_CONVERSION" #define KINPUT_SELECTION "JAPANESE_CONVERSION" #define TARGET "COMPOUND_TEXT" #define CONV_REQUEST "CONVERSION_REQUEST" #define CONV_NOTIFY "CONVERSION_NOTIFY" #define CONV_END "CONVERSION_END" #define CONV_END_REQ "CONVERSION_END_REQUEST" static int conv_mode = CONV_OFF; static Atom conv_selection = None; static Window conv_owner_win = None; static Atom conv_target = None; static Atom conv_property = None; static Atom conv_req = None; static Atom conv_notify = None; static Atom conv_end = None; static Atom conv_end_req = None; static Atom conv_attr = None; static Atom conv_attr_notify = None; static Window conv_win = None; int imProtocol = IM_NONE; int copyAndPasteJIS = FALSE; char kinputConvSelName[MAXSTRING] = KINPUT2_SELECTION; static int kinputConvOverSpot = 0; void KinputSetConvOverSpot(nConvOverSpot) int nConvOverSpot; { kinputConvOverSpot = nConvOverSpot; } /* for over-the-spot: from convlib.c in kinput2/client */ void KinputTellCursorPosition(dpy, win, x, y) Display *dpy; Window win; int x, y; { Window owner_win; char msg[80]; char * str1; XClientMessageEvent xcme; unsigned long data[4]; int len = 0; if(imProtocol != IM_KINPUT) return; if (conv_attr == None || conv_attr_notify == None) return; #if 0 switch(conv_mode) { case WAIT_CONV_ON : Msg(TgLoadString(STID_WAIT_FOR_START_CONV)); return; case WAIT_CONV_OFF : case CONV_OFF : return; } #endif if((owner_win = XGetSelectionOwner(dpy, conv_selection)) == None) { str1 = XGetAtomName(dpy, conv_selection); sprintf(msg, TgLoadString(STID_NO_NAMED_SELECTION_OWNER), str1); Msg(msg); XFree(str1); conv_owner_win = None; conv_mode = CONV_OFF; return; } if(conv_owner_win != owner_win) return; data[len++] = CONV_ATTR(CONVATTR_SPOT_LOCATION, 1); data[len++] = (x << 16) | (y & 0xffff); data[len++] = CONV_ATTR(CONVATTR_INPUT_STYLE, 1); data[len++] = CONVARG_OVERTHESPOT; XChangeProperty(dpy, win, conv_attr, conv_attr, 32, PropModeReplace, (unsigned char *)data, len); xcme.type = ClientMessage; xcme.display = dpy; xcme.window = owner_win; xcme.message_type = conv_attr_notify; xcme.format = 32; xcme.data.l[0] = conv_selection; xcme.data.l[1] = win; xcme.data.l[2] = CONV_ATTR(CONVATTR_INDIRECT, 1); xcme.data.l[3] = conv_attr; if (XSendEvent(dpy, owner_win, False, NoEventMask, (XEvent *)&xcme) == 0) { MsgBox(TgLoadString(STID_FAIL_TO_CHANGE_CONV_PROP), TOOL_NAME, INFO_MB); return; } } static Atom InternAtom(dpy, name) Display *dpy; char * name; { Atom ret; char msg[80]; if((ret = XInternAtom(dpy, name, False)) == None) { sprintf(msg, TgLoadString(STID_FAIL_TO_INTERN_NAMED_ATOM), name); MsgBox(msg, TOOL_NAME, INFO_MB); } return ret; } void KinputBeginConversion (dpy, win) Display *dpy; Window win; { XClientMessageEvent xcme; Window owner_win; char msg[80]; char * str1; int curX, curY; if(imProtocol != IM_KINPUT) return; #ifdef DEBUG /* debug, do not translate */ fprintf(stderr, "KinputBeginConversion() : %d\n", conv_mode); #endif if(curChoice != DRAWTEXT || !textCursorShown) return; if(conv_selection == None && (conv_selection = InternAtom(dpy, kinputConvSelName)) == None) return; if(conv_target == None && (conv_target = InternAtom(dpy, TARGET)) == None) return; #if 1 /* which better? */ if(conv_mode == CONV_OFF) #else if(conv_mode != CONV_ON) #endif conv_property = None; if(conv_req == None && (conv_req = InternAtom(dpy, CONV_REQUEST)) == None) return; if(conv_notify == None && (conv_notify = InternAtom(dpy, CONV_NOTIFY)) == None) return; if(conv_end == None && (conv_end = InternAtom(dpy, CONV_END)) == None) return; if(conv_end_req == None && (conv_end_req = InternAtom(dpy, CONV_END_REQ)) == None) return; if (kinputConvOverSpot) { if(conv_attr == None && (conv_attr = InternAtom(dpy, "CONVERSION_ATTRIBUTE")) == None) return; if(conv_attr_notify == None && (conv_attr_notify = InternAtom(dpy, "CONVERSION_ATTRIBUTE_NOTIFY")) == None) return; } if((owner_win = XGetSelectionOwner(dpy, conv_selection)) == None) { str1 = XGetAtomName(dpy, conv_selection); sprintf(msg, TgLoadString(STID_NO_NAMED_SELECTION_OWNER), str1); MsgBox(msg, TOOL_NAME, INFO_MB); XFree(str1); conv_owner_win = None; conv_mode = CONV_OFF; #ifdef DEBUG /* debug, do not translate */ fprintf(stderr, "0x%08x\n", owner_win); #endif return; } #ifdef DEBUG /* debug, do not translate */ fprintf(stderr, "0x%08x\n", owner_win); #endif switch(conv_mode) { case WAIT_CONV_ON : Msg(TgLoadString(STID_WAIT_FOR_START_CONV)); return; case CONV_ON : if (conv_owner_win == owner_win) return; break; } xcme.type = ClientMessage; xcme.display = dpy; xcme.window = owner_win; xcme.message_type = conv_req; xcme.format = 32; xcme.data.l[0] = conv_selection; xcme.data.l[1] = win; xcme.data.l[2] = conv_target; xcme.data.l[3] = conv_property; xcme.data.l[4] = conv_attr; if(XSendEvent(dpy, owner_win, False, NoEventMask, (XEvent *)&xcme) == 0) { MsgBox(TgLoadString(STID_FAIL_TO_CONNECT_TO_OWNER), TOOL_NAME, INFO_MB); return; } conv_owner_win = owner_win; conv_mode = WAIT_CONV_ON; TellTextCursorPosition(&curX, &curY); KinputTellCursorPosition(dpy, win, curX, curY); } void KinputCheckClientMessage (dpy, win, xclient) Display *dpy; Window win; XClientMessageEvent * xclient; { if(imProtocol != IM_KINPUT) return; if(xclient->message_type == conv_notify) { #ifdef DEBUG /* debug, do not translate */ fprintf(stderr, "KinputCheckClientMessage() : conv_notify : %d\n", conv_mode); #endif if( conv_mode != WAIT_CONV_ON || xclient->window != win || xclient->format != 32 || xclient->data.l[0] != conv_selection) { return; } if( xclient->data.l[2] == None || xclient->data.l[1] != conv_target) { conv_mode = CONV_OFF; return; } conv_mode = CONV_ON; conv_property = xclient->data.l[2]; conv_win = xclient->data.l[3]; } else if(xclient->message_type == conv_end) { #ifdef DEBUG /* debug, do not translate */ fprintf(stderr, "KinputCheckClientMessage() : conv_end : %d\n", conv_mode); #endif if((conv_mode != WAIT_CONV_OFF && conv_mode != CONV_ON) || xclient->window != win || xclient->format != 32 || xclient->data.l[0] != conv_selection || (xclient->data.l[1] != conv_owner_win && xclient->data.l[1] != conv_win)) { return; } conv_mode = CONV_OFF; } } void CvtCompoundTextToEuc(dst, src) register char * dst; register char * src; { int status; status = LATIN; while(*src != '\0') { switch(status) { case LATIN : if(*src == '\033') status = ESC; else *dst++= *src; break; case ESC : if(*src == '$') status = ESC_24; else if(*src == '(') status = ESC_28; else { status = LATIN; *dst++= *src; } break; case ESC_28 : if(*src == 'B' || *src == 'J') /* noda */ status = LATIN; else { status = LATIN; *dst++= *src; } break; case ESC_24 : if(*src == '(') status = ESC_GL; else if(*src == ')') status = ESC_GR; else { status = LATIN; *dst++= *src; } break; case ESC_GL : if(*src == 'B' || *src == '@') status = KANJI_GL; else { status = LATIN; *dst++= *src; } break; case ESC_GR : if(*src == 'B' || *src == '@') status = KANJI_GR; else { status = LATIN; *dst++= *src; } break; case KANJI_GL : if(*src == '\033') status = ESC; else if((*src & 0xff) < ' ') *dst++= *src; else *dst++= (*src | 0x80); break; case KANJI_GR : if(*src == '\033') status = ESC; else *dst++= *src; break; default : status = LATIN; break; } src ++; } *dst = '\0'; } static char* CvtCompoundTextToEuc_N(src, items) char * src; int items; { char *dst; if ((dst = (char *)malloc(sizeof(*src) * (items + 1))) != NULL) { strncpy(dst, src, items); dst[items] = '\0'; CvtCompoundTextToEuc(dst, dst); return dst; } else { FailAllocMessage(); return NULL; } } char* KinputCheckConvProperty (dpy, win, xprop) Display *dpy; Window win; XPropertyEvent * xprop; { Atom act_target; int act_format; unsigned long nitems; unsigned long remain_bytes; unsigned char * data; char * stmp; if(imProtocol != IM_KINPUT) return NULL; if( xprop->window != win || xprop->atom != conv_property || xprop->state != PropertyNewValue || conv_mode != CONV_ON) { return NULL; } if(XGetWindowProperty(dpy, win, conv_property, 0, MAXSTRING/sizeof(long), True, conv_target, &act_target, &act_format, &nitems, &remain_bytes, &data) != Success) { MsgBox(TgLoadString(STID_FAIL_TO_GET_WIN_PROP), TOOL_NAME, INFO_MB); return NULL; } if (remain_bytes > 0) XDeleteProperty(dpy, win, conv_property); if(act_target == None || conv_target != act_target) return NULL; if(act_format != 8) { XFree(data); return NULL; } stmp = CvtCompoundTextToEuc_N((char*)data, nitems); XFree(data); return stmp; } void KinputEndConversion (dpy, win) Display *dpy; Window win; { Window owner_win; char msg[80]; char * str1; XClientMessageEvent xcme; if(imProtocol != IM_KINPUT) return; #ifdef DEBUG /* debug, do not translate */ fprintf(stderr, "KinputEndConversion() : %d\n", conv_mode); #endif switch(conv_mode) { case WAIT_CONV_ON : Msg(TgLoadString(STID_WAIT_FOR_START_CONV)); return; case WAIT_CONV_OFF : case CONV_OFF : return; } if((owner_win = XGetSelectionOwner(dpy, conv_selection)) == None) { str1 = XGetAtomName(dpy, conv_selection); sprintf(msg, TgLoadString(STID_NO_NAMED_SELECTION_OWNER), str1); MsgBox(msg, TOOL_NAME, INFO_MB); XFree(str1); conv_owner_win = None; conv_mode = CONV_OFF; #ifdef DEBUG /* debug, do not translate */ fprintf(stderr, "0x%08x\n", owner_win); #endif return; } #ifdef DEBUG /* debug, do not translate */ fprintf(stderr, "0x%08x\n", owner_win); #endif if(conv_owner_win != owner_win) { conv_mode = CONV_OFF; return; } xcme.type = ClientMessage; xcme.display = dpy; xcme.window = owner_win; xcme.message_type = conv_end_req; xcme.format = 32; xcme.data.l[0] = conv_selection; xcme.data.l[1] = win; if(XSendEvent(dpy, owner_win, False, NoEventMask, (XEvent *)&xcme) == 0) { MsgBox(TgLoadString(STID_FAIL_TO_DISCONNECT_FROM_OWNER), TOOL_NAME, INFO_MB); conv_mode = CONV_OFF; return; } conv_mode = WAIT_CONV_OFF; } void CvtJisToEuc(dst, src) register char * dst; register char * src; { register int kanjiMode; register int len; kanjiMode = KANJI0; len = 0; while(*src != '\0') { switch(kanjiMode) { case KANJI0 : if(*src == '\033') kanjiMode = KANJI1; else *dst ++ = *src; break; case KANJI1 : if(*src == '$') kanjiMode = KANJI2; else kanjiMode = KANJI0; break; case KANJI2 : if(*src == '@' || *src == 'B') { len = 0; kanjiMode = KANJI3; } else kanjiMode = KANJI0; break; case KANJI3 : if(*src == '\033') kanjiMode = KANJI4; else { len ++; if(*(src + 1) != '\033' || (len & 1) == 0) *dst ++ = (*src | 0x80); } break; case KANJI4 : if(*src == '(') kanjiMode = KANJI5; else { len = 0; kanjiMode = KANJI3; } break; case KANJI5 : if(*src == 'J' || *src == 'B') kanjiMode = KANJI0; else { len = 0; kanjiMode = KANJI3; } break; default : break; } src ++; } *dst = '\0'; } int CvtEucToJis(dst, src) register char *dst; register char *src; { int status; int len; status = LATIN; len = 0; while(*src != '\0') { switch(status) { case LATIN : while((*src & 0x80) == 0 && *src != '\0') { if(dst) *dst ++ = *src; src ++; len ++; } status = KANJI_GR; break; case KANJI_GR : if(dst) { *dst ++ = '\033'; *dst ++ = '$'; *dst ++ = 'B'; } len += 3; while((*src & 0x80) == 0x80 && *src != '\0') { if(dst) *dst ++ = *src & 0x7f; src ++; len ++; } if(dst) { *dst ++ = '\033'; *dst ++ = '('; *dst ++ = 'B'; } len += 3; status = LATIN; break; default : break; } } if(dst) *dst = '\0'; return len; } #endif /* ~_NO_KINPUT */ �����������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/choose.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000225373�11602233311�014423� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/choose.c,v 1.11 2011/05/16 16:21:56 william Exp $ */ #define _INCLUDE_FROM_CHOOSE_C_ #include "tgifdefs.h" #include "auxtext.e" #include "button.e" #include "choose.e" #include "cutpaste.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "file.e" #include "font.e" #include "mainloop.e" #include "mainmenu.e" #include "menu.e" #include "msg.e" #include "names.e" #include "raster.e" #include "rect.e" #include "remote.e" #include "ruler.e" #include "scroll.e" #include "setup.e" #include "strtbl.e" #include "util.e" GC nameGC=(GC)0, revNameGC=(GC)0; typedef struct NamesRec { Window base_win, dsp_base_win, dsp_win, scroll_win; int base_win_w, base_win_h; int dsp_base_win_w, dsp_base_win_h; int dsp_area_w, dsp_area_h, scroll_area_h; char **entries; int num_entries; int first_index; int marked_index; int num_btns; struct BBRec btn_bbox[MAXBUTTONS], path_bbox; char btn_str[MAXBUTTONS][40]; int btn_id[MAXBUTTONS]; char inbuf[512]; int buf_index, just_clicked, scroll_dir; DspList *dsp_ptr; char *title_str, *formatted_title_str; struct CheckArrayRec *p_check_array; int title_w, title_h, title_num_lines; int a_btn_w, graph_w, btn_start, title_start, graph_start; int btn_w, btn_gap, btn_selected, exposed, screen_w, screen_h; int edit_style, loop_once, dont_free_entries, leading; int change_to_root, pop_from_root, faking_dot_dot; int tabbed_from_root, just_tabbed_from_root; int def_btn_id, double_click_btn_id; GetEntriesFunc *pf_before_loop; AfterLoopFunc *pf_after_loop; CheckUpdateFunc *pf_check_update; /* called when a checkbox changes state */ /* used only when edit_style== NAMES_SELECT_FILE */ char dir_name[MAXPATHLENGTH+1], saved_dir_name[MAXPATHLENGTH+1]; char name[MAXPATHLENGTH+1], saved_name[MAXPATHLENGTH+1]; int name_index, remote_file; void *userdata; } *NamesRecPtr; static struct NamesRec namesInfo; static XComposeStatus c_stat; int GetWorkingDirectory(buf, buf_sz) char *buf; int buf_sz; { char *psz_result=NULL; #ifdef VMS psz_result = getcwd(buf, buf_sz, 0); #else /* ~VMS */ #ifdef ibm psz_result = getwd(buf, buf_sz); #else /* ~ibm */ #ifdef NeXT psz_result = getwd(buf, buf_sz); #else /* ~NeXT */ #ifdef luna88k psz_result = getwd(buf); #else /* ~luna88k */ #ifdef sequent psz_result = getwd(buf); #else /* ~sequent */ psz_result = getcwd(buf, buf_sz); #endif /* sequent */ #endif /* luna88k */ #endif /* NeXT */ #endif /* ibm */ #endif /* VMS */ if (psz_result == NULL) { UtilStrCpyN(buf, buf_sz, "."); return FALSE; } return TRUE; } int SetWorkingDirectory(dir) char *dir; { return (chdir(dir) == 0); } static void CalcBaseWinWidth(pni) struct NamesRec *pni; { int max_w=max(pni->graph_w,pni->btn_w); pni->base_win_w = max_w + (defaultFontWidth<<2); pni->graph_start = ((pni->base_win_w-pni->graph_w)>>1); if (pni->title_num_lines <= 1) { pni->title_start = ((pni->base_win_w-pni->title_w)>>1); } else { pni->title_start = pni->graph_start; } pni->btn_start = ((pni->base_win_w-pni->btn_w)>>1); pni->path_bbox.ltx = pni->graph_start; pni->path_bbox.lty = (ROW_HEIGHT<<1)+pni->title_h; /* the path_bbox needs 2 pixels around it */ pni->path_bbox.lty -= 2; pni->path_bbox.rbx = pni->path_bbox.ltx + ITEM_LEN*defaultFontWidth+6; pni->path_bbox.rby = pni->path_bbox.lty + ((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontHeight : msgFontHeight)+1+4; if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { pni->base_win_h = (7+ITEM_DSPED)*ROW_HEIGHT + pni->title_h; } else { pni->base_win_h = (6+ITEM_DSPED)*ROW_HEIGHT + boldMsgFontHeight + 1 + pni->title_h; } } void CleanUpCheckArray(pCheckArray) /* Does not free pCheckArray */ struct CheckArrayRec *pCheckArray; { int i, num_cols=pCheckArray->num_cols; if (pCheckArray->col_name != NULL) { /* there's an extra one column here! */ for (i=0; i <= num_cols; i++) { if (pCheckArray->col_name[i] != NULL) { UtilFree(pCheckArray->col_name[i]); } } free(pCheckArray->col_name); } if (pCheckArray->value != NULL) { for (i=0; i < num_cols; i++) { if (pCheckArray->value[i] != NULL) { free(pCheckArray->value[i]); } } free(pCheckArray->value); } memset(pCheckArray, 0, sizeof(struct CheckArrayRec)); } int CopyCheckArray(pCheckArrayTo, pCheckArrayFrom) struct CheckArrayRec *pCheckArrayTo, *pCheckArrayFrom; { int i; int num_cols=pCheckArrayFrom->num_cols, num_rows=pCheckArrayFrom->num_rows; memset(pCheckArrayTo, 0, sizeof(struct CheckArrayRec)); pCheckArrayTo->num_cols = num_cols; pCheckArrayTo->num_rows = num_rows; if (pCheckArrayFrom->col_name != NULL) { /* there's an extra one column here! */ pCheckArrayTo->col_name = (char**)malloc((num_cols+1)*sizeof(char*)); if (pCheckArrayTo->col_name == NULL) FailAllocMessage(); memset(pCheckArrayTo->col_name, 0, (num_cols+1)*sizeof(char*)); for (i=0; i <= num_cols; i++) { if (pCheckArrayFrom->col_name[i] != NULL) { pCheckArrayTo->col_name[i] = UtilStrDup(pCheckArrayFrom->col_name[i]); if (pCheckArrayTo->col_name[i] == NULL) FailAllocMessage(); } } } if (pCheckArrayFrom->value != NULL) { pCheckArrayTo->value = (int**)malloc(num_cols*sizeof(int*)); if (pCheckArrayTo->value == NULL) FailAllocMessage(); memset(pCheckArrayTo->value, 0, num_cols*sizeof(int*)); for (i=0; i < num_cols; i++) { if (pCheckArrayFrom->value[i] != NULL) { pCheckArrayTo->value[i] = (int*)malloc(num_rows*sizeof(int)); if (pCheckArrayTo->value[i] == NULL) FailAllocMessage(); memcpy(pCheckArrayTo->value[i], pCheckArrayFrom->value[i], num_rows*sizeof(int)); } } } return TRUE; } void NamesSetTitle(title_str) char *title_str; { struct NamesRec *pni=(&namesInfo); if (pni->title_str != NULL) free(pni->title_str); if (pni->formatted_title_str != NULL) free(pni->formatted_title_str); pni->formatted_title_str = NULL; pni->title_str = UtilStrDup(title_str); if (pni->title_str == NULL) FailAllocMessage(); if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { CalcFormatStringInBox(pni->title_str, defaultFontPtr, defaultFontHeight, pni->graph_w, &pni->title_num_lines, &pni->title_w, &pni->title_h, &pni->formatted_title_str); } else { CalcFormatStringInBox(pni->title_str, boldMsgFontPtr, boldMsgFontHeight, pni->graph_w, &pni->title_num_lines, &pni->title_w, &pni->title_h, &pni->formatted_title_str); } CalcBaseWinWidth(pni); } void ResetNamesInfo() { struct NamesRec *pni=(&namesInfo); if (pni->title_str != NULL) { free(pni->title_str); pni->title_str = NULL; } if (pni->formatted_title_str != NULL) { free(pni->formatted_title_str); pni->formatted_title_str = NULL; } if (!pni->dont_free_entries) { if (pni->dsp_ptr != NULL) { free(pni->dsp_ptr); pni->dsp_ptr = NULL; } if (pni->entries != NULL) { free(*(pni->entries)); free(pni->entries); pni->entries = NULL; } } memset(&namesInfo, 0, sizeof(struct NamesRec)); pni->num_entries = INVALID; pni->first_index = INVALID; pni->marked_index = INVALID; /* do not translate -- the string is used to measure things */ pni->a_btn_w = ButtonWidth("OK", 8, NULL); pni->btn_gap = defaultFontWidth; pni->screen_w = DisplayWidth(mainDisplay, mainScreen); pni->screen_h = DisplayHeight(mainDisplay, mainScreen); pni->dsp_area_w = ITEM_LEN * defaultFontWidth; pni->dsp_area_h = ITEM_DSPED * ROW_HEIGHT; pni->scroll_area_h = pni->dsp_area_h; pni->dsp_base_win_w = pni->dsp_area_w + scrollBarW + (windowPadding<<1) + (brdrW<<2); pni->dsp_base_win_h = pni->dsp_area_h + (windowPadding<<1) + (brdrW<<1); pni->graph_w = pni->dsp_area_w + scrollBarW + (brdrW<<2); NamesSetTitle(""); if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { pni->base_win_h = (8+ITEM_DSPED)*ROW_HEIGHT; } else { pni->base_win_h = (6+ITEM_DSPED)*ROW_HEIGHT + 2*(boldMsgFontHeight+1); } pni->def_btn_id = BUTTON_OK; pni->double_click_btn_id = BUTTON_OK; pni->tabbed_from_root = TRUE; } void InitNamesInfo() { XGCValues values; memset(&namesInfo, 0, sizeof(struct NamesRec)); values.foreground = myFgPixel; values.background = (threeDLook ? myLtGryPixel : myBgPixel); values.fill_style = FillSolid; if (msgFontPtr == NULL) { values.font = defaultFontPtr->fid; } else { values.font = msgFontPtr->fid; } nameGC = XCreateGC(mainDisplay, rootWindow, GCForeground | GCBackground | GCFillStyle | GCFont, &values); values.foreground = myBgPixel; values.background = myFgPixel; revNameGC = XCreateGC(mainDisplay, rootWindow, GCForeground | GCBackground | GCFillStyle | GCFont, &values); } void CleanUpNamesInfo() { struct NamesRec *pni=(&namesInfo); ResetNamesInfo(); if (pni->title_str != NULL) free(pni->title_str); pni->title_str = NULL; if (pni->formatted_title_str != NULL) free(pni->formatted_title_str); pni->formatted_title_str = NULL; XFreeGC(mainDisplay, nameGC); XFreeGC(mainDisplay, revNameGC); nameGC = revNameGC = (GC)0; } void NamesAddButton(btn_str, btn_id) char *btn_str; int btn_id; { struct NamesRec *pni=(&namesInfo); pni->btn_id[pni->num_btns] = btn_id; strcpy(pni->btn_str[pni->num_btns], btn_str); pni->btn_w += ButtonWidth(btn_str, 8, NULL); if (pni->num_btns != 0) { pni->btn_w += pni->btn_gap; } pni->num_btns++; if (pni->num_btns > MAXBUTTONS) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "Too many buttons detected in NamesAddButton().", NULL); #endif /* _TGIF_DBG */ } CalcBaseWinWidth(pni); } static void RedrawNameScrollWin() { struct NamesRec *pni=(&namesInfo); double frac, start_frac; int block_h, block_start; start_frac = (pni->num_entries > 0) ? (double)((double)(pni->first_index) / (double)(pni->num_entries)) : ((double)0.0); /* starting pixel */ block_start = (int)(pni->scroll_area_h * start_frac); if (pni->num_entries > ITEM_DSPED) { frac = (double)((double)ITEM_DSPED / (double)(pni->num_entries)); } else { frac = 1.0; } if (pni->first_index+ITEM_DSPED >= pni->num_entries) { block_h = pni->scroll_area_h - block_start; } else { block_h = (int)(pni->scroll_area_h * frac); } TgDrawScrollBar(mainDisplay, pni->scroll_win, VERT_SCROLLBAR, 0, 0, scrollBarW, pni->scroll_area_h, start_frac, ITEM_DSPED, pni->num_entries); } #include "xbm/check.xbm" void DrawCheckbox(dpy, win, gc, x, y, w, h, checked) Display *dpy; Window win; GC gc; int x, y, w, h, checked; { if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, x, y, x+w+1, y+h+1); TgDrawThreeDButton(dpy, win, textMenuGC, &bbox, TGBS_LOWRED, 2, FALSE); } else { XDrawRectangle(dpy, win, gc, x, y, w, h); } if (checked) { if (threeDLook) { XGCValues values; values.fill_style = FillStippled; values.stipple = checkBitmap; values.ts_x_origin = x+2; values.ts_y_origin = y+2; XChangeGC(dpy, gc, GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(dpy, win, gc, values.ts_x_origin, values.ts_y_origin, check_width, check_height); values.fill_style = FillSolid; values.ts_x_origin = 0; values.ts_y_origin = 0; XChangeGC(dpy, gc, GCFillStyle | GCTileStipXOrigin | GCTileStipYOrigin, &values); } else { XDrawLine(dpy, win, gc, x, y, x+w, y+h); XDrawLine(dpy, win, gc, x, y+h, x+w, y); } } if (check_bits == NULL) { } } static void RedrawItem(pni, index) struct NamesRec *pni; int index; { int len=0, top=0, end=0, checkbox_cols=0, text_left=0, box_offset=0, box_w=0; int selected=(index==pni->marked_index); if ((msgFontSet==NULL && msgFontPtr==NULL)) { top = defaultFontAsc+1; } else { top = msgFontAsc+1; } if (pni->first_index+ITEM_DSPED > pni->num_entries) { end = pni->num_entries; } else { end = pni->first_index + ITEM_DSPED; } if (pni->p_check_array != NULL && pni->p_check_array->num_cols > 0) { checkbox_cols = pni->p_check_array->num_cols; text_left = checkbox_cols*ROW_HEIGHT; box_offset = 1; box_w = (ROW_HEIGHT-((box_offset+1)<<1)); } len = strlen(pni->entries[index]); XFillRectangle(mainDisplay, pni->dsp_win, (selected ? nameGC : revNameGC), 0, (index-pni->first_index)*ROW_HEIGHT, ITEM_LEN*defaultFontWidth, ROW_HEIGHT); DrawMsgString(mainDisplay, pni->dsp_win, (selected ? revNameGC : nameGC), text_left, (index-pni->first_index)*ROW_HEIGHT+top, pni->entries[index], len); if (checkbox_cols > 0) { int col=0, cur_x=0; for (col=0; col < pni->p_check_array->num_cols; col++) { DrawCheckbox(mainDisplay, pni->dsp_win, (selected ? revNameGC : nameGC), cur_x+box_offset, (index-pni->first_index)*ROW_HEIGHT+top-box_w, box_w, box_w, pni->p_check_array->value[col][index]); cur_x += ROW_HEIGHT; } } } static void RedrawDspWindow() { struct NamesRec *pni=(&namesInfo); int i, end=0; if (pni->first_index+ITEM_DSPED > pni->num_entries) { end = pni->num_entries; } else { end = pni->first_index + ITEM_DSPED; } XFillRectangle(mainDisplay, pni->dsp_win, revNameGC, 0, 0, ITEM_LEN*defaultFontWidth, ITEM_DSPED*ROW_HEIGHT); for (i=pni->first_index; i < end; i++) { RedrawItem(pni, i); } } static void RedrawDspBaseWindow() { if (threeDLook) { struct NamesRec *pni=(&namesInfo); struct BBRec bbox; SetBBRec(&bbox, 0, 0, pni->dsp_base_win_w, pni->dsp_base_win_h); TgDrawThreeDButton(mainDisplay, pni->dsp_base_win, textMenuGC, &bbox, TGBS_LOWRED, 2, FALSE); } } static void RedrawNamePath() { struct NamesRec *pni=(&namesInfo); int len=strlen(pni->inbuf), cursor_x=0, cursor_y, box_w, box_h, x, y; char *c_ptr; struct BBRec bbox; if (msgFontPtr == NULL) { XSetFont(mainDisplay, nameGC, defaultFontPtr->fid); } else { XSetFont(mainDisplay, nameGC, msgFontPtr->fid); } x = pni->graph_start; /* the path_bbox has 2 pixels around it */ y = pni->path_bbox.lty+2; box_w = ITEM_LEN*defaultFontWidth+6+(windowPadding<<1); cursor_y = y; if ((msgFontSet==NULL && msgFontPtr==NULL)) { y += defaultFontAsc; } else { y += msgFontAsc; } box_h = (ROW_HEIGHT+3); if (threeDLook) { XSetForeground(mainDisplay, textMenuGC, myBgPixel); XFillRectangle(mainDisplay, pni->base_win, textMenuGC, x, cursor_y-2, box_w+(windowPadding<<1), box_h+(windowPadding<<1)); SetBBRec(&bbox, x, cursor_y-2, x+box_w+(windowPadding<<1), cursor_y-2+box_h+(windowPadding<<1)); TgDrawThreeDButton(mainDisplay, pni->base_win, textMenuGC, &bbox, TGBS_LOWRED, 2, FALSE); } else { XClearArea(mainDisplay, pni->base_win, x, cursor_y-2, box_w+1, box_h, False); XDrawRectangle(mainDisplay, pni->base_win, nameGC, x, cursor_y-2, box_w+1, box_h); } if ((msgFontSet==NULL && msgFontPtr==NULL)) { if (len > ITEM_LEN) { c_ptr = &(pni->inbuf[len-ITEM_LEN]); len = ITEM_LEN; } else { c_ptr = pni->inbuf; } cursor_x = x+2+len*defaultFontWidth; } else { int index=0; cursor_x = MsgTextWidth(msgFontPtr, pni->inbuf, len); while (cursor_x > box_w-4) { index++; cursor_x = MsgTextWidth(msgFontPtr, &pni->inbuf[index], len-index); } c_ptr = &pni->inbuf[index]; len -= index; cursor_x += x+2+1; } DrawMsgString(mainDisplay, pni->base_win, nameGC, x+2+windowPadding, y+1+windowPadding, c_ptr, len); XDrawLine(mainDisplay, pni->base_win, nameGC, cursor_x+windowPadding, cursor_y+1+windowPadding, cursor_x+windowPadding, cursor_y+box_h-5+windowPadding); } static void RedrawNameBaseWindow() { struct NamesRec *pni=(&namesInfo); int i, left, base_line; /* draw a frame around the window */ if (threeDLook) { if (dialogboxUse3DBorder) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, pni->base_win_w, pni->base_win_h); TgDrawThreeDButton(mainDisplay, pni->base_win, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); } } else { XDrawRectangle(mainDisplay, pni->base_win, nameGC, 0, 0, pni->base_win_w-1, pni->base_win_h-1); } if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { base_line = defaultFontAsc+ROW_HEIGHT; XSetFont(mainDisplay, nameGC, defaultFontPtr->fid); } else { base_line = boldMsgFontAsc+ROW_HEIGHT; if (boldMsgFontPtr != NULL) { XSetFont(mainDisplay, nameGC, boldMsgFontPtr->fid); } } /* draw the title */ if (pni->tabbed_from_root) { if (pni->title_num_lines <= 1) { DrawBoldMsgString(mainDisplay, pni->base_win, nameGC, pni->title_start, base_line, pni->title_str, strlen(pni->title_str)); } else { char *psz_line=pni->formatted_title_str; char *psz=strchr(pni->formatted_title_str, '\n'); do { if (psz != NULL) *psz = '\0'; DrawBoldMsgString(mainDisplay, pni->base_win, nameGC, pni->title_start, base_line, psz_line, strlen(psz_line)); base_line += ((boldMsgFontSet==NULL && boldMsgFontPtr==NULL) ? defaultFontHeight : boldMsgFontHeight); if (psz != NULL) { *psz++ = '\n'; psz_line = psz; psz = strchr(psz_line, '\n'); } else { break; } } while (psz_line != NULL); } } else { int tmp_w, len, tmp_start; strcpy(gszMsgBox, TgLoadString(STID_TAB_FOR_FILE_COMPLETION)); len = strlen(gszMsgBox); if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { tmp_w = defaultFontWidth * len; } else { tmp_w = BoldMsgTextWidth(boldMsgFontPtr, gszMsgBox, len); } tmp_start = ((pni->base_win_w-tmp_w)>>1); DrawBoldMsgString(mainDisplay, pni->base_win, nameGC, tmp_start, base_line, gszMsgBox, len); if (pni->title_str != NULL && *pni->title_str != '\0') { SetStringStatus(pni->title_str); } } if (boldMsgFontSet != NULL || boldMsgFontPtr != NULL) { if (msgFontPtr == NULL) { XSetFont(mainDisplay, nameGC, defaultFontPtr->fid); } else { XSetFont(mainDisplay, nameGC, msgFontPtr->fid); } } RedrawNamePath(); /* draw the buttons */ left = pni->btn_start; for (i=0; i < pni->num_btns; i++) { int len=strlen(pni->btn_str[i]); int button_w=ButtonWidth(pni->btn_str[i], 8, NULL), button_h=0; if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { button_h = defaultFontHeight + 4; } else { button_h = boldMsgFontHeight + 4; } pni->btn_bbox[i].ltx = left; pni->btn_bbox[i].lty = (5+ITEM_DSPED)*ROW_HEIGHT + pni->title_h; pni->btn_bbox[i].lty -= 1; pni->btn_bbox[i].rbx = pni->btn_bbox[i].ltx+button_w; pni->btn_bbox[i].rby = pni->btn_bbox[i].lty+button_h; DisplayButtonInBBox(pni->base_win, pni->btn_str[i], len, &(pni->btn_bbox[i]), BUTTON_NORMAL, FALSE, 0, NULL); left = pni->btn_bbox[i].rbx + 1 + defaultFontWidth; } } static void RedrawNamesWindow() { RedrawNameBaseWindow(); RedrawNameScrollWin(); RedrawDspWindow(); RedrawDspBaseWindow(); } static int ExposeOrMapNames(input) XEvent *input; { struct NamesRec *pni=(&namesInfo); XEvent ev; if ((input->type==MapNotify && input->xany.window==pni->base_win) || (input->type==Expose && (input->xany.window==pni->base_win || input->xany.window==pni->scroll_win || input->xany.window==pni->dsp_win)) || (!pni->exposed && (XCheckWindowEvent(mainDisplay, pni->base_win, ExposureMask, &ev) || XCheckWindowEvent(mainDisplay, pni->scroll_win, ExposureMask, &ev) || XCheckWindowEvent(mainDisplay, pni->dsp_win, ExposureMask, &ev) || XCheckWindowEvent(mainDisplay, pni->base_win, StructureNotifyMask, &ev)))) { while (XCheckWindowEvent(mainDisplay, pni->base_win, ExposureMask, &ev)) ; while (XCheckWindowEvent(mainDisplay, pni->scroll_win, ExposureMask, &ev)) ; while (XCheckWindowEvent(mainDisplay, pni->dsp_win, ExposureMask, &ev)) ; while (XCheckWindowEvent(mainDisplay, pni->base_win, StructureNotifyMask, &ev)) ; RedrawNamesWindow(); pni->exposed = TRUE; XSync(mainDisplay, False); if ((input->type==MapNotify && input->xany.window==pni->base_win) || (input->type==Expose && (input->xany.window==pni->base_win || input->xany.window==pni->scroll_win || input->xany.window==pni->dsp_win))) { return TRUE; } } return FALSE; } static int CreateNamesWindows(win_name) char *win_name; { struct NamesRec *pni=(&namesInfo); int y, base_win_x, base_win_y; int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); XWMHints wmhints; XSizeHints sizehints; XSetWindowAttributes win_attrs; base_win_x = (pni->base_win_w > pni->screen_w) ? 0 : ((pni->screen_w-pni->base_win_w)>>1); base_win_y = (pni->base_win_h > pni->screen_h) ? 0 : ((pni->screen_h-pni->base_win_h)/3); if ((pni->base_win=XCreateSimpleWindow(mainDisplay, rootWindow, base_win_x, base_win_y, pni->base_win_w, pni->base_win_h, brdrW, myBorderPixel, bg_pixel)) == 0) { return FailToCreateWindowMessage("CreateNamesWindows()", NULL, FALSE); } XDefineCursor(mainDisplay, pni->base_win, defaultCursor); y = (ROW_HEIGHT<<2)+pni->title_h; if ((pni->dsp_base_win=XCreateSimpleWindow(mainDisplay, pni->base_win, pni->graph_start, y, pni->dsp_base_win_w, pni->dsp_base_win_h, 0, myBorderPixel, bg_pixel)) == 0) { XDestroyWindow(mainDisplay, pni->base_win); return FailToCreateWindowMessage("CreateNamesWindows()", NULL, FALSE); } if ((pni->dsp_win=XCreateSimpleWindow(mainDisplay, pni->dsp_base_win, windowPadding, windowPadding, pni->dsp_area_w, pni->dsp_area_h, brdrW, myBorderPixel, bg_pixel)) == 0) { XDestroyWindow(mainDisplay, pni->base_win); return FailToCreateWindowMessage("CreateNamesWindows()", NULL, FALSE); } if ((pni->scroll_win=XCreateSimpleWindow(mainDisplay, pni->dsp_base_win, windowPadding+pni->dsp_area_w+(brdrW<<1), windowPadding, scrollBarW, pni->dsp_area_h, brdrW, myBorderPixel, bg_pixel)) == 0) { XDestroyWindow(mainDisplay, pni->base_win); return FailToCreateWindowMessage("CreateNamesWindows()", NULL, FALSE); } win_attrs.save_under = True; win_attrs.colormap = mainColormap; XChangeWindowAttributes(mainDisplay, pni->base_win, CWSaveUnder | CWColormap, &win_attrs); wmhints.flags = InputHint | StateHint; wmhints.input = True; wmhints.initial_state = NormalState; XSetWMHints(mainDisplay, pni->base_win, &wmhints); sizehints.flags = PPosition | PSize | USPosition | PMinSize | PMaxSize; sizehints.x = base_win_x; sizehints.y = base_win_y; sizehints.width = sizehints.min_width = sizehints.max_width = pni->base_win_w; sizehints.height = sizehints.min_height = sizehints.max_height = pni->base_win_h; #ifdef NOTR4MODE XSetNormalHints(mainDisplay, pni->base_win, &sizehints); #else XSetWMNormalHints(mainDisplay, pni->base_win, &sizehints); #endif RegisterWM_DELETE_WINDOW(pni->base_win); XStoreName(mainDisplay, pni->base_win, win_name); XSetTransientForHint(mainDisplay, pni->base_win, mainWindow); #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, pni->base_win); XSelectInput(mainDisplay, pni->base_win, KeyPressMask | ButtonPressMask | ExposureMask | StructureNotifyMask); XMapWindow(mainDisplay, pni->dsp_base_win); XSelectInput(mainDisplay, pni->dsp_base_win, ExposureMask); XMapWindow(mainDisplay, pni->dsp_win); XSelectInput(mainDisplay, pni->dsp_win, KeyPressMask | ButtonPressMask | ExposureMask); XMapWindow(mainDisplay, pni->scroll_win); XSelectInput(mainDisplay, pni->scroll_win, KeyPressMask | ButtonPressMask | ExposureMask); #else XSelectInput(mainDisplay, pni->base_win, KeyPressMask | ButtonPressMask | ExposureMask | StructureNotifyMask); XMapWindow(mainDisplay, pni->base_win); XSelectInput(mainDisplay, pni->dsp_base_win, ExposureMask); XMapWindow(mainDisplay, pni->dsp_base_win); XSelectInput(mainDisplay, pni->dsp_win, KeyPressMask | ButtonPressMask | ExposureMask); XMapWindow(mainDisplay, pni->dsp_win); XSelectInput(mainDisplay, pni->scroll_win, KeyPressMask | ButtonPressMask | ExposureMask); XMapWindow(mainDisplay, pni->scroll_win); #endif if (warpToWinCenter) { XWarpPointer(mainDisplay, None, pni->base_win, 0, 0, 0, 0, (pni->base_win_w>>1), (pni->base_win_h>>1)); } XSync(mainDisplay, False); Msg(""); return TRUE; } static void NamesUpdateIndices() { struct NamesRec *pni=(&namesInfo); pni->first_index = 0; if (pni->marked_index == INVALID) { if (pni->edit_style != NAMES_SELECT_FILE) { *pni->inbuf = '\0'; pni->buf_index = 0; } } else { if (pni->marked_index >= ITEM_DSPED) { if (pni->marked_index < pni->num_entries-ITEM_DSPED) { pni->first_index = pni->marked_index; } else { pni->first_index = pni->num_entries-ITEM_DSPED; } } if (pni->edit_style != NAMES_SELECT_FILE) { strcpy(pni->inbuf, &(pni->entries[pni->marked_index])[pni->leading]); pni->buf_index = strlen(pni->inbuf);; } } } static int IsFirstEqChar(s, index) char *s; int index; { s = (&s[index]); if (*s != '=') return FALSE; for (--index, --s; index >= 0; index--, s--) { if (*s == '=') { return FALSE; } } return TRUE; } static int SetMarkedIndex() { struct NamesRec *pni=(&namesInfo); int i; if (*pni->name == '\0') return FALSE; for (i=0; i < pni->num_entries; i++) { if (strncmp(&(pni->entries[i])[pni->leading], pni->name, pni->name_index) == 0) { break; } } if (i < pni->num_entries) { if (i < pni->first_index) { pni->first_index = i; } else if (i >= pni->first_index+ITEM_DSPED) { if (i < pni->num_entries-ITEM_DSPED) { pni->first_index = i; } else { pni->first_index = pni->num_entries-ITEM_DSPED; } } pni->marked_index = i; return TRUE; } else { return FALSE; } } static void BackSpaceInNames(pn_changing, pn_selected_btn_index) int *pn_changing, *pn_selected_btn_index; { struct NamesRec *pni=(&namesInfo); int i; switch (pni->edit_style) { case NAMES_SIMPLE_SELECT_NAME: return; case NAMES_COMPLEX_SELECT_NAME: if (pni->marked_index == INVALID || pni->buf_index <= 0) return; pni->inbuf[--pni->buf_index] = '\0'; if (pni->buf_index != 0) { int i; for (i=0; i < pni->num_entries; i++) { if (strncmp(&(pni->entries[i])[pni->leading], pni->inbuf, pni->buf_index) == 0) { break; } } if (i < pni->num_entries) { if (i < pni->first_index) { pni->first_index = i; } else if (i >= pni->first_index+ITEM_DSPED) { if (i < pni->num_entries-ITEM_DSPED) { pni->first_index = i; } else { pni->first_index = pni->num_entries-ITEM_DSPED; } } pni->marked_index = i; } } else { pni->first_index = 0; pni->marked_index = INVALID; } break; case NAMES_SELECT_FILE: if (pni->name_index > 0) { pni->name[--pni->name_index] = '\0'; sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); if (pni->tabbed_from_root && pni->name_index != 0) { for (i=0; i < pni->num_entries; i++) { if (strncmp(&(pni->entries[i])[pni->leading], pni->name, pni->name_index) == 0) { pni->marked_index = i; break; } } } else { pni->marked_index = INVALID; } } else if (pni->change_to_root && *pni->dir_name == '\0' && *pni->saved_dir_name != '\0') { pni->pop_from_root = TRUE; strcpy(pni->dir_name, pni->saved_dir_name); *pni->saved_dir_name = '\0'; pni->tabbed_from_root = TRUE; pni->change_to_root = FALSE; sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); *pn_changing = FALSE; *pn_selected_btn_index = INVALID; } else { /* fake as if "../" is selected */ sprintf(pni->name, "..%c", DIR_SEP); pni->name_index = strlen(pni->name); for (i=0; i < pni->num_entries; i++) { if (strncmp(&(pni->entries[i])[pni->leading], pni->name, pni->name_index) == 0) { pni->marked_index = i; pni->faking_dot_dot = TRUE; *pn_changing = FALSE; *pn_selected_btn_index = i; break; } } } break; case NAMES_EDIT_ATTR: if (pni->marked_index == INVALID || pni->buf_index <= 0) return; if (pni->dsp_ptr == NULL || !pni->dsp_ptr[pni->marked_index].directory || !IsFirstEqChar(pni->inbuf, pni->buf_index-1)) { pni->inbuf[--pni->buf_index] = '\0'; strcpy(&(pni->entries[pni->marked_index])[pni->leading], pni->inbuf); } break; case NAMES_EDIT_NAME: if (pni->marked_index == INVALID || pni->buf_index <= 0) return; pni->inbuf[--pni->buf_index] = '\0'; strcpy(&(pni->entries[pni->marked_index])[pni->leading], pni->inbuf); break; default: break; } if (pni->exposed) { RedrawNamePath(); RedrawDspWindow(); } } static void ParseFileName(FullName, DirName, Name) char *FullName, *DirName, *Name; { int i, len; len = strlen(FullName); strcpy(DirName, FullName); for (i=len-1; i>=0; i--) { if (DirName[i] == DIR_SEP) { strcpy(Name, &(DirName[i+1])); DirName[i] = '\0'; return; } } *DirName = *Name = '\0'; } static void TabInNames() { struct NamesRec *pni=(&namesInfo); if (pni->edit_style == NAMES_SELECT_FILE) { pni->tabbed_from_root = TRUE; pni->just_tabbed_from_root = TRUE; if (!FileIsRemote(pni->name)) { /* saved_name is used for just_tabbed_from_root */ sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); strcpy(pni->saved_name, pni->name); ParseFileName(pni->inbuf, pni->dir_name, pni->name); } else { pni->remote_file = TRUE; } } } static void CharInNames(buf, pn_changing, pn_selected_btn_index) char *buf; int *pn_changing, *pn_selected_btn_index; { struct NamesRec *pni=(&namesInfo); int i=INVALID; switch (pni->edit_style) { case NAMES_SIMPLE_SELECT_NAME: if (buf[0] == ' ' && buf[1] == '\0' && pni->p_check_array != NULL && pni->p_check_array->num_cols == 1) { i = pni->marked_index; pni->p_check_array->value[0][i] = !(pni->p_check_array->value[0][i]); RedrawItem(pni, i); } return; case NAMES_COMPLEX_SELECT_NAME: if (buf[0] == '$') { i = pni->num_entries-1; strcpy(pni->inbuf, &(pni->entries[i])[pni->leading]); } else if (buf[0] == '^') { i = 0; strcpy(pni->inbuf, &(pni->entries[i])[pni->leading]); } else { pni->inbuf[pni->buf_index++] = buf[0]; pni->inbuf[pni->buf_index] = '\0'; for (i=0; i < pni->num_entries; i++) { if (strncmp(&(pni->entries[i])[pni->leading], pni->inbuf, pni->buf_index) == 0) { break; } } } if (i < pni->num_entries) { if (i < pni->first_index) { pni->first_index = i; } else if (i >= pni->first_index+ITEM_DSPED) { if (i < pni->num_entries-ITEM_DSPED) { pni->first_index = i; } else { pni->first_index = pni->num_entries-ITEM_DSPED; } } pni->marked_index = i; } else { pni->inbuf[--pni->buf_index] = '\0'; } break; case NAMES_SELECT_FILE: if (!pni->tabbed_from_root) { pni->name[pni->name_index++] = buf[0]; pni->name[pni->name_index] = '\0'; sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); } else if (buf[0] == '$') { i = pni->num_entries-1; strcpy(pni->name, &(pni->entries[i])[pni->leading]); pni->name_index = strlen(pni->name); } else if (buf[0] == '^') { i = 0; strcpy(pni->name, &(pni->entries[i])[pni->leading]); pni->name_index = strlen(pni->name); #ifdef apollo } else if (pni->name_index == 0 && buf[0] == DIR_SEP && *pni->dir_name == '\0') { strcpy(pni->dir_name, DIR_SEP_STR); pni->name[pni->name_index++] = buf[0]; i = pni->num_entries; strcpy(pni->inbuf, "//"); #endif /* apollo */ } else if (pni->name_index == 0 && buf[0] == DIR_SEP) { if (*pni->saved_dir_name == '\0') { strcpy(pni->saved_dir_name, pni->dir_name); pni->num_entries = 0; } *pn_changing = FALSE; pni->change_to_root = TRUE; pni->tabbed_from_root = FALSE; *pn_selected_btn_index = INVALID; *pni->dir_name = *pni->name = '\0'; pni->name_index = 0; sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); break; } else { pni->name[pni->name_index++] = buf[0]; pni->name[pni->name_index] = '\0'; for (i=0; i < pni->num_entries; i++) { if (strncmp(&(pni->entries[i])[pni->leading], pni->name, pni->name_index) == 0) { break; } } } if (pni->num_entries > 0) { if (i < pni->num_entries) { if (i < pni->first_index) { pni->first_index = i; } else if (i >= pni->first_index+ITEM_DSPED) { if (i < pni->num_entries-ITEM_DSPED) { pni->first_index = i; } else { pni->first_index = pni->num_entries-ITEM_DSPED; } } pni->marked_index = i; sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); if (buf[0] == DIR_SEP) { *pn_changing = FALSE; *pn_selected_btn_index = INVALID; } } else { pni->name[--pni->name_index] = '\0'; } } break; case NAMES_EDIT_ATTR: if (pni->marked_index == INVALID) return; pni->inbuf[pni->buf_index++] = buf[0]; pni->inbuf[pni->buf_index] = '\0'; strcpy(&(pni->entries[pni->marked_index])[pni->leading], pni->inbuf); break; case NAMES_EDIT_NAME: if (pni->marked_index == INVALID) return; pni->inbuf[pni->buf_index++] = buf[0]; pni->inbuf[pni->buf_index] = '\0'; strcpy(&(pni->entries[pni->marked_index])[pni->leading], pni->inbuf); break; default: break; } if (pni->exposed) { RedrawNamePath(); RedrawDspWindow(); } } static int GetNameEntryNum(RowOffset) int RowOffset; { struct NamesRec *pni=(&namesInfo); int index; index = pni->first_index + RowOffset; if (index >= pni->num_entries) return INVALID; return index; } static int ScrollItemCallback(pv_userdata) void *pv_userdata; /* returns TRUE to cancel scrolling */ { struct NamesRec *pni=((struct NamesRec *)pv_userdata); if (pni->scroll_dir == SCRL_UP) { if (pni->first_index == 0) return FALSE; pni->first_index--; } else { if (pni->num_entries <= ITEM_DSPED || pni->first_index+ITEM_DSPED == pni->num_entries) { return FALSE; } pni->first_index++; } RedrawNameScrollWin(); RedrawDspWindow(); XSync(mainDisplay, False); return FALSE; } static int ScrollPageCallback(pv_userdata) void *pv_userdata; /* returns TRUE to cancel scrolling */ { struct NamesRec *pni=((struct NamesRec *)pv_userdata); if (pni->scroll_dir == SCRL_UP) { if (pni->first_index == 0) return FALSE; pni->first_index -= ITEM_DSPED; if (pni->first_index < 0) pni->first_index = 0; } else { if (pni->num_entries <= ITEM_DSPED || pni->first_index+ITEM_DSPED == pni->num_entries) { return FALSE; } pni->first_index += ITEM_DSPED; if (pni->first_index+ITEM_DSPED >= pni->num_entries) { pni->first_index = pni->num_entries-ITEM_DSPED; } } RedrawNameScrollWin(); RedrawDspWindow(); XSync(mainDisplay, False); return FALSE; } static int DoNameBtnScroll(scroll_page, scroll_dir, pbbox, pni) int scroll_page, scroll_dir; struct BBRec *pbbox; struct NamesRec *pni; /* returns TRUE if done scrolling */ { ScrollBtnCallbackInfo sbci; pni->scroll_dir = scroll_dir; memset(&sbci, 0, sizeof(ScrollBtnCallbackInfo)); if (scroll_page) { sbci.ms = 200; sbci.pv_userdata = pni; sbci.pf_scroll_btn_callback = ScrollPageCallback; if (TgPressButtonLoop(mainDisplay, pni->scroll_win, NULL, &sbci)) { if (scroll_dir == SCRL_UP) { if (pni->first_index == 0) return TRUE; pni->first_index -= ITEM_DSPED; if (pni->first_index < 0) pni->first_index = 0; } else { if (pni->num_entries <= ITEM_DSPED || pni->first_index+ITEM_DSPED == pni->num_entries) { return TRUE; } pni->first_index += ITEM_DSPED; if (pni->first_index+ITEM_DSPED >= pni->num_entries) { pni->first_index = pni->num_entries-ITEM_DSPED; } } } } else { sbci.ms = 50; sbci.pv_userdata = pni; sbci.pf_scroll_btn_callback = ScrollItemCallback; if (TgPressButtonLoop(mainDisplay, pni->scroll_win, pbbox, &sbci)) { if (scroll_dir == SCRL_UP) { if (pni->first_index == 0) return TRUE; pni->first_index--; } else { if (pni->num_entries <= ITEM_DSPED || pni->first_index+ITEM_DSPED == pni->num_entries) { return TRUE; } pni->first_index++; } } } return FALSE; } static void NameScrollHandler(button_ev) XButtonEvent *button_ev; { struct NamesRec *pni=(&namesInfo); double frac, start_frac; int block_h, block_start, do_drag=FALSE, btn_offset=0; if (!threeDLook && button_ev->button == Button3 && button_ev->type == ButtonPress) { if (DoNameBtnScroll(((button_ev->state & (ShiftMask|ControlMask)) != 0), SCRL_UP, NULL, pni)) { return; } } else if (!threeDLook && button_ev->button == Button1 && button_ev->type == ButtonPress) { if (DoNameBtnScroll(((button_ev->state & (ShiftMask|ControlMask)) != 0), SCRL_DN, NULL, pni)) { return; } } else if (button_ev->button == Button1 && button_ev->type == ButtonPress) { if (button_ev->y < scrollBarW || button_ev->y >= pni->scroll_area_h-scrollBarW) { int which=INVALID; struct BBRec bbox; if (button_ev->y < scrollBarW) { which = SCRL_UP; SetBBRec(&bbox, 0, 0, scrollBarW, scrollBarW); } else { which = SCRL_DN; SetBBRec(&bbox, 0, pni->scroll_area_h-scrollBarW, scrollBarW, pni->scroll_area_h); } if (DoNameBtnScroll(FALSE, which, &bbox, pni)) { return; } } else { int hit=0; start_frac = (pni->num_entries > 0) ? (double)((double)(pni->first_index) / (double)(pni->num_entries)) : ((double)0.0); hit = TgGetScrollHit(button_ev->x, button_ev->y, VERT_SCROLLBAR, scrollBarW, pni->scroll_area_h, start_frac, ITEM_DSPED, pni->num_entries, &btn_offset); if (hit == 0) { do_drag = TRUE; } else { if (DoNameBtnScroll(TRUE, (hit < 0 ? SCRL_UP : SCRL_DN), NULL, pni)) { return; } } } } else if (!threeDLook && button_ev->button == Button2 && button_ev->type == ButtonPress) { do_drag = TRUE; } if (do_drag) { int done=FALSE; XEvent ev; if (pni->num_entries <= ITEM_DSPED) return; frac = (double)((double)ITEM_DSPED / (double)(pni->num_entries)); block_h = (int)(pni->scroll_area_h * frac); if (threeDLook) { block_start = button_ev->y+btn_offset;; start_frac = (double)((double)(block_start-scrollBarW) / (double)(pni->scroll_area_h-(scrollBarW<<1))); if (block_start+block_h >= pni->scroll_area_h-scrollBarW) { pni->first_index = pni->num_entries - ITEM_DSPED; } else { pni->first_index = (int)(pni->num_entries * start_frac); } } else { block_start = button_ev->y; start_frac = (double)((double)(block_start) / (double)(pni->scroll_area_h)); if (block_start+block_h >= pni->scroll_area_h) { pni->first_index = pni->num_entries - ITEM_DSPED; } else { pni->first_index = (int)(pni->num_entries * start_frac); } } RedrawNameScrollWin(); RedrawDspWindow(); XGrabPointer(mainDisplay, pni->scroll_win, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); while (!done) { XNextEvent(mainDisplay, &ev); if (ev.type == Expose || ev.type == VisibilityNotify) { ExposeEventHandler(&ev, TRUE); } else if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); if (debugNoPointerGrab) XSync(mainDisplay, False); done = TRUE; } else if (ev.type == MotionNotify) { int new_name_first=0, y=ev.xmotion.y; if (threeDLook) { y += btn_offset; start_frac = (double)(((double)(y-scrollBarW)) / ((double)(pni->scroll_area_h-(scrollBarW<<1)))); if (y <= scrollBarW) { new_name_first = 0; } else if (y+block_h >= pni->scroll_area_h-scrollBarW) { new_name_first = pni->num_entries - ITEM_DSPED; } else { new_name_first = (int)(pni->num_entries * start_frac); } } else { start_frac = (double)(((double)y) / ((double)pni->scroll_area_h)); if (y <= 0) { new_name_first = 0; } else if (y+block_h >= pni->scroll_area_h) { new_name_first = pni->num_entries - ITEM_DSPED; } else { new_name_first = (int)(pni->num_entries * start_frac); } } if (pni->first_index != new_name_first) { pni->first_index = new_name_first; RedrawNameScrollWin(); RedrawDspWindow(); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } return; } RedrawNameScrollWin(); RedrawDspWindow(); } static int NameDspHandler(button_ev) XButtonEvent *button_ev; { struct NamesRec *pni=(&namesInfo); static Time last_click_time; static int last_name_marked; Time click_time; int checkbox_cols=0, box_offset=0, clicked_col=INVALID, check_updated=FALSE; if (enableMouseWheel && (button_ev->button == Button4 || button_ev->button == Button5)) { int which=INVALID; struct BBRec bbox; if (button_ev->button == Button4) { which = SCRL_UP; SetBBRec(&bbox, 0, 0, scrollBarW, scrollBarW); } else if (button_ev->button == Button5) { which = SCRL_DN; SetBBRec(&bbox, 0, pni->scroll_area_h-scrollBarW, scrollBarW, pni->scroll_area_h); } if (which != INVALID) { DoNameBtnScroll(FALSE, which, &bbox, pni); RedrawNameScrollWin(); RedrawDspWindow(); } return INVALID; } else if (button_ev->button != Button1) { return INVALID; } if (pni->p_check_array != NULL && pni->p_check_array->num_cols > 0) { checkbox_cols = pni->p_check_array->num_cols; box_offset = 1; if (button_ev->x < checkbox_cols*ROW_HEIGHT) { clicked_col = (int)(button_ev->x / ROW_HEIGHT); } } if (pni->marked_index != INVALID && pni->marked_index >= pni->first_index && pni->marked_index < pni->first_index+ITEM_DSPED) { int saved_index=pni->marked_index; pni->marked_index = INVALID; RedrawItem(pni, saved_index); pni->marked_index = saved_index; } pni->marked_index = GetNameEntryNum((int)(button_ev->y / ROW_HEIGHT)); if (pni->marked_index != INVALID) { if (clicked_col != INVALID) { int i=pni->marked_index; pni->p_check_array->value[clicked_col][i] = !(pni->p_check_array->value[clicked_col][i]); if (pni->pf_check_update != NULL) { /* * check_udpated set to TRUE if the callback function calls * SetStringStatus() */ check_updated = (pni->pf_check_update)(&pni->dsp_ptr, &pni->entries, &pni->num_entries, &pni->marked_index, &pni->p_check_array, pni->inbuf, clicked_col, i, pni->userdata); } } RedrawItem(pni, pni->marked_index); } click_time = button_ev->time; if (pni->just_clicked && pni->marked_index != INVALID && last_name_marked == pni->marked_index && (click_time-last_click_time) < doubleClickInterval) { return TRUE; } pni->just_clicked = TRUE; last_click_time = click_time; last_name_marked = pni->marked_index; if (!check_updated) { if (pni->dsp_ptr != NULL && pni->marked_index != INVALID) { SetStringStatus(pni->dsp_ptr[pni->marked_index].pathstr); } else { SetStringStatus(""); } } return INVALID; } static int ControlChar(key_ev, key_sym) XKeyEvent *key_ev; KeySym key_sym; { register int i; struct NamesRec *pni=(&namesInfo); if (key_ev->state & ControlMask) { switch (key_sym) { case XK_Left: return (BAD); case XK_KP_Left: return (BAD); case XK_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_KP_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_Right: return (BAD); case XK_KP_Right: return (BAD); case XK_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_KP_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_KP_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_KP_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; } } else { switch (key_sym) { case XK_Left: return BAD; case XK_KP_Left: return BAD; case XK_Up: key_sym = ((unsigned long)'k')&0xff; break; case XK_KP_Up: key_sym = ((unsigned long)'k')&0xff; break; case XK_Right: return BAD; case XK_KP_Right: return BAD; case XK_Down: key_sym = ((unsigned long)'j')&0xff; break; case XK_KP_Down: key_sym = ((unsigned long)'j')&0xff; break; case XK_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_KP_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_KP_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; } } switch (key_sym&0xff) { case 'w': /* erase */ case 'y': return INVALID; case 'n': /* down one */ case 'j': i = (pni->marked_index < pni->num_entries-1) ? pni->marked_index+1 : pni->num_entries-1; break; case 'p': /* up one */ case 'k': i = (pni->marked_index>0) ? pni->marked_index-1 : 0; break; case 'd': /* down one page */ case 'f': if (pni->marked_index==INVALID) { i = (pni->num_entries <= ITEM_DSPED) ? pni->num_entries-1 : ITEM_DSPED; } else if (pni->marked_index < pni->num_entries-ITEM_DSPED) { i = pni->marked_index+ITEM_DSPED; } else { i = pni->num_entries-1; } break; case 'u': /* up one page */ case 'b': i = (pni->marked_index > (ITEM_DSPED-1)) ? pni->marked_index-ITEM_DSPED : 0; break; default: return BAD; } return i; } static void BackUpOneWord(pn_changing, pn_selected_btn_index) int *pn_changing, *pn_selected_btn_index; { struct NamesRec *pni=(&namesInfo); int new_dir=FALSE; if (pni->buf_index == 0) return; if (pni->inbuf[pni->buf_index-1] == DIR_SEP) { pni->inbuf[--pni->buf_index] = '\0'; new_dir = TRUE; } else { while (pni->buf_index > 0) { if (pni->inbuf[(pni->buf_index)-1] == DIR_SEP) { pni->inbuf[pni->buf_index] = '\0'; break; } else { pni->buf_index--; } } pni->inbuf[pni->buf_index] = '\0'; } ParseFileName(pni->inbuf, pni->dir_name, pni->name); if (new_dir) { int i; sprintf(pni->name, "..%c", DIR_SEP); pni->name_index = strlen(pni->name); for (i=0; i < pni->num_entries; i++) { if (strncmp(&(pni->entries[i])[pni->leading], pni->name, pni->name_index) == 0) { pni->marked_index = i; pni->faking_dot_dot = TRUE; *pn_changing = FALSE; *pn_selected_btn_index = i; break; } } } else { pni->first_index = 0; pni->marked_index = INVALID; } } static void SpecialKeyInNames(key_ev, key_sym, pn_changing, pn_selected_btn_index) XKeyEvent *key_ev; KeySym key_sym; int *pn_changing, *pn_selected_btn_index; { struct NamesRec *pni=(&namesInfo); int i=ControlChar(key_ev, key_sym); if (i == BAD) return; if (i == INVALID) { if (pni->edit_style == NAMES_SELECT_FILE) { /* back-up one word */ BackUpOneWord(pn_changing, pn_selected_btn_index); sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); } else { *pni->inbuf = '\0'; pni->buf_index = 0; pni->first_index = 0; pni->marked_index = INVALID; } } else if (i < pni->num_entries) { if (pni->edit_style == NAMES_SELECT_FILE) { strcpy(pni->name, &(pni->entries[i])[pni->leading]); pni->name_index = strlen(pni->name); sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); } else { strcpy(pni->inbuf, &(pni->entries[i])[pni->leading]); pni->buf_index = strlen(pni->inbuf); } if (i < pni->first_index) { pni->first_index = i; } else if (i >= pni->first_index+ITEM_DSPED) { if (i < pni->num_entries-ITEM_DSPED) { pni->first_index = i; } else { pni->first_index = pni->num_entries-ITEM_DSPED; } } pni->marked_index = i; } if (pni->exposed) { RedrawNamePath(); RedrawNameScrollWin(); RedrawDspWindow(); RedrawDspBaseWindow(); } if (pni->dsp_ptr != NULL && pni->marked_index != INVALID) { SetStringStatus(pni->dsp_ptr[pni->marked_index].pathstr); } else { SetStringStatus(""); } } static int GetBtnIndexFromBtnId(btn_id) int btn_id; { struct NamesRec *pni=(&namesInfo); int i; for (i=0; i < pni->num_btns; i++) { if (pni->btn_id[i] == btn_id) { return i; } } #ifdef _TGIF_DBG /* debug, do not translate */ sprintf(gszMsgBox, "Programing error!\n\nCannot find a button with id=%1d.", btn_id); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); #endif /* _TGIF_DBG */ return INVALID; } static void KeyPressInNames(key_ev, pn_changing, pn_selected_btn_index) XKeyEvent *key_ev; int *pn_changing, *pn_selected_btn_index; { struct NamesRec *pni=(&namesInfo); char buf[80]; KeySym key_sym; int has_ch; has_ch = XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); TranslateKeys(buf, &key_sym); if ((key_ev->state & ControlMask) && key_sym == XK_j) { SpecialKeyInNames(key_ev, key_sym, pn_changing, pn_selected_btn_index); } else if (CharIsCRorLF(key_ev, buf, key_sym, &has_ch)) { if (pni->edit_style == NAMES_SELECT_FILE) { if (!pni->tabbed_from_root) { TabInNames(); } *pn_changing = FALSE; *pn_selected_btn_index = GetBtnIndexFromBtnId(pni->def_btn_id); } else { if (pni->def_btn_id != INVALID) { *pn_changing = FALSE; *pn_selected_btn_index = GetBtnIndexFromBtnId(pni->def_btn_id); } } } else if (CharIsESC(key_ev, buf, key_sym, &has_ch)) { *pn_changing = FALSE; *pn_selected_btn_index = GetBtnIndexFromBtnId(BUTTON_CANCEL); } else if (CharIsBSorDEL(key_ev, buf, key_sym, &has_ch, FALSE)) { if (pni->edit_style == NAMES_SELECT_FILE && (pni->faking_dot_dot || pni->pop_from_root)) { *pn_changing = FALSE; *pn_selected_btn_index = INVALID; } else { BackSpaceInNames(pn_changing, pn_selected_btn_index); } } else if (CharIsTAB(key_ev, buf, key_sym, &has_ch)) { if (pni->edit_style == NAMES_SELECT_FILE && pni->change_to_root) { TabInNames(); *pn_changing = FALSE; *pn_selected_btn_index = INVALID; } } else if ((!pni->tabbed_from_root || pni->num_entries != 0) && ((key_sym>'\040' && key_sym<='\177' && (key_ev->state & ControlMask)) || key_sym==XK_Up || key_sym==XK_Down || key_sym==XK_KP_Up || key_sym==XK_KP_Down || key_sym==XK_Page_Up || key_sym==XK_KP_Page_Up || key_sym==XK_Page_Down || key_sym==XK_KP_Page_Down)) { SpecialKeyInNames(key_ev, key_sym, pn_changing, pn_selected_btn_index); } else if (key_sym>='\040' && key_sym<='\177' && (!pni->tabbed_from_root || pni->num_entries != 0)) { CharInNames(buf, pn_changing, pn_selected_btn_index); } } static void ButtonPressInPath(button_ev) XButtonEvent *button_ev; { struct NamesRec *pni=(&namesInfo); if (button_ev->button == Button1) { } else if (button_ev->button == Button2) { int buf_len=0, from_selection=FALSE; char *cut_buffer=NULL; switch (pni->edit_style) { case NAMES_SIMPLE_SELECT_NAME: return; case NAMES_COMPLEX_SELECT_NAME: return; case NAMES_SELECT_FILE: if (pni->tabbed_from_root) return; break; case NAMES_EDIT_ATTR: break; case NAMES_EDIT_NAME: break; } cut_buffer = FetchSelectionOrCutBuffer(&buf_len, &from_selection); if (cut_buffer != NULL) { char *c_ptr=cut_buffer; int max_len; if (pni->edit_style == NAMES_SELECT_FILE) { max_len = sizeof(pni->inbuf)-strlen(pni->dir_name)-3; while (pni->name_index < max_len && *c_ptr >= '\040' && *c_ptr < '\177') { pni->name[pni->name_index++] = (*c_ptr++); } pni->name[pni->name_index] = '\0'; sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); } else { max_len = sizeof(pni->inbuf)-strlen(pni->inbuf)-3; while (pni->buf_index < max_len && *c_ptr >= '\040' && *c_ptr < '\177') { pni->inbuf[pni->buf_index++] = (*c_ptr++); } pni->inbuf[pni->buf_index] = '\0'; strcpy(&(pni->entries[pni->marked_index])[pni->leading], pni->inbuf); } if (pni->exposed) { RedrawNamePath(); RedrawDspWindow(); } FreeSelectionOrCutBuffer(cut_buffer, from_selection); } } else if (button_ev->button == Button3) { } } static void ButtonPressInNames(button_ev, pn_changing, pn_selected_btn_index) XButtonEvent *button_ev; int *pn_changing, *pn_selected_btn_index; { struct NamesRec *pni=(&namesInfo); if (button_ev->window == pni->base_win) { int i; if (PointInBBox(button_ev->x, button_ev->y, pni->path_bbox)) { ButtonPressInPath(button_ev); } else { for (i=0; i < pni->num_btns; i++) { if (PointInBBox(button_ev->x, button_ev->y, pni->btn_bbox[i])) { struct BBRec *bbox=(&(pni->btn_bbox[i])); char *btn_str=pni->btn_str[i]; int looping=TRUE, selected=TRUE, len=strlen(btn_str); XEvent ev; XGrabPointer(mainDisplay, pni->base_win, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); DisplayButtonInBBox(pni->base_win, btn_str, len, bbox, BUTTON_INVERT, FALSE, 0, NULL); while (looping) { XNextEvent(mainDisplay, &ev); if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); if (debugNoPointerGrab) XSync(mainDisplay, False); looping = FALSE; } else if (ev.type == MotionNotify) { if (PointInBBox(ev.xmotion.x, ev.xmotion.y, pni->btn_bbox[i])) { if (!selected) { selected = TRUE; DisplayButtonInBBox(pni->base_win, btn_str, len, bbox, BUTTON_INVERT, FALSE, 0, NULL); } } else { if (selected) { selected = FALSE; DisplayButtonInBBox(pni->base_win, btn_str, len, bbox, BUTTON_NORMAL, FALSE, 0, NULL); } } } } if (selected) { *pn_changing = FALSE; *pn_selected_btn_index = i; DisplayButtonInBBox(pni->base_win, btn_str, len, bbox, BUTTON_NORMAL, FALSE, 0, NULL); } break; } } } } else if (button_ev->window == pni->scroll_win) { NameScrollHandler(button_ev); } else if (button_ev->window == pni->dsp_win) { int double_clicked=(NameDspHandler(button_ev)!=INVALID); if (pni->marked_index != INVALID) { if (pni->edit_style == NAMES_SELECT_FILE) { strcpy(pni->name, &(pni->entries[pni->marked_index])[pni->leading]); pni->name_index = strlen(pni->name); sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); } else { strcpy(pni->inbuf, &(pni->entries[pni->marked_index])[pni->leading]); pni->buf_index = strlen(pni->inbuf); } RedrawNamePath(); if (double_clicked && pni->double_click_btn_id != INVALID) { *pn_changing = FALSE; *pn_selected_btn_index = GetBtnIndexFromBtnId(pni->double_click_btn_id); } } } } void NamesSetDefaultBtnId(def_btn_id, double_click_btn_id) int def_btn_id, double_click_btn_id; { struct NamesRec *pni=(&namesInfo); pni->def_btn_id = def_btn_id; pni->double_click_btn_id = double_click_btn_id; } void NamesSetStyle(edit_style, loop_once) int edit_style, loop_once; { struct NamesRec *pni=(&namesInfo); pni->edit_style = edit_style; pni->loop_once = loop_once; } void NamesSetEntries(dsp_ptr, entries, num_entries, p_check_array, dont_free_entries, marked_index, leading) DspList *dsp_ptr; char **entries; int num_entries, dont_free_entries, marked_index, leading; struct CheckArrayRec *p_check_array; { struct NamesRec *pni=(&namesInfo); pni->dsp_ptr = dsp_ptr; pni->entries = entries; pni->num_entries = num_entries; pni->p_check_array = p_check_array; pni->dont_free_entries = dont_free_entries; pni->marked_index = marked_index; pni->leading = leading; } void NamesSetCallback(pf_before_loop, pf_after_loop, pf_check_update) GetEntriesFunc *pf_before_loop; AfterLoopFunc *pf_after_loop; CheckUpdateFunc *pf_check_update; { struct NamesRec *pni=(&namesInfo); if (pni->dsp_ptr != NULL || pni->entries != NULL) { #ifdef _TGIF_DBG /* debug, do not translate */ sprintf(gszMsgBox, "%s.", "dsp_ptr != NULL || entries != NULL in NamesSetCallback()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); #endif /* _TGIF_DBG */ if (pni->dsp_ptr != NULL) free(pni->dsp_ptr); if (pni->entries != NULL) { free(*(pni->entries)); free(pni->entries); } } pni->dsp_ptr = NULL; pni->entries = NULL; pni->num_entries = 0; pni->pf_before_loop = pf_before_loop; pni->pf_after_loop = pf_after_loop; pni->pf_check_update = pf_check_update; } void NamesSetDir(dir_name) char *dir_name; { struct NamesRec *pni=(&namesInfo); if (pni->edit_style != NAMES_SELECT_FILE) { #ifdef _TGIF_DBG /* debug, do not translate */ sprintf(gszMsgBox, "%s!\n\nNamesSetDir() called with %s.", "Programing error", "pni->edit_style != NAMES_SELECT_FILE."); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); #endif /* _TGIF_DBG */ } UtilStrCpyN(pni->dir_name, sizeof(pni->dir_name), dir_name); } static void BeforeLoopForSelectFile() { struct NamesRec *pni=(&namesInfo); if (pni->faking_dot_dot) { *pni->name = '\0'; pni->name_index = 0; } else if (pni->tabbed_from_root && !pni->just_tabbed_from_root) { pni->name[0] = '\0'; pni->name_index = 0; } else if (pni->tabbed_from_root && pni->just_tabbed_from_root) { pni->name_index = strlen(pni->name); if (!SetMarkedIndex()) { pni->name[0] = '\0'; pni->name_index = 0; } } sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); if (pni->exposed) { XClearWindow(mainDisplay, pni->base_win); RedrawNameBaseWindow(); } pni->pop_from_root = FALSE; } static int GetParentRealDir(dir, buf, buf_sz) char *dir, *buf; int buf_sz; { int rc=FALSE; char saved_cur_dir[MAXPATHLENGTH]; if (!GetWorkingDirectory(saved_cur_dir, sizeof(saved_cur_dir))) { *saved_cur_dir = '\0'; } if (SetWorkingDirectory(dir) && SetWorkingDirectory("..")) { if (GetWorkingDirectory(buf, buf_sz)) { rc = TRUE; } } if (*saved_cur_dir != '\0') { SetWorkingDirectory(saved_cur_dir); } return rc; } static int BreakForSelectFileAfterLoop() { struct NamesRec *pni=(&namesInfo); if (pni->marked_index == INVALID && !pni->change_to_root && !pni->pop_from_root && !pni->just_tabbed_from_root) { return TRUE; } else if (FileIsRemote(pni->name)) { pni->remote_file = TRUE; return TRUE; } if (pni->inbuf[pni->buf_index-1] != DIR_SEP) { if (!pni->just_tabbed_from_root) { return TRUE; } } else { if (pni->name[0] == '.' && pni->name[1] == '.' && pni->name[2] == DIR_SEP) { /* need to find out what's the real directory */ char parent_dir[MAXPATHLENGTH]; if (GetParentRealDir(pni->dir_name, parent_dir, sizeof(parent_dir))) { int len=0; len = strlen(parent_dir); if (len > 0 && parent_dir[len-1] == DIR_SEP) { parent_dir[--len] = '\0'; } sprintf(pni->inbuf, "%s%c..", parent_dir, DIR_SEP); pni->buf_index = strlen(pni->inbuf); ParseFileName(pni->inbuf, pni->dir_name, pni->name); return FALSE; } } pni->inbuf[--(pni->buf_index)] = '\0'; if (pni->name[0] == '.' && pni->name[1] == '.' && pni->name[2] == DIR_SEP) { /* saved_name is used for faking_dot_dot */ int i; for (i=strlen(pni->dir_name)-1; i >= 0 && pni->dir_name[i] != DIR_SEP; i--) { } if (i < 0) { strcpy(pni->saved_name, pni->dir_name); *pni->dir_name = '\0'; } else { strcpy(pni->saved_name, &(pni->dir_name[i+1])); pni->dir_name[i] = '\0'; } } else { strcpy(&pni->inbuf[pni->buf_index++], DIR_SEP_STR); ParseFileName(pni->inbuf, pni->dir_name, pni->name); } } return FALSE; } int Names(win_name, pn_selected_index, selected_str, str_sz, p_void) char *win_name, *selected_str; int *pn_selected_index, str_sz; void *p_void; { struct NamesRec *pni=(&namesInfo); int i, looping=TRUE, selected_btn_index=INVALID, left=0; if (selected_str != NULL) *selected_str = '\0'; if (pn_selected_index != NULL) *pn_selected_index = INVALID; if (!CreateNamesWindows(win_name)) return INVALID; EndMeasureTooltip(FALSE); pni->userdata = p_void; if (pni->edit_style == NAMES_SELECT_FILE) { pni->faking_dot_dot = FALSE; pni->change_to_root = FALSE; pni->just_tabbed_from_root = FALSE; *pni->saved_dir_name = '\0'; } left = pni->btn_start; for (i=0; i < pni->num_btns; i++) { int button_w=ButtonWidth(pni->btn_str[i], 8, NULL), button_h=0; if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { pni->btn_bbox[i].lty = (6+ITEM_DSPED)*ROW_HEIGHT; button_h = defaultFontHeight + 4; } else { pni->btn_bbox[i].lty = (5+ITEM_DSPED)*ROW_HEIGHT + (boldMsgFontHeight+1); button_h = boldMsgFontHeight + 4; } pni->btn_bbox[i].ltx = left; pni->btn_bbox[i].lty -= 2; pni->btn_bbox[i].rbx = pni->btn_bbox[i].ltx+button_w; pni->btn_bbox[i].rby = pni->btn_bbox[i].lty+button_h; left = pni->btn_bbox[i].rbx + 1 + defaultFontWidth; } SaveStatusStrings(); while (looping) { int changing=TRUE; if (pni->edit_style == NAMES_SELECT_FILE) { BeforeLoopForSelectFile(); } if (pni->pf_before_loop != NULL) { int rc; char saved_ch='\0'; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SetWatchCursor(pni->base_win); if (pni->edit_style == NAMES_SELECT_FILE && !pni->tabbed_from_root && !pni->just_tabbed_from_root) { saved_ch = *pni->inbuf; *pni->inbuf = '\0'; } rc = (pni->pf_before_loop)(&pni->dsp_ptr, &pni->entries, &pni->num_entries, &pni->marked_index, &pni->p_check_array, pni->inbuf, p_void); if (pni->edit_style == NAMES_SELECT_FILE && !pni->tabbed_from_root && !pni->just_tabbed_from_root) { *pni->inbuf = saved_ch; } if (pni->edit_style == NAMES_SELECT_FILE && pni->just_tabbed_from_root) { /* saved_name is used for just_tabbed_from_root */ *pni->dir_name = '\0'; strcpy(pni->name, pni->saved_name); pni->name_index = strlen(pni->name); sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); *pni->saved_name = '\0'; ParseFileName(pni->inbuf, pni->dir_name, pni->name); pni->name_index = strlen(pni->name); if (!SetMarkedIndex()) { pni->name[0] = '\0'; pni->name_index = 0; } } if (pni->edit_style == NAMES_SELECT_FILE && pni->faking_dot_dot) { /* saved_name is used for faking_dot_dot */ strcpy(pni->name, pni->saved_name); pni->name_index = strlen(pni->name); sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); *pni->saved_name = '\0'; if (!SetMarkedIndex()) { pni->name[0] = '\0'; pni->name_index = 0; } } SetDefaultCursor(mainWindow); ShowCursor(); SetDrawCursor(pni->base_win); if (!rc) break; } if (pni->edit_style == NAMES_SELECT_FILE) { pni->just_tabbed_from_root = FALSE; pni->faking_dot_dot = FALSE; } NamesUpdateIndices(); if (pni->pf_before_loop != NULL && pni->exposed) { RedrawNamePath(); RedrawNameScrollWin(); RedrawDspWindow(); RedrawDspBaseWindow(); } if (pni->dsp_ptr != NULL && pni->marked_index != INVALID) { SetStringStatus(pni->dsp_ptr[pni->marked_index].pathstr); } XSync(mainDisplay, False); selected_btn_index = INVALID; while (changing) { XEvent input, ev; XNextEvent(mainDisplay, &input); if (ExposeOrMapNames(&input)) { continue; } if (input.type == Expose) { ExposeEventHandler(&input, FALSE); } else if (input.type==VisibilityNotify && input.xany.window==mainWindow && input.xvisibility.state==VisibilityUnobscured) { int i; while (XCheckWindowEvent(mainDisplay, mainWindow, VisibilityChangeMask, &ev)) ; if (pinnedMainMenu) XMapRaised(mainDisplay, mainMenuWindow); for (i=0; i < numExtraWins; i++) { if (extraWinInfo[i].mapped && extraWinInfo[i].raise && extraWinInfo[i].window != None) { XMapRaised(mainDisplay, extraWinInfo[i].window); } } XMapRaised(mainDisplay, pni->base_win); } else if (input.type == KeyPress) { KeyPressInNames(&input.xkey, &changing, &selected_btn_index); } else if (input.type == ButtonPress) { ButtonPressInNames(&input.xbutton, &changing, &selected_btn_index); } else if ((input.xany.window==pni->base_win || input.xany.window==pni->dsp_base_win || input.xany.window==pni->dsp_win || input.xany.window==pni->scroll_win) && IsWM_DELETE_WINDOW(&input)) { KeyPressInNames(&input.xkey, &changing, &selected_btn_index); changing = FALSE; selected_btn_index = INVALID; } } if (pni->exposed && selected_btn_index != INVALID) { DisplayButtonInBBox(pni->base_win, pni->btn_str[selected_btn_index], strlen(pni->btn_str[selected_btn_index]), &(pni->btn_bbox[selected_btn_index]), BUTTON_INVERT, FALSE, 0, NULL); XSync(mainDisplay, False); } if (pni->edit_style == NAMES_SELECT_FILE) { if (pni->marked_index != INVALID) { strcpy(pni->name, &(pni->entries[pni->marked_index])[pni->leading]); pni->name_index = strlen(pni->name); sprintf(pni->inbuf, "%s%c%s", pni->dir_name, DIR_SEP, pni->name); pni->buf_index = strlen(pni->inbuf); } } if (pni->pf_after_loop != NULL) { int btn_id=INVALID; if (selected_btn_index != INVALID) { btn_id = pni->btn_id[selected_btn_index]; } if (!(pni->pf_after_loop)(&pni->dsp_ptr, &pni->entries, &pni->num_entries, &pni->marked_index, &pni->p_check_array, pni->inbuf, btn_id, pni->marked_index, p_void)) { looping = FALSE; } } if (selected_btn_index != INVALID) { if (pni->btn_id[selected_btn_index] == BUTTON_CANCEL) { looping = FALSE; } } if (pni->edit_style == NAMES_SELECT_FILE) { if (BreakForSelectFileAfterLoop()) { looping = FALSE; } } if (pni->loop_once == NAMES_LOOP_ONCE) { looping = FALSE; } if (pni->exposed && selected_btn_index != INVALID) { DisplayButtonInBBox(pni->base_win, pni->btn_str[selected_btn_index], strlen(pni->btn_str[selected_btn_index]), &(pni->btn_bbox[selected_btn_index]), BUTTON_NORMAL, FALSE, 0, NULL); XSync(mainDisplay, False); } } RestoreStatusStrings(); XDestroyWindow(mainDisplay, pni->base_win); if (warpToWinCenter) { XWarpPointer(mainDisplay, None, drawWindow, 0, 0, 0, 0, (int)(ZOOMED_SIZE(drawWinW)>>1), (int)(ZOOMED_SIZE(drawWinH)>>1)); } if (selected_str != NULL) { if (pni->remote_file) { UtilStrCpyN(selected_str, str_sz, pni->name); } else { UtilStrCpyN(selected_str, str_sz, pni->inbuf); } } pni->userdata = NULL; if (pn_selected_index != NULL) *pn_selected_index = pni->marked_index; if (selected_btn_index != INVALID) { return pni->btn_id[selected_btn_index]; } return INVALID; } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/arc.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000005670�11602233310�013705� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/arc.e,v 1.6 2011/05/16 16:21:56 william Exp $ */ #ifndef _ARC_E_ #define _ARC_E_ extern int arcDrawn; #ifdef _INCLUDE_FROM_ARC_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_ARC_C_*/ extern void PointsToArc ARGS_DECL((int xc, int yc, int x1, int y1, int x2, int y2, int dir, int int_degree, int *ltx, int *lty, int *w, int *h, int *angle1, int *angle2)); extern void ArcRealX2Y2 ARGS_DECL((struct ArcRec *, int *X2, int *Y2)); extern void GetArcArrowInfo ARGS_DECL((struct ObjRec *, IntPoint *tipvs1, IntPoint *tailvs1, IntPoint *vs1, int *a_angle1, IntPoint *tipvs2, IntPoint *tailvs2, IntPoint *vs2, int *a_angle2)); extern void CalcArcOBBox ARGS_DECL((struct ObjRec *)); extern void CalcArcBBox ARGS_DECL((struct ObjRec *, struct BBRec obbox, struct BBRec *bbox)); extern void DumpArcObj ARGS_DECL((FILE *, struct ObjRec *)); extern int NeedsToCacheArcObj ARGS_DECL((struct ObjRec *)); extern void DrawArcObj ARGS_DECL((Window, int X, int Y, struct ObjRec *)); extern struct ObjRec *CreateArcObj ARGS_DECL((int xc, int yc, int x1, int y1, int x2, int y2, int dir, int ltx, int lty, int w, int h, int angle1, int angle2, int CreateAbsolute)); extern void DrawArc ARGS_DECL((XEvent *)); extern void SaveArcObj ARGS_DECL((FILE *, struct ObjRec *)); extern void ReadArcObj ARGS_DECL((FILE *, char *, struct ObjRec **)); extern void SetArcPropMask ARGS_DECL((struct ObjRec *, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void FreeArcObj ARGS_DECL((struct ObjRec *)); extern void MakePreciseArc ARGS_DECL((void)); extern void PreciseRotateAnArc ARGS_DECL((void)); #ifdef _INCLUDE_FROM_ARC_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_ARC_C_*/ #endif /*_ARC_E_*/ ������������������������������������������������������������������������tgif-QPL-4.2.5/import.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000011530�11602233311�014443� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/import.e,v 1.15 2011/05/16 16:21:58 william Exp $ */ #ifndef _IMPORT_E_ #define _IMPORT_E_ #ifdef _INCLUDE_FROM_IMPORT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_IMPORT_C_*/ extern void MillisecondSleep ARGS_DECL((int ms)); extern int ExtensionMatch ARGS_DECL((char *Spec, char *DirName)); extern char *SetUpExtStr ARGS_DECL((int cbBuf, char *szExt, char *szOtherExt)); extern void CleanUpImport ARGS_DECL((void)); extern void InitImport ARGS_DECL((void)); extern void ImportXBitmapFile ARGS_DECL((void)); extern void ImportXPixmapFile ARGS_DECL((void)); extern void ImportEPSFile ARGS_DECL((int Embed, char *psz_fname_spec)); extern int ConvertGifToXpm ARGS_DECL((char *pszGifPath, char *pszXpmPath, int xpm_path_sz)); extern int ConvertPngToXpm ARGS_DECL((char *pszPngPath, char *pszXpmPath, int xpm_path_sz)); extern int ConvertJpegToXpm ARGS_DECL((char *pszJpegPath, char *pszXpmPath, int xpm_path_sz)); extern int ConvertImageFileToPpm6 ARGS_DECL((char *pszImageFilePath, char *pszPpm6Path, int ppm6_path_sz, int format)); extern int ConvertJpegToPpm6 ARGS_DECL((char *pszJpegPath, char *pszPpm6Path, int ppm6_path_sz)); extern int ConvertPngToPpm6 ARGS_DECL((char *pszJpegPath, char *pszPpm6Path, int ppm6_path_sz)); extern void ImportPNGFile ARGS_DECL((void)); extern void ImportJPEGFile ARGS_DECL((int Embed, char *psz_fname_spec)); extern void ImportGIFFile ARGS_DECL((void)); extern int ConvertPbmToXbm ARGS_DECL((char *pszPbmPath, char *pszXbmPath, int xbm_path_sz)); extern void ImportPBMFile ARGS_DECL((void)); extern int ConvertPgmToXpm ARGS_DECL((char *pszPgmPath, char *pszXpmPath, int xpm_path_sz)); extern void ImportPGMFile ARGS_DECL((void)); extern int ConvertPpmToXpm ARGS_DECL((char *pszPpmPath, char *pszXpmPath, int xpm_path_sz)); extern void ImportPPMFile ARGS_DECL((void)); extern DspList *ImportFilterListing ARGS_DECL((int *pnEntries)); extern int GetEnableFailedImportMsgBox ARGS_DECL((void)); extern int SetEnableFailedImportMsgBox ARGS_DECL((int)); extern void ImportOtherFile ARGS_DECL((void)); extern void ImportOtherFileType ARGS_DECL((char*)); extern int ImportSpecifiedFileType ARGS_DECL((char *psz_path, char *psz_filter)); extern int ConvertOtherToXpm ARGS_DECL((char *pszFile, char *pszFormat, char *pszXpmPath, int xpm_path_sz)); extern void ImportGIFToXPixmapDeck ARGS_DECL((void)); extern void CreateThumbnails ARGS_DECL((void)); extern void BrowseXBitmap ARGS_DECL((void)); extern void BrowseXPixmap ARGS_DECL((void)); extern void BrowseOther ARGS_DECL((void)); extern void BrowseOtherType ARGS_DECL((char*)); extern struct ObjRec * CreatePpmTrueObjFromImage ARGS_DECL((XImage*, int image_w, int image_h, char *ppm_data, unsigned int data_size)); extern void ScreenCapture ARGS_DECL((void)); extern void FullScreenCapture ARGS_DECL((void)); extern void DelayedFullScreenCapture ARGS_DECL((void)); extern void ToggleHideDuringCapture ARGS_DECL((void)); extern int RefreshScreenCaptureMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateScreenCaptureMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern void ToggleAutoEPSPreviewBitmap ARGS_DECL((void)); extern int RefreshImportMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateImportMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); #ifdef _INCLUDE_FROM_IMPORT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_IMPORT_C_*/ #endif /*_IMPORT_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/shortcut.e���������������������������������������������������������������������������0000644�0000764�0000764�00000003375�11602233312�015015� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/shortcut.e,v 1.7 2011/05/16 16:21:59 william Exp $ */ #ifndef _SHORTCUT_E_ #define _SHORTCUT_E_ #ifdef _INCLUDE_FROM_SHORTCUT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_SHORTCUT_C_*/ extern void InitShortCut ARGS_DECL((void)); extern void CleanUpShortCut ARGS_DECL((void)); extern int FetchShortCut ARGS_DECL((int c, char *code, unsigned int *state, char **name, char *args, int args_sz)); extern int FetchFuncKeyShortCut ARGS_DECL((int c, char *code, unsigned int *state, char **name, char *args, int args_sz)); extern int FetchCmdById ARGS_DECL((int nCmdId, char *code, unsigned int *state, char **name, char *args)); extern int ValidShortCut ARGS_DECL((char *name, int num_args, char *code, unsigned int *state)); #ifdef _INCLUDE_FROM_SHORTCUT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_SHORTCUT_C_*/ #endif /*_SHORTCUT_E_*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbitmap.e����������������������������������������������������������������������������0000644�0000764�0000764�00000012110�11602233314�014573� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbitmap.e,v 1.12 2011/05/16 16:22:00 william Exp $ */ #ifndef _XBITMAP_E_ #define _XBITMAP_E_ extern GC xbmGC; extern int askForXBmSpec; extern int stripEPSComments; extern int saveEPSLines; extern int leftExportPixelTrim; extern int topExportPixelTrim; extern int rightExportPixelTrim; extern int bottomExportPixelTrim; extern int xpmOutputVersion; extern Pixmap dummyBitmap; extern char gszHhtmlExportTemplate[MAXPATHLENGTH]; #ifdef _INCLUDE_FROM_XBITMAP_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_XBITMAP_C_*/ extern void SetHtmlExportTemplate ARGS_DECL((void)); extern int ReadHtmlExportTemplate ARGS_DECL((char *buf)); extern void SetExportPixelTrim ARGS_DECL((int cur_val_is_too_large)); extern int GetXpmOutputVersion ARGS_DECL((void)); extern void SetXpmOutputVersion ARGS_DECL((int)); extern void InitXBm ARGS_DECL((void)); extern void ExportHalfToneBitmap ARGS_DECL((void)); extern void ExportThresholdBitmap ARGS_DECL((void)); extern void SetExportBitmapThreshold ARGS_DECL((char*)); extern int RefreshBitPixmapMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateBitPixmapMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern void CleanUpXBm ARGS_DECL((void)); extern void CalcTransform ARGS_DECL((struct MtrxRec *)); extern void MakeCachedBitmap ARGS_DECL((struct ObjRec *)); extern int ExtractBitmap ARGS_DECL((Pixmap OrigBitmap, XImage *OrigImage, int X, int Y, int W, int H, Pixmap *Bitmap, XImage **Image)); extern int AutoTrimBitmap ARGS_DECL((Pixmap OrigBitmap, int *pnImageW, int *pnImageH, Pixmap *Bitmap, XImage **Image, int *pnEmptyImage, int *pnDontFreeOrigBitmap)); extern void InvertXBitmaps ARGS_DECL((void)); extern void ParseCutSpec ARGS_DECL((char *Spec, int ImageW, int ImageH, float *Mag, int *SrcX, int *SrcY, int *SrcW, int *SrcH)); extern void CutXBitmap ARGS_DECL((void)); extern int InitTrueColorInfo ARGS_DECL((XImage*, TrueColorInfo*, int image_w)); extern void GenPreviewBitmap ARGS_DECL((FILE *, int llxPage, int llyPage, int urxPage, int uryPage)); extern void GetRealBaseName ARGS_DECL((char *fname)); extern void SetAColorByteInfo ARGS_DECL((ColorBytes*, XColor*)); extern int DumpXImageToPpmFile ARGS_DECL((XImage*, int w, int h, char *tmp_fname, int deflate)); extern void DumpXBitmapFile ARGS_DECL((int nInImageProc, int nDumpPpmPreferred, int nPageNumInFileName)); extern int DumpXImageToFile ARGS_DECL((XImage*, int W, int H, char *tmp_fname, char *ext)); extern void ExportXPixmapDeckToGIF ARGS_DECL((void)); extern void DumpBitmap ARGS_DECL((FILE*, XImage*, char*, int ImageW, int ImageH, int Transformed, int OrigX, int OrigY, int AdjX, struct MtrxRec *, int Indent)); extern void DumpXBmObj ARGS_DECL((FILE*, struct ObjRec *)); extern int NeedsToCacheXBmObj ARGS_DECL((struct ObjRec *)); extern void DrawXBmObj ARGS_DECL((Window, int XOff, int YOff, struct ObjRec *)); extern struct ObjRec * CreateXBmObj ARGS_DECL((int ImageW, int ImageH, int W, int H, Pixmap, XImage *)); extern void BreakUpXBitmap ARGS_DECL((struct ObjRec *, int ColsAndRows, int W, int H)); extern void DumpXBmData ARGS_DECL((FILE*, Pixmap bitmap, XImage**, int W, int H)); extern void SaveXBmObj ARGS_DECL((FILE *, struct ObjRec *)); extern void ReadXBmObj ARGS_DECL((FILE *, char *Inbuf, struct ObjRec **)); extern void SetXBmPropMask ARGS_DECL((struct ObjRec *, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void FreeXBmObj ARGS_DECL((struct ObjRec *)); #ifdef _INCLUDE_FROM_XBITMAP_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_XBITMAP_C_*/ #endif /*_XBITMAP_E_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/depcomp������������������������������������������������������������������������������0000755�0000764�0000764�00000042246�11602233316�014355� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#! /bin/sh # depcomp - compile a program generating dependencies as side-effects scriptversion=2006-10-15.18 # Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006 Free Software # Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301, USA. # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Originally written by Alexandre Oliva <oliva@dcc.unicamp.br>. case $1 in '') echo "$0: No command. Try \`$0 --help' for more information." 1>&2 exit 1; ;; -h | --h*) cat <<\EOF Usage: depcomp [--help] [--version] PROGRAM [ARGS] Run PROGRAMS ARGS to compile a file, generating dependencies as side-effects. Environment variables: depmode Dependency tracking mode. source Source file read by `PROGRAMS ARGS'. object Object file output by `PROGRAMS ARGS'. DEPDIR directory where to store dependencies. depfile Dependency file to output. tmpdepfile Temporary file to use when outputing dependencies. libtool Whether libtool is used (yes/no). Report bugs to <bug-automake@gnu.org>. EOF exit $? ;; -v | --v*) echo "depcomp $scriptversion" exit $? ;; esac if test -z "$depmode" || test -z "$source" || test -z "$object"; then echo "depcomp: Variables source, object and depmode must be set" 1>&2 exit 1 fi # Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. depfile=${depfile-`echo "$object" | sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} rm -f "$tmpdepfile" # Some modes work just like other modes, but use different flags. We # parameterize here, but still list the modes in the big case below, # to make depend.m4 easier to write. Note that we *cannot* use a case # here, because this file can only contain one case statement. if test "$depmode" = hp; then # HP compiler uses -M and no extra arg. gccflag=-M depmode=gcc fi if test "$depmode" = dashXmstdout; then # This is just like dashmstdout with a different argument. dashmflag=-xM depmode=dashmstdout fi case "$depmode" in gcc3) ## gcc 3 implements dependency tracking that does exactly what ## we want. Yay! Note: for some reason libtool 1.4 doesn't like ## it if -MD -MP comes after the -MF stuff. Hmm. ## Unfortunately, FreeBSD c89 acceptance of flags depends upon ## the command line argument order; so add the flags where they ## appear in depend2.am. Note that the slowdown incurred here ## affects only configure: in makefiles, %FASTDEP% shortcuts this. for arg do case $arg in -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; *) set fnord "$@" "$arg" ;; esac shift # fnord shift # $arg done "$@" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi mv "$tmpdepfile" "$depfile" ;; gcc) ## There are various ways to get dependency output from gcc. Here's ## why we pick this rather obscure method: ## - Don't want to use -MD because we'd like the dependencies to end ## up in a subdir. Having to rename by hand is ugly. ## (We might end up doing this anyway to support other compilers.) ## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like ## -MM, not -M (despite what the docs say). ## - Using -M directly means running the compiler twice (even worse ## than renaming). if test -z "$gccflag"; then gccflag=-MD, fi "$@" -Wp,"$gccflag$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" echo "$object : \\" > "$depfile" alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz ## The second -e expression handles DOS-style file names with drive letters. sed -e 's/^[^:]*: / /' \ -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" ## This next piece of magic avoids the `deleted header file' problem. ## The problem is that when a header file which appears in a .P file ## is deleted, the dependency causes make to die (because there is ## typically no way to rebuild the header). We avoid this by adding ## dummy dependencies for each header file. Too bad gcc doesn't do ## this for us directly. tr ' ' ' ' < "$tmpdepfile" | ## Some versions of gcc put a space before the `:'. On the theory ## that the space means something, we add a space to the output as ## well. ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; hp) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; sgi) if test "$libtool" = yes; then "$@" "-Wp,-MDupdate,$tmpdepfile" else "$@" -MDupdate "$tmpdepfile" fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files echo "$object : \\" > "$depfile" # Clip off the initial element (the dependent). Don't try to be # clever and replace this with sed code, as IRIX sed won't handle # lines with more than a fixed number of characters (4096 in # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; # the IRIX cc adds comments like `#:fec' to the end of the # dependency line. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \ tr ' ' ' ' >> $depfile echo >> $depfile # The second pass generates a dummy entry for each header file. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ >> $depfile else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; aix) # The C for AIX Compiler uses -M and outputs the dependencies # in a .u file. In older versions, this file always lives in the # current directory. Also, the AIX compiler puts `$object:' at the # start of each line; $object doesn't have directory information. # Version 6 uses the directory in both cases. stripped=`echo "$object" | sed 's/\(.*\)\..*$/\1/'` tmpdepfile="$stripped.u" if test "$libtool" = yes; then "$@" -Wc,-M else "$@" -M fi stat=$? if test -f "$tmpdepfile"; then : else stripped=`echo "$stripped" | sed 's,^.*/,,'` tmpdepfile="$stripped.u" fi if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi if test -f "$tmpdepfile"; then outname="$stripped.o" # Each line is of the form `foo.o: dependent.h'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile" sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile" else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; icc) # Intel's C compiler understands `-MD -MF file'. However on # icc -MD -MF foo.d -c -o sub/foo.o sub/foo.c # ICC 7.0 will fill foo.d with something like # foo.o: sub/foo.c # foo.o: sub/foo.h # which is wrong. We want: # sub/foo.o: sub/foo.c # sub/foo.o: sub/foo.h # sub/foo.c: # sub/foo.h: # ICC 7.1 will output # foo.o: sub/foo.c sub/foo.h # and will wrap long lines using \ : # foo.o: sub/foo.c ... \ # sub/foo.h ... \ # ... "$@" -MD -MF "$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" # Each line is of the form `foo.o: dependent.h', # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" # Some versions of the HPUX 10.20 sed can't process this invocation # correctly. Breaking it into two sed invocations is a workaround. sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; hp2) # The "hp" stanza above does not work with aCC (C++) and HP's ia64 # compilers, which have integrated preprocessors. The correct option # to use with these is +Maked; it writes dependencies to a file named # 'foo.d', which lands next to the object file, wherever that # happens to be. # Much of this is similar to the tru64 case; see comments there. dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` test "x$dir" = "x$object" && dir= base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` if test "$libtool" = yes; then tmpdepfile1=$dir$base.d tmpdepfile2=$dir.libs/$base.d "$@" -Wc,+Maked else tmpdepfile1=$dir$base.d tmpdepfile2=$dir$base.d "$@" +Maked fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile1" "$tmpdepfile2" exit $stat fi for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" do test -f "$tmpdepfile" && break done if test -f "$tmpdepfile"; then sed -e "s,^.*\.[a-z]*:,$object:," "$tmpdepfile" > "$depfile" # Add `dependent.h:' lines. sed -ne '2,${; s/^ *//; s/ \\*$//; s/$/:/; p;}' "$tmpdepfile" >> "$depfile" else echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" "$tmpdepfile2" ;; tru64) # The Tru64 compiler uses -MD to generate dependencies as a side # effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'. # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put # dependencies in `foo.d' instead, so we check for that too. # Subdirectories are respected. dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` test "x$dir" = "x$object" && dir= base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` if test "$libtool" = yes; then # With Tru64 cc, shared objects can also be used to make a # static library. This mechanism is used in libtool 1.4 series to # handle both shared and static libraries in a single compilation. # With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d. # # With libtool 1.5 this exception was removed, and libtool now # generates 2 separate objects for the 2 libraries. These two # compilations output dependencies in $dir.libs/$base.o.d and # in $dir$base.o.d. We have to check for both files, because # one of the two compilations can be disabled. We should prefer # $dir$base.o.d over $dir.libs/$base.o.d because the latter is # automatically cleaned when .libs/ is deleted, while ignoring # the former would cause a distcleancheck panic. tmpdepfile1=$dir.libs/$base.lo.d # libtool 1.4 tmpdepfile2=$dir$base.o.d # libtool 1.5 tmpdepfile3=$dir.libs/$base.o.d # libtool 1.5 tmpdepfile4=$dir.libs/$base.d # Compaq CCC V6.2-504 "$@" -Wc,-MD else tmpdepfile1=$dir$base.o.d tmpdepfile2=$dir$base.d tmpdepfile3=$dir$base.d tmpdepfile4=$dir$base.d "$@" -MD fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4" exit $stat fi for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4" do test -f "$tmpdepfile" && break done if test -f "$tmpdepfile"; then sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile" # That's a tab and a space in the []. sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile" else echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; #nosideeffect) # This comment above is used by automake to tell side-effect # dependency tracking mechanisms from slower ones. dashmstdout) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout, regardless of -o. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # Remove `-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done test -z "$dashmflag" && dashmflag=-M # Require at least two characters before searching for `:' # in the target name. This is to cope with DOS-style filenames: # a dependency such as `c:/foo/bar' could be seen as target `c' otherwise. "$@" $dashmflag | sed 's:^[ ]*[^: ][^:][^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" tr ' ' ' ' < "$tmpdepfile" | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; dashXmstdout) # This case only exists to satisfy depend.m4. It is never actually # run, as this mode is specially recognized in the preamble. exit 1 ;; makedepend) "$@" || exit $? # Remove any Libtool call if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # X makedepend shift cleared=no for arg in "$@"; do case $cleared in no) set ""; shift cleared=yes ;; esac case "$arg" in -D*|-I*) set fnord "$@" "$arg"; shift ;; # Strip any option that makedepend may not understand. Remove # the object too, otherwise makedepend will parse it as a source file. -*|$object) ;; *) set fnord "$@" "$arg"; shift ;; esac done obj_suffix="`echo $object | sed 's/^.*\././'`" touch "$tmpdepfile" ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" sed '1,2d' "$tmpdepfile" | tr ' ' ' ' | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" "$tmpdepfile".bak ;; cpp) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # Remove `-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done "$@" -E | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' | sed '$ s: \\$::' > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" cat < "$tmpdepfile" >> "$depfile" sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; msvisualcpp) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout, regardless of -o, # because we must use -o when running libtool. "$@" || exit $? IFS=" " for arg do case "$arg" in "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") set fnord "$@" shift shift ;; *) set fnord "$@" "$arg" shift shift ;; esac done "$@" -E | sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile" echo " " >> "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile" rm -f "$tmpdepfile" ;; none) exec "$@" ;; *) echo "Unknown depmode $depmode" 1>&2 exit 1 ;; esac exit 0 # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgcwdl.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000004777�11602233313�014436� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgcwdl.e,v 1.7 2011/05/16 16:22:00 william Exp $ */ #ifndef _TGCWDL_E_ #define _TGCWDL_E_ #include "tidget.h" #define HS_WIDTH 181 #define HS_HEIGHT 181 #define V_WIDTH 14 #define V_HEIGHT 181 #define ID_CWHEEL_DIALOG 101 #define ID_CWHEEL_HS_AREA 102 #define ID_CWHEEL_V_AREA 103 #define ID_CWHEEL_EDIT_R 104 #define ID_CWHEEL_EDIT_G 105 #define ID_CWHEEL_EDIT_B 106 #define ID_CWHEEL_EDIT_H 107 #define ID_CWHEEL_EDIT_S 108 #define ID_CWHEEL_EDIT_V 109 #define ID_CWHEEL_EDIT_CNAME 110 #define ID_CWHEEL_SELCOLOR 111 #define ID_CWHEEL_BTN_ADD 112 #define ID_CWHEEL_BTN_OK 113 #define ID_CWHEEL_BTN_CANCEL 114 typedef struct tagColorWheelInfo { int initialized; int mapped; unsigned int r, g, b, h, s, v; char color_str[40]; /* input and output */ int hs_x, hs_y, v_y; Pixmap hs_pixmap; Pixmap v_pixmap; TidgetInfo *dialogbox_tidgetinfo; } ColorWheelInfo; extern ColorWheelInfo gColorWheelInfo; #ifdef _INCLUDE_FROM_TGCWDL_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TGCWDL_C_*/ extern void ShowTdgtColorWheelDialogBox ARGS_DECL((void)); extern void HideTdgtColorWheelDialogBox ARGS_DECL((void)); extern TidgetInfo *CreateTdgtColorWheelDialogBox ARGS_DECL((Display*, Window)); extern void DestroyTdgtColorWheelDialogBox ARGS_DECL((Display*, TidgetInfo*)); extern int TdgtColorWheelDlgLoop ARGS_DECL((TidgetInfo*)); extern int InitTdgtColorWheelDlg ARGS_DECL((void)); extern void CleanUpTdgtColorWheelDlg ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TGCWDL_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TGCWDL_C_*/ #endif /*_TGCWDL_E_*/ �tgif-QPL-4.2.5/tdgtmsg.c����������������������������������������������������������������������������0000644�0000764�0000764�00000025734�11602233313�014615� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtmsg.c,v 1.9 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TDGTMSG_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "tidget.h" #include "choose.e" #include "cursor.e" #include "font.e" #include "menu.e" #include "msg.e" #include "raster.e" #include "rect.e" #include "setup.e" #include "tdgtmsg.e" #include "text.e" #include "tidget.e" #include "util.e" static void RedrawTdgtMsg ARGS_DECL((TidgetInfo *pti)); static int TdgtMsgEventHandler ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo *handling_pti)); static int IsTdgtMsgEvent ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo **ppti_handler_tidget_return)); static void DestroyTdgtMsg ARGS_DECL((TidgetInfo *pti)); static void MapTdgtMsg ARGS_DECL((TidgetInfo *pti)); static void TdgtMsgMoveResize ARGS_DECL((TidgetInfo *pti, int x, int y, int w, int h)); static int TdgtMsgSendCmd ARGS_DECL((TidgetInfo *pti, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); /* --------------------- RedrawTdgtMsg() --------------------- */ static void TdgtMsgDrawCaption(pTdgtMsg) TdgtMsg *pTdgtMsg; { int x=windowPadding+pTdgtMsg->pti->tci.h_pad; int y=windowPadding+pTdgtMsg->pti->tci.v_pad; int just=pTdgtMsg->just; int win_w=pTdgtMsg->pti->tci.win_info.w; char *psz=NULL, *psz_cur=TdgtMsgGetText(pTdgtMsg); if (boldMsgFontSet != NULL || boldMsgFontPtr != NULL) { if (boldMsgFontPtr != NULL) { XSetFont(mainDisplay, gTidgetManager.gc, boldMsgFontPtr->fid); } y += boldMsgFontAsc; } else if (msgFontSet != NULL || msgFontPtr != NULL) { XSetFont(mainDisplay, gTidgetManager.gc, msgFontPtr->fid); y += msgFontAsc; } else { y += defaultFontAsc; } switch (just) { case JUST_L: break; case JUST_C: x = (win_w>>1); break; case JUST_R: x = win_w-windowPadding-pTdgtMsg->pti->tci.h_pad; break; } do { int line_w=0; psz = strchr(psz_cur, '\n'); if (psz != NULL) *psz = '\0'; switch (just) { case JUST_L: DrawBoldMsgString(mainDisplay, pTdgtMsg->pti->tci.win, gTidgetManager.gc, x, y, psz_cur, strlen(psz_cur)); break; case JUST_C: line_w = BoldMsgTextWidth(boldMsgFontPtr, psz_cur, strlen(psz_cur)); DrawBoldMsgString(mainDisplay, pTdgtMsg->pti->tci.win, gTidgetManager.gc, x-(line_w>>1), y, psz_cur, strlen(psz_cur)); break; case JUST_R: line_w = BoldMsgTextWidth(boldMsgFontPtr, psz_cur, strlen(psz_cur)); DrawBoldMsgString(mainDisplay, pTdgtMsg->pti->tci.win, gTidgetManager.gc, x-line_w, y, psz_cur, strlen(psz_cur)); break; } if (boldMsgFontSet != NULL || boldMsgFontPtr != NULL) { y += boldMsgFontHeight; } else if (msgFontSet != NULL || msgFontPtr != NULL) { y += msgFontHeight; } else { y += defaultFontHeight; } if (psz != NULL) { *psz++ = '\n'; psz_cur = psz; } else { psz_cur = NULL; } } while (psz != NULL); TidgetManagerResetGC(); } static void RedrawTdgtMsg(pti) TidgetInfo *pti; { TdgtMsg *pTdgtMsg=(TdgtMsg*)(pti->tidget); XClearWindow(mainDisplay, pTdgtMsg->pti->tci.win); if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, pTdgtMsg->pti->tci.win_info.w, pTdgtMsg->pti->tci.win_info.h); switch (pTdgtMsg->pti->tci.state) { case TGBS_NORMAL: break; default: TgDrawThreeDButton(mainDisplay, pTdgtMsg->pti->tci.win, gTidgetManager.gc, &bbox, pTdgtMsg->pti->tci.state, 2, TRUE); TidgetManagerResetGC(); break; } } else { /* * XDrawRectangle(mainDisplay, pTdgtMsg->pti->tci.win, gTidgetManager.gc, * 0, 0, pTdgtMsg->pti->tci.win_info.w, * pTdgtMsg->pti->tci.win_info.h); */ } TdgtMsgDrawCaption(pTdgtMsg); } /* --------------------- TdgtMsgEventHandler() --------------------- */ static int TdgtMsgEventHandler(pti, input, handling_pti) TidgetInfo *pti, *handling_pti; XEvent *input; { TdgtMsg *pTdgtMsg=(TdgtMsg*)(pti->tidget); if (pti != handling_pti) return FALSE; if (input->type == Expose) { XEvent ev; RedrawTdgtMsg(pTdgtMsg->pti); while (XCheckWindowEvent(mainDisplay, pTdgtMsg->pti->tci.win, ExposureMask, &ev)) ; } return FALSE; } /* --------------------- IsTdgtMsgEvent() --------------------- */ static int IsTdgtMsgEvent(pti, input, ppti_handler_tidget_return) TidgetInfo *pti, **ppti_handler_tidget_return; XEvent *input; { TdgtMsg *pTdgtMsg=(TdgtMsg*)(pti->tidget); if (input->xany.window == pTdgtMsg->pti->tci.win) { *ppti_handler_tidget_return = pti; return TRUE; } return FALSE; } /* --------------------- DestroyTdgtMsg() --------------------- */ static void DestroyTdgtMsg(pti) TidgetInfo *pti; { TdgtMsg *pTdgtMsg=(TdgtMsg*)(pti->tidget); TdgtMsgReset(pTdgtMsg); free(pTdgtMsg); } /* --------------------- MapTdgtMsg() --------------------- */ static void MapTdgtMsg(pti) TidgetInfo *pti; { TdgtMsg *pTdgtMsg=(TdgtMsg*)(pti->tidget); #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, pTdgtMsg->pti->tci.win); XSelectInput(mainDisplay, pTdgtMsg->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); #else XSelectInput(mainDisplay, pTdgtMsg->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, pTdgtMsg->pti->tci.win); #endif } /* --------------------- TdgtMsgMoveResize() --------------------- */ static void TdgtMsgMoveResize(pti, x, y, w, h) TidgetInfo *pti; int x, y, w, h; { TdgtMsg *pTdgtMsg=(TdgtMsg*)(pti->tidget); /* there should be no need to resize a button */ pTdgtMsg->pti->tci.win_info.x = x; pTdgtMsg->pti->tci.win_info.y = y; pTdgtMsg->pti->tci.win_info.w = w; pTdgtMsg->pti->tci.win_info.h = h; XMoveResizeWindow(mainDisplay, pTdgtMsg->pti->tci.win, x, y, w, h); } /* --------------------- TdgtMsgSendCmd() --------------------- */ static int TdgtMsgSendCmd(pti, cmd_type, cmd_arg, pv_cmd_userdata) TidgetInfo *pti; int cmd_type, cmd_arg; void *pv_cmd_userdata; { TdgtMsg *pTdgtMsg=(TdgtMsg*)(pti->tidget); if (pTdgtMsg != NULL) { } return FALSE; } /* --------------------- TdgtMsgReset() --------------------- */ void TdgtMsgReset(pTdgtMsg) TdgtMsg *pTdgtMsg; { FreeDynStrBuf(&pTdgtMsg->pti->tci.dyn_str); } /* --------------------- CreateTdgtMsg() --------------------- */ static void TdgtMsgCalcGeom(caption, pn_w, pn_h) char *caption; int *pn_w, *pn_h; { int w=0, h=0; char *psz=NULL, *psz_cur=NULL, *dup_caption=UtilStrDup(caption); if (dup_caption == NULL) FailAllocMessage(); psz_cur = dup_caption; do { int line_w=0; psz = strchr(psz_cur, '\n'); if (psz != NULL) *psz = '\0'; line_w = BoldMsgTextWidth(boldMsgFontPtr, psz_cur, strlen(psz_cur)); if (line_w > w) w = line_w; if (boldMsgFontSet != NULL || boldMsgFontPtr != NULL) { h += boldMsgFontHeight; } else if (msgFontSet != NULL || msgFontPtr != NULL) { h += msgFontHeight; } else { h += defaultFontHeight; } if (psz != NULL) { *psz++ = '\n'; psz_cur = psz; } else { psz_cur = NULL; } } while (psz != NULL); UtilFree(dup_caption); if (pn_w != NULL) *pn_w = w; if (pn_h != NULL) *pn_h = h; } TdgtMsg *CreateTdgtMsg(parent_win, parent_tidgetinfo, ctl_id, x, y, h_pad, v_pad, state, caption, just) Window parent_win; TidgetInfo *parent_tidgetinfo; int ctl_id, x, y, h_pad, v_pad, state, just; char *caption; { int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel), w=0, h=0; TdgtMsg *pTdgtMsg=NULL; if (caption != NULL) { int msg_w=0, msg_h=0; TdgtMsgCalcGeom(caption, &msg_w, &msg_h); w = msg_w + (windowPadding<<1) + (h_pad<<1); h = msg_h + (windowPadding<<1) + (v_pad<<1); } pTdgtMsg = (TdgtMsg*)malloc(sizeof(TdgtMsg)); if (pTdgtMsg == NULL) FailAllocMessage(); memset(pTdgtMsg, 0, sizeof(TdgtMsg)); pTdgtMsg->pti = NewTidgetInfo(parent_tidgetinfo, TIDGET_TYPE_MSG, pTdgtMsg, ctl_id, NULL); if ((pTdgtMsg->pti->tci.win=XCreateSimpleWindow(mainDisplay, parent_win, x, y, w, h, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("CreateTdgtMsg()", NULL, TRUE); return NULL; } XSelectInput(mainDisplay, pTdgtMsg->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); SetTidgetInfoBasic(pTdgtMsg->pti, TIDGET_TYPE_MSG, pTdgtMsg, parent_win, x, y, w, h, h_pad, v_pad, state, caption); TidgetSetCallbacks(pTdgtMsg->pti, RedrawTdgtMsg, TdgtMsgEventHandler, IsTdgtMsgEvent, DestroyTdgtMsg, MapTdgtMsg, TdgtMsgMoveResize, TdgtMsgSendCmd); pTdgtMsg->just = just; return pTdgtMsg; } /* --------------------- TdgtMsgSetText() --------------------- */ int TdgtMsgSetText(pTdgtMsg, str) TdgtMsg *pTdgtMsg; char *str; { RedrawTdgtMsg(pTdgtMsg->pti); if (str != NULL) { FreeDynStrBuf(&(pTdgtMsg->pti->tci.dyn_str)); DynStrSet(&(pTdgtMsg->pti->tci.dyn_str), str); } return TRUE; } /* --------------------- TdgtMsgGetText() --------------------- */ char *TdgtMsgGetText(pTdgtMsg) TdgtMsg *pTdgtMsg; { return pTdgtMsg->pti->tci.dyn_str.s; } /* --------------------- TdgtMsgSetState() --------------------- */ int TdgtMsgSetState(pTdgtMsg, new_state) TdgtMsg *pTdgtMsg; int new_state; { int need_to_redraw=(pTdgtMsg->pti->tci.state != new_state); pTdgtMsg->pti->tci.state = new_state; if (need_to_redraw) { RedrawTdgtMsg(pTdgtMsg->pti); } return TRUE; } /* --------------------- TdgtMsgGetState() --------------------- */ int TdgtMsgGetState(pTdgtMsg) TdgtMsg *pTdgtMsg; { return pTdgtMsg->pti->tci.state; } /* --------------------- Init & Clean Up --------------------- */ int InitTdgtMsg() { return TRUE; } void CleanUpTdgtMsg() { } ������������������������������������tgif-QPL-4.2.5/Tgif.tmpl-linux����������������������������������������������������������������������0000644�0000764�0000764�00000006024�11602233313�015713� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-linux,v 1.20 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif XCOMM ----------------------------------------------- XCOMM For Red Hat Linux 7.2 and above, /usr/bin/xpmtoppm does not XCOMM know how to handle XPM format version 1. Please XCOMM add -D_XPM3TOPPM to the last MOREDEFINES below. XCOMM ----------------------------------------------- PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif XCOMM MOREDEFINES = -D_HAS_STREAMS_SUPPORT -DENABLE_NLS -D_TGIF_DBG LOCALEDIR = /usr/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -DDEFATTRGROUP=\"TANGRAM-II:Declaration:Events:Messages:Rewards:Initialization:Watches\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -DUSE_XT_INITIALIZE -DPTHREAD MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) $(DEPXTOOLLIB) $(DEPXMULIB) LOCAL_LIBRARIES = $(XLIB) $(XTOOLLIB) $(XMULIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) SYS_LIBRARIES = -ldl -lm -lz -lpthread -lidn XCOMM SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM Linux 2.0.35 XCOMM XCOMM Linux 2.4.18-14 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/menuinfo.c���������������������������������������������������������������������������0000644�0000764�0000764�00000271115�11602233312�014757� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/menuinfo.c,v 1.60 2011/06/09 15:55:15 cvsps Exp $ */ #define _INCLUDE_FROM_MENUINFO_C_ #include "tgifdefs.h" #include "cmdids.h" #include "align.e" #include "color.e" #include "cutpaste.e" #include "drawing.e" #include "edit.e" #include "file.e" #include "font.e" #include "grid.e" #include "help.e" #include "imgproc.e" #include "import.e" #include "menu.e" #include "menuinfo.e" #include "names.e" #include "navigate.e" #include "page.e" #include "pattern.e" #include "raster.e" #include "scroll.e" #include "shape.e" #include "special.e" #include "stream.e" #include "stretch.e" #include "tangram2.e" #include "text.e" #include "xbitmap.e" /* ------------------ color menus ------------------ */ TgMenuInfo colorMenuInfo={ TGMUTYPE_COLOR, NULL, CreateColorMenu }; /* ------------------ bitmap menus ------------------ */ static TgMenuItemInfo modeMenuItemInfo[] = { { (char*)(&choicePixmap[NOTHING]), NULL, N_("Enter select/move/resize object mode"), NULL, CMDID_SELECTMODE }, { (char*)(&choicePixmap[DRAWTEXT]), NULL, N_("Enter draw text mode"), NULL, CMDID_DRAWTEXT }, { (char*)(&choicePixmap[DRAWBOX]), NULL, N_("Enter draw rectangle mode"), NULL, CMDID_DRAWBOX }, { (char*)(&choicePixmap[DRAWCORNEROVAL]), NULL, N_("Enter draw corner oval mode"), NULL, CMDID_DRAWCORNEROVAL }, { (char*)(&choicePixmap[DRAWCENTEROVAL]), NULL, N_("Enter draw center oval mode"), NULL, CMDID_DRAWCENTEROVAL }, { (char*)(&choicePixmap[DRAWEDGECIRCLE]), NULL, N_("Enter draw edge circle mode"), NULL, CMDID_DRAWEDGEOVAL }, { (char*)(&choicePixmap[DRAWPOLY]), NULL, N_("Enter draw poly/open spline mode"), NULL, CMDID_DRAWPOLY }, { (char*)(&choicePixmap[DRAWPOLYGON]), NULL, N_("Enter draw polygon/close spline mode"), NULL, CMDID_DRAWPOLYGON }, { (char*)(&choicePixmap[DRAWARC]), NULL, N_("Enter draw arc mode (specify center first)"), NULL, CMDID_DRAWARC }, { (char*)(&choicePixmap[DRAWEDGEARC]), NULL, N_("Enter draw arc mode (specify endpoints first)"), NULL, CMDID_DRAWEDGEARC }, { (char*)(&choicePixmap[DRAWRCBOX]), NULL, N_("Enter draw rcbox mode"), NULL, CMDID_DRAWRCBOX }, { (char*)(&choicePixmap[FREEHAND]), NULL, N_("Enter draw freehand poly/open spline mode"), NULL, CMDID_FREEHANDMODE }, { (char*)(&choicePixmap[VERTEXMODE]), NULL, N_("Enter select/move vertices mode"), NULL, CMDID_SELECTVERTEXMODE }, { (char*)(&choicePixmap[ROTATEMODE]), NULL, N_("Enter rotate/shear object mode"), NULL, CMDID_ROTATESHEARMODE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo modeMenuInfo={ TGMUTYPE_BITMAP, modeMenuItemInfo, CreateModeMenu }; TgMenuInfo fillMenuInfo={ TGMUTYPE_BITMAP, NULL, CreateFillMenu }; TgMenuInfo penMenuInfo={ TGMUTYPE_BITMAP, NULL, CreatePenMenu }; TgMenuInfo lineWidthMenuInfo={ TGMUTYPE_BITMAP, NULL, CreateLineWidthMenu }; static TgMenuItemInfo lineStyleMenuItemInfo[] = { { (char*)(&lineStylePixmap[LS_PLAIN]), NULL, N_("No arrows for a poly/open spline"), NULL, CMDID_CHANGEALLSELLINESTYLE }, { (char*)(&lineStylePixmap[LS_RIGHT]), NULL, N_("An arrow at the end of a poly/open spline"), NULL, CMDID_CHANGEALLSELLINESTYLE }, { (char*)(&lineStylePixmap[LS_LEFT]), NULL, N_("An arrow at the beginning of a poly/open spline"), NULL, CMDID_CHANGEALLSELLINESTYLE }, { (char*)(&lineStylePixmap[LS_DOUBLE]), NULL, N_("Arrows at both ends of a poly/open spline"), NULL, CMDID_CHANGEALLSELLINESTYLE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo lineStyleMenuInfo={ TGMUTYPE_BITMAP, lineStyleMenuItemInfo, CreateLineStyleMenu }; static TgMenuItemInfo lineTypeMenuItemInfo[] = { { (char*)(&lineTypePixmap[LT_STRAIGHT]), NULL, N_("Straight line segments"), NULL, CMDID_CHANGEALLSELLINETYPE }, { (char*)(&lineTypePixmap[LT_SPLINE]), NULL, N_("Open/closed splines"), NULL, CMDID_CHANGEALLSELLINETYPE }, { (char*)(&lineTypePixmap[LT_INTSPLINE]), NULL, N_("Interpolated splines"), NULL, CMDID_CHANGEALLSELLINETYPE }, { (char*)(&lineTypePixmap[LT_STRUCT_SPLINE]), NULL, N_("Structured splines"), NULL, CMDID_CHANGEALLSELLINETYPE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo lineTypeMenuInfo={ TGMUTYPE_BITMAP, lineTypeMenuItemInfo, CreateLineTypeMenu }; TgMenuInfo lineDashMenuInfo={ TGMUTYPE_BITMAP, NULL, CreateLineDashMenu }; static TgMenuItemInfo horiAlignMenuItemInfo[] = { { (char*)(&alignHoriPixmap[ALIGN_N]), NULL, N_("Set horizontal alignment to none"), NULL, CMDID_SETHORIZONTALALIGN }, { (char*)(&alignHoriPixmap[ALIGN_L]), NULL, N_("Set horizontal alignment to left aligned"), NULL, CMDID_SETHORIZONTALALIGN }, { (char*)(&alignHoriPixmap[ALIGN_C]), NULL, N_("Set horizontal alignment to center aligned"), NULL, CMDID_SETHORIZONTALALIGN }, { (char*)(&alignHoriPixmap[ALIGN_R]), NULL, N_("Set horizontal alignment to right aligned"), NULL, CMDID_SETHORIZONTALALIGN }, { (char*)(&alignHoriPixmap[ALIGN_S]), NULL, N_("Set horizontal distribution to equal-spacing"), NULL, CMDID_SETHORIZONTALALIGN }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo horiAlignMenuInfo={ TGMUTYPE_BITMAP, horiAlignMenuItemInfo, CreateHoriAlignMenu }; static TgMenuItemInfo vertAlignMenuItemInfo[] = { { (char*)(&alignVertPixmap[ALIGN_N]), NULL, N_("Set vertical alignment to none"), NULL, CMDID_SETVERTICALALIGN }, { (char*)(&alignVertPixmap[ALIGN_T]), NULL, N_("Set vertical alignment to top aligned"), NULL, CMDID_SETVERTICALALIGN }, { (char*)(&alignVertPixmap[ALIGN_M]), NULL, N_("Set vertical alignment to middle aligned"), NULL, CMDID_SETVERTICALALIGN }, { (char*)(&alignVertPixmap[ALIGN_B]), NULL, N_("Set vertical alignment to bottom aligned"), NULL, CMDID_SETVERTICALALIGN }, { (char*)(&alignVertPixmap[ALIGN_S]), NULL, N_("Set vertical distribution to equal-spacing"), NULL, CMDID_SETVERTICALALIGN }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo vertAlignMenuInfo={ TGMUTYPE_BITMAP, vertAlignMenuItemInfo, CreateVertAlignMenu }; static TgMenuItemInfo moveModeMenuItemInfo[] = { { (char*)(&moveModePixmap[CONST_MOVE]), NULL, N_("Set constrained move mode"), NULL, CMDID_SETMOVEMODE }, { (char*)(&moveModePixmap[UNCONST_MOVE]), NULL, N_("Set unconstrained move mode"), NULL, CMDID_SETMOVEMODE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo moveModeMenuInfo={ TGMUTYPE_BITMAP, moveModeMenuItemInfo, CreateMoveModeMenu }; static TgMenuItemInfo stretchableTextModeMenuItemInfo[] = { { (char*)(&stretchableModePixmap[NO_STRETCHABLE_TEXT]), NULL, N_("Make text objects not stretchable"), NULL, CMDID_SETSTRETCHTEXTMODE }, { (char*)(&stretchableModePixmap[STRETCHABLE_TEXT]), NULL, N_("Make text objects stretchable"), NULL, CMDID_SETSTRETCHTEXTMODE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo stretchableTextModeMenuInfo={ TGMUTYPE_BITMAP, stretchableTextModeMenuItemInfo, CreateStretchableTextModeMenu }; static TgMenuItemInfo objShadowMenuItemInfo[] = { { N_("Add Object Shadow"), NULL, N_("Add shadows to selected objects"), NULL, CMDID_ADDOBJSHADOW }, { N_("Remove Object Shadow"), NULL, N_("Remove shadows from selected objects"), NULL, CMDID_REMOVEOBJSHADOW }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Set Object Shadow Color..."), NULL, N_("Set the shadow color to be used for creating object shadows"), NULL, CMDID_SETOBJSHADOWCOLOR }, { N_("Set Object Shadow Offsets..."), NULL, N_("Set the x and y offset for generic object shadow"), NULL, CMDID_SETOBJSHADOWOFFSETS }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo objShadowMenuInfo={ TGMUTYPE_TEXT, objShadowMenuItemInfo, TgCreateMenuFromMenuInfo }; TgMenuInfo shapeMenuInfo={ TGMUTYPE_BITMAP, NULL, CreateShapeMenu }; static TgMenuItemInfo pageLayoutMenuItemInfo[] = { { (char*)(&pageLayoutPixmap[PAGE_STACK]), NULL, N_("Stacked page mode"), NULL, CMDID_SETPAGELAYOUTMODE }, { (char*)(&pageLayoutPixmap[PAGE_TILE]), NULL, N_("Tiled page mode"), NULL, CMDID_SETPAGELAYOUTMODE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo pageLayoutMenuInfo={ TGMUTYPE_BITMAP, pageLayoutMenuItemInfo, CreatePageLayoutMenu }; static TgMenuItemInfo transPatModeMenuItemInfo[] = { { (char*)(&transPatPixmap[NO_TRANSPAT_MODE]), NULL, N_("Make fill and pen patterns opaque"), NULL, CMDID_SETTRANSPATMODE }, { (char*)(&transPatPixmap[TRANSPAT_MODE]), NULL, N_("Make fill and pen patterns transparent"), NULL, CMDID_SETTRANSPATMODE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo transPatModeMenuInfo={ TGMUTYPE_BITMAP, transPatModeMenuItemInfo, CreateTransPatModeMenu }; static TgMenuItemInfo pageStyleMenuItemInfo[] = { { N_("Portrait"), NULL, N_("Portrait page style"), NULL, CMDID_PORTRAITMODE }, { N_("Landscape"), NULL, N_("Lanscape page style"), NULL, CMDID_LANDSCAPEMODE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo pageStyleMenuInfo={ TGMUTYPE_TEXT, pageStyleMenuItemInfo, CreatePageStyleMenu }; /* ------------------ text menus ------------------ */ TgMenuInfo fontMenuInfo={ TGMUTYPE_TEXT, NULL, CreateFontMenu }; static TgMenuItemInfo fontStyleMenuItemInfo[] = { { N_("Roman"), "Alt+Cntrl+o", N_("Roman text style"), NULL, CMDID_CHANGEALLSELFONTSTYLE }, { N_("Bold"), "Alt+Cntrl+b", N_("Bold text style"), NULL, CMDID_CHANGEALLSELFONTSTYLE }, { N_("Italic"), "Alt+Cntrl+t", N_("Italic text style"), NULL, CMDID_CHANGEALLSELFONTSTYLE }, { N_("BoldItalic"), "Alt+Cntrl+p", N_("Bold-italic text style"), NULL, CMDID_CHANGEALLSELFONTSTYLE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Left"), "Alt+Cntrl+l", N_("Left justified text"), NULL, CMDID_CHANGEALLSELFONTJUST }, { N_("Center"), "Alt+Cntrl+c", N_("Center justified text"), NULL, CMDID_CHANGEALLSELFONTJUST }, { N_("Right"), "Alt+Cntrl+r", N_("Right justified text"), NULL, CMDID_CHANGEALLSELFONTJUST }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("No Underline"), NULL, N_("No underlined text"), NULL, CMDID_CHANGEALLSELFONTUNDERLINE }, { N_("Underline"), NULL, N_("Underlined text"), NULL, CMDID_CHANGEALLSELFONTUNDERLINE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("No Overline"), NULL, N_("No overlined text"), NULL, CMDID_CHANGEALLSELFONTOVERLINE }, { N_("Overline"), NULL, N_("Overlined text"), NULL, CMDID_CHANGEALLSELFONTOVERLINE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo fontStyleMenuInfo={ TGMUTYPE_TEXT, fontStyleMenuItemInfo, CreateFontStyleMenu }; TgMenuInfo fontSizeMenuInfo={ TGMUTYPE_TEXT, NULL, CreateFontSizeMenu }; static TgMenuItemInfo stackedPageMenuItemInfo[] = { { N_("Next Page"), NULL, N_("Go to next page"), NULL, CMDID_NEXTPAGE }, { N_("Prev Page"), NULL, N_("Go to previous page"), NULL, CMDID_PREVPAGE }, { N_("Goto Page..."), NULL, N_("Go to a specified page"), NULL, CMDID_GOTOPAGE }, { N_("Name Pages..."), NULL, N_("Assign names to pages"), NULL, CMDID_NAMEPAGES }, { N_("Edit Page File Names..."), NULL, N_("Assign file names to pages to be used for PrintOneFilePerPage()"), NULL, CMDID_EDITPAGEFILENAMES }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Add Page Before..."), NULL, N_("Add a page before the current page"), NULL, CMDID_ADDPAGEBEFORE }, { N_("Add Page After..."), NULL, N_("Add a page after the current page"), NULL, CMDID_ADDPAGEAFTER }, { N_("Add Page Before (Copy All)..."), NULL, N_("Add a page before the current page and copy everything on the current page to the new page"), NULL, CMDID_ADDPAGEBEFORECOPYALL }, { N_("Add Page After (Copy All)..."), NULL, N_("Add a page after the current page and copy everything on the current page to the new page"), NULL, CMDID_ADDPAGEAFTERCOPYALL }, { N_("Delete Current Page"), NULL, N_("Delete the current page"), NULL, CMDID_DELETECURPAGE }, { N_("Delete Pages..."), NULL, N_("Delete user-specified pages"), NULL, CMDID_DELETEPAGES }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Print One Page"), NULL, N_("Print the curret page"), NULL, CMDID_PRINTONEPAGE }, { N_("Print Pages..."), NULL, N_("Print user-specified pages"), NULL, CMDID_PRINTPAGES }, { N_("Print One File Per Page..."), NULL, N_("Print into a separate file for each page"), NULL, CMDID_PRINTONEFILEPERPAGE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Specify Paper Size..."), NULL, N_("Set the physical size of the paper"), NULL, CMDID_SPECIFYPAPERSIZE }, { N_("Set Paper Color..."), NULL, N_("Set the color of the paper"), NULL, CMDID_SETPAPERCOLOR }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo stackedPageMenuInfo={ TGMUTYPE_TEXT, stackedPageMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo tiledPageMenuItemInfo[] = { { N_("Toggle Page Line Shown"), NULL, N_("Toggle the showing of page boundaries"), NULL, CMDID_TOGGLEPAGELINESHOWN }, { N_("Specify Drawing Size..."), NULL, N_("Change the drawing size"), NULL, CMDID_SPECIFYDRAWINGSIZE }, { N_("Print One Page"), NULL, N_("Select and print one of the pages"), NULL, CMDID_PRINTONEPAGE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Specify Paper Size..."), NULL, N_("Set the physical size of the paper"), NULL, CMDID_SPECIFYPAPERSIZE }, { N_("Set Paper Color..."), NULL, N_("Set the color of the paper"), NULL, CMDID_SETPAPERCOLOR }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo tiledPageMenuInfo={ TGMUTYPE_TEXT, tiledPageMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo pageMenuItemInfo[] = { { N_("Stacked Page"), TGMUITEM_PINNABLESUBMENU, N_("StackedPage Menu"), &stackedPageMenuInfo, MENU_STACKEDPAGE }, { N_("Tiled Page"), TGMUITEM_PINNABLESUBMENU, N_("TiledPage Menu"), &tiledPageMenuInfo, MENU_TILEDPAGE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo pageMenuInfo={ TGMUTYPE_TEXT, pageMenuItemInfo, CreatePageMenu }; static TgMenuItemInfo reduceColorMenuItemInfo[] = { { N_("Reduce Colors..."), NULL, N_("Reduce the number of colors of a selected image"), NULL, CMDID_REDUCECOLORS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Set Default Color Levels..."), NULL, N_("Set the number of R G B color levels for the ``standard colors''"), NULL, CMDID_SETDEFAULTCOLORLEVELS }, { N_("Reduce To Default Colors"), NULL, N_("Reduce the colors of a selected image to standard colors"), NULL, CMDID_REDUCETODEFAULTCOLORs }, { N_("Default Error Diffuse"), NULL, N_("Error diffuse to reduce colors of a selected image to standard colors"), NULL, CMDID_DEFAULTERRORDIFFUSE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Reduce To Pixmap Colors..."), NULL, N_("Reduce the colors of a selected image to a the colors in an XPM file"), NULL, CMDID_REDUCETOPIXMAPCOLORS }, { N_("Reduce To Mobileweb Safe Colors"), NULL, N_("Reduce the colors of a selected image to colors that are \"MobileWeb safe\" (6 shades of red/green/blue each)"), NULL, CMDID_REDUCETOMOBILEWEBCOLORS }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo reduceColorMenuInfo={ TGMUTYPE_TEXT, reduceColorMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo effectsMenuItemInfo[] = { { N_("Edge Detect"), NULL, N_("Perform edge-detection on a selected image"), NULL, CMDID_EDGEDETECT }, { N_("Emboss"), NULL, N_("Convert a selected image to gray and then emboss"), NULL, CMDID_EMBOSS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Spread..."), NULL, N_("Spread the pixels of a selected image around"), NULL, CMDID_SPREAD }, { N_("Sharpen"), NULL, N_("Sharpen a selected image"), NULL, CMDID_SHARPEN }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Blur (3x3)"), NULL, N_("Blur a selected image using a 3 by 3 filter"), NULL, CMDID_BLUR3 }, { N_("Blur (5x5)"), NULL, N_("Blur a selected image using a 5 by 5 filter"), NULL, CMDID_BLUR5 }, { N_("Blur (7x7)"), NULL, N_("Blur a selected image using a 7 by 7 filter"), NULL, CMDID_BLUR7 }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo effectsMenuInfo={ TGMUTYPE_TEXT, effectsMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo generateMenuItemInfo[] = { { N_("Run Bggen..."), NULL, N_("Run 'bggen' to create an image using the size of a selected image"), NULL, CMDID_RUNBGGEN }, { N_("Circular Bggen..."), NULL, N_("Create a gray circular image using the size of a selected image"), NULL, CMDID_CIRCULARBGGEN }, { N_("Simple Rect Bggen..."), NULL, N_("Create a single-color rectanglar image using the size of selected image"), NULL, CMDID_SIMPLERECTBGGEN }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo generateMenuInfo={ TGMUTYPE_TEXT, generateMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo fillReplaceMenuItemInfo[] = { { N_("Replace Color"), NULL, N_("Replace a color in a selected image with the current color"), NULL, CMDID_REPLACECOLOR }, { N_("Replace Color with Transparent"), NULL, N_("Replace a color in a selected image with a transparent color"), NULL, CMDID_REPLACECOLORWITHTRANS }, { N_("Flood Fill"), NULL, N_("Flood-fill a selected image with the current color"), NULL, CMDID_FLOODFILL }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Enable Threshold-based Flood and Replace Color"), NULL, N_("Enable flood fill and replace color to apply to colors similar to the selected pixel (+/- a threshold)"), NULL, CMDID_TOGGLEFLOODREPLACECOLORTHRESH }, { N_("Set Flood and Replace Color Threshold"), NULL, N_("Set flood fill and replace color threshold"), NULL, CMDID_SETFLOODREPLACECOLORTHRESH }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo fillReplaceMenuInfo={ TGMUTYPE_TEXT, fillReplaceMenuItemInfo, CreateImageProcMenu }; static TgMenuItemInfo imageProcMenuItemInfo[] = { { N_("Make Gray"), NULL, N_("Convert a selected image into gray-scale"), NULL, CMDID_MAKEGRAY }, { N_("Brighten/Darken..."), NULL, N_("Brighten or darken a selected image"), NULL, CMDID_BRIGHTENDARKEN }, { N_("Contrast Enhance..."), NULL, N_("Adjust contrast of a selected image"), NULL, CMDID_CONTRASTENHANCE }, { N_("Gamma Correct..."), NULL, N_("Apply gamma correction a selected image"), NULL, CMDID_GAMMA }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Change Saturation..."), NULL, N_("Change saturation of a selected image"), NULL, CMDID_CHANGESATURATION }, { N_("Change Hue..."), NULL, N_("Change hue of a selected image"), NULL, CMDID_CHANGEHUE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Invert Color"), NULL, N_("Subtract every pixel of a selected image from White (in RGB-model)"), NULL, CMDID_INVERTCOLOR }, { N_("Interpolate Color..."), NULL, N_("Map pixel intensities of a selected image between two specified colors"), NULL, CMDID_INTERPOLATECOLOR }, { N_("Color Balance..."), NULL, N_("Balance the RGB components of a selected image"), NULL, CMDID_COLORBALANCE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Reduce Number Of Colors"), TGMUITEM_SUBMENU, N_("Reduce number of colors submenu >>>"), &reduceColorMenuInfo, INVALID }, { N_("Effects"), TGMUITEM_SUBMENU, N_("Effects submenu >>>"), &effectsMenuInfo, INVALID }, { N_("Generate"), TGMUITEM_SUBMENU, N_("Generate submenu >>>"), &generateMenuInfo, INVALID }, { N_("Flood Fill / Replace Colors"), TGMUITEM_SUBMENU, N_("Flood fill and replace colors submenu >>>"), &fillReplaceMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Regenerate Image"), NULL, N_("Regenerated a selected image"), NULL, CMDID_REGENERATEIMAGE }, { N_("Crop Image"), NULL, N_("Crop a selected image"), NULL, CMDID_CROPIMAGE }, { N_("Get Color"), NULL, N_("Pick a color from a selected image to be the current color"), NULL, CMDID_GETCOLOR }, { N_("Create Contour"), NULL, N_("Generate a contour from a point in a selected image"), NULL, CMDID_CREATECONTOUR }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Subtract"), NULL, N_("Subtract one image from another"), NULL, CMDID_SUBTRACT }, { N_("Alpha Combine"), NULL, N_("Combine 2 images using another image as the alpha channel"), NULL, CMDID_ALPHACOMBINE }, { N_("Xor Color"), NULL, N_("XOR the colors of one image into another"), NULL, CMDID_XORCOLORS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Vector Warp"), NULL, N_("Warp selected image in a specified direction for a specified amount"), NULL, CMDID_VECTORWARP }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo imageProcMenuInfo={ TGMUTYPE_TEXT, imageProcMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo driverMenuItemInfo[] = { { N_("Solve"), "Alt+s", N_("Escape to driver"), NULL, CMDID_SOLVE }, { N_("Simulate"), "Alt+y", N_("Escape to driver"), NULL, CMDID_SIMULATE }, { N_("Probe"), "Alt+b", N_("Escape to driver"), NULL, CMDID_PROBE }, { N_("Animate"), "Alt+u", N_("Escape to driver"), NULL, CMDID_ANIMATE }, { N_("Escape"), "Alt+x", N_("Escape to driver"), NULL, CMDID_ESCAPE }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo driverMenuInfo={ TGMUTYPE_TEXT, driverMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo browseMenuItemInfo[] = { { N_("Create Thumbnails"), NULL, N_("Create a thumbnail map of all object files"), NULL, CMDID_CREATETHUMBNAILS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Browse X Bitmap"), NULL, N_("Recursively read in all X11 bitmap files"), NULL, CMDID_BROWSEXBITMAP }, { N_("Browse X Pixmap"), NULL, N_("Recursively read in all X11 pixmap files"), NULL, CMDID_BROWSEXPIXMAP }, { N_("Browse Other..."), NULL, N_("Recursively read in all another type of files"), NULL, CMDID_BROWSEOTHER }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo browseMenuInfo={ TGMUTYPE_TEXT, browseMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo importMultipageTextMenuItemInfo[] = { { N_("Import Multipage Text File"), NULL, N_("Import a multipage text file"), NULL, CMDID_IMPORTMULTIPAGETEXTFILE }, { N_("Set Margins"), NULL, N_("Set margins for importing multipage text files"), NULL, CMDID_SETMARGINSONIMPORTTEXT }, { N_("Word Wrap"), NULL, N_("Turn word wrapping on and off for importing multipage text files"), NULL, CMDID_TOGGLEWORDWRAPONIMPORTTEXT }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo importMultipageTextMenuInfo={ TGMUTYPE_TEXT, importMultipageTextMenuItemInfo, CreateImportMutipageTextFileMenu }; static TgMenuItemInfo captureMenuItemInfo[] = { { N_("Screen Capture"), "Cntrl+1", N_("Capture a rectangular area of the screen"), NULL, CMDID_SCREENCAPTURE }, { N_("Full Screen Capture"), "Cntrl+2", N_("Capture the whole screen"), NULL, CMDID_FULLSCREENCAPTURE }, { N_("Delayed Full Screen Capture..."), NULL, N_("Capture the whole screen after a specified delay"), NULL, CMDID_DELAYEDFULLSCREENCAPTURE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Hide During Capture"), NULL, N_("Toggle between hiding and showing tgif during capture"), NULL, CMDID_TOGGLEHIDEDURINGCAPTURE }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo captureMenuInfo={ TGMUTYPE_TEXT, captureMenuItemInfo, CreateScreenCaptureMenu }; static TgMenuItemInfo importMenuItemInfo[] = { { N_("Import..."), "Alt+p", N_("Embed/Import another drawing"), NULL, CMDID_IMPORT }, { N_("Import X Bitmap..."), "Alt+Cntrl+.", N_("Embed/Import an X11 bitmap file"), NULL, CMDID_IMPORTXBITMAP }, { N_("Import X Pixmap..."), "Alt+Cntrl+,", N_("Embed/Import an X11 pixmap file"), NULL, CMDID_IMPORTXPIXMAP }, { N_("Import EPS File..."), "Alt+(", N_("Link to a PS/EPS file"), NULL, CMDID_IMPORTEPSFILE }, { N_("Import GIF File..."), NULL, N_("Embed/Import a GIF file"), NULL, CMDID_IMPORTGIFFILE }, { N_("Import PNG File..."), NULL, N_("Embed/Import a PNG file"), NULL, CMDID_IMPORTPNGFILE }, { N_("Import JPEG File..."), NULL, N_("Embed/Import a JPEG file"), NULL, CMDID_IMPORTJPEGFILE }, { N_("Import PBM File..."), NULL, N_("Embed/Import a PBM file"), NULL, CMDID_IMPORTPBMFILE }, { N_("Import PGM File..."), NULL, N_("Embed/Import a PGM file"), NULL, CMDID_IMPORTPGMFILE }, { N_("Import PPM File..."), NULL, N_("Embed/Import a PPM file"), NULL, CMDID_IMPORTPPMFILE }, { N_("Import Other File..."), NULL, N_("Embed/Import another type of file"), NULL, CMDID_IMPORTOTHERFILE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Embed EPS File..."), NULL, N_("Embed/Import a PS/EPS file"), NULL, CMDID_EMBEDEPSFILE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Link External JPEG File..."), NULL, N_("Link to an external JPEG file"), NULL, CMDID_LINKEXTJPEGFILE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Auto EPS Preview Bitmap"), NULL, N_("Auto-generate a preview bitmap for a PS/EPS file when embedding/importing it (if it does not have one already)."), NULL, CMDID_TOGGLEAUTOEPSPREVIEWBITMAP }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Paste From File..."), NULL, N_("Select a file and paste the content as text"), NULL, CMDID_PASTEFROMFILE }, { N_("Import Multipage Text File"), TGMUITEM_SUBMENU, N_("Import Multipage Text File submenu >>>"), &importMultipageTextMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Browse"), TGMUITEM_SUBMENU, N_("Browse submenu >>>"), &browseMenuInfo, INVALID }, { N_("Screen Capture"), TGMUITEM_SUBMENU, N_("Screen Capture submenu >>>"), &captureMenuInfo, INVALID }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo importMenuInfo={ TGMUTYPE_TEXT, importMenuItemInfo, CreateImportMenu }; static TgMenuItemInfo domainMenuItemInfo[] = { { N_("Change Domain..."), "Alt+*", N_("Change to a different domain"), NULL, CMDID_CHANGEDOMAIN }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Edit Domain Paths..."), NULL, N_("Edit domain paths"), NULL, CMDID_EDITDOMAINPATHS }, { N_("Select Default Domain..."), NULL, N_("Select the default domain"), NULL, CMDID_SELECTDEFAULTDOMAIN }, { N_("Add A Domain..."), NULL, N_("Add a new domain"), NULL, CMDID_ADDADOMAIN }, { N_("Delete A Domain..."), NULL, N_("Delete an existing domain"), NULL, CMDID_DELETEADOMAIN }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Reload Domain Info From X..."), NULL, N_("Reload domain information from X defaults"), NULL, CMDID_RELOADDOMAININFOFROMX }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo domainMenuInfo={ TGMUTYPE_TEXT, domainMenuItemInfo, CreateDomainMenu }; TgMenuInfo exportFormatMenuInfo={ TGMUTYPE_BITMAP, NULL, CreateExportFormatMenu }; static TgMenuItemInfo gifAnimateMenuItemInfo[] = { { N_("Export X Pixmap Deck To GIF"), NULL, N_("Export a deck of X11 pixmap images to an animated GIF file"), NULL, CMDID_EXPORTXPMDECKTOGIF }, { N_("Import GIF To X Pixmap Deck..."), NULL, N_("Import an animated GIF file into a deck of X11 pixmap images"), NULL, CMDID_IMPORTGIFTOXPMDECK }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo gifAnimateMenuInfo={ TGMUTYPE_TEXT, gifAnimateMenuItemInfo, TgCreateMenuFromMenuInfo }; TgMenuInfo recentFilesMenuInfo={ TGMUTYPE_TEXT, NULL, CreateRecentFilesMenu }; #ifdef _TGIF_DBG static TgMenuItemInfo mimeMenuItemInfo[] = { { N_("Fake User Agent..."), NULL, N_("Set 'UserAgent' to be used when making an HTTP request"), NULL, CMDID_FAKEUSERAGENT }, { N_("Fake Referer..."), NULL, N_("Set 'Referer' to be used when making an HTTP request"), NULL, CMDID_FAKEREFERER }, { N_("Toggle Keep Alive"), NULL, N_("Toggle between using Keep-Alive and non-Keep-Alive HTTP connections"), NULL, CMDID_TOGGLEKEEPALIVE }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo mimeMenuInfo={ TGMUTYPE_TEXT, mimeMenuItemInfo, TgCreateMenuFromMenuInfo }; #endif /* _TGIF_DBG */ static TgMenuItemInfo fileMenuItemInfo[] = { { N_("New"), "Cntrl+n", N_("Start with a blank/new drawing"), NULL, CMDID_NEW }, { N_("Open..."), "Cntrl+o", N_("Open an existing drawing"), NULL, CMDID_OPEN }, { N_("Import"), TGMUITEM_SUBMENU, "Import submenu >>>", &importMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Save"), "Cntrl+s", N_("Save current drawing"), NULL, CMDID_SAVE }, { N_("Save New..."), "Alt+Cntrl+s", N_("Save current drawing in a different file"), NULL, CMDID_SAVENEW }, { N_("Save Selected As..."), "Alt+~", N_("Save selected objects in a different file"), NULL, CMDID_SAVESELECTEDAS }, { N_("Save Pages As..."), NULL, N_("Save user-specified pages in a different file"), NULL, CMDID_SAVEPAGESAS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Print"), "Cntrl+p", N_("Print/export current drawing"), NULL, CMDID_PRINT }, { N_("Print/Export Format"), TGMUITEM_SUBMENU, N_("Select print/export format submenu >>>"), &exportFormatMenuInfo, INVALID }, { N_("Set HTML Export Template..."), NULL, N_("Specify a file to be used as a template for genearting HTML files"), NULL, CMDID_SETHTMLEXPORTTEMPLATE }, { N_("Print/Export In Color"), "Alt+Cntrl+k", N_("Toggle between color and black & white printing modes"), NULL, CMDID_TOGGLEBWCOLORPS }, { N_("Print With Cmd..."), "Cntrl+-", N_("Print/export current drawing with a specific command"), NULL, CMDID_PRINTWITHCMD }, { N_("Print Selected Objects"), NULL, N_("Print/export only selected objects"), NULL, CMDID_PRINTSELECTEDOBJS }, { N_("Print One Page"), NULL, N_("Print a page in a multipage drawing"), NULL, CMDID_PRINTONEPAGE }, { N_("Print Pages..."), NULL, N_("Print user-specified pages"), NULL, CMDID_PRINTPAGES }, { N_("Print One File Per Page..."), NULL, N_("Print into a separate file for each page"), NULL, CMDID_PRINTONEFILEPERPAGE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("GIF Animation"), TGMUITEM_SUBMENU, N_("GIFAnimation submenu >>>"), &gifAnimateMenuInfo, INVALID }, #ifdef _TGIF_DBG { N_("Mime"), TGMUITEM_SUBMENU, N_("Mime submenu >>>"), &mimeMenuInfo, INVALID }, #endif /* _TGIF_DBG */ { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Print Msg Buffer..."), NULL, N_("Display/save the contents of the message window"), NULL, CMDID_PRINTMSGBUFFER }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Set Export Pixel Trim..."), NULL, N_("Specify the number of pixels to trim when exporting"), NULL, CMDID_SETEXPORTPIXELTRIM }, { N_("Set Template..."), NULL, N_("Select a template file be used in STACKED page mode"), NULL, CMDID_SETTEMPLATE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Recent Files"), TGMUITEM_SUBMENU, N_("Recently used files submenu >>>"), &recentFilesMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Quit"), "Cntrl+q", N_("Exit <<PROGRAM_NAME>>"), NULL, CMDID_QUIT }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo fileMenuInfo={ TGMUTYPE_TEXT, fileMenuItemInfo, CreateFileMenu }; static TgMenuItemInfo transformMenuItemInfo[] = { { N_("Precise Scale..."), "Alt+)", N_("Scale selected objects"), NULL, CMDID_PRECISESCALE }, { "Precise Scale Everything...", NULL, N_("Scale everything"), NULL, CMDID_PRECISESCALEEVERYTHING }, { N_("Precise Rotate..."), NULL, N_("Rotate selected objects by a specified number of degrees"), NULL, CMDID_PRECISEROTATE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Restore Image Width & Height"), NULL, N_("Restore a seleted bitmap/pixmap/EPS object to its original dimension"), NULL, CMDID_RESTOREIMAGEWH }, { N_("No Transform"), NULL, N_("Get rid of transformations on selected simple objects"), NULL, CMDID_NOTRANSFORM }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo transformMenuInfo={ TGMUTYPE_TEXT, transformMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo bitPixmapMenuItemInfo[] = { { N_("Invert X Bitmap"), "Alt+Cntrl+f", N_("Invert pixels for selected bitmap objects"), NULL, CMDID_INVERTXBITMAP }, { N_("Cut Bit/Pixmap..."), "Alt+;", N_("Trim/scale a selected bitmap/pixmap object"), NULL, CMDID_CUTBITPIXMAP }, { N_("Break Up Bit/Pixmap..."), NULL, N_("Break selected bitmap/pixmap object into smaller objects"), NULL, CMDID_BREAKUPBITPIXMAP }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Remove Transparent Pixel For Pixmap..."), NULL, N_("Remove transparent pixels for selected pixmap objects"), NULL, CMDID_REMOVETRANSPIXEL }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Export Half Tone Bitmap"), NULL, N_("Use Floyd-Steinberg half-tone method when exporting an X11 bitmap file"), NULL, CMDID_EXPORTHALFTONEBITMAP }, { N_("Export Threshold Bitmap"), NULL, N_("Use simple thresholding method when exporting an X11 bitmap file"), NULL, CMDID_EXPORTTHRESHOLDBITMAP }, { N_("Set Export Bitmap Threshold..."), NULL, N_("Set bitmap threshold value for the simple thresholding method"), NULL, CMDID_SETEXPORTBITMAPTHRESHOLD }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Update EPS"), NULL, N_("Refresh a selected EPS object"), NULL, CMDID_UPDATEEPS }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo bitPixmapMenuInfo={ TGMUTYPE_TEXT, bitPixmapMenuItemInfo, CreateBitPixmapMenu }; static TgMenuItemInfo addTickMarksMenuItemInfo[] = { { N_("Set Tick Mark Size..."), NULL, N_("Set the size of tick marks for various commands"), NULL, CMDID_SETTICKMARKSIZE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Add Squares"), NULL, N_("Add square tick marks at vertices of selected polys/polygons/splines"), NULL, CMDID_ADDSQUARETICKMARKS }, { N_("Add Triangles"), NULL, N_("Add triangle tick marks at vertices of selected polys/polygons/splines"), NULL, CMDID_ADDTRIANGLETICKMARKS }, { N_("Add Circles"), NULL, N_("Add circle tick marks at vertices of selected polys/polygons/splines"), NULL, CMDID_ADDCIRCLETICKMARKS }, { N_("Add Xs"), NULL, N_("Add X tick marks at vertices of selected polys/polygons/splines"), NULL, CMDID_ADDXTICKMARKS }, { N_("Add Diamonds"), NULL, N_("Add diamond tick marks at vertices of selected polys/polygons/splines"), NULL, CMDID_ADDDIAMONDTICKMARKS }, { N_("Add Bowties"), NULL, N_("Add bowtie tick marks at vertices of selected polys/polygons/splines"), NULL, CMDID_ADDBOWTIETICKMARKS }, { N_("Add Inverted Triangles"), NULL, N_("Add inverted triangle tick marks at vertices of selected polys/polygons/splines"), NULL, CMDID_ADDINVTRIANGLETICKMARKS }, { N_("Add Plus"), NULL, N_("Add plus tick marks at vertices of selected polys/polygons/splines"), NULL, CMDID_ADDPLUSTICKMARKS }, { N_("Add Hour Glasss"), NULL, N_("Add hour glass tick marks at vertices of selected polys/polygons/splines"), NULL, CMDID_ADDHOURGLASSTICKMARKS }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo addTickMarksMenuInfo={ TGMUTYPE_TEXT, addTickMarksMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo polyMenuItemInfo[] = { { N_("Delete Point"), "Alt+Cntrl+d", N_("Delete vertices from a poly/polygon/spline"), NULL, CMDID_DELETEPOINT }, { N_("Add Point"), "Alt+Cntrl+a", N_("Add vertices to a polygon/polygon/spline"), NULL, CMDID_ADDPOINT }, { N_("Extend Segment"), NULL, N_("Extend or shrink a line segment"), NULL, CMDID_EXTENDSEGMENT }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Convert Interpolated Spline"), NULL, N_("Convert selected interpolated splines to regular splines"), NULL, CMDID_CONVERTINTSPLINE }, { N_("Smooth<->Hinge"), NULL, N_("Toggle smooth/hinge vertices for a selected poly/polygon/spline"), NULL, CMDID_TOGGLESMOOTHHINGE }, #ifdef NOT_DEFINED { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Use Tighter Structured Splines"), NULL, N_("Toggle between tighter and looser structured splines"), NULL, CMDID_TOGGLETIGHTERSPLINES }, #endif /* NOT_DEFINED */ { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Convert To Bezier Curve"), NULL, N_("Convert selected splines to Bezier curves"), NULL, CMDID_CONVERTTOBEZIER }, { N_("Set Segments For Convert To Bezier..."), NULL, N_("Set the number of segments for the convert to Bezier command"), NULL, CMDID_SETBEZIERCONVERTNUMSEGS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Join Poly"), NULL, N_("Join polylines or open-splines at endpoints"), NULL, CMDID_JOINPOLY }, { N_("Cut Poly"), NULL, N_("Cut a poly/polygon at a vertex into two pieces"), NULL, CMDID_CUTPOLY }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Make Regular Polygon..."), "Alt+\"", N_("Make a selected polygon/closed spline into a regular one"), NULL, CMDID_MAKEREGPOLYGON }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Add Tick Marks"), TGMUITEM_SUBMENU, N_("Add Tick Marks submenu >>>"), &addTickMarksMenuInfo, INVALID }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo polyMenuInfo={ TGMUTYPE_TEXT, polyMenuItemInfo, CreatePolySplineMenu }; static TgMenuItemInfo textMenuItemInfo[] = { { N_("Break Up Text"), "Alt+#", N_("Break up selected text objects into one-character text objects"), NULL, CMDID_BREAKUPTEXT }, { N_("Set Text Fill Pattern Color"), NULL, N_("Set the fill pattern color of a text object to be the current color"), NULL, CMDID_SETTEXTFILLPATTERNCOLOR }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Insert Right Superscript"), "Alt+Cntrl+6", N_("Insert superscript to the right of the text cursor"), NULL, CMDID_INSERTRIGHTSUPERSCRIPT }, { N_("Insert Right Subscript"), "Alt+Cntrl+5", N_("Insert subscript to the right of the text cursor"), NULL, CMDID_INSERTRIGHTSUBSCRIPT }, { N_("Insert Left Superscript"), NULL, N_("Insert superscript to the left of the text cursor"), NULL, CMDID_INSERTLEFTSUPERSCRIPT }, { N_("Insert Left Subscript"), NULL, N_("Insert subscript to the left of the text cursor"), NULL, CMDID_INSERTLEFTSUBSCRIPT }, { N_("Insert Center Superscript"), NULL, N_("Insert superscript above the text cursor"), NULL, CMDID_INSERTCENTERSUPERSCRIPT }, { N_("Insert Center Subscript"), NULL, N_("Insert subscript below the text cursor"), NULL, CMDID_INSERTCENTERSUBSCRIPT }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Insert Symbol..."), NULL, N_("Insert a symbol from the Symbol Font"), NULL, CMDID_INSERTSYMBOL }, #ifdef _TGIF_DBG { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Insert Hex/Octal Character..."), NULL, N_("Insert a character using hex or octal code"), NULL, CMDID_INSERTHEXOCTALCHAR }, #endif /* _TGIF_DBG */ { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Reset input method..."), NULL, N_("Reset connection to the input method (in case it is stuck)"), NULL, CMDID_RESETINMETHOD }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Insert Thin Space..."), NULL, N_("Insert a think space at the text cursor"), NULL, CMDID_INSERTTHINSPACE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Insert Vertical Offset..."), NULL, N_("Insert a vertical offset at the text cursor"), NULL, CMDID_INSERTVERTICALOFFSET }, { N_("Remove Vertical Offset..."), NULL, N_("Remove any vertical offset at the text cursor"), NULL, CMDID_REMOVEVERTICALOFFSET }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Set Script Fraction..."), NULL, N_("Set the relative size of super/subscript text"), NULL, CMDID_SETSCRIPTFRACTION }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo textMenuInfo={ TGMUTYPE_TEXT, textMenuItemInfo, CreateEditTextMenu }; static TgMenuItemInfo createObjectMenuItemInfo[] = { { N_("Input Poly Pts"), NULL, N_("Read points from terminal and create a poly"), NULL, CMDID_INPUTPOLYPTS }, { N_("Input Polygon Pts"), NULL, N_("Read points from terminal and create a polygon"), NULL, CMDID_INPUTPOLYGONPTS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Add Tick Marks"), TGMUITEM_SUBMENU, N_("Add Tick Marks submenu >>>"), &addTickMarksMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Specify An Arc..."), "Alt+9", N_("Create and specify an arc"), NULL, CMDID_SPECIFYANARC }, { N_("Get Bounding Box"), NULL, N_("Get rectangular bounding boxes of selected objects"), NULL, CMDID_GETBOUNDINGBOX }, { N_("Create Rectangle From Bounding Box"), NULL, N_("Create a rectangle from the overall bounding box of selected objects"), NULL, CMDID_NEWRECTFROMBOUNDINGBOX }, { N_("Create Oval From Bounding Box"), NULL, N_("Create an oval from the overall bounding box of selected objects"), NULL, CMDID_NEWOVALFROMBOUNDINGBOX }, { N_("Create Rounded-corner Rectangle From Bounding Box"), NULL, N_("Create a rounded-corner rectangle from the overall bounding box of selected objects"), NULL, CMDID_NEWRCBOXFROMBOUNDINGBOX }, { N_("Create Pixmap From Selected"), NULL, N_("Create an X11 pixmap object from selected objects"), NULL, CMDID_CREATEPIXMAPFROMSEL }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo createObjectMenuInfo={ TGMUTYPE_TEXT, createObjectMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo editMenuItemInfo[] = { { N_("Redraw"), "Cntrl+r", N_("Redraw canvas window"), NULL, CMDID_REDRAW }, { N_("Duplicate"), "Cntrl+d", N_("Duplicate selected objects"), NULL, CMDID_DUPLICATE }, { N_("Delete"), NULL, N_("Delete selected objects"), NULL, CMDID_DELETE }, { N_("Select All"), "Cntrl+a", N_("Select all objects on the current page"), NULL, CMDID_SELECTALL }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Undo"), "Cntrl+z", N_("Undo the most recent command"), NULL, CMDID_UNDO }, { N_("Redo"), "Cntrl+y", N_("Redo the most undone command"), NULL, CMDID_REDO }, { N_("Flush Undo Buffer"), NULL, N_("Flush undo buffer and unused colors"), NULL, CMDID_FLUSHUNDOBUFFER }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Copy"), "Cntrl+c", N_("Copy selected objects into the cut buffer"), NULL, CMDID_COPY }, { N_("Copy Plain Text As Object"), NULL, N_("Copy highlighted plain text as an object into the cut buffer (to be pasted into Tgif)"), NULL, CMDID_COPYPLAINTEXTASOBJECT }, { N_("Cut"), NULL, N_("Cut selected objects into the cut buffer"), NULL, CMDID_CUT }, { N_("Paste"), "Cntrl+v", N_("Paste from the cut buffer"), NULL, CMDID_PASTE }, { N_("Paste From File..."), NULL, N_("Select a file and paste the content as text"), NULL, CMDID_PASTEFROMFILE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Copy Double-byte (UTF-8) String"), NULL, N_("Copy selected double-byte text string into the cut buffer (UTF-8) encoding"), NULL, CMDID_COPYUTF8 }, { N_("Paste Double-byte (UTF-8) String"), NULL, N_("Paste from the cut buffer (UTF-8 encoding) into a double-byte text object"), NULL, CMDID_PASTEUTF8 }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Generic Object Shadow"), TGMUITEM_SUBMENU, N_("Generic Object Shadow submenu >>>"), &objShadowMenuInfo, INVALID }, { N_("Shape"), TGMUITEM_PINNABLESUBMENU, N_("Shape submenu >>>"), &shapeMenuInfo, MENU_SHAPE }, { N_("Set Shape Shadow..."), NULL, N_("Specify the shadow for shapes"), NULL, CMDID_SETSHAPESHADOW }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Image Proc"), TGMUITEM_PINNABLESUBMENU, N_("ImageProc submenu >>>"), &imageProcMenuInfo, MENU_IMAGEPROC }, { N_("Properties"), TGMUITEM_PINNABLESUBMENU, N_("Properties submenu >>>"), &propertiesMenuInfo, MENU_PROPERTIES }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Transformation"), TGMUITEM_SUBMENU, N_("Transformation submenu >>>"), &transformMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Bitmap/Pixmap/EPS"), TGMUITEM_SUBMENU, N_("Bitmap/Pixmap/EPS submenu >>>"), &bitPixmapMenuInfo, INVALID }, { N_("Poly/Polygon"), TGMUITEM_SUBMENU, N_("Poly/Polygon submenu >>>"), &polyMenuInfo, INVALID }, { N_("Text"), TGMUITEM_SUBMENU, N_("Text submenu >>>"), &textMenuInfo, INVALID }, { N_("Create Object"), TGMUITEM_SUBMENU, N_("Create object submenu >>>"), &createObjectMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Push Current Choice"), "Cntrl+e", N_("Save/restore current drawing mode"), NULL, CMDID_PUSHCURCHOICE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Find Case Sensitive..."), "Alt+Cntrl+0", N_("Find string in visible text objects (case sensitive)"), NULL, CMDID_FINDCASESENSITIVE }, { N_("Find No Case..."), "Alt+Cntrl+9", N_("Find string in visible text objects (case insensitive)"), NULL, CMDID_FINDNOCASE }, { N_("Find Again"), "Alt+Cntrl+=", N_("Repeat the last Find command"), NULL, CMDID_FINDAGAIN }, /* { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("ConnectPins", NULL, "Connect pins", NULL, CMDID_CONNECTPINS }, */ { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo editMenuInfo={ TGMUTYPE_TEXT, editMenuItemInfo, CreateEditMenu }; static TgMenuItemInfo alignMenuItemInfo[] = { { N_("Align Objects Top"), "Alt+{", N_("Align top sides of selected objects"), NULL, CMDID_ALIGNOBJSTOP }, { N_("Align Objects Middle"), "Alt++", N_("Align vertical centers of selected objects"), NULL, CMDID_ALIGNOBJSMIDDLE }, { N_("Align Objects Bottom"), "Alt+}", N_("Align bottom sides of selected objects"), NULL, CMDID_ALIGNOBJSBOTTOM }, { N_("Align Objects Left"), "Alt+[", N_("Align left sides of selected objects"), NULL, CMDID_ALIGNOBJSLEFT }, { N_("Align Objects Center"), "Alt+=", N_("Align horizontal centers of selected objects"), NULL, CMDID_ALIGNOBJSCENTER }, { N_("Align Objects Right"), "Alt+]", N_("Align right sides of selected objects"), NULL, CMDID_ALIGNOBJSRIGHT }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Center An End Point"), NULL, N_("Move an endpoint of a selected poly to the center of another object"), NULL, CMDID_CENTERANENDPOINT }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo alignMenuInfo={ TGMUTYPE_TEXT, alignMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo sizeMenuItemInfo[] = { { N_("Size To Widest"), NULL, N_("Resize all selected objects to be as wide as the widest one"), NULL, CMDID_SIZETOWIDEST }, { N_("Size To Narrowest"), NULL, N_("Resize all selected objects to be as narrow as the narrowest one"), NULL, CMDID_SIZETONARROWEST }, { N_("Size To Tallest"), NULL, N_("Resize all selected objects to be as tall as the tallest one"), NULL, CMDID_SIZETOTALLEST }, { N_("Size To Shortest"), NULL, N_("Resize all selected objects to be as short as the shortest one"), NULL, CMDID_SIZETOSHORTEST }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Size To Given Width & Height..."), NULL, N_("Resize all selected objects to a specified width and height"), NULL, CMDID_SIZETOGIVENWIDTHHEIGHT }, { N_("Size To Given Width..."), NULL, N_("Resize all selected objects to a specified width"), NULL, CMDID_SIZETOGIVENWIDTH }, { N_("Size To Given Height..."), NULL, N_("Resize all selected objects to a specified height"), NULL, CMDID_SIZETOGIVENHEIGHT }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo sizeMenuInfo={ TGMUTYPE_TEXT, sizeMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuInfo alignObjsDirectMenuInfo={ TGMUTYPE_BITMAP, NULL, CreateAlignObjsDirectMenu }; static TgMenuInfo alignToGridDirectMenuInfo={ TGMUTYPE_BITMAP, NULL, CreateAlignToGridDirectMenu }; static TgMenuInfo alignToPageDirectMenuInfo={ TGMUTYPE_BITMAP, NULL, CreateAlignToPageDirectMenu }; static TgMenuInfo distrObjsDirectMenuInfo={ TGMUTYPE_BITMAP, NULL, CreateDistributeDirectMenu }; static TgMenuItemInfo autoRotatePivotMenuItemInfo[] = { { (char*)(&rotateModePixmap[AUTO_ROTATE_PIVOT]), NULL, N_("Set rotation pivot mode to automatic"), NULL, CMDID_CHOOSEROTATEPIVOT }, { (char*)(&rotateModePixmap[USER_ROTATE_PIVOT]), NULL, N_("Set rotation pivot mode to user-specified"), NULL, CMDID_CHOOSEROTATEPIVOT }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo autoRotatePivotMenuInfo={ TGMUTYPE_BITMAP, autoRotatePivotMenuItemInfo, CreateAutoRotatePivotMenu }; static TgMenuItemInfo moveStdRotatePivotMenuItemInfo[] = { { N_("Move Rotation Pivot To Center"), NULL, N_("Move rotation pivot to the center of selected objects"), NULL, CMDID_MOVEROTATEPIVOTCENTER }, { N_("Move Rotation Pivot To LeftTop Corner"), NULL, N_("Move rotation pivot to the left-top corner of selected objects"), NULL, CMDID_MOVEROTATEPIVOTLT }, { N_("Move Rotation Pivot To RightTop Corner"), NULL, N_("Move rotation pivot to the right-top corner of selected objects"), NULL, CMDID_MOVEROTATEPIVOTRT }, { N_("Move Rotation Pivot To LeftBottom Corner"), NULL, N_("Move rotation pivot to the left-bottom corner of selected objects"), NULL, CMDID_MOVEROTATEPIVOTLB }, { N_("Move Rotation Pivot To RightBottom Corner"), NULL, N_("Move rotation pivot to the right-bottom corner of selected objects"), NULL, CMDID_MOVEROTATEPIVOTRB }, { N_("Move Rotation Pivot To Left Center"), NULL, N_("Move rotation pivot to the left center of selected objects"), NULL, CMDID_MOVEROTATEPIVOTLEFT }, { N_("Move Rotation Pivot To Right Center"), NULL, N_("Move rotation pivot to the right center of selected objects"), NULL, CMDID_MOVEROTATEPIVOTRIGHT }, { N_("Move Rotation Pivot To Top Center"), NULL, N_("Move rotation pivot to the top center of selected objects"), NULL, CMDID_MOVEROTATEPIVOTTOP }, { N_("Move Rotation Pivot To Bottom Center"), NULL, N_("Move rotation pivot to the bottom center of selected objects"), NULL, CMDID_MOVEROTATEPIVOTBOTTOM }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo rotatePivotMenuInfo={ TGMUTYPE_TEXT, moveStdRotatePivotMenuItemInfo, CreateMoveStdRotatePivotMenu }; static TgMenuItemInfo flipRotateMenuItemInfo[] = { { N_("Flip Horizontal"), "Alt+h", N_("Flip selected objects horizontally"), NULL, CMDID_FLIPHORIZONTAL }, { N_("Flip Vertical"), "Alt+v", N_("Flip selected objects vertically"), NULL, CMDID_FLIPVERTICAL }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Rotate Clock-Wise"), "Alt+w", N_("Rotate selected objects clockwise"), NULL, CMDID_ROTATECLOCKWISE }, { N_("Rotate Counter"), "Alt+c", N_("Rotate selected objects counter-clockwise"), NULL, CMDID_ROTATECOUNTER }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Set Text Rotation..."), NULL, N_("Set text rotation in degrees"), NULL, CMDID_SETTEXTROTATION }, { N_("Set Rotation Increment..."), NULL, N_("Set rotation increment in degrees"), NULL, CMDID_SETROTATIONINCREMENT }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Rotation Pivot"), TGMUITEM_SUBMENU, N_("Rotation pivot submenu >>>"), &autoRotatePivotMenuInfo, INVALID }, { N_("Reset Rotation Pivot"), NULL, N_("Reset user-specified rotation pivot to center of selected objects"), NULL, CMDID_RESETROTATEPIVOT }, { N_("Speficy Rotation Pivot..."), NULL, N_("Specify the coordinates for the user-specified rotation pivot"), NULL, CMDID_SPECIFYROTATEPIVOT }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Next Poly/Polygon Rotation Pivot"), NULL, N_("Move the rotation pivot to the next vertex of a poly/polygon object"), NULL, CMDID_NEXTPOLYROTATEPIVOT }, { N_("Move Rotation Pivot To Arc Center"), NULL, N_("Move the rotation pivot to the center of the circle which an arc object is part of"), NULL, CMDID_MOVEROTATEPIVOTARCCNTR }, { N_("Move Standard Rotation Pivot"), TGMUITEM_SUBMENU, N_("Move standard rotation pivot submenu >>>"), &rotatePivotMenuInfo, INVALID }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo flipRotateMenuInfo={ TGMUTYPE_TEXT, flipRotateMenuItemInfo, CreateFlipRotateMenu }; static TgMenuItemInfo arrangeMenuItemInfo[] = { { N_("Front"), "Cntrl+f", N_("Bring selected objects to the front"), NULL, CMDID_FRONT }, { N_("Back"), "Cntrl+b", N_("Send selected objects to the back"), NULL, CMDID_BACK }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Group"), "Cntrl+g", N_("Group selected objects into a compound object"), NULL, CMDID_GROUP }, { N_("UnGroup"), "Cntrl+u", N_("Break up selected grouped objects into its components"), NULL, CMDID_UNGROUP }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Lock"), "Alt+<", N_("Lock the positions of selected objects"), NULL, CMDID_LOCK }, { N_("UnLock"), "Alt+>", N_("UnLock the positions of selected objects"), NULL, CMDID_UNLOCK }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Horizontal Align"), TGMUITEM_PINNABLESUBMENU, N_("HoriAlign submenu >>>"), &horiAlignMenuInfo, MENU_HORIALIGN }, { N_("Vertical Align"), TGMUITEM_PINNABLESUBMENU, N_("VertAlign submenu >>>"), &vertAlignMenuInfo, MENU_VERTALIGN }, { N_("Align Objects"), "Cntrl+l", N_("Align selected objects with each other using the current alignments"), NULL, CMDID_ALIGNOBJS }, { N_("Align Objects Direct"), TGMUITEM_SUBMENU, N_("Align objects direct submenu >>>"), &alignObjsDirectMenuInfo, INVALID }, { N_("Align To Grid"), "Cntrl+t", N_("Align selected objects to grid points using the current alignments"), NULL, CMDID_ALIGNTOGRID }, { N_("Align To Grid Direct"), TGMUITEM_SUBMENU, N_("Align to grid direct submenu >>>"), &alignToGridDirectMenuInfo, INVALID }, { N_("Align To Page"), "Alt+&", N_("Align selected objects to the page using the current alignments"), NULL, CMDID_ALIGNTOPAGE }, { N_("Align To Page Direct"), TGMUITEM_SUBMENU, N_("Align to page direct submenu >>>"), &alignToPageDirectMenuInfo, INVALID }, { N_("More Object Alignments"), TGMUITEM_SUBMENU, N_("Align objects submenu >>>"), &alignMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Size Objects"), TGMUITEM_SUBMENU, N_("Size objects submenu >>>"), &sizeMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Distribute Objects"), "Alt+l", N_("Distribute selected objects using the current alignments"), NULL, CMDID_DISTRIBUTEOBJS }, { N_("Distribute Objects Direct"), TGMUITEM_SUBMENU, N_("Distribute objects direct submenu >>>"), &distrObjsDirectMenuInfo, INVALID }, { N_("Layout On Arc"), NULL, N_("Layout objects on an arc"), NULL, CMDID_LAYOUTONARC }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Abut Horizontal"), "Alt+_", N_("Squish selected objects together horizontally"), NULL, CMDID_ABUTHORIZONTAL }, { N_("Abut Vertical"), "Alt+|", N_("Squish selected objects together vertically"), NULL, CMDID_ABUTVERTICAL }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Flip/Rotate"), TGMUITEM_SUBMENU, N_("Flip and rotate submenu >>>"), &flipRotateMenuInfo, INVALID }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo arrangeMenuInfo={ TGMUTYPE_TEXT, arrangeMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo scrollModeMenuItemInfo[] = { { N_("Off"), NULL, N_("Do not update canvas window while scrolling"), NULL, CMDID_CHANGESCROLLMODE }, { N_("Jump"), NULL, N_("Jump update canvas window while scrolling"), NULL, CMDID_CHANGESCROLLMODE }, { N_("Smooth"), NULL, N_("Update canvas window smoothly while scrolling"), NULL, CMDID_CHANGESCROLLMODE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo scrollModeMenuInfo={ TGMUTYPE_TEXT, scrollModeMenuItemInfo, CreateScrollModeMenu }; static TgMenuItemInfo showHideMenuItemInfo[] = { { N_("Show Bit/Pixmap"), NULL, N_("Toggle between hiding and showing detailed bitmap/pixmap objects"), NULL, CMDID_TOGGLEMAPSHOWN }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Show Measurement"), NULL, N_("Show cursor measurements"), NULL, CMDID_TOGGLESHOWMEASUREMENT }, { N_("Show Measurement in Tooltip"), NULL, N_("Show cursor measurements in tooltip"), NULL, CMDID_TOGGLESHOWMEASUREMENTINTT }, { N_("Set Measure Unit..."), NULL, N_("Set the unit of measurements"), NULL, CMDID_SETMEASUREUNIT }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Enable Right Margin"), NULL, N_("Toggle between using (simple) right margin or not"), NULL, CMDID_TOGGLERIGHTMARGIN }, { N_("Specify Right Margin..."), NULL, N_("Specify the (simple) right margin"), NULL, CMDID_SPECIFYRIGHTMARGIN }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Show Menubar"), NULL, N_("Show menubar window"), NULL, CMDID_TOGGLESHOWMENUBAR }, { N_("Show Choice"), NULL, N_("Show choice and message window"), NULL, CMDID_TOGGLESHOWCHOICEBAR }, { N_("Show Status"), NULL, N_("Show status window"), NULL, CMDID_TOGGLESHOWSTATUS }, { N_("Show Mode"), NULL, N_("Show mode window"), NULL, CMDID_TOGGLESHOWMODE }, { N_("Show Chat"), NULL, N_("Show chat window"), NULL, CMDID_TOGGLESHOWCHAT }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo showHideMenuInfo={ TGMUTYPE_TEXT, showHideMenuItemInfo, CreateShowHideMenu }; static TgMenuItemInfo slideShowModeMenuItemInfo[] = { { N_("Go HyperSpace In Slide Show"), NULL, N_("Enter HyperSpace mode in slideshow"), NULL, CMDID_GOHYPERSPACEINSLIDESHOW }, { N_("Freehand Mode In Slide Show"), NULL, N_("Go into freehand drawing mode in slideshow"), NULL, CMDID_FREEHANDMODEINSLIDESHOW }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Next Slide"), NULL, N_("Go to next slide"), NULL, CMDID_NEXTPAGE }, { N_("Prev Slide"), NULL, N_("Go to previous slide"), NULL, CMDID_PREVPAGE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Color"), TGMUITEM_PINNABLESUBMENU, N_("Color Menu"), &colorMenuInfo, MENU_COLOR }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Exit Slide Show Mode"), "Esc", N_("Exit SlideShow mode"), NULL, CMDID_TOGGLESLIDESHOW }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo slideShowModeMenuInfo={ TGMUTYPE_TEXT, slideShowModeMenuItemInfo, CreateSlideShowModeMenu }; static TgMenuItemInfo slideShowMenuItemInfo[] = { { N_("Slide Show"), "Alt+Cntrl+8", N_("Toggle SlideShow mode"), NULL, CMDID_TOGGLESLIDESHOW }, { N_("Set Slide Show Border Color..."), NULL, N_("Set the color of the slideshow border"), NULL, CMDID_SETSLIDESHOWBRDRCOLOR }, { N_("Set Slide Show Window Offsets..."), NULL, N_("Set the offsets of the slideshow window"), NULL, CMDID_SETSLIDESHOWWINOFFSETS }, { N_("Visible Grid In Slide Show"), NULL, N_("Toggle visible grid in slideshow mode"), NULL, CMDID_VISIBLEGRIDINSLIDESHOW }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Go HyperSpace In Slide Show"), NULL, N_("Enter HyperSpace mode in slideshow"), NULL, CMDID_GOHYPERSPACEINSLIDESHOW }, { N_("Freehand Mode In Slide Show"), NULL, N_("Go into freehand drawing mode in slideshow"), NULL, CMDID_FREEHANDMODEINSLIDESHOW }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo slideShowMenuInfo={ TGMUTYPE_TEXT, slideShowMenuItemInfo, CreateSlideShowMenu }; static TgMenuItemInfo zoomMenuItemInfo[] = { { N_("Zoom In"), "Alt+z", N_("Zoom in"), NULL, CMDID_ZOOMIN }, { N_("Zoom Out"), "Alt+o", N_("Zoom out"), NULL, CMDID_ZOOMOUT }, { N_("Default Zoom"), "Alt+:", N_("No zoom"), NULL, CMDID_DEFAULTZOOM }, { N_("Zoom Way Out"), "Alt+`", N_("Zoom way out to see the whole drawing"), NULL, CMDID_ZOOMWAYOUT }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo zoomMenuInfo={ TGMUTYPE_TEXT, zoomMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo layoutMenuItemInfo[] = { { N_("+Grid"), "Alt+i", N_("Increment grid size"), NULL, CMDID_INCGRID }, { N_("-Grid"), "Alt+d", N_("Decrement grid size"), NULL, CMDID_DECGRID }, { N_("Visible Grid"), "Alt+g", N_("Hide/show grid lines"), NULL, CMDID_TOGGLEGRID }, { N_("Snap To Grid"), "Alt+Cntrl+g", N_("Toggle the snapping to grid points effect"), NULL, CMDID_TOGGLESNAP }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Save Origin"), NULL, N_("Save current location as the 'origin' of the drawing"), NULL, CMDID_SAVEORIGIN }, { N_("Scroll To Origin"), "Alt+^", N_("Scroll to the 'origin' of the drawing"), NULL, CMDID_SCROLLTOORIG }, { N_("Scroll Mode"), TGMUITEM_SUBMENU, N_("ScrollMode submenu >>>"), &scrollModeMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Zoom"), TGMUITEM_SUBMENU, N_("Zoom submenu >>>"), &zoomMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Portrait"), NULL, N_("Portrait page style"), NULL, CMDID_PORTRAITMODE }, { N_("Landscape"), NULL, N_("Lanscape page style"), NULL, CMDID_LANDSCAPEMODE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Stacked Page"), TGMUITEM_PINNABLESUBMENU, N_("StackedPage submenu >>>"), &stackedPageMenuInfo, MENU_STACKEDPAGE }, { N_("Tiled Page"), TGMUITEM_PINNABLESUBMENU, N_("TiledPage submenu >>>"), &tiledPageMenuInfo, MENU_TILEDPAGE }, { N_("Page Layout"), TGMUITEM_PINNABLESUBMENU, N_("PageLayout submenu >>>"), &pageLayoutMenuInfo, MENU_PAGELAYOUT }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Print/Export Format"), TGMUITEM_SUBMENU, N_("Select print/export format submenu >>>"), &exportFormatMenuInfo, INVALID }, { N_("Print/Export In Color"), "Alt+Cntrl+k", N_("Toggle between color and black & white printing modes"), NULL, CMDID_TOGGLEBWCOLORPS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Set Reduction..."), "Alt+%", N_("Specify reduction/magnification of the whole drawing"), NULL, CMDID_SETREDUCTION }, { N_("Metric Grid"), "Alt+Cntrl+-", N_("Toggle between English and Metric grid systems"), NULL, CMDID_TOGGLEGRIDSYSTEM }, { N_("One Motion Select Move"), NULL, N_("Toggle between click-select-move and click-select-click-move modes"), NULL, CMDID_TOGGLEONEMOTIONSELMOVE }, { N_("Use Gray Scale"), NULL, N_("Toggle between using gray scales to tile patterns to speed up printing"), NULL, CMDID_TOGGLEUSEGRAYSCALE }, { N_("Use Color Layers"), NULL, N_("Toggle color layers"), NULL, CMDID_TOGGLECOLORLAYERS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Show/Hide"), TGMUITEM_SUBMENU, N_("Show/Hide submenu >>>"), &showHideMenuInfo, INVALID }, { N_("Slide Show"), TGMUITEM_SUBMENU, N_("SlideShow submenu >>>"), &slideShowMenuInfo, INVALID }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo layoutMenuInfo={ TGMUTYPE_TEXT, layoutMenuItemInfo, CreateLayoutMenu }; static TgMenuItemInfo propertiesMenuItemInfo[] = { { N_("Copy Properties..."), NULL, N_("Copy properties (e.g., color, fill, etc.) into the cut buffer"), NULL, CMDID_COPYPROPERTIES }, { N_("Paste Properties..."), NULL, N_("Paste properties (e.g., color, fill, etc.) from the cut buffer"), NULL, CMDID_PASTEPROPERTIES }, { N_("Save Properties..."), NULL, N_("Save and name a property (e.g., color, fill, etc.) set"), NULL, CMDID_SAVEPROPERTIES }, { N_("Restore Properties..."), NULL, N_("Restore a named property (e.g., color, fill, etc.) set"), NULL, CMDID_RESTOREPROPERTIES }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, /* * { N_("Update Objects"), "Alt+0", * N_("Update selected objects to have current drawing properties"), NULL, * CMDID_UPDATE }, * { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, */ { N_("Set Selected Line Width..."), NULL, N_("Change the line width (and arrow width/height) of selected objects"), NULL, CMDID_SETSELLINEWIDTH }, { N_("Set Selected Font Size..."), NULL, N_("Change the font size of selected objects"), NULL, CMDID_SETSELFONTSIZE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Add Color..."), NULL, N_("Add colors to the current palette"), NULL, CMDID_ADDCOLOR }, { N_("Choose Color..."), NULL, N_("Choose a color from a color wheel and add it to the current palette"), NULL, CMDID_COLORWHEEL }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Set Edit Text Size..."), NULL, N_("Set the text size to be used in editing existing text objects"), NULL, CMDID_SETEDITTEXTSIZE }, { N_("Set Alt Edit Text BgColor..."), NULL, N_("Set the background color to be used in editing existing text objects"), NULL, CMDID_SETALTEDITTEXTBGCOLOR }, { N_("Set Alt Edit Text Highlight Color..."), NULL, N_("Set the highlight color to be used in editing existing text objects"), NULL, CMDID_SETALTEDITTEXTHIGHLIGHTCOLOR }, { N_("Use Alt Edit Text BgColor"), NULL, N_("Toggles the background color to be used in editing existing text objects"), NULL, CMDID_TOGGLEALTEDITTEXTBGCOLOR }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Font"), TGMUITEM_PINNABLESUBMENU, N_("Font submenu >>>"), &fontMenuInfo, MENU_FONT }, { N_("Text Style"), TGMUITEM_PINNABLESUBMENU, N_("TextStyle submenu >>>"), &fontStyleMenuInfo, MENU_STYLE }, { N_("Text Size"), TGMUITEM_PINNABLESUBMENU, N_("TextSize submenu >>>"), &fontSizeMenuInfo, MENU_SIZE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Line Dash"), TGMUITEM_PINNABLESUBMENU, N_("LineDash submenu >>>"), &lineDashMenuInfo, MENU_LINEDASH }, { N_("Line Style"), TGMUITEM_PINNABLESUBMENU, N_("LineStyle submenu >>>"), &lineStyleMenuInfo, MENU_LINESTYLE }, { N_("Line Type"), TGMUITEM_PINNABLESUBMENU, N_("LineType submenu >>>"), &lineTypeMenuInfo, MENU_LINETYPE }, { N_("Line Width"), TGMUITEM_PINNABLESUBMENU, N_("LineWidth submenu >>>"), &lineWidthMenuInfo, MENU_LINEWIDTH }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Fill"), TGMUITEM_PINNABLESUBMENU, N_("Fill submenu >>>"), &fillMenuInfo, MENU_FILL }, { N_("Pen"), TGMUITEM_PINNABLESUBMENU, N_("Pen submenu >>>"), &penMenuInfo, MENU_PEN }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Color"), TGMUITEM_PINNABLESUBMENU, N_("Color submenu >>>"), &colorMenuInfo, MENU_COLOR }, { N_("Transparent Pattern"), TGMUITEM_PINNABLESUBMENU, N_("TransPattern submenu >>>"), &transPatModeMenuInfo, MENU_TRANSPAT }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo propertiesMenuInfo={ TGMUTYPE_TEXT, propertiesMenuItemInfo, CreatePropertiesMenu }; static TgMenuItemInfo navigateMenuItemInfo[] = { { N_("Go Back"), NULL, N_("Go back one file"), NULL, CMDID_GOBACK }, { N_("Go Forward"), NULL, N_("Go forward one file"), NULL, CMDID_GOFORWARD }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Refresh Current"), NULL, N_("Reload the current file"), NULL, CMDID_REFRESHCURRENT }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Hot List..."), NULL, N_("Navigate using the hot-list"), NULL, CMDID_HOTLIST }, { N_("Add Current To Hot List"), NULL, N_("Add the current file to the hot-list"), NULL, CMDID_ADDCURRENTTOHOTLIST }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Session History..."), NULL, N_("Go to a file visited during this session"), NULL, CMDID_SESSIONHISTORY }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Hyper Space"), NULL, N_("Toggle HyperSpace mode"), NULL, CMDID_TOGGLEHYPERSPACE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo navigateMenuInfo={ TGMUTYPE_TEXT, navigateMenuItemInfo, CreateNavigateMenu }; static TgMenuItemInfo attrMenuItemInfo[] = { { N_("Attach Attributes"), "Alt+a", N_("Attach selected text objects as attributes for the non-text object"), NULL, CMDID_ATTACHATTRS }, { N_("Detach Attributes"), "Alt+t", N_("Detach all attributes of selected objects"), NULL, CMDID_DETACHATTRS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Edit Attributes..."), NULL, N_("Edit attributes of a selected object"), NULL, CMDID_EDITATTRS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Show Attributes"), "Alt+-", N_("Make all attributes of selected objects visible"), NULL, CMDID_SHOWATTR }, { N_("Show Attribute Names"), "Alt+n", N_("Make all attribute names of selected objects visible"), NULL, CMDID_SHOWATTRNAME }, { N_("Hide Attributes"), "Alt+Cntrl+h", N_("Hide all attributes for selected objects"), NULL, CMDID_HIDEATTR }, { N_("Hide Attribute Names"), "Alt+j", N_("Hide all attribute names for selected objects"), NULL, CMDID_HIDEATTRNAME }, { N_("Toggle Eq Attribute Shown..."), "Alt+Cntrl+7", N_("Showing/hiding the 'eq=' attibute (for a LaTeX equation object)"), NULL, CMDID_TOGGLEEQATTRSHOWN }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Move/Justfy An Attribute"), "Alt+m", N_("Move/justify an attribute for a selected object"), NULL, CMDID_MOVEJUSTIFYATTR }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Import Attributes..."), NULL, N_("Import attributes of a selected object from a text file"), NULL, CMDID_IMPORTATTRS }, { N_("Export Attributes..."), NULL, N_("Export attributes of a selected object to a text file"), NULL, CMDID_EXPORTATTRS }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo attrMenuInfo={ TGMUTYPE_TEXT, attrMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo fileAttrMenuItemInfo[] = { { N_("Attach File Attributes"), NULL, N_("Attach selected text objects as file attributes"), NULL, CMDID_ATTACHFILEATTRS }, { N_("Detach File Attributes"), NULL, N_("Detach all file attributes"), NULL, CMDID_DETACHFILEATTRS }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Edit File Attributes..."), NULL, N_("Edit file attributes"), NULL, CMDID_EDITFILEATTRS }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo fileAttrMenuInfo={ TGMUTYPE_TEXT, fileAttrMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo animateMenuItemInfo[] = { { N_("Animate Send"), "Alt+e", N_("Animate a little token on a selected poly (not very useful)"), NULL, CMDID_ANIMATESEND }, { N_("Animate Flash"), "Alt+f", N_("Flash a selected poly (not very useful)"), NULL, CMDID_ANIMATEFLASH }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Renumber Object IDs"), "Alt+f", N_("Renumber object IDs for all objects"), NULL, CMDID_RENUMBER_OBJECT_IDS }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo animateMenuInfo={ TGMUTYPE_TEXT, animateMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo portMenuItemInfo[] = { { N_("Connect Two Ports by a Wire..."), NULL, N_("Connect two ports by a wire"), NULL, CMDID_CONNECT2PORTSBYWIRE }, { N_("Repeat Connect Two Ports by a Wire..."), NULL, N_("Repeatedly connecting two ports by a wire (will not prompt if the wire name can be detected). Wire signal name will not be shown."), NULL, CMDID_REPEATCONNECT2PORTSBYWIRE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Show Wire Signal Name"), NULL, N_("Toggle between showing (with placing) and hiding the wire signal name when connecting ports"), NULL, CMDID_TOGGLESHOWWIRESIGNALNAME }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Merge Ports with An Object"), NULL, N_("Merge selected floating port objects with a selected composite object"), NULL, CMDID_MERGEPORTSWITHANOBJECT }, { N_("Connect Ports to a Broadcast Wire"), NULL, N_("Connect selected floating port objects to a selected broadcast-type wire"), NULL, CMDID_CONNECTPORTSTOBROADCAST }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Clear Signal Name for a Port..."), NULL, N_("Clear the 'signal_name=' attribute for a port"), NULL, CMDID_CLEARSIGNAMEFORAPORT }, { N_("Rename Signal Name for a Port..."), NULL, N_("Rename the 'signal_name=' attribute for a port"), NULL, CMDID_RENAMESIGNAMEFORAPORT }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo portMenuInfo={ TGMUTYPE_TEXT, portMenuItemInfo, CreatePortMenu }; static TgMenuItemInfo tableMenuItemInfo[] = { { N_("Merge With Table..."), NULL, N_("Merge selected object with a table file"), NULL, CMDID_MERGEWITHTABLE }, { N_("Export To Table..."), NULL, N_("Export attributes of selected objects to a table file"), NULL, CMDID_EXPORTTOTABLE }, { NULL, NULL, NULL, NULL, INVALID } }; static TgMenuInfo tableMenuInfo={ TGMUTYPE_TEXT, tableMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo specialMenuItemInfo[] = { { N_("Make Symbolic"), "Alt+Cntrl+m", N_("Turn a selected grouped/icon object into a symbol object"), NULL, CMDID_MAKESYMBOLIC }, { N_("UnMake Symbolic"), "Alt+Cntrl+n", N_("Turn a selected symbol object into a grouped object"), NULL, CMDID_UNMAKESYMBOLIC }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Instantiate..."), "Cntrl+i", N_("Instantiate a building-block object from the current domain"), NULL, CMDID_INSTANTIATE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Make Iconic..."), "Alt+Cntrl+i", N_("Turn a selected grouped/symbol object into an icon object"), NULL, CMDID_MAKEICONIC }, { N_("UnMake Iconic"), "Alt+Cntrl+j", N_("Turn an icon object into a grouped object"), NULL, CMDID_UNMAKEICONIC }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Push"), "Alt+Cntrl+y", N_("Push into (edit) the symbol file which defines the selected icon object"), NULL, CMDID_PUSH }, { N_("Pop"), "Cntrl+k", N_("Pop back to a high lever (reverse of Push)"), NULL, CMDID_POP }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Attribute"), TGMUITEM_SUBMENU, N_("Attribute submenu >>>"), &attrMenuInfo, INVALID }, { N_("File Attribute"), TGMUITEM_SUBMENU, N_("File attribute submenu >>>"), &fileAttrMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Update Symbols"), "Alt+Cntrl+u", N_("Refresh selected icon objects from their definition files"), NULL, CMDID_UPDATESYMBOLS }, { N_("Save Sym In Library..."), NULL, N_("Save symbol file in a library path within the current domain"), NULL, CMDID_SAVESYMINLIBRARY }, { N_("Replace Graphic"), NULL, N_("Replace the graphical part of selected objects by the graphical object in the cut buffer"), NULL, CMDID_REPLACEGRAPHIC }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Domain"), TGMUITEM_SUBMENU, N_("Domain submenu >>>"), &domainMenuInfo, INVALID }, { N_("Ports and Signals"), TGMUITEM_SUBMENU, N_("Ports and Signal submenu >>>"), &portMenuInfo, INVALID }, { N_("Table"), TGMUITEM_SUBMENU, N_("Table submenu >>>"), &tableMenuInfo, INVALID }, { N_("Misc"), TGMUITEM_SUBMENU, N_("Misc submenu >>>"), &animateMenuInfo, INVALID }, { N_("Return"), TGMUITEM_SUBMENU, N_("Return submenu >>>"), &driverMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Exec Cmds From File..."), NULL, N_("Execute internal commands from a file"), NULL, CMDID_EXECCMDSFROMFILE }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo specialMenuInfo={ TGMUTYPE_TEXT, specialMenuItemInfo, TgCreateMenuFromMenuInfo }; static TgMenuItemInfo helpMenuItemInfo[] = { { N_("Latest Release Info"), NULL, N_("Find out what is the version number of the most recently released tgif"), NULL, CMDID_LATESTRELEASEINFO }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Copyright"), NULL, N_("Copyright information"), NULL, CMDID_COPYRIGHT }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("About"), NULL, N_("Version information, where to send bug reports, etc."), NULL, CMDID_ABOUT }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo helpMenuInfo={ TGMUTYPE_TEXT, helpMenuItemInfo, TgCreateMenuFromMenuInfo }; /* ------------------ context menu ------------------ */ TgMenuInfo editAttrInEditorMenuInfo={ TGMUTYPE_TEXT, NULL, CreateEditAttrInEditorMenu }; TgMenuInfo editAttrGroupInEditorMenuInfo={ TGMUTYPE_TEXT, NULL, CreateEditAttrGroupInEditorMenu }; TgMenuInfo getPropertyMenuInfo={ TGMUTYPE_TEXT, NULL, CreateGetPropertyMenu }; TgMenuInfo peekDimensionMenuInfo={ TGMUTYPE_TEXT, NULL, CreatePeekDimensionMenu }; static TgMenuItemInfo baseContextMenuItemInfo[] = { { N_("Mode"), TGMUITEM_PINNABLESUBMENU, N_("Mode Menu"), &modeMenuInfo, MENU_MODE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Copy"), "Cntrl+c", N_("Copy selected objects into the cut buffer"), NULL, CMDID_COPY }, { N_("Duplicate"), "Cntrl+d", N_("Duplicate selected objects"), NULL, CMDID_DUPLICATE }, { N_("Delete"), "Cntrl+x", N_("Delete selected objects"), NULL, CMDID_DELETE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Properties"), TGMUITEM_PINNABLESUBMENU, N_("Properties Menu"), &propertiesMenuInfo, MENU_PROPERTIES }, { N_("Image Proc"), TGMUITEM_PINNABLESUBMENU, N_("ImageProc Menu"), &imageProcMenuInfo, MENU_IMAGEPROC }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Edit Attribute In Editor"), TGMUITEM_SUBMENU, N_("Edit attribute in editor submenu >>>"), &editAttrInEditorMenuInfo, INVALID }, { N_("Edit Attribute Group In Editor"), TGMUITEM_SUBMENU, N_("Edit a group of attributes in editor submenu >>>"), &editAttrGroupInEditorMenuInfo, INVALID }, { N_("Get Property"), TGMUITEM_SUBMENU, N_("Get property submenu >>>"), &getPropertyMenuInfo, INVALID }, { N_("Peek Dimension"), TGMUITEM_SUBMENU, N_("Peek dimension submenu >>>"), &peekDimensionMenuInfo, INVALID }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo baseContextMenuInfo={ TGMUTYPE_TEXT, baseContextMenuItemInfo, CreateContextMenu }; static TgMenuItemInfo editTextContextMenuItemInfo[] = { { N_("Mode"), TGMUITEM_PINNABLESUBMENU, N_("Mode Menu"), &modeMenuInfo, MENU_MODE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Copy"), "Cntrl+c", N_("Copy selected objects into the cut buffer"), NULL, CMDID_COPY }, { N_("Copy Plain Text As Object"), NULL, N_("Copy highlighted plain text as an object into the cut buffer"), NULL, CMDID_COPYPLAINTEXTASOBJECT }, { N_("Cut"), NULL, N_("Cut selected text into the cut buffer"), NULL, CMDID_CUT }, { N_("Paste"), "Cntrl+v", N_("Paste from the cut buffer"), NULL, CMDID_PASTE }, { N_("Duplicate"), "Cntrl+d", N_("Duplicate selected objects"), NULL, CMDID_DUPLICATE }, { N_("Delete"), "Cntrl+x", N_("Delete selected objects"), NULL, CMDID_DELETE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Move Edit Text Box..."), NULL, N_("Move the edit text box"), NULL, CMDID_MOVEEDITTEXTBOX }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Properties"), TGMUITEM_PINNABLESUBMENU, N_("Properties Menu"), &propertiesMenuInfo, MENU_PROPERTIES }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo editTextContextMenuInfo={ TGMUTYPE_TEXT, editTextContextMenuItemInfo, CreateEditTextContextMenu }; /* ------------------ grid menu ------------------ */ static TgMenuItemInfo gridMenuItemInfo[] = { { N_("+Grid"), "Alt+i", N_("Increment grid size"), NULL, CMDID_INCGRID }, { N_("-Grid"), "Alt+d", N_("Decrement grid size"), NULL, CMDID_DECGRID }, { N_("Visible Grid"), "Alt+g", N_("Hide/show grid lines"), NULL, CMDID_TOGGLEGRID }, { N_("Snap To Grid"), "Alt+Cntrl+g", N_("Toggle the snapping to grid points effect"), NULL, CMDID_TOGGLESNAP }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Save Origin"), NULL, N_("Save current location as the 'origin' of the drawing"), NULL, CMDID_SAVEORIGIN }, { N_("Scroll To Origin"), "Alt+^", N_("Scroll to the 'origin' of the drawing"), NULL, CMDID_SCROLLTOORIG }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Zoom"), TGMUITEM_SUBMENU, N_("Zoom submenu >>>"), &zoomMenuInfo, INVALID }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Set Reduction..."), "Alt+%", N_("Specify reduction/magnification of the whole drawing"), NULL, CMDID_SETREDUCTION }, { N_("Metric Grid"), "Alt+Cntrl+-", N_("Toggle between English and Metric grid systems"), NULL, CMDID_TOGGLEGRIDSYSTEM }, { N_("Enable Right Margin"), NULL, N_("Toggle between using (simple) right margin or not"), NULL, CMDID_TOGGLERIGHTMARGIN }, { N_("Specify Right Margin..."), NULL, N_("Specify the (simple) right margin"), NULL, CMDID_SPECIFYRIGHTMARGIN }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo gridMenuInfo={ TGMUTYPE_TEXT, gridMenuItemInfo, CreateGridMenu }; /* ------------------ main menu ------------------ */ static TgMenuItemInfo mainMenuItemInfo[] = { { N_("File"), TGMUITEM_PINNABLESUBMENU, N_("File Menu"), &fileMenuInfo, MENU_FILE }, { N_("Edit"), TGMUITEM_PINNABLESUBMENU, N_("Edit Menu"), &editMenuInfo, MENU_EDIT }, { N_("Layout"), TGMUITEM_PINNABLESUBMENU, N_("Layout Menu"), &layoutMenuInfo, MENU_LAYOUT }, { N_("Arrange"), TGMUITEM_PINNABLESUBMENU, N_("Arrange Menu"), &arrangeMenuInfo, MENU_ARRANGE }, { N_("Properties"), TGMUITEM_PINNABLESUBMENU, N_("Properties Menu"), &propertiesMenuInfo, MENU_PROPERTIES }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Stacked Page"), TGMUITEM_PINNABLESUBMENU, N_("StackedPage Menu"), &stackedPageMenuInfo, MENU_STACKEDPAGE }, { N_("Tiled Page"), TGMUITEM_PINNABLESUBMENU, N_("TiledPage Menu"), &tiledPageMenuInfo, MENU_TILEDPAGE }, { N_("Page Layout"), TGMUITEM_PINNABLESUBMENU, N_("PageLayout Menu"), &pageLayoutMenuInfo, MENU_PAGELAYOUT }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Horizontal Align"), TGMUITEM_PINNABLESUBMENU, N_("HoriAlign Menu"), &horiAlignMenuInfo, MENU_HORIALIGN }, { N_("Vertical Align"), TGMUITEM_PINNABLESUBMENU, N_("VertAlign Menu"), &vertAlignMenuInfo, MENU_VERTALIGN }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Font"), TGMUITEM_PINNABLESUBMENU, N_("Font Menu"), &fontMenuInfo, MENU_FONT }, { N_("Text Style"), TGMUITEM_PINNABLESUBMENU, N_("TextStyle Menu"), &fontStyleMenuInfo, MENU_STYLE }, { N_("Text Size"), TGMUITEM_PINNABLESUBMENU, N_("TextSize Menu"), &fontSizeMenuInfo, MENU_SIZE }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Line Dash"), TGMUITEM_PINNABLESUBMENU, N_("LineDash Menu"), &lineDashMenuInfo, MENU_LINEDASH }, { N_("Line Style"), TGMUITEM_PINNABLESUBMENU, N_("LineStyle Menu"), &lineStyleMenuInfo, MENU_LINESTYLE }, { N_("Line Type"), TGMUITEM_PINNABLESUBMENU, N_("LineType Menu"), &lineTypeMenuInfo, MENU_LINETYPE }, { N_("Line Width"), TGMUITEM_PINNABLESUBMENU, N_("LineWidth Menu"), &lineWidthMenuInfo, MENU_LINEWIDTH }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Fill"), TGMUITEM_PINNABLESUBMENU, N_("Fill Menu"), &fillMenuInfo, MENU_FILL }, { N_("Pen"), TGMUITEM_PINNABLESUBMENU, N_("Pen Menu"), &penMenuInfo, MENU_PEN }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Move Mode"), TGMUITEM_PINNABLESUBMENU, N_("MoveMode Menu"), &moveModeMenuInfo, MENU_MOVEMODE }, { N_("Shape"), TGMUITEM_PINNABLESUBMENU, N_("Shape Menu"), &shapeMenuInfo, MENU_SHAPE }, { N_("Stretchable Text"), TGMUITEM_PINNABLESUBMENU, N_("StretchText Menu"), &stretchableTextModeMenuInfo, MENU_STRETCHTEXT }, { N_("Transparent Pattern"), TGMUITEM_PINNABLESUBMENU, N_("TransPattern Menu"), &transPatModeMenuInfo, MENU_TRANSPAT }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Image Proc"), TGMUITEM_PINNABLESUBMENU, N_("ImageProc Menu"), &imageProcMenuInfo, MENU_IMAGEPROC }, { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, { N_("Color"), TGMUITEM_PINNABLESUBMENU, N_("Color Menu"), &colorMenuInfo, MENU_COLOR }, { N_("Navigate"), TGMUITEM_PINNABLESUBMENU, N_("Navigate Menu"), &navigateMenuInfo, MENU_NAVIGATE }, { N_("Special"), TGMUITEM_PINNABLESUBMENU, N_("Special Menu"), &specialMenuInfo, MENU_SPECIAL }, { N_("Tangram-II"), TGMUITEM_PINNABLESUBMENU, N_("Tangram-II Menu"), &tangram2MenuInfo, MENU_TANGRAM2 }, { N_("Help"), TGMUITEM_PINNABLESUBMENU, N_("Help Menu"), &helpMenuInfo, MENU_HELP }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo mainMenuInfo={ TGMUTYPE_TEXT, mainMenuItemInfo, CreateMainMenu }; /* ------------------ menubar ------------------ */ /* * Don't put any separators here! */ static TgMenuItemInfo minimalMenubarMenuItemInfo[] = { { N_("File"), TGMUITEM_PINNABLESUBMENU, N_("File Menu"), &fileMenuInfo, MENU_FILE }, { N_("Edit"), TGMUITEM_PINNABLESUBMENU, N_("Edit Menu"), &editMenuInfo, MENU_EDIT }, { N_("Layout"), TGMUITEM_PINNABLESUBMENU, N_("Layout Menu"), &layoutMenuInfo, MENU_LAYOUT }, { N_("Arrange"), TGMUITEM_PINNABLESUBMENU, N_("Arrange Menu"), &arrangeMenuInfo, MENU_ARRANGE }, { N_("Properties"), TGMUITEM_PINNABLESUBMENU, N_("Properties Menu"), &propertiesMenuInfo, MENU_PROPERTIES }, { N_("Color"), TGMUITEM_PINNABLESUBMENU, N_("Color Menu"), &colorMenuInfo, MENU_COLOR }, { N_("Navigate"), TGMUITEM_PINNABLESUBMENU, N_("Navigate Menu"), &navigateMenuInfo, MENU_NAVIGATE }, { N_("Special"), TGMUITEM_PINNABLESUBMENU, N_("Special Menu"), &specialMenuInfo, MENU_SPECIAL }, { N_("Tangram-II"), TGMUITEM_PINNABLESUBMENU, N_("Tangram-II Menu"), &tangram2MenuInfo, MENU_TANGRAM2 }, { N_("Help"), TGMUITEM_PINNABLESUBMENU, N_("Help Menu"), &helpMenuInfo, MENU_HELP }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo minimalMenubarMenuInfo={ TGMUTYPE_TEXT, minimalMenubarMenuItemInfo, NULL }; static TgMenuItemInfo maximalMenubarMenuItemInfo[] = { { N_("File"), TGMUITEM_PINNABLESUBMENU, N_("File Menu"), &fileMenuInfo, MENU_FILE }, { N_("Edit"), TGMUITEM_PINNABLESUBMENU, N_("Edit Menu"), &editMenuInfo, MENU_EDIT }, { N_("Layout"), TGMUITEM_PINNABLESUBMENU, N_("Layout Menu"), &layoutMenuInfo, MENU_LAYOUT }, { N_("Arrange"), TGMUITEM_PINNABLESUBMENU, N_("Arrange Menu"), &arrangeMenuInfo, MENU_ARRANGE }, { N_("Properties"), TGMUITEM_PINNABLESUBMENU, N_("Properties Menu"), &propertiesMenuInfo, MENU_PROPERTIES }, { N_("Move Mode"), TGMUITEM_PINNABLESUBMENU, N_("MoveMode Menu"), &moveModeMenuInfo, MENU_MOVEMODE }, { N_("Page"), TGMUITEM_PINNABLESUBMENU, N_("Page Menu"), &pageMenuInfo, MENU_PAGE }, { N_("Page Layout"), TGMUITEM_PINNABLESUBMENU, N_("PageLayout Menu"), &pageLayoutMenuInfo, MENU_PAGELAYOUT }, { N_("Horizontal Align"), TGMUITEM_PINNABLESUBMENU, N_("HoriAlign Menu"), &horiAlignMenuInfo, MENU_HORIALIGN }, { N_("Vertical Align"), TGMUITEM_PINNABLESUBMENU, N_("VertAlign Menu"), &vertAlignMenuInfo, MENU_VERTALIGN }, { N_("Font"), TGMUITEM_PINNABLESUBMENU, N_("Font Menu"), &fontMenuInfo, MENU_FONT }, { N_("Text Style"), TGMUITEM_PINNABLESUBMENU, N_("TextStyle Menu"), &fontStyleMenuInfo, MENU_STYLE }, { N_("Text Size"), TGMUITEM_PINNABLESUBMENU, N_("TextSize Menu"), &fontSizeMenuInfo, MENU_SIZE }, { N_("Shape"), TGMUITEM_PINNABLESUBMENU, N_("Shape Menu"), &shapeMenuInfo, MENU_SHAPE }, { N_("Stretchable Text"), TGMUITEM_PINNABLESUBMENU, N_("StretchText Menu"), &stretchableTextModeMenuInfo, MENU_STRETCHTEXT }, { N_("Line Dash"), TGMUITEM_PINNABLESUBMENU, N_("LineDash Menu"), &lineDashMenuInfo, MENU_LINEDASH }, { N_("Line Style"), TGMUITEM_PINNABLESUBMENU, N_("LineStyle Menu"), &lineStyleMenuInfo, MENU_LINESTYLE }, { N_("Line Type"), TGMUITEM_PINNABLESUBMENU, N_("LineType Menu"), &lineTypeMenuInfo, MENU_LINETYPE }, { N_("Line Width"), TGMUITEM_PINNABLESUBMENU, N_("LineWidth Menu"), &lineWidthMenuInfo, MENU_LINEWIDTH }, { N_("Fill"), TGMUITEM_PINNABLESUBMENU, N_("Fill Menu"), &fillMenuInfo, MENU_FILL }, { N_("Pen"), TGMUITEM_PINNABLESUBMENU, N_("Pen Menu"), &penMenuInfo, MENU_PEN }, { N_("Transparent Pattern"), TGMUITEM_PINNABLESUBMENU, N_("TransPattern Menu"), &transPatModeMenuInfo, MENU_TRANSPAT }, { N_("Color"), TGMUITEM_PINNABLESUBMENU, N_("Color Menu"), &colorMenuInfo, MENU_COLOR }, { N_("Image Proc"), TGMUITEM_PINNABLESUBMENU, N_("ImageProc Menu"), &imageProcMenuInfo, MENU_IMAGEPROC }, { N_("Navigate"), TGMUITEM_PINNABLESUBMENU, N_("Navigate Menu"), &navigateMenuInfo, MENU_NAVIGATE }, { N_("Special"), TGMUITEM_PINNABLESUBMENU, N_("Special Menu"), &specialMenuInfo, MENU_SPECIAL }, { N_("Tangram-II"), TGMUITEM_PINNABLESUBMENU, N_("Tangram-II Menu"), &tangram2MenuInfo, MENU_TANGRAM2 }, { N_("Help"), TGMUITEM_PINNABLESUBMENU, N_("Help Menu"), &helpMenuInfo, MENU_HELP }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo maximalMenubarMenuInfo={ TGMUTYPE_TEXT, maximalMenubarMenuItemInfo, NULL }; ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/help.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000003016�11602233311�014061� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/help.e,v 1.6 2011/05/16 16:21:57 william Exp $ */ #ifndef _HELP_E_ #define _HELP_E_ extern int numHelp; #ifdef _INCLUDE_FROM_HELP_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_HELP_C_*/ extern void About ARGS_DECL((void)); extern void Copyright ARGS_DECL((void)); extern void LatestReleaseInfo ARGS_DECL((void)); extern void CleanUpHelp ARGS_DECL((void)); extern void InitHelp ARGS_DECL((void)); extern void RefreshHelpMenu ARGS_DECL((TgMenu*)); extern int HelpMenu ARGS_DECL((int X, int Y, int TrackMenubar)); #ifdef _INCLUDE_FROM_HELP_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_HELP_C_*/ #endif /*_HELP_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/wb2.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000000543�11602233313�013625� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Renato Santana, <renato@nce.ufrj.br> in January, 1996. * * (Obsoleted in tgif-4.1.9 by the TangramII group at land.ufrj.br.) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb2.c,v 1.1 2004/06/18 23:19:10 william Exp $ */ #define _INCLUDE_FROM_WB2_C_ #include "tgifdefs.h" #ifdef _TGIF_WB #include "wb2.e" #endif /* _TGIF_WB */ �������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/color.c������������������������������������������������������������������������������0000644�0000764�0000764�00000255350�11602233311�014257� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/color.c,v 1.25 2011/05/16 16:21:56 william Exp $ */ #define _INCLUDE_FROM_COLOR_C_ #include "tgifdefs.h" #include "cmdids.h" #include "choice.e" #include "cmd.e" #include "color.e" #include "dialog.e" #include "drawing.e" #include "file.e" #include "font.e" #include "imgproc.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "menuinfo.e" #include "miniline.e" #include "msg.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "select.e" #include "setup.e" #include "stk.e" #include "strtbl.e" #include "text.e" #include "tgcwheel.e" #include "util.e" #include "xpixmap.e" #include "xbm/upend.xbm" #define MAX_VERTICAL_BTNS 6 int maxColors=0; int defaultColorIndex=9; int colorIndex=0; int *colorPixels=NULL; int *xorColorPixels=NULL; int *colorLayerOn=NULL; char defaultColorStr[COLORSTRLEN]; char myFgColorStr[COLORSTRLEN]; char myBgColorStr[COLORSTRLEN]; char myRubberBandColorStr[COLORSTRLEN]; char **colorMenuItems=NULL; XColor *tgifColors=NULL; XColor *tgifRequestedColors=NULL; XColor myBgColor; int maxRGB=0; int colorDump=FALSE; int useLocalRGBTxt=FALSE; int printUsingRequestedColor=FALSE; int colorLayers=FALSE; int needToRedrawColorWindow=FALSE; int initColorDontReload=FALSE; int gnUpdatePixelObjCount=0; char defaultBgColorStr[COLORSTRLEN]; int defaultBgColorIndex=INVALID; char altEditTextBgColorStr[COLORSTRLEN]; int altEditTextBgIndex=INVALID; char altEditTextHighlightColorStr[COLORSTRLEN]; int altEditTextHighlightIndex=INVALID; int useAltEditTextBgColor=FALSE; char pngExportTransparentColor[MAXSTRING]; static int colorWindowFirstIndex=0; static int colorItemH=12; static int canChangeAttrColor=FALSE; static int defaultColorIndexInXDefaults=FALSE; static int defaultColorInXDefaults=FALSE; static int allocatedMaxColors=MAXCOLORS; static char *defaultColorMenuItems[MAXCOLORS]={ /* do not translate -- these strings are color names */ "magenta", "red", "green", "blue", "yellow", "pink", "cyan", "CadetBlue", "white", "black", "DarkSlateGray" }; void DefaultColorArrays(Entries, ForePixels, Valid, InitRV, StatusStr) int Entries, **ForePixels, **Valid, **InitRV; char ***StatusStr; { register int i, *fore_pixels, pixel, *valid, *init_rv; pixel = myFgPixel; *ForePixels = fore_pixels = (int*)malloc(Entries*sizeof(int)); if (*ForePixels == NULL) FailAllocMessage(); *Valid = valid = (int*)malloc(Entries*sizeof(int)); if (*Valid == NULL) FailAllocMessage(); *InitRV = init_rv = (int*)malloc(Entries*sizeof(int)); if (*InitRV == NULL) FailAllocMessage(); for (i=0; i < Entries; i++) { *fore_pixels++ = pixel; *valid++ = TRUE; *init_rv++ = FALSE; } if (StatusStr != NULL) { *StatusStr = (char**)malloc(Entries*sizeof(char*)); if (*StatusStr == NULL) FailAllocMessage(); for (i=0; i < Entries; i++) { (*StatusStr)[i] = (char*)malloc((MAXSTRING+1)*sizeof(char)); if ((*StatusStr)[i] == NULL) FailAllocMessage(); *(*StatusStr)[i] = '\0'; } } } int GetDrawingBgPixel(index, pixel) int index, pixel; { if (index != INVALID && index != BACKPAT) { return pixel; } else if (myFileBgColorStr == NULL) { return myBgPixel; } else { return myFileBgPixel; } } int GetDrawingFgPixel(index, pixel) int index, pixel; { if (index != INVALID && index != BACKPAT) { return pixel; } else if (myFileBgColorStr == NULL || myFileFgColorStr == NULL) { return myFgPixel; } else { return myFileFgPixel; } } void GetDrawingFgColorStr(index, pixel, color_buf, buf_sz) int index, pixel, buf_sz; char *color_buf; { if (index != INVALID && index != BACKPAT) { UtilStrCpyN(color_buf, buf_sz, colorMenuItems[index]); } else if (myFileBgColorStr == NULL || myFileFgColorStr == NULL) { UtilStrCpyN(color_buf, buf_sz, myFgColorStr); } else { UtilStrCpyN(color_buf, buf_sz, myFileFgColorStr); } } struct LocalColorRec { char *name, *spec; int len; }; static struct LocalColorRec *privateColorInfo=NULL; int TgifParseColor(psz_color, p_color) char *psz_color; XColor *p_color; { struct LocalColorRec *ptr; int len; if (p_color != NULL) memset(p_color, 0, sizeof(XColor)); if (!useLocalRGBTxt || *psz_color == '#') { return (int)XParseColor(mainDisplay, mainColormap, psz_color, p_color); } len = strlen(psz_color); for (ptr=privateColorInfo; ptr->name != NULL; ptr++) { if (len == ptr->len && strcmp(psz_color, ptr->name) == 0) { if (ptr->spec != NULL) { return (int)XParseColor(mainDisplay, mainColormap, ptr->spec, p_color); } break; } } return (int)XParseColor(mainDisplay, mainColormap, psz_color, p_color); } int ParseAndAllocColorByName(colorname, color, red_req, green_req, blue_req) char *colorname; XColor *color; unsigned short *red_req, *green_req, *blue_req; { Colormap colormap; if (!TgifParseColor(colorname, color)) { fprintf(stderr, TgLoadString(STID_WARN_CANNOT_PARSE_NAMED_COLOR), colorname); fprintf(stderr, "\n"); return FALSE; } if (red_req != NULL) *red_req = color->red; if (green_req != NULL) *green_req = color->green; if (blue_req != NULL) *blue_req = color->blue; if (!XAllocColor(mainDisplay, mainColormap, color)) { if (newColormapUsed) { fprintf(stderr, TgLoadString(STID_CANNOT_ALLOC_NAMED_COLOR), colorname); fprintf(stderr, "\n"); return FALSE; } colormap = XCopyColormapAndFree(mainDisplay, mainColormap); mainColormap = colormap; newColormapUsed = TRUE; if (mainWindow != None) { XSetWindowColormap(mainDisplay, mainWindow, mainColormap); } if (!XAllocColor(mainDisplay, mainColormap, color)) { fprintf(stderr, TgLoadString(STID_CANNOT_ALLOC_NAMED_COLOR), colorname); fprintf(stderr, "\n"); return FALSE; } } return TRUE; } void RecalcXorPixels() { int i, bg_pixel; bg_pixel = GetDrawingBgPixel(INVALID, INVALID); if (xorColorPixels != NULL) { for (i=0; i < maxColors; i++) { xorColorPixels[i] = colorPixels[i] ^ bg_pixel; } } } static void InitLocalRGBTxt() { char *c_ptr; useLocalRGBTxt = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"LocalRGBTxt")) != NULL) { char *fname=UtilStrDup(c_ptr); FILE *fp; if (fname == NULL) { FailAllocMessage(); return; } if ((fp=fopen(fname, "r")) != NULL) { int num_lines=0, ok=TRUE, line_num=0, info_index=0; char *buf; while (fgets(gszMsgBox, sizeof(gszMsgBox), fp) != NULL) { int len=strlen(gszMsgBox); if (len > 0 && gszMsgBox[len-1] != '\n') { while (fgets(gszMsgBox, sizeof(gszMsgBox), fp) != NULL) { len = strlen(gszMsgBox); if (len > 0 && gszMsgBox[len-1] == '\n') break; } } num_lines++; } rewind(fp); if ((privateColorInfo=(struct LocalColorRec *)malloc( (num_lines+1)*sizeof(struct LocalColorRec))) == NULL) { FailAllocMessage(); ok = FALSE; } while ((buf=UtilGetALine(fp)) != NULL) { char *red_str, *green_str, *blue_str, *color_name; line_num++; if ((red_str=strtok(buf, " \t\n\r")) != NULL && (green_str=strtok(NULL, " \t\n\r")) != NULL && (blue_str=strtok(NULL, " \t\n\r")) != NULL && (color_name=strtok(NULL, "\t\n\r")) != NULL) { struct LocalColorRec *color_info_ptr; int red, green, blue; color_info_ptr = (&privateColorInfo[info_index]); while (*color_name == ' ' || *color_name == '\t') color_name++; if (sscanf(red_str, "%d", &red) == 1 && sscanf(green_str, "%d", &green) == 1 && sscanf(blue_str, "%d", &blue) == 1 && red >= 0 && red <= 0xff && green >= 0 && green <= 0xff && blue >= 0 && blue <= 0xff && *color_name != '\0') { color_info_ptr->name = UtilStrDup(color_name); if (color_info_ptr->name == NULL) FailAllocMessage(); color_info_ptr->len = strlen(color_info_ptr->name); sprintf(gszMsgBox, "#%02x%02x%02x", red, green, blue); color_info_ptr->spec = UtilStrDup(gszMsgBox); if (color_info_ptr->spec == NULL) FailAllocMessage(); info_index++; } else { fprintf(stderr, TgLoadCachedString(CSTID_MALFORMED_LINE_NUM_IN_FILE), line_num, fname); fprintf(stderr, "\n"); } } else { fprintf(stderr, TgLoadCachedString(CSTID_MALFORMED_LINE_NUM_IN_FILE), line_num, fname); fprintf(stderr, "\n"); } privateColorInfo[info_index].name = NULL; privateColorInfo[info_index].len = 0; free(buf); } fclose(fp); if (ok) useLocalRGBTxt = TRUE; } else { fprintf(stderr, TgLoadString(STID_INVALID_FILE_IN_X_DEFAULT), fname, TOOL_NAME, "LocalRGBTxt"); fprintf(stderr, "\n"); } free(fname); } printUsingRequestedColor = cmdLineRequestedColor; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PrintUsingRequestedColor")) != NULL && (strcmp(c_ptr, "true") == 0 || strcmp(c_ptr, "True") == 0)) { printUsingRequestedColor = TRUE; } } static int InitColorFromXPixmap(pn_num_colors, pppsz_color_str) int *pn_num_colors; char ***pppsz_color_str; /* return TRUE mean maxColors and initial colors are setup */ { char *c_ptr, xpm_fname[MAXPATHLENGTH], *color_char=NULL, **color_str=NULL; int i, ncolors=0, rc; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ColorFromXPixmap")) == NULL) { return FALSE; } strncpy(xpm_fname, c_ptr, sizeof(xpm_fname)); rc = MyReadPixmapFile(xpm_fname, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, &ncolors, NULL, NULL, &color_char, &color_str, NULL, NULL); if (rc != BitmapSuccess) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_COLORXPM_GET), TOOL_NAME, "ColorFromXPixmap", xpm_fname); fprintf(stderr, "\n"); return FALSE; } if (myReadTransparentPixmap) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_COLORXPM_TRANS), TOOL_NAME, "ColorFromXPixmap", xpm_fname); fprintf(stderr, "\n"); if (color_str != NULL) { for (i=0; i < ncolors; i++) { if (color_str[i] != NULL) { free(color_str[i]); } } free(color_str); } if (color_char != NULL) free(color_char); return FALSE; } *pn_num_colors = ncolors; *pppsz_color_str = color_str; if (color_char != NULL) free(color_char); return TRUE; } static int DoSetAltEditTextBgColor() { int new_alloc=FALSE; if (*altEditTextBgColorStr == '\0') return FALSE; altEditTextBgIndex = QuickFindColorIndex(NULL, altEditTextBgColorStr, &new_alloc, FALSE); if (altEditTextBgIndex == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_ALLOC_EDIT_TEXT_BGCOLOR), altEditTextBgColorStr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *altEditTextBgColorStr = '\0'; return FALSE; } if (colorLayers) RedrawColorWindow(); return TRUE; } static int DoSetAltEditTextHighlightColor() { int new_alloc=FALSE; if (*altEditTextHighlightColorStr == '\0') return FALSE; altEditTextHighlightIndex = QuickFindColorIndex(NULL, altEditTextHighlightColorStr, &new_alloc, FALSE); if (altEditTextHighlightIndex == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_ALLOC_EDIT_TEXT_HICOLOR), altEditTextHighlightColorStr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *altEditTextHighlightColorStr = '\0'; return FALSE; } if (colorLayers) RedrawColorWindow(); return TRUE; } static int DoSetDefaultBgColor() { int new_alloc=FALSE; if (*defaultBgColorStr == '\0') return FALSE; defaultBgColorIndex = QuickFindColorIndex(NULL, defaultBgColorStr, &new_alloc, FALSE); if (defaultBgColorIndex == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_ALLOC_DEF_BGCOLOR), defaultBgColorStr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *defaultBgColorStr = '\0'; return FALSE; } return TRUE; } static int std_palette8[] = { 0x00, 0xff }; static int std_palette27[] = { 0x00, 0x80, 0xff }; static int std_palette64[] = { 0x00, 0x55, 0xaa, 0xff }; static int std_palette216[] = { 0x00, 0x33, 0x66, 0x99, 0xcc, 0xff }; static char *openoffice_galaxy_palette[] = { /* black */ "#000000", "#151a1f", "#29333c", "#4b5a66", "#8b97a0", "#bec5c9", "#d8dcdf", "#edf1f5", "#ffffff", /* blue-gray */ "#123349", "#35556b", "#5382a1", "#a3b8cb", "#dae3ea", /* more-blue-gray */ "#003e6d", "#005a9b", "#0877bc", "#71c0eb", "#a4cef0", "#ddedfa", /* blue */ "#063d80", "#0646a2", "#0852d4", "#085dff", "#0fa0ff", "#b8f1ff", /* green */ "#063e00", "#096000", "#128902", "#1cbb04", "#8dff1a", "#cfff9e", /* yellow */ "#b2bc00", "#7f7800", "#46580b", "#314005", "#634900", "#c69200", /* orange */ "#f26a00", "#faa217", "#ffc726", "#ffdf24", "#fff67b", "#ffff9e", /* red */ "#6d0000", "#8e0000", "#c70909", "#ff0000", "#fc5b5b", "#ffa199", /* purple */ "#2e008f", "#8866cc", "#c2b0e5", NULL }; static char *openoffice_google_palette[] = { /* black */ "#000000", "#262626", "#404040", "#575757", "#747474", "#909090", "#a8a8a8", "#c5c5c5", "#e6e6e6", "#ffffff", /* saturated */ "#ff0000", "#ff9900", "#ffff00", "#98fe00", "#00ff00", "#00ffff", "#0035ff", "#9900ff", "#ff00ff", "#ff0187", /* red */ "#660000", "#990000", "#cc0000", "#f03939", "#ea9999", "#f4cccc", /* orange */ "#783f04", "#b45f06", "#e69138", "#f6b26b", "#f9cb9c", "#fce5cd", /* yellow */ "#7f6b00", "#bfa000", "#f1d932", "#ffe766", "#ffec99", "#fff6cc", /* light green */ "#2c4a00", "#4c7f00", "#5f9f00", "#84be2d", "#acdb65", "#d1e7b1", /* green */ "#1c4e13", "#26761d", "#5ba84f", "#84c47d", "#b0d7a8", "#d6ead3", /* cyan */ "#0c343d", "#134f5c", "#45818e", "#76a5af", "#a2c4c9", "#d0e0e3", /* blue */ "#073763", "#0b5394", "#3d85c6", "#6fa8dc", "#9fc5e8", "#cfe2f3", /* purple */ "#20124d", "#351c75", "#674ea7", "#8e7cc3", "#b4a7d6", "#d9d2e9", /* magenta */ "#4c114a", "#741b68", "#a64d9b", "#c27bbd", "#d5a6d4", "#ead1ea", /* redish */ "#5a002f", "#94004e", "#c10066", "#e53b94", "#e895c1", "#f6d1e5", NULL }; void InitColor() { int i, index=0, looking_for_default_color=FALSE, tmp_max, color_from_pixmap=FALSE; XColor color; char buf[80], *c_ptr, fg_color[80], bg_color[80], brdr_color[80]; long bg_gray=(long)0; int bg_allocated=FALSE, fg_allocated=FALSE, brdr_allocated=FALSE, ncolors=0; int std_palette=0, need_to_handle_additional_colors=FALSE; char **color_str=NULL, *additional_colors_buf=NULL; InitLocalRGBTxt(); strcpy(fg_color, "Black"); strcpy(bg_color, "White"); strcpy(brdr_color, "Black"); if (!initColorDontReload) { reverseVideo = FALSE; if (cmdLineRV != INVALID) { reverseVideo = cmdLineRV; } else if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ReverseVideo")) != NULL) { reverseVideo = FALSE; if (UtilStrICmp(c_ptr, "on") == 0 || UtilStrICmp(c_ptr, "true") == 0) { reverseVideo = TRUE; } } colorDump = (!PRTGIF); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"InitialPrintInColor")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { colorDump = FALSE; } } defaultColorInXDefaults = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DefaultColor")) != NULL) { defaultColorInXDefaults = TRUE; UtilStrCpyN(defaultColorStr, sizeof(defaultColorStr), c_ptr); } defaultColorIndexInXDefaults = FALSE; defaultColorIndex = 9; if (!defaultColorInXDefaults) { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DefaultColorIndex")) != NULL) { defaultColorIndexInXDefaults = TRUE; defaultColorIndex = atoi(c_ptr); } } color_from_pixmap = InitColorFromXPixmap(&ncolors, &color_str); if (color_from_pixmap && ncolors > 0 && color_str != NULL) { maxColors = ncolors; need_to_handle_additional_colors = TRUE; } else { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseMobileWebSafePalette")) != NULL) { maxColors = std_palette = 216; } else if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseStdPalette216")) != NULL) { maxColors = std_palette = 216; } else if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseStdPalette64")) != NULL) { maxColors = std_palette = 64; } else if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseStdPalette27")) != NULL) { maxColors = std_palette = 27; } else if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseStdPalette8")) != NULL) { maxColors = std_palette = 8; } else if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseOpenOfficeGalaxyPalette")) != NULL) { maxColors = std_palette = 53; } else if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseOpenOfficeGooglePalette")) != NULL) { maxColors = std_palette = 80; } else { maxColors = MAXCOLORS; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "MaxColors")) != NULL) { maxColors = atoi(c_ptr); if (maxColors <= 0) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "MaxColors", c_ptr, MAXCOLORS); fprintf(stderr, "\n"); maxColors = MAXCOLORS; } } } if (std_palette > 0) { need_to_handle_additional_colors = TRUE; } } if (need_to_handle_additional_colors) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"AdditionalColors")) != NULL) { char *buf_copy=UtilStrDup(c_ptr), *psz_state=NULL; if (buf_copy == NULL) FailAllocMessage(); UtilTrimBlanks(buf_copy); additional_colors_buf = UtilStrDup(buf_copy); if (additional_colors_buf == NULL) FailAllocMessage(); for (c_ptr=UtilStrTok(buf_copy, ",\t\n\r", &psz_state); c_ptr != NULL; c_ptr=UtilStrTok(NULL, ",\t\n\r", &psz_state)) { maxColors++; } UtilFree(buf_copy); } } if (colorDisplay) { if (((cmdLineForeground != NULL && cmdLineBackground == NULL) || (cmdLineForeground == NULL && cmdLineBackground != NULL)) && reverseVideo) { fprintf(stderr, TgLoadString(STID_NORM_VIDEO_MODE_ASSUMED), (cmdLineForeground == NULL ? "-bg" : "-fg")); fprintf(stderr, "\n"); reverseVideo = FALSE; } if (cmdLineForeground != NULL) { strcpy(fg_color, cmdLineForeground); } else if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"Foreground")) != NULL) { if (reverseVideo) { strcpy(bg_color, c_ptr); } else { strcpy(fg_color, c_ptr); } } else if (reverseVideo) { strcpy(fg_color, "white"); } else { strcpy(fg_color, "black"); } if (cmdLineBackground != NULL) { strcpy(bg_color, cmdLineBackground); } else if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"Background")) != NULL) { if (reverseVideo) { strcpy(fg_color, c_ptr); } else { strcpy(bg_color, c_ptr); } } else if (reverseVideo) { strcpy(bg_color, "black"); } else { strcpy(bg_color, "white"); } if (cmdLineBorder != NULL) { strcpy(brdr_color, cmdLineBorder); } else if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "BorderColor")) != NULL) { strcpy(brdr_color, c_ptr); } else { strcpy(brdr_color, fg_color); } } else { if (reverseVideo) { strcpy(fg_color, "white"); strcpy(bg_color, "black"); } else { strcpy(fg_color, "black"); strcpy(bg_color, "white"); } strcpy(brdr_color, fg_color); } if (maxColors <= 0) { fprintf(stderr, "%s\n", TgLoadString(STID_ZERO_COLORS_SPECIFIED)); exit (-1); } colorPixels = (int*)malloc(maxColors*sizeof(int)); xorColorPixels = (int*)malloc(maxColors*sizeof(int)); colorLayerOn = (int*)malloc(maxColors*sizeof(int)); colorMenuItems = (char**)malloc(maxColors*sizeof(char*)); if (colorPixels == NULL || xorColorPixels == NULL || colorLayerOn == NULL || colorMenuItems == NULL) { FailAllocMessage(); } tgifColors = (XColor*)malloc(maxColors*sizeof(XColor)); tgifRequestedColors = (XColor*)malloc(maxColors*sizeof(XColor)); if (tgifColors == NULL || tgifRequestedColors == NULL) FailAllocMessage(); allocatedMaxColors = maxColors; for (i=0; i < allocatedMaxColors; i++) { colorMenuItems[i] = (char*)malloc(COLORSTRLEN*sizeof(char)); if (colorMenuItems[i] == NULL) FailAllocMessage(); } if (color_from_pixmap && ncolors > 0 && color_str != NULL) { for (i=0; i < maxColors; i++) { strcpy(colorMenuItems[i], color_str[i]); free(color_str[i]); colorLayerOn[i] = TRUE; } free(color_str); color_str = NULL; } else { int r=0, g=0, b=0; switch (std_palette) { case 0: for (i=0; i < maxColors; i++) { sprintf(buf, "Color%1d", i); if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, buf)) != NULL) { UtilStrCpyN(colorMenuItems[i], COLORSTRLEN, c_ptr); } else if (i < MAXCOLORS) { UtilStrCpyN(colorMenuItems[i], COLORSTRLEN, defaultColorMenuItems[i]); } else { fprintf(stderr, TgLoadString(STID_CANNOT_GET_X_DEFAULT), TOOL_NAME, buf); fprintf(stderr, "\n"); exit(-1); } UtilTrimBlanks(colorMenuItems[i]); colorLayerOn[i] = TRUE; } break; case 8: i = 0; for (r=0; r < 2; r++) { for (g=0; g < 2; g++) { for (b=0; b < 2; b++) { sprintf(colorMenuItems[i], "#%02x%02x%02x", std_palette8[r], std_palette8[g], std_palette8[b]); colorLayerOn[i] = TRUE; i++; } } } if (!defaultColorIndexInXDefaults) { if (reverseVideo) { defaultColorIndex = 7; } else { defaultColorIndex = 0; } } break; case 27: i = 0; for (r=0; r < 3; r++) { for (g=0; g < 3; g++) { for (b=0; b < 3; b++) { sprintf(colorMenuItems[i], "#%02x%02x%02x", std_palette27[r], std_palette27[g], std_palette27[b]); colorLayerOn[i] = TRUE; i++; } } } if (!defaultColorIndexInXDefaults) { if (reverseVideo) { defaultColorIndex = 26; } else { defaultColorIndex = 0; } } break; case 64: i = 0; for (r=0; r < 4; r++) { for (g=0; g < 4; g++) { for (b=0; b < 4; b++) { sprintf(colorMenuItems[i], "#%02x%02x%02x", std_palette64[r], std_palette64[g], std_palette64[b]); colorLayerOn[i] = TRUE; i++; } } } if (!defaultColorIndexInXDefaults) { if (reverseVideo) { defaultColorIndex = 63; } else { defaultColorIndex = 0; } } break; case 216: i = 0; for (r=0; r < 6; r++) { for (g=0; g < 6; g++) { for (b=0; b < 6; b++) { sprintf(colorMenuItems[i], "#%02x%02x%02x", std_palette216[r], std_palette216[g], std_palette216[b]); colorLayerOn[i] = TRUE; i++; } } } if (!defaultColorIndexInXDefaults) { if (reverseVideo) { defaultColorIndex = 215; } else { defaultColorIndex = 0; } } break; case 53: /* OpenOffice Galaxy Palette */ for (i=0; i < std_palette; i++) { strcpy(colorMenuItems[i], openoffice_galaxy_palette[i]); colorLayerOn[i] = TRUE; } if (!defaultColorIndexInXDefaults) { if (reverseVideo) { defaultColorIndex = 8; } else { defaultColorIndex = 0; } } break; case 80: /* OpenOffice Google Palette */ for (i=0; i < std_palette; i++) { strcpy(colorMenuItems[i], openoffice_google_palette[i]); colorLayerOn[i] = TRUE; } if (!defaultColorIndexInXDefaults) { if (reverseVideo) { defaultColorIndex = 9; } else { defaultColorIndex = 0; } } break; } } if (need_to_handle_additional_colors && additional_colors_buf != NULL) { char *psz_state=NULL; for (c_ptr=UtilStrTok(additional_colors_buf, ",\t\n\r", &psz_state); c_ptr != NULL; c_ptr=UtilStrTok(NULL, ",\t\n\r", &psz_state)) { UtilStrCpyN(colorMenuItems[i], COLORSTRLEN, c_ptr); colorLayerOn[i] = TRUE; i++; } UtilFree(additional_colors_buf); } if (threeDLook) { static int initVryLtPixel=FALSE; myBlackPixel = myWhitePixel = myLtGryPixel = myDkGryPixel = INVALID; myVryLtPixel = myYellowPixel = INVALID; memset(&color, 0, sizeof(XColor)); if (ParseAndAllocColorByName("black", &color, NULL, NULL, NULL)) { myBlackPixel = color.pixel; } if (ParseAndAllocColorByName("white", &color, NULL, NULL, NULL)) { myWhitePixel = color.pixel; } if (ParseAndAllocColorByName("#ffff00", &color, NULL, NULL, NULL)) { myYellowPixel = color.pixel; } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"LightGrayColor")) != NULL) { if (ParseAndAllocColorByName(c_ptr, &color, NULL, NULL, NULL)) { myLtGryPixel = color.pixel; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_WILL_TRY_STR), TOOL_NAME, "LightGrayColor", c_ptr, "gray75"); } } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DarkGrayColor")) != NULL) { if (ParseAndAllocColorByName(c_ptr, &color, NULL, NULL, NULL)) { myDkGryPixel = color.pixel; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_WILL_TRY_STR), TOOL_NAME, "DarkGrayColor", c_ptr, "gray50"); } } if (initVryLtPixel && (c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "VeryLightGrayColor")) != NULL) { if (ParseAndAllocColorByName(c_ptr, &color, NULL, NULL, NULL)) { myVryLtPixel = color.pixel; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_WILL_TRY_STR), TOOL_NAME, "VeryLightGrayColor", c_ptr, "gray95"); } } if (myLtGryPixel == INVALID && ParseAndAllocColorByName("gray75", &color, NULL, NULL, NULL)) { myLtGryPixel = color.pixel; } if (myDkGryPixel == INVALID && ParseAndAllocColorByName("gray50", &color, NULL, NULL, NULL)) { myDkGryPixel = color.pixel; } if (initVryLtPixel && myVryLtPixel == INVALID && ParseAndAllocColorByName("gray95", &color, NULL, NULL, NULL)) { myVryLtPixel = color.pixel; } if (myBlackPixel == INVALID || myWhitePixel == INVALID || myLtGryPixel == INVALID || myDkGryPixel == INVALID || (initVryLtPixel && myVryLtPixel == INVALID) || myYellowPixel == INVALID) { fprintf(stderr, "%s\n", TgLoadString(STID_FAIL_TO_ALLOC_3D_COLORS)); threeDLook = FALSE; } } if (colorDisplay) { index = 0; for (i=0; i < maxColors; i++) { unsigned short red_req, green_req, blue_req; if (!ParseAndAllocColorByName(colorMenuItems[i], &color, &red_req, &green_req, &blue_req)) { fprintf(stderr, TgLoadString(STID_FAIL_TO_ALLOC_COLOR_NUM), i, colorMenuItems[i], TOOL_NAME); fprintf(stderr, "\n"); exit (-1); } if (i != index) strcpy(colorMenuItems[index], colorMenuItems[i]); colorPixels[index] = color.pixel; tgifColors[index].red = color.red; tgifColors[index].green = color.green; tgifColors[index].blue = color.blue; tgifRequestedColors[index].red = red_req; tgifRequestedColors[index].green = green_req; tgifRequestedColors[index].blue = blue_req; if (UtilStrICmp(colorMenuItems[i], fg_color) == 0) { myFgPixel = color.pixel; strcpy(myFgColorStr, fg_color); fg_allocated = TRUE; } if (UtilStrICmp(colorMenuItems[i], bg_color) == 0) { myBgPixel = color.pixel; myBgColor.pixel = color.pixel; myBgColor.red = color.red; myBgColor.green = color.green; myBgColor.blue = color.blue; strcpy(myBgColorStr, bg_color); bg_allocated = TRUE; bg_gray = (((long)tgifColors[i].red)<<2) + (((long)tgifColors[i].green)<<3) + ((long)tgifColors[i].blue); } if (UtilStrICmp(colorMenuItems[i], brdr_color) == 0) { myBorderPixel = color.pixel; brdr_allocated = TRUE; } index++; } maxColors = index; if (maxColors <= 0) { fprintf(stderr, "%s\n", TgLoadString(STID_ZERO_COLORS_SPECIFIED)); exit (-1); } looking_for_default_color = FALSE; if (defaultColorInXDefaults) { looking_for_default_color = TRUE; for (i=0; i < maxColors; i++) { if (UtilStrICmp(defaultColorStr, colorMenuItems[i]) == 0) { defaultColorIndex = i; looking_for_default_color = FALSE; break; } } } else if (defaultColorIndexInXDefaults) { if (defaultColorIndexInXDefaults && defaultColorIndex >= maxColors) { fprintf(stderr, TgLoadString(STID_DEFCOLORINDEX_GE_MAXCOLORS), TOOL_NAME, "DefaultColorIndex", TOOL_NAME, "MaxColors", TOOL_NAME, "DefaultColorIndex"); fprintf(stderr, "\n"); defaultColorIndex = 0; } } else { looking_for_default_color = TRUE; for (i=0; i < maxColors; i++) { if (UtilStrICmp(fg_color, colorMenuItems[i]) == 0) { defaultColorIndex = i; looking_for_default_color = FALSE; break; } } } if (!fg_allocated) { if (!ParseAndAllocColorByName(fg_color, &color, NULL, NULL, NULL)) { fprintf(stderr, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR_ABORT), fg_color); fprintf(stderr, "\n"); exit (-1); } myFgPixel = color.pixel; strcpy(myFgColorStr, fg_color); } if (!bg_allocated) { if (!ParseAndAllocColorByName(bg_color, &color, NULL, NULL, NULL)) { fprintf(stderr, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR_ABORT), bg_color); fprintf(stderr, "\n"); exit (-1); } myBgPixel = color.pixel; myBgColor.pixel = color.pixel; myBgColor.red = color.red; myBgColor.green = color.green; myBgColor.blue = color.blue; strcpy(myBgColorStr, bg_color); if (looking_for_default_color) { bg_gray = (((long)color.red)<<2) + (((long)color.green)<<3) + ((long)color.blue); } } if (defaultColorInXDefaults && looking_for_default_color) { if (!ParseAndAllocColorByName(defaultColorStr, &color, NULL, NULL, NULL)) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_COLORXPM_GET), TOOL_NAME, "DefaultColor", defaultColorStr); fprintf(stderr, "\n"); defaultColorInXDefaults = FALSE; } for (i=0; i < maxColors; i++) { if (color.pixel == colorPixels[i]) { defaultColorIndex = i; looking_for_default_color = FALSE; break; } } if (looking_for_default_color) { int new_alloc=FALSE; index = QuickFindColorIndex(NULL, defaultColorStr, &new_alloc, FALSE); if (index == INVALID) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_COLORXPM_GET), TOOL_NAME, "DefaultColor", defaultColorStr); fprintf(stderr, "\n"); defaultColorInXDefaults = FALSE; } else { defaultColorIndex = index; looking_for_default_color = FALSE; } } } if (looking_for_default_color) { long val, val1; defaultColorIndex = 0; val = (((long)tgifColors[0].red)<<2) + (((long)tgifColors[0].green)<<3) + ((long)tgifColors[0].blue); if (bg_gray >= 0x67ff9) { /* (0xffff<<1) + (0xffff<<2) + (0x7fff) */ for (i=1; i < maxColors; i++) { val1 = (((long)tgifColors[i].red)<<2) + (((long)tgifColors[i].green)<<3) + ((long)tgifColors[i].blue); if (val > val1) { val = val1; defaultColorIndex = i; } } } else { for (i=1; i < maxColors; i++) { val1 = (((long)tgifColors[i].red)<<2) + (((long)tgifColors[i].green)<<3) + ((long)tgifColors[i].blue); if (val < val1) { val = val1; defaultColorIndex = i; } } } } if (!brdr_allocated) { if (!ParseAndAllocColorByName(brdr_color, &color, NULL, NULL, NULL)) { fprintf(stderr, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR_ABORT), brdr_color); fprintf(stderr, "\n"); exit (-1); } myBorderPixel = color.pixel; } for (i=0; i < maxColors; i++) { xorColorPixels[i] = colorPixels[i] ^ myBgPixel; } colorIndex = defaultColorIndex; } else { /* !colorDisplay */ if (!ParseAndAllocColorByName(fg_color, &color, NULL, NULL, NULL)) { fprintf(stderr, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR_ABORT), fg_color); fprintf(stderr, "\n"); exit (-1); } myFgPixel = color.pixel; strcpy(myFgColorStr, fg_color); if (!ParseAndAllocColorByName(bg_color, &color, NULL, NULL, NULL)) { fprintf(stderr, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR_ABORT), bg_color); fprintf(stderr, "\n"); exit (-1); } myBgPixel = color.pixel; strcpy(myBgColorStr, bg_color); if (!ParseAndAllocColorByName(brdr_color, &color, NULL, NULL, NULL)) { fprintf(stderr, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR_ABORT), brdr_color); fprintf(stderr, "\n"); exit (-1); } myBorderPixel = color.pixel; for (i=0; i < maxColors; i++) { unsigned short red_req, green_req, blue_req; if (!ParseAndAllocColorByName(colorMenuItems[i], &color, &red_req, &green_req, &blue_req)) { fprintf(stderr, TgLoadString(STID_FAIL_ALLOC_COLOR_NUM_ABORT), i, colorMenuItems[i]); fprintf(stderr, "\n"); exit (-1); } tgifColors[i].red = color.red; tgifColors[i].green = color.green; tgifColors[i].blue = color.blue; tgifRequestedColors[i].red = red_req; tgifRequestedColors[i].green = green_req; tgifRequestedColors[i].blue = blue_req; if (UtilStrICmp(colorMenuItems[i], bg_color) == 0) { colorPixels[i] = myBgPixel; } else { colorPixels[i] = myFgPixel; } xorColorPixels[i] = myFgPixel ^ myBgPixel; } colorIndex = defaultColorIndex; } if (!ParseAndAllocColorByName("black", &color, NULL, NULL, NULL)) { fprintf(stderr, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR_ABORT), "black"); fprintf(stderr, "\n"); exit (-1); } tmp_max = max(((int)color.red),max(((int)color.green),((int)color.blue))); #ifndef DONTFREECOLORS XFreeColors(mainDisplay, mainColormap, &(color.pixel), 1, 0); #endif if (tmp_max > maxRGB) maxRGB = tmp_max; if (!ParseAndAllocColorByName("white", &color, NULL, NULL, NULL)) { fprintf(stderr, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR_ABORT), "white"); fprintf(stderr, "\n"); exit (-1); } tmp_max = max(((int)color.red),max(((int)color.green),((int)color.blue))); #ifndef DONTFREECOLORS XFreeColors(mainDisplay, mainColormap, &(color.pixel), 1, 0); #endif if (tmp_max > maxRGB) maxRGB = tmp_max; if (tmp_max == 0) { fprintf(stderr, "%s\n", TgLoadString(STID_UNEXPECTED_MAX_RGB_ZERO)); } *myRubberBandColorStr = '\0'; myRubberBandPixel = INVALID; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"RubberBandColor")) != NULL && ParseAndAllocColorByName(c_ptr, &color, NULL, NULL, NULL)) { strcpy(myRubberBandColorStr, c_ptr); myRubberBandPixel = color.pixel; xorOne = myRubberBandPixel^myBgPixel; } else { xorOne = myFgPixel^myBgPixel; } xorZero = myBgPixel; if (myFgPixel == myBgPixel) { fprintf(stderr, "%s\n", TgLoadString(STID_FG_BG_SAME_COLOR_WARNING)); } if (!initColorDontReload) { canChangeAttrColor = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"CanChangeAttrColor")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { canChangeAttrColor = TRUE; } colorLayers = FALSE; if (colorDisplay && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ColorLayers")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { colorLayers = TRUE; } *defaultBgColorStr = '\0'; defaultBgColorIndex = INVALID; if (colorDisplay && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DefaultObjectBackground")) != NULL) { strcpy(defaultBgColorStr, c_ptr); } else { strcpy(defaultBgColorStr, myBgColorStr); } DoSetDefaultBgColor(); *altEditTextBgColorStr = *altEditTextHighlightColorStr = '\0'; altEditTextBgIndex = altEditTextHighlightIndex = INVALID; useAltEditTextBgColor = FALSE; } if (!colorDisplay) { int new_alloc=FALSE; int color_index=QuickFindColorIndex(NULL, myFgColorStr, &new_alloc, TRUE); if (color_index == INVALID) { fprintf(stderr, TgLoadString(STID_CANNOT_SET_FG_COLOR), myFgColorStr, colorMenuItems[colorIndex]); fprintf(stderr, "\n"); } else { colorIndex = color_index; } } UtilStrCpyN(pngExportTransparentColor, sizeof(pngExportTransparentColor), myBgColorStr); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PNGExportTransparentColor")) != NULL) { int new_alloc=0; char spec[MAXSTRING]; UtilStrCpyN(spec, sizeof(spec), c_ptr); UtilTrimBlanks(spec); if (QuickFindColorIndex(NULL, spec, &new_alloc, FALSE) == INVALID) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_COLORXPM_GET), TOOL_NAME, "PNGExportTransparentColor", spec); fprintf(stderr, "\n"); return; } UtilStrCpyN(pngExportTransparentColor, sizeof(pngExportTransparentColor), spec); } } static int DrawAVerticalTab(color_index, x, y, skip) int color_index, x, y, skip; { XPoint v[5]; int offset; if (skip) return colorItemH; offset = ((colorItemH-7)>>1); v[0].x = v[4].x = x; v[0].y = v[4].y = y; v[1].x = x+scrollBarW; v[1].y = y; v[2].x = x+scrollBarW; v[2].y = y+colorItemH; v[3].x = x; v[3].y = y+colorItemH; XSetForeground(mainDisplay, defaultGC, colorPixels[color_index]); XFillPolygon(mainDisplay, colorWindow, defaultGC, v, 5, Convex, CoordModeOrigin); XSetForeground(mainDisplay, defaultGC, myBgPixel); XFillRectangle(mainDisplay, colorWindow, defaultGC, x+offset, y+offset, 7, 7); XSetForeground(mainDisplay, defaultGC, myFgPixel); XDrawRectangle(mainDisplay, colorWindow, defaultGC, x+offset, y+offset, 7, 7); if (colorLayerOn[color_index]) { XDrawLine(mainDisplay, colorWindow, defaultGC, x+offset, y+offset, x+offset+7, y+offset+7); XDrawLine(mainDisplay, colorWindow, defaultGC, x+offset, y+offset+7, x+offset+7, y+offset); } if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, x, y, x+scrollBarW-windowPadding, y+colorItemH); TgDrawThreeDButton(mainDisplay, colorWindow, textMenuGC, &bbox, TGBS_RAISED, 1, TRUE); } else { XDrawRectangle(mainDisplay, colorWindow, defaultGC, x, y, scrollBarW, colorItemH); } return colorItemH; } void RedrawColorWindow() { int i, x=(windowPadding>>1), y=0, y_start; needToRedrawColorWindow = FALSE; if (!colorLayers || colorWindow == None) return; XClearWindow(mainDisplay, colorWindow); y_start = y = (upend_height*MAX_VERTICAL_BTNS)+(windowPadding>>1); for (i=0; i < maxColors; i++) { if (i >= colorWindowFirstIndex) { int h=0; h = DrawAVerticalTab(i, x, y, FALSE); y += h; if (y > colorWindowH) break; } } for (i=0, y=(windowPadding>>1); i < MAX_VERTICAL_BTNS; i++, y += upend_height) { XSetTSOrigin(mainDisplay, rasterGC, x, y); XSetStipple(mainDisplay, rasterGC, scrollPixmap[i+4]); XFillRectangle(mainDisplay, colorWindow, rasterGC, x, y, upend_width, upend_height); if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, x, y, x+upend_height, y+upend_height); TgDrawThreeDButton(mainDisplay, colorWindow, textMenuGC, &bbox, TGBS_RAISED, 1, FALSE); } } XSetTSOrigin(mainDisplay, rasterGC, 0, 0); if (threeDLook) { XSetForeground(mainDisplay, defaultGC, myBorderPixel); XDrawRectangle(mainDisplay, colorWindow, defaultGC, 0, 0, scrollBarW-1, colorWindowH-1); XSetForeground(mainDisplay, defaultGC, myFgPixel); } } int OneColorObject(ObjPtr, ColorIndex) struct ObjRec *ObjPtr; int *ColorIndex; { struct ObjRec *obj_ptr=NULL; struct TextRec *text_ptr=NULL; for (obj_ptr=ObjPtr->detail.r->last; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { if (ObjPtr->type == OBJ_PIN && obj_ptr != GetPinObj(ObjPtr)) { continue; } switch (obj_ptr->type) { case OBJ_POLY: if (*ColorIndex == INVALID) { if ((obj_ptr->detail.p->fill != NONEPAT && obj_ptr->detail.p->fill != BACKPAT) || (obj_ptr->detail.p->pen != NONEPAT && obj_ptr->detail.p->pen != BACKPAT)) { *ColorIndex = obj_ptr->color; } } else if (obj_ptr->color != *ColorIndex) { if ((obj_ptr->detail.p->fill != NONEPAT && obj_ptr->detail.p->fill != BACKPAT) || (obj_ptr->detail.p->pen != NONEPAT && obj_ptr->detail.p->pen != BACKPAT)) { return FALSE; } } break; case OBJ_BOX: if (*ColorIndex == INVALID) { if ((obj_ptr->detail.b->fill != NONEPAT && obj_ptr->detail.b->fill != BACKPAT) || (obj_ptr->detail.b->pen != NONEPAT && obj_ptr->detail.b->pen != BACKPAT)) { *ColorIndex = obj_ptr->color; } } else if (obj_ptr->color != *ColorIndex) { if ((obj_ptr->detail.b->fill != NONEPAT && obj_ptr->detail.b->fill != BACKPAT) || (obj_ptr->detail.b->pen != NONEPAT && obj_ptr->detail.b->pen != BACKPAT)) { return FALSE; } } break; case OBJ_OVAL: if (*ColorIndex == INVALID) { if ((obj_ptr->detail.o->fill != NONEPAT && obj_ptr->detail.o->fill != BACKPAT) || (obj_ptr->detail.o->pen != NONEPAT && obj_ptr->detail.o->pen != BACKPAT)) { *ColorIndex = obj_ptr->color; } } else if (obj_ptr->color != *ColorIndex) { if ((obj_ptr->detail.o->fill != NONEPAT && obj_ptr->detail.o->fill != BACKPAT) || (obj_ptr->detail.o->pen != NONEPAT && obj_ptr->detail.o->pen != BACKPAT)) { return FALSE; } } break; case OBJ_TEXT: text_ptr = obj_ptr->detail.t; if (*ColorIndex == INVALID) { if (text_ptr->fill != NONEPAT && text_ptr->fill != BACKPAT) { *ColorIndex = obj_ptr->color; } } if (*ColorIndex == INVALID) { if (text_ptr->pen != NONEPAT && text_ptr->pen != BACKPAT) { MiniLinesInfo *minilines=(&text_ptr->minilines); *ColorIndex = minilines->first->first_block->seg->color; if (!OnePropertyMiniLines(PROP_MASK_COLOR, minilines->first->first_block->seg->color, minilines, TRUE)) { return FALSE; } } } else { if (text_ptr->fill != NONEPAT && text_ptr->fill != BACKPAT) { if (*ColorIndex != obj_ptr->color) { return FALSE; } } if (text_ptr->pen != NONEPAT && text_ptr->pen != BACKPAT) { if (!OnePropertyMiniLines(PROP_MASK_COLOR, *ColorIndex, &text_ptr->minilines, TRUE)) { return FALSE; } } } break; case OBJ_POLYGON: if (*ColorIndex == INVALID) { if ((obj_ptr->detail.g->fill != NONEPAT && obj_ptr->detail.g->fill != BACKPAT) || (obj_ptr->detail.g->pen != NONEPAT && obj_ptr->detail.g->pen != BACKPAT)) { *ColorIndex = obj_ptr->color; } } else if (obj_ptr->color != *ColorIndex) { if ((obj_ptr->detail.g->fill != NONEPAT && obj_ptr->detail.g->fill != BACKPAT) || (obj_ptr->detail.g->pen != NONEPAT && obj_ptr->detail.g->pen != BACKPAT)) { return FALSE; } } break; case OBJ_ARC: if (*ColorIndex == INVALID) { if ((obj_ptr->detail.a->fill != NONEPAT && obj_ptr->detail.a->fill != BACKPAT) || (obj_ptr->detail.a->pen != NONEPAT && obj_ptr->detail.a->pen != BACKPAT)) { *ColorIndex = obj_ptr->color; } } else if (obj_ptr->color != *ColorIndex) { if ((obj_ptr->detail.a->fill != NONEPAT && obj_ptr->detail.a->fill != BACKPAT) || (obj_ptr->detail.a->pen != NONEPAT && obj_ptr->detail.a->pen != BACKPAT)) { return FALSE; } } break; case OBJ_RCBOX: if (*ColorIndex == INVALID) { if ((obj_ptr->detail.rcb->fill != NONEPAT && obj_ptr->detail.rcb->fill != BACKPAT) || (obj_ptr->detail.rcb->pen != NONEPAT && obj_ptr->detail.rcb->pen != BACKPAT)) { *ColorIndex = obj_ptr->color; } } else if (obj_ptr->color != *ColorIndex) { if ((obj_ptr->detail.rcb->fill != NONEPAT && obj_ptr->detail.rcb->fill != BACKPAT) || (obj_ptr->detail.rcb->pen != NONEPAT && obj_ptr->detail.rcb->pen != BACKPAT)) { return FALSE; } } break; case OBJ_XBM: if (*ColorIndex == INVALID) { if (obj_ptr->detail.xbm->fill != NONEPAT && obj_ptr->detail.xbm->fill != BACKPAT) { *ColorIndex = obj_ptr->color; } } else if (obj_ptr->color != *ColorIndex) { if (obj_ptr->detail.xbm->fill != NONEPAT && obj_ptr->detail.xbm->fill != BACKPAT) { return FALSE; } } break; case OBJ_XPM: if (*ColorIndex == INVALID) { *ColorIndex = obj_ptr->color; } else if (obj_ptr->color != *ColorIndex) { return FALSE; } break; case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: case OBJ_PIN: if (!OneColorObject(obj_ptr, ColorIndex)) { return FALSE; } break; } } return TRUE; } int ChangeObjColor(ObjPtr, ColorIndex) struct ObjRec *ObjPtr; int ColorIndex; { register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; int changed=FALSE, icon_color_index; switch (ObjPtr->type) { case OBJ_POLY: case OBJ_BOX: case OBJ_OVAL: case OBJ_TEXT: case OBJ_POLYGON: case OBJ_ARC: case OBJ_RCBOX: case OBJ_XBM: case OBJ_XPM: if (ObjPtr->type == OBJ_TEXT) { if (SetMiniLinesProperty(PROP_MASK_COLOR, ColorIndex, &ObjPtr->detail.t->minilines)) { InvalidateTextCache(ObjPtr->detail.t); changed = TRUE; } } else if (ObjPtr->color != ColorIndex) { ObjPtr->color = ColorIndex; if (mainDisplay != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), colorMenuItems[ObjPtr->color]); } if (ObjPtr->type == OBJ_XPM) { /* RecolorXPmObj(ObjPtr, ColorIndex); */ } changed = TRUE; } break; case OBJ_GROUP: case OBJ_SYM: for (obj_ptr = ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { if (ChangeObjColor(obj_ptr, ColorIndex)) { changed = TRUE; } } break; case OBJ_ICON: icon_color_index = INVALID; if (OneColorObject(ObjPtr, &icon_color_index) && icon_color_index != ColorIndex) { for (obj_ptr = ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { if (ChangeObjColor(obj_ptr, ColorIndex)) { changed = TRUE; } } } break; case OBJ_PIN: icon_color_index = INVALID; if (OneColorObject(GetPinObj(ObjPtr), &icon_color_index) && icon_color_index != ColorIndex) { if (ChangeObjColor(GetPinObj(ObjPtr), ColorIndex)) { changed = TRUE; } } break; } if ((canChangeAttrColor || changePropertiesOfAttrs) && ObjPtr->type != OBJ_TEXT) { for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (SetMiniLinesProperty(PROP_MASK_COLOR, ColorIndex, &attr_ptr->obj->detail.t->minilines)) { InvalidateTextCache(attr_ptr->obj->detail.t); changed = TRUE; } } } return changed; } void ChangeAllSelColor(ColorIndex, HighLight) int ColorIndex, HighLight; { register struct SelRec *sel_ptr; int changed=FALSE, dont_do_obj=FALSE; int saved_sticky_menu_selection=stickyMenuSelection; int dont_check_text=FALSE; XGCValues values; if (topSel != NULL && topSel == botSel && topSel->obj->type == OBJ_XPM) { /* if the only selected object is an OBJ_XPM, chang the current color */ stickyMenuSelection = TRUE; if (gnInImageProc) dont_check_text = TRUE; dont_do_obj = TRUE; } if (topSel == NULL || stickyMenuSelection) { int text_obj_created=FALSE, text_cursor_shown=FALSE; if (!dont_check_text) { if (!(curChoice == DRAWTEXT && textCursorShown)) { text_cursor_shown = textCursorShown; text_obj_created = TieLooseEnds(); } } colorIndex = ColorIndex; if (colorLayers && !colorLayerOn[colorIndex]) { if (topSel == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVISIBLE_COLOR_SELECTED), colorIndex, colorMenuItems[colorIndex]); Msg(gszMsgBox); } } ShowColor(TRUE); UpdatePinnedMenu(MENU_COLOR); if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } if (!dont_check_text) { if (curChoice == DRAWTEXT && textCursorShown) { text_cursor_shown = TRUE; if (ChangeEditTextProperty(PROP_MASK_COLOR, colorIndex)) { curTextModified = TRUE; RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_COLORINDEX, colorIndex); } } } else { textCursorShown = FALSE; } } if (topSel == NULL) dont_do_obj = TRUE; } stickyMenuSelection = saved_sticky_menu_selection; sprintf(gszMsgBox, TgLoadString(STID_COLOR_SET_TO), colorMenuItems[ColorIndex]); Msg(gszMsgBox); if (dont_do_obj) return; values.foreground = colorPixels[ColorIndex]; values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle, &values); if (HighLight) HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjColor(sel_ptr->obj, ColorIndex)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { int need_to_update_sel_bbox=FALSE; if (!PRTGIF && colorLayers) { struct SelRec *next_sel; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=next_sel) { struct ObjRec *obj_ptr=sel_ptr->obj; next_sel = sel_ptr->next; obj_ptr->tmp_parent = NULL; if (!ObjInVisibleLayer(obj_ptr)) { need_to_update_sel_bbox = TRUE; if (sel_ptr->prev == NULL) { topSel = sel_ptr->next; } else { sel_ptr->prev->next = sel_ptr->next; } if (sel_ptr->next == NULL) { botSel = sel_ptr->prev; } else { sel_ptr->next->prev = sel_ptr->prev; } free(sel_ptr); } } if (needToRedrawColorWindow) { RedrawColorWindow(); } } SetFileModified(TRUE); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); if (need_to_update_sel_bbox) UpdSelBBox(); } if (HighLight) HighLightForward(); } void SetUpColorMenuPixmap(fore_colors, init_rv, pixmap, rows, cols) int **fore_colors, **init_rv, *rows, *cols; Pixmap **pixmap; { register int i; *pixmap = (Pixmap*)malloc(maxColors*sizeof(Pixmap)); *fore_colors = (int*)malloc(maxColors*sizeof(int)); *init_rv = (int*)malloc(maxColors*sizeof(int)); if (*pixmap == NULL || *fore_colors == NULL || *init_rv == NULL) { FailAllocMessage(); } for (i=0; i < maxColors; i++) { (*pixmap)[i] = patPixmap[SOLIDPAT]; (*fore_colors)[i] = colorPixels[i]; (*init_rv)[i] = FALSE; } *cols = ((maxColors % 10)==0) ? (int)(maxColors/10) : (int)(maxColors/10)+1; *rows = (maxColors <= 10) ? maxColors : 10; } void RefreshColorMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == colorIndex); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateColorMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { int i=0; TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); stMenuInfo.items = (TgMenuItemInfo*)malloc( (maxColors+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (maxColors+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < maxColors; item_info++, i++) { item_info->menu_str = (char*)(int*)(&colorPixels[i]); item_info->shortcut_str = NULL; sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_COLOR_TO), colorMenuItems[i]); item_info->status_str = UtilStrDup(gszMsgBox); if (item_info->status_str == NULL) FailAllocMessage(); item_info->submenu_info = NULL; item_info->cmdid = CMDID_CHANGEALLSELCOLOR; } stMenuInfo.items[maxColors].cmdid = INVALID; stMenuInfo.type |= TGMUTYPE_CANSCROLL; /* the status_str has been translated in TgLoadCachedString() */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < maxColors; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (maxColors+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, 16, 16, 10); menu_item = (&menu->menuitems[colorIndex]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } SetScrollableMenuFirstIndex(menu, colorIndex); } return menu; } int ColorMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(colorMenuInfo.create_proc)(NULL, X, Y, &colorMenuInfo, INVALID); activeMenu = MENU_COLOR; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } void CleanUpColors() { register int i; if (privateColorInfo != NULL) { struct LocalColorRec *ptr; for (ptr=privateColorInfo; ptr->name != NULL; ptr++) { free(ptr->name); if (ptr->spec != NULL) free(ptr->spec); } free(privateColorInfo); privateColorInfo = NULL; } if (colorLayerOn != NULL) free(colorLayerOn); if (colorPixels != NULL) free(colorPixels); if (xorColorPixels != NULL) free(xorColorPixels); colorLayerOn = colorPixels = xorColorPixels = NULL; if (tgifColors != NULL) free(tgifColors); if (tgifRequestedColors != NULL) free(tgifRequestedColors); tgifColors = tgifRequestedColors = NULL; if (colorMenuItems != NULL) { for (i=0; i < maxColors; i++) { if (colorMenuItems[i] != NULL) free(colorMenuItems[i]); } free(colorMenuItems); } colorMenuItems = NULL; maxColors = 0; defaultColorIndex = 9; colorIndex = 0; if (upend_bits == NULL) { } } static void SetAllColorLayersState(on_state) int on_state; { int i, changed=FALSE; for (i=0; i < maxColors; i++) { if (colorLayerOn[i] != on_state) { changed = TRUE; colorLayerOn[i] = on_state; } } strcpy(gszMsgBox, TgLoadString(on_state ? STID_ALL_COLOR_LAYERS_VISIBLE : STID_ALL_COLOR_LAYERS_INVISIBLE)); Msg(gszMsgBox); if (changed) { MakeQuiescent(); RedrawColorWindow(); ClearAndRedrawDrawWindow(); SetCurChoice(curChoiceBeforeMakeQuiescent); } } static void HandleClickInColorWindow(button_ev) XButtonEvent *button_ev; { int i, index, total, offset; if (threeDLook) { index = (int)((button_ev->y-1-(windowPadding>>1)) / upend_height); } else { index = (int)((button_ev->y-1) / scrollBarW); } if (index < 0) index = 0; switch (index+4) { case SCROLL_UPEND: case SCROLL_UP: case SCROLL_CHECKALL: case SCROLL_UNCHECKALL: case SCROLL_DOWN: case SCROLL_DOWNEND: if (button_ev->button != Button1) return; break; default: break; } switch (index+4) { case SCROLL_UPEND: colorWindowFirstIndex = 0; RedrawColorWindow(); break; case SCROLL_UP: if (colorWindowFirstIndex > 0) { if (button_ev->state & (ShiftMask | ControlMask)) { colorWindowFirstIndex -= 10; if (colorWindowFirstIndex < 0) colorWindowFirstIndex = 0; } else { colorWindowFirstIndex--; } RedrawColorWindow(); } break; case SCROLL_CHECKALL: SetAllColorLayersState(TRUE); break; case SCROLL_UNCHECKALL: SetAllColorLayersState(FALSE); break; case SCROLL_DOWN: if (colorWindowFirstIndex < maxColors-1) { if (button_ev->state & (ShiftMask | ControlMask)) { colorWindowFirstIndex += 10; if (colorWindowFirstIndex > maxColors-1) { colorWindowFirstIndex = maxColors-1; } } else { colorWindowFirstIndex++; } RedrawColorWindow(); } break; case SCROLL_DOWNEND: total = colorWindowH-(upend_height*MAX_VERTICAL_BTNS); colorWindowFirstIndex = maxColors-1; for (i=maxColors-1; i >= 0; i--) { int w=DrawAVerticalTab(i, 0, 0, TRUE); total -= w; if (total > 0) { colorWindowFirstIndex = i; } else { break; } } RedrawColorWindow(); break; default: offset = button_ev->y-(upend_height*MAX_VERTICAL_BTNS); for (i=0; i < maxColors; i++) { if (i >= colorWindowFirstIndex) { int h=DrawAVerticalTab(i, 0, 0, TRUE); if (h >= offset) { if (button_ev->button == Button1) { colorLayerOn[i] = !colorLayerOn[i]; sprintf(gszMsgBox, TgLoadString(colorLayerOn[i] ? STID_A_COLOR_LAYER_TURNED_ON : STID_A_COLOR_LAYER_TURNED_OFF), colorMenuItems[i], i); SetStringStatus(gszMsgBox); if (i == colorIndex) { sprintf(gszMsgBox, TgLoadString(STID_INVISIBLE_COLOR_SELECTED), colorIndex, colorMenuItems[colorIndex]); Msg(gszMsgBox); } MakeQuiescent(); RedrawColorWindow(); ClearAndRedrawDrawWindow(); SetCurChoice(curChoiceBeforeMakeQuiescent); } else if (button_ev->button == Button3) { int save_sticky_menu_selection=stickyMenuSelection; stickyMenuSelection = TRUE; ChangeAllSelColor(i, TRUE); stickyMenuSelection = save_sticky_menu_selection; } break; } offset -= h; } } break; } } static void HandleMotionInColorWindow(motion_ev) XMotionEvent *motion_ev; { int i, index, offset; if (threeDLook) { index = (int)((motion_ev->y-1-(windowPadding>>1)) / upend_height); } else { index = (int)((motion_ev->y-1) / scrollBarW); } if (index < 0) index = 0; switch (index+4) { case SCROLL_UPEND: case SCROLL_UP: case SCROLL_CHECKALL: case SCROLL_UNCHECKALL: case SCROLL_DOWN: case SCROLL_DOWNEND: if (motion_ev->state & (ShiftMask | ControlMask)) { SetColorMouseStatusStrings(TRUE, index); } else { SetColorMouseStatusStrings(FALSE, index); } break; default: offset = motion_ev->y-(upend_height*MAX_VERTICAL_BTNS); for (i=0; i < maxColors; i++) { if (i >= colorWindowFirstIndex) { int h=DrawAVerticalTab(i, 0, 0, TRUE); if (h >= offset) { char left_str[80], right_str[80]; sprintf(left_str, TgLoadString(colorLayerOn[i] ? STID_TURN_COLOR_LAYER_NUM_OFF : STID_TURN_COLOR_LAYER_NUM_ON), colorMenuItems[i], i); sprintf(right_str, TgLoadCachedString(CSTID_SET_COLOR_TO), colorMenuItems[i]); SetMouseStatus(left_str, TgLoadCachedString(CSTID_PARANED_NONE), right_str); break; } offset -= h; } } break; } } void ColorEventHandler(input) XEvent *input; { XEvent ev; if (!colorLayers) return; if (input->type == Expose) { while (XCheckWindowEvent(mainDisplay, colorWindow, ExposureMask, &ev)) ; RedrawColorWindow(); } else if (input->type == EnterNotify) { SetMouseStatus("", "", ""); } else if (input->type == MotionNotify) { while (XCheckWindowEvent(mainDisplay,colorWindow,PointerMotionMask,&ev)) ; HandleMotionInColorWindow(&input->xmotion); } else if (input->type == ButtonPress) { XButtonEvent *button_ev=(&(input->xbutton)); if (button_ev->button == Button1 || button_ev->button == Button3) { HandleClickInColorWindow(button_ev); } } } void RedrawColorDummyWindow() { XClearWindow(mainDisplay, colorDummyWindow); if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, scrollBarW, colorDummyWindowH); TgDrawThreeDButton(mainDisplay, colorDummyWindow, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); } } void ColorDummyEventHandler(input) XEvent *input; { if (!colorLayers) return; if (input->type == Expose) { XEvent ev; while (XCheckWindowEvent(mainDisplay,colorDummyWindow,ExposureMask,&ev)) ; RedrawColorDummyWindow(); } else if (input->type == EnterNotify) { SetMouseStatusToAllNone(); } } typedef struct tagUpdatePixelRec { int picture_changed; } UpdatePixelInfo; static void UpdatePixelForStrSeg(pStrSeg, pUserData) StrSegInfo *pStrSeg; void *pUserData; { UpdatePixelInfo *pupi=((UpdatePixelInfo*)pUserData); int new_alloc=FALSE; int index=QuickFindColorIndex(NULL, pStrSeg->color_str, &new_alloc, TRUE); if (index != pStrSeg->color) pupi->picture_changed = TRUE; if (index == INVALID) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANNOT_ALLOC_COLOR_USE_ALT), pStrSeg->color_str, colorMenuItems[colorIndex]); Msg(gszMsgBox); allocColorFailed = TRUE; pStrSeg->color = colorIndex; } else { pStrSeg->color = index; } if (mainDisplay != NULL) { UtilStrCpyN(pStrSeg->color_str, sizeof(pStrSeg->color_str), colorMenuItems[pStrSeg->color]); } } int UpdatePixel(ObjPtr) struct ObjRec *ObjPtr; { int c, i, r; int ncolors=0, new_alloc=FALSE, index=0, changed=FALSE, len=0; int picture_changed=FALSE; unsigned long pixel=0L, *from_pixels=NULL, *to_pixels=NULL; struct ObjRec *obj_ptr=NULL; struct XPmRec *xpm_ptr=NULL; struct AttrRec *attr_ptr=NULL; switch (ObjPtr->type) { case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: case OBJ_PIN: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { if (UpdatePixel(obj_ptr)) { picture_changed = TRUE; } } break; case OBJ_XPM: index = QuickFindColorIndex(NULL, ObjPtr->color_str, &new_alloc, TRUE); if (index != ObjPtr->color) picture_changed = TRUE; if (index == INVALID) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANNOT_ALLOC_COLOR_USE_ALT), ObjPtr->color_str, colorMenuItems[colorIndex]); Msg(gszMsgBox); allocColorFailed = TRUE; ObjPtr->color = colorIndex; } else { ObjPtr->color = index; } if (mainDisplay != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), colorMenuItems[ObjPtr->color]); } changed = FALSE; xpm_ptr = ObjPtr->detail.xpm; ncolors = xpm_ptr->ncolors; from_pixels = (unsigned long *)malloc(ncolors*sizeof(unsigned long)); to_pixels = (unsigned long *)malloc(ncolors*sizeof(unsigned long)); if (from_pixels == NULL || to_pixels == NULL) FailAllocMessage(); for (i=0; i < ncolors; i++) { from_pixels[i] = xpm_ptr->pixels[i]; if (xpm_ptr->pixels[i] == (-1)) { /* transparent pixel */ } else { index = QuickFindColorIndex(NULL, xpm_ptr->color_str[i], &new_alloc, TRUE); if (index == INVALID) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANNOT_ALLOC_COLOR_USE_ALT), xpm_ptr->color_str[i], colorMenuItems[colorIndex]); Msg(gszMsgBox); allocColorFailed = TRUE; len = strlen(colorMenuItems[colorIndex]); free(xpm_ptr->color_str[i]); xpm_ptr->color_str[i] = (char*)malloc((len+1)*sizeof(char)); if (xpm_ptr->color_str[i] == NULL) FailAllocMessage(); strcpy(xpm_ptr->color_str[i], colorMenuItems[colorIndex]); xpm_ptr->pixels[i] = colorPixels[colorIndex]; } else { if (xpm_ptr->pixels[i] != colorPixels[index]) { changed = TRUE; } xpm_ptr->pixels[i] = colorPixels[index]; } } to_pixels[i] = xpm_ptr->pixels[i]; } if (changed) { int image_w=xpm_ptr->image_w, image_h=xpm_ptr->image_h; XImage *image=xpm_ptr->image; Pixmap pixmap=xpm_ptr->pixmap; if (xpm_ptr->cached_pixmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_pixmap); } xpm_ptr->cached_pixmap = None; if (xpm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_bitmap); } xpm_ptr->cached_bitmap = None; xpm_ptr->cached_color = (-1); xpm_ptr->cached_zoom = 0; sprintf(gszMsgBox, TgLoadCachedString(CSTID_UPDATING_PIXELS), ++gnUpdatePixelObjCount, image_w, image_h); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); for (r=0; r<image_h; r++) { for (c=0; c<image_w; c++) { pixel = XGetPixel(image, c, r); for (i=0; i < ncolors; i++) { if (from_pixels[i] == pixel) { XPutPixel(image, c, r, to_pixels[i]); break; } } } } XPutImage(mainDisplay,pixmap,xpmGC,image,0,0,0,0,image_w,image_h); picture_changed = TRUE; } free(from_pixels); free(to_pixels); break; default: index = QuickFindColorIndex(NULL, ObjPtr->color_str, &new_alloc, TRUE); if (index != ObjPtr->color) picture_changed = TRUE; if (index == INVALID) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANNOT_ALLOC_COLOR_USE_ALT), ObjPtr->color_str, colorMenuItems[colorIndex]); Msg(gszMsgBox); allocColorFailed = TRUE; ObjPtr->color = colorIndex; } else { ObjPtr->color = index; } if (mainDisplay != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), colorMenuItems[ObjPtr->color]); } if (ObjPtr->type == OBJ_TEXT) { UpdatePixelInfo upi; memset(&upi, 0, sizeof(UpdatePixelInfo)); upi.picture_changed = FALSE; DoFuncOnStrSegForMiniLines(&ObjPtr->detail.t->minilines, UpdatePixelForStrSeg, &upi); if (upi.picture_changed) { picture_changed = TRUE; } } break; } for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (UpdatePixel(attr_ptr->obj)) { picture_changed = TRUE; } } return picture_changed; } void UpdateXPmObjects(ObjPtr) struct ObjRec *ObjPtr; { struct ObjRec *obj_ptr; struct XPmRec *xpm_ptr; switch (ObjPtr->type) { case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: case OBJ_PIN: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { UpdateXPmObjects(obj_ptr); } break; case OBJ_XPM: xpm_ptr = ObjPtr->detail.xpm; if (xpm_ptr->image == NULL) { xpm_ptr->image = XGetImage(mainDisplay, xpm_ptr->pixmap, 0, 0, xpm_ptr->image_w, xpm_ptr->image_h, AllPlanes, ZPixmap); } break; } } int FlushColormap() { int changed=FALSE; struct ObjRec *obj_ptr=NULL; #ifdef DONT_FREE_COLORMAP Msg(TgLoadString(STID_COLORMAP_NOT_RESETED)); return FALSE; #endif if (!newColormapUsed) { Colormap colormap=XCopyColormapAndFree(mainDisplay, mainColormap); mainColormap = colormap; newColormapUsed = TRUE; XSetWindowColormap(mainDisplay, mainWindow, mainColormap); } if (newColormapUsed) { struct PageRec *page_ptr=NULL; int saved_color_layers=FALSE; struct AttrRec *attr_ptr=NULL; for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next) { for (obj_ptr=page_ptr->bot; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { UpdateXPmObjects(obj_ptr); } } initColorDontReload = TRUE; CleanUpColors(); XFreeColormap(mainDisplay, mainColormap); mainColormap = DefaultColormap(mainDisplay, mainScreen); XSetWindowColormap(mainDisplay, mainWindow, mainColormap); newColormapUsed = FALSE; saved_color_layers = colorLayers; InitColor(); initColorDontReload = FALSE; colorLayers = saved_color_layers; DoSetDefaultBgColor(); ShowColor(TRUE); if (myFileBgColorStr != NULL) { int saved_my_file_bg_pixel=myFileBgPixel; int saved_my_file_fg_pixel=myFileFgPixel; int ok=TRUE; if (myFileFgColorStr != NULL && !SetFileFgColor()) { if (SetFileFgColor()) { if (saved_my_file_fg_pixel != myFileFgPixel) { changed = TRUE; } } else { ok = FALSE; } } if (ok) { if (SetFileBgColor()) { if (saved_my_file_bg_pixel != myFileBgPixel) { changed = TRUE; } } else { ok = FALSE; } } if (!ok) { ClearBgColorInfo(FALSE); changed = TRUE; } } DoSetAltEditTextBgColor(); DoSetAltEditTextHighlightColor(); RecalcXorPixels(); SaveStatusStrings(); gnUpdatePixelObjCount = 0; for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next) { for (obj_ptr=page_ptr->bot; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { if (UpdatePixel(obj_ptr)) { changed = TRUE; } } } if (tgifObj->fattr != NULL) { for (attr_ptr=tgifObj->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (UpdatePixel(attr_ptr->obj)) { changed = TRUE; } } } RestoreStatusStrings(); DestroyPinnedMenu(MENU_COLOR); if (colorLayers) { colorWindowFirstIndex = 0; RedrawColorWindow(); } if (changed) ClearAndRedrawDrawWindow(); return TRUE; } return FALSE; } void AddColor() { char spec[MAXSTRING+1], *c_ptr=NULL; if (!colorDisplay) { MsgBox(TgLoadString(STID_ADDCOLOR_FOR_BW_DPY), TOOL_NAME, INFO_MB); return; } *spec = '\0'; if (Dialog(TgLoadString(STID_ENTER_COLORS_TO_ADD), NULL, spec) == INVALID) { return; } UtilTrimBlanks(spec); if (*spec == '\0') return; for (c_ptr=strtok(spec, ", \t\n\r"); c_ptr != NULL && *c_ptr != '\0'; c_ptr=strtok(NULL, ", \t\n\r")) { int new_alloc; int index=QuickFindColorIndex(NULL, c_ptr, &new_alloc, FALSE); if (index == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR), c_ptr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } else { ChangeAllSelColor(index, FALSE); } } } void ChooseColor() { TgColorWheel_HandleCntrlSpace(mainDisplay, drawWindow); } void SetAltEditTextBgColor() { char spec[MAXSTRING+1]; *spec = '\0'; sprintf(gszMsgBox, TgLoadString(STID_ENTER_EDIT_BG_COLOR), (altEditTextBgIndex==INVALID ? (useAltEditTextBgColor ? myFgColorStr : myBgColorStr) : altEditTextBgColorStr)); if (Dialog(gszMsgBox, NULL, spec) == INVALID) return; UtilTrimBlanks(spec); if (*spec == '\0') return; if (UtilStrICmp(spec, TgLoadCachedString(CSTID_NONE)) == 0) { *altEditTextBgColorStr = '\0'; altEditTextBgIndex = INVALID; if (curChoice == DRAWTEXT && textCursorShown) { RedrawCurText(); } return; } UtilStrCpyN(altEditTextBgColorStr, sizeof(altEditTextBgColorStr), spec); if (DoSetAltEditTextBgColor()) { if (curChoice == DRAWTEXT && textCursorShown) { if (!useAltEditTextBgColor) { useAltEditTextBgColor = TRUE; UpdatePinnedMenu(MENU_PROPERTIES); } RedrawCurText(); } } } void SetAltEditTextHighlightColor() { char spec[MAXSTRING+1]; *spec = '\0'; sprintf(gszMsgBox, TgLoadString(STID_ENTER_EDIT_HILIGHT_COLOR), (altEditTextHighlightIndex==INVALID ? (useAltEditTextBgColor ? myBgColorStr : myFgColorStr) : altEditTextHighlightColorStr)); if (Dialog(gszMsgBox, NULL, spec) == INVALID) return; UtilTrimBlanks(spec); if (*spec == '\0') return; if (UtilStrICmp(spec, TgLoadCachedString(CSTID_NONE)) == 0) { *altEditTextHighlightColorStr = '\0'; altEditTextHighlightIndex = INVALID; if (curChoice == DRAWTEXT && textCursorShown) { RedrawCurText(); } return; } UtilStrCpyN(altEditTextHighlightColorStr, sizeof(altEditTextHighlightColorStr), spec); if (DoSetAltEditTextHighlightColor()) { RedrawCurText(); } } void ToggleAltEditTextBgColor() { useAltEditTextBgColor = (!useAltEditTextBgColor); RedrawCurText(); UpdatePinnedMenu(MENU_PROPERTIES); } void SaveColors(FP) FILE *FP; { int i; if (fprintf(FP, "color_info(%1d,%1d,%1d,[\n", maxColors, maxRGB, colorLayers) == EOF) { writeFileFailed = TRUE; } for (i=0; i < maxColors; i++) { if (i == maxColors-1) { if (fprintf(FP, "\t\"%s\", %1d, %1d, %1d, %1d, %1d, %1d, %1d\n", colorMenuItems[i], (int)(tgifColors[i].red), (int)(tgifColors[i].green), (int)(tgifColors[i].blue), (int)(tgifRequestedColors[i].red), (int)(tgifRequestedColors[i].green), (int)(tgifRequestedColors[i].blue), colorLayerOn==NULL ? 1 : colorLayerOn[i]) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(FP, "\t\"%s\", %1d, %1d, %1d, %1d, %1d, %1d, %1d,\n", colorMenuItems[i], (int)(tgifColors[i].red), (int)(tgifColors[i].green), (int)(tgifColors[i].blue), (int)(tgifRequestedColors[i].red), (int)(tgifRequestedColors[i].green), (int)(tgifRequestedColors[i].blue), colorLayerOn==NULL ? 1 : colorLayerOn[i]) == EOF) { writeFileFailed = TRUE; } } } if (fprintf(FP, "]).\n") == EOF) { writeFileFailed = TRUE; } } int ReadColors(FP, Inbuf) FILE *FP; char *Inbuf; { char *c_ptr, *line; int index=0, max_colors=0, max_rgb=0, color_layers=FALSE; c_ptr = FindChar((int)'(', Inbuf); InitScan(c_ptr, "\t\n, "); if (GETINT("color_info", max_colors, "maxColors") == INVALID || GETINT("color_info", max_rgb, "maxRGB") == INVALID || GETINT("color_info", color_layers, "colorLayers") == INVALID) { return FALSE; } if (PRTGIF && !cmdLineOpenDisplay && cmdLineColor) { CleanUpColors(); maxColors = max_colors; maxRGB = max_rgb; /* colorLayers = color_layers; */ colorMenuItems = (char**)malloc(maxColors*sizeof(char*)); tgifColors = (XColor*)malloc(maxColors*sizeof(XColor)); if (colorMenuItems == NULL || tgifColors == NULL) FailAllocMessage(); memset(colorMenuItems, 0, maxColors*sizeof(char*)); memset(tgifColors, 0, maxColors*sizeof(XColor)); for (index=0; index < maxColors; index++) { colorMenuItems[index] = (char*)malloc(COLORSTRLEN*sizeof(char)); if (colorMenuItems[index] == NULL) FailAllocMessage(); *colorMenuItems[index] = '\0'; } } if (colorDisplay && (!(PRTGIF && !cmdLineOpenDisplay)) && !importingFile) { int saved_color_layers=colorLayers; colorLayers = color_layers; if (colorLayers != saved_color_layers) { if (colorLayers) { XMapWindow(mainDisplay, colorWindow); XMapWindow(mainDisplay, colorDummyWindow); Msg(TgLoadString(STID_COLOR_LAYERS_ENABLED)); } else { XUnmapWindow(mainDisplay, colorWindow); XUnmapWindow(mainDisplay, colorDummyWindow); Msg(TgLoadString(STID_COLOR_LAYERS_DISABLED)); } Reconfigure(TRUE); } } index = 0; while ((line=UtilGetALine(FP)) != NULL) { char color_s[40]; int red=0, green=0, blue=0; int requested_red=0, requested_green=0, requested_blue=0, layer_on=FALSE; scanLineNum++; if (*line == ']') { free(line); break; } if (PRTGIF && !cmdLineOpenDisplay && cmdLineColor && index >= maxColors) { fprintf(stderr, "%s\n", TgLoadString(STID_TOO_MANY_LINES_IN_COLORINFO)); free(line); break; } c_ptr = FindChar((int)'"', line); c_ptr = ParseStr(c_ptr, (int)'"', color_s, sizeof(color_s)); InitScan(c_ptr, "\t\n, "); if (GETINT("color_info", red, "red") == INVALID || GETINT("color_info", green, "green") == INVALID || GETINT("color_info", blue, "blue") == INVALID || GETINT("color_info", requested_red, "requested_red") == INVALID || GETINT("color_info", requested_green, "requested_green") == INVALID || GETINT("color_info", requested_blue, "requested_blue") == INVALID || GETINT("color_info", layer_on, "layer_on") == INVALID) { return FALSE; } if (PRTGIF && !cmdLineOpenDisplay && cmdLineColor) { UtilStrCpyN(colorMenuItems[index], COLORSTRLEN*sizeof(char), color_s); if (cmdLineRequestedColor) { tgifColors[index].red = red; tgifColors[index].green = green; tgifColors[index].blue = blue; } else { tgifColors[index].red = requested_red; tgifColors[index].green = requested_green; tgifColors[index].blue = requested_blue; } index++; } if ((!(PRTGIF && !cmdLineOpenDisplay)) && !importingFile) { int new_alloc=FALSE; int cur_index=QuickFindColorIndex(NULL, color_s, &new_alloc, TRUE); if (cur_index != INVALID && cur_index < maxColors && colorLayerOn != NULL) { colorLayerOn[cur_index] = layer_on; } } free(line); } prTgifFoundColorInfo = TRUE; return TRUE; } void DumpRGBColorLine(FP, ColorIndex, Indent, EndOfLine) FILE *FP; int ColorIndex, Indent, EndOfLine; { register int i; if (colorDump) { for (i=0; i < Indent; i++) fprintf(FP, " "); if (tgifColors[ColorIndex].red == 0 && tgifColors[ColorIndex].green == 0 && tgifColors[ColorIndex].blue == 0) { fprintf(FP, "0 %s", gPsCmd[PS_SETGRAY]); } else if (tgifColors[ColorIndex].red == maxRGB && tgifColors[ColorIndex].green == maxRGB && tgifColors[ColorIndex].blue == maxRGB) { fprintf(FP, "1 %s", gPsCmd[PS_SETGRAY]); } else { fprintf(FP, "%.3f %.3f %.3f %s", ((float)tgifColors[ColorIndex].red/maxRGB), ((float)tgifColors[ColorIndex].green/maxRGB), ((float)tgifColors[ColorIndex].blue/maxRGB), gPsCmd[PS_SETRGBCOLOR]); } fprintf(FP, "%c", EndOfLine ? '\n' : ' '); } else { for (i=0; i < Indent; i++) fprintf(FP, " "); fprintf(FP, "0 %s\n", gPsCmd[PS_SETGRAY]); } } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/descrip.opt��������������������������������������������������������������������������0000644�0000764�0000764�00000000234�11602233311�015137� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������! ! @(#)$Header: /mm2/home/cvs/bc-src/tgif/descrip.opt,v 1.1 2004/06/18 23:20:49 william Exp $ ! !SYS$LIBRARY:VAXCRTL/SHARE SYS$LIBRARY:DECW$XLIBSHR/SHARE ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/AUTHORS������������������������������������������������������������������������������0000644�0000764�0000764�00000000071�11602233310�014030� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������Please see: http;//bourbon.usc.edu/tgif/people.html �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/eq4.sym������������������������������������������������������������������������������0000644�0000764�0000764�00000035736�11602233311�014224� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.43 state(0,37,100.000,0,0,0,8,1,3,1,1,0,0,1,0,1,0,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/eq4.sym,v 1.2 2004/08/31 23:54:51 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1 ]). slideshow_info('',-20,-20). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). dont_reencode("UtopiaFS:FFDingbests:ZapfDingbats"). ps_font_aliases([ "UtopiaFS-Regular=Utopia-Regular", "UtopiaFS-Bold=Utopia-Bold", "UtopiaFS-Italic=Utopia-Italic", "UtopiaFS-BoldItalic=Utopia-BoldItalic" ]). page(1,"LaTeX equation symbol (uses pstoepsi).",1,''). sym([ polygon('#0000ff','',5,[ 64,132,68,132,68,128,64,128,64,132],0,1,0,0,212,0,0,0,0,0,'1',0, "00",[ ]) ], 1116,0,0,[ attr("footer=", "", 0, 1, 0, text('#ff00ff',64,-21,3,0,1,126,48,613,13,3,0,0,0,0,2,126,48,0,0,"",0,0,0,0,-8,'',[ minilines(126,48,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "footer=")]) ]), mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,13,3,0,-1,0,0,0,0,0, "%")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,13,3,0,-4,0,0,0,0,0, "\\end{document}")]) ]) ])])), attr("header=", "", 0, 1, 0, text('#ff00ff',240,-21,11,0,1,270,176,608,13,3,0,0,0,0,2,270,176,0,0,"",0,0,0,0,-8,'',[ minilines(270,176,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "header=")]) ]), mini_line(261,13,3,0,0,0,[ str_block(0,261,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,261,13,3,0,-4,0,0,0,0,0, "\\documentstyle[12pt]{article}")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,162,13,3,0,-1,0,0,0,0,0, "\\oddsidemargin=0in")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "\\textwidth=6.5in")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,13,3,0,-1,0,0,0,0,0, "\\topmargin=0in")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,13,3,0,-2,0,0,0,0,0, "\\textheight=609pt")]) ]), mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,117,13,3,0,-2,0,0,0,0,0, "\\parskip=14pt")]) ]), mini_line(270,13,3,0,0,0,[ str_block(0,270,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,270,13,3,0,-4,0,0,0,0,0, "\\setlength{\\unitlength}{0.5cm}")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,13,3,0,-4,0,0,0,0,0, "\\pagestyle{empty}")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,3,0,-4,0,0,0,0,0, "\\begin{document}")]) ]), mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,13,3,0,-1,0,0,0,0,0, "%")]) ]) ])])), attr("exec=", "", 0, 1, 0, text('blue',64,-272,9,0,1,477,144,1170,13,3,0,0,0,0,2,477,144,0,0,"",0,0,0,0,-259,'',[ minilines(477,144,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "exec=")]) ]), mini_line(378,13,3,0,0,0,[ str_block(0,378,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,378,13,3,0,-4,0,0,0,0,0, " mktemp(\"/tmp/TgifXXXXXX\",\"file_name\");")]) ]), mini_line(468,13,3,0,0,0,[ str_block(0,468,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,468,13,3,0,-4,0,0,0,0,0, " write_attr_into_file(header,\"$(file_name).tex\");")]) ]), mini_line(441,13,3,0,0,0,[ str_block(0,441,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,441,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(eq,\"$(file_name).tex\");")]) ]), mini_line(477,13,3,0,0,0,[ str_block(0,477,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,477,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(footer,\"$(file_name).tex\");")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,162,13,3,0,-4,0,0,0,0,0, " launch(\"cmd\");")]) ]), mini_line(477,13,3,0,0,0,[ str_block(0,477,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,477,13,3,0,-4,0,0,0,0,0, " pstoepsi(\"$(file_name).eps\",\"$(file_name).ps\",1);")]) ]), mini_line(369,13,3,0,0,0,[ str_block(0,369,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,369,13,3,0,-4,0,0,0,0,0, " update_eps_child(\"$(file_name).eps\");")]) ]), mini_line(189,13,3,0,0,0,[ str_block(0,189,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,189,13,3,0,-4,0,0,0,0,0, " launch(\"cleanup\")")]) ]) ])])), attr("cmd=", "", 0, 1, 0, text('blue',64,-152,4,0,1,702,64,1138,13,3,0,0,0,0,2,702,64,0,0,"",0,0,0,0,-139,'',[ minilines(702,64,0,0,0,0,0,[ mini_line(36,13,3,0,0,0,[ str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, "cmd=")]) ]), mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-4,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(459,13,3,0,0,0,[ str_block(0,459,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,459,13,3,0,-4,0,0,0,0,0, " xterm -geom 40x8+200+400 -e latex $(file_name);")]) ]), mini_line(702,13,3,0,0,0,[ str_block(0,702,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,702,13,3,0,-4,0,0,0,0,0, " xterm -geom 40x8+200+400 -e dvips -N -n 1 -o $(file_name).ps $(file_name);")]) ]) ])])), attr("cleanup=", "", 0, 1, 0, text('blue',64,-72,3,0,1,540,48,165,13,3,0,0,0,0,2,540,48,0,0,"",0,0,0,0,-59,'',[ minilines(540,48,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "cleanup=")]) ]), mini_line(540,13,3,0,0,0,[ str_block(0,540,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,540,13,3,0,-2,0,0,0,0,0, " rm -f $(file_name).tex $(file_name).aux $(file_name).dvi")]) ]), mini_line(513,13,3,0,0,0,[ str_block(0,513,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,513,13,3,0,-2,0,0,0,0,0, " $(file_name).log $(file_name).ps $(file_name).eps")]) ]) ])])), attr("file_name=", "", 0, 1, 0, text('blue',64,32,1,0,1,90,16,29,13,3,0,0,0,0,2,90,16,0,0,"",0,0,0,0,45,'',[ minilines(90,16,0,0,0,0,0,[ mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, "file_name=")]) ]) ])])), attr("eq=", "", 1, 1, 0, text('blue',64,48,5,0,1,135,80,25,13,3,0,0,0,0,2,135,80,0,0,"",0,0,0,0,61,'',[ minilines(135,80,0,0,0,0,0,[ mini_line(27,13,3,0,0,0,[ str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, "eq=")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "\\LARGE")]) ]), mini_line(18,13,3,0,0,0,[ str_block(0,18,13,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,18,13,3,0,-3,0,0,0,0,0, "\\[")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,135,13,3,0,-2,0,0,0,0,0, " E\\,=\\,M\\,C^2")]) ]), mini_line(18,13,3,0,0,0,[ str_block(0,18,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,18,13,3,0,-4,0,0,0,0,0, "\\]")]) ]) ])])), attr("", "not_rigid", 0, 1, 0, text('blue',64,152,1,0,1,81,16,535,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,165,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "not_rigid")]) ]) ])])) ]). group([ text('#0000ff',224,258,4,0,1,389,66,1059,14,3,0,-1,0,0,2,389,66,0,2,"",0,0,0,0,272,'',[ minilines(389,66,0,2,0,-1,0,[ mini_line(332,14,4,0,2,0,[ str_block(0,107,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,107,14,3,0,-2,0,0,0,0,0, "Make sure that ")]), str_block(0,32,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,32,14,3,0,2,0,0,0,0,0, "latex")]), str_block(0,34,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,34,14,3,0,-2,0,0,0,0,0, " and ")]), str_block(0,38,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,38,14,3,0,1,0,0,0,0,0, "dvips")]), str_block(0,81,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,81,14,3,0,-2,0,0,0,0,0, " are in your ")]), str_block(0,36,12,4,0,0,0,0,0,[ str_seg('#ff00ff','Courier-Bold',1,80640,36,12,4,0,0,0,0,0,0,0, "PATH")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]), mini_line(370,14,3,0,1,0,[ str_block(0,228,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,228,14,3,0,-3,0,0,0,0,0, "After you instantiate this symbol, ")]), str_block(0,84,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,84,14,3,0,1,0,0,0,0,0, "double-click")]), str_block(0,58,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,58,14,3,0,1,0,0,0,0,0, " it to run")]) ]), mini_line(389,14,3,0,0,0,[ str_block(0,362,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,-3,0,0,0,0,0, "the latex scripts. Afterwards, you can hide/show the ")]), str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, "eq=")]) ]), mini_line(247,14,3,0,1,0,[ str_block(0,148,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,148,14,3,0,-3,0,0,0,0,0, "attribute by pressing ")]), str_block(0,95,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,95,14,3,0,1,0,0,0,0,0, "<Alt><Cntrl>7")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]) ])]), text('#0000ff',224,106,9,0,1,389,145,657,14,3,0,-1,0,0,2,389,145,0,2,"",0,0,0,0,120,'',[ minilines(389,145,0,2,0,-1,0,[ mini_line(360,14,3,0,2,0,[ str_block(0,360,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,360,14,3,0,2,0,0,0,0,0, "This version of the LaTeX equation symbol by default")]) ]), mini_line(356,14,3,0,2,0,[ str_block(0,122,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,122,14,3,0,2,0,0,0,0,0, "uses its internal \"")]), str_block(0,59,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,59,14,3,0,2,0,0,0,0,0, "pstoepsi")]), str_block(0,175,14,3,0,1,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,175,14,3,0,1,0,0,0,0,0, "\" to add a preview bitmap")]) ]), mini_line(339,14,3,0,2,0,[ str_block(0,182,14,3,0,-3,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,182,14,3,0,-3,0,0,0,0,0, "to a PS file. If want to use ")]), str_block(0,87,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,87,14,3,0,2,0,0,0,0,0, "an external \"")]), str_block(0,59,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,59,14,3,0,2,0,0,0,0,0, "pstoepsi")]), str_block(0,11,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,11,14,3,0,-1,0,0,0,0,0, "\",")]) ]), mini_line(382,14,3,0,0,0,[ str_block(0,382,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,382,14,3,0,-1,0,0,0,0,0, "please set the Tgif.ExternalPsToEpsi X default to \"true\".")]) ]), mini_line(369,14,3,0,2,0,[ str_block(0,226,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,226,14,3,0,2,0,0,0,0,0, "If you want to use ghostscript's \"")]), str_block(0,54,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,54,14,3,0,2,0,0,0,0,0, "ps2epsi")]), str_block(0,89,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,89,14,3,0,1,0,0,0,0,0, "\", please use")]) ]), mini_line(362,14,3,0,2,0,[ str_block(0,7,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,7,14,3,0,2,0,0,0,0,0, "\"")]), str_block(0,115,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,115,14,3,0,1,0,0,0,0,0, "eq4-ps2epsi.sym")]), str_block(0,240,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,240,14,3,0,1,0,0,0,0,0, "\" instead. If you'd lke 2x resolution")]) ]), mini_line(389,14,3,0,2,0,[ str_block(0,247,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,247,14,3,0,2,0,0,0,0,0, "for the preview bitmap, please use \"")]), str_block(0,76,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,76,14,3,0,1,0,0,0,0,0, "ps4-2x.sym")]), str_block(0,66,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,66,14,3,0,-1,0,0,0,0,0, "\" instead.")]) ]), mini_line(333,14,3,0,1,0,[ str_block(0,333,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,333,14,3,0,1,0,0,0,0,0, "Information about pstoepsi can be obtained from")]) ]), mini_line(373,14,3,0,2,0,[ str_block(0,42,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,42,14,3,0,1,0,0,0,0,0, "<URL:")]), str_block(0,318,14,3,0,2,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,318,14,3,0,2,0,0,0,0,0, "http://bourbon.cs.umd.edu:8001/tgif/tools.html")]), str_block(0,13,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,13,14,3,0,-1,0,0,0,0,0, ">.")]) ]) ])]), text('#0000ff',224,50,3,0,1,362,49,643,14,3,0,-1,0,0,2,362,49,0,1,"",0,0,0,0,64,'',[ minilines(362,49,0,1,0,-1,0,[ mini_line(325,14,3,0,1,0,[ str_block(0,189,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,189,14,3,0,-3,0,0,0,0,0, "Make sure you are running ")]), str_block(0,68,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,68,14,3,0,1,0,0,0,0,0, "tgif-4.1.44")]), str_block(0,68,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,68,14,3,0,-1,0,0,0,0,0, " or newer.")]) ]), mini_line(362,14,3,0,1,0,[ str_block(0,362,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,1,0,0,0,0,0, "You can find out what version of tgif you are running")]) ]), mini_line(300,14,3,0,0,0,[ str_block(0,300,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,300,14,3,0,-1,0,0,0,0,0, "by selecting About() from the Special menu.")]) ]) ])]), text('#0000ff',192,258,1,0,1,19,17,848,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,272,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(3)")]) ]) ])]), text('#0000ff',192,106,1,0,1,19,17,846,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,120,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(2)")]) ]) ])]), text('#0000ff',192,50,1,0,1,19,17,863,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,64,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(1)")]) ]) ])]) ], 1200,0,0,[ ]). ����������������������������������tgif-QPL-4.2.5/box.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000072257�11602233310�013733� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/box.c,v 1.13 2011/06/09 16:11:41 cvsps Exp $ */ #define _INCLUDE_FROM_BOX_C_ #include "tgifdefs.h" #include "attr.e" #include "auxtext.e" #include "box.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "grid.e" #include "mainloop.e" #include "mark.e" #include "msg.e" #include "obj.e" #include "pattern.e" #include "poly.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "strtbl.e" #include "util.e" #include "xpixmap.e" int boxDrawn=FALSE; static XPoint bv[5]; void MyBox(window, gc, x1, y1, x2, y2) /* Hollow box, solid outline with width=1 */ Window window; GC gc; int x1, y1, x2, y2; { bv[0].x = (short)x1; bv[0].y = (short)y1; bv[1].x = (short)x1; bv[1].y = (short)y2; bv[2].x = (short)x2; bv[2].y = (short)y2; bv[3].x = (short)x2; bv[3].y = (short)y1; bv[4].x = (short)x1; bv[4].y = (short)y1; XDrawLines(mainDisplay, window, gc, bv, 5, CoordModeOrigin); } static void DumpBoxPath(FP, ObjPtr, LtX, LtY, RbX, RbY, Width, Pen, Dash, TransPat) FILE *FP; struct ObjRec *ObjPtr; int LtX, LtY, RbX, RbY, Width, Pen, Dash, TransPat; { register int i; int w_is_int=TRUE; char *width_spec=ObjPtr->detail.b->width_spec; double dw=GetWidthInDouble(Width, width_spec, &w_is_int); fprintf(FP, " %s\n", gPsCmd[PS_GSAVE]); if (!colorDump && useGray && Pen > BACKPAT) { GrayCheck(Pen); fprintf(FP, " %s %s\n", GrayStr(Pen), gPsCmd[PS_SETGRAY]); } DumpRectPath(FP, LtX, LtY, RbX, RbY, 6, TRUE); if (ObjPtr->ctm != NULL) { fprintf(FP, " %s\n", &(gPsCmd[PS_TGIFSETMATRIX])[1]); } if (w_is_int) { if (Width != 1) { fprintf(FP, " %1d %s\n", Width, gPsCmd[PS_SETLINEWIDTH]); } } else { fprintf(FP, " %.3f %s\n", dw, gPsCmd[PS_SETLINEWIDTH]); } if (Dash != 0) { fprintf(FP, " ["); for (i = 0; i < dashListLength[Dash]-1; i++) { fprintf(FP, "%1d ", (int)(dashList[Dash][i])); } fprintf(FP, "%1d] 0 %s\n", (int)(dashList[Dash][dashListLength[Dash]-1]), gPsCmd[PS_SETDASH]); } switch (Pen) { case SOLIDPAT: fprintf(FP, " %s\n", gPsCmd[PS_STROKE]); break; case BACKPAT: if (!TransPat) { fprintf(FP, " 1 %s %s 0 %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_STROKE], gPsCmd[PS_SETGRAY]); } break; default: if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); fprintf(FP, " %s\n", gPsCmd[PS_FLATTENPATH]); DumpPatFill(FP, Pen, ObjPtr->bbox, 6, TRUE); } else { fprintf(FP, " %s\n", gPsCmd[PS_STROKE]); } break; } fprintf(FP, " %s\n", gPsCmd[PS_GRESTORE]); } void DumpBoxObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { int ltx, lty, rbx, rby, fill, width, pen, dash, color_index, trans_pat; if (ObjPtr->ctm == NULL) { ltx = ObjPtr->obbox.ltx; lty = ObjPtr->obbox.lty; rbx = ObjPtr->obbox.rbx; rby = ObjPtr->obbox.rby; } else { ltx = ObjPtr->orig_obbox.ltx; lty = ObjPtr->orig_obbox.lty; rbx = ObjPtr->orig_obbox.rbx; rby = ObjPtr->orig_obbox.rby; } trans_pat = ObjPtr->trans_pat; fill = ObjPtr->detail.b->fill; pen = ObjPtr->detail.b->pen; width = ObjPtr->detail.b->width; dash = ObjPtr->detail.b->dash; if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } fprintf(FP, "%% BOX\n"); if (ObjPtr->ctm != NULL) { float m[6]; fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); m[CTM_SX] = ((float)ObjPtr->ctm->m[CTM_SX])/((float)1000.0); m[CTM_SY] = ((float)ObjPtr->ctm->m[CTM_SY])/((float)1000.0); m[CTM_SIN] = ((float)ObjPtr->ctm->m[CTM_SIN])/((float)1000.0); m[CTM_MSIN] = ((float)ObjPtr->ctm->m[CTM_MSIN])/((float)1000.0); fprintf(FP, " %1d %1d %s\n", ObjPtr->x, ObjPtr->y, gPsCmd[PS_TRANSLATE]); fprintf(FP, " [%.3f %.3f %.3f %.3f %1d %1d] %s\n", m[CTM_SX], m[CTM_SIN], m[CTM_MSIN], m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY], gPsCmd[PS_CONCAT]); fprintf(FP, " %1d %s %1d %s %s\n", ObjPtr->x, gPsCmd[PS_NEG], ObjPtr->y, gPsCmd[PS_NEG], gPsCmd[PS_TRANSLATE]); } color_index = ObjPtr->color; DumpRGBColorLine(FP, color_index, 0, TRUE); switch (fill) { case NONEPAT: break; case SOLIDPAT: /* solid black object */ DumpRectPath(FP, ltx, lty, rbx, rby, 0, FALSE); fprintf(FP, "%s\n", gPsCmd[PS_FILL]); break; case BACKPAT: if (!trans_pat) { /* solid white object */ DumpRectPath(FP, ltx, lty, rbx, rby, 0, FALSE); fprintf(FP, "1 %s %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 3, TRUE); } break; default: /* patterned */ fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); if (!trans_pat) { DumpRectPath(FP, ltx, lty, rbx, rby, 3, FALSE); fprintf(FP, "1 %s %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 3, TRUE); } DumpRectPath(FP, ltx, lty, rbx, rby, 3, FALSE); fprintf(FP, "%s %s\n", gPsCmd[PS_EOCLIP], gPsCmd[PS_NEWPATH]); DumpPatFill(FP, fill, ObjPtr->bbox, 3, TRUE); } else { GrayCheck(fill); fprintf(FP, " %s %s\n", GrayStr(fill), gPsCmd[PS_SETGRAY]); DumpRectPath(FP, ltx, lty, rbx, rby, 3, FALSE); fprintf(FP, "%s\n", gPsCmd[PS_FILL]); } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); break; } if (pen == NONEPAT) { if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); return; } fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); fprintf(FP, " 10 %s\n", gPsCmd[PS_SETMITERLIMIT]); if ((colorDump || !useGray) && pen > BACKPAT) { DumpBoxPath(FP, ObjPtr, ltx, lty, rbx, rby, width, BACKPAT, 0, trans_pat); DumpRGBColorLine(FP, color_index, 3, TRUE); } DumpBoxPath(FP, ObjPtr, ltx, lty, rbx, rby, width, pen, dash, trans_pat); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); } void DrawBoxObj(win, XOff, YOff, ObjPtr) Window win; int XOff, YOff; struct ObjRec *ObjPtr; { struct BoxRec *box_ptr=ObjPtr->detail.b; int fill, pen, pixel, ltx, lty, rbx, rby, width, dash, trans_pat; int real_x_off, real_y_off; XGCValues values; trans_pat = ObjPtr->trans_pat; pen = box_ptr->pen; fill = box_ptr->fill; width = box_ptr->width; dash = box_ptr->dash; pixel = colorPixels[ObjPtr->color]; if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } real_x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); real_y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); ltx = ZOOMED_SIZE(ObjPtr->obbox.ltx - real_x_off); lty = ZOOMED_SIZE(ObjPtr->obbox.lty - real_y_off); rbx = ZOOMED_SIZE(ObjPtr->obbox.rbx - real_x_off); rby = ZOOMED_SIZE(ObjPtr->obbox.rby - real_y_off); if (fill != NONEPAT) { values.foreground = GetDrawingBgPixel(fill, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[fill]; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple, &values); if (ObjPtr->ctm != NULL) { XFillPolygon(mainDisplay, win, drawGC, ObjPtr->rotated_obbox, 5, Convex, CoordModeOrigin); } else { XFillRectangle(mainDisplay, win, drawGC, ltx, lty, rbx-ltx, rby-lty); } } if (pen != NONEPAT) { values.foreground = GetDrawingBgPixel(pen, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[pen]; values.line_width = ZOOMED_SIZE(width); #ifdef NO_THIN_LINE if (values.line_width < 1) values.line_width = 1; #endif values.join_style = JoinMiter; if (dash != 0) { XSetDashes(mainDisplay, drawGC, 0, dashList[dash], dashListLength[dash]); values.line_style = LineOnOffDash; } else { values.line_style = LineSolid; } XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | GCLineStyle | GCJoinStyle, &values); if (ObjPtr->ctm != NULL) { XDrawLines(mainDisplay, win, drawGC, ObjPtr->rotated_obbox, 5, CoordModeOrigin); } else { XDrawRectangle(mainDisplay, win, drawGC, ltx, lty, rbx-ltx, rby-lty); } } } int CreateBoxObj(X1, Y1, X2, Y2, CreateAbsolute) int X1, Y1, X2, Y2, CreateAbsolute; { struct BoxRec *box_ptr; struct ObjRec *obj_ptr; int width=0, w, ltx, lty, rbx, rby; if (X1 == X2 && Y1 == Y2) return FALSE; box_ptr = (struct BoxRec *)malloc(sizeof(struct BoxRec)); if (box_ptr == NULL) FailAllocMessage(); memset(box_ptr, 0, sizeof(struct BoxRec)); if (mainDisplay != NULL) { box_ptr->fill = objFill; box_ptr->width = width = curWidthOfLine[lineWidth]; UtilStrCpyN(box_ptr->width_spec, sizeof(box_ptr->width_spec), curWidthOfLineSpec[lineWidth]); box_ptr->pen = penPat; box_ptr->dash = curDash; } obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); if (X1 < X2) { if (Y1 < Y2) { ltx = X1; lty = Y1; rbx = X2; rby = Y2; } else { ltx = X1; lty = Y2; rbx = X2; rby = Y1; } } else { if (Y1 < Y2) { ltx = X2; lty = Y1; rbx = X1; rby = Y2; } else { ltx = X2; lty = Y2; rbx = X1; rby = Y1; } } if (CreateAbsolute) { obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = ltx; obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = lty; obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = rbx; obj_ptr->bbox.rby = obj_ptr->obbox.rby = rby; } else { obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = ABS_X(ltx); obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = ABS_Y(lty); obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = ABS_X(rbx); obj_ptr->bbox.rby = obj_ptr->obbox.rby = ABS_Y(rby); } w = HALF_W(width); obj_ptr->bbox.ltx -= w; obj_ptr->bbox.lty -= w; obj_ptr->bbox.rbx += w; obj_ptr->bbox.rby += w; obj_ptr->type = OBJ_BOX; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->id = objId++; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->locked = FALSE; obj_ptr->detail.b = box_ptr; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; obj_ptr->invisible = FALSE; obj_ptr->trans_pat = transPat; AddObj(NULL, topObj, obj_ptr); return TRUE; } static void ContinueBox(OrigX, OrigY) int OrigX, OrigY; { int end_x, end_y, grid_x, grid_y, saved_x, saved_y; int done=FALSE, abort=FALSE; char buf[80], w_buf[80], h_buf[80], x_buf[80], y_buf[80]; XEvent input, ev; XMotionEvent *motion_ev; SetXorDrawGC(xorColorPixels[colorIndex]); saved_x = grid_x = OrigX; saved_y = grid_y = OrigY; PixelToMeasurementUnit(w_buf, 0); PixelToMeasurementUnit(h_buf, 0); PixelToMeasurementUnit(x_buf, ABS_X(grid_x)); PixelToMeasurementUnit(y_buf, ABS_Y(grid_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); StartShowMeasureCursor(grid_x, grid_y, buf, TRUE); BeginIntervalRulers(grid_x, grid_y, grid_x, grid_y); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } while (!done) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); SetXorDrawGC(xorColorPixels[colorIndex]); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); MyBox(drawWindow, drawGC, OrigX, OrigY, saved_x, saved_y); EndIntervalRulers(grid_x, grid_y); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(saved_x-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(saved_y-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(saved_x)); PixelToMeasurementUnit(y_buf, ABS_Y(saved_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); EndShowMeasureCursor(saved_x, saved_y, buf, TRUE); done = TRUE; } else if (input.type == MotionNotify) { motion_ev = &(input.xmotion); end_x = motion_ev->x; end_y = motion_ev->y; GridXY(end_x, end_y, &grid_x, &grid_y); if (motion_ev->state & (ShiftMask | ControlMask)) { int w, h, pos_w=TRUE, pos_h=TRUE; w = grid_x - OrigX; h = grid_y - OrigY; if (w < 0) { w = (-w); pos_w = FALSE; } if (h < 0) { h = (-h); pos_h = FALSE; } if (w > h) { grid_x = (pos_w ? (OrigX+h) : (OrigX-h)); } else { grid_y = (pos_h ? (OrigY+w) : (OrigY-w)); } } if (grid_x != saved_x || grid_y != saved_y) { PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(saved_x-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(saved_y-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(saved_x)); PixelToMeasurementUnit(y_buf, ABS_Y(saved_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); ShowMeasureCursor(saved_x, saved_y, buf, TRUE); MyBox(drawWindow, drawGC, OrigX, OrigY, saved_x, saved_y); saved_x = grid_x; saved_y = grid_y; MyBox(drawWindow, drawGC, OrigX, OrigY, saved_x, saved_y); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(saved_x-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(saved_y-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(saved_x)); PixelToMeasurementUnit(y_buf, ABS_Y(saved_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); ShowMeasureCursor(saved_x, saved_y, buf, TRUE); } DrawIntervalRulers(OrigX, OrigY, grid_x, grid_y, NULL); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { XUngrabPointer(mainDisplay, CurrentTime); MyBox(drawWindow, drawGC, OrigX, OrigY, saved_x, saved_y); EndIntervalRulers(grid_x, grid_y); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(saved_x-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(saved_y-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(saved_x)); PixelToMeasurementUnit(y_buf, ABS_Y(saved_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); EndShowMeasureCursor(saved_x, saved_y, buf, TRUE); abort = TRUE; done = TRUE; } } } if (!abort && OrigX != grid_x && OrigY != grid_y) { CreateBoxObj(OrigX, OrigY, grid_x, grid_y, FALSE); RecordNewObjCmd(); DrawBoxObj(drawWindow, drawOrigX, drawOrigY, topObj); boxDrawn = TRUE; SetFileModified(TRUE); } XSync(mainDisplay, False); } void DrawBox(input) XEvent *input; { XButtonEvent *button_ev; int mouse_x, mouse_y, grid_x, grid_y; if (input->type != ButtonPress) return; button_ev = &(input->xbutton); if (button_ev->button == Button1) { mouse_x = button_ev->x; mouse_y = button_ev->y; GridXY(mouse_x, mouse_y, &grid_x, &grid_y); ContinueBox(grid_x, grid_y); } } void MakeBoxObjFromBoundingBox() { if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (curChoice == VERTEXMODE) SetCurChoice(NOTHING); HighLightReverse(); CreateBoxObj(selObjLtX, selObjLtY, selObjRbX, selObjRbY, TRUE); SelectTopObj(); RecordNewObjCmd(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); justDupped = FALSE; SetFileModified(TRUE); } void SaveBoxObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { struct BoxRec *box_ptr=ObjPtr->detail.b; if (fprintf(FP, "box('%s','',", colorMenuItems[ObjPtr->color]) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,'%s',%1d,", ObjPtr->obbox.ltx, ObjPtr->obbox.lty, ObjPtr->obbox.rbx, ObjPtr->obbox.rby, box_ptr->fill, box_ptr->width, box_ptr->pen, ObjPtr->id, box_ptr->dash, ObjPtr->rotation, ObjPtr->locked, ObjPtr->ctm!=NULL, ObjPtr->invisible, box_ptr->width_spec, ObjPtr->trans_pat) == EOF) { writeFileFailed = TRUE; } if (ObjPtr->ctm != NULL && fprintf(FP, "[\n %1d,%1d,%1d,%1d,%1d,%1d,%g,%g,%g,%g,%1d,%1d],", ObjPtr->x, ObjPtr->y, ObjPtr->orig_obbox.ltx, ObjPtr->orig_obbox.lty, ObjPtr->orig_obbox.rbx, ObjPtr->orig_obbox.rby, ObjPtr->ctm->m[CTM_SX], ObjPtr->ctm->m[CTM_SIN], ObjPtr->ctm->m[CTM_MSIN], ObjPtr->ctm->m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY]) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, " "); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } void ReadBoxObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { struct BoxRec *box_ptr; char color_str[40], bg_color_str[40], *s, width_spec[40]; int ltx, lty, rbx, rby, fill, width, pen, dash, w, id=0, trans_pat=FALSE; int new_alloc, rotation, locked=FALSE, transformed=FALSE, invisible=FALSE; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_str, sizeof(color_str)); if (fileVersion >= 37) { s = ParseStr(s, (int)',', bg_color_str, sizeof(bg_color_str)); } InitScan(s, "\t\n, "); dash = 0; rotation = 0; *width_spec = '\0'; if (fileVersion <= 5) { if (GETINT("box", ltx, "ltx") == INVALID || GETINT("box", lty, "lty") == INVALID || GETINT("box", rbx, "rbx") == INVALID || GETINT("box", rby, "rby") == INVALID || GETINT("box", fill, "fill") == INVALID || GETINT("box", width, "width") == INVALID || GETINT("box", pen, "pen") == INVALID) { return; } switch (width) { case 1: width = 3; break; case 2: width = 6; break; } id = objId++; } else if (fileVersion <= 7) { if (GETINT("box", ltx, "ltx") == INVALID || GETINT("box", lty, "lty") == INVALID || GETINT("box", rbx, "rbx") == INVALID || GETINT("box", rby, "rby") == INVALID || GETINT("box", fill, "fill") == INVALID || GETINT("box", width, "width") == INVALID || GETINT("box", pen, "pen") == INVALID) { return; } id = objId++; } else if (fileVersion <= 8) { if (GETINT("box", ltx, "ltx") == INVALID || GETINT("box", lty, "lty") == INVALID || GETINT("box", rbx, "rbx") == INVALID || GETINT("box", rby, "rby") == INVALID || GETINT("box", fill, "fill") == INVALID || GETINT("box", width, "width") == INVALID || GETINT("box", pen, "pen") == INVALID || GETINT("box", id, "id") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 13) { if (GETINT("box", ltx, "ltx") == INVALID || GETINT("box", lty, "lty") == INVALID || GETINT("box", rbx, "rbx") == INVALID || GETINT("box", rby, "rby") == INVALID || GETINT("box", fill, "fill") == INVALID || GETINT("box", width, "width") == INVALID || GETINT("box", pen, "pen") == INVALID || GETINT("box", id, "id") == INVALID || GETINT("box", dash, "dash") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 25) { if (GETINT("box", ltx, "ltx") == INVALID || GETINT("box", lty, "lty") == INVALID || GETINT("box", rbx, "rbx") == INVALID || GETINT("box", rby, "rby") == INVALID || GETINT("box", fill, "fill") == INVALID || GETINT("box", width, "width") == INVALID || GETINT("box", pen, "pen") == INVALID || GETINT("box", id, "id") == INVALID || GETINT("box", dash, "dash") == INVALID || GETINT("box", rotation, "rotation") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 32) { if (GETINT("box", ltx, "ltx") == INVALID || GETINT("box", lty, "lty") == INVALID || GETINT("box", rbx, "rbx") == INVALID || GETINT("box", rby, "rby") == INVALID || GETINT("box", fill, "fill") == INVALID || GETINT("box", width, "width") == INVALID || GETINT("box", pen, "pen") == INVALID || GETINT("box", id, "id") == INVALID || GETINT("box", dash, "dash") == INVALID || GETINT("box", rotation, "rotation") == INVALID || GETINT("box", locked, "locked") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 34) { if (GETINT("box", ltx, "ltx") == INVALID || GETINT("box", lty, "lty") == INVALID || GETINT("box", rbx, "rbx") == INVALID || GETINT("box", rby, "rby") == INVALID || GETINT("box", fill, "fill") == INVALID || GETINT("box", width, "width") == INVALID || GETINT("box", pen, "pen") == INVALID || GETINT("box", id, "id") == INVALID || GETINT("box", dash, "dash") == INVALID || GETINT("box", rotation, "rotation") == INVALID || GETINT("box", locked, "locked") == INVALID || GETINT("box", transformed, "transformed") == INVALID || GETINT("box", invisible, "invisible") == INVALID || GETSTR("box", width_spec, "width_spec") == INVALID) { return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); } else { if (GETINT("box", ltx, "ltx") == INVALID || GETINT("box", lty, "lty") == INVALID || GETINT("box", rbx, "rbx") == INVALID || GETINT("box", rby, "rby") == INVALID || GETINT("box", fill, "fill") == INVALID || GETINT("box", width, "width") == INVALID || GETINT("box", pen, "pen") == INVALID || GETINT("box", id, "id") == INVALID || GETINT("box", dash, "dash") == INVALID || GETINT("box", rotation, "rotation") == INVALID || GETINT("box", locked, "locked") == INVALID || GETINT("box", transformed, "transformed") == INVALID || GETINT("box", invisible, "invisible") == INVALID || GETSTR("box", width_spec, "width_spec") == INVALID || GETINT("box", trans_pat, "trans_pat") == INVALID) { return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); } if (fileVersion <= 16 && width <= 6) width = origWidthOfLine[width]; if (fileVersion <= 32) { sprintf(width_spec, "%1d", width); } fill = UpgradePenFill(fill); pen = UpgradePenFill(pen); *ObjPtr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (*ObjPtr == NULL) FailAllocMessage(); memset(*ObjPtr, 0, sizeof(struct ObjRec)); box_ptr = (struct BoxRec *)malloc(sizeof(struct BoxRec)); if (box_ptr == NULL) FailAllocMessage(); memset(box_ptr, 0, sizeof(struct BoxRec)); if (ltx > rbx || lty > rby) { int tmp_ltx, tmp_lty, tmp_rbx, tmp_rby; if (!PRTGIF) { Msg(TgLoadCachedString(CSTID_BAD_BOX_BBOX_ADJUSTED)); } CalcBBox(ltx, lty, rbx, rby, &tmp_ltx, &tmp_lty, &tmp_rbx, &tmp_rby); ltx = tmp_ltx; lty = tmp_lty; rbx = tmp_rbx; rby = tmp_rby; } (*ObjPtr)->trans_pat = trans_pat; box_ptr->fill = fill; box_ptr->width = width; UtilStrCpyN(box_ptr->width_spec, sizeof(box_ptr->width_spec), width_spec); box_ptr->pen = pen; box_ptr->dash = dash; (*ObjPtr)->x = ltx; (*ObjPtr)->y = lty; (*ObjPtr)->color = QuickFindColorIndex(*ObjPtr, color_str, &new_alloc, TRUE); UtilStrCpyN((*ObjPtr)->color_str, sizeof((*ObjPtr)->color_str), color_str); (*ObjPtr)->dirty = FALSE; (*ObjPtr)->id = id; (*ObjPtr)->rotation = rotation; (*ObjPtr)->locked = locked; (*ObjPtr)->type = OBJ_BOX; (*ObjPtr)->obbox.ltx = ltx; (*ObjPtr)->obbox.lty = lty; (*ObjPtr)->obbox.rbx = rbx; (*ObjPtr)->obbox.rby = rby; w = HALF_W(width); (*ObjPtr)->bbox.ltx = ltx - w; (*ObjPtr)->bbox.lty = lty - w; (*ObjPtr)->bbox.rbx = rbx + w; (*ObjPtr)->bbox.rby = rby + w; (*ObjPtr)->detail.b = box_ptr; (*ObjPtr)->ctm = NULL; (*ObjPtr)->invisible = invisible; if (fileVersion >= 33 && transformed) { int real_x=0, real_y=0; struct BBRec orig_obbox; char inbuf[MAXSTRING+1]; struct XfrmMtrxRec *ctm; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, "); ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ctm == NULL) FailAllocMessage(); if (GETINT("box", real_x, "real_x") == INVALID || GETINT("box", real_y, "real_y") == INVALID || GETINT("box", orig_obbox.ltx, "orig_obbox.ltx") == INVALID || GETINT("box", orig_obbox.lty, "orig_obbox.lty") == INVALID || GETINT("box", orig_obbox.rbx, "orig_obbox.rbx") == INVALID || GETINT("box", orig_obbox.rby, "orig_obbox.rby") == INVALID || GETDBL("box", ctm->m[CTM_SX], "CTM_SX") == INVALID || GETDBL("box", ctm->m[CTM_SIN], "CTM_SIN") == INVALID || GETDBL("box", ctm->m[CTM_MSIN], "CTM_MSIN") == INVALID || GETDBL("box", ctm->m[CTM_SY], "CTM_SY") == INVALID || GETINT("box", ctm->t[CTM_TX], "CTM_TX") == INVALID || GETINT("box", ctm->t[CTM_TY], "CTM_TY") == INVALID) { return; } (*ObjPtr)->ctm = ctm; if (ctm != NULL) { memcpy(&(*ObjPtr)->orig_obbox, &orig_obbox, sizeof(struct BBRec)); (*ObjPtr)->x = real_x; (*ObjPtr)->y = real_y; GetTransformedOBBoxOffsetVs(*ObjPtr, (*ObjPtr)->rotated_obbox); } } } void SetBoxPropMask(ObjPtr, plMask, plSkip, pProp) struct ObjRec *ObjPtr; long *plMask, *plSkip; struct PropertiesRec *pProp; { struct BoxRec *box_ptr=ObjPtr->detail.b; SetCTMPropertyMask(ObjPtr->ctm, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_COLOR, ObjPtr->color, colorMenuItems[ObjPtr->color], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_WIDTH, box_ptr->width, box_ptr->width_spec, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TRANSPAT, ObjPtr->trans_pat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_FILL, box_ptr->fill, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_PEN, box_ptr->pen, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_DASH, box_ptr->dash, NULL, plMask, plSkip, pProp); } void FreeBoxObj(ObjPtr) struct ObjRec *ObjPtr; { free(ObjPtr->detail.b); free(ObjPtr); } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Target.tmpl��������������������������������������������������������������������������0000644�0000764�0000764�00000002060�11602233313�015107� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Target.tmpl,v 1.6 2011/05/16 16:26:57 william Exp $ XCOMM TARGET_1 = tgif XCOMM XCOMM If you want to build tgwb, please change TARGET_1 above to tgwb. XCOMM ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/an-sr-flip-flop.obj������������������������������������������������������������������0000644�0000764�0000764�00000003532�11602233310�016367� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������state(0,14,100,0,0,0,8,1,6,0,2,0,1,0,0,1,1,0,0,4,0,0,0,10,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/an-sr-flip-flop.obj,v 1.1 2004/09/14 05:26:24 william Exp $ % icon([ group([ box('yellow',512,0,576,80,0,0,1,11,0,0,[ ]), poly('yellow',2,[ 488,16,512,16],0,0,1,47,0,0,0,0,[ ]), poly('yellow',2,[ 488,64,512,64],0,0,1,48,0,0,0,0,[ ]), poly('yellow',2,[ 576,16,600,16],0,0,1,49,0,0,0,0,[ ]), poly('yellow',2,[ 576,64,600,64],0,0,1,50,0,0,0,0,[ ]) ],[ ]), icon([ box('yellow',584,0,616,32,0,0,0,51,0,0,[ ]), box('yellow',596,12,604,20,2,0,1,52,0,0,[ ]) ], "pin",43,0,0,[ attr("name=", "Q", 1, 0, 1, text('green',568,8,1,0,4,1,1,0,1,11,19,53,0,15,4,0,0,0,[ "Q"])), attr("num=", "", 0, 1, 1, text('green',600,-24,1,0,4,1,1,0,1,44,19,54,0,15,4,0,0,0,[ "num="])) ]), icon([ box('yellow',584,48,616,80,0,0,0,55,0,0,[ ]), box('yellow',596,60,604,68,2,0,1,56,0,0,[ ]) ], "pin",44,0,0,[ attr("num=", "", 0, 1, 1, text('green',600,24,1,0,4,1,1,0,1,44,19,57,0,15,4,0,0,0,[ "num="])), attr("name=", "Q'", 1, 0, 1, text('green',560,56,1,0,4,1,1,0,1,22,19,58,0,15,4,0,0,0,[ "Q'"])) ]), icon([ box('yellow',472,0,504,32,0,0,0,59,0,0,[ ]), box('yellow',484,12,492,20,2,0,1,60,0,0,[ ]) ], "pin",45,0,0,[ attr("num=", "", 0, 1, 1, text('green',488,-24,1,0,4,1,1,0,1,44,19,61,0,15,4,0,0,0,[ "num="])), attr("name=", "S'", 1, 0, 1, text('green',528,8,1,0,4,1,1,0,1,22,19,62,0,15,4,0,0,0,[ "S'"])) ]), icon([ box('yellow',472,48,504,80,0,0,0,63,0,0,[ ]), box('yellow',484,60,492,68,2,0,1,64,0,0,[ ]) ], "pin",46,0,0,[ attr("name=", "R'", 1, 0, 1, text('green',528,56,1,0,4,1,1,0,1,22,19,65,0,15,4,0,0,0,[ "R'"])), attr("num=", "", 0, 1, 1, text('green',488,24,1,0,4,1,1,0,1,44,19,66,0,15,4,0,0,0,[ "num="])) ]) ], "flip-flop",51,0,0,[ ]). text('white',544,104,0,0,4,2,1,0,1,405,42,67,0,17,4,0,0,0,[ "This is a SR flip-flop", "Select the flip-flop with left mouse button and type ^V"]). ����������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/move.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000004123�11602233312�014100� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/move.e,v 1.7 2011/05/16 16:21:58 william Exp $ */ #ifndef _MOVE_E_ #define _MOVE_E_ extern int oneMotionTimeout; extern int minMoveInterval; #ifdef _INCLUDE_FROM_MOVE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_MOVE_C_*/ extern void MoveObj ARGS_DECL((struct ObjRec *, int Dx, int Dy)); extern void MoveAllSelObjects ARGS_DECL((int Dx, int Dy)); extern int EndPtInSelected ARGS_DECL((int XOff, int YOff)); extern void MoveAllSel ARGS_DECL((int Dx, int Dy)); extern void MoveAnObj ARGS_DECL((struct ObjRec *ObjPtr, struct ObjRec *TopOwner, int Dx, int Dy)); extern void MoveAnAttr ARGS_DECL((struct AttrRec *AttrPtr, struct ObjRec *AttrOwnerObj, int Dx, int Dy)); extern void MoveSel ARGS_DECL((int Dx, int Dy, struct ObjRec *, XButtonEvent *)); extern void FinishMoveVertexForStretchStructSpline ARGS_DECL(( struct VSelRec *, int AbsDx, int AbsDy, StretchStructuredSplineInfo*)); extern void MoveAllSelVs ARGS_DECL((int Dx, int Dy)); extern void MoveSelVs ARGS_DECL((int OrigX, int OrigY)); #ifdef _INCLUDE_FROM_MOVE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_MOVE_C_*/ #endif /*_MOVE_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgisdl.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000070137�11602233313�014427� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgisdl.c,v 1.15 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TGISDL_C_ #include "tgifdefs.h" #include "tidget.h" #include "auxtext.e" #include "dialog.e" #include "file.e" #include "font.e" #include "mainloop.e" #include "msg.e" #include "names.e" #include "raster.e" #include "setup.e" #include "strtbl.e" #include "tdgtbase.e" #include "tdgtbrow.e" #include "tdgtbtn.e" #include "tdgtdraw.e" #include "text.e" #include "tidget.e" #include "tgisdl.e" #include "util.e" InsertSymbolInfo gInsertSymbolInfo; typedef struct tagInsertSymbolDlgInfo { Window parent_win; /* should be the rootWindow */ TdgtDraw *sym_pixmap_ctl; /* user pick HS values here */ TdgtBtnRow *btn_row_ctl; int screen_w, screen_h; int base_win_w, base_win_h; int sym_x, sym_y; int btn_row_x, btn_row_y, btn_row_w, btn_row_h; char *title_str, *formatted_title_str; int def_btn_id; int sym_pixmap_x, sym_pixmap_y, v_pixmap_x, v_pixmap_y; unsigned char r, g, b; int h, s, v; /* 0 <= h,s,v <= 255 */ int pixel; char color_str[40]; TrueColorInfo tci; } InsertSymbolDlgInfo; /* --------------------- Utility Functions --------------------- */ #define TDGTARG_INSSYM_DPY_CLEAR 1 /* pv_cmd_userdata is NULL */ static void ClearAllControls(pTdgtBase) TdgtBase *pTdgtBase; { InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); TidgetSendCmd(pisdi->sym_pixmap_ctl->pti, TDGTCMD_DRAW_USER, TDGTARG_INSSYM_DPY_CLEAR, pTdgtBase); } static char InsertSymbolGetSelectedChar() { int row=gInsertSymbolInfo.selected_row, col=gInsertSymbolInfo.selected_col; int index=0; if (!gInsertSymbolInfo.something_selected) return '\0'; if (row > 6) { index = 0xa0 + ((row-7)<<4) + col; } else { index = 0x20 + (row<<4) + col; } return (char)(((unsigned int)index) & 0x0ff); } static int InsertSymbolInAppl(pTdgtBase) TdgtBase *pTdgtBase; { char buf[3]; buf[0] = InsertSymbolGetSelectedChar(); buf[1] = buf[2] = '\0'; HandleInputFromBuffer(buf); return TRUE; } static void InsertSymbolToggleSelected(pTdgtDraw) TdgtDraw *pTdgtDraw; { int x=windowPadding+TDGTBASE_DEF_H_PAD-1; int y=windowPadding+TDGTBASE_DEF_V_PAD-1; x += (gInsertSymbolInfo.a_symbol_w+1)*gInsertSymbolInfo.selected_col; y += (gInsertSymbolInfo.a_symbol_h+1)*gInsertSymbolInfo.selected_row; XFillRectangle(mainDisplay, pTdgtDraw->pti->tci.win, revDefaultGC, x, y, gInsertSymbolInfo.a_symbol_w, gInsertSymbolInfo.a_symbol_h); } static int InsertSymbolSelectedValid(row, col) int row, col; { if (row >= TGIS_ROWS || col >= TGIS_COLS || row == 6) return FALSE; if (row == 0 && col == 0) return FALSE; if (row == 5 && col == 15) return FALSE; if (row == 12 && col == 0) return FALSE; if (row == 12 && col == 15) return FALSE; return TRUE; } /* --------------------- Focus Stuff --------------------- */ static void InsertSymbolDlgRemoveFocus(pTdgtBase) TdgtBase *pTdgtBase; { InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); Window win=TidgetGetFocusWindow(); if (win == None) return; if (win == pisdi->sym_pixmap_ctl->pti->tci.win) { TidgetDrawFocusRect(pisdi->sym_pixmap_ctl->pti, &pisdi->sym_pixmap_ctl->client_area); } } /* --------------------- HSRedrawCallback --------------------- */ static void SetupControls(pTdgtBase) TdgtBase *pTdgtBase; { } static void RedrawInsertSymbolPixmapControlValues(pTdgtBase) TdgtBase *pTdgtBase; { InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); RedrawTidget(pisdi->sym_pixmap_ctl->pti); } #define SKIP_NONE 0x0 #define SKIP_HS_PIXMAP 0x1 #define SKIP_V_PIXMAP 0x2 static void RedrawControls(pTdgtBase, skip) TdgtBase *pTdgtBase; int skip; { if ((skip & SKIP_HS_PIXMAP) != SKIP_HS_PIXMAP) { RedrawInsertSymbolPixmapControlValues(pTdgtBase); } } static int HSRedrawCallback(pTdgtDraw) TdgtDraw *pTdgtDraw; { TdgtBase *pTdgtBase=NULL; if (pTdgtDraw == NULL) return FALSE; pTdgtBase = (TdgtBase*)(pTdgtDraw->pti->tci.parent_tidgetinfo->tidget); XCopyArea(mainDisplay, gInsertSymbolInfo.sym_pixmap, pTdgtDraw->pti->tci.win, gTidgetManager.gc, 0, 0, pTdgtDraw->client_area.w, pTdgtDraw->client_area.h, pTdgtDraw->client_area.x, pTdgtDraw->client_area.y); if (gInsertSymbolInfo.something_selected) { InsertSymbolToggleSelected(pTdgtDraw); } if (TidgetGetFocusWindow() == pTdgtDraw->pti->tci.win) { TidgetDrawFocusRect(pTdgtDraw->pti, &pTdgtDraw->client_area); } TidgetManagerResetGC(); return TRUE; } /* --------------------- HSEvHandlerCallback() --------------------- */ static int GetRowCol(x, y, pn_row, pn_col) int x, y, *pn_row, *pn_col; { int row=0, col=0; x -= (windowPadding+TDGTBASE_DEF_H_PAD-1); y -= (windowPadding+TDGTBASE_DEF_V_PAD-1); if (x < 0 || y < 0) return FALSE; row = (int)(y / (gInsertSymbolInfo.a_symbol_h+1)); col = (int)(x / (gInsertSymbolInfo.a_symbol_w+1)); if (!InsertSymbolSelectedValid(row, col)) { return FALSE; } *pn_row = row; *pn_col = col; return TRUE; } static int ClickInInsertSymbolPixmap(pTdgtDraw, button_ev) TdgtDraw *pTdgtDraw; XButtonEvent *button_ev; { TdgtBase *pTdgtBase= (TdgtBase*)(pTdgtDraw->pti->tci.parent_tidgetinfo->tidget); InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); int x=button_ev->x, y=button_ev->y; int on_a_symbol=FALSE, row=0, col=0, changed=FALSE; int double_clicked=FALSE; Time click_time=button_ev->time; if (TidgetGetFocusWindow() == pTdgtDraw->pti->tci.win) { /* no need to change focus */ } else { /* change focus */ TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TidgetSetFocusWindow(pTdgtDraw->pti->tci.win); } on_a_symbol = GetRowCol(x, y, &row, &col); if (gInsertSymbolInfo.something_selected) { if (on_a_symbol) { if (row == gInsertSymbolInfo.selected_row && col == gInsertSymbolInfo.selected_col) { /* clicked on the same symbol */ double_clicked = ((click_time-gInsertSymbolInfo.last_click_time) < doubleClickInterval); } else { InsertSymbolToggleSelected(pisdi->sym_pixmap_ctl); gInsertSymbolInfo.selected_row = row; gInsertSymbolInfo.selected_col = col; changed = TRUE; } } else { gInsertSymbolInfo.something_selected = FALSE; changed = TRUE; } } else { if (on_a_symbol) { gInsertSymbolInfo.something_selected = TRUE; gInsertSymbolInfo.selected_row = row; gInsertSymbolInfo.selected_col = col; changed = TRUE; } } if (changed) { SetupControls(pTdgtBase); RedrawControls(pTdgtBase, SKIP_NONE); } else if (double_clicked && gInsertSymbolInfo.something_selected) { InsertSymbolInAppl(pTdgtBase); } gInsertSymbolInfo.last_click_time = click_time; return FALSE; } static int HSEvHandlerCallback(pTdgtDraw, pXEv) TdgtDraw *pTdgtDraw; XEvent *pXEv; { if (pXEv->xany.window == pTdgtDraw->pti->tci.win) { if (pXEv->type == ButtonPress) { XButtonEvent *button_ev=(&(pXEv->xbutton)); return ClickInInsertSymbolPixmap(pTdgtDraw, button_ev); } } return FALSE; } /* --------------------- HSSendCmdCallback() --------------------- */ static int HSSendCmdCallback(pTdgtDraw, cmd_type, cmd_arg, pv_cmd_userdata) TdgtDraw *pTdgtDraw; int cmd_type, cmd_arg; void *pv_cmd_userdata; { TdgtBase *pTdgtBase=NULL; InsertSymbolDlgInfo *pisdi=NULL; switch (cmd_type) { case TDGTCMD_DRAW_USER: switch (cmd_arg) { case TDGTARG_INSSYM_DPY_CLEAR: pTdgtBase = (TdgtBase*)pv_cmd_userdata; pisdi = (InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); /* clear it */ gInsertSymbolInfo.something_selected = FALSE; RedrawTidget(pisdi->sym_pixmap_ctl->pti); break; } break; } return FALSE; } /* --------------- KeyPress Event Handlers --------------- */ static int HandleCRorLF(pTdgtBase) TdgtBase *pTdgtBase; { if (gInsertSymbolInfo.something_selected) { InsertSymbolInAppl(pTdgtBase); } return FALSE; } static int HandleTab(pTdgtBase) TdgtBase *pTdgtBase; { InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); Window win=TidgetGetFocusWindow(); if (win == None) { TidgetSetFocusWindow(pisdi->sym_pixmap_ctl->pti->tci.win); return FALSE; } return FALSE; } static int HandleBackSpace(pTdgtBase) TdgtBase *pTdgtBase; { return FALSE; } static int HandleCursorKey(pTdgtBase, key_sym) TdgtBase *pTdgtBase; KeySym key_sym; { InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); Window win=TidgetGetFocusWindow(); int dir=(-1); if (win == None) return FALSE; switch (key_sym) { case XK_Up: dir = SCROLL_UP; break; case XK_KP_Up: dir = SCROLL_UP; break; case XK_Down: dir = SCROLL_DOWN; break; case XK_KP_Down: dir = SCROLL_DOWN; break; case XK_Left: dir = SCROLL_LEFT; break; case XK_KP_Left: dir = SCROLL_LEFT; break; case XK_Right: dir = SCROLL_RIGHT; break; case XK_KP_Right: dir = SCROLL_RIGHT; break; default: return FALSE; } if (gInsertSymbolInfo.something_selected) { InsertSymbolToggleSelected(pisdi->sym_pixmap_ctl); switch (dir) { case SCROLL_UP: gInsertSymbolInfo.selected_row--; if (gInsertSymbolInfo.selected_row < 0) { gInsertSymbolInfo.selected_row = TGIS_ROWS-1; } break; case SCROLL_DOWN: gInsertSymbolInfo.selected_row++; if (gInsertSymbolInfo.selected_row >= TGIS_ROWS) { gInsertSymbolInfo.selected_row = 0; } break; case SCROLL_LEFT: gInsertSymbolInfo.selected_col--; if (gInsertSymbolInfo.selected_col < 0) { gInsertSymbolInfo.selected_col = TGIS_COLS-1; } break; case SCROLL_RIGHT: gInsertSymbolInfo.selected_col++; if (gInsertSymbolInfo.selected_col >= TGIS_COLS) { gInsertSymbolInfo.selected_col = 0; } break; } } else { switch (dir) { case SCROLL_UP: gInsertSymbolInfo.selected_row = TGIS_ROWS-1; gInsertSymbolInfo.selected_col = TGIS_COLS-1; break; case SCROLL_DOWN: gInsertSymbolInfo.selected_row = 0; gInsertSymbolInfo.selected_col = 0; break; case SCROLL_LEFT: gInsertSymbolInfo.selected_row = TGIS_ROWS-1; gInsertSymbolInfo.selected_col = TGIS_COLS-1; break; case SCROLL_RIGHT: gInsertSymbolInfo.selected_row = 0; gInsertSymbolInfo.selected_col = 0; break; } gInsertSymbolInfo.something_selected = TRUE; } while (!InsertSymbolSelectedValid(gInsertSymbolInfo.selected_row, gInsertSymbolInfo.selected_col)) { switch (dir) { case SCROLL_UP: gInsertSymbolInfo.selected_row--; if (gInsertSymbolInfo.selected_row < 0) { gInsertSymbolInfo.selected_row = TGIS_ROWS-1; } break; case SCROLL_DOWN: gInsertSymbolInfo.selected_row++; if (gInsertSymbolInfo.selected_row >= TGIS_ROWS) { gInsertSymbolInfo.selected_row = 0; } break; case SCROLL_LEFT: gInsertSymbolInfo.selected_col--; if (gInsertSymbolInfo.selected_col < 0) { gInsertSymbolInfo.selected_col = TGIS_COLS-1; } break; case SCROLL_RIGHT: gInsertSymbolInfo.selected_col++; if (gInsertSymbolInfo.selected_col >= TGIS_COLS) { gInsertSymbolInfo.selected_col = 0; } break; } } SetupControls(pTdgtBase); RedrawControls(pTdgtBase, SKIP_NONE); return FALSE; } static int HandleChar(pTdgtBase, key_sym, buf, has_ch) TdgtBase *pTdgtBase; KeySym key_sym; char *buf; int has_ch; { return FALSE; } /* --------------- TdgtInsertSymbolDlgKeyPressEvHandlerCallback --------------- */ static XComposeStatus c_stat; static int TdgtInsertSymbolDlgKeyPressEvHandlerCallback(pTdgtBase, pXEv) TdgtBase *pTdgtBase; XEvent *pXEv; { InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); int has_ch=0; char buf[80]; KeySym key_sym=(KeySym)0; XKeyEvent *key_ev=NULL; if (pXEv->type != KeyPress) return FALSE; if (pisdi == NULL) return FALSE; key_ev = (&(pXEv->xkey)); has_ch = XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); TranslateKeys(buf, &key_sym); if (CharIsESC(key_ev, buf, key_sym, &has_ch)) { HideTdgtInsertSymbolDialogBox(); } else if (CharIsCRorLF(key_ev, buf, key_sym, &has_ch)) { return HandleCRorLF(pTdgtBase); } else if (CharIsTAB(key_ev, buf, key_sym, &has_ch)) { return HandleTab(pTdgtBase); } else if (CharIsCntrlSpace(key_ev, buf, key_sym, &has_ch)) { HideTdgtInsertSymbolDialogBox(); } else if (CharIsBS(key_ev, buf, key_sym, &has_ch, FALSE)) { return HandleBackSpace(pTdgtBase); } else if (key_sym==XK_Up || key_sym==XK_KP_Up || key_sym==XK_Down || key_sym==XK_KP_Down || key_sym==XK_Left || key_sym==XK_KP_Left || key_sym==XK_Right || key_sym==XK_KP_Right || (key_sym>'\040' && key_sym<='\177' && (key_ev->state & ControlMask) == ControlMask)) { return HandleCursorKey(pTdgtBase, key_sym); } else if (key_sym>='\040' && key_sym<='\177') { return HandleChar(pTdgtBase, key_sym, buf, has_ch); } return FALSE; } /* --------------------- ShowTdgtInsertSymbolDialogBox --------------------- */ void ShowTdgtInsertSymbolDialogBox() { TidgetInfo *pti=gInsertSymbolInfo.dialogbox_tidgetinfo; InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pti->userdata); TidgetManagerSetWantAllKeyPressEvents(pti, TRUE); gInsertSymbolInfo.mapped = TRUE; MapTidget(pti); if (pisdi != NULL) { ClearAllControls((TdgtBase*)(pti->tidget)); SetupControls((TdgtBase*)(pti->tidget)); } } /* --------------------- HideTdgtInsertSymbolDialogBox --------------------- */ void HideTdgtInsertSymbolDialogBox() { TidgetManagerSetWantAllKeyPressEvents(NULL, FALSE); TidgetSetHasFocus(FALSE); gInsertSymbolInfo.mapped = FALSE; XUnmapWindow(mainDisplay, gInsertSymbolInfo.dialogbox_tidgetinfo->tci.win); if (warpToWinCenter) { XWarpPointer(mainDisplay, None, drawWindow, 0, 0, 0, 0, (int)(ZOOMED_SIZE(drawWinW)>>1), (int)(ZOOMED_SIZE(drawWinH)>>1)); } } /* --------------------- CreateTdgtInsertSymbolDialogBox --------------------- */ static int TdgtInsertSymbolDlgSetEntries(pti, dsp_ptr, entries, num_entries, marked_index) TidgetInfo *pti; DspList *dsp_ptr; char **entries; int num_entries, marked_index; { return TRUE; } static int TdgtInsertSymbolDlgSetMsg(pti, msg) TidgetInfo *pti; char *msg; { return TRUE; } static void InitTdgtInsertSymbolDlgInfo(pti) TidgetInfo *pti; { InsertSymbolDlgInfo *pisdi=NULL; if (pti == NULL) return; pisdi = (InsertSymbolDlgInfo*)(pti->userdata); if (pisdi == NULL) return; pisdi->screen_w = DisplayWidth(mainDisplay, mainScreen); pisdi->screen_h = DisplayHeight(mainDisplay, mainScreen); TdgtInsertSymbolDlgSetMsg(pti, ""); pisdi->def_btn_id = ID_INSSYM_BTN_OK; } typedef struct tagCreateBtnInfo { char *text; int ctl_id; } CreateBtnInfo; static CreateBtnInfo cbi[] = { { "Insert Symbol", ID_INSSYM_BTN_ADD }, { "Insert and Close", ID_INSSYM_BTN_OK }, { "Close", ID_INSSYM_BTN_CANCEL }, { NULL, 0 } }; static int CreateInsertSymbolButtons(pTdgtBase) TdgtBase *pTdgtBase; { InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); TdgtBtnRow *pTdgtBtnRow=pisdi->btn_row_ctl; int i=0; for (i=0; cbi[i].text != NULL; i++) { TdgtBtn *pTdgtBtn=NULL; int btn_w=0, btn_h=0; CalcTdgtBtnDim(cbi[i].text, 8, TDGTBTN_DEF_H_PAD, TDGTBTN_DEF_V_PAD, &btn_w, &btn_h); pTdgtBtn = CreateTdgtBtn(pTdgtBtnRow->pti->tci.win, pTdgtBtnRow->pti, cbi[i].ctl_id, 0, 0, btn_w, btn_h, TDGTBTN_DEF_H_PAD, TDGTBTN_DEF_V_PAD, TGMUTYPE_TEXT, TDGTBTN_CLICK, TGBS_NORMAL, STYLE_NR, cbi[i].text, NULL); if (pTdgtBtn == NULL) { DestroyTidget(&pTdgtBase->pti); return FALSE; } if (!TdgtBtnRowAddBtn(pTdgtBtnRow, pTdgtBtn)) { DestroyTidget(&pTdgtBase->pti); return FALSE; } } return TRUE; } static void AdjustDialogBoxWidth(dpy, pTdgtBase) Display *dpy; TdgtBase *pTdgtBase; { InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); int max_w=0, bottom=0, h_pad=pTdgtBase->pti->tci.h_pad, cur_x=0, cur_y=0; int v_pad=pTdgtBase->pti->tci.v_pad, end_y=0; SimpleWinInfo *pswi=NULL; /* hue edit */ pswi = (&(pisdi->sym_pixmap_ctl->pti->tci.win_info)); max_w = pswi->w; bottom = pisdi->btn_row_ctl->pti->tci.win_info.y + pisdi->btn_row_ctl->pti->tci.win_info.h; cur_x = windowPadding + h_pad; cur_y = windowPadding + v_pad; /* sym_pixmap */ pswi = (&(pisdi->sym_pixmap_ctl->pti->tci.win_info)); end_y = pswi->y+pswi->h; /* button row */ pswi = (&(pisdi->btn_row_ctl->pti->tci.win_info)); pswi->w = max_w; TidgetMoveResize(pisdi->btn_row_ctl->pti, pswi->x, pswi->y, pswi->w, pswi->h); pswi = (&(pTdgtBase->pti->tci.win_info)); pswi->w = max_w+(windowPadding<<1)+(h_pad<<1); pswi->h = bottom+windowPadding+v_pad; TidgetMoveResize(pTdgtBase->pti, pswi->x, pswi->y, pswi->w, pswi->h); } static void TdgtInsertSymbolDlgWmDeleteCallback(pTdgtBase) TdgtBase *pTdgtBase; { InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); if (pisdi == NULL) return; HideTdgtInsertSymbolDialogBox(); } static int TdgtInsertSymbolDlgFocusCallback(pTdgtBase, cmd_type, cmd_arg, pv_cmd_userdata) TdgtBase *pTdgtBase; int cmd_type, cmd_arg; void *pv_cmd_userdata; { InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); if (pisdi == NULL) return FALSE; switch (cmd_type) { case TDGTCMD_CAN_HANDLE_FOCUS_CHANGE: return TRUE; case TDGTCMD_REMOVE_FOCUS: InsertSymbolDlgRemoveFocus(pTdgtBase); return TRUE; } return FALSE; } static void AdjustDialogBoxSize(dpy, pTdgtBase) Display *dpy; TdgtBase *pTdgtBase; { InsertSymbolDlgInfo *pisdi=(InsertSymbolDlgInfo*)(pTdgtBase->pti->userdata); int base_win_x=0, base_win_y=0, base_win_w=0, base_win_h=0; XWMHints wmhints; XSizeHints sizehints; if (pTdgtBase == NULL) return; AdjustDialogBoxWidth(dpy, pTdgtBase); base_win_w = pTdgtBase->pti->tci.win_info.w; base_win_h = pTdgtBase->pti->tci.win_info.h; memset(&wmhints, 0, sizeof(XWMHints)); wmhints.flags = InputHint | StateHint; wmhints.input = True; wmhints.initial_state = NormalState; XSetWMHints(dpy, pTdgtBase->pti->tci.win, &wmhints); base_win_x = (base_win_w > pisdi->screen_w) ? 0 : ((pisdi->screen_w-base_win_w)>>1); base_win_y = (base_win_h > pisdi->screen_h) ? 0 : ((pisdi->screen_h-base_win_h)/3); XMoveResizeWindow(dpy, pTdgtBase->pti->tci.win, base_win_x, base_win_y, base_win_w, base_win_h); sizehints.flags = PPosition | PSize | USPosition | PMinSize | PMaxSize; sizehints.x = base_win_x; sizehints.y = base_win_y; sizehints.width = sizehints.min_width = sizehints.max_width = base_win_w; sizehints.height = sizehints.min_height = sizehints.max_height = base_win_h; #ifdef NOTR4MODE XSetNormalHints(dpy, pTdgtBase->pti->tci.win, &sizehints); #else XSetWMNormalHints(dpy, pTdgtBase->pti->tci.win, &sizehints); #endif XSetTransientForHint(dpy, pTdgtBase->pti->tci.win, mainWindow); } static int SetupInsertSymbolPixmap(pisdi) InsertSymbolDlgInfo *pisdi; { int row=0, y=0; char ch=(char)0x20; XGCValues values; Pixmap pixmap=gInsertSymbolInfo.sym_pixmap; GC gc=gInsertSymbolInfo.gc; int padding=gInsertSymbolInfo.padding; int asc=gInsertSymbolInfo.font_asc; if (pixmap == None) return FALSE; values.foreground = myBgPixel; XChangeGC(mainDisplay, gc, GCForeground, &values); XFillRectangle(mainDisplay, pixmap, gc, 0, 0, gInsertSymbolInfo.pixmap_w, gInsertSymbolInfo.pixmap_h); values.foreground = myFgPixel; XChangeGC(mainDisplay, gc, GCForeground, &values); for (row=0; row < TGIS_ROWS; row++) { int col=0, x=0; if (row == 6) { ch = (char)0xa0; } else { for (col=0; col < TGIS_COLS; col++) { XDrawRectangle(mainDisplay, pixmap, gc, x, y, gInsertSymbolInfo.a_symbol_w+1, gInsertSymbolInfo.a_symbol_h+1); XDrawString(mainDisplay, pixmap, gc, x+padding, y+padding+asc, &ch, 1); x += gInsertSymbolInfo.a_symbol_w+1; ch++; } } y += gInsertSymbolInfo.a_symbol_h+1; } return TRUE; } TidgetInfo *CreateTdgtInsertSymbolDialogBox(dpy, parent_win) Display *dpy; Window parent_win; /* should be the rootWindow */ { int cur_x=0, cur_y=0, v_gap=20, h_pad=0, v_pad=0; int vh_padding=0, h_gap=14, end_y=0, rgbhsv_width=0; TdgtBase *pTdgtBase=NULL; InsertSymbolDlgInfo *pisdi=NULL; char caption[MAXSTRING]; TidgetSetFocusWindow(None); if (!colorDisplay || mainVisual->class != TrueColor) { sprintf(gszMsgBox, TgLoadString(STID_COLOR_WHEEL_NOT_AVAIL)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pisdi); return NULL; } pisdi = (InsertSymbolDlgInfo*)malloc(sizeof(InsertSymbolDlgInfo)); if (pisdi == NULL) FailAllocMessage(); memset(pisdi, 0, sizeof(InsertSymbolDlgInfo)); memset(&pisdi->tci, 0, sizeof(TrueColorInfo)); if (!SetupInsertSymbolPixmap(pisdi)) { free(pisdi); return NULL; } if (boldMsgFontSet != NULL || boldMsgFontPtr != NULL) { rgbhsv_width = BoldMsgTextWidth(boldMsgFontPtr, "9999", 4); } else if (msgFontSet != NULL || msgFontPtr != NULL) { rgbhsv_width = MsgTextWidth(msgFontPtr, "9999", 4); } else { rgbhsv_width = defaultFontWidth * 4; } h_pad = TDGTBASE_DEF_H_PAD; v_pad = TDGTBASE_DEF_V_PAD; if (msgFontSet != NULL || msgFontPtr != NULL) { vh_padding = (msgFontWidth<<1); } else { vh_padding = (defaultFontWidth<<1); } cur_x = vh_padding+windowPadding; cur_y = vh_padding+windowPadding; sprintf(caption, TgLoadString(STID_TOOL_COLOR_WHEEL), TOOL_NAME); pTdgtBase = CreateTdgtBase(parent_win, NULL, ID_INSSYM_DIALOG, 0, 0, 100, 100, vh_padding, vh_padding, (dialogboxUse3DBorder ? TGBS_RAISED : TGBS_NORMAL), caption); if (pTdgtBase == NULL) { free(pisdi); return NULL; } pTdgtBase->pti->userdata = pisdi; InitTdgtInsertSymbolDlgInfo(pTdgtBase->pti); /* sym_pixmap */ pisdi->sym_pixmap_x = cur_x; pisdi->sym_pixmap_y = cur_y; pisdi->sym_pixmap_ctl = CreateTdgtDraw(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_INSSYM_SYM_AREA, cur_x, cur_y, gInsertSymbolInfo.pixmap_w, gInsertSymbolInfo.pixmap_h, TDGTDRAW_DEF_H_PAD, TDGTDRAW_DEF_V_PAD, TGBS_LOWRED, NULL); if (pisdi->sym_pixmap_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } TdgtDrawSetRedrawCallback(pisdi->sym_pixmap_ctl, HSRedrawCallback); TdgtDrawSetEvHandlerCallback(pisdi->sym_pixmap_ctl, HSEvHandlerCallback); TdgtDrawSetSendCmdCallback(pisdi->sym_pixmap_ctl, HSSendCmdCallback); cur_x += pisdi->sym_pixmap_ctl->pti->tci.win_info.w + h_gap; end_y = cur_y + pisdi->sym_pixmap_ctl->pti->tci.win_info.h - windowPadding; /* buttons */ cur_x = vh_padding+windowPadding; cur_y = end_y + v_gap; pisdi->btn_row_ctl = CreateTdgtBtnRow(pTdgtBase->pti->tci.win, pTdgtBase->pti, INVALID, cur_x, cur_y, TDGTBROW_DEF_H_PAD, TDGTBROW_DEF_V_PAD, TGBS_NORMAL, defaultFontWidth, JUST_C); if (pisdi->btn_row_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } if (!CreateInsertSymbolButtons(pTdgtBase)) { DestroyTidget(&pTdgtBase->pti); return NULL; } TdgtInsertSymbolDlgSetEntries(pTdgtBase->pti, NULL, NULL, 0, INVALID); /* * Specify that the base tidget will handle all the KeyPress events * in all its children tidgets. */ TdgtBaseWillHandleKeyPressEvents(pTdgtBase, TdgtInsertSymbolDlgKeyPressEvHandlerCallback); /* * Specify that the base tidget will handle all the KeyPress events * in all its children tidgets. */ TdgtBaseSetWmDeleteCallback(pTdgtBase, TdgtInsertSymbolDlgWmDeleteCallback); /* * Specify a callback function to answer some focus related questions. */ TdgtBaseSetFocusCallback(pTdgtBase, TdgtInsertSymbolDlgFocusCallback); AdjustDialogBoxSize(dpy, pTdgtBase); TidgetSetFocusWindow(pisdi->sym_pixmap_ctl->pti->tci.win); return pTdgtBase->pti; } /* --------------------- DestroyTdgtInsertSymbolDialogBox --------------------- */ void DestroyTdgtInsertSymbolDialogBox(dpy, pti) Display *dpy; TidgetInfo *pti; { InsertSymbolDlgInfo *pisdi=NULL; if (pti == NULL) return; pisdi = (InsertSymbolDlgInfo*)(pti->userdata); if (pisdi != NULL) { free(pisdi); } DestroyTidget(&pti); } /* --------------------- TdgtInsertSymbolDlgLoop --------------------- */ static int HandleTdgtNotifyEvent(pTdgtBase, pTdgtNtfy) TdgtBase *pTdgtBase; TdgtNtfy *pTdgtNtfy; { switch (pTdgtNtfy->ctl_id) { case ID_INSSYM_BTN_ADD: InsertSymbolInAppl(pTdgtBase); break; case ID_INSSYM_BTN_OK: if (InsertSymbolInAppl(pTdgtBase)) { HideTdgtInsertSymbolDialogBox(); } break; case ID_INSSYM_BTN_CANCEL: HideTdgtInsertSymbolDialogBox(); break; } return FALSE; } int TdgtInsertSymbolDlgLoop(pti) TidgetInfo *pti; { TdgtBase *pTdgtBase=(TdgtBase*)(pti->tidget); int which_btn_clicked=INVALID, first_time_config=TRUE; if (pTdgtBase == NULL) return which_btn_clicked; while (gInsertSymbolInfo.mapped) { XEvent xev; TdgtNtfy tdgt_notify; TidgetInfo *handling_pti=NULL; XNextEvent(mainDisplay, &xev); if (xev.type == MotionNotify) { /* do nothing */ } else if (xev.type == ConfigureNotify && xev.xany.window == pti->tci.win) { if (first_time_config) { first_time_config = FALSE; if (warpToWinCenter) { /* does not work because the window has been moved */ XWarpPointer(mainDisplay, None, pti->tci.win, 0, 0, 0, 0, (pti->tci.win_info.w>>1), (pti->tci.win_info.h>>1)); } } } else if (xev.type == Expose) { ExposeEventHandler(&xev, FALSE); } else if (xev.type == ConfigureNotify && xev.xany.window==mainWindow) { Reconfigure(FALSE); } else if (xev.type == KeyPress) { TidgetManagerHandleAllKeyPressEvent(&xev); } else if (IsTdgtNotifyEvent(pti, &xev, &tdgt_notify)) { HandleTdgtNotifyEvent(pTdgtBase, &tdgt_notify); } else if (IsTidgetEvent(pti, &xev, &handling_pti)) { TidgetEventHandler(pti, &xev, handling_pti); } else { /* anything else? */ } } return which_btn_clicked; } /* --------------------- Init & Clean Up --------------------- */ int InitTdgtInsertSymbolDlg() { return TRUE; } void CleanUpTdgtInsertSymbolDlg() { } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/imgproc.e����������������������������������������������������������������������������0000644�0000764�0000764�00000010565�11602233311�014600� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/imgproc.e,v 1.18 2011/05/16 16:21:58 william Exp $ */ #ifndef _IMGPROC_E_ #define _IMGPROC_E_ extern int numImageProc; extern int gnInImageProc; extern int gnConvolving; extern int gnNumNewColorsInPixmapFile; extern char gszImageProcXPmFile[MAXPATHLENGTH+1]; extern float gfVectorWarpSoftness; extern int threshFillReplaceEnabled; extern int fillReplaceRedThresh; extern int fillReplaceGreenThresh; extern int fillReplaceBlueThresh; #ifdef _INCLUDE_FROM_IMGPROC_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_IMGPROC_C_*/ extern void CleanUpConvolution ARGS_DECL((void)); extern int DoConvolution ARGS_DECL((FILE*, XImage *image, XImage *bitmap_image, int W, int H, struct XPmRec *)); extern FILE *GetImageProcOutputFileName ARGS_DECL((char *pszPath, int path_buf_sz, int *pnShortName, char **ppszRest)); extern void RGBtoHSV ARGS_DECL((int r, int g, int b, int *h, double *s, int *v)); extern void HSVtoRGB ARGS_DECL((int h, double s, int v, int *r, int *g, int *b)); extern void MakeGray ARGS_DECL((void)); extern void InvertColor ARGS_DECL((void)); extern void InterpolateColor ARGS_DECL((void)); extern void BrightenDarken ARGS_DECL((void)); extern void ChangeSaturation ARGS_DECL((void)); extern void ChangeHue ARGS_DECL((void)); extern void ContrastEnhance ARGS_DECL((void)); extern void ColorBalance ARGS_DECL((void)); extern void Gamma ARGS_DECL((char*)); extern void EdgeDetect ARGS_DECL((void)); extern void Emboss ARGS_DECL((void)); extern void ReduceColors ARGS_DECL((void)); extern void ReduceToPixmapColors ARGS_DECL((void)); extern void ReduceToMobileWebSafeColors ARGS_DECL((void)); extern void SetDefaultColorLevels ARGS_DECL((void)); extern void ReduceToDefaultColors ARGS_DECL((void)); extern void DefaultErrorDiffuse ARGS_DECL((void)); extern void Spread ARGS_DECL((void)); extern void Sharpen ARGS_DECL((void)); extern void Blur3 ARGS_DECL((void)); extern void Blur5 ARGS_DECL((void)); extern void Blur7 ARGS_DECL((void)); extern void RunBggen ARGS_DECL((void)); extern void CircularBggen ARGS_DECL((void)); extern void SimpleRectBggen ARGS_DECL((void)); extern void RegenerateImage ARGS_DECL((void)); extern void CreatePixmapFromSelected ARGS_DECL((void)); extern void CropImage ARGS_DECL((void)); extern void GetColor ARGS_DECL((void)); extern void ReplaceColor ARGS_DECL((void)); extern void ReplaceColorWithTrans ARGS_DECL((void)); extern void FloodFill ARGS_DECL((void)); extern void ToggleFloodReplaceColorThreshold ARGS_DECL((void)); extern void SetFloodReplaceColorThreshold ARGS_DECL((void)); extern void CreateContour ARGS_DECL((void)); extern void Subtract ARGS_DECL((void)); extern void XorColors ARGS_DECL((void)); extern void AlphaCombine ARGS_DECL((void)); extern int BuildTrapMapNode ARGS_DECL((TrapMapSpec*, int*, TrapMap*)); extern void VectorWarp ARGS_DECL((void)); extern void CleanUpImageProc ARGS_DECL((void)); extern void InitImageProc ARGS_DECL((void)); extern int RefreshImageProcMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateImageProcMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int ImageProcMenu ARGS_DECL((int X, int Y, int TrackMenubar)); #ifdef _INCLUDE_FROM_IMGPROC_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_IMGPROC_C_*/ #endif /*_IMGPROC_E_*/ �������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/����������������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233155�013407� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/ru/�������������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233155�014035� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/ru/Imakefile����������������������������������������������������������������������0000644�0000764�0000764�00000002235�10064673302�015653� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#ifndef XCOMM #define XCOMM # #endif #ifndef NullParameter #define NullParameter #endif XCOMM XCOMM Author: Vladimir Ignatov <gazett@mail.ru>, 1999 XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/ru/Imakefile,v 1.1 2004/06/18 23:12:02 william Exp $ XCOMM #include <../Po.tmpl> CURRENTDIR =./ SRCS = $(CURRENTDIR)*.po PACKAGE = tgif CATALOGS = ru.mo POFILES = ru.po POTFILES=../../menuinfo.c ../../strtbl.c .SUFFIXES: .SUFFIXES: .mo .po .po.mo: msgfmt -o $@ $< all:: $(CATALOGS) $(PACKAGE).pot: $(POTFILES) xgettext --default-domain=$(PACKAGE) \ --add-comments --keyword=_ --keyword=N_ $(POTFILES) if cmp -s $(PACKAGE).po $(PACKAGE).pot; then \ rm -f $(PACKAGE).po; \ else \ mv -f $(PACKAGE).po $(PACKAGE).pot; \ fi install:: $(CATALOGS) $(MKINSTALLDIRS) $(NLSDIR) chmod 755 $(NLSDIR) for n in $(CATALOGS) __DuMmY ; do \ if test "$$n" -a "$$n" != "__DuMmY" ; then \ l=`basename $$n .mo`; \ $(MKINSTALLDIRS) $(NLSDIR)/$$l/LC_MESSAGES; \ chmod 755 $(NLSDIR)/$$l; \ chmod 755 $(NLSDIR)/$$l/LC_MESSAGES; \ $(INSTALL) -m 644 $$n $(NLSDIR)/$$l/LC_MESSAGES/$(PACKAGE).mo; \ fi; \ done clean:: rm -f $(CATALOGS) �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/ru/ru.po��������������������������������������������������������������������������0000644�0000764�0000764�00001125226�10064673302�015037� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# Author: Vladimir Ignatov <gazett@mail.ru>, 1999 # Modified by: # Andrew W. Nosenko <awn@bcs.zp.ua>, 2002 # # Small glossary: # # set "ŐÓÔÁÎÏŚÉÔŰ" # specify "ŐËÁÚÁÔŰ" # poly "ÌÉÎÉŃ". èÏÔŃ ÎÁÓËÏÌŰËÏ ÜÔÏ ËÏÒÒĆËÔÎÏ? # vertex "ŚĆÒÛÉÎÁ". éÌÉ "ŐÚÌÏŚÁŃ ÔÏȚËÁ" ÂŐÄĆÔ ĐÏÎŃÔÎĆĆ? # # @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/ru/ru.po,v 1.1 2004/06/18 23:12:02 william Exp $ # msgid "" msgstr "" "Project-Id-Version: tgif-4.1.42\n" "POT-Creation-Date: 2002-10-01 20:58+0300\n" "PO-Revision-Date: 2002-10-04 06:52+0300\n" "Last-Translator: \"Andrew W. Nosenko\" <awn@bcs.zp.ua>\n" "Language-Team: Russian\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=koi8-r\n" "Content-Transfer-Encoding: 8bit\n" #: ../../menuinfo.c:59 msgid "Enter select/move/resize object mode" msgstr "òĆÖÉÍ ŚÙÄĆÌĆÎÉŃ/ĐĆÒĆÍĆĘĆÎÉŃ/ÉÚÍĆÎĆÎÉŃ ÒÁÚÍĆÒÏŚ ÏÂßĆËÔÁ" #: ../../menuinfo.c:61 msgid "Enter draw text mode" msgstr "òĆÖÉÍ ÒÉÓÏŚÁÎÉŃ/ŚŚÏÄÁ ÔĆËÓÔÁ" #: ../../menuinfo.c:63 msgid "Enter draw rectangle mode" msgstr "òĆÖÉÍ ÒÉÓÏŚÁÎÉŃ ĐÒŃÍÏŐÇÏÌŰÎÉËÏŚ" #: ../../menuinfo.c:65 msgid "Enter draw corner oval mode" msgstr "" #: ../../menuinfo.c:67 msgid "Enter draw center oval mode" msgstr "" #: ../../menuinfo.c:69 msgid "Enter draw edge circle mode" msgstr "" #: ../../menuinfo.c:71 msgid "Enter draw poly/open spline mode" msgstr "òĆÖÉÍ ÒÉÓÏŚÁÎÉŃ ÌÉÎÉÊ/ÏÔËÒÙÔÙÈ ÓĐÌÁÊÎÏŚ" #: ../../menuinfo.c:73 msgid "Enter draw polygon/close spline mode" msgstr "òĆÖÉÍ ÒÉÓÏŚÁÎÉŃ ÍÎÏÇÏŐÇÏÌŰÎÉËÏŚ/ÚÁËÒÙÔÙÈ ÓĐÌÁÊÎÏŚ" #: ../../menuinfo.c:75 msgid "Enter draw arc mode (specify center first)" msgstr "òĆÖÉÍ ÒÉÓÏŚÁÎÉŃ ÄŐÇ (ÓÎÁȚÁÌÁ ŐËÁÚÙŚÁĆÔÓŃ ĂĆÎÔÒ)" #: ../../menuinfo.c:77 msgid "Enter draw arc mode (specify endpoints first)" msgstr "òĆÖÉÍ ÒÉÓÏŚÁÎÉŃ ÄŐÇ (ÓÎÁȚÁÌÁ ŐËÁÚÙŚÁĆÔÓŃ ËÏÎĆȚÎÁŃ ÔÏȚËÁ)" #: ../../menuinfo.c:80 msgid "Enter draw rcbox mode" msgstr "" #: ../../menuinfo.c:82 msgid "Enter draw freehand poly/open spline mode" msgstr "òĆÖÉÍ ÒÉÓÏŚÁÎÉŃ ÌÉÎÉÊ \"ÏÔ ÒŐËÉ\"/ÏÔËÒÙÔÙĆ ÓĐÌÁÊÎÙ" #: ../../menuinfo.c:85 msgid "Enter select/move vertices mode" msgstr "òĆÖÉÍ ŚÙÄĆÌĆÎÉŃ/ĐĆÒĆÍĆĘĆÎÉŃ ŚĆÒÛÉÎ" #: ../../menuinfo.c:87 msgid "Enter rotate/shear object mode" msgstr "òĆÖÉÍ ŚÒÁĘĆÎÉŃ/ÉÓËÁÖĆÎÉŃ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:98 msgid "No arrows for a poly/open spline" msgstr "ìÉÎÉŃ/ÏÔËÒÙÔÙÊ ÓĐÌÁÊÎ ÂĆÚ ÓÔÒĆÌÏË" #: ../../menuinfo.c:101 msgid "An arrow at the end of a poly/open spline" msgstr "óÔÒĆÌËÁ Ś ËÏÎĂĆ ÌÉÎÉÉ/ÏÔËÒÙÔÏÇÏ ÓĐÌÁÊÎÁ" #: ../../menuinfo.c:104 msgid "An arrow at the beginning of a poly/open spline" msgstr "óÔÒĆÌËÁ Ś ÎÁȚÁÌĆ ÌÉÎÉÉ/ÏÔËÒÙÔÏÇÏ ÓĐÌÁÊÎÁ" #: ../../menuinfo.c:107 msgid "Arrows at both ends of a poly/open spline" msgstr "óÔÒĆÌËÉ ÎÁ ÏÂÏÉÈ ËÏÎĂÁÈ ÌÉÎÉÉ/ÏÔËÒÙÔÏÇÏ ÓĐÌÁÊÎÁ" #: ../../menuinfo.c:116 msgid "Straight line segments" msgstr "" #: ../../menuinfo.c:118 msgid "Open/closed splines" msgstr "" #: ../../menuinfo.c:120 #, fuzzy msgid "Interpolated splines" msgstr "đÒĆÏÂÒÁÚÏŚÁÔŰ Ś ÓĐÌÁÊÎ" #: ../../menuinfo.c:130 msgid "Set horizontal alignment to none" msgstr "" #: ../../menuinfo.c:133 msgid "Set horizontal alignment to left aligned" msgstr "" #: ../../menuinfo.c:136 msgid "Set horizontal alignment to center aligned" msgstr "" #: ../../menuinfo.c:139 msgid "Set horizontal alignment to right aligned" msgstr "" #: ../../menuinfo.c:142 msgid "Set horizontal distribution to equal-spacing" msgstr "" #: ../../menuinfo.c:151 msgid "Set vertical alignment to none" msgstr "" #: ../../menuinfo.c:154 msgid "Set vertical alignment to top aligned" msgstr "" #: ../../menuinfo.c:157 msgid "Set vertical alignment to middle aligned" msgstr "" #: ../../menuinfo.c:160 msgid "Set vertical alignment to bottom aligned" msgstr "" #: ../../menuinfo.c:163 msgid "Set vertical distribution to equal-spacing" msgstr "" #: ../../menuinfo.c:172 msgid "Set constrained move mode" msgstr "" #: ../../menuinfo.c:174 msgid "Set unconstrained move mode" msgstr "" #: ../../menuinfo.c:182 msgid "Make text objects not stretchable" msgstr "" #: ../../menuinfo.c:184 msgid "Make text objects stretchable" msgstr "" #: ../../menuinfo.c:195 #, fuzzy msgid "Stacked page mode" msgstr "óÔÒÁÎÉĂÙ ÎÁÂÏÒÏÍ" #: ../../menuinfo.c:197 #, fuzzy msgid "Tiled page mode" msgstr "óÔÒÁÎÉĂÙ ÍÏÚÁÉËÏÊ" #: ../../menuinfo.c:205 msgid "Make fill and pen patterns opaque" msgstr "" #: ../../menuinfo.c:207 msgid "Make fill and pen patterns transparent" msgstr "" #: ../../menuinfo.c:215 ../../menuinfo.c:1191 msgid "Portrait" msgstr "đÏÒÔÒĆÔ" #: ../../menuinfo.c:215 ../../menuinfo.c:1191 msgid "Portrait page style" msgstr "" #: ../../menuinfo.c:217 ../../menuinfo.c:1193 msgid "Landscape" msgstr "ìÁÎÄÛÁÆÔ" #: ../../menuinfo.c:217 ../../menuinfo.c:1193 msgid "Lanscape page style" msgstr "" #: ../../menuinfo.c:229 msgid "Roman" msgstr "îÏÒÍÁÌŰÎÙÊ" #: ../../menuinfo.c:229 #, fuzzy msgid "Roman text style" msgstr "óÔÉÌŰ ÔĆËÓÔÁ" #: ../../menuinfo.c:231 msgid "Bold" msgstr "öÉÒÎÙÊ" #: ../../menuinfo.c:231 #, fuzzy msgid "Bold text style" msgstr "óÔÉÌŰ ÔĆËÓÔÁ" #: ../../menuinfo.c:233 msgid "Italic" msgstr "ëŐÒÓÉŚ" #: ../../menuinfo.c:233 msgid "Italic text style" msgstr "" #: ../../menuinfo.c:235 msgid "BoldItalic" msgstr "öÉÒÎÙÊëŐÒÓÉŚ" #: ../../menuinfo.c:235 msgid "Bold-italic text style" msgstr "" #: ../../menuinfo.c:238 msgid "Left" msgstr "śÌĆŚÏ" #: ../../menuinfo.c:238 msgid "Left justified text" msgstr "" #: ../../menuinfo.c:240 msgid "Center" msgstr "đÏ ĂĆÎÔÒŐ" #: ../../menuinfo.c:240 msgid "Center justified text" msgstr "" #: ../../menuinfo.c:242 msgid "Right" msgstr "śĐÒÁŚÏ" #: ../../menuinfo.c:242 msgid "Right justified text" msgstr "" #: ../../menuinfo.c:245 msgid "No Underlined" msgstr "îĆđÏÄȚĆÒËÎŐÔÏ" #: ../../menuinfo.c:245 #, fuzzy msgid "No underlined text" msgstr "îĆđÏÄȚĆÒËÎŐÔÏ" #: ../../menuinfo.c:247 msgid "Underlined" msgstr "đÏÄȚĆÒËÎŐÔÏ" #: ../../menuinfo.c:247 #, fuzzy msgid "Underlined text" msgstr "đÏÄȚĆÒËÎŐÔÏ" #: ../../menuinfo.c:257 msgid "Next Page" msgstr "óÌĆÄ. ÓÔÒÁÎÉĂÁ" #: ../../menuinfo.c:257 msgid "Go to next page" msgstr "đĆÒĆÊÔÉ ÎÁ ÓÌĆÄŐÀĘŐÀ ÓÔÒÁÎÉĂŐ" #: ../../menuinfo.c:258 msgid "Prev Page" msgstr "đÒĆÄ. ÓÔÒÁÎÉĂÁ" #: ../../menuinfo.c:258 msgid "Go to previous page" msgstr "đĆÒĆÊÔÉ ÎÁ ĐÒĆÄÙÄŐĘŐÀ ÓÔÒÁÎÉĂŐ" #: ../../menuinfo.c:259 msgid "Goto Page..." msgstr "đĆÒĆÊÔÉ ÎÁ..." #: ../../menuinfo.c:259 msgid "Go to a specified page" msgstr "đĆÒĆÊÔÉ ÎÁ ŐËÁÚÁÎÎŐÀ ÓÔÒÁÎÉĂŐ" #: ../../menuinfo.c:261 msgid "Name Pages..." msgstr "éÍĆÎÁ ÓÔÒÁÎÉĂ..." #: ../../menuinfo.c:261 msgid "Assign names to pages" msgstr "îÁÚÎÁȚÉÔŰ ÓÔÒÁÎÉĂÁÍ ÉÍĆÎÁ" #: ../../menuinfo.c:263 msgid "Edit Page File Names..." msgstr "òĆÄÁËÔÉÒÏŚÁÔŰ éÍŃæÁÊÌÁóÔÒÁÎÉĂÙ" #: ../../menuinfo.c:264 msgid "Assign file names to pages to be used for PrintOneFilePerPage()" msgstr "" #: ../../menuinfo.c:267 msgid "Add Page Before..." msgstr "äÏÂÁŚÉÔŰ ÓÔÒÁÎÉĂŐ ĐĆÒĆÄ ÔĆËŐĘĆÊ..." #: ../../menuinfo.c:267 msgid "Add a page before the current page" msgstr "äÏÂÁŚÉÔŰ ÓÔÒÁÎÉĂŐ ĐĆÒĆÄ ÔĆËŐĘĆÊ" #: ../../menuinfo.c:269 msgid "Add Page After..." msgstr "äÏÂÁŚÉÔŰ ÓÔÒÁÎÉĂŐ ĐÏÓÌĆ ÔĆËŐĘĆÊ..." #: ../../menuinfo.c:270 msgid "Add a page after the current page" msgstr "äÏÂÁŚÉÔŰ ÓÔÒÁÎÉĂŐ ĐÏÓÌĆ ÔĆËŐĘĆÊ" #: ../../menuinfo.c:271 msgid "Delete Current Page" msgstr "őÄÁÌÉÔŰ ÜÔŐ ÓÔÒÁÎÉĂŐ" #: ../../menuinfo.c:271 msgid "Delete the current page" msgstr "őÄÁÌÉÔŰ ÔĆËŐĘŐÀ ÓÔÒÁÎÉĂŐ" #: ../../menuinfo.c:273 msgid "Delete Pages..." msgstr "őÄÁÌÉÔŰ ÓÔÒÁÎÉĂÙ..." #: ../../menuinfo.c:273 msgid "Delete user-specified pages" msgstr "őÄÁÌÉÔŰ ÓÔÒÁÎÉĂÙ, ŐËÁÚÁÎÎÙĆ ĐÏÌŰÚÏŚÁÔĆÌĆÍ" #: ../../menuinfo.c:276 ../../menuinfo.c:299 ../../menuinfo.c:634 msgid "Print One Page" msgstr "đĆȚÁÔŰ ÏÄÎÏÊ ÓÔÒÁÎÉĂÙ" #: ../../menuinfo.c:276 msgid "Print the curret page" msgstr "đĆȚÁÔŰ ÔĆËŐĘĆÊ ÓÔÒÁÎÉĂÙ" #: ../../menuinfo.c:278 ../../menuinfo.c:636 msgid "Print Pages..." msgstr "đĆȚÁÔŰ ÓÔÒÁÎÉĂ..." #: ../../menuinfo.c:278 ../../menuinfo.c:636 msgid "Print user-specified pages" msgstr "đĆȚÁÔÁÔŰ ÓÔÒÁÎÉĂÙ, ŐËÁÚÁÎÎÙĆ ĐÏÌŰÚÏŚÁÔĆÌĆÍ" #: ../../menuinfo.c:280 ../../menuinfo.c:638 #, fuzzy msgid "Print One File Per Page..." msgstr "đĆȚÁÔŰ ÆÁÊÌÁ" #: ../../menuinfo.c:281 ../../menuinfo.c:639 msgid "Print into a separate file for each page" msgstr "" #: ../../menuinfo.c:284 ../../menuinfo.c:302 msgid "Specify Paper Size..." msgstr "őËÁÚÁÔŰ ÒÁÚÍĆÒ ÂŐÍÁÇÉ..." #: ../../menuinfo.c:285 ../../menuinfo.c:303 msgid "Set the physical size of the paper" msgstr "őÓÔÁÎÏŚÉÔŰ ÆÉÚÉȚĆÓËÉÊ ÒÁÚÍĆÒ ÂŐÍÁÇÉ" #: ../../menuinfo.c:286 ../../menuinfo.c:304 msgid "Set Paper Color..." msgstr "őÓÔÁÎÏŚÉÔŰ ĂŚĆÔ ÂŐÍÁÇÉ..." #: ../../menuinfo.c:286 ../../menuinfo.c:304 msgid "Set the color of the paper" msgstr "őÓÔÁÎÏŚÉÔŰ ĂŚĆÔ ÂŐÍÁÇÉ" #: ../../menuinfo.c:294 msgid "Toggle Page Line Shown" msgstr "òÁÚÄĆÌŃÔŰ ÓÔÒÁÎÉĂÙ ÌÉÎÉĆÊ" #: ../../menuinfo.c:295 msgid "Toggle the showing of page boundaries" msgstr "" #: ../../menuinfo.c:297 #, fuzzy msgid "Specify Drawing Size..." msgstr "ïÔÏÂÒÁÖÁĆÍÁŃ ÏÂÌÁÓÔŰ..." #: ../../menuinfo.c:297 msgid "Change the drawing size" msgstr "" #: ../../menuinfo.c:299 msgid "Select and print one of the pages" msgstr "" #: ../../menuinfo.c:312 ../../menuinfo.c:1196 ../../menuinfo.c:1633 msgid "Stacked Page" msgstr "óÔÒÁÎÉĂÁ Ś ÓÔÏĐËĆ" #: ../../menuinfo.c:313 ../../menuinfo.c:1634 #, fuzzy msgid "StackedPage Menu" msgstr "óÔÒÁÎÉĂÙ ÎÁÂÏÒÏÍ" #: ../../menuinfo.c:314 ../../menuinfo.c:1198 ../../menuinfo.c:1635 msgid "Tiled Page" msgstr "óÔÒÁÎÉĂÁ Ś ÍÏÚÁÉËĆ" #: ../../menuinfo.c:315 ../../menuinfo.c:1636 #, fuzzy msgid "TiledPage Menu" msgstr "óÔÒÁÎÉĂÙ ÍÏÚÁÉËÏÊ" #: ../../menuinfo.c:321 msgid "Reduce Colors..." msgstr "őÍĆÎŰÛÉÔŰ ËÏÌÉȚĆÓÔŚÏ ĂŚĆÔÏŚ..." #: ../../menuinfo.c:322 msgid "Reduce the number of colors of a selected image" msgstr "őÍĆÎŰÛÉÔŰ ËÏÌÉȚĆÓÔŚÏ ĂŚĆÔÏŚ ŚÙÄĆÌĆÎÎÏÇÏ ÉÚÏÂÒÁÖĆÎÉŃ" #: ../../menuinfo.c:325 msgid "Set Default Color Levels..." msgstr "őÓÔÁÎÏŚÉÔŰ ÓÔÁÎÄÁÒÔ ÄÌŃ ÇÁÍÍÙ ĂŚĆÔÏŚ..." #: ../../menuinfo.c:326 msgid "Set the number of R G B color levels for the ``standard colors''" msgstr "" #: ../../menuinfo.c:328 msgid "Reduce To Pixmap Colors..." msgstr "đÏ Pixmap-ÆÁÊÌŐ..." #: ../../menuinfo.c:329 msgid "Reduce the colors of a selected image to a the colors in an XPM file" msgstr "" #: ../../menuinfo.c:331 #, fuzzy msgid "Reduce To Default Colors" msgstr "țÉÓÌÏ ĐÏ ŐÍÏÌȚÁÎÉÀ" #: ../../menuinfo.c:332 msgid "Reduce the colors of a selected image to standard colors" msgstr "" #: ../../menuinfo.c:334 msgid "Default Error Diffuse" msgstr "" #: ../../menuinfo.c:335 msgid "Error diffuse to reduce colors of a selected image to standard colors" msgstr "" # FIXME: awn@bcs.zp.ua: ÍÏÖĆÔ ÌŐȚÛĆ "ÄĆÔĆËÔÉÒÏŚÁÎÉĆ ÇÒÁÎÉĂ" ÉÌÉ # "ÏĐÒĆÄĆÌĆÎÉĆ ÇÒÁÎÉĂ"? #: ../../menuinfo.c:343 msgid "Edge Detect" msgstr "śÙÄĆÌĆÎÉĆ ÇÒÁÎÉĂ" #: ../../menuinfo.c:343 msgid "Perform edge-detection on a selected image" msgstr "" #: ../../menuinfo.c:345 msgid "Emboss" msgstr "òĆÌŰĆÆ" #: ../../menuinfo.c:345 msgid "Convert a selected image to gray and then emboss" msgstr "" #: ../../menuinfo.c:348 msgid "Spread..." msgstr "òÁÚÍÁÚÁÔŰ..." #: ../../menuinfo.c:348 msgid "Spread the pixels of a selected image around" msgstr "" #: ../../menuinfo.c:350 msgid "Sharpen" msgstr "Sharpen" #: ../../menuinfo.c:350 msgid "Sharpen a selected image" msgstr "" #: ../../menuinfo.c:352 msgid "Blur (3x3)" msgstr "òÁÚÍÙŚËÁ (3x3)" #: ../../menuinfo.c:352 msgid "Blur a selected image using a 3 by 3 filter" msgstr "" #: ../../menuinfo.c:354 msgid "Blur (5x5)" msgstr "òÁÚÍÙŚËÁ (5x5)" #: ../../menuinfo.c:354 msgid "Blur a selected image using a 5 by 5 filter" msgstr "" #: ../../menuinfo.c:356 msgid "Blur (7x7)" msgstr "òÁÚÍÙŚËÁ (7x7)" #: ../../menuinfo.c:356 msgid "Blur a selected image using a 7 by 7 filter" msgstr "" #: ../../menuinfo.c:364 msgid "Run Bggen..." msgstr "" #: ../../menuinfo.c:365 msgid "Run 'bggen' to create an image using the size of a selected image" msgstr "" #: ../../menuinfo.c:367 msgid "Circular Bggen..." msgstr "" #: ../../menuinfo.c:368 msgid "Create a gray circular image using the size of a selected image" msgstr "" #: ../../menuinfo.c:370 msgid "Simple Rect Bggen..." msgstr "" #: ../../menuinfo.c:371 msgid "Create a single-color rectanglar image using the size of selected image" msgstr "" #: ../../menuinfo.c:379 msgid "Make Gray" msgstr "đĆÒĆŚĆÓÔÉ Ś ÓĆÒÙÊ" #: ../../menuinfo.c:379 msgid "Convert a selected image into gray-scale" msgstr "" #: ../../menuinfo.c:381 msgid "Brighten/Darken..." msgstr "óŚĆÔÌÙÊ/ôĆÍÎÙÊ..." #: ../../menuinfo.c:381 msgid "Brighten or darken a selected image" msgstr "" #: ../../menuinfo.c:383 msgid "Contrast Enhance..." msgstr "éÚÍĆÎÉÔŰ ËÏÎÔÒÁÓÔ..." #: ../../menuinfo.c:383 msgid "Adjust contrast of a selected image" msgstr "" #: ../../menuinfo.c:385 msgid "Gamma Correct..." msgstr "ëÏÒÒĆËĂÉŃ ÇÁÍÍÙ..." #: ../../menuinfo.c:386 msgid "Apply gamma correction a selected image" msgstr "" #: ../../menuinfo.c:388 msgid "Change Saturation..." msgstr "éÚÍĆÎÉÔŰ ÎÁÓÙĘĆÎÎÏÓÔŰ..." #: ../../menuinfo.c:389 msgid "Change saturation of a selected image" msgstr "" #: ../../menuinfo.c:391 msgid "Change Hue..." msgstr "éÚÍĆÎÉÔŰ ÏÔÔĆÎÏË..." #: ../../menuinfo.c:391 msgid "Change hue of a selected image" msgstr "" #: ../../menuinfo.c:394 msgid "Invert Color" msgstr "ïÂÒÁÔÉÔŰ ĂŚĆÔ" #: ../../menuinfo.c:395 msgid "Subtract every pixel of a selected image from White (in RGB-model)" msgstr "" #: ../../menuinfo.c:397 msgid "Interpolate Color..." msgstr "äÏÂÁŚÉÔŰ ĂŚĆÔ..." #: ../../menuinfo.c:398 msgid "Map pixel intensities of a selected image between two specified colors" msgstr "" #: ../../menuinfo.c:400 msgid "Color Balance..." msgstr "âÁÌÁÎÓ ĂŚĆÔÁ..." #: ../../menuinfo.c:401 msgid "Balance the RGB components of a selected image" msgstr "" #: ../../menuinfo.c:404 msgid "Reduce Number Of Colors" msgstr "éÚÍĆÎÉÔŰ ËÏÌÉȚĆÓÔŚÏ ĂŚĆÔÏŚ" #: ../../menuinfo.c:405 msgid "Reduce number of colors submenu >>>" msgstr "đÏÄÍĆÎÀ ÉÚÍĆÎĆÎÉŃ ËÏÌÉȚĆÓÔŚÁ ĂŚĆÔÏŚ >>>" #: ../../menuinfo.c:406 msgid "Effects" msgstr "üÆÆĆËÔÙ" #: ../../menuinfo.c:407 msgid "Effects submenu >>>" msgstr "đÏÄÍĆÎÀ ÜÆÆĆËÔÏŚ >>>" #: ../../menuinfo.c:408 msgid "Generate" msgstr "óÇĆÎĆÒÉÒÏŚÁÔŰ" #: ../../menuinfo.c:409 #, fuzzy msgid "Generate submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:411 msgid "Regenerate Image" msgstr "đÏÓÔÒÏÉÔŰ ĐÏ ËÒÁŃÍ" #: ../../menuinfo.c:412 #, fuzzy msgid "Regenerated a selected image" msgstr "đÏÓÔÒÏÉÔŰ ĐÏ ËÒÁŃÍ" #: ../../menuinfo.c:413 msgid "Crop Image" msgstr "ïÂÒĆÚÁÔŰ ĐÏ ÏÂÌÁÓÔÉ" #: ../../menuinfo.c:413 msgid "Crop a selected image" msgstr "" #: ../../menuinfo.c:415 msgid "Get Color" msgstr "śÚŃÔŰ ĂŚĆÔ" #: ../../menuinfo.c:416 msgid "Pick a color from a selected image to be the current color" msgstr "" #: ../../menuinfo.c:418 msgid "Replace Color" msgstr "úÁÍĆÎÉÔŰ ĂŚĆÔ" #: ../../menuinfo.c:419 msgid "Replace a color in a selected image with the current color" msgstr "" #: ../../menuinfo.c:421 msgid "Flood Fill" msgstr "úÁÌÉÔŰ" #: ../../menuinfo.c:422 msgid "Flood-filling a selected image with the current color" msgstr "" #: ../../menuinfo.c:424 msgid "Create Contour" msgstr "óÏÚÄÁÔŰ ËÏÎÔŐÒ" #: ../../menuinfo.c:425 msgid "Generate a contour from a point in a selected image" msgstr "" #: ../../menuinfo.c:428 #, fuzzy msgid "Subtract" msgstr "ïÂßĆÄÉÎÉÔŰ" #: ../../menuinfo.c:429 msgid "Subtract one image from another" msgstr "" #: ../../menuinfo.c:430 #, fuzzy msgid "Alpha Combine" msgstr "Alpha Combine" #: ../../menuinfo.c:431 msgid "Combine 2 images using another image as the alpha channel" msgstr "" #: ../../menuinfo.c:433 #, fuzzy msgid "Xor Color" msgstr "XorColor" #: ../../menuinfo.c:433 msgid "XOR the colors of one image into another" msgstr "" #: ../../menuinfo.c:436 msgid "Vector Warp" msgstr "éÓËÒÉŚÉÔŰ ĐÏ ŚĆËÔÏÒŐ" #: ../../menuinfo.c:437 msgid "Warp selected image in a specified direction for a specified amount" msgstr "" #: ../../menuinfo.c:445 msgid "Solve" msgstr "Solve" #: ../../menuinfo.c:445 ../../menuinfo.c:446 ../../menuinfo.c:447 #: ../../menuinfo.c:448 ../../menuinfo.c:449 msgid "Escape to driver" msgstr "" #: ../../menuinfo.c:446 msgid "Simulate" msgstr "Simulate" #: ../../menuinfo.c:447 msgid "Probe" msgstr "Probe" #: ../../menuinfo.c:448 msgid "Animate" msgstr "áÎÉÍÁĂÉŃ" #: ../../menuinfo.c:449 msgid "Escape" msgstr "Escape" #: ../../menuinfo.c:456 msgid "Create Thumbnails" msgstr "óÏÚÄÁÔŰ ÜÓËÉÚÙ..." #: ../../menuinfo.c:457 msgid "Create a thumbnail map of all object files" msgstr "" #: ../../menuinfo.c:460 msgid "Browse X Bitmap" msgstr "ïÂÚÏÒ ÆÁÊÌÏŚ X Bitmap" #: ../../menuinfo.c:461 msgid "Recursively read in all X11 bitmap files" msgstr "" #: ../../menuinfo.c:463 msgid "Browse X Pixmap" msgstr "ïÂÚÏÒ ÆÁÊÌÏŚ X Pixmap" #: ../../menuinfo.c:464 msgid "Recursively read in all X11 pixmap files" msgstr "" #: ../../menuinfo.c:466 msgid "Browse Other..." msgstr "ïÂÚÏÒ ÄÒŐÇÉÈ ÆÁÊÌÏŚ..." #: ../../menuinfo.c:467 msgid "Recursively read in all another type of files" msgstr "" #: ../../menuinfo.c:475 ../../menuinfo.c:535 msgid "Import Multipage Text File" msgstr "éÍĐÏÒÔ ÍÎÏÇÏÓÔÒÁÎÉȚÎÏÇÏ ÔĆËÓÔÏŚÏÇÏ ÆÁÊÌÁ" #: ../../menuinfo.c:475 msgid "Import a multipage text file" msgstr "éÍĐÏÒÔÉÒÏŚÁÔŰ ÍÎÏÇÏÓÔÒÁÎÉȚÎÙÊ ÔĆËÓÔÏŚÙÊ ÆÁÊÌ" #: ../../menuinfo.c:477 msgid "Set Margins" msgstr "őÓÔÁÎÏŚÉÔŰ ÏÔÓÔŐĐÙ" #: ../../menuinfo.c:478 msgid "Set margins for importing multipage text files" msgstr "" #: ../../menuinfo.c:480 msgid "Word Wrap" msgstr "đĆÒĆÎÏÓ ÓÌÏŚ" #: ../../menuinfo.c:481 msgid "Turn word wrapping on and off for importing multipage text files" msgstr "" #: ../../menuinfo.c:490 ../../menuinfo.c:541 msgid "Screen Capture" msgstr "óÎÉÍÏË ÜËÒÁÎÁ" #: ../../menuinfo.c:491 msgid "Capture a rectangular area of the screen" msgstr "úÁÈŚÁÔÉÔŰ ĐÒŃÍÏŐÇÏÌŰÎŐÀ ÏÂÌÁÓÔŰ ÜËÒÁÎÁ" #: ../../menuinfo.c:493 msgid "Full Screen Capture" msgstr "óÎÉÍÏË ĐÏÌÎÏÇÏ ÜËÒÁÎÁ" #: ../../menuinfo.c:493 msgid "Capture the whole screen" msgstr "úÁÈŚÁÔÉÔŰ ÜËÒÁÎ ĂĆÌÉËÏÍ" #: ../../menuinfo.c:495 msgid "Delayed Full Screen Capture..." msgstr "óÎÉÍÏË ĐÏÌÎÏÇÏ ÜËÒÁÎÁ Ó ÚÁÄĆÒÖËÏÊ..." #: ../../menuinfo.c:496 msgid "Capture the whole screen after a specified delay" msgstr "" #: ../../menuinfo.c:499 msgid "Hide During Capture" msgstr "đÒŃÔÁÔŰ ĐÒÉ ÓÎÉÍËĆ" #: ../../menuinfo.c:500 msgid "Toggle between hiding and showing tgif during capture" msgstr "" #: ../../menuinfo.c:508 msgid "Import..." msgstr "éÍĐÏÒÔ..." #: ../../menuinfo.c:508 msgid "Embed/Import another drawing" msgstr "" #: ../../menuinfo.c:510 msgid "Import X Bitmap..." msgstr "éÍĐÏÒÔ X Bitmap..." #: ../../menuinfo.c:511 msgid "Embed/Import an X11 bitmap file" msgstr "" #: ../../menuinfo.c:512 msgid "Import X Pixmap..." msgstr "éÍĐÏÒÔ X Pixmap..." #: ../../menuinfo.c:513 msgid "Embed/Import an X11 pixmap file" msgstr "" #: ../../menuinfo.c:514 msgid "Import EPS File..." msgstr "éÍĐÏÒÔ EPS.." #: ../../menuinfo.c:514 msgid "Link to a PS/EPS file" msgstr "" #: ../../menuinfo.c:516 msgid "Import GIF File..." msgstr "éÍĐÏÒÔ GIF..." #: ../../menuinfo.c:516 #, fuzzy msgid "Embed/Import a GIF file" msgstr "éÍĐÏÒÔ GIF..." #: ../../menuinfo.c:518 msgid "Import PNG File..." msgstr "éÍĐÏÒÔ PNG.." #: ../../menuinfo.c:518 msgid "Embed/Import a PNG file" msgstr "" #: ../../menuinfo.c:520 msgid "Import JPEG File..." msgstr "éÍĐÏÒÔ JPEG.." #: ../../menuinfo.c:520 msgid "Embed/Import a JPEG file" msgstr "" #: ../../menuinfo.c:522 msgid "Import Other File..." msgstr "éÍĐÏÒÔ ȚĆÇÏ-ÔÏ ÄÒŐÇÏÇÏ..." #: ../../menuinfo.c:522 msgid "Embed/Import another type of file" msgstr "" #: ../../menuinfo.c:525 msgid "Embed EPS File..." msgstr "śÓÔÁŚÉÔŰ EPS..." #: ../../menuinfo.c:525 #, fuzzy msgid "Embed/Import a PS/EPS file" msgstr "éÍĐÏÒÔ EPS.." #: ../../menuinfo.c:528 msgid "Auto EPS Preview Bitmap" msgstr "" #: ../../menuinfo.c:529 msgid "" "Auto-generate a preview bitmap for a PS/EPS file when embedding/importing it " "(if it does not have one already)." msgstr "" #: ../../menuinfo.c:532 ../../menuinfo.c:885 msgid "Paste From File..." msgstr "śÓÔÁŚÉÔŰ ÉÚ ÆÁÊÌÁ..." #: ../../menuinfo.c:533 ../../menuinfo.c:886 msgid "Select a file and paste the content as text" msgstr "" #: ../../menuinfo.c:536 msgid "Import Multipage Text File submenu >>>" msgstr "đÏÄÍĆÎÀ ÉÍĐÏÒÔÁ ÍÎÏÇÏÓÔÒÁÎÉȚÎÏÇÏ ÔĆËÓÔÏŚÏÇÏ ÆÁÊÌÁ >>>" #: ../../menuinfo.c:539 msgid "Browse" msgstr "ïÂÚÏÒ" #: ../../menuinfo.c:540 msgid "Browse submenu >>>" msgstr "đÏÄÍĆÎÀ ÏÂÚÏÒÁ" #: ../../menuinfo.c:542 #, fuzzy msgid "Screen Capture submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:549 msgid "Change Domain..." msgstr "óÍĆÎÉÔŰ ÄÏÍĆÎ..." #: ../../menuinfo.c:549 msgid "Change to a different domain" msgstr "óÍĆÎÉÔŰ ÔĆËŐĘÉÊ ÄÏÍĆÎ ÎÁ ËÁËÏÊ-ÔÏ ÄÒŐÇÏÊ" #: ../../menuinfo.c:552 msgid "Edit Domain Paths..." msgstr "òĆÄÁËÔÉÒÏŚÁÔŰ ĐŐÔÉ..." #: ../../menuinfo.c:552 #, fuzzy msgid "Edit domain paths" msgstr "òĆÄÁËÔÉÒÏŚÁÔŰ ĐŐÔÉ ÄÏÍĆÎÁ" #: ../../menuinfo.c:554 msgid "Select Default Domain..." msgstr "äÏÍĆÎ ĐÏ ŐÍÏÌȚÁÎÉÀ..." #: ../../menuinfo.c:554 msgid "Select the default domain" msgstr "śÙÂÒÁÔŰ ÄÏÍĆÎ ĐÏ ŐÍÏÌȚÁÎÉÀ" #: ../../menuinfo.c:556 msgid "Add A Domain..." msgstr "äÏÂÁŚÉÔŰ ÄÏÍĆÎ..." #: ../../menuinfo.c:556 msgid "Add a new domain" msgstr "äÏÂÁŚÉÔŰ ÎÏŚÙÊ ÄÏÍĆÎ" #: ../../menuinfo.c:558 msgid "Delete A Domain..." msgstr "őÄÁÌÉÔŰ ÄÏÍĆÎ..." #: ../../menuinfo.c:558 msgid "Delete an existing domain" msgstr "őÄÁÌÉÔŰ ÓŐĘĆÓÔŚŐÀĘÉÊ ÄÏÍĆÎ" #: ../../menuinfo.c:561 msgid "Reload Domain Info From X..." msgstr "đĆÒĆÚÁÇÒŐÚÉÔŰ ÉÎÆÏÒÍÁĂÉÀ Ï ÄÏÍĆÎĆ ÉÚ X..." #: ../../menuinfo.c:562 msgid "Reload domain information from X defaults" msgstr "đĆÒĆÚÁÇÒŐÚÉÔŰ ÉÎÆÏÒÍÁĂÉÀ Ï ÄÏÍĆÎĆ ÉÚ X-ÒĆÓŐÒÓÏŚ" #: ../../menuinfo.c:573 msgid "Export X Pixmap Deck To GIF" msgstr "Export X Pixmap Deck To GIF" #: ../../menuinfo.c:574 msgid "Export a deck of X11 pixmap images to an animated GIF file" msgstr "" #: ../../menuinfo.c:576 msgid "Import GIF To X Pixmap Deck..." msgstr "Import GIF To X Pixmap Deck..." #: ../../menuinfo.c:577 msgid "Import an animated GIF file into a deck of X11 pixmap images" msgstr "" #: ../../menuinfo.c:588 #, fuzzy msgid "Fake User Agent..." msgstr "Fake User Agent..." #: ../../menuinfo.c:589 msgid "Set 'UserAgent' to be used when making an HTTP request" msgstr "" #: ../../menuinfo.c:591 #, fuzzy msgid "Fake Referer..." msgstr "Fake Referer..." #: ../../menuinfo.c:592 msgid "Set 'Referer' to be used when making an HTTP request" msgstr "" #: ../../menuinfo.c:594 #, fuzzy msgid "Toggle Keep Alive" msgstr "Toggle Keep Alive" #: ../../menuinfo.c:595 msgid "Toggle between using Keep-Alive and non-Keep-Alive HTTP connections" msgstr "" #: ../../menuinfo.c:604 msgid "New" msgstr "îÏŚÙÊ" #: ../../menuinfo.c:604 msgid "Start with a blank/new drawing" msgstr "" #: ../../menuinfo.c:606 msgid "Open..." msgstr "ïÔËÒÙÔŰ..." #: ../../menuinfo.c:606 msgid "Open an existing drawing" msgstr "" #: ../../menuinfo.c:608 msgid "Import" msgstr "éÍĐÏÒÔ" #. CSTID_SAVE #: ../../menuinfo.c:611 ../../strtbl.c:107 msgid "Save" msgstr "óÏÈÒÁÎÉÔŰ" #: ../../menuinfo.c:611 msgid "Save current drawing" msgstr "óÏÈÒÁÎÉÔŰ ÔĆËŐĘÉÊ ÒÉÓŐÎÏË" #: ../../menuinfo.c:612 msgid "Save New..." msgstr "óÏÈÒÁÎÉÔŰ ËÁË..." #: ../../menuinfo.c:613 msgid "Save current drawing in a different file" msgstr "óÏÈÒÁÎÉÔŰ ÔĆËŐĘÉÊ ÒÉÓŐÎÏË Ś ÄÒŐÇÏÊ ÆÁÊÌ" #: ../../menuinfo.c:614 msgid "Save Selected As..." msgstr "óÏÈÒÁÎÉÔŰ ŚÙÄĆÌĆÎÎÏĆ ËÁË..." #: ../../menuinfo.c:615 msgid "Save selected objects in a different file" msgstr "óÏÈÒÁÎÉÔŰ ŚÙÄĆÌĆÎÎÙĆ ÏÂßĆËÔÙ Ś ÄÒŐÇÏÊ ÆÁÊÌ" #: ../../menuinfo.c:618 msgid "Print" msgstr "đĆȚÁÔŰ" #: ../../menuinfo.c:618 msgid "Print/export current drawing" msgstr "đĆȚÁÔŰ/ÜËÓĐÏÒÔ ÔĆËŐĘĆÇÏ ÒÉÓŐÎËÁ" #: ../../menuinfo.c:620 ../../menuinfo.c:1203 msgid "Print/Export Format" msgstr "æÏÒÍÁÔ ĐĆȚÁÔÉ/ÜËÓĐÏÒÔÁ" #: ../../menuinfo.c:621 ../../menuinfo.c:1204 msgid "Select print/export format submenu >>>" msgstr "đÏÄÍĆÎÀ ŚÙÂÏÒÁ ÆÏÒÍÁÔÁ ÄÌŃ ĐĆȚÁÔÉ/ÜËÓĐÏÒÔÁ >>>" #: ../../menuinfo.c:623 msgid "Set HTML Export Template..." msgstr "őÓÔÁÎÏŚÉÔŰ ÛÁÂÌÏÎ ÄÌŃ ÜËÓĐÏÒÔÁ Ś HTML..." #: ../../menuinfo.c:624 msgid "Specify a file to be used as a template for genearting HTML files" msgstr "őËÁÚÁÔŰ ÆÁÊÌ, ËÏÔÏÒÙÊ ÂŐÄĆÔ ÉÓĐÏÌŰÚÏŚÁÎ, ËÁË ÛÁÂÌÏÎ ĐÒÉ ÇĆÎĆÒÁĂÉÉ HTML ÆÁÊÌÏŚ" #: ../../menuinfo.c:626 ../../menuinfo.c:1206 msgid "Print/Export In Color" msgstr "đĆȚÁÔŰ/ÜËÓĐÏÒÔ Ś ĂŚĆÔĆ" #: ../../menuinfo.c:627 ../../menuinfo.c:1207 msgid "Toggle between color and black & white printing modes" msgstr "đĆÒĆËÌÀȚĆÎÉĆ ÍĆÖÄŐ ĂŚĆÔÎÙÍ É ȚĆÒÎÏ-ÂĆÌÙÍ ÒĆÖÉÍÁÍÉ ĐĆȚÁÔÉ" #: ../../menuinfo.c:629 msgid "Print With Cmd..." msgstr "đĆȚÁÔŰ Ó ËÏÍÁÎÄÏÊ..." #: ../../menuinfo.c:630 msgid "Print/export current drawing with a specific command" msgstr "" #: ../../menuinfo.c:632 msgid "Print Selected Objects" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:633 #, fuzzy msgid "Print/export only selected objects" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:634 msgid "Print a page in a multipage drawing" msgstr "" #: ../../menuinfo.c:642 msgid "GIF Animation" msgstr "áÎÉÍÁĂÉŃ GIF" #: ../../menuinfo.c:643 #, fuzzy msgid "GIFAnimation submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:645 msgid "Mime" msgstr "MIME" #: ../../menuinfo.c:645 #, fuzzy msgid "Mime submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:649 msgid "Print Msg Buffer..." msgstr "đĆȚÁÔŰ ÓÏÏÂĘĆÎÉÊ ÂŐÆĆÒÁ" #: ../../menuinfo.c:650 msgid "Display/save the contents of the message window" msgstr "" #: ../../menuinfo.c:653 msgid "Set Export Pixel Trim..." msgstr "Set Export Pixel Trim..." #: ../../menuinfo.c:654 msgid "Specify the number of pixels to trim when exporting" msgstr "" #: ../../menuinfo.c:656 msgid "Set Template..." msgstr "śÙÂÒÁÔŰ ÛÁÂÌÏÎ..." #: ../../menuinfo.c:657 msgid "Select a template file be used in STACKED page mode" msgstr "" #: ../../menuinfo.c:660 msgid "Recent Files" msgstr "đÏÓÌĆÄÎÉĆ ÆÁÊÌÙ" #: ../../menuinfo.c:661 #, fuzzy msgid "Recently used files submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:663 msgid "Quit" msgstr "śÙÈÏÄ" #: ../../menuinfo.c:663 msgid "Exit <<PROGRAM_NAME>>" msgstr "śÙÊÔÉ ÉÚ <<PROGRAM_NAME>>" #: ../../menuinfo.c:669 msgid "Precise Scale..." msgstr "ôÏȚÎÏĆ ÍÁÓÛÔÁÂÉÒÏŚÁÎÉĆ..." #: ../../menuinfo.c:669 #, fuzzy msgid "Scale selected objects" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:671 #, fuzzy msgid "Scale everything" msgstr "íÁÓÛÔÁÂÉÒÏŚÁÔŰ ŚÓĆ..." #: ../../menuinfo.c:673 msgid "Precise Rotate..." msgstr "ôÏȚÎÏĆ ŚÒÁĘĆÎÉĆ..." #: ../../menuinfo.c:674 msgid "Rotate selected objects by a specified number of degrees" msgstr "" #: ../../menuinfo.c:677 msgid "Restore Image Width & Height" msgstr "śÏÓÓÔÁÎÏŚÉÔŰ ÒÁÚÍĆÒ ÒÉÓŐÎËÁ" #: ../../menuinfo.c:678 msgid "Restore a seleted bitmap/pixmap/EPS object to its original dimension" msgstr "" # ĐÒĆÄŐĐÒĆÖÄĆÎÉĆ ĐĆÒĆŚÏÄȚÉËÁÍ: ĐÏ ËÒÁÊÎĆÊ ÍĆÒĆ ÄÌŃ 4.1.42 ÜÔÏÔ ĐĆÒĆŚÏÄ # _ÄĆÊÓÔŚÉÔĆÌŰÎÏ_ ĐĆÒĆÄÁĆÔ ĐÏŚĆÄĆÎÉĆ tgif. #: ../../menuinfo.c:680 msgid "No Transform" msgstr "ïÔÍĆÎÉÔŰ ÔÒÁÎÓÆÏÒÍÁĂÉÉ" #: ../../menuinfo.c:681 msgid "Get rid of transformations on selected simple objects" msgstr "" #: ../../menuinfo.c:689 msgid "Invert X Bitmap" msgstr "îĆÇÁÔÉŚ X Bitmap" #: ../../menuinfo.c:690 msgid "Invert pixels for selected bitmap objects" msgstr "" #: ../../menuinfo.c:692 msgid "Cut Bit/Pixmap..." msgstr "ïÂÒĆÚÁÔŰ ÏÂÌÁÓÔŰ/Pixmap..." #: ../../menuinfo.c:693 msgid "Trim/scale a selected bitmap/pixmap object" msgstr "" #: ../../menuinfo.c:695 msgid "Break Up Bit/Pixmap..." msgstr "òÁÚÂÉÔŰ/Pixmap..." #: ../../menuinfo.c:696 msgid "Break selected bitmap/pixmap object into smaller objects" msgstr "" #: ../../menuinfo.c:699 msgid "Export Half Tone Bitmap" msgstr "" #: ../../menuinfo.c:700 msgid "Use Floyd-Steinberg half-tone method when exporting an X11 bitmap file" msgstr "" #: ../../menuinfo.c:702 msgid "Export Threshold Bitmap" msgstr "" #: ../../menuinfo.c:703 msgid "Use simple thresholding method when exporting an X11 bitmap file" msgstr "" #: ../../menuinfo.c:706 #, fuzzy msgid "Set Export Bitmap Threshold..." msgstr "Set Export Pixel Trim..." #: ../../menuinfo.c:707 msgid "Set bitmap threshold value for the simple thresholding method" msgstr "" #: ../../menuinfo.c:710 msgid "Update EPS" msgstr "ïÂÎÏŚÉÔŰ EPS" #: ../../menuinfo.c:710 msgid "Refresh a selected EPS object" msgstr "" #: ../../menuinfo.c:718 #, fuzzy msgid "Set Tick Mark Size..." msgstr "śÙÂÒÁÔŰ ÆÏÒÍÁÔ ÂŐÍÁÇÉ..." #: ../../menuinfo.c:719 msgid "Set the size of tick marks for various commands" msgstr "" #: ../../menuinfo.c:722 msgid "Add Squares" msgstr "" #: ../../menuinfo.c:723 msgid "Add square tick marks at vertices of selected polys/polygons/splines" msgstr "" #: ../../menuinfo.c:725 msgid "Add Triangles" msgstr "" #: ../../menuinfo.c:726 msgid "Add triangle tick marks at vertices of selected polys/polygons/splines" msgstr "" #: ../../menuinfo.c:728 msgid "Add Circles" msgstr "" #: ../../menuinfo.c:729 msgid "Add circle tick marks at vertices of selected polys/polygons/splines" msgstr "" #: ../../menuinfo.c:731 msgid "Add Xs" msgstr "" #: ../../menuinfo.c:732 msgid "Add X tick marks at vertices of selected polys/polygons/splines" msgstr "" #: ../../menuinfo.c:734 msgid "Add Diamonds" msgstr "" #: ../../menuinfo.c:735 msgid "Add diamond tick marks at vertices of selected polys/polygons/splines" msgstr "" #: ../../menuinfo.c:737 msgid "Add Bowties" msgstr "" #: ../../menuinfo.c:738 msgid "Add bowtie tick marks at vertices of selected polys/polygons/splines" msgstr "" #: ../../menuinfo.c:740 msgid "Add Inverted Triangles" msgstr "" #: ../../menuinfo.c:741 msgid "" "Add inverted triangle tick marks at vertices of selected polys/polygons/" "splines" msgstr "" #: ../../menuinfo.c:743 msgid "Add Plus" msgstr "" #: ../../menuinfo.c:744 msgid "Add plus tick marks at vertices of selected polys/polygons/splines" msgstr "" #: ../../menuinfo.c:746 msgid "Add Hour Glasss" msgstr "" #: ../../menuinfo.c:747 msgid "" "Add hour glass tick marks at vertices of selected polys/polygons/splines" msgstr "" #: ../../menuinfo.c:756 msgid "Delete Point" msgstr "őÄÁÌÉÔŰ ÔÏȚËŐ" #: ../../menuinfo.c:757 msgid "Delete vertices from a poly/polygon/spline" msgstr "" #: ../../menuinfo.c:759 msgid "Add Point" msgstr "śÓÔÁŚÉÔŰ ÔÏȚËŐ" #: ../../menuinfo.c:760 msgid "Add vertices to a polygon/polygon/spline" msgstr "" #: ../../menuinfo.c:762 msgid "Convert Interpolated Spline" msgstr "đÒĆÏÂÒÁÚÏŚÁÔŰ Ś ÓĐÌÁÊÎ" #: ../../menuinfo.c:763 #, fuzzy msgid "Convert selected interpolated splines to regular splines" msgstr "đÒĆÏÂÒÁÚÏŚÁÔŰ Ś ÓĐÌÁÊÎ" #: ../../menuinfo.c:765 msgid "Smooth<->Hinge" msgstr "őÇÏÌ<->ëÒÉŚÁŃ" #: ../../menuinfo.c:766 msgid "Toggle smooth/hinge vertices for a selected poly/polygon/spline" msgstr "" #: ../../menuinfo.c:769 msgid "Convert To Bezier Curve" msgstr "" #: ../../menuinfo.c:770 msgid "Convert selected splines to Bezier curves" msgstr "" #: ../../menuinfo.c:772 #, fuzzy msgid "Set Segments For Convert To Bezier..." msgstr "òÁÚÍĆÒ ŚÙÂÒÁÎÎÏÇÏ ÔĆËÓÔÁ..." #: ../../menuinfo.c:773 msgid "Set the number of segments for the convert to Bezier command" msgstr "" #: ../../menuinfo.c:776 msgid "Join Poly" msgstr "óÏĆÄÉÎÉÔŰ ÌÉÎÉÉ" #: ../../menuinfo.c:776 msgid "Join polylines or open-splines at endpoints" msgstr "óÏĆÄÉÎÉÔŰ ÌÉÎÉÉ ÉÌÉ ÏÔËÒÙÔÙĆ ÓĐÌÁÊÎÙ Ś ËÏÎĆȚÎÙÈ ÔÏȚËÁÈ" #: ../../menuinfo.c:778 msgid "Cut Poly" msgstr "òÁÚÒĆÚÁÔŰ ÌÉÎÉÀ" #: ../../menuinfo.c:778 msgid "Cut a poly/polygon at a vertex into two pieces" msgstr "òÁÚÒĆÚÁÔŰ ÌÉÎÉÀ/ÍÎÏÇÏŐÇÏÌŰÎÉË ÎÁ ÄŚĆ ȚÁÓÔÉ ĐÏ ŚÙÄĆÌĆÎÎÏÊ ŚĆÒÛÉÎĆ" #: ../../menuinfo.c:781 msgid "Make Regular Polygon..." msgstr "" #: ../../menuinfo.c:782 msgid "Make a selected polygon/closed spline into a regular one" msgstr "" #: ../../menuinfo.c:785 ../../menuinfo.c:846 msgid "Add Tick Marks" msgstr "" #: ../../menuinfo.c:786 ../../menuinfo.c:847 msgid "Add Tick Marks submenu >>>" msgstr "" #: ../../menuinfo.c:793 msgid "Break Up Text" msgstr "òÁÚÂÉÔŰ ÔĆËÓÔ ÎÁ ÓÉÍŚÏÌÙ" #: ../../menuinfo.c:794 msgid "Break up selected text objects into one-character text objects" msgstr "" #: ../../menuinfo.c:796 #, fuzzy msgid "Set Text Fill Pattern Color" msgstr "őÓÔÁÎÏŚÉÔŰ ÔĆËŐĘÉÊ ĂŚĆÔ ÚÁĐÏÌÎĆÎÉŃ" #: ../../menuinfo.c:797 msgid "Set the fill pattern color of a text object to be the current color" msgstr "" #: ../../menuinfo.c:800 msgid "Insert Right Superscript" msgstr "śÓÔÁŚÉÔŰ ÎÁÄ ÓÔÒÏËŐ ÓĐÒÁŚÁ" #: ../../menuinfo.c:801 msgid "Insert superscript to the right of the text cursor" msgstr "" #: ../../menuinfo.c:803 msgid "Insert Right Subscript" msgstr "śÓÔÁŚÉÔŰ ĐÏÄÓÔÒÏËŐ ÓĐÒÁŚÁ" #: ../../menuinfo.c:804 msgid "Insert subscript to the right of the text cursor" msgstr "" #: ../../menuinfo.c:806 msgid "Insert Left Superscript" msgstr "śÓÔÁŚÉÔŰ ÎÁÄ ÓÔÒÏËŐ ÓÌĆŚÁ" #: ../../menuinfo.c:807 msgid "Insert superscript to the left of the text cursor" msgstr "" #: ../../menuinfo.c:809 msgid "Insert Left Subscript" msgstr "śÓÔÁŚÉÔŰ ĐÏÄÓÔÒÏËŐ ÓÌĆŚÁ" #: ../../menuinfo.c:810 msgid "Insert subscript to the left of the text cursor" msgstr "" #: ../../menuinfo.c:812 msgid "Insert Center Superscript" msgstr "śÓÔÁŚÉÔŰ ÎÁÄ ÓÔÒÏËŐ ĐÏ ĂĆÎÔÒŐ" #: ../../menuinfo.c:813 msgid "Insert superscript above the text cursor" msgstr "" #: ../../menuinfo.c:815 msgid "Insert Center Subscript" msgstr "śÓÔÁŚÉÔŰ ĐÏÄÓÔÒÏËŐ ĐÏ ĂĆÎÔÒŐ" #: ../../menuinfo.c:816 msgid "Insert subscript below the text cursor" msgstr "" #: ../../menuinfo.c:819 msgid "Insert Thin Space..." msgstr "śÓÔÁŚÉÔŰ ÛÉÒÏËÉÊ ĐÒÏÂĆÌ" #: ../../menuinfo.c:820 msgid "Insert a think space at the text cursor" msgstr "" #: ../../menuinfo.c:823 msgid "Insert Vertical Offset..." msgstr "śÓÔÁŚÉÔŰ ŚĆÒÔÉËÁÌŰÎÏĆ ÓÍĆĘĆÎÉĆ" #: ../../menuinfo.c:824 msgid "Insert a vertical offset at the text cursor" msgstr "" #: ../../menuinfo.c:826 msgid "Remove Vertical Offset..." msgstr "őÄÁÌÉÔŰ ŚĆÒÔÉËÁÌŰÎÏĆ ÓÍĆĘĆÎÉĆ" #: ../../menuinfo.c:827 msgid "Remove any vertical offset at the text cursor" msgstr "" #: ../../menuinfo.c:830 #, fuzzy msgid "Set Script Fraction..." msgstr "òÁÚÍĆÒ ÎÁÄÓÔÒÏË/ĐÏÄÓÔÒÏË" #: ../../menuinfo.c:831 msgid "Set the relative size of super/subscript text" msgstr "" #: ../../menuinfo.c:839 msgid "Input Poly Pts" msgstr "śŚĆÓÔÉ ÔÏȚËÉ ÌÉÎÉÉ" #: ../../menuinfo.c:840 msgid "Read points from terminal and create a poly" msgstr "" #: ../../menuinfo.c:842 msgid "Input Polygon Pts" msgstr "śŚĆÓÔÉ ÔÏȚËÉ ÍÎÏÇÏŐÇÏÌŰÎÉËÁ" #: ../../menuinfo.c:843 msgid "Read points from terminal and create a polygon" msgstr "" #: ../../menuinfo.c:849 msgid "Specify An Arc..." msgstr "úÁÄÁÔŰ ÄŐÇŐ..." #: ../../menuinfo.c:849 msgid "Create and specify an arc" msgstr "" #: ../../menuinfo.c:851 msgid "Get Bounding Box" msgstr "Get Bounding Box" #: ../../menuinfo.c:852 msgid "Get rectangular bounding boxes of selected objects" msgstr "" #: ../../menuinfo.c:861 msgid "Redraw" msgstr "ïÂÎÏŚÉÔŰ" #: ../../menuinfo.c:861 msgid "Redraw canvas window" msgstr "" #: ../../menuinfo.c:862 ../../menuinfo.c:1540 ../../menuinfo.c:1575 msgid "Duplicate" msgstr "äŐÂÌÉÒÏŚÁÔŰ" #: ../../menuinfo.c:862 ../../menuinfo.c:1540 ../../menuinfo.c:1575 #, fuzzy msgid "Duplicate selected objects" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #. CSTID_DELETE #: ../../menuinfo.c:864 ../../menuinfo.c:1542 ../../menuinfo.c:1577 #: ../../strtbl.c:225 msgid "Delete" msgstr "őÄÁÌÉÔŰ" #: ../../menuinfo.c:864 ../../menuinfo.c:1542 ../../menuinfo.c:1577 #, fuzzy msgid "Delete selected objects" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:866 msgid "Select All" msgstr "śÙÄĆÌÉÔŰ ŚÓĆ" #: ../../menuinfo.c:866 msgid "Select all objects on the current page" msgstr "" #: ../../menuinfo.c:869 msgid "Undo" msgstr "ïÔËÁÔ" #: ../../menuinfo.c:869 msgid "Undo the most recent command" msgstr "" #: ../../menuinfo.c:871 msgid "Redo" msgstr "śÏÚŚÒÁÔ" #: ../../menuinfo.c:871 msgid "Redo the most undone command" msgstr "śĆÒÎŐÔŰ ĐÏÓÌĆÄÎÀÀ ÏÔËÁȚĆÎÎŐÀ ËÏÍÁÎÄŐ" #: ../../menuinfo.c:873 msgid "Flush Undo Buffer" msgstr "ïȚÉÓÔÉÔŰ ÂŐÆĆÒ ÏÔËÁÔÁ" #: ../../menuinfo.c:873 msgid "Flush undo buffer and unused colors" msgstr "" #. CSTID_COPY #: ../../menuinfo.c:876 ../../menuinfo.c:1538 ../../menuinfo.c:1566 #: ../../strtbl.c:105 msgid "Copy" msgstr "ëÏĐÉÒÏŚÁÔŰ" #: ../../menuinfo.c:876 ../../menuinfo.c:1538 ../../menuinfo.c:1566 msgid "Copy selected objects into the cut buffer" msgstr "" #: ../../menuinfo.c:878 ../../menuinfo.c:1568 msgid "Copy Plain Text As Object" msgstr "ëÏĐÉÒÏŚÁÔŰ ÔĆËÓÔ ËÁË ÏÂßĆËÔ" #: ../../menuinfo.c:879 ../../menuinfo.c:1569 msgid "Copy highlighted plain text as an object into the cut buffer" msgstr "" #: ../../menuinfo.c:881 ../../menuinfo.c:1571 msgid "Cut" msgstr "śÙÒĆÚÁÔŰ" #: ../../menuinfo.c:881 msgid "Cut selected objects into the cut buffer" msgstr "" #. CSTID_PASTE #: ../../menuinfo.c:883 ../../menuinfo.c:1573 ../../strtbl.c:109 msgid "Paste" msgstr "śÓÔÁŚÉÔŰ" #: ../../menuinfo.c:883 ../../menuinfo.c:1573 msgid "Paste from the cut buffer" msgstr "" #: ../../menuinfo.c:889 ../../menuinfo.c:1668 ../../menuinfo.c:1756 msgid "Shape" msgstr "æÉÇŐÒÁ" #: ../../menuinfo.c:890 #, fuzzy msgid "Shape submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:891 msgid "Set Shape Shadow..." msgstr "őÓÔÁÎÏŚÉÔŰ ÔĆÎŰ ÄÌŃ ÆÉÇŐÒÙ" #: ../../menuinfo.c:891 msgid "Specify the shadow for shapes" msgstr "" #: ../../menuinfo.c:894 ../../menuinfo.c:1547 ../../menuinfo.c:1676 #: ../../menuinfo.c:1776 msgid "Image Proc" msgstr "ïÂÒÁÂÏÔÁÔŰ ÒÁÓÔÒÏŚÙÊ ÒÉÓŐÎÏË" #: ../../menuinfo.c:895 #, fuzzy msgid "ImageProc submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:896 ../../menuinfo.c:1545 ../../menuinfo.c:1583 #: ../../menuinfo.c:1630 ../../menuinfo.c:1710 ../../menuinfo.c:1738 msgid "Properties" msgstr "óŚÏÊÓÔŚÁ" #: ../../menuinfo.c:897 msgid "Properties submenu >>>" msgstr "đÏÄÍĆÎÀ ÓŚÏÊÓÔŚ >>>" #: ../../menuinfo.c:899 msgid "Transformation" msgstr "đÒĆÏÂÒÁÚÏŚÁÎÉĆ" #: ../../menuinfo.c:900 msgid "Transformation submenu >>>" msgstr "đÏÄÍĆÎÀ ĐÒĆÏÂÒÁÚÏŚÁÎÉÊ >>>" #: ../../menuinfo.c:902 msgid "Bitmap/Pixmap/EPS" msgstr "Bitmap/Pixmap/EPS" #: ../../menuinfo.c:903 #, fuzzy msgid "Bitmap/Pixmap/EPS submenu >>>" msgstr "Bitmap/Pixmap/EPS" #: ../../menuinfo.c:904 msgid "Poly/Polygon" msgstr "ìÉÎÉŃ/ÍÎÏÇÏŐÇÏÌŰÎÉË" #: ../../menuinfo.c:905 #, fuzzy msgid "Poly/Polygon submenu >>>" msgstr "đÏÄÍĆÎÀ ÌÉÎÉÊ/ÍÎÏÇÏŐÇÏÌŰÎÉËÏŚ >>>" #: ../../menuinfo.c:906 msgid "Text" msgstr "ôĆËÓÔ" #: ../../menuinfo.c:906 msgid "Text submenu >>>" msgstr "đÏÄÍĆÎÀ ÔĆËÓÔÁ >>>" #: ../../menuinfo.c:908 msgid "Create Object" msgstr "óÏÚÄÁÔŰ ÏÂßĆËÔ" #: ../../menuinfo.c:909 #, fuzzy msgid "Create object submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:911 #, fuzzy msgid "Push Current Choice" msgstr "đÒĆÄÙÄŐĘÉÊ ÒĆÖÉÍ ŚŚÏÄÁ" #: ../../menuinfo.c:912 msgid "Save/restore current drawing mode" msgstr "" #: ../../menuinfo.c:914 msgid "Find Case Sensitive..." msgstr "đÏÉÓË (Ó ŐȚĆÔÏÍ ÒĆÇÉÓÔÒÁ)" #: ../../menuinfo.c:915 msgid "Find string in visible text objects (case sensitive)" msgstr "" #: ../../menuinfo.c:917 msgid "Find No Case..." msgstr "đÏÉÓË" #: ../../menuinfo.c:918 msgid "Find string in visible text objects (case insensitive)" msgstr "" #: ../../menuinfo.c:920 msgid "Find Again" msgstr "éÓËÁÔŰ ÓÎÏŚÁ" #: ../../menuinfo.c:920 msgid "Repeat the last Find command" msgstr "" #: ../../menuinfo.c:931 msgid "Align Objects Top" msgstr "śÙÒÏŚÎŃÔŰ ĐÏ ŚĆÒÈŐ" #: ../../menuinfo.c:932 #, fuzzy msgid "Align top sides of selected objects" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:933 msgid "Align Objects Middle" msgstr "śÙÒÏŚÎŃÔŰ ĐÏ ÓĆÒĆÄÉÎĆ" #: ../../menuinfo.c:934 ../../strtbl.c:3441 msgid "Align vertical centers of selected objects" msgstr "" #: ../../menuinfo.c:936 msgid "Align Objects Bottom" msgstr "śÙÒÏŚÎŃÔŰ ĐÏ ÎÉÚŐ" #: ../../menuinfo.c:937 msgid "Align bottom sides of selected objects" msgstr "" #: ../../menuinfo.c:939 msgid "Align Objects Left" msgstr "śÙÒÏŚÎŃÔŰ ÓÌĆŚÁ" #: ../../menuinfo.c:940 #, fuzzy msgid "Align left sides of selected objects" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:941 msgid "Align Objects Center" msgstr "śÙÒÏŚÎŃÔŰ ĐÏ ĂĆÎÔÒŐ" #: ../../menuinfo.c:942 ../../strtbl.c:3447 msgid "Align horizontal centers of selected objects" msgstr "" #: ../../menuinfo.c:944 msgid "Align Objects Right" msgstr "śÙÒÏŚÎŃÔŰ ÓĐÒÁŚÁ" #: ../../menuinfo.c:945 #, fuzzy msgid "Align right sides of selected objects" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:947 msgid "Center An End Point" msgstr "Center An End Point" #: ../../menuinfo.c:948 msgid "Move an endpoint of a selected poly to the center of another object" msgstr "" #: ../../menuinfo.c:956 msgid "Size To Widest" msgstr "đÏ ÓÁÍÏÍŐ ÛÉÒÏËÏÍŐ" #: ../../menuinfo.c:957 msgid "Resize all selected objects to be as wide as the widest one" msgstr "" #: ../../menuinfo.c:959 msgid "Size To Narrowest" msgstr "đÏ ÓÁÍÏÍŐ ŐÚËÏÍŐ" #: ../../menuinfo.c:960 msgid "Resize all selected objects to be as narrow as the narrowest one" msgstr "" #: ../../menuinfo.c:962 msgid "Size To Tallest" msgstr "đÏ ÓÁÍÏÍŐ ŚÙÓÏËÏÍŐ" #: ../../menuinfo.c:963 msgid "Resize all selected objects to be as tall as the tallest one" msgstr "" #: ../../menuinfo.c:965 msgid "Size To Shortest" msgstr "đÏ ÓÁÍÏÍŐ ÎÉÚËÏÍŐ" #: ../../menuinfo.c:966 msgid "Resize all selected objects to be as short as the shortest one" msgstr "" #: ../../menuinfo.c:969 msgid "Size To Given Width & Height..." msgstr "đÏ ÛÉÒÉÎĆ/ŚÙÓÏÔĆ..." #: ../../menuinfo.c:970 msgid "Resize all selected objects to a specified width and height" msgstr "" #: ../../menuinfo.c:972 msgid "Size To Given Width..." msgstr "đÏ ÛÉÒÉÎĆ..." #: ../../menuinfo.c:973 msgid "Resize all selected objects to a specified width" msgstr "" #: ../../menuinfo.c:975 msgid "Size To Given Height..." msgstr "đÏ ŚÙÓÏÔĆ..." #: ../../menuinfo.c:976 msgid "Resize all selected objects to a specified height" msgstr "" #: ../../menuinfo.c:994 msgid "Flip Horizontal" msgstr "đĆÒĆŚĆÒÎŐÔŰ ĐÏ ÇÏÒÉÚÏÎÔÁÌÉ" #: ../../menuinfo.c:995 msgid "Flip selected objects horizontally" msgstr "" #: ../../menuinfo.c:996 msgid "Flip Vertical" msgstr "đĆÒĆŚĆÒÎŐÔŰ ĐÏ ŚĆÒÔÉËÁÌÉ" #: ../../menuinfo.c:996 msgid "Flip selected objects vertically" msgstr "" #: ../../menuinfo.c:999 msgid "Rotate Clock-Wise" msgstr "śÒÁĘÁÔŰ ĐÏ ȚÁÓÏŚÏÊ" #: ../../menuinfo.c:999 msgid "Rotate selected objects clockwise" msgstr "" #: ../../menuinfo.c:1001 msgid "Rotate Counter" msgstr "śÒÁĘÁÔŰ ĐÒÏÔÉŚ ȚÁÓÏŚÏÊ" #: ../../menuinfo.c:1002 msgid "Rotate selected objects counter-clockwise" msgstr "" #: ../../menuinfo.c:1005 msgid "Set Text Rotation..." msgstr "őÓÔÁÎÏŚÉÔŰ ĐÏŚÏÒÏÔ ÔĆËÓÔÁ..." #: ../../menuinfo.c:1005 #, fuzzy msgid "Set text rotation in degrees" msgstr "őÓÔÁÎÏŚÉÔŰ ĐÏŚÏÒÏÔ ÔĆËÓÔÁ..." #: ../../menuinfo.c:1007 msgid "Set Rotation Increment..." msgstr "őÓÔÁÎÏŚÉÔŰ ÛÁÇ ĐÏŚÏÒÏÔÁ..." #: ../../menuinfo.c:1008 #, fuzzy msgid "Set rotation increment in degrees" msgstr "őÓÔÁÎÏŚÉÔŰ ÛÁÇ ĐÏŚÏÒÏÔÁ..." #: ../../menuinfo.c:1016 msgid "Front" msgstr "îÁŚĆÒÈ" #: ../../menuinfo.c:1016 #, fuzzy msgid "Bring selected objects to the front" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:1018 msgid "Back" msgstr "śÎÉÚ" #: ../../menuinfo.c:1018 msgid "Send selected objects to the back" msgstr "" #: ../../menuinfo.c:1021 msgid "Group" msgstr "óÇÒŐĐĐÉÒÏŚÁÔŰ" #: ../../menuinfo.c:1022 msgid "Group selected objects into a compound object" msgstr "óÇÒŐĐĐÉÒÏŚÁÔŰ ŚÙÄĆÌĆÎÎÙĆ ÏÂßĆËÔÙ Ś ÓÏÓÔÁŚÎÏÊ ÏÂßĆËÔ" #: ../../menuinfo.c:1023 msgid "UnGroup" msgstr "òÁÚÇÒŐĐĐÉÒÏŚÁÔŰ" #: ../../menuinfo.c:1024 msgid "Break up selected grouped objects into its components" msgstr "òÁÚÂÉÔŰ ŚÙÄĆÌĆÎÎÙÊ ÇÒŐĐĐÏŚÏÊ ÏÂßĆËÔ ÎÁ ÓÏÓÔÁŚÌŃÀĘÉĆ ĆÇÏ ËÏÍĐÏÎĆÎÔÙ" #: ../../menuinfo.c:1027 msgid "Lock" msgstr "úÁËÒĆĐÉÔŰ" #: ../../menuinfo.c:1027 msgid "Lock the positions of selected objects" msgstr "" #: ../../menuinfo.c:1029 msgid "UnLock" msgstr "ïÔËÒĆĐÉÔŰ" #: ../../menuinfo.c:1029 msgid "UnLock the positions of selected objects" msgstr "" #: ../../menuinfo.c:1032 ../../menuinfo.c:1640 ../../menuinfo.c:1746 msgid "Horizontal Align" msgstr "òÏŚÎŃÔŰ ĐÏ ÇÏÒÉÚÏÎÔÁÌÉ" #: ../../menuinfo.c:1033 #, fuzzy msgid "HoriAlign submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1034 ../../menuinfo.c:1642 ../../menuinfo.c:1748 msgid "Vertical Align" msgstr "òÏŚÎŃÔŰ ĐÏ ŚĆÒÔÉËÁÌÉ" #: ../../menuinfo.c:1035 #, fuzzy msgid "VertAlign submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1037 msgid "Align Objects" msgstr "śÙÒÏŚÎŃÔŰ ÏÂßĆËÔÙ" #: ../../menuinfo.c:1038 msgid "Align selected objects with each other using the current alignments" msgstr "" #: ../../menuinfo.c:1040 msgid "Align Objects Direct" msgstr "îÁĐÒÁŚÌĆÎÉĆ ŚÙÒÁŚÎÉŚÁÎÉŃ" #: ../../menuinfo.c:1041 #, fuzzy msgid "Align objects direct submenu >>>" msgstr "îÁĐÒÁŚÌĆÎÉĆ ŚÙÒÁŚÎÉŚÁÎÉŃ" #: ../../menuinfo.c:1043 msgid "Align To Grid" msgstr "śÙÒÏŚÎŃÔŰ ĐÏ ÓĆÔËĆ" #: ../../menuinfo.c:1044 msgid "Align selected objects to grid points using the current alignments" msgstr "" #: ../../menuinfo.c:1046 msgid "Align To Grid Direct" msgstr "îÁĐÒÁŚÌĆÎÉĆ ŚÙÒÁŚÎÉŚÁÎÉŃ ĐÏ ÓĆÔËĆ" #: ../../menuinfo.c:1047 #, fuzzy msgid "Align to grid direct submenu >>>" msgstr "îÁĐÒÁŚÌĆÎÉĆ ŚÙÒÁŚÎÉŚÁÎÉŃ ĐÏ ÓĆÔËĆ" #: ../../menuinfo.c:1049 msgid "Align To Page" msgstr "śÙÒÏŚÎŃÔŰ ĐÏ ÓÔÒÁÎÉĂĆ" #: ../../menuinfo.c:1050 msgid "Align selected objects to the page using the current alignments" msgstr "" #: ../../menuinfo.c:1052 msgid "Align To Page Direct" msgstr "îÁĐÒÁŚÌĆÎÉĆ ŚÙÒÁŚÎÉŚÁÎÉŃ ĐÏ ÓÔÒÁÎÉĂĆ" #: ../../menuinfo.c:1053 #, fuzzy msgid "Align to page direct submenu >>>" msgstr "îÁĐÒÁŚÌĆÎÉĆ ŚÙÒÁŚÎÉŚÁÎÉŃ ĐÏ ÓÔÒÁÎÉĂĆ" #: ../../menuinfo.c:1055 msgid "More Object Alignments" msgstr "śÙÒÏŚÎŃÔŰ ÓĐĆĂÉÁÌŰÎÏ" #: ../../menuinfo.c:1056 #, fuzzy msgid "Align objects submenu >>>" msgstr "śÙÒÏŚÎŃÔŰ ĐÏ ĂĆÎÔÒŐ" #: ../../menuinfo.c:1058 msgid "Size Objects" msgstr "òÁÚÍĆÒ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:1059 #, fuzzy msgid "Size objects submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1061 msgid "Distribute Objects" msgstr "ïÒÇÁÎÉÚÏŚÁÔŰ ÏÂßĆËÔÙ" #: ../../menuinfo.c:1062 msgid "Distribute selected objects using the current alignments" msgstr "" #: ../../menuinfo.c:1064 msgid "Distribute Objects Direct" msgstr "óĐÏÓÏ ÏÒÇÁÎÉÚÁĂÉÉ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:1065 #, fuzzy msgid "Distribute objects direct submenu >>>" msgstr "óĐÏÓÏ ÏÒÇÁÎÉÚÁĂÉÉ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:1067 msgid "Layout On Arc" msgstr "śÙÒÏŚÎŃÔŰ ĐÏ ÄŐÇĆ" #: ../../menuinfo.c:1067 msgid "Layout objects on an arc" msgstr "" #: ../../menuinfo.c:1070 msgid "Abut Horizontal" msgstr "óÏĆÄÉÎÉÔŰ ĐÏ ÇÏÒÉÚÏÎÔÁÌÉ" #: ../../menuinfo.c:1071 msgid "Squish selected objects together horizontally" msgstr "" #: ../../menuinfo.c:1073 msgid "Abut Vertical" msgstr "óÏĆÄÉÎÉÔŰ ĐÏ ŚĆÒÔÉËÁÌÉ" #: ../../menuinfo.c:1074 msgid "Squish selected objects together vertically" msgstr "" #: ../../menuinfo.c:1077 msgid "Flip/Rotate" msgstr "đĆÒĆŚÏÒÏÔ/śÒÁĘĆÎÉĆ" #: ../../menuinfo.c:1078 msgid "Flip and rotate submenu >>>" msgstr "" #: ../../menuinfo.c:1085 msgid "Off" msgstr "śÙËÌÀȚÉÔŰ" #: ../../menuinfo.c:1085 msgid "Do not update canvas window while scrolling" msgstr "" #: ../../menuinfo.c:1087 msgid "Jump" msgstr "óËÁȚËÁÍÉ" #: ../../menuinfo.c:1087 msgid "Jump update canvas window while scrolling" msgstr "" #: ../../menuinfo.c:1089 msgid "Smooth" msgstr "đÌÁŚÎÏ" #: ../../menuinfo.c:1089 msgid "Update canvas window smoothly while scrolling" msgstr "" #: ../../menuinfo.c:1097 msgid "Show Bit/Pixmap" msgstr "đÏËÁÚÙŚÁÔŰ ÒÁÓÔÒÏŚÙĆ ÏÂßĆËÔÙ" #: ../../menuinfo.c:1098 msgid "Toggle between hiding and showing detailed bitmap/pixmap objects" msgstr "" #: ../../menuinfo.c:1101 msgid "Show Measurement" msgstr "đÏËÁÚÙŚÁÔŰ ĐÏÌÏÖĆÎÉĆ ËŐÒÓÏÒÁ" #: ../../menuinfo.c:1102 #, fuzzy msgid "Show cursor measurements" msgstr "đÏËÁÚÙŚÁÔŰ ĐÏÌÏÖĆÎÉĆ ËŐÒÓÏÒÁ" #: ../../menuinfo.c:1103 #, fuzzy msgid "Show Measurement in Tooltip" msgstr "đÏËÁÚÙŚÁÔŰ ĐÏÌÏÖĆÎÉĆ ËŐÒÓÏÒÁ" #: ../../menuinfo.c:1104 msgid "Show cursor measurements in tooltip" msgstr "" #: ../../menuinfo.c:1106 msgid "Set Measure Unit..." msgstr "őÓÔÁÎÏŚÉÔŰ ĆÄÉÎÉĂÙ ÉÚÍĆÒĆÎÉŃ..." #: ../../menuinfo.c:1106 #, fuzzy msgid "Set the unit of measurements" msgstr "đÏËÁÚÙŚÁÔŰ ĐÏÌÏÖĆÎÉĆ ËŐÒÓÏÒÁ" #: ../../menuinfo.c:1109 msgid "Show Menubar" msgstr "đÏËÁÚÁÔŰ ĐÁÎĆÌŰ ÍĆÎÀ" #: ../../menuinfo.c:1109 #, fuzzy msgid "Show menubar window" msgstr "đÏËÁÚÁÔŰ ĐÁÎĆÌŰ ÍĆÎÀ" #: ../../menuinfo.c:1111 msgid "Show Choice" msgstr "" #: ../../menuinfo.c:1111 msgid "Show choice and message window" msgstr "" #: ../../menuinfo.c:1113 msgid "Show Status" msgstr "đÏËÁÚÁÔŰ ÓÔÒÏËŐ ÓÏÓÔÏŃÎÉŃ" #: ../../menuinfo.c:1113 #, fuzzy msgid "Show status window" msgstr "đÏËÁÚÁÔŰ ÓÔÒÏËŐ ÓÏÓÔÏŃÎÉŃ" #: ../../menuinfo.c:1115 #, fuzzy msgid "Show Mode" msgstr "òĆÖÉÍ ĐÒÏËÒŐÔËÉ" #: ../../menuinfo.c:1115 msgid "Show mode window" msgstr "" #: ../../menuinfo.c:1123 ../../menuinfo.c:1150 #, fuzzy msgid "Go HyperSpace In Slide Show" msgstr "đÏËÁÚÙŚÁÔŰ ÓĆÔËŐ ÎÁ ÓÌÁÊÄÁÈ" #: ../../menuinfo.c:1124 ../../menuinfo.c:1151 msgid "Enter HyperSpace mode in slideshow" msgstr "" #: ../../menuinfo.c:1126 ../../menuinfo.c:1153 #, fuzzy msgid "Freehand Mode In Slide Show" msgstr "đÏËÁÚÙŚÁÔŰ ÓĆÔËŐ ÎÁ ÓÌÁÊÄÁÈ" #: ../../menuinfo.c:1127 ../../menuinfo.c:1154 msgid "Go into freehand drawing mode in slideshow" msgstr "" #: ../../menuinfo.c:1130 ../../menuinfo.c:1298 ../../menuinfo.c:1679 #: ../../menuinfo.c:1712 ../../menuinfo.c:1774 msgid "Color" msgstr "ăŚĆÔ" #: ../../menuinfo.c:1131 ../../menuinfo.c:1680 ../../menuinfo.c:1713 #: ../../menuinfo.c:1775 ../../strtbl.c:3640 msgid "Color Menu" msgstr "íĆÎÀ ĂŚĆÔÏŚ" #: ../../menuinfo.c:1138 ../../menuinfo.c:1227 msgid "Slide Show" msgstr "óÌÁÊÄÙ" #: ../../menuinfo.c:1138 #, fuzzy msgid "Toggle SlideShow mode" msgstr "òÁÚÄĆÌŃÔŰ ÓÔÒÁÎÉĂÙ ÌÉÎÉĆÊ" #: ../../menuinfo.c:1140 msgid "Set Slide Show Border Color..." msgstr "ăŚĆÔ ÂÏÒÄÀÒÁ ÏËÎÁ ÓÌÁÊÄÏŚ..." #: ../../menuinfo.c:1141 msgid "Set the color of the slideshow border" msgstr "" #: ../../menuinfo.c:1143 msgid "Set Slide Show Window Offsets..." msgstr "óÍĆĘĆÎÉĆ ÏËÎÁ ÓÌÁÊÄÏŚ..." #: ../../menuinfo.c:1144 msgid "Set the offsets of the slideshow window" msgstr "" #: ../../menuinfo.c:1146 msgid "Visible Grid In Slide Show" msgstr "đÏËÁÚÙŚÁÔŰ ÓĆÔËŐ ÎÁ ÓÌÁÊÄÁÈ" #: ../../menuinfo.c:1147 #, fuzzy msgid "Toggle visible grid in slideshow mode" msgstr "đÏËÁÚÙŚÁÔŰ ÓĆÔËŐ ÎÁ ÓÌÁÊÄÁÈ" #: ../../menuinfo.c:1162 msgid "Zoom In" msgstr "őŚĆÌÉȚÉÔŰ" #: ../../menuinfo.c:1162 #, fuzzy msgid "Zoom in" msgstr "őŚĆÌÉȚÉÔŰ" #: ../../menuinfo.c:1163 msgid "Zoom Out" msgstr "őÍĆÎŰÛÉÔŰ" #: ../../menuinfo.c:1163 #, fuzzy msgid "Zoom out" msgstr "őÍĆÎŰÛÉÔŰ" #: ../../menuinfo.c:1164 msgid "Default Zoom" msgstr "ïÂÙȚÎÙÊ ÒÁÚÍĆÒ" #: ../../menuinfo.c:1164 msgid "No zoom" msgstr "" #: ../../menuinfo.c:1165 msgid "Zoom Way Out" msgstr "Zoom Way Out" #: ../../menuinfo.c:1165 msgid "Zoom way out to see the whole drawing" msgstr "" #: ../../menuinfo.c:1173 ../../menuinfo.c:1593 msgid "+Grid" msgstr "őŚĆÌÉȚÉÔŰ ÛÁÇ ÓĆÔËÉ" #. CSTID_INC_GRID_SIZE #: ../../menuinfo.c:1173 ../../menuinfo.c:1593 ../../strtbl.c:453 msgid "Increment grid size" msgstr "" #: ../../menuinfo.c:1174 ../../menuinfo.c:1594 msgid "-Grid" msgstr "őÍĆÎŰÛÉÔŰ ÛÁÇ ÓĆÔËÉ" #. CSTID_DEC_GRID_SIZE #: ../../menuinfo.c:1174 ../../menuinfo.c:1594 ../../strtbl.c:455 msgid "Decrement grid size" msgstr "" #: ../../menuinfo.c:1175 ../../menuinfo.c:1595 msgid "Visible Grid" msgstr "đÏËÁÚÙŚÁÔŰ ÓĆÔËŐ" #: ../../menuinfo.c:1175 ../../menuinfo.c:1595 msgid "Hide/show grid lines" msgstr "" #: ../../menuinfo.c:1177 ../../menuinfo.c:1597 msgid "Snap To Grid" msgstr "äŚÉÇÁÔŰ ĐÏ ÓĆÔËĆ" #: ../../menuinfo.c:1178 ../../menuinfo.c:1598 msgid "Toggle the snapping to grid points effect" msgstr "" #: ../../menuinfo.c:1180 ../../menuinfo.c:1600 msgid "Save Origin" msgstr "úÁĐÏÍÎÉÔŰ ĐÏÌÏÖĆÎÉĆ" #: ../../menuinfo.c:1181 ../../menuinfo.c:1601 msgid "Save current location as the 'origin' of the drawing" msgstr "" #: ../../menuinfo.c:1183 ../../menuinfo.c:1603 msgid "Scroll To Origin" msgstr "śÏÓÓÔÁÎÏŚÉÔŰ ĐÏÌÏÖĆÎÉĆ" #: ../../menuinfo.c:1184 ../../menuinfo.c:1604 msgid "Scroll to the 'origin' of the drawing" msgstr "" #: ../../menuinfo.c:1185 msgid "Scroll Mode" msgstr "òĆÖÉÍ ĐÒÏËÒŐÔËÉ" #: ../../menuinfo.c:1186 #, fuzzy msgid "ScrollMode submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1188 ../../menuinfo.c:1606 msgid "Zoom" msgstr "íÁÓÛÔÁÂ" #: ../../menuinfo.c:1188 ../../menuinfo.c:1606 #, fuzzy msgid "Zoom submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1197 #, fuzzy msgid "StackedPage submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1199 #, fuzzy msgid "TiledPage submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1200 ../../menuinfo.c:1637 ../../menuinfo.c:1744 msgid "Page Layout" msgstr "òÁÚÍĆĘĆÎÉĆ ÓÔÒÁÎÉĂ" #: ../../menuinfo.c:1201 #, fuzzy msgid "PageLayout submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1210 ../../menuinfo.c:1609 msgid "Set Reduction..." msgstr "őÍĆÎŰÛÉÔŰ/ŐŚĆÌÉȚÉÔŰ..." #: ../../menuinfo.c:1211 ../../menuinfo.c:1610 msgid "Specify reduction/magnification of the whole drawing" msgstr "" #: ../../menuinfo.c:1213 ../../menuinfo.c:1612 msgid "Metric Grid" msgstr "íĆÔÒÉȚĆÓËÁŃ ÓĆÔËÁ" #: ../../menuinfo.c:1214 ../../menuinfo.c:1613 msgid "Toggle between English and Metric grid systems" msgstr "" #: ../../menuinfo.c:1216 msgid "One Motion Select Move" msgstr "One Motion Select Move" #: ../../menuinfo.c:1217 msgid "Toggle between click-select-move and click-select-click-move modes" msgstr "" #: ../../menuinfo.c:1219 msgid "Use Gray Scale" msgstr "éÓĐÏÌŰÚÏŚÁÔŰ ÛËÁÌŐ ÓĆÒÏÇÏ" #: ../../menuinfo.c:1220 msgid "Toggle between using gray scales to tile patterns to speed up printing" msgstr "" #: ../../menuinfo.c:1222 msgid "Use Color Layers" msgstr "éÓĐÏÌŰÚÏŚÁÔŰ ĂŚĆÔÏŚÙĆ ÓÌÏÉ" #: ../../menuinfo.c:1222 #, fuzzy msgid "Toggle color layers" msgstr "éÓĐÏÌŰÚÏŚÁÔŰ ĂŚĆÔÏŚÙĆ ÓÌÏÉ" #: ../../menuinfo.c:1225 msgid "Show/Hide" msgstr "đÏËÁÚÁÔŰ/óĐÒŃÔÁÔŰ" #: ../../menuinfo.c:1226 #, fuzzy msgid "Show/Hide submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1228 #, fuzzy msgid "SlideShow submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1235 msgid "Copy Properties..." msgstr "óËÏĐÉÒÏŚÁÔŰ ÓŚÏÊÓÔŚÁ..." #: ../../menuinfo.c:1236 msgid "Copy properties (e.g., color, fill, etc.) into the cut buffer" msgstr "" #: ../../menuinfo.c:1238 msgid "Paste Properties..." msgstr "śÓÔÁŚÉÔŰ ÓŚÏÊÓÔŚÁ..." #: ../../menuinfo.c:1239 msgid "Paste properties (e.g., color, fill, etc.) from the cut buffer" msgstr "" #: ../../menuinfo.c:1241 msgid "Save Properties..." msgstr "óÏÈÒÁÎÉÔŰ ÓŚÏÊÓÔŚÁ..." #: ../../menuinfo.c:1242 msgid "Save and name a property (e.g., color, fill, etc.) set" msgstr "" #: ../../menuinfo.c:1244 msgid "Restore Properties..." msgstr "śÏÓÓÔÁÎÏŚÉÔŰ ÓŚÏÊÓÔŚÁ..." #: ../../menuinfo.c:1245 msgid "Restore a named property (e.g., color, fill, etc.) set" msgstr "" #. #. * { N_("Update Objects"), "Alt+0", #. * N_("Update selected objects to have current drawing properties"), NULL, #. * CMDID_UPDATE }, #. * { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, #. #: ../../menuinfo.c:1254 msgid "Set Selected Line Width..." msgstr "ôÏÌĘÉÎÁ ŚÙÂÒÁÎÎÏÊ ÌÉÎÉÉ..." #: ../../menuinfo.c:1255 msgid "Change the line width (and arrow width/height) of selected objects" msgstr "" #: ../../menuinfo.c:1257 msgid "Set Selected Font Size..." msgstr "òÁÚÍĆÒ ŚÙÂÒÁÎÎÏÇÏ ÔĆËÓÔÁ..." #: ../../menuinfo.c:1258 msgid "Change the font size of selected objects" msgstr "" #: ../../menuinfo.c:1261 msgid "Add Color..." msgstr "äÏÂÁŚÉÔŰ ĂŚĆÔ..." #: ../../menuinfo.c:1261 msgid "Add colors to the current palette" msgstr "" #: ../../menuinfo.c:1264 msgid "Set Edit Text Size..." msgstr "òÁÚÍĆÒ ÔĆËÓÔÁ ĐÒÉ ÒĆÄÁËÔÉÒÏŚÁÎÉÉ" #: ../../menuinfo.c:1265 msgid "Set the text size to be used in editing existing text objects" msgstr "" #: ../../menuinfo.c:1267 msgid "Set Alt Edit Text BgColor..." msgstr "ăŚĆÔ ÆÏÎÁ ĐÒÉ ÒĆÄÁËÔÉÒÏŚÁÎÉÉ..." #: ../../menuinfo.c:1268 msgid "Set the background color to be used in editing existing text objects" msgstr "" #: ../../menuinfo.c:1270 msgid "Set Alt Edit Text Highlight Color..." msgstr "ăŚĆÔ ŚÙÄĆÌĆÎÉŃ ĐÒÉ ÒĆÄÁËÔÉÒÏŚÁÎÉÉ..." #: ../../menuinfo.c:1271 msgid "Set the highlight color to be used in editing existing text objects" msgstr "" #: ../../menuinfo.c:1273 msgid "Use Alt Edit Text BgColor" msgstr "éÓĐÏÌŰÚÏŚÁÔŰ ÁÌŰÔĆÒÎÁÔÉŚÎÙĆ ĐÁÒÁÍĆÔÒÙ" #: ../../menuinfo.c:1274 msgid "" "Toggles the background color to be used in editing existing text objects" msgstr "" #: ../../menuinfo.c:1277 ../../menuinfo.c:1645 ../../menuinfo.c:1750 msgid "Font" msgstr "ûÒÉÆÔ" #: ../../menuinfo.c:1278 #, fuzzy msgid "Font submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1279 ../../menuinfo.c:1647 ../../menuinfo.c:1752 msgid "Text Style" msgstr "óÔÉÌŰ ÔĆËÓÔÁ" #: ../../menuinfo.c:1280 #, fuzzy msgid "TextStyle submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1281 ../../menuinfo.c:1649 ../../menuinfo.c:1754 msgid "Text Size" msgstr "òÁÚÍĆÒ ÔĆËÓÔÁ" #: ../../menuinfo.c:1282 #, fuzzy msgid "TextSize submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1284 ../../menuinfo.c:1652 ../../menuinfo.c:1760 msgid "Line Dash" msgstr "úÁĐÏÌÎĆÎÉĆ ÌÉÎÉÉ" #: ../../menuinfo.c:1285 #, fuzzy msgid "LineDash submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1286 ../../menuinfo.c:1654 ../../menuinfo.c:1762 msgid "Line Style" msgstr "óÔÉÌŰ ÌÉÎÉÉ" #: ../../menuinfo.c:1287 #, fuzzy msgid "LineStyle submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1288 ../../menuinfo.c:1656 ../../menuinfo.c:1764 msgid "Line Type" msgstr "ôÉĐ ÌÉÎÉÉ" #: ../../menuinfo.c:1289 #, fuzzy msgid "LineType submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1290 ../../menuinfo.c:1658 ../../menuinfo.c:1766 msgid "Line Width" msgstr "ôÏÌĘÉÎÁ ÌÉÎÉÉ" #: ../../menuinfo.c:1291 #, fuzzy msgid "LineWidth submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1293 ../../menuinfo.c:1661 ../../menuinfo.c:1768 msgid "Fill" msgstr "úÁĐÏÌÎĆÎÉĆ" #: ../../menuinfo.c:1294 msgid "Fill submenu >>>" msgstr "đÏÄÍĆÎÀ ÚÁĐÏÌÎĆÎÉŃ >>>" #: ../../menuinfo.c:1295 ../../menuinfo.c:1663 ../../menuinfo.c:1770 msgid "Pen" msgstr "đĆÒÏ" #: ../../menuinfo.c:1296 msgid "Pen submenu >>>" msgstr "đÏÄÍĆÎÀ ĐĆÒÁ >>>" #: ../../menuinfo.c:1298 msgid "Color submenu >>>" msgstr "đÏÄÍĆÎÀ ĂŚĆÔÁ >>>" #: ../../menuinfo.c:1300 ../../menuinfo.c:1672 ../../menuinfo.c:1772 msgid "Transparent Pattern" msgstr "đÒÏÚÒÁȚÎÏÓÔŰ ÛÁÂÌÏÎÁ" #: ../../menuinfo.c:1301 msgid "TransPattern submenu >>>" msgstr "đÏÄÍĆÎÀ ĐÒÏÚÒÁȚÎÏÓÔÉ ÛÁÂÌÏÎÁ >>>" #: ../../menuinfo.c:1308 msgid "Go Back" msgstr "îÁÚÁÄ" #: ../../menuinfo.c:1308 msgid "Go back one file" msgstr "đĆÒĆÊÔÉ ÎÁÚÁÄ ÎÁ ÏÄÉÎ ÆÁÊÌ" #: ../../menuinfo.c:1309 msgid "Go Forward" msgstr "śĐĆÒĆÄ" #: ../../menuinfo.c:1309 msgid "Go forward one file" msgstr "đĆÒĆÊÔÉ ŚĐĆÒĆÄ ÎÁ ÏÄÉÎ ÆÁÊÌ" #: ../../menuinfo.c:1311 msgid "Refresh Current" msgstr "" #: ../../menuinfo.c:1311 msgid "Reload the current file" msgstr "đĆÒĆÚÁÇÒŐÚÉÔŰ ÔĆËŐĘÉÊ ÆÁÊÌ" #: ../../menuinfo.c:1314 msgid "Hot List..." msgstr "" #: ../../menuinfo.c:1314 msgid "Navigate using the hot-list" msgstr "" #: ../../menuinfo.c:1316 msgid "Add Current To Hot List" msgstr "äÏÂÁŚÉÔŰ Ś HotList" #: ../../menuinfo.c:1317 msgid "Add the current file to the hot-list" msgstr "äÏÂÁŚÉÔŰ ÔĆËŐĘÉÊ ÆÁÊÌ Ś HotList" #: ../../menuinfo.c:1320 msgid "Session History..." msgstr "éÓÔÏÒÉŃ ÒÁÂÏÔÙ..." #: ../../menuinfo.c:1321 msgid "Go to a file visited during this session" msgstr "" #: ../../menuinfo.c:1324 msgid "Hyper Space" msgstr "çÉĐĆÒĐÒÏÓÔÒÁÎÓÔŚÏ" #: ../../menuinfo.c:1324 msgid "Toggle HyperSpace mode" msgstr "đĆÒĆËÌÀȚÉÔŰ ÒĆÖÉÍ ÇÉĐĆÒĐÒÏÓÔÒÁÎÓÔŚÁ" #: ../../menuinfo.c:1332 msgid "Attach Attributes" msgstr "đÒÉÓÏĆÄÉÎÉÔŰ ÁÔÒÉÂŐÔÙ" #: ../../menuinfo.c:1333 msgid "Attach selected text objects as attributes for the non-text object" msgstr "đÒÉÓÏĆÄÉÎÉÔŰ ŚÙÄĆÌĆÎÎÙĆ ÔĆËÓÔÏŚÙĆ ÏÂßĆËÔÙ, ËÁË ÁÔÒÉÂŐÔÙ ÄÌŃ ÎĆ-ÔĆËÓÔÏŚÏÇÏ ÏÂßĆËÔÁ" #: ../../menuinfo.c:1335 msgid "Detach Attributes" msgstr "ïÔĂĆĐÉÔŰ ÁÔÒÉÂŐÔÙ" #: ../../menuinfo.c:1336 msgid "Detach all attributes of selected objects" msgstr "ïÔÓÏĆÄÉÎÉÔŰ ŚÓĆ ÁÔÒÉÂŐÔÙ ÏÔ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:1339 msgid "Edit Attributes..." msgstr "đÒÁŚËÁ ÁÔÒÉÂŐÔÏŚ..." #: ../../menuinfo.c:1340 msgid "Edit attributes of a selected object" msgstr "đÒÁŚËÁ ÁÔÒÉÂŐÔÏŚ ŚÙÄĆÌĆÎÎÏÇÏ ÏÂßĆËÔÁ" #: ../../menuinfo.c:1343 msgid "Show Attributes" msgstr "đÏËÁÚÁÔŰ ÁÔÒÉÂŐÔÙ" #: ../../menuinfo.c:1344 msgid "Make all attributes of selected objects visible" msgstr "óÄĆÌÁÔŰ ŚÓĆ ÁÔÒÉÂŐÔÙ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ ŚÉÄÉÍÙÍÉ" #: ../../menuinfo.c:1346 msgid "Show Attribute Names" msgstr "đÏËÁÚÁÔŰ ÉÍĆÎÁ ÁÔÒÉÂŐÔÏŚ" #: ../../menuinfo.c:1347 msgid "Make all attribute names of selected objects visible" msgstr "óÄĆÌÁÔŰ ÉÍĆÎÁ ŚÓĆÈ ÁÔÒÉÂŐÔÏŚ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ ŚÉÄÉÍÙÍÉ" #: ../../menuinfo.c:1349 msgid "Hide Attributes" msgstr "óËÒÙÔŰ ÁÔÒÉÂŐÔÙ" #: ../../menuinfo.c:1350 msgid "Hide all attributes for selected objects" msgstr "óËÒÙÔŰ ŚÓĆ ÁÔÒÉÂŐÔÙ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:1352 msgid "Hide Attribute Names" msgstr "óËÒÙÔŰ ÉÍĆÎÁ ÁÔÒÉÂŐÔÏŚ" #: ../../menuinfo.c:1353 msgid "Hide all attribute names for selected objects" msgstr "óËÒÙÔŰ ŚÓĆ ÉÍĆÎÁ ÁÔÒÉÂŐÔÏŚ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../menuinfo.c:1355 msgid "Toggle Eq Attribute Shown..." msgstr "đĆÒĆËÌÀȚÉÔŰ ĐÏËÁÚ ÁÔÒÉÂŐÔÁ Eq..." #: ../../menuinfo.c:1356 msgid "Showing/hiding the 'eq=' attibute (for a LaTeX equation object)" msgstr "" #: ../../menuinfo.c:1359 msgid "Move/Justfy An Attribute" msgstr "đĆÒĆÍĆÓÔÉÔŰ/ŚÙÒÏŚÎŃÔŰ ÁÔÒÉÂŐÔ" #: ../../menuinfo.c:1360 msgid "Move/justify an attribute for a selected object" msgstr "đĆÒĆÍĆÓÔÉÔŰ/ŚÙÒÏŚÎŃÔŰ ÁÔÒÉÂŐÔ ŚÙÄĆÌĆÎÎÏÇÏ ÏÂßĆËÔÁ" #: ../../menuinfo.c:1363 msgid "Import Attributes..." msgstr "éÍĐÏÒÔÉÒÏŚÁÔŰ ÁÔÒÉÂŐÔÙ..." #: ../../menuinfo.c:1364 msgid "Import attributes of a selected object from a text file" msgstr "éÍĐÏÒÔÉÒÏŚÁÔŰ ÁÔÒÉÂŐÔÙ ŚÙÄĆÌĆÎÎÏÇÏ ÏÂßĆËÔÁ ÉÚ ÔĆËÓÔÏŚÏÇÏ ÆÁÊÌÁ" #: ../../menuinfo.c:1366 msgid "Export Attributes..." msgstr "üËÓĐÏÒÔÉÒÏŚÁÔŰ ÁÔÒÉÂŐÔÙ..." #: ../../menuinfo.c:1367 msgid "Export attributes of a selected object to a text file" msgstr "üËÓĐÏÒÔÉÒÏŚÁÔŰ ÁÔÒÉÂŐÔÙ ŚÙÄĆÌĆÎÎÏÇÏ ÏÂßĆËÔÁ Ś ÔĆËÓÔÏŚÙÊ ÆÁÊÌ" #: ../../menuinfo.c:1375 msgid "Attach File Attributes" msgstr "đÒÉÓÏĆÄÉÎÉÔŰ ÁÔÒÉÂŐÔÙ Ë ÆÁÊÌŐ" #: ../../menuinfo.c:1376 msgid "Attach selected text objects as file attributes" msgstr "đÒÉÓÏĆÄÉÎÉÔŰ ŚÙÄĆÌĆÎÎÙĆ ÔĆËÓÔÏŚÙĆ ÏÂßĆËÔÙ, ËÁË ÁÔÒÉÂŐÔÙ Ë ÆÁÊÌŐ" #: ../../menuinfo.c:1378 msgid "Detach File Attributes" msgstr "ïÔÓÏĆÄÉÎÉÔŰ ÁÔÒÉÂŐÔÙ ÏÔ ÆÁÊÌÁ" #: ../../menuinfo.c:1379 msgid "Detach all file attributes" msgstr "ïÔÓÏĆÄÉÎÉÔŰ ŚÓĆ ÁÔÒÉÂŐÔÙ ÏÔ ÆÁÊÌÁ" #. STID_EDIT_FILE_ATTRS_DOTS #: ../../menuinfo.c:1382 ../../strtbl.c:670 msgid "Edit File Attributes..." msgstr "đÒÁŚËÁ ÁÔÒÉÂŐÔÏŚ ÆÁÊÌÁ..." #: ../../menuinfo.c:1383 msgid "Edit file attributes" msgstr "đÒÁŚËÁ ÁÔÒÉÂŐÔÏŚ ÆÁÊÌÁ" #: ../../menuinfo.c:1391 msgid "Animate Send" msgstr "" #: ../../menuinfo.c:1392 msgid "Animate a little token on a selected poly (not very useful)" msgstr "" #: ../../menuinfo.c:1394 msgid "Animate Flash" msgstr "" #: ../../menuinfo.c:1395 msgid "Flash a selected poly (not very useful)" msgstr "" #: ../../menuinfo.c:1398 msgid "Renumber Object IDs" msgstr "" #: ../../menuinfo.c:1399 msgid "Renumber object IDs for all objects" msgstr "" #: ../../menuinfo.c:1407 msgid "Connect Two Ports by a Wire..." msgstr "" #: ../../menuinfo.c:1408 msgid "Connect two ports by a wire" msgstr "" #: ../../menuinfo.c:1410 msgid "Repeat Connect Two Ports by a Wire..." msgstr "" #: ../../menuinfo.c:1411 msgid "" "Repeatedly connecting two ports by a wire (will not prompt if the wire name " "can be detected). Wire signal name will not be shown." msgstr "" #: ../../menuinfo.c:1414 msgid "Show Wire Signal Name" msgstr "" #: ../../menuinfo.c:1415 msgid "" "Toggle between showing (with placing) and hiding the wire signal name when " "connecting ports" msgstr "" #: ../../menuinfo.c:1418 msgid "Merge Ports with An Object" msgstr "" #: ../../menuinfo.c:1419 msgid "Merge selected floating port objects with a selected composite object" msgstr "" #: ../../menuinfo.c:1421 msgid "Connect Ports to a Broadcast Wire" msgstr "" #: ../../menuinfo.c:1422 msgid "" "Connect selected floating port objects to a selected broadcast-type wire" msgstr "" #: ../../menuinfo.c:1425 msgid "Clear Signal Name for a Port..." msgstr "" #: ../../menuinfo.c:1426 msgid "Clear the 'signal_name=' attribute for a port" msgstr "" #: ../../menuinfo.c:1428 msgid "Rename Signal Name for a Port..." msgstr "" #: ../../menuinfo.c:1429 msgid "Rename the 'signal_name=' attribute for a port" msgstr "" #: ../../menuinfo.c:1437 msgid "Merge With Table..." msgstr "ïÂßĆÄÉÎÉÔŰ Ó ÔÁÂÌÉĂĆÊ..." #: ../../menuinfo.c:1438 msgid "Merge selected object with a table file" msgstr "ïÂßĆÄÉÎÉÔŰ ŚÙÄĆÌĆÎÎÙĆ ÏÂßĆËÔÙ Ó ÔÁÂÌÉȚÎÙÍ ÆÁÊÌÏÍ" #: ../../menuinfo.c:1440 msgid "Export To Table..." msgstr "üËÓĐÏÒÔÉÒÏŚÁÔŰ Ś ÔÁÂÌÉĂŐ..." #: ../../menuinfo.c:1441 msgid "Export attributes of selected objects to a table file" msgstr "üËÓĐÏÒÔÉÒÏŚÁÔŰ ÁÔÒÉÂŐÔÙ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ Ó ÔÁÂÌÉȚÎÙÍ ÆÁÊÌÏÍ" #: ../../menuinfo.c:1449 msgid "Make Symbolic" msgstr "őĐÁËÏŚÁÔŰ Ś ÓÉÍŚÏÌ" #: ../../menuinfo.c:1450 msgid "Turn a selected grouped/icon object into a symbol object" msgstr "" #: ../../menuinfo.c:1452 msgid "UnMake Symbolic" msgstr "òÁÓĐÁËÏŚÁÔŰ ÉÚ ÓÉÍŚÏÌÁ" #: ../../menuinfo.c:1453 msgid "Turn a selected symbol object into a grouped object" msgstr "" #: ../../menuinfo.c:1456 msgid "Instantiate..." msgstr "úÁÇÒŐÚÉÔŰ ÓÉÍŚÏÌ ÉÚ ÄÏÍĆÎÁ..." #: ../../menuinfo.c:1457 msgid "Instantiate a building-block object from the current domain" msgstr "" #: ../../menuinfo.c:1460 msgid "Make Iconic..." msgstr "đÏÉÍĆÎÏŚÁÔŰ ÏÂßĆËÔ" #: ../../menuinfo.c:1461 msgid "Turn a selected grouped/symbol object into an icon object" msgstr "" #: ../../menuinfo.c:1463 msgid "UnMake Iconic" msgstr "òÁÚÙÍĆÎÏŚÁÔŰ ÏÂßĆËÔ" #: ../../menuinfo.c:1464 msgid "Turn an icon object into a grouped object" msgstr "" #: ../../menuinfo.c:1467 msgid "Push" msgstr "śÏÊÔÉ Ś ÓÉÍŚÏÌ" #: ../../menuinfo.c:1468 msgid "Push into (edit) the symbol file which defines the selected icon object" msgstr "" #: ../../menuinfo.c:1470 msgid "Pop" msgstr "śÙÊÔÉ ÉÚ ÓÉÍŚÏÌÁ" #: ../../menuinfo.c:1471 msgid "Pop back to a high lever (reverse of Push)" msgstr "" #: ../../menuinfo.c:1474 msgid "Attribute" msgstr "áÔÒÉÂŐÔÙ" #: ../../menuinfo.c:1475 msgid "Attribute submenu >>>" msgstr "đÏÄÍĆÎÀ ÁÔÒÉÂŐÔÏŚ >>>" #: ../../menuinfo.c:1476 msgid "File Attribute" msgstr "áÔÒÉÂŐÔÙ ÆÁÊÌÁ" #: ../../menuinfo.c:1477 msgid "File attribute submenu >>>" msgstr "đÏÄÍĆÎÀ ÁÔÒÉÂŐÔÏŚ ÆÁÊÌÁ >>>" #: ../../menuinfo.c:1479 msgid "Update Symbols" msgstr "đĆÒĆȚÉÔÁÔŰ ÓÉÍŚÏÌÙ" #: ../../menuinfo.c:1480 msgid "Refresh selected icon objects from their definition files" msgstr "" #: ../../menuinfo.c:1482 msgid "Save Sym In Library..." msgstr "đÏÍĆÓÔÉÔŰ ÓÉÍŚÏÌ Ś ÂÉÂÌÉÏÔĆËŐ..." #: ../../menuinfo.c:1483 msgid "Save symbol file in a library path within the current domain" msgstr "" #: ../../menuinfo.c:1485 msgid "Replace Graphic" msgstr "úÁÍĆÎÉÔŰ ÇÒÁÆÉËŐ" #: ../../menuinfo.c:1486 msgid "" "Replace the graphical part of selected objects by the graphical object in " "the cut buffer" msgstr "úÁÍĆÎÉÔŰ ÇÒÁÆÉȚĆÓËŐÀ ȚÁÓÔŰ ŚÙÄĆÌĆÎÎÏÇÏ ÏÂßĆËÔÁ ÎÁ ÇÒÁÆÉȚĆÓËŐÀ ȚÁÓÔŰ ÏÂßĆËÔÁ, ÎÁÈÏÄŃĘĆÇÏÓŃ Ś ÂŐÆĆÒĆ ÏÂÍĆÎÁ" #: ../../menuinfo.c:1489 msgid "Domain" msgstr "äÏÍĆÎ" #: ../../menuinfo.c:1490 msgid "Domain submenu >>>" msgstr "đÏÄÍĆÎÀ ÄÏÍĆÎÏŚ >>>" #: ../../menuinfo.c:1491 msgid "Ports and Signals" msgstr "" #: ../../menuinfo.c:1492 #, fuzzy msgid "Ports and Signal submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1493 msgid "Table" msgstr "ôÁÂÌÉĂÁ" #: ../../menuinfo.c:1494 msgid "Table submenu >>>" msgstr "đÏÄÍĆÎÀ ÔÁÂÌÉĂÙ" #: ../../menuinfo.c:1495 msgid "Misc" msgstr "đÒÏȚĆĆ" #: ../../menuinfo.c:1496 #, fuzzy msgid "Misc submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1497 msgid "Return" msgstr "śÏÚŚÒÁÔ" #: ../../menuinfo.c:1498 msgid "Return submenu >>>" msgstr "" #: ../../menuinfo.c:1500 msgid "Exec Cmds From File..." msgstr "śÙĐÏÌÎÉÔŰ ËÏÍÁÎÄÙ ÉÚ ÆÁÊÌÁ..." #: ../../menuinfo.c:1501 msgid "Execute internal commands from a file" msgstr "" #: ../../menuinfo.c:1509 msgid "Latest Release Info" msgstr "éÎÆÏÒÍÁĂÉŃ Ï ĐÏÓÌĆÄÎĆÊ ŚĆÒÓÉÉ" #: ../../menuinfo.c:1510 msgid "Find out what is the version number of the most recently released tgif" msgstr "" #: ../../menuinfo.c:1513 msgid "Copyright" msgstr "áŚÔÏÒÓËÉĆ ĐÒÁŚÁ" #: ../../menuinfo.c:1513 msgid "Copyright information" msgstr "éÎÆÏÒÍÁĂÉŃ Ï ÁŚÔÏÒÓËÉÈ ĐÒÁŚÁÈ" #: ../../menuinfo.c:1516 msgid "About" msgstr "ï ĐÒÏÇÒÁÍÍĆ" #: ../../menuinfo.c:1517 msgid "Version information, where to send bug reports, etc." msgstr "éÎÆÏÒÍÁĂÉŃ Ï ŚĆÒÓÉÉ, ËŐÄÁ ÎÁĐÒÁŚÌŃÔŰ ÓÏÏÂĘĆÎÉŃ Ï ÏÛÉÂËÁÈ É Ô.Đ." #: ../../menuinfo.c:1535 ../../menuinfo.c:1563 msgid "Mode" msgstr "òĆÖÉÍ" #. CSTID_MODE_MENU #: ../../menuinfo.c:1535 ../../menuinfo.c:1563 ../../strtbl.c:81 msgid "Mode Menu" msgstr "íĆÎÀ ÒĆÖÉÍÏŚ" #: ../../menuinfo.c:1546 ../../menuinfo.c:1584 ../../menuinfo.c:1631 #: ../../menuinfo.c:1711 ../../menuinfo.c:1739 msgid "Properties Menu" msgstr "íĆÎÀ ÓŚÏÊÓÔŚ" #: ../../menuinfo.c:1548 ../../menuinfo.c:1677 ../../menuinfo.c:1777 #, fuzzy msgid "ImageProc Menu" msgstr "ïÂÒÁÂÏÔÁÔŰ ÒÁÓÔÒÏŚÙÊ ÒÉÓŐÎÏË" #: ../../menuinfo.c:1550 #, fuzzy msgid "Edit Attribute In Editor" msgstr "òĆÄÁËÔÉÒÏŚÁÔŰ ÁÔÒÉÂŐÔÙ" #: ../../menuinfo.c:1551 msgid "Edit attribute in editor submenu >>>" msgstr "" #: ../../menuinfo.c:1553 #, fuzzy msgid "Get Property" msgstr "îÁÓÔÒÏÊËÉ" #: ../../menuinfo.c:1554 #, fuzzy msgid "Get property submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1555 msgid "Peek Dimension" msgstr "" #: ../../menuinfo.c:1556 #, fuzzy msgid "Peek dimension submenu >>>" msgstr "śĆÒÎŐÔŰÓŃ Ë ĐÏÄÍĆÎÀ >>>" #: ../../menuinfo.c:1571 msgid "Cut selected text into the cut buffer" msgstr "" #: ../../menuinfo.c:1580 #, fuzzy msgid "Move Edit Text Box..." msgstr "òÁÚÍĆÒ ÔĆËÓÔÁ ĐÒÉ ÒĆÄÁËÔÉÒÏŚÁÎÉÉ" #: ../../menuinfo.c:1580 msgid "Move the edit text box" msgstr "" #: ../../menuinfo.c:1622 ../../menuinfo.c:1702 ../../menuinfo.c:1730 msgid "File" msgstr "æÁÊÌ" #: ../../menuinfo.c:1622 ../../menuinfo.c:1702 ../../menuinfo.c:1730 #, fuzzy msgid "File Menu" msgstr "æÁÊÌ" #: ../../menuinfo.c:1624 ../../menuinfo.c:1704 ../../menuinfo.c:1732 msgid "Edit" msgstr "đÒÁŚËÁ" #: ../../menuinfo.c:1624 ../../menuinfo.c:1704 ../../menuinfo.c:1732 #, fuzzy msgid "Edit Menu" msgstr "òĆÄÁËÔÉÒÏŚÁÔŰ" #: ../../menuinfo.c:1626 ../../menuinfo.c:1706 ../../menuinfo.c:1734 msgid "Layout" msgstr "òÁÚÍĆÔËÁ" #. CSTID_LAYOUT_MENU #: ../../menuinfo.c:1627 ../../menuinfo.c:1707 ../../menuinfo.c:1735 #: ../../strtbl.c:159 msgid "Layout Menu" msgstr "íĆÎÀ ÒÁÚÍĆÔËÉ" #: ../../menuinfo.c:1628 ../../menuinfo.c:1708 ../../menuinfo.c:1736 msgid "Arrange" msgstr "òÁÓĐÏÌÏÖĆÎÉĆ" #: ../../menuinfo.c:1629 ../../menuinfo.c:1709 ../../menuinfo.c:1737 msgid "Arrange Menu" msgstr "íĆÎÀ ÒÁÓĐÏÌÏÖĆÎÉŃ" #: ../../menuinfo.c:1638 ../../menuinfo.c:1745 ../../strtbl.c:3662 #: ../../strtbl.c:3664 msgid "PageLayout Menu" msgstr "íĆÎÀ ÒÁÚÍĆÔËÉ ÓÔÒÁÎÉĂÙ" #: ../../menuinfo.c:1641 ../../menuinfo.c:1747 ../../strtbl.c:3645 msgid "HoriAlign Menu" msgstr "íĆÎÀ ÇÏÒÉÚÏÎÔÁÌŰÎÏÇÏ ŚÙÒÁŚÎÉŚÁÎÉŃ" #: ../../menuinfo.c:1643 ../../menuinfo.c:1749 ../../strtbl.c:3650 msgid "VertAlign Menu" msgstr "íĆÎÀ ŚĆÒÔÉËÁÌŰÎÏÇÏ ŚÙÒÁŚÎÉŚÁÎÉŃ" #: ../../menuinfo.c:1645 ../../menuinfo.c:1750 ../../strtbl.c:3678 msgid "Font Menu" msgstr "íĆÎÀ ÛÒÉÆÔÏŚ" #: ../../menuinfo.c:1648 ../../menuinfo.c:1753 ../../strtbl.c:3669 #: ../../strtbl.c:3671 ../../strtbl.c:3673 msgid "TextStyle Menu" msgstr "íĆÎÀ ÓÔÉÌŃ ÔĆËÓÔÁ" #: ../../menuinfo.c:1650 ../../menuinfo.c:1755 ../../strtbl.c:3688 msgid "TextSize Menu" msgstr "íĆÎÀ ÒÁÚÍĆÒÁ ÔĆËÓÔÁ" #: ../../menuinfo.c:1653 ../../menuinfo.c:1761 ../../strtbl.c:3708 msgid "LineDash Menu" msgstr "íĆÎÀ ÚÁĐÏÌÎĆÎÉŃ ÌÉÎÉÉ" #: ../../menuinfo.c:1655 ../../menuinfo.c:1763 ../../strtbl.c:3698 msgid "LineStyle Menu" msgstr "íĆÎÀ ÓÔÉÌŃ ÌÉÎÉÉ" #: ../../menuinfo.c:1657 ../../menuinfo.c:1765 ../../strtbl.c:3703 msgid "LineType Menu" msgstr "íĆÎÀ ÔÉĐÁ ÌÉÎÉÉ" #: ../../menuinfo.c:1659 ../../menuinfo.c:1767 ../../strtbl.c:3693 msgid "LineWidth Menu" msgstr "íĆÎÀ ÔÏÌĘÉÎÙ ÌÉÎÉÉ" #: ../../menuinfo.c:1661 ../../menuinfo.c:1768 ../../strtbl.c:3749 msgid "Fill Menu" msgstr "íĆÎÀ ÚÁĐÏÌÎĆÎÉŃ" #: ../../menuinfo.c:1663 ../../menuinfo.c:1770 ../../strtbl.c:3754 msgid "Pen Menu" msgstr "íĆÎÀ ĐĆÒÁ" #: ../../menuinfo.c:1666 ../../menuinfo.c:1740 msgid "Move Mode" msgstr "òĆÖÉÍ ĐĆÒĆÍĆĘĆÎÉŃ" #: ../../menuinfo.c:1667 ../../menuinfo.c:1741 ../../strtbl.c:3723 #: ../../strtbl.c:3725 msgid "MoveMode Menu" msgstr "íĆÎÀ ÒĆÖÉÍÁ ĐĆÒĆÍĆĘĆÎÉŃ" #: ../../menuinfo.c:1669 ../../menuinfo.c:1757 ../../strtbl.c:3730 #, fuzzy msgid "Shape Menu" msgstr "Sharpen" #: ../../menuinfo.c:1670 ../../menuinfo.c:1758 msgid "Stretchable Text" msgstr "éÚÍĆÎĆÎÉĆ ÒÁÚÍĆÒÏŚ ÔĆËÓÔÁ" #: ../../menuinfo.c:1671 ../../menuinfo.c:1759 ../../strtbl.c:3735 #: ../../strtbl.c:3737 #, fuzzy msgid "StretchText Menu" msgstr "éÚÍĆÎĆÎÉĆ ÒÁÚÍĆÒÏŚ ÔĆËÓÔÁ" #: ../../menuinfo.c:1673 ../../menuinfo.c:1773 ../../strtbl.c:3759 #: ../../strtbl.c:3761 #, fuzzy msgid "TransPattern Menu" msgstr "Transparent Pattern" #: ../../menuinfo.c:1681 ../../menuinfo.c:1714 ../../menuinfo.c:1778 msgid "Navigate" msgstr "îÁŚÉÇÁĂÉŃ" #: ../../menuinfo.c:1682 ../../menuinfo.c:1715 ../../menuinfo.c:1779 #, fuzzy msgid "Navigate Menu" msgstr "íĆÎÀ ÎÁŚÉÇÁĂÉÉ" #: ../../menuinfo.c:1683 ../../menuinfo.c:1716 ../../menuinfo.c:1780 msgid "Special" msgstr "óĐĆĂÉÁÌŰÎÏĆ" #: ../../menuinfo.c:1684 ../../menuinfo.c:1717 ../../menuinfo.c:1781 #, fuzzy msgid "Special Menu" msgstr "óĐĆĂÉÁÌŰÎÏ" #: ../../menuinfo.c:1686 ../../menuinfo.c:1719 ../../menuinfo.c:1783 msgid "Tangram-II" msgstr "Tangram-II" #: ../../menuinfo.c:1687 ../../menuinfo.c:1720 ../../menuinfo.c:1784 #, fuzzy msgid "Tangram-II Menu" msgstr "Tangram-II" #: ../../menuinfo.c:1689 ../../menuinfo.c:1722 ../../menuinfo.c:1786 msgid "Help" msgstr "óĐÒÁŚËÁ" #: ../../menuinfo.c:1689 ../../menuinfo.c:1722 ../../menuinfo.c:1786 #, fuzzy msgid "Help Menu" msgstr "đÏÍÏĘŰ" #: ../../menuinfo.c:1742 msgid "Page" msgstr "óÔÒÁÎÉĂÁ" #. CSTID_PAGE_MENU #: ../../menuinfo.c:1743 ../../strtbl.c:247 ../../strtbl.c:3655 #: ../../strtbl.c:3657 #, fuzzy msgid "Page Menu" msgstr "óÔÒÁÎÉĂÁ" #. CSTID_OK #: ../../strtbl.c:37 msgid "Ok" msgstr "OK" #. CSTID_CANCEL #: ../../strtbl.c:39 msgid "Cancel" msgstr "ïÔÍĆÎÉÔŰ" #. CSTID_PARANED_NONE #: ../../strtbl.c:41 ../../strtbl.c:3344 ../../strtbl.c:3439 #: ../../strtbl.c:3466 ../../strtbl.c:3493 ../../strtbl.c:3520 #: ../../strtbl.c:3730 msgid "(none)" msgstr "" #. CSTID_SET_FONT_TO #: ../../strtbl.c:43 #, c-format msgid "Set font to '%s'" msgstr "" #. CSTID_NO_OBJ_SELECTED #: ../../strtbl.c:45 msgid "No object selected." msgstr "îĆÔ ŚÙÄĆÌĆÎÎÏÇÏ ÏÂßĆËÔÁ." #. CSTID_SPECIFY_ARC_END #: ../../strtbl.c:47 msgid "Please specify the end of an arc." msgstr "" #. CSTID_SPECIFY_ARC_START #: ../../strtbl.c:49 msgid "Please specify the start of an arc." msgstr "" #. CSTID_SPECIFY_ARC_THIRD #: ../../strtbl.c:51 msgid "Please specify a 3rd point on the arc." msgstr "" #. CSTID_SET_ARC_END #: ../../strtbl.c:53 msgid "Set end of arc" msgstr "" #. CSTID_SET_ARC_START #: ../../strtbl.c:55 msgid "Set start of arc" msgstr "" #. CSTID_SET_ARC_THIRD #: ../../strtbl.c:57 msgid "Set 3rd point on arc" msgstr "" #. CSTID_SPECIFY_ARC_END_CW #: ../../strtbl.c:59 msgid "Please specify the end of the arc (clockwise)." msgstr "" #. CSTID_SPECIFY_ARC_END_CCW #: ../../strtbl.c:61 msgid "Please specify the end of the arc (counter-clockwise)." msgstr "" #. CSTID_CANCEL_NOT_AVAIL #: ../../strtbl.c:63 msgid "CANCEL is not a valid option." msgstr "" #. CSTID_DLG_DEF_CONTINUE #: ../../strtbl.c:65 msgid "( <CR> or <ESC> to continue )" msgstr "" #. CSTID_DLG_ACCEPT_CANCEL #: ../../strtbl.c:67 msgid "( <CR>: accept, <ESC>: cancel )" msgstr "" #. CSTID_MALFORMED_INPUT_STR #: ../../strtbl.c:69 #, c-format msgid "Malformed input '%s'." msgstr "" #. CSTID_CACHING_TEXT_BMP #: ../../strtbl.c:71 msgid "Caching text bitmap..." msgstr "" #. CSTID_PROGRESS_PERCENT #: ../../strtbl.c:73 #, c-format msgid "Progress: %1d%%" msgstr "" #. CSTID_FINISHED_CACHEING_TEXT_BMP #: ../../strtbl.c:75 msgid "Finishing caching text bitmap..." msgstr "" #. CSTID_BAD_BOX_BBOX_ADJUSTED #: ../../strtbl.c:77 msgid "Bad box bounding box. Adjusted." msgstr "" #. CSTID_MAIN_MENU #: ../../strtbl.c:79 msgid "Main Menu" msgstr "çÌÁŚÎÏĆ ÍĆÎÀ" #. CSTID_ROTATE_DEGREES_CW #: ../../strtbl.c:83 #, fuzzy, c-format msgid "Rotate %s degrees clock-wise" msgstr "śÒÁĘÁÔŰ ĐÏ ȚÁÓÏŚÏÊ" #. CSTID_ROTATE_DEGREES_CCW #: ../../strtbl.c:85 #, c-format msgid "Rotate %s degrees counter-clock-wise" msgstr "" #. CSTID_PRINT_MODE #: ../../strtbl.c:87 #, c-format msgid "%s print mode" msgstr "" #. CSTID_EXPORT_MODE #: ../../strtbl.c:89 #, c-format msgid "%s export mode" msgstr "" #. CSTID_PRINT_EXPORT_MENU #: ../../strtbl.c:91 #, fuzzy msgid "Print/ExportFormat Menu" msgstr "đĆȚÁÔŰ/üËÓĐÏÒÔ" #. CSTID_FLUSH_UNDO_PERCENT #: ../../strtbl.c:93 #, c-format msgid "Flushing undo buffers... %1d%%" msgstr "ïȚÉÓÔËÁ ÂŐÆĆÒÏŚ ÏÔËÁÔÁ... %1d%%" #. CSTID_SET_COLOR_TO #: ../../strtbl.c:95 #, c-format msgid "Set color to '%s'" msgstr "" #. CSTID_CANNOT_ALLOC_COLOR_USE_ALT #: ../../strtbl.c:97 #, c-format msgid "Cannot allocate color '%s', use '%s' instead." msgstr "" #. CSTID_UPDATING_PIXELS #: ../../strtbl.c:99 #, c-format msgid "Updating pixels (%1d - %1dx%1d)..." msgstr "" #. CSTID_NONE #: ../../strtbl.c:101 msgid "none" msgstr "" #. CSTID_PARANED_NULL #: ../../strtbl.c:103 msgid "null" msgstr "" #. CSTID_RESTORE #: ../../strtbl.c:111 #, fuzzy msgid "Restore" msgstr "śĆÒÎŐÔŰÓŃ" #. CSTID_YES #: ../../strtbl.c:113 msgid "Yes" msgstr "äÁ" #. CSTID_NO #: ../../strtbl.c:115 msgid "No" msgstr "îĆÔ" #. CSTID_EXTRA #: ../../strtbl.c:117 msgid "Extra" msgstr "" #. CSTID_INTERRUPT #: ../../strtbl.c:119 msgid "interrupt" msgstr "" #. CSTID_LEAVE_HYPERSPACE #: ../../strtbl.c:121 #, fuzzy msgid "Leave HyperSpace" msgstr "Hyper Space" #. CSTID_ENTER_HYPERSPACE #: ../../strtbl.c:123 #, fuzzy msgid "Enter HyperSpace" msgstr "Hyper Space" #. CSTID_CACHING_IMAGE #: ../../strtbl.c:125 #, fuzzy msgid "Caching images..." msgstr "đÏÍĆÎŃÔŰ ÏÂÌÁÓÔŰ..." #. CSTID_TOGGLE_SMOOTH_HINGE #: ../../strtbl.c:127 msgid "Toggle smooth/hinge points" msgstr "" #. CSTID_FINISH #: ../../strtbl.c:129 msgid "Finish" msgstr "" #. CSTID_DEL_A_VERTEX #: ../../strtbl.c:131 msgid "Delete a vertex" msgstr "" #. CSTID_ADD_A_VERTEX #: ../../strtbl.c:133 msgid "Add a vertex" msgstr "" #. CSTID_START_LAYOUT_ON_ARC #: ../../strtbl.c:135 #, fuzzy msgid "Start layout on arc" msgstr "śÙÒÏŚÎŃÔŰ ĐÏ ÄŐÇĆ" #. CSTID_END_LAYOUT_ON_ARC #: ../../strtbl.c:137 #, fuzzy msgid "End layout on arc" msgstr "śÙÒÏŚÎŃÔŰ ĐÏ ÄŐÇĆ" #. CSTID_EXECUTING_GIVEN_PROGRAM #: ../../strtbl.c:139 #, c-format msgid "Executing '%s'..." msgstr "éÓĐÏÌÎŃĆÔÓŃ '%s'..." #. CSTID_DOTS_DONE #: ../../strtbl.c:141 msgid "...Done" msgstr "...çÏÔÏŚÏ" #. CSTID_IMPORTING_FILE #: ../../strtbl.c:143 #, c-format msgid "Importing '%s'..." msgstr "éÍĐÏÒÔÉÒŐĆÔÓŃ '%s'..." #. CSTID_LOADING_FILE #: ../../strtbl.c:145 #, c-format msgid "Loading '%s'..." msgstr "úÁÇÒŐÖÁĆÔÓŃ '%s'..." #. CSTID_EDIT_TEXT_SIZE_SUBSTR #: ../../strtbl.c:147 #, fuzzy msgid "edit text size" msgstr "òÁÚÍĆÒ ÔĆËÓÔÁ ĐÒÉ ÒĆÄÁËÔÉÒÏŚÁÎÉÉ" #. CSTID_SET_FONT_SIZE_TO_PT #: ../../strtbl.c:149 #, c-format msgid "Set font size to %1dpt" msgstr "őÓÔÁÎÏŚÉÔŰ ÒÁÚÍĆÒ ÛÒÉÆÔÁ Ś %1dpt" #. CSTID_SET_FONT_SIZE_TO #: ../../strtbl.c:151 #, c-format msgid "Set font size to %1d" msgstr "őÓÔÁÎÏŚÉÔŰ ÒÁÚÍĆÒ ÛÒÉÆÔÁ Ś %1d" #. CSTID_MAKING_CONN_TO_HOST #: ../../strtbl.c:153 #, c-format msgid "%s: making connection to '%s'..." msgstr "%s: ŐÓÔÁÎÁŚÌÉŚÁĆÔÓŃ ÓÏĆÄÉÎĆÎÉĆ Ó '%s'..." #. CSTID_CONN_TO_HOST_ESTABLISHED #: ../../strtbl.c:155 #, c-format msgid "%s: connection to '%s' established." msgstr "%s: ÓÏĆÄÉÎĆÎÉĆ Ó '%s' ŐÓÔÁÎÏŚÌĆÎÏ." #. CSTID_LOGIN_SUCC_RETRIEVE_DATA #: ../../strtbl.c:157 #, c-format msgid "%s: login successful; retrieving data..." msgstr "" #. CSTID_MAKING_CONN_TO_HOST_PORT #: ../../strtbl.c:161 #, c-format msgid "%s: making connection to '%s:%1d'..." msgstr "" #. CSTID_CONN_TO_HOST_PORT_ESTB #: ../../strtbl.c:163 #, c-format msgid "%s: connection to '%s:%1d' established." msgstr "" #. CSTID_SENDING_REQUESTS_DOTS #: ../../strtbl.c:165 #, c-format msgid "%s: sending requests..." msgstr "" #. CSTID_PARANED_UNKNOWN #: ../../strtbl.c:167 msgid "(unknown)" msgstr "" #. CSTID_READING_RESPONSE_DOTS #: ../../strtbl.c:169 #, c-format msgid "%s: reading responses..." msgstr "" #. CSTID_RESPONSES_RECEIVED #: ../../strtbl.c:171 #, c-format msgid "%s: responses received." msgstr "" #. CSTID_GEN_FINAL_PIXELS_PERC #: ../../strtbl.c:173 #, c-format msgid "Generating final pixels: %1d%%" msgstr "" #. CSTID_BUILDING_HISTOGRAM_DOTS #: ../../strtbl.c:175 msgid "Building histogram..." msgstr "" #. CSTID_HISTOGRAM_PERC #: ../../strtbl.c:177 #, c-format msgid "Histogram: %1d%%" msgstr "" #. CSTID_COMP_NEW_PIXELS_PERC #: ../../strtbl.c:179 ../../strtbl.c:185 #, c-format msgid "Computing new pixels: %1d%%" msgstr "" #. CSTID_QUANTIZING_COLORS_DOTS #: ../../strtbl.c:181 #, c-format msgid "Quantizing from %1d to %1d colors..." msgstr "" #. CSTID_REMAPPING_COLORS_DOTS #: ../../strtbl.c:183 #, fuzzy msgid "Remapping Colors..." msgstr "äÏ ÚÁÄÁÎÎÏÇÏ..." #. CSTID_CALC_ERR_DIFF_PIX_VAL_PERC #: ../../strtbl.c:187 #, c-format msgid "Calculating error diffused pixel values: %1d%%" msgstr "" #. CSTID_CALC_NEW_PIX_1_VAL_PERC #: ../../strtbl.c:189 #, c-format msgid "Calculating new pixel values (pass 1): %1d%%" msgstr "" #. CSTID_CALC_NEW_PIX_2_VAL_PERC #: ../../strtbl.c:191 #, c-format msgid "Calculating new pixel values (pass 2): %1d%%" msgstr "" #. CSTID_DLG_ACCEPT_CONTINUE #: ../../strtbl.c:193 msgid "( <CR>: accept, <ESC>: continue )" msgstr "" #. CSTID_OPENING_GIVEN #: ../../strtbl.c:195 #, fuzzy, c-format msgid "Opening '%s'..." msgstr "ïÔËÒÙÔŰ..." #. CSTID_BACKGROUNDING_CMD #: ../../strtbl.c:197 #, c-format msgid "Backgrounding; '%s'." msgstr "" #. CSTID_CNTRL_C_TO_INTR_AND_ABEND #: ../../strtbl.c:199 msgid "Type ^C if you want to interrupt and end abnormally..." msgstr "" #. CSTID_MOVE_PINNED_MENU #: ../../strtbl.c:201 msgid "Move pinned menu" msgstr "" #. CSTID_CLOSE_PINNED_MENU #: ../../strtbl.c:203 msgid "Close pinned menu" msgstr "" #. CSTID_RELEASE_MOUSE_TO_PIN_MENU #: ../../strtbl.c:205 msgid "Release the mouse to pin down the menu" msgstr "" #. CSTID_LOCKED_OBJS_NOT_MOVED #: ../../strtbl.c:207 msgid "Locked objects are not moved." msgstr "" #. CSTID_SCROLL_DOWN_1_LINE #: ../../strtbl.c:209 msgid "scroll down 1 line" msgstr "" #. CSTID_SCROLL_AROUND #: ../../strtbl.c:211 #, fuzzy msgid "scroll around" msgstr "òĆÖÉÍ ĐÒÏËÒŐÔËÉ" #. CSTID_SCROLL_UP_1_LINE #: ../../strtbl.c:213 msgid "scroll up 1 line" msgstr "" #. CSTID_ENABLE_REDRAW #: ../../strtbl.c:215 msgid "enable redraw" msgstr "" #. CSTID_DISABLE_REDRAW #: ../../strtbl.c:217 #, fuzzy msgid "disable redraw" msgstr "đÏËÁÚÙŚÁÔŰ ÓĆÔËŐ" #. CSTID_GET_DIR_LIST_PLEASE_WAIT #: ../../strtbl.c:219 #, c-format msgid "Getting directory listing of '%s', please wait..." msgstr "" #. CSTID_ENTERING_HYPERSPACE #: ../../strtbl.c:221 #, fuzzy msgid "Entering hyperspace..." msgstr "śÈÏÄ Ś ÇÉĐĆÒĐÒÏÓÔÒÁÎÓÔŚÏ..." #. CSTID_GOTO #: ../../strtbl.c:223 msgid "Goto" msgstr "đĆÒĆÊÔÉ" #. CSTID_CLOSE #: ../../strtbl.c:227 msgid "Close" msgstr "úÁËÒÙÔŰ" #. CSTID_BAD_OVAL_BBOX_ADJ #: ../../strtbl.c:229 msgid "Bad oval bounding box. Adjusted." msgstr "" #. CSTID_SHIFT_ALL_TABS_RIGHT #: ../../strtbl.c:231 msgid "Shift All Tabs Right" msgstr "" #. CSTID_SHIFT_TABS_RIGHT #: ../../strtbl.c:233 msgid "Shift Tabs Right" msgstr "" #. CSTID_SHIFT_TABS_LEFT #: ../../strtbl.c:235 msgid "Shift Tabs Left" msgstr "" #. CSTID_SHIFT_ALL_TABS_LEFT #: ../../strtbl.c:241 msgid "Shift All Tabs Left" msgstr "" #. CSTID_SHIFT_10_TABS_RIGHT #: ../../strtbl.c:243 msgid "Shift 10 Tabs Right" msgstr "" #. CSTID_SHIFT_10_TABS_LEFT #: ../../strtbl.c:245 msgid "Shift 10 Tabs Left" msgstr "" #. CSTID_GOTO_GIVEN_PAGE #: ../../strtbl.c:249 #, fuzzy, c-format msgid "Goto page %1d" msgstr "đĆÒĆÊÔÉ ÎÁ..." #. CSTID_GOTO_GIVEN_PAGE_WITH_NAME #: ../../strtbl.c:251 #, c-format msgid "Goto page %1d: \"%s\"" msgstr "" #. CSTID_GRAYSTR_CALLED_WITH_IDX_2 #: ../../strtbl.c:253 msgid "Error: GrayStr() called with index <= 2." msgstr "" #. CSTID_GRAY_SCALE_USED_FOR_PAT #: ../../strtbl.c:255 msgid "Warning: Gray scales used instead of tiling patterns." msgstr "" #. CSTID_SET_FILL_TO_NONE #: ../../strtbl.c:257 #, fuzzy msgid "Set fill pattern to NONE" msgstr "őÓÔÁÎÏŚÉÔŰ ÔĆËŐĘÉÊ ĂŚĆÔ ÚÁĐÏÌÎĆÎÉŃ" #. CSTID_SET_FILL_TO_SOLID #: ../../strtbl.c:259 #, fuzzy msgid "Set fill pattern to SOLID" msgstr "őÓÔÁÎÏŚÉÔŰ ÔĆËŐĘÉÊ ĂŚĆÔ ÚÁĐÏÌÎĆÎÉŃ" #. CSTID_SET_FILL_TO_BACKGROUND #: ../../strtbl.c:261 msgid "Set fill pattern to BACKGROUND" msgstr "" #. CSTID_SET_FILL_TO_PAT_NUMBER #: ../../strtbl.c:263 #, c-format msgid "Set fill pattern to pattern #%1d" msgstr "" #. CSTID_SET_LINE_WIDTH_TO_GIVEN_S #: ../../strtbl.c:265 #, c-format msgid "Set line width to %s" msgstr "" #. CSTID_SET_PEN_DASH_PAT_NO_DASH #: ../../strtbl.c:267 msgid "Set dash pattern for the pen to be no dashes" msgstr "" #. CSTID_SET_PEN_DASH_PAT_PAT_NUM #: ../../strtbl.c:269 #, c-format msgid "Set dash pattern for the pen to dash pattern #%1d" msgstr "" #. CSTID_SET_PEN_TO_NONE #: ../../strtbl.c:271 msgid "Set pen to NONE" msgstr "" #. CSTID_SET_PEN_TO_SOLID #: ../../strtbl.c:273 msgid "Set pen to SOLID" msgstr "" #. CSTID_SET_PEN_TO_BACKGROUND #: ../../strtbl.c:275 msgid "Set pen to BACKGROUND" msgstr "" #. CSTID_SET_PEN_TO_PAT_NUM #: ../../strtbl.c:277 #, c-format msgid "Set pen to pattern #%1d" msgstr "" #. CSTID_SEL_A_PIN_ESC_TO_END_DOTS #: ../../strtbl.c:279 msgid "Please select a pin (or press <ESC> to end)..." msgstr "" #. CSTID_ADD_LAST_VERTEX #: ../../strtbl.c:281 msgid "Add last vertex" msgstr "" #. CSTID_SINGLE_PT_POLY_CONVERTED #: ../../strtbl.c:283 #, c-format msgid "Single point poly (%1d,%1d) converted to double point poly." msgstr "" #. CSTID_BAD_SMOOTHHINGE_POLY_FIXED #: ../../strtbl.c:285 msgid "Invalid poly smooth/hinge specification detected. Fixed." msgstr "" #. CSTID_CLOSE_POLYGON_SPLINE #: ../../strtbl.c:287 msgid "Close the polygon/spline" msgstr "" #. CSTID_SNGL_PT_POLYGON_CONVERTED #: ../../strtbl.c:289 #, c-format msgid "Single point polygon (%1d,%1d) converted to 3-point point polygon." msgstr "" #. CSTID_TWO_PT_POLYGON_CONVERTED #: ../../strtbl.c:291 #, c-format msgid "Two-point polygon [%1d,%1d,%1d,%1d] converted to 3-point point polygon." msgstr "" #. CSTID_FILEVER_TOO_LARGE_FOR_RCBOX #: ../../strtbl.c:293 #, c-format msgid "Invalid file version (=%1d) for rcbox." msgstr "" #. CSTID_BAD_RCBOX_BBOX_ADJUSTED #: ../../strtbl.c:295 msgid "Bad rcbox bounding box. Adjusted." msgstr "" #. CSTID_PARANED_SEC_ELAPSED_AVG_SPEED #: ../../strtbl.c:297 #, c-format msgid "(%1d sec elapsed, avg %.2fKB/sec)" msgstr "" #. CSTID_UNZIPPING_WITH_CMD_DOTS #: ../../strtbl.c:299 #, c-format msgid "Unzipping with '%s'..." msgstr "" #. CSTID_UNCOMPRESSING_WITH_CMD_DOTS #: ../../strtbl.c:301 #, c-format msgid "Uncompressing with '%s'..." msgstr "" #. CSTID_DATA_RECEIVED #: ../../strtbl.c:303 #, c-format msgid "%s: data received." msgstr "" #. CSTID_FORWARDING_URL_TO_URL #: ../../strtbl.c:305 #, c-format msgid "%s: forwarding '%s' to '%s'." msgstr "" #. CSTID_SCROLL_UP #: ../../strtbl.c:307 msgid "scroll up" msgstr "" #. CSTID_SCROLL_DOWN #: ../../strtbl.c:309 #, fuzzy msgid "scroll down" msgstr "òĆÖÉÍ ĐÒÏËÒŐÔËÉ" #. CSTID_SCROLL_PAGE_UP #: ../../strtbl.c:311 msgid "scroll page up" msgstr "" #. CSTID_SCROLL_PAGE_DOWN #: ../../strtbl.c:313 msgid "scroll page down" msgstr "" #. CSTID_SCROLL_VERTICALLY #: ../../strtbl.c:315 msgid "scroll vertically" msgstr "" #. CSTID_SCROLL_HORIZONTALLY #: ../../strtbl.c:317 #, fuzzy msgid "scroll horizontally" msgstr "đĆÒĆŚĆÒÎŐÔŰ ĐÏ ÇÏÒÉÚÏÎÔÁÌÉ" #. CSTID_SCROLL_LEFT #: ../../strtbl.c:319 #, fuzzy msgid "scroll left" msgstr "òĆÖÉÍ ĐÒÏËÒŐÔËÉ" #. CSTID_SCROLL_RIGHT #: ../../strtbl.c:321 #, fuzzy msgid "scroll right" msgstr "śÏÓÓÔÁÎÏŚÉÔŰ ĐÏÌÏÖĆÎÉĆ" #. CSTID_SCROLL_PAGE_LEFT #: ../../strtbl.c:323 msgid "scroll page left" msgstr "" #. CSTID_SCROLL_PAGE_RIGHT #: ../../strtbl.c:325 #, fuzzy msgid "scroll page right" msgstr "śÏÓÓÔÁÎÏŚÉÔŰ ĐÏÌÏÖĆÎÉĆ" #. CSTID_CANT_FIND_ATTR_WITH_COLOR #: ../../strtbl.c:327 #, c-format msgid "Cannot find the '%s' attribute with color %s." msgstr "" #. CSTID_CANT_FIND_FILEATTR_WITH_COLOR #: ../../strtbl.c:329 #, c-format msgid "Cannot find the '%s' file attribute with color %s." msgstr "" #. CSTID_CANT_FIND_NAMED_ATTR #: ../../strtbl.c:331 #, c-format msgid "Cannot find the '%s' attribute." msgstr "" #. CSTID_CANT_FIND_INTERPRETABLE_ATTR #: ../../strtbl.c:333 msgid "Cannot find interpretable attribute." msgstr "" #. CSTID_NO_ACTION_TAKEN #: ../../strtbl.c:335 msgid "No action taken." msgstr "" #. CSTID_FAIL_READ_ICONPXMP_USE_BMP #: ../../strtbl.c:337 #, c-format msgid "Fail to read IconPixmap file: '%s'. Default icon bitmap is used." msgstr "" #. CSTID_DRAG_MOUSE_CREATE_SHAPE_DOTS #: ../../strtbl.c:339 msgid "Drag the mouse to create a shape..." msgstr "" #. CSTID_CREATE_A_SHAPE_ABORTED #: ../../strtbl.c:341 msgid "Create a shape aborted." msgstr "" #. CSTID_INSTANTIATING_FILE_DOTS #: ../../strtbl.c:343 #, fuzzy, c-format msgid "Instantiating '%s'..." msgstr "úÁÇÒŐÚÉÔŰ ÓÉÍŚÏÌ ÉÚ ÏÂÌÁÓÔÉ..." #. CSTID_ATTR_PROMOTED_TO_NEW_SYMBOL #: ../../strtbl.c:345 msgid "Object's attributes are promoted to the new symbol object." msgstr "" #. CSTID_ATTR_PROMOTED_TO_NEW_ICON #: ../../strtbl.c:347 msgid "Object's attributes are promoted to the new icon object." msgstr "" #. CSTID_CREATING_FILE_DOTS #: ../../strtbl.c:349 #, c-format msgid "Creating '%s'..." msgstr "" #. CSTID_NAMED_FILE_CREATED #: ../../strtbl.c:351 #, c-format msgid "File '%s' created." msgstr "" #. CSTID_WRITING_ATTR_TO_NAMED_FILE #: ../../strtbl.c:353 #, fuzzy, c-format msgid "Writing attributes to '%s'..." msgstr "úÁĐÉÓŰ ÁÔÒÉÂŐÔÏŚ Ś '%s'..." #. CSTID_SEMICOLON_USED_AS_SEPARATOR #: ../../strtbl.c:355 msgid "';'s are used as separators." msgstr "óÉÍŚÏÌ `;' ÉÓĐÏÌŰÚŐĆÔÓŃ ËÁË ÒÁÚÄĆÌÉÔĆÌŰ." #. CSTID_TAB_USED_AS_SEPARATOR #: ../../strtbl.c:357 msgid "<TAB>s are used as separators." msgstr "óÉÍŚÏÌ ÔÁÂŐÌŃĂÉÉ ÉÓĐÏÌŰÚŐĆÔÓŃ ËÁË ÒÁÚÄĆÌÉÔĆÌŰ." #. CSTID_PROCESSING_OBJ_NUMBER #: ../../strtbl.c:359 #, c-format msgid "Processing object %1d..." msgstr "ïÂÒÁÂÏÔËÁ ÏÂßĆËÔÁ %1d..." #. CSTID_PLACING_NAMED_OBJ #: ../../strtbl.c:361 #, c-format msgid "Placing object '%s'..." msgstr "òÁÚÍĆĘĆÎÉĆ ÏÂßĆËÔÁ '%s'..." #. CSTID_WRITING_ATTRS_IN_TBL_FORM_TO #: ../../strtbl.c:363 #, c-format msgid "Writing attributes in table form to '%s'..." msgstr "úÁĐÉÓŰ ÁÔÒÉÂŐÔÏŚ Ś ÔÁÂÌÉȚÎÏÊ ÆÏÒÍĆ Ś '%s'..." #. CSTID_CORRUPTED_POLY_MKMULTISPLINE #: ../../strtbl.c:365 msgid "Corrupted poly in MakeMultiSplinePolyVertex()." msgstr "" #. CSTID_CORRUPTED_POLY_DMPMULTICURVE #: ../../strtbl.c:367 msgid "Corrupted poly in DumpMultiCurvedPolyPoints()." msgstr "" #. CSTID_FIX_ATTEMPTED #: ../../strtbl.c:369 msgid "Fix attempted." msgstr "" #. CSTID_PUSHING_INTO_NAMED #: ../../strtbl.c:371 #, c-format msgid "Pushing into '%s'..." msgstr "" #. CSTID_CUR_FILE_IS #: ../../strtbl.c:373 #, c-format msgid "Current file is '%s'." msgstr "ôĆËŐĘÉÊ ÆÁÊÌ: '%s'." #. CSTID_DONT_KNOW_HOW_HANDLE_FRAME_CT #: ../../strtbl.c:375 #, c-format msgid "Does not know how to handle frame Content-Type: %s." msgstr "" #. CSTID_CANT_FIND_OBJ_NAME_ON_RESIZE #: ../../strtbl.c:377 #, c-format msgid "Cannot find object named '%s' any more; on_resize script not invoked." msgstr "" #. CSTID_PASTING_LINE_NUM_DOTS #: ../../strtbl.c:379 #, c-format msgid "Pasting line %1d..." msgstr "" #. CSTID_CANT_PASTE_DEL #: ../../strtbl.c:381 msgid "Cannot paste <DEL>." msgstr "" #. CSTID_CANT_PASTE_BS #: ../../strtbl.c:383 msgid "Cannot paste <BS>." msgstr "" #. CSTID_CANT_PASTE_ESC #: ../../strtbl.c:385 msgid "Cannot paste <ESC>." msgstr "" #. CSTID_CANT_PASTE_TAB_REPLACE_BY_SPC #: ../../strtbl.c:387 msgid "Cannot paste <TAB>, replaced by <SPACE>." msgstr "" #. CSTID_READING_FILE_DOTS #: ../../strtbl.c:389 #, c-format msgid "Reading '%s'..." msgstr "țÉÔÁĆÔÓŃ '%s'..." #. CSTID_RETURNED_FROM_BASIC_DRIVER #: ../../strtbl.c:391 msgid "Returned from basic driver." msgstr "" #. CSTID_CACHING_BITMAP #: ../../strtbl.c:393 #, fuzzy msgid "Caching bitmap..." msgstr "đÏÍĆÎŃÔŰ ÏÂÌÁÓÔŰ..." #. CSTID_FINISHED_CACHEING_BITMAP #: ../../strtbl.c:395 msgid "Finishing caching bitmap..." msgstr "" #. CSTID_NEW_BMP_SIZE_IS_W_X_H #: ../../strtbl.c:397 #, c-format msgid "New bitmap size is %1dx%1d." msgstr "" #. CSTID_BLD_COLOR_TBL_FROM_PIXEL_DOTS #: ../../strtbl.c:399 msgid "Building color table from pixels..." msgstr "" #. CSTID_GENERATING_IMAGEMAP_FILE_DOTS #: ../../strtbl.c:401 msgid "Generating imagemap file..." msgstr "" #. CSTID_GENERATING_HTML_FILE_DOTS #: ../../strtbl.c:403 msgid "Generating HTML file..." msgstr "" #. CSTID_GENERATING_IMAGE #: ../../strtbl.c:405 #, fuzzy msgid "Generating image..." msgstr "đÏÓÔÒÏÉÔŰ ĐÏ ËÒÁŃÍ" #. CSTID_FS_HALFTONE_BMP_THRESH_DOTS #: ../../strtbl.c:407 #, c-format msgid "FS halftone bitmap (threshold=%s)..." msgstr "" #. CSTID_THRESHOLD_BMP_THRESH_DOTS #: ../../strtbl.c:409 #, c-format msgid "Threshold bitmap (threshold=%s)..." msgstr "" #. CSTID_INVALID_FILEVER_FOR_XBM #: ../../strtbl.c:411 #, c-format msgid "Invalid file version (%1d) for X11 Bitmap objects." msgstr "" #. CSTID_FIELD_TOO_LONG_IN_OBJ_TRUNC #: ../../strtbl.c:413 #, c-format msgid "%s, %d: %s field too long in %s object. Truncated" msgstr "" #. CSTID_FILE_LINE_BAD_FLD_IN_OBJ_STR #: ../../strtbl.c:415 #, c-format msgid "%s, %d: Bad %s in %s object [%s]." msgstr "" #. CSTID_MALFORMED_LINE_NUM_IN_FILE #: ../../strtbl.c:417 #, c-format msgid "Malformed line %1d in '%s'." msgstr "" #. CSTID_CACHING_PIXMAP #: ../../strtbl.c:419 #, fuzzy msgid "Caching pixmap..." msgstr "đÏÍĆÎŃÔŰ ÏÂÌÁÓÔŰ..." #. CSTID_FINISHED_CACHEING_PIXMAP #: ../../strtbl.c:421 msgid "Finishing caching pixmap..." msgstr "" #. CSTID_NEW_XPM_SIZE_IS_W_X_H #: ../../strtbl.c:423 #, c-format msgid "New pixmap size is %1dx%1d." msgstr "" #. CSTID_MANY_COLORS_GT_255_SKIP_XPM #: ../../strtbl.c:425 #, c-format msgid "" "Too many colors (%1d, which is > 255) in an xpm objects. This object is " "skipped during printing." msgstr "" #. CSTID_GIVEN_ADDTNL_COLOR_ALLOCATED #: ../../strtbl.c:427 #, c-format msgid "%1d additional color(s) allocated." msgstr "äÏĐÏÌÎÉÔĆÌŰÎÏ ÒÁÓĐÒĆÄĆÌĆÎÏ ĂŚĆÔÏŚ: %1d." #. CSTID_INVALID_FILEVER_FOR_XPM #: ../../strtbl.c:429 #, c-format msgid "Invalid file version (%1d) for X11 Pixmap objects." msgstr "" #. CSTID_COLOR_SUBS_FOR_UNRECOG_IN_XPM #: ../../strtbl.c:431 #, c-format msgid "'%s' is substituted for unrecognized colors in an X11 Pixmap object." msgstr "" #. CSTID_CONTEXT_MENU #: ../../strtbl.c:433 msgid "Context Menu" msgstr "ëÏÎÔĆËÓÔÎÏĆ ÍĆÎÀ" #. CSTID_GEN_TEMPLATE_HTML_FILE_DOT #: ../../strtbl.c:435 #, c-format msgid "Generating HTML file through '%s' template..." msgstr "çĆÎĆÒÁĂÉŃ HTML ÆÁÊÌÁ Ó ĐÏÍÏĘŰÀ ÛÁÂÌÏÎÁ '%s'..." #. CSTID_SCALING_EVERYTHING_PAGE #: ../../strtbl.c:437 #, c-format msgid "Scaling everything for page %1d of %1d..." msgstr "" #. CSTID_SQUARE_BRACK_MODIFIED #: ../../strtbl.c:439 msgid "[Modified]" msgstr "[íÏÄÉÆÉĂÉÒÏŚÁÎ]" #. CSTID_SQUARE_BRACK_MODIFIED_UNSAV #: ../../strtbl.c:445 msgid "[Modified/Unsavable]" msgstr "[íÏÄÉÆÉĂÉÒÏŚÁÎ/ÎĆÓÏÈÒÁÎŃĆÍ]" #. CSTID_SQUARE_BRACK_UNNAMED #: ../../strtbl.c:447 msgid "[Unnamed]" msgstr "[âĆÚ ÉÍĆÎÉ]" #. CSTID_PARANED_EMPTY #: ../../strtbl.c:449 msgid "(Empty)" msgstr "" #. CSTID_OPEN_FILE #: ../../strtbl.c:451 #, c-format msgid "Open '%s'" msgstr "" #. CSTID_GRID_MENU #: ../../strtbl.c:457 msgid "Grid menu" msgstr "" #. CSTID_MOVE_EDIT_TEXT_BOX #: ../../strtbl.c:459 msgid "Move edit text box" msgstr "" #. CSTID_START_MOVE_EDIT_TEXT_BOX #: ../../strtbl.c:461 msgid "Start moving the edit text box" msgstr "" #. CSTID_EDIT_ATTR_IN_EDITOR #: ../../strtbl.c:463 #, c-format msgid "Edit the value of the '%s' attribute in a text editor" msgstr "" #. CSTID_GET_NAMED_PROP_FROM_SEL_OBJ #: ../../strtbl.c:465 #, c-format msgid "Get the current '%s' property from the selected object" msgstr "" #. CSTID_START_AN_EDGE_FROM_A_PORT #: ../../strtbl.c:467 msgid "start an edge from a port" msgstr "" #. CSTID_ABORT #: ../../strtbl.c:469 msgid "abort" msgstr "" #. CSTID_START_A_WIRE_FROM_NAMED_PORT #: ../../strtbl.c:471 #, c-format msgid "Start a wire from port '%s'... (Btn2 or Btn3 to abort)" msgstr "" #. CSTID_END_A_WIRE_AT_NAMED_PORT #: ../../strtbl.c:473 #, c-format msgid "End the wire at port '%s'... (press <ESC> to abort)" msgstr "" #. CSTID_SET_SIGNAME_FOR_NAMED_PORT #: ../../strtbl.c:475 #, c-format msgid "Set signal name (currently '%s') for port '%s'..." msgstr "" #. CSTID_CLK_ON_PORT_TO_RENAME_SIGNAME #: ../../strtbl.c:477 msgid "Please click on a port to rename its signal name..." msgstr "" #. CSTID_CLK_ON_PORT_TO_CLEAR_SIGNAME #: ../../strtbl.c:479 msgid "Please click on a port to clear its signal name..." msgstr "" #. CSTID_PORTNAME_TOO_LONG_SKIPPED #: ../../strtbl.c:481 #, c-format msgid "Port/pin name '%s...' too long. It is skipped in net-list generation." msgstr "" #. CSTID_CLEAR_SIGNAME_FOR_NAMED_PORT #: ../../strtbl.c:483 #, c-format msgid "Clear signal name (currently '%s') for port '%s'..." msgstr "" #. STID_CANNOT_LOAD_FONTSET #: ../../strtbl.c:532 #, c-format msgid "Cannot load fontset specified by %s.%s: '%s'." msgstr "" #. STID_CANNOT_LOAD_FONT #: ../../strtbl.c:534 #, c-format msgid "Cannot load font specified by %s.%s: '%s'." msgstr "" #. STID_CANNOT_DISTRIBUTE_LOCKED_OBJS #: ../../strtbl.c:536 msgid "Cannot distribute with locked objects." msgstr "" #. STID_VERTICES_HORI_APART #: ../../strtbl.c:538 #, c-format msgid "Vertices are %1d pixels apart horizontally." msgstr "" #. STID_VERTICES_VERT_APART #: ../../strtbl.c:540 #, c-format msgid "Vertices are %1d pixels apart vertically." msgstr "" #. STID_LEFT_SIDES_APART #: ../../strtbl.c:542 #, c-format msgid "Left sides of objects are %1d pixels apart." msgstr "" #. STID_CENTERS_APART #: ../../strtbl.c:544 #, c-format msgid "Center of objects are %1d pixels apart." msgstr "" #. STID_RIGHT_SIDES_APART #: ../../strtbl.c:546 #, c-format msgid "Right sides of objects are %1d pixels apart." msgstr "" #. STID_SPACED_APART_HORI #: ../../strtbl.c:548 #, c-format msgid "Objects are spaced %1d pixels apart horizontally." msgstr "" #. STID_TOP_SIDES_APART #: ../../strtbl.c:550 #, c-format msgid "Top sides of objects are %1d pixels apart." msgstr "" #. STID_MIDDLES_APART #: ../../strtbl.c:552 #, c-format msgid "Middles of objects are %1d pixels apart." msgstr "" #. STID_BOTTOM_SIDES_APART #: ../../strtbl.c:554 #, c-format msgid "Bottom sides of objects are %1d pixels apart." msgstr "" #. STID_SPACED_APART_VERT #: ../../strtbl.c:556 #, c-format msgid "Objects are spaced %1d pixels apart vertically." msgstr "" #. STID_DISTR_VERTEX_HORI #: ../../strtbl.c:558 msgid "" "Distribute selected vertices so that they are spaced equally horizontally" msgstr "" #. STID_DISTR_VERTEX_VERT #: ../../strtbl.c:560 msgid "Distribute selected vertices so that they are spaced equally vertically" msgstr "" #. STID_DISTR_VERTEX_VERT_AND_HORI #: ../../strtbl.c:562 msgid "" "Distribute selected vertices so that they are spaced equally horizontally " "and vertically" msgstr "" #. STID_MOVE_ALL_VERTICES_YNC #: ../../strtbl.c:564 msgid "Okay to move all vertices to one point? [ync](y)" msgstr "" #. STID_CANNOT_ALIGN_OBJS_TOO_MANY #: ../../strtbl.c:566 msgid "Cannot align objects. Too many objects locked." msgstr "" #. STID_ALIGN_VERTICES_HORI_TO_GRID #: ../../strtbl.c:568 msgid "Align selected vertices horizontally to the grid" msgstr "" #. STID_ALIGN_VERTICES_VERT_TO_GRID #: ../../strtbl.c:570 msgid "Align selected vertices vertically to the grid" msgstr "" #. STID_ALIGN_VERTICES_HORI #: ../../strtbl.c:572 msgid "Align selected vertices horizontally" msgstr "" #. STID_ALIGN_VERTICES_VERT #: ../../strtbl.c:574 msgid "Align selected vertices vertically" msgstr "" #. STID_ALIGN_VERTICES_TO_GRID #: ../../strtbl.c:576 msgid "Align selected vertices to the grid" msgstr "" #. STID_ALIGN_VERTICES #: ../../strtbl.c:578 #, fuzzy msgid "Align selected vertices" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #. STID_SELECT_ONE_POLY_ONE_NON_POLY #: ../../strtbl.c:580 msgid "Please select one polyline and one non-polyline object." msgstr "" #. STID_CANNOT_MOVE_A_VERTEX_LOCKED #: ../../strtbl.c:582 msgid "Cannot move a vertex for a locked polyline object." msgstr "" #. STID_SELECT_ONLY_ONE_POLY #: ../../strtbl.c:584 msgid "Please select only one POLY object." msgstr "" #. STID_NO_ARC_CREATED #: ../../strtbl.c:586 msgid "No arc created." msgstr "" #. STID_INVALID_ARC_VERSION #: ../../strtbl.c:588 #, c-format msgid "Invalid arc version (%1d)." msgstr "" #. STID_WARN_INCONSIST_ARC_DIR #: ../../strtbl.c:590 msgid "Warning: Inconsistent arc direction. Corrected." msgstr "" #. STID_ARC_SPEC #: ../../strtbl.c:592 msgid "Please enter an arc specification: [radius,dir(+/-),theta1,theta2]" msgstr "" #. STID_INVALID_ARC_SPEC_RADIUS #: ../../strtbl.c:594 #, c-format msgid "Invalid radius in arc specification '%s'." msgstr "" #. STID_INVALID_ARC_SPEC_DIR #: ../../strtbl.c:596 #, c-format msgid "Invalid direction in arc specification '%s'." msgstr "" #. STID_INVALID_ARC_SPEC_THETA1 #: ../../strtbl.c:598 #, c-format msgid "Invalid theta1 in arc specification '%s'." msgstr "" #. STID_SELECT_AT_LEAST_ONE_TEXT #: ../../strtbl.c:600 msgid "Must select at least one text object." msgstr "" #. STID_MORE_THAN_ONE_NON_TEXT #: ../../strtbl.c:602 msgid "More than one non-text objects selected." msgstr "" #. STID_NO_TEXT_SELECTED_ADD_ATTRS #: ../../strtbl.c:604 msgid "No text objects selected to add as attributes." msgstr "" #. STID_NO_NON_TEXT_SELECTED #: ../../strtbl.c:606 msgid "No objects (other than TEXT objects) selected." msgstr "" #. STID_TEXT_ATTACHED #: ../../strtbl.c:608 msgid "Text object(s) attached." msgstr "" #. STID_TEXT_UNLOCKED_AND_ATTACHED #: ../../strtbl.c:610 msgid "Text object(s) unlocked and attached." msgstr "" #. STID_UNEXPECTED_EOF_IN_ABORT_READ #: ../../strtbl.c:612 #, c-format msgid "%s, %d: Unexpected EOF in %s. Read aborted." msgstr "%s, %d: îĆÏÖÉÄÁÎÎÙÊ ËÏÎĆĂ ÆÁÊÌÁ Ś %s. țÔĆÎÉĆ ĐÒĆÒŚÁÎÏ." #. STID_STRING_LEN_EXCEEDS_AND_TRUNC #: ../../strtbl.c:614 #, c-format msgid "String length exceeds %1d. String is truncated." msgstr "äÌÉÎÎÁ ÓÔÒÏËÉ ĐÒĆŚÙÛÁĆÔ %1d. óÔÒÏËÁ ŐÓĆȚĆÎÁ." #. STID_MOVE_ONE_ATTR_MOUSE_MSG #: ../../strtbl.c:616 msgid "LEFT--show and move. MIDDLE--toggle name shown. RIGHT--hide attr." msgstr "" #. STID_CANNOT_MOVE_ATTR_IF_LOCKED #: ../../strtbl.c:618 msgid "Cannot move attributes of locked object." msgstr "" #. STID_SHOW_MOVE_ATTR #: ../../strtbl.c:620 #, fuzzy msgid "Show/move an attribute" msgstr "đÏËÁÚÁÔŰ ÁÔÒÉÂŐÔÙ" #. STID_TOGGLE_NAME_SHOWN #: ../../strtbl.c:622 msgid "Toggle name shown" msgstr "đĆÒĆËÌÀȚÉÔŰ ĐÏËÁÚ ÉÍĆÎ" #. STID_HIDE_ATTR #: ../../strtbl.c:624 msgid "Hide an attribute" msgstr "óËÒÙÔŰ ÁÔÒÉÂŐÔ" #. STID_CHANGE_ATTR_JUST_MOUSE_MSG #: ../../strtbl.c:626 msgid "LEFT--left justify. MIDDLE--center justify. RIGHT--right justify." msgstr "" #. STID_LEFT_JUSTIFY #: ../../strtbl.c:628 #, fuzzy msgid "Left justify an attribute" msgstr "đĆÒĆÍĆÓÔÉÔŰ/śÙÒÏŚÎŃÔŰ ÁÔÒÉÂŐÔÙ" #. STID_CENTER_JUSTIFY #: ../../strtbl.c:630 #, fuzzy msgid "Center justify an attribute" msgstr "đĆÒĆÍĆÓÔÉÔŰ/śÙÒÏŚÎŃÔŰ ÁÔÒÉÂŐÔÙ" #. STID_RIGHT_JUSTIFY #: ../../strtbl.c:632 #, fuzzy msgid "Right justify an attribute" msgstr "đĆÒĆÍĆÓÔÉÔŰ/śÙÒÏŚÎŃÔŰ ÁÔÒÉÂŐÔÙ" #. STID_SELECT_ONLY_ONE_OBJ #: ../../strtbl.c:634 msgid "Please select only ONE object." msgstr "" #. STID_SELECT_HAS_NO_ATTR #: ../../strtbl.c:636 msgid "Selected object currently has NO attributes." msgstr "" #. STID_DRAG_LEFT_BTN_TO_SEE_ATTR #: ../../strtbl.c:638 msgid "Drag left button to see attributes." msgstr "" #. STID_CHANGE_ATTR_JUST #: ../../strtbl.c:640 msgid "Change an attribute justification" msgstr "" #. STID_IS_ATTR_OBSOLETE_FOR_ICON_YNC #: ../../strtbl.c:642 #, c-format msgid "Is the attribute '%s' obsolete for icon '%s'? [yn](y)" msgstr "" #. STID_BAD_FORMAT_IN_SHORTCUT_SPEC #: ../../strtbl.c:644 msgid "Invalid format in shortcut specification." msgstr "" #. STID_CANNOT_FIND_NAMED_ATTR #: ../../strtbl.c:646 #, c-format msgid "Cannot find a '%s' attribute for the selected object." msgstr "îĆ ŐÄÁÌÏÓŰ ÎÁÊÔÉ ÁÔÒÉÂŐÔ '%s' ÄÌŃ ŚÙÄĆÌĆÎÎÏÇÏ ÏÂßĆËÔÁ." #. STID_ATTACH_FILE_ATTRS_IN_WB #: ../../strtbl.c:648 msgid "AttachFileAttrs() is disabled in WhiteBoard mode." msgstr "" #. STID_CANNOT_ATTACH_NON_TEXT_OBJ #: ../../strtbl.c:650 msgid "Cannot attach non-text objects." msgstr "" #. STID_DETACH_FILE_ATTRS_IN_WB #: ../../strtbl.c:652 msgid "DetachFileAttrs() is disabled in WhiteBoard mode." msgstr "" #. STID_FILE_CONTAINS_NO_ATTRS #: ../../strtbl.c:654 msgid "Current file contains no attributes." msgstr "ôĆËŐĘÉÊ ÆÁÊÌ ÎĆ ÓÏÄĆÒÖÉÔ ÁÔÒÉÂŐÔÏŚ." #. STID_SHOW_ATTR_NAME_AND_VALUE #: ../../strtbl.c:656 #, c-format msgid "Will show both the name and the value for the '%s' attribute." msgstr "đÏËÁÚÙŚÁÔŰ É ÉÍŃ É ÚÎÁȚĆÎÉĆ ÄÌŃ ÁÔÒÉÂŐÔÁ '%s'." #. STID_SHOW_ATTR_VALUE_ONLY #: ../../strtbl.c:658 #, c-format msgid "Will only show the value of the '%s' attribute." msgstr "đÏËÁÚÙŚÁÔŰ ÔÏÌŰËÏ ÚÎÁȚĆÎÉĆ ÁÔÒÉÂŐÔÁ '%s'." #. STID_NOT_SHOW_ATTR #: ../../strtbl.c:660 #, c-format msgid "Will not show the '%s' attribute." msgstr "îĆ ĐÏËÁÚÙŚÁÔŰ ÁÔÒÉÂŐÔ '%s'." #. STID_SHOW_ATTR #: ../../strtbl.c:662 #, c-format msgid "Will show the '%s' attribute." msgstr "đÏËÁÚÙŚÁÔŰ ÁÔÒÉÂŐÔ '%s'." #. STID_WONT_SHOW_VALUE #: ../../strtbl.c:664 #, c-format msgid "Will not show the '%s' value." msgstr "îĆ ĐÏËÁÚÙŚÁÔŰ ÚÎÁȚĆÎÉĆ '%s'." #. STID_TGIF_EDIT_ATTR_NAMES #: ../../strtbl.c:666 #, c-format msgid "%s - Edit Attribute Names" msgstr "%s - đÒÁŚËÁ ÉÍĆÎ ÁÔÒÉÂŐÔÏŚ" #. STID_EDIT_FILE_ATTRS_IN_WB #: ../../strtbl.c:668 msgid "EditFileAttrs() is disabled in WhiteBoard mode." msgstr "" #. STID_FILE_ATTRS_UPDATED #: ../../strtbl.c:672 #, fuzzy msgid "File attribute(s) updated." msgstr "æÁÊÌ ÁÔÒÉÂŐÔÏŚ" #. STID_SELECT_ONE_OBJ_FOR_EDITATTRS #: ../../strtbl.c:674 msgid "Must select only one object for EditAttrs()." msgstr "" #. STID_OBJ_CONTAINS_NO_ATTRS #: ../../strtbl.c:676 msgid "Selected object contains no attributes." msgstr "" #. STID_EDIT_OBJ_ATTRS_DOTS #: ../../strtbl.c:678 msgid "Edit Object Attributes (show/hide, name shown)..." msgstr "đÒÁŚËÁ ÁÔÒÉÂŐÔÏŚ ÏÂßĆËÔÁ (ĐÏËÁÚÁÔŰ/ÓËÒÙÔŰ, ĐÏËÁÚ ÉÍĆÎÉ)..." #. STID_OBJ_ATTRS_UPDATED #: ../../strtbl.c:680 msgid "Object attribute(s) updated." msgstr "áÔÒÉÂŐÔ(Ù) ÏÂßĆËÔÁ ÏÂÎÏŚÌĆÎÙ." #. STID_INPUT_OCTAL_STR #: ../../strtbl.c:682 #, c-format msgid "Please input an octal string (e.g., \"%s\"):" msgstr "śŚĆÄÉÔĆ ŚÏÓŰÍĆÒÉȚÎŐÀ ÓÔÒÏËŐ (ÎÁĐÒÉÍĆÒ, \"%s\"):" #. STID_INPUT_STR #: ../../strtbl.c:684 msgid "Please input a string:" msgstr "śŚĆÄÉÔĆ ÓÔÒÏËŐ:" #. STID_WARN_PRINT_COURIER_IN_COLOR #: ../../strtbl.c:686 msgid "Warning: Printing Courier fonts with non-solid pen in color." msgstr "" #. STID_MAY_CAUSE_ERROR_IN_PRINTOUT #: ../../strtbl.c:688 msgid " This may cause error in the printout." msgstr "" #. STID_BAD_OCTAL_STRING_ENCOUNTERED #: ../../strtbl.c:690 #, c-format msgid "Bad octal string \\%c%c%c encountered." msgstr "" #. STID_SERVER_NOT_STARTED #: ../../strtbl.c:692 msgid "Server not started." msgstr "óĆÒŚĆÒ ÎĆ ÚÁĐŐĘĆÎ." #. STID_INVISIBLE_COLOR_SELECTED_YNC #: ../../strtbl.c:694 #, c-format msgid "" "Invisible color #%1d (%s) is selected for drawing.\n" "\n" "Would you like to make the color visible?" msgstr "" "äÌŃ ÒÉÓÏŚÁÎÉŃ ŚÙÂÒÁÎ ÎĆŚÉÄÉÍÙÊ ĂŚĆÔ #%1d (%s).\n" "\n" "èÏÔÉÔĆ ÓÄĆÌÁÔŰ ÜÔÏÔ ĂŚĆÔ ŚÉÄÉÍÙÍ?" #. STID_COLOR_IS_CURRENTLY_INVISIBLE #: ../../strtbl.c:696 #, c-format msgid "Color %1d (%s) is currently invisible." msgstr "ăŚĆÔ %1d (%s) ÎÁ ÔĆËŐĘÉÊ ÍÏÍĆÎÔ ÎĆŚÉÄÉÍ." #. STID_COLOR_SET_TO #: ../../strtbl.c:698 #, c-format msgid "Color set to '%s'." msgstr "ăŚĆÔ ŐÓÔÁÎÏŚÌĆÎ Ś '%s'." #. STID_TEXT_VSPACE_TOO_SMALL_RESET_0 #: ../../strtbl.c:700 msgid "" "Text vertical spacing too small.\n" "\n" "It is reset to 0." msgstr "" #. STID_FONT_AND_SIZE_NOT_AVAILABLE #: ../../strtbl.c:702 #, c-format msgid "%s-%1d not available." msgstr "" #. STID_LINE_WIDTH_SET_TO #: ../../strtbl.c:704 ../../strtbl.c:2518 #, c-format msgid "Line width set to %s." msgstr "" #. STID_LINE_TYPE_IS_STRAIGHT #: ../../strtbl.c:706 msgid "Line type is 'straight'." msgstr "" #. STID_LINE_TYPE_IS_SPLINE #: ../../strtbl.c:708 msgid "Line type is 'spline'." msgstr "" #. STID_LINE_TYPE_IS_INTSPLINE #: ../../strtbl.c:710 #, fuzzy msgid "Line type is 'interpolated spline'." msgstr "đÒĆÏÂÒÁÚÏŚÁÔŰ Ś ÓĐÌÁÊÎ" #. STID_TAB_FOR_FILE_COMPLETION #: ../../strtbl.c:712 msgid "Type <TAB> for file completion..." msgstr "" #. STID_FAIL_TO_CREATE_WINDOW #: ../../strtbl.c:714 msgid "Fail to create a window." msgstr "" #. STID_FAIL_TO_CREATE_NAMED_WINDOW #: ../../strtbl.c:716 #, c-format msgid "Fail to create the %s window." msgstr "" #. STID_UNDO_REDO_MAY_CAUSE_CRASH #: ../../strtbl.c:718 msgid "Further Undo()/Redo() may cause crashes." msgstr "" #. STID_UNDO_IN_WB #: ../../strtbl.c:720 msgid "Undo() is disabled in WhiteBoard mode." msgstr "" #. STID_NO_COMMANDS_TO_UNDO #: ../../strtbl.c:722 msgid "No commands to Undo." msgstr "îĆÔ ËÏÍÁÎÄ ÄÌŃ ÏÔËÁÔÁ." #. STID_REDO_IN_WB #: ../../strtbl.c:724 msgid "Redo() is disabled in WhiteBoard mode." msgstr "" #. STID_NO_COMMANDS_TO_REDO #: ../../strtbl.c:726 msgid "No commands to Redo." msgstr "îĆÔ ËÏÍÁÎÄ ÄÌŃ ŚÏÚŚÒÁÔÁ." #. STID_SELECT_LIST_NOT_SORTED_IN #: ../../strtbl.c:728 #, c-format msgid "Select list not sorted in %s." msgstr "" #. STID_WARN_CANNOT_PARSE_NAMED_COLOR #: ../../strtbl.c:730 #, c-format msgid "Warning: Cannot parse color '%s'." msgstr "đÒĆÄŐĐÒĆÖÄĆÎÉĆ: ÎĆ ŐÄÁÌÏÓŰ ÒÁÚÏÂÒÁÔŰ ĂŚĆÔ '%s'." #. STID_CANNOT_ALLOC_NAMED_COLOR #: ../../strtbl.c:736 #, c-format msgid "Warning: Cannot allocate color '%s'." msgstr "đÒĆÄŐĐÒĆÖÄĆÎÉĆ: ÎĆ ŐÄÁÌÏÓŰ ÒÁÓĐÒĆÄĆÌÉÔŰ ĂŚĆÔ '%s'." #. STID_CANNOT_BREAKUP_EPS #: ../../strtbl.c:738 msgid "Cannot break up an EPS object." msgstr "" #. STID_INVALID_FILE_IN_X_DEFAULT #: ../../strtbl.c:740 #, c-format msgid "Invalid file '%s' specified by X default %s.%s." msgstr "" #. STID_INVALID_XDEF_COLORXPM_GET #: ../../strtbl.c:742 #, c-format msgid "Invalid %s.%s: '%s' - Fail to get colors. Resource ignored." msgstr "" #. STID_INVALID_XDEF_COLORXPM_TRANS #: ../../strtbl.c:744 #, c-format msgid "" "Invalid %s.%s: '%s' - Transparent color is not allowed. Resource ignored." msgstr "" #. STID_FAIL_ALLOC_EDIT_TEXT_BGCOLOR #: ../../strtbl.c:746 #, c-format msgid "" "Fail to allocate the '%s' background color for use in editing existing text " "objects." msgstr "" #. STID_FAIL_ALLOC_EDIT_TEXT_HICOLOR #: ../../strtbl.c:748 #, c-format msgid "" "Fail to allocate the '%s' highlight color for use in editing existing text " "objects" msgstr "" #. STID_FAIL_ALLOC_DEF_BGCOLOR #: ../../strtbl.c:750 #, c-format msgid "Fail to allocate the default background color: '%s'." msgstr "" #. STID_INVALID_XDEF_USE_ALT_VALUE #: ../../strtbl.c:752 #, c-format msgid "Invalid %s.%s: '%s', %1d is used instead." msgstr "" #. STID_NORM_VIDEO_MODE_ASSUMED #: ../../strtbl.c:754 #, c-format msgid "Normal video mode assumed since %s is specified in the command line." msgstr "" #. STID_ZERO_COLORS_SPECIFIED #: ../../strtbl.c:756 msgid "0 colors specified (must be at least 1)." msgstr "" #. STID_CANNOT_GET_X_DEFAULT #: ../../strtbl.c:758 #, c-format msgid "Cannot get X default %s.%s." msgstr "" #. STID_INVALID_XDEF_WILL_TRY_STR #: ../../strtbl.c:760 #, c-format msgid "Invalid %s.%s: '%s'. Will try '%s'." msgstr "" #. STID_FAIL_TO_ALLOC_3D_COLORS #: ../../strtbl.c:762 msgid "Fail to allocate colors for 3DLook." msgstr "" #. STID_FAIL_TO_ALLOC_COLOR_NUM #: ../../strtbl.c:764 #, c-format msgid "Fail to allocate color number %1d: '%s'. %s is aborted." msgstr "" #. STID_DEFCOLORINDEX_GE_MAXCOLORS #: ../../strtbl.c:766 #, c-format msgid "Warning: %s.%s >= %s.%s. Use 0 for %s.%s." msgstr "" #. STID_FAIL_ALLOC_NAMED_COLOR_ABORT #: ../../strtbl.c:768 #, c-format msgid "Fail to allocate the '%s' color. Abort." msgstr "" #. STID_FAIL_ALLOC_COLOR_NUM_ABORT #: ../../strtbl.c:770 #, c-format msgid "Fail to allocate color number %1d: '%s'. Abort." msgstr "" #. STID_UNEXPECTED_MAX_RGB_ZERO #: ../../strtbl.c:772 msgid "Warning: Unexpected maximum RGB intensity of 0." msgstr "" #. STID_FG_BG_SAME_COLOR_WARNING #: ../../strtbl.c:774 msgid "" "Warning: Foreground and background colors are the same. You may not be able " "to see much." msgstr "" #. STID_CANNOT_SET_FG_COLOR #: ../../strtbl.c:776 #, c-format msgid "" "Warning: Cannot set the foreground color to '%s'. The default color '%s' is " "used." msgstr "" #. STID_INVISIBLE_COLOR_SELECTED #: ../../strtbl.c:778 #, c-format msgid "Invisible color #%1d (%s) is selected for drawing." msgstr "" #. STID_ALL_COLOR_LAYERS_VISIBLE #: ../../strtbl.c:780 msgid "All color layers are now visible." msgstr "" #. STID_ALL_COLOR_LAYERS_INVISIBLE #: ../../strtbl.c:782 msgid "All color layers are now invisible." msgstr "" #. STID_A_COLOR_LAYER_TURNED_ON #: ../../strtbl.c:784 #, c-format msgid "Color '%s' (layer %1d) is turned on." msgstr "" #. STID_A_COLOR_LAYER_TURNED_OFF #: ../../strtbl.c:786 #, c-format msgid "Color '%s' (layer %1d) is turned off." msgstr "" #. STID_TURN_COLOR_LAYER_NUM_ON #: ../../strtbl.c:788 #, c-format msgid "Turn color '%s' (layer %1d) on" msgstr "" #. STID_TURN_COLOR_LAYER_NUM_OFF #: ../../strtbl.c:790 #, c-format msgid "Turn color '%s' (layer %1d) off" msgstr "" #. STID_COLORMAP_NOT_RESETED #: ../../strtbl.c:792 msgid "Colormap not reseted due to the DONT_FREE_COLORMAP compile flag." msgstr "" #. STID_ADDCOLOR_FOR_BW_DPY #: ../../strtbl.c:794 msgid "Adding color is not available for a black and white display." msgstr "" #. STID_ENTER_COLORS_TO_ADD #: ../../strtbl.c:796 msgid "Please enter colors to add:" msgstr "" #. STID_FAIL_ALLOC_NAMED_COLOR #: ../../strtbl.c:798 #, c-format msgid "Fail to allocate the '%s' color." msgstr "" #. STID_ENTER_EDIT_BG_COLOR #: ../../strtbl.c:800 #, c-format msgid "" "Please enter the background color to be used in editing existing a text " "object when UseAltEditTextBgColor is selected (please enter 'NONE' to " "remove): [current - %s]" msgstr "" #. STID_ENTER_EDIT_HILIGHT_COLOR #: ../../strtbl.c:802 #, c-format msgid "" "Please enter the highlight color to be used in editing existing a text " "object when UseAltEditTextBgColor is selected (please enter 'NONE' to " "remove): [current - %s]" msgstr "" #. STID_COLOR_LAYERS_ENABLED #: ../../strtbl.c:804 msgid "Color layers enabled." msgstr "ăŚĆÔÏŚÙĆ ÓÌÏÉ ÒÁÚÒĆÛĆÎÙ." #. STID_COLOR_LAYERS_DISABLED #: ../../strtbl.c:806 msgid "Color layers disabled." msgstr "ăŚĆÔÏŚÙĆ ÓÌÏÉ ÚÁĐÒĆĘĆÎÙ." #. STID_TOO_MANY_LINES_IN_COLORINFO #: ../../strtbl.c:808 msgid "Warning: Too many lines in color_info." msgstr "" #. STID_WAIT_FOR_START_CONV #: ../../strtbl.c:810 msgid "Waiting for start of input conversion." msgstr "" #. STID_NO_NAMED_SELECTION_OWNER #: ../../strtbl.c:812 #, c-format msgid "There is no Selection Owner of %s." msgstr "" #. STID_FAIL_TO_CHANGE_CONV_PROP #: ../../strtbl.c:814 msgid "Fail to change conversion property." msgstr "" #. STID_FAIL_TO_INTERN_NAMED_ATOM #: ../../strtbl.c:816 #, c-format msgid "Fail to intern the '%s' atom." msgstr "" #. STID_FAIL_TO_CONNECT_TO_OWNER #: ../../strtbl.c:818 msgid "Fail to connect to selection owner." msgstr "" #. STID_FAIL_TO_GET_WIN_PROP #: ../../strtbl.c:820 msgid "Cannot get window property." msgstr "" #. STID_FAIL_TO_DISCONNECT_FROM_OWNER #: ../../strtbl.c:822 msgid "Fail to disconnect from selection owner." msgstr "" #. STID_LOCALE_IS #: ../../strtbl.c:824 #, c-format msgid "Locale is '%s'." msgstr "" #. STID_MODIFIER_IS #: ../../strtbl.c:826 #, c-format msgid "Modifier is '%s'." msgstr "" #. STID_CANNOT_OPEN_XIM #: ../../strtbl.c:828 msgid "Cannot open the X Input Method." msgstr "" #. STID_OVERTHESPOT_CONV #: ../../strtbl.c:830 msgid "OverTheSpot conversion." msgstr "" #. STID_ROOT_CONV #: ../../strtbl.c:832 msgid "Root conversion." msgstr "" #. STID_IM_NOT_SUPPORT_ANY_STYLE #: ../../strtbl.c:834 msgid "" "This X Input Method does not support either the 'Root' or the 'OverTheSpot' " "input style." msgstr "" #. STID_FAIL_TO_CREATE_INPUTCONTEXT #: ../../strtbl.c:836 msgid "Fail to create InputContext." msgstr "" #. STID_OPEN_XIM #: ../../strtbl.c:838 msgid "Open X Input Method." msgstr "" #. STID_CLOSE_XIM #: ../../strtbl.c:840 msgid "Close X Input Method." msgstr "" #. STID_INVALID_XDEF_USE_ALT_STR #: ../../strtbl.c:842 #, c-format msgid "Invalid %s.%s: '%s', '%s' is used instead." msgstr "" #. STID_NO_OBJ_SELECTED_FOR_COPY #: ../../strtbl.c:844 msgid "No object selected for the COPY operation." msgstr "îĆÔ ŚÙÄĆÌĆÎÎÏÇÏ ÏÂßĆËÔÁ ÄÌŃ ÏĐĆÒÁĂÉÉ ËÏĐÉÒÏŚÁÎÉŃ." #. STID_CANNOT_OPEN_FILE_FOR_WRITING #: ../../strtbl.c:846 #, c-format msgid "Cannot open '%s' for writing." msgstr "îĆ ŐÄÁÌÏÓŰ ÏÔËÒÙÔŰ '%s' ÄÌŃ ÚÁĐÉÓÉ." #. STID_CANNOT_OPEN_FILE_FOR_READING #: ../../strtbl.c:848 #, c-format msgid "Cannot open '%s' for reading." msgstr "îĆ ŐÄÁÌÏÓŰ ÏÔËÒÙÔŰ '%s' ÄÌŃ ȚÔĆÎÉŃ." #. STID_FAIL_TO_FSTAT_ABORT_COPY #: ../../strtbl.c:850 #, c-format msgid "Fail to fstat() '%s'. Copy aborted." msgstr "" #. STID_ERR_READING_FILE_COPY_ABORT #: ../../strtbl.c:852 #, c-format msgid "Error reading from '%s'. Copy aborted." msgstr "ïÛÉÂËÁ ȚÔĆÎÉŃ ÉÚ '%s'. ëÏĐÉÒÏŚÁÎÉĆ ĐÒĆÒŚÁÎÏ." #. STID_COPY_FAILED_OBJ_MAYBE_TOO_BIG #: ../../strtbl.c:854 msgid "Copy to cut buffer failed. Selected object(s) may be too big." msgstr "îĆ ŐÄÁÌÏÓŰ ÓËÏĐÉÒÏŚÁÔŰ Ś ÂŐÆĆÒ ÏÂÍĆÎÁ. óËÏÒĆĆ ŚÓĆÇÏ, ŚÙÂÒÁÎÎÙÊ ÏÂßĆËÔ ÉÌÉ ÏÂßĆËÔÙ ÓÌÉÛËÏÍ ŚĆÌÉËÉ." #. STID_COPY_BUFFER_UPDATED #: ../../strtbl.c:856 msgid "Copy buffer updated." msgstr "" #. STID_ESC_KEY_PRESS_IGNORED #: ../../strtbl.c:858 ../../strtbl.c:2912 msgid "An <ESC> key press is ignored." msgstr "" #. STID_CUT_BUFFER_EMPTY #: ../../strtbl.c:860 msgid "The cut buffer is empty." msgstr "âŐÆĆÒ ÏÂÍĆÎÁ ĐŐÓÔ." #. STID_STR_EXCEEDS_NUM_CH_IGNORED #: ../../strtbl.c:862 #, c-format msgid "String length exceeds %1d. Character is ignored." msgstr "" #. STID_PASTE_FROM_NON_TGIF #: ../../strtbl.c:864 msgid "Paste from a non-tgif tool." msgstr "" #. STID_ERR_WRITING_FILE_PASTE_ABORT #: ../../strtbl.c:866 #, c-format msgid "Error writing to '%s'. Paste aborted." msgstr "ïÛÉÂËÁ ÚÁĐÉÓÉ Ś '%s'. śÓÔÁŚËÁ ĐÒĆÒŚÁÎÁ." #. STID_FILEVER_TOO_LARGE_PASTE_ABORT #: ../../strtbl.c:868 #, c-format msgid "File version too large (=%1d). Paste aborted." msgstr "śĆÒÓÉŃ ÆÁÊÌÁ ÓÌÉÛËÏÍ ŚĆÌÉËÁ (=%1d). śÓÔÁŚËÁ ĐÒĆÒŚÁÎÁ." #. STID_CANNOT_PASTE_MIXED_TEXT #: ../../strtbl.c:870 msgid "Cannot paste mixed text at the current cursor position." msgstr "" #. STID_STR_BLOCKS_PASTED_FROM_TGIF #: ../../strtbl.c:872 msgid "String blocks pasted from tgif." msgstr "" #. STID_OBJS_PASTED_FROM_TGIF #: ../../strtbl.c:874 msgid "Objects pasted from tgif." msgstr "" #. STID_SEL_A_FILE_TO_PASTE_DOTS #: ../../strtbl.c:876 msgid "Please select a file to PASTE..." msgstr "" #. STID_PASTING_REMOTE_FILE_NOT_SUP #: ../../strtbl.c:878 msgid "Pasting remote file not supported." msgstr "" #. STID_NAMED_FILE_IS_EMPTY #: ../../strtbl.c:880 #, c-format msgid "File '%s' is empty." msgstr "æÁÊÌ '%s' ĐŐÓÔ." #. STID_CANNOT_MALLOC_NUM_BYTES #: ../../strtbl.c:882 #, c-format msgid "Cannot malloc %1d bytes." msgstr "" #. STID_NO_PRIMARY_SELECTION_OWNER #: ../../strtbl.c:884 msgid "There is no selection owner of PRIMARY." msgstr "" #. STID_CONVERTING_GIVEN_DOTS #: ../../strtbl.c:886 #, c-format msgid "Converting %s..." msgstr "đÒĆÏÂÒÁÚÏŚÁÎÉĆ %s..." #. STID_TIMEOUT_CONVERT_GIVEN #: ../../strtbl.c:888 #, c-format msgid "Timeout occurred when attempting to convert %s." msgstr "" #. STID_PROBLEM_CONVERT_GIVEN #: ../../strtbl.c:890 #, c-format msgid "Problem encountered when converting %s." msgstr "" #. STID_PASTE_COMP_TEXT_FROM_NON_TGIF #: ../../strtbl.c:892 msgid "Paste compound-text from a non-tgif tool." msgstr "" #. STID_CANNOT_FIND_SIZE_USE_ALT #: ../../strtbl.c:894 #, c-format msgid "Cannot find font size '%1d'. %1d is used instead." msgstr "" #. STID_CANNOT_FIND_FONT_USE_ALT #: ../../strtbl.c:896 #, c-format msgid "Cannot find screen font for '%s'. '%s' font is used instead." msgstr "" #. STID_CANNOT_PASTE_COMPOUND_OBJ #: ../../strtbl.c:898 #, c-format msgid "" "Cannot paste '%s' for compound objects. Therefore, '%s' cannot be selected." msgstr "" #. STID_CUT_BUF_HAS_NON_ROT_COMP #: ../../strtbl.c:900 #, c-format msgid "" "The '%s' in the cut buffer contains non-rotational components. Text " "rotation of 0 degree is used." msgstr "" #. STID_NO_PROPERTY_TO_PASTE #: ../../strtbl.c:902 msgid "No property to paste." msgstr "îĆÔ ÓŚÏÊÓÔŚ ÄÌŃ ŚÓÔÁŚËÉ." #. STID_NO_PROPERTY_TO_COPY #: ../../strtbl.c:904 msgid "No property to copy." msgstr "îĆÔ ÓŚÏÊÓÔŚ ÄÌŃ ËÏĐÉÒÏŚÁÎÉŃ." #. STID_INVALID_KEY_IN_SEC_OF_INIFILE #: ../../strtbl.c:906 #, c-format msgid "Invalid key: '%s' in the [%s] section of '%s'." msgstr "" #. STID_ENTER_NAME_FOR_PROP_SET #: ../../strtbl.c:908 msgid "Please enter a name for the property set." msgstr "śŚĆÄÉÔĆ ÉÍŃ ÄÌŃ ÎÁÂÏÒÁ ÓŚÏÊÓÔŚ." #. STID_PROP_SET_EXISTS_OVERWRITE_YNC #: ../../strtbl.c:910 #, c-format msgid "Property set [%s] already exists. Okay to overwrite?" msgstr "îÁÂÏÒ ÓŚÏÊÓÔŚ [%s] ŐÖĆ ÓŐĘĆÓÔŚŐĆÔ. đĆÒĆĐÉÓÁÔŰ?" #. STID_NO_PROP_TO_SAVE #: ../../strtbl.c:912 msgid "No property to save." msgstr "îĆÔ ÓŚÏÊÓÔŚ ÄÌŃ ÓÏÈÒÁÎĆÎÉŃ." #. STID_WILL_COPY_NAMED_PROP #: ../../strtbl.c:914 #, c-format msgid "Will copy the '%s' property." msgstr "ëÏĐÉÒÏŚÁÔŰ ÓŚÏÊÓÔŚÏ '%s'." #. STID_WILL_NOT_COPY_NAMED_PROP #: ../../strtbl.c:916 #, c-format msgid "Will not copy the '%s' property." msgstr "îĆ ËÏĐÉÒÏŚÁÔŰ ÓŚÏÊÓÔŚÏ '%s'." #. STID_WILL_SAVE_NAMED_PROP #: ../../strtbl.c:918 #, c-format msgid "Will save the '%s' property." msgstr "óÏÈÒÁÎŃÔŰ ÓŚÏÊÓÔŚÏ '%s'." #. STID_WILL_NOT_SAVE_NAMED_PROP #: ../../strtbl.c:920 #, c-format msgid "Will not save the '%s' property." msgstr "îĆ ÓÏÈÒÁÎŃÔŰ ÓŚÏÊÓÔŚÏ '%s'." #. STID_WILL_PASTE_NAMED_PROP #: ../../strtbl.c:922 #, c-format msgid "Will paste the '%s' property." msgstr "" #. STID_WILL_NOT_PASTE_NAMED_PROP #: ../../strtbl.c:924 #, c-format msgid "Will not paste the '%s' property." msgstr "" #. STID_WILL_RESTORE_NAMED_PROP #: ../../strtbl.c:926 #, c-format msgid "Will restore the '%s' property." msgstr "" #. STID_WILL_NOT_RESTORE_NAMED_PROP #: ../../strtbl.c:928 #, c-format msgid "Will not restore the '%s' property." msgstr "" #. STID_TOOL_COPY_PROP #: ../../strtbl.c:930 #, c-format msgid "%s - Copy Properties" msgstr "%s - óËÏĐÉÒÏŚÁÔŰ ÓŚÏÊÓÔŚÁ" #. STID_TOOL_SAVE_PROP #: ../../strtbl.c:932 #, c-format msgid "%s - Save Properties" msgstr "%s - óÏÈÒÁÎÉÔŰ ÓŚÏÊÓÔŚÁ" #. STID_TOOL_PASTE_PROP #: ../../strtbl.c:934 #, c-format msgid "%s - Paste Properties" msgstr "%s - śÓÔÁŚÉÔŰ ÓŚÏÊÓÔŚÁ" #. STID_TOOL_RESTORE_PROP #: ../../strtbl.c:940 #, c-format msgid "%s - Restore Properties" msgstr "%s - śÏÓÓÔÁÎÏŚÉÔŰ ÓŚÏÊÓÔŚÁ" #. STID_SEL_ONLY_ONE_FOR_COPY_PROP #: ../../strtbl.c:942 msgid "Please select only one object for CopyProperties()." msgstr "" #. STID_SEL_ONLY_ONE_FOR_SAVE_PROP #: ../../strtbl.c:944 msgid "Please select only one object for SaveProperties()." msgstr "" #. STID_UNCHECK_PROP_FOR_COPY_DOTS #: ../../strtbl.c:946 msgid "Please uncheck properties you don't want to copy..." msgstr "" #. STID_UNCHECK_PROP_FOR_SAVE_DOTS #: ../../strtbl.c:948 msgid "Please uncheck properties you don't want to save..." msgstr "" #. STID_UNCHECK_PROP_FOR_PASTE_DOTS #: ../../strtbl.c:950 msgid "Please uncheck properties you don't want to paste..." msgstr "" #. STID_UNCHECK_PROP_FOR_RESTORE_DOTS #: ../../strtbl.c:952 msgid "Please uncheck properties you don't want to restore..." msgstr "" #. STID_MALFORMED_CUT_BUF_WHILE_PASTE #: ../../strtbl.c:954 msgid "Malformed cut buffer read while pasting properties." msgstr "" #. STID_NO_PROP_SETS_TO_RESTORE #: ../../strtbl.c:956 msgid "Cannot find any property sets. Nothing to restore." msgstr "" #. STID_SEL_A_PROP_SET_TO_RESTORE #: ../../strtbl.c:958 msgid "Please select a property set to restore..." msgstr "" #. STID_TOOL_EDIT_INI_SECTION #: ../../strtbl.c:960 #, c-format msgid "%s - Edit Ini Section" msgstr "" #. STID_BAD_VALUE_FOR_KEY #: ../../strtbl.c:962 #, c-format msgid "Bad %s value: '%s'." msgstr "" #. STID_NOTHING_TO_EDIT_SEC_EMPTY #: ../../strtbl.c:964 #, c-format msgid "" "The [%s] section of '%s' is empty.\n" "\n" "Nothing to edit." msgstr "" "óĆËĂÉŃ [%s] Ś '%s' ĐŐÓÔÁ.\n" "\n" "òĆÄÁËÔÉÒÏŚÁÔŰ ÎĆȚĆÇÏ." #. STID_EDIT_VALUES_FOR_DOTS #: ../../strtbl.c:966 #, c-format msgid "Edit values for [%s]..." msgstr "" #. STID_TOOL_SEL_FROM_INI_SECTION #: ../../strtbl.c:968 #, c-format msgid "%s - Select From Ini Section" msgstr "" #. STID_NOTHING_TO_SEL_SEC_EMPTY #: ../../strtbl.c:970 #, c-format msgid "" "The [%s] section of '%s' is empty.\n" "\n" "Nothing to select from." msgstr "" #. STID_SELECT_A_VALUE_FROM_SEC_DOTS #: ../../strtbl.c:972 #, c-format msgid "Select a value from [%s]..." msgstr "" #. STID_COPY_PROP_BEFORE_PASTE #: ../../strtbl.c:974 msgid "Please copy some properties before pasting properties." msgstr "" #. STID_INVALID_PARAM_PASSED_TO_FUNC #: ../../strtbl.c:976 #, c-format msgid "Invalid parameters passed to %s." msgstr "" #. STID_TOOL_INPUT #: ../../strtbl.c:978 #, c-format msgid "%s - Input" msgstr "" #. STID_WARN_INVALID_NUMREDRAWBBOX #: ../../strtbl.c:980 msgid "Warning: Invalid numRedrawBBox." msgstr "" #. STID_USER_INTR_ABORT_REPAINT #: ../../strtbl.c:982 msgid "User interrupt. Repaint aborted." msgstr "" #. STID_CANNOT_ALLOC_XPM_NO_ANIM #: ../../strtbl.c:984 #, c-format msgid "" "Cannot allocate pixmap of size [%1dx%1d].\n" "\n" "Cannot cache animation." msgstr "" #. STID_SCROLLING_CANCELED #: ../../strtbl.c:986 msgid "Scrolling canceled." msgstr "" #. STID_CANNOT_ALLOC_PIXMAP_OF_SIZE #: ../../strtbl.c:988 #, c-format msgid "Cannot allocate pixmap of size [%1dx%1d]." msgstr "" #. STID_FORCING_END_ANIMATE #: ../../strtbl.c:990 msgid "Forcing an end_animate()." msgstr "" #. STID_TOOL_NOT_FINISH_WITH_EXEC #: ../../strtbl.c:992 #, c-format msgid "%s is not finished with the previous ExecCmdsFromFile() yet." msgstr "" #. STID_NO_INTSPLINE_SELECTED #: ../../strtbl.c:994 msgid "No interpolated spline objects selected." msgstr "" #. STID_INTSPLINE_CONVERTED_TO_SPLINE #: ../../strtbl.c:996 msgid "Interpolated spline objects converted to splines." msgstr "" #. STID_SELECT_ONLY_ONE_POLY_POLYGON #: ../../strtbl.c:998 msgid "Please select only one POLY or POLYGON object." msgstr "" #. STID_CANNOT_TOGGLE_FOR_INTSPLINE #: ../../strtbl.c:1000 msgid "Cannot toggle Smooth/Hinge points for interpolated spline objects." msgstr "" #. STID_BAD_POLY_IN_TOGGLE_SMOOTH #: ../../strtbl.c:1002 msgid "Bad poly in SelectModeToggleSmoothHinge()." msgstr "" #. STID_CLICK_LEFT_BUTTON_TO_TOGGLE #: ../../strtbl.c:1004 msgid "Click left mouse button to toggle Smooth/Hinge points." msgstr "" #. STID_CLICK_OTHER_BUTTON_TO_QUIT #: ../../strtbl.c:1006 msgid "Click other buttons to quit." msgstr "" #. STID_ONLY_TOGGLE_SMOOTH_IN_MODES #: ../../strtbl.c:1008 msgid "Can only toggle smooth/hinge points in VERTEX or SELECT mode." msgstr "" #. STID_SMOOTHNESS_TOGGLED #: ../../strtbl.c:1010 msgid "The smoothness of selected vertices are toggled." msgstr "" #. STID_BREAK_TEXT_CWL #: ../../strtbl.c:1012 msgid "Would you like to break text at char/word/line boundaries? [cwl](c)" msgstr "" #. STID_BREAK_TEXT_CL #: ../../strtbl.c:1014 msgid "Would you like to break text at char/line boundaries? [cl](c)" msgstr "" #. STID_BREAK_TEXT_CW #: ../../strtbl.c:1016 msgid "Would you like to break text at char/word boundaries? [cw](c)" msgstr "" #. STID_INVALID_SPEC_ON_BREAK_TEXT #: ../../strtbl.c:1018 #, c-format msgid "Invalid specification on how to break up text: '%s'." msgstr "" #. STID_NO_TEXT_OBJ_TO_BREAK_UP #: ../../strtbl.c:1020 msgid "No text objects selected to break up." msgstr "" #. STID_SOME_TEXT_NOT_BROKEN_UP_SIZE #: ../../strtbl.c:1022 msgid "Some text are not broken up due to unavailable text size." msgstr "" #. STID_TEXT_BROKEN_INTO_CHARS #: ../../strtbl.c:1024 msgid "Text string is broken up into characters." msgstr "" #. STID_CUR_TEXT_BG_SET_TO_NAMED #: ../../strtbl.c:1026 #, c-format msgid "Current text object's background color has been set to '%s'." msgstr "" #. STID_SOME_TEXT_BG_SET_TO_NAMED #: ../../strtbl.c:1028 #, c-format msgid "Some text object's background color have been set to '%s'." msgstr "" #. STID_SEL_ONE_POLYGON_TO_MAKE_REG #: ../../strtbl.c:1030 msgid "Please select one polygon object to make it regular." msgstr "" #. STID_POLYGON_LOCKED #: ../../strtbl.c:1032 msgid "Selected polygon is locked." msgstr "" #. STID_POLYGON_TOO_SMALL_FOR_REGULAR #: ../../strtbl.c:1034 msgid "Selected polygon is too small to make regular." msgstr "" #. STID_VERTEX_AT_3_OCLOCK_YNC #: ../../strtbl.c:1036 msgid "Do you want a vertex at the 3 o'clock position? [ync](y)" msgstr "" #. STID_CANNOT_DEL_PT_FOR_LOCKED #: ../../strtbl.c:1038 msgid "Cannot delete points for a locked object." msgstr "" #. STID_LEFT_BTN_TO_DEL_PTS #: ../../strtbl.c:1040 msgid "Click left mouse button to DELETE points." msgstr "" #. STID_CANNOT_ADD_PT_FOR_LOCKED #: ../../strtbl.c:1042 msgid "Cannot add points for a locked object." msgstr "" #. STID_CANNOT_ADD_PT_FOR_AUTO_ARROW #: ../../strtbl.c:1044 msgid "Cannot add points for an auto_retracted_arrows object." msgstr "" #. STID_LEFT_BTN_TO_ADD_PTS #: ../../strtbl.c:1046 msgid "Drag left mouse button to ADD points." msgstr "" #. STID_UNDO_BUF_AND_CMAP_FLUSHED #: ../../strtbl.c:1048 msgid "Undo buffer and Colormap flushed." msgstr "" #. STID_NUM_COLORS_ALLOCATED #: ../../strtbl.c:1050 #, c-format msgid "%1d color(s) allocated." msgstr "%1d ĂŚĆÔ(ÏŚ) ÒÁÓĐÒĆÄĆÌĆÎÏ." #. STID_UNDO_BUF_FLUSHED #: ../../strtbl.c:1052 msgid "Undo buffer flushed." msgstr "âŐÆĆÒ ÏÔËÁÔÁ ÏȚÉĘĆÎ." #. STID_SEL_ONE_XBM_OR_XPM_TO_RESTORE #: ../../strtbl.c:1054 msgid "Please select one X11 Bitmap or X11 Pixmap object to restore." msgstr "" #. STID_CANNOT_RESTORE_LOCKED #: ../../strtbl.c:1056 msgid "Cannot restore a locked object." msgstr "" #. STID_SEL_ONE_XBM_OR_XPM_TO_CUT #: ../../strtbl.c:1058 msgid "Please select one X11 Bitmap or X11 Pixmap object to cut." msgstr "" #. STID_CANNOT_CUT_LOCKED #: ../../strtbl.c:1060 msgid "Cannot cut a locked object." msgstr "" #. STID_CANNOT_CUT_TRANSFORMED_X_OBJ #: ../../strtbl.c:1062 msgid "Cannot cut a stretched/rotated/sheared X11 Bitmap or X11 Pixmap object." msgstr "" #. STID_SEL_ONE_XBM_OR_XPM_TO_BREAKUP #: ../../strtbl.c:1064 msgid "Please select one X11 Bitmap or X11 Pixmap object to break up." msgstr "" #. STID_CANNOT_BREAK_XFORMED_X_OBJ #: ../../strtbl.c:1066 msgid "" "Cannot break up a stretched/rotated/sheared X11 Bitmap or X11 Pixmap object." msgstr "" #. STID_CANNOT_BREAKUP_LOCKED #: ../../strtbl.c:1068 msgid "Cannot break up a locked object." msgstr "" #. STID_ENTER_NUM_ROWCOL_TO_BREAK #: ../../strtbl.c:1070 #, c-format msgid "" "Please enter the number of columns and rows to break into (original size is %" "1dx%1d): [Col x Row]" msgstr "" #. STID_INVALID_ROWCOL_SPEC_REENTER #: ../../strtbl.c:1072 #, c-format msgid "" "Invalid specification: '%s'.\n" "\n" "Please enter [Cols x Rows] or [=WxH]" msgstr "" #. STID_ENTER_CONCAVE_OR_CONVEX #: ../../strtbl.c:1074 msgid "Please specify concave (c) or convex (v):" msgstr "" #. STID_INVALID_SPEC #: ../../strtbl.c:1076 #, c-format msgid "Invalid specification: '%s'." msgstr "" #. STID_SEL_AN_ARC_OBJ #: ../../strtbl.c:1078 msgid "Please select an arc object." msgstr "" #. STID_NO_ARC_OBJ_SELECTED #: ../../strtbl.c:1080 msgid "No arc object selected." msgstr "" #. STID_TOO_MANY_ARC_SEL_ONLY_ONE_ARC #: ../../strtbl.c:1082 msgid "" "Too many arc objects selected.\n" "\n" "Please select only one arc object." msgstr "" #. STID_NO_OTHER_OBJ_FOR_LAYOUTONARC #: ../../strtbl.c:1084 msgid "" "Nothing to layout on the selected arc.\n" "\n" "Please select other objects in addition to the selected arc." msgstr "" #. STID_CANNOT_LAYOUTONARC_LOCKED #: ../../strtbl.c:1086 msgid "" "Some objects are locked.\n" "\n" "Please unlock them before retrying." msgstr "" #. STID_ARC_XFORMED_FOR_LAYOUTONARC #: ../../strtbl.c:1088 msgid "" "Don't know how to layout objects on an arc object that has been stretched/" "sheared/rotated.\n" "\n" "Please use a simple arc." msgstr "" #. STID_ROT_NOT_AVAIL_ON_VERTEX_MODE #: ../../strtbl.c:1090 msgid "PreciseRotate() is not available in vertex mode." msgstr "" #. STID_ENTER_AN_ANGLE_IN_DEGREES #: ../../strtbl.c:1092 msgid "Please specify an angle in degrees: (positive angle is clock-wise)" msgstr "" #. STID_INVALID_SPEC_NUM_EXPECTED #: ../../strtbl.c:1094 #, c-format msgid "" "Invalid specification '%s'.\n" "\n" "A numerical value is expected." msgstr "" #. STID_SOME_GROUP_OBJ_NOT_MODIFIED #: ../../strtbl.c:1096 msgid "Some group/symbol/icon objects are not modified." msgstr "" #. STID_CANNOT_REM_XFORM_FOR_GROUPED #: ../../strtbl.c:1098 msgid "Cannot remove transforms for group/symbol/icon objects." msgstr "" #. STID_ENTER_EDIT_TEXT_SIZE #: ../../strtbl.c:1100 #, c-format msgid "" "Please specify text size for editing text objects (enter 0 or a value " "between 4 and 34, 0 means to use the actual size of text): [current: %1d]" msgstr "" #. STID_EDIT_TEXT_SIZE_OUT_OF_RANGE #: ../../strtbl.c:1102 #, c-format msgid "" "The value entered: '%s' is out of range.\n" "\n" "Please enter a value between 4 and 34." msgstr "" #. STID_ACTUAL_EDIT_TEXT_SIZE #: ../../strtbl.c:1104 msgid "Actual text size will be used to edit existing text." msgstr "" #. STID_USE_SPECIFIED_EDIT_TEXT_SIZE #: ../../strtbl.c:1106 #, c-format msgid "Text size of %1d will be used to edit existing text." msgstr "" #. STID_CANNOT_FIND_NAMED_STRING #: ../../strtbl.c:1108 #, c-format msgid "Cannot find '%s'." msgstr "îĆ ŐÄÁÌÏÓŰ ÎÁÊÔÉ '%s'." #. STID_FIND_CMD_WRAPPED #: ../../strtbl.c:1110 msgid "Find command is wrapped around." msgstr "" #. STID_ENTER_CASE_STR_TO_FIND #: ../../strtbl.c:1112 msgid "Please enter a string to find (case sensitive):" msgstr "" #. STID_ENTER_NOCASE_STR_TO_FIND #: ../../strtbl.c:1114 msgid "Please enter a string to find (case insensitive):" msgstr "" #. STID_NO_PREVIOUS_FIND #: ../../strtbl.c:1116 msgid "" "No previous find specified.\n" "\n" "Please select FindCaseSensitive() or FindNoCase()." msgstr "" #. STID_CANNOT_ABUT_IN_VERTEX_MODE #: ../../strtbl.c:1118 msgid "Cannot abut in vertex mode." msgstr "" #. STID_CANNOT_ABUT_LOCKED #: ../../strtbl.c:1120 msgid "Cannot abut. Too many objects locked." msgstr "" #. STID_ABUTTED_HORI #: ../../strtbl.c:1122 msgid "Objects are abutted horizontally." msgstr "" #. STID_ABUTTED_VERT #: ../../strtbl.c:1124 msgid "Objects are abutted vertically." msgstr "" #. STID_ICONS_BROUGHT_UP_TO_DATE #: ../../strtbl.c:1126 msgid "Selected icons are brought up to date." msgstr "" #. STID_SEL_AT_LEAST_TWO_OBJS #: ../../strtbl.c:1128 msgid "Please select at least two objects." msgstr "" #. STID_CANNOT_SIZE_OF_GIVEN_WIDTH #: ../../strtbl.c:1130 #, c-format msgid "Cannot size objects to width of %1d." msgstr "" #. STID_CANNOT_SIZE_OF_GIVEN_HEIGHT #: ../../strtbl.c:1132 #, c-format msgid "Cannot size objects to height of %1d." msgstr "" #. STID_SPECIFY_WIDTH_HEIGHT #: ../../strtbl.c:1134 msgid "Please specify a width and a height [WxH]:" msgstr "" #. STID_SPECIFY_WIDTH #: ../../strtbl.c:1136 msgid "Please specify a width:" msgstr "őËÁÖÉÔĆ ÛÉÒÉÎŐ:" #. STID_SPECIFY_HEIGHT #: ../../strtbl.c:1138 msgid "Please specify a height:" msgstr "őËÁÖÉÔĆ ŚÙÓÏÔŐ:" #. STID_NAMED_XDEF_IS_OBSOLETE #: ../../strtbl.c:1144 #, c-format msgid "The %s.%s X default is obsolete." msgstr "X-ÒĆÓŐÒÓ %s.%s ŃŚÌŃĆÔÓŃ ŐÓÔÁÒĆŚÛÉÍ." #. STID_GIVEN_BPS_PREVIEW_NOT_SUP #: ../../strtbl.c:1146 #, c-format msgid "%1d bits per sample preview not supported." msgstr "" #. STID_INVALID_PREVIEW_BMP_IN_EPS #: ../../strtbl.c:1148 #, c-format msgid "Invalid preview bitmap in EPS file: '%s'." msgstr "" #. STID_FAIL_TO_WRITE_TO_STDOUT #: ../../strtbl.c:1150 msgid "" "Fail to write to stdout.\n" "\n" "File system may be full." msgstr "" #. STID_FAIL_TO_PARSE_WINEPS_FILE #: ../../strtbl.c:1152 #, c-format msgid "Fail to parse Windows EPS file '%s'." msgstr "ïÛÉÂËÁ ÒÁÚÂÏÒÁ ÆÁÊÌÁ Windows EPS '%s'." #. STID_INVALID_PREVIEW_BOX_IN_EPS #: ../../strtbl.c:1154 #, c-format msgid "Invalid preview box in EPS file: '%s'." msgstr "" #. STID_CANNOT_BBOX_IN_GIVEN_FILE #: ../../strtbl.c:1156 #, c-format msgid "Cannot find bounding box information in '%s'." msgstr "" #. STID_CANNOT_CONVERT_WINEPS_PREVIEW #: ../../strtbl.c:1158 #, c-format msgid "Unable to convert Windows EPS preview bitmap in '%s'." msgstr "" #. STID_CANNOT_OPEN_EPS_FILE_FOR_READ #: ../../strtbl.c:1160 #, c-format msgid "Cannot open EPS file '%s' for reading." msgstr "îĆ ŐÄÁÌÏÓŰ ÏÔËÒÙÔŰ ÆÁÊÌ EPS '%s' ÄÌŃ ȚÔĆÎÉŃ." #. STID_EPS_OBJ_SKIPPED_FOR_PRINT #: ../../strtbl.c:1162 msgid "EPS object skipped during printing." msgstr "EPS-ÏÂßĆËÔ ĐÒÏĐŐĘĆÎ ŚÏ ŚÒĆÍŃ ĐĆȚÁÔÉ." #. STID_EPS_FILE_NEWER_THAN_EPS_OBJ #: ../../strtbl.c:1164 #, c-format msgid "Warning: EPS file '%s' is newer than the EPS object." msgstr "đÒĆÄŐĐÒĆÖÄĆÎÉĆ: ÆÁÊÌ EPS '%s' ÎÏŚĆĆ, ȚĆÍ EPS-ÏÂßĆËÔ." #. STID_NO_TOP_LEVEL_EPS_SELECTED #: ../../strtbl.c:1166 msgid "No top-level EPS object selected." msgstr "" #. STID_CANNOT_IMPORT_GIVEN_EPS #: ../../strtbl.c:1168 #, fuzzy, c-format msgid "Cannot import EPS file '%s'." msgstr "éÍĐÏÒÔ EPS.." #. STID_EPS_OBJECT_UPDATED #: ../../strtbl.c:1170 msgid "EPS object(s) updated." msgstr "" #. STID_CANNOT_EVAL_INVALID_OP_TYPE #: ../../strtbl.c:1172 #, c-format msgid "" "Cannot evaluate '%s'.\n" "\n" "Invalid operand type for the '%s' operator." msgstr "" #. STID_DIVIDE_BY_ZERO_FOR_OP_TYPE #: ../../strtbl.c:1174 #, c-format msgid "Divide by zero encountered for the '%s' operator." msgstr "" #. STID_ILLEGAL_EXPR_INVALID_OP_CODE #: ../../strtbl.c:1176 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Invalid operator code: '%1d'." msgstr "" #. STID_ILLEGAL_EXPR_EMPTY_OP_STACK #: ../../strtbl.c:1178 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Empty operator stack." msgstr "" #. STID_ILLEGAL_EXPR_BAD_NUM_VALUE #: ../../strtbl.c:1180 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Bad numeric value: '%s'." msgstr "" #. STID_ILLEGAL_EXPR_BAD_STR_VALUE #: ../../strtbl.c:1182 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Bad string value: '%s'." msgstr "" #. STID_ILLEGAL_EXPR_BAD_IDENTIFIER #: ../../strtbl.c:1184 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Bad identifier: '%s'." msgstr "" #. STID_ILLEGAL_EXPR_BAD_OPERATOR #: ../../strtbl.c:1186 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Bad operator: '%s'." msgstr "" #. STID_ILLEGAL_EXPR_TOO_MANY_SYMBOL #: ../../strtbl.c:1188 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Too many '%c'." msgstr "" #. STID_ILL_EXPR_OP_STACK_NON_EMPTY #: ../../strtbl.c:1190 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Non empty operator stack after evaluation." msgstr "" #. STID_ILL_EXPR_VAL_STACK_NON_EMPTY #: ../../strtbl.c:1192 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Non empty value stack after evaluation." msgstr "" #. STID_ILL_EXPR_TOO_MANY_VALS_LEFT #: ../../strtbl.c:1194 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Too many values left on the value stack after evaluation." msgstr "" #. STID_CANNOT_OPEN_FOR_READ_PRINT #: ../../strtbl.c:1196 #, c-format msgid "Cannot open '%s' for reading. Printing aborted." msgstr "îĆ ŐÄÁÌÏÓŰ ÏÔËÒÙÔŰ '%s' ÄÌŃ ȚÔĆÎÉŃ. đĆȚÁÔŰ ĐÒĆÒŚÁÎÁ." #. STID_CANNOT_OPEN_FOR_WRITE_PRINT #: ../../strtbl.c:1198 #, c-format msgid "Cannot open '%s' for writing. Printing aborted." msgstr "îĆ ŐÄÁÌÏÓŰ ÏÔËÒÙÔŰ '%s' ÄÌŃ ÚÁĐÉÓÉ. đĆȚÁÔŰ ĐÒĆÒŚÁÎÁ." #. STID_CANNOT_FIND_CMD_EXEC #: ../../strtbl.c:1200 #, c-format msgid "" "Cannot find '%s'.\n" "\n" "Would you like to execute '%s' anyway?" msgstr "" #. STID_CANNOT_FIND_CMD_IN_PATH_EXEC #: ../../strtbl.c:1202 #, c-format msgid "" "Cannot find '%s' in the PATH.\n" "\n" "Would you like to execute '%s' anyway?" msgstr "" #. STID_CANT_FIND_CMD_MSG_EXEC #: ../../strtbl.c:1204 #, c-format msgid "" "Cannot find '%s'. %s\n" "\n" "Would you like to execute '%s' anyway?" msgstr "" #. STID_CANT_FIND_CMD_INPATH_MSG_EXEC #: ../../strtbl.c:1206 #, c-format msgid "" "Cannot find '%s' in the PATH. %s\n" "\n" "Would you like to execute '%s' anyway?" msgstr "" #. STID_FILE_EXISTS_OK_OVERWRITE_YNC #: ../../strtbl.c:1208 #, c-format msgid "File '%s' exists, okay to overwrite? [ync](y)" msgstr "æÁÊÌ '%s' ÓŐĘĆÓÔŚŐĆÔ. đĆÒĆĐÉÓÁÔŰ? [ync](y)" #. STID_ONE_PAGE_SYM_ABORT_SAVE #: ../../strtbl.c:1210 msgid "" "A symbol file can only have one page.\n" "\n" "Save aborted." msgstr "" #. STID_ONE_PAGE_PIN_ABORT_SAVE #: ../../strtbl.c:1212 msgid "" "A pin file can only have one page.\n" "\n" "Save aborted." msgstr "" #. STID_TOO_MANY_SYM_ABORT_SAVE #: ../../strtbl.c:1214 msgid "" "Too many symbols.\n" "\n" "Symbol file not saved." msgstr "" #. STID_CANT_OPEN_WRITE_FILE_NOT_SAVE #: ../../strtbl.c:1216 #, c-format msgid "Cannot open '%s' for writing. File not saved." msgstr "îĆ ŐÄÁÌÏÓŰ ÏÔËÒÙÔŰ '%s' ÄÌŃ ÚÁĐÉÓÉ. æÁÊÌ ÎĆ ÓÏÈÒÁÎĆÎ." #. STID_SAVE_TMP_FILE_DOTS #: ../../strtbl.c:1218 #, c-format msgid "Saving temporary file '%s'..." msgstr "óÏÈÒÁÎŃĆÔÓŃ ŚÒĆÍĆÎÎÙÊ ÆÁÊÌ '%s'..." #. STID_TMP_FILE_SAVED #: ../../strtbl.c:1220 #, c-format msgid "Temporary file '%s' saved." msgstr "śÒĆÍĆÎÎÙÊ ÆÁÊÌ '%s' ÓÏÈÒÁÎĆÎ." #. STID_CANNOT_CHMOD #: ../../strtbl.c:1222 #, c-format msgid "Cannot chmod '%s' to 0%03o." msgstr "îĆ ŐÄÁÌÏÓŰ ÉÚÍĆÎÉÔŰ ĐÒÁŚÁ ÄÏÓÔŐĐÁ Ë '%s' ÎÁ 0%03o." #. STID_WORKING_DIRECTORY_IS #: ../../strtbl.c:1224 #, c-format msgid "( working directory: %s )" msgstr "( ÒÁÂÏȚÉÊ ËÁÔÁÌÏÇ: %s )" #. STID_ENTER_NEW_FNAME_ACCEPT_CANCEL #: ../../strtbl.c:1226 msgid "Please enter new file name: ( <CR>: accept, <ESC>: cancel )" msgstr "śŚĆÄÉÔĆ ÎÏŚÏĆ ÉÍŃ ÆÁÊÌÁ: ( <CR>: ĐÒÉÎŃÔŰ, <ESC>: ÏÔÍĆÎÉÔŰ )" #. STID_CANT_SAVE_SYM_NO_SYM_FOUND #: ../../strtbl.c:1228 msgid "" "Cannot save as a symbol file.\n" "\n" "No symbol defined." msgstr "" #. STID_CANT_SAVE_PIN_NO_SYM_FOUND #: ../../strtbl.c:1230 msgid "" "Cannot save as a pin file.\n" "\n" "No symbol defined." msgstr "" #. STID_CANT_SAVE_OJB_ONE_SYM_FOUND #: ../../strtbl.c:1232 msgid "" "Cannot save as an object file.\n" "\n" "One symbol defined." msgstr "" #. STID_CANT_SAVE_SYM_SAVE_AS_PIN #: ../../strtbl.c:1234 msgid "" "Cannot save as a symbol file.\n" "\n" "Please save the file as a pin file." msgstr "" #. STID_CANT_SAVE_PIN_ONE_SYM_FOUND #: ../../strtbl.c:1236 msgid "" "Cannot save as a pin file.\n" "\n" "Only one symbol is defined." msgstr "" #. STID_CANT_SAVE_OJB_TWO_SYM_FOUND #: ../../strtbl.c:1238 msgid "" "Cannot save as an object file.\n" "\n" "Two symbols defined." msgstr "" #. STID_CANT_SAVE_SYM_TWO_SYM_FOUND #: ../../strtbl.c:1240 msgid "" "Cannot save as a symbol file.\n" "\n" "Two symbols defined." msgstr "" #. STID_CANT_FIND_TYPE_ATTR_NOT_SAVED #: ../../strtbl.c:1242 msgid "" "Cannot find an attribute name 'type'.\n" "\n" "Pin file not saved." msgstr "" #. STID_SYM_TYPE_WRONG_PIN_NOT_SAVED #: ../../strtbl.c:1244 #, c-format msgid "" "Symbol type is not '%s'.\n" "\n" "Pin file not saved." msgstr "" #. STID_NO_FILE_NAME_FILE_NOT_SAVED #: ../../strtbl.c:1246 msgid "" "No file name specified.\n" "\n" "File not saved." msgstr "" #. STID_SAVING_DOTS #: ../../strtbl.c:1248 #, c-format msgid "Saving '%s'..." msgstr "óÏÈÒÁÎŃĆÔÓŃ '%s'..." #. STID_PROBLEM_ZIPPING_PLEASE_SAVE #: ../../strtbl.c:1250 #, c-format msgid "" "Problems encountered while (g)zipping '%s' to '%s'.\n" "\n" "The unzipped file is '%s'. Please save a copy of it before proceeding." msgstr "" #. STID_FILE_SAVED #: ../../strtbl.c:1252 #, c-format msgid "File '%s' saved." msgstr "æÁÊÌ '%s' ÓÏÈÒÁÎĆÎ." #. STID_FILE_NOT_SAVED #: ../../strtbl.c:1254 #, c-format msgid "File '%s' is not saved." msgstr "æÁÊÌ '%s' ÎĆ ÓÏÈÒÁÎĆÎ." #. STID_NO_SYM_FOUND_SYM_NOT_SAVED #: ../../strtbl.c:1256 msgid "" "No symbol found.\n" "\n" "Symbol file not saved." msgstr "" #. STID_ENTER_NEW_FILE_NAME #: ../../strtbl.c:1258 msgid "Please enter new file name:" msgstr "śŚĆÄÉÔĆ ÎÏŚÏĆ ÉÍŃ ÆÁÊÌÁ:" #. STID_CANT_FIND_DOT_IN_SAVEFILE #: ../../strtbl.c:1260 #, c-format msgid "Cannot find '.' in curFileName in %s." msgstr "" #. STID_NO_SYM_FOUND_PIN_NOT_SAVED #: ../../strtbl.c:1262 msgid "" "No symbol found.\n" "\n" "Pin file not saved." msgstr "" #. STID_SYM_TYPE_IS_SHOULD_SAVE_PIN #: ../../strtbl.c:1264 #, c-format msgid "" "The symbol is of type %s.\n" "\n" "It should be saved as a pin file." msgstr "" #. STID_TOO_MANY_SYM_FILE_NOT_SAVED #: ../../strtbl.c:1266 msgid "" "Too many symbols.\n" "\n" "File not saved." msgstr "" "óÌÉÛËÏÍ ÍÎÏÇÏ ÓÉÍŚÏÌÏŚ.\n" "\n" "æÁÊÌ ÎĆ ÓÏÈÒÁÎĆÎ." #. STID_BAD_FIELD_IN_FUNC_ABORT_READ #: ../../strtbl.c:1268 #, c-format msgid "%s, %d: Invalid %s in %s. Read aborted." msgstr "" #. STID_UNRECOG_PAGE_STYLE #: ../../strtbl.c:1270 #, c-format msgid "Unrecognizable page style '%1d'." msgstr "" #. STID_PORTRAIT_STYLE_ASSUMED #: ../../strtbl.c:1272 msgid "Portrait style assumed." msgstr "" #. STID_CANT_FIND_COLOR_NUM_USE_CUR #: ../../strtbl.c:1274 #, c-format msgid "" "In reading state, cannot find color #%1d, use '%s' as the current color." msgstr "" #. STID_LINEWIDTH_IDX_RANGE_SET_TO_0 #: ../../strtbl.c:1276 #, c-format msgid "File's linewidth index '%1d' is out of range. Set to 0." msgstr "" #. STID_BAD_FIELD_IN_OBJ_ABORT_READ #: ../../strtbl.c:1278 #, c-format msgid "%s, %d: Invalid %s field in reading the %s object. Read aborted." msgstr "" #. STID_BAD_INPUT_WHILE_READ_PAGE #: ../../strtbl.c:1280 #, c-format msgid "Malformed input file (apparently reading page %1d). Read aborted." msgstr "" #. STID_BAD_PAGE_FILE_NAME_TRUNC_TO #: ../../strtbl.c:1282 #, c-format msgid "Invalid page file name: '%s'. Truncated to '%s'." msgstr "" #. STID_CUR_COLOR_CORRECTED_TO_BE #: ../../strtbl.c:1284 #, c-format msgid "(Current color is corrected to be '%s'.)" msgstr "" #. STID_FAIL_ALLOC_BGCOLOR_USE_DEF #: ../../strtbl.c:1286 #, c-format msgid "" "Fail to allocate the background color: '%s'. The current default background " "color '%s' is used instead." msgstr "" #. STID_ONLY_PAGE_1_IMPORTED #: ../../strtbl.c:1288 msgid "Only page 1 is imported from a multipage file." msgstr "" #. STID_ONLY_GIVEN_PAGE_IMPORTED #: ../../strtbl.c:1290 #, c-format msgid "Only page %1d is imported from a multipage file." msgstr "" #. STID_INVALID_REMOTE_FNAME #: ../../strtbl.c:1292 #, c-format msgid "Invalid remote file name '%s'." msgstr "" #. STID_CANNOT_READ_TMP_FILE #: ../../strtbl.c:1294 #, c-format msgid "Cannot read temporary file '%s'." msgstr "îĆ ŐÄÁÌÏÓŰ ĐÒÏȚÉÔÁÔŰ ŚÒĆÍĆÎÎÙÊ ÆÁÊÌ '%s'." #. STID_CANNOT_IMPORT_FILE #: ../../strtbl.c:1296 #, c-format msgid "Cannot import '%s'." msgstr "îĆ ŐÄÁÌÏÓŰ ÉÍĐÏÒÔÉÒÏŚÁÔŰ '%s'." #. STID_INVALID_PAGE_NUM #: ../../strtbl.c:1298 #, c-format msgid "Invalid page number '%s' specified." msgstr "" #. STID_USER_INTR_ABORT_DRAW #: ../../strtbl.c:1300 msgid "User interrupt. Drawing aborted." msgstr "" #. STID_FILE_VER_ABORT_IMPORT #: ../../strtbl.c:1302 #, c-format msgid "" "File version (=%1d) too large.\n" "\n" "Import aborted.\n" "\n" "You may need a more recent version of %s. Please check <URL:%s>." msgstr "" "śĆÒÓÉŃ ÆÁÊÌÁ (=%1d) ÓÌÉÛËÏÍ ŚĆÌÉËÁ.\n" "\n" "éÍĐÏÒÔ ĐÒĆÒŚÁÎ.\n" "\n" "óËÏÒĆĆ ŚÓĆÇÏ, ÎĆÏÂÈÏÄÉÍÁ ÂÏÌĆĆ ÓŚĆÖÁŃ ŚĆÒÓÉŃ %s. đÒÏŚĆÒŰÔĆ <URL:%s>." #. STID_FILE_CORRUPTED_ABORT_IMPORT #: ../../strtbl.c:1304 msgid "" "File corrupted.\n" "\n" "Import aborted." msgstr "" #. STID_FILE_IMPORTED #: ../../strtbl.c:1306 #, c-format msgid "'%s' imported." msgstr "" #. STID_SEL_AN_OBJ_FILE_TO_IMPORT #: ../../strtbl.c:1308 msgid "Please select an object file to import..." msgstr "" #. STID_CANNOT_ALLOC_BGCOLOR_USE_DEF #: ../../strtbl.c:1310 #, c-format msgid "Cannot allocate bg_color '%s', default bgcolor used." msgstr "" #. STID_CANNOT_ALLOC_FGCOLOR_USE_DEF #: ../../strtbl.c:1312 #, c-format msgid "Cannot allocate fg_color '%s', default fgcolor used." msgstr "" #. STID_CANNOT_SET_BGXPM_TO #: ../../strtbl.c:1314 #, c-format msgid "Cannot set background pixmap to '%s'." msgstr "" #. STID_COLORMAP_FLUSHED #: ../../strtbl.c:1316 msgid "Colormap flushed." msgstr "ăŚĆÔÏŚÁŃ ĐÁÌÉÔÒÁ ÏȚÉĘĆÎÁ." #. STID_FILE_VER_ABORT_OPEN #: ../../strtbl.c:1318 #, c-format msgid "" "File version (=%1d) too large.\n" "\n" "Open aborted.\n" "\n" "You may need a more recent version of %s. Please check <URL:%s>." msgstr "" #. STID_FILE_CORRUPTED_ABORT_OPEN #: ../../strtbl.c:1320 msgid "" "File corrupted.\n" "\n" "Open aborted." msgstr "" #. STID_POP_BACK_TO_NAMED #: ../../strtbl.c:1322 #, c-format msgid "Pop back to '%s'." msgstr "" #. STID_WARN_PS_BBOX_EMPTY #: ../../strtbl.c:1324 msgid "Warning: The PostScript bounding box is empty." msgstr "" #. STID_TIFFEPSI_DIRECTLY_SUPPORTED #: ../../strtbl.c:1326 #, c-format msgid "" "Obsoleted %s.%s used. Ignored.\n" "\tTiffEPSI export is now supported by %s directly as an export format." msgstr "" #. STID_INVALID_XDEF #: ../../strtbl.c:1328 #, c-format msgid "Invalid %s.%s: '%s'." msgstr "" #. STID_FAIL_EXEC_PROG_EPSI_NOT_GEN #: ../../strtbl.c:1330 #, c-format msgid "" "Fail to execute '%s'.\n" "\n" "EPSI file not generated." msgstr "" #. STID_FAIL_GET_FINFO_EPSI_NOT_GEN #: ../../strtbl.c:1332 #, c-format msgid "" "Fail to get file info for '%s'.\n" "\n" "EPSI file not generated." msgstr "" #. STID_CANNOT_OPEN_FILE_FOR_APPEND #: ../../strtbl.c:1334 #, c-format msgid "Cannot open '%s' for appending." msgstr "" #. STID_CANNOT_PRINT_REMOTE_FILE #: ../../strtbl.c:1336 msgid "" "Cannot print/export a remote file.\n" "\n" "Please first save the file and then print/export again." msgstr "" #. STID_NO_OBJ_TO_PRINT_ON_PAGE #: ../../strtbl.c:1338 #, c-format msgid "No objects to print on page %1d." msgstr "" #. STID_NO_OBJ_TO_PRINT #: ../../strtbl.c:1340 msgid "No objects to print." msgstr "" #. STID_NO_CUR_FILE_CANNOT_GEN_FORMAT #: ../../strtbl.c:1342 #, c-format msgid "" "No current file.\n" "\n" "Cannot generate %s output." msgstr "" #. STID_GENERATING_PRINT_FILE_DOTS #: ../../strtbl.c:1348 msgid "Generating print file..." msgstr "" #. STID_NO_OBJ_TO_EXPORT #: ../../strtbl.c:1350 msgid "No objects to export." msgstr "" #. STID_WRITING_TO_DOTS #: ../../strtbl.c:1352 #, c-format msgid "Writing to '%s'..." msgstr "" #. STID_GENERATING_PREVIEW_BITMAP #: ../../strtbl.c:1354 msgid "Generating preview bitmap..." msgstr "" #. STID_OUTPUT_TRUNC_IN_PRINT_TILED #: ../../strtbl.c:1356 #, c-format msgid "Output may get truncated because %s.%s is set to 1." msgstr "" #. STID_RECOMMEND_REDUCING_SETTING #: ../../strtbl.c:1358 msgid "Reducing the above setting is recommended." msgstr "" #. STID_PRINTING_WITH_GIVEN_CMD #: ../../strtbl.c:1360 #, c-format msgid "Printing with the '%s' command." msgstr "" #. STID_CANNOT_EXEC_ABORT_PRINT #: ../../strtbl.c:1362 #, c-format msgid "Cannot execute '%s', print aborted." msgstr "" #. STID_NAMED_FILE_PRINTED #: ../../strtbl.c:1364 #, c-format msgid "'%s' printed." msgstr "" #. STID_PRINT_COMPLETED #: ../../strtbl.c:1366 msgid "Print completed." msgstr "" #. STID_PRINTING_INTO_NAMED_FILE #: ../../strtbl.c:1368 #, fuzzy, c-format msgid "Printing into '%s'..." msgstr "đĆȚÁÔŰ Ó ËÏÍÁÎÄÏÊ..." #. STID_GENERATING_TIFF_PREVIEW_BMP #: ../../strtbl.c:1370 msgid "Generating TIFF preview bitmap..." msgstr "" #. STID_FORMAT_FILE_NOT_GENERATED #: ../../strtbl.c:1372 #, c-format msgid "%s file not generated." msgstr "" #. STID_CONVERTING_INTO_NAMED_FILE #: ../../strtbl.c:1374 #, c-format msgid "Converting into '%s'..." msgstr "" #. STID_CANNOT_EXEC_FORMAT_NOT_GEN #: ../../strtbl.c:1376 #, c-format msgid "Cannot execute '%s', %s file not generated." msgstr "" #. STID_FORMAT_FILE_PRINTED_INTO #: ../../strtbl.c:1378 #, c-format msgid "%s file printed into '%s'." msgstr "" #. STID_NO_CUR_FILE_CANNOT_GEN_TEXT #: ../../strtbl.c:1380 msgid "" "No current file.\n" "\n" "Cannot generate text output." msgstr "" #. STID_TEXT_OUTPUT_NOT_GEN #: ../../strtbl.c:1382 msgid "Text output not generated." msgstr "" #. STID_TEXT_PRINTED_INTO_NAMED_FILE #: ../../strtbl.c:1384 #, c-format msgid "Text file printed into '%s'." msgstr "" #. STID_TOO_MANY_COLOR_FOR_XPM_EXPORT #: ../../strtbl.c:1386 msgid "" "XPM objects that have more than 255 colors have been skipped during printing/" "exporting.\n" "\n" "You can use ReduceColors() from the ReduceNumberOfColors Submenu of the " "ImageProc Menu to reduce their number of colors." msgstr "" #. STID_CANNOT_PRINT_EPS_TILED_PAGE #: ../../strtbl.c:1388 msgid "Cannot print in EPS format in Tiled page mode." msgstr "" #. STID_PREPROCESS_PAGE_OF #: ../../strtbl.c:1390 #, c-format msgid "Preprocess page %1d of %1d..." msgstr "" #. STID_GENERATING_PAGE_OF #: ../../strtbl.c:1392 #, c-format msgid "Generating page %1d of %1d..." msgstr "" #. STID_GIVEN_PAGE_NOT_GENERATED #: ../../strtbl.c:1394 #, c-format msgid "Page %1d has not been generated." msgstr "" #. STID_PAGE_RANGE_NOT_GENERATED #: ../../strtbl.c:1396 #, c-format msgid "Pages %1d through %1d have not been generated." msgstr "" #. STID_PRINTWITHCMD_WORKS_PRINTER #: ../../strtbl.c:1398 msgid "PrintWithCmd() only works when output device is the printer." msgstr "" #. STID_ENTER_PRINT_CMD_NAME #: ../../strtbl.c:1400 msgid "Please enter print command name:" msgstr "" #. STID_NO_OBJ_SEL_NOTHING_TO_PRINT #: ../../strtbl.c:1402 msgid "" "No objects selected.\n" "\n" "Nothing printed." msgstr "" #. STID_SPECIFY_PERCENT_REDUCTION #: ../../strtbl.c:1404 msgid "Please specify percent reduction (<100) or enlargement (>100):" msgstr "" #. STID_INVALID_REDUCTION #: ../../strtbl.c:1406 #, c-format msgid "Invalid reduction '%s'." msgstr "" #. STID_NEW_REDUCTION_IS_PERCENT #: ../../strtbl.c:1408 #, c-format msgid "New reduction is %s%%." msgstr "" #. STID_NEW_ENLARGEMENT_IS_PERCENT #: ../../strtbl.c:1410 #, c-format msgid "New enlargement is %s%%." msgstr "" #. STID_OK_TO_CLEAR_WHITEBOARD #: ../../strtbl.c:1412 msgid "Okay to clear WhiteBoard?" msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_CLEAR #: ../../strtbl.c:1414 msgid "File modified, save file before clear? [ync](y)" msgstr "æÁÊÌ ÂÙÌ ÉÚÍĆÎĆÎ, ÓÏÈÒÁÎÉÔŰ ĆÇÏ ĐĆÒĆÄ ÏȚÉÓÔËÏÊ? [ync](y)" #. STID_EDITING_NO_FILE #: ../../strtbl.c:1416 msgid "Editing no file." msgstr "" #. STID_OPEN_IN_WB #: ../../strtbl.c:1418 msgid "Open() is disabled in WhiteBoard mode." msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_OPEN #: ../../strtbl.c:1420 msgid "File modified, save file before open? [ync](y)" msgstr "æÁÊÌ ÂÙÌ ÉÚÍĆÎĆÎ, ÓÏÈÒÁÎÉÔŰ ĆÇÏ ĐĆÒĆÄ ÏÔËÒÙÔÉĆÍ? [ync](y)" #. STID_SELECT_A_FILE_TO_OPEN #: ../../strtbl.c:1422 msgid "Please select a file to OPEN..." msgstr "" #. STID_INVALID_PAGE_SPECIFIED_FOR #: ../../strtbl.c:1424 #, c-format msgid "Invalid page specified for '%s'." msgstr "" #. STID_SETTEMPLATE_IN_WB #: ../../strtbl.c:1426 msgid "SetTemplate() is disabled in WhiteBoard mode." msgstr "" #. STID_SELECT_FILE_AS_TEMPLATE #: ../../strtbl.c:1428 msgid "Please select a file to be used as template..." msgstr "" #. STID_NOT_SUP_REMOTE_TEMPLATE_FILE #: ../../strtbl.c:1430 msgid "Using a remote template file is not supported." msgstr "" #. STID_CANNOT_OPEN_STILL_TEMPLATE #: ../../strtbl.c:1432 #, c-format msgid "" "Cannot open '%s' for reading.\n" "\n" "Would you still like to use it as a template file?" msgstr "" #. STID_STILL_USE_AS_TEMPLATE #: ../../strtbl.c:1434 #, c-format msgid "Would you still like to use '%s' as a template file?" msgstr "" #. STID_TEMPLATE_SET_TO #: ../../strtbl.c:1436 #, c-format msgid "Template set to '%s'." msgstr "ûÁÂÌÏÎ ŐÓÔÁÎÏŚÌĆÎ Ś '%s'." #. STID_FILE_MOD_SAVE_BEFORE_QUIT #: ../../strtbl.c:1438 msgid "File modified, save file before quit? [ync](y)" msgstr "æÁÊÌ ÂÙÌ ÉÚÍĆÎĆÎ, ÓÏÈÒÁÎÉÔŰ ĆÇÏ ĐĆÒĆÄ ŚÙÈÏÄÏÍ? [ync](y)" #. STID_ANCESTER_MOD_STILL_QUIT #: ../../strtbl.c:1440 msgid "Ancester file modified, still quitting? [ync](y)" msgstr "" #. STID_ILLEGAL_DOUBLE_BYTE_TRUNC #: ../../strtbl.c:1442 msgid "Illegal double-byte string truncated:" msgstr "" #. STID_TOOL_CANT_HANDLE_DB_FONT #: ../../strtbl.c:1444 #, c-format msgid "" "The '%s' double-byte font has min_byte1=\\%03o and max_byte1=\\%03o.\n" "%s does not know how to handle this double-byte font.\n" "Please don't use this font and e-mail this error message to %s." msgstr "" #. STID_FAIL_LOAD_FONT_FONT_SUBS #: ../../strtbl.c:1446 #, c-format msgid "" "Fail to load the following font: '%s'.\n" "\n" "%s-%1d substituted for %s-%1d." msgstr "" #. STID_FONT_SUBSTITUTED #: ../../strtbl.c:1448 #, c-format msgid "%s-%1d substituted for %s-%1d." msgstr "" #. STID_CANNOT_GET_IMAGE_OF_SIZE #: ../../strtbl.c:1450 #, c-format msgid "Cannot get image of size [%1dx%1d]. System resource may be low." msgstr "" #. STID_UNRECOG_CHARCODE_DISCARD #: ../../strtbl.c:1452 #, c-format msgid "Unrecognized character code \\03%o. Character discarded." msgstr "" #. STID_CANT_FIND_FONT_USE_ALT #: ../../strtbl.c:1454 #, c-format msgid "Cannot find the %s font. Use '%s' instead." msgstr "" #. STID_BAD_XDEF_CANT_FIND_EQ_SKIP #: ../../strtbl.c:1456 #, c-format msgid "Invalid entry '%s' (cannot find '=') in %s.%s, skipped." msgstr "" #. STID_BAD_XDEF_MISS_FONT_NAME_SKIP #: ../../strtbl.c:1458 #, c-format msgid "Invalid entry '%s' (missing font name) in %s.%s, skipped." msgstr "" #. STID_MISS_FONT_SPEC_IN_XDEF #: ../../strtbl.c:1460 #, c-format msgid "Missing font specification in '%s.%s'." msgstr "" #. STID_INVALID_X_FONT_INFO_IN_XDEF #: ../../strtbl.c:1462 #, c-format msgid "Invalid X font information in '%s.%s': '%s'." msgstr "" #. STID_INVALID_X_REG_INFO_IN_XDEF #: ../../strtbl.c:1464 #, c-format msgid "Invalid X registry information in '%s.%s': '%s'." msgstr "" #. STID_INVALID_PS_INFO_IN_XDEF #: ../../strtbl.c:1466 #, c-format msgid "Invalid PS font information in '%s.%s': '%s'." msgstr "" #. STID_ERR_PROCESS_FONT_USE_ALT #: ../../strtbl.c:1468 #, c-format msgid "" "Warning: Error in processing %s.%s: '%s'.\n" "\t'%s-%s-*-%%d-*-*-*-*-*-%s' used." msgstr "" #. STID_INVALID_SB_FONT_USE_DB_FONT #: ../../strtbl.c:1470 #, c-format msgid "Invalid %s.%s: '%s'. Please use a non-double-byte font." msgstr "" #. STID_ERR_PROCESS_SIZE_USE_DEF_SIZE #: ../../strtbl.c:1472 #, c-format msgid "Warning: Error in processing %s.%s. Default font sizes used." msgstr "" #. STID_OBSOLETE_XDEF_USE_ALT #: ../../strtbl.c:1474 #, c-format msgid "Obsoleted %s.%s used. Please use %s.%s instead." msgstr "" #. STID_CANT_OPEN_DEF_MSG_FONT_ABORT #: ../../strtbl.c:1476 #, c-format msgid "Cannot open the Default(Msg)Font '%s'." msgstr "" #. STID_WARN_VERY_SMALL_DEF_FONT #: ../../strtbl.c:1478 #, c-format msgid "" "Warning: Very small default font width/height (%1d/%1d).\n" "\tPossibly a problem with the font path.\n" "\tSet default font width to 9 and height to 14 as a temporary fix." msgstr "" #. STID_CANT_OPEN_RULER_FONT_ABORT #: ../../strtbl.c:1480 #, c-format msgid "Cannot open the RulerFont '%s'." msgstr "" #. STID_WARN_VERY_SMALL_RULER_FONT #: ../../strtbl.c:1482 #, c-format msgid "" "Warning: Very small ruler font width/height (%1d/%1d).\n" "\tPossibly a problem with the font path.\n" "\tSet ruler font width to 7 and height to 12 as a temporary fix." msgstr "" #. STID_CANNOT_SET_INITIAL_FONT_TO #: ../../strtbl.c:1484 #, c-format msgid "Warning: Cannot set InitialFont to '%s'." msgstr "" #. STID_CANT_SET_INIT_FONTSTYLE_ALT #: ../../strtbl.c:1486 #, c-format msgid "" "Warning: Cannot set InitialFontStyle to '%s'. '%s' font is used instead." msgstr "" #. STID_CANT_SET_INIT_FONTJUST_ALT #: ../../strtbl.c:1488 #, c-format msgid "Warning: Cannot set InitialFontJust to '%s'. '%s' is used instead." msgstr "" #. STID_CANT_SET_INIT_FONTSIZE_ALT #: ../../strtbl.c:1490 #, c-format msgid "Warning: Cannot set InitialFontSize to '%s'. '%s' is used instead." msgstr "" #. STID_FONT_NOT_AVAILABLE #: ../../strtbl.c:1492 #, c-format msgid "The '%s' font is not available." msgstr "" #. STID_CANT_CHANGE_SIZEPT_TO_USE_ALT #: ../../strtbl.c:1494 #, c-format msgid "Cannot change size to %1dpt. %1dpt used." msgstr "" #. STID_CANT_CHANGE_SIZE_TO_USE_ALT #: ../../strtbl.c:1496 #, c-format msgid "Cannot change size to %1d. %1d used." msgstr "" #. STID_INVALID_VSPACE_NOT_CHANGED #: ../../strtbl.c:1498 msgid "" "Invalid vertical spacing for a text object. Vertical spacing for that " "object not changed." msgstr "" #. STID_VSPACE_TOO_SMALL_NOT_CHANGED #: ../../strtbl.c:1500 msgid "Text vertical spacing too small. No change." msgstr "" #. STID_ENTER_POINT_SIZE #: ../../strtbl.c:1502 msgid "Please enter point size:" msgstr "" #. STID_ENTER_FONT_SIZE #: ../../strtbl.c:1504 msgid "Please enter font size:" msgstr "" #. STID_FONT_SIZE_TOO_SMALL #: ../../strtbl.c:1506 #, c-format msgid "Font size '%s' too small." msgstr "" #. STID_FONT_SUB_NO_SUCH_FONT_USR_DEF #: ../../strtbl.c:1508 #, c-format msgid "" "%s substituted for font number %d.\n" "\n" "There is no such font. Use default." msgstr "" #. STID_NO_KANJI_FONT_GIVEN_NUMBER #: ../../strtbl.c:1510 #, c-format msgid "There is no kanji-font number %d." msgstr "" #. STID_FAIL_TO_CONN_TO_HOST #: ../../strtbl.c:1512 #, c-format msgid "%s: Fail to connect to server on '%s'." msgstr "" #. STID_NETWORK_READ_ERROR #: ../../strtbl.c:1514 #, c-format msgid "%s: Network read error." msgstr "" #. STID_NETWORK_ERROR #: ../../strtbl.c:1516 #, c-format msgid "%s: Network error." msgstr "" #. STID_CONN_ABORT_BY_USER #: ../../strtbl.c:1518 #, c-format msgid "%s: Aborted by the user." msgstr "" #. STID_CONN_TERM_BY_SERVER #: ../../strtbl.c:1520 #, c-format msgid "%s: Connection terminated by the server." msgstr "" #. STID_FAIL_TO_OPEN_DATA_SOCKET #: ../../strtbl.c:1522 #, c-format msgid "%s: Fail to open a socket for FTP data port." msgstr "" #. STID_USING_METRIC_SYSTEM #: ../../strtbl.c:1524 msgid "Using Metric system." msgstr "" #. STID_USING_ENGLISH_SYSTEM #: ../../strtbl.c:1526 msgid "Using English system." msgstr "" #. STID_SNAP_NOT_ON_GRID_SZ_SAME #: ../../strtbl.c:1528 msgid "Snap is not on, grid size not changed." msgstr "" #. STID_AT_MAX_GRID_GRID_SZ_SAME #: ../../strtbl.c:1530 msgid "Already at maximum grid, grid size not changed." msgstr "" #. STID_AT_MIN_GRID_GRID_SZ_SAME #: ../../strtbl.c:1532 msgid "Already at minimum grid, grid size not changed." msgstr "" #. STID_SNAP_TO_GRID_ACTV #: ../../strtbl.c:1534 msgid "Snapping to grid point activated." msgstr "" #. STID_SNAP_TO_GRID_DISABLED #: ../../strtbl.c:1536 msgid "Snapping to grid point disabled." msgstr "" #. STID_WILL_PRINT_IN_COLOR #: ../../strtbl.c:1538 msgid "Will print in color (PS and pixmap)." msgstr "" #. STID_WILL_PRINT_IN_BW #: ../../strtbl.c:1540 msgid "Will print in black-and-white (PS and bitmap)." msgstr "" #. STID_CONSTRAINED_MOVE #: ../../strtbl.c:1542 msgid "Constrained move." msgstr "" #. STID_UNCONSTRAINED_MOVE #: ../../strtbl.c:1544 msgid "Unconstrained move." msgstr "" #. STID_WILL_DISPLAY_XBM_XPM #: ../../strtbl.c:1546 msgid "Will display bitmap/pixmap." msgstr "" #. STID_WILL_NOT_DISPLAY_XBM_XPM #: ../../strtbl.c:1552 msgid "Will not display bitmap/pixmap." msgstr "" #. STID_GRAY_SCALE_IN_BW_PRINTING #: ../../strtbl.c:1554 msgid "Gray scale enabled in black&white printing." msgstr "" #. STID_NO_GRAY_SCALE_IN_BW_PRINTING #: ../../strtbl.c:1556 msgid "Gray scale disabled in black&white printing." msgstr "" #. STID_CURRENT_SPEC_IS #: ../../strtbl.c:1558 #, c-format msgid "( current spec: '%s' )" msgstr "" #. STID_ENTER_MEASURE_UNIT_SPEC #: ../../strtbl.c:1560 msgid "" "Please enter '<num> {pixel|cm|in}/<unit>' (e.g., 36 in/yd or 0.1 in/mil):" msgstr "" #. STID_WILL_EXPORT_FORMAT_FILE #: ../../strtbl.c:1562 #, c-format msgid "Will export %s file." msgstr "" #. STID_PRINT_DEV_SET_TO_PRINTER #: ../../strtbl.c:1564 msgid "Print device set to printer." msgstr "" #. STID_WILL_EXPORT_EPS_FILE #: ../../strtbl.c:1566 msgid "Will export Encapsulated PostScript (LaTeX-Figure) file." msgstr "" #. STID_WILL_EXPORT_RAW_PS_FILE #: ../../strtbl.c:1568 msgid "Will export raw PostScript file." msgstr "" #. STID_WILL_EXPORT_XPM_FILE #: ../../strtbl.c:1570 #, fuzzy msgid "Will export X11 Pixmap file." msgstr "éÍĐÏÒÔ XPixmap..." #. STID_WILL_EXPORT_XBM_FILE #: ../../strtbl.c:1572 #, fuzzy msgid "Will export X11 Bitmap file." msgstr "éÍĐÏÒÔ Xbitmap..." #. STID_WILL_EXPORT_TEXT_FILE #: ../../strtbl.c:1574 msgid "Will export ASCII text file." msgstr "" #. STID_WILL_EXPORT_EPSI_FILE #: ../../strtbl.c:1576 msgid "Will export EPSI file (EPS with preview bitmap)." msgstr "" #. STID_WILL_EXPORT_GIF_FILE #: ../../strtbl.c:1578 msgid "Will export GIF/ISMAP (needs xpm->gif filter) file." msgstr "" #. STID_WILL_EXPORT_HTML_FILE #: ../../strtbl.c:1580 msgid "Will export HTML (with Client-side imagemap) file." msgstr "" #. STID_WILL_EXPORT_PDF_FILE #: ../../strtbl.c:1582 msgid "Will export PDF (needs ps->pdf filter) file." msgstr "" #. STID_WILL_EXPORT_TIFFEPSI_FILE #: ../../strtbl.c:1584 msgid "Will export DOS/Windows EPS/EPSI file." msgstr "" #. STID_ONE_MOTION_SEL_MOVE_MODE #: ../../strtbl.c:1586 msgid "Click-select-move in one motion mode selected." msgstr "" #. STID_CLICK_SEL_CLICK_MOVE_MODE #: ../../strtbl.c:1588 msgid "Click-select-click-move mode selected." msgstr "" #. STID_CANT_TOGGLE_COLOR_LAYER_BW #: ../../strtbl.c:1590 msgid "Cannot toggle color layers for a black and white display." msgstr "" #. STID_STRETCHABLE_TEXT_MODE #: ../../strtbl.c:1592 msgid "Text objects are stretchable." msgstr "" #. STID_NON_STRETCHABLE_TEXT_MODE #: ../../strtbl.c:1594 msgid "Text objects are not stretchable." msgstr "" #. STID_TRANS_PAT_MODE #: ../../strtbl.c:1596 ../../strtbl.c:2516 msgid "Fill and pen patterns are transparent." msgstr "" #. STID_NON_TRANS_PAT_MODE #: ../../strtbl.c:1598 ../../strtbl.c:2514 msgid "Fill and pen patterns are opaque." msgstr "" #. STID_ALREADY_AT_DEF_ZOOM #: ../../strtbl.c:1600 msgid "Already at the default zoom." msgstr "" #. STID_ALREADY_AT_HIGHEST_MAG #: ../../strtbl.c:1602 msgid "Already at highest magnification, can no longer zoom in." msgstr "" #. STID_CURSOR_IGNORED_CSBTN1 #: ../../strtbl.c:1604 msgid "(the cursor position is ignored even though <Cntrl><Shift>Btn1 is used)" msgstr "" #. STID_ZOOMIN_AROUND_EDIT_TEXT #: ../../strtbl.c:1606 msgid "(Zooming in around text being edited..." msgstr "" #. STID_SEL_ZOOM_CENTER #: ../../strtbl.c:1608 msgid "Select zoom center" msgstr "" #. STID_ZOOMIN_CANCEL_BY_USER #: ../../strtbl.c:1610 msgid "ZoomIn canceled by the user." msgstr "" #. STID_AT_PAPER_EDGE_CANT_ZOOMOUT #: ../../strtbl.c:1612 msgid "Already at paper boundaries, can no longer zoom out." msgstr "" #. STID_PAGE_STYLE_CHANGE_TO_LAND #: ../../strtbl.c:1614 msgid "Page style changed to LandScape." msgstr "" #. STID_PAGE_STYLE_CHANGE_TO_PORT #: ../../strtbl.c:1616 msgid "Page style changed to Portrait." msgstr "" #. STID_WARN_PIN_NOT_SUPPORTED #: ../../strtbl.c:1618 msgid "Warning: Pins are not supported, yet." msgstr "" #. STID_ONE_SIMPLE_GROUP_UNGROUP_ANY #: ../../strtbl.c:1620 msgid "" "Selected object is not a (simple) grouped object.\n" "\n" "Ungroup anyway?" msgstr "" #. STID_ALL_SIMPLE_GROUP_UNGROUP_ANY #: ../../strtbl.c:1622 msgid "" "None of the selected objects are (simple) grouped objects.\n" "\n" "Ungroup anyway?" msgstr "" #. STID_SEL_OBJ_ARE_UNGROUPED #: ../../strtbl.c:1624 msgid "Selected objects are ungrouped." msgstr "" #. STID_NO_OBJ_TO_LOCK #: ../../strtbl.c:1626 msgid "No object to lock." msgstr "" #. STID_CANNOT_LOCK_IN_VERTEX_MODE #: ../../strtbl.c:1628 msgid "Cannot lock in vertex mode." msgstr "" #. STID_SEL_OBJ_ARE_LOCKED #: ../../strtbl.c:1630 msgid "Selected objects are locked." msgstr "" #. STID_NO_OBJ_TO_UNLOCK #: ../../strtbl.c:1632 msgid "No object to unlock." msgstr "" #. STID_CANNOT_UNLOCK_IN_VERTEX_MODE #: ../../strtbl.c:1634 msgid "Cannot unlock in vertex mode." msgstr "" #. STID_SEL_OBJ_ARE_UNLOCKED #: ../../strtbl.c:1636 msgid "Selected objects are unlocked." msgstr "" #. STID_TOOL_VERSION #: ../../strtbl.c:1638 #, c-format msgid "%s Version %s" msgstr "" #. STID_TOOL_VERSION_SPC_BUILD #: ../../strtbl.c:1640 #, c-format msgid "%s Version %s (%s)" msgstr "" #. STID_TOOL_VERSION_PATCH #: ../../strtbl.c:1642 #, c-format msgid "%s Version %s (patchlevel %1d)" msgstr "" #. STID_TOOL_VERSION_PATCH_SPC_BUILD #: ../../strtbl.c:1644 #, c-format msgid "%s Version %s (patchlevel %1d - %s)" msgstr "" #. STID_HYPER_TEXT_HOME #: ../../strtbl.c:1646 #, c-format msgid "" "\n" "\n" "WWW Hypertext Home Page: %s" msgstr "" #. STID_LATEST_REL_INFO #: ../../strtbl.c:1648 #, fuzzy, c-format msgid "" "\n" "\n" "Latest Release Information: %s" msgstr "éÎÆÏÒÍÁĂÉŃ Ï ĐÏÓÌĆÄÎĆÊ ŚĆÒÓÉÉ" #. STID_HYPER_GRAPHICS_INFO #: ../../strtbl.c:1650 #, c-format msgid "" "\n" "\n" "WWW Hyper-Graphics Home Page: %s" msgstr "" #. STID_MAILING_LIST_INFO #: ../../strtbl.c:1652 #, c-format msgid "" "\n" "\n" "The tgif announcement mailing is %s. To join, please send an empty message " "to %s (you do not need a Yahoo ID to join). The previous tgif mailing list, " "%s, is not longer active." msgstr "" #. STID_SEND_BUG_REPORT_TO #: ../../strtbl.c:1654 #, c-format msgid "" "\n" "\n" "Please send bug reports to %s." msgstr "" #. STID_OPEN_URL_FAIL_USE_BROWSER #: ../../strtbl.c:1656 #, c-format msgid "" "Fail to open '%s' for reading.\n" "\n" "Please view %s with a web browser." msgstr "" #. STID_FIND_VER_FAIL_USE_BROWSER #: ../../strtbl.c:1658 #, c-format msgid "" "Fail to find version information in '%s'.\n" "\n" "Please view %s with a web browser." msgstr "" #. STID_TOOL_CUR_VER_IS_DIFF_INFO #: ../../strtbl.c:1660 #, c-format msgid "" "%s is currently at %s and this %s is Version %s.\n" "\n" "For download information, please visit %s with a web browser." msgstr "" #. STID_TOOL_CUR_VER_IS_DIFF_SPC_INFO #: ../../strtbl.c:1662 #, c-format msgid "" "%s is currently at %s and this %s is Version %s (%s).\n" "\n" "For download information, please visit %s with a web browser." msgstr "" #. STID_TOOL_CUR_VER_PATCH_INFO #: ../../strtbl.c:1664 #, c-format msgid "" "%s is currently at %s and this %s is Version %s Patchlevel %1d.\n" "\n" "For download information, please visit %s with a web browser." msgstr "" #. STID_TOOL_CUR_VER_PATCH_SPC_INFO #: ../../strtbl.c:1666 #, c-format msgid "" "%s is currently at %s and this %s is Version %s Patchlevel %1d (%s).\n" "\n" "For download information, please visit %s with a web browser." msgstr "" #. STID_CANT_DOWNLOAD_VER_USE_BROWSER #: ../../strtbl.c:1668 #, c-format msgid "" "Cannot download '%s' to get version information.\n" "\n" "Please view %s with a web browser." msgstr "" #. STID_FAIL_TO_CONN_TO_HOST_PORT #: ../../strtbl.c:1670 #, c-format msgid "%s: Fail to connect to server on '%s:%1d'." msgstr "" #. STID_LINES_TOO_LONG_CONTENT_LENGTH #: ../../strtbl.c:1672 #, c-format msgid "%s: Unexpected lines too long detected while reading content." msgstr "" #. STID_FAIL_TO_SEND_REQ #: ../../strtbl.c:1674 #, c-format msgid "%s: Fail to send requests." msgstr "" #. STID_INVALID_FORMAT_IN_HEADER #: ../../strtbl.c:1676 #, c-format msgid "%s: Invalid format in the header." msgstr "" #. STID_CHECK_FONT_FAILED_FOR_BROWSE #: ../../strtbl.c:1678 msgid "" "The current font/size/style is not available for labeling objects.\n" "\n" "Please use a different font/size/style for the browse operation you've " "selected." msgstr "" #. STID_ERROR_ENCOUNTERED_WHILE_RECV #: ../../strtbl.c:1680 #, c-format msgid "%s: Error encountered in receiving responses." msgstr "" #. STID_SINGLE_XPM_IMGPROC #: ../../strtbl.c:1682 #, c-format msgid "" "The command you have just selected: '%s' can only work with a single X11 " "Pixmap object." msgstr "" #. STID_USER_INTR #: ../../strtbl.c:1684 msgid "User interrupt." msgstr "" #. STID_CANNOT_IMPORT_XPM_FILE #: ../../strtbl.c:1686 #, c-format msgid "Cannot import X11 Pixmap file '%s'." msgstr "" #. STID_MAY_USED_UP_COLORS_RETRY #: ../../strtbl.c:1688 msgid "" "May have used up all the colors.\n" "\n" "Would you like to retry it once more?" msgstr "" #. STID_ENTER_PAIR_COLORS_INTERPOLATE #: ../../strtbl.c:1690 msgid "" "Please enter a pair of colors (from dark to bright) for interpolation (e.g., " "Black Yellow):" msgstr "" #. STID_GIVEN_IS_NOT_A_VALID_COLOR #: ../../strtbl.c:1692 #, c-format msgid "'%s' is not a valid color." msgstr "" #. STID_ENTER_VAL_MINUS_PLUS_ONE_BW #: ../../strtbl.c:1694 msgid "Please enter a value between -1.0 (all black) and +1.0 (all white):" msgstr "" #. STID_FAIL_TO_PARSE_FOR_A_VAL #: ../../strtbl.c:1696 #, c-format msgid "Fail to parse '%s' for a value." msgstr "" #. STID_ENTER_VAL_MINUS_PLUS_ONE_SAT #: ../../strtbl.c:1698 msgid "Please enter a value between -1.0 (gray) and +1.0 (saturated):" msgstr "" #. STID_ENTER_VAL_FOR_CHANGE_HUE #: ../../strtbl.c:1700 msgid "" "Please enter two pairs of (color,angle) values: (e.g., \"red 60 green 60\" " "maps all reddish to greenish colors)" msgstr "" #. STID_FAIL_TO_PARSE_FOR_4_VAL #: ../../strtbl.c:1702 #, c-format msgid "Fail to parse '%s' for 4 values." msgstr "" #. STID_ENTER_VAL_FOR_CONTRAST_ENH #: ../../strtbl.c:1704 msgid "Please enter a non-negative value (1.0 means no adjustment):" msgstr "" #. STID_GIVEN_NEG_VAL_NOT_ALLOWED #: ../../strtbl.c:1706 #, c-format msgid "Nevative value: '%s' is not allowed." msgstr "" #. STID_ENTER_VAL_FOR_COLOR_BAL #: ../../strtbl.c:1708 msgid "Please enter non-negative R G B factors (1.0 1.0 1.0 means no change):" msgstr "" #. STID_FAIL_TO_PARSE_FOR_3_VAL #: ../../strtbl.c:1710 #, c-format msgid "Fail to parse '%s' for 3 values." msgstr "" #. STID_ENTER_VAL_FOR_GAMMA #: ../../strtbl.c:1712 msgid "Please enter a gamma value (1.0 means no change, 2.2 is brighter):" msgstr "" #. STID_SEL_TOO_THIN_FLAT_FOR_EDGE #: ../../strtbl.c:1714 msgid "Selected object is too thin or flat for edge detection." msgstr "" #. STID_SEL_TOO_THIN_FLAT_FOR_EMBOSS #: ../../strtbl.c:1716 msgid "Selected object is too thin or flat for embossing." msgstr "" #. STID_ENTER_NUM_COLORS_TO_REDUCE_TO #: ../../strtbl.c:1718 #, c-format msgid "Please enter the number of colors to reduce to (from %1d colors):" msgstr "" #. STID_NUM_COLORS_BETWEEN_2_N_GIVEN #: ../../strtbl.c:1720 #, c-format msgid "Number of colors: '%s' must be between 2 and %1d." msgstr "" #. STID_SEL_XPM_FILE_FOR_RED_COLORS #: ../../strtbl.c:1722 msgid "Please select an X11 Pixmap file for colors..." msgstr "" #. STID_INVALID_GIVEN_XPM_FILE #: ../../strtbl.c:1724 #, c-format msgid "Invalid X11 Pixmap file '%s.'" msgstr "" #. STID_Q_FS_ERROR_DIFFUSE #: ../../strtbl.c:1726 msgid "Would you like to apply Floyd-Steinberg error diffusion (slow)?" msgstr "" #. STID_ENTER_NUM_BITS_IN_RGB #: ../../strtbl.c:1728 #, c-format msgid "" "Please enter number of bits to use for R, G, and B (current [R G B] levels " "are [%1d %1d %1d]):" msgstr "" #. STID_RGB_LEVELS_CHANGED_TO #: ../../strtbl.c:1730 #, c-format msgid "Levels changed to: [%1d %1d %1d]." msgstr "" #. STID_BAD_VAL_SUM_RGB_LEVEL #: ../../strtbl.c:1732 #, c-format msgid "Bad values: '%s'. R+G+B must be <= 8." msgstr "" #. STID_BAD_VAL_GT_0_RGB_LEVEL #: ../../strtbl.c:1734 #, c-format msgid "Bad values: '%s'. Values must all be > 0." msgstr "" #. STID_RGB_LEVELS_ARE #: ../../strtbl.c:1736 #, c-format msgid "[R G B] levels are [%1d %1d %1d]." msgstr "" #. STID_ENTER_INT_AMT_TO_SPREAD #: ../../strtbl.c:1738 msgid "Please enter an integer amount to spread:" msgstr "" #. STID_SEL_TOO_THIN_FLAT_FOR_SHARPEN #: ../../strtbl.c:1740 msgid "Selected object is too thin or flat for sharpening." msgstr "" #. STID_SEL_TOO_THIN_FLAT_FOR_BLUR #: ../../strtbl.c:1742 #, c-format msgid "Selected object is too thin or flat for %1d by %1d blurring." msgstr "" #. STID_IMAGE_PROC_CANT_USE_XFORMED #: ../../strtbl.c:1744 #, c-format msgid "" "'%s' cannot operate on stretched/rotated/sheared pixmap objects.\n" "\n" "You can use '%s' in the ImageProc Menu to regenerate these objects." msgstr "" #. STID_SEL_3_XPM_FOR_IMAGEPROC_CMD #: ../../strtbl.c:1746 #, c-format msgid "Please select 3 X11 Pixmap object for the '%s' command." msgstr "" #. STID_SEL_2_XPM_FOR_IMAGEPROC_CMD #: ../../strtbl.c:1748 #, c-format msgid "Please select 2 X11 Pixmap object for the '%s' command." msgstr "" #. STID_PICK_PT_WITHIN_IMAGE_BOUND #: ../../strtbl.c:1750 msgid "Please pick a starting point within the image boundary" msgstr "" #. STID_IMG_TOO_SMALL_FOR_IMAGEPROC_CMD #: ../../strtbl.c:1756 #, c-format msgid "Image is too small for the '%s' command." msgstr "" #. STID_NO_WARPING #: ../../strtbl.c:1758 msgid "No warping." msgstr "" #. STID_START_LINE_SEG_DOTS #: ../../strtbl.c:1760 #, fuzzy msgid "Start line segment..." msgstr "őÓÔÁÎÏŚÉÔŰ ÛÁÇ ĐÏŚÏÒÏÔÁ..." #. STID_ENDT_LINE_SEG_DOTS #: ../../strtbl.c:1762 msgid "End line segment..." msgstr "" #. STID_ENTER_IMAGE_SIZE_IN_PIX_RC #: ../../strtbl.c:1764 msgid "Please enter image size in pixels: [Col x Row]" msgstr "" #. STID_FAIL_TO_EXECUTE_CMD #: ../../strtbl.c:1766 #, c-format msgid "Fail to execute '%s'." msgstr "" #. STID_ENTER_CMD_OP_FOR_BGGEN #: ../../strtbl.c:1768 msgid "Please enter command options for 'bggen' (e.g., 'blue magenta'):" msgstr "" #. STID_NEW_XPM_WH_GENERATED #: ../../strtbl.c:1770 #, c-format msgid "New X11 Pixmap object (%1dx%1d) generated." msgstr "" #. STID_ENTER_GRAY_LEVELS_222 #: ../../strtbl.c:1772 msgid "Please enter number of gray levels (between 2 and 222):" msgstr "" #. STID_INVALID_GIVEN_VALUE_ENTERED #: ../../strtbl.c:1774 #, c-format msgid "Invalid value '%s' entered." msgstr "" #. STID_ENTER_COLOR_FOR_RECT_BGGEN #: ../../strtbl.c:1776 msgid "Please enter a color for the rectangle (e.g., magenta, #808080):" msgstr "" #. STID_CANNOT_PARSE_NAMED_COLOR #: ../../strtbl.c:1778 #, c-format msgid "Cannot parse color: '%s'." msgstr "" #. STID_XPM_NOT_XFORMED_REGEN_ANYWAY #: ../../strtbl.c:1780 msgid "" "Selected object is not stretched/rotated/sheared.\n" "\n" "Would you like to regenerate it anyway?" msgstr "" #. STID_DRAG_A_RECT_TO_CROP #: ../../strtbl.c:1782 msgid "Please drag out a rectangular area to crop..." msgstr "" #. STID_START_CROP_IMAGE #: ../../strtbl.c:1784 #, fuzzy msgid "Start crop image" msgstr "ïÂÒĆÚÁÔŰ ĐÏ ÏÂÌÁÓÔÉ" #. STID_END_CROP_IMAGE #: ../../strtbl.c:1786 #, fuzzy msgid "End crop image" msgstr "ïÂÒĆÚÁÔŰ ĐÏ ÏÂÌÁÓÔÉ" #. STID_ABORT_CROP_IMAGE #: ../../strtbl.c:1788 #, fuzzy msgid "Abort crop image" msgstr "ïÂÒĆÚÁÔŰ ĐÏ ÏÂÌÁÓÔÉ" #. STID_SELECT_A_COLOR #: ../../strtbl.c:1790 #, fuzzy msgid "Select a color" msgstr "śÙÄĆÌÉÔŰ ŚÓĆ" #. STID_SEL_A_COLOR_TO_USE_AS_CUR #: ../../strtbl.c:1792 msgid "Please select a color to be used as the current color..." msgstr "" #. STID_SEL_AREA_NOT_INTERSECT_IMAGE #: ../../strtbl.c:1794 msgid "Selected area does not intersect selected image." msgstr "" #. STID_SEL_PT_NOT_ON_IMAGE #: ../../strtbl.c:1796 msgid "Selected point is not on the selected image." msgstr "" #. STID_ONE_PRIM_FOR_IMAGEPROC_CMD #: ../../strtbl.c:1798 #, c-format msgid "Please select only one primitive object for the '%s' command." msgstr "" #. STID_DARG_TO_FILL_AN_AREA #: ../../strtbl.c:1800 msgid "Drag to fill an area..." msgstr "" #. STID_SEL_A_COLOR_TO_BE_REPLACED #: ../../strtbl.c:1802 msgid "Please select a color to be replaced by the current color..." msgstr "" #. STID_SEL_A_COLOR_TO_REPLACE #: ../../strtbl.c:1804 msgid "Select a color to replace" msgstr "" #. STID_BTN1_FLOODFILL_BTN3_SET_COLOR #: ../../strtbl.c:1806 msgid "<Btn1>: Flood-fill, <Btn3>: Set a pixel to current color." msgstr "" #. STID_ESC_TO_FINISH #: ../../strtbl.c:1808 msgid "<ESC> to finish." msgstr "" #. STID_FLOOD_FILL #: ../../strtbl.c:1810 #, fuzzy msgid "Flood-fill" msgstr "úÁÌÉÔŰ" #. STID_SET_A_PIXEL #: ../../strtbl.c:1812 msgid "Set a pixel" msgstr "" #. STID_NO_CONTOUR_CAN_BE_GEN_HERE #: ../../strtbl.c:1814 msgid "No contour can be generated from here." msgstr "" #. STID_SEL_A_COLOR_TO_BE_TRACED #: ../../strtbl.c:1816 msgid "Please select a color to be traced..." msgstr "" #. STID_START_CONTOUR #: ../../strtbl.c:1818 #, fuzzy msgid "Start contour" msgstr "óÏÚÄÁÔŰ ËÏÎÔŐÒ" #. STID_INVALID_XDEF_RNG_USE_ALT_VAL #: ../../strtbl.c:1820 #, c-format msgid "" "Invalid %s.%s: '%s', (must be between %1d and %1d), %1d is used instead." msgstr "" #. STID_VAL_TOO_LARGE_IN_XDEF_USE_ALT #: ../../strtbl.c:1822 #, c-format msgid "Values too large in %s.%s: '%s', '%s' is used instead." msgstr "" #. STID_VAL_TOO_SMALL_IN_XDEF_USE_ALT #: ../../strtbl.c:1824 #, c-format msgid "Values too small in %s.%s: '%s', '%s' is used instead." msgstr "" #. STID_INVALID_GIVEN_PATH_MUST_FULL #: ../../strtbl.c:1826 #, c-format msgid "Invalid path: '%s'. Must use a full path name." msgstr "" #. STID_CANNOT_SET_LOCALE_ENV_VARS #: ../../strtbl.c:1828 msgid "Cannot set to the locale specified by the environment variables." msgstr "" #. STID_XT_CANNOT_SET_LOCALE_ENV_VARS #: ../../strtbl.c:1830 msgid "" "Xtoolkit cannot set to the locale specified by the environment variables." msgstr "" #. STID_XLIB_CANT_SET_LOCALE_ENV_VARS #: ../../strtbl.c:1832 msgid "Xlib cannot set to the locale specified by the environment variables." msgstr "" #. STID_CANT_SET_LOCALE_MODIFIERS #: ../../strtbl.c:1834 msgid "Cannot set locale modifiers." msgstr "" #. STID_LOCALE_DIR_NOT_EXIST_USE_XDEF #: ../../strtbl.c:1836 #, c-format msgid "" "Locale directory '%s' does not exist. Please specify locale direory with %s." "%s." msgstr "" #. STID_WARN_CANT_PUTENV_GIVEN #: ../../strtbl.c:1838 #, c-format msgid "Warning: Cannot putenv(%s)." msgstr "" #. STID_CANT_OPEN_DISPLAY_ABORT #: ../../strtbl.c:1840 msgid "Could not open the default display. Abort." msgstr "" #. STID_CANT_OPEN_GIVEN_DPY_ABORT #: ../../strtbl.c:1842 #, c-format msgid "Could not open display '%s'. Abort." msgstr "" #. STID_CUR_EMPTY_FILE_IS #: ../../strtbl.c:1844 #, c-format msgid "Current (empty) file is '%s'." msgstr "" #. STID_LEFT_STEP_MID_RUN_RIGHT_STOP #: ../../strtbl.c:1846 msgid "Left:step. Middle:run. Right:stop." msgstr "" #. STID_CANT_FIND_POLY_WITH_GIVEN_ID #: ../../strtbl.c:1848 #, c-format msgid "Cannot find poly with id=%1d." msgstr "" #. STID_CANT_FIND_OBJ_WITH_GIVEN_ID #: ../../strtbl.c:1850 #, c-format msgid "Cannot find object with id=%1d." msgstr "" #. STID_CANT_FIND_ATTR_NAME_AND_COLOR #: ../../strtbl.c:1852 #, c-format msgid "Cannot find attr name '%s' and color '%s'." msgstr "" #. STID_BAD_FLTR_SPEC_DEF #: ../../strtbl.c:1854 #, c-format msgid "" "Invalid %s.%s: '%s'.\n" "\n" "Format is '<name> <extensions> <filter spec>', e.g.,\n" "\n" " JPEG jpg;jpeg djpeg -gif -colors 222 %%s | giftopnm | ppmtoxpm" msgstr "" #. STID_BAD_FLTR_SPEC_MISS_PERC_S #: ../../strtbl.c:1856 #, c-format msgid "" "Invalid %s.%s: '%s' (missing %%s).\n" "\n" "Format is '<name> <extensions> <filter spec>', e.g.,\n" "\n" " JPEG jpg;jpeg djpeg -gif -colors 222 %%s | giftopnm | ppmtoxpm" msgstr "" #. STID_BAD_FLTR_SPEC_MANY_PERC_S #: ../../strtbl.c:1858 #, c-format msgid "" "Invalid %s.%s: '%s' (too many %%s).\n" "\n" "Format is '<name> <extensions> <filter spec>', e.g.,\n" "\n" " JPEG jpg;jpeg djpeg -gif -colors 222 %%s | giftopnm | ppmtoxpm" msgstr "" #. STID_BAD_XDEF_MUST_BE_GT_0 #: ../../strtbl.c:1860 #, c-format msgid "Invalid %s.%s: '%s'. Value must be > 0." msgstr "" #. STID_CANT_FIND_XDEF_CONT_LOOK_FLTR #: ../../strtbl.c:1862 #, c-format msgid "" "Cannot find %s.%s.\n" "\n" "Would you like to continue looking for filters?" msgstr "" #. STID_SEL_XBM_FILE_TO_IMPORT #: ../../strtbl.c:1864 msgid "Please select an X11 Bitmap file to IMPORT..." msgstr "" #. STID_CANNOT_IMPORT_XBM_FILE #: ../../strtbl.c:1866 #, c-format msgid "Cannot import X11 Bitmap file '%s'." msgstr "" #. STID_ENTER_GEOM_SPEC_ORIG_SIZE #: ../../strtbl.c:1868 #, c-format msgid "Please enter geometry spec: [[MAG=]WxH+X+Y] (original size is %1dx%1d)" msgstr "" #. STID_GIVEN_XBM_SIZE_FILE_IMPORTED #: ../../strtbl.c:1870 #, c-format msgid "X11 Bitmap file (%1dx%1d) '%s' imported." msgstr "" #. STID_GIVEN_XPM_SIZE_FILE_IMPORTED #: ../../strtbl.c:1872 #, c-format msgid "X11 Pixmap file (%1dx%1d) '%s' imported." msgstr "" #. STID_SEL_XPM_FILE_TO_IMPORT #: ../../strtbl.c:1874 msgid "Please select an X11 Pixmap file to IMPORT..." msgstr "" #. STID_SEL_EPS_FILE_TO_IMPORT #: ../../strtbl.c:1876 msgid "Please select an EPS file to IMPORT..." msgstr "" #. STID_IMPORT_REM_EPS_EMBED_INSTEAD #: ../../strtbl.c:1878 msgid "" "Importing (linking to) a remote EPS file is not supported. Would you like " "to embed the EPS file instead?" msgstr "" #. STID_GIVEN_EPS_FILE_IMPORTED #: ../../strtbl.c:1880 #, c-format msgid "EPS file '%s' imported." msgstr "" #. STID_SEL_GIF_FILE_TO_IMPORT #: ../../strtbl.c:1882 msgid "Please select a GIF file to IMPORT..." msgstr "" #. STID_CANNOT_IMPORT_GIVEN_GIF #: ../../strtbl.c:1884 #, fuzzy, c-format msgid "Cannot import GIF file '%s'." msgstr "éÍĐÏÒÔ GIF..." #. STID_GIVEN_GIF_SIZE_FILE_IMPORTED #: ../../strtbl.c:1886 #, c-format msgid "GIF file (%1dx%1d) '%s' imported." msgstr "" #. STID_CANT_FIND_ANY_IMP_FLTR_SPEC #: ../../strtbl.c:1888 #, c-format msgid "" "Cannot find any import filter specifications.\n" "\n" "Import filters are specified with %s.%s and %s.%s X resources." msgstr "" #. STID_SEL_AN_IMPORT_FILTER #: ../../strtbl.c:1890 msgid "Please select an import filter..." msgstr "" #. STID_SEL_A_TYPE_FILE_TO_IMPORT #: ../../strtbl.c:1892 #, c-format msgid "Please select a %s file to IMPORT..." msgstr "" #. STID_CANT_IMPORT_GIVEN_TYPE_FILE #: ../../strtbl.c:1894 #, c-format msgid "Cannot import %s file '%s'." msgstr "" #. STID_GIVEN_TYPE_SIZE_FILE_IMPORTED #: ../../strtbl.c:1896 #, c-format msgid "%s file (%1dx%1d) '%s' imported." msgstr "" #. STID_INVALID_FMT_IN_SHORTCUT_SPEC #: ../../strtbl.c:1898 #, c-format msgid "Invalid format in shortcut specification of %s(%s)." msgstr "" #. STID_CANT_FIND_NAMED_IMP_FLTR #: ../../strtbl.c:1900 #, c-format msgid "Cannot find any import filter named '%s'." msgstr "" #. STID_SEL_ANIM_GIF_FILE_TO_IMPORT #: ../../strtbl.c:1902 msgid "Please select an animated GIF file to IMPORT..." msgstr "" #. STID_CANT_EXEC_CMD_IMPORT_ANIM_GIF #: ../../strtbl.c:1904 #, c-format msgid "" "Cannot execute '%s'.\n" "\n" "Animated GIF not imported." msgstr "" #. STID_Q_LIKE_TO_USE_AN_IMP_FLTR_GIF #: ../../strtbl.c:1906 msgid "" "Would you like to use an import filter when importing individual GIF files?" msgstr "" #. STID_CANT_CREATE_NAMED_TMP_FILE #: ../../strtbl.c:1908 #, c-format msgid "Cannot create temporary file: '%s'." msgstr "" #. STID_CANT_IMP_ANIM_GIF_TMP_DIR #: ../../strtbl.c:1910 #, c-format msgid "" "Cannot import GIF animation file '%s'. Please make sure that you can write " "to the '%s' directory." msgstr "" #. STID_CANT_IMP_GIVEN_ANIM_GIF #: ../../strtbl.c:1912 #, c-format msgid "Cannot import GIF animation file '%s'." msgstr "" #. STID_ONLY_ONE_GIF_COMP_EXTRACTED #: ../../strtbl.c:1914 #, c-format msgid "Only one GIF component extracted from '%s'." msgstr "" #. STID_ANIMATING_GIVEN #: ../../strtbl.c:1916 #, c-format msgid "Animating '%s'..." msgstr "" #. STID_GIF_ANIMATION_STOPPED #: ../../strtbl.c:1918 #, fuzzy msgid "GIF animation stopped." msgstr "áÎÉÍÁĂÉŃ GIF" #. STID_PRESS_ESC_TO_STOP #: ../../strtbl.c:1920 msgid "(press <ESC> to stop)" msgstr "" #. STID_BROWSING_DIR_FOR_TYPE_FILES #: ../../strtbl.c:1922 #, c-format msgid "Browsing '%s' for %s files..." msgstr "" #. STID_SKIP_GIVEN_FILE_SYM_LINK #: ../../strtbl.c:1924 #, c-format msgid "Skipping '%s' because it's a symbolic link." msgstr "" #. STID_WORKING_DIR_IS_GIVEN #: ../../strtbl.c:1926 #, c-format msgid "Working directory: '%s'" msgstr "" #. STID_MORE_THAN_ONE_CMAP_INSTALLED #: ../../strtbl.c:1928 msgid "More than one colormap installed." msgstr "" #. STID_FIRST_ONE_ON_LIST_USED #: ../../strtbl.c:1930 msgid "First one on the list is used." msgstr "" #. STID_SPECIFY_AREA #: ../../strtbl.c:1932 #, fuzzy msgid "Specify area" msgstr "śÙÂÒÁÔŰ ÆÏÒÍÁÔ ÂŐÍÁÇÉ..." #. STID_SPECIFY_DELAY_FULL_SCR_CAP #: ../../strtbl.c:1934 msgid "Please specify a delay (in seconds) for full screen capture:" msgstr "" #. STID_WILL_HIDE_TOOL_WHILE_CAPTURE #: ../../strtbl.c:1936 #, fuzzy, c-format msgid "Will hide %s during capturing." msgstr "đÒŃÔÁÔŰ ĐÒÉ ÓÎÉÍËĆ" #. STID_WILL_SHOW_TOOL_WHILE_CAPTURE #: ../../strtbl.c:1938 #, c-format msgid "Will leave %s alone during capturing." msgstr "" #. STID_FUNC_SELECT_SYS_CALL_FAILED #: ../../strtbl.c:1940 #, c-format msgid "In %s: select() system call failed." msgstr "" #. STID_FUNC_INVALID_RC_FOR_SELECT #: ../../strtbl.c:1942 #, c-format msgid "In %s: Invalid return code of %1d from the select() system call." msgstr "" #. STID_CNTRL_C_ABORT_LAUNCH #: ../../strtbl.c:1944 msgid "" "You have typed a ^C. Do you want to abort the command that's being " "executed? (If the command is running in an xterm, please try killing or " "destroying the xterm from the desktop first before doing an abort.)" msgstr "" #. STID_CMD_ABORT_LAUNCH_CLOSE_TOOL #: ../../strtbl.c:1946 #, c-format msgid "" "The '%s' command is aborted.\n" "\n" "However, it's not safe to actually kill the command. Therefore, please " "close %s at the next convenient point." msgstr "" #. STID_INVALID_GIVEN_ATTR_SPEC #: ../../strtbl.c:1948 #, c-format msgid "Invalid attribute specification: '%s'." msgstr "" #. STID_LAUNCH_NOT_AUTO_IN_HYPER_EXEC #: ../../strtbl.c:1950 #, c-format msgid "" "Launching is not automatic in hyperspace. Do you want to execute the " "following command?\n" "\n" " %s\n" "\n" "(If you are not sure about this, just click on NO.)" msgstr "" #. STID_USER_ABORT_LAUNCH_IN_HYPER #: ../../strtbl.c:1952 msgid "Launching in hyperspace aborted at user's request." msgstr "" #. STID_MALFORMED_CMD_EXEC_ABORT #: ../../strtbl.c:1954 #, c-format msgid "" "Malformed '%s' command.\n" "\n" "Command execution aborted." msgstr "" #. STID_NO_OBJ_SEL_WHILE_EXEC_CMD #: ../../strtbl.c:1960 #, c-format msgid "No object is selected while executing the '%s' command." msgstr "" #. STID_CANT_FIND_NAMED_ATTR_EXEC #: ../../strtbl.c:1962 #, c-format msgid "Cannot find the '%s' attribute while executing the '%s' command." msgstr "" #. STID_FILE_ATTR_NOT_ALLOWED_FOR_CMD #: ../../strtbl.c:1964 #, c-format msgid "File attribute '%s' is not appropriate for the '%s' command." msgstr "" #. STID_CANT_FIND_NAMED_OBJ_EXEC #: ../../strtbl.c:1966 #, c-format msgid "Cannot find object named '%s' while executing the '%s' command." msgstr "" #. STID_INVALID_ARG_WHILE_EXEC_CMD #: ../../strtbl.c:1968 #, c-format msgid "Invalid '%s' while executing the '%s' command." msgstr "" #. STID_MODIFY_FILE_ATTR_IN_WB #: ../../strtbl.c:1970 msgid "Cannot modify file attributes in WhiteBoard mode." msgstr "" #. STID_USER_INTR_TOOL_WAIT_CLEANUP #: ../../strtbl.c:1972 #, c-format msgid "" "User interrupt received. %s is waiting for clean up to complete.\n" "\n" "Are you sure you don't want to wait for clean up to complete (this may leave " "the scripts in an inconsistent state)?" msgstr "" #. STID_FUNC_USER_INTR #: ../../strtbl.c:1974 #, c-format msgid "%s(): User interrupt." msgstr "" #. STID_BAD_EVAL_INT_EXP_EXEC_CMD #: ../../strtbl.c:1976 #, c-format msgid "" "Invalid evaluation '%s' used (integer expected) while executing the '%s' " "command." msgstr "" #. STID_BAD_EVAL_FLOAT_EXP_EXEC_CMD #: ../../strtbl.c:1978 #, c-format msgid "" "Invalid evaluation '%s' used (floating pointer number expected) while " "executing the '%s' command." msgstr "" #. STID_FAIL_FUNC_CMD_EXEC_ABORT #: ../../strtbl.c:1980 #, c-format msgid "Fail to %s. Command execution aborted." msgstr "" #. STID_FUNC_ONLY_WORK_COMPOSITE_OBJ #: ../../strtbl.c:1982 #, c-format msgid "%s() only works with composite objects." msgstr "" #. STID_FUNC_FAIL_TO_IMPORT_GIVEN #: ../../strtbl.c:1984 #, c-format msgid "%s(): Fail to import '%s'." msgstr "" #. STID_FUNC_OBJ_NON_XBM_XPM_SUB_OBJS #: ../../strtbl.c:1986 #, c-format msgid "%s(): Object contains non-Bitmap/Pixmap sub-objects." msgstr "" #. STID_WILL_EXPORT_PNG_FILE #: ../../strtbl.c:1988 msgid "Will export PNG (needs xpm->png filter) file." msgstr "" #. STID_CANNOT_IMPORT_GIVEN_PNG #: ../../strtbl.c:1990 #, c-format msgid "Cannot import PNG file '%s'." msgstr "" #. STID_GIVEN_PNG_SIZE_FILE_IMPORTED #: ../../strtbl.c:1992 #, c-format msgid "PNG file (%1dx%1d) '%s' imported." msgstr "" #. STID_SEL_PNG_FILE_TO_IMPORT #: ../../strtbl.c:1994 msgid "Please select a PNG file to IMPORT..." msgstr "" #. STID_FUNC_DIFF_SZ_XBM_XPM_SUBOBJS #: ../../strtbl.c:1996 #, c-format msgid "%s(): Different sizes Bitmap/Pixmap sub-objects." msgstr "" #. STID_FUNC_MORE_1_XBM_XPM_SUBOBJS #: ../../strtbl.c:1998 #, c-format msgid "%s(): Must have > 1 Bitmap/Pixmap sub-objects." msgstr "" #. STID_FUNC_ARG_RANGE #: ../../strtbl.c:2000 #, c-format msgid "" "%s(): '%s' must be between %1d and %1d (inclusive).\n" "\n" "%1d was specified." msgstr "" #. STID_FUNC_UNDEFINED_ARG #: ../../strtbl.c:2002 #, c-format msgid "%s(): Undefined '%s'." msgstr "" #. STID_INTERNAL_CMD_SELECT_FAILED #: ../../strtbl.c:2004 #, c-format msgid "%s(): select() system call failed." msgstr "" #. STID_CANT_OPEN_FILE_READ_EXEC_CMD #: ../../strtbl.c:2006 #, c-format msgid "Cannot open '%s' for reading while executing the '%s' command." msgstr "" #. STID_FAIL_TO_EXECUTE_CMD_EXEC_CMD #: ../../strtbl.c:2008 #, c-format msgid "Fail to execute '%s' while executing the '%s' command." msgstr "" #. STID_UNEXP_ERR_EXEC_CMD_ABORT #: ../../strtbl.c:2010 #, c-format msgid "" "Unexpected error while executing the '%s' command.\n" "\n" "Command execution aborted." msgstr "" #. STID_BAD_NAME_TOP_LEVEL_ONLY_CMD #: ../../strtbl.c:2012 #, c-format msgid "" "Bad object name: '%s'.\n" "\n" "Only top level object can be selected while executing the '%s' command." msgstr "" #. STID_BAD_CURSOR_WHILE_EXEC_CMD #: ../../strtbl.c:2014 #, c-format msgid "Cannot create the '%s' cursor while executing the '%s' command." msgstr "" #. STID_BAD_COLOR_NAME_WHILE_EXEC_CMD #: ../../strtbl.c:2016 #, c-format msgid "Fail to allocate the '%s' color while executing the '%s' command." msgstr "" #. STID_WIDTH_RANGE_WHILE_EXEC_CMD #: ../../strtbl.c:2018 #, c-format msgid "Line width of '%s' is out of range while executing the '%s' command." msgstr "" #. STID_SPLINE_TYPE_WHILE_EXEC_CMD #: ../../strtbl.c:2020 #, c-format msgid "Invalid spline type of '%s' used while executing the '%s' command." msgstr "" #. STID_ARROW_STYLE_WHILE_EXEC_CMD #: ../../strtbl.c:2022 #, c-format msgid "Invalid arrow style of '%s' used while executing the '%s' command." msgstr "" #. STID_DASH_INDEX_WHILE_EXEC_CMD #: ../../strtbl.c:2024 #, c-format msgid "Invalid dash index of '%s' used while executing the '%s' command." msgstr "" #. STID_RCB_RAD_RANGE_WHILE_EXEC_CMD #: ../../strtbl.c:2026 #, c-format msgid "Rcbox radius of '%s' is out of range while executing the '%s' command." msgstr "" #. STID_BAD_TEXT_JUST_WHILE_EXEC_CMD #: ../../strtbl.c:2028 #, c-format msgid "" "Invalid text justification of '%s' used while executing the '%s' command." msgstr "" #. STID_BAD_FONT_NAME_WHILE_EXEC_CMD #: ../../strtbl.c:2030 #, c-format msgid "Invalid font name of '%s' used while executing the '%s' command." msgstr "" #. STID_UNDO_BUF_FLUSHED_BY_CMD #: ../../strtbl.c:2032 #, c-format msgid "Undo buffer flushed by %s()." msgstr "âŐÆĆÒ ÏÔËÁÔÁ ÏȚÉĘĆÎ %s()." #. STID_BAD_EVAL_NUM_EXP_EXEC_CMD #: ../../strtbl.c:2034 #, c-format msgid "" "Invalid evaluation '%s' used (numeric value expected) while executing the '%" "s' command." msgstr "" #. STID_WRITE_CUT_BUF_WHILE_EXEC_CMD #: ../../strtbl.c:2036 #, c-format msgid "Writing to cut buffer failed while executing the '%s' command." msgstr "" #. STID_CANT_FIND_DOT_WHILE_EXEC_CMD #: ../../strtbl.c:2038 #, c-format msgid "Cannot find '.' in '%s%c%s' while executing the '%s' command." msgstr "" #. STID_BAD_WIDTH_WHILE_EXEC_CMD #: ../../strtbl.c:2040 #, c-format msgid "Invalid width of '%s' used while executing the '%s' command." msgstr "" #. STID_BAD_HEIGHT_WHILE_EXEC_CMD #: ../../strtbl.c:2042 #, c-format msgid "Invalid height of '%s' used while executing the '%s' command." msgstr "" #. STID_BAD_STYLE_WHILE_EXEC_CMD #: ../../strtbl.c:2044 #, c-format msgid "Invalid style of '%s' used while executing the '%s' command." msgstr "" #. STID_TOO_MANY_OBJ_WHILE_EXEC_CMD #: ../../strtbl.c:2046 #, c-format msgid "Too many objects selected while executing the '%s' command." msgstr "" #. STID_BAD_ATTR_NAME_WHILE_EXEC_CMD #: ../../strtbl.c:2048 #, c-format msgid "Illegal attribute name '%s' used while executing the '%s' command." msgstr "" #. STID_END_AN_EDGE_AT_A_PORT #: ../../strtbl.c:2050 msgid "Please end an edge at a port..." msgstr "" #. STID_DRAW_AN_EDGE_BETWEEN_PORTS #: ../../strtbl.c:2052 msgid "Please draw an edge between ports..." msgstr "" #. STID_CANT_FIND_VRTX_WHILE_EXEC_CMD #: ../../strtbl.c:2054 #, c-format msgid "" "Cannot find vertex %1d for an object named '%s' while executing the '%s' " "command." msgstr "" #. STID_POLY_NOR_PGON_WHILE_EXEC_CMD #: ../../strtbl.c:2056 #, c-format msgid "" "'%s' is neither a poly nor a polygon object while executing the '%s' command." msgstr "" #. STID_BAD_REM_FNAME_WHILE_EXEC_CMD #: ../../strtbl.c:2058 #, c-format msgid "Invalid remote file name '%s' used while executing the '%s' command." msgstr "" #. STID_CANT_OPEN_FILE_WRITE_EXEC_CMD #: ../../strtbl.c:2060 #, c-format msgid "Cannot open '%s' for writing while executing the '%s' command." msgstr "" #. STID_GIVEN_CMD_EXECUTED #: ../../strtbl.c:2062 #, c-format msgid "%s() command executed." msgstr "" #. STID_SQRT_NEG_NUM_WHILE_EXEC_CMD #: ../../strtbl.c:2064 #, c-format msgid "%s() domain error: Cannot take square-root of a negative number." msgstr "" #. STID_CMD_NOT_AVAIL_ON_PLATFORM #: ../../strtbl.c:2066 #, c-format msgid "The %s() command is not available on this platform." msgstr "ëÏÍÁÎÄÁ %s() ÎĆ ÄÏÓÔŐĐÎÁ ÎÁ ÄÁÎÎÏÊ ĐÌÁÔÆÏÒÍĆ." #. STID_BAD_SHORTCUT_WHILE_EXEC_CMD #: ../../strtbl.c:2068 #, c-format msgid "Invalid shortcut name '%s' used while executing the '%s' command." msgstr "" #. STID_STAT_FAILED_WHILE_EXEC_CMD #: ../../strtbl.c:2070 #, c-format msgid "Fail to get file info for '%s' while executing the '%s' command." msgstr "" #. STID_NON_GROUPED_WHILE_EXEC_CMD #: ../../strtbl.c:2072 #, c-format msgid "" "Non-compound object named '%s' specified while executing the '%s' command." msgstr "" #. STID_BAD_SEP_LONG_WHILE_EXEC_CMD #: ../../strtbl.c:2074 #, c-format msgid "" "Invalid separator '%s' specified while executing the '%s' command.\n" "\n" "(Separator must be a single charactor.)" msgstr "" #. STID_BAD_SEP_WHILE_EXEC_CMD #: ../../strtbl.c:2076 #, c-format msgid "Invalid separator '%s' specified while executing the '%s' command." msgstr "" #. STID_MORE_THAN_ONE_WHILE_EXEC_CMD #: ../../strtbl.c:2078 #, c-format msgid "More than one object selected while executing the '%s' command." msgstr "" #. STID_MUST_FULL_PATH_WHILE_EXEC_CMD #: ../../strtbl.c:2080 #, c-format msgid "" "Invalid path: '%s' specified while executing the '%s' command.\n" "\n" "(Must use an absolute path.)" msgstr "" #. STID_OBJ_ALRDY_SEL_WHILE_EXEC_CMD #: ../../strtbl.c:2082 #, c-format msgid "Object named '%s' is already selected while executing the '%s' command." msgstr "" #. STID_INVALID_FNAME_WHILE_EXEC_CMD #: ../../strtbl.c:2084 #, c-format msgid "Invalid file name '%s' specified while executing the '%s' command." msgstr "" #. STID_INVALID_FMODE_WHILE_EXEC_CMD #: ../../strtbl.c:2086 #, c-format msgid "Invalid file mode '%s' specified while executing the '%s' command." msgstr "" #. STID_INVALID_FNUM_WHILE_EXEC_CMD #: ../../strtbl.c:2088 #, c-format msgid "Invalid file number '%s' specified while executing the '%s' command." msgstr "" #. STID_FNUM_ARDY_OPEN_WHILE_EXEC_CMD #: ../../strtbl.c:2090 #, c-format msgid "File number %1d is already opened while executing the '%s' command." msgstr "" #. STID_CANT_OPEN_FMOD_WRITE_EXEC_CMD #: ../../strtbl.c:2092 #, c-format msgid "" "Cannot open '%s' in the '%s' mode for writing while executing the '%s' " "command." msgstr "" #. STID_FNUM_NOT_OPEN_WHILE_EXEC_CMD #: ../../strtbl.c:2094 #, c-format msgid "File number %1d is not opened while executing the '%s' command." msgstr "" #. STID_EOF_FOR_FNUM_WHILE_EXEC_CMD #: ../../strtbl.c:2096 #, c-format msgid "" "Cannot read beyond the end-of-file for file number %1d while executing the '%" "s' command." msgstr "" #. STID_WRI_FNUM_FAIL_WHILE_EXEC_CMD #: ../../strtbl.c:2098 #, c-format msgid "Fail to write to file number %1d while executing the '%s' command." msgstr "" #. STID_WRI_FNN_FAIL_WHILE_EXEC_CMD #: ../../strtbl.c:2100 #, c-format msgid "" "Fail to write to file number %1d ('%s') while executing the '%s' command." msgstr "" #. STID_INVALID_PATH_WHILE_EXEC_CMD #: ../../strtbl.c:2102 #, c-format msgid "File '%s' does not exist while executing the '%s' command." msgstr "" #. STID_APPEND_FAILED_WHILE_EXEC_CMD #: ../../strtbl.c:2104 #, c-format msgid "Appending '%s' to '%s' failed while executing the '%s' command." msgstr "" #. STID_COPY_FAILED_WHILE_EXEC_CMD #: ../../strtbl.c:2106 #, c-format msgid "Copying '%s' to '%s' failed while executing the '%s' command." msgstr "" #. STID_INVALID_FORMAT_WHILE_EXEC_CMD #: ../../strtbl.c:2108 #, c-format msgid "Invalid format '%s' specified while executing the '%s' command." msgstr "" #. STID_INVALID_REC_WHILE_EXEC_CMD #: ../../strtbl.c:2110 #, c-format msgid "" "Invalid rectangle '(%d,%d,%d,%d)' specified while executing the '%s' command." msgstr "" #. STID_CONVERT_FORMAT_WHILE_EXEC_CMD #: ../../strtbl.c:2112 #, c-format msgid "" "Fail to convert '%s' from the '%s' format to XPM format while executing the " "'%s' command." msgstr "" #. STID_IMPORT_FAILED_WHILE_EXEC_CMD #: ../../strtbl.c:2114 #, c-format msgid "Fail to import '%s' while executing the '%s' command." msgstr "" #. STID_BAD_VER_NUM_WHILE_EXEC_CMD #: ../../strtbl.c:2116 #, c-format msgid "" "Invalid version number '%1d' specified while executing the '%s' command." msgstr "" #. STID_EMPTY_INI_SEC_WHILE_EXEC_CMD #: ../../strtbl.c:2118 #, c-format msgid "" "The [%s] section of '%s' is empty or non-existent while executing the '%s' " "command." msgstr "" #. STID_BAD_LINENUM_WHILE_EXEC_CMD #: ../../strtbl.c:2120 #, c-format msgid "Invalid line number '%1d' specified while executing the '%s' command." msgstr "" #. STID_BAD_SMALL_LNUM_WHILE_EXEC_CMD #: ../../strtbl.c:2122 #, c-format msgid "" "Invalid line number '%1d' (too small) specified while executing the '%s' " "command." msgstr "" #. STID_BAD_EMPTY_STR_WHILE_EXEC_CMD #: ../../strtbl.c:2124 #, c-format msgid "Invalid empty string specified while executing the '%s' command." msgstr "" #. STID_BAD_DIRECTION_WHILE_EXEC_CMD #: ../../strtbl.c:2126 #, c-format msgid "Invalid direction '%s' specified while executing the '%s' command." msgstr "" #. STID_NO_START_VRTX_WHILE_EXEC_CMD #: ../../strtbl.c:2128 #, c-format msgid "No starting vertex specified while executing the '%s' command." msgstr "" #. STID_TOO_FEW_VRTX_WHILE_EXEC_CMD #: ../../strtbl.c:2130 #, c-format msgid "Too few vertices (%1d) specified while executing the '%s' command." msgstr "" #. STID_NO_START_OBJ_WHILE_EXEC_CMD #: ../../strtbl.c:2132 #, c-format msgid "No starting object specified by %s() while executing the '%s' command." msgstr "" #. STID_CANT_FIND_MARK_WHILE_EXEC_CMD #: ../../strtbl.c:2134 #, c-format msgid "" "Cannot find the object marker for %s() while executing the '%s' command." msgstr "" #. STID_NO_OBJ_GROUP_WHILE_EXEC_CMD #: ../../strtbl.c:2136 #, c-format msgid "No object to group while executing the '%s' command." msgstr "" #. STID_CANT_GRP_SNGL_WHILE_EXEC_CMD #: ../../strtbl.c:2138 #, c-format msgid "Cannot group a single object while executing the '%s' command." msgstr "" #. STID_UNRECOG_CMD_MAY_BE_BLANKS_ABT #: ../../strtbl.c:2140 #, c-format msgid "" "Unrecognized command: '%s' (may be caused by illegal trailing blanks in " "command name).\n" "\n" "Command execution aborted." msgstr "" #. STID_UNRECOG_CMD_DOWNLOAD_TOOL #: ../../strtbl.c:2142 #, c-format msgid "" "Unrecognized command: '%s'.\n" "\n" "Command execution aborted.\n" "\n" "It is possible that the command is supported in a newer version of %s. " "Please visit '%s' to download the latest release." msgstr "" #. STID_UNRECOG_CMD_ABORT #: ../../strtbl.c:2144 msgid "Unrecognized command. Command execution aborted." msgstr "" #. STID_TOOL_NOT_DONE_WITH_PREV_FUNC #: ../../strtbl.c:2146 #, c-format msgid "%s is not finished with the previous %s yet." msgstr "" #. STID_ENTER_INTERN_CMD_FILE_NAME #: ../../strtbl.c:2148 #, c-format msgid "" "Please specify the file name for a %s internal command file (enter '-' for " "standard input)." msgstr "" #. STID_FINISH_EXEC_CMD_FROM_STDIN #: ../../strtbl.c:2150 msgid "Finished executing commands from the standard input." msgstr "" #. STID_FATAL_ERROR_IN_FUNC_PLUS_DESC #: ../../strtbl.c:2152 #, c-format msgid "Fatal Error in %s: %s" msgstr "" #. STID_TOOL_ABORTED #: ../../strtbl.c:2154 #, c-format msgid "%s aborted." msgstr "" #. STID_ICON_FILEVER_TOO_LARGE #: ../../strtbl.c:2156 #, c-format msgid "Icon file version too large (=%1d)." msgstr "" #. STID_UNEQUAL_DEPTHS_IN_FUNC #: ../../strtbl.c:2158 #, c-format msgid "Unequal depths in %s." msgstr "" #. STID_BASELINE_YS_NOT_EQ_IN_FUNC #: ../../strtbl.c:2164 #, c-format msgid "Error: left_baseline_y != right_baseline_y in %s." msgstr "" #. STID_LOCKED_OBJS_CANT_BE_MOVED #: ../../strtbl.c:2166 msgid "Locked object(s) cannot be moved." msgstr "" #. STID_HINT_CTL_MOVE_ATTR_ONLY #: ../../strtbl.c:2168 msgid "" "(HINT: You can hold down <Cntrl> key to move only the attribute under the " "cursor.)" msgstr "" #. STID_OUT_OF_VMEM_CANNOT_MALLOC #: ../../strtbl.c:2170 msgid "Out of virtual memory and cannot malloc()." msgstr "" #. STID_CANT_ALLOC_BITMAP_OF_SIZE #: ../../strtbl.c:2172 #, c-format msgid "Cannot allocate bitmap of size %1dx%1d." msgstr "" #. STID_FAIL_TO_WRITE_TO_FILE #: ../../strtbl.c:2174 #, c-format msgid "Fail to write to '%s'. File system may be full." msgstr "" #. STID_SAFEST_SAVE_N_EXIT_REPRODUCE #: ../../strtbl.c:2176 #, c-format msgid "" "Safest thing to do is to save file and exit.\n" "Please try to reproduce this error and\n" "\tsend bug report to %s." msgstr "" #. STID_FATAL_UNEXPECTED_ERROR #: ../../strtbl.c:2178 #, c-format msgid "" "Fatal Unexpected Error: %s%s%s\n" "\n" "Safest thing to do is to save file and exit.\n" "\n" "Please try to reproduce this error and send bug report to %s." msgstr "" #. STID_ENTER_FNAME_TO_WRITE_MSG_BUF #: ../../strtbl.c:2180 msgid "Please enter a file name to write the message buffer content:" msgstr "" #. STID_STDOUT_STDERR_ESC_CANCEL #: ../../strtbl.c:2182 msgid "( \"stdout\", \"stderr\", <ESC>: cancel )" msgstr "" #. STID_MSG_BUF_SAVED_INTO_GIVEN #: ../../strtbl.c:2184 #, c-format msgid "Message buffer saved into '%s'." msgstr "" #. STID_FILE_LINE_MISS_FIELD_IN_OBJ #: ../../strtbl.c:2186 #, c-format msgid "%s, %d: Missing %s in %s object." msgstr "" #. STID_FILE_LINE_BAD_FIELD_IN_OBJ #: ../../strtbl.c:2188 #, c-format msgid "%s, %d: Bad %s in %s object." msgstr "" #. STID_NAMED_SIG_RECV #: ../../strtbl.c:2190 #, c-format msgid "%s signal received." msgstr "" #. STID_ERR_COUNT_EXCEED_TOOL_ABORTED #: ../../strtbl.c:2192 #, c-format msgid "Error count exceeds %1d in %s. %s aborted." msgstr "" #. STID_WORKING_FILE_SAVED_TO #: ../../strtbl.c:2194 #, c-format msgid "Working file saved to '%s.%s'." msgstr "" #. STID_UNABLE_TO_SAVE_WORKING_FILE #: ../../strtbl.c:2196 msgid "Unable to save working file." msgstr "" #. STID_X_ERROR_MSG #: ../../strtbl.c:2198 #, c-format msgid "X Error: %s." msgstr "" #. STID_BAD_COMPILE_OPT_USE_ALT_STR #: ../../strtbl.c:2200 #, c-format msgid "Invalid compiler option %s=\"%s\", \"%s\" is used instead." msgstr "" #. STID_MISSING_DISPLAY_NAME #: ../../strtbl.c:2202 msgid "Missing display name." msgstr "" #. STID_MISSING_PAGE_NUMBER #: ../../strtbl.c:2204 msgid "Missing page number." msgstr "" #. STID_INVALID_GIVEN_PAGE_NUMBER_STR #: ../../strtbl.c:2206 #, c-format msgid "Invalid page number: '%s'." msgstr "" #. STID_MISSING_ARG_FOR_CMDLINE_OPT #: ../../strtbl.c:2208 #, c-format msgid "Missing command line argument for '%s'." msgstr "" #. STID_INVALID_ARG_FOR_CMDLINE_OPT #: ../../strtbl.c:2210 #, c-format msgid "Invalid command line argument for '%s': '%s'." msgstr "" #. STID_TGIF_PATH_SHOULD_NOT_BE_USED #: ../../strtbl.c:2212 msgid "Warning: -tgif_path should not be used!" msgstr "" #. STID_PRINT_TO_PRINTER_INCOMPAT #: ../../strtbl.c:2214 #, c-format msgid "Printing to printer is incompatible with '%s'." msgstr "" #. STID_BAD_EXEC_FNAME_DASH #: ../../strtbl.c:2216 msgid "Invalid exec file name (cannot start with '-')." msgstr "" #. STID_CANNOT_OPEN_DIR_FOR_READING #: ../../strtbl.c:2218 #, c-format msgid "Cannot open the '%s' directory for reading." msgstr "" #. STID_FAIL_TO_STAT_GIVEN_FILE #: ../../strtbl.c:2220 #, c-format msgid "Fail to stat() '%s'." msgstr "" #. STID_SET_WORKING_DIR #: ../../strtbl.c:2222 msgid "SetWorkingDir" msgstr "" #. STID_CLICK_SETWORKDIR_TO_SET_DIR #: ../../strtbl.c:2224 msgid "Click on the 'SetWorkingDir' button to set Open/SaveAs directory." msgstr "" #. STID_SETWORKDIR_NOT_SUP_FOR_STR #: ../../strtbl.c:2226 #, c-format msgid "SetWorkingDir not supported for '%s'." msgstr "" #. STID_OPENSAVE_DIR_CHANGE_TO_REMAIN #: ../../strtbl.c:2228 #, c-format msgid "" "Current open/save directory change to '%s'.\n" "\n" "(Current import directory remains '%s'.)" msgstr "" #. STID_IMPORT_DIR_CHANGED_TO_REMAIN #: ../../strtbl.c:2230 #, c-format msgid "" "Current import directory changed to '%s'.\n" "\n" "(Current open/save directory remains '%s'.)" msgstr "" #. STID_GEN_LIST_OF_DOMAIN_NAMES_WAIT #: ../../strtbl.c:2232 msgid "Generating list of domain names, please wait..." msgstr "" #. STID_CANT_GEN_DOM_NAMES_INI_ENTRY #: ../../strtbl.c:2234 #, c-format msgid "" "Fail to generate a list of domain names.\n" "\n" "Cannot find the '%s' entry in the [%s] section of '%s'." msgstr "" #. STID_CANT_GEN_DOM_NAMES_XDEF #: ../../strtbl.c:2236 #, c-format msgid "" "Fail to generate a list of domain names.\n" "\n" "Cannot find %s.%s%1d." msgstr "" #. STID_CANT_GET_LIST_OF_DOM_NAMES #: ../../strtbl.c:2238 msgid "Fail to get a list of domain names." msgstr "" #. STID_PLEASE_SELECT_A_NEW_DOMAIN #: ../../strtbl.c:2240 msgid "Please select a new DOMAIN..." msgstr "śÙÂĆÒÉÔĆ ÎÏŚÙÊ ÄÏÍĆÎ..." #. STID_CURRENT_DOMAIN_IS #: ../../strtbl.c:2242 #, c-format msgid "Current domain is '%s'." msgstr "ôĆËŐĘÉÊ ÄÏÍĆÎ ŐÓÔÁÎÏŚÌĆÎ Ś '%s'." #. STID_SYMBOL_PATH_SET_TO #: ../../strtbl.c:2244 #, c-format msgid "Symbol path set to '%s'." msgstr "" #. STID_PLS_SEL_A_DIR_IN_GIVEN_DOMAIN #: ../../strtbl.c:2246 #, c-format msgid "Please select a DIRECTORY in the '%s' domain..." msgstr "śÙÂĆÒÉÔĆ ËÁÔÁÌÏÇ Ś ÄÏÍĆÎĆ '%s'..." #. STID_GEN_LIST_XBM_NAMES_WAIT #: ../../strtbl.c:2248 msgid "Generating list of bitmap names, please wait..." msgstr "" #. STID_GEN_LIST_XPM_NAMES_WAIT #: ../../strtbl.c:2250 msgid "Generating list of pixmap names, please wait..." msgstr "" #. STID_GEN_LIST_OBJ_NAMES_WAIT #: ../../strtbl.c:2252 msgid "Generating list of object file names, please wait..." msgstr "" #. STID_GEN_LIST_SYM_NAMES_WAIT #: ../../strtbl.c:2254 msgid "Generating list of symbol names, please wait..." msgstr "" #. STID_GEN_LIST_TYPE_FILE_NAMES_WAIT #: ../../strtbl.c:2256 #, c-format msgid "Generating list of %s file names, please wait..." msgstr "" #. STID_NO_GIVEN_TYPE_FILE_FOUND #: ../../strtbl.c:2258 #, c-format msgid "No '%s' file found." msgstr "æÁÊÌ '%s' ÎĆ ÎÁÊÄĆÎ." #. STID_NO_DIR_SEP_IN_FUNC_WORK_DIR #: ../../strtbl.c:2260 #, c-format msgid "" "Error: No directory-separator found in %s.\n" "\n" "Current working directory set to '%s'." msgstr "" #. STID_NO_DIR_SEP_IN_FUNC_SYM_DIR #: ../../strtbl.c:2262 #, c-format msgid "" "Error: No directory-separator found in %s.\n" "\n" "Current symbol directory set to '%s'." msgstr "" #. STID_NO_DIR_SEP_IN_FUNC_IMPORT_DIR #: ../../strtbl.c:2264 #, c-format msgid "" "Error: No directory-separator found in %s.\n" "\n" "Current import directory set to '%s'." msgstr "" #. STID_EMPTY_PATH_DISALLOW_FOR_DOM #: ../../strtbl.c:2266 #, c-format msgid "Empty path is not allowed for the '%s' domain." msgstr "" #. STID_TOOL_EDIT_DOM_PATHS #: ../../strtbl.c:2268 #, fuzzy, c-format msgid "%s - Edit Domain Paths" msgstr "òĆÄÁËÔÉÒÏŚÁÔŰ ĐŐÔÉ..." #. STID_EDIT_DOMAIN_PATHS_DOTS #: ../../strtbl.c:2270 #, fuzzy msgid "Edit domain paths..." msgstr "òĆÄÁËÔÉÒÏŚÁÔŰ ĐŐÔÉ..." #. STID_TOOL_SEL_DEFAULT_DOMAIN #: ../../strtbl.c:2272 #, fuzzy, c-format msgid "%s - Select A Default Domain" msgstr "ïÂÌÁÓÔŰ ĐÏ ŐÍÏÌȚÁÎÉÀ..." #. STID_SEL_DEFAULT_DOMAIN_DOTS #: ../../strtbl.c:2274 msgid "Please select a default domain..." msgstr "śÙÂĆÒÉÔĆ ÄÏÍĆÎ ĐÏ ŐÍÏÌȚÁÎÉÀ..." #. STID_PLS_SPEC_A_NEW_DOMAIN_NAME #: ../../strtbl.c:2276 msgid "Please specify a new domain name:" msgstr "" #. STID_GIVEN_DOMAIN_ALREADY_EXISTS #: ../../strtbl.c:2278 #, c-format msgid "Domain '%s' already exists!" msgstr "äÏÍĆÎ '%s' ŐÖĆ ÓŐĘĆÓÔŚŐĆÔ!" #. STID_GIVEN_DOM_ADDED_PATH_SET_TO #: ../../strtbl.c:2280 #, c-format msgid "Domain '%s' added. Path set to \"%s\"." msgstr "äÏÍĆÎ '%s' ÄÏÂÁŚÌĆÎ. đŐÔŰ ŐÓÔÁÎÏŚÌĆÎ Ś \"%s\"." #. STID_SEL_DOMAIN_TO_DELETE_DOTS #: ../../strtbl.c:2282 msgid "Please select a domain to delete..." msgstr "śÙÂĆÒÉÔĆ ÉÍŃ ÄÏÍĆÎÁ ÄÌŃ ŐÄÁÌĆÎÉŃ..." #. STID_OK_TO_DELETE_NAMED_DOMAIN_YNC #: ../../strtbl.c:2284 #, c-format msgid "Okay to delete the '%s' domain? [ync](y)" msgstr "őÄÁÌÉÔŰ ÄÏÍĆÎ '%s'? [ync](y)" #. STID_OK_TO_RELOAD_DOM_INFO_FROM_X #: ../../strtbl.c:2286 msgid "Okay to reload domain information from X defaults? [ync](y)" msgstr "" #. STID_ERR_IN_PARSE_STR_FOR_2_VAL #: ../../strtbl.c:2288 #, c-format msgid "Error in parsing '%s' for 2 values." msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_BACK #: ../../strtbl.c:2290 msgid "File modified, save file before going back? [ync](y)" msgstr "æÁÊÌ ÂÙÌ ÉÚÍĆÎĆÎ, ÓÏÈÒÁÎÉÔŰ ĆÇÏ ĐĆÒĆÄ ĐĆÒĆÈÏÄÏÍ ÎÁÚÁÄ? [ync](y)" #. STID_NOTHING_TO_GO_BACK_TO #: ../../strtbl.c:2292 msgid "Nothing to go back to." msgstr "éÄÔÉ ÎÁÚÁÄ ÎĆËŐÄÁ." #. STID_FILE_MOD_SAVE_BEFORE_FORWARD #: ../../strtbl.c:2294 msgid "File modified, save file before going forward? [ync](y)" msgstr "æÁÊÌ ÂÙÌ ÉÚÍĆÎĆÎ, ÓÏÈÒÁÎÉÔŰ ĆÇÏ ĐĆÒĆÄ ĐĆÒĆÈÏÄÏÍ ŚĐĆÒĆÄ? [ync](y)" #. STID_NOTHING_TO_GO_FORWARD_TO #: ../../strtbl.c:2296 msgid "Nothing to go forward to." msgstr "éÄÔÉ ŚĐĆÒĆÄ ÎĆËŐÄÁ." #. STID_FAIL_TO_FIND_RECORD_IN_FUNC #: ../../strtbl.c:2298 msgid "Fail to find record in AdjustNavigate()." msgstr "" #. STID_FURTHER_NAVIGATE_MAY_CRASH #: ../../strtbl.c:2300 msgid "Further navigating may crash." msgstr "" #. STID_CANT_REFRESH_UNDEFINED_FILE #: ../../strtbl.c:2302 msgid "Canot refresh an undefined file." msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_RELOAD #: ../../strtbl.c:2304 msgid "File modified, save file before going reloading? [ync](y)" msgstr "æÁÊÌ ÂÙÌ ÉÚÍĆÎĆÎ, ÓÏÈÒÁÎÉÔŰ ĆÇÏ ĐĆÒĆÄ ĐĆÒĆÚÁÇÒŐÚËÏÊ? [ync](y)" #. STID_HOT_LIST_FILE_UNDEF_PLS_SPEC #: ../../strtbl.c:2306 #, c-format msgid "Hot list file undefined. Please specify it in %s.%s." msgstr "" #. STID_MALFORMED_NAMED_HOT_LIST_FILE #: ../../strtbl.c:2308 #, c-format msgid "Malformed hot list file '%s'." msgstr "" #. STID_HOT_LIST_FILE_IS_EMPTY #: ../../strtbl.c:2310 msgid "Hot list file is empty." msgstr "" #. STID_Q_DEL_NAMED_FROM_HOT_LIST #: ../../strtbl.c:2312 #, c-format msgid "Would you like to delete '%s' from the hot list? [ync](y)" msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_OPEN_ANO #: ../../strtbl.c:2314 msgid "File modified, save file before opening another file? [ync](y)" msgstr "æÁÊÌ ÂÙÌ ÉÚÍĆÎĆÎ, ÓÏÈÒÁÎÉÔŰ ĆÇÏ ĐĆÒĆÄ ÏÔËÒÙÔÉĆÍ ÄÒŐÇÏÇÏ ÆÁÊÌÁ? [ync](y)" #. STID_SESSION_HIST_NOT_ESTABLISHED #: ../../strtbl.c:2316 msgid "Sesion history has not been established yet." msgstr "" #. STID_TOOL_HOT_LIST #: ../../strtbl.c:2318 #, fuzzy, c-format msgid "%s - Hot List" msgstr "Host List..." #. STID_TOOL_HISTORY #: ../../strtbl.c:2320 #, c-format msgid "%s - History" msgstr "%s - éÓÔÏÒÉŃ" #. STID_HOT_LIST_DOTS #: ../../strtbl.c:2322 #, fuzzy msgid "Hot list..." msgstr "Host List..." #. STID_CANT_ADD_UNDEF_TO_HOT_LIST #: ../../strtbl.c:2324 msgid "Cannot add an undefined file to hot list." msgstr "" #. STID_HOT_LIST_FILE_UPDATED #: ../../strtbl.c:2326 msgid "Hot list file updated." msgstr "" #. STID_SESSION_HISTORY_DOTS #: ../../strtbl.c:2328 #, fuzzy msgid "Session history..." msgstr "éÓÔÏÒÉŃ ÒÁÂÏÔÙ..." #. STID_ENTER_HYPERSPACE_DOTS #: ../../strtbl.c:2330 msgid "Enter hyperspace..." msgstr "śÈÏÄ Ś ÇÉĐĆÒĐÒÏÓÔÒÁÎÓÔŚÏ..." #. STID_LEAVING_HYPERSPACE_DOTS #: ../../strtbl.c:2332 msgid "Leaving hyperspace..." msgstr "śÙÈÏÄ ÉÚ ÇÉĐĆÒĐÒÏÓÔÒÁÎÓÔŚÁ..." #. STID_CANT_SLIDESHOW_IN_TILED_PAGE #: ../../strtbl.c:2334 msgid "" "Cannot enter slideshow mode in TILED page mode. Would you like to switch to " "STACKED page mode (and mark the file unsavable) then proceed? [ync](y)" msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_SLIDE #: ../../strtbl.c:2336 msgid "File modified, save file before entering slideshow mode? [ync](y)" msgstr "" #. STID_PAGE_NUM_MOD_IN_SLIDE_NOT_SAV - this string is not used! #: ../../strtbl.c:2338 #, c-format msgid "" "Page numbers will be modified by %s in slideshow mode. It's probably a good " "idea NOT to do a Save() until you've re-opened the file." msgstr "" #. STID_Q_PAGE_NUM_MOD_IN_SLIDE_YNC #: ../../strtbl.c:2340 #, c-format msgid "" "Page numbers will be modified by %s in slideshow mode. The file will be " "marked unsavable if you continue.\n" "\n" "Okay to mark the file unsavable and enter slideshow mode? [ync](y)" msgstr "" #. STID_ENTERING_SLIDESHOW_DOTS #: ../../strtbl.c:2342 msgid "Entering slideshow..." msgstr "" #. STID_LEAVING_SLIDESHOW_DOTS #: ../../strtbl.c:2344 msgid "Leaving slideshow..." msgstr "" #. STID_ENTER_A_COLOR_FOR_SLIDE_BRDR #: ../../strtbl.c:2346 msgid "Please enter a color for the slideshow border:" msgstr "" #. STID_PRESS_ENTER_FOR_DEF_COLOR #: ../../strtbl.c:2348 msgid "( just press <ENTER> for the default color )" msgstr "" #. STID_SLIDE_WILL_USE_DEF_BRDR_COLOR #: ../../strtbl.c:2350 msgid "Slideshow will use default border color." msgstr "" #. STID_SLIDE_BRDR_COLOR_SET_TO_NAMED #: ../../strtbl.c:2352 #, fuzzy, c-format msgid "Slideshow border color set to '%s'." msgstr "ăŚĆÔ ÂÏÒÄÀÒÁ ÏËÎÁ ÓÌÁÊÄÏŚ..." #. STID_ENTER_XY_OFFSET_FOR_SLIDE_WIN #: ../../strtbl.c:2354 #, c-format msgid "" "Please enter X and Y offsets for the slideshow window: [current: %1d,%1d]" msgstr "" #. STID_SLIDE_WIN_XY_OFFSETS_SET_TO #: ../../strtbl.c:2356 #, c-format msgid "Slideshow window offsets set to: %1d, %1d." msgstr "" #. STID_GRID_BE_VISIBLE_IN_SLIDE #: ../../strtbl.c:2358 msgid "Grid will be visible in slideshow mode." msgstr "" #. STID_GRID_NOT_BE_VISIBLE_IN_SLIDE #: ../../strtbl.c:2360 msgid "Grid will not be visible in slideshow mode." msgstr "" #. STID_CANT_DO_NEXTPAGE_IN_TILED #: ../../strtbl.c:2362 msgid "Cannot do NextPage() in TILED page mode." msgstr "" #. STID_ALREADY_AT_LAST_PAGE #: ../../strtbl.c:2368 msgid "Already at last page." msgstr "őÖĆ ÎÁ ĐÏÓÌĆÄÎĆÊ ÓÔÒÁÎÉĂĆ." #. STID_CANT_DO_PREFPAGE_IN_TILED #: ../../strtbl.c:2370 msgid "Cannot do PrevPage() in TILED page mode." msgstr "" #. STID_ALREADY_AT_FIRST_PAGE #: ../../strtbl.c:2372 msgid "Already at first page." msgstr "őÖĆ ÎÁ ĐĆÒŚÏÊ ÓÔÒÁÎÉĂĆ." #. STID_TOOL_NAME_PAGES #: ../../strtbl.c:2374 #, c-format msgid "%s - Name Pages" msgstr "%s - éÍĆÎÁ ÓÔÒÁÎÉĂ" #. STID_TOOL_GOTO_PAGE #: ../../strtbl.c:2376 #, c-format msgid "%s - Goto Page" msgstr "%s - đĆÒĆÊÔÉ Ë ÓÔÒÁÎÉĂĆ" #. STID_CANT_DO_GOTOPAGE_IN_TILED #: ../../strtbl.c:2378 msgid "Cannot do GotoPage() in TILED page mode." msgstr "" #. STID_GOTO_PAGE_DOTS #: ../../strtbl.c:2380 msgid "Goto page..." msgstr "đĆÒĆÊÔÉ Ë ÓÔÒÁÎÉĂĆ..." #. STID_NO_PAGE_SELECTED #: ../../strtbl.c:2382 #, fuzzy msgid "No page selected." msgstr "óÏÈÒÁÎÉÔŰ ŚÙÄĆÌĆÎÎÏĆ ËÁË..." #. STID_INVALID_GIVEN_PAGE_NUMBER #: ../../strtbl.c:2384 #, c-format msgid "Invalid page number '%1d'." msgstr "" #. STID_ALREADY_AT_GIVEN_PAGE #: ../../strtbl.c:2386 #, c-format msgid "Already at page %1d." msgstr "őÖĆ ÎÁ ÓÔÒÁÎÉĂĆ %1d." #. STID_CUR_PAGE_IS_GIVEN_PAGE_NUM #: ../../strtbl.c:2388 #, c-format msgid "Current page is page %1d." msgstr "ôĆËŐĘÁŃ ÓÔÒÁÎÉĂÁ: %1d." #. STID_CANT_DO_NAMEPAGES_IN_TILED #: ../../strtbl.c:2390 msgid "Cannot do NamePages() in TILED page mode." msgstr "" #. STID_EDIT_PAGE_NAMES_DOTS #: ../../strtbl.c:2392 msgid "Edige page names..." msgstr "òĆÄÁËÔÉÒÏŚÁÔŰ ÉÍĆÎÁ ÓÔÒÁÎÉĂ..." #. STID_CANT_EDITPAGEFNAME_IN_TILED #: ../../strtbl.c:2394 msgid "Cannot do EditPageFileNames() in TILED page mode." msgstr "" #. STID_EDIT_PAGE_FILE_NAMES_DOTS #: ../../strtbl.c:2396 msgid "Edige page file names..." msgstr "òĆÄÁËÔÉÒÏŚÁÔŰ ÉÍĆÎÁ ÆÁÊÌÏŚ ÓÔÒÁÎÉĂ..." #. STID_PAGE_FNAME_NO_SPACE_TRUNC #: ../../strtbl.c:2398 #, c-format msgid "" "Page file name: '%s' must not contain space characters. It is truncated to " "'%s'." msgstr "" #. STID_OK_TO_FLUSH_UNDO_AND_PROCEED #: ../../strtbl.c:2400 msgid "Okay to flush the undo buffer and proceed? [ync](y)" msgstr "ïȚÉÓÔÉÔŰ ÂŐÆĆÒÁ ÏÔËÁÔÁ É ĐÒÏÄÏÌÖÉmŰ? [ync](y)" #. STID_ADD_PAGE_BEFORE_GIVEN_FLUSH #: ../../strtbl.c:2402 #, c-format msgid "Adding a page before page %1d will cause the undo buffer to be flushed." msgstr "äÏÂÁŚÌĆÎÉĆ ÓÔÒÁÎÉĂÙ ĐĆÒĆÄ ÓÔÒÁÎÉĂĆÊ %1d ĐÒÉŚĆÄĆÔ Ë ÏȚÉÓÔËĆ ÂŐÆĆÒÁ ÏÔËÁÔÁ." #. STID_ADD_PAGE_AFTER_GIVEN_FLUSH #: ../../strtbl.c:2404 #, c-format msgid "Adding a page after page %1d will cause the undo buffer to be flushed." msgstr "äÏÂÁŚÌĆÎÉĆ ÓÔÒÁÎÉĂÙ ĐÏÓÌĆ ÓÔÒÁÎÉĂÙ %1d ĐÒÉŚĆÄĆÔ Ë ÏȚÉÓÔËĆ ÂŐÆĆÒÁ ÏÔËÁÔÁ." #. STID_DELETE_GIVEN_PAGE_CAUSE_FLUSH #: ../../strtbl.c:2406 #, c-format msgid "Deleting page %1d will cause the undo buffer to be flushed." msgstr "őÄÁÌĆÎÉĆ ÓÔÒÁÎÉĂÙ %1d ĐÒÉŚĆÄĆÔ Ë ÏȚÉÓÔËĆ ÂŐÆĆÒÁ ÏÔËÁÔÁ." #. STID_DELETE_A_PAGE_CAUSE_FLUSH #: ../../strtbl.c:2408 msgid "Deleting a page will cause the undo buffer to be flushed." msgstr "őÄÁÌĆÎÉĆ ÓÔÒÁÎÉĂÙ ĐÒÉŚĆÄĆÔ Ë ÏȚÉÓÔËĆ ÂŐÆĆÒÁ ÏÔËÁÔÁ." #. STID_DELETE_PAGES_PAGE_CAUSE_FLUSH #: ../../strtbl.c:2410 msgid "Deleting pages will cause the undo buffer to be flushed." msgstr "őÄÁÌĆÎÉĆ ÓÔÒÁÎÉĂ ĐÒÉŚĆÄĆÔ Ë ÏȚÉÓÔËĆ ÂŐÆĆÒÁ ÏÔËÁÔÁ." #. STID_CHNG_PAGE_LAYOUT_FLUSH #: ../../strtbl.c:2412 msgid "Changing the page layout mode will cause the undo buffer to be flushed." msgstr "éÚÍĆÎĆÎÉĆ ÒĆÖÉÍÁ ÒÁÚÍĆÔËÉ ÓÔÒÁÎÉĂÙ ĐÒÉŚĆÄĆÔ Ë ÏȚÉÓÔËĆ ÂŐÆĆÒÁ ÏÔËÁÔÁ." #. STID_SET_PAPER_COLOR_CAUSE_FLUSH #: ../../strtbl.c:2414 msgid "Setting paper color will cause the undo buffer to be flushed." msgstr "őÓÔÁÎÏŚËÁ ĂŚĆÔÁ ÂŐÍÁÇÉ ĐÒÉŚĆÄĆÔ Ë ÏȚÉÓÔËĆ ÂŐÆĆÒÁ ÏÔËÁÔÁ." #. STID_CANT_DO_ADDPAGE_IN_TILED #: ../../strtbl.c:2416 msgid "Cannot do AddPage() in TILED page mode." msgstr "" #. STID_CANT_DO_DELETEPAGE_IN_TILED #: ../../strtbl.c:2418 msgid "Cannot do DeleteCurrentPage() in TILED page mode." msgstr "" #. STID_CANT_DEL_ONLY_PAGE_IN_TILED #: ../../strtbl.c:2420 msgid "Cannot delete (the only) page in TILED page mode." msgstr "" #. STID_CANT_DO_SPECDRAWSIZE_IN_TILED #: ../../strtbl.c:2422 msgid "Cannot do SpecifyDrawingSize() in TILED page mode." msgstr "" #. STID_CANT_DO_DELETEPAGES_IN_TILED #: ../../strtbl.c:2424 msgid "Cannot do DeletePages() in TILED page mode." msgstr "" #. STID_CANT_DO_POFPP_IN_TILED #: ../../strtbl.c:2426 msgid "Cannot do PrintOneFilePerPage() in TILED page mode." msgstr "" #. STID_CANT_DO_POFPP_TO_PRINTER #: ../../strtbl.c:2428 msgid "Cannot do PrintOneFilePerPage() to printer." msgstr "" #. STID_NAMED_TEMPLATE_LOADED #: ../../strtbl.c:2430 #, c-format msgid "Template loaded: '%s'." msgstr "ûÁÂÌÏÎ ÚÁÇÒŐÖĆÎ: '%s'." #. STID_PROB_LOADING_NAMED_TEMPLATE #: ../../strtbl.c:2432 #, c-format msgid "Problem loading template file '%s'." msgstr "đÒÏÂÌĆÍÁ Ó ÚÁÇÒŐÚËÏÊ ÆÁÊÌÁ ÛÁÂÌÏÎÁ '%s'." #. STID_GIVEN_PAGE_NUM_ADDED #: ../../strtbl.c:2434 #, c-format msgid "Page %1d added." msgstr "óÔÒÁÎÉĂÁ %1d ÄÏÂÁŚÌĆÎÁ." #. STID_ADDPAGEBEFORE_IN_WB #: ../../strtbl.c:2436 msgid "AddPageBefore() is disabled in WhiteBoard mode." msgstr "" #. STID_ADDPAGEAFTER_IN_WB #: ../../strtbl.c:2438 msgid "AddPageAfter() is disabled in WhiteBoard mode." msgstr "" #. STID_GIVEN_PAGE_NUM_DELETED #: ../../strtbl.c:2440 #, c-format msgid "Page %1d deleted." msgstr "óÔÒÁÎÉĂÁ %1d ŐÄÁÌĆÎÁ." #. STID_CANT_TPLS_IN_STACKED #: ../../strtbl.c:2442 msgid "Cannot TogglePageLineShown() in STACKED page mode." msgstr "" #. STID_ENTER_DRAW_SIZE_SPEC_WH #: ../../strtbl.c:2444 msgid "Please enter drawing size specification: [W x H]" msgstr "" #. STID_BAD_DRAW_SIZE_SPEC_WH #: ../../strtbl.c:2446 msgid "" "Invalid drawing size specification.\n" "\n" "Must specify both Width and Height." msgstr "" #. STID_BAD_DRAW_SIZE_SPEC_W_TIMES_H #: ../../strtbl.c:2448 #, c-format msgid "Invalid drawing size specification: W times H should be >= %1d." msgstr "" #. STID_INVALID_DRAW_SIZE_SPEC #: ../../strtbl.c:2450 msgid "Invalid drawing size specified." msgstr "" #. STID_CANT_PRINTONEPAGE_IN_FORMAT #: ../../strtbl.c:2452 #, c-format msgid "Cannot do PrintOnePage() in the '%s' format." msgstr "" #. STID_BTN1_SEL_PAGE_TO_PRINT #: ../../strtbl.c:2454 msgid "Left button selects a page to print," msgstr "" #. STID_OTHER_BTN_CANCEL_PRINTONEPAGE #: ../../strtbl.c:2456 msgid "other buttons cancel printing one page." msgstr "" #. STID_SELECT_A_PAGE_TO_PRINT #: ../../strtbl.c:2458 msgid "Select a page to print" msgstr "" #. STID_OPERATION_CANCEL_BY_USER #: ../../strtbl.c:2460 msgid "Operation canceled by the user." msgstr "ïĐĆÒÁĂÉŃ ÏÔÍĆÎĆÎÁ ĐÏÌŰÚÏŚÁÔĆÌĆÍ." #. STID_MUST_SEL_A_PT_ON_THE_PAPER #: ../../strtbl.c:2462 msgid "Must select a point on the paper." msgstr "" #. STID_MUST_SEL_A_PT_IN_TOOL_WIN #: ../../strtbl.c:2464 #, c-format msgid "Must select a point within the %s window." msgstr "" #. STID_NEW_PAPER_SIZE_IS_GIVEN #: ../../strtbl.c:2466 #, c-format msgid "New paper size: %.2fin x %.2fin (%.2fcm x %.2fcm)." msgstr "îÏŚÙÊ ÒÁÚÍĆÒ ÂŐÍÁÇÉ: %.2fin x %.2fin (%.2fcm x %.2fcm)." #. STID_INVALID_GIVEN_PAPER_SIZE_SPEC #: ../../strtbl.c:2468 #, c-format msgid "Invalid paper size specification: '%s'." msgstr "" #. STID_CUR_PAPER_SIZE_IS_GIVEN #: ../../strtbl.c:2470 #, c-format msgid "( current paper size: '%s' )" msgstr "( ÔĆËŐĘÉÊ ÒÁÚÍĆÒ ÂŐÍÁÇÉ: '%s' )" #. STID_ENTER_PAPER_SIZE_WH #: ../../strtbl.c:2472 msgid "Please enter physical paper size: [W x H] (e.g., 8.5in x 11in)" msgstr "śŚĆÄÉÔĆ ÆÉÚÉȚĆÓËÉÊ ÒÁÚÍĆÒ ÂŐÍÁÇÉ: [û x ś] (ÎÁĐÒÉÍĆÒ, 8.5in x 11in)" #. STID_CANT_DEL_ONLY_PAGE_IN_STACKED #: ../../strtbl.c:2474 msgid "Cannot delete (the only) page." msgstr "" #. STID_SPECIFY_PAGES_TO_DEL_EX #: ../../strtbl.c:2476 msgid "Please specify pages to delete: (e.g., 2,3,7-9,10)" msgstr "śŚĆÄÉÔĆ ÓÔÒÁÎÉĂÙ ÄÌŃ ŐÄÁÌĆÎÉŃ: (ÎÁĐÒÉÍĆÒ, 2,3,7-9,10)" #. STID_GIVEN_PAGE_NUM_IS_OUT_OF_RNG #: ../../strtbl.c:2478 #, c-format msgid "Page %1d is out of range." msgstr "óÔÒÁÎÉĂÁ %1d ŚÎĆ ÄÏĐŐÓÔÉÍÙÈ ĐÒĆÄĆÌÏŚ." #. STID_MALFORMED_SPECIFICATION_STR #: ../../strtbl.c:2480 #, c-format msgid "Malformed specification: '%s'." msgstr "" #. STID_CANT_DEL_ALL_PAGES #: ../../strtbl.c:2482 msgid "Cannot delete all pages." msgstr "" #. STID_ONE_PAGE_DELETED #: ../../strtbl.c:2484 msgid "1 page deleted." msgstr "őÄÁÌĆÎÏ ÓÔÒÁÎÉĂ: 1." #. STID_MANY_PAGES_DELETED #: ../../strtbl.c:2486 #, c-format msgid "%1d pages deleted." msgstr "őÄÁÌĆÎÏ ÓÔÒÁÎÉĂ: %1d." #. STID_OBJ_OUTSIDE_PAGE_BNRDY_SWITCH #: ../../strtbl.c:2488 msgid "" "There are objects outside the page boundary.\n" "\n" "Cannot switch to TILED mode." msgstr "" #. STID_SWTCH_TO_TILED_LOSE_ALL_NAMES #: ../../strtbl.c:2490 msgid "" "Switching from TILED to STACKED mode loses all page names and page file " "names.\n" "\n" "Ok to proceed? [ync](y)" msgstr "" #. STID_CHANGE_PAGE_LAYOUT_MODE_IN_WB #: ../../strtbl.c:2492 msgid "Changing page layout mode is disabled in WhiteBoard mode." msgstr "" #. STID_PAGE_LAYOUT_MODE_IS_STACKED #: ../../strtbl.c:2494 msgid "Page layout mode is STACKED." msgstr "" #. STID_PAGE_LAYOUT_MODE_IS_TILED #: ../../strtbl.c:2496 msgid "Page layout mode is TILED." msgstr "" #. STID_SPECIFY_A_PAPER_COLOR #: ../../strtbl.c:2498 msgid "Please specify a paper color:" msgstr "őËÁÖÉÔĆ ĂŚĆÔ ÂŐÍÁÇÉ:" #. STID_SPECIFY_A_PAPER_COLOR_CUR_IS #: ../../strtbl.c:2500 #, c-format msgid "Please specify a paper color: [current: %s]" msgstr "őËÁÖÉÔĆ ĂŚĆÔ ÂŐÍÁÇÉ: [ÔĆËŐĘÉÊ: %s]" #. STID_ENTER_NONE_TO_REMOVE_COLOR #: ../../strtbl.c:2502 msgid "( Enter 'None' to remove the current paper color. )" msgstr "( śŚĆÄÉÔĆ 'None' ÄÌŃ ŐÄÁÌĆÎÉŃ ÔĆËŐĘĆÇÏ ĂŚĆÔÁ ÂŐÍÁÇÉ. )" #. STID_PAPER_COLOR_REMOVED #: ../../strtbl.c:2504 msgid "Paper color removed." msgstr "ăŚĆÔ ÂŐÍÁÇÉ ŐÄÁÌĆÎ." #. STID_PAPER_COLOR_SET_TO_GIVEN #: ../../strtbl.c:2506 #, c-format msgid "Paper color set to '%s'." msgstr "ăŚĆÔ ÂŐÍÁÇÉ ŐÓÔÁÎÏŚÌĆÎ Ś '%s'." #. STID_GRAY_SCALE_USED_IN_PRINT_PAT #: ../../strtbl.c:2508 msgid "Gray scale used in printing tiling patterns." msgstr "" #. STID_NOTE_SLOW_PRINT_DUE_USE_PAT #: ../../strtbl.c:2510 msgid "Note: slow printing due to the use of patterns." msgstr "" #. STID_SUGGEST_USEGRAYSCALE_TO_SPEED #: ../../strtbl.c:2512 msgid "You may want to try UseGrayScale() to speed things up." msgstr "" #. STID_ENTER_LINE_WIDTH_OPT_AW_AH #: ../../strtbl.c:2520 msgid "Please enter line width (arrow width and height are optional):" msgstr "" #. STID_INVALID_GIVEN_STR_WIDTH #: ../../strtbl.c:2522 #, c-format msgid "Invalid width: '%s'." msgstr "" #. STID_INVALID_GIVEN_STR_AW_AH #: ../../strtbl.c:2524 #, c-format msgid "Invalid arrow width and height: '%s %s'." msgstr "" #. STID_NO_PINS_FOUND_IN_CUR_DRAWING #: ../../strtbl.c:2526 msgid "No pins found in the current drawing." msgstr "" #. STID_INPUT_PAIRS_OF_POINTS_POLY #: ../../strtbl.c:2528 msgid "" "Please input pairs of points: (terminate with \"<Cntrl>d<CR>\" or \".<CR>\", " "continue to next poly with \";<CR>\")" msgstr "" #. STID_READ_INT_ERROR_FOR_POLY_PTS #: ../../strtbl.c:2530 msgid "Error reading integer for poly points." msgstr "" #. STID_TOO_FEW_POINTERS_ENTERED #: ../../strtbl.c:2532 msgid "Too few points entered." msgstr "" #. STID_TOO_FEW_VER_TO_CLOSE_POLY #: ../../strtbl.c:2534 msgid "Too few vertices to close a polyline/open-spline." msgstr "" #. STID_HUH_WHERE_ARE_THE_VERTICES #: ../../strtbl.c:2536 msgid "Huh? Where are the vertices?" msgstr "" #. STID_HUH_TOPVSEL_NE_BOTVSEL #: ../../strtbl.c:2538 msgid "Huh? How can topVSel != botVSel?" msgstr "" #. STID_CMD_ONLY_AVAIL_IN_VERSEL_MODE #: ../../strtbl.c:2540 msgid "This command is only available in vertex or select mode." msgstr "" #. STID_SEL_2_ENDPOINT_VER_TO_JOIN #: ../../strtbl.c:2542 msgid "Please select 2 end-point vertices to join." msgstr "" #. STID_SEL_VER_FROM_POLY_OPEN_ONLY #: ../../strtbl.c:2544 msgid "Please select vertices from polylines/open-splines only." msgstr "" #. STID_SEL_2_POLYLINES_OPEN_SPLINES #: ../../strtbl.c:2546 msgid "Please select 2 polylines/open-splines." msgstr "" #. STID_CANT_JOIN_INTSPLINE_W_NONEINT #: ../../strtbl.c:2548 msgid "" "Cannot join a interpolated spline with a non-interpolated polyline/open-" "spline." msgstr "" #. STID_SEL_1_VERTEX_TO_CUT #: ../../strtbl.c:2550 msgid "Please select 1 vertex to cut." msgstr "" #. STID_SEL_A_VERTEX_FROM_POLY_OR_GON #: ../../strtbl.c:2552 msgid "Please select a vertex from a polyline or polygon object." msgstr "" #. STID_INVALID_SMOOTHHINGE_SPEC_POLY #: ../../strtbl.c:2554 #, c-format msgid "" "%s, %d: Invalid smooth/hinge spec for a poly/polygon object. Read aborted" msgstr "" #. STID_INVALID_NUM_PTS_IN_POLY #: ../../strtbl.c:2556 #, c-format msgid "%s, %d: Invalid number of points in a poly object. Read aborted" msgstr "" #. STID_INPUT_PAIRS_OF_POINTS_POLYGON #: ../../strtbl.c:2558 msgid "" "Please input pairs of points: (terminate with \"<Cntrl>d<CR>\" or \".<CR>\", " "continue to next polygon with \";<CR>\")" msgstr "" #. STID_READ_INT_ERR_FOR_POLYGON_PTS #: ../../strtbl.c:2560 msgid "Error reading integer for polygon points." msgstr "" #. STID_INVALID_NUM_PTS_IN_POLYGON #: ../../strtbl.c:2562 #, c-format msgid "%s, %d: Invalid number of points in a polygon. Read aborted" msgstr "" #. STID_CANT_GET_XDEF_DEF_WIDTHS_USED #: ../../strtbl.c:2564 #, c-format msgid "Error in getting X default %s.%s. Default widths used." msgstr "" #. STID_ERR_SETCTM_CALLED_CTM_NONNULL #: ../../strtbl.c:2566 msgid "Error: SetCTM() is called with ObjPtr->ctm != NULL." msgstr "" #. STID_MEASUREMENT_SHOWN_IN_UNIT #: ../../strtbl.c:2572 #, c-format msgid "Measurement will be shown in '%s' (%s %s)." msgstr "" #. STID_BAD_MEASUREMENT_UNIT_SPEC #: ../../strtbl.c:2574 #, c-format msgid "Bad measurement unit specification '%s'." msgstr "" #. STID_SHOW_CROSSHAIR_ENABLED #: ../../strtbl.c:2576 msgid "Showing cross-hair enabled." msgstr "" #. STID_SHOW_CROSSHAIR_DISABLED #: ../../strtbl.c:2578 msgid "Showing cross-hair disabled." msgstr "" #. STID_SHOW_MEASUREMENT_ENABLED #: ../../strtbl.c:2580 msgid "Showing measurement enabled." msgstr "đÏËÁÚ ÒÁÚÍĆÒÏŚ ÒÁÚÒĆÛĆÎ." #. STID_SHOW_MEASUREMENT_DISABLED #: ../../strtbl.c:2582 msgid "Showing measurement disabled." msgstr "đÏËÁÚ ÒÁÚÍĆÒÏŚ ÚÁĐÒĆĘĆÎ." #. STID_CANNOT_EXECUTE_GIVEN_CMD #: ../../strtbl.c:2584 #, c-format msgid "Cannot execute '%s'." msgstr "îĆ ŐÄÁÌÏÓŰ ÉÓĐÏÌÎÉÔŰ '%s'." #. STID_CONNECTION_INTERRUPTED #: ../../strtbl.c:2586 #, c-format msgid "%s: connection interrupted." msgstr "%s: ÓÏĆÄÉÎĆÎÉĆ ĐÒĆÒŚÁÎÏ." #. STID_CANT_CONN_TO_HOST_PORT #: ../../strtbl.c:2588 #, c-format msgid "%s: cannot connect to %s%s%s." msgstr "%s: ÎĆ ŐÄÁÌÏÓŰ ÓÏĆÄÉÎÉÔŰÓŃ Ó %s%s%s." #. STID_FAIL_TO_GET_DATA_FROM_URL #: ../../strtbl.c:2590 #, c-format msgid "%s: fail to get data from '%s'." msgstr "%s: ÏÛÉÂËÁ ȚÔĆÎÉŃ ÄÁÎÎÙÈ ÉÚ '%s'." #. STID_NETWORK_ERR_TALK_TO_HOST_PORT #: ../../strtbl.c:2592 #, c-format msgid "%s: network error occurred when talking to %s%s%s." msgstr "%s: ŚÏ ŚÒĆÍŃ ÏÂĘĆÎÉŃ Ó %s%s%s ĐÒÏÉÚÏÛÌÁ ÏÛÉÂËÁ ÓĆÔÉ." #. STID_FAILED_TO_LOGIN_TO_HOST_PORT #: ../../strtbl.c:2594 #, c-format msgid "%s: fail to login to %s%s%s." msgstr "" #. STID_CANT_FIND_LOCATION_IN_HDR #: ../../strtbl.c:2596 #, c-format msgid "" "%s: Cannot find forwarding 'Location' information in message header while " "getting data from '%s'." msgstr "" #. STID_LNK_FWD_5_TIMES_LOAD_ABORT #: ../../strtbl.c:2598 #, c-format msgid "" "%s: Links forwarded more than 5 times while getting data from '%s'.\n" "\n" "Loading is aborted." msgstr "" #. STID_CANT_FIND_WWW_AUTHEN_IN_HDR #: ../../strtbl.c:2600 #, c-format msgid "" "%s: Cannot find 'WWW-Authenticate' information in message header while " "getting data from '%s'." msgstr "" #. STID_AUTHEN_REQ_FOR_REALM #: ../../strtbl.c:2602 #, c-format msgid "%s: Authentication information for %s required..." msgstr "" #. STID_ENTER_USERNAME_FOR_REALM #: ../../strtbl.c:2604 #, c-format msgid "Please enter UserName for %s:" msgstr "śŚĆÄÉÔĆ ÉÍŃ ĐÏÌŰÚÏŚÁÔĆÌŃ ÄÌŃ %s:" #. STID_ENTER_PASSWORD_FOR_REALM #: ../../strtbl.c:2606 #, c-format msgid "Please enter Password for %s:" msgstr "śŚĆÄÉÔĆ ĐÁÒÏÌŰ ÄÌŃ %s:" #. STID_FAIL_TO_PARSE_GIVEN_URL #: ../../strtbl.c:2608 #, c-format msgid "Fail to parse URL: '%s'." msgstr "îĆ ŐÄÁÌÏÓŰ ÒÁÚÏÂÒÁÔŰ URL: '%s'." #. STID_TOOL_NOT_KNOW_HOW_TALK_PROTO #: ../../strtbl.c:2610 #, c-format msgid "%s does not know how to talk using the '%s' protocol." msgstr "" #. STID_LAUNCH_GIVEN_VIEWER #: ../../strtbl.c:2612 #, c-format msgid "Launch viewer: %s" msgstr "" #. STID_CANT_OPEN_GIVEN_MAILCAP_FILE #: ../../strtbl.c:2614 #, c-format msgid "Cannot open mailcap file '%s'." msgstr "îĆ ŐÄÁÌÏÓŰ ÏÔËÒÙÔŰ ÆÁÊÌ mailcap '%s'." #. STID_MALFORMED_MAILCAP_ENTRY #: ../../strtbl.c:2616 #, c-format msgid "" "Malformed mailcap entry:\n" "\n" "%s/%s; %s" msgstr "" #. STID_MALFORMED_MAILCAP_ENTRY_PARAM #: ../../strtbl.c:2618 #, c-format msgid "" "Malformed mailcap entry:\n" "\n" "%s/%s; %s; %s" msgstr "" #. STID_TOOL_CANT_HANDLE_MP_MIME #: ../../strtbl.c:2620 #, c-format msgid "%s does not know how to handle Multipart MIME types." msgstr "" #. STID_CANT_FIND_RT_BRACK_MC #: ../../strtbl.c:2622 #, c-format msgid "" "Cannot find matching '}' for mailcap entry:\n" "\n" "%s/%s; %s" msgstr "" #. STID_CANT_FIND_RT_BRACK_MC_PARAM #: ../../strtbl.c:2624 #, c-format msgid "" "Cannot find matching '}' for mailcap entry:\n" "\n" "%s/%s; %s; %s" msgstr "" #. STID_CANT_FIND_NAMED_INFO_IN_CT #: ../../strtbl.c:2626 #, c-format msgid "%s: cannot find the '%s' information in the message Content-Type." msgstr "" #. STID_SAVE_GIVEN_STR_AS #: ../../strtbl.c:2628 #, c-format msgid "Save %s as:" msgstr "óÏÈÒÁÎÉÔŰ %s ËÁË:" #. STID_NO_VIEWER_SAVE_GIVEN_STR_AS #: ../../strtbl.c:2630 #, c-format msgid "No viewer found. Save %s as:" msgstr "" #. STID_UNKNOWN_ERR_IN_COPYING_FILES #: ../../strtbl.c:2632 msgid "Unknown error in copying files." msgstr "îĆÉÚŚĆÓÔÎÁŃ ÏÛÉÂËÁ ĐÒÉ ËÏĐÉÒÏŚÁÎÉÉ ÆÁÊÌÏŚ." #. STID_CANT_GETHOSTNAME_USE_LOCALH #: ../../strtbl.c:2634 msgid "Cannot gethostname(), 'localhost' is used instead." msgstr "" #. STID_TURN_OFF_AUTO_PAN_SET_XDEF #: ../../strtbl.c:2636 #, c-format msgid "To turn off auto-panning, set %s.%s to false in X defaults." msgstr "" #. STID_WILL_UPD_WIN_SMOOTH_SCROLL #: ../../strtbl.c:2638 msgid "Will update canvas window smoothly while scrolling." msgstr "" #. STID_WILL_UPD_WIN_JUMP_SCROLL #: ../../strtbl.c:2640 msgid "Will jump update canvas window while scrolling." msgstr "" #. STID_WILL_NOT_UPD_WIN_SCROLL #: ../../strtbl.c:2642 msgid "Will not update canvas window while scrolling." msgstr "" #. STID_INCONSIS_VERTEX_SEL_IN_FUNC #: ../../strtbl.c:2644 #, c-format msgid "Inconsistent vertex selection detected in %s." msgstr "" #. STID_INVALID_NAMED_TELEPORT_DEST #: ../../strtbl.c:2646 #, c-format msgid "Invalid teleport destination '%s'." msgstr "" #. STID_Q_FILE_NOT_EXIST_CREATE #: ../../strtbl.c:2648 #, c-format msgid "" "File '%s' does not exist.\n" "\n" "Would you like to create it?" msgstr "" "æÁÊÌ '%s' ÎĆ ÓŐĘĆÓÔŚŐĆÔ.\n" "\n" "óÏÚÄÁÔŰ?" #. STID_CANT_FIND_PAGE_NAMED_TO_TEL #: ../../strtbl.c:2650 #, c-format msgid "Cannot find page named '%s' to teleport to." msgstr "" #. STID_CANT_FIND_PAGE_NUM_TO_TEL #: ../../strtbl.c:2652 #, c-format msgid "Cannot find page %1d to teleport to." msgstr "" #. STID_CANT_GROUP_IN_VERTEX_MODE #: ../../strtbl.c:2654 msgid "Cannot group in vertex mode." msgstr "" #. STID_CANT_GROUP_SINGLE_OBJECT #: ../../strtbl.c:2656 msgid "Cannot group a single object." msgstr "îĆŚÏÚÍÏÖÎÏ ÓÇÒŐĐĐÉÒÏŚÁÔŰ ÏÄÉÎ ĆÄÉÎÓÔŚĆÎÎÙÊ ÏÂßĆËÔ." #. STID_INVALID_XDEF_USE_ALT_OCTVALUE #: ../../strtbl.c:2658 #, c-format msgid "Invalid %s.%s: '%s', 0%03o is used instead." msgstr "" #. STID_INVALID_XDEF_RNG_USE_ALT_STR #: ../../strtbl.c:2660 #, c-format msgid "Invalid %s.%s: '%s', (must be between %s and %s), %s is used instead." msgstr "" #. STID_CANT_CREATE_NAMED_DIRECTORY #: ../../strtbl.c:2662 #, c-format msgid "Cannot create the '%s' directory." msgstr "îĆ ŐÄÁÌÏÓŰ ÓÏÚÄÁÔŰ ËÁÔÁÌÏÇ '%s'." #. STID_OPR_USING_NAMED_DIR_WILL_FAIL #: ../../strtbl.c:2664 #, c-format msgid "" "Operations using the '%s' directory (such as CopyProperties() and " "PasteProperties()) will fail." msgstr "" #. STID_CREATE_A_SHAPE_FAILED #: ../../strtbl.c:2666 msgid "Create a shape failed." msgstr "" #. STID_CREATE_SHADOW_SHAPE_NO_FILL #: ../../strtbl.c:2668 msgid "" "You are attempting to create a shadowed shape but the shape has no fill (the " "shadow will show through).\n" "\n" "Would you like to create such a shape without a shadow?" msgstr "" #. STID_CREATE_SHADOW_SHAPE_TRAN_FILL #: ../../strtbl.c:2670 msgid "" "You are attempting to create a shadowed shape but the shape has transparent " "fill (the shadow will show through).\n" "\n" "Would you like to create such a shape without a shadow?" msgstr "" #. STID_ENTER_XY_OFFSET_FOR_SHP_SHDW #: ../../strtbl.c:2672 #, c-format msgid "Please enter X and Y offsets for the shape shadow: [current: %1d,%1d]" msgstr "" #. STID_SHAPE_SHDW_XY_OFFSETS_SET_TO #: ../../strtbl.c:2674 #, c-format msgid "Shape shadow offsets set to: %1d, %1d." msgstr "" #. STID_INVALID_SHORTCUT_ENTRY_SKIP #: ../../strtbl.c:2676 #, c-format msgid "Invalid shortcut entry: '%s'. It is skipped." msgstr "" #. STID_DUP_SHORTCUT_ENTRY_FOR_CHAR #: ../../strtbl.c:2678 #, c-format msgid "Warning: duplicate shortcut entry for '%c'." msgstr "" #. STID_INVALID_SHORTCUT_ENTRY #: ../../strtbl.c:2680 #, c-format msgid "Invalid shortcut entry: '%s'." msgstr "" #. STID_WARN_DUP_CMDID #: ../../strtbl.c:2682 #, c-format msgid "Warning: duplicate cmdid %1d." msgstr "" #. STID_PUSH_IN_WB #: ../../strtbl.c:2684 msgid "Push() is disabled in WhiteBoard mode." msgstr "" #. STID_FILE_VER_ABORT_READ_SYMBOL #: ../../strtbl.c:2686 #, c-format msgid "" "File version (=%1d) too large.\n" "\n" "Read symbol aborted.\n" "\n" "You may need a more recent version of %s. Please check <URL:%s>." msgstr "" #. STID_CANT_FIND_NAMED_OBJ_IN_FUNC #: ../../strtbl.c:2688 #, c-format msgid "Cannot find the '%s' text object in %s." msgstr "îĆ ŐÄÁÌÏÓŰ ÎÁÊÔÉ ÔĆËÓÔÏŚÙÊ ÏÂßĆËÔ '%s' Ś '%s'." #. STID_SEL_A_SYM_TO_INSTAN_IN_DOMAIN #: ../../strtbl.c:2690 #, c-format msgid "Please select a symbol to INSTANTIATE in the '%s' domain..." msgstr "" #. STID_CANT_INSTAN_FILE_UNKNOWN_EXT #: ../../strtbl.c:2692 #, c-format msgid "Cannot instantiate because '%s' has unknow file extension." msgstr "" #. STID_CANT_MAKESYMBOLIC_VERTEX_MODE #: ../../strtbl.c:2694 msgid "Cannot MakeSymbolic() in vertex mode." msgstr "" #. STID_SEL_ONLY_ONE_FOR_MAKESYMBOLIC #: ../../strtbl.c:2696 msgid "Please select only one object for MakeSymbolic()." msgstr "" #. STID_PIN_CANT_MADE_INTO_SYMBOL #: ../../strtbl.c:2698 msgid "A pin object cannot be made into a symbol object." msgstr "" #. STID_SEL_OBJ_IS_NOW_SYMBOLIC #: ../../strtbl.c:2700 msgid "Selected object is now SYMBOLIC." msgstr "" #. STID_ENTER_NAME_FOR_THE_ICON #: ../../strtbl.c:2702 msgid "Please enter name for the icon:" msgstr "" #. STID_NAME_NOT_SPEC_ICON_NOT_CREATE #: ../../strtbl.c:2704 msgid "Name not specified, icon not created." msgstr "" #. STID_CANT_SAVE_OBJ_ICON_NOT_CREATE #: ../../strtbl.c:2706 msgid "Cannot save as an object file, icon not created." msgstr "" #. STID_CANT_FIND_DOT_IN_ICON_NAME_MI #: ../../strtbl.c:2708 msgid "Cannot find '.' in icon_name in MakeIconic()." msgstr "" #. STID_CANT_SAVE_PIN_ICON_NOT_CREATE #: ../../strtbl.c:2710 msgid "Cannot save as a pin file, icon not created." msgstr "" #. STID_CANT_OPEN_FOR_WRITE_ICON_CRET #: ../../strtbl.c:2712 #, c-format msgid "Cannot open '%s' for writing, icon not created." msgstr "" #. STID_SEL_OBJ_IS_NOW_ICONIC #: ../../strtbl.c:2714 msgid "Selected object is now ICONIC." msgstr "" #. STID_SEL_ONLY_ONE_FOR_MAKEICONIC #: ../../strtbl.c:2716 msgid "Please select one object to make it ICONIC." msgstr "" #. STID_SEL_OBJS_ARE_NOW_GROUP #: ../../strtbl.c:2718 msgid "Selected ICONIC objects are GROUP objects now." msgstr "" #. STID_GIVEN_LINE_SKIP_NOT_AN_ATTR #: ../../strtbl.c:2720 #, c-format msgid "Line %1d in '%s' is skipped because it does not specify an attribute." msgstr "" #. STID_GIVEN_LINE_SKIP_ILLEGAL_CHAR #: ../../strtbl.c:2722 #, c-format msgid "" "Line %1d in '%s' is skipped because attribute name contains illegal " "characters such as '!' or '.'." msgstr "" #. STID_SEL_ONE_OBJ_FOR_IMPORTATTRS #: ../../strtbl.c:2724 msgid "Please select only one object for ImportAttrs()." msgstr "" #. STID_SEL_TEXT_FILE_OF_ATTR_TO_IMP #: ../../strtbl.c:2726 msgid "Please select a text file containing attributes to import..." msgstr "" #. STID_CANT_IMPORT_REMOTE_TEXT_FILE #: ../../strtbl.c:2728 msgid "Importing remote text file not supported." msgstr "" #. STID_SEL_ONE_OBJ_FOR_EXPORTATTRS #: ../../strtbl.c:2730 msgid "Please select only one object for ExportAttrs()." msgstr "" #. STID_SEL_OBJ_HAS_NO_ATTR_TO_EXPORT #: ../../strtbl.c:2732 msgid "Select object has no attributes to export." msgstr "" #. STID_ENTER_TXT_FILE_TO_EXPORT_CRES #: ../../strtbl.c:2734 msgid "" "Please enter a text file name to export to: ( <CR>: accept, <ESC>: cancel )" msgstr "" #. STID_ATTR_EXPORTED_TO_NAMED_FILE #: ../../strtbl.c:2736 #, c-format msgid "Attributes exported to '%s'." msgstr "" #. STID_CANT_FIND_ATTR_FOR_MERGEWTBL #: ../../strtbl.c:2738 #, c-format msgid "Cannot find the '%s' attribute for MergeWithTable()." msgstr "" #. STID_MALFORMED_ATTR_FOR_MERGEWTBL #: ../../strtbl.c:2740 #, c-format msgid "Malformed '%s' attribute for MergeWithTable()." msgstr "" #. STID_SEL_ONE_OBJ_FOR_MERGEWTBL #: ../../strtbl.c:2742 msgid "Please select only one object for MergeWithTable()." msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_MERGE #: ../../strtbl.c:2744 msgid "File modified, save file before merge? [ync](y)" msgstr "" #. STID_Q_MERGEWTBL_CANT_UNDO_PROCEED #: ../../strtbl.c:2746 msgid "" "MergeWithTable cannot be undone.\n" "\n" "Ok to proceed? [ync](y)" msgstr "" #. STID_SEL_TEXT_FILE_FOR_MERGEWTBL #: ../../strtbl.c:2748 msgid "Please select a text file for MergeWithTable()." msgstr "" #. STID_CANT_MERGE_W_REMOTE_TEXT_FILE #: ../../strtbl.c:2750 msgid "Merging remote text file not supported." msgstr "" #. STID_FIND_COL_NAMES_IN_FILE_ABORT #: ../../strtbl.c:2752 #, c-format msgid "" "Cannot find column names in '%s'.\n" "\n" "Merge aborted." msgstr "" #. STID_MALFORMED_COL_NAMES_ABORT_MRG #: ../../strtbl.c:2754 #, c-format msgid "" "Malformed column names in '%s'.\n" "\n" "Merge aborted." msgstr "" #. STID_LF_BTN_PLACE_MRG_OTHER_CANCEL #: ../../strtbl.c:2756 msgid "Left button places a merged object, other buttons cancel merging." msgstr "" #. STID_MALFORMED_TBL_LINE_ABORT_MRG #: ../../strtbl.c:2758 #, c-format msgid "" "Malformed table at line %d in '%s'.\n" "\n" "Merge aborted." msgstr "" #. STID_CANT_FND_NAMED_ATTR_ABORT_MRG #: ../../strtbl.c:2760 #, c-format msgid "" "Cannot find attribute named '%s'.\n" "\n" "Merge aborted." msgstr "" #. STID_NUM_OBJECTS_GENERATED #: ../../strtbl.c:2762 #, c-format msgid "%1d object(s) generated." msgstr "" #. STID_CANT_FND_TABLE_ATTRS_FILE_ATT #: ../../strtbl.c:2764 msgid "" "Cannot find the \"!.TABLE_ATTRS\" file attribute.\n" "\n" "Cannot proceed with ExportToTable()." msgstr "" "îĆ ŐÄÁÌÏÓŰ ÎÁÊÔÉ ÁÔÒÉÂŐÔ ÆÁÊÌÁ \"!.TABLE_ATTRS\".\n" "\n" "đÒÏÄÏÌÖĆÎÉĆ ExportToTable() ÎĆŚÏÚÍÏÖÎÏ." #. STID_NUM_OBJECTS_EXPORTED #: ../../strtbl.c:2766 #, c-format msgid "%1d object(s) exported." msgstr "ïÂßĆËÔÏŚ ÜËÓĐÏÒÔÉÒÏŚÁÎÏ: %1d." #. STID_ATTRS_EXPORTED_TO_TBL_FILE #: ../../strtbl.c:2768 #, c-format msgid "Attributes exported to table file '%s'." msgstr "áÔÒÉÂŐÔÙ ÜËÓĐÏÒÔÉÒÏŚÁÎÙ Ś ÔÁÂÌÉȚÎÙÊ ÆÁÊÌ '%s'." #. STID_SEL_ONE_ICON_OBJ_TO_PUSH #: ../../strtbl.c:2770 msgid "Please select one ICON object to push into." msgstr "" #. STID_CANT_FND_SYM_FILE_IN_PATH #: ../../strtbl.c:2776 #, c-format msgid "Cannot find '%s.%s' in %s." msgstr "îĆ ŐÄÁÌÏÓŰ ÎÁÊÔÉ '%s.%s' Ś %s." #. STID_CANNOT_OPEN_FOR_READ_PUSH #: ../../strtbl.c:2778 #, c-format msgid "Cannot open '%s' for reading. Icon not pushed into." msgstr "" #. STID_FILE_VER_ABORT_PUSH #: ../../strtbl.c:2780 #, c-format msgid "" "File version (=%1d) too large.\n" "\n" "Push aborted.\n" "\n" "You may need a more recent version of %s. Please check <URL:%s>." msgstr "" #. STID_POP_BACK_TO_PARENT_UNDEF #: ../../strtbl.c:2782 msgid "Poping back to parent level. Current file undefined." msgstr "" #. STID_ALREADY_AT_TOP_LEVEL #: ../../strtbl.c:2784 msgid "Already at top level." msgstr "őÖĆ ÎÁ ŚĆÒÈÎĆÍ ŐÒÏŚÎĆ." #. STID_FILE_MOD_SAVE_BEFORE_POP #: ../../strtbl.c:2786 msgid "" "File modified, save file before poping back to the parent level? [ync](y)" msgstr "" #. STID_CANT_FND_SYM_IN_NAMED_TO_INST #: ../../strtbl.c:2788 #, c-format msgid "Cannot find a symbol object in '%s' to instantiate." msgstr "" #. STID_CANT_FIND_XDEF #: ../../strtbl.c:2790 #, c-format msgid "Cannot find %s.%s." msgstr "îĆ ŐÄÁÌÏÓŰ ÎÁÊÔÉ %s.%s." #. STID_ENTER_USERAGENT_FOR_HTTP #: ../../strtbl.c:2792 msgid "Please specify 'UserAgent' to be used when making an HTTP request." msgstr "" #. STID_ENTER_USERAGENT_FOR_HTTP_CUR #: ../../strtbl.c:2794 #, c-format msgid "" "Please specify 'UserAgent' to be used when making an HTTP request (current " "value is '%s')." msgstr "" #. STID_PRESS_ENTER_FOR_DEF_USERAGENT #: ../../strtbl.c:2796 msgid "( press <ENTER> for the default 'UserAgent' )" msgstr "" #. STID_WILL_USE_DEF_USERAGENT_HTTP #: ../../strtbl.c:2798 msgid "Will use the default 'UserAgent' when making an HTTP request." msgstr "" #. STID_WILL_USE_NAMED_USERAGENT_HTTP #: ../../strtbl.c:2800 #, c-format msgid "Will use '%s' as 'UserAgent' when making an HTTP request." msgstr "" #. STID_ENTER_REFERRER_FOR_HTTP #: ../../strtbl.c:2802 msgid "Please specify 'Referrer' to be used when making an HTTP request." msgstr "" #. STID_ENTER_REFERRER_FOR_HTTP_CUR #: ../../strtbl.c:2804 #, c-format msgid "" "Please specify 'Referrer' to be used when making an HTTP request (current " "value is '%s')." msgstr "" #. STID_PRESS_ENTER_FOR_NO_REFERRER #: ../../strtbl.c:2806 msgid "( press <ENTER> for no 'Referrer' )" msgstr "" #. STID_WILL_NOT_USE_REFERRER_HTTP #: ../../strtbl.c:2808 msgid "Will not use 'Referrer' when making an HTTP request." msgstr "" #. STID_WILL_USE_NAMED_REFERRER_HTTP #: ../../strtbl.c:2810 #, c-format msgid "Will use '%s' as 'Referrer' when making an HTTP request." msgstr "" #. STID_WILL_USE_KEEP_ALIVE_HTTP #: ../../strtbl.c:2812 msgid "Will use Keep-Alive HTTP connections." msgstr "" #. STID_NOT_WILL_USE_KEEP_ALIVE_HTTP #: ../../strtbl.c:2814 msgid "Will not use Keep-Alive HTTP connections." msgstr "" #. STID_CANT_LOCATE_NAMED_SERVER_TRY #: ../../strtbl.c:2816 #, c-format msgid "" "%s: unable to locate the server '%s'.\n" "\n" "Please check the server name and try again." msgstr "" #. STID_FAIL_TO_MAKE_SOCKET_BLOCK #: ../../strtbl.c:2818 msgid "Fail to make socket blocking." msgstr "" #. STID_FAIL_TO_MAKE_SOCKET_NON_BLOCK #: ../../strtbl.c:2820 msgid "Fail to make socket non-blocking." msgstr "" #. STID_BROKEN_PIPE_CONTACT_HOST #: ../../strtbl.c:2822 #, c-format msgid "Broken pipe while contacting '%s'." msgstr "" #. STID_WRITE_TO_SOCKET_FAILED #: ../../strtbl.c:2824 msgid "Writing to socket failed." msgstr "" #. STID_READ_FROM_SOCKET_FAILED #: ../../strtbl.c:2826 msgid "Reading from socket failed." msgstr "" #. STID_UNEXP_NETWORK_ERR_WRITE_SOCK #: ../../strtbl.c:2828 msgid "Unexpected network error while writing to socket." msgstr "" #. STID_UNEXP_NETWORK_ERR_READ_SOCK #: ../../strtbl.c:2830 msgid "Unexpected network error while reading from socket." msgstr "" #. STID_LOCKED_OBJS_CANT_BE_STRETCHED #: ../../strtbl.c:2832 msgid "Locked object(s) cannot be stretched." msgstr "" #. STID_CANT_STRETCH_OBJ_HAS_0_WIDTH #: ../../strtbl.c:2834 msgid "Cannot stretch. Object has ZERO width." msgstr "" #. STID_CANT_STRETCH_OBJ_HAS_0_HEIGHT #: ../../strtbl.c:2836 msgid "Cannot stretch. Object has ZERO height." msgstr "" #. STID_LOCKED_OBJS_CANT_BE_SCALED #: ../../strtbl.c:2838 msgid "Locked object(s) cannot be scaled." msgstr "" #. STID_ENTER_SCALING_FACTORS_XY #: ../../strtbl.c:2840 msgid "Please enter scaling factors: [X:Y] or [scale]" msgstr "" #. STID_ENTER_A_SCALING_FACTOR #: ../../strtbl.c:2842 msgid "Please enter a scaling factor:" msgstr "" #. STID_ONLY_INPUT_ONE_NUMERIC_VAL #: ../../strtbl.c:2844 msgid "Please only input only one numeric value." msgstr "" #. STID_SCALING_EVERYTHING_LARGE_SURE #: ../../strtbl.c:2846 #, c-format msgid "Scaling everything by %g times. Are you sure?" msgstr "" #. STID_DISABLE_ON_RESIZE_ROTATE #: ../../strtbl.c:2848 #, c-format msgid "" "The '%s' object has an on_resize() script.\n" "\n" "To rotate it will disable the on_resize() script. Is it okay to rotate it?" msgstr "" #. STID_DISABLE_ON_RESIZE_SHEAR #: ../../strtbl.c:2850 #, c-format msgid "" "The '%s' object has an on_resize() script.\n" "\n" "To shear it will disable the on_resize() script. Is it okay to shear it?" msgstr "" #. STID_DISABLE_ON_RESIZE_TRANSFORM #: ../../strtbl.c:2852 #, c-format msgid "" "The '%s' object has an on_resize() script.\n" "\n" "To transform it will disable the on_resize() script. Is it okay to " "transform it?" msgstr "" #. STID_LOCKED_OBJS_CANT_BE_FLIPPED #: ../../strtbl.c:2854 msgid "Locked object(s) cannot be flipped." msgstr "" #. STID_LOCKED_OBJS_ARE_NOT_FLIPPED #: ../../strtbl.c:2856 msgid "Locked object(s) are not flipped." msgstr "" #. STID_LOCKED_OBJS_ARE_NOT_STRETCHED #: ../../strtbl.c:2858 msgid "Locked object(s) are not stretched." msgstr "" #. STID_LOCKED_OBJS_ARE_NOT_ROTATED #: ../../strtbl.c:2860 msgid "Locked object(s) are not rotated." msgstr "" #. STID_LOCKED_OBJS_ARE_NOT_SHEARED #: ../../strtbl.c:2862 msgid "Locked object(s) are not sheared." msgstr "" #. STID_LOCKED_OBJS_ARE_NOT_XFORMED #: ../../strtbl.c:2864 msgid "Transformation matrix not changed for locked object(s)." msgstr "" #. STID_FLIPPED_HORIZONTALLY #: ../../strtbl.c:2866 #, fuzzy msgid "Flipped horizontally." msgstr "đĆÒĆŚĆÒÎŐÔŰ ĐÏ ÇÏÒÉÚÏÎÔÁÌÉ" #. STID_FLIPPED_VERTICALLY #: ../../strtbl.c:2868 #, fuzzy msgid "Flipped vertically." msgstr "đĆÒĆŚĆÒÎŐÔŰ ĐÏ ŚĆÒÔÉËÁÌÉ" #. STID_LOCKED_OBJS_CANT_BE_ROTATED #: ../../strtbl.c:2870 msgid "Locked object(s) cannot be rotated." msgstr "" #. STID_ROTATED_CLOCKWISE #: ../../strtbl.c:2872 #, fuzzy msgid "Rotated clockwise." msgstr "śÒÁĘÁÔŰ ĐÏ ȚÁÓÏŚÏÊ" #. STID_ROTATED_COUNTER_CLOCKWISE #: ../../strtbl.c:2874 #, fuzzy msgid "Rotated counter-clockwise." msgstr "śÒÁĘÁÔŰ ĐÏ ȚÁÓÏŚÏÊ" #. STID_ENTER_TEXT_ROT_IN_DEGREE_CUR #: ../../strtbl.c:2876 #, c-format msgid "Please enter text rotation in degrees: (current value is %s)" msgstr "" #. STID_CANT_PARSE_ENTER_ONE_NUM_VAL #: ../../strtbl.c:2878 #, c-format msgid "" "Cannot parse '%s'.\n" "\n" "Please enter a numeric value." msgstr "" "îĆ ŐÄÁÌÏÓŰ ÒÁÚÏÂÒÁÔŰ '%s'.\n" "\n" "śŚĆÄÉÔĆ ȚÉÓÌÏŚÏĆ ÚÎÁȚĆÎÉĆ." #. STID_INVALID_VAL_ENTERED_RNG_INC #: ../../strtbl.c:2880 #, c-format msgid "" "Invalid value entered: '%s'. Please enter a numeric value between %1d and %" "1d (inclusive)." msgstr "śŚĆÄĆÎÏ ÎĆŚĆÒÎÏĆ ÚÎÁȚĆÎÉĆ: '%s' śŚĆÄÉÔĆ ȚÉÓÌÏŚÏĆ ÚÎÁȚĆÎÉĆ ÍĆÖÄŐ %1d É %1d (ŚËÌÀȚÉÔĆÌŰÎÏ)." #. STID_TEXT_ROTATION_SET_TO_GIVEN #: ../../strtbl.c:2882 #, c-format msgid "Text rotation set to %s." msgstr "" #. STID_ENTER_ROT_INC_IN_DEGREE_CUR #: ../../strtbl.c:2884 #, c-format msgid "Please enter text rotation increment in degrees: (current value is %s)" msgstr "śŚĆÄÉÔĆ ÛÁÇ ĐÏŚÏÒÏÔÁ ÔĆËÓÔÁ Ś ÇÒÁÄŐÓÁÈ: (ÔĆËŐĘĆĆ ÚÎÁȚĆÎÉĆ: %s)" #. STID_INVALID_VAL_ENTERED_RNG_EXC #: ../../strtbl.c:2886 #, c-format msgid "" "Invalid value entered: '%s'. Please enter a numeric value > %1d and < %1d." msgstr "śŚĆÄĆÎÏ ÎĆŚĆÒÎÏĆ ÚÎÁȚĆÎÉĆ: '%s' śŚĆÄÉÔĆ ȚÉÓÌÏŚÏĆ ÚÎÁȚĆÎÉĆ ÍĆÖÄŐ > %1d É < %1d." #. STID_TEXT_ROT_INC_SET_TO_GIVEN #: ../../strtbl.c:2888 #, c-format msgid "Text rotation increment set to %s." msgstr "ûÁÇ ĐÏŚÏÒÏÔÁ ÔĆËÓÔÁ ŐÓÔÁÎÏŚÌĆÎ Ś %s." #. STID_LOCKED_OBJS_CANT_BE_XFORMED #: ../../strtbl.c:2890 msgid "Cannot change transformation matrix for locked object(s)." msgstr "" #. STID_SEL_OBJ_TOO_SMALL_ROT_ANOTHER #: ../../strtbl.c:2892 msgid "" "Selected object is too small to rotate.\n" "\n" "Please select another object to rotate." msgstr "" "śÙÄĆÌĆÎÎÙÊ ÏÂßĆËÔ ÓÌÉÛËÏÍ ÍÁÌ ÄÌŃ ŚÒÁĘĆÎÉŃ.\n" "\n" "śÙÂĆÒÉÔĆ ÄÒŐÇÏÊ ÏÂßĆËÔ ÄÌŃ ŚÒÁĘĆÎÉŃ." #. STID_SEL_OBJ_TOO_SMALL_SHEAR_ANO #: ../../strtbl.c:2894 msgid "" "Selected object is too small to shear.\n" "\n" "Please select another object to shear." msgstr "" #. STID_CANNOT_CREATE_GC #: ../../strtbl.c:2896 msgid "Cannot create GC." msgstr "" #. STID_READ_ONLY_TEXT_CANT_BE_EDITED #: ../../strtbl.c:2898 msgid "Read-only text cannot be edited." msgstr "" #. STID_TEXT_SZ_NOT_AVAIL_TRY_DIFF #: ../../strtbl.c:2900 #, c-format msgid "" "Text size=%1d not available.\n" "\n" "Please try a different size." msgstr "" #. STID_CANT_INS_NON_DB_CH_AT_CUR_REM #: ../../strtbl.c:2902 msgid "" "Cannot insert a non-double-byte character at the text cursor position. The " "non-double-byte character is removed." msgstr "" #. STID_TOO_MANY_BYTES_IN_CH_IGNORED #: ../../strtbl.c:2904 msgid "Cannot handle so many bytes in a character. Character is ignored." msgstr "" #. STID_CANT_TAB_OUT_OF_NON_ATTR_TEXT #: ../../strtbl.c:2906 msgid "Cannot TAB out of a non-attribute text." msgstr "" #. STID_COMPOUND_TEXT_BUF_IS_EMPTY #: ../../strtbl.c:2908 msgid "Compound-text buffer is empty." msgstr "" #. STID_CUT_BUFFER_IS_EMPTY #: ../../strtbl.c:2910 msgid "Cut buffer is empty." msgstr "âŐÆĆÒ ÏÂÍĆÎÁ ĐŐÓÔ." #. STID_GIVEN_NUM_LINES_PASTED #: ../../strtbl.c:2914 #, c-format msgid "%1d line(s) pasted." msgstr "ìÉÎÉÊ ŚÓÔÁŚÌĆÎÏ: %1d." #. STID_COPY_FAIL_SEL_STR_MAY_TOO_LNG #: ../../strtbl.c:2916 msgid "Copy to cut buffer failed. Selected string may be too long." msgstr "ïÛÉÂËÁ ËÏĐÉÒÏŚÁÎÉŃ Ś ÂŐÆĆÒ ÏÂÍĆÎÁ. óËÏÒĆĆ ŚÓĆÇÏ, ŚÙÄĆÌĆÎÎÁŃ ÓÔÒÏËÁ ÓÌÉÛËÏÍ ŚĆÌÉËÁ." #. STID_UNEXPECTED_TOK_IN_ABORT_READ #: ../../strtbl.c:2918 #, c-format msgid "%s, %d: Unexpected token '%c' in %s. Read aborted." msgstr "%s, %d: îĆÏÖÉÄÁÎÎÙÊ ÔÏËĆÎ '%c' Ś %s. țÔĆÎÉĆ ĐÒĆÒŚÁÎÏ." #. STID_ILLEGAL_FIELD_IN_ABORT_READ #: ../../strtbl.c:2920 #, c-format msgid "%s, %d: Illegal field '%s' in %s. Read aborted." msgstr "%s, %d: îĆÄÏĐŐÓÔÉÍÏĆ ĐÏÌĆ '%s' Ś %s. țÔĆÎÉĆ ĐÒĆÒŚÁÎÏ." #. STID_INVALID_GIVEN_VALUE_SPECIFIED #: ../../strtbl.c:2922 #, c-format msgid "Invalid value '%s' specified." msgstr "őËÁÚÁÎÏ ÎĆŚĆÒÎÏĆ ÚÎÁȚĆÎÉĆ '%s'." #. STID_ENTER_SCRIPT_FRACTION_CUR_IS #: ../../strtbl.c:2924 #, c-format msgid "" "Please enter a fraction for the super/subscript size (current fraction is %" "s):" msgstr "" #. STID_SCRIPT_FRACTION_SET_TO_STR #: ../../strtbl.c:2926 #, c-format msgid "Script fraction set to '%s'." msgstr "" #. STID_ENTER_INT_WIDTH_FOR_THIN_SPC #: ../../strtbl.c:2928 msgid "" "Please enter an integer width value for the thin space (a negative value " "indicates a negative think space):" msgstr "" #. STID_ENTER_INT_VAL_FOR_VERT_OFFSET #: ../../strtbl.c:2930 msgid "" "Please enter an integer value for the vertical offset (a negative value " "raises the current line):" msgstr "" #. STID_FAIL_INSERT_SCRIPT_FONT_SZ #: ../../strtbl.c:2932 msgid "Failed to insert super/subscript because font size is not available." msgstr "" #. STID_TOOL_DONT_KNOW_HOW_RUN_GUNZIP #: ../../strtbl.c:2934 #, c-format msgid "%s does not know how to run gunzip." msgstr "" #. STID_SPECIFY_DISPLAY_ON_CMD_LINE #: ../../strtbl.c:2936 msgid "Please specify '-display $DISPLAY' on the command line." msgstr "őËÁÖÉÔĆ '-display $DISPLAY' Ś ËÏÍÁÎÄÎÏÊ ÓÔÒÏËĆ" #. STID_FILE_VER_ABORT_TOOL #: ../../strtbl.c:2938 #, c-format msgid "" "File version (=%1d) too large.\n" "\n" "%s aborted.\n" "\n" "You may need a more recent version of %s. Please check <URL:%s>." msgstr "" "śĆÒÓÉŃ ÆÁÊÌÁ (=%1d) ÓÌÉÛËÏÍ ŚĆÌÉËÁ.\n" "\n" "%s ĐÒĆÒŚÁÎÏ.\n" "\n" "óËÏÒĆĆ ŚÓĆÇÏ, ÎĆÏÂÈÏÄÉÍÁ ÂÏÌĆĆ ÓŚĆÖÁŃ ŚĆÒÓÉŃ %s. đÒÏŚĆÒŰÔĆ <URL:%s>." #. STID_FILE_SKIP_CONTAINS_ONE_PAGE #: ../../strtbl.c:2940 #, c-format msgid "%s is skipped because it only contains 1 page." msgstr "%s ĐÒÏĐŐĘĆÎ, ĐÏÓËÏÌŰËŐ ÓÏÄĆÒÖÉÔ ÔÏÌŰËÏ 1 ÓÔÒÁÎÉĂŐ." #. STID_FILE_SKIP_CONTAINS_NUM_PAGE #: ../../strtbl.c:2942 #, c-format msgid "%s is skipped because it only contains %1d pages." msgstr "%s ĐÒÏĐŐĘĆÎ, ĐÏÓËÏÌŰËŐ ÓÏÄĆÒÖÉÔ ÔÏÌŰËÏ %1d ÓÔÒÁÎÉĂ." #. STID_FILE_NOT_CONTAIN_COLOR_ABORT #: ../../strtbl.c:2944 #, c-format msgid "" "File does not contain enough color information (it is not saved by tgif-3.0-" "p10 or beyond). %s aborted." msgstr "" #. STID_SPEC_FILE_WHEN_STDOUT_USED #: ../../strtbl.c:2946 msgid "File name must be specified when -stdout is used." msgstr "ëÏÇÄÁ ÉÓĐÏÌŰÚŐĆÔÓŃ -stdout, ÉÍŃ ÆÁÊÌÁ ÄÏÌÖÎÏ ÂÙÔŰ ŐËÁÚÁÎÏ." #. STID_TOOL_FILE_NAME_TO_PRINT #: ../../strtbl.c:2948 #, c-format msgid "%s File Name to Print" msgstr "" #. STID_CANT_ONEFPPAGE_IN_TILED_PAGE #: ../../strtbl.c:2950 msgid "Cannot use -one_file_per_page in TILED page mode." msgstr "" #. STID_ONE_FILE_ONLY_WITH_STDOUT #: ../../strtbl.c:2952 msgid "Only one file name can be specified with -stdout." msgstr "" #. STID_ONE_FILE_ONLY_RAW_PLUS_H #: ../../strtbl.c:2954 msgid "Cannot process more than one file in -raw or -raw+h mode." msgstr "" #. STID_ONE_FILE_ONLY_DOSEPSFILTER #: ../../strtbl.c:2956 msgid "Cannot process more than one file in -dosepsfilter mode." msgstr "" #. STID_CANT_PRTGIF_OFPP_TILED_PAGE #: ../../strtbl.c:2958 msgid "Cannot use -one_file_per_page mode with a TILED page mode file." msgstr "" #. STID_INVALID_SHARELIB_VER_IN_FILE #: ../../strtbl.c:2960 #, c-format msgid "Invalid shared library version in '%s'." msgstr "" #. STID_FAIL_LOAD_SHARELIB #: ../../strtbl.c:2962 #, c-format msgid "Fail to load shared library '%s'." msgstr "" #. STID_FAIL_GET_ENTRY_PT_IN_SHARELIB #: ../../strtbl.c:2964 #, c-format msgid "Fail to get entry point '%s' in shared lib '%s'." msgstr "" #. STID_SHARELIB_TGEF_MSG_INIT_FAIL #: ../../strtbl.c:2966 #, c-format msgid "%s: TGEF_MSG_INIT failed with return code %ld." msgstr "" #. STID_SHARELIB_CNFLCT_PROTOCOL_VER #: ../../strtbl.c:2968 #, c-format msgid "Conflicting protocol version %1d implemented by '%s'." msgstr "" #. STID_SHARELIB_TGEF_MSG_LOAD_FAIL #: ../../strtbl.c:2970 #, c-format msgid "%s: TGEF_MSG_LOAD failed with return code %ld." msgstr "" #. STID_SHARELIB_TGEF_MSG_NO_BMP_INFO #: ../../strtbl.c:2972 #, c-format msgid "%s: TGEF_MSG_LOAD returned with no bitmap info." msgstr "" #. STID_ALLOC_BMP_FAIL_FOR_SHARELIB #: ../../strtbl.c:2974 #, c-format msgid "Failed to allocate bitmap for '%s'." msgstr "" #. STID_UNSUP_PROTOCOL_VER_SHARELIB #: ../../strtbl.c:2980 #, c-format msgid "Unsupported protocol version %1d implemented by '%s'." msgstr "" #. STID_SHARELIB_TGEF_MSG_DO_EXPORT_F #: ../../strtbl.c:2982 #, c-format msgid "%s: TGEF_MSG_DO_EXPORT failed with return code %ld." msgstr "" #. STID_NEG_VAL_IN_EXP_PXL_TRM_ALT #: ../../strtbl.c:2984 #, c-format msgid "" "Error in parsing ExportPixelTrim values: negative values are not allowed.\n" "\n" "[%1d,%1d,%1d,%1d] used." msgstr "" #. STID_EXP_PXL_TRM_VAL_SET_TO #: ../../strtbl.c:2986 #, c-format msgid "ExportPixelTrim values set to [%1d,%1d,%1d,%1d]." msgstr "" #. STID_SPECIFY_TO_TRIM_EXP_PXL_TRM #: ../../strtbl.c:2988 #, c-format msgid "" "Please specify the number of pixels to trim when exporting (or printing) in " "bitmap-type format: [current: %1d,%1d,%1d,%1d]" msgstr "" #. STID_ENTER_4_NUM_CUR_TOO_LARGE #: ../../strtbl.c:2990 msgid "" "Please enter 4 numbers or type <CR> or <ESC> to use the current values (they " "are too large now):" msgstr "" #. STID_ENTER_4_NUM_OR_CR_ESC #: ../../strtbl.c:2992 msgid "Please enter 4 numbers or type <CR> or <ESC> to use the current values:" msgstr "" #. STID_OBSOLETE_XDEF_USE_IGNORED #: ../../strtbl.c:2994 #, c-format msgid "Obsoleted %s.%s used. Ignored." msgstr "" #. STID_WILL_USE_FS_HALFTONE_BMP #: ../../strtbl.c:2996 msgid "" "Will use Floyd-Steinberg half-tone method when exporting an X11 bitmap file." msgstr "" #. STID_WILL_NOT_USE_FS_HALFTONE_BMP #: ../../strtbl.c:2998 msgid "" "Will not use Floyd-Steinberg half-tone method when exporting an X11 bitmap " "file." msgstr "" #. STID_WILL_USE_GIVE_SMPLE_THRESHOLD #: ../../strtbl.c:3000 #, c-format msgid "" "Will use simple thresholding method with a threshold of '%s' when exporting " "an X11 bitmap file." msgstr "" #. STID_WILL_NOT_USE_SIMPLE_THRESHOLD #: ../../strtbl.c:3002 msgid "" "Will not use simple thresholding method when exporting an X11 bitmap file." msgstr "" #. STID_ENTER_BMP_THRESHOLD_CUR_VAL #: ../../strtbl.c:3004 #, c-format msgid "" "Please specify bitmap threshold when exporting an X11 bitmap file (current " "value is '%s')." msgstr "" #. STID_INVALID_THRESHOLD_REMAINS #: ../../strtbl.c:3006 #, c-format msgid "Invalid threshold: '%s' specified. Threshold remains at '%s'." msgstr "" #. STID_USE_GIVEN_AS_BMP_THRESHOLD #: ../../strtbl.c:3008 #, c-format msgid "Will use '%s' as bitmap threshold when exporting an X11 bitmap file." msgstr "" #. STID_XGETIMAGE_MAY_RUN_OUT_VMEM #: ../../strtbl.c:3010 msgid "XGetImage() failed. May have run out of virtual memory." msgstr "" #. STID_NO_X11_BITMAP_OBJ_SELECTED #: ../../strtbl.c:3012 msgid "No X11 Bitmap objects selected." msgstr "" #. STID_CANT_CUT_AN_EPS_OBJECT #: ../../strtbl.c:3014 msgid "Cannot cut an EPS object." msgstr "" #. STID_XBM_CANT_HAVE_0_W_OR_H #: ../../strtbl.c:3016 msgid "Bitmap cannot have 0 width or height." msgstr "" #. STID_BAD_RED_MASK_TRUE_COLOR_DPY #: ../../strtbl.c:3018 #, c-format msgid "" "Unexpected red_mask value of 0x%06lx in the default visual for this " "TrueColor display. Proceed pretending that the display is not TrueColor. " "Please set %s.%s to FALSE to avoid this error message in the future." msgstr "" #. STID_BAD_GREEN_MASK_TRUE_COLOR_DPY #: ../../strtbl.c:3020 #, c-format msgid "" "Unexpected green_mask value of 0x%06lx in the default visual for this " "TrueColor display. Proceed pretending that the display is not TrueColor. " "Please set %s.%s to FALSE to avoid this error message in the future." msgstr "" #. STID_BAD_BLUE_MASK_TRUE_COLOR_DPY #: ../../strtbl.c:3022 #, c-format msgid "" "Unexpected blue_mask value of 0x%06lx in the default visual for this " "TrueColor display. Proceed pretending that the display is not TrueColor. " "Please set %s.%s to FALSE to avoid this error message in the future." msgstr "" #. STID_NETPBM_PROGS_VISIT_HOME_PAGE #: ../../strtbl.c:3024 #, c-format msgid "" "(These programs are part of the netpbm package. Please visit %s's home page " "at <URL:%s> regarding where to obtain netpbm.)" msgstr "" #. STID_NETPBM_PNMTOPNG_VST_HOME_PAGE #: ../../strtbl.c:3026 #, c-format msgid "" "(These programs are part of the netpbm and pnmtopng packages. Please visit %" "s's home page at <URL:%s> regarding where to obtain netpbm and pnmtopng.)" msgstr "" #. STID_FNAME_FORMAT_ERROR_IN_FUNC #: ../../strtbl.c:3028 #, c-format msgid "File name format error in %s." msgstr "" #. STID_NAMED_IMAGEMAP_FILE_GEN #: ../../strtbl.c:3030 #, c-format msgid "Imagemap file '%s' generated." msgstr "" #. STID_CANT_FND_FATTR_IMGMAP_NOT_GEN #: ../../strtbl.c:3032 #, c-format msgid "" "Cannot find a '%s' file attribute.\n" "\n" "Imagemap not generated." msgstr "" #. STID_CANT_FND_FATTR_NO_IMGMAP_GIF #: ../../strtbl.c:3034 #, c-format msgid "" "Cannot find a '%s' file attribute.\n" "\n" "Imagemap not generated. Only a GIF file is generated." msgstr "" #. STID_NAMED_HTML_FILE_GEN #: ../../strtbl.c:3036 #, c-format msgid "HTML file '%s' generated." msgstr "" #. STID_LARGE_EXP_PXL_TRM_WH_0_USED #: ../../strtbl.c:3038 #, c-format msgid "" "The ExportPixelTrim values of [%1d,%1d,%1d,%1d] are too large for the image " "(%1dx%1d). Zeroes are used." msgstr "" #. STID_APPLY_EXP_PXL_TRM_VALS #: ../../strtbl.c:3040 #, c-format msgid "Applying ExportPixelTrim of [%1d,%1d,%1d,%1d]..." msgstr "" #. STID_TOO_MANY_COLORS_LIMIT_IS #: ../../strtbl.c:3042 #, c-format msgid "Too many colors: %1d (limit is %1d) in the image." msgstr "" #. STID_UNRECOG_GIVEN_PIXEL_VAL_PRINT #: ../../strtbl.c:3044 #, c-format msgid "" "Unrecognized pixel value at (%1d,%1d): %1d (0x%08lx).\n" "\n" "Printing/exporting aborted." msgstr "" #. STID_UNRECOG_GIVEN_PIXEL_VAL_1_USE #: ../../strtbl.c:3046 #, c-format msgid "" "Unrecognized pixel value: %1d (0x%08lx).\n" "\n" "1 used." msgstr "" #. STID_FORMAT_FILE_WH_PRINTED_INTO #: ../../strtbl.c:3048 #, c-format msgid "%s file [%1dx%1d] printed into '%s'." msgstr "" #. STID_SEL_XPM_DECK_TO_EXPORT #: ../../strtbl.c:3050 msgid "Please select a deck of X Pixmap object to export." msgstr "" #. STID_MANY_SZ_FAIL_XPM_DESK_EXPORT #: ../../strtbl.c:3052 #, c-format msgid "" "Not all X Pixmap objects in the deck are of size. Expecting %1dx%1d.\n" "\n" "Export aborted." msgstr "" #. STID_INVALID_CH_PER_PIX_IN_FUNC #: ../../strtbl.c:3054 #, c-format msgid "Invalid chars_per_pixel (%1d) in %s." msgstr "" #. STID_XPM_CANT_HAVE_0_W_OR_H #: ../../strtbl.c:3056 msgid "Pixmap cannot have 0 width or height." msgstr "" #. STID_WARN_XPM_ALL_NON_BG_BE_BLACK #: ../../strtbl.c:3058 msgid "" "Warning (xpm object): all non-background color will be treated as black." msgstr "" #. STID_SAVED_FILE_MAY_BE_CORRUPTED #: ../../strtbl.c:3060 msgid "Saved file may be corrupted." msgstr "" #. STID_CANT_SAVE_XPM_ON_BW_DPY #: ../../strtbl.c:3062 msgid "Cannot save X11 Pixmap objects on a Black & White display." msgstr "" #. STID_CANT_IMPORT_GIVEN_FORMAT_XPM #: ../../strtbl.c:3064 #, c-format msgid "Does not know how to import an X11 Pixmap file with format: '%1d'." msgstr "" #. STID_CANT_IMPORT_GIVEN_CPP_XPM #: ../../strtbl.c:3066 #, c-format msgid "" "Does not know how to import an X11 Pixmap file with chars_per_pixel: '%1d'." msgstr "" #. STID_EDIT_UNNAME_ATTR_DOTS #: ../../strtbl.c:3068 #, fuzzy msgid "Edit an unnamed attribute..." msgstr "òĆÄÁËÔÉÒÏŚÁÔŰ ÆÁÊÌ ÁÔÒÉÂŐÔÏŚ..." #. STID_EDIT_VAL_OF_ATTR_DOTS #: ../../strtbl.c:3070 #, fuzzy, c-format msgid "Edit the value for the '%s' attribute..." msgstr "òĆÄÁËÔÉÒÏŚÁÔŰ ÆÁÊÌ ÁÔÒÉÂŐÔÏŚ..." #. STID_EDIT_UNNAME_ATTR_WITH_CMD #: ../../strtbl.c:3072 #, c-format msgid "Editing an unnamed attribute with '%s'..." msgstr "" #. STID_EDIT_VAL_OF_ATTR_WITH_CMD #: ../../strtbl.c:3074 #, c-format msgid "Editing the value for the '%s' attribute with '%s'..." msgstr "" #. STID_STAT_FAIL_EDIT_ATTR_VAL_SAME #: ../../strtbl.c:3076 #, c-format msgid "" "Fail to get file info for '%s' while editing an attribute. Attribute value " "is unchanged." msgstr "" #. STID_ENTER_HTML_TEMPLATE #: ../../strtbl.c:3078 msgid "" "Please specify a file to be used as a template for generating HTML files:" msgstr "" #. STID_ENTER_HTML_TEMPLATE_CUR_IS #: ../../strtbl.c:3080 #, c-format msgid "" "Please specify a file to be used as a template for generating HTML files " "(current template is '%s'):" msgstr "" #. STID_HTML_TEMPLATE_UNCHANGED #: ../../strtbl.c:3082 msgid "HTML export template file unchanged." msgstr "" #. STID_HTML_TEMPLATE_SET_TO_GIVEN #: ../../strtbl.c:3084 #, c-format msgid "HTML export template file set to '%s'." msgstr "" #. STID_NO_HTML_TEMPLATE_FILE #: ../../strtbl.c:3086 msgid "Will not use an HTML export template file." msgstr "" #. STID_Q_FILE_NOT_EXIST_USE_ANYWAY #: ../../strtbl.c:3088 #, c-format msgid "" "File '%s' does not exist.\n" "\n" "Would you like to use it anyway?" msgstr "" #. STID_CANNOT_OPEN_HTML_TMPL_READ #: ../../strtbl.c:3090 #, c-format msgid "Cannot open HTML export template file '%s' for reading." msgstr "" #. STID_OK_TO_FULL_SCREEN_CAPTURE_YNC #: ../../strtbl.c:3092 msgid "Okay to proceed with full screen capture? [ync](y)" msgstr "" #. STID_Q_FILE_UNSAVABLE_SAVE_NEW_YNC #: ../../strtbl.c:3094 msgid "" "File is marked unsavable.\n" "\n" "Would you like to save to a new file name? [ync](y)" msgstr "" #. STID_WONT_CONDENSE_READHEXSTRING #: ../../strtbl.c:3096 msgid "Will not condense exported PS/EPS file due to 'readhexstring'." msgstr "" #. STID_CMD_ONLY_AVAIL_IN_VERTEX_MODE #: ../../strtbl.c:3098 msgid "This command is only available in vertex mode." msgstr "" #. STID_CANNOT_MERGE_WITH_TILED_PAGE #: ../../strtbl.c:3100 #, c-format msgid "" "Does not know how to merge files with '%s' because it is in TILED page " "mode. Merge aborted." msgstr "" #. STID_SPECIFY_PAGES_TO_PRINT_EX #: ../../strtbl.c:3102 msgid "Please specify pages to print: (e.g., 2,3,7-9,10 or '*' for all pages)" msgstr "" #. STID_CANT_PRINT_PAGES_IN_TILED #: ../../strtbl.c:3104 msgid "Cannot print pages in TILED page mode." msgstr "" #. STID_CANT_PRINT_PAGES_IN_FORMAT #: ../../strtbl.c:3106 #, c-format msgid "Cannot print pages in the '%s' format." msgstr "" #. STID_PRECISE_SCALE_EV_CAUSE_FLUSH #: ../../strtbl.c:3108 msgid "Precise Scale Everything will cause the undo buffer to be flushed." msgstr "" #. STID_GO_HYPERSPACE_IN_SLIDE #: ../../strtbl.c:3110 msgid "HyperSpace mode will be entered upon entering slideshow mode." msgstr "" #. STID_DONT_GO_HYPERSPACE_IN_SLIDE #: ../../strtbl.c:3112 msgid "Freehand drawing mode will be entered upon entering slideshow mode." msgstr "" #. STID_MOVE_EDIT_TEXT_BOX_ABORTED #: ../../strtbl.c:3114 msgid "Move edit text box aborted." msgstr "" #. STID_DRAG_MOUSE_MOVE_EDITTEXT_DOTS #: ../../strtbl.c:3116 msgid "Drag the edit text box to move it around..." msgstr "" #. STID_EXCEED_BUF_SIZE_LIMIT_IN_WB #: ../../strtbl.c:3118 #, c-format msgid "" "Error: There's a buffer size limitation of %1d bytes in the current " "implementation of the whiteboard. The buffer size requirement (%1d bytes) " "for the operation you just performed has exceeded this limit.\n" "\n" "In order to keep the whiteboard running, the operation in question is " "canceled." msgstr "" #. STID_CANT_REPLACE_GRAPHIC_NOT_TGIF #: ../../strtbl.c:3120 #, c-format msgid "" "Cannot replace graphical objects because cut buffer does not contain %s " "objects." msgstr "" #. STID_CANT_REPLACE_GRAPHIC_TOO_MANY #: ../../strtbl.c:3122 msgid "" "Cannot replace graphical objects because cut buffer contain more than one " "objects." msgstr "" #. STID_REPLACE_GRAPHIC_ICON_TO_GROUP #: ../../strtbl.c:3124 msgid "" "Some iconic objects have been converted to grouped objects during Replace " "Graphic." msgstr "" #. STID_REPLACE_GRAPHIC_DONE #: ../../strtbl.c:3126 msgid "Graphical part of selected objects have been replaced and updated." msgstr "" #. STID_TOO_MANY_ICON_REPLACE_GRAPHIC #: ../../strtbl.c:3128 msgid "More than one iconic objects are selected for Replace Graphic." msgstr "" #. STID_Q_CVT_ICON_TO_GRP_IN_REPLACE #: ../../strtbl.c:3130 msgid "" "Replacing the graphic of an iconic object...\n" "\n" "Would you like to convert the object into a grouped object? [ync](y)\n" "\n" "(If you press the No button, you will be prompted with the name of a new " "symbol file the iconic object. If you press Cancel, this object will be " "skipped for Replace Graphic.)" msgstr "" #. STID_SHOW_MEASUREMENT_IN_TT_ENAB #: ../../strtbl.c:3132 msgid "Showing measurement in tooltip enabled." msgstr "" #. STID_SHOW_MEASUREMENT_IN_TT_DISB #: ../../strtbl.c:3134 msgid "" "Showing measurement in tooltip disabled. Measurement will be shown in the " "ruler window." msgstr "" #. STID_SEL_JPEG_FILE_TO_IMPORT #: ../../strtbl.c:3136 msgid "Please select a JPEG file to IMPORT..." msgstr "" #. STID_CANNOT_IMPORT_GIVEN_JPEG #: ../../strtbl.c:3138 #, c-format msgid "Cannot import JPEG file '%s'." msgstr "" #. STID_GIVEN_JPEG_SIZE_FILE_IMPORTED #: ../../strtbl.c:3140 #, c-format msgid "JPEG file (%1dx%1d) '%s' imported." msgstr "" #. STID_WILL_EXPORT_JPEG_FILE #: ../../strtbl.c:3142 msgid "Will export JPEG (needs xpm->jpg filter) file." msgstr "" #. STID_NETPBM_JPEG_VST_HOME_PAGE #: ../../strtbl.c:3144 #, c-format msgid "" "(These programs are part of the netpbm and jpeg packages. Please visit %s's " "home page at <URL:%s> regarding where to obtain netpbm and jpeg.)" msgstr "" #. STID_CANT_GEN_PREVIEW_FOR_PS #: ../../strtbl.c:3146 #, c-format msgid "Cannot auto-generate a preview bitmap for '%s'." msgstr "" #. STID_CANT_GEN_PREVIEW_FOR_EMPTY_PS #: ../../strtbl.c:3148 #, c-format msgid "" "The auto-generate preview bitmap for '%s' is empty. Auto-generation skipped." msgstr "" #. STID_WILL_AUTO_GEN_PREVIEW_BITMAP #: ../../strtbl.c:3150 msgid "" "Will auto-generate a preview bitmap when importing/embedding a PS/EPS file." msgstr "" #. STID_WONT_AUTO_GEN_PREVIEW_BITMAP #: ../../strtbl.c:3152 msgid "" "Will not auto-generate a preview bitmap when importing/embedding a PS/EPS " "file." msgstr "" #. STID_TMP_DIR_NOT_EXIST_USE_XDEF #: ../../strtbl.c:3154 #, c-format msgid "" "Temporary directory '%s' does not exist. Please fix the %s.%s X default." msgstr "" #. STID_INVALID_DIR_IN_X_DEFAULT #: ../../strtbl.c:3156 #, c-format msgid "Invalid directory '%s' specified by X default %s.%s." msgstr "" #. STID_RACE_IN_CREATE_TMP_FILE #: ../../strtbl.c:3158 #, c-format msgid "" "Race condition detected in creating the '%s' temporary file. Possible " "causes are network problems, security problems, etc. This file will be " "removed before proceeding." msgstr "" #. STID_INVALID_GEOM_USE_ALT_GEOM #: ../../strtbl.c:3160 #, c-format msgid "" "Invalid %s.%s: '%s', the geometry must be at least '%s', '%s' is used " "instead." msgstr "" #. STID_REDUCE_BY_FACTOR #: ../../strtbl.c:3162 #, c-format msgid "Reducing by a factor of %.2f..." msgstr "" #. STID_ENLARGE_BY_FACTOR #: ../../strtbl.c:3164 #, c-format msgid "Enlarging by a factor of %.2f..." msgstr "" #. STID_CREATE_THUMBNAIL_CAUSE_FLUSH #: ../../strtbl.c:3166 msgid "Create Thumbnails will cause the undo buffer to be flushed." msgstr "" #. STID_CONNECT_PORTS_CANCEL_BY_USER #: ../../strtbl.c:3168 msgid "Connect ports canceled by the user." msgstr "" #. STID_Q_CNFLCT_SIG_NAME_OKAY_TO_CLR #: ../../strtbl.c:3170 #, c-format msgid "" "Conflicting signal names '%s' (at '%s') and '%s' (at '%s').\n" "\n" "Okay to clear both signal names? [ync](y)" msgstr "" #. STID_PLS_ENT_SIG_NAME #: ../../strtbl.c:3172 msgid "Please enter a signal name:" msgstr "" #. STID_SIGNAL_NAMES_CLEARED #: ../../strtbl.c:3174 #, c-format msgid "Signal names at '%s' and '%s' have been cleared." msgstr "" #. STID_PLACING_NAMED_SIGNAL #: ../../strtbl.c:3176 #, c-format msgid "Click to place signal name '%s'" msgstr "" #. STID_PLS_ENT_SIG_NAME_FOR_PORT #: ../../strtbl.c:3178 #, c-format msgid "Please enter a signal name for the '%s' port:" msgstr "" #. STID_NO_CUR_FILE_CANNOT_GEN_NETLST #: ../../strtbl.c:3184 msgid "" "No current file.\n" "\n" "Cannot generate a net list." msgstr "" #. STID_NO_SIGNAME_FOUND_EMPTY_NETLST #: ../../strtbl.c:3186 msgid "" "No signal name found.\n" "\n" "Net list not generated." msgstr "" #. STID_WILL_EXPORT_NETLIST_FILE #: ../../strtbl.c:3188 msgid "Will export net-list file." msgstr "" #. STID_Q_OK_TO_CUT_INTO_SEGMENTS #: ../../strtbl.c:3190 msgid "" "Okay to cut selected polyline/polygon objects into segments? [ync](y)\n" "\n" "(If you would like to cut at a specific vertex of the polyline/polygon, " "please use the vertex mode.)" msgstr "" #. STID_NO_POLY_OBJ_SELECTED #: ../../strtbl.c:3192 msgid "No polyline/polygon object selected." msgstr "" #. STID_WILL_SHOW_WIRE_SIGNAL_NAME #: ../../strtbl.c:3194 msgid "Will show (and place) wire signal name when connecting ports." msgstr "" #. STID_WILL_HIDE_WIRE_SIGNAL_NAME #: ../../strtbl.c:3196 msgid "Will hide wire signal name when connecting ports." msgstr "" #. STID_TRY_AGAIN_AND_CLICK_IN_A_PORT #: ../../strtbl.c:3198 msgid "Please try again and click in a port." msgstr "" #. STID_TRY_AGAIN_AND_END_IN_A_PORT #: ../../strtbl.c:3200 msgid "The last vertex did not end in a port, please try again." msgstr "" #. STID_CANNOT_CREATE_ARC_WITH_RAD1 #: ../../strtbl.c:3202 #, c-format msgid "%s cannot create an arc with radius %1d (must be at least 1)." msgstr "" #. STID_SEL_ONE_NONE_PORT_PLUS_COMP #: ../../strtbl.c:3204 msgid "Please select at least one port object and a composite object." msgstr "" #. STID_PORT_OBJ_HAS_EMPTY_NAME #: ../../strtbl.c:3206 msgid "The port object has an empty name." msgstr "" #. STID_CANNOT_FIND_INIT_ATTR_PORT_PA #: ../../strtbl.c:3208 #, c-format msgid "" "Cannot find the 'Initialization=' attribute of the '%s' object (parent of " "the port object)." msgstr "" #. STID_CANNOT_FIND_VAR_IN_INIT_ATTR #: ../../strtbl.c:3210 #, c-format msgid "" "Cannot find the '%s' variable in the 'Initialization=' attribute of the '%s' " "object (parent of the port object)." msgstr "" #. STID_RENUMBER_OBJ_IDS_CAUSE_FLUSH #: ../../strtbl.c:3212 msgid "Renumber Object IDs will cause the undo buffer to be flushed." msgstr "" #. STID_RENUMBER_OBJ_IDS_DONE #: ../../strtbl.c:3214 msgid "Renumbering object IDs done." msgstr "" #. STID_RENUMBER_OBJ_IDS_IN_WB #: ../../strtbl.c:3216 msgid "RenumberObjectIDs() is disabled in WhiteBoard mode." msgstr "" #. STID_SEL_ONE_NONE_PORT_PLUS_BRDCST #: ../../strtbl.c:3218 msgid "Please select at least one port object and a broadcast wire object." msgstr "" #. STID_CONFLICT_SIG_NAME_ENT_NEW #: ../../strtbl.c:3220 msgid "" "Conflicting signal names detected. Please entry a valid signal name for all " "the ports:" msgstr "" #. STID_BAD_SIG_NAME_UNDO_AND_REDO #: ../../strtbl.c:3222 msgid "" "Invalid or inconsistent signal names are given to the ports. Please undo " "the previous operation and redo it again." msgstr "" #. STID_WILL_USE_WORDWRAP_IMPORT_TEXT #: ../../strtbl.c:3224 msgid "Will use word wrap when importing a multipage text file." msgstr "" #. STID_NO_WORDWRAP_IMPORT_TEXT #: ../../strtbl.c:3226 msgid "Will not use word wrap when importing a multipage text file." msgstr "" #. STID_CUR_MARGINS_ARE_GIVEN #: ../../strtbl.c:3228 #, c-format msgid "( current margins (top, bottom, left, right) are: %s )" msgstr "" #. STID_ENTER_MARGINS #: ../../strtbl.c:3230 #, c-format msgid "" "Please enter margins to be used when importing a multipage text file: [top," "bottom,left,right] (e.g., %s -- the three commas are mandatory)" msgstr "" #. STID_NEW_MARGINS_ARE_GIVEN #: ../../strtbl.c:3232 msgid "" "New margins for import multipage text file are (top, bottom, left, right):" msgstr "" #. STID_CANT_OBTAIN_TMP_FILE_NAME #: ../../strtbl.c:3234 #, c-format msgid "" "Cannot obtain a temporary file name using mkstemp() from the following " "request: '%s'. Will use mktemp() instead." msgstr "" #. STID_NO_OBJ_SPEC_WHILE_EXEC_CMD #: ../../strtbl.c:3236 #, c-format msgid "Non object specified while executing the '%s' command." msgstr "" #. STID_UNRECOG_GIVEN_TRPIX_VAL_PRINT #: ../../strtbl.c:3238 #, c-format msgid "" "Unrecognized transparent pixel value at (%1d,%1d): %1d (0x%08lx).\n" "\n" "Printing/exporting aborted." msgstr "" #. STID_TGIF_DISTRUBITION #: ../../strtbl.c:3240 #, c-format msgid " [distribution: %s]" msgstr "" #. STID_WRITE_TO_SELF_PIPE_FAIL #: ../../strtbl.c:3242 #, c-format msgid "Fail to write to the pipe that talks to %s itself." msgstr "" #. STID_CREATE_SELF_PIPE_FAIL #: ../../strtbl.c:3244 #, c-format msgid "Fail to create the pipe that talks to %s itself." msgstr "" #. STID_READ_FROM_SELF_PIPE_FAIL #: ../../strtbl.c:3246 #, c-format msgid "Fail to read %1d byte from the pipe that talks to %s itself." msgstr "" #. STID_ENTER_BEZIER_NUM_SEGS_CUR_IS #: ../../strtbl.c:3248 #, c-format msgid "" "Please enter the number of segments for the Convert To Bezier command " "(current value is %1d):" msgstr "" #. STID_BEZIER_NUM_SEGS_SET_TO_INT #: ../../strtbl.c:3250 #, c-format msgid "Number of segments for the Convert To Bezier command set to %1d." msgstr "" #. STID_ENT_VAL_RANGE_ENTER_GE_INT #: ../../strtbl.c:3252 #, c-format msgid "" "The value entered: '%s' is out of range.\n" "\n" "Please enter a value >= %1d." msgstr "" #. STID_ENTER_TICK_MARK_SIZE_CUR_IS #: ../../strtbl.c:3254 #, c-format msgid "" "Please enter the tick mark size for the various Add Tick Mark commands " "(current value is %1d):" msgstr "" #. STID_TICK_MARK_SIZE_SET_TO_INT #: ../../strtbl.c:3256 #, c-format msgid "Tick mark size set to %1d." msgstr "" #. STID_NO_SPLINE_SELECTED #: ../../strtbl.c:3258 msgid "No (non-interpolated) spline objects selected." msgstr "" #. STID_SPLINE_CONVERTED_TO_BEZIER #: ../../strtbl.c:3260 msgid "Spline objects converted to Bezier curves." msgstr "" #. STID_PEEK_DIM_LEFT #: ../../strtbl.c:3262 msgid "The x-coordinate of the left most part of the selected object." msgstr "" #. STID_PEEK_DIM_TOP #: ../../strtbl.c:3264 msgid "The y-coordinate of the top most part of the selected object." msgstr "" #. STID_PEEK_DIM_RIGHT #: ../../strtbl.c:3266 msgid "The x-coordinate of the right most part of the selected object." msgstr "" #. STID_PEEK_DIM_BOTTOM #: ../../strtbl.c:3268 msgid "The y-coordinate of the bottom most part of the selected object." msgstr "" #. STID_PEEK_DIM_WIDTH #: ../../strtbl.c:3270 msgid "The width of the selected object." msgstr "" #. STID_PEEK_DIM_HEIGHT #: ../../strtbl.c:3272 msgid "The height of the selected object." msgstr "" #. STID_PEEK_DIM_CX #: ../../strtbl.c:3274 msgid "The x-coordinate of the center of the selected object." msgstr "" #. STID_PEEK_DIM_CY #: ../../strtbl.c:3276 msgid "The y-coordinate of the center of the selected object." msgstr "" #. STID_NO_POLY_ETC_SELECTED #: ../../strtbl.c:3278 msgid "No polyline/polygon/spline objects selected." msgstr "" #. STID_SEL_A_SYM_TO_INSTAN_IN_NONE #: ../../strtbl.c:3280 msgid "Please select a symbol to INSTANTIATE..." msgstr "" #. STID_WRITE_NOT_AUTO_IN_HYPER_EXEC #: ../../strtbl.c:3282 #, c-format msgid "" "Writing into file is not automatic in hyperspace. Do you want to allow " "writing into '%s'?\n" "\n" "(If you are not sure about this, just click on NO.)" msgstr "" #. STID_USER_ABORT_WRITE_IN_HYPER #: ../../strtbl.c:3284 msgid "Writing into file in hyperspace aborted at user's request." msgstr "" #. STID_READ_FROM_SELF_PIPE_OVERFLOW #: ../../strtbl.c:3286 #, c-format msgid "Buffer overflow while reading the pipe that talks to %s itself." msgstr "" #. STID_BAD_CMDLINE_OPT_USE_ALT_STR #: ../../strtbl.c:3288 #, c-format msgid "Invalid commandline option %s=\"%s\", \"%s\" is used instead." msgstr "" #. STID_BAD_CMDLINE_OPT_IGNORED #: ../../strtbl.c:3290 #, c-format msgid "Invalid commandline option %s=\"%s\"; it is ignored." msgstr "" #. STID_OBSOLETE_CMDLINE_ASSUME #: ../../strtbl.c:3292 #, c-format msgid "The %s commandline option is obsolete; assuming you mean %s." msgstr "" #. STID_INVALID_XDEF_IGNORED #: ../../strtbl.c:3294 #, c-format msgid "Invalid %s.%s: '%s'. Resource ignored." msgstr "" #. STID_OBSOLETE_XDEF_REPLACED #: ../../strtbl.c:3296 #, c-format msgid "" "Obsoleted %s.%s used. Assuming %s.%s to have the value of '%s' instead." msgstr "" #. STID_FILE_IS_MARKED_UNSAVABLE #: ../../strtbl.c:3298 msgid "File is marked unsavable." msgstr "" #: ../../strtbl.c:3345 msgid "Distribute selected objects so that their top edges are equally spaced" msgstr "" #: ../../strtbl.c:3346 msgid "" "Distribute selected objects so that their vertical centers are equally spaced" msgstr "" #: ../../strtbl.c:3347 msgid "" "Distribute selected objects so that their bottom edges are equally spaced" msgstr "" #: ../../strtbl.c:3348 msgid "Distribute selected objects so that they are equally spaced vertically" msgstr "" #: ../../strtbl.c:3349 msgid "Distribute selected objects so that their left edges are equally spaced" msgstr "" #: ../../strtbl.c:3350 msgid "" "Distribute selected objects so that their left and top edges are equally " "spaced" msgstr "" #: ../../strtbl.c:3351 msgid "" "Distribute selected objects so that their left and vertical centers are " "equally spaced" msgstr "" #: ../../strtbl.c:3352 msgid "" "Distribute selected objects so that their left and bottom edges are equally " "spaced" msgstr "" #: ../../strtbl.c:3353 msgid "" "Distribute selected objects so that they are equally spaced vertically and " "their left edges are spaced equally" msgstr "" #: ../../strtbl.c:3354 msgid "" "Distribute selected objects so that their horizontal centers are equally " "spaced" msgstr "" #: ../../strtbl.c:3355 msgid "" "Distribute selected objects so that their horizontal centers and top edges " "are equally spaced" msgstr "" #: ../../strtbl.c:3356 msgid "" "Distribute selected objects so that their horizontal and vertical centers " "are equally spaced" msgstr "" #: ../../strtbl.c:3357 msgid "" "Distribute selected objects so that their horizontal centers and bottom " "edges are equally spaced" msgstr "" #: ../../strtbl.c:3358 msgid "" "Distribute selected objects so that they are equally spaced vertically and " "their horizontal centers are spaced equally" msgstr "" #: ../../strtbl.c:3359 msgid "" "Distribute selected objects so that their right edges are equally spaced" msgstr "" #: ../../strtbl.c:3360 msgid "" "Distribute selected objects so that their right and top edges are equally " "spaced" msgstr "" #: ../../strtbl.c:3361 msgid "" "Distribute selected objects so that their right and vertical centers are " "equally spaced" msgstr "" #: ../../strtbl.c:3362 msgid "" "Distribute selected objects so that their right and bottom edges are equally " "spaced" msgstr "" #: ../../strtbl.c:3363 msgid "" "Distribute selected objects so that they are equally spaced vertically and " "their right edges are spaced equally" msgstr "" #: ../../strtbl.c:3364 msgid "" "Distribute selected objects so that they are equally spaced horizontally" msgstr "" #: ../../strtbl.c:3365 msgid "" "Distribute selected objects so that they are equally spaced horizontally and " "their top edges are spaced equally" msgstr "" #: ../../strtbl.c:3366 msgid "" "Distribute selected objects so that they are equally spaced horizontally and " "their vertical centers are spaced equally" msgstr "" #: ../../strtbl.c:3367 msgid "" "Distribute selected objects so that they are equally spaced horizontally and " "their bottom edges are spaced equally" msgstr "" #: ../../strtbl.c:3368 msgid "" "Distribute selected objects so that they are equally spaced horizontally and " "vertically" msgstr "" #: ../../strtbl.c:3384 ../../strtbl.c:3404 msgid "top sides are aligned." msgstr "" #: ../../strtbl.c:3385 ../../strtbl.c:3405 msgid "vertical centers are aligned." msgstr "" #: ../../strtbl.c:3386 ../../strtbl.c:3406 msgid "bottom sides are aligned." msgstr "" #: ../../strtbl.c:3388 ../../strtbl.c:3392 msgid "left sides are aligned." msgstr "" #: ../../strtbl.c:3389 msgid "left and top sides are aligned." msgstr "" #: ../../strtbl.c:3390 msgid "left side and middle are aligned." msgstr "" #: ../../strtbl.c:3391 msgid "left and bottom sides are aligned." msgstr "" #: ../../strtbl.c:3393 ../../strtbl.c:3397 msgid "horizontal centers are aligned." msgstr "" #: ../../strtbl.c:3394 msgid "centers and top sides are aligned." msgstr "" #: ../../strtbl.c:3395 msgid "centers and middle are aligned." msgstr "" #: ../../strtbl.c:3396 msgid "centers and bottom sides are aligned." msgstr "" #: ../../strtbl.c:3398 ../../strtbl.c:3402 msgid "right sides are aligned." msgstr "" #: ../../strtbl.c:3399 msgid "right and top sides are aligned." msgstr "" #: ../../strtbl.c:3400 msgid "right and middle are aligned." msgstr "" #: ../../strtbl.c:3401 msgid "right and bottom sides are aligned." msgstr "" #: ../../strtbl.c:3416 #, fuzzy msgid "Horizontal alignment set to NONE." msgstr "òÏŚÎŃÔŰ ĐÏ ÇÏÒÉÚÏÎÔÁÌÉ" #: ../../strtbl.c:3417 msgid "Will align on the LEFT." msgstr "" #: ../../strtbl.c:3418 msgid "Will align objects at the horizontal CENTER." msgstr "" #: ../../strtbl.c:3419 msgid "Will align on the RIGHT." msgstr "" #: ../../strtbl.c:3420 msgid "Will equally SPACE objects horizontally." msgstr "" #: ../../strtbl.c:3429 msgid "Vertical alignment set to NONE." msgstr "" #: ../../strtbl.c:3430 msgid "Will align at the TOP." msgstr "" #: ../../strtbl.c:3431 msgid "Will align objects in the MIDDLE vertically." msgstr "" #: ../../strtbl.c:3432 msgid "Will align at the BOTTOM." msgstr "" #: ../../strtbl.c:3433 msgid "Will equally SPACE objects vertically." msgstr "" #: ../../strtbl.c:3440 #, fuzzy msgid "Align top edges of selected objects" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../strtbl.c:3442 msgid "Align bottom edges of selected objects" msgstr "" #: ../../strtbl.c:3443 #, fuzzy msgid "Align left edges of selected objects" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../strtbl.c:3444 msgid "Align left and top edges of selected objects" msgstr "" #: ../../strtbl.c:3445 msgid "Align left edges and vertical centers of selected objects" msgstr "" #: ../../strtbl.c:3446 msgid "Align left and bottom edges of selected objects" msgstr "" #: ../../strtbl.c:3448 msgid "Align horizontal centers and top edges of selected objects" msgstr "" #: ../../strtbl.c:3449 msgid "Align horizontal and vertical centers of selected objects" msgstr "" #: ../../strtbl.c:3450 msgid "Align horizontal centers and bottom edges of selected objects" msgstr "" #: ../../strtbl.c:3451 #, fuzzy msgid "Align right edges of selected objects" msgstr "đĆȚÁÔŰ ŚÙÄĆÌĆÎÎÙÈ ÏÂßĆËÔÏŚ" #: ../../strtbl.c:3452 msgid "Align right and top edges of selected objects" msgstr "" #: ../../strtbl.c:3453 msgid "Align right edges and vertical centers of selected objects" msgstr "" #: ../../strtbl.c:3454 msgid "Align right and bottom edges of selected objects" msgstr "" #: ../../strtbl.c:3467 msgid "Align top edges of selected objects to the grid" msgstr "" #: ../../strtbl.c:3468 msgid "Align vertical centers of selected objects to the grid" msgstr "" #: ../../strtbl.c:3469 msgid "Align bottom edges of selected objects to the grid" msgstr "" #: ../../strtbl.c:3470 msgid "Align left edges of selected objects to the grid" msgstr "" #: ../../strtbl.c:3471 msgid "Align left and top edges of selected objects to the grid" msgstr "" #: ../../strtbl.c:3472 msgid "Align left edges and vertical centers of selected objects to the grid" msgstr "" #: ../../strtbl.c:3473 msgid "Align left and bottom edges of selected objects to the grid" msgstr "" #: ../../strtbl.c:3474 msgid "Align horizontal centers of selected objects to the grid" msgstr "" #: ../../strtbl.c:3475 msgid "Align horizontal centers and top edges of selected objects to the grid" msgstr "" #: ../../strtbl.c:3476 msgid "Align horizontal and vertical centers of selected objects to the grid" msgstr "" #: ../../strtbl.c:3477 msgid "" "Align horizontal centers and bottom edges of selected objects to the grid" msgstr "" #: ../../strtbl.c:3478 msgid "Align right edges of selected objects to the grid" msgstr "" #: ../../strtbl.c:3479 msgid "Align right and top edges of selected objects to the grid" msgstr "" #: ../../strtbl.c:3480 msgid "Align right edges and vertical centers of selected objects to the grid" msgstr "" #: ../../strtbl.c:3481 msgid "Align right and bottom edges of selected objects to the grid" msgstr "" #: ../../strtbl.c:3494 msgid "Align selected objects (as a group) to the top of the page" msgstr "" #: ../../strtbl.c:3495 msgid "Align selected objects (as a group) to the vertical center of the page" msgstr "" #: ../../strtbl.c:3496 msgid "Align selected objects (as a group) to the bottom of the page" msgstr "" #: ../../strtbl.c:3497 msgid "Align selected objects (as a group) to the left side of the page" msgstr "" #: ../../strtbl.c:3498 msgid "Align selected objects (as a group) to the left top corner of the page" msgstr "" #: ../../strtbl.c:3499 msgid "" "Align selected objects (as a group) to the left vertical center of the page" msgstr "" #: ../../strtbl.c:3500 msgid "Align selected objects (as a group) to the left bottom of the page" msgstr "" #: ../../strtbl.c:3501 msgid "" "Align selected objects (as a group) to the horizontal center of the page" msgstr "" #: ../../strtbl.c:3502 msgid "" "Align selected objects (as a group) to the top horizontal center of the page" msgstr "" #: ../../strtbl.c:3503 msgid "Align selected objects (as a group) to the center of the page" msgstr "" #: ../../strtbl.c:3504 msgid "" "Align selected objects (as a group) to the bottom horizontal center of the " "page" msgstr "" #: ../../strtbl.c:3505 msgid "Align selected objects (as a group) to the right side of the page" msgstr "" #: ../../strtbl.c:3506 msgid "Align selected objects (as a group) to the right top corner of the page" msgstr "" #: ../../strtbl.c:3507 msgid "" "Align selected objects (as a group) to the right vertical center of the page" msgstr "" #: ../../strtbl.c:3508 msgid "" "Align selected objects (as a group) to the right bottom corner of the page" msgstr "" #: ../../strtbl.c:3521 msgid "Align selected vertices to the top of the page" msgstr "" #: ../../strtbl.c:3522 msgid "Align selected vertices to the vertical center of the page" msgstr "" #: ../../strtbl.c:3523 msgid "Align selected vertices to the bottom of the page" msgstr "" #: ../../strtbl.c:3524 msgid "Align selected vertices to the left side of the page" msgstr "" #: ../../strtbl.c:3525 msgid "Align selected vertices to the left top corner of the page" msgstr "" #: ../../strtbl.c:3526 msgid "Align selected vertices to the left vertical center of the page" msgstr "" #: ../../strtbl.c:3527 msgid "Align selected vertices to the left bottom corner of the page" msgstr "" #: ../../strtbl.c:3528 msgid "Align selected vertices to the horizontal center of the page" msgstr "" #: ../../strtbl.c:3529 msgid "Align selected vertices to the top horizontal center of the page" msgstr "" #: ../../strtbl.c:3530 msgid "Align selected vertices to the center of the page" msgstr "" #: ../../strtbl.c:3531 msgid "Align selected vertices to the bottom horizontal center of the page" msgstr "" #: ../../strtbl.c:3532 msgid "Align selected vertices to the right side of the page" msgstr "" #: ../../strtbl.c:3533 msgid "Align selected vertices to the right top corner of the page" msgstr "" #: ../../strtbl.c:3534 msgid "Align selected vertices to the right vertical center of the page" msgstr "" #: ../../strtbl.c:3535 msgid "Align selected vertices to the right bottom corner of the page" msgstr "" #. #. * note: the m field is used for the localized strings #. #: ../../strtbl.c:3552 msgid "select/move/resize objects" msgstr "ŚÙÄĆÌĆÎÉĆ/ĐĆÒĆÍĆĘĆÎÉĆ/ÉÚÍĆÎÉĆ ÒÁÚÍĆÒÁ ÏÂßĆËÔÁ" #: ../../strtbl.c:3553 msgid "enter text" msgstr "ŚŚÏÄ ÔĆËÓÔÁ" #: ../../strtbl.c:3554 msgid "draw rectangles" msgstr "ÒÉÓÏŚÁÎÉĆ ĐÒŃÍÏŐÇÏÌŰÎÉËÏŚ" #: ../../strtbl.c:3555 msgid "draw ovals (corner to corner)" msgstr "" #: ../../strtbl.c:3556 msgid "draw ovals (center to corner)" msgstr "" #: ../../strtbl.c:3557 msgid "draw circles (edge to edge)" msgstr "" #: ../../strtbl.c:3558 msgid "draw poly/open splines" msgstr "" #: ../../strtbl.c:3559 msgid "draw polygon/closed splines" msgstr "" #: ../../strtbl.c:3560 msgid "draw arcs (center first)" msgstr "" #: ../../strtbl.c:3561 msgid "draw arcs (endpoints first)" msgstr "" #: ../../strtbl.c:3562 msgid "draw rcboxes" msgstr "" #: ../../strtbl.c:3563 msgid "freehand poly/open splines" msgstr "" #: ../../strtbl.c:3564 msgid "select/move vertices" msgstr "ŚÙÄĆÌĆÎÉĆ/ĐĆÒĆÍĆĘĆÎÉĆ ŚĆÒÛÉÎ" #: ../../strtbl.c:3565 msgid "rotate/shear objects" msgstr "ŚÒÁĘĆÎÉĆ/ÉÓËÁÖĆÎÉĆ ÏÂßĆËÔÏŚ" #: ../../strtbl.c:3640 msgid "next color" msgstr "ÓÌĆÄ. ĂŚĆÔ" #: ../../strtbl.c:3640 msgid "prev color" msgstr "ĐÒĆÄ. ĂŚĆÔ" #: ../../strtbl.c:3645 msgid "next horizontal align" msgstr "ÓÌĆÄ. ŚÙÒÁŚÎÉŚÁÎÉĆ ĐÏ ÇÏÒÉÚÏÎÔÁÌÉ" #: ../../strtbl.c:3645 msgid "prev horizontal align" msgstr "ĐÒĆÄ. ŚÙÒÁŚÎÉŚÁÎÉĆ ĐÏ ÇÏÒÉÚÏÎÔÁÌÉ" #: ../../strtbl.c:3650 msgid "next vertical align" msgstr "ÓÌĆÄ. ŚÙÒÁŚÎÉŚÁÎÉĆ ĐÏ ŚĆÒÔÉËÁÌÉ" #: ../../strtbl.c:3650 msgid "prev vertical align" msgstr "ĐÒĆÄ. ŚÙÒÁŚÎÉŚÁÎÉĆ ĐÏ ŚĆÒÔÉËÁÌÉ" #: ../../strtbl.c:3655 msgid "next page" msgstr "ÓÌĆÄ. ÓÔÒÁÎÉĂÁ" #: ../../strtbl.c:3655 msgid "prev page" msgstr "ĐÒĆÄ. ÓÔÒÁÎÉĂÁ" #: ../../strtbl.c:3657 msgid "drawing size" msgstr "ÒÁÚÍĆÒ ÒÉÓŐÎËÁ" #: ../../strtbl.c:3662 msgid "tiled page mode" msgstr "" #: ../../strtbl.c:3664 #, fuzzy msgid "stacked page mode" msgstr "óÔÒÁÎÉĂÙ ÎÁÂÏÒÏÍ" #: ../../strtbl.c:3669 ../../strtbl.c:3673 msgid "center justified" msgstr "" #: ../../strtbl.c:3669 ../../strtbl.c:3671 msgid "right justified" msgstr "" #: ../../strtbl.c:3671 ../../strtbl.c:3673 msgid "left justified" msgstr "" #: ../../strtbl.c:3678 msgid "next font" msgstr "ÓÌĆÄ. ÛÒÉÆÔ" #: ../../strtbl.c:3678 msgid "prev font" msgstr "ĐÒĆÄ. ÛÒÉÆÔ" #: ../../strtbl.c:3683 msgid "inc text vspace" msgstr "" #: ../../strtbl.c:3683 msgid "modify text vspace" msgstr "" #: ../../strtbl.c:3683 msgid "dec text vspace" msgstr "" #: ../../strtbl.c:3688 msgid "next text size" msgstr "ÓÌĆÄ . ÒÁÚÍĆÒ ÔĆËÓÔÁ" #: ../../strtbl.c:3688 msgid "prev text size" msgstr "ĐÒĆÄ. ÒÁÚÍĆÒ ÔĆËÓÔÁ" #: ../../strtbl.c:3693 msgid "next line width" msgstr "ÓÌĆÄ. ÔÏÌĘÉÎÁ ÌÉÎÉÉ" #: ../../strtbl.c:3693 msgid "prev line width" msgstr "ĐÒĆÄ. ÔÏÌĘÉÎÁ ÌÉÎÉÉ" #: ../../strtbl.c:3698 msgid "next line style" msgstr "ÓÌĆÄ. ÓÔÉÌŰ ÔĆËÓÔÁ" #: ../../strtbl.c:3698 msgid "prev line style" msgstr "ĐÒĆÄ. ÓÔÉÌŰ ÌÉÎÉÉ" #: ../../strtbl.c:3703 msgid "next line type" msgstr "ÓÌĆÄ. ÔÉĐ ÌÉÎÉÉ" #: ../../strtbl.c:3703 msgid "prev line type" msgstr "ĐÒĆÄ. ÔÉĐ ÌÉÎÉÉ" #: ../../strtbl.c:3708 msgid "next line dash" msgstr "ÓÌĆÄ. ÚÁĐÏÌÎĆÎÉĆ ÌÉÎÉÉ" #: ../../strtbl.c:3708 msgid "prev line dash" msgstr "ĐÒĆÄ. ÚÁĐÏÌÎĆÎÉĆ ÌÉÎÉÉ" #: ../../strtbl.c:3713 msgid "inc rcbox radius" msgstr "" #: ../../strtbl.c:3713 msgid "modify rcbox radius" msgstr "" #: ../../strtbl.c:3713 msgid "dec rcbox radius" msgstr "" #: ../../strtbl.c:3718 msgid "zoom in" msgstr "ŐŚĆÌÉȚÉÔŰ" #: ../../strtbl.c:3718 msgid "modify zoom" msgstr "" #: ../../strtbl.c:3718 msgid "zoom out" msgstr "ŐÍĆÎŰÛÉÔŰ" #: ../../strtbl.c:3723 msgid "unconstrained move mode" msgstr "" #: ../../strtbl.c:3725 msgid "constrained move mode" msgstr "" #: ../../strtbl.c:3735 #, fuzzy msgid "stretchable text mode" msgstr "éÚÍĆÎĆÎÉĆ ÒÁÚÍĆÒÏŚ ÔĆËÓÔÁ" #: ../../strtbl.c:3737 #, fuzzy msgid "non-stretchable text mode" msgstr "éÚÍĆÎĆÎÉĆ ÒÁÚÍĆÒÏŚ ÔĆËÓÔÁ" #: ../../strtbl.c:3742 msgid "landscape" msgstr "ÌÁÎÄÛÁÆÔ" #: ../../strtbl.c:3742 ../../strtbl.c:3744 msgid "PageStyle Menu" msgstr "" #: ../../strtbl.c:3744 msgid "portrait" msgstr "ĐÏÒÔÒĆÔ" #: ../../strtbl.c:3749 msgid "next fill pattern" msgstr "ÓÌĆÄ. ÛÁÂÌÏÎ ÚÁĐÏÌÎĆÎÉŃ" #: ../../strtbl.c:3749 msgid "prev fill pattern" msgstr "ĐÒĆÄ. ÛÁÂÌÏÎ ÚÁĐÏÌÎĆÎÉŃ" #: ../../strtbl.c:3754 msgid "next pen pattern" msgstr "ÓÌĆÄ. ÛÁÂÌÏÎ ĐĆÒÁ" #: ../../strtbl.c:3754 msgid "prev pen pattern" msgstr "ĐÒĆÄ. ÛÁÂÌÏÎ ĐĆÒÁ" #: ../../strtbl.c:3759 #, fuzzy msgid "transparent pattern mode" msgstr "Transparent Pattern" #: ../../strtbl.c:3761 msgid "opaque pattern mode" msgstr "" #. #. * note: the m field is used for the localized strings #. #: ../../strtbl.c:3834 ../../strtbl.c:3847 msgid "Shift All Tabs Down" msgstr "" #: ../../strtbl.c:3835 msgid "Shift Tabs Down" msgstr "" #: ../../strtbl.c:3836 ../../strtbl.c:3849 #, fuzzy msgid "Check All" msgstr "śÙÄĆÌÉÔŰ ŚÓĆ" #: ../../strtbl.c:3837 ../../strtbl.c:3850 msgid "Uncheck All" msgstr "" #: ../../strtbl.c:3838 msgid "Shift Tabs Up" msgstr "" #: ../../strtbl.c:3839 ../../strtbl.c:3852 msgid "Shift All Tabs Up" msgstr "" #: ../../strtbl.c:3848 msgid "Shift 10 Tabs Down" msgstr "" #: ../../strtbl.c:3851 msgid "Shift 10 Tabs Up" msgstr "" #. #. * note: the localized field is used for the localized strings #. #: ../../strtbl.c:3910 msgid "arrow height" msgstr "" #: ../../strtbl.c:3911 msgid "arrow width" msgstr "" #: ../../strtbl.c:3912 msgid "arrow style" msgstr "" #: ../../strtbl.c:3913 msgid "color" msgstr "ĂŚĆÔ" #: ../../strtbl.c:3914 msgid "dash" msgstr "" #: ../../strtbl.c:3915 msgid "line width" msgstr "ÔÏÌĘÉÎÁ ÌÉÎÉÉ" #: ../../strtbl.c:3916 msgid "pattern transparency" msgstr "" #: ../../strtbl.c:3917 msgid "fill" msgstr "ÚÁĐÏÌÎĆÎÉĆ" #: ../../strtbl.c:3918 msgid "pen" msgstr "ĐĆÒÏ" #: ../../strtbl.c:3919 msgid "rcbox radius" msgstr "" #: ../../strtbl.c:3920 msgid "spline" msgstr "ÓĐÌÁÊÎ" #: ../../strtbl.c:3921 msgid "text font" msgstr "ÛÒÉÆÔ ÔĆËÓÔÁ" #: ../../strtbl.c:3922 msgid "text style (no use, part of text font)" msgstr "" #: ../../strtbl.c:3923 msgid "text justification" msgstr "ŚÙÒÁŚÎÉŚÁÎÉĆ ÔĆËÓÔÁ" #: ../../strtbl.c:3924 msgid "text size" msgstr "ÒÁÚÍĆÒ ÔĆËÓÔÁ" #: ../../strtbl.c:3925 msgid "text vertical spacing" msgstr "" #: ../../strtbl.c:3926 #, fuzzy msgid "text underline" msgstr "îĆđÏÄȚĆÒËÎŐÔÏ" #: ../../strtbl.c:3927 msgid "transformation matrix" msgstr "ÍÁÔÒÉĂÁ ĐÒĆÏÂÒÁÚÏŚÁÎÉŃ" #: ../../strtbl.c:3928 #, fuzzy msgid "line width index" msgstr "ôÏÌĘÉÎÁ ÌÉÎÉÉ" #. #. * note: the m field is used for the localized strings #. #: ../../strtbl.c:3976 msgid "Set printing mode to print to a printer" msgstr "" #: ../../strtbl.c:3977 msgid "Set printing mode to generate EPS files" msgstr "" #: ../../strtbl.c:3978 msgid "Set printing mode to generate PS files" msgstr "" #: ../../strtbl.c:3979 msgid "Set printing mode to generate X11 Bitmap files" msgstr "" #: ../../strtbl.c:3980 msgid "Set printing mode to generate X11 Pixmap files" msgstr "" #: ../../strtbl.c:3981 msgid "Set printing mode to generate ASCII files" msgstr "" #: ../../strtbl.c:3982 msgid "Set printing mode to generate EPSI files" msgstr "" #: ../../strtbl.c:3983 msgid "Set printing mode to generate GIF/ISMAP files" msgstr "" #: ../../strtbl.c:3984 msgid "Set printing mode to generate HTML files" msgstr "" #: ../../strtbl.c:3985 msgid "Set printing mode to generate PDF files" msgstr "" #: ../../strtbl.c:3986 msgid "Set printing mode to generate DOS/Windows EPSI files" msgstr "" #: ../../strtbl.c:3987 msgid "Set printing mode to generate PNG files" msgstr "" #: ../../strtbl.c:3988 msgid "Set printing mode to generate JPEG files" msgstr "" #: ../../strtbl.c:3989 msgid "Set printing mode to generate NetList files" msgstr "" #: ../../strtbl.c:3990 #, c-format msgid "Set printing mode to generate %s files" msgstr "" #~ msgid "Update Objects" #~ msgstr "ïÂÎÏŚÉÔŰ ÏÂßĆËÔÙ" #~ msgid "White-Board" #~ msgstr "White-Board" ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/Po.tmpl-solaris�������������������������������������������������������������������0000644�0000764�0000764�00000000470�10064673302�016341� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/Po.tmpl-solaris,v 1.1 2004/06/18 23:12:02 william Exp $ XCOMM INSTALL = bsdinst -c MKINSTALLDIRS = bsdinst -d DESTDIR = SYSNLSDIR = /usr/lib/locale NLSDIR = $(DESTDIR)$(SYSNLSDIR) ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/Po.tmpl-linux���������������������������������������������������������������������0000644�0000764�0000764�00000000470�10064673302�016024� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/Po.tmpl-linux,v 1.1 2004/06/18 23:12:02 william Exp $ XCOMM INSTALL = install -c MKINSTALLDIRS = install -d DESTDIR = SYSNLSDIR = /usr/share/locale NLSDIR = $(DESTDIR)$(SYSNLSDIR) ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/ja/�������������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233155�014001� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/ja/tgif.spec����������������������������������������������������������������������0000644�0000764�0000764�00000024234�10774250147�015624� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%define Xresource_ja_ver 4.1ja9 Name: tgif Version: 4.1.45 Release: 5%{?dist} Summary: 2-D drawing tool Group: Applications/Multimedia License: QPL URL: http://bourbon.usc.edu/tgif/ Source0: http://downloads.sourceforge.net/%{name}/%{name}-QPL-%{version}.tar.gz # Borrowed from Vine Linux Source1: tgif-%{Xresource_ja_ver}.tar.gz Source2: tgif-4.1.41.ja.po Source3: tgif.desktop Source4: http://bourbon.usc.edu/tgif/images/%{name}.gif Source5: tgif-wrapper.sh Patch1: tgif-4.1.45-fontcheck.patch Patch3: tgif-4.1.35-overthespot_fix.patch # http://tyche.pu-toyama.ac.jp/~a-urasim/tgif/ Patch10: tgif-textcursor-a-urasim.patch Patch20: tgif-4.1.44-xim-bad-focus.patch Patch100: tgif-QPL-4.1.45-open-with-mode.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-%(%{__id_u} -n) BuildRequires: ImageMagick BuildRequires: imake BuildRequires: desktop-file-utils BuildRequires: gettext BuildRequires: libXmu-devel Requires: ghostscript Requires: netpbm-progs %description Tgif - Xlib based interactive 2-D drawing facility under X11. Supports hierarchical construction of drawings and easy navigation between sets of drawings. It's also a hyper-graphics (or hyper-structured-graphics) browser on the World-Wide-Web. %prep %setup -q -n %{name}-QPL-%{version} -a 1 %patch1 -p1 -b .fontcheck %patch3 -p1 -b .overthespot %patch10 -p0 -b textcursor %patch20 -p1 -b .xim-bad-focus %patch100 -p1 -b .opmode %{__cp} -pf %{SOURCE2} po/ja/ja.po pushd po/ja %{__perl} -pi \ -e 's,JISX-0208-1983-0,EUC-JP,g' \ ja.po popd # use scalable bitmap font for i in C ja ; do %{__sed} -e s,alias\-mincho,misc\-mincho,g \ -e s,alias\-gothic,jis\-fixed,g \ -i tgif-%{Xresource_ja_ver}/${i}/Tgif.ad done %build %{__cp} -pf Tgif.tmpl-linux Tgif.tmpl %{__sed} -i.mode -e 's|0664|0644|' Tgif.tmpl xmkmf %{__sed} -i.mode -e 's|0444|0644|' Makefile DEFOPTS='-DOVERTHESPOT -DUSE_XT_INITIALIZE -D_ENABLE_NLS -DPRINT_CMD=\"lpr\" -DA4PAPER' %{__make} %{?_smp_mflags} \ CC="%{__cc} %{optflags}" \ MOREDEFINES="$DEFOPTS" \ TGIFDIR=%{_datadir}/tgif/ \ LOCAL_LIBRARIES="-lXmu -lXt -lX11" \ tgif pushd po xmkmf %{__sed} -i.mode -e 's|0444|0644|' Makefile %{__make} \ Makefile \ Makefiles \ depend \ all popd %install %{__rm} -rf $RPM_BUILD_ROOT/ # wrap xgif %{__make} \ DESTDIR=$RPM_BUILD_ROOT/ \ BINDIR=%{_libexecdir}/ \ TGIFDIR=%{_datadir}/tgif/ \ INSTALLFLAGS="-cp" \ install \ install.man %{__mkdir_p} $RPM_BUILD_ROOT%{_bindir}/ %{__install} -cpm 0755 %{SOURCE5} $RPM_BUILD_ROOT%{_bindir}/%{name} %{__rm} -f $RPM_BUILD_ROOT%{_datadir}/tgif/*.obj %{__install} -cpm 0644 *.obj \ $RPM_BUILD_ROOT%{_datadir}/tgif/ %{__mkdir_p} $RPM_BUILD_ROOT%{_datadir}/X11/{,ja/}app-defaults/ %{__install} -cpm 0644 tgif-%{Xresource_ja_ver}/C/Tgif.ad \ $RPM_BUILD_ROOT%{_datadir}/X11/app-defaults/Tgif %{__install} -cpm 0644 tgif-%{Xresource_ja_ver}/ja/Tgif.ad \ $RPM_BUILD_ROOT%{_datadir}/X11/ja/app-defaults/Tgif pushd po %{__make} \ DESTDIR=$RPM_BUILD_ROOT/ \ INSTALLFLAGS="-cp" \ install popd # desktop file & icon %{__mkdir_p} $RPM_BUILD_ROOT%{_datadir}/applications/ desktop-file-install \ --remove-category 'Application' \ --remove-category 'X-Fedora' \ --vendor 'fedora' \ --dir $RPM_BUILD_ROOT%{_datadir}/applications/ \ %{SOURCE3} %{__mkdir_p} %{buildroot}%{_datadir}/pixmaps/ convert -geometry 64x64! %{SOURCE4} %{name}.png %{__install} -cpm644 %{name}.png \ $RPM_BUILD_ROOT/%{_datadir}/pixmaps/ %{find_lang} tgif %clean %{__rm} -rf $RPM_BUILD_ROOT/ %post %{_bindir}/update-desktop-database -q %{_datadir}/applications/ ||: %postun %{_bindir}/update-desktop-database -q %{_datadir}/applications/ ||: %files -f %{name}.lang %defattr(-,root,root,-) %doc Copyright HISTORY LICENSE.QPL %doc README* %doc VMS_MAKE_TGIF.COM %doc example.tex %doc %{name}-%{Xresource_ja_ver}/README.jp %{_bindir}/%{name} %{_libexecdir}/%{name} %{_mandir}/man1/%{name}.1x* %{_datadir}/%{name}/ %{_datadir}/X11/app-defaults/Tgif # Currently no package owns the following directories %dir %{_datadir}/X11/ja/ %dir %{_datadir}/X11/ja/app-defaults/ %{_datadir}/X11/ja/app-defaults/Tgif %{_datadir}/pixmaps/%{name}.png %{_datadir}/applications/*-%{name}.desktop %changelog * Wed Aug 22 2007 TASAKA Mamoru <mtasaka@ioa.s.u-tokyo.ac.jp> - 4.1.45-5 - Set mode explicitly when open(2) is used with O_CREAT due to recent glibc change * Wed Aug 22 2007 TASAKA Mamoru <mtasaka@ioa.s.u-tokyo.ac.jp> - 4.1.45-4.dist.1 - Mass rebuild (buildID or binutils issue) * Wed Jul 11 2007 MATSUURA Takanori <t.matsuu at gmail.com> - 4.1.45-4 - based on tgif-4.1.44-0vl6.src.rpm from VineSeed main - use scalable bitmap font * Mon Jul 9 2007 TASAKA Mamoru <mtasaka@ioa.s.u-tokyo.ac.jp> - 4.1.45-3 - Clean up BuildRequires * Thu Jul 5 2007 TASAKA Mamoru <mtasaka@ioa.s.u-tokyo.ac.jp> - 4.1.45-2 - Explicitly set LANG=ja_JP.eucJP on ja_JP locale - Add needed Requires * Thu Jul 5 2007 TASAKA Mamoru <mtasaka@ioa.s.u-tokyo.ac.jp> - 4.1.45-1 - Clean up for Fedora * Sat Apr 07 2007 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 4.1.44-0vl6 - add Patch20 to fix problems with {scim,uim}-anthy (<BTS:512>) * Thu Jan 4 2007 MATSUURA Takanori <t.matsuu at gmail.com> - 4.1.45-0vl5.1 - based on tgif-4.1.44-0vl5.src.rpm from VineSeed main - update to 4.1.45 - some ajustments for Fedora Core * Wed Dec 27 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 4.1.44-0vl5 - add tgificon.png (source4) - update tgif.desktop (source3) * Wed Oct 11 2006 Daisuke SUZUKI <daisuke@linux.or.jp> 4.1.44-0vl4 - add Patch10 to fix text cursor problem (<BTS:250>) http://tyche.pu-toyama.ac.jp/~a-urasim/tgif/ * Fri Sep 08 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 4.1.44-0vl3 - add and update desktop file (source3) - move desktop file to %%{_datadir}/applications - exec update-desktop-database at %%post,%%postun - add Requires(post,postun): desktop-file-utils * Sat Sep 02 2006 KAZUKI SHIMURA <kazuki@ma.ccnw.ne.jp> 4.1.44-0vl2 - add BuildRequires: XOrg-devel * Mon Jan 17 2005 Daisuke SUZUKI <daisuke@linux.or.jp> 4.1.44-0vl1 - switch to QPL version * Thu Jun 10 2004 KOBAYASHI R. Taizo <tkoba@vinelinux.org> 4.1.43-0vl1 - source update * Thu Jun 12 2003 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 4.1.42-0vl2 - rebuild with new toolchains * Fri Mar 29 2002 Jun Nishii <jun@vinelinux.org> 4.1.41-0vl3 - add Tate-gaki entry for Ricoh fonts * Sun Mar 17 2002 Shoji Matsumoto <shom@vinelinux.org> 4.1.41-0vl2 - refine Tgif.ad for Vine 2.5 * Fri Oct 19 2001 Jun Nishii <jun@vinelinux.org> 4.1.41-0vl1 - ver.up * Thu Jul 28 2001 Shoji Matsumoto <shom@vinelinux.org> - 4.1.40-0vl2 - tgif-4.1ja6 (-aliastt-{mincho,gothic}- -> -alias-{mincho,gothic}-) * Thu Dec 7 2000 Jun Nishii <jun@vinelinux.org> - 4.1.40-0vl1 * Tue Oct 3 2000 Jun Nishii <jun@vinelinux.org> - 4.1.39-0vl2 - added documents * Sun Sep 10 2000 Jun Nishii <jun@vinelinux.org> - 4.1.39-0vl1 * Thu Aug 17 2000 Yasuyuki Furukawa <furukawa@vinelinux.org> - added overthespot_fix patch for XIM with OverTheSpot style. * Fri Aug 11 2000 Jun Nishii <jun@vinelinux.org> - 4.1.36-0vl1 * Mon Aug 7 2000 Jun Nishii <jun@vinelinux.org> - 4.1.35-0vl1 * Sat Jul 15 2000 MATSUBAYASHI 'Shaolin' Kohji <shaolin@rhythmaning.org> - 4.1.34-0vl2 - modified %%files section to handle compressed man page * Mon May 8 2000 Jun Nishii <jun@vinelinux.org> - updated 4.0.33 * Thu Apr 20 2000 Yasuyuki Furukawa <furukawa@vinelinux.org> - updated 4.0.29 - modified fontcheck patch to check signgle byte font, too. * Thu Mar 9 2000 Yasuyuki Furukawa <furukawa@vinelinux.org> - updated 4.0.28 * Mon Feb 28 2000 Yasuyuki Furukawa <furukawa@vinelinux.org> - updated 4.0.27 * Thu Feb 24 2000 Yasuyuki Furukawa <furukawa@vinelinux.org> - added tgif wmconfig, desktop file * Fri Feb 18 2000 Yasuyuki Furukawa <furukawa@vinelinux.org> - added xim unofficial patch from fj.sources to fix a bug about XIM. * Wed Feb 16 2000 Jun Nishii <jun@vinelinux.org> - 4.1.26-0vl3 - bug fix in tgif-4.1.26-fontcheck.patch * Mon Feb 14 2000 Jun Nishii <jun@vinelinux.org> - 4.1.26-0vl2 - merge tgif-4.1.26-fontcheck.patch by Mr. Yasuyuki Furukawa which obsoletes trigger for Dynafonts and TrueTypeFonts ! * Thu Jan 20 2000 Jun Nishii <jun@vinelinux.org> - 4.1.26-0vl2 - added trigger for Dynafonts and TrueTypeFonts * Thu Jan 20 2000 Yasuyuki Furukawa <furukawa@vinelinux.org> - updated to 4.1.26 - change ja resource from ja_JP.ujis/app-defaults to ja/app-defaults - modified font setting * Wed Nov 17 1999 Jun Nishii <jun@flatout.org> - updated to 4.1.25 * Thu Nov 4 1999 Jun Nishii <jun@flatout.org> - updated to 4.1.23 * Thu Oct 28 1999 Jun Nishii <jun@flatout.org> - rel.4 - update ja.po - more gettextize in choice.c and menu.c * Wed Oct 27 1999 Jun Nishii <jun@flatout.org> - rel.3 - merge messages in strtbl.c and added japanese catalog * Tue Oct 26 1999 Jun Nishii <jun@flatout.org> - rel.2 - enable nls in status buffer and added japanese catalog * Tue Oct 26 1999 Jun Nishii <jun@flatout.org> - updated to 4.1.22 * Sun Aug 8 1999 Norihito Ohmori <ohmori@flatout.org> - archive format change to bzip2 - rebuild for glibc-2.1.x * Wed Jun 30 1999 Jun Nishii <jun@flatout.org> - updated to 4.1.16 * Tue Apr 15 1999 Jun Nishii <jun@flatout.org> - updated to 4.1.7 * Tue Apr 8 1999 Jun Nishii <jun@flatout.org> - updated to 4.1.6 - Our menufontset-nls patch and xim patch were merged in original source! * Tue Mar 9 1999 MATSUMOTO Shoji <vine@flatout.org> - vertical font indicator bug fix - modify resource and tgif.sh * Mon Mar 8 1999 Jun Nishii <jun@flatout.org> - updated to 4.1 * Mon Mar 8 1999 Jun Nishii <jun@flatout.org> - bug fix in showing shortcut key in menu - modify document * Wed Mar 4 1999 MATSUMOTO Shoji <vine@flatout.org> - set Tgif.InitialFont Ryumin * Wed Mar 3 1999 MATSUMOTO Shoji <vine@flatout.org> - add XIM OverTheSpot patch - modify Tgif-ja.ad * Mon Mar 2 1999 Jun Nishii <jun@flatout.org> - updated to 4.0.18 * Mon Mar 1 1999 Jun Nishii <jun@flatout.org> - make patch to support fontset and nls - change version name as 4.0.17_jp * Sat Feb 27 1999 Jun Nishii <jun@flatout.org> - modify Tgif-ja.ad (use A4,cm,color-icon,etc...) - correct document * Wed Feb 24 1999 Jun Nishii <jun@flatout.org> - updated to ver. 4.0.17 - make wrapper to read Tgif-ja * Sat Feb 20 1999 Jun Nishii <jun@flatout.org> - updated to ver. 4.0.16 * Tue Feb 16 1999 Jun Nishii <jun@flatout.org> - build ver. 4.0.14 for Vine Linux ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/ja/ja.po��������������������������������������������������������������������������0000644�0000764�0000764�00001145015�10773267116�014756� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# Author: Jun Nishii, Project Vine <jun@vinelinux.org>, 2000, 2001 # # @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/ja/ja.po,v 1.2 2008/03/28 22:16:46 william Exp $ # #, fuzzy msgid "" msgstr "" "Project-Id-Version: tgif-4.0.17\n" "POT-Creation-Date: 2001-10-19 17:49+0900\n" "PO-Revision-Date: 2000-12-07 19:00 JST\n" "Last-Translator: Jun Nishii <jun@vinelinux.org>\n" "Language-Team: Project Vine <Vine@vinelinux.org>\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=JISX-0208-1983-0\n" "Content-Transfer-Encoding: 8-bit\n" #: ../../menuinfo.c:72 msgid "Enter select/move/resize object mode" msgstr "„Ș„Ö„ž„§„Ż„È€ÎÁȘÂò/°Üư/łÈÂçœÌŸź„âĄŒ„É" #: ../../menuinfo.c:74 msgid "Enter draw text mode" msgstr "„Æ„­„č„ÈÉÁČè„âĄŒ„É" #: ../../menuinfo.c:76 msgid "Enter draw rectangle mode" msgstr "»ÍłŃ·ÁÉÁČè„âĄŒ„É" #: ../../menuinfo.c:78 msgid "Enter draw corner oval mode" msgstr "„łĄŒ„ÊĄŒ€«€é€ÎÂʱßÉÁČè„âĄŒ„É" #: ../../menuinfo.c:80 msgid "Enter draw center oval mode" msgstr "ĂæżŽÀßÄꀫ€é€ÎÂʱßÉÁČè„âĄŒ„É" #: ../../menuinfo.c:82 msgid "Enter draw edge circle mode" msgstr "ĂŒÀßÄê€Î±ßÉÁČè„âĄŒ„É" #: ../../menuinfo.c:84 msgid "Enter draw poly/open spline mode" msgstr "ÀȚ€ìÀț/¶ÊÀț„âĄŒ„É" #: ../../menuinfo.c:86 msgid "Enter draw polygon/close spline mode" msgstr "ÂżłŃ·Á/ÊÄ€ž€ż¶ÊÀț„âĄŒ„É" #: ../../menuinfo.c:88 msgid "Enter draw arc mode (specify center first)" msgstr "±ßžÌ„âĄŒ„É(ĂæżŽ€òÀè€Ë»ŰÄê)" #: ../../menuinfo.c:90 msgid "Enter draw arc mode (specify endpoints first)" msgstr "±ßžÌ„âĄŒ„É(ĂŒ€ò»ŰÄê)" #: ../../menuinfo.c:93 msgid "Enter draw rcbox mode" msgstr "łŃ€ÎŽĘ€€ÄčÊę·Á„âĄŒ„É" #: ../../menuinfo.c:95 msgid "Enter draw freehand poly/open spline mode" msgstr "„Ő„êĄŒ„Ï„ó„É€ÎÀȚ€ìÀț/¶ÊÀț„âĄŒ„É" #: ../../menuinfo.c:98 msgid "Enter select/move vertices mode" msgstr "ÄșĆÀ€ÎÁȘÂò/°Üư„âĄŒ„É" #: ../../menuinfo.c:100 msgid "Enter rotate/shear object mode" msgstr "ČóĆŸ/ÊŃ·Á„âĄŒ„É" #: ../../menuinfo.c:111 msgid "No arrows for a poly/open spline" msgstr "ÀȚ€ìÀț/¶ÊÀț€Ë€ÏÌđ°ő€Ï€Ä€±€Ê€€" #: ../../menuinfo.c:114 msgid "An arrow at the end of a poly/open spline" msgstr "ÀȚ€ìÀț/¶ÊÀț€ÎœȘ€ê€ÎĆÀ€ËÌđ°ő€ò€Ä€±€ë" #: ../../menuinfo.c:117 msgid "An arrow at the beginning of a poly/open spline" msgstr "ÀȚ€ìÀț/¶ÊÀț€Î»Ï€á€ÎĆÀ€ËÌđ°ő€ò€Ä€±€ë" #: ../../menuinfo.c:120 msgid "Arrows at both ends of a poly/open spline" msgstr "ÀȚ€ìÀț/¶ÊÀț€ÎÎŸĂŒ€ËÌđ°ő€ò€Ä€±€ë" #: ../../menuinfo.c:129 msgid "Straight line segments" msgstr "ÄŸÀț/ÀȚ€ìÀț" #: ../../menuinfo.c:131 msgid "Open/closed splines" msgstr "„脌„é„€„ó¶ÊÀț" #: ../../menuinfo.c:133 msgid "Interpolated splines" msgstr "ÆâÁȚ€”€ì€ż„脌„é„€„ó" #: ../../menuinfo.c:143 msgid "Set horizontal alignment to none" msgstr "żćÊżÊęžț€ÎÀ°Îó€Ï€Ê€·" #: ../../menuinfo.c:146 msgid "Set horizontal alignment to left aligned" msgstr "șžĂŒ€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó" #: ../../menuinfo.c:149 msgid "Set horizontal alignment to center aligned" msgstr "ĂæżŽ€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó" #: ../../menuinfo.c:152 msgid "Set horizontal alignment to right aligned" msgstr "±ŠĂŒ€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó" #: ../../menuinfo.c:155 msgid "Set horizontal distribution to equal-spacing" msgstr "żćÊżÊęžț€ËĆùŽÖłÖ€ÇÀ°Îó" #: ../../menuinfo.c:164 msgid "Set vertical alignment to none" msgstr "żâÄŸÊęžț€ÎÀ°Îó€Ï€Ê€·" #: ../../menuinfo.c:167 msgid "Set vertical alignment to top aligned" msgstr "ŸćĂŒ€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó" #: ../../menuinfo.c:170 msgid "Set vertical alignment to middle aligned" msgstr "ĂæżŽ€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó" #: ../../menuinfo.c:173 msgid "Set vertical alignment to bottom aligned" msgstr "Äì€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó" #: ../../menuinfo.c:176 msgid "Set vertical distribution to equal-spacing" msgstr "żâÄŸÊęžț€ËĆùŽÖłÖ€ÇÀ°Îó" #: ../../menuinfo.c:185 msgid "Set constrained move mode" msgstr "čŽÂ«€”€ì€ż°Üư„âĄŒ„É" #: ../../menuinfo.c:187 msgid "Set unconstrained move mode" msgstr "čŽÂ«€Î€Ê€€°Üư„âĄŒ„É" #: ../../menuinfo.c:195 msgid "Make text objects not stretchable" msgstr "„Æ„­„č„È€ÎłÈÂçœÌŸź€ò€Ç€­€Ê€Ż€č€ë" #: ../../menuinfo.c:197 msgid "Make text objects stretchable" msgstr "„Æ„­„č„È€òłÈÂçœÌŸźČĀˀč€ë" #: ../../menuinfo.c:208 msgid "Stacked page mode" msgstr "„脿„Ă„ŻĄŠ„ÚĄŒ„žĄŠ„âĄŒ„É" #: ../../menuinfo.c:210 msgid "Tiled page mode" msgstr "„ÚĄŒ„ž€Î„ż„€„ëÉœŒš" #: ../../menuinfo.c:218 msgid "Make fill and pen patterns opaque" msgstr "ĆÉ€ê€Ä€Ö€·€È„ڄ󥊄фżĄŒ„ó€ÏÈóÆ©Čá€Ë€č€ë" #: ../../menuinfo.c:220 msgid "Make fill and pen patterns transparent" msgstr "ĆÉ€ê€Ä€Ö€·€È„ڄ󥊄фżĄŒ„ó€òÆ©Čá€Ë€č€ë" #: ../../menuinfo.c:228 ../../menuinfo.c:1202 msgid "Portrait" msgstr "„ĘĄŒ„È„ìĄŒ„È" #: ../../menuinfo.c:228 ../../menuinfo.c:1202 msgid "Portrait page style" msgstr "œÄÄč€Î„ÚĄŒ„ž„脿„€„ë" #: ../../menuinfo.c:230 ../../menuinfo.c:1204 msgid "Landscape" msgstr "„é„ó„Ʉ脱ĄŒ„Ś" #: ../../menuinfo.c:230 ../../menuinfo.c:1204 msgid "Lanscape page style" msgstr "ČŁÄč€Î„ÚĄŒ„ž„脿„€„ë" #: ../../menuinfo.c:242 msgid "Roman" msgstr "„íĄŒ„Ț„óÂÎ" #: ../../menuinfo.c:242 msgid "Roman text style" msgstr "„íĄŒ„Ț„óÂÎ" #: ../../menuinfo.c:244 msgid "Bold" msgstr "ÂÀ»ú" #: ../../menuinfo.c:244 msgid "Bold text style" msgstr "ÂÀ»ú" #: ../../menuinfo.c:246 msgid "Italic" msgstr "ŒĐÂÎ" #: ../../menuinfo.c:246 msgid "Italic text style" msgstr "ŒĐÂÎÊž»ú" #: ../../menuinfo.c:248 msgid "BoldItalic" msgstr "ŒĐÂÎÂÀ»ú" #: ../../menuinfo.c:248 msgid "Bold-italic text style" msgstr "ŒĐÂÎÂÀ»ú" #: ../../menuinfo.c:251 msgid "Left" msgstr "șž" #: ../../menuinfo.c:251 msgid "Left justified text" msgstr "„Æ„­„č„È€òșž€Ë€œ€í€š€ë" #: ../../menuinfo.c:253 msgid "Center" msgstr "Ăæ±û" #: ../../menuinfo.c:253 msgid "Center justified text" msgstr "„Æ„­„č„È€òĂæ±û€Ë€œ€í€š€ë" #: ../../menuinfo.c:255 msgid "Right" msgstr "±ŠŽó€»" #: ../../menuinfo.c:255 msgid "Right justified text" msgstr "„Æ„­„č„È€ò±Š€Ë€œ€í€š€ë" #: ../../menuinfo.c:258 msgid "No Underlined" msgstr "„ą„ó„ÀĄŒ„é„€„ó€Ê€·" #: ../../menuinfo.c:258 msgid "No underlined text" msgstr "„Æ„­„č„Ȁ΄ą„ó„ÀĄŒ„é„€„óŒè€êŸĂ€·" #: ../../menuinfo.c:260 msgid "Underlined" msgstr "„ą„ó„ÀĄŒ„é„€„ó" #: ../../menuinfo.c:260 msgid "Underlined text" msgstr "„Æ„­„č„Ȁ˄ą„ó„ÀĄŒ„é„€„ó€ò€Ò€Ż" #: ../../menuinfo.c:270 msgid "Next Page" msgstr "ŒĄ€Î„ÚĄŒ„ž" #: ../../menuinfo.c:270 msgid "Go to next page" msgstr "ŒĄ€Î„ÚĄŒ„ž€Ű°Üư" #: ../../menuinfo.c:271 msgid "Prev Page" msgstr "Á°€Î„ÚĄŒ„ž" #: ../../menuinfo.c:271 msgid "Go to previous page" msgstr "Á°€Î„ÚĄŒ„ž€ËÌá€ë" #: ../../menuinfo.c:272 msgid "Goto Page..." msgstr "„ÚĄŒ„ž°Üư..." #: ../../menuinfo.c:272 msgid "Go to a specified page" msgstr "»ŰÄꀷ€ż„ÚĄŒ„ž€Ë°Üư€č€ë" #: ../../menuinfo.c:274 msgid "Name Pages..." msgstr "„ÚĄŒ„ž€ËÌŸÁ°€ò€Ä€±€ë..." #: ../../menuinfo.c:274 msgid "Assign names to pages" msgstr "„ÚĄŒ„ž€ËÌŸÁ°€ò€Ä€±€ë..." #: ../../menuinfo.c:276 msgid "Edit Page File Names..." msgstr "„ÚĄŒ„žÌŸÊÔœž..." #: ../../menuinfo.c:277 msgid "Assign file names to pages to be used for PrintOneFilePerPage()" msgstr "PrintOneFilePerPage() €ÇÍŃ€€€ëłÆ„ÚĄŒ„ž€Î„Ő„Ą„€„ëÌŸÀßÄê" #: ../../menuinfo.c:280 msgid "Add Page Before..." msgstr "Á°€Ë„ÚĄŒ„ž€òÄÉČĂ..." #: ../../menuinfo.c:280 msgid "Add a page before the current page" msgstr "žœș߀΄ڥŒ„ž€ÎÁ°€ËĄą„ÚĄŒ„ž€òÄÉČĂ" #: ../../menuinfo.c:282 msgid "Add Page After..." msgstr "žć€í€Ë„ÚĄŒ„ž€òÄÉČĂ..." #: ../../menuinfo.c:283 msgid "Add a page after the current page" msgstr "žœș߀΄ڥŒ„ž€Îžć€í€ËĄą„ÚĄŒ„ž€òÄÉČĂ" #: ../../menuinfo.c:284 msgid "Delete Current Page" msgstr "žœș߀΄ڥŒ„ž€òșïœü" #: ../../menuinfo.c:284 msgid "Delete the current page" msgstr "žœș߀΄ڥŒ„ž€òșïœü" #: ../../menuinfo.c:286 msgid "Delete Pages..." msgstr "„ÚĄŒ„ž€Îșïœü..." #: ../../menuinfo.c:286 msgid "Delete user-specified pages" msgstr "»ŰÄꀷ€ż„ÚĄŒ„ž€òșïœü" #: ../../menuinfo.c:289 ../../menuinfo.c:312 ../../menuinfo.c:647 msgid "Print One Page" msgstr "žœș߀΄ڥŒ„ž€òœĐÎÏ" #: ../../menuinfo.c:289 msgid "Print the curret page" msgstr "žœș߀΄ڥŒ„ž€òœĐÎÏ€č€ë" #: ../../menuinfo.c:291 ../../menuinfo.c:649 msgid "Print Pages..." msgstr "žœș߀΄ڥŒ„ž€òœĐÎÏ..." #: ../../menuinfo.c:291 ../../menuinfo.c:649 msgid "Print user-specified pages" msgstr "»ŰÄꀷ€ż„ÚĄŒ„ž€òœĐÎÏ€č€ë" #: ../../menuinfo.c:293 ../../menuinfo.c:651 msgid "Print One File Per Page..." msgstr "łÆ„ÚĄŒ„ž€òÊÌ€Î„Ő„Ą„€„ë€ËœĐÎÏ..." #: ../../menuinfo.c:294 ../../menuinfo.c:652 msgid "Print into a separate file for each page" msgstr "łÆ„ÚĄŒ„ž€òÊÌ€Î„Ő„Ą„€„ë€ËœĐÎÏ€č€ë" #: ../../menuinfo.c:297 ../../menuinfo.c:315 msgid "Specify Paper Size..." msgstr "ÍŃ»æ„”„€„șÀßÄê..." #: ../../menuinfo.c:298 ../../menuinfo.c:316 msgid "Set the physical size of the paper" msgstr "ÍŃ»æ€Î„”„€„ș€òÀßÄê€č€ë" #: ../../menuinfo.c:299 ../../menuinfo.c:317 msgid "Set Paper Color..." msgstr "ÍŃ»æ€Îż§ÀßÄê..." #: ../../menuinfo.c:299 ../../menuinfo.c:317 msgid "Set the color of the paper" msgstr "ÍŃ»æ€Îż§€òÀßÄê€č€ë" #: ../../menuinfo.c:307 msgid "Toggle Page Line Shown" msgstr "„ÚĄŒ„ž¶­łŠÀț€ÎÉœŒšÀÚÂŰ" #: ../../menuinfo.c:308 msgid "Toggle the showing of page boundaries" msgstr "„ÚĄŒ„ž¶­łŠÀț€ÎÉœŒš€ÎÀÚÂŰ" #: ../../menuinfo.c:310 msgid "Specify Drawing Size..." msgstr "ÉÁČè„”„€„șÀßÄê..." #: ../../menuinfo.c:310 msgid "Change the drawing size" msgstr "ÉÁČè„”„€„ș€òÊŃčč€č€ë" #: ../../menuinfo.c:312 msgid "Select and print one of the pages" msgstr "1€Ä€Î„ÚĄŒ„ž€òÁȘÂò€·°őșț€č€ë" #: ../../menuinfo.c:325 ../../menuinfo.c:1207 ../../menuinfo.c:1644 msgid "Stacked Page" msgstr "„脿„Ă„ŻĄŠ„ÚĄŒ„žÁàșî" #: ../../menuinfo.c:326 ../../menuinfo.c:1645 msgid "StackedPage Menu" msgstr "„脿„Ă„Ż„ÚĄŒ„žĄŠ„á„Ë„ćĄŒ" #: ../../menuinfo.c:327 ../../menuinfo.c:1209 ../../menuinfo.c:1646 msgid "Tiled Page" msgstr "„ż„€„륊„ÚĄŒ„ž" #: ../../menuinfo.c:328 ../../menuinfo.c:1647 msgid "TiledPage Menu" msgstr "„ż„€„ë„ÚĄŒ„žĄŠ„á„Ë„ćĄŒ" #: ../../menuinfo.c:334 msgid "Reduce Colors..." msgstr "žșż§..." #: ../../menuinfo.c:335 msgid "Reduce the number of colors of a selected image" msgstr "ÁȘÂò€·€żČèÁü€Îż§żô€òžș€é€č" #: ../../menuinfo.c:338 msgid "Set Default Color Levels..." msgstr "„DŽՄ©„ë„È€Îż§łŹÄŽÀßÄê..." #: ../../menuinfo.c:339 msgid "Set the number of R G B color levels for the ``standard colors''" msgstr "``Éžœàż§''€Î R G B €Îż§żô€òÀßÄê€č€ë" #: ../../menuinfo.c:341 msgid "Reduce To Pixmap Colors..." msgstr "Pixmap€Îż§łŹÄŽ€Ëžșż§..." #: ../../menuinfo.c:342 msgid "Reduce the colors of a selected image to a the colors in an XPM file" msgstr "ÁȘÂò€·€żČèÁü€Îż§żô€òXPM„Ő„Ą„€„ë€Îż§żô€Ëžș€é€č" #: ../../menuinfo.c:344 msgid "Reduce To Default Colors" msgstr "„DŽՄ©„ë„È€Îż§łŹÄŽ€Ëžșż§" #: ../../menuinfo.c:345 msgid "Reduce the colors of a selected image to standard colors" msgstr "ÁȘÂò€·€żČèÁü€Îż§żô€òÉžœà€Îż§żô€Ëžș€é€č" #: ../../menuinfo.c:347 msgid "Default Error Diffuse" msgstr "" #: ../../menuinfo.c:348 msgid "Error diffuse to reduce colors of a selected image to standard colors" msgstr "" #: ../../menuinfo.c:356 msgid "Edge Detect" msgstr "„š„Ă„žžĄœĐ" #: ../../menuinfo.c:356 msgid "Perform edge-detection on a selected image" msgstr "ÁȘÂòČèÁü€Î„š„Ă„ž€ÎžĄœĐ" #: ../../menuinfo.c:358 msgid "Emboss" msgstr "É‭Ċ€ê" #: ../../menuinfo.c:358 msgid "Convert a selected image to gray and then emboss" msgstr "ÁȘÂòČèÁü€ò„°„ì„€„脱ĄŒ„ë€Ë€·ĄąÎ©ÂÎČœ€č€ë" #: ../../menuinfo.c:361 msgid "Spread..." msgstr "" #: ../../menuinfo.c:361 msgid "Spread the pixels of a selected image around" msgstr "" #: ../../menuinfo.c:363 msgid "Sharpen" msgstr "ÎŰłÔ¶ŻÄŽ" #: ../../menuinfo.c:363 msgid "Sharpen a selected image" msgstr "ÁȘÂòČèÁü€ÎÎŰłÔ€ò¶ŻÄŽ€č€ë" #: ../../menuinfo.c:365 msgid "Blur (3x3)" msgstr "€Ë€ž€ß (3x3)" #: ../../menuinfo.c:365 msgid "Blur a selected image using a 3 by 3 filter" msgstr "ÁȘÂòČèÁü€ò 3x3 €Î„Ő„Ł„ë„żĄŒ€Ç€Ë€ž€Ț€»€ë" #: ../../menuinfo.c:367 msgid "Blur (5x5)" msgstr "€Ë€ž€ß (5x5)" #: ../../menuinfo.c:367 msgid "Blur a selected image using a 5 by 5 filter" msgstr "ÁȘÂòČèÁü€ò 5x5 €Î„Ő„Ł„ë„żĄŒ€Ç€Ë€ž€Ț€»€ë" #: ../../menuinfo.c:369 msgid "Blur (7x7)" msgstr "€Ë€ž€ß (7x7)" #: ../../menuinfo.c:369 msgid "Blur a selected image using a 7 by 7 filter" msgstr "ÁȘÂòČèÁü€ò 7x7 €Î„Ő„Ł„ë„żĄŒ€Ç€Ë€ž€Ț€»€ë" #: ../../menuinfo.c:377 msgid "Run Bggen..." msgstr "" #: ../../menuinfo.c:378 msgid "Run 'bggen' to create an image using the size of a selected image" msgstr "" #: ../../menuinfo.c:380 msgid "Circular Bggen..." msgstr "" #: ../../menuinfo.c:381 msgid "Create a gray circular image using the size of a selected image" msgstr "" #: ../../menuinfo.c:383 msgid "Simple Rect Bggen..." msgstr "" #: ../../menuinfo.c:384 msgid "Create a single-color rectanglar image using the size of selected image" msgstr "" #: ../../menuinfo.c:392 msgid "Make Gray" msgstr "„°„ì„€„脱ĄŒ„ë€Ë€č€ë" #: ../../menuinfo.c:392 msgid "Convert a selected image into gray-scale" msgstr "ÁȘÂò€·€żČèÁü€ò„°„ì„€„脱ĄŒ„ë€Ë€č€ë" #: ../../menuinfo.c:394 msgid "Brighten/Darken..." msgstr "ÌÀ°Ć..." #: ../../menuinfo.c:394 msgid "Brighten or darken a selected image" msgstr "ÁȘÂò€·€żČèÁü€òÌÀ€ë€Ż/°Ć€Ż€č€ë" #: ../../menuinfo.c:396 msgid "Contrast Enhance..." msgstr "„ł„ó„È„é„č„ȶŻÄŽ..." #: ../../menuinfo.c:396 msgid "Adjust contrast of a selected image" msgstr "ÁȘÂò€·€żČèÁü€Î„ł„ó„È„é„č„ÈÄŽÀá" #: ../../menuinfo.c:398 msgid "Gamma Correct..." msgstr "„Ź„ó„ȚÊäÀ”..." #: ../../menuinfo.c:399 msgid "Apply gamma correction a selected image" msgstr "ÁȘÂò€·€żČèÁü€ÎgammaÊäÀ”" #: ../../menuinfo.c:401 msgid "Change Saturation..." msgstr "˰ÏÂĂÍ€ÎÊŃčč" #: ../../menuinfo.c:402 msgid "Change saturation of a selected image" msgstr "ÁȘÂò€·€żČèÁü€Î˰ÏÂĂÍ€òÊŃčč€č€ë" #: ../../menuinfo.c:404 msgid "Change Hue..." msgstr "ż§č瀀ÊŃčč..." #: ../../menuinfo.c:404 msgid "Change hue of a selected image" msgstr "ÁȘÂò€·€żČèÁü€Îż§č瀀€òÊŃčč€č€ë" #: ../../menuinfo.c:407 msgid "Invert Color" msgstr "ż§ÈżĆŸ" #: ../../menuinfo.c:408 msgid "Subtract every pixel of a selected image from White (in RGB-model)" msgstr "" #: ../../menuinfo.c:410 msgid "Interpolate Color..." msgstr "ż§ÊäŽÖ" #: ../../menuinfo.c:411 msgid "Map pixel intensities of a selected image between two specified colors" msgstr "" #: ../../menuinfo.c:413 msgid "Color Balance..." msgstr "ż§„Đ„é„ó„č" #: ../../menuinfo.c:414 msgid "Balance the RGB components of a selected image" msgstr "ÁȘÂòČèÁü€Î RGB ÀźÊŹ€Î„Đ„é„ó„č€òÄŽÀá€č€ë" #: ../../menuinfo.c:417 msgid "Reduce Number Of Colors" msgstr "žșż§" #: ../../menuinfo.c:418 msgid "Reduce number of colors submenu >>>" msgstr "žșż§€ËŽŰ€č€ë„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:419 msgid "Effects" msgstr "žúČÌ" #: ../../menuinfo.c:420 msgid "Effects submenu >>>" msgstr "žúČÌ€ËŽŰ€č€ë„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:421 msgid "Generate" msgstr "" #: ../../menuinfo.c:422 msgid "Generate submenu >>>" msgstr "" #: ../../menuinfo.c:424 msgid "Regenerate Image" msgstr "" #: ../../menuinfo.c:425 msgid "Regenerated a selected image" msgstr "" #: ../../menuinfo.c:426 msgid "Crop Image" msgstr "ČèÁüÀÚŒè€ê" #: ../../menuinfo.c:426 msgid "Crop a selected image" msgstr "ÁȘÂòČèÁü€ÎÀÚ€êŒè€ê" #: ../../menuinfo.c:428 msgid "Get Color" msgstr "ż§Œè€êčț€ß" #: ../../menuinfo.c:429 msgid "Pick a color from a selected image to be the current color" msgstr "ÁȘÂòČèÁü€«€éż§€òŒè€êčț€ßĄąžœș߀ÎÁȘÂòż§€Ë€č€ë" #: ../../menuinfo.c:431 msgid "Replace Color" msgstr "ż§ĂÖŽč" #: ../../menuinfo.c:432 msgid "Replace a color in a selected image with the current color" msgstr "ÁȘÂòČèÁü€Îż§€òžœș߀ÎÁȘÂòż§€ÈĂÖŽč€č€ë" #: ../../menuinfo.c:434 msgid "Flood Fill" msgstr "ĆÉ€ê€Ä€Ö€·" #: ../../menuinfo.c:435 msgid "Flood-filling a selected image with the current color" msgstr "ÁȘÂòż§€ÇÁȘÂòČèÁü€òĆÉ€ê€Ä€Ö€č" #: ../../menuinfo.c:437 msgid "Create Contour" msgstr "ÎŰłÔ" #: ../../menuinfo.c:438 msgid "Generate a contour from a point in a selected image" msgstr "ÁȘÂòČèÁüÆâ€ÎĆÀ€«€éÎŰłÔ€òșîÀź€č€ë" #: ../../menuinfo.c:441 msgid "Subtract" msgstr "°ú€­»»" #: ../../menuinfo.c:442 msgid "Subtract one image from another" msgstr "ČèÁü€«€éÊÌ€ÎČèÁü€Î°ú€­»»€ò€č€ë" #: ../../menuinfo.c:443 msgid "Alpha Combine" msgstr "" #: ../../menuinfo.c:444 msgid "Combine 2 images using another image as the alpha channel" msgstr "" #: ../../menuinfo.c:446 msgid "Xor Color" msgstr "XOR€Îż§" #: ../../menuinfo.c:446 msgid "XOR the colors of one image into another" msgstr "2€Ä€ÎČèÁü€ÎXORż§€òÆÀ€ë" #: ../../menuinfo.c:449 msgid "Vector Warp" msgstr "" #: ../../menuinfo.c:450 msgid "Warp selected image in a specified direction for a specified amount" msgstr "" #: ../../menuinfo.c:458 msgid "Solve" msgstr "" #: ../../menuinfo.c:458 ../../menuinfo.c:459 ../../menuinfo.c:460 #: ../../menuinfo.c:461 ../../menuinfo.c:462 msgid "Escape to driver" msgstr "" #: ../../menuinfo.c:459 msgid "Simulate" msgstr "" #: ../../menuinfo.c:460 msgid "Probe" msgstr "" #: ../../menuinfo.c:461 msgid "Animate" msgstr "" #: ../../menuinfo.c:462 msgid "Escape" msgstr "" #: ../../menuinfo.c:469 msgid "Create Thumbnails" msgstr "" #: ../../menuinfo.c:470 msgid "Create a thumbnail map of all object files" msgstr "" #: ../../menuinfo.c:473 msgid "Browse X Bitmap" msgstr "XBitmap°ìÍśÉœŒš" #: ../../menuinfo.c:474 msgid "Recursively read in all X11 bitmap files" msgstr "ÁŽ€Æ€Î X11 bitmap „Ő„Ą„€„ë€òșÆ”ąĆȘ€ËÆÉ€ßčț€à" #: ../../menuinfo.c:476 msgid "Browse X Pixmap" msgstr "XPixmap°ìÍśÉœŒš" #: ../../menuinfo.c:477 msgid "Recursively read in all X11 pixmap files" msgstr "ÁŽ€Æ€Î X11 pixmap „Ő„Ą„€„ë€òșÆ”ąĆȘ€ËÆÉ€ßčț€à" #: ../../menuinfo.c:479 msgid "Browse Other..." msgstr "€œ€ÎŸ€ò°ìÍśÉœŒš..." #: ../../menuinfo.c:480 msgid "Recursively read in all another type of files" msgstr "€œ€ÎŸÁŽ€ÆŒïÎà€Î„Ő„Ą„€„ë€òșÆ”ąĆȘ€ËÆÉ€ßčț€à" #: ../../menuinfo.c:488 ../../menuinfo.c:548 #, fuzzy msgid "Import Multipage Text File" msgstr "€œ€ÎŸ€Î„Ő„Ą„€„ëÁȚÆț..." #: ../../menuinfo.c:488 msgid "Import a multipage text file" msgstr "" #: ../../menuinfo.c:490 msgid "Set Margins" msgstr "„ȚĄŒ„ž„óÀßÄê" #: ../../menuinfo.c:491 msgid "Set margins for importing multipage text files" msgstr "" #: ../../menuinfo.c:493 msgid "Word Wrap" msgstr "" #: ../../menuinfo.c:494 msgid "Turn word wrapping on and off for importing multipage text files" msgstr "" #: ../../menuinfo.c:503 ../../menuinfo.c:554 msgid "Screen Capture" msgstr "ČèÌÌŒè€êčț€ß" #: ../../menuinfo.c:504 msgid "Capture a rectangular area of the screen" msgstr "„脯„êĄŒ„ó€Î¶ë·Á„š„ê„ą€ò„­„ㄌ„Á„ă€č€ë" #: ../../menuinfo.c:506 msgid "Full Screen Capture" msgstr "ČèÌÌÁŽÂ΀Όè€êčț€ß" #: ../../menuinfo.c:506 msgid "Capture the whole screen" msgstr "„脯„êĄŒ„óÁŽÂ΀ò„­„ㄌ„Á„ă€č€ë" #: ../../menuinfo.c:508 msgid "Delayed Full Screen Capture..." msgstr "ŸŻ€·ÂԀÀÆČèÌÌÁŽÂ΀Όè€êčț€ß" #: ../../menuinfo.c:509 msgid "Capture the whole screen after a specified delay" msgstr "»ŰÄê»țŽÖžć€Ë„脯„êĄŒ„óÁŽÂ΀ò„­„ㄌ„Á„ă€č€ë" #: ../../menuinfo.c:512 msgid "Hide During Capture" msgstr "„­„ㄌ„Á„ă€ÎŽÖtgif€ò±Ł€č" #: ../../menuinfo.c:513 msgid "Toggle between hiding and showing tgif during capture" msgstr "ČèÌÌŒè€êčț€ß€ÎŽÖ, tgif €òÉœŒš€č€ë/ÉœŒš€·€Ê€€" #: ../../menuinfo.c:521 msgid "Import..." msgstr "„Ő„Ą„€„ëÁȚÆț..." #: ../../menuinfo.c:521 msgid "Embed/Import another drawing" msgstr "ÊÌ€Îłš€ÎËä€áčț€ß/ÁȚÆț" #: ../../menuinfo.c:523 msgid "Import X Bitmap..." msgstr "Xbitmap ÁȚÆț..." #: ../../menuinfo.c:524 msgid "Embed/Import an X11 bitmap file" msgstr "X11 bitmap „Ő„Ą„€„ë€ÎËä€áčț€ß/ÁȚÆț" #: ../../menuinfo.c:525 msgid "Import X Pixmap..." msgstr "XPixmapÁȚÆț..." #: ../../menuinfo.c:526 msgid "Embed/Import an X11 pixmap file" msgstr "X11 pixmap „Ő„Ą„€„ë€ÎËä€áčț€ß/ÁȚÆț" #: ../../menuinfo.c:527 msgid "Import EPS File..." msgstr "EPS„Ő„Ą„€„ëÁȚÆț..." #: ../../menuinfo.c:527 msgid "Link to a PS/EPS file" msgstr "PS/EPS„Ő„Ą„€„ë€Ű€Î„ê„ó„Ż" #: ../../menuinfo.c:529 msgid "Import GIF File..." msgstr "GIF„Ő„Ą„€„ëÁȚÆț..." #: ../../menuinfo.c:529 msgid "Embed/Import a GIF file" msgstr "GIF „Ő„Ą„€„ë€ÎËä€áčț€ß/ÁȚÆț" #: ../../menuinfo.c:531 msgid "Import PNG File..." msgstr "PNG„Ő„Ą„€„ëÁȚÆț..." #: ../../menuinfo.c:531 msgid "Embed/Import a PNG file" msgstr "PNG „Ő„Ą„€„ë€ÎËä€áčț€ß/ÁȚÆț" #: ../../menuinfo.c:533 msgid "Import JPEG File..." msgstr "JPEG„Ő„Ą„€„ëÁȚÆț..." #: ../../menuinfo.c:533 msgid "Embed/Import a JPEG file" msgstr "JPEG„Ő„Ą„€„ë€ÎËä€áčț€ß/ÁȚÆț" #: ../../menuinfo.c:535 msgid "Import Other File..." msgstr "€œ€ÎŸ€Î„Ő„Ą„€„ëÁȚÆț..." #: ../../menuinfo.c:535 msgid "Embed/Import another type of file" msgstr "€œ€ÎŸ€Î„Ő„Ą„€„ë€ÎËä€áčț€ß/ÁȚÆț" #: ../../menuinfo.c:538 msgid "Embed EPS File..." msgstr "EPS„Ő„Ą„€„ë€ÎËä€áčț€ß..." #: ../../menuinfo.c:538 msgid "Embed/Import a PS/EPS file" msgstr "PS/EPS„Ő„Ą„€„ëËä€áčț€ß/ÁȚÆț" #: ../../menuinfo.c:541 msgid "Auto EPS Preview Bitmap" msgstr "" #: ../../menuinfo.c:542 msgid "" "Auto-generate a preview bitmap for a PS/EPS file when embedding/importing it " "(if it does not have one already)." msgstr "" #: ../../menuinfo.c:545 ../../menuinfo.c:898 msgid "Paste From File..." msgstr "„Ő„Ą„€„뀫€é„ÚĄŒ„č„È..." #: ../../menuinfo.c:546 ../../menuinfo.c:899 msgid "Select a file and paste the content as text" msgstr "„Ő„Ą„€„ë€òÁȘÂò€·Ąą€œ€ÎÆâÍÆ€ò„Æ„­„č„ȀȀ·€Æ„ÚĄŒ„č„È" #: ../../menuinfo.c:549 #, fuzzy msgid "Import Multipage Text File submenu >>>" msgstr "Êž»ú„”„€„șĄŠ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:552 msgid "Browse" msgstr "°ìÍśÉœŒš" #: ../../menuinfo.c:553 msgid "Browse submenu >>>" msgstr "°ìÍśÉœŒš€Î„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:555 msgid "Screen Capture submenu >>>" msgstr "„脯„êĄŒ„óĄŠ„­„ㄌ„Á„ă€Î„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:562 msgid "Change Domain..." msgstr "„Ʉᄀ„ó°Üư" #: ../../menuinfo.c:562 msgid "Change to a different domain" msgstr "Ÿ€Î„Ʉᄀ„ó€ËÊŃčč" #: ../../menuinfo.c:565 msgid "Edit Domain Paths..." msgstr "„Ʉᄀ„ó„Ń„č€ÎÊÔœž" #: ../../menuinfo.c:565 msgid "Edit domain paths" msgstr "„Ʉᄀ„ó„Ń„č€ÎÊÔœž" #: ../../menuinfo.c:567 msgid "Select Default Domain..." msgstr "„DŽՄ©„ë„ȄɄᄀ„ó€ÎÁȘÂò..." #: ../../menuinfo.c:567 msgid "Select the default domain" msgstr "„DŽՄ©„ë„ȄɄᄀ„ó€ÎÁȘÂò" #: ../../menuinfo.c:569 msgid "Add A Domain..." msgstr "„Ʉᄀ„ó€ÎÄÉČĂ" #: ../../menuinfo.c:569 msgid "Add a new domain" msgstr "ż·€·€€„Ʉᄀ„ó€ÎÄÉČĂ" #: ../../menuinfo.c:571 msgid "Delete A Domain..." msgstr "„Ʉᄀ„ó€Îșïœü..." #: ../../menuinfo.c:571 msgid "Delete an existing domain" msgstr "„Ʉᄀ„ó€Îșïœü..." #: ../../menuinfo.c:574 msgid "Reload Domain Info From X..." msgstr "X €«€é„Ʉᄀ„óŸđÊó€ÎșÆÆÉ€ßčț€ß..." #: ../../menuinfo.c:575 msgid "Reload domain information from X defaults" msgstr "X defaults €«€é„Ʉᄀ„óŸđÊó€ÎșÆÆÉ€ßčț€ß" #: ../../menuinfo.c:586 msgid "Export X Pixmap Deck To GIF" msgstr "X Pixmap„DŽÄ­€òGIF€ŰœĐÎÏ" #: ../../menuinfo.c:587 msgid "Export a deck of X11 pixmap images to an animated GIF file" msgstr "X11 PixmapČèÁü€Î„DŽÄ­€ò„ą„Ë„áĄŒ„·„ç„óGIF„Ő„Ą„€„ë€ŰœĐÎÏ€č€ë" #: ../../menuinfo.c:589 msgid "Import GIF To X Pixmap Deck..." msgstr "X Pixmap„DŽÄ­€ŰGIFČèÁü€òŒè€êčț€ß..." #: ../../menuinfo.c:590 msgid "Import an animated GIF file into a deck of X11 pixmap images" msgstr "„ą„Ë„áĄŒ„·„ç„óGIF„Ő„Ą„€„ë€òX11 PixmapČèÁü€Î„DŽÄ­€ËŒè€êčț€à" #: ../../menuinfo.c:601 msgid "Fake User Agent..." msgstr "" #: ../../menuinfo.c:602 msgid "Set 'UserAgent' to be used when making an HTTP request" msgstr "HTTP „ê„Ż„š„č„È€ÎșÆ€Ë»È€Š„æĄŒ„¶ÌŸÀßÄê" #: ../../menuinfo.c:604 msgid "Fake Referer..." msgstr "" #: ../../menuinfo.c:605 msgid "Set 'Referer' to be used when making an HTTP request" msgstr "" #: ../../menuinfo.c:607 msgid "Toggle Keep Alive" msgstr "" #: ../../menuinfo.c:608 msgid "Toggle between using Keep-Alive and non-Keep-Alive HTTP connections" msgstr "" #: ../../menuinfo.c:617 msgid "New" msgstr "ż·€·€€„Ő„Ą„€„ë" #: ../../menuinfo.c:617 msgid "Start with a blank/new drawing" msgstr "Çò»æ€Îż·€·€€łš€òł«€Ż" #: ../../menuinfo.c:619 msgid "Open..." msgstr "„Ő„Ą„€„ë€òł«€Ż..." #: ../../menuinfo.c:619 msgid "Open an existing drawing" msgstr "Žûž€Îłš€òł«€Ż" #: ../../menuinfo.c:621 msgid "Import" msgstr "„Ő„Ą„€„ëÁȚÆț" #. CSTID_SAVE #: ../../menuinfo.c:624 ../../strtbl.c:120 msgid "Save" msgstr "ÊĘž" #: ../../menuinfo.c:624 msgid "Save current drawing" msgstr "žœș߀γš€òÊĘž" #: ../../menuinfo.c:625 msgid "Save New..." msgstr "ÌŸÁ°€òÉŐ€±€ÆÊĘž..." #: ../../menuinfo.c:626 msgid "Save current drawing in a different file" msgstr "žœș߀γš€ò°ă€Š„Ő„Ą„€„ë€ËÊĘž€č€ë" #: ../../menuinfo.c:627 msgid "Save Selected As..." msgstr "ÁȘÂòÂĐŸĘ€òÊÌĄč€ËÊĘž" #: ../../menuinfo.c:628 msgid "Save selected objects in a different file" msgstr "ÁȘÂò€·€żÂĐŸĘ€ò°ă€Š„Ő„Ą„€„ë€ËÊĘž€č€ë" #: ../../menuinfo.c:631 msgid "Print" msgstr "°őșț" #: ../../menuinfo.c:631 msgid "Print/export current drawing" msgstr "žœș߀γš€ò°őșț/œĐÎÏ€č€ë" #: ../../menuinfo.c:633 ../../menuinfo.c:1214 msgid "Print/Export Format" msgstr "°őșț/œĐÎÏ„Ő„©ĄŒ„Ț„Ă„È" #: ../../menuinfo.c:634 ../../menuinfo.c:1215 msgid "Select print/export format submenu >>>" msgstr "°őșț/œĐÎÏ„Ő„©ĄŒ„Ț„Ă„È€ÎÁȘÂò„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:636 msgid "Set HTML Export Template..." msgstr "HTML„Æ„ó„Ś„ìĄŒ„ÈÆÉčț€ß" #: ../../menuinfo.c:637 msgid "Specify a file to be used as a template for genearting HTML files" msgstr "HTML„Ő„Ą„€„ë€òșîÀź€č€ë»ț€Î„Æ„ó„Ś„ìĄŒ„ÈĄŠ„Ő„Ą„€„ëÆÉčț€ß" #: ../../menuinfo.c:639 ../../menuinfo.c:1217 msgid "Print/Export In Color" msgstr "„«„éĄŒ€Ç°őșț/œĐÎÏ" #: ../../menuinfo.c:640 ../../menuinfo.c:1218 msgid "Toggle between color and black & white printing modes" msgstr "„«„éĄŒ€ÈÇòčő°őșț€ÎÀÚÂŰ€š" #: ../../menuinfo.c:642 msgid "Print With Cmd..." msgstr "„ł„Ț„ó„É»ŰÄê€Ë€è€ë°őșț" #: ../../menuinfo.c:643 msgid "Print/export current drawing with a specific command" msgstr "»ŰÄꀷ€ż„ł„Ț„ó„É€òÍŃ€€€Æžœș߀γš€ò°őșț/œĐÎÏ" #: ../../menuinfo.c:645 msgid "Print Selected Objects" msgstr "ÁȘÂòÂĐŸĘ€Î°őșț" #: ../../menuinfo.c:646 msgid "Print/export only selected objects" msgstr "ÁȘÂò€·€żÂĐŸĘ€Î€ß€ò°őșț/œĐÎÏ€č€ë" #: ../../menuinfo.c:647 msgid "Print a page in a multipage drawing" msgstr "" #: ../../menuinfo.c:655 msgid "GIF Animation" msgstr "GIF„ą„Ë„áĄŒ„·„ç„ó" #: ../../menuinfo.c:656 msgid "GIFAnimation submenu >>>" msgstr "GIF„ą„Ë„áĄŒ„·„ç„ó€Î„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:658 msgid "Mime" msgstr "" #: ../../menuinfo.c:658 msgid "Mime submenu >>>" msgstr "Mime „”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:662 msgid "Print Msg Buffer..." msgstr "„á„Ă„»ĄŒ„ž„ЄÄՄĄ€ÎœĐÎÏ" #: ../../menuinfo.c:663 msgid "Display/save the contents of the message window" msgstr "„á„Ă„»ĄŒ„žĄŠ„Єلó„ɄЀÎĂæżÈ€ò°őșț/ÊĘž" #: ../../menuinfo.c:666 msgid "Set Export Pixel Trim..." msgstr "œĐÎÏ„Ô„Ż„»„ëÈŽ€­Œè€êÀßÄê..." #: ../../menuinfo.c:667 msgid "Specify the number of pixels to trim when exporting" msgstr "œĐÎÏ»ț€ÎÈŽ€­Œè€ë(„È„ê„à€č€ë)„Ô„Ż„»„ëżô€ò»ŰÄê€č€ë" #: ../../menuinfo.c:669 msgid "Set Template..." msgstr "„Æ„ó„Ś„ìĄŒ„ÈÀßÄê..." #: ../../menuinfo.c:670 msgid "Select a template file be used in STACKED page mode" msgstr "" #: ../../menuinfo.c:673 msgid "Recent Files" msgstr "șǶá»ÈÍŃ€·€ż„Ő„Ą„€„ë" #: ../../menuinfo.c:674 msgid "Recently used files submenu >>>" msgstr "șǶá»È€Ă€ż„Ő„Ą„€„ë€Î„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:676 msgid "Quit" msgstr "œȘλ" #: ../../menuinfo.c:676 msgid "Exit <<PROGRAM_NAME>>" msgstr "" #: ../../menuinfo.c:682 msgid "Precise Scale..." msgstr "À”łÎ€ËłÈÂçœÌŸź..." #: ../../menuinfo.c:682 msgid "Scale selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎłÈÂçœÌŸź" #: ../../menuinfo.c:684 msgid "Scale everything" msgstr "ÁŽ€Æ€òłÈÂçœÌŸź" #: ../../menuinfo.c:686 msgid "Precise Rotate..." msgstr "À”łÎ€ËČóĆŸ..." #: ../../menuinfo.c:687 msgid "Rotate selected objects by a specified number of degrees" msgstr "ÁȘÂò€·€żÂĐŸĘ€ò»ŰÄꀷ€żłŃĆÙ€À€±ČóĆŸ" #: ../../menuinfo.c:690 msgid "Restore Image Width & Height" msgstr "ČèÁü€ÎÉę€Èč—€òÌá€č" #: ../../menuinfo.c:691 msgid "Restore a seleted bitmap/pixmap/EPS object to its original dimension" msgstr "" #: ../../menuinfo.c:693 msgid "No Transform" msgstr "łÆŒïÊŃŽč" #: ../../menuinfo.c:694 msgid "Get rid of transformations on selected simple objects" msgstr "" #: ../../menuinfo.c:702 msgid "Invert X Bitmap" msgstr "XBitmapÈżĆŸ" #: ../../menuinfo.c:703 msgid "Invert pixels for selected bitmap objects" msgstr "" #: ../../menuinfo.c:705 msgid "Cut Bit/Pixmap..." msgstr "Bit/Pixmap șïœü..." #: ../../menuinfo.c:706 msgid "Trim/scale a selected bitmap/pixmap object" msgstr "" #: ../../menuinfo.c:708 msgid "Break Up Bit/Pixmap..." msgstr "" #: ../../menuinfo.c:709 msgid "Break selected bitmap/pixmap object into smaller objects" msgstr "" #: ../../menuinfo.c:712 msgid "Export Half Tone Bitmap" msgstr "" #: ../../menuinfo.c:713 msgid "Use Floyd-Steinberg half-tone method when exporting an X11 bitmap file" msgstr "" #: ../../menuinfo.c:715 msgid "Export Threshold Bitmap" msgstr "" #: ../../menuinfo.c:716 msgid "Use simple thresholding method when exporting an X11 bitmap file" msgstr "" #: ../../menuinfo.c:719 msgid "Set Export Bitmap Threshold..." msgstr "" #: ../../menuinfo.c:720 msgid "Set bitmap threshold value for the simple thresholding method" msgstr "" #: ../../menuinfo.c:723 msgid "Update EPS" msgstr "EPS€Îččż·" #: ../../menuinfo.c:723 msgid "Refresh a selected EPS object" msgstr "ÁȘÂò€·€ż EPS „Ș„Ö„ž„§„Ż„È€òșÆÉÁČè" #: ../../menuinfo.c:731 #, fuzzy msgid "Set Tick Mark Size..." msgstr "ÍŃ»æ„”„€„șÀßÄê..." #: ../../menuinfo.c:732 msgid "Set the size of tick marks for various commands" msgstr "" #: ../../menuinfo.c:735 msgid "Add Squares" msgstr "»ÍłŃ·Á€òÄÉČĂ..." #: ../../menuinfo.c:736 #, fuzzy msgid "Add square tick marks at vertices of selected polys/polygons/splines" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òÄÉČĂ€č€ë" #: ../../menuinfo.c:738 #, fuzzy msgid "Add Triangles" msgstr "»ÍłŃ·ÁÉÁČè" #: ../../menuinfo.c:739 #, fuzzy msgid "Add triangle tick marks at vertices of selected polys/polygons/splines" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òÄÉČĂ€č€ë" #: ../../menuinfo.c:741 msgid "Add Circles" msgstr "" #: ../../menuinfo.c:742 #, fuzzy msgid "Add circle tick marks at vertices of selected polys/polygons/splines" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òÄÉČĂ€č€ë" #: ../../menuinfo.c:744 msgid "Add Xs" msgstr "" #: ../../menuinfo.c:745 #, fuzzy msgid "Add X tick marks at vertices of selected polys/polygons/splines" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òÄÉČĂ€č€ë" #: ../../menuinfo.c:747 msgid "Add Diamonds" msgstr "" #: ../../menuinfo.c:748 #, fuzzy msgid "Add diamond tick marks at vertices of selected polys/polygons/splines" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òÄÉČĂ€č€ë" #: ../../menuinfo.c:750 #, fuzzy msgid "Add Bowties" msgstr "„Ę„€„ó„ÈÄÉČĂ" #: ../../menuinfo.c:751 #, fuzzy msgid "Add bowtie tick marks at vertices of selected polys/polygons/splines" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òÄÉČĂ€č€ë" #: ../../menuinfo.c:753 msgid "Add Inverted Triangles" msgstr "" #: ../../menuinfo.c:754 msgid "" "Add inverted triangle tick marks at vertices of selected polys/polygons/" "splines" msgstr "" #: ../../menuinfo.c:756 msgid "Add Plus" msgstr "" #: ../../menuinfo.c:757 #, fuzzy msgid "Add plus tick marks at vertices of selected polys/polygons/splines" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òÄÉČĂ€č€ë" #: ../../menuinfo.c:759 msgid "Add Hour Glasss" msgstr "" #: ../../menuinfo.c:760 #, fuzzy msgid "" "Add hour glass tick marks at vertices of selected polys/polygons/splines" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òÄÉČĂ€č€ë" #: ../../menuinfo.c:769 msgid "Delete Point" msgstr "„Ę„€„ó„Èșïœü" #: ../../menuinfo.c:770 msgid "Delete vertices from a poly/polygon/spline" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òșïœü€č€ë" #: ../../menuinfo.c:772 msgid "Add Point" msgstr "„Ę„€„ó„ÈÄÉČĂ" #: ../../menuinfo.c:773 msgid "Add vertices to a polygon/polygon/spline" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òÄÉČĂ€č€ë" #: ../../menuinfo.c:775 msgid "Convert Interpolated Spline" msgstr "" #: ../../menuinfo.c:776 msgid "Convert selected interpolated splines to regular splines" msgstr "" #: ../../menuinfo.c:778 msgid "Smooth<->Hinge" msgstr "¶ÊÀț<->ÀȚ€ìÀț" #: ../../menuinfo.c:779 msgid "Toggle smooth/hinge vertices for a selected poly/polygon/spline" msgstr "" #: ../../menuinfo.c:782 msgid "Convert To Bezier Curve" msgstr "„Ù„ž„š¶ÊÀț€Ë€č€ë" #: ../../menuinfo.c:783 msgid "Convert selected splines to Bezier curves" msgstr "ÁȘÂò€·€ż„脌„é„€„ó€ò„Ù„ž„š¶ÊÀț€Ë€č€ë" #: ../../menuinfo.c:785 #, fuzzy msgid "Set Segments For Convert To Bezier..." msgstr "ÁȘÂò€·€żÊž»ú€Î„”„€„șÊŃčč..." #: ../../menuinfo.c:786 msgid "Set the number of segments for the convert to Bezier command" msgstr "" #: ../../menuinfo.c:789 msgid "Join Poly" msgstr "„Ę„ê„Ž„ó·ëčç" #: ../../menuinfo.c:789 msgid "Join polylines or open-splines at endpoints" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á€òĄąĂŒĆÀ€Ç€Ä€Ê€Č€ë" #: ../../menuinfo.c:791 msgid "Cut Poly" msgstr "„Ę„ê„Ž„ó€òÀÚ€ë" #: ../../menuinfo.c:791 msgid "Cut a poly/polygon at a vertex into two pieces" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á€òĄąÄșĆÀ€Î€È€ł€í€Ç2€Ä€ËÊŹ€±€ë" #: ../../menuinfo.c:794 msgid "Make Regular Polygon..." msgstr "" #: ../../menuinfo.c:795 msgid "Make a selected polygon/closed spline into a regular one" msgstr "" #: ../../menuinfo.c:798 ../../menuinfo.c:859 msgid "Add Tick Marks" msgstr "" #: ../../menuinfo.c:799 ../../menuinfo.c:860 #, fuzzy msgid "Add Tick Marks submenu >>>" msgstr "€œ€ÎŸ€ÎÀßÄê„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:806 msgid "Break Up Text" msgstr "„Æ„­„č„È€òÊŹłä" #: ../../menuinfo.c:807 msgid "Break up selected text objects into one-character text objects" msgstr "ÁȘÂò€·€ż„Æ„­„č„È€òĄą°ìÊž»ú€ș€Ä€Î„Æ„­„č„ÈĄŠ„Ș„Ö„ž„§„Ż„È€ËÊŹČò" #: ../../menuinfo.c:809 msgid "Set Text Fill Pattern Color" msgstr "„Æ„­„č„È€ÎĆÉ€ê€Ä€Ö€·ż§ÀßÄê" #: ../../menuinfo.c:810 msgid "Set the fill pattern color of a text object to be the current color" msgstr "„Æ„­„č„È€ÎĆÉ€ê€Ä€Ö€·ż§€òÁȘÂòż§€ËÀßÄê" #: ../../menuinfo.c:813 msgid "Insert Right Superscript" msgstr "±ŠŸćÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:814 msgid "Insert superscript to the right of the text cursor" msgstr "„Æ„­„č„È„«ĄŒ„œ„ë€Î±Š€ËŸćÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:816 msgid "Insert Right Subscript" msgstr "±ŠČŒÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:817 msgid "Insert subscript to the right of the text cursor" msgstr "„Æ„­„č„È„«ĄŒ„œ„ë€Î±Š€ËČŒÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:819 msgid "Insert Left Superscript" msgstr "șžŸćÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:820 msgid "Insert superscript to the left of the text cursor" msgstr "„Æ„­„č„È„«ĄŒ„œ„ë€Îșž€ËŸćÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:822 msgid "Insert Left Subscript" msgstr "șžČŒÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:823 msgid "Insert subscript to the left of the text cursor" msgstr "„Æ„­„č„È„«ĄŒ„œ„ë€Îșž€ËČŒÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:825 msgid "Insert Center Superscript" msgstr "Ăæ±ûŸćÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:826 msgid "Insert superscript above the text cursor" msgstr "„Æ„­„č„È„«ĄŒ„œ„ë€ÎŸć€ËŸćÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:828 msgid "Insert Center Subscript" msgstr "Ăæ±ûČŒÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:829 msgid "Insert subscript below the text cursor" msgstr "„Æ„­„č„È„«ĄŒ„œ„ë€ÎČŒ€ËŸćÉŐ€­Êž»úÁȚÆț" #: ../../menuinfo.c:832 msgid "Insert Thin Space..." msgstr "Ÿź€”€Ê„č„ÚĄŒ„čÁȚÆț..." #: ../../menuinfo.c:833 msgid "Insert a think space at the text cursor" msgstr "„Æ„­„č„È„«ĄŒ„œ„ë€Î°ÌĂÖ€ËŸź€”€Ê„č„ÚĄŒ„čÁȚÆț" #: ../../menuinfo.c:836 msgid "Insert Vertical Offset..." msgstr "" #: ../../menuinfo.c:837 msgid "Insert a vertical offset at the text cursor" msgstr "" #: ../../menuinfo.c:839 msgid "Remove Vertical Offset..." msgstr "" #: ../../menuinfo.c:840 msgid "Remove any vertical offset at the text cursor" msgstr "" #: ../../menuinfo.c:843 #, fuzzy msgid "Set Script Fraction..." msgstr "Êž»ú€ÎČóĆŸłŃ€òÀßÄê" #: ../../menuinfo.c:844 msgid "Set the relative size of super/subscript text" msgstr "" #: ../../menuinfo.c:852 msgid "Input Poly Pts" msgstr "" #: ../../menuinfo.c:853 msgid "Read points from terminal and create a poly" msgstr "" #: ../../menuinfo.c:855 msgid "Input Polygon Pts" msgstr "" #: ../../menuinfo.c:856 msgid "Read points from terminal and create a polygon" msgstr "" #: ../../menuinfo.c:862 msgid "Specify An Arc..." msgstr "±ßžÌ€ò»ŰÄê..." #: ../../menuinfo.c:862 msgid "Create and specify an arc" msgstr "" #: ../../menuinfo.c:864 msgid "Get Bounding Box" msgstr "„Đ„Š„ó„Ç„Ł„ó„°ĄŠ„Ü„Ă„Ż„čŒèÆÀ" #: ../../menuinfo.c:865 msgid "Get rectangular bounding boxes of selected objects" msgstr "ÁȘÂòÂĐŸĘ€Î„Đ„Š„ó„Ç„Ł„ó„°ĄŠ„Ü„Ă„Ż„č€òŒèÆÀ€č€ë" #: ../../menuinfo.c:874 msgid "Redraw" msgstr "șÆÉÁČè" #: ../../menuinfo.c:874 msgid "Redraw canvas window" msgstr "„Єلó„ɄЀòșÆÉÁČè€č€ë" #: ../../menuinfo.c:875 ../../menuinfo.c:1551 ../../menuinfo.c:1586 msgid "Duplicate" msgstr "ÊŁÀœ" #: ../../menuinfo.c:875 ../../menuinfo.c:1551 ../../menuinfo.c:1586 msgid "Duplicate selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎÊŁÀœ€ò€Ä€Ż€ë" #. CSTID_DELETE #: ../../menuinfo.c:877 ../../menuinfo.c:1553 ../../menuinfo.c:1588 #: ../../strtbl.c:238 msgid "Delete" msgstr "șïœü" #: ../../menuinfo.c:877 ../../menuinfo.c:1553 ../../menuinfo.c:1588 msgid "Delete selected objects" msgstr "ÁȘÂòÂĐŸĘ€Îșïœü" #: ../../menuinfo.c:879 msgid "Select All" msgstr "ÁŽ€ÆÁȘÂò" #: ../../menuinfo.c:879 msgid "Select all objects on the current page" msgstr "žœș߀΄ڥŒ„ž€ÎÁŽ€Æ€Î„Ș„Ö„ž„§„Ż„È€òÁȘÂò" #: ../../menuinfo.c:882 msgid "Undo" msgstr "ŒÂčÔŒèŸĂ" #: ../../menuinfo.c:882 msgid "Undo the most recent command" msgstr "șÇžć€Î„ł„Ț„ó„ɀΌÂčÔŒèŸĂ" #: ../../menuinfo.c:884 msgid "Redo" msgstr "șÆŒÂčÔ" #: ../../menuinfo.c:884 msgid "Redo the most undone command" msgstr "șÇžć€ËŒÂčÔ€·€ż Undo „ł„Ț„ó„ɀΌèŸĂ" #: ../../menuinfo.c:886 msgid "Flush Undo Buffer" msgstr "„ł„Ț„ó„ÉÍúÎò€òŸĂ”î" #: ../../menuinfo.c:886 msgid "Flush undo buffer and unused colors" msgstr "ŒÂčÔŒèŸĂ€Î„ł„Ț„ó„ÉÍúÎò€òŸĂ”î" #. CSTID_COPY #: ../../menuinfo.c:889 ../../menuinfo.c:1549 ../../menuinfo.c:1577 #: ../../strtbl.c:118 msgid "Copy" msgstr "„ł„ÔĄŒ" #: ../../menuinfo.c:889 ../../menuinfo.c:1549 ../../menuinfo.c:1577 msgid "Copy selected objects into the cut buffer" msgstr "ÁȘÂòÂĐŸĘ€ò„«„Ă„È„Đ„Ă„Ő„Ą€Ë„ł„ÔĄŒ€č€ë" #: ../../menuinfo.c:891 ../../menuinfo.c:1579 msgid "Copy Plain Text As Object" msgstr "„Æ„­„č„È€ò„Ș„Ö„ž„§„Ż„È€È€·€Æ„ł„ÔĄŒ" #: ../../menuinfo.c:892 ../../menuinfo.c:1580 msgid "Copy highlighted plain text as an object into the cut buffer" msgstr "„Ï„€„é„€„Ȁ΄Ƅ­„č„È€ò„«„Ă„È„Đ„Ă„Ő„Ą€Ë„ł„ÔĄŒ€č€ë" #: ../../menuinfo.c:894 ../../menuinfo.c:1582 msgid "Cut" msgstr "ÀÚ€êŒè€ê" #: ../../menuinfo.c:894 msgid "Cut selected objects into the cut buffer" msgstr "ÁȘÂòÂĐŸĘ€ò„«„Ă„È„Đ„Ă„Ő„Ą€Ë°Üư€č€ë" #. CSTID_PASTE #: ../../menuinfo.c:896 ../../menuinfo.c:1584 ../../strtbl.c:122 msgid "Paste" msgstr "„ÚĄŒ„č„È" #: ../../menuinfo.c:896 ../../menuinfo.c:1584 msgid "Paste from the cut buffer" msgstr "„«„Ă„È„Đ„Ă„Ő„Ą€«€é„ÚĄŒ„č„È" #: ../../menuinfo.c:902 ../../menuinfo.c:1679 ../../menuinfo.c:1767 msgid "Shape" msgstr "·Á" #: ../../menuinfo.c:903 msgid "Shape submenu >>>" msgstr "·Á€Î„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:904 msgid "Set Shape Shadow..." msgstr "·Á€Ë±Æ€òÉŐ€±€ë" #: ../../menuinfo.c:904 msgid "Specify the shadow for shapes" msgstr "·Á€Ë€Ä€±€ë±Æ€ÎÁȘÂò" #: ../../menuinfo.c:907 ../../menuinfo.c:1558 ../../menuinfo.c:1687 #: ../../menuinfo.c:1787 msgid "Image Proc" msgstr "ČèÁüœèÍę" #: ../../menuinfo.c:908 msgid "ImageProc submenu >>>" msgstr "ČèÁüœèÍę„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:909 ../../menuinfo.c:1556 ../../menuinfo.c:1594 #: ../../menuinfo.c:1641 ../../menuinfo.c:1721 ../../menuinfo.c:1749 msgid "Properties" msgstr "łÆŒïÀßÄê" #: ../../menuinfo.c:910 msgid "Properties submenu >>>" msgstr "°À­„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:912 msgid "Transformation" msgstr "łÆŒïÊŃŽč" #: ../../menuinfo.c:913 msgid "Transformation submenu >>>" msgstr "łÆŒïÊŃŽč„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:915 msgid "Bitmap/Pixmap/EPS" msgstr "" #: ../../menuinfo.c:916 msgid "Bitmap/Pixmap/EPS submenu >>>" msgstr "Bitmap/Pixmap/EPS „”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:917 msgid "Poly/Polygon" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á" #: ../../menuinfo.c:918 msgid "Poly/Polygon submenu >>>" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á€Î„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:919 msgid "Text" msgstr "„Æ„­„č„È" #: ../../menuinfo.c:919 msgid "Text submenu >>>" msgstr "„Æ„­„č„ÈŽŰÏą€Î„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:921 msgid "Create Object" msgstr "„Ș„Ö„ž„§„Ż„ÈșîÀź" #: ../../menuinfo.c:922 msgid "Create object submenu >>>" msgstr "„Ș„Ö„ž„§„Ż„ÈșîÀź„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:924 msgid "Push Current Choice" msgstr "žœș߀ÎÁȘÂò€ò„Ś„Ă„·„ć" #: ../../menuinfo.c:925 msgid "Save/restore current drawing mode" msgstr "" #: ../../menuinfo.c:927 msgid "Find Case Sensitive..." msgstr "Êž»úžĄșś(ÂçÊž»ú€ÈŸźÊž»ú€ò¶èÊÌ)" #: ../../menuinfo.c:928 msgid "Find string in visible text objects (case sensitive)" msgstr "„Æ„­„č„ÈĄŠ„Ș„Ö„ž„§„Ż„È€«€éÊž»úžĄșś(ÂçÊž»ú€ÈŸźÊž»ú€ò¶èÊÌ)" #: ../../menuinfo.c:930 msgid "Find No Case..." msgstr "Êž»úžĄșś(ÂçÊž»ú€ÈŸźÊž»ú€òƱ°ì»ë)" #: ../../menuinfo.c:931 msgid "Find string in visible text objects (case insensitive)" msgstr "„Æ„­„č„ÈĄŠ„Ș„Ö„ž„§„Ż„È€«€éÊž»úžĄșś(ÂçÊž»ú€ÈŸźÊž»ú€òƱ°ì»ë)" #: ../../menuinfo.c:933 msgid "Find Again" msgstr "șÆžĄșś" #: ../../menuinfo.c:933 msgid "Repeat the last Find command" msgstr "șÇžć€ËŒÂčÔ€·€żžĄșś€ÎșÆŒÂčÔ" #: ../../menuinfo.c:944 msgid "Align Objects Top" msgstr "ŸćÉô€Îč—€ò€œ€í€š€ë" #: ../../menuinfo.c:945 msgid "Align top sides of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎŸćÉô€ò€œ€í€š€ë" #: ../../menuinfo.c:946 msgid "Align Objects Middle" msgstr "ĂæżŽ€Îč—€ò€œ€í€š€ë" #: ../../menuinfo.c:947 ../../strtbl.c:3434 msgid "Align vertical centers of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎĂæżŽ€òżâÄŸ€Ë€œ€í€š€ë" #: ../../menuinfo.c:949 msgid "Align Objects Bottom" msgstr "ÄìÉô€Îč—€ò€œ€í€š€ë" #: ../../menuinfo.c:950 msgid "Align bottom sides of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎÄìÉô€ò€œ€í€š€ë" #: ../../menuinfo.c:952 msgid "Align Objects Left" msgstr "șžĂŒ€ò€œ€í€š€ë" #: ../../menuinfo.c:953 msgid "Align left sides of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎșžĂŒ€ò€œ€í€š€ë" #: ../../menuinfo.c:954 msgid "Align Objects Center" msgstr "ĂæżŽ€ò€œ€í€š€ë" #: ../../menuinfo.c:955 ../../strtbl.c:3440 msgid "Align horizontal centers of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎĂæżŽ€òżćÊż€Ë€œ€í€š€ë" #: ../../menuinfo.c:957 msgid "Align Objects Right" msgstr "±ŠĂŒ€ò€œ€í€š€ë" #: ../../menuinfo.c:958 msgid "Align right sides of selected objects" msgstr "ÁȘÂòÂĐŸĘ€Î±ŠĂŒ€ò€œ€í€š€ë" #: ../../menuinfo.c:960 msgid "Center An End Point" msgstr "ĂŒĆÀ€òÂżłŃ·Á€ÎĂæżŽ€Ű" #: ../../menuinfo.c:961 msgid "Move an endpoint of a selected poly to the center of another object" msgstr "ÁȘÂò€·€żÂżłŃ·Á€ÎĂŒĆÀ€òÊÌ€ÎÂżłŃ·Á€ÎĂæżŽ€Ű°Üư€č€ë" #: ../../menuinfo.c:969 msgid "Size To Widest" msgstr "Éę€ÎÂ瀭€€Êę€Ë€œ€í€š€ë" #: ../../menuinfo.c:970 msgid "Resize all selected objects to be as wide as the widest one" msgstr "ÁȘÂò€·€żÁŽ€Æ€Î„Ș„Ö„ž„§„Ż„È€ÎÉę€òĄą°ìÈÖÂ瀭€€€â€Î€Ë€ą€ï€»€ë" #: ../../menuinfo.c:972 msgid "Size To Narrowest" msgstr "Éę€ÎŸź€”€€Êę€Ë€œ€í€š€ë" #: ../../menuinfo.c:973 msgid "Resize all selected objects to be as narrow as the narrowest one" msgstr "ÁȘÂò€·€żÁŽ€Æ€Î„Ș„Ö„ž„§„Ż„È€ÎÉę€òĄą°ìÈÖŸź€”€€€â€Î€Ë€ą€ï€»€ë" #: ../../menuinfo.c:975 msgid "Size To Tallest" msgstr "č Êę€Ë€ą€ï€»€ë" #: ../../menuinfo.c:976 msgid "Resize all selected objects to be as tall as the tallest one" msgstr "ÁȘÂò€·€żÁŽ€Æ€Î„Ș„Ö„ž„§„Ż„È€Îč—€òĄą°ìÈÖč €â€Î€Ë€ą€ï€»€ë" #: ../../menuinfo.c:978 msgid "Size To Shortest" msgstr "Ä Êę€Ë€ą€ï€»€ë" #: ../../menuinfo.c:979 msgid "Resize all selected objects to be as short as the shortest one" msgstr "ÁȘÂò€·€żÁŽ€Æ€Î„Ș„Ö„ž„§„Ż„È€Îč—€òĄą°ìÈÖÄ €â€Î€Ë€ą€ï€»€ë" #: ../../menuinfo.c:982 msgid "Size To Given Width & Height..." msgstr "»ŰÄê€Îč—€ÈÉę€Ë€č€ë..." #: ../../menuinfo.c:983 msgid "Resize all selected objects to a specified width and height" msgstr "ÁȘÂò€·€żÁŽ€Æ€Î„Ș„Ö„ž„§„Ż„È€òĄą»ŰÄꀷ€żÉę/藀ˀč€ë" #: ../../menuinfo.c:985 msgid "Size To Given Width..." msgstr "»ŰÄê€ÎÉę€Ë€č€ë..." #: ../../menuinfo.c:986 msgid "Resize all selected objects to a specified width" msgstr "ÁȘÂò€·€żÁŽ€Æ€Î„Ș„Ö„ž„§„Ż„È€òĄą»ŰÄꀷ€żÉę€Ë€č€ë" #: ../../menuinfo.c:988 msgid "Size To Given Height..." msgstr "»ŰÄê€Î藀ˀč€ë" #: ../../menuinfo.c:989 msgid "Resize all selected objects to a specified height" msgstr "ÁȘÂò€·€żÁŽ€Æ€Î„Ș„Ö„ž„§„Ż„È€òĄą»ŰÄꀷ€żč—€Ë€č€ë" #: ../../menuinfo.c:1007 msgid "Flip Horizontal" msgstr "¶ÀÁü(żćÊżÊęžț)" #: ../../menuinfo.c:1008 msgid "Flip selected objects horizontally" msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż„È€òżćÊżÊęžț€ËÈżĆŸ€č€ë" #: ../../menuinfo.c:1009 msgid "Flip Vertical" msgstr "¶ÀÁü(żâÄŸÊęžț)" #: ../../menuinfo.c:1009 msgid "Flip selected objects vertically" msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż„È€òżâÄŸÊęžț€ËÈżĆŸ€č€ë" #: ../../menuinfo.c:1012 msgid "Rotate Clock-Wise" msgstr "»ț·ŚÊęžț€ËČóĆŸ" #: ../../menuinfo.c:1012 msgid "Rotate selected objects clockwise" msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż„È€ò»ț·ŚŒț€ê€ËČóĆŸ€č€ë" #: ../../menuinfo.c:1014 msgid "Rotate Counter" msgstr "”ŐČóĆŸ" #: ../../menuinfo.c:1015 msgid "Rotate selected objects counter-clockwise" msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż„È€òÈż»ț·ŚŒț€ê€ËČóĆŸ€č€ë" #: ../../menuinfo.c:1018 msgid "Set Text Rotation..." msgstr "Êž»ú€ÎČóĆŸłŃ€òÀßÄê" #: ../../menuinfo.c:1018 msgid "Set text rotation in degrees" msgstr "ÉÁČèÊž»ú€ÎČóĆŸłŃĆÙ€òÀßÄê" #: ../../menuinfo.c:1020 msgid "Set Rotation Increment..." msgstr "ČóĆŸ€ÎÂ瀭€”€ò»ŰÄê..." #: ../../menuinfo.c:1021 msgid "Set rotation increment in degrees" msgstr "Êž»ú€òČóĆŸ€č€ë»ț€ÎÂ瀭€”€ò»ŰÄê..." #: ../../menuinfo.c:1029 msgid "Front" msgstr "Á°ÌÌ€Ű" #: ../../menuinfo.c:1029 msgid "Bring selected objects to the front" msgstr "ÁȘÂòÂĐŸĘ€òÁ°€Ë" #: ../../menuinfo.c:1031 msgid "Back" msgstr "ÇŰÌÌ€Ű" #: ../../menuinfo.c:1031 msgid "Send selected objects to the back" msgstr "ÁȘÂòÂĐŸĘ€òžć€í€Ë" #: ../../menuinfo.c:1034 msgid "Group" msgstr "„°„ëĄŒ„ŚČœ" #: ../../menuinfo.c:1035 msgid "Group selected objects into a compound object" msgstr "ÁȘÂòÂĐŸĘ€ò€Ò€È€Ä€Î„Ș„Ö„ž„§„Ż„È€È€·€Æ„°„ëĄŒ„ŚČœ€č€ë" #: ../../menuinfo.c:1036 msgid "UnGroup" msgstr "„°„ëĄŒ„ŚČòœü" #: ../../menuinfo.c:1037 msgid "Break up selected grouped objects into its components" msgstr "ÁȘÂò€”€ì€Æ€€€ë„Ș„Ö„ž„§„Ż„È€Î„°„ëĄŒ„ŚČœČòœü" #: ../../menuinfo.c:1040 msgid "Lock" msgstr "„í„Ă„Ż" #: ../../menuinfo.c:1040 msgid "Lock the positions of selected objects" msgstr "ÁȘÂòÂĐŸĘ€Î°ÌĂÖ€òžÇÄê€č€ë" #: ../../menuinfo.c:1042 msgid "UnLock" msgstr "„í„Ă„ŻČòœü" #: ../../menuinfo.c:1042 msgid "UnLock the positions of selected objects" msgstr "ÁȘÂòÂĐŸĘ€Î°ÌĂÖžÇÄê€òČòœü" #: ../../menuinfo.c:1045 ../../menuinfo.c:1651 ../../menuinfo.c:1757 msgid "Horizontal Align" msgstr "żćÊżÊęžț€ËÀ°Îó" #: ../../menuinfo.c:1046 msgid "HoriAlign submenu >>>" msgstr "żćÊżÊęžț€ÎÀ°Îó€ËŽŰ€č€ë„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1047 ../../menuinfo.c:1653 ../../menuinfo.c:1759 msgid "Vertical Align" msgstr "żâÄŸÊęžț€ËÀ°Îó" #: ../../menuinfo.c:1048 msgid "VertAlign submenu >>>" msgstr "żâÄŸÊęžț€ÎÀ°Îó€ËŽŰ€č€ë„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1050 msgid "Align Objects" msgstr "À°ÎóŒÂčÔ" #: ../../menuinfo.c:1051 msgid "Align selected objects with each other using the current alignments" msgstr "žœș߀ÎÀ°ÎóÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€òÀ°Îó" #: ../../menuinfo.c:1053 msgid "Align Objects Direct" msgstr "„Ș„Ö„ž„§„Ż„È€ÎÇÛĂÖÀßÄê" #: ../../menuinfo.c:1054 msgid "Align objects direct submenu >>>" msgstr "„Ș„Ö„ž„§„Ż„È€ÎÇÛĂÖÀßÄê„”„Ö„á„Ë„ćĄŒ>>>" #: ../../menuinfo.c:1056 msgid "Align To Grid" msgstr "„°„ê„ÄɀۀÎÀ°ÎóŒÂčÔ" #: ../../menuinfo.c:1057 msgid "Align selected objects to grid points using the current alignments" msgstr "žœș߀ÎÀ°ÎóÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../menuinfo.c:1059 msgid "Align To Grid Direct" msgstr "„°„ê„ÄɀËÂĐ€č€ëÇÛĂÖÀßÄê" #: ../../menuinfo.c:1060 msgid "Align to grid direct submenu >>>" msgstr "„°„ê„ÄɀËÂĐ€č€ëÇÛĂÖÀßÄê >>>" #: ../../menuinfo.c:1062 msgid "Align To Page" msgstr "„ÚĄŒ„žÆâ€ÎÀ°ÎóŒÂčÔ" #: ../../menuinfo.c:1063 msgid "Align selected objects to the page using the current alignments" msgstr "žœș߀ÎÀ°ÎóÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ò„ÚĄŒ„žÆâ€ÇÀ°Îó" #: ../../menuinfo.c:1065 msgid "Align To Page Direct" msgstr "„ÚĄŒ„žÆâ€Ç€ÎÇÛĂÖÀßÄê" #: ../../menuinfo.c:1066 msgid "Align to page direct submenu >>>" msgstr "„ÚĄŒ„žÆâ€Ç€ÎÇÛĂÖÀßÄê„”„Ö„á„Ë„ćĄŒ>>>" #: ../../menuinfo.c:1068 msgid "More Object Alignments" msgstr "€œ€ÎŸ€ÎÀ°Îó" #: ../../menuinfo.c:1069 msgid "Align objects submenu >>>" msgstr "À°ÎóŽŰÏą€Î„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1071 msgid "Size Objects" msgstr "Â瀭€”ÄŽÀ°" #: ../../menuinfo.c:1072 msgid "Size objects submenu >>>" msgstr "Â瀭€”ÄŽÀ°„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1074 msgid "Distribute Objects" msgstr "ŽÖłÖÄŽÀáŒÂčÔ" #: ../../menuinfo.c:1075 msgid "Distribute selected objects using the current alignments" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../menuinfo.c:1077 msgid "Distribute Objects Direct" msgstr "ŽÖłÖÄŽÀáÀßÄê" #: ../../menuinfo.c:1078 msgid "Distribute objects direct submenu >>>" msgstr "ŽÖłÖÄŽÀáÀßÄê„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1080 msgid "Layout On Arc" msgstr "±ßžÌŸć€ËÀ°Îó" #: ../../menuinfo.c:1080 msgid "Layout objects on an arc" msgstr "„Ș„Ö„ž„§„Ż„È€ò±ßžÌŸć€ËÇÛÎó€č€ë" #: ../../menuinfo.c:1083 msgid "Abut Horizontal" msgstr "żćÊżÊęžț€ËÎÙÀÜ" #: ../../menuinfo.c:1084 msgid "Squish selected objects together horizontally" msgstr "ÁȘÂòÂĐŸĘ€òĄążćÊżÊęžț€ËÎÙÀÜÇÛĂÖ€č€ë" #: ../../menuinfo.c:1086 msgid "Abut Vertical" msgstr "żâÄŸÊęžț€ËÎÙÀÜ" #: ../../menuinfo.c:1087 msgid "Squish selected objects together vertically" msgstr "ÁȘÂòÂĐŸĘ€òĄążâÄŸÊęžț€ËÎÙÀÜÇÛĂÖ€č€ë" #: ../../menuinfo.c:1090 msgid "Flip/Rotate" msgstr "¶ÀÁü/ČóĆŸ" #: ../../menuinfo.c:1091 msgid "Flip and rotate submenu >>>" msgstr "¶ÀÁü/ČóĆŸ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1098 msgid "Off" msgstr "" #: ../../menuinfo.c:1098 msgid "Do not update canvas window while scrolling" msgstr "„脯„íĄŒ„ëĂæ€Ë€ÏĄą„­„ă„ó„Є脊„Ł„ó„ɄЀòččż·€·€Ê€€" #: ../../menuinfo.c:1100 msgid "Jump" msgstr "„ž„ă„ó„Ś" #: ../../menuinfo.c:1100 msgid "Jump update canvas window while scrolling" msgstr "„Єلó„É„Š€Î„č„Ż„íĄŒ„ë»ț€Ë€Ï„­„ă„ó„Đ„č€ò„ž„ă„ó„Ś€·€Æččż·€č€ë" #: ../../menuinfo.c:1102 msgid "Smooth" msgstr "€Ê€á€é€«€Ë" #: ../../menuinfo.c:1102 msgid "Update canvas window smoothly while scrolling" msgstr "„脯„íĄŒ„ëĂæ€Ë€ÏĄą„­„ă„ó„Є脊„Ł„ó„É„Š€Ï€Ê€á€é€«€Ëččż·€č€ë" #: ../../menuinfo.c:1110 msgid "Show Bit/Pixmap" msgstr "Bit/Pixmap €ÎÉœŒš" #: ../../menuinfo.c:1111 msgid "Toggle between hiding and showing detailed bitmap/pixmap objects" msgstr "bitmap/pixmap„Ș„Ö„ž„§„Ż„È€ÎŸÜșÙ€ÎÉœŒš/ÈóÉœŒš€ÎÀÚÂŰ€š" #: ../../menuinfo.c:1114 msgid "Show Measurement" msgstr "ÊȘș耷€òÉœŒš" #: ../../menuinfo.c:1115 msgid "Show cursor measurements" msgstr "„«ĄŒ„œ„ë€ÎÊȘș耷€òÉœŒš" #: ../../menuinfo.c:1116 msgid "Show Measurement in Tooltip" msgstr "„ÄĄŒ„ë„Ò„ó„È€ËÊȘș耷€òÉœŒš" #: ../../menuinfo.c:1117 msgid "Show cursor measurements in tooltip" msgstr "„ÄĄŒ„ë„Ò„ó„Ȁ˄«ĄŒ„œ„ë€ÎÊȘș耷€òÉœŒš" #: ../../menuinfo.c:1119 msgid "Set Measure Unit..." msgstr "ÊȘș耷€Îñ°ÌÀßÄê" #: ../../menuinfo.c:1119 msgid "Set the unit of measurements" msgstr "ÊȘș耷€Îñ°ÌÀßÄê" #: ../../menuinfo.c:1122 msgid "Show Menubar" msgstr "„á„Ë„ćĄŒ„ĐĄŒ€òÉœŒš" #: ../../menuinfo.c:1122 msgid "Show menubar window" msgstr "„á„Ë„ćĄŒ„ĐĄŒ€òÉœŒš" #: ../../menuinfo.c:1124 msgid "Show Choice" msgstr "ÁȘÂò€òÉœŒš" #: ../../menuinfo.c:1124 #, fuzzy msgid "Show choice and message window" msgstr "„á„Ë„ćĄŒ„ĐĄŒ€òÉœŒš" #: ../../menuinfo.c:1126 msgid "Show Status" msgstr "łÆŒïŸđÊó€òÉœŒš" #: ../../menuinfo.c:1126 msgid "Show status window" msgstr "łÆŒïŸđÊóÉœŒšÍфЄلó„ɄЀòÉœŒš" #: ../../menuinfo.c:1134 ../../menuinfo.c:1161 msgid "Go HyperSpace In Slide Show" msgstr "„č„é„€„É„·„çĄŒ€Ç„Ï„€„ŃĄŒ„č„ÚĄŒ„襊„âĄŒ„ɀۄž„ă„ó„Ś" #: ../../menuinfo.c:1135 ../../menuinfo.c:1162 msgid "Enter HyperSpace mode in slideshow" msgstr "„č„é„€„É„·„çĄŒ€Ç„Ï„€„ŃĄŒ„č„ÚĄŒ„č€ËÆț€ë" #: ../../menuinfo.c:1137 ../../menuinfo.c:1164 msgid "Freehand Mode In Slide Show" msgstr "„č„é„€„É„·„çĄŒ€Ç„Ő„êĄŒ„Ï„ó„ÉĄŠ„âĄŒ„É" #: ../../menuinfo.c:1138 ../../menuinfo.c:1165 msgid "Go into freehand drawing mode in slideshow" msgstr "„č„é„€„É„·„çĄŒ€Ç„Ő„êĄŒ„Ï„ó„ÉÉÁŒÌ„âĄŒ„É€ŰÆț€ë" #: ../../menuinfo.c:1141 ../../menuinfo.c:1309 ../../menuinfo.c:1690 #: ../../menuinfo.c:1723 ../../menuinfo.c:1785 msgid "Color" msgstr "ż§" #: ../../menuinfo.c:1142 ../../menuinfo.c:1691 ../../menuinfo.c:1724 #: ../../menuinfo.c:1786 ../../strtbl.c:3633 msgid "Color Menu" msgstr "ż§€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1149 ../../menuinfo.c:1238 msgid "Slide Show" msgstr "„č„é„€„É„·„çĄŒ" #: ../../menuinfo.c:1149 msgid "Toggle SlideShow mode" msgstr "„č„é„€„É„·„çĄŒĄŠ„âĄŒ„É€ÎÀÚÂŰ" #: ../../menuinfo.c:1151 msgid "Set Slide Show Border Color..." msgstr "„č„é„€„É„·„çĄŒ€Î„ÜĄŒ„ÀĄŒ„«„éĄŒÀßÄê" #: ../../menuinfo.c:1152 msgid "Set the color of the slideshow border" msgstr "„č„é„€„É„·„çĄŒ€Î„ÜĄŒ„ÀĄŒ„«„éĄŒÀßÄê" #: ../../menuinfo.c:1154 msgid "Set Slide Show Window Offsets..." msgstr "" #: ../../menuinfo.c:1155 msgid "Set the offsets of the slideshow window" msgstr "" #: ../../menuinfo.c:1157 msgid "Visible Grid In Slide Show" msgstr "„č„é„€„É„·„çĄŒ€Ë„°„ê„ÄɀòÉœŒš" #: ../../menuinfo.c:1158 msgid "Toggle visible grid in slideshow mode" msgstr "„č„é„€„É„·„çĄŒ€Ë„°„ê„ÄɀòÉœŒš/ÈóÉœŒš" #: ../../menuinfo.c:1173 msgid "Zoom In" msgstr "„șĄŒ„à„€„ó" #: ../../menuinfo.c:1173 msgid "Zoom in" msgstr "„șĄŒ„à„€„ó" #: ../../menuinfo.c:1174 msgid "Zoom Out" msgstr "„șĄŒ„à„ą„Š„È" #: ../../menuinfo.c:1174 msgid "Zoom out" msgstr "„șĄŒ„à„ą„Š„È" #: ../../menuinfo.c:1175 msgid "Default Zoom" msgstr "„șĄŒ„à(„DŽՄ©„ë„È)" #: ../../menuinfo.c:1175 msgid "No zoom" msgstr "„șĄŒ„à€Ê€·" #: ../../menuinfo.c:1176 msgid "Zoom Way Out" msgstr "„șĄŒ„à„ą„Š„È(șÇŸź€Ë)" #: ../../menuinfo.c:1176 msgid "Zoom way out to see the whole drawing" msgstr "ÁŽÂ΀òž«€ì€ë€è€ŠŽ°ÁŽ€Ë„șĄŒ„à„ą„Š„È" #: ../../menuinfo.c:1184 ../../menuinfo.c:1604 msgid "+Grid" msgstr "„°„ê„Ă„É+" #. CSTID_INC_GRID_SIZE #: ../../menuinfo.c:1184 ../../menuinfo.c:1604 ../../strtbl.c:466 msgid "Increment grid size" msgstr "„°„ê„Ă„ÉĄŠ„”„€„ș€òÂ瀭€Ż€č€ë" #: ../../menuinfo.c:1185 ../../menuinfo.c:1605 msgid "-Grid" msgstr "„°„ê„Ă„É-" #. CSTID_DEC_GRID_SIZE #: ../../menuinfo.c:1185 ../../menuinfo.c:1605 ../../strtbl.c:468 msgid "Decrement grid size" msgstr "„°„ê„Ă„ÉĄŠ„”„€„ș€òŸź€”€Ż€č€ë" #: ../../menuinfo.c:1186 ../../menuinfo.c:1606 msgid "Visible Grid" msgstr "„°„ê„Ă„ÉÉœŒš" #: ../../menuinfo.c:1186 ../../menuinfo.c:1606 msgid "Hide/show grid lines" msgstr "„°„ê„ÄɄ鄀„ó€ÎÉœŒš/ÈóÉœŒš" #: ../../menuinfo.c:1188 ../../menuinfo.c:1608 msgid "Snap To Grid" msgstr "„°„ê„Äɀۀą€ï€»€ë" #: ../../menuinfo.c:1189 ../../menuinfo.c:1609 msgid "Toggle the snapping to grid points effect" msgstr "„°„ê„Ă„ÉĆÀ€Ű°ÌĂÖ€ò€ą€ï€»€ë/€ą€ï€»€Ê€€" #: ../../menuinfo.c:1191 ../../menuinfo.c:1611 msgid "Save Origin" msgstr "žœșß°ÌĂÖ”­Č±" #: ../../menuinfo.c:1192 ../../menuinfo.c:1612 msgid "Save current location as the 'origin' of the drawing" msgstr "žœșßÉÁČè°ÌĂÖ€ò”­Č±€č€ë" #: ../../menuinfo.c:1194 ../../menuinfo.c:1614 msgid "Scroll To Origin" msgstr "”­Č±°ÌĂÖ€ŰÌá€ë" #: ../../menuinfo.c:1195 ../../menuinfo.c:1615 msgid "Scroll to the 'origin' of the drawing" msgstr "”­Č±€·€Æ€€€ëÉÁČè°ÌĂÖ€ËÌá€ë" #: ../../menuinfo.c:1196 msgid "Scroll Mode" msgstr "„脯„íĄŒ„ë„âĄŒ„É" #: ../../menuinfo.c:1197 msgid "ScrollMode submenu >>>" msgstr "„脯„íĄŒ„륊„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1199 ../../menuinfo.c:1617 msgid "Zoom" msgstr "„șĄŒ„à" #: ../../menuinfo.c:1199 ../../menuinfo.c:1617 msgid "Zoom submenu >>>" msgstr "„șĄŒ„àĄŠ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1208 msgid "StackedPage submenu >>>" msgstr "„脿„Ă„Ż„ÚĄŒ„žĄŠ„”„Ö„á„Ë„ć >>>" #: ../../menuinfo.c:1210 msgid "TiledPage submenu >>>" msgstr "„ż„€„ë„ÚĄŒ„žĄŠ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1211 ../../menuinfo.c:1648 ../../menuinfo.c:1755 msgid "Page Layout" msgstr "„ÚĄŒ„ž„ì„€„ą„Š„È" #: ../../menuinfo.c:1212 msgid "PageLayout submenu >>>" msgstr "„ÚĄŒ„ž„ì„€„ą„Š„ÈĄŠ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1221 ../../menuinfo.c:1620 msgid "Set Reduction..." msgstr "łÈÂç/œÌŸź" #: ../../menuinfo.c:1222 ../../menuinfo.c:1621 msgid "Specify reduction/magnification of the whole drawing" msgstr "ÉÁČèÂĐŸĘÁŽÂ΀γÈÂç/œÌŸźÎš€ò»ŰÄê€č€ë" #: ../../menuinfo.c:1224 ../../menuinfo.c:1623 msgid "Metric Grid" msgstr "„°„ê„Ă„Éñ°Ì" #: ../../menuinfo.c:1225 ../../menuinfo.c:1624 msgid "Toggle between English and Metric grid systems" msgstr "„°„ê„Ă„Éñ°Ì€ÎÀÚÂŰ€š(inch/cm)" #: ../../menuinfo.c:1227 msgid "One Motion Select Move" msgstr "" #: ../../menuinfo.c:1228 msgid "Toggle between click-select-move and click-select-click-move modes" msgstr "„Ż„ê„Ă„Ż-ÁȘÂò-°Üư €«Ąą„Ż„ê„Ă„Ż-ÁȘÂò-„Ż„ê„Ă„Ż-°Üư €ÎÀÚÂŰ€š" #: ../../menuinfo.c:1230 msgid "Use Gray Scale" msgstr "„°„ì„€„脱ĄŒ„ë" #: ../../menuinfo.c:1231 msgid "Toggle between using gray scales to tile patterns to speed up printing" msgstr "" #: ../../menuinfo.c:1233 msgid "Use Color Layers" msgstr "„«„éĄŒ„ì„€„äĄŒ" #: ../../menuinfo.c:1233 msgid "Toggle color layers" msgstr "„«„éĄŒ„ì„€„äĄŒÀÚÂŰ€š" #: ../../menuinfo.c:1236 msgid "Show/Hide" msgstr "ÉœŒš/ÈóÉœŒš" #: ../../menuinfo.c:1237 msgid "Show/Hide submenu >>>" msgstr "ÉœŒš/ÈóÉœŒš„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1239 msgid "SlideShow submenu >>>" msgstr "„č„é„€„ÉĄŠ„·„焊ĄŠ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1246 msgid "Copy Properties..." msgstr "„ł„ÔĄŒ€Î°À­ÀßÄê" #: ../../menuinfo.c:1247 msgid "Copy properties (e.g., color, fill, etc.) into the cut buffer" msgstr "„«„Ă„È„Đ„Ă„Ő„Ą€Ű€Î„ł„ÔĄŒ€Î°À­(ż§ĄąĆÉ€ê€Ä€Ö€·€Ê€É)ÀßÄê" #: ../../menuinfo.c:1249 msgid "Paste Properties..." msgstr "„ÚĄŒ„č„È€ÎÀßÄê" #: ../../menuinfo.c:1250 msgid "Paste properties (e.g., color, fill, etc.) from the cut buffer" msgstr "„«„Ă„È„Đ„Ă„Ő„Ą€«€é€Î„ÚĄŒ„č„ȀΰÀ­(ż§ĄąĆÉ€ê€Ä€Ö€·€Ê€É)ÀßÄê" #: ../../menuinfo.c:1252 msgid "Save Properties..." msgstr "ÊĘž€Î°À­" #: ../../menuinfo.c:1253 msgid "Save and name a property (e.g., color, fill, etc.) set" msgstr "°À­(ż§ĄąĆÉ€ê€Ä€Ö€·€Ê€É)€Î„»„Ă„È€òÌŸÁ°€ò€Ä€±€ÆÊĘž" #: ../../menuinfo.c:1255 msgid "Restore Properties..." msgstr "°À­€òÌá€č..." #: ../../menuinfo.c:1256 msgid "Restore a named property (e.g., color, fill, etc.) set" msgstr "ÌŸÁ°€ò€Ä€±€żÂ°À­(ż§ĄąĆÉ€ê€Ä€Ö€·€Ê€É)€Î„»„Ă„È€ò€â€È€ËÌá€č" #. #. * { N_("Update Objects"), "Alt+0", #. * N_("Update selected objects to have current drawing properties"), NULL, #. * CMDID_UPDATE }, #. * { TGMUITEM_SEPARATOR, NULL, NULL, NULL, INVALID }, #. #: ../../menuinfo.c:1265 msgid "Set Selected Line Width..." msgstr "ÁȘÂò€·€żÀț€ÎÂÀ€”ÊŃčč..." #: ../../menuinfo.c:1266 msgid "Change the line width (and arrow width/height) of selected objects" msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż„È€ÎÀț€ÎÂÀ€”(€Ș€è€ÓÌđ°ő€ÎÉę/č—)€òÊŃčč" #: ../../menuinfo.c:1268 msgid "Set Selected Font Size..." msgstr "ÁȘÂò€·€żÊž»ú€Î„”„€„șÊŃčč..." #: ../../menuinfo.c:1269 msgid "Change the font size of selected objects" msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż„È€ÎÊž»ú„”„€„ș€òÊŃčč€č€ë" #: ../../menuinfo.c:1272 msgid "Add Color..." msgstr "ż§ÄÉČĂ..." #: ../../menuinfo.c:1272 msgid "Add colors to the current palette" msgstr "žœș߀΄фì„Ă„È€Ëż§€òÄÉČĂ€č€ë" #: ../../menuinfo.c:1275 msgid "Set Edit Text Size..." msgstr "ÊÔœžĂæ€ÎÊž»ú„”„€„șÀßÄê..." #: ../../menuinfo.c:1276 msgid "Set the text size to be used in editing existing text objects" msgstr "ÊÔœžĂæ€ÎÊž»ú„Ș„Ö„ž„§„Ż„È€ÎÊž»ú„”„€„ș€òÀßÄê€č€ë" #: ../../menuinfo.c:1278 msgid "Set Alt Edit Text BgColor..." msgstr "ÊÔœžĂæ€ÎÊž»úÇŰ·Êż§ÀßÄê..." #: ../../menuinfo.c:1279 msgid "Set the background color to be used in editing existing text objects" msgstr "ÊÔœžĂæ€ÎÊž»ú„Ș„Ö„ž„§„Ż„È€ÎÇŰ·Êż§€òÀßÄê€č€ë" #: ../../menuinfo.c:1281 msgid "Set Alt Edit Text Highlight Color..." msgstr "ÊÔœžĂæ€ÎÊž»ú€Î„Ï„€„é„€„È„«„éĄŒ" #: ../../menuinfo.c:1282 msgid "Set the highlight color to be used in editing existing text objects" msgstr "ÊÔœžĂæ€ÎÊž»ú„Ș„Ö„ž„§„Ż„È€Î„Ï„€„é„€„È„«„éĄŒ€òÀßÄê€č€ë" #: ../../menuinfo.c:1284 msgid "Use Alt Edit Text BgColor" msgstr "ÊÔœžĂæ€ÎÊž»úÇŰ·Ê€Ë„«„éĄŒ»ÈÍŃ" #: ../../menuinfo.c:1285 msgid "" "Toggles the background color to be used in editing existing text objects" msgstr "ÊÔœžĂæ€ÎÊž»ú„Ș„Ö„ž„§„Ż„È€ÎÇŰ·Êż§€ò»È€Š" #: ../../menuinfo.c:1288 ../../menuinfo.c:1656 ../../menuinfo.c:1761 msgid "Font" msgstr "„Ő„©„ó„È" #: ../../menuinfo.c:1289 msgid "Font submenu >>>" msgstr "„Ő„©„ó„ÈĄŠ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1290 ../../menuinfo.c:1658 ../../menuinfo.c:1763 msgid "Text Style" msgstr "»úÂÎ" #: ../../menuinfo.c:1291 msgid "TextStyle submenu >>>" msgstr "»úÂÎĄŠ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1292 ../../menuinfo.c:1660 ../../menuinfo.c:1765 msgid "Text Size" msgstr "Êž»ú„”„€„ș" #: ../../menuinfo.c:1293 msgid "TextSize submenu >>>" msgstr "Êž»ú„”„€„șĄŠ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1295 ../../menuinfo.c:1663 ../../menuinfo.c:1771 msgid "Line Dash" msgstr "ÇËÀț" #: ../../menuinfo.c:1296 msgid "LineDash submenu >>>" msgstr "ÇËÀț„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1297 ../../menuinfo.c:1665 ../../menuinfo.c:1773 msgid "Line Style" msgstr "Àț€Î„脿„€„ë" #: ../../menuinfo.c:1298 msgid "LineStyle submenu >>>" msgstr "Àț€Î„脿„€„ë€ËŽŰ€č€ë„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1299 ../../menuinfo.c:1667 ../../menuinfo.c:1775 msgid "Line Type" msgstr "Àț€ÎŒïÎà" #: ../../menuinfo.c:1300 msgid "LineType submenu >>>" msgstr "Àț€ÎŒïÎà€ËŽŰ€č€ë„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1301 ../../menuinfo.c:1669 ../../menuinfo.c:1777 msgid "Line Width" msgstr "Àț€ÎÂÀ€”" #: ../../menuinfo.c:1302 msgid "LineWidth submenu >>>" msgstr "Àț€ÎÂÀ€”€Î„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1304 ../../menuinfo.c:1672 ../../menuinfo.c:1779 msgid "Fill" msgstr "ĆÉ€ê€Ä€Ö€·" #: ../../menuinfo.c:1305 msgid "Fill submenu >>>" msgstr "ĆÉ€ê€Ä€Ö€·€ËŽŰ€č€ë„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1306 ../../menuinfo.c:1674 ../../menuinfo.c:1781 msgid "Pen" msgstr "„Ú„ó" #: ../../menuinfo.c:1307 msgid "Pen submenu >>>" msgstr "„Ú„ó€ËŽŰ€č€ë„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1309 msgid "Color submenu >>>" msgstr "ż§€ËŽŰ€č€ë„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1311 ../../menuinfo.c:1683 ../../menuinfo.c:1783 msgid "Transparent Pattern" msgstr "Æ©Čá„Ń„żĄŒ„ó" #: ../../menuinfo.c:1312 msgid "TransPattern submenu >>>" msgstr "Æ©Čá„Ń„żĄŒ„óĄŠ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1319 msgid "Go Back" msgstr "Ìá€ë" #: ../../menuinfo.c:1319 msgid "Go back one file" msgstr "Á°€Î„Ő„Ą„€„ë€ËÌá€ë" #: ../../menuinfo.c:1320 msgid "Go Forward" msgstr "ŒĄ€Ű" #: ../../menuinfo.c:1320 msgid "Go forward one file" msgstr "ŒĄ€Î„Ő„Ą„€„ë€Ű" #: ../../menuinfo.c:1322 msgid "Refresh Current" msgstr "„Ő„Ą„€„ëșÆÆÉčț€ß" #: ../../menuinfo.c:1322 msgid "Reload the current file" msgstr "žœș߀΄ՄĄ„€„ë€òșÆÆÉčț€ß" #: ../../menuinfo.c:1325 msgid "Hot List..." msgstr "„Û„Ă„È„ê„č„È" #: ../../menuinfo.c:1325 msgid "Navigate using the hot-list" msgstr "" #: ../../menuinfo.c:1327 msgid "Add Current To Hot List" msgstr "„Û„Ă„È„ê„č„È€ËÄÉČĂ" #: ../../menuinfo.c:1328 msgid "Add the current file to the hot-list" msgstr "žœș߀΄ՄĄ„€„ë€ò„Û„Ă„È„ê„č„È€ËÄÉČĂ" #: ../../menuinfo.c:1331 msgid "Session History..." msgstr "ÍúÎò" #: ../../menuinfo.c:1332 msgid "Go to a file visited during this session" msgstr "" #: ../../menuinfo.c:1335 msgid "Hyper Space" msgstr "„Ï„€„ŃĄŒ„č„ÚĄŒ„č" #: ../../menuinfo.c:1335 msgid "Toggle HyperSpace mode" msgstr "„Ï„€„ŃĄŒ„č„ÚĄŒ„襊„âĄŒ„É€ÎÀÚÂŰ€š" #: ../../menuinfo.c:1343 msgid "Attach Attributes" msgstr "°À­€ò€Ä€±€ë" #: ../../menuinfo.c:1344 msgid "Attach selected text objects as attributes for the non-text object" msgstr "ÁȘÂò€·€ż„Æ„­„č„È€ËÈó„Æ„­„č„ÈĄŠ„Ș„Ö„ž„§„Ż„ÈÍрΰÀ­€ò€Ä€±€ë" #: ../../menuinfo.c:1346 msgid "Detach Attributes" msgstr "°À­€ò€Ï€ș€č" #: ../../menuinfo.c:1347 msgid "Detach all attributes of selected objects" msgstr "ÁȘÂòÂĐŸĘ€«€éÁŽ€Æ€Î°À­€ò€Ï€ș€č" #: ../../menuinfo.c:1350 msgid "Edit Attributes..." msgstr "°À­ÊÔœž" #: ../../menuinfo.c:1351 msgid "Edit attributes of a selected object" msgstr "ÁȘÂòÂĐŸĘ€Î°À­€ÎÊÔœž" #: ../../menuinfo.c:1354 msgid "Show Attributes" msgstr "°À­€òÉœŒš" #: ../../menuinfo.c:1355 msgid "Make all attributes of selected objects visible" msgstr "" #: ../../menuinfo.c:1357 msgid "Show Attribute Names" msgstr "°À­ÌŸ€òÉœŒš" #: ../../menuinfo.c:1358 msgid "Make all attribute names of selected objects visible" msgstr "ÁȘÂòÂĐŸĘ€Î°À­€òÉœŒš€č€ë" #: ../../menuinfo.c:1360 msgid "Hide Attributes" msgstr "°À­€ò±Ł€č" #: ../../menuinfo.c:1361 msgid "Hide all attributes for selected objects" msgstr "ÁȘÂòÂĐŸĘ€Î°À­€ò±Ł€č" #: ../../menuinfo.c:1363 msgid "Hide Attribute Names" msgstr "°À­ÌŸ€ò±Ł€č" #: ../../menuinfo.c:1364 msgid "Hide all attribute names for selected objects" msgstr "ÁȘÂòÂĐŸĘ€Î°À­ÌŸ€ò±Ł€č" #: ../../menuinfo.c:1366 msgid "Toggle Eq Attribute Shown..." msgstr "" #: ../../menuinfo.c:1367 msgid "Showing/hiding the 'eq=' attibute (for a LaTeX equation object)" msgstr "" #: ../../menuinfo.c:1370 msgid "Move/Justfy An Attribute" msgstr "" #: ../../menuinfo.c:1371 msgid "Move/justify an attribute for a selected object" msgstr "" #: ../../menuinfo.c:1374 msgid "Import Attributes..." msgstr "°À­€òÆÉ€ßčț€à..." #: ../../menuinfo.c:1375 msgid "Import attributes of a selected object from a text file" msgstr "" #: ../../menuinfo.c:1377 msgid "Export Attributes..." msgstr "°À­€òœĐÎÏ" #: ../../menuinfo.c:1378 msgid "Export attributes of a selected object to a text file" msgstr "ÁȘÂòÂĐŸĘ€Î°À­€ò„Æ„­„č„È„Ő„Ą„€„ë€ËœĐÎÏ" #: ../../menuinfo.c:1386 msgid "Attach File Attributes" msgstr "„Ő„Ą„€„ë°À­€ò€Ä€±€ë" #: ../../menuinfo.c:1387 msgid "Attach selected text objects as file attributes" msgstr "" #: ../../menuinfo.c:1389 msgid "Detach File Attributes" msgstr "„Ő„Ą„€„ë°À­€ò€Ï€ș€č" #: ../../menuinfo.c:1390 msgid "Detach all file attributes" msgstr "ÁŽ€Æ€Î„Ő„Ą„€„ë°À­€ò€Ï€ș€č" #. STID_EDIT_FILE_ATTRS_DOTS #: ../../menuinfo.c:1393 ../../strtbl.c:683 msgid "Edit File Attributes..." msgstr "„Ő„Ą„€„ë°À­€òÊÔœž" #: ../../menuinfo.c:1394 msgid "Edit file attributes" msgstr "„Ő„Ą„€„ë°À­€òÊÔœž" #: ../../menuinfo.c:1402 msgid "Animate Send" msgstr "" #: ../../menuinfo.c:1403 msgid "Animate a little token on a selected poly (not very useful)" msgstr "" #: ../../menuinfo.c:1405 msgid "Animate Flash" msgstr "" #: ../../menuinfo.c:1406 msgid "Flash a selected poly (not very useful)" msgstr "" #: ../../menuinfo.c:1409 msgid "Renumber Object IDs" msgstr "" #: ../../menuinfo.c:1410 msgid "Renumber object IDs for all objects" msgstr "" #: ../../menuinfo.c:1418 msgid "Connect Two Ports by a Wire..." msgstr "" #: ../../menuinfo.c:1419 msgid "Connect two ports by a wire" msgstr "" #: ../../menuinfo.c:1421 msgid "Repeat Connect Two Ports by a Wire..." msgstr "" #: ../../menuinfo.c:1422 msgid "" "Repeatedly connecting two ports by a wire (will not prompt if the wire name " "can be detected). Wire signal name will not be shown." msgstr "" #: ../../menuinfo.c:1425 msgid "Show Wire Signal Name" msgstr "" #: ../../menuinfo.c:1426 msgid "" "Toggle between showing (with placing) and hiding the wire signal name when " "connecting ports" msgstr "" #: ../../menuinfo.c:1429 msgid "Merge Ports with An Object" msgstr "" #: ../../menuinfo.c:1430 #, fuzzy msgid "Merge selected floating port objects with a selected composite object" msgstr "ÁȘÂòÂĐŸĘ€ò€Ò€È€Ä€Î„Ș„Ö„ž„§„Ż„È€È€·€Æ„°„ëĄŒ„ŚČœ€č€ë" #: ../../menuinfo.c:1432 msgid "Connect Ports to a Broadcast Wire" msgstr "" #: ../../menuinfo.c:1433 msgid "" "Connect selected floating port objects to a selected broadcast-type wire" msgstr "" #: ../../menuinfo.c:1436 msgid "Clear Signal Name for a Port..." msgstr "" #: ../../menuinfo.c:1437 msgid "Clear the 'signal_name=' attribute for a port" msgstr "" #: ../../menuinfo.c:1439 msgid "Rename Signal Name for a Port..." msgstr "" #: ../../menuinfo.c:1440 msgid "Rename the 'signal_name=' attribute for a port" msgstr "" #: ../../menuinfo.c:1448 msgid "Merge With Table..." msgstr "„ÆĄŒ„Ö„ë€ÈĆęčç..." #: ../../menuinfo.c:1449 msgid "Merge selected object with a table file" msgstr "" #: ../../menuinfo.c:1451 msgid "Export To Table..." msgstr "„ÆĄŒ„Ö„ë€ŰœĐÎÏ..." #: ../../menuinfo.c:1452 msgid "Export attributes of selected objects to a table file" msgstr "" #: ../../menuinfo.c:1460 msgid "Make Symbolic" msgstr "„·„ó„Ü„ëČœ" #: ../../menuinfo.c:1461 msgid "Turn a selected grouped/icon object into a symbol object" msgstr "ÁȘÂò€·€ż„°„ëĄŒ„Ś/„ą„€„ł„ó€ò°ì€Ä€Î„·„ó„܄륊„Ș„Ö„ž„§„Ż„È€Ë€č€ë" #: ../../menuinfo.c:1463 msgid "UnMake Symbolic" msgstr "Èó„·„ó„Ü„ëČœ" #: ../../menuinfo.c:1464 msgid "Turn a selected symbol object into a grouped object" msgstr "ÁȘÂò€·€ż„·„ó„Ü„ë€ò„°„ëĄŒ„ŚČœ€”€ì€ż„Ș„Ö„ž„§„Ż„È€ËÌá€č" #: ../../menuinfo.c:1467 msgid "Instantiate..." msgstr "„Ö„í„Ă„Ż„Ș„Ö„ž„§„Ż„ÈÎă..." #: ../../menuinfo.c:1468 msgid "Instantiate a building-block object from the current domain" msgstr "" #: ../../menuinfo.c:1471 msgid "Make Iconic..." msgstr "„ą„€„ł„óČœ" #: ../../menuinfo.c:1472 msgid "Turn a selected grouped/symbol object into an icon object" msgstr "ÁȘÂò€·€ż„°„ëĄŒ„Ś/„ą„€„ł„ó€ò°ì€Ä€Î„ą„€„ł„óĄŠ„Ș„Ö„ž„§„Ż„È€Ë€č€ë" #: ../../menuinfo.c:1474 msgid "UnMake Iconic" msgstr "Èó„ą„€„ł„óČœ" #: ../../menuinfo.c:1475 msgid "Turn an icon object into a grouped object" msgstr "ÁȘÂò€·€ż„ą„€„ł„ó€ò„°„ëĄŒ„ŚČœ€”€ì€ż„Ș„Ö„ž„§„Ż„È€ËÌá€č" #: ../../menuinfo.c:1478 msgid "Push" msgstr "„Ś„Ă„·„ć" #: ../../menuinfo.c:1479 msgid "Push into (edit) the symbol file which defines the selected icon object" msgstr "" #: ../../menuinfo.c:1481 msgid "Pop" msgstr "„ʄÄŚ" #: ../../menuinfo.c:1482 msgid "Pop back to a high lever (reverse of Push)" msgstr "" #: ../../menuinfo.c:1485 msgid "Attribute" msgstr "°À­" #: ../../menuinfo.c:1486 msgid "Attribute submenu >>>" msgstr "°À­„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1487 msgid "File Attribute" msgstr "„Ő„Ą„€„ë°À­" #: ../../menuinfo.c:1488 msgid "File attribute submenu >>>" msgstr "„Ő„Ą„€„ë°À­„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1490 msgid "Update Symbols" msgstr "„·„ó„Ü„ë€Îččż·" #: ../../menuinfo.c:1491 msgid "Refresh selected icon objects from their definition files" msgstr "" #: ../../menuinfo.c:1493 msgid "Save Sym In Library..." msgstr "„·„ó„Ü„ë€ò„é„€„Ö„é„ê€ËÊĘž..." #: ../../menuinfo.c:1494 msgid "Save symbol file in a library path within the current domain" msgstr "žœș߀΄Ʉᄀ„óÆâ€Î„é„€„Ö„é„ê„Ń„č€Ë„·„ó„܄륊„Ő„Ą„€„ë€òÊĘž€č€ë" #: ../../menuinfo.c:1496 msgid "Replace Graphic" msgstr "„°„é„Ő„Ł„Ă„ŻĂÖŽč" #: ../../menuinfo.c:1497 msgid "" "Replace the graphical part of selected objects by the graphical object in " "the cut buffer" msgstr "" #: ../../menuinfo.c:1500 msgid "Domain" msgstr "„Ʉᄀ„ó" #: ../../menuinfo.c:1501 msgid "Domain submenu >>>" msgstr "„Ʉᄀ„óĄŠ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1502 msgid "Ports and Signals" msgstr "„ĘĄŒ„ȀȄ·„°„Ê„ë" #: ../../menuinfo.c:1503 msgid "Ports and Signal submenu >>>" msgstr "„ĘĄŒ„ȀȄ·„°„Ê„ëĄŠ„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1504 msgid "Table" msgstr "Éœ" #: ../../menuinfo.c:1505 msgid "Table submenu >>>" msgstr "ÉœŽŰÏą€Î„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1506 msgid "Misc" msgstr "€œ€ÎŸ" #: ../../menuinfo.c:1507 msgid "Misc submenu >>>" msgstr "€œ€ÎŸ€ÎÀßÄê„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1508 msgid "Return" msgstr "Ìá€ë" #: ../../menuinfo.c:1509 msgid "Return submenu >>>" msgstr "„”„Ö„á„Ë„ćĄŒ€ËÌá€ë >>>" #: ../../menuinfo.c:1511 msgid "Exec Cmds From File..." msgstr "„Ő„Ą„€„뀫€é„ł„Ț„ó„ÉŒÂčÔ..." #: ../../menuinfo.c:1512 msgid "Execute internal commands from a file" msgstr "„Ő„Ą„€„뀫€éÆâÉô„ł„Ț„ó„É€òŒÂčÔ€č€ë" #: ../../menuinfo.c:1520 msgid "Latest Release Info" msgstr "șÇż·ÈǀΟđÊó" #: ../../menuinfo.c:1521 msgid "Find out what is the version number of the most recently released tgif" msgstr "tgif €ÎșÇż·„ĐĄŒ„ž„ç„óÌŸ€ŹČż€«€òĂ΀ë" #: ../../menuinfo.c:1524 msgid "Copyright" msgstr "Ăűșîžą" #: ../../menuinfo.c:1524 msgid "Copyright information" msgstr "Ăűșîžą€ÎŸđÊó" #: ../../menuinfo.c:1527 msgid "About" msgstr "tgif €Ë€Ä€€€Æ" #: ../../menuinfo.c:1528 msgid "Version information, where to send bug reports, etc." msgstr "„ĐĄŒ„ž„ç„óŸđÊó€äĄą„Đ„°„ì„ĘĄŒ„È€ÎÁś€êÀè€Ê€É" #: ../../menuinfo.c:1546 ../../menuinfo.c:1574 msgid "Mode" msgstr "„âĄŒ„É" #. CSTID_MODE_MENU #: ../../menuinfo.c:1546 ../../menuinfo.c:1574 ../../strtbl.c:94 msgid "Mode Menu" msgstr "„âĄŒ„ÉĄŠ„á„Ë„ćĄŒ" #: ../../menuinfo.c:1557 ../../menuinfo.c:1595 ../../menuinfo.c:1642 #: ../../menuinfo.c:1722 ../../menuinfo.c:1750 msgid "Properties Menu" msgstr "łÆŒïÀßÄê„á„Ë„ćĄŒ" #: ../../menuinfo.c:1559 ../../menuinfo.c:1688 ../../menuinfo.c:1788 msgid "ImageProc Menu" msgstr "ČèÁüœèÍę€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1561 msgid "Edit Attribute In Editor" msgstr "„š„Ç„Ł„żĄŒ€Ç°À­ÊÔœž" #: ../../menuinfo.c:1562 msgid "Edit attribute in editor submenu >>>" msgstr "„š„Ç„Ł„żĄŒ€Ë€è€ë°À­ÊÔœžŽŰÏą€Î„”„Ö„á„Ë„ćĄŒ" #: ../../menuinfo.c:1564 msgid "Get Property" msgstr "°À­ŸđÊó" #: ../../menuinfo.c:1565 msgid "Get property submenu >>>" msgstr "°À­ŸđÊó„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1566 msgid "Peek Dimension" msgstr "" #: ../../menuinfo.c:1567 #, fuzzy msgid "Peek dimension submenu >>>" msgstr "„Ú„ó€ËŽŰ€č€ë„”„Ö„á„Ë„ćĄŒ >>>" #: ../../menuinfo.c:1582 msgid "Cut selected text into the cut buffer" msgstr "ÁȘÂò„Æ„­„č„È€ò„«„Ă„È„Đ„Ă„Ő„Ą€Ë°Üư€č€ë" #: ../../menuinfo.c:1591 msgid "Move Edit Text Box..." msgstr "ÊÔœžĂæ€Î„Æ„­„č„È„Ü„Ă„Ż„č€Î°Üư..." #: ../../menuinfo.c:1591 msgid "Move the edit text box" msgstr "ÊÔœžĂæ€Î„Æ„­„č„È„Ü„Ă„Ż„č€Î°Üư" #: ../../menuinfo.c:1633 ../../menuinfo.c:1713 ../../menuinfo.c:1741 msgid "File" msgstr "„Ő„Ą„€„ë" #: ../../menuinfo.c:1633 ../../menuinfo.c:1713 ../../menuinfo.c:1741 msgid "File Menu" msgstr "„Ő„Ą„€„륊„á„Ë„ćĄŒ" #: ../../menuinfo.c:1635 ../../menuinfo.c:1715 ../../menuinfo.c:1743 msgid "Edit" msgstr "ÊÔœž" #: ../../menuinfo.c:1635 ../../menuinfo.c:1715 ../../menuinfo.c:1743 msgid "Edit Menu" msgstr "ÊÔœž„á„Ë„ćĄŒ" #: ../../menuinfo.c:1637 ../../menuinfo.c:1717 ../../menuinfo.c:1745 msgid "Layout" msgstr "„ì„€„ą„Š„È" #. CSTID_LAYOUT_MENU #: ../../menuinfo.c:1638 ../../menuinfo.c:1718 ../../menuinfo.c:1746 #: ../../strtbl.c:172 msgid "Layout Menu" msgstr "„ì„€„ą„Š„ÈĄŠ„á„Ë„ćĄŒ" #: ../../menuinfo.c:1639 ../../menuinfo.c:1719 ../../menuinfo.c:1747 msgid "Arrange" msgstr "„ą„ì„ó„ž" #: ../../menuinfo.c:1640 ../../menuinfo.c:1720 ../../menuinfo.c:1748 msgid "Arrange Menu" msgstr "„ą„ì„ó„žĄŠ„á„Ë„ćĄŒ" #: ../../menuinfo.c:1649 ../../menuinfo.c:1756 ../../strtbl.c:3655 #: ../../strtbl.c:3657 msgid "PageLayout Menu" msgstr "„ÚĄŒ„ž„ì„€„ą„Š„ÈĄŠ„á„Ë„ćĄŒ" #: ../../menuinfo.c:1652 ../../menuinfo.c:1758 ../../strtbl.c:3638 msgid "HoriAlign Menu" msgstr "żćÊżÊęžț€ÎÀ°ÎóŽŰÏą€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1654 ../../menuinfo.c:1760 ../../strtbl.c:3643 msgid "VertAlign Menu" msgstr "żâÄŸÊęžț€ÎÀ°ÎóŽŰÏą€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1656 ../../menuinfo.c:1761 ../../strtbl.c:3671 msgid "Font Menu" msgstr "„Ő„©„ó„ÈĄŠ„á„Ë„ćĄŒ" #: ../../menuinfo.c:1659 ../../menuinfo.c:1764 ../../strtbl.c:3662 #: ../../strtbl.c:3664 ../../strtbl.c:3666 msgid "TextStyle Menu" msgstr "»úÂ΄á„Ë„ćĄŒ" #: ../../menuinfo.c:1661 ../../menuinfo.c:1766 ../../strtbl.c:3681 msgid "TextSize Menu" msgstr "Êž»ú„”„€„ș€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1664 ../../menuinfo.c:1772 ../../strtbl.c:3701 msgid "LineDash Menu" msgstr "ÇËÀț„á„Ë„ćĄŒ" #: ../../menuinfo.c:1666 ../../menuinfo.c:1774 ../../strtbl.c:3691 msgid "LineStyle Menu" msgstr "Àț€Î„脿„€„ë€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1668 ../../menuinfo.c:1776 ../../strtbl.c:3696 msgid "LineType Menu" msgstr "Àț€ÎŒïÎà€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1670 ../../menuinfo.c:1778 ../../strtbl.c:3686 msgid "LineWidth Menu" msgstr "Àț€ÎÂÀ€”€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1672 ../../menuinfo.c:1779 ../../strtbl.c:3742 msgid "Fill Menu" msgstr "ĆÉ€ê€Ä€Ö€·€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1674 ../../menuinfo.c:1781 ../../strtbl.c:3747 msgid "Pen Menu" msgstr "„Ú„ó€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1677 ../../menuinfo.c:1751 msgid "Move Mode" msgstr "°Üư„âĄŒ„É" #: ../../menuinfo.c:1678 ../../menuinfo.c:1752 ../../strtbl.c:3716 #: ../../strtbl.c:3718 msgid "MoveMode Menu" msgstr "°Üư„âĄŒ„ɀ΄á„Ë„ćĄŒ" #: ../../menuinfo.c:1680 ../../menuinfo.c:1768 ../../strtbl.c:3723 msgid "Shape Menu" msgstr "·Á€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1681 ../../menuinfo.c:1769 msgid "Stretchable Text" msgstr "łÈÂç€Ç€­€ëÊž»ú" #: ../../menuinfo.c:1682 ../../menuinfo.c:1770 ../../strtbl.c:3728 #: ../../strtbl.c:3730 msgid "StretchText Menu" msgstr "łÈÂç€Ç€­€ëÊž»ú€ËŽŰ€č€ë„á„Ë„ćĄŒ" #: ../../menuinfo.c:1684 ../../menuinfo.c:1784 ../../strtbl.c:3752 #: ../../strtbl.c:3754 msgid "TransPattern Menu" msgstr "Æ©Čá„Ń„żĄŒ„ó€Î„á„Ë„ćĄŒ" #: ../../menuinfo.c:1692 ../../menuinfo.c:1725 ../../menuinfo.c:1789 msgid "Navigate" msgstr "„Ê„Ó„ČĄŒ„È" #: ../../menuinfo.c:1693 ../../menuinfo.c:1726 ../../menuinfo.c:1790 msgid "Navigate Menu" msgstr "„Ê„Ó„ČĄŒ„È„á„Ë„ćĄŒ" #: ../../menuinfo.c:1694 ../../menuinfo.c:1727 ../../menuinfo.c:1791 msgid "Special" msgstr "„č„Ú„·„ă„ë" #: ../../menuinfo.c:1695 ../../menuinfo.c:1728 ../../menuinfo.c:1792 msgid "Special Menu" msgstr "„č„Ú„·„ă„륊„á„Ë„ćĄŒ" #: ../../menuinfo.c:1697 ../../menuinfo.c:1730 ../../menuinfo.c:1794 msgid "Tangram-II" msgstr "" #: ../../menuinfo.c:1698 ../../menuinfo.c:1731 ../../menuinfo.c:1795 msgid "Tangram-II Menu" msgstr "" #: ../../menuinfo.c:1700 ../../menuinfo.c:1733 ../../menuinfo.c:1797 msgid "Help" msgstr "„ۄ넌" #: ../../menuinfo.c:1700 ../../menuinfo.c:1733 ../../menuinfo.c:1797 msgid "Help Menu" msgstr "„ۄ넌ĄŠ„á„Ë„ćĄŒ" #: ../../menuinfo.c:1753 msgid "Page" msgstr "„ÚĄŒ„ž" #. CSTID_PAGE_MENU #: ../../menuinfo.c:1754 ../../strtbl.c:260 ../../strtbl.c:3648 #: ../../strtbl.c:3650 msgid "Page Menu" msgstr "„ÚĄŒ„žĄŠ„á„Ë„ćĄŒ" #. CSTID_OK #: ../../strtbl.c:50 msgid "Ok" msgstr "λČò" #. CSTID_CANCEL #: ../../strtbl.c:52 msgid "Cancel" msgstr "„­„ă„ó„»„ë" #. CSTID_PARANED_NONE #: ../../strtbl.c:54 ../../strtbl.c:3337 ../../strtbl.c:3432 #: ../../strtbl.c:3459 ../../strtbl.c:3486 ../../strtbl.c:3513 #: ../../strtbl.c:3723 msgid "(none)" msgstr "(Ì”žú)" #. CSTID_SET_FONT_TO #: ../../strtbl.c:56 #, c-format msgid "Set font to '%s'" msgstr "„Ő„©„ó„È€ò '%s' €ËÀßÄê" #. CSTID_NO_OBJ_SELECTED #: ../../strtbl.c:58 msgid "No object selected." msgstr "„Ș„Ö„ž„§„Ż„È€ŹÁȘÂò€”€ì€Æ€Ț€»€ó" #. CSTID_SPECIFY_ARC_END #: ../../strtbl.c:60 msgid "Please specify the end of an arc." msgstr "±ßžÌ€ÎœȘ€ê€ÎĆÀ€ò»ŰÄꀷ€Æ€Ż€À€”€€" #. CSTID_SPECIFY_ARC_START #: ../../strtbl.c:62 msgid "Please specify the start of an arc." msgstr "±ßžÌ€Î€Ï€ž€Ț€ê€ÎĆÀ€ò»ŰÄꀷ€Æ€Ż€À€”€€" #. CSTID_SPECIFY_ARC_THIRD #: ../../strtbl.c:64 msgid "Please specify a 3rd point on the arc." msgstr "" #. CSTID_SET_ARC_END #: ../../strtbl.c:66 msgid "Set end of arc" msgstr "±ßžÌ€ÎœȘĆÀ€òÀßÄê" #. CSTID_SET_ARC_START #: ../../strtbl.c:68 msgid "Set start of arc" msgstr "±ßžÌ€Î»ÏĆÀ€òÀßÄê" #. CSTID_SET_ARC_THIRD #: ../../strtbl.c:70 msgid "Set 3rd point on arc" msgstr "±ßžÌŸć€ÎĆÀ€ò°ìžÄÀßÄê" #. CSTID_SPECIFY_ARC_END_CW #: ../../strtbl.c:72 msgid "Please specify the end of the arc (clockwise)." msgstr "±ßžÌ€ÎœȘ€ê€ÎĆÀ€ò»ŰÄꀷ€Æ€Ż€À€”€€(»ț·ŚŒț€ê)" #. CSTID_SPECIFY_ARC_END_CCW #: ../../strtbl.c:74 msgid "Please specify the end of the arc (counter-clockwise)." msgstr "±ßžÌ€ÎœȘ€ê€ÎĆÀ€ò»ŰÄꀷ€Æ€Ż€À€”€€(Èż»ț·ŚŒț€ê)" #. CSTID_CANCEL_NOT_AVAIL #: ../../strtbl.c:76 msgid "CANCEL is not a valid option." msgstr "" #. CSTID_DLG_DEF_CONTINUE #: ../../strtbl.c:78 msgid "( <CR> or <ESC> to continue )" msgstr "(„­„ă„ó„»„ë€Ï <CR>€Ț€ż€Ï<ESC>)" #. CSTID_DLG_ACCEPT_CANCEL #: ../../strtbl.c:80 msgid "( <CR>: accept, <ESC>: cancel )" msgstr "(<CR>: łÎÄê, <ESC>: „­„ă„ó„»„ë)" #. CSTID_MALFORMED_INPUT_STR #: ../../strtbl.c:82 #, c-format msgid "Malformed input '%s'." msgstr "" #. CSTID_CACHING_TEXT_BMP #: ../../strtbl.c:84 msgid "Caching text bitmap..." msgstr "" #. CSTID_PROGRESS_PERCENT #: ../../strtbl.c:86 msgid "Progress: %1d%%" msgstr "œèÍęĂæ: %1d%%" #. CSTID_FINISHED_CACHEING_TEXT_BMP #: ../../strtbl.c:88 msgid "Finishing caching text bitmap..." msgstr "" #. CSTID_BAD_BOX_BBOX_ADJUSTED #: ../../strtbl.c:90 msgid "Bad box bounding box. Adjusted." msgstr "" #. CSTID_MAIN_MENU #: ../../strtbl.c:92 msgid "Main Menu" msgstr "„á„€„óĄŠ„á„Ë„ćĄŒ" #. CSTID_ROTATE_DEGREES_CW #: ../../strtbl.c:96 #, c-format msgid "Rotate %s degrees clock-wise" msgstr "»ț·ŚŒț€ê€Ë %s ĆÙČóĆŸ€č€ë" #. CSTID_ROTATE_DEGREES_CCW #: ../../strtbl.c:98 #, c-format msgid "Rotate %s degrees counter-clock-wise" msgstr "Èż»ț·ŚŒț€ê€Ë %s ĆÙČóĆŸ€č€ë" #. CSTID_PRINT_MODE #: ../../strtbl.c:100 #, c-format msgid "%s print mode" msgstr "%s °őșț„âĄŒ„É" #. CSTID_EXPORT_MODE #: ../../strtbl.c:102 #, c-format msgid "%s export mode" msgstr "%s œĐÎÏ„âĄŒ„É" #. CSTID_PRINT_EXPORT_MENU #: ../../strtbl.c:104 msgid "Print/ExportFormat Menu" msgstr "°őșț/œĐÎÏ„Ő„©ĄŒ„Ț„Ă„ÈĄŠ„á„Ë„ćĄŒ" #. CSTID_FLUSH_UNDO_PERCENT #: ../../strtbl.c:106 msgid "Flushing undo buffers... %1d%%" msgstr "„ł„Ț„ó„ÉÍúÎò€òŸĂ”î... %1d%%" #. CSTID_SET_COLOR_TO #: ../../strtbl.c:108 #, c-format msgid "Set color to '%s'" msgstr "ż§€ò'%s' €ËÀßÄê" #. CSTID_CANNOT_ALLOC_COLOR_USE_ALT #: ../../strtbl.c:110 #, c-format msgid "Cannot allocate color '%s', use '%s' instead." msgstr "ż§ '%s' €ò»È€š€Ț€»€ó. €«€ï€ê€Ë '%s' €ò»È€€€Ț€č." #. CSTID_UPDATING_PIXELS #: ../../strtbl.c:112 #, c-format msgid "Updating pixels (%1d - %1dx%1d)..." msgstr "" #. CSTID_NONE #: ../../strtbl.c:114 msgid "none" msgstr "€Ê€·" #. CSTID_PARANED_NULL #: ../../strtbl.c:116 msgid "null" msgstr "" #. CSTID_RESTORE #: ../../strtbl.c:124 msgid "Restore" msgstr "Ìá€č" #. CSTID_YES #: ../../strtbl.c:126 msgid "Yes" msgstr "€Ï€€" #. CSTID_NO #: ../../strtbl.c:128 msgid "No" msgstr "€€€€€š" #. CSTID_EXTRA #: ../../strtbl.c:130 msgid "Extra" msgstr "" #. CSTID_INTERRUPT #: ../../strtbl.c:132 msgid "interrupt" msgstr "łäčț€ß" #. CSTID_LEAVE_HYPERSPACE #: ../../strtbl.c:134 msgid "Leave HyperSpace" msgstr "„Ï„€„ŃĄŒ„č„ÚĄŒ„耫€éœĐ€ë" #. CSTID_ENTER_HYPERSPACE #: ../../strtbl.c:136 msgid "Enter HyperSpace" msgstr "„Ï„€„ŃĄŒ„č„ÚĄŒ„č€ËÆț€ë" #. CSTID_CACHING_IMAGE #: ../../strtbl.c:138 msgid "Caching images..." msgstr "ČèÁüŒè€êčț€ß" #. CSTID_TOGGLE_SMOOTH_HINGE #: ../../strtbl.c:140 msgid "Toggle smooth/hinge points" msgstr "" #. CSTID_FINISH #: ../../strtbl.c:142 msgid "Finish" msgstr "" #. CSTID_DEL_A_VERTEX #: ../../strtbl.c:144 msgid "Delete a vertex" msgstr "ÄșĆÀ€Îșïœü..." #. CSTID_ADD_A_VERTEX #: ../../strtbl.c:146 msgid "Add a vertex" msgstr "ÄșĆÀ€ÎÄÉČĂ..." #. CSTID_START_LAYOUT_ON_ARC #: ../../strtbl.c:148 msgid "Start layout on arc" msgstr "±ßžÌŸć€Ë„ì„€„ą„Š„Èł«»Ï" #. CSTID_END_LAYOUT_ON_ARC #: ../../strtbl.c:150 msgid "End layout on arc" msgstr "±ßžÌŸć€Ë„ì„€„ą„Š„ÈœȘλ" #. CSTID_EXECUTING_GIVEN_PROGRAM #: ../../strtbl.c:152 #, c-format msgid "Executing '%s'..." msgstr "'%s' ŒÂčÔĂæ..." #. CSTID_DOTS_DONE #: ../../strtbl.c:154 msgid "...Done" msgstr "...œȘλ" #. CSTID_IMPORTING_FILE #: ../../strtbl.c:156 #, c-format msgid "Importing '%s'..." msgstr "„Ő„Ą„€„ë '%s' €òÁȚÆț..." #. CSTID_LOADING_FILE #: ../../strtbl.c:158 #, c-format msgid "Loading '%s'..." msgstr "'%s'ÆÉ€ßčț€ßĂæ..." #. CSTID_EDIT_TEXT_SIZE_SUBSTR #: ../../strtbl.c:160 msgid "edit text size" msgstr "Êž»ú„”„€„ș€ÎÊÔœž..." #. CSTID_SET_FONT_SIZE_TO_PT #: ../../strtbl.c:162 #, c-format msgid "Set font size to %1dpt" msgstr "„Ő„©„ó„Ȁ΄”„€„ș€ò %1dpt €Ë€·€Ț€č" #. CSTID_SET_FONT_SIZE_TO #: ../../strtbl.c:164 #, c-format msgid "Set font size to %1d" msgstr "„Ő„©„ó„Ȁ΄”„€„ș€ò %1d €Ë€·€Ț€č" #. CSTID_MAKING_CONN_TO_HOST #: ../../strtbl.c:166 #, c-format msgid "%s: making connection to '%s'..." msgstr "" #. CSTID_CONN_TO_HOST_ESTABLISHED #: ../../strtbl.c:168 #, c-format msgid "%s: connection to '%s' established." msgstr "" #. CSTID_LOGIN_SUCC_RETRIEVE_DATA #: ../../strtbl.c:170 #, c-format msgid "%s: login successful; retrieving data..." msgstr "" #. CSTID_MAKING_CONN_TO_HOST_PORT #: ../../strtbl.c:174 #, c-format msgid "%s: making connection to '%s:%1d'..." msgstr "" #. CSTID_CONN_TO_HOST_PORT_ESTB #: ../../strtbl.c:176 #, c-format msgid "%s: connection to '%s:%1d' established." msgstr "" #. CSTID_SENDING_REQUESTS_DOTS #: ../../strtbl.c:178 #, c-format msgid "%s: sending requests..." msgstr "" #. CSTID_PARANED_UNKNOWN #: ../../strtbl.c:180 msgid "(unknown)" msgstr "" #. CSTID_READING_RESPONSE_DOTS #: ../../strtbl.c:182 #, c-format msgid "%s: reading responses..." msgstr "" #. CSTID_RESPONSES_RECEIVED #: ../../strtbl.c:184 #, c-format msgid "%s: responses received." msgstr "" #. CSTID_GEN_FINAL_PIXELS_PERC #: ../../strtbl.c:186 msgid "Generating final pixels: %1d%%" msgstr "" #. CSTID_BUILDING_HISTOGRAM_DOTS #: ../../strtbl.c:188 msgid "Building histogram..." msgstr "„Ò„č„È„°„é„àșîÀźĂæ..." #. CSTID_HISTOGRAM_PERC #: ../../strtbl.c:190 msgid "Histogram: %1d%%" msgstr "„Ò„č„È„°„é„à: %1d%%" #. CSTID_COMP_NEW_PIXELS_PERC #: ../../strtbl.c:192 ../../strtbl.c:198 msgid "Computing new pixels: %1d%%" msgstr "" #. CSTID_QUANTIZING_COLORS_DOTS #: ../../strtbl.c:194 #, c-format msgid "Quantizing from %1d to %1d colors..." msgstr "" #. CSTID_REMAPPING_COLORS_DOTS #: ../../strtbl.c:196 #, fuzzy msgid "Remapping Colors..." msgstr "žșż§..." #. CSTID_CALC_ERR_DIFF_PIX_VAL_PERC #: ../../strtbl.c:200 msgid "Calculating error diffused pixel values: %1d%%" msgstr "" #. CSTID_CALC_NEW_PIX_1_VAL_PERC #: ../../strtbl.c:202 msgid "Calculating new pixel values (pass 1): %1d%%" msgstr "" #. CSTID_CALC_NEW_PIX_2_VAL_PERC #: ../../strtbl.c:204 msgid "Calculating new pixel values (pass 2): %1d%%" msgstr "" #. CSTID_DLG_ACCEPT_CONTINUE #: ../../strtbl.c:206 msgid "( <CR>: accept, <ESC>: continue )" msgstr "(<CR>: łÎÄê, <ESC>: „­„ă„ó„»„ë)" #. CSTID_OPENING_GIVEN #: ../../strtbl.c:208 #, c-format msgid "Opening '%s'..." msgstr "„Ő„Ą„€„ë %s €òł«€€€Æ€Ț€č..." #. CSTID_BACKGROUNDING_CMD #: ../../strtbl.c:210 #, c-format msgid "Backgrounding; '%s'." msgstr "„Đ„Ă„Ż„°„鄊„ó„É; '%s'." #. CSTID_CNTRL_C_TO_INTR_AND_ABEND #: ../../strtbl.c:212 msgid "Type ^C if you want to interrupt and end abnormally..." msgstr "" #. CSTID_MOVE_PINNED_MENU #: ../../strtbl.c:214 msgid "Move pinned menu" msgstr "žÇÄê„âĄŒ„ɀ΄á„Ë„ćĄŒ€ò°Üư" #. CSTID_CLOSE_PINNED_MENU #: ../../strtbl.c:216 msgid "Close pinned menu" msgstr "žÇÄê„á„Ë„ćĄŒ€òÊÄ€ž€ë" #. CSTID_RELEASE_MOUSE_TO_PIN_MENU #: ../../strtbl.c:218 msgid "Release the mouse to pin down the menu" msgstr "" #. CSTID_LOCKED_OBJS_NOT_MOVED #: ../../strtbl.c:220 msgid "Locked objects are not moved." msgstr "„í„Ă„Ż€”€ì€ż„Ș„Ö„ž„§„Ż„È€Ï°ÜÆ°€Ç€­€Ț€»€ó" #. CSTID_SCROLL_DOWN_1_LINE #: ../../strtbl.c:222 msgid "scroll down 1 line" msgstr "1čÔČŒ€Ë„脯„íĄŒ„ë" #. CSTID_SCROLL_AROUND #: ../../strtbl.c:224 #, fuzzy msgid "scroll around" msgstr "„脯„íĄŒ„ë„âĄŒ„É" #. CSTID_SCROLL_UP_1_LINE #: ../../strtbl.c:226 msgid "scroll up 1 line" msgstr "1čÔŸć€Ë„脯„íĄŒ„ë" #. CSTID_ENABLE_REDRAW #: ../../strtbl.c:228 msgid "enable redraw" msgstr "șÆÉÁČè€òčÔ€Š" #. CSTID_DISABLE_REDRAW #: ../../strtbl.c:230 msgid "disable redraw" msgstr "șÆÉÁČè€òčÔ€ï€Ê€€" #. CSTID_GET_DIR_LIST_PLEASE_WAIT #: ../../strtbl.c:232 #, c-format msgid "Getting directory listing of '%s', please wait..." msgstr " '%s'€Î„Ç„Ł„ì„Ż„È„ê„ê„č„È€òŒèÆÀĂæĄąŸŻĄč€ȘÂÔ€ÁČŒ€”€€..." #. CSTID_ENTERING_HYPERSPACE #: ../../strtbl.c:234 msgid "Entering hyperspace..." msgstr "„Ï„€„ŃĄŒ„č„ÚĄŒ„č€ËÆț€ê€Ț€č..." #. CSTID_GOTO #: ../../strtbl.c:236 msgid "Goto" msgstr "" #. CSTID_CLOSE #: ../../strtbl.c:240 msgid "Close" msgstr "ÊÄ€ž€ë" #. CSTID_BAD_OVAL_BBOX_ADJ #: ../../strtbl.c:242 msgid "Bad oval bounding box. Adjusted." msgstr "" #. CSTID_SHIFT_ALL_TABS_RIGHT #: ../../strtbl.c:244 msgid "Shift All Tabs Right" msgstr "" #. CSTID_SHIFT_TABS_RIGHT #: ../../strtbl.c:246 msgid "Shift Tabs Right" msgstr "" #. CSTID_SHIFT_TABS_LEFT #: ../../strtbl.c:248 msgid "Shift Tabs Left" msgstr "" #. CSTID_SHIFT_ALL_TABS_LEFT #: ../../strtbl.c:254 msgid "Shift All Tabs Left" msgstr "" #. CSTID_SHIFT_10_TABS_RIGHT #: ../../strtbl.c:256 msgid "Shift 10 Tabs Right" msgstr "" #. CSTID_SHIFT_10_TABS_LEFT #: ../../strtbl.c:258 msgid "Shift 10 Tabs Left" msgstr "" #. CSTID_GOTO_GIVEN_PAGE #: ../../strtbl.c:262 #, c-format msgid "Goto page %1d" msgstr "„ÚĄŒ„ž %1d €Ű°Üư" #. CSTID_GOTO_GIVEN_PAGE_WITH_NAME #: ../../strtbl.c:264 #, c-format msgid "Goto page %1d: \"%s\"" msgstr "%1d: \"%s\" €Ë°Üư" #. CSTID_GRAYSTR_CALLED_WITH_IDX_2 #: ../../strtbl.c:266 msgid "Error: GrayStr() called with index <= 2." msgstr "" #. CSTID_GRAY_SCALE_USED_FOR_PAT #: ../../strtbl.c:268 msgid "Warning: Gray scales used instead of tiling patterns." msgstr "" #. CSTID_SET_FILL_TO_NONE #: ../../strtbl.c:270 msgid "Set fill pattern to NONE" msgstr "ĆÉ€ê€Ä€Ö€·„Ń„żĄŒ„ó:€Ê€·" #. CSTID_SET_FILL_TO_SOLID #: ../../strtbl.c:272 msgid "Set fill pattern to SOLID" msgstr "ĆÉ€ê€Ä€Ö€·„Ń„żĄŒ„ó:„œ„ê„Ă„É" #. CSTID_SET_FILL_TO_BACKGROUND #: ../../strtbl.c:274 msgid "Set fill pattern to BACKGROUND" msgstr "ÇŰ·Ê€ÎĆÉ€ê€Ä€Ö€·„Ń„żĄŒ„óÀßÄê" #. CSTID_SET_FILL_TO_PAT_NUMBER #: ../../strtbl.c:276 #, c-format msgid "Set fill pattern to pattern #%1d" msgstr "" #. CSTID_SET_LINE_WIDTH_TO_GIVEN_S #: ../../strtbl.c:278 #, c-format msgid "Set line width to %s" msgstr "Àț€ÎÂÀ€”€ò %s €Ë€č€ë" #. CSTID_SET_PEN_DASH_PAT_NO_DASH #: ../../strtbl.c:280 msgid "Set dash pattern for the pen to be no dashes" msgstr "" #. CSTID_SET_PEN_DASH_PAT_PAT_NUM #: ../../strtbl.c:282 #, c-format msgid "Set dash pattern for the pen to dash pattern #%1d" msgstr "„Ú„ó€ÎÇËÀț€Î„Ń„żĄŒ„ó€ò„Ń„żĄŒ„ó #%1d €ËÊŃčč" #. CSTID_SET_PEN_TO_NONE #: ../../strtbl.c:284 msgid "Set pen to NONE" msgstr "" #. CSTID_SET_PEN_TO_SOLID #: ../../strtbl.c:286 msgid "Set pen to SOLID" msgstr "" #. CSTID_SET_PEN_TO_BACKGROUND #: ../../strtbl.c:288 msgid "Set pen to BACKGROUND" msgstr "" #. CSTID_SET_PEN_TO_PAT_NUM #: ../../strtbl.c:290 #, c-format msgid "Set pen to pattern #%1d" msgstr "„Ú„ó€ò„Ń„żĄŒ„ó #%1d €ËÀßÄê" #. CSTID_SEL_A_PIN_ESC_TO_END_DOTS #: ../../strtbl.c:292 msgid "Please select a pin (or press <ESC> to end)..." msgstr "" #. CSTID_ADD_LAST_VERTEX #: ../../strtbl.c:294 msgid "Add last vertex" msgstr "șÇžć€ÎÄșĆÀ€òÄÉČĂ" #. CSTID_SINGLE_PT_POLY_CONVERTED #: ../../strtbl.c:296 #, c-format msgid "Single point poly (%1d,%1d) converted to double point poly." msgstr "" #. CSTID_BAD_SMOOTHHINGE_POLY_FIXED #: ../../strtbl.c:298 msgid "Invalid poly smooth/hinge specification detected. Fixed." msgstr "" #. CSTID_CLOSE_POLYGON_SPLINE #: ../../strtbl.c:300 msgid "Close the polygon/spline" msgstr "ÀȚ€ìÀț/ÂżłŃ·Á€òÊÄ€ž€ë" #. CSTID_SNGL_PT_POLYGON_CONVERTED #: ../../strtbl.c:302 #, c-format msgid "Single point polygon (%1d,%1d) converted to 3-point point polygon." msgstr "" #. CSTID_TWO_PT_POLYGON_CONVERTED #: ../../strtbl.c:304 #, c-format msgid "Two-point polygon [%1d,%1d,%1d,%1d] converted to 3-point point polygon." msgstr "" #. CSTID_FILEVER_TOO_LARGE_FOR_RCBOX #: ../../strtbl.c:306 #, c-format msgid "Invalid file version (=%1d) for rcbox." msgstr "" #. CSTID_BAD_RCBOX_BBOX_ADJUSTED #: ../../strtbl.c:308 msgid "Bad rcbox bounding box. Adjusted." msgstr "" #. CSTID_PARANED_SEC_ELAPSED_AVG_SPEED #: ../../strtbl.c:310 #, c-format msgid "(%1d sec elapsed, avg %.2fKB/sec)" msgstr "" #. CSTID_UNZIPPING_WITH_CMD_DOTS #: ../../strtbl.c:312 #, c-format msgid "Unzipping with '%s'..." msgstr "'%s'€ÇČòĆà(unzip)Ăæ..." #. CSTID_UNCOMPRESSING_WITH_CMD_DOTS #: ../../strtbl.c:314 #, c-format msgid "Uncompressing with '%s'..." msgstr "'%s'€ÇČòĆà(uncompress)Ăæ..." #. CSTID_DATA_RECEIVED #: ../../strtbl.c:316 #, c-format msgid "%s: data received." msgstr "%s: „ÇĄŒ„ż€òŒèÆÀ€·€Ț€·€ż." #. CSTID_FORWARDING_URL_TO_URL #: ../../strtbl.c:318 #, c-format msgid "%s: forwarding '%s' to '%s'." msgstr "" #. CSTID_SCROLL_UP #: ../../strtbl.c:320 msgid "scroll up" msgstr "„脯„íĄŒ„륊„ą„Ă„Ś" #. CSTID_SCROLL_DOWN #: ../../strtbl.c:322 msgid "scroll down" msgstr "„脯„íĄŒ„륊„À„Š„ó" #. CSTID_SCROLL_PAGE_UP #: ../../strtbl.c:324 msgid "scroll page up" msgstr "„ÚĄŒ„ž€Î„脯„íĄŒ„륊„ą„Ă„Ś" #. CSTID_SCROLL_PAGE_DOWN #: ../../strtbl.c:326 msgid "scroll page down" msgstr "„ÚĄŒ„ž€Î„脯„íĄŒ„륊„À„Š„ó" #. CSTID_SCROLL_VERTICALLY #: ../../strtbl.c:328 msgid "scroll vertically" msgstr "żâÄŸÊęžț€Ë„脯„íĄŒ„ë" #. CSTID_SCROLL_HORIZONTALLY #: ../../strtbl.c:330 msgid "scroll horizontally" msgstr "żćÊżÊęžț€Ë„脯„íĄŒ„ë" #. CSTID_SCROLL_LEFT #: ../../strtbl.c:332 msgid "scroll left" msgstr "șž€Ë„脯„íĄŒ„ë" #. CSTID_SCROLL_RIGHT #: ../../strtbl.c:334 msgid "scroll right" msgstr "±Š€Ë„脯„íĄŒ„ë" #. CSTID_SCROLL_PAGE_LEFT #: ../../strtbl.c:336 msgid "scroll page left" msgstr "„ÚĄŒ„ž€òșž€Ë„脯„íĄŒ„ë" #. CSTID_SCROLL_PAGE_RIGHT #: ../../strtbl.c:338 msgid "scroll page right" msgstr "„ÚĄŒ„ž€ò±Š€Ë„脯„íĄŒ„ë" #. CSTID_CANT_FIND_ATTR_WITH_COLOR #: ../../strtbl.c:340 #, c-format msgid "Cannot find the '%s' attribute with color %s." msgstr "" #. CSTID_CANT_FIND_FILEATTR_WITH_COLOR #: ../../strtbl.c:342 #, c-format msgid "Cannot find the '%s' file attribute with color %s." msgstr "" #. CSTID_CANT_FIND_NAMED_ATTR #: ../../strtbl.c:344 #, c-format msgid "Cannot find the '%s' attribute." msgstr "" #. CSTID_CANT_FIND_INTERPRETABLE_ATTR #: ../../strtbl.c:346 msgid "Cannot find interpretable attribute." msgstr "" #. CSTID_NO_ACTION_TAKEN #: ../../strtbl.c:348 msgid "No action taken." msgstr "" #. CSTID_FAIL_READ_ICONPXMP_USE_BMP #: ../../strtbl.c:350 #, c-format msgid "Fail to read IconPixmap file: '%s'. Default icon bitmap is used." msgstr "" #. CSTID_DRAG_MOUSE_CREATE_SHAPE_DOTS #: ../../strtbl.c:352 msgid "Drag the mouse to create a shape..." msgstr "·Á€ò€Ä€Ż€ë€Ë€ÏĄą„Ț„Š„č€ò„É„é„Ă„°€·€Æ€Ż€À€”€€" #. CSTID_CREATE_A_SHAPE_ABORTED #: ../../strtbl.c:354 msgid "Create a shape aborted." msgstr "·Á€òșî€ë€Î€ÏĂæ»ß€·€Ț€·€ż" #. CSTID_INSTANTIATING_FILE_DOTS #: ../../strtbl.c:356 #, fuzzy, c-format msgid "Instantiating '%s'..." msgstr "„Ö„í„Ă„Ż„Ș„Ö„ž„§„Ż„ÈÎă..." #. CSTID_ATTR_PROMOTED_TO_NEW_SYMBOL #: ../../strtbl.c:358 msgid "Object's attributes are promoted to the new symbol object." msgstr "" #. CSTID_ATTR_PROMOTED_TO_NEW_ICON #: ../../strtbl.c:360 msgid "Object's attributes are promoted to the new icon object." msgstr "" #. CSTID_CREATING_FILE_DOTS #: ../../strtbl.c:362 #, c-format msgid "Creating '%s'..." msgstr "'%s'€òșîÀźĂæ..." #. CSTID_NAMED_FILE_CREATED #: ../../strtbl.c:364 #, c-format msgid "File '%s' created." msgstr "„Ő„Ą„€„ë '%s' €òșî€ê€Ț€·€ż" #. CSTID_WRITING_ATTR_TO_NAMED_FILE #: ../../strtbl.c:366 #, c-format msgid "Writing attributes to '%s'..." msgstr "°À­€ò'%s'€Ëœń€­čț€ó€Ç€€€Ț€č..." #. CSTID_SEMICOLON_USED_AS_SEPARATOR #: ../../strtbl.c:368 msgid "';'s are used as separators." msgstr "';'€Ï„»„Ń„ìĄŒ„ż€È€·€Æ»È€ï€ì€Æ€€€Ț€č" #. CSTID_TAB_USED_AS_SEPARATOR #: ../../strtbl.c:370 msgid "<TAB>s are used as separators." msgstr "" #. CSTID_PROCESSING_OBJ_NUMBER #: ../../strtbl.c:372 #, c-format msgid "Processing object %1d..." msgstr "„Ș„Ö„ž„§„Ż„È %1d €òœèÍęĂæ" #. CSTID_PLACING_NAMED_OBJ #: ../../strtbl.c:374 #, c-format msgid "Placing object '%s'..." msgstr "" #. CSTID_WRITING_ATTRS_IN_TBL_FORM_TO #: ../../strtbl.c:376 #, c-format msgid "Writing attributes in table form to '%s'..." msgstr "" #. CSTID_CORRUPTED_POLY_MKMULTISPLINE #: ../../strtbl.c:378 msgid "Corrupted poly in MakeMultiSplinePolyVertex()." msgstr "" #. CSTID_CORRUPTED_POLY_DMPMULTICURVE #: ../../strtbl.c:380 msgid "Corrupted poly in DumpMultiCurvedPolyPoints()." msgstr "" #. CSTID_FIX_ATTEMPTED #: ../../strtbl.c:382 msgid "Fix attempted." msgstr "" #. CSTID_PUSHING_INTO_NAMED #: ../../strtbl.c:384 #, c-format msgid "Pushing into '%s'..." msgstr "" #. CSTID_CUR_FILE_IS #: ../../strtbl.c:386 #, c-format msgid "Current file is '%s'." msgstr "žœș߀΄ՄĄ„€„ë€Ï '%s' €Ç€č." #. CSTID_DONT_KNOW_HOW_HANDLE_FRAME_CT #: ../../strtbl.c:388 #, c-format msgid "Does not know how to handle frame Content-Type: %s." msgstr "" #. CSTID_CANT_FIND_OBJ_NAME_ON_RESIZE #: ../../strtbl.c:390 #, c-format msgid "Cannot find object named '%s' any more; on_resize script not invoked." msgstr "" #. CSTID_PASTING_LINE_NUM_DOTS #: ../../strtbl.c:392 #, c-format msgid "Pasting line %1d..." msgstr "" #. CSTID_CANT_PASTE_DEL #: ../../strtbl.c:394 msgid "Cannot paste <DEL>." msgstr "" #. CSTID_CANT_PASTE_BS #: ../../strtbl.c:396 msgid "Cannot paste <BS>." msgstr "" #. CSTID_CANT_PASTE_ESC #: ../../strtbl.c:398 msgid "Cannot paste <ESC>." msgstr "" #. CSTID_CANT_PASTE_TAB_REPLACE_BY_SPC #: ../../strtbl.c:400 msgid "Cannot paste <TAB>, replaced by <SPACE>." msgstr "" #. CSTID_READING_FILE_DOTS #: ../../strtbl.c:402 #, c-format msgid "Reading '%s'..." msgstr "'%s'€òÆÉ€ßčț€ßĂæ..." #. CSTID_RETURNED_FROM_BASIC_DRIVER #: ../../strtbl.c:404 msgid "Returned from basic driver." msgstr "" #. CSTID_CACHING_BITMAP #: ../../strtbl.c:406 msgid "Caching bitmap..." msgstr "bitmap Œè€êčț€ßĂæ..." #. CSTID_FINISHED_CACHEING_BITMAP #: ../../strtbl.c:408 msgid "Finishing caching bitmap..." msgstr "bitmap Œè€êčț€ßĂæœȘλ..." #. CSTID_NEW_BMP_SIZE_IS_W_X_H #: ../../strtbl.c:410 #, c-format msgid "New bitmap size is %1dx%1d." msgstr "" #. CSTID_BLD_COLOR_TBL_FROM_PIXEL_DOTS #: ../../strtbl.c:412 msgid "Building color table from pixels..." msgstr "" #. CSTID_GENERATING_IMAGEMAP_FILE_DOTS #: ../../strtbl.c:414 msgid "Generating imagemap file..." msgstr "" #. CSTID_GENERATING_HTML_FILE_DOTS #: ../../strtbl.c:416 msgid "Generating HTML file..." msgstr "HTML„Ő„Ą„€„ë€ÎșîÀźĂæ..." #. CSTID_GENERATING_IMAGE #: ../../strtbl.c:418 msgid "Generating image..." msgstr "ČèÁüÀžÀźĂæ..." #. CSTID_FS_HALFTONE_BMP_THRESH_DOTS #: ../../strtbl.c:420 #, c-format msgid "FS halftone bitmap (threshold=%s)..." msgstr "" #. CSTID_THRESHOLD_BMP_THRESH_DOTS #: ../../strtbl.c:422 #, c-format msgid "Threshold bitmap (threshold=%s)..." msgstr "" #. CSTID_INVALID_FILEVER_FOR_XBM #: ../../strtbl.c:424 #, c-format msgid "Invalid file version (%1d) for X11 Bitmap objects." msgstr "" #. CSTID_FIELD_TOO_LONG_IN_OBJ_TRUNC #: ../../strtbl.c:426 #, c-format msgid "%s, %d: %s field too long in %s object. Truncated" msgstr "" #. CSTID_FILE_LINE_BAD_FLD_IN_OBJ_STR #: ../../strtbl.c:428 #, c-format msgid "%s, %d: Bad %s in %s object [%s]." msgstr "" #. CSTID_MALFORMED_LINE_NUM_IN_FILE #: ../../strtbl.c:430 #, c-format msgid "Malformed line %1d in '%s'." msgstr "" #. CSTID_CACHING_PIXMAP #: ../../strtbl.c:432 msgid "Caching pixmap..." msgstr "pixmao Œè€êčț€ßĂæ..." #. CSTID_FINISHED_CACHEING_PIXMAP #: ../../strtbl.c:434 msgid "Finishing caching pixmap..." msgstr "" #. CSTID_NEW_XPM_SIZE_IS_W_X_H #: ../../strtbl.c:436 #, c-format msgid "New pixmap size is %1dx%1d." msgstr "" #. CSTID_MANY_COLORS_GT_255_SKIP_XPM #: ../../strtbl.c:438 #, c-format msgid "" "Too many colors (%1d, which is > 255) in an xpm objects. This object is " "skipped during printing." msgstr "" #. CSTID_GIVEN_ADDTNL_COLOR_ALLOCATED #: ../../strtbl.c:440 #, c-format msgid "%1d additional color(s) allocated." msgstr "" #. CSTID_INVALID_FILEVER_FOR_XPM #: ../../strtbl.c:442 #, c-format msgid "Invalid file version (%1d) for X11 Pixmap objects." msgstr "" #. CSTID_COLOR_SUBS_FOR_UNRECOG_IN_XPM #: ../../strtbl.c:444 #, c-format msgid "'%s' is substituted for unrecognized colors in an X11 Pixmap object." msgstr "" #. CSTID_CONTEXT_MENU #: ../../strtbl.c:446 msgid "Context Menu" msgstr "„ł„󄯄݄č„ÈĄŠ„á„Ë„ćĄŒ" #. CSTID_GEN_TEMPLATE_HTML_FILE_DOT #: ../../strtbl.c:448 #, c-format msgid "Generating HTML file through '%s' template..." msgstr "" #. CSTID_SCALING_EVERYTHING_PAGE #: ../../strtbl.c:450 #, c-format msgid "Scaling everything for page %1d of %1d..." msgstr "" #. CSTID_SQUARE_BRACK_MODIFIED #: ../../strtbl.c:452 msgid "[Modified]" msgstr "[œ€À”€ą€ê]" #. CSTID_SQUARE_BRACK_MODIFIED_UNSAV #: ../../strtbl.c:458 msgid "[Modified/Unsavable]" msgstr "[œ€À”€ą€ê/Ì€ÊĘž]" #. CSTID_SQUARE_BRACK_UNNAMED #: ../../strtbl.c:460 msgid "[Unnamed]" msgstr "[ÌŸŸÎ€Ê€·]" #. CSTID_PARANED_EMPTY #: ../../strtbl.c:462 msgid "(Empty)" msgstr "(¶ő)" #. CSTID_OPEN_FILE #: ../../strtbl.c:464 #, c-format msgid "Open '%s'" msgstr "„Ő„Ą„€„ë %s €òł«€Ż" #. CSTID_GRID_MENU #: ../../strtbl.c:470 msgid "Grid menu" msgstr "„°„ê„Ă„ÉĄŠ„á„Ë„ćĄŒ" #. CSTID_MOVE_EDIT_TEXT_BOX #: ../../strtbl.c:472 #, fuzzy msgid "Move edit text box" msgstr "Êž»ú„”„€„ș€ÎÊÔœž..." #. CSTID_START_MOVE_EDIT_TEXT_BOX #: ../../strtbl.c:474 msgid "Start moving the edit text box" msgstr "" #. CSTID_EDIT_ATTR_IN_EDITOR #: ../../strtbl.c:476 #, c-format msgid "Edit the value of the '%s' attribute in a text editor" msgstr "„Æ„­„č„È„š„Ç„Ł„ż€Ç°À­ '%s' €ÎĂÍ€òÊÔœž" #. CSTID_GET_NAMED_PROP_FROM_SEL_OBJ #: ../../strtbl.c:478 #, c-format msgid "Get the current '%s' property from the selected object" msgstr "ÁȘÂòÂĐŸĘ€«€éžœș߀ΰÀ­ '%s' €òŒèÆÀ" #. CSTID_START_AN_EDGE_FROM_A_PORT #: ../../strtbl.c:480 msgid "start an edge from a port" msgstr "" #. CSTID_ABORT #: ../../strtbl.c:482 msgid "abort" msgstr "" #. CSTID_START_A_WIRE_FROM_NAMED_PORT #: ../../strtbl.c:484 #, c-format msgid "Start a wire from port '%s'... (Btn2 or Btn3 to abort)" msgstr "" #. CSTID_END_A_WIRE_AT_NAMED_PORT #: ../../strtbl.c:486 #, c-format msgid "End the wire at port '%s'... (press <ESC> to abort)" msgstr "" #. CSTID_SET_SIGNAME_FOR_NAMED_PORT #: ../../strtbl.c:488 #, c-format msgid "Set signal name (currently '%s') for port '%s'..." msgstr "" #. CSTID_CLK_ON_PORT_TO_RENAME_SIGNAME #: ../../strtbl.c:490 msgid "Please click on a port to rename its signal name..." msgstr "" #. CSTID_CLK_ON_PORT_TO_CLEAR_SIGNAME #: ../../strtbl.c:492 msgid "Please click on a port to clear its signal name..." msgstr "" #. CSTID_PORTNAME_TOO_LONG_SKIPPED #: ../../strtbl.c:494 #, c-format msgid "Port/pin name '%s...' too long. It is skipped in net-list generation." msgstr "" #. CSTID_CLEAR_SIGNAME_FOR_NAMED_PORT #: ../../strtbl.c:496 #, fuzzy, c-format msgid "Clear signal name (currently '%s') for port '%s'..." msgstr "„ą„€„ł„ó€ÎÌŸÁ°€òÆțÎÏ€·€Æ€Ż€À€”€€:" #. STID_CANNOT_LOAD_FONTSET #: ../../strtbl.c:545 #, c-format msgid "Cannot load fontset specified by %s.%s: '%s'." msgstr "%s.%s €Ç»ŰÄꀔ€ì€ż„Ő„©„ó„È„»„Ă„È€òÆÉ€ßčț€á€Ț€»€ó: '%s'." #. STID_CANNOT_LOAD_FONT #: ../../strtbl.c:547 #, c-format msgid "Cannot load font specified by %s.%s: '%s'." msgstr "%s.%s €Ç»ŰÄꀔ€ì€ż„Ő„©„ó„È€òÆÉ€ßčț€á€Ț€»€ó: '%s'." #. STID_CANNOT_DISTRIBUTE_LOCKED_OBJS #: ../../strtbl.c:549 msgid "Cannot distribute with locked objects." msgstr "" #. STID_VERTICES_HORI_APART #: ../../strtbl.c:551 #, c-format msgid "Vertices are %1d pixels apart horizontally." msgstr "" #. STID_VERTICES_VERT_APART #: ../../strtbl.c:553 #, c-format msgid "Vertices are %1d pixels apart vertically." msgstr "" #. STID_LEFT_SIDES_APART #: ../../strtbl.c:555 #, c-format msgid "Left sides of objects are %1d pixels apart." msgstr "" #. STID_CENTERS_APART #: ../../strtbl.c:557 #, c-format msgid "Center of objects are %1d pixels apart." msgstr "" #. STID_RIGHT_SIDES_APART #: ../../strtbl.c:559 #, c-format msgid "Right sides of objects are %1d pixels apart." msgstr "" #. STID_SPACED_APART_HORI #: ../../strtbl.c:561 #, c-format msgid "Objects are spaced %1d pixels apart horizontally." msgstr "" #. STID_TOP_SIDES_APART #: ../../strtbl.c:563 #, c-format msgid "Top sides of objects are %1d pixels apart." msgstr "" #. STID_MIDDLES_APART #: ../../strtbl.c:565 #, c-format msgid "Middles of objects are %1d pixels apart." msgstr "" #. STID_BOTTOM_SIDES_APART #: ../../strtbl.c:567 #, c-format msgid "Bottom sides of objects are %1d pixels apart." msgstr "" #. STID_SPACED_APART_VERT #: ../../strtbl.c:569 #, c-format msgid "Objects are spaced %1d pixels apart vertically." msgstr "" #. STID_DISTR_VERTEX_HORI #: ../../strtbl.c:571 msgid "" "Distribute selected vertices so that they are spaced equally horizontally" msgstr "" #. STID_DISTR_VERTEX_VERT #: ../../strtbl.c:573 msgid "Distribute selected vertices so that they are spaced equally vertically" msgstr "" #. STID_DISTR_VERTEX_VERT_AND_HORI #: ../../strtbl.c:575 msgid "" "Distribute selected vertices so that they are spaced equally horizontally " "and vertically" msgstr "" #. STID_MOVE_ALL_VERTICES_YNC #: ../../strtbl.c:577 msgid "Okay to move all vertices to one point? [ync](y)" msgstr "" #. STID_CANNOT_ALIGN_OBJS_TOO_MANY #: ../../strtbl.c:579 msgid "Cannot align objects. Too many objects locked." msgstr "" #. STID_ALIGN_VERTICES_HORI_TO_GRID #: ../../strtbl.c:581 msgid "Align selected vertices horizontally to the grid" msgstr "ÁȘÂò€·€żÄșĆÀ€òżćÊżÊęžț€Ë„°„ê„Äɀˀą€ï€»€ë" #. STID_ALIGN_VERTICES_VERT_TO_GRID #: ../../strtbl.c:583 msgid "Align selected vertices vertically to the grid" msgstr "ÁȘÂò€·€żÄșĆÀ€òżâÄŸÊęžț€Ë„°„ê„Äɀˀą€ï€»€ë" #. STID_ALIGN_VERTICES_HORI #: ../../strtbl.c:585 msgid "Align selected vertices horizontally" msgstr "ÁȘÂò€·€żÄșĆÀ€òżćÊżÊęžț€ËÀ°Îó" #. STID_ALIGN_VERTICES_VERT #: ../../strtbl.c:587 msgid "Align selected vertices vertically" msgstr "ÁȘÂò€·€żÄșĆÀ€òżâÄŸÊęžț€ËÀ°Îó" #. STID_ALIGN_VERTICES_TO_GRID #: ../../strtbl.c:589 msgid "Align selected vertices to the grid" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„°„ê„Äɀˀą€ï€»€ë" #. STID_ALIGN_VERTICES #: ../../strtbl.c:591 msgid "Align selected vertices" msgstr "ÁȘÂò€·€żÄșĆÀ€ÎÀ°Îó" #. STID_SELECT_ONE_POLY_ONE_NON_POLY #: ../../strtbl.c:593 msgid "Please select one polyline and one non-polyline object." msgstr "" #. STID_CANNOT_MOVE_A_VERTEX_LOCKED #: ../../strtbl.c:595 msgid "Cannot move a vertex for a locked polyline object." msgstr "" #. STID_SELECT_ONLY_ONE_POLY #: ../../strtbl.c:597 msgid "Please select only one POLY object." msgstr "ÂżłŃ·Á€Î„Ș„Ö„ž„§„Ż„È€ò°ì€Ä€À€±ÁȘÂò€·€Æ€Ż€À€”€€" #. STID_NO_ARC_CREATED #: ../../strtbl.c:599 msgid "No arc created." msgstr "±ßžÌ€Ïșî€é€ì€Ț€»€ó€Ç€·€ż" #. STID_INVALID_ARC_VERSION #: ../../strtbl.c:601 #, c-format msgid "Invalid arc version (%1d)." msgstr "" #. STID_WARN_INCONSIST_ARC_DIR #: ../../strtbl.c:603 msgid "Warning: Inconsistent arc direction. Corrected." msgstr "" #. STID_ARC_SPEC #: ../../strtbl.c:605 msgid "Please enter an arc specification: [radius,dir(+/-),theta1,theta2]" msgstr "" #. STID_INVALID_ARC_SPEC_RADIUS #: ../../strtbl.c:607 #, c-format msgid "Invalid radius in arc specification '%s'." msgstr "" #. STID_INVALID_ARC_SPEC_DIR #: ../../strtbl.c:609 #, c-format msgid "Invalid direction in arc specification '%s'." msgstr "" #. STID_INVALID_ARC_SPEC_THETA1 #: ../../strtbl.c:611 #, c-format msgid "Invalid theta1 in arc specification '%s'." msgstr "" #. STID_SELECT_AT_LEAST_ONE_TEXT #: ../../strtbl.c:613 msgid "Must select at least one text object." msgstr "ŸŻ€Ê€Ż€È€â°ì€Ä€Î„Æ„­„č„È€òÁȘÂò€·€ż€·€Ê€±€ì€Đ€Ê€ê€Ț€»€ó" #. STID_MORE_THAN_ONE_NON_TEXT #: ../../strtbl.c:615 msgid "More than one non-text objects selected." msgstr "„Æ„­„č„Ȁǀʀ€„Ș„Ö„ž„§„Ż„È€òŸŻ€Ê€Ż€È€â°ì€ÄÁȘÂò€·€Ê€±€ì€Đ€Ê€ê€Ț€»€ó" #. STID_NO_TEXT_SELECTED_ADD_ATTRS #: ../../strtbl.c:617 msgid "No text objects selected to add as attributes." msgstr "" #. STID_NO_NON_TEXT_SELECTED #: ../../strtbl.c:619 msgid "No objects (other than TEXT objects) selected." msgstr "(„Æ„Ż„č„È„Ș„Ö„ž„§„Ż„È°Êł°€Î)„Ș„Ö„ž„§„Ż„È€ŹÁȘÂò€”€ì€Æ€Ț€»€ó." #. STID_TEXT_ATTACHED #: ../../strtbl.c:621 #, fuzzy msgid "Text object(s) attached." msgstr "„Æ„­„č„È€òłÈÂçœÌŸźČĀˀč€ë" #. STID_TEXT_UNLOCKED_AND_ATTACHED #: ../../strtbl.c:623 msgid "Text object(s) unlocked and attached." msgstr "" #. STID_UNEXPECTED_EOF_IN_ABORT_READ #: ../../strtbl.c:625 #, c-format msgid "%s, %d: Unexpected EOF in %s. Read aborted." msgstr "" #. STID_STRING_LEN_EXCEEDS_AND_TRUNC #: ../../strtbl.c:627 #, c-format msgid "String length exceeds %1d. String is truncated." msgstr "" #. STID_MOVE_ONE_ATTR_MOUSE_MSG #: ../../strtbl.c:629 msgid "LEFT--show and move. MIDDLE--toggle name shown. RIGHT--hide attr." msgstr "" #. STID_CANNOT_MOVE_ATTR_IF_LOCKED #: ../../strtbl.c:631 #, fuzzy msgid "Cannot move attributes of locked object." msgstr "„í„Ă„Ż€”€ì€ż„Ș„Ö„ž„§„Ż„È€Î°À­" #. STID_SHOW_MOVE_ATTR #: ../../strtbl.c:633 msgid "Show/move an attribute" msgstr "°À­€òÉœŒš/°Üư" #. STID_TOGGLE_NAME_SHOWN #: ../../strtbl.c:635 msgid "Toggle name shown" msgstr "" #. STID_HIDE_ATTR #: ../../strtbl.c:637 msgid "Hide an attribute" msgstr "°À­€ò±Ł€č" #. STID_CHANGE_ATTR_JUST_MOUSE_MSG #: ../../strtbl.c:639 msgid "LEFT--left justify. MIDDLE--center justify. RIGHT--right justify." msgstr "" #. STID_LEFT_JUSTIFY #: ../../strtbl.c:641 #, fuzzy msgid "Left justify an attribute" msgstr "„Æ„­„č„È€òșž€Ë€œ€í€š€ë" #. STID_CENTER_JUSTIFY #: ../../strtbl.c:643 #, fuzzy msgid "Center justify an attribute" msgstr "„Æ„­„č„È€òĂæ±û€Ë€œ€í€š€ë" #. STID_RIGHT_JUSTIFY #: ../../strtbl.c:645 #, fuzzy msgid "Right justify an attribute" msgstr "„Æ„­„č„È€ò±Š€Ë€œ€í€š€ë" #. STID_SELECT_ONLY_ONE_OBJ #: ../../strtbl.c:647 msgid "Please select only ONE object." msgstr "„Ș„Ö„ž„§„Ż„È€Ï°ì€Ä€À€±ÁȘÂò€·€Æ€Ż€À€”€€" #. STID_SELECT_HAS_NO_ATTR #: ../../strtbl.c:649 msgid "Selected object currently has NO attributes." msgstr "" #. STID_DRAG_LEFT_BTN_TO_SEE_ATTR #: ../../strtbl.c:651 msgid "Drag left button to see attributes." msgstr "" #. STID_CHANGE_ATTR_JUST #: ../../strtbl.c:653 msgid "Change an attribute justification" msgstr "" #. STID_IS_ATTR_OBSOLETE_FOR_ICON_YNC #: ../../strtbl.c:655 #, c-format msgid "Is the attribute '%s' obsolete for icon '%s'? [yn](y)" msgstr "" #. STID_BAD_FORMAT_IN_SHORTCUT_SPEC #: ../../strtbl.c:657 msgid "Invalid format in shortcut specification." msgstr "" #. STID_CANNOT_FIND_NAMED_ATTR #: ../../strtbl.c:659 #, c-format msgid "Cannot find a '%s' attribute for the selected object." msgstr "ÁȘÂòÂĐŸĘ€Î°À­ '%s' €Źž«ÉŐ€«€ê€Ț€»€ó" #. STID_ATTACH_FILE_ATTRS_IN_WB #: ../../strtbl.c:661 msgid "AttachFileAttrs() is disabled in WhiteBoard mode." msgstr "" #. STID_CANNOT_ATTACH_NON_TEXT_OBJ #: ../../strtbl.c:663 msgid "Cannot attach non-text objects." msgstr "" #. STID_DETACH_FILE_ATTRS_IN_WB #: ../../strtbl.c:665 msgid "DetachFileAttrs() is disabled in WhiteBoard mode." msgstr "" #. STID_FILE_CONTAINS_NO_ATTRS #: ../../strtbl.c:667 msgid "Current file contains no attributes." msgstr "žœș߀΄ՄĄ„€„ë€Ï°À­€òŽȚ€ó€Ç€€€Ț€»€ó" #. STID_SHOW_ATTR_NAME_AND_VALUE #: ../../strtbl.c:669 #, c-format msgid "Will show both the name and the value for the '%s' attribute." msgstr "" #. STID_SHOW_ATTR_VALUE_ONLY #: ../../strtbl.c:671 #, c-format msgid "Will only show the value of the '%s' attribute." msgstr "" #. STID_NOT_SHOW_ATTR #: ../../strtbl.c:673 #, c-format msgid "Will not show the '%s' attribute." msgstr "" #. STID_SHOW_ATTR #: ../../strtbl.c:675 #, c-format msgid "Will show the '%s' attribute." msgstr "" #. STID_WONT_SHOW_VALUE #: ../../strtbl.c:677 #, c-format msgid "Will not show the '%s' value." msgstr "" #. STID_TGIF_EDIT_ATTR_NAMES #: ../../strtbl.c:679 #, c-format msgid "%s - Edit Attribute Names" msgstr "%s - °À­ÌŸ€òÊÔœž€č€ë" #. STID_EDIT_FILE_ATTRS_IN_WB #: ../../strtbl.c:681 msgid "EditFileAttrs() is disabled in WhiteBoard mode." msgstr "" #. STID_FILE_ATTRS_UPDATED #: ../../strtbl.c:685 msgid "File attribute(s) updated." msgstr "„Ő„Ą„€„ë°À­„”„Ö„á„Ë„ćĄŒ >>>" #. STID_SELECT_ONE_OBJ_FOR_EDITATTRS #: ../../strtbl.c:687 msgid "Must select only one object for EditAttrs()." msgstr "" #. STID_OBJ_CONTAINS_NO_ATTRS #: ../../strtbl.c:689 msgid "Selected object contains no attributes." msgstr "ÁȘÂò„Ș„Ö„ž„§„Ż„È€Ï°À­€òŽȚ€ó€Ç€€€Ț€»€ó" #. STID_EDIT_OBJ_ATTRS_DOTS #: ../../strtbl.c:691 msgid "Edit Object Attributes (show/hide, name shown)..." msgstr "" #. STID_OBJ_ATTRS_UPDATED #: ../../strtbl.c:693 msgid "Object attribute(s) updated." msgstr "" #. STID_INPUT_OCTAL_STR #: ../../strtbl.c:695 #, c-format msgid "Please input an octal string (e.g., \"%s\"):" msgstr "" #. STID_INPUT_STR #: ../../strtbl.c:697 msgid "Please input a string:" msgstr "" #. STID_WARN_PRINT_COURIER_IN_COLOR #: ../../strtbl.c:699 msgid "Warning: Printing Courier fonts with non-solid pen in color." msgstr "" #. STID_MAY_CAUSE_ERROR_IN_PRINTOUT #: ../../strtbl.c:701 msgid " This may cause error in the printout." msgstr "" #. STID_BAD_OCTAL_STRING_ENCOUNTERED #: ../../strtbl.c:703 #, c-format msgid "Bad octal string \\%c%c%c encountered." msgstr "" #. STID_SERVER_NOT_STARTED #: ../../strtbl.c:705 msgid "Server not started." msgstr "" #. STID_INVISIBLE_COLOR_SELECTED_YNC #: ../../strtbl.c:707 #, c-format msgid "" "Invisible color #%1d (%s) is selected for drawing.\n" "\n" "Would you like to make the color visible?" msgstr "" #. STID_COLOR_IS_CURRENTLY_INVISIBLE #: ../../strtbl.c:709 #, c-format msgid "Color %1d (%s) is currently invisible." msgstr "" #. STID_COLOR_SET_TO #: ../../strtbl.c:711 #, c-format msgid "Color set to '%s'." msgstr "ż§€ò '%s' €Ë€·€Ț€·€ż" #. STID_TEXT_VSPACE_TOO_SMALL_RESET_0 #: ../../strtbl.c:713 msgid "" "Text vertical spacing too small.\n" "\n" "It is reset to 0." msgstr "" #. STID_FONT_AND_SIZE_NOT_AVAILABLE #: ../../strtbl.c:715 #, c-format msgid "%s-%1d not available." msgstr "" #. STID_LINE_WIDTH_SET_TO #: ../../strtbl.c:717 ../../strtbl.c:2531 #, c-format msgid "Line width set to %s." msgstr "Àț€ÎÂÀ€”€ò %s €Ë€·€Ț€·€ż" #. STID_LINE_TYPE_IS_STRAIGHT #: ../../strtbl.c:719 msgid "Line type is 'straight'." msgstr "Àț€Î„ż„€„Ś€Ï 'ÄŸÀț'€Ç€č." #. STID_LINE_TYPE_IS_SPLINE #: ../../strtbl.c:721 msgid "Line type is 'spline'." msgstr "Àț€Î„ż„€„Ś€Ï '„脌„é„€„ó'€Ç€č." #. STID_LINE_TYPE_IS_INTSPLINE #: ../../strtbl.c:723 msgid "Line type is 'interpolated spline'." msgstr "Àț€Î„ż„€„Ś€Ï'ÆâÁȚ€”€ì€ż„脌„é„€„ó'€Ç€č" #. STID_TAB_FOR_FILE_COMPLETION #: ../../strtbl.c:725 msgid "Type <TAB> for file completion..." msgstr "„Ő„Ą„€„ëÌŸ€ÎÊäŽÖ€Ë€Ï <TAB> €òČĄ€·€Æ€Ż€À€”€€..." #. STID_FAIL_TO_CREATE_WINDOW #: ../../strtbl.c:727 msgid "Fail to create a window." msgstr "„Єلó„ɄЀÎșîÀźŒșÇÔ" #. STID_FAIL_TO_CREATE_NAMED_WINDOW #: ../../strtbl.c:729 #, c-format msgid "Fail to create the %s window." msgstr "„Єلó„ɄР%s €ÎșîÀźŒșÇÔ" #. STID_UNDO_REDO_MAY_CAUSE_CRASH #: ../../strtbl.c:731 msgid "Further Undo()/Redo() may cause crashes." msgstr "€ł€ì°ÊŸć Undo()/Redo() €č€ë€ÈĄą„Ż„é„Ă„·„ć€č€ë€«€â€·€ì€Ț€»€ó" #. STID_UNDO_IN_WB #: ../../strtbl.c:733 msgid "Undo() is disabled in WhiteBoard mode." msgstr "" #. STID_NO_COMMANDS_TO_UNDO #: ../../strtbl.c:735 msgid "No commands to Undo." msgstr "Undo €Î„ł„Ț„ó„É€Źž«ÉŐ€«€ê€Ț€»€ó" #. STID_REDO_IN_WB #: ../../strtbl.c:737 msgid "Redo() is disabled in WhiteBoard mode." msgstr "" #. STID_NO_COMMANDS_TO_REDO #: ../../strtbl.c:739 msgid "No commands to Redo." msgstr "Redo €Î„ł„Ț„ó„É€Źž«ÉŐ€«€ê€Ț€»€ó" #. STID_SELECT_LIST_NOT_SORTED_IN #: ../../strtbl.c:741 #, c-format msgid "Select list not sorted in %s." msgstr "" #. STID_WARN_CANNOT_PARSE_NAMED_COLOR #: ../../strtbl.c:743 #, c-format msgid "Warning: Cannot parse color '%s'." msgstr "·Ùčđ: ż§ '%s' €ò„ÚĄŒ„č„Ȁǀ­€Ț€»€ó." #. STID_CANNOT_ALLOC_NAMED_COLOR #: ../../strtbl.c:749 #, c-format msgid "Warning: Cannot allocate color '%s'." msgstr "·Ùčđ: ż§ '%s' €òłä€êĆö€Æ€é€ì€Ț€»€ó." #. STID_CANNOT_BREAKUP_EPS #: ../../strtbl.c:751 msgid "Cannot break up an EPS object." msgstr "" #. STID_INVALID_FILE_IN_X_DEFAULT #: ../../strtbl.c:753 #, c-format msgid "Invalid file '%s' specified by X default %s.%s." msgstr "" #. STID_INVALID_XDEF_COLORXPM_GET #: ../../strtbl.c:755 #, c-format msgid "Invalid %s.%s: '%s' - Fail to get colors. Resource ignored." msgstr "" #. STID_INVALID_XDEF_COLORXPM_TRANS #: ../../strtbl.c:757 #, c-format msgid "" "Invalid %s.%s: '%s' - Transparent color is not allowed. Resource ignored." msgstr "" #. STID_FAIL_ALLOC_EDIT_TEXT_BGCOLOR #: ../../strtbl.c:759 #, fuzzy, c-format msgid "" "Fail to allocate the '%s' background color for use in editing existing text " "objects." msgstr "ÊÔœžĂæ€ÎÊž»ú„Ș„Ö„ž„§„Ż„È€ÎÇŰ·Êż§€ò»È€Š" #. STID_FAIL_ALLOC_EDIT_TEXT_HICOLOR #: ../../strtbl.c:761 #, fuzzy, c-format msgid "" "Fail to allocate the '%s' highlight color for use in editing existing text " "objects" msgstr "ÊÔœžĂæ€ÎÊž»ú„Ș„Ö„ž„§„Ż„È€Î„Ï„€„é„€„È„«„éĄŒ€òÀßÄê€č€ë" #. STID_FAIL_ALLOC_DEF_BGCOLOR #: ../../strtbl.c:763 #, c-format msgid "Fail to allocate the default background color: '%s'." msgstr "" #. STID_INVALID_XDEF_USE_ALT_VALUE #: ../../strtbl.c:765 #, c-format msgid "Invalid %s.%s: '%s', %1d is used instead." msgstr "" #. STID_NORM_VIDEO_MODE_ASSUMED #: ../../strtbl.c:767 #, c-format msgid "Normal video mode assumed since %s is specified in the command line." msgstr "" #. STID_ZERO_COLORS_SPECIFIED #: ../../strtbl.c:769 msgid "0 colors specified (must be at least 1)." msgstr "" #. STID_CANNOT_GET_X_DEFAULT #: ../../strtbl.c:771 #, c-format msgid "Cannot get X default %s.%s." msgstr "" #. STID_INVALID_XDEF_WILL_TRY_STR #: ../../strtbl.c:773 #, c-format msgid "Invalid %s.%s: '%s'. Will try '%s'." msgstr "" #. STID_FAIL_TO_ALLOC_3D_COLORS #: ../../strtbl.c:775 msgid "Fail to allocate colors for 3DLook." msgstr "" #. STID_FAIL_TO_ALLOC_COLOR_NUM #: ../../strtbl.c:777 #, c-format msgid "Fail to allocate color number %1d: '%s'. %s is aborted." msgstr "" #. STID_DEFCOLORINDEX_GE_MAXCOLORS #: ../../strtbl.c:779 #, c-format msgid "Warning: %s.%s >= %s.%s. Use 0 for %s.%s." msgstr "" #. STID_FAIL_ALLOC_NAMED_COLOR_ABORT #: ../../strtbl.c:781 #, c-format msgid "Fail to allocate the '%s' color. Abort." msgstr "" #. STID_FAIL_ALLOC_COLOR_NUM_ABORT #: ../../strtbl.c:783 #, c-format msgid "Fail to allocate color number %1d: '%s'. Abort." msgstr "" #. STID_UNEXPECTED_MAX_RGB_ZERO #: ../../strtbl.c:785 msgid "Warning: Unexpected maximum RGB intensity of 0." msgstr "" #. STID_FG_BG_SAME_COLOR_WARNING #: ../../strtbl.c:787 msgid "" "Warning: Foreground and background colors are the same. You may not be able " "to see much." msgstr "" #. STID_CANNOT_SET_FG_COLOR #: ../../strtbl.c:789 #, c-format msgid "" "Warning: Cannot set the foreground color to '%s'. The default color '%s' is " "used." msgstr "" #. STID_INVISIBLE_COLOR_SELECTED #: ../../strtbl.c:791 #, c-format msgid "Invisible color #%1d (%s) is selected for drawing." msgstr "" #. STID_ALL_COLOR_LAYERS_VISIBLE #: ../../strtbl.c:793 msgid "All color layers are now visible." msgstr "" #. STID_ALL_COLOR_LAYERS_INVISIBLE #: ../../strtbl.c:795 msgid "All color layers are now invisible." msgstr "" #. STID_A_COLOR_LAYER_TURNED_ON #: ../../strtbl.c:797 #, c-format msgid "Color '%s' (layer %1d) is turned on." msgstr "" #. STID_A_COLOR_LAYER_TURNED_OFF #: ../../strtbl.c:799 #, c-format msgid "Color '%s' (layer %1d) is turned off." msgstr "" #. STID_TURN_COLOR_LAYER_NUM_ON #: ../../strtbl.c:801 #, c-format msgid "Turn color '%s' (layer %1d) on" msgstr "" #. STID_TURN_COLOR_LAYER_NUM_OFF #: ../../strtbl.c:803 #, c-format msgid "Turn color '%s' (layer %1d) off" msgstr "" #. STID_COLORMAP_NOT_RESETED #: ../../strtbl.c:805 msgid "Colormap not reseted due to the DONT_FREE_COLORMAP compile flag." msgstr "" #. STID_ADDCOLOR_FOR_BW_DPY #: ../../strtbl.c:807 msgid "Adding color is not available for a black and white display." msgstr "" #. STID_ENTER_COLORS_TO_ADD #: ../../strtbl.c:809 msgid "Please enter colors to add:" msgstr "ÄÉČĂ€č€ëż§€òÆțÎÏ€·€Æ€Ż€À€”€€:" #. STID_FAIL_ALLOC_NAMED_COLOR #: ../../strtbl.c:811 #, c-format msgid "Fail to allocate the '%s' color." msgstr "" #. STID_ENTER_EDIT_BG_COLOR #: ../../strtbl.c:813 #, c-format msgid "" "Please enter the background color to be used in editing existing a text " "object when UseAltEditTextBgColor is selected (please enter 'NONE' to remove)" ": [current - %s]" msgstr "" #. STID_ENTER_EDIT_HILIGHT_COLOR #: ../../strtbl.c:815 #, c-format msgid "" "Please enter the highlight color to be used in editing existing a text " "object when UseAltEditTextBgColor is selected (please enter 'NONE' to remove)" ": [current - %s]" msgstr "" #. STID_COLOR_LAYERS_ENABLED #: ../../strtbl.c:817 msgid "Color layers enabled." msgstr "„«„éĄŒ„ì„€„ä€òÍ­žú€Ë" #. STID_COLOR_LAYERS_DISABLED #: ../../strtbl.c:819 msgid "Color layers disabled." msgstr "„«„éĄŒ„ì„€„ä€òÌ”žú€Ë" #. STID_TOO_MANY_LINES_IN_COLORINFO #: ../../strtbl.c:821 msgid "Warning: Too many lines in color_info." msgstr "" #. STID_WAIT_FOR_START_CONV #: ../../strtbl.c:823 msgid "Waiting for start of input conversion." msgstr "" #. STID_NO_NAMED_SELECTION_OWNER #: ../../strtbl.c:825 #, c-format msgid "There is no Selection Owner of %s." msgstr "" #. STID_FAIL_TO_CHANGE_CONV_PROP #: ../../strtbl.c:827 msgid "Fail to change conversion property." msgstr "" #. STID_FAIL_TO_INTERN_NAMED_ATOM #: ../../strtbl.c:829 #, c-format msgid "Fail to intern the '%s' atom." msgstr "" #. STID_FAIL_TO_CONNECT_TO_OWNER #: ../../strtbl.c:831 msgid "Fail to connect to selection owner." msgstr "" #. STID_FAIL_TO_GET_WIN_PROP #: ../../strtbl.c:833 msgid "Cannot get window property." msgstr "" #. STID_FAIL_TO_DISCONNECT_FROM_OWNER #: ../../strtbl.c:835 msgid "Fail to disconnect from selection owner." msgstr "" #. STID_LOCALE_IS #: ../../strtbl.c:837 #, c-format msgid "Locale is '%s'." msgstr "" #. STID_MODIFIER_IS #: ../../strtbl.c:839 #, c-format msgid "Modifier is '%s'." msgstr "" #. STID_CANNOT_OPEN_XIM #: ../../strtbl.c:841 msgid "Cannot open the X Input Method." msgstr "" #. STID_OVERTHESPOT_CONV #: ../../strtbl.c:843 msgid "OverTheSpot conversion." msgstr "" #. STID_ROOT_CONV #: ../../strtbl.c:845 msgid "Root conversion." msgstr "" #. STID_IM_NOT_SUPPORT_ANY_STYLE #: ../../strtbl.c:847 msgid "" "This X Input Method does not support either the 'Root' or the 'OverTheSpot' " "input style." msgstr "" #. STID_FAIL_TO_CREATE_INPUTCONTEXT #: ../../strtbl.c:849 msgid "Fail to create InputContext." msgstr "" #. STID_OPEN_XIM #: ../../strtbl.c:851 msgid "Open X Input Method." msgstr "" #. STID_CLOSE_XIM #: ../../strtbl.c:853 msgid "Close X Input Method." msgstr "" #. STID_INVALID_XDEF_USE_ALT_STR #: ../../strtbl.c:855 #, c-format msgid "Invalid %s.%s: '%s', '%s' is used instead." msgstr "" #. STID_NO_OBJ_SELECTED_FOR_COPY #: ../../strtbl.c:857 msgid "No object selected for the COPY operation." msgstr "" #. STID_CANNOT_OPEN_FILE_FOR_WRITING #: ../../strtbl.c:859 #, c-format msgid "Cannot open '%s' for writing." msgstr "" #. STID_CANNOT_OPEN_FILE_FOR_READING #: ../../strtbl.c:861 #, c-format msgid "Cannot open '%s' for reading." msgstr "" #. STID_FAIL_TO_FSTAT_ABORT_COPY #: ../../strtbl.c:863 #, c-format msgid "Fail to fstat() '%s'. Copy aborted." msgstr "" #. STID_ERR_READING_FILE_COPY_ABORT #: ../../strtbl.c:865 #, c-format msgid "Error reading from '%s'. Copy aborted." msgstr "" #. STID_COPY_FAILED_OBJ_MAYBE_TOO_BIG #: ../../strtbl.c:867 msgid "Copy to cut buffer failed. Selected object(s) may be too big." msgstr "" #. STID_COPY_BUFFER_UPDATED #: ../../strtbl.c:869 msgid "Copy buffer updated." msgstr "" #. STID_ESC_KEY_PRESS_IGNORED #: ../../strtbl.c:871 ../../strtbl.c:2925 msgid "An <ESC> key press is ignored." msgstr "" #. STID_CUT_BUFFER_EMPTY #: ../../strtbl.c:873 msgid "The cut buffer is empty." msgstr "" #. STID_STR_EXCEEDS_NUM_CH_IGNORED #: ../../strtbl.c:875 #, c-format msgid "String length exceeds %1d. Character is ignored." msgstr "" #. STID_PASTE_FROM_NON_TGIF #: ../../strtbl.c:877 msgid "Paste from a non-tgif tool." msgstr "" #. STID_ERR_WRITING_FILE_PASTE_ABORT #: ../../strtbl.c:879 #, c-format msgid "Error writing to '%s'. Paste aborted." msgstr "" #. STID_FILEVER_TOO_LARGE_PASTE_ABORT #: ../../strtbl.c:881 #, c-format msgid "File version too large (=%1d). Paste aborted." msgstr "" #. STID_CANNOT_PASTE_MIXED_TEXT #: ../../strtbl.c:883 msgid "Cannot paste mixed text at the current cursor position." msgstr "" #. STID_STR_BLOCKS_PASTED_FROM_TGIF #: ../../strtbl.c:885 msgid "String blocks pasted from tgif." msgstr "" #. STID_OBJS_PASTED_FROM_TGIF #: ../../strtbl.c:887 msgid "Objects pasted from tgif." msgstr "" #. STID_SEL_A_FILE_TO_PASTE_DOTS #: ../../strtbl.c:889 msgid "Please select a file to PASTE..." msgstr "„ÚĄŒ„č„È€Ë»È€Š„Ő„Ą„€„ë€òÁȘÂò€·€Æ€Ż€À€”€€..." #. STID_PASTING_REMOTE_FILE_NOT_SUP #: ../../strtbl.c:891 msgid "Pasting remote file not supported." msgstr "" #. STID_NAMED_FILE_IS_EMPTY #: ../../strtbl.c:893 #, c-format msgid "File '%s' is empty." msgstr "" #. STID_CANNOT_MALLOC_NUM_BYTES #: ../../strtbl.c:895 #, c-format msgid "Cannot malloc %1d bytes." msgstr "" #. STID_NO_PRIMARY_SELECTION_OWNER #: ../../strtbl.c:897 msgid "There is no selection owner of PRIMARY." msgstr "" #. STID_CONVERTING_GIVEN_DOTS #: ../../strtbl.c:899 #, c-format msgid "Converting %s..." msgstr "%s €òÊŃŽč..." #. STID_TIMEOUT_CONVERT_GIVEN #: ../../strtbl.c:901 #, c-format msgid "Timeout occurred when attempting to convert %s." msgstr "" #. STID_PROBLEM_CONVERT_GIVEN #: ../../strtbl.c:903 #, c-format msgid "Problem encountered when converting %s." msgstr "" #. STID_PASTE_COMP_TEXT_FROM_NON_TGIF #: ../../strtbl.c:905 msgid "Paste compound-text from a non-tgif tool." msgstr "" #. STID_CANNOT_FIND_SIZE_USE_ALT #: ../../strtbl.c:907 #, c-format msgid "Cannot find font size '%1d'. %1d is used instead." msgstr "" #. STID_CANNOT_FIND_FONT_USE_ALT #: ../../strtbl.c:909 #, c-format msgid "Cannot find screen font for '%s'. '%s' font is used instead." msgstr "" #. STID_CANNOT_PASTE_COMPOUND_OBJ #: ../../strtbl.c:911 #, c-format msgid "" "Cannot paste '%s' for compound objects. Therefore, '%s' cannot be selected." msgstr "" #. STID_CUT_BUF_HAS_NON_ROT_COMP #: ../../strtbl.c:913 #, c-format msgid "" "The '%s' in the cut buffer contains non-rotational components. Text " "rotation of 0 degree is used." msgstr "" #. STID_NO_PROPERTY_TO_PASTE #: ../../strtbl.c:915 msgid "No property to paste." msgstr "" #. STID_NO_PROPERTY_TO_COPY #: ../../strtbl.c:917 msgid "No property to copy." msgstr "" #. STID_INVALID_KEY_IN_SEC_OF_INIFILE #: ../../strtbl.c:919 #, c-format msgid "Invalid key: '%s' in the [%s] section of '%s'." msgstr "" #. STID_ENTER_NAME_FOR_PROP_SET #: ../../strtbl.c:921 msgid "Please enter a name for the property set." msgstr "" #. STID_PROP_SET_EXISTS_OVERWRITE_YNC #: ../../strtbl.c:923 #, c-format msgid "Property set [%s] already exists. Okay to overwrite?" msgstr "" #. STID_NO_PROP_TO_SAVE #: ../../strtbl.c:925 msgid "No property to save." msgstr "" #. STID_WILL_COPY_NAMED_PROP #: ../../strtbl.c:927 #, c-format msgid "Will copy the '%s' property." msgstr "" #. STID_WILL_NOT_COPY_NAMED_PROP #: ../../strtbl.c:929 #, c-format msgid "Will not copy the '%s' property." msgstr "" #. STID_WILL_SAVE_NAMED_PROP #: ../../strtbl.c:931 #, c-format msgid "Will save the '%s' property." msgstr "" #. STID_WILL_NOT_SAVE_NAMED_PROP #: ../../strtbl.c:933 #, c-format msgid "Will not save the '%s' property." msgstr "" #. STID_WILL_PASTE_NAMED_PROP #: ../../strtbl.c:935 #, c-format msgid "Will paste the '%s' property." msgstr "" #. STID_WILL_NOT_PASTE_NAMED_PROP #: ../../strtbl.c:937 #, c-format msgid "Will not paste the '%s' property." msgstr "" #. STID_WILL_RESTORE_NAMED_PROP #: ../../strtbl.c:939 #, c-format msgid "Will restore the '%s' property." msgstr "" #. STID_WILL_NOT_RESTORE_NAMED_PROP #: ../../strtbl.c:941 #, c-format msgid "Will not restore the '%s' property." msgstr "" #. STID_TOOL_COPY_PROP #: ../../strtbl.c:943 #, c-format msgid "%s - Copy Properties" msgstr "%s - „ł„ÔĄŒ€Î°À­ÀßÄê" #. STID_TOOL_SAVE_PROP #: ../../strtbl.c:945 #, c-format msgid "%s - Save Properties" msgstr "%s - ÊĘž€Î°À­" #. STID_TOOL_PASTE_PROP #: ../../strtbl.c:947 #, c-format msgid "%s - Paste Properties" msgstr "%s - „ÚĄŒ„č„È€ÎÀßÄê" #. STID_TOOL_RESTORE_PROP #: ../../strtbl.c:953 #, c-format msgid "%s - Restore Properties" msgstr "" #. STID_SEL_ONLY_ONE_FOR_COPY_PROP #: ../../strtbl.c:955 msgid "Please select only one object for CopyProperties()." msgstr "" #. STID_SEL_ONLY_ONE_FOR_SAVE_PROP #: ../../strtbl.c:957 msgid "Please select only one object for SaveProperties()." msgstr "" #. STID_UNCHECK_PROP_FOR_COPY_DOTS #: ../../strtbl.c:959 msgid "Please uncheck properties you don't want to copy..." msgstr "„ł„ÔĄŒ€·€ż€Ż€Ê€€Â°À­€Î„Á„§„Ă„Ż€ò€Ï€ș€·€Æ€Ż€À€”€€" #. STID_UNCHECK_PROP_FOR_SAVE_DOTS #: ../../strtbl.c:961 msgid "Please uncheck properties you don't want to save..." msgstr "ÊĘž€·€ż€Ż€Ê€€Â°À­€Î„Á„§„Ă„Ż€ò€Ï€ș€·€Æ€Ż€À€”€€" #. STID_UNCHECK_PROP_FOR_PASTE_DOTS #: ../../strtbl.c:963 msgid "Please uncheck properties you don't want to paste..." msgstr "„ÚĄŒ„č„È€·€ż€Ż€Ê€€Â°À­€Î„Á„§„Ă„Ż€ò€Ï€ș€·€Æ€Ż€À€”€€" #. STID_UNCHECK_PROP_FOR_RESTORE_DOTS #: ../../strtbl.c:965 msgid "Please uncheck properties you don't want to restore..." msgstr "" #. STID_MALFORMED_CUT_BUF_WHILE_PASTE #: ../../strtbl.c:967 msgid "Malformed cut buffer read while pasting properties." msgstr "" #. STID_NO_PROP_SETS_TO_RESTORE #: ../../strtbl.c:969 msgid "Cannot find any property sets. Nothing to restore." msgstr "" #. STID_SEL_A_PROP_SET_TO_RESTORE #: ../../strtbl.c:971 msgid "Please select a property set to restore..." msgstr "" #. STID_TOOL_EDIT_INI_SECTION #: ../../strtbl.c:973 #, c-format msgid "%s - Edit Ini Section" msgstr "" #. STID_BAD_VALUE_FOR_KEY #: ../../strtbl.c:975 #, c-format msgid "Bad %s value: '%s'." msgstr "" #. STID_NOTHING_TO_EDIT_SEC_EMPTY #: ../../strtbl.c:977 #, c-format msgid "" "The [%s] section of '%s' is empty.\n" "\n" "Nothing to edit." msgstr "" #. STID_EDIT_VALUES_FOR_DOTS #: ../../strtbl.c:979 #, c-format msgid "Edit values for [%s]..." msgstr "" #. STID_TOOL_SEL_FROM_INI_SECTION #: ../../strtbl.c:981 #, c-format msgid "%s - Select From Ini Section" msgstr "" #. STID_NOTHING_TO_SEL_SEC_EMPTY #: ../../strtbl.c:983 #, c-format msgid "" "The [%s] section of '%s' is empty.\n" "\n" "Nothing to select from." msgstr "" #. STID_SELECT_A_VALUE_FROM_SEC_DOTS #: ../../strtbl.c:985 #, c-format msgid "Select a value from [%s]..." msgstr "" #. STID_COPY_PROP_BEFORE_PASTE #: ../../strtbl.c:987 msgid "Please copy some properties before pasting properties." msgstr "" #. STID_INVALID_PARAM_PASSED_TO_FUNC #: ../../strtbl.c:989 #, c-format msgid "Invalid parameters passed to %s." msgstr "" #. STID_TOOL_INPUT #: ../../strtbl.c:991 #, c-format msgid "%s - Input" msgstr "" #. STID_WARN_INVALID_NUMREDRAWBBOX #: ../../strtbl.c:993 msgid "Warning: Invalid numRedrawBBox." msgstr "" #. STID_USER_INTR_ABORT_REPAINT #: ../../strtbl.c:995 msgid "User interrupt. Repaint aborted." msgstr "" #. STID_CANNOT_ALLOC_XPM_NO_ANIM #: ../../strtbl.c:997 #, c-format msgid "" "Cannot allocate pixmap of size [%1dx%1d].\n" "\n" "Cannot cache animation." msgstr "" #. STID_SCROLLING_CANCELED #: ../../strtbl.c:999 msgid "Scrolling canceled." msgstr "" #. STID_CANNOT_ALLOC_PIXMAP_OF_SIZE #: ../../strtbl.c:1001 #, c-format msgid "Cannot allocate pixmap of size [%1dx%1d]." msgstr "" #. STID_FORCING_END_ANIMATE #: ../../strtbl.c:1003 msgid "Forcing an end_animate()." msgstr "" #. STID_TOOL_NOT_FINISH_WITH_EXEC #: ../../strtbl.c:1005 #, c-format msgid "%s is not finished with the previous ExecCmdsFromFile() yet." msgstr "" #. STID_NO_INTSPLINE_SELECTED #: ../../strtbl.c:1007 msgid "No interpolated spline objects selected." msgstr "ÊäŽÖ€”€ì€ż„脌„é„€„ó€Î„Ș„Ö„ž„§„Ż„È€ŹÁȘÂò€”€ì€Æ€Ț€»€ó." #. STID_INTSPLINE_CONVERTED_TO_SPLINE #: ../../strtbl.c:1009 msgid "Interpolated spline objects converted to splines." msgstr "" #. STID_SELECT_ONLY_ONE_POLY_POLYGON #: ../../strtbl.c:1011 msgid "Please select only one POLY or POLYGON object." msgstr "" #. STID_CANNOT_TOGGLE_FOR_INTSPLINE #: ../../strtbl.c:1013 msgid "Cannot toggle Smooth/Hinge points for interpolated spline objects." msgstr "" #. STID_BAD_POLY_IN_TOGGLE_SMOOTH #: ../../strtbl.c:1015 msgid "Bad poly in SelectModeToggleSmoothHinge()." msgstr "" #. STID_CLICK_LEFT_BUTTON_TO_TOGGLE #: ../../strtbl.c:1017 msgid "Click left mouse button to toggle Smooth/Hinge points." msgstr "" #. STID_CLICK_OTHER_BUTTON_TO_QUIT #: ../../strtbl.c:1019 msgid "Click other buttons to quit." msgstr "" #. STID_ONLY_TOGGLE_SMOOTH_IN_MODES #: ../../strtbl.c:1021 msgid "Can only toggle smooth/hinge points in VERTEX or SELECT mode." msgstr "" #. STID_SMOOTHNESS_TOGGLED #: ../../strtbl.c:1023 msgid "The smoothness of selected vertices are toggled." msgstr "" #. STID_BREAK_TEXT_CWL #: ../../strtbl.c:1025 msgid "Would you like to break text at char/word/line boundaries? [cwl](c)" msgstr "" #. STID_BREAK_TEXT_CL #: ../../strtbl.c:1027 msgid "Would you like to break text at char/line boundaries? [cl](c)" msgstr "" #. STID_BREAK_TEXT_CW #: ../../strtbl.c:1029 msgid "Would you like to break text at char/word boundaries? [cw](c)" msgstr "" #. STID_INVALID_SPEC_ON_BREAK_TEXT #: ../../strtbl.c:1031 #, c-format msgid "Invalid specification on how to break up text: '%s'." msgstr "" #. STID_NO_TEXT_OBJ_TO_BREAK_UP #: ../../strtbl.c:1033 #, fuzzy msgid "No text objects selected to break up." msgstr "„Æ„­„č„È€òłÈÂçœÌŸźČĀˀč€ë" #. STID_SOME_TEXT_NOT_BROKEN_UP_SIZE #: ../../strtbl.c:1035 msgid "Some text are not broken up due to unavailable text size." msgstr "" #. STID_TEXT_BROKEN_INTO_CHARS #: ../../strtbl.c:1037 msgid "Text string is broken up into characters." msgstr "" #. STID_CUR_TEXT_BG_SET_TO_NAMED #: ../../strtbl.c:1039 #, c-format msgid "Current text object's background color has been set to '%s'." msgstr "" #. STID_SOME_TEXT_BG_SET_TO_NAMED #: ../../strtbl.c:1041 #, c-format msgid "Some text object's background color have been set to '%s'." msgstr "" #. STID_SEL_ONE_POLYGON_TO_MAKE_REG #: ../../strtbl.c:1043 msgid "Please select one polygon object to make it regular." msgstr "" #. STID_POLYGON_LOCKED #: ../../strtbl.c:1045 msgid "Selected polygon is locked." msgstr "ÁȘÂò€”€ì€żÂżłŃ·Á€Ï„í„Ă„Ż€”€ì€Ț€·€ż" #. STID_POLYGON_TOO_SMALL_FOR_REGULAR #: ../../strtbl.c:1047 msgid "Selected polygon is too small to make regular." msgstr "" #. STID_VERTEX_AT_3_OCLOCK_YNC #: ../../strtbl.c:1049 msgid "Do you want a vertex at the 3 o'clock position? [ync](y)" msgstr "" #. STID_CANNOT_DEL_PT_FOR_LOCKED #: ../../strtbl.c:1051 msgid "Cannot delete points for a locked object." msgstr "„í„Ă„Ż€”€ì€ż„Ș„Ö„ž„§„Ż„È€ÎÄșĆÀ€ÏșïœüœĐÍè€Ț€»€ó" #. STID_LEFT_BTN_TO_DEL_PTS #: ../../strtbl.c:1053 msgid "Click left mouse button to DELETE points." msgstr "" #. STID_CANNOT_ADD_PT_FOR_LOCKED #: ../../strtbl.c:1055 msgid "Cannot add points for a locked object." msgstr "" #. STID_CANNOT_ADD_PT_FOR_AUTO_ARROW #: ../../strtbl.c:1057 msgid "Cannot add points for an auto_retracted_arrows object." msgstr "" #. STID_LEFT_BTN_TO_ADD_PTS #: ../../strtbl.c:1059 msgid "Drag left mouse button to ADD points." msgstr "" #. STID_UNDO_BUF_AND_CMAP_FLUSHED #: ../../strtbl.c:1061 msgid "Undo buffer and Colormap flushed." msgstr "" #. STID_NUM_COLORS_ALLOCATED #: ../../strtbl.c:1063 #, c-format msgid "%1d color(s) allocated." msgstr "" #. STID_UNDO_BUF_FLUSHED #: ../../strtbl.c:1065 msgid "Undo buffer flushed." msgstr "" #. STID_SEL_ONE_XBM_OR_XPM_TO_RESTORE #: ../../strtbl.c:1067 msgid "Please select one X11 Bitmap or X11 Pixmap object to restore." msgstr "" #. STID_CANNOT_RESTORE_LOCKED #: ../../strtbl.c:1069 msgid "Cannot restore a locked object." msgstr "" #. STID_SEL_ONE_XBM_OR_XPM_TO_CUT #: ../../strtbl.c:1071 msgid "Please select one X11 Bitmap or X11 Pixmap object to cut." msgstr "" #. STID_CANNOT_CUT_LOCKED #: ../../strtbl.c:1073 msgid "Cannot cut a locked object." msgstr "" #. STID_CANNOT_CUT_TRANSFORMED_X_OBJ #: ../../strtbl.c:1075 msgid "Cannot cut a stretched/rotated/sheared X11 Bitmap or X11 Pixmap object." msgstr "" #. STID_SEL_ONE_XBM_OR_XPM_TO_BREAKUP #: ../../strtbl.c:1077 msgid "Please select one X11 Bitmap or X11 Pixmap object to break up." msgstr "" #. STID_CANNOT_BREAK_XFORMED_X_OBJ #: ../../strtbl.c:1079 msgid "" "Cannot break up a stretched/rotated/sheared X11 Bitmap or X11 Pixmap object." msgstr "" #. STID_CANNOT_BREAKUP_LOCKED #: ../../strtbl.c:1081 msgid "Cannot break up a locked object." msgstr "" #. STID_ENTER_NUM_ROWCOL_TO_BREAK #: ../../strtbl.c:1083 #, c-format msgid "" "Please enter the number of columns and rows to break into (original size is %" "1dx%1d): [Col x Row]" msgstr "" #. STID_INVALID_ROWCOL_SPEC_REENTER #: ../../strtbl.c:1085 #, c-format msgid "" "Invalid specification: '%s'.\n" "\n" "Please enter [Cols x Rows] or [=WxH]" msgstr "" #. STID_ENTER_CONCAVE_OR_CONVEX #: ../../strtbl.c:1087 msgid "Please specify concave (c) or convex (v):" msgstr "" #. STID_INVALID_SPEC #: ../../strtbl.c:1089 #, c-format msgid "Invalid specification: '%s'." msgstr "" #. STID_SEL_AN_ARC_OBJ #: ../../strtbl.c:1091 msgid "Please select an arc object." msgstr "±ßžÌ€òÁȘÂò€·€Æ€Ż€À€”€€" #. STID_NO_ARC_OBJ_SELECTED #: ../../strtbl.c:1093 msgid "No arc object selected." msgstr "±ßžÌ€ŹÁȘÂò€”€ì€Æ€Ț€»€ó" #. STID_TOO_MANY_ARC_SEL_ONLY_ONE_ARC #: ../../strtbl.c:1095 msgid "" "Too many arc objects selected.\n" "\n" "Please select only one arc object." msgstr "" #. STID_NO_OTHER_OBJ_FOR_LAYOUTONARC #: ../../strtbl.c:1097 msgid "" "Nothing to layout on the selected arc.\n" "\n" "Please select other objects in addition to the selected arc." msgstr "" #. STID_CANNOT_LAYOUTONARC_LOCKED #: ../../strtbl.c:1099 msgid "" "Some objects are locked.\n" "\n" "Please unlock them before retrying." msgstr "" #. STID_ARC_XFORMED_FOR_LAYOUTONARC #: ../../strtbl.c:1101 msgid "" "Don't know how to layout objects on an arc object that has been stretched/" "sheared/rotated.\n" "\n" "Please use a simple arc." msgstr "" #. STID_ROT_NOT_AVAIL_ON_VERTEX_MODE #: ../../strtbl.c:1103 msgid "PreciseRotate() is not available in vertex mode." msgstr "" #. STID_ENTER_AN_ANGLE_IN_DEGREES #: ../../strtbl.c:1105 msgid "Please specify an angle in degrees: (positive angle is clock-wise)" msgstr "" #. STID_INVALID_SPEC_NUM_EXPECTED #: ../../strtbl.c:1107 #, c-format msgid "" "Invalid specification '%s'.\n" "\n" "A numerical value is expected." msgstr "" #. STID_SOME_GROUP_OBJ_NOT_MODIFIED #: ../../strtbl.c:1109 msgid "Some group/symbol/icon objects are not modified." msgstr "" #. STID_CANNOT_REM_XFORM_FOR_GROUPED #: ../../strtbl.c:1111 msgid "Cannot remove transforms for group/symbol/icon objects." msgstr "" #. STID_ENTER_EDIT_TEXT_SIZE #: ../../strtbl.c:1113 #, c-format msgid "" "Please specify text size for editing text objects (enter 0 or a value " "between 4 and 34, 0 means to use the actual size of text): [current: %1d]" msgstr "" #. STID_EDIT_TEXT_SIZE_OUT_OF_RANGE #: ../../strtbl.c:1115 #, c-format msgid "" "The value entered: '%s' is out of range.\n" "\n" "Please enter a value between 4 and 34." msgstr "" #. STID_ACTUAL_EDIT_TEXT_SIZE #: ../../strtbl.c:1117 #, fuzzy msgid "Actual text size will be used to edit existing text." msgstr "ÊÔœžĂæ€ÎÊž»ú„Ș„Ö„ž„§„Ż„È€ÎÊž»ú„”„€„ș€òÀßÄê€č€ë" #. STID_USE_SPECIFIED_EDIT_TEXT_SIZE #: ../../strtbl.c:1119 #, fuzzy, c-format msgid "Text size of %1d will be used to edit existing text." msgstr "ÊÔœžĂæ€ÎÊž»ú„Ș„Ö„ž„§„Ż„È€ÎÊž»ú„”„€„ș€òÀßÄê€č€ë" #. STID_CANNOT_FIND_NAMED_STRING #: ../../strtbl.c:1121 #, c-format msgid "Cannot find '%s'." msgstr "'%s' €òž«ÉŐ€±€é€ì€Ț€»€ó." #. STID_FIND_CMD_WRAPPED #: ../../strtbl.c:1123 msgid "Find command is wrapped around." msgstr "" #. STID_ENTER_CASE_STR_TO_FIND #: ../../strtbl.c:1125 msgid "Please enter a string to find (case sensitive):" msgstr "" #. STID_ENTER_NOCASE_STR_TO_FIND #: ../../strtbl.c:1127 msgid "Please enter a string to find (case insensitive):" msgstr "" #. STID_NO_PREVIOUS_FIND #: ../../strtbl.c:1129 msgid "" "No previous find specified.\n" "\n" "Please select FindCaseSensitive() or FindNoCase()." msgstr "" #. STID_CANNOT_ABUT_IN_VERTEX_MODE #: ../../strtbl.c:1131 msgid "Cannot abut in vertex mode." msgstr "" #. STID_CANNOT_ABUT_LOCKED #: ../../strtbl.c:1133 msgid "Cannot abut. Too many objects locked." msgstr "" #. STID_ABUTTED_HORI #: ../../strtbl.c:1135 msgid "Objects are abutted horizontally." msgstr "" #. STID_ABUTTED_VERT #: ../../strtbl.c:1137 msgid "Objects are abutted vertically." msgstr "" #. STID_ICONS_BROUGHT_UP_TO_DATE #: ../../strtbl.c:1139 msgid "Selected icons are brought up to date." msgstr "" #. STID_SEL_AT_LEAST_TWO_OBJS #: ../../strtbl.c:1141 msgid "Please select at least two objects." msgstr "ŸŻ€Ê€Ż€È€â2€Ä€Î„Ș„Ö„ž„§„Ż„È€òÁȘÂò€·€Æ€Ż€À€”€€" #. STID_CANNOT_SIZE_OF_GIVEN_WIDTH #: ../../strtbl.c:1143 #, c-format msgid "Cannot size objects to width of %1d." msgstr "" #. STID_CANNOT_SIZE_OF_GIVEN_HEIGHT #: ../../strtbl.c:1145 #, c-format msgid "Cannot size objects to height of %1d." msgstr "" #. STID_SPECIFY_WIDTH_HEIGHT #: ../../strtbl.c:1147 msgid "Please specify a width and a height [WxH]:" msgstr "Éę€Èč—€ò»ŰÄꀷ€ÆČŒ€”€€ [WxH]:" #. STID_SPECIFY_WIDTH #: ../../strtbl.c:1149 msgid "Please specify a width:" msgstr "Éę€ò»ŰÄꀷ€ÆČŒ€”€€:" #. STID_SPECIFY_HEIGHT #: ../../strtbl.c:1151 msgid "Please specify a height:" msgstr "č—€ò»ŰÄꀷ€ÆČŒ€”€€:" #. STID_NAMED_XDEF_IS_OBSOLETE #: ../../strtbl.c:1157 #, c-format msgid "The %s.%s X default is obsolete." msgstr "" #. STID_GIVEN_BPS_PREVIEW_NOT_SUP #: ../../strtbl.c:1159 #, c-format msgid "%1d bits per sample preview not supported." msgstr "" #. STID_INVALID_PREVIEW_BMP_IN_EPS #: ../../strtbl.c:1161 #, c-format msgid "Invalid preview bitmap in EPS file: '%s'." msgstr "" #. STID_FAIL_TO_WRITE_TO_STDOUT #: ../../strtbl.c:1163 msgid "" "Fail to write to stdout.\n" "\n" "File system may be full." msgstr "" "ÉžœàœĐÎÏ€Ű€Îœń€­čț€ß€òŒșÇÔ€·€Ț€·€ż.\n" "\n" "„Ő„Ą„€„ë„·„脯„à€Ź°ìÇŐ€Î€è€Š€Ç€č." #. STID_FAIL_TO_PARSE_WINEPS_FILE #: ../../strtbl.c:1165 #, c-format msgid "Fail to parse Windows EPS file '%s'." msgstr "Windows EPS „Ő„Ą„€„ë '%s' €ÎœèÍę€ËŒșÇÔ€·€Ț€·€ż." #. STID_INVALID_PREVIEW_BOX_IN_EPS #: ../../strtbl.c:1167 #, c-format msgid "Invalid preview box in EPS file: '%s'." msgstr "" #. STID_CANNOT_BBOX_IN_GIVEN_FILE #: ../../strtbl.c:1169 #, c-format msgid "Cannot find bounding box information in '%s'." msgstr "" #. STID_CANNOT_CONVERT_WINEPS_PREVIEW #: ../../strtbl.c:1171 #, c-format msgid "Unable to convert Windows EPS preview bitmap in '%s'." msgstr "" #. STID_CANNOT_OPEN_EPS_FILE_FOR_READ #: ../../strtbl.c:1173 #, c-format msgid "Cannot open EPS file '%s' for reading." msgstr "" #. STID_EPS_OBJ_SKIPPED_FOR_PRINT #: ../../strtbl.c:1175 msgid "EPS object skipped during printing." msgstr "" #. STID_EPS_FILE_NEWER_THAN_EPS_OBJ #: ../../strtbl.c:1177 #, c-format msgid "Warning: EPS file '%s' is newer than the EPS object." msgstr "" #. STID_NO_TOP_LEVEL_EPS_SELECTED #: ../../strtbl.c:1179 msgid "No top-level EPS object selected." msgstr "" #. STID_CANNOT_IMPORT_GIVEN_EPS #: ../../strtbl.c:1181 #, c-format msgid "Cannot import EPS file '%s'." msgstr "EPS„Ő„Ą„€„ë€òÁȚÆț€Ç€­€Ț€»€ó '%s'." #. STID_EPS_OBJECT_UPDATED #: ../../strtbl.c:1183 msgid "EPS object(s) updated." msgstr "EPS „Ș„Ö„ž„§„Ż„È€Źččż·€”€ì€Ț€·€ż." #. STID_CANNOT_EVAL_INVALID_OP_TYPE #: ../../strtbl.c:1185 #, c-format msgid "" "Cannot evaluate '%s'.\n" "\n" "Invalid operand type for the '%s' operator." msgstr "" #. STID_DIVIDE_BY_ZERO_FOR_OP_TYPE #: ../../strtbl.c:1187 #, c-format msgid "Divide by zero encountered for the '%s' operator." msgstr "" #. STID_ILLEGAL_EXPR_INVALID_OP_CODE #: ../../strtbl.c:1189 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Invalid operator code: '%1d'." msgstr "" #. STID_ILLEGAL_EXPR_EMPTY_OP_STACK #: ../../strtbl.c:1191 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Empty operator stack." msgstr "" #. STID_ILLEGAL_EXPR_BAD_NUM_VALUE #: ../../strtbl.c:1193 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Bad numeric value: '%s'." msgstr "" #. STID_ILLEGAL_EXPR_BAD_STR_VALUE #: ../../strtbl.c:1195 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Bad string value: '%s'." msgstr "" #. STID_ILLEGAL_EXPR_BAD_IDENTIFIER #: ../../strtbl.c:1197 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Bad identifier: '%s'." msgstr "" #. STID_ILLEGAL_EXPR_BAD_OPERATOR #: ../../strtbl.c:1199 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Bad operator: '%s'." msgstr "" #. STID_ILLEGAL_EXPR_TOO_MANY_SYMBOL #: ../../strtbl.c:1201 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Too many '%c'." msgstr "" #. STID_ILL_EXPR_OP_STACK_NON_EMPTY #: ../../strtbl.c:1203 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Non empty operator stack after evaluation." msgstr "" #. STID_ILL_EXPR_VAL_STACK_NON_EMPTY #: ../../strtbl.c:1205 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Non empty value stack after evaluation." msgstr "" #. STID_ILL_EXPR_TOO_MANY_VALS_LEFT #: ../../strtbl.c:1207 #, c-format msgid "" "Illegal expression: '%s'.\n" "\n" "Too many values left on the value stack after evaluation." msgstr "" #. STID_CANNOT_OPEN_FOR_READ_PRINT #: ../../strtbl.c:1209 #, c-format msgid "Cannot open '%s' for reading. Printing aborted." msgstr "" #. STID_CANNOT_OPEN_FOR_WRITE_PRINT #: ../../strtbl.c:1211 #, c-format msgid "Cannot open '%s' for writing. Printing aborted." msgstr "" #. STID_CANNOT_FIND_CMD_EXEC #: ../../strtbl.c:1213 #, c-format msgid "" "Cannot find '%s'.\n" "\n" "Would you like to execute '%s' anyway?" msgstr "" #. STID_CANNOT_FIND_CMD_IN_PATH_EXEC #: ../../strtbl.c:1215 #, c-format msgid "" "Cannot find '%s' in the PATH.\n" "\n" "Would you like to execute '%s' anyway?" msgstr "" #. STID_CANT_FIND_CMD_MSG_EXEC #: ../../strtbl.c:1217 #, c-format msgid "" "Cannot find '%s'. %s\n" "\n" "Would you like to execute '%s' anyway?" msgstr "" #. STID_CANT_FIND_CMD_INPATH_MSG_EXEC #: ../../strtbl.c:1219 #, c-format msgid "" "Cannot find '%s' in the PATH. %s\n" "\n" "Would you like to execute '%s' anyway?" msgstr "" #. STID_FILE_EXISTS_OK_OVERWRITE_YNC #: ../../strtbl.c:1221 #, c-format msgid "File '%s' exists, okay to overwrite? [ync](y)" msgstr "„Ő„Ą„€„ë '%s' €ŹÂžș߀·€Ț€č. Ÿćœń€­€·€Æ€â€è€€€Ç€č€«? [ync](y)" #. STID_ONE_PAGE_SYM_ABORT_SAVE #: ../../strtbl.c:1223 msgid "" "A symbol file can only have one page.\n" "\n" "Save aborted." msgstr "" #. STID_ONE_PAGE_PIN_ABORT_SAVE #: ../../strtbl.c:1225 msgid "" "A pin file can only have one page.\n" "\n" "Save aborted." msgstr "" #. STID_TOO_MANY_SYM_ABORT_SAVE #: ../../strtbl.c:1227 msgid "" "Too many symbols.\n" "\n" "Symbol file not saved." msgstr "" #. STID_CANT_OPEN_WRITE_FILE_NOT_SAVE #: ../../strtbl.c:1229 #, c-format msgid "Cannot open '%s' for writing. File not saved." msgstr "" #. STID_SAVE_TMP_FILE_DOTS #: ../../strtbl.c:1231 #, c-format msgid "Saving temporary file '%s'..." msgstr "" #. STID_TMP_FILE_SAVED #: ../../strtbl.c:1233 #, c-format msgid "Temporary file '%s' saved." msgstr "" #. STID_CANNOT_CHMOD #: ../../strtbl.c:1235 #, c-format msgid "Cannot chmod '%s' to 0%03o." msgstr "" #. STID_WORKING_DIRECTORY_IS #: ../../strtbl.c:1237 #, c-format msgid "( working directory: %s )" msgstr "( „ïĄŒ„­„ó„°ĄŠ„Ç„Ł„ì„Ż„È„ê: %s)" #. STID_ENTER_NEW_FNAME_ACCEPT_CANCEL #: ../../strtbl.c:1239 msgid "Please enter new file name: ( <CR>: accept, <ESC>: cancel )" msgstr "ż·€·€€„Ő„Ą„€„ëÌŸ€òÆțÎÏ€·€Æ€Ż€À€”€€ (<CR>: łÎÄê, <ESC>: „­„ă„ó„»„ë)" #. STID_CANT_SAVE_SYM_NO_SYM_FOUND #: ../../strtbl.c:1241 msgid "" "Cannot save as a symbol file.\n" "\n" "No symbol defined." msgstr "" #. STID_CANT_SAVE_PIN_NO_SYM_FOUND #: ../../strtbl.c:1243 msgid "" "Cannot save as a pin file.\n" "\n" "No symbol defined." msgstr "" #. STID_CANT_SAVE_OJB_ONE_SYM_FOUND #: ../../strtbl.c:1245 msgid "" "Cannot save as an object file.\n" "\n" "One symbol defined." msgstr "" #. STID_CANT_SAVE_SYM_SAVE_AS_PIN #: ../../strtbl.c:1247 msgid "" "Cannot save as a symbol file.\n" "\n" "Please save the file as a pin file." msgstr "" #. STID_CANT_SAVE_PIN_ONE_SYM_FOUND #: ../../strtbl.c:1249 msgid "" "Cannot save as a pin file.\n" "\n" "Only one symbol is defined." msgstr "" #. STID_CANT_SAVE_OJB_TWO_SYM_FOUND #: ../../strtbl.c:1251 msgid "" "Cannot save as an object file.\n" "\n" "Two symbols defined." msgstr "" #. STID_CANT_SAVE_SYM_TWO_SYM_FOUND #: ../../strtbl.c:1253 msgid "" "Cannot save as a symbol file.\n" "\n" "Two symbols defined." msgstr "" #. STID_CANT_FIND_TYPE_ATTR_NOT_SAVED #: ../../strtbl.c:1255 msgid "" "Cannot find an attribute name 'type'.\n" "\n" "Pin file not saved." msgstr "" #. STID_SYM_TYPE_WRONG_PIN_NOT_SAVED #: ../../strtbl.c:1257 #, c-format msgid "" "Symbol type is not '%s'.\n" "\n" "Pin file not saved." msgstr "" #. STID_NO_FILE_NAME_FILE_NOT_SAVED #: ../../strtbl.c:1259 msgid "" "No file name specified.\n" "\n" "File not saved." msgstr "" #. STID_SAVING_DOTS #: ../../strtbl.c:1261 #, c-format msgid "Saving '%s'..." msgstr "" #. STID_PROBLEM_ZIPPING_PLEASE_SAVE #: ../../strtbl.c:1263 #, c-format msgid "" "Problems encountered while (g)zipping '%s' to '%s'.\n" "\n" "The unzipped file is '%s'. Please save a copy of it before proceeding." msgstr "" #. STID_FILE_SAVED #: ../../strtbl.c:1265 #, c-format msgid "File '%s' saved." msgstr "" #. STID_FILE_NOT_SAVED #: ../../strtbl.c:1267 #, c-format msgid "File '%s' is not saved." msgstr "" #. STID_NO_SYM_FOUND_SYM_NOT_SAVED #: ../../strtbl.c:1269 msgid "" "No symbol found.\n" "\n" "Symbol file not saved." msgstr "" #. STID_ENTER_NEW_FILE_NAME #: ../../strtbl.c:1271 msgid "Please enter new file name:" msgstr "ż·€·€€„Ő„Ą„€„ëÌŸ€òÆțÎÏ€·€Æ€Ż€À€”€€:" #. STID_CANT_FIND_DOT_IN_SAVEFILE #: ../../strtbl.c:1273 #, c-format msgid "Cannot find '.' in curFileName in %s." msgstr "" #. STID_NO_SYM_FOUND_PIN_NOT_SAVED #: ../../strtbl.c:1275 msgid "" "No symbol found.\n" "\n" "Pin file not saved." msgstr "" #. STID_SYM_TYPE_IS_SHOULD_SAVE_PIN #: ../../strtbl.c:1277 #, c-format msgid "" "The symbol is of type %s.\n" "\n" "It should be saved as a pin file." msgstr "" #. STID_TOO_MANY_SYM_FILE_NOT_SAVED #: ../../strtbl.c:1279 msgid "" "Too many symbols.\n" "\n" "File not saved." msgstr "" #. STID_BAD_FIELD_IN_FUNC_ABORT_READ #: ../../strtbl.c:1281 #, c-format msgid "%s, %d: Invalid %s in %s. Read aborted." msgstr "" #. STID_UNRECOG_PAGE_STYLE #: ../../strtbl.c:1283 #, c-format msgid "Unrecognizable page style '%1d'." msgstr "" #. STID_PORTRAIT_STYLE_ASSUMED #: ../../strtbl.c:1285 msgid "Portrait style assumed." msgstr "œÄÄč€Î„ÚĄŒ„ž„脿„€„ë€ò»È€€€Ț€č" #. STID_CANT_FIND_COLOR_NUM_USE_CUR #: ../../strtbl.c:1287 #, c-format msgid "" "In reading state, cannot find color #%1d, use '%s' as the current color." msgstr "" #. STID_LINEWIDTH_IDX_RANGE_SET_TO_0 #: ../../strtbl.c:1289 #, c-format msgid "File's linewidth index '%1d' is out of range. Set to 0." msgstr "" #. STID_BAD_FIELD_IN_OBJ_ABORT_READ #: ../../strtbl.c:1291 #, c-format msgid "%s, %d: Invalid %s field in reading the %s object. Read aborted." msgstr "" #. STID_BAD_INPUT_WHILE_READ_PAGE #: ../../strtbl.c:1293 #, c-format msgid "Malformed input file (apparently reading page %1d). Read aborted." msgstr "" #. STID_BAD_PAGE_FILE_NAME_TRUNC_TO #: ../../strtbl.c:1295 #, c-format msgid "Invalid page file name: '%s'. Truncated to '%s'." msgstr "" #. STID_CUR_COLOR_CORRECTED_TO_BE #: ../../strtbl.c:1297 #, c-format msgid "(Current color is corrected to be '%s'.)" msgstr "" #. STID_FAIL_ALLOC_BGCOLOR_USE_DEF #: ../../strtbl.c:1299 #, c-format msgid "" "Fail to allocate the background color: '%s'. The current default background " "color '%s' is used instead." msgstr "" #. STID_ONLY_PAGE_1_IMPORTED #: ../../strtbl.c:1301 msgid "Only page 1 is imported from a multipage file." msgstr "" #. STID_ONLY_GIVEN_PAGE_IMPORTED #: ../../strtbl.c:1303 #, c-format msgid "Only page %1d is imported from a multipage file." msgstr "" #. STID_INVALID_REMOTE_FNAME #: ../../strtbl.c:1305 #, c-format msgid "Invalid remote file name '%s'." msgstr "" #. STID_CANNOT_READ_TMP_FILE #: ../../strtbl.c:1307 #, c-format msgid "Cannot read temporary file '%s'." msgstr "" #. STID_CANNOT_IMPORT_FILE #: ../../strtbl.c:1309 #, c-format msgid "Cannot import '%s'." msgstr "" #. STID_INVALID_PAGE_NUM #: ../../strtbl.c:1311 #, c-format msgid "Invalid page number '%s' specified." msgstr "" #. STID_USER_INTR_ABORT_DRAW #: ../../strtbl.c:1313 msgid "User interrupt. Drawing aborted." msgstr "" #. STID_FILE_VER_ABORT_IMPORT #: ../../strtbl.c:1315 #, c-format msgid "" "File version (=%1d) too large.\n" "\n" "Import aborted.\n" "\n" "You may need a more recent version of %s. Please check <URL:%s>." msgstr "" #. STID_FILE_CORRUPTED_ABORT_IMPORT #: ../../strtbl.c:1317 msgid "" "File corrupted.\n" "\n" "Import aborted." msgstr "" #. STID_FILE_IMPORTED #: ../../strtbl.c:1319 #, c-format msgid "'%s' imported." msgstr "" #. STID_SEL_AN_OBJ_FILE_TO_IMPORT #: ../../strtbl.c:1321 msgid "Please select an object file to import..." msgstr "" #. STID_CANNOT_ALLOC_BGCOLOR_USE_DEF #: ../../strtbl.c:1323 #, c-format msgid "Cannot allocate bg_color '%s', default bgcolor used." msgstr "" #. STID_CANNOT_ALLOC_FGCOLOR_USE_DEF #: ../../strtbl.c:1325 #, c-format msgid "Cannot allocate fg_color '%s', default fgcolor used." msgstr "" #. STID_CANNOT_SET_BGXPM_TO #: ../../strtbl.c:1327 #, c-format msgid "Cannot set background pixmap to '%s'." msgstr "" #. STID_COLORMAP_FLUSHED #: ../../strtbl.c:1329 msgid "Colormap flushed." msgstr "" #. STID_FILE_VER_ABORT_OPEN #: ../../strtbl.c:1331 #, c-format msgid "" "File version (=%1d) too large.\n" "\n" "Open aborted.\n" "\n" "You may need a more recent version of %s. Please check <URL:%s>." msgstr "" #. STID_FILE_CORRUPTED_ABORT_OPEN #: ../../strtbl.c:1333 msgid "" "File corrupted.\n" "\n" "Open aborted." msgstr "" #. STID_POP_BACK_TO_NAMED #: ../../strtbl.c:1335 #, c-format msgid "Pop back to '%s'." msgstr "" #. STID_WARN_PS_BBOX_EMPTY #: ../../strtbl.c:1337 msgid "Warning: The PostScript bounding box is empty." msgstr "" #. STID_TIFFEPSI_DIRECTLY_SUPPORTED #: ../../strtbl.c:1339 #, c-format msgid "" "Obsoleted %s.%s used. Ignored.\n" "\tTiffEPSI export is now supported by %s directly as an export format." msgstr "" #. STID_INVALID_XDEF #: ../../strtbl.c:1341 #, c-format msgid "Invalid %s.%s: '%s'." msgstr "" #. STID_FAIL_EXEC_PROG_EPSI_NOT_GEN #: ../../strtbl.c:1343 #, c-format msgid "" "Fail to execute '%s'.\n" "\n" "EPSI file not generated." msgstr "" #. STID_FAIL_GET_FINFO_EPSI_NOT_GEN #: ../../strtbl.c:1345 #, c-format msgid "" "Fail to get file info for '%s'.\n" "\n" "EPSI file not generated." msgstr "" #. STID_CANNOT_OPEN_FILE_FOR_APPEND #: ../../strtbl.c:1347 #, c-format msgid "Cannot open '%s' for appending." msgstr "" #. STID_CANNOT_PRINT_REMOTE_FILE #: ../../strtbl.c:1349 msgid "" "Cannot print/export a remote file.\n" "\n" "Please first save the file and then print/export again." msgstr "" #. STID_NO_OBJ_TO_PRINT_ON_PAGE #: ../../strtbl.c:1351 #, c-format msgid "No objects to print on page %1d." msgstr "" #. STID_NO_OBJ_TO_PRINT #: ../../strtbl.c:1353 msgid "No objects to print." msgstr "" #. STID_NO_CUR_FILE_CANNOT_GEN_FORMAT #: ../../strtbl.c:1355 #, c-format msgid "" "No current file.\n" "\n" "Cannot generate %s output." msgstr "" #. STID_GENERATING_PRINT_FILE_DOTS #: ../../strtbl.c:1361 msgid "Generating print file..." msgstr "" #. STID_NO_OBJ_TO_EXPORT #: ../../strtbl.c:1363 msgid "No objects to export." msgstr "" #. STID_WRITING_TO_DOTS #: ../../strtbl.c:1365 #, c-format msgid "Writing to '%s'..." msgstr "" #. STID_GENERATING_PREVIEW_BITMAP #: ../../strtbl.c:1367 msgid "Generating preview bitmap..." msgstr "" #. STID_OUTPUT_TRUNC_IN_PRINT_TILED #: ../../strtbl.c:1369 #, c-format msgid "Output may get truncated because %s.%s is set to 1." msgstr "" #. STID_RECOMMEND_REDUCING_SETTING #: ../../strtbl.c:1371 msgid "Reducing the above setting is recommended." msgstr "" #. STID_PRINTING_WITH_GIVEN_CMD #: ../../strtbl.c:1373 #, c-format msgid "Printing with the '%s' command." msgstr "'%s'„ł„Ț„ó„É€òÍŃ€€€ÆœĐÎÏĂæ€Ç€č." #. STID_CANNOT_EXEC_ABORT_PRINT #: ../../strtbl.c:1375 #, c-format msgid "Cannot execute '%s', print aborted." msgstr "'%s'€òŒÂčԀǀ­€Ț€»€óĄ„œĐÎÏ€ÏĂæĂÇ€·€Ț€·€ż" #. STID_NAMED_FILE_PRINTED #: ../../strtbl.c:1377 #, c-format msgid "'%s' printed." msgstr "'%s' €ÏœĐÎÏ€”€ì€Ț€ì€Ț€·€ż" #. STID_PRINT_COMPLETED #: ../../strtbl.c:1379 msgid "Print completed." msgstr "œĐÎÏŽ°Î»" #. STID_PRINTING_INTO_NAMED_FILE #: ../../strtbl.c:1381 #, c-format msgid "Printing into '%s'..." msgstr "'%s' €ËœĐÎÏĂæ..." #. STID_GENERATING_TIFF_PREVIEW_BMP #: ../../strtbl.c:1383 msgid "Generating TIFF preview bitmap..." msgstr "" #. STID_FORMAT_FILE_NOT_GENERATED #: ../../strtbl.c:1385 #, c-format msgid "%s file not generated." msgstr "" #. STID_CONVERTING_INTO_NAMED_FILE #: ../../strtbl.c:1387 #, c-format msgid "Converting into '%s'..." msgstr "" #. STID_CANNOT_EXEC_FORMAT_NOT_GEN #: ../../strtbl.c:1389 #, c-format msgid "Cannot execute '%s', %s file not generated." msgstr "" #. STID_FORMAT_FILE_PRINTED_INTO #: ../../strtbl.c:1391 #, c-format msgid "%s file printed into '%s'." msgstr "" #. STID_NO_CUR_FILE_CANNOT_GEN_TEXT #: ../../strtbl.c:1393 msgid "" "No current file.\n" "\n" "Cannot generate text output." msgstr "" #. STID_TEXT_OUTPUT_NOT_GEN #: ../../strtbl.c:1395 msgid "Text output not generated." msgstr "" #. STID_TEXT_PRINTED_INTO_NAMED_FILE #: ../../strtbl.c:1397 #, c-format msgid "Text file printed into '%s'." msgstr "" #. STID_TOO_MANY_COLOR_FOR_XPM_EXPORT #: ../../strtbl.c:1399 msgid "" "XPM objects that have more than 255 colors have been skipped during printing/" "exporting.\n" "\n" "You can use ReduceColors() from the ReduceNumberOfColors Submenu of the " "ImageProc Menu to reduce their number of colors." msgstr "" #. STID_CANNOT_PRINT_EPS_TILED_PAGE #: ../../strtbl.c:1401 msgid "Cannot print in EPS format in Tiled page mode." msgstr "" #. STID_PREPROCESS_PAGE_OF #: ../../strtbl.c:1403 #, c-format msgid "Preprocess page %1d of %1d..." msgstr "" #. STID_GENERATING_PAGE_OF #: ../../strtbl.c:1405 #, c-format msgid "Generating page %1d of %1d..." msgstr "" #. STID_GIVEN_PAGE_NOT_GENERATED #: ../../strtbl.c:1407 #, c-format msgid "Page %1d has not been generated." msgstr "" #. STID_PAGE_RANGE_NOT_GENERATED #: ../../strtbl.c:1409 #, c-format msgid "Pages %1d through %1d have not been generated." msgstr "" #. STID_PRINTWITHCMD_WORKS_PRINTER #: ../../strtbl.c:1411 msgid "PrintWithCmd() only works when output device is the printer." msgstr "" #. STID_ENTER_PRINT_CMD_NAME #: ../../strtbl.c:1413 msgid "Please enter print command name:" msgstr "" #. STID_NO_OBJ_SEL_NOTHING_TO_PRINT #: ../../strtbl.c:1415 msgid "" "No objects selected.\n" "\n" "Nothing printed." msgstr "" #. STID_SPECIFY_PERCENT_REDUCTION #: ../../strtbl.c:1417 msgid "Please specify percent reduction (<100) or enlargement (>100):" msgstr "" #. STID_INVALID_REDUCTION #: ../../strtbl.c:1419 #, c-format msgid "Invalid reduction '%s'." msgstr "" #. STID_NEW_REDUCTION_IS_PERCENT #: ../../strtbl.c:1421 msgid "New reduction is %s%%." msgstr "" #. STID_NEW_ENLARGEMENT_IS_PERCENT #: ../../strtbl.c:1423 msgid "New enlargement is %s%%." msgstr "" #. STID_OK_TO_CLEAR_WHITEBOARD #: ../../strtbl.c:1425 msgid "Okay to clear WhiteBoard?" msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_CLEAR #: ../../strtbl.c:1427 msgid "File modified, save file before clear? [ync](y)" msgstr "„Ő„Ą„€„ë€Ë€Ïœ€À”€ŹČĂ€ï€Ă€Æ€Ț€čĄŁ„Ż„ê„ą€č€ëÁ°€ËÊĘž€·€Ț€č€«? [ync](y)" #. STID_EDITING_NO_FILE #: ../../strtbl.c:1429 msgid "Editing no file." msgstr "" #. STID_OPEN_IN_WB #: ../../strtbl.c:1431 msgid "Open() is disabled in WhiteBoard mode." msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_OPEN #: ../../strtbl.c:1433 msgid "File modified, save file before open? [ync](y)" msgstr "„Ő„Ą„€„ë€Ë€Ïœ€À”€ŹČĂ€ï€Ă€Æ€Ț€čĄŁł«€ŻÁ°€ËÊĘž€·€Ț€č€«? [ync](y)" #. STID_SELECT_A_FILE_TO_OPEN #: ../../strtbl.c:1435 msgid "Please select a file to OPEN..." msgstr "ł«€Ż„Ő„Ą„€„ë€òÁȘ€ó€Ç€Ż€À€”€€" #. STID_INVALID_PAGE_SPECIFIED_FOR #: ../../strtbl.c:1437 #, c-format msgid "Invalid page specified for '%s'." msgstr "" #. STID_SETTEMPLATE_IN_WB #: ../../strtbl.c:1439 msgid "SetTemplate() is disabled in WhiteBoard mode." msgstr "" #. STID_SELECT_FILE_AS_TEMPLATE #: ../../strtbl.c:1441 msgid "Please select a file to be used as template..." msgstr "" #. STID_NOT_SUP_REMOTE_TEMPLATE_FILE #: ../../strtbl.c:1443 msgid "Using a remote template file is not supported." msgstr "" #. STID_CANNOT_OPEN_STILL_TEMPLATE #: ../../strtbl.c:1445 #, c-format msgid "" "Cannot open '%s' for reading.\n" "\n" "Would you still like to use it as a template file?" msgstr "" #. STID_STILL_USE_AS_TEMPLATE #: ../../strtbl.c:1447 #, c-format msgid "Would you still like to use '%s' as a template file?" msgstr "" #. STID_TEMPLATE_SET_TO #: ../../strtbl.c:1449 #, c-format msgid "Template set to '%s'." msgstr "„Æ„ó„Ś„ìĄŒ„È€ò '%s' €ËÀßÄê" #. STID_FILE_MOD_SAVE_BEFORE_QUIT #: ../../strtbl.c:1451 msgid "File modified, save file before quit? [ync](y)" msgstr "„Ő„Ą„€„ë€Ë€Ïœ€À”€ŹČĂ€ï€Ă€Æ€Ț€čĄŁœȘλÁ°€ËÊĘž€·€Ț€č€«? [ync](y)" #. STID_ANCESTER_MOD_STILL_QUIT #: ../../strtbl.c:1453 msgid "Ancester file modified, still quitting? [ync](y)" msgstr "" #. STID_ILLEGAL_DOUBLE_BYTE_TRUNC #: ../../strtbl.c:1455 msgid "Illegal double-byte string truncated:" msgstr "" #. STID_TOOL_CANT_HANDLE_DB_FONT #: ../../strtbl.c:1457 #, c-format msgid "" "The '%s' double-byte font has min_byte1=\\%03o and max_byte1=\\%03o.\n" "%s does not know how to handle this double-byte font.\n" "Please don't use this font and e-mail this error message to %s." msgstr "" #. STID_FAIL_LOAD_FONT_FONT_SUBS #: ../../strtbl.c:1459 #, c-format msgid "" "Fail to load the following font: '%s'.\n" "\n" "%s-%1d substituted for %s-%1d." msgstr "" #. STID_FONT_SUBSTITUTED #: ../../strtbl.c:1461 #, c-format msgid "%s-%1d substituted for %s-%1d." msgstr "" #. STID_CANNOT_GET_IMAGE_OF_SIZE #: ../../strtbl.c:1463 #, c-format msgid "Cannot get image of size [%1dx%1d]. System resource may be low." msgstr "" #. STID_UNRECOG_CHARCODE_DISCARD #: ../../strtbl.c:1465 #, c-format msgid "Unrecognized character code \\03%o. Character discarded." msgstr "" #. STID_CANT_FIND_FONT_USE_ALT #: ../../strtbl.c:1467 #, c-format msgid "Cannot find the %s font. Use '%s' instead." msgstr "„Ő„©„ó„È '%s' €Źž«ÉŐ€«€ê€Ț€»€ó. €«€ï€ê€Ë '%s' €ò»È€€€Ț€č." #. STID_BAD_XDEF_CANT_FIND_EQ_SKIP #: ../../strtbl.c:1469 #, c-format msgid "Invalid entry '%s' (cannot find '=') in %s.%s, skipped." msgstr "" #. STID_BAD_XDEF_MISS_FONT_NAME_SKIP #: ../../strtbl.c:1471 #, c-format msgid "Invalid entry '%s' (missing font name) in %s.%s, skipped." msgstr "" #. STID_MISS_FONT_SPEC_IN_XDEF #: ../../strtbl.c:1473 #, c-format msgid "Missing font specification in '%s.%s'." msgstr "" #. STID_INVALID_X_FONT_INFO_IN_XDEF #: ../../strtbl.c:1475 #, c-format msgid "Invalid X font information in '%s.%s': '%s'." msgstr "" #. STID_INVALID_X_REG_INFO_IN_XDEF #: ../../strtbl.c:1477 #, c-format msgid "Invalid X registry information in '%s.%s': '%s'." msgstr "" #. STID_INVALID_PS_INFO_IN_XDEF #: ../../strtbl.c:1479 #, c-format msgid "Invalid PS font information in '%s.%s': '%s'." msgstr "" #. STID_ERR_PROCESS_FONT_USE_ALT #: ../../strtbl.c:1481 msgid "" "Warning: Error in processing %s.%s: '%s'.\n" "\t'%s-%s-*-%%d-*-*-*-*-*-%s' used." msgstr "" #. STID_INVALID_SB_FONT_USE_DB_FONT #: ../../strtbl.c:1483 #, c-format msgid "Invalid %s.%s: '%s'. Please use a non-double-byte font." msgstr "" #. STID_ERR_PROCESS_SIZE_USE_DEF_SIZE #: ../../strtbl.c:1485 #, c-format msgid "Warning: Error in processing %s.%s. Default font sizes used." msgstr "" #. STID_OBSOLETE_XDEF_USE_ALT #: ../../strtbl.c:1487 #, c-format msgid "Obsoleted %s.%s used. Please use %s.%s instead." msgstr "" #. STID_CANT_OPEN_DEF_MSG_FONT_ABORT #: ../../strtbl.c:1489 #, c-format msgid "Cannot open the Default(Msg)Font '%s'." msgstr "" #. STID_WARN_VERY_SMALL_DEF_FONT #: ../../strtbl.c:1491 #, c-format msgid "" "Warning: Very small default font width/height (%1d/%1d).\n" "\tPossibly a problem with the font path.\n" "\tSet default font width to 9 and height to 14 as a temporary fix." msgstr "" #. STID_CANT_OPEN_RULER_FONT_ABORT #: ../../strtbl.c:1493 #, c-format msgid "Cannot open the RulerFont '%s'." msgstr "„ëĄŒ„é€Î„Ő„©„ó„È '%s'€òł«€Ż€ł€È€Ź€Ç€­€Ț€»€ó" #. STID_WARN_VERY_SMALL_RULER_FONT #: ../../strtbl.c:1495 #, c-format msgid "" "Warning: Very small ruler font width/height (%1d/%1d).\n" "\tPossibly a problem with the font path.\n" "\tSet ruler font width to 7 and height to 12 as a temporary fix." msgstr "" #. STID_CANNOT_SET_INITIAL_FONT_TO #: ../../strtbl.c:1497 #, c-format msgid "Warning: Cannot set InitialFont to '%s'." msgstr "" #. STID_CANT_SET_INIT_FONTSTYLE_ALT #: ../../strtbl.c:1499 #, c-format msgid "" "Warning: Cannot set InitialFontStyle to '%s'. '%s' font is used instead." msgstr "" "·ÙčđĄ§œéŽü„Ő„©„ó„ÈĄŠ„č„ż„€„ë '%s' €ò»È€š€Ț€»€ó. €«€ï€ê€Ë '%s' €ò»È€€€Ț€č." #. STID_CANT_SET_INIT_FONTJUST_ALT #: ../../strtbl.c:1501 #, c-format msgid "Warning: Cannot set InitialFontJust to '%s'. '%s' is used instead." msgstr "" #. STID_CANT_SET_INIT_FONTSIZE_ALT #: ../../strtbl.c:1503 #, c-format msgid "Warning: Cannot set InitialFontSize to '%s'. '%s' is used instead." msgstr "" "·ÙčđĄ§œéŽü„Ő„©„ó„ÈĄŠ„”„€„ș '%s' €ò»È€š€Ț€»€ó. €«€ï€ê€Ë '%s' €ò»È€€€Ț€č." #. STID_FONT_NOT_AVAILABLE #: ../../strtbl.c:1505 #, c-format msgid "The '%s' font is not available." msgstr "" #. STID_CANT_CHANGE_SIZEPT_TO_USE_ALT #: ../../strtbl.c:1507 #, c-format msgid "Cannot change size to %1dpt. %1dpt used." msgstr "" #. STID_CANT_CHANGE_SIZE_TO_USE_ALT #: ../../strtbl.c:1509 #, c-format msgid "Cannot change size to %1d. %1d used." msgstr "" #. STID_INVALID_VSPACE_NOT_CHANGED #: ../../strtbl.c:1511 msgid "" "Invalid vertical spacing for a text object. Vertical spacing for that " "object not changed." msgstr "" #. STID_VSPACE_TOO_SMALL_NOT_CHANGED #: ../../strtbl.c:1513 msgid "Text vertical spacing too small. No change." msgstr "„Æ„­„č„È€ÎżâÄŸÊęžț€ÎŽÖłÖ€ŹŸź€”€č€ź€Ț€čĄ„ÊŃč耷€Ț€»€ó." #. STID_ENTER_POINT_SIZE #: ../../strtbl.c:1515 #, fuzzy msgid "Please enter point size:" msgstr "„Ő„©„ó„È€ÎÂ瀭€”€òÆțÎÏ€·€Æ€Ż€À€”€€" #. STID_ENTER_FONT_SIZE #: ../../strtbl.c:1517 msgid "Please enter font size:" msgstr "„Ő„©„ó„È€ÎÂ瀭€”€òÆțÎÏ€·€Æ€Ż€À€”€€" #. STID_FONT_SIZE_TOO_SMALL #: ../../strtbl.c:1519 #, c-format msgid "Font size '%s' too small." msgstr "„Ő„©„ó„È„”„€„ș '%s' €ÏŸź€”€č€ź€Ț€č." #. STID_FONT_SUB_NO_SUCH_FONT_USR_DEF #: ../../strtbl.c:1521 #, c-format msgid "" "%s substituted for font number %d.\n" "\n" "There is no such font. Use default." msgstr "" #. STID_NO_KANJI_FONT_GIVEN_NUMBER #: ../../strtbl.c:1523 #, c-format msgid "There is no kanji-font number %d." msgstr "" #. STID_FAIL_TO_CONN_TO_HOST #: ../../strtbl.c:1525 #, c-format msgid "%s: Fail to connect to server on '%s'." msgstr "%s: '%s' Ÿć€Î„”ĄŒ„ЀۀÎÀÜÂłŒșÇÔ." #. STID_NETWORK_READ_ERROR #: ../../strtbl.c:1527 #, c-format msgid "%s: Network read error." msgstr "" #. STID_NETWORK_ERROR #: ../../strtbl.c:1529 #, c-format msgid "%s: Network error." msgstr "%s: „Í„Ă„È„ïĄŒ„Ż„š„éĄŒ" #. STID_CONN_ABORT_BY_USER #: ../../strtbl.c:1531 #, c-format msgid "%s: Aborted by the user." msgstr "%s: „æĄŒ„¶€Ë€è€ëœȘλ" #. STID_CONN_TERM_BY_SERVER #: ../../strtbl.c:1533 #, c-format msgid "%s: Connection terminated by the server." msgstr "" #. STID_FAIL_TO_OPEN_DATA_SOCKET #: ../../strtbl.c:1535 #, c-format msgid "%s: Fail to open a socket for FTP data port." msgstr "" #. STID_USING_METRIC_SYSTEM #: ../../strtbl.c:1537 msgid "Using Metric system." msgstr "" #. STID_USING_ENGLISH_SYSTEM #: ../../strtbl.c:1539 msgid "Using English system." msgstr "" #. STID_SNAP_NOT_ON_GRID_SZ_SAME #: ../../strtbl.c:1541 msgid "Snap is not on, grid size not changed." msgstr "„č„Ê„Ă„Ś€ÏÍ­žú€Ë€Ê€Ă€Æ€Ț€»€óĄŁ„°„ê„ÄɀÎÂ瀭€”ÊŃčč€Ï€Ç€­€Ț€»€ó" #. STID_AT_MAX_GRID_GRID_SZ_SAME #: ../../strtbl.c:1543 msgid "Already at maximun grid, grid size not changed." msgstr "€č€Ç€Ë„°„ê„ÄɀÏșÇÂç€Ç€čĄŁ„°„ê„ÄɀÎÂ瀭€”ÊŃčč€Ï€Ç€­€Ț€»€ó" #. STID_AT_MIN_GRID_GRID_SZ_SAME #: ../../strtbl.c:1545 msgid "Already at minimum grid, grid size not changed." msgstr "€č€Ç€Ë„°„ê„ÄɀÏșÇŸź€Ç€čĄŁ„°„ê„ÄɀÎÂ瀭€”ÊŃčč€Ï€Ç€­€Ț€»€ó" #. STID_SNAP_TO_GRID_ACTV #: ../../strtbl.c:1547 msgid "Snapping to grid point activated." msgstr "„°„ê„Ă„ÉĆÀ€Ű€Î°ÌĂÖčç€ï€»€òčÔ€€€Ț€č" #. STID_SNAP_TO_GRID_DISABLED #: ../../strtbl.c:1549 msgid "Snapping to grid point disabled." msgstr "" #. STID_WILL_PRINT_IN_COLOR #: ../../strtbl.c:1551 msgid "Will print in color (PS and pixmap)." msgstr "„«„éĄŒ€Ç°őșț€·€Ț€č (PS €Ș€è€Ó „Ó„Ă„È„Ț„Ă„Ś)" #. STID_WILL_PRINT_IN_BW #: ../../strtbl.c:1553 msgid "Will print in black-and-white (PS and bitmap)." msgstr "Çòčő€Ç°őșț€·€Ț€č (PS €Ș€è€Ó „Ó„Ă„È„Ț„Ă„Ś)" #. STID_CONSTRAINED_MOVE #: ../../strtbl.c:1555 msgid "Constrained move." msgstr "čŽÂ«€”€ì€ż°Üư" #. STID_UNCONSTRAINED_MOVE #: ../../strtbl.c:1557 msgid "Unconstrained move." msgstr "čŽÂ«€Î€Ê€€°Üư" #. STID_WILL_DISPLAY_XBM_XPM #: ../../strtbl.c:1559 msgid "Will display bitmap/pixmap." msgstr "bitmap/pixmap €òÉœŒš€·€Ț€č." #. STID_WILL_NOT_DISPLAY_XBM_XPM #: ../../strtbl.c:1565 msgid "Will not display bitmap/pixmap." msgstr "bitmap/pixmap €òÉœŒš€·€Ț€»€ó." #. STID_GRAY_SCALE_IN_BW_PRINTING #: ../../strtbl.c:1567 #, fuzzy msgid "Gray scale enabled in black&white printing." msgstr "„«„éĄŒ€ÈÇòčő°őșț€ÎÀÚÂŰ€š" #. STID_NO_GRAY_SCALE_IN_BW_PRINTING #: ../../strtbl.c:1569 msgid "Gray scale disabled in black&white printing." msgstr "" #. STID_CURRENT_SPEC_IS #: ../../strtbl.c:1571 #, c-format msgid "( current spec: '%s' )" msgstr "" #. STID_ENTER_MEASURE_UNIT_SPEC #: ../../strtbl.c:1573 msgid "" "Please enter '<num> {pixel|cm|in}/<unit>' (e.g., 36 in/yd or 0.1 in/mil):" msgstr "" #. STID_WILL_EXPORT_FORMAT_FILE #: ../../strtbl.c:1575 #, c-format msgid "Will export %s file." msgstr "„Ő„Ą„€„ë %s €òœĐÎÏ€·€Ț€č" #. STID_PRINT_DEV_SET_TO_PRINTER #: ../../strtbl.c:1577 msgid "Print device set to printer." msgstr "„Ś„ê„󄿥Œ€ËœĐÎÏ€·€Ț€č" #. STID_WILL_EXPORT_EPS_FILE #: ../../strtbl.c:1579 msgid "Will export Encapsulated PostScript (LaTeX-Figure) file." msgstr "Encapsulated PostScript (LaTeX-żȚÉœÍŃ) €Î„Ő„Ą„€„ë€òœĐÎÏ€·€Ț€č." #. STID_WILL_EXPORT_RAW_PS_FILE #: ../../strtbl.c:1581 msgid "Will export raw PostScript file." msgstr "PostScript „Ő„Ą„€„ë€òœĐÎÏ€·€Ț€č" #. STID_WILL_EXPORT_XPM_FILE #: ../../strtbl.c:1583 msgid "Will export X11 Pixmap file." msgstr "X11 Pixmap „Ő„Ą„€„ë€òœĐÎÏ€·€Ț€č" #. STID_WILL_EXPORT_XBM_FILE #: ../../strtbl.c:1585 msgid "Will export X11 Bitmap file." msgstr "X11 bitmap „Ő„Ą„€„ë„Ő„Ą„€„ë€òœĐÎÏ€·€Ț€č" #. STID_WILL_EXPORT_TEXT_FILE #: ../../strtbl.c:1587 msgid "Will export ASCII text file." msgstr "„ą„č„­ĄŒ·ÁŒ°€Î„Æ„­„č„È„Ő„Ą„€„ë€òœĐÎÏ€·€Ț€č" #. STID_WILL_EXPORT_EPSI_FILE #: ../../strtbl.c:1589 msgid "Will export EPSI file (EPS with preview bitmap)." msgstr "EPSI „Ő„Ą„€„ë(„Ś„ì„Ó„ćĄŒÍŃ„Ó„Ă„È„Ț„Ă„ŚÉŐ€­EPS)€òœĐÎÏ€·€Ț€č" #. STID_WILL_EXPORT_GIF_FILE #: ../../strtbl.c:1591 msgid "Will export GIF/ISMAP (needs xpm->gif filter) file." msgstr "GIF/ISMAP „Ő„Ą„€„ë(xpm->gif„Ő„Ł„ë„ż€ŹÉŹÍŚ)€òœĐÎÏ€·€Ț€č" #. STID_WILL_EXPORT_HTML_FILE #: ../../strtbl.c:1593 msgid "Will export HTML (with Client-side imagemap) file." msgstr "HTML „Ő„Ą„€„ë(with Client-side imagemap)€òœĐÎÏ€·€Ț€č" #. STID_WILL_EXPORT_PDF_FILE #: ../../strtbl.c:1595 msgid "Will export PDF (needs ps->pdf filter) file." msgstr "PDF „Ő„Ą„€„ë (ps-pdf€Î„Ő„Ł„ë„ż€ŹÉŹÍŚ)€òœĐÎÏ€·€Ț€č" #. STID_WILL_EXPORT_TIFFEPSI_FILE #: ../../strtbl.c:1597 msgid "Will export DOS/Windows EPS/EPSI file." msgstr "DOS/Windows EPS/EPSI „Ő„Ą„€„ë€òœĐÎÏ€·€Ț€č" #. STID_ONE_MOTION_SEL_MOVE_MODE #: ../../strtbl.c:1599 msgid "Click-select-move in one motion mode selected." msgstr "" #. STID_CLICK_SEL_CLICK_MOVE_MODE #: ../../strtbl.c:1601 msgid "Click-select-click-move mode selected." msgstr "" #. STID_CANT_TOGGLE_COLOR_LAYER_BW #: ../../strtbl.c:1603 msgid "Cannot toggle color layers for a black and white display." msgstr "" #. STID_STRETCHABLE_TEXT_MODE #: ../../strtbl.c:1605 msgid "Text objects are stretchable." msgstr "„Æ„­„č„È€òłÈÂçœÌŸźČĀˀ·€Ț€·€ż" #. STID_NON_STRETCHABLE_TEXT_MODE #: ../../strtbl.c:1607 msgid "Text objects are not stretchable." msgstr "„Æ„­„č„È€ÎłÈÂçœÌŸźÉÔČĀˀ·€Ț€·€ż." #. STID_TRANS_PAT_MODE #: ../../strtbl.c:1609 ../../strtbl.c:2529 msgid "Fill and pen patterns are transparent." msgstr "ĆÉ€ê€Ä€Ö€·€È„ڄ󥊄фżĄŒ„ó€ÏÆ©Čá€Ç€č" #. STID_NON_TRANS_PAT_MODE #: ../../strtbl.c:1611 ../../strtbl.c:2527 msgid "Fill and pen patterns are opaque." msgstr "ĆÉ€ê€Ä€Ö€·€È„ڄ󥊄фżĄŒ„ó€ÏÈóÆ©Čá€Ç€č" #. STID_ALREADY_AT_DEF_ZOOM #: ../../strtbl.c:1613 msgid "Already at the default zoom." msgstr "Žû€Ë„DŽՄ©„ë„Ȁ΄șĄŒ„àẰǀč" #. STID_ALREADY_AT_HIGHEST_MAG #: ../../strtbl.c:1615 msgid "Already at highest magnification, can no longer zoom in." msgstr "Žû€Ë„șĄŒ„à€ÏșÇÂç€Ë€Ê€Ă€Æ€Ț€čĄŁ€ł€ì°ÊŸć€Î„șĄŒ„à„€„ó€Ï€Ç€­€Ț€»€ó" #. STID_CURSOR_IGNORED_CSBTN1 #: ../../strtbl.c:1617 msgid "(the cursor position is ignored even though <Cntrl><Shift>Btn1 is used)" msgstr "" #. STID_ZOOMIN_AROUND_EDIT_TEXT #: ../../strtbl.c:1619 msgid "(Zooming in around text being edited..." msgstr "" #. STID_SEL_ZOOM_CENTER #: ../../strtbl.c:1621 msgid "Select zoom center" msgstr "„șĄŒ„à€ÎĂæżŽ€òÁȘÂò" #. STID_ZOOMIN_CANCEL_BY_USER #: ../../strtbl.c:1623 msgid "ZoomIn canceled by the user." msgstr "" #. STID_AT_PAPER_EDGE_CANT_ZOOMOUT #: ../../strtbl.c:1625 msgid "Already at paper boundaries, can no longer zoom out." msgstr "" #. STID_PAGE_STYLE_CHANGE_TO_LAND #: ../../strtbl.c:1627 msgid "Page style changed to LandScape." msgstr "„ÚĄŒ„ž„脿„€„ë€òČŁÄč€Ë€·€Ț€·€ż" #. STID_PAGE_STYLE_CHANGE_TO_PORT #: ../../strtbl.c:1629 msgid "Page style changed to Portrait." msgstr "„ÚĄŒ„ž„脿„€„ë€òœÄÄč€Ë€·€Ț€·€ż" #. STID_WARN_PIN_NOT_SUPPORTED #: ../../strtbl.c:1631 msgid "Warning: Pins are not supported, yet." msgstr "" #. STID_ONE_SIMPLE_GROUP_UNGROUP_ANY #: ../../strtbl.c:1633 msgid "" "Selected object is not a (simple) grouped object.\n" "\n" "Ungroup anyway?" msgstr "" #. STID_ALL_SIMPLE_GROUP_UNGROUP_ANY #: ../../strtbl.c:1635 msgid "" "None of the selected objects are (simple) grouped objects.\n" "\n" "Ungroup anyway?" msgstr "" #. STID_SEL_OBJ_ARE_UNGROUPED #: ../../strtbl.c:1637 msgid "Selected objects are ungrouped." msgstr "ÁȘÂòÂĐŸĘ€Î„°„ëĄŒ„ŚČœ€ÏČòœü€”€ì€Ț€·€ż" #. STID_NO_OBJ_TO_LOCK #: ../../strtbl.c:1639 msgid "No object to lock." msgstr "„í„Ă„Ż€č€ë„Ș„Ö„ž„§„Ż„È€Ź€ą€ê€Ț€»€ó" #. STID_CANNOT_LOCK_IN_VERTEX_MODE #: ../../strtbl.c:1641 msgid "Cannot lock in vertex mode." msgstr "" #. STID_SEL_OBJ_ARE_LOCKED #: ../../strtbl.c:1643 msgid "Selected objects are locked." msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż„È€Ï„í„Ă„Ż€”€ì€Ț€·€ż" #. STID_NO_OBJ_TO_UNLOCK #: ../../strtbl.c:1645 msgid "No object to unlock." msgstr "„í„Ă„ŻČòœü€č€ë„Ș„Ö„ž„§„Ż„È€Ź€ą€ê€Ț€»€ó" #. STID_CANNOT_UNLOCK_IN_VERTEX_MODE #: ../../strtbl.c:1647 msgid "Cannot unlock in vertex mode." msgstr "" #. STID_SEL_OBJ_ARE_UNLOCKED #: ../../strtbl.c:1649 msgid "Selected objects are unlocked." msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż€Ï„í„Ă„Ż€ÏČòœü€”€ì€Ț€·€ż" #. STID_TOOL_VERSION #: ../../strtbl.c:1651 #, c-format msgid "%s Version %s" msgstr "%s „ĐĄŒ„ž„ç„ó %s" #. STID_TOOL_VERSION_SPC_BUILD #: ../../strtbl.c:1653 #, c-format msgid "%s Version %s (%s)" msgstr "%s „ĐĄŒ„ž„ç„ó %s (%s)" #. STID_TOOL_VERSION_PATCH #: ../../strtbl.c:1655 #, c-format msgid "%s Version %s (patchlevel %1d)" msgstr "%s „ĐĄŒ„ž„ç„ó %s („фÄÁ„ì„Ù„ë %1d)" #. STID_TOOL_VERSION_PATCH_SPC_BUILD #: ../../strtbl.c:1657 #, c-format msgid "%s Version %s (patchlevel %1d - %s)" msgstr "%s „ĐĄŒ„ž„ç„ó %s („фÄÁ„ì„Ù„ë %1d - %s)" #. STID_HYPER_TEXT_HOME #: ../../strtbl.c:1659 #, c-format msgid "" "\n" "\n" "WWW Hypertext Home Page: %s" msgstr "" "\n" "\n" "WWW „Ï„€„ŃĄŒ„Æ„­„č„È „ÛĄŒ„àĄŠ„ÚĄŒ„ž: %s" #. STID_LATEST_REL_INFO #: ../../strtbl.c:1661 #, c-format msgid "" "\n" "\n" "Latest Release Information: %s" msgstr "" "\n" "\n" "șÇż·ÈǀΟđÊó: %s" #. STID_HYPER_GRAPHICS_INFO #: ../../strtbl.c:1663 #, c-format msgid "" "\n" "\n" "WWW Hyper-Graphics Home Page: %s" msgstr "" #. STID_MAILING_LIST_INFO #: ../../strtbl.c:1665 #, c-format msgid "" "\n" "\n" "The tgif announcement mailing is %s. To join, please send an empty message " "to %s (you do not need a Yahoo ID to join). The previous tgif mailing list, " "%s, is not longer active." msgstr "" #. STID_SEND_BUG_REPORT_TO #: ../../strtbl.c:1667 #, c-format msgid "" "\n" "\n" "Please send bug reports to %s." msgstr "" #. STID_OPEN_URL_FAIL_USE_BROWSER #: ../../strtbl.c:1669 #, c-format msgid "" "Fail to open '%s' for reading.\n" "\n" "Please view %s with a web browser." msgstr "" #. STID_FIND_VER_FAIL_USE_BROWSER #: ../../strtbl.c:1671 #, c-format msgid "" "Fail to find version information in '%s'.\n" "\n" "Please view %s with a web browser." msgstr "" #. STID_TOOL_CUR_VER_IS_DIFF_INFO #: ../../strtbl.c:1673 #, c-format msgid "" "%s is currently at %s and this %s is Version %s.\n" "\n" "For download information, please visit %s with a web browser." msgstr "" #. STID_TOOL_CUR_VER_IS_DIFF_SPC_INFO #: ../../strtbl.c:1675 #, c-format msgid "" "%s is currently at %s and this %s is Version %s (%s).\n" "\n" "For download information, please visit %s with a web browser." msgstr "" #. STID_TOOL_CUR_VER_PATCH_INFO #: ../../strtbl.c:1677 #, c-format msgid "" "%s is currently at %s and this %s is Version %s Patchlevel %1d.\n" "\n" "For download information, please visit %s with a web browser." msgstr "" #. STID_TOOL_CUR_VER_PATCH_SPC_INFO #: ../../strtbl.c:1679 #, c-format msgid "" "%s is currently at %s and this %s is Version %s Patchlevel %1d (%s).\n" "\n" "For download information, please visit %s with a web browser." msgstr "" #. STID_CANT_DOWNLOAD_VER_USE_BROWSER #: ../../strtbl.c:1681 #, c-format msgid "" "Cannot download '%s' to get version information.\n" "\n" "Please view %s with a web browser." msgstr "" #. STID_FAIL_TO_CONN_TO_HOST_PORT #: ../../strtbl.c:1683 #, c-format msgid "%s: Fail to connect to server on '%s:%1d'." msgstr "" #. STID_LINES_TOO_LONG_CONTENT_LENGTH #: ../../strtbl.c:1685 #, c-format msgid "%s: Unexpected lines too long detected while reading content." msgstr "" #. STID_FAIL_TO_SEND_REQ #: ../../strtbl.c:1687 #, c-format msgid "%s: Fail to send requests." msgstr "" #. STID_INVALID_FORMAT_IN_HEADER #: ../../strtbl.c:1689 #, c-format msgid "%s: Invalid format in the header." msgstr "" #. STID_CHECK_FONT_FAILED_FOR_BROWSE #: ../../strtbl.c:1691 msgid "" "The current font/size/style is not available for labeling objects.\n" "\n" "Please use a different font/size/style for the browse operation you've " "selected." msgstr "" #. STID_ERROR_ENCOUNTERED_WHILE_RECV #: ../../strtbl.c:1693 #, c-format msgid "%s: Error encountered in receiving responses." msgstr "" #. STID_SINGLE_XPM_IMGPROC #: ../../strtbl.c:1695 #, c-format msgid "" "The command you have just selected: '%s' can only work with a single X11 " "Pixmap object." msgstr "" #. STID_USER_INTR #: ../../strtbl.c:1697 msgid "User interrupt." msgstr "" #. STID_CANNOT_IMPORT_XPM_FILE #: ../../strtbl.c:1699 #, c-format msgid "Cannot import X11 Pixmap file '%s'." msgstr "X11 Pixmap „Ő„Ą„€„ë€òÁȚÆț€Ç€­€Ț€»€ó '%s'." #. STID_MAY_USED_UP_COLORS_RETRY #: ../../strtbl.c:1701 msgid "" "May have used up all the colors.\n" "\n" "Would you like to retry it once more?" msgstr "" #. STID_ENTER_PAIR_COLORS_INTERPOLATE #: ../../strtbl.c:1703 msgid "" "Please enter a pair of colors (from dark to bright) for interpolation (e.g., " "Black Yellow):" msgstr "" #. STID_GIVEN_IS_NOT_A_VALID_COLOR #: ../../strtbl.c:1705 #, c-format msgid "'%s' is not a valid color." msgstr "" #. STID_ENTER_VAL_MINUS_PLUS_ONE_BW #: ../../strtbl.c:1707 msgid "Please enter a value between -1.0 (all black) and +1.0 (all white):" msgstr "" #. STID_FAIL_TO_PARSE_FOR_A_VAL #: ../../strtbl.c:1709 #, c-format msgid "Fail to parse '%s' for a value." msgstr "" #. STID_ENTER_VAL_MINUS_PLUS_ONE_SAT #: ../../strtbl.c:1711 msgid "Please enter a value between -1.0 (gray) and +1.0 (saturated):" msgstr "" #. STID_ENTER_VAL_FOR_CHANGE_HUE #: ../../strtbl.c:1713 msgid "" "Please enter two pairs of (color,angle) values: (e.g., \"red 60 green 60\" " "maps all reddish to greenish colors)" msgstr "" #. STID_FAIL_TO_PARSE_FOR_4_VAL #: ../../strtbl.c:1715 #, c-format msgid "Fail to parse '%s' for 4 values." msgstr "" #. STID_ENTER_VAL_FOR_CONTRAST_ENH #: ../../strtbl.c:1717 msgid "Please enter a non-negative value (1.0 means no adjustment):" msgstr "" #. STID_GIVEN_NEG_VAL_NOT_ALLOWED #: ../../strtbl.c:1719 #, c-format msgid "Nevative value: '%s' is not allowed." msgstr "" #. STID_ENTER_VAL_FOR_COLOR_BAL #: ../../strtbl.c:1721 msgid "Please enter non-negative R G B factors (1.0 1.0 1.0 means no change):" msgstr "" #. STID_FAIL_TO_PARSE_FOR_3_VAL #: ../../strtbl.c:1723 #, c-format msgid "Fail to parse '%s' for 3 values." msgstr "" #. STID_ENTER_VAL_FOR_GAMMA #: ../../strtbl.c:1725 msgid "Please enter a gamma value (1.0 means no change, 2.2 is brighter):" msgstr "" #. STID_SEL_TOO_THIN_FLAT_FOR_EDGE #: ../../strtbl.c:1727 msgid "Selected object is too thin or flat for edge detection." msgstr "" #. STID_SEL_TOO_THIN_FLAT_FOR_EMBOSS #: ../../strtbl.c:1729 msgid "Selected object is too thin or flat for embossing." msgstr "" #. STID_ENTER_NUM_COLORS_TO_REDUCE_TO #: ../../strtbl.c:1731 #, c-format msgid "Please enter the number of colors to reduce to (from %1d colors):" msgstr "" #. STID_NUM_COLORS_BETWEEN_2_N_GIVEN #: ../../strtbl.c:1733 #, c-format msgid "Number of colors: '%s' must be between 2 and %1d." msgstr "" #. STID_SEL_XPM_FILE_FOR_RED_COLORS #: ../../strtbl.c:1735 msgid "Please select an X11 Pixmap file for colors..." msgstr "" #. STID_INVALID_GIVEN_XPM_FILE #: ../../strtbl.c:1737 #, c-format msgid "Invalid X11 Pixmap file '%s.'" msgstr "" #. STID_Q_FS_ERROR_DIFFUSE #: ../../strtbl.c:1739 msgid "Would you like to apply Floyd-Steinberg error diffusion (slow)?" msgstr "" #. STID_ENTER_NUM_BITS_IN_RGB #: ../../strtbl.c:1741 #, c-format msgid "" "Please enter number of bits to use for R, G, and B (current [R G B] levels " "are [%1d %1d %1d]):" msgstr "" #. STID_RGB_LEVELS_CHANGED_TO #: ../../strtbl.c:1743 #, c-format msgid "Levels changed to: [%1d %1d %1d]." msgstr "" #. STID_BAD_VAL_SUM_RGB_LEVEL #: ../../strtbl.c:1745 #, c-format msgid "Bad values: '%s'. R+G+B must be <= 8." msgstr "" #. STID_BAD_VAL_GT_0_RGB_LEVEL #: ../../strtbl.c:1747 #, c-format msgid "Bad values: '%s'. Values must all be > 0." msgstr "" #. STID_RGB_LEVELS_ARE #: ../../strtbl.c:1749 #, c-format msgid "[R G B] levels are [%1d %1d %1d]." msgstr "" #. STID_ENTER_INT_AMT_TO_SPREAD #: ../../strtbl.c:1751 msgid "Please enter an integer amount to spread:" msgstr "" #. STID_SEL_TOO_THIN_FLAT_FOR_SHARPEN #: ../../strtbl.c:1753 msgid "Selected object is too thin or flat for sharpening." msgstr "" #. STID_SEL_TOO_THIN_FLAT_FOR_BLUR #: ../../strtbl.c:1755 #, c-format msgid "Selected object is too thin or flat for %1d by %1d blurring." msgstr "" #. STID_IMAGE_PROC_CANT_USE_XFORMED #: ../../strtbl.c:1757 #, c-format msgid "" "'%s' cannot operate on stretched/rotated/sheared pixmap objects.\n" "\n" "You can use '%s' in the ImageProc Menu to regenerate these objects." msgstr "" #. STID_SEL_3_XPM_FOR_IMAGEPROC_CMD #: ../../strtbl.c:1759 #, c-format msgid "Please select 3 X11 Pixmap object for the '%s' command." msgstr "" #. STID_SEL_2_XPM_FOR_IMAGEPROC_CMD #: ../../strtbl.c:1761 #, c-format msgid "Please select 2 X11 Pixmap object for the '%s' command." msgstr "" #. STID_PICK_PT_WITHIN_IMAGE_BOUND #: ../../strtbl.c:1763 msgid "Please pick a starting point within the image boundary" msgstr "" #. STID_IMG_TOO_SMALL_FOR_IMAGEPROC_CMD #: ../../strtbl.c:1769 #, c-format msgid "Image is too small for the '%s' command." msgstr "" #. STID_NO_WARPING #: ../../strtbl.c:1771 msgid "No warping." msgstr "" #. STID_START_LINE_SEG_DOTS #: ../../strtbl.c:1773 #, fuzzy msgid "Start line segment..." msgstr "ÄŸÀț/ÀȚ€ìÀț" #. STID_ENDT_LINE_SEG_DOTS #: ../../strtbl.c:1775 #, fuzzy msgid "End line segment..." msgstr "ÄŸÀț/ÀȚ€ìÀț" #. STID_ENTER_IMAGE_SIZE_IN_PIX_RC #: ../../strtbl.c:1777 msgid "Please enter image size in pixels: [Col x Row]" msgstr "" #. STID_FAIL_TO_EXECUTE_CMD #: ../../strtbl.c:1779 #, c-format msgid "Fail to execute '%s'." msgstr "" #. STID_ENTER_CMD_OP_FOR_BGGEN #: ../../strtbl.c:1781 msgid "Please enter command options for 'bggen' (e.g., 'blue magenta'):" msgstr "" #. STID_NEW_XPM_WH_GENERATED #: ../../strtbl.c:1783 #, c-format msgid "New X11 Pixmap object (%1dx%1d) generated." msgstr "" #. STID_ENTER_GRAY_LEVELS_222 #: ../../strtbl.c:1785 msgid "Please enter number of gray levels (between 2 and 222):" msgstr "" #. STID_INVALID_GIVEN_VALUE_ENTERED #: ../../strtbl.c:1787 #, c-format msgid "Invalid value '%s' entered." msgstr "" #. STID_ENTER_COLOR_FOR_RECT_BGGEN #: ../../strtbl.c:1789 msgid "Please enter a color for the rectangle (e.g., magenta, #808080):" msgstr "" #. STID_CANNOT_PARSE_NAMED_COLOR #: ../../strtbl.c:1791 #, c-format msgid "Cannot parse color: '%s'." msgstr "" #. STID_XPM_NOT_XFORMED_REGEN_ANYWAY #: ../../strtbl.c:1793 msgid "" "Selected object is not stretched/rotated/sheared.\n" "\n" "Would you like to regenerate it anyway?" msgstr "" #. STID_DRAG_A_RECT_TO_CROP #: ../../strtbl.c:1795 msgid "Please drag out a rectangular area to crop..." msgstr "„­„ㄌ„Á„ă€č€ë¶ë·Á„š„ê„ą€ò„É„é„Ă„°€·€Æ€Ż€À€”€€..." #. STID_START_CROP_IMAGE #: ../../strtbl.c:1797 msgid "Start crop image" msgstr "ČèÁüÀÚŒè€êł«»Ï" #. STID_END_CROP_IMAGE #: ../../strtbl.c:1799 msgid "End crop image" msgstr "ČèÁüÀÚŒè€êœȘλ" #. STID_ABORT_CROP_IMAGE #: ../../strtbl.c:1801 msgid "Abort crop image" msgstr "ČèÁüÀÚŒè€êĂæĂÇ" #. STID_SELECT_A_COLOR #: ../../strtbl.c:1803 msgid "Select a color" msgstr "ż§€òÁȘÂò" #. STID_SEL_A_COLOR_TO_USE_AS_CUR #: ../../strtbl.c:1805 msgid "Please select a color to be used as the current color..." msgstr "»È€Šż§€òÁȘ€ó€Ç€Ż€À€”€€ĄŁ" #. STID_SEL_AREA_NOT_INTERSECT_IMAGE #: ../../strtbl.c:1807 #, fuzzy msgid "Selected area does not intersect selected image." msgstr "ÁȘÂòČèÁü€ÎÎŰłÔĂêœĐ€ò€č€ë" #. STID_SEL_PT_NOT_ON_IMAGE #: ../../strtbl.c:1809 #, fuzzy msgid "Selected point is not on the selected image." msgstr "ÁȘÂò€·€żČèÁü€Î„ł„ó„È„é„č„ÈÄŽÀá" #. STID_ONE_PRIM_FOR_IMAGEPROC_CMD #: ../../strtbl.c:1811 #, c-format msgid "Please select only one primitive object for the '%s' command." msgstr "" #. STID_DARG_TO_FILL_AN_AREA #: ../../strtbl.c:1813 msgid "Drag to fill an area..." msgstr "" #. STID_SEL_A_COLOR_TO_BE_REPLACED #: ../../strtbl.c:1815 #, fuzzy msgid "Please select a color to be replaced by the current color..." msgstr "ÁȘÂòČèÁü€«€éż§€òŒè€êčț€ßĄąžœș߀ÎÁȘÂòż§€Ë€č€ë" #. STID_SEL_A_COLOR_TO_REPLACE #: ../../strtbl.c:1817 #, fuzzy msgid "Select a color to replace" msgstr "ÍŃ»æ€Îż§€òÀßÄê€č€ë" #. STID_BTN1_FLOODFILL_BTN3_SET_COLOR #: ../../strtbl.c:1819 #, fuzzy msgid "<Btn1>: Flood-fill, <Btn3>: Set a pixel to current color." msgstr "ÁȘÂòż§€ÇÁȘÂòČèÁü€òĆÉ€ê€Ä€Ö€č" #. STID_ESC_TO_FINISH #: ../../strtbl.c:1821 msgid "<ESC> to finish." msgstr "<ESC> €ÇœȘλ" #. STID_FLOOD_FILL #: ../../strtbl.c:1823 #, fuzzy msgid "Flood-fill" msgstr "ĆÉ€ê€Ä€Ö€·" #. STID_SET_A_PIXEL #: ../../strtbl.c:1825 msgid "Set a pixel" msgstr "" #. STID_NO_CONTOUR_CAN_BE_GEN_HERE #: ../../strtbl.c:1827 msgid "No contour can be generated from here." msgstr "" #. STID_SEL_A_COLOR_TO_BE_TRACED #: ../../strtbl.c:1829 msgid "Please select a color to be traced..." msgstr "" #. STID_START_CONTOUR #: ../../strtbl.c:1831 msgid "Start contour" msgstr "ÎŰłÔÀț€Î»Ï€Ț€ê" #. STID_INVALID_XDEF_RNG_USE_ALT_VAL #: ../../strtbl.c:1833 #, c-format msgid "" "Invalid %s.%s: '%s', (must be between %1d and %1d), %1d is used instead." msgstr "" #. STID_VAL_TOO_LARGE_IN_XDEF_USE_ALT #: ../../strtbl.c:1835 #, c-format msgid "Values too large in %s.%s: '%s', '%s' is used instead." msgstr "" #. STID_VAL_TOO_SMALL_IN_XDEF_USE_ALT #: ../../strtbl.c:1837 #, c-format msgid "Values too small in %s.%s: '%s', '%s' is used instead." msgstr "" #. STID_INVALID_GIVEN_PATH_MUST_FULL #: ../../strtbl.c:1839 #, c-format msgid "Invalid path: '%s'. Must use a full path name." msgstr "" #. STID_CANNOT_SET_LOCALE_ENV_VARS #: ../../strtbl.c:1841 msgid "Cannot set to the locale specified by the environment variables." msgstr "" #. STID_XT_CANNOT_SET_LOCALE_ENV_VARS #: ../../strtbl.c:1843 msgid "" "Xtoolkit cannot set to the locale specified by the environment variables." msgstr "" #. STID_XLIB_CANT_SET_LOCALE_ENV_VARS #: ../../strtbl.c:1845 msgid "Xlib cannot set to the locale specified by the environment variables." msgstr "" #. STID_CANT_SET_LOCALE_MODIFIERS #: ../../strtbl.c:1847 msgid "Cannot set locale modifiers." msgstr "" #. STID_LOCALE_DIR_NOT_EXIST_USE_XDEF #: ../../strtbl.c:1849 #, c-format msgid "" "Locale directory '%s' does not exist. Please specify locale direory with %s." "%s." msgstr "" #. STID_WARN_CANT_PUTENV_GIVEN #: ../../strtbl.c:1851 #, c-format msgid "Warning: Cannot putenv(%s)." msgstr "" #. STID_CANT_OPEN_DISPLAY_ABORT #: ../../strtbl.c:1853 msgid "Could not open the default display. Abort." msgstr "" #. STID_CANT_OPEN_GIVEN_DPY_ABORT #: ../../strtbl.c:1855 #, c-format msgid "Could not open display '%s'. Abort." msgstr "" #. STID_CUR_EMPTY_FILE_IS #: ../../strtbl.c:1857 #, c-format msgid "Current (empty) file is '%s'." msgstr "" #. STID_LEFT_STEP_MID_RUN_RIGHT_STOP #: ../../strtbl.c:1859 msgid "Left:step. Middle:run. Right:stop." msgstr "" #. STID_CANT_FIND_POLY_WITH_GIVEN_ID #: ../../strtbl.c:1861 #, c-format msgid "Cannot find poly with id=%1d." msgstr "" #. STID_CANT_FIND_OBJ_WITH_GIVEN_ID #: ../../strtbl.c:1863 #, c-format msgid "Cannot find object with id=%1d." msgstr "" #. STID_CANT_FIND_ATTR_NAME_AND_COLOR #: ../../strtbl.c:1865 #, c-format msgid "Cannot find attr name '%s' and color '%s'." msgstr "" #. STID_BAD_FLTR_SPEC_DEF #: ../../strtbl.c:1867 msgid "" "Invalid %s.%s: '%s'.\n" "\n" "Format is '<name> <extensions> <filter spec>', e.g.,\n" "\n" " JPEG jpg;jpeg djpeg -gif -colors 222 %%s | giftopnm | ppmtoxpm" msgstr "" #. STID_BAD_FLTR_SPEC_MISS_PERC_S #: ../../strtbl.c:1869 msgid "" "Invalid %s.%s: '%s' (missing %%s).\n" "\n" "Format is '<name> <extensions> <filter spec>', e.g.,\n" "\n" " JPEG jpg;jpeg djpeg -gif -colors 222 %%s | giftopnm | ppmtoxpm" msgstr "" #. STID_BAD_FLTR_SPEC_MANY_PERC_S #: ../../strtbl.c:1871 msgid "" "Invalid %s.%s: '%s' (too many %%s).\n" "\n" "Format is '<name> <extensions> <filter spec>', e.g.,\n" "\n" " JPEG jpg;jpeg djpeg -gif -colors 222 %%s | giftopnm | ppmtoxpm" msgstr "" #. STID_BAD_XDEF_MUST_BE_GT_0 #: ../../strtbl.c:1873 #, c-format msgid "Invalid %s.%s: '%s'. Value must be > 0." msgstr "" #. STID_CANT_FIND_XDEF_CONT_LOOK_FLTR #: ../../strtbl.c:1875 #, c-format msgid "" "Cannot find %s.%s.\n" "\n" "Would you like to continue looking for filters?" msgstr "" #. STID_SEL_XBM_FILE_TO_IMPORT #: ../../strtbl.c:1877 msgid "Please select an X11 Bitmap file to IMPORT..." msgstr "" #. STID_CANNOT_IMPORT_XBM_FILE #: ../../strtbl.c:1879 #, c-format msgid "Cannot import X11 Bitmap file '%s'." msgstr "X11 bitmap „Ő„Ą„€„ë '%s'€òÁȚÆț€Ç€­€Ț€»€ó" #. STID_ENTER_GEOM_SPEC_ORIG_SIZE #: ../../strtbl.c:1881 #, c-format msgid "Please enter geometry spec: [[MAG=]WxH+X+Y] (original size is %1dx%1d)" msgstr "" #. STID_GIVEN_XBM_SIZE_FILE_IMPORTED #: ../../strtbl.c:1883 #, c-format msgid "X11 Bitmap file (%1dx%1d) '%s' imported." msgstr "" #. STID_GIVEN_XPM_SIZE_FILE_IMPORTED #: ../../strtbl.c:1885 #, c-format msgid "X11 Pixmap file (%1dx%1d) '%s' imported." msgstr "" #. STID_SEL_XPM_FILE_TO_IMPORT #: ../../strtbl.c:1887 msgid "Please select an X11 Pixmap file to IMPORT..." msgstr "" #. STID_SEL_EPS_FILE_TO_IMPORT #: ../../strtbl.c:1889 msgid "Please select an EPS file to IMPORT..." msgstr "" #. STID_IMPORT_REM_EPS_EMBED_INSTEAD #: ../../strtbl.c:1891 msgid "" "Importing (linking to) a remote EPS file is not supported. Would you like " "to embed the EPS file instead?" msgstr "" #. STID_GIVEN_EPS_FILE_IMPORTED #: ../../strtbl.c:1893 #, c-format msgid "EPS file '%s' imported." msgstr "" #. STID_SEL_GIF_FILE_TO_IMPORT #: ../../strtbl.c:1895 msgid "Please select a GIF file to IMPORT..." msgstr "" #. STID_CANNOT_IMPORT_GIVEN_GIF #: ../../strtbl.c:1897 #, c-format msgid "Cannot import GIF file '%s'." msgstr "GIF„Ő„Ą„€„ë '%s'€òÁȚÆț€Ç€­€Ț€»€ó." #. STID_GIVEN_GIF_SIZE_FILE_IMPORTED #: ../../strtbl.c:1899 #, c-format msgid "GIF file (%1dx%1d) '%s' imported." msgstr "" #. STID_CANT_FIND_ANY_IMP_FLTR_SPEC #: ../../strtbl.c:1901 #, c-format msgid "" "Cannot find any import filter specifications.\n" "\n" "Import filters are specified with %s.%s and %s.%s X resources." msgstr "" #. STID_SEL_AN_IMPORT_FILTER #: ../../strtbl.c:1903 msgid "Please select an import filter..." msgstr "" #. STID_SEL_A_TYPE_FILE_TO_IMPORT #: ../../strtbl.c:1905 #, c-format msgid "Please select a %s file to IMPORT..." msgstr "" #. STID_CANT_IMPORT_GIVEN_TYPE_FILE #: ../../strtbl.c:1907 #, c-format msgid "Cannot import %s file '%s'." msgstr "" #. STID_GIVEN_TYPE_SIZE_FILE_IMPORTED #: ../../strtbl.c:1909 #, c-format msgid "%s file (%1dx%1d) '%s' imported." msgstr "" #. STID_INVALID_FMT_IN_SHORTCUT_SPEC #: ../../strtbl.c:1911 #, c-format msgid "Invalid format in shortcut specification of %s(%s)." msgstr "" #. STID_CANT_FIND_NAMED_IMP_FLTR #: ../../strtbl.c:1913 #, c-format msgid "Cannot find any import filter named '%s'." msgstr "" #. STID_SEL_ANIM_GIF_FILE_TO_IMPORT #: ../../strtbl.c:1915 msgid "Please select an animated GIF file to IMPORT..." msgstr "" #. STID_CANT_EXEC_CMD_IMPORT_ANIM_GIF #: ../../strtbl.c:1917 #, c-format msgid "" "Cannot execute '%s'.\n" "\n" "Animated GIF not imported." msgstr "" #. STID_Q_LIKE_TO_USE_AN_IMP_FLTR_GIF #: ../../strtbl.c:1919 msgid "" "Would you like to use an import filter when importing individual GIF files?" msgstr "" #. STID_CANT_CREATE_NAMED_TMP_FILE #: ../../strtbl.c:1921 #, c-format msgid "Cannot create temporary file: '%s'." msgstr "" #. STID_CANT_IMP_ANIM_GIF_TMP_DIR #: ../../strtbl.c:1923 #, c-format msgid "" "Cannot import GIF animation file '%s'. Please make sure that you can write " "to the '%s' directory." msgstr "" #. STID_CANT_IMP_GIVEN_ANIM_GIF #: ../../strtbl.c:1925 #, c-format msgid "Cannot import GIF animation file '%s'." msgstr "" #. STID_ONLY_ONE_GIF_COMP_EXTRACTED #: ../../strtbl.c:1927 #, c-format msgid "Only one GIF component extracted from '%s'." msgstr "" #. STID_ANIMATING_GIVEN #: ../../strtbl.c:1929 #, c-format msgid "Animating '%s'..." msgstr "" #. STID_GIF_ANIMATION_STOPPED #: ../../strtbl.c:1931 msgid "GIF animation stopped." msgstr "GIF„ą„Ë„áĄŒ„·„ç„óÄä»ß" #. STID_PRESS_ESC_TO_STOP #: ../../strtbl.c:1933 msgid "(press <ESC> to stop)" msgstr "" #. STID_BROWSING_DIR_FOR_TYPE_FILES #: ../../strtbl.c:1935 #, c-format msgid "Browsing '%s' for %s files..." msgstr "" #. STID_SKIP_GIVEN_FILE_SYM_LINK #: ../../strtbl.c:1937 #, c-format msgid "Skipping '%s' because it's a symbolic link." msgstr "" #. STID_WORKING_DIR_IS_GIVEN #: ../../strtbl.c:1939 #, c-format msgid "Working directory: '%s'" msgstr "žœșß€Î„Ç„Ł„ì„Ż„È„ê: '%s'" #. STID_MORE_THAN_ONE_CMAP_INSTALLED #: ../../strtbl.c:1941 msgid "More than one colormap installed." msgstr "" #. STID_FIRST_ONE_ON_LIST_USED #: ../../strtbl.c:1943 msgid "First one on the list is used." msgstr "" #. STID_SPECIFY_AREA #: ../../strtbl.c:1945 msgid "Specify area" msgstr "ÈϰϻŰÄê" #. STID_SPECIFY_DELAY_FULL_SCR_CAP #: ../../strtbl.c:1947 msgid "Please specify a delay (in seconds) for full screen capture:" msgstr "" #. STID_WILL_HIDE_TOOL_WHILE_CAPTURE #: ../../strtbl.c:1949 #, c-format msgid "Will hide %s during capturing." msgstr "„­„ㄌ„Á„ă€ÎŽÖ %s €ò±Ł€·€Ț€č" #. STID_WILL_SHOW_TOOL_WHILE_CAPTURE #: ../../strtbl.c:1951 #, c-format msgid "Will leave %s alone during capturing." msgstr "" #. STID_FUNC_SELECT_SYS_CALL_FAILED #: ../../strtbl.c:1953 #, c-format msgid "In %s: select() system call failed." msgstr "" #. STID_FUNC_INVALID_RC_FOR_SELECT #: ../../strtbl.c:1955 #, c-format msgid "In %s: Invalid return code of %1d from the select() system call." msgstr "" #. STID_CNTRL_C_ABORT_LAUNCH #: ../../strtbl.c:1957 msgid "" "You have typed a ^C. Do you want to abort the command that's being executed?" " (If the command is running in an xterm, please try killing or destroying " "the xterm from the desktop first before doing an abort.)" msgstr "" #. STID_CMD_ABORT_LAUNCH_CLOSE_TOOL #: ../../strtbl.c:1959 #, c-format msgid "" "The '%s' command is aborted.\n" "\n" "However, it's not safe to actually kill the command. Therefore, please " "close %s at the next convenient point." msgstr "" #. STID_INVALID_GIVEN_ATTR_SPEC #: ../../strtbl.c:1961 #, c-format msgid "Invalid attribute specification: '%s'." msgstr "" #. STID_LAUNCH_NOT_AUTO_IN_HYPER_EXEC #: ../../strtbl.c:1963 #, c-format msgid "" "Launching is not automatic in hyperspace. Do you want to execute to " "following command?\n" "\n" " %s\n" "\n" "(If you are not sure about this, just click on NO.)" msgstr "" #. STID_USER_ABORT_LAUNCH_IN_HYPER #: ../../strtbl.c:1965 msgid "Launching in hyperspace aborted at user's request." msgstr "" #. STID_MALFORMED_CMD_EXEC_ABORT #: ../../strtbl.c:1967 #, c-format msgid "" "Malformed '%s' command.\n" "\n" "Command execution aborted." msgstr "" #. STID_NO_OBJ_SEL_WHILE_EXEC_CMD #: ../../strtbl.c:1973 #, c-format msgid "No object is selected while executing the '%s' command." msgstr "" #. STID_CANT_FIND_NAMED_ATTR_EXEC #: ../../strtbl.c:1975 #, c-format msgid "Cannot find the '%s' attribute while executing the '%s' command." msgstr "" #. STID_FILE_ATTR_NOT_ALLOWED_FOR_CMD #: ../../strtbl.c:1977 #, c-format msgid "File attribute '%s' is not appropriate for the '%s' command." msgstr "" #. STID_CANT_FIND_NAMED_OBJ_EXEC #: ../../strtbl.c:1979 #, c-format msgid "Cannot find object named '%s' while executing the '%s' command." msgstr "" #. STID_INVALID_ARG_WHILE_EXEC_CMD #: ../../strtbl.c:1981 #, c-format msgid "Invalid '%s' while executing the '%s' command." msgstr "" #. STID_MODIFY_FILE_ATTR_IN_WB #: ../../strtbl.c:1983 msgid "Cannot modify file attributes in WhiteBoard mode." msgstr "" #. STID_USER_INTR_TOOL_WAIT_CLEANUP #: ../../strtbl.c:1985 #, c-format msgid "" "User interrupt received. %s is waiting for clean up to complete.\n" "\n" "Are you sure you don't want to wait for clean up to complete (this may leave " "the scripts in an inconsistent state)?" msgstr "" #. STID_FUNC_USER_INTR #: ../../strtbl.c:1987 #, c-format msgid "%s(): User interrupt." msgstr "" #. STID_BAD_EVAL_INT_EXP_EXEC_CMD #: ../../strtbl.c:1989 #, c-format msgid "" "Invalid evaluation '%s' used (integer expected) while executing the '%s' " "command." msgstr "" #. STID_BAD_EVAL_FLOAT_EXP_EXEC_CMD #: ../../strtbl.c:1991 #, c-format msgid "" "Invalid evaluation '%s' used (floating pointer number expected) while " "executing the '%s' command." msgstr "" #. STID_FAIL_FUNC_CMD_EXEC_ABORT #: ../../strtbl.c:1993 #, c-format msgid "Fail to %s. Command execution aborted." msgstr "" #. STID_FUNC_ONLY_WORK_COMPOSITE_OBJ #: ../../strtbl.c:1995 #, c-format msgid "%s() only works with composite objects." msgstr "" #. STID_FUNC_FAIL_TO_IMPORT_GIVEN #: ../../strtbl.c:1997 #, c-format msgid "%s(): Fail to import '%s'." msgstr "" #. STID_FUNC_OBJ_NON_XBM_XPM_SUB_OBJS #: ../../strtbl.c:1999 #, c-format msgid "%s(): Object contains non-Bitmap/Pixmap sub-objects." msgstr "" #. STID_WILL_EXPORT_PNG_FILE #: ../../strtbl.c:2001 msgid "Will export PNG (needs xpm->png filter) file." msgstr "" #. STID_CANNOT_IMPORT_GIVEN_PNG #: ../../strtbl.c:2003 #, c-format msgid "Cannot import PNG file '%s'." msgstr "PNG„Ő„Ą„€„ë '%s' €òÁȚÆț€Ç€­€Ț€»€ó." #. STID_GIVEN_PNG_SIZE_FILE_IMPORTED #: ../../strtbl.c:2005 #, c-format msgid "PNG file (%1dx%1d) '%s' imported." msgstr "PNG„Ő„Ą„€„ë (%1dx%1d) '%s' €ŹÁȚÆț€”€ì€Ț€·€ż." #. STID_SEL_PNG_FILE_TO_IMPORT #: ../../strtbl.c:2007 msgid "Please select a PNG file to IMPORT..." msgstr "ÁȚÆț€č€ë PNG „Ő„Ą„€„ë€òÁȘÂò€·€Æ€Ż€À€”€€." #. STID_FUNC_DIFF_SZ_XBM_XPM_SUBOBJS #: ../../strtbl.c:2009 #, c-format msgid "%s(): Different sizes Bitmap/Pixmap sub-objects." msgstr "" #. STID_FUNC_MORE_1_XBM_XPM_SUBOBJS #: ../../strtbl.c:2011 #, c-format msgid "%s(): Must have > 1 Bitmap/Pixmap sub-objects." msgstr "" #. STID_FUNC_ARG_RANGE #: ../../strtbl.c:2013 #, c-format msgid "" "%s(): '%s' must be between %1d and %1d (inclusive).\n" "\n" "%1d was specified." msgstr "" #. STID_FUNC_UNDEFINED_ARG #: ../../strtbl.c:2015 #, c-format msgid "%s(): Undefined '%s'." msgstr "" #. STID_INTERNAL_CMD_SELECT_FAILED #: ../../strtbl.c:2017 #, c-format msgid "%s(): select() system call failed." msgstr "" #. STID_CANT_OPEN_FILE_READ_EXEC_CMD #: ../../strtbl.c:2019 #, c-format msgid "Cannot open '%s' for reading while executing the '%s' command." msgstr "" #. STID_FAIL_TO_EXECUTE_CMD_EXEC_CMD #: ../../strtbl.c:2021 #, c-format msgid "Fail to execute '%s' while executing the '%s' command." msgstr "" #. STID_UNEXP_ERR_EXEC_CMD_ABORT #: ../../strtbl.c:2023 #, c-format msgid "" "Unexpected error while executing the '%s' command.\n" "\n" "Command execution aborted." msgstr "" #. STID_BAD_NAME_TOP_LEVEL_ONLY_CMD #: ../../strtbl.c:2025 #, c-format msgid "" "Bad object name: '%s'.\n" "\n" "Only top level object can be selected while executing the '%s' command." msgstr "" #. STID_BAD_CURSOR_WHILE_EXEC_CMD #: ../../strtbl.c:2027 #, c-format msgid "Cannot create the '%s' cursor while executing the '%s' command." msgstr "" #. STID_BAD_COLOR_NAME_WHILE_EXEC_CMD #: ../../strtbl.c:2029 #, c-format msgid "Fail to allocate the '%s' color while executing the '%s' command." msgstr "" #. STID_WIDTH_RANGE_WHILE_EXEC_CMD #: ../../strtbl.c:2031 #, c-format msgid "Line width of '%s' is out of range while executing the '%s' command." msgstr "" #. STID_SPLINE_TYPE_WHILE_EXEC_CMD #: ../../strtbl.c:2033 #, c-format msgid "Invalid spline type of '%s' used while executing the '%s' command." msgstr "" #. STID_ARROW_STYLE_WHILE_EXEC_CMD #: ../../strtbl.c:2035 #, c-format msgid "Invalid arrow style of '%s' used while executing the '%s' command." msgstr "" #. STID_DASH_INDEX_WHILE_EXEC_CMD #: ../../strtbl.c:2037 #, c-format msgid "Invalid dash index of '%s' used while executing the '%s' command." msgstr "" #. STID_RCB_RAD_RANGE_WHILE_EXEC_CMD #: ../../strtbl.c:2039 #, c-format msgid "Rcbox radius of '%s' is out of range while executing the '%s' command." msgstr "" #. STID_BAD_TEXT_JUST_WHILE_EXEC_CMD #: ../../strtbl.c:2041 #, c-format msgid "" "Invalid text justification of '%s' used while executing the '%s' command." msgstr "" #. STID_BAD_FONT_NAME_WHILE_EXEC_CMD #: ../../strtbl.c:2043 #, c-format msgid "Invalid font name of '%s' used while executing the '%s' command." msgstr "" #. STID_UNDO_BUF_FLUSHED_BY_CMD #: ../../strtbl.c:2045 #, c-format msgid "Undo buffer flushed by %s()." msgstr "" #. STID_BAD_EVAL_NUM_EXP_EXEC_CMD #: ../../strtbl.c:2047 #, c-format msgid "" "Invalid evaluation '%s' used (numeric value expected) while executing the '%" "s' command." msgstr "" #. STID_WRITE_CUT_BUF_WHILE_EXEC_CMD #: ../../strtbl.c:2049 #, c-format msgid "Writing to cut buffer failed while executing the '%s' command." msgstr "" #. STID_CANT_FIND_DOT_WHILE_EXEC_CMD #: ../../strtbl.c:2051 #, c-format msgid "Cannot find '.' in '%s%c%s' while executing the '%s' command." msgstr "" #. STID_BAD_WIDTH_WHILE_EXEC_CMD #: ../../strtbl.c:2053 #, c-format msgid "Invalid width of '%s' used while executing the '%s' command." msgstr "" #. STID_BAD_HEIGHT_WHILE_EXEC_CMD #: ../../strtbl.c:2055 #, c-format msgid "Invalid height of '%s' used while executing the '%s' command." msgstr "" #. STID_BAD_STYLE_WHILE_EXEC_CMD #: ../../strtbl.c:2057 #, c-format msgid "Invalid style of '%s' used while executing the '%s' command." msgstr "" #. STID_TOO_MANY_OBJ_WHILE_EXEC_CMD #: ../../strtbl.c:2059 #, c-format msgid "Too many objects selected while executing the '%s' command." msgstr "" #. STID_BAD_ATTR_NAME_WHILE_EXEC_CMD #: ../../strtbl.c:2061 #, c-format msgid "Illegal attribute name '%s' used while executing the '%s' command." msgstr "" #. STID_END_AN_EDGE_AT_A_PORT #: ../../strtbl.c:2063 msgid "Please end an edge at a port..." msgstr "" #. STID_DRAW_AN_EDGE_BETWEEN_PORTS #: ../../strtbl.c:2065 msgid "Please draw an edge between ports..." msgstr "" #. STID_CANT_FIND_VRTX_WHILE_EXEC_CMD #: ../../strtbl.c:2067 #, c-format msgid "" "Cannot find vertex %1d for an object named '%s' while executing the '%s' " "command." msgstr "" #. STID_POLY_NOR_PGON_WHILE_EXEC_CMD #: ../../strtbl.c:2069 #, c-format msgid "" "'%s' is neither a poly nor a polygon object while executing the '%s' command." msgstr "" #. STID_BAD_REM_FNAME_WHILE_EXEC_CMD #: ../../strtbl.c:2071 #, c-format msgid "Invalid remote file name '%s' used while executing the '%s' command." msgstr "" #. STID_CANT_OPEN_FILE_WRITE_EXEC_CMD #: ../../strtbl.c:2073 #, c-format msgid "Cannot open '%s' for writing while executing the '%s' command." msgstr "" #. STID_GIVEN_CMD_EXECUTED #: ../../strtbl.c:2075 #, c-format msgid "%s() command executed." msgstr "" #. STID_SQRT_NEG_NUM_WHILE_EXEC_CMD #: ../../strtbl.c:2077 #, c-format msgid "%s() domain error: Cannot take square-root of a negative number." msgstr "" #. STID_CMD_NOT_AVAIL_ON_PLATFORM #: ../../strtbl.c:2079 #, c-format msgid "The %s() command is not available on this platform." msgstr "" #. STID_BAD_SHORTCUT_WHILE_EXEC_CMD #: ../../strtbl.c:2081 #, c-format msgid "Invalid shortcut name '%s' used while executing the '%s' command." msgstr "" #. STID_STAT_FAILED_WHILE_EXEC_CMD #: ../../strtbl.c:2083 #, c-format msgid "Fail to get file info for '%s' while executing the '%s' command." msgstr "" #. STID_NON_GROUPED_WHILE_EXEC_CMD #: ../../strtbl.c:2085 #, c-format msgid "" "Non-compound object named '%s' specified while executing the '%s' command." msgstr "" #. STID_BAD_SEP_LONG_WHILE_EXEC_CMD #: ../../strtbl.c:2087 #, c-format msgid "" "Invalid separator '%s' specified while executing the '%s' command.\n" "\n" "(Separator must be a single charactor.)" msgstr "" #. STID_BAD_SEP_WHILE_EXEC_CMD #: ../../strtbl.c:2089 #, c-format msgid "Invalid separator '%s' specified while executing the '%s' command." msgstr "" #. STID_MORE_THAN_ONE_WHILE_EXEC_CMD #: ../../strtbl.c:2091 #, c-format msgid "More than one object selected while executing the '%s' command." msgstr "" #. STID_MUST_FULL_PATH_WHILE_EXEC_CMD #: ../../strtbl.c:2093 #, c-format msgid "" "Invalid path: '%s' specified while executing the '%s' command.\n" "\n" "(Must use an absolute path.)" msgstr "" #. STID_OBJ_ALRDY_SEL_WHILE_EXEC_CMD #: ../../strtbl.c:2095 #, c-format msgid "Object named '%s' is already selected while executing the '%s' command." msgstr "" #. STID_INVALID_FNAME_WHILE_EXEC_CMD #: ../../strtbl.c:2097 #, c-format msgid "Invalid file name '%s' specified while executing the '%s' command." msgstr "" #. STID_INVALID_FMODE_WHILE_EXEC_CMD #: ../../strtbl.c:2099 #, c-format msgid "Invalid file mode '%s' specified while executing the '%s' command." msgstr "" #. STID_INVALID_FNUM_WHILE_EXEC_CMD #: ../../strtbl.c:2101 #, c-format msgid "Invalid file number '%s' specified while executing the '%s' command." msgstr "" #. STID_FNUM_ARDY_OPEN_WHILE_EXEC_CMD #: ../../strtbl.c:2103 #, c-format msgid "File number %1d is already opened while executing the '%s' command." msgstr "" #. STID_CANT_OPEN_FMOD_WRITE_EXEC_CMD #: ../../strtbl.c:2105 #, c-format msgid "" "Cannot open '%s' in the '%s' mode for writing while executing the '%s' " "command." msgstr "" #. STID_FNUM_NOT_OPEN_WHILE_EXEC_CMD #: ../../strtbl.c:2107 #, c-format msgid "File number %1d is not opened while executing the '%s' command." msgstr "" #. STID_EOF_FOR_FNUM_WHILE_EXEC_CMD #: ../../strtbl.c:2109 #, c-format msgid "" "Cannot read beyond the end-of-file for file number %1d while executing the '%" "s' command." msgstr "" #. STID_WRI_FNUM_FAIL_WHILE_EXEC_CMD #: ../../strtbl.c:2111 #, c-format msgid "Fail to write to file number %1d while executing the '%s' command." msgstr "" #. STID_WRI_FNN_FAIL_WHILE_EXEC_CMD #: ../../strtbl.c:2113 #, c-format msgid "" "Fail to write to file number %1d ('%s') while executing the '%s' command." msgstr "" #. STID_INVALID_PATH_WHILE_EXEC_CMD #: ../../strtbl.c:2115 #, c-format msgid "File '%s' does not exist while executing the '%s' command." msgstr "" #. STID_APPEND_FAILED_WHILE_EXEC_CMD #: ../../strtbl.c:2117 #, c-format msgid "Appending '%s' to '%s' failed while executing the '%s' command." msgstr "" #. STID_COPY_FAILED_WHILE_EXEC_CMD #: ../../strtbl.c:2119 #, c-format msgid "Copying '%s' to '%s' failed while executing the '%s' command." msgstr "" #. STID_INVALID_FORMAT_WHILE_EXEC_CMD #: ../../strtbl.c:2121 #, c-format msgid "Invalid format '%s' specified while executing the '%s' command." msgstr "" #. STID_INVALID_REC_WHILE_EXEC_CMD #: ../../strtbl.c:2123 #, c-format msgid "" "Invalid rectangle '(%d,%d,%d,%d)' specified while executing the '%s' command." msgstr "" #. STID_CONVERT_FORMAT_WHILE_EXEC_CMD #: ../../strtbl.c:2125 #, c-format msgid "" "Fail to convert '%s' from the '%s' format to XPM format while executing the '" "%s' command." msgstr "" #. STID_IMPORT_FAILED_WHILE_EXEC_CMD #: ../../strtbl.c:2127 #, c-format msgid "Fail to import '%s' while executing the '%s' command." msgstr "" #. STID_BAD_VER_NUM_WHILE_EXEC_CMD #: ../../strtbl.c:2129 #, c-format msgid "" "Invalid version number '%1d' specified while executing the '%s' command." msgstr "" #. STID_EMPTY_INI_SEC_WHILE_EXEC_CMD #: ../../strtbl.c:2131 #, c-format msgid "" "The [%s] section of '%s' is empty or non-existent while executing the '%s' " "command." msgstr "" #. STID_BAD_LINENUM_WHILE_EXEC_CMD #: ../../strtbl.c:2133 #, c-format msgid "Invalid line number '%1d' specified while executing the '%s' command." msgstr "" #. STID_BAD_SMALL_LNUM_WHILE_EXEC_CMD #: ../../strtbl.c:2135 #, c-format msgid "" "Invalid line number '%1d' (too small) specified while executing the '%s' " "command." msgstr "" #. STID_BAD_EMPTY_STR_WHILE_EXEC_CMD #: ../../strtbl.c:2137 #, c-format msgid "Invalid empty string specified while executing the '%s' command." msgstr "" #. STID_BAD_DIRECTION_WHILE_EXEC_CMD #: ../../strtbl.c:2139 #, c-format msgid "Invalid direction '%s' specified while executing the '%s' command." msgstr "" #. STID_NO_START_VRTX_WHILE_EXEC_CMD #: ../../strtbl.c:2141 #, c-format msgid "No starting vertex specified while executing the '%s' command." msgstr "" #. STID_TOO_FEW_VRTX_WHILE_EXEC_CMD #: ../../strtbl.c:2143 #, c-format msgid "Too few vertices (%1d) specified while executing the '%s' command." msgstr "" #. STID_NO_START_OBJ_WHILE_EXEC_CMD #: ../../strtbl.c:2145 #, c-format msgid "No starting object specified by %s() while executing the '%s' command." msgstr "" #. STID_CANT_FIND_MARK_WHILE_EXEC_CMD #: ../../strtbl.c:2147 #, c-format msgid "" "Cannot find the object marker for %s() while executing the '%s' command." msgstr "" #. STID_NO_OBJ_GROUP_WHILE_EXEC_CMD #: ../../strtbl.c:2149 #, c-format msgid "No object to group while executing the '%s' command." msgstr "" #. STID_CANT_GRP_SNGL_WHILE_EXEC_CMD #: ../../strtbl.c:2151 #, c-format msgid "Cannot group a single object while executing the '%s' command." msgstr "" #. STID_UNRECOG_CMD_MAY_BE_BLANKS_ABT #: ../../strtbl.c:2153 #, c-format msgid "" "Unrecognized command: '%s' (may be caused by illegal trailing blanks in " "command name).\n" "\n" "Command execution aborted." msgstr "" #. STID_UNRECOG_CMD_DOWNLOAD_TOOL #: ../../strtbl.c:2155 #, c-format msgid "" "Unrecognized command: '%s'.\n" "\n" "Command execution aborted.\n" "\n" "It is possible that the command is supported in a newer version of %s. " "Please visit '%s' to download the latest release." msgstr "" #. STID_UNRECOG_CMD_ABORT #: ../../strtbl.c:2157 msgid "Unrecognized command. Command execution aborted." msgstr "" #. STID_TOOL_NOT_DONE_WITH_PREV_FUNC #: ../../strtbl.c:2159 #, c-format msgid "%s is not finished with the previous %s yet." msgstr "" #. STID_ENTER_INTERN_CMD_FILE_NAME #: ../../strtbl.c:2161 #, c-format msgid "" "Please specify the file name for a %s internal command file (enter '-' for " "standard input)." msgstr "" #. STID_FINISH_EXEC_CMD_FROM_STDIN #: ../../strtbl.c:2163 msgid "Finished executing commands from the standard input." msgstr "" #. STID_FATAL_ERROR_IN_FUNC_PLUS_DESC #: ../../strtbl.c:2165 #, c-format msgid "Fatal Error in %s: %s" msgstr "" #. STID_TOOL_ABORTED #: ../../strtbl.c:2167 #, c-format msgid "%s aborted." msgstr "" #. STID_ICON_FILEVER_TOO_LARGE #: ../../strtbl.c:2169 #, c-format msgid "Icon file version too large (=%1d)." msgstr "" #. STID_UNEQUAL_DEPTHS_IN_FUNC #: ../../strtbl.c:2171 #, c-format msgid "Unequal depths in %s." msgstr "" #. STID_BASELINE_YS_NOT_EQ_IN_FUNC #: ../../strtbl.c:2177 #, c-format msgid "Error: left_baseline_y != right_baseline_y in %s." msgstr "" #. STID_LOCKED_OBJS_CANT_BE_MOVED #: ../../strtbl.c:2179 msgid "Locked object(s) cannot be moved." msgstr "" #. STID_HINT_CTL_MOVE_ATTR_ONLY #: ../../strtbl.c:2181 msgid "" "(HINT: You can hold down <Cntrl> key to move only the attribute under the " "cursor.)" msgstr "" #. STID_OUT_OF_VMEM_CANNOT_MALLOC #: ../../strtbl.c:2183 msgid "Out of virtual memory and cannot malloc()." msgstr "" #. STID_CANT_ALLOC_BITMAP_OF_SIZE #: ../../strtbl.c:2185 #, c-format msgid "Cannot allocate bitmap of size %1dx%1d." msgstr "" #. STID_FAIL_TO_WRITE_TO_FILE #: ../../strtbl.c:2187 #, c-format msgid "Fail to write to '%s'. File system may be full." msgstr "" #. STID_SAFEST_SAVE_N_EXIT_REPRODUCE #: ../../strtbl.c:2189 #, c-format msgid "" "Safest thing to do is to save file and exit.\n" "Please try to reproduce this error and\n" "\tsend bug report to %s." msgstr "" #. STID_FATAL_UNEXPECTED_ERROR #: ../../strtbl.c:2191 #, c-format msgid "" "Fatal Unexpected Error: %s%s%s\n" "\n" "Safest thing to do is to save file and exit.\n" "\n" "Please try to reproduce this error and send bug report to %s." msgstr "" #. STID_ENTER_FNAME_TO_WRITE_MSG_BUF #: ../../strtbl.c:2193 msgid "Please enter a file name to write the message buffer content:" msgstr "" #. STID_STDOUT_STDERR_ESC_CANCEL #: ../../strtbl.c:2195 msgid "( \"stdout\", \"stderr\", <ESC>: cancel )" msgstr "" #. STID_MSG_BUF_SAVED_INTO_GIVEN #: ../../strtbl.c:2197 #, c-format msgid "Message buffer saved into '%s'." msgstr "" #. STID_FILE_LINE_MISS_FIELD_IN_OBJ #: ../../strtbl.c:2199 #, c-format msgid "%s, %d: Missing %s in %s object." msgstr "" #. STID_FILE_LINE_BAD_FIELD_IN_OBJ #: ../../strtbl.c:2201 #, c-format msgid "%s, %d: Bad %s in %s object." msgstr "" #. STID_NAMED_SIG_RECV #: ../../strtbl.c:2203 #, c-format msgid "%s signal received." msgstr "" #. STID_ERR_COUNT_EXCEED_TOOL_ABORTED #: ../../strtbl.c:2205 #, c-format msgid "Error count exceeds %1d in %s. %s aborted." msgstr "" #. STID_WORKING_FILE_SAVED_TO #: ../../strtbl.c:2207 #, c-format msgid "Working file saved to '%s.%s'." msgstr "" #. STID_UNABLE_TO_SAVE_WORKING_FILE #: ../../strtbl.c:2209 msgid "Unable to save working file." msgstr "" #. STID_X_ERROR_MSG #: ../../strtbl.c:2211 #, c-format msgid "X Error: %s." msgstr "" #. STID_BAD_COMPILE_OPT_USE_ALT_STR #: ../../strtbl.c:2213 #, c-format msgid "Invalid compiler option %s=\"%s\", \"%s\" is used instead." msgstr "" #. STID_MISSING_DISPLAY_NAME #: ../../strtbl.c:2215 msgid "Missing display name." msgstr "" #. STID_MISSING_PAGE_NUMBER #: ../../strtbl.c:2217 msgid "Missing page number." msgstr "" #. STID_INVALID_GIVEN_PAGE_NUMBER_STR #: ../../strtbl.c:2219 #, c-format msgid "Invalid page number: '%s'." msgstr "" #. STID_MISSING_ARG_FOR_CMDLINE_OPT #: ../../strtbl.c:2221 #, c-format msgid "Missing command line argument for '%s'." msgstr "" #. STID_INVALID_ARG_FOR_CMDLINE_OPT #: ../../strtbl.c:2223 #, c-format msgid "Invalid command line argument for '%s': '%s'." msgstr "" #. STID_TGIF_PATH_SHOULD_NOT_BE_USED #: ../../strtbl.c:2225 msgid "Warning: -tgif_path should not be used!" msgstr "" #. STID_PRINT_TO_PRINTER_INCOMPAT #: ../../strtbl.c:2227 #, c-format msgid "Printing to printer is incompatible with '%s'." msgstr "" #. STID_BAD_EXEC_FNAME_DASH #: ../../strtbl.c:2229 msgid "Invalid exec file name (cannot start with '-')." msgstr "" #. STID_CANNOT_OPEN_DIR_FOR_READING #: ../../strtbl.c:2231 #, c-format msgid "Cannot open the '%s' directory for reading." msgstr "" #. STID_FAIL_TO_STAT_GIVEN_FILE #: ../../strtbl.c:2233 #, c-format msgid "Fail to stat() '%s'." msgstr "" #. STID_SET_WORKING_DIR #: ../../strtbl.c:2235 msgid "SetWorkingDir" msgstr "„Ç„Ł„ì„Ż„È„êÀßÄê" #. STID_CLICK_SETWORKDIR_TO_SET_DIR #: ../../strtbl.c:2237 msgid "Click on the 'SetWorkingDir' button to set Open/SaveAs directory." msgstr "" #. STID_SETWORKDIR_NOT_SUP_FOR_STR #: ../../strtbl.c:2239 #, c-format msgid "SetWorkingDir not supported for '%s'." msgstr "" #. STID_OPENSAVE_DIR_CHANGE_TO_REMAIN #: ../../strtbl.c:2241 #, c-format msgid "" "Current open/save directory change to '%s'.\n" "\n" "(Current import directory remains '%s'.)" msgstr "" "žœșß€ÎÆÉ€ßčț€ß/ÊĘž„Ç„Ł„ì„Ż„È„ê€ò'%s'€ËÊŃčč\n" "€·€Ț€·€ż\n" "(ÁȚÆțÍŃ€Î„Ç„Ł„ì„Ż„È„ê€Ï '%s' €Î€Ț€Ț€Ç€č.)" #. STID_IMPORT_DIR_CHANGED_TO_REMAIN #: ../../strtbl.c:2243 #, c-format msgid "" "Current import directory changed to '%s'.\n" "\n" "(Current open/save directory remains '%s'.)" msgstr "" #. STID_GEN_LIST_OF_DOMAIN_NAMES_WAIT #: ../../strtbl.c:2245 msgid "Generating list of domain names, please wait..." msgstr "" #. STID_CANT_GEN_DOM_NAMES_INI_ENTRY #: ../../strtbl.c:2247 #, c-format msgid "" "Fail to generate a list of domain names.\n" "\n" "Cannot find the '%s' entry in the [%s] section of '%s'." msgstr "" #. STID_CANT_GEN_DOM_NAMES_XDEF #: ../../strtbl.c:2249 #, c-format msgid "" "Fail to generate a list of domain names.\n" "\n" "Cannot find %s.%s%1d." msgstr "" #. STID_CANT_GET_LIST_OF_DOM_NAMES #: ../../strtbl.c:2251 msgid "Fail to get a list of domain names." msgstr "" #. STID_PLEASE_SELECT_A_NEW_DOMAIN #: ../../strtbl.c:2253 msgid "Please select a new DOMAIN..." msgstr "" #. STID_CURRENT_DOMAIN_IS #: ../../strtbl.c:2255 #, c-format msgid "Current domain is '%s'." msgstr "" #. STID_SYMBOL_PATH_SET_TO #: ../../strtbl.c:2257 #, c-format msgid "Symbol path set to '%s'." msgstr "" #. STID_PLS_SEL_A_DIR_IN_GIVEN_DOMAIN #: ../../strtbl.c:2259 #, c-format msgid "Please select a DIRECTORY in the '%s' domain..." msgstr "" #. STID_GEN_LIST_XBM_NAMES_WAIT #: ../../strtbl.c:2261 msgid "Generating list of bitmap names, please wait..." msgstr "" #. STID_GEN_LIST_XPM_NAMES_WAIT #: ../../strtbl.c:2263 msgid "Generating list of pixmap names, please wait..." msgstr "" #. STID_GEN_LIST_OBJ_NAMES_WAIT #: ../../strtbl.c:2265 msgid "Generating list of object file names, please wait..." msgstr "" #. STID_GEN_LIST_SYM_NAMES_WAIT #: ../../strtbl.c:2267 msgid "Generating list of symbol names, please wait..." msgstr "" #. STID_GEN_LIST_TYPE_FILE_NAMES_WAIT #: ../../strtbl.c:2269 #, c-format msgid "Generating list of %s file names, please wait..." msgstr "" #. STID_NO_GIVEN_TYPE_FILE_FOUND #: ../../strtbl.c:2271 #, c-format msgid "No '%s' file found." msgstr "" #. STID_NO_DIR_SEP_IN_FUNC_WORK_DIR #: ../../strtbl.c:2273 #, c-format msgid "" "Error: No directory-separator found in %s.\n" "\n" "Current working directory set to '%s'." msgstr "" #. STID_NO_DIR_SEP_IN_FUNC_SYM_DIR #: ../../strtbl.c:2275 #, c-format msgid "" "Error: No directory-separator found in %s.\n" "\n" "Current symbol directory set to '%s'." msgstr "" #. STID_NO_DIR_SEP_IN_FUNC_IMPORT_DIR #: ../../strtbl.c:2277 #, c-format msgid "" "Error: No directory-separator found in %s.\n" "\n" "Current import directory set to '%s'." msgstr "" #. STID_EMPTY_PATH_DISALLOW_FOR_DOM #: ../../strtbl.c:2279 #, c-format msgid "Empty path is not allowed for the '%s' domain." msgstr "" #. STID_TOOL_EDIT_DOM_PATHS #: ../../strtbl.c:2281 #, c-format msgid "%s - Edit Domain Paths" msgstr "%s - „Ʉᄀ„ó„Ń„č€ÎÊÔœž" #. STID_EDIT_DOMAIN_PATHS_DOTS #: ../../strtbl.c:2283 msgid "Edit domain paths..." msgstr "„Ʉᄀ„ó„Ń„č€ÎÊÔœž..." #. STID_TOOL_SEL_DEFAULT_DOMAIN #: ../../strtbl.c:2285 #, c-format msgid "%s - Select A Default Domain" msgstr "%s - „DŽՄ©„ë„ȄɄᄀ„ó€ÎÁȘÂò" #. STID_SEL_DEFAULT_DOMAIN_DOTS #: ../../strtbl.c:2287 msgid "Please select a default domain..." msgstr "„DŽՄ©„ë„ȄɄᄀ„ó€òÁȘÂò€·€Æ€Ż€À€”€€..." #. STID_PLS_SPEC_A_NEW_DOMAIN_NAME #: ../../strtbl.c:2289 msgid "Please specify a new domain name:" msgstr "ż·€·€€„Ʉᄀ„óÌŸ€ò»ŰÄꀷ€Æ€Ż€À€”€€:" #. STID_GIVEN_DOMAIN_ALREADY_EXISTS #: ../../strtbl.c:2291 #, c-format msgid "Domain '%s' already exists!" msgstr "„Ʉᄀ„ó '%s' €ÏŽû€Ëžș߀·€Ț€č!" #. STID_GIVEN_DOM_ADDED_PATH_SET_TO #: ../../strtbl.c:2293 #, c-format msgid "Domain '%s' added. Path set to \"%s\"." msgstr "" #. STID_SEL_DOMAIN_TO_DELETE_DOTS #: ../../strtbl.c:2295 msgid "Please select a domain to delete..." msgstr "" #. STID_OK_TO_DELETE_NAMED_DOMAIN_YNC #: ../../strtbl.c:2297 #, c-format msgid "Okay to delete the '%s' domain? [ync](y)" msgstr "" #. STID_OK_TO_RELOAD_DOM_INFO_FROM_X #: ../../strtbl.c:2299 #, fuzzy msgid "Okay to reload domain information from X defaults? [ync](y)" msgstr "X defaults €«€é„Ʉᄀ„óŸđÊó€ÎșÆÆÉ€ßčț€ß" #. STID_ERR_IN_PARSE_STR_FOR_2_VAL #: ../../strtbl.c:2301 #, c-format msgid "Error in parsing '%s' for 2 values." msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_BACK #: ../../strtbl.c:2303 msgid "File modified, save file before going back? [ync](y)" msgstr "" #. STID_NOTHING_TO_GO_BACK_TO #: ../../strtbl.c:2305 msgid "Nothing to go back to." msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_FORWARD #: ../../strtbl.c:2307 msgid "File modified, save file before going forward? [ync](y)" msgstr "" #. STID_NOTHING_TO_GO_FORWARD_TO #: ../../strtbl.c:2309 msgid "Nothing to go forward to." msgstr "" #. STID_FAIL_TO_FIND_RECORD_IN_FUNC #: ../../strtbl.c:2311 msgid "Fail to find record in AdjustNavigate()." msgstr "" #. STID_FURTHER_NAVIGATE_MAY_CRASH #: ../../strtbl.c:2313 msgid "Further navigating may crash." msgstr "" #. STID_CANT_REFRESH_UNDEFINED_FILE #: ../../strtbl.c:2315 msgid "Canot refresh an undefined file." msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_RELOAD #: ../../strtbl.c:2317 msgid "File modified, save file before going reloading? [ync](y)" msgstr "" #. STID_HOT_LIST_FILE_UNDEF_PLS_SPEC #: ../../strtbl.c:2319 #, c-format msgid "Hot list file undefined. Please specify it in %s.%s." msgstr "" #. STID_MALFORMED_NAMED_HOT_LIST_FILE #: ../../strtbl.c:2321 #, c-format msgid "Malformed hot list file '%s'." msgstr "" #. STID_HOT_LIST_FILE_IS_EMPTY #: ../../strtbl.c:2323 msgid "Hot list file is empty." msgstr "" #. STID_Q_DEL_NAMED_FROM_HOT_LIST #: ../../strtbl.c:2325 #, c-format msgid "Would you like to delete '%s' from the hot list? [ync](y)" msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_OPEN_ANO #: ../../strtbl.c:2327 msgid "File modified, save file before opening another file? [ync](y)" msgstr "" "„Ő„Ą„€„ë€Ë€Ïœ€À”€ŹČĂ€ï€Ă€Æ€Ț€čĄŁÊÌ€Î„Ő„Ą„€„ë€òł«€ŻÁ°€ËÊĘž€·€Ț€č€«? [ync](y)" #. STID_SESSION_HIST_NOT_ESTABLISHED #: ../../strtbl.c:2329 msgid "Sesion history has not been established yet." msgstr "" #. STID_TOOL_HOT_LIST #: ../../strtbl.c:2331 #, c-format msgid "%s - Hot List" msgstr "%s - „Û„Ă„È„ê„č„È" #. STID_TOOL_HISTORY #: ../../strtbl.c:2333 #, c-format msgid "%s - History" msgstr "%s - ÍúÎò" #. STID_HOT_LIST_DOTS #: ../../strtbl.c:2335 msgid "Hot list..." msgstr "„Û„Ă„È„ê„č„È..." #. STID_CANT_ADD_UNDEF_TO_HOT_LIST #: ../../strtbl.c:2337 msgid "Cannot add an undefined file to hot list." msgstr "" #. STID_HOT_LIST_FILE_UPDATED #: ../../strtbl.c:2339 msgid "Hot list file updated." msgstr "" #. STID_SESSION_HISTORY_DOTS #: ../../strtbl.c:2341 msgid "Session history..." msgstr "„»„Ă„·„ç„ó€ÎÍúÎò" #. STID_ENTER_HYPERSPACE_DOTS #: ../../strtbl.c:2343 msgid "Enter hyperspace..." msgstr "„Ï„€„ŃĄŒĄŠ„č„ÚĄŒ„č€ËÆț€ë..." #. STID_LEAVING_HYPERSPACE_DOTS #: ../../strtbl.c:2345 msgid "Leaving hyperspace..." msgstr "„Ï„€„ŃĄŒĄŠ„č„ÚĄŒ„耫€éœĐ€ë..." #. STID_CANT_SLIDESHOW_IN_TILED_PAGE #: ../../strtbl.c:2347 msgid "" "Cannot enter slideshow mode in TILED page mode. Would you like to switch to " "STACKED page mode then proceed? [ync](y)" msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_SLIDE #: ../../strtbl.c:2349 msgid "File modified, save file before entering slideshow mode? [ync](y)" msgstr "" #. STID_PAGE_NUM_MOD_IN_SLIDE_NOT_SAV - this string is not used! #: ../../strtbl.c:2351 #, c-format msgid "" "Page numbers will be modified by %s in slideshow mode. It's probably a good " "idea NOT to do a Save() until you've re-opened the file." msgstr "" #. STID_Q_PAGE_NUM_MOD_IN_SLIDE_YNC #: ../../strtbl.c:2353 #, c-format msgid "" "Page numbers will be modified by %s in slideshow mode. The file will be " "marked unsavable if you continue.\n" "\n" "Okay to mark the file unsavable and enter slideshow mode? [ync](y)" msgstr "" #. STID_ENTERING_SLIDESHOW_DOTS #: ../../strtbl.c:2355 msgid "Entering slideshow..." msgstr "" #. STID_LEAVING_SLIDESHOW_DOTS #: ../../strtbl.c:2357 msgid "Leaving slideshow..." msgstr "" #. STID_ENTER_A_COLOR_FOR_SLIDE_BRDR #: ../../strtbl.c:2359 msgid "Please enter a color for the slideshow border:" msgstr "„č„é„€„É„·„çĄŒ€Î„ÜĄŒ„ÀĄŒ„«„éĄŒ€òÆțÎÏ€·€Æ€Ż€À€”€€:" #. STID_PRESS_ENTER_FOR_DEF_COLOR #: ../../strtbl.c:2361 msgid "( just press <ENTER> for the default color )" msgstr "" #. STID_SLIDE_WILL_USE_DEF_BRDR_COLOR #: ../../strtbl.c:2363 msgid "Slideshow will use default border color." msgstr "„č„é„€„É„·„çĄŒ€Î„ÜĄŒ„ÀĄŒż§€Ï„DŽՄ©„ë„È€Îż§€ò»È€€€Ț€č" #. STID_SLIDE_BRDR_COLOR_SET_TO_NAMED #: ../../strtbl.c:2365 #, c-format msgid "Slideshow border color set to '%s'." msgstr "„č„é„€„É„·„çĄŒ€Î„ÜĄŒ„ÀĄŒ„«„éĄŒ€Ï '%s' €ËÀßÄꀔ€ì€Ț€·€ż" #. STID_ENTER_XY_OFFSET_FOR_SLIDE_WIN #: ../../strtbl.c:2367 #, c-format msgid "" "Please enter X and Y offsets for the slideshow window: [current: %1d,%1d]" msgstr "" #. STID_SLIDE_WIN_XY_OFFSETS_SET_TO #: ../../strtbl.c:2369 #, c-format msgid "Slideshow window offsets set to: %1d, %1d." msgstr "" #. STID_GRID_BE_VISIBLE_IN_SLIDE #: ../../strtbl.c:2371 msgid "Grid will be visible in slideshow mode." msgstr "„č„é„€„É„·„çĄŒĄŠ„âĄŒ„ɀDް„ê„ÄɀòÉœŒš€·€Ț€č." #. STID_GRID_NOT_BE_VISIBLE_IN_SLIDE #: ../../strtbl.c:2373 msgid "Grid will not be visible in slideshow mode." msgstr "„č„é„€„É„·„çĄŒĄŠ„âĄŒ„ɀDް„ê„ÄɀòÉœŒš€·€Ț€»€ó." #. STID_CANT_DO_NEXTPAGE_IN_TILED #: ../../strtbl.c:2375 msgid "Cannot do NextPage() in TILED page mode." msgstr "" #. STID_ALREADY_AT_LAST_PAGE #: ../../strtbl.c:2381 msgid "Already at last page." msgstr "€č€Ç€ËșÇžć€Î„ÚĄŒ„ž€Ë€€€Ț€č" #. STID_CANT_DO_PREFPAGE_IN_TILED #: ../../strtbl.c:2383 msgid "Cannot do PrevPage() in TILED page mode." msgstr "" #. STID_ALREADY_AT_FIRST_PAGE #: ../../strtbl.c:2385 msgid "Already at first page." msgstr "€č€Ç€ËșÇœé€Î„ÚĄŒ„ž€Ë€€€Ț€č" #. STID_TOOL_NAME_PAGES #: ../../strtbl.c:2387 #, c-format msgid "%s - Name Pages" msgstr "%s - „ÚĄŒ„ž€ËÌŸÁ°€ò€Ä€±€ë" #. STID_TOOL_GOTO_PAGE #: ../../strtbl.c:2389 #, c-format msgid "%s - Goto Page" msgstr "%s - „ÚĄŒ„ž°Üư" #. STID_CANT_DO_GOTOPAGE_IN_TILED #: ../../strtbl.c:2391 msgid "Cannot do GotoPage() in TILED page mode." msgstr "" #. STID_GOTO_PAGE_DOTS #: ../../strtbl.c:2393 msgid "Goto page..." msgstr "„ÚĄŒ„ž°Üư..." #. STID_NO_PAGE_SELECTED #: ../../strtbl.c:2395 msgid "No page selected." msgstr "„ÚĄŒ„ž€ŹÁȘÂò€”€ì€Æ€Ț€»€ó" #. STID_INVALID_GIVEN_PAGE_NUMBER #: ../../strtbl.c:2397 #, c-format msgid "Invalid page number '%1d'." msgstr "" #. STID_ALREADY_AT_GIVEN_PAGE #: ../../strtbl.c:2399 #, c-format msgid "Already at page %1d." msgstr "" #. STID_CUR_PAGE_IS_GIVEN_PAGE_NUM #: ../../strtbl.c:2401 #, c-format msgid "Current page is page %1d." msgstr "" #. STID_CANT_DO_NAMEPAGES_IN_TILED #: ../../strtbl.c:2403 msgid "Cannot do NamePages() in TILED page mode." msgstr "" #. STID_EDIT_PAGE_NAMES_DOTS #: ../../strtbl.c:2405 #, fuzzy msgid "Edige page names..." msgstr "„ÚĄŒ„žÌŸÊÔœž..." #. STID_CANT_EDITPAGEFNAME_IN_TILED #: ../../strtbl.c:2407 msgid "Cannot do EditPageFileNames() in TILED page mode." msgstr "" #. STID_EDIT_PAGE_FILE_NAMES_DOTS #: ../../strtbl.c:2409 #, fuzzy msgid "Edige page file names..." msgstr "„ÚĄŒ„žÌŸÊÔœž..." #. STID_PAGE_FNAME_NO_SPACE_TRUNC #: ../../strtbl.c:2411 #, c-format msgid "" "Page file name: '%s' must not contain space characters. It is truncated to '" "%s'." msgstr "" #. STID_OK_TO_FLUSH_UNDO_AND_PROCEED #: ../../strtbl.c:2413 msgid "Okay to flush the undo buffer and proceed? [ync](y)" msgstr "" #. STID_ADD_PAGE_BEFORE_GIVEN_FLUSH #: ../../strtbl.c:2415 #, c-format msgid "Adding a page before page %1d will cause the undo buffer to be flushed." msgstr "" #. STID_ADD_PAGE_AFTER_GIVEN_FLUSH #: ../../strtbl.c:2417 #, c-format msgid "Adding a page after page %1d will cause the undo buffer to be flushed." msgstr "" #. STID_DELETE_GIVEN_PAGE_CAUSE_FLUSH #: ../../strtbl.c:2419 #, c-format msgid "Deleting page %1d will cause the undo buffer to be flushed." msgstr "" #. STID_DELETE_A_PAGE_CAUSE_FLUSH #: ../../strtbl.c:2421 msgid "Deleting a page will cause the undo buffer to be flushed." msgstr "" #. STID_DELETE_PAGES_PAGE_CAUSE_FLUSH #: ../../strtbl.c:2423 msgid "Deleting pages will cause the undo buffer to be flushed." msgstr "" #. STID_CHNG_PAGE_LAYOUT_FLUSH #: ../../strtbl.c:2425 msgid "Changing the page layout mode will cause the undo buffer to be flushed." msgstr "" #. STID_SET_PAPER_COLOR_CAUSE_FLUSH #: ../../strtbl.c:2427 msgid "Setting paper color will cause the undo buffer to be flushed." msgstr "" #. STID_CANT_DO_ADDPAGE_IN_TILED #: ../../strtbl.c:2429 msgid "Cannot do AddPage() in TILED page mode." msgstr "" #. STID_CANT_DO_DELETEPAGE_IN_TILED #: ../../strtbl.c:2431 msgid "Cannot do DeleteCurrentPage() in TILED page mode." msgstr "" #. STID_CANT_DEL_ONLY_PAGE_IN_TILED #: ../../strtbl.c:2433 msgid "Cannot delete (the only) page in TILED page mode." msgstr "" #. STID_CANT_DO_SPECDRAWSIZE_IN_TILED #: ../../strtbl.c:2435 msgid "Cannot do SpecifyDrawingSize() in TILED page mode." msgstr "" #. STID_CANT_DO_DELETEPAGES_IN_TILED #: ../../strtbl.c:2437 msgid "Cannot do DeletePages() in TILED page mode." msgstr "" #. STID_CANT_DO_POFPP_IN_TILED #: ../../strtbl.c:2439 msgid "Cannot do PrintOneFilePerPage() in TILED page mode." msgstr "" #. STID_CANT_DO_POFPP_TO_PRINTER #: ../../strtbl.c:2441 msgid "Cannot do PrintOneFilePerPage() to printer." msgstr "" #. STID_NAMED_TEMPLATE_LOADED #: ../../strtbl.c:2443 #, c-format msgid "Template loaded: '%s'." msgstr "" #. STID_PROB_LOADING_NAMED_TEMPLATE #: ../../strtbl.c:2445 #, c-format msgid "Problem loading template file '%s'." msgstr "" #. STID_GIVEN_PAGE_NUM_ADDED #: ../../strtbl.c:2447 #, c-format msgid "Page %1d added." msgstr "" #. STID_ADDPAGEBEFORE_IN_WB #: ../../strtbl.c:2449 msgid "AddPageBefore() is disabled in WhiteBoard mode." msgstr "" #. STID_ADDPAGEAFTER_IN_WB #: ../../strtbl.c:2451 msgid "AddPageAfter() is disabled in WhiteBoard mode." msgstr "" #. STID_GIVEN_PAGE_NUM_DELETED #: ../../strtbl.c:2453 #, c-format msgid "Page %1d deleted." msgstr "" #. STID_CANT_TPLS_IN_STACKED #: ../../strtbl.c:2455 msgid "Cannot TogglePageLineShown() in STACKED page mode." msgstr "" #. STID_ENTER_DRAW_SIZE_SPEC_WH #: ../../strtbl.c:2457 msgid "Please enter drawing size specification: [W x H]" msgstr "ÉÁČè„”„€„ș€òÆțÎÏ€·€Æ€Ż€À€”€€: [Éę x č—]" #. STID_BAD_DRAW_SIZE_SPEC_WH #: ../../strtbl.c:2459 msgid "" "Invalid drawing size specification.\n" "\n" "Must specify both Width and Height." msgstr "" #. STID_BAD_DRAW_SIZE_SPEC_W_TIMES_H #: ../../strtbl.c:2461 #, c-format msgid "Invalid drawing size specification: W times H should be >= %1d." msgstr "" #. STID_INVALID_DRAW_SIZE_SPEC #: ../../strtbl.c:2463 msgid "Invalid drawing size specified." msgstr "" #. STID_CANT_PRINTONEPAGE_IN_FORMAT #: ../../strtbl.c:2465 #, c-format msgid "Cannot do PrintOnePage() in the '%s' format." msgstr "" #. STID_BTN1_SEL_PAGE_TO_PRINT #: ../../strtbl.c:2467 msgid "Left button selects a page to print," msgstr "" #. STID_OTHER_BTN_CANCEL_PRINTONEPAGE #: ../../strtbl.c:2469 msgid "other buttons cancel printing one page." msgstr "" #. STID_SELECT_A_PAGE_TO_PRINT #: ../../strtbl.c:2471 msgid "Select a page to print" msgstr "" #. STID_OPERATION_CANCEL_BY_USER #: ../../strtbl.c:2473 msgid "Operation canceled by the user." msgstr "" #. STID_MUST_SEL_A_PT_ON_THE_PAPER #: ../../strtbl.c:2475 #, fuzzy msgid "Must select a point on the paper." msgstr "1€Ä€Î„ÚĄŒ„ž€òÁȘÂò€·°őșț€č€ë" #. STID_MUST_SEL_A_PT_IN_TOOL_WIN #: ../../strtbl.c:2477 #, c-format msgid "Must select a point within the %s window." msgstr "" #. STID_NEW_PAPER_SIZE_IS_GIVEN #: ../../strtbl.c:2479 #, c-format msgid "New paper size: %.2fin x %.2fin (%.2fcm x %.2fcm)." msgstr "" #. STID_INVALID_GIVEN_PAPER_SIZE_SPEC #: ../../strtbl.c:2481 #, c-format msgid "Invalid paper size specification: '%s'." msgstr "" #. STID_CUR_PAPER_SIZE_IS_GIVEN #: ../../strtbl.c:2483 #, c-format msgid "( current paper size: '%s' )" msgstr "( žœș߀ÎÍŃ»æ„”„€„ș: '%s' )" #. STID_ENTER_PAPER_SIZE_WH #: ../../strtbl.c:2485 msgid "Please enter physical paper size: [W x H] (e.g., 8.5in x 11in)" msgstr "" #. STID_CANT_DEL_ONLY_PAGE_IN_STACKED #: ../../strtbl.c:2487 msgid "Cannot delete (the only) page." msgstr "žœș߀΄ڥŒ„ž€Ïșïœü€Ç€­€Ț€»€ó" #. STID_SPECIFY_PAGES_TO_DEL_EX #: ../../strtbl.c:2489 msgid "Please specify pages to delete: (e.g., 2,3,7-9,10)" msgstr "" #. STID_GIVEN_PAGE_NUM_IS_OUT_OF_RNG #: ../../strtbl.c:2491 #, c-format msgid "Page %1d is out of range." msgstr "" #. STID_MALFORMED_SPECIFICATION_STR #: ../../strtbl.c:2493 #, c-format msgid "Malformed specification: '%s'." msgstr "" #. STID_CANT_DEL_ALL_PAGES #: ../../strtbl.c:2495 msgid "Cannot delete all pages." msgstr "" #. STID_ONE_PAGE_DELETED #: ../../strtbl.c:2497 msgid "1 page deleted." msgstr "" #. STID_MANY_PAGES_DELETED #: ../../strtbl.c:2499 #, c-format msgid "%1d pages deleted." msgstr "" #. STID_OBJ_OUTSIDE_PAGE_BNRDY_SWITCH #: ../../strtbl.c:2501 msgid "" "There are objects outside the page boundary.\n" "\n" "Cannot switch to TILED mode." msgstr "" #. STID_SWTCH_TO_TILED_LOSE_ALL_NAMES #: ../../strtbl.c:2503 msgid "" "Switching from TILED to STACKED mode loses all page names and page file " "names.\n" "\n" "Ok to proceed? [ync](y)" msgstr "" #. STID_CHANGE_PAGE_LAYOUT_MODE_IN_WB #: ../../strtbl.c:2505 msgid "Changing page layout mode is disabled in WhiteBoard mode." msgstr "" #. STID_PAGE_LAYOUT_MODE_IS_STACKED #: ../../strtbl.c:2507 msgid "Page layout mode is STACKED." msgstr "" #. STID_PAGE_LAYOUT_MODE_IS_TILED #: ../../strtbl.c:2509 msgid "Page layout mode is TILED." msgstr "" #. STID_SPECIFY_A_PAPER_COLOR #: ../../strtbl.c:2511 msgid "Please specify a paper color:" msgstr "" #. STID_SPECIFY_A_PAPER_COLOR_CUR_IS #: ../../strtbl.c:2513 #, c-format msgid "Please specify a paper color: [current: %s]" msgstr "" #. STID_ENTER_NONE_TO_REMOVE_COLOR #: ../../strtbl.c:2515 msgid "( Enter 'None' to remove the current paper color. )" msgstr "" #. STID_PAPER_COLOR_REMOVED #: ../../strtbl.c:2517 msgid "Paper color removed." msgstr "" #. STID_PAPER_COLOR_SET_TO_GIVEN #: ../../strtbl.c:2519 #, c-format msgid "Paper color set to '%s'." msgstr "" #. STID_GRAY_SCALE_USED_IN_PRINT_PAT #: ../../strtbl.c:2521 msgid "Gray scale used in printing tiling patterns." msgstr "" #. STID_NOTE_SLOW_PRINT_DUE_USE_PAT #: ../../strtbl.c:2523 msgid "Note: slow printing due to the use of patterns." msgstr "" #. STID_SUGGEST_USEGRAYSCALE_TO_SPEED #: ../../strtbl.c:2525 msgid "You may want to try UseGrayScale() to speed things up." msgstr "" #. STID_ENTER_LINE_WIDTH_OPT_AW_AH #: ../../strtbl.c:2533 msgid "Please enter line width (arrow width and height are optional):" msgstr "" #. STID_INVALID_GIVEN_STR_WIDTH #: ../../strtbl.c:2535 #, c-format msgid "Invalid width: '%s'." msgstr "" #. STID_INVALID_GIVEN_STR_AW_AH #: ../../strtbl.c:2537 #, c-format msgid "Invalid arrow width and height: '%s %s'." msgstr "" #. STID_NO_PINS_FOUND_IN_CUR_DRAWING #: ../../strtbl.c:2539 #, fuzzy msgid "No pins found in the current drawing." msgstr "žœș߀γš€ò°őșț/œĐÎÏ€č€ë" #. STID_INPUT_PAIRS_OF_POINTS_POLY #: ../../strtbl.c:2541 msgid "" "Please input pairs of points: (terminate with \"<Cntrl>d<CR>\" or \".<CR>\", " "continue to next poly with \";<CR>\")" msgstr "" #. STID_READ_INT_ERROR_FOR_POLY_PTS #: ../../strtbl.c:2543 msgid "Error reading integer for poly points." msgstr "" #. STID_TOO_FEW_POINTERS_ENTERED #: ../../strtbl.c:2545 msgid "Too few points entered." msgstr "" #. STID_TOO_FEW_VER_TO_CLOSE_POLY #: ../../strtbl.c:2547 msgid "Too few vertices to close a polyline/open-spline." msgstr "ÀȚ€ìÀț/„脌„é„€„ó€òÊÄ€ž€ë€Ë€ÏÄșĆÀ€ŹŸŻ€Ê€č€ź€Ț€č" #. STID_HUH_WHERE_ARE_THE_VERTICES #: ../../strtbl.c:2549 msgid "Huh? Where are the vertices?" msgstr "€ó? ÄșĆÀ€Ï€É€ł€«€·€é€ó?" #. STID_HUH_TOPVSEL_NE_BOTVSEL #: ../../strtbl.c:2551 msgid "Huh? How can topVSel != botVSel?" msgstr "" #. STID_CMD_ONLY_AVAIL_IN_VERSEL_MODE #: ../../strtbl.c:2553 msgid "This command is only available in vertex or select mode." msgstr "" #. STID_SEL_2_ENDPOINT_VER_TO_JOIN #: ../../strtbl.c:2555 msgid "Please select 2 end-point vertices to join." msgstr "" #. STID_SEL_VER_FROM_POLY_OPEN_ONLY #: ../../strtbl.c:2557 #, fuzzy msgid "Please select vertices from polylines/open-splines only." msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òșïœü€č€ë" #. STID_SEL_2_POLYLINES_OPEN_SPLINES #: ../../strtbl.c:2559 msgid "Please select 2 polylines/open-splines." msgstr "" #. STID_CANT_JOIN_INTSPLINE_W_NONEINT #: ../../strtbl.c:2561 msgid "" "Cannot join a interpolated spline with a non-interpolated polyline/open-" "spline." msgstr "" #. STID_SEL_1_VERTEX_TO_CUT #: ../../strtbl.c:2563 msgid "Please select 1 vertex to cut." msgstr "" #. STID_SEL_A_VERTEX_FROM_POLY_OR_GON #: ../../strtbl.c:2565 #, fuzzy msgid "Please select a vertex from a polyline or polygon object." msgstr "ÀȚ€ìÀț/ÂżłŃ·Á/„脌„é„€„ó€ÎÄșĆÀ€òșïœü€č€ë" #. STID_INVALID_SMOOTHHINGE_SPEC_POLY #: ../../strtbl.c:2567 #, c-format msgid "" "%s, %d: Invalid smooth/hinge spec for a poly/polygon object. Read aborted" msgstr "" #. STID_INVALID_NUM_PTS_IN_POLY #: ../../strtbl.c:2569 #, c-format msgid "%s, %d: Invalid number of points in a poly object. Read aborted" msgstr "" #. STID_INPUT_PAIRS_OF_POINTS_POLYGON #: ../../strtbl.c:2571 msgid "" "Please input pairs of points: (terminate with \"<Cntrl>d<CR>\" or \".<CR>\", " "continue to next polygon with \";<CR>\")" msgstr "" #. STID_READ_INT_ERR_FOR_POLYGON_PTS #: ../../strtbl.c:2573 msgid "Error reading integer for polygon points." msgstr "" #. STID_INVALID_NUM_PTS_IN_POLYGON #: ../../strtbl.c:2575 #, c-format msgid "%s, %d: Invalid number of points in a polygon. Read aborted" msgstr "" #. STID_CANT_GET_XDEF_DEF_WIDTHS_USED #: ../../strtbl.c:2577 #, c-format msgid "Error in getting X default %s.%s. Default widths used." msgstr "" #. STID_ERR_SETCTM_CALLED_CTM_NONNULL #: ../../strtbl.c:2579 msgid "Error: SetCTM() is called with ObjPtr->ctm != NULL." msgstr "" #. STID_MEASUREMENT_SHOWN_IN_UNIT #: ../../strtbl.c:2585 #, c-format msgid "Measurement will be shown in '%s' (%s %s)." msgstr "" #. STID_BAD_MEASUREMENT_UNIT_SPEC #: ../../strtbl.c:2587 #, c-format msgid "Bad measurement unit specification '%s'." msgstr "" #. STID_SHOW_CROSSHAIR_ENABLED #: ../../strtbl.c:2589 msgid "Showing cross-hair enabled." msgstr "" #. STID_SHOW_CROSSHAIR_DISABLED #: ../../strtbl.c:2591 msgid "Showing cross-hair disabled." msgstr "" #. STID_SHOW_MEASUREMENT_ENABLED #: ../../strtbl.c:2593 msgid "Showing measurement enabled." msgstr "ÊȘș耷€òÉœŒš€·€Ț€č" #. STID_SHOW_MEASUREMENT_DISABLED #: ../../strtbl.c:2595 msgid "Showing measurement disabled." msgstr "ÊȘș耷€òÉœŒš€·€Ț€»€ó" #. STID_CANNOT_EXECUTE_GIVEN_CMD #: ../../strtbl.c:2597 #, c-format msgid "Cannot execute '%s'." msgstr "'%s' €òŒÂčԀǀ­€Ț€»€ó." #. STID_CONNECTION_INTERRUPTED #: ../../strtbl.c:2599 #, c-format msgid "%s: connection interrupted." msgstr "" #. STID_CANT_CONN_TO_HOST_PORT #: ../../strtbl.c:2601 #, c-format msgid "%s: cannot connect to %s%s%s." msgstr "" #. STID_FAIL_TO_GET_DATA_FROM_URL #: ../../strtbl.c:2603 #, c-format msgid "%s: fail to get data from '%s'." msgstr "" #. STID_NETWORK_ERR_TALK_TO_HOST_PORT #: ../../strtbl.c:2605 #, c-format msgid "%s: network error occurred when talking to %s%s%s." msgstr "" #. STID_FAILED_TO_LOGIN_TO_HOST_PORT #: ../../strtbl.c:2607 #, c-format msgid "%s: fail to login to %s%s%s." msgstr "" #. STID_CANT_FIND_LOCATION_IN_HDR #: ../../strtbl.c:2609 #, c-format msgid "" "%s: Cannot find forwarding 'Location' information in message header while " "getting data from '%s'." msgstr "" #. STID_LNK_FWD_5_TIMES_LOAD_ABORT #: ../../strtbl.c:2611 #, c-format msgid "" "%s: Links forwarded more than 5 times while getting data from '%s'.\n" "\n" "Loading is aborted." msgstr "" #. STID_CANT_FIND_WWW_AUTHEN_IN_HDR #: ../../strtbl.c:2613 #, c-format msgid "" "%s: Cannot find 'WWW-Authenticate' information in message header while " "getting data from '%s'." msgstr "" #. STID_AUTHEN_REQ_FOR_REALM #: ../../strtbl.c:2615 #, c-format msgid "%s: Authentication information for %s required..." msgstr "" #. STID_ENTER_USERNAME_FOR_REALM #: ../../strtbl.c:2617 #, c-format msgid "Please enter UserName for %s:" msgstr "" #. STID_ENTER_PASSWORD_FOR_REALM #: ../../strtbl.c:2619 #, c-format msgid "Please enter Password for %s:" msgstr "" #. STID_FAIL_TO_PARSE_GIVEN_URL #: ../../strtbl.c:2621 #, c-format msgid "Fail to parse URL: '%s'." msgstr "" #. STID_TOOL_NOT_KNOW_HOW_TALK_PROTO #: ../../strtbl.c:2623 #, c-format msgid "%s does not know how to talk using the '%s' protocol." msgstr "" #. STID_LAUNCH_GIVEN_VIEWER #: ../../strtbl.c:2625 #, c-format msgid "Launch viewer: %s" msgstr "" #. STID_CANT_OPEN_GIVEN_MAILCAP_FILE #: ../../strtbl.c:2627 #, c-format msgid "Cannot open mailcap file '%s'." msgstr "" #. STID_MALFORMED_MAILCAP_ENTRY #: ../../strtbl.c:2629 #, c-format msgid "" "Malformed mailcap entry:\n" "\n" "%s/%s; %s" msgstr "" #. STID_MALFORMED_MAILCAP_ENTRY_PARAM #: ../../strtbl.c:2631 #, c-format msgid "" "Malformed mailcap entry:\n" "\n" "%s/%s; %s; %s" msgstr "" #. STID_TOOL_CANT_HANDLE_MP_MIME #: ../../strtbl.c:2633 #, c-format msgid "%s does not know how to handle Multipart MIME types." msgstr "" #. STID_CANT_FIND_RT_BRACK_MC #: ../../strtbl.c:2635 #, c-format msgid "" "Cannot find matching '}' for mailcap entry:\n" "\n" "%s/%s; %s" msgstr "" #. STID_CANT_FIND_RT_BRACK_MC_PARAM #: ../../strtbl.c:2637 #, c-format msgid "" "Cannot find matching '}' for mailcap entry:\n" "\n" "%s/%s; %s; %s" msgstr "" #. STID_CANT_FIND_NAMED_INFO_IN_CT #: ../../strtbl.c:2639 #, c-format msgid "%s: cannot find the '%s' information in the message Content-Type." msgstr "" #. STID_SAVE_GIVEN_STR_AS #: ../../strtbl.c:2641 #, c-format msgid "Save %s as:" msgstr "" #. STID_NO_VIEWER_SAVE_GIVEN_STR_AS #: ../../strtbl.c:2643 #, c-format msgid "No viewer found. Save %s as:" msgstr "" #. STID_UNKNOWN_ERR_IN_COPYING_FILES #: ../../strtbl.c:2645 msgid "Unknown error in copying files." msgstr "" #. STID_CANT_GETHOSTNAME_USE_LOCALH #: ../../strtbl.c:2647 msgid "Cannot gethostname(), 'localhost' is used instead." msgstr "" #. STID_TURN_OFF_AUTO_PAN_SET_XDEF #: ../../strtbl.c:2649 #, c-format msgid "To turn off auto-panning, set %s.%s to false in X defaults." msgstr "" #. STID_WILL_UPD_WIN_SMOOTH_SCROLL #: ../../strtbl.c:2651 msgid "Will update canvas window smoothly while scrolling." msgstr "„脯„íĄŒ„ëĂæ€Ë€ÏĄą„­„ă„ó„Є脊„Ł„ó„ɄЀò€Ê€á€é€«€Ëččż·€č€ë" #. STID_WILL_UPD_WIN_JUMP_SCROLL #: ../../strtbl.c:2653 #, fuzzy msgid "Will jump update canvas window while scrolling." msgstr "„脯„íĄŒ„ëĂæ€Ë€ÏĄą„­„ă„ó„Є脊„Ł„ó„ɄЀòččż·€č€ë" #. STID_WILL_NOT_UPD_WIN_SCROLL #: ../../strtbl.c:2655 msgid "Will not update canvas window while scrolling." msgstr "„脯„íĄŒ„ëĂæ€Ë€ÏĄą„­„ă„ó„Є脊„Ł„ó„ɄЀòččż·€·€Ê€€" #. STID_INCONSIS_VERTEX_SEL_IN_FUNC #: ../../strtbl.c:2657 #, c-format msgid "Inconsistent vertex selection detected in %s." msgstr "" #. STID_INVALID_NAMED_TELEPORT_DEST #: ../../strtbl.c:2659 #, c-format msgid "Invalid teleport destination '%s'." msgstr "" #. STID_Q_FILE_NOT_EXIST_CREATE #: ../../strtbl.c:2661 #, c-format msgid "" "File '%s' does not exist.\n" "\n" "Would you like to create it?" msgstr "" #. STID_CANT_FIND_PAGE_NAMED_TO_TEL #: ../../strtbl.c:2663 #, c-format msgid "Cannot find page named '%s' to teleport to." msgstr "" #. STID_CANT_FIND_PAGE_NUM_TO_TEL #: ../../strtbl.c:2665 #, c-format msgid "Cannot find page %1d to teleport to." msgstr "" #. STID_CANT_GROUP_IN_VERTEX_MODE #: ../../strtbl.c:2667 msgid "Cannot group in vertex mode." msgstr "" #. STID_CANT_GROUP_SINGLE_OBJECT #: ../../strtbl.c:2669 msgid "Cannot group a single object." msgstr "" #. STID_INVALID_XDEF_USE_ALT_OCTVALUE #: ../../strtbl.c:2671 #, c-format msgid "Invalid %s.%s: '%s', 0%03o is used instead." msgstr "" #. STID_INVALID_XDEF_RNG_USE_ALT_STR #: ../../strtbl.c:2673 #, c-format msgid "Invalid %s.%s: '%s', (must be between %s and %s), %s is used instead." msgstr "" #. STID_CANT_CREATE_NAMED_DIRECTORY #: ../../strtbl.c:2675 #, c-format msgid "Cannot create the '%s' directory." msgstr "" #. STID_OPR_USING_NAMED_DIR_WILL_FAIL #: ../../strtbl.c:2677 #, c-format msgid "" "Operations using the '%s' directory (such as CopyProperties() and " "PasteProperties()) will fail." msgstr "" #. STID_CREATE_A_SHAPE_FAILED #: ../../strtbl.c:2679 msgid "Create a shape failed." msgstr "" #. STID_CREATE_SHADOW_SHAPE_NO_FILL #: ../../strtbl.c:2681 msgid "" "You are attempting to create a shadowed shape but the shape has no fill (the " "shadow will show through).\n" "\n" "Would you like to create such a shape without a shadow?" msgstr "" #. STID_CREATE_SHADOW_SHAPE_TRAN_FILL #: ../../strtbl.c:2683 msgid "" "You are attempting to create a shadowed shape but the shape has transparent " "fill (the shadow will show through).\n" "\n" "Would you like to create such a shape without a shadow?" msgstr "" #. STID_ENTER_XY_OFFSET_FOR_SHP_SHDW #: ../../strtbl.c:2685 #, c-format msgid "Please enter X and Y offsets for the shape shadow: [current: %1d,%1d]" msgstr "" #. STID_SHAPE_SHDW_XY_OFFSETS_SET_TO #: ../../strtbl.c:2687 #, c-format msgid "Shape shadow offsets set to: %1d, %1d." msgstr "·Á€Ë€Ä€±€ë±Æ€Î„Ș„Ő„»„Ă„È€Î»ŰÄê: %1d, %1d." #. STID_INVALID_SHORTCUT_ENTRY_SKIP #: ../../strtbl.c:2689 #, c-format msgid "Invalid shortcut entry: '%s'. It is skipped." msgstr "" #. STID_DUP_SHORTCUT_ENTRY_FOR_CHAR #: ../../strtbl.c:2691 #, c-format msgid "Warning: duplicate shortcut entry for '%c'." msgstr "" #. STID_INVALID_SHORTCUT_ENTRY #: ../../strtbl.c:2693 #, c-format msgid "Invalid shortcut entry: '%s'." msgstr "" #. STID_WARN_DUP_CMDID #: ../../strtbl.c:2695 #, c-format msgid "Warning: duplicate cmdid %1d." msgstr "" #. STID_PUSH_IN_WB #: ../../strtbl.c:2697 msgid "Push() is disabled in WhiteBoard mode." msgstr "" #. STID_FILE_VER_ABORT_READ_SYMBOL #: ../../strtbl.c:2699 #, c-format msgid "" "File version (=%1d) too large.\n" "\n" "Read symbol aborted.\n" "\n" "You may need a more recent version of %s. Please check <URL:%s>." msgstr "" #. STID_CANT_FIND_NAMED_OBJ_IN_FUNC #: ../../strtbl.c:2701 #, c-format msgid "Cannot find the '%s' text object in %s." msgstr "" #. STID_SEL_A_SYM_TO_INSTAN_IN_DOMAIN #: ../../strtbl.c:2703 #, c-format msgid "Please select a symbol to INSTANTIATE in the '%s' domain..." msgstr "" #. STID_CANT_INSTAN_FILE_UNKNOWN_EXT #: ../../strtbl.c:2705 #, c-format msgid "Cannot instantiate because '%s' has unknow file extension." msgstr "" #. STID_CANT_MAKESYMBOLIC_VERTEX_MODE #: ../../strtbl.c:2707 msgid "Cannot MakeSymbolic() in vertex mode." msgstr "" #. STID_SEL_ONLY_ONE_FOR_MAKESYMBOLIC #: ../../strtbl.c:2709 msgid "Please select only one object for MakeSymbolic()." msgstr "MakeSymbolic() €òčÔ€Š„Ș„Ö„ž„§„Ż„È€ò°ì€Ä€À€±ÁȘÂò€·€Æ€Ż€À€”€€." #. STID_PIN_CANT_MADE_INTO_SYMBOL #: ../../strtbl.c:2711 #, fuzzy msgid "A pin object cannot be made into a symbol object." msgstr "ÁȘÂò€·€ż„°„ëĄŒ„Ś/„ą„€„ł„ó€ò°ì€Ä€Î„·„ó„܄륊„Ș„Ö„ž„§„Ż„È€Ë€č€ë." #. STID_SEL_OBJ_IS_NOW_SYMBOLIC #: ../../strtbl.c:2713 msgid "Selected object is now SYMBOLIC." msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż„È€Ï„·„ó„Ü„ëČœ€”€ì€Ț€·€ż." #. STID_ENTER_NAME_FOR_THE_ICON #: ../../strtbl.c:2715 msgid "Please enter name for the icon:" msgstr "„ą„€„ł„ó€ÎÌŸÁ°€òÆțÎÏ€·€Æ€Ż€À€”€€:" #. STID_NAME_NOT_SPEC_ICON_NOT_CREATE #: ../../strtbl.c:2717 msgid "Name not specified, icon not created." msgstr "" #. STID_CANT_SAVE_OBJ_ICON_NOT_CREATE #: ../../strtbl.c:2719 msgid "Cannot save as an object file, icon not created." msgstr "" #. STID_CANT_FIND_DOT_IN_ICON_NAME_MI #: ../../strtbl.c:2721 msgid "Cannot find '.' in icon_name in MakeIconic()." msgstr "" #. STID_CANT_SAVE_PIN_ICON_NOT_CREATE #: ../../strtbl.c:2723 msgid "Cannot save as a pin file, icon not created." msgstr "" #. STID_CANT_OPEN_FOR_WRITE_ICON_CRET #: ../../strtbl.c:2725 #, c-format msgid "Cannot open '%s' for writing, icon not created." msgstr "" #. STID_SEL_OBJ_IS_NOW_ICONIC #: ../../strtbl.c:2727 msgid "Selected object is now ICONIC." msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż„È€Ï„ą„€„ł„óČœ€”€ì€Ț€·€ż." #. STID_SEL_ONLY_ONE_FOR_MAKEICONIC #: ../../strtbl.c:2729 msgid "Please select one object to make it ICONIC." msgstr "„ą„€„ł„óČœ€č€ë„Ș„Ö„ž„§„Ż„È€òÁȘÂò€·€Æ€Ż€À€”€€." #. STID_SEL_OBJS_ARE_NOW_GROUP #: ../../strtbl.c:2731 msgid "Selected ICONIC objects are GROUP objects now." msgstr "" #. STID_GIVEN_LINE_SKIP_NOT_AN_ATTR #: ../../strtbl.c:2733 #, c-format msgid "Line %1d in '%s' is skipped because it does not specify an attribute." msgstr "" #. STID_GIVEN_LINE_SKIP_ILLEGAL_CHAR #: ../../strtbl.c:2735 #, c-format msgid "" "Line %1d in '%s' is skipped because attribute name contains illegal " "characters such as '!' or '.'." msgstr "" #. STID_SEL_ONE_OBJ_FOR_IMPORTATTRS #: ../../strtbl.c:2737 msgid "Please select only one object for ImportAttrs()." msgstr "" #. STID_SEL_TEXT_FILE_OF_ATTR_TO_IMP #: ../../strtbl.c:2739 msgid "Please select a text file containing attributes to import..." msgstr "" #. STID_CANT_IMPORT_REMOTE_TEXT_FILE #: ../../strtbl.c:2741 msgid "Importing remote text file not supported." msgstr "" #. STID_SEL_ONE_OBJ_FOR_EXPORTATTRS #: ../../strtbl.c:2743 msgid "Please select only one object for ExportAttrs()." msgstr "" #. STID_SEL_OBJ_HAS_NO_ATTR_TO_EXPORT #: ../../strtbl.c:2745 #, fuzzy msgid "Select object has no attributes to export." msgstr "ÁȘÂò€·€ż„Æ„­„č„È€ËÈó„Æ„­„č„ÈĄŠ„Ș„Ö„ž„§„Ż„ÈÍрΰÀ­€ò€Ä€±€ë" #. STID_ENTER_TXT_FILE_TO_EXPORT_CRES #: ../../strtbl.c:2747 msgid "" "Please enter a text file name to export to: ( <CR>: accept, <ESC>: cancel )" msgstr "" #. STID_ATTR_EXPORTED_TO_NAMED_FILE #: ../../strtbl.c:2749 #, c-format msgid "Attributes exported to '%s'." msgstr "" #. STID_CANT_FIND_ATTR_FOR_MERGEWTBL #: ../../strtbl.c:2751 #, c-format msgid "Cannot find the '%s' attribute for MergeWithTable()." msgstr "" #. STID_MALFORMED_ATTR_FOR_MERGEWTBL #: ../../strtbl.c:2753 #, c-format msgid "Malformed '%s' attribute for MergeWithTable()." msgstr "" #. STID_SEL_ONE_OBJ_FOR_MERGEWTBL #: ../../strtbl.c:2755 msgid "Please select only one object for MergeWithTable()." msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_MERGE #: ../../strtbl.c:2757 msgid "File modified, save file before merge? [ync](y)" msgstr "" #. STID_Q_MERGEWTBL_CANT_UNDO_PROCEED #: ../../strtbl.c:2759 msgid "" "MergeWithTable cannot be undone.\n" "\n" "Ok to proceed? [ync](y)" msgstr "" #. STID_SEL_TEXT_FILE_FOR_MERGEWTBL #: ../../strtbl.c:2761 msgid "Please select a text file for MergeWithTable()." msgstr "" #. STID_CANT_MERGE_W_REMOTE_TEXT_FILE #: ../../strtbl.c:2763 msgid "Merging remote text file not supported." msgstr "" #. STID_FIND_COL_NAMES_IN_FILE_ABORT #: ../../strtbl.c:2765 #, c-format msgid "" "Cannot find column names in '%s'.\n" "\n" "Merge aborted." msgstr "" #. STID_MALFORMED_COL_NAMES_ABORT_MRG #: ../../strtbl.c:2767 #, c-format msgid "" "Malformed column names in '%s'.\n" "\n" "Merge aborted." msgstr "" #. STID_LF_BTN_PLACE_MRG_OTHER_CANCEL #: ../../strtbl.c:2769 msgid "Left button places a merged object, other buttons cancel merging." msgstr "" #. STID_MALFORMED_TBL_LINE_ABORT_MRG #: ../../strtbl.c:2771 #, c-format msgid "" "Malformed table at line %d in '%s'.\n" "\n" "Merge aborted." msgstr "" #. STID_CANT_FND_NAMED_ATTR_ABORT_MRG #: ../../strtbl.c:2773 #, c-format msgid "" "Cannot find attribute named '%s'.\n" "\n" "Merge aborted." msgstr "" #. STID_NUM_OBJECTS_GENERATED #: ../../strtbl.c:2775 #, c-format msgid "%1d object(s) generated." msgstr "" #. STID_CANT_FND_TABLE_ATTRS_FILE_ATT #: ../../strtbl.c:2777 msgid "" "Cannot find the \"!.TABLE_ATTRS\" file attribute.\n" "\n" "Cannot proceed with ExportToTable()." msgstr "" #. STID_NUM_OBJECTS_EXPORTED #: ../../strtbl.c:2779 #, c-format msgid "%1d object(s) exported." msgstr "" #. STID_ATTRS_EXPORTED_TO_TBL_FILE #: ../../strtbl.c:2781 #, c-format msgid "Attributes exported to table file '%s'." msgstr "" #. STID_SEL_ONE_ICON_OBJ_TO_PUSH #: ../../strtbl.c:2783 msgid "Please select one ICON object to push into." msgstr "" #. STID_CANT_FND_SYM_FILE_IN_PATH #: ../../strtbl.c:2789 #, c-format msgid "Cannot find '%s.%s' in %s." msgstr "" #. STID_CANNOT_OPEN_FOR_READ_PUSH #: ../../strtbl.c:2791 #, c-format msgid "Cannot open '%s' for reading. Icon not pushed into." msgstr "" #. STID_FILE_VER_ABORT_PUSH #: ../../strtbl.c:2793 #, c-format msgid "" "File version (=%1d) too large.\n" "\n" "Push aborted.\n" "\n" "You may need a more recent version of %s. Please check <URL:%s>." msgstr "" #. STID_POP_BACK_TO_PARENT_UNDEF #: ../../strtbl.c:2795 msgid "Poping back to parent level. Current file undefined." msgstr "" #. STID_ALREADY_AT_TOP_LEVEL #: ../../strtbl.c:2797 msgid "Already at top level." msgstr "" #. STID_FILE_MOD_SAVE_BEFORE_POP #: ../../strtbl.c:2799 msgid "" "File modified, save file before poping back to the parent level? [ync](y)" msgstr "" #. STID_CANT_FND_SYM_IN_NAMED_TO_INST #: ../../strtbl.c:2801 #, c-format msgid "Cannot find a symbol object in '%s' to instantiate." msgstr "" #. STID_CANT_FIND_XDEF #: ../../strtbl.c:2803 #, c-format msgid "Cannot find %s.%s." msgstr "%s.%s €Źž«ÉŐ€«€ê€Ț€»€ó." #. STID_ENTER_USERAGENT_FOR_HTTP #: ../../strtbl.c:2805 #, fuzzy msgid "Please specify 'UserAgent' to be used when making an HTTP request." msgstr "HTTP „ê„Ż„š„č„È€ÎșÆ€Ë»È€Š„æĄŒ„¶ÌŸÀßÄê" #. STID_ENTER_USERAGENT_FOR_HTTP_CUR #: ../../strtbl.c:2807 #, fuzzy, c-format msgid "" "Please specify 'UserAgent' to be used when making an HTTP request (current " "value is '%s')." msgstr "HTTP „ê„Ż„š„č„È€ÎșÆ€Ë»È€Š„æĄŒ„¶ÌŸÀßÄê" #. STID_PRESS_ENTER_FOR_DEF_USERAGENT #: ../../strtbl.c:2809 msgid "( press <ENTER> for the default 'UserAgent' )" msgstr "" #. STID_WILL_USE_DEF_USERAGENT_HTTP #: ../../strtbl.c:2811 #, fuzzy msgid "Will use the default 'UserAgent' when making an HTTP request." msgstr "HTTP „ê„Ż„š„č„È€ÎșÆ€Ë»È€Š„æĄŒ„¶ÌŸÀßÄê" #. STID_WILL_USE_NAMED_USERAGENT_HTTP #: ../../strtbl.c:2813 #, fuzzy, c-format msgid "Will use '%s' as 'UserAgent' when making an HTTP request." msgstr "HTTP „ê„Ż„š„č„È€ÎșÆ€Ë»È€Š„æĄŒ„¶ÌŸÀßÄê" #. STID_ENTER_REFERRER_FOR_HTTP #: ../../strtbl.c:2815 #, fuzzy msgid "Please specify 'Referrer' to be used when making an HTTP request." msgstr "HTTP „ê„Ż„š„č„È€ÎșÆ€Ë»È€Š„æĄŒ„¶ÌŸÀßÄê" #. STID_ENTER_REFERRER_FOR_HTTP_CUR #: ../../strtbl.c:2817 #, fuzzy, c-format msgid "" "Please specify 'Referrer' to be used when making an HTTP request (current " "value is '%s')." msgstr "HTTP „ê„Ż„š„č„È€ÎșÆ€Ë»È€Š„æĄŒ„¶ÌŸÀßÄê" #. STID_PRESS_ENTER_FOR_NO_REFERRER #: ../../strtbl.c:2819 msgid "( press <ENTER> for no 'Referrer' )" msgstr "" #. STID_WILL_NOT_USE_REFERRER_HTTP #: ../../strtbl.c:2821 #, fuzzy msgid "Will not use 'Referrer' when making an HTTP request." msgstr "HTTP „ê„Ż„š„č„È€ÎșÆ€Ë»È€Š„æĄŒ„¶ÌŸÀßÄê" #. STID_WILL_USE_NAMED_REFERRER_HTTP #: ../../strtbl.c:2823 #, fuzzy, c-format msgid "Will use '%s' as 'Referrer' when making an HTTP request." msgstr "HTTP „ê„Ż„š„č„È€ÎșÆ€Ë»È€Š„æĄŒ„¶ÌŸÀßÄê" #. STID_WILL_USE_KEEP_ALIVE_HTTP #: ../../strtbl.c:2825 msgid "Will use Keep-Alive HTTP connections." msgstr "" #. STID_NOT_WILL_USE_KEEP_ALIVE_HTTP #: ../../strtbl.c:2827 msgid "Will not use Keep-Alive HTTP connections." msgstr "" #. STID_CANT_LOCATE_NAMED_SERVER_TRY #: ../../strtbl.c:2829 #, c-format msgid "" "%s: unable to locate the server '%s'.\n" "\n" "Please check the server name and try again." msgstr "" #. STID_FAIL_TO_MAKE_SOCKET_BLOCK #: ../../strtbl.c:2831 msgid "Fail to make socket blocking." msgstr "" #. STID_FAIL_TO_MAKE_SOCKET_NON_BLOCK #: ../../strtbl.c:2833 msgid "Fail to make socket non-blocking." msgstr "" #. STID_BROKEN_PIPE_CONTACT_HOST #: ../../strtbl.c:2835 #, c-format msgid "Broken pipe while contacting '%s'." msgstr "" #. STID_WRITE_TO_SOCKET_FAILED #: ../../strtbl.c:2837 msgid "Writing to socket failed." msgstr "" #. STID_READ_FROM_SOCKET_FAILED #: ../../strtbl.c:2839 msgid "Reading from socket failed." msgstr "" #. STID_UNEXP_NETWORK_ERR_WRITE_SOCK #: ../../strtbl.c:2841 msgid "Unexpected network error while writing to socket." msgstr "" #. STID_UNEXP_NETWORK_ERR_READ_SOCK #: ../../strtbl.c:2843 msgid "Unexpected network error while reading from socket." msgstr "" #. STID_LOCKED_OBJS_CANT_BE_STRETCHED #: ../../strtbl.c:2845 msgid "Locked object(s) cannot be stretched." msgstr "„í„Ă„Ż€”€ì€ż„Ș„Ö„ž„§„Ż„È€ÏłÈÂç€ò€Ç€­€Ț€»€ó." #. STID_CANT_STRETCH_OBJ_HAS_0_WIDTH #: ../../strtbl.c:2847 msgid "Cannot stretch. Object has ZERO width." msgstr "" #. STID_CANT_STRETCH_OBJ_HAS_0_HEIGHT #: ../../strtbl.c:2849 msgid "Cannot stretch. Object has ZERO height." msgstr "" #. STID_LOCKED_OBJS_CANT_BE_SCALED #: ../../strtbl.c:2851 msgid "Locked object(s) cannot be scaled." msgstr "" #. STID_ENTER_SCALING_FACTORS_XY #: ../../strtbl.c:2853 msgid "Please enter scaling factors: [X:Y] or [scale]" msgstr "" #. STID_ENTER_A_SCALING_FACTOR #: ../../strtbl.c:2855 msgid "Please enter a scaling factor:" msgstr "" #. STID_ONLY_INPUT_ONE_NUMERIC_VAL #: ../../strtbl.c:2857 msgid "Please only input only one numeric value." msgstr "" #. STID_SCALING_EVERYTHING_LARGE_SURE #: ../../strtbl.c:2859 #, c-format msgid "Scaling everything by %g times. Are you sure?" msgstr "" #. STID_DISABLE_ON_RESIZE_ROTATE #: ../../strtbl.c:2861 #, c-format msgid "" "The '%s' object has an on_resize() script.\n" "\n" "To rotate it will disable the on_resize() script. Is it okay to rotate it?" msgstr "" #. STID_DISABLE_ON_RESIZE_SHEAR #: ../../strtbl.c:2863 #, c-format msgid "" "The '%s' object has an on_resize() script.\n" "\n" "To shear it will disable the on_resize() script. Is it okay to shear it?" msgstr "" #. STID_DISABLE_ON_RESIZE_TRANSFORM #: ../../strtbl.c:2865 #, c-format msgid "" "The '%s' object has an on_resize() script.\n" "\n" "To transform it will disable the on_resize() script. Is it okay to " "transform it?" msgstr "" #. STID_LOCKED_OBJS_CANT_BE_FLIPPED #: ../../strtbl.c:2867 msgid "Locked object(s) cannot be flipped." msgstr "" #. STID_LOCKED_OBJS_ARE_NOT_FLIPPED #: ../../strtbl.c:2869 msgid "Locked object(s) are not flipped." msgstr "" #. STID_LOCKED_OBJS_ARE_NOT_STRETCHED #: ../../strtbl.c:2871 msgid "Locked object(s) are not stretched." msgstr "„í„Ă„Ż€”€ì€ż„Ș„Ö„ž„§„Ż„È€ÏłÈÂçœÌŸź€”€ì€Ț€»€ó" #. STID_LOCKED_OBJS_ARE_NOT_ROTATED #: ../../strtbl.c:2873 msgid "Locked object(s) are not rotated." msgstr "" #. STID_LOCKED_OBJS_ARE_NOT_SHEARED #: ../../strtbl.c:2875 msgid "Locked object(s) are not sheared." msgstr "" #. STID_LOCKED_OBJS_ARE_NOT_XFORMED #: ../../strtbl.c:2877 msgid "Transformation matrix not changed for locked object(s)." msgstr "" #. STID_FLIPPED_HORIZONTALLY #: ../../strtbl.c:2879 #, fuzzy msgid "Flipped horizontally." msgstr "¶ÀÁü(żćÊżÊęžț)" #. STID_FLIPPED_VERTICALLY #: ../../strtbl.c:2881 #, fuzzy msgid "Flipped vertically." msgstr "¶ÀÁü(żâÄŸÊęžț)" #. STID_LOCKED_OBJS_CANT_BE_ROTATED #: ../../strtbl.c:2883 msgid "Locked object(s) cannot be rotated." msgstr "" #. STID_ROTATED_CLOCKWISE #: ../../strtbl.c:2885 #, fuzzy msgid "Rotated clockwise." msgstr "»ț·ŚÊęžț€ËČóĆŸ" #. STID_ROTATED_COUNTER_CLOCKWISE #: ../../strtbl.c:2887 #, fuzzy msgid "Rotated counter-clockwise." msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż„È€òÈż»ț·ŚŒț€ê€ËČóĆŸ€č€ë" #. STID_ENTER_TEXT_ROT_IN_DEGREE_CUR #: ../../strtbl.c:2889 #, fuzzy, c-format msgid "Please enter text rotation in degrees: (current value is %s)" msgstr "ÉÁČèÊž»ú€ÎČóĆŸłŃĆÙ€òÀßÄê" #. STID_CANT_PARSE_ENTER_ONE_NUM_VAL #: ../../strtbl.c:2891 #, c-format msgid "" "Cannot parse '%s'.\n" "\n" "Please enter a numeric value." msgstr "" #. STID_INVALID_VAL_ENTERED_RNG_INC #: ../../strtbl.c:2893 #, c-format msgid "" "Invalid value entered: '%s'. Please enter a numeric value between %1d and %" "1d (inclusive)." msgstr "" #. STID_TEXT_ROTATION_SET_TO_GIVEN #: ../../strtbl.c:2895 #, c-format msgid "Text rotation set to %s." msgstr "" #. STID_ENTER_ROT_INC_IN_DEGREE_CUR #: ../../strtbl.c:2897 #, fuzzy, c-format msgid "Please enter text rotation increment in degrees: (current value is %s)" msgstr "Êž»ú€òČóĆŸ€č€ë»ț€ÎÂ瀭€”€ò»ŰÄê..." #. STID_INVALID_VAL_ENTERED_RNG_EXC #: ../../strtbl.c:2899 #, c-format msgid "" "Invalid value entered: '%s'. Please enter a numeric value > %1d and < %1d." msgstr "" #. STID_TEXT_ROT_INC_SET_TO_GIVEN #: ../../strtbl.c:2901 #, fuzzy, c-format msgid "Text rotation increment set to %s." msgstr "Êž»ú€òČóĆŸ€č€ë»ț€ÎÂ瀭€”€ò»ŰÄê..." #. STID_LOCKED_OBJS_CANT_BE_XFORMED #: ../../strtbl.c:2903 msgid "Cannot change transformation matrix for locked object(s)." msgstr "" #. STID_SEL_OBJ_TOO_SMALL_ROT_ANOTHER #: ../../strtbl.c:2905 msgid "" "Selected object is too small to rotate.\n" "\n" "Please select another object to rotate." msgstr "" #. STID_SEL_OBJ_TOO_SMALL_SHEAR_ANO #: ../../strtbl.c:2907 msgid "" "Selected object is too small to shear.\n" "\n" "Please select another object to shear." msgstr "" #. STID_CANNOT_CREATE_GC #: ../../strtbl.c:2909 msgid "Cannot create GC." msgstr "" #. STID_READ_ONLY_TEXT_CANT_BE_EDITED #: ../../strtbl.c:2911 msgid "Read-only text cannot be edited." msgstr "" #. STID_TEXT_SZ_NOT_AVAIL_TRY_DIFF #: ../../strtbl.c:2913 #, c-format msgid "" "Text size=%1d not available.\n" "\n" "Please try a different size." msgstr "" #. STID_CANT_INS_NON_DB_CH_AT_CUR_REM #: ../../strtbl.c:2915 msgid "" "Cannot insert a non-double-byte character at the text cursor position. The " "non-double-byte character is removed." msgstr "" #. STID_TOO_MANY_BYTES_IN_CH_IGNORED #: ../../strtbl.c:2917 msgid "Cannot handle so many bytes in a character. Character is ignored." msgstr "" #. STID_CANT_TAB_OUT_OF_NON_ATTR_TEXT #: ../../strtbl.c:2919 msgid "Cannot TAB out of a non-attribute text." msgstr "" #. STID_COMPOUND_TEXT_BUF_IS_EMPTY #: ../../strtbl.c:2921 msgid "Compound-text buffer is empty." msgstr "" #. STID_CUT_BUFFER_IS_EMPTY #: ../../strtbl.c:2923 msgid "Cut buffer is empty." msgstr "" #. STID_GIVEN_NUM_LINES_PASTED #: ../../strtbl.c:2927 #, c-format msgid "%1d line(s) pasted." msgstr "" #. STID_COPY_FAIL_SEL_STR_MAY_TOO_LNG #: ../../strtbl.c:2929 msgid "Copy to cut buffer failed. Selected string may be too long." msgstr "" #. STID_UNEXPECTED_TOK_IN_ABORT_READ #: ../../strtbl.c:2931 #, c-format msgid "%s, %d: Unexpected token '%c' in %s. Read aborted." msgstr "" #. STID_ILLEGAL_FIELD_IN_ABORT_READ #: ../../strtbl.c:2933 #, c-format msgid "%s, %d: Illegal field '%s' in %s. Read aborted." msgstr "" #. STID_INVALID_GIVEN_VALUE_SPECIFIED #: ../../strtbl.c:2935 #, c-format msgid "Invalid value '%s' specified." msgstr "" #. STID_ENTER_SCRIPT_FRACTION_CUR_IS #: ../../strtbl.c:2937 #, c-format msgid "" "Please enter a fraction for the super/subscript size (current fraction is %s)" ":" msgstr "" #. STID_SCRIPT_FRACTION_SET_TO_STR #: ../../strtbl.c:2939 #, c-format msgid "Script fraction set to '%s'." msgstr "" #. STID_ENTER_INT_WIDTH_FOR_THIN_SPC #: ../../strtbl.c:2941 msgid "" "Please enter an integer width value for the thin space (a negative value " "indicates a negative think space):" msgstr "" #. STID_ENTER_INT_VAL_FOR_VERT_OFFSET #: ../../strtbl.c:2943 msgid "" "Please enter an integer value for the vertical offset (a negative value " "raises the current line):" msgstr "" #. STID_FAIL_INSERT_SCRIPT_FONT_SZ #: ../../strtbl.c:2945 msgid "Failed to insert super/subscript because font size is not available." msgstr "" #. STID_TOOL_DONT_KNOW_HOW_RUN_GUNZIP #: ../../strtbl.c:2947 #, c-format msgid "%s does not know how to run gunzip." msgstr "" #. STID_SPECIFY_DISPLAY_ON_CMD_LINE #: ../../strtbl.c:2949 msgid "Please specify '-display $DISPLAY' on the command line." msgstr "" #. STID_FILE_VER_ABORT_TOOL #: ../../strtbl.c:2951 #, c-format msgid "" "File version (=%1d) too large.\n" "\n" "%s aborted.\n" "\n" "You may need a more recent version of %s. Please check <URL:%s>." msgstr "" #. STID_FILE_SKIP_CONTAINS_ONE_PAGE #: ../../strtbl.c:2953 #, c-format msgid "%s is skipped because it only contains 1 page." msgstr "" #. STID_FILE_SKIP_CONTAINS_NUM_PAGE #: ../../strtbl.c:2955 #, c-format msgid "%s is skipped because it only contains %1d pages." msgstr "" #. STID_FILE_NOT_CONTAIN_COLOR_ABORT #: ../../strtbl.c:2957 #, c-format msgid "" "File does not contain enough color information (it is not saved by tgif-3.0-" "p10 or beyond). %s aborted." msgstr "" #. STID_SPEC_FILE_WHEN_STDOUT_USED #: ../../strtbl.c:2959 msgid "File name must be specified when -stdout is used." msgstr "" #. STID_TOOL_FILE_NAME_TO_PRINT #: ../../strtbl.c:2961 #, c-format msgid "%s File Name to Print" msgstr "" #. STID_CANT_ONEFPPAGE_IN_TILED_PAGE #: ../../strtbl.c:2963 msgid "Cannot use -one_file_per_page in TILED page mode." msgstr "" #. STID_ONE_FILE_ONLY_WITH_STDOUT #: ../../strtbl.c:2965 msgid "Only one file name can be specified with -stdout." msgstr "" #. STID_ONE_FILE_ONLY_RAW_PLUS_H #: ../../strtbl.c:2967 msgid "Cannot process more than one file in -raw or -raw+h mode." msgstr "" #. STID_ONE_FILE_ONLY_DOSEPSFILTER #: ../../strtbl.c:2969 msgid "Cannot process more than one file in -dosepsfilter mode." msgstr "" #. STID_CANT_PRTGIF_OFPP_TILED_PAGE #: ../../strtbl.c:2971 msgid "Cannot use -one_file_per_page mode with a TILED page mode file." msgstr "" #. STID_INVALID_SHARELIB_VER_IN_FILE #: ../../strtbl.c:2973 #, c-format msgid "Invalid shared library version in '%s'." msgstr "" #. STID_FAIL_LOAD_SHARELIB #: ../../strtbl.c:2975 #, c-format msgid "Fail to load shared library '%s'." msgstr "" #. STID_FAIL_GET_ENTRY_PT_IN_SHARELIB #: ../../strtbl.c:2977 #, c-format msgid "Fail to get entry point '%s' in shared lib '%s'." msgstr "" #. STID_SHARELIB_TGEF_MSG_INIT_FAIL #: ../../strtbl.c:2979 #, c-format msgid "%s: TGEF_MSG_INIT failed with return code %ld." msgstr "" #. STID_SHARELIB_CNFLCT_PROTOCOL_VER #: ../../strtbl.c:2981 #, c-format msgid "Conflicting protocol version %1d implemented by '%s'." msgstr "" #. STID_SHARELIB_TGEF_MSG_LOAD_FAIL #: ../../strtbl.c:2983 #, c-format msgid "%s: TGEF_MSG_LOAD failed with return code %ld." msgstr "" #. STID_SHARELIB_TGEF_MSG_NO_BMP_INFO #: ../../strtbl.c:2985 #, c-format msgid "%s: TGEF_MSG_LOAD returned with no bitmap info." msgstr "" #. STID_ALLOC_BMP_FAIL_FOR_SHARELIB #: ../../strtbl.c:2987 #, c-format msgid "Failed to allocate bitmap for '%s'." msgstr "" #. STID_UNSUP_PROTOCOL_VER_SHARELIB #: ../../strtbl.c:2993 #, c-format msgid "Unsupported protocol version %1d implemented by '%s'." msgstr "" #. STID_SHARELIB_TGEF_MSG_DO_EXPORT_F #: ../../strtbl.c:2995 #, c-format msgid "%s: TGEF_MSG_DO_EXPORT failed with return code %ld." msgstr "" #. STID_NEG_VAL_IN_EXP_PXL_TRM_ALT #: ../../strtbl.c:2997 #, c-format msgid "" "Error in parsing ExportPixelTrim values: negative values are not allowed.\n" "\n" "[%1d,%1d,%1d,%1d] used." msgstr "" #. STID_EXP_PXL_TRM_VAL_SET_TO #: ../../strtbl.c:2999 #, c-format msgid "ExportPixelTrim values set to [%1d,%1d,%1d,%1d]." msgstr "" #. STID_SPECIFY_TO_TRIM_EXP_PXL_TRM #: ../../strtbl.c:3001 #, c-format msgid "" "Please specify the number of pixels to trim when exporting (or printing) in " "bitmap-type format: [current: %1d,%1d,%1d,%1d]" msgstr "" #. STID_ENTER_4_NUM_CUR_TOO_LARGE #: ../../strtbl.c:3003 msgid "" "Please enter 4 numbers or type <CR> or <ESC> to use the current values (they " "are too large now):" msgstr "" #. STID_ENTER_4_NUM_OR_CR_ESC #: ../../strtbl.c:3005 msgid "Please enter 4 numbers or type <CR> or <ESC> to use the current values:" msgstr "" #. STID_OBSOLETE_XDEF_USE_IGNORED #: ../../strtbl.c:3007 #, c-format msgid "Obsoleted %s.%s used. Ignored." msgstr "" #. STID_WILL_USE_FS_HALFTONE_BMP #: ../../strtbl.c:3009 msgid "" "Will use Floyd-Steinberg half-tone method when exporting an X11 bitmap file." msgstr "" #. STID_WILL_NOT_USE_FS_HALFTONE_BMP #: ../../strtbl.c:3011 msgid "" "Will not use Floyd-Steinberg half-tone method when exporting an X11 bitmap " "file." msgstr "" #. STID_WILL_USE_GIVE_SMPLE_THRESHOLD #: ../../strtbl.c:3013 #, c-format msgid "" "Will use simple thresholding method with a threshold of '%s' when exporting " "an X11 bitmap file." msgstr "" #. STID_WILL_NOT_USE_SIMPLE_THRESHOLD #: ../../strtbl.c:3015 msgid "" "Will not use simple thresholding method when exporting an X11 bitmap file." msgstr "" #. STID_ENTER_BMP_THRESHOLD_CUR_VAL #: ../../strtbl.c:3017 #, c-format msgid "" "Please specify bitmap threshold when exporting an X11 bitmap file (current " "value is '%s')." msgstr "" #. STID_INVALID_THRESHOLD_REMAINS #: ../../strtbl.c:3019 #, c-format msgid "Invalid threshold: '%s' specified. Threshold remains at '%s'." msgstr "" #. STID_USE_GIVEN_AS_BMP_THRESHOLD #: ../../strtbl.c:3021 #, c-format msgid "Will use '%s' as bitmap threshold when exporting an X11 bitmap file." msgstr "" #. STID_XGETIMAGE_MAY_RUN_OUT_VMEM #: ../../strtbl.c:3023 msgid "XGetImage() failed. May have run out of virtual memory." msgstr "" #. STID_NO_X11_BITMAP_OBJ_SELECTED #: ../../strtbl.c:3025 msgid "No X11 Bitmap objects selected." msgstr "" #. STID_CANT_CUT_AN_EPS_OBJECT #: ../../strtbl.c:3027 msgid "Cannot cut an EPS object." msgstr "" #. STID_XBM_CANT_HAVE_0_W_OR_H #: ../../strtbl.c:3029 msgid "Bitmap cannot have 0 width or height." msgstr "" #. STID_BAD_RED_MASK_TRUE_COLOR_DPY #: ../../strtbl.c:3031 #, c-format msgid "" "Unexpected red_mask value of 0x%06lx in the default visual for this " "TrueColor display. Proceed pretending that the display is not TrueColor. " "Please set %s.%s to FALSE to avoid this error message in the future." msgstr "" #. STID_BAD_GREEN_MASK_TRUE_COLOR_DPY #: ../../strtbl.c:3033 #, c-format msgid "" "Unexpected green_mask value of 0x%06lx in the default visual for this " "TrueColor display. Proceed pretending that the display is not TrueColor. " "Please set %s.%s to FALSE to avoid this error message in the future." msgstr "" #. STID_BAD_BLUE_MASK_TRUE_COLOR_DPY #: ../../strtbl.c:3035 #, c-format msgid "" "Unexpected blue_mask value of 0x%06lx in the default visual for this " "TrueColor display. Proceed pretending that the display is not TrueColor. " "Please set %s.%s to FALSE to avoid this error message in the future." msgstr "" #. STID_NETPBM_PROGS_VISIT_HOME_PAGE #: ../../strtbl.c:3037 #, c-format msgid "" "(These programs are part of the netpbm package. Please visit %s's home page " "at <URL:%s> regarding where to obtain netpbm.)" msgstr "" #. STID_NETPBM_PNMTOPNG_VST_HOME_PAGE #: ../../strtbl.c:3039 #, c-format msgid "" "(These programs are part of the netpbm and pnmtopng packages. Please visit %" "s's home page at <URL:%s> regarding where to obtain netpbm and pnmtopng.)" msgstr "" #. STID_FNAME_FORMAT_ERROR_IN_FUNC #: ../../strtbl.c:3041 #, c-format msgid "File name format error in %s." msgstr "" #. STID_NAMED_IMAGEMAP_FILE_GEN #: ../../strtbl.c:3043 #, c-format msgid "Imagemap file '%s' generated." msgstr "" #. STID_CANT_FND_FATTR_IMGMAP_NOT_GEN #: ../../strtbl.c:3045 #, c-format msgid "" "Cannot find a '%s' file attribute.\n" "\n" "Imagemap not generated." msgstr "" #. STID_CANT_FND_FATTR_NO_IMGMAP_GIF #: ../../strtbl.c:3047 #, c-format msgid "" "Cannot find a '%s' file attribute.\n" "\n" "Imagemap not generated. Only a GIF file is generated." msgstr "" #. STID_NAMED_HTML_FILE_GEN #: ../../strtbl.c:3049 #, c-format msgid "HTML file '%s' generated." msgstr "" #. STID_LARGE_EXP_PXL_TRM_WH_0_USED #: ../../strtbl.c:3051 #, c-format msgid "" "The ExportPixelTrim values of [%1d,%1d,%1d,%1d] are too large for the image (" "%1dx%1d). Zeroes are used." msgstr "" #. STID_APPLY_EXP_PXL_TRM_VALS #: ../../strtbl.c:3053 #, c-format msgid "Applying ExportPixelTrim of [%1d,%1d,%1d,%1d]..." msgstr "" #. STID_TOO_MANY_COLORS_LIMIT_IS #: ../../strtbl.c:3055 #, c-format msgid "Too many colors: %1d (limit is %1d) in the image." msgstr "" #. STID_UNRECOG_GIVEN_PIXEL_VAL_PRINT #: ../../strtbl.c:3057 #, c-format msgid "" "Unrecognized pixel value at (%1d,%1d): %1d (0x%08lx).\n" "\n" "Printing/exporting aborted." msgstr "" #. STID_UNRECOG_GIVEN_PIXEL_VAL_1_USE #: ../../strtbl.c:3059 #, c-format msgid "" "Unrecognized pixel value: %1d (0x%08lx).\n" "\n" "1 used." msgstr "" #. STID_FORMAT_FILE_WH_PRINTED_INTO #: ../../strtbl.c:3061 #, c-format msgid "%s file [%1dx%1d] printed into '%s'." msgstr "" #. STID_SEL_XPM_DECK_TO_EXPORT #: ../../strtbl.c:3063 msgid "Please select a deck of X Pixmap object to export." msgstr "" #. STID_MANY_SZ_FAIL_XPM_DESK_EXPORT #: ../../strtbl.c:3065 #, c-format msgid "" "Not all X Pixmap objects in the deck are of size. Expecting %1dx%1d.\n" "\n" "Export aborted." msgstr "" #. STID_INVALID_CH_PER_PIX_IN_FUNC #: ../../strtbl.c:3067 #, c-format msgid "Invalid chars_per_pixel (%1d) in %s." msgstr "" #. STID_XPM_CANT_HAVE_0_W_OR_H #: ../../strtbl.c:3069 msgid "Pixmap cannot have 0 width or height." msgstr "" #. STID_WARN_XPM_ALL_NON_BG_BE_BLACK #: ../../strtbl.c:3071 msgid "" "Warning (xpm object): all non-background color will be treated as black." msgstr "" #. STID_SAVED_FILE_MAY_BE_CORRUPTED #: ../../strtbl.c:3073 msgid "Saved file may be corrupted." msgstr "" #. STID_CANT_SAVE_XPM_ON_BW_DPY #: ../../strtbl.c:3075 msgid "Cannot save X11 Pixmap objects on a Black & White display." msgstr "" #. STID_CANT_IMPORT_GIVEN_FORMAT_XPM #: ../../strtbl.c:3077 #, c-format msgid "Does not know how to import an X11 Pixmap file with format: '%1d'." msgstr "" #. STID_CANT_IMPORT_GIVEN_CPP_XPM #: ../../strtbl.c:3079 #, c-format msgid "" "Does not know how to import an X11 Pixmap file with chars_per_pixel: '%1d'." msgstr "" #. STID_EDIT_UNNAME_ATTR_DOTS #: ../../strtbl.c:3081 #, fuzzy msgid "Edit an unnamed attribute..." msgstr "„Ő„Ą„€„ë°À­€òÊÔœž" #. STID_EDIT_VAL_OF_ATTR_DOTS #: ../../strtbl.c:3083 #, fuzzy, c-format msgid "Edit the value for the '%s' attribute..." msgstr "„Ő„Ą„€„ë°À­€òÊÔœž" #. STID_EDIT_UNNAME_ATTR_WITH_CMD #: ../../strtbl.c:3085 #, c-format msgid "Editing an unnamed attribute with '%s'..." msgstr "" #. STID_EDIT_VAL_OF_ATTR_WITH_CMD #: ../../strtbl.c:3087 #, c-format msgid "Editing the value for the '%s' attribute with '%s'..." msgstr "" #. STID_STAT_FAIL_EDIT_ATTR_VAL_SAME #: ../../strtbl.c:3089 #, c-format msgid "" "Fail to get file info for '%s' while editing an attribute. Attribute value " "is unchanged." msgstr "" #. STID_ENTER_HTML_TEMPLATE #: ../../strtbl.c:3091 #, fuzzy msgid "" "Please specify a file to be used as a template for generating HTML files:" msgstr "HTML„Ő„Ą„€„ë€òșîÀź€č€ë»ț€Î„Æ„ó„Ś„ìĄŒ„ÈĄŠ„Ő„Ą„€„ëÆÉčț€ß" #. STID_ENTER_HTML_TEMPLATE_CUR_IS #: ../../strtbl.c:3093 #, fuzzy, c-format msgid "" "Please specify a file to be used as a template for generating HTML files (" "current template is '%s'):" msgstr "HTML„Ő„Ą„€„ë€òșîÀź€č€ë»ț€Î„Æ„ó„Ś„ìĄŒ„ÈĄŠ„Ő„Ą„€„ëÆÉčț€ß" #. STID_HTML_TEMPLATE_UNCHANGED #: ../../strtbl.c:3095 #, fuzzy msgid "HTML export template file unchanged." msgstr "HTML„Æ„ó„Ś„ìĄŒ„ÈÆÉčț€ß" #. STID_HTML_TEMPLATE_SET_TO_GIVEN #: ../../strtbl.c:3097 #, c-format msgid "HTML export template file set to '%s'." msgstr "" #. STID_NO_HTML_TEMPLATE_FILE #: ../../strtbl.c:3099 #, fuzzy msgid "Will not use an HTML export template file." msgstr "HTML„Æ„ó„Ś„ìĄŒ„ÈÆÉčț€ß" #. STID_Q_FILE_NOT_EXIST_USE_ANYWAY #: ../../strtbl.c:3101 #, c-format msgid "" "File '%s' does not exist.\n" "\n" "Would you like to use it anyway?" msgstr "" #. STID_CANNOT_OPEN_HTML_TMPL_READ #: ../../strtbl.c:3103 #, c-format msgid "Cannot open HTML export template file '%s' for reading." msgstr "" #. STID_OK_TO_FULL_SCREEN_CAPTURE_YNC #: ../../strtbl.c:3105 msgid "Okay to proceed with full screen capture? [ync](y)" msgstr "" #. STID_Q_FILE_UNSAVABLE_SAVE_NEW_YNC #: ../../strtbl.c:3107 msgid "" "File is marked unsavable.\n" "\n" "Would you like to save to a new file name? [ync](y)" msgstr "" #. STID_WONT_CONDENSE_READHEXSTRING #: ../../strtbl.c:3109 msgid "Will not condense exported PS/EPS file due to 'readhexstring'." msgstr "" #. STID_CMD_ONLY_AVAIL_IN_VERTEX_MODE #: ../../strtbl.c:3111 msgid "This command is only available in vertex mode." msgstr "" #. STID_CANNOT_MERGE_WITH_TILED_PAGE #: ../../strtbl.c:3113 #, c-format msgid "" "Does not know how to merge files with '%s' because it is in TILED page mode. " " Merge aborted." msgstr "" #. STID_SPECIFY_PAGES_TO_PRINT_EX #: ../../strtbl.c:3115 msgid "Please specify pages to print: (e.g., 2,3,7-9,10 or '*' for all pages)" msgstr "" #. STID_CANT_PRINT_PAGES_IN_TILED #: ../../strtbl.c:3117 msgid "Cannot print pages in TILED page mode." msgstr "" #. STID_CANT_PRINT_PAGES_IN_FORMAT #: ../../strtbl.c:3119 #, c-format msgid "Cannot print pages in the '%s' format." msgstr "'%s' „Ő„©ĄŒ„Ț„Ă„È€Ç„ÚĄŒ„ž€ò°őșț€Ç€­€Ț€»€ó." #. STID_PRECISE_SCALE_EV_CAUSE_FLUSH #: ../../strtbl.c:3121 msgid "Precise Scale Everything will cause the undo buffer to be flushed." msgstr "" #. STID_GO_HYPERSPACE_IN_SLIDE #: ../../strtbl.c:3123 #, fuzzy msgid "HyperSpace mode will be entered upon entering slideshow mode." msgstr "„č„é„€„É„·„çĄŒĄŠ„âĄŒ„ɀDް„ê„ÄɀòÉœŒš€·€Ț€č." #. STID_DONT_GO_HYPERSPACE_IN_SLIDE #: ../../strtbl.c:3125 #, fuzzy msgid "Freehand drawing mode will be entered upon entering slideshow mode." msgstr "„č„é„€„É„·„çĄŒĄŠ„âĄŒ„ɀDް„ê„ÄɀòÉœŒš€·€Ț€č." #. STID_MOVE_EDIT_TEXT_BOX_ABORTED #: ../../strtbl.c:3127 msgid "Move edit text box aborted." msgstr "" #. STID_DRAG_MOUSE_MOVE_EDITTEXT_DOTS #: ../../strtbl.c:3129 msgid "Drag the edit text box to move it around..." msgstr "" #. STID_EXCEED_BUF_SIZE_LIMIT_IN_WB #: ../../strtbl.c:3131 #, c-format msgid "" "Error: There's a buffer size limitation of %1d bytes in the current " "implementation of the whiteboard. The buffer size requirement (%1d bytes) " "for the operation you just performed has exceeded this limit.\n" "\n" "In order to keep the whiteboard running, the operation in question is " "canceled." msgstr "" #. STID_CANT_REPLACE_GRAPHIC_NOT_TGIF #: ../../strtbl.c:3133 #, c-format msgid "" "Cannot replace graphical objects because cut buffer does not contain %s " "objects." msgstr "" #. STID_CANT_REPLACE_GRAPHIC_TOO_MANY #: ../../strtbl.c:3135 msgid "" "Cannot replace graphical objects because cut buffer contain more than one " "objects." msgstr "" #. STID_REPLACE_GRAPHIC_ICON_TO_GROUP #: ../../strtbl.c:3137 msgid "" "Some iconic objects have been converted to grouped objects during Replace " "Graphic." msgstr "" #. STID_REPLACE_GRAPHIC_DONE #: ../../strtbl.c:3139 msgid "Graphical part of selected objects have been replaced and updated." msgstr "" #. STID_TOO_MANY_ICON_REPLACE_GRAPHIC #: ../../strtbl.c:3141 #, fuzzy msgid "More than one iconic objects are selected for Replace Graphic." msgstr "„Æ„­„č„Ȁǀʀ€„Ș„Ö„ž„§„Ż„È€òŸŻ€Ê€Ż€È€â°ì€ÄÁȘÂò€·€Ê€±€ì€Đ€Ê€ê€Ț€»€ó" #. STID_Q_CVT_ICON_TO_GRP_IN_REPLACE #: ../../strtbl.c:3143 msgid "" "Replacing the graphic of an iconic object...\n" "\n" "Would you like to convert the object into a grouped object? [ync](y)\n" "\n" "(If you press the No button, you will be prompted with the name of a new " "symbol file the iconic object. If you press Cancel, this object will be " "skipped for Replace Graphic.)" msgstr "" #. STID_SHOW_MEASUREMENT_IN_TT_ENAB #: ../../strtbl.c:3145 #, fuzzy msgid "Showing measurement in tooltip enabled." msgstr "ÊȘș耷€òÉœŒš€·€Ț€č" #. STID_SHOW_MEASUREMENT_IN_TT_DISB #: ../../strtbl.c:3147 msgid "" "Showing measurement in tooltip disabled. Measurement will be shown in the " "ruler window." msgstr "" #. STID_SEL_JPEG_FILE_TO_IMPORT #: ../../strtbl.c:3149 msgid "Please select a JPEG file to IMPORT..." msgstr "ÁȚÆț€č€ë JPEG „Ő„Ą„€„ë€òÁȘÂò€·€Æ€Ż€À€”€€." #. STID_CANNOT_IMPORT_GIVEN_JPEG #: ../../strtbl.c:3151 #, c-format msgid "Cannot import JPEG file '%s'." msgstr "JPEG„Ő„Ą„€„ë '%s' €òÁȚÆț€Ç€­€Ț€»€ó." #. STID_GIVEN_JPEG_SIZE_FILE_IMPORTED #: ../../strtbl.c:3153 #, c-format msgid "JPEG file (%1dx%1d) '%s' imported." msgstr "JPEG„Ő„Ą„€„ë (%1dx%1d) '%s' €ŹÁȚÆț€”€ì€Ț€·€ż." #. STID_WILL_EXPORT_JPEG_FILE #: ../../strtbl.c:3155 msgid "Will export JPEG (needs xpm->jpg filter) file." msgstr "JPEG „Ő„Ą„€„ë (xpm-jpg€Î„Ő„Ł„ë„ż€ŹÉŹÍŚ)€òœĐÎÏ€·€Ț€č" #. STID_NETPBM_JPEG_VST_HOME_PAGE #: ../../strtbl.c:3157 #, c-format msgid "" "(These programs are part of the netpbm and jpeg packages. Please visit %s's " "home page at <URL:%s> regarding where to obtain netpbm and jpeg.)" msgstr "" #. STID_CANT_GEN_PREVIEW_FOR_PS #: ../../strtbl.c:3159 #, fuzzy, c-format msgid "Cannot auto-generate a preview bitmap for '%s'." msgstr "X11 bitmap „Ő„Ą„€„ë '%s'€òÁȚÆț€Ç€­€Ț€»€ó" #. STID_CANT_GEN_PREVIEW_FOR_EMPTY_PS #: ../../strtbl.c:3161 #, c-format msgid "" "The auto-generate preview bitmap for '%s' is empty. Auto-generation skipped." msgstr "" #. STID_WILL_AUTO_GEN_PREVIEW_BITMAP #: ../../strtbl.c:3163 msgid "" "Will auto-generate a preview bitmap when importing/embedding a PS/EPS file." msgstr "" #. STID_WONT_AUTO_GEN_PREVIEW_BITMAP #: ../../strtbl.c:3165 msgid "" "Will not auto-generate a preview bitmap when importing/embedding a PS/EPS " "file." msgstr "" #. STID_TMP_DIR_NOT_EXIST_USE_XDEF #: ../../strtbl.c:3167 #, c-format msgid "" "Temporary directory '%s' does not exist. Please fix the %s.%s X default." msgstr "" #. STID_INVALID_DIR_IN_X_DEFAULT #: ../../strtbl.c:3169 #, c-format msgid "Invalid directory '%s' specified by X default %s.%s." msgstr "" #. STID_RACE_IN_CREATE_TMP_FILE #: ../../strtbl.c:3171 #, c-format msgid "" "Race condition detected in creating the '%s' temporary file. Possible " "causes are network problems, security problems, etc. This file will be " "removed before proceeding." msgstr "" #. STID_INVALID_GEOM_USE_ALT_GEOM #: ../../strtbl.c:3173 #, c-format msgid "" "Invalid %s.%s: '%s', the geometry must be at least '%s', '%s' is used " "instead." msgstr "" #. STID_REDUCE_BY_FACTOR #: ../../strtbl.c:3175 #, c-format msgid "Reducing by a factor of %.2f..." msgstr "" #. STID_ENLARGE_BY_FACTOR #: ../../strtbl.c:3177 #, c-format msgid "Enlarging by a factor of %.2f..." msgstr "" #. STID_CREATE_THUMBNAIL_CAUSE_FLUSH #: ../../strtbl.c:3179 msgid "Create Thumbnails will cause the undo buffer to be flushed." msgstr "" #. STID_CONNECT_PORTS_CANCEL_BY_USER #: ../../strtbl.c:3181 msgid "Connect ports canceled by the user." msgstr "" #. STID_Q_CNFLCT_SIG_NAME_OKAY_TO_CLR #: ../../strtbl.c:3183 #, c-format msgid "" "Conflicting signal names '%s' (at '%s') and '%s' (at '%s').\n" "\n" "Okay to clear both signal names? [ync](y)" msgstr "" #. STID_PLS_ENT_SIG_NAME #: ../../strtbl.c:3185 #, fuzzy msgid "Please enter a signal name:" msgstr "ż·€·€€„Ő„Ą„€„ëÌŸ€òÆțÎÏ€·€Æ€Ż€À€”€€:" #. STID_SIGNAL_NAMES_CLEARED #: ../../strtbl.c:3187 #, c-format msgid "Signal names at '%s' and '%s' have been cleared." msgstr "" #. STID_PLACING_NAMED_SIGNAL #: ../../strtbl.c:3189 #, c-format msgid "Click to place signal name '%s'" msgstr "" #. STID_PLS_ENT_SIG_NAME_FOR_PORT #: ../../strtbl.c:3191 #, fuzzy, c-format msgid "Please enter a signal name for the '%s' port:" msgstr "„ą„€„ł„ó€ÎÌŸÁ°€òÆțÎÏ€·€Æ€Ż€À€”€€:" #. STID_NO_CUR_FILE_CANNOT_GEN_NETLST #: ../../strtbl.c:3197 msgid "" "No current file.\n" "\n" "Cannot generate a net list." msgstr "" #. STID_NO_SIGNAME_FOUND_EMPTY_NETLST #: ../../strtbl.c:3199 msgid "" "No signal name found.\n" "\n" "Net list not generated." msgstr "" #. STID_WILL_EXPORT_NETLIST_FILE #: ../../strtbl.c:3201 #, fuzzy msgid "Will export net-list file." msgstr "„Ő„Ą„€„ë %s €òœĐÎÏ€·€Ț€č" #. STID_Q_OK_TO_CUT_INTO_SEGMENTS #: ../../strtbl.c:3203 msgid "" "Okay to cut selected polyline/polygon objects into segments? [ync](y)\n" "\n" "(If you would like to cut at a specific vertex of the polyline/polygon, " "please use the vertex mode.)" msgstr "" #. STID_NO_POLY_OBJ_SELECTED #: ../../strtbl.c:3205 #, fuzzy msgid "No polyline/polygon object selected." msgstr "ÊäŽÖ€”€ì€ż„脌„é„€„ó" #. STID_WILL_SHOW_WIRE_SIGNAL_NAME #: ../../strtbl.c:3207 msgid "Will show (and place) wire signal name when connecting ports." msgstr "" #. STID_WILL_HIDE_WIRE_SIGNAL_NAME #: ../../strtbl.c:3209 msgid "Will hide wire signal name when connecting ports." msgstr "" #. STID_TRY_AGAIN_AND_CLICK_IN_A_PORT #: ../../strtbl.c:3211 msgid "Please try again and click in a port." msgstr "" #. STID_TRY_AGAIN_AND_END_IN_A_PORT #: ../../strtbl.c:3213 msgid "The last vertex did not end in a port, please try again." msgstr "" #. STID_CANNOT_CREATE_ARC_WITH_RAD1 #: ../../strtbl.c:3215 #, c-format msgid "%s cannot create an arc with radius %1d (must be at least 1)." msgstr "" #. STID_SEL_ONE_NONE_PORT_PLUS_COMP #: ../../strtbl.c:3217 #, fuzzy msgid "Please select at least one port object and a composite object." msgstr "ŸŻ€Ê€Ż€È€â2€Ä€Î„Ș„Ö„ž„§„Ż„È€òÁȘÂò€·€Æ€Ż€À€”€€" #. STID_PORT_OBJ_HAS_EMPTY_NAME #: ../../strtbl.c:3219 #, fuzzy msgid "The port object has an empty name." msgstr "„Æ„­„č„È€òłÈÂçœÌŸźČĀˀ·€Ț€·€ż" #. STID_CANNOT_FIND_INIT_ATTR_PORT_PA #: ../../strtbl.c:3221 #, fuzzy, c-format msgid "" "Cannot find the 'Initialization=' attribute of the '%s' object (parent of " "the port object)." msgstr "ÁȘÂòÂĐŸĘ€Î°À­ '%s' €Źž«ÉŐ€«€ê€Ț€»€ó" #. STID_CANNOT_FIND_VAR_IN_INIT_ATTR #: ../../strtbl.c:3223 #, c-format msgid "" "Cannot find the '%s' variable in the 'Initialization=' attribute of the '%s' " "object (parent of the port object)." msgstr "" #. STID_RENUMBER_OBJ_IDS_CAUSE_FLUSH #: ../../strtbl.c:3225 msgid "Renumber Object IDs will cause the undo buffer to be flushed." msgstr "" #. STID_RENUMBER_OBJ_IDS_DONE #: ../../strtbl.c:3227 msgid "Renumbering object IDs done." msgstr "" #. STID_RENUMBER_OBJ_IDS_IN_WB #: ../../strtbl.c:3229 msgid "RenumberObjectIDs() is disabled in WhiteBoard mode." msgstr "" #. STID_SEL_ONE_NONE_PORT_PLUS_BRDCST #: ../../strtbl.c:3231 #, fuzzy msgid "Please select at least one port object and a broadcast wire object." msgstr "ŸŻ€Ê€Ż€È€â2€Ä€Î„Ș„Ö„ž„§„Ż„È€òÁȘÂò€·€Æ€Ż€À€”€€" #. STID_CONFLICT_SIG_NAME_ENT_NEW #: ../../strtbl.c:3233 msgid "" "Conflicting signal names detected. Please entry a valid signal name for all " "the ports:" msgstr "" #. STID_BAD_SIG_NAME_UNDO_AND_REDO #: ../../strtbl.c:3235 msgid "" "Invalid or inconsistent signal names are given to the ports. Please undo " "the previous operation and redo it again." msgstr "" #. STID_WILL_USE_WORDWRAP_IMPORT_TEXT #: ../../strtbl.c:3237 msgid "Will use word wrap when importing a multipage text file." msgstr "" #. STID_NO_WORDWRAP_IMPORT_TEXT #: ../../strtbl.c:3239 #, fuzzy msgid "Will not use word wrap when importing a multipage text file." msgstr "HTML„Æ„ó„Ś„ìĄŒ„ÈÆÉčț€ß" #. STID_CUR_MARGINS_ARE_GIVEN #: ../../strtbl.c:3241 #, c-format msgid "( current margins (top, bottom, left, right) are: %s )" msgstr "" #. STID_ENTER_MARGINS #: ../../strtbl.c:3243 #, c-format msgid "" "Please enter margins to be used when importing a multipage text file: [top," "bottom,left,right] (e.g., %s -- the three commas are mandatory)" msgstr "" #. STID_NEW_MARGINS_ARE_GIVEN #: ../../strtbl.c:3245 msgid "" "New margins for import multipage text file are (top, bottom, left, right):" msgstr "" #. STID_CANT_OBTAIN_TMP_FILE_NAME #: ../../strtbl.c:3247 #, c-format msgid "" "Cannot obtain a temporary file name using mkstemp() from the following " "request: '%s'. Will use mktemp() instead." msgstr "" #. STID_NO_OBJ_SPEC_WHILE_EXEC_CMD #: ../../strtbl.c:3249 #, c-format msgid "Non object specified while executing the '%s' command." msgstr "" #. STID_UNRECOG_GIVEN_TRPIX_VAL_PRINT #: ../../strtbl.c:3251 #, c-format msgid "" "Unrecognized transparent pixel value at (%1d,%1d): %1d (0x%08lx).\n" "\n" "Printing/exporting aborted." msgstr "" #. STID_TGIF_DISTRUBITION #: ../../strtbl.c:3253 #, c-format msgid " [distribution: %s]" msgstr "" #. STID_WRITE_TO_SELF_PIPE_FAIL #: ../../strtbl.c:3255 #, c-format msgid "Fail to write to the pipe that talks to %s itself." msgstr "" #. STID_CREATE_SELF_PIPE_FAIL #: ../../strtbl.c:3257 #, fuzzy, c-format msgid "Fail to create the pipe that talks to %s itself." msgstr "„Єلó„ɄР%s €ÎșîÀźŒșÇÔ" #. STID_READ_FROM_SELF_PIPE_FAIL #: ../../strtbl.c:3259 #, c-format msgid "Fail to read %1d byte from the pipe that talks to %s itself." msgstr "" #. STID_ENTER_BEZIER_NUM_SEGS_CUR_IS #: ../../strtbl.c:3261 #, fuzzy, c-format msgid "" "Please enter the number of segments for the Convert To Bezier command (" "current value is %1d):" msgstr "Êž»ú€òČóĆŸ€č€ë»ț€ÎÂ瀭€”€ò»ŰÄê..." #. STID_BEZIER_NUM_SEGS_SET_TO_INT #: ../../strtbl.c:3263 #, c-format msgid "Number of segments for the Convert To Bezier command set to %1d." msgstr "" #. STID_ENT_VAL_RANGE_ENTER_GE_INT #: ../../strtbl.c:3265 #, c-format msgid "" "The value entered: '%s' is out of range.\n" "\n" "Please enter a value >= %1d." msgstr "" #. STID_ENTER_TICK_MARK_SIZE_CUR_IS #: ../../strtbl.c:3267 #, fuzzy, c-format msgid "" "Please enter the tick mark size for the various Add Tick Mark commands (" "current value is %1d):" msgstr "ÉÁČèÊž»ú€ÎČóĆŸłŃĆÙ€òÀßÄê" #. STID_TICK_MARK_SIZE_SET_TO_INT #: ../../strtbl.c:3269 #, c-format msgid "Tick mark size set to %1d." msgstr "" #. STID_NO_SPLINE_SELECTED #: ../../strtbl.c:3271 #, fuzzy msgid "No (non-interpolated) spline objects selected." msgstr "ÊäŽÖ€”€ì€ż„脌„é„€„ó€Î„Ș„Ö„ž„§„Ż„È€ŹÁȘÂò€”€ì€Æ€Ț€»€ó." #. STID_SPLINE_CONVERTED_TO_BEZIER #: ../../strtbl.c:3273 msgid "Spline objects converted to Bezier curves." msgstr "" #. STID_PEEK_DIM_LEFT #: ../../strtbl.c:3275 #, fuzzy msgid "The x-coordinate of the left most part of the selected object." msgstr "ÁȘÂòÂĐŸĘ€«€éžœș߀ΰÀ­ '%s' €òŒèÆÀ" #. STID_PEEK_DIM_TOP #: ../../strtbl.c:3277 #, fuzzy msgid "The y-coordinate of the top most part of the selected object." msgstr "ÁȘÂòÂĐŸĘ€«€éžœș߀ΰÀ­ '%s' €òŒèÆÀ" #. STID_PEEK_DIM_RIGHT #: ../../strtbl.c:3279 #, fuzzy msgid "The x-coordinate of the right most part of the selected object." msgstr "ÁȘÂòÂĐŸĘ€«€éžœș߀ΰÀ­ '%s' €òŒèÆÀ" #. STID_PEEK_DIM_BOTTOM #: ../../strtbl.c:3281 #, fuzzy msgid "The y-coordinate of the bottom most part of the selected object." msgstr "ÁȘÂòÂĐŸĘ€«€éžœș߀ΰÀ­ '%s' €òŒèÆÀ" #. STID_PEEK_DIM_WIDTH #: ../../strtbl.c:3283 #, fuzzy msgid "The width of the selected object." msgstr "ÁȘÂò€·€ż„Ș„Ö„ž„§„Ż„È€ÎÊž»ú„”„€„ș€òÊŃčč€č€ë" #. STID_PEEK_DIM_HEIGHT #: ../../strtbl.c:3285 #, fuzzy msgid "The height of the selected object." msgstr "ÁȘÂòÂĐŸĘ€Îșïœü" #. STID_PEEK_DIM_CX #: ../../strtbl.c:3287 #, fuzzy msgid "The x-coordinate of the center of the selected object." msgstr "ÁȘÂòÂĐŸĘ€ÎĂæżŽ€òżćÊż€Ë€œ€í€š€ë" #. STID_PEEK_DIM_CY #: ../../strtbl.c:3289 #, fuzzy msgid "The y-coordinate of the center of the selected object." msgstr "ÁȘÂòÂĐŸĘ€ÎĂæżŽ€òżćÊż€Ë€œ€í€š€ë" #. STID_NO_POLY_ETC_SELECTED #: ../../strtbl.c:3291 #, fuzzy msgid "No polyline/polygon/spline objects selected." msgstr "ÊäŽÖ€”€ì€ż„脌„é„€„ó" #: ../../strtbl.c:3338 #, fuzzy msgid "Distribute selected objects so that their top edges are equally spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3339 #, fuzzy msgid "" "Distribute selected objects so that their vertical centers are equally spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3340 #, fuzzy msgid "" "Distribute selected objects so that their bottom edges are equally spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3341 #, fuzzy msgid "Distribute selected objects so that they are equally spaced vertically" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3342 #, fuzzy msgid "Distribute selected objects so that their left edges are equally spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3343 #, fuzzy msgid "" "Distribute selected objects so that their left and top edges are equally " "spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3344 #, fuzzy msgid "" "Distribute selected objects so that their left and vertical centers are " "equally spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3345 #, fuzzy msgid "" "Distribute selected objects so that their left and bottom edges are equally " "spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3346 msgid "" "Distribute selected objects so that they are equally spaced vertically and " "their left edges are spaced equally" msgstr "" #: ../../strtbl.c:3347 #, fuzzy msgid "" "Distribute selected objects so that their horizontal centers are equally " "spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3348 msgid "" "Distribute selected objects so that their horizontal centers and top edges " "are equally spaced" msgstr "" #: ../../strtbl.c:3349 msgid "" "Distribute selected objects so that their horizontal and vertical centers " "are equally spaced" msgstr "" #: ../../strtbl.c:3350 msgid "" "Distribute selected objects so that their horizontal centers and bottom " "edges are equally spaced" msgstr "" #: ../../strtbl.c:3351 msgid "" "Distribute selected objects so that they are equally spaced vertically and " "their horizontal centers are spaced equally" msgstr "" #: ../../strtbl.c:3352 #, fuzzy msgid "" "Distribute selected objects so that their right edges are equally spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3353 #, fuzzy msgid "" "Distribute selected objects so that their right and top edges are equally " "spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3354 #, fuzzy msgid "" "Distribute selected objects so that their right and vertical centers are " "equally spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3355 #, fuzzy msgid "" "Distribute selected objects so that their right and bottom edges are equally " "spaced" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3356 msgid "" "Distribute selected objects so that they are equally spaced vertically and " "their right edges are spaced equally" msgstr "" #: ../../strtbl.c:3357 #, fuzzy msgid "" "Distribute selected objects so that they are equally spaced horizontally" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3358 msgid "" "Distribute selected objects so that they are equally spaced horizontally and " "their top edges are spaced equally" msgstr "" #: ../../strtbl.c:3359 msgid "" "Distribute selected objects so that they are equally spaced horizontally and " "their vertical centers are spaced equally" msgstr "" #: ../../strtbl.c:3360 msgid "" "Distribute selected objects so that they are equally spaced horizontally and " "their bottom edges are spaced equally" msgstr "" #: ../../strtbl.c:3361 #, fuzzy msgid "" "Distribute selected objects so that they are equally spaced horizontally and " "vertically" msgstr "žœș߀ÎÀßÄê€ËŽđ€Ć€­ĄąÁȘÂòÂĐŸĘ€ÎŽÖłÖÄŽÀ°" #: ../../strtbl.c:3377 ../../strtbl.c:3397 msgid "top sides are aligned." msgstr "ŸćÊŐ€ò€œ€í€š€ÆÀ°Îó" #: ../../strtbl.c:3378 ../../strtbl.c:3398 msgid "vertical centers are aligned." msgstr "żâÄŸÊęžț€ÎĂæżŽ€ò€œ€í€š€ÆÀ°Îó" #: ../../strtbl.c:3379 ../../strtbl.c:3399 msgid "bottom sides are aligned." msgstr "ÄìÊŐ€ò€œ€í€š€ÆÀ°Îó" #: ../../strtbl.c:3381 ../../strtbl.c:3385 msgid "left sides are aligned." msgstr "șžÊŐ€ò€œ€í€š€ÆÀ°Îó" #: ../../strtbl.c:3382 msgid "left and top sides are aligned." msgstr "șžŸć€ò€œ€í€š€ÆÀ°Îó" #: ../../strtbl.c:3383 #, fuzzy msgid "left side and middle are aligned." msgstr "ĂæżŽ€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó" #: ../../strtbl.c:3384 msgid "left and bottom sides are aligned." msgstr "" #: ../../strtbl.c:3386 ../../strtbl.c:3390 #, fuzzy msgid "horizontal centers are aligned." msgstr "ĂæżŽ€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó" #: ../../strtbl.c:3387 msgid "centers and top sides are aligned." msgstr "" #: ../../strtbl.c:3388 #, fuzzy msgid "centers and middle are aligned." msgstr "ĂæżŽ€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó" #: ../../strtbl.c:3389 msgid "centers and bottom sides are aligned." msgstr "" #: ../../strtbl.c:3391 ../../strtbl.c:3395 msgid "right sides are aligned." msgstr "" #: ../../strtbl.c:3392 msgid "right and top sides are aligned." msgstr "" #: ../../strtbl.c:3393 msgid "right and middle are aligned." msgstr "" #: ../../strtbl.c:3394 msgid "right and bottom sides are aligned." msgstr "±ŠĂŒ€ÈÄìÌÌ€òÀ°Îó" #: ../../strtbl.c:3409 msgid "Horizontal alignment set to NONE." msgstr "żćÊżÊęžț€ÎÀ°Îó€Ï€Ê€·" #: ../../strtbl.c:3410 msgid "Will align on the LEFT." msgstr "șžĂŒ€ò€œ€í€š€ÆÀ°Îó€·€Ț€č" #: ../../strtbl.c:3411 msgid "Will align objects at the horizontal CENTER." msgstr "ĂæżŽ€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó€·€Ț€č" #: ../../strtbl.c:3412 msgid "Will align on the RIGHT." msgstr "±ŠĂŒ€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó€·€Ț€č" #: ../../strtbl.c:3413 msgid "Will equally SPACE objects horizontally." msgstr "żćÊżÊęžț€ËĆùŽÖłÖ€ÇÀ°Îó€·€Ț€č" #: ../../strtbl.c:3422 msgid "Vertical alignment set to NONE." msgstr "żâÄŸÊęžț€ÎÀ°Îó€Ï€Ê€·" #: ../../strtbl.c:3423 msgid "Will align at the TOP." msgstr "ŸćĂŒ€ò€œ€í€š€ÆÀ°Îó€·€Ț€č" #: ../../strtbl.c:3424 msgid "Will align objects in the MIDDLE vertically." msgstr "ĂæżŽ€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó€·€Ț€č" #: ../../strtbl.c:3425 msgid "Will align at the BOTTOM." msgstr "Äì€ò€œ€í€š€ÆżćÊżÊęžț€ËÀ°Îó€·€Ț€č" #: ../../strtbl.c:3426 msgid "Will equally SPACE objects vertically." msgstr "żâÄŸÊęžț€ËĆùŽÖłÖ€ÇÀ°Îó€·€Ț€č" #: ../../strtbl.c:3433 msgid "Align top edges of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎŸćÉô€ò€œ€í€š€ë" #: ../../strtbl.c:3435 msgid "Align bottom edges of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎÄìÉô€ò€œ€í€š€ë" #: ../../strtbl.c:3436 msgid "Align left edges of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎșžĂŒ€ò€œ€í€š€ë" #: ../../strtbl.c:3437 msgid "Align left and top edges of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎșžŸć€ò€œ€í€š€ë" #: ../../strtbl.c:3438 msgid "Align left edges and vertical centers of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎșžĂŒ€ÈżâÄŸÊęžț€ÎĂæżŽ€ò€œ€í€š€ë" #: ../../strtbl.c:3439 msgid "Align left and bottom edges of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎșžČŒ€ò€œ€í€š€ë" #: ../../strtbl.c:3441 msgid "Align horizontal centers and top edges of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎŸćĂŒ€ÈżćÊżÊęžț€ÎĂæżŽ€ò€œ€í€š€ë" #: ../../strtbl.c:3442 msgid "Align horizontal and vertical centers of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎżâÄŸÊęžț€Ș€è€ÓżćÊżÊęžț€ÎĂæżŽ€ò€œ€í€š€ë" #: ../../strtbl.c:3443 msgid "Align horizontal centers and bottom edges of selected objects" msgstr "ÁȘÂòÂĐŸĘ€ÎÄìÉô€ÈżćÊżÊęžț€ÎĂæżŽ€ò€œ€í€š€ë" #: ../../strtbl.c:3444 msgid "Align right edges of selected objects" msgstr "ÁȘÂòÂĐŸĘ€Î±ŠĂŒ€ò€œ€í€š€ë" #: ../../strtbl.c:3445 msgid "Align right and top edges of selected objects" msgstr "ÁȘÂòÂĐŸĘ€Î±ŠŸć€ò€œ€í€š€ë" #: ../../strtbl.c:3446 msgid "Align right edges and vertical centers of selected objects" msgstr "ÁȘÂòÂĐŸĘ€Î±ŠĂŒ€ÈżâÄŸÊęžț€ÎĂæżŽ€ò€œ€í€š€ë" #: ../../strtbl.c:3447 msgid "Align right and bottom edges of selected objects" msgstr "ÁȘÂòÂĐŸĘ€Î±ŠČŒ€ò€œ€í€š€ë" #: ../../strtbl.c:3460 msgid "Align top edges of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎŸćÉô€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3461 msgid "Align vertical centers of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎżâÄŸÊęžț€ÎĂæżŽ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3462 msgid "Align bottom edges of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎÄìÉô€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3463 msgid "Align left edges of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎșžĂŒ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3464 msgid "Align left and top edges of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎșžŸćĂŒ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3465 msgid "Align left edges and vertical centers of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎșžĂŒ€ÈżâÄŸÊęžț€ÎĂæżŽ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3466 msgid "Align left and bottom edges of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎșžČŒ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3467 msgid "Align horizontal centers of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎżćÊżÊęžț€ÎĂæżŽ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3468 msgid "Align horizontal centers and top edges of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎżćÊżÊęžț€ÎĂæżŽ€ÈŸćĂŒ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3469 msgid "Align horizontal and vertical centers of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎżćÊżÊęžț€Ș€è€ÓżâÄŸÊęžț€ÎĂæżŽ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3470 msgid "" "Align horizontal centers and bottom edges of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎżćÊżÊęžț€ÎĂæżŽ€ÈČŒĂŒ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3471 msgid "Align right edges of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€Î±ŠĂŒ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3472 msgid "Align right and top edges of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€Î±ŠŸć€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3473 msgid "Align right edges and vertical centers of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€ÎżâÄŸÊęžț€ÎĂæżŽ€È±ŠĂŒ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3474 msgid "Align right and bottom edges of selected objects to the grid" msgstr "ÁȘÂòÂĐŸĘ€Î±ŠČŒ€ò„°„ê„Äɀˀą€ï€»€ë" #: ../../strtbl.c:3487 msgid "Align selected objects (as a group) to the top of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€ÎŸćÉô€ËÀ°Îó" #: ../../strtbl.c:3488 msgid "Align selected objects (as a group) to the vertical center of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€ÎżâÄŸÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3489 msgid "Align selected objects (as a group) to the bottom of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€ÎČŒĄŠżâÄŸÊęžț€ËÀ°Îó" #: ../../strtbl.c:3490 msgid "Align selected objects (as a group) to the left side of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€ÎșžĂŒ€ËÀ°Îó" #: ../../strtbl.c:3491 msgid "Align selected objects (as a group) to the left top corner of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€ÎșžŸć€ËÀ°Îó" #: ../../strtbl.c:3492 msgid "" "Align selected objects (as a group) to the left vertical center of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€ÎșžĄŠżâÄŸÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3493 msgid "Align selected objects (as a group) to the left bottom of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€ÎșžČŒ€ËÀ°Îó" #: ../../strtbl.c:3494 msgid "" "Align selected objects (as a group) to the horizontal center of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€ÎżćÊżÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3495 msgid "" "Align selected objects (as a group) to the top horizontal center of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€ÎŸćĄŠżćÊżÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3496 msgid "Align selected objects (as a group) to the center of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3497 msgid "" "Align selected objects (as a group) to the bottom horizontal center of the " "page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€ÎČŒĄŠżćÊżÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3498 msgid "Align selected objects (as a group) to the right side of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€Î±Š€ËÀ°Îó" #: ../../strtbl.c:3499 msgid "Align selected objects (as a group) to the right top corner of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€Î±ŠŸć€ËÀ°Îó" #: ../../strtbl.c:3500 msgid "" "Align selected objects (as a group) to the right vertical center of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€Î±ŠĄŠżâÄŸÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3501 msgid "" "Align selected objects (as a group) to the right bottom corner of the page" msgstr "ÁȘÂòÂĐŸĘ€ò(€Ò€È€Ä€Î„°„ëĄŒ„Ś€Î€è€Š€Ë)„ÚĄŒ„ž€Î±ŠČŒ€ËÀ°Îó" #: ../../strtbl.c:3514 msgid "Align selected vertices to the top of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€ÎŸć€ËÀ°Îó" #: ../../strtbl.c:3515 msgid "Align selected vertices to the vertical center of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€ÎżâÄŸÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3516 msgid "Align selected vertices to the bottom of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€ÎČŒ€ËÀ°Îó" #: ../../strtbl.c:3517 msgid "Align selected vertices to the left side of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€Îșž€ËÀ°Îó" #: ../../strtbl.c:3518 msgid "Align selected vertices to the left top corner of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€ÎșžŸć€ËÀ°Îó" #: ../../strtbl.c:3519 msgid "Align selected vertices to the left vertical center of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€ÎșžĄŠżâÄŸÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3520 msgid "Align selected vertices to the left bottom corner of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€ÎșžČŒ€ËÀ°Îó" #: ../../strtbl.c:3521 msgid "Align selected vertices to the horizontal center of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€ÎżćÊżÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3522 msgid "Align selected vertices to the top horizontal center of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€ÎŸćĄŠżćÊżÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3523 msgid "Align selected vertices to the center of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3524 msgid "Align selected vertices to the bottom horizontal center of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€ÎČŒĄŠżćÊżÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3525 msgid "Align selected vertices to the right side of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€Î±Š€ËÀ°Îó" #: ../../strtbl.c:3526 msgid "Align selected vertices to the right top corner of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€Î±ŠŸć€ËÀ°Îó" #: ../../strtbl.c:3527 msgid "Align selected vertices to the right vertical center of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€Î±ŠĄŠżâÄŸÊęžț€ÎĂæżŽ€ËÀ°Îó" #: ../../strtbl.c:3528 msgid "Align selected vertices to the right bottom corner of the page" msgstr "ÁȘÂò€·€żÄșĆÀ€ò„ÚĄŒ„ž€Î±ŠČŒ€ËÀ°Îó" #. #. * note: the m field is used for the localized strings #. #: ../../strtbl.c:3545 msgid "select/move/resize objects" msgstr "„Ș„Ö„ž„§„Ż„È€ÎÁȘÂò/°Üư/łÈÂçœÌŸź" #: ../../strtbl.c:3546 msgid "enter text" msgstr "„Æ„­„č„ÈÆțÎÏ" #: ../../strtbl.c:3547 msgid "draw rectangles" msgstr "»ÍłŃ·ÁÉÁČè" #: ../../strtbl.c:3548 msgid "draw ovals (corner to corner)" msgstr "ÂʱßÉÁČè(ĂŒ€«€éĂŒ)" #: ../../strtbl.c:3549 msgid "draw ovals (center to corner)" msgstr "ÂʱßÉÁČè(ĂæżŽ€«€éĂŒ)" #: ../../strtbl.c:3550 msgid "draw circles (edge to edge)" msgstr "±ßÉÁČè(ĂæżŽ€«€éĂŒ)" #: ../../strtbl.c:3551 msgid "draw poly/open splines" msgstr "ÀȚ€ìÀț/¶ÊÀțÉÁČè" #: ../../strtbl.c:3552 msgid "draw polygon/closed splines" msgstr "ÂżłŃ·Á/ÊÄ€ž€ż¶ÊÀțÉÁČè" #: ../../strtbl.c:3553 msgid "draw arcs (center first)" msgstr "±ßžÌÉÁČè(ĂæżŽ€òÀè€Ë»ŰÄê)" #: ../../strtbl.c:3554 msgid "draw arcs (endpoints first)" msgstr "±ßžÌÉÁČè(ĂŒ€òÀè€Ë»ŰÄê)" #: ../../strtbl.c:3555 msgid "draw rcboxes" msgstr "ĂŒ€ÎŽĘ€€ÄčÊę·ÁÉÁČè" #: ../../strtbl.c:3556 msgid "freehand poly/open splines" msgstr "„Ő„êĄŒ„Ï„ó„É€ÎÀȚ€ìÀț/¶ÊÀț" #: ../../strtbl.c:3557 msgid "select/move vertices" msgstr "ÄșĆÀ€ÎÁȘÂò/°Üư" #: ../../strtbl.c:3558 msgid "rotate/shear objects" msgstr "„Ș„Ö„ž„§„Ż„È€ÎČóĆŸ/ÊŃ·Á" #: ../../strtbl.c:3633 msgid "next color" msgstr "ŒĄ€Îż§" #: ../../strtbl.c:3633 msgid "prev color" msgstr "Á°€Îż§" #: ../../strtbl.c:3638 msgid "next horizontal align" msgstr "ŒĄ€ÎżćÊżÊęžț€ÎÀ°ÎóÊęËĄ" #: ../../strtbl.c:3638 msgid "prev horizontal align" msgstr "Á°€ÎżćÊżÊęžț€ÎÀ°ÎóÊęËĄ" #: ../../strtbl.c:3643 msgid "next vertical align" msgstr "ŒĄ€ÎżâÄŸÊęžț€ËÀ°ÎóÊęËĄ" #: ../../strtbl.c:3643 msgid "prev vertical align" msgstr "Á°€ÎżâÄŸÊęžț€ËÀ°ÎóÊęËĄ" #: ../../strtbl.c:3648 msgid "next page" msgstr "ŒĄ€Î„ÚĄŒ„ž" #: ../../strtbl.c:3648 msgid "prev page" msgstr "Á°€Î„ÚĄŒ„ž" #: ../../strtbl.c:3650 msgid "drawing size" msgstr "ÉÁČè„”„€„ș" #: ../../strtbl.c:3655 #, fuzzy msgid "tiled page mode" msgstr "„ÚĄŒ„ž€Î„ż„€„ëÉœŒš" #: ../../strtbl.c:3657 #, fuzzy msgid "stacked page mode" msgstr "„ÚĄŒ„žÁàșî" #: ../../strtbl.c:3662 ../../strtbl.c:3666 msgid "center justified" msgstr "Ăæ±û€Ç€œ€í€š€ë" #: ../../strtbl.c:3662 ../../strtbl.c:3664 msgid "right justified" msgstr "±ŠĂŒ€ò€œ€í€š€ë" #: ../../strtbl.c:3664 ../../strtbl.c:3666 msgid "left justified" msgstr "șžĂŒ€ò€œ€í€š€ë" #: ../../strtbl.c:3671 msgid "next font" msgstr "ŒĄ€Î„Ő„©„ó„È" #: ../../strtbl.c:3671 msgid "prev font" msgstr "Á°€Î„Ő„©„ó„È" #: ../../strtbl.c:3676 msgid "inc text vspace" msgstr "„Æ„­„č„ȀΜÄÊęžț€ÎŽÖłÖ€òŸź€”€Ż" #: ../../strtbl.c:3676 msgid "modify text vspace" msgstr "„Æ„­„č„ȀΜÄÊęžț€ÎŽÖłÖ€òœ€À”" #: ../../strtbl.c:3676 msgid "dec text vspace" msgstr "„Æ„­„č„ȀΜÄÊęžț€ÎŽÖłÖ€òÂ瀭€Ż" #: ../../strtbl.c:3681 msgid "next text size" msgstr "ŒĄ€ÎÊž»ú„”„€„ș" #: ../../strtbl.c:3681 msgid "prev text size" msgstr "Á°€ÎÊž»ú„”„€„ș" #: ../../strtbl.c:3686 msgid "next line width" msgstr "ŒĄ€ÎÀț€ÎÂÀ€”" #: ../../strtbl.c:3686 msgid "prev line width" msgstr "Àț€ÎÂÀ€”" #: ../../strtbl.c:3691 msgid "next line style" msgstr "ŒĄ€ÎÀț€Î„脿„€„ëÂÎ" #: ../../strtbl.c:3691 msgid "prev line style" msgstr "Á°€ÎÀț€Î„脿„€„ë" #: ../../strtbl.c:3696 msgid "next line type" msgstr "ŒĄ€ÎÀț€ÎŒïÎà" #: ../../strtbl.c:3696 msgid "prev line type" msgstr "Á°€ÎÀț€ÎŒïÎà" #: ../../strtbl.c:3701 msgid "next line dash" msgstr "ŒĄ€ÎÇËÀț„ż„€„Ś" #: ../../strtbl.c:3701 msgid "prev line dash" msgstr "Á°€ÎÇËÀț„ż„€„Ś" #: ../../strtbl.c:3706 msgid "inc rcbox radius" msgstr "łŃ€ÎŽĘ€€»ÍłŃ·Á€ÎŽĘ€ß€òÂ瀭€Ż" #: ../../strtbl.c:3706 msgid "modify rcbox radius" msgstr "łŃ€ÎŽĘ€€»ÍłŃ·Á€ÎŽĘ€ß€òœ€À”" #: ../../strtbl.c:3706 msgid "dec rcbox radius" msgstr "łŃ€ÎŽĘ€€»ÍłŃ·Á€ÎŽĘ€ß€òŸź€”€Ż" #: ../../strtbl.c:3711 msgid "zoom in" msgstr "„șĄŒ„à„€„ó" #: ../../strtbl.c:3711 msgid "modify zoom" msgstr "„șĄŒ„àÊŃčč" #: ../../strtbl.c:3711 msgid "zoom out" msgstr "„șĄŒ„à„ą„Š„È" #: ../../strtbl.c:3716 msgid "unconstrained move mode" msgstr "čŽÂ«€Î€Ê€€°Üư„âĄŒ„É" #: ../../strtbl.c:3718 msgid "constrained move mode" msgstr "čŽÂ«€”€ì€ż°Üư„âĄŒ„É" #: ../../strtbl.c:3728 msgid "stretchable text mode" msgstr "Êž»ú€ÎłÈÂçœÌŸźČÄ„âĄŒ„É" #: ../../strtbl.c:3730 msgid "non-stretchable text mode" msgstr "Êž»ú€ÎłÈÂçœÌŸźÉÔČÄ„âĄŒ„É" #: ../../strtbl.c:3735 msgid "landscape" msgstr "„é„ó„Ʉ脱ĄŒ„Ś" #: ../../strtbl.c:3735 ../../strtbl.c:3737 msgid "PageStyle Menu" msgstr "»úÂ΄á„Ë„ćĄŒ" #: ../../strtbl.c:3737 msgid "portrait" msgstr "„ĘĄŒ„È„ìĄŒ„È" #: ../../strtbl.c:3742 msgid "next fill pattern" msgstr "ŒĄ€ÎĆÉ€ê€Ä€Ö€·„Ń„żĄŒ„ó" #: ../../strtbl.c:3742 msgid "prev fill pattern" msgstr "Á°€ÎĆÉ€ê€Ä€Ö€·„Ń„żĄŒ„ó" #: ../../strtbl.c:3747 msgid "next pen pattern" msgstr "ŒĄ€Î„ڄ󥊄фżĄŒ„ó" #: ../../strtbl.c:3747 msgid "prev pen pattern" msgstr "Á°€Î„ڄ󥊄фżĄŒ„ó" #: ../../strtbl.c:3752 msgid "transparent pattern mode" msgstr "Æ©Čá„Ń„żĄŒ„ó„âĄŒ„É" #: ../../strtbl.c:3754 msgid "opaque pattern mode" msgstr "ÈóÆ©Čá„Ń„żĄŒ„ó„âĄŒ„É" #. #. * note: the m field is used for the localized strings #. #: ../../strtbl.c:3827 ../../strtbl.c:3840 msgid "Shift All Tabs Down" msgstr "" #: ../../strtbl.c:3828 msgid "Shift Tabs Down" msgstr "" #: ../../strtbl.c:3829 ../../strtbl.c:3842 msgid "Check All" msgstr "ÁŽ€Æ„Á„§„Ă„Ż" #: ../../strtbl.c:3830 ../../strtbl.c:3843 msgid "Uncheck All" msgstr "" #: ../../strtbl.c:3831 msgid "Shift Tabs Up" msgstr "" #: ../../strtbl.c:3832 ../../strtbl.c:3845 msgid "Shift All Tabs Up" msgstr "" #: ../../strtbl.c:3841 msgid "Shift 10 Tabs Down" msgstr "" #: ../../strtbl.c:3844 msgid "Shift 10 Tabs Up" msgstr "" #. #. * note: the localized field is used for the localized strings #. #: ../../strtbl.c:3903 msgid "arrow height" msgstr "Ìđ°ő€Îč—" #: ../../strtbl.c:3904 msgid "arrow width" msgstr "Ìđ°ő€ÎÉę" #: ../../strtbl.c:3905 msgid "arrow style" msgstr "Ìđ°ő€Î„脿„€„ë" #: ../../strtbl.c:3906 msgid "color" msgstr "ż§" #: ../../strtbl.c:3907 msgid "dash" msgstr "ÇËÀț" #: ../../strtbl.c:3908 msgid "line width" msgstr "Àț€ÎÂÀ€”" #: ../../strtbl.c:3909 msgid "pattern transparency" msgstr "„Ń„żĄŒ„ó€ÎÆ©ČáÀ­" #: ../../strtbl.c:3910 msgid "fill" msgstr "ĆÉ€ê€Ä€Ö€·" #: ../../strtbl.c:3911 msgid "pen" msgstr "„Ú„ó" #: ../../strtbl.c:3912 msgid "rcbox radius" msgstr "łŃ€ÎŽĘ€€»ÍłŃ·Á€ÎłŃ" #: ../../strtbl.c:3913 msgid "spline" msgstr "„脌„é„€„ó" #: ../../strtbl.c:3914 msgid "text font" msgstr "„Æ„­„č„ÈĄŠ„Ő„©„ó„È" #: ../../strtbl.c:3915 msgid "text style (no use, part of text font)" msgstr "" #: ../../strtbl.c:3916 msgid "text justification" msgstr "" #: ../../strtbl.c:3917 msgid "text size" msgstr "Êž»ú„”„€„ș" #: ../../strtbl.c:3918 msgid "text vertical spacing" msgstr "„Æ„­„č„È€ÎżâÄŸÊęžț€ËŽÖłÖ" #: ../../strtbl.c:3919 msgid "text underline" msgstr "„Æ„­„č„È€ÎČŒÀț" #: ../../strtbl.c:3920 msgid "transformation matrix" msgstr "łÆŒïÊŃŽč" #: ../../strtbl.c:3921 #, fuzzy msgid "line width index" msgstr "Àț€ÎÂÀ€”" #. #. * note: the m field is used for the localized strings #. #: ../../strtbl.c:3969 msgid "Set printing mode to print to a printer" msgstr "" #: ../../strtbl.c:3970 msgid "Set printing mode to generate EPS files" msgstr "" #: ../../strtbl.c:3971 msgid "Set printing mode to generate PS files" msgstr "" #: ../../strtbl.c:3972 msgid "Set printing mode to generate X11 Bitmap files" msgstr "" #: ../../strtbl.c:3973 msgid "Set printing mode to generate X11 Pixmap files" msgstr "" #: ../../strtbl.c:3974 msgid "Set printing mode to generate ASCII files" msgstr "" #: ../../strtbl.c:3975 msgid "Set printing mode to generate EPSI files" msgstr "" #: ../../strtbl.c:3976 msgid "Set printing mode to generate GIF/ISMAP files" msgstr "" #: ../../strtbl.c:3977 msgid "Set printing mode to generate HTML files" msgstr "" #: ../../strtbl.c:3978 msgid "Set printing mode to generate PDF files" msgstr "" #: ../../strtbl.c:3979 msgid "Set printing mode to generate DOS/Windows EPSI files" msgstr "" #: ../../strtbl.c:3980 msgid "Set printing mode to generate PNG files" msgstr "" #: ../../strtbl.c:3981 msgid "Set printing mode to generate JPEG files" msgstr "" #: ../../strtbl.c:3982 msgid "Set printing mode to generate NetList files" msgstr "" #: ../../strtbl.c:3983 #, c-format msgid "Set printing mode to generate %s files" msgstr "" �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/ja/Imakefile����������������������������������������������������������������������0000644�0000764�0000764�00000002246�10064673302�015621� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#ifndef XCOMM #define XCOMM # #endif #ifndef NullParameter #define NullParameter #endif XCOMM XCOMM Author: Jun Nishii, Project Vine <jun@flatout.org>, 1999 XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/ja/Imakefile,v 1.1 2004/06/18 23:12:02 william Exp $ XCOMM #include <../Po.tmpl> CURRENTDIR =./ SRCS = $(CURRENTDIR)*.po PACKAGE = tgif CATALOGS = ja.mo POFILES = ja.po POTFILES=../../menuinfo.c ../../strtbl.c .SUFFIXES: .SUFFIXES: .mo .po .po.mo: msgfmt -o $@ $< all:: $(CATALOGS) $(PACKAGE).pot: $(POTFILES) xgettext --default-domain=$(PACKAGE) \ --add-comments --keyword=_ --keyword=N_ $(POTFILES) if cmp -s $(PACKAGE).po $(PACKAGE).pot; then \ rm -f $(PACKAGE).po; \ else \ mv -f $(PACKAGE).po $(PACKAGE).pot; \ fi install:: $(CATALOGS) $(MKINSTALLDIRS) $(NLSDIR) chmod 755 $(NLSDIR) for n in $(CATALOGS) __DuMmY ; do \ if test "$$n" -a "$$n" != "__DuMmY" ; then \ l=`basename $$n .mo`; \ $(MKINSTALLDIRS) $(NLSDIR)/$$l/LC_MESSAGES; \ chmod 755 $(NLSDIR)/$$l; \ chmod 755 $(NLSDIR)/$$l/LC_MESSAGES; \ $(INSTALL) -m 644 $$n $(NLSDIR)/$$l/LC_MESSAGES/$(PACKAGE).mo; \ fi; \ done clean:: rm -f $(CATALOGS) ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/ja/tgif-wrapper.sh����������������������������������������������������������������0000644�0000764�0000764�00000000152�10774250147�016753� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#!/bin/bash if echo $LANG | grep -q ja_JP ; then export LANG=ja_JP.eucJP fi exec /usr/libexec/tgif $* ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/ja/README.jp����������������������������������������������������������������������0000644�0000764�0000764�00000001443�10773267116�015307� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������Shift-<Space> €Ç, kinput2€Ë€è€ëÆüËÜžìÆțÎÏ€òčÔ€š€Ț€č. €”€é€Ë€€€í€€€í€ÊÀßÄê€òčÔ€€€ż€€€È€­€Ë€Ï, tgif.Xdefaults €ò»Čč̀ˀ·€Æ, .Xdefaults €ËÀßÄê€òČĂ€š€Æ€Ż€À€”€€. €Ț€żĄą„á„Ë„ćĄŒ€ò±ŃžìÉœŒš€Ë€·€ż€€€È€­€Ë€ÏĄąŽÄ¶­ÊŃżô LANG=C LANGUAGE=C €ò»ŰÄꀷ€Æ€Ż€À€”€€ĄŁ ex) hoge> LANG=C LANGUAGE=C tgif €Ț€żĄą alias eng='LANG=C LANGUAGE=C' €È€€€Ă€ż„š„€„ê„ą„č€òșî€Ă€Æ€Ș€Ż€ÈĄątgif €œ€ÎŸ, NLSÂбț€Î„ł„Ț„ó„ɀDZўìÉœŒš€ò hoge> eng tgif €ÈŽÊñ€ËŒÂčԀǀ­€ë€Î€ÇÊŰÍű€Ç€čĄŁ ÆüËÜžì€ÎŒĐÂ΀ä„ÜĄŒ„ë„ÉÂ΀ÎÉœŒš€âtgifŸć€Ç€ÏčÔ€Š€ł€È€Ï€Ç€­€Ț€č€Ź, „ÜĄŒ„ë „É€ÎœĐÎππǀ­€Ț€»€óĄŁŒĐÂ΀Ï(Vine Linux 2.0 Ÿć€Ç€Ï)ÌäÂê€ą€ê€Ț€»€ó€ŹĄą ÆüËÜžìPS„Ś„ê„󄿀ò»È€Ă€Æ€ëŸìčç€Ë€ÏĄąÆüËÜžì€Ïgs·ĐÍł€ÇœĐÎÏ€č€ë€è€Š€Ë€·€Æ €Ż€À€”€€ĄŁ 2000/1/20 Jun Nishii, Project Vine <jun@vinelinux.org> �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/ja/Tgif.ad������������������������������������������������������������������������0000644�0000764�0000764�00000016505�10773267172�015225� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������! Resource file to use Japanese characters and kinput2/xim ! ! Jun Nishii, Project Vine ! Time-stamp: <05/01/17 23:03:15 daisuke> ! <jun@vinelinux.org> ! Modified by Shoji Matsumoto <shom@vinelinux.org> ! Modified by Daisuke SUZUKI <daisuke@vinelinux.org> Tgif.MenuFontSet: -*-helvetica-medium-r-normal--12-*-*-*-*-*-*-*,-alias-*-medium-r-normal--12-*-*-*-*-*-*-* Tgif.BoldMsgFont: -*-helvetica-bold-r-normal--12-*-*-*-*-*-*-* Tgif.MsgFont: -*-helvetica-medium-r-normal--12-*-*-*-*-*-*-* Tgif.FontSizes: 8 9 10 11 12 13 14 15 16 17 18 20 24 32 34 36 40 44 60 70 100 200 250 300 Tgif.DefaultSingleByteFont: Helvetica Tgif.AdditionalFonts: \n\ lucidabright-medium-r-normal,iso8859-1,ZapfChancery-MediumItalic\n\ lucidabright-demibold-r-normal,iso8859-1,ZapfChancery-MediumItalic\n\ lucidabright-medium-i-normal,iso8859-1,ZapfChancery-MediumItalic\n\ lucidabright-demibold-i-normal,iso8859-1,ZapfChancery-MediumItalic\n\ Tgif.ZapfChanceryShowFontChar: ZC Tgif.SquareDoubleByteFonts: \n\ -alias-mincho-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,Ryumin-Light-EUC-H\n\ -alias-mincho-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,Ryumin-Light-EUC-H\n\ -alias-mincho-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,Ryumin-Italic-EUC-H\n\ -alias-mincho-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,Ryumin-Italic-EUC-H\n\ \n\ -alias-gothic-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,GothicBBB-Medium-EUC-H\n\ -alias-gothic-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,GothicBBB-Medium-EUC-H\n\ -alias-gothic-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,GothicBBB-Italic-EUC-H\n\ -alias-gothic-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,GothicBBB-Italic-EUC-H\n\ \n\ -alias-mincho-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,Ryumin-Light-EUC-V\n\ -alias-mincho-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,Ryumin-Light-EUC-V\n\ -alias-mincho-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,V,Ryumin-Light-EUC-V\n\ -alias-mincho-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,V,Ryumin-Light-EUC-V\n\ \n\ -alias-gothic-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,GothicBBB-Medium-EUC-V\n\ -alias-gothic-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,GothicBBB-Medium-EUC-V\n\ -alias-gothic-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,V,GothicBBB-Italic-EUC-V\n\ -alias-gothic-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,V,GothicBBB-Italic-EUC-V\n\ \n\ -ricoh-lx marugothic-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-MaruGothic--Regular-EUC-H\n\ -ricoh-lx marugothic-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-MaruGothic--Regular-EUC-H\n\ -ricoh-lx marugothic-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-MaruGothic--Italic-EUC-H\n\ -ricoh-lx marugothic-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-MaruGothic--Italic-EUC-H\n\ \n\ -ricoh-lx pop-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-POP--Regular-EUC-H\n\ -ricoh-lx pop-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-POP--Regular-EUC-H\n\ -ricoh-lx pop-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-POP--Italic-EUC-H\n\ -ricoh-lx pop-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-POP--Italic-EUC-H\n\ \n\ -ricoh-lx gothic ub-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-Gothic-UB--Regular-EUC-H\n\ -ricoh-lx gothic ub-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-Gothic-UB--Regular-EUC-H\n\ -ricoh-lx gothic ub-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-Gothic-UB--Italic-EUC-H\n\ -ricoh-lx gothic ub-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,LX-Gothic-UB--Italic-EUC-H\n\ \n\ -ricoh-lx marugothic-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-MaruGothic--Regular-EUC-V\n\ -ricoh-lx marugothic-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-MaruGothic--Regular-EUC-V\n\ -ricoh-lx marugothic-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-MaruGothic--Italic-EUC-V\n\ -ricoh-lx marugothic-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-MaruGothic--Italic-EUC-V\n\ \n\ -ricoh-lx pop-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-POP--Regular-EUC-V\n\ -ricoh-lx pop-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-POP--Regular-EUC-V\n\ -ricoh-lx pop-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-POP--Italic-EUC-V\n\ -ricoh-lx pop-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-POP--Italic-EUC-V\n\ \n\ -ricoh-lx gothic ub-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-Gothic-UB--Regular-EUC-V\n\ -ricoh-lx gothic ub-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-Gothic-UB--Regular-EUC-V\n\ -ricoh-lx gothic ub-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-Gothic-UB--Italic-EUC-V\n\ -ricoh-lx gothic ub-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,V,LX-Gothic-UB--Italic-EUC-V\n\ \n\ -dynalab-dfmincho ub-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-Mincho-UB--Regular-EUC-H\n\ -dynalab-dfmincho ub-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-Mincho-UB--Regular-EUC-H\n\ -dynalab-dfmincho ub-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-Mincho-ubUB--Italic-EUC-H\n\ -dynalab-dfmincho ub-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-Mincho-UB--Italic-EUC-H\n\ \n\ -dynalab-dfkaisho sb-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-Kaisho-Bd--Regular-EUC-H\n\ -dynalab-dfkaisho sb-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-Kaisho-Bd--Regular-EUC-H\n\ -dynalab-dfkaisho sb-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-Kaisho-Bd--Italic-EUC-H\n\ -dynalab-dfkaisho sb-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-Kaisho-Bd--Italic-EUC-H\n\ \n\ -dynalab-dfpopstencil w7-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-POPStencil-W7--Regular-EUC-H\n\ -dynalab-dfpopstencil w7-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-POPStencil-W7--Regular-EUC-H\n\ -dynalab-dfpopstencil w7-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-POPStencil-W7--Italic-EUC-H\n\ -dynalab-dfpopstencil w7-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-POPStencil-W7--Italic-EUC-H\n\ \n\ -dynalab-dfbrushrd w7-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-BrushRD-W7--Regular-EUC-H\n\ -dynalab-dfbrushrd w7-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-BrushRD-W7--Regular-EUC-H\n\ -dynalab-dfbrushrd w7-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-BrushRD-W7--Italic-EUC-H\n\ -dynalab-dfbrushrd w7-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-BrushRD-W7--Italic-EUC-H\n\ \n\ -dynalab-dffreeryuyou lt-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-FreeRyuyou-Lt--Regular-EUC-H\n\ -dynalab-dffreeryuyou lt-bold-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-FreeRyuyou-Lt--Regular-EUC-H\n\ -dynalab-dffreeryuyou lt-medium-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-FreeRyuyou-Lt--Italic-EUC-H\n\ -dynalab-dffreeryuyou lt-bold-i-*--%d-*-*-*-*-*-jisx0208.1983-*,H,DF-FreeRyuyou-Lt--Italic-EUC-H\n\ !Tgif.DoubleByteInputMethod: kinput2 Tgif.DoubleByteInputMethod: xim Tgif.UseNKF: true Tgif.CopyAndPasteJIS: true Tgif.PreeditType: overthespot Tgif.Lang: ja_JP.eucJP Tgif.ConvSelection: JAPANESE_CONVERSION Tgif.IconPixmap: /usr/share/tgif/tgificon.xpm ! etc... Tgif.MinimalMenubar: true Tgif.PSA4PaperSize: true Tgif.InitialPaperSize: 21cm x 29.7cm Tgif.GridSystem: Metric Tgif.InitialFont: Ryumin Tgif.RyuminShowFontChar: ÌÀ Tgif.GothicBBBShowFontChar: łŃ Tgif.DFPOPShowFontChar: ŁÄ„Ę Tgif.DFGyoShoShowFontChar: ŁÄčÔ Tgif.DFLeiShoShowFontChar: ŁÄÎì Tgif.LX-POPShowFontChar: ŁÌ„Ę Tgif.LX-Gothic-UBShowFontChar: ŁÌ„Ž Tgif.LX-MaruGothicShowFontChar: ŁÌŽĘ Tgif.DF-Mincho-UBShowFontChar: ÂÀÌÀ Tgif.DF-Kaisho-BdShowFontChar: ÜŽ Tgif.DF-POPStencil-W7ShowFontChar: „Ę„č Tgif.DF-BrushRD-W7ShowFontChar: „ÖRD Tgif.DF-FreeRyuyou-LtShowFontChar: ÎźÍŐ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/ja/tgif.desktop�������������������������������������������������������������������0000644�0000764�0000764�00000000423�10774250147�016335� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������[Desktop Entry] Encoding=UTF-8 Name=Tgif Comment=2-D drawling tool Comment[ja]=2æŹĄć…ƒăƒ‰ăƒ­ăƒŒă‚€ăƒłă‚°ă‚œăƒ•ăƒˆ Exec=tgif %f Icon=tgif Terminal=false Type=Application StartupNotify=false MimeType=application/x-tgif; Categories=Application;Graphics;VectorGraphics;X-Fedora; ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/Imakefile�������������������������������������������������������������������������0000644�0000764�0000764�00000002632�10064673302�015226� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#ifndef XCOMM #define XCOMM # #endif #ifndef NullParameter #define NullParameter #endif XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 1990-2001, William Chia-Wei Cheng. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/Imakefile,v 1.1 2004/06/18 23:12:02 william Exp $ XCOMM XCOMM -------------------------------------------- XCOMM XCOMM There should be no need to modify this file. XCOMM XCOMM -------------------------------------------- XCOMM #include <Po.tmpl> #define IHaveSubdirs SUBDIRS = ja ru fr #define PassCDebugFlags 'CDEBUGFLAGS=$(CDEBUGFLAGS)' MakeSubdirs($(SUBDIRS)) DependSubdirs($(SUBDIRS)) TGIFNLSVER = 1.0.8 distr: tar versioninfo tar: rm -f tgifintl-$(TGIFNLSVER).tar/**/* tar cvf tgifintl-$(TGIFNLSVER).tar \ Imakefile Po.tmpl Po.tmpl-/**/* README HISTORY \ ja/Imakefile ja/ja.po \ ru/Imakefile ru/ru.po \ fr/Imakefile fr/fr.po rm -rf tgifintl-$(TGIFNLSVER) mkdir tgifintl-$(TGIFNLSVER) cd tgifintl-$(TGIFNLSVER); tar xvf ../tgifintl-$(TGIFNLSVER).tar; cd .. rm -f tgifintl-$(TGIFNLSVER).tar tar cvf tgifintl-$(TGIFNLSVER).tar tgifintl-$(TGIFNLSVER) rm -rf tgifintl-$(TGIFNLSVER) gzip tgifintl-$(TGIFNLSVER).tar rm -f /**/*.cat.Z.uu versioninfo: what Imakefile README Po.tmpl Po.tmpl-/**/* \ ja/Imakefile ja/ja.po \ ru/Imakefile ru/ru.po \ fr/Imakefile fr/fr.po \ > VersionInfo/Distribution/tgifintl-$(TGIFNLSVER) ������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/fr/�������������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233155�014016� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/fr/fr.po��������������������������������������������������������������������������0000644�0000764�0000764�00000070461�10064673302�015000� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# Author : Roland Baudin <roland.baudin@cnet.francetelecom.fr> # # @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/fr/fr.po,v 1.1 2004/06/18 23:12:02 william Exp $ # msgid "" msgstr "" "Project-Id-Version: tgif-4.1.26\n" "POT-Creation-Date: 2000-02-07\n" "PO-Revision-Date: 2000-03-09\n" "Last-Translator: Roland Baudin <roland.baudin@cnet.francetelecom.fr>\n" "Language-Team: Français" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset= koi8-r\n" "Content-Transfer-Encoding: 8-bit\n" msgid "Flip/Rotate" msgstr "Symétrie/Rotation" msgid "Set Paper Color..." msgstr "Couleur du papier..." msgid "Screen Capture" msgstr "Capture d'écran" msgid "Full Screen Capture" msgstr "Capture plein écran" msgid "Delayed Full Screen Capture..." msgstr "Capture d'écran différée..." msgid "Hide During Capture" msgstr "Cacher durant la capture" #: ../../menuinfo.c:225 ../../menuinfo.c:956 msgid "Portrait" msgstr "Portrait" #: ../../menuinfo.c:226 ../../menuinfo.c:957 msgid "Landscape" msgstr "Paysage" #: ../../menuinfo.c:238 msgid "Roman" msgstr "Romain" #: ../../menuinfo.c:240 msgid "Bold" msgstr "Gras" #: ../../menuinfo.c:242 msgid "Italic" msgstr "Italique" #: ../../menuinfo.c:244 msgid "BoldItalic" msgstr "Italique Gras" #: ../../menuinfo.c:247 msgid "Left" msgstr "Gauche" #: ../../menuinfo.c:249 msgid "Center" msgstr "Centré" #: ../../menuinfo.c:251 msgid "Right" msgstr "Droite" #: ../../menuinfo.c:254 msgid "No Underlined" msgstr "Non souligné" #: ../../menuinfo.c:256 msgid "Underlined" msgstr "Souligné" #: ../../menuinfo.c:266 msgid "Next Page" msgstr "Page suivante" #: ../../menuinfo.c:267 msgid "Prev Page" msgstr "Page précédente" #: ../../menuinfo.c:268 msgid "Goto Page..." msgstr "Aller à la page..." #: ../../menuinfo.c:269 msgid "Name Pages..." msgstr "Noms des pages..." #: ../../menuinfo.c:270 msgid "Edit Page File Names..." msgstr "Editer les noms des pages..." #: ../../menuinfo.c:274 msgid "Add Page Before..." msgstr "Ajouter une page avant..." #: ../../menuinfo.c:276 msgid "Add Page After..." msgstr "Ajouter une page après..." #: ../../menuinfo.c:278 msgid "Delete Current Page" msgstr "Supprimer la page courante" #: ../../menuinfo.c:280 msgid "Delete Pages..." msgstr "Supprimer les pages..." #: ../../menuinfo.c:283 ../../menuinfo.c:299 ../../menuinfo.c:542 msgid "Print One Page" msgstr "Imprimer une page" #: ../../menuinfo.c:284 ../../menuinfo.c:544 msgid "Print One File Per Page" msgstr "Imprimer un fichier par page" #: ../../menuinfo.c:287 ../../menuinfo.c:301 msgid "Specify Paper Size..." msgstr "Taille du papier..." #: ../../menuinfo.c:295 msgid "Toggle Page Line Shown" msgstr "Montrer/cacher la ligne" #: ../../menuinfo.c:297 msgid "Specify Drawing Size..." msgstr "Taille du dessin..." #: ../../menuinfo.c:309 ../../menuinfo.c:960 ../../menuinfo.c:1243 msgid "Stacked Page" msgstr "Pages empilées" #: ../../menuinfo.c:311 ../../menuinfo.c:962 ../../menuinfo.c:1245 msgid "Tiled Page" msgstr "Pages juxtaposées" #: ../../menuinfo.c:318 msgid "Reduce Colors..." msgstr "Réduire les couleurs..." #: ../../menuinfo.c:321 msgid "Set Default Color Levels..." msgstr "Niveaux de couleurs par défaut..." #: ../../menuinfo.c:324 msgid "Reduce To Pixmap Colors..." msgstr "Réduire aux couleurs Pixmap..." #: ../../menuinfo.c:327 msgid "Reduce To Default Colors" msgstr "Réduire aux couleurs par défaut" #: ../../menuinfo.c:330 msgid "Default Error Diffuse" msgstr "Diffusion d'erreur par défaut" #: ../../menuinfo.c:339 msgid "Edge Detect" msgstr "Détection de contours" #: ../../menuinfo.c:341 msgid "Emboss" msgstr "Relief" #: ../../menuinfo.c:344 msgid "Spread..." msgstr "Diffuser" #: ../../menuinfo.c:346 msgid "Sharpen" msgstr "Accentuation" #: ../../menuinfo.c:348 msgid "Blur (3x3)" msgstr "Flou (3x3)" #: ../../menuinfo.c:350 msgid "Blur (5x5)" msgstr "Flou (5x5)" #: ../../menuinfo.c:352 msgid "Blur (7x7)" msgstr "Flou (7x7)" #: ../../menuinfo.c:360 msgid "Run Bggen..." msgstr "Fond dégradé..." #: ../../menuinfo.c:363 msgid "Circular Bggen..." msgstr "Fond circulaire..." #: ../../menuinfo.c:366 msgid "Simple Rect Bggen..." msgstr "Fond rectangulaire..." #: ../../menuinfo.c:375 msgid "Make Gray" msgstr "Niveaux de gris" #: ../../menuinfo.c:377 msgid "Brighten/Darken..." msgstr "Eclairer/Assombrir..." #: ../../menuinfo.c:379 msgid "Contrast Enhance..." msgstr "Augmenter le contraste..." #: ../../menuinfo.c:382 msgid "Change Saturation..." msgstr "Changer la saturation..." #: ../../menuinfo.c:384 msgid "Change Hue..." msgstr "Changer la teinte..." #: ../../menuinfo.c:386 msgid "Gamma Correct..." msgstr "Correction gamma..." #: ../../menuinfo.c:389 msgid "Invert Color" msgstr "Inverser la couleur" #: ../../menuinfo.c:392 msgid "Interpolate Color..." msgstr "Interpoler la couleur..." #: ../../menuinfo.c:395 msgid "Color Balance..." msgstr "Balance des couleurs..." #: ../../menuinfo.c:398 msgid "Reduce Number Of Colors" msgstr "Réduire le nombre de couleurs" #: ../../menuinfo.c:400 msgid "Effects" msgstr "Effets" #: ../../menuinfo.c:402 msgid "Generate" msgstr "Générer" #: ../../menuinfo.c:405 msgid "Regenerate Image" msgstr "Regénérer l'image" #: ../../menuinfo.c:407 msgid "Crop Image" msgstr "Recadrer l'image" #: ../../menuinfo.c:408 msgid "Get Color" msgstr "Acquérir la couleur" #: ../../menuinfo.c:411 msgid "Replace Color" msgstr "Remplacer la couleur" #: ../../menuinfo.c:414 msgid "Flood Fill" msgstr "Remplir avec la couleur" #: ../../menuinfo.c:416 msgid "Create Contour" msgstr "Créer le contour" #: ../../menuinfo.c:420 msgid "Subtract" msgstr "Soustraire" #: ../../menuinfo.c:422 msgid "Alpha Combine" msgstr "Combiner Alpha" #: ../../menuinfo.c:425 msgid "Xor Color" msgstr "XorColor" #: ../../menuinfo.c:428 msgid "Vector Warp" msgstr "Vector Warp" #: ../../menuinfo.c:437 msgid "Solve" msgstr "Résoudre" #: ../../menuinfo.c:438 msgid "Simulate" msgstr "Simuler" #: ../../menuinfo.c:439 msgid "Probe" msgstr "Tester" #: ../../menuinfo.c:440 msgid "Animate" msgstr "Animer" #: ../../menuinfo.c:441 msgid "Escape" msgstr "Escape" #: ../../menuinfo.c:448 msgid "Import..." msgstr "Importer..." #: ../../menuinfo.c:449 msgid "Import X Bitmap..." msgstr "Importer Bitmap X..." #: ../../menuinfo.c:451 msgid "Import X Pixmap..." msgstr "Importer Pixmap X..." #: ../../menuinfo.c:453 msgid "Import EPS File..." msgstr "Importer fichier EPS..." #: ../../menuinfo.c:455 msgid "Import GIF File..." msgstr "Importer fichier GIF..." #: ../../menuinfo.c:457 msgid "Import Other File..." msgstr "Importer autre fichier..." #: ../../menuinfo.c:460 msgid "Embed EPS File..." msgstr "Encapsuler fichier EPS..." #: ../../menuinfo.c:468 msgid "Browse X Bitmap" msgstr "Parcourir les Bitmap X" #: ../../menuinfo.c:470 msgid "Browse X Pixmap" msgstr "Parcourir les Pixmap X" #: ../../menuinfo.c:472 msgid "Browse Other..." msgstr "Parcourir autres..." #: ../../menuinfo.c:483 msgid "Export X Pixmap Deck To GIF" msgstr "Exporter X Pixmap Deck vers GIF" #: ../../menuinfo.c:486 msgid "Import GIF To X Pixmap Deck..." msgstr "Importer GIF dans X Pixmap Deck..." #: ../../menuinfo.c:496 msgid "Fake User Agent..." msgstr "Fake User Agent..." #: ../../menuinfo.c:499 msgid "Fake Referer..." msgstr "Fake Referer..." #: ../../menuinfo.c:502 msgid "Toggle Keep Alive" msgstr "Toggle Keep Alive" #: ../../menuinfo.c:512 msgid "New" msgstr "Nouveau" #: ../../menuinfo.c:513 msgid "Open..." msgstr "Ouvrir..." #: ../../menuinfo.c:514 msgid "Import" msgstr "Importer" #: ../../menuinfo.c:516 msgid "Browse" msgstr "Parcourir" #: ../../menuinfo.c:519 msgid "Save" msgstr "Enregistrer" #: ../../menuinfo.c:520 msgid "Save New..." msgstr "Enregistrer nouveau..." #: ../../menuinfo.c:522 msgid "Save Selected As..." msgstr "Enregistrer la sélection sous..." #: ../../menuinfo.c:524 msgid "Save Sym In Library..." msgstr "Enregistrer Sym dans une bibliothèque..." #: ../../menuinfo.c:528 msgid "Change Domain..." msgstr "Changer le domaine..." msgid "Domain" msgstr "Domaine" msgid "Edit Domain Paths..." msgstr "Editer les chemins de domaine..." msgid "Select Default Domain..." msgstr "Choisir le domaine par défaut..." msgid "Add A Domain..." msgstr "Ajouter un domaine..." msgid "Delete A Domain..." msgstr "Supprimer un domaine..." msgid "Reload Domain Info From X..." msgstr "Reload Domain Info From X..." #: ../../menuinfo.c:531 msgid "Print" msgstr "Imprimer" #: ../../menuinfo.c:532 ../../menuinfo.c:967 msgid "Print/Export Format" msgstr "Imprimer/Format d'exportation" #: ../../menuinfo.c:534 ../../menuinfo.c:969 msgid "Print/Export In Color" msgstr "Imprimer/Exporter en couleurs" #: ../../menuinfo.c:537 msgid "Print With Cmd..." msgstr "Imprimer avec la commande..." #: ../../menuinfo.c:540 msgid "Print Selected Objects" msgstr "Imprimer les objets sélectionnés" #: ../../menuinfo.c:547 msgid "GIF Animation" msgstr "Animation GIF" #: ../../menuinfo.c:550 msgid "Mime" msgstr "Mime" #: ../../menuinfo.c:554 msgid "Print Msg Buffer..." msgstr "Imprimer le buffer de messages..." #: ../../menuinfo.c:558 msgid "Set Export Pixel Trim..." msgstr "Set Export Pixel Trim..." #: ../../menuinfo.c:561 msgid "Set Template..." msgstr "Choisir un modèle..." #: ../../menuinfo.c:565 msgid "Return" msgstr "Retour" #: ../../menuinfo.c:566 msgid "Return submenu >>>" msgstr "Retour au sous-menu >>>" #: ../../menuinfo.c:567 msgid "Quit" msgstr "Quitter" #: ../../menuinfo.c:573 msgid "Precise Scale..." msgstr "Redimensionner précisément..." msgid "Precise Scale Everything..." msgstr "Tout redimensionner précisément..." #: ../../menuinfo.c:575 msgid "Precise Rotate..." msgstr "Faire tourner précisément..." #: ../../menuinfo.c:578 msgid "Restore Image Width & Height" msgstr "Restaurer hauteur et largeur d'image" #: ../../menuinfo.c:581 msgid "No Transform" msgstr "Pas de transformation" #: ../../menuinfo.c:590 msgid "Invert X Bitmap" msgstr "Inverser la Bitmap X" #: ../../menuinfo.c:592 msgid "Cut Bit/Pixmap..." msgstr "Couper Bit/Pixmap..." #: ../../menuinfo.c:594 msgid "Break Up Bit/Pixmap..." msgstr "Rompre Bit/Pixmap..." #: ../../menuinfo.c:598 msgid "Update EPS" msgstr "Mise à jour EPS" #: ../../menuinfo.c:606 msgid "Delete Point" msgstr "Supprimer le point" #: ../../menuinfo.c:608 msgid "Add Point" msgstr "Ajouter un point" #: ../../menuinfo.c:611 msgid "Convert Interpolated Spline" msgstr "Convertir la spline interpolée" #: ../../menuinfo.c:614 msgid "Smooth<->Hinge" msgstr "Courbe<->Angles" #: ../../menuinfo.c:618 msgid "Join Poly" msgstr "Joindre les polylignes" #: ../../menuinfo.c:620 msgid "Cut Poly" msgstr "Couper la polyligne" #: ../../menuinfo.c:628 msgid "Break Up Text" msgstr "Rompre le texte" #: ../../menuinfo.c:631 msgid "Set Text Fill Pattern Color" msgstr "Set Text Fill Pattern Color" #: ../../menuinfo.c:635 msgid "Insert Right Superscript" msgstr "Insérer exposant à droite" #: ../../menuinfo.c:638 msgid "Insert Right Subscript" msgstr "Insérer indice à droite" #: ../../menuinfo.c:641 msgid "Insert Left Superscript" msgstr "Insérer exposant à gauche" #: ../../menuinfo.c:644 msgid "Insert Left Subscript" msgstr "Insérer indice à gauche" #: ../../menuinfo.c:647 msgid "Insert Center Superscript" msgstr "Insérer au dessus" #: ../../menuinfo.c:650 msgid "Insert Center Subscript" msgstr "Insert au dessous" #: ../../menuinfo.c:654 msgid "Insert Thin Space..." msgstr "Insérer un espace mince..." #: ../../menuinfo.c:658 msgid "Insert Vertical Offset..." msgstr "Insérer un décalage vertical..." #: ../../menuinfo.c:661 msgid "Remove Vertical Offset..." msgstr "Supprimer le décalage vertical..." #: ../../menuinfo.c:665 msgid "Set Script Fraction" msgstr "Taille indice/exposant" #: ../../menuinfo.c:674 msgid "Input Poly Pts" msgstr "Entrer les points de la polyligne" #: ../../menuinfo.c:676 msgid "Input Polygon Pts" msgstr "Entrer les points du polygone" #: ../../menuinfo.c:679 msgid "Specify An Arc..." msgstr "Définir un arc..." #: ../../menuinfo.c:681 msgid "Make Regular Polygon..." msgstr "Créer un polygone régulier..." #: ../../menuinfo.c:684 msgid "Get Bounding Box" msgstr "Contour de l'objet" #: ../../menuinfo.c:694 msgid "Redraw" msgstr "Redessiner" #: ../../menuinfo.c:695 msgid "Duplicate" msgstr "Dupliquer" #: ../../menuinfo.c:697 msgid "Delete" msgstr "Supprimer" #: ../../menuinfo.c:698 msgid "Select All" msgstr "Sélectionner tout" #: ../../menuinfo.c:701 msgid "Undo" msgstr "Annuler" #: ../../menuinfo.c:702 msgid "Redo" msgstr "Refaire" #: ../../menuinfo.c:703 msgid "Flush Undo Buffer" msgstr "Vider le buffer d'annulation" #: ../../menuinfo.c:706 msgid "Copy" msgstr "Copier" #: ../../menuinfo.c:708 msgid "Copy Plain Text As Object" msgstr "Copier le texte en tant qu'objet" #: ../../menuinfo.c:711 msgid "Cut" msgstr "Couper" #: ../../menuinfo.c:712 msgid "Paste" msgstr "Coller" #: ../../menuinfo.c:713 msgid "Paste From File..." msgstr "Coller depuis le fichier..." #: ../../menuinfo.c:716 ../../menuinfo.c:1275 ../../menuinfo.c:1356 msgid "Shape" msgstr "Forme" #: ../../menuinfo.c:718 msgid "Set Shape Shadow..." msgstr "Définir l'ombre de la forme" #: ../../menuinfo.c:721 ../../menuinfo.c:1283 ../../menuinfo.c:1374 msgid "Image Proc" msgstr "Traitement d'image" #: ../../menuinfo.c:723 ../../menuinfo.c:1240 ../../menuinfo.c:1314 ../../menuinfo.c:1339 msgid "Properties" msgstr "Propriétés" #: ../../menuinfo.c:726 msgid "Transformation" msgstr "Transformation" #: ../../menuinfo.c:729 msgid "Bitmap/Pixmap/EPS" msgstr "Bitmap/Pixmap/EPS" #: ../../menuinfo.c:731 msgid "Poly/Polygon" msgstr "Polyligne/Polygone" #: ../../menuinfo.c:733 msgid "Text" msgstr "Texte" #: ../../menuinfo.c:734 msgid "Create Object" msgstr "Créer un objet" #: ../../menuinfo.c:737 msgid "Push Current Choice" msgstr "Sauver/restaurer le mode courant" #: ../../menuinfo.c:740 msgid "Find Case Sensitive..." msgstr "Rechercher (sensible à la casse)" #: ../../menuinfo.c:743 msgid "Find No Case..." msgstr "Rechercher (insensible à la casse)" #: ../../menuinfo.c:746 msgid "Find Again" msgstr "Rechercher à nouveau" #: ../../menuinfo.c:757 msgid "Align Objects Top" msgstr "Aligner les objets en haut" #: ../../menuinfo.c:759 msgid "Align Objects Middle" msgstr "Aligner les objets au milieu" #: ../../menuinfo.c:761 msgid "Align Objects Bottom" msgstr "Aligner les objets en bas" #: ../../menuinfo.c:763 msgid "Align Objects Left" msgstr "Aligner les objets à gauche" #: ../../menuinfo.c:765 msgid "Align Objects Center" msgstr "Aligner les objets au centre" #: ../../menuinfo.c:767 msgid "Align Objects Right" msgstr "Aligner les objets à droite" #: ../../menuinfo.c:775 msgid "Size To Widest" msgstr "Au plus large" #: ../../menuinfo.c:778 msgid "Size To Narrowest" msgstr "Au plus étroit" #: ../../menuinfo.c:781 msgid "Size To Tallest" msgstr "Au plus long" #: ../../menuinfo.c:784 msgid "Size To Shortest" msgstr "Au plus court" #: ../../menuinfo.c:788 msgid "Size To Given Width & Height..." msgstr "A largeur et hauteur données..." #: ../../menuinfo.c:791 msgid "Size To Given Width..." msgstr "A largeur donnée..." #: ../../menuinfo.c:794 msgid "Size To Given Height..." msgstr "A hauteur donnée..." #: ../../menuinfo.c:813 msgid "Front" msgstr "En avant" #: ../../menuinfo.c:815 msgid "Back" msgstr "En arrière" #: ../../menuinfo.c:817 msgid "Group" msgstr "Grouper" #: ../../menuinfo.c:819 msgid "UnGroup" msgstr "Séparer" #: ../../menuinfo.c:823 msgid "Lock" msgstr "Verrouiller" #: ../../menuinfo.c:825 msgid "UnLock" msgstr "Déverrouiller" #: ../../menuinfo.c:828 ../../menuinfo.c:1250 ../../menuinfo.c:1347 msgid "Horizontal Align" msgstr "Aligner horizontalement" #: ../../menuinfo.c:830 ../../menuinfo.c:1252 ../../menuinfo.c:1349 msgid "Vertical Align" msgstr "Aligner verticalement" #: ../../menuinfo.c:833 msgid "Align Objects" msgstr "Aligner les objets" #: ../../menuinfo.c:836 msgid "Align To Grid" msgstr "Aligner sur la grille" #: ../../menuinfo.c:839 msgid "Align To Page" msgstr "Aligner sur la page" #: ../../menuinfo.c:842 msgid "Align Objects Direct" msgstr "Aligner directement les objets" #: ../../menuinfo.c:844 msgid "Align To Grid Direct" msgstr "Aligner directement sur la grille" #: ../../menuinfo.c:846 msgid "Align To Page Direct" msgstr "Aligner directement sur la page" #: ../../menuinfo.c:848 msgid "More Object Alignments" msgstr "Plus d'alignements" #: ../../menuinfo.c:851 msgid "Size Objects" msgstr "Taille des objets" #: ../../menuinfo.c:854 msgid "Distribute Objects" msgstr "Distribuer les objets" #: ../../menuinfo.c:857 msgid "Distribute Objects Direct" msgstr "Distribuer directement les objets" #: ../../menuinfo.c:860 msgid "Layout On Arc" msgstr "Placer sur un arc" #: ../../menuinfo.c:862 msgid "Flip Horizontal" msgstr "Symétrie horizontale" #: ../../menuinfo.c:864 msgid "Flip Vertical" msgstr "Symétrie verticale" #: ../../menuinfo.c:867 msgid "Rotate Clock-Wise" msgstr "Rotation horaire" #: ../../menuinfo.c:869 msgid "Rotate Counter" msgstr "Rotation antihoraire" #: ../../menuinfo.c:872 msgid "Set Text Rotation..." msgstr "Rotation du texte..." #: ../../menuinfo.c:874 msgid "Set Rotation Increment..." msgstr "Définir le pas de rotation..." #: ../../menuinfo.c:877 msgid "Abut Horizontal" msgstr "Abut Horizontal" #: ../../menuinfo.c:879 msgid "Abut Vertical" msgstr "Abut Vertical" #: ../../menuinfo.c:882 msgid "Center An End Point" msgstr "Center An End Point" #: ../../menuinfo.c:891 msgid "Off" msgstr "Direct" #: ../../menuinfo.c:893 msgid "Jump" msgstr "Paliers" #: ../../menuinfo.c:895 msgid "Smooth" msgstr "Lisse" #: ../../menuinfo.c:902 msgid "Show Bit/Pixmap" msgstr "Montrer Bit/Pixmap" #: ../../menuinfo.c:906 msgid "Show Measurement" msgstr "Afficher les dimensions" #: ../../menuinfo.c:908 msgid "Set Measure Unit..." msgstr "Unité des dimensions..." #: ../../menuinfo.c:911 msgid "Show Menubar" msgstr "Afficher la barre de menu" #: ../../menuinfo.c:913 msgid "Show Status" msgstr "Afficher l'état" #: ../../menuinfo.c:920 ../../menuinfo.c:990 msgid "Slide Show" msgstr "Mode plein écran" #: ../../menuinfo.c:922 msgid "Set Slide Show Border Color..." msgstr "Couleur de bord en mode plein écran..." #: ../../menuinfo.c:925 msgid "Set Slide Show Window Offsets..." msgstr "Offset en mode plein écran..." #: ../../menuinfo.c:928 msgid "Visible Grid In Slide Show" msgstr "Grille visible en mode plein écran" #: ../../menuinfo.c:937 msgid "+Grid" msgstr "+Grille" #: ../../menuinfo.c:938 msgid "-Grid" msgstr "-Grille" #: ../../menuinfo.c:939 msgid "Visible Grid" msgstr "Grille visible" #: ../../menuinfo.c:940 msgid "Snap To Grid" msgstr "Coller à la grille" #: ../../menuinfo.c:943 msgid "Save Origin" msgstr "Enregistrer l'origine" #: ../../menuinfo.c:945 msgid "Scroll To Origin" msgstr "Aller à l'origine" #: ../../menuinfo.c:947 msgid "Scroll Mode" msgstr "Mode de défilement" #: ../../menuinfo.c:950 msgid "Zoom" msgstr "Zoom" msgid "Zoom In" msgstr "Agrandir" #: ../../menuinfo.c:951 msgid "Zoom Out" msgstr "Réduire" #: ../../menuinfo.c:952 msgid "Default Zoom" msgstr "Zoom par défaut" #: ../../menuinfo.c:953 msgid "Zoom Way Out" msgstr "Page" #: ../../menuinfo.c:964 ../../menuinfo.c:1247 ../../menuinfo.c:1345 msgid "Page Layout" msgstr "Mise en page" #: ../../menuinfo.c:973 msgid "Set Reduction..." msgstr "Définir la réduction..." #: ../../menuinfo.c:976 msgid "Metric Grid" msgstr "Grille métrique" #: ../../menuinfo.c:979 msgid "One Motion Select Move" msgstr "Sélectionner/déplacer en un clic" #: ../../menuinfo.c:982 msgid "Use Gray Scale" msgstr "Utiliser l'échelle de gris" #: ../../menuinfo.c:985 msgid "Use Color Layers" msgstr "Utiliser les calques de couleurs" #: ../../menuinfo.c:988 msgid "Show/Hide" msgstr "Afficher/Cacher" #: ../../menuinfo.c:998 msgid "Copy Properties..." msgstr "Attributs de copie..." #: ../../menuinfo.c:1001 msgid "Paste Properties..." msgstr "Attributs de collage..." #: ../../menuinfo.c:1004 msgid "Save Properties..." msgstr "Attributs d'enregistrement..." #: ../../menuinfo.c:1007 msgid "Restore Properties..." msgstr "Restaurer les propriétés..." #: ../../menuinfo.c:1011 msgid "Update Objects" msgstr "Mise à jour des objets" #: ../../menuinfo.c:1015 msgid "Set Selected Line Width..." msgstr "Epaisseur de la ligne sélectionnée..." #: ../../menuinfo.c:1018 msgid "Set Selected Font Size..." msgstr "Taille de la police sélectionnée..." #: ../../menuinfo.c:1021 msgid "Add Color..." msgstr "Ajouter une couleur..." #: ../../menuinfo.c:1024 msgid "Set Edit Text Size..." msgstr "Taille du texte à l'édition..." #: ../../menuinfo.c:1027 msgid "Set Alt Edit Text BgColor..." msgstr "Couleur de fond en mode Alt Edit Text..." #: ../../menuinfo.c:1030 msgid "Set Alt Edit Text Highlight Color..." msgstr "Couleur de la sélection en mode Alt Edit Text..." #: ../../menuinfo.c:1033 msgid "Use Alt Edit Text BgColor" msgstr "Mode Alt Edit Text" #: ../../menuinfo.c:1037 ../../menuinfo.c:1255 ../../menuinfo.c:1351 msgid "Font" msgstr "Police" #: ../../menuinfo.c:1039 ../../menuinfo.c:1256 ../../menuinfo.c:1352 msgid "Text Style" msgstr "Style du texte" #: ../../menuinfo.c:1041 ../../menuinfo.c:1258 ../../menuinfo.c:1354 msgid "Text Size" msgstr "Taille du texte" #: ../../menuinfo.c:1044 ../../menuinfo.c:1261 ../../menuinfo.c:1360 msgid "Line Dash" msgstr "Style de ligne" #: ../../menuinfo.c:1046 ../../menuinfo.c:1263 ../../menuinfo.c:1362 msgid "Line Style" msgstr "Type de ligne" #: ../../menuinfo.c:1048 ../../menuinfo.c:1265 ../../menuinfo.c:1364 msgid "Line Type" msgstr "Forme de ligne" #: ../../menuinfo.c:1050 ../../menuinfo.c:1267 ../../menuinfo.c:1366 msgid "Line Width" msgstr "Epaisseur de ligne" #: ../../menuinfo.c:1053 ../../menuinfo.c:1270 ../../menuinfo.c:1368 msgid "Fill" msgstr "Remplir" #: ../../menuinfo.c:1055 ../../menuinfo.c:1271 ../../menuinfo.c:1369 msgid "Pen" msgstr "Crayon" #: ../../menuinfo.c:1058 ../../menuinfo.c:1273 ../../menuinfo.c:1341 msgid "Move Mode" msgstr "Mode de déplacement" #: ../../menuinfo.c:1060 ../../menuinfo.c:1277 ../../menuinfo.c:1358 msgid "Stretchable Text" msgstr "Stretchable Text" #: ../../menuinfo.c:1063 ../../menuinfo.c:1279 ../../menuinfo.c:1370 msgid "Transparent Pattern" msgstr "Transparence" #: ../../menuinfo.c:1071 msgid "Go Back" msgstr "Précédent" #: ../../menuinfo.c:1072 msgid "Go Forward" msgstr "Suivant" #: ../../menuinfo.c:1074 msgid "Refresh Current" msgstr "Actualiser" #: ../../menuinfo.c:1077 msgid "Hot List..." msgstr "Favoris..." #: ../../menuinfo.c:1078 msgid "Add Current To Hot List" msgstr "Ajouter courant aux favoris" #: ../../menuinfo.c:1081 msgid "Session History..." msgstr "Historique de la session..." #: ../../menuinfo.c:1084 msgid "Hyper Space" msgstr "Hyper espace" #: ../../menuinfo.c:1092 msgid "Attach Attributes" msgstr "Attacher les attributs" #: ../../menuinfo.c:1095 msgid "Detach Attributes" msgstr "Détacher les attributs" #: ../../menuinfo.c:1099 msgid "Edit Attributes..." msgstr "Editer les attributs" #: ../../menuinfo.c:1103 msgid "Show Attributes" msgstr "Afficher les attributs" #: ../../menuinfo.c:1106 msgid "Show Attribute Names" msgstr "Afficher les noms des attributs" #: ../../menuinfo.c:1109 msgid "Hide Attributes" msgstr "Cacher les attributs" #: ../../menuinfo.c:1112 msgid "Hide Attribute Names" msgstr "Cacher les noms des attributs" #: ../../menuinfo.c:1116 msgid "Move/Justfy An Attribute" msgstr "Déplacer/Justifier un attribut" #: ../../menuinfo.c:1120 msgid "Import Attributes..." msgstr "Importer les attributs..." #: ../../menuinfo.c:1123 msgid "Export Attributes..." msgstr "Exporter les attributs..." #: ../../menuinfo.c:1132 msgid "Attach File Attributes" msgstr "Attacher les attributs de fichier" #: ../../menuinfo.c:1135 msgid "Detach File Attributes" msgstr "Détacher les attributs de fichier" #: ../../menuinfo.c:1139 msgid "Edit File Attributes..." msgstr "Editer les attributs de fichier..." #: ../../menuinfo.c:1148 msgid "Animate Send" msgstr "Animate Send" #: ../../menuinfo.c:1151 msgid "Animate Flash" msgstr "Animate Flash" #: ../../menuinfo.c:1160 msgid "Make Symbolic" msgstr "Faire symbole" #: ../../menuinfo.c:1163 msgid "UnMake Symbolic" msgstr "Défaire symbole" #: ../../menuinfo.c:1167 msgid "Instantiate..." msgstr "Instantier..." #: ../../menuinfo.c:1171 msgid "Make Iconic..." msgstr "Faire icône..." #: ../../menuinfo.c:1174 msgid "UnMake Iconic" msgstr "Défaire icône" #: ../../menuinfo.c:1178 msgid "Push" msgstr "Descendre" #: ../../menuinfo.c:1181 msgid "Pop" msgstr "Remonter" #: ../../menuinfo.c:1185 msgid "Attribute" msgstr "Attributs" #: ../../menuinfo.c:1187 msgid "File Attribute" msgstr "Attributs de fichier" #: ../../menuinfo.c:1190 msgid "Update Symbols" msgstr "Mise à jour des symboles" #: ../../menuinfo.c:1194 msgid "Misc" msgstr "Divers" #: ../../menuinfo.c:1197 msgid "Merge With Table..." msgstr "Fusionner avec la table..." #: ../../menuinfo.c:1200 msgid "Export To Table..." msgstr "Exporter dans la table..." #: ../../menuinfo.c:1204 msgid "Exec Cmds From File..." msgstr "Executer le fichier de commandes..." #: ../../menuinfo.c:1208 msgid "White-Board" msgstr "Tableau blanc" #: ../../menuinfo.c:1217 msgid "Latest Release Info" msgstr "Infos sur la dernière mise à jour" #: ../../menuinfo.c:1221 msgid "Copyright" msgstr "Copyright" #: ../../menuinfo.c:1223 msgid "About" msgstr "A propos" #: ../../menuinfo.c:1234 ../../menuinfo.c:1308 ../../menuinfo.c:1333 msgid "File" msgstr "Fichier" #: ../../menuinfo.c:1235 ../../menuinfo.c:1309 ../../menuinfo.c:1334 msgid "Edit" msgstr "Editer" #: ../../menuinfo.c:1236 ../../menuinfo.c:1310 ../../menuinfo.c:1335 msgid "Layout" msgstr "Mise en page" #: ../../menuinfo.c:1238 ../../menuinfo.c:1312 ../../menuinfo.c:1337 msgid "Arrange" msgstr "Arranger" #: ../../menuinfo.c:1286 ../../menuinfo.c:1316 ../../menuinfo.c:1372 msgid "Color" msgstr "Couleur" #: ../../menuinfo.c:1288 ../../menuinfo.c:1318 ../../menuinfo.c:1376 msgid "Navigate" msgstr "Navigation" #: ../../menuinfo.c:1290 ../../menuinfo.c:1320 ../../menuinfo.c:1378 msgid "Special" msgstr "Spécial" #: ../../menuinfo.c:1293 ../../menuinfo.c:1323 ../../menuinfo.c:1381 msgid "Tangram-II" msgstr "Tangram-II" #: ../../menuinfo.c:1296 ../../menuinfo.c:1326 ../../menuinfo.c:1384 msgid "Help" msgstr "Aide" #: ../../menuinfo.c:1343 msgid "Page" msgstr "Page" ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/fr/Imakefile����������������������������������������������������������������������0000644�0000764�0000764�00000002257�10064673302�015640� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#ifndef XCOMM #define XCOMM # #endif #ifndef NullParameter #define NullParameter #endif XCOMM XCOMM Author: Roland Baudin <roland.baudin@cnet.francetelecom.fr>, 2000 XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/fr/Imakefile,v 1.1 2004/06/18 23:12:02 william Exp $ XCOMM #include <../Po.tmpl> CURRENTDIR =./ SRCS = $(CURRENTDIR)*.po PACKAGE = tgif CATALOGS = fr.mo POFILES = fr.po POTFILES=../../menuinfo.c ../../strtbl.c .SUFFIXES: .SUFFIXES: .mo .po .po.mo: msgfmt -o $@ $< all:: $(CATALOGS) $(PACKAGE).pot: $(POTFILES) xgettext --default-domain=$(PACKAGE) \ --add-comments --keyword=_ --keyword=N_ $(POTFILES) if cmp -s $(PACKAGE).po $(PACKAGE).pot; then \ rm -f $(PACKAGE).po; \ else \ mv -f $(PACKAGE).po $(PACKAGE).pot; \ fi install:: $(CATALOGS) $(MKINSTALLDIRS) $(NLSDIR) chmod 755 $(NLSDIR) for n in $(CATALOGS) __DuMmY ; do \ if test "$$n" -a "$$n" != "__DuMmY" ; then \ l=`basename $$n .mo`; \ $(MKINSTALLDIRS) $(NLSDIR)/$$l/LC_MESSAGES; \ chmod 755 $(NLSDIR)/$$l; \ chmod 755 $(NLSDIR)/$$l/LC_MESSAGES; \ $(INSTALL) -m 644 $$n $(NLSDIR)/$$l/LC_MESSAGES/$(PACKAGE).mo; \ fi; \ done clean:: rm -f $(CATALOGS) �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/Po.tmpl���������������������������������������������������������������������������0000644�0000764�0000764�00000000463�10064673302�014671� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/Po.tmpl,v 1.1 2004/06/18 23:12:02 william Exp $ XCOMM INSTALL = install -c MKINSTALLDIRS = install -d DESTDIR = SYSNLSDIR = /usr/share/locale NLSDIR = $(DESTDIR)$(SYSNLSDIR) �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/HISTORY���������������������������������������������������������������������������0000644�0000764�0000764�00000001357�10064673302�014504� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������-----------------------> tgifnls-1.0.3 => tgifnls-1.0.4 <----------------------- 1) Added French support in the "fr" subdirectory. Thanks to Roland Baudin <roland.baudin@cnet.francetelecom.fr> for the contribution. -----------------------> tgifnls-1.0.0 => tgifnls-1.0.3 <----------------------- 1) Added Russian support in the "ru" subdirectory. Thanks to Vladimir Ignatov <gazett@mail.ru> for the contribution. 2) Update ja/ja.po for tgif-4.1.22. -----------------------> tgifnls-1.0.0 <----------------------- Initial release as part of tgif-4.1.5. Thanks to Jun Nishii <jun@flatout.org> of Project Vine for the contribution. /* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/HISTORY,v 1.1 2004/06/18 23:12:02 william Exp $ */ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/po/README����������������������������������������������������������������������������0000644�0000764�0000764�00000004725�10064673302�014302� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/po/README,v 1.1 2004/06/18 23:12:02 william Exp $ */ This is the README file for tgifintl -- tgif's native language support (NLS) message catalogs. The current release of tgif only supports native language in the menus (strings obtained from "menuinfo.c"). 1) Tgifintl is only useful for tgif-4.1.5 and above, and it is to be installed in the tgif source directory. For example, if your tgif is installed in ~/src/tgif/tgif-4.1.5 and you have tgifintl-1.0.0, do: cd ~/src/tgif/tgif-4.1.5 gunzip -c tgifintl-1.0.0.tar.gz | tar xvf - cd tgifintl-1.0.0 If you don't have tgif, please download tgif source from tgif's download link mentioned below. 2) Although Tgifintl-1.0.0 is release as part of tgif-4.1.5 (in the po subdirectory), tgifintl is maintained separately. The home page of tgifintl is: http://bourbon.cs.umd.edu:8001/tgif/tgifintl/ 3) Please copy Po.tmpl-PLATFORM to Po.tmpl (where PLATFORM depends on the platform you are on). For example, if you are on a Solaris platform, do: rm Po.tmpl cp Po.tmpl-solaris Po.tmpl The default Po.tmpl is identical to Po.tmpl-linux. There's only a few Po.tmpl-* files in the current release of tgifintl. More will be added when they become available. I only have access to limited number of platforms, so if you don't find your platform listed, please ask a local expert to modify Po.tmpl and send a working version to me so I can create new Po.tmpl-* files. 4) Modify lines in Po.tmpl to match your configuration. 5) If you want to compile all message catalogs, do: xmkmf make Makefile make Makefiles make depend make all make install If you only want to make one message catalog, say, the "ja" catalog, do: xmkmf make Makefile make Makefiles make depend cd ja make all make install cd .. 6) Tgif resources: Home Page: http://bourbon.cs.umd.edu:8001/tgif/ FAQ: http://bourbon.cs.umd.edu:8001/tgif/faq/ Current Release & Download: http://bourbon.cs.umd.edu:8001/tgif/current.html Join to Mailing List: kragen-tgif-subscribe@kragen.dnaco.net Mailing List: kragen-tgif@kragen.dnaco.net Bug Reports Send To: bill.cheng@acm.org �������������������������������������������tgif-QPL-4.2.5/aclocal.m4���������������������������������������������������������������������������0000644�0000764�0000764�00000077012�11602233371�014640� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# generated automatically by aclocal 1.10 -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, # 2005, 2006 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. m4_if(m4_PACKAGE_VERSION, [2.61],, [m4_fatal([this file was generated for autoconf 2.61. You have another version of autoconf. If you want to use that, you should regenerate the build system entirely.], [63])]) # Copyright (C) 2002, 2003, 2005, 2006 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_AUTOMAKE_VERSION(VERSION) # ---------------------------- # Automake X.Y traces this macro to ensure aclocal.m4 has been # generated from the m4 files accompanying Automake X.Y. # (This private macro should not be called outside this file.) AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version='1.10' dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to dnl require some minimum version. Point them to the right macro. m4_if([$1], [1.10], [], [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl ]) # _AM_AUTOCONF_VERSION(VERSION) # ----------------------------- # aclocal traces this macro to find the Autoconf version. # This is a private macro too. Using m4_define simplifies # the logic in aclocal, which can simply ignore this definition. m4_define([_AM_AUTOCONF_VERSION], []) # AM_SET_CURRENT_AUTOMAKE_VERSION # ------------------------------- # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. # This function is AC_REQUIREd by AC_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], [AM_AUTOMAKE_VERSION([1.10])dnl _AM_AUTOCONF_VERSION(m4_PACKAGE_VERSION)]) # AM_AUX_DIR_EXPAND -*- Autoconf -*- # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to # `$srcdir', `$srcdir/..', or `$srcdir/../..'. # # Of course, Automake must honor this variable whenever it calls a # tool from the auxiliary directory. The problem is that $srcdir (and # therefore $ac_aux_dir as well) can be either absolute or relative, # depending on how configure is run. This is pretty annoying, since # it makes $ac_aux_dir quite unusable in subdirectories: in the top # source directory, any form will work fine, but in subdirectories a # relative path needs to be adjusted first. # # $ac_aux_dir/missing # fails when called from a subdirectory if $ac_aux_dir is relative # $top_srcdir/$ac_aux_dir/missing # fails if $ac_aux_dir is absolute, # fails when called from a subdirectory in a VPATH build with # a relative $ac_aux_dir # # The reason of the latter failure is that $top_srcdir and $ac_aux_dir # are both prefixed by $srcdir. In an in-source build this is usually # harmless because $srcdir is `.', but things will broke when you # start a VPATH build or use an absolute $srcdir. # # So we could use something similar to $top_srcdir/$ac_aux_dir/missing, # iff we strip the leading $srcdir from $ac_aux_dir. That would be: # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` # and then we would define $MISSING as # MISSING="\${SHELL} $am_aux_dir/missing" # This will work as long as MISSING is not called from configure, because # unfortunately $(top_srcdir) has no meaning in configure. # However there are other variables, like CC, which are often used in # configure, and could therefore not use this "fixed" $ac_aux_dir. # # Another solution, used here, is to always expand $ac_aux_dir to an # absolute PATH. The drawback is that using absolute paths prevent a # configured tree to be moved without reconfiguration. AC_DEFUN([AM_AUX_DIR_EXPAND], [dnl Rely on autoconf to set up CDPATH properly. AC_PREREQ([2.50])dnl # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` ]) # AM_CONDITIONAL -*- Autoconf -*- # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 8 # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], [AC_PREREQ(2.52)dnl ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl AC_SUBST([$1_TRUE])dnl AC_SUBST([$1_FALSE])dnl _AM_SUBST_NOTMAKE([$1_TRUE])dnl _AM_SUBST_NOTMAKE([$1_FALSE])dnl if $2; then $1_TRUE= $1_FALSE='#' else $1_TRUE='#' $1_FALSE= fi AC_CONFIG_COMMANDS_PRE( [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then AC_MSG_ERROR([[conditional "$1" was never defined. Usually this means the macro was only invoked conditionally.]]) fi])]) # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 9 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be # written in clear, in which case automake, when reading aclocal.m4, # will think it sees a *use*, and therefore will trigger all it's # C support machinery. Also note that it means that autoscan, seeing # CC etc. in the Makefile, will ask for an AC_PROG_CC use... # _AM_DEPENDENCIES(NAME) # ---------------------- # See how the compiler implements dependency checking. # NAME is "CC", "CXX", "GCJ", or "OBJC". # We try a few techniques and use that to set a single cache variable. # # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular # dependency, and given that the user is not expected to run this macro, # just rely on AC_PROG_CC. AC_DEFUN([_AM_DEPENDENCIES], [AC_REQUIRE([AM_SET_DEPDIR])dnl AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl AC_REQUIRE([AM_MAKE_INCLUDE])dnl AC_REQUIRE([AM_DEP_TRACK])dnl ifelse([$1], CC, [depcc="$CC" am_compiler_list=], [$1], CXX, [depcc="$CXX" am_compiler_list=], [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], [$1], UPC, [depcc="$UPC" am_compiler_list=], [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], [depcc="$$1" am_compiler_list=]) AC_CACHE_CHECK([dependency style of $depcc], [am_cv_$1_dependencies_compiler_type], [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_$1_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_$1_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_$1_dependencies_compiler_type=none fi ]) AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) AM_CONDITIONAL([am__fastdep$1], [ test "x$enable_dependency_tracking" != xno \ && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) ]) # AM_SET_DEPDIR # ------------- # Choose a directory name for dependency files. # This macro is AC_REQUIREd in _AM_DEPENDENCIES AC_DEFUN([AM_SET_DEPDIR], [AC_REQUIRE([AM_SET_LEADING_DOT])dnl AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl ]) # AM_DEP_TRACK # ------------ AC_DEFUN([AM_DEP_TRACK], [AC_ARG_ENABLE(dependency-tracking, [ --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors]) if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) AC_SUBST([AMDEPBACKSLASH])dnl _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl ]) # Generate code to set up dependency tracking. -*- Autoconf -*- # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. #serial 3 # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [for mf in $CONFIG_FILES; do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # Grep'ing the whole file is not good either: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. if sed 10q "$mf" | grep '^#.*generated by automake' > /dev/null 2>&1; then dirpart=`AS_DIRNAME("$mf")` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`AS_DIRNAME(["$file"])` AS_MKDIR_P([$dirpart/$fdir]) # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done ])# _AM_OUTPUT_DEPENDENCY_COMMANDS # AM_OUTPUT_DEPENDENCY_COMMANDS # ----------------------------- # This macro should only be invoked once -- use via AC_REQUIRE. # # This code is only required when automatic dependency tracking # is enabled. FIXME. This creates each `.P' file that we will # need in order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) ]) # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 8 # AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS. AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)]) # Do all the work for Automake. -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, # 2005, 2006 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 12 # This macro actually does too much. Some checks are only needed if # your package does certain things. But this isn't really a big deal. # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) # AM_INIT_AUTOMAKE([OPTIONS]) # ----------------------------------------------- # The call with PACKAGE and VERSION arguments is the old style # call (pre autoconf-2.50), which is being phased out. PACKAGE # and VERSION should now be passed to AC_INIT and removed from # the call to AM_INIT_AUTOMAKE. # We support both call styles for the transition. After # the next Automake release, Autoconf can make the AC_INIT # arguments mandatory, and then we can depend on a new Autoconf # release and drop the old call support. AC_DEFUN([AM_INIT_AUTOMAKE], [AC_PREREQ([2.60])dnl dnl Autoconf wants to disallow AM_ names. We explicitly allow dnl the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl AC_REQUIRE([AC_PROG_INSTALL])dnl if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl # test to see if srcdir already configured if test -f $srcdir/config.status; then AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) fi fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi AC_SUBST([CYGPATH_W]) # Define the identity of the package. dnl Distinguish between old-style and new-style calls. m4_ifval([$2], [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl AC_SUBST([PACKAGE], [$1])dnl AC_SUBST([VERSION], [$2])], [_AM_SET_OPTIONS([$1])dnl dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, [m4_fatal([AC_INIT should be called with package and version arguments])])dnl AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl _AM_IF_OPTION([no-define],, [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl # Some tools Automake needs. AC_REQUIRE([AM_SANITY_CHECK])dnl AC_REQUIRE([AC_ARG_PROGRAM])dnl AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) AM_MISSING_PROG(AUTOCONF, autoconf) AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) AM_MISSING_PROG(AUTOHEADER, autoheader) AM_MISSING_PROG(MAKEINFO, makeinfo) AM_PROG_INSTALL_SH AM_PROG_INSTALL_STRIP AC_REQUIRE([AM_PROG_MKDIR_P])dnl # We need awk for the "check" target. The system "awk" is bad on # some platforms. AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AM_SET_LEADING_DOT])dnl _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], [_AM_PROG_TAR([v7])])]) _AM_IF_OPTION([no-dependencies],, [AC_PROVIDE_IFELSE([AC_PROG_CC], [_AM_DEPENDENCIES(CC)], [define([AC_PROG_CC], defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl AC_PROVIDE_IFELSE([AC_PROG_CXX], [_AM_DEPENDENCIES(CXX)], [define([AC_PROG_CXX], defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl AC_PROVIDE_IFELSE([AC_PROG_OBJC], [_AM_DEPENDENCIES(OBJC)], [define([AC_PROG_OBJC], defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl ]) ]) # When config.status generates a header, we must update the stamp-h file. # This file resides in the same directory as the config header # that is generated. The stamp files are numbered to have different names. # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the # loop where config.status creates the headers, so we can generate # our stamp files there. AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], [# Compute $1's index in $config_headers. _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $1 | $1:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count]) # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_SH # ------------------ # Define $install_sh. AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"} AC_SUBST(install_sh)]) # Copyright (C) 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 2 # Check whether the underlying file-system supports filenames # with a leading dot. For instance MS-DOS doesn't. AC_DEFUN([AM_SET_LEADING_DOT], [rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null AC_SUBST([am__leading_dot])]) # Check to see how 'make' treats includes. -*- Autoconf -*- # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 3 # AM_MAKE_INCLUDE() # ----------------- # Check to see how make treats includes. AC_DEFUN([AM_MAKE_INCLUDE], [am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo done .PHONY: am__doit END # If we don't find an include directive, just comment out the code. AC_MSG_CHECKING([for style of include used by $am_make]) am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # We grep out `Entering directory' and `Leaving directory' # messages which can occur if `w' ends up in MAKEFLAGS. # In particular we don't look at `^make:' because GNU make might # be invoked under some other name (usually "gmake"), in which # case it prints its new name instead of `make'. if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then am__include=include am__quote= _am_result=GNU fi # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then am__include=.include am__quote="\"" _am_result=BSD fi fi AC_SUBST([am__include]) AC_SUBST([am__quote]) AC_MSG_RESULT([$_am_result]) rm -f confinc confmf ]) # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 5 # AM_MISSING_PROG(NAME, PROGRAM) # ------------------------------ AC_DEFUN([AM_MISSING_PROG], [AC_REQUIRE([AM_MISSING_HAS_RUN]) $1=${$1-"${am_missing_run}$2"} AC_SUBST($1)]) # AM_MISSING_HAS_RUN # ------------------ # Define MISSING if not defined so far and test if it supports --run. # If it does, set am_missing_run to use it, otherwise, to nothing. AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl AC_REQUIRE_AUX_FILE([missing])dnl test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= AC_MSG_WARN([`missing' script is too old or missing]) fi ]) # Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_MKDIR_P # --------------- # Check for `mkdir -p'. AC_DEFUN([AM_PROG_MKDIR_P], [AC_PREREQ([2.60])dnl AC_REQUIRE([AC_PROG_MKDIR_P])dnl dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, dnl while keeping a definition of mkdir_p for backward compatibility. dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of dnl Makefile.ins that do not define MKDIR_P, so we do our own dnl adjustment using top_builddir (which is defined more often than dnl MKDIR_P). AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl case $mkdir_p in [[\\/$]]* | ?:[[\\/]]*) ;; */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; esac ]) # Helper functions for option handling. -*- Autoconf -*- # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 3 # _AM_MANGLE_OPTION(NAME) # ----------------------- AC_DEFUN([_AM_MANGLE_OPTION], [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) # _AM_SET_OPTION(NAME) # ------------------------------ # Set option NAME. Presently that only means defining a flag for this option. AC_DEFUN([_AM_SET_OPTION], [m4_define(_AM_MANGLE_OPTION([$1]), 1)]) # _AM_SET_OPTIONS(OPTIONS) # ---------------------------------- # OPTIONS is a space-separated list of Automake options. AC_DEFUN([_AM_SET_OPTIONS], [AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) # ------------------------------------------- # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) # Check to make sure that the build environment is sane. -*- Autoconf -*- # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 4 # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane]) # Just in case sleep 1 echo timestamp > conftest.file # Do `set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` if test "$[*]" = "X"; then # -L didn't work. set X `ls -t $srcdir/configure conftest.file` fi rm -f conftest.file if test "$[*]" != "X $srcdir/configure conftest.file" \ && test "$[*]" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken alias in your environment]) fi test "$[2]" = conftest.file ) then # Ok. : else AC_MSG_ERROR([newly created file is older than distributed files! Check your system clock]) fi AC_MSG_RESULT(yes)]) # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_STRIP # --------------------- # One issue with vendor `install' (even GNU) is that you can't # specify the program used to strip binaries. This is especially # annoying in cross-compiling environments, where the build's strip # is unlikely to handle the host's binaries. # Fortunately install-sh will honor a STRIPPROG variable, so we # always use install-sh in `make install-strip', and initialize # STRIPPROG with the value of the STRIP variable (set by the user). AC_DEFUN([AM_PROG_INSTALL_STRIP], [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl # Installed binaries are usually stripped using `strip' when the user # run `make install-strip'. However `strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the `STRIP' environment variable to overrule this program. dnl Don't test for $cross_compiling = yes, because it might be `maybe'. if test "$cross_compiling" != no; then AC_CHECK_TOOL([STRIP], [strip], :) fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) # Copyright (C) 2006 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # _AM_SUBST_NOTMAKE(VARIABLE) # --------------------------- # Prevent Automake from outputing VARIABLE = @VARIABLE@ in Makefile.in. # This macro is traced by Automake. AC_DEFUN([_AM_SUBST_NOTMAKE]) # Check how to create a tarball. -*- Autoconf -*- # Copyright (C) 2004, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 2 # _AM_PROG_TAR(FORMAT) # -------------------- # Check how to create a tarball in format FORMAT. # FORMAT should be one of `v7', `ustar', or `pax'. # # Substitute a variable $(am__tar) that is a command # writing to stdout a FORMAT-tarball containing the directory # $tardir. # tardir=directory && $(am__tar) > result.tar # # Substitute a variable $(am__untar) that extract such # a tarball read from stdin. # $(am__untar) < result.tar AC_DEFUN([_AM_PROG_TAR], [# Always define AMTAR for backward compatibility. AM_MISSING_PROG([AMTAR], [tar]) m4_if([$1], [v7], [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], [m4_case([$1], [ustar],, [pax],, [m4_fatal([Unknown tar format])]) AC_MSG_CHECKING([how to create a $1 tar archive]) # Loop over all known methods to create a tar archive until one works. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' _am_tools=${am_cv_prog_tar_$1-$_am_tools} # Do not fold the above two line into one, because Tru64 sh and # Solaris sh will not grok spaces in the rhs of `-'. for _am_tool in $_am_tools do case $_am_tool in gnutar) for _am_tar in tar gnutar gtar; do AM_RUN_LOG([$_am_tar --version]) && break done am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' am__untar="$_am_tar -xf -" ;; plaintar) # Must skip GNU tar: if it does not support --format= it doesn't create # ustar tarball either. (tar --version) >/dev/null 2>&1 && continue am__tar='tar chf - "$$tardir"' am__tar_='tar chf - "$tardir"' am__untar='tar xf -' ;; pax) am__tar='pax -L -x $1 -w "$$tardir"' am__tar_='pax -L -x $1 -w "$tardir"' am__untar='pax -r' ;; cpio) am__tar='find "$$tardir" -print | cpio -o -H $1 -L' am__tar_='find "$tardir" -print | cpio -o -H $1 -L' am__untar='cpio -i -H $1 -d' ;; none) am__tar=false am__tar_=false am__untar=false ;; esac # If the value was cached, stop now. We just wanted to have am__tar # and am__untar set. test -n "${am_cv_prog_tar_$1}" && break # tar/untar a dummy directory, and stop if the command works rm -rf conftest.dir mkdir conftest.dir echo GrepMe > conftest.dir/file AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) rm -rf conftest.dir if test -s conftest.tar; then AM_RUN_LOG([$am__untar <conftest.tar]) grep GrepMe conftest.dir/file >/dev/null 2>&1 && break fi done rm -rf conftest.dir AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) AC_MSG_RESULT([$am_cv_prog_tar_$1])]) AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgif_dbg.h���������������������������������������������������������������������������0000644�0000764�0000764�00000010217�11602233313�014704� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgif_dbg.h,v 1.6 2011/05/16 16:22:00 william Exp $ */ #ifndef _TGIF_DBG_H_ #ifdef _TGIF_DBG #include <X11/Xlib.h> #include <X11/Xutil.h> #include <X11/cursorfont.h> #include <X11/keysym.h> extern void tgif_dbg_add_to_log ARGS_DECL((char*)); extern void tgif_dbg_enable ARGS_DECL((int)); extern void got_trigger ARGS_DECL((int)); extern void tgif_track ARGS_DECL((int)); extern void tgif_dbg_dump_count ARGS_DECL((char*)); extern int gnAllocTrigger; extern int gnFreeTrigger; extern void *tgif_malloc ARGS_DECL((size_t)); extern void *tgif_realloc ARGS_DECL((void*, size_t)); extern void tgif_free ARGS_DECL((void*)); extern size_t tgif_strlen ARGS_DECL((char*)); extern GC Tgif_XCreateGC ARGS_DECL((Display*, Drawable, unsigned long, XGCValues*)); extern void Tgif_XFreeGC ARGS_DECL((Display*, GC)); extern XImage *Tgif_XCreateImage ARGS_DECL((Display*, Visual*, unsigned int, int, int, char*, unsigned int, unsigned int, int, int)); extern XImage *Tgif_XGetImage ARGS_DECL((Display*, Drawable, int, int, unsigned int, unsigned int, unsigned long, int)); extern void Tgif_XDestroyImage ARGS_DECL((XImage*)); extern Cursor Tgif_XCreateFontCursor ARGS_DECL((Display*, unsigned int)); extern Cursor Tgif_XCreatePixmapCursor ARGS_DECL((Display*, Pixmap, Pixmap, XColor*, XColor*, unsigned int, unsigned int)); extern void Tgif_XFreeCursor ARGS_DECL((Display*, Cursor)); extern Pixmap Tgif_XCreatePixmap ARGS_DECL((Display*, Drawable, unsigned int, unsigned int, unsigned int)); extern Pixmap Tgif_XCreateBitmapFromData ARGS_DECL((Display*, Drawable, _Xconst char*, unsigned int, unsigned int)); extern int Tgif_XReadBitmapFile ARGS_DECL((Display*, Drawable, _Xconst char*, unsigned int *, unsigned int *, Pixmap*, int*, int*)); extern void Tgif_XFreePixmap ARGS_DECL((Display*, Pixmap)); extern char *Tgif_XFetchBytes ARGS_DECL((Display*, int*)); extern Status Tgif_XQueryTree ARGS_DECL((Display*, Window, Window*, Window*, Window**, unsigned int*)); extern char *Tgif_XGetAtomName ARGS_DECL((Display*, Atom)); extern Colormap *Tgif_XListInstalledColormaps ARGS_DECL((Display*, Window, int*)); extern void Tgif_XFree ARGS_DECL((void*)); /* -------------------- defines -------------------- */ #ifndef PRTGIF_NO_TGIF_DBG #ifdef malloc #undef malloc #endif /* malloc */ #ifdef realloc #undef realloc #endif /* realloc */ #ifdef free #undef free #endif /* free */ #ifdef strlen #undef strlen #endif /* strlen */ #define malloc tgif_malloc #define realloc tgif_realloc #define free tgif_free #define strlen tgif_strlen #define XCreateGC Tgif_XCreateGC #define XFreeGC Tgif_XFreeGC #define XCreateImage Tgif_XCreateImage #define XGetImage Tgif_XGetImage #undef XDestroyImage #define XDestroyImage Tgif_XDestroyImage #define XCreateFontCursor Tgif_XCreateFontCursor #define XCreatePixmapCursor Tgif_XCreatePixmapCursor #define XFreeCursor Tgif_XFreeCursor #define XCreatePixmap Tgif_XCreatePixmap #define XCreateBitmapFromData Tgif_XCreateBitmapFromData #define XReadBitmapFile Tgif_XReadBitmapFile #define XFreePixmap Tgif_XFreePixmap #define XFetchBytes Tgif_XFetchBytes #define XQueryTree Tgif_XQueryTree #define XGetAtomName Tgif_XGetAtomName #define XListInstalledColormaps Tgif_XListInstalledColormaps #define XFree Tgif_XFree #endif /* ~PRTGIF_NO_TGIF_DBG */ #endif /* _TGIF_DBG */ #endif /* ~_TGIF_DBG_H_ */ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tdgtbtn.e����������������������������������������������������������������������������0000644�0000764�0000764�00000005106�11602233313�014603� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtbtn.e,v 1.6 2011/05/16 16:22:00 william Exp $ */ #ifndef _TDGTBTN_E_ #define _TDGTBTN_E_ #include "tidget.h" #define TDGTBTN_DEF_H_PAD 0 #define TDGTBTN_DEF_V_PAD 0 #define TDGTBTN_CLICK 0 #define TDGTBTN_STICKY 1 typedef struct tagTdgtBtn { TidgetInfo *pti; int btn_type; /* TGMUTYPE_TEXT, TGMUTYPE_COLOR, or TGMUTYPE_BITMAP */ int btn_style; /* TDGTBTN_CLICK or TDGTBTN_STICKY */ int font_style; /* STYLE_NR, STYLE_BR, STYLE_NI, STYLE_BI */ /* * for TGMUTYPE_TEXT, str is (char*), point to a string * for TGMUTYPE_COLOR, str is (int), point to a color index * for TGMUTYPE_BITMAP, str is (Pixmap*), point to a pixmap */ char *str; MouseOverStatusInfo mosi; } TdgtBtn; #ifdef _INCLUDE_FROM_TDGTBTN_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TDGTBTN_C_*/ extern void CalcTdgtBtnDim ARGS_DECL((char *text, int min_len, int h_pad, int v_pad, int *pn_width, int *pn_height)); extern void TdgtBtnReset ARGS_DECL((TdgtBtn*)); extern TdgtBtn *CreateTdgtBtn ARGS_DECL((Window parent_win, TidgetInfo *parent_tidgetinfo, int ctl_id, int x, int y, int w, int h, int h_pad, int v_pad, int btn_type, int btn_style, int state, int font_style, char *str, MouseOverStatusInfo *pmosi)); extern int TdgtBtnSetText ARGS_DECL((TdgtBtn*, char *str, MouseOverStatusInfo *pmosi)); extern char *TdgtBtnGetText ARGS_DECL((TdgtBtn*)); extern int TdgtBtnSetState ARGS_DECL((TdgtBtn*, int)); extern int TdgtBtnGetState ARGS_DECL((TdgtBtn*)); extern int InitTdgtBtn ARGS_DECL((void)); extern void CleanUpTdgtBtn ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TDGTBTN_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TDGTBTN_C_*/ #endif /*_TDGTBTN_E_*/ ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/expfdefs.h���������������������������������������������������������������������������0000644�0000764�0000764�00000020052�11602233311�014737� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/expfdefs.h,v 1.6 2011/05/16 16:21:57 william Exp $ */ #ifndef _EXPFDEFS_H_ #define _EXPFDEFS_H_ /* * A tgif export filter is a shared library having a name like * lib<name>.so.<ver> where <name> names the export filter type * and <ver> is a ``protocol version''. * * The main entry point of the shared library must be: * * long TgifExportFilterMain( * TGEF_USER_INFO *ppUserInfo; * int nMsg; * int nArg; * void *pvArg * ); * * *ppUserInfo is a place to hang internal data for the export filter * nMsg is the message type, which is one of TGEF_MSG_* * nArg and pvArg are arguments for a message */ #include "tgifdefs.h" #ifdef _DL_EXPORT_UNDERSCORE #define TGEF_MAIN_NAME "_TgifExportFilterMain" #else /* ~_DL_EXPORT_UNDERSCORE */ #define TGEF_MAIN_NAME "TgifExportFilterMain" #endif /* _DL_EXPORT_UNDERSCORE */ typedef void *TGEF_USER_INFO; typedef long (TGEF_MAIN)ARGS_DECL((TGEF_USER_INFO*, int, int, void*)); typedef int (MsgBoxFunc)ARGS_DECL((char*, char*, int)); typedef int (DialogFunc)ARGS_DECL((char*, char*, char*)); typedef int (FailAllocMessageFunc)ARGS_DECL((void)); typedef int (UtilCopyFileFunc)ARGS_DECL((char *pszFromFile, char *pszToFile)); typedef int (ObjInVisibleLayerFunc)ARGS_DECL((struct ObjRec *)); typedef char *(UtilStrDupFunc)ARGS_DECL((char*)); typedef void (UtilFreeFunc)ARGS_DECL((char*)); typedef void (MsgFunc)ARGS_DECL((char*)); typedef void (SetStringStatusFunc)ARGS_DECL((char*)); typedef void (UtilTrimBlanksFunc)ARGS_DECL((char*)); typedef void (DynStrSetFunc)ARGS_DECL((struct DynStrRec *, char*)); typedef struct tagTgEFProtocolInfo_1 { /* in */ Display *dpy; /* in */ Window win; /* in */ char sz_sl_path[MAXPATHLENGTH]; /* in */ NLFN *pfnMsgBox; /* in */ NLFN *pfnDialog; /* in */ NLFN *pfnFailAllocMessage; /* in */ NLFN *pfnUtilCopyFile; /* in */ NLFN *pfnObjInVisibleLayer; /* in */ NLFN *pfnUtilStrDup; /* in */ VDFN *pfnUtilFree; /* in */ VDFN *pfnMsg; /* in */ VDFN *pfnSetStringStatus; /* in */ VDFN *pfnUtilTrimBlanks; /* in */ VDFN *pfnDynStrSet; /* Must fill in the following information in response to TGEF_MSG_LOAD: */ /* out */ char *bm_bits; /* out */ int bm_width; /* out */ int bm_height; /* out */ char color_format_name[14]; /* format name */ /* out */ char bw_format_name[14]; /* format name */ /* out */ char color_ext[14]; /* file extension */ /* out */ char bw_ext[14]; /* file extension */ /* out */ int capability; /* TGEF_CAP_* */ /* These are filled in when TGEF_MSG_DO_EXPORT is sent */ /* in */ FILE *fp; /* in */ int color_dump; /* in */ int color_layers; /* in */ int printing_page_num; /* in */ int printing_first_page_num; /* in */ int printing_page_row; /* in */ int printing_page_col; /* in */ int page_layout_mode; /* in */ int last_page_num; /* in */ struct ObjRec *top_obj; /* in */ struct ObjRec *bot_obj; /* out */ int write_file_failed; } TgEFProtocolInfo_1; typedef struct tagTgEFInfo { TGEF_USER_INFO pTgEFUserInfo; TGEF_MAIN *pfnTgEFMain; void *pSharedLibHandle; char *pszSharedLibPath; int nSharedLibVersion; union { TgEFProtocolInfo_1 stProtocolInfo_1; } detail; } TgEFInfo; /* Used by tgif only. Not to be used by any export filter. */ #define TGEF_STATUS_OK 0 #define TGEF_STATUS_UNKNOWN 1 #define TGEF_STATUS_INVALID_ARGS 2 #define TGEF_STATUS_MALLOC 3 /* * capability * * Use TGEF_CAP_SINGLE_PAGE if the file format is EPS-like where * it doesn't make sense to have a multi-page output. * Otherwise, use TGEF_CAP_MULTI_PAGE. */ #define TGEF_CAP_SINGLE_PAGE 0x0000 /* cannot handle multi-pg drawing */ #define TGEF_CAP_MULTI_PAGE 0x0001 /* handle multi-pg drawing */ /* * message types */ #define TGEF_MSG_INIT 0 #define TGEF_MSG_GET_PROTOCOL_VERSION 1 #define TGEF_MSG_LOAD 2 #define TGEF_MSG_UNLOAD 3 #define TGEF_MSG_CLEANUP 4 #define TGEF_MSG_DO_EXPORT 10 /* * Basic messages: * * TGEF_MSG_INIT, TGEF_MSG_GET_PROTOCOL_VERSION, TGEF_MSG_LOAD, * TGEF_MSG_UNLOAD, and TGEF_MSG_CLEANUP are basic messages. * * They are called in the following sequence: * * In InitExportFilters() of "xprtfltr.c": * * TGEF_MSG_INIT * TGEF_MSG_GET_PROTOCOL_VERSION * TGEF_MSG_LOAD * * In DoGenDump() of "file.c": * * Other non-basic messages are sent to do the actual exporting. * * In CleanUpExportFilters() of "xprtfltr.c": * * TGEF_MSG_UNLOAD * TGEF_MSG_CLEANUP * * TGEF_MSG_INIT: * On entry: * *ppUserInfo is set to NULL, nArg = 0, pvArg = NULL * On return: * If returns anything other than TGEF_STATUS_OK, the shared * library is unloaded. * Note: * No memory allocation should be performed in the message * handler of this message! If you want to allocate memory, * do it in TGEF_MSG_LOAD. * * TGEF_MSG_GET_PROTOCOL_VERSION: * On entry: * nArg = 0, pvArg = NULL * On return: * The returned value should be an integer specifying the * protocol version this export filter implements. Please * note that if the returned value is different from the * <ver> part of the "lib<name>.so.<ver>", TGEF_MSG_CLEANUP * will be sent immediately. * * TGEF_MSG_LOAD: * On entry: * *ppUserInfo is set to NULL, nArg = 0, pvArg is a pointer to * TgEFProtocolInfo_<ver> where <ver> is the returned value * of the TGEF_MSG_GET_PROTOCOL_VERSION message. * On return: * If returns anything other than TGEF_STATUS_OK, the shared * library is unloaded. * If returns TGEF_STATUS_OK, *ppUserInfo can be used to hang * internal data for the export filter. Tgif will not * touch *ppUserInfo from this point on until after the * call with message type TGEF_MSG_UNLOAD. * * TGEF_MSG_UNLOAD: * On entry: * ppUserInfo = what's set in TGEF_MSG_LOAD, nArg = 0, pvArg = NULL * On return: * *ppUserInfo will be set to NULL immediately afterwards. * Note: * The message handler should free up allocated memory. * * TGEF_MSG_CLEANUP: * On entry: * ppUserInfo = NULL, nArg = 0, pvArg = NULL * On return: * The shared library is unloaded and the returned value is ignored. * Note: * No memory deallocation should be performed in the message * handler of this message! If you want to deallocate memory, * do it in TGEF_MSG_UNLOAD. * Usually, there's no need to handle this message if the shared * library can be simply unloaded. * */ /* * TGEF_MSG_DO_EXPORT: * On entry: * ppUserInfo = what's set in TGEF_MSG_LOAD, nArg = 0, pvArg is a * pointer to TgEFProtocolInfo_<ver> where <ver> is the returned * value of the TGEF_MSG_GET_PROTOCOL_VERSION message. * On return: * Should return TGEF_STATUS_OK if everything is okay. */ #endif /*_EXPFDEFS_H_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/z_intrf.e����������������������������������������������������������������������������0000644�0000764�0000764�00000003225�11602233314�014611� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/z_intrf.e,v 1.7 2011/05/16 16:22:00 william Exp $ */ #ifndef _Z_INTRF_E_ #define _Z_INTRF_E_ #ifdef _INCLUDE_FROM_Z_INTRF_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_Z_INTRF_C_*/ extern int HasZlibSupport ARGS_DECL((void)); extern int DeflateFile ARGS_DECL((char *fname, char *deflated_fname)); extern int DoDeflate ARGS_DECL((FILE *in_fp, char *in_buf, int bytes_left, FILE *out_fp, int use_def_compression, int use_byte_stuffing, int *pn_rc)); extern int DoInflate ARGS_DECL((char *in_buf, int bytes_left, FILE *out_fp, int use_byte_unstuffing, int *pn_rc)); extern void ZlibError ARGS_DECL((int status, int deflate)); #ifdef _INCLUDE_FROM_Z_INTRF_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_Z_INTRF_C_*/ #endif /*_Z_INTRF_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/setup.e������������������������������������������������������������������������������0000644�0000764�0000764�00000012476�11602233312�014304� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/setup.e,v 1.14 2011/05/16 16:21:59 william Exp $ */ #ifndef _SETUP_E_ #define _SETUP_E_ extern int debugNoPointerGrab; extern int debugCopyPaste; extern unsigned int mainWinW; extern unsigned int mainWinH; extern int vSBarH; extern int hSBarW; extern int scrollBarW; extern int rulerW; extern int brdrW; extern int windowPadding; extern int pageWindowW; extern int pageDummyWindowW; extern int colorWindowH; extern int colorDummyWindowH; extern int msgWindowW; extern int msgWindowH; extern int choiceImageW; extern int choiceImageH; extern int choiceWindowW; extern int choiceWindowH; extern int menuImageW; extern int menuImageH; extern int titleWindowW; extern int titleWindowH; extern int iconWindowW; extern int iconWindowH; extern int menubarWindowW; extern int menubarWindowH; extern int userRedrawWindowW; extern int userRedrawWindowH; extern int statusWindowW; extern int statusWindowH; extern int statusSubWindowW[]; extern int statusSubWindowH[]; extern int modeWindowW; extern int modeWindowH; extern int chatWindowW; extern int chatWindowH; extern int initialMenubarWindowH; extern Display * mainDisplay; extern Colormap mainColormap; extern unsigned int mainDepth; extern int mainScreen; extern Visual * mainVisual; extern Window rootWindow; extern Window mainWindow; extern Window drawWindow; extern Window choiceWindow; extern Window titleWindow; extern Window msgWindow; extern Window vSBarWindow; extern Window hSBarWindow; extern Window vRuleWindow; extern Window hRuleWindow; extern Window iconWindow; extern Window iconBaseWindow; extern Window menubarWindow; extern Window userRedrawWindow; extern Window statusWindow; extern Window modeWindow; extern Window pageWindow; extern Window pageDummyWindow; extern Window colorWindow; extern Window colorDummyWindow; extern Window chatWindow; extern int paperWidth; extern int paperHeight; extern int onePageWidth; extern int onePageHeight; extern int drawOrigX; extern int drawOrigY; extern int drawWinW; extern int drawWinH; extern int zoomScale; extern int zoomedIn; extern struct BBRec drawWinBBox; extern int colorDisplay; extern int fullTrueColorMode; extern int noAntiAlias; extern int threeDLook; extern int fileModified; extern int objId; extern int myBgPixel; extern int myFgPixel; extern int myRubberBandPixel; extern int myBorderPixel; extern int myWhitePixel; extern int myBlackPixel; extern int myLtGryPixel; extern int myDkGryPixel; extern int myVryLtPixel; extern int myYellowPixel; extern int reverseVideo; extern char drawPath[]; extern char bootDir[]; extern char homeDir[]; extern char tgifDir[]; extern char tmpDir[]; extern int symPathNumEntries; extern char * * symPath; extern int initDrawWinW; extern int initDrawWinH; extern short handleSize; extern int resizeTextOnStretch; extern Window dummyWindow1, dummyWindow2; extern Window statusSubWindow[]; extern int noMenubar; extern int noStatusWindow; extern int noChoiceWindow; extern int noModeWindow; extern int noChatWindow; extern Atom executeCmdByIDAtom; extern int curChoiceBeforeMakeQuiescent; extern int noMinWinSize; extern int canvasWindowOnly; extern int talkToSelfFiledesInitialized; extern int talkToSelfFiledes[2]; extern Atom compoundTextAtom; extern Atom textAtom; extern Atom utf8StringAtom; extern Atom tgifProtocolAtom; extern Atom tmpSelectionAtom; #ifdef _INCLUDE_FROM_SETUP_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_SETUP_C_*/ extern void RegisterWM_DELETE_WINDOW ARGS_DECL((Window)); extern int IsWM_DELETE_WINDOW ARGS_DECL((XEvent*)); extern void UpdDrawWinWH ARGS_DECL((void)); extern void UpdDrawWinBBox ARGS_DECL((void)); extern void InitWinSizes ARGS_DECL((void)); extern void InverseInitWinSizes ARGS_DECL((void)); extern void ComputeMainWinXY ARGS_DECL((int *MainWinX, int *MainWinY)); extern int TgHandleCmdEvent ARGS_DECL((XEvent*)); extern int TgIsCmdEvent ARGS_DECL((XEvent*)); extern void HandleSelectionRequest ARGS_DECL((XEvent *)); extern int mainWinEventHandler ARGS_DECL((XEvent *)); extern void Reconfigure ARGS_DECL((int Forced)); extern void CleanUpPaperSize ARGS_DECL((void)); extern void InitPaperSize ARGS_DECL((void)); extern void InitTmpDir ARGS_DECL((void)); extern void Setup ARGS_DECL((void)); extern void CleanUpResiduals ARGS_DECL((void)); extern int TieLooseEnds ARGS_DECL((void)); extern void MakeQuiescent ARGS_DECL((void)); extern void SetFileModified ARGS_DECL((int)); #ifdef _INCLUDE_FROM_SETUP_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_SETUP_C_*/ #endif /*_SETUP_E_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/bootstrap.pl�������������������������������������������������������������������������0000755�0000764�0000764�00000003723�11602233310�015344� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#!/usr/bin/perl # # @(#)$Header: /mm2/home/cvs/bc-src/tgif/bootstrap.pl,v 1.16 2011/05/23 16:35:57 william Exp $ # # bootstrap.pl version $skip_autoscan = 0; $num_cmd_args = $#ARGV +1; if ($num_cmd_args != 1) { print "usage: bootstrap.pl version\n"; exit 0; } $version = $ARGV[0]; $autodir = "/usr/share/automake-1.10"; $email = "bill.cheng\@acm.org"; print "clean up files...\n"; system("rm -rf autom4te.cache"); system("rm -f Makefile Makefile.distr Makefile.in aclocal.m4 autoscan.log"); system("rm -f configure configure.ac config.h.in config.h"); if (!$skip_autoscan) { # # These files will be generated, delete them to make sure that we start # from scratch # system("rm -f mkinstalldirs install-sh missing depcomp"); system("rm -f config.status configure.scan"); # # Need these from for the script to run # print "copy files from $autodir...\n"; system("cp $autodir/mkinstalldirs $autodir/install-sh ."); system("cp $autodir/missing $autodir/depcomp ."); print "running autoscan...\n"; system("autoscan"); } print "generating configure.ac...\n"; $init_pat = "AC_INIT(FULL-PACKAGE-NAME, VERSION, BUG-REPORT-ADDRESS)"; $init_dat = "AC_INIT(tgif, $version, $email)"; $cmd = "sed -e '1,\$s/$init_pat/$init_dat/' configure.scan > configure.1.$$"; system($cmd); $init_pat = "AC_INIT(\\\[FULL-PACKAGE-NAME\\\], \\\[VERSION\\\], \\\[BUG-REPORT-ADDRESS\\\])"; $init_dat = "AC_INIT([tgif], [$version], [$email])"; $cmd = "sed -e '1,\$s/$init_pat/$init_dat/' configure.1.$$ > configure.$$"; system($cmd); system("awk -f scan2ac.awk configure.$$ > configure.ac"); system("rm -f configure.1.$$ configure.$$"); print "running aclocal...\n"; system("aclocal"); print "running autoheader...\n"; system("autoheader"); print "running automake -ac...\n"; system("automake -ac"); print "running autoconf...\n"; system("autoconf"); print "running configure...\n"; system("./configure; cp Makefile Makefile.distr; make clean"); ���������������������������������������������tgif-QPL-4.2.5/rm_intrf.c���������������������������������������������������������������������������0000644�0000764�0000764�00000043524�11602233312�014760� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/rm_intrf.c,v 1.17 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_RM_INTRF_C_ #include "tgifdefs.h" #include "cmdids.h" #include "dialog.e" #include "menu.e" #include "msg.e" #include "rm_intrf.e" #include "strtbl.e" #include "util.e" #ifndef _NO_DL_SUPPORT #define CLOSE_DL(handle) dlclose(handle) #define OPEN_DL(path,flag) dlopen((path),(flag)) #define GET_DL_SYM(handle,symbol) dlsym((handle),(symbol)) #ifndef RTLD_NOW #define OPEN_DL_MODE 1 #else /* RTLD_NOW */ #define OPEN_DL_MODE (RTLD_NOW|RTLD_GLOBAL) #endif /* ~RTLD_NOW */ #else /* _NO_DL_SUPPORT */ #define CLOSE_DL(handle) #define OPEN_DL(path,flag) NULL #define GET_DL_SYM(handle,symbol) NULL #define OPEN_DL_MODE 0 #endif /* ~_NO_DL_SUPPORT */ char cmdLineRMCastLibDir[MAXPATHLENGTH+1]; char cmdLineRMCastLibPath[MAXPATHLENGTH+1]; RMCastIntrfInfo gRMCastIntrfInfo; /* ------------------ Utility Functions ------------------ */ /* ------------------ RMCastCleanUp() ------------------ */ void RMCastCleanUp() { #ifndef _NO_RMCAST_SO if (gRMCastIntrfInfo.pSharedLibHandle != NULL) { CLOSE_DL(gRMCastIntrfInfo.pSharedLibHandle); } #endif /* ~_NO_RMCAST_SO */ memset(&gRMCastIntrfInfo, 0, sizeof(RMCastIntrfInfo)); } /* ------------------ RMCastInit() ------------------ */ static int GetEntryPointFailed(psz_funcname) char *psz_funcname; { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_FAIL_GET_ENTRY_PT_IN_SHARELIB), psz_funcname, gRMCastIntrfInfo.szPath); fprintf(stderr, "%s\n", gszMsgBox); if (gRMCastIntrfInfo.pSharedLibHandle != NULL) { CLOSE_DL(gRMCastIntrfInfo.pSharedLibHandle); } memset(&gRMCastIntrfInfo, 0, sizeof(RMCastIntrfInfo)); return FALSE; } typedef struct tagInterfaceVerInfo { char sz_interface_type[80]; int major_version; char sz_other_version_info[80]; char sz_additional_info[MAXSTRING]; } InterfaceVerInfo; static int ParseInterfaceVersion(buf, pivi) char *buf; InterfaceVerInfo *pivi; { char *psz=NULL, *psz2=NULL; memset(pivi, 0, sizeof(InterfaceVerInfo)); psz = strchr(buf, ' '); if (psz == NULL) return FALSE; *psz = '\0'; UtilStrCpyN(pivi->sz_interface_type, sizeof(pivi->sz_interface_type), buf); *psz++ = ' '; buf = psz; psz = strchr(buf, ' '); if (psz != NULL) { *psz = '\0'; UtilStrCpyN(pivi->sz_additional_info, sizeof(pivi->sz_additional_info), &psz[1]); } psz2 = strchr(buf, '.'); if (psz2 == NULL) return FALSE; *psz2 = '\0'; if (sscanf(buf, "%d", &pivi->major_version) != 1) { *psz2 = '.'; return FALSE; } *psz2++ = '.'; UtilStrCpyN(pivi->sz_other_version_info, sizeof(pivi->sz_other_version_info), psz2); if (psz != NULL) { *psz++ = ' '; } return TRUE; } static int RMCastInterface1Init(pivi) InterfaceVerInfo *pivi; { gRMCastIntrfInfo.pfn_RM_initialize = (RM_initialize_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_initialize"); if (gRMCastIntrfInfo.pfn_RM_initialize == NULL) { return GetEntryPointFailed("RM_initialize"); } gRMCastIntrfInfo.pfn_RM_joinGroup = (RM_joinGroup_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_joinGroup"); if (gRMCastIntrfInfo.pfn_RM_joinGroup == NULL) { return GetEntryPointFailed("RM_joinGroup"); } gRMCastIntrfInfo.pfn_RM_leaveGroup = (RM_leaveGroup_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_leaveGroup"); if (gRMCastIntrfInfo.pfn_RM_leaveGroup == NULL) { return GetEntryPointFailed("RM_leaveGroup"); } gRMCastIntrfInfo.pfn_RM_terminate = (RM_terminate_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_terminate"); if (gRMCastIntrfInfo.pfn_RM_terminate == NULL) { return GetEntryPointFailed("RM_terminate"); } gRMCastIntrfInfo.pfn_RM_sendto = (RM_sendto_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_sendto"); if (gRMCastIntrfInfo.pfn_RM_sendto == NULL) { return GetEntryPointFailed("RM_sendto"); } gRMCastIntrfInfo.pfn_RM_recv = (RM_recv_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_recv"); if (gRMCastIntrfInfo.pfn_RM_recv == NULL) { return GetEntryPointFailed("RM_recv"); } gRMCastIntrfInfo.pfn_RM_getCurStatus = (RM_getCurStatus_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_getCurStatus"); if (gRMCastIntrfInfo.pfn_RM_getCurStatus == NULL) { return GetEntryPointFailed("RM_getCurStatus"); } gRMCastIntrfInfo.pfn_RM_sendCurStatus = (RM_sendCurStatus_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_sendCurStatus"); if (gRMCastIntrfInfo.pfn_RM_sendCurStatus == NULL) { return GetEntryPointFailed("RM_sendCurStatus"); } gRMCastIntrfInfo.pfn_RM_readConfigFile = (RM_readConfigFile_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_readConfigFile"); if (gRMCastIntrfInfo.pfn_RM_readConfigFile == NULL) { return GetEntryPointFailed("RM_readConfigFile"); } gRMCastIntrfInfo.pfn_RM_getOption = (RM_getOption_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_getOption"); if (gRMCastIntrfInfo.pfn_RM_getOption == NULL) { return GetEntryPointFailed("RM_getOption"); } gRMCastIntrfInfo.pfn_RM_setOption = (RM_setOption_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_setOption"); if (gRMCastIntrfInfo.pfn_RM_setOption == NULL) { return GetEntryPointFailed("RM_setOption"); } gRMCastIntrfInfo.pfn_RM_setHostDelay = (RM_setHostDelay_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_setHostDelay"); if (gRMCastIntrfInfo.pfn_RM_setHostDelay == NULL) { return GetEntryPointFailed("RM_setHostDelay"); } gRMCastIntrfInfo.pfn_RM_getHostDelay = (RM_getHostDelay_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RM_getHostDelay"); if (gRMCastIntrfInfo.pfn_RM_getHostDelay == NULL) { return GetEntryPointFailed("RM_getHostDelay"); } gRMCastIntrfInfo.pfn_RMDEBUG_setpidip = (RMDEBUG_setpidip_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RMDEBUG_setpidip"); if (gRMCastIntrfInfo.pfn_RMDEBUG_setpidip == NULL) { return GetEntryPointFailed("RMDEBUG_setpidip"); } gRMCastIntrfInfo.pfn_RMDEBUG_setsn = (RMDEBUG_setsn_Func*)GET_DL_SYM(gRMCastIntrfInfo.pSharedLibHandle, "RMDEBUG_setsn"); if (gRMCastIntrfInfo.pfn_RMDEBUG_setsn == NULL) { return GetEntryPointFailed("RMDEBUG_setsn"); } return TRUE; } #define LIBRMCAST_SO "librmcast.so" int RMCastInit() { #ifndef _NO_RMCAST_SO char sz_interface_version[MAXSTRING]; InterfaceVerInfo ivi; memset(&gRMCastIntrfInfo, 0, sizeof(RMCastIntrfInfo)); memset(&ivi, 0, sizeof(InterfaceVerInfo)); if (*cmdLineRMCastLibPath != '\0') { UtilStrCpyN(gRMCastIntrfInfo.szPath, sizeof(gRMCastIntrfInfo.szPath), cmdLineRMCastLibPath); if (!UtilPathExists(gRMCastIntrfInfo.szPath)) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_INVALID_RMCAST_DLIB_PATH), gRMCastIntrfInfo.szPath, TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, STOP_MB); SendCommandToSelf(CMDID_QUIT, 0); return FALSE; } } else if (*cmdLineRMCastLibDir == '\0') { char *psz=getenv("LD_LIBRARY_PATH"), *psz_copy=NULL, *psz_state=NULL; int found=FALSE; if (psz == NULL) { snprintf(gRMCastIntrfInfo.szPath, sizeof(gRMCastIntrfInfo.szPath), "%s", LIBRMCAST_SO); gRMCastIntrfInfo.pSharedLibHandle = OPEN_DL(gRMCastIntrfInfo.szPath, OPEN_DL_MODE); if (gRMCastIntrfInfo.pSharedLibHandle == NULL) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_NO_INFO_LIBRMCAST_SO), LIBRMCAST_SO, LIBRMCAST_SO, TOOL_NAME, TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, STOP_MB); SendCommandToSelf(CMDID_QUIT, 0); return FALSE; } } else { psz_copy = UtilStrDup(psz); if (psz_copy == NULL) FailAllocMessage(); for (psz=UtilStrTok(psz_copy, ":", &psz_state); psz != NULL; psz=UtilStrTok(NULL, ":", &psz_state)) { snprintf(gRMCastIntrfInfo.szPath, sizeof(gRMCastIntrfInfo.szPath), "%s%c%s", psz, DIR_SEP, LIBRMCAST_SO); if (UtilPathExists(gRMCastIntrfInfo.szPath)) { found = TRUE; break; } } UtilFree(psz_copy); if (!found) { snprintf(gRMCastIntrfInfo.szPath, sizeof(gRMCastIntrfInfo.szPath), "%s", LIBRMCAST_SO); gRMCastIntrfInfo.pSharedLibHandle = OPEN_DL(gRMCastIntrfInfo.szPath, OPEN_DL_MODE); if (gRMCastIntrfInfo.pSharedLibHandle == NULL) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_NO_INFO_LIBRMCAST_SO), LIBRMCAST_SO, LIBRMCAST_SO, TOOL_NAME, TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, STOP_MB); SendCommandToSelf(CMDID_QUIT, 0); return FALSE; } /* return FALSE; -- seems to not work with -parent, shouldn't really get here anyway */ } } } else { snprintf(gRMCastIntrfInfo.szPath, sizeof(gRMCastIntrfInfo.szPath), "%s%c%s", cmdLineRMCastLibDir, DIR_SEP, LIBRMCAST_SO); if (!UtilPathExists(gRMCastIntrfInfo.szPath)) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_INVALID_RMCAST_DLIB_PATH), gRMCastIntrfInfo.szPath, TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, STOP_MB); SendCommandToSelf(CMDID_QUIT, 0); return FALSE; } } if (gRMCastIntrfInfo.pSharedLibHandle == NULL) { gRMCastIntrfInfo.pSharedLibHandle = OPEN_DL(gRMCastIntrfInfo.szPath, OPEN_DL_MODE); if (gRMCastIntrfInfo.pSharedLibHandle == NULL) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_FAIL_LOAD_SHARELIB), gRMCastIntrfInfo.szPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } gRMCastIntrfInfo.pfn_RM_getVersion = (RM_getVersion_Func*)GET_DL_SYM( gRMCastIntrfInfo.pSharedLibHandle, "RM_getVersion"); if (gRMCastIntrfInfo.pfn_RM_getVersion == NULL) { return GetEntryPointFailed("RM_getVersion"); } RM_getVersion(sz_interface_version, sizeof(sz_interface_version)); if (!ParseInterfaceVersion(sz_interface_version, &ivi)) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_BAD_VER_RMCAST_DLIB), sz_interface_version, gRMCastIntrfInfo.szPath); fprintf(stderr, "%s\n", gszMsgBox); CLOSE_DL(gRMCastIntrfInfo.pSharedLibHandle); memset(&gRMCastIntrfInfo, 0, sizeof(RMCastIntrfInfo)); return FALSE; } if (strcmp(ivi.sz_interface_type, "RMCAST") == 0 && ivi.major_version == 2) { return RMCastInterface1Init(&ivi); } else { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_CANNOT_HANDLE_VER_RMCAST_DLIB), TOOL_NAME, sz_interface_version, gRMCastIntrfInfo.szPath); fprintf(stderr, "%s\n", gszMsgBox); CLOSE_DL(gRMCastIntrfInfo.pSharedLibHandle); memset(&gRMCastIntrfInfo, 0, sizeof(RMCastIntrfInfo)); return FALSE; } #else /* ~_NO_RMCAST_SO */ memset(&gRMCastIntrfInfo, 0, sizeof(RMCastIntrfInfo)); #endif /* _NO_RMCAST_SO */ return FALSE; } /* ------------------ Functions in RMCAST library ------------------ */ #ifndef _NO_RMCAST_SO void RM_getVersion(buf, buf_sz) char *buf; int buf_sz; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_getVersion != NULL) { (gRMCastIntrfInfo.pfn_RM_getVersion)(buf, buf_sz); return; } TgAssert(FALSE, "RM_getVersion() called when it's not available.", NULL); } int RM_initialize(void *callbackterm( void )) { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_initialize != NULL) { return (gRMCastIntrfInfo.pfn_RM_initialize)(*callbackterm); } TgAssert(FALSE, "RM_initialize() called when it's not available.", NULL); return 0; } int RM_joinGroup(group, port) char *group; int port; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_joinGroup != NULL) { return (gRMCastIntrfInfo.pfn_RM_joinGroup)(group, port); } TgAssert(FALSE, "RM_joinGroup() called when it's not available.", NULL); return 0; } void RM_leaveGroup(sock, group) int sock; char *group; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_leaveGroup != NULL) { (gRMCastIntrfInfo.pfn_RM_leaveGroup)(sock, group); return; } TgAssert(FALSE, "RM_leaveGroup() called when it's not available.", NULL); } void RM_terminate() { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_terminate != NULL) { (gRMCastIntrfInfo.pfn_RM_terminate)(); return ; } TgAssert(FALSE, "RM_terminate() called when it's not available.", NULL); } int RM_sendto(socket, buffer, buffsize) int socket, buffsize; void *buffer; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_sendto != NULL) { return (gRMCastIntrfInfo.pfn_RM_sendto)(socket, buffer, buffsize); } TgAssert(FALSE, "RM_sendto() called when it's not available.", NULL); return 0; } int RM_recv(socket, buffer, buffsize) int socket, buffsize; void *buffer; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_recv != NULL) { return (gRMCastIntrfInfo.pfn_RM_recv)(socket, buffer, buffsize); } TgAssert(FALSE, "RM_recv() called when it's not available.", NULL); return 0; } int RM_getCurStatus(group, port, c) char *group; int port; CurStatus *c; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_getCurStatus != NULL) { return (gRMCastIntrfInfo.pfn_RM_getCurStatus)(group, port, c); } TgAssert(FALSE, "RM_getCurStatus() called when it's not available.", NULL); return 0; } int RM_sendCurStatus(connfd, buff, buffsize) int connfd, buffsize; char *buff; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_sendCurStatus != NULL) { return (gRMCastIntrfInfo.pfn_RM_sendCurStatus)(connfd, buff, buffsize); } TgAssert(FALSE, "RM_sendCurStatus() called when it's not available.", NULL); return 0; } int RM_readConfigFile(filename, show_config_file) char *filename, show_config_file; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_readConfigFile != NULL) { return (gRMCastIntrfInfo.pfn_RM_readConfigFile)(filename, show_config_file); } TgAssert(FALSE, "RM_readConfigFile() called when it's not available.", NULL); return 0; } void RM_getOption(opt, return_value) int opt; void *return_value; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_getOption != NULL) { (gRMCastIntrfInfo.pfn_RM_getOption)(opt, return_value); return; } TgAssert(FALSE, "RM_getOption() called when it's not available.", NULL); } void RM_setOption(opt, optvalue) int opt; void *optvalue; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_setOption != NULL) { (gRMCastIntrfInfo.pfn_RM_setOption)(opt, optvalue); return; } TgAssert(FALSE, "RM_setOption() called when it's not available.", NULL); } int RM_setHostDelay(hostname, estimated_one_way_delay) char *hostname; int estimated_one_way_delay; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_setHostDelay != NULL) { return (gRMCastIntrfInfo.pfn_RM_setHostDelay)(hostname, estimated_one_way_delay); } TgAssert(FALSE, "RM_setHostDelay() called when it's not available.", NULL); return 0; } int RM_getHostDelay(hostname, estimated_one_way_delay) char *hostname; int *estimated_one_way_delay; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RM_getHostDelay != NULL) { return (gRMCastIntrfInfo.pfn_RM_getHostDelay)(hostname, estimated_one_way_delay); } TgAssert(FALSE, "RM_getHostDelay() called when it's not available.", NULL); return 0; } void RMDEBUG_setpidip(pid, ip) int pid; char *ip; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RMDEBUG_setpidip != NULL) { (gRMCastIntrfInfo.pfn_RMDEBUG_setpidip)(pid, ip); return; } TgAssert(FALSE, "RMDEBUG_setpidip() called when it's not available.", NULL); } void RMDEBUG_setsn(sn) int sn; { if (gRMCastIntrfInfo.pSharedLibHandle != NULL && gRMCastIntrfInfo.pfn_RMDEBUG_setsn != NULL) { (gRMCastIntrfInfo.pfn_RMDEBUG_setsn)(sn); return; } TgAssert(FALSE, "RMDEBUG_setsn() called when it's not available.", NULL); } #endif /* _NO_RMCAST_SO */ ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tidget.h�����������������������������������������������������������������������������0000644�0000764�0000764�00000012757�11602233313�014432� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tidget.h,v 1.6 2011/05/16 16:22:00 william Exp $ */ #ifndef _TIDGET_H_ #define _TIDGET_H_ #include "list.e" #define TIDGET_TYPE_BASE 0 #define TIDGET_TYPE_LIST 1 #define TIDGET_TYPE_BTN 2 #define TIDGET_TYPE_EDIT 3 #define TIDGET_TYPE_DRAW 4 #define TIDGET_TYPE_MSG 5 #define TIDGET_TYPE_BROW 6 #define TIDGET_TYPE_BMPL 7 #define TIDGET_TYPE_SEDT 8 /* --------------------- Notifications --------------------- */ /* * TDGTNF_* are tidget notifications generated by a control. * nf_type is one of TDGTNF_*. * nf_arg and nf_arg2 are arguments to the notification event. */ #define TDGTNF_NO_NOTIFY 0 /* list control events */ #define TDGTNF_LIST_CLICKED 10 /* nf_arg is the item index, nf_arg2 is which mouse button was used when clicking */ #define TDGTNF_LIST_DBL_CLICKED 11 /* nf_arg is the item index */ /* button control events */ #define TDGTNF_BTN_CLICKED 20 /* nf_arg is 0 */ #define TDGTNF_MULTI_BTN_CLICKED 21 /* nf_arg is Button[1-3], nf_arg2 is color_index */ /* edit control events */ #define TDGTNF_EDIT_ENTERED 30 /* nf_arg is 0 */ /* --------------------- Commands --------------------- */ /* * TDGTCMD_* are tidget commands that can be send to a control. * cmd_type is one of TDGTCMD_*. * cmd_arg is an argument to the command. */ #define TDGTCMD_NO_CMD 200 /* bitmap list control commands */ #define TDGTCMD_LIST_RESETCONTENT 210 /* cmd_arg is 0 */ #define TDGTCMD_LIST_SEL_NEXT 211 /* cmd_arg is one of TDGTARG_MOVE_* */ #define TDGTARG_MOVE_UP 0 #define TDGTARG_MOVE_DOWN 1 #define TDGTARG_MOVE_RIGHT 2 #define TDGTARG_MOVE_LEFT 3 #define TDGTCMD_LIST_GETCURSEL 212 /* get marked_index, pv_cmd_userdata is of type (int*) */ #define TDGTCMD_LIST_GETITEM 213 /* cmd_arg is an index, if tidget is TdgtBmpList, pv_cmd_userdata is of type (BmpListItemInfo**), if tidget is TdgtList, pv_cmd_userdata is of type (ListItemInfo**) */ /* draw control commands */ #define TDGTCMD_DRAW_USER 240 /* cmd_arg is user defined */ /* --------------------- Structures --------------------- */ struct tagTidgetInfo; typedef void (TidgetRedrawCallbackFunc)ARGS_DECL((struct tagTidgetInfo *)); typedef int (TidgetEvHandlerCallbackFunc)ARGS_DECL((struct tagTidgetInfo *, XEvent*, struct tagTidgetInfo *)); typedef int (TidgetIsEventCallbackFunc)ARGS_DECL((struct tagTidgetInfo *, XEvent*, struct tagTidgetInfo **)); typedef void (TidgetDestroyCallbackFunc)ARGS_DECL((struct tagTidgetInfo *)); typedef void (TidgetMapCallbackFunc)ARGS_DECL((struct tagTidgetInfo *)); typedef void (TidgetMoveResizeCallbackFunc)ARGS_DECL((struct tagTidgetInfo *, int x, int y, int w, int h)); typedef int (TidgetSendCmdCallbackFunc)ARGS_DECL((struct tagTidgetInfo *, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); typedef struct tagTidgetCommonInfo { /* * If parent_tidgetinfo is NULL, the parent is not a tidget (just some sort * of a window -- for an example, see "chat.c" and "tgtwb5dl.c"). * The parent window is stored in parent_win. */ struct tagTidgetInfo *parent_tidgetinfo; Window parent_win; Window win; SimpleWinInfo win_info; int state; /* TGBS_NORMAL, TGBS_GRAYED, TGBS_RAISED, or TGBS_LOWRED */ int mapped; int redraw_disabled; int dirty; /* to be used with redraw_disabled */ int h_pad, v_pad; /* horizontal and vertical padding */ /* * content_w is usually win_info.w-(windowPadding<<1)-(h_pad<<1) * content_h is usually win_info.h-(windowPadding<<1)-(v_pad<<1) */ int content_w, content_h; struct DynStrRec dyn_str; /* caption, msg, btn name, etc. */ int ctl_id; /* so that objects can be named */ int can_have_children; /* TRUE if a tidget can have child tidgets */ CVList clist; /* list of (TIdgetInfo*) which are children tidgets */ /* call back functions */ TidgetRedrawCallbackFunc *pf_redraw_callback; TidgetEvHandlerCallbackFunc *pf_ev_handler_callback; TidgetIsEventCallbackFunc *pf_is_event_callback; TidgetDestroyCallbackFunc *pf_destroy_callback; TidgetMapCallbackFunc *pf_map_callback; TidgetMoveResizeCallbackFunc *pf_moveresize_callback; TidgetSendCmdCallbackFunc *pf_sendcmd_callback; } TidgetCommonInfo; typedef struct tagTidgetInfo { /* * type is one of TIDGET_TYPE_* * It is used to typecast the tidget field below to one of the * known types. */ int type; void *tidget; /* points to the actual tidget */ TidgetCommonInfo tci; /* additional userdata */ void *userdata; } TidgetInfo; typedef struct tagTdgtCmd { int cmd_type; int cmd_arg; void *cmd_userdata; } TdgtCmd; typedef struct tagTdgtNtfy { int ctl_id; int nf_type; int nf_arg; int nf_arg2; } TdgtNtfy; #endif /*_TIDGET_H_*/ �����������������tgif-QPL-4.2.5/poly.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000012411�11602233312�014114� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/poly.e,v 1.11 2011/05/16 16:21:59 william Exp $ */ #ifndef _POLY_E_ #define _POLY_E_ #include "list.e" typedef struct tagWiringInfo { int num_ports_to_connect; /* this used to be drawPolyToEndInANode */ struct ObjRec *first_port_obj, *first_port_owner_obj; char first_port_name[MAXSTRING]; /* this used to be drawPolyFirstNodeName */ struct ObjRec *last_port_obj, *last_port_owner_obj; char last_port_name[MAXSTRING]; /* this used to be drawPolyLastNodeName */ } WiringInfo; extern WiringInfo gstWiringInfo; extern int polyDrawn; extern int queryPolyNameOnConnect; extern short origWidthOfLine[]; extern short origArrowHeadH[]; extern short origArrowHeadW[]; extern short *curWidthOfLine; extern short *curArrowHeadH; extern short *curArrowHeadW; extern char **curWidthOfLineSpec; extern char **curArrowHeadHSpec; extern char **curArrowHeadWSpec; extern int numPtsInPoly; extern CVList gStructSplineList; extern struct PtRec *lastPtPtr; extern struct ObjRec * drawPolyHighlightedNode; #ifdef _INCLUDE_FROM_POLY_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_POLY_C_*/ extern IntPoint *GetPolyOrPolygonAbsVs ARGS_DECL((int *pnReturn, int *pnAllocated, struct ObjRec *)); extern XPoint *MakePolyVertex ARGS_DECL((int XOff, int YOff, int NumVs, IntPoint*)); extern void CalcPolyBBox ARGS_DECL((struct ObjRec *)); extern void UpdPolyBBox ARGS_DECL((struct ObjRec *, int NumPts, IntPoint*)); extern void UpdNonIntSplinePolyBBox ARGS_DECL((struct ObjRec *, int NumPts, IntPoint*)); extern void UpdPolyOrPolygonBBox ARGS_DECL((struct ObjRec *)); extern void CreatePolyObj ARGS_DECL((int NumPts, int CreateAbsolute)); extern void ResetCreatePoly ARGS_DECL((void)); extern void AddPtToCreatePoly ARGS_DECL((int AbsX, int AbsY)); extern void FreePointsForCont ARGS_DECL((int *pn_ltx, int *pn_lty, int *pn_rbx, int *pn_rby)); extern int SetFirstPoint ARGS_DECL((int grid_x, int grid_y, IntPointTriplet*)); extern int AddPointForCont ARGS_DECL((int grid_x, int grid_y, IntPointTriplet*)); extern void UpdateLastPointForCont ARGS_DECL((IntPointTriplet*)); extern void DrawAllStructSplinePointsForCont ARGS_DECL((int num_pts)); extern void UpdatePrevToLastPointForCont ARGS_DECL((IntPointTriplet*)); extern void DrawPoly ARGS_DECL((XEvent*)); extern void SetWiringNodeInfo ARGS_DECL((struct ObjRec *port_obj, struct ObjRec *port_owner_obj, char *port_name, int first)); extern void ResetWiringNodeInfo ARGS_DECL((void)); extern void InputPolyPts ARGS_DECL((void)); extern void JoinPoly ARGS_DECL((void)); extern void CutPoly ARGS_DECL((void)); extern double GetWidthInDouble ARGS_DECL((int nVal, char *pszSpec, int *pnIsInt)); extern void SetWidthAndSpec ARGS_DECL((double dWidth, int *pnWidth, char *pszWidthSpec)); extern void ScaleWidthAndSpec ARGS_DECL((double dScale, int *pnWidth, char *pszWidthSpec)); extern void DumpArrow ARGS_DECL((FILE*, IntPoint *TailV, IntPoint *HeadV, int ArrowW, int ArrowH, char *AWSpec, char *AHSpec, int Pen, int TransPat, int ColorIndex)); extern void DumpPolyObj ARGS_DECL((FILE*, struct ObjRec *)); extern int NeedsToCachePolyObj ARGS_DECL((struct ObjRec *)); extern void DrawPolyObj ARGS_DECL((Window, int XOff, int YOff, struct ObjRec *)); extern void SaveSmoothHinge ARGS_DECL((FILE*, int Curved, int NumPts, char *Smooth)); extern void SavePolyObj ARGS_DECL((FILE*, struct ObjRec *)); extern int ReadSmoothHinge ARGS_DECL((FILE*, int Curved, int NumPts, char *Smooth)); extern void ReadPolyObj ARGS_DECL((FILE*, char *Inbuf, struct ObjRec **)); extern void SetPolyPropMask ARGS_DECL((struct ObjRec *, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void FreePolyObj ARGS_DECL((struct ObjRec *)); extern void InitPoly ARGS_DECL((void)); #ifdef _INCLUDE_FROM_POLY_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_POLY_C_*/ #endif /*_POLY_E_*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/fonts.obj����������������������������������������������������������������������������0000644�0000764�0000764�00000022446�11602233311�014620� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������state(0,14,100,0,0,0,16,1,0,1,1,1,0,1,0,7,0,0,3,4,0,0,0,10,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/fonts.obj,v 1.1 2004/09/14 05:26:24 william Exp $ % text('yellow',64,64,0,0,4,1,0,0,1,83,21,11,0,17,4,0,0,0,[ "hello world"]). text('yellow',64,80,1,0,4,1,0,0,1,121,19,12,0,15,4,0,0,0,[ "hello world"]). text('yellow',64,96,2,0,4,1,0,0,1,90,22,13,0,18,4,0,0,0,[ "hello world"]). text('yellow',64,112,3,0,4,1,0,0,1,94,22,14,0,18,4,0,0,0,[ "hello world"]). text('yellow',64,128,4,0,4,1,0,0,1,105,25,15,0,18,7,0,0,0,[ "hello world"]). text('yellow',256,64,0,1,4,1,0,0,1,89,21,16,0,17,4,0,0,0,[ "hello world"]). text('yellow',256,80,1,1,4,1,0,0,1,121,20,17,0,15,5,0,0,0,[ "hello world"]). text('yellow',256,96,2,1,4,1,0,0,1,98,22,18,0,17,5,0,0,0,[ "hello world"]). text('yellow',256,112,3,1,4,1,0,0,1,107,22,19,0,18,4,0,0,0,[ "hello world"]). text('yellow',256,128,4,1,4,1,0,0,1,105,25,20,0,18,7,0,0,0,[ "hello world"]). text('yellow',448,64,0,2,4,1,0,0,1,84,22,21,0,17,5,0,0,0,[ "hello world"]). text('yellow',448,80,1,2,4,1,0,0,1,121,19,22,0,15,4,0,0,0,[ "hello world"]). text('yellow',448,96,2,2,4,1,0,0,1,88,22,23,0,17,5,0,0,0,[ "hello world"]). text('yellow',448,112,3,2,4,1,0,0,1,94,22,24,0,16,6,0,0,0,[ "hello world"]). text('yellow',448,128,4,2,4,1,0,0,1,105,25,25,0,18,7,0,0,0,[ "hello world"]). text('yellow',640,64,0,3,4,1,0,0,1,85,21,26,0,17,4,0,0,0,[ "hello world"]). text('yellow',640,80,1,3,4,1,0,0,1,121,20,27,0,15,5,0,0,0,[ "hello world"]). text('yellow',640,96,2,3,4,1,0,0,1,93,22,28,0,17,5,0,0,0,[ "hello world"]). text('yellow',640,112,3,3,4,1,0,0,1,104,22,29,0,16,6,0,0,0,[ "hello world"]). text('yellow',640,128,4,3,4,1,0,0,1,105,25,30,0,18,7,0,0,0,[ "hello world"]). text('yellow',64,192,0,0,5,1,0,0,1,109,28,31,0,22,6,0,0,0,[ "hello world"]). text('yellow',64,208,1,0,5,1,0,0,1,165,24,32,0,19,5,0,0,0,[ "hello world"]). text('yellow',64,224,2,0,5,1,0,0,1,117,29,33,0,24,5,0,0,0,[ "hello world"]). text('yellow',64,240,3,0,5,1,0,0,1,125,28,34,0,23,5,0,0,0,[ "hello world"]). text('yellow',64,256,4,0,5,1,0,0,1,140,32,35,0,24,8,0,0,0,[ "hello world"]). text('yellow',288,192,0,1,5,1,0,0,1,121,28,36,0,22,6,0,0,0,[ "hello world"]). text('yellow',288,208,1,1,5,1,0,0,1,165,25,37,0,20,5,0,0,0,[ "hello world"]). text('yellow',288,224,2,1,5,1,0,0,1,128,29,38,0,24,5,0,0,0,[ "hello world"]). text('yellow',288,240,3,1,5,1,0,0,1,148,29,39,0,24,5,0,0,0,[ "hello world"]). text('yellow',288,256,4,1,5,1,0,0,1,140,32,40,0,24,8,0,0,0,[ "hello world"]). text('yellow',512,192,0,2,5,1,0,0,1,110,29,41,0,23,6,0,0,0,[ "hello world"]). text('yellow',512,208,1,2,5,1,0,0,1,165,24,42,0,19,5,0,0,0,[ "hello world"]). text('yellow',512,224,2,2,5,1,0,0,1,117,29,43,0,24,5,0,0,0,[ "hello world"]). text('yellow',512,240,3,2,5,1,0,0,1,127,28,44,0,23,5,0,0,0,[ "hello world"]). text('yellow',512,256,4,2,5,1,0,0,1,140,32,45,0,24,8,0,0,0,[ "hello world"]). text('yellow',736,192,0,3,5,1,0,0,1,113,28,46,0,22,6,0,0,0,[ "hello world"]). text('yellow',736,208,1,3,5,1,0,0,1,165,25,47,0,20,5,0,0,0,[ "hello world"]). text('yellow',736,224,2,3,5,1,0,0,1,128,29,48,0,24,5,0,0,0,[ "hello world"]). text('yellow',736,240,3,3,5,1,0,0,1,140,29,49,0,24,5,0,0,0,[ "hello world"]). text('yellow',736,256,4,3,5,1,0,0,1,140,32,50,0,24,8,0,0,0,[ "hello world"]). text('yellow',64,320,0,0,3,1,0,0,1,63,18,51,0,14,4,0,0,0,[ "hello world"]). text('yellow',64,336,1,0,3,1,0,0,1,99,16,52,0,13,3,0,0,0,[ "hello world"]). text('yellow',64,352,2,0,3,1,0,0,1,67,17,53,0,14,3,0,0,0,[ "hello world"]). text('yellow',64,368,3,0,3,1,0,0,1,72,17,54,0,14,3,0,0,0,[ "hello world"]). text('yellow',64,384,4,0,3,1,0,0,1,84,20,55,0,14,6,0,0,0,[ "hello world"]). text('yellow',192,320,0,1,3,1,0,0,1,70,18,56,0,14,4,0,0,0,[ "hello world"]). text('yellow',192,336,1,1,3,1,0,0,1,99,16,57,0,12,4,0,0,0,[ "hello world"]). text('yellow',192,352,2,1,3,1,0,0,1,76,17,58,0,14,3,0,0,0,[ "hello world"]). text('yellow',192,368,3,1,3,1,0,0,1,84,18,59,0,15,3,0,0,0,[ "hello world"]). text('yellow',192,384,4,1,3,1,0,0,1,84,20,60,0,14,6,0,0,0,[ "hello world"]). text('yellow',320,320,0,2,3,1,0,0,1,64,18,61,0,14,4,0,0,0,[ "hello world"]). text('yellow',320,336,1,2,3,1,0,0,1,99,16,62,0,13,3,0,0,0,[ "hello world"]). text('yellow',320,352,2,2,3,1,0,0,1,68,17,63,0,14,3,0,0,0,[ "hello world"]). text('yellow',320,368,3,2,3,1,0,0,1,71,17,64,0,14,3,0,0,0,[ "hello world"]). text('yellow',320,384,4,2,3,1,0,0,1,84,20,65,0,14,6,0,0,0,[ "hello world"]). text('yellow',448,320,0,3,3,1,0,0,1,66,17,66,0,14,3,0,0,0,[ "hello world"]). text('yellow',448,336,1,3,3,1,0,0,1,99,16,67,0,12,4,0,0,0,[ "hello world"]). text('yellow',448,352,2,3,3,1,0,0,1,75,17,68,0,14,3,0,0,0,[ "hello world"]). text('yellow',448,368,3,3,3,1,0,0,1,82,17,69,0,14,3,0,0,0,[ "hello world"]). text('yellow',448,384,4,3,3,1,0,0,1,84,20,70,0,14,6,0,0,0,[ "hello world"]). text('yellow',64,448,0,0,2,1,0,0,1,55,15,71,0,12,3,0,0,0,[ "hello world"]). text('yellow',64,464,1,0,2,1,0,0,1,77,14,72,0,11,3,0,0,0,[ "hello world"]). text('yellow',64,480,2,0,2,1,0,0,1,61,15,73,0,12,3,0,0,0,[ "hello world"]). text('yellow',64,496,3,0,2,1,0,0,1,64,15,74,0,12,3,0,0,0,[ "hello world"]). text('yellow',64,512,4,0,2,1,0,0,1,75,16,75,0,12,4,0,0,0,[ "hello world"]). text('yellow',192,448,0,1,2,1,0,0,1,59,15,76,0,12,3,0,0,0,[ "hello world"]). text('yellow',192,464,1,1,2,1,0,0,1,77,14,77,0,11,3,0,0,0,[ "hello world"]). text('yellow',192,480,2,1,2,1,0,0,1,64,15,78,0,12,3,0,0,0,[ "hello world"]). text('yellow',192,496,3,1,2,1,0,0,1,77,15,79,0,12,3,0,0,0,[ "hello world"]). text('yellow',192,512,4,1,2,1,0,0,1,75,16,80,0,12,4,0,0,0,[ "hello world"]). text('yellow',320,448,0,2,2,1,0,0,1,55,15,81,0,12,3,0,0,0,[ "hello world"]). text('yellow',320,464,1,2,2,1,0,0,1,77,14,82,0,11,3,0,0,0,[ "hello world"]). text('yellow',320,480,2,2,2,1,0,0,1,60,15,83,0,12,3,0,0,0,[ "hello world"]). text('yellow',320,496,3,2,2,1,0,0,1,64,15,84,0,12,3,0,0,0,[ "hello world"]). text('yellow',320,512,4,2,2,1,0,0,1,75,16,85,0,12,4,0,0,0,[ "hello world"]). text('yellow',448,448,0,3,2,1,0,0,1,58,15,86,0,12,3,0,0,0,[ "hello world"]). text('yellow',448,464,1,3,2,1,0,0,1,77,14,87,0,11,3,0,0,0,[ "hello world"]). text('yellow',448,480,2,3,2,1,0,0,1,63,15,88,0,12,3,0,0,0,[ "hello world"]). text('yellow',448,496,3,3,2,1,0,0,1,70,15,89,0,12,3,0,0,0,[ "hello world"]). text('yellow',448,512,4,3,2,1,0,0,1,75,16,90,0,12,4,0,0,0,[ "hello world"]). text('yellow',64,576,0,0,1,1,0,0,1,50,13,91,0,10,3,0,0,0,[ "hello world"]). text('yellow',64,592,1,0,1,1,0,0,1,66,11,92,0,9,2,0,0,0,[ "hello world"]). text('yellow',64,608,2,0,1,1,0,0,1,50,13,93,0,11,2,0,0,0,[ "hello world"]). text('yellow',64,624,3,0,1,1,0,0,1,54,13,94,0,11,2,0,0,0,[ "hello world"]). text('yellow',64,640,4,0,1,1,0,0,1,60,14,95,0,10,4,0,0,0,[ "hello world"]). text('yellow',192,576,0,1,1,1,0,0,1,49,13,96,0,10,3,0,0,0,[ "hello world"]). text('yellow',192,592,1,1,1,1,0,0,1,66,11,97,0,9,2,0,0,0,[ "hello world"]). text('yellow',192,608,2,1,1,1,0,0,1,54,13,98,0,11,2,0,0,0,[ "hello world"]). text('yellow',192,624,3,1,1,1,0,0,1,66,13,99,0,11,2,0,0,0,[ "hello world"]). text('yellow',192,640,4,1,1,1,0,0,1,60,14,100,0,10,4,0,0,0,[ "hello world"]). text('yellow',320,576,0,2,1,1,0,0,1,47,13,101,0,10,3,0,0,0,[ "hello world"]). text('yellow',320,592,1,2,1,1,0,0,1,66,11,102,0,9,2,0,0,0,[ "hello world"]). text('yellow',320,608,2,2,1,1,0,0,1,49,13,103,0,11,2,0,0,0,[ "hello world"]). text('yellow',320,624,3,2,1,1,0,0,1,54,13,104,0,11,2,0,0,0,[ "hello world"]). text('yellow',320,640,4,2,1,1,0,0,1,60,14,105,0,10,4,0,0,0,[ "hello world"]). text('yellow',448,576,0,3,1,1,0,0,1,47,13,106,0,10,3,0,0,0,[ "hello world"]). text('yellow',448,592,1,3,1,1,0,0,1,66,11,107,0,9,2,0,0,0,[ "hello world"]). text('yellow',448,608,2,3,1,1,0,0,1,54,13,108,0,11,2,0,0,0,[ "hello world"]). text('yellow',448,624,3,3,1,1,0,0,1,61,13,109,0,11,2,0,0,0,[ "hello world"]). text('yellow',448,640,4,3,1,1,0,0,1,60,14,110,0,10,4,0,0,0,[ "hello world"]). text('yellow',64,704,0,0,0,1,0,0,1,40,10,111,0,8,2,0,0,0,[ "hello world"]). text('yellow',64,720,1,0,0,1,0,0,1,55,10,112,0,8,2,0,0,0,[ "hello world"]). text('yellow',64,736,2,0,0,1,0,0,1,41,11,113,0,9,2,0,0,0,[ "hello world"]). text('yellow',64,752,3,0,0,1,0,0,1,43,10,114,0,8,2,0,0,0,[ "hello world"]). text('yellow',64,768,4,0,0,1,0,0,1,48,11,115,0,8,3,0,0,0,[ "hello world"]). text('yellow',192,704,0,1,0,1,0,0,1,39,10,116,0,8,2,0,0,0,[ "hello world"]). text('yellow',192,720,1,1,0,1,0,0,1,55,9,117,0,7,2,0,0,0,[ "hello world"]). text('yellow',192,736,2,1,0,1,0,0,1,42,11,118,0,9,2,0,0,0,[ "hello world"]). text('yellow',192,752,3,1,0,1,0,0,1,55,10,119,0,8,2,0,0,0,[ "hello world"]). text('yellow',192,768,4,1,0,1,0,0,1,48,11,120,0,8,3,0,0,0,[ "hello world"]). text('yellow',320,704,0,2,0,1,0,0,1,38,10,121,0,8,2,0,0,0,[ "hello world"]). text('yellow',320,720,1,2,0,1,0,0,1,55,9,122,0,7,2,0,0,0,[ "hello world"]). text('yellow',320,736,2,2,0,1,0,0,1,40,11,123,0,9,2,0,0,0,[ "hello world"]). text('yellow',320,752,3,2,0,1,0,0,1,43,10,124,0,8,2,0,0,0,[ "hello world"]). text('yellow',320,768,4,2,0,1,0,0,1,48,11,125,0,8,3,0,0,0,[ "hello world"]). text('yellow',448,704,0,3,0,1,0,0,1,37,10,126,0,8,2,0,0,0,[ "hello world"]). text('yellow',448,720,1,3,0,1,0,0,1,55,9,127,0,7,2,0,0,0,[ "hello world"]). text('yellow',448,736,2,3,0,1,0,0,1,42,11,128,0,9,2,0,0,0,[ "hello world"]). text('yellow',448,752,3,3,0,1,0,0,1,50,10,129,0,8,2,0,0,0,[ "hello world"]). text('yellow',448,768,4,3,0,1,0,0,1,48,11,130,0,8,3,0,0,0,[ "hello world"]). ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Tgif.tmpl-aix4�����������������������������������������������������������������������0000644�0000764�0000764�00000004721�11602233313�015423� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-aix4,v 1.12 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/lib/nls/loc DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_BSD -D_NO_DL_SUPPORT -D_NO_IDNLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) XCOMM SYS_LIBRARIES = -ldl -lm -lz SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r -v): XCOMM XCOMM AIX 4 1 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM �����������������������������������������������tgif-QPL-4.2.5/navigate.e���������������������������������������������������������������������������0000644�0000764�0000764�00000010007�11602233312�014726� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/navigate.e,v 1.7 2011/05/16 16:21:58 william Exp $ */ #ifndef _NAVIGATE_E_ #define _NAVIGATE_E_ extern int navigatingBackAndForth; extern int inHyperSpace; extern int inSlideShow; extern int visibleGridInSlideShow; extern int slideShowInfoValid; extern char * slideShowBorderColor; extern int slideShowXOffset; extern int slideShowYOffset; extern int autoHyperSpaceOnRemote; extern int allowLaunchInHyperSpace; extern int navigateRefresh; extern int goHyperSpaceInSlideShow; #ifdef _INCLUDE_FROM_NAVIGATE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_NAVIGATE_C_*/ extern int ParseXYSpec ARGS_DECL((char *spec, int *pnx, int *pny)); extern int ParseWHSpec ARGS_DECL((char *spec, int *pnw, int *pnh)); extern void CleanUpSlideShowInfo ARGS_DECL((void)); extern void CleanUpNavigate ARGS_DECL((void)); extern void InitNavigate ARGS_DECL((void)); extern void UpdateLRU ARGS_DECL((struct URLCacheRec *url_cache)); extern struct URLCacheRec *FindURLCache ARGS_DECL((char *psz_url, int update_lru)); extern void UpdateURLCache ARGS_DECL((char *psz_url, char *psz_remote_buf, char *psz_content_type, int remote_buf_sz, int is_html)); extern void BeforeNavigate ARGS_DECL((void)); extern void CommitNavigate ARGS_DECL((void)); extern void NavigateBack ARGS_DECL((void)); extern void NavigateForward ARGS_DECL((void)); extern void AdjustNavigate ARGS_DECL((void)); extern void NavigateRefresh ARGS_DECL((void)); extern void NavigateHotList ARGS_DECL((void)); extern void NavigateAddToHotList ARGS_DECL((void)); extern void NavigateSessionHistory ARGS_DECL((void)); extern void ToggleHyperSpace ARGS_DECL((int KeepSelected)); extern void NextSlide ARGS_DECL((void)); extern void PrevSlide ARGS_DECL((void)); extern void EnterSlideShow ARGS_DECL((void)); extern void LeaveSlideShow ARGS_DECL((void)); extern void SetSlideShowBorderColor ARGS_DECL((void)); extern void SetSlideShowWindowOffsets ARGS_DECL((void)); extern void ToggleVisibleGridInSlideShow ARGS_DECL((void)); extern void GoHyperSpaceInSlideShow ARGS_DECL((void)); extern void FreehandModeInSlideShow ARGS_DECL((void)); extern int RefreshSlideShowModeMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateSlideShowModeMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int SlideShowModeMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int RefreshSlideShowMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateSlideShowMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int ReadSlideShowInfo ARGS_DECL((char*)); extern void RefreshNavigateMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateNavigateMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int NavigateMenu ARGS_DECL((int X, int Y, int TrackMenubar)); #ifdef _INCLUDE_FROM_NAVIGATE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_NAVIGATE_C_*/ #endif /*_NAVIGATE_E_*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/button.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000003067�11602233310�014451� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/button.e,v 1.6 2011/05/16 16:21:56 william Exp $ */ #ifndef _BUTTON_E_ #define _BUTTON_E_ typedef struct tagButtonFontInfo { int font_style; } ButtonFontInfo; #ifdef _INCLUDE_FROM_BUTTON_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_BUTTON_C_*/ extern int ButtonWidth ARGS_DECL((char *, int, ButtonFontInfo*)); extern void DisplayButtonInBBox ARGS_DECL((Window, char *, int Len, struct BBRec *, int, int HighLight, int Width, ButtonFontInfo*)); #ifdef _INCLUDE_FROM_BUTTON_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_BUTTON_C_*/ #endif /*_BUTTON_E_*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/align.e������������������������������������������������������������������������������0000644�0000764�0000764�00000006027�11602233310�014227� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/align.e,v 1.6 2011/05/16 16:21:56 william Exp $ */ #ifndef _ALIGN_E_ #define _ALIGN_E_ extern int horiAlign; extern int vertAlign; extern int alignDirectType; #ifdef _INCLUDE_FROM_ALIGN_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_ALIGN_C_*/ extern void DistrSelObjs ARGS_DECL((void)); extern void DistributeDirect ARGS_DECL((int)); extern TgMenu *CreateDistributeDirectMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern void AlignSelObjs ARGS_DECL((void)); extern void AlignSelToPage ARGS_DECL((void)); extern void AlignSelToGrid ARGS_DECL((void)); extern void HoriAlignSubMenu ARGS_DECL((int Index)); extern void RefreshHoriAlignMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateHoriAlignMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int HoriAlignMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void VertAlignSubMenu ARGS_DECL((int Index)); extern void RefreshVertAlignMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateVertAlignMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int VertAlignMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void AlignDirect ARGS_DECL((int)); extern TgMenu *CreateAlignObjsDirectMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern TgMenu *CreateAlignToGridDirectMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern TgMenu *CreateAlignToPageDirectMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern void CenterAnEndPoint ARGS_DECL((void)); #ifdef _INCLUDE_FROM_ALIGN_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_ALIGN_C_*/ #endif /*_ALIGN_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/select.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000011716�11602233312�014417� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/select.e,v 1.7 2011/05/16 16:21:59 william Exp $ */ #ifndef _SELECT_E_ #define _SELECT_E_ extern int selLtX, selLtY, selRbX, selRbY; extern int selObjLtX, selObjLtY, selObjRbX, selObjRbY; extern int selNoLockLtX, selNoLockLtY, selNoLockRbX, selNoLockRbY; extern int selNoLockObjLtX, selNoLockObjLtY; extern int selNoLockObjRbX, selNoLockObjRbY; extern int numObjSelected; extern int numObjLocked; extern struct SelRec * topSel, * botSel; extern struct VSelRec * topVSel, * botVSel; #ifdef _INCLUDE_FROM_SELECT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_SELECT_C_*/ extern int GetObjCurved ARGS_DECL((struct ObjRec *)); extern struct SelRec *SelectThisObject ARGS_DECL((struct ObjRec *)); extern int CountSelectedVertices ARGS_DECL((void)); extern void CalcBBox ARGS_DECL((int X1, int Y1, int X2, int Y2, int *LtX, int *LtY, int *RbX, int *RbY)); extern void CalcVertexBBox ARGS_DECL((int *LtX, int *LtY, int *RbX, int *RbY)); extern void UnSelNonVertexObjs ARGS_DECL((int HighLight, int NoLockedObjOnly)); extern void FreeTopSel ARGS_DECL((void)); extern void JustFreeSel ARGS_DECL((struct SelRec *pTopSel, struct SelRec *pBotSel)); extern void UnlinkSel ARGS_DECL((struct SelRec *pSel, struct SelRec **ppTopSel, struct SelRec **ppBotSel)); extern struct SelRec *FindObjInSel ARGS_DECL((struct ObjRec *pObj, struct SelRec *pTopSel, struct SelRec *pBotSel)); extern int PrependObjToSel ARGS_DECL((struct ObjRec *pObj, struct SelRec **ppTopSel, struct SelRec **ppBotSel)); extern struct SelRec *AddObjIntoSel ARGS_DECL((struct ObjRec *pObj, struct SelRec *pPrevSel, struct SelRec *pNextSel, struct SelRec **ppTopSel, struct SelRec **ppBotSel)); extern void JustRemoveAllVSel ARGS_DECL((void)); extern void RemoveAllSel ARGS_DECL((void)); extern struct AttrRec * FindObjAttrWithName ARGS_DECL((struct ObjRec *ObjPtr, char *AttrName)); extern struct ObjRec * FindAnObj ARGS_DECL((int XOff, int YOff, struct ObjRec **OwnerObj, struct ObjRec **ConnectObj, char *ObjName)); extern struct SelRec * AlreadySelected ARGS_DECL((struct ObjRec *)); extern void AddSel ARGS_DECL((struct SelRec *Prev, struct SelRec *Next, struct SelRec *)); extern void AddNewSelObj ARGS_DECL((struct ObjRec *)); extern void ExpandCurSelBBoxes ARGS_DECL((struct ObjRec *)); extern void UpdSelBBox ARGS_DECL((void)); extern void SelBox ARGS_DECL((Window, GC, int X1, int Y1, int X2, int Y2)); extern void Select ARGS_DECL((XEvent *)); extern struct AttrRec * FindFileAttrWithName ARGS_DECL((char *AttrName)); extern struct AttrRec * FindAttrWithName ARGS_DECL((struct ObjRec *, char *AttrName, struct ObjRec **)); extern struct AttrRec * ValidAttrArg ARGS_DECL((char *CPtr, struct ObjRec *, char **NewCPtr)); extern int DoTeleport ARGS_DECL((struct AttrRec *)); extern int DoPageTeleport ARGS_DECL((struct AttrRec *, int ByPageName)); extern void DoExecLoop ARGS_DECL((struct ObjRec *, struct AttrRec *)); extern void Teleport ARGS_DECL((XButtonEvent *)); extern void SelAllObj ARGS_DECL((int HighLight, int ignore_slideshow)); extern void JustMoveSelToTop ARGS_DECL((void)); extern void MoveSelToTop ARGS_DECL((void)); extern void MoveSelToBot ARGS_DECL((void)); extern void DelAllSelObj ARGS_DECL((void)); extern void GroupSingleObj ARGS_DECL((int ForcePromoteAttrs)); extern void GroupSelObj ARGS_DECL((int highlight, int record_cmd, int redraw)); extern void SelectTopObj ARGS_DECL((void)); #ifdef _INCLUDE_FROM_SELECT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_SELECT_C_*/ #endif /*_SELECT_E_*/ ��������������������������������������������������tgif-QPL-4.2.5/mainloop.e���������������������������������������������������������������������������0000644�0000764�0000764�00000007402�11602233312�014753� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/mainloop.e,v 1.8 2011/05/16 16:21:58 william Exp $ */ #ifndef _MAINLOOP_E_ #define _MAINLOOP_E_ extern int x11R6OrAbove; extern int origArgC; extern char * * origArgV; extern int cmdLineBW; extern int cmdLineRV; extern int cmdLineCWO; extern int cmdLineBtn1Warp; extern char * cmdLineForeground; extern char * cmdLineBackground; extern char * cmdLineBorder; extern int cmdLineMerge; extern int cmdLineMergeArgc; extern char * * cmdLineMergeArgv; extern int geometrySpecified; extern int exitNormally; extern char geometrySpec[]; extern char * displayName; extern int initializingMain; extern int cmdLineUseXlib; extern int cmdLineVersion; extern int cmdLineNoModeWindow; extern int cmdLineNoChatWindow; extern KeyOrBtnEvInfo lastKeyOrBtnEvInfo; extern int numExtraWins; extern struct WinInfoRec * extraWinInfo; #ifdef _INCLUDE_FROM_MAINLOOP_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_MAINLOOP_C_*/ extern int AddExtraWinInfo ARGS_DECL((Window, int Mapped, int Raise, void (*ExposeHandler)ARGS_DECL((XEvent*, struct WinInfoRec *)), int (*EventHandler)ARGS_DECL((XEvent*, struct WinInfoRec *)), void (*CleanUpRoutine)ARGS_DECL(( struct WinInfoRec *)), void *userdata)); extern void CleanUpTalkToSelfFiledes ARGS_DECL((void)); extern int InitTalkToSelfFiledes ARGS_DECL((void)); extern void DeallocStrings ARGS_DECL((char **Func, char **Str1, char **Menu1, char **Str2, char **Menu2, char **Str3, char **Menu3)); extern void CleanUp ARGS_DECL((void)); extern void ExposeEventHandler ARGS_DECL((XEvent *, int Recursive)); extern int GzipFile ARGS_DECL((char *fname, char *gzipped_fname)); extern char *GunzipFileIntoTemp ARGS_DECL((char *gzipped_fname)); extern int JustInit ARGS_DECL((char *pszFile, int *pnNeedToCheckAutoExec)); extern void HandleDataInMBuff ARGS_DECL((void)); extern int TryProcessAnXEvent ARGS_DECL((int *pnNeedToCheckAutoExec)); extern int TryProcessAnAbortXEvent ARGS_DECL((int esc_to_abort, AbortCallbackFunc*, void*)); extern void MainLoop ARGS_DECL((char *Op, char *FileName, char **Func, char **Str1, char **Menu1, char **Str2, char **Menu2, char **Str3, char **Menu3)); extern void UrlDump ARGS_DECL((char *FileName)); extern void DosEpsFilter ARGS_DECL((char *FileName)); extern void Animate ARGS_DECL((char *Type, char *PolyId, char *Speed, char *Color, char **ReturnStr)); extern void UpdAttrVal ARGS_DECL((char *ObjId, char *AttrName, char *AttrColor, char *AttrVal, char **ReturnStr)); extern void SetLastKeyEvInfo ARGS_DECL((XKeyEvent*)); extern void SetLastBtnEvInfo ARGS_DECL((XButtonEvent*)); #ifdef _INCLUDE_FROM_MAINLOOP_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_MAINLOOP_C_*/ #endif /*_MAINLOOP_E_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Tgif.tmpl-uw7������������������������������������������������������������������������0000644�0000764�0000764�00000005133�11602233313�015276� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-uw7,v 1.11 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif CC = gcc -Wall PREPROCESSCMD = gcc -E $(STD_CPP_DEFINES) EXTRA_LDOPTIONS = EXTRA_LIBRARIES = -lsocket -lnsl -lgen LDCOMBINEFLAGS = -r CCOPTIONS = PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g XCOMM INSTPGMFLAGS= -s BINDIR = /usr/local/bin MANPATH = /usr/local/man TGIFDIR = /usr/local/lib/X11/tgif LOCALEDIR = /usr/local/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_HAS_STREAMS_SUPPORT -D_NO_IDNLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) SYS_LIBRARIES = -ldl -lm -lz XCOMM SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM UnixWare 5 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tginssym.e���������������������������������������������������������������������������0000644�0000764�0000764�00000003254�11602233313�015014� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tginssym.e,v 1.2 2011/05/16 16:22:00 william Exp $ */ #ifndef _TGINSSYM_E_ #define _TGINSSYM_E_ #ifdef _INCLUDE_FROM_TGINSSYM_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TGINSSYM_C_*/ extern void TgInsertSymbol_CleanUp ARGS_DECL((Display*, Window)); extern int TgInsertSymbol_Init ARGS_DECL((Display*, Window, char *arg)); extern void CleanUpInsertSymbol ARGS_DECL((void)); extern int InitInsertSymbol ARGS_DECL((void)); extern int TgInsertSymbol_SendKey ARGS_DECL((Display*, Window, XKeyEvent*, char*)); extern int TgInsertSymbol_HandleCntrlSpace ARGS_DECL((Display*, Window)); extern int TgInsertSymbol_HandleCreateText ARGS_DECL((Display*, Window)); #ifdef _INCLUDE_FROM_TGINSSYM_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TGINSSYM_C_*/ #endif /*_TGINSSYM_E_*/ ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgif.spec����������������������������������������������������������������������������0000644�0000764�0000764�00000005565�11602233314�014606� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%define ver 4.2.5 # # @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgif.spec.in,v 1.5 2010/09/09 02:28:12 william Exp $ # %define rel 1 %define prefix /usr/X11R6 %define name tgif Summary: tgif 2-D drawing package Summary(pl): tgif - pakiet do tworzenia grafiki 2D Name: %{name} Version: %{ver} Release: %{rel} License: custom (please see Copyright file in distribution) Group: X11/Applications/Graphics Group(pl): X11/Aplikacje/Grafika Source: ftp://bourbon.usc.edu/pub/tgif/%{name}-%{ver}.tar.gz URL: http://bourbon.usc.edu/tgif/ BuildRoot: /tmp/%{name}-%{version}-root Prefix: %prefix Packager: Roberto A. Oppedisano <rao@penguinpowered.com> Requires: xorg-x11-fonts-ISO8859-1-75dpi Requires: ghostscript Requires: netpbm-progs Requires: zlib %description Xlib based interactive 2-D drawing facility under X11. Supports hierarchical construction of drawings and easy navigation between sets of drawings. It's also a hyper-graphics (or hyper-structured-graphics) browser on the World-Wide-Web. Please see the README file for various information including copyright notices. %prep %setup -n tgif-%{ver} %build xmkmf make %install [ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf $RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT%{prefix}/bin mkdir -p $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif mkdir -p $RPM_BUILD_ROOT%{prefix}/man/man1 install -s tgif $RPM_BUILD_ROOT%{prefix}/bin/tgif install -c -m 0444 tgif.Xdefaults $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tgificon.eps $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tgificon.obj $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tgificon.xbm $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tgificon.xpm $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tangram.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4-2x.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4-ps2epsi.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4-epstool.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4xpm.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4-lyx-ps2epsi.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 eq4-2x-nowin-jpg.sym $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 keys.obj $RPM_BUILD_ROOT%{prefix}/lib/X11/tgif install -c -m 0444 tgif.man $RPM_BUILD_ROOT%{prefix}/man/man1/tgif.1 %clean [ -n "$RPM_BUILD_ROOT" -a "$RPM_BUILD_ROOT" != / ] && rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root) %doc README Copyright HISTORY %{prefix}/bin/tgif %{prefix}/lib/X11/tgif ################################################################ # Note: For RedHat 7.0 or above, use the value below. If you # # have RedHat 6.x, you should delete the .gz at the end. # ################################################################ %{prefix}/man/man1/tgif.1.gz �������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/eq4-2x.sym���������������������������������������������������������������������������0000644�0000764�0000764�00000044311�11602233311�014540� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.43 state(0,37,100.000,0,0,0,8,1,3,1,1,0,0,1,0,1,0,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/eq4-2x.sym,v 1.2 2004/08/31 23:54:51 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1 ]). slideshow_info('',-20,-20). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). dont_reencode("UtopiaFS:FFDingbests:ZapfDingbats"). ps_font_aliases([ "UtopiaFS-Regular=Utopia-Regular", "UtopiaFS-Bold=Utopia-Bold", "UtopiaFS-Italic=Utopia-Italic", "UtopiaFS-BoldItalic=Utopia-BoldItalic" ]). page(1,"2x resolution LaTeX equation symbol.",1,''). group([ group([ text('#0000ff',224,106,5,0,1,378,81,657,14,3,0,-1,0,0,2,378,81,0,2,"",0,0,0,0,120,'',[ minilines(378,81,0,2,0,-1,0,[ mini_line(360,14,3,0,2,0,[ str_block(0,360,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,360,14,3,0,2,0,0,0,0,0, "This version of the LaTeX equation symbol by default")]) ]), mini_line(356,14,3,0,2,0,[ str_block(0,122,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,122,14,3,0,2,0,0,0,0,0, "uses its internal \"")]), str_block(0,59,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,59,14,3,0,2,0,0,0,0,0, "pstoepsi")]), str_block(0,175,14,3,0,1,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,175,14,3,0,1,0,0,0,0,0, "\" to add a preview bitmap")]) ]), mini_line(339,14,3,0,2,0,[ str_block(0,182,14,3,0,-3,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,182,14,3,0,-3,0,0,0,0,0, "to a PS file. If want to use ")]), str_block(0,87,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,87,14,3,0,2,0,0,0,0,0, "an external \"")]), str_block(0,59,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,59,14,3,0,2,0,0,0,0,0, "pstoepsi")]), str_block(0,11,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,11,14,3,0,-1,0,0,0,0,0, "\",")]) ]), mini_line(378,14,3,0,2,0,[ str_block(0,378,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,378,14,3,0,2,0,0,0,0,0, "please set the Tgif.ExternalPsToEpsi X default to \"true\"")]) ]), mini_line(134,14,3,0,0,0,[ str_block(0,134,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,134,14,3,0,-1,0,0,0,0,0, "and see (2b) below.")]) ]) ])]), text('#0000ff',192,106,1,0,1,27,17,846,14,3,0,0,0,0,2,27,17,0,0,"",0,0,0,0,120,'',[ minilines(27,17,0,0,0,0,0,[ mini_line(27,14,3,0,0,0,[ str_block(0,27,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,27,14,3,0,0,0,0,0,0,0, "(2a)")]) ]) ])]) ], 1270,0,0,[ ]), group([ text('#0000ff',224,50,3,0,1,362,49,643,14,3,0,-1,0,0,2,362,49,0,1,"",0,0,0,0,64,'',[ minilines(362,49,0,1,0,-1,0,[ mini_line(325,14,3,0,1,0,[ str_block(0,189,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,189,14,3,0,-3,0,0,0,0,0, "Make sure you are running ")]), str_block(0,68,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,68,14,3,0,1,0,0,0,0,0, "tgif-4.1.44")]), str_block(0,68,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,68,14,3,0,-1,0,0,0,0,0, " or newer.")]) ]), mini_line(362,14,3,0,1,0,[ str_block(0,362,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,1,0,0,0,0,0, "You can find out what version of tgif you are running")]) ]), mini_line(300,14,3,0,0,0,[ str_block(0,300,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,300,14,3,0,-1,0,0,0,0,0, "by selecting About() from the Special menu.")]) ]) ])]), text('#0000ff',192,50,1,0,1,19,17,863,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,64,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(1)")]) ]) ])]) ], 1258,0,0,[ ]), group([ text('#0000ff',224,194,11,0,1,413,177,657,14,3,0,-1,0,0,2,413,177,0,2,"",0,0,0,0,208,'',[ minilines(413,177,0,2,0,-1,0,[ mini_line(351,14,3,0,1,0,[ str_block(0,351,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,351,14,3,0,1,0,0,0,0,0, "This version of the LaTeX equation symbol uses the")]) ]), mini_line(391,14,3,0,2,0,[ str_block(0,158,14,3,0,2,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,158,14,3,0,2,0,0,0,0,0, "20may1999 version of \"")]), str_block(0,59,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,59,14,3,0,2,0,0,0,0,0, "pstoepsi")]), str_block(0,174,14,3,0,1,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,174,14,3,0,1,0,0,0,0,0, "\" to add a 144dpi preview")]) ]), mini_line(394,14,3,0,2,0,[ str_block(0,328,14,3,0,2,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,328,14,3,0,2,0,0,0,0,0, "bitmap to a PS file. This 20may1999 version of \"")]), str_block(0,59,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,59,14,3,0,2,0,0,0,0,0, "pstoepsi")]), str_block(0,7,14,3,0,2,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,7,14,3,0,2,0,0,0,0,0, "\"")]) ]), mini_line(407,14,3,0,2,0,[ str_block(0,69,14,3,0,2,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,69,14,3,0,2,0,0,0,0,0, "requires \"")]), str_block(0,132,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,132,14,3,0,1,0,0,0,0,0, "netpbm-20may1999")]), str_block(0,115,14,3,0,-3,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,115,14,3,0,-3,0,0,0,0,0, "\". If want to use ")]), str_block(0,91,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,91,14,3,0,1,0,0,0,0,0, "ghostscript's")]) ]), mini_line(400,14,3,0,2,0,[ str_block(0,7,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,7,14,3,0,2,0,0,0,0,0, "\"")]), str_block(0,54,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,54,14,3,0,2,0,0,0,0,0, "ps2epsi")]), str_block(0,155,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,155,14,3,0,2,0,0,0,0,0, "\" instead, please use \"")]), str_block(0,115,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,115,14,3,0,1,0,0,0,0,0, "eq4-ps2epsi.sym")]), str_block(0,69,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,69,14,3,0,2,0,0,0,0,0, "\". If you'd")]) ]), mini_line(413,14,3,0,2,0,[ str_block(0,413,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,413,14,3,0,2,0,0,0,0,0, "like a lower (standard) resolution preview bitmap (which will")]) ]), mini_line(404,14,3,0,1,0,[ str_block(0,404,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,404,14,3,0,1,0,0,0,0,0, "also result in a smaller file -- but won't look too good on the")]) ]), mini_line(397,14,3,0,2,0,[ str_block(0,146,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,146,14,3,0,2,0,0,0,0,0, "screen), please use \"")]), str_block(0,56,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,56,14,3,0,1,0,0,0,0,0, "ps4.sym")]), str_block(0,195,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,195,14,3,0,2,0,0,0,0,0, "\" instead. Information about")]) ]), mini_line(280,14,3,0,2,0,[ str_block(0,184,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,184,14,3,0,2,0,0,0,0,0, "the 20may1999 version of \"")]), str_block(0,59,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,59,14,3,0,2,0,0,0,0,0, "pstoepsi")]), str_block(0,37,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,37,14,3,0,2,0,0,0,0,0, "\" and")]) ]), mini_line(295,14,3,0,2,0,[ str_block(0,7,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,7,14,3,0,2,0,0,0,0,0, "\"")]), str_block(0,132,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,132,14,3,0,1,0,0,0,0,0, "netpbm-20may1999")]), str_block(0,156,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,156,14,3,0,1,0,0,0,0,0, "\" can be obtained from")]) ]), mini_line(373,14,3,0,2,0,[ str_block(0,42,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,42,14,3,0,1,0,0,0,0,0, "<URL:")]), str_block(0,318,14,3,0,2,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,318,14,3,0,2,0,0,0,0,0, "http://bourbon.cs.umd.edu:8001/tgif/tools.html")]), str_block(0,13,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,13,14,3,0,-1,0,0,0,0,0, ">.")]) ]) ])]), text('#0000ff',192,194,1,0,1,28,17,846,14,3,0,0,0,0,2,28,17,0,0,"",0,0,0,0,208,'',[ minilines(28,17,0,0,0,0,0,[ mini_line(28,14,3,0,0,0,[ str_block(0,28,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,28,14,3,0,0,0,0,0,0,0, "(2b)")]) ]) ])]) ], 1261,0,0,[ ]), group([ text('#0000ff',192,378,1,0,1,19,17,1021,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,392,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(3)")]) ]) ])]), text('#0000ff',224,378,4,0,1,403,66,1022,14,3,0,-1,0,0,2,403,66,0,2,"",0,0,0,0,392,'',[ minilines(403,66,0,2,0,-1,0,[ mini_line(403,14,4,0,2,0,[ str_block(0,107,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,107,14,3,0,-2,0,0,0,0,0, "Make sure that ")]), str_block(0,32,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,32,14,3,0,2,0,0,0,0,0, "latex")]), str_block(0,8,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,8,14,3,0,-3,0,0,0,0,0, ", ")]), str_block(0,38,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,38,14,3,0,1,0,0,0,0,0, "dvips")]), str_block(0,38,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,38,14,3,0,-2,0,0,0,0,0, ", and ")]), str_block(0,59,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,59,14,3,0,2,0,0,0,0,0, "pstoepsi")]), str_block(0,81,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,81,14,3,0,-2,0,0,0,0,0, " are in your ")]), str_block(0,36,12,4,0,0,0,0,0,[ str_seg('#ff00ff','Courier-Bold',1,80640,36,12,4,0,0,0,0,0,0,0, "PATH")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]), mini_line(370,14,3,0,1,0,[ str_block(0,228,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,228,14,3,0,-3,0,0,0,0,0, "After you instantiate this symbol, ")]), str_block(0,84,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,84,14,3,0,1,0,0,0,0,0, "double-click")]), str_block(0,58,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,58,14,3,0,1,0,0,0,0,0, " it to run")]) ]), mini_line(389,14,3,0,0,0,[ str_block(0,362,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,-3,0,0,0,0,0, "the latex scripts. Afterwards, you can hide/show the ")]), str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, "eq=")]) ]), mini_line(247,14,3,0,1,0,[ str_block(0,148,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,148,14,3,0,-3,0,0,0,0,0, "attribute by pressing ")]), str_block(0,95,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,95,14,3,0,1,0,0,0,0,0, "<Alt><Cntrl>7")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]) ])]) ], 1264,0,0,[ ]) ], 1381,0,0,[ ]). sym([ polygon('#0000ff','',5,[ 64,132,68,132,68,128,64,128,64,132],0,1,0,0,212,0,0,0,0,0,'1',0, "00",[ ]) ], 1116,0,0,[ attr("footer=", "", 0, 1, 0, text('#ff00ff',64,-21,3,0,1,126,48,613,13,3,0,0,0,0,2,126,48,0,0,"",0,0,0,0,-8,'',[ minilines(126,48,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "footer=")]) ]), mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,13,3,0,-1,0,0,0,0,0, "%")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,13,3,0,-4,0,0,0,0,0, "\\end{document}")]) ]) ])])), attr("header=", "", 0, 1, 0, text('#ff00ff',240,-21,11,0,1,270,176,608,13,3,0,0,0,0,2,270,176,0,0,"",0,0,0,0,-8,'',[ minilines(270,176,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "header=")]) ]), mini_line(261,13,3,0,0,0,[ str_block(0,261,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,261,13,3,0,-4,0,0,0,0,0, "\\documentstyle[12pt]{article}")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,162,13,3,0,-1,0,0,0,0,0, "\\oddsidemargin=0in")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "\\textwidth=6.5in")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,13,3,0,-1,0,0,0,0,0, "\\topmargin=0in")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,13,3,0,-2,0,0,0,0,0, "\\textheight=609pt")]) ]), mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,117,13,3,0,-2,0,0,0,0,0, "\\parskip=14pt")]) ]), mini_line(270,13,3,0,0,0,[ str_block(0,270,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,270,13,3,0,-4,0,0,0,0,0, "\\setlength{\\unitlength}{0.5cm}")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,13,3,0,-4,0,0,0,0,0, "\\pagestyle{empty}")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,3,0,-4,0,0,0,0,0, "\\begin{document}")]) ]), mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,13,3,0,-1,0,0,0,0,0, "%")]) ]) ])])), attr("exec=", "", 0, 1, 0, text('blue',64,-272,9,0,1,477,144,1368,13,3,0,0,0,0,2,477,144,0,0,"",0,0,0,0,-259,'',[ minilines(477,144,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "exec=")]) ]), mini_line(378,13,3,0,0,0,[ str_block(0,378,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,378,13,3,0,-4,0,0,0,0,0, " mktemp(\"/tmp/TgifXXXXXX\",\"file_name\");")]) ]), mini_line(468,13,3,0,0,0,[ str_block(0,468,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,468,13,3,0,-4,0,0,0,0,0, " write_attr_into_file(header,\"$(file_name).tex\");")]) ]), mini_line(441,13,3,0,0,0,[ str_block(0,441,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,441,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(eq,\"$(file_name).tex\");")]) ]), mini_line(477,13,3,0,0,0,[ str_block(0,477,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,477,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(footer,\"$(file_name).tex\");")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,162,13,3,0,-4,0,0,0,0,0, " launch(\"cmd\");")]) ]), mini_line(477,13,3,0,0,0,[ str_block(0,477,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,477,13,3,0,-4,0,0,0,0,0, " pstoepsi(\"$(file_name).eps\",\"$(file_name).ps\",2);")]) ]), mini_line(369,13,3,0,0,0,[ str_block(0,369,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,369,13,3,0,-4,0,0,0,0,0, " update_eps_child(\"$(file_name).eps\");")]) ]), mini_line(189,13,3,0,0,0,[ str_block(0,189,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,189,13,3,0,-4,0,0,0,0,0, " launch(\"cleanup\")")]) ]) ])])), attr("cmd=", "", 0, 1, 0, text('blue',64,-152,4,0,1,702,64,1138,13,3,0,0,0,0,2,702,64,0,0,"",0,0,0,0,-139,'',[ minilines(702,64,0,0,0,0,0,[ mini_line(36,13,3,0,0,0,[ str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, "cmd=")]) ]), mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-4,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(459,13,3,0,0,0,[ str_block(0,459,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,459,13,3,0,-4,0,0,0,0,0, " xterm -geom 40x8+200+400 -e latex $(file_name);")]) ]), mini_line(702,13,3,0,0,0,[ str_block(0,702,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,702,13,3,0,-4,0,0,0,0,0, " xterm -geom 40x8+200+400 -e dvips -N -n 1 -o $(file_name).ps $(file_name);")]) ]) ])])), attr("cleanup=", "", 0, 1, 0, text('blue',64,-72,3,0,1,540,48,165,13,3,0,0,0,0,2,540,48,0,0,"",0,0,0,0,-59,'',[ minilines(540,48,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "cleanup=")]) ]), mini_line(540,13,3,0,0,0,[ str_block(0,540,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,540,13,3,0,-2,0,0,0,0,0, " rm -f $(file_name).tex $(file_name).aux $(file_name).dvi")]) ]), mini_line(513,13,3,0,0,0,[ str_block(0,513,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,513,13,3,0,-2,0,0,0,0,0, " $(file_name).log $(file_name).ps $(file_name).eps")]) ]) ])])), attr("file_name=", "", 0, 1, 0, text('blue',64,32,1,0,1,90,16,29,13,3,0,0,0,0,2,90,16,0,0,"",0,0,0,0,45,'',[ minilines(90,16,0,0,0,0,0,[ mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, "file_name=")]) ]) ])])), attr("eq=", "", 1, 1, 0, text('blue',64,48,5,0,1,135,80,25,13,3,0,0,0,0,2,135,80,0,0,"",0,0,0,0,61,'',[ minilines(135,80,0,0,0,0,0,[ mini_line(27,13,3,0,0,0,[ str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, "eq=")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "\\LARGE")]) ]), mini_line(18,13,3,0,0,0,[ str_block(0,18,13,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,18,13,3,0,-3,0,0,0,0,0, "\\[")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,135,13,3,0,-2,0,0,0,0,0, " E\\,=\\,M\\,C^2")]) ]), mini_line(18,13,3,0,0,0,[ str_block(0,18,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,18,13,3,0,-4,0,0,0,0,0, "\\]")]) ]) ])])), attr("", "not_rigid", 0, 1, 0, text('blue',64,152,1,0,1,81,16,535,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,165,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "not_rigid")]) ]) ])])) ]). �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/raster.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000006673�11602233312�014446� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/raster.e,v 1.12 2011/05/16 16:21:59 william Exp $ */ #ifndef _RASTER_E_ #define _RASTER_E_ extern GC rasterGC; extern GC patGC; extern unsigned long xorOne; extern unsigned long xorZero; extern GC drawGC; extern GC drawSBGC; extern GC defaultGC; extern GC revDefaultGC; extern GC revGrayGC; extern Pixmap rotateModePixmap[]; extern Pixmap choicePixmap[]; extern Pixmap patPixmap[]; extern Pixmap * lineWidthPixmap; extern Pixmap lineTypePixmap[]; extern Pixmap lineDashPixmap[]; extern Pixmap lineStylePixmap[]; extern Pixmap justPixmap[]; extern Pixmap alignHoriPixmap[]; extern Pixmap alignVertPixmap[]; extern Pixmap alignDirectPixmap[]; extern Pixmap distrDirectPixmap[]; extern Pixmap filePixmap; extern Pixmap landscapePixmap; extern Pixmap specialPixmap; extern Pixmap vspacePixmap; extern Pixmap rcbRadiusPixmap; extern Pixmap moveModePixmap[]; extern Pixmap editPixmap; extern Pixmap intrPixmap[]; extern Pixmap trekPixmap; extern Pixmap pageLayoutPixmap[]; extern Pixmap scrollPixmap[]; extern Pixmap scrlBitmap[]; extern Pixmap shapePixmap[]; extern Pixmap stretchableModePixmap[]; extern Pixmap transPatPixmap[]; extern Pixmap rotatePixmap[]; extern Pixmap * whereToPrintPixmap; extern Pixmap * shortLineWidthPixmap; extern Pixmap shortLineStylePixmap[]; extern Pixmap shortLineTypePixmap[]; extern Pixmap shortDashPixmap[]; extern Pixmap wireBitmap; extern Pixmap runBitmap; extern Pixmap checkBitmap; extern Pixmap radioBitmap; extern Pixmap submenuBitmap; extern Pixmap graySubmenuBitmap; extern Pixmap userRedrawBitmap; extern Pixmap statusBtnPixmap[]; extern Pixmap msgBoxPixmap[]; extern int maxLineWidths; extern int maxWhereToPrint; extern int dashListLength[]; extern char *dashList[]; #ifdef _INCLUDE_FROM_RASTER_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_RASTER_C_*/ extern void InitPatFill ARGS_DECL((void)); extern void Init2PatFill ARGS_DECL((void)); extern void InitPattern ARGS_DECL((void)); extern void RedrawChoiceWindow ARGS_DECL((void)); extern void CleanUpPatFill ARGS_DECL((void)); extern void CleanUpRasters ARGS_DECL((void)); extern int UpgradePenFill ARGS_DECL((int)); extern unsigned char ByteReverse ARGS_DECL((unsigned char)); extern void GetPatternCellsize ARGS_DECL((int pat_index, int *pn_cell_w, int *pn_cell_h)); extern unsigned char *GetPatternBytes ARGS_DECL((int pat_index, int *pn_num_bytes, int *pn_need_to_free)); #ifdef _INCLUDE_FROM_RASTER_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_RASTER_C_*/ #endif /*_RASTER_E_*/ ���������������������������������������������������������������������tgif-QPL-4.2.5/inmethod.e���������������������������������������������������������������������������0000644�0000764�0000764�00000010475�11602233311�014747� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/inmethod.e,v 1.7 2011/05/16 16:21:58 william Exp $ */ #ifndef _INMETHOD_E_ #define _INMETHOD_E_ typedef char *(Tgim_stringprep_convert_Func)ARGS_DECL((const char *str, const char *to_codeset, const char *from_codeset)); extern int gnInputMethod; /* one of TGIM_* */ extern int gnOverTheSpot; extern int cmdLineHasInputMethod; extern int cmdLineDoubleByteInputMethod; extern char cmdLineInputMethod[]; #ifdef _INCLUDE_FROM_INMETHOD_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_INMETHOD_C_*/ extern int Tgim_has_stringprep_convert ARGS_DECL((void)); extern char *Tgim_stringprep_convert ARGS_DECL((const char *str, const char *to_codeset, const char *from_codeset)); extern void CleanUpInputMethods ARGS_DECL((void)); extern int InitInputMethods ARGS_DECL((void)); extern int ResetInputMethod ARGS_DECL((void)); extern int InputMethodTypeMatched ARGS_DECL((int DoubleByte)); extern int tgIMFocusIn ARGS_DECL((Display *dpy, Window win)); extern int tgIMFocusOut ARGS_DECL((Display *dpy, Window win)); extern int tgIMTranslateKeyEvent ARGS_DECL((Display *dpy, Window win, XKeyEvent *key_ev, char *buf)); extern int tgIMConvertProperty ARGS_DECL((Display *dpy, Window win, XPropertyEvent *prop_ev, char **ppsz_buf)); extern int tgIMExpectClientMessage ARGS_DECL((Display *dpy, Window win)); extern int tgIMHandleClientMessage ARGS_DECL((Display *dpy, Window win, XClientMessageEvent *cm_ev, XKeyEvent *key_ev, char *buf)); extern int tgIMActiveOnCntrlSpace ARGS_DECL((Display *dpy, Window win)); extern int tgIMHandleCntrlSpace ARGS_DECL((Display *dpy, Window win)); extern int tgIMDeactiveOnCreateText ARGS_DECL((Display *dpy, Window win)); extern int tgIMHandleCreateText ARGS_DECL((Display *dpy, Window win)); extern int tgIMTellCursorPosition ARGS_DECL((Display *dpy, Window win, int cur_x, int cur_y)); extern int tgIMExpectNextEvent ARGS_DECL((Display *dpy, Window win)); extern int tgIMHandleNextEvent ARGS_DECL((Display *dpy, Window win, XEvent *ev)); extern int tgIMHandleNewCurText ARGS_DECL((Display *dpy, Window win)); extern int tgIMExpectLookupString ARGS_DECL((Display *dpy, Window win)); extern int tgIMHandleLookupString ARGS_DECL((Display *dpy, Window win, XKeyEvent *key_ev, char *psz_buf, int buf_size, KeySym *p_key_sym, int *pn_has_ch)); #ifdef _INCLUDE_FROM_INMETHOD_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_INMETHOD_C_*/ #endif /*_INMETHOD_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/group.c������������������������������������������������������������������������������0000644�0000764�0000764�00000050224�11602233311�014266� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/group.c,v 1.7 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_GROUP_C_ #include "tgifdefs.h" #include "attr.e" #include "choice.e" #include "cmd.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "group.e" #include "mark.e" #include "msg.e" #include "obj.e" #include "page.e" #include "select.e" #include "setup.e" #include "strtbl.e" int gnDeleteAttrsWhileUngrouping=FALSE; struct ObjRec *JustCreateGroupObj() { struct GroupRec *group_ptr=NULL; struct ObjRec *obj_ptr=NULL; group_ptr = (struct GroupRec *)malloc(sizeof(struct GroupRec)); if (group_ptr == NULL) FailAllocMessage(); memset(group_ptr, 0, sizeof(struct GroupRec)); group_ptr->first = NULL; group_ptr->last = NULL; group_ptr->rotate = ROTATE0; group_ptr->flip = NO_FLIP; group_ptr->deck_index = (-1); group_ptr->pin_connected = 0; group_ptr->first_conn = group_ptr->last_conn = NULL; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); obj_ptr->x = 0; obj_ptr->y = 0; obj_ptr->id = objId++; obj_ptr->locked = FALSE; obj_ptr->type = OBJ_GROUP; obj_ptr->bbox.ltx = 0; obj_ptr->bbox.lty = 0; obj_ptr->bbox.rbx = 0; obj_ptr->bbox.rby = 0; obj_ptr->obbox.ltx = 0; obj_ptr->obbox.lty = 0; obj_ptr->obbox.rbx = 0; obj_ptr->obbox.rby = 0; obj_ptr->detail.r = group_ptr; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; obj_ptr->invisible = FALSE; return obj_ptr; } void CreateGroupObj(TopObjPtr, BotObjPtr) struct ObjRec *TopObjPtr, *BotObjPtr; { struct ObjRec *obj_ptr=JustCreateGroupObj(); struct GroupRec *group_ptr=obj_ptr->detail.r; group_ptr->first = TopObjPtr; group_ptr->last = BotObjPtr; obj_ptr->x = selObjLtX; /* note: selLtX, selLtY are absolute */ obj_ptr->y = selObjLtY; obj_ptr->bbox.ltx = selLtX; obj_ptr->bbox.lty = selLtY; obj_ptr->bbox.rbx = selRbX; obj_ptr->bbox.rby = selRbY; obj_ptr->obbox.ltx = selObjLtX; obj_ptr->obbox.lty = selObjLtY; obj_ptr->obbox.rbx = selObjRbX; obj_ptr->obbox.rby = selObjRbY; if (numObjLocked > 0) obj_ptr->locked = TRUE; AddObj(NULL, topObj, obj_ptr); } void SaveGroupObj(FP, ObjPtr, Level) FILE *FP; struct ObjRec *ObjPtr; int Level; { if (fprintf(FP, "group([\n") == EOF) writeFileFailed = TRUE; Save(FP, ObjPtr->detail.r->last, Level+1, INVALID); if (fprintf(FP, "],\n") == EOF) writeFileFailed = TRUE; if (fprintf(FP, "%1d,%1d,%1d,", ObjPtr->id, ObjPtr->locked, ObjPtr->invisible) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, "\t"); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } void SaveCompObj(FP, ObjPtr, Level) FILE *FP; struct ObjRec *ObjPtr; int Level; { if (fprintf(FP, "sym([\n") == EOF) writeFileFailed = TRUE; Save(FP, ObjPtr->detail.r->last, Level+1, INVALID); if (fprintf(FP, "],\n") == EOF) writeFileFailed = TRUE; if (fprintf(FP, "%1d,%1d,%1d,", ObjPtr->id, ObjPtr->locked, ObjPtr->invisible) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, "\t"); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } void SaveIconObj(FP, ObjPtr, Level) FILE *FP; struct ObjRec *ObjPtr; int Level; { if (fprintf(FP, "icon([\n") == EOF) writeFileFailed = TRUE; Save(FP, ObjPtr->detail.r->last, Level+1, INVALID); if (fprintf(FP, "],\n") == EOF) writeFileFailed = TRUE; if (fprintf(FP, "\"%s\",%1d,%1d,%1d,%1d,%1d,", ObjPtr->detail.r->s, ObjPtr->id, ObjPtr->detail.r->rotate, ObjPtr->detail.r->flip, ObjPtr->locked, ObjPtr->invisible) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, "\t"); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } void SavePinObj(FP, ObjPtr, Level) FILE *FP; struct ObjRec *ObjPtr; int Level; { if (fprintf(FP, "pin([\n") == EOF) writeFileFailed = TRUE; Save(FP, ObjPtr->detail.r->last, Level+1, INVALID); if (fprintf(FP, "],\n") == EOF) writeFileFailed = TRUE; /* * Need to check for pins. * Need to handle the case where connection objects need to be dupped! */ if (fprintf(FP, "\"%s\",%1d,%1d,%1d,%1d,%1d,%1d,", ObjPtr->detail.r->s, ObjPtr->id, ObjPtr->detail.r->rotate, ObjPtr->detail.r->flip, ObjPtr->locked, ObjPtr->invisible, ObjPtr->detail.r->pin_connected) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, "\t"); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } static int gnPinWarning=FALSE; #define GETGROUPVALUE(val,name) ScanValue("%d", &(val), name, "group") #define GETSYMVALUE(val,name) ScanValue("%d", &(val), name, "sym") #define GETICONVALUE(val,name) ScanValue("%d", &(val), name, "icon") #define GETPINVALUE(val,name) ScanValue("%d", &(val), name, "pin") void ReadGroupObj(FP, ObjType, ObjPtr) FILE *FP; int ObjType; struct ObjRec **ObjPtr; { struct GroupRec *group_ptr; struct ObjRec *top_obj=NULL, *bot_obj=NULL, *obj_ptr; int ltx, lty, rbx, rby, id=0, locked=FALSE; int obj_ltx, obj_lty, obj_rbx, obj_rby, rotate=0, flip=0; int invisible=FALSE, pin_connected=0; char line[MAXSTRING+1], *s, *s1, tmp_str[MAXSTRING+1]; *ObjPtr = NULL; while (ReadObj(FP, &obj_ptr)) { if (obj_ptr == NULL) return; obj_ptr->next = top_obj; if (top_obj == NULL) { bot_obj = obj_ptr; } else { top_obj->prev = obj_ptr; } top_obj = obj_ptr; } if (top_obj == NULL) return; if (fileVersion <= 20 && (ObjType==OBJ_GROUP || ObjType==OBJ_SYM)) { id = objId++; } else { if (fgets(line, MAXSTRING, FP) == NULL) return; scanLineNum++; switch (ObjType) { case OBJ_GROUP: InitScan(line, "\t\n, []"); if (fileVersion <= 25) { if (GETGROUPVALUE(id, "id") == INVALID) return; } else if (fileVersion <= 32) { if (GETGROUPVALUE(id, "id") == INVALID || GETGROUPVALUE(locked, "locked") == INVALID) { return; } } else { if (GETGROUPVALUE(id, "id") == INVALID || GETGROUPVALUE(locked, "locked") == INVALID || GETGROUPVALUE(invisible, "invisible") == INVALID) { return; } } if (id >= objId) objId = id+1; break; case OBJ_SYM: InitScan(line, "\t\n, []"); if (fileVersion <= 25) { if (GETSYMVALUE(id, "id") == INVALID) return; } else if (fileVersion <= 32) { if (GETSYMVALUE(id, "id") == INVALID || GETSYMVALUE(locked, "locked") == INVALID) { return; } } else { if (GETSYMVALUE(id, "id") == INVALID || GETSYMVALUE(locked, "locked") == INVALID || GETSYMVALUE(invisible, "invisible") == INVALID) { return; } } if (id >= objId) objId = id+1; break; case OBJ_ICON: strcpy(tmp_str, FindChar((int)'"', line)); s = FindChar((int)'"', tmp_str); if (fileVersion == INVALID) return; if (fileVersion <= 12) { s1 = FindChar((int)',', s); InitScan(s1, "\t\n, "); if (GETICONVALUE(id, "id") == INVALID) return; } else if (fileVersion <= 25) { s1 = FindChar((int)',', s); InitScan(s1, "\t\n, "); if (GETICONVALUE(id, "id") == INVALID || GETICONVALUE(rotate, "rotation") == INVALID || GETICONVALUE(flip, "flip") == INVALID) { return; } } else if (fileVersion <= 32) { s1 = FindChar((int)',', s); InitScan(s1, "\t\n, "); if (GETICONVALUE(id, "id") == INVALID || GETICONVALUE(rotate, "rotation") == INVALID || GETICONVALUE(flip, "flip") == INVALID || GETICONVALUE(locked, "locked") == INVALID) { return; } } else { s1 = FindChar((int)',', s); InitScan(s1, "\t\n, "); if (GETICONVALUE(id, "id") == INVALID || GETICONVALUE(rotate, "rotation") == INVALID || GETICONVALUE(flip, "flip") == INVALID || GETICONVALUE(locked, "locked") == INVALID || GETICONVALUE(invisible, "invisible") == INVALID) { return; } } if (id >= objId) objId = id+1; *(--s) = '\0'; break; case OBJ_PIN: strcpy(tmp_str, FindChar((int)'"', line)); s = FindChar((int)'"', tmp_str); if (fileVersion == INVALID) return; if (fileVersion >= 34) { s1 = FindChar((int)',', s); InitScan(s1, "\t\n, "); /* * Need to check for pins. * Need to handle the case where connection objects need to be dupped! */ if (GETPINVALUE(id, "id") == INVALID || GETPINVALUE(rotate, "rotation") == INVALID || GETPINVALUE(flip, "flip") == INVALID || GETPINVALUE(locked, "locked") == INVALID || GETPINVALUE(invisible, "invisible") == INVALID || GETPINVALUE(pin_connected, "pin_connected") == INVALID) { return; } } if (id >= objId) objId = id+1; *(--s) = '\0'; if (!gnPinWarning) { gnPinWarning = TRUE; strcpy(gszMsgBox, TgLoadString(STID_WARN_PIN_NOT_SUPPORTED)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, STOP_MB); } } break; } } *ObjPtr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (*ObjPtr == NULL) FailAllocMessage(); memset(*ObjPtr, 0, sizeof(struct ObjRec)); top_obj->prev = NULL; group_ptr = (struct GroupRec *)malloc(sizeof(struct GroupRec)); if (group_ptr == NULL) FailAllocMessage(); memset(group_ptr, 0, sizeof(struct GroupRec)); group_ptr->first = top_obj; group_ptr->last = bot_obj; group_ptr->rotate = rotate; group_ptr->flip = flip; group_ptr->deck_index = (-1); group_ptr->pin_connected = pin_connected; group_ptr->first_conn = group_ptr->last_conn = NULL; if (ObjType == OBJ_ICON || ObjType == OBJ_PIN) { strcpy(group_ptr->s, tmp_str); } ltx = top_obj->bbox.ltx; lty = top_obj->bbox.lty; rbx = top_obj->bbox.rbx; rby = top_obj->bbox.rby; obj_ltx = top_obj->obbox.ltx; obj_lty = top_obj->obbox.lty; obj_rbx = top_obj->obbox.rbx; obj_rby = top_obj->obbox.rby; for (obj_ptr = top_obj->next; obj_ptr != NULL; obj_ptr = obj_ptr->next) { if (obj_ptr->bbox.ltx < ltx) ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < lty) lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > rbx) rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > rby) rby = obj_ptr->bbox.rby; if (obj_ptr->obbox.ltx < obj_ltx) obj_ltx = obj_ptr->obbox.ltx; if (obj_ptr->obbox.lty < obj_lty) obj_lty = obj_ptr->obbox.lty; if (obj_ptr->obbox.rbx > obj_rbx) obj_rbx = obj_ptr->obbox.rbx; if (obj_ptr->obbox.rby > obj_rby) obj_rby = obj_ptr->obbox.rby; } (*ObjPtr)->x = obj_ltx; (*ObjPtr)->y = obj_lty; (*ObjPtr)->dirty = FALSE; (*ObjPtr)->id = id; (*ObjPtr)->locked = locked; (*ObjPtr)->type = ObjType; (*ObjPtr)->bbox.ltx = ltx; (*ObjPtr)->bbox.lty = lty; (*ObjPtr)->bbox.rbx = rbx; (*ObjPtr)->bbox.rby = rby; (*ObjPtr)->obbox.ltx = obj_ltx; (*ObjPtr)->obbox.lty = obj_lty; (*ObjPtr)->obbox.rbx = obj_rbx; (*ObjPtr)->obbox.rby = obj_rby; (*ObjPtr)->detail.r = group_ptr; (*ObjPtr)->ctm = NULL; (*ObjPtr)->invisible = invisible; } void FreeGroupObj(ObjPtr) struct ObjRec *ObjPtr; { register struct ObjRec *ptr, *next_obj; for (ptr=ObjPtr->detail.r->first; ptr != NULL; ptr=next_obj) { next_obj = ptr->next; FreeObj(ptr); } free(ObjPtr->detail.r); free(ObjPtr); } void UngroupObj(ObjPtr, TopSelPtr, BotSelPtr) struct ObjRec *ObjPtr; struct SelRec **TopSelPtr, **BotSelPtr; /* ungroup the grouped object ObjPtr to a list of objects */ /* when returns, a list of select pointers will be created, */ /* *TopSelPtr will point to the top of the list, and */ /* *BotSelPtr will point to the bottom of the list. */ { struct ObjRec *obj_ptr=ObjPtr->detail.r->last; for ( ; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { AddObjIntoSel(obj_ptr, NULL, *TopSelPtr, TopSelPtr, BotSelPtr); } (*TopSelPtr)->prev = NULL; } static int NoObjToUngroup(pn_force_ungroup) int *pn_force_ungroup; { struct SelRec *sel_ptr=NULL; int every_obj_is_sym_or_icon=TRUE; if (pn_force_ungroup != NULL && topSel != NULL && topSel == botSel) { int obj_type=topSel->obj->type; *pn_force_ungroup = FALSE; if (obj_type==OBJ_ICON || obj_type==OBJ_SYM) { /* * Need to check for pins. */ if (MsgBox(TgLoadString(STID_ONE_SIMPLE_GROUP_UNGROUP_ANY), TOOL_NAME, YNC_MB) == MB_ID_YES) { *pn_force_ungroup = TRUE; return FALSE; } return TRUE; } } for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { int obj_type=sel_ptr->obj->type; if (obj_type == OBJ_GROUP) { return FALSE; } else if (obj_type==OBJ_ICON || obj_type==OBJ_SYM) { /* * Need to check for pins. */ } else { every_obj_is_sym_or_icon = FALSE; } } if (every_obj_is_sym_or_icon) { if (MsgBox(TgLoadString(STID_ALL_SIMPLE_GROUP_UNGROUP_ANY), TOOL_NAME, YNC_MB) == MB_ID_YES) { *pn_force_ungroup = TRUE; return FALSE; } } return TRUE; } void UngroupSelObj(highlight, record_cmd) int highlight, record_cmd; { struct SelRec *sel_ptr=NULL, *next_sel=NULL; struct ObjRec *obj_ptr=NULL; int sel_ltx, sel_lty, sel_rbx, sel_rby; int changed=FALSE, force_ungroup_single_obj=FALSE; if (topSel==NULL || NoObjToUngroup(&force_ungroup_single_obj)) return; sel_ltx = selLtX; sel_lty = selLtY; sel_rbx = selRbX; sel_rby = selRbY; if (highlight) HighLightReverse(); if (record_cmd) StartCompositeCmd(); if (force_ungroup_single_obj) { for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct AttrRec *attr_ptr=NULL; obj_ptr = sel_ptr->obj; switch (obj_ptr->type) { case OBJ_ICON: PrepareToReplaceAnObj(obj_ptr); obj_ptr->type = OBJ_GROUP; attr_ptr = obj_ptr->fattr; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { attr_ptr->inherited = FALSE; } AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); break; case OBJ_SYM: PrepareToReplaceAnObj(obj_ptr); obj_ptr->type = OBJ_GROUP; AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); break; case OBJ_PIN: /* * Need to check for pins. */ break; default: break; } } } for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; obj_ptr = sel_ptr->obj; if (obj_ptr->type == OBJ_GROUP) { int count; struct SelRec *tmp_sel_ptr, *tmp_top_sel=NULL, *tmp_bot_sel=NULL; changed = TRUE; if (record_cmd) PrepareToReplaceAnObj(obj_ptr); UngroupObj(obj_ptr, &tmp_top_sel, &tmp_bot_sel); if (gnDeleteAttrsWhileUngrouping) { DelAllAttrs(obj_ptr->fattr); } else { DetachGroupAttrs(obj_ptr, &tmp_top_sel, &tmp_bot_sel); } obj_ptr->detail.r->first->prev = obj_ptr->prev; if (obj_ptr->prev == NULL) { curPage->top = topObj = obj_ptr->detail.r->first; } else { obj_ptr->prev->next = obj_ptr->detail.r->first; } obj_ptr->detail.r->last->next = obj_ptr->next; if (obj_ptr->next == NULL) { curPage->bot = botObj = obj_ptr->detail.r->last; } else { obj_ptr->next->prev = obj_ptr->detail.r->last; } count = 0; for (tmp_sel_ptr=tmp_top_sel; tmp_sel_ptr!=NULL; tmp_sel_ptr=tmp_sel_ptr->next) { count++; } if (record_cmd) { RecordCmd(CMD_ONE_TO_MANY, NULL, tmp_top_sel, tmp_bot_sel, count); } tmp_top_sel->prev = sel_ptr->prev; if (sel_ptr->prev == NULL) { topSel = tmp_top_sel; } else { sel_ptr->prev->next = tmp_top_sel; } tmp_bot_sel->next = sel_ptr->next; if (sel_ptr->next == NULL) { botSel = tmp_bot_sel; } else { sel_ptr->next->prev = tmp_bot_sel; } free(sel_ptr); /* * What about obj_ptr->detail.r->first_conn and * obj_ptr->detail.r->last_conn? */ free(obj_ptr->detail.r); free(obj_ptr); } } if (record_cmd) EndCompositeCmd(); if (changed) { UpdSelBBox(); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; Msg(TgLoadString(STID_SEL_OBJ_ARE_UNGROUPED)); } if (highlight) HighLightForward(); } void LockSelObj() { register struct SelRec *sel_ptr; register struct ObjRec *obj_ptr; int changed=FALSE; if (topSel==NULL) { Msg(TgLoadString(STID_NO_OBJ_TO_LOCK)); return; } if (curChoice==VERTEXMODE) { Msg(TgLoadString(STID_CANNOT_LOCK_IN_VERTEX_MODE)); return; } HighLightReverse(); StartCompositeCmd(); for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; if (!obj_ptr->locked) { changed = TRUE; PrepareToReplaceAnObj(obj_ptr); obj_ptr->locked = TRUE; RecordReplaceAnObj(obj_ptr); } } EndCompositeCmd(); HighLightForward(); if (changed) { UpdSelBBox(); SetFileModified(TRUE); justDupped = FALSE; Msg(TgLoadString(STID_SEL_OBJ_ARE_LOCKED)); } } void UnlockSelObj() { register struct SelRec *sel_ptr; register struct ObjRec *obj_ptr; int changed=FALSE; if (topSel==NULL) { Msg(TgLoadString(STID_NO_OBJ_TO_UNLOCK)); return; } if (curChoice==VERTEXMODE) { Msg(TgLoadString(STID_CANNOT_UNLOCK_IN_VERTEX_MODE)); return; } HighLightReverse(); StartCompositeCmd(); for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; if (obj_ptr->locked) { changed = TRUE; PrepareToReplaceAnObj(obj_ptr); obj_ptr->locked = FALSE; RecordReplaceAnObj(obj_ptr); } } EndCompositeCmd(); HighLightForward(); if (changed) { UpdSelBBox(); SetFileModified(TRUE); justDupped = FALSE; Msg(TgLoadString(STID_SEL_OBJ_ARE_UNLOCKED)); } } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xprtfltr.e���������������������������������������������������������������������������0000644�0000764�0000764�00000004013�11602233314�015017� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xprtfltr.e,v 1.6 2011/05/16 16:22:00 william Exp $ */ #ifndef _XPRTFLTR_E_ #define _XPRTFLTR_E_ extern int gnMaxExportFilters; /* if 0, no export filters */ extern Pixmap *gaExportFilterBitmaps; extern TgEFInfo *gpTgEFInfo; #ifdef _INCLUDE_FROM_XPRTFLTR_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_XPRTFLTR_C_*/ extern void CleanUpExportFilters ARGS_DECL((void)); extern int InitExportFilters ARGS_DECL((void)); extern int GetExportIndex ARGS_DECL((int nWhereToPrint, int nMode)); extern char * GetExportName ARGS_DECL((int nWhereToPrint, int nMode)); extern char * GetExportExt ARGS_DECL((int nWhereToPrint)); extern int GetExportFilterCapability ARGS_DECL((int nWhereToPrint)); extern int ExportVectorFile ARGS_DECL((FILE *pDumpFile, int nPageNumInFileName, int nPrintingPageNum, int nPrintingFirstPageNum, int nPrintingPageRow, int nPrintingPageCol)); #ifdef _INCLUDE_FROM_XPRTFLTR_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_XPRTFLTR_C_*/ #endif /*_XPRTFLTR_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/cmd.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000010273�11602233311�013677� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/cmd.e,v 1.7 2011/05/16 16:21:56 william Exp $ */ #ifndef _CMD_E_ #define _CMD_E_ extern int recordCmdIncludeTgifObj; extern int recordCmdUsesNewColormap; extern int undoingOrRedoing; extern int historyDepth, historyCount, defaultHistoryDepth; extern struct CmdRec *firstCmd, *lastCmd, *curCmd; extern struct SelRec *topSelBeforeInCmd, *botSelBeforeInCmd; extern int *stackingPosition; extern int stackingCount; extern int stackingPositionHasIds; extern int composingCommand; extern int undoRedoRestoreDrawingMode; extern Colormap preparedColormap; #ifdef _INCLUDE_FROM_CMD_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_CMD_C_*/ extern void InsertCmd ARGS_DECL((struct CmdRec *PrevCmd, struct CmdRec *NextCmd, struct CmdRec *CmdPtr, struct CmdRec **ppFirstCmd, struct CmdRec **ppLastCmd)); extern void CopyAndInsertCmd ARGS_DECL((int from_remote, char *serialization_buf, struct CmdRec *PrevCmd, struct CmdRec *NextCmd, struct CmdRec *CmdPtr, struct CmdRec **ppFirstCmd, struct CmdRec **ppLastCmd)); extern void DeleteARedoRecord ARGS_DECL((struct CmdRec *, double PercStart, double PercEnd)); extern void ClearRedoRecords ARGS_DECL((struct CmdRec *)); extern void CleanUpCmds ARGS_DECL((void)); extern void CopySel ARGS_DECL((struct SelRec *FromTopSel, int Count, struct SelRec **ToTopSel, struct SelRec **ToBotSel)); extern void UndoACmd ARGS_DECL((struct CmdRec *CmdPtr, int HighLight, int PerformAction)); extern void UndoCmd ARGS_DECL((void)); extern int RedoACmd ARGS_DECL((struct CmdRec *CmdPtr, int HighLight, int PerformAction)); extern void RedoCmd ARGS_DECL((void)); extern void StartCompositeCmd ARGS_DECL((void)); extern void EndCompositeCmd ARGS_DECL((void)); extern void RestoreDefaultHistoryDepth ARGS_DECL((void)); extern void DisableUndo ARGS_DECL((void)); extern void EnableUndo ARGS_DECL((void)); extern struct SelRec * PrepareStackingInfo ARGS_DECL(( struct SelRec *TopSel, struct SelRec *BotSel, int NumObjs, int PreparePhase, int **ppnStackingPosition, int *pnStackingCount, int *pnStackingPositionHasIds)); extern void PrepareToRecord ARGS_DECL((int, struct SelRec *Top, struct SelRec *Bot, int NumObjs)); extern void FreeAfterSel ARGS_DECL((struct CmdRec *)); extern void RecordCmd ARGS_DECL((int, struct SubCmdRec *, struct SelRec *Top, struct SelRec *Bot, int NumObjs)); extern void AbortPrepareCmd ARGS_DECL((int CmdType)); extern void RecordNewObjCmd ARGS_DECL((void)); extern void PrepareToReplaceAnObj ARGS_DECL((struct ObjRec *)); extern void RecordReplaceAnObj ARGS_DECL((struct ObjRec *)); extern void ChangeReplaceOneCmdToDeleteCmd ARGS_DECL((void)); extern void RecordWBClearAll ARGS_DECL((void)); extern void RecordWBSlideShow ARGS_DECL((int nIntoSlideShow)); extern void RecordWBChatALine ARGS_DECL((struct SubCmdRec *)); #ifdef _INCLUDE_FROM_CMD_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_CMD_C_*/ #endif /*_CMD_E_*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgcwheel.e���������������������������������������������������������������������������0000644�0000764�0000764�00000003236�11602233313�014741� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgcwheel.e,v 1.3 2011/05/16 16:22:00 william Exp $ */ #ifndef _TGCWHEEL_E_ #define _TGCWHEEL_E_ #ifdef _INCLUDE_FROM_TGCWHEEL_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TGCWHEEL_C_*/ extern void TgColorWheel_CleanUp ARGS_DECL((Display*, Window)); extern int TgColorWheel_Init ARGS_DECL((Display*, Window, char *arg)); extern void CleanUpColorWheel ARGS_DECL((void)); extern int InitColorWheel ARGS_DECL((void)); extern int TgColorWheel_SendKey ARGS_DECL((Display*, Window, XKeyEvent*, char*)); extern int TgColorWheel_HandleCntrlSpace ARGS_DECL((Display*, Window)); extern int TgColorWheel_HandleCreateText ARGS_DECL((Display*, Window)); #ifdef _INCLUDE_FROM_TGCWHEEL_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TGCWHEEL_C_*/ #endif /*_TGCWHEEL_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/flip-flop.sym������������������������������������������������������������������������0000644�0000764�0000764�00000013673�11602233311�015417� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������state(0,14,100,0,0,0,8,1,8,0,2,0,1,0,0,1,0,0,0,4,0,0,0,10,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/flip-flop.sym,v 1.1 2004/06/18 23:20:01 william Exp $ % text('white',496,184,0,0,4,1,0,0,1,252,21,71,0,17,4,0,0,0,[ "definition part of the NAND gate."]). text('white',448,160,0,0,4,1,0,0,1,317,21,72,0,17,4,0,0,0,[ "Select a NAND gate and type ^V to see the"]). text('white',496,136,0,0,4,1,0,0,1,164,21,73,0,17,4,0,0,0,[ "building-block object."]). text('white',448,112,0,0,4,1,0,0,1,341,21,74,0,17,4,0,0,0,[ "The rest of this file is the definition part of the"]). text('white',496,88,0,0,4,1,0,0,1,264,21,75,0,17,4,0,0,0,[ "is highlighted with a dashed outline."]). text('white',448,64,0,0,4,1,0,0,1,293,21,76,0,17,4,0,0,0,[ "The representation part of the flip-flop"]). text('white',448,40,0,0,4,1,0,0,1,321,21,77,0,17,4,0,0,0,[ "The SR flip-flop is a building-block object."]). icon([ group([ poly('yellow',2,[ 192,272,168,272],0,0,1,20,1,0,0,0,[ ]), poly('yellow',2,[ 192,320,168,320],0,0,1,21,1,0,0,0,[ ]), poly('yellow',2,[ 312,296,288,296],0,0,1,22,1,0,0,0,[ ]), group([ oval('yellow',264,284,288,308,2,0,1,78,0,0,[ ]), poly('yellow',4,[ 224,264,192,264,192,328,224,328],0,0,1,23,0,0,0,0,[ ]), poly('yellow',3,[ 224,264,264,264,264,296],0,0,1,24,1,0,0,0,[ ]), poly('yellow',3,[ 224,328,264,328,264,296],0,0,1,25,1,0,0,0,[ ]) ],[ ]) ],[ ]), icon([ box('yellow',296,280,328,312,0,0,0,79,0,0,[ ]), box('yellow',308,292,316,300,2,0,1,80,0,0,[ ]) ], "pin",17,0,0,[ attr("name=", "out", 0, 1, 1, text('green',312,272,1,0,4,1,1,0,1,88,19,81,0,15,4,0,0,0,[ "name=out"])), attr("num=", "3", 1, 0, 1, text('green',296,280,1,0,4,1,1,0,1,11,19,82,0,15,4,0,0,0,[ "3"])) ]), icon([ box('yellow',152,256,184,288,0,0,0,83,0,0,[ ]), box('yellow',164,268,172,276,2,0,1,84,0,0,[ ]) ], "pin",18,0,0,[ attr("num=", "1", 1, 0, 1, text('green',184,256,1,0,4,1,1,0,1,11,19,85,0,15,4,0,0,0,[ "1"])), attr("name=", "in1", 0, 1, 1, text('green',168,248,1,0,4,1,1,0,1,88,19,86,0,15,4,0,0,0,[ "name=in1"])) ]), icon([ box('yellow',152,304,184,336,0,0,0,87,0,0,[ ]), box('yellow',164,316,172,324,2,0,1,88,0,0,[ ]) ], "pin",19,0,0,[ attr("name=", "in2", 0, 1, 1, text('green',168,296,1,0,4,1,1,0,1,88,19,89,0,15,4,0,0,0,[ "name=in2"])), attr("num=", "2", 1, 0, 1, text('green',184,304,1,0,4,1,1,0,1,11,19,90,0,15,4,0,0,0,[ "2"])) ]) ], "nand2",26,0,0,[ attr("LOC=", "", 1, 1, 1, text('red',228,285,1,0,5,1,1,0,1,60,24,91,0,19,5,0,0,0,[ "LOC="])) ]). icon([ group([ poly('yellow',2,[ 192,392,168,392],0,0,1,27,1,0,0,0,[ ]), poly('yellow',2,[ 192,440,168,440],0,0,1,28,1,0,0,0,[ ]), poly('yellow',2,[ 312,416,288,416],0,0,1,29,1,0,0,0,[ ]), group([ oval('yellow',264,404,288,428,2,0,1,92,0,0,[ ]), poly('yellow',4,[ 224,384,192,384,192,448,224,448],0,0,1,30,0,0,0,0,[ ]), poly('yellow',3,[ 224,384,264,384,264,416],0,0,1,31,1,0,0,0,[ ]), poly('yellow',3,[ 224,448,264,448,264,416],0,0,1,32,1,0,0,0,[ ]) ],[ ]) ],[ ]), icon([ box('yellow',296,400,328,432,0,0,0,93,0,0,[ ]), box('yellow',308,412,316,420,2,0,1,94,0,0,[ ]) ], "pin",33,0,0,[ attr("num=", "3", 1, 0, 1, text('green',296,400,1,0,4,1,1,0,1,11,19,95,0,15,4,0,0,0,[ "3"])), attr("name=", "out", 0, 1, 1, text('green',312,392,1,0,4,1,1,0,1,88,19,96,0,15,4,0,0,0,[ "name=out"])) ]), icon([ box('yellow',152,376,184,408,0,0,0,97,0,0,[ ]), box('yellow',164,388,172,396,2,0,1,98,0,0,[ ]) ], "pin",34,0,0,[ attr("name=", "in1", 0, 1, 1, text('green',168,368,1,0,4,1,1,0,1,88,19,99,0,15,4,0,0,0,[ "name=in1"])), attr("num=", "1", 1, 0, 1, text('green',184,376,1,0,4,1,1,0,1,11,19,100,0,15,4,0,0,0,[ "1"])) ]), icon([ box('yellow',152,424,184,456,0,0,0,101,0,0,[ ]), box('yellow',164,436,172,444,2,0,1,102,0,0,[ ]) ], "pin",35,0,0,[ attr("num=", "2", 1, 0, 1, text('green',184,424,1,0,4,1,1,0,1,11,19,103,0,15,4,0,0,0,[ "2"])), attr("name=", "in2", 0, 1, 1, text('green',168,416,1,0,4,1,1,0,1,88,19,104,0,15,4,0,0,0,[ "name=in2"])) ]) ], "nand2",36,0,0,[ attr("LOC=", "", 1, 1, 1, text('red',228,405,1,0,5,1,1,0,1,60,24,105,0,19,5,0,0,0,[ "LOC="])) ]). poly('cyan',6,[ 312,416,336,416,336,392,144,344,144,320,168,320],0,0,1,41,0,0,0,0,[ ]). poly('cyan',6,[ 312,296,336,296,336,320,144,368,144,392,168,392],0,0,1,42,0,0,0,0,[ ]). sym([ group([ box('yellow',208,88,272,168,0,0,1,106,0,0,[ ]), poly('yellow',2,[ 184,104,208,104],0,0,1,47,0,0,0,0,[ ]), poly('yellow',2,[ 184,152,208,152],0,0,1,48,0,0,0,0,[ ]), poly('yellow',2,[ 272,104,296,104],0,0,1,49,0,0,0,0,[ ]), poly('yellow',2,[ 272,152,296,152],0,0,1,50,0,0,0,0,[ ]) ],[ ]), icon([ box('yellow',280,88,312,120,0,0,0,107,0,0,[ ]), box('yellow',292,100,300,108,2,0,1,108,0,0,[ ]) ], "pin",43,0,0,[ attr("name=", "Q", 1, 0, 1, text('green',264,96,1,0,4,1,1,0,1,11,19,109,0,15,4,0,0,0,[ "Q"])), attr("num=", "", 0, 1, 1, text('green',296,64,1,0,4,1,1,0,1,44,19,110,0,15,4,0,0,0,[ "num="])) ]), icon([ box('yellow',280,136,312,168,0,0,0,111,0,0,[ ]), box('yellow',292,148,300,156,2,0,1,112,0,0,[ ]) ], "pin",44,0,0,[ attr("num=", "", 0, 1, 1, text('green',296,112,1,0,4,1,1,0,1,44,19,113,0,15,4,0,0,0,[ "num="])), attr("name=", "Q'", 1, 0, 1, text('green',256,144,1,0,4,1,1,0,1,22,19,114,0,15,4,0,0,0,[ "Q'"])) ]), icon([ box('yellow',168,88,200,120,0,0,0,115,0,0,[ ]), box('yellow',180,100,188,108,2,0,1,116,0,0,[ ]) ], "pin",45,0,0,[ attr("num=", "", 0, 1, 1, text('green',184,64,1,0,4,1,1,0,1,44,19,117,0,15,4,0,0,0,[ "num="])), attr("name=", "S'", 1, 0, 1, text('green',224,96,1,0,4,1,1,0,1,22,19,118,0,15,4,0,0,0,[ "S'"])) ]), icon([ box('yellow',168,136,200,168,0,0,0,119,0,0,[ ]), box('yellow',180,148,188,156,2,0,1,120,0,0,[ ]) ], "pin",46,0,0,[ attr("name=", "R'", 1, 0, 1, text('green',224,144,1,0,4,1,1,0,1,22,19,121,0,15,4,0,0,0,[ "R'"])), attr("num=", "", 0, 1, 1, text('green',184,112,1,0,4,1,1,0,1,44,19,122,0,15,4,0,0,0,[ "num="])) ]) ],[ ]). poly('cyan',4,[ 184,104,80,104,80,272,168,272],0,0,1,51,0,0,0,0,[ ]). poly('cyan',4,[ 184,152,64,152,64,440,168,440],0,0,1,52,0,0,0,0,[ ]). poly('cyan',4,[ 312,296,360,296,360,104,296,104],0,0,1,53,0,0,0,0,[ ]). poly('cyan',4,[ 312,416,376,416,376,152,296,152],0,0,1,54,0,0,0,0,[ ]). ���������������������������������������������������������������������tgif-QPL-4.2.5/tgif.gif�����������������������������������������������������������������������������0000644�0000764�0000764�00000000110�11602233313�014375� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������GIF89a5 "@™źŁÌ4 ZĂ:%IŠœbłÀUž­àÁ‚ Ÿ€æîbZc?† FòdÊK _.72đæ{–?SpŠYôŸ4" ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tdgtbrow.e���������������������������������������������������������������������������0000644�0000764�0000764�00000004025�11602233313�014770� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtbrow.e,v 1.6 2011/05/16 16:22:00 william Exp $ */ #ifndef _TDGTBROW_E_ #define _TDGTBROW_E_ #include "tidget.h" #include "tdgtbtn.e" #include "list.e" #define TDGTBROW_DEF_H_PAD 2 #define TDGTBROW_DEF_V_PAD 2 /* * A button row tidget is a container of which other buttons can sit on top. */ typedef struct tagTdgtBtnRow { TidgetInfo *pti; SimpleWinInfo client_area; int content_w, content_h; /* the area occupied by the buttons */ int h_gap; int just; /* JUST_L, JUST_C, or JUST_R */ } TdgtBtnRow; #ifdef _INCLUDE_FROM_TDGTBROW_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TDGTBROW_C_*/ extern void TdgtBtnRowReset ARGS_DECL((TdgtBtnRow*)); extern TdgtBtnRow *CreateTdgtBtnRow ARGS_DECL((Window parent_win, TidgetInfo *parent_tidgetinfo, int ctl_id, int x, int y, int h_pad, int v_pad, int state, int h_gap, int just)); extern int TdgtBtnRowAddBtn ARGS_DECL((TdgtBtnRow*, TdgtBtn*)); extern int InitTdgtBtnRow ARGS_DECL((void)); extern void CleanUpTdgtBtnRow ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TDGTBROW_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TDGTBROW_C_*/ #endif /*_TDGTBROW_E_*/ �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/configure.ac�������������������������������������������������������������������������0000644�0000764�0000764�00000003010�11602233365�015254� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# -*- Autoconf -*- # Process this file with autoconf to produce a configure script. AC_PREREQ(2.61) AC_INIT(tgif, 4.2.5, bill.cheng@acm.org) AC_CONFIG_SRCDIR([wb_seg.c]) AM_INIT_AUTOMAKE AM_CONFIG_HEADER([config.h]) # Checks for programs. AC_PROG_CC # Checks for libraries. AC_CHECK_LIB([X11], [XOpenDisplay]) AC_CHECK_LIB([Xt], [XtInitialize]) AC_CHECK_LIB([socket], [socket]) AC_CHECK_LIB([nsl], [inet_addr]) AC_CHECK_LIB([dl], [dlsym]) AC_CHECK_LIB([idn], [stringprep_convert]) AC_CHECK_LIB([m], [pow]) AC_CHECK_LIB([z], [deflate]) AC_CHECK_LIB([pthread], [pthread_create]) # Checks for header files. AC_PATH_X AC_HEADER_DIRENT AC_HEADER_STDC AC_HEADER_SYS_WAIT AC_CHECK_HEADERS([arpa/inet.h fcntl.h libintl.h netdb.h netinet/in.h stdint.h stdlib.h string.h sys/file.h sys/ioctl.h sys/socket.h sys/time.h sys/timeb.h unistd.h]) # Checks for typedefs, structures, and compiler characteristics. AC_C_CONST AC_TYPE_MODE_T AC_TYPE_SIZE_T AC_HEADER_TIME AC_TYPE_UINT16_T AC_TYPE_UINT32_T # Checks for library functions. AC_FUNC_CLOSEDIR_VOID AC_FUNC_FORK AC_PROG_GCC_TRADITIONAL AC_FUNC_LSTAT AC_FUNC_LSTAT_FOLLOWS_SLASHED_SYMLINK AC_FUNC_MALLOC AC_FUNC_MEMCMP AC_FUNC_REALLOC AC_FUNC_SELECT_ARGTYPES AC_TYPE_SIGNAL AC_FUNC_STAT AC_FUNC_STRTOD AC_CHECK_FUNCS([ftime getcwd gethostbyname gethostname gettimeofday memmove memset mkdir pow putenv select setlocale socket sqrt strchr strpbrk strrchr strstr strtol]) AC_CONFIG_FILES([Makefile]) # BC: skipping AC_CONFIG_SUBDIRS([rmcast]) AC_OUTPUT ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/rm_intrf.e���������������������������������������������������������������������������0000644�0000764�0000764�00000012262�11602233312�014755� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/rm_intrf.e,v 1.10 2011/05/16 16:21:59 william Exp $ */ #ifndef _RM_INTRF_E_ #define _RM_INTRF_E_ #include "rmcast/src/rmcast.h" typedef void *TGEF_USER_INFO; typedef long (TGEF_MAIN)ARGS_DECL((TGEF_USER_INFO*, int, int, void*)); typedef void (RM_getVersion_Func)ARGS_DECL((char *buf, int buf_sz)); typedef int (RM_initialize_Func)ARGS_DECL((void *callbackterm( void ))); typedef int (RM_joinGroup_Func)ARGS_DECL((char *group, int port)); typedef void (RM_leaveGroup_Func)ARGS_DECL((int sock, char *group)); typedef void (RM_terminate_Func)ARGS_DECL((void)); typedef int (RM_sendto_Func)ARGS_DECL((int socket, void *buffer, int buffsize)); typedef int (RM_recv_Func)ARGS_DECL((int socket, void *buffer, int buffsize)); typedef int (RM_getCurStatus_Func)ARGS_DECL((char *group, int port, CurStatus *c)); typedef int (RM_sendCurStatus_Func)ARGS_DECL((int connfd, char *buff, int buffsize)); typedef int (RM_readConfigFile_Func)ARGS_DECL((char *filename, char show_config_file)); typedef void (RM_getOption_Func)ARGS_DECL((int opt, void *return_value)); typedef void (RM_setOption_Func)ARGS_DECL((int opt, void *optvalue)); typedef int (RM_setHostDelay_Func)ARGS_DECL((char *hostname, int estimated_one_way_delay)); typedef int (RM_getHostDelay_Func)ARGS_DECL((char *hostname, int *estimated_one_way_delay)); typedef void (RMDEBUG_setpidip_Func)ARGS_DECL((int pid, char *ip)); typedef void (RMDEBUG_setsn_Func)ARGS_DECL((int sn)); typedef struct tagRMCastIntrfInfo { char szPath[MAXPATHLENGTH+1]; RM_getVersion_Func *pfn_RM_getVersion; RM_initialize_Func *pfn_RM_initialize; RM_joinGroup_Func *pfn_RM_joinGroup; RM_leaveGroup_Func *pfn_RM_leaveGroup; RM_terminate_Func *pfn_RM_terminate; /* no need */ RM_sendto_Func *pfn_RM_sendto; RM_recv_Func *pfn_RM_recv; RM_getCurStatus_Func *pfn_RM_getCurStatus; RM_sendCurStatus_Func *pfn_RM_sendCurStatus; RM_readConfigFile_Func *pfn_RM_readConfigFile; RM_getOption_Func *pfn_RM_getOption; RM_setOption_Func *pfn_RM_setOption; RM_setHostDelay_Func *pfn_RM_setHostDelay; /* no need */ RM_getHostDelay_Func *pfn_RM_getHostDelay; /* no need */ RMDEBUG_setpidip_Func *pfn_RMDEBUG_setpidip; /* no need */ RMDEBUG_setsn_Func *pfn_RMDEBUG_setsn; /* no need */ void *pSharedLibHandle; } RMCastIntrfInfo; extern char cmdLineRMCastLibDir[MAXPATHLENGTH+1]; extern char cmdLineRMCastLibPath[MAXPATHLENGTH+1]; extern RMCastIntrfInfo gRMCastIntrfInfo; #ifdef _INCLUDE_FROM_RM_INTRF_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_RM_INTRF_C_*/ extern void RMCastCleanUp ARGS_DECL((void)); extern int RMCastInit ARGS_DECL((void)); #ifndef _NO_RMCAST_SO extern void RM_getVersion ARGS_DECL((char *buf, int buf_sz)); extern int RM_initialize ARGS_DECL((void *callbackterm( void ))); extern int RM_joinGroup ARGS_DECL((char *group, int port)); extern void RM_leaveGroup ARGS_DECL((int sock, char *group)); extern void RM_terminate ARGS_DECL((void)); extern int RM_sendto ARGS_DECL((int socket, void *buffer, int buffsize)); extern int RM_recv ARGS_DECL((int socket, void *buffer, int buffsize)); extern int RM_getCurStatus ARGS_DECL((char *group, int port, CurStatus *c)); extern int RM_sendCurStatus ARGS_DECL((int connfd, char *buff, int buffsize)); extern int RM_readConfigFile ARGS_DECL((char *filename, char show_config_file)); extern void RM_getOption ARGS_DECL((int opt, void *return_value)); extern void RM_setOption ARGS_DECL((int opt, void *optvalue)); extern int RM_setHostDelay ARGS_DECL((char *hostname, int estimated_one_way_delay)); extern int RM_getHostDelay ARGS_DECL((char *hostname, int *estimated_one_way_delay)); extern void RMDEBUG_setpidip ARGS_DECL((int pid, char *ip)); extern void RMDEBUG_setsn ARGS_DECL((int sn)); #endif /* _NO_RMCAST_SO */ #ifdef _INCLUDE_FROM_RM_INTRF_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_RM_INTRF_C_*/ #endif /*_RM_INTRF_E_*/ ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tdgtbtn.c����������������������������������������������������������������������������0000644�0000764�0000764�00000047202�11602233313�014604� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtbtn.c,v 1.8 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TDGTBTN_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "tidget.h" #include "button.e" #include "color.e" #include "cursor.e" #include "font.e" #include "menu.e" #include "msg.e" #include "raster.e" #include "rect.e" #include "setup.e" #include "tdgtbtn.e" #include "tidget.e" #include "util.e" static void RedrawTdgtBtn ARGS_DECL((TidgetInfo *pti)); static int TdgtBtnEventHandler ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo *handling_pti)); static int IsTdgtBtnEvent ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo **ppti_handler_tidget_return)); static void DestroyTdgtBtn ARGS_DECL((TidgetInfo *pti)); static void MapTdgtBtn ARGS_DECL((TidgetInfo *pti)); static void TdgtBtnMoveResize ARGS_DECL((TidgetInfo *pti, int x, int y, int w, int h)); static int TdgtBtnSendCmd ARGS_DECL((TidgetInfo *pti, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); static int gnBtnFontHeight=0; static int gnBtnFontWidth=0; static int gnBtnFontAsc=0; static int gnBtnFontDes=0; static XFontStruct *gnBtnFontPtr=NULL; /* --------------------- RedrawTdgtBtn() --------------------- */ void CalcTdgtBtnDim(text, min_len, h_pad, v_pad, pn_width, pn_height) char *text; int min_len, h_pad, v_pad, *pn_width, *pn_height; { int btn_w=ButtonWidth(text, min_len, NULL)+(h_pad<<1), btn_h=0; if (boldMsgFontSet != NULL || boldMsgFontPtr != NULL) { btn_h = boldMsgFontHeight; } else if (msgFontSet != NULL || msgFontPtr != NULL) { btn_h = msgFontHeight; } else { btn_h = defaultFontHeight; } btn_h += (v_pad<<1)+(windowPadding<<1); if (pn_width != NULL) *pn_width = btn_w; if (pn_height != NULL) *pn_height = btn_h; } /* --------------------- RedrawTdgtBtn() --------------------- */ static void DrawTdgtTextBtn(pTdgtBtn, pBBRec, str, len, down, pButtonFontInfo) TdgtBtn *pTdgtBtn; struct BBRec *pBBRec; char *str; int len, down; ButtonFontInfo *pButtonFontInfo; { if (down) { DisplayButtonInBBox(pTdgtBtn->pti->tci.win, str, len, pBBRec, BUTTON_INVERT, FALSE, 0, pButtonFontInfo); if (threeDLook) { TgDrawThreeDButton(mainDisplay, pTdgtBtn->pti->tci.win, gTidgetManager.gc, pBBRec, TGBS_LOWRED, 2, TRUE); } } else { DisplayButtonInBBox(pTdgtBtn->pti->tci.win, str, len, pBBRec, BUTTON_NORMAL, FALSE, 0, pButtonFontInfo); if (threeDLook) { TgDrawThreeDButton(mainDisplay, pTdgtBtn->pti->tci.win, gTidgetManager.gc, pBBRec, TGBS_RAISED, 2, TRUE); } } TidgetManagerResetGC(); } static void RedrawTdgtBtn(pti) TidgetInfo *pti; { TdgtBtn *pTdgtBtn=(TdgtBtn*)(pti->tidget); struct BBRec bbox; char *str=NULL; int len=0, pixel=INVALID, btn_down=(pTdgtBtn->pti->tci.state != TGBS_NORMAL); ButtonFontInfo btn_font_info; XGCValues values; Pixmap bitmap=None; SetBBRec(&bbox, 0, 0, pTdgtBtn->pti->tci.win_info.w, pTdgtBtn->pti->tci.win_info.h); switch (pTdgtBtn->btn_type) { case TGMUTYPE_TEXT: str = ((pTdgtBtn->str == NULL) ? "" : pTdgtBtn->str); len = strlen(str); memset(&btn_font_info, 0, sizeof(ButtonFontInfo)); btn_font_info.font_style = pTdgtBtn->font_style; DrawTdgtTextBtn(pTdgtBtn, &bbox, str, len, FALSE, &btn_font_info); break; case TGMUTYPE_COLOR: if (colorDisplay) { pixel = (btn_down ? myFgPixel : colorPixels[(int)(long)(pTdgtBtn->str)]); } else { pixel = myFgPixel; } values.foreground = pixel; values.function = GXcopy; values.fill_style = FillOpaqueStippled; values.stipple = patPixmap[1]; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground | GCFunction | GCFillStyle | GCStipple, &values); XFillRectangle(mainDisplay, pTdgtBtn->pti->tci.win, gTidgetManager.gc, windowPadding, windowPadding, pTdgtBtn->pti->tci.content_w, pTdgtBtn->pti->tci.content_h); if (threeDLook) { TgDrawThreeDButton(mainDisplay, pTdgtBtn->pti->tci.win, gTidgetManager.gc, &bbox, (btn_down ? TGBS_LOWRED : TGBS_RAISED), 2, TRUE); } TidgetManagerResetGC(); break; case TGMUTYPE_BITMAP: bitmap = (*(Pixmap*)pTdgtBtn->str); if (threeDLook) { values.foreground = myFgPixel; values.background = (threeDLook ? myLtGryPixel : myBgPixel); values.function = GXcopy; values.fill_style = FillStippled; values.stipple = bitmap; values.ts_x_origin = windowPadding; values.ts_y_origin = windowPadding; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground | GCBackground | GCFunction | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, pTdgtBtn->pti->tci.win, gTidgetManager.gc, values.ts_x_origin, values.ts_y_origin, pTdgtBtn->pti->tci.content_w, pTdgtBtn->pti->tci.content_h); XSetTSOrigin(mainDisplay, gTidgetManager.gc, 0, 0); switch (pTdgtBtn->btn_style) { case TDGTBTN_CLICK: break; case TDGTBTN_STICKY: TidgetManagerResetGC(); TgDrawThreeDButton(mainDisplay, pTdgtBtn->pti->tci.win, gTidgetManager.gc, &bbox, (btn_down ? TGBS_LOWRED : TGBS_RAISED), 2, TRUE); break; } TidgetManagerResetGC(); } else { if (btn_down) { values.foreground = myFgPixel; values.fill_style = FillSolid; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground | GCFillStyle, &values); XFillRectangle(mainDisplay, pTdgtBtn->pti->tci.win, gTidgetManager.gc, windowPadding, windowPadding, pTdgtBtn->pti->tci.content_w, pTdgtBtn->pti->tci.content_h); values.foreground = myFgPixel; values.fill_style = FillStippled; values.stipple = bitmap; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground | GCFillStyle | GCStipple, &values); XFillRectangle(mainDisplay, pTdgtBtn->pti->tci.win, gTidgetManager.gc, windowPadding, windowPadding, pTdgtBtn->pti->tci.content_w, pTdgtBtn->pti->tci.content_h); } else { values.foreground = myFgPixel; values.fill_style = FillStippled; values.stipple = bitmap; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground | GCFillStyle | GCStipple, &values); XFillRectangle(mainDisplay, pTdgtBtn->pti->tci.win, gTidgetManager.gc, windowPadding, windowPadding, pTdgtBtn->pti->tci.content_w, pTdgtBtn->pti->tci.content_h); } TidgetManagerResetGC(); } break; } } /* --------------------- TdgtBtnEventHandler() --------------------- */ static int ButtonPressInTdgtBtn(pTdgtBtn, button_ev, pn_changing, pn_selected_btn_index) TdgtBtn *pTdgtBtn; XButtonEvent *button_ev; int *pn_changing, *pn_selected_btn_index; { struct BBRec bbox; char *str=NULL; int len=0, looping=TRUE, selected=TRUE; ButtonFontInfo btn_font_info; XEvent ev; memset(&btn_font_info, 0, sizeof(ButtonFontInfo)); btn_font_info.font_style = pTdgtBtn->font_style; SetBBRec(&bbox, 0, 0, pTdgtBtn->pti->tci.win_info.w, pTdgtBtn->pti->tci.win_info.h); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, pTdgtBtn->pti->tci.win, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } switch (pTdgtBtn->btn_type) { case TGMUTYPE_TEXT: str = ((pTdgtBtn->str == NULL) ? "" : pTdgtBtn->str); len = strlen(str); DrawTdgtTextBtn(pTdgtBtn, &bbox, str, len, TRUE, &btn_font_info); break; case TGMUTYPE_COLOR: pTdgtBtn->pti->tci.state = TGBS_LOWRED; RedrawTdgtBtn(pTdgtBtn->pti); pTdgtBtn->pti->tci.state = TGBS_NORMAL; break; case TGMUTYPE_BITMAP: break; } while (looping) { XNextEvent(mainDisplay, &ev); if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); if (debugNoPointerGrab) XSync(mainDisplay, False); looping = FALSE; } else if (ev.type == MotionNotify) { if (PointInBBox(ev.xmotion.x, ev.xmotion.y, bbox)) { if (!selected) { selected = TRUE; switch (pTdgtBtn->btn_type) { case TGMUTYPE_TEXT: DrawTdgtTextBtn(pTdgtBtn, &bbox, str, len, TRUE, &btn_font_info); break; case TGMUTYPE_COLOR: pTdgtBtn->pti->tci.state = TGBS_LOWRED; RedrawTdgtBtn(pTdgtBtn->pti); pTdgtBtn->pti->tci.state = TGBS_NORMAL; break; case TGMUTYPE_BITMAP: break; } } } else { if (selected) { selected = FALSE; switch (pTdgtBtn->btn_type) { case TGMUTYPE_TEXT: DrawTdgtTextBtn(pTdgtBtn, &bbox, str, len, FALSE, &btn_font_info); break; case TGMUTYPE_COLOR: RedrawTdgtBtn(pTdgtBtn->pti); break; case TGMUTYPE_BITMAP: break; } } } } } if (selected) { switch (pTdgtBtn->btn_type) { case TGMUTYPE_TEXT: DrawTdgtTextBtn(pTdgtBtn, &bbox, str, len, FALSE, &btn_font_info); break; case TGMUTYPE_COLOR: RedrawTdgtBtn(pTdgtBtn->pti); break; case TGMUTYPE_BITMAP: break; } } return selected; } static int TdgtBtnEventHandler(pti, input, handling_pti) TidgetInfo *pti, *handling_pti; XEvent *input; { TdgtBtn *pTdgtBtn=(TdgtBtn*)(pti->tidget); int nf_arg=0, nf_arg2=INVALID; if (pti != handling_pti) return FALSE; if (input->type == Expose) { XEvent ev; RedrawTdgtBtn(pTdgtBtn->pti); while (XCheckWindowEvent(mainDisplay, pTdgtBtn->pti->tci.win, ExposureMask, &ev)) ; } else if (input->type == ButtonPress) { switch (pTdgtBtn->btn_style) { case TDGTBTN_CLICK: switch (pTdgtBtn->btn_type) { case TGMUTYPE_TEXT: if (ButtonPressInTdgtBtn(pTdgtBtn, &input->xbutton, NULL, NULL)) { /* clicked */ TidgetControlNotify(pTdgtBtn->pti, TDGTNF_BTN_CLICKED, 0, 0); return TRUE; } break; case TGMUTYPE_COLOR: switch (input->xbutton.button) { case Button1: nf_arg = (int)Button1; break; case Button2: { int x=0, y=0, root_x=0, root_y=0, color_index=0; Window root_win, child_win; unsigned int status=0; XQueryPointer(mainDisplay, rootWindow, &root_win, &child_win, &root_x, &root_y, &x, &y, &status); gstMenuDontSendCommandInfo.dont_send_command = TRUE; gstMenuDontSendCommandInfo.selected_index = INVALID; ColorMenu(x, y, FALSE); color_index = gstMenuDontSendCommandInfo.selected_index; if (color_index >= 0 && color_index < maxColors) { nf_arg = Button2; nf_arg2 = color_index; } memset(&gstMenuDontSendCommandInfo, 0, sizeof(MenuDontSendCommandInfo)); } break; case Button3: nf_arg = Button3; break; default: break; } if (nf_arg != 0) { TidgetControlNotify(pTdgtBtn->pti, TDGTNF_MULTI_BTN_CLICKED, nf_arg, nf_arg2); } return TRUE; case TGMUTYPE_BITMAP: break; } break; case TDGTBTN_STICKY: /* press it */ if (pTdgtBtn->pti->tci.state == TGBS_NORMAL) { pTdgtBtn->pti->tci.state = TGBS_LOWRED; } else { pTdgtBtn->pti->tci.state = TGBS_NORMAL; } TidgetControlNotify(pTdgtBtn->pti, TDGTNF_BTN_CLICKED, 0, 0); RedrawTdgtBtn(pTdgtBtn->pti); return TRUE; } } else if (input->type == EnterNotify) { if (pTdgtBtn->mosi.one_line_status) { SetStringStatus(pTdgtBtn->mosi.one_line_str); } else { MouseOverStatusInfo *pmosi=(&pTdgtBtn->mosi); SetMouseStatus(pmosi->btn_str[0], pmosi->btn_str[1], pmosi->btn_str[2]); } } else if (input->type == LeaveNotify) { SetMouseStatus("", "", ""); } return FALSE; } /* --------------------- IsTdgtBtnEvent() --------------------- */ static int IsTdgtBtnEvent(pti, input, ppti_handler_tidget_return) TidgetInfo *pti, **ppti_handler_tidget_return; XEvent *input; { TdgtBtn *pTdgtBtn=(TdgtBtn*)(pti->tidget); if (input->xany.window == pTdgtBtn->pti->tci.win) return TRUE; return FALSE; } /* --------------------- DestroyTdgtBtn() --------------------- */ static void DestroyTdgtBtn(pti) TidgetInfo *pti; { TdgtBtn *pTdgtBtn=(TdgtBtn*)(pti->tidget); TdgtBtnReset(pTdgtBtn); free(pTdgtBtn); } /* --------------------- MapTdgtBtn() --------------------- */ static void MapTdgtBtn(pti) TidgetInfo *pti; { TdgtBtn *pTdgtBtn=(TdgtBtn*)(pti->tidget); #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, pTdgtBtn->pti->tci.win); XSelectInput(mainDisplay, pTdgtBtn->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); #else XSelectInput(mainDisplay, pTdgtBtn->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, pTdgtBtn->pti->tci.win); #endif } /* --------------------- TdgtBtnMoveResize() --------------------- */ static void TdgtBtnMoveResize(pti, x, y, w, h) TidgetInfo *pti; int x, y, w, h; { TdgtBtn *pTdgtBtn=(TdgtBtn*)(pti->tidget); /* there should be no need to resize a button */ pTdgtBtn->pti->tci.win_info.x = x; pTdgtBtn->pti->tci.win_info.y = y; pTdgtBtn->pti->tci.win_info.w = w; pTdgtBtn->pti->tci.win_info.h = h; XMoveResizeWindow(mainDisplay, pTdgtBtn->pti->tci.win, x, y, w, h); } /* --------------------- TdgtBtnSendCmd() --------------------- */ static int TdgtBtnSendCmd(pti, cmd_type, cmd_arg, pv_cmd_userdata) TidgetInfo *pti; int cmd_type, cmd_arg; void *pv_cmd_userdata; { TdgtBtn *pTdgtBtn=(TdgtBtn*)(pti->tidget); if (pTdgtBtn != NULL) { } return FALSE; } /* --------------------- TdgtBtnReset() --------------------- */ void TdgtBtnReset(pTdgtBtn) TdgtBtn *pTdgtBtn; { switch (pTdgtBtn->btn_type) { case TGMUTYPE_TEXT: UtilFree(pTdgtBtn->str); break; case TGMUTYPE_COLOR: break; case TGMUTYPE_BITMAP: break; } pTdgtBtn->str = NULL; } /* --------------------- CreateTdgtBtn() --------------------- */ TdgtBtn *CreateTdgtBtn(parent_win, parent_tidgetinfo, ctl_id, x, y, w, h, h_pad, v_pad, btn_type, btn_style, state, font_style, str, pmosi) Window parent_win; TidgetInfo *parent_tidgetinfo; int ctl_id, x, y, w, h, h_pad, v_pad, state, font_style; char *str; MouseOverStatusInfo *pmosi; { int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); TdgtBtn *pTdgtBtn=NULL; pTdgtBtn = (TdgtBtn*)malloc(sizeof(TdgtBtn)); if (pTdgtBtn == NULL) FailAllocMessage(); memset(pTdgtBtn, 0, sizeof(TdgtBtn)); pTdgtBtn->pti = NewTidgetInfo(parent_tidgetinfo, TIDGET_TYPE_BTN, pTdgtBtn, ctl_id, NULL); if ((pTdgtBtn->pti->tci.win=XCreateSimpleWindow(mainDisplay, parent_win, x, y, w, h, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("CreateTdgtBtn()", NULL, TRUE); } XSelectInput(mainDisplay, pTdgtBtn->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); SetTidgetInfoBasic(pTdgtBtn->pti, TIDGET_TYPE_BTN, pTdgtBtn, parent_win, x, y, w, h, h_pad, v_pad, state, NULL); TidgetSetCallbacks(pTdgtBtn->pti, RedrawTdgtBtn, TdgtBtnEventHandler, IsTdgtBtnEvent, DestroyTdgtBtn, MapTdgtBtn, TdgtBtnMoveResize, TdgtBtnSendCmd); switch (btn_type) { case TGMUTYPE_TEXT: if (str != NULL) { pTdgtBtn->str = UtilStrDup(str); if (pTdgtBtn->str == NULL) FailAllocMessage(); } break; case TGMUTYPE_COLOR: pTdgtBtn->str = str; break; case TGMUTYPE_BITMAP: pTdgtBtn->str = str; break; } if (pmosi != NULL) { memcpy(&pTdgtBtn->mosi, pmosi, sizeof(MouseOverStatusInfo)); } pTdgtBtn->btn_type = btn_type; pTdgtBtn->btn_style = btn_style; pTdgtBtn->font_style = font_style; return pTdgtBtn; } /* --------------------- TdgtBtnSetText() --------------------- */ int TdgtBtnSetText(pTdgtBtn, str, pmosi) TdgtBtn *pTdgtBtn; char *str; MouseOverStatusInfo *pmosi; { switch (pTdgtBtn->btn_type) { case TGMUTYPE_TEXT: UtilFree(pTdgtBtn->str); if (str != NULL) { pTdgtBtn->str = UtilStrDup(str); if (pTdgtBtn->str == NULL) FailAllocMessage(); } break; case TGMUTYPE_COLOR: pTdgtBtn->str = str; break; case TGMUTYPE_BITMAP: pTdgtBtn->str = str; break; } if (pmosi != NULL) { memcpy(&pTdgtBtn->mosi, pmosi, sizeof(MouseOverStatusInfo)); } RedrawTdgtBtn(pTdgtBtn->pti); return TRUE; } /* --------------------- TdgtBtnGetText() --------------------- */ char *TdgtBtnGetText(pTdgtBtn) TdgtBtn *pTdgtBtn; { return pTdgtBtn->str; } /* --------------------- TdgtBtnSetState() --------------------- */ int TdgtBtnSetState(pTdgtBtn, new_state) TdgtBtn *pTdgtBtn; int new_state; { int need_to_redraw=(pTdgtBtn->pti->tci.state != new_state); pTdgtBtn->pti->tci.state = new_state; if (need_to_redraw) { RedrawTdgtBtn(pTdgtBtn->pti); } return TRUE; } /* --------------------- TdgtBtnGetState() --------------------- */ int TdgtBtnGetState(pTdgtBtn) TdgtBtn *pTdgtBtn; { return pTdgtBtn->pti->tci.state; } /* --------------------- Init & Clean Up --------------------- */ int InitTdgtBtn() { if (msgFontSet == NULL && msgFontPtr == NULL) { gnBtnFontHeight = defaultFontHeight; gnBtnFontWidth = defaultFontWidth; gnBtnFontAsc = defaultFontAsc; gnBtnFontDes = defaultFontDes; gnBtnFontPtr = defaultFontPtr; } else { gnBtnFontHeight = msgFontHeight; gnBtnFontWidth = msgFontWidth; gnBtnFontAsc = msgFontAsc; gnBtnFontDes = msgFontDes; gnBtnFontPtr = msgFontPtr; } return TRUE; } void CleanUpTdgtBtn() { gnBtnFontHeight = gnBtnFontWidth = gnBtnFontAsc = gnBtnFontDes = 0; gnBtnFontPtr = NULL; } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/attr.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000012250�11602233310�014102� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/attr.e,v 1.8 2011/05/16 16:21:56 william Exp $ */ #ifndef _ATTR_E_ #define _ATTR_E_ typedef struct tagAttrGroupInfo { char *group_name; char *group_value; char *displayed_names; /* better looking group_value */ int num_attrs; char **attr_name; /* just pointers, do not free */ } AttrGroupInfo; extern int dropObsIconAttrWhenUpdate; extern int maxAttrGroups; extern AttrGroupInfo **gAttrGroupInfo; extern EditAttrInfo *gpEditAttrInEditorAttrInfo; #ifdef _INCLUDE_FROM_ATTR_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_ATTR_C_*/ extern void LinkInAttr ARGS_DECL((struct AttrRec *, struct AttrRec *, struct AttrRec *)); extern void FreeAttr ARGS_DECL((struct AttrRec *)); extern void UnlinkAttr ARGS_DECL((struct AttrRec *)); extern void UpdAttrOwner ARGS_DECL((struct AttrRec *first_attr, struct ObjRec *owner_obj)); extern void ParseAttrStr ARGS_DECL((char *buf, char *name, int name_sz, char *value, int value_sz)); extern void UpdateAttr ARGS_DECL((struct TextRec *, struct AttrRec *)); extern void DrawAttrs ARGS_DECL((Window, int X, int Y, struct AttrRec *)); extern void MoveAttrs ARGS_DECL((struct AttrRec *, int Dx, int Dy)); extern void DelAllAttrs ARGS_DECL((struct AttrRec *)); extern struct AttrRec * AddAttrByNameAndValue ARGS_DECL((struct ObjRec *, char *AttrName, char *AttrValue)); extern void DupAttrs ARGS_DECL((struct ObjRec *From, struct ObjRec *To)); extern void AddAttrs ARGS_DECL((void)); extern void SaveAttrs ARGS_DECL((FILE *, struct AttrRec *)); extern char * ReadAttrString ARGS_DECL((char *)); extern int ReadAttr ARGS_DECL((FILE *, struct AttrRec **)); extern struct ObjRec *FindTopLevelObjWithType ARGS_DECL((char*)); extern void ShowAllAttrNames ARGS_DECL((void)); extern void ShowAllAttrs ARGS_DECL((void)); extern void HideAllAttrs ARGS_DECL((void)); extern void HideAllAttrNames ARGS_DECL((void)); extern void DetachGroupAttrs ARGS_DECL((struct ObjRec *, struct SelRec **Top, struct SelRec **Bot)); extern void DetachAllObjAttrs ARGS_DECL((struct ObjRec *, struct SelRec **Top, struct SelRec **Bot)); extern void DetachAttrs ARGS_DECL((void)); extern void UpdAttr ARGS_DECL((struct AttrRec *)); extern TgMenu *CreateAttrMenu ARGS_DECL((TgMenu*, int x, int y, int num_items, char **menu_strings, char **status_strings, int *pixels)); extern void FreeEditAttrInfo ARGS_DECL((EditAttrInfo*)); extern int HasEditAttrsInContextMenu ARGS_DECL((struct ObjRec *, struct AttrRec **)); extern void FreeRestrictedAttrNames ARGS_DECL((char **ppsz_restricted, int num_restricted)); extern void GetRestrictedAttrNames ARGS_DECL((struct ObjRec *, char ***pppsz_restricted, int *pn_num_restricted)); extern void GetAttrGroupAttrNames ARGS_DECL((struct ObjRec *, int group_index, char ***pppsz_restricted, int *pn_num_restricted)); extern int IsRestrictedAttr ARGS_DECL((char *attr_name, char **ppsz_restricted, int num_restricted)); extern EditAttrInfo *CreateEditAttrInfo ARGS_DECL((struct ObjRec *)); extern EditAttrInfo *CreateEditAttrGroupInfo ARGS_DECL((struct ObjRec *)); extern void MoveAttr ARGS_DECL((void)); extern void CopyAndUpdateAttrs ARGS_DECL((struct ObjRec *To, struct ObjRec *From)); extern void ToggleNamedAttrShown ARGS_DECL((char *)); extern void ToggleEqAttrShown ARGS_DECL((void)); extern void AddFileAttrs ARGS_DECL((void)); extern void DetachFileAttrs ARGS_DECL((void)); extern int BlankStr ARGS_DECL((char*)); extern void EditFileAttrs ARGS_DECL((void)); extern void EditAttrs ARGS_DECL((void)); extern void CleanUpAttr ARGS_DECL((void)); extern int InitAttr ARGS_DECL((void)); #ifdef _INCLUDE_FROM_ATTR_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_ATTR_C_*/ #endif /*_ATTR_E_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/box.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000003713�11602233310�013724� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/box.e,v 1.7 2011/06/09 15:55:15 cvsps Exp $ */ #ifndef _BOX_E_ #define _BOX_E_ extern int boxDrawn; #ifdef _INCLUDE_FROM_BOX_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_BOX_C_*/ extern void MyBox ARGS_DECL((Window, GC, int X1, int Y1, int X2, int Y2)); extern void DumpBoxObj ARGS_DECL((FILE *, struct ObjRec *)); extern int CreateBoxObj ARGS_DECL((int X1, int Y1, int X2, int Y2, int CreateAbsolute)); extern void DrawBoxObj ARGS_DECL((Window, int X, int Y, struct ObjRec *)); extern void DrawBox ARGS_DECL((XEvent *)); extern void MakeBoxObjFromBoundingBox ARGS_DECL((void)); extern void SaveBoxObj ARGS_DECL((FILE *, struct ObjRec *)); extern void ReadBoxObj ARGS_DECL((FILE *, char *, struct ObjRec **)); extern void SetBoxPropMask ARGS_DECL((struct ObjRec *, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void FreeBoxObj ARGS_DECL((struct ObjRec *)); #ifdef _INCLUDE_FROM_BOX_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_BOX_C_*/ #endif /*_BOX_E_*/ �����������������������������������������������������tgif-QPL-4.2.5/chat.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000003642�11602233311�014055� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/chat.e,v 1.6 2011/05/16 16:21:56 william Exp $ */ #ifndef _CHAT_E_ #define _CHAT_E_ #include "tidget.h" extern char *cmdLineChatNickName; #ifdef _INCLUDE_FROM_CHAT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_CHAT_C_*/ extern void RedrawChatWindow ARGS_DECL((void)); extern void MoveResizeChatWindow ARGS_DECL((int x, int y, int w, int h)); extern void ChatEventHandler ARGS_DECL((XEvent*, TidgetInfo*)); extern int IsChatWindowEvent ARGS_DECL((XEvent*, TidgetInfo**)); extern int GetInitialChatWindowHeight ARGS_DECL((void)); extern void SetChatWindowGeom ARGS_DECL((void)); extern void MapChatSubWindows ARGS_DECL((void)); extern int CreateChatSubWindows ARGS_DECL((void)); extern void ChatAppendChatLine ARGS_DECL((TextFormatInfo*, char *nick_name, char *encoding, char *buf)); extern void ChatAddUser ARGS_DECL((char*)); extern int InitChat ARGS_DECL((void)); extern void CleanUpChat ARGS_DECL((void)); #ifdef _INCLUDE_FROM_CHAT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_CHAT_C_*/ #endif /*_CHAT_E_*/ ����������������������������������������������������������������������������������������������tgif-QPL-4.2.5/keys.obj�����������������������������������������������������������������������������0000644�0000764�0000764�00000076776�11602233312�014462� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 2.12 state(0,26,100,128,64,0,8,1,0,1,1,0,0,0,0,1,0,2,0,2,0,0,0,10,0,0,1,1,0,16). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/keys.obj,v 1.1 2004/09/01 04:41:32 william Exp $ % %W% % text('yellow',576,64,2,1,5,1,1,0,1,388,29,62,0,24,5,0,0,0,0,[ "Keyboard Shortcuts for Tgif-2.12"]). poly('yellow',2,[ 376,96,776,96],0,2,1,222,0,0,0,0,10,4,0,[ ]). poly('yellow',2,[ 376,100,776,100],0,2,1,223,0,0,0,0,10,4,0,[ ]). group([ rcbox('yellow',736,704,992,864,0,1,1,0,16,206,0,0,[ ]), text('yellow',864,704,2,0,4,1,1,0,1,163,22,173,0,18,4,0,0,0,0,[ "Miscellaneous Keys"]), group([ text('yellow',752,752,2,0,2,1,0,0,1,12,15,211,0,12,3,0,0,0,0,[ "^z"]), text('yellow',776,752,2,0,2,1,0,0,1,8,15,769,0,12,3,0,0,0,0,[ "-"]), text('yellow',784,752,2,0,2,1,0,0,1,148,15,778,0,12,3,0,0,0,0,[ "animate (escape to driver)"]) ], 787,0,[ ]), group([ text('yellow',752,736,2,0,2,1,0,0,1,13,15,207,0,12,3,0,0,0,0,[ "^c"]), text('yellow',784,736,2,0,2,1,0,0,1,86,15,788,0,12,3,0,0,0,0,[ "change domain"]), text('yellow',776,736,2,0,2,1,0,0,1,8,15,791,0,12,3,0,0,0,0,[ "-"]) ], 795,0,[ ]), group([ text('yellow',752,768,2,0,2,1,0,0,1,14,15,212,0,12,3,0,0,0,0,[ "#b"]), text('yellow',784,768,2,0,2,1,0,0,1,136,15,796,0,12,3,0,0,0,0,[ "probe (escape to driver)"]), text('yellow',776,768,2,0,2,1,0,0,1,8,15,799,0,12,3,0,0,0,0,[ "-"]) ], 803,0,[ ]), group([ text('yellow',752,848,2,0,2,1,0,0,1,14,15,216,0,12,3,0,0,0,0,[ "#y"]), text('yellow',784,848,2,0,2,1,0,0,1,150,15,819,0,12,3,0,0,0,0,[ "simulate (escape to driver)"]), text('yellow',776,848,2,0,2,1,0,0,1,8,15,825,0,12,3,0,0,0,0,[ "-"]) ], 829,0,[ ]), group([ text('yellow',752,832,2,0,2,1,0,0,1,13,15,214,0,12,3,0,0,0,0,[ "#x"]), text('yellow',776,832,2,0,2,1,0,0,1,8,15,783,0,12,3,0,0,0,0,[ "-"]), text('yellow',784,832,2,0,2,1,0,0,1,145,15,818,0,12,3,0,0,0,0,[ "escape (escape to driver)"]) ], 833,0,[ ]), group([ text('yellow',752,816,2,0,2,1,0,0,1,13,15,213,0,12,3,0,0,0,0,[ "#s"]), text('yellow',784,816,2,0,2,1,0,0,1,134,15,814,0,12,3,0,0,0,0,[ "solve (escape to driver)"]), text('yellow',776,816,2,0,2,1,0,0,1,8,15,817,0,12,3,0,0,0,0,[ "-"]) ], 845,0,[ ]), group([ text('yellow',784,800,2,0,2,1,0,0,1,137,15,809,0,12,3,0,0,0,0,[ "flash a selected polyline"]), text('yellow',752,800,2,0,2,1,0,0,1,10,15,209,0,12,3,0,0,0,0,[ "#f"]), text('yellow',776,800,2,0,2,1,0,0,1,8,15,813,0,12,3,0,0,0,0,[ "-"]) ], 1069,0,[ ]), group([ text('yellow',784,784,2,0,2,1,0,0,1,202,15,804,0,12,3,0,0,0,0,[ "send a token on a selected polyline"]), text('yellow',752,784,2,0,2,1,0,0,1,14,15,208,0,12,3,0,0,0,0,[ "#e"]), text('yellow',776,784,2,0,2,1,0,0,1,8,15,808,0,12,3,0,0,0,0,[ "-"]) ], 1073,0,[ ]) ], 1108,0,[ ]). group([ rcbox('yellow',736,880,992,1152,0,1,1,0,16,186,0,0,[ ]), text('yellow',864,880,2,0,4,1,1,0,1,118,22,173,0,18,4,0,0,0,0,[ "Attribute Keys"]), group([ text('yellow',784,992,2,0,2,2,0,0,1,161,30,1161,0,12,3,0,0,0,0,[ "move/justify an attribute of a", "selected object"]), text('yellow',752,992,2,0,2,1,0,0,1,16,15,191,0,12,3,0,0,0,0,[ "#m"]), text('yellow',776,992,2,0,2,1,0,0,1,8,15,1165,0,12,3,0,0,0,0,[ "-"]) ], 1170,0,[ ]), group([ text('yellow',784,1024,2,0,2,2,0,0,1,195,30,1171,0,12,3,0,0,0,0,[ "show all the attribute names of the", "selected objects"]), text('yellow',752,1024,2,0,2,1,0,0,1,14,15,193,0,12,3,0,0,0,0,[ "#n"]), text('yellow',776,1024,2,0,2,1,0,0,1,8,15,1175,0,12,3,0,0,0,0,[ "-"]) ], 1179,0,[ ]), group([ text('yellow',784,1056,2,0,2,2,0,0,1,171,30,1180,0,12,3,0,0,0,0,[ "detach all the attributes of the", "selected objects"]), text('yellow',752,1056,2,0,2,1,0,0,1,11,15,194,0,12,3,0,0,0,0,[ "#t"]), text('yellow',776,1056,2,0,2,1,0,0,1,8,15,1184,0,12,3,0,0,0,0,[ "-"]) ], 1188,0,[ ]), group([ text('yellow',784,960,2,0,2,2,0,0,1,203,30,1189,0,12,3,0,0,0,0,[ "hide attribute names of the selected", "objects"]), text('yellow',752,960,2,0,2,1,0,0,1,10,15,189,0,12,3,0,0,0,0,[ "#j"]), text('yellow',776,960,2,0,2,1,0,0,1,8,15,1194,0,12,3,0,0,0,0,[ "-"]) ], 1198,0,[ ]), group([ text('yellow',784,912,2,0,2,3,0,0,1,184,45,1199,0,12,3,0,0,0,0,[ "attach selected text objects to a", "selected non-text object as", "attributes"]), text('yellow',752,912,2,0,2,1,0,0,1,14,15,187,0,12,3,0,0,0,0,[ "#a"]), text('yellow',776,912,2,0,2,1,0,0,1,8,15,1203,0,12,3,0,0,0,0,[ "-"]) ], 1207,0,[ ]), group([ text('yellow',784,1088,2,0,2,2,0,0,1,161,30,1229,0,12,3,0,0,0,0,[ "show all the attributes of the", "selected objects"]), text('yellow',752,1088,2,0,2,1,0,0,1,15,15,218,0,12,3,0,0,0,0,[ "#-"]), text('yellow',776,1088,2,0,2,1,0,0,1,8,15,1234,0,12,3,0,0,0,0,[ "-"]) ], 1238,0,[ ]), group([ text('yellow',784,1120,2,0,2,2,0,0,1,156,30,1239,0,12,3,0,0,0,0,[ "hide all the attributes of the", "selected objects"]), text('yellow',752,1120,2,0,2,1,0,0,1,20,15,195,0,12,3,0,0,0,0,[ "^#h"]), text('yellow',776,1120,2,0,2,1,0,0,1,8,15,846,0,12,3,0,0,0,0,[ "-"]) ], 1246,0,[ ]) ], 1277,0,[ ]). group([ rcbox('yellow',448,848,704,1056,0,1,1,0,16,197,0,0,[ ]), text('yellow',576,848,2,0,4,1,1,0,1,152,22,173,0,18,4,0,0,0,0,[ "Symbol/Icon Keys"]), group([ text('yellow',464,912,2,0,2,1,0,0,1,13,15,25,0,12,3,0,0,0,0,[ "^v"]), text('yellow',488,912,2,0,2,1,0,0,1,8,15,742,0,12,3,0,0,0,0,[ "-"]), text('yellow',496,912,2,0,2,1,0,0,1,188,15,744,0,12,3,0,0,0,0,[ "push into a building-block object"]) ], 755,0,[ ]), group([ text('yellow',496,1024,2,0,2,2,0,0,1,182,30,2095,0,12,3,0,0,0,0,[ "update iconic representations of", "the selected objects"]), text('yellow',464,1024,2,0,2,1,0,0,1,20,15,205,0,12,3,0,0,0,0,[ "^#u"]), text('yellow',488,1024,2,0,2,1,0,0,1,8,15,2099,0,12,3,0,0,0,0,[ "-"]) ], 2103,0,[ ]), group([ text('yellow',496,880,2,0,2,1,0,0,1,195,15,2134,0,12,3,0,0,0,0,[ "instantiate a building-block object"]), text('yellow',464,880,2,0,2,1,0,0,1,9,15,199,0,12,3,0,0,0,0,[ "^i"]), text('yellow',488,880,2,0,2,1,0,0,1,8,15,751,0,12,3,0,0,0,0,[ "-"]) ], 2146,0,[ ]), group([ text('yellow',496,896,2,0,2,1,0,0,1,174,15,2130,0,12,3,0,0,0,0,[ "pop back and close symbol file"]), text('yellow',464,896,2,0,2,1,0,0,1,12,15,23,0,12,3,0,0,0,0,[ "^k"]), text('yellow',488,896,2,0,2,1,0,0,1,8,15,2138,0,12,3,0,0,0,0,[ "-"]) ], 2150,0,[ ]), group([ text('yellow',464,928,2,0,2,1,0,0,1,16,15,200,0,12,3,0,0,0,0,[ "^#i"]), text('yellow',496,928,2,0,2,1,0,0,1,180,15,2117,0,12,3,0,0,0,0,[ "make the selected object iconic"]), text('yellow',488,928,2,0,2,1,0,0,1,8,15,2139,0,12,3,0,0,0,0,[ "-"]) ], 2154,0,[ ]), group([ text('yellow',496,944,2,0,2,2,0,0,1,181,30,2113,0,12,3,0,0,0,0,[ "make the selected icon object a", "grouped object"]), text('yellow',464,944,2,0,2,1,0,0,1,16,15,201,0,12,3,0,0,0,0,[ "^#j"]), text('yellow',488,944,2,0,2,1,0,0,1,8,15,2140,0,12,3,0,0,0,0,[ "-"]) ], 2158,0,[ ]), group([ text('yellow',496,976,2,0,2,1,0,0,1,195,15,2109,0,12,3,0,0,0,0,[ "make the selected object symbolic"]), text('yellow',464,976,2,0,2,1,0,0,1,22,15,203,0,12,3,0,0,0,0,[ "^#m"]), text('yellow',488,976,2,0,2,1,0,0,1,8,15,2141,0,12,3,0,0,0,0,[ "-"]) ], 2162,0,[ ]), group([ text('yellow',496,992,2,0,2,2,0,0,1,196,30,2104,0,12,3,0,0,0,0,[ "make the selected symbol object a", "grouped object"]), text('yellow',464,992,2,0,2,1,0,0,1,20,15,204,0,12,3,0,0,0,0,[ "^#n"]), text('yellow',488,992,2,0,2,1,0,0,1,8,15,2142,0,12,3,0,0,0,0,[ "-"]) ], 2166,0,[ ]) ], 2201,0,[ ]). group([ group([ text('yellow',784,640,2,0,2,1,0,0,1,198,15,2220,0,12,3,0,0,0,0,[ "cycle among the output file formats"]), text('yellow',752,640,2,0,2,1,0,0,1,19,15,154,0,12,3,0,0,0,0,[ "^#x"]), text('yellow',776,640,2,0,2,1,0,0,1,8,15,2224,0,12,3,0,0,0,0,[ "-"]) ], 2228,0,[ ]), rcbox('yellow',736,352,992,688,0,1,1,0,16,75,0,0,[ ]), text('yellow',864,352,2,0,4,1,1,0,1,73,22,77,0,18,4,0,0,0,0,[ "I/O Keys"]), group([ text('yellow',752,416,2,0,2,1,0,0,1,13,15,87,0,12,3,0,0,0,0,[ "^p"]), text('yellow',784,416,2,0,2,2,0,0,1,195,30,698,0,12,3,0,0,0,0,[ "print the current page (or export in", "xbm, xpm, eps, or ps formats)"]), text('yellow',776,416,2,0,2,1,0,0,1,8,15,699,0,12,3,0,0,0,0,[ "-"]) ], 737,0,[ ]), group([ text('yellow',752,480,2,0,2,1,0,0,1,12,15,93,0,12,3,0,0,0,0,[ "^s"]), text('yellow',784,480,2,0,2,1,0,0,1,195,15,712,0,12,3,0,0,0,0,[ "save the current object/symbol file"]), text('yellow',776,480,2,0,2,1,0,0,1,8,15,716,0,12,3,0,0,0,0,[ "-"]) ], 741,0,[ ]), group([ text('yellow',784,384,2,0,2,1,0,0,1,180,15,882,0,12,3,0,0,0,0,[ "open a new unnamed object file"]), text('yellow',752,384,2,0,2,1,0,0,1,13,15,81,0,12,3,0,0,0,0,[ "^n"]), text('yellow',776,384,2,0,2,1,0,0,1,8,15,886,0,12,3,0,0,0,0,[ "-"]) ], 890,0,[ ]), group([ text('yellow',784,400,2,0,2,1,0,0,1,145,15,891,0,12,3,0,0,0,0,[ "open an object file to edit"]), text('yellow',752,400,2,0,2,1,0,0,1,13,15,84,0,12,3,0,0,0,0,[ "^o"]), text('yellow',776,400,2,0,2,1,0,0,1,8,15,895,0,12,3,0,0,0,0,[ "-"]) ], 899,0,[ ]), group([ text('yellow',784,464,2,0,2,1,0,0,1,92,15,900,0,12,3,0,0,0,0,[ "redraw the page"]), text('yellow',752,464,2,0,2,1,0,0,1,10,15,90,0,12,3,0,0,0,0,[ "^r"]), text('yellow',776,464,2,0,2,1,0,0,1,8,15,904,0,12,3,0,0,0,0,[ "-"]) ], 908,0,[ ]), group([ text('yellow',784,448,2,0,2,1,0,0,1,42,15,909,0,12,3,0,0,0,0,[ "quit tgif"]), text('yellow',752,448,2,0,2,1,0,0,1,13,15,89,0,12,3,0,0,0,0,[ "^q"]), text('yellow',776,448,2,0,2,1,0,0,1,8,15,913,0,12,3,0,0,0,0,[ "-"]) ], 917,0,[ ]), group([ text('yellow',784,496,2,0,2,2,0,0,1,161,30,918,0,12,3,0,0,0,0,[ "print the current page with a", "specified command"]), text('yellow',752,496,2,0,2,1,0,0,1,14,15,95,0,12,3,0,0,0,0,[ "^-"]), text('yellow',776,496,2,0,2,1,0,0,1,8,15,922,0,12,3,0,0,0,0,[ "-"]) ], 926,0,[ ]), group([ text('yellow',784,528,2,0,2,1,0,0,1,200,15,929,0,12,3,0,0,0,0,[ "import a .obj file into the current file"]), text('yellow',752,528,2,0,2,1,0,0,1,14,15,98,0,12,3,0,0,0,0,[ "#p"]), text('yellow',776,528,2,0,2,1,0,0,1,8,15,933,0,12,3,0,0,0,0,[ "-"]) ], 948,0,[ ]), group([ text('yellow',784,544,2,0,2,2,0,0,1,138,30,1356,0,12,3,0,0,0,0,[ "specify the percent print", "reduction/maginification"]), text('yellow',752,544,2,0,2,1,0,0,1,18,15,224,0,12,3,0,0,0,0,[ "#%"]), text('yellow',776,544,2,0,2,1,0,0,1,8,15,1360,0,12,3,0,0,0,0,[ "-"]) ], 1364,0,[ ]), group([ text('yellow',784,576,2,0,2,1,0,0,1,196,15,1365,0,12,3,0,0,0,0,[ "save selected objects in a new file"]), text('yellow',752,576,2,0,2,1,0,0,1,14,15,225,0,12,3,0,0,0,0,[ "#~"]), text('yellow',776,576,2,0,2,1,0,0,1,8,15,1369,0,12,3,0,0,0,0,[ "-"]) ], 1373,0,[ ]), group([ text('yellow',752,592,2,0,2,1,0,0,1,11,15,274,0,12,3,0,0,0,0,[ "#("]), text('yellow',784,592,2,0,2,1,0,0,1,100,15,1431,0,12,3,0,0,0,0,[ "import an EPS file"]), text('yellow',776,592,2,0,2,1,0,0,1,8,15,1434,0,12,3,0,0,0,0,[ "-"]) ], 1438,0,[ ]), group([ text('yellow',784,624,2,0,2,1,0,0,1,177,15,2202,0,12,3,0,0,0,0,[ "save the file under a new name"]), text('yellow',752,624,2,0,2,1,0,0,1,19,15,100,0,12,3,0,0,0,0,[ "^#s"]), text('yellow',776,624,2,0,2,1,0,0,1,8,15,2211,0,12,3,0,0,0,0,[ "-"]) ], 2215,0,[ ]), group([ text('yellow',784,608,2,0,2,1,0,0,1,202,15,2206,0,12,3,0,0,0,0,[ "select color or black & white output"]), text('yellow',752,608,2,0,2,1,0,0,1,19,15,45,0,12,3,0,0,0,0,[ "^#k"]), text('yellow',776,608,2,0,2,1,0,0,1,8,15,2210,0,12,3,0,0,0,0,[ "-"]) ], 2219,0,[ ]), group([ text('yellow',784,672,2,0,2,1,0,0,1,142,15,2233,0,12,3,0,0,0,0,[ "import an X11 pixmap file"]), text('yellow',752,672,2,0,2,1,0,0,1,17,15,103,0,12,3,0,0,0,0,[ "^#,"]), text('yellow',776,672,2,0,2,1,0,0,1,8,15,2237,0,12,3,0,0,0,0,[ "-"]) ], 2241,0,[ ]), group([ text('yellow',784,656,2,0,2,1,0,0,1,140,15,2229,0,12,3,0,0,0,0,[ "import an X11 bitmap file"]), text('yellow',752,656,2,0,2,1,0,0,1,16,15,102,0,12,3,0,0,0,0,[ "^#."]), text('yellow',776,656,2,0,2,1,0,0,1,8,15,705,0,12,3,0,0,0,0,[ "-"]) ], 2245,0,[ ]) ], 2321,0,[ ]). group([ rcbox('yellow',448,624,704,832,0,1,1,0,16,172,0,0,[ ]), text('yellow',576,624,2,0,4,1,1,0,1,135,22,173,0,18,4,0,0,0,0,[ "Grid/Zoom Keys"]), group([ text('yellow',496,688,2,0,2,1,0,0,1,128,15,1152,0,12,3,0,0,0,0,[ "increment the grid size"]), text('yellow',464,688,2,0,2,1,0,0,1,10,15,177,0,12,3,0,0,0,0,[ "#i"]), text('yellow',488,688,2,0,2,1,0,0,1,8,15,1156,0,12,3,0,0,0,0,[ "-"]) ], 1160,0,[ ]), group([ text('yellow',496,672,2,0,2,1,0,0,1,147,15,1991,0,12,3,0,0,0,0,[ "show/un-show grid points"]), text('yellow',464,672,2,0,2,1,0,0,1,14,15,176,0,12,3,0,0,0,0,[ "#g"]), text('yellow',488,672,2,0,2,1,0,0,1,8,15,1996,0,12,3,0,0,0,0,[ "-"]) ], 2000,0,[ ]), group([ text('yellow',496,656,2,0,2,1,0,0,1,132,15,1987,0,12,3,0,0,0,0,[ "decrement the grid size"]), text('yellow',464,656,2,0,2,1,0,0,1,14,15,175,0,12,3,0,0,0,0,[ "#d"]), text('yellow',488,656,2,0,2,1,0,0,1,8,15,1995,0,12,3,0,0,0,0,[ "-"]) ], 2004,0,[ ]), group([ text('yellow',464,768,2,0,2,1,0,0,1,20,15,182,0,12,3,0,0,0,0,[ "^#g"]), text('yellow',488,768,2,0,2,1,0,0,1,8,15,2022,0,12,3,0,0,0,0,[ "-"]), text('yellow',496,768,2,0,2,2,0,0,1,174,30,2023,0,12,3,0,0,0,0,[ "toggle the snapping to the grid", "points"]) ], 2039,0,[ ]), group([ text('yellow',464,752,2,0,2,1,0,0,1,10,15,227,0,12,3,0,0,0,0,[ "#`"]), text('yellow',496,752,2,0,2,1,0,0,1,117,15,2016,0,12,3,0,0,0,0,[ "zoom all the way out"]), text('yellow',488,752,2,0,2,1,0,0,1,8,15,2021,0,12,3,0,0,0,0,[ "-"]) ], 2043,0,[ ]), group([ text('yellow',496,736,2,0,2,1,0,0,1,71,15,2012,0,12,3,0,0,0,0,[ "default zoom"]), text('yellow',464,736,2,0,2,1,0,0,1,10,15,226,0,12,3,0,0,0,0,[ "#:"]), text('yellow',488,736,2,0,2,1,0,0,1,8,15,2020,0,12,3,0,0,0,0,[ "-"]) ], 2047,0,[ ]), group([ text('yellow',464,720,2,0,2,1,0,0,1,13,15,181,0,12,3,0,0,0,0,[ "#z"]), text('yellow',496,720,2,0,2,1,0,0,1,43,15,2009,0,12,3,0,0,0,0,[ "zoom in"]), text('yellow',488,720,2,0,2,1,0,0,1,8,15,2019,0,12,3,0,0,0,0,[ "-"]) ], 2051,0,[ ]), group([ text('yellow',496,704,2,0,2,1,0,0,1,51,15,2005,0,12,3,0,0,0,0,[ "zoom out"]), text('yellow',464,704,2,0,2,1,0,0,1,14,15,180,0,12,3,0,0,0,0,[ "#o"]), text('yellow',488,704,2,0,2,1,0,0,1,8,15,756,0,12,3,0,0,0,0,[ "-"]) ], 2055,0,[ ]), group([ text('yellow',496,800,2,0,2,2,0,0,1,179,30,2028,0,12,3,0,0,0,0,[ "toggle between the English and", "the Metric grid systems"]), text('yellow',464,800,2,0,2,1,0,0,1,21,15,183,0,12,3,0,0,0,0,[ "^#-"]), text('yellow',488,800,2,0,2,1,0,0,1,8,15,2027,0,12,3,0,0,0,0,[ "-"]) ], 2410,0,[ ]) ], 2449,0,[ ]). group([ rcbox('yellow',448,480,704,608,0,1,1,0,16,155,0,0,[ ]), text('yellow',576,480,2,0,4,1,1,0,1,193,22,157,0,18,4,0,0,0,0,[ "Window Scrolling Keys"]), group([ text('yellow',464,576,2,0,2,1,0,0,1,13,15,231,0,12,3,0,0,0,0,[ "#^"]), text('yellow',496,576,2,0,2,2,0,0,1,141,30,1420,0,12,3,0,0,0,0,[ "scroll to the origin set by", "SaveOrigin()"]), text('yellow',488,576,2,0,2,1,0,0,1,8,15,1426,0,12,3,0,0,0,0,[ "-"]) ], 1430,0,[ ]), group([ text('yellow',464,512,2,0,2,1,0,0,1,10,15,161,0,12,3,0,0,0,0,[ "^,"]), text('yellow',488,512,2,0,2,1,0,0,1,8,15,757,0,12,3,0,0,0,0,[ "-"]), text('yellow',496,512,2,0,2,1,0,0,1,51,15,2462,0,12,3,0,0,0,0,[ "scroll left"]) ], 2471,0,[ ]), group([ text('yellow',496,528,2,0,2,1,0,0,1,59,15,2458,0,12,3,0,0,0,0,[ "scroll right"]), text('yellow',464,528,2,0,2,1,0,0,1,9,15,164,0,12,3,0,0,0,0,[ "^."]), text('yellow',488,528,2,0,2,1,0,0,1,8,15,2465,0,12,3,0,0,0,0,[ "-"]) ], 2475,0,[ ]), group([ text('yellow',496,544,2,0,2,1,0,0,1,48,15,2454,0,12,3,0,0,0,0,[ "scroll up"]), text('yellow',464,544,2,0,2,1,0,0,1,11,15,167,0,12,3,0,0,0,0,[ "#,"]), text('yellow',488,544,2,0,2,1,0,0,1,8,15,2466,0,12,3,0,0,0,0,[ "-"]) ], 2479,0,[ ]), group([ text('yellow',496,560,2,0,2,1,0,0,1,64,15,2450,0,12,3,0,0,0,0,[ "scroll down"]), text('yellow',464,560,2,0,2,1,0,0,1,10,15,169,0,12,3,0,0,0,0,[ "#."]), text('yellow',488,560,2,0,2,1,0,0,1,8,15,2467,0,12,3,0,0,0,0,[ "-"]) ], 2483,0,[ ]) ], 2506,0,[ ]). group([ rcbox('yellow',160,144,416,224,0,1,1,0,16,14,0,0,[ ]), text('yellow',288,144,2,0,4,1,1,0,1,125,22,18,0,18,4,0,0,0,0,[ "Selection Keys"]), group([ text('yellow',208,208,2,0,2,1,0,0,1,143,15,2800,0,12,3,0,0,0,0,[ "ungroup selected objects"]), text('yellow',176,208,2,0,2,1,0,0,1,13,15,24,0,12,3,0,0,0,0,[ "^u"]), text('yellow',200,208,2,0,2,1,0,0,1,8,15,2805,0,12,3,0,0,0,0,[ "-"]) ], 2809,0,[ ]), group([ text('yellow',208,192,2,0,2,1,0,0,1,129,15,2796,0,12,3,0,0,0,0,[ "group selected objects"]), text('yellow',176,192,2,0,2,1,0,0,1,13,15,21,0,12,3,0,0,0,0,[ "^g"]), text('yellow',200,192,2,0,2,1,0,0,1,8,15,2804,0,12,3,0,0,0,0,[ "-"]) ], 2813,0,[ ]), group([ text('yellow',176,176,2,0,2,1,0,0,1,13,15,20,0,12,3,0,0,0,0,[ "^a"]), text('yellow',208,176,2,0,2,1,0,0,1,51,15,411,0,12,3,0,0,0,0,[ "select all"]), text('yellow',200,176,2,0,2,1,0,0,1,8,15,412,0,12,3,0,0,0,0,[ "-"]) ], 2817,0,[ ]) ], 2832,0,[ ]). group([ rcbox('yellow',448,144,704,448,0,1,1,0,16,28,0,0,[ ]), text('yellow',576,144,2,0,4,1,1,0,1,167,22,29,0,18,4,0,0,0,0,[ "Drawing Mode Keys"]), group([ text('yellow',496,176,2,0,2,1,0,0,1,152,15,2833,0,12,3,0,0,0,0,[ "save/restore drawing mode"]), text('yellow',464,176,2,0,2,1,0,0,1,13,15,31,0,12,3,0,0,0,0,[ "^e"]), text('yellow',488,176,2,0,2,1,0,0,1,8,15,2795,0,12,3,0,0,0,0,[ "-"]) ], 2897,0,[ ]), group([ text('yellow',496,192,2,0,2,1,0,0,1,186,15,2837,0,12,3,0,0,0,0,[ "change the drawing mode to text"]), text('yellow',464,192,2,0,2,1,0,0,1,15,15,32,0,12,3,0,0,0,0,[ "^w"]), text('yellow',488,192,2,0,2,1,0,0,1,8,15,2872,0,12,3,0,0,0,0,[ "-"]) ], 2901,0,[ ]), group([ text('yellow',464,208,2,0,2,1,0,0,1,13,15,36,0,12,3,0,0,0,0,[ "#k"]), text('yellow',496,208,2,0,2,1,0,0,1,199,15,2841,0,12,3,0,0,0,0,[ "change the drawing mode to select"]), text('yellow',488,208,2,0,2,1,0,0,1,8,15,2873,0,12,3,0,0,0,0,[ "-"]) ], 2905,0,[ ]), group([ text('yellow',464,224,2,0,2,1,0,0,1,14,15,37,0,12,3,0,0,0,0,[ "#q"]), text('yellow',496,224,2,0,2,2,0,0,1,161,30,2844,0,12,3,0,0,0,0,[ "change the drawing mode to", "polyline/open-spline"]), text('yellow',488,224,2,0,2,1,0,0,1,8,15,2874,0,12,3,0,0,0,0,[ "-"]) ], 2909,0,[ ]), group([ text('yellow',464,256,2,0,2,1,0,0,1,11,15,39,0,12,3,0,0,0,0,[ "#r"]), text('yellow',496,256,2,0,2,1,0,0,1,196,15,2847,0,12,3,0,0,0,0,[ "change drawing mode to rectangle"]), text('yellow',488,256,2,0,2,1,0,0,1,8,15,2876,0,12,3,0,0,0,0,[ "-"]) ], 2913,0,[ ]), group([ text('yellow',464,272,2,0,2,1,0,0,1,19,15,232,0,12,3,0,0,0,0,[ "#@"]), text('yellow',496,272,2,0,2,2,0,0,1,182,30,2850,0,12,3,0,0,0,0,[ "toggle between constrained and", "un-constrained move modes"]), text('yellow',488,272,2,0,2,1,0,0,1,8,15,2877,0,12,3,0,0,0,0,[ "-"]) ], 2917,0,[ ]), group([ text('yellow',464,304,2,0,2,1,0,0,1,13,15,237,0,12,3,0,0,0,0,[ "#$"]), text('yellow',496,304,2,0,2,2,0,0,1,199,30,2853,0,12,3,0,0,0,0,[ "change the drawing mode to select", "vertices"]), text('yellow',488,304,2,0,2,1,0,0,1,8,15,2879,0,12,3,0,0,0,0,[ "-"]) ], 2921,0,[ ]), group([ text('yellow',464,336,2,0,2,1,0,0,1,20,15,44,0,12,3,0,0,0,0,[ "^#e"]), text('yellow',496,336,2,0,2,2,0,0,1,161,30,2856,0,12,3,0,0,0,0,[ "change the drawing mode to", "rounded-corner rectangles"]), text('yellow',488,336,2,0,2,1,0,0,1,8,15,2881,0,12,3,0,0,0,0,[ "-"]) ], 2928,0,[ ]), group([ text('yellow',464,368,2,0,2,1,0,0,1,20,15,59,0,12,3,0,0,0,0,[ "^#q"]), text('yellow',496,368,2,0,2,2,0,0,1,161,30,2859,0,12,3,0,0,0,0,[ "change the drawing mode to", "polygon/close-spline"]), text('yellow',488,368,2,0,2,1,0,0,1,8,15,2883,0,12,3,0,0,0,0,[ "-"]) ], 2932,0,[ ]), group([ text('yellow',464,400,2,0,2,1,0,0,1,20,15,65,0,12,3,0,0,0,0,[ "^#v"]), text('yellow',496,400,2,0,2,1,0,0,1,189,15,2863,0,12,3,0,0,0,0,[ "change the drawing mode to oval"]), text('yellow',488,400,2,0,2,1,0,0,1,8,15,2885,0,12,3,0,0,0,0,[ "-"]) ], 2936,0,[ ]), group([ text('yellow',464,416,2,0,2,1,0,0,1,22,15,68,0,12,3,0,0,0,0,[ "^#w"]), text('yellow',496,416,2,0,2,1,0,0,1,177,15,2866,0,12,3,0,0,0,0,[ "toggle between poly and spline"]), text('yellow',488,416,2,0,2,1,0,0,1,8,15,2886,0,12,3,0,0,0,0,[ "-"]) ], 2940,0,[ ]), group([ text('yellow',464,432,2,0,2,1,0,0,1,19,15,69,0,12,3,0,0,0,0,[ "^#z"]), text('yellow',496,432,2,0,2,1,0,0,1,189,15,2869,0,12,3,0,0,0,0,[ "change the drawing mode to arcs"]), text('yellow',488,432,2,0,2,1,0,0,1,8,15,2887,0,12,3,0,0,0,0,[ "-"]) ], 2944,0,[ ]) ], 2995,0,[ ]). group([ rcbox('yellow',736,144,992,240,0,1,1,0,16,51,0,0,[ ]), text('yellow',864,144,2,0,4,1,1,0,1,133,22,52,0,18,4,0,0,0,0,[ "Text Style Keys"]), group([ text('yellow',784,176,2,0,2,1,0,0,1,163,15,2996,0,12,3,0,0,0,0,[ "change the text style to bold"]), text('yellow',752,176,2,0,2,1,0,0,1,20,15,41,0,12,3,0,0,0,0,[ "^#b"]), text('yellow',776,176,2,0,2,1,0,0,1,8,15,3009,0,12,3,0,0,0,0,[ "-"]) ], 3016,0,[ ]), group([ text('yellow',752,192,2,0,2,1,0,0,1,20,15,48,0,12,3,0,0,0,0,[ "^#o"]), text('yellow',784,192,2,0,2,1,0,0,1,173,15,3000,0,12,3,0,0,0,0,[ "change the text style to roman"]), text('yellow',776,192,2,0,2,1,0,0,1,8,15,3010,0,12,3,0,0,0,0,[ "-"]) ], 3020,0,[ ]), group([ text('yellow',752,208,2,0,2,1,0,0,1,20,15,58,0,12,3,0,0,0,0,[ "^#p"]), text('yellow',784,208,2,0,2,1,0,0,1,198,15,3003,0,12,3,0,0,0,0,[ "change the text style to bold-italic"]), text('yellow',776,208,2,0,2,1,0,0,1,8,15,3011,0,12,3,0,0,0,0,[ "-"]) ], 3024,0,[ ]), group([ text('yellow',752,224,2,0,2,1,0,0,1,17,15,63,0,12,3,0,0,0,0,[ "^#t"]), text('yellow',784,224,2,0,2,1,0,0,1,166,15,3006,0,12,3,0,0,0,0,[ "change the text style to italic"]), text('yellow',776,224,2,0,2,1,0,0,1,8,15,3012,0,12,3,0,0,0,0,[ "-"]) ], 3028,0,[ ]) ], 3047,0,[ ]). group([ rcbox('yellow',736,256,992,336,0,1,1,0,16,70,0,0,[ ]), text('yellow',864,256,2,0,4,1,1,0,1,189,22,71,0,18,4,0,0,0,0,[ "Text Justification Keys"]), group([ text('yellow',752,320,2,0,2,1,0,0,1,17,15,60,0,12,3,0,0,0,0,[ "^#r"]), text('yellow',784,320,2,0,2,1,0,0,1,158,15,3054,0,12,3,0,0,0,0,[ "change to right justified text"]), text('yellow',776,320,2,0,2,1,0,0,1,8,15,3058,0,12,3,0,0,0,0,[ "-"]) ], 3062,0,[ ]), group([ text('yellow',752,304,2,0,2,1,0,0,1,16,15,46,0,12,3,0,0,0,0,[ "^#l"]), text('yellow',784,304,2,0,2,1,0,0,1,150,15,3051,0,12,3,0,0,0,0,[ "change to left justified text"]), text('yellow',776,304,2,0,2,1,0,0,1,8,15,3057,0,12,3,0,0,0,0,[ "-"]) ], 3066,0,[ ]), group([ text('yellow',752,288,2,0,2,1,0,0,1,20,15,43,0,12,3,0,0,0,0,[ "^#c"]), text('yellow',776,288,2,0,2,1,0,0,1,8,15,2893,0,12,3,0,0,0,0,[ "-"]), text('yellow',784,288,2,0,2,1,0,0,1,169,15,3048,0,12,3,0,0,0,0,[ "change to center justified text"]) ], 3070,0,[ ]) ], 3085,0,[ ]). group([ group([ text('yellow',208,640,2,0,2,2,0,0,1,168,30,1289,0,12,3,0,0,0,0,[ "align the horizontal centers of", "objects"]), text('yellow',176,640,2,0,2,1,0,0,1,14,15,137,0,12,3,0,0,0,0,[ "#="]), text('yellow',200,640,2,0,2,1,0,0,1,8,15,1293,0,12,3,0,0,0,0,[ "-"]) ], 1303,0,[ ]), rcbox('yellow',160,240,416,1072,0,1,1,0,16,104,0,0,[ ]), text('yellow',288,240,2,0,4,1,1,0,1,212,22,109,0,18,4,0,0,0,0,[ "Object Manipulation Keys"]), group([ text('yellow',176,400,2,0,2,1,0,0,1,13,15,126,0,12,3,0,0,0,0,[ "^y"]), text('yellow',208,400,2,0,2,2,0,0,1,194,30,761,0,12,3,0,0,0,0,[ "copy selected objects into the cut", "buffer"]), text('yellow',200,400,2,0,2,1,0,0,1,8,15,764,0,12,3,0,0,0,0,[ "-"]) ], 768,0,[ ]), group([ text('yellow',208,272,2,0,2,1,0,0,1,186,15,949,0,12,3,0,0,0,0,[ "send selected object to the back"]), text('yellow',176,272,2,0,2,1,0,0,1,13,15,120,0,12,3,0,0,0,0,[ "^b"]), text('yellow',200,272,2,0,2,1,0,0,1,8,15,953,0,12,3,0,0,0,0,[ "-"]) ], 957,0,[ ]), group([ text('yellow',208,288,2,0,2,1,0,0,1,149,15,958,0,12,3,0,0,0,0,[ "duplicate selected objects"]), text('yellow',176,288,2,0,2,1,0,0,1,13,15,121,0,12,3,0,0,0,0,[ "^d"]), text('yellow',200,288,2,0,2,1,0,0,1,8,15,962,0,12,3,0,0,0,0,[ "-"]) ], 966,0,[ ]), group([ text('yellow',208,304,2,0,2,1,0,0,1,190,15,967,0,12,3,0,0,0,0,[ "send selected objects to the front"]), text('yellow',176,304,2,0,2,1,0,0,1,9,15,122,0,12,3,0,0,0,0,[ "^f"]), text('yellow',200,304,2,0,2,1,0,0,1,8,15,971,0,12,3,0,0,0,0,[ "-"]) ], 975,0,[ ]), group([ text('yellow',208,352,2,0,2,2,0,0,1,195,30,985,0,12,3,0,0,0,0,[ "align selected objects to the grid", "according to the current alignment"]), text('yellow',176,352,2,0,2,1,0,0,1,10,15,124,0,12,3,0,0,0,0,[ "^t"]), text('yellow',200,352,2,0,2,1,0,0,1,8,15,989,0,12,3,0,0,0,0,[ "-"]) ], 993,0,[ ]), group([ text('yellow',208,384,2,0,2,1,0,0,1,132,15,994,0,12,3,0,0,0,0,[ "delete selected objects"]), text('yellow',176,384,2,0,2,1,0,0,1,12,15,125,0,12,3,0,0,0,0,[ "^x"]), text('yellow',200,384,2,0,2,1,0,0,1,8,15,998,0,12,3,0,0,0,0,[ "-"]) ], 1002,0,[ ]), group([ text('yellow',208,432,2,0,2,2,0,0,1,185,30,1004,0,12,3,0,0,0,0,[ "rotate selected objects counter-", "clockwise"]), text('yellow',176,432,2,0,2,1,0,0,1,14,15,130,0,12,3,0,0,0,0,[ "#c"]), text('yellow',200,432,2,0,2,1,0,0,1,8,15,1008,0,12,3,0,0,0,0,[ "-"]) ], 1021,0,[ ]), group([ text('yellow',208,464,2,0,2,1,0,0,1,182,15,1109,0,12,3,0,0,0,0,[ "flip selected objects horizontally"]), text('yellow',176,464,2,0,2,1,0,0,1,14,15,131,0,12,3,0,0,0,0,[ "#h"]), text('yellow',200,464,2,0,2,1,0,0,1,8,15,1113,0,12,3,0,0,0,0,[ "-"]) ], 1117,0,[ ]), group([ text('yellow',208,528,2,0,2,1,0,0,1,169,15,1120,0,12,3,0,0,0,0,[ "flip selected objects vertically"]), text('yellow',176,528,2,0,2,1,0,0,1,14,15,133,0,12,3,0,0,0,0,[ "#v"]), text('yellow',200,528,2,0,2,1,0,0,1,8,15,1124,0,12,3,0,0,0,0,[ "-"]) ], 1128,0,[ ]), group([ text('yellow',208,544,2,0,2,1,0,0,1,189,15,1134,0,12,3,0,0,0,0,[ "rotate selected objects clockwise"]), text('yellow',176,544,2,0,2,1,0,0,1,16,15,134,0,12,3,0,0,0,0,[ "#w"]), text('yellow',200,544,2,0,2,1,0,0,1,8,15,1138,0,12,3,0,0,0,0,[ "-"]) ], 1142,0,[ ]), group([ text('yellow',208,512,2,0,2,1,0,0,1,28,15,1143,0,12,3,0,0,0,0,[ "undo"]), text('yellow',176,512,2,0,2,1,0,0,1,14,15,132,0,12,3,0,0,0,0,[ "#u"]), text('yellow',200,512,2,0,2,1,0,0,1,8,15,1147,0,12,3,0,0,0,0,[ "-"]) ], 1151,0,[ ]), group([ text('yellow',208,592,2,0,2,2,0,0,1,185,30,1209,0,12,3,0,0,0,0,[ "update the selected objects", "according to the current settings"]), text('yellow',176,592,2,0,2,1,0,0,1,14,15,245,0,12,3,0,0,0,0,[ "#0"]), text('yellow',200,592,2,0,2,1,0,0,1,8,15,1213,0,12,3,0,0,0,0,[ "-"]) ], 1219,0,[ ]), group([ text('yellow',208,576,2,0,2,1,0,0,1,155,15,1220,0,12,3,0,0,0,0,[ "create a user-specified arc"]), text('yellow',176,576,2,0,2,1,0,0,1,14,15,219,0,12,3,0,0,0,0,[ "#9"]), text('yellow',200,576,2,0,2,1,0,0,1,8,15,1224,0,12,3,0,0,0,0,[ "-"]) ], 1228,0,[ ]), group([ text('yellow',208,624,2,0,2,1,0,0,1,162,15,1279,0,12,3,0,0,0,0,[ "align the left sides of objects"]), text('yellow',176,624,2,0,2,1,0,0,1,14,15,136,0,12,3,0,0,0,0,[ "#[ "]), text('yellow',200,624,2,0,2,1,0,0,1,8,15,1283,0,12,3,0,0,0,0,[ "-"]) ], 1311,0,[ ]), group([ text('yellow',208,672,2,0,2,1,0,0,1,170,15,1312,0,12,3,0,0,0,0,[ "align the right sides of objects"]), text('yellow',176,672,2,0,2,1,0,0,1,10,15,139,0,12,3,0,0,0,0,[ "#]"]), text('yellow',200,672,2,0,2,1,0,0,1,8,15,1327,0,12,3,0,0,0,0,[ "-"]) ], 1334,0,[ ]), group([ text('yellow',208,688,2,0,2,1,0,0,1,163,15,1316,0,12,3,0,0,0,0,[ "align the top sides of objects"]), text('yellow',176,688,2,0,2,1,0,0,1,11,15,140,0,12,3,0,0,0,0,[ "#{"]), text('yellow',200,688,2,0,2,1,0,0,1,8,15,1328,0,12,3,0,0,0,0,[ "-"]) ], 1338,0,[ ]), group([ text('yellow',208,704,2,0,2,1,0,0,1,200,15,1320,0,12,3,0,0,0,0,[ "align the vertical centers of objects"]), text('yellow',176,704,2,0,2,1,0,0,1,14,15,141,0,12,3,0,0,0,0,[ "#+"]), text('yellow',200,704,2,0,2,1,0,0,1,8,15,1329,0,12,3,0,0,0,0,[ "-"]) ], 1342,0,[ ]), group([ text('yellow',176,720,2,0,2,1,0,0,1,11,15,143,0,12,3,0,0,0,0,[ "#}"]), text('yellow',208,720,2,0,2,1,0,0,1,183,15,1324,0,12,3,0,0,0,0,[ "align the bottom sides of objects"]), text('yellow',200,720,2,0,2,1,0,0,1,8,15,1330,0,12,3,0,0,0,0,[ "-"]) ], 1346,0,[ ]), group([ text('yellow',208,736,2,0,2,1,0,0,1,201,15,1347,0,12,3,0,0,0,0,[ "make the selected polygons regular"]), text('yellow',176,736,2,0,2,1,0,0,1,12,15,221,0,12,3,0,0,0,0,[ "#"""]), text('yellow',200,736,2,0,2,1,0,0,1,8,15,1351,0,12,3,0,0,0,0,[ "-"]) ], 1355,0,[ ]), group([ text('yellow',208,752,2,0,2,2,0,0,1,136,30,1374,0,12,3,0,0,0,0,[ "cut (magnify) a selected", "bitmap/pixmap object"]), text('yellow',176,752,2,0,2,1,0,0,1,10,15,229,0,12,3,0,0,0,0,[ "#;"]), text('yellow',200,752,2,0,2,1,0,0,1,8,15,1379,0,12,3,0,0,0,0,[ "-"]) ], 1383,0,[ ]), group([ text('yellow',208,800,2,0,2,1,0,0,1,178,15,1388,0,12,3,0,0,0,0,[ "abut selected objects vertically"]), text('yellow',176,800,2,0,2,1,0,0,1,10,15,234,0,12,3,0,0,0,0,[ "#|"]), text('yellow',200,800,2,0,2,1,0,0,1,8,15,1393,0,12,3,0,0,0,0,[ "-"]) ], 1397,0,[ ]), group([ text('yellow',208,784,2,0,2,1,0,0,1,191,15,1384,0,12,3,0,0,0,0,[ "abut selected objects horizontally"]), text('yellow',176,784,2,0,2,1,0,0,1,14,15,230,0,12,3,0,0,0,0,[ "#_"]), text('yellow',200,784,2,0,2,1,0,0,1,8,15,1392,0,12,3,0,0,0,0,[ "-"]) ], 1401,0,[ ]), group([ text('yellow',208,480,2,0,2,2,0,0,1,209,30,1402,0,12,3,0,0,0,0,[ "distribute selected objects according", "to the current alignment"]), text('yellow',176,480,2,0,2,1,0,0,1,10,15,242,0,12,3,0,0,0,0,[ "#l"]), text('yellow',200,480,2,0,2,1,0,0,1,8,15,1406,0,12,3,0,0,0,0,[ "-"]) ], 1410,0,[ ]), group([ text('yellow',208,816,2,0,2,2,0,0,1,196,30,1411,0,12,3,0,0,0,0,[ "break up selected text objects into", "single character objects"]), text('yellow',176,816,2,0,2,1,0,0,1,14,15,235,0,12,3,0,0,0,0,[ "##"]), text('yellow',200,816,2,0,2,1,0,0,1,8,15,1415,0,12,3,0,0,0,0,[ "-"]) ], 1419,0,[ ]), group([ text('yellow',208,896,2,0,2,2,0,0,1,206,30,1445,0,12,3,0,0,0,0,[ "scale selected objects by specifying", "X and Y scaling factors"]), text('yellow',176,896,2,0,2,1,0,0,1,11,15,1446,0,12,3,0,0,0,0,[ "#)"]), text('yellow',200,896,2,0,2,1,0,0,1,8,15,1447,0,12,3,0,0,0,0,[ "-"]) ], 1455,0,[ ]), group([ text('yellow',208,848,2,0,2,2,0,0,1,197,30,1456,0,12,3,0,0,0,0,[ "align selected objects to the paper", "according to the current alignment"]), text('yellow',176,848,2,0,2,1,0,0,1,16,15,248,0,12,3,0,0,0,0,[ "#&"]), text('yellow',200,848,2,0,2,1,0,0,1,8,15,1460,0,12,3,0,0,0,0,[ "-"]) ], 1464,0,[ ]), group([ text('yellow',208,880,2,0,2,1,0,0,1,25,15,1440,0,12,3,0,0,0,0,[ "redo"]), text('yellow',176,880,2,0,2,1,0,0,1,12,15,250,0,12,3,0,0,0,0,[ "#*"]), text('yellow',200,880,2,0,2,1,0,0,1,8,15,1444,0,12,3,0,0,0,0,[ "-"]) ], 1485,0,[ ]), group([ text('yellow',208,928,2,0,2,1,0,0,1,142,15,1465,0,12,3,0,0,0,0,[ "lock the selected objects"]), text('yellow',176,928,2,0,2,1,0,0,1,14,15,332,0,12,3,0,0,0,0,[ "#<"]), text('yellow',200,928,2,0,2,1,0,0,1,8,15,1472,0,12,3,0,0,0,0,[ "-"]) ], 1500,0,[ ]), group([ text('yellow',176,944,2,0,2,1,0,0,1,14,15,333,0,12,3,0,0,0,0,[ "#>"]), text('yellow',208,944,2,0,2,1,0,0,1,160,15,1469,0,12,3,0,0,0,0,[ "unLock the selected objects"]), text('yellow',200,944,2,0,2,1,0,0,1,8,15,1473,0,12,3,0,0,0,0,[ "-"]) ], 1504,0,[ ]), group([ text('yellow',208,960,2,0,2,2,0,0,1,191,30,1505,0,12,3,0,0,0,0,[ "add points to the selected poly or", "spline object"]), text('yellow',176,960,2,0,2,1,0,0,1,20,15,147,0,12,3,0,0,0,0,[ "^#a"]), text('yellow',200,960,2,0,2,1,0,0,1,8,15,1509,0,12,3,0,0,0,0,[ "-"]) ], 1514,0,[ ]), group([ text('yellow',208,992,2,0,2,2,0,0,1,202,30,1515,0,12,3,0,0,0,0,[ "delete points from the selected poly", "or spline object"]), text('yellow',176,992,2,0,2,1,0,0,1,20,15,149,0,12,3,0,0,0,0,[ "^#d"]), text('yellow',200,992,2,0,2,1,0,0,1,8,15,1519,0,12,3,0,0,0,0,[ "-"]) ], 1523,0,[ ]), group([ text('yellow',208,1056,2,0,2,1,0,0,1,137,15,1538,0,12,3,0,0,0,0,[ "paste from the cut buffer"]), text('yellow',176,1056,2,0,2,1,0,0,1,20,15,151,0,12,3,0,0,0,0,[ "^#y"]), text('yellow',200,1056,2,0,2,1,0,0,1,8,15,758,0,12,3,0,0,0,0,[ "-"]) ], 1545,0,[ ]), group([ text('yellow',208,1024,2,0,2,2,0,0,1,196,30,1524,0,12,3,0,0,0,0,[ "reverse-video the selected bitmap", "objects"]), text('yellow',176,1024,2,0,2,1,0,0,1,16,15,150,0,12,3,0,0,0,0,[ "^#f"]), text('yellow',200,1024,2,0,2,1,0,0,1,8,15,1528,0,12,3,0,0,0,0,[ "-"]) ], 1842,0,[ ]), group([ text('yellow',208,320,2,0,2,2,0,0,1,199,30,976,0,12,3,0,0,0,0,[ "align selected objects according to", "the current alignment settings"]), text('yellow',176,320,2,0,2,1,0,0,1,9,15,123,0,12,3,0,0,0,0,[ "^l"]), text('yellow',200,320,2,0,2,1,0,0,1,8,15,980,0,12,3,0,0,0,0,[ "-"]) ], 3239,0,[ ]) ], 3382,0,[ ]). ��tgif-QPL-4.2.5/make.common��������������������������������������������������������������������������0000644�0000764�0000764�00000003127�11602233312�015116� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# # @(#)$Header: /mm2/home/cvs/bc-src/tgif/make.common,v 1.1 2004/06/18 23:20:49 william Exp $ # # This file is shared by Makefile.noimake and descrip.mms. # $(O) and $(XBM) must be defined before this file is included. # OBJ1 = align$(O) animate$(O) arc$(O) attr$(O) auxtext$(O) \ box$(O) button$(O) \ chat$(O) chinput$(O) choice$(O) choose$(O) cli_xcin$(O) convkinput$(O) \ convxim$(O) cmd$(O) color$(O) cursor$(O) cutpaste$(O) \ dialog$(O) drawing$(O) dup$(O) \ edit$(O) eps$(O) exec$(O) expr$(O) \ file$(O) font$(O) ftp$(O) \ grid$(O) group$(O) \ help$(O) http$(O) \ imgproc$(O) import$(O) ini$(O) inmethod$(O) \ list$(O) \ mainloop$(O) mainmenu$(O) mark$(O) markup$(O) menu$(O) \ menuinfo$(O) miniline$(O) move$(O) msg$(O) \ names$(O) navigate$(O) nkf$(O) \ obj$(O) oval$(O) \ page$(O) pattern$(O) pin$(O) poly$(O) polygon$(O) ps$(O) \ raster$(O) rcbox$(O) rect$(O) remote$(O) ruler$(O) \ scroll$(O) select$(O) setup$(O) shape$(O) shortcut$(O) \ special$(O) spline$(O) stk$(O) stream$(O) stretch$(O) \ strtbl$(O) \ tangram2$(O) tdgtbase$(O) tdgtbmpl$(O) tdgtbrow$(O) tdgtbtn$(O) \ tdgtdraw$(O) tdgtlist$(O) tdgtmsg$(O) tdgtsedt$(O) \ tgif_dbg$(O) tgtwb5$(O) tgtwb5dl$(O) tgtwb5xl$(O) \ tidget$(O) tcp$(O) text$(O) \ util$(O) \ version$(O) vms_comp$(O) \ wb$(O) wb1$(O) wb2$(O) wb3$(O) wb_buff$(O) wb_mcast$(O) wb_seg$(O) \ xbitmap$(O) xpixmap$(O) xprtfltr$(O) OBJS = tgif$(O) $(OBJ1) �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tginssym.c���������������������������������������������������������������������������0000644�0000764�0000764�00000012730�11602233313�015011� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tginssym.c,v 1.5 2011/06/02 15:53:08 william Exp $ */ #define _INCLUDE_FROM_TGINSSYM__C_ #include "tgifdefs.h" #include "tidget.h" #include "auxtext.e" #include "dialog.e" #include "font.e" #include "msg.e" #include "setup.e" #include "strtbl.e" #include "tginssym.e" #include "tgisdl.e" #include "tidget.e" #include "util.e" /* --------------------- Init & Clean Up --------------------- */ void TgInsertSymbol_CleanUp(dpy, win) Display *dpy; Window win; { if (gInsertSymbolInfo.initialized) { if (gInsertSymbolInfo.dialogbox_tidgetinfo != NULL) { DestroyTdgtInsertSymbolDialogBox(dpy, gInsertSymbolInfo.dialogbox_tidgetinfo); } } if (gInsertSymbolInfo.sym_pixmap != None) { XFreePixmap(mainDisplay, gInsertSymbolInfo.sym_pixmap); } if (gInsertSymbolInfo.xfs != NULL) { XFreeFont(mainDisplay, gInsertSymbolInfo.xfs); } if (gInsertSymbolInfo.gc != NULL) { XFreeGC(mainDisplay, gInsertSymbolInfo.gc); } memset(&gInsertSymbolInfo, 0, sizeof(InsertSymbolInfo)); CleanUpTdgtInsertSymbolDlg(); } int TgInsertSymbol_Init(dpy, win, arg) Display *dpy; Window win; char *arg; { XGCValues values; memset(&gInsertSymbolInfo, 0, sizeof(InsertSymbolInfo)); gInsertSymbolInfo.xfs = LoadASymbolFont(14); if (gInsertSymbolInfo.xfs == NULL) { TgInsertSymbol_CleanUp(dpy, win); return FALSE; } gInsertSymbolInfo.font_width = gInsertSymbolInfo.xfs->max_bounds.width; gInsertSymbolInfo.font_asc = gInsertSymbolInfo.xfs->max_bounds.ascent; gInsertSymbolInfo.font_des = gInsertSymbolInfo.xfs->max_bounds.descent; gInsertSymbolInfo.font_height = gInsertSymbolInfo.font_asc + gInsertSymbolInfo.font_des; gInsertSymbolInfo.padding = 2; values.foreground = myFgPixel; values.background = myBgPixel; values.fill_style = FillSolid; values.font = gInsertSymbolInfo.xfs->fid; gInsertSymbolInfo.gc = XCreateGC(mainDisplay, mainWindow, GCForeground | GCBackground | GCFillStyle | GCFont, &values); if (gInsertSymbolInfo.gc == NULL) { TgInsertSymbol_CleanUp(dpy, win); return FALSE; } gInsertSymbolInfo.a_symbol_w = gInsertSymbolInfo.font_width + (gInsertSymbolInfo.padding<<1); gInsertSymbolInfo.a_symbol_h = gInsertSymbolInfo.font_height + (gInsertSymbolInfo.padding<<1); gInsertSymbolInfo.pixmap_w = TGIS_COLS*(gInsertSymbolInfo.a_symbol_w+1) + 1; gInsertSymbolInfo.pixmap_h = TGIS_ROWS*(gInsertSymbolInfo.a_symbol_h+1) + 1; gInsertSymbolInfo.sym_pixmap = XCreatePixmap(mainDisplay, rootWindow, gInsertSymbolInfo.pixmap_w, gInsertSymbolInfo.pixmap_h, mainDepth); if (gInsertSymbolInfo.sym_pixmap == None) { FailAllocPixmapMessage(gInsertSymbolInfo.pixmap_w, gInsertSymbolInfo.pixmap_h); TgInsertSymbol_CleanUp(dpy, win); return FALSE; } if (!InitTdgtInsertSymbolDlg()) { TgInsertSymbol_CleanUp(dpy, win); return FALSE; } return TRUE; } void CleanUpInsertSymbol() { TgInsertSymbol_CleanUp(mainDisplay, drawWindow); } int InitInsertSymbol() { return TgInsertSymbol_Init(mainDisplay, drawWindow, NULL); } /* --------------------- TgInsertSymbol_SendKey --------------------- */ static XComposeStatus c_stat; int TgInsertSymbol_SendKey(dpy, win, key_ev, buf) Display *dpy; Window win; XKeyEvent *key_ev; char *buf; /* return FALSE means key_ev will be handled without modifications */ { int has_ch=0; char s[80]; KeySym key_sym=(KeySym)0; has_ch = XLookupString(key_ev, s, sizeof(s), &key_sym, &c_stat); TranslateKeys(s, &key_sym); return FALSE; } /* --------------------- TgInsertSymbol_HandleCntrlSpace --------------------- */ int TgInsertSymbol_HandleCntrlSpace(dpy, win) Display *dpy; Window win; { if (!gInsertSymbolInfo.initialized) { gInsertSymbolInfo.initialized = TRUE; /* create window */ gInsertSymbolInfo.dialogbox_tidgetinfo = CreateTdgtInsertSymbolDialogBox(dpy, rootWindow); if (gInsertSymbolInfo.dialogbox_tidgetinfo == NULL) { /* print a message */ } } if (gInsertSymbolInfo.dialogbox_tidgetinfo == NULL) { return FALSE; } if (!gInsertSymbolInfo.mapped) { ShowTdgtInsertSymbolDialogBox(); TdgtInsertSymbolDlgLoop(gInsertSymbolInfo.dialogbox_tidgetinfo); } else { HideTdgtInsertSymbolDialogBox(); } return FALSE; } /* --------------------- TgInsertSymbol_HandleCreateText --------------------- */ int TgInsertSymbol_HandleCreateText(dpy, win) Display *dpy; Window win; { if (gInsertSymbolInfo.initialized && gInsertSymbolInfo.mapped) { HideTdgtInsertSymbolDialogBox(); } return TRUE; } ����������������������������������������tgif-QPL-4.2.5/eq4-lyx-ps2epsi.sym������������������������������������������������������������������0000644�0000764�0000764�00000067333�11602233311�016417� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.43 state(0,37,100.000,0,0,0,8,1,3,1,1,0,0,1,0,1,0,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/eq4-lyx-ps2epsi.sym,v 1.1 2004/06/18 23:20:01 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(13,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "CadetBlue", 24415, 40606, 41120, 24415, 40606, 41120, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1 ]). slideshow_info('',-20,-20). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). dont_reencode("UtopiaFS:FFDingbests:ZapfDingbats"). ps_font_aliases([ "UtopiaFS-Regular=Utopia-Regular", "UtopiaFS-Bold=Utopia-Bold", "UtopiaFS-Italic=Utopia-Italic", "UtopiaFS-BoldItalic=Utopia-BoldItalic" ]). page(1,"LyX equation symbol (uses ghostscript's ps2epsi).",1,''). sym([ polygon('CadetBlue','',5,[ 64,144,131,144,131,128,64,128,64,144],0,1,0,0,3029,0,0,0,0,0,'1',0, "00",[ ]), xbm('#0000ff','',64,144,181,170,0,3028,0,117,26,0,0,1,247000,616000,364000,642000,0,0,1,0,0,0,0, "Wed Oct 9 21:19:46 2002","/tmp/Tgif9AI2Rh.eps",127,[ "%!PS-Adobe-2.0 EPSF-1.2", "save countdictstack mark newpath /showpage {} def /setpagedevice {pop} def", "%DVIPSWebPage: (www.radicaleye.com)", "%DVIPSCommandLine: dvips -t letter -o Tgif9AI2Rh.ps Tgif9AI2Rh.dvi", "%DVIPSParameters: dpi=600, compressed", "%DVIPSSource: TeX output 2002.10.09:2119", "%!", "/TeXDict 300 dict def TeXDict begin/N{def}def/B{bind def}N/S{exch}N/X{S", "N}B/A{dup}B/TR{translate}N/isls false N/vsize 11 72 mul N/hsize 8.5 72", "mul N/landplus90{false}def/@rigin{isls{[0 landplus90{1 -1}{-1 1}ifelse 0", "0 0]concat}if 72 Resolution div 72 VResolution div neg scale isls{", "landplus90{VResolution 72 div vsize mul 0 exch}{Resolution -72 div hsize", "mul 0}ifelse TR}if Resolution VResolution vsize -72 div 1 add mul TR[", "matrix currentmatrix{A A round sub abs 0.00001 lt{round}if}forall round", "exch round exch]setmatrix}N/@landscape{/isls true N}B/@manualfeed{", "statusdict/manualfeed true put}B/@copies{/#copies X}B/FMat[1 0 0 -1 0 0]", "N/FBB[0 0 0 0]N/nn 0 N/IEn 0 N/ctr 0 N/df-tail{/nn 8 dict N nn begin", "/FontType 3 N/FontMatrix fntrx N/FontBBox FBB N string/base X array", "/BitMaps X/BuildChar{CharBuilder}N/Encoding IEn N end A{/foo setfont}2", "array copy cvx N load 0 nn put/ctr 0 N[}B/sf 0 N/df{/sf 1 N/fntrx FMat N", "df-tail}B/dfs{div/sf X/fntrx[sf 0 0 sf neg 0 0]N df-tail}B/E{pop nn A", "definefont setfont}B/Cw{Cd A length 5 sub get}B/Ch{Cd A length 4 sub get", "}B/Cx{128 Cd A length 3 sub get sub}B/Cy{Cd A length 2 sub get 127 sub}", "B/Cdx{Cd A length 1 sub get}B/Ci{Cd A type/stringtype ne{ctr get/ctr ctr", "1 add N}if}B/id 0 N/rw 0 N/rc 0 N/gp 0 N/cp 0 N/G 0 N/CharBuilder{save 3", "1 roll S A/base get 2 index get S/BitMaps get S get/Cd X pop/ctr 0 N Cdx", "0 Cx Cy Ch sub Cx Cw add Cy setcachedevice Cw Ch true[1 0 0 -1 -.1 Cx", "sub Cy .1 sub]/id Ci N/rw Cw 7 add 8 idiv string N/rc 0 N/gp 0 N/cp 0 N{", "rc 0 ne{rc 1 sub/rc X rw}{G}ifelse}imagemask restore}B/G{{id gp get/gp", "gp 1 add N A 18 mod S 18 idiv pl S get exec}loop}B/adv{cp add/cp X}B", "/chg{rw cp id gp 4 index getinterval putinterval A gp add/gp X adv}B/nd{", "/cp 0 N rw exit}B/lsh{rw cp 2 copy get A 0 eq{pop 1}{A 255 eq{pop 254}{", "A A add 255 and S 1 and or}ifelse}ifelse put 1 adv}B/rsh{rw cp 2 copy", "get A 0 eq{pop 128}{A 255 eq{pop 127}{A 2 idiv S 128 and or}ifelse}", "ifelse put 1 adv}B/clr{rw cp 2 index string putinterval adv}B/set{rw cp", "fillstr 0 4 index getinterval putinterval adv}B/fillstr 18 string 0 1 17", "{2 copy 255 put pop}for N/pl[{adv 1 chg}{adv 1 chg nd}{1 add chg}{1 add", "chg nd}{adv lsh}{adv lsh nd}{adv rsh}{adv rsh nd}{1 add adv}{/rc X nd}{", "1 add set}{1 add clr}{adv 2 chg}{adv 2 chg nd}{pop nd}]A{bind pop}", "forall N/D{/cc X A type/stringtype ne{]}if nn/base get cc ctr put nn", "/BitMaps get S ctr S sf 1 ne{A A length 1 sub A 2 index S get sf div put", "}if put/ctr ctr 1 add N}B/I{cc 1 add D}B/bop{userdict/bop-hook known{", "bop-hook}if/SI save N @rigin 0 0 moveto/V matrix currentmatrix A 1 get A", "mul exch 0 get A mul add .99 lt{/QV}{/RV}ifelse load def pop pop}N/eop{", "SI restore userdict/eop-hook known{eop-hook}if showpage}N/@start{", "userdict/start-hook known{start-hook}if pop/VResolution X/Resolution X", "1000 div/DVImag X/IEn 256 array N 2 string 0 1 255{IEn S A 360 add 36 4", "index cvrs cvn put}for pop 65781.76 div/vsize X 65781.76 div/hsize X}N", "/p{show}N/RMat[1 0 0 -1 0 0]N/BDot 260 string N/Rx 0 N/Ry 0 N/V{}B/RV/v{", "/Ry X/Rx X V}B statusdict begin/product where{pop false[(Display)(NeXT)", "(LaserWriter 16/600)]{A length product length le{A length product exch 0", "exch getinterval eq{pop true exit}if}{pop}ifelse}forall}{false}ifelse", "end{{gsave TR -.1 .1 TR 1 1 scale Rx Ry false RMat{BDot}imagemask", "grestore}}{{gsave TR -.1 .1 TR Rx Ry scale 1 1 false RMat{BDot}", "imagemask grestore}}ifelse B/QV{gsave newpath transform round exch round", "exch itransform moveto Rx 0 rlineto 0 Ry neg rlineto Rx neg 0 rlineto", "fill grestore}B/a{moveto}B/delta 0 N/tail{A/delta X 0 rmoveto}B/M{S p", "delta add tail}B/b{S p tail}B/c{-4 M}B/d{-3 M}B/e{-2 M}B/f{-1 M}B/g{0 M}", "B/h{1 M}B/i{2 M}B/j{3 M}B/k{4 M}B/w{0 rmoveto}B/l{p -4 w}B/m{p -3 w}B/n{", "p -2 w}B/o{p -1 w}B/q{p 1 w}B/r{p 2 w}B/s{p 3 w}B/t{p 4 w}B/x{0 S", "rmoveto}B/y{3 2 roll p a}B/bos{/SS save N}B/eos{SS restore}B end", "", "TeXDict begin 40258431 52099146 1000 600 600 (Tgif9AI2Rh.dvi)", "@start", "%DVIPSBitmapFont: Fa cmr17 20.74 1", "/Fa 1 51 df<ED7FF00207B57E023F14F091B612FC4915FF902707FE007F13C0D90FE001", "0F7FD91F80010113F849C87F017CED3FFE496F7E48486F138048486F13C04848817113E0", "484817F090CAFC48EF7FF8121E003EEF3FFC123CA2007CEF1FFE1278A2EA7FC0D8FFF0EE", "0FFF7F7F7FA76C5A6C5A6C5AD807C0EE1FFECBFCA3F03FFCA3F07FF8A219F018FF19E05F", "19C04D1380A24D130060170F4D5A604D5A4D5A604D5A4C90C7FC4C5A4C5A5F4C5A4C5A4C", "5A4C5A94C8FC16FE4B5A4B5A4B5A4B5A4B5A4B5A4BC9FC157E5D4A5A4A5A4A5A4A5A4A48", "15074AC9FC143E4A160E5C495A495A495A495A49CA121E011E171C5B5B49173C485A4848", "177C4848EE01FC48B912F8A25A5A5ABAFCA219F0A3407279F14F>50", "D E", "%EndDVIPSBitmapFont", "%DVIPSBitmapFont: Fb cmr17 24.88 1", "/Fb 1 62 df<003FC112FC4820FEC3FCA46C20FE6C20FCD5FCB3AC003FC112FC4820FEC3", "FCA46C20FE6C20FC802E76CA95>61 D E", "%EndDVIPSBitmapFont", "%DVIPSBitmapFont: Fc cmmi12 24.88 3", "/Fc 3 78 df[<99263FFFC0160E090FB500FE160F98B700C0151F080704F0153F083F04", "FC157E4FB915FE07079126FC003F6D1301073F91C7000113E096B500F86E6C6CEB03FC06", "0302C0DB0FF81307060F49C96C6C130F4E01F8DC01FE131F067F01C0706CEB3FF84DB5CB", "EA7F804D01FC063F137F050F4995381FC0FF4D01E0DE0FE113F04D49F007F394B5CCEA03", "F74C4997B5FC4C01F87314E0040F5B4C49854C5B4C90CE6C13C04C5A4B49874B5B4B491D", "804B49875D4B5B4B4975130092B5CFFC4A5B5E4A674A5B4A491C075C4C654A5B5C91B55A", "6A4991D0FC5D5B494966A2495BA2494966491F0FA2495B6A4B1D0790B59BC8FC5D5AA248", "91D4FCA3485BA3485BA35A5CA35A5CA35A5CA55CA2B5FCA65C200F68A368203E7E207E20", "7CA220FC686E1C016C671F03681F076C676E1C0F555A6C9CC9FC676E1C7E6C1E7C1FFC6C", "6D515A545A6C6D515A1E0F6C6D64545A6D6C51CAFC6D1C7E6F4F5A6D6D4F5A6D6D4F5A6D", "515A6D6DF13FC06D6D4F5A6D01FE07FECBFC6E6CF003FC6E6DEF0FF86E01E0EF3FF06E6D", "EFFFC06E01FC04035B020101FFDC0FFECCFC6E02E0ED7FF8033F01FC913807FFE06FD9FF", "E090B51280030791B648CDFC030117F8DB003F16C004074BCEFCDC007F14F0050301FCCF", "FC>144 149 118 272 145 67 D[<041FC012804C1FC0A4701F80DC00014ACA120FDD00", "1F49EF001F501803501800223F8E50857C13004E87A25085A2608E5062A295B5FCA297CE", "127EA25FA24F1B7CA25FA24F1BFCA25F6B61A25FA2610C0F15014D4E7E6B4F94C8FC2200", "4D4E93C7FCA24F163E1E7E5FA24F5EA294B51601A296C9485AA24C18071D0F4E4C5A1D3F", "4C18FF1C034E037F5B95B9FC5EA266A25E06F8C8FC4E03075B884C83884E94CCFC895EA2", "4E167EA25EA24E167C1DFC93B5FCA295CA481678227C4B060117FCA24D4D4B5AA24B7248", "4B5A9AC9FC4D6421075D575A5F575A5D213F4D99C8FCA24B1D7E21FE5F565A5D565A5F56", "5A5D200F4D505AA292B5515A207F94CE12FF555B5C5590C9FC4C62555A4A1C3F1F7F4C4F", "485A4A630C0F5B4A1B7F0B03B5FC023F083F5C0103B5061FB6FC007FC05AC1FCA268A26C", "67>146 141 118 268 150 69 D[<041FB600FC0B1FB612FC4C6F5315FEA15CA2A191B7", "FC705616FCDC00016EF88000DD001F5402F8C7FC07BFE307DF5BA15EA149485BA2073FE3", "1F3F5BA1133E4E6C6D64A1137C063E0CF891C8FCA2067E5348B5FCA2067C53485BA1485A", "DEFC0F6D1BC1A1EA0F8106F8E31F015BA20501F63E03A206F00B7C5CA112F805036D6D63", "FB01F006E0E203E05CA2050753485AA206C0E20F805CFB1F00050F6D6D63233E0680525D", "A2051F535BA2060051485D585A4D6D6D63585A053E524892C9FCA2057E52C7B5FCA2057C", "0A3E5D6A05FC6D6D626A4D51485DA2040152485BA24D51485D575A04036F6C6257C7FC4D", "093E5EA20407525CA24D515E565A040F6F6C62565A4D50485EA2041F51485C56C8FC94C8", "66746D153E4C6768043E5194CAFCA2047E504892B5FC555A047C68746D4A5A04FC66555A", "4C50C85CA20301093E5D674C68746D5C030367545A4C4F485FA2030750485D545A4C6874", "6D49C9FC030F671E3E4C4F60A2031F505E535A93C965746D485A4B67535A033E4F4895CB", "FCA2037E4FCAB5FC1D3E037C68746D5A03FC66654BDEFDF060A20201DFFFE05E654B6802", "03725B0207679ACAFC4A6C4E61021F67023F614A6C4E5F49487E01076D6C7048057F7F01", "7F02F00A07B6FC007FB700F04C92B912F8B84D5CA26499C8FC6C4C031E6F60>199", "141 118 268 196 77 D E", "%EndDVIPSBitmapFont", "end", "TeXDict begin", "letter", "", "1 0 bop 1453 855 a Fc(E)103 b Fb(=)92 b Fc(M)55 b(C)2358", "770 y Fa(2)p eop", "end", "userdict /end-hook known{end-hook}if", "cleartomark countdictstack exch sub { end } repeat restore"], "0000000000000000000000000001e00000000000000000000000000006700000 0000000000000000000000043800000000000000000000000000061800000000 0000000000000000000618000000000000000000000000000018000000000000 0000000000000000300000000000000000000000001e10300fffc00000000000 f801f000ffb0600381c000000000003803c001c0e0c00300c000000000003803 c00380e1800700c00000000000780780070063080700c000000000007c05800e 00661807088000000000005c0b801c0047f006180000000000004c1b801c0040 0006380000000000004c1300180000000ff00001fffe0000cc3300380000000e 100000000000008c6700380000000c110000000000008c4700380000000c3100 00000000008cc600380080001c010001fffe00018e8600380180001c030001ff fe00010f0e00380100001806000000000001070e0018020000380e0000000000 03060c000c0c0000fffc00000000000fc67f000fb80000000000000000000000 000003e00000",[ ]) ], 3027,0,0,[ attr("", "not_rigid", 0, 1, 1, text('blue',64,152,1,0,1,81,16,3037,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,165,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "not_rigid")]) ]) ])])), attr("eq=", "#LyX 1.2 created this file. For more info see http://www.lyx.org/", 0, 1, 1, text('blue',64,48,46,0,1,612,736,3036,13,3,0,0,0,0,2,612,736,0,0,"",0,0,0,0,61,'',[ minilines(612,736,0,0,0,0,0,[ mini_line(612,13,3,0,0,0,[ str_block(0,612,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,612,13,3,0,-2,0,0,0,0,0, "eq=#LyX 1.2 created this file. For more info see http://www.lyx.org/")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,126,13,3,0,-2,0,0,0,0,0, "\\lyxformat 220")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,162,13,3,0,-1,0,0,0,0,0, "\\textclass article")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,153,13,3,0,-1,0,0,0,0,0, "\\language english")]) ]), mini_line(171,13,3,0,0,0,[ str_block(0,171,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,171,13,3,0,-1,0,0,0,0,0, "\\inputencoding auto")]) ]), mini_line(171,13,3,0,0,0,[ str_block(0,171,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,171,13,3,0,-2,0,0,0,0,0, "\\fontscheme default")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,153,13,3,0,-2,0,0,0,0,0, "\\graphics default")]) ]), mini_line(198,13,3,0,0,0,[ str_block(0,198,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,198,13,3,0,-2,0,0,0,0,0, "\\paperfontsize default")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-8,0,0,0,[ str_seg('blue','Courier',0,80640,144,13,3,0,-8,0,0,0,0,0, "\\spacing single ")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,162,13,3,0,-2,0,0,0,0,0, "\\papersize Default")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,144,13,3,0,-2,0,0,0,0,0, "\\paperpackage a4")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,135,13,3,0,-2,0,0,0,0,0, "\\use_geometry 0")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,126,13,3,0,-2,0,0,0,0,0, "\\use_amsmath 0")]) ]), mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,117,13,3,0,-2,0,0,0,0,0, "\\use_natbib 0")]) ]), mini_line(234,13,3,0,0,0,[ str_block(0,234,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,234,13,3,0,-2,0,0,0,0,0, "\\use_numerical_citations 0")]) ]), mini_line(234,13,3,0,0,0,[ str_block(0,234,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,234,13,3,0,-2,0,0,0,0,0, "\\paperorientation portrait")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,126,13,3,0,-2,0,0,0,0,0, "\\secnumdepth 3")]) ]), mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,99,13,3,0,-2,0,0,0,0,0, "\\tocdepth 3")]) ]), mini_line(252,13,3,0,0,0,[ str_block(0,252,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,252,13,3,0,-2,0,0,0,0,0, "\\paragraph_separation indent")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "\\defskip medskip")]) ]), mini_line(216,13,3,0,0,0,[ str_block(0,216,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,216,13,3,0,-1,0,0,0,0,0, "\\quotes_language english")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,135,13,3,0,-2,0,0,0,0,0, "\\quotes_times 2")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,135,13,3,0,-3,0,0,0,0,0, "\\papercolumns 1")]) ]), mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,117,13,3,0,-3,0,0,0,0,0, "\\papersides 1")]) ]), mini_line(189,13,3,0,0,0,[ str_block(0,189,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,189,13,3,0,-1,0,0,0,0,0, "\\paperpagestyle empty")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "\\layout Standard")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "\\begin_inset ERT")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "status Collapsed")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "\\layout Standard")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]), mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-8,0,0,0,[ str_seg('blue','Courier',0,80640,99,13,3,0,-8,0,0,0,0,0, "\\backslash ")]) ]), mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-8,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-8,0,0,0,0,0, "Huge ")]) ]), mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-8,0,0,0,[ str_seg('blue','Courier',0,80640,99,13,3,0,-8,0,0,0,0,0, "\\end_inset ")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]), mini_line(207,13,3,0,0,0,[ str_block(0,207,13,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,207,13,3,0,-3,0,0,0,0,0, "\\begin_inset Formula \\[")]) ]), mini_line(171,13,3,0,0,0,[ str_block(0,171,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,171,13,3,0,-4,0,0,0,0,0, "E\\, =\\, M\\, C^{2}\\]")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]), mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-8,0,0,0,[ str_seg('blue','Courier',0,80640,99,13,3,0,-8,0,0,0,0,0, "\\end_inset ")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]), mini_line(0,13,3,0,0,0,[ str_block(0,0,13,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,0,13,3,0,0,0,0,0,0,0, "")]) ]), mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "\\the_end")]) ]) ])])), attr("file_name=", "/tmp/Tgif9AI2Rh", 0, 1, 1, text('blue',64,32,1,0,1,225,16,3035,13,3,0,0,0,0,2,225,16,0,0,"",0,0,0,0,45,'',[ minilines(225,16,0,0,0,0,0,[ mini_line(225,13,3,0,0,0,[ str_block(0,225,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,225,13,3,0,-1,0,0,0,0,0, "file_name=/tmp/Tgif9AI2Rh")]) ]) ])])), attr("cleanup=", "", 0, 1, 1, text('blue',64,-72,3,0,1,540,48,3034,13,3,0,0,0,0,2,540,48,0,0,"",0,0,0,0,-59,'',[ minilines(540,48,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "cleanup=")]) ]), mini_line(540,13,3,0,0,0,[ str_block(0,540,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,540,13,3,0,-2,0,0,0,0,0, " rm -f $(file_name).tex $(file_name).aux $(file_name).dvi")]) ]), mini_line(513,13,3,0,0,0,[ str_block(0,513,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,513,13,3,0,-2,0,0,0,0,0, " $(file_name).log $(file_name).ps $(file_name).eps")]) ]) ])])), attr("cmd=", "", 0, 1, 1, text('blue',64,-152,5,0,1,648,80,3033,13,3,0,0,0,0,2,648,80,0,0,"",0,0,0,0,-139,'',[ minilines(648,80,0,0,0,0,0,[ mini_line(36,13,3,0,0,0,[ str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, "cmd=")]) ]), mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-4,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(477,13,3,0,0,0,[ str_block(0,477,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,477,13,3,0,-4,0,0,0,0,0, " xterm -geom 40x8+200+400 -e lyx $(file_name).tex;")]) ]), mini_line(585,13,3,0,0,0,[ str_block(0,585,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,585,13,3,0,-4,0,0,0,0,0, " xterm -geom 40x8+200+400 -e lyx $(file_name).tex --export ps;")]) ]), mini_line(648,13,3,0,0,0,[ str_block(0,648,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,648,13,3,0,-2,0,0,0,0,0, " xterm -geom 40x8+200+400 -e ps2epsi $(file_name).ps $(file_name).eps")]) ]) ])])), attr("exec=", "", 0, 1, 1, text('blue',64,-272,9,0,1,477,144,3032,13,3,0,0,0,0,2,477,144,0,0,"",0,0,0,0,-259,'',[ minilines(477,144,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "exec=")]) ]), mini_line(378,13,3,0,0,0,[ str_block(0,378,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,378,13,3,0,-4,0,0,0,0,0, " mktemp(\"/tmp/TgifXXXXXX\",\"file_name\");")]) ]), mini_line(468,13,3,0,0,0,[ str_block(0,468,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,468,13,3,0,-4,0,0,0,0,0, " write_attr_into_file(header,\"$(file_name).tex\");")]) ]), mini_line(441,13,3,0,0,0,[ str_block(0,441,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,441,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(eq,\"$(file_name).tex\");")]) ]), mini_line(477,13,3,0,0,0,[ str_block(0,477,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,477,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(footer,\"$(file_name).tex\");")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,162,13,3,0,-4,0,0,0,0,0, " launch(\"cmd\");")]) ]), mini_line(423,13,3,0,0,0,[ str_block(0,423,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,423,13,3,0,-4,0,0,0,0,0, " read_file_into_attr(\"$(file_name).tex\",eq);")]) ]), mini_line(369,13,3,0,0,0,[ str_block(0,369,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,369,13,3,0,-4,0,0,0,0,0, " update_eps_child(\"$(file_name).eps\");")]) ]), mini_line(189,13,3,0,0,0,[ str_block(0,189,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,189,13,3,0,-4,0,0,0,0,0, " launch(\"cleanup\")")]) ]) ])])), attr("header=", "", 0, 1, 1, text('#0000ff',247,-21,1,0,1,63,16,3031,13,3,0,0,0,0,2,63,16,0,0,"",0,0,0,0,-8,'',[ minilines(63,16,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "header=")]) ]) ])])), attr("footer=", "", 0, 1, 1, text('#0000ff',64,-21,1,0,1,63,16,3030,13,3,0,0,0,0,2,63,16,0,0,"",0,0,0,0,-8,'',[ minilines(63,16,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "footer=")]) ]) ])])) ]). group([ group([ text('#0000ff',224,50,1,0,1,406,17,643,14,3,0,-1,0,0,2,406,17,0,0,"",0,0,0,0,64,'',[ minilines(406,17,0,0,0,-1,0,[ mini_line(406,14,3,0,0,0,[ str_block(0,406,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,406,14,3,0,-1,0,0,0,0,0, "You can use LyX to edit your equation and still see it in tgif.")]) ]) ])]), text('#0000ff',192,50,1,0,1,19,17,863,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,64,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(1)")]) ]) ])]) ], 3109,0,0,[ ]), group([ text('#0000ff',192,74,1,0,1,19,17,656,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,88,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(2)")]) ]) ])]), text('#0000ff',224,74,4,0,1,414,65,657,14,3,0,-1,0,0,2,414,65,0,3,"",0,0,0,0,88,'',[ minilines(414,65,0,3,0,-1,0,[ mini_line(414,14,3,0,0,0,[ str_block(0,414,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,414,14,3,0,-2,0,0,0,0,0, "Now, when you double click the equation object below it will ")]) ]), mini_line(400,14,3,0,3,0,[ str_block(0,400,14,3,0,3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,400,14,3,0,3,0,0,0,0,0, "start LyX for editing. Edit the equation, save the file in LyX")]) ]), mini_line(407,14,3,0,1,0,[ str_block(0,407,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,407,14,3,0,1,0,0,0,0,0, "to keep your modifications, then close LyX and the equation")]) ]), mini_line(133,14,3,0,0,0,[ str_block(0,133,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,133,14,3,0,-1,0,0,0,0,0, "should be updated.")]) ]) ])]) ], 3112,0,0,[ ]), group([ text('#0000ff',224,146,3,0,1,408,49,1039,14,3,0,-1,0,0,2,408,49,0,2,"",0,0,0,0,160,'',[ minilines(408,49,0,2,0,-1,0,[ mini_line(408,14,3,0,2,0,[ str_block(0,408,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,408,14,3,0,2,0,0,0,0,0, "This was accomplished by changing the header, footer, and")]) ]), mini_line(389,14,3,0,2,0,[ str_block(0,389,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,389,14,3,0,2,0,0,0,0,0, "cmd attributes in this special equation object. Note that")]) ]), mini_line(403,14,3,0,0,0,[ str_block(0,403,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,403,14,3,0,-1,0,0,0,0,0, "you do not have to update your .Xdefaults for this to work...")]) ]) ])]), text('#0000ff',192,146,1,0,1,19,17,651,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,160,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(3)")]) ]) ])]) ], 3115,0,0,[ ]), group([ text('#0000ff',192,202,1,0,1,19,17,3154,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,216,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(4)")]) ]) ])]), group([ group([ text('#0000ff',288,234,2,0,1,339,33,3262,14,3,0,-1,0,0,2,339,33,0,1,"",0,0,0,0,248,'',[ minilines(339,33,0,1,0,-1,0,[ mini_line(339,14,3,0,1,0,[ str_block(0,339,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,339,14,3,0,1,0,0,0,0,0, "Remove any new changes in the LyX file and save")]) ]), mini_line(191,14,3,0,0,0,[ str_block(0,191,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,191,14,3,0,-1,0,0,0,0,0, "using the older LyX version.")]) ]) ])]), text('#0000ff',256,234,1,0,1,19,17,3263,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,248,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(a)")]) ]) ])]) ], 3261,0,0,[ ]), group([ text('#0000ff',288,282,5,0,1,336,81,3265,14,3,0,-1,0,0,2,336,81,0,2,"",0,0,0,0,296,'',[ minilines(336,81,0,2,0,-1,0,[ mini_line(304,14,3,0,2,0,[ str_block(0,304,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,304,14,3,0,2,0,0,0,0,0, "In tgif right click on the equation, select Edit")]) ]), mini_line(283,14,3,0,1,0,[ str_block(0,283,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,283,14,3,0,1,0,0,0,0,0, "attribute, select eq=, and replace the eq=")]) ]), mini_line(336,14,3,0,0,0,[ str_block(0,336,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,336,14,3,0,-1,0,0,0,0,0, "information with the contents of a simple LyX file.")]) ]), mini_line(300,14,3,0,1,0,[ str_block(0,300,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,300,14,3,0,1,0,0,0,0,0, "Make sure the LyX file has was created with")]) ]), mini_line(120,14,3,0,0,0,[ str_block(0,120,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,120,14,3,0,-1,0,0,0,0,0, "pagestyle=empty.")]) ]) ])]), text('#0000ff',256,282,1,0,1,20,17,3266,14,3,0,0,0,0,2,20,17,0,0,"",0,0,0,0,296,'',[ minilines(20,17,0,0,0,0,0,[ mini_line(20,14,3,0,0,0,[ str_block(0,20,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,20,14,3,0,0,0,0,0,0,0, "(b)")]) ]) ])]) ], 3264,0,0,[ ]), text('#0000ff',224,202,2,0,1,371,33,3153,14,3,0,-1,0,0,2,371,33,0,1,"",0,0,0,0,216,'',[ minilines(371,33,0,1,0,-1,0,[ mini_line(371,14,3,0,1,0,[ str_block(0,371,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,371,14,3,0,1,0,0,0,0,0, "Older versions of LyX (< 1.2) may give a warning when")]) ]), mini_line(215,14,3,0,1,0,[ str_block(0,215,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,215,14,3,0,1,0,0,0,0,0, "editing this equation. You can:")]) ]) ])]), text('#0000ff',224,266,1,0,1,19,17,3181,14,3,0,0,0,0,2,19,17,0,1,"",0,0,0,0,280,'',[ minilines(19,17,0,1,0,0,0,[ mini_line(19,14,3,0,1,0,[ str_block(0,19,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,1,0,0,0,0,0, "or:")]) ]) ])]) ], 3296,0,0,[ ]) ], 3307,0,0,[ ]) ], 3328,0,0,[ ]). �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/page.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000010234�11602233312�014046� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/page.e,v 1.8 2011/05/16 16:21:58 william Exp $ */ #ifndef _PAGE_E_ #define _PAGE_E_ extern struct PageRec * firstPage, * lastPage, * curPage; extern int curPageNum, lastPageNum; extern int paperRow, paperCol; extern int pageLayoutMode; extern int pageLineShownInTileMode; #ifdef _INCLUDE_FROM_PAGE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_PAGE_C_*/ extern void RedrawPageWindow ARGS_DECL((void)); extern void MakeCurPageTabVisible ARGS_DECL((void)); extern void GotoPageNum ARGS_DECL((int)); extern void SetCurPage ARGS_DECL((int)); extern void RedrawPageDummyWindow ARGS_DECL((void)); extern void PageDummyEventHandler ARGS_DECL((XEvent*)); extern void InitPage ARGS_DECL((void)); extern void NextPage ARGS_DECL((void)); extern void PrevPage ARGS_DECL((void)); extern void GotoPage ARGS_DECL((char*)); extern void NamePages ARGS_DECL((void)); extern void EditPageFileNames ARGS_DECL((void)); extern int OkToFlushUndoBuffer ARGS_DECL((char *msg_prefix)); extern void AddPageBefore ARGS_DECL((void)); extern void AddPageAfter ARGS_DECL((void)); extern void AddPageBeforeCopyAll ARGS_DECL((void)); extern void AddPageAfterCopyAll ARGS_DECL((void)); extern void DeleteCurPage ARGS_DECL((void)); extern void TogglePageLineShown ARGS_DECL((void)); extern void SpecifyDrawingSize ARGS_DECL((void)); extern void PrintOnePage ARGS_DECL((void)); extern int GetDimension ARGS_DECL((char*, int, int*)); extern int GetDimensionInDouble ARGS_DECL((char*, int, double*)); extern int SetPaperSize ARGS_DECL((char *)); extern void SpecifyPaperSize ARGS_DECL((void)); extern void FreePageSpec ARGS_DECL((SpecifyPagesInfo*)); extern int ParsePagesSpec ARGS_DECL((char*, SpecifyPagesInfo*)); extern void DeletePages ARGS_DECL((void)); extern void SavePagesAs ARGS_DECL((void)); extern void PrintPages ARGS_DECL((void)); extern void PrintOneFilePerPage ARGS_DECL((void)); extern int StackedPageMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int TiledPageMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int RefreshPageMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreatePageMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int PageMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void DelAllPages ARGS_DECL((void)); extern void PageLayoutSubMenu ARGS_DECL((int Index)); extern void RefreshPageLayoutMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreatePageLayoutMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int PageLayoutMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void PageEventHandler ARGS_DECL((XEvent*)); extern void CleanUpPage ARGS_DECL((void)); extern void PushPageInfo ARGS_DECL((void)); extern void PopPageInfo ARGS_DECL((void)); extern void GetPageInfo ARGS_DECL((PageInfo*)); extern int FixPageNumInMiniLines ARGS_DECL((MiniLinesInfo*, struct AttrRec *, int just_checking)); extern void FixPageNumbersForSlideShow ARGS_DECL((void)); extern int NeedToFixPageNumbersForSlideShow ARGS_DECL((void)); extern void SetPaperColor ARGS_DECL((void)); #ifdef _INCLUDE_FROM_PAGE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_PAGE_C_*/ #endif /*_PAGE_E_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgificon.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000003777�11602233313�015315� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgificon.xbm,v 1.1 2004/06/18 23:19:38 william Exp $ */ #define tgificon_width 48 #define tgificon_height 48 #define tgificon_x_hot 0 #define tgificon_y_hot 0 static unsigned char tgificon_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x02, 0x00, 0x00, 0x00, 0x00, 0x40, 0x04, 0x00, 0x00, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x00, 0x00, 0x10, 0x10, 0x00, 0x00, 0x00, 0x00, 0xc8, 0x27, 0x00, 0x00, 0x00, 0x00, 0x84, 0x41, 0x00, 0x00, 0x00, 0x00, 0x82, 0x81, 0x00, 0x00, 0x00, 0x00, 0xc1, 0x00, 0x01, 0x00, 0x00, 0x80, 0xc0, 0x00, 0x02, 0x00, 0x00, 0x40, 0x00, 0x00, 0x04, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x30, 0x00, 0x03, 0x10, 0x00, 0x00, 0x28, 0x00, 0x05, 0x20, 0x00, 0x00, 0x24, 0x00, 0x09, 0x40, 0x00, 0x00, 0x22, 0x1c, 0x11, 0x80, 0x00, 0x00, 0x21, 0x12, 0x21, 0x00, 0x01, 0x80, 0x20, 0x02, 0x41, 0x00, 0x02, 0x40, 0x20, 0x1a, 0x81, 0x00, 0x04, 0x20, 0x20, 0x1c, 0x01, 0x01, 0x08, 0x10, 0x20, 0x00, 0x01, 0x02, 0x10, 0x08, 0x20, 0x00, 0x01, 0x04, 0x20, 0xfc, 0xff, 0xff, 0xff, 0xff, 0x7f, 0x08, 0x00, 0x00, 0x01, 0x00, 0x20, 0x10, 0x00, 0x00, 0x01, 0x00, 0x10, 0x20, 0x00, 0x00, 0xe1, 0x01, 0x08, 0x40, 0x00, 0x00, 0xc1, 0x00, 0x04, 0x80, 0x00, 0x00, 0xc1, 0x00, 0x02, 0x00, 0x01, 0x00, 0x61, 0x00, 0x01, 0x00, 0x02, 0x3c, 0x61, 0x80, 0x00, 0x00, 0x04, 0x0c, 0xf1, 0x40, 0x00, 0x00, 0x08, 0x1c, 0x01, 0x20, 0x00, 0x00, 0x10, 0x06, 0x01, 0x10, 0x00, 0x00, 0x20, 0x06, 0x01, 0x08, 0x00, 0x00, 0x40, 0x06, 0x01, 0x04, 0x00, 0x00, 0x80, 0x00, 0x01, 0x02, 0x00, 0x00, 0x00, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x02, 0x81, 0x00, 0x00, 0x00, 0x00, 0x04, 0x41, 0x00, 0x00, 0x00, 0x00, 0x08, 0x21, 0x00, 0x00, 0x00, 0x00, 0x10, 0x11, 0x00, 0x00, 0x00, 0x00, 0x20, 0x09, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �tgif-QPL-4.2.5/obj.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000072054�11602233312�013712� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/obj.c,v 1.16 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_OBJ_C_ #include "tgifdefs.h" #include "arc.e" #include "attr.e" #include "auxtext.e" #include "box.e" #include "cmd.e" #include "cursor.e" #include "group.e" #include "msg.e" #include "obj.e" #include "oval.e" #include "page.e" #include "pin.e" #include "poly.e" #include "polygon.e" #include "rcbox.e" #include "rect.e" #include "setup.e" #include "spline.e" #include "stretch.e" #include "text.e" #include "xbitmap.e" #include "xpixmap.e" struct ObjRec *topObj=NULL, *botObj=NULL; void AddObj(PrevPtr, NextPtr, ObjPtr) struct ObjRec *PrevPtr, *NextPtr, *ObjPtr; /* add ObjPtr between PrevPtr and NextPtr */ { ObjPtr->prev = PrevPtr; ObjPtr->next = NextPtr; if (PrevPtr == NULL) { curPage->top = topObj = ObjPtr; } else { PrevPtr->next = ObjPtr; } if (NextPtr == NULL) { curPage->bot = botObj = ObjPtr; } else { NextPtr->prev = ObjPtr; } } void UnlinkObj(ObjPtr) struct ObjRec *ObjPtr; { if (topObj == ObjPtr) { curPage->top = topObj = ObjPtr->next; } else { ObjPtr->prev->next = ObjPtr->next; } if (botObj == ObjPtr) { curPage->bot = botObj = ObjPtr->prev; } else { ObjPtr->next->prev = ObjPtr->prev; } } void ReplaceObj(old_obj, new_obj) struct ObjRec *old_obj, *new_obj; { if (topObj == old_obj) { curPage->top = topObj = new_obj; new_obj->prev = NULL; } else { old_obj->prev->next = new_obj; new_obj->prev = old_obj->prev; } if (botObj == old_obj) { curPage->bot = botObj = new_obj; new_obj->next = NULL; } else { old_obj->next->prev = new_obj; new_obj->next = old_obj->next; } } void FreeObj(ObjPtr) register struct ObjRec *ObjPtr; { if (ObjPtr == NULL) return; if (ObjPtr->ctm != NULL) { free(ObjPtr->ctm); ObjPtr->ctm = NULL; } if (ObjPtr->creator_full_id != NULL) { free(ObjPtr->creator_full_id); ObjPtr->creator_full_id = NULL; } switch (ObjPtr->type) { case OBJ_POLY: DelAllAttrs(ObjPtr->fattr); FreePolyObj(ObjPtr); break; case OBJ_BOX: DelAllAttrs(ObjPtr->fattr); FreeBoxObj(ObjPtr); break; case OBJ_OVAL: DelAllAttrs(ObjPtr->fattr); FreeOvalObj(ObjPtr); break; case OBJ_TEXT: FreeTextObj(ObjPtr); break; case OBJ_POLYGON: DelAllAttrs(ObjPtr->fattr); FreePolygonObj(ObjPtr); break; case OBJ_ARC: DelAllAttrs(ObjPtr->fattr); FreeArcObj(ObjPtr); break; case OBJ_RCBOX: DelAllAttrs(ObjPtr->fattr); FreeRCBoxObj(ObjPtr); break; case OBJ_XBM: DelAllAttrs(ObjPtr->fattr); FreeXBmObj(ObjPtr); break; case OBJ_XPM: DelAllAttrs(ObjPtr->fattr); FreeXPmObj(ObjPtr); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: DelAllAttrs(ObjPtr->fattr); FreeGroupObj(ObjPtr); break; } } void DelObj(ObjPtr) struct ObjRec *ObjPtr; { if (ObjPtr->type == OBJ_POLY) { if (ObjPtr->detail.p->start_conn != NULL) { DelConnFromPoly(ObjPtr->detail.p->start_conn); } if (ObjPtr->detail.p->end_conn != NULL) { DelConnFromPoly(ObjPtr->detail.p->end_conn); } } else if (ObjPtr->type == OBJ_PIN) { while (ObjPtr->detail.r->pin_connected > 0) { DelConnFromPin(ObjPtr->detail.p->end_conn); } } if (topObj == ObjPtr) { curPage->top = topObj = ObjPtr->next; } else { ObjPtr->prev->next = ObjPtr->next; } if (botObj == ObjPtr) { curPage->bot = botObj = ObjPtr->prev; } else { ObjPtr->next->prev = ObjPtr->prev; } FreeObj(ObjPtr); } void DelAllObj() { register struct ObjRec *ptr, *next_obj; if (topObj == NULL) return; for (ptr=topObj; ptr != NULL; ptr=next_obj) { next_obj = ptr->next; FreeObj(ptr); } if (curPage != NULL) curPage->top = curPage->bot = NULL; topObj = botObj = NULL; } void AdjObjOBBox(ObjPtr) struct ObjRec *ObjPtr; { struct ObjRec *obj_ptr; int oltx, olty, orbx, orby; switch (ObjPtr->type) { case OBJ_ARC: CalcArcOBBox(ObjPtr); break; case OBJ_TEXT: SetTextOBBox(ObjPtr, ObjPtr->detail.t->minilines.just, ObjPtr->obbox.rbx-ObjPtr->obbox.ltx, ObjPtr->obbox.rby-ObjPtr->obbox.lty, ObjPtr->detail.t->min_lbearing, ObjPtr->detail.t->max_rextra, ROTATE0); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: obj_ptr = ObjPtr->detail.r->last; oltx = obj_ptr->obbox.ltx; olty = obj_ptr->obbox.lty; orbx = obj_ptr->obbox.rbx; orby = obj_ptr->obbox.rby; for (obj_ptr = obj_ptr->prev; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { if (obj_ptr->obbox.ltx < oltx) oltx = obj_ptr->obbox.ltx; if (obj_ptr->obbox.lty < olty) olty = obj_ptr->obbox.lty; if (obj_ptr->obbox.rbx > orbx) orbx = obj_ptr->obbox.rbx; if (obj_ptr->obbox.rby > orby) orby = obj_ptr->obbox.rby; } ObjPtr->obbox.ltx = oltx; ObjPtr->obbox.lty = olty; ObjPtr->obbox.rbx = orbx; ObjPtr->obbox.rby = orby; break; case OBJ_PIN: obj_ptr = GetPinObj(ObjPtr); oltx = obj_ptr->obbox.ltx; olty = obj_ptr->obbox.lty; orbx = obj_ptr->obbox.rbx; orby = obj_ptr->obbox.rby; ObjPtr->obbox.ltx = oltx; ObjPtr->obbox.lty = olty; ObjPtr->obbox.rbx = orbx; ObjPtr->obbox.rby = orby; break; } } void AdjObjBBox(ObjPtr) struct ObjRec *ObjPtr; { register int w=0; register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; int ltx, lty, rbx, rby; AdjObjOBBox(ObjPtr); switch (ObjPtr->type) { case OBJ_POLY: CalcPolyBBox(ObjPtr); break; case OBJ_ARC: CalcArcBBox(ObjPtr, ObjPtr->obbox, &(ObjPtr->bbox)); break; case OBJ_POLYGON: w = HALF_W(ObjPtr->detail.g->width); break; case OBJ_BOX: w = HALF_W(ObjPtr->detail.b->width); break; case OBJ_OVAL: w = HALF_W(ObjPtr->detail.o->width); break; case OBJ_RCBOX: w = HALF_W(ObjPtr->detail.rcb->width); break; case OBJ_XBM: break; case OBJ_XPM: break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: obj_ptr = ObjPtr->detail.r->last; ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; for (obj_ptr = obj_ptr->prev; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { if (obj_ptr->bbox.ltx < ltx) ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < lty) lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > rbx) rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > rby) rby = obj_ptr->bbox.rby; } ObjPtr->bbox.ltx = ltx; ObjPtr->bbox.lty = lty; ObjPtr->bbox.rbx = rbx; ObjPtr->bbox.rby = rby; break; case OBJ_PIN: obj_ptr = GetPinObj(ObjPtr); ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; ObjPtr->bbox.ltx = ltx; ObjPtr->bbox.lty = lty; ObjPtr->bbox.rbx = rbx; ObjPtr->bbox.rby = rby; break; } switch (ObjPtr->type) { case OBJ_POLY: case OBJ_ARC: break; case OBJ_POLYGON: case OBJ_BOX: case OBJ_OVAL: case OBJ_RCBOX: case OBJ_XBM: case OBJ_XPM: ObjPtr->bbox.ltx = ObjPtr->obbox.ltx - w; ObjPtr->bbox.lty = ObjPtr->obbox.lty - w; ObjPtr->bbox.rbx = ObjPtr->obbox.rbx + w; ObjPtr->bbox.rby = ObjPtr->obbox.rby + w; break; case OBJ_TEXT: SetTextBBox(ObjPtr, ObjPtr->detail.t->minilines.just, ObjPtr->obbox.rbx-ObjPtr->obbox.ltx, ObjPtr->obbox.rby-ObjPtr->obbox.lty, ObjPtr->detail.t->min_lbearing, ObjPtr->detail.t->max_rextra, ROTATE0); break; } attr_ptr = ObjPtr->fattr; ltx = ObjPtr->bbox.ltx; lty = ObjPtr->bbox.lty; rbx = ObjPtr->bbox.rbx; rby = ObjPtr->bbox.rby; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { if (attr_ptr->shown) { if (attr_ptr->obj->bbox.ltx < ltx) ltx = attr_ptr->obj->bbox.ltx; if (attr_ptr->obj->bbox.lty < lty) lty = attr_ptr->obj->bbox.lty; if (attr_ptr->obj->bbox.rbx > rbx) rbx = attr_ptr->obj->bbox.rbx; if (attr_ptr->obj->bbox.rby > rby) rby = attr_ptr->obj->bbox.rby; } } ObjPtr->bbox.ltx = ltx; ObjPtr->bbox.lty = lty; ObjPtr->bbox.rbx = rbx; ObjPtr->bbox.rby = rby; if (ObjPtr->type == OBJ_SYM) { if (ObjPtr->obbox.ltx-QUARTER_INCH < ObjPtr->bbox.ltx) { ObjPtr->bbox.ltx = ObjPtr->obbox.ltx - QUARTER_INCH; } if (ObjPtr->obbox.lty-QUARTER_INCH < ObjPtr->bbox.lty) { ObjPtr->bbox.lty = ObjPtr->obbox.lty - QUARTER_INCH; } if (ObjPtr->obbox.rbx+QUARTER_INCH > ObjPtr->bbox.rbx) { ObjPtr->bbox.rbx = ObjPtr->obbox.rbx + QUARTER_INCH; } if (ObjPtr->obbox.rby+QUARTER_INCH > ObjPtr->bbox.rby) { ObjPtr->bbox.rby = ObjPtr->obbox.rby + QUARTER_INCH; } } } static void RecursivelyAdjAnObjBBox(target_obj, owner_obj) struct ObjRec *target_obj, *owner_obj; { if (target_obj == owner_obj) { AdjObjBBox(target_obj); } else { struct ObjRec *obj_ptr=NULL; switch (owner_obj->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: for (obj_ptr=owner_obj->detail.r->first; obj_ptr!=NULL; obj_ptr=obj_ptr->next) { RecursivelyAdjAnObjBBox(target_obj, obj_ptr); } AdjObjBBox(owner_obj); break; default: break; } } } void RecursivelyAdjObjBBox(sub_obj, owner_obj, top_owner) struct ObjRec *sub_obj, *owner_obj, *top_owner; { if (owner_obj == NULL) { RecursivelyAdjAnObjBBox(sub_obj, sub_obj); } else { RecursivelyAdjAnObjBBox(sub_obj, top_owner); } } static void InvalidateObjCache(ObjPtr) struct ObjRec *ObjPtr; { int w=0, h=0, num_rows=0, num_cols=0; struct TextRec *text_ptr=NULL; struct XBmRec *xbm_ptr=NULL; struct XPmRec *xpm_ptr=NULL; struct ObjRec *obj_ptr=NULL; w = ObjPtr->obbox.rbx - ObjPtr->obbox.ltx; h = ObjPtr->obbox.rby - ObjPtr->obbox.lty; switch (ObjPtr->type) { case OBJ_POLY: if (NeedsToCachePolyObj(ObjPtr)) { struct PolyRec *poly_ptr=ObjPtr->detail.p; if (poly_ptr->rotated_vlist != NULL) free(poly_ptr->rotated_vlist); if (poly_ptr->rotated_asvlist != NULL) { free(poly_ptr->rotated_asvlist); } poly_ptr->rotated_vlist = poly_ptr->rotated_asvlist = NULL; poly_ptr->rotated_n = poly_ptr->rotated_asn = 0; } break; case OBJ_BOX: break; case OBJ_OVAL: /* atan2(61/112) = 0.498721 rad = 28.5746 deg */ if (NeedsToCacheOvalObj(ObjPtr)) { struct OvalRec *oval_ptr=ObjPtr->detail.o; if (oval_ptr->rotated_vlist != NULL) free(oval_ptr->rotated_vlist); oval_ptr->rotated_vlist = NULL; oval_ptr->rotated_n = 0; } break; case OBJ_POLYGON: if (NeedsToCachePolygonObj(ObjPtr)) { struct PolygonRec *polygon_ptr=ObjPtr->detail.g; if (polygon_ptr->rotated_vlist != NULL) { free(polygon_ptr->rotated_vlist); } polygon_ptr->rotated_vlist = NULL; polygon_ptr->rotated_n = 0; } break; case OBJ_ARC: if (NeedsToCacheArcObj(ObjPtr)) { struct ArcRec *arc_ptr=ObjPtr->detail.a; if (arc_ptr->rotated_vlist != NULL) free(arc_ptr->rotated_vlist); if (arc_ptr->rotated_asvlist != NULL) free(arc_ptr->rotated_asvlist); arc_ptr->rotated_vlist = arc_ptr->rotated_asvlist = NULL; arc_ptr->rotated_n = arc_ptr->rotated_asn = 0; } break; case OBJ_RCBOX: if (NeedsToCacheRCBoxObj(ObjPtr)) { struct RCBoxRec *rcbox_ptr=ObjPtr->detail.rcb; if (rcbox_ptr->rotated_vlist != NULL) free(rcbox_ptr->rotated_vlist); rcbox_ptr->rotated_vlist = NULL; rcbox_ptr->rotated_n = 0; } break; case OBJ_TEXT: text_ptr = ObjPtr->detail.t; if (NeedsToCacheTextObj(ObjPtr)) { if (text_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, text_ptr->cached_bitmap); } if (text_ptr->cached_pixmap != None) { XFreePixmap(mainDisplay, text_ptr->cached_pixmap); } if (text_ptr->cached_bg_bitmap != None) { XFreePixmap(mainDisplay, text_ptr->cached_bg_bitmap); } text_ptr->cached_bitmap = None; text_ptr->cached_pixmap = None; text_ptr->cached_bg_bitmap = None; if (zoomScale != 0) { text_ptr->cached_zoom = 0; } } break; case OBJ_XBM: xbm_ptr = ObjPtr->detail.xbm; num_cols = (zoomedIn) ? (w<<zoomScale) : (w>>zoomScale); num_rows = (zoomedIn) ? (h<<zoomScale) : (h>>zoomScale); if (NeedsToCacheXBmObj(ObjPtr)) { if (xbm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xbm_ptr->cached_bitmap); } xbm_ptr->cached_bitmap = None; if (zoomScale != 0) { xbm_ptr->cached_zoom = 0; } } break; case OBJ_XPM: xpm_ptr = ObjPtr->detail.xpm; num_cols = (zoomedIn) ? (w<<zoomScale) : (w>>zoomScale); num_rows = (zoomedIn) ? (h<<zoomScale) : (h>>zoomScale); if (NeedsToCacheXPmObj(ObjPtr)) { if (xpm_ptr->cached_pixmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_pixmap); } xpm_ptr->cached_pixmap = None; if (xpm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_bitmap); } xpm_ptr->cached_bitmap = None; if (xpm_ptr->clip_mask != None) { XFreePixmap(mainDisplay, xpm_ptr->clip_mask); } xpm_ptr->clip_mask = None; if (zoomScale != 0) { xpm_ptr->cached_zoom = 0; } xpm_ptr->cached_color = (-1); } break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: for (obj_ptr=ObjPtr->detail.r->first; obj_ptr != NULL; obj_ptr=obj_ptr->next) { InvalidateObjCache(obj_ptr); } break; } } void AdjObjCache(ObjPtr) struct ObjRec *ObjPtr; { register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; GetTransformedOBBoxOffsetVs(ObjPtr, ObjPtr->rotated_obbox); switch (ObjPtr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: for (obj_ptr=ObjPtr->detail.r->first; obj_ptr != NULL; obj_ptr=obj_ptr->next) { AdjObjCache(obj_ptr); } break; default: InvalidateObjCache(ObjPtr); break; } for (attr_ptr=ObjPtr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { AdjObjCache(attr_ptr->obj); } } } void AdjCaches() { register struct ObjRec *obj_ptr, *ptr; register struct AttrRec *attr_ptr; if (topObj == NULL) return; for (obj_ptr = topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { switch (obj_ptr->type) { case OBJ_TEXT: case OBJ_XBM: case OBJ_XPM: AdjObjCache(obj_ptr); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: for (ptr=obj_ptr->detail.r->first; ptr != NULL; ptr=ptr->next) { AdjObjCache(ptr); } break; } for (attr_ptr=obj_ptr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { AdjObjCache(attr_ptr->obj); } } } } static int dontAutoRetractArrow=FALSE; #define RETREAT (0.8) static void AdjArcCache(ObjPtr) struct ObjRec *ObjPtr; { struct ArcRec *arc_ptr=ObjPtr->detail.a; int a_angle1, a_angle2; if (arc_ptr->style == LS_PLAIN) return; a_angle1 = arc_ptr->angle1; a_angle2 = arc_ptr->angle2; GetArcArrowInfo(ObjPtr, NULL, NULL, NULL, &a_angle1, NULL, NULL, NULL, &a_angle2); arc_ptr->a_angle1 = a_angle1; arc_ptr->a_angle2 = a_angle2; } static void AdjPolyCache(ObjPtr) struct ObjRec *ObjPtr; { struct PolyRec *poly_ptr=ObjPtr->detail.p; if (poly_ptr->rotated_vlist != NULL) { free(poly_ptr->rotated_vlist); } if (poly_ptr->rotated_asvlist != NULL) { free(poly_ptr->rotated_asvlist); } poly_ptr->rotated_vlist = poly_ptr->rotated_asvlist = NULL; poly_ptr->rotated_n = poly_ptr->rotated_asn = 0; switch (poly_ptr->curved) { case LT_STRAIGHT: case LT_SPLINE: if (poly_ptr->svlist != NULL) { free(poly_ptr->svlist); } poly_ptr->svlist = MakeMultiSplinePolyVertex( poly_ptr->curved, &(poly_ptr->sn), poly_ptr->smooth, drawOrigX, drawOrigY, poly_ptr->n, poly_ptr->vlist); break; case LT_STRUCT_SPLINE: if (poly_ptr->svlist != NULL) free(poly_ptr->svlist); if (poly_ptr->ssvlist != NULL) free(poly_ptr->ssvlist); if (poly_ptr->ssmooth != NULL) free(poly_ptr->ssmooth); if (poly_ptr->smooth != NULL) free(poly_ptr->smooth); poly_ptr->smooth = NULL; poly_ptr->ssvlist = MakeStructuredSplinePolyVertex(&(poly_ptr->ssn), &(poly_ptr->ssmooth), poly_ptr->n, poly_ptr->vlist); poly_ptr->svlist = MakeMultiSplinePolyVertex( poly_ptr->curved, &(poly_ptr->sn), poly_ptr->ssmooth, drawOrigX, drawOrigY, poly_ptr->ssn, poly_ptr->ssvlist); break; case LT_INTSPLINE: if (poly_ptr->svlist != NULL) { free(poly_ptr->svlist); } if (poly_ptr->intvlist != NULL) { free(poly_ptr->intvlist); } if (!undoingOrRedoing && !dontAutoRetractArrow) { if (AutoRetractedArrowAttr(ObjPtr, FALSE)) { int new_x=0, new_y=0; IntPoint *v=NULL; if (poly_ptr->n != 3) { int x0, y0, x2, y2; v = poly_ptr->vlist; x0 = v[0].x; y0 = v[0].y; x2 = v[poly_ptr->n-1].x; y2 = v[poly_ptr->n-1].y; if (poly_ptr->smooth != NULL) free(poly_ptr->smooth); poly_ptr->smooth = (char*)malloc(4*sizeof(char)); if (poly_ptr->smooth == NULL) FailAllocMessage(); poly_ptr->smooth[0] = poly_ptr->smooth[1] = poly_ptr->smooth[2] = FALSE; if (poly_ptr->vlist != NULL) free(poly_ptr->vlist); poly_ptr->vlist = (IntPoint*)malloc(4*sizeof(IntPoint)); if (poly_ptr->vlist == NULL) FailAllocMessage(); poly_ptr->vlist[0].x = x0; poly_ptr->vlist[0].y = y0; poly_ptr->vlist[2].x = x2; poly_ptr->vlist[2].y = y2; poly_ptr->n = 3; } v = poly_ptr->vlist; CalcAutoRetractedArrowAttrBend(poly_ptr->style, v[0].x, v[0].y, v[2].x, v[2].y, &new_x, &new_y); v[1].x = new_x; v[1].y = new_y; } } poly_ptr->svlist = MakeIntSplinePolyVertex( &(poly_ptr->sn), &(poly_ptr->intn), &(poly_ptr->intvlist), drawOrigX, drawOrigY, poly_ptr->n, poly_ptr->vlist); break; } if (poly_ptr->style != LS_PLAIN) { IntPoint *v=poly_ptr->vlist, *v_copy; int i, n=poly_ptr->n, dx, dy, aw=poly_ptr->aw, retracted_arrow; double len, sin_val, cos_val; retracted_arrow = (RetractedArrowAttr(ObjPtr) || AutoRetractedArrowAttr(ObjPtr, TRUE)); if (poly_ptr->asvlist != NULL) { free(poly_ptr->asvlist); } switch (poly_ptr->curved) { case LT_STRAIGHT: case LT_SPLINE: v = poly_ptr->vlist; n = poly_ptr->n; break; case LT_STRUCT_SPLINE: v = poly_ptr->ssvlist; n = poly_ptr->ssn; break; case LT_INTSPLINE: v = poly_ptr->intvlist; n = poly_ptr->intn; break; } v_copy = (IntPoint *)malloc((n+1)*sizeof(IntPoint)); if (v_copy == NULL) FailAllocMessage(); for (i = 0; i < n; i++) { v_copy[i].x = v[i].x; v_copy[i].y = v[i].y; } if (aw == 0) aw = 1; dx = v_copy[1].x - v_copy[0].x; dy = v_copy[1].y - v_copy[0].y; if (!retracted_arrow && (poly_ptr->style & LS_LEFT) && (dx != 0 || dy != 0)) { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin_val = ((double)dy)/len; cos_val = ((double)dx)/len; v_copy[0].x = round(v_copy[0].x+RETREAT*aw*cos_val); v_copy[0].y = round(v_copy[0].y+RETREAT*aw*sin_val); } dx = v_copy[n-1].x - v_copy[n-2].x; dy = v_copy[n-1].y - v_copy[n-2].y; if (!retracted_arrow && (poly_ptr->style & LS_RIGHT) && (dx != 0 || dy != 0)) { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin_val = ((double)dy)/len; cos_val = ((double)dx)/len; v_copy[n-1].x = round(v_copy[n-1].x-RETREAT*aw*cos_val); v_copy[n-1].y = round(v_copy[n-1].y-RETREAT*aw*sin_val); } switch (poly_ptr->curved) { case LT_STRAIGHT: case LT_SPLINE: poly_ptr->asvlist = MakeMultiSplinePolyVertex( poly_ptr->curved, &(poly_ptr->asn), poly_ptr->smooth, drawOrigX, drawOrigY, n, v_copy); break; case LT_STRUCT_SPLINE: poly_ptr->asvlist = MakeMultiSplinePolyVertex( poly_ptr->curved, &(poly_ptr->asn), poly_ptr->ssmooth, drawOrigX, drawOrigY, n, v_copy); break; case LT_INTSPLINE: poly_ptr->asvlist = MakeSplinePolyVertex(0, poly_ptr->curved, &(poly_ptr->asn), drawOrigX, drawOrigY, n, v_copy); break; } free(v_copy); } } static void AdjPolygonCache(ObjPtr) struct ObjRec *ObjPtr; { struct PolygonRec *polygon_ptr=ObjPtr->detail.g; if (polygon_ptr->rotated_vlist != NULL) { free(polygon_ptr->rotated_vlist); } polygon_ptr->rotated_vlist = NULL; polygon_ptr->rotated_n = 0; switch (polygon_ptr->curved) { case LT_STRAIGHT: if (polygon_ptr->svlist != NULL) { free(polygon_ptr->svlist); } polygon_ptr->svlist = MakeMultiSplinePolygonVertex( polygon_ptr->curved, &(polygon_ptr->sn), polygon_ptr->smooth, drawOrigX, drawOrigY, polygon_ptr->n, polygon_ptr->vlist); break; case LT_SPLINE: if (polygon_ptr->svlist != NULL) { free(polygon_ptr->svlist); } polygon_ptr->svlist = MakeMultiSplinePolygonVertex( polygon_ptr->curved, &(polygon_ptr->sn), polygon_ptr->smooth, drawOrigX, drawOrigY, polygon_ptr->n, polygon_ptr->vlist); break; case LT_STRUCT_SPLINE: if (polygon_ptr->svlist != NULL) free(polygon_ptr->svlist); if (polygon_ptr->ssvlist != NULL) free(polygon_ptr->ssvlist); if (polygon_ptr->ssmooth != NULL) free(polygon_ptr->ssmooth); if (polygon_ptr->smooth != NULL) free(polygon_ptr->smooth); #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(polygon_ptr->n >= 7, "NumPts < 7 in AdjPolygonCache()", NULL); #endif /* _TGIF_DBG */ polygon_ptr->smooth = NULL; polygon_ptr->ssvlist = MakeStructuredSplinePolygonVertex( &(polygon_ptr->ssn), &(polygon_ptr->ssmooth), polygon_ptr->n, polygon_ptr->vlist); polygon_ptr->svlist = MakeMultiSplinePolygonVertex( polygon_ptr->curved, &(polygon_ptr->sn), polygon_ptr->ssmooth, drawOrigX, drawOrigY, polygon_ptr->ssn, polygon_ptr->ssvlist); break; case LT_INTSPLINE: if (polygon_ptr->svlist != NULL) { free(polygon_ptr->svlist); } if (polygon_ptr->intvlist != NULL) { free(polygon_ptr->intvlist); } polygon_ptr->svlist = MakeIntSplinePolygonVertex( &(polygon_ptr->sn), &(polygon_ptr->intn), &(polygon_ptr->intvlist), drawOrigX, drawOrigY, polygon_ptr->n, polygon_ptr->vlist); break; } } void AdjObjSplineVs(ObjPtr) struct ObjRec *ObjPtr; { struct ObjRec *obj_ptr; switch (ObjPtr->type) { case OBJ_BOX: break; case OBJ_XBM: break; case OBJ_XPM: break; case OBJ_OVAL: InvalidateObjCache(ObjPtr); break; case OBJ_TEXT: break; case OBJ_RCBOX: InvalidateObjCache(ObjPtr); break; case OBJ_ARC: InvalidateObjCache(ObjPtr); AdjArcCache(ObjPtr); break; case OBJ_POLY: AdjPolyCache(ObjPtr); break; case OBJ_POLYGON: AdjPolygonCache(ObjPtr); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: for (obj_ptr=ObjPtr->detail.r->first; obj_ptr != NULL; obj_ptr=obj_ptr->next) { AdjObjSplineVs(obj_ptr); } break; } GetTransformedOBBoxOffsetVs(ObjPtr, ObjPtr->rotated_obbox); } void AdjSplineVs() { register struct ObjRec *obj_ptr, *ptr; if (topObj == NULL) return; dontAutoRetractArrow = TRUE; for (obj_ptr = topObj; obj_ptr != NULL; obj_ptr = obj_ptr->next) { switch (obj_ptr->type) { case OBJ_POLY: case OBJ_BOX: case OBJ_OVAL: case OBJ_TEXT: case OBJ_POLYGON: case OBJ_ARC: case OBJ_RCBOX: case OBJ_XBM: case OBJ_XPM: AdjObjSplineVs(obj_ptr); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: for (ptr=obj_ptr->detail.r->first; ptr != NULL; ptr=ptr->next) { AdjObjSplineVs(ptr); } GetTransformedOBBoxOffsetVs(obj_ptr, obj_ptr->rotated_obbox); break; } } dontAutoRetractArrow = FALSE; } void ClearObjCachesInAllPages() { struct ObjRec *saved_top_obj=topObj, *saved_bot_obj=botObj; struct PageRec *saved_cur_page=curPage; for (curPage=firstPage; curPage != NULL; curPage=curPage->next) { topObj = curPage->top; botObj = curPage->bot; AdjCaches(); AdjSplineVs(); curPage->draw_orig_x = drawOrigX; curPage->draw_orig_y = drawOrigY; curPage->zoom_scale = zoomScale; curPage->zoomed_in = zoomedIn; } topObj = saved_top_obj; botObj = saved_bot_obj; curPage = saved_cur_page; } void MoveRotatedObjCache(ObjPtr, AbsDx, AbsDy) struct ObjRec *ObjPtr; int AbsDx, AbsDy; { register int i; int dx_off, dy_off, n=0; XPoint *v=NULL; if (ObjPtr->ctm == NULL) return; dx_off = ZOOMED_SIZE(AbsDx); dy_off = ZOOMED_SIZE(AbsDy); for (i=0; i < 5; i++) { ObjPtr->rotated_obbox[i].x += dx_off; ObjPtr->rotated_obbox[i].y += dy_off; } ObjPtr->orig_obbox.ltx += AbsDx; ObjPtr->orig_obbox.lty += AbsDy; ObjPtr->orig_obbox.rbx += AbsDx; ObjPtr->orig_obbox.rby += AbsDy; switch (ObjPtr->type) { case OBJ_POLY: case OBJ_POLYGON: case OBJ_OVAL: case OBJ_ARC: case OBJ_RCBOX: switch (ObjPtr->type) { case OBJ_POLY: n = ObjPtr->detail.p->rotated_n; v = ObjPtr->detail.p->rotated_vlist; break; case OBJ_POLYGON: n = ObjPtr->detail.g->rotated_n; v = ObjPtr->detail.g->rotated_vlist; break; case OBJ_OVAL: n = ObjPtr->detail.o->rotated_n; v = ObjPtr->detail.o->rotated_vlist; break; case OBJ_ARC: n = ObjPtr->detail.a->rotated_n; v = ObjPtr->detail.a->rotated_vlist; break; case OBJ_RCBOX: n = ObjPtr->detail.rcb->rotated_n; v = ObjPtr->detail.rcb->rotated_vlist; break; } if (v != NULL) { for (i=0; i < n; i++) { v[i].x += dx_off; v[i].y += dy_off; } } if (ObjPtr->type == OBJ_POLY) { n = ObjPtr->detail.p->rotated_asn; v = ObjPtr->detail.p->rotated_asvlist; if (v != NULL) { for (i=0; i < n; i++) { v[i].x += dx_off; v[i].y += dy_off; } } } break; case OBJ_BOX: case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: case OBJ_XBM: case OBJ_XPM: break; case OBJ_TEXT: ObjPtr->detail.t->orig_bbox.ltx += AbsDx; ObjPtr->detail.t->orig_bbox.lty += AbsDy; ObjPtr->detail.t->orig_bbox.rbx += AbsDx; ObjPtr->detail.t->orig_bbox.rby += AbsDy; break; } } void AdjHotSpots() { } void AdjObjHotSpot() { } int IsTopLevelObject(ObjPtr) struct ObjRec *ObjPtr; { struct ObjRec *obj_ptr=NULL; for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (obj_ptr == ObjPtr) { return TRUE; } } return FALSE; } struct ObjRec *GetTopOwner(ObjPtr) struct ObjRec *ObjPtr; { struct ObjRec *top_owner=ObjPtr; while (top_owner->tmp_parent != NULL) { top_owner = top_owner->tmp_parent; } return top_owner; } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/vms_comp.h���������������������������������������������������������������������������0000644�0000764�0000764�00000004273�11602233313�014767� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: George Carrette, <GJC@MITECH.COM> * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/vms_comp.h,v 1.1 2004/06/18 23:19:10 william Exp $ */ /* Header file for vms_comp routines, generally useful functions to aid in porting/running Unix and BSD code under VAX/VMS. ** Written by George Carrette, <GJC@MITECH.COM>. ** Includes modified VMS readdir() routines. ** Written by Rich $alz, <rsalz@bbn.com> in August, 1990. To use: #include "vms_comp.h" */ #ifndef _VMS_COMP_H_ #define _VMS_COMP_H_ #include <stdio.h> #ifdef VMS #include <ctype.h> #include <errno.h> #include <descrip.h> #include <string.h> #include <stdlib.h> /* RN */ #include <stat.h> /* RN */ #include <unixio.h> /* RN */ #include <unistd.h> /* RN */ #include <rmsdef.h> #include <ssdef.h> #include <clidef.h> /* RN */ #include <lib$routines.h> /* RN */ #include <starlet.h> /* RN */ #if __VMS_VER < 70000000 /* RN */ # define bcopy memmove # define rindex strrchr #endif #define lstat stat #define unlink delete #ifndef DESCRIP_H_DEFINED #include <descrip.h> #endif int ioctl(int fildes, int request,... /* arg */); /* RN */ /* 12-NOV-1990 added d_namlen field -GJC@MITECH.COM */ /* Data structure returned by READDIR(). */ struct dirent { char d_name[100]; /* File name */ int d_namlen; int vms_verscount; /* Number of versions */ int vms_versions[20]; /* Version numbers */ }; /* Handle returned by opendir(), used by the other routines. You * are not supposed to care what's inside this structure. */ typedef struct _dirdesc { long context; int vms_wantversions; char *pattern; struct dirent entry; struct dsc$descriptor_s pat; } DIR; /* Another name for this? Used by TGIF */ struct direct { char d_name[100]; /* File name */ int d_namlen; int vms_verscount; /* Number of versions */ int vms_versions[20]; /* Version numbers */ }; #define rewinddir(dirp) seekdir((dirp), 0L) extern DIR *opendir(); extern struct dirent *readdir(); extern long telldir(); extern void seekdir(); extern void closedir(); extern void vmsreaddirversions(); #endif /* VMS */ #endif /*_VMS_COMP_H_*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/stk.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000037013�11602233312�013735� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/stk.c,v 1.7 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_STK_C_ #include "tgifdefs.h" #include "align.e" #include "attr.e" #include "box.e" #include "button.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "font.e" #include "grid.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "stk.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "version.e" #include "wb.e" struct ObjRec *tgifObj=NULL; struct StkRec *topStk=NULL; int AncesterModified() { struct StkRec *stk_ptr; for (stk_ptr = topStk; stk_ptr != NULL; stk_ptr = stk_ptr->next) { if (stk_ptr->file_mod) { return TRUE; } } return FALSE; } void InitTgifObj() { tgifObj = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (tgifObj == NULL) FailAllocMessage(); memset(tgifObj, 0, sizeof(struct ObjRec)); tgifObj->type = OBJ_BOX; tgifObj->x = tgifObj->y = 0; tgifObj->color = 0; tgifObj->id = (-1); tgifObj->dirty = FALSE; tgifObj->rotation = 0; tgifObj->marked = tgifObj->locked = FALSE; tgifObj->obbox.ltx = tgifObj->obbox.lty = 0; tgifObj->obbox.rbx = tgifObj->obbox.rby = 0; tgifObj->bbox.ltx = tgifObj->bbox.lty = 0; tgifObj->bbox.rbx = tgifObj->bbox.rby = 0; tgifObj->next = tgifObj->prev = NULL; tgifObj->fattr = tgifObj->lattr = NULL; tgifObj->invisible = FALSE; tgifObj->trans_pat = FALSE; tgifObj->detail.b = (struct BoxRec *)malloc(sizeof(struct BoxRec)); if (tgifObj->detail.b == NULL) FailAllocMessage(); memset(tgifObj->detail.b, 0, sizeof(struct BoxRec)); tgifObj->detail.b->fill = NONEPAT; tgifObj->detail.b->pen = NONEPAT; tgifObj->detail.b->width = 0; tgifObj->detail.b->dash = 0; } void InitStk() { curSymDir[0] = '\0'; InitTgifObj(); } struct StkRec *SaveFileInfo() { struct StkRec *stk_ptr; stk_ptr = (struct StkRec *)malloc(sizeof(struct StkRec)); if (stk_ptr == NULL) FailAllocMessage(); memset(stk_ptr, 0, sizeof(struct StkRec)); stk_ptr->next = topStk; stk_ptr->sel = (topSel == NULL ? NULL : topSel->obj); stk_ptr->first = topObj; stk_ptr->last = botObj; stk_ptr->file_mod = fileModified; stk_ptr->id = objId; stk_ptr->page_style = pageStyle; stk_ptr->orig_x = drawOrigX; stk_ptr->orig_y = drawOrigY; stk_ptr->zoom = zoomScale; stk_ptr->zoomed = zoomedIn; stk_ptr->grid_system = gridSystem; stk_ptr->english_grid = xyEnglishGrid; stk_ptr->metric_grid = xyMetricGrid; stk_ptr->snap_on = snapOn; stk_ptr->color = colorIndex; stk_ptr->h_align = horiAlign; stk_ptr->v_align = vertAlign; stk_ptr->line_w = lineWidth; stk_ptr->line_s = lineStyle; stk_ptr->trans_pat = transPat; stk_ptr->fill = objFill; stk_ptr->pen = penPat; stk_ptr->just = textJust; stk_ptr->v_space = textVSpace; stk_ptr->font = curFont; stk_ptr->f_style = curStyle; stk_ptr->f_sz_unit = curSzUnit; stk_ptr->print_mag = printMag; stk_ptr->grid_shown = gridShown; stk_ptr->move_mode = moveMode; stk_ptr->rcb_radius = rcbRadius; stk_ptr->underline_on = curUnderlineOn; stk_ptr->underline_y_offset = curUnderlineYOffset; stk_ptr->overline_on = curOverlineOn; stk_ptr->overline_y_offset = curOverlineYOffset; stk_ptr->first_file_attr = tgifObj->fattr; stk_ptr->last_file_attr = tgifObj->lattr; stk_ptr->first_page = firstPage; stk_ptr->last_page = lastPage; stk_ptr->cur_page = curPage; stk_ptr->cur_page_num = curPageNum; stk_ptr->last_page_num = lastPageNum; stk_ptr->cols = paperCol; stk_ptr->rows = paperRow; stk_ptr->page_layout_mode = pageLayoutMode; stk_ptr->color_dump = colorDump; stk_ptr->one_page_width = onePageWidth; stk_ptr->one_page_height = onePageHeight; stk_ptr->first_cmd = firstCmd; stk_ptr->last_cmd = lastCmd; stk_ptr->cur_cmd = curCmd; stk_ptr->history_count = historyCount; strcpy(stk_ptr->dir, curDir); stk_ptr->name_valid = curFileDefined; if (stk_ptr->name_valid) strcat(stk_ptr->name, curFileName); strcpy(stk_ptr->sym_dir, curSymDir); strcpy(stk_ptr->domain, curDomainName); stk_ptr->saved_comments = savedComments; stk_ptr->saved_comments_len = savedCommentsLen; stk_ptr->file_bg_pixel = myFileBgPixel; stk_ptr->file_fg_pixel = myFileFgPixel; stk_ptr->file_bg_color_str = myFileBgColorStr; stk_ptr->file_fg_color_str = myFileFgColorStr; stk_ptr->file_bg_gif_url = myFileBgGifURL; stk_ptr->file_bg_pixmap_w = myFileBgPixmapW; stk_ptr->file_bg_pixmap_h = myFileBgPixmapH; stk_ptr->file_bg_pixmap = myFileBgPixmap; myFileBgPixel = myFileFgPixel = INVALID; myFileBgColorStr = myFileFgColorStr = myFileBgGifURL = NULL; myFileBgPixmap = None; return stk_ptr; } void ResetFileInfo() { ClearBgColorInfo(FALSE); ClearBgPixmapInfo(FALSE); tgifObj->fattr = NULL; tgifObj->lattr = NULL; firstCmd = lastCmd = curCmd = NULL; historyCount = 0; topObj = botObj = NULL; firstPage = lastPage = curPage = NULL; lastPageNum = 0; InitPage(); savedComments = NULL; savedCommentsLen = 0; } int PushIcon() { struct StkRec *stk_ptr; struct ObjRec *obj_ptr; char sym_name[MAXPATHLENGTH], path_name[MAXPATHLENGTH]; char file_name[MAXPATHLENGTH], *rest; int read_status, short_name; FILE *fp; int tmp_linenum, interrupted, is_pin; char tmp_filename[MAXPATHLENGTH], tmp_filefullpath[MAXPATHLENGTH]; if (gstWBInfo.do_whiteboard) { MsgBox(TgLoadString(STID_PUSH_IN_WB), TOOL_NAME, INFO_MB); return FALSE; } if (topSel == NULL || topSel != botSel || (topSel->obj->type != OBJ_ICON && topSel->obj->type != OBJ_PIN)) { MsgBox(TgLoadString(STID_SEL_ONE_ICON_OBJ_TO_PUSH), TOOL_NAME, INFO_MB); return FALSE; } is_pin = (topSel->obj->type==OBJ_PIN); strcpy(sym_name, topSel->obj->detail.r->s); if (*sym_name == DIR_SEP) { char *psz=UtilStrRChr(sym_name, DIR_SEP), *psz1=sym_name; *psz = '\0'; strcpy(path_name, sym_name); *psz++ = DIR_SEP; while (*psz != '\0') *psz1++ = *psz++; *psz1 = '\0'; } else { if (!GetSymbolPath(sym_name, is_pin, path_name)) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FND_SYM_FILE_IN_PATH), sym_name, is_pin ? PIN_FILE_EXT : SYM_FILE_EXT, curDomainPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } strcat(sym_name, "."); if (is_pin) { strcat(sym_name, PIN_FILE_EXT); } else { strcat(sym_name, SYM_FILE_EXT); } sprintf(file_name, "%s%c%s", path_name, DIR_SEP, sym_name); if ((short_name=IsPrefix(bootDir, file_name, &rest))) ++rest; if ((fp=fopen(file_name, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FOR_READ_PUSH), (short_name ? rest : file_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } strcpy(tmp_filefullpath, scanFileFullPath); strcpy(tmp_filename, scanFileName); tmp_linenum = scanLineNum; UtilStrCpyN(scanFileFullPath, sizeof(scanFileFullPath), file_name); strcpy(scanFileName, (short_name ? rest : file_name)); scanLineNum = 0; HighLightReverse(); stk_ptr = SaveFileInfo(); ResetFileInfo(); if (usePaperSizeStoredInFile) ResetOnePageSize(); topStk = stk_ptr; sprintf(gszMsgBox, TgLoadCachedString(CSTID_PUSHING_INTO_NAMED), (short_name ? rest : file_name)); Msg(gszMsgBox); CleanUpDrawingWindow(); XClearWindow(mainDisplay, drawWindow); somethingHighLighted = FALSE; SetFileModified(FALSE); SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); numRedrawBBox = 0; ShowInterrupt(1); interrupted = FALSE; readingPageNum = loadedCurPageNum = 0; foundGoodStateObject = FALSE; while ((read_status=ReadObj(fp, &obj_ptr)) == TRUE) { if (obj_ptr != NULL) { obj_ptr->tmp_parent = NULL; AdjForOldVersion(obj_ptr); AddObj(NULL, topObj, obj_ptr); if (!interrupted && (PointInBBox(obj_ptr->x, obj_ptr->y, drawWinBBox) || BBoxIntersect(obj_ptr->bbox, drawWinBBox))) { if (!DrawObj(drawWindow, obj_ptr)) interrupted = TRUE; if (CheckInterrupt(TRUE)) interrupted = TRUE; } } } fclose(fp); if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } if (interrupted) Msg(TgLoadString(STID_USER_INTR_ABORT_DRAW)); HideInterrupt(); strcpy(scanFileFullPath, tmp_filefullpath); strcpy(scanFileName, tmp_filename); scanLineNum = tmp_linenum; SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); if (read_status == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FILE_VER_ABORT_PUSH), fileVersion, TOOL_NAME, homePageURL); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); DrawPaperBoundary(drawWindow); RedrawGridLines(drawWindow); return FALSE; } if (loadedCurPageNum > 0 && curPage != NULL) { GotoPageNum(loadedCurPageNum); } CheckFileAttrsInLoad(); strcpy(curFileName, sym_name); strcpy(curSymDir, path_name); curFileDefined = TRUE; if (!curDirIsLocal) { strcpy(curDir, curLocalDir); *curLocalDir = '\0'; curDirIsLocal = TRUE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_CUR_FILE_IS), (short_name ? rest : file_name)); Msg(gszMsgBox); RedrawTitleWindow(); UpdateAllPinnedMenus(); if (!navigatingBackAndForth) CommitNavigate(); return foundGoodStateObject; } void RestoreFileInfo(StkPtr) struct StkRec *StkPtr; { char fname[MAXPATHLENGTH], *rest; fileModified = StkPtr->file_mod; objId = StkPtr->id; CleanUpComments(); CleanUpDrawingWindow(); drawOrigX = StkPtr->orig_x; drawOrigY = StkPtr->orig_y; zoomScale = StkPtr->zoom; zoomedIn = StkPtr->zoomed; gridSystem = StkPtr->grid_system; xyEnglishGrid = StkPtr->english_grid; xyMetricGrid = StkPtr->metric_grid; snapOn = StkPtr->snap_on; colorIndex = StkPtr->color; horiAlign = StkPtr->h_align; vertAlign = StkPtr->v_align; lineWidth = StkPtr->line_w; lineStyle = StkPtr->line_s; transPat = StkPtr->trans_pat; objFill = StkPtr->fill; penPat = StkPtr->pen; textJust = StkPtr->just; textVSpace = StkPtr->v_space; curFont = StkPtr->font; curStyle = StkPtr->f_style; curSzUnit = StkPtr->f_sz_unit; printMag = StkPtr->print_mag; gridShown = StkPtr->grid_shown; moveMode = StkPtr->move_mode; rcbRadius = StkPtr->rcb_radius; curUnderlineOn = StkPtr->underline_on; curUnderlineYOffset = StkPtr->underline_y_offset; curOverlineOn = StkPtr->overline_on; curOverlineYOffset = StkPtr->overline_y_offset; tgifObj->fattr = StkPtr->first_file_attr; tgifObj->lattr = StkPtr->last_file_attr; CleanUpCmds(); firstCmd = StkPtr->first_cmd; lastCmd = StkPtr->last_cmd; curCmd = StkPtr->cur_cmd; historyCount = StkPtr->history_count; firstPage = StkPtr->first_page; lastPage = StkPtr->last_page; curPage = StkPtr->cur_page; curPageNum = StkPtr->cur_page_num; lastPageNum = StkPtr->last_page_num; paperCol = StkPtr->cols; paperRow = StkPtr->rows; pageLayoutMode = StkPtr->page_layout_mode; colorDump = StkPtr->color_dump; onePageWidth = StkPtr->one_page_width; onePageHeight = StkPtr->one_page_height; if (usePaperSizeStoredInFile) SetPSPageWidthHeight(); curPage->top = topObj = StkPtr->first; curPage->bot = botObj = StkPtr->last; strcpy(curDomainName, StkPtr->domain); strcpy(curSymDir, StkPtr->sym_dir); curFileDefined = StkPtr->name_valid; if (curFileDefined) { strcpy(curFileName, StkPtr->name); if (*curSymDir == '\0') { sprintf(fname, "%s%c%s", StkPtr->dir, DIR_SEP, curFileName); } else { sprintf(fname, "%s%c%s", curSymDir, DIR_SEP, curFileName); } if (IsPrefix(bootDir, fname, &rest)) { sprintf(gszMsgBox, TgLoadString(STID_POP_BACK_TO_NAMED), ++rest); } else { sprintf(gszMsgBox, TgLoadString(STID_POP_BACK_TO_NAMED), fname); } if (!deserializingFile) Msg(gszMsgBox); SetCurDir(fname); } else { if (!deserializingFile) Msg(TgLoadString(STID_POP_BACK_TO_PARENT_UNDEF)); } if (strcmp(curDir, StkPtr->dir) != 0) { strcpy(curDir, StkPtr->dir); UpdateDirInfo(); } savedComments = StkPtr->saved_comments; savedCommentsLen = StkPtr->saved_comments_len; ClearBgColorInfo(FALSE); ClearBgPixmapInfo(FALSE); myFileBgPixel = StkPtr->file_bg_pixel; myFileFgPixel = StkPtr->file_fg_pixel; myFileBgColorStr = StkPtr->file_bg_color_str; myFileFgColorStr = StkPtr->file_fg_color_str; myFileBgGifURL = StkPtr->file_bg_gif_url; myFileBgPixmapW = StkPtr->file_bg_pixmap_w; myFileBgPixmapH = StkPtr->file_bg_pixmap_h; myFileBgPixmap = StkPtr->file_bg_pixmap; if (myFileBgColorStr != NULL) { if (!SetFileBgColor()) { ClearBgColorInfo(FALSE); } } else if (myFileBgGifURL != NULL) { if (!SetFileBgPixmap()) { ClearBgColorInfo(FALSE); } } } void PopIcon() { if (topStk == NULL) { MsgBox(TgLoadString(STID_ALREADY_AT_TOP_LEVEL), TOOL_NAME, INFO_MB); return; } while (fileModified) { XBell(mainDisplay, 0); switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_POP), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: SetFileModified(FALSE); break; case MB_ID_CANCEL: return; } } AdjustNavigate(); RestoreFileInfo(topStk); ResetOnePageSize(); topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->next = NULL; topSel->prev = NULL; topSel->obj = topStk->sel; UpdSelBBox(); if (UpdPageStyle(topStk->page_style)) { UpdDrawWinBBox(); AdjSplineVs(); } UpdDrawWinWH(); SetCanvasFont(); RedrawRulers(); RedrawScrollBars(); RedrawChoiceWindow(); RedrawTitleWindow(); UpdDrawWinBBox(); UpdateAllPinnedMenus(); free(topStk); topStk = topStk->next; ClearAndRedrawDrawWindow(); XSync(mainDisplay, True); justDupped = FALSE; } void CleanUpTgifObj() { if (tgifObj != NULL) { DelAllAttrs(tgifObj->fattr); FreeBoxObj(tgifObj); } tgifObj = NULL; } void CleanUpStk() { register struct StkRec *next_stk; for ( ; topStk != NULL; topStk = next_stk) { next_stk = topStk->next; firstPage = topStk->first_page; lastPage = topStk->last_page; CleanUpPage(); free(topStk); } curSymDir[0] = '\0'; CleanUpTgifObj(); } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/dup.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000114425�11602233311�013726� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/dup.c,v 1.13 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_DUP_C_ #include "tgifdefs.h" #include "attr.e" #include "auxtext.e" #include "choice.e" #include "cmd.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "grid.e" #include "mark.e" #include "move.e" #include "msg.e" #include "obj.e" #include "page.e" #include "raster.e" #include "select.e" #include "setup.e" #include "text.e" #include "util.e" #include "xbitmap.e" #include "xpixmap.e" int justDupped = FALSE; int useRecentDupDistance = TRUE; int dupDx = INVALID, dupDy = INVALID; void CopyObjId(FromObjPtr, ToObjPtr) struct ObjRec *FromObjPtr, *ToObjPtr; { register struct ObjRec *from_obj_ptr, *to_obj_ptr; register struct AttrRec *from_attr_ptr, *to_attr_ptr; ToObjPtr->id = FromObjPtr->id; if (FromObjPtr->creator_full_id != NULL) { UtilFree(ToObjPtr->creator_full_id); ToObjPtr->creator_full_id = UtilStrDup(FromObjPtr->creator_full_id); if (ToObjPtr->creator_full_id == NULL) FailAllocMessage(); } switch (FromObjPtr->type) { case OBJ_SYM: case OBJ_GROUP: case OBJ_ICON: case OBJ_PIN: from_obj_ptr = FromObjPtr->detail.r->first; to_obj_ptr = ToObjPtr->detail.r->first; for ( ; from_obj_ptr!=NULL; from_obj_ptr=from_obj_ptr->next, to_obj_ptr=to_obj_ptr->next) { CopyObjId(from_obj_ptr, to_obj_ptr); } break; } from_attr_ptr = FromObjPtr->fattr; to_attr_ptr = ToObjPtr->fattr; for ( ; from_attr_ptr!=NULL; from_attr_ptr=from_attr_ptr->next, to_attr_ptr=to_attr_ptr->next) { CopyObjId(from_attr_ptr->obj, to_attr_ptr->obj); } } void CopyObjLocks(FromObjPtr, ToObjPtr) struct ObjRec *FromObjPtr, *ToObjPtr; { register struct ObjRec *from_obj_ptr, *to_obj_ptr; register struct AttrRec *from_attr_ptr, *to_attr_ptr; ToObjPtr->locked = FromObjPtr->locked; switch (FromObjPtr->type) { case OBJ_SYM: case OBJ_GROUP: case OBJ_ICON: case OBJ_PIN: from_obj_ptr = FromObjPtr->detail.r->first; to_obj_ptr = ToObjPtr->detail.r->first; for ( ; from_obj_ptr!=NULL; from_obj_ptr=from_obj_ptr->next, to_obj_ptr=to_obj_ptr->next) { CopyObjLocks(from_obj_ptr, to_obj_ptr); } break; } from_attr_ptr = FromObjPtr->fattr; to_attr_ptr = ToObjPtr->fattr; for ( ; from_attr_ptr!=NULL; from_attr_ptr=from_attr_ptr->next, to_attr_ptr=to_attr_ptr->next) { CopyObjLocks(from_attr_ptr->obj, to_attr_ptr->obj); } } void UnlockAnObj(ObjPtr) struct ObjRec *ObjPtr; { register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; ObjPtr->locked = FALSE; switch (ObjPtr->type) { case OBJ_SYM: case OBJ_GROUP: case OBJ_ICON: case OBJ_PIN: for (obj_ptr=ObjPtr->detail.r->first; obj_ptr!=NULL; obj_ptr=obj_ptr->next) { UnlockAnObj(obj_ptr); } } for (attr_ptr=ObjPtr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { attr_ptr->obj->locked = FALSE; } } void DupObjXfrmMtrx(FromObjPtr, ToObjPtr) register struct ObjRec *FromObjPtr, *ToObjPtr; { ToObjPtr->ctm = NULL; if (FromObjPtr->ctm == NULL) return; ToObjPtr->ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ToObjPtr->ctm == NULL) FailAllocMessage(); memcpy(ToObjPtr->ctm, FromObjPtr->ctm, sizeof(struct XfrmMtrxRec)); memcpy(&ToObjPtr->orig_obbox,&FromObjPtr->orig_obbox,sizeof(struct BBRec)); } void DupObjBasics(FromObjPtr, ToObjPtr) register struct ObjRec *FromObjPtr, *ToObjPtr; { ToObjPtr->next = ToObjPtr->prev = NULL; ToObjPtr->x = FromObjPtr->x; ToObjPtr->y = FromObjPtr->y; ToObjPtr->color = FromObjPtr->color; ToObjPtr->bg_color = FromObjPtr->bg_color; memcpy(ToObjPtr->color_str, FromObjPtr->color_str, sizeof(ToObjPtr->color_str)); memcpy(ToObjPtr->bg_color_str, FromObjPtr->bg_color_str, sizeof(ToObjPtr->bg_color_str)); ToObjPtr->id = objId++; ToObjPtr->dirty = FALSE; ToObjPtr->rotation = FromObjPtr->rotation; ToObjPtr->type = FromObjPtr->type; ToObjPtr->bbox.ltx = FromObjPtr->bbox.ltx; ToObjPtr->bbox.lty = FromObjPtr->bbox.lty; ToObjPtr->bbox.rbx = FromObjPtr->bbox.rbx; ToObjPtr->bbox.rby = FromObjPtr->bbox.rby; ToObjPtr->obbox.ltx = FromObjPtr->obbox.ltx; ToObjPtr->obbox.lty = FromObjPtr->obbox.lty; ToObjPtr->obbox.rbx = FromObjPtr->obbox.rbx; ToObjPtr->obbox.rby = FromObjPtr->obbox.rby; ToObjPtr->locked = FALSE; ToObjPtr->invisible = FromObjPtr->invisible; ToObjPtr->trans_pat = FromObjPtr->trans_pat; memcpy(&ToObjPtr->orig_obbox, &FromObjPtr->orig_obbox, sizeof(struct BBRec)); memcpy(ToObjPtr->rotated_obbox, FromObjPtr->rotated_obbox, 5*sizeof(XPoint)); DupObjXfrmMtrx(FromObjPtr, ToObjPtr); } void DupPolyObj(PolyPtr, ObjPtr) struct PolyRec *PolyPtr; struct ObjRec *ObjPtr; { register int i, num_pts; register struct PolyRec *poly_ptr; register XPoint *sv; register IntPoint *pv; poly_ptr = (struct PolyRec *)malloc(sizeof(struct PolyRec)); if (poly_ptr == NULL) FailAllocMessage(); memset(poly_ptr, 0, sizeof(struct PolyRec)); num_pts = poly_ptr->n = PolyPtr->n; pv = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); if (PolyPtr->smooth != NULL) { poly_ptr->smooth = (char*)malloc((num_pts+1)*sizeof(char)); if (poly_ptr->smooth == NULL) FailAllocMessage(); } else { poly_ptr->smooth = NULL; } for (i=0; i < num_pts; i++) { pv[i].x = PolyPtr->vlist[i].x; pv[i].y = PolyPtr->vlist[i].y; if (PolyPtr->smooth != NULL && poly_ptr->smooth != NULL) { poly_ptr->smooth[i] = PolyPtr->smooth[i]; } } poly_ptr->vlist = pv; poly_ptr->style = PolyPtr->style; poly_ptr->width = PolyPtr->width; poly_ptr->aw = PolyPtr->aw; poly_ptr->ah = PolyPtr->ah; strcpy(poly_ptr->width_spec, PolyPtr->width_spec); strcpy(poly_ptr->aw_spec, PolyPtr->aw_spec); strcpy(poly_ptr->ah_spec, PolyPtr->ah_spec); poly_ptr->pen = PolyPtr->pen; poly_ptr->fill = PolyPtr->fill; poly_ptr->curved = PolyPtr->curved; if (PolyPtr->sn != 0 && PolyPtr->svlist != NULL) { poly_ptr->sn = num_pts = PolyPtr->sn; sv = (XPoint*)malloc((num_pts+1)*sizeof(XPoint)); if (sv == NULL) FailAllocMessage(); for (i=0; i < num_pts; i++) { sv[i].x = PolyPtr->svlist[i].x; sv[i].y = PolyPtr->svlist[i].y; } poly_ptr->svlist = sv; } else { poly_ptr->sn = 0; poly_ptr->svlist = NULL; } if (PolyPtr->ssn != 0 && PolyPtr->ssvlist != NULL) { poly_ptr->ssn = num_pts = PolyPtr->ssn; pv = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); for (i=0; i < num_pts; i++) { pv[i].x = PolyPtr->ssvlist[i].x; pv[i].y = PolyPtr->ssvlist[i].y; } poly_ptr->ssvlist = pv; } else { poly_ptr->ssn = 0; poly_ptr->ssvlist = NULL; } if (PolyPtr->ssmooth != NULL && PolyPtr->ssvlist != NULL) { num_pts = PolyPtr->ssn; poly_ptr->ssmooth = (char*)malloc((num_pts+1)*sizeof(char)); if (poly_ptr->ssmooth == NULL) FailAllocMessage(); memcpy(poly_ptr->ssmooth, PolyPtr->ssmooth, num_pts*sizeof(char)); poly_ptr->ssmooth[num_pts] = FALSE; } else { poly_ptr->ssmooth = NULL; } if (PolyPtr->curved == LT_INTSPLINE && PolyPtr->intn != 0 && PolyPtr->intvlist != NULL) { poly_ptr->intn = num_pts = PolyPtr->intn; pv = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); for (i=0; i < num_pts; i++) { pv[i].x = PolyPtr->intvlist[i].x; pv[i].y = PolyPtr->intvlist[i].y; } poly_ptr->intvlist = pv; } else { poly_ptr->intn = 0; poly_ptr->intvlist = NULL; } poly_ptr->dash = PolyPtr->dash; if (ObjPtr->ctm != NULL && PolyPtr->rotated_n != 0 && PolyPtr->rotated_vlist != NULL) { poly_ptr->rotated_n = num_pts = PolyPtr->rotated_n; sv = (XPoint*)malloc((num_pts+1)*sizeof(XPoint)); if (sv == NULL) FailAllocMessage(); for (i=0; i < num_pts; i++) { sv[i].x = PolyPtr->rotated_vlist[i].x; sv[i].y = PolyPtr->rotated_vlist[i].y; } poly_ptr->rotated_vlist = sv; } else { poly_ptr->rotated_n = 0; poly_ptr->rotated_vlist = NULL; } /* * Need to check for pins. * Need to handle the case where connection objects need to be dupped! */ poly_ptr->start_conn = poly_ptr->end_conn = NULL; ObjPtr->detail.p = poly_ptr; } void DupPolygonObj(PolygonPtr, ObjPtr) struct PolygonRec *PolygonPtr; struct ObjRec *ObjPtr; { register int i, num_pts; register struct PolygonRec *polygon_ptr; XPoint *sv; IntPoint *pv; polygon_ptr = (struct PolygonRec *)malloc(sizeof(struct PolygonRec)); if (polygon_ptr == NULL) FailAllocMessage(); memset(polygon_ptr, 0, sizeof(struct PolygonRec)); num_pts = polygon_ptr->n = PolygonPtr->n; pv = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); if (PolygonPtr->smooth != NULL) { polygon_ptr->smooth = (char*)malloc((num_pts+1)*sizeof(char)); if (polygon_ptr->smooth == NULL) FailAllocMessage(); } else { polygon_ptr->smooth = NULL; } for (i=0; i < num_pts; i++) { pv[i].x = PolygonPtr->vlist[i].x; pv[i].y = PolygonPtr->vlist[i].y; if (PolygonPtr->smooth != NULL && polygon_ptr->smooth != NULL) { polygon_ptr->smooth[i] = PolygonPtr->smooth[i]; } } polygon_ptr->vlist = pv; polygon_ptr->fill = PolygonPtr->fill; polygon_ptr->width = PolygonPtr->width; strcpy(polygon_ptr->width_spec, PolygonPtr->width_spec); polygon_ptr->pen = PolygonPtr->pen; polygon_ptr->curved = PolygonPtr->curved; if (PolygonPtr->sn != 0 && PolygonPtr->svlist != NULL) { polygon_ptr->sn = num_pts = PolygonPtr->sn; sv = (XPoint*)malloc((num_pts+1)*sizeof(XPoint)); if (sv == NULL) FailAllocMessage(); for (i=0; i < num_pts; i++) { sv[i].x = PolygonPtr->svlist[i].x; sv[i].y = PolygonPtr->svlist[i].y; } polygon_ptr->svlist = sv; } else { polygon_ptr->sn = 0; polygon_ptr->svlist = NULL; } if (PolygonPtr->ssn != 0 && PolygonPtr->ssvlist != NULL) { polygon_ptr->ssn = num_pts = PolygonPtr->ssn; pv = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); for (i=0; i < num_pts; i++) { pv[i].x = PolygonPtr->ssvlist[i].x; pv[i].y = PolygonPtr->ssvlist[i].y; } polygon_ptr->ssvlist = pv; } else { polygon_ptr->ssn = 0; polygon_ptr->ssvlist = NULL; } if (PolygonPtr->ssmooth != NULL && PolygonPtr->ssvlist != NULL) { num_pts = PolygonPtr->ssn; polygon_ptr->ssmooth = (char*)malloc((num_pts+1)*sizeof(char)); if (polygon_ptr->ssmooth == NULL) FailAllocMessage(); memcpy(polygon_ptr->ssmooth, PolygonPtr->ssmooth, num_pts*sizeof(char)); polygon_ptr->ssmooth[num_pts] = FALSE; } else { polygon_ptr->ssmooth = NULL; } if (PolygonPtr->curved == LT_INTSPLINE && PolygonPtr->intn != 0 && PolygonPtr->intvlist != NULL) { polygon_ptr->intn = num_pts = PolygonPtr->intn; pv = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); for (i=0; i < num_pts; i++) { pv[i].x = PolygonPtr->intvlist[i].x; pv[i].y = PolygonPtr->intvlist[i].y; } polygon_ptr->intvlist = pv; } else { polygon_ptr->intn = 0; polygon_ptr->intvlist = NULL; } polygon_ptr->dash = PolygonPtr->dash; if (ObjPtr->ctm != NULL && PolygonPtr->rotated_n != 0 && PolygonPtr->rotated_vlist != NULL) { polygon_ptr->rotated_n = num_pts = PolygonPtr->rotated_n; sv = (XPoint*)malloc((num_pts+1)*sizeof(XPoint)); if (sv == NULL) FailAllocMessage(); for (i=0; i < num_pts; i++) { sv[i].x = PolygonPtr->rotated_vlist[i].x; sv[i].y = PolygonPtr->rotated_vlist[i].y; } polygon_ptr->rotated_vlist = sv; } else { polygon_ptr->rotated_n = 0; polygon_ptr->rotated_vlist = NULL; } ObjPtr->detail.g = polygon_ptr; } void DupOvalObj(OvalPtr, ObjPtr) struct OvalRec *OvalPtr; struct ObjRec *ObjPtr; { register struct OvalRec *oval_ptr; oval_ptr = (struct OvalRec *)malloc(sizeof(struct OvalRec)); if (oval_ptr == NULL) FailAllocMessage(); memset(oval_ptr, 0, sizeof(struct OvalRec)); oval_ptr->fill = OvalPtr->fill; oval_ptr->width = OvalPtr->width; strcpy(oval_ptr->width_spec, OvalPtr->width_spec); oval_ptr->pen = OvalPtr->pen; oval_ptr->dash = OvalPtr->dash; if (ObjPtr->ctm != NULL && OvalPtr->rotated_n != 0 && OvalPtr->rotated_vlist != NULL) { int i, num_pts; XPoint *v; oval_ptr->rotated_n = num_pts = OvalPtr->rotated_n; v = (XPoint*)malloc((num_pts+1)*sizeof(XPoint)); if (v == NULL) FailAllocMessage(); for (i=0; i < num_pts; i++) { v[i].x = OvalPtr->rotated_vlist[i].x; v[i].y = OvalPtr->rotated_vlist[i].y; } oval_ptr->rotated_vlist = v; } else { oval_ptr->rotated_n = 0; oval_ptr->rotated_vlist = NULL; } ObjPtr->detail.o = oval_ptr; } void DupBoxObj(BoxPtr, ObjPtr) struct BoxRec *BoxPtr; struct ObjRec *ObjPtr; { register struct BoxRec *box_ptr; box_ptr = (struct BoxRec *)malloc(sizeof(struct BoxRec)); if (box_ptr == NULL) FailAllocMessage(); memset(box_ptr, 0, sizeof(struct BoxRec)); box_ptr->fill = BoxPtr->fill; box_ptr->width = BoxPtr->width; strcpy(box_ptr->width_spec, BoxPtr->width_spec); box_ptr->pen = BoxPtr->pen; box_ptr->dash = BoxPtr->dash; ObjPtr->detail.b = box_ptr; } void DupRCBoxObj(RCBoxPtr, ObjPtr) struct RCBoxRec *RCBoxPtr; struct ObjRec *ObjPtr; { register struct RCBoxRec *rcbox_ptr; rcbox_ptr = (struct RCBoxRec *)malloc(sizeof(struct RCBoxRec)); if (rcbox_ptr == NULL) FailAllocMessage(); memset(rcbox_ptr, 0, sizeof(struct RCBoxRec)); rcbox_ptr->fill = RCBoxPtr->fill; rcbox_ptr->width = RCBoxPtr->width; strcpy(rcbox_ptr->width_spec, RCBoxPtr->width_spec); rcbox_ptr->pen = RCBoxPtr->pen; rcbox_ptr->dash = RCBoxPtr->dash; rcbox_ptr->radius = RCBoxPtr->radius; if (ObjPtr->ctm != NULL && RCBoxPtr->rotated_n != 0 && RCBoxPtr->rotated_vlist != NULL) { int i, num_pts; XPoint *v; rcbox_ptr->rotated_n = num_pts = RCBoxPtr->rotated_n; v = (XPoint*)malloc((num_pts+1)*sizeof(XPoint)); if (v == NULL) FailAllocMessage(); for (i=0; i < num_pts; i++) { v[i].x = RCBoxPtr->rotated_vlist[i].x; v[i].y = RCBoxPtr->rotated_vlist[i].y; } rcbox_ptr->rotated_vlist = v; } else { rcbox_ptr->rotated_n = 0; rcbox_ptr->rotated_vlist = NULL; } ObjPtr->detail.rcb = rcbox_ptr; } void DupArcObj(ArcPtr, ObjPtr) struct ArcRec *ArcPtr; struct ObjRec *ObjPtr; { register struct ArcRec *arc_ptr; arc_ptr = (struct ArcRec *)malloc(sizeof(struct ArcRec)); if (arc_ptr == NULL) FailAllocMessage(); memset(arc_ptr, 0, sizeof(struct ArcRec)); arc_ptr->fill = ArcPtr->fill; arc_ptr->width = ArcPtr->width; arc_ptr->aw = ArcPtr->aw; arc_ptr->ah = ArcPtr->ah; strcpy(arc_ptr->width_spec, ArcPtr->width_spec); strcpy(arc_ptr->aw_spec, ArcPtr->aw_spec); strcpy(arc_ptr->ah_spec, ArcPtr->ah_spec); arc_ptr->pen = ArcPtr->pen; arc_ptr->dash = ArcPtr->dash; arc_ptr->style = ArcPtr->style; arc_ptr->xc = ArcPtr->xc; arc_ptr->yc = ArcPtr->yc; arc_ptr->x1 = ArcPtr->x1; arc_ptr->y1 = ArcPtr->y1; arc_ptr->x2 = ArcPtr->x2; arc_ptr->y2 = ArcPtr->y2; arc_ptr->dir = ArcPtr->dir; arc_ptr->ltx = ArcPtr->ltx; arc_ptr->lty = ArcPtr->lty; arc_ptr->w = ArcPtr->w; arc_ptr->h = ArcPtr->h; arc_ptr->angle1 = ArcPtr->angle1; arc_ptr->angle2 = ArcPtr->angle2; arc_ptr->a_angle1 = ArcPtr->a_angle1; arc_ptr->a_angle2 = ArcPtr->a_angle2; if (ObjPtr->ctm != NULL && ArcPtr->rotated_n != 0 && ArcPtr->rotated_vlist != NULL) { int i, num_pts; XPoint *v; arc_ptr->rotated_n = num_pts = ArcPtr->rotated_n; v = (XPoint*)malloc((num_pts+2)*sizeof(XPoint)); if (v == NULL) FailAllocMessage(); for (i=0; i < num_pts+2; i++) { v[i].x = ArcPtr->rotated_vlist[i].x; v[i].y = ArcPtr->rotated_vlist[i].y; } arc_ptr->rotated_vlist = v; } else { arc_ptr->rotated_n = 0; arc_ptr->rotated_vlist = NULL; } ObjPtr->detail.a = arc_ptr; } void DupXBmObj(XBmPtr, ObjPtr) struct XBmRec *XBmPtr; struct ObjRec *ObjPtr; { register struct XBmRec *xbm_ptr; register int i; Pixmap bitmap, cached_bitmap; int w, h, image_w, image_h; xbm_ptr = (struct XBmRec *)malloc(sizeof(struct XBmRec)); if (xbm_ptr == NULL) FailAllocMessage(); memset(xbm_ptr, 0, sizeof(struct XBmRec)); ObjPtr->detail.xbm = xbm_ptr; xbm_ptr->image = NULL; xbm_ptr->data = NULL; xbm_ptr->fill = XBmPtr->fill; xbm_ptr->image_w = image_w = XBmPtr->image_w; xbm_ptr->image_h = image_h = XBmPtr->image_h; xbm_ptr->flip = XBmPtr->flip; xbm_ptr->cached_zoom = XBmPtr->cached_zoom; xbm_ptr->cached_zoomed = XBmPtr->cached_zoomed; xbm_ptr->cached_flip = XBmPtr->cached_flip; xbm_ptr->cached_w = XBmPtr->cached_w; xbm_ptr->cached_h = XBmPtr->cached_h; xbm_ptr->eps_w = XBmPtr->eps_w; xbm_ptr->eps_h = XBmPtr->eps_h; xbm_ptr->bitmap = None; xbm_ptr->cached_bitmap = None; *xbm_ptr->write_date = '\0'; xbm_ptr->save_epsf = XBmPtr->save_epsf; xbm_ptr->real_type = XBmPtr->real_type; if (ObjPtr->ctm != NULL) { memcpy(&xbm_ptr->cached_ctm, &XBmPtr->cached_ctm, sizeof(struct XfrmMtrxRec)); } if (XBmPtr->real_type==XBM_XBM || (XBmPtr->real_type==XBM_EPS && XBmPtr->bitmap!=None)) { bitmap = XCreatePixmap(mainDisplay, mainWindow, image_w, image_h, 1); if (bitmap == None) { FailAllocBitmapMessage(image_w, image_h); return; } XCopyArea(mainDisplay, XBmPtr->bitmap, bitmap, xbmGC, 0, 0, image_w, image_h, 0, 0); xbm_ptr->bitmap = bitmap; if (XBmPtr->cached_bitmap != None) { w = ZOOMED_SIZE(ObjPtr->obbox.rbx - ObjPtr->obbox.ltx); h = ZOOMED_SIZE(ObjPtr->obbox.rby - ObjPtr->obbox.lty); cached_bitmap = XCreatePixmap(mainDisplay, mainWindow, w, h, 1); if (cached_bitmap == None) { FailAllocBitmapMessage(w, h); return; } XCopyArea(mainDisplay, XBmPtr->cached_bitmap, cached_bitmap, xbmGC, 0, 0, w, h, 0, 0); xbm_ptr->cached_bitmap = cached_bitmap; } } if (XBmPtr->real_type == XBM_EPS) { int len=strlen(XBmPtr->filename); int num_epsf_lines=XBmPtr->num_epsf_lines; xbm_ptr->llx = XBmPtr->llx; xbm_ptr->lly = XBmPtr->lly; xbm_ptr->urx = XBmPtr->urx; xbm_ptr->ury = XBmPtr->ury; xbm_ptr->filename = (char*)malloc((len+1)*sizeof(char)); if (xbm_ptr->filename == NULL) FailAllocMessage(); strcpy(xbm_ptr->filename, XBmPtr->filename); strcpy(xbm_ptr->write_date, XBmPtr->write_date); if (num_epsf_lines > 0) { xbm_ptr->num_epsf_lines = num_epsf_lines; xbm_ptr->epsflines = (char**)malloc(num_epsf_lines*sizeof(char*)); if (xbm_ptr->epsflines == NULL) FailAllocMessage(); for (i=0; i < num_epsf_lines; i++) { len = strlen(XBmPtr->epsflines[i]); xbm_ptr->epsflines[i] = (char*)malloc((len+1)*sizeof(char)); if (xbm_ptr->epsflines[i] == NULL) FailAllocMessage(); strcpy(xbm_ptr->epsflines[i], XBmPtr->epsflines[i]); } } } } void DupXPmObj(XPmPtr, ObjPtr) struct XPmRec *XPmPtr; struct ObjRec *ObjPtr; { register struct XPmRec *xpm_ptr=NULL; Pixmap pixmap=None, bitmap=None, cached_pixmap=None, cached_bitmap=None; int w=0, h=0, ncolors=0, image_w=0, image_h=0; xpm_ptr = (struct XPmRec *)malloc(sizeof(struct XPmRec)); if (xpm_ptr == NULL) FailAllocMessage(); memset(xpm_ptr, 0, sizeof(struct XPmRec)); ObjPtr->detail.xpm = xpm_ptr; xpm_ptr->image = NULL; xpm_ptr->bitmap_image = NULL; xpm_ptr->data = NULL; xpm_ptr->fill = XPmPtr->fill; xpm_ptr->image_w = image_w = XPmPtr->image_w; xpm_ptr->image_h = image_h = XPmPtr->image_h; xpm_ptr->flip = XPmPtr->flip; xpm_ptr->cached_zoom = XPmPtr->cached_zoom; xpm_ptr->cached_zoomed = XPmPtr->cached_zoomed; xpm_ptr->cached_flip = XPmPtr->cached_flip; xpm_ptr->cached_w = XPmPtr->cached_w; xpm_ptr->cached_h = XPmPtr->cached_h; xpm_ptr->cached_color = (-1); xpm_ptr->pixmap = None; xpm_ptr->bitmap = None; xpm_ptr->cached_pixmap = None; xpm_ptr->cached_bitmap = None; xpm_ptr->clip_mask = None; xpm_ptr->real_type = XPmPtr->real_type; xpm_ptr->linked_jpeg = FALSE; xpm_ptr->filename = NULL; if (xpm_ptr->real_type == XPM_JPEG) { xpm_ptr->linked_jpeg = XPmPtr->linked_jpeg; if (XPmPtr->filename != NULL) { xpm_ptr->filename = UtilStrDup(XPmPtr->filename); if (xpm_ptr->filename == NULL) FailAllocMessage(); } } else if (xpm_ptr->real_type == PPM_TRUE) { xpm_ptr->ppm_data_compress = XPmPtr->ppm_data_compress; if (xpm_ptr->ppm_data_compress == PPM_JPEG_COMPRESS || xpm_ptr->ppm_data_compress == PPM_DATA_DEFLATED) { xpm_ptr->ppm_mask_size = XPmPtr->ppm_mask_size; if (xpm_ptr->ppm_mask_size > 0) { xpm_ptr->ppm_mask_data = (char*)malloc(xpm_ptr->ppm_mask_size); if (xpm_ptr->ppm_mask_data == NULL) FailAllocMessage(); memcpy(xpm_ptr->ppm_mask_data, XPmPtr->ppm_mask_data, xpm_ptr->ppm_mask_size); } xpm_ptr->ppm_data_size = XPmPtr->ppm_data_size; xpm_ptr->ppm_data = (char*)malloc(xpm_ptr->ppm_data_size); if (xpm_ptr->ppm_data == NULL) FailAllocMessage(); memcpy(xpm_ptr->ppm_data, XPmPtr->ppm_data, xpm_ptr->ppm_data_size); xpm_ptr->has_transparent_color = XPmPtr->has_transparent_color; memcpy(xpm_ptr->transparent_color, XPmPtr->transparent_color, sizeof(xpm_ptr->transparent_color)); } } if (ObjPtr->ctm != NULL) { memcpy(&xpm_ptr->cached_ctm, &XPmPtr->cached_ctm, sizeof(struct XfrmMtrxRec)); } pixmap = XCreatePixmap(mainDisplay,mainWindow,image_w,image_h,mainDepth); if (pixmap == None) { FailAllocPixmapMessage(image_w, image_h); return; } XCopyArea(mainDisplay,XPmPtr->pixmap,pixmap,xpmGC,0,0,image_w,image_h,0,0); xpm_ptr->pixmap = pixmap; bitmap = XCreatePixmap(mainDisplay,mainWindow,image_w,image_h,1); if (bitmap == None) { FailAllocBitmapMessage(image_w, image_h); return; } XCopyArea(mainDisplay,XPmPtr->bitmap,bitmap,xbmGC,0,0,image_w,image_h,0,0); xpm_ptr->bitmap = bitmap; w = ZOOMED_SIZE(ObjPtr->obbox.rbx - ObjPtr->obbox.ltx); h = ZOOMED_SIZE(ObjPtr->obbox.rby - ObjPtr->obbox.lty); if (XPmPtr->cached_pixmap != None) { cached_pixmap = XCreatePixmap(mainDisplay, mainWindow, w, h, mainDepth); if (cached_pixmap == None) { FailAllocPixmapMessage(w, h); return; } XCopyArea(mainDisplay, XPmPtr->cached_pixmap, cached_pixmap, xpmGC, 0, 0, w, h, 0, 0); xpm_ptr->cached_pixmap = cached_pixmap; } if (XPmPtr->cached_bitmap != None) { cached_bitmap = XCreatePixmap(mainDisplay, mainWindow, w, h, 1); if (cached_bitmap == None) { FailAllocBitmapMessage(w, h); return; } XCopyArea(mainDisplay, XPmPtr->cached_bitmap, cached_bitmap, xbmGC, 0, 0, w, h, 0, 0); xpm_ptr->cached_bitmap = cached_bitmap; } ncolors = xpm_ptr->ncolors = XPmPtr->ncolors; if (xpm_ptr->real_type != PPM_TRUE) { int i=0, *pixels=NULL, chars_per_pixel=0; char *color_char=NULL, **color_str=NULL; chars_per_pixel = xpm_ptr->chars_per_pixel = XPmPtr->chars_per_pixel; xpm_ptr->first_pixel_is_bg = XPmPtr->first_pixel_is_bg; color_char = xpm_ptr->color_char = (char*)malloc(ncolors*chars_per_pixel*sizeof(char)); color_str = xpm_ptr->color_str = (char**)malloc(ncolors*sizeof(char*)); pixels = xpm_ptr->pixels = (int*)malloc(ncolors*sizeof(int)); if (color_char==NULL || color_str==NULL || pixels==NULL) { FailAllocMessage(); } for (i=0; i < ncolors; i++) { int j=0, len=0; for (j=0; j < chars_per_pixel; j++) { color_char[i*chars_per_pixel+j] = XPmPtr->color_char[i*chars_per_pixel+j]; } pixels[i] = XPmPtr->pixels[i]; len = strlen(XPmPtr->color_str[i]); color_str[i] = (char*)malloc((len+1)*sizeof(char)); if (color_str[i] == NULL) FailAllocMessage(); strcpy(color_str[i], XPmPtr->color_str[i]); } } xpm_ptr->red = xpm_ptr->green = xpm_ptr->blue = NULL; if (ObjPtr->ctm != NULL && XPmPtr->clip_mask != None) { w = ZOOMED_SIZE(ObjPtr->obbox.rbx - ObjPtr->obbox.ltx); h = ZOOMED_SIZE(ObjPtr->obbox.rby - ObjPtr->obbox.lty); pixmap = XCreatePixmap(mainDisplay, mainWindow, w, h, 1); if (pixmap == None) { FailAllocBitmapMessage(w, h); return; } XCopyArea(mainDisplay, XPmPtr->clip_mask, pixmap, xbmGC, 0, 0, w, h, 0, 0); xpm_ptr->clip_mask = pixmap; } } void DupStrSeg(pToStrBlock, pFromStrSeg) StrBlockInfo *pToStrBlock; StrSegInfo *pFromStrSeg; /* pToStrBlock->type is either SB_SIMPLE or SB_SUPSUB_CENTER */ /* pToStrBlock->seg is the newly created string segment */ { StrSegInfo *str_seg=(StrSegInfo*)malloc(sizeof(StrSegInfo)); if (str_seg == NULL) FailAllocMessage(); memcpy(str_seg, pFromStrSeg, sizeof(StrSegInfo)); if (PRTGIF && pFromStrSeg->font_name != NULL && *pFromStrSeg->font_name != '\0') { /* * this should never happen anyway (because DupStrSeg() is never called * in PRTGIF) */ str_seg->font_name = UtilStrDup(pFromStrSeg->font_name); if (str_seg->font_name == NULL) FailAllocMessage(); } str_seg->dyn_str.s = NULL; str_seg->dyn_str.sz = 0; DynStrCpy(&str_seg->dyn_str, &pFromStrSeg->dyn_str); str_seg->owner = pToStrBlock; pToStrBlock->seg = str_seg; } void DupStrBlock(pStrBlock, pMiniLineOwner, ppFirstStrBlock, ppLastStrBlock) StrBlockInfo *pStrBlock, **ppFirstStrBlock, **ppLastStrBlock; MiniLineInfo *pMiniLineOwner; { StrBlockInfo *str_block=(StrBlockInfo*)malloc(sizeof(StrBlockInfo)); if (str_block == NULL) FailAllocMessage(); memcpy(str_block, pStrBlock, sizeof(StrBlockInfo)); str_block->seg = NULL; str_block->sup = str_block->sub = NULL; str_block->owner_mini_line = pMiniLineOwner; str_block->next = NULL; str_block->prev = (*ppLastStrBlock); if ((*ppLastStrBlock) == NULL) { (*ppFirstStrBlock) = str_block; } else { (*ppLastStrBlock)->next = str_block; } (*ppLastStrBlock) = str_block; switch (pStrBlock->type) { case SB_SIMPLE: DupStrSeg(str_block, pStrBlock->seg); break; case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) { DupMiniLines(pStrBlock->sup, str_block, &str_block->sup); } if (pStrBlock->sub != NULL) { DupMiniLines(pStrBlock->sub, str_block, &str_block->sub); } if (pStrBlock->type == SB_SUPSUB_CENTER) { DupStrSeg(str_block, pStrBlock->seg); } break; } } void DupMiniLine(pMiniLine, pOwnerMiniLines, pOwnerBlock, ppFirstMiniLine, ppLastMiniLine) MiniLineInfo *pMiniLine, **ppFirstMiniLine, **ppLastMiniLine; MiniLinesInfo *pOwnerMiniLines; StrBlockInfo *pOwnerBlock; { MiniLineInfo *new_mini_line=(MiniLineInfo*)malloc(sizeof(MiniLineInfo)); StrBlockInfo *pStrBlock=NULL; if (new_mini_line == NULL) FailAllocMessage(); memcpy(new_mini_line, pMiniLine, sizeof(MiniLineInfo)); new_mini_line->first_block = new_mini_line->last_block = NULL; new_mini_line->owner_minilines = pOwnerMiniLines; new_mini_line->next = NULL; new_mini_line->prev = (*ppLastMiniLine); if ((*ppLastMiniLine) == NULL) { (*ppFirstMiniLine) = new_mini_line; } else { (*ppLastMiniLine)->next = new_mini_line; } (*ppLastMiniLine) = new_mini_line; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { DupStrBlock(pStrBlock, new_mini_line, &new_mini_line->first_block, &new_mini_line->last_block); } } void DupMiniLines(minilines, pOwnerBlock, ppMinilines) MiniLinesInfo *minilines, **ppMinilines; StrBlockInfo *pOwnerBlock; { MiniLinesInfo *new_minilines=(MiniLinesInfo*)malloc(sizeof(MiniLinesInfo)); MiniLineInfo *pMiniLine=NULL, *pFirstMiniLine=NULL, *pLastMiniLine=NULL; if (new_minilines == NULL) FailAllocMessage(); memcpy(new_minilines, minilines, sizeof(MiniLinesInfo)); new_minilines->first = new_minilines->last = NULL; new_minilines->owner_block = pOwnerBlock; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { DupMiniLine(pMiniLine, new_minilines, pOwnerBlock, &pFirstMiniLine, &pLastMiniLine); } new_minilines->first = pFirstMiniLine; new_minilines->last = pLastMiniLine; if (ppMinilines != NULL) { *ppMinilines = new_minilines; } } void DupTextObj(TextPtr, FromObjPtr, ToObjPtr) struct TextRec *TextPtr; struct ObjRec *FromObjPtr, *ToObjPtr; { struct TextRec *text_ptr=NULL; MiniLinesInfo *minilines=NULL; MiniLineInfo *pMiniLine=NULL; text_ptr = (struct TextRec *)malloc(sizeof(struct TextRec)); if (text_ptr == NULL) FailAllocMessage(); memcpy(text_ptr, TextPtr, sizeof(struct TextRec)); text_ptr->attr = NULL; text_ptr->cached_bitmap = None; text_ptr->cached_pixmap = None; text_ptr->cached_bg_bitmap = None; ToObjPtr->detail.t = text_ptr; if (TextPtr->cached_bitmap != None) { int w=ZOOMED_SIZE(FromObjPtr->bbox.rbx - FromObjPtr->bbox.ltx - 2); int h=ZOOMED_SIZE(FromObjPtr->bbox.rby - FromObjPtr->bbox.lty - 2); if (w == 0) w = 1; if (h == 0) h = 1; text_ptr->cached_bitmap = XCreatePixmap(mainDisplay,mainWindow,w,h,1); if (text_ptr->cached_bitmap == None) { FailAllocBitmapMessage(w, h); return; } XCopyArea(mainDisplay, TextPtr->cached_bitmap, text_ptr->cached_bitmap, rotateGC, 0, 0, w, h, 0, 0); } if (TextPtr->cached_bg_bitmap != None) { int w=ZOOMED_SIZE(FromObjPtr->bbox.rbx - FromObjPtr->bbox.ltx - 2); int h=ZOOMED_SIZE(FromObjPtr->bbox.rby - FromObjPtr->bbox.lty - 2); if (w == 0) w = 1; if (h == 0) h = 1; text_ptr->cached_bg_bitmap = XCreatePixmap(mainDisplay,mainWindow,w,h,1); if (text_ptr->cached_bg_bitmap == None) { FailAllocBitmapMessage(w, h); return; } XCopyArea(mainDisplay, TextPtr->cached_bg_bitmap, text_ptr->cached_bg_bitmap, rotateGC, 0, 0, w, h, 0, 0); } if (TextPtr->cached_pixmap != None) { int w=ZOOMED_SIZE(FromObjPtr->bbox.rbx - FromObjPtr->bbox.ltx - 2); int h=ZOOMED_SIZE(FromObjPtr->bbox.rby - FromObjPtr->bbox.lty - 2); if (w == 0) w = 1; if (h == 0) h = 1; text_ptr->cached_pixmap = XCreatePixmap(mainDisplay, mainWindow, w, h, mainDepth); if (text_ptr->cached_pixmap == None) { FailAllocBitmapMessage(w, h); return; } XCopyArea(mainDisplay, TextPtr->cached_pixmap, text_ptr->cached_pixmap, xpmGC, 0, 0, w, h, 0, 0); } DupMiniLines(&FromObjPtr->detail.t->minilines, NULL, &minilines); memcpy(&text_ptr->minilines, minilines, sizeof(MiniLinesInfo)); free(minilines); minilines = (&text_ptr->minilines); for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { pMiniLine->owner_minilines = minilines; } } void DupConnection(FromConnPtr, ToConnPtr) struct ConnRec *FromConnPtr, *ToConnPtr; { } void DupGroupObj(GroupPtr, ObjPtr) struct GroupRec *GroupPtr; struct ObjRec *ObjPtr; { register struct GroupRec *group_ptr; struct ObjRec *top_obj; struct ObjRec *from_obj_ptr, *to_obj_ptr; group_ptr = (struct GroupRec *)malloc(sizeof(struct GroupRec)); if (group_ptr == NULL) FailAllocMessage(); memset(group_ptr, 0, sizeof(struct GroupRec)); top_obj = NULL; from_obj_ptr = GroupPtr->last; for ( ; from_obj_ptr != NULL; from_obj_ptr=from_obj_ptr->prev) { to_obj_ptr = DupObj(from_obj_ptr); to_obj_ptr->next = top_obj; if (top_obj == NULL) { group_ptr->last = to_obj_ptr; } else { top_obj->prev = to_obj_ptr; } top_obj = to_obj_ptr; } top_obj->prev = NULL; group_ptr->first = top_obj; ObjPtr->detail.r = group_ptr; } struct ObjRec *DupObj(ObjPtr) struct ObjRec *ObjPtr; { struct ObjRec *obj_ptr; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); DupObjBasics(ObjPtr, obj_ptr); switch (ObjPtr->type) { case OBJ_POLY: DupPolyObj(ObjPtr->detail.p, obj_ptr); DupAttrs(ObjPtr, obj_ptr); break; case OBJ_BOX: DupBoxObj(ObjPtr->detail.b, obj_ptr); DupAttrs(ObjPtr, obj_ptr); break; case OBJ_OVAL: DupOvalObj(ObjPtr->detail.o, obj_ptr); DupAttrs(ObjPtr, obj_ptr); break; case OBJ_TEXT: DupTextObj(ObjPtr->detail.t, ObjPtr, obj_ptr); break; case OBJ_POLYGON: DupPolygonObj(ObjPtr->detail.g, obj_ptr); DupAttrs(ObjPtr, obj_ptr); break; case OBJ_ARC: DupArcObj(ObjPtr->detail.a, obj_ptr); DupAttrs(ObjPtr, obj_ptr); break; case OBJ_RCBOX: DupRCBoxObj(ObjPtr->detail.rcb, obj_ptr); DupAttrs(ObjPtr, obj_ptr); break; case OBJ_XBM: DupXBmObj(ObjPtr->detail.xbm, obj_ptr); DupAttrs(ObjPtr, obj_ptr); break; case OBJ_XPM: DupXPmObj(ObjPtr->detail.xpm, obj_ptr); DupAttrs(ObjPtr, obj_ptr); break; case OBJ_SYM: case OBJ_GROUP: case OBJ_ICON: case OBJ_PIN: DupGroupObj(ObjPtr->detail.r, obj_ptr); DupAttrs(ObjPtr, obj_ptr); if (obj_ptr->type == OBJ_ICON || obj_ptr->type == OBJ_PIN) { strcpy(obj_ptr->detail.r->s, ObjPtr->detail.r->s); obj_ptr->detail.r->rotate = ObjPtr->detail.r->rotate; obj_ptr->detail.r->flip = ObjPtr->detail.r->flip; obj_ptr->detail.r->deck_index = (-1); /* * Need to check for pins. * Need to handle the case where connection objects need to be dupped! */ obj_ptr->detail.r->pin_connected = 0; obj_ptr->detail.r->first_conn = obj_ptr->detail.r->last_conn = NULL; } break; } return obj_ptr; } void DupSelObj() { struct SelRec *sel_ptr, *sel_ptr1; struct ObjRec *obj_ptr, *top_obj, *bot_obj; int dx=0, dy=0; if (topSel==NULL || curChoice==VERTEXMODE) return; /* * Need to check for pins. * Need to handle the case where connection objects need to be dupped! */ top_obj = bot_obj = NULL; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { obj_ptr = DupObj(sel_ptr->obj); obj_ptr->next = top_obj; if (top_obj == NULL) { bot_obj = obj_ptr; } else { top_obj->prev = obj_ptr; } top_obj = obj_ptr; } top_obj->prev = NULL; HighLightReverse(); sel_ptr = botSel; sel_ptr1 = sel_ptr->prev; for (obj_ptr=bot_obj; sel_ptr1 != NULL; obj_ptr=obj_ptr->prev) { sel_ptr->obj = obj_ptr; sel_ptr = sel_ptr1; sel_ptr1 = sel_ptr1->prev; } sel_ptr->obj = obj_ptr; bot_obj->next = topObj; topObj->prev = bot_obj; curPage->top = topObj = top_obj; if (justDupped && useRecentDupDistance) { dx = dupDx; dy = dupDy; } else { switch (gridSystem) { case ENGLISH_GRID: if (snapOn) { dupDx = dupDy = dx = dy = GRID_ABS_SIZE(xyEnglishGrid); } else { dupDx = dupDy = dx = dy = GRID_ABS_SIZE(DEFAULT_ENGLISH_GRID); } break; case METRIC_GRID: if (snapOn) { dupDx = dupDy = dx = dy = GRID_ABS_SIZE(xyMetricGrid); } else { dupDx = dupDy = dx = dy = GRID_ABS_SIZE(DEFAULT_METRIC_GRID); } break; } justDupped = TRUE; } MoveAllSelObjects(dx, dy); PrepareToRecord(CMD_NEW, NULL, NULL, 0); RecordCmd(CMD_NEW, NULL, topSel, botSel, numObjSelected); UpdSelBBox(); RedrawAnArea(botObj, selLtX-(GRID_ABS_SIZE(1)), selLtY-(GRID_ABS_SIZE(1)), selRbX+(GRID_ABS_SIZE(1)), selRbY+(GRID_ABS_SIZE(1))); HighLightForward(); SetFileModified(TRUE); } void DupTheseObjects(TopSel, BotSel, NewTopSel, NewBotSel) struct SelRec *TopSel, *BotSel, **NewTopSel, **NewBotSel; { struct SelRec *sel_ptr, *new_sel_ptr; struct ObjRec *obj_ptr, *top_obj; *NewTopSel = *NewBotSel = NULL; if (TopSel == NULL) return; top_obj = NULL; for (sel_ptr=BotSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { obj_ptr = DupObj(sel_ptr->obj); AdjObjSplineVs(obj_ptr); obj_ptr->next = top_obj; new_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (new_sel_ptr == NULL) FailAllocMessage(); new_sel_ptr->next = *NewTopSel; new_sel_ptr->obj = obj_ptr; if (top_obj == NULL) { *NewBotSel = new_sel_ptr; } else { top_obj->prev = obj_ptr; (*NewTopSel)->prev = new_sel_ptr; } top_obj = obj_ptr; *NewTopSel = new_sel_ptr; } top_obj->prev = NULL; (*NewTopSel)->prev = NULL; } void JustDupSelObj(NewTopSel, NewBotSel) struct SelRec **NewTopSel, **NewBotSel; { DupTheseObjects(topSel, botSel, NewTopSel, NewBotSel); } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/http.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000007000�11602233311�014105� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/http.e,v 1.8 2011/05/16 16:21:57 william Exp $ */ #ifndef _TGIF_HTTP_E_ #define _TGIF_HTTP_E_ extern int debugHttp; extern int gnHttpKeepAlive; extern char *gpszFakedReferer; #ifdef _INCLUDE_FROM_HTTP_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_HTTP_C_*/ extern void HttpFreeBuf ARGS_DECL((char *buf)); extern void HttpDebug ARGS_DECL((int)); extern void DoBase64Encode ARGS_DECL((char *buf_in, int buf_len, char *return_buf_in)); extern int DoBase64Decode ARGS_DECL((char *buf_in, int buf_len, char *return_buf_in)); extern char *Base64Encode ARGS_DECL((char*)); extern char *Base64Decode ARGS_DECL((char*)); extern char *FindAuthorization ARGS_DECL((char *pszHost, int nPort, char *pszScheme, char *pszRealm)); extern void CommitAuthorization ARGS_DECL((void)); extern void ResetAuthorization ARGS_DECL((void)); extern int SetAuthorization ARGS_DECL((char *pszHost, int nPort, char *pszScheme, char *pszRealm, char *pszAuth)); extern void HttpClearReferer ARGS_DECL((void)); extern void HttpSetReferer ARGS_DECL((char*)); extern void HttpFakeReferer ARGS_DECL((char*)); extern void CleanUpHttp ARGS_DECL((void)); extern void InitHttp ARGS_DECL((void)); extern char *HttpHeaderGetVersion ARGS_DECL((void)); extern int HttpHeaderGetResponseCode ARGS_DECL((void)); extern char *HttpHeaderGetResponseStatus ARGS_DECL((void)); extern char *HttpHeaderGetLastModified ARGS_DECL((void)); extern char *HttpHeaderGetServer ARGS_DECL((void)); extern char *HttpHeaderGetConnection ARGS_DECL((void)); extern char *HttpHeaderGetLocation ARGS_DECL((void)); extern char *HttpHeaderGetWWWAuthentication ARGS_DECL((void)); extern char *HttpHeaderGetContentEncoding ARGS_DECL((void)); extern char *HttpHeaderGetContentType ARGS_DECL((void)); extern long HttpHeaderGetContentLength ARGS_DECL((void)); extern char *HttpHeaderGetOtherField ARGS_DECL((char*)); extern int HttpDoConnect ARGS_DECL((char *psz_host, int us_port, int *pn_socket)); extern int HttpDoWrite ARGS_DECL((int n_socket, char *psz_path, char *psz_host, int us_port)); extern void HttpDumpHeader ARGS_DECL((void)); extern char *HttpExtractText ARGS_DECL((char *buf, int *pn_buf_sz, int *pn_html, char **ppsz_content_type)); extern int HttpDoRead ARGS_DECL((int n_socket, char **ppsz_buf, int *pn_buf_sz)); #ifdef _INCLUDE_FROM_HTTP_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_HTTP_C_*/ #endif /*_TGIF_HTTP_E_*/ tgif-QPL-4.2.5/make.comdep��������������������������������������������������������������������������0000644�0000764�0000764�00000076617�11602233312�015113� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# # @(#)$Header: /mm2/home/cvs/bc-src/tgif/make.comdep,v 1.30 2011/06/19 14:57:50 william Exp $ # # This file is included at the end of Makefile.noimake and descrip.mms. # $(O) and $(XBM) must be defined before this file is included. # # ------------------------------------------------------------------------- # dependencies generated by makedepend and noimake align$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h align.e \ auxtext.e button.e choice.e cmd.e color.e dialog.e drawing.e \ dup.e grid.e mark.e mainmenu.e menu.e menuinfo.e move.e msg.e \ obj.e poly.e list.e raster.e rect.e select.e setup.e \ stretch.e strtbl.e util.e animate$(O) : tgifdefs.h const.h tgif_dbg.h types.h animate.e color.e \ dialog.e msg.e poly.e list.e raster.e select.e setup.e \ strtbl.e arc$(O) : tgifdefs.h const.h tgif_dbg.h types.h arc.e attr.e auxtext.e \ choice.e cmd.e color.e cursor.e cutpaste.e dialog.e drawing.e \ dup.e file.e grid.e mainloop.e mark.e msg.e obj.e page.e \ pattern.e poly.e list.e ps.e raster.e rect.e ruler.e select.e \ setup.e special.e spline.e strtbl.e util.e xpixmap.e attr$(O) : tgifdefs.h const.h tgif_dbg.h types.h attr.e auxtext.e \ button.e choice.e choose.e cmd.e color.e cursor.e dialog.e \ drawing.e dup.e file.e font.e grid.e mainloop.e mainmenu.e \ mark.e menu.e miniline.e move.e msg.e names.e obj.e pattern.e \ raster.e rect.e ruler.e select.e setup.e stk.e strtbl.e \ text.e util.e wb.e auxtext$(O) : tgifdefs.h const.h tgif_dbg.h types.h auxtext.e choice.e \ color.e cursor.e cutpaste.e dialog.e drawing.e file.e font.e \ miniline.e msg.e obj.e pattern.e prtgif.e ps.e raster.e \ rect.e setup.e select.e strtbl.e text.e util.e xbitmap.e \ xpixmap.e box$(O) : tgifdefs.h const.h tgif_dbg.h types.h attr.e auxtext.e box.e \ choice.e cmd.e color.e cursor.e cutpaste.e dialog.e drawing.e \ dup.e file.e grid.e mainloop.e mark.e msg.e obj.e pattern.e \ poly.e list.e ps.e raster.e rect.e ruler.e select.e setup.e \ strtbl.e util.e xpixmap.e button$(O) : tgifdefs.h const.h tgif_dbg.h types.h auxtext.e box.e \ button.e cursor.e file.e font.e mainloop.e mainmenu.e menu.e \ msg.e raster.e rect.e setup.e chat$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h tidget.h \ list.e button.e chat.e cmd.e color.e choose.e dialog.e file.e \ font.e http.e ini.e inmethod.e msg.e menu.e rect.e setup.e \ strtbl.e tdgtbtn.e tdgtsedt.e tdgtlist.e tidget.e util.e \ xpixmap.e $(XBM)a1.xbm $(XBM)bold1.xbm $(XBM)italic1.xbm chinput$(O) : tgifdefs.h const.h tgif_dbg.h types.h chinput.e strtbl.e choice$(O) : tgifdefs.h const.h tgif_dbg.h types.h expfdefs.h align.e \ arc.e auxtext.e box.e choice.e color.e cursor.e dialog.e \ drawing.e edit.e file.e font.e grid.e inmethod.e mainloop.e \ mainmenu.e mark.e menu.e menuinfo.e miniline.e msg.e \ navigate.e oval.e page.e pattern.e poly.e list.e polygon.e \ raster.e rcbox.e rect.e select.e setup.e shape.e special.e \ stretch.e strtbl.e text.e util.e wb.e xbitmap.e xprtfltr.e \ $(XBM)abc.xbm choose$(O) : tgifdefs.h const.h tgif_dbg.h types.h auxtext.e button.e \ choose.e cutpaste.e cursor.e dialog.e drawing.e file.e font.e \ mainloop.e mainmenu.e menu.e msg.e names.e raster.e rect.e \ remote.e ruler.e scroll.e setup.e strtbl.e util.e \ $(XBM)check.xbm cli_xcin$(O) : tgifdefs.h const.h tgif_dbg.h types.h cli_xcin.e cmd$(O) : tgifdefs.h const.h tgif_dbg.h types.h attr.e choice.e cmd.e \ color.e dialog.e drawing.e dup.e file.e grid.e imgproc.e \ mainmenu.e mark.e miniline.e move.e msg.e navigate.e obj.e \ page.e remote.e select.e setup.e stk.e strtbl.e text.e util.e \ wb.e xpixmap.e color$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h choice.e cmd.e \ color.e dialog.e drawing.e file.e font.e imgproc.e mainloop.e \ mainmenu.e mark.e menu.e menuinfo.e miniline.e msg.e obj.e \ page.e pattern.e ps.e raster.e rect.e select.e setup.e stk.e \ strtbl.e text.e tgcwheel.e util.e xpixmap.e $(XBM)upend.xbm convkinput$(O) : tgifdefs.h const.h tgif_dbg.h types.h choice.e convkinput.e \ dialog.e msg.e strtbl.e text.e convxim$(O) : tgifdefs.h const.h tgif_dbg.h types.h convkinput.e convxim.e \ dialog.e font.e list.e miniline.e msg.e setup.e strtbl.e \ util.e cursor$(O) : tgifdefs.h const.h tgif_dbg.h types.h choice.e color.e \ cursor.e file.e setup.e strtbl.e xbitmap.e $(XBM)null.xbm \ $(XBM)nullmask.xbm $(XBM)text_cur.xbm $(XBM)helphand.xbm \ $(XBM)hhand_mk.xbm $(XBM)mag.xbm $(XBM)mag_mask.xbm \ $(XBM)flood.xbm $(XBM)flood_mk.xbm $(XBM)drip.xbm \ $(XBM)drip_msk.xbm cutpaste$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h arc.e \ auxtext.e attr.e box.e choice.e choose.e cmd.e color.e \ convkinput.e cutpaste.e cursor.e dialog.e drawing.e dup.e \ file.e font.e grid.e import.e ini.e mainloop.e mark.e menu.e \ miniline.e move.e msg.e names.e nkf.e obj.e oval.e page.e \ pattern.e poly.e list.e polygon.e raster.e rcbox.e remote.e \ select.e setup.e special.e stretch.e strtbl.e text.e util.e \ xbitmap.e xpixmap.e dialog$(O) : tgifdefs.h const.h tgif_dbg.h types.h auxtext.e box.e \ button.e cutpaste.e cursor.e dialog.e drawing.e file.e font.e \ grid.e mainloop.e mainmenu.e menu.e msg.e raster.e rect.e \ ruler.e setup.e strtbl.e text.e util.e $(XBM)info.xbm drawing$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h align.e \ animate.e arc.e attr.e auxtext.e box.e choice.e cmd.e color.e \ cutpaste.e cursor.e dialog.e drawing.e dup.e edit.e eps.e \ exec.e list.e file.e font.e grid.e group.e help.e imgproc.e \ import.e inmethod.e mark.e mainloop.e mainmenu.e menu.e \ menuinfo.e miniline.e msg.e navigate.e names.e obj.e oval.e \ page.e pattern.e pin.e poly.e polygon.e raster.e rcbox.e \ rect.e remote.e ruler.e scroll.e select.e setup.e shape.e \ shortcut.e special.e stk.e stream.e stretch.e strtbl.e \ tangram2.e tcp.e text.e tidget.e tidget.h util.e wb.e \ xbitmap.e xpixmap.e $(XBM)intr.xbm $(XBM)trek.xbm \ $(XBM)run.xbm dup$(O) : tgifdefs.h const.h tgif_dbg.h types.h attr.e auxtext.e \ choice.e cmd.e drawing.e dup.e file.e grid.e mark.e move.e \ msg.e obj.e page.e raster.e select.e setup.e text.e util.e \ xbitmap.e xpixmap.e edit$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h align.e arc.e \ attr.e auxtext.e button.e choice.e cmd.e color.e cutpaste.e \ cursor.e dialog.e drawing.e dup.e edit.e eps.e exec.e list.e \ file.e font.e grid.e group.e mainloop.e mainmenu.e mark.e \ menu.e menuinfo.e miniline.e move.e msg.e names.e navigate.e \ obj.e page.e pattern.e pin.e poly.e polygon.e raster.e rect.e \ ruler.e select.e setup.e shape.e special.e spline.e stretch.e \ strtbl.e text.e util.e xbitmap.e xpixmap.e eps$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmd.e color.e cursor.e \ dialog.e drawing.e dup.e eps.e file.e grid.e mark.e msg.e \ names.e obj.e pattern.e ps.e rect.e select.e setup.e \ special.e strtbl.e util.e xbitmap.e exec$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h expfdefs.h \ cmdids.h align.e arc.e attr.e auxtext.e box.e cmd.e color.e \ choice.e cursor.e cutpaste.e dialog.e drawing.e dup.e edit.e \ eps.e exec.e list.e expr.e file.e font.e grid.e import.e \ ini.e mainloop.e mainmenu.e mark.e menu.e miniline.e move.e \ msg.e names.e navigate.e obj.e oval.e page.e pattern.e \ pngtrans.e poly.e polygon.e raster.e rcbox.e rect.e remote.e \ ruler.e select.e setup.e shortcut.e special.e stk.e stretch.e \ strtbl.e tangram2.e tcp.e text.e util.e version.e wb.e \ xbitmap.e xpixmap.e xprtfltr.e z_intrf.e expr$(O) : tgifdefs.h const.h tgif_dbg.h types.h dialog.e expr.e msg.e \ setup.e strtbl.e util.e file$(O) : tgifdefs.h const.h tgif_dbg.h types.h expfdefs.h cmdids.h \ align.e arc.e attr.e auxtext.e box.e button.e choice.e cmd.e \ color.e cutpaste.e cursor.e dialog.e drawing.e dup.e edit.e \ eps.e exec.e list.e file.e font.e grid.e group.e imgproc.e \ import.e ini.e mainloop.e mainmenu.e mark.e menu.e menuinfo.e \ miniline.e move.e msg.e names.e navigate.e obj.e oval.e \ page.e pattern.e poly.e polygon.e prtgif.e ps.e raster.e \ rcbox.e rect.e remote.e ruler.e scroll.e select.e setup.e \ shape.e special.e spline.e stk.e stretch.e strtbl.e text.e \ util.e version.e wb.e xbitmap.e xpixmap.e xprtfltr.e font$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h auxtext.e \ choice.e cmd.e color.e cursor.e dialog.e drawing.e exec.e \ list.e file.e font.e ini.e mainmenu.e mark.e menu.e \ menuinfo.e miniline.e msg.e obj.e pattern.e page.e ps.e \ raster.e rect.e select.e setup.e strtbl.e text.e util.e \ version.e xpixmap.e frontend$(O) : ftp$(O) : tgifdefs.h const.h tgif_dbg.h types.h dialog.e file.e ftp.e \ msg.e remote.e strtbl.e tcp.e util.e grid$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h expfdefs.h \ choice.e color.e cursor.e dialog.e drawing.e dup.e file.e \ grid.e mainmenu.e menu.e menuinfo.e msg.e navigate.e obj.e \ page.e pattern.e raster.e ruler.e scroll.e select.e setup.e \ stretch.e strtbl.e text.e util.e wb.e xprtfltr.e group$(O) : tgifdefs.h const.h tgif_dbg.h types.h attr.e choice.e cmd.e \ dialog.e drawing.e dup.e file.e group.e mark.e msg.e obj.e \ page.e select.e setup.e strtbl.e hash$(O) : tgifdefs.h const.h tgif_dbg.h types.h hash.e list.e msg.e \ util.e help$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h color.e \ dialog.e file.e help.e menu.e menuinfo.e msg.e navigate.e \ remote.e setup.e strtbl.e util.e version.e http$(O) : tgifdefs.h const.h tgif_dbg.h types.h dialog.e drawing.e \ file.e http.e mainloop.e msg.e remote.e setup.e stream.e \ strtbl.e tcp.e util.e version.e imgproc$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h auxtext.e \ choice.e cmd.e color.e cursor.e dialog.e drawing.e dup.e \ file.e grid.e hash.e list.e imgproc.e mainloop.e mainmenu.e \ mark.e menu.e menuinfo.e move.e msg.e names.e navigate.e \ obj.e page.e pngtrans.e poly.e polygon.e raster.e rect.e \ remote.e ruler.e select.e setup.e special.e strtbl.e util.e \ xbitmap.e xpixmap.e z_intrf.e import$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h attr.e \ auxtext.e box.e choice.e choose.e cmd.e color.e cursor.e \ cutpaste.e dialog.e drawing.e dup.e eps.e file.e font.e \ grid.e imgproc.e import.e mainloop.e mainmenu.e mark.e msg.e \ menu.e move.e names.e navigate.e obj.e page.e pngtrans.e \ raster.e rect.e remote.e scroll.e select.e setup.e special.e \ stretch.e strtbl.e text.e util.e xbitmap.e xpixmap.e \ z_intrf.e ini$(O) : tgifdefs.h const.h tgif_dbg.h types.h dialog.e ini.e msg.e \ strtbl.e util.e inmethod$(O) : tgifdefs.h const.h tgif_dbg.h types.h cli_xcin.e chinput.e \ convkinput.e convxim.e tgtwb5.e dialog.e inmethod.e msg.e \ util.e setup.e strtbl.e tidget.e tidget.h list.e list$(O) : tgifdefs.h const.h tgif_dbg.h types.h list.e msg.e mainloop$(O) : tgifdefs.h const.h tgif_dbg.h types.h expfdefs.h patchlvl.h \ cmdids.h animate.e attr.e auxtext.e chat.e tidget.h list.e \ choice.e cmd.e color.e cursor.e cutpaste.e dialog.e drawing.e \ edit.e eps.e exec.e expr.e file.e font.e ftp.e grid.e help.e \ http.e imgproc.e import.e ini.e inmethod.e mainloop.e \ mainmenu.e mark.e markup.e menu.e miniline.e msg.e names.e \ navigate.e obj.e page.e pin.e ps.e raster.e remote.e ruler.e \ scroll.e select.e setup.e shape.e shortcut.e special.e stk.e \ strtbl.e tangram2.e text.e tgcwheel.e tginssym.e tidget.e \ util.e version.e wb.e xbitmap.e xpixmap.e xprtfltr.e mainmenu$(O) : tgifdefs.h const.h tgif_dbg.h types.h align.e choice.e \ color.e cursor.e dialog.e edit.e file.e font.e grid.e help.e \ imgproc.e mainloop.e mainmenu.e menu.e menuinfo.e msg.e \ navigate.e obj.e page.e pattern.e raster.e setup.e shape.e \ special.e stretch.e strtbl.e tangram2.e text.e util.e mark$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h choice.e cmd.e \ dialog.e drawing.e dup.e exec.e list.e file.e mark.e msg.e \ obj.e oval.e pattern.e page.e poly.e polygon.e raster.e \ rect.e setup.e select.e spline.e stretch.e strtbl.e util.e markup$(O) : tgifdefs.h const.h tgif_dbg.h types.h file.e http.e markup.e \ msg.e setup.e util.e menu$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h align.e box.e \ choice.e cmd.e color.e cursor.e dialog.e drawing.e edit.e \ exec.e list.e file.e font.e grid.e help.e imgproc.e \ mainloop.e mainmenu.e menu.e menuinfo.e move.e msg.e names.e \ navigate.e obj.e page.e pattern.e raster.e rect.e remote.e \ scroll.e select.e setup.e shape.e special.e stk.e strtbl.e \ tangram2.e text.e util.e version.e $(XBM)check.xbm \ $(XBM)submenu.xbm menuinfo$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h align.e \ color.e cutpaste.e drawing.e edit.e file.e font.e grid.e \ help.e imgproc.e import.e menu.e menuinfo.e names.e \ navigate.e page.e pattern.e raster.e scroll.e shape.e \ special.e stream.e stretch.e tangram2.e text.e xbitmap.e miniline$(O) : tgifdefs.h const.h tgif_dbg.h types.h auxtext.e choice.e \ color.e cutpaste.e dialog.e drawing.e dup.e file.e font.e \ inmethod.e miniline.e move.e msg.e obj.e pattern.e ps.e \ raster.e rect.e setup.e strtbl.e text.e util.e wb.e move$(O) : tgifdefs.h const.h tgif_dbg.h types.h arc.e attr.e choice.e \ cmd.e cursor.e dialog.e drawing.e dup.e exec.e list.e grid.e \ mainloop.e mark.e move.e msg.e names.e obj.e oval.e poly.e \ raster.e rcbox.e rect.e ruler.e select.e setup.e spline.e \ stretch.e strtbl.e msg$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h auxtext.e \ button.e chat.e tidget.h list.e cutpaste.e cursor.e dialog.e \ drawing.e file.e font.e grid.e inmethod.e mainloop.e markup.e \ menu.e msg.e navigate.e pattern.e ps.e raster.e rect.e \ remote.e rm_intrf.e rmcast/src/rmcast.h setup.e strtbl.e \ tangram2.e text.e util.e version.e wb.e xbitmap.e \ $(XBM)redraw.xbm $(XBM)btn1.xbm names$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h auxtext.e \ box.e button.e choose.e cutpaste.e cursor.e dialog.e \ drawing.e file.e font.e import.e ini.e mainloop.e mainmenu.e \ menu.e msg.e names.e navigate.e raster.e rect.e remote.e \ setup.e strtbl.e util.e xpixmap.e navigate$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h attr.e \ auxtext.e button.e choice.e choose.e cmd.e color.e cursor.e \ cutpaste.e dialog.e drawing.e exec.e list.e file.e font.e \ mainloop.e mainmenu.e menu.e menuinfo.e msg.e names.e \ navigate.e obj.e page.e pattern.e raster.e rect.e remote.e \ scroll.e select.e setup.e stk.e strtbl.e util.e xpixmap.e nkf$(O) : tgifdefs.h const.h tgif_dbg.h types.h nkf.e setup.e util.e obj$(O) : tgifdefs.h const.h tgif_dbg.h types.h arc.e attr.e auxtext.e \ box.e cmd.e cursor.e group.e msg.e obj.e oval.e page.e pin.e \ poly.e list.e polygon.e rcbox.e rect.e setup.e spline.e \ stretch.e text.e xbitmap.e xpixmap.e oval$(O) : tgifdefs.h const.h tgif_dbg.h types.h attr.e auxtext.e \ choice.e cmd.e color.e cursor.e cutpaste.e dialog.e drawing.e \ dup.e file.e grid.e mainloop.e mark.e msg.e obj.e oval.e \ pattern.e poly.e list.e ps.e raster.e rect.e ruler.e select.e \ setup.e spline.e strtbl.e util.e xpixmap.e page$(O) : tgifdefs.h const.h tgif_dbg.h types.h expfdefs.h attr.e \ auxtext.e button.e cmd.e choice.e choose.e color.e cursor.e \ dialog.e drawing.e dup.e file.e font.e grid.e mark.e \ mainloop.e mainmenu.e menu.e menuinfo.e move.e msg.e names.e \ navigate.e obj.e page.e raster.e rect.e scroll.e select.e \ setup.e stk.e strtbl.e text.e util.e wb.e xpixmap.e \ xprtfltr.e $(XBM)leftend.xbm pattern$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h arc.e choice.e \ color.e cmd.e cutpaste.e dialog.e drawing.e file.e font.e \ mainmenu.e mark.e menu.e menuinfo.e miniline.e msg.e \ navigate.e obj.e pattern.e poly.e list.e raster.e select.e \ setup.e spline.e strtbl.e text.e util.e pin$(O) : tgifdefs.h const.h tgif_dbg.h types.h auxtext.e choice.e \ color.e dialog.e drawing.e mainloop.e msg.e navigate.e obj.e \ pin.e poly.e list.e raster.e rect.e select.e setup.e strtbl.e pngtrans$(O) : tgifdefs.h const.h tgif_dbg.h types.h dialog.e pngtrans.e \ msg.e strtbl.e util.e poly$(O) : tgifdefs.h const.h tgif_dbg.h types.h arc.e attr.e auxtext.e \ choice.e cmd.e color.e cursor.e cutpaste.e dialog.e drawing.e \ dup.e file.e grid.e list.e mainloop.e mark.e msg.e obj.e \ page.e pattern.e pin.e poly.e polygon.e ps.e raster.e rect.e \ ruler.e select.e setup.e special.e spline.e stretch.e \ strtbl.e util.e xpixmap.e polygon$(O) : tgifdefs.h const.h tgif_dbg.h types.h arc.e attr.e auxtext.e \ box.e cmd.e color.e choice.e cursor.e cutpaste.e dialog.e \ drawing.e dup.e grid.e file.e mainloop.e mark.e msg.e obj.e \ pattern.e poly.e list.e polygon.e ps.e raster.e rect.e \ ruler.e select.e setup.e spline.e strtbl.e util.e xpixmap.e prtgif$(O) : tgifdefs.h const.h tgif_dbg.h types.h prtgif.e ps$(O) : tgifdefs.h const.h tgif_dbg.h types.h file.e msg.e ps.e \ raster.e util.e raster$(O) : tgifdefs.h const.h tgif_dbg.h types.h expfdefs.h choice.e \ color.e dialog.e file.e font.e menu.e miniline.e msg.e \ pattern.e poly.e list.e shape.e raster.e setup.e strtbl.e \ text.e util.e xprtfltr.e $(XBM)arrow.xbm $(XBM)text.xbm \ $(XBM)box.xbm $(XBM)oval.xbm $(XBM)ovalcent.xbm \ $(XBM)ovaledge.xbm $(XBM)poly.xbm $(XBM)polygon.xbm \ $(XBM)arc.xbm $(XBM)arc_edge.xbm $(XBM)rcbox.xbm \ $(XBM)freehand.xbm $(XBM)vmode.xbm $(XBM)rot_mode.xbm \ $(XBM)rot_mode2.xbm $(XBM)pat0.xbm $(XBM)pat1.xbm \ $(XBM)pat2.xbm $(XBM)pat3.xbm $(XBM)pat4.xbm $(XBM)pat5.xbm \ $(XBM)pat6.xbm $(XBM)pat7.xbm $(XBM)pat8.xbm $(XBM)pat9.xbm \ $(XBM)pat10.xbm $(XBM)pat11.xbm $(XBM)pat12.xbm \ $(XBM)pat13.xbm $(XBM)pat14.xbm $(XBM)pat15.xbm \ $(XBM)pat16.xbm $(XBM)pat17.xbm $(XBM)pat18.xbm \ $(XBM)pat19.xbm $(XBM)pat20.xbm $(XBM)pat21.xbm \ $(XBM)pat22.xbm $(XBM)pat23.xbm $(XBM)pat24.xbm \ $(XBM)pat25.xbm $(XBM)pat26.xbm $(XBM)pat27.xbm \ $(XBM)pat28.xbm $(XBM)pat29.xbm $(XBM)pat30.xbm \ $(XBM)pat31.xbm $(XBM)pat32.xbm $(XBM)shape0.xbm \ $(XBM)shape1.xbm $(XBM)shape2.xbm $(XBM)shape3.xbm \ $(XBM)shape4.xbm $(XBM)shape5.xbm $(XBM)shape6.xbm \ $(XBM)shape7.xbm $(XBM)shape8.xbm $(XBM)shape9.xbm \ $(XBM)shape10.xbm $(XBM)shape11.xbm $(XBM)shape12.xbm \ $(XBM)shape13.xbm $(XBM)shape14.xbm $(XBM)shape15.xbm \ $(XBM)shape16.xbm $(XBM)shape17.xbm $(XBM)shape18.xbm \ $(XBM)shape19.xbm $(XBM)just_l.xbm $(XBM)just_c.xbm \ $(XBM)just_r.xbm $(XBM)align_n.xbm $(XBM)align_l.xbm \ $(XBM)align_c.xbm $(XBM)align_r.xbm $(XBM)align_t.xbm \ $(XBM)align_m.xbm $(XBM)align_b.xbm $(XBM)align_s.xbm \ $(XBM)align_lt.xbm $(XBM)align_lm.xbm $(XBM)align_lb.xbm \ $(XBM)align_ct.xbm $(XBM)align_cm.xbm $(XBM)align_cb.xbm \ $(XBM)align_rt.xbm $(XBM)align_rm.xbm $(XBM)align_rb.xbm \ $(XBM)align_sn.xbm $(XBM)align_st.xbm $(XBM)align_sm.xbm \ $(XBM)align_sb.xbm $(XBM)align_ns.xbm $(XBM)align_ls.xbm \ $(XBM)align_cs.xbm $(XBM)align_rs.xbm $(XBM)align_ss.xbm \ $(XBM)lw0.xbm $(XBM)lw1.xbm $(XBM)lw2.xbm $(XBM)lw3.xbm \ $(XBM)lw4.xbm $(XBM)lw5.xbm $(XBM)lw6.xbm $(XBM)lt0.xbm \ $(XBM)lt1.xbm $(XBM)lt2.xbm $(XBM)lt3.xbm $(XBM)ls0.xbm \ $(XBM)ls1.xbm $(XBM)ls2.xbm $(XBM)ls3.xbm $(XBM)ld0.xbm \ $(XBM)ld1.xbm $(XBM)ld2.xbm $(XBM)ld3.xbm $(XBM)ld4.xbm \ $(XBM)ld5.xbm $(XBM)ld6.xbm $(XBM)ld7.xbm $(XBM)ld8.xbm \ $(XBM)lw0s.xbm $(XBM)lw1s.xbm $(XBM)lw2s.xbm $(XBM)lw3s.xbm \ $(XBM)lw4s.xbm $(XBM)lw5s.xbm $(XBM)lw6s.xbm $(XBM)lt0s.xbm \ $(XBM)lt1s.xbm $(XBM)lt2s.xbm $(XBM)lt3s.xbm $(XBM)ls0s.xbm \ $(XBM)ls1s.xbm $(XBM)ls2s.xbm $(XBM)ls3s.xbm $(XBM)ld0s.xbm \ $(XBM)ld1s.xbm $(XBM)ld2s.xbm $(XBM)ld3s.xbm $(XBM)ld4s.xbm \ $(XBM)ld5s.xbm $(XBM)ld6s.xbm $(XBM)ld7s.xbm $(XBM)ld8s.xbm \ $(XBM)printer.xbm $(XBM)latex.xbm $(XBM)psfile.xbm \ $(XBM)xbm.xbm $(XBM)ascii.xbm $(XBM)epsi.xbm $(XBM)gif.xbm \ $(XBM)html.xbm $(XBM)pdf.xbm $(XBM)tiffepsi.xbm $(XBM)png.xbm \ $(XBM)jpeg.xbm $(XBM)pbm.xbm $(XBM)netlist.xbm $(XBM)svg.xbm \ $(XBM)file.xbm $(XBM)landscap.xbm $(XBM)special.xbm \ $(XBM)vspace.xbm $(XBM)rcb_rad.xbm $(XBM)const_mv.xbm \ $(XBM)uncon_mv.xbm $(XBM)edit.xbm $(XBM)intr.xbm \ $(XBM)intr90.xbm $(XBM)trek.xbm $(XBM)stack.xbm \ $(XBM)tile.xbm $(XBM)leftend.xbm $(XBM)lfarrow.xbm \ $(XBM)rtarrow.xbm $(XBM)rightend.xbm $(XBM)upend.xbm \ $(XBM)uparrow.xbm $(XBM)dnarrow.xbm $(XBM)downend.xbm \ $(XBM)chkall.xbm $(XBM)unchkall.xbm $(XBM)scrl_up.xbm \ $(XBM)scrl_dn.xbm $(XBM)scrl_lf.xbm $(XBM)scrl_rt.xbm \ $(XBM)stretch.xbm $(XBM)nstretch.xbm $(XBM)pattrans.xbm \ $(XBM)patopaq.xbm $(XBM)rot_0.xbm $(XBM)rot_90.xbm \ $(XBM)rot_180.xbm $(XBM)rot_270.xbm $(XBM)wire.xbm \ $(XBM)run.xbm $(XBM)check.xbm $(XBM)radio.xbm \ $(XBM)submenu.xbm $(XBM)gsubmenu.xbm $(XBM)redraw.xbm \ $(XBM)btn1.xbm $(XBM)btn2.xbm $(XBM)btn3.xbm $(XBM)stop.xbm \ $(XBM)question.xbm $(XBM)info.xbm $(XBM)dialog.xbm rcbox$(O) : tgifdefs.h const.h tgif_dbg.h types.h attr.e auxtext.e box.e \ cmd.e color.e choice.e cursor.e cutpaste.e dialog.e drawing.e \ dup.e file.e grid.e mainloop.e mark.e msg.e obj.e pattern.e \ poly.e list.e ps.e raster.e rect.e rcbox.e ruler.e select.e \ setup.e spline.e strtbl.e util.e xpixmap.e rect$(O) : tgifdefs.h const.h tgif_dbg.h types.h arc.e color.e dialog.e \ drawing.e file.e msg.e poly.e list.e ps.e rect.e setup.e \ spline.e strtbl.e remote$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h cmd.e \ cutpaste.e dialog.e drawing.e file.e ftp.e http.e mainloop.e \ markup.e menu.e msg.e names.e navigate.e page.e remote.e \ setup.e stream.e strtbl.e tcp.e util.e version.e rm_intrf$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h dialog.e \ menu.e msg.e rm_intrf.e rmcast/src/rmcast.h strtbl.e util.e ruler$(O) : tgifdefs.h const.h tgif_dbg.h types.h choice.e cursor.e \ dialog.e file.e font.e grid.e mainloop.e mainmenu.e menu.e \ msg.e raster.e rect.e ruler.e select.e setup.e strtbl.e \ text.e util.e xpixmap.e scroll$(O) : tgifdefs.h const.h tgif_dbg.h types.h choice.e cursor.e \ dialog.e drawing.e dup.e exec.e list.e grid.e mainloop.e \ menu.e miniline.e msg.e obj.e page.e raster.e rect.e ruler.e \ scroll.e setup.e strtbl.e text.e util.e $(XBM)scrl_up.xbm select$(O) : tgifdefs.h const.h tgif_dbg.h types.h attr.e auxtext.e \ button.e choice.e cmd.e color.e cursor.e dialog.e drawing.e \ dup.e edit.e exec.e list.e file.e font.e grid.e group.e \ http.e mainloop.e mark.e menu.e miniline.e move.e msg.e \ names.e navigate.e obj.e page.e pin.e poly.e raster.e rect.e \ remote.e ruler.e scroll.e select.e setup.e special.e stk.e \ stretch.e strtbl.e util.e setup$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h expfdefs.h \ attr.e auxtext.e chat.e tidget.h list.e choice.e choose.e \ cmd.e color.e cursor.e cutpaste.e dialog.e drawing.e dup.e \ edit.e exec.e file.e font.e grid.e help.e imgproc.e import.e \ inmethod.e mainloop.e mainmenu.e mark.e markup.e menu.e \ miniline.e move.e msg.e names.e navigate.e nkf.e page.e \ pattern.e pin.e poly.e ps.e raster.e remote.e ruler.e \ scroll.e select.e setup.e shape.e shortcut.e special.e \ spline.e stk.e stretch.e strtbl.e tangram2.e tdgtlist.e \ text.e tgcwheel.e tginssym.e tidget.e util.e version.e wb.e \ xbitmap.e xpixmap.e xprtfltr.e z_intrf.e tgificon.xbm \ $(XBM)btn1.xbm shape$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h arc.e attr.e \ auxtext.e box.e cmd.e color.e cursor.e dialog.e drawing.e \ dup.e grid.e group.e mainloop.e menu.e menuinfo.e move.e \ msg.e navigate.e obj.e oval.e page.e pattern.e poly.e list.e \ polygon.e raster.e ruler.e select.e setup.e shape.e spline.e \ strtbl.e text.e util.e shortcut$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h choice.e msg.e \ setup.e shortcut.e strtbl.e tangram2.e util.e special$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h animate.e \ attr.e auxtext.e choice.e cmd.e color.e cutpaste.e cursor.e \ dialog.e drawing.e dup.e edit.e exec.e list.e file.e font.e \ grid.e group.e mainloop.e mainmenu.e mark.e menu.e menuinfo.e \ miniline.e msg.e move.e names.e obj.e page.e pattern.e poly.e \ raster.e rect.e remote.e ruler.e scroll.e select.e setup.e \ special.e stk.e stretch.e strtbl.e tangram2.e text.e util.e \ version.e wb.e spline$(O) : tgifdefs.h const.h tgif_dbg.h types.h dialog.e file.e msg.e \ poly.e list.e polygon.e ps.e raster.e rect.e setup.e spline.e \ strtbl.e stk$(O) : tgifdefs.h const.h tgif_dbg.h types.h align.e attr.e box.e \ button.e choice.e cmd.e color.e cursor.e dialog.e drawing.e \ dup.e file.e font.e grid.e mainmenu.e mark.e menu.e msg.e \ names.e navigate.e obj.e page.e pattern.e raster.e rect.e \ ruler.e scroll.e select.e setup.e stk.e strtbl.e text.e \ util.e version.e wb.e stream$(O) : tgifdefs.h const.h tgif_dbg.h types.h dialog.e drawing.e \ file.e http.e import.e menu.e move.e msg.e navigate.e obj.e \ remote.e setup.e stream.e strtbl.e util.e stretch$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h align.e arc.e \ auxtext.e choice.e cmd.e color.e cursor.e dialog.e drawing.e \ dup.e exec.e list.e file.e font.e grid.e mainloop.e \ mainmenu.e mark.e menu.e menuinfo.e miniline.e move.e msg.e \ navigate.e obj.e page.e poly.e raster.e rect.e ruler.e \ scroll.e select.e setup.e spline.e stretch.e strtbl.e text.e \ util.e xbitmap.e xpixmap.e strtbl$(O) : tgifdefs.h const.h tgif_dbg.h types.h choice.e drawing.e \ msg.e poly.e list.e strtbl.e special.e text.e util.e tangram2$(O) : tgifdefs.h const.h tgif_dbg.h types.h attr.e auxtext.e box.e \ cmd.e color.e dialog.e drawing.e exec.e list.e menu.e msg.e \ miniline.e move.e obj.e pattern.e rcbox.e select.e setup.e \ strtbl.e tangram2.e text.e util.e tcp$(O) : tgifdefs.h const.h tgif_dbg.h types.h msg.e remote.e strtbl.e \ tcp.e util.e tdgtbase$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h tidget.h \ list.e cursor.e menu.e msg.e raster.e rect.e setup.e \ tdgtbase.e text.e tidget.e util.e tdgtbmpl$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h auxtext.e \ choose.e color.e cursor.e dialog.e font.e mainloop.e menu.e \ msg.e names.e pattern.e raster.e rect.e scroll.e setup.e \ strtbl.e tdgtbmpl.e tidget.h list.e text.e tidget.e util.e tdgtbrow$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h tidget.h \ list.e menu.e msg.e raster.e rect.e setup.e tdgtbrow.e \ tdgtbtn.e tidget.e util.e tdgtbtn$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h tidget.h \ list.e button.e color.e cursor.e font.e menu.e msg.e raster.e \ rect.e setup.e tdgtbtn.e tidget.e util.e tdgtdraw$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h tidget.h \ list.e button.e color.e cursor.e font.e menu.e msg.e raster.e \ rect.e setup.e tdgtdraw.e tidget.e util.e tdgtlist$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h auxtext.e \ choose.e color.e cursor.e dialog.e drawing.e font.e \ mainloop.e menu.e msg.e pattern.e raster.e rect.e scroll.e \ setup.e strtbl.e tdgtlist.e tidget.h list.e tidget.e util.e tdgtmsg$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h tidget.h \ list.e choose.e cursor.e font.e menu.e msg.e raster.e rect.e \ setup.e tdgtmsg.e text.e tidget.e util.e tdgtsedt$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h tidget.h \ list.e auxtext.e choose.e color.e cursor.e dialog.e font.e \ inmethod.e menu.e msg.e raster.e rect.e setup.e tdgtbase.e \ tdgtsedt.e text.e tidget.e util.e testdrive$(O) : tgifdefs.h const.h tgif_dbg.h types.h mainloop.e msg.e obj.e \ setup.e text$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h attr.e \ auxtext.e choice.e cmd.e color.e convkinput.e cutpaste.e \ cursor.e dialog.e drawing.e dup.e edit.e exec.e list.e file.e \ font.e grid.e inmethod.e mainloop.e mainmenu.e mark.e menu.e \ miniline.e move.e msg.e names.e nkf.e obj.e pattern.e poly.e \ prtgif.e raster.e rect.e ruler.e scroll.e select.e setup.e \ stretch.e strtbl.e text.e tginssym.e util.e wb.e xbitmap.e \ xpixmap.e $(XBM)text_cur.xbm tgcwdl$(O) : tgifdefs.h const.h tgif_dbg.h types.h tidget.h list.e \ auxtext.e button.e color.e cursor.e dialog.e file.e font.e \ imgproc.e mainloop.e msg.e raster.e rect.e setup.e strtbl.e \ tdgtbase.e tdgtbmpl.e tdgtbrow.e tdgtbtn.e tdgtdraw.e \ tdgtsedt.e tdgtlist.e tdgtmsg.e tidget.e tgcwdl.e util.e \ xbitmap.e xpixmap.e tgcwheel$(O) : tgifdefs.h const.h tgif_dbg.h types.h tidget.h list.e \ auxtext.e dialog.e font.e msg.e setup.e strtbl.e tgcwheel.e \ tgcwdl.e tidget.e util.e tgif$(O) : tgifdefs.h const.h tgif_dbg.h types.h color.e dialog.e exec.e \ list.e file.e font.e grid.e mainloop.e msg.e names.e obj.e \ page.e raster.e setup.e strtbl.e tangram2.e util.e version.e tgif_dbg$(O) : tginssym$(O) : tgifdefs.h const.h tgif_dbg.h types.h tidget.h list.e \ auxtext.e dialog.e font.e msg.e setup.e strtbl.e tginssym.e \ tgisdl.e tidget.e util.e tgisdl$(O) : tgifdefs.h const.h tgif_dbg.h types.h tidget.h list.e \ auxtext.e dialog.e file.e font.e mainloop.e msg.e names.e \ raster.e setup.e strtbl.e tdgtbase.e tdgtbrow.e tdgtbtn.e \ tdgtdraw.e text.e tidget.e tgisdl.e util.e tgtwb5$(O) : tgifdefs.h const.h tgif_dbg.h types.h big5.h tidget.h list.e \ auxtext.e dialog.e font.e msg.e setup.e strtbl.e tgtwb5.e \ tgtwb5dl.e tgtwb5xl.e tidget.e util.e $(XBM)tgtwb5.xbm tgtwb5dl$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h tidget.h \ list.e auxtext.e cursor.e dialog.e file.e font.e mainloop.e \ msg.e raster.e rect.e scroll.e setup.e strtbl.e tdgtbase.e \ tdgtbmpl.e tdgtbrow.e tdgtbtn.e tdgtdraw.e tdgtsedt.e \ tdgtlist.e tdgtmsg.e text.e tidget.e tgtwb5dl.e tgtwb5xl.e \ util.e xbitmap.e tgtwb5xl$(O) : tgifdefs.h const.h tgif_dbg.h types.h tgtwb5xl.e tidget$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h tidget.h \ list.e font.e msg.e raster.e setup.e tdgtbase.e tdgtbmpl.e \ tdgtbrow.e tdgtbtn.e tdgtdraw.e tdgtlist.e tdgtmsg.e \ tdgtsedt.e text.e tidget.e util.e util$(O) : tgifdefs.h const.h tgif_dbg.h types.h dialog.e file.e \ remote.e strtbl.e util.e version$(O) : tgifdefs.h const.h tgif_dbg.h types.h patchlvl.h version.e vms_comp$(O) : vms_comp.h wb1$(O) : tgifdefs.h const.h tgif_dbg.h types.h wb2$(O) : tgifdefs.h const.h tgif_dbg.h types.h wb3$(O) : tgifdefs.h const.h tgif_dbg.h types.h wb_buff$(O) : tgifdefs.h const.h tgif_dbg.h types.h wb_buff.e wb$(O) : tgifdefs.h const.h tgif_dbg.h types.h cmdids.h \ rmcast/src/rmcast.h auxtext.e chat.e tidget.h list.e choice.e \ color.e cmd.e dialog.e drawing.e file.e font.e grid.e http.e \ import.e mark.e menu.e msg.e obj.e page.e raster.e remote.e \ rm_intrf.e ruler.e scroll.e select.e setup.e stk.e strtbl.e \ tcp.e util.e version.e wb.e wb_buff.e wb_seg.e xpixmap.e \ z_intrf.e wb_mcast$(O) : tgifdefs.h const.h tgif_dbg.h types.h wb_mcast.e wb_seg$(O) : tgifdefs.h const.h tgif_dbg.h types.h wb_seg.e xbitmap$(O) : tgifdefs.h const.h tgif_dbg.h types.h expfdefs.h cmdids.h \ attr.e auxtext.e choice.e cmd.e color.e cursor.e cutpaste.e \ dialog.e drawing.e dup.e edit.e eps.e file.e font.e grid.e \ imgproc.e mainloop.e mark.e menu.e miniline.e move.e msg.e \ names.e obj.e page.e pattern.e ps.e raster.e rect.e remote.e \ select.e setup.e stretch.e strtbl.e util.e version.e \ xbitmap.e xpixmap.e xprtfltr.e z_intrf.e xpixmap$(O) : tgifdefs.h const.h tgif_dbg.h types.h attr.e auxtext.e \ choice.e cmd.e color.e cursor.e cutpaste.e dialog.e drawing.e \ dup.e file.e font.e grid.e hash.e list.e http.e imgproc.e \ import.e mainloop.e mainmenu.e mark.e move.e msg.e names.e \ obj.e page.e pattern.e pngtrans.e ps.e raster.e rect.e \ select.e setup.e stretch.e strtbl.e util.e xbitmap.e \ xpixmap.e z_intrf.e xprtfltr$(O) : tgifdefs.h const.h tgif_dbg.h types.h expfdefs.h color.e \ dialog.e drawing.e file.e grid.e msg.e names.e obj.e page.e \ ps.e raster.e setup.e strtbl.e text.e util.e xbitmap.e \ xprtfltr.e z_intrf$(O) : tgifdefs.h const.h tgif_dbg.h types.h dialog.e file.e msg.e \ setup.e strtbl.e util.e z_intrf.e �����������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Tgif.tmpl-darwin���������������������������������������������������������������������0000644�0000764�0000764�00000004727�11602233313�016050� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-darwin,v 1.17 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM CCOPTIONS = -Wall -Wpointer-arith -Wmissing-prototypes \@@\ XCOMM -Wmissing-declarations -Wredundant-decls \@@\ XCOMM -Wnested-externs -no-cpp-precomp XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_NO_DL_SUPPORT -D_NO_IDNLIB -DHAVE_STDINT_H MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) XCOMM SYS_LIBRARIES = -lm -lz SYS_LIBRARIES = -lm -lz �����������������������������������������tgif-QPL-4.2.5/z_intrf.c����������������������������������������������������������������������������0000644�0000764�0000764�00000035172�11602233314�014615� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/z_intrf.c,v 1.11 2011/06/18 04:44:51 william Exp $ */ #define _INCLUDE_FROM_Z_INTRF_C_ #include "tgifdefs.h" #if (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) #include <zlib.h> #endif /* (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ #include "dialog.e" #include "file.e" #include "msg.e" #include "setup.e" #include "strtbl.e" #include "util.e" #include "z_intrf.e" /* --------------------- Utility Functions --------------------- */ static void ByteStuff(buf_in, buf_len, buf_out, pn_buf_out) unsigned char *buf_in, *buf_out; unsigned int buf_len, *pn_buf_out; { int i=0, count=0; for (i=0; i < buf_len; i++, buf_in++) { switch (*buf_in) { case '\0': *buf_out++ = ((unsigned char)0xff); *buf_out++ = ((unsigned char)0x30); count += 2; break; case ((unsigned char)0xff): *buf_out++ = ((unsigned char)0xff); *buf_out++ = ((unsigned char)0xff); count += 2; break; default: *buf_out++ = *buf_in; count++; break; } } if (pn_buf_out != NULL) *pn_buf_out = count; } static int ByteUnStuff(buf_in, buf_len, buf_out, pn_buf_out, pn_has_left_over) unsigned char *buf_in, *buf_out; int buf_len, *pn_buf_out, *pn_has_left_over; { int i=0, count=0; if (*pn_has_left_over) { if (buf_len == 0) return TRUE; switch (*buf_in) { case ((unsigned char)0x30): *buf_out++ = ((unsigned char)'\0'); count++; buf_in++; break; case ((unsigned char)0xff): *buf_out++ = ((unsigned char)0xff); count++; buf_in++; break; default: return FALSE; } *pn_has_left_over = FALSE; } for (i=count; i < buf_len; i++, buf_in++) { if (*buf_in == ((unsigned char)0xff)) { i++; buf_in++; if (i >= buf_len) { *pn_has_left_over = TRUE; if (pn_buf_out != NULL) *pn_buf_out = count; return TRUE; } switch (*buf_in) { case ((unsigned char)0x30): *buf_out++ = ((unsigned char)'\0'); count++; break; case ((unsigned char)0xff): *buf_out++ = ((unsigned char)0xff); count++; break; default: return FALSE; } } else { *buf_out++ = *buf_in; count++; } } if (pn_buf_out != NULL) *pn_buf_out = count; return TRUE; } /* --------------------- HasZlibSupport() --------------------- */ int HasZlibSupport() { #if (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) return TRUE; #else /* ~(!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ return FALSE; #endif /* (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ } /* --------------------- DeflateFile() --------------------- */ int DeflateFile(fname, deflated_fname) char *fname, *deflated_fname; /* no byte stuffing */ { #if (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) int level=Z_DEFAULT_COMPRESSION; int ret=0, flush=0; unsigned int block_sz=0x4000; unsigned int have=0; z_stream strm; FILE *in_fp=NULL, *out_fp=NULL; unsigned char in[0x4000], out[0x4000]; int bytes_left=0, input_size=0; struct stat stat_buf; ProgressInfo pi; if ((in_fp=fopen(fname, "r")) == NULL) { FailToOpenMessage(fname, "r", NULL); return FALSE; } if (fstat(fileno(in_fp), &stat_buf) != 0) { fclose(in_fp); sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_FSTAT_ABORT_COPY), fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } bytes_left = input_size = stat_buf.st_size; if ((out_fp=fopen(deflated_fname, "w")) == NULL) { fclose(in_fp); FailToOpenMessage(deflated_fname, "w", NULL); return FALSE; } /* allocate deflate state */ memset(&strm, 0, sizeof(strm)); strm.zalloc = Z_NULL; strm.zfree = Z_NULL; strm.opaque = Z_NULL; ret = deflateInit(&strm, level); if (ret != Z_OK) { ZlibError(ret, TRUE); return FALSE; } BeginProgress(&pi, input_size); do { int bytes_to_read=min(block_sz, bytes_left); strm.avail_in = fread(in, 1, bytes_to_read, in_fp); if (ferror(in_fp)) { (void)deflateEnd(&strm); ZlibError(ret, TRUE); return FALSE; } bytes_left -= bytes_to_read; flush = (bytes_left == 0) ? Z_FINISH : Z_NO_FLUSH; strm.next_in = in; UpdateProgress(&pi, input_size-bytes_left); /* * run deflate() on input until output buffer not full, finish compression * if all of in_fp has been read in or in_buf is exhausted */ do { strm.avail_out = block_sz; strm.next_out = out; ret = deflate(&strm, flush); /* no bad return value */ TgAssert(ret != Z_STREAM_ERROR, "deflate() returns Z_STREAM_ERROR in DeflateFile()", NULL); /* make sure that state is not clobbered */ have = block_sz - strm.avail_out; if (fwrite(out, 1, have, out_fp) != have || ferror(out_fp)) { (void)deflateEnd(&strm); ZlibError(ret, TRUE); return FALSE; } } while (strm.avail_out == 0); TgAssert(strm.avail_in == 0, "un-deflated data left in input buffer in DeflateFile()", NULL); /* make sure that all input are used */ /* done when last data in file processed */ } while (flush != Z_FINISH); EndProgress(&pi); TgAssert(ret == Z_STREAM_END, "end-of-stream not detected in DeflateFile()", NULL); /* make sure that stream is complete */ deflateEnd(&strm); fclose(in_fp); fclose(out_fp); return TRUE; #else /* ~(!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ return FALSE; #endif /* (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ } /* --------------------- DoDeflate() --------------------- */ int DoDeflate(in_fp, in_buf, bytes_left, out_fp, use_def_compression, use_byte_stuffing, pn_rc) /* * This function is adapted from <URL:http://www.zlib.net/zpipe.c> * * zpipe.c - example of proper use of zlib's inflate() and deflate() * Not copyrighted -- provided to the public domain * Version 1.4 11 December 2005 Mark Adler */ FILE *in_fp, *out_fp; char *in_buf; int bytes_left, use_byte_stuffing, *pn_rc; int use_def_compression; /* always use Z_DEFAULT_COMPRESSION */ { #if (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) int level=Z_DEFAULT_COMPRESSION; int ret=0, flush=0; unsigned int block_sz=0x4000; unsigned int have=0; z_stream strm; unsigned char in[0x4000], out[0x4000]; TgAssert(in_fp == NULL || in_buf == NULL, "in_fp and in_buf cannot be both NULL in DoDeflate()", NULL); /* allocate deflate state */ memset(&strm, 0, sizeof(strm)); strm.zalloc = Z_NULL; strm.zfree = Z_NULL; strm.opaque = Z_NULL; ret = deflateInit(&strm, level); if (ret != Z_OK) { if (pn_rc != NULL) *pn_rc = ret; return FALSE; } if (in_fp != NULL) rewind(in_fp); rewind(out_fp); do { int bytes_to_read=min(block_sz, bytes_left); if (in_fp != NULL) { strm.avail_in = fread(in, 1, bytes_to_read, in_fp); if (ferror(in_fp)) { (void)deflateEnd(&strm); if (pn_rc != NULL) *pn_rc = Z_ERRNO; return FALSE; } } else { memcpy(in, in_buf, bytes_to_read); strm.avail_in = bytes_to_read; } bytes_left -= bytes_to_read; flush = (bytes_left == 0) ? Z_FINISH : Z_NO_FLUSH; strm.next_in = in; /* * run deflate() on input until output buffer not full, finish compression * if all of in_fp has been read in or in_buf is exhausted */ do { strm.avail_out = block_sz; strm.next_out = out; ret = deflate(&strm, flush); /* no bad return value */ TgAssert(ret != Z_STREAM_ERROR, "deflate() returns Z_STREAM_ERROR in DoDeflate()", NULL); /* make sure that state is not clobbered */ have = block_sz - strm.avail_out; if (use_byte_stuffing) { unsigned int have2=0; unsigned char out2[0x8000]; have2 = 0; ByteStuff(out, have, out2, &have2); if (fwrite(out2, 1, have2, out_fp) != have2 || ferror(out_fp)) { (void)deflateEnd(&strm); if (pn_rc != NULL) *pn_rc = Z_ERRNO; return FALSE; } } else { if (fwrite(out, 1, have, out_fp) != have || ferror(out_fp)) { (void)deflateEnd(&strm); if (pn_rc != NULL) *pn_rc = Z_ERRNO; return FALSE; } } } while (strm.avail_out == 0); TgAssert(strm.avail_in == 0, "un-deflated data left in input buffer in DoDeflate()", NULL); /* make sure that all input are used */ /* done when last data in file processed */ } while (flush != Z_FINISH); TgAssert(ret == Z_STREAM_END, "end-of-stream not detected in DoDeflate()", NULL); /* make sure that stream is complete */ deflateEnd(&strm); return TRUE; #else /* ~(!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ return FALSE; #endif /* (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ } /* --------------------- DoInflate() --------------------- */ int DoInflate(in_buf, bytes_left, out_fp, use_byte_unstuffing, pn_rc) /* * This function is adapted from <URL:http://www.zlib.net/zpipe.c> * * zpipe.c - example of proper use of zlib's inflate() and deflate() * Not copyrighted -- provided to the public domain * Version 1.4 11 December 2005 Mark Adler */ char *in_buf; int bytes_left, use_byte_unstuffing, *pn_rc; FILE *out_fp; { #if (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) int ret=0, has_left_over=FALSE; unsigned int block_sz=0x4000; unsigned int have=0; z_stream strm; unsigned char in[0x4000], out[0x4000]; /* allocate inflate state */ memset(&strm, 0, sizeof(strm)); strm.zalloc = Z_NULL; strm.zfree = Z_NULL; strm.opaque = Z_NULL; strm.avail_in = 0; strm.next_in = Z_NULL; ret = inflateInit(&strm); if (ret != Z_OK) { if (pn_rc != NULL) *pn_rc = ret; return FALSE; } rewind(out_fp); /* decompress until deflate stream ends or end of file */ do { int bytes_to_read=min(block_sz, bytes_left), bytes_to_read2=0; unsigned char in2[0x4000]; if (bytes_to_read == 0) break; memcpy(in, in_buf, bytes_to_read); bytes_left -= bytes_to_read; in_buf += bytes_to_read; if (use_byte_unstuffing) { if (!ByteUnStuff(in, bytes_to_read, in2, &bytes_to_read2, &has_left_over)) { (void)inflateEnd(&strm); if (pn_rc != NULL) *pn_rc = Z_DATA_ERROR; return FALSE; } strm.avail_in = bytes_to_read2; strm.next_in = in2; } else { strm.avail_in = bytes_to_read; strm.next_in = in; } /* run inflate() on input until output buffer not full */ do { strm.avail_out = block_sz; strm.next_out = out; ret = inflate(&strm, Z_NO_FLUSH); TgAssert(ret != Z_STREAM_ERROR, "inflate() returns Z_STREAM_ERROR in DoInflate()", NULL); /* make sure that state is not clobbered */ switch (ret) { case Z_NEED_DICT: ret = Z_DATA_ERROR; /* and fall through */ case Z_DATA_ERROR: case Z_MEM_ERROR: (void)inflateEnd(&strm); if (pn_rc != NULL) *pn_rc = ret; return FALSE; } have = block_sz - strm.avail_out; if (fwrite(out, 1, have, out_fp) != have || ferror(out_fp)) { (void)inflateEnd(&strm); if (pn_rc != NULL) *pn_rc = Z_ERRNO; return FALSE; } } while (strm.avail_out == 0); /* done when inflate() says it's done */ } while (ret != Z_STREAM_END); if (has_left_over) { (void)inflateEnd(&strm); if (pn_rc != NULL) *pn_rc = Z_DATA_ERROR; return FALSE; } /* clean up and return */ inflateEnd(&strm); if (ret == Z_STREAM_END) { return TRUE; } if (pn_rc != NULL) *pn_rc = Z_DATA_ERROR; return FALSE; #else /* ~(!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ return FALSE; #endif /* (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ } /* --------------------- InflateInit() --------------------- */ /* --------------------- ZlibError() --------------------- */ void ZlibError(status, deflate) int status, deflate; { #if (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) char buf[MAXSTRING]; switch (status) { case Z_ERRNO: snprintf(buf, sizeof(buf), "%s-%s.", "File I/O error during z", deflate ? "compression" : "decompression"); break; case Z_STREAM_ERROR: snprintf(buf, sizeof(buf), "%s-%s.", "Invalid compression level used for z", deflate ? "compression" : "decompression"); break; case Z_DATA_ERROR: snprintf(buf, sizeof(buf), "%s-%s.", "Corrupted data encountered during z", deflate ? "compression" : "decompression"); break; case Z_MEM_ERROR: snprintf(buf, sizeof(buf), "%s-%s.", "Out of memory during z", deflate ? "compression" : "decompression"); break; case Z_VERSION_ERROR: snprintf(buf, sizeof(buf), "%s-%s.", "Zlib version mismatch for z", deflate ? "compression" : "decompression"); break; } if (deflate) { snprintf(gszMsgBox, sizeof(gszMsgBox), "%s\n\n%s", buf, "Continue without z-compression."); } else { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), buf); } if (PRTGIF && !cmdLineOpenDisplay) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } #endif /* (!defined(_NO_ZLIB) || defined(HAVE_LIBZ)) */ } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Tgif.tmpl-openbsd��������������������������������������������������������������������0000644�0000764�0000764�00000004713�11602233313�016211� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-openbsd,v 1.12 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_NO_IDNLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) SYS_LIBRARIES = -lm -lz XCOMM SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM OpenBSD 2.6 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM �����������������������������������������������������tgif-QPL-4.2.5/nand2.sym����������������������������������������������������������������������������0000644�0000764�0000764�00000005566�11602233312�014534� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������state(0,14,100,0,0,0,8,1,8,0,2,0,1,0,0,1,0,0,0,4,0,0,0,10,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/nand2.sym,v 1.1 2004/06/18 23:20:01 william Exp $ % text('white',320,272,0,0,4,1,0,0,1,428,21,123,0,17,4,0,0,0,[ "Select a pin icon and type #M to look at the pin attributes."]). text('white',320,248,0,0,4,1,0,0,1,436,21,124,0,17,4,0,0,0,[ "You can actually push into the little squares which are pins."]). text('white',320,224,0,0,4,1,0,0,1,377,21,125,0,17,4,0,0,0,[ "Ungroup the little pieces and see what is it made of."]). text('white',384,200,0,0,4,1,0,0,1,94,21,126,0,17,4,0,0,0,[ "box go away."]). text('white',320,176,0,0,4,1,0,0,1,390,21,127,0,17,4,0,0,0,[ "Select the UnMakeSymbolic item and see the dashed"]). text('white',384,152,0,0,4,1,0,0,1,129,21,128,0,17,4,0,0,0,[ "named ``special''."]). text('white',384,128,0,0,4,1,0,0,1,356,21,129,0,17,4,0,0,0,[ "the right mouse button, then select the last entry"]). text('white',320,104,0,0,4,1,0,0,1,438,21,130,0,17,4,0,0,0,[ "Select one of the NAND gates, pop up the main menu using"]). text('white',320,80,0,0,4,1,0,0,1,237,21,131,0,17,4,0,0,0,[ "Make a copy of the NAND gate."]). text('white',320,56,0,0,4,1,0,0,1,374,21,132,0,17,4,0,0,0,[ "It is therefore a ``primitive'' building-block object."]). text('white',320,32,0,0,4,1,0,0,1,338,21,133,0,17,4,0,0,0,[ "The NAND gate has no implementation part."]). sym([ group([ poly('yellow',2,[ 136,112,112,112],0,0,1,20,1,0,0,0,[ ]), poly('yellow',2,[ 136,160,112,160],0,0,1,21,1,0,0,0,[ ]), poly('yellow',2,[ 256,136,232,136],0,0,1,22,1,0,0,0,[ ]), group([ oval('yellow',208,124,232,148,2,0,1,134,0,0,[ ]), poly('yellow',4,[ 168,104,136,104,136,168,168,168],0,0,1,23,0,0,0,0,[ ]), poly('yellow',3,[ 168,104,208,104,208,136],0,0,1,24,1,0,0,0,[ ]), poly('yellow',3,[ 168,168,208,168,208,136],0,0,1,25,1,0,0,0,[ ]) ],[ ]) ],[ ]), icon([ box('yellow',240,120,272,152,0,0,0,135,0,0,[ ]), box('yellow',252,132,260,140,2,0,1,136,0,0,[ ]) ], "pin",17,0,0,[ attr("name=", "out", 0, 1, 1, text('green',256,112,1,0,4,1,1,0,1,88,19,137,0,15,4,0,0,0,[ "name=out"])), attr("num=", "3", 1, 0, 1, text('green',240,120,1,0,4,1,1,0,1,11,19,138,0,15,4,0,0,0,[ "3"])) ]), icon([ box('yellow',96,96,128,128,0,0,0,139,0,0,[ ]), box('yellow',108,108,116,116,2,0,1,140,0,0,[ ]) ], "pin",18,0,0,[ attr("num=", "1", 1, 0, 1, text('green',128,96,1,0,4,1,1,0,1,11,19,141,0,15,4,0,0,0,[ "1"])), attr("name=", "in1", 0, 1, 1, text('green',112,88,1,0,4,1,1,0,1,88,19,142,0,15,4,0,0,0,[ "name=in1"])) ]), icon([ box('yellow',96,144,128,176,0,0,0,143,0,0,[ ]), box('yellow',108,156,116,164,2,0,1,144,0,0,[ ]) ], "pin",19,0,0,[ attr("name=", "in2", 0, 1, 1, text('green',112,136,1,0,4,1,1,0,1,88,19,145,0,15,4,0,0,0,[ "name=in2"])), attr("num=", "2", 1, 0, 1, text('green',128,144,1,0,4,1,1,0,1,11,19,146,0,15,4,0,0,0,[ "2"])) ]) ],[ attr("LOC=", "", 1, 1, 0, text('red',172,125,1,0,5,1,1,0,1,60,24,147,0,19,5,0,0,0,[ "LOC="])) ]). ������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/wb1.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000000544�11602233313�013625� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Renato Santana, <renato@nce.ufrj.br> in January, 1996. * * (Obsoleted in tgif-4.1.9 by the TangramII group at land.ufrj.br.) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb1.c,v 1.1 2004/06/18 23:19:10 william Exp $ */ #define _INCLUDE_FROM_WB1_C_ #include "tgifdefs.h" #ifdef _TGIF_WB #include "wb1.e" #endif /* _TGIF_WB */ ������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/dup.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000007136�11602233311�013730� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/dup.e,v 1.6 2011/05/16 16:21:57 william Exp $ */ #ifndef _DUP_E_ #define _DUP_E_ extern int justDupped; extern int useRecentDupDistance; extern int dupDx; extern int dupDy; #ifdef _INCLUDE_FROM_DUP_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_DUP_C_*/ extern void CopyObjId ARGS_DECL((struct ObjRec *From, struct ObjRec *To)); extern void CopyObjLocks ARGS_DECL((struct ObjRec *From, struct ObjRec *To)); extern void UnlockAnObj ARGS_DECL((struct ObjRec *From)); extern void DupObjXfrmMtrx ARGS_DECL((struct ObjRec *From, struct ObjRec *To)); extern void DupObjBasics ARGS_DECL((struct ObjRec *From, struct ObjRec *To)); extern void DupPolyObj ARGS_DECL((struct PolyRec *, struct ObjRec *)); extern void DupPolygonObj ARGS_DECL((struct PolygonRec *, struct ObjRec *)); extern void DupOvalObj ARGS_DECL((struct OvalRec *, struct ObjRec *)); extern void DupBoxObj ARGS_DECL((struct BoxRec *, struct ObjRec *)); extern void DupRCBoxObj ARGS_DECL((struct RCBoxRec *, struct ObjRec *)); extern void DupArcObj ARGS_DECL((struct ArcRec *, struct ObjRec *)); extern void DupXBmObj ARGS_DECL((struct XBmRec *, struct ObjRec *)); extern void DupXPmObj ARGS_DECL((struct XPmRec *, struct ObjRec *)); extern void DupStrSeg ARGS_DECL((StrBlockInfo*, StrSegInfo*)); extern void DupStrBlock ARGS_DECL((StrBlockInfo*, MiniLineInfo*, StrBlockInfo**, StrBlockInfo**)); extern void DupMiniLine ARGS_DECL((MiniLineInfo *pMiniLine, MiniLinesInfo *pOwnerMiniLines, StrBlockInfo *pOwnerBlock, MiniLineInfo **ppFirstMiniLine, MiniLineInfo **ppLastMiniLine)); extern void DupMiniLines ARGS_DECL((MiniLinesInfo *minilines, StrBlockInfo *pOwnerBlock, MiniLinesInfo **ppMiniLines)); extern void DupTextObj ARGS_DECL((struct TextRec *, struct ObjRec *From, struct ObjRec *To)); extern void DupConnection ARGS_DECL((struct ConnRec *From, struct ConnRec *To)); extern void DupGroupObj ARGS_DECL((struct GroupRec *, struct ObjRec *)); extern struct ObjRec * DupObj ARGS_DECL((struct ObjRec *)); extern void DupSelObj ARGS_DECL((void)); extern void DupTheseObjects ARGS_DECL((struct SelRec *Top, struct SelRec *Bot, struct SelRec **NewTop, struct SelRec **NewBot)); extern void JustDupSelObj ARGS_DECL((struct SelRec **NewTop, struct SelRec **NewBot)); #ifdef _INCLUDE_FROM_DUP_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_DUP_C_*/ #endif /*_DUP_E_*/ ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tidget.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000011065�11602233313�014416� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tidget.e,v 1.8 2011/05/16 16:22:00 william Exp $ */ #ifndef _TIDGET_E_ #define _TIDGET_E_ #include "tidget.h" #include "list.e" #define TDGT_NOTIFY ((long)0x80000002) typedef void (TidgetDrawMsgStringFunc)ARGS_DECL((Display*, Window, GC, int, int, char*, int)); typedef int (TidgetMsgTextWidthFunc)ARGS_DECL((XFontStruct*, char*, int)); typedef struct tagTidgetManager { GC gc; int want_all_key_press_events; TidgetInfo *key_press_base_tidgetinfo; Atom notify_atom; CVList toplevel_tidgets; /* list of (TidgetInfo*) */ } TidgetManager; extern TidgetManager gTidgetManager; #ifdef _INCLUDE_FROM_TIDGET_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TIDGET_C_*/ extern void TidgetWindowNotify ARGS_DECL((Window, int ctl_id, int nf_type, int nf_arg, int nf_arg2)); extern void TidgetNotify ARGS_DECL((TidgetInfo*, int ctl_id, int nf_type, int nf_arg, int nf_arg2)); extern void TidgetControlNotify ARGS_DECL((TidgetInfo*, int nf_type, int nf_arg, int nf_arg2)); extern int IsTdgtWindowNotifyEvent ARGS_DECL((Window, XEvent*, TdgtNtfy*)); extern int IsTdgtNotifyEvent ARGS_DECL((TidgetInfo*, XEvent*, TdgtNtfy*)); extern void TidgetDrawFocusRect ARGS_DECL((TidgetInfo*, SimpleWinInfo*)); extern void RedrawTidget ARGS_DECL((TidgetInfo*)); extern int TidgetEventHandler ARGS_DECL((TidgetInfo*, XEvent*, TidgetInfo *pti_handler_tidget)); extern int IsTidgetEvent ARGS_DECL((TidgetInfo*, XEvent*, TidgetInfo **ppti_handler_tidget_return)); extern void DestroyTidget ARGS_DECL((TidgetInfo**)); extern void SetTidgetInfoBasic ARGS_DECL((TidgetInfo*, int tidget_type, void *tidget, Window parent_win, int x, int y, int w, int h, int h_pad, int v_pad, int state, char *caption)); extern void TidgetCanHaveChildren ARGS_DECL((TidgetInfo*, int)); extern void TidgetSetCallbacks ARGS_DECL((TidgetInfo*, TidgetRedrawCallbackFunc*, TidgetEvHandlerCallbackFunc*, TidgetIsEventCallbackFunc*, TidgetDestroyCallbackFunc*, TidgetMapCallbackFunc*, TidgetMoveResizeCallbackFunc*, TidgetSendCmdCallbackFunc*)); extern TidgetInfo *NewTidgetInfo ARGS_DECL((TidgetInfo *parent_tidgetinfo, int type, void *tidget, int ctl_id, void *userdata)); extern void MapTidget ARGS_DECL((TidgetInfo*)); extern void TidgetMoveResize ARGS_DECL((TidgetInfo*, int x, int y, int w, int h)); extern void ResetTidgetCommon ARGS_DECL((TidgetCommonInfo*)); extern int TidgetSendCmd ARGS_DECL((TidgetInfo*, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); extern int TidgetDisableRedraw ARGS_DECL((TidgetInfo*, int)); extern int TidgetSetDirty ARGS_DECL((TidgetInfo*, int)); extern int TidgetHasFocus ARGS_DECL((void)); extern int TidgetSetHasFocus ARGS_DECL((int nHasFocus)); extern Window TidgetGetFocusWindow ARGS_DECL((void)); extern Window TidgetSetFocusWindow ARGS_DECL((Window)); extern int TidgetIsFocus ARGS_DECL((TidgetInfo*)); extern void TidgetGetFontInfo ARGS_DECL((int *pnFontIndex, int *pnSzUnit)); extern void TidgetGetFontInfoGivenStyle ARGS_DECL((int font_style, XFontStruct **pp_font_ptr, int *pn_font_width, int *pn_font_height, int *pn_font_asc, int *pn_font_des)); extern void TidgetManagerResetGC ARGS_DECL((void)); extern int TidgetManagerHandleEvent ARGS_DECL((XEvent*)); extern int TidgetManagerHandleAllKeyPressEvent ARGS_DECL((XEvent*)); extern int TidgetManagerWantAllKeyPressEvents ARGS_DECL((void)); extern int TidgetManagerSetWantAllKeyPressEvents ARGS_DECL((TidgetInfo*, int want_all_key_press_events)); extern int InitTidget ARGS_DECL((void)); extern void CleanUpTidget ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TIDGET_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TIDGET_C_*/ #endif /*_TIDGET_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/mainmenu.c���������������������������������������������������������������������������0000644�0000764�0000764�00000112103�11602233312�014737� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/mainmenu.c,v 1.8 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_MAINMENU_C_ #include "tgifdefs.h" #include "align.e" #include "choice.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "edit.e" #include "file.e" #include "font.e" #include "grid.e" #include "help.e" #include "imgproc.e" #include "mainloop.e" #include "mainmenu.e" #include "menu.e" #include "menuinfo.e" #include "msg.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "raster.e" #include "setup.e" #include "shape.e" #include "special.e" #include "stretch.e" #include "strtbl.e" #include "tangram2.e" #include "text.e" #include "util.e" #define DEF_MAINMENUPINDIST 80 int pinnedMainMenu=FALSE; int mainMenuPinDistance=DEF_MAINMENUPINDIST; Window mainMenuWindow=None; int numStacking=0; Window *stackingWins=NULL; int titledPinnedMenu=TRUE; int btn3PopupModeMenu=FALSE; static int mainMenuX=0; static int mainMenuY=0; static int mainMenuW=0; static int mainMenuH=0; typedef struct SubMenuRec { Window win; int x, y, w, h, extra_index; } * SubMenuRecPtr; static struct SubMenuRec subMenuInfo[MAXMENUS+1]; static int savedMainWinX, savedMainWinY; static void InitPinnedMenus() { int i; for (i=0; i < MAXMENUS+1; i++) subMenuInfo[i].win = None; } void InitMainMenu() { int menu_w, menu_h; int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); char *c_ptr; XWMHints wmhints; XSizeHints sizehints; XSetWindowAttributes win_attrs; mainMenuPinDistance = DEF_MAINMENUPINDIST; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MainMenuPinDistance")) != NULL) { mainMenuPinDistance = atoi(c_ptr); if (mainMenuPinDistance <= 0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "MainMenuPinDistance", c_ptr, DEF_MAINMENUPINDIST); fprintf(stderr, "%s\n", gszMsgBox); mainMenuPinDistance = DEF_MAINMENUPINDIST; } } pinnedMainMenu = FALSE; btn3PopupModeMenu = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"Btn3PopupModeMenu")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { fprintf(stderr, TgLoadString(STID_NAMED_XDEF_IS_OBSOLETE), TOOL_NAME, "Btn3PopupModeMenu"); fprintf(stderr, "\n"); } menuRowsBeforeScroll = 20; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MenuRowsBeforeScroll")) != NULL) { /* well, this is really not used, yet */ menuRowsBeforeScroll = atoi(c_ptr); if (menuRowsBeforeScroll <= 0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "MenuRowsBeforeScroll", c_ptr, 20); fprintf(stderr, "%s\n", gszMsgBox); menuRowsBeforeScroll = 20; } } menuColsBeforeScroll = 26; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MenuColsBeforeScroll")) != NULL) { /* well, this is really not used, yet */ menuColsBeforeScroll = atoi(c_ptr); if (menuColsBeforeScroll <= 0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "MenuColsBeforeScroll", c_ptr, 26); fprintf(stderr, "%s\n", gszMsgBox); menuColsBeforeScroll = 26; } } menu_w = defaultFontWidth; menu_h = defaultFontHeight; mainMenuX = 0; mainMenuY = 0; mainMenuW = menu_w+2*brdrW; mainMenuH = menu_h+2*brdrW; if ((mainMenuWindow=XCreateSimpleWindow(mainDisplay, rootWindow, 0, 0, menu_w, menu_h, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("InitMainMenu()", NULL, TRUE); } win_attrs.save_under = True; win_attrs.override_redirect = (titledPinnedMenu ? False : True); XChangeWindowAttributes(mainDisplay, mainMenuWindow, CWSaveUnder | CWOverrideRedirect, &win_attrs); XSelectInput(mainDisplay, mainMenuWindow, StructureNotifyMask | ExposureMask | ButtonPressMask | ButtonReleaseMask | KeyPressMask | EnterWindowMask | LeaveWindowMask); sizehints.flags = PSize | PMinSize | PMaxSize; sizehints.width = sizehints.min_width = sizehints.max_width = menu_w+2*brdrW; sizehints.height = sizehints.min_height = sizehints.max_height = menu_h+2*brdrW; sizehints.flags |= USPosition | PPosition; #ifdef NOTR4MODE XSetNormalHints(mainDisplay, mainMenuWindow, &sizehints); #else XSetWMNormalHints(mainDisplay, mainMenuWindow, &sizehints); #endif wmhints.flags = InputHint; wmhints.input = True; XSetWMHints(mainDisplay, mainMenuWindow, &wmhints); if (!titledPinnedMenu) { XSetTransientForHint(mainDisplay, mainMenuWindow, mainWindow); } RegisterWM_DELETE_WINDOW(mainMenuWindow); XStoreName(mainDisplay, mainMenuWindow, TgLoadCachedString(CSTID_MAIN_MENU)); InitPinnedMenus(); } void CleanUpMainMenu() { int i; XDestroyWindow(mainDisplay, mainMenuWindow); for (i=0; i < MAXMENUS+1; i++) { if (subMenuInfo[i].win != None) { XDestroyWindow(mainDisplay, subMenuInfo[i].win); } subMenuInfo[i].win = None; } } static int mainMenuMoveDX=0, mainMenuMoveDY=0; void SaveMainWinPosition(x, y) unsigned int x, y; { mainMenuMoveDX = x - savedMainWinX; mainMenuMoveDY = y - savedMainWinY; savedMainWinX = x; savedMainWinY = y; } void MoveMainMenuWindow(x, y) unsigned int x, y; { mainMenuMoveDX = x - savedMainWinX; mainMenuMoveDY = y - savedMainWinY; if (x == savedMainWinX && y == savedMainWinX) return; mainMenuX += mainMenuMoveDX; mainMenuY += mainMenuMoveDY; /* no need to move the windows */ /* XMoveWindow(mainDisplay, mainMenuWindow, mainMenuX, mainMenuY); */ savedMainWinX = x; savedMainWinY = y; } void GetPopupXY(win, px, py) Window win; int *px, *py; { *px = *py = 0; for (;;) { Window root_win=None, parent_win=None, *child_wins=NULL; unsigned int num_child=0; XWindowAttributes win_attrs; XGetWindowAttributes(mainDisplay, win, &win_attrs); *px += win_attrs.x; *py += win_attrs.y; if (XQueryTree(mainDisplay, win, &root_win, &parent_win, &child_wins, &num_child) == 0) { return; } if (child_wins != NULL) XFree((void*)child_wins); if (parent_win != rootWindow) { win = parent_win; } else { break; } } } void GetPopupWH(win, pw, ph) Window win; int *pw, *ph; { XWindowAttributes win_attrs; XGetWindowAttributes(mainDisplay, win, &win_attrs); *pw = win_attrs.width; *ph = win_attrs.height; } static char checkExtra[33]; void SaveStackingOrder() { register int i, j; register unsigned char hash_value; Window root_win, parent_win, *child_wins=NULL; unsigned int num_child; for (i=0; i < 33; i++) checkExtra[i] = '\0'; if (pinnedMainMenu) { hash_value = mainMenuWindow & 0xff; checkExtra[hash_value>>3] |= (1<<(hash_value&0x7)); } for (i = 0; i < numExtraWins; i++) { if (extraWinInfo[i].raise && extraWinInfo[i].mapped && extraWinInfo[i].window != None) { hash_value = extraWinInfo[i].window & 0xff; checkExtra[hash_value>>3] |= (1<<(hash_value&0x7)); } } XQueryTree(mainDisplay, rootWindow, &root_win, &parent_win, &child_wins, &num_child); numStacking = 0; if (stackingWins != NULL) free(stackingWins); stackingWins = (Window*)malloc((numExtraWins+1)*sizeof(Window)); if (stackingWins == NULL) FailAllocMessage(); for (i = 0; i < num_child; i++) { hash_value = child_wins[i] & 0xff; if (checkExtra[hash_value>>3] & (1<<(hash_value&0x7))) { if (child_wins[i] == mainMenuWindow) { stackingWins[numStacking++] = mainMenuWindow; } else { for (j = 0; j < numExtraWins; j++) { if (extraWinInfo[j].raise && extraWinInfo[j].mapped && extraWinInfo[j].window == child_wins[i]) { stackingWins[numStacking++] = child_wins[i]; break; } } } } } if (child_wins != NULL) XFree((void*)child_wins); } static void RepositionSubMenuWindow(win, menu_index, OrigCursorX, OrigCursorY) Window win; int menu_index, OrigCursorX, OrigCursorY; { int moving=TRUE, x, y, w, h; XEvent input; x = subMenuInfo[menu_index].x; y = subMenuInfo[menu_index].y; w = subMenuInfo[menu_index].w; h = subMenuInfo[menu_index].h; if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, win, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } XSetSubwindowMode(mainDisplay, revDefaultGC, IncludeInferiors); XDrawRectangle(mainDisplay, rootWindow, revDefaultGC, x, y, w, h); while (moving) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { XDrawRectangle(mainDisplay, rootWindow, revDefaultGC, x, y, w, h); XSetSubwindowMode(mainDisplay, revDefaultGC, ClipByChildren); XMoveWindow(mainDisplay, win, x, y); XRaiseWindow(mainDisplay, win); subMenuInfo[menu_index].x = x; subMenuInfo[menu_index].y = y; moving = FALSE; XUngrabPointer(mainDisplay, CurrentTime); XDefineCursor(mainDisplay, win, defaultCursor); } else if (input.type == MotionNotify) { XDrawRectangle(mainDisplay, rootWindow, revDefaultGC, x, y, w, h); x = input.xbutton.x_root-OrigCursorX+subMenuInfo[menu_index].x; y = input.xbutton.y_root-OrigCursorY+subMenuInfo[menu_index].y; XDrawRectangle(mainDisplay, rootWindow, revDefaultGC, x, y, w, h); } } } static void TgSubMenuExposeHandler(input, win_info) XEvent *input; struct WinInfoRec *win_info; { int menu_index; Window win; XEvent ev; win = input->xany.window; while (XCheckWindowEvent(mainDisplay, win, ExposureMask, &ev)); while (XCheckWindowEvent(mainDisplay, win, StructureNotifyMask, &ev)); for (menu_index=0; menu_index <= MAXMENUS+1; menu_index++) { if (subMenuInfo[menu_index].win == win && win != None) { TgMenu *menu=(TgMenu*)(win_info->userdata); if (menu != NULL) TgDrawEntireMenu(menu); break; } } } static void ComputeSubMenuWinXY(win, x, y) Window win; int *x, *y; { int win_x, win_y, done=FALSE; unsigned int win_w, win_h, win_brdr_w, win_d, num_child; Window root_win, parent_win, *child_wins=NULL; *x = *y = 0; while (!done) { XGetGeometry(mainDisplay, win, &root_win, &win_x, &win_y, &win_w, &win_h, &win_brdr_w, &win_d); *x += win_x; *y += win_y; if (XQueryTree(mainDisplay, win, &root_win, &parent_win, &child_wins, &num_child) == 0) { return; } if (child_wins != NULL) XFree((void*)child_wins); if (parent_win == rootWindow) { done = TRUE; } else { win = parent_win; } } } static void TgUpdateMenuBBox(menu, pn_win_x, pn_win_y) TgMenu *menu; int *pn_win_x, *pn_win_y; { int dx=0, dy=0; ComputeSubMenuWinXY(menu->window, pn_win_x, pn_win_y); dx = (*pn_win_x) - menu->bbox.ltx; dy = (*pn_win_y) - menu->bbox.lty; menu->bbox.ltx += dx; menu->bbox.lty += dy; menu->bbox.rbx += dx; menu->bbox.rby += dy; } static void TgShowPullDownStatus(menu, new_selected) TgMenu *menu; int new_selected; { TgMenuItem *menuitems=menu->menuitems; if (menuitems[new_selected].status_str != NULL) { if (!titledPinnedMenu) { SetMouseStatus(TgLoadCachedString(CSTID_MOVE_PINNED_MENU), menuitems[new_selected].status_str, TgLoadCachedString(CSTID_CLOSE_PINNED_MENU)); } else { SetMouseStatus(menuitems[new_selected].status_str, "", TgLoadCachedString(CSTID_CLOSE_PINNED_MENU)); } } } static void TgPullDownFromSubMenu(menu, new_selected) TgMenu *menu; int new_selected; { TgMenuItem *menuitems=menu->menuitems; int rc=BAD, last_selected_non_submenu_item=FALSE; XEvent ev; while (rc == BAD || rc == (-3)) { if (new_selected != INVALID && (menuitems[new_selected].flags & TGMU_DISABLED) == 0) { if ((menuitems[new_selected].flags & TGMU_HAS_SUBMENU) == TGMU_HAS_SUBMENU && menuitems[new_selected].submenu_create_info != NULL) { /* * highlight the submenu item, popup the submenu, * and unhighlight it */ int win_x=0, win_y=0; TgMenu *submenu=NULL; menuitems[new_selected].state = TGBS_RAISED; TgDrawMenuItem(menu, &menuitems[new_selected]); TgShowPullDownStatus(menu, new_selected); TgUpdateMenuBBox(menu, &win_x, &win_y); submenu = TgCreatePopUpSubMenu(menu, new_selected); if (submenu != NULL) { submenu->track_menubar = FALSE; submenu->track_parent_menu = TRUE; rc = TgPopUpSubMenu(menu, win_x, win_y); submenu = menuitems[new_selected].detail.submenu; if (submenu != NULL) { TgDestroyMenu(submenu, TRUE); menuitems[new_selected].detail.submenu = NULL; } } menuitems[menu->selected_index].state = TGBS_NORMAL; TgDrawMenuItem(menu, &menuitems[menu->selected_index]); } else { if (new_selected != last_selected_non_submenu_item) { menuitems[new_selected].state = TGBS_RAISED; TgDrawMenuItem(menu, &menuitems[new_selected]); TgShowPullDownStatus(menu, new_selected); last_selected_non_submenu_item = new_selected; } } } if (rc == BAD || rc == (-3)) { Window root_win, child_win; int mouse_x, mouse_y, root_x, root_y; unsigned int status; XQueryPointer(mainDisplay, menu->window, &root_win, &child_win, &root_x, &root_y, &mouse_x, &mouse_y, &status); new_selected = TgWhichMenuIndex(menu, mouse_x, mouse_y, TRUE); if (!(status & BUTTONSMASK)) { break; } if (!(status & BUTTONSMASK) && !(mouse_x >= 0 && mouse_x < menu->bbox.rbx-menu->bbox.ltx && mouse_y >= 0 && mouse_y < menu->bbox.rby-menu->bbox.lty)) { break; } if (new_selected != last_selected_non_submenu_item && last_selected_non_submenu_item != INVALID) { menuitems[last_selected_non_submenu_item].state = TGBS_NORMAL; TgDrawMenuItem(menu, &menuitems[last_selected_non_submenu_item]); last_selected_non_submenu_item = INVALID; } switch (new_selected) { case INVALID: break; case (-2): new_selected = INVALID; break; /* separator */ case (-3): new_selected = INVALID; break; /* scrollbar */ default: break; } menu->selected_index = new_selected; } } XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, menu->window, ButtonPressMask|ButtonReleaseMask|PointerMotionMask, &ev)) ; } static int MouseInsideWindow(win, win_w, win_h) Window win; int win_w, win_h; { Window root_win, child_win; int x, y, root_x, root_y; unsigned int status; XQueryPointer(mainDisplay, win, &root_win, &child_win, &root_x, &root_y, &x, &y, &status); return (x >= 0 && x < win_w && y >=0 && y < win_h); } static int TgSubMenuEventHandler(input, win_info) XEvent *input; struct WinInfoRec *win_info; { static TgMenu *clicked_menu=NULL; static int clicked_index=INVALID; TgMenu *menu=(TgMenu*)(win_info->userdata); TgMenuItem *menuitems=menu->menuitems; int menu_index=INVALID, new_selected=INVALID, rc=INVALID; int menu_w=menu->bbox.rbx-menu->bbox.ltx+((menu->padding)<<1); int menu_h=menu->bbox.rby-menu->bbox.lty+((menu->padding)<<1); XButtonEvent *button_ev=NULL; XEvent ev; Window win=None; if (input->type == MapNotify || input->type == Expose) { TgSubMenuExposeHandler(input, win_info); clicked_menu = NULL; clicked_index = INVALID; return INVALID; } if (menu == NULL) return INVALID; win = input->xany.window; for (menu_index=0; menu_index <= MAXMENUS; menu_index++) { if (subMenuInfo[menu_index].win == win && win != None) { break; } } if (menu_index > MAXMENUS) return INVALID; if (menu->scroll_start > 0) { switch (menu->type) { case TGMUTYPE_TEXT: menu_w += scrollBarW + menu->padding; menu_h = maxScrollableMenuHeight; break; case TGMUTYPE_COLOR: case TGMUTYPE_BITMAP: menu_w = maxScrollableMenuWidth; menu_h += scrollBarW + menu->padding; break; } } menu->parent_menu = NULL; if (input->type == MotionNotify || input->type == ButtonPress || input->type == ButtonRelease) { if (!MouseInsideWindow(menu->window, menu_w, menu_h)) { return INVALID; } } if (input->type == ConfigureNotify) { ComputeSubMenuWinXY(win, &(subMenuInfo[menu_index].x), &(subMenuInfo[menu_index].y)); clicked_menu = NULL; clicked_index = INVALID; } else if (input->type == EnterNotify) { if (menu->selected_index != INVALID) { menuitems[menu->selected_index].state = TGBS_NORMAL; TgDrawMenuItem(menu, &menuitems[menu->selected_index]); } menu->selected_index = INVALID; clicked_menu = NULL; clicked_index = INVALID; SetStringStatus(""); } else if (input->type == LeaveNotify) { if (menu->selected_index != INVALID) { menuitems[menu->selected_index].state = TGBS_NORMAL; TgDrawMenuItem(menu, &menuitems[menu->selected_index]); } clicked_menu = NULL; clicked_index = INVALID; menu->selected_index = INVALID; } else if (input->type == MotionNotify) { while (XCheckWindowEvent(mainDisplay, menu->window, PointerMotionMask, &ev)) ; new_selected = TgWhichMenuIndex(menu, input->xmotion.x, input->xmotion.y, FALSE); if (menu->selected_index != new_selected) { if (menu->selected_index != INVALID) { menuitems[menu->selected_index].state = TGBS_NORMAL; TgDrawMenuItem(menu, &menuitems[menu->selected_index]); } switch (new_selected) { case INVALID: break; case (-2): new_selected = INVALID; break; /* separator */ case (-3): new_selected = INVALID; break; /* scrollbar */ default: break; } if (new_selected != INVALID) { menuitems[new_selected].state = TGBS_RAISED; TgDrawMenuItem(menu, &menuitems[new_selected]); TgShowPullDownStatus(menu, new_selected); } menu->selected_index = new_selected; if (clicked_menu != NULL && clicked_index != INVALID) { clicked_index = INVALID; } } } else if (input->type == ButtonPress) { button_ev = &(input->xbutton); switch (button_ev->button) { case Button1: if (!titledPinnedMenu) { RepositionSubMenuWindow(win, menu_index, button_ev->x_root, button_ev->y_root); break; } /* dropping through if titledPinnedMenu ! */ case Button2: new_selected = TgWhichMenuIndex(menu, button_ev->x, button_ev->y, FALSE); clicked_menu = menu; clicked_index = (new_selected < 0 ? INVALID : new_selected); if (new_selected != INVALID) { if (menu->selected_index != new_selected) { if (menu->selected_index != INVALID) { menuitems[menu->selected_index].state = TGBS_NORMAL; TgDrawMenuItem(menu, &menuitems[menu->selected_index]); } switch (new_selected) { case INVALID: break; case (-2): new_selected = INVALID; break; /* separator */ case (-3): /* scrollbar */ if (menu->scroll_start > 0) { /* loop to scroll */ ScrollMenu(menu, button_ev->x, button_ev->y, menu_w, menu_h, (button_ev->button == Button1 ? Button1Mask : Button2Mask)); } new_selected = INVALID; break; default: break; } if (new_selected != INVALID) { menuitems[new_selected].state = TGBS_RAISED; TgDrawMenuItem(menu, &menuitems[new_selected]); TgShowPullDownStatus(menu, new_selected); } menu->selected_index = new_selected; } if (new_selected != INVALID && (menuitems[new_selected].flags & TGMU_HAS_SUBMENU) == TGMU_HAS_SUBMENU && (menuitems[new_selected].flags & TGMU_DISABLED) == 0 && menuitems[new_selected].submenu_create_info != NULL) { TgPullDownFromSubMenu(menu, new_selected); clicked_index = INVALID; } } break; case Button3: if (TgWhichMenuIndex(menu, button_ev->x, button_ev->y, FALSE) != (-3)) { clicked_menu = NULL; clicked_index = INVALID; } else if (!threeDLook && menu->scroll_start > 0) { /* loop to scroll */ ScrollMenu(menu, button_ev->x, button_ev->y, menu_w, menu_h, Button3Mask); } break; } } else if (input->type == ButtonRelease) { button_ev = &(input->xbutton); switch (button_ev->button) { case Button1: if (!titledPinnedMenu) { break; } /* dropping through if titledPinnedMenu ! */ case Button2: new_selected = TgWhichMenuIndex(menu, button_ev->x, button_ev->y, FALSE); if (new_selected != INVALID) { if (menu->selected_index != new_selected) { if (menu->selected_index != INVALID) { menuitems[menu->selected_index].state = TGBS_NORMAL; TgDrawMenuItem(menu, &menuitems[menu->selected_index]); } switch (new_selected) { case INVALID: break; case (-2): new_selected = INVALID; break; /* separator */ case (-3): new_selected = INVALID; break; /* scrollbar */ default: break; } if (new_selected != INVALID) { menuitems[new_selected].state = TGBS_RAISED; TgDrawMenuItem(menu, &menuitems[new_selected]); TgShowPullDownStatus(menu, new_selected); } menu->selected_index = new_selected; } if (new_selected != INVALID && (menuitems[new_selected].flags & TGMU_HAS_SUBMENU) == TGMU_HAS_SUBMENU && (menuitems[new_selected].flags & TGMU_DISABLED) == 0 && menuitems[new_selected].submenu_create_info != NULL) { TgPullDownFromSubMenu(menu, new_selected); clicked_index = INVALID; } else if (menu->menuitems[new_selected].cmdid != INVALID && ((menu->menuitems[new_selected].flags & TGMU_DISABLED) != TGMU_DISABLED)) { if (clicked_menu != NULL && clicked_index != INVALID && clicked_index == new_selected) { SendCommandToSelf(menu->menuitems[new_selected].cmdid, new_selected); } } } break; case Button3: if (TgWhichMenuIndex(menu, button_ev->x, button_ev->y, FALSE) != (-3)) { if (button_ev->x>=0 && button_ev->x<=subMenuInfo[menu_index].w && button_ev->y>=0 && button_ev->y<=subMenuInfo[menu_index].h) { XDestroyWindow(mainDisplay, subMenuInfo[menu_index].win); subMenuInfo[menu_index].win = None; extraWinInfo[subMenuInfo[menu_index].extra_index].window = None; TgDestroyMenu(menu, TRUE); win_info->userdata = NULL; } clicked_menu = NULL; clicked_index = INVALID; } break; } } else if (IsWM_DELETE_WINDOW(input)) { XDestroyWindow(mainDisplay, subMenuInfo[menu_index].win); subMenuInfo[menu_index].win = None; extraWinInfo[subMenuInfo[menu_index].extra_index].window = None; TgDestroyMenu(menu, TRUE); win_info->userdata = NULL; clicked_menu = NULL; clicked_index = INVALID; } return rc; } static void TgSubMenuCleanUp(win_info) struct WinInfoRec *win_info; { TgMenu *menu=(TgMenu*)(win_info->userdata); if (menu != NULL) { TgDestroyMenu(menu, TRUE); win_info->userdata = NULL; } } Window TgRealizePinnedMenuWindow(menu, win_x, win_y, win_w, win_h) TgMenu *menu; int win_x, win_y, win_w, win_h; { Window win; XWMHints wmhints; XSizeHints sizehints; XSetWindowAttributes win_attrs; TgMenu *dup_menu=NULL; int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); TgMenuItemInfo *item_info=NULL; win_w -= (brdrW<<1); win_h -= (brdrW<<1); if ((win=XCreateSimpleWindow(mainDisplay, rootWindow, win_x, win_y, win_w, win_h, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("TgRealizePinnedMenuWindow()", NULL, TRUE); } XDefineCursor(mainDisplay, win, defaultCursor); win_attrs.save_under = True; win_attrs.override_redirect = (titledPinnedMenu ? False : True); win_attrs.colormap = mainColormap; XChangeWindowAttributes(mainDisplay, win, CWSaveUnder | CWOverrideRedirect | CWColormap, &win_attrs); if (!titledPinnedMenu) { XSetTransientForHint(mainDisplay, win, mainWindow); } if (activeMenu == MENU_MAIN) { XStoreName(mainDisplay, win, TgLoadCachedString(CSTID_MAIN_MENU)); } else { for (item_info=mainMenuInfo.items; item_info->menu_str != NULL; item_info++) { if (item_info->menu_str != TGMUITEM_SEPARATOR && item_info->cmdid == activeMenu) { XStoreName(mainDisplay, win, item_info->status_str); break; } } } sizehints.flags = PSize | PMinSize | PMaxSize; sizehints.width = sizehints.min_width = sizehints.max_width = win_w; sizehints.height = sizehints.min_height = sizehints.max_height = win_h; sizehints.flags |= USPosition | PPosition; #ifdef NOTR4MODE XSetNormalHints(mainDisplay, win, &sizehints); #else XSetWMNormalHints(mainDisplay, win, &sizehints); #endif wmhints.flags = InputHint; wmhints.input = True; XSetWMHints(mainDisplay, win, &wmhints); RegisterWM_DELETE_WINDOW(win); #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, win); XSelectInput(mainDisplay, win, StructureNotifyMask | ExposureMask | ButtonPressMask | ButtonReleaseMask | KeyPressMask | EnterWindowMask | LeaveWindowMask | PointerMotionMask); #else XSelectInput(mainDisplay, win, StructureNotifyMask | ExposureMask | ButtonPressMask | ButtonReleaseMask | KeyPressMask | EnterWindowMask | LeaveWindowMask | PointerMotionMask); XMapWindow(mainDisplay, win); #endif if (subMenuInfo[activeMenu].win != None) { int extra_index=subMenuInfo[activeMenu].extra_index; XDestroyWindow(mainDisplay, subMenuInfo[activeMenu].win); extraWinInfo[extra_index].window = None; TgDestroyMenu(menu, FALSE); dup_menu = (TgMenu*)(extraWinInfo[extra_index].userdata); } else { if ((dup_menu=(TgMenu*)malloc(sizeof(TgMenu))) == NULL) { FailAllocMessage(); } memcpy(dup_menu, menu, sizeof(TgMenu)); } dup_menu->window = win; subMenuInfo[activeMenu].extra_index = AddExtraWinInfo(win, TRUE, TRUE, TgSubMenuExposeHandler, TgSubMenuEventHandler, TgSubMenuCleanUp, dup_menu); subMenuInfo[activeMenu].x = win_x; subMenuInfo[activeMenu].y = win_y; subMenuInfo[activeMenu].w = win_w; subMenuInfo[activeMenu].h = win_h; subMenuInfo[activeMenu].win = win; XDestroyWindow(mainDisplay, menu->window); menu->window = None; memset(menu, 0, sizeof(TgMenu)); return win; } int TgWindowIsPinnedMenu(win, menu_index) Window win; int menu_index; { return (subMenuInfo[menu_index].win != None && subMenuInfo[menu_index].win == win); } int TgHandlePinnedMenuEvent(win, menu_index, input) Window win; int menu_index; XEvent *input; { if (TgWindowIsPinnedMenu(win, menu_index)) { int extra_win_info_index=subMenuInfo[menu_index].extra_index; return (*(extraWinInfo[extra_win_info_index].ev_handler))( input, &extraWinInfo[extra_win_info_index]); } return INVALID; } void UpdatePinnedMenu(menu_index) int menu_index; { Window win=subMenuInfo[menu_index].win; if (win != None) { int extra_win_info_index=subMenuInfo[menu_index].extra_index; if (extra_win_info_index >= 0 && extra_win_info_index < numExtraWins && extraWinInfo[extra_win_info_index].window == win) { TgMenu *menu=(TgMenu*)(extraWinInfo[extra_win_info_index].userdata); if (menu != NULL) { switch (menu_index) { case MENU_FILE: RefreshFileMenu(menu); break; case MENU_EDIT: RefreshEditMenu(menu); break; case MENU_LAYOUT: RefreshLayoutMenu(menu); break; case MENU_ARRANGE: RefreshArrangeMenu(menu); break; case MENU_PROPERTIES: RefreshPropertiesMenu(menu); break; case MENU_MOVEMODE: RefreshMoveModeMenu(menu); break; case MENU_HORIALIGN: RefreshHoriAlignMenu(menu); break; case MENU_VERTALIGN: RefreshVertAlignMenu(menu); break; case MENU_FONT: RefreshFontMenu(menu); break; case MENU_STYLE: RefreshFontStyleMenu(menu); break; case MENU_SIZE: RefreshFontSizeMenu(menu); break; case MENU_SHAPE: RefreshShapeMenu(menu); break; case MENU_STRETCHTEXT: RefreshStretchableTextModeMenu(menu); break; case MENU_TRANSPAT: RefreshTransPatModeMenu(menu); break; case MENU_LINEWIDTH: RefreshLineWidthMenu(menu); break; case MENU_LINESTYLE: RefreshLineStyleMenu(menu); break; case MENU_LINETYPE: RefreshLineTypeMenu(menu); break; case MENU_LINEDASH: RefreshLineDashMenu(menu); break; case MENU_FILL: RefreshFillMenu(menu); break; case MENU_PEN: RefreshPenMenu(menu); break; case MENU_COLOR: RefreshColorMenu(menu); break; case MENU_IMAGEPROC: RefreshImageProcMenu(menu); break; case MENU_NAVIGATE: RefreshNavigateMenu(menu); break; case MENU_SPECIAL: RefreshSpecialMenu(menu); break; case MENU_PAGE: RefreshPageMenu(menu); break; case MENU_PAGELAYOUT: RefreshPageLayoutMenu(menu); break; case MENU_HELP: RefreshHelpMenu(menu); break; case MENU_TANGRAM2: if (cmdLineTgrm2) { RefreshTangram2Menu(menu); } break; case MENU_MODE: RefreshModeMenu(menu); break; case MENU_MAIN: RefreshMainMenu(menu); break; } TgDrawEntireMenu(menu); return; } } } } void UpdateAllPinnedMenus() { UpdatePinnedMenu(MENU_HORIALIGN); UpdatePinnedMenu(MENU_VERTALIGN); UpdatePinnedMenu(MENU_STYLE); UpdatePinnedMenu(MENU_FONT); UpdatePinnedMenu(MENU_SIZE); UpdatePinnedMenu(MENU_LINEWIDTH); UpdatePinnedMenu(MENU_LINESTYLE); UpdatePinnedMenu(MENU_LINETYPE); UpdatePinnedMenu(MENU_LINEDASH); UpdatePinnedMenu(MENU_LAYOUT); UpdatePinnedMenu(MENU_MOVEMODE); UpdatePinnedMenu(MENU_STRETCHTEXT); UpdatePinnedMenu(MENU_TRANSPAT); UpdatePinnedMenu(MENU_PAGELAYOUT); UpdatePinnedMenu(MENU_MAIN); } void UseWireMenuItemInModeItem(connecting) int connecting; { Window win=subMenuInfo[MENU_MODE].win; if (win != None) { int extra_win_info_index=subMenuInfo[MENU_MODE].extra_index; if (extra_win_info_index >= 0 && extra_win_info_index < numExtraWins && extraWinInfo[extra_win_info_index].window == win) { TgMenu *menu=(TgMenu*)(extraWinInfo[extra_win_info_index].userdata); if (menu != NULL) { TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); if (connecting) { stMenuItem.menu_str = (char*)(&wireBitmap); } else { stMenuItem.menu_str = (char*)(&choicePixmap[DRAWPOLY]); } if (!TgSetMenuItemInfo(&menu->menuitems[DRAWPOLY], TGMU_MASK_MENUSTR, &stMenuItem)) { } return; } } } } void DestroyPinnedMenu(menu_index) int menu_index; { if (subMenuInfo[menu_index].win != None) { int extra_index=subMenuInfo[menu_index].extra_index; TgMenu *menu=(TgMenu*)(extraWinInfo[extra_index].userdata); XDestroyWindow(mainDisplay, subMenuInfo[menu_index].win); subMenuInfo[menu_index].win = None; extraWinInfo[extra_index].window = None; if (menu != NULL) { TgDestroyMenu(menu, TRUE); extraWinInfo[extra_index].userdata = NULL; } } } static IntPoint gaPopupCoords[MAXMENUS+5]; void HidePopupMenusForSlideShow() { int adj_caches=(zoomScale!=0 || zoomedIn!=FALSE); int menu_index=0, draw_win_x=0, draw_win_y=0, draw_win_w=0, draw_win_h=0; int dpy_w=DisplayWidth(mainDisplay,mainScreen); int dpy_h=DisplayHeight(mainDisplay,mainScreen); for (menu_index=0; menu_index <= MAXMENUS; menu_index++) { if (subMenuInfo[menu_index].win != None) { GetPopupXY(subMenuInfo[menu_index].win, &gaPopupCoords[menu_index].x, &gaPopupCoords[menu_index].y); XMoveWindow(mainDisplay, subMenuInfo[menu_index].win, -dpy_w, -dpy_h); } } GetPopupXY(drawWindow, &draw_win_x, &draw_win_y); GetPopupWH(drawWindow, &draw_win_w, &draw_win_h); GetPopupXY(mainWindow, &gaPopupCoords[MAXMENUS+1].x, &gaPopupCoords[MAXMENUS+1].y); GetPopupWH(mainWindow, &gaPopupCoords[MAXMENUS+2].x, &gaPopupCoords[MAXMENUS+2].y); gaPopupCoords[MAXMENUS+3].x = drawOrigX; gaPopupCoords[MAXMENUS+3].y = drawOrigY; gaPopupCoords[MAXMENUS+4].x = zoomedIn; gaPopupCoords[MAXMENUS+4].y = zoomScale; if (gaPopupCoords[MAXMENUS+3].x != 0 || gaPopupCoords[MAXMENUS+3].y != 0 || adj_caches) { drawOrigX = drawOrigY = 0; zoomedIn = FALSE; zoomScale = 0; UpdDrawWinWH(); UpdDrawWinBBox(); ClearObjCachesInAllPages(); if (adj_caches) { ShowZoom(); } } #ifndef NOKDE3BUG XMoveResizeWindow(mainDisplay, mainWindow, 0, 0, dpy_w+gaPopupCoords[MAXMENUS+2].x-draw_win_w+2, dpy_h+gaPopupCoords[MAXMENUS+2].y-draw_win_h+2); #endif /* ~NOKDE3BUG */ XMoveResizeWindow(mainDisplay, mainWindow, gaPopupCoords[MAXMENUS+1].x-draw_win_x-1, gaPopupCoords[MAXMENUS+1].y-draw_win_y-1, dpy_w+gaPopupCoords[MAXMENUS+2].x-draw_win_w+2, dpy_h+gaPopupCoords[MAXMENUS+2].y-draw_win_h+2); } void ShowPopupMenusForSlideShow() { int menu_index=0; zoomScale = gaPopupCoords[MAXMENUS+4].y; zoomScale = gaPopupCoords[MAXMENUS+4].y; drawOrigX = gaPopupCoords[MAXMENUS+3].x; drawOrigY = gaPopupCoords[MAXMENUS+3].y; drawWinW = gaPopupCoords[MAXMENUS+2].x; drawWinH = gaPopupCoords[MAXMENUS+2].y; XMoveResizeWindow(mainDisplay, mainWindow, gaPopupCoords[MAXMENUS+1].x, gaPopupCoords[MAXMENUS+1].y, gaPopupCoords[MAXMENUS+2].x, gaPopupCoords[MAXMENUS+2].y); InitWinSizes(); for (menu_index=0; menu_index <= MAXMENUS; menu_index++) { if (subMenuInfo[menu_index].win != None) { XMoveWindow(mainDisplay, subMenuInfo[menu_index].win, gaPopupCoords[menu_index].x, gaPopupCoords[menu_index].y); UpdatePinnedMenu(menu_index); } } } void EnumPopupMenuWindow(pFunc, pUserData) ENUMPOPUPMENUFN *pFunc; void *pUserData; { int menu_index=0; for (menu_index=0; menu_index <= MAXMENUS; menu_index++) { if (subMenuInfo[menu_index].win != None) { if (!((pFunc)(menu_index, subMenuInfo[menu_index].win, pUserData))) { break; } } } } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/eq4-2x-jpg.sym�����������������������������������������������������������������������0000644�0000764�0000764�00000032635�11602233311�015324� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.2.2 state(0,37,100.000,0,0,0,8,1,3,1,1,0,0,1,0,1,0,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/eq4-2x-jpg.sym,v 1.3 2009/11/01 00:45:28 cvsps Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1 ]). slideshow_info('',-20,-20). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). dont_reencode("UtopiaFS:FFDingbests:ZapfDingbats"). ps_font_aliases([ "UtopiaFS-Regular=Utopia-Regular", "UtopiaFS-Bold=Utopia-Bold", "UtopiaFS-Italic=Utopia-Italic", "UtopiaFS-BoldItalic=Utopia-BoldItalic" ]). objshadow_info('#c0c0c0',2,2). rotate_pivot(0,0,0,0). spline_tightness(1). right_margin(1,480597). page(1,"2x resolution LaTeX equation symbol.",1,''). sym([ polygon('#0000ff','',5,[ 64,132,68,132,68,128,64,128,64,132],0,1,0,0,212,0,0,0,0,0,'1',0, "00",[ ]) ], 1116,0,0,[ attr("footer=", "", 0, 1, 0, text('#ff00ff',64,-19,3,0,1,112,42,613,11,3,0,0,0,0,2,112,42,0,0,"",0,0,0,0,-8,'',[ minilines(112,42,0,0,0,0,0,[ mini_line(56,11,3,0,0,0,[ str_block(0,56,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,56,11,3,0,0,0,0,0,0,0, "footer=")]) ]), mini_line(8,11,3,0,0,0,[ str_block(0,8,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,8,11,3,0,0,0,0,0,0,0, "%")]) ]), mini_line(112,11,3,0,0,0,[ str_block(0,112,11,3,0,-3,0,0,0,[ str_seg('#0000ff','Courier',0,80640,112,11,3,0,-3,0,0,0,0,0, "\\end{document}")]) ]) ])])), attr("header=", "", 0, 1, 0, text('#ff00ff',240,-19,11,0,1,240,154,608,11,3,0,0,0,0,2,240,154,0,0,"",0,0,0,0,-8,'',[ minilines(240,154,0,0,0,0,0,[ mini_line(56,11,3,0,0,0,[ str_block(0,56,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,56,11,3,0,0,0,0,0,0,0, "header=")]) ]), mini_line(232,11,3,0,0,0,[ str_block(0,232,11,3,0,-3,0,0,0,[ str_seg('#0000ff','Courier',0,80640,232,11,3,0,-3,0,0,0,0,0, "\\documentstyle[12pt]{article}")]) ]), mini_line(144,11,3,0,0,0,[ str_block(0,144,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,11,3,0,0,0,0,0,0,0, "\\oddsidemargin=0in")]) ]), mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,0,0,0,0,0,0, "\\textwidth=6.5in")]) ]), mini_line(112,11,3,0,0,0,[ str_block(0,112,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,112,11,3,0,0,0,0,0,0,0, "\\topmargin=0in")]) ]), mini_line(136,11,3,0,0,0,[ str_block(0,136,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,136,11,3,0,-1,0,0,0,0,0, "\\textheight=609pt")]) ]), mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "\\parskip=14pt")]) ]), mini_line(240,11,3,0,0,0,[ str_block(0,240,11,3,0,-3,0,0,0,[ str_seg('#0000ff','Courier',0,80640,240,11,3,0,-3,0,0,0,0,0, "\\setlength{\\unitlength}{0.5cm}")]) ]), mini_line(136,11,3,0,0,0,[ str_block(0,136,11,3,0,-3,0,0,0,[ str_seg('#0000ff','Courier',0,80640,136,11,3,0,-3,0,0,0,0,0, "\\pagestyle{empty}")]) ]), mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-3,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-3,0,0,0,0,0, "\\begin{document}")]) ]), mini_line(8,11,3,0,0,0,[ str_block(0,8,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,8,11,3,0,0,0,0,0,0,0, "%")]) ]) ])])), attr("exec=", "", 0, 1, 0, text('blue',64,-270,8,0,1,424,112,1483,11,3,0,0,0,0,2,424,112,0,0,"",0,0,0,0,-259,'',[ minilines(424,112,0,0,0,0,0,[ mini_line(40,11,3,0,0,0,[ str_block(0,40,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,40,11,3,0,0,0,0,0,0,0, "exec=")]) ]), mini_line(336,11,3,0,0,0,[ str_block(0,336,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,336,11,3,0,-3,0,0,0,0,0, " mktemp(\"/tmp/TgifXXXXXX\",\"file_name\");")]) ]), mini_line(416,11,3,0,0,0,[ str_block(0,416,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,416,11,3,0,-3,0,0,0,0,0, " write_attr_into_file(header,\"$(file_name).tex\");")]) ]), mini_line(392,11,3,0,0,0,[ str_block(0,392,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,392,11,3,0,-3,0,0,0,0,0, " append_attr_into_file(eq,\"$(file_name).tex\");")]) ]), mini_line(424,11,3,0,0,0,[ str_block(0,424,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,424,11,3,0,-3,0,0,0,0,0, " append_attr_into_file(footer,\"$(file_name).tex\");")]) ]), mini_line(144,11,3,0,0,0,[ str_block(0,144,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,144,11,3,0,-3,0,0,0,0,0, " launch(\"cmd\");")]) ]), mini_line(328,11,3,0,0,0,[ str_block(0,328,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,328,11,3,0,-3,0,0,0,0,0, " update_xpm_child(\"$(file_name).jpg\");")]) ]), mini_line(168,11,3,0,0,0,[ str_block(0,168,11,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,168,11,3,0,-4,0,0,0,0,0, " launch(\"cleanup\")")]) ]) ])])), attr("cmd=", "", 0, 1, 0, text('blue',64,-150,5,0,1,776,70,1494,11,3,0,0,0,0,2,776,70,0,0,"",0,0,0,0,-139,'',[ minilines(776,70,0,0,0,0,0,[ mini_line(32,11,3,0,0,0,[ str_block(0,32,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,32,11,3,0,0,0,0,0,0,0, "cmd=")]) ]), mini_line(96,11,3,0,0,0,[ str_block(0,96,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,96,11,3,0,-3,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(408,11,3,0,0,0,[ str_block(0,408,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,408,11,3,0,-3,0,0,0,0,0, " xterm -geom 40x8+200+400 -e latex $(file_name);")]) ]), mini_line(624,11,3,0,0,0,[ str_block(0,624,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,624,11,3,0,-3,0,0,0,0,0, " xterm -geom 40x8+200+400 -e dvips -E -n 1 -o $(file_name).ps $(file_name);")]) ]), mini_line(776,11,3,0,0,0,[ str_block(0,776,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,776,11,3,0,-3,0,0,0,0,0, " xterm -geom 40x8+200+400 -e convert -scale 25% -density 576 $(file_name).ps $(file_name).jpg;")]) ]) ])])), attr("cleanup=", "", 0, 1, 0, text('blue',64,-70,3,0,1,480,42,1392,11,3,0,0,0,0,2,480,42,0,0,"",0,0,0,0,-59,'',[ minilines(480,42,0,0,0,0,0,[ mini_line(64,11,3,0,0,0,[ str_block(0,64,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,64,11,3,0,0,0,0,0,0,0, "cleanup=")]) ]), mini_line(480,11,3,0,0,0,[ str_block(0,480,11,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,480,11,3,0,-1,0,0,0,0,0, " rm -f $(file_name).tex $(file_name).aux $(file_name).dvi")]) ]), mini_line(456,11,3,0,0,0,[ str_block(0,456,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,456,11,3,0,0,0,0,0,0,0, " $(file_name).log $(file_name).ps $(file_name).jpg")]) ]) ])])), attr("file_name=", "", 0, 1, 0, text('blue',64,34,1,0,1,80,14,29,11,3,0,0,0,0,2,80,14,0,0,"",0,0,0,0,45,'',[ minilines(80,14,0,0,0,0,0,[ mini_line(80,11,3,0,0,0,[ str_block(0,80,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,80,11,3,0,0,0,0,0,0,0, "file_name=")]) ]) ])])), attr("eq=", "", 1, 1, 0, text('blue',64,50,5,0,1,120,70,25,11,3,0,0,0,0,2,120,70,0,0,"",0,0,0,0,61,'',[ minilines(120,70,0,0,0,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "eq=")]) ]), mini_line(48,11,3,0,0,0,[ str_block(0,48,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,48,11,3,0,0,0,0,0,0,0, "\\LARGE")]) ]), mini_line(16,11,3,0,0,0,[ str_block(0,16,11,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,16,11,3,0,-1,0,0,0,0,0, "\\[")]) ]), mini_line(120,11,3,0,0,0,[ str_block(0,120,11,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,120,11,3,0,-1,0,0,0,0,0, " E\\,=\\,M\\,C^2")]) ]), mini_line(16,11,3,0,0,0,[ str_block(0,16,11,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,16,11,3,0,-4,0,0,0,0,0, "\\]")]) ]) ])])), attr("", "not_rigid", 0, 1, 0, text('blue',64,154,1,0,1,72,14,535,11,3,0,0,0,0,2,72,14,0,0,"",0,0,0,0,165,'',[ minilines(72,14,0,0,0,0,0,[ mini_line(72,11,3,0,0,0,[ str_block(0,72,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,72,11,3,0,0,0,0,0,0,0, "not_rigid")]) ]) ])])) ]). group([ group([ text('#0000ff',224,106,4,0,1,366,65,657,14,3,0,-1,0,0,2,366,65,0,2,"",0,0,0,0,120,'',[ minilines(366,65,0,2,0,-1,0,[ mini_line(360,14,3,0,2,0,[ str_block(0,360,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,360,14,3,0,2,0,0,0,0,0, "This version of the LaTeX equation symbol by default")]) ]), mini_line(353,14,3,0,2,0,[ str_block(0,44,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,44,14,3,0,2,0,0,0,0,0, "uses \"")]), str_block(0,52,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,52,14,3,0,2,0,0,0,0,0, "convert")]), str_block(0,257,14,3,0,-1,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,257,14,3,0,-1,0,0,0,0,0, "\" to add a preview bitmap to a PS file.")]) ]), mini_line(366,14,3,0,2,0,[ str_block(0,36,14,3,0,2,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,36,14,3,0,2,0,0,0,0,0, "The \"")]), str_block(0,52,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,52,14,3,0,2,0,0,0,0,0, "convert")]), str_block(0,278,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,278,14,3,0,1,0,0,0,0,0, "\" program is part of ImageMagick, which")]) ]), mini_line(199,14,3,0,0,0,[ str_block(0,199,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,199,14,3,0,-1,0,0,0,0,0, "is available on most systems.")]) ]) ])]), text('#0000ff',192,106,1,0,1,19,17,846,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,120,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(2)")]) ]) ])]) ], 1270,0,0,[ ]), group([ text('#0000ff',224,50,3,0,1,362,49,643,14,3,0,-1,0,0,2,362,49,0,1,"",0,0,0,0,64,'',[ minilines(362,49,0,1,0,-1,0,[ mini_line(317,14,3,0,1,0,[ str_block(0,189,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,189,14,3,0,-3,0,0,0,0,0, "Make sure you are running ")]), str_block(0,60,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,60,14,3,0,1,0,0,0,0,0, "tgif-4.2.2")]), str_block(0,68,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,68,14,3,0,-1,0,0,0,0,0, " or newer.")]) ]), mini_line(362,14,3,0,1,0,[ str_block(0,362,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,1,0,0,0,0,0, "You can find out what version of tgif you are running")]) ]), mini_line(300,14,3,0,0,0,[ str_block(0,300,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,300,14,3,0,-1,0,0,0,0,0, "by selecting About() from the Special menu.")]) ]) ])]), text('#0000ff',192,50,1,0,1,19,17,863,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,64,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(1)")]) ]) ])]) ], 1258,0,0,[ ]), group([ text('#0000ff',192,178,1,0,1,19,17,1021,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,192,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(3)")]) ]) ])]), text('#0000ff',224,178,4,0,1,392,65,1022,14,3,0,-1,0,0,2,392,65,0,2,"",0,0,0,0,192,'',[ minilines(392,65,0,2,0,-1,0,[ mini_line(392,14,3,0,2,0,[ str_block(0,107,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,107,14,3,0,-2,0,0,0,0,0, "Make sure that ")]), str_block(0,32,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,32,14,3,0,2,0,0,0,0,0, "latex")]), str_block(0,8,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,8,14,3,0,-3,0,0,0,0,0, ", ")]), str_block(0,38,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,38,14,3,0,1,0,0,0,0,0, "dvips")]), str_block(0,38,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,38,14,3,0,-2,0,0,0,0,0, ", and ")]), str_block(0,52,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,52,14,3,0,2,0,0,0,0,0, "convert")]), str_block(0,81,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,81,14,3,0,-2,0,0,0,0,0, " are in your ")]), str_block(0,32,12,3,0,0,0,0,0,[ str_seg('#ff00ff','Courier-Bold',1,80640,32,12,3,0,0,0,0,0,0,0, "PATH")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]), mini_line(370,14,3,0,1,0,[ str_block(0,228,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,228,14,3,0,-3,0,0,0,0,0, "After you instantiate this symbol, ")]), str_block(0,84,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,84,14,3,0,1,0,0,0,0,0, "double-click")]), str_block(0,58,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,58,14,3,0,1,0,0,0,0,0, " it to run")]) ]), mini_line(386,14,3,0,0,0,[ str_block(0,362,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,-3,0,0,0,0,0, "the latex scripts. Afterwards, you can hide/show the ")]), str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "eq=")]) ]), mini_line(247,14,3,0,1,0,[ str_block(0,148,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,148,14,3,0,-3,0,0,0,0,0, "attribute by pressing ")]), str_block(0,95,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,95,14,3,0,1,0,0,0,0,0, "<Alt><Cntrl>7")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]) ])]) ], 1264,0,0,[ ]) ], 1472,0,0,[ ]). ���������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/config.status������������������������������������������������������������������������0000755�0000764�0000764�00000102725�11602233423�015513� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#! /bin/sh # Generated by configure. # Run this file to recreate the current configuration. # Compiler output produced by configure, useful for debugging # configure, is in config.log if it exists. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=${CONFIG_SHELL-/bin/sh} ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi # PATH needs CR # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset else as_unset=false fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) as_nl=' ' IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. case $0 in *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 { (exit 1); exit 1; } fi # Work around bugs in pre-3.0 UWIN ksh. for as_var in ENV MAIL MAILPATH do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. for as_var in \ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ LC_TELEPHONE LC_TIME do if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then eval $as_var=C; export $as_var else ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var fi done # Required to use basename. if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi # Name of the executable. as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # CDPATH. $as_unset CDPATH as_lineno_1=$LINENO as_lineno_2=$LINENO test "x$as_lineno_1" != "x$as_lineno_2" && test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || { # Create $as_me.lineno as a copy of $as_myself, but with $LINENO # uniformly replaced by the line number. The first 'sed' inserts a # line-number line after each line using $LINENO; the second 'sed' # does the real work. The second script uses 'N' to pair each # line-number line with the line containing $LINENO, and appends # trailing '-' during substitution so that $LINENO is not a special # case at line end. # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the # scripts with optimization help from Paolo Bonzini. Blame Lee # E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 { (exit 1); exit 1; }; } # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in -n*) case `echo 'x\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. *) ECHO_C='\c';; esac;; *) ECHO_N='-n';; esac if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir fi echo >conf$$.file if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p=: else test -d ./-p && rmdir ./-p as_mkdir_p=false fi if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 # Save the log message, to keep $[0] and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by tgif $as_me 4.2.5, which was generated by GNU Autoconf 2.61. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ on `(hostname || uname -n) 2>/dev/null | sed 1q` " # Files that config.status was made for. config_files=" Makefile" config_headers=" config.h" config_commands=" depfiles" ac_cs_usage="\ \`$as_me' instantiates files from templates according to the current configuration. Usage: $0 [OPTIONS] [FILE]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit -q, --quiet do not print progress messages -d, --debug don't remove temporary files --recheck update $as_me by reconfiguring in the same conditions --file=FILE[:TEMPLATE] instantiate the configuration file FILE --header=FILE[:TEMPLATE] instantiate the configuration header FILE Configuration files: $config_files Configuration headers: $config_headers Configuration commands: $config_commands Report bugs to <bug-autoconf@gnu.org>." ac_cs_version="\ tgif config.status 4.2.5 configured by ./configure, generated by GNU Autoconf 2.61, with options \"\" Copyright (C) 2006 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='/merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5' srcdir='.' INSTALL='/usr/bin/install -c' MKDIR_P='/bin/mkdir -p' # If no file are specified by the user, then we need to provide default # value. By we need to know if files were specified by the user. ac_need_defaults=: while test $# != 0 do case $1 in --*=*) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` ac_shift=: ;; *) ac_option=$1 ac_optarg=$2 ac_shift=shift ;; esac case $ac_option in # Handling of the options. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) echo "$ac_cs_version"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift CONFIG_FILES="$CONFIG_FILES $ac_optarg" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg" ac_need_defaults=false;; --he | --h) # Conflict between --help and --header { echo "$as_me: error: ambiguous option: $1 Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; };; --help | --hel | -h ) echo "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) { echo "$as_me: error: unrecognized option: $1 Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; } ;; *) ac_config_targets="$ac_config_targets $1" ac_need_defaults=false ;; esac shift done ac_configure_extra_args= if $ac_cs_silent; then exec 6>/dev/null ac_configure_extra_args="$ac_configure_extra_args --silent" fi if $ac_cs_recheck; then echo "running CONFIG_SHELL=/bin/sh /bin/sh ./configure " $ac_configure_extra_args " --no-create --no-recursion" >&6 CONFIG_SHELL=/bin/sh export CONFIG_SHELL exec /bin/sh "./configure" $ac_configure_extra_args --no-create --no-recursion fi exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX echo "$ac_log" } >&5 # # INIT-COMMANDS # AMDEP_TRUE="" ac_aux_dir="." # Handling of arguments. for ac_config_target in $ac_config_targets do case $ac_config_target in "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 echo "$as_me: error: invalid argument: $ac_config_target" >&2;} { (exit 1); exit 1; }; };; esac done # If the user did not use the arguments to specify the items to instantiate, # then the envvar interface is used. Set only those that are not. # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason against having it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: # after its creation but before its name has been assigned to `$tmp'. $debug || { tmp= trap 'exit_status=$? { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status ' 0 trap '{ (exit 1); exit 1; }' 1 2 13 15 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || { echo "$me: cannot create a temporary directory in ." >&2 { (exit 1); exit 1; } } # # Set up the sed scripts for CONFIG_FILES section. # # No need to generate the scripts if there are no CONFIG_FILES. # This happens for instance when ./config.status config.h if test -n "$CONFIG_FILES"; then cat >"$tmp/subs-1.sed" <<\CEOF /@[a-zA-Z_][a-zA-Z_0-9]*@/!b end s,@SHELL@,|#_!!_#|/bin/sh,g s,@PATH_SEPARATOR@,|#_!!_#|:,g s,@PACKAGE_NAME@,|#_!!_#|tgif,g s,@PACKAGE_TARNAME@,|#_!!_#|tgif,g s,@PACKAGE_VERSION@,|#_!!_#|4.2.5,g s,@PACKAGE_STRING@,|#_!!_#|tgif 4.2.5,g s,@PACKAGE_BUGREPORT@,|#_!!_#|bill.cheng@|#_!!_#|acm.org,g s,@exec_prefix@,|#_!!_#|${prefix},g s,@prefix@,|#_!!_#|/usr/local,g s,@program_transform_name@,|#_!!_#|s\,x\,x\,,g s,@bindir@,|#_!!_#|${exec_prefix}/bin,g s,@sbindir@,|#_!!_#|${exec_prefix}/sbin,g s,@libexecdir@,|#_!!_#|${exec_prefix}/libexec,g s,@datarootdir@,|#_!!_#|${prefix}/share,g s,@datadir@,|#_!!_#|${datarootdir},g s,@sysconfdir@,|#_!!_#|${prefix}/etc,g s,@sharedstatedir@,|#_!!_#|${prefix}/com,g s,@localstatedir@,|#_!!_#|${prefix}/var,g s,@includedir@,|#_!!_#|${prefix}/include,g s,@oldincludedir@,|#_!!_#|/usr/include,g s,@docdir@,|#_!!_#|${datarootdir}/doc/${PACKAGE_TARNAME},g s,@infodir@,|#_!!_#|${datarootdir}/info,g s,@htmldir@,|#_!!_#|${docdir},g s,@dvidir@,|#_!!_#|${docdir},g s,@pdfdir@,|#_!!_#|${docdir},g s,@psdir@,|#_!!_#|${docdir},g s,@libdir@,|#_!!_#|${exec_prefix}/lib,g s,@localedir@,|#_!!_#|${datarootdir}/locale,g s,@mandir@,|#_!!_#|${datarootdir}/man,g s,@DEFS@,|#_!!_#|-DHAVE_CONFIG_H,g s,@ECHO_C@,|#_!!_#|,g s,@ECHO_N@,|#_!!_#|-n,g s,@ECHO_T@,|#_!!_#|,g s,@LIBS@,|#_!!_#|-lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 ,g s,@build_alias@,|#_!!_#|,g s,@host_alias@,|#_!!_#|,g s,@target_alias@,|#_!!_#|,g s,@INSTALL_PROGRAM@,|#_!!_#|${INSTALL},g s,@INSTALL_SCRIPT@,|#_!!_#|${INSTALL},g s,@INSTALL_DATA@,|#_!!_#|${INSTALL} -m 644,g s,@am__isrc@,|#_!!_#|,g s,@CYGPATH_W@,|#_!!_#|echo,g s,@PACKAGE@,|#_!!_#|tgif,g s,@VERSION@,|#_!!_#|4.2.5,g s,@ACLOCAL@,|#_!!_#|${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run aclocal-1.10,g s,@AUTOCONF@,|#_!!_#|${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run autoconf,g s,@AUTOMAKE@,|#_!!_#|${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run automake-1.10,g s,@AUTOHEADER@,|#_!!_#|${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run autoheader,g s,@MAKEINFO@,|#_!!_#|${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run makeinfo,g s,@install_sh@,|#_!!_#|$(SHELL) /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/install-sh,g s,@STRIP@,|#_!!_#|,g s,@INSTALL_STRIP_PROGRAM@,|#_!!_#|$(install_sh) -c -s,g s,@mkdir_p@,|#_!!_#|/bin/mkdir -p,g s,@AWK@,|#_!!_#|gawk,g s,@SET_MAKE@,|#_!!_#|,g s,@am__leading_dot@,|#_!!_#|.,g s,@AMTAR@,|#_!!_#|${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run tar,g s,@am__tar@,|#_!!_#|${AMTAR} chof - "$$tardir",g s,@am__untar@,|#_!!_#|${AMTAR} xf -,g s,@CC@,|#_!!_#|gcc,g s,@CFLAGS@,|#_!!_#|-g -O2,g s,@LDFLAGS@,|#_!!_#|,g s,@CPPFLAGS@,|#_!!_#|,g s,@ac_ct_CC@,|#_!!_#|gcc,g s,@EXEEXT@,|#_!!_#|,g s,@OBJEXT@,|#_!!_#|o,g s,@DEPDIR@,|#_!!_#|.deps,g s,@am__include@,|#_!!_#|include,g s,@am__quote@,|#_!!_#|,g s,@AMDEP_TRUE@,|#_!!_#|,g s,@AMDEP_FALSE@,|#_!!_#|#,g s,@AMDEPBACKSLASH@,|#_!!_#|\\,g s,@CCDEPMODE@,|#_!!_#|depmode=gcc3,g s,@am__fastdepCC_TRUE@,|#_!!_#|,g s,@am__fastdepCC_FALSE@,|#_!!_#|#,g s,@XMKMF@,|#_!!_#|,g s,@CPP@,|#_!!_#|gcc -E,g s,@GREP@,|#_!!_#|/bin/grep,g s,@EGREP@,|#_!!_#|/bin/grep -E,g s,@LIBOBJS@,|#_!!_#|,g s,@POW_LIB@,|#_!!_#|,g s,@LTLIBOBJS@,|#_!!_#|,g :end s/|#_!!_#|//g CEOF fi # test -n "$CONFIG_FILES" for ac_tag in :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS do case $ac_tag in :[FHLC]) ac_mode=$ac_tag; continue;; esac case $ac_mode$ac_tag in :[FHL]*:*);; :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5 echo "$as_me: error: Invalid tag $ac_tag." >&2;} { (exit 1); exit 1; }; };; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac ac_save_IFS=$IFS IFS=: set x $ac_tag IFS=$ac_save_IFS shift ac_file=$1 shift case $ac_mode in :L) ac_source=$1;; :[FH]) ac_file_inputs= for ac_f do case $ac_f in -) ac_f="$tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, # because $ac_f cannot contain `:'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5 echo "$as_me: error: cannot find input file: $ac_f" >&2;} { (exit 1); exit 1; }; };; esac ac_file_inputs="$ac_file_inputs $ac_f" done # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input="Generated from "`IFS=: echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure." if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { echo "$as_me:$LINENO: creating $ac_file" >&5 echo "$as_me: creating $ac_file" >&6;} fi case $ac_tag in *:-:* | *:-) cat >"$tmp/stdin";; esac ;; esac ac_dir=`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` { as_dir="$ac_dir" case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 echo "$as_me: error: cannot create directory $as_dir" >&2;} { (exit 1); exit 1; }; }; } ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix case $ac_mode in :F) # # CONFIG_FILE # case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac ac_MKDIR_P=$MKDIR_P case $MKDIR_P in [\\/$]* | ?:[\\/]* ) ;; */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; esac # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= case `sed -n '/datarootdir/ { p q } /@datadir@/p /@docdir@/p /@infodir@/p /@localedir@/p /@mandir@/p ' $ac_file_inputs` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} ac_datarootdir_hack=' s&@datadir@&${datarootdir}&g s&@docdir@&${datarootdir}/doc/${PACKAGE_TARNAME}&g s&@infodir@&${datarootdir}/info&g s&@localedir@&${datarootdir}/locale&g s&@mandir@&${datarootdir}/man&g s&\${datarootdir}&${prefix}/share&g' ;; esac sed "/^[ ]*VPATH[ ]*=/{ s/:*\$(srcdir):*/:/ s/:*\${srcdir}:*/:/ s/:*@srcdir@:*/:/ s/^\([^=]*=[ ]*\):*/\1/ s/:*$// s/^[^=]*=[ ]*$// } :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s&@configure_input@&$configure_input&;t t s&@top_builddir@&$ac_top_builddir_sub&;t t s&@srcdir@&$ac_srcdir&;t t s&@abs_srcdir@&$ac_abs_srcdir&;t t s&@top_srcdir@&$ac_top_srcdir&;t t s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t s&@builddir@&$ac_builddir&;t t s&@abs_builddir@&$ac_abs_builddir&;t t s&@abs_top_builddir@&$ac_abs_top_builddir&;t t s&@INSTALL@&$ac_INSTALL&;t t s&@MKDIR_P@&$ac_MKDIR_P&;t t $ac_datarootdir_hack " $ac_file_inputs | sed -f "$tmp/subs-1.sed" >$tmp/out test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&5 echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&2;} rm -f "$tmp/stdin" case $ac_file in -) cat "$tmp/out"; rm -f "$tmp/out";; *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;; esac ;; :H) # # CONFIG_HEADER # # First, check the format of the line: cat >"$tmp/defines.sed" <<\CEOF /^[ ]*#[ ]*undef[ ][ ]*[_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ][_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789]*[ ]*$/b def /^[ ]*#[ ]*define[ ][ ]*[_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ][_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789]*[( ]/b def b :def s/$/ / s,^\([ #]*\)[^ ]*\([ ]*PACKAGE_NAME\)[ (].*,\1define\2 "tgif" , s,^\([ #]*\)[^ ]*\([ ]*PACKAGE_TARNAME\)[ (].*,\1define\2 "tgif" , s,^\([ #]*\)[^ ]*\([ ]*PACKAGE_VERSION\)[ (].*,\1define\2 "4.2.5" , s,^\([ #]*\)[^ ]*\([ ]*PACKAGE_STRING\)[ (].*,\1define\2 "tgif 4.2.5" , s,^\([ #]*\)[^ ]*\([ ]*PACKAGE_BUGREPORT\)[ (].*,\1define\2 "bill.cheng@acm.org" , s,^\([ #]*\)[^ ]*\([ ]*PACKAGE\)[ (].*,\1define\2 "tgif" , s,^\([ #]*\)[^ ]*\([ ]*VERSION\)[ (].*,\1define\2 "4.2.5" , s,^\([ #]*\)[^ ]*\([ ]*HAVE_LIBX11\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_LIBXT\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_LIBNSL\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_LIBDL\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_LIBIDN\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_LIBM\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_LIBZ\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_LIBPTHREAD\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_DIRENT_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*STDC_HEADERS\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SYS_WAIT_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SYS_TYPES_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SYS_STAT_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STDLIB_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STRING_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_MEMORY_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STRINGS_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_INTTYPES_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STDINT_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_UNISTD_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_ARPA_INET_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_FCNTL_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_LIBINTL_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_NETDB_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_NETINET_IN_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STDINT_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STDLIB_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STRING_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SYS_FILE_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SYS_IOCTL_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SYS_SOCKET_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SYS_TIME_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SYS_TIMEB_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_UNISTD_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*TIME_WITH_SYS_TIME\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_FORK\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_VFORK\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_WORKING_VFORK\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_WORKING_FORK\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*LSTAT_FOLLOWS_SLASHED_SYMLINK\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STDLIB_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_MALLOC\)[ (].*,\1define\2 1 , CEOF sed -f "$tmp/defines.sed" $ac_file_inputs >"$tmp/out1" # First, check the format of the line: cat >"$tmp/defines.sed" <<\CEOF /^[ ]*#[ ]*undef[ ][ ]*[_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ][_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789]*[ ]*$/b def /^[ ]*#[ ]*define[ ][ ]*[_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ][_abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789]*[( ]/b def b :def s,^\([ #]*\)[^ ]*\([ ]*HAVE_STDLIB_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_REALLOC\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SYS_SELECT_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SYS_SOCKET_H\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*SELECT_TYPE_ARG1\)[ (].*,\1define\2 int , s,^\([ #]*\)[^ ]*\([ ]*SELECT_TYPE_ARG234\)[ (].*,\1define\2 (fd_set *) , s,^\([ #]*\)[^ ]*\([ ]*SELECT_TYPE_ARG5\)[ (].*,\1define\2 (struct timeval *) , s,^\([ #]*\)[^ ]*\([ ]*RETSIGTYPE\)[ (].*,\1define\2 void , s,^\([ #]*\)[^ ]*\([ ]*HAVE_FTIME\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_GETCWD\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_GETHOSTBYNAME\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_GETHOSTNAME\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_GETTIMEOFDAY\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_MEMMOVE\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_MEMSET\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_MKDIR\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_POW\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_PUTENV\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SELECT\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SETLOCALE\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SOCKET\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_SQRT\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STRCHR\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STRPBRK\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STRRCHR\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STRSTR\)[ (].*,\1define\2 1 , s,^\([ #]*\)[^ ]*\([ ]*HAVE_STRTOL\)[ (].*,\1define\2 1 , s/ $// s,^[ #]*u.*,/* & */, CEOF sed -f "$tmp/defines.sed" "$tmp/out1" >"$tmp/out2" ac_result="$tmp/out2" if test x"$ac_file" != x-; then echo "/* $configure_input */" >"$tmp/config.h" cat "$ac_result" >>"$tmp/config.h" if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then { echo "$as_me:$LINENO: $ac_file is unchanged" >&5 echo "$as_me: $ac_file is unchanged" >&6;} else rm -f $ac_file mv "$tmp/config.h" $ac_file fi else echo "/* $configure_input */" cat "$ac_result" fi rm -f "$tmp/out12" # Compute $ac_file's index in $config_headers. _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $ac_file | $ac_file:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $ac_file" >`$as_dirname -- $ac_file || $as_expr X$ac_file : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X$ac_file : 'X\(//\)[^/]' \| \ X$ac_file : 'X\(//\)$' \| \ X$ac_file : 'X\(/\)' \| . 2>/dev/null || echo X$ac_file | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'`/stamp-h$_am_stamp_count ;; :C) { echo "$as_me:$LINENO: executing $ac_file commands" >&5 echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "depfiles":C) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # Grep'ing the whole file is not good either: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. if sed 10q "$mf" | grep '^#.*generated by automake' > /dev/null 2>&1; then dirpart=`$as_dirname -- "$mf" || $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$mf" : 'X\(//\)[^/]' \| \ X"$mf" : 'X\(//\)$' \| \ X"$mf" : 'X\(/\)' \| . 2>/dev/null || echo X"$mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`$as_dirname -- "$file" || $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$file" : 'X\(//\)[^/]' \| \ X"$file" : 'X\(//\)$' \| \ X"$file" : 'X\(/\)' \| . 2>/dev/null || echo X"$file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` { as_dir=$dirpart/$fdir case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 echo "$as_me: error: cannot create directory $as_dir" >&2;} { (exit 1); exit 1; }; }; } # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done ;; esac done # for ac_tag { (exit 0); exit 0; } �������������������������������������������tgif-QPL-4.2.5/pngtrans.e���������������������������������������������������������������������������0000644�0000764�0000764�00000003415�11602233312�014771� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/pngtrans.e,v 1.4 2011/05/16 16:21:59 william Exp $ */ #ifndef _PNGTRANS_E_ #define _PNGTRANS_E_ #ifdef _INCLUDE_FROM_PNGTRANS_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_PNGTRANS_C_*/ extern int ParseTransColor ARGS_DECL((char*, unsigned char *puch_trans_color_pixel_r, unsigned char *puch_trans_color_pixel_g, unsigned char *puch_trans_color_pixel_b)); extern void ResetPngHeaderInfo ARGS_DECL((PngHeaderInfo*)); extern void SetPngHeaderInfoForTransColor ARGS_DECL((PngHeaderInfo*, unsigned char trans_color_pixel_r, unsigned char trans_color_pixel_g, unsigned char trans_color_pixel_b)); extern int PngFileGetTransColorInit ARGS_DECL((PngHeaderInfo*, char *fname)); extern int PngFileGetTransColor ARGS_DECL((PngHeaderInfo*)); #ifdef _INCLUDE_FROM_PNGTRANS_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_PNGTRANS_C_*/ #endif /*_PNGTRANS_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Imakefile����������������������������������������������������������������������������0000644�0000764�0000764�00000072250�11602233314�014605� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#ifndef XCOMM #define XCOMM # #endif #ifndef NullParameter #define NullParameter #endif XCOMM ------------------------------------------------- XCOMM XCOMM Please make changed in Tgif.tmpl and Target.tmpl. XCOMM XCOMM There should be no need to modify this file. XCOMM XCOMM ------------------------------------------------- XCOMM #include <Tgif.tmpl> #include <Target.tmpl> XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Imakefile,v 1.205 2011/06/26 02:02:01 william Exp $ XCOMM TGIFVERSION = 4.2.5 EXTDEFINES = -DEPSF_FILE_EXT=\"eps\" -DPS_FILE_EXT=\"ps\" \@@\ -DXBM_FILE_EXT=\"xbm\" -DXPM_FILE_EXT=\"xpm\" \@@\ -DOBJ_FILE_EXT=\"obj\" -DSYM_FILE_EXT=\"sym\" \@@\ -DTEXT_FILE_EXT=\"txt\" -DPIN_FILE_EXT=\"pin\" \@@\ -DNETLIST_FILE_EXT=\"net\" -DCOMP_FILE_EXT=\"cmp\" DEFINES = $(DIRDEFINES) \@@\ $(EXTDEFINES) \@@\ $(XIMPDEFINES) \@@\ $(MISCDEFINES) \@@\ -DTGIF_DISTR_VER=\"$(TGIFVERSION)\" \@@\ $(MOREDEFINES) -DQPL_LICENSE XCOMM Things to try to add to the DEFINES line above: XCOMM XCOMM RS6000: -D_BSD XCOMM Solaris: XCOMM Irix: XCOMM SunOS: XCOMM HP-UX: -D_NO_LOCALE_SUPPORT XCOMM VMS: -D_NO_GETTIMEOFDAY XCOMM Linux: XCOMM FreeBSD: XCOMM SCO: -DPRINT_CMD=\""lp -o raw -o nobanner"\" XCOMM -D_NO_XUTF8FUNCTIONS XCOMM Include the above line if your X11 library does have have the XCOMM Xutf8TextListToTextProperty() function implemented (such as on XCOMM some Solaris system). XCOMM -D_NO_RMCAST_SO XCOMM Include the above line if you do not want to link to the rmcast XCOMM library dynamically. If this flag is used, you must link tgif with XCOMM the rmcast library statically. XCOMM -D_NO_IDNLIB XCOMM Include the above line if you do not have libidn installed in your XCOMM system. libidn is used in conjunction with the XIM input method XCOMM to convert a UTF-8 character into something X understands. XCOMM -D_NO_ZLIB XCOMM Include the above line if you do not have zlib installed in your XCOMM system. Zlib is only used in tgif when _TGIF_WB2 (see below) is XCOMM used. XCOMM -D_NO_ENTER_TEXT_EVERYWHERE XCOMM Include the above line if you do not want to be able to enter XCOMM text from the keyboard in tgif unless the drawing area of tgif XCOMM has the keyboard focus. XCOMM -D_DARWIN_MOD1_AS_META XCOMM Include the above line if you are compiling for Mac OS X and XCOMM you want to use the Mod1 key as the <Meta> key. By default, XCOMM the Mod2 key is treated as the <Meta> key (at the time this XCOMM option was added). XCOMM -D_XPM3TOPPM XCOMM Include the above line if the xpmtoppm you have only knows how to XCOMM handle XPM format version 3. (This is the case with xpm-9.14.) XCOMM This has the same effect as setting Tgif.XPmOutputVersion to 3 and XCOMM Tgif.UseXPmVersion1ForImageMap to false. XCOMM -D_NO_LANDSCAPE_PDF_SETPAGEDEVICE XCOMM Include the above line if you want tgif to *not* generate XCOMM "setpagedevice" PostScript command to rotate the generated PostScript XCOMM file. (This is meant to be used when ps2pdf can handle landscape XCOMM PostScript files correctly.) XCOMM -D_PRTGIF_USE_ISO_LATIN_1_ALWAYS XCOMM Include the above line if you want to always use ISO 8859-1 character XCOMM set for single-byte characters when running tgif with the -print XCOMM commandline option. Please only use this if you are sure that you XCOMM will *never* use other encodings. You can selectively turn off XCOMM reencoding by using either the Tgif.DontReencode X default or the XCOMM -dontreencode commandline option. XCOMM -D_TMP_DIR_IN_HOME_DIR XCOMM Include the above line if you want the temporary directory to be XCOMM a user's $HOME/.Tgif directory by default. XCOMM -D_DONT_USE_MKTEMP XCOMM Include the above line if you do not want to use mktemp() and your XCOMM system supports tempnam(). The use of mktemp() is not recommanded XCOMM due to some security considerations. XCOMM -D_PS_SEVENBIT_DOUBLEBYTE_TEXT XCOMM Include the above line if bit 7 in both bytes of a double-byte XCOMM character should be masked out when printing/exporting double-byte XCOMM text to a PostScript file. XCOMM -D_USE_PS_ADOBE_STRING=\"true\" XCOMM Include the above line in the DEFINES if you want to configure tgif XCOMM to use a default Tgif.UsePsAdobeString value. XCOMM -D_MINIMAL_EPS=1 XCOMM Include the above line in the DEFINES if you want to configure tgif XCOMM to use a default Tgif.MinimalEPS value. XCOMM -DENABLE_NLS XCOMM Include the above line if you want to enable NLS (Native Language XCOMM Support). XCOMM -D_DONT_USE_PORTABLE_LOCALE (obsoleted) XCOMM Include the above line if you don't want to use the portable locale. XCOMM (Portable locale is "C" for all locale categories.) XCOMM -D_NO_RECURSIVE_EXTERN XCOMM Include the above line if your C compiler cannot handle XCOMM "#define extern extern". The /bin/cc compiler on HP-UX reports a XCOMM Recursion in macro "extern" when the above define is used. XCOMM -D_DL_EXPORT_UNDERSCORE XCOMM Include the above line if you use export filters and there is an entry XCOMM point to an export filter named "_TgifExportFilterMain" (and there's XCOMM no entry point named "TgifExportFilterMain"). One can see all the XCOMM entry points to an export filter by running 'nm' against it. XCOMM -D_NO_TGTWB5 XCOMM Include the above line if you do not want to include the code XCOMM that handles tgtwb5. Please also remove "tgtwb5.o" and "tgtwb5xl.o" XCOMM from OBJ1 in Imakefile. XCOMM -D_NO_XCIN XCOMM Include the above line if you do not want to include the code XCOMM that handles xcin. Please also remove "cli_xcin.o" from XCOMM OBJ1 in Imakefile. XCOMM -D_NO_CHINPUT XCOMM Include the above line if you do not want to include the code XCOMM that handles chinput. Please also remove "chinput.o" from XCOMM OBJ1 in Imakefile. XCOMM -D_NO_KINPUT XCOMM Include the above line if you do not want to include the code XCOMM that handles kinput. Please also remove "convkinput.o" from XCOMM OBJ1 in Imakefile. XCOMM -D_NO_XIM XCOMM Include the above line if you do not want to include the code XCOMM that handles X Input Method. Please also remove "convxim.o" from XCOMM OBJ1 in Imakefile. XCOMM -D_NO_NKF XCOMM Include the above line if you do not want to include the code XCOMM that handles Network Kanji Filter (NKF). Please also remove XCOMM "nkf.o" from OBJ1 in Imakefile. XCOMM -D_NO_DL_SUPPORT XCOMM Include the above line if you don't have <dlfcn.h>. If you define XCOMM _NO_DL_SUPPORT, please use the SYS_LIBRARIES that does not contain XCOMM -ldl above. XCOMM -D_NO_LOCALE_SUPPORT XCOMM Include the above line if you don't have <X11/Xlocale.h>. If this XCOMM is the case and you don't have <locale.h>, you must also use XCOMM -D_NO_XIM because "convxim.c" assumes that you have <locale.h>. XCOMM -D_METRIC_PIX_PER_INCH XCOMM Include the above line if you want to use 127 pixels per inch XCOMM when printing in the metric system. If this line is not XCOMM included, 128 pixels per inch is used. XCOMM -D_NO_GETTIMEOFDAY XCOMM Include the above line if you do not have the gettimeofday() XCOMM function but have the ftime() function. XCOMM -D_TANGRAM_II (obsoleted) XCOMM Include the above line if you want to include the Tangram-II features XCOMM by Carlos Fisch de Brito, Luiz Rogerio Goncalves de Carvalho, and XCOMM Denise Jorge de Oliveira <fisch,luiz,dezinha@land.ufrj.br> of the XCOMM Tangram-II team of the Universidade Federal do Rio de Janeiro. These XCOMM features are under development and highly experimental. XCOMM (Tangram-II features are enabled in tgif by default now. To activate XCOMM them, run tgif with "-tgrm2" commandline option.) XCOMM -D_TGIF_WB (obsoleted) XCOMM Include the above line if you want to include the whiteboard feature XCOMM by Renato Santana <renato@nce.ufrj.br>. XCOMM -D_TGIF_WB2 XCOMM Include the above line if you want to include the whiteboard feature XCOMM by Magnos Martinello <magnos@land.ufrj.br> and Raphael S. de Moraes XCOMM <raphael@land.ufrj.br>. The whiteboard needs IP multicast support, XCOMM and therefore, can only run on IP multicast enabled kernels. This XCOMM has only been tested on Solaris 2.6 or above or Linux 6.x or above. XCOMM Once tgif is copmiled with this flag, you need to run tgif with the XCOMM "-tgwb2" commandline option to activate it. XCOMM -D_WB2DATA_NO_GZIP XCOMM Starting with tgif-4.2 tgif always gzip whiteboard data before XCOMM sending it down the multicast channel. Include the above line if you XCOMM do *not* want the data to be gzipped. This flag can only be used XCOMM if _TGIF_WB2 is active. XCOMM -D_HAS_STREAMS_SUPPORT XCOMM Include the above line in addition to -D_TGIF_WB2 if you have the XCOMM /usr/include/stropts.h file (such as Solaris 2.6 or above or Linux XCOMM 6.x or above. XCOMM -DBSD_COMP XCOMM Include the above line if you are compiling on a Solaris (or XCOMM possibly an SGI) machine which requires it in <sys/ioctl.h>. XCOMM (If you see the error that FIONBIO is not defined when compiling XCOMM tcp.c, then you probably need this.) XCOMM -D_BACKGROUND_DONT_FORK XCOMM Try the above line if there are defunct tgif child processes. XCOMM -D_NO_LSTAT XCOMM Include the above line if lstat() is not available. In this case, XCOMM using BrowseXBitmap and BrowseXPixmap under the File Menu may cause XCOMM infinite loop if the directory structure is infinitely recursive. XCOMM -D_USE_XDRAWPOINT_TO_PUT_A_POINT XCOMM Include the above line if the grid points are not visible. This can XCOMM be used to bypass some X server bugs (such as certain Linux X server XCOMM using VGA16 screen) where the XDrawLine() Xlib call does not work XCOMM properly. XCOMM -D_NO_EXTERN (obsoleted) XCOMM Include the above line in the DEFINES if you don't want to include XCOMM the extern definition for functions defined in a module. For example, XCOMM if this option is set, then file "foo.c" will not include "foo.e", XCOMM and certain other extern definition in "foo.c" will be omitted. XCOMM -D_NO_PROTO XCOMM Include the above line in the DEFINES if checking for function XCOMM prototypes is not desired. Checking for function prototypes XCOMM are automatically enabled if you are using an ANSI or C++ compilor. XCOMM However, not all ANSI/C++ compilors are created equal. XCOMM -D_BSD XCOMM Include the above line in the DEFINES if the select() function can XCOMM does not be found for AIX systems (such as RS6000). Also, on AIX XCOMM systems, if you see garbage file names when you try to open files, XCOMM try this flag to make direct and dirent equivalent (in <sys/dir.h>). XCOMM -D_NO_RAND48 XCOMM Include the above line in the DEFINES if you do not have the XCOMM srand48() or drand48() functions in your system's library. XCOMM -DNO_STRSTR XCOMM Include the above line in the DEFINES if you do not have the strstr() XCOMM function in your system's string library. XCOMM -DINVERT_CTM_BUG XCOMM Include the above line in the DEFINES if you are using PostScript XCOMM utilities which fails when trying to invert non-invertible CTM XCOMM (e.g., muluti.ps from ftp.ucc.su.oz.au:/pub/ps_printing/multi). XCOMM -DHP_LINE_BUG XCOMM Include the above line in the DEFINES if two-vertices horizontal and XCOMM verticle line segments don't draw properly on a buggy HP server. XCOMM -DDONTFREECOLORS XCOMM Include the above line in the DEFINES if you don't want the black and XCOMM the white colors to be freed when tgif initializes itself. You should XCOMM not need to do this unless you need to get around some server bugs. XCOMM -DUSE_XT_INITIALIZE XCOMM This will cause the XToolkit to be initialized so that the X defaults XCOMM are obtained from the Xt directories. Please remember to use XCOMM LOCAL_LIBRARIES with $(XTOOLLIB) $(XMULIB) in your Tgif.tmpl file. XCOMM -DUSE_XAPPLRESDIR XCOMM Include the above line in the DEFINES if $XAPPLRESDIR/Tgif is used to XCOMM specify the resource file. If your system does not have putenv() XCOMM (such as IBM-RT), then this won't work. This directive has no effect XCOMM if -DUSE_XT_INITIALIZE is used. XCOMM -DXAPPLOADDIR_DEF XCOMM If you define USE_XAPPLRESDIR, define this to a default directory XCOMM to use in case $XAPPLRESDIR isn't set. XCOMM -DNO_THIN_LINE XCOMM Include the above line in the DEFINES if a line width of 0 causes XCOMM your server to crash. This is to get around a bug in some X servers. XCOMM -DTHIN_OVAL_AND_ARC XCOMM Include the above line in the DEFINES if you want 0 width arcs to XCOMM be used when the width of an arc is less than or equal to 1. XCOMM (Sun3 server has a bug that makes drawing ovals and arcs with XCOMM width other than 0 VERY slow). XCOMM -DKEEP_WHEN_PRINT XCOMM Include the above line in the DEFINES if you don't want the temp XCOMM file to be deleted after sending the print job to the printer. XCOMM (Some VMS systems might require this flag to be used.) XCOMM -DPRINT_CMD=\"lpr\" XCOMM Include the above line in the DEFINES if you want to configure tgif XCOMM to use a default print command. XCOMM -DNOTR4MODE XCOMM Include the above line in the DEFINES if you are running X11R3. XCOMM This will cause tgif NOT to use some X11R4 window manager related XCOMM functions that's not present in R3. XCOMM -DMAPBEFORESELECT XCOMM Include the above line in the DEFINES to call XMapWindow() before XCOMM calling XSelectInput(). This might be needed to get around some XCOMM server bugs. XCOMM -DDONT_FREE_COLORMAP XCOMM Include the above line in the DEFINES if you don't want the colormap XCOMM to be freed when tgif exits. XCOMM -DA4PAPER XCOMM Include the above line in the DEFINES if you want to print on A4 paper XCOMM (8.25in by 11.7in or about 21cm by 29.7cm). OBJ1 = align.o animate.o arc.o attr.o auxtext.o \ box.o button.o \ chat.o chinput.o choice.o choose.o cli_xcin.o \ convkinput.o convxim.o cmd.o color.o cutpaste.o \ cursor.o \ dialog.o drawing.o dup.o \ edit.o eps.o exec.o expr.o \ file.o font.o ftp.o \ grid.o group.o \ hash.o help.o http.o \ imgproc.o import.o ini.o inmethod.o \ list.o \ mainloop.o mainmenu.o mark.o markup.o menu.o \ menuinfo.o miniline.o move.o msg.o \ names.o navigate.o nkf.o \ obj.o oval.o \ page.o pattern.o pin.o pngtrans.o poly.o polygon.o ps.o \ raster.o rcbox.o rect.o remote.o rm_intrf.o ruler.o \ scroll.o select.o setup.o shape.o shortcut.o \ special.o spline.o stk.o stream.o stretch.o \ strtbl.o \ tangram2.o tdgtbase.o tdgtbmpl.o tdgtbrow.o tdgtbtn.o tdgtdraw.o \ tdgtlist.o tdgtmsg.o tdgtsedt.o tgif_dbg.o tgcwheel.o \ tgcwdl.o tginssym.o tgisdl.o tgtwb5.o tgtwb5dl.o tgtwb5xl.o \ tidget.o tcp.o text.o \ util.o \ version.o vms_comp.o \ wb.o wb1.o wb2.o wb3.o wb_buff.o wb_mcast.o \ wb_seg.o \ xbitmap.o xpixmap.o xprtfltr.o \ z_intrf.o OBJS1 = tgif.o $(OBJ1) OBJS2 = prtgif.o OBJS3 = testdrive.o $(OBJ1) FRONTENDOBJS = frontend.o $(OBJ1) CURRENTDIR =./ SRCS1 = $(CURRENTDIR)*.c SRCS2 = SRCS3 = ComplexProgramTarget_1($(TARGET_1),$(LOCAL_LIBRARIES),NullParameter) /* * ComplexProgramTarget_2(prtgif,NullParameter,NullParameter) * ComplexProgramTarget_3(testdrive,$(LOCAL_LIBRARIES),NullParameter) */ XCOMM rmcast/src/librmcast.a: XCOMM pushd rmcast; make $(CCLL)$(EEAANN); ./configure; make; popd /* * NormalRelocatableTarget(frontend11,$(FRONTENDOBJS)) */ ICONSDIR =icons/ MakeDirectories(install,$(TGIFDIR)) MakeDirectories(install,$(TGIFDIR)/hicolor) MakeDirectories(install,$(TGIFDIR)/hicolor/22x22) MakeDirectories(install,$(TGIFDIR)/hicolor/22x22/apps) MakeDirectories(install,$(TGIFDIR)/hicolor/32x32) MakeDirectories(install,$(TGIFDIR)/hicolor/32x32/apps) MakeDirectories(install,$(TGIFDIR)/hicolor/48x48) MakeDirectories(install,$(TGIFDIR)/hicolor/48x48/apps) MakeDirectories(install,$(TGIFDIR)/hicolor/64x64) MakeDirectories(install,$(TGIFDIR)/hicolor/64x64/apps) MakeDirectories(install,$(TGIFDIR)/hicolor/128x128) MakeDirectories(install,$(TGIFDIR)/hicolor/128x128/apps) InstallNonExec(tgif.Xdefaults,$(TGIFDIR)) InstallNonExec(tgificon.eps,$(TGIFDIR)) InstallNonExec(tgificon.obj,$(TGIFDIR)) InstallNonExec(tgificon.xbm,$(TGIFDIR)) InstallNonExec(tgificon.xpm,$(TGIFDIR)) InstallNonExec(tgif.gif,$(TGIFDIR)) InstallNonExec(tangram.sym,$(TGIFDIR)) InstallNonExec(eq4.sym,$(TGIFDIR)) InstallNonExec(eq4-2x.sym,$(TGIFDIR)) InstallNonExec(eq4-2x-jpg.sym,$(TGIFDIR)) InstallNonExec(eq4-2x-nowin-jpg.sym,$(TGIFDIR)) InstallNonExec(eq4-ps2epsi.sym,$(TGIFDIR)) InstallNonExec(eq4-epstool.sym,$(TGIFDIR)) InstallNonExec(eq4xpm.sym,$(TGIFDIR)) InstallNonExec(eq4-lyx-ps2epsi.sym,$(TGIFDIR)) InstallNonExec(eq4xpm-land.sym,$(TGIFDIR)) InstallNonExec(eq4png.sym,$(TGIFDIR)) InstallNonExec(eq4jpg.sym,$(TGIFDIR)) InstallNonExec(keys.obj,$(TGIFDIR)) InstallNonExec(Copyright,$(TGIFDIR)) InstallNonExec(LICENSE.QPL,$(TGIFDIR)) InstallNonExec($(ICONSDIR)22x22/apps/tgificon.png,$(TGIFDIR)/hicolor/22x22/apps) InstallNonExec($(ICONSDIR)32x32/apps/tgificon.png,$(TGIFDIR)/hicolor/32x32/apps) InstallNonExec($(ICONSDIR)48x48/apps/tgificon.png,$(TGIFDIR)/hicolor/48x48/apps) InstallNonExec($(ICONSDIR)64x64/apps/tgificon.png,$(TGIFDIR)/hicolor/64x64/apps) InstallNonExec($(ICONSDIR)128x128/apps/tgificon.png,$(TGIFDIR)/hicolor/128x128/apps) .SUFFIXES: .l .man .l.man: rm -f $*.man cp $*.l $*.man .e.o: SPICEDIR =spice/ XBMDIR =xbm/ RMCASTDIR_QPL =rmcast-qpl RMCASTDIR_GPL =rmcast-gpl OBJDEMO = an-sr-flip-flop.obj fonts.obj slide-demo.obj keys.obj \ $(SPICEDIR)*.obj launch-demo.obj launch-demo-1.obj SYMDEMO = flip-flop.sym nand2.sym pin.sym tangram.sym $(SPICEDIR)*.sym \ eq4.sym eq4-2x.sym eq4-ps2epsi.sym eq4-epstool.sym eq4xpm.sym \ eq4-lyx-ps2epsi.sym eq4xpm-land.sym eq4png.sym eq4jpg.sym \ eq4-2x-jpg.sym eq4-2x-nowin-jpg.sym MISCTAR = /**/*.man README README.tgwb Copyright License $(SPICEDIR)*.mod \ tgif.pl example.tex HISTORY testdrive.pl frontend.pl \ Imakefile.tgwb NEWS AUTHORS ChangeLog \ bootstrap.pl scan2ac.awk $(SPICEDIR)README AUTOCONF_FILES = Makefile Makefile.in config.h.in config.h \ mkinstalldirs install-sh missing depcomp \ configure configure.ac aclocal.m4 stamp-h1 \ config.status AUTOCONF_JUNK = autom4te.cache configure.scan config.log config.status AUTOCONF_JUNK = autom4te.cache configure.scan RMCASTJUNK_QPL = $(RMCASTDIR_QPL)/stamp-h1 $(RMCASTDIR_QPL)/Makefile \ $(RMCASTDIR_QPL)/LOG $(RMCASTDIR_QPL)/config.status \ $(RMCASTDIR_QPL)/config.log $(RMCASTDIR_QPL)/config.h \ $(RMCASTDIR_QPL)/mcastproxy/.deps \ $(RMCASTDIR_QPL)/rmchat/.deps $(RMCASTDIR_QPL)/src/.deps \ $(RMCASTDIR_QPL)/mcastproxy/Makefile \ $(RMCASTDIR_QPL)/rmchat/Makefile $(RMCASTDIR_QPL)/src/Makefile CVSSUBDIRS_QPL =\ $(RMCASTDIR_QPL)/config/CVS\ $(RMCASTDIR_QPL)/doc/manual/CVS\ $(RMCASTDIR_QPL)/doc/CVS\ $(RMCASTDIR_QPL)/etc/CVS\ $(RMCASTDIR_QPL)/mcastproxy/CVS\ $(RMCASTDIR_QPL)/rmchat/CVS\ $(RMCASTDIR_QPL)/src/CVS\ $(RMCASTDIR_QPL)/tgif/CVS\ $(RMCASTDIR_QPL)/tools/scripts/special/CVS\ $(RMCASTDIR_QPL)/tools/scripts/CVS\ $(RMCASTDIR_QPL)/tools/tcpdump2rmcast/CVS\ $(RMCASTDIR_QPL)/tools/CVS\ $(RMCASTDIR_QPL)/CVS\ po/ja/CVS\ po/ru/CVS\ po/fr/CVS\ po/CVS CVSSUBDIRS_GPL =\ $(RMCASTDIR_GPL)/config/CVS\ $(RMCASTDIR_GPL)/doc/manual/CVS\ $(RMCASTDIR_GPL)/doc/CVS\ $(RMCASTDIR_GPL)/tgif/CVS\ $(RMCASTDIR_GPL)/tools/tcpdump2rmcast/CVS\ $(RMCASTDIR_GPL)/tools/scripts/special/CVS\ $(RMCASTDIR_GPL)/tools/scripts/CVS\ $(RMCASTDIR_GPL)/tools/mcastproxy/CVS\ $(RMCASTDIR_GPL)/tools/CVS\ $(RMCASTDIR_GPL)/examples/rmchat/rmchat-files/CVS\ $(RMCASTDIR_GPL)/examples/rmchat/CVS\ $(RMCASTDIR_GPL)/examples/CVS\ $(RMCASTDIR_GPL)/CVS\ po/ja/CVS\ po/ru/CVS\ po/fr/CVS\ po/CVS CCLL = cl EEAANN = ean BACKUPDIR = /mnt/halfmoon/home/william/src/tgif/v4/backup distr: tar versioninfo rcstar: @rm -f home/RCS3.tar.gz.save @if [ -f home/RCS3.tar.gz ]; then \ mv home/RCS3.tar.gz home/RCS3.tar.gz.save; \ fi tar cf home/RCS3.tar RCS xbm.RCS gzip home/RCS3.tar ls -l home/RCS3.tar.gz spec: @rm -f tgif.spec echo "%define ver $(TGIFVERSION)" > tgif.spec cat tgif.spec.in >> tgif.spec clean-rmcast-qpl: pushd rmcast-qpl; ./configure; make $(CCLL)$(EEAANN); popd rm -rf $(RMCASTJUNK_QPL) clean-rmcast-gpl: pushd rmcast-gpl; make $(CCLL)$(EEAANN); popd install-tgwb-qpl: install $(INSTALL) $(INSTALLFLAGS) rmcast/tgif/tgwb $(DESTDIR)$(BINDIR)/tgwb $(INSTALL) $(INSTALLFLAGS) $(INSTPGMFLAGS) \ rmcast/mcastproxy/mcastproxy $(DESTDIR)$(BINDIR)/mcastproxy install-tgwb: install-tgwb-qpl install-tgwb-gpl: install $(INSTALL) $(INSTALLFLAGS) rmcast/tools/scripts/tgwb \ $(DESTDIR)$(BINDIR)/tgwb $(INSTALL) $(INSTALLFLAGS) $(INSTPGMFLAGS) \ rmcast/tools/mcastproxy/mcastproxy \ $(DESTDIR)$(BINDIR)/mcastproxy tar: spec clean-rmcast-qpl rm -f tgif-$(TGIFVERSION).tar/**/* tar cvf tgif-$(TGIFVERSION).tar /**/*.c /**/*.e /**/*.h \ Makefile.am Makefile.noimake Imakefile Target.tmpl Tgif.tmpl \ Tgif.tmpl-/**/* descrip./**/??? tgif.spec.in tgif.spec \ make./**/* VMS_MAKE_TGIF.COM tgificon.obj $(XBMDIR)*.xbm \ tgificon.xbm tgificon.xpm tgif.gif tgif.Xdefaults tgificon.eps \ $(ICONSDIR)22x22/apps//**/*.png \ $(ICONSDIR)32x32/apps//**/*.png \ $(ICONSDIR)48x48/apps//**/*.png \ $(ICONSDIR)64x64/apps//**/*.png \ $(ICONSDIR)128x128/apps//**/*.png \ $(OBJDEMO) \ $(SYMDEMO) \ $(MISCTAR) LICENSE.QPL \ $(RMCASTDIR_QPL) \ po rm -rf tgif-$(TGIFVERSION) mkdir tgif-$(TGIFVERSION) cd tgif-$(TGIFVERSION); tar xvf ../tgif-$(TGIFVERSION).tar; cd .. cd tgif-$(TGIFVERSION); rm -rf $(CVSSUBDIRS_QPL); cd .. cd tgif-$(TGIFVERSION); mv $(RMCASTDIR_QPL) rmcast; cd .. cd tgif-$(TGIFVERSION); ./bootstrap.pl $(TGIFVERSION); cd .. cd tgif-$(TGIFVERSION); rm -rf $(AUTOCONF_JUNK); cd .. rm -f tgif-$(TGIFVERSION).tar tar cvf tgif-$(TGIFVERSION).tar tgif-$(TGIFVERSION) rm -rf tgif-$(TGIFVERSION) gzip tgif-$(TGIFVERSION).tar rpmtar: spec clean-rmcast-qpl rm -f tgif-$(TGIFVERSION).tar/**/* tar cvf tgif-$(TGIFVERSION).tar /**/*.c /**/*.e /**/*.h \ Makefile.am Makefile.noimake Imakefile Target.tmpl Tgif.tmpl \ Tgif.tmpl-/**/* descrip./**/??? tgif.spec.in tgif.spec \ make./**/* VMS_MAKE_TGIF.COM tgificon.obj $(XBMDIR)*.xbm \ tgificon.xbm tgificon.xpm tgif.gif tgif.Xdefaults tgificon.eps \ $(ICONSDIR)22x22/apps//**/*.png \ $(ICONSDIR)32x32/apps//**/*.png \ $(ICONSDIR)48x48/apps//**/*.png \ $(ICONSDIR)64x64/apps//**/*.png \ $(ICONSDIR)128x128/apps//**/*.png \ $(OBJDEMO) \ $(SYMDEMO) \ $(MISCTAR) LICENSE.QPL \ rmcast \ po rm -rf tgif-$(TGIFVERSION) mkdir tgif-$(TGIFVERSION) cd tgif-$(TGIFVERSION); tar xvf ../tgif-$(TGIFVERSION).tar; cd .. cd tgif-$(TGIFVERSION); rm -rf $(CVSSUBDIRS_QPL); cd .. cd tgif-$(TGIFVERSION); ./bootstrap.pl $(TGIFVERSION); cd .. cd tgif-$(TGIFVERSION); rm -rf $(AUTOCONF_JUNK); cd .. rm -f tgif-$(TGIFVERSION).tar tar cvf tgif-$(TGIFVERSION).tar tgif-$(TGIFVERSION) rm -rf tgif-$(TGIFVERSION) gzip tgif-$(TGIFVERSION).tar QPL: spec rm -f tgif-QPL-$(TGIFVERSION).tar/**/* tar cvf tgif-QPL-$(TGIFVERSION).tar /**/*.c /**/*.e /**/*.h \ Makefile.am Makefile.noimake Imakefile Target.tmpl Tgif.tmpl \ Tgif.tmpl-/**/* descrip./**/??? tgif.spec.in tgif.spec \ make./**/* VMS_MAKE_TGIF.COM tgificon.obj $(XBMDIR)*.xbm \ tgificon.xbm tgificon.xpm tgif.gif tgif.Xdefaults tgificon.eps \ $(ICONSDIR)22x22/apps//**/*.png \ $(ICONSDIR)32x32/apps//**/*.png \ $(ICONSDIR)48x48/apps//**/*.png \ $(ICONSDIR)64x64/apps//**/*.png \ $(ICONSDIR)128x128/apps//**/*.png \ $(OBJDEMO) \ $(SYMDEMO) \ $(MISCTAR) LICENSE.QPL \ rmcast \ po rm -rf tgif-QPL-$(TGIFVERSION) mkdir tgif-QPL-$(TGIFVERSION) cd tgif-QPL-$(TGIFVERSION);tar xvf ../tgif-QPL-$(TGIFVERSION).tar;cd .. rm -f tgif-QPL-$(TGIFVERSION).tar cd tgif-QPL-$(TGIFVERSION); ./bootstrap.pl $(TGIFVERSION); cd .. cd tgif-QPL-$(TGIFVERSION); rm -rf $(AUTOCONF_JUNK); cd .. tar cvf tgif-QPL-$(TGIFVERSION).tar tgif-QPL-$(TGIFVERSION) rm -rf tgif-QPL-$(TGIFVERSION) gzip tgif-QPL-$(TGIFVERSION).tar rmcastlinks: ln -s rmcast rmcast-qpl ln -s rmcast rmcast-gpl rpm-src: rmcastlinks rpmtar rpmbuild -ba tgif.spec rpm-bin: rmcastlinks rpmtar # The following stopped working after Fedora 11 # rpmbuild -ta tgif-$(TGIFVERSION).tar.gz # # Beyond Fedora 11, if the following command failed, try this and then # run it again: # cp tgif-$(TGIFVERSION).tar.gz /usr/src/redhat/SOURCE rpmbuild -ba --target i386-linux tgif.spec backup: distr rm -rf $(BACKUPDIR).old mv $(BACKUPDIR) $(BACKUPDIR).old mkdir $(BACKUPDIR) tar cf - RCS VersionInfo tgif-$(TGIFVERSION).tar.gz | \ (cd $(BACKUPDIR); tar xvpf -) MAN_1 = README /**/*.man Imakefile Copyright License BASIC_1 = Makefile.noimake descrip./**/* make./**/* HISTORY tgif.Xdefaults \ Tgif.tmpl Tgif.tmpl-/**/* VMS_MAKE_TGIF.COM MISC_1 = an-sr-flip-flop.obj fonts.obj slide-demo.obj keys.obj \ launch-demo.obj launch-demo-1.obj \ flip-flop.sym nand2.sym pin.sym tangram.sym tgificon.xbm \ eq4.sym eq4-2x.sym eq4-ps2epsi.sym eq4-epstool.sym eq4xpm.sym \ eq4-lyx-ps2epsi.sym eq4xpm-land.sym eq4png.sym eq4jpg.sym \ eq4-2x-jpg.sym eq4-2x-nowin-jpg.sym MISC_2 = tgif.pl testdrive.pl frontend.pl tgificon.obj example.tex MISC_3 = tgificon.xpm tgif.gif tgificon.eps SPICE_1 = spice $(SPICEDIR)*.obj $(SPICEDIR)*.sym $(SPICEDIR)*.mod shar: rm -f tgif-$(TGIFVERSION).shar./**/* shar -otgif-$(TGIFVERSION).shar.1 -n1 -e38 $(MAN_1) shar -otgif-$(TGIFVERSION).shar.2 -n2 -e38 $(BASIC_1) shar -otgif-$(TGIFVERSION).shar.3 -n3 -e38 a[a-n]/**/*.c shar -otgif-$(TGIFVERSION).shar.4 -n4 -e38 a[o-s]/**/*.c shar -otgif-$(TGIFVERSION).shar.5 -n5 -e38 a[t-z]/**/*.c shar -otgif-$(TGIFVERSION).shar.6 -n6 -e38 b/**/*.c shar -otgif-$(TGIFVERSION).shar.7 -n7 -e38 c[a-m]/**/*.c shar -otgif-$(TGIFVERSION).shar.8 -n8 -e38 c[n-z]/**/*.c shar -otgif-$(TGIFVERSION).shar.9 -n9 -e38 d/**/*.c shar -otgif-$(TGIFVERSION).shar.10 -n10 -e38 e[a-d]/**/*.c shar -otgif-$(TGIFVERSION).shar.11 -n11 -e38 e[e-z]/**/*.c shar -otgif-$(TGIFVERSION).shar.12 -n12 -e38 f[a-i]/**/*.c shar -otgif-$(TGIFVERSION).shar.13 -n13 -e38 f[j-z]/**/*.c shar -otgif-$(TGIFVERSION).shar.14 -n14 -e38 [g-l]/**/*.c shar -otgif-$(TGIFVERSION).shar.15 -n15 -e38 ma/**/*.c shar -otgif-$(TGIFVERSION).shar.16 -n16 -e38 m[b-e]/**/*.c shar -otgif-$(TGIFVERSION).shar.17 -n17 -e38 m[f-z]/**/*.c shar -otgif-$(TGIFVERSION).shar.18 -n18 -e38 n/**/*.c shar -otgif-$(TGIFVERSION).shar.19 -n19 -e38 o/**/*.c p[a-n]/**/*.c shar -otgif-$(TGIFVERSION).shar.20 -n20 -e38 poly.c shar -otgif-$(TGIFVERSION).shar.21 -n21 -e38 polygon.c p[p-z]/**/*.c shar -otgif-$(TGIFVERSION).shar.22 -n22 -e38 r[a-c]/**/*.c stk/**/*.c shar -otgif-$(TGIFVERSION).shar.23 -n23 -e38 r[d-z]/**/*.c shar -otgif-$(TGIFVERSION).shar.24 -n24 -e38 sc/**/*.c sel/**/*.c shar -otgif-$(TGIFVERSION).shar.25 -n25 -e38 set/**/*.c s[f-p]/**/*.c shar -otgif-$(TGIFVERSION).shar.26 -n26 -e38 str/**/*.c shar -otgif-$(TGIFVERSION).shar.27 -n27 -e38 text.c shar -otgif-$(TGIFVERSION).shar.28 -n28 -e38 testdrive.c t[f-z]/**/*.c \ [u-w]/**/*.c shar -otgif-$(TGIFVERSION).shar.29 -n29 -e38 x[a-m]/**/*.c shar -otgif-$(TGIFVERSION).shar.30 -n30 -e38 x[n-z]/**/*.c shar -otgif-$(TGIFVERSION).shar.31 -n31 -e38 [a-n]/**/*.e shar -otgif-$(TGIFVERSION).shar.32 -n32 -e38 [o-z]/**/*.e /**/*.h shar -otgif-$(TGIFVERSION).shar.33 -n33 -e38 xbm xbm/[a-k]/**/*.xbm \ xbm/l[a-s]/**/*.xbm shar -otgif-$(TGIFVERSION).shar.34 -n34 -e38 xbm/l[t-z]/**/*.xbm \ xbm/[m-z]/**/*.xbm shar -otgif-$(TGIFVERSION).shar.35 -n35 -e38 $(MISC_1) shar -otgif-$(TGIFVERSION).shar.36 -n36 -e38 $(MISC_2) shar -otgif-$(TGIFVERSION).shar.37 -n37 -e38 $(MISC_3) shar -otgif-$(TGIFVERSION).shar.38 -n38 -e38 $(SPICE_1) versioninfo: ident .psmac /**/*.c /**/*.e /**/*.h Makefile.noimake Imakefile \ Tgif.tmpl /**/*.man tgif.pl README example.tex HISTORY \ tgificon.obj an-sr-flip-flop.obj fonts.obj slide-demo.obj \ keys.obj flip-flop.sym nand2.sym pin.sym tangram.sym \ eq4.sym eq4-2x.sym eq4-ps2epsi.sym eq4-epstool.sym \ $(SPICEDIR)*.obj $(SPICEDIR)*.sym testdrive.pl frontend.pl \ descrip.mms descrip.opt tgifmacro.ps $(XBMDIR)*.xbm \ tgificon.xbm tgif.Xdefaults tgificon.eps \ VMS_MAKE_TGIF.COM launch-demo.obj launch-demo-1.obj \ Copyright License make./**/* Tgif.tmpl-/**/* tgif.spec.in \ Imakefile.tgwb README.tgwb Target.tmpl $(SPICEDIR)README \ eq4xpm.sym eq4-lyx-ps2epsi.sym eq4xpm-land.sym eq4png.sym \ eq4jpg.sym eq4-2x-jpg.sym bootstrap.pl scan2ac.awk Makefile.am \ eq4-2x-nowin-jpg.sym \ > VersionInfo/Distribution/tgif-$(TGIFVERSION) ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/wb.c���������������������������������������������������������������������������������0000644�0000764�0000764�00000260242�11602233313�013547� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb.c,v 1.45 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_WB_C_ #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) #include <pthread.h> #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ #include "tgifdefs.h" #include "cmdids.h" #ifdef _HAS_STREAMS_SUPPORT #include <stropts.h> #include <sys/types.h> #endif /* _HAS_STREAMS_SUPPORT */ #include "rmcast/src/rmcast.h" #include "auxtext.e" #include "chat.e" #include "choice.e" #include "color.e" #include "cmd.e" #include "dialog.e" #include "drawing.e" #include "file.e" #include "font.e" #include "grid.e" #include "http.e" #include "import.e" #include "mark.e" #include "menu.e" #include "msg.e" #include "obj.e" #include "page.e" #include "raster.e" #include "remote.e" #include "rm_intrf.e" #include "ruler.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "stk.e" #include "strtbl.e" #include "tcp.e" #include "util.e" #include "version.e" #include "wb.e" #include "wb_buff.e" #include "wb_seg.e" #include "xpixmap.e" #include "z_intrf.e" struct WhiteBoardRec gstWBInfo; int cmdLineNoWhiteBoard=FALSE; int cmdLineWhiteBoardListenOnly=FALSE; static int recordCmdLogicalClock=0; static char recordCmdSenderProcID[MAXSTRING]; #ifdef _TGIF_DBG_WB2 static int wb2DebugLevel=0; #endif /* _TGIF_DBG_WB2 */ /* =================== Remote Related Functions =================== */ static void CleanUpWBSockets() { if (gstWBInfo.listening) { if (gstWBInfo.listen_socket != (-1)) { close(gstWBInfo.listen_socket); gstWBInfo.listen_socket = (-1); } if (gstWBInfo.listen_fp != NULL) { fclose(gstWBInfo.listen_fp); gstWBInfo.listen_fp = NULL; } if (gstWBInfo.gz_listen_fp != NULL) { fclose(gstWBInfo.gz_listen_fp); gstWBInfo.gz_listen_fp = NULL; } if (*gstWBInfo.gz_listen_fname != '\0') { unlink(gstWBInfo.gz_listen_fname); *gstWBInfo.gz_listen_fname = '\0'; } if (*gstWBInfo.listen_fname != '\0') { unlink(gstWBInfo.listen_fname); *gstWBInfo.listen_fname = '\0'; } gstWBInfo.listening = FALSE; } if (gstWBInfo.send_socket != (-1)) { close(gstWBInfo.send_socket); gstWBInfo.send_socket = (-1); } if (gstWBInfo.gz_send_fp != NULL) { fclose(gstWBInfo.gz_send_fp); gstWBInfo.gz_send_fp = NULL; } if (gstWBInfo.send_fp != NULL) { fclose(gstWBInfo.send_fp); gstWBInfo.send_fp = NULL; } if (*gstWBInfo.gz_send_fname != '\0') { unlink(gstWBInfo.gz_send_fname); *gstWBInfo.gz_send_fname = '\0'; } if (*gstWBInfo.send_fname != '\0') { unlink(gstWBInfo.send_fname); *gstWBInfo.send_fname = '\0'; } } static void CleanUpWBShadowCmds() { struct CmdRec *cmd_ptr=NULL; int num_records=0; for (cmd_ptr=gstWBInfo.last_shadow_cmd; cmd_ptr != NULL; cmd_ptr=cmd_ptr->prev) { num_records++; } if (num_records > 0) { struct CmdRec *prev_cmd=NULL; double inc=(100.0/((double)num_records)), percent_start=0.0; ShowInterrupt(1); SaveStatusStrings(); for (cmd_ptr=gstWBInfo.last_shadow_cmd; cmd_ptr != NULL; cmd_ptr=prev_cmd, percent_start+=inc) { prev_cmd = cmd_ptr->prev; DeleteARedoRecord(cmd_ptr, percent_start, min(((double)percent_start+inc),((double)100.0))); } RestoreStatusStrings(); HideInterrupt(); } gstWBInfo.first_shadow_cmd = gstWBInfo.last_shadow_cmd = NULL; } static void CleanUpWBCmds() { struct CmdRec *cmd_ptr=NULL; int num_records=0; for (cmd_ptr=gstWBInfo.last_cmd; cmd_ptr != NULL; cmd_ptr=cmd_ptr->prev) { num_records++; } if (num_records > 0) { struct CmdRec *prev_cmd=NULL; double inc=(100.0/((double)num_records)), percent_start=0.0; ShowInterrupt(1); SaveStatusStrings(); for (cmd_ptr=gstWBInfo.last_cmd; cmd_ptr != NULL; cmd_ptr=prev_cmd, percent_start+=inc) { prev_cmd = cmd_ptr->prev; DeleteARedoRecord(cmd_ptr, percent_start, min(((double)percent_start+inc),((double)100.0))); } RestoreStatusStrings(); HideInterrupt(); } gstWBInfo.first_cmd = gstWBInfo.last_cmd = gstWBInfo.cur_cmd = NULL; CleanUpWBShadowCmds(); } static int CreateWBListenSocket() { gstWBInfo.listening = TRUE; if (MkTempFile(gstWBInfo.listen_fname, sizeof(gstWBInfo.listen_fname), tmpDir, TOOL_NAME) == NULL) { fprintf(stderr, "Fail to create '%s' for deserialization.\n", gstWBInfo.listen_fname); return FALSE; } snprintf(gstWBInfo.gz_listen_fname, sizeof(gstWBInfo.gz_listen_fname), "%s.z", gstWBInfo.listen_fname); if ((gstWBInfo.listen_fp=fopen(gstWBInfo.listen_fname, "w+")) == NULL) { fprintf(stderr, "Fail to create '%s' for deserialization.\n", gstWBInfo.listen_fname); return FALSE; } if ((gstWBInfo.gz_listen_fp=fopen(gstWBInfo.gz_listen_fname, "w+")) == NULL) { fprintf(stderr, "Fail to create '%s' for deserialization.\n", gstWBInfo.gz_listen_fname); return FALSE; } return TRUE; } void PrintFullIDsOfObjects(psz_prefix) char *psz_prefix; { #ifdef _TGIF_DBG_WB2 if (wb2DebugLevel > 0) { struct ObjRec *obj_ptr=NULL; int stacking_order=0; if (psz_prefix != NULL) { if (strcmp(psz_prefix, "\t") == 0) { fprintf(stderr, "\tin PrintFullIDsOfObjects():\n"); } else { fprintf(stderr, "%s, in PrintFullIDsOfObjects():\n", psz_prefix); } } else { fprintf(stderr, "In PrintFullIDsOfObjects():\n"); } for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next, stacking_order++) { char buf[MAXSTRING], obj_type[MAXSTRING]; if (obj_ptr->creator_full_id == NULL) { sprintf(buf, "(NULL)%1d/%s", obj_ptr->id, gszLocalPID); } else { strcpy(buf, obj_ptr->creator_full_id); } switch (obj_ptr->type) { case OBJ_POLY: strcpy(obj_type, "p"); break; case OBJ_BOX: strcpy(obj_type, "b"); break; case OBJ_OVAL: strcpy(obj_type, "o"); break; case OBJ_TEXT: strcpy(obj_type, "t"); { MiniLinesInfo *minilines=(&obj_ptr->detail.t->minilines); char *psz=minilines->first->first_block->seg->dyn_str.s; char buf1[MAXSTRING]; int len=strlen(psz); if (len > 5) { char saved_ch=psz[5]; sprintf(buf1, " - \"%s...\"", psz); psz[5] = saved_ch; } else { sprintf(buf1, " - \"%s\"", psz); } strcat(buf, buf1); } break; case OBJ_POLYGON: strcpy(obj_type, "g"); break; case OBJ_ARC: strcpy(obj_type, "a"); break; case OBJ_RCBOX: strcpy(obj_type, "rcb"); break; case OBJ_XBM: strcpy(obj_type, "xbm"); break; case OBJ_XPM: strcpy(obj_type, "xpm"); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: strcpy(obj_type, "r"); break; } fprintf(stderr, "\t%d/%s:\t%s\n", stacking_order, obj_type, buf); } } #endif /* _TGIF_DBG_WB2 */ } int RecvWBData(flag, ppsz_buf, pn_buf_sz) int flag, *pn_buf_sz; char **ppsz_buf; { int retval; retval = buff_rem(gstWBInfo.bd_commands, (void**)ppsz_buf); return retval; } static void ProcessWBInputData(buf) char *buf; /* * Here the WB input data is in the HTTP data format. * So we use HttpExtractText() to convert the data into * something that can be handled by ProcessRemoteCmd(). * In the future, if the WB input data is binary, this is * where the conversion takes place. */ { char *psz_content=NULL, *psz_content_type=NULL; int content_sz=0; psz_content = HttpExtractText(buf, &content_sz, NULL, &psz_content_type); if (psz_content != NULL) { ProcessRemoteCmd(psz_content_type, psz_content, content_sz); FreeRemoteBuf(psz_content); } if (psz_content_type != NULL) UtilFree(psz_content_type); } int WBHasReadData(pn_flag, pn_retry) int *pn_flag, *pn_retry; { /* leave *pn_retry alone */ if ((!(gstWBInfo.BlockRemoteCmdDepth <= 1)) && (buff_items(gstWBInfo.bd_commands) > 0) ) { /* FIXME fprintf(stderr,"gstWBInfo.BlockRemoteCmdDepth > 1 e existem dados no buffer. (WBHasReadData)\n"); exit(1); */ } return (gstWBInfo.BlockRemoteCmdDepth <= 1 && buff_items(gstWBInfo.bd_commands) > 0); } void TryHandleWBInputData() { int flag=0, retry=TRUE; char *buf; int buf_sz; while (retry && WBHasReadData(&flag, &retry)) { buf=NULL; buf_sz=0; deserializingFile = TRUE; if (RecvWBData(flag, &buf, &buf_sz)) { ProcessWBInputData(buf); FreeRemoteBuf(buf); } deserializingFile = FALSE; } } int SendWBData(pszWBData, logical_clock) char *pszWBData; int logical_clock; { int nPackets1, i; struct SegmentationPack *pack1; #ifdef DEBUG fprintf(stderr,"Mensagem enviada:\n%s\n", pszWBData); #endif pack1 = Segment( pszWBData, strlen(pszWBData), gszLocalPID, logical_clock, &nPackets1 ); for( i = 0; i < nPackets1; i++ ) { RM_sendto(gstWBInfo.MCastSock, (char*)&pack1[i], sizeof(struct SegmentationPack)); } free( pack1 ); #ifdef _TGIF_DBG_WB2 fprintf(stderr, "SendWBData(), pid = %ld\n", gstWBInfo.pid); #endif /* _TGIF_DBG_WB2 */ return TRUE; } /* =================== Cmd Related Functions =================== */ static int SaveCmd(FP, CmdType, psi) FILE *FP; int CmdType; SerializationInfo *psi; { struct SelRec *sel_ptr=NULL; int count=0; /* * This part should work now! * * if (recordCmdIncludeTgifObj) { * sprintf(gszMsgBox, "%s.\n%s %s.\n\n%s %s.", * "Warning: recordCmdIncludeTgifObj is TRUE in SaveCmd()", * TOOL_NAME, "WhiteBoard may crash", * "Please try to reproduce this error and send bug report to", * authorEmailString); * MsgBox(gszMsgBox, TOOL_NAME, STOP_MB); * return FALSE; * } else */ if (CmdType == CMD_GOTO_PAGE) { /* * GotoPage() is disabled for _TGIF_WB2. */ return FALSE; } if (fprintf(FP, "cmd(%1d,", CmdType) == EOF) { writeFileFailed = TRUE; } if (CmdType == CMD_MOVE) { if (fprintf(FP, "%1d,%1d,", psi->subcmd->detail.move.dx, psi->subcmd->detail.move.dy) == EOF) { writeFileFailed = TRUE; } } else if (CmdType == CMD_WB_CLEARALL) { if (fprintf(FP, "%1d,%.3f,", psi->subcmd->detail.clearall.page_style, psi->subcmd->detail.clearall.print_mag) == EOF) { writeFileFailed = TRUE; } } else if (CmdType == CMD_WB_SLIDESHOW) { if (fprintf(FP, "%1d,", psi->subcmd->detail.slideshow.into_slideshow) == EOF) { writeFileFailed = TRUE; } } else if (CmdType == CMD_CHAT_A_LINE) { if (fprintf(FP, "%1d,'", psi->subcmd->detail.chat.type) == EOF) { writeFileFailed = TRUE; } SaveString(FP, psi->subcmd->detail.chat.nick_name); if (fprintf(FP, "','%s',%1d,'%s',", psi->subcmd->detail.chat.tfi.color_str, psi->subcmd->detail.chat.tfi.font_style, psi->subcmd->detail.chat.encoding) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "\"") == EOF) writeFileFailed = TRUE; SaveString(FP, psi->subcmd->detail.chat.buf); if (fprintf(FP, "\",") == EOF) writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,\"%s\").\n", psi->include_tgif_obj, psi->new_colormap, psi->logical_clock, psi->sender_process_id) == EOF) { writeFileFailed = TRUE; } /* Lamport's Algorithm increments logical_clock */ gstWBInfo.logical_clock++; if (psi->bot_before != NULL) { if (fprintf(FP, "before_image(%1d,[\n", psi->count_before) == EOF) { writeFileFailed = TRUE; } for (count=0, sel_ptr=psi->top_before; sel_ptr != NULL; sel_ptr=sel_ptr->next, count++) { struct ObjRec *obj_ptr=sel_ptr->obj; char buf[MAXSTRING]; if (psi->pos_before_has_ids) { sprintf(buf, "%s", ((char**)psi->pos_before)[count]); } else { if (obj_ptr->creator_full_id == NULL) { sprintf(buf, "%1d/%s", obj_ptr->id, psi->sender_process_id); } else { strcpy(buf, obj_ptr->creator_full_id); } } if (fprintf(FP, "\t\"") == EOF) writeFileFailed = TRUE; SaveString(FP, buf); if (sel_ptr->next == NULL) { if (fprintf(FP, "\"\n") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, "\",\n") == EOF) writeFileFailed = TRUE; } } if (fprintf(FP, "]).\n") == EOF) writeFileFailed = TRUE; } if (psi->bot_sel != NULL) { struct SelRec *sel_ptr; int *stacking_pos=NULL, stacking_count=0; sel_ptr = PrepareStackingInfo(psi->top_sel, psi->bot_sel, psi->num_objs, FALSE, &stacking_pos, &stacking_count, NULL); if (sel_ptr == NULL && stacking_count == psi->num_objs) { if (fprintf(FP, "after_positions(%1d,[\n", psi->num_objs) == EOF) { writeFileFailed = TRUE; } for (count=0, sel_ptr=psi->top_sel; count < stacking_count && sel_ptr != NULL; count++, sel_ptr=sel_ptr->next) { char buf[MAXSTRING]; sprintf(buf, "%1d", stacking_pos[count]); if (fprintf(FP, "\t") == EOF) writeFileFailed = TRUE; SaveString(FP, buf); if (sel_ptr->next == NULL) { if (fprintf(FP, "\n") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, ",\n") == EOF) writeFileFailed = TRUE; } } if (fprintf(FP, "]).\n") == EOF) writeFileFailed = TRUE; if (fprintf(FP, "after_image(%1d,[\n", psi->num_objs) == EOF) { writeFileFailed = TRUE; } for (count=0, sel_ptr=psi->top_sel; sel_ptr != NULL; sel_ptr=sel_ptr->next, count++) { SaveObj(FP, sel_ptr->obj, 1); if (sel_ptr->next == NULL) { if (fprintf(FP, "\n") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, ",\n") == EOF) writeFileFailed = TRUE; } } if (fprintf(FP, "]).\n") == EOF) writeFileFailed = TRUE; } if (stacking_pos != NULL) free(stacking_pos); } return TRUE; } static void PrepareExtendedSerializationInfo(CmdPtr, psi) struct CmdRec *CmdPtr; SerializationInfo *psi; { psi->subcmd = CmdPtr->subcmd; psi->top_sel = NULL; /* not used */ psi->bot_sel = NULL; /* not used */ psi->num_objs = 0; /* not used */ psi->include_tgif_obj = CmdPtr->include_tgif_obj; psi->new_colormap = CmdPtr->new_colormap; psi->logical_clock = CmdPtr->logical_clock; psi->sender_process_id = CmdPtr->sender_process_id; psi->top_before = CmdPtr->top_before; psi->bot_before = CmdPtr->bot_before; psi->pos_before = CmdPtr->pos_before; psi->count_before = CmdPtr->count_before; psi->pos_before_has_ids = CmdPtr->pos_before_has_ids; } static int SaveExtendedCmd(FP, CmdPtr, psi) FILE *FP; struct CmdRec *CmdPtr; SerializationInfo *psi; { if (CmdPtr->type == CMD_GOTO_PAGE) { /* * GotoPage() is disabled for _TGIF_WB2. */ return FALSE; } else if (CmdPtr->type == CMD_CHAT_A_LINE) { /* * intentionally forget what has been chatted */ return FALSE; } if (CmdPtr->serialization_buf == NULL) { fprintf(stderr, "serialization_buf is NULL\n"); return FALSE; } #ifdef NOT_DEFINED /* this is replaced by simply printing CmdPtr->serialization_buf */ if (fprintf(FP, "cmdx(%1d,%1d,", CmdPtr->type, CmdPtr->undone) == EOF) { writeFileFailed = TRUE; } if (CmdPtr->type == CMD_MOVE) { if (fprintf(FP, "%1d,%1d,", CmdPtr->subcmd->detail.move.dx, CmdPtr->subcmd->detail.move.dy) == EOF) { writeFileFailed = TRUE; } } else if (CmdPtr->type == CMD_WB_CLEARALL) { if (fprintf(FP, "%1d,%.3f,", CmdPtr->subcmd->detail.clearall.page_style, CmdPtr->subcmd->detail.clearall.print_mag) == EOF) { writeFileFailed = TRUE; } } else if (CmdPtr->type == CMD_WB_SLIDESHOW) { if (fprintf(FP, "%1d,", CmdPtr->subcmd->detail.slideshow.into_slideshow) == EOF) { writeFileFailed = TRUE; } } else if (CmdPtr->type == CMD_CHAT_A_LINE) { /* intentionally forget what has been chatted */ return FALSE; } if (fprintf(FP, "%1d,%1d,%1d,\"%s\",%1d).\n", CmdPtr->include_tgif_obj, CmdPtr->new_colormap, CmdPtr->logical_clock, CmdPtr->sender_process_id, CmdPtr->undone) == EOF) { writeFileFailed = TRUE; } #endif /* NOT_DEFINED */ if (fprintf(FP, "%s", CmdPtr->serialization_buf) == EOF) { writeFileFailed = TRUE; } return TRUE; } static int SaveExtendedCmdInfo(FP, nNumCmds, nCurCmdPos) FILE *FP; int nNumCmds, nCurCmdPos; { if (fprintf(FP, "cmdxinfo(%1d,%1d).\n", nNumCmds, nCurCmdPos) == EOF) { writeFileFailed = TRUE; } return TRUE; } #ifdef _TGIF_DBG_WB2 static void DebugDumpCmd(psz_prefix, cmd_type, logical_clock, psz_process_id) char *psz_prefix, *psz_process_id; int cmd_type, logical_clock; { if (psz_prefix == NULL) { fprintf(stderr, "cmd(%1d,%1d,\"%s\")\n", cmd_type, logical_clock, psz_process_id); } else { fprintf(stderr, "%s, cmd(%1d,%1d,\"%s\")\n", psz_prefix, cmd_type, logical_clock, psz_process_id); } } #endif /* _TGIF_DBG_WB2 */ char *SerializeCmd(CmdType, psi, pnAssignedLogicalClock, ppszPlainWBData, pnPlainWBDataSz) int CmdType, *pnAssignedLogicalClock, *pnPlainWBDataSz; SerializationInfo *psi; char **ppszPlainWBData; { char *buf=NULL, header[MAXSTRING<<1]; int content_sz=0, ok=TRUE, header_sz=0, do_deflate=TRUE; long loc_sec=0L, loc_msec=0L; if (HasZlibSupport()) { #ifdef _TGIF_DBG_WB2 do_deflate = FALSE; #endif /* _TGIF_DBG_WB2 */ } else { do_deflate = FALSE; } if (gstWBInfo.send_fp == NULL || gstWBInfo.gz_send_fp == NULL) { sprintf(gszMsgBox, "Cannot open '%s' or '%s'.\n\nSerialization aborted.", gstWBInfo.send_fname, gstWBInfo.gz_send_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } *pnAssignedLogicalClock = gstWBInfo.logical_clock; rewind(gstWBInfo.send_fp); writeFileFailed = FALSE; UtilGetMilliSecTime(&loc_sec, &loc_msec); if (fprintf(gstWBInfo.send_fp, "%%TGWB begin - %ld.%ld\n", loc_sec, loc_msec) == EOF) { writeFileFailed = TRUE; } Save(gstWBInfo.send_fp, NULL, 0, 1); ok = SaveCmd(gstWBInfo.send_fp, CmdType, psi); /* gstWBInfo.logical_clock has been incremented in SaveCmd() */ if (fprintf(gstWBInfo.send_fp, "%%TGWB end - %ld.%ld\n", loc_sec, loc_msec) == EOF) { writeFileFailed = TRUE; } if (writeFileFailed) { FailToWriteFileMessage(gstWBInfo.send_fname); return NULL; } if (!ok) { return NULL; } content_sz = (int)ftell(gstWBInfo.send_fp); /* * From: <PID>:<IP>\r\n * Content-Type: application/x-tgif-cmd\r\n * Content-Length: <LENGTH>\r\n * \r\n * <DATA of size LENGTH> */ if (do_deflate && HasZlibSupport()) { int rc=0; char *new_buf=NULL; rewind(gstWBInfo.send_fp); new_buf = (char*)malloc((content_sz+1)*sizeof(char)); if (new_buf == NULL) FailAllocMessage(); if (fread(new_buf, sizeof(char), content_sz, gstWBInfo.send_fp) != content_sz) { #ifdef _TGIF_DBG_WB2 fprintf(stderr, "Failed to read %1d bytes in SerializeCmd().\n", content_sz); fflush(stderr); #endif /* _TGIF_DBG_WB2 */ do_deflate = FALSE; } else { new_buf[content_sz] = '\0'; *pnPlainWBDataSz = content_sz+1; *ppszPlainWBData = new_buf; if (!DoDeflate(gstWBInfo.send_fp, NULL, content_sz, gstWBInfo.gz_send_fp, TRUE, TRUE, &rc)) { ZlibError(rc, TRUE); do_deflate = FALSE; } else { content_sz = (int)ftell(gstWBInfo.gz_send_fp); } } } if (do_deflate) { sprintf(header, "%s%s\r\n%s%s\r\n%s%1d\r\n\r\n", "From: ", gszLocalPID, "Content-Type: ", "application/x-tgif-cmd-z", "Content-Length: ", content_sz); header_sz = strlen(header); buf = (char*)malloc((header_sz+content_sz+1)*sizeof(char)); if (buf == NULL) FailAllocMessage(); strcpy(buf, header); rewind(gstWBInfo.gz_send_fp); if (fread(&buf[header_sz], sizeof(char), content_sz, gstWBInfo.gz_send_fp) != content_sz) { sprintf(gszMsgBox, "Error in reading '%s'.\n\nSerialization aborted.", gstWBInfo.gz_send_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); UtilFree(buf); return NULL; } } else { sprintf(header, "%s%s\r\n%s%s\r\n%s%1d\r\n\r\n", "From: ", gszLocalPID, "Content-Type: ", "application/x-tgif-cmd", "Content-Length: ", content_sz); header_sz = strlen(header); buf = (char*)malloc((header_sz+content_sz+1)*sizeof(char)); if (buf == NULL) FailAllocMessage(); strcpy(buf, header); rewind(gstWBInfo.send_fp); if (fread(&buf[header_sz], sizeof(char), content_sz, gstWBInfo.send_fp) != content_sz) { sprintf(gszMsgBox, "Error in reading '%s'.\n\nSerialization aborted.", gstWBInfo.send_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); UtilFree(buf); return NULL; } } buf[header_sz+content_sz] = '\0'; #ifdef _TGIF_DBG_WB2 if (wb2DebugLevel == 0) { fprintf(stderr, "Sending %1d bytes, pid = %ld!\n", header_sz+content_sz+2, gstWBInfo.pid); } else { fprintf(stderr, "===========================\n"); if (do_deflate) { fprintf(stderr, "%s", header); fprintf(stderr, "[content not displayed] ...\n"); } else { fprintf(stderr, "%s", buf); } fprintf(stderr, "===========================\n"); fprintf(stderr, "Sending %1d bytes, pid = %ld!\n", header_sz+content_sz+2, gstWBInfo.pid); } DebugDumpCmd(">>> In SerializeCmd()", CmdType, *pnAssignedLogicalClock, gszLocalPID); PrintFullIDsOfObjects("In SerializeCmd()"); #endif /* _TGIF_DBG_WB2 */ return buf; } void SerializeFreeBuf(pszWBData) char *pszWBData; { UtilFree(pszWBData); } static struct CmdRec gstDeserializeCmd; static struct SubCmdRec *gpDeserializeSubCmd=NULL; static char **gppszBeforeImage=NULL; static int gnBeforeImageCount=0; static int *gpnAfterPositions=NULL; static int gnAfterPositionsCount=0; static int seenCmdXInfo=FALSE; static void CleanUpDeserializeCmd() { if (gpDeserializeSubCmd != NULL) free(gpDeserializeSubCmd); memset(&gstDeserializeCmd, 0, sizeof(struct CmdRec)); gpDeserializeSubCmd = NULL; } static int InitDeserializeCmd() { gpDeserializeSubCmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (gpDeserializeSubCmd == NULL) FailAllocMessage(); memset(gpDeserializeSubCmd, 0, sizeof(struct SubCmdRec)); memset(&gstDeserializeCmd, 0, sizeof(struct CmdRec)); gstDeserializeCmd.subcmd = gpDeserializeSubCmd; return TRUE; } static void DoDeserializationCleanUp() { switch (gstDeserializeCmd.type) { case CMD_WB_CLEARALL: break; case CMD_CHAT_A_LINE: UtilFree(gpDeserializeSubCmd->detail.chat.buf); break; case CMD_WB_SLIDESHOW: break; default: break; } memset(gpDeserializeSubCmd, 0, sizeof(struct SubCmdRec)); memset(&gstDeserializeCmd, 0, sizeof(gstDeserializeCmd)); gstDeserializeCmd.subcmd = gpDeserializeSubCmd; gstDeserializeCmd.type = INVALID; } static void CleanUpBeforeImage() { if (gppszBeforeImage != NULL) { int i; for (i=0; i < gnBeforeImageCount; i++) { if (gppszBeforeImage[i] != NULL) { UtilFree(gppszBeforeImage[i]); } else { break; } } free(gppszBeforeImage); } gppszBeforeImage = NULL; gnBeforeImageCount = 0; } static void CleanUpAfterPositions() { if (gpnAfterPositions != NULL) free(gpnAfterPositions); gpnAfterPositions = NULL; gnAfterPositionsCount = 0; } static void DeserializationCleanUp() { DoDeserializationCleanUp(); CleanUpBeforeImage(); CleanUpAfterPositions(); } static void ResetDeserializeCmd() { recordCmdIncludeTgifObj = FALSE; recordCmdUsesNewColormap = FALSE; memset(&gstDeserializeCmd, 0, sizeof(gstDeserializeCmd)); gstDeserializeCmd.subcmd = gpDeserializeSubCmd; gstDeserializeCmd.type = INVALID; gppszBeforeImage = NULL; gpnAfterPositions = NULL; gnBeforeImageCount = gnAfterPositionsCount = 0; } int ReadExtendedCmd(FP, Inbuf) FILE *FP; char *Inbuf; { char *c_ptr=NULL; c_ptr = FindChar((int)'(', Inbuf); InitScan(c_ptr, "\t\n, ()"); if (GETINT("cmdx", gstDeserializeCmd.type, "cmd_type") == INVALID || GETINT("cmdx", gstDeserializeCmd.undone, "undone") == INVALID) { return FALSE; } if (gstDeserializeCmd.type == INVALID) { return FALSE; } else if (gstDeserializeCmd.type == CMD_GOTO_PAGE) { return FALSE; } else if (gstDeserializeCmd.type == CMD_WB_CLEARALL) { int page_style=PORTRAIT; float print_mag=(float)100.0; if (GETINT("cmdx", page_style, "page_style") == INVALID || GETFLT("cmdx", print_mag, "print_mag") == INVALID) { return FALSE; } gpDeserializeSubCmd->detail.clearall.page_style = page_style; gpDeserializeSubCmd->detail.clearall.print_mag = print_mag; } else if (gstDeserializeCmd.type == CMD_WB_SLIDESHOW) { int into_slideshow=FALSE; if (GETINT("cmdx", into_slideshow, "into_slideshow") == INVALID) { return FALSE; } gpDeserializeSubCmd->detail.slideshow.into_slideshow = into_slideshow; } else if (gstDeserializeCmd.type == CMD_CHAT_A_LINE) { char nick_name[MAXSTRING], color_str[40], font_str[MAXSTRING]; char encoding[MAXSTRING]; int chat_type=FALSE, font_style=0, new_alloc=0; struct DynStrRec dyn_str; memset(&dyn_str, 0, sizeof(struct DynStrRec)); *nick_name = *color_str = *font_str = *encoding = '\0'; if (GETINT("cmdx", chat_type, "type") == INVALID || GETSTR("cmdx", nick_name, "nick_name") == INVALID || GETSTR("cmdx", color_str, "color_str") == INVALID || GETINT("cmdx", font_style, "font_style") == INVALID || GETSTR("cmdx", encoding, "encoding") == INVALID || GETDYN("cmdx", dyn_str, "buf") == INVALID) { return FALSE; } UtilRemoveQuotes(nick_name); UtilRemoveQuotes(color_str); UtilRemoveQuotes(encoding); gpDeserializeSubCmd->detail.chat.tfi.color_index = QuickFindColorIndex(NULL, color_str, &new_alloc, TRUE); UtilStrCpyN(gpDeserializeSubCmd->detail.chat.tfi.color_str, sizeof(gpDeserializeSubCmd->detail.chat.tfi.color_str), colorMenuItems[gpDeserializeSubCmd->detail.chat.tfi.color_index]); gpDeserializeSubCmd->detail.chat.tfi.font_style = font_style; gpDeserializeSubCmd->detail.chat.type = chat_type; UtilStrCpyN(gpDeserializeSubCmd->detail.chat.nick_name, sizeof(gpDeserializeSubCmd->detail.chat.nick_name), nick_name); UtilStrCpyN(gpDeserializeSubCmd->detail.chat.encoding, sizeof(gpDeserializeSubCmd->detail.chat.encoding), encoding); gpDeserializeSubCmd->detail.chat.buf = dyn_str.s; dyn_str.s = NULL; } else if (gstDeserializeCmd.type == CMD_MOVE) { int dx=0, dy=0; if (GETINT("cmdx", dx, "dx") == INVALID || GETINT("cmdx", dy, "dy") == INVALID) { return FALSE; } gpDeserializeSubCmd->detail.move.dx = dx; gpDeserializeSubCmd->detail.move.dy = dy; } *recordCmdSenderProcID = '\0'; if (GETINT("cmdx", recordCmdIncludeTgifObj, "include_tgif_obj")==INVALID || GETINT("cmdx", recordCmdUsesNewColormap, "use_new_colormap")==INVALID || GETINT("cmdx", recordCmdLogicalClock, "logical_clock")==INVALID || GETSTR("cmdx", recordCmdSenderProcID, "sender_process_id")==INVALID || GETINT("cmdx", gstDeserializeCmd.undone, "undone")==INVALID) { return FALSE; } UtilRemoveQuotes(recordCmdSenderProcID); return TRUE; } int ReadExtendedCmdInfo(FP, Inbuf) FILE *FP; char *Inbuf; { char *c_ptr=NULL; int num_cmds=0, cur_cmd_pos=0; c_ptr = FindChar((int)'(', Inbuf); InitScan(c_ptr, "\t\n, ()"); if (GETINT("cmdxinfo", num_cmds, "num_cmds") == INVALID || GETINT("cmdxinfo", cur_cmd_pos, "cur_cmd_pos") == INVALID) { return FALSE; } seenCmdXInfo = TRUE; return TRUE; } int ReadCmd(FP, Inbuf) FILE *FP; char *Inbuf; { char *c_ptr=NULL; ResetDeserializeCmd(); c_ptr = FindChar((int)'(', Inbuf); InitScan(c_ptr, "\t\n, ()"); if (GETINT("cmd", gstDeserializeCmd.type, "cmd_type") == INVALID) { return FALSE; } if (gstDeserializeCmd.type == INVALID) { return FALSE; } else if (gstDeserializeCmd.type == CMD_GOTO_PAGE) { return FALSE; } else if (gstDeserializeCmd.type == CMD_WB_CLEARALL) { int page_style=PORTRAIT; float print_mag=(float)100.0; if (GETINT("cmd", page_style, "page_style") == INVALID || GETFLT("cmd", print_mag, "print_mag") == INVALID) { return FALSE; } gpDeserializeSubCmd->detail.clearall.page_style = page_style; gpDeserializeSubCmd->detail.clearall.print_mag = print_mag; } else if (gstDeserializeCmd.type == CMD_WB_SLIDESHOW) { int into_slideshow=FALSE; if (GETINT("cmd", into_slideshow, "into_slideshow") == INVALID) { return FALSE; } gpDeserializeSubCmd->detail.slideshow.into_slideshow = into_slideshow; } else if (gstDeserializeCmd.type == CMD_CHAT_A_LINE) { char nick_name[MAXSTRING], color_str[40], font_str[MAXSTRING]; char encoding[MAXSTRING]; int chat_type=FALSE, font_style=0, new_alloc=0; struct DynStrRec dyn_str; memset(&dyn_str, 0, sizeof(struct DynStrRec)); *nick_name = *color_str = *font_str = *encoding = '\0'; if (GETINT("cmd", chat_type, "type") == INVALID || GETSTR("cmd", nick_name, "nick_name") == INVALID || GETSTR("cmd", color_str, "color_str") == INVALID || GETINT("cmd", font_style, "font_style") == INVALID || GETSTR("cmd", encoding, "encoding") == INVALID || GETDYN("cmd", dyn_str, "buf") == INVALID) { return FALSE; } UtilRemoveQuotes(nick_name); UtilRemoveQuotes(color_str); UtilRemoveQuotes(encoding); gpDeserializeSubCmd->detail.chat.tfi.color_index = QuickFindColorIndex(NULL, color_str, &new_alloc, TRUE); UtilStrCpyN(gpDeserializeSubCmd->detail.chat.tfi.color_str, sizeof(gpDeserializeSubCmd->detail.chat.tfi.color_str), colorMenuItems[gpDeserializeSubCmd->detail.chat.tfi.color_index]); gpDeserializeSubCmd->detail.chat.tfi.font_style = font_style; gpDeserializeSubCmd->detail.chat.type = chat_type; UtilStrCpyN(gpDeserializeSubCmd->detail.chat.nick_name, sizeof(gpDeserializeSubCmd->detail.chat.nick_name), nick_name); UtilStrCpyN(gpDeserializeSubCmd->detail.chat.encoding, sizeof(gpDeserializeSubCmd->detail.chat.encoding), encoding); gpDeserializeSubCmd->detail.chat.buf = dyn_str.s; dyn_str.s = NULL; } else if (gstDeserializeCmd.type == CMD_MOVE) { int dx=0, dy=0; if (GETINT("cmd", dx, "dx") == INVALID || GETINT("cmd", dy, "dy") == INVALID) { return FALSE; } gpDeserializeSubCmd->detail.move.dx = dx; gpDeserializeSubCmd->detail.move.dy = dy; } *recordCmdSenderProcID = '\0'; if (GETINT("cmd", recordCmdIncludeTgifObj, "include_tgif_obj") == INVALID || GETINT("cmd", recordCmdUsesNewColormap, "use_new_colormap") == INVALID || GETINT("cmd", recordCmdLogicalClock, "logical_clock") == INVALID || GETSTR("cmd", recordCmdSenderProcID, "sender_process_id") == INVALID) { return FALSE; } UtilRemoveQuotes(recordCmdSenderProcID); return TRUE; } int ReadBeforeImage(FP, Inbuf) FILE *FP; char *Inbuf; { char *c_ptr, *line; int index=0, ok=TRUE; c_ptr = FindChar((int)'(', Inbuf); InitScan(c_ptr, "\t\n, "); if (GETINT("before_image", gnBeforeImageCount, "before_image_count") == INVALID) { return FALSE; } if (gnBeforeImageCount > 0) { gppszBeforeImage = (char**)malloc(gnBeforeImageCount*sizeof(char*)); if (gppszBeforeImage == NULL) FailAllocMessage(); memset(gppszBeforeImage, 0, gnBeforeImageCount*sizeof(char*)); } index = 0; while ((line=UtilGetALine(FP)) != NULL) { char full_id[MAXSTRING]; scanLineNum++; if (*line == ']') { free(line); break; } if (index >= gnBeforeImageCount) { fprintf(stderr, "Warning: too many lines in before_image.\n"); free(line); break; } c_ptr = FindChar((int)'"', line); c_ptr = ParseStr(c_ptr, (int)'"', full_id, sizeof(full_id)); if (c_ptr == NULL) { ok = FALSE; free(line); break; } gppszBeforeImage[index] = UtilStrDup(full_id); if (gppszBeforeImage[index] == NULL) FailAllocMessage(); index++; free(line); } if (ok && index < gnBeforeImageCount) { fprintf(stderr, "Warning: too few lines in before_image.\n"); ok = FALSE; } if (!ok) { CleanUpBeforeImage(); } return ok; } int ReadAfterPositions(FP, Inbuf) FILE *FP; char *Inbuf; { char *c_ptr, *line; int index=0, ok=TRUE; c_ptr = FindChar((int)'(', Inbuf); InitScan(c_ptr, "\t\n, "); if (GETINT("after_positions", gnAfterPositionsCount, "after_positions_count") == INVALID) { return FALSE; } if (gnAfterPositionsCount > 0) { gpnAfterPositions = (int*)malloc(gnAfterPositionsCount*sizeof(int)); if (gpnAfterPositions == NULL) FailAllocMessage(); memset(gpnAfterPositions, 0, gnAfterPositionsCount*sizeof(int)); } index = 0; while ((line=UtilGetALine(FP)) != NULL) { int pos=(-1); scanLineNum++; if (*line == ']') { free(line); break; } if (index >= gnAfterPositionsCount) { fprintf(stderr, "Warning: too many lines in before_image.\n"); free(line); break; } InitScan(line, "\t\n, "); if (GETINT("after_positions", pos, "after_positions_pos") == INVALID) { ok = FALSE; free(line); break; } gpnAfterPositions[index++] = pos; free(line); } if (ok && index < gnAfterPositionsCount) { fprintf(stderr, "Warning: too few lines in after_positions.\n"); ok = FALSE; } if (!ok) { CleanUpBeforeImage(); } return ok; } int ReadAfterImage(FP, Inbuf) FILE *FP; char *Inbuf; { struct ObjRec *obj_ptr=NULL; char *c_ptr; int ok=TRUE, count_expected=(-1), count=0; c_ptr = FindChar((int)'(', Inbuf); InitScan(c_ptr, "\t\n, "); if (GETINT("after_image", count_expected, "after_image_count") == INVALID) { return FALSE; } count = 0; while (ReadObj(FP, &obj_ptr)) { if (obj_ptr == NULL) { ok = FALSE; break; } obj_ptr->next = NULL; obj_ptr->prev = botObj; if (botObj == NULL) { topObj = obj_ptr; } else { botObj->next = obj_ptr; } botObj = obj_ptr; obj_ptr = NULL; count++; } if (ok && count != count_expected) { fprintf(stderr, "Warning: object count mismatched in after_image.\n"); ok = FALSE; } return ok; } static void SelectObjects(top_obj, bot_obj) struct ObjRec *top_obj, *bot_obj; { struct ObjRec *obj_ptr; for (obj_ptr=bot_obj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; AddObjIntoSel(obj_ptr, NULL, topSel, &topSel, &botSel); } UpdSelBBox(); } static struct CmdRec *DeserializeCmd(psz_content_type, psz_buf, buf_sz, ppsz_plain_buf, pn_plain_buf_sz) char *psz_content_type, *psz_buf, **ppsz_plain_buf; int buf_sz, *pn_plain_buf_sz; { struct StkRec *stk_ptr=NULL; struct ObjRec *obj_ptr=NULL, *saved_top_obj=NULL, *saved_bot_obj=NULL; int read_status=TRUE, ok=TRUE, do_inflate=FALSE, need_to_free_buf=FALSE; struct CmdRec *cmd_ptr=NULL; if (gstWBInfo.listen_fp == NULL) { sprintf(gszMsgBox, "Cannot open '%s'.\n\n%s pid=%ld.", gstWBInfo.listen_fname, "Deserialization aborted for", gstWBInfo.pid); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } #ifdef _TGIF_DBG_WB2 fprintf(stderr, "Content-Type: %s\n", (psz_content_type!=NULL) ? psz_content_type : "(unknown)"); fprintf(stderr, "Content-Length: %1d\n", buf_sz); #endif /* _TGIF_DBG_WB2 */ if (psz_content_type != NULL && strcmp(psz_content_type, "application/x-tgif-cmd-z") == 0) { if (!HasZlibSupport()) { sprintf(gszMsgBox, "%s %s.\n\nDeserialization aborted.", TOOL_NAME, "is not compiled with ZLIB and cannot inflate()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } else { if (gstWBInfo.gz_listen_fp == NULL) { sprintf(gszMsgBox, "Cannot open '%s'.\n\n%s pid=%ld.", gstWBInfo.gz_listen_fname, "Deserialization aborted for", gstWBInfo.pid); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } do_inflate = TRUE; } } if (do_inflate && HasZlibSupport()) { int rc=0; if (!DoInflate(psz_buf, buf_sz, gstWBInfo.gz_listen_fp, TRUE, &rc)) { ZlibError(rc, FALSE); return NULL; } buf_sz = (int)ftell(gstWBInfo.gz_listen_fp); psz_buf = (char*)malloc(buf_sz+1); if (psz_buf == NULL) FailAllocMessage(); rewind(gstWBInfo.gz_listen_fp); if (fread(psz_buf, sizeof(char), buf_sz, gstWBInfo.gz_listen_fp) != buf_sz) { sprintf(gszMsgBox, "Cannot read %1d bytes from '%s'.\n\n%s.", buf_sz, gstWBInfo.gz_listen_fname, "Deserialization aborted"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); UtilFree(psz_buf); return NULL; } psz_buf[buf_sz] = '\0'; if (ppsz_plain_buf != NULL) { *pn_plain_buf_sz = buf_sz; *ppsz_plain_buf = UtilStrDup(psz_buf); if (*ppsz_plain_buf == NULL) FailAllocMessage(); } need_to_free_buf = TRUE; } #ifdef _TGIF_DBG_WB2 if (wb2DebugLevel == 0) { fprintf(stderr, "Received %1d bytes, pid = %ld, timestamp = (below)\n", buf_sz, gstWBInfo.pid); } else { fprintf(stderr, "<<<------------------------\n"); fprintf(stderr, "%s\n", psz_buf); fprintf(stderr, "<<<------------------------\n"); fprintf(stderr, "Received %1d bytes, pid = %ld, timestamp = (below)\n", buf_sz, gstWBInfo.pid); } PrintFullIDsOfObjects("In the beginning of DeserializeCmd()"); #endif /* _TGIF_DBG_WB2 */ rewind(gstWBInfo.listen_fp); writeFileFailed = FALSE; if (fprintf(gstWBInfo.listen_fp, "%s", psz_buf) == EOF) { writeFileFailed = TRUE; } if (writeFileFailed) { FailToWriteFileMessage(gstWBInfo.listen_fname); return NULL; } stk_ptr = SaveFileInfo(); ResetFileInfo(); /* if (usePaperSizeStoredInFile) ResetOnePageSize(); */ ResetDeserializeCmd(); rewind(gstWBInfo.listen_fp); importingFile = TRUE; strcpy(scanFileName, gstWBInfo.listen_fname); scanLineNum = 0; readingPageNum = loadedCurPageNum = 0; foundGoodStateObject = FALSE; while ((read_status=ReadObj(gstWBInfo.listen_fp, &obj_ptr)) == TRUE) { if (obj_ptr != NULL) { obj_ptr->tmp_parent = NULL; AdjForOldVersion(obj_ptr); AddObj(NULL, topObj, obj_ptr); } } importingFile = FALSE; if (read_status == INVALID) { sprintf(gszMsgBox, "File version too large (=%1d). %s!", fileVersion, "Deserialization aborted"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else { #ifdef _TGIF_DBG_WB2 fprintf(stderr, "%s, pid = %ld, timestamp = %1d/%s\n", "Command successfully parsed", gstWBInfo.pid, recordCmdLogicalClock, recordCmdSenderProcID); #endif /* _TGIF_DBG_WB2 */ if (recordCmdLogicalClock+1 > gstWBInfo.logical_clock) { /* Lamport's Algorithm set logical_clock */ gstWBInfo.logical_clock = recordCmdLogicalClock+1; #ifdef _TGIF_DBG_WB2 fprintf(stderr, "Logical clock for pid = %ld set to %1d.\n", gstWBInfo.pid, gstWBInfo.logical_clock); #endif /* _TGIF_DBG_WB2 */ } } if (!ok) { DelAllObj(); } else { saved_top_obj = topObj; saved_bot_obj = botObj; topObj = botObj = NULL; } RestoreFileInfo(stk_ptr); ResetOnePageSize(); free(stk_ptr); /* * This is new. Does it work?! */ UpdPageStyle(pageStyle); if (ok) { cmd_ptr = (struct CmdRec *)malloc(sizeof(struct CmdRec)); if (cmd_ptr == NULL) FailAllocMessage(); memset(cmd_ptr, 0, sizeof(struct CmdRec)); cmd_ptr->serialized = TRUE; /* created from deserialization */ cmd_ptr->top_before = cmd_ptr->bot_before = NULL; cmd_ptr->pos_before = (int*)gppszBeforeImage; cmd_ptr->count_before = gnBeforeImageCount; cmd_ptr->type = gstDeserializeCmd.type; cmd_ptr->undone = TRUE; cmd_ptr->include_tgif_obj = recordCmdIncludeTgifObj; cmd_ptr->new_colormap = recordCmdUsesNewColormap; cmd_ptr->logical_clock = recordCmdLogicalClock; if (*recordCmdSenderProcID != '\0') { cmd_ptr->sender_process_id = UtilStrDup(recordCmdSenderProcID); if (cmd_ptr->sender_process_id == NULL) FailAllocMessage(); } cmd_ptr->first_redo_after_deserialize = TRUE; cmd_ptr->skipped = FALSE; #ifdef _TGIF_DBG_WB2 DebugDumpCmd("<<< In DeserializeCmd()", cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); #endif /* _TGIF_DBG_WB2 */ if (saved_top_obj != NULL) { SelectObjects(saved_top_obj, saved_bot_obj); CopySel(topSel, numObjSelected, &(cmd_ptr->top_after), &(cmd_ptr->bot_after)); cmd_ptr->pos_after = gpnAfterPositions; cmd_ptr->count_after = gnAfterPositionsCount; RemoveAllSel(); } else { cmd_ptr->top_after = cmd_ptr->bot_after = NULL; cmd_ptr->pos_after = NULL; cmd_ptr->count_after = 0; } gppszBeforeImage = NULL; gnBeforeImageCount = 0; gpnAfterPositions = NULL; gnAfterPositionsCount = 0; } /* * Move this to the end of ProcessRemoteCmd() because we may need * some information from gpDeserializeSubCmd. * * DeserializationCleanUp(); */ #ifdef _TGIF_DBG_WB2 PrintFullIDsOfObjects("At the end of DeserializeCmd()"); #endif /* _TGIF_DBG_WB2 */ if (need_to_free_buf) UtilFree(psz_buf); return cmd_ptr; } static int TotalOrderForTwo(older_cmd, newer_cmd) struct CmdRec *older_cmd, *newer_cmd; /* * Note: If logical clocks and host names are the same, and if pid in * older_cmd is less than pid in newer_cmd, will return TRUE! */ { int comparison=0; if (older_cmd == NULL || newer_cmd == NULL) return TRUE; if (older_cmd->logical_clock > newer_cmd->logical_clock) { return FALSE; } else if (older_cmd->logical_clock < newer_cmd->logical_clock) { return TRUE; } comparison = strcmp(older_cmd->sender_process_id, newer_cmd->sender_process_id); TgAssert(comparison != 0, "Identical logical clock detected in TotalOrderForTwo()", NULL); return (comparison < 0); } #ifdef _TGIF_DBG_WB2 static void DumpCmdStack(prefix_string) char *prefix_string; /* Dump the command stack, last one first */ { struct CmdRec *cmd_ptr=NULL; if (prefix_string != NULL) fprintf(stderr, "%s\n", prefix_string); for (cmd_ptr=gstWBInfo.last_cmd; cmd_ptr != NULL; cmd_ptr=cmd_ptr->prev) { char buf[256]; if (cmd_ptr->skipped) { sprintf(buf, "\tcmd_ptr->next = 0x%08lx, (SKIPPED)", (long)cmd_ptr->next); } else { sprintf(buf, "\tcmd_ptr->next = 0x%08lx", (long)cmd_ptr->next); } DebugDumpCmd(buf, cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); } } #endif /* _TGIF_DBG_WB2 */ void FindCmdInsertionPoint(cmd_to_insert, pp_immed_right_cmd) struct CmdRec *cmd_to_insert, **pp_immed_right_cmd; /* * On return, cmd_to_insert is to be inserted immediately to the left * of *pp_immed_right_cmd. */ { struct CmdRec *cmd_ptr=NULL; for (cmd_ptr=gstWBInfo.last_cmd; cmd_ptr != NULL; cmd_ptr=cmd_ptr->prev) { if (TotalOrderForTwo(cmd_ptr, cmd_to_insert)) { *pp_immed_right_cmd = cmd_ptr->next; return; } } *pp_immed_right_cmd = gstWBInfo.first_cmd; } void FindShadowCmdInsertionPoint(cmd_to_insert, pp_immed_right_cmd) struct CmdRec *cmd_to_insert, **pp_immed_right_cmd; /* * On return, cmd_to_insert is to be inserted immediately to the left * of *pp_immed_right_cmd. */ { struct CmdRec *cmd_ptr=NULL; for (cmd_ptr=gstWBInfo.last_shadow_cmd; cmd_ptr != NULL; cmd_ptr=cmd_ptr->prev) { if (TotalOrderForTwo(cmd_ptr, cmd_to_insert)) { *pp_immed_right_cmd = cmd_ptr->next; return; } } *pp_immed_right_cmd = gstWBInfo.first_shadow_cmd; } static void HighLightExistingObjects() /* * If select object no longer exists, don't select and highlight it! */ { int something_deleted=FALSE; struct SelRec *sel_ptr=NULL, *next_sel=NULL; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; if (!IsTopLevelObject(sel_ptr->obj)) { UnlinkSel(sel_ptr, &topSel, &botSel); free(sel_ptr); something_deleted = TRUE; } } if (something_deleted) UpdSelBBox(); HighLightForward(); } void CleanUpObsoletedWBCmds(stopped_cmd_ptr) struct CmdRec *stopped_cmd_ptr; { struct CmdRec *cmd_ptr=NULL; int num_records=0; for (cmd_ptr=stopped_cmd_ptr->prev; cmd_ptr != NULL; cmd_ptr=cmd_ptr->prev) { num_records++; } if (num_records > 0) { struct CmdRec *prev_cmd=NULL; double inc=(100.0/((double)num_records)), percent_start=0.0; ShowInterrupt(1); SaveStatusStrings(); for (cmd_ptr=stopped_cmd_ptr->prev; cmd_ptr != NULL; cmd_ptr=prev_cmd, percent_start+=inc) { prev_cmd = cmd_ptr->prev; DeleteARedoRecord(cmd_ptr, percent_start, min(((double)percent_start+inc),((double)100.0))); } RestoreStatusStrings(); HideInterrupt(); } gstWBInfo.first_cmd = stopped_cmd_ptr; gstWBInfo.first_cmd->prev = NULL; CleanUpWBShadowCmds(); } static void HandleChatLine(cmd_ptr) struct CmdRec *cmd_ptr; { struct ChatSubCmdRec *pChatSubCmdInfo=(&gpDeserializeSubCmd->detail.chat); switch (pChatSubCmdInfo->type) { case CHAT_STATE_NORMAL: ChatAppendChatLine(&pChatSubCmdInfo->tfi, pChatSubCmdInfo->nick_name, pChatSubCmdInfo->encoding, pChatSubCmdInfo->buf); break; case CHAT_STATE_HELLO: break; case CHAT_STATE_DISCONNECT: /* handle explicit user disconnect */ break; } /* * Handle the chat line... */ DeleteARedoRecord(cmd_ptr, 0, 0); gstWBInfo.cur_cmd = NULL; } void ProcessRemoteCmd(psz_content_type, psz_buf, buf_sz) char *psz_content_type, *psz_buf; int buf_sz; { struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; struct CmdRec *cmd_ptr=NULL; char *psz_plain_buf=NULL; int highlighted_before=FALSE, plain_buf_sz=0; if (topSel != NULL) { highlighted_before = TRUE; HighLightReverse(); topSel = botSel = NULL; } gstWBInfo.cur_cmd = DeserializeCmd(psz_content_type, psz_buf, buf_sz, &psz_plain_buf, &plain_buf_sz); if (gstWBInfo.cur_cmd != NULL) { struct CmdRec *immed_right_cmd=NULL; int cur_cmd_is_wb_clearall=(gstWBInfo.cur_cmd->type == CMD_WB_CLEARALL); if (gstWBInfo.cur_cmd->type == CMD_CHAT_A_LINE) { HandleChatLine(gstWBInfo.cur_cmd); /* * May be we need to allocate subcmd pointer here. */ } else { if (gstWBInfo.cur_cmd->type == CMD_MOVE) { gstWBInfo.cur_cmd->subcmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (gstWBInfo.cur_cmd->subcmd == NULL) FailAllocMessage(); memset(gstWBInfo.cur_cmd->subcmd, 0, sizeof(struct SubCmdRec)); gstWBInfo.cur_cmd->subcmd->detail.move.dx = gpDeserializeSubCmd->detail.move.dx; gstWBInfo.cur_cmd->subcmd->detail.move.dy = gpDeserializeSubCmd->detail.move.dy; } else if (gstWBInfo.cur_cmd->type == CMD_WB_SLIDESHOW) { gstWBInfo.cur_cmd->subcmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (gstWBInfo.cur_cmd->subcmd == NULL) FailAllocMessage(); memset(gstWBInfo.cur_cmd->subcmd, 0, sizeof(struct SubCmdRec)); gstWBInfo.cur_cmd->subcmd->detail.slideshow.into_slideshow = gpDeserializeSubCmd->detail.slideshow.into_slideshow; } #ifdef _TGIF_DBG_WB2 DumpCmdStack("Before FindCmdInsertionPoint()"); #endif /* _TGIF_DBG_WB2 */ /* * FindShadowCmdInsertionPoint() examine the logical clock of the new * command and decides where to insert it in the shadow cmd list. */ FindShadowCmdInsertionPoint(gstWBInfo.cur_cmd, &immed_right_cmd); if (immed_right_cmd == NULL) { /* append */ CopyAndInsertCmd(TRUE, (psz_plain_buf==NULL ? psz_buf : psz_plain_buf), gstWBInfo.last_shadow_cmd, NULL, gstWBInfo.cur_cmd, &gstWBInfo.first_shadow_cmd, &gstWBInfo.last_shadow_cmd); } else { /* insert */ CopyAndInsertCmd(TRUE, (psz_plain_buf==NULL ? psz_buf : psz_plain_buf), immed_right_cmd->prev, immed_right_cmd, gstWBInfo.cur_cmd, &gstWBInfo.first_shadow_cmd, &gstWBInfo.last_shadow_cmd); } immed_right_cmd = NULL; /* * FindCmdInsertionPoint() examine the logical clock of the new command * and decides where to insert it. */ FindCmdInsertionPoint(gstWBInfo.cur_cmd, &immed_right_cmd); if (immed_right_cmd == NULL) { /* append */ InsertCmd(gstWBInfo.last_cmd, NULL, gstWBInfo.cur_cmd, &gstWBInfo.first_cmd, &gstWBInfo.last_cmd); } else { /* insert */ InsertCmd(immed_right_cmd->prev, immed_right_cmd, gstWBInfo.cur_cmd, &gstWBInfo.first_cmd, &gstWBInfo.last_cmd); } #ifdef _TGIF_DBG_WB2 DumpCmdStack("After FindCmdInsertionPoint()"); #endif /* _TGIF_DBG_WB2 */ if (immed_right_cmd != NULL) { /* * Undo all the commands to the right of gstWBInfo.cur_cmd. * Do not perform the undo if the command is skipped. */ for (cmd_ptr=gstWBInfo.last_cmd; cmd_ptr != gstWBInfo.cur_cmd && cmd_ptr->type != CMD_WB_CLEARALL; cmd_ptr=cmd_ptr->prev) { if (cmd_ptr->skipped) { #ifdef _TGIF_DBG_WB2 strcpy(gszMsgBox, "*** No need to UndoACmd()"); DebugDumpCmd(gszMsgBox, cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); #endif /* _TGIF_DBG_WB2 */ cmd_ptr->skipped = FALSE; } else { #ifdef _TGIF_DBG_WB2 strcpy(gszMsgBox, "*** Just before UndoACmd()"); DebugDumpCmd(gszMsgBox, cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); PrintFullIDsOfObjects("\t"); #endif /* _TGIF_DBG_WB2 */ UndoACmd(cmd_ptr, FALSE, TRUE); #ifdef _TGIF_DBG_WB2 DebugDumpCmd("*** After UndoACmd()", cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); PrintFullIDsOfObjects("\t"); #endif /* _TGIF_DBG_WB2 */ if (topSel != NULL) RemoveAllSel(); } } if (cmd_ptr != gstWBInfo.cur_cmd) { gstWBInfo.cur_cmd = cmd_ptr; } } /* * Redo all the commands starting from gstWBInfo.cur_cmd. */ if (gstWBInfo.cur_cmd->type == CMD_WB_CLEARALL) { CleanUpObsoletedWBCmds(gstWBInfo.cur_cmd); if (cur_cmd_is_wb_clearall) { struct ClearAllSubCmdRec *clearall= &gpDeserializeSubCmd->detail.clearall; CleanUpDrawingWindow(); ClearFileInfo(TRUE); SetFileModified(FALSE); ClearAndRedrawDrawWindow(); CheckFileAttrsInLoad(); Msg("WhiteBoard cleared by peer."); DelAllPages(); lastPageNum = 1; InitPage(); ShowPage(); if (!(pageStyle == clearall->page_style && fabs(printMag-clearall->print_mag) < INT_TOL)) { pageStyle = clearall->page_style; printMag = clearall->print_mag; UpdPageStyle(pageStyle); UpdDrawWinWH(); RedrawScrollBars(); UpdDrawWinBBox(); SetDefaultDrawWinClipRecs(); DrawPaperBoundary(drawWindow); RedrawGridLines(drawWindow); RedrawPageLines(drawWindow); RedrawRulers(); RedrawChoiceWindow(); RedrawTitleWindow(); } } } for (cmd_ptr=gstWBInfo.cur_cmd; cmd_ptr != NULL; cmd_ptr=cmd_ptr->next) { #ifdef _TGIF_DBG_WB2 DebugDumpCmd("--- Just before RedoACmd()", cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); PrintFullIDsOfObjects("\t"); #endif /* _TGIF_DBG_WB2 */ if (!RedoACmd(cmd_ptr, FALSE, TRUE)) { cmd_ptr->skipped = TRUE; #ifdef _TGIF_DBG_WB2 DebugDumpCmd("=== Skip RedoACmd()", cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); PrintFullIDsOfObjects("\t"); #endif /* _TGIF_DBG_WB2 */ } else { #ifdef NOT_DEFINED /* insanity check! */ fprintf(stderr, "Sanity check: %s\n", "need to comment this before distributing the code!"); if (topSel != NULL) RemoveAllSel(); UndoACmd(cmd_ptr, FALSE, TRUE); if (topSel != NULL) RemoveAllSel(); if (!RedoACmd(cmd_ptr, FALSE, TRUE)) { fprintf(stderr, "\7\7\7Oh no!!! RedoACmd() failed!\n"); } #endif /* NOT_DEFINED */ #ifdef _TGIF_DBG_WB2 DebugDumpCmd("--- Just after RedoACmd()", cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); PrintFullIDsOfObjects("\t"); #endif /* _TGIF_DBG_WB2 */ if (topSel != NULL) RemoveAllSel(); } } #ifdef _TGIF_DBG_WB2 PrintFullIDsOfObjects("At end of ProcessRemoteCmd()"); fprintf(stderr, "%s%s\n", "========================================", "========================================"); #endif /* _TGIF_DBG_WB2 */ } } DeserializationCleanUp(); ResetDeserializeCmd(); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); if (highlighted_before) { HighLightExistingObjects(); } UtilFree(psz_plain_buf); } /* =================== Pack and Unpack current state Functions ======= */ static void PackCurrentTGWBState(p_cur_state) CurStatus *p_cur_state; { char tmp_fname[MAXPATHLENGTH], *buf=NULL, header[MAXSTRING<<1]; char gz_tmp_fname[MAXPATHLENGTH]; int content_sz=0, ok=TRUE, header_sz=0, num_cmds=0, cur_cmd_pos=0; int do_deflate=TRUE; struct CmdRec *cmd_ptr=NULL; long loc_sec=0L, loc_msec=0L; FILE *fp=NULL, *gz_fp=NULL; if (HasZlibSupport()) { #ifdef _TGIF_DBG_WB2 do_deflate = FALSE; #endif /* _TGIF_DBG_WB2 */ } else { do_deflate = FALSE; } memset(p_cur_state, 0, sizeof(CurStatus)); if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { fprintf(stderr, TgLoadString(STID_CANT_CREATE_NAMED_TMP_FILE), tmp_fname); fprintf(stderr, "\n"); return; } snprintf(gz_tmp_fname, sizeof(gz_tmp_fname), "%s.z", tmp_fname); if ((fp=fopen(tmp_fname, "w+")) == NULL) { FailToOpenMessage(tmp_fname, "w", NULL); return; } if ((gz_fp=fopen(gz_tmp_fname, "w+")) == NULL) { FailToOpenMessage(gz_tmp_fname, "w", NULL); fclose(fp); unlink(tmp_fname); return; } writeFileFailed = FALSE; UtilGetMilliSecTime(&loc_sec, &loc_msec); if (fprintf(fp, "%%TGWB begin packing - %ld.%ld\n", loc_sec, loc_msec) == EOF) { writeFileFailed = TRUE; } for (cmd_ptr=gstWBInfo.first_shadow_cmd; cmd_ptr != NULL; cmd_ptr=cmd_ptr->next) { SerializationInfo si; memset(&si, 0, sizeof(SerializationInfo)); PrepareExtendedSerializationInfo(cmd_ptr, &si); if (SaveExtendedCmd(fp, cmd_ptr, &si)) { if (cmd_ptr == gstWBInfo.cur_cmd) { cur_cmd_pos = num_cmds; } num_cmds++; } } ok = SaveExtendedCmdInfo(fp, num_cmds, cur_cmd_pos); if (fprintf(fp, "%%TGWB end - %ld.%ld\n", loc_sec, loc_msec) == EOF) { writeFileFailed = TRUE; } if (writeFileFailed) { FailToWriteFileMessage(tmp_fname); fclose(fp); unlink(tmp_fname); fclose(gz_fp); unlink(gz_tmp_fname); return; } if (!ok) { fclose(fp); unlink(tmp_fname); fclose(gz_fp); unlink(gz_tmp_fname); return; } fflush(fp); content_sz = (int)ftell(fp); /* * From: <PID>:<IP>\r\n * Content-Type: application/x-tgif-cmd\r\n * Content-Length: <LENGTH>\r\n * \r\n * <DATA of size LENGTH> */ if (do_deflate && HasZlibSupport()) { int rc=0; if (!DoDeflate(fp, NULL, content_sz, gz_fp, TRUE, TRUE, &rc)) { ZlibError(rc, TRUE); do_deflate = FALSE; } else { content_sz = (int)ftell(gz_fp); } } if (do_deflate) { sprintf(header, "%s%s\r\n%s%s\r\n%s%1d\r\n\r\n", "From: ", gszLocalPID, "Content-Type: ", "application/x-tgif-cmd-z", "Content-Length: ", content_sz); header_sz = strlen(header); buf = (char*)malloc((header_sz+content_sz+1)*sizeof(char)); if (buf == NULL) FailAllocMessage(); strcpy(buf, header); rewind(gz_fp); if (fread(&buf[header_sz], sizeof(char), content_sz, gz_fp) != content_sz) { sprintf(gszMsgBox, "Error in reading '%s'.\n\nPackCurrentTGWBState() aborted.", gz_tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); UtilFree(buf); fclose(fp); unlink(tmp_fname); fclose(gz_fp); unlink(gz_tmp_fname); return; } } else { sprintf(header, "%s%s\r\n%s%s\r\n%s%1d\r\n\r\n", "From: ", gszLocalPID, "Content-Type: ", "application/x-tgif-cmd", "Content-Length: ", content_sz); header_sz = strlen(header); buf = (char*)malloc((header_sz+content_sz+1)*sizeof(char)); if (buf == NULL) FailAllocMessage(); strcpy(buf, header); rewind(fp); if (fread(&buf[header_sz], sizeof(char), content_sz, fp) != content_sz) { sprintf(gszMsgBox, "Error in reading '%s'.\n\nPackCurrentTGWBState() aborted.", tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); UtilFree(buf); fclose(fp); unlink(tmp_fname); fclose(gz_fp); unlink(gz_tmp_fname); return; } } buf[header_sz+content_sz] = '\0'; #ifdef _TGIF_DBG_WB2 if (wb2DebugLevel == 0) { fprintf(stderr, "Sending %1d bytes, pid = %ld!\n", header_sz+content_sz+2, gstWBInfo.pid); } else { fprintf(stderr, "---------------------------\n"); if (do_deflate) { fprintf(stderr, "%s", header); fprintf(stderr, "[content not displayed] ...\n"); } else { fprintf(stderr, "%s\n", buf); } fprintf(stderr, "---------------------------\n"); fprintf(stderr, "Sent %1d bytes, pid = %ld!\n", header_sz+content_sz+2, gstWBInfo.pid); } DebugDumpCmd(">>> In PackCurrentTGWBState()", (-1), (-1), gszLocalPID); PrintFullIDsOfObjects("In PackCurrentTGWBState()"); #endif /* _TGIF_DBG_WB2 */ fclose(fp); unlink(tmp_fname); fclose(gz_fp); unlink(gz_tmp_fname); /* It is important to include the terminating '\0' */ p_cur_state->data = buf; p_cur_state->size = header_sz+content_sz+1; } static int CheckUnpackState(read_status) int read_status; { int ok=TRUE; if (read_status == INVALID) { sprintf(gszMsgBox, "File version too large (=%1d). %s!", fileVersion, "UnpackCurrentTGWBState() aborted"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else { #ifdef _TGIF_DBG_WB2 fprintf(stderr, "%s, pid = %ld, timestamp = %1d/%s\n", "Command successfully parsed", gstWBInfo.pid, recordCmdLogicalClock, recordCmdSenderProcID); #endif /* _TGIF_DBG_WB2 */ if (recordCmdLogicalClock+1 > gstWBInfo.logical_clock) { /* Lamport's Algorithm set logical_clock */ gstWBInfo.logical_clock = recordCmdLogicalClock+1; #ifdef _TGIF_DBG_WB2 fprintf(stderr, "Logical clock for pid = %ld set to %1d.\n", gstWBInfo.pid, gstWBInfo.logical_clock); #endif /* _TGIF_DBG_WB2 */ } } return ok; } static struct CmdRec *CreateCmdFromSerializedData(saved_top_obj, saved_bot_obj) struct ObjRec *saved_top_obj, *saved_bot_obj; { struct CmdRec *cmd_ptr=(struct CmdRec *)malloc(sizeof(struct CmdRec)); if (cmd_ptr == NULL) FailAllocMessage(); memset(cmd_ptr, 0, sizeof(struct CmdRec)); cmd_ptr->serialized = TRUE; /* created from deserialization */ cmd_ptr->top_before = cmd_ptr->bot_before = NULL; cmd_ptr->pos_before = (int*)gppszBeforeImage; cmd_ptr->count_before = gnBeforeImageCount; cmd_ptr->type = gstDeserializeCmd.type; cmd_ptr->undone = TRUE; cmd_ptr->include_tgif_obj = recordCmdIncludeTgifObj; cmd_ptr->new_colormap = recordCmdUsesNewColormap; cmd_ptr->logical_clock = recordCmdLogicalClock; if (*recordCmdSenderProcID != '\0') { cmd_ptr->sender_process_id = UtilStrDup(recordCmdSenderProcID); if (cmd_ptr->sender_process_id == NULL) FailAllocMessage(); } else { fprintf(stderr, "Missing sender_process_id in CreateCmdFromSerializedData().\n"); } cmd_ptr->first_redo_after_deserialize = TRUE; cmd_ptr->skipped = FALSE; #ifdef _TGIF_DBG_WB2 DebugDumpCmd("<<< In CreateCmdFromSerializedData()", cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); #endif /* _TGIF_DBG_WB2 */ if (saved_top_obj != NULL) { SelectObjects(saved_top_obj, saved_bot_obj); CopySel(topSel, numObjSelected, &(cmd_ptr->top_after), &(cmd_ptr->bot_after)); cmd_ptr->pos_after = gpnAfterPositions; cmd_ptr->count_after = gnAfterPositionsCount; RemoveAllSel(); } else { cmd_ptr->top_after = cmd_ptr->bot_after = NULL; cmd_ptr->pos_after = NULL; cmd_ptr->count_after = 0; } gppszBeforeImage = NULL; gnBeforeImageCount = 0; gpnAfterPositions = NULL; gnAfterPositionsCount = 0; return cmd_ptr; } static int GetContentInfoFromBuf(buf, content_type_buf, content_type_buf_sz, pn_content_length, ppsz_buf_data_start) char *buf, *content_type_buf, **ppsz_buf_data_start; int content_type_buf_sz, *pn_content_length; { char *psz_start=buf, *psz=NULL; char *content_type_prefix="Content-Type: "; char *content_len_prefix="Content-Length: "; int content_type_prefix_len=strlen(content_type_prefix); int content_len_prefix_len=strlen(content_len_prefix); int found_content_type=FALSE, found_content_len=FALSE; psz = strstr(psz_start, "\r\n"); while (psz != NULL) { *psz = '\0'; if (*psz_start == '\0') { *psz = '\r'; psz_start = &psz[2]; if (ppsz_buf_data_start != NULL) *ppsz_buf_data_start = psz_start; return (found_content_type && found_content_len); } else if (UtilStrNCaseCmp(psz_start, content_type_prefix, content_type_prefix_len) == 0) { UtilStrCpyN(content_type_buf, content_type_buf_sz, &psz_start[content_type_prefix_len]); UtilTrimBlanks(content_type_buf); found_content_type = TRUE; } else if (UtilStrNCaseCmp(psz_start, content_len_prefix, content_len_prefix_len) == 0) { char buf2[80]; int ival=0; UtilStrCpyN(buf2, sizeof(buf2), &psz_start[content_len_prefix_len]); UtilTrimBlanks(buf2); if (sscanf(buf2, "%d", &ival) == 1) { if (pn_content_length != NULL) *pn_content_length = ival; found_content_len = TRUE; } } *psz = '\r'; psz_start = &psz[2]; psz = strstr(psz_start, "\r\n"); } return FALSE; } static int ReadPastWrapper(fp, pn_file_pos) FILE *fp; int *pn_file_pos; { char *buf=NULL; char *psz_looking_for="%TGWB begin packing - "; int len=strlen(psz_looking_for); while ((buf=UtilGetALine(fp)) != NULL) { if (strncmp(buf, psz_looking_for, len) == 0) { if (pn_file_pos != NULL) *pn_file_pos = (int)ftell(fp); UtilFree(buf); return TRUE; } UtilFree(buf); } return FALSE; } static int ReadPastHeader(fp, pn_file_pos) FILE *fp; int *pn_file_pos; /* * The From, Content-Type, Content-Length header is optional. So, * need to handle the case where there is a header and the case * where there is none. */ { char *psz_looking_for="%TGWB begin - "; int len=strlen(psz_looking_for); int cur_pos=(int)ftell(fp); char *buf=NULL; while ((buf=UtilGetALine(fp)) != NULL) { char obj_name[80]; *obj_name = '\0'; UtilTrimBlanks(buf); if (*buf == '\0') { if (pn_file_pos != NULL) *pn_file_pos = (int)ftell(fp); UtilFree(buf); return TRUE; } else if (strncmp(buf, psz_looking_for, len) == 0) { if (pn_file_pos != NULL) *pn_file_pos = cur_pos; UtilFree(buf); return TRUE; } else if (*buf == ']' || *buf == '%') { fprintf(stderr, "Unexpected line (start with '%c' read in ReadPastHeader().\n", *buf); UtilFree(buf); return FALSE; } else if (ParseStr(buf, (int)'(', obj_name, sizeof(obj_name)) == NULL) { /* it's probably okay */ } else if (strcmp(obj_name, "cmdxinfo") == 0) { int ok=ReadExtendedCmdInfo(fp, buf); UtilFree(buf); return ok; } UtilFree(buf); cur_pos = (int)ftell(fp); } return FALSE; } static int ReadAheadOverACmd(fp, pn_file_pos) FILE *fp; int *pn_file_pos; { char *buf=NULL; char *psz_looking_for="%TGWB end - "; int len=strlen(psz_looking_for); while ((buf=UtilGetALine(fp)) != NULL) { if (strncmp(buf, psz_looking_for, len) == 0) { if (pn_file_pos != NULL) *pn_file_pos = (int)ftell(fp); UtilFree(buf); return TRUE; } UtilFree(buf); } return FALSE; } static char *ReReadCmd(fp, start_file_pos, end_file_pos, pn_buf_len) FILE *fp; int start_file_pos, end_file_pos, *pn_buf_len; { char *buf=NULL; int ok=TRUE, buf_len=end_file_pos-start_file_pos; if (end_file_pos > start_file_pos) { buf_len = end_file_pos-start_file_pos; if (fseek(fp, start_file_pos, SEEK_SET) != 0) { fprintf(stderr, "Seek to %1d failed in UnpackCurrentTGWBState().\n", start_file_pos); ok = FALSE; } else { buf = (char*)malloc(buf_len+1); if (buf == NULL) FailAllocMessage(); buf[buf_len] = '\0'; if (buf_len != (int)fread(buf, sizeof(char), buf_len, fp)) { fprintf(stderr, "Reading %1d bytes failed in %s.\n", buf_len, "UnpackCurrentTGWBState()"); ok = FALSE; } } if (ok && fseek(fp, start_file_pos, SEEK_SET) != 0) { fprintf(stderr, "Seek to %1d failed in UnpackCurrentTGWBState().\n", start_file_pos); ok = FALSE; } } else { fprintf(stderr, "Invalid (empty) cmd detected in UnpackCurrentTGWBState().\n"); ok = FALSE; } if (!ok) { UtilFree(buf); return NULL; } if (pn_buf_len != NULL) *pn_buf_len = buf_len; return buf; } static void UnpackCurrentTGWBState(p_cur_state) CurStatus *p_cur_state; { struct StkRec *stk_ptr=NULL; struct ObjRec *obj_ptr=NULL, *saved_top_obj=NULL, *saved_bot_obj=NULL; int read_status=TRUE, ok=TRUE, start_file_pos=0, end_file_pos=0; int content_length=0, do_inflate=FALSE, need_to_free_buf=FALSE; char *buf=p_cur_state->data, tmp_fname[MAXPATHLENGTH], content_type[80]; char *buf_data_start=NULL; FILE *fp=NULL; struct CmdRec *cmd_ptr=NULL; *content_type = '\0'; if (!GetContentInfoFromBuf(buf, content_type, sizeof(content_type), &content_length, &buf_data_start)) { sprintf(gszMsgBox, TgLoadString(STID_JOIN_WB_IN_FAILED_NO_CONTTYPE)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (strcmp(content_type, "application/x-tgif-cmd-z") == 0) { if (!HasZlibSupport()) { sprintf(gszMsgBox, "%s %s.\n\nDeserialization aborted in %s.", TOOL_NAME, "is not compiled with ZLIB and cannot inflate()", "UnpackCurrentTGWBState()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } else { if (gstWBInfo.gz_listen_fp == NULL) { sprintf(gszMsgBox, "Cannot open '%s'.\n\n%s pid=%ld in %s.", gstWBInfo.gz_listen_fname, "Deserialization aborted for", gstWBInfo.pid, "UnpackCurrentTGWBState()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } do_inflate = TRUE; } } if (do_inflate && HasZlibSupport()) { int rc=0, buf_sz=0; if (!DoInflate(buf_data_start, content_length, gstWBInfo.gz_listen_fp, TRUE, &rc)) { ZlibError(rc, FALSE); return; } buf_sz = (int)ftell(gstWBInfo.gz_listen_fp); buf = (char*)malloc(buf_sz+1); if (buf == NULL) FailAllocMessage(); rewind(gstWBInfo.gz_listen_fp); if (fread(buf, sizeof(char), buf_sz, gstWBInfo.gz_listen_fp) != buf_sz) { sprintf(gszMsgBox, "Cannot read %1d bytes from '%s'.\n\n%s for %s.", buf_sz, gstWBInfo.gz_listen_fname, "Deserialization aborted", "UnpackCurrentTGWBState()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); UtilFree(buf); return; } need_to_free_buf = TRUE; } if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { fprintf(stderr, TgLoadString(STID_CANT_CREATE_NAMED_TMP_FILE), tmp_fname); fprintf(stderr, "\n"); if (need_to_free_buf) UtilFree(buf); return; } if ((fp=fopen(tmp_fname, "w+")) == NULL) { FailToOpenMessage(tmp_fname, "w", NULL); if (need_to_free_buf) UtilFree(buf); return; } writeFileFailed = FALSE; #ifdef _TGIF_DBG_WB2 if (wb2DebugLevel == 0) { fprintf(stderr, "Received %1d bytes, pid = %ld\n", strlen(buf), gstWBInfo.pid); } else { fprintf(stderr, "<<<========================\n"); fprintf(stderr, "%s\n", buf); fprintf(stderr, "<<<========================\n"); fprintf(stderr, "Received %1d bytes, pid = %ld\n", strlen(buf), gstWBInfo.pid); } PrintFullIDsOfObjects("At the beginning of UnpackCurrentTGWBState()"); #endif /* _TGIF_DBG_WB2 */ writeFileFailed = FALSE; if (fprintf(fp, "%s", buf) == EOF) { writeFileFailed = TRUE; } if (writeFileFailed) { FailToWriteFileMessage(gstWBInfo.listen_fname); fclose(fp); unlink(tmp_fname); if (need_to_free_buf) UtilFree(buf); return; } stk_ptr = SaveFileInfo(); ResetFileInfo(); /* if (usePaperSizeStoredInFile) ResetOnePageSize(); */ ResetDeserializeCmd(); rewind(fp); importingFile = TRUE; strcpy(scanFileName, gstWBInfo.listen_fname); scanLineNum = 0; foundGoodStateObject = FALSE; seenCmdXInfo = FALSE; *content_type = '\0'; ok = ReadPastWrapper(fp, NULL); while (ok && !seenCmdXInfo) { char *serialization_buf=NULL; int serialization_buf_len=0; DelAllPages(); lastPageNum = 1; InitPage(); readingPageNum = loadedCurPageNum = 0; ok = ReadPastHeader(fp, &start_file_pos); if (ok) { if (seenCmdXInfo) { break; } ok = ReadAheadOverACmd(fp, &end_file_pos); if (ok) { serialization_buf = ReReadCmd(fp, start_file_pos, end_file_pos, &serialization_buf_len); if (serialization_buf == NULL) { ok = FALSE; #ifdef _TGIF_DBG_WB2 } else { static int n=1; fprintf(stderr, "******* cmd %1d begin *******\n", n); fprintf(stderr, "%s", serialization_buf); fprintf(stderr, "******* cmd %1d end *******\n", n++); #endif /* _TGIF_DBG_WB2 */ } } } if (ok) { while ((read_status=ReadObj(fp, &obj_ptr)) == TRUE) { if (obj_ptr != NULL) { fprintf(stderr, "Unexpected objects read in UnpackCurrentTGWBState().\n"); } } ok = CheckUnpackState(read_status); if (!ok) { DelAllObj(); } else { saved_top_obj = topObj; saved_bot_obj = botObj; topObj = botObj = NULL; } DelAllPages(); lastPageNum = 0; InitPage(); } if (ok) { cmd_ptr = CreateCmdFromSerializedData(saved_top_obj, saved_bot_obj); if (cmd_ptr->type == CMD_MOVE) { cmd_ptr->subcmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (cmd_ptr->subcmd == NULL) FailAllocMessage(); memset(cmd_ptr->subcmd, 0, sizeof(struct SubCmdRec)); cmd_ptr->subcmd->detail.move.dx = gpDeserializeSubCmd->detail.move.dx; cmd_ptr->subcmd->detail.move.dy = gpDeserializeSubCmd->detail.move.dy; } else if (cmd_ptr->type == CMD_WB_SLIDESHOW) { cmd_ptr->subcmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (cmd_ptr->subcmd == NULL) FailAllocMessage(); memset(cmd_ptr->subcmd, 0, sizeof(struct SubCmdRec)); cmd_ptr->subcmd->detail.slideshow.into_slideshow = gpDeserializeSubCmd->detail.slideshow.into_slideshow; } if (cmd_ptr != NULL) { /* append */ CopyAndInsertCmd(TRUE, serialization_buf, gstWBInfo.last_shadow_cmd, NULL, cmd_ptr, &gstWBInfo.first_shadow_cmd, &gstWBInfo.last_shadow_cmd); InsertCmd(gstWBInfo.last_cmd, NULL, cmd_ptr, &gstWBInfo.first_cmd, &gstWBInfo.last_cmd); } } #ifdef _TGIF_DBG_WB2 PrintFullIDsOfObjects("In UnpackCurrentTGWBState()"); #endif /* _TGIF_DBG_WB2 */ DeserializationCleanUp(); ResetDeserializeCmd(); } importingFile = FALSE; fclose(fp); unlink(tmp_fname); RestoreFileInfo(stk_ptr); ResetOnePageSize(); free(stk_ptr); UpdPageStyle(pageStyle); /* * Now execute the commands! */ if (ok) { gstWBInfo.cur_cmd = NULL; for (cmd_ptr=gstWBInfo.first_cmd; cmd_ptr != NULL; cmd_ptr=cmd_ptr->next) { #ifdef _TGIF_DBG_WB2 DebugDumpCmd("--- Just before RedoACmd()", cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); PrintFullIDsOfObjects("\t"); #endif /* _TGIF_DBG_WB2 */ if (!RedoACmd(cmd_ptr, FALSE, TRUE)) { cmd_ptr->skipped = TRUE; #ifdef _TGIF_DBG_WB2 DebugDumpCmd("=== Skip RedoACmd()", cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); PrintFullIDsOfObjects("\t"); #endif /* _TGIF_DBG_WB2 */ gstWBInfo.cur_cmd = cmd_ptr; break; } else { #ifdef _TGIF_DBG_WB2 DebugDumpCmd("--- Just after RedoACmd()", cmd_ptr->type, cmd_ptr->logical_clock, cmd_ptr->sender_process_id); PrintFullIDsOfObjects("\t"); #endif /* _TGIF_DBG_WB2 */ if (topSel != NULL) RemoveAllSel(); } } gstWBInfo.join_session_in_progress = TRUE; } else { CleanUpWBCmds(); sprintf(gszMsgBox, TgLoadString(STID_JOIN_WB_IN_PROGRESS_FAILED)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } if (need_to_free_buf) UtilFree(buf); } void HandleNewUserRequest() { char buf[80]; int buf_sz=sizeof(buf); /* * Get current tgwb state and establish * a TCP conection to send the data. */ int index=0; if (!gstWBInfo.do_whiteboard) { return; } for (index=0; index < buf_sz-1; index++) { if (read(talkToSelfFiledes[0], &buf[index], 1) != 1) { sprintf(gszMsgBox, TgLoadString(STID_READ_FROM_SELF_PIPE_FAIL), 1, TOOL_NAME), fprintf(stderr, "%s\n", gszMsgBox); index = (-1); break; } else if (buf[index] == '\0') { break; } } if (index == buf_sz-1) { sprintf(gszMsgBox, TgLoadString(STID_READ_FROM_SELF_PIPE_OVERFLOW), TOOL_NAME), fprintf(stderr, "%s\n", gszMsgBox); index = (-1); } if (index != (-1)) { int conn=0; CurStatus cur_state; memset(&cur_state, 0, sizeof(CurStatus)); sscanf(buf, "%d", &conn); serializingFile = TRUE; PackCurrentTGWBState(&cur_state); serializingFile = FALSE; if (cur_state.size != 0) { RM_sendCurStatus(conn, (char*)cur_state.data, cur_state.size); UtilFree(cur_state.data); } } } /* =================== SIGPOLL Handler function =================== */ /* #define DEBUG0 */ #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) static void *ReceivePacket( void *arg ) { while( 1 ) { char *buf=NULL, *aux=NULL, id[300]; int byread=0; struct SegmentationPack pack1; if( (byread = RM_recv(gstWBInfo.MCastSock, (char*) &pack1, sizeof(struct SegmentationPack))) > 0 ) { char *buffer1=NULL; #ifdef DEBUG0 fprintf(stdout, "__________# of received packet: %u of %u\n", ntohl(pack1.NumSeq), ntohl(pack1.NumPackets)); #endif if( (buffer1 = DeSegment( pack1, &byread )) != NULL ){ buf = (char *)malloc( byread + 1 ); memcpy( buf, buffer1, byread ); buf[byread]= '\0'; free(buffer1); #ifdef DEBUG0 fprintf(stdout, "******Desegmentation OK\n"); #endif } else { continue; } } else if (byread == 0) { continue; } else { /* on error, break - no more messages to receive (shutting down) */ break; } /* * check if the message is from itself */ if (strncmp(buf, "From: ", 6) != 0 || sscanf(&buf[6], "%s\r\n", id) != 1) { fprintf(stderr, "%s. %s, pid = %ld=tid=%s.\nbuf=%s.\n", "Fatal error", "Cannot find the sender id in IO_SignalHandler()", gstWBInfo.pid, id, buf); free(buf); continue; } if(strcmp(id, gszLocalPID) == 0) { continue; } #ifdef DEBUG0 /* Verify if either the command may be processed right now, or if it should be stored */ fprintf(stderr,"Process the comand now? "); #endif if ((aux = (char *)malloc( byread + 1 )) == NULL) { fprintf(stderr,"Allocation error. (ReceivePacket)\n"); exit(1); } strncpy(aux, buf, byread); aux[byread] = (char)0; buff_ins(gstWBInfo.bd_commands, aux); free(aux); free(buf); /* * Don't think we need this any more! * * if(gstWBInfo.BlockRemoteCmdDepth > 0) { #ifdef DEBUG * buff_show(gstWBInfo.bd_commands); #endif * continue; * } * else */ { static char c='a'; if (write(talkToSelfFiledes[1], &c, 1) != 1) { sprintf(gszMsgBox, TgLoadString(STID_WRITE_TO_SELF_PIPE_FAIL), TOOL_NAME); fprintf(stderr, "%s\n", gszMsgBox); } } } return( NULL ); } #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ /* =================== Init and CleanUp Functions =================== */ void CleanUpWhiteBoard() { int i=0; if (!gstWBInfo.do_whiteboard) { return; } snprintf(gszMsgBox, sizeof(gszMsgBox), "****%s**** ", TgLoadString(STID_SHUTTING_DOWN_WHITEBOARD)); Msg(gszMsgBox); RM_leaveGroup( gstWBInfo.MCastSock, (char*)RM_USE_CURRENT_CONFIG ); fprintf(stderr, "%s ", gszMsgBox); for (i=0; i < 10; i++) { fprintf(stderr, "."); MillisecondSleep(100); } fprintf(stderr, "\n"); RMCastCleanUp(); buff_destroy(gstWBInfo.bd_commands); CleanUpWBSockets(); CleanUpWBCmds(); memset(&gstWBInfo, 0, sizeof(struct WhiteBoardRec)); CleanUpDeserializeCmd(); buff_cleanup(); } void handler(int a) { fprintf(stderr,"alarm catched in wb.c\n"); exit(1); } int InitWhiteBoard() { InitLocalPID(); /* initializes gszLocalPID */ memset(&gstWBInfo, 0, sizeof(struct WhiteBoardRec)); gstWBInfo.BlockRemoteCmdDepth = 1; /* FIXME Should be zero? */ gstWBInfo.pid = (long)getpid(); if (cmdLineWb2) { gstWBInfo.do_whiteboard = TRUE; } if (cmdLineNoWhiteBoard) gstWBInfo.do_whiteboard = FALSE; *gstWBInfo.send_fname = *gstWBInfo.gz_send_fname = '\0'; gstWBInfo.send_fp = gstWBInfo.gz_send_fp = NULL; gstWBInfo.send_socket = (-1); gstWBInfo.listening = FALSE; *gstWBInfo.listen_fname = *gstWBInfo.gz_listen_fname = '\0'; gstWBInfo.listen_fp = gstWBInfo.gz_listen_fp = NULL; gstWBInfo.listen_socket = (-1); #ifdef _TGIF_DBG_WB2 { char *c_ptr=NULL; wb2DebugLevel = 0; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DebugWB2")) != NULL) { wb2DebugLevel = atoi(c_ptr); } } #endif /* _TGIF_DBG_WB2 */ memset(&gRMCastIntrfInfo, 0, sizeof(RMCastIntrfInfo)); return TRUE; } int InitWhiteBoard2() { int want_new_member_support=0; #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) pthread_t tid=(pthread_t)0; #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ char tgwb_config_file[255]; char *homedir=NULL; int config_ok=0; if (!gstWBInfo.do_whiteboard) return TRUE; #if (!defined(PTHREAD) && !defined(HAVE_LIBPTHREAD)) sprintf(gszMsgBox, TgLoadString(STID_NO_PTHREAD_CONTINUE), TOOL_NAME, TOOL_NAME, TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, STOP_MB); gstWBInfo.do_whiteboard = FALSE; SendCommandToSelf(CMDID_QUIT, 0); return FALSE; #endif /* (!defined(PTHREAD) && !defined(HAVE_LIBPTHREAD)) */ if (!RMCastInit()) { gstWBInfo.do_whiteboard = FALSE; return FALSE; } InitDeserializeCmd(); if (!CreateWBListenSocket()) { CleanUpWBSockets(); exit(-1); } if (MkTempFile(gstWBInfo.send_fname, sizeof(gstWBInfo.send_fname), tmpDir, TOOL_NAME) == NULL) { fprintf(stderr, "Fail to create '%s' for serialization.\n", gstWBInfo.send_fname); exit(-1); } snprintf(gstWBInfo.gz_send_fname, sizeof(gstWBInfo.gz_send_fname), "%s.z", gstWBInfo.send_fname); if ((gstWBInfo.send_fp=fopen(gstWBInfo.send_fname, "w+")) == NULL) { fprintf(stderr, "Fail to create '%s' for serialization.\n", gstWBInfo.send_fname); exit(-1); } if ((gstWBInfo.gz_send_fp=fopen(gstWBInfo.gz_send_fname, "w+")) == NULL) { fprintf(stderr, "Fail to create '%s' for serialization.\n", gstWBInfo.gz_send_fname); exit(-1); } if ( (homedir=getenv("HOME")) != NULL ){ sprintf(tgwb_config_file,"%s/.tgwb/tgwb.conf",homedir); if (RM_readConfigFile(tgwb_config_file, 0)) config_ok=2; /* It means that we read $HOME/.tgwb/tgwb.conf */ } else{ fprintf(stderr,"TGWB Warning: Can't get environment variable 'HOME', using default values.\n"); } if (config_ok==0 && RM_readConfigFile("/etc/tgwb.conf", 0)){ config_ok=1; /* It means that we read /etc/tgwb.conf */ } switch (config_ok){ case 1: fprintf(stderr,"Using config file: '/etc/tgwb.conf'\n"); break; case 2: fprintf(stderr,"Using config file: '%s'\n",tgwb_config_file); break; default: fprintf(stderr,"TGWB Warning:\n Config files:\n\t'%s/.tgwb/tgwb.conf'\n\t'/etc/tgwb.conf'\n not found.\nUsing default values.\n",homedir); } /* setting defaults */ RM_setOption(PIPE, &talkToSelfFiledes); RM_setOption(SHUT_DOWN_ROUTINE, &CleanUpWBSockets); RM_initialize((void *)RMcallback_terminate); RM_getOption(NEW_MEMBER_SUPPORT, (void*)&want_new_member_support); if (want_new_member_support) { CurStatus cur_state; fprintf(stderr,"Getting the current status.\n"); RM_getCurStatus( (char*)RM_USE_CURRENT_CONFIG, RM_USE_CURRENT_CONFIG, &cur_state); if (cur_state.size != -1) { int saved_disable_redraw=disableRedraw; deserializingFile = TRUE; disableRedraw = TRUE; UnpackCurrentTGWBState(&cur_state); disableRedraw = saved_disable_redraw; if (!saved_disable_redraw) { ClearAndRedrawDrawWindow(); } deserializingFile = FALSE; } } gstWBInfo.MCastSock = RM_joinGroup((char*)RM_USE_CURRENT_CONFIG, RM_USE_CURRENT_CONFIG ); gstWBInfo.bd_commands = buff_init (10, WB_PACK, UNSORTED, NULL ); /* debugging RMCAST fprintf(stderr,"buffer descriptor: %d\n", gstWBInfo.bd_commands); */ #if (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) if( pthread_create( &tid, NULL, ReceivePacket, NULL ) != 0 ) { fprintf( stderr, "Could not create receive thread\n" ); exit( -1 ); } #endif /* (defined(PTHREAD) || defined(HAVE_LIBPTHREAD)) */ return TRUE; } void RMcallback_terminate( void ) { /* * tgif must do its clean up here before exit * * exit(0); */ } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/text.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000675331�11602233313�014134� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/text.c,v 1.73 2011/06/14 02:32:19 william Exp $ */ #define _INCLUDE_FROM_TEXT_C_ #include "tgifdefs.h" #include "cmdids.h" #include "attr.e" #include "auxtext.e" #include "choice.e" #include "cmd.e" #include "color.e" #ifndef _NO_KINPUT #include "convkinput.e" #endif /* ~_NO_KINPUT */ #include "cutpaste.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "edit.e" #include "exec.e" #include "file.e" #include "font.e" #include "grid.e" #include "inmethod.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "names.e" #ifndef _NO_NKF #include "nkf.e" #endif /* ~_NO_NKF */ #include "obj.e" #include "pattern.e" #include "poly.e" #include "prtgif.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "stretch.e" #include "strtbl.e" #include "text.e" #include "tginssym.e" #include "util.e" #include "wb.e" #include "xbitmap.e" #include "xpixmap.e" #define ADVANCE_LEFT (TRUE) #define ADVANCE_RIGHT (FALSE) #define POSITION_END (TRUE) #define POSITION_CUR (FALSE) int textDrawn=FALSE; int curTextModified=FALSE; int textVSpace=0; int textJust=JUST_L; int textCursorShown=FALSE; int textCursorH=14; /* UNSCALED height of the text cursor */ int editingText=FALSE; /* editing existing text */ int curTextIsNew=FALSE; int editTextSize=0; int readingTextObject=FALSE; float scriptFraction=((float)0.6); char scriptFractionStr[80]; int deleteNextCharWithDelKey=TRUE; int lengthLimit256InInsertChar=FALSE; static struct ObjRec *justDrawnTextObj=NULL; struct tagBeforeEditTextInfo { int x, baseline_y; int obbox_w, obbox_h; int first_mini_line_asc; struct BBRec bbox, obbox; } beforeEditTextInfo; static int tmpAdjAbsX=0, tmpAdjAbsY=0; /* absolute coordinates */ static int curTextMovedAbsX=0, curTextMovedAbsY=0; /* absolute coordinates */ /* --------------------- DynStr Routines --------------------- */ void FreeDynStrBuf(dyn_str) struct DynStrRec *dyn_str; { if (dyn_str == NULL) return; UtilFree(dyn_str->s); memset(dyn_str, 0, sizeof(struct DynStrRec)); } void DynStrCpy(dest_dyn_str, src_dyn_str) struct DynStrRec *dest_dyn_str, *src_dyn_str; { char *psz_new=NULL; int new_sz=src_dyn_str->sz; if (new_sz == 0) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "src_dyn_str has 0 size in DynStrCpy()", "Fixed"); #endif /* _TGIF_DBG */ new_sz++; psz_new = (char *)malloc(sizeof(char)); if (psz_new == NULL) FailAllocMessage(); *psz_new = '\0'; } else { psz_new = (char *)malloc(new_sz*sizeof(char)); if (psz_new == NULL) FailAllocMessage(); strcpy(psz_new, src_dyn_str->s); } if (dest_dyn_str->s != NULL) free(dest_dyn_str->s); dest_dyn_str->s = psz_new; dest_dyn_str->sz = new_sz; } struct DynStrRec *NewDynStr() { struct DynStrRec *new_dyn_str=NULL; new_dyn_str = (struct DynStrRec *)malloc(sizeof(struct DynStrRec)); if (new_dyn_str == NULL) FailAllocMessage(); new_dyn_str->s = NULL; new_dyn_str->sz = 0; return new_dyn_str; } struct DynStrRec *DynStrDup(dyn_str) struct DynStrRec *dyn_str; { struct DynStrRec *new_dyn_str=NULL; new_dyn_str = (struct DynStrRec *)malloc(sizeof(struct DynStrRec)); if (new_dyn_str == NULL) FailAllocMessage(); new_dyn_str->s = NULL; DynStrCpy(new_dyn_str, dyn_str); return new_dyn_str; } void DynStrSet(dest_dyn_str, buf) struct DynStrRec *dest_dyn_str; char *buf; { char *psz_new=NULL; int sz=strlen(buf)+1; psz_new = (char*)malloc(sz*sizeof(char)); if (psz_new == NULL) FailAllocMessage(); strcpy(psz_new, buf); if (dest_dyn_str->s != NULL) free(dest_dyn_str->s); dest_dyn_str->s = psz_new; dest_dyn_str->sz = sz; } /* --------------------- Str Routines --------------------- */ void FreeStr(str_ptr) struct StrRec *str_ptr; { if (str_ptr->dyn_str.s != NULL) free(str_ptr->dyn_str.s); free(str_ptr); } void FreeStrList(str_ptr) struct StrRec *str_ptr; { while (str_ptr != NULL) { struct StrRec *next_str_ptr=str_ptr->next; FreeStr(str_ptr); str_ptr = next_str_ptr; } } struct StrRec *NewStr() { struct StrRec *new_str_ptr=NULL; new_str_ptr = (struct StrRec *)malloc(sizeof(struct StrRec)); if (new_str_ptr == NULL) FailAllocMessage(); memset(new_str_ptr, 0, sizeof(struct StrRec)); DynStrSet(&new_str_ptr->dyn_str, ""); return new_str_ptr; } /* --------------------- Text Routines --------------------- */ void SetTextHighlight() { textHighlight = (endStrBlock != NULL && (curStrBlock != endStrBlock || textCurIndex != textEndIndex)); } typedef struct tagCursorPositionInCurText { struct ObjRec *cur_text_obj; StrBlockInfo *cur_str_block, *end_str_block; int text_cur_index, text_end_index; } CursorPositionInCurTextInfo; static CursorPositionInCurTextInfo gstCursorPositionInCurText; void SaveCursorPositionInCurText() { gstCursorPositionInCurText.cur_text_obj = curTextObj; gstCursorPositionInCurText.cur_str_block = curStrBlock; gstCursorPositionInCurText.end_str_block = endStrBlock; gstCursorPositionInCurText.text_cur_index = textCurIndex; gstCursorPositionInCurText.text_end_index = textEndIndex; } void RestoreCursorPositionInCurText() { curTextObj = gstCursorPositionInCurText.cur_text_obj; curStrBlock = gstCursorPositionInCurText.cur_str_block; endStrBlock = gstCursorPositionInCurText.end_str_block; textCurIndex = gstCursorPositionInCurText.text_cur_index; textEndIndex = gstCursorPositionInCurText.text_end_index; SetTextHighlight(); } void InvalidateTextCache(text_ptr) struct TextRec *text_ptr; { if (text_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, text_ptr->cached_bitmap); } if (text_ptr->cached_pixmap != None) { XFreePixmap(mainDisplay, text_ptr->cached_pixmap); } if (text_ptr->cached_bg_bitmap != None) { XFreePixmap(mainDisplay, text_ptr->cached_bg_bitmap); } text_ptr->cached_zoom = 0; text_ptr->cached_bitmap = None; text_ptr->cached_pixmap = None; text_ptr->cached_bg_bitmap = None; } void TellTextCursorPosition(pnX, pnY) int *pnX, *pnY; { *pnX = textCurX; *pnY = textCurY + textCursorH; } #define BLUR 32 void BlurText(Win, gc, XOff, YOff, W, H) Window Win; GC gc; int XOff, YOff, W, H; /* XOff and YOff are screen offsets (scaled and translated) */ { XPoint v[5]; v[0].x = (short)XOff; v[0].y = (short)YOff; v[1].x = (short)XOff; v[1].y = (short)YOff+H+1; v[2].x = (short)XOff+W+1; v[2].y = (short)YOff+H+1; v[3].x = (short)XOff+W+1; v[3].y = (short)YOff; v[4].x = (short)XOff; v[4].y = (short)YOff; XFillPolygon(mainDisplay, Win, gc, v, 5, Convex, CoordModeOrigin); } void InitText() { char *c_ptr=NULL; XGCValues values; textBackingBitmap = XCreatePixmap(mainDisplay,mainWindow,10,10,1); if (textBackingBitmap==None) { sprintf(gszMsgBox, TgLoadString(STID_CANT_ALLOC_BITMAP_OF_SIZE), 10, 10); Error("InitText()", gszMsgBox); } textBackingBgBitmap = XCreatePixmap(mainDisplay,mainWindow,10,10,1); if (textBackingBgBitmap==None) { sprintf(gszMsgBox, TgLoadString(STID_CANT_ALLOC_BITMAP_OF_SIZE), 10, 10); Error("InitText()", gszMsgBox); } textBackingPixmap = XCreatePixmap(mainDisplay,mainWindow,10,10,mainDepth); if (textBackingPixmap==None) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), 10, 10); Error("InitText()", gszMsgBox); } textBackingBitmapW = 10; textBackingBitmapH = 10; values.foreground = 1; values.background = 0; values.fill_style = FillSolid; values.function = GXcopy; rotateGC = XCreateGC(mainDisplay, textBackingBitmap, GCForeground | GCBackground | GCFillStyle | GCFunction, &values); if (rotateGC==NULL) { Error("InitText()", TgLoadString(STID_CANNOT_CREATE_GC)); } scriptFraction = 0.6; strcpy(scriptFractionStr, "0.6"); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ScriptFraction")) != NULL) { strcpy(scriptFractionStr, c_ptr); scriptFraction = (float)atof(c_ptr); if (scriptFraction < 0.2 || scriptFraction > 1.01) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "ScriptFraction", scriptFractionStr, "0.6"); fprintf(stderr, "\n"); scriptFraction = 0.6; strcpy(scriptFractionStr, "0.6"); } else if (strcmp(scriptFractionStr, "0.6") == 0) { scriptFraction = 0.6; strcpy(scriptFractionStr, "0.6"); } } deleteNextCharWithDelKey = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DeleteNextCharWithDelKey")) != NULL && UtilStrICmp("false", c_ptr) == 0) { deleteNextCharWithDelKey = FALSE; } lengthLimit256InInsertChar = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "LengthLimit256InInsertChar")) != NULL && UtilStrICmp("true", c_ptr) == 0) { lengthLimit256InInsertChar = TRUE; } } void CleanUpText() { if (textBackingBitmap != None) { XFreePixmap(mainDisplay, textBackingBitmap); } if (textBackingBgBitmap != None) { XFreePixmap(mainDisplay, textBackingBgBitmap); } if (textBackingPixmap != None) { XFreePixmap(mainDisplay, textBackingPixmap); } textBackingBitmap = None; textBackingBitmapW = textBackingBitmapH = 0; if (rotateGC != NULL) XFreeGC(mainDisplay, rotateGC); rotateGC = NULL; } static struct BBRec editTextAreaBBox; /* coordinates are screen offsets */ static void SetEditTextArea(w, h, min_lbearing, max_rextra) int w, h, min_lbearing, max_rextra; { memset(&editTextAreaBBox, 0, sizeof(struct BBRec)); SetBBRec(&editTextAreaBBox, textOrigX, textOrigY, textOrigX+w, textOrigY+h); textW = w; textH = h; textAbsMinLBearing = min_lbearing; textAbsMaxRExtra = max_rextra; } static void UpdateEditTextArea(w, h, min_lbearing, max_rextra) int w, h, min_lbearing, max_rextra; { struct BBRec bbox; int text_area_enlarged=FALSE; SetBBRec(&bbox, textOrigX, textOrigY, textOrigX+w, textOrigY+h); UnionRect(&editTextAreaBBox, &bbox, &editTextAreaBBox); w = editTextAreaBBox.rbx-editTextAreaBBox.ltx; h = editTextAreaBBox.rby-editTextAreaBBox.lty; if (w > textW) { textW = w; text_area_enlarged = TRUE; } if (h > textH) { textH = h; text_area_enlarged = TRUE; } if (min_lbearing < textAbsMinLBearing) { textAbsMinLBearing = min_lbearing; text_area_enlarged = TRUE; } if (max_rextra > textAbsMaxRExtra) { textAbsMaxRExtra = max_rextra; text_area_enlarged = TRUE; } if (text_area_enlarged) { ForceDirtyBBoxToRedrawAll(); } } static void AdjTextVerticalShift(clean_bbox) int clean_bbox; { struct TextRec *text_ptr=curTextObj->detail.t; int w=0, h=0, saved_first_miniline_asc=0, new_first_miniline_asc=0; saved_first_miniline_asc = text_ptr->minilines.first->asc; UpdTextBBox(curTextObj); new_first_miniline_asc = text_ptr->minilines.first->asc; if (new_first_miniline_asc > saved_first_miniline_asc) { int saved_orig_y=textOrigY; textAbsY = textAbsBaselineY - new_first_miniline_asc; textOrigY = OFFSET_Y(textAbsY); textCurY += (textOrigY - saved_orig_y); } w = text_ptr->minilines.w; h = (textOrigBaselineY - textOrigY) + (text_ptr->minilines.h - new_first_miniline_asc); SetTextCurXY(); if (textHighlight) SetTextEndXY(); UpdateEditTextArea(w, h, text_ptr->minilines.min_lbearing, text_ptr->minilines.max_rextra); UpdateCurTextBBoxes(clean_bbox); } void NewCurText() { MiniLinesInfo *minilines=NULL; struct TextRec *text_ptr=NULL; if (textCursorH+textVSpace <= 0) { textVSpace = 0; ShowTextVSpace(); MsgBox(TgLoadString(STID_TEXT_VSPACE_TOO_SMALL_RESET_0), TOOL_NAME, INFO_MB); } PushCurFont(); text_ptr = (struct TextRec *)malloc(sizeof(struct TextRec)); if (text_ptr == NULL) FailAllocMessage(); memset(text_ptr, 0, sizeof(struct TextRec)); minilines = (&text_ptr->minilines); CreateMiniLineFromString("", &minilines->first, &minilines->last); text_ptr->attr = NULL; minilines->just = textJust; minilines->v_space = textVSpace; minilines->first->asc = canvasFontAsc; minilines->first->des = canvasFontDes; text_ptr->pen = penPat; text_ptr->fill = objFill; text_ptr->cached_bitmap = None; text_ptr->cached_zoom = 0; text_ptr->lines = 1; curStrBlock = minilines->first->first_block; textCurIndex = 0; ResetOnCursorKey(FALSE); text_ptr->read_only = FALSE; text_ptr->orig_w = text_ptr->orig_h = 0; text_ptr->underline_y_offset = curUnderlineYOffset; text_ptr->overline_y_offset = curOverlineYOffset; text_ptr->min_lbearing = 0; text_ptr->max_rextra = 0; text_ptr->baseline_y = textAbsBaselineY; curTextObj = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (curTextObj == NULL) FailAllocMessage(); memset(curTextObj, 0, sizeof(struct ObjRec)); curTextObj->x = textAbsX; curTextObj->y = textAbsY; curTextObj->type = OBJ_TEXT; curTextObj->id = objId++; curTextObj->dirty = FALSE; curTextObj->rotation = 0; curTextObj->locked = FALSE; /* the color specifies the fill pattern color */ curTextObj->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(curTextObj->color_str, sizeof(curTextObj->color_str), colorMenuItems[colorIndex]); } curTextObj->detail.t = text_ptr; curTextObj->fattr = curTextObj->lattr = NULL; curTextObj->ctm = NULL; curTextObj->invisible = FALSE; curTextObj->trans_pat = transPat; AddObj(NULL, topObj, curTextObj); SetEditTextArea(0, textCursorH, 0, 0); textCursorShown = TRUE; SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); curTextIsNew = TRUE; if (editTextSize != 0) { RestoreEditTextSize(curTextObj, FALSE); } AdjTextVerticalShift(TRUE); if (gnInputMethod != TGIM_NONE) { if (!tgIMHandleNewCurText(mainDisplay, drawWindow)) { } } } void FreeTextObj(ObjPtr) struct ObjRec *ObjPtr; { if (ObjPtr->detail.t != NULL) { FreeMiniLines(&ObjPtr->detail.t->minilines, FALSE); if (ObjPtr->detail.t->cached_bitmap != None) { XFreePixmap(mainDisplay, ObjPtr->detail.t->cached_bitmap); } if (ObjPtr->detail.t->cached_pixmap != None) { XFreePixmap(mainDisplay, ObjPtr->detail.t->cached_pixmap); } if (ObjPtr->detail.t->cached_bg_bitmap != None) { XFreePixmap(mainDisplay, ObjPtr->detail.t->cached_bg_bitmap); } free(ObjPtr->detail.t); } free(ObjPtr); } static void ShowTextRelatedInfo() { ShowJust(); ShowPen(); ShowFill(); ShowTransPatMode(); ShowColor(FALSE); ShowTextVSpace(); ShowCurFont(); ShowTextSize(); } void SetEditTextSizeValue(new_edit_text_size) int new_edit_text_size; { editTextSize = new_edit_text_size; curRealSzUnit = INVALID; } void UpdateTextInfoChoices(forced) int forced; { int saved_font=curFont, saved_style=curStyle, saved_sz_unit=curSzUnit; int saved_just=textJust, saved_color=colorIndex; int saved_underline_on=curUnderlineOn; int saved_overline_on=curOverlineOn; StrSegInfo *pStrSeg=curStrBlock->seg; MiniLinesInfo *minilines=curStrBlock->owner_mini_line->owner_minilines; if (!forced && pStrSeg->color == colorIndex && /* pStrSeg->underline_on == curUnderlineOn && */ minilines->just == textJust && minilines->v_space == textVSpace && pStrSeg->font == curFont && pStrSeg->style == curStyle && pStrSeg->sz_unit == curSzUnit && (editTextSize == 0 || pStrSeg->real_sz_unit == curRealSzUnit) && pStrSeg->underline_on == curUnderlineOn && pStrSeg->overline_on == curOverlineOn) { return; } if (pStrSeg->color != colorIndex) { colorIndex = pStrSeg->color; ShowColor(FALSE); } if (minilines->just != textJust) { textJust = minilines->just; ShowJust(); } if (minilines->v_space != textVSpace) { textVSpace = minilines->v_space; ShowTextVSpace(); } if (editTextSize != 0) { saved_sz_unit = curRealSzUnit; if (forced || curRealSzUnit == INVALID || pStrSeg->font != curFont || pStrSeg->style != curStyle || pStrSeg->real_sz_unit != curRealSzUnit || pStrSeg->sz_unit != curSzUnit || pStrSeg->underline_on != curUnderlineOn || pStrSeg->overline_on != curOverlineOn) { if (!TrySetCanvasFont(pStrSeg->font, pStrSeg->style, editTextSize, TRUE, NULL)) { SetEditTextSizeValue(0); } else { if (pStrSeg->font != curFont) curFont = pStrSeg->font; if (pStrSeg->style != curStyle) curStyle = pStrSeg->style; if (pStrSeg->real_sz_unit != curRealSzUnit) { curRealSzUnit = pStrSeg->real_sz_unit; } if (pStrSeg->underline_on != curUnderlineOn) { curUnderlineOn = pStrSeg->underline_on; } if (pStrSeg->overline_on != curOverlineOn) { curOverlineOn = pStrSeg->overline_on; } curSzUnit = FontSizeToSzUnit(editTextSize); SetCanvasFont(); ShowTextSize(); ShowCurFont(); if (!textHighlight) CurFontMsg(FALSE, TRUE, pStrSeg); } } } if (editTextSize == 0) { if (forced || pStrSeg->font != curFont || pStrSeg->style != curStyle || pStrSeg->sz_unit != curSzUnit || pStrSeg->underline_on != curUnderlineOn || pStrSeg->overline_on != curOverlineOn) { if (pStrSeg->font != curFont) curFont = pStrSeg->font; if (pStrSeg->style != curStyle) curStyle = pStrSeg->style; if (pStrSeg->sz_unit != curSzUnit) curSzUnit = pStrSeg->sz_unit; if (pStrSeg->underline_on != curUnderlineOn) { curUnderlineOn = pStrSeg->underline_on; } if (pStrSeg->overline_on != curOverlineOn) { curOverlineOn = pStrSeg->overline_on; } SetCanvasFont(); ShowTextSize(); ShowCurFont(); if (!textHighlight) CurFontMsg(FALSE, TRUE, NULL); } } if (pStrSeg->underline_on != curUnderlineOn) { curUnderlineOn = pStrSeg->underline_on; } if (pStrSeg->overline_on != curOverlineOn) { curOverlineOn = pStrSeg->overline_on; } if (saved_style != curStyle || saved_just != textJust || saved_underline_on != curUnderlineOn || saved_overline_on != curOverlineOn) { UpdatePinnedMenu(MENU_STYLE); } if (saved_font != curFont) UpdatePinnedMenu(MENU_FONT); if (editTextSize != 0) { if (saved_sz_unit != curRealSzUnit) { UpdatePinnedMenu(MENU_SIZE); } } else { if (saved_sz_unit != curSzUnit) { UpdatePinnedMenu(MENU_SIZE); } } if (saved_color != colorIndex) UpdatePinnedMenu(MENU_COLOR); } static void RestoreStrSegFromUsingEditTextSize(pStrSeg, pUserData) StrSegInfo *pStrSeg; void *pUserData; /* NULL */ { pStrSeg->sz_unit = pStrSeg->real_sz_unit; } static void SaveStrSegToUseEditTextSize(pStrSeg, pUserData) StrSegInfo *pStrSeg; void *pUserData; /* NULL */ { pStrSeg->real_sz_unit = pStrSeg->sz_unit; pStrSeg->sz_unit = FontSizeToSzUnit(editTextSize); } int RestoreEditTextSize(obj_ptr, restore) struct ObjRec *obj_ptr; int restore; /* returns TRUE if something is changed */ { if (editTextSize != 0) { MiniLinesInfo *minilines=(&obj_ptr->detail.t->minilines); if (restore) { DoFuncOnStrSegForMiniLines(minilines, RestoreStrSegFromUsingEditTextSize, NULL); } else { DoFuncOnStrSegForMiniLines(minilines, SaveStrSegToUseEditTextSize, NULL); } return TRUE; } return FALSE; } int ShouldRightMarginBeActive() { if (curChoice != DRAWTEXT) return TRUE; if (!textCursorShown) return TRUE; if (curTextObj->ctm != NULL) return FALSE; if (textJust != JUST_L) return FALSE; if (curStrBlock->owner_mini_line->owner_minilines->owner_block != NULL) { return FALSE; } if (zoomScale != 0 || zoomedIn) return FALSE; if (editTextSize != 0) return FALSE; if (curStrBlock->next != NULL) return FALSE; if (curStrBlock->type != SB_SIMPLE) return FALSE; if (textCurIndex != curStrBlock->seg->dyn_str.sz-1) return FALSE; return TRUE; } void SetRightMarginActive() { if (rightMarginEnabled == TRUE) { int saved_right_margin_active=rightMarginActive; rightMarginActive = ShouldRightMarginBeActive(); if (rightMarginActive != saved_right_margin_active) { RedrawHRulerWindow(); } } else { rightMarginActive = TRUE; } } static int gnDontRedrawDuringPaste=FALSE; static int gnPastingLineNum=0; static void EndChangeCurText(clean_bbox) int clean_bbox; { curTextModified = TRUE; if (!gnDontRedrawDuringPaste) { /* * If clean_bbox is TRUE, AdjTextVerticalShift() will adjust * curStrBlock->bbox to be the new size. After * UpdateTextInfoChoices() is called, curStrBlock->clean_bbox * will also be updated to the new size. */ AdjTextVerticalShift(clean_bbox); RedrawCurText(); UpdateTextInfoChoices(FALSE); } InvalidateTextCache(curTextObj->detail.t); } static int NumLinesInCurText() { MiniLinesInfo *minilines=(&curTextObj->detail.t->minilines); MiniLineInfo *pMiniLine=NULL; int count=0; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next, count++) { } return count; } static void CreateNoTextObj() { struct TextRec *text_ptr=curTextObj->detail.t; struct AttrRec *attr_ptr=text_ptr->attr; int ltx=0, lty=0, rbx=0, rby=0, scr_ltx=0, scr_lty; if (attr_ptr != NULL) { /* the text being edited is an attribute */ if (attr_ptr->nameshown) { UnlinkAttr(attr_ptr); FreeTextObj(curTextObj); FreeAttr(attr_ptr); } else { text_ptr->lines = 1; UpdateAttr(text_ptr, attr_ptr); } AdjObjBBox(attr_ptr->owner); if (outerSel != NULL) AdjAncestorsBBox(); if (curTextModified) { if (outerSel != NULL) { RecordReplaceAnObj(outerSel->obj); } else { RecordReplaceAnObj(attr_ptr->owner); } } else { AbortPrepareCmd(CMD_REPLACE); } } else { if (outerSel != NULL) { UnlinkCurTextFromInnerSel(); AdjAncestorsBBox(); } if (!curTextIsNew) { if (outerSel != NULL) { RecordReplaceAnObj(outerSel->obj); } else { ChangeReplaceOneCmdToDeleteCmd(); } } else { AbortPrepareCmd(CMD_REPLACE); } if (curTextObj != NULL) { if (outerSel != NULL) { /* curTextObj already broken off from the main */ /* stream of objects, so just free it. */ FreeObj(curTextObj); } else { DelObj(curTextObj); } } } switch (textJust) { case JUST_L: scr_ltx = OFFSET_X(textAbsX-2); if (zoomedIn) { ltx = ABS_X(textOrigX-2)-2; rbx = ABS_X(textOrigX+textW+2)+2; } else { ltx = ABS_X(textOrigX-4); rbx = ABS_X(textOrigX+textW+4); } break; case JUST_C: scr_ltx = OFFSET_X(textAbsX)-textW/2-2; if (zoomedIn) { ltx = ABS_X(textOrigX-(textW>>1)-2)-2; rbx = ABS_X(textOrigX+(textW>>1)+2)+2; } else { ltx = ABS_X(textOrigX-(textW>>1)-4); rbx = ABS_X(textOrigX+(textW>>1)+4); } break; case JUST_R: scr_ltx = OFFSET_X(textAbsX)-textW-2; if (zoomedIn) { ltx = ABS_X(textOrigX-textW-2)-2; rbx = ABS_X(textOrigX+textW+2)+2; } else { ltx = ABS_X(textOrigX-textW-4); rbx = ABS_X(textOrigX+textW+4); } break; } scr_lty = OFFSET_Y(textAbsY)-2; if (zoomedIn) { lty = ABS_Y(textOrigY-2)-2; rby = ABS_Y(textOrigY+textH+2)+2; } else { lty = ABS_Y(textOrigY-4); rby = ABS_Y(textOrigY+textH+4); } ltx -= (curTextOutlineHalfW<<1); lty -= (curTextOutlineHalfW<<1); rbx += (curTextOutlineHalfW<<2); rby += (curTextOutlineHalfW<<2); if (editingText) { XClearArea(mainDisplay, drawWindow, scr_ltx-(curTextOutlineHalfW<<1), scr_lty-(curTextOutlineHalfW<<1), textW+5+(curTextOutlineHalfW<<2), textH+5+(curTextOutlineHalfW<<2), FALSE); RedrawAreas(botObj, beforeEditTextInfo.bbox.ltx-GRID_ABS_SIZE(2), beforeEditTextInfo.bbox.lty-GRID_ABS_SIZE(2), beforeEditTextInfo.bbox.rbx+GRID_ABS_SIZE(2), beforeEditTextInfo.bbox.rby+GRID_ABS_SIZE(2), ltx, lty, rbx, rby); } else { RedrawAnArea(botObj, ltx, lty, rbx, rby); } firstMiniLine = lastMiniLine = NULL; textCursorShown = FALSE; curTextObj = NULL; textCurIndex = 0; SetEditTextArea(0, textCursorH, 0, 0); if (editingText) { XClearArea(mainDisplay, drawWindow, scr_ltx-(curTextOutlineHalfW<<1), scr_lty-(curTextOutlineHalfW<<1), textW+5+(curTextOutlineHalfW<<2), textH+5+(curTextOutlineHalfW<<2), FALSE); RedrawAreas(botObj, beforeEditTextInfo.bbox.ltx-GRID_ABS_SIZE(2), beforeEditTextInfo.bbox.lty-GRID_ABS_SIZE(2), beforeEditTextInfo.bbox.rbx+GRID_ABS_SIZE(2), beforeEditTextInfo.bbox.rby+GRID_ABS_SIZE(2), ltx, lty, rbx, rby); } else { RedrawAnArea(botObj, ltx, lty, rbx, rby); } firstMiniLine = lastMiniLine = NULL; textCursorShown = FALSE; curTextObj = NULL; textCurIndex = 0; SetEditTextArea(0, textCursorH, 0, 0); PopCurFont(); ShowTextRelatedInfo(); if (editingText) { editingText = FALSE; } textDrawn = FALSE; justDrawnTextObj = NULL; textHighlight = FALSE; curTextIsNew = FALSE; curStrBlock = endStrBlock = NULL; textCurIndex = textEndIndex = INVALID; textHighlight = FALSE; } static void RedrawAreasInCreateText(ltx1, lty1, rbx1, rby1, ltx2, lty2, rbx2, rby2) int ltx1, lty1, rbx1, rby1, ltx2, lty2, rbx2, rby2; { struct BBRec bbox1, bbox2; SetBBRec(&bbox1, ltx1, lty1, rbx1, rby1); SetBBRec(&bbox2, ltx2, lty2, rbx2, rby2); if (curTextObj != NULL) { UnionRect(&bbox1, &curTextObj->bbox, &bbox1); } InflateBBox(&bbox2, -GRID_ABS_SIZE(2), -GRID_ABS_SIZE(2), &bbox2); if (!BBoxIntersect(bbox1, bbox2)) { RedrawAnArea(botObj, ltx2-GRID_ABS_SIZE(2), lty2-GRID_ABS_SIZE(2), rbx2+GRID_ABS_SIZE(2), rby2+GRID_ABS_SIZE(2)); } RedrawAreas(botObj, bbox1.ltx-GRID_ABS_SIZE(2), bbox1.lty-GRID_ABS_SIZE(2), bbox1.rbx+GRID_ABS_SIZE(2), bbox1.rby+GRID_ABS_SIZE(2), ltx2-GRID_ABS_SIZE(2), lty2-GRID_ABS_SIZE(2), rbx2+GRID_ABS_SIZE(2), rby2+GRID_ABS_SIZE(2)); } int CreateTextObj(nDeactivateIM, nRedraw) int nDeactivateIM, nRedraw; /* returns TRUE if something got created */ /* returns FALSE otherwise */ { struct TextRec *text_ptr=NULL; struct AttrRec *attr_ptr=NULL; MiniLinesInfo *minilines=NULL; int num_lines=0, ltx=0, lty=0, rbx=0, rby=0, scr_ltx=0, scr_lty=0; int saved_font=curFont, saved_style=curStyle, saved_sz_unit=curSzUnit; int saved_just=textJust, saved_color=colorIndex; int saved_underline_on=curUnderlineOn; int saved_overline_on=curOverlineOn; if (nDeactivateIM) { if (canvasFontDoubleByte && tgIMDeactiveOnCreateText(mainDisplay, drawWindow)) { if (tgIMHandleCreateText(mainDisplay, drawWindow)) { } } } if (!textCursorShown) return FALSE; if (gstWBInfo.do_whiteboard) { gstWBInfo.BlockRemoteCmdDepth--; } text_ptr = curTextObj->detail.t; minilines = (&text_ptr->minilines); num_lines = NumLinesInCurText(); if (editTextSize != 0) { RestoreEditTextSize(curTextObj, TRUE); RecalcTextMetrics(text_ptr, curTextObj->x, text_ptr->baseline_y); UpdateEditTextArea(minilines->w, minilines->h, minilines->min_lbearing, minilines->max_rextra); } if (curTextModified) { int retry=TRUE, shrunk=FALSE; while (retry) { retry = FALSE; if (ShrinkMiniLines(&curTextObj->detail.t->minilines, &retry)) { shrunk = TRUE; } } if (shrunk) { curStrBlock = endStrBlock = NULL; textCurIndex = textEndIndex = INVALID; textHighlight = FALSE; UpdTextBBox(curTextObj); } } if (minilines->first == minilines->last && BlankMiniLine(minilines->first)) { /* no text entered or all text erased */ CreateNoTextObj(); UpdatePinnedMenu(MENU_EDIT); if (saved_style != curStyle || saved_just != textJust || saved_underline_on != curUnderlineOn || saved_overline_on != curOverlineOn) { UpdatePinnedMenu(MENU_STYLE); } if (saved_font != curFont) UpdatePinnedMenu(MENU_FONT); if (saved_sz_unit != curSzUnit) UpdatePinnedMenu(MENU_SIZE); if (saved_color != colorIndex) UpdatePinnedMenu(MENU_COLOR); if (gstWBInfo.do_whiteboard) { TryHandleWBInputData(); SetCurChoice(DRAWTEXT); } curTextMovedAbsX = curTextMovedAbsY = 0; ClearCopyUTF8Info(); return FALSE; } if (curTextModified) { InvalidateTextCache(text_ptr); } text_ptr->lines = num_lines; if (curTextObj->ctm == NULL) { curTextObj->x = textAbsX - tmpAdjAbsX - curTextMovedAbsX; text_ptr->baseline_y = textAbsBaselineY - tmpAdjAbsY - curTextMovedAbsY; curTextObj->y = text_ptr->baseline_y - minilines->first->asc; } else { int dx=0, dy=0; if (beforeEditTextInfo.first_mini_line_asc != minilines->first->asc) { int anchor_x=0, anchor_y=0, x=0, y=0; TransformPointThroughCTM(0, beforeEditTextInfo.first_mini_line_asc, curTextObj->ctm, &x, &y); anchor_x = curTextObj->x + x; anchor_y = curTextObj->y + y; TransformPointThroughCTM(0, minilines->first->asc, curTextObj->ctm, &x, &y); dx = anchor_x - (curTextObj->x + x); dy = anchor_y - (curTextObj->y + y); } curTextObj->x = textAbsX - tmpAdjAbsX - curTextMovedAbsX; curTextObj->y = textAbsY - tmpAdjAbsY - curTextMovedAbsY; curTextObj->x += dx; curTextObj->y += dy; curTextObj->x -= curTextObj->ctm->t[CTM_TX]; curTextObj->y -= curTextObj->ctm->t[CTM_TY]; } RecalcTextMetrics(text_ptr, curTextObj->x, text_ptr->baseline_y); textJust = minilines->just; SetTextOrigBBoxes(curTextObj, textJust, text_ptr->w, text_ptr->h, text_ptr->min_lbearing, text_ptr->max_rextra, ROTATE0); SetTextBBox(curTextObj, textJust, text_ptr->w, text_ptr->h, text_ptr->min_lbearing, text_ptr->max_rextra, ROTATE0); if (curTextObj->ctm != NULL) { GetTransformedOBBoxOffsetVs(curTextObj, curTextObj->rotated_obbox); } switch (textJust) { case JUST_L: scr_ltx = OFFSET_X(textAbsX-2); if (zoomedIn) { ltx = textAbsX-2-GRID_ABS_SIZE(2); rbx = textAbsX+textW+2+GRID_ABS_SIZE(2); } else { ltx = textAbsX-ABS_SIZE(2)-GRID_ABS_SIZE(2); rbx = textAbsX+ABS_SIZE(textW+2)+GRID_ABS_SIZE(2); } break; case JUST_C: scr_ltx = OFFSET_X(textAbsX)-textW/2-2; if (zoomedIn) { ltx = textAbsX-textW/2-2-GRID_ABS_SIZE(2); rbx = textAbsX+textW/2+2+GRID_ABS_SIZE(2); } else { ltx = textAbsX-ABS_SIZE(textW/2+2)-GRID_ABS_SIZE(2); rbx = textAbsX+ABS_SIZE(textW/2+2)+GRID_ABS_SIZE(2); } break; case JUST_R: scr_ltx = OFFSET_X(textAbsX)-textW-2; if (zoomedIn) { ltx = textAbsX-textW-2-GRID_ABS_SIZE(2); rbx = textAbsX+2+GRID_ABS_SIZE(2); } else { ltx = textAbsX-ABS_SIZE(textW+2)-GRID_ABS_SIZE(2); rbx = textAbsX+ABS_SIZE(2)+GRID_ABS_SIZE(2); } break; } scr_lty = OFFSET_Y(textAbsY); if (zoomedIn) { lty = textAbsY-2-GRID_ABS_SIZE(2); rby = textAbsY+textH+2+GRID_ABS_SIZE(2); } else { lty = textAbsY-ABS_SIZE(2)-GRID_ABS_SIZE(2); rby = textAbsY+ABS_SIZE(textH+2)+GRID_ABS_SIZE(2); } if ((attr_ptr=text_ptr->attr) != NULL) { UpdateAttr(text_ptr, attr_ptr); textDrawn = FALSE; justDrawnTextObj = NULL; if (curTextModified && AutoCenterAttr(attr_ptr->owner)) { struct BBRec bbox; CenterObjInOBBox(attr_ptr->obj, attr_ptr->owner->obbox, &bbox); if (bbox.ltx < ltx) ltx = bbox.ltx; if (bbox.lty < lty) lty = bbox.lty; if (bbox.rbx > rbx) rbx = bbox.rbx; if (bbox.rby > rby) rby = bbox.rby; } AdjObjBBox(attr_ptr->owner); if (outerSel != NULL) AdjAncestorsBBox(); if (curTextModified) { if (outerSel != NULL) { RecordReplaceAnObj(outerSel->obj); } else { RecordReplaceAnObj(attr_ptr->owner); } } else { AbortPrepareCmd(CMD_REPLACE); } } else { if (outerSel != NULL) { textDrawn = FALSE; justDrawnTextObj = NULL; AdjAncestorsBBox(); } else { textDrawn = TRUE; justDrawnTextObj = curTextObj; } if (curTextIsNew) { AbortPrepareCmd(CMD_REPLACE); RecordNewObjCmd(); } else if (curTextModified) { if (outerSel != NULL) { RecordReplaceAnObj(outerSel->obj); } else { RecordReplaceAnObj(curTextObj); } } else { AbortPrepareCmd(CMD_REPLACE); } } textCursorShown = FALSE; textCurIndex = 0; GetCurTextBBoxes(&curTextOBBox, NULL); SetEditTextArea(curTextOBBox.rbx-curTextOBBox.ltx, curTextOBBox.rby-curTextOBBox.lty, text_ptr->minilines.min_lbearing, text_ptr->minilines.max_rextra); if (editingText) { int x=0; x = curTextBBox.ltx; XClearArea(mainDisplay, drawWindow, x-2-(curTextOutlineHalfW<<1), curTextBBox.lty-2-(curTextOutlineHalfW<<1), curTextBBox.rbx-x+5+(curTextOutlineHalfW<<2), curTextBBox.rby-curTextBBox.lty+5+(curTextOutlineHalfW<<2), FALSE); if (ABS_X(x) < ltx) ltx = ABS_X(x); if (ABS_Y(textOrigY) < lty) lty = ABS_Y(textOrigY); x += textW-textAbsMinLBearing+textAbsMaxRExtra+1; if (ABS_X(x) > rbx) rbx = ABS_X(x); if (ABS_Y(textOrigY+textH+1) > rby) rby = ABS_Y(textOrigY+textH+1); if (curTextObj->ctm != NULL) { int i; for (i=0; i < 4; i++) { int tmp_x=ABS_X(curTextObj->rotated_obbox[i].x); int tmp_y=ABS_Y(curTextObj->rotated_obbox[i].y); if (tmp_x < ltx) ltx = tmp_x; if (tmp_y < lty) lty = tmp_y; if (tmp_x > rbx) rbx = tmp_x; if (tmp_y > rby) rby = tmp_y; } } if (nRedraw) { ltx -= (curTextOutlineHalfW<<1); lty -= (curTextOutlineHalfW<<1); rbx += (curTextOutlineHalfW<<1); rby += (curTextOutlineHalfW<<1); RedrawAreasInCreateText(beforeEditTextInfo.bbox.ltx, beforeEditTextInfo.bbox.lty, beforeEditTextInfo.bbox.rbx, beforeEditTextInfo.bbox.rby, ltx, lty, rbx, rby); } } else { int x=0; switch (textJust) { case JUST_L: x = textOrigX+textAbsMinLBearing; break; case JUST_C: x = textOrigX-textW/2+textAbsMinLBearing; break; case JUST_R: x = textOrigX-textW+textAbsMinLBearing; break; } if (nRedraw) { ltx -= (curTextOutlineHalfW<<1); lty -= (curTextOutlineHalfW<<1); rbx += (curTextOutlineHalfW<<1); rby += (curTextOutlineHalfW<<1); RedrawAreasInCreateText(ltx, lty, rbx, rby, ABS_X(x-2), ABS_Y(textOrigY-2), ABS_X(x+textW-textAbsMinLBearing+textAbsMaxRExtra+3), ABS_Y(textOrigY+textH+3)); } } textOrigX = textOrigY = textCurX = textCurY = ABS_SIZE(20); SetEditTextArea(0, textCursorH, 0, 0); textAbsX = textOrigX + drawOrigX; textAbsY = textOrigY + drawOrigY; curTextObj = NULL; PopCurFont(); ShowTextRelatedInfo(); if (editingText) { editingText = FALSE; } else if (textRotation != 0) { int saved_rotation_increment=rotationIncrement; int saved_ltx=topObj->bbox.ltx, saved_lty=topObj->bbox.lty; int saved_rbx=topObj->bbox.rbx, saved_rby=topObj->bbox.rby; SetRotatePivotByObject(topObj); rotationIncrement = textRotation; RotateObjClockWise(topObj); rotationIncrement = saved_rotation_increment; if (nRedraw) { RedrawAreasInCreateText(saved_ltx, saved_lty, saved_rbx, saved_rby, topObj->bbox.ltx, topObj->bbox.lty, topObj->bbox.rbx, topObj->bbox.rby); } } curTextIsNew = FALSE; SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); curStrBlock = endStrBlock = NULL; textCurIndex = textEndIndex = INVALID; textHighlight = FALSE; if (saved_style != curStyle || saved_just != textJust || saved_underline_on != curUnderlineOn || saved_overline_on != curOverlineOn) { UpdatePinnedMenu(MENU_STYLE); } if (saved_font != curFont) UpdatePinnedMenu(MENU_FONT); if (saved_sz_unit != curSzUnit) UpdatePinnedMenu(MENU_SIZE); if (saved_color != colorIndex) UpdatePinnedMenu(MENU_COLOR); if (gstWBInfo.do_whiteboard) { int saved_text_drawn=textDrawn; textDrawn = FALSE; TryHandleWBInputData(); if (justDrawnTextObj != NULL && !IsTopLevelObject(justDrawnTextObj)) { justDrawnTextObj = NULL; textDrawn = FALSE; } else { textDrawn = saved_text_drawn; } SetCurChoice(DRAWTEXT); } curTextMovedAbsX = curTextMovedAbsY = 0; ClearCopyUTF8Info(); if (rightMarginEnabled == TRUE) { if (!rightMarginActive) { rightMarginActive = TRUE; RedrawHRulerWindow(); } } return TRUE; } static int CanAdvanceRight(pStrBlock, nIndex) StrBlockInfo *pStrBlock; int nIndex; { if (nIndex != pStrBlock->seg->dyn_str.sz-1) { return TRUE; } if (pStrBlock->type == SB_SUPSUB_CENTER) { return FALSE; } for (pStrBlock=pStrBlock->next; pStrBlock != NULL; pStrBlock=pStrBlock->next) { switch (pStrBlock->type) { case SB_SIMPLE: if (*pStrBlock->seg->dyn_str.s != '\0') { return TRUE; } break; case SB_CHAR_SPACE: return TRUE; case SB_SUPSUB_LEFT: return FALSE; case SB_SUPSUB_CENTER: return FALSE; case SB_SUPSUB_RIGHT: return FALSE; } } return FALSE; } static int CanAdvanceLeft(pStrBlock, nIndex) StrBlockInfo *pStrBlock; int nIndex; { if (nIndex != 0) { return TRUE; } if (pStrBlock->type == SB_SUPSUB_CENTER) { return FALSE; } for (pStrBlock=pStrBlock->prev; pStrBlock != NULL; pStrBlock=pStrBlock->prev) { switch (pStrBlock->type) { case SB_SIMPLE: if (*pStrBlock->seg->dyn_str.s != '\0') { return TRUE; } break; case SB_CHAR_SPACE: return TRUE; case SB_SUPSUB_LEFT: return FALSE; case SB_SUPSUB_CENTER: return FALSE; case SB_SUPSUB_RIGHT: return FALSE; } } return FALSE; } int AtBeginningOfInheritedAttrValue(obj_ptr, pStrBlock, nIndex) struct ObjRec *obj_ptr; StrBlockInfo *pStrBlock; int nIndex; { if (obj_ptr->type == OBJ_TEXT) { struct TextRec *text_ptr=obj_ptr->detail.t; struct AttrRec *attr_ptr=text_ptr->attr; if (attr_ptr != NULL && attr_ptr->inherited && attr_ptr->shown && attr_ptr->nameshown) { if (pStrBlock != NULL && pStrBlock->prev == NULL && pStrBlock->owner_mini_line == text_ptr->minilines.first) { if (nIndex <= attr_ptr->attr_name.sz-1) { return TRUE; } } } } return FALSE; } void HighLightJustDrawnText() { if (justDrawnTextObj == NULL) return; AddNewSelObj(justDrawnTextObj); UpdSelBBox(); HighLightAnObj(justDrawnTextObj); justDupped = FALSE; } void DelSelText() { if (textHighlight) { DeleteHighlightedText(); EndChangeCurText(FALSE); } } static int PrepareEditExistingText(obj_ptr, abs_x, abs_y, x_off, y_off) struct ObjRec *obj_ptr; int abs_x, abs_y, *x_off, *y_off; { struct TextRec *text_ptr=obj_ptr->detail.t; int orig_text_w=0, orig_text_h=0; if (text_ptr->read_only) { MsgBox(TgLoadString(STID_READ_ONLY_TEXT_CANT_BE_EDITED), TOOL_NAME, INFO_MB); return FALSE; } curTextObj = obj_ptr; memset(&beforeEditTextInfo, 0, sizeof(struct tagBeforeEditTextInfo)); memcpy(&beforeEditTextInfo.bbox, &obj_ptr->bbox, sizeof(struct BBRec)); memcpy(&beforeEditTextInfo.obbox, &obj_ptr->obbox, sizeof(struct BBRec)); beforeEditTextInfo.x = obj_ptr->x; beforeEditTextInfo.baseline_y = text_ptr->baseline_y; beforeEditTextInfo.first_mini_line_asc = text_ptr->minilines.first->asc; beforeEditTextInfo.obbox_w = orig_text_w = obj_ptr->obbox.rbx - obj_ptr->obbox.ltx; beforeEditTextInfo.obbox_h = orig_text_h = obj_ptr->obbox.rby - obj_ptr->obbox.lty; PushCurFont(); editingText = TRUE; ObjFontInfoToCurFontInfo(text_ptr); penPat = text_ptr->pen; objFill = text_ptr->fill; transPat = obj_ptr->trans_pat; SetEditTextArea(0, 0, 0, 0); colorIndex = obj_ptr->color; ShowTextRelatedInfo(); ResetOnCursorKey(FALSE); textAbsX = obj_ptr->x; textAbsY = obj_ptr->y; textAbsBaselineY = text_ptr->baseline_y; if (obj_ptr->ctm != NULL) { textAbsX += obj_ptr->ctm->t[CTM_TX]; textAbsY += obj_ptr->ctm->t[CTM_TY]; textAbsBaselineY += obj_ptr->ctm->t[CTM_TY]; } textOrigX = OFFSET_X(textAbsX); textOrigY = OFFSET_Y(textAbsY); textOrigBaselineY = textOrigY + text_ptr->baseline_y - obj_ptr->y; if (editTextSize != 0) { if (RestoreEditTextSize(obj_ptr, FALSE)) { UpdTextBBox(obj_ptr); } } if (obj_ptr->ctm == NULL) { SetEditTextArea(obj_ptr->obbox.rbx-obj_ptr->obbox.ltx, obj_ptr->obbox.rby-obj_ptr->obbox.lty, text_ptr->min_lbearing, text_ptr->max_rextra); switch (textJust) { case JUST_L: tmpAdjAbsX = ((orig_text_w-ABS_SIZE(textW))>>1); break; case JUST_C: tmpAdjAbsX = 0; break; case JUST_R: tmpAdjAbsX = ((ABS_SIZE(textW)-orig_text_w)>>1); break; } tmpAdjAbsY = ((orig_text_h-ABS_SIZE(textH))>>1); } else { int abs_w=0, abs_h=0; int orig_2_xc=(beforeEditTextInfo.obbox.ltx+beforeEditTextInfo.obbox.rbx); int orig_2_yc=(beforeEditTextInfo.obbox.lty+beforeEditTextInfo.obbox.rby); SetEditTextArea(obj_ptr->orig_obbox.rbx-obj_ptr->orig_obbox.ltx, obj_ptr->orig_obbox.rby-obj_ptr->orig_obbox.lty, text_ptr->min_lbearing, text_ptr->max_rextra); abs_w = ABS_SIZE(textW); abs_h = ABS_SIZE(textH); switch (textJust) { case JUST_L: tmpAdjAbsX = ((orig_2_xc-abs_w)>>1)-textAbsX; break; case JUST_C: tmpAdjAbsX = ((orig_2_xc)>>1) - textAbsX; break; case JUST_R: tmpAdjAbsX = ((orig_2_xc+abs_w)>>1)-textAbsX; break; } tmpAdjAbsY = ((orig_2_yc - abs_h)>>1) - textAbsY; } textAbsX += tmpAdjAbsX; textAbsY += tmpAdjAbsY; textAbsBaselineY += tmpAdjAbsY; textOrigX = OFFSET_X(textAbsX); textOrigY = OFFSET_Y(textAbsY); textOrigBaselineY = textOrigY + text_ptr->baseline_y - obj_ptr->y; if (obj_ptr->ctm == NULL) { abs_x += tmpAdjAbsX; abs_y += tmpAdjAbsY; } else { int x, y, dx=0; ReverseTransformPointThroughCTM(abs_x-obj_ptr->x, abs_y-obj_ptr->y, obj_ptr->ctm, &x, &y); abs_x = obj_ptr->x + x; abs_y = obj_ptr->y + y; switch (textJust) { case JUST_L: break; case JUST_C: dx = (textW>>1); break; case JUST_R: dx = textW; break; } abs_x += textAbsX - obj_ptr->orig_obbox.ltx - dx; abs_y += textAbsY - obj_ptr->orig_obbox.lty; } *x_off = OFFSET_X(abs_x); *y_off = OFFSET_Y(abs_y); if (editTextSize != 0) { if (RestoreEditTextSize(curTextObj, TRUE)) { UpdTextBBox(curTextObj); } } if (outerSel != NULL) { PrepareToReplaceAnObj(outerSel->obj); } else if (text_ptr->attr == NULL) { PrepareToReplaceAnObj(obj_ptr); } else { PrepareToReplaceAnObj(text_ptr->attr->owner); } if (editTextSize != 0) { if (RestoreEditTextSize(curTextObj, FALSE)) { UpdTextBBox(curTextObj); } } SetEditTextArea(textW, textH, text_ptr->minilines.min_lbearing, text_ptr->minilines.max_rextra); UpdateCurTextBBoxes(TRUE); if (gstWBInfo.do_whiteboard) { gstWBInfo.BlockRemoteCmdDepth++; } curTextMovedAbsX = curTextMovedAbsY = 0; return TRUE; } static int BeginAdvance(drag, dir, ppStrBlock, pnCurIndex) int drag, *pnCurIndex, dir; StrBlockInfo **ppStrBlock; { int position_end=FALSE; if (drag) { if (textHighlight) { *ppStrBlock = endStrBlock; *pnCurIndex = textEndIndex; } else { *ppStrBlock = curStrBlock; *pnCurIndex = textCurIndex; } position_end = TRUE; } else { if (textHighlight) { textHighlight = FALSE; } if (dir == ADVANCE_RIGHT && endStrBlock != NULL) { *ppStrBlock = endStrBlock; *pnCurIndex = textEndIndex; position_end = TRUE; } else { *ppStrBlock = curStrBlock; *pnCurIndex = textCurIndex; } } return position_end; } static void EndAdvance(position_end, pStrBlock, nCurIndex) int position_end, nCurIndex; StrBlockInfo *pStrBlock; { if (position_end) { endStrBlock = pStrBlock; textEndIndex = nCurIndex; SetTextEndXY(); } else { curStrBlock = pStrBlock; textCurIndex = nCurIndex; SetTextCurXY(); } } static int PartOfAWord(double_byte, ch) int double_byte; char ch; { if (double_byte) { return TRUE; } return (ch == '_' || (ch >= '0' && ch <= '9') || (ch >= 'a' && ch <= 'z') || (ch >= 'A' && ch <= 'Z')); } #include "xbm/text_cur.xbm" static int GetCursorPositionInCurText(x_off, y_off, use_abs, pn_abs_dx, pn_abs_baseline_dy, ppStrBlock, pnIndex) int x_off, y_off, use_abs, *pn_abs_dx, *pn_abs_baseline_dy, *pnIndex; StrBlockInfo **ppStrBlock; /* * returns -1 if caller needs to figure out where the beginning is * returns 0 if *pn_abs_dx and *pn_abs_baseline_dy are set * returns 1 if caller needs to figure out where the end is */ { struct TextRec *text_ptr=curTextObj->detail.t; int x=0, y=0, orig_x=0, baseline_y=0, dx=0, dy=0, rc=TRUE; if (use_abs) { x = ABS_X(x_off); y = ABS_Y(y_off); orig_x = textAbsX; baseline_y = textAbsBaselineY; } else { x = x_off; y = y_off; orig_x = textOrigX; baseline_y = textOrigBaselineY; } if (y < baseline_y-text_ptr->minilines.first->des-(text_cur_height>>1)) { if (text_cur_bits == NULL) { } /* no compiler warning */ return INVALID; } PushCurFont(); rc = GetCursorPositionInMiniLines(&text_ptr->minilines, x-orig_x, y-baseline_y, &dx, &dy, ppStrBlock, pnIndex); PopCurFont(); if (rc == 0) { *pn_abs_dx = dx; *pn_abs_baseline_dy = dy; } return rc; } static void HandleClickOnCanvas(x_off, y_off) int x_off, y_off; { if (SzUnitToFontSize(curSzUnit) != canvasFontSize) { sprintf(gszMsgBox, TgLoadString(STID_TEXT_SZ_NOT_AVAIL_TRY_DIFF), SzUnitToFontSize(curSzUnit)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { int grid_x=0, grid_y=0; GridXY(x_off, y_off, &grid_x, &grid_y); textOrigX = grid_x; textOrigBaselineY = grid_y; textOrigY = textOrigBaselineY-canvasFontAsc; textAbsMinLBearing = 0; textAbsMaxRExtra = 0; textAbsX = ABS_X(grid_x); textAbsBaselineY = ABS_Y(grid_y); textAbsY = textAbsBaselineY-canvasFontAsc; tmpAdjAbsX = tmpAdjAbsY = 0; curTextMovedAbsX = curTextMovedAbsY = 0; NewCurText(); RedrawCurText(); UpdateTextInfoChoices(TRUE); if (editTextSize != 0 && curStrBlock != NULL && (curStrBlock->type == SB_SIMPLE || curStrBlock->type == SB_SUPSUB_CENTER)) { CurFontMsg(FALSE, TRUE, curStrBlock->seg); } else { CurFontMsg(FALSE, TRUE, NULL); } if (gstWBInfo.do_whiteboard) { gstWBInfo.BlockRemoteCmdDepth++; } PrepareToReplaceAnObj(curTextObj); } } static void AdjTextIndicesForInheritedAttr() { if (AtBeginningOfInheritedAttrValue(curTextObj, curStrBlock, textCurIndex)) { textCurIndex = curTextObj->detail.t->attr->attr_name.sz-1; SetTextCurXY(); } if (AtBeginningOfInheritedAttrValue(curTextObj, endStrBlock, textEndIndex)) { textEndIndex = curTextObj->detail.t->attr->attr_name.sz-1; SetTextEndXY(); } } static void AdvanceForDoubleClickOnWord(double_byte) int double_byte; { char *psz=(curStrBlock->seg->dyn_str.s); int len=(curStrBlock->seg->dyn_str.sz-1); int step=(double_byte ? 2 : 1); for ( ; textCurIndex > 0 && PartOfAWord(double_byte, psz[textCurIndex-step]); textCurIndex-=step) { } for (endStrBlock=curStrBlock, textEndIndex=textCurIndex; textEndIndex < len && PartOfAWord(double_byte, psz[textEndIndex]); textEndIndex+=step) { } } static void AdvanceForDoubleClickOnSpaceChar() { char *psz=(curStrBlock->seg->dyn_str.s); int len=(curStrBlock->seg->dyn_str.sz-1); for ( ; textCurIndex > 0 && psz[textCurIndex-1] == ' '; textCurIndex--) { } for (endStrBlock=curStrBlock, textEndIndex=textCurIndex; textEndIndex < len && psz[textEndIndex] == ' '; textEndIndex++) { } } static void AdvanceForDoubleClickOnText() { char cur_char=curStrBlock->seg->dyn_str.s[textCurIndex]; int double_byte=curStrBlock->seg->double_byte; int select_word=PartOfAWord(double_byte, cur_char); if (select_word) { AdvanceForDoubleClickOnWord(double_byte); } else { AdvanceForDoubleClickOnSpaceChar(); } } static void SetTextIndices(drag, x_off, y_off, pressed_in_same_text) int drag, x_off, y_off, pressed_in_same_text; { MiniLinesInfo *minilines=(&curTextObj->detail.t->minilines); StrBlockInfo *pStrBlock=NULL; int index=INVALID, position_end=FALSE; int abs_dx=0, abs_baseline_dy=0; position_end = BeginAdvance(drag, INVALID, &pStrBlock, &index); switch (GetCursorPositionInCurText(x_off, y_off, !pressed_in_same_text, &abs_dx, &abs_baseline_dy, &pStrBlock, &index)) { case 0: if (position_end) { textEndX = textOrigX + abs_dx; textEndBaselineY = textOrigBaselineY + abs_baseline_dy; endStrBlock = pStrBlock; textEndIndex = index; } else { textCurX = textOrigX + abs_dx; textCurBaselineY = textOrigBaselineY + abs_baseline_dy; curStrBlock = pStrBlock; textCurIndex = index; } break; case 1: pStrBlock = minilines->last->last_block; index = pStrBlock->seg->dyn_str.sz-1;; if (position_end) { endStrBlock = pStrBlock; textEndIndex = index; } else { curStrBlock = pStrBlock; textCurIndex = index; } EndAdvance(position_end, pStrBlock, index); break; case (-1): pStrBlock = minilines->first->first_block; index = 0; if (position_end) { endStrBlock = pStrBlock; textEndIndex = index; } else { curStrBlock = pStrBlock; textCurIndex = index; } EndAdvance(position_end, pStrBlock, index); break; } AdjTextIndicesForInheritedAttr(); } static void AdvanceStrBlockToParentBlock(advance_left, position_end) int advance_left, position_end; { MiniLinesInfo *pOwnerMinilines=NULL; if (advance_left) { if (position_end) { if (endStrBlock->type == SB_SUPSUB_CENTER) { endStrBlock = endStrBlock->prev; } else { pOwnerMinilines = endStrBlock->owner_mini_line->owner_minilines; endStrBlock = pOwnerMinilines->owner_block->prev; } textEndIndex = (endStrBlock->seg->dyn_str.sz-1); SetTextEndXY(); } else { if (curStrBlock->type == SB_SUPSUB_CENTER) { curStrBlock = curStrBlock->prev; } else { pOwnerMinilines = curStrBlock->owner_mini_line->owner_minilines; curStrBlock = pOwnerMinilines->owner_block->prev; } textCurIndex = (curStrBlock->seg->dyn_str.sz-1); SetTextCurXY(); } } else { if (position_end) { if (endStrBlock->type == SB_SUPSUB_CENTER) { endStrBlock = endStrBlock->next; } else { pOwnerMinilines = endStrBlock->owner_mini_line->owner_minilines; endStrBlock = pOwnerMinilines->owner_block->next; } textEndIndex = 0; SetTextEndXY(); } else { if (curStrBlock->type == SB_SUPSUB_CENTER) { curStrBlock = curStrBlock->next; } else { pOwnerMinilines = curStrBlock->owner_mini_line->owner_minilines; curStrBlock = pOwnerMinilines->owner_block->next; } textCurIndex = 0; SetTextCurXY(); } } } static int FindStrBlockPosInMiniline(pMiniline, pStrBlockTarget, pnPos) MiniLineInfo *pMiniline; StrBlockInfo *pStrBlockTarget; int *pnPos; { StrBlockInfo *psbi=NULL; for (psbi=pMiniline->first_block; psbi != NULL; psbi=psbi->next) { if (pnPos != NULL) (*pnPos)++; if (psbi->type == SB_SIMPLE) { if (psbi == pStrBlockTarget) { return TRUE; } } } return FALSE; } static int FindStrBlockPosInMinilines(pMinilines, pStrBlockTarget) MiniLinesInfo *pMinilines; StrBlockInfo *pStrBlockTarget; { MiniLineInfo *pMiniline=NULL; int pos=0; for (pMiniline=pMinilines->first; pMiniline != NULL; pMiniline=pMiniline->next) { if (FindStrBlockPosInMiniline(pMiniline, pStrBlockTarget, &pos)) { return pos; } } return 0; } void SwitchTextCurAndEndStrBlocks() { StrBlockInfo *pStrBlock=curStrBlock; int index=textCurIndex; curStrBlock = endStrBlock; textCurIndex = textEndIndex; endStrBlock = pStrBlock; textEndIndex = index; SetTextCurXY(); SetTextEndXY(); } int FixHighlightedStrBlockDepths() { if (!textHighlight) { return 0; } else if (curStrBlock->depth == endStrBlock->depth) { if (curStrBlock->owner_mini_line->owner_minilines == endStrBlock->owner_mini_line->owner_minilines) { if (curStrBlock == endStrBlock) { return textEndIndex - textCurIndex; } else { int cur_count = FindStrBlockPosInMinilines( curStrBlock->owner_mini_line->owner_minilines, curStrBlock); int end_count = FindStrBlockPosInMinilines( curStrBlock->owner_mini_line->owner_minilines, endStrBlock); #ifdef _TGIF_DBG TgAssert(cur_count!=end_count, "cur_count==end_count in FixHighlightedStrBlockDepths()", NULL); #endif /* _TGIF_DBG */ return end_count - cur_count; } } } if (curStrBlock->depth < endStrBlock->depth) { /* move endStrBlock */ while (curStrBlock->depth < endStrBlock->depth) { if (curStrBlock->pre_order < endStrBlock->pre_order) { /* move endStrBlock to the right */ AdvanceStrBlockToParentBlock(ADVANCE_RIGHT, POSITION_END); } else { /* move endStrBlock to the left */ AdvanceStrBlockToParentBlock(ADVANCE_LEFT, POSITION_END); } } } else if (curStrBlock->depth > endStrBlock->depth) { /* move curStrBlock */ while (curStrBlock->depth > endStrBlock->depth) { if (curStrBlock->pre_order < endStrBlock->pre_order) { /* move curStrBlock to the left */ AdvanceStrBlockToParentBlock(ADVANCE_LEFT, POSITION_CUR); } else { /* move curStrBlock to the right */ AdvanceStrBlockToParentBlock(ADVANCE_RIGHT, POSITION_CUR); } } } if (curStrBlock->depth == endStrBlock->depth) { while (curStrBlock->owner_mini_line->owner_minilines != endStrBlock->owner_mini_line->owner_minilines) { if (curStrBlock->pre_order < endStrBlock->pre_order) { /* move curStrBlock to the left and endStrBlock to the right */ AdvanceStrBlockToParentBlock(ADVANCE_LEFT, POSITION_CUR); AdvanceStrBlockToParentBlock(ADVANCE_RIGHT, POSITION_END); } else { /* move curStrBlock to the right and endStrBlock to the left */ AdvanceStrBlockToParentBlock(ADVANCE_LEFT, POSITION_END); AdvanceStrBlockToParentBlock(ADVANCE_RIGHT, POSITION_CUR); } } } else { /* Should not get here! */ } return 0; } static Time lastClickTime=(Time)0; static int textJustClicked=FALSE; static void DragButtonOnText() { StrBlockInfo *pStrBlock=endStrBlock; int index=textEndIndex, done=FALSE; if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, textCursor, CurrentTime); } SetTextHighlight(); FixHighlightedStrBlockDepths(); UpdatePinnedMenu(MENU_EDIT); RedrawCurText(); UpdateHighLightedTextBBoxes(TRUE); while (!done) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); done = TRUE; } else if (input.type == MotionNotify) { XEvent ev; int x_off=input.xmotion.x; int y_off=input.xmotion.y; SetTextIndices(TRUE, x_off, y_off, TRUE); if (pStrBlock != endStrBlock || index != textEndIndex) { SetTextHighlight(); FixHighlightedStrBlockDepths(); UpdatePinnedMenu(MENU_EDIT); UpdateHighLightedTextBBoxes(FALSE); RedrawCurText(); UpdateHighLightedTextBBoxes(TRUE); pStrBlock = endStrBlock; index = textEndIndex; } while (XCheckMaskEvent(mainDisplay,PointerMotionMask,&ev)) ; } } } static void AdjustTextHighlight(drag, saved_text_highlight, update_highlighted_text_bboxes) int drag, saved_text_highlight, update_highlighted_text_bboxes; { SetTextHighlight(); if (!drag) { int rc=FixHighlightedStrBlockDepths(); if (rc < 0) { SwitchTextCurAndEndStrBlocks(); } } else if (curStrBlock != NULL && endStrBlock != NULL && curStrBlock->depth != endStrBlock->depth) { int rc=FixHighlightedStrBlockDepths(); if (rc < 0) { SwitchTextCurAndEndStrBlocks(); } } UpdatePinnedMenu(MENU_EDIT); if (update_highlighted_text_bboxes) { UpdateHighLightedTextBBoxes(FALSE); } if (textCursorShown && !saved_text_highlight && !drag) { PutTextCursor(); } else { RedrawCurText(); } ScrollTo(textCurX, textCurBaselineY); } static void HandleClickOnText(drag, from_cursor_keys, x_off, y_off, pressed_in_same_text, obj_ptr, double_clicked, saved_text_highlight, skip_post_processing, click_time) int drag, from_cursor_keys, x_off, y_off, pressed_in_same_text; int double_clicked, saved_text_highlight; struct ObjRec *obj_ptr; Time click_time; { SetTextIndices(drag, x_off, y_off, pressed_in_same_text); textCursorShown = TRUE; if (gnInputMethod != TGIM_NONE) { if (!tgIMHandleNewCurText(mainDisplay, drawWindow)) { } } if (double_clicked) { ResetOnCursorKey(FALSE); SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); AdvanceForDoubleClickOnText(); SetTextCurXY(); SetTextEndXY(); textJustClicked = FALSE; } else if (!from_cursor_keys) { textJustClicked = TRUE; lastClickTime = click_time; DragButtonOnText(); } if (!skip_post_processing) { AdjustTextHighlight(drag, saved_text_highlight, from_cursor_keys || double_clicked); } } static void HandleButton(Button_Ev) XButtonEvent *Button_Ev; { int x_off=0, y_off=0, update_highlighted_text_bboxes=FALSE; if (!textCursorShown) { ClearCopyUTF8Info(); } escPressed = FALSE; if (Button_Ev->button == Button1 && !(Button_Ev->state & (ShiftMask|ControlMask))) { struct ObjRec *obj_ptr=NULL; int pressed_in_same_text=FALSE, x=0, abs_x=0, abs_y=0; x_off = Button_Ev->x; abs_x = ABS_X(x_off); y_off = Button_Ev->y; abs_y = ABS_Y(y_off); if (textCursorShown) { switch (curTextObj->detail.t->minilines.just) { case JUST_L: x = textOrigX-2; break; case JUST_C: x = textOrigX-textW/2-2; break; case JUST_R: x = textOrigX-textW-2; break; } if (x_off >= x && x_off <= x+textW+4 && y_off >= textOrigY-2 && y_off <= textOrigY+textH+2) { pressed_in_same_text = TRUE; if (textHighlight) { UpdateHighLightedTextBBoxes(TRUE); update_highlighted_text_bboxes = TRUE; } else { EraseTextCursor(); } } else { CreateTextObj(TRUE, TRUE); /* end editing on the old text */ curTextModified = FALSE; } } else { editingText = FALSE; curTextModified = FALSE; } ResetOnCursorKey(FALSE); if (!pressed_in_same_text && (obj_ptr=FindTextObj(x_off, y_off, NULL)) == NULL) { /* cursor not within any existing text object */ HandleClickOnCanvas(x_off, y_off); } else { /* cursor inside an existing text object */ Time click_time=Button_Ev->time; int double_clicked=FALSE; double_clicked = (pressed_in_same_text && textJustClicked && (click_time-lastClickTime) < doubleClickInterval); if (pressed_in_same_text) { obj_ptr = curTextObj; if (textJustClicked && (click_time-lastClickTime) < doubleClickInterval) { double_clicked = TRUE; } } else { if (!PrepareEditExistingText(obj_ptr, abs_x, abs_y, &x_off, &y_off)) { return; } } if (!update_highlighted_text_bboxes && curStrBlock != NULL) { UpdateHighLightedTextBBoxes(TRUE); } HandleClickOnText(FALSE, FALSE, x_off, y_off, pressed_in_same_text, obj_ptr, double_clicked, TRUE, FALSE, click_time); UpdateTextInfoChoices(TRUE); } } else if (Button_Ev->button == Button1 && (Button_Ev->state & (ShiftMask|ControlMask))) { if (!textCursorShown) return; x_off = Button_Ev->x; y_off = Button_Ev->y; if (curStrBlock != NULL) UpdateHighLightedTextBBoxes(TRUE); HandleClickOnText(TRUE, FALSE, x_off, y_off, TRUE, curTextObj, FALSE, TRUE, FALSE, (Time)0); UpdateTextInfoChoices(FALSE); } } static void AdvanceRight(drag) int drag; { StrBlockInfo *pStrBlock=NULL; int index=INVALID, position_end=FALSE; int done=FALSE, something_skipped=FALSE; position_end = BeginAdvance(drag, ADVANCE_RIGHT, &pStrBlock, &index); while (!done) { switch (pStrBlock->type) { case SB_SIMPLE: case SB_SUPSUB_CENTER: if (something_skipped) { done = TRUE; } else if (index < pStrBlock->seg->dyn_str.sz-1) { if (pStrBlock->seg->double_byte) { index += 2; } else { index++; } done = TRUE; } break; default: something_skipped = TRUE; break; } if (done) { EndAdvance(position_end, pStrBlock, index); } else if (pStrBlock->next == NULL) { MiniLineInfo *owner_mini_line=pStrBlock->owner_mini_line; MiniLinesInfo *owner_minilines=owner_mini_line->owner_minilines; if (owner_mini_line->next == NULL && owner_minilines->owner_block != NULL && owner_minilines->owner_block->next != NULL) { pStrBlock = owner_minilines->owner_block->next; something_skipped = TRUE; } else { done = TRUE; } } else { if (pStrBlock->type == SB_SUPSUB_CENTER) { pStrBlock = pStrBlock->next; something_skipped = TRUE; } else { pStrBlock = pStrBlock->next; if (pStrBlock->type == SB_SUPSUB_CENTER) { pStrBlock = pStrBlock->next; something_skipped = TRUE; } } } if (!done) { if (pStrBlock->type == SB_SIMPLE) { index = 0; } } } } static void AdvanceLeft(drag) int drag; { StrBlockInfo *pStrBlock=NULL; int index=INVALID, position_end=FALSE; int done=FALSE, something_skipped=FALSE; position_end = BeginAdvance(drag, ADVANCE_LEFT, &pStrBlock, &index); while (!done) { switch (pStrBlock->type) { case SB_SIMPLE: case SB_SUPSUB_CENTER: if (something_skipped) { done = TRUE; } else if (index != 0) { if (pStrBlock->seg->double_byte) { index -= 2; } else { index--; } done = TRUE; } break; default: something_skipped = TRUE; break; } if (done) { EndAdvance(position_end, pStrBlock, index); } else if (pStrBlock->prev == NULL) { MiniLineInfo *owner_mini_line=pStrBlock->owner_mini_line; MiniLinesInfo *owner_minilines=owner_mini_line->owner_minilines; if (owner_mini_line->prev == NULL && owner_minilines->owner_block != NULL) { pStrBlock = owner_minilines->owner_block->prev; something_skipped = TRUE; } else { done = TRUE; } } else { if (pStrBlock->type == SB_SUPSUB_CENTER) { pStrBlock = pStrBlock->prev; something_skipped = TRUE; } else { pStrBlock = pStrBlock->prev; if (pStrBlock->type == SB_SUPSUB_CENTER) { pStrBlock = pStrBlock->prev; something_skipped = TRUE; } } } if (!done) { if (pStrBlock->type == SB_SIMPLE) { index = pStrBlock->seg->dyn_str.sz-1; } } } AdjTextIndicesForInheritedAttr(); } static void InsertCRLFIntoCurText() { MiniLineInfo *pNewMiniLine=NewMiniLine(); MiniLineInfo *owner_mini_line=curStrBlock->owner_mini_line; MiniLinesInfo *minilines=owner_mini_line->owner_minilines; StrBlockInfo *pStrBlock=NULL, *pRightStrBlock=NULL; char *psz=UtilStrDup(curStrBlock->seg->dyn_str.s), saved_ch='\0'; if (psz == NULL) FailAllocMessage(); DupStrBlock(curStrBlock, owner_mini_line, &pRightStrBlock, &pRightStrBlock); saved_ch = psz[textCurIndex]; psz[textCurIndex] = '\0'; DynStrSet(&curStrBlock->seg->dyn_str, psz); psz[textCurIndex] = saved_ch; DynStrSet(&pRightStrBlock->seg->dyn_str, &psz[textCurIndex]); UtilFree(psz); pRightStrBlock->next = curStrBlock->next; if (curStrBlock->next != NULL) { curStrBlock->next->prev = pRightStrBlock; } curStrBlock->next = NULL; owner_mini_line->last_block = curStrBlock; pNewMiniLine->owner_minilines = minilines; InsertMiniLine(owner_mini_line, owner_mini_line->next, pNewMiniLine, &minilines->first, &minilines->last); pNewMiniLine->first_block = pNewMiniLine->last_block = pRightStrBlock; pRightStrBlock->prev = NULL; for (pStrBlock=pRightStrBlock; pStrBlock != NULL; pStrBlock=pStrBlock->next) { pNewMiniLine->last_block = pStrBlock; pStrBlock->owner_mini_line = pNewMiniLine; } curStrBlock = pRightStrBlock; textCurIndex = 0; ResetOnCursorKey(FALSE); SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); } static void DoMoveTextCursorToNextMiniLine() { int saved_text_highlight=textHighlight; MiniLineInfo *owner_mini_line=curStrBlock->owner_mini_line; MiniLinesInfo *owner_minilines=owner_mini_line->owner_minilines; if (textCursorShown && !saved_text_highlight) { EraseTextCursor(); } UpdateHighLightedTextBBoxes(TRUE); if (owner_mini_line->next == NULL) { curStrBlock = owner_minilines->first->first_block; } else { curStrBlock = owner_mini_line->next->first_block; } textCurIndex = 0; ResetOnCursorKey(FALSE); SetTextCurXY(); SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); if (textCursorShown && !saved_text_highlight) { PutTextCursor(); } else { RedrawCurText(); } MarkRulers(textCurX, textCurY); ScrollTo(textCurX, textCurBaselineY); UpdateTextInfoChoices(FALSE); } static void HandleCRLF(key_ev) XKeyEvent *key_ev; { int cycle=(key_ev != NULL && (key_ev->state & ControlMask) != 0); escPressed = FALSE; if (cycle) { if (curStrBlock->type != SB_SUPSUB_CENTER) { DoMoveTextCursorToNextMiniLine(); } return; } if (curStrBlock->type == SB_SUPSUB_CENTER) { return; } curTextModified = TRUE; if (textHighlight) { DeleteHighlightedText(); EndChangeCurText(FALSE); } InsertCRLFIntoCurText(); EndChangeCurText(TRUE); if (!gnDontRedrawDuringPaste) { ScrollTo(textCurX, textCurBaselineY); } else { gnPastingLineNum++; sprintf(gszMsgBox, TgLoadCachedString(CSTID_PASTING_LINE_NUM_DOTS), gnPastingLineNum+1); SetStringStatus(gszMsgBox); } } static void HandleBS(key_ev, buf, key_sym, pn_has_char) XKeyEvent *key_ev; char *buf; KeySym key_sym; int *pn_has_char; { struct AttrRec *attr_ptr=NULL; int merged_lines=FALSE; int nDeleteNextChar=(deleteNextCharWithDelKey && CharIsDEL(key_ev, buf, key_sym, pn_has_char)) || (!deleteNextCharWithDelKey && (key_ev != NULL && (key_ev->state & (ControlMask | ShiftMask)) && !((key_ev->state & ControlMask) && (key_sym == XK_h)))); escPressed = FALSE; if (textHighlight) { DeleteHighlightedText(); EndChangeCurText(FALSE); return; } attr_ptr = curTextObj->detail.t->attr; if (nDeleteNextChar) { if (CanAdvanceRight(curStrBlock, textCurIndex)) { AdvanceRight(TRUE); } else if (curStrBlock->next == NULL) { MiniLineInfo *pNextMiniLine=curStrBlock->owner_mini_line->next; if (pNextMiniLine == NULL) { return; } endStrBlock = pNextMiniLine->first_block; textEndIndex = 0; merged_lines = TRUE; } else { return; } SetTextHighlight(); DeleteHighlightedText(); if (merged_lines) { ResetDirtyBBoxInfo(); } EndChangeCurText(merged_lines); UpdatePinnedMenu(MENU_EDIT); return; } if (AtBeginningOfInheritedAttrValue(curTextObj, curStrBlock, textCurIndex)) { return; } curTextModified = TRUE; if (textCurIndex != 0) { StrSegInfo *pStrSeg=curStrBlock->seg; int i=0, step=(pStrSeg->double_byte ? 2 : 1); char *psz=curStrBlock->seg->dyn_str.s; for (i=textCurIndex; i < pStrSeg->dyn_str.sz; i+=step) { if (step == 1) { psz[i-1] = psz[i]; } else { psz[i-2] = psz[i]; psz[i-1] = psz[i+1]; } } textCurIndex -= step; pStrSeg->dyn_str.sz -= step; } else { if (CanAdvanceLeft(curStrBlock, textCurIndex)) { AdvanceLeft(TRUE); } else if (curStrBlock->prev == NULL) { MiniLineInfo *pNextMiniLine=curStrBlock->owner_mini_line->prev; if (pNextMiniLine == NULL) { return; } endStrBlock = pNextMiniLine->last_block; textEndIndex = endStrBlock->seg->dyn_str.sz-1; merged_lines = TRUE; } else { return; } SetTextHighlight(); DeleteHighlightedText(); UpdatePinnedMenu(MENU_EDIT); } if (merged_lines) { ResetDirtyBBoxInfo(); } EndChangeCurText(merged_lines); } static int InsertSingleByteCharIntoCurText(Str) char *Str; { MiniLineInfo *owner_mini_line=curStrBlock->owner_mini_line; StrBlockInfo *pLeftStrBlock=NULL; DupStrBlock(curStrBlock, owner_mini_line, &pLeftStrBlock, &pLeftStrBlock); pLeftStrBlock->seg->double_byte = FALSE; pLeftStrBlock->seg->font = defaultSingleByteFont; DynStrSet(&pLeftStrBlock->seg->dyn_str, Str); pLeftStrBlock->clean = FALSE; if (textCurIndex == 0 && curStrBlock->prev != NULL && curStrBlock->prev->type == SB_SIMPLE && !curStrBlock->prev->seg->double_byte && StrBlocksHasSameProperties(pLeftStrBlock, curStrBlock->prev)) { /* just add the current char to curStrBlock->prev */ char *psz=(char*)malloc(curStrBlock->prev->seg->dyn_str.sz+1); if (psz == NULL) FailAllocMessage(); sprintf(psz, "%s%s", curStrBlock->prev->seg->dyn_str.s, Str); DynStrSet(&curStrBlock->prev->seg->dyn_str, psz); curStrBlock->prev->clean = FALSE; UtilFree(psz); FreeStrBlock(pLeftStrBlock); return TRUE; } if (textCurIndex != 0) { StrBlockInfo *pDupStrBlock=NULL; DupStrBlock(curStrBlock, owner_mini_line, &pDupStrBlock, &pDupStrBlock); pDupStrBlock->seg->dyn_str.s[textCurIndex] = '\0'; DynStrSet(&pDupStrBlock->seg->dyn_str, pDupStrBlock->seg->dyn_str.s); DynStrSet(&curStrBlock->seg->dyn_str, &curStrBlock->seg->dyn_str.s[textCurIndex]); pDupStrBlock->prev = curStrBlock->prev; if (curStrBlock->prev == NULL) { owner_mini_line->first_block = pDupStrBlock; } else { curStrBlock->prev->next = pDupStrBlock; } pDupStrBlock->next = curStrBlock; curStrBlock->prev = pDupStrBlock; curStrBlock->clean = pDupStrBlock->clean = FALSE; textCurIndex = 0; } pLeftStrBlock->prev = curStrBlock->prev; if (curStrBlock->prev == NULL) { owner_mini_line->first_block = pLeftStrBlock; } else { curStrBlock->prev->next = pLeftStrBlock; } pLeftStrBlock->next = curStrBlock; curStrBlock->prev = pLeftStrBlock; return TRUE; } static int InsertCharIntoCurText(Str, double_byte) char *Str; int double_byte; { if (curStrBlock->seg->double_byte && !double_byte) { if (curStrBlock->type == SB_SUPSUB_CENTER) { MsgBox(TgLoadString(STID_CANT_INS_NON_DB_CH_AT_CUR_REM), TOOL_NAME, INFO_MB); return FALSE; } else { InsertSingleByteCharIntoCurText(Str); } } else { char *buf=NULL; int cur_index_is_last=(textCurIndex==curStrBlock->seg->dyn_str.sz-1); if (lengthLimit256InInsertChar && curStrBlock->seg->dyn_str.sz-1+(double_byte ? 2 : 1) >= MAXSTRING) { sprintf(gszMsgBox, TgLoadString(STID_STR_EXCEEDS_NUM_CH_IGNORED), MAXSTRING); Msg(gszMsgBox); return FALSE; } buf = (char*)malloc((curStrBlock->seg->dyn_str.sz+7)*sizeof(char)); if (buf == NULL) FailAllocMessage(); if (double_byte) { char tmp_s[3]; tmp_s[0] = curStrBlock->seg->dyn_str.s[textCurIndex]; curStrBlock->seg->dyn_str.s[textCurIndex] = '\0'; if (tmp_s[0] != '\0') { tmp_s[1] = curStrBlock->seg->dyn_str.s[textCurIndex+1]; curStrBlock->seg->dyn_str.s[textCurIndex+1] = '\0'; sprintf(buf, "%s%c%c%c%c%s", curStrBlock->seg->dyn_str.s, Str[0], Str[1], tmp_s[0], tmp_s[1], (cur_index_is_last ? "" : (&curStrBlock->seg->dyn_str.s[textCurIndex+2]))); } else { sprintf(buf, "%s%c%c", curStrBlock->seg->dyn_str.s, Str[0], Str[1]); } textCurIndex += 2; } else { char tmp_char=curStrBlock->seg->dyn_str.s[textCurIndex]; curStrBlock->seg->dyn_str.s[textCurIndex] = '\0'; sprintf(buf, "%s%c%c%s", curStrBlock->seg->dyn_str.s, *Str, tmp_char, (cur_index_is_last ? "" : (&curStrBlock->seg->dyn_str.s[textCurIndex+1]))); textCurIndex++; } DynStrSet(&curStrBlock->seg->dyn_str, buf); curStrBlock->clean = FALSE; free(buf); } EndChangeCurText(FALSE); return TRUE; } static int SwitchToSingleOrDoubleByteFont(pStrSeg) StrSegInfo *pStrSeg; { int saved_sz_unit=curSzUnit, saved_font=curFont, saved_style=curStyle; if (!(curChoice == DRAWTEXT && textCursorShown)) { TieLooseEnds(); } curFont = pStrSeg->font; curStyle = pStrSeg->style; curSzUnit = pStrSeg->sz_unit; if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { curSzUnit = GetCurSzUnit(); } allowFontFaceSubstitution = FALSE; SetCanvasFont(); allowFontFaceSubstitution = TRUE; if (canvasFontSize == INVALID) { char buf[MAXSTRING]; GetCurFontMsg(buf, NULL); curFont = saved_font; curStyle = saved_style; curSzUnit = saved_sz_unit; SetCanvasFont(); sprintf(gszMsgBox, TgLoadString(STID_FONT_NOT_AVAILABLE), buf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (SzUnitToFontSize(curSzUnit) != canvasFontSize) { if (showFontSizeInPoints) { sprintf(gszMsgBox, TgLoadString(STID_CANT_CHANGE_SIZEPT_TO_USE_ALT), SzUnitToPointSize(curSzUnit), SzUnitToPointSize(FontSizeToSzUnit(canvasFontSize))); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_CHANGE_SIZE_TO_USE_ALT), SzUnitToFontSize(curSzUnit), canvasFontSize); } curSzUnit = FontSizeToSzUnit(canvasFontSize); if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { PutCurSzUnit(curSzUnit); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { PutCurSzUnit(curSzUnit); } if (curChoice == DRAWTEXT && textCursorShown) { ChangeEditTextProperty(PROP_MASK_TEXT_FONT, pStrSeg->font); ChangeEditTextProperty(PROP_MASK_TEXT_STYLE, pStrSeg->style); ChangeEditTextProperty(PROP_MASK_TEXT_SZ_UNIT, pStrSeg->sz_unit); curTextModified = TRUE; UpdCurTextBBox(); RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_FONT, curFont); } } else { textCursorShown = FALSE; } ShowCurFont(); ShowTextSize(); UpdatePinnedMenu(MENU_FONT); return TRUE; } int SwitchToSingleByteFont(pStrSeg) StrSegInfo *pStrSeg; { return SwitchToSingleOrDoubleByteFont(pStrSeg); } int SwitchToDoubleByteFont(pStrSeg) StrSegInfo *pStrSeg; { return SwitchToSingleOrDoubleByteFont(pStrSeg); } static void AdvanceEnd(drag) int drag; { StrBlockInfo *pStrBlock=NULL; int index=INVALID, position_end=FALSE; MiniLinesInfo *minilines=NULL; MiniLineInfo *pMiniLine=NULL; position_end = BeginAdvance(drag, ADVANCE_RIGHT, &pStrBlock, &index); if (pStrBlock->type == SB_SUPSUB_CENTER) { index = pStrBlock->seg->dyn_str.sz-1; EndAdvance(position_end, pStrBlock, index); } else { minilines = pStrBlock->owner_mini_line->owner_minilines; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (CurStrBlockInMiniLine(pMiniLine)) { pStrBlock = pMiniLine->last_block; /* pStrBlock->type must be SB_SIMPLE */ index = pStrBlock->seg->dyn_str.sz-1; EndAdvance(position_end, pStrBlock, index); break; } } } AdjTextIndicesForInheritedAttr(); } static void HandleEnd(drag) int drag; { int saved_text_highlight=textHighlight; if (textCursorShown && !saved_text_highlight && !drag) { EraseTextCursor(); } UpdateHighLightedTextBBoxes(TRUE); if (!drag && endStrBlock != NULL) { textCurIndex = textEndIndex; curStrBlock = endStrBlock; } ResetOnCursorKey(drag); AdvanceEnd(drag); AdjustTextHighlight(drag, saved_text_highlight, TRUE); UpdateTextInfoChoices(FALSE); } static int HandleRightMargin() /* return TRUE if something changed */ { char *psz=NULL; int right_margin=OFFSET_X(paperWidth-(rightMargin>>TIK_PER_PIXEL_SHIFTS)); int x=textCurX, done=FALSE, last_index_beyond_right_margin=(-1); StrBlockInfo *psbi=NULL, *psbi_last_beyond_right_margin=NULL; if (textCurX <= right_margin) return FALSE; if (textHighlight) return FALSE; if (textCurIndex > 0 && curStrBlock->seg->dyn_str.s[textCurIndex-1] == ' ') { HandleCRLF(NULL); done = TRUE; } for (psbi=curStrBlock; !done && psbi != NULL; psbi=psbi->prev) { int saved_x=x; if (psbi->type == SB_SIMPLE) { StrSegInfo *pssi=psbi->seg; psz = strrchr(psbi->seg->dyn_str.s, ' '); while (!done && psz != NULL) { int w=0; if (psz[1] == '\0') { w = 0; } else { PushCurFont(); curFont = pssi->font; curSzUnit = pssi->sz_unit; curStyle = pssi->style; SetCanvasFont(); w = MyTextWidth(canvasFontPtr, &psz[1], strlen(&psz[1])); PopCurFont(); } if (x-w < right_margin) { /* found it! */ done = TRUE; curStrBlock = psbi; textCurIndex = ((int)(psz-psbi->seg->dyn_str.s))+1; HandleCRLF(NULL); HandleEnd(FALSE); } else { char *psz2=psz, saved_ch=(*psz); last_index_beyond_right_margin = ((int)(psz-psbi->seg->dyn_str.s))+1; psbi_last_beyond_right_margin = psbi; *psz2 = '\0'; psz = strrchr(psbi->seg->dyn_str.s, ' '); *psz2 = saved_ch; } } } if (!done) { x = saved_x - psbi->w; } } if (!done && psbi_last_beyond_right_margin != NULL) { curStrBlock = psbi_last_beyond_right_margin; textCurIndex = last_index_beyond_right_margin; HandleCRLF(NULL); HandleEnd(FALSE); } return TRUE; } static void HandleChar(Str) char *Str; { int double_byte=FALSE, len=strlen(Str); TgAssert(len <= 2, TgLoadString(STID_TOO_MANY_BYTES_IN_CH_IGNORED), NULL); double_byte = (len == 2); if (canvasFontDoubleByte) { escPressed = FALSE; } else { if (escPressed) { Str[0] |= 0x80; escPressed = FALSE; } if ((((*Str)&0x80) != '\0') && curFont!=FONT_SYM && !ValidCharCode(Str)) { return; } } if (textHighlight) { curTextModified = TRUE; DeleteHighlightedText(); EndChangeCurText(FALSE); SetRightMarginActive(); } if (canvasFontDoubleByte != double_byte && curStrBlock->type == SB_SUPSUB_CENTER) { XEvent ev; MsgBox(TgLoadString(STID_CANT_CHNG_FONT_SUPSUB_CENTER), TOOL_NAME, INFO_MB); if (!gnDontRedrawDuringPaste) { RedrawCurText(); UpdateTextInfoChoices(FALSE); } while (XCheckWindowEvent(mainDisplay, drawWindow, KeyPressMask, &ev)) ; return; } else if (canvasFontDoubleByte && !double_byte) { StrSegInfo double_byte_ssi; StrSegInfo ssi; memset(&double_byte_ssi, 0, sizeof(StrSegInfo)); memcpy(&double_byte_ssi, curStrBlock->seg, sizeof(StrSegInfo)); memset(&ssi, 0, sizeof(StrSegInfo)); if (CanFindSingleByteFontAtCursor(&ssi)) { if (SwitchToSingleByteFont(&ssi)) { SetCopyUTF8FontInfo(&double_byte_ssi, TRUE); double_byte = FALSE; } } else if (gstCopyUTF8Info.single_byte_valid) { if (SwitchToSingleByteFont(&gstCopyUTF8Info.single_byte_seg)) { SetCopyUTF8FontInfo(&double_byte_ssi, TRUE); double_byte = FALSE; } } else { ssi.font = GetInitialFont(); ssi.style = curStyle; ssi.sz_unit = curSzUnit; if (SwitchToSingleByteFont(&ssi)) { SetCopyUTF8FontInfo(&double_byte_ssi, TRUE); double_byte = FALSE; } } } else if (!canvasFontDoubleByte && double_byte) { StrSegInfo single_byte_ssi; StrSegInfo ssi; memset(&single_byte_ssi, 0, sizeof(StrSegInfo)); memcpy(&single_byte_ssi, curStrBlock->seg, sizeof(StrSegInfo)); memset(&ssi, 0, sizeof(StrSegInfo)); if (CanFindDoubleByteFontAtCursor(&ssi)) { if (SwitchToDoubleByteFont(&ssi)) { SetCopyUTF8FontInfo(&single_byte_ssi, FALSE); double_byte = TRUE; } } else if (gstCopyUTF8Info.double_byte_valid) { if (SwitchToDoubleByteFont(&gstCopyUTF8Info.double_byte_seg)) { SetCopyUTF8FontInfo(&single_byte_ssi, FALSE); double_byte = TRUE; } } } if (!InsertCharIntoCurText(Str, double_byte)) { XEvent ev; if (!gnDontRedrawDuringPaste) { RedrawCurText(); UpdateTextInfoChoices(FALSE); } while (XCheckWindowEvent(mainDisplay, drawWindow, KeyPressMask, &ev)) ; return; } if ((rightMarginEnabled == TRUE) && rightMarginActive) { /* add a <CR> somewhere */ HandleRightMargin(); } if (gnDontRedrawDuringPaste) { if ((rightMarginEnabled == TRUE) && rightMarginActive) { gnDontRedrawDuringPaste = FALSE; } } if (!gnDontRedrawDuringPaste) { ScrollTo(textCurX, textCurBaselineY); } } static void HandleTAB(key_ev) XKeyEvent *key_ev; { struct AttrRec *attr_ptr=NULL, *new_attr=NULL; struct ObjRec *obj_ptr=NULL; int abs_x=0, abs_y=0, x_off=0, y_off=0; escPressed = FALSE; if ((attr_ptr=curTextObj->detail.t->attr) == NULL) { MsgBox(TgLoadString(STID_CANT_TAB_OUT_OF_NON_ATTR_TEXT), TOOL_NAME, INFO_MB); return; } CreateTextObj(TRUE, TRUE); curTextModified = FALSE; if (key_ev != NULL && (key_ev->state & METAMASK) != 0) { /* new_attr will be the next attribute */ if (attr_ptr->next == NULL) { new_attr = attr_ptr->owner->fattr; } else { new_attr = attr_ptr->next; } while (!new_attr->shown) { if (new_attr->next == NULL) { new_attr = new_attr->owner->fattr; } else { new_attr = new_attr->next; } } } else { /* new_attr will be the previous attribute */ if (attr_ptr->prev == NULL) { new_attr = attr_ptr->owner->lattr; } else { new_attr = attr_ptr->prev; } while (!new_attr->shown) { if (new_attr->prev == NULL) { new_attr = new_attr->owner->lattr; } else { new_attr = new_attr->prev; } } } obj_ptr = new_attr->obj; abs_x = obj_ptr->x; x_off = OFFSET_X(abs_x); abs_y = obj_ptr->y; y_off = OFFSET_Y(abs_y); if (!PrepareEditExistingText(obj_ptr, abs_x, abs_y, &x_off, &y_off)) { return; } if (curStrBlock != NULL) UpdateHighLightedTextBBoxes(TRUE); HandleClickOnText(FALSE, TRUE, x_off, y_off, FALSE, obj_ptr, FALSE, TRUE, FALSE, (Time)0); UpdateTextInfoChoices(TRUE); } static void AdvanceHome(drag) int drag; { StrBlockInfo *pStrBlock=NULL; int index=INVALID, position_end=FALSE; MiniLinesInfo *minilines=NULL; MiniLineInfo *pMiniLine=NULL; position_end = BeginAdvance(drag, ADVANCE_LEFT, &pStrBlock, &index); if (pStrBlock->type == SB_SUPSUB_CENTER) { EndAdvance(position_end, pStrBlock, 0); } else { minilines = pStrBlock->owner_mini_line->owner_minilines; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (CurStrBlockInMiniLine(pMiniLine)) { EndAdvance(position_end, pMiniLine->first_block, 0); break; } } } AdjTextIndicesForInheritedAttr(); } static void HandleHome(drag) int drag; { int saved_text_highlight=textHighlight; if (textCursorShown && !saved_text_highlight && !drag) { EraseTextCursor(); } UpdateHighLightedTextBBoxes(TRUE); ResetOnCursorKey(drag); AdvanceHome(drag); AdjustTextHighlight(drag, saved_text_highlight, TRUE); UpdateTextInfoChoices(FALSE); } static int CanMoveTextCursorIntoLeftScripts() { if (textCursorShown && curStrBlock != NULL && textCurIndex == 0 && curStrBlock->prev != NULL && (curStrBlock->prev->type == SB_SUPSUB_LEFT || curStrBlock->prev->type == SB_SUPSUB_CENTER || curStrBlock->prev->type == SB_SUPSUB_RIGHT)) { return TRUE; } return FALSE; } static void DoMoveTextCursorIntoLeftScripts() { int saved_text_highlight=textHighlight; if (textCursorShown && !saved_text_highlight) { EraseTextCursor(); } UpdateHighLightedTextBBoxes(TRUE); curStrBlock = curStrBlock->prev->sup->first->last_block; textCurIndex = curStrBlock->seg->dyn_str.sz-1; ResetOnCursorKey(FALSE); SetTextCurXY(); SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); if (textCursorShown && !saved_text_highlight) { PutTextCursor(); } else { RedrawCurText(); } MarkRulers(textCurX, textCurY); ScrollTo(textCurX, textCurBaselineY); UpdateTextInfoChoices(FALSE); } static void HandleLeft(key_ev) XKeyEvent *key_ev; { int saved_text_highlight=textHighlight; int cycle=((key_ev->state & ControlMask) != 0); int drag=((key_ev->state & ShiftMask) != 0); if (cycle) { if (CanMoveTextCursorIntoLeftScripts()) { DoMoveTextCursorIntoLeftScripts(); } return; } if (textCursorShown && !saved_text_highlight && !drag) { EraseTextCursor(); } else if (textCursorShown && saved_text_highlight && !drag) { if (FixHighlightedStrBlockDepths() < 0) { SwitchTextCurAndEndStrBlocks(); } } UpdateHighLightedTextBBoxes(TRUE); ResetOnCursorKey(drag); AdvanceLeft(drag); AdjustTextHighlight(drag, saved_text_highlight, TRUE); UpdateTextInfoChoices(FALSE); } static int CanCycleTextCursorInScripts() { return (textCursorShown && curStrBlock != NULL && curStrBlock->depth != 0); } static void DoCycleTextCursorInScripts(direction) int direction; { int saved_text_highlight=textHighlight; MiniLinesInfo *pOwnerMinilines=NULL; StrBlockInfo *pOwnerStrBlock=NULL; if (textCursorShown && !saved_text_highlight) { EraseTextCursor(); } UpdateHighLightedTextBBoxes(TRUE); ResetOnCursorKey(FALSE); switch(curStrBlock->type) { case SB_SIMPLE: pOwnerMinilines = curStrBlock->owner_mini_line->owner_minilines; pOwnerStrBlock = pOwnerMinilines->owner_block; switch (pOwnerStrBlock->type) { case SB_SUPSUB_LEFT: case SB_SUPSUB_RIGHT: if (pOwnerMinilines == pOwnerStrBlock->sup) { curStrBlock = pOwnerStrBlock->sub->first->first_block; } else if (pOwnerMinilines == pOwnerStrBlock->sub) { curStrBlock = pOwnerStrBlock->sup->first->first_block; } else { if (textCursorShown && !saved_text_highlight) { PutTextCursor(); } return; } break; case SB_SUPSUB_CENTER: if (pOwnerMinilines == pOwnerStrBlock->sup) { if (direction == SCROLL_UP) { curStrBlock = pOwnerStrBlock->sub->first->first_block; } else { curStrBlock = pOwnerStrBlock; } } else if (pOwnerMinilines == pOwnerStrBlock->sub) { if (direction == SCROLL_UP) { curStrBlock = pOwnerStrBlock; } else { curStrBlock = pOwnerStrBlock->sup->first->first_block; } } else { if (textCursorShown && !saved_text_highlight) { PutTextCursor(); } return; } break; } break; case SB_CHAR_SPACE: /* not possible */ case SB_SUPSUB_LEFT: /* not possible */ case SB_SUPSUB_RIGHT: /* not possible */ if (textCursorShown && !saved_text_highlight) { PutTextCursor(); } return; case SB_SUPSUB_CENTER: if (curStrBlock->sub != NULL) { if (direction == SCROLL_UP) { curStrBlock = curStrBlock->sup->first->first_block; } else { curStrBlock = curStrBlock->sub->first->first_block; } } else { if (textCursorShown && !saved_text_highlight) { PutTextCursor(); } return; } break; } textCurIndex = 0; SetTextCurXY(); SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); if (textCursorShown && !saved_text_highlight) { PutTextCursor(); } else { RedrawCurText(); } MarkRulers(textCurX, textCurY); ScrollTo(textCurX, textCurBaselineY); UpdateTextInfoChoices(FALSE); } static void HandleUp(key_ev) XKeyEvent *key_ev; { int saved_text_highlight=textHighlight; int cycle=((key_ev->state & ControlMask) != 0); int drag=((key_ev->state & ShiftMask) != 0), new_x_off=0, new_y_off=0; if (cycle) { if (CanCycleTextCursorInScripts()) { DoCycleTextCursorInScripts(SCROLL_UP); } return; } if (textCursorShown && !saved_text_highlight && !drag) { EraseTextCursor(); } UpdateHighLightedTextBBoxes(TRUE); ResetOnCursorKey(drag); if (drag && textHighlight) { new_x_off = textEndX; if (endStrBlock->type == SB_SUPSUB_CENTER) { new_y_off = textEndBaselineY-endStrBlock->seg->asc-2; } else { MiniLineInfo *pOwnerMiniLine=endStrBlock->owner_mini_line; new_y_off = textEndBaselineY - pOwnerMiniLine->asc - pOwnerMiniLine->v_gap - 2; if (pOwnerMiniLine->owner_minilines != NULL && pOwnerMiniLine->owner_minilines->owner_block == NULL) { new_y_off -= pOwnerMiniLine->owner_minilines->v_space; } } } else { new_x_off = textCurX; if (curStrBlock->type == SB_SUPSUB_CENTER) { new_y_off = textCurBaselineY-curStrBlock->seg->asc-2; } else { MiniLineInfo *pOwnerMiniLine=curStrBlock->owner_mini_line; new_y_off = textCurBaselineY - pOwnerMiniLine->asc - pOwnerMiniLine->v_gap - 2; if (pOwnerMiniLine->owner_minilines != NULL && pOwnerMiniLine->owner_minilines->owner_block == NULL) { new_y_off -= pOwnerMiniLine->owner_minilines->v_space; } } } HandleClickOnText(drag, TRUE, new_x_off, new_y_off, TRUE, curTextObj, FALSE, saved_text_highlight, FALSE, key_ev->time); UpdateTextInfoChoices(FALSE); } static int CanMoveTextCursorIntoRightScripts() { if (textCursorShown && curStrBlock != NULL && textCurIndex == curStrBlock->seg->dyn_str.sz-1 && curStrBlock->next != NULL && (curStrBlock->next->type == SB_SUPSUB_LEFT || curStrBlock->next->type == SB_SUPSUB_CENTER || curStrBlock->next->type == SB_SUPSUB_RIGHT)) { return TRUE; } return FALSE; } static void DoMoveTextCursorIntoRightScripts() { int saved_text_highlight=textHighlight; if (textCursorShown && !saved_text_highlight) { EraseTextCursor(); } UpdateHighLightedTextBBoxes(TRUE); curStrBlock = curStrBlock->next->sup->first->first_block; textCurIndex = 0; ResetOnCursorKey(FALSE); SetTextCurXY(); SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); if (textCursorShown && !saved_text_highlight) { PutTextCursor(); } else { RedrawCurText(); } MarkRulers(textCurX, textCurY); ScrollTo(textCurX, textCurBaselineY); UpdateTextInfoChoices(FALSE); } static void HandleRight(key_ev) XKeyEvent *key_ev; { int saved_text_highlight=textHighlight; int cycle=((key_ev->state & ControlMask) != 0); int drag=((key_ev->state & ShiftMask) != 0); if (cycle) { if (CanMoveTextCursorIntoRightScripts()) { DoMoveTextCursorIntoRightScripts(); } return; } if (textCursorShown && !saved_text_highlight && !drag) { EraseTextCursor(); } else if (textCursorShown && saved_text_highlight && !drag) { if (FixHighlightedStrBlockDepths() < 0) { SwitchTextCurAndEndStrBlocks(); } } UpdateHighLightedTextBBoxes(TRUE); if (!drag && endStrBlock != NULL) { textCurIndex = textEndIndex; curStrBlock = endStrBlock; } ResetOnCursorKey(drag); AdvanceRight(drag); AdjustTextHighlight(drag, saved_text_highlight, TRUE); UpdateTextInfoChoices(FALSE); } static void HandleDown(key_ev) XKeyEvent *key_ev; { int saved_text_highlight=textHighlight; int cycle=((key_ev->state & ControlMask) != 0); int drag=((key_ev->state & ShiftMask) != 0), new_x_off=0, new_y_off=0; if (cycle) { if (CanCycleTextCursorInScripts()) { DoCycleTextCursorInScripts(SCROLL_DOWN); } return; } if (textCursorShown && !saved_text_highlight && !drag) { EraseTextCursor(); } UpdateHighLightedTextBBoxes(TRUE); ResetOnCursorKey(drag); if (drag && textHighlight) { new_x_off = textEndX; if (endStrBlock->type == SB_SUPSUB_CENTER) { new_y_off = textEndBaselineY+endStrBlock->seg->des+2; } else { MiniLineInfo *pOwnerMiniLine=endStrBlock->owner_mini_line; new_y_off = textEndBaselineY+pOwnerMiniLine->des+2; if (pOwnerMiniLine->owner_minilines != NULL && pOwnerMiniLine->owner_minilines->owner_block == NULL) { new_y_off += pOwnerMiniLine->owner_minilines->v_space; } if (pOwnerMiniLine->next != NULL) { new_y_off += pOwnerMiniLine->v_gap; } } } else { new_x_off = textCurX; if (curStrBlock->type == SB_SUPSUB_CENTER) { new_y_off = textCurBaselineY+curStrBlock->seg->des+2; } else { MiniLineInfo *pOwnerMiniLine=curStrBlock->owner_mini_line; new_y_off = textCurBaselineY+pOwnerMiniLine->des+2; if (pOwnerMiniLine->owner_minilines != NULL && pOwnerMiniLine->owner_minilines->owner_block == NULL) { new_y_off += pOwnerMiniLine->owner_minilines->v_space; } if (pOwnerMiniLine->next != NULL) { new_y_off += pOwnerMiniLine->v_gap; } } } HandleClickOnText(drag, TRUE, new_x_off, new_y_off, TRUE, curTextObj, FALSE, saved_text_highlight, FALSE, key_ev->time); UpdateTextInfoChoices(FALSE); } static void DoHandleInputFromBuffer(cut_buffer) char *cut_buffer; { char *c_ptr=NULL, s[80]; s[2] = '\0'; for (c_ptr = cut_buffer; *c_ptr != '\0'; c_ptr+=2) { int double_byte=FALSE; if (((*c_ptr) & 0x80) == '\0') { s[0] = c_ptr[0]; s[1] = '\0'; } else { double_byte = TRUE; if (!canvasFontDoubleByte && double_byte) { StrSegInfo ssi; memset(&ssi, 0, sizeof(StrSegInfo)); if (!CanFindDoubleByteFontAtCursor(&ssi) && !gstCopyUTF8Info.double_byte_valid) { double_byte = FALSE; } } if (double_byte) { s[0] = c_ptr[0]; s[1] = c_ptr[1]; } else { s[0] = c_ptr[0]; s[1] = '\0'; } } switch (s[0]) { case '\r': case '\n': HandleCRLF(NULL); c_ptr--; break; case '\177': Msg(TgLoadCachedString(CSTID_CANT_PASTE_DEL)); break; case '\b': Msg(TgLoadCachedString(CSTID_CANT_PASTE_BS)); break; case '\033': Msg(TgLoadCachedString(CSTID_CANT_PASTE_ESC)); break; case '\t': Msg(TgLoadCachedString(CSTID_CANT_PASTE_TAB_REPLACE_BY_SPC)); s[0] = ' '; /* drop through */ default: HandleChar(s); if (!double_byte) { c_ptr--; } break; } } } void HandleInputFromBuffer(cut_buffer) char *cut_buffer; { if (cut_buffer == NULL || *cut_buffer == '\0') return; SaveStatusStrings(); gnPastingLineNum = 0; if (!((rightMarginEnabled == TRUE) && rightMarginActive)) { gnDontRedrawDuringPaste = TRUE; } DoHandleInputFromBuffer(cut_buffer); gnDontRedrawDuringPaste = FALSE; RestoreStatusStrings(); UpdTextBBox(curTextObj); SetTextCurXY(); if (textHighlight) SetTextEndXY(); UpdateEditTextArea( curTextObj->detail.t->minilines.w, curTextObj->detail.t->minilines.h, curTextObj->detail.t->minilines.min_lbearing, curTextObj->detail.t->minilines.max_rextra); RedrawCurText(); ScrollTo(textCurX, textCurBaselineY); MarkRulers(textCurX, textCurY); SetFileModified(TRUE); UpdateTextInfoChoices(FALSE); return; } void HandleTextFromBuffer(key_ev, s, key_sym, has_ch) XKeyEvent *key_ev; char *s; KeySym key_sym; int has_ch; { int drag=FALSE, cursor_key=FALSE; ResetDirtyBBoxInfo(); if (CharIsCntrlShiftINS(key_ev, key_sym)) { char szBuf[MAXSTRING]; int nBufSize=sizeof(szBuf); memset(szBuf, 0, sizeof(szBuf)); if (InputOctalString(szBuf, &nBufSize)) { HandleInputFromBuffer(szBuf); } } else if (CharIsESC(key_ev, s, key_sym, &has_ch) || CharIsCRorLF(key_ev, s, key_sym, &has_ch) || CharIsBSorDEL(key_ev, s, key_sym, &has_ch, FALSE) || CharIsTAB(key_ev, s, key_sym, &has_ch) || CharIsHome(key_ev, s, key_sym, &has_ch) || CharIsEnd(key_ev, s, key_sym, &has_ch)) { } else if (!((s[0]=='\r' && (key_sym & 0xff)=='\r') || (s[0]=='\n' && (key_sym & 0xff)=='\n') || (s[0]=='\b' && (key_sym & 0xff)=='\b') || (s[0]=='\b' && (key_sym & 0xff)=='h' && (key_ev != NULL && (key_ev->state & ControlMask))) || key_sym==XK_Left || key_sym==XK_Up || key_sym==XK_Right || key_sym==XK_Down || key_sym==XK_KP_Left || key_sym==XK_KP_Up || key_sym==XK_KP_Right || key_sym==XK_KP_Down || (key_sym==XK_Tab && (key_ev != NULL && (key_ev->state & (ShiftMask | METAMASK)) != 0)) || (s[0]=='\033' && (key_sym & 0xff)=='\033') || (s[0]=='\177' && (key_sym & 0x7f)=='\177') || ((s[0]&0xff) && canvasFontDoubleByte) || (has_ch==1 && ((unsigned char)s[0])>='\040'))) { return; } drag = ((key_ev->state & ShiftMask) != 0); switch (key_sym) { case XK_Left: HandleLeft(key_ev); cursor_key = TRUE; break; case XK_KP_Left: HandleLeft(key_ev); cursor_key = TRUE; break; case XK_Up: HandleUp(key_ev); cursor_key = TRUE; break; case XK_KP_Up: HandleUp(key_ev); cursor_key = TRUE; break; case XK_Right: HandleRight(key_ev); cursor_key = TRUE; break; case XK_KP_Right: HandleRight(key_ev); cursor_key = TRUE; break; case XK_Down: HandleDown(key_ev); cursor_key = TRUE; break; case XK_KP_Down: HandleDown(key_ev); cursor_key = TRUE; break; default: if (!canvasFontDoubleByte) { s[1] = '\0'; } if (CharIsESC(key_ev, s, key_sym, &has_ch)) { if (!escPressed) { escPressed = TRUE; return; } } else if (CharIsCRorLF(key_ev, s, key_sym, &has_ch)) { HandleCRLF(key_ev); } else if (CharIsBSorDEL(key_ev, s, key_sym, &has_ch, FALSE)) { if (has_ch && s[0] == '\177') { if (escPressed) { HandleChar(s); } else { HandleBS(key_ev, s, key_sym, &has_ch); } } else { HandleBS(key_ev, s, key_sym, &has_ch); } } else if (CharIsTAB(key_ev, s, key_sym, &has_ch)) { HandleTAB(key_ev); cursor_key = TRUE; } else if (CharIsHome(key_ev, s, key_sym, &has_ch)) { HandleHome(drag); cursor_key = TRUE; } else if (CharIsEnd(key_ev, s, key_sym, &has_ch)) { HandleEnd(drag); cursor_key = TRUE; } else if (has_ch) { if (canvasFontDoubleByte) { char ch[3], *c_ptr=NULL; ch[2] = '\0'; for (c_ptr=s; *c_ptr != '\0'; c_ptr++) { int double_byte=((*c_ptr)&0x80); ch[0] = c_ptr[0]; if (double_byte) { ch[1] = *(++c_ptr); } else { ch[1] = '\0'; } HandleChar(ch); } } else { HandleChar(s); } } break; } if (textCursorShown) { MarkRulers(textCurX, textCurY); if (!cursor_key) SetFileModified(TRUE); } } static void HandlePasteInDrawTextMode() { char *cut_buffer=NULL; int xfree_cut_buffer=FALSE; int len=0; if (pasteFromFileInDrawTextMode) { FILE *fp; char inbuf[MAXSTRING+1]; int size=0; pasteFromFileInDrawTextMode = FALSE; if ((fp=fopen(pasteFromFileName, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), pasteFromFileName); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } while (fgets(inbuf, MAXSTRING, fp) != NULL) size += strlen(inbuf); fclose(fp); if (size == 0) { sprintf(gszMsgBox, TgLoadString(STID_NAMED_FILE_IS_EMPTY), pasteFromFileName); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } cut_buffer = (char*)malloc((size+2)*sizeof(char)); if (cut_buffer == NULL) { FailAllocMessage(); return; } memset(cut_buffer, 0, (size+2)*sizeof(char)); if ((fp=fopen(pasteFromFileName, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), pasteFromFileName); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(cut_buffer); return; } len = 0; while (fgets(&cut_buffer[len], MAXSTRING, fp) != NULL) { len += strlen(&cut_buffer[len]); } fclose(fp); #ifndef _NO_NKF if (Tg_useNKF()) { char *out_buffer=(char*)malloc(size+2); if (out_buffer == NULL) FailAllocMessage(); Tg_do_kconv(cut_buffer, out_buffer, size+2); strcpy(cut_buffer, out_buffer); free(out_buffer); } else { #ifndef _NO_KINPUT if (copyAndPasteJIS) { CvtJisToEuc(cut_buffer, cut_buffer); } #endif /* ~_NO_KINPUT */ } #endif /* ~_NO_NKF */ } else if (pasteCompoundTextInDrawTextMode) { unsigned long ul=0L; pasteCompoundTextInDrawTextMode = FALSE; cut_buffer = GetTextBytesFromSelection(TRUE, &ul); if (cut_buffer == NULL || ul == 0L) { Msg(TgLoadString(STID_COMPOUND_TEXT_BUF_IS_EMPTY)); if (cut_buffer != NULL) UtilFree(cut_buffer); return; } } else { int from_selection=FALSE; cut_buffer = FetchSelectionOrCutBuffer(&len, &from_selection); if (cut_buffer == NULL) { Msg(TgLoadString(STID_CUT_BUFFER_IS_EMPTY)); return; } xfree_cut_buffer = !from_selection; #ifndef _NO_KINPUT if (copyAndPasteJIS) { CvtJisToEuc(cut_buffer, cut_buffer); } #endif /* ~_NO_KINPUT */ } if (escPressed) { escPressed = FALSE; Msg(TgLoadString(STID_AN_ESC_KEY_PRESS_IGNORED)); } HandleInputFromBuffer(cut_buffer); if (gnPastingLineNum > 0) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_NUM_LINES_PASTED), gnPastingLineNum); Msg(gszMsgBox); } FreeSelectionOrCutBuffer(cut_buffer, !xfree_cut_buffer); } static void HandleCopyInDrawTextMode() { int copy_failed=FALSE, copy_db_utf8_str=FALSE; int cut_buffer_size=0, double_byte_font_index=INVALID; char *cut_buffer=NULL; if (!textHighlight) return; if (escPressed) { escPressed = FALSE; Msg(TgLoadString(STID_AN_ESC_KEY_PRESS_IGNORED)); } if (copyDoubleByteStringInDrawTextMode && CanCopyHighLightedTextAsUTF8Strings(&double_byte_font_index)) { /* copy just text, cut_buffer_size will include terminating '\0' */ GatherHighLightedTextAsStrings(&cut_buffer, &cut_buffer_size); copy_db_utf8_str = TRUE; } else if (CanCopyHighLightedTextAsStrings()) { /* copy just text, cut_buffer_size will include terminating '\0' */ GatherHighLightedTextAsStrings(&cut_buffer, &cut_buffer_size); } else { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "Can only handle simple text in HandleCopyInDrawTextMode()", NULL); #endif /* _TGIF_DBG */ } if (cut_buffer == NULL) { ClearSelection(); return; } #ifndef _NO_KINPUT if (!copy_db_utf8_str && canvasFontDoubleByte && gnInputMethod == TGIM_KINPUT && copyAndPasteJIS) { char *tmp_buffer=NULL; cut_buffer_size = CvtEucToJis(NULL, cut_buffer); tmp_buffer = (char*)malloc((cut_buffer_size+2)*sizeof(char)); CvtEucToJis(tmp_buffer, cut_buffer); free(cut_buffer); cut_buffer = tmp_buffer; } #endif /* ~_NO_KINPUT */ if (copy_db_utf8_str && (double_byte_font_index != INVALID)) { if (!ConvertToOrFromUTF8(CONVERT_TO_UTF8, double_byte_font_index, &cut_buffer)) { ClearSelection(); return; } cut_buffer_size = strlen(cut_buffer)+1; } copy_failed = !WriteBufToCutBuffer(cut_buffer, cut_buffer_size-1, TRUE, copy_db_utf8_str && (double_byte_font_index != INVALID), NULL); if (copy_failed) { sprintf(gszMsgBox, TgLoadString(STID_COPY_FAIL_SEL_STR_MAY_TOO_LNG)); } else { sprintf(gszMsgBox, TgLoadString(STID_COPY_BUFFER_UPDATED)); } Msg(gszMsgBox); free(cut_buffer); } static int HandleFunctionKey(key_sym) KeySym key_sym; { int index=0; char buf[MAXSTRING], *c_ptr=NULL, tmp_fname[MAXSTRING+1]; FILE *fp=NULL; switch (key_sym) { case XK_F1: index=1; break; case XK_F2: index=2; break; case XK_F3: index=3; break; case XK_F4: index=4; break; case XK_F5: index=5; break; case XK_F6: index=6; break; case XK_F7: index=7; break; case XK_F8: index=8; break; case XK_F9: index=9; break; case XK_F10: index=10; break; case XK_F11: index=11; break; case XK_F12: index=12; break; default: return FALSE; } sprintf(buf, "DrawTextFuncKey_F%1d", index); if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, buf)) == NULL) { return FALSE; } if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { return TRUE; } if ((fp=fopen(tmp_fname, "w")) == NULL) { FailToWriteFileMessage(tmp_fname); return TRUE; } fprintf(fp, "%s\n", c_ptr); fclose(fp); ExecCmdsFromTmp(tmp_fname); unlink(tmp_fname); return TRUE; } int HandleDoubleByteUTF8Chars(s, has_ch) char *s; int has_ch; { if (has_ch >= 2 && !canvasFontDoubleByte && Tgim_has_stringprep_convert()) { char *psz=NULL, *psz1=NULL, *psz2=NULL, *psz_encoding=NULL; char buf[MAXSTRING]; GetCurFontInfoStr(buf, sizeof(buf)); psz1 = strrchr(buf, '-'); if (psz1 != NULL) { *psz1 = '\0'; psz2 = strrchr(buf, '-'); if (psz2 != NULL) { *psz2 = '\0'; } *psz1 = '-'; } if (psz2 != NULL) { if (strchr(&psz2[1], '*') == NULL) { psz_encoding = &psz2[1]; } *psz2 = '-'; } if (psz_encoding != NULL) { psz = Tgim_stringprep_convert(s, psz_encoding, "utf-8"); if (psz != NULL && strlen(psz) == 1) { s[0] = psz[0]; s[1] = '\0'; has_ch = 1; } UtilFree(psz); } if (has_ch > 1) { s[0] = '\0'; has_ch = 0; } } return has_ch; } static XComposeStatus c_stat; void DrawText(input) XEvent *input; { if (input->type == ButtonPress) { HandleButton(&(input->xbutton)); } else if (input->type == PropertyNotify) { if (gnInputMethod != TGIM_NONE) { char *psz_buf=NULL; XPropertyEvent *prop_ev=((XPropertyEvent*)input); if (tgIMConvertProperty(mainDisplay, drawWindow, prop_ev, &psz_buf) && psz_buf != NULL) { HandleInputFromBuffer(psz_buf); free(psz_buf); } } } else if (input->type == KeyPress) { char s[80]; int has_ch=0; XKeyEvent *key_ev=NULL; KeySym key_sym=(KeySym)0; if (!textCursorShown) return; if (pasteInDrawTextMode) { pasteInDrawTextMode = FALSE; HandlePasteInDrawTextMode(); return; } else if (copyInDrawTextMode) { copyInDrawTextMode = FALSE; HandleCopyInDrawTextMode(); return; } key_ev = (&(input->xkey)); if (gnInputMethod != TGIM_NONE && /* * Cannot call: InputMethodTypeMatched(canvasFontDoubleByte) && */ tgIMExpectLookupString(mainDisplay, drawWindow)) { if (tgIMHandleLookupString(mainDisplay, drawWindow, key_ev, s, sizeof(s), &key_sym, &has_ch)) { if (has_ch > 0) s[has_ch] = '\0'; has_ch = HandleDoubleByteUTF8Chars(s, has_ch); } TranslateKeys(s, &key_sym); } else { has_ch = XLookupString(key_ev, s, sizeof(s), &key_sym, &c_stat); if (has_ch > 0) s[has_ch] = '\0'; if (gnInputMethod != TGIM_NONE) { char s1[80]; *s1 = '\0'; if (tgIMTranslateKeyEvent(mainDisplay, mainWindow, key_ev, s1)) { strcpy(s, s1); /* added by Ambrose Li <acli@mingpaoxpress.com> */ key_sym = (KeySym)0; } if (tgIMExpectClientMessage(mainDisplay, mainWindow)) { /* input characters only come from ClientMessage */ return; } } else { TranslateKeys(s, &key_sym); } } if (HandleFunctionKey(key_sym)) { return; } if (textHighlight) { if (!CanCopyHighLightedTextAsUTF8Strings(NULL)) { ClearCopyUTF8Info(); } else if (gstCopyUTF8Info.double_byte_valid && !gstCopyUTF8Info.single_byte_valid) { CalcSingleByteInfoForCopyUTF8(NULL); } } HandleTextFromBuffer(key_ev, s, key_sym, has_ch); } } void InsertHexOctalChar() { XKeyEvent key_ev; KeySym key_sym=(KeySym)XK_Insert; char s[1]; int has_ch=FALSE; if (curChoice != DRAWTEXT || !textCursorShown) return; memset(&key_ev, 0, sizeof(XKeyEvent)); key_ev.state = (ControlMask | ShiftMask); s[0] = '\0'; HandleTextFromBuffer(&key_ev, s, key_sym, has_ch); } void InsertSymbol() { int need_to_restore=FALSE; if (curChoice != DRAWTEXT || !textCursorShown) return; if (textHighlight) { curTextModified = TRUE; DeleteHighlightedText(); EndChangeCurText(FALSE); } if (curFont != FONT_SYM) { PushCurFont(); need_to_restore = TRUE; } if (ChangeFont(FONT_SYM, FALSE)) { TgInsertSymbol_HandleCntrlSpace(mainDisplay, drawWindow); } if (need_to_restore) { PopCurFont(); ChangeFont(curFont, FALSE); } } void EditTextInAttr(attr_ptr) struct AttrRec *attr_ptr; { struct ObjRec *obj_ptr=attr_ptr->obj; int abs_x, abs_y, x_off=0, y_off=0; int ok=TRUE; int saved_grouped_text_editable=groupedTextEditable; SetCurChoice(DRAWTEXT); if (obj_ptr->ctm == NULL) { abs_x = obj_ptr->obbox.ltx; abs_y = obj_ptr->obbox.lty; } else { abs_x = ((obj_ptr->obbox.ltx+obj_ptr->obbox.rbx)>>1); abs_y = ((obj_ptr->obbox.lty+obj_ptr->obbox.rby)>>1); } groupedTextEditable = TRUE; ok = (FindTextObj(OFFSET_X(abs_x), OFFSET_Y(abs_y), obj_ptr) == obj_ptr); groupedTextEditable = saved_grouped_text_editable; if (!ok) { return; } editingText = FALSE; curTextModified = FALSE; if (!PrepareEditExistingText(obj_ptr, abs_x, abs_y, &x_off, &y_off)) { return; } textJustClicked = FALSE; if (curStrBlock != NULL) UpdateHighLightedTextBBoxes(TRUE); HandleClickOnText(FALSE, TRUE, x_off, y_off, FALSE, curTextObj, FALSE, TRUE, FALSE, (Time)0); RedrawCurText(); UpdateTextInfoChoices(TRUE); } void DumpOneStr(FP, FontIndex, DoubleByte, DoubleByteModBytes, Str) register FILE *FP; int FontIndex, DoubleByte, DoubleByteModBytes; register char *Str; { register char *c_ptr; if (DoubleByte) { for ( ; *Str != '\0'; Str++) { switch (*Str) { case '(': case ')': case '\\': if (fprintf(FP, "\\") == EOF) writeFileFailed = TRUE; break; } if (((*Str) & 0x80) != '\0') { if (DoubleByteModBytes) { if (fprintf(FP, "\\%03o\\%03o", Str[0]&0x7f, Str[1]&0x7f) == EOF) { writeFileFailed = TRUE; } } else { #ifdef _PS_SEVENBIT_DOUBLEBYTE_TEXT if (fprintf(FP, "\\%03o\\%03o", Str[0]&0x7f, Str[1]&0x7f) == EOF) { #else /* ~_PS_SEVENBIT_DOUBLEBYTE_TEXT */ if (fprintf(FP, "\\%03o\\%03o", Str[0]&0xff, Str[1]&0xff) == EOF) { #endif /* _PS_SEVENBIT_DOUBLEBYTE_TEXT */ writeFileFailed = TRUE; } } Str++; if (*Str == '\0') break; } else { if (fprintf(FP, "%c", *Str) == EOF) writeFileFailed = TRUE; } } } else { for ( ; *Str != '\0'; Str++) { switch (*Str) { case '(': case ')': case '\\': fprintf(FP, "\\"); break; } if (((*Str) & 0x80) != '\0') { if (FontIndex != FONT_SYM && (c_ptr=CharCodeTranslate(Str)) != NULL) { if (*c_ptr == '\\') { if (fprintf(FP, "%s", c_ptr) == EOF) writeFileFailed = TRUE; } else if (*c_ptr == '8') { if (fprintf(FP, "\\%c%c%c", c_ptr[2], c_ptr[3], c_ptr[4]) == EOF) { writeFileFailed = TRUE; } } } else { if (fprintf(FP, "\\%o", (*Str)&0xff) == EOF) { writeFileFailed = TRUE; } } } else { if (fprintf(FP, "%c", *Str)== EOF) writeFileFailed = TRUE; } } } } void DrawTextObj(Win, XOff, YOff, ObjPtr) Window Win; int XOff, YOff; struct ObjRec *ObjPtr; { struct TextRec *text_ptr=ObjPtr->detail.t; int x, y, xinc=0, yinc=0, trans_pat=0, fill=0, pen=0; int use_cache=FALSE; XGCValues values; if (userDisableRedraw) return; if ((text_ptr->fill == NONEPAT || (ObjPtr->trans_pat && text_ptr->fill == BACKPAT)) && (text_ptr->pen == NONEPAT || (ObjPtr->trans_pat && text_ptr->pen == BACKPAT))) { return; } if (BlankMiniLines(&text_ptr->minilines)) { return; } PushCurFont(); ObjFontInfoToCurFontInfo(text_ptr); pen = text_ptr->pen; if (NeedsToCacheTextObj(ObjPtr)) { if (text_ptr->cached_bitmap == None) { MakeCachedTextBitmap(ObjPtr); } use_cache = TRUE; } x = ObjPtr->x - XOff; y = ObjPtr->y - YOff; xinc = 0; yinc = textCursorH+textVSpace; trans_pat = ObjPtr->trans_pat; fill = text_ptr->fill; if (curChoice == DRAWTEXT && textCursorShown && ObjPtr == curTextObj) { if (RestoreEditTextSize(ObjPtr, TRUE)) { UpdTextBBox(ObjPtr); } } if (fill != NONEPAT) { int real_x_off, real_y_off, ltx, lty, rbx, rby; real_x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); real_y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); ltx = ZOOMED_SIZE(ObjPtr->bbox.ltx + 1 - real_x_off); lty = ZOOMED_SIZE(ObjPtr->bbox.lty + 1 - real_y_off); rbx = ZOOMED_SIZE(ObjPtr->bbox.rbx - 1 - real_x_off); rby = ZOOMED_SIZE(ObjPtr->bbox.rby - 1 - real_y_off); values.foreground = GetDrawingBgPixel(fill, colorPixels[ObjPtr->color]); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[fill]; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple, &values); if (ObjPtr->ctm != NULL) { XFillPolygon(mainDisplay, Win, drawGC, ObjPtr->rotated_obbox, 5, Convex, CoordModeOrigin); } else { XFillRectangle(mainDisplay, Win, drawGC, ltx, lty, rbx-ltx, rby-lty); } } if (pen == NONEPAT || (trans_pat && pen == BACKPAT)) { } else if (use_cache || ObjPtr->ctm != NULL || zoomScale != 0 || text_ptr->read_only) { if (ObjPtr->obbox.ltx != ObjPtr->obbox.rbx && ObjPtr->obbox.lty != ObjPtr->obbox.rby) { int ltx, lty, w, h; ltx = OFFSET_X(ObjPtr->bbox.ltx+1); lty = OFFSET_Y(ObjPtr->bbox.lty+1); w = ZOOMED_SIZE(ObjPtr->bbox.rbx-ObjPtr->bbox.ltx-2); h = ZOOMED_SIZE(ObjPtr->bbox.rby-ObjPtr->bbox.lty-2); if (!trans_pat) { values.foreground = myBgPixel; values.function = GXcopy; values.fill_style = FillSolid; values.clip_mask = text_ptr->cached_bg_bitmap; values.clip_x_origin = ltx; values.clip_y_origin = lty; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCClipMask | GCClipXOrigin | GCClipYOrigin, &values); FillClippedRectangle(Win, drawGC, ltx, lty, w, h); } values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[pen]; values.clip_mask = text_ptr->cached_bitmap; values.clip_x_origin = ltx; values.clip_y_origin = lty; XChangeGC(mainDisplay, drawGC, GCFunction | GCFillStyle | GCStipple | GCClipMask | GCClipXOrigin | GCClipYOrigin, &values); DrawClippedPixmap(text_ptr->cached_pixmap, Win, drawGC, w, h, ltx, lty); values.clip_mask = None; values.clip_x_origin = 0; values.clip_y_origin = 0; XChangeGC(mainDisplay, drawGC, GCClipMask | GCClipXOrigin | GCClipYOrigin, &values); if (numClipRecs > 0) { XSetClipRectangles(mainDisplay, drawGC, 0, 0, clipRecs, numClipRecs, clipOrdering); } } } else { MiniLinesInfo *minilines=(&text_ptr->minilines); int saved_pen=penPat, saved_trans_pat=transPat; int baseline_y=text_ptr->baseline_y-YOff; ResetDirtyBBoxInfo(); penPat = pen; transPat = trans_pat; PaintMiniLines(mainDisplay, Win, drawGC, mainDepth, x, baseline_y, minilines, FALSE, FALSE); penPat = saved_pen; transPat = saved_trans_pat; } if (curChoice == DRAWTEXT && textCursorShown && ObjPtr == curTextObj) { if (RestoreEditTextSize(ObjPtr, FALSE)) { UpdTextBBox(ObjPtr); } } PopCurFont(); } #define FONTS_PER_DPI (((MAXFONTS-1)*MAXFONTSTYLES+1)*MAXFONTSIZES) static int OldFontIndex(dpi_index, font_index, size_index, style_index) register int dpi_index, font_index, size_index, style_index; /* obsoleted procedure, kept to remain compatible with old versions */ { if (font_index == FONT_SYM) { return (size_index+MAXFONTSIZES*(MAXFONTSTYLES*font_index) + dpi_index*FONTS_PER_DPI); } else { return (size_index+MAXFONTSIZES*(style_index+MAXFONTSTYLES*font_index) + dpi_index*FONTS_PER_DPI); } } static void ReadTextSetFontStyleSzUnit(font_str, sb_font_str, style, sz_unit, size, dpi, pn_double_byte, pn_cur_sb_font, pn_cur_db_font) char *font_str, *sb_font_str; int style, sz_unit, size, dpi; int *pn_double_byte, *pn_cur_sb_font, *pn_cur_db_font; /* * set curFont, curStyle, and curSzUnit */ { char *psz=NULL; int len=strlen(font_str); if (len > 1 && *font_str == '\'' && font_str[len-1] == '\'') { char *psz1=(&font_str[1]); font_str[len-1] = '\0'; psz = font_str; while (*psz1 != '\0') *psz++ = *psz1++; *psz = '\0'; } if (fileVersion <= 33 && (psz=strchr(font_str, '%')) != NULL) { *pn_double_byte = TRUE; } if (*pn_double_byte) { if ((psz=strchr(font_str, '%')) != NULL) { *psz++ = '\0'; strcpy(sb_font_str, font_str); strcpy(font_str, psz); /* * e.g., font_str="Ryumin-Light-EUC-H", sb_font_str="Helvetica-Bold" */ } } /* * Set curFont and cur_sb_font so that they correspond to the text object. */ if (PRTGIF && !cmdLineOpenDisplay) { curFont = GetFontIndex(font_str, style, FALSE); if (*pn_double_byte) { *pn_cur_db_font = curFont; *pn_cur_sb_font = GetFontIndex(sb_font_str, style, FALSE); } } else { curFont = GetFontIndex(font_str, style, TRUE); if (curFont == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_FIND_FONT_USE_ALT), font_str, "Times"); Msg(gszMsgBox); SetFileModified(TRUE); curFont = FONT_TIM; if (*pn_double_byte) { /* * curFont would have been the double-byte font. * But since it can't be found and Times is used, it should * not be double-byte any more. */ *pn_double_byte = FALSE; } } if (*pn_double_byte) { *pn_cur_db_font = curFont; *pn_cur_sb_font = GetFontIndex(sb_font_str, style, TRUE); if (*pn_cur_sb_font == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_FIND_FONT_USE_ALT), sb_font_str, "Times"); Msg(gszMsgBox); SetFileModified(TRUE); *pn_cur_sb_font = FONT_TIM; } } } curStyle = style; if (fileVersion <= 29) { size = GetCompatibleSize(dpi, size); } if (fileVersion <= 35) { curSzUnit = FontSizeToSzUnit(size); } else { curSzUnit = sz_unit; } } static void ReadTextSetCanvasFont(text_ptr, dpi, size, asc, des, double_byte, db_mod_bytes, db_vertical, direction) struct TextRec *text_ptr; int dpi, size, asc, des, double_byte, db_mod_bytes, db_vertical, direction; /* * set canvasFontAsc, canvasFontDes, textCursorH, and canvasFontDoubleByte... */ { if (PRTGIF) { if (fileVersion < 10) { canvasFontAsc = pDrawFontAsc[OldFontIndex(dpi,curFont,size,curStyle)]; canvasFontDes = pDrawFontDes[OldFontIndex(dpi,curFont,size,curStyle)]; } else { canvasFontAsc = asc; canvasFontDes = des; } textCursorH = canvasFontAsc + canvasFontDes; text_ptr->read_only = FALSE; if (fileVersion > 31) { canvasFontDoubleByte = double_byte; canvasFontDirection = direction; /* * Need to fix this in the future. */ canvasFontDontReencode = FALSE; canvasFontDoubleByteModBytes = db_mod_bytes; canvasFontDoubleByteVertical = db_vertical; } else { canvasFontDoubleByte = FALSE; canvasFontDoubleByteModBytes = FALSE; canvasFontDoubleByteVertical = FALSE; canvasFontDirection = FontLeftToRight; canvasFontDontReencode = FALSE; } } else { /* * since fileVersion 37 there's no such a thing as a read_only * text object. If after SetCanvasFont() and * canvasFontSize != INVALID && * SzUnitToFontSize(curSzUnit) != canvasFontSize */ if (fileVersion <= 36) { text_ptr->read_only = SetCanvasFont(); } else { /* curFont, curStyle, and curSzUnit are undefined here */ } } } static int ReadStrSeg(FP, ppStrSeg) FILE *FP; StrSegInfo **ppStrSeg; { int font=0, style=0, sz_unit=0; int w=0, asc=0, des=0, min_lbearing=0, max_rextra=0; int underline_on=0, direction=0, new_alloc=FALSE, modified=FALSE; int double_byte=0, db_mod_bytes=0, db_vertical=0, dontreencode=FALSE; char *s=NULL, *line=NULL, color_str[40], font_str[MAXSTRING], *psz=NULL; StrSegInfo *pStrSeg=NULL; *font_str = '\0'; *ppStrSeg = NULL; if ((line=UtilGetALine(FP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanFileName, scanLineNum, "ReadStrSeg()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } scanLineNum++; s = FindChar((int)'(', line); s = ParseStr(s, (int)',', color_str, sizeof(color_str)); InitScan(s, ", \t\n"); if (fileVersion >= 37) { if (GETSTR("str_seg", font_str, "font_str") == INVALID || GETINT("str_seg", style, "style") == INVALID || GETINT("str_seg", sz_unit, "sz_unit") == INVALID || GETINT("str_seg", w, "w") == INVALID || GETINT("str_seg", asc, "asc") == INVALID || GETINT("str_seg", des, "des") == INVALID || GETINT("str_seg", min_lbearing, "min_lbearing") == INVALID || GETINT("str_seg", max_rextra, "max_rextra") == INVALID || GETINT("str_seg", underline_on, "underline_on") == INVALID || GETINT("str_seg", double_byte, "double_byte") == INVALID || GETINT("str_seg", db_mod_bytes, "db_mod_bytes") == INVALID || GETINT("str_seg", db_vertical, "db_vertical") == INVALID || GETINT("str_seg", direction, "direction") == INVALID) { return FALSE; } } free(line); font = GetFontIndexFromPSFontAndStyle(font_str, style, &double_byte, &modified); if (modified) SetFileModified(TRUE); if ((line=UtilGetALine(FP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanFileName, scanLineNum, "ReadStrSeg()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } scanLineNum++; psz = FindChar((int)'"', line); s = ReadString(psz); *(--s) = '\0'; pStrSeg = NewStrSeg(); DynStrSet(&pStrSeg->dyn_str, psz); free(line); pStrSeg->color = QuickFindColorIndex(NULL, color_str, &new_alloc, TRUE); UtilStrCpyN(pStrSeg->color_str, sizeof(pStrSeg->color_str), color_str); if (PRTGIF) { if (*font_str != '\0') { pStrSeg->font_name = UtilStrDup(font_str); if (pStrSeg->font_name == NULL) FailAllocMessage(); } } else { curFont = font; curStyle = style; curSzUnit = sz_unit; SetCanvasFont(); if (canvasFontSize != INVALID && SzUnitToFontSize(curSzUnit) != canvasFontSize) { SetFileModified(TRUE); sz_unit = curSzUnit = FontSizeToSzUnit(canvasFontSize); } double_byte = canvasFontDoubleByte; db_mod_bytes = canvasFontDoubleByteModBytes; db_vertical = canvasFontDoubleByteVertical; direction = canvasFontDirection; dontreencode = canvasFontDontReencode; } pStrSeg->font = font; pStrSeg->style = style; pStrSeg->sz_unit = sz_unit; pStrSeg->w = w; pStrSeg->asc = asc; pStrSeg->des = des; pStrSeg->min_lbearing = min_lbearing; pStrSeg->max_rextra = max_rextra; pStrSeg->underline_on = (underline_on & 0x1); pStrSeg->overline_on = ((underline_on & 0x2) == 0x2); pStrSeg->double_byte = double_byte; pStrSeg->double_byte_mod_bytes = db_mod_bytes; pStrSeg->double_byte_vertical = db_vertical; pStrSeg->direction = direction; pStrSeg->dontreencode = dontreencode; *ppStrSeg = pStrSeg; return TRUE; } static int ReadStrBlock(FP, pOwnerMiniLine, ppStrBlock) FILE *FP; MiniLineInfo *pOwnerMiniLine; StrBlockInfo **ppStrBlock; { int type=INVALID, w=0, asc=0, des=0, min_lbearing=0, max_rextra=0; int special_char_w=0, has_sup=0, has_sub=0; char *s=NULL, *line=NULL; StrBlockInfo *pStrBlock=NULL; StrSegInfo *pStrSeg=NULL; MiniLinesInfo *minilines=NULL; *ppStrBlock = NULL; if ((line=UtilGetALine(FP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanFileName, scanLineNum, "ReadStrBlock()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } scanLineNum++; if (*line == ']') { free(line); return TRUE; } s = FindChar((int)'(', line); InitScan(s, ", \t\n"); if (fileVersion >= 37) { if (GETINT("str_block", type, "type") == INVALID || GETINT("str_block", w, "w") == INVALID || GETINT("str_block", asc, "asc") == INVALID || GETINT("str_block", des, "des") == INVALID || GETINT("str_block", min_lbearing, "min_lbearing") == INVALID || GETINT("str_block", max_rextra, "max_rextra") == INVALID || GETINT("str_block", special_char_w, "special_char_w") == INVALID || GETINT("str_block", has_sup, "has_sup") == INVALID || GETINT("str_block", has_sub, "has_sub") == INVALID) { return FALSE; } } pStrBlock = NewStrBlock(); pStrBlock->type = type; pStrBlock->w = w; pStrBlock->asc = asc; pStrBlock->des = des; pStrBlock->min_lbearing = min_lbearing; pStrBlock->max_rextra = max_rextra; pStrBlock->special_char_w = special_char_w; free(line); switch (type) { case SB_SIMPLE: pStrSeg = NULL; if (!ReadStrSeg(FP, &pStrSeg)) { return FALSE; } pStrBlock->seg = pStrSeg; break; case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (has_sup) { minilines = NULL; if (!ReadMiniLines(FP, pStrBlock, &minilines) || minilines == NULL) { return FALSE; } pStrBlock->sup = minilines; } if (has_sub) { minilines = NULL; if (!ReadMiniLines(FP, pStrBlock, &minilines) || minilines == NULL) { return FALSE; } pStrBlock->sub = minilines; } if (type == SB_SUPSUB_CENTER) { pStrSeg = NULL; if (!ReadStrSeg(FP, &pStrSeg)) { return FALSE; } pStrBlock->seg = pStrSeg; } if ((line=UtilGetALine(FP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanFileName, scanLineNum, "ReadStrBlock()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } scanLineNum++; if (*line != ']') { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_TOK_IN_ABORT_READ), scanFileName, scanLineNum, ']', "ReadStrBlock()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } free(line); break; } pStrBlock->owner_mini_line = pOwnerMiniLine; *ppStrBlock = pStrBlock; return TRUE; } static int ReadMiniLine(FP, pOwnerMiniLines, ppMiniLine) FILE *FP; MiniLinesInfo *pOwnerMiniLines; MiniLineInfo **ppMiniLine; { int w=0, asc=0, des=0, min_lbearing=0, max_rextra=0, v_gap=0; char *s=NULL, *line=NULL; MiniLineInfo *pMiniLine=NULL; StrBlockInfo *pFirstStrBlock=NULL, *pLastStrBlock=NULL; *ppMiniLine = NULL; if ((line=UtilGetALine(FP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanFileName, scanLineNum, "ReadMiniLine()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } scanLineNum++; if (*line == ']') { free(line); return TRUE; } s = FindChar((int)'(', line); InitScan(s, ", \t\n"); if (fileVersion >= 37) { if (GETINT("mini_line", w, "w") == INVALID || GETINT("mini_line", asc, "asc") == INVALID || GETINT("mini_line", des, "des") == INVALID || GETINT("mini_line", min_lbearing, "min_lbearing") == INVALID || GETINT("mini_line", max_rextra, "max_rextra") == INVALID || GETINT("mini_line", v_gap, "v_gap") == INVALID) { return FALSE; } } pMiniLine = NewMiniLine(); pMiniLine->w = w; pMiniLine->asc = asc; pMiniLine->des = des; pMiniLine->min_lbearing = min_lbearing; pMiniLine->max_rextra = max_rextra; pMiniLine->v_gap = v_gap; free(line); for (;;) { StrBlockInfo *pStrBlock=NULL; if (!ReadStrBlock(FP, pMiniLine, &pStrBlock)) { FreeStrBlockList(pFirstStrBlock); return FALSE; } if (pStrBlock == NULL) { /* shouldn't come here if num_lines is correct */ break; } InsertStrBlock(pLastStrBlock, NULL, pStrBlock, &pFirstStrBlock, &pLastStrBlock); } pMiniLine->first_block = pFirstStrBlock; pMiniLine->last_block = pLastStrBlock; pMiniLine->owner_minilines = pOwnerMiniLines; *ppMiniLine = pMiniLine; return TRUE; } int ReadMiniLines(FP, pOwnerBlock, ppMiniLines) FILE *FP; StrBlockInfo *pOwnerBlock; MiniLinesInfo **ppMiniLines; { int w=0, h=0, min_lbearing=0, max_rextra=0; int just=0, v_space=0, baseline_offset=0; char *s=NULL, *line=NULL; MiniLinesInfo *minilines=NULL; MiniLineInfo *pFirstMiniLine=NULL, *pLastMiniLine=NULL; *ppMiniLines = NULL; if ((line=UtilGetALine(FP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanFileName, scanLineNum, "ReadMiniLines()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } scanLineNum++; s = FindChar((int)'(', line); InitScan(s, ", \t\n"); if (fileVersion >= 37) { if (GETINT("minilines", w, "w") == INVALID || GETINT("minilines", h, "h") == INVALID || GETINT("minilines", min_lbearing, "min_lbearing") == INVALID || GETINT("minilines", max_rextra, "max_rextra") == INVALID || GETINT("minilines", just, "just") == INVALID || GETINT("minilines", v_space, "v_space") == INVALID || GETINT("minilines", baseline_offset, "baseline_offset") == INVALID) { return FALSE; } } minilines = NewMiniLines(); minilines->w = w; minilines->h = h; minilines->min_lbearing = min_lbearing; minilines->max_rextra = max_rextra; minilines->just = just; minilines->v_space = v_space; minilines->baseline_offset = baseline_offset; free(line); for (;;) { MiniLineInfo *pMiniLine=NULL; if (!ReadMiniLine(FP, minilines, &pMiniLine)) { FreeMiniLineList(pFirstMiniLine); return FALSE; } if (pMiniLine == NULL) { /* shouldn't come here if num_lines is correct */ break; } if (pMiniLine->first_block == NULL) { StrBlockInfo *pStrBlock=CreateStrBlockFromString("", pMiniLine); pMiniLine->first_block = pMiniLine->last_block = pStrBlock; } InsertMiniLine(pLastMiniLine, NULL, pMiniLine, &pFirstMiniLine, &pLastMiniLine); } minilines->first = pFirstMiniLine; minilines->last = pLastMiniLine; minilines->owner_block = pOwnerBlock; *ppMiniLines = minilines; return TRUE; } static int ReadTextLines(FP, ObjPtr, text_ptr, color_str, num_lines, has_ps_bitmap, cur_sb_font, cur_db_font, double_byte, db_mod_bytes, db_vertical, direction, x, baseline_y, text_w, pn_max_len, pn_max_h) FILE *FP; struct ObjRec **ObjPtr; struct TextRec *text_ptr; char *color_str; int num_lines, has_ps_bitmap, cur_sb_font, cur_db_font; int double_byte, db_mod_bytes, db_vertical, direction; int x, baseline_y, *pn_max_len, *pn_max_h; /* * (Note: text_w is only used for fileVersion <= 36) */ { int len=0; /* * Set readingTextObject to TRUE to *enable* the setting of the read_only * fields in the string segments and the text object. */ readingTextObject = TRUE; if (deserializingFile) ReadCreatorID(FP, ObjPtr); if (fileVersion <= 36) { int i=0, line_h=canvasFontAsc+canvasFontDes+textVSpace; for (i=0; i < num_lines; i++) { int new_alloc=FALSE; char *tmp_str=NULL, *s=NULL, *line=NULL; MiniLineInfo *pMiniLine=NULL; StrSegInfo *pStrSeg=NULL; RecalcMetricsInfo rmi; if ((line=UtilGetALine(FP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanFileName, scanLineNum, "ReadTextLines()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } scanLineNum++; tmp_str = FindChar((int)'"', line); s = ReadString(tmp_str); *(--s) = '\0'; pMiniLine = NewMiniLine(); if (double_byte) { /* * Note: should not get here for PRTGIF because * double_byte is always 0 in any released version * of tgif for fileVersion <= 36. */ struct StrRec *pStr=NULL, *pStr1=NULL; pStr = SegmentDoubleByteString(tmp_str); for (pStr1=pStr; pStr1 != NULL; pStr1=pStr1->next) { int str_seg_double_byte=((*pStr1->dyn_str.s) & 0x80); StrBlockInfo *pStrBlock=NewStrBlock(); pStrBlock->prev = pMiniLine->last_block; pStrBlock->next = NULL; if (pMiniLine->first_block == NULL) { pMiniLine->first_block = pStrBlock; } else { pMiniLine->last_block->next = pStrBlock; } pMiniLine->last_block = pStrBlock; pStrBlock->type = SB_SIMPLE; pStrBlock->seg = pStrSeg = NewStrSeg(); DynStrSet(&pStrSeg->dyn_str, pStr1->dyn_str.s); pStrSeg->color = QuickFindColorIndex(NULL, color_str, &new_alloc, TRUE); UtilStrCpyN(pStrSeg->color_str, sizeof(pStrSeg->color_str), color_str); curFont = (str_seg_double_byte ? cur_db_font : cur_sb_font); if (!PRTGIF) { SetCanvasFont(); if (canvasFontSize != INVALID && SzUnitToFontSize(curSzUnit) != canvasFontSize) { SetFileModified(TRUE); curSzUnit = FontSizeToSzUnit(canvasFontSize); } } pStrSeg->double_byte = canvasFontDoubleByte; pStrSeg->double_byte_mod_bytes = canvasFontDoubleByteModBytes; pStrSeg->double_byte_vertical = canvasFontDoubleByteVertical; pStrSeg->font = curFont; pStrSeg->style = curStyle; pStrSeg->sz_unit = curSzUnit; pStrSeg->direction = direction; pStrSeg->read_only = text_ptr->read_only; pStrSeg->orig_w = text_ptr->orig_w; /* valid if read_only */ pStrSeg->orig_h = text_ptr->orig_h; /* valid if read_only */ pStrSeg->underline_on = curUnderlineOn; pStrSeg->overline_on = curOverlineOn; pStrSeg->asc = canvasFontAsc; pStrSeg->des = canvasFontDes; /* * pStrSeg->w = text_w; * * Well, this doesn't really work here for PRTGIF. But since * double-byte for version <= 36 is really not supported, * (and the file does not contain enough information) * this bug really cannot be fixed. */ } FreeStrList(pStr); } else { pMiniLine->first_block = pMiniLine->last_block = NewStrBlock(); pMiniLine->first_block->type = SB_SIMPLE; pMiniLine->first_block->seg = pStrSeg = NewStrSeg(); DynStrSet(&pStrSeg->dyn_str, tmp_str); pStrSeg->color = QuickFindColorIndex(NULL, color_str, &new_alloc, TRUE); UtilStrCpyN(pStrSeg->color_str, sizeof(pStrSeg->color_str), color_str); if (!PRTGIF) { SetCanvasFont(); if (canvasFontSize != INVALID && SzUnitToFontSize(curSzUnit) != canvasFontSize) { SetFileModified(TRUE); curSzUnit = FontSizeToSzUnit(canvasFontSize); } } pStrSeg->font = curFont; pStrSeg->style = curStyle; pStrSeg->sz_unit = curSzUnit; pStrSeg->direction = direction; pStrSeg->read_only = text_ptr->read_only; pStrSeg->orig_w = text_ptr->orig_w; /* valid if read_only */ pStrSeg->orig_h = text_ptr->orig_h; /* valid if read_only */ pStrSeg->underline_on = curUnderlineOn; pStrSeg->overline_on = curOverlineOn; pStrSeg->asc = canvasFontAsc; pStrSeg->des = canvasFontDes; pStrSeg->w = text_w; } memset(&rmi, 0, sizeof(RecalcMetricsInfo)); rmi.x = rmi.orig_x = x; rmi.orig_baseline_y = text_ptr->baseline_y; rmi.baseline_y = baseline_y; if (PRTGIF) { dontRecalcStrSegMetrics = TRUE; RecalcMiniLineMetrics(pMiniLine, &rmi); dontRecalcStrSegMetrics = FALSE; } else { PushCurFont(); if (!RecalcMiniLineMetrics(pMiniLine, &rmi)) { text_ptr->read_only = TRUE; } PopCurFont(); } InsertMiniLine(lastMiniLine, NULL, pMiniLine, &firstMiniLine, &lastMiniLine); if (PRTGIF) { len = strlen(tmp_str); /* assume string width = 1 pixel per char */ if (len > (*pn_max_len)) (*pn_max_len) = len; } baseline_y += line_h; free(line); } *pn_max_h = baseline_y - text_ptr->baseline_y; if (has_ps_bitmap) { sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_FIELD_IN_ABORT_READ), scanFileName, scanLineNum, "has_ps_bitmap", "ReadTextLines()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } } else { MiniLinesInfo *minilines=NULL; MiniLineInfo *pMiniLine=NULL; int v_space=0; PushCurFont(); ReadMiniLines(FP, NULL, &minilines); PopCurFont(); if (minilines == NULL) { return FALSE; } firstMiniLine = minilines->first; lastMiniLine = minilines->last; v_space = minilines->v_space; free(minilines); for (pMiniLine=firstMiniLine; pMiniLine != NULL; pMiniLine=pMiniLine->next) { RecalcMetricsInfo rmi; memset(&rmi, 0, sizeof(RecalcMetricsInfo)); rmi.x = rmi.orig_x = x; rmi.orig_baseline_y = text_ptr->baseline_y; rmi.baseline_y = baseline_y; if (PRTGIF) { dontRecalcStrSegMetrics = TRUE; RecalcMiniLineMetrics(pMiniLine, &rmi); dontRecalcStrSegMetrics = FALSE; len = pMiniLine->w; if (len > (*pn_max_len)) (*pn_max_len) = len; } else { PushCurFont(); if (!RecalcMiniLineMetrics(pMiniLine, &rmi)) { text_ptr->read_only = TRUE; } PopCurFont(); } baseline_y += pMiniLine->des + v_space; if (pMiniLine->next != NULL) { baseline_y += pMiniLine->next->asc; } } *pn_max_h = baseline_y - text_ptr->baseline_y; } readingTextObject = FALSE; return TRUE; } static void OldStyleRotateGetFinalOBBoxLtXY(ObjPtr, rotate, text_just, pnFinalLtX, pnFinalLtY) struct ObjRec *ObjPtr; int rotate, text_just, *pnFinalLtX, *pnFinalLtY; /* * For fileVersion >= 33, rotate is always ROTATE0. So we need * to convert the old format to the new one. The way we will * do it is to: * 1) Calculate where the final obbox.ltx and obbox.lty will be. * 2) Rotate the object. * 3) Move the object to matched the final position calculated in (1). */ { /* * This this point, coordinates in ObjPtr have been computed using ROTATE0. * Remember, positive rotate is clockwise. * In the old style, for JUST_L, pivot is left top corner, for JUST_C, pivot * is center top corner, and for JUST_R, pivot is right top corner. */ int x=ObjPtr->x, y=ObjPtr->y, ltx=ObjPtr->obbox.ltx, lty=ObjPtr->obbox.lty; int w=ObjPtr->obbox.rbx-ltx, h=ObjPtr->obbox.rby-lty; switch (rotate) { case ROTATE90: switch (text_just) { case JUST_L: ltx=x-h; lty=y; break; case JUST_C: ltx=x-h; lty=y-(w>>1); break; case JUST_R: ltx=x-h; lty=y-w; break; } break; case ROTATE180: switch (text_just) { case JUST_L: ltx=x-(w-(w>>1)); lty=y-h; break; case JUST_C: ltx=x-w; lty=y-h; break; case JUST_R: ltx=x; lty=y-h; break; } break; case ROTATE270: switch (text_just) { case JUST_L: ltx=x; lty=y-w; break; case JUST_C: ltx=x; lty=y-(w-(w>>1)); break; case JUST_R: ltx=x; lty=y; break; } break; } *pnFinalLtX = ltx; *pnFinalLtY = lty; } void ReadTextObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { int max_len=0, max_h=0, len; struct TextRec *text_ptr; char color_str[40], bg_color_str[40], *s, *c_ptr, font_str[MAXSTRING]; char sb_font_str[MAXSTRING], inbuf[MAXSTRING+1]; char cust_font_name[MAXSTRING+1]; /* this is not really used any more */ int has_ps_bitmap=FALSE; int cur_sb_font=(-1), cur_db_font=(-1), baseline_y=0; int num_lines=0, x, y, font=0, style=0, size=0, sz_unit=0, id=0; int text_just=0, rotate=0, pen=0, rotation=0, adj_bbox_for_third_party=FALSE; int obbox_w=0, obbox_h=0, dpi=0, asc=0, des=0, fill=0, trans_pat=FALSE; int locked=FALSE, max_rextra=0, v_space=0, new_alloc=FALSE; int underline_on=FALSE, underline=2, min_lbearing=0; int underline_y_offset=0, overline_y_offset=0; int double_byte=FALSE, compressed=FALSE; int db_mod_bytes=FALSE, db_vertical=FALSE; int transformed=FALSE, invisible=FALSE; int direction=FontLeftToRight, real_x=0, real_y=0; int first_block_asc=0, first_block_des=0, text_w=0, text_h=0; struct XfrmMtrxRec *ctm=NULL; struct BBRec orig_obbox, orig_bbox; dpi = FONT_DPI_75; fill = NONEPAT; v_space = 0; *cust_font_name = '\0'; *font_str = *sb_font_str = '\0'; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_str, sizeof(color_str)); InitScan(s, ", \t\n"); rotate = 0; pen = 1; rotation = 0; if (fileVersion <= 2) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETINT("text", font, "font") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID) { return; } id = objId++; } else if (fileVersion <= 6) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETINT("text", font, "font") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID) { return; } id = objId++; } else if (fileVersion <= 7) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETINT("text", font, "font") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID) { return; } id = objId++; } else if (fileVersion <= 9) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETINT("text", font, "font") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", dpi, "dpi") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 10) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETINT("text", font, "font") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", dpi, "dpi") == INVALID || GETINT("text", asc, "ascent") == INVALID || GETINT("text", des, "descent") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 12) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETINT("text", font, "font") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", dpi, "dpi") == INVALID || GETINT("text", asc, "ascent") == INVALID || GETINT("text", des, "descent") == INVALID || GETINT("text", fill, "fill") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 13) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETINT("text", font, "font") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", dpi, "dpi") == INVALID || GETINT("text", asc, "ascent") == INVALID || GETINT("text", des, "descent") == INVALID || GETINT("text", fill, "fill") == INVALID || GETINT("text", v_space, "vertical spacing") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 25) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETINT("text", font, "font") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", dpi, "dpi") == INVALID || GETINT("text", asc, "ascent") == INVALID || GETINT("text", des, "descent") == INVALID || GETINT("text", fill, "fill") == INVALID || GETINT("text", v_space, "vertical spacing") == INVALID || GETINT("text", rotation, "rotation") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 29) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETINT("text", font, "font") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", dpi, "dpi") == INVALID || GETINT("text", asc, "ascent") == INVALID || GETINT("text", des, "descent") == INVALID || GETINT("text", fill, "fill") == INVALID || GETINT("text", v_space, "vertical spacing") == INVALID || GETINT("text", rotation, "rotation") == INVALID || GETINT("text", locked, "locked") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 32) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETSTR("text", font_str, "font_str") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", dpi, "dpi") == INVALID || GETINT("text", asc, "ascent") == INVALID || GETINT("text", des, "descent") == INVALID || GETINT("text", fill, "fill") == INVALID || GETINT("text", v_space, "vertical spacing") == INVALID || GETINT("text", rotation, "rotation") == INVALID || GETINT("text", locked, "locked") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 33) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETSTR("text", font_str, "font_str") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", dpi, "dpi") == INVALID || GETINT("text", asc, "ascent") == INVALID || GETINT("text", des, "descent") == INVALID || GETINT("text", fill, "fill") == INVALID || GETINT("text", v_space, "vertical spacing") == INVALID || GETINT("text", rotation, "rotation") == INVALID || GETINT("text", locked, "locked") == INVALID || GETINT("text", underline_on, "underline_on") == INVALID || GETINT("text", underline, "underline") == INVALID || GETINT("text", min_lbearing, "min_lbearing") == INVALID || GETINT("text", max_rextra, "max_rextra") == INVALID || GETINT("text", double_byte, "double_byte") == INVALID || GETINT("text", direction, "direction") == INVALID || GETSTR("text", cust_font_name, "cust_font_name") == INVALID || GETINT("text", compressed, "compressed") == INVALID || GETINT("text", transformed, "transformed") == INVALID || GETINT("text", invisible, "invisible") == INVALID) { return; } if (id >= objId) objId = id+1; len = strlen(cust_font_name); if (len >= 2 && *cust_font_name=='"' && cust_font_name[len-1]=='"') { for (c_ptr=cust_font_name; c_ptr[2] != '\0'; c_ptr++) { *c_ptr = c_ptr[1]; } *c_ptr = '\0'; } } else if (fileVersion <= 34) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETSTR("text", font_str, "font_str") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", dpi, "dpi") == INVALID || GETINT("text", asc, "ascent") == INVALID || GETINT("text", des, "descent") == INVALID || GETINT("text", fill, "fill") == INVALID || GETINT("text", v_space, "vertical spacing") == INVALID || GETINT("text", rotation, "rotation") == INVALID || GETINT("text", locked, "locked") == INVALID || GETINT("text", underline_on, "underline_on") == INVALID || GETINT("text", underline, "underline") == INVALID || GETINT("text", min_lbearing, "min_lbearing") == INVALID || GETINT("text", max_rextra, "max_rextra") == INVALID || GETINT("text", double_byte, "double_byte") == INVALID || GETINT("text", direction, "direction") == INVALID || GETSTR("text", cust_font_name, "cust_font_name") == INVALID || GETINT("text", compressed, "compressed") == INVALID || GETINT("text", transformed, "transformed") == INVALID || GETINT("text", invisible, "invisible") == INVALID || GETINT("text", has_ps_bitmap, "has_ps_bitmap") == INVALID) { return; } if (id >= objId) objId = id+1; len = strlen(cust_font_name); if (len >= 2 && *cust_font_name=='"' && cust_font_name[len-1]=='"') { for (c_ptr=cust_font_name; c_ptr[2] != '\0'; c_ptr++) { *c_ptr = c_ptr[1]; } *c_ptr = '\0'; } } else if (fileVersion <= 35) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETSTR("text", font_str, "font_str") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", size, "size") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", dpi, "dpi") == INVALID || GETINT("text", asc, "ascent") == INVALID || GETINT("text", des, "descent") == INVALID || GETINT("text", fill, "fill") == INVALID || GETINT("text", v_space, "vertical spacing") == INVALID || GETINT("text", rotation, "rotation") == INVALID || GETINT("text", locked, "locked") == INVALID || GETINT("text", underline_on, "underline_on") == INVALID || GETINT("text", underline, "underline") == INVALID || GETINT("text", min_lbearing, "min_lbearing") == INVALID || GETINT("text", max_rextra, "max_rextra") == INVALID || GETINT("text", double_byte, "double_byte") == INVALID || GETINT("text", direction, "direction") == INVALID || GETSTR("text", cust_font_name, "cust_font_name") == INVALID || GETINT("text", compressed, "compressed") == INVALID || GETINT("text", transformed, "transformed") == INVALID || GETINT("text", invisible, "invisible") == INVALID || GETINT("text", has_ps_bitmap, "has_ps_bitmap") == INVALID || GETINT("text", db_mod_bytes, "double_byte_mod_bytes") == INVALID || GETINT("text", db_vertical, "double_byte_vertical") == INVALID || GETINT("text", trans_pat, "trans_pat") == INVALID) { return; } if (id >= objId) objId = id+1; len = strlen(cust_font_name); if (len >= 2 && *cust_font_name=='"' && cust_font_name[len-1]=='"') { for (c_ptr=cust_font_name; c_ptr[2] != '\0'; c_ptr++) { *c_ptr = c_ptr[1]; } *c_ptr = '\0'; } } else if (fileVersion <= 36) { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETSTR("text", font_str, "font_str") == INVALID || GETINT("text", style, "style") == INVALID || GETINT("text", sz_unit, "size unit") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", rotate, "rotate") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", dpi, "dpi") == INVALID || GETINT("text", asc, "ascent") == INVALID || GETINT("text", des, "descent") == INVALID || GETINT("text", fill, "fill") == INVALID || GETINT("text", v_space, "vertical spacing") == INVALID || GETINT("text", rotation, "rotation") == INVALID || GETINT("text", locked, "locked") == INVALID || GETINT("text", underline_on, "underline_on") == INVALID || GETINT("text", underline, "underline") == INVALID || GETINT("text", min_lbearing, "min_lbearing") == INVALID || GETINT("text", max_rextra, "max_rextra") == INVALID || GETINT("text", double_byte, "double_byte") == INVALID || GETINT("text", direction, "direction") == INVALID || GETSTR("text", cust_font_name, "cust_font_name") == INVALID || GETINT("text", compressed, "compressed") == INVALID || GETINT("text", transformed, "transformed") == INVALID || GETINT("text", invisible, "invisible") == INVALID || GETINT("text", has_ps_bitmap, "has_ps_bitmap") == INVALID || GETINT("text", db_mod_bytes, "double_byte_mod_bytes") == INVALID || GETINT("text", db_vertical, "double_byte_vertical") == INVALID || GETINT("text", trans_pat, "trans_pat") == INVALID) { return; } if (id >= objId) objId = id+1; len = strlen(cust_font_name); if (len >= 2 && *cust_font_name=='"' && cust_font_name[len-1]=='"') { for (c_ptr=cust_font_name; c_ptr[2] != '\0'; c_ptr++) { *c_ptr = c_ptr[1]; } *c_ptr = '\0'; } } else { if (GETINT("text", x, "x") == INVALID || GETINT("text", y, "y") == INVALID || GETINT("text", num_lines, "num_lines") == INVALID || GETINT("text", text_just, "text_just") == INVALID || GETINT("text", pen, "pen") == INVALID || GETINT("text", obbox_w, "bbox w") == INVALID || GETINT("text", obbox_h, "bbox h") == INVALID || GETINT("text", id, "id") == INVALID || GETINT("text", first_block_asc, "first block ascent") == INVALID || GETINT("text", first_block_des, "first block descent") == INVALID || GETINT("text", fill, "fill") == INVALID || GETINT("text", v_space, "vertical spacing") == INVALID || GETINT("text", rotation, "rotation") == INVALID || GETINT("text", locked, "locked") == INVALID || GETINT("text", underline, "underline") == INVALID || GETINT("text", text_w, "text_w") == INVALID || GETINT("text", text_h, "text_h") == INVALID || GETINT("text", min_lbearing, "min_lbearing") == INVALID || GETINT("text", max_rextra, "max_rextra") == INVALID || GETSTR("text", cust_font_name, "cust_font_name") == INVALID || GETINT("text", compressed, "compressed") == INVALID || GETINT("text", transformed, "transformed") == INVALID || GETINT("text", invisible, "invisible") == INVALID || GETINT("text", trans_pat, "trans_pat") == INVALID || GETINT("text", baseline_y, "baseline_y") == INVALID) { return; } /* * This is a hack! If the file version becomes >= 38, this code * must be removed! */ if (GETSTR("text", bg_color_str, "bg_color_str") == INVALID) { /* should not get here because we should have read in: "[" */ return; } else if (*bg_color_str == '[') { *bg_color_str = '\0'; } else if (*bg_color_str == '\'') { UtilRemoveQuotes(bg_color_str); } if (id >= objId) objId = id+1; len = strlen(cust_font_name); if (len >= 2 && *cust_font_name=='"' && cust_font_name[len-1]=='"') { for (c_ptr=cust_font_name; c_ptr[2] != '\0'; c_ptr++) { *c_ptr = c_ptr[1]; } *c_ptr = '\0'; } } if (fileVersion >= 33 && transformed) { int do_adjust=FALSE, dx=0, t[2]; double dreal_x, dreal_y, m[4]; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, "); ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ctm == NULL) FailAllocMessage(); if (GETDBL("text", dreal_x, "real_x") == INVALID || GETDBL("text", dreal_y, "real_y") == INVALID || GETINT("text", orig_obbox.ltx, "orig_obbox.ltx") == INVALID || GETINT("text", orig_obbox.lty, "orig_obbox.lty") == INVALID || GETINT("text", orig_obbox.rbx, "orig_obbox.rbx") == INVALID || GETINT("text", orig_obbox.rby, "orig_obbox.rby") == INVALID || GETDBL("text", m[CTM_SX], "CTM_SX") == INVALID || GETDBL("text", m[CTM_SIN], "CTM_SIN") == INVALID || GETDBL("text", m[CTM_MSIN], "CTM_MSIN") == INVALID || GETDBL("text", m[CTM_SY], "CTM_SY") == INVALID || GETINT("text", t[CTM_TX], "CTM_TX") == INVALID || GETINT("text", t[CTM_TY], "CTM_TY") == INVALID || GETINT("text", orig_bbox.ltx, "orig_bbox.ltx") == INVALID || GETINT("text", orig_bbox.lty, "orig_bbox.lty") == INVALID || GETINT("text", orig_bbox.rbx, "orig_bbox.rbx") == INVALID || GETINT("text", orig_bbox.rby, "orig_bbox.rby") == INVALID) { return; } real_x = round(dreal_x); real_y = round(dreal_y); ctm->m[CTM_SX] = m[CTM_SX]; ctm->m[CTM_SIN] = m[CTM_SIN]; ctm->m[CTM_MSIN] = m[CTM_MSIN]; ctm->m[CTM_SY] = m[CTM_SY]; ctm->t[CTM_TX] = t[CTM_TX]; ctm->t[CTM_TY] = t[CTM_TY]; if (orig_obbox.ltx == 0 && orig_obbox.lty == 0 && orig_obbox.rbx == 0 && orig_obbox.rby == 0) { adj_bbox_for_third_party = TRUE; } switch (text_just) { case JUST_L: if (real_x != orig_obbox.ltx) { dx = real_x - orig_obbox.ltx; do_adjust = TRUE; } break; case JUST_C: if (real_x != ((orig_obbox.ltx+orig_obbox.rbx)>>1)) { dx = real_x - ((orig_obbox.ltx+orig_obbox.rbx)>>1); do_adjust = TRUE; } break; case JUST_R: if (real_x != orig_obbox.rbx) { dx = real_x - orig_obbox.rbx; do_adjust = TRUE; } break; } if (adj_bbox_for_third_party || do_adjust) { orig_obbox.ltx += dx; orig_obbox.rbx += dx; orig_bbox.ltx += dx; orig_bbox.rbx += dx; } } if (fileVersion <= 36) { baseline_y = y+asc; if (ctm == NULL) { text_w = obbox_w; text_h = obbox_h; } else { text_w = orig_obbox.rbx-orig_obbox.ltx; text_h = orig_obbox.rby-orig_obbox.lty; } first_block_asc = asc; first_block_des = des; } else { asc = first_block_asc; des = first_block_des; } fill = UpgradePenFill(fill); pen = UpgradePenFill(pen); *ObjPtr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (*ObjPtr == NULL) FailAllocMessage(); memset(*ObjPtr, 0, sizeof(struct ObjRec)); text_ptr = (struct TextRec *)malloc(sizeof(struct TextRec)); if (text_ptr == NULL) FailAllocMessage(); memset(text_ptr, 0, sizeof(struct TextRec)); text_ptr->lines = num_lines; text_ptr->cached_bitmap = None; text_ptr->cached_zoom = 0; if (!PRTGIF) SaveCurFont(); if (fileVersion <= 36) { /* set curFont, curStyle, and curSzUnit */ if (fileVersion <= 29) { GetCompatibleFontName(font, style, font_str); } ReadTextSetFontStyleSzUnit(font_str, sb_font_str, style, sz_unit, size, dpi, &double_byte, &cur_sb_font, &cur_db_font); } else { /* curFont, curStyle, and curSzUnit are undefined here */ } if (fileVersion >= 37) { UncombineOverUnderYOffsets(underline, &underline_y_offset, &overline_y_offset); } else { underline_y_offset = underline; overline_y_offset = 0; } transPat = (*ObjPtr)->trans_pat = trans_pat; textJust = text_ptr->minilines.just = text_just; textVSpace = text_ptr->minilines.v_space = v_space; canvasLineAsc = asc; canvasLineDes = des; penPat = text_ptr->pen = pen; objFill = text_ptr->fill = fill; curUnderlineOn = (underline_on & 0x1); curOverlineOn = ((underline_on & 0x2) == 0x2); curUnderlineYOffset = text_ptr->underline_y_offset = underline_y_offset; curOverlineYOffset = text_ptr->overline_y_offset = overline_y_offset; curOverlineOn = FALSE; /* * set canvasFontAsc, canvasFontDes, textCursorH, and canvasFontDoubleByte... */ ReadTextSetCanvasFont(text_ptr, dpi, size, asc, des, double_byte, db_mod_bytes, db_vertical, direction); if (!PRTGIF && fileVersion <= 36) { baseline_y = y+canvasFontAsc; } if (text_ptr->read_only) { switch (rotate) { case ROTATE0: case ROTATE180: text_ptr->orig_w = obbox_w; text_ptr->orig_h = obbox_h; break; case ROTATE90: case ROTATE270: text_ptr->orig_w = obbox_h; text_ptr->orig_h = obbox_w; break; } text_ptr->min_lbearing = min_lbearing; text_ptr->max_rextra = max_rextra; } else { text_ptr->orig_w = text_ptr->orig_h = 0; text_ptr->min_lbearing = text_ptr->max_rextra = 0; } text_ptr->baseline_y = baseline_y; /* * Now read all the lines in. */ firstMiniLine = lastMiniLine = NULL; if (!ReadTextLines(FP, ObjPtr, text_ptr, color_str, num_lines, has_ps_bitmap, cur_sb_font, cur_db_font, double_byte, db_mod_bytes, db_vertical, direction, x, baseline_y, text_w, &max_len, &max_h)) { if (!PRTGIF) RestoreCurFont(); return; } text_ptr->minilines.first = firstMiniLine; text_ptr->minilines.last = lastMiniLine; firstMiniLine = lastMiniLine = NULL; textCurIndex = 0; if (!PRTGIF && !text_ptr->read_only) { RecalcTextMetrics(text_ptr, x, text_ptr->baseline_y); max_len = text_ptr->w; max_h = text_ptr->h; min_lbearing = text_ptr->min_lbearing; max_rextra = text_ptr->max_rextra; } if (!PRTGIF) { if (text_ptr->minilines.baseline_offset != 0 || text_ptr->minilines.first->v_gap != 0) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "Non-zero first baseline_offset or v_gap in ReadTextObj()", "Fixed"); #endif /* _TGIF_DBG */ text_ptr->minilines.baseline_offset = 0; text_ptr->minilines.first->v_gap = 0; } y = text_ptr->baseline_y - text_ptr->minilines.first->asc + text_ptr->minilines.first->v_gap; } text_ptr->min_lbearing = min_lbearing; text_ptr->max_rextra = max_rextra; (*ObjPtr)->type = OBJ_TEXT; (*ObjPtr)->color = QuickFindColorIndex(*ObjPtr, color_str, &new_alloc, TRUE); UtilStrCpyN((*ObjPtr)->color_str, sizeof((*ObjPtr)->color_str), color_str); (*ObjPtr)->dirty = FALSE; (*ObjPtr)->id = id; (*ObjPtr)->rotation = rotation; (*ObjPtr)->locked = locked; (*ObjPtr)->detail.t = text_ptr; (*ObjPtr)->x = x; (*ObjPtr)->y = y; /* NOTE: this y is derived from text_ptr->baseline_y */ (*ObjPtr)->ctm = ctm; (*ObjPtr)->invisible = invisible; if (ctm != NULL) { memcpy(&(*ObjPtr)->orig_obbox, &orig_obbox, sizeof(struct BBRec)); memcpy(&text_ptr->orig_bbox, &orig_bbox, sizeof(struct BBRec)); (*ObjPtr)->x = real_x; (*ObjPtr)->y = real_y; if (adj_bbox_for_third_party) { SetTextOrigBBoxes(*ObjPtr, text_just, max_len, max_h, min_lbearing, max_rextra, rotate); } GetTransformedOBBoxOffsetVs(*ObjPtr, (*ObjPtr)->rotated_obbox); } /* * This this point, (*ObjPtr)->x, (*ObjPtr)->y, text_just, obbox_w, obbox_h, * max_len, min_lbearing, max_rextra, and rotate are all valid */ if (PRTGIF && fileVersion > 6) { switch (rotate) { case ROTATE0: case ROTATE180: SetTextBBox(*ObjPtr, text_just, obbox_w, obbox_h, min_lbearing, max_rextra, rotate); break; case ROTATE90: case ROTATE270: SetTextBBox(*ObjPtr, text_just, obbox_h, obbox_w, min_lbearing, max_rextra, rotate); break; } } else if (!PRTGIF && text_ptr->read_only) { SetTextBBox(*ObjPtr, text_just, text_ptr->orig_w, text_ptr->orig_h, min_lbearing, max_rextra, rotate); } else { if (fileVersion < 33 && rotate != ROTATE0) { /* pretend there's no rotate so we can get the coordiantes for obbox */ SetTextBBox(*ObjPtr, text_just, max_len, max_h, min_lbearing, max_rextra, ROTATE0); } else { SetTextBBox(*ObjPtr, text_just, max_len, max_h, min_lbearing, max_rextra, rotate); } } if (fileVersion < 33 && rotate != ROTATE0) { int ltx=0, lty=0, saved_rotation_increment=rotationIncrement; /* * For fileVersion >= 33, rotate is always ROTATE0. So we need * to convert the old format to the new one. The way we will * do it is to: * 1) Calculate where the final obbox.ltx and obbox.lty will be. * 2) Rotate the object. * 3) Move the object to matched the final position calculated in (1). * * Well, turns out this is not needed! */ OldStyleRotateGetFinalOBBoxLtXY(*ObjPtr, rotate, text_just, <x, <y); SetRotatePivotByObject(*ObjPtr); switch (rotate) { case ROTATE90: rotationIncrement = (90<<6); break; case ROTATE180: rotationIncrement = (180<<6); break; case ROTATE270: rotationIncrement = (270<<6); break; } RotateObjClockWise(*ObjPtr); rotationIncrement = saved_rotation_increment; } if (!PRTGIF && ctm != NULL && strcmp(gGenerateByInfo.name, "pstoedit") == 0) { int asc=text_ptr->minilines.first->first_block->asc, dx=0, dy=0; text_ptr->baseline_y = (*ObjPtr)->y + asc; TransformPointThroughCTM(0, asc, ctm, &dx, &dy); MoveObj(*ObjPtr, -dx, -dy); } if (!PRTGIF) RestoreCurFont(); } void UpdCurTextBBox() { struct TextRec *text_ptr=curTextObj->detail.t; MiniLinesInfo *minilines=NULL; if (!textCursorShown) return; RecalcTextMetrics(text_ptr, textOrigX, text_ptr->baseline_y); minilines = (&text_ptr->minilines); SetTextCurXY(); if (textHighlight) SetTextEndXY(); UpdateEditTextArea(minilines->w, minilines->h, minilines->min_lbearing, minilines->max_rextra); } void AdjustCurText(XOff, YOff) int XOff, YOff; { textOrigX += XOff; textOrigY += YOff; textOrigBaselineY += YOff; textCurX += XOff; textCurY += YOff; textCurBaselineY += YOff; textEndX += XOff; textEndY += YOff; textEndBaselineY += YOff; } void PrepareZoomCurText(AbsXc, AbsYc) int *AbsXc, *AbsYc; { switch (textJust) { case JUST_L: *AbsXc = ABS_X(textOrigX+(textW>>1)); break; case JUST_C: *AbsXc = ABS_X(textOrigX); break; case JUST_R: *AbsXc = ABS_X(textOrigX-(textW>>1)); break; } *AbsYc = ABS_Y(textOrigY+(textH>>1)); } void PreZoomCurText() { InvalidateTextCache(curTextObj->detail.t); } void PostZoomCurText(AbsXc, AbsYc) int AbsXc, AbsYc; { int x=0, y=0, orig_text_w=0, orig_text_h=0; switch (textJust) { case JUST_L: x = OFFSET_X(AbsXc)-(textW>>1); break; case JUST_C: x = OFFSET_X(AbsXc); break; case JUST_R: x = OFFSET_X(AbsXc)+(textW>>1); break; } y = OFFSET_Y(AbsYc)-(textH>>1); AdjustCurText(x-textOrigX, y-textOrigY); textAbsX -= (tmpAdjAbsX+curTextMovedAbsX); textAbsY -= (tmpAdjAbsY+curTextMovedAbsY); textAbsBaselineY -= (tmpAdjAbsY+curTextMovedAbsY); if (editTextSize != 0) { if (RestoreEditTextSize(curTextObj, TRUE)) { UpdTextBBox(curTextObj); } } orig_text_w = curTextObj->obbox.rbx - curTextObj->obbox.ltx; orig_text_h = curTextObj->obbox.rby - curTextObj->obbox.lty; if (editTextSize != 0) { if (RestoreEditTextSize(curTextObj, FALSE)) { UpdTextBBox(curTextObj); } } switch (textJust) { case JUST_L: tmpAdjAbsX = (orig_text_w-ABS_SIZE(textW))/2; break; case JUST_C: tmpAdjAbsX = 0; break; case JUST_R: tmpAdjAbsX = (ABS_SIZE(textW)-orig_text_w)/2; break; } tmpAdjAbsY = (orig_text_h-ABS_SIZE(textH))/2; textAbsX += (tmpAdjAbsX+curTextMovedAbsX); textAbsY += (tmpAdjAbsY+curTextMovedAbsY); textAbsBaselineY += (tmpAdjAbsY+curTextMovedAbsY); SetTextCurXY(); SetTextEndXY(); RedrawCurText(); UpdateTextInfoChoices(FALSE); } void HighLightText(obj_ptr, pStartStrBlock, start_index, pEndStrBlock, end_index) struct ObjRec *obj_ptr; StrBlockInfo *pStartStrBlock, *pEndStrBlock; int start_index, end_index; { int abs_x=0, abs_y=0, x_off=0, y_off=0; int update_highlighted_text_bboxes=FALSE; if (curChoice == DRAWTEXT && textCursorShown) { if (textHighlight) { update_highlighted_text_bboxes = TRUE; } else { EraseTextCursor(); } escPressed = FALSE; CreateTextObj(TRUE, TRUE); curTextModified = FALSE; } outerSel = outerSelForFind; innerSel = innerSelForFind; outerSelForFind = innerSelForFind = NULL; abs_x = obj_ptr->x; x_off = OFFSET_X(abs_x); abs_y = obj_ptr->detail.t->baseline_y; y_off = OFFSET_Y(abs_y); curTextModified = FALSE; if (!PrepareEditExistingText(obj_ptr, abs_x, abs_y, &x_off, &y_off)) { return; } if (update_highlighted_text_bboxes && curStrBlock != NULL) { UpdateHighLightedTextBBoxes(TRUE); } HandleClickOnText(FALSE, TRUE, x_off, y_off, FALSE, curTextObj, FALSE, TRUE, TRUE, (Time)0); if (pStartStrBlock == NULL) { curStrBlock = curTextObj->detail.t->minilines.first->first_block; textCurIndex = 0; ResetOnCursorKey(FALSE); } else { curStrBlock = pStartStrBlock; textCurIndex = start_index; endStrBlock = pEndStrBlock; textEndIndex = end_index; } SetTextHighlight(); SetTextCurXY(); if (endStrBlock != NULL) SetTextEndXY(); textJustClicked = FALSE; UpdatePinnedMenu(MENU_EDIT); RedrawCurText(); ScrollTo(textCurX, textCurBaselineY); UpdateTextInfoChoices(FALSE); } int FindTextInCurTextObj(str_to_match, str_len, case_sensitive, ppFoundStartStrBlock, pn_start_index, ppFoundEndStrBlock, pn_end_index) char *str_to_match; int str_len, case_sensitive, *pn_start_index, *pn_end_index; StrBlockInfo **ppFoundStartStrBlock, **ppFoundEndStrBlock; { int found_starting_point=FALSE; MiniLinesInfo *minilines=(&curTextObj->detail.t->minilines); SaveCursorPositionInCurText(); if (textHighlight) { ReorderCursorStrBlocks(); SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); } *ppFoundStartStrBlock = *ppFoundEndStrBlock = NULL; *pn_start_index = *pn_end_index = INVALID; /* * This is what's going on in FindStringInMiniLines()... * First, find curStrBlock. Set *pn_found_starting_point to TRUE * once curStrBlock is found. * After curStrBlock is found, if *ppStartStrBlock is NULL, this means * that we are still trying to find a prefix match. * If *ppStartStrBlock is non-NULL, that means the prefix is found, so * we must match starting at the beginning of every string. */ if (FindStringInMiniLines(minilines, &found_starting_point, str_to_match, str_len, case_sensitive, ppFoundStartStrBlock, pn_start_index, ppFoundEndStrBlock, pn_end_index)) { RestoreCursorPositionInCurText(); return TRUE; } RestoreCursorPositionInCurText(); return FALSE; } /* --------------------- Insert Special Routines --------------------- */ int SetScriptFractionValue(spec) char *spec; { float fv=(float)0.0; char buf[80]; fv = (float)atof(spec); UtilStrCpyN(buf, sizeof(buf), spec); if (fabs(fv - ((double)1.01)) < INT_TOL) { fv = (float)1.0; strcpy(buf, "1.0"); } else if (fabs(fv - ((double)0.2)) < INT_TOL) { fv = (float)0.2; strcpy(buf, "0.2"); } else if (fv < 0.2 || fv > 1.01) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_VALUE_SPECIFIED), spec); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return FALSE; } if (strcmp(spec, scriptFractionStr) != 0) { scriptFraction = fv; strcpy(scriptFractionStr, buf); } return TRUE; } void SetScriptFraction() { char spec[MAXSTRING+1]; *spec = '\0'; sprintf(gszMsgBox, TgLoadString(STID_ENTER_SCRIPT_FRACTION_CUR_IS), scriptFractionStr); if (Dialog(gszMsgBox, NULL, spec) == INVALID) return; UtilTrimBlanks(spec); if (*spec == '\0') return; if (SetScriptFractionValue(spec)) { sprintf(gszMsgBox, TgLoadString(STID_SCRIPT_FRACTION_SET_TO_STR), scriptFractionStr); Msg(gszMsgBox); } } static int CanInsertThinSpace() { return (textCursorShown && curStrBlock != NULL && curStrBlock->type != SB_SUPSUB_CENTER && !textHighlight); } void InsertThinSpace() { int w=0; char spec[MAXSTRING]; if (!CanInsertThinSpace()) return; *spec = '\0'; if (Dialog(TgLoadString(STID_ENTER_INT_WIDTH_FOR_THIN_SPC), NULL, spec) == INVALID) { return; } UtilTrimBlanks(spec); if (*spec == '\0') return; w = atoi(spec); if (w == 0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_VALUE_SPECIFIED), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } escPressed = FALSE; ResetDirtyBBoxInfo(); curTextModified = TRUE; if (textHighlight) { /* Well, should never get here! */ #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "textHighlight in InsertThinSpace()", NULL); #endif /* _TGIF_DBG */ InsertHighlightedThinSpace(w); } else { DoInsertThinSpace(w); } EndChangeCurText(FALSE); MarkRulers(textCurX, textCurY); SetFileModified(TRUE); ScrollTo(textCurX, textCurBaselineY); } static int CanInsertOrRemoveVerticalOffset() { if (textCursorShown && !textHighlight && curStrBlock != NULL && curStrBlock->type == SB_SIMPLE) { MiniLinesInfo *minilines=(&curTextObj->detail.t->minilines); if (curStrBlock->owner_mini_line->owner_minilines == minilines && curStrBlock->owner_mini_line == minilines->first) { return FALSE; } return TRUE; } return FALSE; } static void DoInsertVerticalOffset(baseline_offset) int baseline_offset; { MiniLinesInfo *pOwnerMinilines=NULL; ResetOnCursorKey(FALSE); switch(curStrBlock->type) { case SB_SIMPLE: pOwnerMinilines = curStrBlock->owner_mini_line->owner_minilines; if (curStrBlock->owner_mini_line == pOwnerMinilines->first) { pOwnerMinilines->baseline_offset += baseline_offset; } else { curStrBlock->owner_mini_line->v_gap += baseline_offset; } break; case SB_CHAR_SPACE: /* not possible */ return; case SB_SUPSUB_LEFT: /* not possible */ return; case SB_SUPSUB_RIGHT: /* not possible */ return; case SB_SUPSUB_CENTER: /* not possible */ return; } EndChangeCurText(FALSE); MarkRulers(textCurX, textCurY); SetFileModified(TRUE); ScrollTo(textCurX, textCurBaselineY); } void InsertVerticalOffset() { int baseline_offset=0; char spec[MAXSTRING]; if (!CanInsertOrRemoveVerticalOffset()) return; *spec = '\0'; if (Dialog(TgLoadString(STID_ENTER_INT_VAL_FOR_VERT_OFFSET), NULL, spec) == INVALID) { return; } UtilTrimBlanks(spec); if (*spec == '\0') return; baseline_offset = atoi(spec); if (baseline_offset == 0) { return; } ResetOnCursorKey(TRUE); SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); ResetDirtyBBoxInfo(); curTextModified = TRUE; DoInsertVerticalOffset(baseline_offset); } static void DoRemoveVerticalOffset() { MiniLinesInfo *pOwnerMinilines=NULL; ResetOnCursorKey(FALSE); switch(curStrBlock->type) { case SB_SIMPLE: pOwnerMinilines = curStrBlock->owner_mini_line->owner_minilines; if (curStrBlock->owner_mini_line == pOwnerMinilines->first) { pOwnerMinilines->baseline_offset = 0; } else { curStrBlock->owner_mini_line->v_gap = 0; } break; case SB_CHAR_SPACE: /* not possible */ return; case SB_SUPSUB_LEFT: /* not possible */ return; case SB_SUPSUB_RIGHT: /* not possible */ return; case SB_SUPSUB_CENTER: /* not possible */ return; } EndChangeCurText(FALSE); MarkRulers(textCurX, textCurY); SetFileModified(TRUE); ScrollTo(textCurX, textCurBaselineY); } void RemoveVerticalOffset() { if (!CanInsertOrRemoveVerticalOffset()) return; ResetOnCursorKey(TRUE); SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); ResetDirtyBBoxInfo(); curTextModified = TRUE; DoRemoveVerticalOffset(); } #define INSERT_SUPERSCRIPT (TRUE) #define INSERT_SUBSCRIPT (FALSE) static int CanInsertLeftRightScripts() { return (textCursorShown && !textHighlight && curStrBlock != NULL && curStrBlock->type != SB_SUPSUB_CENTER); } static MiniLinesInfo *CreateMinilinesForInsertScripts(type) int type; /* assuming curFont, curStyle, curSzUnit, textVSpace are all correct */ { MiniLinesInfo *new_minilines=NewMiniLines(); SetCanvasFont(); CreateMiniLineFromString("", &new_minilines->first, &new_minilines->last); switch (type) { case SB_SUPSUB_LEFT: new_minilines->just = JUST_R; break; case SB_SUPSUB_CENTER: new_minilines->just = JUST_C; break; case SB_SUPSUB_RIGHT: new_minilines->just = JUST_L; break; } new_minilines->v_space = textVSpace; new_minilines->first->first_block->seg->sz_unit = curSzUnit; return new_minilines; } static void DetermineWhatToDoForLeftRightScripts(type, pnJustMove, pnSplitAtIndex, pnInsertBefore) int type, *pnJustMove, *pnSplitAtIndex, *pnInsertBefore; { if (textCurIndex == 0 && curStrBlock->seg->dyn_str.sz == 1) { if (type == SB_SUPSUB_LEFT && curStrBlock->prev != NULL && curStrBlock->prev->type == type) { *pnJustMove = TRUE; return; } else if (type == SB_SUPSUB_RIGHT && curStrBlock->next != NULL && curStrBlock->next->type == type) { *pnJustMove = TRUE; return; } if ((type == SB_SUPSUB_LEFT && curStrBlock->prev == NULL) || (type == SB_SUPSUB_RIGHT && curStrBlock->next == NULL)) { *pnSplitAtIndex = TRUE; return; } } if (textCurIndex == 0) { if (curStrBlock->prev == NULL) { *pnSplitAtIndex = TRUE; } else if (curStrBlock->prev->type == SB_SIMPLE) { *pnInsertBefore = TRUE; } else { if (curStrBlock->prev->type == type && type == SB_SUPSUB_LEFT) { *pnJustMove = TRUE; } else { *pnSplitAtIndex = TRUE; } } } else if (textCurIndex == curStrBlock->seg->dyn_str.sz-1) { if (curStrBlock->next == NULL) { *pnSplitAtIndex = TRUE; } else if (curStrBlock->next->type == SB_SIMPLE) { *pnInsertBefore = FALSE; } else { if (curStrBlock->next->type == type && type == SB_SUPSUB_RIGHT) { *pnJustMove = TRUE; } else { *pnSplitAtIndex = TRUE; } } } else { *pnSplitAtIndex = TRUE; } } static void GetNewSize(pStrSeg, pn_new_size) StrSegInfo *pStrSeg; int *pn_new_size; { int new_sz_unit=0; if (editTextSize != 0) { new_sz_unit = round(((double)pStrSeg->real_sz_unit) * ((double)scriptFraction)); } else { new_sz_unit = round(((double)pStrSeg->sz_unit) * ((double)scriptFraction)); } if (pn_new_size != NULL) { *pn_new_size = SzUnitToFontSize(new_sz_unit); } } static int DoInsertLeftRightScripts(type, superscript) int type, superscript; { int just_move=FALSE, split_at_index=FALSE, insert_before=FALSE; int new_size=0, cur_v_space=textVSpace, font_h=0; MiniLineInfo *owner_mini_line=curStrBlock->owner_mini_line; StrBlockInfo *pSupSubStrBlock=NULL; PushCurFont(); if (editTextSize != 0) { if (RestoreEditTextSize(curTextObj, TRUE)) { UpdTextBBox(curTextObj); } } CopyCurInfoFromStrSeg(curStrBlock->seg); GetNewSize(curStrBlock->seg, &new_size); if (!TrySetCanvasFont(curFont, curStyle, new_size, TRUE, NULL)) { if (editTextSize != 0) { if (RestoreEditTextSize(curTextObj, FALSE)) { UpdTextBBox(curTextObj); } } PopCurFont(); return FALSE; } DetermineWhatToDoForLeftRightScripts(type, &just_move, &split_at_index, &insert_before); if (just_move) { if (type == SB_SUPSUB_LEFT) { pSupSubStrBlock = curStrBlock->prev; } else { pSupSubStrBlock = curStrBlock->next; } } else { pSupSubStrBlock = NewStrBlock(); pSupSubStrBlock->type = type; pSupSubStrBlock->owner_mini_line = owner_mini_line; if (split_at_index) { StrBlockInfo *pLeftStrBlock=NULL; char *psz=UtilStrDup(curStrBlock->seg->dyn_str.s), saved_ch='\0'; if (psz == NULL) FailAllocMessage(); DupStrBlock(curStrBlock, owner_mini_line, &pLeftStrBlock, &pLeftStrBlock); saved_ch = psz[textCurIndex]; psz[textCurIndex] = '\0'; DynStrSet(&pLeftStrBlock->seg->dyn_str, psz); psz[textCurIndex] = saved_ch; DynStrSet(&curStrBlock->seg->dyn_str, &psz[textCurIndex]); UtilFree(psz); pLeftStrBlock->prev = curStrBlock->prev; if (curStrBlock->prev == NULL) { owner_mini_line->first_block = pLeftStrBlock; } else { curStrBlock->prev->next = pLeftStrBlock; } pLeftStrBlock->next = pSupSubStrBlock; pSupSubStrBlock->prev = pLeftStrBlock; pSupSubStrBlock->next = curStrBlock; curStrBlock->prev = pSupSubStrBlock; } else if (insert_before) { pSupSubStrBlock->prev = curStrBlock->prev; curStrBlock->prev->next = pSupSubStrBlock; pSupSubStrBlock->next = curStrBlock; curStrBlock->prev = pSupSubStrBlock; } else { /* insert after */ pSupSubStrBlock->next = curStrBlock->next; curStrBlock->next->prev = pSupSubStrBlock; pSupSubStrBlock->prev = curStrBlock; curStrBlock->next = pSupSubStrBlock; } pSupSubStrBlock->sup = CreateMinilinesForInsertScripts(type); font_h = pSupSubStrBlock->sup->first->first_block->seg->asc + pSupSubStrBlock->sup->first->first_block->seg->des; pSupSubStrBlock->sup->baseline_offset = -curStrBlock->seg->asc + curStrBlock->seg->des + (font_h>>1) - pSupSubStrBlock->sup->first->first_block->seg->des; pSupSubStrBlock->sub = CreateMinilinesForInsertScripts(type); font_h = pSupSubStrBlock->sub->first->first_block->seg->asc + pSupSubStrBlock->sub->first->first_block->seg->des; pSupSubStrBlock->sub->baseline_offset = (font_h>>1) - pSupSubStrBlock->sub->first->first_block->seg->des; } if (superscript) { curStrBlock = pSupSubStrBlock->sup->first->first_block; } else { curStrBlock = pSupSubStrBlock->sub->first->first_block; } textCurIndex = 0; textVSpace = cur_v_space; if (editTextSize != 0) { if (RestoreEditTextSize(curTextObj, FALSE)) { UpdTextBBox(curTextObj); } } PopCurFont(); EndChangeCurText(FALSE); MarkRulers(textCurX, textCurY); SetFileModified(TRUE); ScrollTo(textCurX, textCurBaselineY); return TRUE; } static void InsertLeftRightScripts(type, superscript) int type, superscript; { escPressed = FALSE; ResetDirtyBBoxInfo(); if (!DoInsertLeftRightScripts(type, superscript)) { MsgBox(TgLoadString(STID_FAIL_INSERT_SCRIPT_FONT_SZ), TOOL_NAME, INFO_MB); } else { curTextModified = TRUE; } } void InsertRightSuperscript() { if (!CanInsertLeftRightScripts()) return; InsertLeftRightScripts(SB_SUPSUB_RIGHT, INSERT_SUPERSCRIPT); } void InsertRightSubscript() { if (!CanInsertLeftRightScripts()) return; InsertLeftRightScripts(SB_SUPSUB_RIGHT, INSERT_SUBSCRIPT); } void InsertLeftSuperscript() { if (!CanInsertLeftRightScripts()) return; InsertLeftRightScripts(SB_SUPSUB_LEFT, INSERT_SUPERSCRIPT); } void InsertLeftSubscript() { if (!CanInsertLeftRightScripts()) return; InsertLeftRightScripts(SB_SUPSUB_LEFT, INSERT_SUBSCRIPT); } static int CanInsertCenterScripts() { if (textCursorShown) { if (textHighlight) { if (curStrBlock == endStrBlock && textCurIndex != textEndIndex) { return TRUE; } } else if (curStrBlock->type == SB_SUPSUB_CENTER) { return TRUE; } } return FALSE; } static int DoInsertCenterScripts(superscript) int superscript; { int new_size=0; MiniLineInfo *owner_mini_line=curStrBlock->owner_mini_line; PushCurFont(); CopyCurInfoFromStrSeg(curStrBlock->seg); GetNewSize(curStrBlock->seg, &new_size); if (!TrySetCanvasFont(curFont, curStyle, new_size, TRUE, NULL)) { PopCurFont(); return FALSE; } if (curStrBlock->type == SB_SUPSUB_CENTER) { if (superscript) { curStrBlock = curStrBlock->sup->first->first_block; } else { curStrBlock = curStrBlock->sub->first->first_block; } } else { int min_index=min(textCurIndex, textEndIndex); int max_index=max(textCurIndex, textEndIndex); StrBlockInfo *pLeftStrBlock=NULL, *pRightStrBlock=curStrBlock; StrBlockInfo *pCenterStrBlock=NULL; char *psz=NULL, saved_ch='\0'; pCenterStrBlock = NewStrBlock(); pCenterStrBlock->type = SB_SUPSUB_CENTER; pCenterStrBlock->owner_mini_line = owner_mini_line; DupStrSeg(pCenterStrBlock, curStrBlock->seg); psz = UtilStrDup(curStrBlock->seg->dyn_str.s); if (psz == NULL) FailAllocMessage(); DupStrBlock(pRightStrBlock, owner_mini_line, &pLeftStrBlock, &pLeftStrBlock); saved_ch = psz[min_index]; psz[min_index] = '\0'; DynStrSet(&pLeftStrBlock->seg->dyn_str, psz); psz[min_index] = saved_ch; DynStrSet(&pRightStrBlock->seg->dyn_str, &psz[max_index]); psz[max_index] = '\0'; DynStrSet(&pCenterStrBlock->seg->dyn_str, &psz[min_index]); UtilFree(psz); pLeftStrBlock->prev = pRightStrBlock->prev; if (pRightStrBlock->prev == NULL) { owner_mini_line->first_block = pLeftStrBlock; } else { pRightStrBlock->prev->next = pLeftStrBlock; } pLeftStrBlock->next = pCenterStrBlock; pCenterStrBlock->prev = pLeftStrBlock; pCenterStrBlock->next = pRightStrBlock; pRightStrBlock->prev = pCenterStrBlock; pCenterStrBlock->sup = CreateMinilinesForInsertScripts(SB_SUPSUB_CENTER); /* * pCenterStrBlock->sup->baseline_offset = * (-pCenterStrBlock->sup->first->first_block->seg->des); */ pCenterStrBlock->sup->baseline_offset = 0; pCenterStrBlock->sub = CreateMinilinesForInsertScripts(SB_SUPSUB_CENTER); /* * pCenterStrBlock->sub->baseline_offset = * pCenterStrBlock->sub->first->first_block->seg->asc; */ pCenterStrBlock->sub->baseline_offset = (pCenterStrBlock->sub->first->first_block->seg->asc - pCenterStrBlock->seg->des); if (superscript) { curStrBlock = pCenterStrBlock->sup->first->first_block; } else { curStrBlock = pCenterStrBlock->sub->first->first_block; } /* consolidate */ if (*pLeftStrBlock->seg->dyn_str.s == '\0') { if (pLeftStrBlock->prev != NULL && pLeftStrBlock->prev->type == SB_SIMPLE) { UnlinkStrBlock(pLeftStrBlock); FreeStrBlock(pLeftStrBlock); pLeftStrBlock = NULL; } } if (*pRightStrBlock->seg->dyn_str.s == '\0') { if (pRightStrBlock->next != NULL && pRightStrBlock->next->type == SB_SIMPLE) { UnlinkStrBlock(pRightStrBlock); FreeStrBlock(pRightStrBlock); pRightStrBlock = NULL; } } } textCurIndex = 0; ResetOnCursorKey(FALSE); SetTextHighlight(); PopCurFont(); EndChangeCurText(FALSE); UpdatePinnedMenu(MENU_EDIT); MarkRulers(textCurX, textCurY); SetFileModified(TRUE); ScrollTo(textCurX, textCurBaselineY); return TRUE; } static void InsertCenterScripts(superscript) int superscript; { escPressed = FALSE; ResetDirtyBBoxInfo(); if (!DoInsertCenterScripts(superscript)) { MsgBox(TgLoadString(STID_FAIL_INSERT_SCRIPT_FONT_SZ), TOOL_NAME, INFO_MB); } else { curTextModified = TRUE; } } void InsertCenterSuperscript() { if (!CanInsertCenterScripts()) return; InsertCenterScripts(INSERT_SUPERSCRIPT); } void InsertCenterSubscript() { if (!CanInsertCenterScripts()) return; InsertCenterScripts(INSERT_SUBSCRIPT); } int RefreshEditTextMenu(menu) TgMenu *menu; { int ok=TRUE; ok &= TgEnableMenuItemById(menu, CMDID_INSERTTHINSPACE, CanInsertThinSpace()); ok &= TgEnableMenuItemById(menu, CMDID_INSERTVERTICALOFFSET, CanInsertOrRemoveVerticalOffset()); ok &= TgEnableMenuItemById(menu, CMDID_INSERTRIGHTSUPERSCRIPT, CanInsertLeftRightScripts()); ok &= TgEnableMenuItemById(menu, CMDID_INSERTRIGHTSUBSCRIPT, CanInsertLeftRightScripts()); ok &= TgEnableMenuItemById(menu, CMDID_INSERTLEFTSUPERSCRIPT, CanInsertLeftRightScripts()); ok &= TgEnableMenuItemById(menu, CMDID_INSERTLEFTSUBSCRIPT, CanInsertLeftRightScripts()); ok &= TgEnableMenuItemById(menu, CMDID_INSERTCENTERSUPERSCRIPT, CanInsertCenterScripts()); ok &= TgEnableMenuItemById(menu, CMDID_INSERTCENTERSUBSCRIPT, CanInsertCenterScripts()); ok &= TgEnableMenuItemById(menu, CMDID_RESETINMETHOD, gnInputMethod != TGIM_NONE); return ok; } TgMenu *CreateEditTextMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshEditTextMenu(menu)) { return TgDestroyMenu(menu, TRUE); } } return menu; } static void DetermineWhatToDoForChangeProperty(lWhich, nValue, pStrBlock, nIndex, pnMoveLeft, pnMoveRight, pnSplitAtIndex, pnInsertBefore) long lWhich; int nValue; StrBlockInfo *pStrBlock; int nIndex, *pnMoveLeft, *pnMoveRight, *pnSplitAtIndex, *pnInsertBefore; { if (nIndex == 0) { if (pStrBlock->prev == NULL) { *pnInsertBefore = TRUE; } else if (pStrBlock->prev->type == SB_SIMPLE) { if (SameProperty(lWhich, nValue, pStrBlock->prev->seg, FALSE)) { *pnMoveLeft = TRUE; } else { *pnInsertBefore = TRUE; } } else { *pnInsertBefore = TRUE; } } else if (nIndex == pStrBlock->seg->dyn_str.sz-1) { if (pStrBlock->next == NULL) { *pnInsertBefore = FALSE; } else if (pStrBlock->next->type == SB_SIMPLE) { if (SameProperty(lWhich, nValue, pStrBlock->next->seg, FALSE)) { *pnMoveRight = TRUE; } else { *pnInsertBefore = FALSE; } } else { *pnInsertBefore = FALSE; } } else { *pnSplitAtIndex = TRUE; } } static int ChangeEditTextPropertyAtCursor(lWhich, nValue) long lWhich; int nValue; { StrBlockInfo *pNewStrBlock=NULL; MiniLineInfo *owner_mini_line=curStrBlock->owner_mini_line; int move_left=FALSE, move_right=FALSE; int split_at_index=FALSE, insert_before=FALSE; DetermineWhatToDoForChangeProperty(lWhich, nValue, curStrBlock, textCurIndex, &move_left, &move_right, &split_at_index, &insert_before); if (move_left) { curStrBlock = curStrBlock->prev; textCurIndex = curStrBlock->seg->dyn_str.sz-1; } else if (move_right) { curStrBlock = curStrBlock->next; textCurIndex = 0; } else { DupStrBlock(curStrBlock, owner_mini_line, &pNewStrBlock, &pNewStrBlock); DynStrSet(&pNewStrBlock->seg->dyn_str, ""); if (lWhich == PROP_MASK_TEXT_FONT && curStrBlock->seg->double_byte != IsFontDoubleByte(nValue)) { pNewStrBlock->seg->double_byte = IsFontDoubleByte(nValue); if (pNewStrBlock->seg->double_byte) { pNewStrBlock->seg->double_byte_vertical = IsDoubleByteFontVertical(nValue, pNewStrBlock->seg->style); } else { pNewStrBlock->seg->double_byte_vertical = FALSE; } } if (!SetStrSegProperty(lWhich, nValue, pNewStrBlock->seg)) { /* * don't call UnlinkStrBlock() because DupStrBlock() does not * insert pNewStrBlock into owner_mini_line */ FreeStrBlock(pNewStrBlock); return FALSE; } if (split_at_index) { StrBlockInfo *pLeftStrBlock=NULL; char *psz=UtilStrDup(curStrBlock->seg->dyn_str.s), saved_ch='\0'; if (psz == NULL) FailAllocMessage(); DupStrBlock(curStrBlock, owner_mini_line, &pLeftStrBlock, &pLeftStrBlock); saved_ch = psz[textCurIndex]; psz[textCurIndex] = '\0'; DynStrSet(&pLeftStrBlock->seg->dyn_str, psz); psz[textCurIndex] = saved_ch; DynStrSet(&curStrBlock->seg->dyn_str, &psz[textCurIndex]); UtilFree(psz); pLeftStrBlock->prev = curStrBlock->prev; if (curStrBlock->prev == NULL) { owner_mini_line->first_block = pLeftStrBlock; } else { curStrBlock->prev->next = pLeftStrBlock; } pLeftStrBlock->next = pNewStrBlock; pNewStrBlock->prev = pLeftStrBlock; pNewStrBlock->next = curStrBlock; curStrBlock->prev = pNewStrBlock; } else if (insert_before) { pNewStrBlock->prev = curStrBlock->prev; if (curStrBlock->prev == NULL) { owner_mini_line->first_block = pNewStrBlock; } else { curStrBlock->prev->next = pNewStrBlock; } pNewStrBlock->next = curStrBlock; curStrBlock->prev = pNewStrBlock; } else { /* insert after */ pNewStrBlock->next = curStrBlock->next; if (curStrBlock->next == NULL) { owner_mini_line->last_block = pNewStrBlock; } else { curStrBlock->next->prev = pNewStrBlock; } pNewStrBlock->prev = curStrBlock; curStrBlock->next = pNewStrBlock; } curStrBlock = pNewStrBlock; textCurIndex = 0; } return TRUE; } int ChangeEditTextProperty(lWhich, nValue) long lWhich; int nValue; /* returns TRUE if anything is changed */ { int changed=FALSE; ResetDirtyBBoxInfo(); PushCurFont(); if (editTextSize != 0) { if (RestoreEditTextSize(curTextObj, TRUE)) { UpdTextBBox(curTextObj); } } if (curStrBlock->type == SB_SUPSUB_CENTER) { if (SameProperty(lWhich, nValue, curStrBlock->seg, TRUE)) { /* nothing need to change */ changed = FALSE; } else { int saved_double_byte=INVALID; int saved_double_byte_vertical=INVALID; int saved_double_byte_mod_bytes=INVALID; if (lWhich == PROP_MASK_TEXT_FONT && curStrBlock->seg->double_byte != IsFontDoubleByte(nValue)) { saved_double_byte = curStrBlock->seg->double_byte; saved_double_byte_vertical = curStrBlock->seg->double_byte_vertical; saved_double_byte_mod_bytes = curStrBlock->seg->double_byte_mod_bytes; curStrBlock->seg->double_byte = IsFontDoubleByte(nValue); } changed = SetStrSegProperty(lWhich, nValue, curStrBlock->seg); if (!changed && saved_double_byte != INVALID) { curStrBlock->seg->double_byte = saved_double_byte; curStrBlock->seg->double_byte_vertical = saved_double_byte_vertical; curStrBlock->seg->double_byte_mod_bytes = saved_double_byte_mod_bytes; } } } else { if (textHighlight) { changed = ChangeHighlightedTextProperty(lWhich, nValue); } else { if (SameProperty(lWhich, nValue, curStrBlock->seg, FALSE)) { /* nothing need to change */ changed = FALSE; } else if (textCurIndex == 0 && curStrBlock->seg->dyn_str.sz == 1) { int saved_double_byte=INVALID; int saved_double_byte_vertical=INVALID; int saved_double_byte_mod_bytes=INVALID; if (lWhich == PROP_MASK_TEXT_FONT && curStrBlock->seg->double_byte != IsFontDoubleByte(nValue)) { saved_double_byte = curStrBlock->seg->double_byte; saved_double_byte_vertical = curStrBlock->seg->double_byte_vertical; saved_double_byte_mod_bytes = curStrBlock->seg->double_byte_mod_bytes; curStrBlock->seg->double_byte = IsFontDoubleByte(nValue); } changed = SetStrSegProperty(lWhich, nValue, curStrBlock->seg); if (!changed && saved_double_byte != INVALID) { curStrBlock->seg->double_byte = saved_double_byte; curStrBlock->seg->double_byte_vertical = saved_double_byte_vertical; curStrBlock->seg->double_byte_mod_bytes = saved_double_byte_mod_bytes; } } else { changed = ChangeEditTextPropertyAtCursor(lWhich, nValue); } } } if (editTextSize != 0) { if (RestoreEditTextSize(curTextObj, FALSE)) { UpdTextBBox(curTextObj); } } PopCurFont(); if (changed) { EndChangeCurText(FALSE); if (editTextSize != 0 && curStrBlock != NULL && (curStrBlock->type == SB_SIMPLE || curStrBlock->type == SB_SUPSUB_CENTER)) { CurFontMsg(TRUE, TRUE, curStrBlock->seg); } else { CurFontMsg(TRUE, TRUE, NULL); } SetFileModified(TRUE); } return changed; } static void SplitCurStrBlock() { StrBlockInfo *pLeftStrBlock=NULL; MiniLineInfo *owner_mini_line=curStrBlock->owner_mini_line; char *buf=NULL, saved_ch='\0'; DupStrBlock(curStrBlock, owner_mini_line, &pLeftStrBlock, &pLeftStrBlock); buf = curStrBlock->seg->dyn_str.s; saved_ch = buf[textCurIndex]; buf[textCurIndex] = '\0'; DynStrSet(&pLeftStrBlock->seg->dyn_str, buf); buf[textCurIndex] = saved_ch; DynStrSet(&curStrBlock->seg->dyn_str, &buf[textCurIndex]); pLeftStrBlock->prev = curStrBlock->prev; if (curStrBlock->prev == NULL) { owner_mini_line->first_block = pLeftStrBlock; } else { curStrBlock->prev->next = pLeftStrBlock; } pLeftStrBlock->next = curStrBlock; curStrBlock->prev = pLeftStrBlock; textCurIndex = 0; } void PasteMiniLinesAtCursor(partial_text_obj_ptr) struct ObjRec *partial_text_obj_ptr; { struct TextRec *src_text_ptr=partial_text_obj_ptr->detail.t; MiniLinesInfo *src_minilines=(&src_text_ptr->minilines); MiniLineInfo *src_mini_line=NULL, *next_mini_line=NULL; MiniLineInfo *pFirstMiniLine=NULL, *pLastMiniLine=NULL; StrBlockInfo *src_str_block=NULL, *next_str_block=NULL; StrBlockInfo *pFirstStrBlock=NULL, *pLastStrBlock=NULL; ResetDirtyBBoxInfo(); if (textHighlight) { DeleteHighlightedText(); EndChangeCurText(FALSE); } if (editTextSize != 0) { if (RestoreEditTextSize(curTextObj, TRUE)) { UpdTextBBox(curTextObj); } } SplitCurStrBlock(); pFirstStrBlock = curStrBlock->owner_mini_line->first_block; pLastStrBlock = curStrBlock->owner_mini_line->last_block; for (src_str_block=src_minilines->first->first_block; src_str_block != NULL; src_str_block=next_str_block) { next_str_block = src_str_block->next; src_str_block->owner_mini_line = curStrBlock->owner_mini_line; InsertStrBlock(curStrBlock->prev, curStrBlock, src_str_block, &pFirstStrBlock, &pLastStrBlock); } curStrBlock->owner_mini_line->first_block = pFirstStrBlock; curStrBlock->owner_mini_line->last_block = pLastStrBlock; if (src_minilines->first->next != NULL) { InsertCRLFIntoCurText(); EndChangeCurText(TRUE); pFirstMiniLine = curStrBlock->owner_mini_line->owner_minilines->first; pLastMiniLine = curStrBlock->owner_mini_line->owner_minilines->last; for (src_mini_line=src_minilines->first->next; src_mini_line->next != NULL; src_mini_line=next_mini_line) { next_mini_line = src_mini_line->next; src_mini_line->owner_minilines = curStrBlock->owner_mini_line->owner_minilines; InsertMiniLine(curStrBlock->owner_mini_line->prev, curStrBlock->owner_mini_line, src_mini_line, &pFirstMiniLine, &pLastMiniLine); } curStrBlock->owner_mini_line->owner_minilines->first = pFirstMiniLine; curStrBlock->owner_mini_line->owner_minilines->last = pLastMiniLine; pFirstStrBlock = curStrBlock->owner_mini_line->first_block; pLastStrBlock = curStrBlock->owner_mini_line->last_block; for (src_str_block=src_mini_line->first_block; src_str_block != NULL; src_str_block=next_str_block) { next_str_block = src_str_block->next; src_str_block->owner_mini_line = curStrBlock->owner_mini_line; InsertStrBlock(curStrBlock->prev, curStrBlock, src_str_block, &pFirstStrBlock, &pLastStrBlock); } curStrBlock->owner_mini_line->first_block = pFirstStrBlock; curStrBlock->owner_mini_line->last_block = pLastStrBlock; } if (editTextSize != 0) { if (RestoreEditTextSize(curTextObj, FALSE)) { UpdTextBBox(curTextObj); } } EndChangeCurText(TRUE); MarkRulers(textCurX, textCurY); SetFileModified(TRUE); ScrollTo(textCurX, textCurBaselineY); if (src_minilines->first != NULL) { if (src_minilines->first != src_minilines->last) { free(src_minilines->last); } free(src_minilines->first); src_minilines->first = src_minilines->last = NULL; } } /* --------------------- Insert Special Routines --------------------- */ static void DoMoveEditText(dx, dy) int dx, dy; { struct TextRec *text_ptr=curTextObj->detail.t; int abs_dx=ABS_SIZE(dx), abs_dy=ABS_SIZE(dy), w=0, h=0; curTextMovedAbsX += abs_dx; curTextMovedAbsY += abs_dy; textAbsX += abs_dx; textAbsY += abs_dy; textAbsBaselineY += abs_dy; textOrigX = OFFSET_X(textAbsX); textOrigY = OFFSET_Y(textAbsY); textOrigBaselineY = textOrigY + text_ptr->baseline_y - curTextObj->y; SetTextCurXY(); if (textHighlight) SetTextEndXY(); w = text_ptr->minilines.w; h = (textOrigBaselineY - textOrigY) + (text_ptr->minilines.h - text_ptr->minilines.first->asc); SetEditTextArea(w, h, text_ptr->minilines.min_lbearing, text_ptr->minilines.max_rextra); } static void ContinueMoveEditText(OrigX, OrigY) int OrigX, OrigY; { int done=FALSE, abort=FALSE, dx=0, dy=0; int saved_x=OrigX, saved_y=OrigY; XEvent input, ev; struct BBRec bbox; GetCurTextBBoxes(NULL, &bbox); InflateBBox(&bbox, -2, -2, &bbox); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, moveCursor, CurrentTime); } while (!done) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); SelBox(drawWindow, revDefaultGC, bbox.ltx+dx, bbox.lty+dy, bbox.rbx+dx, bbox.rby+dy); done = TRUE; } else if (input.type == MotionNotify) { int cur_x=input.xmotion.x, cur_y=input.xmotion.y; if (cur_x != saved_x || cur_y != saved_y) { SelBox(drawWindow, revDefaultGC, bbox.ltx+dx, bbox.lty+dy, bbox.rbx+dx, bbox.rby+dy); saved_x = cur_x; saved_y = cur_y; dx = saved_x-OrigX; dy = saved_y-OrigY; SelBox(drawWindow, revDefaultGC, bbox.ltx+dx, bbox.lty+dy, bbox.rbx+dx, bbox.rby+dy); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { XUngrabPointer(mainDisplay, CurrentTime); SelBox(drawWindow, revDefaultGC, bbox.ltx+dx, bbox.lty+dy, bbox.rbx+dx, bbox.rby+dy); abort = TRUE; done = TRUE; } } } SelBox(drawWindow, revDefaultGC, bbox.ltx, bbox.lty, bbox.rbx, bbox.rby); if (debugNoPointerGrab) XSync(mainDisplay, False); if (!abort && (OrigX != saved_x || OrigY != saved_y)) { int abs_dx=ABS_SIZE(dx), abs_dy=ABS_SIZE(dy); struct BBRec new_bbox; bbox.ltx = ABS_X(bbox.ltx); bbox.lty = ABS_Y(bbox.lty); bbox.rbx = ABS_X(bbox.rbx); bbox.rby = ABS_Y(bbox.rby); SetBBRec(&new_bbox, bbox.ltx+abs_dx, bbox.lty+abs_dy, bbox.rbx+abs_dx, bbox.rby+abs_dy); InflateBBox(&bbox, -(curTextOutlineHalfW<<1), -(curTextOutlineHalfW<<1), &bbox); DoMoveEditText(dx, dy); RedrawAreas(botObj, bbox.ltx-GRID_ABS_SIZE(2), bbox.lty-GRID_ABS_SIZE(2), bbox.rbx+GRID_ABS_SIZE(2), bbox.rby+GRID_ABS_SIZE(2), new_bbox.ltx-GRID_ABS_SIZE(2), new_bbox.lty-GRID_ABS_SIZE(2), new_bbox.rbx+GRID_ABS_SIZE(2), new_bbox.rby+GRID_ABS_SIZE(2)); RedrawCurText(); } ShowCurChoiceMouseStatus(curChoice, 0, FALSE); } int MouseInCurText(input) XEvent *input; { if (curChoice == DRAWTEXT && textCursorShown) { int mouse_x=input->xbutton.x, mouse_y=input->xbutton.y; struct BBRec bbox; GetCurTextBBoxes(NULL, &bbox); InflateBBox(&bbox, -(curTextOutlineHalfW<<1), -(curTextOutlineHalfW<<1), &bbox); if (PointInBBox(mouse_x, mouse_y, bbox)) { return TRUE; } } return FALSE; } int MouseOnCurTextBoundary(input) XEvent *input; { if (MouseInCurText(input)) { int mouse_x=input->xbutton.x, mouse_y=input->xbutton.y; struct BBRec bbox; GetCurTextBBoxes(NULL, &bbox); if (!PointInBBox(mouse_x, mouse_y, bbox)) { return TRUE; } } return FALSE; } void MoveEditText(input) XEvent *input; { if (MouseInCurText(input)) { ContinueMoveEditText(input->xbutton.x, input->xbutton.y); } } void MoveEditTextBox() { unsigned int button; int mouse_x=0, mouse_y=0; Msg(TgLoadString(STID_DRAG_MOUSE_MOVE_EDITTEXT_DOTS)); SetMouseStatus(TgLoadCachedString(CSTID_START_MOVE_EDIT_TEXT_BOX), TgLoadCachedString(CSTID_CANCEL), TgLoadCachedString(CSTID_CANCEL)); button = DrawWindowLoop(&mouse_x, &mouse_y, handCursor, FALSE); if (button == Button1) { ContinueMoveEditText(mouse_x, mouse_y); } else { Msg(TgLoadString(STID_MOVE_EDIT_TEXT_BOX_ABORTED)); } } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/prtgif.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000005601�11602233312�014425� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/prtgif.c,v 1.6 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_PRTGIF_C_ #define PRTGIF_NO_TGIF_DBG 1 #include "tgifdefs.h" #include "prtgif.e" int main(argc, argv) int argc; char * argv[]; { register int i; int total_len; char tgif_path[MAXSTRING+1], print_cmd[MAXSTRING+1], * cmd, * c_ptr; char tmp_str[MAXSTRING+1], **s_ptr; FILE * fp; if ((c_ptr=getenv("TGIFPATH")) == NULL) { strcpy(tgif_path, TGIF_PATH); } else { if (strlen(c_ptr) >= MAXSTRING) { /* must be an error */ strcpy(tgif_path, TGIF_PATH); } else { strcpy(tgif_path, c_ptr); } } #ifdef PRINT_CMD strcpy(print_cmd, PRINT_CMD); #else #ifdef VMS strcpy(print_cmd, "print"); #else #ifdef SYSV strcpy(print_cmd, "lp -dpostscript"); #else strcpy(print_cmd, "lpr"); #endif /* SYSV */ #endif /* VMS */ #endif /* PRINT_CMD */ total_len = strlen("tgif ")+strlen("-prtgif "); total_len += strlen(tgif_path); total_len += strlen("-tgif_path")+4; total_len += strlen(print_cmd); total_len += strlen("-print_cmd")+4; for (i=argc-1, s_ptr=(&argv[1]); i > 0; i--, s_ptr++) { total_len += strlen(*s_ptr)+1; } cmd = (char*)malloc((total_len+2)*sizeof(char)); if (cmd == NULL) { fprintf(stderr, "Out of virtual memory and cannot malloc().\n"); } c_ptr = cmd; sprintf(c_ptr, "tgif "); c_ptr += strlen("tgif")+1; sprintf(c_ptr, "-prtgif "); c_ptr += strlen("-prtgif")+1; sprintf(c_ptr, "-tgif_path \"%s\" ", tgif_path); c_ptr += strlen(tgif_path)+strlen("-tgif_path")+4; sprintf(c_ptr, "-print_cmd \"%s\" ", print_cmd); c_ptr += strlen(print_cmd)+strlen("-print_cmd")+4; for (argc--, argv++; argc > 0; argc--, argv++) { sprintf(c_ptr, "%s ", *argv); c_ptr += strlen(*argv)+1; } *(--c_ptr) = '\0'; if ((fp=(FILE*)popen(cmd, "r")) == NULL) { fprintf(stderr, "Cannot popen() to tgif. Abort!\n"); exit (-1); } while (fgets(tmp_str, MAXSTRING, fp) != NULL) { fprintf(stderr, "%s", tmp_str); } pclose(fp); free(cmd); return 0; } �������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/file.c�������������������������������������������������������������������������������0000644�0000764�0000764�00001131555�11602233311�014061� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/file.c,v 1.69 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_FILE_C_ #include "tgifdefs.h" #include "expfdefs.h" #include "cmdids.h" #include "align.e" #include "arc.e" #include "attr.e" #include "auxtext.e" #include "box.e" #include "button.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cutpaste.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "edit.e" #include "eps.e" #include "exec.e" #include "file.e" #include "font.e" #include "grid.e" #include "group.e" #include "imgproc.e" #include "import.e" #include "ini.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "menuinfo.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "obj.e" #include "oval.e" #include "page.e" #include "pattern.e" #include "poly.e" #include "polygon.e" #include "prtgif.e" #include "ps.e" #include "raster.e" #include "rcbox.e" #include "rect.e" #include "remote.e" #include "ruler.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "shape.e" #include "special.e" #include "spline.e" #include "stk.e" #include "stretch.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "version.e" #include "wb.e" #include "xbitmap.e" #include "xpixmap.e" #include "xprtfltr.e" #ifdef _METRIC_PIX_PER_INCH #define METRIC_PIX_PER_INCH 127 #endif /* _METRIC_PIX_PER_INCH */ #define CUR_VERSION 37 int PRTGIF=FALSE; int prTgifFoundColorInfo=FALSE; char curFileName[MAXPATHLENGTH+1]; int curFileDefined=FALSE; int fileVersion=INVALID; int curFileWriteVersion=CUR_VERSION; int importingFile=FALSE; int mergingFile=FALSE; int serializingFile=FALSE; int deserializingFile=FALSE; int psDotsPerInch=72; float printMag=(float)100.0; int saveTmpOnReturn=TRUE; int warpToWinCenter=TRUE; float tiledPageScaling=(float)0.9; char *psXOffStr[MAXPAGESTYLES] = {"0","0"}; float psXOff[MAXPAGESTYLES] = { 0, 0 }; char * * psYOffStr=NULL; float * psYOff=NULL; float * psPageWidthInInch=NULL; float * psPageHeightInInch=NULL; char printCommand[MAXSTRING+1]; char outputDir[MAXPATHLENGTH+1]; char * savedComments=NULL; int savedCommentsLen=0; int saveCommentsInSaveNew=TRUE; int usePsAdobeString=FALSE; char adobeString[80], epsfString[80]; int readingPageNum=0; int loadedCurPageNum=0; int writeFileFailed=FALSE; int foundGoodStateObject=FALSE; int cmdLineHasPageNum=FALSE; int cmdLinePageNum=(-1); char cmdLinePageNumStr[80]; int cmdLineOneFilePerPage=FALSE; int cmdLineA4=FALSE; int cmdLineLetter=FALSE; int cmdLineNoShowPageInEPS=FALSE; int cmdLineColor=FALSE; int cmdLineRequestedColor=FALSE; int cmdLineDumpURL=FALSE; int cmdLineDumpURLWithHeader=FALSE; int cmdLineDumpURLHeaderOnly=FALSE; int cmdLineDumpURLShowStatus=FALSE; int cmdLineDosEpsFilter=FALSE; int cmdLinePreviewOnly=FALSE; int cmdLinePsSetup=FALSE; int tmpFileMode=PSFILE_MOD; char cmdLineTmpFileModeStr[MAXSTRING]; int cmdLineOpenDisplay=FALSE; int cmdLineStdOut=FALSE; int cmdLineWhereToPrint=INVALID; int cmdLineTiffEPSI=INVALID; int cmdLinePdfSetPageDevice=INVALID; char cmdLineFileToExec[MAXSTRING]; char cmdLineProducedBy[MAXSTRING]; char cmdLineOpenFile[MAXSTRING]; char cmdLineJpegToPpm6Cmd[MAXSTRING]; int cmdLineQuiet=FALSE; char cmdLineCustomPatternDir[MAXSTRING]; char customPatDir[MAXSTRING]; int generateTiffEPSI=FALSE; int showPageInEPS=TRUE; int gnQuit=FALSE; int myFileBgPixel=INVALID, myFileFgPixel=INVALID; char *myFileBgColorStr=NULL, *myFileFgColorStr=NULL; XColor myFileBgColor; int myFileBgPixmapW=(-1), myFileBgPixmapH=(-1); Pixmap myFileBgPixmap=None; char *myFileBgGifURL=NULL; char gszProducedBy[MAXSTRING]; int dumpOneFilePerPage=FALSE; int bufferAsFileForWhiteBoard=FALSE; int flushColormapOnOpen=FALSE; struct BBRec *gpExportClipBBox=NULL; int gnNumFilePSFontAliases=0; KeyValInfo *gaFilePSFontAliases=NULL; SpecifyPagesInfo gPagesToPrintSpec; GenerateByInfo gGenerateByInfo; static int pdfSetPageDevice=INVALID; static int psRegMarksInTiledPageMode=INVALID; static float psRegMarksGray=(float)0.95; static int importingPageNum=(-1); static char importingPageName[MAXSTRING+1]; static int unsavableFile=FALSE; static char *gpszPsSetup=NULL; static int psSetupStatus=INVALID; static int psDistillerNoImageCompress=INVALID; struct DocFontRec { char name[80]; int len; struct DocFontRec *next; }; static struct DocFontRec *firstDocFont=NULL; char *MkTempFile(buf, buf_sz, psz_dir, psz_prefix) char *buf, *psz_dir, *psz_prefix; int buf_sz; { int mkstemp_succes=FALSE; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(buf_sz > sizeof(char*), "buf_sz <= sizeof(char*) in MkTempFile()", NULL); #endif /* _TGIF_DBG */ #ifndef _DONT_USE_MKTEMP sprintf(buf, "%s%sXXXXXX", psz_dir, psz_prefix); mktemp(buf); #else /* _DONT_USE_MKTEMP */ { int fd=(-1); sprintf(buf, "%s%sXXXXXX", psz_dir, psz_prefix); if ((fd=mkstemp(buf)) == (-1)) { /* * UtilStrCpyN(buf, buf_sz, (char*)tempnam(psz_dir, psz_prefix)); */ sprintf(buf, "%s%sXXXXXX", psz_dir, psz_prefix); sprintf(gszMsgBox, TgLoadString(STID_CANT_OBTAIN_TMP_FILE_NAME), buf); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return NULL; } else { close(fd); mkstemp_succes = TRUE; } } #endif /* ~_DONT_USE_MKTEMP */ if (!mkstemp_succes) { #ifdef O_EXCL int fd=open(buf, O_CREAT|O_EXCL|O_WRONLY, S_IRUSR|S_IWUSR); if (fd == -1) { /* barf loudly that someone is trying to hack the box */ sprintf(gszMsgBox, TgLoadString(STID_RACE_IN_CREATE_TMP_FILE), buf); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return NULL; } else { close(fd); } #endif /* O_EXCL */ } unlink(buf); return buf; } int IsFiletUnSavable() { return unsavableFile; } void SetUnSavableFile(unsavable) int unsavable; { if (!unsavableFile && unsavable) { Msg(TgLoadString(STID_FILE_IS_MARKED_UNSAVABLE)); } unsavableFile = unsavable; } void UpdateDocumentFonts(ps_font_name) char *ps_font_name; { int len=strlen(ps_font_name); struct DocFontRec *df_ptr; for (df_ptr=firstDocFont; df_ptr != NULL; df_ptr=df_ptr->next) { if (df_ptr->len == len && strcmp(df_ptr->name, ps_font_name) == 0) { return; } } df_ptr = (struct DocFontRec *)malloc(sizeof(struct DocFontRec)); if (df_ptr == NULL) FailAllocMessage(); memset(df_ptr, 0, sizeof(struct DocFontRec)); df_ptr->len = len; UtilStrCpyN(df_ptr->name, sizeof(df_ptr->name), ps_font_name); df_ptr->next = firstDocFont; firstDocFont = df_ptr; } static void DumpDocumentFonts(dump_fp) FILE *dump_fp; { struct DocFontRec *next_df=NULL; if (fprintf(dump_fp, "%%%%DocumentFonts: ") == EOF) { writeFileFailed = TRUE; } for ( ; firstDocFont != NULL; firstDocFont=next_df) { next_df = firstDocFont->next; if (fprintf(dump_fp, "%s", firstDocFont->name) == EOF) { writeFileFailed = TRUE; } if (next_df != NULL) { if (fprintf(dump_fp, "\n%%%%+ ") == EOF) { writeFileFailed = TRUE; } } free(firstDocFont); } if (fprintf(dump_fp, "\n") == EOF) writeFileFailed = TRUE; } #define LANGUAGELEVEL 0 #define EXTENSIONS 1 #define DOCUMENTFONTS 2 #define DOCUMENTNEEDEDRESOURCES 3 #define DOCUMENTNEEDEDFONTS 4 #define MAXPROPAGATEDEPSINFO 5 struct tagPropagatedEPSInfoRec { char *name; int status; } gstPropagatedEPSInfo[] = { { "%%LanguageLevel", LANGUAGELEVEL }, { "%%Extensions", EXTENSIONS }, { "%%DocumentFonts", DOCUMENTFONTS }, { "%%DocumentNeededResources", DOCUMENTNEEDEDRESOURCES }, { "%%DocumentNeededFonts", DOCUMENTNEEDEDFONTS }, { NULL, INVALID } }; static KeyValInfo *gPropagatedEPSInfo[MAXPROPAGATEDEPSINFO]; static int maxLanguageLevel=0; static int FindPropagatedEPSInfo(buf) char *buf; { struct tagPropagatedEPSInfoRec *ppei=gstPropagatedEPSInfo; for (ppei=gstPropagatedEPSInfo; ppei->name != NULL; ppei++) { if (strcmp(buf, ppei->name) == 0) { return ppei->status; } } return INVALID; } static void CleanUpPropagatedEPSInfo() { int i=0; maxLanguageLevel = 0; for (i=0; i < MAXPROPAGATEDEPSINFO; i++) { KeyValInfo *pkvi=NULL, *p_next_kvi=NULL; for (pkvi=gPropagatedEPSInfo[i]; pkvi != NULL; pkvi=p_next_kvi) { p_next_kvi = pkvi->next; UtilFree(pkvi->value); free(pkvi); } } memset(gPropagatedEPSInfo, 0, MAXPROPAGATEDEPSINFO*sizeof(KeyValInfo*)); } static void DumpPropagatedEPSInfo(dump_fp) FILE *dump_fp; { int i=0; if (maxLanguageLevel > 0) { if (fprintf(dump_fp, "%%%%LanguageLevel: %1d\n", maxLanguageLevel) == EOF) { writeFileFailed = TRUE; } } for (i=0; i < MAXPROPAGATEDEPSINFO; i++) { if (gPropagatedEPSInfo[i] != NULL) { KeyValInfo *pkvi=NULL, *p_next_kvi=NULL; if (fprintf(dump_fp, "%s: ", gstPropagatedEPSInfo[i].name) == EOF) { writeFileFailed = TRUE; } for (pkvi=gPropagatedEPSInfo[i]; pkvi != NULL; pkvi=p_next_kvi) { p_next_kvi = pkvi->next; if (fprintf(dump_fp, "%s", pkvi->value) == EOF) { writeFileFailed = TRUE; } if (p_next_kvi != NULL) { if (fprintf(dump_fp, "\n%%%%+ ") == EOF) { writeFileFailed = TRUE; } } UtilFree(pkvi->value); free(pkvi); } if (fprintf(dump_fp, "\n") == EOF) writeFileFailed = TRUE; gPropagatedEPSInfo[i] = NULL; } } } static void DoUpdatePropagatedEPSInfo(index, psz_value) int index; char *psz_value; { int len=strlen(psz_value); KeyValInfo *pkvi=NULL, *p_last_kvi=NULL; for (pkvi=gPropagatedEPSInfo[index]; pkvi != NULL; pkvi=pkvi->next) { if (pkvi->key == ((char*)(long)len) && strcmp(pkvi->value, psz_value) == 0) { return; } p_last_kvi = pkvi; } pkvi = (KeyValInfo *)malloc(sizeof(KeyValInfo)); if (pkvi == NULL) FailAllocMessage(); memset(pkvi, 0, sizeof(KeyValInfo)); pkvi->key = ((char*)(long)len); pkvi->value = UtilStrDup(psz_value); if (pkvi->value == NULL) FailAllocMessage(); if (p_last_kvi == NULL) { gPropagatedEPSInfo[index] = pkvi; } else { p_last_kvi->next = pkvi; } } void UpdatePropagatedEPSInfo(line, pn_status) char *line; int *pn_status; { int propagated_eps_status=INVALID, level=0; char *arg=NULL; if (*pn_status == INVALID) { arg = strchr(line, ':'); if (arg == NULL) return; *arg++ = '\0'; propagated_eps_status = FindPropagatedEPSInfo(line); if (propagated_eps_status == INVALID) return; } else { propagated_eps_status = (*pn_status); arg = (&line[3]); } #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(propagated_eps_status != INVALID, "propagated_eps_status != INVALID in UpdatePropagatedEPSInfo()", NULL); #endif /* _TGIF_DBG */ UtilTrimBlanks(arg); if (arg[0] == '(' && UtilStrICmp(arg, "(atend)") == 0) { *pn_status = INVALID; return; } switch (propagated_eps_status) { case LANGUAGELEVEL: if (sscanf(arg, "%d", &level) == 1) { if (level > maxLanguageLevel) { maxLanguageLevel = level; } } break; case EXTENSIONS: case DOCUMENTNEEDEDFONTS: case DOCUMENTNEEDEDRESOURCES: DoUpdatePropagatedEPSInfo(propagated_eps_status, arg); break; case DOCUMENTFONTS: UpdateDocumentFonts(arg); break; } *pn_status = propagated_eps_status; } static int dontUseShortHandPS=INVALID; static int dontCondense=INVALID; static int stripSimpleComments=INVALID; void SetCmdLineDontCondense() { dontUseShortHandPS = TRUE; dontCondense = TRUE; stripSimpleComments = FALSE; } void SetCmdLineCondensedPS() { dontUseShortHandPS = FALSE; dontCondense = FALSE; stripSimpleComments = TRUE; } static char gszResidual[80]; static int gnResidualLen=0; static void DumpResidual(write_fp) FILE *write_fp; { if (gnResidualLen > 0) { if (fputs(gszResidual, write_fp) == EOF) writeFileFailed = TRUE; if (fputs("\n", write_fp) == EOF) writeFileFailed = TRUE; *gszResidual = '\0'; gnResidualLen = 0; } } static void AddToResidual(write_fp, buf) FILE *write_fp; char *buf; { int len=strlen(buf); if (len <= 0) return; if (len+gnResidualLen >= 77) { DumpResidual(write_fp); if (len >= 77) { if (fputs(buf, write_fp) == EOF) writeFileFailed = TRUE; if (fputs("\n", write_fp) == EOF) writeFileFailed = TRUE; return; } } if (gnResidualLen == 0) { sprintf(&gszResidual[gnResidualLen], "%s", buf); gnResidualLen += len; } else { sprintf(&gszResidual[gnResidualLen], " %s", buf); gnResidualLen += len+1; } } static char *GetPostScriptToken(read_fname, pszStart, ppszEnd) char *read_fname, *pszStart, **ppszEnd; { char *psz=NULL; *ppszEnd = NULL; while (*pszStart == ' ' || *pszStart == '\t') pszStart++; if (*pszStart == '\0') return NULL; if (*pszStart == '%') return NULL; if (*pszStart == '(') { for (psz=pszStart; *psz != ')' && *psz != '\0'; psz++) { if (*psz == '\\') { psz++; if (*psz >= '0' && *psz <= '7') { psz++; psz++; } } } if (*psz == ')') { *ppszEnd = (&psz[1]); } else { /* no problem - Adobe Illustrator 6.0 does this a lot */ } } else { for (psz=pszStart; *psz!='\0' && *psz!=' ' && *psz!='\t' && *psz!='(' && *psz!='%'; psz++) { } if (*psz == '%') { *psz = '\0'; } if (*psz != '\0') { *ppszEnd = psz; } } return pszStart; } static void CondenseAndCopyPostScriptFile(read_fp, write_fp, read_fname, condense) FILE *read_fp, *write_fp; char *read_fname; int condense; { if (condense) { char *buf; int previewing=FALSE, begin_preview_len=strlen("%%BeginPreview:"); if (stripSimpleComments == INVALID) stripSimpleComments = FALSE; *gszResidual = '\0'; gnResidualLen = 0; while ((buf=UtilGetALine(read_fp)) != NULL) { if (*buf == '%') { if (strncmp(buf, "%%BeginPreview:", begin_preview_len) == 0) { previewing = TRUE; } else if (strncmp(buf, "%%EndPreview", begin_preview_len-3) == 0) { previewing = FALSE; } if (!stripSimpleComments || buf[1] == '%' || buf[1] == '!' || previewing) { DumpResidual(write_fp); AddToResidual(write_fp, buf); DumpResidual(write_fp); } } else { char *psz=NULL, *pszStart=buf, *pszEnd=NULL; while ((psz=GetPostScriptToken(read_fname, pszStart, &pszEnd)) != NULL) { char saved_ch='\0'; if (pszEnd != NULL) { saved_ch = (*pszEnd); *pszEnd = '\0'; } AddToResidual(write_fp, psz); if (pszEnd == NULL) { break; } *pszEnd = saved_ch; pszStart = pszEnd; pszEnd = NULL; } } UtilFree(buf); } DumpResidual(write_fp); } else { char tmp_str[MAXSTRING<<1]; while (fgets(tmp_str, MAXSTRING, read_fp) != NULL) { if (fputs(tmp_str, write_fp) == EOF) { writeFileFailed = TRUE; } } } } static int CondensePostScriptFile(read_fname, buf_sz) char *read_fname; int buf_sz; { char write_fname[MAXSTRING+1]; FILE *read_fp=NULL, *write_fp=NULL; if (MkTempFile(write_fname, sizeof(write_fname), tmpDir, TOOL_NAME) == NULL) { return FALSE; } if ((read_fp=fopen(read_fname, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FOR_READ_PRINT), read_fname); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } if ((write_fp=fopen(write_fname, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FOR_WRITE_PRINT), write_fname); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } fclose(read_fp); return FALSE; } CondenseAndCopyPostScriptFile(read_fp, write_fp, read_fname, TRUE); fclose(read_fp); fclose(write_fp); unlink(read_fname); UtilStrCpyN(read_fname, buf_sz, write_fname); return TRUE; } static int CopyAFile(file1, file2, condense) char *file1, *file2; int condense; { char tmp_str[MAXSTRING<<1], *rest; FILE *fp1, *fp2; if ((fp1=fopen(file1, "r")) == NULL) { sprintf(tmp_str, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), file1); if (PRTGIF) { fprintf(stderr, "%s\n", tmp_str); } else { MsgBox(tmp_str, TOOL_NAME, INFO_MB); } return FALSE; } if (file2 == NULL) { /* PRTGIF && cmdLineStdOut */ fp2 = stdout; } else { int short_name=FALSE; if ((short_name=IsPrefix(bootDir, file2, &rest))) ++rest; if ((fp2=fopen(file2, "w")) == NULL) { if (PRTGIF) { sprintf(tmp_str, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), file2); fprintf(stderr, "%s\n", tmp_str); } else { if (short_name) { sprintf(tmp_str, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), rest); } else { sprintf(tmp_str, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), file2); } MsgBox(tmp_str, TOOL_NAME, INFO_MB); } fclose(fp1); return FALSE; } } writeFileFailed = FALSE; CondenseAndCopyPostScriptFile(fp1, fp2, file1, (condense && !dontCondense)); fclose(fp1); if (file2 != NULL) fclose(fp2); if (writeFileFailed) { writeFileFailed = FALSE; if (file2 == NULL) { strcpy(tmp_str, TgLoadString(STID_FAIL_TO_WRITE_TO_STDOUT)); if (PRTGIF) { fprintf(stderr, "%s\n", tmp_str); } else { MsgBox(tmp_str, TOOL_NAME, INFO_MB); } } else { FailToWriteFileMessage(file2); } return FALSE; } return TRUE; } int FindProgramInPath(cmd, msg, no_msg) char *cmd, *msg; int no_msg; { char *psz=strchr(cmd, ' '), szPath[MAXPATHLENGTH]; if (psz != NULL) *psz = '\0'; UtilStrCpyN(szPath, sizeof(szPath), cmd); if (psz != NULL) *psz = ' '; if (*szPath == '\0') { /* no program specified, assume it's okay */ return TRUE; } else if (*szPath == DIR_SEP) { if (UtilPathExists(szPath)) return TRUE; } else { char *env=NULL; psz = getenv("PATH"); if (psz == NULL) { /* cannot get the PATH environment, assume it's okay */ return TRUE; } env = UtilStrDup(psz); if (env == NULL) FailAllocMessage(); for (psz=strtok(env, ":"); psz != NULL; psz=strtok(NULL, ":")) { sprintf(gszMsgBox, "%s%c%s", psz, DIR_SEP, szPath); if (UtilPathExists(gszMsgBox)) { UtilFree(env); return TRUE; } } UtilFree(env); } if (no_msg) { return FALSE; } if (msg == NULL || *msg == '\0') { sprintf(gszMsgBox, TgLoadString(*szPath==DIR_SEP ? STID_CANNOT_FIND_CMD_EXEC : STID_CANNOT_FIND_CMD_IN_PATH_EXEC), szPath, cmd); } else { sprintf(gszMsgBox, TgLoadString(*szPath==DIR_SEP ? STID_CANT_FIND_CMD_MSG_EXEC : STID_CANT_FIND_CMD_INPATH_MSG_EXEC), szPath, msg, cmd); } if (PRTGIF) { fprintf(stderr, "%s [no]\n", gszMsgBox); return FALSE; } return (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB)==MB_ID_YES); } int ExecuteCmd(cmd, done_msg) char *cmd; int done_msg; { int watch_cursor=watchCursorOnMainWindow; char tmp_str[MAXSTRING+1]; FILE *fp=NULL; EndMeasureTooltip(FALSE); if (!FindProgramInPath(cmd, NULL, FALSE)) return FALSE; sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), cmd); SetStringStatus(gszMsgBox); if (!PRTGIF) XSync(mainDisplay, False); if ((fp=(FILE*)popen(cmd, "r")) == NULL) return FALSE; if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } while (fgets(tmp_str, MAXSTRING, fp) != NULL) { if (PRTGIF) { fprintf(stderr, "%s", tmp_str); } else { Msg(tmp_str); } } pclose(fp); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } if (done_msg) { SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); } return TRUE; } void CleanUpComments() { if (savedComments != NULL) { free(savedComments); savedComments = NULL; savedCommentsLen = 0; } } void ClearFileInfo(clean_up_comments) int clean_up_comments; /* * This function is called everything a new file is initialized. */ { *curFileName = '\0'; curFileDefined = FALSE; if (!curDirIsLocal) strcpy(curDir, curLocalDir); curDirIsLocal = TRUE; *curLocalDir = '\0'; *curSymDir = '\0'; if (clean_up_comments) { CleanUpComments(); } *gszHhtmlExportTemplate = '\0'; SetUnSavableFile(FALSE); memset(&gGenerateByInfo, 0, sizeof(GenerateByInfo)); } int OkayToCreateFile(FileName) char *FileName; { FILE *fp; if ((fp=fopen(FileName, "r")) == NULL) return TRUE; fclose(fp); sprintf(gszMsgBox, TgLoadString(STID_FILE_EXISTS_OK_OVERWRITE_YNC), FileName); switch (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB)) { case MB_ID_YES: break; case MB_ID_NO: return FALSE; case MB_ID_CANCEL: return FALSE; } unlink(FileName); return TRUE; } void SaveObj(FP, ObjPtr, Level) FILE *FP; struct ObjRec *ObjPtr; int Level; { switch (ObjPtr->type) { case OBJ_POLY: SavePolyObj(FP, ObjPtr); break; case OBJ_BOX: SaveBoxObj(FP, ObjPtr); break; case OBJ_OVAL: SaveOvalObj(FP, ObjPtr); break; case OBJ_TEXT: SaveTextObj(FP, ObjPtr); break; case OBJ_POLYGON: SavePolygonObj(FP, ObjPtr); break; case OBJ_ARC: SaveArcObj(FP, ObjPtr); break; case OBJ_RCBOX: SaveRCBoxObj(FP, ObjPtr); break; case OBJ_XBM: SaveXBmObj(FP, ObjPtr); break; case OBJ_XPM: SaveXPmObj(FP, ObjPtr); break; case OBJ_GROUP: SaveGroupObj(FP, ObjPtr, Level); break; case OBJ_SYM: SaveCompObj(FP, ObjPtr, Level); break; case OBJ_ICON: SaveIconObj(FP, ObjPtr, Level); break; case OBJ_PIN: SavePinObj(FP, ObjPtr, Level); break; /* reserved */ case OBJ_SS: SaveSimpleStringObj(FP, ObjPtr); break; } } int FileNameHasExtension(file_name, file_type, pn_gzipped, pn_no_name) char *file_name; int file_type, *pn_gzipped, *pn_no_name; { static char stszObjFileExt[20], stszGzObjFileExt[20]; static char stszSymFileExt[20]; static char stszPinFileExt[20]; static int initialized=FALSE; char *psz=NULL; if (!initialized) { sprintf(stszObjFileExt, ".%s", OBJ_FILE_EXT); sprintf(stszGzObjFileExt, ".%s.gz", OBJ_FILE_EXT); sprintf(stszSymFileExt, ".%s", SYM_FILE_EXT); sprintf(stszPinFileExt, ".%s", PIN_FILE_EXT); initialized = TRUE; } if (pn_gzipped != NULL) *pn_gzipped = FALSE; switch (file_type) { case OBJ_FILE_TYPE: if ((psz=strstr(file_name, ".obj")) != NULL && strcmp(psz, ".obj") == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); return TRUE; } else if ((psz=strstr(file_name, ".obj.gz")) != NULL && strcmp(psz, ".obj.gz") == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); if (pn_gzipped != NULL) *pn_gzipped = TRUE; return TRUE; } else if ((psz=strstr(file_name, ".tgo")) != NULL && strcmp(psz, ".tgo") == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); return TRUE; } else if ((psz=strstr(file_name, ".tgo.gz")) != NULL && strcmp(psz, ".tgo.gz") == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); if (pn_gzipped != NULL) *pn_gzipped = TRUE; return TRUE; } else if ((psz=strstr(file_name, stszObjFileExt)) != NULL && strcmp(psz, stszObjFileExt) == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); return TRUE; } else if ((psz=strstr(file_name, stszGzObjFileExt)) != NULL && strcmp(psz, stszGzObjFileExt) == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); if (pn_gzipped != NULL) *pn_gzipped = TRUE; return TRUE; } break; case SYM_FILE_TYPE: if ((psz=strstr(file_name, ".sym")) != NULL && strcmp(psz, ".sym") == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); return TRUE; } else if ((psz=strstr(file_name, ".tgs")) != NULL && strcmp(psz, ".tgs") == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); return TRUE; } else if ((psz=strstr(file_name, stszSymFileExt)) != NULL && strcmp(psz, stszSymFileExt) == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); return TRUE; } break; case PIN_FILE_TYPE: if ((psz=strstr(file_name, ".pin")) != NULL && strcmp(psz, ".pin") == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); return TRUE; } else if ((psz=strstr(file_name, ".tgp")) != NULL && strcmp(psz, ".tgp") == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); return TRUE; } else if ((psz=strstr(file_name, stszPinFileExt)) != NULL && strcmp(psz, stszPinFileExt) == 0) { if (pn_no_name != NULL) *pn_no_name = (psz == file_name); return TRUE; } break; } if (pn_no_name != NULL) *pn_no_name = (*file_name == '\0'); return FALSE; } void RemoveFileNameExtension(file_name) char *file_name; { static char stszObjFileExt[20], stszGzObjFileExt[20]; static char stszSymFileExt[20]; static char stszPinFileExt[20]; static int initialized=FALSE; char *psz=NULL; int len=strlen(file_name); if (!initialized) { sprintf(stszObjFileExt, ".%s", OBJ_FILE_EXT); sprintf(stszGzObjFileExt, ".%s.gz", OBJ_FILE_EXT); sprintf(stszSymFileExt, ".%s", SYM_FILE_EXT); sprintf(stszPinFileExt, ".%s", PIN_FILE_EXT); initialized = TRUE; } if ((psz=strstr(file_name, ".obj")) != NULL && strcmp(psz, ".obj") == 0) { file_name[len-strlen(".obj")] = '\0'; } else if ((psz=strstr(file_name, ".obj.gz")) != NULL && strcmp(psz, ".obj.gz") == 0) { file_name[len-strlen(".obj.gz")] = '\0'; } else if ((psz=strstr(file_name, ".tgo")) != NULL && strcmp(psz, ".tgo") == 0) { file_name[len-strlen(".tgo")] = '\0'; } else if ((psz=strstr(file_name, ".tgo.gz")) != NULL && strcmp(psz, ".tgo.gz") == 0) { file_name[len-strlen(".tgo.gz")] = '\0'; } else if ((psz=strstr(file_name, stszObjFileExt)) != NULL && strcmp(psz, stszObjFileExt) == 0) { file_name[len-strlen(stszObjFileExt)] = '\0'; } else if ((psz=strstr(file_name, stszGzObjFileExt)) != NULL && strcmp(psz, stszGzObjFileExt) == 0) { file_name[len-strlen(stszGzObjFileExt)] = '\0'; } else if ((psz=strstr(file_name, ".sym")) != NULL && strcmp(psz, ".sym") == 0) { file_name[len-strlen(".sym")] = '\0'; } else if ((psz=strstr(file_name, ".tgs")) != NULL && strcmp(psz, ".tgs") == 0) { file_name[len-strlen(".tgs")] = '\0'; } else if ((psz=strstr(file_name, stszSymFileExt)) != NULL && strcmp(psz, stszSymFileExt) == 0) { file_name[len-strlen(stszSymFileExt)] = '\0'; } else if ((psz=strstr(file_name, ".pin")) != NULL && strcmp(psz, ".pin") == 0) { file_name[len-strlen(".pin")] = '\0'; } else if ((psz=strstr(file_name, ".tgp")) != NULL && strcmp(psz, ".tgp") == 0) { file_name[len-strlen(".tgp")] = '\0'; } else if ((psz=strstr(file_name, stszPinFileExt)) != NULL && strcmp(psz, stszPinFileExt) == 0) { file_name[len-strlen(stszPinFileExt)] = '\0'; } } int FixDecimalPoint(buf) char *buf; { char *psz=strchr(buf, ','), *psz2=NULL; if (psz == NULL) { return TRUE; } psz2 = strchr(&psz[1], ','); if (psz2 == NULL) { *psz = '.'; return TRUE; } return FALSE; } void Save(FP, BotObjPtr, Level, PageNumber) FILE *FP; struct ObjRec *BotObjPtr; int Level, PageNumber; { int watch_cursor=watchCursorOnMainWindow; struct ObjRec *obj_ptr=NULL; if (BotObjPtr != NULL && !copyInDrawTextMode) { SetCurChoice(NOTHING); if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } } if (Level == 0 && PageNumber == 1) { char font_str[MAXSTRING], print_mag_str[MAXSTRING]; ResetXPmErrorMessage(); GetPSFontStr(curFont, curStyle, font_str); SetFullVersionString(); /* do not translate -- program constants */ if (fprintf(FP, "%%TGIF %s\n", fullVersionString) == EOF) { writeFileFailed = TRUE; } snprintf(print_mag_str, sizeof(print_mag_str), "%.3f", printMag); if (!FixDecimalPoint(print_mag_str)) { /* do not translate -- program constants */ sprintf(gszMsgBox, TgLoadString(STID_BAD_GIVEN_LINE_WRITTEN), "print_mag"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } writeFileFailed = TRUE; } if (fprintf(FP, "state(%1d,%1d,%s,", pageStyle, CUR_VERSION, print_mag_str) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,", drawOrigX, drawOrigY, zoomScale) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,", xyEnglishGrid, snapOn, colorIndex) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,", horiAlign, vertAlign, lineWidth) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,", curSpline, lineStyle, objFill, penPat) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,'%s',%1d,%1d,", textJust, /* font_str starts with the '/' character */ &font_str[1], curStyle, GetCurSzUnit()) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,", 0, curDash, gridSystem) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,", xyMetricGrid, textVSpace, zoomedIn) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,", gridShown, moveMode, ROTATE0) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,", rcbRadius, useGray) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d).\n", pageLayoutMode, (pageLayoutMode == PAGE_STACK) ? curPageNum : paperCol, (pageLayoutMode == PAGE_STACK) ? lastPageNum : paperRow, pageLineShownInTileMode, colorDump, round(((float)onePageWidth)*printMag/100.0), round(((float)onePageHeight)*printMag/100.0), stretchableText, textRotation, rotationIncrement, transPat) == EOF) { writeFileFailed = TRUE; } if ((BotObjPtr != NULL || tgifObj != NULL) && !copyInDrawTextMode && !serializingFile) { char script_frac_str[MAXSTRING]; if (fprintf(FP, "%%\n") == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%% @%s%s\n", "(#)$H", "eader$") == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%% %s\n", "%W%") == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%%\n") == EOF) { writeFileFailed = TRUE; } if (savedComments != NULL) { if (fputs(savedComments, FP) == EOF) { writeFileFailed = TRUE; } } if (tgifObj->lattr != NULL) { if (fprintf(FP, "file_attr(") == EOF) writeFileFailed = TRUE; SaveAttrs(FP, tgifObj->lattr); if (fprintf(FP, ").\n") == EOF) writeFileFailed = TRUE; } GetUnitSpec(gszMsgBox); if (fprintf(FP, "unit(\"") == EOF) writeFileFailed = TRUE; SaveString(FP, gszMsgBox); if (fprintf(FP, "\").\n") == EOF) writeFileFailed = TRUE; if (shapeShadowInResource || shapeShadowDx != 0 || shapeShadowDy != 0) { if (fprintf(FP, "shapeshadow(%1d,%1d).\n", shapeShadowDx, shapeShadowDy) == EOF) { writeFileFailed = TRUE; } } SaveColors(FP); if (slideShowInfoValid) { if (fprintf(FP, "slideshow_info('%s',%1d,%1d).\n", (slideShowBorderColor==NULL ? "" : slideShowBorderColor), slideShowXOffset, slideShowYOffset) == EOF) { writeFileFailed = TRUE; } } UtilStrCpyN(script_frac_str, sizeof(script_frac_str), scriptFractionStr); if (!FixDecimalPoint(script_frac_str)) { /* do not translate -- program constants */ sprintf(gszMsgBox, TgLoadString(STID_BAD_GIVEN_LINE_WRITTEN), "script_frac"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } writeFileFailed = TRUE; } if (fprintf(FP, "script_frac(\"%s\").\n", script_frac_str) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "fg_bg_colors('%s','%s').\n", colorMenuItems[colorIndex], (*defaultBgColorStr=='\0' ? myBgColorStr : defaultBgColorStr)) == EOF) { /* * The above should use colorMenuItmes[bgColorIndex] * and not myBgColorStr. */ writeFileFailed = TRUE; } if (*gszHhtmlExportTemplate != '\0') { if (fprintf(FP, "html_export_template(\"%s\").\n", gszHhtmlExportTemplate) == EOF) { writeFileFailed = TRUE; } } SaveDontReencode(FP); SavePSFontAliases(FP); SaveDoubleByteModBytes(FP); if (fprintf(FP, "objshadow_info('%s',%1d,%1d).\n", objShadowColorStr, objShadowXOffset, objShadowYOffset) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "rotate_pivot(%1d,%1d,%1d,%1d).\n", autoRotatePivot, rotatePivotAbsXYValid, rotatePivotAbsX, rotatePivotAbsY) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "spline_tightness(%1d).\n", tighterStructSplines) == EOF) { writeFileFailed = TRUE; } if (rightMarginEnabled != INVALID) { if (fprintf(FP, "right_margin(%1d,%1d).\n", rightMarginEnabled, rightMargin) == EOF) { writeFileFailed = TRUE; } } if (threshFillReplaceEnabled) { if (fprintf(FP, "threshold_fill_replace(%1d,%1d,%1d).\n", fillReplaceRedThresh, fillReplaceGreenThresh, fillReplaceBlueThresh) == EOF) { writeFileFailed = TRUE; } } SavePSCharSubs(FP); SavePSFontNeedCharSubs(FP); } } if (Level == 0 && BotObjPtr != NULL && !copyInDrawTextMode) { if (fprintf(FP, "page(%1d,\"", PageNumber) == EOF) writeFileFailed = TRUE; SaveString(FP, ((pageLayoutMode==PAGE_TILE || curPage->name==NULL) ? "" : curPage->name)); if (fprintf(FP, "\",%1d,'%s').\n", curPage->layer_on, ((pageLayoutMode==PAGE_TILE || curPage->page_file_name==NULL) ? "" : curPage->page_file_name)) == EOF) { writeFileFailed = TRUE; } } for (obj_ptr=BotObjPtr; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { SaveObj(FP, obj_ptr, Level); if (obj_ptr->prev == NULL) { if (Level == 0) { if (fprintf(FP, ".\n") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, "\n") == EOF) writeFileFailed = TRUE; } } else { if (Level == 0) { if (fprintf(FP, ".\n") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, ",\n") == EOF) writeFileFailed = TRUE; } } } if (BotObjPtr != NULL && !copyInDrawTextMode) { if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } } } int SaveTmpFile(NewFileName) char *NewFileName; /* return TRUE if file successfully saved */ { char new_file_name[MAXPATHLENGTH+1], *rest=NULL; FILE *fp=NULL; int count=0, file_type=INVALID, short_name, watch_cursor=FALSE; struct PageRec *saved_cur_page; struct ObjRec *obj_ptr; struct ObjRec *obj_ptr1=NULL, *obj_ptr2=NULL; struct AttrRec *attr_ptr; UtilStrCpyN(new_file_name, sizeof(new_file_name), NewFileName); saved_cur_page = curPage; for (curPage=firstPage; curPage != NULL; curPage=curPage->next) { for (obj_ptr=curPage->top; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (obj_ptr->type == OBJ_SYM) { if (obj_ptr1 == NULL) { obj_ptr1 = obj_ptr; } else if (obj_ptr2 == NULL) { obj_ptr2 = obj_ptr; } count++; } } } curPage = saved_cur_page; switch (count) { case 0: sprintf(new_file_name, "%s.%s", NewFileName, OBJ_FILE_EXT); file_type = OBJ_FILE_TYPE; break; case 1: if (lastPageNum != 1) { MsgBox(TgLoadString(STID_ONE_PAGE_SYM_ABORT_SAVE), TOOL_NAME, INFO_MB); return INVALID; } if ((attr_ptr=FindAttrWithName(obj_ptr1, "type=", NULL)) != NULL && strcmp(attr_ptr->attr_value.s, "tgif_pin") == 0) { sprintf(new_file_name, "%s.%s", NewFileName, PIN_FILE_EXT); file_type = PIN_FILE_TYPE; } else { sprintf(new_file_name, "%s.%s", NewFileName, SYM_FILE_EXT); file_type = SYM_FILE_TYPE; } break; case 2: if (lastPageNum != 1) { MsgBox(TgLoadString(STID_ONE_PAGE_PIN_ABORT_SAVE), TOOL_NAME, INFO_MB); return INVALID; } sprintf(new_file_name, "%s.%s", NewFileName, PIN_FILE_EXT); file_type = PIN_FILE_TYPE; break; default: MsgBox(TgLoadString(STID_TOO_MANY_SYM_ABORT_SAVE), TOOL_NAME, INFO_MB); return INVALID; } unlink(new_file_name); if ((short_name=IsPrefix(bootDir, new_file_name, &rest))) ++rest; if ((fp=fopen(new_file_name, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_WRITE_FILE_NOT_SAVE), (short_name ? rest : new_file_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return INVALID; } sprintf(gszMsgBox, TgLoadString(STID_SAVE_TMP_FILE_DOTS), (short_name ? rest : new_file_name)); Msg(gszMsgBox); watch_cursor = watchCursorOnMainWindow; if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; MakeQuiescent(); saved_cur_page = curPage; for (curPage=firstPage, count=1; curPage != NULL; curPage=curPage->next, count++) { topObj = curPage->top; botObj = curPage->bot; Save(fp, botObj, 0, count); } curPage = saved_cur_page; topObj = curPage->top; botObj = curPage->bot; fclose(fp); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(new_file_name); } else { sprintf(gszMsgBox, TgLoadString(STID_TMP_FILE_SAVED), (short_name ? rest : new_file_name)); Msg(gszMsgBox); } if (tmpFileMode != 0 && chmod(new_file_name, tmpFileMode)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CHMOD), (short_name ? rest : new_file_name), tmpFileMode); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } SetCurChoice(curChoiceBeforeMakeQuiescent); return file_type; } void SaveNewFile(SaveSelectedOnly, pszNewFile) int SaveSelectedOnly; char *pszNewFile; { char new_file_name[MAXPATHLENGTH+1], gzipped_fname[MAXPATHLENGTH+1]; char new_full_name[MAXPATHLENGTH+1], tmp_str[MAXPATHLENGTH+1], *rest=NULL; char saved_cur_dir[MAXPATHLENGTH+1], saved_cur_file_name[MAXPATHLENGTH+1]; char obj_ext_str[MAXSTRING+1], gz_obj_ext_str[MAXSTRING+1]; char sym_ext_str[MAXSTRING+1], pin_ext_str[MAXSTRING+1]; int saved_cur_file_defined=FALSE, no_name=FALSE, gzipped=FALSE, file_type=0; int count=0, len, short_name=FALSE, ok=TRUE, watch_cursor=FALSE; struct ObjRec *obj_ptr=NULL, *saved_top_obj=NULL, *saved_bot_obj=NULL; struct ObjRec *obj_ptr1=NULL, *obj_ptr2=NULL; struct SelRec *top_sel_ptr=NULL, *bot_sel_ptr=NULL; struct SelRec *sel_ptr=NULL, *next_sel=NULL; struct PageRec *saved_cur_page=NULL; struct AttrRec *attr_ptr=NULL; FILE *fp=NULL; file_type = OBJ_FILE_TYPE; *gzipped_fname = '\0'; if (SaveSelectedOnly && pszNewFile == NULL && topSel == NULL) { MsgBox("No objects selected!\n\nNothing saved!", TOOL_NAME, INFO_MB); return; } if (SaveSelectedOnly && pszNewFile != NULL) { UtilStrCpyN(new_file_name, sizeof(new_file_name), pszNewFile); } else if (pszNewFile != NULL && strcmp(pszNewFile, "-1") != 0) { UtilStrCpyN(new_file_name, sizeof(new_file_name), pszNewFile); len = strlen(new_file_name); if (len > 0 && new_file_name[len-1] == ')') { new_file_name[len-1] = '\0'; } } else { sprintf(gszMsgBox, TgLoadString(STID_WORKING_DIRECTORY_IS), (curDirIsLocal ? curDir : curLocalDir)); *new_file_name = '\0'; Dialog(TgLoadString(STID_ENTER_NEW_FNAME_ACCEPT_CANCEL), gszMsgBox, new_file_name); } UtilTrimBlanks(new_file_name); if (*new_file_name == '\0') return; len = strlen(new_file_name); if (SaveSelectedOnly) { for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (sel_ptr->obj->type == OBJ_SYM) { if (obj_ptr1 == NULL) { obj_ptr1 = sel_ptr->obj; } else if (obj_ptr2 == NULL) { obj_ptr2 = sel_ptr->obj; } count++; } } } else { saved_cur_page = curPage; for (curPage=firstPage; curPage != NULL; curPage=curPage->next) { for (obj_ptr=curPage->top; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (obj_ptr->type == OBJ_SYM) { if (obj_ptr1 == NULL) { obj_ptr1 = obj_ptr; } else if (obj_ptr2 == NULL) { obj_ptr2 = obj_ptr; } count++; } } } curPage = saved_cur_page; } sprintf(obj_ext_str, ".%s", OBJ_FILE_EXT); sprintf(gz_obj_ext_str, ".%s.gz", OBJ_FILE_EXT); sprintf(sym_ext_str, ".%s", SYM_FILE_EXT); sprintf(pin_ext_str, ".%s", PIN_FILE_EXT); if (count > 2) { MsgBox(TgLoadString(STID_TOO_MANY_SYM_ABORT_SAVE), TOOL_NAME, INFO_MB); return; } if (count >= 1 && lastPageNum != 1) { MsgBox(TgLoadString(count==1 ? STID_ONE_PAGE_SYM_ABORT_SAVE : STID_ONE_PAGE_PIN_ABORT_SAVE), TOOL_NAME, INFO_MB); return; } switch (count) { case 0: if (FileNameHasExtension(new_file_name, OBJ_FILE_TYPE, &gzipped, &no_name)) { /* don't modify */ } else if (FileNameHasExtension(new_file_name, SYM_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_SYM_NO_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, PIN_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_PIN_NO_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else { strcat(new_file_name, obj_ext_str); } file_type = OBJ_FILE_TYPE; break; case 1: if ((attr_ptr=FindAttrWithName(obj_ptr1, "type=", NULL)) != NULL && strcmp(attr_ptr->attr_value.s, "tgif_pin") == 0) { if (FileNameHasExtension(new_file_name, OBJ_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_OJB_ONE_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, SYM_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_SYM_SAVE_AS_PIN), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, PIN_FILE_TYPE, NULL, &no_name)) { /* don't modify */ } else { strcat(new_file_name, pin_ext_str); } file_type = PIN_FILE_TYPE; } else { if (FileNameHasExtension(new_file_name, OBJ_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_OJB_ONE_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, SYM_FILE_TYPE, NULL, &no_name)) { /* don't modify */ } else if (FileNameHasExtension(new_file_name, PIN_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_PIN_ONE_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else { strcat(new_file_name, sym_ext_str); } file_type = SYM_FILE_TYPE; } break; case 2: if (FileNameHasExtension(new_file_name, OBJ_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_OJB_TWO_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, SYM_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_SYM_TWO_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, PIN_FILE_TYPE, NULL, &no_name)) { /* don't modify */ } else { strcat(new_file_name, pin_ext_str); } if (obj_ptr2->fattr != NULL) { obj_ptr = obj_ptr2; obj_ptr2 = obj_ptr1; obj_ptr1 = obj_ptr; } if ((attr_ptr=FindAttrWithName(obj_ptr1, "type=", NULL)) == NULL) { MsgBox(TgLoadString(STID_CANT_FIND_TYPE_ATTR_NOT_SAVED), TOOL_NAME, INFO_MB); return; } if (strcmp(attr_ptr->attr_value.s, "tgif_pin") != 0) { sprintf(gszMsgBox, TgLoadString(STID_SYM_TYPE_WRONG_PIN_NOT_SAVED), "tgif_pin"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } file_type = PIN_FILE_TYPE; break; default: return; } if (no_name) { MsgBox(TgLoadString(STID_NO_FILE_NAME_FILE_NOT_SAVED), TOOL_NAME, INFO_MB); return; } if (*new_file_name == DIR_SEP) { UtilStrCpyN(new_full_name, sizeof(new_full_name), new_file_name); } else if (curDirIsLocal) { sprintf(new_full_name, "%s%c%s", curDir, DIR_SEP, new_file_name); } else { sprintf(new_full_name, "%s%c%s", curLocalDir, DIR_SEP, new_file_name); } if (file_type == OBJ_FILE_TYPE && gzipped) { char tmp_fname[MAXPATHLENGTH]; if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { return; } strcpy(gzipped_fname, new_full_name); strcpy(new_full_name, tmp_fname); } if (!OkayToCreateFile((*gzipped_fname=='\0') ? new_full_name : gzipped_fname)) { if (*gzipped_fname != '\0') unlink(new_full_name); return; } if (*gzipped_fname == '\0') { if ((short_name=IsPrefix(bootDir, new_full_name, &rest))) ++rest; } else { if ((short_name=IsPrefix(bootDir, gzipped_fname, &rest))) ++rest; } if ((fp=fopen(new_full_name, "w")) == NULL) { if (short_name) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_WRITE_FILE_NOT_SAVE), rest); } else { if (*gzipped_fname == '\0') { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_WRITE_FILE_NOT_SAVE), new_full_name); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_WRITE_FILE_NOT_SAVE), gzipped_fname); } } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (*gzipped_fname != '\0') unlink(new_full_name); return; } if (!SaveSelectedOnly) BeforeNavigate(); if (SaveSelectedOnly) { PushPageInfo(); if (pageLayoutMode == PAGE_STACK) { paperCol = paperRow = curPageNum = lastPageNum = 1; } if (curDirIsLocal) { strcpy(saved_cur_dir, curDir); } else { strcpy(saved_cur_dir, curLocalDir); } strcpy(saved_cur_file_name, curFileName); saved_cur_file_defined = curFileDefined; saved_top_obj = topObj; saved_bot_obj = botObj; if (topSel == NULL) { topObj = botObj = NULL; } else { JustDupSelObj(&top_sel_ptr, &bot_sel_ptr); topObj = top_sel_ptr->obj; botObj = bot_sel_ptr->obj; } firstPage = lastPage = curPage = (struct PageRec *)malloc(sizeof(struct PageRec)); if (firstPage == NULL) FailAllocMessage(); memset(firstPage, 0, sizeof(struct PageRec)); firstPage->layer_on = TRUE; firstPage->top = topObj; firstPage->bot = botObj; firstPage->next = firstPage->prev = NULL; if (pageLayoutMode == PAGE_STACK) { firstPage->draw_orig_x = drawOrigX; firstPage->draw_orig_y = drawOrigY; firstPage->zoom_scale = zoomScale; firstPage->zoomed_in = zoomedIn; curPageNum = lastPageNum = 1; } for (sel_ptr=topSel, obj_ptr=topObj; obj_ptr!=NULL; sel_ptr=sel_ptr->next, obj_ptr=obj_ptr->next) { CopyObjId(sel_ptr->obj, obj_ptr); CopyObjLocks(sel_ptr->obj, obj_ptr); } } if (curDirIsLocal) { strcpy(tmp_str, curDir); } else { strcpy(tmp_str, curLocalDir); } if (*gzipped_fname == '\0') { SetCurDir(new_full_name); } else { SetCurDir(gzipped_fname); } curFileDefined = TRUE; if (cmdLineMerge) { cmdLineMerge = FALSE; } switch (count) { case 0: *curSymDir = '\0'; if ((strcmp(tmp_str, (curDirIsLocal ? curDir : curLocalDir)) != 0) || (!NameInCurDir(curFileName))) { UpdateDirInfo(); } break; default: strcpy(curSymDir, (curDirIsLocal ? curDir : curLocalDir)); if (!DirInSymPath(curDirIsLocal ? curDir : curLocalDir)) { UpdateSymInfo(); } break; } if (short_name) { sprintf(gszMsgBox, TgLoadString(STID_SAVING_DOTS), rest); } else { if (*gzipped_fname == '\0') { sprintf(gszMsgBox, TgLoadString(STID_SAVING_DOTS), new_full_name); } else { sprintf(gszMsgBox, TgLoadString(STID_SAVING_DOTS), gzipped_fname); } } Msg(gszMsgBox); if (!saveCommentsInSaveNew) CleanUpComments(); watch_cursor = watchCursorOnMainWindow; if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; saved_cur_page = curPage; for (curPage=firstPage, count=1; curPage != NULL; curPage=curPage->next, count++) { topObj = curPage->top; botObj = curPage->bot; Save(fp, botObj, 0, count); } curPage = saved_cur_page; topObj = curPage->top; botObj = curPage->bot; fclose(fp); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(new_full_name); ok = FALSE; } else { if (*gzipped_fname != '\0') { if (!GzipFile(new_full_name, gzipped_fname)) { sprintf(gszMsgBox, TgLoadString(STID_PROBLEM_ZIPPING_PLEASE_SAVE), new_full_name, gzipped_fname, new_full_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } unlink(new_full_name); strcpy(new_full_name, gzipped_fname); } if (ok) { sprintf(gszMsgBox, TgLoadString(STID_FILE_SAVED), (short_name ? rest : new_full_name)); Msg(gszMsgBox); } else { sprintf(gszMsgBox, TgLoadString(STID_FILE_NOT_SAVED), (short_name ? rest : new_full_name)); Msg(gszMsgBox); } } if (SaveSelectedOnly) { CleanUpPage(); for (sel_ptr=top_sel_ptr; sel_ptr != NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } topObj = saved_top_obj; botObj = saved_bot_obj; if (curDirIsLocal) { strcpy(curDir, saved_cur_dir); } else { strcpy(curLocalDir, saved_cur_dir); } strcpy(curFileName, saved_cur_file_name); curFileDefined = saved_cur_file_defined; PopPageInfo(); } else if (ok) { SetFileModified(FALSE); RedrawTitleWindow(); SetUnSavableFile(FALSE); } if (!SaveSelectedOnly && !PRTGIF) CommitNavigate(); } void SaveSymInLibrary() { char new_file_name[MAXPATHLENGTH+1]; char new_full_name[MAXPATHLENGTH+1], dir_name[MAXPATHLENGTH+1]; char saved_dir[MAXPATHLENGTH+1], saved_file[MAXPATHLENGTH+1]; char saved_sym_dir[MAXPATHLENGTH+1], *rest=NULL; char sym_ext_str[MAXSTRING+1], pin_ext_str[MAXSTRING+1], *c_ptr; FILE *fp; int count=0, short_name, watch_cursor=FALSE; int saved_cur_file_defined, file_type=INVALID; struct ObjRec *obj_ptr; struct PageRec *saved_cur_page; struct ObjRec *obj_ptr1=NULL, *obj_ptr2=NULL; struct AttrRec *attr_ptr; saved_cur_page = curPage; for (curPage=firstPage; curPage != NULL; curPage=curPage->next) { for (obj_ptr=curPage->top; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (obj_ptr->type == OBJ_SYM) { if (obj_ptr1 == NULL) { obj_ptr1 = obj_ptr; } else if (obj_ptr2 == NULL) { obj_ptr2 = obj_ptr; } count++; } } } curPage = saved_cur_page; switch (count) { case 0: MsgBox(TgLoadString(STID_NO_SYM_FOUND_SYM_NOT_SAVED), TOOL_NAME, INFO_MB); return; case 1: if (lastPageNum != 1) { MsgBox(TgLoadString(STID_ONE_PAGE_SYM_ABORT_SAVE), TOOL_NAME, INFO_MB); return; } if ((attr_ptr=FindAttrWithName(obj_ptr1, "type=", NULL)) != NULL && strcmp(attr_ptr->attr_value.s, "tgif_pin") == 0) { file_type = PIN_FILE_TYPE; } else { file_type = SYM_FILE_TYPE; } break; case 2: if (lastPageNum != 1) { MsgBox(TgLoadString(STID_ONE_PAGE_PIN_ABORT_SAVE), TOOL_NAME, INFO_MB); return; } if (obj_ptr2->fattr != NULL) { obj_ptr = obj_ptr2; obj_ptr2 = obj_ptr1; obj_ptr1 = obj_ptr; } if ((attr_ptr=FindAttrWithName(obj_ptr1, "type=", NULL)) == NULL) { MsgBox(TgLoadString(STID_CANT_FIND_TYPE_ATTR_NOT_SAVED), TOOL_NAME, INFO_MB); return; } if (strcmp(attr_ptr->attr_value.s, "tgif_pin") != 0) { sprintf(gszMsgBox, TgLoadString(STID_SYM_TYPE_WRONG_PIN_NOT_SAVED), "tgif_pin"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } file_type = PIN_FILE_TYPE; break; default: MsgBox(TgLoadString(STID_TOO_MANY_SYM_ABORT_SAVE), TOOL_NAME, INFO_MB); return; } MakeQuiescent(); sprintf(sym_ext_str, ".%s", SYM_FILE_EXT); sprintf(pin_ext_str, ".%s", PIN_FILE_EXT); if (*curFileName == '\0') { int no_name=FALSE; *new_file_name = '\0'; Dialog(TgLoadString(STID_ENTER_NEW_FILE_NAME), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), new_file_name); UtilTrimBlanks(new_file_name); if (*new_file_name == '\0') return; if (FileNameHasExtension(new_file_name, SYM_FILE_TYPE, NULL, &no_name)) { /* do nothing */ } else if (FileNameHasExtension(new_file_name, PIN_FILE_TYPE, NULL, &no_name)) { /* do nothing */ } else if (count == 1) { if (file_type == SYM_FILE_TYPE) { strcat(new_file_name, sym_ext_str); } else { strcat(new_file_name, pin_ext_str); } } else { strcat(new_file_name, pin_ext_str); } if (no_name) { MsgBox(TgLoadString(STID_NO_FILE_NAME_FILE_NOT_SAVED), TOOL_NAME, INFO_MB); return; } } else { c_ptr = UtilStrRChr(curFileName, DIR_SEP); strcpy(new_file_name, (c_ptr==NULL) ? curFileName : ++c_ptr); } if (SelectSymDir(dir_name) == INVALID) { Msg(""); return; } if (strcmp(dir_name, ".") == 0) { sprintf(new_full_name, "%s%c%s", (curDirIsLocal ? curDir : curLocalDir), DIR_SEP, new_file_name); } else { sprintf(new_full_name, "%s%c%s", dir_name, DIR_SEP, new_file_name); } if (!OkayToCreateFile(new_full_name)) return; if ((short_name=IsPrefix(bootDir, new_full_name, &rest))) ++rest; if ((fp=fopen(new_full_name, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_WRITE_FILE_NOT_SAVE), (short_name ? rest : new_full_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } strcpy(saved_dir, (curDirIsLocal ? curDir : curLocalDir)); strcpy(saved_file, curFileName); strcpy(saved_sym_dir, curSymDir); saved_cur_file_defined = curFileDefined; SetCurDir(new_full_name); curFileDefined = TRUE; strcpy(curSymDir, (curDirIsLocal ? curDir : curLocalDir)); if (!DirInSymPath(curDirIsLocal ? curDir : curLocalDir)) UpdateSymInfo(); sprintf(gszMsgBox, TgLoadString(STID_SAVING_DOTS), (short_name ? rest : new_full_name)); Msg(gszMsgBox); if (!saveCommentsInSaveNew) CleanUpComments(); watch_cursor = watchCursorOnMainWindow; if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; saved_cur_page = curPage; for (curPage=firstPage, count=1; curPage != NULL; curPage=curPage->next, count++) { topObj = curPage->top; botObj = curPage->bot; Save(fp, botObj, 0, count); } curPage = saved_cur_page; topObj = curPage->top; botObj = curPage->bot; fclose(fp); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(new_full_name); } else { sprintf(gszMsgBox, TgLoadString(STID_FILE_SAVED), (short_name ? rest : new_full_name)); Msg(gszMsgBox); } if (curDirIsLocal) { strcpy(curDir, saved_dir); } else { strcpy(curLocalDir, saved_dir); } strcpy(curFileName, saved_file); strcpy(curSymDir, saved_sym_dir); curFileDefined = saved_cur_file_defined; RedrawTitleWindow(); SetCurChoice(curChoiceBeforeMakeQuiescent); } void SaveFile() { int count=0, short_name, file_type=INVALID, no_name=FALSE; struct ObjRec *obj_ptr=NULL; FILE *fp=NULL; char ext[MAXPATHLENGTH+1], gzipped_fname[MAXPATHLENGTH+1]; char full_name[MAXPATHLENGTH+1], *rest=NULL, *psz=NULL; struct PageRec *saved_cur_page=NULL; struct ObjRec *obj_ptr1=NULL, *obj_ptr2=NULL; struct AttrRec *attr_ptr=NULL; int watch_cursor=FALSE, gzipped=FALSE; *gzipped_fname = '\0'; if (!curFileDefined || !curDirIsLocal) { SaveNewFile(FALSE, NULL); return; } if (unsavableFile) { if (MsgBox(TgLoadString(STID_Q_FILE_UNSAVABLE_SAVE_NEW_YNC), TOOL_NAME, YNC_MB) == MB_ID_YES) { SaveNewFile(FALSE, NULL); } return; } if ((psz=UtilStrRChr(curFileName, '.')) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_DOT_IN_SAVEFILE), "SaveFile()"); TgAssert(FALSE, gszMsgBox, NULL); return; } if (strcmp(psz, ".gz") == 0) { char *dot_ptr=psz; gzipped = TRUE; *dot_ptr = '\0'; if ((psz=UtilStrRChr(curFileName, '.')) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_DOT_IN_SAVEFILE), "SaveFile()"); TgAssert(FALSE, gszMsgBox, NULL); *dot_ptr = '.'; return; } UtilStrCpyN(ext, sizeof(ext), psz); *dot_ptr = '.'; } else { UtilStrCpyN(ext, sizeof(ext), psz); } saved_cur_page = curPage; for (curPage=firstPage; curPage != NULL; curPage=curPage->next) { for (obj_ptr=curPage->top; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (obj_ptr->type == OBJ_SYM) { if (obj_ptr1 == NULL) { obj_ptr1 = obj_ptr; } else if (obj_ptr2 == NULL) { obj_ptr2 = obj_ptr; } count++; } } } curPage = saved_cur_page; switch (count) { case 0: if (FileNameHasExtension(ext, SYM_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_NO_SYM_FOUND_SYM_NOT_SAVED), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(ext, PIN_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_NO_SYM_FOUND_PIN_NOT_SAVED), TOOL_NAME, INFO_MB); return; } file_type = OBJ_FILE_TYPE; break; case 1: if (FileNameHasExtension(ext, OBJ_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_OJB_ONE_SYM_FOUND), TOOL_NAME, INFO_MB); return; } if ((attr_ptr=FindAttrWithName(obj_ptr1, "type=", NULL)) != NULL && strcmp(attr_ptr->attr_value.s, "tgif_pin") == 0) { if (FileNameHasExtension(ext, SYM_FILE_TYPE, NULL, &no_name)) { sprintf(gszMsgBox, TgLoadString(STID_SYM_TYPE_IS_SHOULD_SAVE_PIN), "tgif_pin"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } file_type = PIN_FILE_TYPE; } else { if (FileNameHasExtension(ext, PIN_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_PIN_ONE_SYM_FOUND), TOOL_NAME, INFO_MB); return; } file_type = SYM_FILE_TYPE; } break; case 2: if (FileNameHasExtension(ext, OBJ_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_OJB_ONE_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(ext, SYM_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_TOO_MANY_SYM_ABORT_SAVE), TOOL_NAME, INFO_MB); return; } file_type = PIN_FILE_TYPE; break; default: MsgBox(TgLoadString(STID_TOO_MANY_SYM_FILE_NOT_SAVED), TOOL_NAME, INFO_MB); return; } if (file_type == SYM_FILE_TYPE || file_type == PIN_FILE_TYPE) { sprintf(full_name, "%s%c%s", curSymDir, DIR_SEP, curFileName); } else { sprintf(full_name, "%s%c%s", curDir, DIR_SEP, curFileName); } if (file_type == OBJ_FILE_TYPE && gzipped) { char tmp_fname[MAXPATHLENGTH]; if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { return; } strcpy(gzipped_fname, full_name); strcpy(full_name, tmp_fname); } if (*gzipped_fname == '\0') { if ((short_name=IsPrefix(bootDir, full_name, &rest))) ++rest; } else { if ((short_name=IsPrefix(bootDir, gzipped_fname, &rest))) ++rest; } if ((fp=fopen(full_name, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_WRITE_FILE_NOT_SAVE), (short_name ? rest : full_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (*gzipped_fname != '\0') unlink(full_name); return; } if (short_name) { sprintf(gszMsgBox, TgLoadString(STID_SAVING_DOTS), rest); } else { sprintf(gszMsgBox, TgLoadString(STID_SAVING_DOTS), (*gzipped_fname == '\0' ? full_name : gzipped_fname)); } Msg(gszMsgBox); watch_cursor = watchCursorOnMainWindow; if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; MakeQuiescent(); saved_cur_page = curPage; for (curPage=firstPage, count=1; curPage != NULL; curPage=curPage->next, count++) { topObj = curPage->top; botObj = curPage->bot; Save(fp, botObj, 0, count); } curPage = saved_cur_page; topObj = curPage->top; botObj = curPage->bot; fclose(fp); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(full_name); } else { if (*gzipped_fname != '\0') { if (!GzipFile(full_name, gzipped_fname)) { sprintf(gszMsgBox, TgLoadString(STID_PROBLEM_ZIPPING_PLEASE_SAVE), full_name, gzipped_fname, full_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(full_name); return; } unlink(full_name); strcpy(full_name, gzipped_fname); } sprintf(gszMsgBox, TgLoadString(STID_FILE_SAVED), (short_name ? rest : full_name)); Msg(gszMsgBox); SetFileModified(FALSE); if (!NameInCurDir(curFileName)) UpdateDirInfo(); } SetCurChoice(curChoiceBeforeMakeQuiescent); } void SavePages(pSpecifyPagesInfo) SpecifyPagesInfo *pSpecifyPagesInfo; { char new_file_name[MAXPATHLENGTH+1], gzipped_fname[MAXPATHLENGTH+1]; char new_full_name[MAXPATHLENGTH+1], *rest=NULL; char obj_ext_str[MAXSTRING+1], gz_obj_ext_str[MAXSTRING+1]; char sym_ext_str[MAXSTRING+1], pin_ext_str[MAXSTRING+1]; int no_name=FALSE, gzipped=FALSE, file_type=0, page_num=0; int count=0, len, short_name=FALSE, ok=TRUE, watch_cursor=FALSE; struct ObjRec *obj_ptr=NULL; struct ObjRec *obj_ptr1=NULL, *obj_ptr2=NULL; struct PageRec *saved_cur_page=NULL; struct AttrRec *attr_ptr=NULL; FILE *fp=NULL; file_type = OBJ_FILE_TYPE; *gzipped_fname = '\0'; sprintf(gszMsgBox, TgLoadString(STID_WORKING_DIRECTORY_IS), (curDirIsLocal ? curDir : curLocalDir)); *new_file_name = '\0'; Dialog(TgLoadString(STID_ENTER_NEW_FNAME_ACCEPT_CANCEL), gszMsgBox, new_file_name); UtilTrimBlanks(new_file_name); if (*new_file_name == '\0') return; len = strlen(new_file_name); saved_cur_page = curPage; for (page_num=0, curPage=firstPage; curPage != NULL; curPage=curPage->next, page_num++) { if (pSpecifyPagesInfo->page_specified[page_num]) { for (obj_ptr=curPage->top; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (obj_ptr->type == OBJ_SYM) { if (obj_ptr1 == NULL) { obj_ptr1 = obj_ptr; } else if (obj_ptr2 == NULL) { obj_ptr2 = obj_ptr; } count++; } } } } curPage = saved_cur_page; sprintf(obj_ext_str, ".%s", OBJ_FILE_EXT); sprintf(gz_obj_ext_str, ".%s.gz", OBJ_FILE_EXT); sprintf(sym_ext_str, ".%s", SYM_FILE_EXT); sprintf(pin_ext_str, ".%s", PIN_FILE_EXT); if (count > 2) { MsgBox(TgLoadString(STID_TOO_MANY_SYM_ABORT_SAVE), TOOL_NAME, INFO_MB); return; } if (count >= 1 && pSpecifyPagesInfo->num_pages_specified != 1) { MsgBox(TgLoadString(count==1 ? STID_ONE_PAGE_SYM_ABORT_SAVE : STID_ONE_PAGE_PIN_ABORT_SAVE), TOOL_NAME, INFO_MB); return; } switch (count) { case 0: if (FileNameHasExtension(new_file_name, OBJ_FILE_TYPE, &gzipped, &no_name)) { /* don't modify */ } else if (FileNameHasExtension(new_file_name, SYM_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_SYM_NO_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, PIN_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_PIN_NO_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else { strcat(new_file_name, obj_ext_str); } file_type = OBJ_FILE_TYPE; break; case 1: if ((attr_ptr=FindAttrWithName(obj_ptr1, "type=", NULL)) != NULL && strcmp(attr_ptr->attr_value.s, "tgif_pin") == 0) { if (FileNameHasExtension(new_file_name, OBJ_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_OJB_ONE_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, SYM_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_SYM_SAVE_AS_PIN), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, PIN_FILE_TYPE, NULL, &no_name)) { /* don't modify */ } else { strcat(new_file_name, pin_ext_str); } file_type = PIN_FILE_TYPE; } else { if (FileNameHasExtension(new_file_name, OBJ_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_OJB_ONE_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, SYM_FILE_TYPE, NULL, &no_name)) { /* don't modify */ } else if (FileNameHasExtension(new_file_name, PIN_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_PIN_ONE_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else { strcat(new_file_name, sym_ext_str); } file_type = SYM_FILE_TYPE; } break; case 2: if (FileNameHasExtension(new_file_name, OBJ_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_OJB_TWO_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, SYM_FILE_TYPE, NULL, &no_name)) { MsgBox(TgLoadString(STID_CANT_SAVE_SYM_TWO_SYM_FOUND), TOOL_NAME, INFO_MB); return; } else if (FileNameHasExtension(new_file_name, PIN_FILE_TYPE, NULL, &no_name)) { /* don't modify */ } else { strcat(new_file_name, pin_ext_str); } if (obj_ptr2->fattr != NULL) { obj_ptr = obj_ptr2; obj_ptr2 = obj_ptr1; obj_ptr1 = obj_ptr; } if ((attr_ptr=FindAttrWithName(obj_ptr1, "type=", NULL)) == NULL) { MsgBox(TgLoadString(STID_CANT_FIND_TYPE_ATTR_NOT_SAVED), TOOL_NAME, INFO_MB); return; } if (strcmp(attr_ptr->attr_value.s, "tgif_pin") != 0) { sprintf(gszMsgBox, TgLoadString(STID_SYM_TYPE_WRONG_PIN_NOT_SAVED), "tgif_pin"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } file_type = PIN_FILE_TYPE; break; default: return; } if (no_name) { MsgBox(TgLoadString(STID_NO_FILE_NAME_FILE_NOT_SAVED), TOOL_NAME, INFO_MB); return; } if (*new_file_name == DIR_SEP) { strcpy(new_full_name, new_file_name); } else if (curDirIsLocal) { sprintf(new_full_name, "%s%c%s", curDir, DIR_SEP, new_file_name); } else { sprintf(new_full_name, "%s%c%s", curLocalDir, DIR_SEP, new_file_name); } if (file_type == OBJ_FILE_TYPE && gzipped) { char tmp_fname[MAXPATHLENGTH]; if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { return; } strcpy(gzipped_fname, new_full_name); strcpy(new_full_name, tmp_fname); } if (!OkayToCreateFile((*gzipped_fname=='\0') ? new_full_name : gzipped_fname)) { if (*gzipped_fname != '\0') unlink(new_full_name); return; } if (*gzipped_fname == '\0') { if ((short_name=IsPrefix(bootDir, new_full_name, &rest))) ++rest; } else { if ((short_name=IsPrefix(bootDir, gzipped_fname, &rest))) ++rest; } if ((fp=fopen(new_full_name, "w")) == NULL) { if (short_name) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_WRITE_FILE_NOT_SAVE), rest); } else { if (*gzipped_fname == '\0') { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_WRITE_FILE_NOT_SAVE), new_full_name); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_WRITE_FILE_NOT_SAVE), gzipped_fname); } } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (*gzipped_fname != '\0') unlink(new_full_name); return; } if (short_name) { sprintf(gszMsgBox, TgLoadString(STID_SAVING_DOTS), rest); } else { if (*gzipped_fname == '\0') { sprintf(gszMsgBox, TgLoadString(STID_SAVING_DOTS), new_full_name); } else { sprintf(gszMsgBox, TgLoadString(STID_SAVING_DOTS), gzipped_fname); } } Msg(gszMsgBox); if (!saveCommentsInSaveNew) CleanUpComments(); watch_cursor = watchCursorOnMainWindow; if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; saved_cur_page = curPage; for (page_num=0, curPage=firstPage, count=1; curPage != NULL; curPage=curPage->next, page_num++) { if (pSpecifyPagesInfo->page_specified[page_num]) { int saved_cur_page_num=curPageNum, saved_last_page_num=lastPageNum; int need_to_restore_page_nums=FALSE; topObj = curPage->top; botObj = curPage->bot; if (count == 1) { curPageNum = 1; lastPageNum = pSpecifyPagesInfo->num_pages_specified; need_to_restore_page_nums = TRUE; } Save(fp, botObj, 0, count++); if (need_to_restore_page_nums) { curPageNum = saved_cur_page_num; lastPageNum = saved_last_page_num; } } } curPage = saved_cur_page; topObj = curPage->top; botObj = curPage->bot; fclose(fp); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(new_full_name); ok = FALSE; } else { if (*gzipped_fname != '\0') { if (!GzipFile(new_full_name, gzipped_fname)) { sprintf(gszMsgBox, TgLoadString(STID_PROBLEM_ZIPPING_PLEASE_SAVE), new_full_name, gzipped_fname, new_full_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } unlink(new_full_name); strcpy(new_full_name, gzipped_fname); } if (ok) { if (pSpecifyPagesInfo->num_pages_specified > 1) { sprintf(gszMsgBox, TgLoadString(STID_MANY_PAGES_SAVED_INTO_GIVEN), pSpecifyPagesInfo->num_pages_specified, (short_name ? rest : new_full_name)); } else { sprintf(gszMsgBox, TgLoadString(STID_ONE_PAGE_SAVED_INTO_GIVEN), (short_name ? rest : new_full_name)); } Msg(gszMsgBox); } else { sprintf(gszMsgBox, TgLoadString(STID_FILE_NOT_SAVED), (short_name ? rest : new_full_name)); Msg(gszMsgBox); } } } char *ParseStr(Str, C, Left, LeftSz) char *Str, *Left; int C, LeftSz; { register char *s=Str, *l=Left; register int len=0; int max_len=LeftSz-1; char the_char=(char)C; while (*s != '\0' && *s != the_char) { if (len < max_len) { *l++ = *s++; len++; } else { break; } } if (*s == the_char) s++; *l = '\0'; while (len >= 2 && *Left == '\'' && *(--l) == '\'') { char *c_ptr, *c_ptr1; *l-- = '\0'; len -= 2; c_ptr = &Left[1]; c_ptr1 = Left; while (*c_ptr != '\0') *c_ptr1++ = *c_ptr++; *c_ptr1 = '\0'; } return s; } char *FindChar(C, Str) int C; char *Str; /* returns the address of the character right after C of the string Str */ { register char *s=Str, the_char=(char)C; while (*s != '\0' && *s != the_char) s++; if (*s == the_char) s++; return s; } void SaveCreatorID(FP, obj_ptr, psz_prefix) FILE *FP; struct ObjRec *obj_ptr; char *psz_prefix; { char buf[MAXSTRING]; if (obj_ptr->creator_full_id == NULL) { sprintf(buf, "%1d/%s", obj_ptr->id, gszLocalPID); } else { strcpy(buf, obj_ptr->creator_full_id); } if (fprintf(FP, "\n%s\"", psz_prefix) == EOF) writeFileFailed = TRUE; SaveString(FP, buf); if (fprintf(FP, "\",") == EOF) writeFileFailed = TRUE; } int ReadCreatorID(FP, ObjPtr) FILE *FP; struct ObjRec **ObjPtr; { int ok=TRUE; char *c_ptr=NULL, *line=NULL, full_id[MAXSTRING]; if ((line=UtilGetALine(FP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanFileName, scanLineNum, "ReadCreatorID()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } scanLineNum++; c_ptr = FindChar((int)'"', line); c_ptr = ParseStr(c_ptr, (int)'"', full_id, sizeof(full_id)); if (c_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_BAD_FIELD_IN_FUNC_ABORT_READ), scanFileName, scanLineNum, "creator_full_id", "ReadCreatorID()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } (*ObjPtr)->creator_full_id = UtilStrDup(full_id); if ((*ObjPtr)->creator_full_id == NULL) FailAllocMessage(); free(line); return ok; } static int NumFieldsToFontStr(buf) char *buf; /* 300.000,0,0,0,16,1,0,1,1,0,0,1,0,1,0,'...' */ { char *psz=NULL, *psz_single_quote=strchr(buf, '\''); int count=0; if (psz_single_quote == NULL) { return (-1); } *psz_single_quote = '\0'; for (psz=strchr(buf, ','); psz != NULL; psz=strchr(&psz[1], ',')) { count++; } *psz_single_quote = '\''; return count; } static int gnCannotFindColorMsg=FALSE; static int ReadState(Inbuf) char *Inbuf; { char *s, font_str[MAXSTRING], sb_font_str[MAXSTRING]; int page_style, forced_use_gray=FALSE, compat_dpi, font_sz=0, sz_unit=0; int page_arg1=0, page_arg2=0, rotate=ROTATE0; int one_page_width=0, one_page_height=0; *font_str = *sb_font_str = '\0'; s = FindChar((int)'(', Inbuf); if (sscanf(s, "%d", &page_style) != 1) return FALSE; s = FindChar((int)',', s); if (*s == '\0') { fileVersion = INVALID; } else if (sscanf(s, "%d", &fileVersion) != 1) { return FALSE; } if (fileVersion > CUR_VERSION) return FALSE; gnCannotFindColorMsg = FALSE; if (!importingFile && !mergingFile) { if (fileVersion <= 13) { switch (page_style) { case PORTRAIT: printMag = (float)100.0; break; case LANDSCAPE: printMag = (float)100.0; break; case HIGHPORT: printMag = (float)50.0; page_style = PORTRAIT; break; case HIGHLAND: printMag = (float)50.0; page_style = LANDSCAPE; break; case SLIDEPORT: printMag = (float)200.0; page_style = PORTRAIT; break; case SLIDELAND: printMag = (float)200.0; page_style = LANDSCAPE; break; default: sprintf(gszMsgBox, TgLoadString(STID_UNRECOG_PAGE_STYLE), page_style); TwoLineMsg(gszMsgBox, TgLoadString(STID_PORTRAIT_STYLE_ASSUMED)); page_style = PORTRAIT; printMag = (float)100.0; break; } } else { int num_fields_to_font_str=0; if (page_style != PORTRAIT && page_style != LANDSCAPE) { sprintf(gszMsgBox, TgLoadString(STID_UNRECOG_PAGE_STYLE), page_style); TwoLineMsg(gszMsgBox, TgLoadString(STID_PORTRAIT_STYLE_ASSUMED)); page_style = PORTRAIT; } s = FindChar((int)',', s); /* begin locale bug fix kluge */ num_fields_to_font_str = NumFieldsToFontStr(s); if (num_fields_to_font_str == (-1)) { /* cannot find single quote */ } else if (num_fields_to_font_str == 15) { /* normal case */ } else if (num_fields_to_font_str == 16) { /* extra one, must be the locale bug, fix it! */ char *psz_comma=strchr(s, ','); *psz_comma = '.'; } else { /* don't know what happened */ } /* end locale bug fix kluge */ sscanf(s, "%f", &printMag); } pageStyle = page_style; } if (PRTGIF && useGray) forced_use_gray = TRUE; if (importingFile || mergingFile) return TRUE; page_arg1 = page_arg2 = 1; one_page_width = onePageWidth; one_page_height = onePageHeight; if (fileVersion >= 2) { compat_dpi = FONT_DPI_75; curDash = 0; gridSystem = ENGLISH_GRID; xyMetricGrid = DEFAULT_METRIC_GRID; textVSpace = 0; zoomedIn = FALSE; rcbRadius = DEF_RCB_RADIUS; pageLayoutMode = PAGE_STACK; paperCol = paperRow = 1; curPageNum = lastPageNum = 1; pageLineShownInTileMode = TRUE; if (usePaperSizeStoredInFile) ResetOnePageSize(); s = FindChar((int)',', s); InitScan(s, "\t\n, "); if (fileVersion <= 3) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); if (lineWidth == LINE_CURVED) { lineWidth = 0; curSpline = LT_SPLINE; } else { curSpline = LT_STRAIGHT; } } else if (fileVersion <= 7) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); } else if (fileVersion <= 8) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); } else if (fileVersion <= 11) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); } else if (fileVersion <= 12) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); } else if (fileVersion <= 18) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); } else if (fileVersion <= 19) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); } else if (fileVersion <= 21) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); GETINT("state", gridShown, "Grid Shown"); GETINT("state", moveMode, "Move Mode"); } else if (fileVersion <= 26) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); GETINT("state", gridShown, "Grid Shown"); GETINT("state", moveMode, "Move Mode"); GETINT("state", rotate, "Text Rotation"); GETINT("state", rcbRadius, "RCBox Radius"); } else if (fileVersion <= 27) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); GETINT("state", gridShown, "Grid Shown"); GETINT("state", moveMode, "Move Mode"); GETINT("state", rotate, "Text Rotation"); GETINT("state", rcbRadius, "RCBox Radius"); GETINT("state", useGray, "Use Gray Scale"); } else if (fileVersion <= 28) { /* Matsuda's Version */ GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); GETINT("state", gridShown, "Grid Shown"); GETINT("state", moveMode, "Move Mode"); GETINT("state", rotate, "Text Rotation"); GETINT("state", rcbRadius, "RCBox Radius"); GETINT("state", useGray, "Use Gray Scale"); GETINT("state", paperCol, "Num Columns"); GETINT("state", paperRow, "Num Rows"); GETINT("state", curPageNum, "Current Page Number"); GETINT("state", lastPageNum, "Last Page Number"); } else if (fileVersion <= 29) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETINT("state", curFont, "Font Name"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); GETINT("state", gridShown, "Grid Shown"); GETINT("state", moveMode, "Move Mode"); GETINT("state", rotate, "Text Rotation"); GETINT("state", rcbRadius, "RCBox Radius"); GETINT("state", useGray, "Use Gray Scale"); GETINT("state", pageLayoutMode,"Page Layout Mode"); GETINT("state", page_arg1, "Page Layout Subarg 1"); GETINT("state", page_arg2, "Page Layout Subarg 2"); GETINT("state", pageLineShownInTileMode,"Page Lines Shown"); } else if (fileVersion <= 30) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETSTR("state", font_str, "Font Name String"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); GETINT("state", gridShown, "Grid Shown"); GETINT("state", moveMode, "Move Mode"); GETINT("state", rotate, "Text Rotation"); GETINT("state", rcbRadius, "RCBox Radius"); GETINT("state", useGray, "Use Gray Scale"); GETINT("state", pageLayoutMode,"Page Layout Mode"); GETINT("state", page_arg1, "Page Layout Subarg 1"); GETINT("state", page_arg2, "Page Layout Subarg 2"); GETINT("state", pageLineShownInTileMode,"Page Lines Shown"); } else if (fileVersion <= 31) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETSTR("state", font_str, "Font Name String"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); GETINT("state", gridShown, "Grid Shown"); GETINT("state", moveMode, "Move Mode"); GETINT("state", rotate, "Text Rotation"); GETINT("state", rcbRadius, "RCBox Radius"); GETINT("state", useGray, "Use Gray Scale"); GETINT("state", pageLayoutMode,"Page Layout Mode"); GETINT("state", page_arg1, "Page Layout Subarg 1"); GETINT("state", page_arg2, "Page Layout Subarg 2"); GETINT("state", pageLineShownInTileMode,"Page Lines Shown"); GETINT("state", colorDump, "Print In Color"); } else if (fileVersion <= 32) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETSTR("state", font_str, "Font Name String"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); GETINT("state", gridShown, "Grid Shown"); GETINT("state", moveMode, "Move Mode"); GETINT("state", rotate, "Text Rotation"); GETINT("state", rcbRadius, "RCBox Radius"); GETINT("state", useGray, "Use Gray Scale"); GETINT("state", pageLayoutMode, "Page Layout Mode"); GETINT("state", page_arg1, "Page Layout Subarg 1"); GETINT("state", page_arg2, "Page Layout Subarg 2"); GETINT("state", pageLineShownInTileMode,"Page Lines Shown"); GETINT("state", colorDump, "Print In Color"); GETINT("state", one_page_width, "One Page Width"); GETINT("state", one_page_height,"One Page Height"); } else if (fileVersion <= 34) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETSTR("state", font_str, "Font Name String"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); GETINT("state", gridShown, "Grid Shown"); GETINT("state", moveMode, "Move Mode"); GETINT("state", rotate, "Text Rotation"); GETINT("state", rcbRadius, "RCBox Radius"); GETINT("state", useGray, "Use Gray Scale"); GETINT("state", pageLayoutMode, "Page Layout Mode"); GETINT("state", page_arg1, "Page Layout Subarg 1"); GETINT("state", page_arg2, "Page Layout Subarg 2"); GETINT("state", pageLineShownInTileMode,"Page Lines Shown"); GETINT("state", colorDump, "Print In Color"); GETINT("state", one_page_width, "One Page Width"); GETINT("state", one_page_height,"One Page Height"); GETINT("state", stretchableText,"Stretchable Text"); GETINT("state", textRotation, "Text Rotation"); GETINT("state", rotationIncrement,"Rotation Increment"); } else if (fileVersion <= 35) { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETSTR("state", font_str, "Font Name String"); GETINT("state", curStyle, "Font Style"); GETINT("state", font_sz, "Font Size"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); GETINT("state", gridShown, "Grid Shown"); GETINT("state", moveMode, "Move Mode"); GETINT("state", rotate, "Text Rotation"); GETINT("state", rcbRadius, "RCBox Radius"); GETINT("state", useGray, "Use Gray Scale"); GETINT("state", pageLayoutMode, "Page Layout Mode"); GETINT("state", page_arg1, "Page Layout Subarg 1"); GETINT("state", page_arg2, "Page Layout Subarg 2"); GETINT("state", pageLineShownInTileMode,"Page Lines Shown"); GETINT("state", colorDump, "Print In Color"); GETINT("state", one_page_width, "One Page Width"); GETINT("state", one_page_height,"One Page Height"); GETINT("state", stretchableText,"Stretchable Text"); GETINT("state", textRotation, "Text Rotation"); GETINT("state", rotationIncrement,"Rotation Increment"); GETINT("state", transPat, "Pattern Transparency"); } else { GETINT("state", drawOrigX, "X Draw Origin"); GETINT("state", drawOrigY, "Y Draw Origin"); GETINT("state", zoomScale, "Zoom scale"); GETINT("state", xyEnglishGrid, "English Grid"); GETINT("state", snapOn, "Grid"); GETINT("state", colorIndex, "Color"); GETINT("state", horiAlign, "Horizontal Align"); GETINT("state", vertAlign, "Vertical Align"); GETINT("state", lineWidth, "Line Width"); GETINT("state", curSpline, "Spline"); GETINT("state", lineStyle, "Line Style"); GETINT("state", objFill, "Fill Pattern"); GETINT("state", penPat, "Pen Pattern"); GETINT("state", textJust, "Text Justify"); GETSTR("state", font_str, "Font Name String"); GETINT("state", curStyle, "Font Style"); GETINT("state", sz_unit, "Font Size Unit"); GETINT("state", compat_dpi, "Font DPI"); GETINT("state", curDash, "Dash Style"); GETINT("state", gridSystem, "Grid System"); GETINT("state", xyMetricGrid, "Metric Grid"); GETINT("state", textVSpace, "Text Vertical Spacing"); GETINT("state", zoomedIn, "Zoomed In"); GETINT("state", gridShown, "Grid Shown"); GETINT("state", moveMode, "Move Mode"); GETINT("state", rotate, "Text Rotation"); GETINT("state", rcbRadius, "RCBox Radius"); GETINT("state", useGray, "Use Gray Scale"); GETINT("state", pageLayoutMode, "Page Layout Mode"); GETINT("state", page_arg1, "Page Layout Subarg 1"); GETINT("state", page_arg2, "Page Layout Subarg 2"); GETINT("state", pageLineShownInTileMode,"Page Lines Shown"); GETINT("state", colorDump, "Print In Color"); GETINT("state", one_page_width, "One Page Width"); GETINT("state", one_page_height,"One Page Height"); GETINT("state", stretchableText,"Stretchable Text"); GETINT("state", textRotation, "Text Rotation"); GETINT("state", rotationIncrement,"Rotation Increment"); GETINT("state", transPat, "Pattern Transparency"); } if (fileVersion <= 28) readingPageNum++; if (fileVersion <= 29) { VerifyCompatibleFontIndex(&curFont); font_sz = GetCompatibleSize(compat_dpi, font_sz); curSzUnit = FontSizeToSzUnit(font_sz); if (PRTGIF) { PrTgifInitBaseFonts(); } } else { char *psz=NULL; int len=strlen(font_str); if (fileVersion <= 35) { curSzUnit = FontSizeToSzUnit(font_sz); } else { curSzUnit = sz_unit; } if (len > 1 && *font_str == '\'' && font_str[len-1] == '\'') { char *psz1=(&font_str[1]); font_str[len-1] = '\0'; psz = font_str; while (*psz1 != '\0') *psz++ = *psz1++; *psz = '\0'; } if ((psz=strchr(font_str, '%')) != NULL) { *psz++ = '\0'; /* Ex., ignore last '%' if font_str eq "Courier%". */ if (*psz != '\0') { strcpy(sb_font_str, font_str); strcpy(font_str, psz); } } curFont = GetFontIndex(font_str, curStyle, TRUE); if (curFont == INVALID && (!PRTGIF || cmdLineOpenDisplay)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_FIND_FONT_USE_ALT), font_str, "Times"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); curFont = FONT_TIM; } } switch (pageLayoutMode) { case PAGE_STACK: curPageNum = page_arg1; lastPageNum = page_arg2; paperCol = paperRow = 1; pageLineShownInTileMode = TRUE; break; case PAGE_TILE: paperCol = page_arg1; paperRow = page_arg2; curPageNum = lastPageNum = 1; break; } loadedCurPageNum = curPageNum; InitPage(); curPageNum = loadedCurPageNum; if (fileVersion <= 13) { switch (gridSystem) { case ENGLISH_GRID: drawOrigX += HALF_INCH; drawOrigY += HALF_INCH; break; case METRIC_GRID: drawOrigX += 2.5*ONE_CM; drawOrigY += 2.5*ONE_CM; break; } } if ((usePaperSizeStoredInFile || PRTGIF) && fileVersion >= 32) { if (pageStyle == LANDSCAPE) { onePageWidth = one_page_height; onePageHeight = one_page_width; } else { onePageWidth = one_page_width; onePageHeight = one_page_height; } SetPSPageWidthHeight(); if (PRTGIF) { UpdPageStyle(pageStyle); } } if (PRTGIF && !cmdLineOpenDisplay) { if (forced_use_gray) useGray = TRUE; return TRUE; } if (rotate != 0) { switch (rotate) { case ROTATE0: textRotation = 0; break; case ROTATE90: textRotation = (90<<6); break; case ROTATE180: textRotation = (180<<6); break; case ROTATE270: textRotation = (270<<6); break; } rotationIncrement = (90<<6); rotate = ROTATE0; } if (colorIndex >= maxColors) { fprintf(stderr, TgLoadString(STID_CANT_FIND_COLOR_NUM_USE_CUR), colorIndex, colorMenuItems[defaultColorIndex]); fprintf(stderr, "\n"); colorIndex = defaultColorIndex; gnCannotFindColorMsg = TRUE; } SetCanvasFont(); /* * if (!PRTGIF && SzUnitToFontSize(curSzUnit) != canvasFontSize) { * curFont = actualCurFont; * curSzUnit = actualCurSzUnit; * SetFileModified(TRUE); * } */ } /* * Move from below. Hope this won't change anything! */ UpdDrawWinWH(); UpdPageStyle(pageStyle); if (PRTGIF && !cmdLineOpenDisplay) return TRUE; if (lineWidth >= maxLineWidths) { fprintf(stderr, TgLoadString(STID_LINEWIDTH_IDX_RANGE_SET_TO_0), lineWidth); fprintf(stderr, "\n"); lineWidth = 0; } RedrawScrollBars(); ShowPage(); ShowPageLayout(); UpdDrawWinBBox(); SetDefaultDrawWinClipRecs(); DrawPaperBoundary(drawWindow); RedrawGridLines(drawWindow); RedrawPageLines(drawWindow); RedrawRulers(); RedrawChoiceWindow(); return TRUE; } static void ReadObjAttrs(MinFileVersion, FP, ObjPtr) int MinFileVersion; FILE *FP; struct ObjRec **ObjPtr; { struct AttrRec *top_attr=NULL, *bot_attr=NULL, *attr_ptr; if (fileVersion <= MinFileVersion) return; while (ReadAttr(FP, &attr_ptr)) { attr_ptr->owner = *ObjPtr; attr_ptr->prev = NULL; attr_ptr->next = top_attr; if (top_attr == NULL) { bot_attr = attr_ptr; } else { top_attr->prev = attr_ptr; } top_attr = attr_ptr; } if (bot_attr != NULL) bot_attr->next = NULL; if (*ObjPtr == NULL) { DelAllAttrs(top_attr); } else { (*ObjPtr)->fattr = top_attr; (*ObjPtr)->lattr = bot_attr; } } static int ReadPageObj(Inbuf, ppsz_page_name) char *Inbuf, **ppsz_page_name; { int page_num=0, reading_page_num=0; char *s=NULL, *c_ptr=NULL; if (ppsz_page_name != NULL) *ppsz_page_name = NULL; s = FindChar((int)'(', Inbuf); if (sscanf(s, "%d", &page_num) != 1) { sprintf(gszMsgBox, TgLoadString(STID_BAD_FIELD_IN_OBJ_ABORT_READ), scanFileName, scanLineNum, "page_num", "page"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } reading_page_num = page_num; if (!importingFile) { char saved_ch='\0'; for (curPage=firstPage; page_num != 1 && curPage != NULL; curPage=curPage->next, page_num--) { } if (curPage == NULL) { if (!mergingFile) { sprintf(gszMsgBox, TgLoadString(STID_BAD_INPUT_WHILE_READ_PAGE), page_num); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } AddPageAfter(); } s = FindChar((int)',', s); c_ptr = FindChar((int)'"', s); s = ReadString(c_ptr); saved_ch = *(--s); *s = '\0'; if (*c_ptr != '\0') { curPage->name = UtilStrDup(c_ptr); if (curPage->name == NULL) FailAllocMessage(); } *s++ = saved_ch; InitScan(s, "\t\n, )"); topObj = curPage->top; botObj = curPage->bot; curPage->layer_on = TRUE; if (fileVersion <= 32) { } else { int layer_on=TRUE; char page_file_name[MAXSTRING]; if (GETINT("page", layer_on, "color layer on") == INVALID) { return FALSE; } curPage->layer_on = layer_on; /* * This is a hack! If the file version becomes >= 38, this code * must be removed! */ if (GETSTR("page", page_file_name, "page_file_name") == INVALID) { /* should not get here because we should have read in: "." */ return FALSE; } else if (strcmp(page_file_name, ".") == 0) { *page_file_name = '\0'; } else if (*page_file_name == '\'') { UtilRemoveQuotes(page_file_name); } if (*page_file_name != '\0') { char *psz=strchr(page_file_name, ' '); if (psz != NULL) { char truncated_name[MAXSTRING]; *psz = *truncated_name = '\0'; UtilStrCpyN(truncated_name, sizeof(truncated_name), page_file_name); *psz = ' '; sprintf(gszMsgBox, TgLoadString(STID_BAD_PAGE_FILE_NAME_TRUNC_TO), page_file_name, truncated_name); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } strcpy(page_file_name, truncated_name); } curPage->page_file_name = UtilStrDup(page_file_name); if (curPage->page_file_name == NULL) FailAllocMessage(); } } } else { s = FindChar((int)',', s); c_ptr = FindChar((int)'"', s); s = ReadString(c_ptr); *(--s) = '\0'; if (*c_ptr != '\0' && ppsz_page_name != NULL) { *ppsz_page_name = UtilStrDup(c_ptr); if (*ppsz_page_name == NULL) FailAllocMessage(); } } readingPageNum++; if (readingPageNum < reading_page_num) { readingPageNum = reading_page_num; } return TRUE; } static int ReadUnitObj(Inbuf) char *Inbuf; { if (!importingFile) { char *s=FindChar((int)'(', Inbuf), *c_ptr; c_ptr = FindChar((int)'"', s); s = ReadString(c_ptr); *(--s) = '\0'; if (SetUnit(c_ptr)) { return TRUE; } else { return FALSE; } } return TRUE; } static int ReadGeneratedBy(Inbuf) char *Inbuf; { int ok=TRUE; char *s=FindChar((int)'(', Inbuf); memset(&gGenerateByInfo, 0, sizeof(GenerateByInfo)); if (s == NULL) { ok = FALSE; } else { GenerateByInfo *pgbi=(&gGenerateByInfo); InitScan(s, "\t\n, "); if (GETSTR("generated_by", pgbi->name, "name") == INVALID || GETINT("generated_by", pgbi->version, "version") == INVALID || GETSTR("generated_by", pgbi->version_str, "version_str") == INVALID) { ok = FALSE; memset(&gGenerateByInfo, 0, sizeof(GenerateByInfo)); } else { UtilRemoveQuotes(pgbi->name); UtilRemoveQuotes(pgbi->version_str); } } if (!ok) { fprintf(stderr, TgLoadCachedString(CSTID_MALFORMED_LINE_NUM_IN_FILE), scanLineNum, scanFileName); fprintf(stderr, "\n"); } return TRUE; } static int ReadScriptFracObj(Inbuf) char *Inbuf; { if (!importingFile) { char *s=FindChar((int)'(', Inbuf), *c_ptr=NULL; c_ptr = FindChar((int)'"', s); s = ReadString(c_ptr); *(--s) = '\0'; if (!FixDecimalPoint(c_ptr)) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "FixDecimalPoint() failed in ReadScriptFracObj().\n"); #endif /* _TGIF_DBG */ } if (SetScriptFractionValue(c_ptr)) { return TRUE; } else { return FALSE; } } return TRUE; } static int ReadRightMarginObj(Inbuf) char *Inbuf; { if (!importingFile) { int right_margin_enabled=FALSE, right_margin=0; char *s=FindChar((int)'(', Inbuf); InitScan(s, "\t\n, )"); GETINT("right_margin", right_margin_enabled, "Right Margin Enabled"); GETINT("right_margin", right_margin, "Right Margin"); rightMarginEnabled = right_margin_enabled; rightMargin = right_margin; rightMarginActive = rightMarginEnabled; if (!PRTGIF) RedrawHRulerWindow(); } return TRUE; } static int ReadThreshFillReplaceObj(Inbuf) char *Inbuf; { if (!importingFile) { int do_msg=FALSE; int saved_thresh_fill_replace_enabled=threshFillReplaceEnabled; int saved_r=fillReplaceRedThresh, r=0; int saved_g=fillReplaceGreenThresh, g=0; int saved_b=fillReplaceBlueThresh, b=0; char *s=FindChar((int)'(', Inbuf); InitScan(s, "\t\n, )"); GETINT("threshold_fill_replace", r, "Red Threshold"); GETINT("threshold_fill_replace", g, "Green Threshold"); GETINT("threshold_fill_replace", b, "Blue Threshold"); do_msg = (saved_thresh_fill_replace_enabled && (saved_r != r || saved_g != g || saved_b != b)); threshFillReplaceEnabled = TRUE; fillReplaceRedThresh = r; fillReplaceGreenThresh = g; fillReplaceBlueThresh = b; if (!PRTGIF && do_msg) { sprintf(gszMsgBox, TgLoadString(STID_FLOOD_REPLACE_ENABLED), fillReplaceRedThresh, fillReplaceGreenThresh, fillReplaceBlueThresh); Msg(gszMsgBox); } } return TRUE; } #define GETSSVALUE(val,name) ScanValue("%d", &(val), name, "shapeshadow") static int ReadShapeShadowObj(Inbuf) char *Inbuf; { if (!importingFile) { char *s=FindChar((int)'(', Inbuf); int dx=0, dy=0; InitScan(s, "\t\n, "); if (GETSSVALUE(dx, "dx") == INVALID || GETSSVALUE(dy, "dy") == INVALID) { return FALSE; } shapeShadowDx = dx; shapeShadowDy = dy; } return TRUE; } static int ReadFgBgColors(Inbuf) char *Inbuf; { if (!importingFile && !PRTGIF) { int new_alloc=FALSE, bg_color_index=INVALID; char *s=FindChar((int)'(', Inbuf), fg_color_str[40], bg_color_str[40]; s = ParseStr(s, (int)',', fg_color_str, sizeof(fg_color_str)); s = ParseStr(s, (int)')', bg_color_str, sizeof(bg_color_str)); UtilTrimBlanks(fg_color_str); UtilTrimBlanks(bg_color_str); allocColorFailed = FALSE; colorIndex = QuickFindColorIndex(NULL, fg_color_str, &new_alloc, TRUE); if (gnCannotFindColorMsg && !allocColorFailed) { sprintf(gszMsgBox, TgLoadString(STID_CUR_COLOR_CORRECTED_TO_BE), colorMenuItems[colorIndex]); fprintf(stderr, " %s\n", gszMsgBox); } bg_color_index = QuickFindColorIndex(NULL, bg_color_str, &new_alloc, FALSE); if (bg_color_index == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_ALLOC_BGCOLOR_USE_DEF), bg_color_str, defaultBgColorStr); fprintf(stderr, "%s\n", gszMsgBox); } else { strcpy(defaultBgColorStr, bg_color_str); defaultBgColorIndex = bg_color_index; } } return TRUE; } static int FreeBufAndReturn(buf, rc) char *buf; int rc; { if (buf != NULL) free(buf); return rc; } int ReadObj(FP, ObjPtr) FILE *FP; struct ObjRec **ObjPtr; { char *line, obj_name[80]; int read_state_ok; *ObjPtr = NULL; while ((line=UtilGetALine(FP)) != NULL) { scanLineNum++; if (*line == ']') return FreeBufAndReturn(line, FALSE); if (*line == '%') { if (!importingFile && line[1]=='%') { int line_len=strlen(line); if (savedComments == NULL) { if ((savedComments=(char*)malloc((line_len+2)*sizeof(char))) == NULL) { FailAllocMessage(); } *savedComments = '\0'; } else { if ((savedComments=(char*)realloc(savedComments, savedCommentsLen+line_len+2)) == NULL) { FailAllocMessage(); } savedComments[savedCommentsLen] = '\0'; } strcat(savedComments, line); savedCommentsLen += line_len; savedComments[savedCommentsLen++] = '\n'; savedComments[savedCommentsLen] = '\0'; } /* do not translate -- program constants */ if (strncmp(line, "%TGWB end - ", strlen("%TGWB end - ")) == 0) { return FreeBufAndReturn(line, FALSE); } free(line); continue; } /* do not translate -- program constants */ if (ParseStr(line, (int)'(', obj_name, sizeof(obj_name)) == NULL) { } else if (strcmp(obj_name, "poly") == 0) { ReadPolyObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(INVALID, FP, ObjPtr); if (RetractedArrowAttr(*ObjPtr) || AutoRetractedArrowAttr(*ObjPtr, TRUE)) { /* fake the undoingOrRedoing so that no */ /* actual auto-adjusting is done */ undoingOrRedoing = TRUE; AdjObjSplineVs(*ObjPtr); undoingOrRedoing = FALSE; } AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "box") == 0) { ReadBoxObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(START_HAVING_ATTRS-1, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "oval") == 0) { ReadOvalObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(START_HAVING_ATTRS-1, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "text") == 0) { ReadTextObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "polygon") == 0) { ReadPolygonObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(START_HAVING_ATTRS-1, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "arc") == 0) { ReadArcObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(START_HAVING_ATTRS-1, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "rcbox") == 0) { ReadRCBoxObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(START_HAVING_ATTRS-1, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "xbm") == 0) { ReadXBmObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(START_HAVING_ATTRS-1, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "xpm") == 0) { ReadXPmObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(START_HAVING_ATTRS-1, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "jpeg") == 0) { ReadJpegObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(START_HAVING_ATTRS-1, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "ppm_true") == 0) { ReadPpmTrueObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(START_HAVING_ATTRS-1, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "group") == 0) { ReadGroupObj(FP, OBJ_GROUP, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(INVALID, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "sym") == 0) { ReadGroupObj(FP, OBJ_SYM, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(INVALID, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "icon") == 0) { ReadGroupObj(FP, OBJ_ICON, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(INVALID, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "pin") == 0) { ReadGroupObj(FP, OBJ_PIN, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); ReadObjAttrs(INVALID, FP, ObjPtr); AdjObjBBox(*ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "simple_string") == 0) { /* reserved */ ReadSimpleStringObj(FP, line, ObjPtr); if (*ObjPtr == NULL) return FreeBufAndReturn(line, FALSE); if (deserializingFile) ReadCreatorID(FP, ObjPtr); return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "page") == 0) { int ok; char *page_name=NULL; *ObjPtr = NULL; if (importingFile && !importingIconFile) { if (importingPageNum == (-1) && *importingPageName == '\0') { if (readingPageNum == 1) { /* as if read to the end of file */ if (!PRTGIF && !pastingFile) { MsgBox(TgLoadString(STID_ONLY_PAGE_1_IMPORTED), TOOL_NAME, INFO_MB); } return FreeBufAndReturn(line, FALSE); } } else { if (readingPageNum == importingPageNum) { /* as if read to the end of file */ if (!PRTGIF && !pastingFile) { sprintf(gszMsgBox, TgLoadString(STID_ONLY_GIVEN_PAGE_IMPORTED), importingPageNum); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FreeBufAndReturn(line, FALSE); } } } ok = ReadPageObj(line, &page_name); if (importingFile && !importingIconFile && importingPageNum == (-1) && *importingPageName != '\0' && page_name != NULL && strcmp(page_name,importingPageName)==0) { *importingPageName = '\0'; importingPageNum = readingPageNum; } if (page_name != NULL) free(page_name); return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "state") == 0) { if ((read_state_ok=ReadState(line)) == TRUE) { foundGoodStateObject = TRUE; } *ObjPtr = NULL; return FreeBufAndReturn(line, (read_state_ok) ? TRUE : INVALID); } else if (strcmp(obj_name, "file_attr") == 0) { if (mergingFile) { struct AttrRec *saved_first_attr=NULL, *saved_last_attr=NULL; saved_first_attr = tgifObj->fattr; saved_last_attr = tgifObj->lattr; tgifObj->fattr = NULL; tgifObj->lattr = NULL; ReadObjAttrs(START_HAVING_ATTRS-1, FP, &tgifObj); if (tgifObj->fattr == NULL) { /* this file has no file attribute -- which should not happen */ tgifObj->fattr = saved_first_attr; tgifObj->lattr = saved_last_attr; } else if (saved_last_attr == NULL) { /* this is this first file that has file attributes, keep it */ } else { tgifObj->fattr->prev = saved_last_attr; saved_last_attr->next = tgifObj->fattr; tgifObj->fattr = saved_first_attr; } } else if (importingFile && !importingIconFile) { struct AttrRec *saved_first_attr=NULL, *saved_last_attr=NULL; saved_first_attr = tgifObj->fattr; saved_last_attr = tgifObj->lattr; tgifObj->fattr = NULL; tgifObj->lattr = NULL; ReadObjAttrs(START_HAVING_ATTRS-1, FP, &tgifObj); DelAllAttrs(tgifObj->fattr); tgifObj->fattr = saved_first_attr; tgifObj->lattr = saved_last_attr; } else { ReadObjAttrs(START_HAVING_ATTRS-1, FP, &tgifObj); } return FreeBufAndReturn(line, TRUE); } else if (strcmp(obj_name, "unit") == 0) { int ok=ReadUnitObj(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "generated_by") == 0) { int ok=ReadGeneratedBy(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "shapeshadow") == 0) { int ok=ReadShapeShadowObj(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "color_info") == 0) { int ok=ReadColors(FP, line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "cmdx") == 0) { int ok=ReadExtendedCmd(FP, line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "cmdxinfo") == 0) { int ok=ReadExtendedCmdInfo(FP, line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "cmd") == 0) { int ok=ReadCmd(FP, line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "before_image") == 0) { int ok=ReadBeforeImage(FP, line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "after_positions") == 0) { int ok=ReadAfterPositions(FP, line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "after_image") == 0) { int ok=ReadAfterImage(FP, line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "slideshow_info") == 0) { int ok=ReadSlideShowInfo(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "script_frac") == 0) { int ok=ReadScriptFracObj(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "fg_bg_colors") == 0) { int ok=ReadFgBgColors(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "html_export_template") == 0) { int ok=ReadHtmlExportTemplate(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "objshadow_info") == 0) { int ok=ReadObjectShadowInfo(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "rotate_pivot") == 0) { int ok=ReadRotatePivotInfo(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "spline_tightness") == 0) { int ok=ReadSplineTightness(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "right_margin") == 0) { int ok=ReadRightMarginObj(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "threshold_fill_replace") == 0) { int ok=ReadThreshFillReplaceObj(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "dont_reencode") == 0) { int ok=ReadDontReencode(line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "ps_font_aliases") == 0) { int ok=ReadPSFontAliases(FP, line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "ps_char_subs") == 0) { int ok=ReadPSCharSubs(FP, line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } else if (strcmp(obj_name, "ps_font_need_char_subs") == 0) { int ok=ReadPSFontNeedCharSubs(FP, line); *ObjPtr = NULL; return FreeBufAndReturn(line, ok); } free(line); } return FALSE; } void AdjForOldVersion(obj_ptr) struct ObjRec *obj_ptr; { if (fileVersion <= 13) { switch (gridSystem) { case ENGLISH_GRID: MoveObj(obj_ptr, (int)(HALF_INCH), (int)(HALF_INCH)); break; case METRIC_GRID: MoveObj(obj_ptr, (int)(2.5*ONE_CM), (int)(2.5*ONE_CM)); break; } } } int DownloadRemoteFile(file_name, ppsz_content_type, ppsz_page_spec, pn_is_html, return_tmp_fname, psz_final_url, cb_final_url) char *file_name, **ppsz_content_type, **ppsz_page_spec, *return_tmp_fname, *psz_final_url; int *pn_is_html, cb_final_url; /* file_name is assumed to be remote */ { int ok=TRUE; char remote_fname[MAXPATHLENGTH+1], *tmp_remote_fname=NULL; if (!FileIsRemote(file_name)) return FALSE; *remote_fname = '\0'; if (ppsz_page_spec != NULL) *ppsz_page_spec = NULL; if (pn_is_html != NULL) *pn_is_html = FALSE; if (!FormNewFileName(curDir, file_name, NULL, remote_fname, ppsz_page_spec)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_REMOTE_FNAME), file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else { int remote_buf_sz=0; char *remote_buf=NULL; SaveStatusStrings(); ok = LoadRemoteFileInMem(remote_fname, &remote_buf, ppsz_content_type, &remote_buf_sz, pn_is_html, navigateRefresh, psz_final_url, cb_final_url); RestoreStatusStrings(); if (ok && remote_buf != NULL) { if ((tmp_remote_fname=WriteRemoteFileIntoTemp(remote_buf, remote_buf_sz, NULL)) == NULL) { ok = FALSE; } } if (remote_buf != NULL) FreeRemoteBuf(remote_buf); } if (tmp_remote_fname != NULL) { strcpy(return_tmp_fname, tmp_remote_fname); FreeRemoteBuf(tmp_remote_fname); } return ok; } int ImportGivenFile(file_name, group_and_lock, highlight) char *file_name; int group_and_lock, highlight; /* returns TRUE if ok */ /* returns FALSE if file_name looks ok, only have temporary problems */ /* returns BAD if file_name is bad */ { struct ObjRec *obj_ptr, *saved_top_obj, *saved_bot_obj; char *rest, remote_fname[MAXPATHLENGTH+1], *remote_buf=NULL; char gzipped_fname[MAXPATHLENGTH+1], *tmp_remote_fname=NULL, *page_spec=NULL; char tmp_filename[MAXPATHLENGTH+1], tmp_filefullpath[MAXPATHLENGTH+1]; int short_name=FALSE, read_status=0, remote_buf_sz=0; int tmp_linenum, file_is_remote=FALSE, interrupted; FILE *fp=NULL; XEvent ev; *gzipped_fname = '\0'; if (FileIsRemote(file_name)) { int rc=TRUE; if (!FormNewFileName(curDir, file_name, NULL, remote_fname, &page_spec)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_REMOTE_FNAME), file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); rc = BAD; } else { int is_html=FALSE;; SaveStatusStrings(); rc = LoadRemoteFileInMem(remote_fname, &remote_buf, NULL, &remote_buf_sz, &is_html, TRUE, NULL, 0); RestoreStatusStrings(); if (rc && remote_buf != NULL) { if ((tmp_remote_fname=WriteRemoteFileIntoTemp(remote_buf, remote_buf_sz, NULL)) != NULL) { file_is_remote = TRUE; } else { rc = FALSE; } } } if (!file_is_remote) { if (remote_buf != NULL) FreeRemoteBuf(remote_buf); return rc; } } else { int gzipped=FALSE; if (FileNameHasExtension(file_name, OBJ_FILE_TYPE, &gzipped, NULL) && gzipped) { char *tmp_fname=NULL; if ((tmp_fname=GunzipFileIntoTemp(file_name)) == NULL) { return BAD; } else { strcpy(gzipped_fname, file_name); strcpy(file_name, tmp_fname); free(tmp_fname); } } } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } if (file_is_remote) { if ((fp=fopen(tmp_remote_fname, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_READ_TMP_FILE), tmp_remote_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(tmp_remote_fname); FreeRemoteBuf(remote_buf); FreeRemoteBuf(tmp_remote_fname); /* temporary problem */ return FALSE; } } else { if (*gzipped_fname == '\0') { if ((short_name=IsPrefix(bootDir, file_name, &rest))) ++rest; } else { if ((short_name=IsPrefix(bootDir, gzipped_fname, &rest))) ++rest; } if ((fp=fopen(file_name, "r")) == NULL) { if (short_name) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_FILE), rest); } else { if (*gzipped_fname == '\0') { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_FILE), file_name); } else { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_FILE), gzipped_fname); } } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (*gzipped_fname != '\0') unlink(file_name); /* temporary problem -- may be the file does not exist yet */ return FALSE; } } strcpy(tmp_filefullpath, scanFileFullPath); strcpy(tmp_filename, scanFileName); tmp_linenum = scanLineNum; UtilStrCpyN(scanFileFullPath, sizeof(scanFileFullPath), file_name); if (file_is_remote) { strcpy(scanFileName, tmp_remote_fname); } else { strcpy(scanFileName, (short_name ? rest : file_name)); } scanLineNum = 0; saved_top_obj = topObj; saved_bot_obj = botObj; curPage->top = curPage->bot = topObj = botObj = NULL; if (file_is_remote) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_IMPORTING_FILE), remote_fname); } else { if (short_name) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_IMPORTING_FILE), rest); } else { if (*gzipped_fname == '\0') { sprintf(gszMsgBox, TgLoadCachedString(CSTID_IMPORTING_FILE), file_name); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_IMPORTING_FILE), gzipped_fname); } } } Msg(gszMsgBox); SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); numRedrawBBox = 0; readingPageNum = loadedCurPageNum = 0; foundGoodStateObject = FALSE; ShowInterrupt(1); interrupted = FALSE; importingPageNum = (-1); *importingPageName = '\0'; if (page_spec != NULL) { if (*page_spec == '#') { importingPageNum = atoi(&page_spec[1]); if (importingPageNum < 1) { importingPageNum = (-1); sprintf(gszMsgBox, TgLoadString(STID_INVALID_PAGE_NUM), page_spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } else { strcpy(importingPageName, page_spec); } } if (importingPageNum == (-1) && *importingPageName == '\0') { while (!interrupted && (read_status=ReadObj(fp, &obj_ptr)) == TRUE) { if (obj_ptr != NULL) { obj_ptr->tmp_parent = NULL; AdjForOldVersion(obj_ptr); UnlockAnObj(obj_ptr); AddObj(NULL, topObj, obj_ptr); if (!interrupted && (PointInBBox(obj_ptr->x, obj_ptr->y, drawWinBBox) || BBoxIntersect(obj_ptr->bbox, drawWinBBox))) { if (!DrawObj(drawWindow, obj_ptr)) interrupted = TRUE; if (CheckInterrupt(TRUE)) interrupted = TRUE; } } } } else if (importingPageNum == (-1)) { while (!interrupted && (read_status=ReadObj(fp, &obj_ptr)) == TRUE) { if (obj_ptr != NULL) { obj_ptr->tmp_parent = NULL; if (importingPageNum == (-1)) { FreeObj(obj_ptr); if (!interrupted && CheckInterrupt(TRUE)) interrupted = TRUE; } else { AdjForOldVersion(obj_ptr); UnlockAnObj(obj_ptr); AddObj(NULL, topObj, obj_ptr); if (!interrupted && (PointInBBox(obj_ptr->x, obj_ptr->y, drawWinBBox) || BBoxIntersect(obj_ptr->bbox, drawWinBBox))) { if (!DrawObj(drawWindow, obj_ptr)) interrupted = TRUE; if (CheckInterrupt(TRUE)) interrupted = TRUE; } } } } } else { while (!interrupted && (read_status=ReadObj(fp, &obj_ptr)) == TRUE) { if (obj_ptr != NULL) { obj_ptr->tmp_parent = NULL; if (importingPageNum != readingPageNum) { FreeObj(obj_ptr); if (!interrupted && CheckInterrupt(TRUE)) interrupted = TRUE; } else { AdjForOldVersion(obj_ptr); UnlockAnObj(obj_ptr); AddObj(NULL, topObj, obj_ptr); if (!interrupted && (PointInBBox(obj_ptr->x, obj_ptr->y, drawWinBBox) || BBoxIntersect(obj_ptr->bbox, drawWinBBox))) { if (!DrawObj(drawWindow, obj_ptr)) interrupted = TRUE; if (CheckInterrupt(TRUE)) interrupted = TRUE; } } } } } if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } if (interrupted) { MsgBox(TgLoadString(STID_USER_INTR_ABORT_DRAW), TOOL_NAME, INFO_MB); } HideInterrupt(); if (fp != NULL) fclose(fp); if (*gzipped_fname != '\0') { unlink(file_name); strcpy(file_name, gzipped_fname); } strcpy(scanFileFullPath, tmp_filefullpath); strcpy(scanFileName, tmp_filename); scanLineNum = tmp_linenum; if (read_status == INVALID) { if (fileVersion > CUR_VERSION) { sprintf(gszMsgBox, TgLoadString(STID_FILE_VER_ABORT_IMPORT), fileVersion, TOOL_NAME, homePageURL); } else { sprintf(gszMsgBox, TgLoadString(STID_FILE_CORRUPTED_ABORT_IMPORT)); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); SetDefaultCursor(mainWindow); ShowCursor(); if (file_is_remote) { unlink(tmp_remote_fname); FreeRemoteBuf(remote_buf); FreeRemoteBuf(tmp_remote_fname); } /* temporary problem -- may be the file will be fixed later */ return FALSE; } if (file_is_remote) { if (!foundGoodStateObject) PasteString(remote_buf, TRUE, TRUE); unlink(tmp_remote_fname); FreeRemoteBuf(remote_buf); FreeRemoteBuf(tmp_remote_fname); } if (topObj != NULL) SetFileModified(TRUE); justDupped = FALSE; if (group_and_lock && topObj != NULL) { if (topObj != botObj || topObj->type==OBJ_POLY || topObj->type==OBJ_POLYGON) { struct ObjRec *top_obj=topObj, *bot_obj=botObj; SelAllObj(FALSE, FALSE); curPage->top = curPage->bot = topObj = botObj = NULL; CreateGroupObj(top_obj, bot_obj); RemoveAllSel(); } topObj->locked = TRUE; } SelAllObj(FALSE, FALSE); if (botObj != NULL) { botObj->next = saved_top_obj; } else { topObj = saved_top_obj; } if (saved_top_obj != NULL) { saved_top_obj->prev = botObj; botObj = saved_bot_obj; } curPage->top = topObj; curPage->bot = botObj; if (!(file_is_remote && !foundGoodStateObject) && topSel != NULL) { PrepareToRecord(CMD_NEW, NULL, NULL, 0); RecordCmd(CMD_NEW, NULL, topSel, botSel, numObjSelected); } if (highlight) HighLightForward(); if (!importFromLibrary && !file_is_remote && !importingFromExec) { SetCurImportDir(file_name); } if (file_is_remote) { sprintf(gszMsgBox, TgLoadString(STID_FILE_IMPORTED), remote_fname); } else { if (short_name) { sprintf(gszMsgBox, TgLoadString(STID_FILE_IMPORTED), rest); } else { sprintf(gszMsgBox, TgLoadString(STID_FILE_IMPORTED), file_name); } } Msg(gszMsgBox); SetDefaultCursor(mainWindow); ShowCursor(); if (page_spec != NULL) free(page_spec); return TRUE; } void ImportFile() { char file_name[MAXPATHLENGTH+1]; MakeQuiescent(); importingFile = TRUE; if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_AN_OBJ_FILE_TO_IMPORT), OBJ_FILE_EXT, name, path) == INVALID) { importingFile = FALSE; return; } sprintf(file_name, "%s%c%s", path, DIR_SEP, name); } else if (SelectFileNameToImport( TgLoadString(STID_SEL_AN_OBJ_FILE_TO_IMPORT), OBJ_FILE_EXT, file_name) == INVALID) { importingFile = FALSE; return; } ImportGivenFile(file_name, FALSE, TRUE); importingFile = FALSE; SetCurChoice(curChoiceBeforeMakeQuiescent); } int ClearBgColorInfo(nRedraw) int nRedraw; { myFileBgPixel = myFileFgPixel = INVALID; if (myFileFgColorStr != NULL) { free(myFileFgColorStr); myFileFgColorStr = NULL; } if (myFileBgColorStr != NULL) { free(myFileBgColorStr); myFileBgColorStr = NULL; XSetWindowBackground(mainDisplay, drawWindow, myBgPixel); if (nRedraw) { ClearAndRedrawDrawWindow(); } RecalcXorPixels(); return TRUE; } return FALSE; } int ClearBgPixmapInfo(nRedraw) int nRedraw; { int changed=FALSE; if (myFileBgGifURL != NULL) { free(myFileBgGifURL); myFileBgGifURL = NULL; changed = TRUE; } myFileBgPixmapW = myFileBgPixmapH = (-1); if (myFileBgPixmap != None) { XFreePixmap(mainDisplay, myFileBgPixmap); myFileBgPixmap = None; XSetWindowBackgroundPixmap(mainDisplay, drawWindow, None); changed = TRUE; } if (changed && nRedraw) { ClearAndRedrawDrawWindow(); } return changed; } int SetFileBgColor() /* assumes myFileBgColorStr is set */ { int new_alloc=FALSE; int index=QuickFindColorIndex(NULL, myFileBgColorStr, &new_alloc, TRUE); if (index != INVALID) { myFileBgPixel = colorPixels[index]; myFileBgColor.pixel = colorPixels[index]; myFileBgColor.red = tgifColors[index].red; myFileBgColor.green = tgifColors[index].green; myFileBgColor.blue = tgifColors[index].blue; XSetWindowBackground(mainDisplay, drawWindow, colorPixels[index]); RecalcXorPixels(); return TRUE; } sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_BGCOLOR_USE_DEF), myFileBgColorStr); Msg(gszMsgBox); return FALSE; } int SetFileFgColor() /* assumes myFileFgColorStr is set */ { int new_alloc=FALSE; int index=QuickFindColorIndex(NULL, myFileFgColorStr, &new_alloc, TRUE); if (index != INVALID) { myFileFgPixel = colorPixels[index]; return TRUE; } sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_FGCOLOR_USE_DEF), myFileFgColorStr); Msg(gszMsgBox); return FALSE; } int SetFileBgPixmap() { int ok=TRUE; char tmp_xpm_fname[MAXPATHLENGTH+1]; if (myFileBgGifURL == NULL) return FALSE; *tmp_xpm_fname = '\0'; if (FileIsRemote(myFileBgGifURL)) { char tmp_gif_fname[MAXPATHLENGTH+1], *content_type=NULL, *page_spec=NULL; int is_html=FALSE; *tmp_gif_fname = '\0'; if (DownloadRemoteFile(myFileBgGifURL, &content_type, &page_spec, &is_html, tmp_gif_fname, NULL, 0)) { if (page_spec != NULL || is_html) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_REMOTE_FNAME), myFileBgGifURL); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); ok = ConvertGifToXpm(tmp_gif_fname, tmp_xpm_fname, sizeof(tmp_xpm_fname)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); } } else { ok = FALSE; } if (content_type != NULL) FreeRemoteBuf(content_type); if (page_spec != NULL) UtilFree(page_spec); if (*tmp_gif_fname != '\0') unlink(tmp_gif_fname); } else { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); ok = ConvertGifToXpm(myFileBgGifURL, tmp_xpm_fname, sizeof(tmp_xpm_fname)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); } if (ok) { int image_w, image_h, w, h, ncolors=0; int chars_per_pixel=0, first_pixel_is_bg=FALSE, *pixels=NULL; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if (!MyReadPixmapFile(tmp_xpm_fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data) == BitmapSuccess) { ok = FALSE; } SetDefaultCursor(mainWindow); ShowCursor(); unlink(tmp_xpm_fname); if (bitmap != None) XFreePixmap(mainDisplay, bitmap); if (image != NULL) XDestroyImage(image); if (bitmap_image != NULL) XDestroyImage(bitmap_image); if (color_char != NULL) free(color_char); if (color_str != NULL) { int i; for (i=0; i < ncolors; i++) free(color_str[i]); free(color_str); } if (ok) { myFileBgPixmapW = image_w; myFileBgPixmapH = image_h; myFileBgPixmap = pixmap; XSetWindowBackgroundPixmap(mainDisplay, drawWindow, myFileBgPixmap); } } if (!ok) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_SET_BGXPM_TO), myFileBgGifURL); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return ok; } void CheckFileAttrsInLoad() { struct AttrRec *attr_ptr; int changed=FALSE; if ((attr_ptr=FindFileAttrWithName("bg_color=")) != NULL) { struct AttrRec *fg_attr_ptr; int ok=TRUE; if ((fg_attr_ptr=FindFileAttrWithName("fg_color=")) != NULL) { if (myFileFgColorStr == NULL || strcmp(fg_attr_ptr->attr_value.s, myFileFgColorStr) != 0) { myFileFgColorStr = UtilStrDup(fg_attr_ptr->attr_value.s); if (myFileFgColorStr == NULL) FailAllocMessage(); if (!SetFileFgColor()) { ClearBgColorInfo(TRUE); ok = FALSE; } } } if (ok && (myFileBgColorStr == NULL || strcmp(attr_ptr->attr_value.s, myFileBgColorStr) != 0)) { myFileBgColorStr = UtilStrDup(attr_ptr->attr_value.s); if (myFileBgColorStr == NULL) FailAllocMessage(); if (SetFileBgColor()) { ClearAndRedrawDrawWindow(); } else { ClearBgColorInfo(TRUE); } } return; } else { changed = ClearBgColorInfo(FALSE); } /* * Can't really get this to work because of scrolling and zooming. */ /* if ((attr_ptr=FindFileAttrWithName("bg_gif=")) != NULL) { if (myFileBgGifURL == NULL || strcmp(attr_ptr->attr_value.s, myFileBgGifURL) != 0) { if (myFileBgPixmap != None) XFreePixmap(mainDisplay, myFileBgPixmap); myFileBgPixmap = None; myFileBgPixmapW = myFileBgPixmapH = (-1); if (myFileBgGifURL != NULL) free(myFileBgGifURL); myFileBgGifURL = UtilStrDup(attr_ptr->attr_value.s); if (myFileBgGifURL == NULL) FailAllocMessage(); if (SetFileBgPixmap()) { ClearAndRedrawDrawWindow(); } else { ClearBgPixmapInfo(TRUE); } } return; } else { if (!changed) { changed = ClearBgPixmapInfo(FALSE); } else { ClearBgPixmapInfo(FALSE); } } */ if (changed) { if (myFileBgPixmap == None) { XSetWindowBackground(mainDisplay, drawWindow, myBgPixel); } ClearAndRedrawDrawWindow(); } } int LoadFile(FullName, ObjFile, GzippedObjFile) char *FullName; int ObjFile; /* equals TRUE if the file is an OBJ file */ /* equals FALSE if the file is a SYM or PIN file */ /* equals -1 if the file is an temporary OBJ file */ { struct ObjRec *obj_ptr=NULL; char tmp_filename[MAXPATHLENGTH+1], tmp_filefullpath[MAXPATHLENGTH+1]; char file_name[MAXPATHLENGTH+1], saved_cur_dir[MAXPATHLENGTH+1], *rest=NULL; char gzipped_fname[MAXPATHLENGTH+1]; int read_status=0, short_name=FALSE, tmp_linenum=0, interrupted=FALSE; int done_clear_all_wb=FALSE; FILE *fp=NULL; XEvent ev; *gzipped_fname = '\0'; if (ObjFile != FALSE) { strcpy(saved_cur_dir, curDir); } else { strcpy(saved_cur_dir, curSymDir); } if (GzippedObjFile) { char *tmp_fname=NULL; if ((tmp_fname=GunzipFileIntoTemp(FullName)) == NULL) { return FALSE; } else { strcpy(gzipped_fname, FullName); strcpy(file_name, tmp_fname); free(tmp_fname); } } else { strcpy(file_name, FullName); } if (*gzipped_fname == '\0') { if ((short_name=IsPrefix(bootDir, file_name, &rest))) ++rest; } else { if ((short_name=IsPrefix(bootDir, gzipped_fname, &rest))) ++rest; } if ((fp=fopen(file_name, "r")) == NULL) { if (short_name) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), rest); } else { if (*gzipped_fname == '\0') { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), file_name); } else { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), gzipped_fname); } } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (*gzipped_fname != '\0') unlink(file_name); return FALSE; } if (!navigatingBackAndForth) BeforeNavigate(); ClearFileInfo(TRUE); if (usePaperSizeStoredInFile) ResetOnePageSize(); strcpy(tmp_filefullpath, scanFileFullPath); strcpy(tmp_filename, scanFileName); tmp_linenum = scanLineNum; UtilStrCpyN(scanFileFullPath, sizeof(scanFileFullPath), FullName); strcpy(scanFileName, (short_name ? rest : file_name)); scanLineNum = 0; TieLooseEnds(); CleanUpDrawingWindow(); SetFileModified(FALSE); XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, drawWindow, ExposureMask, &ev)) ; SaveStatusStrings(); if (short_name) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_LOADING_FILE), rest); } else { if (*gzipped_fname == '\0') { sprintf(gszMsgBox, TgLoadCachedString(CSTID_LOADING_FILE), file_name); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_LOADING_FILE), gzipped_fname); } } SetStringStatus(gszMsgBox); SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if (flushColormapOnOpen) { if (FlushColormap()) { Msg(TgLoadString(STID_COLORMAP_FLUSHED)); } } XClearWindow(mainDisplay, drawWindow); somethingHighLighted = FALSE; numRedrawBBox = 0; ShowInterrupt(1); interrupted = FALSE; readingPageNum = loadedCurPageNum = 0; foundGoodStateObject = FALSE; while ((read_status=ReadObj(fp, &obj_ptr)) == TRUE) { if (foundGoodStateObject && !done_clear_all_wb) { done_clear_all_wb = TRUE; if (gstWBInfo.do_whiteboard) { RecordWBClearAll(); } } if (obj_ptr != NULL) { obj_ptr->tmp_parent = NULL; AdjForOldVersion(obj_ptr); AddObj(NULL, topObj, obj_ptr); if (!interrupted && readingPageNum == loadedCurPageNum && (PointInBBox(obj_ptr->x, obj_ptr->y, drawWinBBox) || BBoxIntersect(obj_ptr->bbox, drawWinBBox))) { if (!DrawObj(drawWindow, obj_ptr)) interrupted = TRUE; if (CheckInterrupt(TRUE)) interrupted = TRUE; } } } fclose(fp); if (*gzipped_fname != '\0') unlink(file_name); if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } if (interrupted) { MsgBox(TgLoadString(STID_USER_INTR_ABORT_DRAW), TOOL_NAME, INFO_MB); } HideInterrupt(); strcpy(scanFileFullPath, tmp_filefullpath); strcpy(scanFileName, tmp_filename); scanLineNum = tmp_linenum; if (read_status == INVALID) { if (fileVersion > CUR_VERSION) { sprintf(gszMsgBox, TgLoadString(STID_FILE_VER_ABORT_OPEN), fileVersion, TOOL_NAME, homePageURL); } else { sprintf(gszMsgBox, TgLoadString(STID_FILE_CORRUPTED_ABORT_OPEN)); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); DrawPaperBoundary(drawWindow); RedrawGridLines(drawWindow); SetDefaultCursor(mainWindow); ShowCursor(); RestoreStatusStrings(); return FALSE; } if (ObjFile == TRUE) { if (*gzipped_fname == '\0') { SetCurDir(file_name); } else { SetCurDir(gzipped_fname); } *curSymDir = '\0'; } else if (ObjFile == FALSE) { SetCurSymDir(file_name); } curFileDefined = TRUE; if (loadedCurPageNum > 0 && curPage != NULL) { GotoPageNum(loadedCurPageNum); } CheckFileAttrsInLoad(); if (loadedCurPageNum <= 0 || curPage == NULL) { DelAllPages(); loadedCurPageNum = curPageNum = lastPageNum = 1; InitPage(); DrawPaperBoundary(drawWindow); RedrawGridLines(drawWindow); RedrawPageLines(drawWindow); RedrawChoiceWindow(); } if (ObjFile != FALSE) { if (strcmp(saved_cur_dir, curDir) != 0 && DirInSymPath(".")) { UpdateSymInfo(); } } else { if (strcmp(saved_cur_dir, curSymDir) != 0 && DirInSymPath(".")) { UpdateSymInfo(); } } if (short_name) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CUR_FILE_IS), rest); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CUR_FILE_IS), (*gzipped_fname == '\0' ? file_name : gzipped_fname)); } Msg(gszMsgBox); RestoreStatusStrings(); RedrawTitleWindow(); justDupped = FALSE; SetDefaultCursor(mainWindow); RedrawHRulerWindow(); ShowCursor(); if (!gstWBInfo.do_whiteboard) { CleanUpCmds(); } UpdateAllPinnedMenus(); if (!navigatingBackAndForth && !PRTGIF) CommitNavigate(); return foundGoodStateObject; } void DumpPatFill(FP, Fill, BBox, Indent, EndOfLine) FILE *FP; int Fill, Indent, EndOfLine; struct BBRec BBox; { int ltx=0, lty=0, rbx=0, rby=0, cellw=0, cellh=0; struct BBRec bbox; GetPatternCellsize(Fill, &cellw, &cellh); if ((cellw&0x7) != 0) { sprintf(gszMsgBox, "cellw = %1d in DumpPatFill()\n", cellw); TgAssert(FALSE, gszMsgBox, NULL); } /* if ((cellw % 8) != 0) cellw += (8-(cellw%8)); */ bbox.ltx = BBox.ltx-1; bbox.lty = BBox.lty-1; bbox.rbx = BBox.rbx+1; bbox.rby = BBox.rby+1; ltx = ((bbox.ltx % cellw) == 0) ? bbox.ltx : ((bbox.ltx > 0) ? ((int)(bbox.ltx / cellw))*cellw : ((int)(bbox.ltx / cellw)-1)*cellw); lty = ((bbox.lty % cellh) == 0) ? bbox.lty : ((bbox.lty > 0) ? ((int)(bbox.lty / cellh))*cellh : ((int)(bbox.lty / cellh)-1)*cellh); rbx = ((bbox.rbx % cellw) == 0) ? bbox.rbx : ((bbox.rbx > 0) ? ((int)(bbox.rbx / cellw)+1)*cellw : ((int)(bbox.rbx / cellw))*cellw); rby = ((bbox.rby % cellh) == 0) ? bbox.rby : ((bbox.rby > 0) ? ((int)(bbox.rby / cellh)+1)*cellh : ((int)(bbox.rby / cellh))*cellh); if (fprintf(FP, "%spat%1d %1d %1d %1d %1d %1d %1d TGPF%s", GetIndentString(Indent), Fill, cellw, cellh, ltx, lty, rbx-ltx, rby-lty, (EndOfLine?"\n":"")) == EOF) { writeFileFailed = TRUE; } } void DumpSymOutline(FP, ObjPtr) FILE *FP; register struct ObjRec *ObjPtr; { int ltx, lty, rbx, rby; ltx = ObjPtr->obbox.ltx - QUARTER_INCH + 1; lty = ObjPtr->obbox.lty - QUARTER_INCH + 1; rbx = ObjPtr->obbox.rbx + QUARTER_INCH - 1; rby = ObjPtr->obbox.rby + QUARTER_INCH - 1; fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); fprintf(FP, " 0 %s\n", gPsCmd[PS_SETGRAY]); fprintf(FP, " [4 4] 0 %s\n", gPsCmd[PS_SETDASH]); fprintf(FP, " %s\n %1d %1d %s ", gPsCmd[PS_NEWPATH], ltx, lty, gPsCmd[PS_MOVETO]); fprintf(FP, "%1d %1d %s ", rbx, lty, gPsCmd[PS_LINETO]); fprintf(FP, "%1d %1d %s ", rbx, rby, gPsCmd[PS_LINETO]); fprintf(FP, "%1d %1d %s\n", ltx, rby, gPsCmd[PS_LINETO]); fprintf(FP, " %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_STROKE]); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); } static int printingFirstPageNum=1; static int printingPageNum=1, printingPageRow=1, printingPageCol=1; static int printingLastPageNum=0; static int dumpOnePageInTileMode=FALSE; static int dumpOnePageInStackMode=FALSE; static int dumpPages=FALSE; static int dumpPageNum=0; static FILE *dumpFP=NULL; static char tmpFile[MAXSTRING+1]; static int llxTotal=0, llyTotal=0, urxTotal=0, uryTotal=0; static int totalBBoxValid=FALSE; static int msgAboutTiledPageScalingSeen=FALSE; static void DumpAttrs(FP, AttrPtr) FILE *FP; register struct AttrRec *AttrPtr; { for ( ; AttrPtr != NULL; AttrPtr=AttrPtr->prev) { if (!AttrPtr->shown) { continue; } /* do not translate -- program constants */ if (!AttrPtr->nameshown && *AttrPtr->attr_name.s == '!' && strcmp(AttrPtr->attr_name.s, "!PAGE_NUM=") == 0) { if (pageLayoutMode == PAGE_STACK) { MiniLineInfo *pMiniLine=AttrPtr->obj->detail.t->minilines.first; char *c_ptr; if (pMiniLine != NULL && pMiniLine->first_block == pMiniLine->last_block && (strstr(pMiniLine->first_block->seg->dyn_str.s, "!(STACKED_PAGE_NUM)") != NULL || strstr(pMiniLine->first_block->seg->dyn_str.s, "!(STACKED_NUM_PAGES)") != NULL)) { char *psz_saved=NULL, *c_ptr1=NULL; int page_num_str_len=strlen("!(STACKED_PAGE_NUM)"); int num_pages_str_len=strlen("!(STACKED_NUM_PAGES)"); psz_saved = UtilStrDup(pMiniLine->first_block->seg->dyn_str.s); if (psz_saved == NULL) FailAllocMessage(); while ((c_ptr=strstr(pMiniLine->first_block->seg->dyn_str.s, "!(STACKED_PAGE_NUM)")) != NULL) { c_ptr1 = &c_ptr[page_num_str_len]; sprintf(c_ptr, "%1d", printingPageNum); c_ptr = &c_ptr[strlen(c_ptr)]; while (*c_ptr1 != '\0') *c_ptr++ = *c_ptr1++; *c_ptr = '\0'; } while ((c_ptr=strstr(pMiniLine->first_block->seg->dyn_str.s, "!(STACKED_NUM_PAGES)")) != NULL) { c_ptr1 = &c_ptr[num_pages_str_len]; sprintf(c_ptr, "%1d", lastPageNum); c_ptr = &c_ptr[strlen(c_ptr)]; while (*c_ptr1 != '\0') *c_ptr++ = *c_ptr1++; *c_ptr = '\0'; } DumpTextObj(FP, AttrPtr->obj); DynStrSet(&pMiniLine->first_block->seg->dyn_str, psz_saved); UtilFree(psz_saved); } else { DumpTextObj(FP, AttrPtr->obj); } } else { /* pageLayoutMode == PAGE_TILE */ MiniLineInfo *pMiniLine=AttrPtr->obj->detail.t->minilines.first; char *c_ptr=NULL; if (pMiniLine != NULL) { char *psz_saved=NULL, *c_ptr1=NULL, *c_ptr2=NULL; psz_saved = UtilStrDup(pMiniLine->first_block->seg->dyn_str.s); if (psz_saved == NULL) FailAllocMessage(); for (c_ptr=pMiniLine->first_block->seg->dyn_str.s; *c_ptr != '\0'; c_ptr++) { int len=strlen("!(TILED_PAGE_ROW)"); if (*c_ptr == '!' && (strncmp(c_ptr, "!(TILED_PAGE_ROW)", len) == 0 || strncmp(c_ptr, "!(TILED_PAGE_COL)", len) == 0)) { if (strncmp(c_ptr, "!(TILED_PAGE_ROW)", len) == 0) { sprintf(c_ptr, "%1d", printingPageRow); } else { sprintf(c_ptr, "%1d", printingPageCol); } c_ptr1 = &c_ptr[len]; c_ptr = c_ptr2 = &c_ptr[strlen(c_ptr)]; while (*c_ptr1 != '\0') *c_ptr2++ = *c_ptr1++; *c_ptr2 = '\0'; c_ptr--; } } DumpTextObj(FP, AttrPtr->obj); DynStrSet(&pMiniLine->first_block->seg->dyn_str, psz_saved); UtilFree(psz_saved); } else { DumpTextObj(FP, AttrPtr->obj); } } } else { DumpTextObj(FP, AttrPtr->obj); } } } static void DumpAnObj(FP, ObjPtr) FILE *FP; register struct ObjRec *ObjPtr; { switch (ObjPtr->type) { case OBJ_POLY: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DumpPolyObj(FP, ObjPtr); DumpAttrs(FP, ObjPtr->lattr); } break; case OBJ_BOX: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DumpBoxObj(FP, ObjPtr); DumpAttrs(FP, ObjPtr->lattr); } break; case OBJ_OVAL: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DumpOvalObj(FP, ObjPtr); DumpAttrs(FP, ObjPtr->lattr); } break; case OBJ_TEXT: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DumpTextObj(FP, ObjPtr); } break; case OBJ_POLYGON: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DumpPolygonObj(FP, ObjPtr); DumpAttrs(FP, ObjPtr->lattr); } break; case OBJ_ARC: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DumpArcObj(FP, ObjPtr); DumpAttrs(FP, ObjPtr->lattr); } break; case OBJ_RCBOX: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DumpRCBoxObj(FP, ObjPtr); DumpAttrs(FP, ObjPtr->lattr); } break; case OBJ_XBM: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DumpXBmObj(FP, ObjPtr); DumpAttrs(FP, ObjPtr->lattr); } break; case OBJ_XPM: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DumpXPmObj(FP, ObjPtr); DumpAttrs(FP, ObjPtr->lattr); } break; case OBJ_SYM: case OBJ_ICON: case OBJ_GROUP: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { struct ObjRec *obj_ptr=ObjPtr->detail.r->last; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = ObjPtr; DumpAnObj(FP, obj_ptr); } DumpAttrs(FP, ObjPtr->lattr); if (ObjPtr->type == OBJ_SYM) DumpSymOutline(FP, ObjPtr); } break; case OBJ_PIN: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { struct ObjRec *obj_ptr=GetPinObj(ObjPtr); obj_ptr->tmp_parent = ObjPtr; DumpAnObj(FP, obj_ptr); DumpAttrs(FP, ObjPtr->lattr); } break; } } static int llxPage=0, llyPage=0, urxPage=0, uryPage=0; static int minimalEPS=INVALID; #define ALL_BBOX 0 #define PAGE_BBOX 1 int DumpBBox(fp, page_only, page_bbox) FILE *fp; int page_only; struct BBRec *page_bbox; { struct ObjRec *obj_ptr=NULL; int ltx=0, lty=0, rbx=0, rby=0, rc=TRUE; double llx1=0, lly1=0, urx1=0, ury1=0; if ((obj_ptr = topObj) == NULL) { ltx = lty = rbx = rby = 0; if (!(pageLayoutMode == PAGE_STACK && printingFirstPageNum != printingLastPageNum)) { strcpy(gszMsgBox, TgLoadString(STID_WARN_PS_BBOX_EMPTY)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } } rc = FALSE; } else if (pageLayoutMode == PAGE_STACK || page_bbox == NULL) { ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; for (obj_ptr=topObj->next; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (obj_ptr->bbox.ltx < ltx) ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < lty) lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > rbx) rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > rby) rby = obj_ptr->bbox.rby; } } else { int found=FALSE; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (Inside(obj_ptr->bbox, *page_bbox) || BBoxIntersect(obj_ptr->bbox, *page_bbox)) { if (found) { if (obj_ptr->bbox.ltx < ltx) ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < lty) lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > rbx) rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > rby) rby = obj_ptr->bbox.rby; } else { found = TRUE; ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; } } } if (!found) { rc = FALSE; ltx = lty = rbx = rby = 0; } else if (page_bbox != NULL) { struct BBRec bbox, bbox1; bbox.ltx = ltx; bbox.lty = lty; bbox.rbx = rbx; bbox.rby = rby; if (IntersectRect(bbox, *page_bbox, &bbox1)) { ltx = bbox1.ltx-page_bbox->ltx; lty = bbox1.lty-page_bbox->lty; rbx = bbox1.rbx-page_bbox->ltx; rby = bbox1.rby-page_bbox->lty; } } } switch (pageStyle) { case PORTRAIT: llx1 = (double)(1.0*ltx*psDotsPerInch/PIX_PER_INCH*printMag/100 + psXOff[pageStyle]*psDotsPerInch); lly1 = (double)(-1.0*rby*psDotsPerInch/PIX_PER_INCH*printMag/100 + psYOff[pageStyle]*psDotsPerInch); urx1 = (double)(1.0*rbx*psDotsPerInch/PIX_PER_INCH*printMag/100 + psXOff[pageStyle]*psDotsPerInch); ury1 = (double)(-1.0*lty*psDotsPerInch/PIX_PER_INCH*printMag/100 + psYOff[pageStyle]*psDotsPerInch); break; case LANDSCAPE: llx1 = (double)(1.0*lty*psDotsPerInch/PIX_PER_INCH*printMag/100 - psYOff[pageStyle]*psDotsPerInch); lly1 = (double)(1.0*ltx*psDotsPerInch/PIX_PER_INCH*printMag/100 + psXOff[pageStyle]*psDotsPerInch); urx1 = (double)(1.0*rby*psDotsPerInch/PIX_PER_INCH*printMag/100 - psYOff[pageStyle]*psDotsPerInch); ury1 = (double)(1.0*rbx*psDotsPerInch/PIX_PER_INCH*printMag/100 + psXOff[pageStyle]*psDotsPerInch); break; default: fprintf(stderr, TgLoadString(STID_UNRECOG_PAGE_STYLE), pageStyle); fprintf(stderr, "\n"); break; } if (rc) { llxPage = (llx1 >= 0.0) ? ((int)llx1)-1 : (-((int)(-llx1)))-1; llyPage = (lly1 >= 0.0) ? ((int)lly1)-1 : (-((int)(-lly1)))-1; urxPage = (urx1 >= 0.0) ? ((int)urx1)+1 : (-((int)(0.999-urx1)))+1; uryPage = (ury1 >= 0.0) ? ((int)ury1)+1 : (-((int)(0.999-ury1)))+1; } else { llxPage = llyPage = urxPage = uryPage = 0; } if (!page_only || !minimalEPS) { fprintf(fp,"%%%%%sBoundingBox: %1d %1d %1d %1d\n", (page_only ? "Page" : ""), llxPage, llyPage, urxPage, uryPage); } return rc; } void ModifyOutputFileName(FileName) char *FileName; { char *psz=NULL, s[MAXPATHLENGTH<<1]; if (*outputDir == '\0') return; strcpy(s, FileName); psz = UtilStrRChr(s, DIR_SEP); if (psz != NULL) { sprintf(FileName, "%s%c%s", outputDir, DIR_SEP, ++psz); } else { sprintf(FileName, "%s%c%s", outputDir, DIR_SEP, s); } } static void DumpTextObjInAscii(FP, ObjPtr) FILE *FP; register struct ObjRec *ObjPtr; { struct TextRec *text_ptr=ObjPtr->detail.t; MiniLinesInfo *minilines=(&text_ptr->minilines); if (text_ptr->pen == NONEPAT) return; DumpMiniLinesInAscii(FP, minilines, &totalBBoxValid); if (fprintf(FP, "\n") == EOF) writeFileFailed = TRUE; } static void DumpAttrsInAscii(FP, AttrPtr) FILE *FP; register struct AttrRec *AttrPtr; { for ( ; AttrPtr != NULL; AttrPtr=AttrPtr->prev) { if (!AttrPtr->shown) { continue; } /* do not translate -- program constants */ if (!AttrPtr->nameshown && *AttrPtr->attr_name.s == '!' && strcmp(AttrPtr->attr_name.s, "!PAGE_NUM=") == 0) { if (pageLayoutMode == PAGE_STACK) { MiniLineInfo *pMiniLine=AttrPtr->obj->detail.t->minilines.first; char *c_ptr; if (pMiniLine != NULL && pMiniLine->first_block == pMiniLine->last_block && (strstr(pMiniLine->first_block->seg->dyn_str.s, "!(STACKED_PAGE_NUM)") != NULL || strstr(pMiniLine->first_block->seg->dyn_str.s, "!(STACKED_NUM_PAGES)") != NULL)) { char *psz_saved=NULL, *c_ptr1; int page_num_str_len=strlen("!(STACKED_PAGE_NUM)"); int num_pages_str_len=strlen("!(STACKED_NUM_PAGES)"); psz_saved = UtilStrDup(pMiniLine->first_block->seg->dyn_str.s); if (psz_saved == NULL) FailAllocMessage(); while ((c_ptr=strstr(pMiniLine->first_block->seg->dyn_str.s, "!(STACKED_PAGE_NUM)")) != NULL) { c_ptr1 = &c_ptr[page_num_str_len]; sprintf(c_ptr, "%1d", printingPageNum); c_ptr = &c_ptr[strlen(c_ptr)]; while (*c_ptr1 != '\0') *c_ptr++ = *c_ptr1++; *c_ptr = '\0'; } while ((c_ptr=strstr(pMiniLine->first_block->seg->dyn_str.s, "!(STACKED_NUM_PAGES)")) != NULL) { c_ptr1 = &c_ptr[num_pages_str_len]; sprintf(c_ptr, "%1d", lastPageNum); c_ptr = &c_ptr[strlen(c_ptr)]; while (*c_ptr1 != '\0') *c_ptr++ = *c_ptr1++; *c_ptr = '\0'; } DumpTextObjInAscii(FP, AttrPtr->obj); DynStrSet(&pMiniLine->first_block->seg->dyn_str, psz_saved); UtilFree(psz_saved); } else { DumpTextObjInAscii(FP, AttrPtr->obj); } } else { MiniLineInfo *pMiniLine=AttrPtr->obj->detail.t->minilines.first; char *c_ptr; if (pMiniLine != NULL) { char *psz_saved, *c_ptr1, *c_ptr2; psz_saved = UtilStrDup(pMiniLine->first_block->seg->dyn_str.s); if (psz_saved == NULL) FailAllocMessage(); for (c_ptr=pMiniLine->first_block->seg->dyn_str.s; *c_ptr != '\0'; c_ptr++) { int len=strlen("!(TILED_PAGE_ROW)"); if (*c_ptr == '!' && (strncmp(c_ptr, "!(TILED_PAGE_ROW)", len) == 0 || strncmp(c_ptr, "!(TILED_PAGE_COL)", len) == 0)) { if (strncmp(c_ptr, "!(TILED_PAGE_ROW)", len) == 0) { sprintf(c_ptr, "%1d", printingPageRow); } else { sprintf(c_ptr, "%1d", printingPageCol); } c_ptr1 = &c_ptr[len]; c_ptr = c_ptr2 = &c_ptr[strlen(c_ptr)]; while (*c_ptr1 != '\0') *c_ptr2++ = *c_ptr1++; *c_ptr2 = '\0'; c_ptr--; } } DumpTextObjInAscii(FP, AttrPtr->obj); DynStrSet(&pMiniLine->first_block->seg->dyn_str, psz_saved); UtilFree(psz_saved); } else { DumpTextObjInAscii(FP, AttrPtr->obj); } } } else { DumpTextObjInAscii(FP, AttrPtr->obj); } } } static void DumpAnObjInAscii(FP, ObjPtr) FILE *FP; register struct ObjRec *ObjPtr; { switch (ObjPtr->type) { case OBJ_POLY: case OBJ_BOX: case OBJ_OVAL: case OBJ_POLYGON: case OBJ_ARC: case OBJ_RCBOX: case OBJ_XBM: case OBJ_XPM: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DumpAttrsInAscii(FP, ObjPtr->lattr); } break; case OBJ_TEXT: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DumpTextObjInAscii(FP, ObjPtr); } break; case OBJ_SYM: case OBJ_ICON: case OBJ_GROUP: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { struct ObjRec *obj_ptr=ObjPtr->detail.r->last; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = ObjPtr; DumpAnObjInAscii(FP, obj_ptr); } DumpAttrsInAscii(FP, ObjPtr->lattr); } break; case OBJ_PIN: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { struct ObjRec *obj_ptr=GetPinObj(ObjPtr); obj_ptr->tmp_parent = ObjPtr; DumpAnObjInAscii(FP, obj_ptr); DumpAttrsInAscii(FP, ObjPtr->lattr); } break; } } static int SetPortName(name, buf, buf_sz, pn_buf_index) char *name, *buf; int buf_sz, *pn_buf_index; { int len=strlen(name)+1, index=(*pn_buf_index); if (index+len+1 > buf_sz) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_PORTNAME_TOO_LONG_SKIPPED), buf); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return FALSE; } buf[index] = '!'; strcpy(&buf[index+1], name); (*pn_buf_index) = index+len; buf[(*pn_buf_index)] = '\0'; return TRUE; } static void DumpNetlListLine(FP, port_name, pMiniLine) FILE *FP; char *port_name; MiniLineInfo *pMiniLine; { int need_to_free_tmp_buf=FALSE; char *tmp_buf=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); char *c_ptr=strchr(tmp_buf, '='); if (fprintf(FP, "\"%s\",\t\"%s\"\n", port_name, ++c_ptr) == EOF) { writeFileFailed = TRUE; } if (need_to_free_tmp_buf) UtilFree(tmp_buf); } static void DumpNetListForAPort(FP, ObjPtr, buf, buf_sz, pn_buf_index) FILE *FP; struct ObjRec *ObjPtr; char *buf; int buf_sz, *pn_buf_index; { struct AttrRec *attr_ptr=FindObjAttrWithName(ObjPtr, "name="); int ok=TRUE; if (attr_ptr != NULL) { if (BlankStr(attr_ptr->attr_value.s)) { /* do not translate -- program constants */ ok = SetPortName("(unknown)", buf, buf_sz, pn_buf_index); } else { ok = SetPortName(attr_ptr->attr_value.s, buf, buf_sz, pn_buf_index); } } if (ok) { attr_ptr = FindAttrWithName(ObjPtr, "signal_name=", NULL); DumpNetlListLine(FP, buf, attr_ptr->obj->detail.t->minilines.first); } } static void DoDumpNetListForAnObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { struct ObjRec *obj_ptr=NULL; struct AttrRec *attr_ptr=NULL; char port_name[MAXSTRING]; switch (ObjPtr->type) { case OBJ_SYM: case OBJ_ICON: if ((attr_ptr=FindObjAttrWithName(ObjPtr, "name=")) != NULL) { int index=0, ok=TRUE; if (BlankStr(attr_ptr->attr_value.s)) { /* do not translate -- program constants */ ok = SetPortName("(unknown)", port_name, sizeof(port_name), &index); } else { ok = SetPortName(attr_ptr->attr_value.s, port_name, sizeof(port_name), &index); } if (ok) { if (ObjIsAPort(ObjPtr)) { attr_ptr = FindAttrWithName(ObjPtr, "signal_name=", NULL); DumpNetlListLine(FP, port_name, attr_ptr->obj->detail.t->minilines.first); } else { for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = ObjPtr; if (obj_ptr->type != OBJ_TEXT && ObjIsAPort(obj_ptr)) { int saved_index=index; port_name[saved_index] = '\0'; DumpNetListForAPort(FP, obj_ptr, port_name, sizeof(port_name), &index); index = saved_index; } } } } } break; case OBJ_GROUP: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = ObjPtr; DoDumpNetListForAnObj(FP, obj_ptr); } break; case OBJ_PIN: obj_ptr = GetPinObj(ObjPtr); if ((attr_ptr=FindObjAttrWithName(obj_ptr, "name=")) != NULL) { int index=0, ok=TRUE; if (BlankStr(attr_ptr->attr_value.s)) { /* do not translate -- program constants */ ok = SetPortName("(unknown)", port_name, sizeof(port_name), &index); } else { ok = SetPortName(attr_ptr->attr_value.s, port_name, sizeof(port_name), &index); } if (ok) { if (ObjIsAPort(obj_ptr)) { attr_ptr = FindAttrWithName(obj_ptr, "signal_name=", NULL); DumpNetlListLine(FP, port_name, attr_ptr->obj->detail.t->minilines.first); } } } break; } } static void DumpComponentAttrs(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { struct AttrRec *attr_ptr=NULL; for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (strcmp(attr_ptr->attr_name.s, "name=") != 0 && strcmp(attr_ptr->attr_name.s, "type=") != 0) { int need_to_free_tmp_buf=FALSE; char *tmp_buf; tmp_buf = ConvertAttrNameFirstMiniLineToString(attr_ptr, &need_to_free_tmp_buf); if (fprintf(FP, "\t%s\n", tmp_buf) == EOF) writeFileFailed = TRUE; if (need_to_free_tmp_buf) UtilFree(tmp_buf); } } } static void DoDumpComponentForAnObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { struct ObjRec *obj_ptr=NULL; struct AttrRec *attr_ptr=NULL; switch (ObjPtr->type) { case OBJ_SYM: case OBJ_ICON: if ((attr_ptr=FindObjAttrWithName(ObjPtr, "name=")) != NULL) { char *comp_name=NULL; if (BlankStr(attr_ptr->attr_value.s)) { /* do not translate -- program constants */ comp_name = "(unknown)"; } else { comp_name = attr_ptr->attr_value.s; } attr_ptr = FindAttrWithName(ObjPtr, "type=", NULL); if (attr_ptr != NULL) { char *comp_type=attr_ptr->attr_value.s; if (fprintf(FP, "%s: %s\n", comp_name, comp_type) == EOF) { writeFileFailed = TRUE; } DumpComponentAttrs(FP, ObjPtr); } } break; case OBJ_GROUP: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = ObjPtr; DoDumpComponentForAnObj(FP, obj_ptr); } break; case OBJ_PIN: obj_ptr = GetPinObj(ObjPtr); if ((attr_ptr=FindObjAttrWithName(obj_ptr, "name=")) != NULL) { char *comp_name=NULL; if (BlankStr(attr_ptr->attr_value.s)) { /* do not translate -- program constants */ comp_name = "(unknown)"; } else { comp_name = attr_ptr->attr_value.s; } attr_ptr = FindAttrWithName(obj_ptr, "type=", NULL); if (attr_ptr != NULL) { char *comp_type=attr_ptr->attr_value.s; if (fprintf(FP, "%s: %s\n", comp_name, comp_type) == EOF) { writeFileFailed = TRUE; } DumpComponentAttrs(FP, ObjPtr); } } break; } } static void DumpNetListForAnObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { connectingPortsFromInternalCommand = FALSE; if (preDumpSetup) { /* dumping components */ DoDumpComponentForAnObj(FP, ObjPtr); } else { /* dumping netlist */ DoDumpNetListForAnObj(FP, ObjPtr); } connectingPortsFromInternalCommand = TRUE; } #define WRITEBYTE(fp,byte) fputc((byte),(fp)) static void WriteWord(fp, word) FILE *fp; unsigned short word; { WRITEBYTE(fp, word&0xff); WRITEBYTE(fp, ((unsigned short)(word&0xff00))>>8); } static void WriteDoubleWord(fp, dword) FILE *fp; unsigned long dword; { WRITEBYTE(fp, dword&0xff); WRITEBYTE(fp, (dword&0xff00)>>8); WRITEBYTE(fp, (dword&0xff0000)>>16); WRITEBYTE(fp, (dword&0xff000000)>>24); } static char psBopHook[MAXSTRING], psEopHook[MAXSTRING]; static int psBopHookStatus=INVALID, psEopHookStatus=INVALID; static int noOrientationIfPdfSetPageDevice=INVALID; static int colorBgInPrintingColorPS=INVALID; static char xbmToTiffCmd[MAXSTRING+1]; static char psToPdfCmd[MAXSTRING+1]; static char epsToTmpSvgCmd[(MAXSTRING<<1)+1]; static char tmpSvgToSvgCmd[(MAXSTRING<<1)+1]; static char epsiExportExtension[MAXSTRING]; static int overrideEPSIExportExtension=INVALID; static char pdfExportExtension[MAXSTRING]; static char tmpSvgExportExtension[MAXSTRING]; static int numberFileInPrintOnePage=INVALID; static char defXbmToTiffCmd[]="xbmtopbm %s | pnmtotiff -none > %s"; static char defPsToPdfCmd[]="ps2pdf \"%s\" \"%s\""; static char defEpsToTmpSvgCmd[]="pstoedit -dt -f sk \"%s\" \"%s\""; static char defTmpSvgToSvgCmd[]="uniconvertor \"%s\" \"%s\""; /* * 1) pstoedit -dt -f sk FILE.eps FILE.sk * skconvert FILE.sk FILE.svg * * 2) pstoedit -dt -f sk FILE.eps FILE.sk * uniconvertor FILE.sk FILE.svg * * 3) pstoedit -dt -f ps2ai FILE.eps FILE.ai * uniconvertor FILE.ai FILE.svg */ void SetPsSetup(buf) char *buf; { gpszPsSetup = UtilStrDup(buf); if (gpszPsSetup == NULL) FailAllocMessage(); psSetupStatus = TRUE; } void SetBopHook(buf) char *buf; { UtilStrCpyN(psBopHook, sizeof(psBopHook), buf); psBopHookStatus = TRUE; } void SetEopHook(buf) char *buf; { UtilStrCpyN(psEopHook, sizeof(psEopHook), buf); psEopHookStatus = TRUE; } static void CleanUpDumpInitDefaults() { *psBopHook = *psEopHook = '\0'; psBopHookStatus = psEopHookStatus = INVALID; minimalEPS = INVALID; noOrientationIfPdfSetPageDevice = INVALID; colorBgInPrintingColorPS = INVALID; *xbmToTiffCmd = '\0'; *psToPdfCmd = '\0'; *epsToTmpSvgCmd = '\0'; *tmpSvgToSvgCmd = '\0'; *epsiExportExtension = '\0'; *pdfExportExtension = '\0'; *tmpSvgExportExtension = '\0'; overrideEPSIExportExtension = INVALID; numberFileInPrintOnePage = INVALID; } int GetCmdUsingDefAndXDef(buf, buf_sz, def_cmd, option, verify_count, msg_box_if_error) char *buf, *def_cmd, *option; int buf_sz, verify_count, msg_box_if_error; { char *c_ptr=NULL; UtilStrCpyN(buf, buf_sz, def_cmd); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,option)) != NULL) { UtilStrCpyN(buf, buf_sz, c_ptr); if (verify_count > 0) { int count=0; for (c_ptr=strstr(buf,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != verify_count) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, option, buf, def_cmd); fprintf(stderr, "%s\n", gszMsgBox); if (!PRTGIF && msg_box_if_error) { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } UtilStrCpyN(buf, buf_sz, def_cmd); return FALSE; } } } } return TRUE; } static void GenDumpInitDefaults() { static int init_other_xdefs=FALSE; char *c_ptr; if (minimalEPS == INVALID) { minimalEPS = !usePsAdobeString; #ifdef _MINIMAL_EPS minimalEPS = (_MINIMAL_EPS != 0); #endif /* _MINIMAL_EPS */ if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MinimalEPS")) != NULL) { minimalEPS = (UtilStrICmp(c_ptr, "true") == 0); } } } if (noOrientationIfPdfSetPageDevice == INVALID) { noOrientationIfPdfSetPageDevice = FALSE; if (!PRTGIF) { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "NoOrientationIfPdfSetPageDevice")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { noOrientationIfPdfSetPageDevice = TRUE; } } } if (colorBgInPrintingColorPS == INVALID) { colorBgInPrintingColorPS = FALSE; if (!PRTGIF) { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ColorBgInPrintingColorPS")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { colorBgInPrintingColorPS = TRUE; } } } if (psBopHookStatus == INVALID) { *psBopHook = '\0'; if (!PRTGIF) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PSBopHook")) != NULL) { UtilStrCpyN(psBopHook, sizeof(psBopHook), c_ptr); psBopHookStatus = TRUE; } else { psBopHookStatus = FALSE; } } } if (psEopHookStatus == INVALID) { *psEopHook = '\0'; if (!PRTGIF) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PSEopHook")) != NULL) { UtilStrCpyN(psEopHook, sizeof(psEopHook), c_ptr); psEopHookStatus = TRUE; } else { psEopHookStatus = FALSE; } } } if (psSetupStatus == INVALID) { psSetupStatus = TRUE; if (gpszPsSetup == NULL && (!PRTGIF || cmdLineOpenDisplay) && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "AdditionalPSSetup")) != NULL) { SetPsSetup(c_ptr); } } if (psDistillerNoImageCompress == INVALID) { psDistillerNoImageCompress = FALSE; if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "PSDistillerNoImageCompress")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { psDistillerNoImageCompress = TRUE; } } } if (!init_other_xdefs) { init_other_xdefs = TRUE; if (PRTGIF) { generateTiffEPSI = cmdLineTiffEPSI; strcpy(xbmToTiffCmd, defXbmToTiffCmd); } else { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "TiffEPSI")) != NULL) { if (UtilStrICmp(c_ptr, "true") == 0) { fprintf(stderr, TgLoadString(STID_TIFFEPSI_DIRECTLY_SUPPORTED), TOOL_NAME, "TiffEPSI", TOOL_NAME); fprintf(stderr, "\n"); } } if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "XbmToTiff")) != NULL) { int count=0; UtilStrCpyN(xbmToTiffCmd, sizeof(xbmToTiffCmd), c_ptr); for (c_ptr=strstr(xbmToTiffCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1 && count != 2) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "XbmToTiff", xbmToTiffCmd, defXbmToTiffCmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(xbmToTiffCmd, defXbmToTiffCmd); } } else { strcpy(xbmToTiffCmd, defXbmToTiffCmd); } } strcpy(pdfExportExtension, "pdf"); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PdfFileExtension")) != NULL) { UtilStrCpyN(pdfExportExtension, sizeof(pdfExportExtension), c_ptr); UtilTrimBlanks(pdfExportExtension); if (*pdfExportExtension == '\0') { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PdfFileExtension", pdfExportExtension, "pdf"); fprintf(stderr, "\n"); strcpy(pdfExportExtension, "pdf"); } } } strcpy(tmpSvgExportExtension, "sk"); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"TmpSvgFileExtension")) != NULL) { UtilStrCpyN(tmpSvgExportExtension, sizeof(tmpSvgExportExtension), c_ptr); UtilTrimBlanks(tmpSvgExportExtension); if (*tmpSvgExportExtension == '\0') { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "TmpSvgFileExtension", tmpSvgExportExtension, "sk"); fprintf(stderr, "\n"); strcpy(tmpSvgExportExtension, "sk"); } } } if (!GetCmdUsingDefAndXDef(psToPdfCmd, sizeof(psToPdfCmd), defPsToPdfCmd, "PsToPdf", 2, TRUE)) { } if (!GetCmdUsingDefAndXDef(epsToTmpSvgCmd, sizeof(epsToTmpSvgCmd), defEpsToTmpSvgCmd, "EpsToTmpSvg", 2, TRUE)) { } if (!GetCmdUsingDefAndXDef(tmpSvgToSvgCmd, sizeof(tmpSvgToSvgCmd), defTmpSvgToSvgCmd, "TmpSvgToSvg", 2, TRUE)) { } strcpy(gszProducedBy, TgLoadCachedString(CSTID_PARANED_UNKNOWN)); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ProducedBy")) != NULL) { UtilStrCpyN(gszProducedBy, sizeof(gszProducedBy), c_ptr); } } else if (*cmdLineProducedBy != '\0') { UtilStrCpyN(gszProducedBy, sizeof(gszProducedBy), cmdLineProducedBy); } pdfSetPageDevice = INVALID; if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "PdfSetPageDevice")) != NULL) { if (UtilStrICmp(c_ptr, "true") == 0) { pdfSetPageDevice = TRUE; } else if (UtilStrICmp(c_ptr, "false") == 0) { pdfSetPageDevice = FALSE; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_IGNORED), TOOL_NAME, "PdfSetPageDevice", c_ptr); fprintf(stderr, "\n"); } } else if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "LandscapePdfSetPageDevice")) != NULL) { if (UtilStrICmp(c_ptr, "true") == 0) { fprintf(stderr, TgLoadString(STID_OBSOLETE_XDEF_REPLACED), TOOL_NAME, "LandscapePdfSetPageDevice", TOOL_NAME, "PdfSetPageDevice", "true"); fprintf(stderr, "\n"); pdfSetPageDevice = TRUE; } else if (UtilStrICmp(c_ptr, "false") == 0) { fprintf(stderr, TgLoadString(STID_OBSOLETE_XDEF_REPLACED), TOOL_NAME, "LandscapePdfSetPageDevice", TOOL_NAME, "PdfSetPageDevice", "false"); fprintf(stderr, "\n"); pdfSetPageDevice = FALSE; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_IGNORED), TOOL_NAME, "LandscapePdfSetPageDevice"); fprintf(stderr, "\n"); } } } } if (overrideEPSIExportExtension == INVALID) { *epsiExportExtension = '\0'; overrideEPSIExportExtension = FALSE; if (!PRTGIF) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"EPSIExportExtension")) != NULL) { UtilStrCpyN(epsiExportExtension, sizeof(epsiExportExtension), c_ptr); if (strchr(epsiExportExtension, '.') != NULL || strchr(epsiExportExtension, ' ') != NULL) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF), TOOL_NAME, "EPSIExportExtension", epsiExportExtension); fprintf(stderr, "\n"); *epsiExportExtension = '\0'; } } } } if (numberFileInPrintOnePage == INVALID) { numberFileInPrintOnePage = FALSE; if (PRTGIF) { if (cmdLineOneFilePerPage) numberFileInPrintOnePage = TRUE; } else { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "NumberFileInPrintOnePage")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { numberFileInPrintOnePage = TRUE; } } } if (dontUseShortHandPS == INVALID) { dontUseShortHandPS = FALSE; if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DontUseShortHandPS")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { dontUseShortHandPS = TRUE; } } } if (dontCondense == INVALID) { dontCondense = TRUE; if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DontCondensePSFile")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { dontCondense = FALSE; } } } if (stripSimpleComments == INVALID) { stripSimpleComments = FALSE; if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "StripCondensedPSComments")) != NULL && UtilStrICmp(c_ptr, "false") != 0) { static int shown_once=FALSE; if (!shown_once) { sprintf(gszMsgBox, TgLoadString(STID_NAMED_XDEF_IS_OBSOLETE), TOOL_NAME, "StripCondensedPSComments"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); shown_once = TRUE; } } } } if (psRegMarksInTiledPageMode == INVALID) { psRegMarksInTiledPageMode = FALSE; psRegMarksGray = 0.95; if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "PsRegMarksInTiledPageMode")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { psRegMarksInTiledPageMode = TRUE; } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PsRegMarksGray")) != NULL) { psRegMarksGray = (float)atof(c_ptr); if (psRegMarksGray < 0.0 || psRegMarksGray > 1.0) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PsRegMarksGray", c_ptr, "0.95"); psRegMarksGray = 0.95; } } } } } static void GenTiffFile(tmp_fname, epsi_fname, condense, condensed_already) char *tmp_fname, *epsi_fname; int condense, condensed_already; { register int i; char tiff_fname[MAXPATHLENGTH+1], xbm_fname[MAXPATHLENGTH+1]; char cmd[MAXPATHLENGTH+1], buf[1024], *c_ptr=NULL; int bytes_read=0, count=0, tiff_fd=(-1), epsi_fd=(-1); FILE *tmp_fp=NULL, *epsi_fp=NULL, *pfp=NULL; long tmp_bytes=0L, tiff_bytes=0L; struct stat stat_buf; strcpy(buf, curFileName); GetRealBaseName(buf); sprintf(xbm_fname, "%s%c%s", curDir, DIR_SEP, buf); i = strlen(xbm_fname); sprintf(&xbm_fname[i], ".%s", XBM_FILE_EXT); ModifyOutputFileName(xbm_fname); sprintf(tiff_fname, "%s%c%s", curDir, DIR_SEP, buf); i = strlen(tiff_fname); sprintf(&tiff_fname[i], ".tif"); ModifyOutputFileName(tiff_fname); count = 0; for (c_ptr=strstr(xbmToTiffCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count == 1) { sprintf(cmd, xbmToTiffCmd, xbm_fname); } else { sprintf(cmd, xbmToTiffCmd, xbm_fname, tiff_fname); } unlink(tiff_fname); if (!FindProgramInPath(cmd, NULL, FALSE)) { return; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), cmd); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pfp=(FILE*)popen(cmd, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_EXEC_PROG_EPSI_NOT_GEN), cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } while (fgets(buf, sizeof(buf), pfp) != NULL) { Msg(buf); } pclose(pfp); SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); if (stat(tmp_fname, &stat_buf) != 0) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_GET_FINFO_EPSI_NOT_GEN), tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } tmp_bytes = (long)stat_buf.st_size; if (stat(tiff_fname, &stat_buf) != 0) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_GET_FINFO_EPSI_NOT_GEN), tiff_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } tiff_bytes = (long)stat_buf.st_size; if ((tmp_fp=fopen(tmp_fname, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if ((tiff_fd=open(tiff_fname, O_RDONLY)) == (-1)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), tiff_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); fclose(tmp_fp); return; } if (PRTGIF && cmdLineStdOut) { epsi_fp = stdout; } else if ((epsi_fp=fopen(epsi_fname, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), tiff_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); fclose(tmp_fp); close(tiff_fd); unlink(tiff_fname); return; } WRITEBYTE(epsi_fp, 0xc5); WRITEBYTE(epsi_fp, 0xd0); WRITEBYTE(epsi_fp, 0xd3); WRITEBYTE(epsi_fp, 0xc6); WriteDoubleWord(epsi_fp, 0x0000001e); WriteDoubleWord(epsi_fp, tmp_bytes); WriteDoubleWord(epsi_fp, 0L); WriteDoubleWord(epsi_fp, 0L); WriteDoubleWord(epsi_fp, tmp_bytes+0x1e); WriteDoubleWord(epsi_fp, tiff_bytes); WriteWord(epsi_fp, 0xffff); if (!writeFileFailed) { CondenseAndCopyPostScriptFile(tmp_fp, epsi_fp, tmp_fname, (!condensed_already && condense && !dontCondense)); } fclose(tmp_fp); if (!(PRTGIF && cmdLineStdOut)) fclose(epsi_fp); if (writeFileFailed) { writeFileFailed = FALSE; if (PRTGIF && cmdLineStdOut) { fprintf(stderr, "%s\n", TgLoadString(STID_FAIL_TO_WRITE_TO_STDOUT)); } else { FailToWriteFileMessage(epsi_fname); } close(tiff_fd); unlink(tiff_fname); return; } if (PRTGIF && cmdLineStdOut) { epsi_fd = 1; } else if ((epsi_fd=open(epsi_fname, O_WRONLY|O_APPEND, S_IRUSR|S_IWUSR)) == (-1)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_APPEND), epsi_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); close(tiff_fd); unlink(tiff_fname); return; } while ((bytes_read=read(tiff_fd, buf, sizeof(buf))) > 0) { if (write(epsi_fd, buf, bytes_read) <= 0) { writeFileFailed = TRUE; break; } } if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(epsi_fname); } if (!(PRTGIF && cmdLineStdOut)) close(epsi_fd); close(tiff_fd); unlink(tiff_fname); } static int psA4PaperSize=FALSE; static void InitNeedA4() { static int nInitialized=FALSE; if (nInitialized) return; nInitialized = TRUE; if (cmdLineA4) { psA4PaperSize = TRUE; } else if (!PRTGIF) { char *c_ptr; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PSA4PaperSize")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { psA4PaperSize = TRUE; } } } static int NeedA4() { int width_to_match, height_to_match; InitNeedA4(); if (!psA4PaperSize) return FALSE; width_to_match = (int)(825.0*PIX_PER_INCH/printMag); height_to_match = (int)(117.0*PIX_PER_INCH*10.0/printMag); if (onePageWidth == width_to_match && onePageHeight == height_to_match) { return TRUE; } width_to_match = (int)(21000.0*PIX_PER_MM/printMag); height_to_match = (int)(29700.0*PIX_PER_MM/printMag); return (onePageWidth == width_to_match && onePageHeight == height_to_match); } void SetOutputFileName(ps_file, file_ext, pn_short_name, ppsz_rest) char *ps_file, *file_ext, **ppsz_rest; int *pn_short_name; { if (PRTGIF) { char *psz_file=(*ppsz_rest); if (cmdLineOneFilePerPage) { if (curPage != NULL && curPage->page_file_name != NULL && *curPage->page_file_name != '\0') { sprintf(ps_file, "%s.%s", curPage->page_file_name, file_ext); } else { sprintf(ps_file, "%s-%1d.%s", psz_file, cmdLinePageNum, file_ext); } } else { sprintf(ps_file, "%s.%s", psz_file, file_ext); } } else { int len=0, use_page_num=FALSE; char *psz=NULL; if (dumpOneFilePerPage || (dumpOnePageInStackMode && numberFileInPrintOnePage)) { if (curPage != NULL && curPage->page_file_name != NULL && *curPage->page_file_name != '\0') { sprintf(ps_file, "%s%c%s.", curDir, DIR_SEP, curPage->page_file_name); } else { sprintf(ps_file, "%s%c%s", curDir, DIR_SEP, curFileName); use_page_num = TRUE; } } else { sprintf(ps_file, "%s%c%s", curDir, DIR_SEP, curFileName); } len = strlen(ps_file); if (len > 3 && strcmp(&ps_file[len-3], ".gz") == 0) { ps_file[len-3] = '\0'; len -= 3; } if ((psz=UtilStrRChr(ps_file, '.')) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_DOT_IN_SAVEFILE), "SetOutputFileName()"); TgAssert(FALSE, gszMsgBox, NULL); } if (use_page_num) { sprintf(psz, "-%1d.%s", curPageNum, file_ext); } else { sprintf(psz, ".%s", file_ext); } } ModifyOutputFileName(ps_file); if (!PRTGIF && pn_short_name != NULL && ppsz_rest != NULL) { if (((*pn_short_name)=IsPrefix(bootDir, ps_file, ppsz_rest))) { *ppsz_rest = (&(*ppsz_rest)[1]); } } } static void DumpRegMark(fp, pstem) FILE *fp; float *pstem; { float fval=(*pstem); fprintf(dumpFP, " %s ", gPsCmd[PS_GSAVE]); fprintf(dumpFP, "%.3f 0 %s ", -fval, gPsCmd[PS_RMOVETO]); fprintf(dumpFP, "2 %.3f %s 0 %s ", fval, gPsCmd[PS_MUL], gPsCmd[PS_RLINETO]); fprintf(dumpFP, "%s %s\n", gPsCmd[PS_STROKE], gPsCmd[PS_GRESTORE]); fprintf(dumpFP, " %s ", gPsCmd[PS_GSAVE]); fprintf(dumpFP, "0 %.3f %s ", -fval, gPsCmd[PS_RMOVETO]); fprintf(dumpFP, "0 2 %.3f %s %s ", fval, gPsCmd[PS_MUL], gPsCmd[PS_RLINETO]); fprintf(dumpFP, "%s %s\n", gPsCmd[PS_STROKE], gPsCmd[PS_GRESTORE]); } static int FixUpSVGLine(out_fp, dup_buf) FILE *out_fp; char *dup_buf; { char *psz=NULL, *psz_start=&dup_buf[5]; int found_xmlns=FALSE; while (psz_start != NULL) { char saved_ch='\0', key[MAXSTRING]; /* skip all the blank characters */ while (*psz_start == ' ' || *psz_start == '\t') psz_start++; *key = '\0'; for (psz=psz_start; *psz != '>'; psz++) { /* looking for key */ saved_ch = '\0'; if (*psz == ' ' || *psz == '\t' || *psz == '=' || *psz == '>') { saved_ch = *psz; *psz = '\0'; UtilStrCpyN(key, sizeof(key), psz_start); *psz = saved_ch; break; } } if (*key == '\0') { /* no key, this should not happen, may be malformed, give up */ break; } else if (saved_ch != '=') { /* saved_ch is either '\0' or a blank character, key with no value */ psz_start = ++psz; } else { int find_double_quote=FALSE; char value[MAXSTRING]; *value = '\0'; /* looking for value */ psz_start = ++psz; if (*psz_start == '"') { find_double_quote = TRUE; psz_start++; } if (find_double_quote) { for (psz=psz_start; *psz != '"' && *psz != '>'; psz++) ; if (*psz == '>') { /* may be malformed, give up */ break; } else if (*psz == '"') { saved_ch = *psz; *psz = '\0'; UtilStrCpyN(value, sizeof(value), psz_start); *psz = saved_ch; } } else { for (psz=psz_start; *psz != '>'; psz++) { saved_ch = '\0'; if (*psz == ' ' || *psz == '\t' || *psz == '>') { saved_ch = *psz; *psz = '\0'; UtilStrCpyN(value, sizeof(value), psz_start); *psz = saved_ch; break; } } if (*key == '\0') { /* no value, this should not happen, may be malformed, give up */ break; } } /* found both key and value */ if (UtilStrICmp(key, "xmlns") == 0) { found_xmlns = TRUE; break; } psz_start = ++psz; } } if (found_xmlns) { fprintf(out_fp, "%s\n", dup_buf); } else { int len=strlen(dup_buf); dup_buf[len-1] = '\0'; fprintf(out_fp, "%s xmlns=\"http://www.w3.org/2000/svg\">\n", dup_buf); dup_buf[len-1] = '>'; } return TRUE; } static int FixUpSVGFile(tmpsvg_fname, svg_fname) char *tmpsvg_fname, *svg_fname; { FILE *in_fp=fopen(tmpsvg_fname, "r"), *out_fp=NULL; char *buf=NULL; int line_num=0, fixed=FALSE; if (in_fp == NULL) { return FailToOpenMessage(tmpsvg_fname, "r", NULL); } out_fp = fopen(svg_fname, "w"); if (out_fp == NULL) { return FailToOpenMessage(tmpsvg_fname, "w", NULL); } while ((buf=UtilGetALine(in_fp)) != NULL) { line_num++; if (!fixed && buf[0] == '<') { if (UtilStrNCaseCmp(buf, "<svg ", 5) == 0) { int len=0; UtilTrimBlanks(buf); len = strlen(buf); if (len > 0 && buf[len-1] == '>') { char *dup_buf=UtilStrDup(buf); if (dup_buf == NULL) { FailAllocMessage(); UtilFree(buf); fclose(in_fp); fclose(out_fp); return FALSE; } if (FixUpSVGLine(out_fp, dup_buf)) { fixed = TRUE; } else { fprintf(out_fp, "%s\n", buf); } UtilFree(dup_buf); } else { fprintf(out_fp, "%s\n", buf); } } else { fprintf(out_fp, "%s\n", buf); } } else { fprintf(out_fp, "%s\n", buf); } UtilFree(buf); } fclose(in_fp); fclose(out_fp); return TRUE; } static int DoGenDump(FileName) char *FileName; { static char loc_time[MAXSTRING+1]; struct ObjRec *obj_ptr=NULL; char cmd[(MAXSTRING<<1)+1], tmp_str[MAXSTRING+1], ps_file[MAXSTRING+1]; char *rest=NULL, *file_ext=NULL, *output_type=NULL; int i, len, short_name=FALSE, export_cap=0; time_t tloc; if (!curDirIsLocal) { MsgBox(TgLoadString(STID_CANNOT_PRINT_REMOTE_FILE), TOOL_NAME, INFO_MB); return FALSE; } GenDumpInitDefaults(); if (botObj==NULL && ((pageLayoutMode==PAGE_STACK && dumpOnePageInStackMode) || pageLayoutMode==PAGE_TILE)) { int rc=FALSE; if (PRTGIF && cmdLineOneFilePerPage) { sprintf(gszMsgBox, TgLoadString(STID_NO_OBJ_TO_PRINT_ON_PAGE), cmdLinePageNum); rc = TRUE; } else if (!PRTGIF && dumpOneFilePerPage) { sprintf(gszMsgBox, TgLoadString(STID_NO_OBJ_TO_PRINT_ON_PAGE), curPageNum); rc = TRUE; } if (preDumpSetup && rc) { return rc; } if (rc) { if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } } else { strcpy(gszMsgBox, TgLoadString(STID_NO_OBJ_TO_PRINT)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } return rc; } if (whereToPrint != PRINTER) { if (!PRTGIF && !curFileDefined) { sprintf(gszMsgBox, TgLoadString(STID_NO_CUR_FILE_CANNOT_GEN_FORMAT), GetExportName(whereToPrint, EXPORT_THIS)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } } if (!PRTGIF && printingPageNum==printingFirstPageNum && !preDumpSetup) { Msg(TgLoadString(STID_GENERATING_PRINT_FILE_DOTS)); } if (whereToPrint >= MAXDEFWHERETOPRINT) { export_cap = GetExportFilterCapability(whereToPrint); } if (whereToPrint == XBM_FILE || whereToPrint == GIF_FILE || whereToPrint == HTML_FILE || whereToPrint == PNG_FILE || whereToPrint == JPEG_FILE || whereToPrint == PPM_FILE) { if (topObj == NULL) { sprintf(gszMsgBox, TgLoadString(STID_NO_OBJ_TO_EXPORT)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } else { int saved_colordump=colorDump, watch_cursor=watchCursorOnMainWindow; int dump_ppm_preferred=FALSE; if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } if (whereToPrint == GIF_FILE || whereToPrint == HTML_FILE || whereToPrint == PNG_FILE || whereToPrint == JPEG_FILE) { colorDump = TRUE; } dump_ppm_preferred = colorDump && fullTrueColorMode && (whereToPrint==GIF_FILE || whereToPrint==HTML_FILE || whereToPrint==PNG_FILE || whereToPrint==JPEG_FILE || whereToPrint==PPM_FILE || whereToPrint==XBM_FILE); DumpXBitmapFile(FALSE, dump_ppm_preferred, dumpOneFilePerPage || (dumpOnePageInStackMode && numberFileInPrintOnePage)); colorDump = saved_colordump; if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } } return TRUE; } /* * At this point, whereToPrint can only be PostScript, ASCII Text, NetList, * or external export type (if whereToPrint >= MAXDEFWHERETOPRINT). */ if (printingPageNum == printingFirstPageNum) { if (MkTempFile(tmpFile, sizeof(tmpFile), tmpDir, TOOL_NAME) == NULL) { return FALSE; } if ((dumpFP=fopen(tmpFile, "w")) == NULL) { sprintf(tmp_str, TgLoadString(STID_CANNOT_OPEN_FOR_WRITE_PRINT), tmpFile); if (PRTGIF) { fprintf(stderr, "%s\n", tmp_str); } else { MsgBox(tmp_str, TOOL_NAME, INFO_MB); } return FALSE; } if (PRTGIF && !cmdLineStdOut) { if (!cmdLineQuiet) { fprintf(stderr, TgLoadString(STID_WRITING_TO_DOTS), tmpFile); fprintf(stderr, "\n"); } } writeFileFailed = FALSE; ResetGrayDetection(); } if (whereToPrint < MAXDEFWHERETOPRINT && printingPageNum == printingFirstPageNum && whereToPrint != TEXT_FILE && whereToPrint != NETLIST_FILE) { PSUseShortHand(); if (dontUseShortHandPS) { PSDontUseShortHand(); } if (usePsAdobeString) { switch (whereToPrint) { case PRINTER: case PS_FILE: case PDF_FILE: if (*adobeString == '\0') { if (fprintf(dumpFP, "%%!PS-Adobe-2.0\n") == EOF) { writeFileFailed = TRUE; } } else if (fprintf(dumpFP,"%%!PS-Adobe-%s\n",adobeString) == EOF) { writeFileFailed = TRUE; } break; case LATEX_FIG: case EPSI_FILE: case SVG_FILE: if (*adobeString == '\0') { if (fprintf(dumpFP, "%%!PS-Adobe-2.0 EPSF-1.2\n") == EOF) { writeFileFailed = TRUE; } } else if (*epsfString == '\0') { if (fprintf(dumpFP, "%%!PS-Adobe-%s\n", adobeString) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(dumpFP, "%%!PS-Adobe-%s EPSF-%s\n", adobeString, epsfString) == EOF) { writeFileFailed = TRUE; } } break; } } else { if (preDumpSetup) PSUsePSAdobe(); if (fprintf(dumpFP, "%%!\n") == EOF) { writeFileFailed = TRUE; } } if (pageLayoutMode == PAGE_STACK && printingFirstPageNum == printingLastPageNum) { DumpBBox(dumpFP, ALL_BBOX, NULL); } else if (fprintf(dumpFP,"%%%%BoundingBox: (atend)\n") == EOF) { writeFileFailed = TRUE; } if (PRTGIF && !cmdLineOpenDisplay) { if (fprintf(dumpFP, "%%%%Title: %s\n", FileName) == EOF) { writeFileFailed = TRUE; } } else if (curFileDefined) { int gzipped=FALSE; strcpy(tmp_str, curFileName); if (FileNameHasExtension(tmp_str, OBJ_FILE_TYPE, &gzipped, NULL) && gzipped) { char *psz=UtilStrRChr(tmp_str, '.'); if (psz != NULL) *psz = '\0'; } len = strlen(tmp_str); for (i=len-1; tmp_str[i] != '.'; i--) ; tmp_str[i] = '\0'; if (fprintf(dumpFP, "%%%%Title: %s\n", tmp_str) == EOF) { writeFileFailed = TRUE; } } else if (fprintf(dumpFP, "%%%%Title: [Unnamed]\n") == EOF) { writeFileFailed = TRUE; } time(&tloc); strcpy(loc_time, ctime(&tloc)); loc_time[24] = '\0'; if (fprintf(dumpFP, "%%%%CreationDate: %s\n", loc_time) == EOF) { writeFileFailed = TRUE; } SetFullVersionString(); if (fprintf(dumpFP, "%%%%Creator: %s written by %s\n", fullToolName, "William Chia-Wei Cheng (bill.cheng@acm.org)") == EOF) { writeFileFailed = TRUE; } if (fprintf(dumpFP, "%%%%ProducedBy: %s\n", gszProducedBy) == EOF) { writeFileFailed = TRUE; } if (whereToPrint != LATEX_FIG && whereToPrint != EPSI_FILE && whereToPrint != SVG_FILE) { if (!(pdfSetPageDevice && noOrientationIfPdfSetPageDevice)) { if (fprintf(dumpFP, "%%%%Orientation: %s\n", (pageStyle==PORTRAIT ? "Portrait" : "Landscape")) == EOF) { writeFileFailed = TRUE; } } } if ((whereToPrint != LATEX_FIG && whereToPrint != EPSI_FILE && whereToPrint != SVG_FILE) || !minimalEPS) { int total_pages=0; if (dumpOnePageInStackMode || dumpOnePageInTileMode || whereToPrint == LATEX_FIG || whereToPrint == EPSI_FILE || whereToPrint == SVG_FILE) { total_pages = 1; } else if (pageLayoutMode == PAGE_STACK) { total_pages = (dumpPages ? gPagesToPrintSpec.num_pages_specified : lastPageNum); } else { total_pages = paperCol * paperRow; } if (fprintf(dumpFP, "%%%%Pages: %1d\n", total_pages) == EOF) { writeFileFailed = TRUE; } if (fprintf(dumpFP, "%%%%DocumentFonts: (atend)\n") == EOF) { writeFileFailed = TRUE; } if (NeedA4()) { if (fprintf(dumpFP, "%%%%DocumentPaperSizes: a4\n") == EOF) { writeFileFailed = TRUE; } } if (fprintf(dumpFP, "%%%%EndComments\n") == EOF) { writeFileFailed = TRUE; } } if (whereToPrint == EPSI_FILE && !generateTiffEPSI) { SaveStatusStrings(); SetStringStatus(TgLoadString(STID_GENERATING_PREVIEW_BITMAP)); GenPreviewBitmap(dumpFP, llxPage, llyPage, urxPage, uryPage); RestoreStatusStrings(); } if ((whereToPrint != LATEX_FIG && whereToPrint != EPSI_FILE && whereToPrint != SVG_FILE) || !minimalEPS) { if (fprintf(dumpFP, "%%%%BeginProlog\n") == EOF) { writeFileFailed = TRUE; } } DumpPSMacro(dumpFP); PrepareEightBitFontInfo(); DumpEightBitFontInfo(dumpFP); if (fprintf(dumpFP, "end\n\n") == EOF) writeFileFailed = TRUE; if ((whereToPrint != LATEX_FIG && whereToPrint != EPSI_FILE && whereToPrint != SVG_FILE) || !minimalEPS) { int need_a4=NeedA4(), need_page_size=FALSE, need_setup=FALSE; #ifndef _NO_LANDSCAPE_PDF_SETPAGEDEVICE if (whereToPrint == PDF_FILE) { need_page_size = TRUE; } #endif /* ~_NO_LANDSCAPE_PDF_SETPAGEDEVICE */ if (whereToPrint != LATEX_FIG && whereToPrint != EPSI_FILE && whereToPrint != SVG_FILE) { if (pdfSetPageDevice == INVALID) { if (cmdLinePdfSetPageDevice == INVALID) { /* do nothing */ } else if (cmdLinePdfSetPageDevice) { need_page_size = TRUE; } else { need_page_size = FALSE; } } else if (pdfSetPageDevice) { if (cmdLinePdfSetPageDevice == FALSE) { need_page_size = FALSE; } else { need_page_size = TRUE; } } else { if (cmdLinePdfSetPageDevice == TRUE) { need_page_size = TRUE; } else { need_page_size = FALSE; } } } if (fprintf(dumpFP, "%%%%EndProlog\n") == EOF) writeFileFailed = TRUE; need_setup = (psDistillerNoImageCompress == TRUE || gpszPsSetup != NULL || need_a4 || need_page_size); if (need_setup) { if (fprintf(dumpFP, "%%%%BeginSetup\n") == EOF) { writeFileFailed = TRUE; } } if (need_a4) { if (fprintf(dumpFP, "%%%%PaperSize: a4\n") == EOF || fprintf(dumpFP, "%%%%BeginPaperSize: a4\n") == EOF || fprintf(dumpFP, "%%%%EndPaperSize\n") == EOF) { writeFileFailed = TRUE; } } if (need_page_size) { double scale=((double)printMag)*((double)72.0)/((double)100.0); double w=((double)onePageWidth)/((double)PIX_PER_INCH)*scale; double h=((double)onePageHeight)/((double)PIX_PER_INCH)*scale; if (pageStyle == LANDSCAPE) { fprintf(dumpFP, "<< /PageSize [%1d %1d] ", round(h), round(w)); fprintf(dumpFP, "/ImagingBBox null /Orientation 3 >> setpagedevice\n"); } else { fprintf(dumpFP, "<< /PageSize [%1d %1d] ", round(w), round(h)); fprintf(dumpFP, "/ImagingBBox null /Orientation 0 >> setpagedevice\n"); } } if (psDistillerNoImageCompress == TRUE) { fprintf(dumpFP, "%s\n", "systemdict /setdistillerparams known"); fprintf(dumpFP, " { << %s %s\n", "/AutoFilterGrayImages false", "/AutoFilterColorImages false"); fprintf(dumpFP, " %s %s\n", "/ColorImageFilter /FlateEncode", "/GrayImageFilter /FlateEncode >>"); fprintf(dumpFP, " %s\n", "setdistillerparams"); fprintf(dumpFP, " %s\n", "} if"); } if (gpszPsSetup != NULL) { if (fprintf(dumpFP, "%s\n", gpszPsSetup) == EOF) { writeFileFailed = TRUE; } } if (need_setup) { if (fprintf(dumpFP, "%%%%EndSetup\n") == EOF) { writeFileFailed = TRUE; } } } } if (whereToPrint == NETLIST_FILE && !preDumpSetup && printingPageNum == printingFirstPageNum) { if (fprintf(dumpFP, "PORTNAME\tSIGNALNAME\n") == EOF) { writeFileFailed = TRUE; } } if (pageLayoutMode == PAGE_STACK || (pageLayoutMode == PAGE_TILE && ((paperCol == 1 && paperRow == 1) || ((whereToPrint == LATEX_FIG || whereToPrint == EPSI_FILE || whereToPrint == SVG_FILE) && !dumpOnePageInTileMode)))) { printingPageRow = printingPageCol = 1; if (whereToPrint >= MAXDEFWHERETOPRINT) { if (!ExportVectorFile(dumpFP, dumpOneFilePerPage || (dumpOnePageInStackMode && numberFileInPrintOnePage), printingPageNum, printingFirstPageNum, printingPageRow, printingPageCol)) { return FALSE; } } else if (whereToPrint == TEXT_FILE) { if (printingPageNum != printingFirstPageNum) { fprintf(dumpFP, "\014\n"); } for (obj_ptr = botObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = NULL; DumpAnObjInAscii(dumpFP, obj_ptr); } } else if (whereToPrint == NETLIST_FILE) { for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; DumpNetListForAnObj(dumpFP, obj_ptr); } } else { if ((whereToPrint != LATEX_FIG && whereToPrint != EPSI_FILE && whereToPrint != SVG_FILE) || !minimalEPS) { if (dumpPages) { fprintf(dumpFP, "%%%%Page: %1d %1d\n\n", printingPageNum, dumpPageNum); } else { fprintf(dumpFP, "%%%%Page: %1d %1d\n\n", printingPageNum-printingFirstPageNum+1, printingPageNum-printingFirstPageNum+1); } } if (!minimalEPS) { DumpBBox(dumpFP, PAGE_BBOX, NULL); } if (totalBBoxValid) { if (topObj != NULL) { if (llxPage < llxTotal) llxTotal = llxPage; if (llyPage < llyTotal) llyTotal = llyPage; if (urxPage > urxTotal) urxTotal = urxPage; if (uryPage > uryTotal) uryTotal = uryPage; } } else if (topObj != NULL) { totalBBoxValid = TRUE; llxTotal = llxPage; llyTotal = llyPage; urxTotal = urxPage; uryTotal = uryPage; } if (psBopHookStatus == TRUE && (whereToPrint == PRINTER || whereToPrint == PS_FILE || whereToPrint == PDF_FILE)) { fprintf(dumpFP, "userdict /%s known { %s } if\n\n", psBopHook, psBopHook); } fprintf(dumpFP, "tgifdict begin\n"); fprintf(dumpFP, "/tgifsavedpage save def\n\n"); fprintf(dumpFP, "1 %s\n", gPsCmd[PS_SETMITERLIMIT]); fprintf(dumpFP, "1 %s\n\n", gPsCmd[PS_SETLINEWIDTH]); fprintf(dumpFP, "0 %s\n\n", gPsCmd[PS_SETGRAY]); if (pageStyle == LANDSCAPE) { fprintf(dumpFP, "90 %s\n", gPsCmd[PS_ROTATE]); } fprintf(dumpFP, "%1d %s %s %1d %s %s %s\n", psDotsPerInch, psXOffStr[pageStyle], gPsCmd[PS_MUL], psDotsPerInch, psYOffStr[pageStyle], gPsCmd[PS_MUL], gPsCmd[PS_TRANSLATE]); #ifndef METRIC_PIX_PER_INCH fprintf(dumpFP, "%1d %1d %s %.3f %s 100 %s %s %s %s\n\n", psDotsPerInch, PIX_PER_INCH, gPsCmd[PS_DIV], printMag, gPsCmd[PS_MUL], gPsCmd[PS_DIV], gPsCmd[PS_DUP], gPsCmd[PS_NEG], gPsCmd[PS_SCALE]); #else /* METRIC_PIX_PER_INCH */ fprintf(dumpFP, "%1d %1d %s %.3f %s 100 %s %s %s %s\n\n", psDotsPerInch, (gridSystem==ENGLISH_GRID ? PIX_PER_INCH : METRIC_PIX_PER_INCH), gPsCmd[PS_DIV], printMag, gPsCmd[PS_MUL], gPsCmd[PS_DIV], gPsCmd[PS_DUP], gPsCmd[PS_NEG], gPsCmd[PS_SCALE]); #endif /* ~METRIC_PIX_PER_INCH */ fprintf(dumpFP, "%s\n\n", gPsCmd[PS_GSAVE]); if (needsTgifOrigCTM) { fprintf(dumpFP, "/tgiforigctm matrix currentmatrix def\n\n"); } if (colorDump && colorBgInPrintingColorPS && (whereToPrint == PS_FILE || whereToPrint == PDF_FILE || whereToPrint == PRINTER)) { fprintf(dumpFP, "%% Background\n"); if (myBgColor.red==0 && myBgColor.green==0 && myBgColor.blue==0) { fprintf(dumpFP, "0 %s\n", gPsCmd[PS_SETGRAY]); } else if (myBgColor.red==maxRGB && myBgColor.green==maxRGB && myBgColor.blue==maxRGB) { fprintf(dumpFP, "1 %s\n", gPsCmd[PS_SETGRAY]); } else { fprintf(dumpFP, "%.3f %.3f %.3f %s\n", ((float)myBgColor.red/maxRGB), ((float)myBgColor.green/maxRGB), ((float)myBgColor.blue/maxRGB), gPsCmd[PS_SETRGBCOLOR]); } fprintf(dumpFP, "%s\n", gPsCmd[PS_NEWPATH]); fprintf(dumpFP, " 0 0 %s 0 %d %s %d %d %s %d 0 %s\n", gPsCmd[PS_MOVETO], onePageHeight, gPsCmd[PS_LINETO], onePageWidth, onePageHeight, gPsCmd[PS_LINETO], onePageWidth, gPsCmd[PS_LINETO]); fprintf(dumpFP, "%s %s\n\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_FILL]); } for (obj_ptr = botObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = NULL; DumpAnObj(dumpFP, obj_ptr); } fprintf(dumpFP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(dumpFP, "tgifsavedpage restore\n"); fprintf(dumpFP, "end\n"); switch (whereToPrint) { case PRINTER: case PS_FILE: case PDF_FILE: if (psEopHookStatus == TRUE) { fprintf(dumpFP, "userdict /%s known { %s } if\n", psEopHook, psEopHook); } fprintf(dumpFP, "showpage\n\n"); break; case EPSI_FILE: case LATEX_FIG: case SVG_FILE: if (showPageInEPS) { fprintf(dumpFP, "showpage\n"); } fprintf(dumpFP, "\n"); break; } } } else if (whereToPrint >= MAXDEFWHERETOPRINT) { if (!ExportVectorFile(dumpFP, dumpOneFilePerPage || (dumpOnePageInStackMode && numberFileInPrintOnePage), printingPageNum, printingFirstPageNum, printingPageRow, printingPageCol)) { return FALSE; } } else if (whereToPrint == TEXT_FILE) { for (obj_ptr = botObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = NULL; DumpAnObjInAscii(dumpFP, obj_ptr); } } else if (whereToPrint == NETLIST_FILE) { for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; DumpNetListForAnObj(dumpFP, obj_ptr); } } else { int row, col; float one=(float)atof("1.0"), f_rbx, f_rby, x_dist, y_dist; if (tiledPageScaling == one && !msgAboutTiledPageScalingSeen) { char msg1[MAXSTRING+1]; msgAboutTiledPageScalingSeen = TRUE; sprintf(gszMsgBox, TgLoadString(STID_OUTPUT_TRUNC_IN_PRINT_TILED), TOOL_NAME, "TiledPageScaling"); sprintf(msg1, " %s", TgLoadString(STID_RECOMMEND_REDUCING_SETTING)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); fprintf(stderr, "%s\n", msg1); } else { TwoLineMsg(gszMsgBox, msg1); } } f_rbx = (float)(((float)PIX_PER_INCH) * 100.0 / printMag * psPageWidthInInch[pageStyle]); f_rby = (float)(((float)PIX_PER_INCH) * 100.0 / printMag * psPageHeightInInch[pageStyle]); x_dist = (float)(((float)PIX_PER_INCH) * psPageWidthInInch[pageStyle] * (1.0-tiledPageScaling) * 50.0 / printMag); y_dist = (float)(((float)PIX_PER_INCH) * psPageHeightInInch[pageStyle] * (1.0-tiledPageScaling) * 50.0 / printMag); for (row = 0; row < paperRow; row++) { printingPageRow = row+1; for (col = 0; col < paperCol; col++) { struct BBRec page_bbox; float real_ltx, real_lty; if (dumpOnePageInTileMode && row*paperCol+col+1 != printingPageNum) { continue; } printingPageCol = col+1; page_bbox.ltx = col * onePageWidth; page_bbox.lty = row * onePageHeight; page_bbox.rbx = page_bbox.ltx + onePageWidth; page_bbox.rby = page_bbox.lty + onePageHeight; if ((whereToPrint != LATEX_FIG && whereToPrint != EPSI_FILE && whereToPrint != SVG_FILE) || !minimalEPS) { if (dumpOnePageInTileMode) { fprintf(dumpFP, "%%%%Page: 1 1\n\n"); } else { fprintf(dumpFP, "%%%%Page: %1d %1d\n\n", col+1+row*paperCol, col+1+row*paperCol); } } if (DumpBBox(dumpFP, PAGE_BBOX, &page_bbox)) { if (totalBBoxValid) { if (topObj != NULL) { if (llxPage < llxTotal) llxTotal = llxPage; if (llyPage < llyTotal) llyTotal = llyPage; if (urxPage > urxTotal) urxTotal = urxPage; if (uryPage > uryTotal) uryTotal = uryPage; } } else if (topObj != NULL) { totalBBoxValid = TRUE; llxTotal = llxPage; llyTotal = llyPage; urxTotal = urxPage; uryTotal = uryPage; } } if (psBopHookStatus == TRUE && (whereToPrint == PRINTER || whereToPrint == PS_FILE || whereToPrint == PDF_FILE)) { fprintf(dumpFP, "userdict /%s known { %s } if\n\n", psBopHook, psBopHook); } fprintf(dumpFP, "tgifdict begin\n"); fprintf(dumpFP, "/tgifsavedpage save def\n\n"); fprintf(dumpFP, "1 %s\n", gPsCmd[PS_SETMITERLIMIT]); fprintf(dumpFP, "1 %s\n\n", gPsCmd[PS_SETLINEWIDTH]); fprintf(dumpFP, "0 %s\n\n", gPsCmd[PS_SETGRAY]); if (pageStyle == LANDSCAPE) { fprintf(dumpFP, "90 %s\n", gPsCmd[PS_ROTATE]); } fprintf(dumpFP, "%1d %s %s %1d %s %s %s\n", psDotsPerInch, psXOffStr[pageStyle], gPsCmd[PS_MUL], psDotsPerInch, psYOffStr[pageStyle], gPsCmd[PS_MUL], gPsCmd[PS_TRANSLATE]); #ifndef METRIC_PIX_PER_INCH fprintf(dumpFP, "%1d %1d %s %.3f %s 100 %s %s %s %s\n\n", psDotsPerInch, PIX_PER_INCH, gPsCmd[PS_DIV], printMag, gPsCmd[PS_MUL], gPsCmd[PS_DIV], gPsCmd[PS_DUP], gPsCmd[PS_NEG], gPsCmd[PS_SCALE]); #else /* METRIC_PIX_PER_INCH */ fprintf(dumpFP, "%1d %1d %s %.3f %s 100 %s %s %s %s\n\n", psDotsPerInch, (gridSystem==ENGLISH_GRID ? PIX_PER_INCH : METRIC_PIX_PER_INCH), gPsCmd[PS_DIV], printMag, gPsCmd[PS_MUL], gPsCmd[PS_DIV], gPsCmd[PS_DUP], gPsCmd[PS_NEG], gPsCmd[PS_SCALE]); #endif /* ~METRIC_PIX_PER_INCH */ fprintf(dumpFP, "%s\n\n", gPsCmd[PS_GSAVE]); fprintf(dumpFP, "%% SETUP CLIP FOR PAGE\n\n"); fprintf(dumpFP, "%.3f %.3f %s\n", x_dist, y_dist, gPsCmd[PS_TRANSLATE]); fprintf(dumpFP, "%.3f %.3f %s\n", tiledPageScaling, tiledPageScaling, gPsCmd[PS_SCALE]); fprintf(dumpFP, "-%1d -%1d %s\n", page_bbox.ltx, page_bbox.lty, gPsCmd[PS_TRANSLATE]); real_ltx = (float)(((float)col) * ((float)psPageWidthInInch[pageStyle]) * ((float)PIX_PER_INCH) * 100.0 / printMag); real_lty = (float)(((float)row) * ((float)psPageHeightInInch[pageStyle]) * ((float)PIX_PER_INCH) * 100.0 / printMag); if (psRegMarksInTiledPageMode && tiledPageScaling < (float)1.0) { float stem=((float)(min(x_dist,y_dist)))*((float)0.5); fprintf(dumpFP, "%s\n", gPsCmd[PS_GSAVE]); fprintf(dumpFP, " 0.1 %s %.3f %s\n", gPsCmd[PS_SETLINEWIDTH], psRegMarksGray, gPsCmd[PS_SETGRAY]); fprintf(dumpFP, " %s %.3f %.3f %s\n", gPsCmd[PS_NEWPATH], real_ltx, real_lty, gPsCmd[PS_MOVETO]); DumpRegMark(dumpFP, &stem); fprintf(dumpFP, " %.3f 0 %s\n", f_rbx, gPsCmd[PS_RMOVETO]); DumpRegMark(dumpFP, &stem); fprintf(dumpFP, " 0 %.3f %s\n", f_rby, gPsCmd[PS_RMOVETO]); DumpRegMark(dumpFP, &stem); fprintf(dumpFP, " -%.3f 0 %s\n", f_rbx, gPsCmd[PS_RMOVETO]); DumpRegMark(dumpFP, &stem); fprintf(dumpFP, "%s\n", gPsCmd[PS_GRESTORE]); } fprintf(dumpFP, "%s\n", gPsCmd[PS_NEWPATH]); fprintf(dumpFP, " %.3f %.3f %s\n", real_ltx, real_lty, gPsCmd[PS_MOVETO]); fprintf(dumpFP, " %.3f 0 %s\n", f_rbx, gPsCmd[PS_RLINETO]); fprintf(dumpFP, " 0 %.3f %s\n", f_rby, gPsCmd[PS_RLINETO]); fprintf(dumpFP, " -%.3f 0 %s\n", f_rbx, gPsCmd[PS_RLINETO]); fprintf(dumpFP, "%s %s %s\n\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_CLIP], gPsCmd[PS_NEWPATH]); if (needsTgifOrigCTM) { fprintf(dumpFP, "/tgiforigctm matrix currentmatrix def\n\n"); } if (colorDump && colorBgInPrintingColorPS && (whereToPrint == PS_FILE || whereToPrint == PDF_FILE || whereToPrint == PRINTER)) { fprintf(dumpFP, "%% Background\n"); if (myBgColor.red==0 && myBgColor.green==0 && myBgColor.blue==0) { fprintf(dumpFP, "0 %s\n", gPsCmd[PS_SETGRAY]); } else if (myBgColor.red==maxRGB && myBgColor.green==maxRGB && myBgColor.blue==maxRGB) { fprintf(dumpFP, "1 %s\n", gPsCmd[PS_SETGRAY]); } else { fprintf(dumpFP, "%.3f %.3f %.3f %s\n", ((float)myBgColor.red/maxRGB), ((float)myBgColor.green/maxRGB), ((float)myBgColor.blue/maxRGB), gPsCmd[PS_SETRGBCOLOR]); } fprintf(dumpFP, "%s\n", gPsCmd[PS_NEWPATH]); fprintf(dumpFP, " %.3f %.3f %s\n", real_ltx, real_lty, gPsCmd[PS_MOVETO]); fprintf(dumpFP, " %.3f 0 %s\n", f_rbx, gPsCmd[PS_LINETO]); fprintf(dumpFP, " 0 %.3f %s\n", f_rby, gPsCmd[PS_LINETO]); fprintf(dumpFP, " -%.3f 0 %s\n", f_rbx, gPsCmd[PS_LINETO]); fprintf(dumpFP, "%s %s %s\n\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_FILL], gPsCmd[PS_NEWPATH]); } for (obj_ptr = botObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { if (Inside(obj_ptr->bbox, page_bbox) || BBoxIntersect(obj_ptr->bbox, page_bbox)) { obj_ptr->tmp_parent = NULL; DumpAnObj(dumpFP, obj_ptr); } } fprintf(dumpFP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(dumpFP, "tgifsavedpage restore\n"); fprintf(dumpFP, "end\n"); switch (whereToPrint) { case PRINTER: case PS_FILE: case PDF_FILE: if (psEopHookStatus == TRUE) { fprintf(dumpFP, "userdict /%s known { %s } if\n", psEopHook, psEopHook); } fprintf(dumpFP, "showpage\n\n"); break; case EPSI_FILE: case LATEX_FIG: case SVG_FILE: if (showPageInEPS) { fprintf(dumpFP, "showpage\n"); } fprintf(dumpFP, "\n"); break; } } } } if (dumpPages) { if (dumpPageNum != gPagesToPrintSpec.num_pages_specified) { return TRUE; } } else if (printingPageNum != printingLastPageNum) { return TRUE; } if (whereToPrint < MAXDEFWHERETOPRINT && whereToPrint != TEXT_FILE && whereToPrint != NETLIST_FILE) { if ((whereToPrint != LATEX_FIG && whereToPrint != EPSI_FILE && whereToPrint != SVG_FILE) || !minimalEPS) { if (fprintf(dumpFP, "%%%%Trailer\n") == EOF) { writeFileFailed = TRUE; } } if (pageLayoutMode!=PAGE_STACK || printingFirstPageNum!=printingLastPageNum) { if (fprintf(dumpFP, "%%%%BoundingBox: %1d %1d %1d %1d\n", llxTotal, llyTotal, urxTotal, uryTotal) == EOF) { writeFileFailed = TRUE; } } if (fprintf(dumpFP, "%%MatchingCreationDate: %s\n", loc_time) == EOF) { writeFileFailed = TRUE; } if ((whereToPrint != LATEX_FIG && whereToPrint != EPSI_FILE && whereToPrint != SVG_FILE) || !minimalEPS) { DumpDocumentFonts(dumpFP); DumpPropagatedEPSInfo(dumpFP); if (fprintf(dumpFP, "%%%%EOF\n") == EOF) writeFileFailed = TRUE; } } fclose(dumpFP); dumpFP = NULL; EndGrayDetection(); if (whereToPrint < MAXDEFWHERETOPRINT && whereToPrint != TEXT_FILE && whereToPrint != NETLIST_FILE && !totalBBoxValid) { strcpy(gszMsgBox, TgLoadString(STID_NO_OBJ_TO_PRINT)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(tmpFile); #ifdef KEEP_WHEN_PRINT if (whereToPrint != PRINTER) unlink(tmpFile); #else unlink(tmpFile); #endif return FALSE; } if (preDumpSetup && whereToPrint != NETLIST_FILE) { unlink(tmpFile); return TRUE; } switch (whereToPrint) { case PRINTER: #ifdef VMS #define PRINT_TRAILER "" #else #define PRINT_TRAILER " 2>&1" #endif if (PRTGIF) { /* do not translate -- program constants */ if (strstr(printCommand, "%s") == NULL) { if (lastFile) { sprintf(cmd, "%s %s", printCommand, tmpFile); } else { sprintf(cmd, "%s -h %s", printCommand, tmpFile); } } else { sprintf(cmd, printCommand, tmpFile); } if (strcmp(printCommand, "cat") != 0) { strcat(cmd, PRINT_TRAILER); } fprintf(stderr, "%s\n", cmd); } else { if (strstr(printCommand, "%s") == NULL) { sprintf(cmd, "%s %s", printCommand, tmpFile); } else { sprintf(cmd, printCommand, tmpFile); } sprintf(gszMsgBox, TgLoadString(STID_PRINTING_WITH_GIVEN_CMD), printCommand); if (strcmp(printCommand, "cat") != 0) { strcat(cmd, PRINT_TRAILER); } Msg(gszMsgBox); } if (strcmp(printCommand, "cat") == 0) { /* * Well, you can't really "cat" to a printer (without piping to * anything else), so you must mean "catting" to stdout! */ FILE *pfp=NULL; sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), cmd); SetStringStatus(gszMsgBox); if (!PRTGIF) XSync(mainDisplay, False); if ((pfp=(FILE*)popen(cmd, "r")) == NULL) return FALSE; while (fgets(gszMsgBox, sizeof(gszMsgBox)-1, pfp) != NULL) { printf("%s", gszMsgBox); } pclose(pfp); SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); } else if (!ExecuteCmd(cmd, FALSE)) { if (PRTGIF) { fprintf(stderr, TgLoadString(STID_CANNOT_EXEC_ABORT_PRINT), cmd); fprintf(stderr, "\n"); } else { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_EXEC_ABORT_PRINT), cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } unlink(tmpFile); return FALSE; } if (PRTGIF) { fprintf(stderr, TgLoadString(STID_NAMED_FILE_PRINTED), tmpFile); fprintf(stderr, "\n"); } else { Msg(TgLoadString(STID_PRINT_COMPLETED)); } break; case EPSI_FILE: case LATEX_FIG: case SVG_FILE: case PS_FILE: case PDF_FILE: switch (whereToPrint) { case EPSI_FILE: if (*epsiExportExtension == '\0') { file_ext = EPSF_FILE_EXT; } else { file_ext = epsiExportExtension; } output_type = "EPSI"; break; case LATEX_FIG: file_ext = EPSF_FILE_EXT; output_type = "EPS"; break; case SVG_FILE: file_ext = EPSF_FILE_EXT; output_type = "SVG"; break; case PS_FILE: file_ext = PS_FILE_EXT; output_type = "PostScript"; break; case PDF_FILE: file_ext = "p~f"; output_type = "PDF"; break; } if (PRTGIF) { SetOutputFileName(ps_file, file_ext, NULL, &FileName); } else { if (!curFileDefined) { sprintf(gszMsgBox, TgLoadString(STID_NO_CUR_FILE_CANNOT_GEN_FORMAT), output_type); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(tmpFile); return FALSE; } SetOutputFileName(ps_file, file_ext, &short_name, &rest); if (short_name && *outputDir=='\0') { sprintf(gszMsgBox, TgLoadString(STID_PRINTING_INTO_NAMED_FILE), rest); } else { sprintf(gszMsgBox, TgLoadString(STID_PRINTING_INTO_NAMED_FILE), ps_file); } Msg(gszMsgBox); } if (whereToPrint == EPSI_FILE && generateTiffEPSI) { int saved_colordump=colorDump, consensed_already=FALSE, ok=TRUE; SaveStatusStrings(); SetStringStatus(TgLoadString(STID_GENERATING_TIFF_PREVIEW_BMP)); colorDump = FALSE; DumpXBitmapFile(FALSE, FALSE, FALSE); colorDump = saved_colordump; if (psUseShortHand && !dontCondense) { if (CondensePostScriptFile(tmpFile, sizeof(tmpFile))) { consensed_already = TRUE; } else { ok = FALSE; } } if (ok) { GenTiffFile(tmpFile, ps_file, psUseShortHand, consensed_already); } RestoreStatusStrings(); unlink(tmpFile); } else if (whereToPrint == PDF_FILE) { char real_ps_file[MAXSTRING+1]; if (!CopyAFile(tmpFile, (PRTGIF && cmdLineStdOut) ? NULL : ps_file, psUseShortHand)) { sprintf(gszMsgBox, TgLoadString(STID_FORMAT_FILE_NOT_GENERATED), output_type); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } unlink(tmpFile); return FALSE; } UtilStrCpyN(real_ps_file, sizeof(real_ps_file), ps_file); if (PRTGIF) { SetOutputFileName(ps_file, pdfExportExtension, NULL, &FileName); } else { SetOutputFileName(ps_file, pdfExportExtension, &short_name, &rest); if (short_name && *outputDir=='\0') { sprintf(gszMsgBox, TgLoadString(STID_CONVERTING_INTO_NAMED_FILE), rest); } else { sprintf(gszMsgBox, TgLoadString(STID_CONVERTING_INTO_NAMED_FILE), ps_file); } Msg(gszMsgBox); } /* actually, ps_file contains the full path to the PDF file */ sprintf(cmd, psToPdfCmd, real_ps_file, ps_file); if (!ExecuteCmd(cmd, FALSE)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_EXEC_FORMAT_NOT_GEN), cmd, output_type); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } unlink(real_ps_file); unlink(tmpFile); return FALSE; } unlink(real_ps_file); } else if (whereToPrint == SVG_FILE) { char sk_fname[MAXPATHLENGTH], svg_fname[MAXPATHLENGTH]; char eps_fname[MAXPATHLENGTH]; /* ps_file contains the full path to an EPS file */ *sk_fname = *svg_fname = *eps_fname = '\0'; snprintf(sk_fname, sizeof(sk_fname), "%s.sk", tmpFile); snprintf(svg_fname, sizeof(svg_fname), "%s.svg", tmpFile); snprintf(eps_fname, sizeof(eps_fname), "%s.eps", tmpFile); unlink(sk_fname); unlink(svg_fname); unlink(eps_fname); if (!CopyAFile(tmpFile, (PRTGIF && cmdLineStdOut) ? NULL : eps_fname, psUseShortHand)) { sprintf(gszMsgBox, TgLoadString(STID_FORMAT_FILE_NOT_GENERATED), output_type); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } unlink(tmpFile); return FALSE; } if (PRTGIF) { SetOutputFileName(ps_file, "svg", NULL, &FileName); } else { SetOutputFileName(ps_file, "svg", &short_name, &rest); if (short_name && *outputDir=='\0') { sprintf(gszMsgBox, TgLoadString(STID_CONVERTING_INTO_NAMED_FILE), rest); } else { sprintf(gszMsgBox, TgLoadString(STID_CONVERTING_INTO_NAMED_FILE), ps_file); } Msg(gszMsgBox); } sprintf(cmd, epsToTmpSvgCmd, eps_fname, sk_fname); if (!ExecuteCmd(cmd, FALSE)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_EXEC_FORMAT_NOT_GEN), cmd, output_type); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } unlink(eps_fname); unlink(tmpFile); return FALSE; } unlink(eps_fname); sprintf(cmd, tmpSvgToSvgCmd, sk_fname, svg_fname); if (!ExecuteCmd(cmd, FALSE)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_EXEC_FORMAT_NOT_GEN), cmd, output_type); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } unlink(sk_fname); unlink(tmpFile); return FALSE; } unlink(sk_fname); if (!FixUpSVGFile(svg_fname, ps_file)) { unlink(svg_fname); unlink(tmpFile); return FALSE; } unlink(svg_fname); /* at this point, ps_file contains the full path to the SVG file */ } else { if (!CopyAFile(tmpFile, (PRTGIF && cmdLineStdOut) ? NULL : ps_file, psUseShortHand)) { sprintf(gszMsgBox, TgLoadString(STID_FORMAT_FILE_NOT_GENERATED), output_type); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } unlink(tmpFile); return FALSE; } } if (tmpFileMode != 0 && chmod(ps_file, tmpFileMode)) { if (PRTGIF) { fprintf(stderr, TgLoadString(STID_CANNOT_CHMOD), ps_file, tmpFileMode); fprintf(stderr, "\n"); } else { if (short_name && *outputDir=='\0') { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CHMOD), rest, tmpFileMode); } else { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CHMOD), ps_file, tmpFileMode); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } if (PRTGIF) { if (!cmdLineStdOut && !cmdLineQuiet) { fprintf(stderr, TgLoadString(STID_FORMAT_FILE_PRINTED_INTO), output_type, ps_file); fprintf(stderr, "\n"); } } else { if (short_name && *outputDir=='\0') { sprintf(gszMsgBox, TgLoadString(STID_FORMAT_FILE_PRINTED_INTO), output_type, rest); } else { sprintf(gszMsgBox, TgLoadString(STID_FORMAT_FILE_PRINTED_INTO), output_type, ps_file); } Msg(gszMsgBox); } break; case TEXT_FILE: if (PRTGIF) { SetOutputFileName(ps_file, TEXT_FILE_EXT, NULL, &FileName); } else { if (!curFileDefined) { sprintf(gszMsgBox, TgLoadString(STID_NO_CUR_FILE_CANNOT_GEN_TEXT)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(tmpFile); return FALSE; } SetOutputFileName(ps_file, TEXT_FILE_EXT, &short_name, &rest); if (short_name && *outputDir=='\0') { sprintf(gszMsgBox, TgLoadString(STID_PRINTING_INTO_NAMED_FILE), rest); } else { sprintf(gszMsgBox, TgLoadString(STID_PRINTING_INTO_NAMED_FILE), ps_file); } Msg(gszMsgBox); } if (!CopyAFile(tmpFile, (PRTGIF && cmdLineStdOut) ? NULL : ps_file, FALSE)) { if (PRTGIF) { fprintf(stderr, "%s\n", TgLoadString(STID_TEXT_OUTPUT_NOT_GEN)); } else { Msg(TgLoadString(STID_TEXT_OUTPUT_NOT_GEN)); } unlink(tmpFile); return FALSE; } if (tmpFileMode != 0 && chmod(ps_file, tmpFileMode)) { if (PRTGIF) { fprintf(stderr, TgLoadString(STID_CANNOT_CHMOD), ps_file, tmpFileMode); } else { if (short_name && *outputDir=='\0') { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CHMOD), rest, tmpFileMode); } else { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CHMOD), ps_file, tmpFileMode); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } if (PRTGIF) { if (!cmdLineStdOut && !cmdLineQuiet) { fprintf(stderr, TgLoadString(STID_TEXT_PRINTED_INTO_NAMED_FILE), ps_file); fprintf(stderr, "\n"); } } else { if (short_name && *outputDir=='\0') { sprintf(gszMsgBox, TgLoadString(STID_TEXT_PRINTED_INTO_NAMED_FILE), rest); } else { sprintf(gszMsgBox, TgLoadString(STID_TEXT_PRINTED_INTO_NAMED_FILE), ps_file); } Msg(gszMsgBox); } break; default: /* * whereToPrint >= MAXDEFWHERETOPRINT or whereToPrint == NETLIST_FILE */ if (PRTGIF) { SetOutputFileName(ps_file, GetExportExt(whereToPrint), NULL, &FileName); } else { if (!curFileDefined) { sprintf(gszMsgBox, TgLoadString(STID_NO_CUR_FILE_CANNOT_GEN_FORMAT), GetExportName(whereToPrint, EXPORT_THIS)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(tmpFile); return FALSE; } SetOutputFileName(ps_file, GetExportExt(whereToPrint), &short_name, &rest); if (short_name && *outputDir=='\0') { sprintf(gszMsgBox, TgLoadString(STID_PRINTING_INTO_NAMED_FILE), rest); } else { sprintf(gszMsgBox, TgLoadString(STID_PRINTING_INTO_NAMED_FILE), ps_file); } Msg(gszMsgBox); } if (!CopyAFile(tmpFile, (PRTGIF && cmdLineStdOut) ? NULL : ps_file, FALSE)) { sprintf(gszMsgBox, TgLoadString(STID_FORMAT_FILE_NOT_GENERATED), GetExportName(whereToPrint, EXPORT_THIS)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } unlink(tmpFile); return FALSE; } if (tmpFileMode != 0 && chmod(ps_file, tmpFileMode)) { if (PRTGIF) { fprintf(stderr, TgLoadString(STID_CANNOT_CHMOD), ps_file, tmpFileMode); } else { if (short_name && *outputDir=='\0') { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CHMOD), rest, tmpFileMode); } else { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CHMOD), ps_file, tmpFileMode); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } if (PRTGIF) { if (!cmdLineStdOut && !cmdLineQuiet) { fprintf(stderr, TgLoadString(STID_FORMAT_FILE_PRINTED_INTO), GetExportName(whereToPrint, EXPORT_THIS), ps_file); fprintf(stderr, "\n"); } } else { if (short_name && *outputDir=='\0') { sprintf(gszMsgBox, TgLoadString(STID_FORMAT_FILE_PRINTED_INTO), GetExportName(whereToPrint, EXPORT_THIS), rest); } else { sprintf(gszMsgBox, TgLoadString(STID_FORMAT_FILE_PRINTED_INTO), GetExportName(whereToPrint, EXPORT_THIS), ps_file); } Msg(gszMsgBox); } break; } #ifdef KEEP_WHEN_PRINT if (whereToPrint != PRINTER) { unlink(tmpFile); } #else unlink(tmpFile); #endif return TRUE; } static int GenDump(FileName) char *FileName; { int rc=INVALID, saved_where_to_print=whereToPrint; static int saved_dont_condense=INVALID; if (preDumpSetup) { CleanUpPropagatedEPSInfo(); saved_dont_condense = dontCondense; hasReadHexString = FALSE; } xpmHasTooManyColorsForPrinting = FALSE; if (whereToPrint == TIFFEPSI_FILE) { whereToPrint = EPSI_FILE; generateTiffEPSI = TRUE; } SaveStatusStrings(); rc = DoGenDump(FileName); RestoreStatusStrings(); if (saved_where_to_print == TIFFEPSI_FILE) { whereToPrint = TIFFEPSI_FILE; generateTiffEPSI = FALSE; } if (preDumpSetup && hasReadHexString) { if (!dontCondense) { strcpy(gszMsgBox, TgLoadString(STID_WONT_CONDENSE_READHEXSTRING)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } } dontCondense = TRUE; } if (!preDumpSetup && xpmHasTooManyColorsForPrinting) { MsgBox(TgLoadString(STID_TOO_MANY_COLOR_FOR_XPM_EXPORT), TOOL_NAME, INFO_MB); } if (!preDumpSetup) { if (hasReadHexString) { dontCondense = saved_dont_condense; hasReadHexString = FALSE; } CleanUpPropagatedEPSInfo(); } return rc; } void Dump(FileName) char *FileName; { int ok=TRUE; struct PageRec *saved_cur_page; if ((whereToPrint == LATEX_FIG || whereToPrint == EPSI_FILE || whereToPrint == TIFFEPSI_FILE || whereToPrint == SVG_FILE) && pageLayoutMode == PAGE_TILE && (paperCol != 1 || paperRow != 1)) { strcpy(gszMsgBox, TgLoadString(STID_CANNOT_PRINT_EPS_TILED_PAGE)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(TgLoadString(STID_CANNOT_PRINT_EPS_TILED_PAGE), TOOL_NAME, INFO_MB); } return; } if (PRTGIF) { RemoveFileNameExtension(FileName); if (cmdLineOneFilePerPage || (cmdLineHasPageNum && pageLayoutMode==PAGE_STACK && (whereToPrint==PS_FILE || whereToPrint==PDF_FILE || whereToPrint==PRINTER))) { totalBBoxValid = FALSE; printingFirstPageNum = printingPageNum = printingLastPageNum = curPageNum; dumpOnePageInStackMode = TRUE; } } else { HighLightReverse(); SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } totalBBoxValid = FALSE; if (whereToPrint == PRINTER || whereToPrint == PS_FILE || whereToPrint == PDF_FILE || whereToPrint == TEXT_FILE || whereToPrint == NETLIST_FILE || (whereToPrint >= MAXDEFWHERETOPRINT && (GetExportFilterCapability(whereToPrint) & TGEF_CAP_MULTI_PAGE) != 0)) { if (PRTGIF && (cmdLineOneFilePerPage || (cmdLineHasPageNum && pageLayoutMode==PAGE_STACK && (whereToPrint==PS_FILE || whereToPrint==PDF_FILE || whereToPrint==PRINTER)))) { if (whereToPrint==PRINTER || whereToPrint==LATEX_FIG || whereToPrint==PS_FILE || whereToPrint==PDF_FILE || whereToPrint==EPSI_FILE || whereToPrint==TIFFEPSI_FILE || whereToPrint==NETLIST_FILE || whereToPrint==SVG_FILE) { ResetPSInfo(); CacheColorsForPrinting(); ok = GenDump(FileName); DoneResetPSInfo(); } if (ok) GenDump(FileName); CleanUpCachedColorsForPrinting(); } else { XColor *saved_tgif_colors=tgifColors; if (printUsingRequestedColor) tgifColors = tgifRequestedColors; if (whereToPrint==PRINTER || whereToPrint==LATEX_FIG || whereToPrint==PS_FILE || whereToPrint==PDF_FILE || whereToPrint==EPSI_FILE || whereToPrint==TIFFEPSI_FILE || whereToPrint==NETLIST_FILE || whereToPrint==SVG_FILE) { ResetPSInfo(); CacheColorsForPrinting(); printingFirstPageNum = 1; printingPageNum = 1; printingLastPageNum = lastPageNum; saved_cur_page = curPage; SaveStatusStrings(); for (curPage=firstPage; ok && curPage != NULL; curPage=curPage->next, printingPageNum++) { topObj = curPage->top; botObj = curPage->bot; sprintf(gszMsgBox, TgLoadString(STID_PREPROCESS_PAGE_OF), printingPageNum, lastPageNum); SetStringStatus(gszMsgBox); ok = GenDump(FileName); } RestoreStatusStrings(); curPage = saved_cur_page; topObj = curPage->top; botObj = curPage->bot; DoneResetPSInfo(); } printingFirstPageNum = 1; printingPageNum = 1; printingLastPageNum = lastPageNum; saved_cur_page = curPage; SaveStatusStrings(); for (curPage=firstPage; ok && curPage != NULL; curPage=curPage->next, printingPageNum++) { topObj = curPage->top; botObj = curPage->bot; sprintf(gszMsgBox, TgLoadString(STID_GENERATING_PAGE_OF), printingPageNum, lastPageNum); SetStringStatus(gszMsgBox); ok = GenDump(FileName); } CleanUpCachedColorsForPrinting(); RestoreStatusStrings(); curPage = saved_cur_page; topObj = curPage->top; botObj = curPage->bot; if (printUsingRequestedColor) tgifColors = saved_tgif_colors; } } else { XColor *saved_tgif_colors=tgifColors; if (printUsingRequestedColor) tgifColors = tgifRequestedColors; if (whereToPrint==PRINTER || whereToPrint==LATEX_FIG || whereToPrint==PS_FILE || whereToPrint==PDF_FILE || whereToPrint==EPSI_FILE || whereToPrint==TIFFEPSI_FILE || whereToPrint==SVG_FILE) { ResetPSInfo(); CacheColorsForPrinting(); printingFirstPageNum = 1; printingPageNum = 1; printingLastPageNum = 1; ok = GenDump(FileName); DoneResetPSInfo(); } printingFirstPageNum = 1; printingPageNum = 1; printingLastPageNum = 1; if (ok) GenDump(FileName); CleanUpCachedColorsForPrinting(); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; } if (PRTGIF) { if (cmdLineOneFilePerPage || (cmdLineHasPageNum && pageLayoutMode==PAGE_STACK && (whereToPrint==PS_FILE || whereToPrint==PDF_FILE || whereToPrint==PRINTER))) { dumpOnePageInStackMode = FALSE; } } else { SetDefaultCursor(mainWindow); ShowCursor(); HighLightForward(); } } void DumpPages() { struct PageRec *saved_cur_page=NULL; int ok=TRUE; XColor *saved_tgif_colors=tgifColors; if (printUsingRequestedColor) tgifColors = tgifRequestedColors; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); ResetPSInfo(); CacheColorsForPrinting(); printingFirstPageNum = INVALID; printingPageNum = 1; printingLastPageNum = lastPageNum; saved_cur_page = curPage; totalBBoxValid = FALSE; SaveStatusStrings(); for (curPage=firstPage; ok && curPage != NULL; curPage=curPage->next, printingPageNum++) { if (gPagesToPrintSpec.page_specified[printingPageNum-1]) { if (printingFirstPageNum == INVALID) { printingFirstPageNum = printingPageNum; } topObj = curPage->top; botObj = curPage->bot; sprintf(gszMsgBox, TgLoadString(STID_PREPROCESS_PAGE_OF), printingPageNum, lastPageNum); SetStringStatus(gszMsgBox); ok = GenDump(""); } } RestoreStatusStrings(); curPage = saved_cur_page; topObj = curPage->top; botObj = curPage->bot; DoneResetPSInfo(); dumpPages = TRUE; dumpPageNum = 0; printingFirstPageNum = INVALID; printingPageNum = 1; printingLastPageNum = lastPageNum; saved_cur_page = curPage; totalBBoxValid = FALSE; SaveStatusStrings(); for (curPage=firstPage; ok && curPage != NULL; curPage=curPage->next, printingPageNum++) { if (gPagesToPrintSpec.page_specified[printingPageNum-1]) { if (printingFirstPageNum == INVALID) { printingFirstPageNum = printingPageNum; } dumpPageNum++; topObj = curPage->top; botObj = curPage->bot; sprintf(gszMsgBox, TgLoadString(STID_GENERATING_PAGE_OF), printingPageNum, lastPageNum); SetStringStatus(gszMsgBox); ok = GenDump(""); } } CleanUpCachedColorsForPrinting(); RestoreStatusStrings(); curPage = saved_cur_page; topObj = curPage->top; botObj = curPage->bot; dumpPages = FALSE; dumpPageNum = INVALID; SetDefaultCursor(mainWindow); ShowCursor(); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; } void DumpOnePageInTileMode(row, col) int row, col; { int ok=TRUE; XColor *saved_tgif_colors=tgifColors; if (printUsingRequestedColor) tgifColors = tgifRequestedColors; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); totalBBoxValid = FALSE; printingFirstPageNum = printingPageNum = printingLastPageNum = row*paperCol+col+1; dumpOnePageInTileMode = TRUE; if (whereToPrint==PRINTER || whereToPrint==LATEX_FIG || whereToPrint==PS_FILE || whereToPrint==PDF_FILE || whereToPrint==EPSI_FILE || whereToPrint==TIFFEPSI_FILE || whereToPrint==SVG_FILE) { ResetPSInfo(); CacheColorsForPrinting(); ok = GenDump(""); DoneResetPSInfo(); } if (ok) GenDump(""); CleanUpCachedColorsForPrinting(); dumpOnePageInTileMode = FALSE; SetDefaultCursor(mainWindow); ShowCursor(); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; } void DumpOnePageInStackMode() { int ok=TRUE; XColor *saved_tgif_colors=tgifColors; if (printUsingRequestedColor) tgifColors = tgifRequestedColors; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); totalBBoxValid = FALSE; printingFirstPageNum = printingPageNum = printingLastPageNum = curPageNum; dumpOnePageInStackMode = TRUE; if (whereToPrint==PRINTER || whereToPrint==LATEX_FIG || whereToPrint==PS_FILE || whereToPrint==PDF_FILE || whereToPrint==EPSI_FILE || whereToPrint==TIFFEPSI_FILE || whereToPrint==SVG_FILE) { ResetPSInfo(); CacheColorsForPrinting(); ok = GenDump(""); DoneResetPSInfo(); } if (ok) GenDump(""); CleanUpCachedColorsForPrinting(); dumpOnePageInStackMode = FALSE; SetDefaultCursor(mainWindow); ShowCursor(); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; } void DumpOneFilePerPage() { int ok=TRUE, saved_cur_page_num=curPageNum; XColor *saved_tgif_colors=tgifColors; if (printUsingRequestedColor) tgifColors = tgifRequestedColors; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); dumpOneFilePerPage = TRUE; dumpOnePageInStackMode = TRUE; for (curPageNum=1; ok && curPageNum <= lastPageNum; curPageNum++) { totalBBoxValid = FALSE; GotoPageNum(curPageNum); ShowPage(); XSync(mainDisplay, False); printingFirstPageNum = printingPageNum = printingLastPageNum = curPageNum; if (gPagesToPrintSpec.page_specified[curPageNum-1]) { if (whereToPrint==LATEX_FIG || whereToPrint==PS_FILE || whereToPrint==PDF_FILE || whereToPrint==EPSI_FILE || whereToPrint==TIFFEPSI_FILE || whereToPrint==SVG_FILE) { ResetPSInfo(); CacheColorsForPrinting(); ok = GenDump(""); DoneResetPSInfo(); if (ok) ok = GenDump(""); CleanUpCachedColorsForPrinting(); } else { ok = GenDump(""); } } } dumpOnePageInStackMode = FALSE; dumpOneFilePerPage = FALSE; SetDefaultCursor(mainWindow); ShowCursor(); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; if (!ok && curPageNum <= lastPageNum) { if (curPageNum == lastPageNum) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_PAGE_NOT_GENERATED), lastPageNum); } else { sprintf(gszMsgBox, TgLoadString(STID_PAGE_RANGE_NOT_GENERATED), curPageNum, lastPageNum); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } if (saved_cur_page_num != curPageNum) { GotoPageNum(saved_cur_page_num); ClearAndRedrawDrawWindow(); ShowPage(); } } void PrintWithCommand(FileName) char *FileName; { struct PageRec *saved_cur_page=NULL; int ok=TRUE; XColor *saved_tgif_colors=tgifColors; if (whereToPrint != PRINTER) { MsgBox(TgLoadString(STID_PRINTWITHCMD_WORKS_PRINTER), TOOL_NAME, INFO_MB); return; } Dialog(TgLoadString(STID_ENTER_PRINT_CMD_NAME), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), printCommand); if (*printCommand == '\0') return; if (printUsingRequestedColor) tgifColors = tgifRequestedColors; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if (whereToPrint==PRINTER || whereToPrint==LATEX_FIG || whereToPrint==PS_FILE || whereToPrint==PDF_FILE || whereToPrint==EPSI_FILE || whereToPrint==TIFFEPSI_FILE || whereToPrint==SVG_FILE) { ResetPSInfo(); CacheColorsForPrinting(); printingPageNum = 1; printingLastPageNum = lastPageNum; saved_cur_page = curPage; totalBBoxValid = FALSE; SaveStatusStrings(); for (curPage=firstPage; ok && curPage != NULL; curPage=curPage->next, printingPageNum++) { topObj = curPage->top; botObj = curPage->bot; sprintf(gszMsgBox, TgLoadString(STID_PREPROCESS_PAGE_OF), printingPageNum, lastPageNum); SetStringStatus(gszMsgBox); ok = GenDump(FileName); } RestoreStatusStrings(); curPage = saved_cur_page; topObj = curPage->top; botObj = curPage->bot; DoneResetPSInfo(); } printingPageNum = 1; printingLastPageNum = lastPageNum; saved_cur_page = curPage; totalBBoxValid = FALSE; SaveStatusStrings(); for (curPage=firstPage; ok && curPage != NULL; curPage=curPage->next, printingPageNum++) { topObj = curPage->top; botObj = curPage->bot; sprintf(gszMsgBox, TgLoadString(STID_GENERATING_PAGE_OF), printingPageNum, lastPageNum); SetStringStatus(gszMsgBox); ok = GenDump(FileName); } CleanUpCachedColorsForPrinting(); RestoreStatusStrings(); curPage = saved_cur_page; topObj = curPage->top; botObj = curPage->bot; SetDefaultCursor(mainWindow); ShowCursor(); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; } void PrintSelectedObjs() { struct SelRec *top_sel_ptr, *bot_sel_ptr, *sel_ptr, *next_sel; struct ObjRec *saved_top_obj, *saved_bot_obj, *obj_ptr; if (topSel == NULL) { MsgBox(TgLoadString(STID_NO_OBJ_SEL_NOTHING_TO_PRINT), TOOL_NAME, INFO_MB); return; } HighLightReverse(); PushPageInfo(); saved_top_obj = topObj; saved_bot_obj = botObj; JustDupSelObj(&top_sel_ptr, &bot_sel_ptr); curPage->top = topObj = top_sel_ptr->obj; curPage->bot = botObj = bot_sel_ptr->obj; for (sel_ptr=topSel, obj_ptr=topObj; obj_ptr!=NULL; sel_ptr=sel_ptr->next, obj_ptr=obj_ptr->next) { CopyObjId(sel_ptr->obj, obj_ptr); CopyObjLocks(sel_ptr->obj, obj_ptr); } if (pageLayoutMode == PAGE_STACK) { DumpOnePageInStackMode(); } else { int ok=TRUE; XColor *saved_tgif_colors=tgifColors; if (printUsingRequestedColor) tgifColors = tgifRequestedColors; printingFirstPageNum = 1; printingPageNum = 1; printingLastPageNum = 1; totalBBoxValid = FALSE; if (whereToPrint==PRINTER || whereToPrint==LATEX_FIG || whereToPrint==PS_FILE || whereToPrint==PDF_FILE || whereToPrint==EPSI_FILE || whereToPrint==TIFFEPSI_FILE || whereToPrint==SVG_FILE) { ResetPSInfo(); CacheColorsForPrinting(); ok = GenDump(""); DoneResetPSInfo(); } if (ok) GenDump(""); CleanUpCachedColorsForPrinting(); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; } DelAllObj(); for (sel_ptr = top_sel_ptr; sel_ptr != NULL; sel_ptr = next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } PopPageInfo(); curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); } void SetPrintReduction() { float fval=(float)0; double right_margin=(double)0; char buf[MAXSTRING+1]; *buf = '\0'; Dialog(TgLoadString(STID_SPECIFY_PERCENT_REDUCTION), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), buf); if (*buf == '\0') return; if (sscanf(buf, "%f", &fval) != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_REDUCTION), buf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (rightMarginEnabled == TRUE) { right_margin = rightMargin * ((double)printMag) / ((double)100); } printMag = fval; if (UpdPageStyle(pageStyle)) { UpdDrawWinBBox(); AdjSplineVs(); ClearAndRedrawDrawWindow(); } if (rightMarginEnabled == TRUE) { rightMargin = right_margin * ((double)100) / ((double)printMag); } RedrawScrollBars(); RedrawRulers(); RedrawTitleWindow(); SetFileModified(TRUE); FormatFloat(&printMag, buf); if (printMag <= 100.0) { sprintf(gszMsgBox, TgLoadString(STID_NEW_REDUCTION_IS_PERCENT), buf); } else { sprintf(gszMsgBox, TgLoadString(STID_NEW_ENLARGEMENT_IS_PERCENT), buf); } Msg(gszMsgBox); } static void DoNewProc(clear_all_wb) int clear_all_wb; { if (!gstWBInfo.do_whiteboard) { CleanUpCmds(); } CleanUpDrawingWindow(); ClearFileInfo(TRUE); ClearAndRedrawDrawWindow(); CheckFileAttrsInLoad(); Msg(TgLoadString(STID_EDITING_NO_FILE)); if (gstWBInfo.do_whiteboard) { if (clear_all_wb) { RecordWBClearAll(); } } else { objId = 0; } RedrawTitleWindow(); DelAllPages(); lastPageNum = 1; InitPage(); ShowPage(); rightMargin = defRightMargin; rightMarginEnabled = defRightMarginEnabled; rightMarginActive = (rightMarginEnabled == TRUE); RedrawHRulerWindow(); } void NewProc() { if (gstWBInfo.do_whiteboard) { XBell(mainDisplay, 0); if (MsgBox(TgLoadString(STID_OK_TO_CLEAR_WHITEBOARD), TOOL_NAME, YNC_MB) != MB_ID_YES) { return; } TieLooseEnds(); SetFileModified(FALSE); } else { while (!DirIsRemote(curDir) && fileModified && !IsFiletUnSavable()) { XBell(mainDisplay, 0); switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_CLEAR), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: TieLooseEnds(); SetFileModified(FALSE); break; case MB_ID_CANCEL: return; } } if (!DirIsRemote(curDir) && fileModified && IsFiletUnSavable()) { TieLooseEnds(); SetFileModified(FALSE); } } if (inHyperSpace && !inSlideShow) ToggleHyperSpace(FALSE); DoNewProc(TRUE); } int BeforeOpenURL(pn_do_not_save) int *pn_do_not_save; { int do_not_save=FALSE; if (inSlideShow) { XBell(mainDisplay, 0); MsgBox(TgLoadString(STID_CANNOT_OPEN_IN_SLIDESHOW), TOOL_NAME, INFO_MB); return FALSE; } else if (gstWBInfo.do_whiteboard) { XBell(mainDisplay, 0); if (MsgBox(TgLoadString(STID_OK_TO_CLEAR_WHITEBOARD), TOOL_NAME, YNC_MB) != MB_ID_YES) { return FALSE; } } else { while (!DirIsRemote(curDir) && fileModified && !IsFiletUnSavable()) { XBell(mainDisplay, 0); switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_OPEN), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: do_not_save = TRUE; SetFileModified(FALSE); break; case MB_ID_CANCEL: return FALSE; } } if (!DirIsRemote(curDir) && fileModified && IsFiletUnSavable()) { do_not_save = TRUE; SetFileModified(FALSE); } } if (pn_do_not_save != NULL) *pn_do_not_save = do_not_save; return TRUE; } void OpenURL(file_name, do_not_save, pn_need_to_check_auto_exec) char *file_name; int do_not_save, *pn_need_to_check_auto_exec; { int need_to_check_auto_exec=FALSE; if (gstWBInfo.do_whiteboard) { DoNewProc(FALSE); } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if (FileIsRemote(file_name)) { char remote_fname[MAXPATHLENGTH+1]; char *page_spec=NULL; if (!FormNewFileName(curDir, file_name, NULL, remote_fname, &page_spec)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_REMOTE_FNAME), file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (do_not_save) SetFileModified(TRUE); } else { char *buf=NULL, *content_type=NULL, final_url[MAXPATHLENGTH+1]; int rc, buf_sz=0, is_html=FALSE; *final_url = '\0'; SaveStatusStrings(); rc = LoadRemoteFileInMem(remote_fname, &buf, &content_type, &buf_sz, &is_html, TRUE, final_url, sizeof(final_url)); RestoreStatusStrings(); if (rc && buf != NULL) { if (*final_url != '\0') { UtilStrCpyN(remote_fname, sizeof(remote_fname), final_url); } if (LoadRemoteFileFromMem(remote_fname, buf, content_type, buf_sz, is_html)) { need_to_check_auto_exec = TRUE; } } else if (do_not_save) { SetFileModified(TRUE); } if (content_type != NULL) FreeRemoteBuf(content_type); if (buf != NULL) FreeRemoteBuf(buf); if (page_spec != NULL) { int new_page_num=(-1); need_to_check_auto_exec = FALSE; if (!GetPageNumFromPageSpec(page_spec, &new_page_num)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PAGE_SPECIFIED_FOR), file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (new_page_num != curPageNum) { BeforeNavigate(); GotoPageNum(new_page_num); ShowPage(); ClearAndRedrawDrawWindow(); RedrawTitleWindow(); RedrawRulers(); RedrawScrollBars(); justDupped = FALSE; } } } if (page_spec != NULL) free(page_spec); } else { int gzipped=FALSE, obj_file=FALSE; obj_file = FileNameHasExtension(file_name, OBJ_FILE_TYPE, &gzipped, NULL); if (!LoadFile(file_name, obj_file, obj_file && gzipped)) { if (do_not_save) { SetFileModified(TRUE); } } else { need_to_check_auto_exec = TRUE; } } SetDefaultCursor(mainWindow); ShowCursor(); if (gstWBInfo.do_whiteboard && (topObj != NULL || tgifObj->fattr != NULL)) { #ifdef _TGIF_WB2_NO_DELAY_BUG sleep(1); #endif /* ~_TGIF_WB2_NO_DELAY_BUG */ /* * In slideshow mode, SelAllObj() will *not* select anything! * Since we really want the objects to be selected (because * we want to record them), we must set ignore_slideshow * to TRUE when we call SelAllObj(). */ if (tgifObj->fattr != NULL) { StartCompositeCmd(); } if (topObj != NULL) { SelAllObj(FALSE, TRUE); PrepareToRecord(CMD_NEW, NULL, NULL, 0); RecordCmd(CMD_NEW, NULL, topSel, botSel, numObjSelected); RemoveAllSel(); } if (tgifObj->fattr != NULL) { struct AttrRec *saved_fattr=tgifObj->fattr; struct AttrRec *saved_lattr=tgifObj->lattr; tgifObj->fattr = tgifObj->lattr = NULL; AddObj(NULL, topObj, tgifObj); AddNewSelObj(topObj); PrepareToReplaceAnObj(tgifObj); tgifObj->fattr = saved_fattr; tgifObj->lattr = saved_lattr; recordCmdIncludeTgifObj = TRUE; RecordReplaceAnObj(tgifObj); recordCmdIncludeTgifObj = FALSE; UnlinkObj(topObj); FreeTopSel(); EndCompositeCmd(); } } if (pn_need_to_check_auto_exec != NULL) { *pn_need_to_check_auto_exec = need_to_check_auto_exec; } } void AfterOpenURL(need_to_check_auto_exec) int need_to_check_auto_exec; { if (need_to_check_auto_exec) { struct AttrRec *exec_attr=FindFileAttrWithName("auto_exec="); if (exec_attr != NULL) { DoExecLoop(NULL, exec_attr); } } } void OpenProc(psz_fname_spec) char *psz_fname_spec; { char file_name[MAXPATHLENGTH+1]; int do_not_save=FALSE, need_to_check_auto_exec=FALSE; if (!BeforeOpenURL(&do_not_save)) { return; } if (psz_fname_spec != NULL && strcmp(psz_fname_spec, "-1") != 0) { int len=strlen(psz_fname_spec); char new_full_name[MAXPATHLENGTH<<2]; if (len > 0 && psz_fname_spec[len-1] == ')') { psz_fname_spec[len-1] = '\0'; UtilStrCpyN(file_name, sizeof(file_name), psz_fname_spec); psz_fname_spec[len-1] = ')'; } else { UtilStrCpyN(file_name, sizeof(file_name), psz_fname_spec); } if (FileIsRemote(file_name)) { OpenURL(file_name, do_not_save, &need_to_check_auto_exec); } else { if (*file_name == DIR_SEP) { strcpy(new_full_name, file_name); } else if (curDirIsLocal) { sprintf(new_full_name, "%s%c%s", curDir, DIR_SEP, file_name); } else { sprintf(new_full_name, "%s%c%s", curLocalDir, DIR_SEP, file_name); } OpenURL(new_full_name, do_not_save, &need_to_check_auto_exec); } } else { if (SelectFileName(TgLoadString(STID_SELECT_A_FILE_TO_OPEN), file_name) != INVALID) { OpenURL(file_name, do_not_save, &need_to_check_auto_exec); } else if (do_not_save) { SetFileModified(TRUE); } } AfterOpenURL(need_to_check_auto_exec); } void SetTemplate() { char file_name[MAXPATHLENGTH+1], *rest=NULL; int short_name, rc; FILE *fp=NULL; struct AttrRec *attr_ptr=NULL; struct SelRec *saved_top_sel=NULL, *saved_bot_sel=NULL; if (gstWBInfo.do_whiteboard) { /* * Now it's allowed. * * MsgBox(TgLoadString(STID_SETTEMPLATE_IN_WB), TOOL_NAME, INFO_MB); * return; */ } MakeQuiescent(); if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_AN_OBJ_FILE_TO_IMPORT), OBJ_FILE_EXT, name, path) == INVALID) { return; } sprintf(file_name, "%s%c%s", path, DIR_SEP, name); } else { sprintf(gszMsgBox, TgLoadString(STID_SELECT_FILE_AS_TEMPLATE)); if (SelectFileNameToImport(gszMsgBox, OBJ_FILE_EXT, file_name) == INVALID) { return; } else if (FileIsRemote(file_name)) { MsgBox(TgLoadString(STID_NOT_SUP_REMOTE_TEMPLATE_FILE), TOOL_NAME, INFO_MB); return; } } if (FileIsRemote(file_name)) { MsgBox(TgLoadString(STID_NOT_SUP_REMOTE_TEMPLATE_FILE), TOOL_NAME, INFO_MB); return; } if ((short_name=IsPrefix(bootDir, file_name, &rest))) ++rest; if ((fp=fopen(file_name, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_STILL_TEMPLATE), (short_name ? rest : file_name)); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) != MB_ID_YES) { return; } } else { fclose(fp); } StartCompositeCmd(); importingFile = TRUE; rc = ImportGivenFile(file_name, TRUE, TRUE); importingFile = FALSE; if (rc == BAD) { EndCompositeCmd(); return; } else if (rc == FALSE) { sprintf(gszMsgBox, TgLoadString(STID_STILL_USE_AS_TEMPLATE), (short_name ? rest : file_name)); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) != MB_ID_YES) { EndCompositeCmd(); return; } } HighLightReverse(); saved_top_sel = topSel; saved_bot_sel = botSel; topSel = botSel = NULL; UpdSelBBox(); if ((attr_ptr=FindAttrWithName(tgifObj, "template=", NULL)) != NULL) { ReplaceAttrFirstValue(tgifObj, attr_ptr, short_name ? rest : file_name); } else { int x=tgifObj->obbox.ltx, y=tgifObj->obbox.rby; AddObj(NULL, topObj, tgifObj); UpdSelBBox(); PrepareToReplaceAnObj(tgifObj); attr_ptr = AddAttrByNameAndValue(tgifObj, "template=", short_name ? rest : file_name); attr_ptr->shown = TRUE; attr_ptr->obj->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(attr_ptr->obj->color_str, sizeof(attr_ptr->obj->color_str), colorMenuItems[colorIndex]); } MoveObj(attr_ptr->obj, x-attr_ptr->obj->x, y-attr_ptr->obj->y); UpdTextBBox(attr_ptr->obj); AdjObjBBox(tgifObj); recordCmdIncludeTgifObj = TRUE; RecordReplaceAnObj(tgifObj); recordCmdIncludeTgifObj = FALSE; RemoveAllSel(); UnlinkObj(topObj); UpdSelBBox(); SetFileModified(TRUE); justDupped = FALSE; } EndCompositeCmd(); sprintf(gszMsgBox, TgLoadString(STID_TEMPLATE_SET_TO), (short_name ? rest : file_name)); Msg(gszMsgBox); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); HighLightForward(); SetCurChoice(curChoiceBeforeMakeQuiescent); } /* do not translate -- program constants */ char * fileMenuStr[] = { "New ^n", "Open ^o", "Save ^s", "SaveNew ^#s", "Import #p", "ImportXBitmap ^#.", "ImportXPixmap ^#,", "ImportEPSFile #(", "ImportGIFFile ", "ImportOtherFile ", "EmbedEPSFile ", "BrowseXBitmap ", "BrowseXPixmap ", "BrowseOther ", "ChangeDomain ^c", "Print ^p", "PrintWithCmd ^-", "PrintSelectedObjs ", "PrintOnePage ", "SetExportPixelTrim", "InputPolyPts ", "InputPolygonPts ", "SetTemplate ", "Solve #s", "Simulate #y", "Probe #b", "Animate ^z", "Escape #x", "SaveSelectedAs #~", "SaveSymInLibrary ", "Quit ^q", NULL }; int QuitProc() { int do_not_save=FALSE; while (!DirIsRemote(curDir) && fileModified && !IsFiletUnSavable()) { XBell(mainDisplay, 0); switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_QUIT), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: do_not_save = TRUE; SetFileModified(FALSE); break; case MB_ID_CANCEL: return INVALID; } } if (!DirIsRemote(curDir) && fileModified && IsFiletUnSavable()) { do_not_save = TRUE; SetFileModified(FALSE); } if (AncesterModified()) { switch (MsgBox(TgLoadString(STID_ANCESTER_MOD_STILL_QUIT), TOOL_NAME, YNC_MB)) { case MB_ID_YES: return FILE_QUIT; case MB_ID_NO: if (do_not_save) SetFileModified(TRUE); return INVALID; case MB_ID_CANCEL: if (do_not_save) SetFileModified(TRUE); return INVALID; } } gnQuit = TRUE; return FILE_QUIT; } int SolveProc() { if (!saveTmpOnReturn) return FILE_SOLVE; switch (SaveTmpFile("tmpmodel")) { case OBJ_FILE_TYPE: return FILE_SOLVE; case SYM_FILE_TYPE: return INVALID; case PIN_FILE_TYPE: return INVALID; case INVALID: return INVALID; } return INVALID; } int SimulateProc() { if (!saveTmpOnReturn) return FILE_SIMULATE; switch (SaveTmpFile("tmpmodel")) { case OBJ_FILE_TYPE: return FILE_SIMULATE; case SYM_FILE_TYPE: return INVALID; case PIN_FILE_TYPE: return INVALID; case INVALID: return INVALID; } return INVALID; } int ProbeProc() { if (!saveTmpOnReturn) return FILE_PROBE; switch (SaveTmpFile("tmpmodel")) { case OBJ_FILE_TYPE: return FILE_PROBE; case SYM_FILE_TYPE: return INVALID; case PIN_FILE_TYPE: return INVALID; case INVALID: return INVALID; } return INVALID; } int AnimateProc() { if (!saveTmpOnReturn) return FILE_ANIMATE; switch (SaveTmpFile("tmpmodel")) { case OBJ_FILE_TYPE: return FILE_ANIMATE; case SYM_FILE_TYPE: return INVALID; case PIN_FILE_TYPE: return INVALID; case INVALID: return INVALID; } return INVALID; } int EscapeProc() { return FILE_ESCAPE; } int RefreshFileMenu(menu) TgMenu *menu; { int ok=TRUE, allow_print_pages=TRUE; /* Print/Export In Color */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEBWCOLORPS, colorDump); /* Print With Cmd */ ok &= TgEnableMenuItemById(menu, CMDID_PRINTWITHCMD, (whereToPrint==PRINTER)); /* * Print Pages - only allows PRINTER, PS_FILE, PDF_FILE, or user supplied * export filters */ if (pageLayoutMode == PAGE_TILE) { allow_print_pages = FALSE; } else { switch (whereToPrint) { case LATEX_FIG: case XBM_FILE: case TEXT_FILE: case NETLIST_FILE: case EPSI_FILE: case GIF_FILE: case HTML_FILE: case TIFFEPSI_FILE: case PNG_FILE: case JPEG_FILE: case PPM_FILE: case SVG_FILE: allow_print_pages = FALSE; break; default: break; } } ok &= TgEnableMenuItemById(menu, CMDID_PRINTPAGES, allow_print_pages); /* Print One File Per Page */ ok &= TgEnableMenuItemById(menu, CMDID_PRINTONEFILEPERPAGE, (pageLayoutMode == PAGE_STACK && whereToPrint != PRINTER)); return ok; } TgMenu *CreateFileMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshFileMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshFileMenu); } return menu; } int FileMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(fileMenuInfo.create_proc)(NULL, X, Y, &fileMenuInfo, INVALID); activeMenu = MENU_FILE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } TgMenu *CreateRecentFilesMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { int i=0, count=0; TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; KeyValInfo *pkvi=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); pkvi = RecentFilesListing(&count); if (pkvi == NULL || count == 0) { count = 0; stMenuInfo.items = (TgMenuItemInfo*)malloc((1+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (1+1)*sizeof(TgMenuItemInfo)); item_info = stMenuInfo.items; item_info->menu_str = UtilStrDup(TgLoadCachedString(CSTID_PARANED_EMPTY)); if (item_info->menu_str == NULL) FailAllocMessage(); item_info->shortcut_str = NULL; item_info->status_str = UtilStrDup(""); if (item_info->status_str == NULL) FailAllocMessage(); item_info->submenu_info = NULL; item_info->cmdid = CMDID_RECENTLYUSEDFILES; stMenuInfo.items[1].cmdid = INVALID; } else { stMenuInfo.items = (TgMenuItemInfo*)malloc( (count+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (count+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < count; item_info++, i++) { sprintf(gszMsgBox, "%2d. %s", i+1, pkvi[i].key); item_info->menu_str = UtilStrDup(gszMsgBox); if (item_info->menu_str == NULL) FailAllocMessage(); item_info->shortcut_str = NULL; sprintf(gszMsgBox, TgLoadCachedString(CSTID_OPEN_FILE), pkvi[i].value); item_info->status_str = UtilStrDup(gszMsgBox); if (item_info->status_str == NULL) FailAllocMessage(); item_info->submenu_info = NULL; item_info->cmdid = CMDID_RECENTLYUSEDFILES; } stMenuInfo.items[count].cmdid = INVALID; } /* the status_str has actual file names, no tralslation needed */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); if (count == 0) { UtilFree(stMenuInfo.items->status_str); memset(stMenuInfo.items, 0, (1+1)*sizeof(TgMenuItemInfo)); } else { for (item_info=stMenuInfo.items, i=0; i < count; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (count+1)*sizeof(TgMenuItemInfo)); } free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { if (count == 0) { TgEnableMenuItemByIndex(menu, 0, FALSE); menu->menuitems[0].menu_str_allocated = TRUE; } else { for (i=0; i < count; i++) { menu->menuitems[i].menu_str_allocated = TRUE; } } } FreeRecentFilesListing(pkvi, count); return menu; } char *ReadFileIntoBuf(fname, pn_buf_sz) char *fname; unsigned int *pn_buf_sz; { struct stat stat_buf; if (stat(fname, &stat_buf) == 0) { char *psz=NULL, buf[0x10000], *psz_return=NULL; FILE *fp=NULL; unsigned int bytes_to_read=0, file_size=0, bytes_read=0, total_read=0; if ((fp=fopen(fname, "r")) == NULL) { FailToOpenMessage(fname, "r", NULL); return NULL; } file_size = (unsigned int)(stat_buf.st_size); psz = psz_return = (char*)malloc(file_size); if (psz_return == NULL) FailAllocMessage(); bytes_to_read = min(file_size, sizeof(buf)); while ((bytes_read=fread(psz, sizeof(char), bytes_to_read, fp)) > 0) { total_read += bytes_read; psz += bytes_read; file_size -= bytes_read; bytes_to_read = min(file_size, sizeof(buf)); if (bytes_to_read == 0) break; } fclose(fp); if (total_read == (unsigned int)(stat_buf.st_size)) { if (pn_buf_sz != NULL) *pn_buf_sz = total_read; } return psz_return; } return NULL; } int WriteBufIntoTmpFile(buf, buf_sz, tmp_fname, tmp_fname_sz) char *buf, *tmp_fname; int buf_sz, tmp_fname_sz; { FILE *fp=NULL; if (MkTempFile(tmp_fname, tmp_fname_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } if ((fp=fopen(tmp_fname, "w")) == NULL) { return FailToOpenMessage(tmp_fname, "w", NULL); } if ((int)fwrite(buf, sizeof(char), buf_sz, fp) != buf_sz) { fclose(fp); return FailToWriteFileMessage(tmp_fname); } fclose(fp); return TRUE; } void CleanUpFiles() { UtilFree(gpszPsSetup); gpszPsSetup = NULL; ClearBgColorInfo(FALSE); ClearBgPixmapInfo(FALSE); CleanUpDumpInitDefaults(); ClearFileInfo(TRUE); if (usePaperSizeStoredInFile) ResetOnePageSize(); fileModified = FALSE; } ���������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/prtgif.man���������������������������������������������������������������������������0000644�0000764�0000764�00000001204�11602233312�014751� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������.\"@(#)$Header: /mm2/home/cvs/bc-src/tgif/prtgif.man,v 1.1 2004/06/18 23:20:49 william Exp $ .TH PRTGIF n "Version 2.12-p12 or above" "PrTgif" .SH NAME \fI(OBSOLETED) prtgif\fR - Prints a \fItgif\fR object file without opening windows or fonts. .SH SYNOPSIS .B prtgif [\fB-eps\fR] [\fB-p\fR] [\fB-ps\fR] [\fB-f\fR] [\fB-gray\fR] [\fB-adobe\fR] [\fB-o\fRdir] [\fIfile1\fR \fIfile2\fR ...] .SH DESCRIPTION \fIPrtgif\fR is obsoleted to conserve space. Please use the equivalent form, "\fItgif -print\fR", instead. (Prtgif will still work, all it does is to run "tgif -print".) Please see the man pages of tgif for a description of the options. ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/animate.c����������������������������������������������������������������������������0000644�0000764�0000764�00000021045�11602233310�014546� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/animate.c,v 1.6 2011/05/16 16:21:56 william Exp $ */ #define _INCLUDE_FROM_ANIMATE_C_ #include "tgifdefs.h" #include "animate.e" #include "color.e" #include "dialog.e" #include "msg.e" #include "poly.e" #include "raster.e" #include "select.e" #include "setup.e" #include "strtbl.e" #define SEND_SPEED 8 #define TOKEN_R 8 static XPoint savedToken[5]; void AnimateSend(PolyPtr, Speed, Pixel) struct PolyRec *PolyPtr; int Speed, Pixel; { register int delta, i; register XPoint *token; int x, y, num_pts, j, x_dist, y_dist; IntPoint *v; struct BBRec bbox; double slope, delta_x, delta_y; XGCValues values; values.foreground = Pixel; values.function = GXxor; values.line_style = FillSolid; #ifdef NO_THIN_LINE values.line_width = 1; #else values.line_width = 0; #endif XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCLineStyle | GCLineWidth, &values); bbox.ltx = 0; bbox.lty = 0; bbox.rbx = 2*TOKEN_R; bbox.rby = 2*TOKEN_R; num_pts = PolyPtr->n; v = PolyPtr->vlist; token = (XPoint *)malloc(5*sizeof(XPoint)); if (token == NULL) FailAllocMessage(); for (j = 0; j < num_pts-1; j++) { x = OFFSET_X(v[j].x); y = OFFSET_Y(v[j].y); token[0].x = (short)(x - TOKEN_R); token[0].y = (short)(y - TOKEN_R); token[1].x = (short)(x + TOKEN_R); token[1].y = (short)(y - TOKEN_R); token[2].x = (short)(x + TOKEN_R); token[2].y = (short)(y + TOKEN_R); token[3].x = (short)(x - TOKEN_R); token[3].y = (short)(y + TOKEN_R); token[4].x = (short)(x - TOKEN_R); token[4].y = (short)(y - TOKEN_R); XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); if (v[j].x == v[j+1].x) { /* moving vertical */ if ((y_dist = ZOOMED_SIZE(v[j+1].y-v[j].y)) > 0) { /* moving down */ for (delta = 0; delta < y_dist; delta += Speed) { XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); for (i = 0; i < 5; i++) token[i].y += Speed; XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); } } else { /* moving up */ for (delta = y_dist; delta < 0; delta += Speed) { XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); for (i = 0; i < 5; i++) token[i].y -= Speed; XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); } } } else if (v[j].y == v[j+1].y) { /* moving horizontal */ if ((x_dist = ZOOMED_SIZE(v[j+1].x-v[j].x)) > 0) { /* moving right */ for (delta = 0; delta < x_dist; delta += Speed) { XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); for (i = 0; i < 5; i++) token[i].x += Speed; XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); } } else { /* moving left */ for (delta = x_dist; delta < 0; delta += Speed) { XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); for (i = 0; i < 5; i++) token[i].x -= Speed; XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); } } } else { /* moving diagonally */ x_dist = ZOOMED_SIZE(v[j+1].x-v[j].x); y_dist = ZOOMED_SIZE(v[j+1].y-v[j].y); for (i = 0; i < 5; i++) { savedToken[i].x = token[i].x; savedToken[i].y = token[i].y; } if (abs(x_dist) > abs(y_dist)) { /* moving in the x direction */ slope = ((double)y_dist) / ((double)x_dist); if (x_dist > 0) { /* moving right */ for (delta = 0; delta < x_dist; delta += Speed) { XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); delta_y = slope * ((double)delta); for (i = 0; i < 5; i++) { token[i].x = savedToken[i].x + delta; token[i].y = savedToken[i].y + delta_y; } XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); } } else { /* moving left */ for (delta = 0; delta > x_dist; delta -= Speed) { XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); delta_y = slope * ((double)delta); for (i = 0; i < 5; i++) { token[i].x = savedToken[i].x + delta; token[i].y = savedToken[i].y + delta_y; } XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); } } } else { /* moving in the y direction */ slope = ((double)x_dist) / ((double)y_dist); if (y_dist > 0) { /* moving down */ for (delta = 0; delta < y_dist; delta += Speed) { XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); delta_x = slope * ((double)delta); for (i = 0; i < 5; i++) { token[i].x = savedToken[i].x + delta_x; token[i].y = savedToken[i].y + delta; } XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); } } else { /* moving up */ for (delta = 0; delta > y_dist; delta -= Speed) { XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); delta_x = slope * ((double)delta); for (i = 0; i < 5; i++) { token[i].x = savedToken[i].x + delta_x; token[i].y = savedToken[i].y + delta; } XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); } } } } XFillPolygon(mainDisplay, drawWindow, drawGC, token, 5, Convex, CoordModeOrigin); } free(token); } void AnimateSel() { if (topSel != botSel || topSel == NULL || topSel->obj->type != OBJ_POLY) { MsgBox(TgLoadString(STID_SELECT_ONLY_ONE_POLY), TOOL_NAME, INFO_MB); return; } AnimateSend(topSel->obj->detail.p, SEND_SPEED, xorColorPixels[topSel->obj->color]); } void AnimateFlashColor(ObjPtr, ColorIndex) struct ObjRec *ObjPtr; int ColorIndex; { int saved_color_index = ObjPtr->color; ObjPtr->color = ColorIndex; DrawPolyObj(drawWindow, drawOrigX, drawOrigY, ObjPtr); ObjPtr->color = saved_color_index; DrawPolyObj(drawWindow, drawOrigX, drawOrigY, ObjPtr); } void FlashSelColor() /* This routine is kind of stupid. It's left for compatibity reason. */ { register int i; if (topSel != botSel || topSel == NULL || topSel->obj->type != OBJ_POLY) { MsgBox(TgLoadString(STID_SELECT_ONLY_ONE_POLY), TOOL_NAME, INFO_MB); return; } for (i = 0; i < maxColors; i++) { if (strcmp("white", colorMenuItems[i]) == 0) { break; } } AnimateFlashColor(topSel->obj, i); } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/wb2.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000001114�11602233313�013622� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Renato Santana, <renato@nce.ufrj.br> in January, 1996. * * (Obsoleted in tgif-4.1.9 by the TangramII group at land.ufrj.br.) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb2.e,v 1.1 2004/06/18 23:19:10 william Exp $ */ #ifdef _TGIF_WB #ifndef _WB2_E_ #define _WB2_E_ #ifdef _INCLUDE_FROM_WB2_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_WB2_C_*/ #ifdef _INCLUDE_FROM_WB2_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_WB2_C_*/ #endif /*_WB2_E_*/ #endif /* _TGIF_WB */ ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/cli_xcin.c���������������������������������������������������������������������������0000644�0000764�0000764�00000000000�11602233314�014710� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/config.h.in��������������������������������������������������������������������������0000644�0000764�0000764�00000016544�11602233374�015031� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* config.h.in. Generated from configure.ac by autoheader. */ /* Define to 1 if the `closedir' function returns void instead of `int'. */ #undef CLOSEDIR_VOID /* Define to 1 if you have the <arpa/inet.h> header file. */ #undef HAVE_ARPA_INET_H /* Define to 1 if you have the <dirent.h> header file, and it defines `DIR'. */ #undef HAVE_DIRENT_H /* Define to 1 if you have the <fcntl.h> header file. */ #undef HAVE_FCNTL_H /* Define to 1 if you have the `fork' function. */ #undef HAVE_FORK /* Define to 1 if you have the `ftime' function. */ #undef HAVE_FTIME /* Define to 1 if you have the `getcwd' function. */ #undef HAVE_GETCWD /* Define to 1 if you have the `gethostbyname' function. */ #undef HAVE_GETHOSTBYNAME /* Define to 1 if you have the `gethostname' function. */ #undef HAVE_GETHOSTNAME /* Define to 1 if you have the `gettimeofday' function. */ #undef HAVE_GETTIMEOFDAY /* Define to 1 if you have the <inttypes.h> header file. */ #undef HAVE_INTTYPES_H /* Define to 1 if you have the `dl' library (-ldl). */ #undef HAVE_LIBDL /* Define to 1 if you have the `idn' library (-lidn). */ #undef HAVE_LIBIDN /* Define to 1 if you have the <libintl.h> header file. */ #undef HAVE_LIBINTL_H /* Define to 1 if you have the `m' library (-lm). */ #undef HAVE_LIBM /* Define to 1 if you have the `nsl' library (-lnsl). */ #undef HAVE_LIBNSL /* Define to 1 if you have the `pthread' library (-lpthread). */ #undef HAVE_LIBPTHREAD /* Define to 1 if you have the `socket' library (-lsocket). */ #undef HAVE_LIBSOCKET /* Define to 1 if you have the `X11' library (-lX11). */ #undef HAVE_LIBX11 /* Define to 1 if you have the `Xt' library (-lXt). */ #undef HAVE_LIBXT /* Define to 1 if you have the `z' library (-lz). */ #undef HAVE_LIBZ /* Define to 1 if `lstat' has the bug that it succeeds when given the zero-length file name argument. */ #undef HAVE_LSTAT_EMPTY_STRING_BUG /* Define to 1 if your system has a GNU libc compatible `malloc' function, and to 0 otherwise. */ #undef HAVE_MALLOC /* Define to 1 if you have the `memmove' function. */ #undef HAVE_MEMMOVE /* Define to 1 if you have the <memory.h> header file. */ #undef HAVE_MEMORY_H /* Define to 1 if you have the `memset' function. */ #undef HAVE_MEMSET /* Define to 1 if you have the `mkdir' function. */ #undef HAVE_MKDIR /* Define to 1 if you have the <ndir.h> header file, and it defines `DIR'. */ #undef HAVE_NDIR_H /* Define to 1 if you have the <netdb.h> header file. */ #undef HAVE_NETDB_H /* Define to 1 if you have the <netinet/in.h> header file. */ #undef HAVE_NETINET_IN_H /* Define to 1 if you have the `pow' function. */ #undef HAVE_POW /* Define to 1 if you have the `putenv' function. */ #undef HAVE_PUTENV /* Define to 1 if your system has a GNU libc compatible `realloc' function, and to 0 otherwise. */ #undef HAVE_REALLOC /* Define to 1 if you have the `select' function. */ #undef HAVE_SELECT /* Define to 1 if you have the `setlocale' function. */ #undef HAVE_SETLOCALE /* Define to 1 if you have the `socket' function. */ #undef HAVE_SOCKET /* Define to 1 if you have the `sqrt' function. */ #undef HAVE_SQRT /* Define to 1 if `stat' has the bug that it succeeds when given the zero-length file name argument. */ #undef HAVE_STAT_EMPTY_STRING_BUG /* Define to 1 if you have the <stdint.h> header file. */ #undef HAVE_STDINT_H /* Define to 1 if you have the <stdlib.h> header file. */ #undef HAVE_STDLIB_H /* Define to 1 if you have the `strchr' function. */ #undef HAVE_STRCHR /* Define to 1 if you have the <strings.h> header file. */ #undef HAVE_STRINGS_H /* Define to 1 if you have the <string.h> header file. */ #undef HAVE_STRING_H /* Define to 1 if you have the `strpbrk' function. */ #undef HAVE_STRPBRK /* Define to 1 if you have the `strrchr' function. */ #undef HAVE_STRRCHR /* Define to 1 if you have the `strstr' function. */ #undef HAVE_STRSTR /* Define to 1 if you have the `strtol' function. */ #undef HAVE_STRTOL /* Define to 1 if you have the <sys/dir.h> header file, and it defines `DIR'. */ #undef HAVE_SYS_DIR_H /* Define to 1 if you have the <sys/file.h> header file. */ #undef HAVE_SYS_FILE_H /* Define to 1 if you have the <sys/ioctl.h> header file. */ #undef HAVE_SYS_IOCTL_H /* Define to 1 if you have the <sys/ndir.h> header file, and it defines `DIR'. */ #undef HAVE_SYS_NDIR_H /* Define to 1 if you have the <sys/select.h> header file. */ #undef HAVE_SYS_SELECT_H /* Define to 1 if you have the <sys/socket.h> header file. */ #undef HAVE_SYS_SOCKET_H /* Define to 1 if you have the <sys/stat.h> header file. */ #undef HAVE_SYS_STAT_H /* Define to 1 if you have the <sys/timeb.h> header file. */ #undef HAVE_SYS_TIMEB_H /* Define to 1 if you have the <sys/time.h> header file. */ #undef HAVE_SYS_TIME_H /* Define to 1 if you have the <sys/types.h> header file. */ #undef HAVE_SYS_TYPES_H /* Define to 1 if you have <sys/wait.h> that is POSIX.1 compatible. */ #undef HAVE_SYS_WAIT_H /* Define to 1 if you have the <unistd.h> header file. */ #undef HAVE_UNISTD_H /* Define to 1 if you have the `vfork' function. */ #undef HAVE_VFORK /* Define to 1 if you have the <vfork.h> header file. */ #undef HAVE_VFORK_H /* Define to 1 if `fork' works. */ #undef HAVE_WORKING_FORK /* Define to 1 if `vfork' works. */ #undef HAVE_WORKING_VFORK /* Define to 1 if `lstat' dereferences a symlink specified with a trailing slash. */ #undef LSTAT_FOLLOWS_SLASHED_SYMLINK /* Name of package */ #undef PACKAGE /* Define to the address where bug reports for this package should be sent. */ #undef PACKAGE_BUGREPORT /* Define to the full name of this package. */ #undef PACKAGE_NAME /* Define to the full name and version of this package. */ #undef PACKAGE_STRING /* Define to the one symbol short name of this package. */ #undef PACKAGE_TARNAME /* Define to the version of this package. */ #undef PACKAGE_VERSION /* Define as the return type of signal handlers (`int' or `void'). */ #undef RETSIGTYPE /* Define to the type of arg 1 for `select'. */ #undef SELECT_TYPE_ARG1 /* Define to the type of args 2, 3 and 4 for `select'. */ #undef SELECT_TYPE_ARG234 /* Define to the type of arg 5 for `select'. */ #undef SELECT_TYPE_ARG5 /* Define to 1 if you have the ANSI C header files. */ #undef STDC_HEADERS /* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */ #undef TIME_WITH_SYS_TIME /* Version number of package */ #undef VERSION /* Define for Solaris 2.5.1 so the uint32_t typedef from <sys/synch.h>, <pthread.h>, or <semaphore.h> is not used. If the typedef was allowed, the #define below would cause a syntax error. */ #undef _UINT32_T /* Define to empty if `const' does not conform to ANSI C. */ #undef const /* Define to rpl_malloc if the replacement function should be used. */ #undef malloc /* Define to `int' if <sys/types.h> does not define. */ #undef mode_t /* Define to `int' if <sys/types.h> does not define. */ #undef pid_t /* Define to rpl_realloc if the replacement function should be used. */ #undef realloc /* Define to `unsigned int' if <sys/types.h> does not define. */ #undef size_t /* Define to the type of an unsigned integer type of width exactly 16 bits if such a type exists and the standard includes do not define it. */ #undef uint16_t /* Define to the type of an unsigned integer type of width exactly 32 bits if such a type exists and the standard includes do not define it. */ #undef uint32_t /* Define as `fork' if `vfork' does not work. */ #undef vfork ������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/eps.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000004361�11602233311�013724� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/eps.e,v 1.6 2011/05/16 16:21:57 william Exp $ */ #ifndef _EPS_E_ #define _EPS_E_ extern float defaultEPSScaling; extern char defaultEPSScalingStr[]; extern int autoEPSPreviewBitmap; #ifdef _INCLUDE_FROM_EPS_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_EPS_C_*/ extern void InitEPS ARGS_DECL((void)); extern void CleanUpEPS ARGS_DECL((void)); extern int MyReadEPSFile ARGS_DECL((char *FileName, int *ImageW, int *ImageH, Pixmap *, XImage **, int *NumLines, char ***EPSFLines, int *EPSFLevel, float *llx, float *lly, float *urx, float *ury, char *Date)); extern void DumpEPSObj ARGS_DECL((FILE *, struct ObjRec *)); extern void SetEPSObjCTM ARGS_DECL((struct ObjRec *, struct BBRec *)); extern struct ObjRec * CreateEPSObj ARGS_DECL((char *FileName, int ImageW, int ImageH, Pixmap, XImage *, int NumLines, char **Lines, int EPSFLevel, float *llx, float *lly, float *urx, float *ury, char *Date)); extern void UpdateEPS ARGS_DECL((void)); #ifdef _INCLUDE_FROM_EPS_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_EPS_C_*/ #endif /*_EPS_E_*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/wb3.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000001114�11602233313�013623� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Renato Santana, <renato@nce.ufrj.br> in Januray, 1996. * * (Obsoleted in tgif-4.1.9 by the TangramII group at land.ufrj.br.) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb3.e,v 1.1 2004/06/18 23:19:10 william Exp $ */ #ifdef _TGIF_WB #ifndef _WB3_E_ #define _WB3_E_ #ifdef _INCLUDE_FROM_WB3_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_WB3_C_*/ #ifdef _INCLUDE_FROM_WB3_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_WB3_C_*/ #endif /*_WB3_E_*/ #endif /* _TGIF_WB */ ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/msg.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000221010�11602233312�013712� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/msg.c,v 1.49 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_MSG_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "auxtext.e" #include "button.e" #include "chat.e" #include "cutpaste.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "file.e" #include "font.e" #include "grid.e" #include "inmethod.e" #include "mainloop.e" #include "markup.e" #include "menu.e" #include "msg.e" #include "navigate.e" #include "pattern.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "remote.e" #include "rm_intrf.e" #include "setup.e" #include "strtbl.e" #include "tangram2.e" #include "text.e" #include "util.e" #include "version.e" #include "wb.e" #include "xbitmap.e" #include "xbm/redraw.xbm" char scanFileFullPath[MAXPATHLENGTH+1]; char scanFileName[MAXPATHLENGTH+1]; int scanLineNum=0; char progName[MAXPATHLENGTH+1]; char fatalMsgBuf1[MAXSTRING<<1]; char fatalMsgBuf2[MAXSTRING<<1]; int cmdLineParentWindowID=0; int cmdLineTgrm2=FALSE; int cmdLineWb2=FALSE; struct MsgRec { char * s; struct MsgRec * next, * prev; }; static struct MsgRec * topMsg = NULL, * botMsg = NULL; static struct MsgRec * mostRecentTopMsgPtr = NULL; static int msgCount = 0; static int topMsgNumber = 0, mostRecentTopMsgNumber = INVALID; static int firstCharPos = 0; static int reverseMouseStatusButtons=FALSE; static int gnMsgRows=2; int ShowOrPrintMsg(buf, use_msgbox) char *buf; int use_msgbox; { if (PRTGIF && !cmdLineOpenDisplay) { fprintf(stderr, "%s\n", buf); } else if (use_msgbox) { MsgBox(buf, TOOL_NAME, INFO_MB); } else { Msg(buf); } return FALSE; } int FailAllocMessage() { fprintf(stderr, "%s\n", TgLoadString(STID_OUT_OF_VMEM_CANNOT_MALLOC)); fflush(stderr); return FALSE; } int FailAllocBitmapMessage(w, h) int w, h; { fprintf(stderr, TgLoadString(STID_CANT_ALLOC_BITMAP_OF_SIZE), w, h); fprintf(stderr, "\n"); fflush(stderr); return FALSE; } int FailAllocPixmapMessage(w, h) int w, h; { fprintf(stderr, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), w, h); fprintf(stderr, "\n"); fflush(stderr); return FALSE; } int FailToWriteFileMessage(file_name) char *file_name; { if (PRTGIF) { fprintf(stderr, TgLoadString(STID_FAIL_TO_WRITE_TO_FILE), file_name); fprintf(stderr, "\n"); } else { char msg[MAXPATHLENGTH<<1]; sprintf(msg, TgLoadString(STID_FAIL_TO_WRITE_TO_FILE), file_name); MsgBox(msg, TOOL_NAME, INFO_MB); } return FALSE; } int FailToOpenMessage(file_name, rwa, extra_msg) char *file_name, *rwa, *extra_msg; /* rwa is either "r", "w", or "a" */ { char msg[MAXPATHLENGTH<<1]; int msgid=0; switch (*rwa) { case 'r': msgid = STID_CANNOT_OPEN_FILE_FOR_READING; break; case 'w': msgid = STID_CANNOT_OPEN_FILE_FOR_WRITING; break; case 'a': msgid = STID_CANNOT_OPEN_FILE_FOR_APPEND; break; default: msgid = INVALID; break; } if (extra_msg == NULL) { sprintf(msg, TgLoadString(msgid), file_name); if (PRTGIF) { fprintf(stderr, "%s\n", msg); } else { MsgBox(msg, TOOL_NAME, INFO_MB); } } else { sprintf(msg, TgLoadString(msgid), file_name); strcat(msg, " "); strcat(msg, extra_msg); if (PRTGIF) { fprintf(stderr, "%s\n", msg); } else { MsgBox(msg, TOOL_NAME, INFO_MB); } } return FALSE; } int FailToCreateWindowMessage(where, win_name, do_exit) char *where, *win_name; int do_exit; { char msg[MAXSTRING<<1]; if (win_name == NULL) { strcpy(msg, TgLoadString(STID_FAIL_TO_CREATE_WINDOW)); } else { sprintf(msg, TgLoadString(STID_FAIL_TO_CREATE_NAMED_WINDOW), win_name); } if (do_exit) { Error(where, msg); } fprintf(stderr, "%s\n", msg); return FALSE; } int FatalUnexpectedError(msg1, msg2) char *msg1, *msg2; { char buf[2048]; if (msg2 == NULL) { fprintf(stderr, "%s\n", msg1); } else { fprintf(stderr, "%s\n%s\n", msg1, msg2); } fprintf(stderr, TgLoadString(STID_SAFEST_SAVE_N_EXIT_REPRODUCE), authorEmailString); fprintf(stderr, "\n"); fflush(stderr); sprintf(buf, TgLoadString(STID_FATAL_UNEXPECTED_ERROR), msg1, (msg2==NULL ? "" : "\n"), (msg2==NULL ? "" : msg2), authorEmailString); MsgBox(buf, TOOL_NAME, STOP_MB); XFlush(mainDisplay); XSync(mainDisplay, False); return FALSE; } int TgAssert(must_be_true, msg1, msg2) int must_be_true; char *msg1, *msg2; { if (must_be_true) return TRUE; FatalUnexpectedError(msg1, msg2); return FALSE; } int BoldMsgCharBytes(pszStr) char *pszStr; { #ifdef ENABLE_NLS if (boldMsgFontDoubleByte) { if ((*pszStr) & 0x80) { return 2; } } #endif /* ENABLE_NLS */ return 1; } char *BoldMsgNextChar(pszStr) char *pszStr; { #ifdef ENABLE_NLS if (boldMsgFontDoubleByte) { if ((*pszStr) & 0x80) { return (&pszStr[2]); } } #endif /* ENABLE_NLS */ return (&pszStr[1]); } char *BoldMsgLastChar(pszStr) char *pszStr; { if (*pszStr == '\0') return NULL; #ifdef ENABLE_NLS if (boldMsgFontDoubleByte) { int nLen=strlen(pszStr), nIndex=0; char *pszLast=NULL; while (nIndex < nLen) { int nSubStrIndex=0, nDoubleByte=FALSE; char *psz=NULL, *pszStart=NULL; pszStart = &pszStr[nIndex]; nDoubleByte = ((*pszStart) & 0x80); if (nDoubleByte) { for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && ((*psz)&0x80) == nDoubleByte; psz=(&psz[2]), nSubStrIndex+=2) { pszLast = psz; } } else { for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && ((*psz)&0x80) == 0; psz++, nSubStrIndex++) { pszLast = psz; } } nIndex += nSubStrIndex; } return pszLast; } #endif /* ENABLE_NLS */ return (&pszStr[strlen(pszStr)-1]); } char *BoldMsgStrChr(pszStr, c) char *pszStr; int c; /* c can only be a single-byte char */ { #ifdef ENABLE_NLS if (boldMsgFontDoubleByte) { int nLen=strlen(pszStr), nIndex=0; while (nIndex < nLen) { int nSubStrIndex=0, nDoubleByte=FALSE; char *psz=NULL, *pszStart=NULL; pszStart = &pszStr[nIndex]; nDoubleByte = ((*pszStart) & 0x80); if (nDoubleByte) { for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && ((*psz)&0x80) == nDoubleByte; psz=(&psz[2]), nSubStrIndex+=2) { } } else { for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && ((*psz)&0x80) == 0; psz++, nSubStrIndex++) { if ((int)(*psz) == c) { return psz; } } } nIndex += nSubStrIndex; } return NULL; } #endif /* ENABLE_NLS */ return strchr(pszStr, c); } int MenuTextWidth(font_ptr, psz_str, len) XFontStruct *font_ptr; char *psz_str; int len; { #ifdef ENABLE_NLS if (menuFontSet != NULL) { return XmbTextEscapement(menuFontSet, psz_str, len); } #endif /* ENABLE_NLS */ return XTextWidth(font_ptr, psz_str, len); } int MsgTextWidth(font_ptr, psz_str, len) XFontStruct *font_ptr; char *psz_str; int len; { #ifdef ENABLE_NLS if (msgFontSet != NULL) { return XmbTextEscapement(msgFontSet, psz_str, len); } #endif /* ENABLE_NLS */ return XTextWidth(font_ptr, psz_str, len); } int BoldMsgTextWidth(font_ptr, psz_str, len) XFontStruct *font_ptr; char *psz_str; int len; { #ifdef ENABLE_NLS if (boldMsgFontSet != NULL) { return XmbTextEscapement(boldMsgFontSet, psz_str, len); } #endif /* ENABLE_NLS */ return XTextWidth(font_ptr, psz_str, len); } int ItalicMsgTextWidth(font_ptr, psz_str, len) XFontStruct *font_ptr; char *psz_str; int len; { #ifdef ENABLE_NLS if (italicMsgFontSet != NULL) { return XmbTextEscapement(italicMsgFontSet, psz_str, len); } #endif /* ENABLE_NLS */ return XTextWidth(font_ptr, psz_str, len); } int BoldItalicMsgTextWidth(font_ptr, psz_str, len) XFontStruct *font_ptr; char *psz_str; int len; { #ifdef ENABLE_NLS if (boldItalicMsgFontSet != NULL) { return XmbTextEscapement(boldItalicMsgFontSet, psz_str, len); } #endif /* ENABLE_NLS */ return XTextWidth(font_ptr, psz_str, len); } void DrawMenuString(dpy, win, gc, x, baseline_y, menu_str, len) Display *dpy; Window win; GC gc; int x, baseline_y, len; char *menu_str; { #ifdef ENABLE_NLS if (menuFontSet != NULL) { XmbDrawString(dpy, win, menuFontSet, gc, x, baseline_y, menu_str, len); return; } #endif /* ENABLE_NLS */ XDrawString(dpy, win, gc, x, baseline_y, menu_str, len); } void DrawMsgString(dpy, win, gc, x, baseline_y, msg_str, len) Display *dpy; Window win; GC gc; int x, baseline_y, len; char *msg_str; { #ifdef ENABLE_NLS if (msgFontSet != NULL) { XmbDrawString(dpy, win, msgFontSet, gc, x, baseline_y, msg_str, len); return; } #endif /* ENABLE_NLS */ XDrawString(dpy, win, gc, x, baseline_y, msg_str, len); } void DrawBoldMsgString(dpy, win, gc, x, baseline_y, msg_str, len) Display *dpy; Window win; GC gc; int x, baseline_y, len; char *msg_str; { #ifdef ENABLE_NLS if (boldMsgFontSet != NULL) { XmbDrawString(dpy, win, boldMsgFontSet, gc, x, baseline_y, msg_str, len); return; } #endif /* ENABLE_NLS */ XDrawString(dpy, win, gc, x, baseline_y, msg_str, len); } void DrawItalicMsgString(dpy, win, gc, x, baseline_y, msg_str, len) Display *dpy; Window win; GC gc; int x, baseline_y, len; char *msg_str; { #ifdef ENABLE_NLS if (italicMsgFontSet != NULL) { XmbDrawString(dpy, win, italicMsgFontSet, gc, x, baseline_y, msg_str, len); return; } #endif /* ENABLE_NLS */ XDrawString(dpy, win, gc, x, baseline_y, msg_str, len); } void DrawBoldItalicMsgString(dpy, win, gc, x, baseline_y, msg_str, len) Display *dpy; Window win; GC gc; int x, baseline_y, len; char *msg_str; { #ifdef ENABLE_NLS if (boldItalicMsgFontSet != NULL) { XmbDrawString(dpy, win, boldItalicMsgFontSet, gc, x, baseline_y, msg_str, len); return; } #endif /* ENABLE_NLS */ XDrawString(dpy, win, gc, x, baseline_y, msg_str, len); } static void AddMsg(Msg) char *Msg; { char *s; struct MsgRec *msg_ptr; firstCharPos = 0; if (*Msg == '\0') { topMsgNumber = msgCount; return; } s = (char*)malloc((strlen(Msg)+1)*sizeof(char)); if (s == NULL) FailAllocMessage(); msg_ptr = (struct MsgRec *)malloc(sizeof(struct MsgRec)); if (msg_ptr == NULL) FailAllocMessage(); strcpy(s, Msg); msg_ptr->s = s; ++msgCount; if (msgCount > topMsgNumber+gnMsgRows) topMsgNumber = msgCount-gnMsgRows; msg_ptr->prev = botMsg; msg_ptr->next = NULL; if (botMsg == NULL) { topMsg = msg_ptr; } else { botMsg->next = msg_ptr; } botMsg = msg_ptr; } void CleanUpMsg() { register struct MsgRec *msg_ptr, *prev_msg; for (msg_ptr=botMsg; msg_ptr != NULL; msg_ptr=prev_msg) { prev_msg = msg_ptr->prev; free(msg_ptr->s); free(msg_ptr); } topMsg = botMsg = mostRecentTopMsgPtr = NULL; msgCount = topMsgNumber = firstCharPos = 0; mostRecentTopMsgNumber = INVALID; } static struct MsgRec *FindMsg(Number) int Number; { register int i; register struct MsgRec *ptr; if (Number >= msgCount) { return botMsg; } else if (Number < 0) { return topMsg; } else if (Number > (int)(msgCount/2)) { for (i=msgCount-1, ptr=botMsg; i != Number; i--, ptr=ptr->prev) { } } else { for (i=0, ptr=topMsg; i != Number; i++, ptr=ptr->next) { } } return ptr; } void RedrawMsg(erase_background) int erase_background; { int i, x, y, len; XEvent ev; struct MsgRec *msg_ptr; if (msgWindow == None) return; if (erase_background) { XClearWindow(mainDisplay, msgWindow); XSync(mainDisplay, False); } while (XCheckWindowEvent(mainDisplay, msgWindow, ExposureMask, &ev)) ; if (topMsgNumber == msgCount) { if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, msgWindowW, msgWindowH); TgDrawThreeDButton(mainDisplay, msgWindow, textMenuGC, &bbox, TGBS_LOWRED, 2, TRUE); } return; } x = 2 + windowPadding; y = 2 + ((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontAsc : msgFontAsc) + windowPadding; mostRecentTopMsgPtr = msg_ptr = (topMsgNumber == mostRecentTopMsgNumber) ? mostRecentTopMsgPtr : FindMsg(topMsgNumber); mostRecentTopMsgNumber = topMsgNumber; if (msgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, msgFontPtr->fid); } for (i=topMsgNumber; i < min(msgCount,topMsgNumber+gnMsgRows); i++) { int w=0; len = strlen(msg_ptr->s); if (msgFontSet == NULL && msgFontPtr == NULL) { w = defaultFontWidth*strlen(msg_ptr->s); } else { w = MsgTextWidth(msgFontPtr, msg_ptr->s, len); } if (w > firstCharPos) { DrawMsgString(mainDisplay, msgWindow, defaultGC, x-firstCharPos, y, msg_ptr->s, len); } msg_ptr = msg_ptr->next; y += ((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontHeight : msgFontHeight); } if (msgFontSet != NULL || msgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, defaultFontPtr->fid); } if (erase_background && threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, msgWindowW, msgWindowH); TgDrawThreeDButton(mainDisplay, msgWindow, textMenuGC, &bbox, TGBS_LOWRED, 2, TRUE); } XSync(mainDisplay, False); } void Msg(Message) char *Message; { AddMsg(Message); RedrawMsg(TRUE); } void TwoLineMsg(Msg1, Msg2) char *Msg1, *Msg2; { AddMsg(Msg1); AddMsg(Msg2); RedrawMsg(TRUE); } void PrintMsgBuffer() { char file_name[MAXPATHLENGTH], *rest, msg[MAXSTRING]; FILE *fp; struct MsgRec *msg_ptr; *file_name = '\0'; Dialog(TgLoadString(STID_ENTER_FNAME_TO_WRITE_MSG_BUF), TgLoadString(STID_STDOUT_STDERR_ESC_CANCEL), file_name); UtilTrimBlanks(file_name); if (*file_name == '\0') return; /* do not translate -- program constants */ if (strcmp(file_name, "stdout") == 0) { for (msg_ptr=topMsg; msg_ptr != NULL; msg_ptr=msg_ptr->next) { printf("%s\n", msg_ptr->s); } } else if (strcmp(file_name, "stderr") == 0) { for (msg_ptr=topMsg; msg_ptr != NULL; msg_ptr=msg_ptr->next) { fprintf(stderr, "%s\n", msg_ptr->s); } } else { int short_name; if (!OkayToCreateFile(file_name)) return; if ((short_name=IsPrefix(bootDir, file_name, &rest))) ++rest; if ((fp=fopen(file_name, "w")) == NULL) { sprintf(msg, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), (short_name ? rest : file_name)); MsgBox(msg, TOOL_NAME, INFO_MB); return; } writeFileFailed = FALSE; for (msg_ptr=topMsg; msg_ptr != NULL; msg_ptr=msg_ptr->next) { if (fprintf(fp, "%s\n", msg_ptr->s) == EOF) { writeFileFailed = TRUE; } } fclose(fp); if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(file_name); } else { sprintf(msg, TgLoadString(STID_MSG_BUF_SAVED_INTO_GIVEN), (short_name ? rest : file_name)); MsgBox(msg, TOOL_NAME, INFO_MB); } } } #include "xbm/btn1.xbm" static int oneLineStatus=FALSE; static char btnStatusStr[MAX_STATUS_BTNS][MAXSTRING+1]; static char oneLineStatusStr[MAXSTRING+1]; static void RedrawStatusStrings() { register int i; struct BBRec bbox; if (PRTGIF || noStatusWindow || statusWindow==None) return; if (oneLineStatus) { int y; XClearWindow(mainDisplay, statusWindow); if (threeDLook) { SetBBRec(&bbox, 0, 0, statusWindowW, statusWindowH); TgDrawThreeDButton(mainDisplay, statusWindow, textMenuGC, &bbox, TGBS_RAISED, 1, FALSE); } if (msgFontSet == NULL && msgFontPtr == NULL) { if (defaultFontHeight+windowPadding+(brdrW<<1)+2 > btn1_height) { y = 2 + brdrW + defaultFontAsc + (windowPadding>>1); } else { y = ((statusWindowH-defaultFontHeight-windowPadding)>>1) + defaultFontAsc; } DrawMsgString(mainDisplay, statusWindow, defaultGC, (windowPadding>>1)+2, y, oneLineStatusStr, strlen(oneLineStatusStr)); } else { if (msgFontHeight+windowPadding+(brdrW<<1)+2 > btn1_height) { y = 2 + brdrW + msgFontAsc + (windowPadding>>1); } else { y = ((statusWindowH-msgFontHeight-windowPadding)>>1) + msgFontAsc; } if (msgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, msgFontPtr->fid); } DrawMsgString(mainDisplay, statusWindow, defaultGC, (windowPadding>>1)+2, y, oneLineStatusStr, strlen(oneLineStatusStr)); XSetFont(mainDisplay, defaultGC, defaultFontPtr->fid); } } else { int left=0, w=(int)(statusWindowW/3), right=0; if (msgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, msgFontPtr->fid); } for (i=0; i < MAX_STATUS_BTNS; i++) { right += w; if (right >= statusWindowW) right = statusWindowW-1; XClearWindow(mainDisplay, statusSubWindow[i]); if (msgFontSet == NULL && msgFontPtr == NULL) { DrawMsgString(mainDisplay, statusSubWindow[i], defaultGC, 2, 1+defaultFontAsc, btnStatusStr[i], strlen(btnStatusStr[i])); } else { DrawMsgString(mainDisplay, statusSubWindow[i], defaultGC, 2, 1+msgFontAsc, btnStatusStr[i], strlen(btnStatusStr[i])); } if (threeDLook) { SetBBRec(&bbox, 0, 0, statusSubWindowW[i], statusSubWindowH[i]); TgDrawThreeDButton(mainDisplay, statusSubWindow[i], textMenuGC, &bbox, TGBS_LOWRED, 1, FALSE); } left += w; } if (msgFontSet != NULL || msgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, defaultFontPtr->fid); } } } void RedrawStatusWindow() { register int i; XEvent ev; if (PRTGIF || noStatusWindow || statusWindow==None) return; if (!oneLineStatus) { int left=windowPadding, w=(int)(statusWindowW/3), y=0, right=0; if (msgFontSet == NULL && msgFontPtr == NULL) { if (defaultFontHeight+(brdrW<<1)+2 > btn1_height) { y = (statusWindowH-btn1_height)>>1; } else { y = 1; } } else { if (msgFontHeight+(brdrW<<1)+2 > btn1_height) { y = (statusWindowH-btn1_height)>>1; } else { y = 1; } } for (i=0; i < MAX_STATUS_BTNS; i++) { int x=left+(brdrW<<2); right += w; if (right >= statusWindowW) right = statusWindowW-1; XSetTSOrigin(mainDisplay, rasterGC, x, y); XSetStipple(mainDisplay, rasterGC, statusBtnPixmap[i]); XFillRectangle(mainDisplay, statusWindow, rasterGC, x, y, btn1_width, btn1_height); XSetTSOrigin(mainDisplay, rasterGC, 0, 0); left += w; } } RedrawStatusStrings(); if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, statusWindowW, statusWindowH); TgDrawThreeDButton(mainDisplay, statusWindow, textMenuGC, &bbox, TGBS_RAISED, 1, FALSE); } XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, statusWindow, ExposureMask, &ev)) ; } void SetMouseStatus(Left, Middle, Right) char *Left, *Middle, *Right; /* If Left, Middle, and Right are all NULL, just refresh the status */ { register int i; int force_redraw=FALSE, left_index, right_index; if (reverseMouseStatusButtons) { left_index = 2; right_index = 0; } else { left_index = 0; right_index = 2; } if (PRTGIF || noStatusWindow) return; if (oneLineStatus) { oneLineStatus = FALSE; if (statusWindow != None) { XClearWindow(mainDisplay, statusWindow); for (i=0; i < MAX_STATUS_BTNS; i++) { XMapWindow(mainDisplay, statusSubWindow[i]); } XSync(mainDisplay, False); } force_redraw = TRUE; } else if (Left != NULL || Middle != NULL || Right != NULL) { if (((Left == NULL && *btnStatusStr[left_index] == '\0') || (Left != NULL && strcmp(Left, btnStatusStr[left_index]) == 0)) && ((Middle == NULL && *btnStatusStr[1] == '\0') || (Middle != NULL && strcmp(Middle, btnStatusStr[1]) == 0)) && ((Right == NULL && *btnStatusStr[right_index] == '\0') || (Right != NULL && strcmp(Right, btnStatusStr[right_index]) == 0))) { return; } } if (Left != NULL || Middle != NULL || Right != NULL) { if (Left != NULL) { if (Left != btnStatusStr[left_index] && strcmp(Left, btnStatusStr[left_index]) != 0) { UtilStrCpyN(btnStatusStr[left_index], MAXSTRING+1, Left); } } else { *btnStatusStr[left_index] = '\0'; } if (Middle != NULL) { if (Middle != btnStatusStr[1] && strcmp(Middle, btnStatusStr[1]) != 0) { UtilStrCpyN(btnStatusStr[1], MAXSTRING+1, Middle); } } else { *btnStatusStr[1] = '\0'; } if (Right != NULL) { if (Right != btnStatusStr[right_index] && strcmp(Right, btnStatusStr[right_index]) != 0) { UtilStrCpyN(btnStatusStr[right_index], MAXSTRING+1, Right); } } else { *btnStatusStr[right_index] = '\0'; } } if (force_redraw) { RedrawStatusWindow(); } else { RedrawStatusStrings(); } } void SetStringStatus(StatusStr) char *StatusStr; /* If StatusStr is NULL, just refresh the status */ { register int i; int force_redraw=FALSE; if (PRTGIF || noStatusWindow) return; if (!oneLineStatus) { oneLineStatus = TRUE; if (statusWindow != None) { for (i=0; i < MAX_STATUS_BTNS; i++) { XUnmapWindow(mainDisplay, statusSubWindow[i]); } XSync(mainDisplay, False); } force_redraw = TRUE; } else if (StatusStr != NULL && strcmp(StatusStr, oneLineStatusStr) == 0) { return; } /* if StatusStr and oneLineStatusStr are the same string, don't copy */ if (StatusStr != NULL && StatusStr != oneLineStatusStr) { UtilStrCpyN(oneLineStatusStr, MAXSTRING+1, StatusStr); } if (force_redraw) { RedrawStatusWindow(); } else { RedrawStatusStrings(); } } static MouseOverStatusInfo *topStatusInfo=NULL; void SaveStatusStrings() { MouseOverStatusInfo *pmosi=NULL; int i=0; if (PRTGIF || noStatusWindow) return; pmosi = (MouseOverStatusInfo *)malloc(sizeof(MouseOverStatusInfo)); if (pmosi == NULL) FailAllocMessage(); pmosi->next = topStatusInfo; for (i=0; i < MAX_STATUS_BTNS; i++) { UtilStrCpyN(pmosi->btn_str[i], MAXSTRING+1, btnStatusStr[i]); } UtilStrCpyN(pmosi->one_line_str, MAXSTRING+1, oneLineStatusStr); pmosi->one_line_status = oneLineStatus; topStatusInfo = pmosi; } void RestoreStatusStrings() { MouseOverStatusInfo *pmosi=NULL; int i=0; if (PRTGIF || noStatusWindow || topStatusInfo == NULL) return; for (i=0; i < MAX_STATUS_BTNS; i++) { UtilStrCpyN(btnStatusStr[i], MAXSTRING+1, topStatusInfo->btn_str[i]); } UtilStrCpyN(oneLineStatusStr, MAXSTRING+1, topStatusInfo->one_line_str); if (topStatusInfo->one_line_status != oneLineStatus) { if (topStatusInfo->one_line_status) { SetStringStatus(oneLineStatusStr); } else { SetMouseStatus(btnStatusStr[0], btnStatusStr[1], btnStatusStr[2]); } } else { RedrawStatusWindow(); } pmosi = topStatusInfo->next; free(topStatusInfo); topStatusInfo = pmosi; } void SaveStatusStringsIntoBuf(ppsz_buf, pn_one_line) char ppsz_buf[MAX_STATUS_BTNS+1][MAXSTRING+1]; int *pn_one_line; /* dimension of ppsz_buf must be [MAX_STATUS_BTNS+1][MAXSTRING+1] */ { register int i; if (PRTGIF || noStatusWindow) return; for (i=0; i < MAX_STATUS_BTNS; i++) { UtilStrCpyN(ppsz_buf[i], MAXSTRING+1, btnStatusStr[i]); } UtilStrCpyN(ppsz_buf[i], MAXSTRING+1, oneLineStatusStr); *pn_one_line = oneLineStatus; } void RestoreStatusStringsFromBuf(ppsz_buf, one_line) char ppsz_buf[MAX_STATUS_BTNS+1][MAXSTRING+1]; int one_line; /* dimension of ppsz_buf must be [MAX_STATUS_BTNS+1][MAXSTRING+1] */ { register int i; if (PRTGIF || noStatusWindow) return; for (i=0; i < MAX_STATUS_BTNS; i++) { UtilStrCpyN(btnStatusStr[i], MAXSTRING+1, ppsz_buf[i]); } UtilStrCpyN(oneLineStatusStr, MAXSTRING+1, ppsz_buf[i]); if (one_line != oneLineStatus) { if (one_line) { SetStringStatus(oneLineStatusStr); } else { SetMouseStatus(btnStatusStr[0], btnStatusStr[1], btnStatusStr[2]); } } else { RedrawStatusWindow(); } } void BeginProgress(ppi, total_size) ProgressInfo *ppi; int total_size; { memset(ppi, 0, sizeof(ProgressInfo)); ppi->total_size = total_size; SaveStatusStringsIntoBuf(ppi->status_buf, &ppi->one_line_status); } void UpdateProgress(ppi, cur_size) ProgressInfo *ppi; int cur_size; { int percent=(int)(((double)cur_size) / ((double)ppi->total_size) * ((double)100)); if (percent >= ppi->target_percent) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_PROGRESS_PERCENT), percent); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); while (ppi->target_percent <= percent) ppi->target_percent += 5; } } void EndProgress(ppi) ProgressInfo *ppi; { RestoreStatusStringsFromBuf(ppi->status_buf, ppi->one_line_status); } void MsgEventHandler(input) XEvent *input; { XButtonEvent *button_ev; if (input->type == Expose) { RedrawMsg(TRUE); } else if (input->type == EnterNotify) { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_DOWN_1_LINE), TgLoadCachedString(CSTID_SCROLL_AROUND), TgLoadCachedString(CSTID_SCROLL_UP_1_LINE)); } else if (input->type == ButtonPress) { button_ev = &(input->xbutton); if (button_ev->button == Button1) { if (button_ev->state & (ShiftMask | ControlMask)) { firstCharPos += (((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontWidth : msgFontWidth)<<2); RedrawMsg(TRUE); } else { if (topMsgNumber+1 >= msgCount) return; topMsgNumber++; RedrawMsg(TRUE); } } else if (button_ev->button == Button2) { int done=FALSE, saved_x=button_ev->x, saved_y=button_ev->y, x, y; int saved_pos=firstCharPos, cur_top_msg_number=topMsgNumber, cur_dx=0; XEvent ev; RedrawMsg(TRUE); XGrabPointer(mainDisplay, msgWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); while (!done) { XNextEvent(mainDisplay, &ev); if (ev.type == Expose || ev.type == VisibilityNotify) { ExposeEventHandler(&ev, TRUE); } else if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); done = TRUE; } else if (ev.type == MotionNotify) { double dx=(double)0, dy=(double)0; x = ev.xmotion.x; y = ev.xmotion.y; dx = ((double)(x-saved_x)) / ((double)((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontWidth : msgFontWidth)); dy = ((double)(y-saved_y)) / ((double)((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontHeight : msgFontHeight)); topMsgNumber += round(dy); if (topMsgNumber > msgCount) topMsgNumber = msgCount; if (topMsgNumber < 0) topMsgNumber = 0; if (topMsgNumber != cur_top_msg_number || round(dx) != cur_dx) { cur_top_msg_number = topMsgNumber; cur_dx = round(dx); firstCharPos = cur_dx * ((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontWidth : msgFontWidth) + saved_pos; if (firstCharPos < 0) firstCharPos = 0; RedrawMsg(TRUE); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } } else if (button_ev->button == Button3) { if (button_ev->state & (ShiftMask | ControlMask)) { if (firstCharPos <= 0) return; firstCharPos -= (((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontWidth : msgFontWidth)<<2); if (firstCharPos < 0) firstCharPos = 0; RedrawMsg(TRUE); } else { if (topMsgNumber == 0) return; topMsgNumber--; RedrawMsg(TRUE); } } } } void StatusEventHandler(input) XEvent *input; { if (PRTGIF || noStatusWindow) return; if (input->type == Expose) { RedrawStatusWindow(); } } void RedrawUserRedrawWindow() { XEvent ev; int x, y; XGCValues values; while (XCheckWindowEvent(mainDisplay,userRedrawWindow,ExposureMask,&ev)) ; while (XCheckWindowEvent(mainDisplay,userRedrawWindow,ButtonPressMask,&ev)) ; x = ((userRedrawWindowW-redraw_width)>>1); y = ((userRedrawWindowH-redraw_height)>>1); XClearWindow(mainDisplay, userRedrawWindow); values.stipple = userRedrawBitmap; values.ts_x_origin = x; values.ts_y_origin = y; XChangeGC(mainDisplay, rasterGC, GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, userRedrawWindow, rasterGC, x, y, redraw_width, redraw_height); XSetTSOrigin(mainDisplay, rasterGC, 0, 0); if (userDisableRedraw) { GC gc; int shift=windowPadding; values.foreground = myFgPixel; values.background = (threeDLook ? myLtGryPixel : myBgPixel); gc = XCreateGC(mainDisplay, userRedrawWindow, GCForeground | GCBackground, &values); XDrawLine(mainDisplay, userRedrawWindow, gc, shift, userRedrawWindowH-1-shift, userRedrawWindowW-1-shift, shift); XFreeGC(mainDisplay, gc); } if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, userRedrawWindowW, userRedrawWindowH); TgDrawThreeDButton(mainDisplay, userRedrawWindow, textMenuGC, &bbox, (userDisableRedraw ? TGBS_LOWRED : TGBS_RAISED), 2, TRUE); } } static void ToggleUserRedraw() { userDisableRedraw = !userDisableRedraw; RedrawUserRedrawWindow(); if (!userDisableRedraw) { ClearAndRedrawDrawWindow(); } } void UserRedrawEventHandler(input) XEvent *input; { if (PRTGIF || noStatusWindow) return; if (input->type == Expose) { RedrawUserRedrawWindow(); } else if (input->type == EnterNotify) { SetMouseStatus(TgLoadCachedString(userDisableRedraw ? CSTID_ENABLE_REDRAW : CSTID_DISABLE_REDRAW), TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PARANED_NONE)); } else if (input->type == ButtonPress) { ToggleUserRedraw(); SetMouseStatus(TgLoadCachedString(userDisableRedraw ? CSTID_ENABLE_REDRAW : CSTID_DISABLE_REDRAW), TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PARANED_NONE)); } } void InitStatus() { register int i; char *c_ptr; oneLineStatus = FALSE; *oneLineStatusStr = '\0'; for (i=0; i < MAX_STATUS_BTNS; i++) *btnStatusStr[i] = '\0'; reverseMouseStatusButtons = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ReverseMouseStatusButtons")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { reverseMouseStatusButtons = TRUE; } gnMsgRows = (int)((msgWindowH-2-(windowPadding<<1)) / ((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontHeight : msgFontHeight)); } void CleanUpStatus() { while (topStatusInfo != NULL) { MouseOverStatusInfo *next_mosi=topStatusInfo->next; free(topStatusInfo); topStatusInfo = next_mosi; } if (redraw_bits == NULL) { } if (btn1_bits == NULL) { } } static char *scanVal=NULL; static char *scanSep=NULL; void InitScan(s, pat) char *s, *pat; { scanVal = s; scanSep = pat; } static char *GetString() { char *c_ptr; if (scanVal == NULL || scanSep == NULL) return NULL; while (*scanVal!='\0' && strchr(scanSep,*scanVal)!=NULL) *scanVal++ = '\0'; if (*scanVal == '\0') return NULL; c_ptr=scanVal; for ( ; *scanVal!='\0' && strchr(scanSep,*scanVal)==NULL; scanVal++) ; if (*scanVal != '\0') *scanVal++ = '\0'; return c_ptr; } int ScanValue(fmt, v, item, stype) char *fmt, *item, *stype; void *v; { char *c_ptr, msg[MAXPATHLENGTH]; if (scanVal == NULL) return INVALID; #ifdef DEBUG /* debug, do not translate */ printf("get %s for %s from %s: ", item, stype, scanVal); #endif if ((c_ptr=GetString()) == NULL) { #ifdef DEBUG /* debug, do not translate */ printf("nothing\n"); #endif (void)sprintf(msg, TgLoadString(STID_FILE_LINE_MISS_FIELD_IN_OBJ), scanFileName, scanLineNum, item, stype); if (PRTGIF) { fprintf(stderr, "%s\n", msg); } else { Msg(msg); } return INVALID; } if (sscanf(c_ptr, fmt, v) != 1) { #ifdef DEBUG /* debug, do not translate */ printf("error in %s\n", c_ptr); #endif (void)sprintf(msg, TgLoadString(STID_FILE_LINE_BAD_FIELD_IN_OBJ), scanFileName, scanLineNum, item, stype, c_ptr); if (PRTGIF) { fprintf(stderr, "%s\n", msg); } else { Msg(msg); } return INVALID; } #ifdef DEBUG /* debug, do not translate */ printf("got %d\n", (*(int *)v)); #endif return 0; } int ScanDynStrValue(v, item, stype) struct DynStrRec *v; char *item, *stype; /* * */ { char *c_ptr=NULL, *psz=NULL, msg[MAXPATHLENGTH]; if (scanVal == NULL) return INVALID; #ifdef DEBUG /* debug, do not translate */ printf("get %s for %s from %s: ", item, stype, scanVal); #endif if ((c_ptr=GetString()) == NULL) { #ifdef DEBUG /* debug, do not translate */ printf("nothing\n"); #endif (void)sprintf(msg, TgLoadString(STID_FILE_LINE_MISS_FIELD_IN_OBJ), scanFileName, scanLineNum, item, stype); if (PRTGIF) { fprintf(stderr, "%s\n", msg); } else { Msg(msg); } return INVALID; } while (*c_ptr != '"' && *c_ptr != '\0') c_ptr++; if (c_ptr != NULL) { psz = ReadString(++c_ptr); } if (psz == NULL) { #ifdef DEBUG /* debug, do not translate */ printf("error in %s\n", c_ptr); #endif (void)sprintf(msg, TgLoadString(STID_FILE_LINE_BAD_FIELD_IN_OBJ), scanFileName, scanLineNum, item, stype, c_ptr); if (PRTGIF) { fprintf(stderr, "%s\n", msg); } else { Msg(msg); } return INVALID; } *(--psz) = '\0'; DynStrSet(v, c_ptr); #ifdef DEBUG /* debug, do not translate */ printf("got \"%s\"\n", ((struct DynStrRec *)v)->s); #endif return 0; } #define MAXEMERGENCYCOUNT 5 static int emergencyCount = 0; static void SaveEmergencyTmpFile() { switch (SaveTmpFile("EmergencySave")) { case OBJ_FILE_TYPE: fprintf(stderr, TgLoadString(STID_WORKING_FILE_SAVED_TO), "EmergencySave", OBJ_FILE_EXT); fprintf(stderr, "\n"); break; case SYM_FILE_TYPE: fprintf(stderr, TgLoadString(STID_WORKING_FILE_SAVED_TO), "EmergencySave", SYM_FILE_EXT); fprintf(stderr, "\n"); break; case PIN_FILE_TYPE: fprintf(stderr, TgLoadString(STID_WORKING_FILE_SAVED_TO), "EmergencySave", PIN_FILE_EXT); fprintf(stderr, "\n"); break; case INVALID: fprintf(stderr, "%s\n", TgLoadString(STID_UNABLE_TO_SAVE_WORKING_FILE)); break; } } void EmergencySave(sig) int sig; { switch (sig) { case SIGHUP: fprintf(stderr, TgLoadString(STID_NAMED_SIG_RECV), "SIGHUP"); fprintf(stderr, "\n"); break; case SIGFPE: fprintf(stderr, TgLoadString(STID_NAMED_SIG_RECV), "SIGFPE"); fprintf(stderr, "\n"); break; #ifndef linux case SIGBUS: fprintf(stderr, TgLoadString(STID_NAMED_SIG_RECV), "SIGBUS"); fprintf(stderr, "\n"); break; #endif case SIGSEGV: fprintf(stderr, TgLoadString(STID_NAMED_SIG_RECV), "SIGSEGV"); fprintf(stderr, "\n"); break; } if (++emergencyCount > MAXEMERGENCYCOUNT) { fprintf(stderr, TgLoadString(STID_ERR_COUNT_EXCEED_TOOL_ABORTED), MAXEMERGENCYCOUNT, "EmergencySave()", TOOL_NAME); fprintf(stderr, "\n"); exit(-1); } if (exitNormally) return; signal(SIGHUP, SIG_DFL); signal(SIGFPE, SIG_DFL); #ifndef linux signal(SIGBUS, SIG_DFL); #endif signal(SIGSEGV, SIG_DFL); if (fileModified) { SaveEmergencyTmpFile(); } exitNormally = TRUE; exit(0); } static int EmergencySaveForXCont(s) char *s; { if (++emergencyCount > MAXEMERGENCYCOUNT) { fprintf(stderr, TgLoadString(STID_ERR_COUNT_EXCEED_TOOL_ABORTED), MAXEMERGENCYCOUNT, s, TOOL_NAME); fprintf(stderr, "\n"); exit(-1); } if (exitNormally) return 0; if (copyingToCutBuffer) { emergencyCount--; copyingToCutBuffer = INVALID; return 0; } signal(SIGHUP, SIG_DFL); signal(SIGFPE, SIG_DFL); #ifndef linux signal(SIGBUS, SIG_DFL); #endif signal(SIGSEGV, SIG_DFL); if (fileModified) { SaveEmergencyTmpFile(); } exitNormally = TRUE; return (-1); } int EmergencySaveForX(dsp, ev) Display *dsp; XErrorEvent *ev; { char msg[MAXSTRING+1]; XGetErrorText(mainDisplay, (int)(ev->error_code), msg, MAXSTRING); fprintf(stderr, TgLoadString(STID_X_ERROR_MSG), msg); fprintf(stderr, "\n"); return EmergencySaveForXCont("EmergencySaveForX()"); } int IOEmergencySaveForX(dsp) Display *dsp; { return EmergencySaveForXCont("IOEmergencySaveForX()"); } void Error(where, msg) char *where, *msg; { fprintf(stderr, TgLoadString(STID_FATAL_ERROR_IN_FUNC_PLUS_DESC), where, msg); fprintf(stderr, "\n"); fprintf(stderr, TgLoadString(STID_TOOL_ABORTED), TOOL_NAME); fprintf(stderr, "\n"); if (fileModified) EmergencySave(0); exit(-1); } void GetTgifVersionAndPatchLevel(buf, buf_sz) char *buf; int buf_sz; { char buf1[MAXSTRING], buf2[MAXSTRING]; *buf1 = *buf2 = '\0'; if (TGIF_PATCHLEVEL == 0) { if (*specialBuild == '\0') { sprintf(buf1, TgLoadString(STID_TOOL_VERSION), TOOL_NAME, versionString); } else { sprintf(buf1, TgLoadString(STID_TOOL_VERSION_SPC_BUILD), TOOL_NAME, versionString, specialBuild); } strcpy(buf2, versionString); } else { if (*specialBuild == '\0') { sprintf(buf1, TgLoadString(STID_TOOL_VERSION_PATCH), TOOL_NAME, versionString, TGIF_PATCHLEVEL); } else { sprintf(buf1, TgLoadString(STID_TOOL_VERSION_PATCH_SPC_BUILD), TOOL_NAME, versionString, TGIF_PATCHLEVEL, specialBuild); } sprintf(buf2, "%s.%1d", versionString, TGIF_PATCHLEVEL); } #ifdef TGIF_DISTR_VER if (strcmp(TGIF_DISTR_VER, buf2) != 0) { sprintf(&buf1[strlen(buf1)], TgLoadString(STID_TGIF_DISTRUBITION), TGIF_DISTR_VER); } #endif /* TGIF_DISTR_VER */ #ifdef NOT_DEFINED sprintf(&buf1[strlen(buf1)], TgLoadString(STID_TGIF_FLAGS), "_TGIF_WB2"); #endif /* NOT_DEFINED */ UtilStrCpyN(buf, buf_sz, buf1); } void Usage(tool_name) char *tool_name; { char buf[MAXSTRING]; GetTgifVersionAndPatchLevel(buf, sizeof(buf)); fprintf(stdout, "%s\n", buf); fprintf(stdout, "%s\n\n", copyrightString); fprintf(stdout, "Usage:\t%s \\\n", tool_name); fprintf(stdout, "\t[-display displayname] \\\n"); fprintf(stdout, "\t[-fg <color>] \\\n"); fprintf(stdout, "\t[-bg <color>] \\\n"); fprintf(stdout, "\t[-bd <color>] \\\n"); fprintf(stdout, "\t[-rv] [-nv] \\\n"); fprintf(stdout, "\t[-bw] \\\n"); fprintf(stdout, "\t[-tgwb2 [-rmcastlibdir <directory> | -rmcastlibpath <path>] [-parent <parent_window_id>]] \\\n"); fprintf(stdout, "\t[-reqcolor] \\\n"); fprintf(stdout, "\t[-cwo[+sbwarp]] \\\n"); fprintf(stdout, "\t[-hyper] \\\n"); fprintf(stdout, "\t[-a4 | -letter] \\\n"); fprintf(stdout, "\t[-geometry <geom>] [=<geom>] \\\n"); fprintf(stdout, "\t[-exec <file>] \\\n"); fprintf(stdout, "\t[-dbim {xcin|chinput|xim|kinput2}] \\\n"); fprintf(stdout, "\t[-sbim xim] \\\n"); fprintf(stdout, "\t[-usexlib] \\\n"); fprintf(stdout, "\t[-listdontreencode] \\\n"); fprintf(stdout, "\t[-version | --version] \\\n"); fprintf(stdout, "\t[-pdfspd | -pdfspd=true | -pdfspd=false] \\\n"); fprintf(stdout, "\t[-pssetup \"<string>\"] \\\n"); fprintf(stdout, "\t[-nomode] \\\n"); fprintf(stdout, "\t[-tg2genparse=\"<string>\"] \\\n"); fprintf(stdout, "\t[{<file>[.%s] | -merge <file1>[.%s] <file2>[.%s] ...}]\n", OBJ_FILE_EXT, OBJ_FILE_EXT, OBJ_FILE_EXT); fprintf(stdout, "or:\n"); fprintf(stdout, "\t%s -print \\\n", tool_name); fprintf(stdout, "\t[-display displayname] \\\n"); fprintf(stdout, "\t[-eps | -p | -epsi | -tiffepsi] \\\n"); fprintf(stdout, "\t[-ps | -f] \\\n"); fprintf(stdout, "\t[-text] \\\n"); fprintf(stdout, "\t[-gif | -png | -jpeg | -ppm | -pbm | -xpm | -xbm | -html] \\\n"); fprintf(stdout, "\t[-pdf] \\\n"); fprintf(stdout, "\t[-netlist] \\\n"); fprintf(stdout, "\t[-stdout] \\\n"); fprintf(stdout, "\t[-raw[+h[eaderonly]]] \\\n"); fprintf(stdout, "\t[-dosepsfilter [-previewonly]] \\\n"); fprintf(stdout, "\t[-status] \\\n"); fprintf(stdout, "\t[-gray] \\\n"); fprintf(stdout, "\t[-color | -reqcolor] \\\n"); fprintf(stdout, "\t[-adobe | -adobe=<number>/<number>] \\\n"); fprintf(stdout, "\t[-dontreencode=\"<%s>:<%s>:...\" | -listdontreencode] \\\n", "fontfamily", "fontfamily"); fprintf(stdout, "\t[-version | --version | -justversion] \\\n"); fprintf(stdout, "\t[-producedby=\"<string>\"] \\\n"); fprintf(stdout, "\t[-page <number>] \\\n"); fprintf(stdout, "\t[-print_cmd \"<command>\"] \\\n"); fprintf(stdout, "\t[-one_file_per_page] \\\n"); fprintf(stdout, "\t[-pepsc] \\\n"); fprintf(stdout, "\t[-pdfspd | -pdfspd=true | -pdfspd=false] \\\n"); fprintf(stdout, "\t[-pssetup \"<string>\"] \\\n"); fprintf(stdout, "\t[-j2p6_cmd \"<command>\"] \\\n"); fprintf(stdout, "\t[-dontcondense | -condensed] \\\n"); fprintf(stdout, "\t[-a4 | -letter] \\\n"); fprintf(stdout, "\t[-noshowpageineps] \\\n"); fprintf(stdout, "\t[-quiet] \\\n"); fprintf(stdout, "\t[-bop_hook \"<string>\"] \\\n"); fprintf(stdout, "\t[-eop_hook \"<string>\"] \\\n"); fprintf(stdout, "\t[-tmp_file_mode \"<octal number>\"] \\\n"); fprintf(stdout, "\t[-odir] \\\n"); fprintf(stdout, "\t[-exec <file>] \\\n"); fprintf(stdout, "\t[<file1>[.%s] <file2>[.%s] ...]\n", OBJ_FILE_EXT, OBJ_FILE_EXT); exit(-1); } int ProcessPrTgifOptions(argc, argv, from_prtgif) int argc, from_prtgif; char *argv[]; { char *c_ptr=NULL; int saved_argc=argc, show_copyright=FALSE; char **saved_argv=argv; *cmdLineTmpFileModeStr = '\0'; *cmdLineGenParser = '\0'; *cmdLineFileToExec = '\0'; *cmdLineJpegToPpm6Cmd = '\0'; *cmdLineCustomPatternDir = '\0'; cmdLineOneFilePerPage = FALSE; *outputDir = '\0'; for (argc--, argv++; argc > 0; argc--, argv++) { if (**argv == '-') { if (strcmp(*argv, "-version") == 0 || strcmp(*argv, "--version") == 0) { show_copyright = TRUE; } else if (strcmp(*argv, "-tgrm2") == 0) { cmdLineTgrm2 = TRUE; } else if (strcmp(*argv, "-justversion") == 0) { char buf[MAXSTRING]; GetTgifVersionAndPatchLevel(buf, sizeof(buf)); fprintf(stdout, "%s\n", buf); fprintf(stdout, "%s (%s)\n\n", copyrightString, authorEmailString); fflush(stdout); return INVALID; } } } argc = saved_argc; argv = saved_argv; if (show_copyright) { char buf[MAXSTRING]; GetTgifVersionAndPatchLevel(buf, sizeof(buf)); fprintf(stderr, "%s\n", buf); fprintf(stderr, "%s (%s)\n\n", copyrightString, authorEmailString); fflush(stderr); } if (!from_prtgif) { if ((c_ptr=getenv("TGIFPATH")) == NULL) { strcpy(drawPath, TGIF_PATH); } else { if (((int)strlen(c_ptr)) >= MAXSTRING) { /* must be an error */ strcpy(drawPath, TGIF_PATH); } else { strcpy(drawPath, c_ptr); } } #ifdef PRINT_CMD strcpy(printCommand, PRINT_CMD); #else #ifdef VMS strcpy(printCommand, "print"); #else #ifdef SYSV strcpy(printCommand, "lp -dpostscript"); #else strcpy(printCommand, "lpr"); #endif /* SYSV */ #endif /* VMS */ #endif /* PRINT_CMD */ } cmdLineWhereToPrint = INVALID; whereToPrint = PRINTER; usePsAdobeString = FALSE; *adobeString = *epsfString = '\0'; *cmdLineDontReencode = *cmdLineProducedBy = '\0'; *cmdLineOpenFile = '\0'; #ifdef _USE_PS_ADOBE_STRING { char buf[MAXSTRING]; UtilStrCpyN(buf, sizeof(buf), _USE_PS_ADOBE_STRING); if (!ParsePsAdobeString(buf,&usePsAdobeString,adobeString,epsfString)) { fprintf(stderr, TgLoadString(STID_BAD_COMPILE_OPT_USE_ALT_STR), "_USE_PS_ADOBE_STRING", _USE_PS_ADOBE_STRING, "false"); fprintf(stderr, "\n"); usePsAdobeString = FALSE; *adobeString = *epsfString = '\0'; } } #endif /* _USE_PS_ADOBE_STRING */ c_ptr = printCommand; c_ptr += strlen(printCommand); for (argc--, argv++; argc > 0; argc--, argv++) { if (**argv == '-') { int len=0; if (strcmp(*argv, "-display") == 0) { argc--; argv++; if (argc <= 0) { fprintf(stderr, "%s\n\n", TgLoadString(STID_MISSING_DISPLAY_NAME)); Usage(progName); } if ((displayName=UtilStrDup(*argv)) == NULL) FailAllocMessage(); cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv, "-p") == 0 || strcmp(*argv, "-eps") == 0) { whereToPrint = cmdLineWhereToPrint = LATEX_FIG; } else if (strcmp(*argv,"-f") == 0 || strcmp(*argv,"-ps") == 0) { whereToPrint = cmdLineWhereToPrint = PS_FILE; } else if (strcmp(*argv,"-stdout") == 0) { cmdLineStdOut = TRUE; } else if (strcmp(*argv,"-epsi") == 0) { cmdLineWhereToPrint = EPSI_FILE; cmdLineTiffEPSI = FALSE; cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv,"-tiffepsi") == 0) { cmdLineWhereToPrint = EPSI_FILE; cmdLineTiffEPSI = TRUE; cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv,"-gif") == 0) { cmdLineWhereToPrint = GIF_FILE; cmdLineColor = TRUE; cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv,"-png") == 0) { cmdLineWhereToPrint = PNG_FILE; cmdLineColor = TRUE; cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv,"-jpeg") == 0) { cmdLineWhereToPrint = JPEG_FILE; cmdLineColor = TRUE; cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv,"-ppm") == 0) { cmdLineWhereToPrint = PPM_FILE; cmdLineColor = TRUE; cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv,"-pbm") == 0) { cmdLineWhereToPrint = PPM_FILE; cmdLineColor = FALSE; cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv,"-xpm") == 0) { cmdLineWhereToPrint = XBM_FILE; cmdLineColor = TRUE; cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv,"-xbm") == 0) { cmdLineWhereToPrint = XBM_FILE; cmdLineColor = FALSE; cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv,"-html") == 0) { cmdLineWhereToPrint = HTML_FILE; cmdLineColor = TRUE; cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv,"-pdf") == 0) { whereToPrint = cmdLineWhereToPrint = PDF_FILE; } else if (strcmp(*argv, "-text") == 0) { whereToPrint = cmdLineWhereToPrint = TEXT_FILE; } else if (strcmp(*argv, "-netlist") == 0) { whereToPrint = cmdLineWhereToPrint = NETLIST_FILE; } else if (strcmp(*argv,"-svg") == 0) { whereToPrint = cmdLineWhereToPrint = SVG_FILE; } else if (strcmp(*argv, "-raw") == 0) { cmdLineDumpURL = TRUE; cmdLineDumpURLWithHeader = FALSE; cmdLineDumpURLHeaderOnly = FALSE; } else if (strcmp(*argv, "-raw+h") == 0) { cmdLineDumpURL = TRUE; cmdLineDumpURLWithHeader = TRUE; cmdLineDumpURLHeaderOnly = FALSE; } else if (strcmp(*argv, "-raw+headeronly") == 0) { cmdLineDumpURL = TRUE; cmdLineDumpURLWithHeader = TRUE; cmdLineDumpURLHeaderOnly = TRUE; } else if (strcmp(*argv, "-dosepsfilter") == 0) { cmdLineDosEpsFilter = TRUE; } else if (strcmp(*argv, "-previewonly") == 0) { cmdLinePreviewOnly = TRUE; } else if (strcmp(*argv, "-status") == 0) { cmdLineDumpURLShowStatus = TRUE; } else if (strcmp(*argv, "-page") == 0) { argc--; argv++; if (argc <= 0) { fprintf(stderr, "%s\n\n", TgLoadString(STID_MISSING_PAGE_NUMBER)); Usage(progName); } cmdLineHasPageNum = TRUE; UtilStrCpyN(cmdLinePageNumStr, sizeof(cmdLinePageNumStr), *argv); if (sscanf(cmdLinePageNumStr, "%d", &cmdLinePageNum) != 1 || cmdLinePageNum <= 0) { cmdLineHasPageNum = FALSE; fprintf(stderr, TgLoadString(STID_INVALID_GIVEN_PAGE_NUMBER_STR), cmdLinePageNumStr); fprintf(stderr, "\n\n"); Usage(progName); } } else if (strcmp(*argv, "-one_file_per_page") == 0) { cmdLineOneFilePerPage = TRUE; } else if (strcmp(*argv, "-pepsc") == 0) { stripEPSComments = FALSE; } else if (strcmp(*argv, "-nolandpdfspd") == 0) { cmdLinePdfSetPageDevice = FALSE; fprintf(stderr, TgLoadString(STID_OBSOLETE_CMDLINE_ASSUME), "-nolandpdfspd", "-pdfspd=false"); fprintf(stderr, "\n"); } else if (strcmp(*argv, "-pdfspd") == 0) { cmdLinePdfSetPageDevice = TRUE; } else if (strncmp(*argv, "-pdfspd=", 8) == 0) { char tmp_str[80]; UtilStrCpyN(tmp_str, sizeof(tmp_str), &(*argv)[8]); UtilTrimBlanks(tmp_str); if (UtilStrICmp(tmp_str, "true") == 0) { cmdLinePdfSetPageDevice = TRUE; } else if (UtilStrICmp(tmp_str, "false") == 0) { cmdLinePdfSetPageDevice = FALSE; } else { fprintf(stderr, TgLoadString(STID_BAD_CMDLINE_OPT_IGNORED), "-pdfspd", tmp_str); fprintf(stderr, "\n"); } } else if (strcmp(*argv, "-pssetup") == 0) { argc--; argv++; if (argc <= 0) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-pssetup"); fprintf(stderr, "\n\n"); Usage(progName); } cmdLinePsSetup = TRUE; SetPsSetup(*argv); } else if (strcmp(*argv, "-dontcondense") == 0) { SetCmdLineDontCondense(); } else if (strcmp(*argv, "-condensed") == 0) { SetCmdLineCondensedPS(); } else if (strcmp(*argv, "-a4") == 0) { cmdLineA4 = TRUE; } else if (strcmp(*argv, "-letter") == 0) { cmdLineLetter = TRUE; } else if (strcmp(*argv, "-noshowpageineps") == 0) { cmdLineNoShowPageInEPS = TRUE; } else if (strcmp(*argv, "-quiet") == 0) { cmdLineQuiet = TRUE; } else if (strcmp(*argv, "-bop_hook") == 0) { argc--; argv++; if (argc <= 0) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-bop_hook"); fprintf(stderr, "\n\n"); Usage(progName); } SetBopHook(*argv); } else if (strcmp(*argv, "-eop_hook") == 0) { argc--; argv++; if (argc <= 0) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-eop_hook"); fprintf(stderr, "\n\n"); Usage(progName); } SetEopHook(*argv); } else if (strcmp(*argv, "-tmp_file_mode") == 0) { int nFileMode=0; argc--; argv++; if (argc <= 0) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-tmp_file_mode"); fprintf(stderr, "\n\n"); Usage(progName); } UtilStrCpyN(cmdLineTmpFileModeStr, sizeof(cmdLineTmpFileModeStr), *argv); UtilTrimBlanks(cmdLineTmpFileModeStr); if (*cmdLineTmpFileModeStr != '\0' && sscanf(cmdLineTmpFileModeStr, "%o", &nFileMode) == 1) { if (nFileMode >= 0) { tmpFileMode = nFileMode; } else { fprintf(stderr, TgLoadString(STID_INVALID_ARG_FOR_CMDLINE_OPT), "-tmp_file_mode", cmdLineTmpFileModeStr); fprintf(stderr, "\n\n"); Usage(progName); } } } else if (strcmp(*argv, "-gray") == 0) { useGray = TRUE; } else if (strcmp(*argv, "-bw") == 0) { } else if (strcmp(*argv, "-color") == 0) { cmdLineRequestedColor = FALSE; cmdLineColor = TRUE; } else if (strcmp(*argv, "-reqcolor") == 0) { cmdLineRequestedColor = TRUE; cmdLineColor = TRUE; } else if (strcmp(*argv, "-adobe") == 0) { usePsAdobeString = TRUE; } else if (strncmp(*argv, "-adobe=", 7) == 0) { char tmp_str[80]; UtilStrCpyN(tmp_str, sizeof(tmp_str), &(*argv)[7]); UtilTrimBlanks(tmp_str); if (!ParsePsAdobeString(tmp_str, &usePsAdobeString, adobeString, epsfString)) { fprintf(stderr, TgLoadString(STID_BAD_CMDLINE_OPT_USE_ALT_STR), "-adobe", tmp_str, "false"); fprintf(stderr, "\n"); usePsAdobeString = FALSE; *adobeString = *epsfString = '\0'; } } else if (strcmp(*argv, "-listdontreencode") == 0) { #ifdef _DONT_REENCODE fprintf(stderr, "-D_DONT_REENCODE=\"%s\"\n", _DONT_REENCODE); #endif /* _DONT_REENCODE */ } else if (strcmp(*argv, "-version") == 0 || strcmp(*argv, "--version") == 0) { cmdLineVersion = TRUE; } else if (strncmp(*argv, "-dontreencode=", 14) == 0) { strcpy(cmdLineDontReencode, &(*argv)[14]); UtilTrimBlanks(cmdLineDontReencode); if (*cmdLineDontReencode != '\0') { UtilRemoveQuotes(cmdLineDontReencode); UtilTrimBlanks(cmdLineDontReencode); } } else if (strncmp(*argv, "-producedby=", 12) == 0) { UtilStrCpyN(cmdLineProducedBy, sizeof(cmdLineProducedBy), &(*argv)[12]); UtilTrimBlanks(cmdLineProducedBy); if (*cmdLineProducedBy != '\0') { UtilRemoveQuotes(cmdLineProducedBy); } } else if (strncmp(*argv, "-tg2genparser=", 14) == 0) { UtilStrCpyN(cmdLineGenParser, sizeof(cmdLineGenParser), &(*argv)[14]); UtilTrimBlanks(cmdLineGenParser); if (*cmdLineGenParser != '\0') { UtilRemoveQuotes(cmdLineGenParser); } } else if (strcmp(*argv, "-parse_html") == 0) { cmdLineParseHtml = TRUE; /* cmdLineDumpURL will be reset in UrlDump() */ cmdLineDumpURL = TRUE; cmdLineDumpURLWithHeader = FALSE; cmdLineDumpURLHeaderOnly = FALSE; } else if (strcmp(*argv, "-exec") == 0) { argc--; argv++; if (argc <= 0) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-exec"); fprintf(stderr, "\n\n"); Usage(progName); } UtilStrCpyN(cmdLineFileToExec, sizeof(cmdLineFileToExec), *argv); UtilTrimBlanks(cmdLineFileToExec); if (*cmdLineFileToExec == '-' && cmdLineFileToExec[1] != '\0') { fprintf(stderr, "%s\n\n", TgLoadString(STID_BAD_EXEC_FNAME_DASH)); Usage(progName); } cmdLineOpenDisplay = TRUE; } else if (strcmp(*argv, "-tgif_path") == 0) { argc--; argv++; if (argc <= 0) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-tgif_path"); fprintf(stderr, "\n\n"); Usage(progName); } len = strlen(*argv); if (**argv == '"' && (*argv)[len-1] == '"') { strcpy(drawPath, &(*argv)[1]); drawPath[strlen(drawPath)-1] = '\0'; } else { strcpy(drawPath, *argv); } if (!from_prtgif) { fprintf(stderr, "%s\n", TgLoadString(STID_TGIF_PATH_SHOULD_NOT_BE_USED)); } } else if (strcmp(*argv, "-print_cmd") == 0) { argc--; argv++; if (argc <= 0) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-print_cmd"); fprintf(stderr, "\n\n"); Usage(progName); } len = strlen(*argv); if (**argv == '"' && (*argv)[len-1] == '"') { strcpy(printCommand, &(*argv)[1]); printCommand[strlen(printCommand)-1] = '\0'; } else { strcpy(printCommand, *argv); } } else if (strcmp(*argv, "-j2p6_cmd") == 0) { argc--; argv++; if (argc <= 0) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-j2p6_cmd"); fprintf(stderr, "\n\n"); Usage(progName); } len = strlen(*argv); if (**argv == '"' && (*argv)[len-1] == '"') { if (len-3 >= MAXSTRING) { fprintf(stderr, TgLoadString(STID_CMDLINE_ARG_GIVEN_TOO_LONG), "-j2p6_cmd"); fprintf(stderr, "\n"); } else { strcpy(cmdLineJpegToPpm6Cmd, &(*argv)[1]); cmdLineJpegToPpm6Cmd[strlen(cmdLineJpegToPpm6Cmd)-1] = '\0'; } } else { if (len-1 >= MAXSTRING) { fprintf(stderr, TgLoadString(STID_CMDLINE_ARG_GIVEN_TOO_LONG), "-j2p6_cmd"); fprintf(stderr, "\n"); } else { strcpy(cmdLineJpegToPpm6Cmd, *argv); cmdLineJpegToPpm6Cmd[strlen(cmdLineJpegToPpm6Cmd)-1] = '\0'; } } } else if (strcmp(*argv, "-patterndir") == 0) { argc--; argv++; if (argc <= 0) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-patterndir"); fprintf(stderr, "\n\n"); Usage(progName); } UtilStrCpyN(cmdLineCustomPatternDir, sizeof(cmdLineCustomPatternDir), *argv); UtilTrimBlanks(cmdLineCustomPatternDir); len = strlen(cmdLineCustomPatternDir); if (len > 0 && cmdLineCustomPatternDir[len-1] == DIR_SEP) { cmdLineCustomPatternDir[len-1] = '\0'; } if (*cmdLineCustomPatternDir == '\0' || !UtilIsDirectory(cmdLineCustomPatternDir)) { fprintf(stderr, TgLoadString(STID_PATTERNDIR_NOT_EXIST), cmdLineCustomPatternDir); fprintf(stderr, "\n"); *cmdLineCustomPatternDir = '\0'; } } else if (strncmp(*argv, "-o", 2) == 0) { strcpy(outputDir, &(*argv)[2]); } else if (strcmp(*argv, "-prtgif") != 0 && strcmp(*argv, "-print") != 0 && strcmp(*argv, "-PRINT") != 0) { strcat(c_ptr++, " "); strcat(c_ptr, *argv); c_ptr += strlen(*argv); } } else { break; } } if (cmdLineOneFilePerPage) { if ((!cmdLineOpenDisplay && whereToPrint == PRINTER) || (cmdLineOpenDisplay && cmdLineWhereToPrint == INVALID)) { fprintf(stderr, TgLoadString(STID_PRINT_TO_PRINTER_INCOMPAT), "-one_file_page_page"); fprintf(stderr, "\n\n"); Usage(progName); } } return argc; } int ProcessTgifOptions(argc, argv, file_name, name_sz) int argc, name_sz; char *argv[], *file_name; /* All these strangeness with strings are related to */ /* Prolog's foreign function interface. */ { int i=0, len=0; *file_name = '\0'; *cmdLineTmpFileModeStr = '\0'; *cmdLineGenParser = '\0'; *cmdLineFileToExec = '\0'; *cmdLineRMCastLibDir = *cmdLineRMCastLibPath = '\0'; *cmdLineCustomPatternDir = '\0'; cmdLineMergeArgv = NULL; for (i=1; i < argc; i++) { if (strcmp(argv[i], "-display") == 0) { if (++i == argc) { fprintf(stderr, "%s\n\n", TgLoadString(STID_MISSING_DISPLAY_NAME)); Usage(progName); } if ((displayName=UtilStrDup(argv[i])) == NULL) FailAllocMessage(); } else if (strcmp(argv[i], "-tgrm2") == 0) { cmdLineTgrm2 = TRUE; } else if (strcmp(argv[i], "-rmcastlibdir") == 0) { if (++i == argc) { fprintf(stderr, "%s\n\n", TgLoadString(STID_MISSING_RMCASTDIR)); Usage(progName); } UtilStrCpyN(cmdLineRMCastLibDir, sizeof(cmdLineRMCastLibDir), argv[i]); } else if (strcmp(argv[i], "-rmcastlibpath") == 0) { if (++i == argc) { fprintf(stderr, "%s\n\n", TgLoadString(STID_MISSING_RMCASTLIB)); Usage(progName); } UtilStrCpyN(cmdLineRMCastLibPath, sizeof(cmdLineRMCastLibPath), argv[i]); } else if (strcmp(argv[i], "-tgwb2") == 0) { cmdLineWb2 = TRUE; } else if (strcmp(argv[i], "-bw") == 0) { cmdLineBW = TRUE; } else if (strcmp(argv[i], "-parent") == 0) { if (++i == argc) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-parent"); fprintf(stderr, "\n\n"); Usage(progName); } if (strncmp(argv[i], "0x", 2) == 0) { if (sscanf(&(argv[i])[2], "%x", &cmdLineParentWindowID) != 1) { fprintf(stderr, TgLoadString(STID_FAIL_TO_PARSE_FOR_A_VAL), argv[i]); fprintf(stderr, "\n\n"); Usage(progName); } } else { if (sscanf(argv[i], "%d", &cmdLineParentWindowID) != 1) { fprintf(stderr, TgLoadString(STID_FAIL_TO_PARSE_FOR_A_VAL), argv[i]); fprintf(stderr, "\n\n"); Usage(progName); } } } else if (strcmp(argv[i], "-reqcolor") == 0) { cmdLineRequestedColor = TRUE; } else if (strcmp(argv[i], "-rv") == 0) { cmdLineRV = TRUE; } else if (strcmp(argv[i], "-nv") == 0) { cmdLineRV = FALSE; } else if (strcmp(argv[i], "-cwo") == 0) { cmdLineCWO = TRUE; cmdLineBtn1Warp = FALSE; } else if (strcmp(argv[i], "-cwo+sbwarp") == 0) { cmdLineCWO = TRUE; cmdLineBtn1Warp = TRUE; } else if (strcmp(argv[i], "-hyper") == 0) { inHyperSpace = TRUE; } else if (strcmp(argv[i], "-exec") == 0) { if (++i == argc) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-exec"); fprintf(stderr, "\n\n"); Usage(progName); } UtilStrCpyN(cmdLineFileToExec, sizeof(cmdLineFileToExec), argv[i]); UtilTrimBlanks(cmdLineFileToExec); if (*cmdLineFileToExec == '-' && cmdLineFileToExec[1] != '\0') { fprintf(stderr, "%s\n\n", TgLoadString(STID_BAD_EXEC_FNAME_DASH)); Usage(progName); } } else if (strcmp(argv[i], "-dbim") == 0) { if (++i == argc) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-dbim"); fprintf(stderr, "\n\n"); Usage(progName); } if (cmdLineHasInputMethod) { fprintf(stderr, "%s\n\n", TgLoadString(STID_ONLYONE_DBIM_OR_SBIM)); Usage(progName); } strcpy(cmdLineInputMethod, argv[i]); cmdLineHasInputMethod = TRUE; cmdLineDoubleByteInputMethod = TRUE; } else if (strcmp(argv[i], "-sbim") == 0) { if (++i == argc) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-sbim"); fprintf(stderr, "\n\n"); Usage(progName); } if (cmdLineHasInputMethod) { fprintf(stderr, "%s\n\n", TgLoadString(STID_ONLYONE_DBIM_OR_SBIM)); Usage(progName); } strcpy(cmdLineInputMethod, argv[i]); cmdLineHasInputMethod = TRUE; cmdLineDoubleByteInputMethod = FALSE; } else if (strcmp(argv[i], "-usexlib") == 0) { cmdLineUseXlib = TRUE; } else if (strcmp(argv[i], "-merge") == 0) { cmdLineMerge = TRUE; } else if (strcmp(argv[i], "-a4") == 0) { cmdLineA4 = TRUE; } else if (strcmp(argv[i], "-letter") == 0) { cmdLineLetter = TRUE; #ifdef NOT_DEFINED } else if (strcmp(argv[i], "-listen") == 0) { cmdLineWhiteBoardListenOnly = TRUE; #endif /* NOT_DEFINED */ } else if (strcmp(argv[i], "-no-wb") == 0) { cmdLineNoWhiteBoard = TRUE; } else if (strcmp(argv[i], "-no-chat") == 0) { cmdLineNoChatWindow = TRUE; } else if (strcmp(argv[i], "-chatnick") == 0) { if (++i == argc) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-chatnick"); fprintf(stderr, "\n\n"); Usage(progName); } cmdLineChatNickName = UtilStrDup(argv[i]); if (cmdLineChatNickName == NULL) FailAllocMessage(); } else if (strcmp(argv[i], "-fg") == 0) { if (++i == argc) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-fg"); fprintf(stderr, "\n\n"); Usage(progName); } cmdLineForeground = (char*)malloc(80*sizeof(char)); if (cmdLineForeground == NULL) FailAllocMessage(); strcpy(cmdLineForeground, argv[i]); } else if (strcmp(argv[i], "-bg") == 0) { if (++i == argc) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-bg"); fprintf(stderr, "\n\n"); Usage(progName); } cmdLineBackground = (char*)malloc(80*sizeof(char)); if (cmdLineBackground == NULL) FailAllocMessage(); strcpy(cmdLineBackground, argv[i]); } else if (strcmp(argv[i], "-bd") == 0) { if (++i == argc) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-bd"); fprintf(stderr, "\n\n"); Usage(progName); } cmdLineBorder = (char*)malloc(80*sizeof(char)); if (cmdLineBorder == NULL) FailAllocMessage(); strcpy(cmdLineBorder, argv[i]); } else if (strcmp(argv[i], "-geometry") == 0) { if (++i == argc) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-geometry"); fprintf(stderr, "\n\n"); Usage(progName); } strcat(geometrySpec, argv[i]); geometrySpecified = TRUE; } else if (strcmp(argv[i], "-listdontreencode") == 0) { #ifdef _DONT_REENCODE fprintf(stderr, "-D_DONT_REENCODE=\"%s\"\n", _DONT_REENCODE); #endif /* _DONT_REENCODE */ } else if (strcmp(argv[i], "-version") == 0 || strcmp(argv[i], "--version") == 0) { cmdLineVersion = TRUE; } else if (strcmp(argv[i], "-nomode") == 0) { cmdLineNoModeWindow = TRUE; } else if (strcmp(argv[i], "-pdfspd") == 0) { cmdLinePdfSetPageDevice = TRUE; } else if (strncmp(argv[i], "-pdfspd=", 8) == 0) { char tmp_str[80]; UtilStrCpyN(tmp_str, sizeof(tmp_str), &(argv[i])[8]); UtilTrimBlanks(tmp_str); if (UtilStrICmp(tmp_str, "true") == 0) { cmdLinePdfSetPageDevice = TRUE; } else if (UtilStrICmp(tmp_str, "false") == 0) { cmdLinePdfSetPageDevice = FALSE; } else { fprintf(stderr, TgLoadString(STID_BAD_CMDLINE_OPT_IGNORED), "-pdfspd", tmp_str); fprintf(stderr, "\n"); } } else if (strcmp(argv[i], "-pssetup") == 0) { i++; if (i >= argc) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-pssetup"); fprintf(stderr, "\n\n"); Usage(progName); } cmdLinePsSetup = TRUE; SetPsSetup(argv[i]); } else if (strcmp(*argv, "-patterndir") == 0) { argc--; argv++; if (argc <= 0) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-patterndir"); fprintf(stderr, "\n\n"); Usage(progName); } UtilStrCpyN(cmdLineCustomPatternDir, sizeof(cmdLineCustomPatternDir), *argv); UtilTrimBlanks(cmdLineCustomPatternDir); len = strlen(cmdLineCustomPatternDir); if (len > 0 && cmdLineCustomPatternDir[len-1] == DIR_SEP) { cmdLineCustomPatternDir[len-1] = '\0'; } if (*cmdLineCustomPatternDir == '\0' || !UtilIsDirectory(cmdLineCustomPatternDir)) { fprintf(stderr, TgLoadString(STID_PATTERNDIR_NOT_EXIST), cmdLineCustomPatternDir); fprintf(stderr, "\n"); *cmdLineCustomPatternDir = '\0'; } } else if (argv[i][0] == '=') { strcpy(geometrySpec, argv[i]); geometrySpecified = TRUE; } else if (argv[i][0] != '-') { if (cmdLineMerge) { int j=0; cmdLineMergeArgc = argc-i; cmdLineMergeArgv = (char**)malloc(cmdLineMergeArgc*sizeof(char*)); if (cmdLineMergeArgv == NULL) FailAllocMessage(); for (j=i; j < argc; j++) { if (*argv[j] == '-') { Usage(progName); } cmdLineMergeArgv[j-i] = UtilStrDup(argv[j]); if (cmdLineMergeArgv[j-i] == NULL) FailAllocMessage(); } break; } else { UtilStrCpyN(file_name, name_sz, argv[i]); } } else { #ifndef USE_XT_INITIALIZE Usage(progName); #else /* USE_XT_INITIALIZE */ if (strcmp(argv[i], "-xrm") == 0) { if (++i == argc) { fprintf(stderr, TgLoadString(STID_MISSING_ARG_FOR_CMDLINE_OPT), "-xrm"); fprintf(stderr, "\n"); } } #endif /* ~USE_XT_INITIALIZE */ } } return TRUE; } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tcp.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000003112�11602233313�013716� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tcp.e,v 1.6 2011/05/16 16:21:59 william Exp $ */ #ifndef _TGIF_TCP_E_ #define _TGIF_TCP_E_ #ifdef _INCLUDE_FROM_TCP_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TCP_C_*/ extern void SetSocketBlockingState ARGS_DECL((int *pn_socket, int)); extern void TcpFreeBuf ARGS_DECL((char *buf)); extern int TcpDoConnect ARGS_DECL((char *psz_host, int us_port, int *pn_socket)); extern int TcpDoWrite ARGS_DECL((int n_socket, char *buf, int buf_sz)); extern int TcpDoRead ARGS_DECL((int n_socket, char **ppsz_buf, int *pn_buf_sz)); #ifdef _INCLUDE_FROM_TCP_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TCP_C_*/ #endif /*_TGIF_TCP_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/ftp.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000003263�11602233311�013726� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/ftp.e,v 1.6 2011/05/16 16:21:57 william Exp $ */ #ifndef _TGIF_FTP_E_ #define _TGIF_FTP_E_ extern int debugFtp; #ifdef _INCLUDE_FROM_FTP_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_FTP_C_*/ extern void FtpFreeBuf ARGS_DECL((char *buf)); extern void FtpDebug ARGS_DECL((int)); extern int FtpDoConnect ARGS_DECL((char *psz_host, int us_port, int *pn_socket)); extern int FtpDoWrite ARGS_DECL((int n_socket, char *psz_path)); extern int FtpDoRead ARGS_DECL((int n_socket, char **ppsz_buf, int *pn_buf_sz)); extern int FtpDoTalk ARGS_DECL((int n_socket, char *psz_path, char **ppsz_buf, int *pn_buf_sz)); #ifdef _INCLUDE_FROM_FTP_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_FTP_C_*/ #endif /*_TGIF_FTP_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/LICENSE.QPL��������������������������������������������������������������������������0000644�0000764�0000764�00000011160�11602233314�014425� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������� THE Q PUBLIC LICENSE version 1.0 Copyright (C) 1999-2000 Trolltech AS, Norway. Everyone is permitted to copy and distribute this license document. The intent of this license is to establish freedom to share and change the software regulated by this license under the open source model. This license applies to any software containing a notice placed by the copyright holder saying that it may be distributed under the terms of the Q Public License version 1.0. Such software is herein referred to as the Software. This license covers modification and distribution of the Software, use of third-party application programs based on the Software, and development of free software which uses the Software. Granted Rights 1. You are granted the non-exclusive rights set forth in this license provided you agree to and comply with any and all conditions in this license. Whole or partial distribution of the Software, or software items that link with the Software, in any form signifies acceptance of this license. 2. You may copy and distribute the Software in unmodified form provided that the entire package, including - but not restricted to - copyright, trademark notices and disclaimers, as released by the initial developer of the Software, is distributed. 3. You may make modifications to the Software and distribute your modifications, in a form that is separate from the Software, such as patches. The following restrictions apply to modifications: a. Modifications must not alter or remove any copyright notices in the Software. b. When modifications to the Software are released under this license, a non-exclusive royalty-free right is granted to the initial developer of the Software to distribute your modification in future versions of the Software provided such versions remain available under these terms in addition to any other license(s) of the initial developer. 4. You may distribute machine-executable forms of the Software or machine-executable forms of modified versions of the Software, provided that you meet these restrictions: a. You must include this license document in the distribution. b. You must ensure that all recipients of the machine-executable forms are also able to receive the complete machine-readable source code to the distributed Software, including all modifications, without any charge beyond the costs of data transfer, and place prominent notices in the distribution explaining this. c. You must ensure that all modifications included in the machine-executable forms are available under the terms of this license. 5. You may use the original or modified versions of the Software to compile, link and run application programs legally developed by you or by others. 6. You may develop application programs, reusable components and other software items that link with the original or modified versions of the Software. These items, when distributed, are subject to the following requirements: a. You must ensure that all recipients of machine-executable forms of these items are also able to receive and use the complete machine-readable source code to the items without any charge beyond the costs of data transfer. b. You must explicitly license all recipients of your items to use and re-distribute original and modified versions of the items in both machine-executable and source code forms. The recipients must be able to do so without any charges whatsoever, and they must be able to re-distribute to anyone they choose. c. If the items are not available to the general public, and the initial developer of the Software requests a copy of the items, then you must supply one. Limitations of Liability In no event shall the initial developers or copyright holders be liable for any damages whatsoever, including - but not restricted to - lost revenue or profits or other direct, indirect, special, incidental or consequential damages, even if they have been advised of the possibility of such damages, except to the extent invariable law, if any, provides otherwise. No Warranty The Software and this license document are provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. Choice of Law This license is governed by the Laws of United States. Disputes shall be settled by Los Angeles City Court, California, USA. ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/choice.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000005727�11602233311�014376� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/choice.e,v 1.6 2011/05/16 16:21:56 william Exp $ */ #ifndef _CHOICE_E_ #define _CHOICE_E_ extern int curChoice; extern int cycleThroughChoice; extern int setCurChoiceDontUpdateUI; #ifdef _INCLUDE_FROM_CHOICE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_CHOICE_C_*/ extern void InitChoice ARGS_DECL((void)); extern void CleanUpChoices ARGS_DECL((void)); extern void ShowColor ARGS_DECL((int PropagateWhereToPrint)); extern void ShowHoriAlign ARGS_DECL((void)); extern void ShowVertAlign ARGS_DECL((void)); extern void ShowJust ARGS_DECL((void)); extern void ShowCurFont ARGS_DECL((void)); extern void ShowTextVSpace ARGS_DECL((void)); extern void ShowZoom ARGS_DECL((void)); extern void ShowTextSize ARGS_DECL((void)); extern void ShowRotate ARGS_DECL((void)); extern void ShowLineWidth ARGS_DECL((void)); extern void ShowLineStyle ARGS_DECL((void)); extern void ShowLineType ARGS_DECL((void)); extern void ShowDash ARGS_DECL((void)); extern void ShowWhereToPrint ARGS_DECL((void)); extern void ShowFile ARGS_DECL((void)); extern void ShowRCBRadius ARGS_DECL((void)); extern void ShowMoveMode ARGS_DECL((void)); extern void ShowShape ARGS_DECL((void)); extern void ShowStretchableTextMode ARGS_DECL((void)); extern void ShowFill ARGS_DECL((void)); extern void ShowTransPatMode ARGS_DECL((void)); extern void ShowPen ARGS_DECL((void)); extern void ShowPage ARGS_DECL((void)); extern void ShowPageLayout ARGS_DECL((void)); extern void ShowCurChoiceMouseStatus ARGS_DECL((int choice, unsigned int state, int cur_text_under_mouse)); extern void SetCurChoice ARGS_DECL((int NewChoice)); extern void PushCurChoice ARGS_DECL((void)); extern void FormatFloat ARGS_DECL((float *pfval, char *buf)); extern void FormatAngle ARGS_DECL((int DegreeTimes64, char *buf)); extern int ChoiceEventHandler ARGS_DECL((XEvent *)); extern void RedrawModeWindow ARGS_DECL((void)); extern int ModeEventHandler ARGS_DECL((XEvent *)); #ifdef _INCLUDE_FROM_CHOICE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_CHOICE_C_*/ #endif /*_CHOICE_E_*/ �����������������������������������������tgif-QPL-4.2.5/version.e����������������������������������������������������������������������������0000644�0000764�0000764�00000003245�11602233313�014624� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/version.e,v 1.6 2011/05/16 16:22:00 william Exp $ */ #ifndef _VERSION_E_ #define _VERSION_E_ extern char *versionString; extern char *authorEmailString; extern char *copyrightString; extern char *homePageURL; extern char *oldMailingList; extern char *mailingList; extern char *joinMailingList; extern char *mailingURL; extern char *currentReleaseURL; extern char *hyperGraphicsURL; extern char fullVersionString[]; extern char fullToolName[]; extern char *specialBuild; #ifdef _INCLUDE_FROM_VERSION_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_VERSION_C_*/ extern void SetFullVersionString ARGS_DECL((void)); extern void InitVersion ARGS_DECL((void)); #ifdef _INCLUDE_FROM_VERSION_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_VERSION_C_*/ #endif /*_VERSION_E_*/ �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/descrip.mms��������������������������������������������������������������������������0000644�0000764�0000764�00000015106�11602233311�015135� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# # @(#)$Header: /mm2/home/cvs/bc-src/tgif/descrip.mms,v 1.1 2004/06/18 23:20:49 william Exp $ # # VMS MAKEFILE (DESCRIP.MSS) # 25-MAR-91 GJC@MITECH.COM # # Before running this define these logical names: # $ DEFINE X11 DECW$INCLUDE # $ DEFINE SYS SYS$LIBRARY # # 24-NOV-97 Rolf Niepraschk, niepraschk@ptb.de # O = .O E = .EXE XBM = [.XBM] .SUFFIXES : ! clear the suffix list first .SUFFIXES : $(X) $(O) .C .C$(O) : $(CC) /OBJ=$@ $(CFLAGS) $< TGIFEXE = TGIF$(E) TGIFLIB = TGIF.OLB MISCLIB =,DESCRIP.OPT/OPT # CFLAGS = $(DEFINES)/debug/nooptimize/list/show=(nosource)/object=$(mms$target_name).obj CFLAGS = /prefix=(ALL,EXCEPT=(delete,select))\ /WARN=(DISABLE=(LONGEXTERN,EMPTYFILE,IMPLICITFUNC))$(DEFINES) # LFLAGS = /DEBUG/MAP DEFINES = /DEFINE=(TGIF_PATH="""""", \ VMS=1, PSFILE_MOD="0664",\ EPSF_FILE_EXT="""eps""", PS_FILE_EXT="""ps""", \ XBM_FILE_EXT="""xbm""", XPM_FILE_EXT="""xpm""", \ OBJ_FILE_EXT="""obj""", SYM_FILE_EXT="""sym""", \ TEXT_FILE_EXT="""txt""", PIN_FILE_EXT="""pin""", \ TELEPORT_ATTR="""warp_to=""", LAUNCH_ATTR="""launch=""", \ EXEC_ATTR="""exec=""", \ TMP_DIR="""/sys$scratch/""" $(D10)$(D11)$(D12)$(D13)$(D14)$(D15)$(D16)$(D17)$(D18)$(D19)\ $(D20)$(D21)$(D22)$(D23)$(D24)$(D25)$(D26)$(D27)$(D28)$(D29)\ $(D30)$(D31)$(D32)$(D33)$(D34)$(D35)$(D36)$(D37)$(D38)$(D39)\ $(D40)$(D41)$(D42)$(D43)$(D44)$(D45)$(D46)$(D47)$(D48)$(D49)) D10=,"dumpOneFilePerPage=_dumpOneFilePerPage" D11=,"execNavigateBack=_execNavigateBack" D12=,"navigateRefresh=_navigateRefresh" D13=,F_SETFL=0,F_GETFL=1 # ??? D14=,"unlink=delete" # # D42=,METRIC_PIX_PER_INCH=1 # Include the above line if you want to use 127 pixels per inch # when printing in the metric system. If this line is not # included, 128 pixels per inch is used. D41=,_NO_GETTIMEOFDAY # Include the above line if you do not have the gettimeofday() # function but have the ftime() function. # D40=,BSD_COMP # Include the above line if you are compiling on a Solaris (or # possibly an SGI) machine which requires it in <sys/ioctl.h>. # (If you see the error that FIONBIO is not defined when compiling # tcp.c, then you probably need this.) # D39=,_HANDLE_SIGCHLD # Include the above line if there are defunct tgif child processes. # D38=,_NO_LSTAT # Include the above line if lstat() is not available. In this case, # using BrowseXBitmap and BrowseXPixmap under the File Menu may cause # infinite loop if the directory structure is infinitely recursive. # D37=,_USE_XDRAWPOINT_TO_PUT_A_POINT # Include the above line if the grid points are not visible. This can # be used to bypass some X server bugs (such as certain Linux X server # using VGA16 screen) where the XDrawLine() Xlib call does not work # properly. # D36=,_NO_EXTERN (obsoleted) # Include the above line in the DEFINES if you don't want to include # the extern definition for functions defined in a module. For example, # if this option is set, then file "foo.c" will not include "foo.e", # and certain other extern definition in "foo.c" will be omitted. # D35=,_NO_PROTO # Include the above line in the DEFINES if checking for function # prototypes is not desired. Checking for function prototypes # are automatically enabled if you are using an ANSI or C++ compilor. # However, not all ANSI/C++ compilors are created equal. # D34=,NO_STRSTR # Include the above line in the DEFINES if you do not have the strstr() # function in your system's string library. # D33=,INVERT_CTM_BUG # Include the above line in the DEFINES if you are using PostScript # utilities which fails when trying to invert non-invertible CTM # (e.g., muluti.ps from ftp.ucc.su.oz.au:/pub/ps_printing/multi). # D32=,HP_LINE_BUG # Include the above line in the DEFINES if two-vertices horizontal and # verticle line segments don't draw properly on a buggy HP server. # D31=,DONTFREECOLORS # Include the above line in the DEFINES if you don't want the black and # the white colors to be freed when tgif initializes itself. You should # not need to do this unless to get around some server bugs. # D30=,USE_XAPPLRESDIR # Include the above line in the DEFINES if $XAPPLRESDIR/Tgif is used to # specify the resource file. If your system does not have putenv() # (such as IBM-RT), then this won't work. I'm not sure if VMS systems # have putenv(), so this might be useless for VMS systems. # D29=,XAPPLOADDIR_DEF # If you define USE_XAPPLRESDIR, define this to a default directory # to use in case $XAPPLRESDIR isn't set. # D28=,USE_XT_INITIALIZE # This will cause the XToolkit to be initialized so that the X defaults # are obtained from the Xt directories. This should only be used when # USE_XAPPLRESDIR option is NOT used. # D27=,NO_THIN_LINE # Include the above line in the DEFINES if a line width of 0 causes # your server to crash. This is to get around a bug in some X servers. # D26=,THIN_OVAL_AND_ARC # Include the above line in the DEFINES if you want 0 width arcs to # be used when the width of an arc is less than or equal to 1. # (Sun3 server has a bug that makes drawing ovals and arcs with # width other than 0 VERY slow). # D25=,KEEP_WHEN_PRINT # Include the above line in the DEFINES if you don't want the temp # file to be deleted after sending the print job to the printer. # (Some VMS systems might require this flag to be used.) # D24=,PRINT_CMD="""print""" # Include the above line in the DEFINES if you want to configure tgif # to use a default print command. # D23=,NOTR4MODE # Include the above line in the DEFINES if you are running X11R3. # This will cause tgif NOT to use some X11R4 window manager related # functions that's not present in R3. # D22=,MAPBEFORESELECT # Include the above line in the DEFINES to call XMapWindow() before # calling XSelectInput(). This might be needed to get around some # server bugs. # D21=,DONT_FREE_COLORMAP="""true""" # Include the above line in the DEFINES if you don't want the colormap # to be freed when tgif exits. D20=,A4PAPER # Include the above line in the DEFINES if you want to print on A4 paper # (8.25in by 11.7in or about 21cm by 29.7cm). .FIRST @ DEFINE XMB [.XBM] @ DEFINE X11 DECW$INCLUDE ALL : $(TGIFEXE) $(TGIFLIB) @ ! INCLUDE make.common $(TGIFEXE) : $(TGIFLIB) LINK/EXE=$@ $</LIB/INCLUDE=TGIF $(MISCLIB) $(TGIFLIB) : $(OBJS) IF F$SEARCH("$@") .EQS. "" THEN LIBRARY/CREATE $@ LIBRARY/obj $@ $+ CLEAN : IF F$SEARCH("*$(O)",).NES."" THEN DEL *$(O);* IF F$SEARCH("$(TGIFLIB)",).NES."" THEN DEL $(TGIFLIB);* VERYCLEAN : CLEAN IF F$SEARCH("$(TGIFEXE)",).NES."" THEN DEL $(TGIFEXE);* INCLUDE make.comdep ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/eq4-ps2epsi.sym����������������������������������������������������������������������0000644�0000764�0000764�00000034433�11602233311�015600� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.43 state(0,37,100.000,0,0,0,8,1,3,1,1,0,0,1,0,1,0,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/eq4-ps2epsi.sym,v 1.1 2004/06/18 23:20:01 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1 ]). slideshow_info('',-20,-20). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). dont_reencode("UtopiaFS:FFDingbests:ZapfDingbats"). ps_font_aliases([ "UtopiaFS-Regular=Utopia-Regular", "UtopiaFS-Bold=Utopia-Bold", "UtopiaFS-Italic=Utopia-Italic", "UtopiaFS-BoldItalic=Utopia-BoldItalic" ]). page(1,"LaTeX equation symbol (uses ghostscript's ps2epsi).",1,''). group([ text('#0000ff',224,194,4,0,1,394,69,1039,14,3,0,-1,0,0,2,394,69,0,2,"",0,0,0,0,208,'',[ minilines(394,69,0,2,0,-1,0,[ mini_line(394,14,5,0,2,0,[ str_block(0,107,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,107,14,3,0,-2,0,0,0,0,0, "Make sure that ")]), str_block(0,32,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,32,14,3,0,2,0,0,0,0,0, "latex")]), str_block(0,8,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,8,14,3,0,-3,0,0,0,0,0, ", ")]), str_block(0,38,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,38,14,3,0,1,0,0,0,0,0, "dvips")]), str_block(0,38,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,38,14,3,0,-2,0,0,0,0,0, ", and ")]), str_block(0,54,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,54,14,3,0,2,0,0,0,0,0, "ps2epsi")]), str_block(0,81,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,81,14,3,0,-2,0,0,0,0,0, " are in your ")]), str_block(0,32,13,5,0,0,0,0,0,[ str_seg('#ff00ff','Courier-Bold',1,80640,32,13,5,0,0,0,0,0,0,0, "PATH")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]), mini_line(370,14,3,0,1,0,[ str_block(0,228,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,228,14,3,0,-3,0,0,0,0,0, "After you instantiate this symbol, ")]), str_block(0,84,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,84,14,3,0,1,0,0,0,0,0, "double-click")]), str_block(0,58,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,58,14,3,0,1,0,0,0,0,0, " it to run")]) ]), mini_line(386,14,5,0,0,0,[ str_block(0,362,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,-3,0,0,0,0,0, "the latex scripts. Afterwards, you can hide/show the ")]), str_block(0,24,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,13,5,0,0,0,0,0,0,0, "eq=")]) ]), mini_line(247,14,3,0,1,0,[ str_block(0,148,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,148,14,3,0,-3,0,0,0,0,0, "attribute by pressing ")]), str_block(0,95,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,95,14,3,0,1,0,0,0,0,0, "<Alt><Cntrl>7")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]) ])]), text('#0000ff',192,194,1,0,1,19,17,651,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,208,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(3)")]) ]) ])]), text('#0000ff',192,106,1,0,1,19,17,656,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,120,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(2)")]) ]) ])]), text('#0000ff',224,106,5,0,1,410,81,657,14,3,0,-1,0,0,2,410,81,0,2,"",0,0,0,0,120,'',[ minilines(410,81,0,2,0,-1,0,[ mini_line(325,14,3,0,1,0,[ str_block(0,325,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,325,14,3,0,1,0,0,0,0,0, "This version of the LaTeX equation symbol uses")]) ]), mini_line(384,14,3,0,2,0,[ str_block(0,102,14,3,0,2,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,102,14,3,0,2,0,0,0,0,0, "ghostscript's \"")]), str_block(0,54,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,54,14,3,0,2,0,0,0,0,0, "ps2epsi")]), str_block(0,228,14,3,0,1,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,228,14,3,0,1,0,0,0,0,0, "\" to add a preview bitmap to a PS")]) ]), mini_line(354,14,3,0,2,0,[ str_block(0,129,14,3,0,-3,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,129,14,3,0,-3,0,0,0,0,0, "file. If want to use ")]), str_block(0,7,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,7,14,3,0,2,0,0,0,0,0, "\"")]), str_block(0,59,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,59,14,3,0,2,0,0,0,0,0, "pstoepsi")]), str_block(0,96,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,96,14,3,0,2,0,0,0,0,0, "\", please use\"")]), str_block(0,56,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,56,14,3,0,1,0,0,0,0,0, "eq4.sym")]), str_block(0,7,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,7,14,3,0,2,0,0,0,0,0, "\"")]) ]), mini_line(410,14,3,0,2,0,[ str_block(0,195,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,195,14,3,0,2,0,0,0,0,0, "instead. Information about \"")]), str_block(0,59,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,59,14,3,0,2,0,0,0,0,0, "pstoepsi")]), str_block(0,156,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,156,14,3,0,1,0,0,0,0,0, "\" can be obtained from")]) ]), mini_line(373,14,3,0,2,0,[ str_block(0,42,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,42,14,3,0,1,0,0,0,0,0, "<URL:")]), str_block(0,318,14,3,0,2,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,318,14,3,0,2,0,0,0,0,0, "http://bourbon.cs.umd.edu:8001/tgif/tools.html")]), str_block(0,13,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,13,14,3,0,-1,0,0,0,0,0, ">.")]) ]) ])]), text('#0000ff',224,50,3,0,1,362,49,643,14,3,0,-1,0,0,2,362,49,0,1,"",0,0,0,0,64,'',[ minilines(362,49,0,1,0,-1,0,[ mini_line(325,14,3,0,0,0,[ str_block(0,189,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,189,14,3,0,-3,0,0,0,0,0, "Make sure you are running ")]), str_block(0,68,14,3,0,0,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,68,14,3,0,0,0,0,0,0,0, "tgif-4.1.11")]), str_block(0,68,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,68,14,3,0,-1,0,0,0,0,0, " or newer.")]) ]), mini_line(362,14,3,0,1,0,[ str_block(0,362,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,1,0,0,0,0,0, "You can find out what version of tgif you are running")]) ]), mini_line(300,14,3,0,0,0,[ str_block(0,300,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,300,14,3,0,-1,0,0,0,0,0, "by selecting About() from the Special menu.")]) ]) ])]), text('#0000ff',192,50,1,0,1,19,17,863,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,64,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(1)")]) ]) ])]) ], 1058,0,0,[ ]). sym([ polygon('#0000ff','',5,[ 64,132,68,132,68,128,64,128,64,132],0,1,0,0,212,0,0,0,0,0,'1',0, "00",[ ]) ], 1126,0,0,[ attr("footer=", "", 0, 1, 0, text('#ff00ff',64,-21,3,0,1,112,54,613,13,5,0,0,0,0,2,112,54,0,0,"",0,0,0,0,-8,'',[ minilines(112,54,0,0,0,0,0,[ mini_line(56,13,5,0,0,0,[ str_block(0,56,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,56,13,5,0,0,0,0,0,0,0, "footer=")]) ]), mini_line(8,13,5,0,0,0,[ str_block(0,8,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,8,13,5,0,-1,0,0,0,0,0, "%")]) ]), mini_line(112,13,5,0,0,0,[ str_block(0,112,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,112,13,5,0,-1,0,0,0,0,0, "\\end{document}")]) ]) ])])), attr("header=", "", 0, 1, 0, text('#ff00ff',240,-21,11,0,1,240,198,608,13,5,0,0,0,0,2,240,198,0,0,"",0,0,0,0,-8,'',[ minilines(240,198,0,0,0,0,0,[ mini_line(56,13,5,0,0,0,[ str_block(0,56,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,56,13,5,0,0,0,0,0,0,0, "header=")]) ]), mini_line(232,13,5,0,0,0,[ str_block(0,232,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,232,13,5,0,-1,0,0,0,0,0, "\\documentstyle[12pt]{article}")]) ]), mini_line(144,13,5,0,0,0,[ str_block(0,144,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,5,0,0,0,0,0,0,0, "\\oddsidemargin=0in")]) ]), mini_line(128,13,5,0,0,0,[ str_block(0,128,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,13,5,0,0,0,0,0,0,0, "\\textwidth=6.5in")]) ]), mini_line(112,13,5,0,0,0,[ str_block(0,112,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,112,13,5,0,0,0,0,0,0,0, "\\topmargin=0in")]) ]), mini_line(136,13,5,0,0,0,[ str_block(0,136,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,136,13,5,0,-1,0,0,0,0,0, "\\textheight=609pt")]) ]), mini_line(104,13,5,0,0,0,[ str_block(0,104,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,13,5,0,-1,0,0,0,0,0, "\\parskip=14pt")]) ]), mini_line(240,13,5,0,0,0,[ str_block(0,240,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,240,13,5,0,-1,0,0,0,0,0, "\\setlength{\\unitlength}{0.5cm}")]) ]), mini_line(136,13,5,0,0,0,[ str_block(0,136,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,136,13,5,0,-1,0,0,0,0,0, "\\pagestyle{empty}")]) ]), mini_line(128,13,5,0,0,0,[ str_block(0,128,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,13,5,0,-1,0,0,0,0,0, "\\begin{document}")]) ]), mini_line(8,13,5,0,0,0,[ str_block(0,8,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,8,13,5,0,-1,0,0,0,0,0, "%")]) ]) ])])), attr("exec=", "", 0, 1, 0, text('blue',64,-272,8,0,1,424,144,23,13,5,0,0,0,0,2,424,144,0,0,"",0,0,0,0,-259,'',[ minilines(424,144,0,0,0,0,0,[ mini_line(40,13,5,0,0,0,[ str_block(0,40,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,40,13,5,0,0,0,0,0,0,0, "exec=")]) ]), mini_line(336,13,5,0,0,0,[ str_block(0,336,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,336,13,5,0,-2,0,0,0,0,0, " mktemp(\"/tmp/TgifXXXXXX\",\"file_name\");")]) ]), mini_line(416,13,5,0,0,0,[ str_block(0,416,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,416,13,5,0,-2,0,0,0,0,0, " write_attr_into_file(header,\"$(file_name).tex\");")]) ]), mini_line(392,13,5,0,0,0,[ str_block(0,392,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,392,13,5,0,-2,0,0,0,0,0, " append_attr_into_file(eq,\"$(file_name).tex\");")]) ]), mini_line(424,13,5,0,0,0,[ str_block(0,424,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,424,13,5,0,-2,0,0,0,0,0, " append_attr_into_file(footer,\"$(file_name).tex\");")]) ]), mini_line(144,13,5,0,0,0,[ str_block(0,144,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,5,0,-2,0,0,0,0,0, " launch(\"cmd\");")]) ]), mini_line(328,13,5,0,0,0,[ str_block(0,328,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,328,13,5,0,-2,0,0,0,0,0, " update_eps_child(\"$(file_name).eps\");")]) ]), mini_line(168,13,5,0,0,0,[ str_block(0,168,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,168,13,5,0,-2,0,0,0,0,0, " launch(\"cleanup\")")]) ]) ])])), attr("cmd=", "", 0, 1, 0, text('blue',64,-152,5,0,1,624,90,27,13,5,0,0,0,0,2,624,90,0,0,"",0,0,0,0,-139,'',[ minilines(624,90,0,0,0,0,0,[ mini_line(32,13,5,0,0,0,[ str_block(0,32,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,32,13,5,0,0,0,0,0,0,0, "cmd=")]) ]), mini_line(96,13,5,0,0,0,[ str_block(0,96,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,96,13,5,0,-2,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(408,13,5,0,0,0,[ str_block(0,408,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,408,13,5,0,-2,0,0,0,0,0, " xterm -geom 40x8+200+400 -e latex $(file_name);")]) ]), mini_line(624,13,5,0,0,0,[ str_block(0,624,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,624,13,5,0,-2,0,0,0,0,0, " xterm -geom 40x8+200+400 -e dvips -N -n 1 -o $(file_name).ps $(file_name);")]) ]), mini_line(576,13,5,0,0,0,[ str_block(0,576,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,576,13,5,0,-1,0,0,0,0,0, " xterm -geom 40x8+200+400 -e ps2epsi $(file_name).ps $(file_name).eps")]) ]) ])])), attr("cleanup=", "", 0, 1, 0, text('blue',64,-72,3,0,1,480,54,165,13,5,0,0,0,0,2,480,54,0,0,"",0,0,0,0,-59,'',[ minilines(480,54,0,0,0,0,0,[ mini_line(64,13,5,0,0,0,[ str_block(0,64,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,64,13,5,0,0,0,0,0,0,0, "cleanup=")]) ]), mini_line(480,13,5,0,0,0,[ str_block(0,480,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,480,13,5,0,0,0,0,0,0,0, " rm -f $(file_name).tex $(file_name).aux $(file_name).dvi")]) ]), mini_line(456,13,5,0,0,0,[ str_block(0,456,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,456,13,5,0,-1,0,0,0,0,0, " $(file_name).log $(file_name).ps $(file_name).eps")]) ]) ])])), attr("file_name=", "", 0, 1, 0, text('blue',64,32,1,0,1,80,18,29,13,5,0,0,0,0,2,80,18,0,0,"",0,0,0,0,45,'',[ minilines(80,18,0,0,0,0,0,[ mini_line(80,13,5,0,0,0,[ str_block(0,80,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,80,13,5,0,0,0,0,0,0,0, "file_name=")]) ]) ])])), attr("eq=", "", 1, 1, 0, text('blue',64,48,5,0,1,120,90,25,13,5,0,0,0,0,2,120,90,0,0,"",0,0,0,0,61,'',[ minilines(120,90,0,0,0,0,0,[ mini_line(24,13,5,0,0,0,[ str_block(0,24,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,13,5,0,0,0,0,0,0,0, "eq=")]) ]), mini_line(48,13,5,0,0,0,[ str_block(0,48,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,48,13,5,0,0,0,0,0,0,0, "\\LARGE")]) ]), mini_line(16,13,5,0,0,0,[ str_block(0,16,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,16,13,5,0,-2,0,0,0,0,0, "\\[")]) ]), mini_line(120,13,5,0,0,0,[ str_block(0,120,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,120,13,5,0,-1,0,0,0,0,0, " E\\,=\\,M\\,C^2")]) ]), mini_line(16,13,5,0,0,0,[ str_block(0,16,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,16,13,5,0,-2,0,0,0,0,0, "\\]")]) ]) ])])), attr("", "not_rigid", 0, 1, 0, text('blue',64,152,1,0,1,72,18,535,13,5,0,0,0,0,2,72,18,0,1,"",0,0,0,0,165,'',[ minilines(72,18,0,1,0,0,0,[ mini_line(72,13,5,0,1,0,[ str_block(0,72,13,5,0,1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,72,13,5,0,1,0,0,0,0,0, "not_rigid")]) ]) ])])) ]). �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tcp.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000015450�11602233313�013724� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Some code in this file is derived from the public domain code in * WWW/Library/Implementation/HTTCP.c distributed with lynx-2.2, * whose original author is Tim Berners-lee <timbl@info.cern.ch>. * * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tcp.c,v 1.6 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_TCP_C_ #include "tgifdefs.h" #include "msg.e" #include "remote.e" #include "strtbl.e" #include "tcp.e" #include "util.e" void SetSocketBlockingState(pn_socket, n_blocking) int *pn_socket, n_blocking; { int rc; #ifdef O_NONBLOCK int flags = fcntl(*pn_socket, F_GETFL); rc = fcntl(*pn_socket, F_SETFL, n_blocking ? (flags & (~O_NONBLOCK)) : (flags | O_NONBLOCK)); #else /* ~O_NONBLOCK */ int val=(!n_blocking); rc = ioctl(*pn_socket, FIONBIO, &val); #endif /* O_NONBLOCK */ if (rc == (-1)) { fprintf(stderr, "%s\n", TgLoadString(n_blocking ? STID_FAIL_TO_MAKE_SOCKET_BLOCK : STID_FAIL_TO_MAKE_SOCKET_NON_BLOCK)); } } void TcpFreeBuf(buf) char *buf; { free(buf); } static int gnPipeBroken=FALSE; static void BrokenPipe(nSig) int nSig; { if (nSig == SIGPIPE) { gnPipeBroken = TRUE; signal(SIGPIPE, SIG_DFL); } } int TcpDoConnect(psz_host, us_port, pn_socket) char *psz_host; int us_port, *pn_socket; { static int not_initialized=TRUE; struct sockaddr_in soc_address; struct sockaddr_in *sin=(&soc_address); struct hostent *p_hostent=NULL; int status=TG_REMOTE_STATUS_OK; if (not_initialized) { not_initialized = FALSE; signal(SIGPIPE, BrokenPipe); } if (*psz_host >= '0' && *psz_host <= '9') { sin->sin_addr.s_addr = inet_addr(psz_host); } else { p_hostent = gethostbyname(psz_host); if (p_hostent == NULL) { return TG_REMOTE_STATUS_HOST; } memcpy(&sin->sin_addr, p_hostent->h_addr, p_hostent->h_length); } sin->sin_family = AF_INET; sin->sin_port = htons((unsigned short)us_port); *pn_socket = socket(AF_INET, SOCK_STREAM, IPPROTO_TCP); SetSocketBlockingState(pn_socket, FALSE); status = connect(*pn_socket, (struct sockaddr*)&soc_address, sizeof(soc_address)); #ifdef EAGAIN if ((status < 0) && (errno==EINPROGRESS || errno==EAGAIN)) { #else /* ~EAGAIN */ if ((status < 0) && (errno == EINPROGRESS)) { #endif /* EAGAIN */ struct timeval timeout; int rc=0; timeout.tv_sec = 0; timeout.tv_usec = 100000; while (rc <= 0) { fd_set writefds; FD_ZERO(&writefds); FD_SET(*pn_socket, &writefds); #ifdef __hpux rc = select(FD_SETSIZE, NULL, (int*)&writefds, NULL, &timeout); #else /* ~__hpux */ rc = select(FD_SETSIZE, NULL, &writefds, NULL, &timeout); #endif /* __hpux */ if ((rc < 0)&&(errno != EALREADY)) { status = rc; break; } else if (rc > 0) { gnPipeBroken = FALSE; status = connect(*pn_socket, (struct sockaddr*)&soc_address, sizeof(soc_address)); if (gnPipeBroken) { fprintf(stderr, TgLoadString(STID_BROKEN_PIPE_CONTACT_HOST), psz_host); fprintf(stderr, "\n"); } if ((status < 0)&&(errno == EISCONN)) status = TG_REMOTE_STATUS_OK; if (errno == EALREADY) { rc = 0; } else { break; } } else { status = connect(*pn_socket, (struct sockaddr*)&soc_address, sizeof(soc_address)); #ifdef EAGAIN if ((status < 0) && (errno != EALREADY) && (errno != EISCONN) && (errno != EAGAIN)) #else /* ~EAGAIN */ if ((status < 0) && (errno != EALREADY) && (errno != EISCONN)) #endif /* EAGAIN */ break; } if (UserAbortComm()) { status = TG_REMOTE_STATUS_INTR; errno = EINTR; break; } } } if (status >= 0) { SetSocketBlockingState(pn_socket, TRUE); } else { close(*pn_socket); } return status; } int TcpDoWrite(n_socket, buf, buf_sz) int n_socket, buf_sz; char *buf; { int status=0; if (buf == NULL) return TG_REMOTE_STATUS_OK; status = write(n_socket, buf, (int)buf_sz); if (status <= 0) { if (status == 0) { fprintf(stderr, "%s\n", TgLoadString(STID_WRITE_TO_SOCKET_FAILED)); } else if ((errno == ENOTCONN || errno == ECONNRESET || errno == EPIPE)) { fprintf(stderr, "%s\n", TgLoadString(STID_UNEXP_NETWORK_ERR_WRITE_SOCK)); return TG_REMOTE_STATUS_WRITE; } } return TG_REMOTE_STATUS_OK; } #define MIN_READ_SIZE 0x100 int TcpDoRead(n_socket, ppsz_buf, pn_buf_sz) int n_socket, *pn_buf_sz; char **ppsz_buf; { int buf_sz=0x400, len=0, end_of_file=FALSE; char *buf=(char*)malloc(buf_sz*sizeof(char)); if (pn_buf_sz != NULL) *pn_buf_sz = 0; *ppsz_buf = NULL; if (buf == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } do { int bytes_read; if (buf_sz - len < MIN_READ_SIZE) { buf_sz += 0x400; if ((buf=(char*)realloc(buf, buf_sz)) == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } } bytes_read = read(n_socket, &buf[len], buf_sz-len-1); if (bytes_read <= 0) { if (bytes_read < 0 && (errno == ENOTCONN || errno == ECONNRESET || errno == EPIPE)) { free(buf); fprintf(stderr, "%s\n", TgLoadString(STID_READ_FROM_SOCKET_FAILED)); return TG_REMOTE_STATUS_READ; } else if (bytes_read < 0) { free(buf); fprintf(stderr, "%s\n", TgLoadString(STID_UNEXP_NETWORK_ERR_READ_SOCK)); return TG_REMOTE_STATUS_NET; } end_of_file = TRUE; } else { len += bytes_read; } } while (!end_of_file); buf[len] = '\0'; *ppsz_buf = buf; if (pn_buf_sz != NULL) *pn_buf_sz = len; return TG_REMOTE_STATUS_OK; } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/�������������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233424�014001� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/wb3.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�014763� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tgtwb5xl.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016050� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/page.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015204� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/choose.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015550� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/wb1.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�014761� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tcp.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015056� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/cli_xcin.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016060� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/attr.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015242� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tgif_dbg.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016035� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tgcwheel.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016072� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/shape.Po�����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015370� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/cutpaste.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016120� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/animate.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015706� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/move.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015236� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/dialog.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015527� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/help.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015220� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tgtwb5.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015504� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/button.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015603� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/inmethod.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016077� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/hash.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015213� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/mainloop.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016106� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/stretch.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015744� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/cmd.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015033� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/util.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015245� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tgtwb5dl.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016024� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/version.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015755� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/color.Po�����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015406� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/stream.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015563� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/pattern.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015745� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tdgtmsg.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015741� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/xpixmap.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015756� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/mark.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015222� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/ftp.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015061� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/chat.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015207� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/navigate.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016066� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tgcwdl.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015554� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/oval.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015231� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/vms_comp.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016113� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/file.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015207� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/setup.Po�����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015430� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/msg.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015056� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/miniline.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016074� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/scroll.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015566� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/nkf.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015046� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/markup.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015567� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/wb2.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�014762� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tidget.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015550� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/exec.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015214� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/grid.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015215� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/ps.Po��������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�014712� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tginssym.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016145� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/eps.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015057� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/spline.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015562� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/obj.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015042� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/menuinfo.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016110� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/align.Po�����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015362� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/polygon.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015757� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/pin.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015056� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/stk.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015071� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/pngtrans.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016124� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tdgtbtn.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015736� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/remote.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015563� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tdgtlist.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016126� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tgisdl.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015556� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/arc.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015035� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/strtbl.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015602� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/shortcut.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016143� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/select.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015547� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/z_intrf.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015743� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/choice.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015522� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/convkinput.Po������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016470� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tdgtdraw.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016110� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/wb.Po��������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�014700� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/font.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015236� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tdgtbrow.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016124� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/cursor.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015605� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/http.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015247� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/ruler.Po�����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015421� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/expr.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015246� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/menu.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015234� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/names.Po�����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015373� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/raster.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015570� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/wb_buff.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015702� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tgif.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015221� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/group.Po�����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015424� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/chinput.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015742� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/dup.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015060� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tdgtbase.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016065� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/import.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015602� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/convxim.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015753� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/mainmenu.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016101� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/drawing.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015723� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/list.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015243� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tangram2.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016003� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/wb_mcast.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016067� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/edit.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015215� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/xbitmap.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015734� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/wb_seg.Po����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015536� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/box.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015060� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/rcbox.Po�����������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015405� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/special.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015710� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/xprtfltr.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016155� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/rect.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015225� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tdgtsedt.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016112� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/imgproc.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015730� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/rm_intrf.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016110� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/text.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015254� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/ini.Po�������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015047� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/auxtext.Po���������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015772� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/poly.Po������������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�015253� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/.deps/tdgtbmpl.Po��������������������������������������������������������������������0000644�0000764�0000764�00000000010�11602233424�016105� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# dummy ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/�������������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�014102� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/64x64/�������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�014675� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/64x64/apps/��������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�015640� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/64x64/apps/tgificon.png��������������������������������������������������������0000644�0000764�0000764�00000011160�11261743301�020151� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������‰PNG  ��� IHDR���@���@���ȘiqȚ���sRGB�źÎé���bKGD�ÿ�ÿ�ÿ œ§“��� pHYs�� �� �šœ���tIMEÙ *j@g��đIDATxÚƚytTUžÇ?śU„’ÊJ…Ù2:`dĄ”šR·#çۊB JË& … ›„qƒdZlÚÖ>Ł8ΈÂc5 HBŰ@dO„R˝?Ț}”%a šsÏy'•Șśî»żïęęŸżíÂU:  őy:è2ìršïWyhWOx'à” ·șFĘ0�t»úęȘ‚ źžđ�z°^ ŁȚ?œo†ž!ìčߌ�è°7lśŁÁ_z^è_çÿЅ!ˆȚ8 Ž�BV !úé /Әß2�șP6ĘX d™ÂK™Ê7îçwž’+BHÓ$}AH ź,'XźŒÍ5…ïŒ ÜȚA‡ŒöÚ_0@Çí†Í›;±BŸô€Ą^ș9DŒËű Œp•Őł@_ŁÜ\Àű›/[”ú»üä“[„”ŻĄC'K›í _I!Ì{u úHĐă~)y9ÂÛAß)üził­‘ß|“-„D"„aĂr%l’°AFĆăąb‰_;èVExBlo`ÿț!t†ÆÛoÏÂćZ €DO8ôW~í»oFx 2wOˆu¶I‡c”Ü·ŻuĎŚwyœ9wîvGkô%őkÛŻGűŽ oˆŸP¶kśź\»¶ëy…7MąȘ*VΚő°„m6I!֙œPúÜșïęEmȚÜ ęFĐW‡„Ś%ìíÛ/“}ÔëŒÂGƒ %rüű± Äüp$èč Çü D^KĐŚFȚ™•ő7ùć—7]°đő]#FL”‰‰ŸIŰ6·.Aș­1ÌA\šđÁHÍّ±}ëÖ=ÓY@iib»Б’RĆÀÏłjU "úçgÀ9çrs‡Ë�@·GÌúś`±ű‘òÒ”TÓ$ŐŐ±ű|V…oń:8'^E�‚ámK`Úùs™ZC żˆćù@C7xeàYW;€ đ7o˜ám(Ä”ö |e BÔÔŃcž ț<sT!„OJ)„ažĄ áël4�ÂŐKïšbû{#m>†víŽĐ§Ïv<ž˜sÎëe˖Žf«”‡Z·ț‘ÖSR’Xż^YŹXq'OBžM'°œ”‚ő"/ĂÈÙéU·˜a§OŸí,Z4ç‚PŸ1c……7eu�hŐêÏ?żŒ€€êŸŻ©±ńțû}đùâDˆłJЗÓ{Ąæ ] đV`łŸ^Í9ßÎG Û�7TłyswÚŽYEyyĂf°bĆˌő±Úżˆ„üбçu“ÚùÍC·ßŚvj>ڈqE`QîÒCII2­Z}Àńăi�őz’ æòÊ+sŠŃ?͌Œ/I‚„—|mș:ƒ€RÈÊ:ÎșuOïč̒‚ńúÏ>{ŠîĘw#eS4Í`üòrœ{ÏeûövêœuAÈÉùóæč‚0”eäÎóUŽsßxËÌêÌJNûö…,]:§ł�‹Ćß( eϞEŒùænče#@S„�”:Ԟ'Ÿφ ë€ „ÀnŻeäÈOxńĆY€ ° UYІ…ČȆ«ÍZĘŰ>XÆz èką*eíÚídƌ„Ü~û·”–&ȘÉËàôé&t붟W_}‹Î·"e’r‹„äçśâÙgG5!Òe bcœLŸŸ‚QŁ> &Š)í&`ČQOĐăA‹ȘۛÌ„À=!¶·âpœdńâÙÜÿÆzóùˊÇŐ\œ{đȚ{3ÈÈű° „†ĆäçßÊÀÏ9!ú9€Ć‹g3hЗáFÊYOàQŁ*í”Ń€šE±œln Ą}őŐn»mÇOł:v<BQџ±Û«MiY‡ę 7ܰüœȚaùòWÈÉùG}œÄІđpYj€ÉöIŠíłBèÆałŐräÈĂ\ęśW-ŚlÖŹ”cÇ&#Ł0“)/ćć‰de­â۱ŒœĂœ9 ™5kĐ,ú§—BŐf=\‚íȘőfĘȚ˜<ž›n*bïȚÇÈÊ:YoŠf,L�†-^è°Û=Áç�ŽÊzA۱c8}úŹGʄ Ś””4ăî»g’ŸßŸA3œ8qŁh Â; ő ï`5•t„NżÎOyy<ü{Š‹SR`‹ŸȘȘ8<›JVjŰČ„#3f QAÎč…ÿìłß5Á$gÚŽa€„•©Ź€Znzz g΀šw˜rÔ°wo\źÇéĘ»�·;RĘArr5ĆĆÉámČu0ôSàtS ŁÀœ]ÔMLêazĄ_ Ȱd(țŒB}ÉPąÚ­úȚS”ênŒ/^č>yŽ,ȎfI#”“ <yÌ»ïæ/ł6”/ôŚWˆˆzDš;ßœ‘àEÚoő9ŸÒő?€G]›ęj@€ÌÌC‹æÌÁždH6ŠŸ?ÿ\ՂžFĄÆăa‰H(W^ÓĄWŻ|ÖŹ™ÀɓMƒvyčĂášdÚŽa,\8Dí|€ÇѶíOžĘ¶Ëž_JAjj{öŽáśż_ą4Ó4ÓDìö“Œ3Œ€€b|>°‚łôw•. m}­(*ș–ÜÜŃ̛7ŻQw 3Ą*ŹRIÛ¶?’‘QÒhó<ЊI“žˆ>•ŽŽBțűÇWHK;…χ”aU±żxôL`: „đÊÒÒŠbțü‡p8*xnú Ź1~änx_ž»űS < 4‰€Öéű4?ûnÿ™ŽÀJŽÒ8NœĘ›êJ;„à€ô‚è`dœn;ÌžXĐőšűŠ„3ä­œŽM›ț�”�FC63s+}ûŸEvö^*+ƒdô‘5#;„áôtà1)Eœ)„&òòÆÓŽy9Ă{ź&~źÇ”ësjŹNKžu,4ͰČSÆ@0_kĂ)bqÜù]ïÜGyE3j:T\UéÛ ÛB\gèĐšJ€g_«śæXÆÖP€eÊlăq8öĐŻßbșvĘFY™0ă‡ÀŃ@ék06*4áuòĂ*ÎȘ4W˔Éʁv ˜7@Û±Œń]GąæÇz҃ôÄjIXÒŹX©e‡iî j€ÿ2ŒvŻqĐ [”6kŽƒÛNeTP…@ )ąvà` ńǀć@6››áĂÇr픇©ź&o?7ž\TDćČfœì|˜•ł1‰\’K  =P„~™ Ž2€¶êÛւ}lK&úČȰz‰śû)Œe[ł ٚ”“CŁŽƒ†ßËŁŸŽäÓ€źC–`‡83ÖÒž€\riE Zњ֮€5­H&‘ćŹV+± i~rrÓČćaȘ«ƒáQ ”Ëeűl­źđÁ8ùUٰÖàćAnŒu ßę� ‰&4Đóűț8í…Ę{ [Oƒ ÖŒ§œlË.ÂóC-+WÀĜ(țè} ï‰Őê&ŃȘńđcs^VöÿßÊ3&@Źd"pì&è°Üù„”ÛFĂ'_'àă|,ÁË[Ä�“HH8FNÎ#$'ăś}y>płËeűĘŒŒz‹ąfĆ�}…*.(7à•'ŽéÇxW‹=/a§–X Ł)ŽÊ4.€•dȆ4üùg)ÿ5ßy˜= ă3Î”|žNÁ9Xb_æÌ§g90F-ĄÌPÿ© aőnxì " ~ Š*<ÇD7ĘEç3™ŒÇ°#™,~æ ŽžŸ™țę_„yóÔÖlŻ`Íuč8“§Žbč\ V…ƒÄXÌę „á—Ö“•"ć3Ä�Ÿ űBBòÈ>ś§rÀ’ˆ{珟ź 7ž~ö`g{śi2b%ńq^|e±űl<4^㑆]Y Ę\üżĐéfôP돘ż—èE= QŠ=[.ćD˃ôsîąC‡]TT ê `šËƞŒ<„ËŠîÎ Fx‡) §!cc;rDÎcž�+g[HúȚùt~lđHŹ0sŠńęŹÚk)žï8Ęî[LqNˆŁoiŻ«0L@™k 0} Üy+È !jŰÁÊćY,æ7R`%‘ïyƒ[o>JPRdû"`„ËĆŃhá/ /^AqŽ2zô<UKšâbEòÂd;ăžpŚv‚/,SnSĂîČ8*}±ŰšZ‘>ɁžŒ<íă§żÀ ÂJ1*”f KhʃÈ~šć«ïí~šnRàńHSűÀï\.Üő �Ô$«ÁöșùM*0uÜŽï̟ÿbÀDú%2 €<q„êéf4ĄśÆl|űđú4Vț' ê üSùS«™·)ę¶úŠè~`0đ in&Œ{ˆ„ű*@â6öá0ír…ëÔEw†ąœƒ“úU'SK5Đ(PÙÜâĆąŒÜÏòć/Ę;iĄZH{ÀÁuÿŠ©ő‰Oö„Tź­lß4)HL e·ĆepśkpČ,)>ƒß[Ž„ d ’’ yüńR’ĘhÒïGHÉF`€)|^žAx—@$9l(U­"„&zàó VźìCRR ÌeȘő 3œÿÊŠtžtÁkț,$°/« ™Ä#ę”ĄèŚ§\Ÿ<^Űö<;EđàęȚj§Ó©UL’ÏrX�9ŒŒmÜ{hqéó!€OÉ.?‡łę%öëM\m 2 DśÙqVú|qbáÂ?ŃąćiЌŸ‰q xÛČՒÂqË5ʖ5Ü[JЊOȚ?…�±ĄhÄÈ]HTÏó.Éî#Śâțž;œ�«ŽČˆ… {Ò<نŸw, S§Âp¶_LučŰՐÍ_6�« Ó0źS» ms)”4#ˆś1uÊTjxjÔG<g;ÄÓŚs`‡Ï(°7±rü/GđŠĆȚź ŸČ]Pî' Ńm/ UN±ŸÓg>MòÚ»X&Ê8(·`ĆBL҃Üsï?éÔi=ććA¶ß<êrńă… ńčvÈĘšÖ§A&œuŹMB‘Ì{ńQ)%òè€ dœ†L°"c4$Ü+á$ÄJ@~ú©q.hÍZł c“đw [%âk s% 5 ™“ƒœ9™—ŒŽçća3íęâ›s…�»”HłÀIèô‚êχłžžÍèŃÏĐŠ-ü\'Î@„žzzˆJ5â),Lçž{Œ§úȚGĆc”~ Ò­jn ë‡L˜KłfàńŚČÈrčšœôîäߊ(,ő†@YhT\Ă+w’„KïaèĐ)4iMTŸ“Ż Ąp–Șù:Ԓțś-ÁïoȘâˆ�BJÊ ÆŒžLJJ-ê™iów˜ÂŸ‹íÎŃMź5'ĐÄhQ#„đHŻ7QŹXŃ‡Łœ9s…7 ČŁááQ怭[ł™8q4;wv�ÊU%§)͛Ă]w-ąu냊7Ù~ȘČùóČę 6{YêŐ()EŹqŒ%FŒńƟiŃą˜‰W‘œ\ĄO©©<ے)SF°aC„8”)“IOÿ–Ÿ}ߊK—o)/æó•«Ûuč„gm<Š4Ăf§Šő8`˜”Âbìv%čč.23ÏšŠE(čÙł§ “&=ÁŠMœ•đ`!!áúśÿw:tŰ^É9Ź‚œŸƒíŻÀQӈÊÒ+ĄŠ€9ÌH jüa+T1ăš7?4Û·včđ]Šœ7†žX­˜<U·œiț°„›Í̈́ ‘šjäóêŠ"àș°ŰŸQÆ�ÀIÔ±”·"+K†wˆöź†z;p83|űXŽbăfÌçû»\FșÙX»…L ŽwêÜÁdŁEĘP2•ÌÌ­ô뷘N¶©šJÎ4—‹‚Œ<#5l,áŻ�á `V›‡©.m €„íćî»Ò­ÛŚálŸ «Ż’ó ”J«Ï‹€IÓíöR† ™Dvö^**‚lT0Ï\±Űțê „ž<!ü<óÌ@ÒÒNá N~RlhL{żÂqÀ…șG�§kđà[NdfZ$„0•ŠIì�z›„ë+Ț)æȘƒ€Ä>gC<–ű|ÁS!S\.46Û74țțąC~ȚN„Z����IENDźB`‚����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/32x32/�������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�014663� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/32x32/apps/��������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�015626� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/32x32/apps/tgificon.png��������������������������������������������������������0000644�0000764�0000764�00000003165�11261743301�020145� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������‰PNG  ��� IHDR��� ��� ���szzô���sRGB�źÎé���bKGD�ÿ�ÿ�ÿ œ§“��� pHYs�� �� �šœ���tIMEÙ+E™}'��őIDATXĂœ—{PTuÇ?»Ü+‹ «VŰĂ©4œj òÙVŠM ÊŽŽÓ49 ѓÇ:źșëkŒČlŠŹ°br$#LÍ;=š™ì1ŐDiŠ&.% PËĂĘ˞țŰ]KQŽÎ̝ٻżß=çüŸßóûžß†dšŽś@ĐÖpfBđÀÀúĂ”.°ú/ԛqIżțàƒ»T`ÏkZ h” ‰Ù\/ŐŐÓ€·Ś .—MBT.–ŽA`ŚȚM,–:©š˜-"ˆâó)R\üˆšênÍÚІ]ê¶…V)nś]}Áû?……ča$Žg.U` h5 ąŁ?ȘȘț5]7ö§CmíEîÍŒ.8“ÉGrră9ùę44$†_őPqź«o( Ô�\KÀZzĄ·-TŐš=:Z::Ì»=§?çČiÓìăęèđŸ‹ćŸ[ @Ftt7șAOÏ0,–.,–Î3##ƒšÛAkëòóóˆ‰é"#ă�ŠŠ6ÓȚMYY–âś+OƒvXw&g Qe˜óM›VÊ9À‹/źçȚ{śŃÖfÁf+aç΀àʔ^VŻ~•‚‚-�A„dńY”PÚV ŐbéÂí^Ț·’ÁÌlîfûögIIùœîîH22VP]=œoÜé|—ë”đ«ăL±2 €čfs댿ÀŒy{1䌫&*êoŸčȘ/‰E‹Šš©™€ȘêŰíïRXèFUu(m1hjž6)�ăÆ5qđàŐ8pűđU�”–.èăŒŻZŽ›ƒœUÎäË/'�0aÂoìŰ1™¶6 ÙÙK±Ûߐäȑ^ZZF€U€ XnVêÿoqqüč苞W‚BÁS€:eÊlAUőATVÎÄퟛ’’·HJúiĐù]]&òóĆă‰EU{˜:Ő­E Xí u˱Zż„Žtc€țšțÜ%ŁuŁeII?‘šÚ�^  ˜�șȚYpZ!ÒżˆÁă‰Ć`0oȚrâă?ŰRBM őó•ȘȘžŒȘŠ{š^%IŽ�‡€Wbà~·‰găÀ>ÎÖ^bîEn”‡…ÏB3œŹƒòVX|Û=è3ëÙÍn�Ná#jLŠLÒÒ֑˜ž7Œćs"‚ T â3xÈ“țL4ț’ì#ÓÜÈKm,oĂô‡ ŸGĘ#^ûŻL<<‘§ńË8æ]ż“è‡ăMđi ÌÜč–ÎƱ”Îș“·Œ—QȚفAOZÚLœű@ăpđŚżIńĐ$ ÙGœLéè@Ž"ešÿ6I˜ąÈŚ?GÈÂúčÆîń‹o—?D€±Í@êëčáà€fčĐžQl¶Éât"N'”çb�Vú-ì_Csĕ™Ś`25ă &$Àő78iŰÏŰéÍ+<BwKpS łgç=ÁÓŒO&“ÓuŸ’ï Þ;șĐêëÊÇ©>UŽ‘­[ç°n]6^#*ÂèGź@Ežł» Ăę:i“àÛęđœŰț�ú—sŒ6ŽD䐐ê'}W€j ïLەłm›$±s-0‡âbhoÆ”j3%·ȚÈ}úțlśbî==ÿśvxÌÉ'ćóńuîc{ÄAČłájŻu8˜sĘđŽć@Î7OŸ–••e)Fِ—^IùÆ^šżŠeG&“ă7ÀxxûçöTàÿă:.7­aNj#ńń'ð?z±Gł”Ąc–ž\6ŃuŁ,Yò°€&””SÄçSdî\§€&FăÉÊș[œNN'5N'–syVÎ/kQ🻊‹q℅ššS} —ž^J]]2Šâcțü„aŰkÎûoFÚ°P?wšȘź„ cÆŽâńÄb2yII)cÒ€=aŰó:ț‹«Ùš`K=ę­Á +kEXáȚlg™K‘�û9«‚ęŸ§ż¶W9d^ˆ'eˆUù`Š‹;đìÔ©n5ŒÈûnÇô;n±(v�ٝêăo«$±.…#¶Œ����IENDźB`‚�����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/128x128/�����������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�015037� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/128x128/apps/������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�016002� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/128x128/apps/tgificon.png������������������������������������������������������0000644�0000764�0000764�00000034162�11261743301�020322� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������‰PNG  ��� IHDR���€���€���Ă>aË���sRGB�źÎé���bKGD�ÿ�ÿ�ÿ œ§“��� pHYs�� �� �šœ���tIMEÙ!Š;(�� �IDATxÚíœyp\Ś•æù»/śÄŸ$ˆ•;Hp)Jâ’¶LÛČe«lËvY¶ȘÜ.Ë%—gșjșg&:šQćˆțŁ»käȘ)WŒ—°C–Çc[¶JkY›I&IqI‘à ’ Aûž�čŒețž7‘/‰…›Òz ‚`æÛîčç~ç;ç;Wpß�!n°Ôïđ_€ÿÈHó„ț+4 €œĂ‚îçC»ŸÍČęìœS|Öžù<œśßÌo°ƒp5À`ùÏ»�xKĐ0f;Ç}í œśč—ß>”źI>śP ì~œúÈÜ[35Cmn?„öăÀ’”„A€üìWžÂœ€@;4ôŠàÛ)>2€Ytˆ‰k~`đ9`“rï3=æ�_—Æx öM} `¶=  os§0˜ÔŸQKÄz ƒÀ)hJŸÎę…îQHŠ„žőÀ'SßÂÂȄ^Ț„Ÿt„°,ËvƒÈ¶}8 1ACÄvęûȚO 0ű2đç@Ćäł^šèWŰ-Ҝïa`>đ đ2:űÎBÀЀB”ȚoȘÒ,ÂČäŹÏÌ 2wn/‡AGGyÈÙŻÇ?nÙŹŁDś"@4èaĂGpś�‹Ż[Ԑű°ȚßČÊ« jjÎó­oœAfæżűĆvMjIBˆ˜<č•äȘżV�żȚOÀĐyÍüTÀç�ÖOȘ0.Zéî- Œ±fMög{ÉÉ„©i‡-%ÎL,KŹÔćÀ ŹTËÊ5œ††áû%DtȚ#ƒŸ.Ô[©ȚöǁyÉ3ßČ€Ûw#©ÿuuçhh8Á§>u˜ČČ>�>ő©C†F °Š#G–�9üI óÇä; 쑞 ÁLńÖGàĂ1 żŒïšŰ=u„PƒŠNœÎ1¶o?ÂßüÍKTVvjÆF/ŸF~ț0—.ÍĄżż@qA“ÍHJ螎ïű̟À헫PosÊà[BH·/gŸ†Š…˜;·•”k/ĐĐp"iđăGaá7žâüù Ț{o˜kŚJˆF3°,€šòI‘ <" 0°h†0śhîÀ1{oíiőҟ·ÿźRÍúż�êIÎà !,!Ç)đSVÖÊ_ęŐ|ë[o°zőE<žXÚ+QWw•ąąAš›Ëèé©T§Ž „)„©Ą�XŠÌ5\ƒç;lś(&ȚśGàC=€€xP‘<ËSB=‰ś-‡úç(nw/ë֝瓟<ÌȘUmÀP „•ôłÏaɒ<ž'OÖÒÚZÌđp6`ĆÏ)RBD°PŒÓh††Á{ÎBnVß�>Ÿ:ó…°!Cčl@céÒ |ęëïđÄûÒÌ|1Ž’†ŒŒ0ùùAæÎíclÌM[ÛuN!tőYû7È�òäČôtžż6ń9`6{ƒÙˆRC=§ŠńŸU.7%Ô)`-ÄÆ§űÎw^„ȘȘ3 <ŽÒț àvÇŰŒù$˗7c§OW3:šaçDš ô°2JĄBā{‰˜%°…QqwЀE*ÎÿxÊàÛž}·r#,XĐÈÚ”çÙŸęhÒàljÔŸìÿóó‡ihű€ÎÎ|Źăüù b±À�ÂéBÄLƶA`?pNCf;0œÍa`25ûĆÔ8?y&ș?yy|ć+;ùêWwRUŐ1éŹOK/ŠùÿOQSÓΫŻnàŸțé \čRDĄ”6D|P‘E�~�œÿÈÜà ÄI—ÊőŚN|ËrȘސ“ÓɆ §ŰČć‹]K™ÙBÜÀúŁ€ĄÓiPYÙƖ-'8vl!##>z{s°,§:ŻA 0tšu pƒ@—…ł7wp—A`:Àśô2d.ÿK í{ìôŽ ő4ÎÜ,\x‘o~óMŸò•ŹZu Ż7: à›é‘üŹŹĘ̛ŚM6íí ûEÂH 3•!TAxŸu6‡ˆÎ»<óÓs<„LîTNœˆăFY·î<_ûÚ»,\Ű:#Ś>íđ§|Ç~ęYjjÚéè(äôéjÂá|"Іàd%R·**žűŒYá wiđӄGzàÏ$ĂÆû‹ÂČ$ăVLgéÒó|țóûűÌg°nĘ93ƍßb(b‰$o‘Æé4ÈÎEŚM::ò)(SÉ2ÿd^ÆcÓ§Mxș ž7“ßÁÓw=Dœ-Q@6đȂ·<­_·W7O/ŸùÌAžyfúPïftç۶í8˗_ᗿìćÚ”bș»‹`2`žQ1†UÈŒÁ”?a˜đ9RKoJ|[1‡|>ß %%WX·î<>z4íàß飞x€mێqáÂ<öìĄœœ‘żb €ûV sŸ€À. ą) śź-âđ4i�_-đ đT*àK~‰^@cÊ&ž}öeŸęíŚYłŠéźÍšÒÒ~VŻnąČțîî\ź\)W·źÛȚîr‘Ôq9ĐÏ·Ï`èŒ;3 àV$ÏăÈȘž”PÏțeQGNÎuuW©­m`h(öȚßyâ-"æäŒ2wn/őő—)*J7—Ru^d”RЁ ĐL†ÛŚî€ŸŒűïW"+o«Š?O °ž~œ˜—^ÚDcc ŃšËf�ëżVfæ~˜ëŚ‹ij*WŃ ą°N.Ț…†ś&1šíÎì·[uÀ üŻêOÙÌoÓÂá0đxtÆÔ?üC% 0 Hąź;žÁ‚ aà'À‡†ž”ÉbĘ ț0IqŻY`čNÍüČt€/ę —Ń“ax…Čm·}·ò-ńÛ4€Cs*ƒL}Ÿ,`pïïVQɇ–Ș0ïń4n_L“Ç_x˜dU»u À̙xŁtÿčYZ¶ ű ńnšò�|©qțvà?+’'đ„ÜҝpíÖMË힟€k§>óUà�żO,ÓœÏÙëÒŸz|6©PhÒuUÎ"§ ©ŽÛxKŠiŃé\ő"Hrî[|U1um=·˜‹,v©…À+éaàŽ-Î;0ÍìjNĂđÙ_J,Oߑ[›)pL|NÇÆöĘÒő'Éž©ä„ÀšÊ“ßçŹö�éĐk�`2±óÉÉŸd;p1.ŒÎŠ—(,Â04…°oîĐ4—Ë ôsút gÎTĄë^5 æ4ßv&íŹ_–yózˆFŒŽzgzz<1tĘÁ… ó8|x)‘HŸ2đđT‚ÔA O*Ɛ; ïŒ 5żÆ”Ćö_I&mÊK<ûì+,[ÖL4êblìæ[śžĘ:aZZJűéOŁ©©]ś( 9žÚÚvțò/ßdóæˆF]ôőecšÓ“O’0 16æá„—6ŃÜ<‡ëŚăUì“•lPËäż!©—gqŽá hŠíÚšÖüʙ†zń5ż°pˆe˚)(Ț¶‡ÌËŠŹŹOe 3uòvŁQ'Á ŸXÌIvö(ÙÙŁ7|ę‡>͖-'Ű”KĐՕ‡ź{&€ÆÉąÈą’R»SE%· H[̱ű6Rą=·ŸÎž(«W7±qc#YYc·Í�"{śźàÀćÄb™ š30�“ŃQMMć47Ï„žx€ÒÒțŸ~NÎ(óç·Q^ȚKgg>U€„;HWT’Ô:V�=đüő©ßû‡êÆ-0]őî:d _í͆œșîž%·Ÿî…Œèú’GˆöśsèP.TPX8HMM;ÙÙĄș~FF˜5kš(+ëçÒ„9œ;WI8œŁ€á€‚Ô ;]…À™;%HuȚÄàOÆíoaJĄf<œÒŠÍ8$»c$ÈxèéRśçôu4ÍÂČ ź Èć7"sČeË ~ű š–Z„bMˆ$ìż++ëć‰'ö‘™9ÆîĘ«8rd)qAȘ`0,@v8sC �H™x·,HœQ€ű4“Ôí'\[œ5łn”čS‡EąÈ3.ÆCÁ(ńdÔțękhlŹĄ»;ššæÌ靗`[·gÊKäæŽpńb9€†eĄ.ŽHĘA±…·”Âyc3‚PsžŠa73Ąnß.Ôtàó ČtéyrrFž~œ˜Ë—Ë0 ÏmбoŽ ’^I§ąąêêąQçÏW00P€f~t|6M'E0èçÀ:^{í6oț€êêŒȚš8bB9ZȘî   ÈÆ\žPÁțęCŽŽ”fÙź9Ašƒ,šy\ RŻȚźÜÁ AàÓ€|HĄæ_2­PÓGyy Ï>û2_űÂąQ'ó‰ĆČl AàȘUÙŽéyy#·mšĂa.ăĐĄ„ÄbjFŁ0jŒíۏđĘïŸL}}3MMóhoŻ!./ò0€ęęœ9SEGG••]̙Ó7êۍ@V3'ßSQŃ Ë–]Ą°pˆË—çÒÛ[©æc˜Ä»› H­CæTZàùÎÛ 7êÒçŻGòûi„š"n€Q<)ÔÜŸę(””m46Öš”źSa‚»ćäăWVv±uë B!‡/„©iCC€™Šc|i"Œe "‘<.]*#òČ|y3Ő՝äçÓșęt Ł€FYŒű.—Áɓóik+"ÌVŸ™Tș@…žšĄĘ<0tNë'ÓŸÇ”ÛŻœ?Ïb,]zšÏ|æ >ztŒ’'u1›ŽhÔI4ê$7w„§žz‡ąąAȚxc=‡­Rl!"šeME1șșòűőŻ·ŃÖVȧ?}ˆM›NNêö';ÊË»ùúŚßŠȘȘ“7ȚxˆĂ‡W"u# N ŻË€ŻÈBà·ÚÌr:HŚ“§I:s$„šÖűìß°Ą1©zwh(cŒ’g¶�ÁŃQ}}9dfޱfÍjkÛˆĆœœ>]ĂÈHBšX Â@ĂpqèĐZe{ąeËźLë RïńÄŰŽé$˖5‰8ilŹ&òÛ~*AȘÆ„4ęÆ_šs†ÜŸ†ŹÛ‹ 5S:sLj.\ŰšÜț‘ BÍd‹ŸûF`šÓLÜSnî[¶œ «+—ƒ—qî\%Ńhźšùa[ˆš^FG Ű»wsçöòÈ#ÔŐ]MR(M"Ú "?˜­[OĐӓËÁƒuœ;WI,–žæ$‚Ô͒) ìÎȚŒ uŠa`ĄâőŸdB͜œNž|r7_ûÚ»i„š|h5|3ç&Țӆ JúÏ=ś%ź\)%žÈ‘ž N擣GsíZ ŸúÔ!țöo_dɒ– A RkkÛyć• <śÜii™‘ ”űwà9àÂ-x€ŽÜŸ@&v6)ą§f"àل`„ŒŒ„P3\ë^i€ćp̛ŚMCĂ;¶ˆPÈKOO.Š™‡ÊAŒbYĂÈŁœœ˜@@Č~99Ł”–öŁi持ĄÓiPQŃ„źč·ȚòĐӓ; uźŽc–<Aƒ9Ó܁s�Q‡Ìêm&}FMaÁ‚FŸò•lÙr‚•+ïÎȘ””í|ç;ݰ|y3żęíVŽy@ò!ĆfƁa0hm-æ§?ę4gÎTń䓻۰Ąń†áüùŚùëż~…úúf~ó›­ŒÿțšńkNÒÌČű+5F/ûg Ó5Ś«ÄNŐD«” 5Ł@ˆ”kÏóŐŻîL’hßë‡ÏaĘșóTWwÒȚ^Hcc5ccÄ <’!D"?ŸŽK—dòšŸțòxî`ŠÀĐïđàƒçšźîäúő RŚššŹkjAjČ7p2yżęÈbŽŠ‰ÜŸP ŸeéÒ3lÜxJuæè˜’żWŽÔÙZT4ȧ?-»ÄîÛWÏûï/Â4sŐÌ·C陃Á<Ț~{-.—ΊM§X»ö<.—~CÀ°žx€Ç;ˆŠÁȚœő;¶ËJ\3 0ÌU܌}ÀQÙÛ8ÜO\RwÚűÓöÛŚ�7nw/=vpF=yî„#Ę}oÙr‚eËź0gN/--%tu“XÉčƒAÀdÿț•œ=[Ć”k%̝ۓ¶OátŚ”‚ÔfÊÊä5{zб•ÌM–;šSś:Đ: l°sûeÈ2źM)ƒ?AšéśQRr…”koLšévÇp8Æ+LxM3q»ooM Ç“€{g‡Û›Ń芊Ù¶íMMćìÙ3L[[!ĂĂăâP9ˆșúw9ìßżŒ·Țz­[3o^wRî`&Gqń Û¶§©iûö'\“‰Ć6ùHAêvì–FĐ! Ֆ xz>Ršù4ÜŸíäRšč|ùEž}öežyæÆ„š.—ÁÁƒËxïœćDŁYÄ3mr“kßöíGđùą·Í�\.–łÿrąŃLÛ ’Ś|èĄłlß~4„»ÈäGié�kÖ4QYÙEww^Ș81Nü›€Îà —ŠŠy\ż^LYYćć=7ü eeęŹYÓDEE]]ù\œ:—R«‰Ü>™ Ő©Bœ8ˆű é7XJjBvö(‹_ŁŠFžwp0sÊÜŸÇĂï—őyYŠx1mÆ+sëÁ Ÿ––òò†‰D\„BȚ[šù~˜«WKÓ\ӚpÍúú"7ĄgÊóæäŒPVÖG]ĘU[éšĂSrčœ;WF__K–ްxń5rsGęÆÌòqčč#̙Ók»Š`‚Ô%Êœƒ@Sbûéőżÿ}‰ț‹ÂËI_șrąšEŒôÒæqĄf0èÇ4”qĘ\z7«30ÉáĂK‰Ć\$Jłâ‘„ĆéÓ5üô§QVևź;l•<7ËËkf©L 3Í5áÔ©Z~ò“Ç(-íŸôšń5>YZDSÓ<Їš€IoooŸù }}Ùű|Âaϔ“Æ~ÍŹŹ1|Ÿ0­­Ć\ŒXNBë0ę "„őEËpț]XŒ/%šŒŰ�Ą‹*2čV߈PS ÓÄbNtʙ’?;.—ŽĂq{Ș…ìŚ”p;źi©hÔ9Cqš@—KÇć2lŐH7J CSïïf©źĂĂÿDŻĘdLBՉ©oÄÍŰX3jڦƉ*űÏșîU„ێÛÀÎôš>tĘ}ŚŒ1qš|g’4‹Fę*zŁÉ°›€Æ7ÊÒłJKÏműŰÇțźù©§ŰÿèŁ\‚1çWš2>N5Ć <ŒÀ^fżùôçœ!äLź©«ÿż‘kÆ?;œLü_|©ˆĘäóÍüš‰q”Oˆsæ4­)*j)»pwź_—‚Ô[Ź Œ•Ú>mš5ó¶Eô3žOë& À~~ń!œł›}~—eYšđzG]NgŹ2cÛĐïÿût;§ÈÖLčÈtșMčg„3Ɛ*Hu0»“Uń dT-SáKć)4èD"~LS`Y”ê:_VĘââ^;Ò/1u‚śæł€FŽš@HÄáĐăÉ+żiČ ŰæțU™țĆúÓđ�vZ°˜7Ż‡:Ceeșî`dÄgÓÌ͎Ăá0ÆĆĄ§NŐrút5șî#!ɒ‚ÔE‹ź±jŐ% †0 Ç- Roÿ K綇ńzŁtućsèĐR.\šżÿdŻe/!ô�AJKOP^~–ššă–Û=†a L3úęWĆú=ŽláR3 Ż˜TUuòoŒÍ¶mLjƜôőć(˜=.Ô펑‘Ą„„„Ÿüä1.\˜§ĐŸ©țÈȘàU«.ńìł/łlÙ"śmW&Ęê,Â"/o„ŒŒ1Ž]L0èç…j5l±”%:NDÉeÍ犟.Àʕo“Ę+À"KΚÊÒÀA`§òsHl°›öˆF] d yÈË!3slÖșÊúúʊ†°Ń§Æ8~)(bÙČ+äæŽ0›PÈĂÀ@á°{’pUŒç1Lfæ5**©Ș:EYY7ŒŽ‚a$&Ș\~œ@öé_ŸJÆî…yüó?Ă‡—òÔSï°ví,nv@ȍő(@d(#ĐÆÉ•HÄ5«ÿbÓ<~ńÂ'Űłg.Ìłń– ĐjÈRA((žÌȘUoQ]}‚ąąb1Đu©=±+ì!cÀ)Ž«e Žx©O’'Đś_ÀŃŁœ?_Aaá””mäçOŒsĘÆŸȚ*>pNqt.L4 3œÁˆßÄU4DžÇ î1ùâą9òŁNÆÆ<Ó_ßL‰PíûPOđĘb.Н`jp3KŁĂïᰛ»Wń ÒÚșH |!ôń‚”„c M„ŒüK—ą ÀpŰ>Ž–©Ö=MAHC/^CnĄčY‚œÔčń gó‡?ŹÇ04>`ă†S8] Ą‡uA v[RŃæș±šqÆƒŐ!ÛKæN S[,/'Ź,†4 b č2čŸŸ‡"ó žoF„h[Ę/Ż„Ÿô~?–1Ué@/ĐVDȚÈF–È:ÓĘł­‡Łk!˜ žh7ÂoF5Ÿ!ö™ì<ž€öŽÂ$žDÎzÔČæF)+;Muőqjk‘›ÛÇjÌÆ]ÿ(đnœJcš ûdY}È-ÔK&† ŃäáĂ+8}șšÎÎ|jȘÛ©ŹČ>Œü8ŁŒŻï&žŠ zɏ!ûgʜú+ç­ ^¶ŠčȘ{ń §tSČæ=JŒ:oŒàńyô^)Âܙ…„;Šÿu  ž b,Mœ•LdKŒ ˎöm„=e9Ꙇš dŒŚE'?·z荘`d±‰2ÓND9q:GY°à>ű2yy}˜Š\óS9dĄÈ¶Ú5Čń‘†!�^AˆT«! O`Șč3ÍààŃ:^}s[8A­· [±Ï‚sń—BŒtnzÆÉöûëÀć( ŒúżAö0Ô-„čĆNšń2biű,“Qáà”–Ću|táƅ…ŚaàsEđeŽâPƛ±%nr·]Ä:9«[ńù#Ób‘ô‡pÁp4 BÌ©€ù•à‰ă3Ă}rđk$ó†W@'YôŃF/WƱč~Ei3N^iÚ99W(/?Guőöáń@(„‹ !Ś| uśŐì?¶cag g?N!{ŐCnĄŸ29>–\ì$z>č‚úń8öۅ<ăx•‡ÆÎÊ.ù&iiÖé ~~œŸcÿ‹śÀúÌę2ô;=ŒFç ?.LœÂąÏ!_L!& àP‰N&š['ÿsű7\€Žà*ù#闟ԉOŸy »țß=pŽ>ùxæ/ÁS( ÜQpXÆÍń ~ “wß*XögÈm uőÇ8ÉΟÊÚ”Żłpá!òò:Đu0M,ØPfvű1pèH‰Æ=mŽ"2:D+*$p€…,K æpćdŁűXA3”Ž“Í A@Ç"ȚĄ'SęŃlœąšXăË„h°x3n0Ð}چ ŚtrŽLŽ‘Í)2p:ÀkhĂÚpb&B„^,„fĄù4™N4ŻAö’vȈĄ3H+!p`„7Ê8àsš?…śÁțV(Ż‚ˆĘ‰8 éòĘQĘO=§Á#„a`ăKę$Í΋>š8M}88ŽA SažŠ `·{”òòłÌŸ„šš+˜&„B`B€Lž6`/đæŽ C"<“ŁűrNjǐ…‡i&ČDé#‡ŚÙJ+…x9H˜ă„Ôꕋ`;đI,ŒÊ̂Àì· {KvUȚŁ.ąć×>k7i8ÎâŚ"‹f2é3œžàƁC@èÜĂo 0z%JŰĐ05 —Ɵ­“łȚGțăùxœ>5�çÈàEÓÉJ-Ä&‚ä36ŃŰ+%Ź4i$1/3ȚpúdwĆ;°1ÀàƁ‰(ĄÏV:qâÄE#‡|jZƧ†Eié)/>@UŐIòóÛ1 9óă“S±Č&đ–šCûâƒÍÎÉWŒ;(Ô„Ûœ&Q=”›đ"i‘7qȏ5ŒG”Čì+Đ|S.ćHaü] #{aț4…ŚJ]4¶-‡ÿíÛ°t‹ƒÉâEœ˜^ʅ“<b81‰Ćtú Óő|/‘ÖDĆ̘’z ÿ 'ž</†nÒdi4 è`˜R-Âz›;4“ߐCż„^Ÿ…°Álˆ$‡–A‚ìČvós~ށh44L„ZŰüX˜¶ąčb5ű&` i#TUdíÚŚ(*êEŚal,qË6Ś xűùŽÒŹV°ü`8Ź:T” «N—aßÖ ""0đšŐą^ÆOe§XșŸ™őVœç1 &Ù�zâƒ_ ë—Aq>è˜:!ÈtÀÇ‚5KăF­1€‹a§ è1†/Œ0tx”¶W‚DZŁž‡–CQœ;>3œ•ô.Áó›<b=™+źă)éBĂÉ>šƒ^;ȘŃÖu‹ ¶\.úŃÖ šĐ. ‡ęp9lk– čFŸZסּă«U€›bŽÒ-ż6Ż6‰ELŽ.Eo.łčöT’!X ” DˆąąÓ”—ŸdțüŁääôâvƒa`ÙTńyuR9ĐCöÁÿțś„‘ìۑÖ�Òâ4ûqžą–‚żĂÖÿŚJȘZR__S_UĂß~ûE>[w™ŒŸu:}nĂJűߟuJ«¶Lp(ˊ#‹(&~ bžpŁĐéùm?]żê#Ü,g~u |û?ÁČć~^x~—ÿő„ÛæÒöC}ĐΜïíĆûévrĐńăf°ËäW/À›ïĂŚÿŸč\v@BŁ��æIDATB=í5ńæ’8Àć�MEa–G‘T-Őđ“oÁ+ÛĄ§H’A¶ścà[űÈáżę·Ïr°ùau␠qÆĘ~|k„üțêëßbùò?’“ӍeÉPO†„Iő˜g€v“XY'Œë4 ,)<€]y‚5 —’ԁ1ŸŻ_Üz‹pëŠ9†eő§”ă7żï9E°v”€ Ăhœ3ęt 7a!ÂQBC1†śĐőÎ0áf‰ÄJ‹aÛvűŰŁPTâ ąȘ‡sèć 3ŽÇCF};î9ƒxçöbŒŽŃ”'Hëź(ŚźĂ#Ś€ÂT¶ÜŻL7Ă0Ű G/C{?Xˆ88ʁÆćĐ6wÂZæĂÇBÒÆ¶ÒĆF3ƒ ”’Ml€‹‡‰á"‹#ô 3†–0"„ÏwȘȘăTW§ŒŒM“ƒŻëB”•Ïm·Șß»c}qÀż“;’’A7}Žšâ4R@úpz`(ăîKWŠùż~ô»ò—ńűÙ�ŸŒìǧȘZłHˆ “€l•ęèÂĂNò8NŚ„SèŒĐÿÚ�œ»F–łgÍRűóÿ�Û…ąÀ0ˆö ŒpŒ%…ÉĄç·ëù  gæŹX€ț«Śàș9Æ[ Nfùœž ŻŒ»NÁńŽF°,$ÛçJ/lÉ'—'ù,Źe,z/#.2#…|ŸqË)ÁƒGă%äą%ȚPČšš‘úú·©Ș:Aqńôxăń‰ĘĆȚ~§BŸȚéč† jPö߅‘íL›‘ŠąúńLÄžïBùÍÝn_]D+Y,à2ÚjÚ»mŽÏĐal’:“VËÍ^3‡C"'ü"Š~1LÏï_’ “ß[>O=…Š9í :èc gn ÉŁ»,ąíDź»ÁjV9äæAq™y nÈ7„ČŻ:àĆCpYžPT >ŻàKëpłÈd#ë€ur{ˆFyêŐyxÈ&Êk€‹ �ĄŒü˗ÿ‘òòb±ńS€xôve�żÜ±CȘ™šőÖM@Z‚. !đŠúę&ő,[ a"Ïêg1Śx€ <ÂŒ j2ôÛeÁ8œ‡ŽIž0ÆĐđ©Ûˆ™„û%ä\]>ŸęT|đ5Îâá€+Ÿ«kû(üÖaœƒ™xœQ4f(3ŠŁ;zȚlJ]AêŽ0«ŠL6lŻWYŠ‘üôĄ1èW‹ćÀ'·ÂÖmáW1™4YÙĄí­æBc?žÉ,ńČŹ\cțüSääô i‰S§pûà Ä?ęxĘșL–;8­È† ì•ŸźŠƒżæ>ËȑőqK–#œc{Ç>1yČρ…ƒ q@·ƒÒü_~Jșț….â涔đž'àÆJÖì„H‰W€”És„]:žsYé|Mëd‹6„Óo‹lä§ž5((ƒ§Ÿ ßüäçÛâMęauÊæmđŒË’E‚«łÈÉ cYŁŁŒg�mĄȚeE–Ÿ¶cDŽ:=ë6,3 Tݚ? »‰TÈUS�„­ZÚE|đz-ÁYÀp[ž‹`ăbxäAÈ̜Üő$‚#yYS±1^TT$ h8žbűčäđá͍Qš;„f‹­Ç‹ŹÇ„[ƒĂ:W “&Ì)‡ìĐÒäK-Kz)Ÿ*+mƒ„XÉ”Â}ôqk 1ˆÀ7ȚÔ§ó“Cƒęì„›sK'7 ŠŠúńzadb1ÛšŃsÈ>ű*ÔK|·ËLE—Ÿ~ ±ÿx ț10î€ïę4‘ń|ûKP[țŒi=WR B†A‘H:‹±l±†01‘t™ ƒđțQș=HGcˆăĂ–Á—ż_țdć/ƒL>íڜűRÎóK~É)N Ç3éő%Š9üDqqZéF‹‚ˆÊpŰćŠŸ€JĐÀρĂ*gvĂÇ-@0ŒçÂÀy !·@Y�"GźßNkX’ówiTÎő°d‰ Ż7ŠüźuCŠhšòE%%S4“y"B”>ÆÈˆ`,l`9Î šWB{SŚ Ÿ1űú ±~ Ô [À·™Ä”¶uęŽ,ˆŠ€ĐŹ ĆŽł‡Ę\ ÉVÙbq‰œÓÆ&’R˜'đ»@Ś-t=QƒaŁçś�ŻîŰ!©Ë8ÁŁfŸu‡ `òcŚ»źRú»ÎnÈŰ bęYa’Ëźò‰py(ƒŚßXĂŐ444ńĐCû’ȚIŃXQ ‚†fŠ”ă“b€ČpˆÿnpdŸ‰^í§ì‰\Čæ{ÇIŚhÄ"6*ĂŃőaĂ6hXȚ«¶z‡ŠÈ ÈđHÄoŽ7…°œëÌpê)öCśÎ5ŠŐs+.Ä„‚§YeÇš­=C–Ž(dù Ź KD,6ŸöG‘”›ï»ăƒłÇí2€$k»ÈŚLà=Ű{<c0ČÌC,KL@ő*Žfpđíù`ïFÚÛߣČò,sætOı“•‰ù44K‘1Ić!©ŽÁćƒ&ű„Ì%C&Ùó”qˆĄGŁąțâxò  uȘ…l„Ä–FJ_ŃöHwoaŻ$l‡ A&eAۀ/šAU'ÎDÓzšŻpđđș«ä捍€iZhšl7 'lȘU懔cÇžiÙBŸË�І›†·ò\Ÿ ]_ÁȘ/Ń« v ĆQZ1ÀÍŰXûś/ăĆ·°q㠖,č†ßŸš 1,A°„áÂÂcŻÆƒÿłč2BVm*d—yƒR”ÖrńĂ?Z–Ëfł–%#ŠK@s+ŚQ«‘_./m—át+ìl„Îé€Ë’°4\ ‡ÁîÍXíeIváĆŁ€ŸŠhŻbdëĆ0š6D~~›*æh#/Ś +t/–źË™ŻK’iXHÌŒ8b|;··<À€!Çsü«ÏÀĄć1F5ę„T‰ŃóÀ9 •› «dń(”üă?>ɉ”|ï{żOê>b Đ-AUünZdŹò3§ÔCč!wNń─ĂčŸÏŁúá"ș3|xç9LȚžÌ0 4j#TăŠ1/{%ûśÿ퇶›†àđ+șpïfxî/àű I'y�7Ć*‰XqrA‘ŃÆȘU/±té^rrș1Í(##đ™Š=äăàÿVć=7ê}ˆАzWžœtˆD‰Ș‘ld!šEˆ LKGŚłhk[ÂΝ&«V]€ŹŹoŒ{ŠVŒÒkžҝ˜Bà(v“SŹáEĐÇ(]V&!4ÉȚZ]NŁU9äTćƉË4e]Ÿ=Ț°lź6üÇŃeER|đ=~XłÊæ©'œRû6@HRT–&ÖeuÓÄB «Ź‘CŒŻ·“ŠŠÔÔĄąâ*BHn?Âă›ÊíïvíŰ!ædÜțĘö�3ąDOR~°\#1Ÿèvućń réÒŸôÄ^6m=ÁBÂ<)Ú©–Ì „pÉö‘ËeӋ‹ ‡iҜ\#Gą&ŐșÁ‰c%BŸ’jÁÓ_†ÂbĘ ÍhcĆ«#Ä»ŰĆ[ŒÍqvÓ!:Àò«2Š JJš©«{ƒȘȘ^Ă0Æ«wSčę7WÓŚ»Ç㟀—xö2` «±,SńźrQĐu'N<Àčs•dfŽQ·ą™‚‚!„ÈŃĂ pÒlú0tƒ!ÇÈä™/šÇ#łX"VwÜűžÀš)ż±ȘȚâ©§ NuSČ"nq |Ł”ŚXöłŸŸó3„•­�n„ąąą‘U«ȚąŹŹ“XlBĘ~ü’Ś•ü,žÏŸŽÛŸu`‚[@–m{LË##_M†B™6ÄBS6Hèç°kś*rrGxtăIÖŹ9KžWçcZ':‚SF&—ńŃïpŁiB%!ì”5Èab§FńÌdoòâ͕č7Ëé@x5Đ )ÎV±8–ŒŰ2œàÔččPS-?öț•Žęû*–îZÍÆPBW›Acrđe„‚E””™Wń:‹''§ ‡C*vRžęadAę^UÆeΔ۟ iȘ‰$37„$ÏGIlÖ€Ùj°‹ŁG–réb9/Ìăÿ,Č`q+‹‰Q€uđ¶Y@ŻUBUEkŽS,ń‚«pT§ïĘAzžï%s­ï‚"2r=hqCÓĂYM€Š%$ЃĐsùĆ [yęǟæËËy@űƗ ?N<hDX ü9o!Kë^gŐȘ·ÈÉéAk2nż ©ŠxkÇ‚· đĘĐäöè{°ŠŠÏ€Ł Ô>ÚÁanMŁ\ĆFăö!„OČábïíâÍwŚâtTÏk§Àă!g?WńĄ ›t\·èí10 p8Askh~hK„àÂW# ù î«@ˆ\ތ^ąíŒœ‚ žm‹ïse™ËXô\†ś› „G.ÒœĘìÏ'ȘŻààȚŽtÔp„v[c,&‚ MÖišiÆ@€æÀ—ĄŠąŸȘȘ–tBM{QćUàÀûàϔ۟m`Ș°„ă Űö&<}jźopvć2ú<„Ÿ§‘ÂŻK·”—Đhi)ćGÿÏă4žŹć[_‹u›©&ÊŚé ŒŚÏóż¶8ò–%ĄDfÁk0ƒË’‰Ó»‹éz~oeŁčȚDœDđ˜:Œ2äȚ+àL?<ÿŽ`Ś{W•ŽúÜé*ž{n;†±’æ3ć@˜łôóyœȚbˆĂœâ2:ÙùíŹ]őæŚ8(,Œ”"ÔLâöś�żTƝ‚wŸ3`kOe©znïW F0Á‚ߌfòë~Z„lP1.HMŽr‰HȚ=šÉčs«ik+ąąȘ‹ùËź’Ÿ?L9a6ëaȚkęG„qy”„˶€˜ 1è#ó \!ÙNß dmR&2sĄqÄâÜ@ü—nÚZ—ÒÖșو3ŒÒ% Ë2Áșąr3Ç€Ô ŠŒeKûšš P3‰ÛßünÇ9?â€ïfIž™w€Æß«ü‡’TÁȘË N‚Űí„Ęsáűÿƒÿ%#}êž&t(—Ą‘p‰FCnzșsÉôZ̝ŚInx-()‚5ËaăĂđÈzŰüÔ-u`‰EtölĆ4V!§W]*‡ĆŐŸÿÂ0.ÆêŐńôź‡ K lÄb‹éîú–őČ3»O=’šEąv\VŻæ•™ŹȘbÉb‹ČR™Č6 ,ÈŸńśČű5đΎŽĆŸ{˖dÚœûò�“€•aàu•»ÈÀ/Ú1^mżűÎ+ä·Pń„ Ú©rń8rx%§«éíÍeÎŒvÊçuóń'`íV™«šÔéùüĐrŐÇżüp-œù±X‰7Ö5ŹĘđ6ßę›êëCnżČ *żôó?ő‡9}êqLłX ü m±‹Żó€ZÎ5,[đ;Ö?xŒ<c*ĄæUćöÇgț­pûłÂ�Dúš ÜTč=4!đđoHőQ-©–€f ùÙżżŽ—țm#ûŰÔŐ]'7wąÈłČJ#//M+S±xŸ2‚\ÀCnnUUÎI_Qgg§êèêZeÍU·4DąUk|śs M “›ÛKyy3ŐU}XxœqĄ&ÂFò +ŽÿGĆíGï4à»[aàź]'‘‚ÔăÈęˆW$%mH€žŻä?ű"'N,ä{ß{…Ő«ÏM8a(dÆ°Ź1ì]5ä�ŽF±ÈΞx3—.•òăŽwȚYGKK Š_ɌбTÂYY­<đÀk,ZtˆÜÜNt=ÆŰX\š™têžpț@ÀśĄ5Zš%Mț ö††šÄ R\źŠ-É!ą€Ærii)ăÍ7=,_ȚLyy'ĆĆIgD@ŚÄz=^‹$gŃèÄw>4”ÁțęËxă”œ?żR}?ˆ1”,i*L5ÜîæÍ;MmíAȘ«/‹6 #‰Û3|{íqțíâöïQH{tš”ń*ȍę$‚TÙƒŠ§'—ßüf+ŚŻòŰcÙ¶íxò”šAWnûqôèb^}őöí«§„%Ÿe\,i —›gdJKOČxń~ȘȘNRPЖ$ÔŽÍ|SQ»qĄfđnżäYb� Hyš=›ŰAàŒZ`ë‘2Ł€1.H”,'ïżż†Ó§«Ń4XŸŒ™ââÁt k"fIÙ70vłkŚj~üăÏÒÛ;W-ÁIŒÉ@ˆaȘȘN±víëi…š6ȚȘ;?K#ÔäÞęłÌÄ?­ 5 ą‚‡UêĐcá!ÎgïȚzÊÊzÙ¶í8«V]$7w„ŹŹ15È=ßß­üâĆrvî\Í»ïźĄ··HŸ˜­En\žîFˆ EE'ÇőùÓ5?PnÿàdBÍ?a0-�: q#© &ÎÆ„ ő۱…ŽŽ”ĐÔ4żÿûç™3§Ÿ/œ&0‘{œQ22Æ…<üâŸà…>A[[Ą-aŠìòć|ű|Ś©ŻÿăL„šg‘Ć»˜Bšù‘${5B –òJșZAî2R©qpfYčôôło_Ę»WRWw•ÖÖb Cłq�ń„tućsôèbČŰłg%­­‹ŐÿÚ6jÔTw !†ńûŻSUu’ȘȘ(/ïœLš%!ÔÜw»‹9îw˜îžȘB§FäêSRuÚÚ ùÙÏ>MAA‹ËՎ!uƒ2ô>th)Á ŸpŰ­š0†™ŰÖ=^ÏgRTôőőïR]ęĆĆWâbÖtB͝ÈÎ#L,㚇˜ęcHçò€ÿ |ȜúńâM&ÒNɃkïXdMòš|hÚ+WŸĆæÍż€Œ\6dŠD&bț'đ/ńΔbŽYqÜ+ U:�?šo&Eš�†qM·ƒéś pï'„źö‚DÆaJKOQUïÌŃ=•Pó�2ł·;„tû¶sü)Àd‚ÔF5Ó*±mt™ ǒN3ę~ń-`ăăć�œžĘŁ,^|€”k_#'§wđ„)æhFÊ”^M#ژu»QÜ`ç&„ˆƒJúïꃕjÊÚfÚL¶æJ7.ò4š6BvöUÊËÏRUu’ą"ê%�_’Pó22ÙuŰ>ű&·żƒÀtüYà9dțݐmkŠû΀PBš Nrrź°víë̟„üüvt]ÆùŠ9Ą˜ă Rą}ˆ›j~d�3óé© 0Œl']‹­…ʍBDŚíQœNÙu{áÂCÔÔ\Á0â ߄&ŒíjÍŚçߌPó#ž”ŁxÙÒy;“æÒ;™Ő‹ 5Ç(+;͂‡šźț€ŒŒL3mÆR€ù.Č3Ç=·‰Òœl�)łȘÁö«.çșòù3ó"©$\ÓF©ź>΃ŸLaaș.ÛŻ2± c+Č!Ó/SÚȌßßl\śï˜C`ČŹìdáž7=&°o°äDˆa .S^~ŽÚÚcäćÉźÛČńònÿ ĄŠ‘ű˜Ínÿ~[ÒœèŁ ˆmț#É;ąÛ�¶¶ë23ݱjŐ[,]ș‡ÜÜîxăeKV 'qû'‘Mś2±›u/œŒûÀ�ÆÙAćą,ŐÛž»UTÌ&ȘțÂűL ˆÏ7LEE#ŐŐ'ššhjÊ~ûIBÍk6’gÊ&ŒÀĘ?ZUhvNmĄțHąăŁË’+CH”–ž ź.@UŐ)ŠŠZŠjŸ…lŒ|ˆ; ÔüÈ�nKˆ8î Pû…@“e‰ ô,™5Ô而ü,+WŸMYYśTBÍ6d%ÏÏï”Pó#ž-GÀŽúmÛߜú|„„ç6̙ӎÆëuE"~ššăVvvݘDš9‚ÌæĘqĄæGpGáâ}`ûŰÇțźčšš„ÌéŒUÆ·șu«mä&áö/"{"ż™ČÙÂ==đÜSvŻzƒ†ńzûmê/\à»±Û,‹RËÂoČAubïc+źažŽłüpÇZSBœ{đę)‚À ÇŁrńúuțehˆśu/™&Ûâ)Ûf}œáû=2ÇĐqżŸûÜ�$0އiB04~ÿût«}ÛRYuôòŽČĂCJšgĘ/oèÿ ,4 CŠ����IENDźB`‚��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/22x22/�������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�014661� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/22x22/apps/��������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�015624� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/22x22/apps/tgificon.png��������������������������������������������������������0000644�0000764�0000764�00000001745�11261743301�020145� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������‰PNG  ��� IHDR���������ÄŽl;���sRGB�źÎé���bKGD�ÿ�ÿ�ÿ œ§“��� pHYs�� �� �šœ���tIMEÙ đmy��eIDAT8Ë­•_L[uÇ?śȚJ‰°2uFEcČ ·YŰ5D}đ*"1d•ÄŰĂÄń€áë’ĆÈè„”eŒ,•`Txa·č']bfù…d Á‡EC¶E‘lÓń0j ±wŽ„ćű@·àì–â<Éïćäü>ż“óęs +S T/(=›zvPŸ(*ș ĐăáM�Ż©é—h4WnM›J‚ €2ț+ŽTą¶ö„DŁč"‚ˆ íí’.KÏV€j�u»Șj@–—ó%‘pÜ=¶í”––#*ÊJËDÉàT Àé-dr°À#›Ž B}066@IÉ�ńxƒ�TWÿHwś�gÎT22RŚ$€Ț •šȘPrńbńĘșÚ¶S@IećGb!éìl–dR—dRŸŻU4M„6jț/AU#šxmí Y^Îż/xvvŻű|­J:;›3 žșêń ÉÒRD"yJBĄR±m§Ű¶SÂa—€’éiS"‘<ii9"ș>%–Ő$¶í”••<in>* ’iAumă„ÿŚê뻏;ÒȘv•—ÿÄ©SŁc±Êʆ™˜èĂퟞ1ftt?ăă5˜æìȚ=Ó„„{ÿ˜ŠIwÛ[ç ß̧<»’äàüÛÏ|ù$Ÿ]‚„H!?u•Ś\7č< …ožÈ}ń‹,r0ŐńÿB]]_LŚS‡6Ś:�JJK:äÈÀ�òÍ|Ÿìęz—tuÊöŠ>yőä.‰ęŒ Dnœl”+\‘KÚe'ĂbšíbYÄƒAïBœ@đć9çúw;tŒ^[; pÿț'œÛ(œ€Kąè6$v@áÚóüÊožæ^ ôéońzÇÖŽ”w-kŁč6=)đt·rv~<ü CCm€ÖÉó1ž3âÀ-ÜÛą,ÏÁ_ ^çBœȚ·ÄKï}żêp$Ț±,&ïÓyfáò<•É‘‘:7ŽuöŒ–ú±Ç‰Í?ÊÚö$łNžtu?ęÓ1śÇë]@ÓäeńU3șÌ�ćŚ4•jmíp8O $33{dp°N`JLłSzzž Ò n}tö€șóù„©é1Œ˜f—XVNâŽPYN·€ ÀŸȚ€i^ÀëíO€…š|ŰMâ%Šé—@ÀX}PŠ[ëőőćœ~żSȅț ’ûč9p”Ùś����IENDźB`‚���������������������������tgif-QPL-4.2.5/icons/48x48/�������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�014701� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/48x48/apps/��������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�015644� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/icons/48x48/apps/tgificon.png��������������������������������������������������������0000644�0000764�0000764�00000005044�11261743301�020161� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������‰PNG  ��� IHDR���0���0���Wù‡���sRGB�źÎé���bKGD�ÿ�ÿ�ÿ œ§“��� pHYs�� �� �šœ���tIMEÙ ÛKŽ©�� €IDAThȚՙ{TTőÇ?3 0Ä#ôȚűHP „\–àY¶źșPnIźkh„=ž>R݆æH‰æ-ÍZTŠä»Ë|ö\™rOTróŃEfą\‹qŽ�AžĂčÌ9Ó<‡{­YkÎ>ûü~{Ÿœ{ś> \N‚ žŰ+1žփź•~ E?(Ÿ Œăpc%șFW tńzśuŁ<ÀZ őïŰ�!Ű%_ED\äź»ŸłxX‚§+ ps‘ò™Àë€@XŰ%ÖŻßJZZ aÁČ`2`†ß sAž‚‚šŐŠ……Ią("Š"bIIŒ˜°E”ïƒ`!çśąü<ŒČrÍGâÁƒcŹÊËżÒÒ(qÔší¶F4ƒ°ö·Vța.Ú(%–”Ä8)/ÿÊʆˆáá»lž ÂșßJù™ ÔŰ*/±bW—âșˆ"bUUˆèïÀֈFÖüŠu@PӁ�<=;8th)‰‰ć(•â Wš«Ó0x𻎶zÈŹv`%Őê:ûŃ�Aü ŰgËÍÏß@ròɛÚÔd $1ńUGöj`#èšûÁ�ë›ßŚÏ±čxőf*vo ÙŻĄ<R(ęz@˜ l“c`Ôš*Ə/»îŐŐÁ|đÁ8'~FF1Wű'NÜÁ±c‘ŽáŽź/gą»Ti—m@Ÿ|rQÙæđáxŃńÄÇ_,67{:ɗ”ĈcÆlv”_}‹!$Ìr@WĆÇoL#+k‘?)©œ—^zžžłçáÆ)Vy}xÀj@+§Êüü }RzΜƒèt§ŹŚ;vLâᇗ;ɍś [·n`Ĉd–°èFĆNy`¶•9‡-œéT)ÓȑÿcÛ¶ŹÈTìÜ9‘ÙłłdÎPXžŠAƒjd–Z:Ôk{i€Œ Žr„…$&–ßRèDD\€šèi†ÿŃRčÚĘÙ”+č[ODF^àűńÇđòj—YÉ9= šlđŒ€FÓBIÉƏï]…œŚSQ1›ĄCV# &1gÎrZZì[­¶–êê4üę›d–7°Êb„}?ĄŽiśÊęV[ÇȚœ9$%•ŁPˆ.Kò*•™Ó§ČzBLfɒ,êê|íd1%<ÜdûČWKm;;ÇÜÒȚW‚»»™#GâmÊ€]ž·œçH_}5ÌúÿìÙÁNČ99̜čÊ.;yxt0mÚQ§”æÏ/dńâ,[Vź„)^]ŁÂ’sÿx”šșae|üM*ț úĘZÀS%ÍmôöÖ}ARRß3ÏÙłƒÙČe*�))„vuàféÜčP6oN”ăĆÇáë[ WY†N\“F�AŒś5cÇ~Û§M‰· Óbɒ=}ZÇd $33ÛĄV|Ȅ űűÔˇXŚ BĐ%>8qâæÎę';wæsÎ’Łź‡ÒŚ�w[ț6ăÆ3æ!ÔĆ(őńjȚ‰u–ÿLÊuśHŚM—;‰5c&­„’Òґvo~„4šZ™ő€ Ԗč č2'<ÜD±śS„Ÿd1ρr€wț »‹àÍÈáÔàÁŃ Zéšő!Kù#ł‚ÏÿòP!\úęvïòçÂŒ­Nk_„?ț*żSbc?aòäWńönEîȚ·©Äș&`đŹä ȘȘŽÄUŒIP—†±Òq?�Üź­;lt‡•ëa˰áD_*/»ń„ö'•QùD5*ÿȚș͟Ý·!Š€”ï::àüy@T€Ù2šZÆ2B܂V $ˆÂ ˜P(Dąą>eêԍČòfàà}œžN(Ą»ș)0Z�êQÓâő.û…@k›ț8˜ÚĄ±Š<šąI„ąÍÔÁ‰đrÆÇvràí.œč›sóÓhšö #Š‹ƒ ^SœŽĘxbł„Ü<ŰŸÙ›ÄŃ/âÍ{\a/Jć6ąąJÈÈX‡G@đ ^Ï>œžÎĐš.xhžÖȘâÉħh*$Ÿ7‡Q)zSvÏitI"E‡•5 Nű‘&Ă N§‡hlÄW*ŽfHZQQöëä’Ëäy?°ÿäCüÀXŒ••DF~ΌÖ¶à2°PŻ·ï {šș• (€ùèPïçŽ/kAĘęB”èIțhw–Ÿ@ËéVR«Œo„Ÿ-rBAđĄćú{Ÿç gìgžîY̘qMŸŒäèőìp‚'='2Ę Ë(e>'$$„èè à›nŸĐ(:‰7ęLń™űé4\.šE04’îAíĘïȇ=èÙ „]L”UyđŹ^O~›zĘȘ§ÙÙvŰ ĂYŒ8‹Ï>‹±ŻŒ ąpƒ :žżęużŽł<‘J 6}$żÓPŰ3Ăf…‰ÀRââF’’âƔ)�ÔÏèőlœ„ét1eÙ&đœÈÄhŒ“ŠŠ0ąą.ùg_‹”wûQŻpçżą§üš‰Œ €úĂWčWÛDŒh‚é/Ăú!Ös,Èă Ÿ <Œü‰„„J&N܆O@đ„^Ï[.ü>�Œà۱HæÏ_ˆûÉČĘȘ𣓶»‚Ùßu;—{r1ïrś*aÊ?–/ €où–cx“đ& VŚÉąłôzȚŸ!DïÚ`j:| Ÿ–šžu�Ă0fÍZIaá*6Žűž»ÿąÄÜ  f:~ș“š}Ci»PفŃđśPÛèÆ€I/pæä|Î[\æ_ÄĆ]%9čÜVùtKÉsĘhQ„[Ü*4�K€‚À A5?țmm”ˆ"=:ŠYłrwČł_gÊ"Ôjšź†˜˜|ź\‘û…6ąŁß%%%//l•OÎóźšÌ‰ÀyK:Ó5KȑêFcC†ìÂÏOCDh”ž€?àC` ”š›0mZ>őőC„PêbäÈ/™>}»Ź|›üæ{«|ŻCš›ÌÔiń€ Č4Üš[[=2dĂŁĘąÊŽŽç0†Iʛ‹T-°@Żïö!.<ÄÎ)ȓ+v}œšääM”—GŰáùÌÌl+ȘT(DGćMÀČȚX|žîo­ä ïIFE}JFÆjÛ ûlOyŸŸ=` ;x‘nAś/û Ó§?o‹mrnEyzÀê‰iôáDńńEÜ{ïV7HÀlÇ­îèæZf—JÙ$Ù± LNȚŽZ}EÆó™}ù~ !Û~‚W€ìÚÀ!ń- Ë\?đĐ5đZjêehèwk}}kŹ žÜșr·~š éăăÙxڌlŹm +wú?L㐠Śq����IENDźB`‚��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/auxtext.c����������������������������������������������������������������������������0000644�0000764�0000764�00000220602�11602233310�014632� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/auxtext.c,v 1.17 2011/05/16 16:21:56 william Exp $ */ #define _INCLUDE_FROM_AUXTEXT_C_ #include "tgifdefs.h" #include "auxtext.e" #include "choice.e" #include "color.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "file.e" #include "font.e" #include "miniline.e" #include "msg.e" #include "obj.e" #include "pattern.e" #include "prtgif.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "setup.e" #include "select.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "xbitmap.e" #include "xpixmap.e" GC rotateGC=NULL; Pixmap textBackingBitmap=None, textBackingBgBitmap=None; Pixmap textBackingPixmap=None; int textBackingBitmapW=INVALID; int textBackingBitmapH=INVALID; int doubleQuoteDoubleQuote=FALSE; int groupedTextEditable=FALSE; struct SelRec *outerSel=NULL, *innerSel=NULL; void GetStrSizeInfo(pDynStr, w, lbearing, rextra) struct DynStrRec *pDynStr; int *w, *lbearing, *rextra; { XCharStruct xcs; MyTextExtents(canvasFontPtr, pDynStr->s, pDynStr->sz-1, &xcs); if (w != NULL) *w = xcs.width; if (lbearing != NULL) *lbearing = (xcs.lbearing >= 0 ? 0 : xcs.lbearing); if (rextra != NULL) *rextra = xcs.rbearing-xcs.width; } int GetNumberOfMiniLines(minilines) MiniLinesInfo *minilines; { int count=0; MiniLineInfo *pMiniLine=minilines->first; for ( ; pMiniLine != NULL; pMiniLine=pMiniLine->next, count++) { } return count; } int IsHex(ch, pn_val) char ch; int *pn_val; { if (ch >= '0' && ch <= '9') { *pn_val = ((int)(ch - '0')); return TRUE; } if (ch >= 'a' && ch <= 'f') { *pn_val = 10+((int)(ch - 'a')); return TRUE; } if (ch >= 'A' && ch <= 'F') { *pn_val = 10+((int)(ch - 'F')); return TRUE; } return FALSE; } int InputOctalString(pszBuf, pnBufSize) char *pszBuf; int *pnBufSize; { int i=0, nBufSizeIn=(*pnBufSize), nError=FALSE; int nPrevIsOctal=FALSE, nByte1OfOctal=TRUE; char *psz=NULL, szSpec[MAXSTRING]; *pnBufSize = 0; *pszBuf = '\0'; *szSpec = '\0'; if (canvasFontDoubleByte) { sprintf(gszMsgBox, TgLoadString(STID_INPUT_OCTAL_STR), "\\244\\244"); } else { sprintf(gszMsgBox, TgLoadString(STID_INPUT_STR)); } Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') return FALSE; if (szSpec[0] == '0' && szSpec[1] == 'x') { for (i=0, psz=(&szSpec[2]); !nError && i < nBufSizeIn-1 && *psz != '\0'; i++, psz=(&psz[2])) { int hi_nibble=0, lo_nibble=0; if (IsHex(psz[0], &hi_nibble) && IsHex(psz[1], &lo_nibble)) { int hval=(((hi_nibble&0x0ff)<<4)+(lo_nibble&0x0ff)); pszBuf[i] = hval; if (canvasFontDoubleByte && canvasFontDoubleByteModBytes) { if ((pszBuf[i] & 0x80) == 0) { pszBuf[i] |= 0x80; } } } else { nError = TRUE; } } } else { for (i=0, psz=szSpec; !nError && i < nBufSizeIn-1 && *psz != '\0'; i++, psz++) { int nThisIsOctal=FALSE; if (*psz == '\\') { if (psz[1] == '\0') { pszBuf[i] = '\\'; } else if (psz[1] == '\\') { pszBuf[i] = '\\'; psz++; } else if (psz[1] == 'r') { pszBuf[i] = '\r'; psz++; } else if (psz[1] == 'n') { pszBuf[i] = '\n'; psz++; } else if (psz[1] >= '0' && psz[1] <= '7') { char *psz1=NULL, saved_ch='\0'; int oval=0; *psz = '0'; for (psz1=(&psz[2]); *psz1 >= '0' && *psz1 <= '7'; psz1++) ; saved_ch = (*psz1); *psz1 = '\0'; if (sscanf(psz, "%o", &oval) != 1) { nError = TRUE; } else { pszBuf[i] = (char)(oval & 0xff); nThisIsOctal = TRUE; if (canvasFontDoubleByte && canvasFontDoubleByteModBytes) { if (nPrevIsOctal) { nByte1OfOctal = !nByte1OfOctal; } else { nByte1OfOctal = TRUE; } if ((pszBuf[i] & 0x80) == 0) { pszBuf[i] |= 0x80; } } } *psz1 = saved_ch; *psz = '\\'; if (!nError) { psz = psz1; psz--; } } else { i--; psz++; } } else { pszBuf[i] = *psz; } nPrevIsOctal = nThisIsOctal; } } if (canvasFontDoubleByte && ((i & 0x1) != 0)) { nError = TRUE; } if (nError) { *pszBuf = '\0'; sprintf(gszMsgBox, TgLoadCachedString(CSTID_MALFORMED_INPUT_STR), szSpec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } pszBuf[i] = '\0'; *pnBufSize = i; return TRUE; } int CharIsCntrlINS(key_ev, key_sym) XKeyEvent *key_ev; KeySym key_sym; { if (key_ev != NULL && ((key_ev->state & ControlMask) != 0) && ((key_ev->state & ShiftMask) == 0) && (key_sym == XK_Insert || key_sym == XK_KP_Insert)) { return TRUE; } return FALSE; } int CharIsShiftINS(key_ev, key_sym) XKeyEvent *key_ev; KeySym key_sym; { if (key_ev != NULL && ((key_ev->state & ControlMask) == 0) && ((key_ev->state & ShiftMask) != 0) && (key_sym == XK_Insert || key_sym == XK_KP_Insert)) { return TRUE; } return FALSE; } int CharIsCntrlShiftINS(key_ev, key_sym) XKeyEvent *key_ev; KeySym key_sym; { if (key_ev != NULL && ((key_ev->state & ControlMask) != 0) && ((key_ev->state & ShiftMask) != 0) && (key_sym == XK_Insert || key_sym == XK_KP_Insert)) { return TRUE; } return FALSE; } /* * int has_ch=XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); * * TranslateKeys(buf, &key_sym); * * if (CharIsESC(key_ev, buf, key_sym, &has_ch)) { * } else if (CharIsCRorLF(key_ev, buf, key_sym, &has_ch)) { * } else if (CharIsBSorDEL(key_ev, buf, key_sym, &has_ch, FALSE)) { * } else if (CharIsTAB(key_ev, buf, key_sym, &has_ch)) { * } */ int CharIsESC(key_ev, psz_buf, key_sym, pn_has_ch) XKeyEvent *key_ev; char *psz_buf; KeySym key_sym; int *pn_has_ch; { if (key_sym == XK_Escape) return TRUE; if (key_ev != NULL && (key_ev->state & ControlMask) && key_sym == XK_bracketleft) { return TRUE; } if (pn_has_ch != NULL) { return ((*pn_has_ch) && *psz_buf == '\033'); } return (*psz_buf == '\033'); } int CharIsCRorLF(key_ev, psz_buf, key_sym, pn_has_ch) XKeyEvent *key_ev; char *psz_buf; KeySym key_sym; int *pn_has_ch; { if (key_sym==XK_Return || key_sym==XK_KP_Enter || key_sym==XK_Linefeed) { return TRUE; } if (key_ev != NULL && (key_ev->state & ControlMask) && (key_sym == XK_m || key_sym == XK_j)) { return TRUE; } if (pn_has_ch != NULL) { return ((*pn_has_ch) && (*psz_buf == '\r' || *psz_buf == '\n')); } return (*psz_buf == '\r' || *psz_buf == '\n'); } int CharIsDEL(key_ev, psz_buf, key_sym, pn_has_ch) XKeyEvent *key_ev; char *psz_buf; KeySym key_sym; int *pn_has_ch; { if (key_sym==XK_Delete || key_sym==XK_KP_Delete) { return TRUE; } if (pn_has_ch != NULL) { return ((*pn_has_ch) && (*psz_buf == '\177')); } return (*psz_buf == '\177'); } int CharIsBS(key_ev, psz_buf, key_sym, pn_has_ch, left_is_BS) XKeyEvent *key_ev; char *psz_buf; KeySym key_sym; int *pn_has_ch, left_is_BS; { if ((left_is_BS && (key_sym==XK_Left || key_sym==XK_KP_Left)) || key_sym==XK_BackSpace) { return TRUE; } if (key_ev != NULL && (key_ev->state & ControlMask) && (key_sym == XK_h)) { return TRUE; } if (pn_has_ch != NULL) { return ((*pn_has_ch) && (*psz_buf == '\b')); } return (*psz_buf == '\b'); } int CharIsBSorDEL(key_ev, psz_buf, key_sym, pn_has_ch, left_is_BS) XKeyEvent *key_ev; char *psz_buf; KeySym key_sym; int *pn_has_ch, left_is_BS; { if ((left_is_BS && (key_sym==XK_Left || key_sym==XK_KP_Left)) || key_sym==XK_BackSpace || key_sym==XK_Delete || key_sym==XK_KP_Delete) { return TRUE; } if (key_ev != NULL && (key_ev->state & ControlMask) && (key_sym == XK_h)) { return TRUE; } if (pn_has_ch != NULL) { return ((*pn_has_ch) && (*psz_buf == '\b' || *psz_buf == '\177')); } return (*psz_buf == '\b' || *psz_buf == '\177'); } int CharIsTAB(key_ev, psz_buf, key_sym, pn_has_ch) XKeyEvent *key_ev; char *psz_buf; KeySym key_sym; int *pn_has_ch; { if (key_sym==XK_Tab || key_sym==XK_KP_Tab) { return TRUE; } if (key_ev != NULL && (key_ev->state & ControlMask) && (key_sym == XK_i)) { return TRUE; } if (pn_has_ch != NULL) { return ((*pn_has_ch) && (*psz_buf == '\t')); } return (*psz_buf == '\t'); } int CharIsHome(key_ev, psz_buf, key_sym, pn_has_ch) XKeyEvent *key_ev; char *psz_buf; KeySym key_sym; int *pn_has_ch; { return (key_sym==XK_Home || key_sym==XK_KP_Home); } int CharIsEnd(key_ev, psz_buf, key_sym, pn_has_ch) XKeyEvent *key_ev; char *psz_buf; KeySym key_sym; int *pn_has_ch; { return (key_sym==XK_End || key_sym==XK_KP_End); } int CharIsCntrlSpace(key_ev, psz_buf, key_sym, pn_has_ch) XKeyEvent *key_ev; char *psz_buf; KeySym key_sym; int *pn_has_ch; { int state=key_ev->state; if (((state & ControlMask) == ControlMask) && ((state & METAMASK) == 0)) { if (key_sym == XK_space || (psz_buf[0] == ' ' && psz_buf[1] == '\0')) { return TRUE; } else if (key_sym == XK_backslash || (psz_buf[0] == '\\' && psz_buf[1] == '\0')) { return TRUE; } } return FALSE; } void TranslateKeys(s, key_sym) char *s; KeySym *key_sym; { switch (*key_sym) { case XK_KP_Space: *key_sym=XK_space; s[0]=' '; s[1]='\0'; break; case XK_KP_Tab: *key_sym=XK_Tab; s[0]='\t'; s[1]='\0'; break; case XK_KP_Enter: *key_sym=XK_Return; s[0]='\r'; s[1]='\0'; break; case XK_KP_Equal: *key_sym=XK_equal; s[0]='='; s[1]='\0'; break; case XK_KP_Multiply: *key_sym=XK_multiply; s[0]='*'; s[1]='\0'; break; case XK_KP_Add: *key_sym=XK_plus; s[0]='+'; s[1]='\0'; break; case XK_KP_Separator: *key_sym=XK_comma; s[0]=','; s[1]='\0'; break; case XK_KP_Subtract: *key_sym=XK_minus; s[0]='-'; s[1]='\0'; break; case XK_KP_Decimal: *key_sym=XK_period; s[0]='.'; s[1]='\0'; break; case XK_KP_Divide: *key_sym=XK_slash; s[0]='/'; s[1]='\0'; break; case XK_KP_0: *key_sym=XK_0; s[0]='0'; s[1]='\0'; break; case XK_KP_1: *key_sym=XK_1; s[0]='1'; s[1]='\0'; break; case XK_KP_2: *key_sym=XK_2; s[0]='2'; s[1]='\0'; break; case XK_KP_3: *key_sym=XK_3; s[0]='3'; s[1]='\0'; break; case XK_KP_4: *key_sym=XK_4; s[0]='4'; s[1]='\0'; break; case XK_KP_5: *key_sym=XK_5; s[0]='5'; s[1]='\0'; break; case XK_KP_6: *key_sym=XK_6; s[0]='6'; s[1]='\0'; break; case XK_KP_7: *key_sym=XK_7; s[0]='7'; s[1]='\0'; break; case XK_KP_8: *key_sym=XK_8; s[0]='8'; s[1]='\0'; break; case XK_KP_9: *key_sym=XK_9; s[0]='9'; s[1]='\0'; break; } } static void GetTransformedTextBBoxAbsVs(ObjPtr, LBearing, RightExtra, Vs) struct ObjRec *ObjPtr; int LBearing, RightExtra; IntPoint *Vs; /* array of 5 points */ { int x, y; struct BBRec bbox; bbox.ltx = ObjPtr->orig_obbox.ltx - ObjPtr->x + LBearing; bbox.lty = ObjPtr->orig_obbox.lty - ObjPtr->y; bbox.rbx = ObjPtr->orig_obbox.rbx - ObjPtr->x + RightExtra; bbox.rby = ObjPtr->orig_obbox.rby - ObjPtr->y; TransformOffsetBBoxThroughCTM(&bbox, ObjPtr->ctm, Vs); x = Vs[0].x + ObjPtr->x; y = Vs[0].y + ObjPtr->y; Vs[0].x = Vs[4].x = x; Vs[0].y = Vs[4].y = y; x = Vs[1].x + ObjPtr->x; y = Vs[1].y + ObjPtr->y; Vs[1].x = x; Vs[1].y = y; x = Vs[2].x + ObjPtr->x; y = Vs[2].y + ObjPtr->y; Vs[2].x = x; Vs[2].y = y; x = Vs[3].x + ObjPtr->x; y = Vs[3].y + ObjPtr->y; Vs[3].x = x; Vs[3].y = y; } void SetTextOBBox(ObjPtr, Just, W, H, LBearing, RightExtra, Rotate) struct ObjRec *ObjPtr; int Just, W, H, LBearing, RightExtra, Rotate; { /* In this procedure, it is assumed that the x and y field */ /* of the text object has the correct information.*/ /* The rotation is clockwise */ register int mw2, pw2; if (ObjPtr->ctm == NULL) { switch (Just) { case JUST_L: switch (Rotate) { case ROTATE0: ObjPtr->obbox.ltx = ObjPtr->x; ObjPtr->obbox.rbx = ObjPtr->x+W; ObjPtr->obbox.lty = ObjPtr->y; ObjPtr->obbox.rby = ObjPtr->y+H; break; case ROTATE90: ObjPtr->obbox.ltx = ObjPtr->x-H; ObjPtr->obbox.rbx = ObjPtr->x; ObjPtr->obbox.lty = ObjPtr->y; ObjPtr->obbox.rby = ObjPtr->y+W; break; case ROTATE180: ObjPtr->obbox.ltx = ObjPtr->x-W; ObjPtr->obbox.rbx = ObjPtr->x; ObjPtr->obbox.lty = ObjPtr->y-H; ObjPtr->obbox.rby = ObjPtr->y; break; case ROTATE270: ObjPtr->obbox.ltx = ObjPtr->x; ObjPtr->obbox.rbx = ObjPtr->x+H; ObjPtr->obbox.lty = ObjPtr->y-W; ObjPtr->obbox.rby = ObjPtr->y; break; } break; case JUST_C: mw2 = W/2; pw2 = W-W/2; switch (Rotate) { case ROTATE0: ObjPtr->obbox.ltx = ObjPtr->x-mw2; ObjPtr->obbox.rbx = ObjPtr->x+pw2; ObjPtr->obbox.lty = ObjPtr->y; ObjPtr->obbox.rby = ObjPtr->y+H; break; case ROTATE90: ObjPtr->obbox.ltx = ObjPtr->x-H; ObjPtr->obbox.rbx = ObjPtr->x; ObjPtr->obbox.lty = ObjPtr->y-mw2; ObjPtr->obbox.rby = ObjPtr->y+pw2; break; case ROTATE180: ObjPtr->obbox.ltx = ObjPtr->x-pw2; ObjPtr->obbox.rbx = ObjPtr->x+mw2; ObjPtr->obbox.lty = ObjPtr->y-H; ObjPtr->obbox.rby = ObjPtr->y; break; case ROTATE270: ObjPtr->obbox.ltx = ObjPtr->x; ObjPtr->obbox.rbx = ObjPtr->x+H; ObjPtr->obbox.lty = ObjPtr->y-pw2; ObjPtr->obbox.rby = ObjPtr->y+mw2; break; } break; case JUST_R: switch (Rotate) { case ROTATE0: ObjPtr->obbox.ltx = ObjPtr->x-W; ObjPtr->obbox.rbx = ObjPtr->x; ObjPtr->obbox.lty = ObjPtr->y; ObjPtr->obbox.rby = ObjPtr->y+H; break; case ROTATE90: ObjPtr->obbox.ltx = ObjPtr->x-H; ObjPtr->obbox.rbx = ObjPtr->x; ObjPtr->obbox.lty = ObjPtr->y-W; ObjPtr->obbox.rby = ObjPtr->y; break; case ROTATE180: ObjPtr->obbox.ltx = ObjPtr->x; ObjPtr->obbox.rbx = ObjPtr->x+W; ObjPtr->obbox.lty = ObjPtr->y-H; ObjPtr->obbox.rby = ObjPtr->y; break; case ROTATE270: ObjPtr->obbox.ltx = ObjPtr->x; ObjPtr->obbox.rbx = ObjPtr->x+H; ObjPtr->obbox.lty = ObjPtr->y; ObjPtr->obbox.rby = ObjPtr->y+W; break; } break; } } else { IntPoint abs_obj_obbox_vs[5]; GetTransformedOBBoxAbsVs(ObjPtr, abs_obj_obbox_vs); ObjPtr->obbox.ltx = min(min(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), min(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); ObjPtr->obbox.rbx = max(max(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), max(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); ObjPtr->obbox.lty = min(min(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), min(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); ObjPtr->obbox.rby = max(max(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), max(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); } } void SetTextBBox(ObjPtr, Just, W, H, LBearing, RightExtra, Rotate) struct ObjRec *ObjPtr; int Just, W, H, LBearing, RightExtra, Rotate; /* In this procedure, it is assumed that the x and y field */ /* of the text object has the correct information.*/ /* The rotation is clockwise */ { SetTextOBBox(ObjPtr, Just, W, H, LBearing, RightExtra, Rotate); if (ObjPtr->ctm == NULL) { switch (Rotate) { case ROTATE0: ObjPtr->bbox.ltx = ObjPtr->obbox.ltx + LBearing; ObjPtr->bbox.rbx = ObjPtr->obbox.rbx + RightExtra; ObjPtr->bbox.lty = ObjPtr->obbox.lty; ObjPtr->bbox.rby = ObjPtr->obbox.rby; break; case ROTATE90: ObjPtr->bbox.ltx = ObjPtr->obbox.ltx; ObjPtr->bbox.rbx = ObjPtr->obbox.rbx; ObjPtr->bbox.lty = ObjPtr->obbox.lty + LBearing; ObjPtr->bbox.rby = ObjPtr->obbox.rby + RightExtra; break; case ROTATE180: ObjPtr->bbox.ltx = ObjPtr->obbox.ltx - RightExtra; ObjPtr->bbox.rbx = ObjPtr->obbox.rbx - LBearing; ObjPtr->bbox.lty = ObjPtr->obbox.lty; ObjPtr->bbox.rby = ObjPtr->obbox.rby; break; case ROTATE270: ObjPtr->bbox.ltx = ObjPtr->obbox.ltx; ObjPtr->bbox.rbx = ObjPtr->obbox.rbx; ObjPtr->bbox.lty = ObjPtr->obbox.lty - RightExtra; ObjPtr->bbox.rby = ObjPtr->obbox.rby - LBearing; break; } } else { IntPoint abs_obj_bbox_vs[5]; GetTransformedTextBBoxAbsVs(ObjPtr, LBearing, RightExtra, abs_obj_bbox_vs); ObjPtr->bbox.ltx = min(min(abs_obj_bbox_vs[0].x,abs_obj_bbox_vs[1].x), min(abs_obj_bbox_vs[2].x,abs_obj_bbox_vs[3].x)); ObjPtr->bbox.rbx = max(max(abs_obj_bbox_vs[0].x,abs_obj_bbox_vs[1].x), max(abs_obj_bbox_vs[2].x,abs_obj_bbox_vs[3].x)); ObjPtr->bbox.lty = min(min(abs_obj_bbox_vs[0].y,abs_obj_bbox_vs[1].y), min(abs_obj_bbox_vs[2].y,abs_obj_bbox_vs[3].y)); ObjPtr->bbox.rby = max(max(abs_obj_bbox_vs[0].y,abs_obj_bbox_vs[1].y), max(abs_obj_bbox_vs[2].y,abs_obj_bbox_vs[3].y)); } ObjPtr->bbox.ltx--; ObjPtr->bbox.rbx++; ObjPtr->bbox.lty--; ObjPtr->bbox.rby++; } void SetTextOrigBBoxes(ObjPtr, Just, W, H, LBearing, RightExtra, Rotate) struct ObjRec *ObjPtr; int Just, W, H, LBearing, RightExtra, Rotate; /* In this procedure, it is assumed that the x and y field */ /* of the text object has the correct information.*/ /* The rotation is clockwise */ { struct BBRec obbox, bbox; struct XfrmMtrxRec *ctm; if (ObjPtr->ctm == NULL) return; memcpy(&obbox, &ObjPtr->obbox, sizeof(struct BBRec)); memcpy(&bbox, &ObjPtr->bbox, sizeof(struct BBRec)); ctm = ObjPtr->ctm; ObjPtr->ctm = NULL; SetTextBBox(ObjPtr, Just, W, H, LBearing, RightExtra, Rotate); memcpy(&ObjPtr->orig_obbox, &ObjPtr->obbox, sizeof(struct BBRec)); memcpy(&ObjPtr->detail.t->orig_bbox, &ObjPtr->bbox, sizeof(struct BBRec)); ObjPtr->ctm = ctm; } int UpdTextBBox(ObjPtr) struct ObjRec *ObjPtr; /* * This function should be called every time any part of a text object is * changed. * Therefore, it should never be called if PRTGIF. * Returns FALSE if the text object is changed. */ { struct TextRec *text_ptr=ObjPtr->detail.t; int read_only=FALSE; #ifdef _TGIF_DBG /* debug, do not translate */ int saved_baseline_y=text_ptr->baseline_y; #endif /* _TGIF_DBG */ if (mainDisplay == NULL) return FALSE; #ifdef _TGIF_DBG /* debug, do not translate */ if (PRTGIF && !cmdLineOpenDisplay) { fprintf(stderr, "UpdTextBBox() called in PRTGIF!\n"); } #endif /* _TGIF_DBG */ if (text_ptr->read_only) { return TRUE; } PushCurFont(); ObjFontInfoToCurFontInfo(text_ptr); allowFontFaceSubstitution = FALSE; read_only = (!RecalcTextMetrics(text_ptr, ObjPtr->x, text_ptr->baseline_y)); allowFontFaceSubstitution = TRUE; #ifdef _TGIF_DBG /* debug, do not translate */ if (text_ptr->baseline_y != saved_baseline_y) { TgAssert(FALSE, "Text_ptr->baseline_y changed in UpdTextBBox()", "Restored"); text_ptr->baseline_y = saved_baseline_y; } #endif /* _TGIF_DBG */ if (read_only) { PopCurFont(); return FALSE; } ObjPtr->y = text_ptr->baseline_y - text_ptr->minilines.first->asc; SetTextOrigBBoxes(ObjPtr, textJust, text_ptr->w, text_ptr->h, text_ptr->min_lbearing, text_ptr->max_rextra, ROTATE0); SetTextBBox(ObjPtr, textJust, text_ptr->w, text_ptr->h, text_ptr->min_lbearing, text_ptr->max_rextra, ROTATE0); PopCurFont(); return (!read_only); } int PixelOnOff(image, col_start, row_start, scale) XImage *image; int col_start, row_start, scale; { register int m, n; int on_count=0, off_count=0; if (scale == 2) { for (m = 0; m < 2; m++) { for (n = 0; n < 2; n++) { switch (XGetPixel(image,col_start+n,row_start+m)) { case 0: if (++off_count > 2) return 0; break; case 1: if (++on_count >= 2) return 1; break; } } } } else if (scale > 2) { int half_scale=scale>>1; for (m = 0; m < 2; m++) { for (n = 0; n < 2; n++) { switch (PixelOnOff(image, col_start+n*half_scale, row_start+m*half_scale, half_scale)) { case 0: if (++off_count > 2) return 0; break; case 1: if (++on_count >= 2) return 1; break; } } } } else { return 1; } return 0; } static int PaintBackingPixmap(text_ptr, bbox_w, bbox_h, min_lbearing, max_rextra, baseline_y) struct TextRec *text_ptr; int bbox_w, bbox_h, min_lbearing, max_rextra, baseline_y; /* * bbox_w includes left bearing and right extra. */ { MiniLinesInfo *minilines=(&text_ptr->minilines); int x=0, w=minilines->w, saved_pen=penPat, saved_trans_pat=transPat; if (bbox_w > textBackingBitmapW || bbox_h > textBackingBitmapH) { int tmp_w, tmp_h; if (textBackingBitmap != None) { XFreePixmap(mainDisplay, textBackingBitmap); } if (textBackingBgBitmap != None) { XFreePixmap(mainDisplay, textBackingBgBitmap); } if (textBackingPixmap != None) { XFreePixmap(mainDisplay, textBackingPixmap); } tmp_w = max(bbox_w,textBackingBitmapW); tmp_h = max(bbox_h,textBackingBitmapH); textBackingBitmap = XCreatePixmap(mainDisplay, mainWindow, tmp_w, tmp_h, 1); textBackingBgBitmap = XCreatePixmap(mainDisplay, mainWindow, tmp_w, tmp_h, 1); textBackingPixmap = XCreatePixmap(mainDisplay, mainWindow, tmp_w, tmp_h, mainDepth); if (textBackingBitmap == None || textBackingBgBitmap == None || textBackingPixmap == None) { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FailAllocPixmapMessage(tmp_w, tmp_h); } textBackingBitmapW = tmp_w; textBackingBitmapH = tmp_h; } switch (textJust) { case JUST_L: x = (-min_lbearing); break; case JUST_C: x = ((bbox_w+min_lbearing-max_rextra-w)>>1)-min_lbearing+(w>>1); break; case JUST_R: x = bbox_w-max_rextra; break; } XFillRectangle(mainDisplay, textBackingPixmap, xpmGC, 0, 0, bbox_w, bbox_h); XSetForeground(mainDisplay, rotateGC, 0); XFillRectangle(mainDisplay, textBackingBitmap, rotateGC, 0, 0, bbox_w, bbox_h); XFillRectangle(mainDisplay, textBackingBgBitmap, rotateGC, 0, 0, bbox_w, bbox_h); XSetForeground(mainDisplay, rotateGC, 1); ResetDirtyBBoxInfo(); transPat = FALSE; penPat = SOLIDPAT; PaintMiniLines(mainDisplay, textBackingBgBitmap, rotateGC, 1, x, baseline_y, minilines, FALSE, TRUE); penPat = text_ptr->pen; PaintMiniLines(mainDisplay, textBackingBitmap, rotateGC, 1, x, baseline_y, minilines, FALSE, TRUE); PaintMiniLines(mainDisplay, textBackingPixmap, xpmGC, mainDepth, x, baseline_y, minilines, FALSE, FALSE); penPat = saved_pen; transPat = saved_trans_pat; return TRUE; } #ifdef NOT_DEFINED #ifdef _TGIF_DBG /* debug, do not translate */ static void DebugCachedTextBitmapImage(image, before, w, h, min_lbearing, max_rextra) XImage *image; int before, w, h, min_lbearing, max_rextra; { int i=0; if (before) fprintf(stderr, "\n"); fprintf(stderr, " w = %1d\n", w); fprintf(stderr, " h = %1d\n", h); if (before) { fprintf(stderr, "min_lbearing = %1d\n", min_lbearing); fprintf(stderr, " max_rextra = %1d\n", max_rextra); } for (i=0; i < h; i++) { int j=0; for (j=0; j < w; j++) { int data=XGetPixel(image,j,i); fprintf(stderr, "%c%s", (data==1 ? 'X' : ' '), (j+1 == w ? "\n" : "")); } } } #endif /* _TGIF_DBG */ #endif /* NOT_DEFINED */ void MakeCachedTextBitmap(ObjPtr) struct ObjRec *ObjPtr; { int r=0, c=0, bbox_w=0, bbox_h=0, num_cols=0, num_rows=0; int watch_cursor=FALSE, do_msg=FALSE, min_lbearing=0, max_rextra=0; int flat=FALSE, skinny=FALSE, start_row=0, start_col=0, ok=FALSE; struct MtrxRec mtrx; Pixmap dest_bitmap=None, dest_bg_bitmap=None, dest_pixmap=None; XImage *src_image=NULL, *src_bitmap_image=NULL, *src_bitmap_bg_image=NULL; XImage *dest_image=NULL, *dest_bitmap_image=NULL, *dest_bitmap_bg_image=NULL; struct TextRec *text_ptr=ObjPtr->detail.t; if (ObjPtr->ctm == NULL && text_ptr->cached_bitmap != None && text_ptr->cached_zoomed == zoomedIn && text_ptr->cached_zoom == zoomScale) { return; } if (ObjPtr->obbox.ltx==ObjPtr->obbox.rbx || ObjPtr->obbox.lty==ObjPtr->obbox.rby) { return; } InvalidateTextCache(text_ptr); if (PRTGIF) { RecalcTextMetrics(text_ptr, ObjPtr->x, text_ptr->baseline_y); } if (curChoice == DRAWTEXT && textCursorShown && ObjPtr == curTextObj) { if (RestoreEditTextSize(ObjPtr, TRUE)) { UpdTextBBox(ObjPtr); } } if (text_ptr->read_only) { min_lbearing = text_ptr->min_lbearing; max_rextra = text_ptr->max_rextra; bbox_w = text_ptr->orig_w; bbox_h = text_ptr->orig_h; } else { min_lbearing = text_ptr->min_lbearing; max_rextra = text_ptr->max_rextra; bbox_w = text_ptr->w - min_lbearing + max_rextra; bbox_h = text_ptr->h; } ok = PaintBackingPixmap(text_ptr, bbox_w, bbox_h, min_lbearing, max_rextra, text_ptr->minilines.first->asc); if (curChoice == DRAWTEXT && textCursorShown && ObjPtr == curTextObj) { if (RestoreEditTextSize(ObjPtr, FALSE)) { UpdTextBBox(ObjPtr); } } if (!ok) { return; } watch_cursor = watchCursorOnMainWindow; if (!watch_cursor && !RedrawDuringScrolling()) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } else { CheckInterrupt(TRUE); } src_image = XGetImage(mainDisplay, textBackingPixmap, 0, 0, bbox_w, bbox_h, AllPlanes, ZPixmap); src_bitmap_image = XGetImage(mainDisplay, textBackingBitmap, 0, 0, bbox_w, bbox_h, 1, ZPixmap); src_bitmap_bg_image = XGetImage(mainDisplay, textBackingBgBitmap, 0, 0, bbox_w, bbox_h, 1, ZPixmap); if (ObjPtr->ctm == NULL) { if (text_ptr->read_only) { num_cols = ObjPtr->bbox.rbx - ObjPtr->bbox.ltx - 2; num_rows = ObjPtr->bbox.rby - ObjPtr->bbox.lty - 2; } else { num_cols = bbox_w; num_rows = bbox_h; } if (zoomedIn || zoomScale == 0) { num_cols <<= zoomScale; num_rows <<= zoomScale; } else { num_cols >>= zoomScale; num_rows >>= zoomScale; } } else { num_cols = ZOOMED_SIZE(ObjPtr->bbox.rbx - ObjPtr->bbox.ltx - 2); num_rows = ZOOMED_SIZE(ObjPtr->bbox.rby - ObjPtr->bbox.lty - 2); } if (num_cols == 0) { skinny = TRUE; num_cols = 1; } if (num_rows == 0) { flat = TRUE; num_rows = 1; } do_msg = (((num_rows*num_cols)>=0x4000) && !RedrawDuringScrolling()); if (do_msg) { SaveStatusStrings(); SetStringStatus(TgLoadCachedString(CSTID_CACHING_TEXT_BMP)); XSync(mainDisplay, False); } dest_bitmap = XCreatePixmap(mainDisplay,mainWindow,num_cols,num_rows,1); dest_bg_bitmap = XCreatePixmap(mainDisplay,mainWindow,num_cols,num_rows,1); XSetForeground(mainDisplay, rotateGC, 0); XFillRectangle(mainDisplay,dest_bitmap,rotateGC,0,0,num_cols,num_rows); XFillRectangle(mainDisplay,dest_bg_bitmap,rotateGC,0,0,num_cols,num_rows); dest_pixmap = XCreatePixmap(mainDisplay, mainWindow, num_cols, num_rows, mainDepth); XFillRectangle(mainDisplay, dest_pixmap, xpmGC, 0, 0, num_cols, num_rows); dest_image = XGetImage(mainDisplay, dest_pixmap, 0, 0, num_cols, num_rows, AllPlanes, ZPixmap); dest_bitmap_image = XGetImage(mainDisplay, dest_bitmap, 0, 0, num_cols, num_rows, 1, ZPixmap); dest_bitmap_bg_image = XGetImage(mainDisplay, dest_bg_bitmap, 0, 0, num_cols, num_rows, 1, ZPixmap); if (!flat && !skinny) { #ifdef NOT_DEFINED #ifdef _TGIF_DBG DebugCachedTextBitmapImage(src_bitmap_image, TRUE, bbox_w, bbox_h, min_lbearing, max_rextra); #endif /* _TGIF_DBG */ #endif /* NOT_DEFINED */ if (ObjPtr->ctm == NULL) { mtrx.image_w = (float)bbox_w; mtrx.image_h = (float)bbox_h; mtrx.w = (float)num_cols; mtrx.h = (float)num_rows; mtrx.rotate = ROTATE0; mtrx.flip = NO_FLIP; CalcTransform(&mtrx); start_col = (mtrx.transformed_w >= 0.0) ? 0 : (-num_cols)+1; start_row = (mtrx.transformed_h >= 0.0) ? 0 : (-num_rows)+1; for (r=0; r < num_rows; r++) { double part_x, part_y; if (do_msg && ((r & 0xf) == 0)) { int percent=(r*10000/num_rows)/100; sprintf(gszMsgBox, TgLoadCachedString(CSTID_PROGRESS_PERCENT), percent); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); } part_x = ((double)(r+start_row)+0.5)*(mtrx.rev_m[1][0]); part_y = ((double)(r+start_row)+0.5)*(mtrx.rev_m[1][1]); for (c=0; c < num_cols; c++) { double x, y; x = part_x+((double)(c+start_col)+0.5)*(mtrx.rev_m[0][0]); y = part_y+((double)(c+start_col)+0.5)*(mtrx.rev_m[0][1]); if (x >= ((double)0) && x < ((double)bbox_w) && y >= ((double)0) && y < ((double)bbox_h)) { int new_x=(int)x, new_y=(int)y; if (new_x < 0) new_x = 0; if (new_x >= bbox_w) new_x = bbox_w-1; if (new_y < 0) new_y = 0; if (new_y >= bbox_h) new_y = bbox_h-1; if (XGetPixel(src_bitmap_image, new_x, new_y) == 1) { int dest_pixel=XGetPixel(src_image, new_x, new_y); XPutPixel(dest_bitmap_image, c, r, 1); XPutPixel(dest_image, c, r, dest_pixel); } if (XGetPixel(src_bitmap_bg_image, new_x, new_y) == 1) { XPutPixel(dest_bitmap_bg_image, c, r, 1); } } } } } else { int abs_offset_x=ObjPtr->bbox.ltx+1-ObjPtr->x; int abs_offset_y=ObjPtr->bbox.lty+1-ObjPtr->y; int abs_adj_x=ObjPtr->x-ObjPtr->orig_obbox.ltx; int abs_adj_y=ObjPtr->y-ObjPtr->orig_obbox.lty; for (r=0; r < num_rows; r++) { int y=abs_offset_y+ABS_SIZE(r); double dy=((double)y)+0.5; if (do_msg && ((r & 0xf) == 0)) { int percent=(r*10000/num_rows)/100; sprintf(gszMsgBox, TgLoadCachedString(CSTID_PROGRESS_PERCENT), percent); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); } for (c=0; c < num_cols; c++) { int x=abs_offset_x+ABS_SIZE(c); double dx=((double)x)+0.5; double new_dx=((double)0), new_dy=((double)0); ReverseTransformDoublePointThroughCTM(dx, dy, ObjPtr->ctm, &new_dx, &new_dy); new_dx += (double)abs_adj_x; new_dy += (double)abs_adj_y; if (new_dx >= ((double)0) && new_dx < ((double)bbox_w) && new_dy >= ((double)0) && new_dy < ((double)bbox_h)) { int new_x=(int)new_dx, new_y=(int)new_dy; if (new_x < 0) new_x = 0; if (new_x >= bbox_w) new_x = bbox_w-1; if (new_y < 0) new_y = 0; if (new_y >= bbox_h) new_y = bbox_h-1; if (XGetPixel(src_bitmap_image, new_x, new_y) == 1) { int dest_pixel=XGetPixel(src_image, new_x, new_y); XPutPixel(dest_bitmap_image, c, r, 1); XPutPixel(dest_image, c, r, dest_pixel); } if (XGetPixel(src_bitmap_bg_image, new_x, new_y) == 1) { XPutPixel(dest_bitmap_bg_image, c, r, 1); } } } } memcpy(&text_ptr->cached_ctm,ObjPtr->ctm,sizeof(struct XfrmMtrxRec)); } #ifdef NOT_DEFINED #ifdef _TGIF_DBG DebugCachedTextBitmapImage(dest_bitmap_image, FALSE, num_cols, num_rows, 0, 0); #endif /* _TGIF_DBG */ #endif /* NOT_DEFINED */ } if (do_msg) { SetStringStatus(TgLoadCachedString(CSTID_FINISHED_CACHEING_TEXT_BMP)); XSync(mainDisplay, False); } XPutImage(mainDisplay, dest_bitmap, rotateGC, dest_bitmap_image, 0, 0, 0, 0, num_cols, num_rows); XPutImage(mainDisplay, dest_bg_bitmap, rotateGC, dest_bitmap_bg_image, 0, 0, 0, 0, num_cols, num_rows); XPutImage(mainDisplay, dest_pixmap, xpmGC, dest_image, 0, 0, 0, 0, num_cols, num_rows); if (do_msg) RestoreStatusStrings(); text_ptr->cached_bitmap = dest_bitmap; text_ptr->cached_bg_bitmap = dest_bg_bitmap; text_ptr->cached_pixmap = dest_pixmap; text_ptr->cached_zoomed = zoomedIn; text_ptr->cached_zoom = zoomScale; XDestroyImage(src_image); XDestroyImage(src_bitmap_image); XDestroyImage(src_bitmap_bg_image); XDestroyImage(dest_image); XDestroyImage(dest_bitmap_image); XDestroyImage(dest_bitmap_bg_image); if (!watch_cursor && !RedrawDuringScrolling()) { SetDefaultCursor(mainWindow); ShowCursor(); } else { CheckInterrupt(TRUE); } } void CleanOuterInnerSel() { register struct SelRec *sel_ptr, *next_sel; if (outerSel != NULL) { for (sel_ptr=outerSel; sel_ptr != NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } outerSel = innerSel = NULL; } } void UpdateOuterInnerSel(obj_ptr) struct ObjRec *obj_ptr; /* outerSel is at the top of the chain and innerSel is at the bottom */ { AddObjIntoSel(obj_ptr, NULL, outerSel, &outerSel, &innerSel); } /* * Need to check for pins. */ static struct ObjRec *SubFindTextObj(ObjPtr, XOff, YOff, obj_to_be_found) struct ObjRec *ObjPtr, *obj_to_be_found; int XOff, YOff; { register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; struct ObjRec *found_text_obj; for (obj_ptr=ObjPtr->detail.r->first; obj_ptr!=NULL; obj_ptr=obj_ptr->next) { if (ObjPtr->type == OBJ_PIN && obj_ptr != GetPinObj(ObjPtr)) { continue; } obj_ptr->tmp_parent = ObjPtr; if (obj_to_be_found == NULL) { if (obj_ptr->type == OBJ_TEXT && XOff >= OFFSET_X(obj_ptr->bbox.ltx)-3 && YOff >= OFFSET_Y(obj_ptr->bbox.lty)-3 && XOff <= OFFSET_X(obj_ptr->bbox.rbx)+3 && YOff <= OFFSET_Y(obj_ptr->bbox.rby)+3) { return obj_ptr; } else { attr_ptr = obj_ptr->fattr; for (; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (XOff>=OFFSET_X(attr_ptr->obj->bbox.ltx)-3 && YOff>=OFFSET_Y(attr_ptr->obj->bbox.lty)-3 && XOff<=OFFSET_X(attr_ptr->obj->bbox.rbx)+3 && YOff<=OFFSET_Y(attr_ptr->obj->bbox.rby)+3 && attr_ptr->shown == TRUE) { return attr_ptr->obj; } } switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: continue; } if (XOff >= OFFSET_X(obj_ptr->bbox.ltx)-3 && YOff >= OFFSET_Y(obj_ptr->bbox.lty)-3 && XOff <= OFFSET_X(obj_ptr->bbox.rbx)+3 && YOff <= OFFSET_Y(obj_ptr->bbox.rby)+3) { if ((found_text_obj=SubFindTextObj(obj_ptr, XOff, YOff, obj_to_be_found)) != NULL) { UpdateOuterInnerSel(obj_ptr); return found_text_obj; } } } } else { if (obj_ptr == obj_to_be_found) { return obj_ptr; } else { attr_ptr = obj_ptr->fattr; for (; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->obj == obj_to_be_found) { return attr_ptr->obj; } } switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: continue; } if ((found_text_obj=SubFindTextObj(obj_ptr, XOff, YOff, obj_to_be_found)) != NULL) { UpdateOuterInnerSel(obj_ptr); return found_text_obj; } } } } return NULL; } struct ObjRec *FindTextObj(XOff, YOff, obj_to_be_found) int XOff, YOff; struct ObjRec *obj_to_be_found; /* XOff and YOff are screen offsets */ { register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; struct ObjRec *found_text_obj; CleanOuterInnerSel(); for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { obj_ptr->tmp_parent = NULL; if (colorLayers && !ObjInVisibleLayer(obj_ptr)) { continue; } if (obj_to_be_found == NULL) { if (obj_ptr->type == OBJ_TEXT && XOff >= OFFSET_X(obj_ptr->bbox.ltx)-3 && YOff >= OFFSET_Y(obj_ptr->bbox.lty)-3 && XOff <= OFFSET_X(obj_ptr->bbox.rbx)+3 && YOff <= OFFSET_Y(obj_ptr->bbox.rby)+3) { return obj_ptr; } else { attr_ptr = obj_ptr->fattr; for (; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (XOff>=OFFSET_X(attr_ptr->obj->bbox.ltx)-3 && YOff>=OFFSET_Y(attr_ptr->obj->bbox.lty)-3 && XOff<=OFFSET_X(attr_ptr->obj->bbox.rbx)+3 && YOff<=OFFSET_Y(attr_ptr->obj->bbox.rby)+3 && attr_ptr->shown == TRUE) { return attr_ptr->obj; } } if (!groupedTextEditable) continue; switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: continue; } if (XOff >= OFFSET_X(obj_ptr->bbox.ltx)-3 && YOff >= OFFSET_Y(obj_ptr->bbox.lty)-3 && XOff <= OFFSET_X(obj_ptr->bbox.rbx)+3 && YOff <= OFFSET_Y(obj_ptr->bbox.rby)+3) { if (colorLayers && !ObjInVisibleLayer(obj_ptr)) { } else if ((found_text_obj=SubFindTextObj(obj_ptr, XOff, YOff, obj_to_be_found)) != NULL) { UpdateOuterInnerSel(obj_ptr); return found_text_obj; } } } } else { if (obj_ptr == obj_to_be_found) { return obj_ptr; } else { attr_ptr = obj_ptr->fattr; for (; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->obj == obj_to_be_found) { return attr_ptr->obj; } } if (!groupedTextEditable) continue; switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: continue; } if (colorLayers && !ObjInVisibleLayer(obj_ptr)) { } else if ((found_text_obj=SubFindTextObj(obj_ptr, XOff, YOff, obj_to_be_found)) != NULL) { UpdateOuterInnerSel(obj_ptr); return found_text_obj; } } } } return NULL; } void UnlinkCurTextFromInnerSel() { register struct GroupRec *group_obj=innerSel->obj->detail.r; if (group_obj->first == group_obj->last) { if (outerSel != innerSel || innerSel->obj->fattr != NULL) { #ifdef _TGIF_DBG /* debug, do not translate */ sprintf(gszMsgBox, "%s %s. %s! %s %s.", "Error! The text object within a composite object which you", "have just erased caused all ancestors to be deleted", "You may see ghost images now", "Please undo and try ungroup the ancestor object first", "before erasing the text"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } #endif /* _TGIF_DBG */ } DelObj(outerSel->obj); CleanOuterInnerSel(); curTextObj = NULL; return; } else if (curTextObj == group_obj->first) { curTextObj->next->prev = NULL; group_obj->first = curTextObj->next; } else if (curTextObj == group_obj->last) { curTextObj->prev->next = NULL; group_obj->last = curTextObj->prev; } else { curTextObj->prev->next = curTextObj->next; curTextObj->next->prev = curTextObj->prev; } curTextObj->prev = curTextObj->next = NULL; } void AdjAncestorsBBox() { register struct SelRec *sel_ptr; for (sel_ptr=innerSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { AdjObjBBox(sel_ptr->obj); } } static void DumpTextPath(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { struct TextRec *text_ptr=ObjPtr->detail.t; MiniLinesInfo *minilines=(&text_ptr->minilines); int x=ObjPtr->x, y=ObjPtr->y, trans_pat=ObjPtr->trans_pat; fprintf(FP, " %s\n", gPsCmd[PS_GSAVE]); fprintf(FP, " 1 %s\n", gPsCmd[PS_SETLINEWIDTH]); if (ObjPtr->ctm != NULL) { float m[6]; m[CTM_SX] = ((float)ObjPtr->ctm->m[CTM_SX])/((float)1000.0); m[CTM_SY] = ((float)ObjPtr->ctm->m[CTM_SY])/((float)1000.0); m[CTM_SIN] = ((float)ObjPtr->ctm->m[CTM_SIN])/((float)1000.0); m[CTM_MSIN] = ((float)ObjPtr->ctm->m[CTM_MSIN])/((float)1000.0); fprintf(FP, " %1d %1d %s\n", ObjPtr->x, ObjPtr->y, gPsCmd[PS_TRANSLATE]); fprintf(FP, " [%.3f %.3f %.3f %.3f %1d %1d] %s\n", m[CTM_SX], m[CTM_SIN], m[CTM_MSIN], m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY], gPsCmd[PS_CONCAT]); x = y = 0; } switch (penPat) { case SOLIDPAT: break; case BACKPAT: if (!trans_pat) { fprintf(FP, " 1 %s\n", gPsCmd[PS_SETGRAY]); } break; default: if (!colorDump && useGray) { GrayCheck(penPat); fprintf(FP, " %s %s\n", GrayStr(penPat), gPsCmd[PS_SETGRAY]); } break; } fprintf(FP, " %1d %1d %s\n", x, y+minilines->first->asc, gPsCmd[PS_MOVETO]); if (preDumpSetup) PSUseMiniLines(); DumpMiniLines(minilines, x, y+minilines->first->asc, FP, &ObjPtr->obbox, TRUE, 6); #ifdef _TGIF_DBG CleanUpIndentStrings(); #endif /* _TGIF_DBG */ fprintf(FP, " %s\n", gPsCmd[PS_GRESTORE]); } static void DumpSimpleTextBBoxPath(FP, just, x, lty, rby, indent) FILE *FP; int just, x, lty, rby, indent; { int i=0; if (psUseShortHand) { for (i=0; i < indent; i++) fprintf(FP, " "); fprintf(FP, "%s %1d %1d %s ", gPsCmd[PS_NEWPATH], x, lty, gPsCmd[PS_MOVETO]); switch (just) { case JUST_L: break; case JUST_C: fprintf(FP, "tgifstrw 2 %s %s 0 %s ", gPsCmd[PS_DIV], gPsCmd[PS_NEG], gPsCmd[PS_RMOVETO]); break; case JUST_R: fprintf(FP, "tgifstrw %s 0 %s ", gPsCmd[PS_NEG], gPsCmd[PS_RMOVETO]); break; } fprintf(FP, "tgifstrw 0 %s 0 %1d %s tgifstrw neg 0 %s %s ", gPsCmd[PS_RLINETO], rby-lty, gPsCmd[PS_RLINETO], gPsCmd[PS_RLINETO], gPsCmd[PS_CLOSEPATH]); } else { for (i=0; i < indent; i++) fprintf(FP, " "); fprintf(FP, "%s\n", gPsCmd[PS_NEWPATH]); for (i=0; i < indent; i++) fprintf(FP, " "); fprintf(FP, " %1d %1d %s ", x, lty, gPsCmd[PS_MOVETO]); switch (just) { case JUST_L: break; case JUST_C: fprintf(FP, "tgifstrw 2 %s %s 0 %s\n", gPsCmd[PS_DIV], gPsCmd[PS_NEG], gPsCmd[PS_RMOVETO]); for (i=0; i < indent+3; i++) fprintf(FP, " "); break; case JUST_R: fprintf(FP, "tgifstrw %s 0 %s\n", gPsCmd[PS_NEG], gPsCmd[PS_RMOVETO]); for (i=0; i < indent+3; i++) fprintf(FP, " "); break; } fprintf(FP, "tgifstrw 0 %s ", gPsCmd[PS_RLINETO]); fprintf(FP, "0 %1d %s ", rby-lty, gPsCmd[PS_RLINETO]); fprintf(FP, "tgifstrw neg 0 %s\n", gPsCmd[PS_RLINETO]); for (i=0; i < indent; i++) fprintf(FP, " "); fprintf(FP, "%s ", gPsCmd[PS_CLOSEPATH]); } } static void DumpTextFill(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { struct TextRec *text_ptr=ObjPtr->detail.t; int fill=text_ptr->fill, trans_pat=ObjPtr->trans_pat, ltx, lty, rbx, rby; int color_index=ObjPtr->color; int simple_text=SimpleTextObj(text_ptr); if (simple_text) { fprintf(FP, " /tgifstrw 0 def\n"); DumpSimpleTextPath(FP, ObjPtr); } DumpRGBColorLine(FP, color_index, 0, TRUE); if (ObjPtr->ctm == NULL) { ltx = ObjPtr->bbox.ltx; lty = ObjPtr->bbox.lty; rbx = ObjPtr->bbox.rbx-1; rby = ObjPtr->bbox.rby-1; } else { ltx = ObjPtr->detail.t->orig_bbox.ltx; lty = ObjPtr->detail.t->orig_bbox.lty; rbx = ObjPtr->detail.t->orig_bbox.rbx-1; rby = ObjPtr->detail.t->orig_bbox.rby-1; } if (ObjPtr->ctm != NULL) { float m[6]; fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); m[CTM_SX] = ((float)ObjPtr->ctm->m[CTM_SX])/((float)1000.0); m[CTM_SY] = ((float)ObjPtr->ctm->m[CTM_SY])/((float)1000.0); m[CTM_SIN] = ((float)ObjPtr->ctm->m[CTM_SIN])/((float)1000.0); m[CTM_MSIN] = ((float)ObjPtr->ctm->m[CTM_MSIN])/((float)1000.0); fprintf(FP, " %1d %1d %s\n", ObjPtr->x, ObjPtr->y, gPsCmd[PS_TRANSLATE]); fprintf(FP, " [%.3f %.3f %.3f %.3f %1d %1d] %s\n", m[CTM_SX], m[CTM_SIN], m[CTM_MSIN], m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY], gPsCmd[PS_CONCAT]); fprintf(FP, " %1d %s %1d %s %s\n", ObjPtr->x, gPsCmd[PS_NEG], ObjPtr->y, gPsCmd[PS_NEG], gPsCmd[PS_TRANSLATE]); } switch (fill) { case NONEPAT: break; case SOLIDPAT: if (simple_text) { DumpSimpleTextBBoxPath(FP, text_ptr->minilines.just, ObjPtr->x, lty, rby, 0); } else { DumpRectPath(FP, ltx, lty, rbx, rby, 0, FALSE); } fprintf(FP, "%s\n", gPsCmd[PS_FILL]); break; case BACKPAT: if (!trans_pat) { if (simple_text) { DumpSimpleTextBBoxPath(FP, text_ptr->minilines.just, ObjPtr->x, lty, rby, 0); } else { DumpRectPath(FP, ltx, lty, rbx, rby, 0, FALSE); } fprintf(FP, "1 %s %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 0, TRUE); } break; default: /* patterned */ fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if (colorDump || !useGray) { if (!trans_pat) { if (simple_text) { DumpSimpleTextBBoxPath(FP, text_ptr->minilines.just, ObjPtr->x, lty, rby, 3); } else { DumpRectPath(FP, ltx, lty, rbx, rby, 3, FALSE); } fprintf(FP, "1 %s %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 3, TRUE); } } else { GrayCheck(fill); fprintf(FP, " %s %s\n", GrayStr(fill), gPsCmd[PS_SETGRAY]); } if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); if (simple_text) { DumpSimpleTextBBoxPath(FP, text_ptr->minilines.just, ObjPtr->x, lty, rby, 3); } else { DumpRectPath(FP, ltx, lty, rbx, rby, 3, FALSE); } fprintf(FP, "%s %s\n", gPsCmd[PS_EOCLIP], gPsCmd[PS_NEWPATH]); DumpPatFill(FP, fill, ObjPtr->bbox, 3, TRUE); } else { if (simple_text) { DumpSimpleTextBBoxPath(FP, text_ptr->minilines.just, ObjPtr->x, lty, rby, 3); } else { DumpRectPath(FP, ltx, lty, rbx, rby, 3, FALSE); } fprintf(FP, "%s\n", gPsCmd[PS_FILL]); } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); break; } if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); } void DumpTextObj(FP, ObjPtr) FILE *FP; register struct ObjRec *ObjPtr; { struct TextRec *text_ptr=ObjPtr->detail.t; MiniLinesInfo *minilines=(&text_ptr->minilines); int pen=text_ptr->pen, fill=text_ptr->fill, trans_pat=ObjPtr->trans_pat; int underline_y_offset=text_ptr->underline_y_offset; int overline_y_offset=text_ptr->overline_y_offset; if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } if (ObjPtr->ctm != NULL && (ObjPtr->obbox.ltx == ObjPtr->obbox.rbx || ObjPtr->obbox.lty == ObjPtr->obbox.rby)) { /* zero width or height text */ return; } fprintf(FP, "%% TEXT\n"); fprintf(FP, "%s\n", gPsCmd[PS_NEWPATH]); if (!PRTGIF) SaveCurFont(); ObjFontInfoToCurFontInfo(text_ptr); penPat = pen; transPat = trans_pat; objFill = fill; curUnderlineYOffset = underline_y_offset; curOverlineYOffset = overline_y_offset; if (PRTGIF || text_ptr->read_only) { canvasFontAsc = minilines->first->asc; canvasFontDes = minilines->first->des; textCursorH = canvasFontAsc + canvasFontDes; } /* fill the bounding rectangle */ DumpTextFill(FP, ObjPtr); if (penPat == NONEPAT) { fprintf(FP, "\n"); if (!PRTGIF) RestoreCurFont(); return; } if ((colorDump || !useGray) && penPat>BACKPAT && curFont==FONT_COU) { if (PRTGIF) { fprintf(stderr, "%s\n", TgLoadString(STID_WARN_PRINT_COURIER_IN_COLOR)); fprintf(stderr, "%s\n", TgLoadString(STID_MAY_CAUSE_ERROR_IN_PRINTOUT)); } else { TwoLineMsg(TgLoadString(STID_WARN_PRINT_COURIER_IN_COLOR), TgLoadString(STID_MAY_CAUSE_ERROR_IN_PRINTOUT)); } } if ((colorDump || !useGray) && penPat > BACKPAT && !trans_pat) { int tmp_pen = penPat; penPat = BACKPAT; DumpTextPath(FP, ObjPtr); penPat = tmp_pen; } if (!(penPat == BACKPAT && trans_pat)) { DumpTextPath(FP, ObjPtr); } fprintf(FP, "\n"); if (!PRTGIF) RestoreCurFont(); } static int NeedToCacheStrSeg(pStrSeg) StrSegInfo *pStrSeg; { return (pStrSeg->double_byte && pStrSeg->double_byte_vertical); } static int NeedToCacheStrBlock(pStrBlock) StrBlockInfo *pStrBlock; { switch (pStrBlock->type) { case SB_SIMPLE: return NeedToCacheStrSeg(pStrBlock->seg); case SB_CHAR_SPACE: return FALSE; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL && NeedToCacheMiniLines(pStrBlock->sup)) { return TRUE; } if (pStrBlock->sub != NULL && NeedToCacheMiniLines(pStrBlock->sub)) { return TRUE; } if (pStrBlock->type == SB_SUPSUB_CENTER) { return NeedToCacheStrSeg(pStrBlock->seg); } break; } return FALSE; } static int NeedToCacheMiniLine(pMiniLine) MiniLineInfo *pMiniLine; { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (NeedToCacheStrBlock(pStrBlock)) { return TRUE; } } return FALSE; } int NeedToCacheMiniLines(minilines) MiniLinesInfo *minilines; { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (NeedToCacheMiniLine(pMiniLine)) { return TRUE; } } return FALSE; } int NeedsToCacheTextObj(ObjPtr) struct ObjRec *ObjPtr; { struct TextRec *text_ptr=ObjPtr->detail.t; if (ObjPtr->ctm != NULL || zoomScale != 0 || text_ptr->read_only) { return TRUE; } return NeedToCacheMiniLines(&text_ptr->minilines); } void SaveString(FP, S) FILE *FP; register char *S; { for ( ; *S != '\0'; S++) { if (*S == '\\') { if (fprintf(FP, "%s", "\\\\") == EOF) writeFileFailed = TRUE; } else if (*S == '"') { if (doubleQuoteDoubleQuote) { if (fprintf(FP, "%s", "\"\"") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, "%s", "\\\"") == EOF) writeFileFailed = TRUE; } } else if ((*S) & 0x80) { if (fprintf(FP, "\\%o", (*S)&0xff) == EOF) writeFileFailed = TRUE; } else { if (fputc(*S, FP) == EOF) writeFileFailed = TRUE; } } } void SaveDoubleByteString(FP, S) FILE *FP; register char *S; { for ( ; *S != '\0'; S++) { if ((*S)&0x80) { if (fprintf(FP, "\\%03o\\%03o", S[0]&0xff, S[1]&0xff) == EOF) { writeFileFailed = TRUE; } S++; if (*S == '\0') break; } else if (*S == '\\') { if (fprintf(FP, "%s", "\\\\") == EOF) writeFileFailed = TRUE; } else if (*S == '"') { if (doubleQuoteDoubleQuote) { if (fprintf(FP, "%s", "\"\"") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, "%s", "\\\"") == EOF) writeFileFailed = TRUE; } } else { if (fputc(*S, FP) == EOF) writeFileFailed = TRUE; } } } static void SaveStrSeg(FP, pStrSeg) FILE *FP; StrSegInfo *pStrSeg; /* * str_seg() */ { char font_str[MAXSTRING]; int overunder=((pStrSeg->overline_on<<1)+pStrSeg->underline_on); GetPSFontStr(pStrSeg->font, pStrSeg->style, font_str); /* font_str starts with the '/' character */ if (fprintf(FP, "str_seg('%s',", colorMenuItems[pStrSeg->color]) == EOF) { writeFileFailed = TRUE; } /* * When the new file format (version 38) is implemented, make sure to * save the DontReencode related information (dontreencode) in the file! */ if (fprintf(FP, "'%s',%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,", &font_str[1], pStrSeg->style, pStrSeg->sz_unit, pStrSeg->w, pStrSeg->asc, pStrSeg->des, pStrSeg->min_lbearing, pStrSeg->max_rextra, overunder, pStrSeg->double_byte, pStrSeg->double_byte_mod_bytes, pStrSeg->double_byte_vertical, pStrSeg->direction) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "\n\t\"") == EOF) writeFileFailed = TRUE; if (pStrSeg->double_byte) { SaveDoubleByteString(FP, pStrSeg->dyn_str.s); } else { SaveString(FP, pStrSeg->dyn_str.s); } if (fprintf(FP, "\")") == EOF) writeFileFailed = TRUE; } static void SaveAStrBlock(FP, pStrBlock) FILE *FP; StrBlockInfo *pStrBlock; /* * str_block() */ { int has_sup=FALSE, has_sub=FALSE; int something_saved=FALSE; switch (pStrBlock->type) { case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) has_sup = TRUE; if (pStrBlock->sub != NULL) has_sub = TRUE; break; } if (fprintf(FP, "str_block(%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d", pStrBlock->type, pStrBlock->w, pStrBlock->asc, pStrBlock->des, pStrBlock->min_lbearing, pStrBlock->max_rextra, pStrBlock->special_char_w, has_sup, has_sub) == EOF) { writeFileFailed = TRUE; } switch (pStrBlock->type) { case SB_SIMPLE: if (fprintf(FP, ",[\n") == EOF) writeFileFailed = TRUE; SaveStrSeg(FP, pStrBlock->seg); if (fprintf(FP, "]") == EOF) writeFileFailed = TRUE; break; case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (fprintf(FP, ",[\n") == EOF) writeFileFailed = TRUE; if (pStrBlock->sup != NULL) { SaveMiniLines(FP, pStrBlock->sup); something_saved = TRUE; } if (pStrBlock->sub != NULL) { if (something_saved) { if (fprintf(FP, ",\n") == EOF) writeFileFailed = TRUE; } SaveMiniLines(FP, pStrBlock->sub); something_saved = TRUE; } if (pStrBlock->type == SB_SUPSUB_CENTER) { if (something_saved) { if (fprintf(FP, ",\n") == EOF) writeFileFailed = TRUE; } /* pStrBlock->seg better not be NULL or it will crash */ SaveStrSeg(FP, pStrBlock->seg); something_saved = TRUE; } if (something_saved) { if (fprintf(FP, "\n]") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, "]") == EOF) writeFileFailed = TRUE; } break; } if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } static void SaveStrBlocks(FP, pFirstStrBlock) FILE *FP; StrBlockInfo *pFirstStrBlock; /* * ... [ * str_block(), * str_block(), * ... * str_block() * ] */ { StrBlockInfo *pStrBlock; if (fprintf(FP, "[\n") == EOF) writeFileFailed = TRUE; for (pStrBlock=pFirstStrBlock; pStrBlock != NULL; pStrBlock=pStrBlock->next) { SaveAStrBlock(FP, pStrBlock); if (pStrBlock->next != NULL) { if (fprintf(FP, ",\n") == EOF) { writeFileFailed = TRUE; } } } if (pFirstStrBlock == NULL) { if (fprintf(FP, "]") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, "\n]") == EOF) writeFileFailed = TRUE; } } static void SaveAMiniLine(FP, pMiniLine) FILE *FP; MiniLineInfo *pMiniLine; /* * mini_line(w,asc,des,min_lbearing,max_rextra,v_gap) */ { if (pMiniLine == pMiniLine->owner_minilines->first && pMiniLine->v_gap != 0) { TgAssert(FALSE, "First mini_line has non-zero v_gap in SaveAMiniLine()", "It's set to 0"); pMiniLine->v_gap = 0; } if (fprintf(FP, "mini_line(%1d,%1d,%1d,%1d,%1d,%1d,", pMiniLine->w, pMiniLine->asc, pMiniLine->des, pMiniLine->min_lbearing, pMiniLine->max_rextra, pMiniLine->v_gap) == EOF) { writeFileFailed = TRUE; } SaveStrBlocks(FP, pMiniLine->first_block); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } void SaveMiniLines(FP, minilines) FILE *FP; MiniLinesInfo *minilines; /* * ... [ * minilines(w,h,min_lbearing,max_rextra,just,v_space,baseline_offset,[ * mini_line(), * mini_line(), * ... * mini_line() * ]) * ] */ { MiniLineInfo *pMiniLine=NULL; if (fprintf(FP, "minilines(%1d,%1d,%1d,%1d,%1d,%1d,%1d,[\n", minilines->w, minilines->h, minilines->min_lbearing, minilines->max_rextra, minilines->just, minilines->v_space, minilines->baseline_offset) == EOF) { writeFileFailed = TRUE; } for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { SaveAMiniLine(FP, pMiniLine); if (pMiniLine->next != NULL) { if (fprintf(FP, ",\n") == EOF) writeFileFailed = TRUE; } } if (fprintf(FP, "\n])") == EOF) writeFileFailed = TRUE; } void CombineOverUnderYOffsets(underline_y_offset, overline_y_offset, pn_combined) int underline_y_offset, overline_y_offset, *pn_combined; { underline_y_offset = (underline_y_offset & 0x0ffff); overline_y_offset = (overline_y_offset & 0x0ffff); *pn_combined = ((overline_y_offset << 16) | underline_y_offset); } void UncombineOverUnderYOffsets(combined, pn_underline_y_offset, pn_overline_y_offset) int combined, *pn_underline_y_offset, *pn_overline_y_offset; { int underline_y_offset=(combined & 0x0ffff); int overline_y_offset=((combined >> 16) & 0x0ffff); if ((underline_y_offset & 0x08000) == 0x08000) { underline_y_offset = (0x010000 - abs(underline_y_offset)); underline_y_offset = -underline_y_offset; } if ((overline_y_offset & 0x08000) == 0x08000) { overline_y_offset = (0x010000 - abs(overline_y_offset)); overline_y_offset = -overline_y_offset; } *pn_underline_y_offset = underline_y_offset; *pn_overline_y_offset = overline_y_offset; } void SaveTextObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { struct TextRec *text_ptr=ObjPtr->detail.t; int compressed=FALSE, combined_y_offset=0; CombineOverUnderYOffsets(text_ptr->underline_y_offset, text_ptr->overline_y_offset, &combined_y_offset); if (fprintf(FP, "text('%s',", colorMenuItems[ObjPtr->color]) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,", ObjPtr->x, ObjPtr->y, text_ptr->lines, text_ptr->minilines.just, text_ptr->pen, ObjPtr->obbox.rbx-ObjPtr->obbox.ltx, ObjPtr->obbox.rby-ObjPtr->obbox.lty, ObjPtr->id, text_ptr->minilines.first->first_block->asc, text_ptr->minilines.first->first_block->des) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,\"\",", text_ptr->fill, text_ptr->minilines.v_space, ObjPtr->rotation, ObjPtr->locked, combined_y_offset, text_ptr->w, text_ptr->h, text_ptr->min_lbearing, text_ptr->max_rextra) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,'',", compressed, ObjPtr->ctm!=NULL, ObjPtr->invisible, ObjPtr->trans_pat, text_ptr->baseline_y) == EOF) { writeFileFailed = TRUE; } if (ObjPtr->ctm != NULL && fprintf(FP, "[\n\t%1d,%1d,%1d,%1d,%1d,%1d,%g,%g,%g,%g,%1d,%1d,%1d,%1d,%1d,%1d],", ObjPtr->x, ObjPtr->y, ObjPtr->orig_obbox.ltx, ObjPtr->orig_obbox.lty, ObjPtr->orig_obbox.rbx, ObjPtr->orig_obbox.rby, ObjPtr->ctm->m[CTM_SX], ObjPtr->ctm->m[CTM_SIN], ObjPtr->ctm->m[CTM_MSIN], ObjPtr->ctm->m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY], text_ptr->orig_bbox.ltx, text_ptr->orig_bbox.lty, text_ptr->orig_bbox.rbx, text_ptr->orig_bbox.rby) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, "\t"); if (fprintf(FP, "[\n") == EOF) writeFileFailed = TRUE; if (text_ptr->minilines.baseline_offset != 0) { TgAssert(FALSE, "Minilines of text object has bad baseline_offset in SaveTextObj()", "It's set to 0"); text_ptr->minilines.baseline_offset = 0; } SaveMiniLines(FP, &text_ptr->minilines); if (fprintf(FP, "])") == EOF) writeFileFailed = TRUE; } void SaveHexString(FP, buf) FILE *FP; char *buf; { for ( ; *buf != '\0'; buf++) { int ival=0; ival = ((((unsigned int)(*buf)) >> 4) & 0x0f); if (ival >= 10) { fprintf(FP, "%c", (char)(((int)'a')+(ival-10))); } else { fprintf(FP, "%c", (char)(((int)'0')+ival)); } ival = (((unsigned int)(*buf)) & 0x0f); if (ival >= 10) { fprintf(FP, "%c", (char)(((int)'a')+(ival-10))); } else { fprintf(FP, "%c", (char)(((int)'0')+ival)); } } } char *ReadString(Str) char *Str; { register char *s=NULL; if (Str == NULL) return NULL; for (s=Str; *s != '\0'; s++) { if (*s == '"') { if (s[1] == '"') { UtilStrCpy(s, s+1); } else { break; } } else if (*s == '\\') { if (s[1] >= '0' && s[1] <= '3') { if (s[2] >= '0' && s[2] <= '7' && s[3] >= '0' && s[3] <= '7') { *s = (char)(((s[1]-'0')<<6)+((s[2]-'0')<<3)+(s[3]-'0')); UtilStrCpy(s+1, s+4); } else { sprintf(gszMsgBox, TgLoadString(STID_BAD_OCTAL_STRING_ENCOUNTERED), s[1], s[2], s[3]); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } UtilStrCpy(s, s+1); } } else { UtilStrCpy(s, s+1); } } } if (*s == '"') s++; return s; } StrSegInfo *CreateStrSegFromString(buf, pOwnerStrBlock) char *buf; StrBlockInfo *pOwnerStrBlock; { StrSegInfo *pStrSeg=NewStrSeg(); DynStrSet(&pStrSeg->dyn_str, buf); pStrSeg->color = colorIndex; pStrSeg->font = curFont; pStrSeg->style = curStyle; pStrSeg->sz_unit = GetCurSzUnit(); if (mainDisplay != NULL) { strcpy(pStrSeg->color_str, colorMenuItems[colorIndex]); } pStrSeg->double_byte = canvasFontDoubleByte; pStrSeg->double_byte_mod_bytes = canvasFontDoubleByteModBytes; pStrSeg->double_byte_vertical = canvasFontDoubleByteVertical; pStrSeg->direction = canvasFontDirection; pStrSeg->dontreencode = canvasFontDontReencode; pStrSeg->underline_on = curUnderlineOn; pStrSeg->overline_on = curOverlineOn; pStrSeg->asc = canvasFontAsc; pStrSeg->des = canvasFontDes; if (mainDisplay != NULL) { pStrSeg->w = MyTextWidth(canvasFontPtr, pStrSeg->dyn_str.s, pStrSeg->dyn_str.sz-1); } pStrSeg->owner = pOwnerStrBlock; return pStrSeg; } StrBlockInfo *CreateStrBlockFromString(buf, pOwnerMiniLine) char *buf; MiniLineInfo *pOwnerMiniLine; { StrBlockInfo *pStrBlock=NewStrBlock(); pStrBlock->seg = CreateStrSegFromString(buf, pStrBlock); pStrBlock->type = SB_SIMPLE; pStrBlock->owner_mini_line = pOwnerMiniLine; return pStrBlock; } MiniLineInfo *CreateMiniLineFromString(buf, ppFirstMiniLine, ppLastMiniLine) char *buf; MiniLineInfo **ppFirstMiniLine, **ppLastMiniLine; { MiniLineInfo *pMiniLine=NewMiniLine(); if (canvasFontDoubleByte) { struct StrRec *pStr=NULL, *pStr1=NULL; pStr = SegmentDoubleByteString(buf); for (pStr1=pStr; pStr1 != NULL; pStr1=pStr1->next) { int str_seg_double_byte=TRUE; StrBlockInfo *pStrBlock=CreateStrBlockFromString(pStr1->dyn_str.s, pMiniLine); if (*pStr1->dyn_str.s != '\0') { str_seg_double_byte = ((*pStr1->dyn_str.s) & 0x80); } pStrBlock->prev = pMiniLine->last_block; if (pMiniLine->first_block == NULL) { pMiniLine->first_block = pStrBlock; } else { pMiniLine->last_block->next = pStrBlock; } pMiniLine->last_block = pStrBlock; if (str_seg_double_byte == FALSE) { pStrBlock->seg->font = defaultSingleByteFont; pStrBlock->seg->double_byte = FALSE; pStrBlock->seg->double_byte_mod_bytes = FALSE; pStrBlock->seg->double_byte_vertical = FALSE; } } FreeStrList(pStr); } else { StrBlockInfo *pStrBlock=CreateStrBlockFromString(buf, pMiniLine); pMiniLine->first_block = pMiniLine->last_block = pStrBlock; } if (ppFirstMiniLine != NULL && ppLastMiniLine != NULL) { pMiniLine->prev = (*ppLastMiniLine); pMiniLine->next = NULL;; if ((*ppLastMiniLine) == NULL) { (*ppFirstMiniLine) = pMiniLine; } else { (*ppLastMiniLine)->next = pMiniLine; } (*ppLastMiniLine) = pMiniLine; } return pMiniLine; } struct ObjRec *FormTextObjectFromFile(FP, AbsX, AbsBaselineY) FILE *FP; int AbsX, AbsBaselineY; { MiniLineInfo *pFirstMiniLine=NULL, *pLastMiniLine=NULL; struct ObjRec *obj_ptr=NULL; struct TextRec *text_ptr=NULL; int num_lines=0; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); text_ptr = (struct TextRec *)malloc(sizeof(struct TextRec)); if (text_ptr == NULL) FailAllocMessage(); memset(text_ptr, 0, sizeof(struct TextRec)); if (FP != NULL) { char *buf=NULL; while ((buf=UtilGetALine(FP)) != NULL) { MiniLineInfo *pMiniLine=CreateMiniLineFromString(buf, &pFirstMiniLine, &pLastMiniLine); if (pMiniLine != NULL) { num_lines++; } free(buf); } } if (num_lines == 0) { CreateMiniLineFromString("", &pFirstMiniLine, &pLastMiniLine); num_lines++; } text_ptr->lines = num_lines; text_ptr->minilines.first = pFirstMiniLine; text_ptr->minilines.last = pLastMiniLine; text_ptr->baseline_y = AbsBaselineY; CopyCurInfoIntoTextPtr(obj_ptr, text_ptr); obj_ptr->x = AbsX; obj_ptr->y = AbsBaselineY-text_ptr->minilines.first->asc; obj_ptr->type = OBJ_TEXT; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->id = objId++;; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->detail.t = text_ptr; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; RecalcTextMetrics(text_ptr, AbsX, AbsBaselineY); SetTextBBox(obj_ptr, textJust, text_ptr->w, text_ptr->h, text_ptr->min_lbearing, text_ptr->max_rextra, ROTATE0); AdjObjBBox(obj_ptr); return obj_ptr; } static int PaintLeftText(Str, Just, LtX, LtY) char *Str; int Just, LtX, LtY; /* LtX and LtY are UNSCALED screen offset */ { register int amount; if (zoomScale != 0) { LtX = ZOOMED_SIZE(LtX); LtY = ZOOMED_SIZE(LtY); amount = MyTextWidth(canvasFontPtr, Str, strlen(Str)); BlurText(drawWindow, drawGC, LtX, LtY, (zoomedIn ? ((amount<<zoomScale)+1) : (amount>>zoomScale)+1), (zoomedIn ? (textCursorH<<zoomScale)+1 : (textCursorH>>zoomScale)+1)); return amount; } LtY += canvasFontAsc; amount = MyTextWidth(canvasFontPtr, Str, strlen(Str)); MyDrawString(mainDisplay, drawWindow, drawGC, mainDepth, LtX, LtY, Str, strlen(Str)); return amount; /* return the length of the painted string */ } void RepaintFirstStr(ObjPtr, Str) struct ObjRec *ObjPtr; char *Str; /* Replace (graphically) the FIRST string of the text in ObjPtr by Str */ { struct TextRec *text_ptr=ObjPtr->detail.t; char *s=GetTextPtrFirstStrSeg(text_ptr)->dyn_str.s, *s1=Str; char tmp_str[MAXSTRING+1], *c_ptr; int len; struct BBRec bbox; XGCValues values; bbox.ltx = ObjPtr->obbox.ltx; bbox.lty = ObjPtr->obbox.lty; bbox.rbx = ObjPtr->obbox.rbx; bbox.rby = ObjPtr->obbox.rby; c_ptr = tmp_str; for ( ; *s != '\0' && *s1 != '\0' && *s1 == *s; *c_ptr++ = *s++, s1++) ; if (*s == *s1) return; /* no updates */ text_ptr->attr->owner->dirty = TRUE; *c_ptr = '\0'; PushCurFont(); ObjFontInfoToCurFontInfo(text_ptr); SetCanvasFont(); if (*s != '\0') { values.foreground = GetDrawingBgPixel(INVALID, INVALID); values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle, &values); len = MyTextWidth(canvasFontPtr, tmp_str, strlen(tmp_str)); XFillRectangle(mainDisplay, drawWindow, drawGC, OFFSET_X(bbox.ltx+len), OFFSET_Y(bbox.lty), (zoomedIn ? ((bbox.rbx-bbox.ltx-len)<<zoomScale)+1 : ((bbox.rbx-bbox.ltx-len)>>zoomScale)+1), (zoomedIn ? (textCursorH<<zoomScale)+1 : (textCursorH>>zoomScale)+1)); values.foreground = colorPixels[ObjPtr->color]; XChangeGC(mainDisplay, drawGC, GCForeground, &values); } else { values.foreground = colorPixels[ObjPtr->color]; values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle, &values); } ObjPtr->bbox.rbx = ObjPtr->obbox.rbx = bbox.ltx + PaintLeftText(Str, textJust, bbox.ltx-drawOrigX, bbox.lty-drawOrigY); PopCurFont(); } ������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spline.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000174075�11602233312�014440� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/spline.c,v 1.45 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_SPLINE_C_ #include "tgifdefs.h" #include "dialog.e" #include "file.e" #include "msg.e" #include "poly.e" #include "polygon.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "setup.e" #include "spline.e" #include "strtbl.e" #define SUM_MINUS_2 (theSum-((double)2.0)) #define HALF ((double)0.5) int intSplineTension=3; int splineTol=9; int tighterStructSplines=TRUE; #define curveToFactor (((double)2.0)/((double)3.0)) #define compCurveToFactor (((double)1.0)/((double)3.0)) static double theSum=(double)6.0; int ReadSplineTightness(buf) char *buf; { int tighter=TRUE; char *psz=NULL; if (importingFile) return TRUE; psz = FindChar((int)'(', buf); InitScan(psz, "\t\n, "); if (GETINT("spline_tightness", tighter, "tighter_splines") == INVALID) { return FALSE; } tighterStructSplines = tighter; return TRUE; } void CalcAutoRetractedArrowAttrBend(Style, X0, Y0, X2, Y2, X1, Y1) int Style, X0, Y0, X2, Y2, *X1, *Y1; { double dx, dy, len, new_x, new_y; dx = (double)(X2 - X0); dy = (double)(Y2 - Y0); len = (double)(sqrt(((double)dx)*((double)dx)+((double)dy)*((double)dy))); if (Style == LS_RIGHT) { new_x = ((double)((X0+X2)>>1)) + dy/((double)8.0); new_y = ((double)((Y0+Y2)>>1)) - dx/((double)8.0); } else { new_x = ((double)((X0+X2)>>1)) - dy/((double)8.0); new_y = ((double)((Y0+Y2)>>1)) + dx/((double)8.0); } *X1 = (int)round(new_x); *Y1 = (int)round(new_y); } static void MidPoint(X1, Y1, X2, Y2, pd_mx, pd_my) double X1, Y1, X2, Y2, *pd_mx, *pd_my; { *pd_mx = HALF*X1+HALF*X2; *pd_my = HALF*Y1+HALF*Y2; } static void SetAStructuredSplineTickMark(vs, num_pts, target_vs) IntPoint *vs, *target_vs; int num_pts; { double x, y, x0, y0, x1, y1, x2, y2, x3, y3; double mx1, my1, mx2, my2, mx3, my3, mx12, my12, mx23, my23; switch (num_pts) { case 1: target_vs[0].x = vs[0].x; target_vs[0].y = vs[0].y; break; case 3: x0 = (double)(vs[0].x); y0 = (double)(vs[0].y); x1 = (double)(vs[1].x); y1 = (double)(vs[1].y); x2 = (double)(vs[2].x); y2 = (double)(vs[2].y); MidPoint(x0, y0, x1, y1, &mx1, &my1); MidPoint(x2, y2, x1, y1, &mx2, &my2); MidPoint(mx1, my1, mx2, my2, &x, &y); target_vs[0].x = (int)x; target_vs[0].y = (int)y; break; case 4: x0 = (double)(vs[0].x); y0 = (double)(vs[0].y); x1 = (double)(vs[1].x); y1 = (double)(vs[1].y); x2 = (double)(vs[2].x); y2 = (double)(vs[2].y); x3 = (double)(vs[3].x); y3 = (double)(vs[3].y); MidPoint(x0, y0, x1, y1, &mx1, &my1); MidPoint(x1, y1, x2, y2, &mx2, &my2); MidPoint(x2, y2, x3, y3, &mx3, &my3); MidPoint(mx1, my1, mx2, my2, &mx12, &my12); MidPoint(mx2, my2, mx3, my3, &mx23, &my23); MidPoint(mx12, my12, mx23, my23, &x, &y); target_vs[0].x = (int)x; target_vs[0].y = (int)y; break; } } IntPoint *GetStructuredSplinePolyTickMarkVs(pn_N, obj_ptr, poly_ptr, polygon_ptr) int *pn_N; struct ObjRec *obj_ptr; struct PolyRec *poly_ptr; struct PolygonRec *polygon_ptr; { int i=0, j=0, n=0, num_hinge_vs=0, num_vs=0, index=0; int last_was_smooth=FALSE; IntPoint *vs=NULL, *vlist=NULL, tmp_vs[4], *xformed_vs=NULL; if (poly_ptr != NULL) { n = poly_ptr->n; vlist = poly_ptr->vlist; } else if (polygon_ptr != NULL) { n = polygon_ptr->n; vlist = polygon_ptr->vlist; } if (obj_ptr->ctm != NULL) { xformed_vs = (IntPoint*)malloc((n+1)*sizeof(IntPoint)); if (xformed_vs == NULL) FailAllocMessage(); memset(xformed_vs, 0, (n+1)*sizeof(IntPoint)); for (i=0; i < n; i++) { int tmp_x=0, tmp_y=0; TransformPointThroughCTM(vlist[i].x-obj_ptr->x, vlist[i].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); xformed_vs[i].x = tmp_x + obj_ptr->x; xformed_vs[i].y = tmp_y + obj_ptr->y; } } num_hinge_vs = (n+2)/3; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert((n+2)%3 == 0, "invalid n in GetStructuredSplinePolyTickMarkVs()", NULL); #endif /* _TGIF_DBG */ num_vs = num_hinge_vs; for (i=0, j=0; i < num_hinge_vs; i++, j+=3) { if (i == 0) { if (vlist[0].x != vlist[1].x || vlist[0].y != vlist[1].y) { last_was_smooth = TRUE; } } else if (i == num_hinge_vs-1) { if (vlist[n-1].x != vlist[n-2].x || vlist[n-1].y != vlist[n-2].y) { num_vs++; last_was_smooth = TRUE; } else if (last_was_smooth) { num_vs++; last_was_smooth = FALSE; } } else { if (vlist[j-1].x != vlist[j].x || vlist[j-1].y != vlist[j].y) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(vlist[j+1].x != vlist[j].x || vlist[j+1].y != vlist[j].y, "half smooth detected in GetStructuredSplinePolyTickMarkVs()", NULL); #endif /* _TGIF_DBG */ num_vs++; last_was_smooth = TRUE; } else if (last_was_smooth) { num_vs++; last_was_smooth = FALSE; } } } vs = (IntPoint*)malloc((num_vs+1)*sizeof(IntPoint)); if (vs == NULL) FailAllocMessage(); memset(vs, 0, (num_vs+1)*sizeof(IntPoint)); if (xformed_vs != NULL) { vs[0].x = xformed_vs[0].x; vs[0].y = xformed_vs[0].y; } else { vs[0].x = vlist[0].x; vs[0].y = vlist[0].y; } index = 1; last_was_smooth = FALSE; for (i=0, j=0; i < num_hinge_vs; i++, j+=3) { int num_pts_in_seg=0; if (i == 0) { if (xformed_vs != NULL) { tmp_vs[0].x = xformed_vs[0].x; tmp_vs[0].y = xformed_vs[0].y; } else { tmp_vs[0].x = vlist[0].x; tmp_vs[0].y = vlist[0].y; } if (vlist[0].x != vlist[1].x || vlist[0].y != vlist[1].y) { last_was_smooth = TRUE; if (xformed_vs != NULL) { tmp_vs[1].x = xformed_vs[1].x; tmp_vs[1].y = xformed_vs[1].y; } else { tmp_vs[1].x = vlist[1].x; tmp_vs[1].y = vlist[1].y; } } } else if (i == num_hinge_vs-1) { if (vlist[n-1].x != vlist[n-2].x || vlist[n-1].y != vlist[n-2].y) { if (last_was_smooth) { num_pts_in_seg = 4; } else { num_pts_in_seg = 3; } if (xformed_vs != NULL) { tmp_vs[num_pts_in_seg-2].x = xformed_vs[j-1].x; tmp_vs[num_pts_in_seg-2].y = xformed_vs[j-1].y; tmp_vs[num_pts_in_seg-1].x = xformed_vs[j].x; tmp_vs[num_pts_in_seg-1].y = xformed_vs[j].y; } else { tmp_vs[num_pts_in_seg-2].x = vlist[j-1].x; tmp_vs[num_pts_in_seg-2].y = vlist[j-1].y; tmp_vs[num_pts_in_seg-1].x = vlist[j].x; tmp_vs[num_pts_in_seg-1].y = vlist[j].y; } SetAStructuredSplineTickMark(tmp_vs, num_pts_in_seg, &vs[index++]); } else if (last_was_smooth) { if (xformed_vs != NULL) { tmp_vs[2].x = xformed_vs[j].x; tmp_vs[2].y = xformed_vs[j].y; } else { tmp_vs[2].x = vlist[j].x; tmp_vs[2].y = vlist[j].y; } SetAStructuredSplineTickMark(tmp_vs, 3, &vs[index++]); } if (poly_ptr != NULL) { if (xformed_vs != NULL) { SetAStructuredSplineTickMark(&xformed_vs[j], 1, &vs[index++]); } else { SetAStructuredSplineTickMark(&vlist[j], 1, &vs[index++]); } } /* all done */ } else { if (vlist[j-1].x != vlist[j].x || vlist[j-1].y != vlist[j].y) { if (last_was_smooth) { num_pts_in_seg = 4; } else { num_pts_in_seg = 3; } if (xformed_vs != NULL) { tmp_vs[num_pts_in_seg-2].x = xformed_vs[j-1].x; tmp_vs[num_pts_in_seg-2].y = xformed_vs[j-1].y; tmp_vs[num_pts_in_seg-1].x = xformed_vs[j].x; tmp_vs[num_pts_in_seg-1].y = xformed_vs[j].y; } else { tmp_vs[num_pts_in_seg-2].x = vlist[j-1].x; tmp_vs[num_pts_in_seg-2].y = vlist[j-1].y; tmp_vs[num_pts_in_seg-1].x = vlist[j].x; tmp_vs[num_pts_in_seg-1].y = vlist[j].y; } SetAStructuredSplineTickMark(tmp_vs, num_pts_in_seg, &vs[index++]); last_was_smooth = TRUE; if (xformed_vs != NULL) { tmp_vs[1].x = xformed_vs[j+1].x; tmp_vs[1].y = xformed_vs[j+1].y; } else { tmp_vs[1].x = vlist[j+1].x; tmp_vs[1].y = vlist[j+1].y; } } else if (last_was_smooth) { if (xformed_vs != NULL) { tmp_vs[2].x = xformed_vs[j].x; tmp_vs[2].y = xformed_vs[j].y; } else { tmp_vs[2].x = vlist[j].x; tmp_vs[2].y = vlist[j].y; } SetAStructuredSplineTickMark(tmp_vs, 3, &vs[index++]); last_was_smooth = FALSE; } if (xformed_vs != NULL) { tmp_vs[0].x = xformed_vs[j].x; tmp_vs[0].y = xformed_vs[j].y; SetAStructuredSplineTickMark(&xformed_vs[j], 1, &vs[index++]); } else { tmp_vs[0].x = vlist[j].x; tmp_vs[0].y = vlist[j].y; SetAStructuredSplineTickMark(&vlist[j], 1, &vs[index++]); } } } if (xformed_vs != NULL) free(xformed_vs); *pn_N = num_vs; return vs; } IntPoint *MakeStructuredSplinePolyVertex(pn_N, ppszSmooth, NumVs, Vs) int *pn_N, NumVs; /* NumVs is poly_ptr->n */ char **ppszSmooth; IntPoint *Vs; /* Vs is poly_ptr->vlist */ { int i=0, j=0, k=0, num_hinge_vs=(NumVs+2)/3, num_vs=0; IntPoint *vs=NULL; char *ssmooth=NULL; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert((NumVs+2)%3 == 0, "invalid NumVs in MakeStructuredSplineVertex()", NULL); #endif /* _TGIF_DBG */ num_vs = num_hinge_vs; for (i=0, j=0; i < num_hinge_vs; i++, j+=3) { if (i == 0) { if (Vs[0].x != Vs[1].x || Vs[0].y != Vs[1].y) { num_vs++; } } else if (i == num_hinge_vs-1) { if (Vs[NumVs-1].x != Vs[NumVs-2].x || Vs[NumVs-1].y != Vs[NumVs-2].y) { num_vs++; } } else { if (Vs[j-1].x != Vs[j].x || Vs[j-1].y != Vs[j].y) { num_vs++; } if (Vs[j+1].x != Vs[j].x || Vs[j+1].y != Vs[j].y) { num_vs++; } } } vs = (IntPoint*)malloc((num_vs+2)*sizeof(IntPoint)); if (vs == NULL) FailAllocMessage(); ssmooth = (char*)malloc((num_vs+2)*sizeof(char)); if (ssmooth == NULL) FailAllocMessage(); memset(ssmooth, 0, (num_vs+2)*sizeof(char)); for (i=0, j=0, k=0; i < num_hinge_vs; i++, j+=3, k++) { if (i == 0) { vs[k].x = Vs[0].x; vs[k].y = Vs[0].y; ssmooth[k] = FALSE; if (Vs[0].x != Vs[1].x || Vs[0].y != Vs[1].y) { k++; vs[k].x = Vs[1].x; vs[k].y = Vs[1].y; ssmooth[k] = TRUE; } } else if (i == num_hinge_vs-1) { if (Vs[NumVs-1].x != Vs[NumVs-2].x || Vs[NumVs-1].y != Vs[NumVs-2].y) { vs[k].x = Vs[NumVs-2].x; vs[k].y = Vs[NumVs-2].y; ssmooth[k] = TRUE; k++; } vs[k].x = Vs[NumVs-1].x; vs[k].y = Vs[NumVs-1].y; ssmooth[k] = FALSE; } else { if (Vs[j-1].x != Vs[j].x || Vs[j-1].y != Vs[j].y) { vs[k].x = Vs[j-1].x; vs[k].y = Vs[j-1].y; ssmooth[k] = TRUE; k++; } vs[k].x = Vs[j].x; vs[k].y = Vs[j].y; ssmooth[k] = FALSE; if (Vs[j+1].x != Vs[j].x || Vs[j+1].y != Vs[j].y) { k++; vs[k].x = Vs[j+1].x; vs[k].y = Vs[j+1].y; ssmooth[k] = TRUE; } } } #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(k == num_vs, "k != num_vs in MakeStructuredSplineVertex()", NULL); #endif /* _TGIF_DBG */ *pn_N = num_vs; *ppszSmooth = ssmooth; return vs; } IntPoint *MakeStructuredSplinePolygonVertex(pn_N, ppszSmooth, NumVs, Vs) int *pn_N, NumVs; char **ppszSmooth; IntPoint *Vs; { int i=0, j=0, k=0, num_hinge_vs=(NumVs+2)/3, num_vs=0; IntPoint *vs=NULL; char *ssmooth=NULL; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert((NumVs+2)%3 == 0, "invalid NumVs in MakeStructuredSplinePolygonVertex()", NULL); TgAssert(Vs[0].x == Vs[NumVs-1].x && Vs[0].y == Vs[NumVs-1].y, "first and last points not identical in MakeStructuredSplinePolygonVertex()", NULL); #endif /* _TGIF_DBG */ num_vs = num_hinge_vs; for (i=0, j=0; i < num_hinge_vs; i++, j+=3) { if (i == 0) { if (Vs[0].x != Vs[1].x || Vs[0].y != Vs[1].y) { num_vs++; } } else if (i == num_hinge_vs-1) { if (Vs[NumVs-1].x != Vs[NumVs-2].x || Vs[NumVs-1].y != Vs[NumVs-2].y) { num_vs++; } } else { if (Vs[j-1].x != Vs[j].x || Vs[j-1].y != Vs[j].y) { num_vs++; } if (Vs[j+1].x != Vs[j].x || Vs[j+1].y != Vs[j].y) { num_vs++; } } } vs = (IntPoint*)malloc((num_vs+2)*sizeof(IntPoint)); if (vs == NULL) FailAllocMessage(); ssmooth = (char*)malloc((num_vs+2)*sizeof(char)); if (ssmooth == NULL) FailAllocMessage(); memset(ssmooth, 0, (num_vs+2)*sizeof(char)); for (i=0, j=0, k=0; i < num_hinge_vs; i++, j+=3, k++) { if (i == 0) { vs[k].x = Vs[0].x; vs[k].y = Vs[0].y; ssmooth[k] = FALSE; if (Vs[0].x != Vs[1].x || Vs[0].y != Vs[1].y) { k++; vs[k].x = Vs[1].x; vs[k].y = Vs[1].y; ssmooth[k] = TRUE; } } else if (i == num_hinge_vs-1) { if (Vs[NumVs-1].x != Vs[NumVs-2].x || Vs[NumVs-1].y != Vs[NumVs-2].y) { vs[k].x = Vs[NumVs-2].x; vs[k].y = Vs[NumVs-2].y; ssmooth[k] = TRUE; k++; } vs[k].x = Vs[NumVs-1].x; vs[k].y = Vs[NumVs-1].y; ssmooth[k] = FALSE; } else { if (Vs[j-1].x != Vs[j].x || Vs[j-1].y != Vs[j].y) { vs[k].x = Vs[j-1].x; vs[k].y = Vs[j-1].y; ssmooth[k] = TRUE; k++; } vs[k].x = Vs[j].x; vs[k].y = Vs[j].y; ssmooth[k] = FALSE; if (Vs[j+1].x != Vs[j].x || Vs[j+1].y != Vs[j].y) { k++; vs[k].x = Vs[j+1].x; vs[k].y = Vs[j+1].y; ssmooth[k] = TRUE; } } } #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(k == num_vs, "k != num_vs in MakeStructuredSplinePolygonVertex()", NULL); #endif /* _TGIF_DBG */ *pn_N = num_vs; *ppszSmooth = ssmooth; return vs; } static XPoint *splineVs=NULL; static DoublePoint *splineDoubleVs=NULL; static int AddSplinePt(N, MaxN, X, Y) int *N, *MaxN, X, Y; { if (*N == *MaxN) { splineVs = (XPoint*)realloc(splineVs, (*MaxN)*2*sizeof(XPoint)+1); if (splineVs == NULL) { return FailAllocMessage(); } *MaxN = (*MaxN) * 2; } splineVs[*N].x = X; splineVs[*N].y = Y; (*N)++; return TRUE; } static int AddDoubleSplinePt(N, MaxN, X, Y) int *N, *MaxN; double X, Y; { if (*N == *MaxN) { splineDoubleVs = (DoublePoint*)realloc(splineDoubleVs, (*MaxN)*2*sizeof(DoublePoint)+1); if (splineDoubleVs == NULL) { return FailAllocMessage(); } *MaxN = (*MaxN) << 1; } splineDoubleVs[*N].x = X; splineDoubleVs[*N].y = Y; (*N)++; return TRUE; } static void SetSplineVs(N, MaxN, X1, Y1, X2, Y2, X3, Y3, X4, Y4) int *N, *MaxN; double X1, Y1, X2, Y2, X3, Y3, X4, Y4; /* X1, Y1, X2, Y2, X3, Y3, X4, Y4 are screen offsets */ { if (tighterStructSplines) { double mx1, my1, mx2, my2, mx3, my3, mx12, my12, mx23, my23, mx4, my4; MidPoint(X1, Y1, X2, Y2, &mx1, &my1); MidPoint(X2, Y2, X3, Y3, &mx2, &my2); MidPoint(X3, Y3, X4, Y4, &mx3, &my3); MidPoint(mx1, my1, mx2, my2, &mx12, &my12); MidPoint(mx2, my2, mx3, my3, &mx23, &my23); MidPoint(mx12, my12, mx23, my23, &mx4, &my4); if (fabs(X1 - mx4) < splineTol && fabs(Y1 - my4) < splineTol) { AddSplinePt(N, MaxN, round(mx4), round(my4)); } else { SetSplineVs(N, MaxN, X1, Y1, mx1, my1, mx12, my12, mx4, my4); } if (fabs(mx4 - X4) < splineTol && fabs(my4 - Y4) < splineTol) { AddSplinePt(N, MaxN, round(X4), round(Y4)); } else { SetSplineVs(N, MaxN, mx4, my4, mx23, my23, mx3, my3, X4, Y4); } } else { double x, y; x = (X2 + X3) / 2.0; y = (Y2 + Y3) / 2.0; if (fabs(X1 - x) < splineTol && fabs(Y1 - y) < splineTol) { AddSplinePt(N, MaxN, round(x), round(y)); } else { SetSplineVs(N, MaxN, X1, Y1, ((X1+X2)/2.0), ((Y1+Y2)/2.0), ((3.0*X2+X3)/4.0), ((3.0*Y2+Y3)/4.0), x, y); } if (fabs(x - X4) < splineTol && fabs(y - Y4) < splineTol) { AddSplinePt(N, MaxN, round(X4), round(Y4)); } else { SetSplineVs(N, MaxN, x, y, ((X2+3.0*X3)/4.0), ((Y2+3.0*Y3)/4.0), ((X3+X4)/2.0), ((Y3+Y4)/2.0), X4, Y4); } } } static void SetDoubleSplineVs(N, MaxN, X1, Y1, X2, Y2, X3, Y3, X4, Y4) int *N, *MaxN; double X1, Y1, X2, Y2, X3, Y3, X4, Y4; /* X1, Y1, X2, Y2, X3, Y3, X4, Y4 are screen offsets */ { if (tighterStructSplines) { double mx1, my1, mx2, my2, mx3, my3, mx12, my12, mx23, my23, mx4, my4; MidPoint(X1, Y1, X2, Y2, &mx1, &my1); MidPoint(X2, Y2, X3, Y3, &mx2, &my2); MidPoint(X3, Y3, X4, Y4, &mx3, &my3); MidPoint(mx1, my1, mx2, my2, &mx12, &my12); MidPoint(mx2, my2, mx3, my3, &mx23, &my23); MidPoint(mx12, my12, mx23, my23, &mx4, &my4); if (fabs(X1 - mx4) < splineTol && fabs(Y1 - my4) < splineTol) { AddDoubleSplinePt(N, MaxN, mx4, my4); } else { SetDoubleSplineVs(N, MaxN, X1, Y1, mx1, my1, mx12, my12, mx4, my4); } if (fabs(mx4 - X4) < splineTol && fabs(my4 - Y4) < splineTol) { AddDoubleSplinePt(N, MaxN, round(X4), round(Y4)); } else { SetDoubleSplineVs(N, MaxN, mx4, my4, mx23, my23, mx3, my3, X4, Y4); } } else { double x, y; x = (X2 + X3) / 2.0; y = (Y2 + Y3) / 2.0; if (fabs(X1 - x) < splineTol && fabs(Y1 - y) < splineTol) { AddDoubleSplinePt(N, MaxN, x, y); } else { SetDoubleSplineVs(N, MaxN, X1, Y1, ((X1+X2)/2.0), ((Y1+Y2)/2.0), ((3.0*X2+X3)/4.0), ((3.0*Y2+Y3)/4.0), x, y); } if (fabs(x - X4) < splineTol && fabs(y - Y4) < splineTol) { AddDoubleSplinePt(N, MaxN, X4, Y4); } else { SetDoubleSplineVs(N, MaxN, x, y, ((X2+3.0*X3)/4.0), ((Y2+3.0*Y3)/4.0), ((X3+X4)/2.0), ((Y3+Y4)/2.0), X4, Y4); } } } XPoint *MakeSplinePolyVertex(Level, Curved, N, XOff, YOff, NumVs, Vs) int Level, Curved, *N, XOff, YOff, NumVs; IntPoint *Vs; { double mx1, my1, mx2, my2, mx3, my3, mx4, my4; double x0, y0, x1, y1, x2, y2, x3, y3; int i, x_off, y_off, max_n, saved_tighter_splines=tighterStructSplines; if (Level == 0 && Curved != LT_STRUCT_SPLINE && saved_tighter_splines) { tighterStructSplines = FALSE; } x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); splineVs = NULL; switch (NumVs) { case 0: case 1: break; case 2: splineVs = (XPoint*)malloc((NumVs+1)*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); *N = 0; tighterStructSplines = saved_tighter_splines; return splineVs; } memset(splineVs, 0, (NumVs+1)*sizeof(XPoint)); splineVs[0].x = ZOOMED_SIZE(Vs[0].x-x_off); splineVs[0].y = ZOOMED_SIZE(Vs[0].y-y_off); splineVs[1].x = ZOOMED_SIZE(Vs[1].x-x_off); splineVs[1].y = ZOOMED_SIZE(Vs[1].y-y_off); *N = 2; break; case 3: if (tighterStructSplines) { mx1 = ZOOMED_SIZE(Vs->x-x_off); my1 = ZOOMED_SIZE((Vs++)->y-y_off); x1 = ZOOMED_SIZE(Vs->x-x_off); y1 = ZOOMED_SIZE((Vs++)->y-y_off); mx2 = (mx1+2.0*x1)/3.0; my2 = (my1+2.0*y1)/3.0; mx4 = ZOOMED_SIZE(Vs->x-x_off); my4 = ZOOMED_SIZE(Vs->y-y_off); mx3 = (2.0*x1+mx4)/3.0; my3 = (2.0*y1+my4)/3.0; max_n = 100; splineVs = (XPoint*)malloc((max_n+1)*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); *N = 0; tighterStructSplines = saved_tighter_splines; return splineVs; } memset(splineVs, 0, (max_n+1)*sizeof(XPoint)); splineVs[0].x = mx1; splineVs[0].y = my1; *N = 1; SetSplineVs(N, &max_n, mx1, my1, mx2, my2, mx3, my3, mx4, my4); } else { mx1 = ZOOMED_SIZE(Vs->x-x_off); my1 = ZOOMED_SIZE((Vs++)->y-y_off); x1 = ZOOMED_SIZE(Vs->x-x_off); y1 = ZOOMED_SIZE((Vs++)->y-y_off); mx2 = (mx1+x1)/2.0; my2 = (my1+y1)/2.0; mx4 = ZOOMED_SIZE(Vs->x-x_off); my4 = ZOOMED_SIZE(Vs->y-y_off); mx3 = (x1+mx4)/2.0; my3 = (y1+my4)/2.0; max_n = 100; splineVs = (XPoint*)malloc((max_n+1)*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); *N = 0; tighterStructSplines = saved_tighter_splines; return splineVs; } memset(splineVs, 0, (max_n+1)*sizeof(XPoint)); splineVs[0].x = mx1; splineVs[0].y = my1; *N = 1; SetSplineVs(N, &max_n, mx1, my1, mx2, my2, mx3, my3, mx4, my4); } break; default: if (tighterStructSplines) { /* must only have 4 points */ double mx1, my1, mx2, my2, mx3, my3, mx12, my12, mx23, my23, mx4, my4; x0 = ZOOMED_SIZE(Vs->x-x_off); y0 = ZOOMED_SIZE((Vs++)->y-y_off); x1 = ZOOMED_SIZE(Vs->x-x_off); y1 = ZOOMED_SIZE((Vs++)->y-y_off); x2 = ZOOMED_SIZE(Vs->x-x_off); y2 = ZOOMED_SIZE((Vs++)->y-y_off); x3 = ZOOMED_SIZE(Vs->x-x_off); y3 = ZOOMED_SIZE(Vs->y-y_off); MidPoint(x0, y0, x1, y1, &mx1, &my1); MidPoint(x1, y1, x2, y2, &mx2, &my2); MidPoint(x2, y2, x3, y3, &mx3, &my3); MidPoint(mx1, my1, mx2, my2, &mx12, &my12); MidPoint(mx2, my2, mx3, my3, &mx23, &my23); MidPoint(mx12, my12, mx23, my23, &mx4, &my4); max_n = 100; splineVs = (XPoint *)malloc((max_n+1)*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); *N = 0; tighterStructSplines = saved_tighter_splines; return splineVs; } memset(splineVs, 0, (max_n+1)*sizeof(XPoint)); splineVs[0].x = x0; splineVs[0].y = y0; *N = 1; SetSplineVs(N, &max_n, x0, y0, mx1, my1, mx12, my12, mx4, my4); SetSplineVs(N, &max_n, mx4, my4, mx23, my23, mx3, my3, x3, y3); } else { mx1 = ZOOMED_SIZE(Vs->x-x_off); my1 = ZOOMED_SIZE((Vs++)->y-y_off); x1 = ZOOMED_SIZE(Vs->x-x_off); y1 = ZOOMED_SIZE((Vs++)->y-y_off); x2 = ZOOMED_SIZE(Vs->x-x_off); y2 = ZOOMED_SIZE((Vs++)->y-y_off); mx2 = (mx1+x1)/2.0; my2 = (my1+y1)/2.0; mx3 = (3.0*x1+x2)/4.0; my3 = (3.0*y1+y2)/4.0; mx4 = (x1+x2)/2.0; my4 = (y1+y2)/2.0; max_n = 100; splineVs = (XPoint *)malloc((max_n+1)*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); *N = 0; tighterStructSplines = saved_tighter_splines; return splineVs; } memset(splineVs, 0, (max_n+1)*sizeof(XPoint)); splineVs[0].x = mx1; splineVs[0].y = my1; *N = 1; SetSplineVs(N, &max_n, mx1, my1, mx2, my2, mx3, my3, mx4, my4); for (i=2; i < NumVs-2; i++, Vs++) { mx1 = mx4; my1 = my4; mx2 = (x1 + 3.0*x2) / 4.0; my2 = (y1 + 3.0*y2) / 4.0; x1 = x2; y1 = y2; x2 = ZOOMED_SIZE(Vs->x-x_off); y2 = ZOOMED_SIZE(Vs->y-y_off); mx3 = (3.0*x1 + x2) / 4.0; my3 = (3.0*y1 + y2) / 4.0; mx4 = (x1 + x2) / 2.0; my4 = (y1 + y2) / 2.0; SetSplineVs(N, &max_n, mx1, my1, mx2, my2, mx3, my3, mx4, my4); } mx1 = mx4; my1 = my4; mx2 = (x1 + 3.0*x2) / 4.0; my2 = (y1 + 3.0*y2) / 4.0; x1 = x2; y1 = y2; mx4 = ZOOMED_SIZE(Vs->x-x_off); my4 = ZOOMED_SIZE(Vs->y-y_off); mx3 = (x1 + mx4) / 2.0; my3 = (y1 + my4) / 2.0; SetSplineVs(N, &max_n, mx1, my1, mx2, my2, mx3, my3, mx4, my4); } break; } tighterStructSplines = saved_tighter_splines; return splineVs; } typedef struct MultiSplineRec { XPoint *vlist; int n; } *MultiSplineRecPtr; XPoint *MakeMultiSplinePolyVertex(Curved, N, Smooth, XOff, YOff, NumVs, Vs) int *N, XOff, YOff, NumVs; char *Smooth; IntPoint *Vs; { register int i, j; int segments=1, has_smooth_point=FALSE, start_index, seg_index; int total=0; XPoint *xpptr=NULL; struct MultiSplineRec *msptr=NULL; if (Smooth == NULL) { return MakeSplinePolyVertex(0, Curved, N, XOff, YOff, NumVs, Vs); } if (Smooth[0] || Smooth[NumVs-1]) { FatalUnexpectedError( TgLoadCachedString(CSTID_CORRUPTED_POLY_MKMULTISPLINE), TgLoadCachedString(CSTID_FIX_ATTEMPTED)); Smooth[0] = Smooth[NumVs-1] = FALSE; } for (i=1; i < NumVs-1; i++) { if (Smooth[i]) { has_smooth_point = TRUE; } else { segments++; } } if (!has_smooth_point) { *N = NumVs; return MakePolyVertex(XOff, YOff, NumVs, Vs); } if (segments == 1) { return MakeSplinePolyVertex(0, Curved, N, XOff, YOff, NumVs, Vs); } msptr = (struct MultiSplineRec *)malloc(segments * sizeof(struct MultiSplineRec)); if (msptr == NULL) { FailAllocMessage(); return NULL; } memset(msptr, 0, segments*sizeof(struct MultiSplineRec)); start_index = 0; seg_index = 0; for (i=1; i <= NumVs-1; i++) { if (!Smooth[i]) { msptr[seg_index].vlist = MakeSplinePolyVertex(0, Curved, &msptr[seg_index].n, XOff, YOff, i-start_index+1, &Vs[start_index]); total += msptr[seg_index].n-1; seg_index++; start_index = i; } } if (total > 0) total++; splineVs = (XPoint *)malloc((total+2)*sizeof(XPoint)); if (splineVs == NULL) FailAllocMessage(); memset(splineVs, 0, (total+2)*sizeof(XPoint)); xpptr = splineVs; for (i=0; i < segments; i++) { if (msptr[i].vlist != NULL) { for (j=0; j < msptr[i].n; j++) { xpptr->x = msptr[i].vlist[j].x; xpptr->y = msptr[i].vlist[j].y; xpptr++; } xpptr--; free(msptr[i].vlist); } } free(msptr); *N = total; return splineVs; } XPoint *MakeSplinePolygonVertex(Level, Curved, N, XOff, YOff, NumVs, Vs) int Level, Curved, *N, XOff, YOff, NumVs; IntPoint *Vs; { double mx1, my1, mx2, my2, mx3, my3, mx4, my4, x1, y1, x2, y2; int i, x_off, y_off, max_n, saved_tighter_splines=tighterStructSplines; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(Curved != LT_STRUCT_SPLINE, "Curved == LT_STRUCT_SPLINE in MakeSplinePolygonVertex()", NULL); #endif /* _TGIF_DBG */ if (Level == 0 && Curved != LT_STRUCT_SPLINE && saved_tighter_splines) { tighterStructSplines = FALSE; } x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); splineVs = NULL; if (NumVs <= 3) { splineVs = (XPoint *)malloc(5*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); *N = 0; tighterStructSplines = saved_tighter_splines; return splineVs; } memset(splineVs, 0, 5*sizeof(XPoint)); splineVs[0].x = ZOOMED_SIZE(Vs[0].x-x_off); splineVs[0].y = ZOOMED_SIZE(Vs[0].y-y_off); splineVs[1].x = ZOOMED_SIZE(Vs[1].x-x_off); splineVs[1].y = ZOOMED_SIZE(Vs[1].y-y_off); *N = 2; tighterStructSplines = saved_tighter_splines; return splineVs; } Vs[NumVs].x = Vs[1].x; Vs[NumVs].y = Vs[1].y; x1 = ZOOMED_SIZE(Vs->x-x_off); y1 = ZOOMED_SIZE((Vs++)->y-y_off); x2 = ZOOMED_SIZE(Vs->x-x_off); y2 = ZOOMED_SIZE((Vs++)->y-y_off); mx4 = (x1 + x2) / 2.0; my4 = (y1 + y2) / 2.0; max_n = 100; splineVs = (XPoint*)malloc((max_n+1)*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); *N = 0; tighterStructSplines = saved_tighter_splines; return splineVs; } memset(splineVs, 0, (max_n+1)*sizeof(XPoint)); splineVs[0].x = mx4; splineVs[0].y = my4; *N = 1; for (i=1; i < NumVs; i++, Vs++) { mx1 = mx4; my1 = my4; mx2 = (x1+3.0*x2)/4.0; my2 = (y1+3.0*y2)/4.0; x1 = x2; y1 = y2; x2 = ZOOMED_SIZE(Vs->x-x_off); y2 = ZOOMED_SIZE(Vs->y-y_off); mx3 = (3.0*x1+x2)/4.0; my3 = (3.0*y1+y2)/4.0; mx4 = (x1+x2)/2.0; my4 = (y1+y2)/2.0; SetSplineVs(N, &max_n, mx1, my1, mx2, my2, mx3, my3, mx4, my4); } tighterStructSplines = saved_tighter_splines; return splineVs; } static XPoint *DoMakeDoubleIntSplinePolygonVertex(N, XOff, YOff, NumVs, Vs) int *N, XOff, YOff, NumVs; DoublePoint *Vs; { double mx1, my1, mx2, my2, mx3, my3, mx4, my4, x1, y1, x2, y2, x, y; double dx_off, dy_off; int i, max_n, x_off, y_off; x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); dx_off = (double)x_off; dy_off = (double)y_off; splineVs = NULL; if (NumVs <= 3) { splineVs = (XPoint *)malloc(5*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); *N = 0; return splineVs; } memset(splineVs, 0, 5*sizeof(XPoint)); x = ZOOMED_DOUBLE_SIZE(Vs[0].x-dx_off); y = ZOOMED_DOUBLE_SIZE(Vs[0].y-dy_off); splineVs[0].x = round(x); splineVs[0].y = round(y); x = ZOOMED_DOUBLE_SIZE(Vs[1].x-dx_off); y = ZOOMED_DOUBLE_SIZE(Vs[1].y-dy_off); splineVs[1].x = round(x); splineVs[1].y = round(y); *N = 2; return splineVs; } Vs[NumVs].x = Vs[1].x; Vs[NumVs].y = Vs[1].y; x1 = ZOOMED_DOUBLE_SIZE(Vs->x-dx_off); y1 = ZOOMED_DOUBLE_SIZE((Vs++)->y-dy_off); x2 = ZOOMED_DOUBLE_SIZE(Vs->x-dx_off); y2 = ZOOMED_DOUBLE_SIZE((Vs++)->y-dy_off); mx4 = (x1 + x2) / 2.0; my4 = (y1 + y2) / 2.0; max_n = 100; splineDoubleVs = (DoublePoint*)malloc((max_n+1)*sizeof(DoublePoint)); if (splineDoubleVs == NULL) { FailAllocMessage(); *N = 0; return NULL; } memset(splineDoubleVs, 0, (max_n+1)*sizeof(DoublePoint)); splineDoubleVs[0].x = mx4; splineDoubleVs[0].y = my4; *N = 1; for (i=1; i < NumVs; i++, Vs++) { mx1 = mx4; my1 = my4; mx2 = (x1+3.0*x2)/4.0; my2 = (y1+3.0*y2)/4.0; x1 = x2; y1 = y2; x2 = ZOOMED_DOUBLE_SIZE(Vs->x-dx_off); y2 = ZOOMED_DOUBLE_SIZE(Vs->y-dy_off); mx3 = (3.0*x1+x2)/4.0; my3 = (3.0*y1+y2)/4.0; mx4 = (x1+x2)/2.0; my4 = (y1+y2)/2.0; SetDoubleSplineVs(N, &max_n, mx1, my1, mx2, my2, mx3, my3, mx4, my4); } splineVs = (XPoint*)malloc(((*N)+2)*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); free(splineDoubleVs); splineDoubleVs = NULL; *N = 0; return NULL; } memset(splineVs, 0, ((*N)+2)*sizeof(XPoint)); for (i=0; i < *N; i++) { splineVs[i].x = round(splineDoubleVs[i].x); splineVs[i].y = round(splineDoubleVs[i].y); } free(splineDoubleVs); splineDoubleVs = NULL; return splineVs; } XPoint *MakeMultiSplinePolygonVertex(Curved, N, Smooth, XOff, YOff, NumVs, Vs) int Curved, *N, XOff, YOff, NumVs; char *Smooth; IntPoint *Vs; { register int i, j; int num_smooth_points=0, num_hinge_points=0; int start_index, seg_index, tmp_index; int total=0, once_around=FALSE; XPoint *xpptr=NULL; IntPoint *tmp_vs=NULL; struct MultiSplineRec *msptr=NULL; if (Smooth == NULL) { return MakeSplinePolygonVertex(0, Curved, N, XOff, YOff, NumVs, Vs); } for (i=1; i < NumVs; i++) { if (Smooth[i]) { num_smooth_points++; } else { num_hinge_points++; } } if (num_smooth_points == 0) { *N = NumVs; return MakePolygonVertex(XOff, YOff, NumVs, Vs); } if (num_hinge_points == 0) { return MakeSplinePolygonVertex(0, Curved, N, XOff, YOff, NumVs, Vs); } msptr = (struct MultiSplineRec *)malloc(num_hinge_points * sizeof(struct MultiSplineRec)); if (msptr == NULL) FailAllocMessage(); memset(msptr, 0, num_hinge_points*sizeof(struct MultiSplineRec)); for (i=0; i < NumVs; i++) { if (!Smooth[i]) { break; } } tmp_vs = (IntPoint*)malloc((NumVs+1)*sizeof(IntPoint)); if (tmp_vs == NULL) FailAllocMessage(); memset(tmp_vs, 0, (NumVs+1)*sizeof(IntPoint)); start_index = i; seg_index = 0; tmp_vs[0].x = Vs[start_index].x; tmp_vs[0].y = Vs[start_index].y; tmp_index = 1; for (i=start_index+1; !(once_around && i==start_index+1); i++, tmp_index++) { tmp_vs[tmp_index].x = Vs[i].x; tmp_vs[tmp_index].y = Vs[i].y; if (!Smooth[i]) { msptr[seg_index].vlist = MakeSplinePolyVertex(0, Curved, &msptr[seg_index].n, XOff, YOff, tmp_index+1, tmp_vs); total += msptr[seg_index].n-1; seg_index++; start_index = (i==NumVs-1 ? 0 : i); tmp_vs[0].x = Vs[start_index].x; tmp_vs[0].y = Vs[start_index].y; tmp_index = 0; } if (i == NumVs-1) { i = 0; once_around = TRUE; } } if (tmp_vs != NULL) free(tmp_vs); if (total > 0) total++; splineVs = (XPoint*)malloc((total+2)*sizeof(XPoint)); if (splineVs == NULL) FailAllocMessage(); memset(splineVs, 0, (total+2)*sizeof(XPoint)); xpptr = splineVs; for (i=0; i < num_hinge_points; i++) { if (msptr[i].vlist != NULL) { for (j=0; j < msptr[i].n; j++) { xpptr->x = msptr[i].vlist[j].x; xpptr->y = msptr[i].vlist[j].y; xpptr++; } xpptr--; free(msptr[i].vlist); } } free(msptr); *N = total; return splineVs; } struct MtxRec { double *x, *y, *dx, *dy; double **mtx; } mtxInfo; static void OpenSetupMatrix(NumPts, Vs) int NumPts; IntPoint *Vs; { register int i; mtxInfo.x = (double*)malloc(NumPts*sizeof(double)); mtxInfo.y = (double*)malloc(NumPts*sizeof(double)); mtxInfo.dx = (double*)malloc(NumPts*sizeof(double)); mtxInfo.dy = (double*)malloc(NumPts*sizeof(double)); if (mtxInfo.x == NULL || mtxInfo.y == NULL || mtxInfo.dx == NULL || mtxInfo.dy == NULL) { FailAllocMessage(); } for (i=0; i < NumPts; i++) { mtxInfo.x[i] = mtxInfo.dx[i] = ((double)(Vs[i].x))*((double)theSum); mtxInfo.y[i] = mtxInfo.dy[i] = ((double)(Vs[i].y))*((double)theSum); } mtxInfo.mtx = (double**)malloc(NumPts*sizeof(double*)); if (mtxInfo.mtx == NULL) FailAllocMessage(); memset(mtxInfo.mtx, 0, NumPts*sizeof(double*)); for (i=0; i < NumPts; i++) { mtxInfo.mtx[i] = (double*)malloc(3*sizeof(double)); if (mtxInfo.mtx[i] == NULL) FailAllocMessage(); memset(mtxInfo.mtx[i], 0, 3*sizeof(double)); } mtxInfo.mtx[0][0] = mtxInfo.mtx[NumPts-1][2] = (double)0.0; mtxInfo.mtx[0][1] = mtxInfo.mtx[NumPts-1][1] = (double)theSum; mtxInfo.mtx[0][2] = mtxInfo.mtx[NumPts-1][0] = (double)0.0; for (i=1; i < NumPts-1; i++) { mtxInfo.mtx[i][0] = (double)1.0; mtxInfo.mtx[i][1] = (double)SUM_MINUS_2; mtxInfo.mtx[i][2] = (double)1.0; } } static void TriGaussian(NumPts) int NumPts; { register int i; register double val; for (i=1; i<NumPts-1; i++) { val = (-mtxInfo.mtx[i-1][1]); mtxInfo.mtx[i][0] = (double)0.0; mtxInfo.mtx[i][1] = (mtxInfo.mtx[i][1]*val+mtxInfo.mtx[i-1][2])/theSum; mtxInfo.mtx[i][2] = val/theSum; mtxInfo.x[i] = (mtxInfo.x[i]*val+mtxInfo.x[i-1])/theSum; mtxInfo.y[i] = (mtxInfo.y[i]*val+mtxInfo.y[i-1])/theSum; } mtxInfo.x[i] = mtxInfo.x[i]/mtxInfo.mtx[i][1]; mtxInfo.y[i] = mtxInfo.y[i]/mtxInfo.mtx[i][1]; for (i--; i>=0; i--) { mtxInfo.x[i] = (mtxInfo.x[i]-mtxInfo.x[i+1]*mtxInfo.mtx[i][2]) / mtxInfo.mtx[i][1]; mtxInfo.y[i] = (mtxInfo.y[i]-mtxInfo.y[i+1]*mtxInfo.mtx[i][2]) / mtxInfo.mtx[i][1]; } } static void FreeMtxInfo(NumPts) int NumPts; { register int i; if (mtxInfo.x != NULL) free(mtxInfo.x); if (mtxInfo.y != NULL) free(mtxInfo.y); if (mtxInfo.dx != NULL) free(mtxInfo.dx); if (mtxInfo.dy != NULL) free(mtxInfo.dy); if (mtxInfo.mtx != NULL) { for (i=0; i < NumPts; i++) { if (mtxInfo.mtx[i] != NULL) free(mtxInfo.mtx[i]); } free(mtxInfo.mtx); } memset(&mtxInfo, 0, sizeof(struct MtxRec)); } static IntPoint *OpenControlPts(NumPts, N) int NumPts, *N; { register int i; int index=0; double half=theSum/((double)2.0); double weight=half-((double)1.0); IntPoint *v; v = (IntPoint*)malloc((((NumPts-2)<<1)+2)*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); memset(v, 0, (((NumPts-2)<<1)+2)*sizeof(IntPoint)); v[index].x = (int)(mtxInfo.x[0]); v[index].y = (int)(mtxInfo.y[0]); index++; v[index].x = (int)((mtxInfo.x[0]+weight*mtxInfo.x[1])/half); v[index].y = (int)((mtxInfo.y[0]+weight*mtxInfo.y[1])/half); index++; for (i=1; i<NumPts-2; i++) { v[index].x = (int)((weight*mtxInfo.x[i]+mtxInfo.x[i+1])/half); v[index].y = (int)((weight*mtxInfo.y[i]+mtxInfo.y[i+1])/half); index++; v[index].x = (int)((mtxInfo.x[i]+weight*mtxInfo.x[i+1])/half); v[index].y = (int)((mtxInfo.y[i]+weight*mtxInfo.y[i+1])/half); index++; } v[index].x = (int)((weight*mtxInfo.x[i]+mtxInfo.x[i+1])/half); v[index].y = (int)((weight*mtxInfo.y[i]+mtxInfo.y[i+1])/half); index++; v[index].x = (int)(mtxInfo.x[NumPts-1]); v[index].y = (int)(mtxInfo.y[NumPts-1]); index++; FreeMtxInfo(NumPts); *N = index; return v; } XPoint *MakeIntSplinePolyVertex(N, CntrlN, CntrlVs, XOff, YOff, NumVs, Vs) int *N, *CntrlN, XOff, YOff, NumVs; IntPoint **CntrlVs, *Vs; { int x_off, y_off; x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); splineVs = NULL; switch (NumVs) { case 0: case 1: break; case 2: *CntrlVs = (IntPoint*)malloc((NumVs+1)*sizeof(IntPoint)); if (*CntrlVs == NULL) FailAllocMessage(); memset(*CntrlVs, 0, (NumVs+1)*sizeof(IntPoint)); splineVs = (XPoint*)malloc((NumVs+1)*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); *N = 0; return splineVs; } memset(splineVs, 0, (NumVs+1)*sizeof(XPoint)); splineVs[0].x = ZOOMED_SIZE(Vs[0].x-x_off); splineVs[0].y = ZOOMED_SIZE(Vs[0].y-y_off); splineVs[1].x = ZOOMED_SIZE(Vs[1].x-x_off); splineVs[1].y = ZOOMED_SIZE(Vs[1].y-y_off); (*CntrlVs)[0].x = Vs[0].x; (*CntrlVs)[0].y = Vs[0].y; (*CntrlVs)[1].x = Vs[1].x; (*CntrlVs)[1].y = Vs[1].y; *N = *CntrlN = 2; break; default: OpenSetupMatrix(NumVs, Vs); TriGaussian(NumVs); *CntrlVs = OpenControlPts(NumVs, CntrlN); return MakeSplinePolyVertex(0, LT_INTSPLINE, N, XOff, YOff, *CntrlN, *CntrlVs); } return splineVs; } static void ClosedSetupMatrix(NumPts, Vs) int NumPts; IntPoint *Vs; { register int i; register double val; mtxInfo.x = (double*)malloc(NumPts*sizeof(double)); mtxInfo.y = (double*)malloc(NumPts*sizeof(double)); mtxInfo.dx = (double*)malloc(NumPts*sizeof(double)); mtxInfo.dy = (double*)malloc(NumPts*sizeof(double)); if (mtxInfo.x == NULL || mtxInfo.y == NULL || mtxInfo.dx == NULL || mtxInfo.dy == NULL) { FailAllocMessage(); } for (i=0; i < NumPts; i++) { mtxInfo.x[i] = mtxInfo.dx[i] = ((double)(Vs[i].x))*((double)theSum); mtxInfo.y[i] = mtxInfo.dy[i] = ((double)(Vs[i].y))*((double)theSum); } /* the first NumPts-2 rows have an extra column */ mtxInfo.mtx = (double**)malloc(NumPts*sizeof(double*)); if (mtxInfo.mtx == NULL) FailAllocMessage(); memset(mtxInfo.mtx, 0, NumPts*sizeof(double*)); for (i=0; i < NumPts; i++) { mtxInfo.mtx[i] = (double*)malloc(4*sizeof(double)); if (mtxInfo.mtx[i] == NULL) FailAllocMessage(); memset(mtxInfo.mtx[i], 0, 4*sizeof(double)); } mtxInfo.mtx[0][0] = mtxInfo.mtx[NumPts-1][2] = (double)1.0; mtxInfo.mtx[0][1] = mtxInfo.mtx[NumPts-1][1] = (double)SUM_MINUS_2; mtxInfo.mtx[0][2] = mtxInfo.mtx[NumPts-1][0] = (double)1.0; mtxInfo.mtx[0][3] = (double)1.0; /* use mtx[NumPts-1][3] as mtx[NumPts-1][i] where i is moving to right */ mtxInfo.mtx[NumPts-1][3] = (double)0.0; for (i=1; i < NumPts-1; i++) { mtxInfo.mtx[i][0] = (double)1.0; mtxInfo.mtx[i][1] = (double)SUM_MINUS_2; mtxInfo.mtx[i][2] = (double)1.0; mtxInfo.mtx[i][3] = (double)0.0; } val = (-mtxInfo.mtx[0][1]); if (NumPts == 3) { mtxInfo.mtx[NumPts-1][0] = (mtxInfo.mtx[NumPts-1][0]*val+mtxInfo.mtx[0][2])/theSum; } else { mtxInfo.mtx[NumPts-1][0] = mtxInfo.mtx[NumPts-1][0]*val/theSum; } mtxInfo.mtx[NumPts-1][1] = (mtxInfo.mtx[NumPts-1][1]*val+mtxInfo.mtx[0][3])/theSum; /* use mtx[NumPts-1][3] as mtx[NumPts-1][i] where i moves to right */ mtxInfo.mtx[NumPts-1][3] = mtxInfo.mtx[0][2]/theSum; mtxInfo.x[NumPts-1] = (mtxInfo.x[NumPts-1]*val+mtxInfo.x[0])/theSum; mtxInfo.y[NumPts-1] = (mtxInfo.y[NumPts-1]*val+mtxInfo.y[0])/theSum; } static void DoubleClosedSetupMatrix(NumPts, Vs) int NumPts; DoublePoint *Vs; { register int i; register double val; mtxInfo.x = (double*)malloc(NumPts*sizeof(double)); mtxInfo.y = (double*)malloc(NumPts*sizeof(double)); mtxInfo.dx = (double*)malloc(NumPts*sizeof(double)); mtxInfo.dy = (double*)malloc(NumPts*sizeof(double)); if (mtxInfo.x == NULL || mtxInfo.y == NULL || mtxInfo.dx == NULL || mtxInfo.dy == NULL) { FailAllocMessage(); } for (i=0; i < NumPts; i++) { mtxInfo.x[i] = mtxInfo.dx[i] = ((double)(Vs[i].x))*((double)theSum); mtxInfo.y[i] = mtxInfo.dy[i] = ((double)(Vs[i].y))*((double)theSum); } /* the first NumPts-2 rows have an extra column */ mtxInfo.mtx = (double**)malloc(NumPts*sizeof(double*)); if (mtxInfo.mtx == NULL) FailAllocMessage(); memset(mtxInfo.mtx, 0, NumPts*sizeof(double*)); for (i=0; i < NumPts; i++) { mtxInfo.mtx[i] = (double*)malloc(4*sizeof(double)); if (mtxInfo.mtx[i] == NULL) FailAllocMessage(); memset(mtxInfo.mtx[i], 0, 4*sizeof(double)); } mtxInfo.mtx[0][0] = mtxInfo.mtx[NumPts-1][2] = (double)1.0; mtxInfo.mtx[0][1] = mtxInfo.mtx[NumPts-1][1] = (double)SUM_MINUS_2; mtxInfo.mtx[0][2] = mtxInfo.mtx[NumPts-1][0] = (double)1.0; mtxInfo.mtx[0][3] = (double)1.0; /* use mtx[NumPts-1][3] as mtx[NumPts-1][i] where i is moving to right */ mtxInfo.mtx[NumPts-1][3] = (double)0.0; for (i=1; i < NumPts-1; i++) { mtxInfo.mtx[i][0] = (double)1.0; mtxInfo.mtx[i][1] = (double)SUM_MINUS_2; mtxInfo.mtx[i][2] = (double)1.0; mtxInfo.mtx[i][3] = (double)0.0; } val = (-mtxInfo.mtx[0][1]); if (NumPts == 3) { mtxInfo.mtx[NumPts-1][0] = (mtxInfo.mtx[NumPts-1][0]*val+mtxInfo.mtx[0][2])/theSum; } else { mtxInfo.mtx[NumPts-1][0] = mtxInfo.mtx[NumPts-1][0]*val/theSum; } mtxInfo.mtx[NumPts-1][1] = (mtxInfo.mtx[NumPts-1][1]*val+mtxInfo.mtx[0][3])/theSum; /* use mtx[NumPts-1][3] as mtx[NumPts-1][i] where i moves to right */ mtxInfo.mtx[NumPts-1][3] = mtxInfo.mtx[0][2]/theSum; mtxInfo.x[NumPts-1] = (mtxInfo.x[NumPts-1]*val+mtxInfo.x[0])/theSum; mtxInfo.y[NumPts-1] = (mtxInfo.y[NumPts-1]*val+mtxInfo.y[0])/theSum; } static int gaussIteration=0; #ifdef NOT_DEFINED #ifdef _TGIF_DBG static void DebugClosedMatrix(NumPts) int NumPts; { int j, i; /* mtxInfo.mtx[0][3] is actually mtxInfo.mtx[0][NumPts-1] */ /* mtxInfo.mtx[NumPts-1][3] is actually mtxInfo.mtx[NumPts-1][i+1] */ /* where i is the current iteration in gaussian elimincation; */ /* before gaussian() is called, i is 0 */ printf("| %+8.2f %+8.2f ", mtxInfo.mtx[0][1], mtxInfo.mtx[0][2]); for (j=2; j<NumPts-1; j++) printf(" "); printf("%+8.2f | (%+8.2f,%+8.2f)\n", mtxInfo.mtx[0][3], mtxInfo.x[0], mtxInfo.y[0]); for (i=1; i<NumPts-1; i++) { if (i == NumPts-2) { printf("| "); for (j=1; j<i; j++) printf(" "); printf("%+8.2f %+8.2f %+8.2f ", mtxInfo.mtx[i][0], mtxInfo.mtx[i][1], mtxInfo.mtx[i][2]); for (j=i+2; j<NumPts; j++) printf(" "); printf("| (%+8.2f,%+8.2f)\n", mtxInfo.x[i], mtxInfo.y[i]); } else { printf("| "); for (j=1; j<i; j++) printf(" "); printf("%+8.2f %+8.2f %+8.2f ", mtxInfo.mtx[i][0], mtxInfo.mtx[i][1], mtxInfo.mtx[i][2]); for (j=i+2; j<NumPts-1; j++) printf(" "); printf("%+8.2f | (%+8.2f,%+8.2f)\n", mtxInfo.mtx[i][3], mtxInfo.x[i], mtxInfo.y[i]); } } printf("| "); if (gaussIteration+2 < i) { for (j=1; j<gaussIteration+2; j++) printf(" "); printf("%+8.2f ", mtxInfo.mtx[i][3]); for (j=gaussIteration+3; j<i; j++) printf(" "); } else { for (j=1; j<i; j++) printf(" "); } printf("%+8.2f %+8.2f ", mtxInfo.mtx[i][0], mtxInfo.mtx[i][1]); printf("| (%+8.2f,%+8.2f)\n", mtxInfo.x[i], mtxInfo.y[i]); } #endif /* _TGIF_DBG */ #endif /* NOT_DEFINED */ static void Gaussian(NumPts) int NumPts; { register int i; register double val; gaussIteration = 0; #ifdef _TGIF_DBG /* DebugClosedMatrix(NumPts); */ #endif /* _TGIF_DBG */ for (i=1; i<NumPts-1; i++) { val = (-mtxInfo.mtx[i-1][1]); mtxInfo.mtx[i][0] = (double)0.0; mtxInfo.mtx[i][1] = (mtxInfo.mtx[i][1]*val+mtxInfo.mtx[i-1][2])/theSum; if (i == NumPts-2) { mtxInfo.mtx[i][2] = (mtxInfo.mtx[i][2]*val+mtxInfo.mtx[i-1][3])/theSum; } else { mtxInfo.mtx[i][2] = val/theSum; } mtxInfo.x[i] = (mtxInfo.x[i]*val+mtxInfo.x[i-1])/theSum; mtxInfo.y[i] = (mtxInfo.y[i]*val+mtxInfo.y[i-1])/theSum; if (i != NumPts-2) { mtxInfo.mtx[i][3] = mtxInfo.mtx[i-1][3]/theSum;; } val = (-mtxInfo.mtx[i][1])/mtxInfo.mtx[NumPts-1][3]; if (i < NumPts-2) { if (i < NumPts-3) { mtxInfo.mtx[NumPts-1][0] = mtxInfo.mtx[NumPts-1][0]*val/theSum; } else { mtxInfo.mtx[NumPts-1][0] = (mtxInfo.mtx[NumPts-1][0]*val+mtxInfo.mtx[i][2])/theSum; } mtxInfo.mtx[NumPts-1][1] = (mtxInfo.mtx[NumPts-1][1]*val+mtxInfo.mtx[i][3])/theSum; mtxInfo.mtx[NumPts-1][3] = mtxInfo.mtx[i][2]/theSum; mtxInfo.x[NumPts-1] = (mtxInfo.x[NumPts-1]*val+mtxInfo.x[i])/theSum; mtxInfo.y[NumPts-1] = (mtxInfo.y[NumPts-1]*val+mtxInfo.y[i])/theSum; } gaussIteration++; #ifdef _TGIF_DBG /* DebugClosedMatrix(NumPts); */ #endif /* _TGIF_DBG */ } val = (-mtxInfo.mtx[i-1][1])/mtxInfo.mtx[i][0]; mtxInfo.mtx[i][0] = (double)0.0; mtxInfo.mtx[i][1] = (mtxInfo.mtx[i][1]*val+mtxInfo.mtx[i-1][2])/theSum; mtxInfo.x[i] = (mtxInfo.x[i]*val+mtxInfo.x[i-1])/theSum; mtxInfo.y[i] = (mtxInfo.y[i]*val+mtxInfo.y[i-1])/theSum; mtxInfo.x[i] = mtxInfo.x[i]/mtxInfo.mtx[i][1]; mtxInfo.y[i] = mtxInfo.y[i]/mtxInfo.mtx[i][1]; for (i--; i>=0; i--) { if (i == NumPts-2) { mtxInfo.x[i] = (mtxInfo.x[i]-mtxInfo.x[i+1]*mtxInfo.mtx[i][2]) / mtxInfo.mtx[i][1]; mtxInfo.y[i] = (mtxInfo.y[i]-mtxInfo.y[i+1]*mtxInfo.mtx[i][2]) / mtxInfo.mtx[i][1]; } else { mtxInfo.x[i] = (mtxInfo.x[i]-mtxInfo.x[i+1]*mtxInfo.mtx[i][2] - mtxInfo.x[NumPts-1]*mtxInfo.mtx[i][3])/mtxInfo.mtx[i][1]; mtxInfo.y[i] = (mtxInfo.y[i]-mtxInfo.y[i+1]*mtxInfo.mtx[i][2] - mtxInfo.y[NumPts-1]*mtxInfo.mtx[i][3])/mtxInfo.mtx[i][1]; } } #ifdef _TGIF_DBG /* DebugClosedMatrix(NumPts); */ #endif /* _TGIF_DBG */ } static IntPoint *ClosedControlPts(NumPts, N) int NumPts, *N; { register int i; int index=0; double half=theSum/((double)2.0); double weight=half-((double)1.0); IntPoint *v; v = (IntPoint*)malloc(((NumPts<<1)+2)*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); memset(v, 0, ((NumPts<<1)+2)*sizeof(IntPoint)); for (i=0; i<NumPts; i++) { v[index].x = (int)((weight*mtxInfo.x[i]+mtxInfo.x[(i+1) % NumPts])/half); v[index].y = (int)((weight*mtxInfo.y[i]+mtxInfo.y[(i+1) % NumPts])/half); index++; v[index].x = (int)((mtxInfo.x[i]+weight*mtxInfo.x[(i+1) % NumPts])/half); v[index].y = (int)((mtxInfo.y[i]+weight*mtxInfo.y[(i+1) % NumPts])/half); index++; } v[index].x = (int)((weight*mtxInfo.x[0]+mtxInfo.x[1])/half); v[index].y = (int)((weight*mtxInfo.y[0]+mtxInfo.y[1])/half); index++; FreeMtxInfo(NumPts); *N = index; return v; } static DoublePoint *DoubleClosedControlPts(NumPts, N) int NumPts, *N; { register int i; int index=0; double half=theSum/((double)2.0); double weight=half-((double)1.0); DoublePoint *v; v = (DoublePoint*)malloc(((NumPts<<1)+2)*sizeof(DoublePoint)); if (v == NULL) FailAllocMessage(); memset(v, 0, ((NumPts<<1)+2)*sizeof(DoublePoint)); for (i=0; i<NumPts; i++) { v[index].x = ((weight*mtxInfo.x[i]+mtxInfo.x[(i+1) % NumPts])/half); v[index].y = ((weight*mtxInfo.y[i]+mtxInfo.y[(i+1) % NumPts])/half); index++; v[index].x = ((mtxInfo.x[i]+weight*mtxInfo.x[(i+1) % NumPts])/half); v[index].y = ((mtxInfo.y[i]+weight*mtxInfo.y[(i+1) % NumPts])/half); index++; } v[index].x = ((weight*mtxInfo.x[0]+mtxInfo.x[1])/half); v[index].y = ((weight*mtxInfo.y[0]+mtxInfo.y[1])/half); index++; FreeMtxInfo(NumPts); *N = index; return v; } XPoint *MakeIntSplinePolygonVertex(N, CntrlN, CntrlVs, XOff, YOff, NumVs, Vs) int *N, *CntrlN, XOff, YOff, NumVs; IntPoint **CntrlVs, *Vs; { int x_off, y_off; x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); splineVs = NULL; if (NumVs <= 3) { splineVs = (XPoint *)malloc(5*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); *N = 0; return (splineVs); } memset(splineVs, 0, 5*sizeof(XPoint)); splineVs[0].x = ZOOMED_SIZE(Vs[0].x-x_off); splineVs[0].y = ZOOMED_SIZE(Vs[0].y-y_off); splineVs[1].x = ZOOMED_SIZE(Vs[1].x-x_off); splineVs[1].y = ZOOMED_SIZE(Vs[1].y-y_off); *N = *CntrlN = 2; return splineVs; } gaussIteration = 0; NumVs--; /* drop the duplicated end point */ ClosedSetupMatrix(NumVs, Vs); Gaussian(NumVs); *CntrlVs = ClosedControlPts(NumVs, CntrlN); return MakeSplinePolygonVertex(0, LT_INTSPLINE, N, XOff, YOff, *CntrlN, *CntrlVs); } XPoint *MakeDoubleIntSplinePolygonVertex(N, CntrlN, CntrlVs, XOff, YOff, NumVs, Vs) int *N, *CntrlN, XOff, YOff, NumVs; DoublePoint **CntrlVs, *Vs; { int x_off=0, y_off=0; int saved_tighter_splines=tighterStructSplines; XPoint *pxp=NULL; x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); splineVs = NULL; if (NumVs <= 3) { double x, y; splineVs = (XPoint *)malloc(5*sizeof(XPoint)); if (splineVs == NULL) { FailAllocMessage(); *N = 0; return splineVs; } memset(splineVs, 0, 5*sizeof(XPoint)); x = ZOOMED_DOUBLE_SIZE(Vs[0].x-((double)x_off)); y = ZOOMED_DOUBLE_SIZE(Vs[0].y-((double)y_off)); splineVs[0].x = round(x); splineVs[0].y = round(y); x = ZOOMED_DOUBLE_SIZE(Vs[1].x-((double)x_off)); y = ZOOMED_DOUBLE_SIZE(Vs[1].y-((double)y_off)); splineVs[1].x = round(x); splineVs[1].y = round(y); *N = *CntrlN = 2; return splineVs; } gaussIteration = 0; NumVs--; /* drop the duplicated end point */ DoubleClosedSetupMatrix(NumVs, Vs); Gaussian(NumVs); *CntrlVs = DoubleClosedControlPts(NumVs, CntrlN); if (saved_tighter_splines) { tighterStructSplines = FALSE; } pxp = DoMakeDoubleIntSplinePolygonVertex(N, XOff, YOff, *CntrlN, *CntrlVs); tighterStructSplines = saved_tighter_splines; return pxp; } void DumpCurvedPolyPoints(FP, Curved, NumPts, V, Indent) FILE *FP; int Curved, NumPts, Indent; register IntPoint *V; { register int j, i; double x1, y1, x2, y2; double mx1, my1, mx2, my2, mx3, my3, mx4, my4; int saved_tighter_splines=tighterStructSplines; if (Curved != LT_STRUCT_SPLINE && saved_tighter_splines) { tighterStructSplines = FALSE; } switch (NumPts) { case 0: case 1: case 2: break; case 3: mx1 = V->x; my1 = (V++)->y; x1 = V->x; y1 = (V++)->y; x2 = V->x; y2 = (V++)->y; mx2 = compCurveToFactor*mx1 + curveToFactor*x1; my2 = compCurveToFactor*my1 + curveToFactor*y1; mx3 = curveToFactor*x1 + compCurveToFactor*x2; my3 = curveToFactor*y1 + compCurveToFactor*y2; for (j = 0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%.2f %.2f %.2f %.2f\n", mx2, my2, mx3, my3); break; default: if (tighterStructSplines) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(NumPts <= 4, "NumPts > 4 in DumpCurvedPolyPoints()", NULL); #endif /* _TGIF_DBG */ mx1 = V->x; my1 = (V++)->y; x1 = V->x; y1 = (V++)->y; x2 = V->x; y2 = (V++)->y; mx4 = V->x; my4 = V->y; for (j = 0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%.2f %.2f %.2f %.2f\n", x1, y1, x2, y2); } else { mx1 = V->x; my1 = (V++)->y; x1 = V->x; y1 = (V++)->y; x2 = V->x; y2 = (V++)->y; mx2 = (mx1 + 2.0*x1) / 3.0; my2 = (my1 + 2.0*y1) / 3.0; mx3 = (5.0*x1 + x2) / 6.0; my3 = (5.0*y1 + y2) / 6.0; mx4 = (x1 + x2) / 2.0; my4 = (y1 + y2) / 2.0; for (j = 0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%.2f %.2f %.2f %.2f %.2f %.2f %s\n", mx2, my2, mx3, my3, mx4, my4, gPsCmd[PS_CURVETO]); for (i=2; i < NumPts-2; i++, V++) { mx2 = (x1 + 5.0*x2) / 6.0; my2 = (y1 + 5.0*y2) / 6.0; x1 = x2; y1 = y2; #ifdef stellar mx3 = (5.0*x1 + V->x) / 6.0; my3 = (5.0*y1 + V->y) / 6.0; mx4 = (x1 + V->x) / 2.0; my4 = (y1 + V->y) / 2.0; #else x2 = V->x; y2 = V->y; mx3 = (5.0*x1 + x2) / 6.0; my3 = (5.0*y1 + y2) / 6.0; mx4 = (x1 + x2) / 2.0; my4 = (y1 + y2) / 2.0; #endif for (j = 0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%.2f %.2f %.2f %.2f %.2f %.2f %s\n", mx2, my2, mx3, my3, mx4, my4, gPsCmd[PS_CURVETO]); #ifdef stellar x2 = V->x; y2 = V->y; #endif } mx2 = (x1 + 5.0*x2) / 6.0; my2 = (y1 + 5.0*y2) / 6.0; x1 = x2; y1 = y2; mx3 = (2.0*x1 + V->x) / 3.0; my3 = (2.0*y1 + V->y) / 3.0; for (j = 0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%.2f %.2f %.2f %.2f\n", mx2, my2, mx3, my3); } break; } tighterStructSplines = saved_tighter_splines; } void DumpCurvedPolygonPoints(FP, Curved, NumPts, V, Indent) FILE *FP; int Curved, NumPts, Indent; register IntPoint *V; { register int j; double mx2, my2, mx3, my3, mx4, my4, x1, y1, x2, y2; int i; int saved_tighter_splines=tighterStructSplines; if (Curved != LT_STRUCT_SPLINE && saved_tighter_splines) { tighterStructSplines = FALSE; } V[NumPts].x = V[1].x; V[NumPts].y = V[1].y; x1 = V->x; y1 = (V++)->y; x2 = V->x; y2 = (V++)->y; mx4 = (x1 + x2) / 2.0; my4 = (y1 + y2) / 2.0; for (j = 0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%.2f %.2f %s\n", mx4, my4, gPsCmd[PS_MOVETO]); for (i=1; i < NumPts; i++, V++) { mx2 = (x1+5.0*x2)/6.0; my2 = (y1+5.0*y2)/6.0; x1 = x2; y1 = y2; #ifdef stellar mx3 = (5.0*x1+V->x)/6.0; my3 = (5.0*y1+V->y)/6.0; mx4 = (x1+V->x)/2.0; my4 = (y1+V->y)/2.0; #else x2 = V->x; y2 = V->y; mx3 = (5.0*x1+x2)/6.0; my3 = (5.0*y1+y2)/6.0; mx4 = (x1+x2)/2.0; my4 = (y1+y2)/2.0; #endif for (j = 0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%.2f %.2f %.2f %.2f %.2f %.2f %s\n", mx2, my2, mx3, my3, mx4, my4, gPsCmd[PS_CURVETO]); #ifdef stellar x2 = V->x; y2 = V->y; #endif } tighterStructSplines = saved_tighter_splines; } void DumpMultiCurvedPolyPoints(FP, Smooth, Style, Curved, NumPts, V, Indent) FILE *FP; char *Smooth; int Style, Curved, NumPts, Indent; register IntPoint *V; { register int i, j; int segments=1, has_smooth_point=FALSE, start_index; if (Curved == LT_INTSPLINE || Smooth == NULL) { DumpCurvedPolyPoints(FP, Curved, NumPts, V, Indent); return; } if (Smooth[0] || Smooth[NumPts-1]) { FatalUnexpectedError( TgLoadCachedString(CSTID_CORRUPTED_POLY_DMPMULTICURVE), TgLoadCachedString(CSTID_FIX_ATTEMPTED)); Smooth[0] = Smooth[NumPts-1] = FALSE; } for (i=1; i < NumPts-1; i++) { if (Smooth[i]) { has_smooth_point = TRUE; } else { segments++; } } if (!has_smooth_point) { /* simple polyline */ if (Style & LS_RIGHT) { DumpPoints(FP, NumPts-1, V, Indent); } else { DumpPoints(FP, NumPts, V, Indent); } return; } if (segments == 1) { /* simple spline */ if (Style & LS_RIGHT) { if (NumPts != 2) { DumpCurvedPolyPoints(FP, Curved, NumPts, V, Indent); } else { DumpPoints(FP, NumPts-1, V, Indent); } } else if (NumPts != 2) { DumpCurvedPolyPoints(FP, Curved, NumPts, V, Indent); for (i=0; i < Indent; i++) fprintf(FP, " "); fprintf(FP, "%1d %1d %s\n", V[NumPts-1].x, V[NumPts-1].y, gPsCmd[PS_CURVETO]); } else { DumpPoints(FP, NumPts, V, Indent); } return; } start_index = 0; for (i=1; i <= NumPts-1; i++) { if (!Smooth[i]) { int num_tmp_vs=i-start_index+1; if (num_tmp_vs == 2) { if (!(i == NumPts-1 && (Style & LS_RIGHT))) { DumpPoints(FP, num_tmp_vs, &V[start_index], Indent); } } else { DumpCurvedPolyPoints(FP, Curved, num_tmp_vs, &V[start_index], Indent); if (!(i == NumPts-1 && (Style & LS_RIGHT))) { for (j=0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%1d %1d %s\n", V[i].x, V[i].y, gPsCmd[PS_CURVETO]); } } start_index = i; } } } void DumpMultiCurvedPolygonPoints(FP, Smooth, Curved, NumPts, V, Indent) FILE *FP; char *Smooth; int Curved, NumPts, Indent; register IntPoint *V; { register int i, j; int num_smooth_points=0, num_hinge_points=0, tmp_index; int start_index, once_around=FALSE; IntPoint *tmp_vs=NULL; if (Curved == LT_INTSPLINE || Smooth == NULL) { DumpCurvedPolygonPoints(FP, Curved, NumPts, V, Indent); return; } for (i=1; i < NumPts; i++) { if (Smooth[i]) { num_smooth_points++; } else { num_hinge_points++; } } if (num_smooth_points == 0) { /* simple polygon */ for (j=0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%1d %1d %s\n", V[0].x, V[0].y, gPsCmd[PS_MOVETO]); DumpPoints(FP, NumPts-1, V, Indent); return; } if (num_hinge_points == 0) { DumpCurvedPolygonPoints(FP, Curved, NumPts, V, Indent); return; } tmp_vs = (IntPoint*)malloc((NumPts+1)*sizeof(IntPoint)); if (tmp_vs == NULL) FailAllocMessage(); memset(tmp_vs, 0, (NumPts+1)*sizeof(IntPoint)); for (i=0; i < NumPts; i++) { if (!Smooth[i]) { break; } } for (j=0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%1d %1d %s\n", V[i].x, V[i].y, gPsCmd[PS_MOVETO]); start_index = i; tmp_vs[0].x = V[start_index].x; tmp_vs[0].y = V[start_index].y; tmp_index = 1; for (i=start_index+1; !(once_around && i==start_index+1); i++, tmp_index++) { tmp_vs[tmp_index].x = V[i].x; tmp_vs[tmp_index].y = V[i].y; if (!Smooth[i]) { if (tmp_index == 1) { DumpPoints(FP, tmp_index+1, tmp_vs, Indent); } else { DumpCurvedPolyPoints(FP, Curved, tmp_index+1, tmp_vs, Indent); for (j=0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%1d %1d %s\n", V[i].x, V[i].y, gPsCmd[PS_CURVETO]); } start_index = (i==NumPts-1 ? 0 : i); tmp_vs[0].x = V[start_index].x; tmp_vs[0].y = V[start_index].y; tmp_index = 0; } if (i == NumPts-1) { i = 0; once_around = TRUE; } } if (tmp_vs != NULL) free(tmp_vs); } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/testdrive.pl�������������������������������������������������������������������������0000644�0000764�0000764�00000010067�11602233313�015337� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������% % Author: William Chia-Wei Cheng (bill.cheng@acm.org) % % Copyright (C) 2001-2009, William Chia-Wei Cheng. % % This file may be distributed under the terms of the Q Public License % as defined by Trolltech AS of Norway and appearing in the file % LICENSE.QPL included in the packaging of this file. % % THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING % THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR % PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, % INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING % FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, % NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION % WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/testdrive.pl,v 1.6 2011/05/16 16:26:57 william Exp $ % % ?- compile(testdrive). % ?- tgif. % % This is an example of a Prolog driver, which list the IDs of the % objects in the current drawing (attributes are skipped). The code % might be buggy, it is there to give some hints of how 'tgif.pl' can % be used. % % In order to use it, don't forget to uncomment the stuff related to % 'frontend11.o' in either the 'Imakefile' or the 'Makefile.noimake'. % It also expects 'tgif.pl' and 'frontend.pl' to be in the same directory % as itself. :- ensure_loaded(frontend). :- ensure_loaded(tgif). tgif :- interface(init,'',Cmd,Domain,File,_,_,_,_), tgif(Cmd,Domain,File). tgif(InitFile) :- interface(init,InitFile,Cmd,Domain,File,_,_,_,_), tgif(Cmd,Domain,File). tgif('Solve',_Domain,File) :- process_file(File), interface('','',NewCmd,NewDomain,NewFile,_,_,_,_), !, tgif(NewCmd,NewDomain,NewFile). tgif('Quit',_Domain,_File) :- interface(quit,'',_,_,_,_,_,_,_), !. % --------------------------------------------------------------------- % process_file(File) :- tgif_real_clean, my_consult(File), tgif_state(_,_), write('=============='), nl, write('Listing IDs...'), nl, write('=============='), nl, ( tgif_obj(Obj), print_id(Obj,0), fail ; ! ). % --------------------------------------------------------------------- % print_id(Obj,Level) :- print_level(Level), NextLevel is Level+1, get_id(Obj,Id), functor(Obj,Name,_Arity), write(Name), write(': '), write(Id), nl, !, ( ( Name==group | Name==sym | Name==icon ) -> atom_chars(Name,NameStr), catlist(["tgif_",NameStr],FunctorStr), atom_chars(Functor,FunctorStr), Goal =.. [Functor,Obj,Parms], call(Goal), memberchk(=(objs,Objs),Parms), ( member(SubObj,Objs), print_id(SubObj,NextLevel), fail ; true ) ; true ), !, get_attrs(Obj,Attrs), ( Attrs \== [] -> print_level(NextLevel), write('attrs:'), nl, AttrLevel is NextLevel+1, !, print_attr_id(Attrs,AttrLevel) ; true ). print_attr_id([],_AttrLevel) :- !. print_attr_id([Attr|Attrs],AttrLevel) :- tgif_attr(Attr,AttrParms), memberchk(=(text_obj,TextObj),AttrParms), print_id(TextObj,AttrLevel), !, print_attr_id(Attrs,AttrLevel). print_level(0) :- !. print_level(N) :- write(' '), N1 is N-1, !, print_level(N1). get_id(Obj,Id) :- functor(Obj,Name,_Arity), atom_chars(Name,NameStr), catlist(["tgif_",NameStr],FunctorStr), atom_chars(Functor,FunctorStr), Goal =.. [Functor,Obj,Parms], call(Goal), memberchk(=(id,Id),Parms), !. get_id(_Obj,none). get_attrs(Obj,Attrs) :- functor(Obj,Name,_Arity), atom_chars(Name,NameStr), catlist(["tgif_",NameStr],FunctorStr), atom_chars(Functor,FunctorStr), Goal =.. [Functor,Obj,Parms], call(Goal), memberchk(=(attrs,Attrs),Parms), !. get_attrs(_Obj,[]). % --------------------------------------------------------------------- % my_consult(File) :- seeing(X), see(File), my_consult, seen, see(X). my_consult :- repeat, read(Term), ( Term == end_of_file -> ! ; Term = :-(_) -> % ignore directives fail ; assertz(Term), fail ). member(Element, [Element|_]). member(Element, [_|Rest]) :- member(Element, Rest). memberchk(Element, [Element|_]) :- !. memberchk(Element, [_|Rest]) :- memberchk(Element, Rest). catlist([X|[]], X) :- !. catlist([[]|X], Y) :- !, catlist(X, Y). catlist([[H|T]|X], [H|Y]) :- catlist([T|X], Y). �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/stk.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000003271�11602233312�013736� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/stk.e,v 1.6 2011/05/16 16:21:59 william Exp $ */ #ifndef _STK_E_ #define _STK_E_ extern struct ObjRec * tgifObj; extern struct StkRec * topStk; #ifdef _INCLUDE_FROM_STK_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_STK_C_*/ extern int AncesterModified ARGS_DECL((void)); extern void InitTgifObj ARGS_DECL((void)); extern void InitStk ARGS_DECL((void)); extern struct StkRec * SaveFileInfo ARGS_DECL((void)); extern void ResetFileInfo ARGS_DECL((void)); extern int PushIcon ARGS_DECL((void)); extern void RestoreFileInfo ARGS_DECL((struct StkRec *)); extern void PopIcon ARGS_DECL((void)); extern void CleanUpTgifObj ARGS_DECL((void)); extern void CleanUpStk ARGS_DECL((void)); #ifdef _INCLUDE_FROM_STK_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_STK_C_*/ #endif /*_STK_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tdgtdraw.e���������������������������������������������������������������������������0000644�0000764�0000764�00000006112�11602233313�014753� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtdraw.e,v 1.6 2011/05/16 16:22:00 william Exp $ */ #ifndef _TDGTDRAW_E_ #define _TDGTDRAW_E_ #include "tidget.h" #define TDGTDRAW_DEF_H_PAD 2 #define TDGTDRAW_DEF_V_PAD 2 struct tagTdgtDraw; typedef int (TdgtDrawRedrawCallbackFunc)ARGS_DECL((struct tagTdgtDraw *)); typedef int (TdgtDrawEvHandlerCallbackFunc)ARGS_DECL((struct tagTdgtDraw *, XEvent*)); typedef int (TdgtDrawResetCallbackFunc)ARGS_DECL((struct tagTdgtDraw *)); typedef int (TdgtDrawSendCmdCallbackFunc)ARGS_DECL((struct tagTdgtDraw *, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); /* * A drawing area tidget uses callback routings to handl redraws * and mouse events. */ typedef struct tagTdgtDraw { TidgetInfo *pti; SimpleWinInfo client_area; void *pv_userdata; /* callback functions */ TdgtDrawRedrawCallbackFunc *pf_redraw_callback; TdgtDrawEvHandlerCallbackFunc *pf_ev_handler_callback; TdgtDrawResetCallbackFunc *pf_reset_callback; TdgtDrawSendCmdCallbackFunc *pf_sendcmd_callback; } TdgtDraw; #ifdef _INCLUDE_FROM_TDGTDRAW_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TDGTDRAW_C_*/ extern void TdgtDrawReset ARGS_DECL((TdgtDraw*)); extern TdgtDraw *CreateTdgtDraw ARGS_DECL((Window parent_win, TidgetInfo *parent_tidgetinfo, int ctl_id, int x, int y, int client_w, int client_h, int h_pad, int v_pad, int state, void *pv_userdata)); extern int TdgtDrawSetUserData ARGS_DECL((TdgtDraw*, void *pv_userdata)); extern char *TdgtDrawGetUserData ARGS_DECL((TdgtDraw*)); extern int TdgtDrawSetState ARGS_DECL((TdgtDraw*, int)); extern int TdgtDrawGetState ARGS_DECL((TdgtDraw*)); extern void TdgtDrawSetRedrawCallback ARGS_DECL((TdgtDraw*, TdgtDrawRedrawCallbackFunc*)); extern void TdgtDrawSetEvHandlerCallback ARGS_DECL((TdgtDraw*, TdgtDrawEvHandlerCallbackFunc*)); extern void TdgtDrawSetResetCallback ARGS_DECL((TdgtDraw*, TdgtDrawResetCallbackFunc*)); extern void TdgtDrawSetSendCmdCallback ARGS_DECL((TdgtDraw*, TdgtDrawSendCmdCallbackFunc*)); extern int InitTdgtDraw ARGS_DECL((void)); extern void CleanUpTdgtDraw ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TDGTDRAW_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TDGTDRAW_C_*/ #endif /*_TDGTDRAW_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/names.c������������������������������������������������������������������������������0000644�0000764�0000764�00000207353�11602233312�014245� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/names.c,v 1.10 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_NAMES_C_ #include "tgifdefs.h" #include "cmdids.h" #include "auxtext.e" #include "box.e" #include "button.e" #include "choose.e" #include "cutpaste.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "file.e" #include "font.e" #include "import.e" #include "ini.e" #include "mainloop.e" #include "mainmenu.e" #include "menu.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "raster.e" #include "rect.e" #include "remote.e" #include "setup.e" #include "strtbl.e" #include "util.e" #include "xpixmap.e" char curDomainName[MAXPATHLENGTH+1]; char curDomainPath[MAXPATHLENGTH+1]; char curDir[MAXPATHLENGTH+1]; char curLocalDir[MAXPATHLENGTH+1]; char curSymDir[MAXPATHLENGTH+1]; int doubleClickInterval=300; int importFromLibrary=FALSE; int importingFromExec=FALSE; int curDirIsLocal=TRUE; int ignoreDirectoryFlag=FALSE; static int domainInIni=FALSE; static int domainInResource=TRUE; static char curImportDir[MAXPATHLENGTH+1]; static DspList *symbolList=NULL; static int numSymbols=0; static DspList *dirList=NULL; static int numDirEntries=0; static DspList *topOfSymLinkList=NULL, *topOfDirLinkList=NULL; static void CleanUpDirList() { DspList *dsp_ptr=NULL, *next_dsp=NULL; for (dsp_ptr=topOfDirLinkList; dsp_ptr != NULL; dsp_ptr=next_dsp) { next_dsp = dsp_ptr->next; free(dsp_ptr); } topOfDirLinkList = NULL; } static void CleanUpSymList() { DspList *dsp_ptr=NULL, *next_dsp=NULL; for (dsp_ptr=topOfSymLinkList; dsp_ptr != NULL; dsp_ptr=next_dsp) { next_dsp = dsp_ptr->next; free(dsp_ptr); } topOfSymLinkList = NULL; } static char *ReadPath(path_str, dir_str) char *path_str, *dir_str; { register char *s1, *s2; s1 = path_str; while (*s1==' ' || *s1=='\t' || *s1=='\n') s1++; if (*s1 == '~') { strcpy(dir_str, homeDir); s2 = &dir_str[strlen(dir_str)]; s1++; } else { s2 = dir_str; } for ( ; *s1 != '\0' && *s1 != ':'; s1++) { if (*s1 == '\\') { UtilStrCpy(s1, s1+1); } else { *s2++ = *s1; } } *s2 = '\0'; if (*s1 == ':') s1++; return s1; } static void CleanUpSymPath() { if (symPath != NULL) { int i; for (i=0; i < symPathNumEntries; i++) { if (symPath[i] != NULL) { free(symPath[i]); } } if (symPath != NULL) free(symPath); symPath = NULL; } } void ParseSymPath(path_str) char *path_str; { int i, path_len=0; char *s, dir_str[MAXPATHLENGTH+1]; CleanUpSymPath(); for (i=0, s=path_str; *s != '\0'; ) { s = ReadPath(s, dir_str); UtilTrimBlanks(dir_str); if (*dir_str != '\0') i++; } symPath = (char**)malloc(i*sizeof(char*)); if (symPath == NULL) FailAllocMessage(); symPathNumEntries = i; *curDomainPath = '\0'; for (i=0, s=path_str; *s != '\0'; ) { s = ReadPath(s, dir_str); UtilTrimBlanks(dir_str); if (*dir_str != '\0') { symPath[i] = (char*)malloc((MAXPATHLENGTH+1)*sizeof(char)); if (symPath[i] == NULL) FailAllocMessage(); strcpy(symPath[i], dir_str); if (path_len == 0) { sprintf(&curDomainPath[path_len], "%s", dir_str); path_len += strlen(dir_str); } else { sprintf(&curDomainPath[path_len], ":%s", dir_str); path_len += strlen(dir_str)+1; } i++; } } } static int LargerStr(S1, S2) register char *S1, *S2; /* returns TRUE if S1 > S2 */ { while (*S1 == *S2 && *S1 != '\0' && *S2 != '\0') { S1++; S2++; } return (*S1 > *S2); } static DspList *SymbolListing() { int len, path_index, count = 0, reject, sym_ext_len, pin_ext_len; char path[MAXPATHLENGTH], sym_ext_str[MAXSTRING], pin_ext_str[MAXSTRING]; DspList *dsp_ptr, *head_ptr, *tail_ptr, *p, *p1; DIR *dirp; DIR_ENTRY *d; head_ptr = tail_ptr = NULL; sprintf(sym_ext_str, ".%s", SYM_FILE_EXT); sym_ext_len = strlen(sym_ext_str); sprintf(pin_ext_str, ".%s", PIN_FILE_EXT); pin_ext_len = strlen(pin_ext_str); for (path_index = 0; path_index < symPathNumEntries; path_index++) { strcpy(path, symPath[path_index]); if (strcmp(".", path) == 0) { if (curDirIsLocal) { strcpy(path, curDir); } else { strcpy(path, curLocalDir); } } if ((dirp=opendir(path)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_DIR_FOR_READING), path); Msg(gszMsgBox); continue; } while ((d=readdir(dirp)) != NULL) { int symbol_is_pin=FALSE; len = strlen(d->d_name); if (len > sym_ext_len && (strcmp(sym_ext_str, &d->d_name[len-sym_ext_len]) == 0)) { d->d_name[len-sym_ext_len] = '\0'; } else if (len > pin_ext_len && (strcmp(pin_ext_str, &d->d_name[len-pin_ext_len]) == 0)) { d->d_name[len-pin_ext_len] = '\0'; symbol_is_pin = TRUE; } else { continue; } if (head_ptr == NULL) { head_ptr = tail_ptr = (DspList*)malloc(sizeof(DspList)); if (head_ptr == NULL) FailAllocMessage(); memset(head_ptr, 0, sizeof(DspList)); UtilStrCpyN(head_ptr->itemstr, sizeof(head_ptr->itemstr), d->d_name); UtilStrCpyN(head_ptr->pathstr, sizeof(head_ptr->pathstr), path); /* The directory field is TRUE if the entry has PIN_FILE_EXT. */ head_ptr->directory = symbol_is_pin; } else { p1 = NULL; reject = FALSE; for (p=head_ptr; p != NULL; p = p->next) { if (strcmp(d->d_name, p->itemstr) == 0) { reject = TRUE; break; } else if (LargerStr(d->d_name, p->itemstr)) { p1 = p; } else { break; } } if (reject) continue; dsp_ptr = (DspList*)malloc(sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, sizeof(DspList)); dsp_ptr->next = p; UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), d->d_name); UtilStrCpyN(dsp_ptr->pathstr, sizeof(dsp_ptr->pathstr), path); /* The directory field is TRUE if the entry has PIN_FILE_EXT. */ dsp_ptr->directory = symbol_is_pin; if (p == NULL) { /* dsp_ptr has the largest element */ tail_ptr->next = dsp_ptr; tail_ptr = dsp_ptr; } else if (p1 == NULL) { head_ptr = dsp_ptr; } else { p1->next = dsp_ptr; } } count++; } closedir(dirp); } numSymbols = count; return head_ptr; } static void BuildSymbolList() { int i=0, watch_cursor=watchCursorOnMainWindow; DspList *dsp_ptr=NULL, *next_dsp=NULL; if (topOfSymLinkList == NULL) { if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } if ((topOfSymLinkList = SymbolListing()) != NULL) BuildSymbolList(); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } } if (topOfSymLinkList != NULL) { if (symbolList != NULL) free(symbolList); symbolList = (DspList*)malloc(numSymbols*sizeof(DspList)); if (symbolList == NULL) FailAllocMessage(); memset(symbolList, 0, numSymbols*sizeof(DspList)); dsp_ptr = topOfSymLinkList; for (i=0; i < numSymbols; i++, dsp_ptr = next_dsp) { next_dsp = dsp_ptr->next; UtilStrCpyN(symbolList[i].itemstr, sizeof(symbolList[i].itemstr), dsp_ptr->itemstr); UtilStrCpyN(symbolList[i].pathstr, sizeof(symbolList[i].pathstr), dsp_ptr->pathstr); symbolList[i].directory = dsp_ptr->directory; symbolList[i].next = &symbolList[i+1]; free(dsp_ptr); } symbolList[numSymbols-1].next = NULL; topOfSymLinkList = NULL; } } static DspList *DirListing(Path, ExtStr, OtherExtStr) char *Path, *ExtStr, *OtherExtStr; { DspList *dsp_ptr, *head_ptr, *tail_ptr, *p, *p1; DIR *dirp; DIR_ENTRY *d; int len, ext_len, count = 0; char path[MAXPATHLENGTH], s[MAXPATHLENGTH], *ext_str=NULL; struct stat stat_buf; if (ExtStr != NULL && *ExtStr != '\0') { if (OtherExtStr != NULL && *OtherExtStr != '\0') { ext_len = (strlen(ExtStr)<<1)+3+strlen(OtherExtStr); if ((ext_str=SetUpExtStr(ext_len, ExtStr, OtherExtStr)) == NULL) { return NULL; } } else { ext_len = (strlen(ExtStr)<<1)+3; if ((ext_str=SetUpExtStr(ext_len, ExtStr, "")) == NULL) { return NULL; } } } else if (OtherExtStr != NULL && *OtherExtStr != '\0') { ext_len = strlen(OtherExtStr)+3; if ((ext_str=SetUpExtStr(ext_len, "", OtherExtStr)) == NULL) { return NULL; } } ext_len = (ext_str == NULL ? 0 : strlen(ext_str)); if (*Path == '\0') { strcpy(path, DIR_SEP_STR); if ((dirp=opendir(path)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_DIR_FOR_READING), path); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (ext_str != NULL) free(ext_str); return NULL; } } else { strcpy(path, Path); if ((dirp=opendir(path)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_DIR_FOR_READING), path); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (ext_str != NULL) free(ext_str); return NULL; } #ifdef __CYGWIN__ if (path[strlen(path)-1] != DIR_SEP) { strcat(path, DIR_SEP_STR); } #else /* ~__CYGWIN__ */ strcat(path, DIR_SEP_STR); #endif /* __CYGWIN__ */ } #ifdef VMS /* Fake the .. entry for VMS */ head_ptr = tail_ptr = (DspList*)malloc(sizeof(DspList)); if (head_ptr == NULL) FailAllocMessage(); memset(head_ptr, 0, sizeof(DspList)); head_ptr->directory = TRUE; UtilStrCpyN(head_ptr->itemstr, sizeof(head_ptr->itemstr), "../"); head_ptr->next = NULL; count = 1; #else head_ptr = tail_ptr = NULL; #endif /* VMS */ while ((d=readdir(dirp)) != NULL) { len = strlen(d->d_name); if (ext_len == 0) { #ifdef VMS if (len > 4 && (strcmp(".dir", &d->d_name[len-4]) == 0)) { d->d_name[len-4] = DIR_SEP; d->d_name[len-4+1] = '\0'; dsp_ptr = (DspList*)malloc(sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, sizeof(DspList)); dsp_ptr->directory = TRUE; UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), d->d_name); } else if (strcmp(d->d_name, ".") == 0) { #else if (strcmp(d->d_name, ".") == 0) { #endif /* VMS */ continue; } else { sprintf(s, "%s%s", path, d->d_name); if (stat(s, &stat_buf) != 0) { int show_msg=TRUE; #ifndef _NO_LSTAT if (lstat(s, &stat_buf) == 0 && ((stat_buf.st_mode & S_IFLNK) == S_IFLNK)) { show_msg = FALSE; } #endif /* _NO_LSTAT */ if (show_msg) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_STAT_GIVEN_FILE), s); Msg(gszMsgBox); } continue; } else { dsp_ptr = (DspList*)malloc(sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, sizeof(DspList)); if (stat_buf.st_mode & S_IFDIR) { dsp_ptr->directory = TRUE; strcat(d->d_name, DIR_SEP_STR); } else { dsp_ptr->directory = FALSE; } UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), d->d_name); } } } else if (ExtensionMatch(ext_str, d->d_name)) { dsp_ptr = (DspList*)malloc(sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, sizeof(DspList)); dsp_ptr->directory = FALSE; UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), d->d_name); #ifdef VMS } else if (len > 4 && (strcmp(".dir", &d->d_name[len-4]) == 0)) { d->d_name[len-4] = DIR_SEP; d->d_name[len-4+1] = '\0'; dsp_ptr = (DspList*)malloc(sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, sizeof(DspList)); dsp_ptr->directory = TRUE; UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), d->d_name); #endif /* VMS */ } else if (strcmp(d->d_name, ".") == 0) { continue; } else { sprintf(s, "%s%s", path, d->d_name); if (stat(s, &stat_buf) != 0) { int show_msg=TRUE; #ifndef _NO_LSTAT if (lstat(s, &stat_buf) == 0 && ((stat_buf.st_mode & S_IFLNK) == S_IFLNK)) { show_msg = FALSE; } #endif /* _NO_LSTAT */ if (show_msg) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_STAT_GIVEN_FILE), s); Msg(gszMsgBox); } continue; } else if (stat_buf.st_mode & S_IFDIR) { dsp_ptr = (DspList*)malloc(sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, sizeof(DspList)); dsp_ptr->directory = TRUE; strcat(d->d_name, DIR_SEP_STR); UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), d->d_name); } else { continue; } } if (head_ptr == NULL) { head_ptr = tail_ptr = dsp_ptr; } else { p1 = NULL; for (p = head_ptr; p != NULL; p = p->next) { if (LargerStr(d->d_name, p->itemstr)) { p1 = p; } else { break; } } dsp_ptr->next = p; if (p == NULL) { /* dsp_ptr has the largest element */ tail_ptr->next = dsp_ptr; tail_ptr = dsp_ptr; } else if (p1 == NULL) { head_ptr = dsp_ptr; } else { p1->next = dsp_ptr; } } count++; } closedir(dirp); numDirEntries = count; if (ext_str != NULL) free(ext_str); return head_ptr; } static void BuildDirList() { int i=0, watch_cursor=watchCursorOnMainWindow; DspList *dsp_ptr=NULL, *next_dsp=NULL; if (topOfDirLinkList == NULL) { if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } if (curDirIsLocal) { if ((topOfDirLinkList=DirListing(curDir, OBJ_FILE_EXT, "")) != NULL) { BuildDirList(); } } else if ((topOfDirLinkList=DirListing(curLocalDir, OBJ_FILE_EXT, "")) != NULL) { BuildDirList(); } if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } } if (topOfDirLinkList != NULL) { if (dirList != NULL) free(dirList); dirList = (DspList*)malloc(numDirEntries*sizeof(DspList)); if (dirList == NULL) FailAllocMessage(); memset(dirList, 0, numDirEntries*sizeof(DspList)); dsp_ptr = topOfDirLinkList; for (i=0; i < numDirEntries; i++, dsp_ptr = next_dsp) { next_dsp = dsp_ptr->next; UtilStrCpyN(dirList[i].itemstr, sizeof(dirList[i].itemstr), dsp_ptr->itemstr); UtilStrCpyN(dirList[i].pathstr, sizeof(dirList[i].pathstr), dsp_ptr->pathstr); dirList[i].directory = dsp_ptr->directory; dirList[i].next = &dirList[i+1]; free(dsp_ptr); } dirList[numDirEntries-1].next = NULL; topOfDirLinkList = NULL; } } static char gszDefaultDomainSec[]="DefaultDomain"; static char gszDomainPathsSec[]="DomainPaths"; static char gszDomainIniFile[MAXPATHLENGTH]; static void InitDomain() { char *c_ptr=NULL, domain_str[20], sym_path[80], cap_tool_name[MAXSTRING]; int default_found=FALSE, need_to_copy_domain_into_ini=FALSE; char *pszDomainNames=NULL, *psz_default_path=NULL; sprintf(gszDomainIniFile, "%s%cdomain.ini", tgifDir, DIR_SEP); domainInIni = FALSE; domainInResource = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DomainInIni")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { if ((pszDomainNames=tgGetProfileString(gszDomainPathsSec, NULL, gszDomainIniFile)) != NULL) { domainInIni = TRUE; domainInResource = FALSE; tgFreeProfileString(pszDomainNames); } else { need_to_copy_domain_into_ini = TRUE; } } if (domainInIni && (pszDomainNames=tgGetProfileString(gszDomainPathsSec, NULL, gszDomainIniFile)) != NULL) { char *pszKeys=NULL; if ((pszKeys=tgGetProfileString(gszDefaultDomainSec, NULL, gszDomainIniFile)) != NULL) { char *pszKey=pszKeys; char *pszPath=tgGetProfileString(gszDomainPathsSec, pszKey, gszDomainIniFile); if (pszPath != NULL || strcmp(pszKey, "Examples") == 0) { psz_default_path = UtilStrDup(pszPath==NULL ? TGIF_PATH : pszPath); if (psz_default_path == NULL) FailAllocMessage(); UtilStrCpyN(curDomainName, sizeof(curDomainName), pszKey); default_found = TRUE; tgFreeProfileString(pszPath); } tgFreeProfileString(pszKeys); } if (!default_found) { /* just pick the first one */ char *pszKey=pszDomainNames; char *pszPath=tgGetProfileString(gszDomainPathsSec, pszKey, gszDomainIniFile); if (pszPath != NULL) { psz_default_path = UtilStrDup(pszPath); if (psz_default_path == NULL) FailAllocMessage(); UtilStrCpyN(curDomainName, sizeof(curDomainName), pszKey); default_found = TRUE; tgFreeProfileString(pszPath); } tgFreeProfileString(pszKeys); } tgFreeProfileString(pszDomainNames); } if (domainInResource && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DefaultDomain")) != NULL) { int default_domain=atoi(c_ptr); sprintf(domain_str, "DomainPath%1d", default_domain); if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, domain_str)) != NULL) { char *c_ptr1; while (*c_ptr==' ' || *c_ptr=='\t' || *c_ptr=='\n') c_ptr++; if (*c_ptr != '\0' && (c_ptr1=strchr(c_ptr, ':')) != NULL) { int len=c_ptr1-c_ptr; strncpy(curDomainName, c_ptr, len); curDomainName[len] = '\0'; psz_default_path = UtilStrDup(++c_ptr1); if (psz_default_path == NULL) FailAllocMessage(); default_found = TRUE; } } else { sprintf(domain_str, "Domain%1d", default_domain); if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, domain_str)) != NULL) { if (*c_ptr != '\0') { strcpy(cap_tool_name, TOOL_NAME); UtilStrUpper(cap_tool_name); strcpy(curDomainName, c_ptr); sprintf(sym_path, "%s_%s", cap_tool_name, c_ptr); default_found = TRUE; domainInResource = FALSE; } } } } if (default_found) { if (domainInIni || domainInResource) { ParseSymPath(psz_default_path); } else if ((c_ptr=getenv(sym_path)) == NULL || ((int)strlen(c_ptr)) >= MAXPATHLENGTH-1) { ParseSymPath("."); } else { ParseSymPath(c_ptr); } } else { char buf[MAXPATHLENGTH]; strcpy(buf, ".:"); UtilStrCpyN(&buf[2], sizeof(buf)-2, TGIF_PATH); ParseSymPath(buf); } if (need_to_copy_domain_into_ini) { CopyDomainInfoToIni(); tgWriteProfileString(gszDefaultDomainSec, curDomainName, "", gszDomainIniFile); tgWriteProfileString(NULL, NULL, NULL, gszDomainIniFile); if ((pszDomainNames=tgGetProfileString(gszDomainPathsSec, NULL, gszDomainIniFile)) != NULL) { domainInIni = TRUE; domainInResource = FALSE; tgFreeProfileString(pszDomainNames); } } UtilFree(psz_default_path); } void InitNames() { char *c_ptr=NULL; if (mainDisplay != NULL) InitNamesInfo(); ignoreDirectoryFlag = FALSE; symbolList = dirList = NULL; numSymbols = numDirEntries = 0; topOfSymLinkList = topOfDirLinkList = NULL; *curDomainName = '\0'; *curDomainPath = '\0'; *curSymDir = '\0'; strcpy(curDir, bootDir); strcpy(curLocalDir, bootDir); strcpy(curImportDir, bootDir); if (mainDisplay == NULL) return; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DoubleClickInterval")) != NULL) { doubleClickInterval = atoi(c_ptr); } else { doubleClickInterval = 300; } warpToWinCenter = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"WarpToWinCenter")) != NULL) { if (UtilStrICmp(c_ptr, "false") == 0) { warpToWinCenter = FALSE; } } importFromLibrary = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ImportFromLibrary")) != NULL) { if (UtilStrICmp(c_ptr, "true") == 0) { importFromLibrary = TRUE; } } InitDomain(); } void UpdateDirInfo() { CleanUpDirList(); } void UpdateSymInfo() { CleanUpSymList(); } void CleanUpNames() { CleanUpNamesInfo(); CleanUpSymPath(); if (symbolList != NULL) free(symbolList); if (dirList != NULL) free(dirList); symbolList = dirList = NULL; ignoreDirectoryFlag = FALSE; } char **MakeNameDspItemArray(Entries, DLPtr) int Entries; DspList *DLPtr; { int i, j, len; char **dsp_ptr, *c_ptr; if (Entries == 0) return NULL; dsp_ptr = (char**)malloc(Entries*sizeof(char*)); if (dsp_ptr == NULL) FailAllocMessage(); c_ptr = (char*)malloc(Entries*(MAXPATHLENGTH+1)*sizeof(char)); if (c_ptr == NULL) FailAllocMessage(); for (i=0; i < Entries; i++, DLPtr=DLPtr->next) { dsp_ptr[i] = c_ptr; len = strlen(DLPtr->itemstr); if (!ignoreDirectoryFlag && !DLPtr->directory) { for (j = len; j >= 0 && DLPtr->itemstr[j] != DIR_SEP; j--) ; if (j >= 0) { strcpy(c_ptr, (&(DLPtr->itemstr[j]))+1); } else { strcpy(c_ptr, DLPtr->itemstr); } } else { strcpy(c_ptr, DLPtr->itemstr); } c_ptr += MAXPATHLENGTH; } return dsp_ptr; } int DirInSymPath(DirName) char *DirName; { register int i; if (symPath == NULL) return FALSE; for (i = 0; i < symPathNumEntries; i++) { if (strcmp(DirName, symPath[i]) == 0) { return TRUE; } } return FALSE; } static int lengthOfLongestItem=INVALID; static char **MakeLongNameDspItemArray(Entries, DLPtr) int Entries; DspList *DLPtr; { int i, len; char **dsp_ptr, *c_ptr; lengthOfLongestItem = INVALID; if (Entries == 0) return NULL; dsp_ptr = (char**)malloc(Entries*sizeof(char*)); if (dsp_ptr == NULL) FailAllocMessage(); c_ptr = (char*)malloc(Entries*(MAXPATHLENGTH+1)*sizeof(char)); if (c_ptr == NULL) FailAllocMessage(); for (i=0; i < Entries; i++, DLPtr=DLPtr->next) { dsp_ptr[i] = c_ptr; len = strlen(DLPtr->itemstr); strcpy(c_ptr, DLPtr->itemstr); if (len > lengthOfLongestItem) lengthOfLongestItem = len; c_ptr += MAXPATHLENGTH; } return dsp_ptr; } struct DirNamesInfoRec { char ext_str[81], other_ext_str[81]; } dirNamesInfo; static int GetNamesEntries(p_dsp_ptr, p_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, p_void) DspList **p_dsp_ptr; char ***p_entries, *cur_buf; int *pn_num_entries, *pn_marked_index; struct CheckArrayRec **pp_check_array; void *p_void; { struct DirNamesInfoRec *p_dninfo=(struct DirNamesInfoRec*)p_void; DspList *dsp_ptr, *next_dsp; for (dsp_ptr=topOfDirLinkList; dsp_ptr != NULL; dsp_ptr=next_dsp) { next_dsp = dsp_ptr->next; free(dsp_ptr); } topOfDirLinkList = NULL; *p_dsp_ptr = NULL; *p_entries = NULL; *pn_num_entries = 0; *pn_marked_index = INVALID; if (*cur_buf == '\0') { /* this can only happen if the change_to_root */ return TRUE; } else { char status_buf[MAX_STATUS_BTNS+1][MAXSTRING+1]; int one_line_status=FALSE; SaveStatusStringsIntoBuf(status_buf, &one_line_status); sprintf(gszMsgBox, TgLoadCachedString(CSTID_GET_DIR_LIST_PLEASE_WAIT), cur_buf); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((topOfDirLinkList=DirListing(cur_buf, p_dninfo->ext_str, p_dninfo->other_ext_str)) == NULL) { RestoreStatusStringsFromBuf(status_buf, one_line_status); return FALSE; } RestoreStatusStringsFromBuf(status_buf, one_line_status); *pn_num_entries = numDirEntries; if (topOfDirLinkList == NULL) { *p_entries = MakeNameDspItemArray(*pn_num_entries, dirList); } else { *p_entries = MakeNameDspItemArray(*pn_num_entries, topOfDirLinkList); } } return TRUE; } static int NamesAfterLoop(p_dsp_ptr, p_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, btn_id, selected_index, p_void) DspList **p_dsp_ptr; char ***p_entries, *cur_buf; int *pn_num_entries, *pn_marked_index, btn_id, selected_index; struct CheckArrayRec **pp_check_array; void *p_void; { if (*p_dsp_ptr != NULL) free(*p_dsp_ptr); if (*p_entries != NULL) { free(**p_entries); free(*p_entries); } *p_dsp_ptr = NULL; *p_entries = NULL; *pn_num_entries = 0; switch (btn_id) { case BUTTON_OK: break; case BUTTON_SETDIR: if (cur_buf != NULL) { int len=strlen(cur_buf); if (len > 4 && cur_buf[len-4] == DIR_SEP && cur_buf[len-3] == '.' && cur_buf[len-2] == '.' && cur_buf[len-1] == DIR_SEP) { break; } } return FALSE; case BUTTON_CANCEL: break; } return TRUE; } static int DirNames(TopStr, ExtStr, SelStr, JustSetDir) char *TopStr, *ExtStr, *SelStr; int *JustSetDir; { char win_name[128], selected_str[MAXSTRING+1]; int selected_index=INVALID, selected_btn_id; struct DirNamesInfoRec dninfo; *SelStr = '\0'; *JustSetDir = FALSE; memset(&dninfo, 0, sizeof(struct DirNamesInfoRec)); UtilStrCpyN(dirNamesInfo.ext_str, sizeof(dirNamesInfo.ext_str), ExtStr); UtilStrCpyN(dirNamesInfo.other_ext_str, sizeof(dirNamesInfo.other_ext_str), ExtStr); if (ExtStr != NULL && strcmp(ExtStr, EPSF_FILE_EXT) == 0) { sprintf(dirNamesInfo.other_ext_str, ".%s;.epsi", PS_FILE_EXT); } else if (ExtStr != NULL && strcmp(ExtStr, OBJ_FILE_EXT) == 0) { sprintf(dirNamesInfo.other_ext_str, ".%s;.%s", SYM_FILE_EXT, PIN_FILE_EXT); if (strstr(dirNamesInfo.other_ext_str, ".obj") == NULL) { strcat(dirNamesInfo.other_ext_str, ";.obj"); } if (strstr(dirNamesInfo.other_ext_str, ".sym") == NULL) { strcat(dirNamesInfo.other_ext_str, ";.sym"); } if (strstr(dirNamesInfo.other_ext_str, ".pin") == NULL) { strcat(dirNamesInfo.other_ext_str, ";.pin"); } if (strstr(dirNamesInfo.other_ext_str, ".tgo") == NULL) { strcat(dirNamesInfo.other_ext_str, ";.tgo"); } if (strstr(dirNamesInfo.other_ext_str, ".tgs") == NULL) { strcat(dirNamesInfo.other_ext_str, ";.tgs"); } if (strstr(dirNamesInfo.other_ext_str, ".tgp") == NULL) { strcat(dirNamesInfo.other_ext_str, ";.tgp"); } sprintf(selected_str, ";.obj.gz;.tgo.gz;.%s.gz", OBJ_FILE_EXT); strcat(dirNamesInfo.other_ext_str, selected_str); } else if (ExtStr != NULL && strcmp(ExtStr, "gif") == 0) { strcpy(dirNamesInfo.other_ext_str, ".GIF"); } else if (ExtStr != NULL && strcmp(ExtStr, "png") == 0) { strcpy(dirNamesInfo.other_ext_str, ".PNG"); } else if (ExtStr != NULL && strcmp(ExtStr, "jpeg") == 0) { strcpy(dirNamesInfo.other_ext_str, ".JPEG;.jpg;.JPG"); } else { *dirNamesInfo.other_ext_str = '\0'; } ResetNamesInfo(); NamesSetTitle(TopStr); NamesAddButton(TgLoadCachedString(CSTID_OK), BUTTON_OK); if (!(importingFile || (curFileDefined && curDirIsLocal))) { NamesAddButton(TgLoadString(STID_SET_WORKING_DIR), BUTTON_SETDIR); } NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); NamesSetEntries(NULL, NULL, 0, NULL, TRUE, INVALID, 0); NamesSetStyle(NAMES_SELECT_FILE, NAMES_LOOP_MANY); NamesSetCallback((GetEntriesFunc*)GetNamesEntries, (AfterLoopFunc*)NamesAfterLoop, NULL); if (importingFile) { NamesSetDir(curImportDir); } else if (curDirIsLocal) { NamesSetDir(curDir); } else { NamesSetDir(curLocalDir); } if (!(importingFile || (curFileDefined && curDirIsLocal))) { Msg(TgLoadString(STID_CLICK_SETWORKDIR_TO_SET_DIR)); } *selected_str = '\0'; sprintf(win_name, "%s - %s", TOOL_NAME, TopStr); selected_btn_id = Names(win_name, &selected_index, selected_str, sizeof(selected_str), &dirNamesInfo); if (selected_btn_id == BUTTON_OK) { *JustSetDir = FALSE; strcpy(SelStr, selected_str); if (FileIsRemote(selected_str)) { /* index != INVALID means SelStr is valid */ return 0; } return selected_index; } else if (selected_btn_id == BUTTON_SETDIR) { if (DirIsRemote(selected_str)) { *SelStr = '\0'; *JustSetDir = FALSE; sprintf(gszMsgBox, TgLoadString(STID_SETWORKDIR_NOT_SUP_FOR_STR), selected_str); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { int len=strlen(selected_str); if (len > 0 && selected_str[len-1] == DIR_SEP) { UtilShrinkName(selected_str); len = strlen(selected_str); } if (len > 0) { if (selected_str[len-1] == DIR_SEP) { selected_str[--len] = '\0'; } else { while (len > 0 && selected_str[len-1] != DIR_SEP) { selected_str[--len] = '\0'; } if (len > 0) selected_str[--len] = '\0'; } } strcpy(SelStr, selected_str); *JustSetDir = TRUE; } } return INVALID; } static int ChooseAName(TopStr, entries, num_entries, marked_index) char *TopStr, **entries; int num_entries, marked_index; { char win_name[128]; int selected_index=INVALID; ResetNamesInfo(); NamesSetTitle(TopStr); NamesAddButton(TgLoadCachedString(CSTID_OK), BUTTON_OK); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); NamesSetEntries(NULL, entries, num_entries, NULL, TRUE, marked_index, 0); NamesSetStyle(NAMES_COMPLEX_SELECT_NAME, NAMES_LOOP_ONCE); sprintf(win_name, "%s - %s", TOOL_NAME, TopStr); if (Names(win_name, &selected_index, NULL, 0, NULL) == BUTTON_OK) { return selected_index; } return INVALID; } int SelectFileName(MsgStr, SelStr) char *MsgStr, *SelStr; { int index, saved_num_dir_entries, just_set_dir; DspList *dsp_ptr, *next_dsp; char saved_cur_dir[MAXPATHLENGTH]; if (curDirIsLocal) { strcpy(saved_cur_dir, curDir); } else { strcpy(saved_cur_dir, curLocalDir); } saved_num_dir_entries = numDirEntries; if ((index=DirNames(MsgStr,OBJ_FILE_EXT,SelStr,&just_set_dir)) == INVALID) { if (just_set_dir) { if (curDirIsLocal) { strcpy(curDir, SelStr); } else { strcpy(curLocalDir, SelStr); } BuildDirList(); if (strcmp(saved_cur_dir, curDir) != 0 && DirInSymPath(".")) { UpdateSymInfo(); } RedrawTitleWindow(); sprintf(gszMsgBox, TgLoadString(STID_OPENSAVE_DIR_CHANGE_TO_REMAIN), curDir, curImportDir); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); Msg(""); } else { numDirEntries = saved_num_dir_entries; for (dsp_ptr=topOfDirLinkList; dsp_ptr != NULL; dsp_ptr=next_dsp) { next_dsp = dsp_ptr->next; free(dsp_ptr); } topOfDirLinkList = NULL; } *SelStr = '\0'; return INVALID; } BuildDirList(); Msg(""); return index; } int SelectFileNameToPaste(MsgStr, SelStr) char *MsgStr, *SelStr; { int index, saved_num_dir_entries, just_set_dir; DspList *dsp_ptr, *next_dsp; char saved_cur_dir[MAXPATHLENGTH]; if (curDirIsLocal) { strcpy(saved_cur_dir, curDir); } else { strcpy(saved_cur_dir, curLocalDir); } saved_num_dir_entries = numDirEntries; if ((index=DirNames(MsgStr,NULL,SelStr,&just_set_dir)) == INVALID) { if (just_set_dir) { if (curDirIsLocal) { strcpy(curDir, SelStr); } else { strcpy(curLocalDir, SelStr); } BuildDirList(); if (strcmp(saved_cur_dir, curDir) != 0 && DirInSymPath(".")) { UpdateSymInfo(); } RedrawTitleWindow(); sprintf(gszMsgBox, TgLoadString(STID_OPENSAVE_DIR_CHANGE_TO_REMAIN), curDir, curImportDir); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); Msg(""); } else { numDirEntries = saved_num_dir_entries; for (dsp_ptr=topOfDirLinkList; dsp_ptr != NULL; dsp_ptr=next_dsp) { next_dsp = dsp_ptr->next; free(dsp_ptr); } topOfDirLinkList = NULL; } *SelStr = '\0'; return INVALID; } BuildDirList(); Msg(""); return index; } int SelectFileNameToImport(MsgStr, ExtStr, SelStr) char *MsgStr, *ExtStr, *SelStr; { int index, saved_num_dir_entries, just_set_dir; DspList *dsp_ptr, *next_dsp; saved_num_dir_entries = numDirEntries; if ((index=DirNames(MsgStr, ExtStr, SelStr, &just_set_dir)) == INVALID) { if (just_set_dir) { /* This should not happen since SetDir is removed during importing. */ strcpy(curImportDir, SelStr); sprintf(gszMsgBox, TgLoadString(STID_IMPORT_DIR_CHANGED_TO_REMAIN), curImportDir, curDir); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } *SelStr = '\0'; } else { Msg(""); } numDirEntries = saved_num_dir_entries; for (dsp_ptr=topOfDirLinkList; dsp_ptr != NULL; dsp_ptr=next_dsp) { next_dsp = dsp_ptr->next; free(dsp_ptr); } topOfDirLinkList = NULL; return index; } int GetSymbolPath(SymName, Pin, PathName) char *SymName, *PathName; int Pin; { int i; if (topOfSymLinkList == NULL) { if ((topOfSymLinkList=SymbolListing()) != NULL) BuildSymbolList(); } if (symbolList == NULL) return FALSE; for (i = 0; i < numSymbols; i++) { /* The directory field is TRUE if the entry has PIN_FILE_EXT. */ if (symbolList[i].directory == Pin && strcmp(SymName, symbolList[i].itemstr) == 0) { strcpy(PathName, symbolList[i].pathstr); return TRUE; } } return FALSE; } int NameInCurDir(FileName) char *FileName; { int i; if (dirList == NULL) return FALSE; for (i = 0; i < numDirEntries; i++) { if (dirList[i].directory && strcmp(FileName, dirList[i].itemstr) == 0) { return TRUE; } } return FALSE; } static char **tmpDomainName=NULL; static char **tmpDomainPath=NULL; static int numTmpDomainNames=0; static void CleanUpTmpDomainName() { if (tmpDomainName != NULL) { int i=0; for (i=0; i < numTmpDomainNames; i++) { UtilFree(tmpDomainName[i]); UtilFree(tmpDomainPath[i]); } free(tmpDomainName); free(tmpDomainPath); tmpDomainName = tmpDomainPath = NULL; } } static DspList *DomainListing(pn_num_entries, name_only) int *pn_num_entries, name_only; /* * If (name_only == TRUE) returned DspList only has names. * If (name_only == FALSE) returned DspList has name=path. */ { int i=0, seen_examples=FALSE; char s[MAXSTRING], *c_ptr=NULL, **ppsz_keys=NULL; DspList *dsp_ptr=NULL, *head_ptr=NULL, *tail_ptr=NULL, *p=NULL, *p1=NULL; DspList *next_dsp=NULL; int one_line_status=FALSE; char status_buf[MAX_STATUS_BTNS+1][MAXSTRING+1]; SaveStatusStringsIntoBuf(status_buf, &one_line_status); SetStringStatus(TgLoadString(STID_GEN_LIST_OF_DOMAIN_NAMES_WAIT)); *pn_num_entries = 0; if (domainInIni) { char *pszKeys=tgGetProfileString(gszDomainPathsSec, NULL, gszDomainIniFile); if (pszKeys != NULL) { int count=1; char *pszKey=NULL; ppsz_keys = (char**)malloc(sizeof(char*)); if (ppsz_keys == NULL) FailAllocMessage(); ppsz_keys[count-1] = NULL; for (pszKey=pszKeys; *pszKey != '\0'; pszKey++) { ppsz_keys = (char**)realloc(ppsz_keys, (++count)*sizeof(char*)); if (ppsz_keys == NULL) FailAllocMessage(); ppsz_keys[count-1] = NULL; ppsz_keys[count-2] = UtilStrDup(pszKey); if (ppsz_keys[count-2] == NULL) FailAllocMessage(); pszKey += strlen(pszKey); } *pn_num_entries = count; tgFreeProfileString(pszKeys); } } else { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "MaxDomains")) == NULL) { *pn_num_entries = 1; } else { *pn_num_entries = atoi(c_ptr)+1; } } if (*pn_num_entries == 0) { RestoreStatusStringsFromBuf(status_buf, one_line_status); return NULL; } numTmpDomainNames = (*pn_num_entries); tmpDomainName = (char**)malloc((*pn_num_entries)*sizeof(char*)); tmpDomainPath = (char**)malloc((*pn_num_entries)*sizeof(char*)); if (tmpDomainName == NULL || tmpDomainPath == NULL) FailAllocMessage(); memset(tmpDomainName, 0, (*pn_num_entries)*sizeof(char*)); memset(tmpDomainPath, 0, (*pn_num_entries)*sizeof(char*)); head_ptr = tail_ptr = NULL; for (i = 0; i < (*pn_num_entries); i++) { if (i != (*pn_num_entries)-1) { char *c_ptr1=NULL, *psz_path_in_ini=NULL; if (domainInIni) { if ((psz_path_in_ini=tgGetProfileString(gszDomainPathsSec, ppsz_keys[i], gszDomainIniFile)) != NULL) { c_ptr = psz_path_in_ini; while (*c_ptr==' ' || *c_ptr=='\t' || *c_ptr=='\n') c_ptr++; } } else if (domainInResource) { sprintf(s, "DomainPath%1d", i); if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, s)) != NULL) { while (*c_ptr==' ' || *c_ptr=='\t' || *c_ptr=='\n') c_ptr++; } } else { sprintf(s, "Domain%1d", i); c_ptr = XGetDefault(mainDisplay, TOOL_NAME, s); } if (c_ptr == NULL || *c_ptr == '\0') { if (domainInIni) { sprintf(gszMsgBox, TgLoadString(STID_CANT_GEN_DOM_NAMES_INI_ENTRY), ppsz_keys[i], gszDomainPathsSec, gszDomainIniFile); } else if (domainInResource) { sprintf(gszMsgBox, TgLoadString(STID_CANT_GEN_DOM_NAMES_XDEF), TOOL_NAME, "DomainPath", i); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_GEN_DOM_NAMES_XDEF), TOOL_NAME, "Domain", i); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); for ( ; head_ptr != NULL; head_ptr = next_dsp) { next_dsp = head_ptr->next; free(head_ptr); } if (ppsz_keys != NULL) { for (i=0; i < *pn_num_entries; i++) { tgFreeProfileString(ppsz_keys[i]); } free(ppsz_keys); } tgFreeProfileString(psz_path_in_ini); RestoreStatusStringsFromBuf(status_buf, one_line_status); return NULL; } dsp_ptr = (DspList*)malloc(sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, sizeof(DspList)); if (domainInIni) { if (name_only) { UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), ppsz_keys[i]); } else { sprintf(gszMsgBox, "%s=%s", ppsz_keys[i], psz_path_in_ini==NULL ? "" : psz_path_in_ini); UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), gszMsgBox); } tmpDomainName[i] = UtilStrDup(ppsz_keys[i]); tmpDomainPath[i] = UtilStrDup(psz_path_in_ini==NULL ? "" : psz_path_in_ini); if (tmpDomainName[i] == NULL || tmpDomainPath[i] == NULL) { FailAllocMessage(); } } else if ((c_ptr1=strchr(c_ptr, ':')) != NULL) { *c_ptr1 = '\0'; if (name_only) { UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), c_ptr); } else { sprintf(gszMsgBox, "%s=%s", c_ptr, &c_ptr1[1]); UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), gszMsgBox); } tmpDomainName[i] = UtilStrDup(c_ptr); tmpDomainPath[i] = UtilStrDup(&c_ptr1[1]); if (tmpDomainName[i] == NULL || tmpDomainPath[i] == NULL) { FailAllocMessage(); } *c_ptr1 = ':'; } else { if (name_only) { UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), c_ptr); } else { sprintf(gszMsgBox, "%s=", c_ptr); UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), gszMsgBox); } tmpDomainName[i] = UtilStrDup(c_ptr); tmpDomainPath[i] = UtilStrDup(""); if (tmpDomainName[i] == NULL || tmpDomainPath[i] == NULL) { FailAllocMessage(); } } /* do not translate -- program constants */ if (strcmp(tmpDomainName[i], "Examples") == 0) { seen_examples = TRUE; } tgFreeProfileString(psz_path_in_ini); } else if (seen_examples) { (*pn_num_entries)--; numTmpDomainNames--; break; } else { dsp_ptr = (DspList*)malloc(sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, sizeof(DspList)); /* do not translate -- program constants */ if (name_only) { UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), "Examples"); } else { sprintf(gszMsgBox, "Examples=%s", TGIF_PATH); UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), gszMsgBox); } tmpDomainName[i] = UtilStrDup("Examples"); tmpDomainPath[i] = UtilStrDup(TGIF_PATH); if (tmpDomainName[i] == NULL || tmpDomainPath[i] == NULL) { FailAllocMessage(); } } if (head_ptr == NULL) { head_ptr = tail_ptr = dsp_ptr; } else { p1 = NULL; for (p = head_ptr; p != NULL; p = p->next) { if (LargerStr(dsp_ptr->itemstr, p->itemstr)) { p1 = p; } else { break; } } dsp_ptr->next = p; if (p == NULL) { /* dsp_ptr has the largest element */ tail_ptr->next = dsp_ptr; tail_ptr = dsp_ptr; } else if (p1 == NULL) { head_ptr = dsp_ptr; } else { p1->next = dsp_ptr; } } } if (ppsz_keys != NULL) { for (i=0; i < *pn_num_entries; i++) { tgFreeProfileString(ppsz_keys[i]); } free(ppsz_keys); } RestoreStatusStringsFromBuf(status_buf, one_line_status); return head_ptr; } static int SelectDomain(SelStr) char *SelStr; { int i, index=INVALID, num_entries=0; char **entries=NULL; DspList *dsp_ptr=NULL, *next_dsp=NULL; if ((dsp_ptr=DomainListing(&num_entries, TRUE)) == NULL) { CleanUpTmpDomainName(); MsgBox(TgLoadString(STID_CANT_GET_LIST_OF_DOM_NAMES), TOOL_NAME, INFO_MB); *SelStr = '\0'; return INVALID; } entries = MakeNameDspItemArray(num_entries, dsp_ptr); if ((index=ChooseAName(TgLoadString(STID_PLEASE_SELECT_A_NEW_DOMAIN), entries, num_entries, INVALID)) == INVALID) { *SelStr = '\0'; } else { strcpy(SelStr, entries[index]); } for ( ; dsp_ptr != NULL; dsp_ptr = next_dsp) { next_dsp = dsp_ptr->next; free(dsp_ptr); } free(*entries); free(entries); Msg(""); index = INVALID; if (*SelStr != '\0' && num_entries > 0 && tmpDomainName != NULL) { for (i=0; i < num_entries; i++) { if (tmpDomainName[i] != NULL && strcmp(tmpDomainName[i],SelStr)==0) { index = i; break; } } } CleanUpTmpDomainName(); return index; } void ChangeDomain() { char *c_ptr=NULL, domain_name[MAXPATHLENGTH+1], env_str[MAXPATHLENGTH+1]; char s[MAXSTRING+1], s1[MAXSTRING+1], cap_tool_name[MAXSTRING+1]; int index=0; XEvent ev; *domain_name = '\0'; index = SelectDomain(domain_name); if (index == INVALID || *domain_name == '\0') return; XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } if (domainInIni) { char *pszPath=tgGetProfileString(gszDomainPathsSec, domain_name, gszDomainIniFile); if (pszPath != NULL) { ParseSymPath(pszPath); tgFreeProfileString(pszPath); } else if (strcmp(domain_name, "Examples") == 0) { ParseSymPath(TGIF_PATH); } else { ParseSymPath("."); } } else if (domainInResource) { sprintf(s, "DomainPath%1d", index); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,s)) != NULL) { char *c_ptr1; while (*c_ptr==' ' || *c_ptr=='\t' || *c_ptr=='\n') c_ptr++; if (*c_ptr != '\0' && (c_ptr1=strchr(c_ptr, ':')) != NULL) { c_ptr = &c_ptr1[1]; } ParseSymPath(c_ptr); } else if (strcmp(domain_name, "Examples") == 0) { ParseSymPath(TGIF_PATH); } else { ParseSymPath("."); } } else { strcpy(cap_tool_name, TOOL_NAME); UtilStrUpper(cap_tool_name); sprintf(env_str, "%s_%s", cap_tool_name, domain_name); if ((c_ptr=getenv(env_str)) == NULL) { if (strcmp(domain_name, "Examples") == 0) { ParseSymPath(TGIF_PATH); } else { ParseSymPath("."); } } else { ParseSymPath(c_ptr); } } UpdateSymInfo(); strcpy(curDomainName, domain_name); sprintf(s, TgLoadString(STID_CURRENT_DOMAIN_IS), curDomainName); sprintf(s1, TgLoadString(STID_SYMBOL_PATH_SET_TO), curDomainPath); TwoLineMsg(s, s1); RedrawTitleWindow(); } static char *oldDomain=NULL, *oldDir=NULL; static DspList *SymDirListing(pn_marked_index, pn_num_entries) int *pn_marked_index, *pn_num_entries; { int i, checking=FALSE; DspList *dsp_ptr, *head_ptr, *tail_ptr; *pn_marked_index = INVALID; if (oldDomain!=NULL && oldDir!=NULL && strcmp(oldDomain,curDomainName)==0) { checking = TRUE; } head_ptr = tail_ptr = NULL; for (i = 0; i < symPathNumEntries; i++) { dsp_ptr = (DspList*)malloc(sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, sizeof(DspList)); dsp_ptr->next = NULL; UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), symPath[i]); if (head_ptr == NULL) { head_ptr = tail_ptr = dsp_ptr; } else { tail_ptr->next = dsp_ptr; tail_ptr = dsp_ptr; } if (checking && strcmp(oldDir, symPath[i]) == 0) { checking = FALSE; *pn_marked_index = i; } } *pn_num_entries = symPathNumEntries; return head_ptr; } int SelectSymDir(SelStr) char *SelStr; { int index, num_entries=0, marked_index=INVALID; char **entries=NULL, msg[MAXSTRING+1]; DspList *dsp_ptr, *next_dsp; *SelStr = '\0'; if ((dsp_ptr=SymDirListing(&marked_index, &num_entries)) == NULL) { return INVALID; } entries = MakeLongNameDspItemArray(num_entries, dsp_ptr); sprintf(msg, TgLoadString(STID_PLS_SEL_A_DIR_IN_GIVEN_DOMAIN), curDomainName); if ((index=ChooseAName(msg, entries, num_entries, marked_index)) != INVALID) { strcpy(SelStr, entries[index]); if (oldDomain != NULL) free(oldDomain); if (oldDir != NULL) free(oldDir); oldDomain = (char*)malloc((strlen(curDomainName)+1)*sizeof(char)); if (oldDomain == NULL) FailAllocMessage(); oldDir = (char*)malloc((strlen(SelStr)+1)*sizeof(char)); if (oldDir == NULL) FailAllocMessage(); strcpy(oldDomain, curDomainName); strcpy(oldDir, SelStr); } for ( ; dsp_ptr != NULL; dsp_ptr = next_dsp) { next_dsp = dsp_ptr->next; free(dsp_ptr); } free(*entries); free(entries); Msg(""); return index; } static DspList *BitmapListing(ExtStr, OtherExtStr) char *ExtStr, *OtherExtStr; { int len, path_index, count = 0, reject, ext_len; char path[MAXPATHLENGTH], ext_str[MAXSTRING]; DspList *head_ptr=NULL, *tail_ptr=NULL; DIR *dirp=NULL; DIR_ENTRY *d=NULL; head_ptr = tail_ptr = NULL; sprintf(ext_str, ".%s", ExtStr); ext_len = strlen(ext_str); for (path_index=0; path_index < symPathNumEntries; path_index++) { strcpy(path, symPath[path_index]); if (strcmp(".", path) == 0) { if (curDirIsLocal) { strcpy(path, curDir); } else { strcpy(path, curLocalDir); } } if ((dirp=opendir(path)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_DIR_FOR_READING), path); Msg(gszMsgBox); continue; } while ((d=readdir(dirp)) != NULL) { len = strlen(d->d_name); if (!((len > ext_len && UtilStrICmp(ext_str,&d->d_name[len-ext_len]) == 0) || ExtensionMatch(OtherExtStr, d->d_name))) { continue; } if (head_ptr == NULL) { head_ptr = tail_ptr = (DspList*)malloc(sizeof(DspList)); if (head_ptr == NULL) FailAllocMessage(); memset(head_ptr, 0, sizeof(DspList)); UtilStrCpyN(head_ptr->itemstr, sizeof(head_ptr->itemstr), d->d_name); UtilStrCpyN(head_ptr->pathstr, sizeof(head_ptr->pathstr), path); } else { DspList *dsp_ptr=NULL, *p=NULL, *p1=NULL; p1 = NULL; reject = FALSE; for (p=head_ptr; p != NULL; p = p->next) { if (strcmp(d->d_name, p->itemstr) == 0) { reject = TRUE; break; } else if (LargerStr(d->d_name, p->itemstr)) { p1 = p; } else { break; } } if (reject) continue; dsp_ptr = (DspList*)malloc(sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, sizeof(DspList)); dsp_ptr->next = p; UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), d->d_name); UtilStrCpyN(dsp_ptr->pathstr, sizeof(dsp_ptr->pathstr), path); if (p == NULL) { /* dsp_ptr has the largest element */ tail_ptr->next = dsp_ptr; tail_ptr = dsp_ptr; } else if (p1 == NULL) { head_ptr = dsp_ptr; } else { p1->next = dsp_ptr; } } count++; } closedir(dirp); } numSymbols = count; return head_ptr; } int SelectFromLibrary(MsgStr, ExtStr, SelStr, PathStr) char *MsgStr, *ExtStr, *SelStr, *PathStr; { int index, num_entries=0; char **entries=NULL; char other_ext_str[MAXSTRING]; DspList *dsp_ptr, *next_dsp; *other_ext_str = '\0'; if (strcmp(ExtStr, XBM_FILE_EXT) == 0) { Msg(TgLoadString(STID_GEN_LIST_XBM_NAMES_WAIT)); } else if (strcmp(ExtStr, XPM_FILE_EXT) == 0) { Msg(TgLoadString(STID_GEN_LIST_XPM_NAMES_WAIT)); } else if (strcmp(ExtStr, OBJ_FILE_EXT) == 0) { Msg(TgLoadString(STID_GEN_LIST_OBJ_NAMES_WAIT)); sprintf(other_ext_str, ".%s;.%s", SYM_FILE_EXT, PIN_FILE_EXT); } else if (strcmp(ExtStr, SYM_FILE_EXT) == 0) { Msg(TgLoadString(STID_GEN_LIST_SYM_NAMES_WAIT)); sprintf(other_ext_str, ".%s", PIN_FILE_EXT); } else if (strcmp(ExtStr, EPSF_FILE_EXT) == 0) { sprintf(gszMsgBox, TgLoadString(STID_GEN_LIST_TYPE_FILE_NAMES_WAIT), "EPS"); sprintf(other_ext_str, ".%s;.epsi", PS_FILE_EXT); } else { sprintf(gszMsgBox, TgLoadString(STID_GEN_LIST_TYPE_FILE_NAMES_WAIT), ExtStr); Msg(gszMsgBox); sprintf(other_ext_str, ".GIF"); } if ((topOfSymLinkList=BitmapListing(ExtStr,other_ext_str)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_NO_GIVEN_TYPE_FILE_FOUND), ExtStr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *SelStr = *PathStr = '\0'; return INVALID; } BuildSymbolList(); num_entries = numSymbols; entries = MakeNameDspItemArray(num_entries, symbolList); if ((index=ChooseAName(MsgStr, entries, num_entries, INVALID)) == INVALID) { *SelStr = *PathStr = '\0'; } else { strcpy(SelStr, entries[index]); strcpy(PathStr, symbolList[index].pathstr); } for (dsp_ptr=topOfSymLinkList; dsp_ptr != NULL; dsp_ptr=next_dsp) { next_dsp = dsp_ptr->next; free(dsp_ptr); } free(*entries); free(entries); Msg(""); UpdateSymInfo(); return index; } void SetCurDir(FileName) char *FileName; { char file_name[MAXPATHLENGTH+1], *psz=NULL; strcpy(file_name, FileName); UtilShrinkName(file_name); if (curDirIsLocal && FileIsRemote(FileName)) { strcpy(curLocalDir, curDir); if (autoHyperSpaceOnRemote) { inHyperSpace = TRUE; Msg(TgLoadCachedString(CSTID_ENTERING_HYPERSPACE)); } } else if (!curDirIsLocal && !FileIsRemote(FileName)) { *curLocalDir = '\0'; } if ((psz=UtilStrRChr(file_name, DIR_SEP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_NO_DIR_SEP_IN_FUNC_WORK_DIR), "SetDurDir()", bootDir); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(curDir, bootDir); strcpy(curFileName, FileName); } else { *psz++ = '\0'; strcpy(curFileName, psz); strcpy(curDir, file_name); } curDirIsLocal = (!DirIsRemote(curDir)); RedrawDummyWindow1(); } void SetCurSymDir(FileName) char *FileName; { char file_name[MAXPATHLENGTH+1], *psz=NULL; strcpy(file_name, FileName); UtilShrinkName(file_name); if ((psz=UtilStrRChr(file_name, DIR_SEP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_NO_DIR_SEP_IN_FUNC_SYM_DIR), "SetDurSymDir()", bootDir); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(curSymDir, bootDir); strcpy(curFileName, FileName); } else { *psz++ = '\0'; strcpy(curFileName, psz); strcpy(curSymDir, file_name); } } void SetCurImportDir(FileName) char *FileName; { char file_name[MAXPATHLENGTH+1], *psz=NULL; strcpy(file_name, FileName); UtilShrinkName(file_name); if ((psz=UtilStrRChr(file_name, DIR_SEP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_NO_DIR_SEP_IN_FUNC_IMPORT_DIR), "SetDurImportir()", bootDir); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(curImportDir, bootDir); } else { *psz = '\0'; strcpy(curImportDir, file_name); } } /* ---------------------- Additional Domain Functions ---------------------- */ static DspList *FreeDspLinkedList(dsp_ptr) DspList *dsp_ptr; { DspList *next_dsp=NULL; for ( ; dsp_ptr != NULL; dsp_ptr=next_dsp) { next_dsp = dsp_ptr->next; free(dsp_ptr); } return NULL; } void CopyDomainInfoToIni() { int i=0, num_entries=0; DspList *dsp_ptr=NULL; tgWriteProfileString(gszDomainPathsSec, NULL, NULL, gszDomainIniFile); if ((dsp_ptr=DomainListing(&num_entries, TRUE)) == NULL) { CleanUpTmpDomainName(); return; } dsp_ptr = FreeDspLinkedList(dsp_ptr); for (i=0; i < num_entries; i++) { /* do not translate -- program constants */ if (strcmp(tmpDomainName[i], "Examples") != 0) { tgWriteProfileString(gszDomainPathsSec, tmpDomainName[i], tmpDomainPath[i], gszDomainIniFile); } } tgWriteProfileString(NULL, NULL, NULL, gszDomainIniFile); CleanUpTmpDomainName(); } static DspList *DomainListToDomainArray(dsp_ptr, num_entries, set_directory) DspList *dsp_ptr; int num_entries, set_directory; { int i=0; DspList *dsp_ptr1=NULL, *new_dsp=NULL, *pdl=NULL; new_dsp = (DspList*)malloc(num_entries*sizeof(DspList)); if (new_dsp == NULL) FailAllocMessage(); memset(new_dsp, 0, num_entries*sizeof(DspList)); for (i=0, pdl=new_dsp, dsp_ptr1=dsp_ptr; i < num_entries; i++, pdl++, dsp_ptr1=dsp_ptr1->next) { UtilStrCpyN(pdl->itemstr, sizeof(pdl->itemstr), dsp_ptr1->itemstr); /* use the directory field for inherited */ if (set_directory) pdl->directory = TRUE; pdl->next = (&pdl[1]); } new_dsp[num_entries-1].next = NULL; FreeDspLinkedList(dsp_ptr); return new_dsp; } static int EditDomainPathsAfterLoop(pp_dsp_ptr, ppsz_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, btn_id, selected_index, p_void) DspList **pp_dsp_ptr; char ***ppsz_entries, *cur_buf; int *pn_num_entries, *pn_marked_index, btn_id, selected_index; struct CheckArrayRec **pp_check_array; void *p_void; /* * Returns FALSE if the content of the dialogbox is acceptable and * the dialogbox will be closed. * Returns TRUE to tell the dialogbox to continue to loop. In this case, * this function should call MsgBox() to let the user know why * the dialogbox is not closed. */ { int i=0, num_entries=(*pn_num_entries); if (btn_id == BUTTON_CANCEL) { return FALSE; } for (i=0; i < num_entries; i++) { char *psz_key=(*ppsz_entries)[i], *psz_value=NULL; char *psz=strchr(psz_key, '='); *psz = '\0'; psz_value = UtilStrDup(&psz[1]); if (psz_value == NULL) FailAllocMessage(); *psz = '='; UtilTrimBlanks(psz_value); if (*psz_value == '\0') { int len=strlen(psz_key); if (len > 0 && psz_key[len-1] == '=') psz_key[len-1] = '\0'; sprintf(gszMsgBox, TgLoadString(STID_EMPTY_PATH_DISALLOW_FOR_DOM), psz_key); if (len > 0 && psz_key[len-1] == '\0') psz_key[len-1] = '='; MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); UtilFree(psz_value); return TRUE; } UtilFree(psz_value); } /* everything is fine */ return FALSE; } static int DoEditDomainPaths(psz_title, dsp_ptr, entries, num_entries, pf_after_loop) char *psz_title, **entries; DspList *dsp_ptr; int num_entries; AfterLoopFunc *pf_after_loop; { char win_name[128]; sprintf(win_name, TgLoadString(STID_TOOL_EDIT_DOM_PATHS), TOOL_NAME); ResetNamesInfo(); NamesSetTitle(psz_title); NamesAddButton(TgLoadCachedString(CSTID_OK), BUTTON_OK); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); /* ignore double-click and <CR> */ NamesSetDefaultBtnId(BUTTON_OK, INVALID); NamesSetStyle(NAMES_EDIT_ATTR, NAMES_LOOP_MANY); NamesSetCallback(NULL, pf_after_loop, NULL); NamesSetEntries(dsp_ptr, entries, num_entries, NULL, TRUE, INVALID, 0); return (Names(win_name, NULL, NULL, 0, NULL)==BUTTON_OK); } void EditDomainPaths() { int num_entries=0; DspList *dsp_ptr=NULL; char *pszKeys=NULL, **entries=NULL; if ((pszKeys=tgGetProfileString(gszDomainPathsSec, NULL, gszDomainIniFile)) == NULL) { CopyDomainInfoToIni(); } else { tgFreeProfileString(pszKeys); } if ((dsp_ptr=DomainListing(&num_entries, FALSE)) == NULL) { MsgBox(TgLoadString(STID_CANT_GET_LIST_OF_DOM_NAMES), TOOL_NAME, INFO_MB); return; } CleanUpTmpDomainName(); dsp_ptr = DomainListToDomainArray(dsp_ptr, num_entries, TRUE); ignoreDirectoryFlag = TRUE; entries = MakeNameDspItemArray(num_entries, dsp_ptr); ignoreDirectoryFlag = FALSE; if (DoEditDomainPaths(TgLoadString(STID_EDIT_DOMAIN_PATHS_DOTS), dsp_ptr, entries, num_entries, (AfterLoopFunc*)EditDomainPathsAfterLoop)) { int i=0; tgWriteProfileString(gszDomainPathsSec, NULL, NULL, gszDomainIniFile); for (i=0; i < num_entries; i++) { char *psz=strchr(entries[i], '='); *psz++ = '\0'; tgWriteProfileString(gszDomainPathsSec, entries[i], psz, gszDomainIniFile); } tgWriteProfileString(NULL, NULL, NULL, gszDomainIniFile); } free(dsp_ptr); free(*entries); free(entries); } static int DoSelectDefaultDomain(psz_title, dsp_ptr, entries, num_entries, selected_str, selected_str_sz) char *psz_title, **entries, *selected_str; DspList *dsp_ptr; int num_entries, selected_str_sz; { char win_name[128]; sprintf(win_name, TgLoadString(STID_TOOL_SEL_DEFAULT_DOMAIN), TOOL_NAME); ResetNamesInfo(); NamesSetTitle(psz_title); NamesAddButton(TgLoadCachedString(CSTID_OK), BUTTON_OK); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); /* ignore double-click and <CR> */ NamesSetDefaultBtnId(BUTTON_OK, BUTTON_OK); NamesSetStyle(NAMES_SIMPLE_SELECT_NAME, NAMES_LOOP_ONCE); NamesSetEntries(dsp_ptr, entries, num_entries, NULL, TRUE, INVALID, 0); return (Names(win_name, NULL, selected_str, selected_str_sz, NULL)==BUTTON_OK); } void SelectDefaultDomain() { int num_entries=0; DspList *dsp_ptr=NULL; char *pszKeys=NULL, **entries=NULL, selected_domain[MAXSTRING]; if ((pszKeys=tgGetProfileString(gszDomainPathsSec, NULL, gszDomainIniFile)) == NULL) { CopyDomainInfoToIni(); } else { tgFreeProfileString(pszKeys); } if ((dsp_ptr=DomainListing(&num_entries, TRUE)) == NULL) { MsgBox(TgLoadString(STID_CANT_GET_LIST_OF_DOM_NAMES), TOOL_NAME, INFO_MB); return; } CleanUpTmpDomainName(); dsp_ptr = DomainListToDomainArray(dsp_ptr, num_entries, FALSE); ignoreDirectoryFlag = TRUE; entries = MakeNameDspItemArray(num_entries, dsp_ptr); ignoreDirectoryFlag = FALSE; *selected_domain = '\0'; if (!DoSelectDefaultDomain(TgLoadString(STID_SEL_DEFAULT_DOMAIN_DOTS), dsp_ptr, entries, num_entries, selected_domain, sizeof(selected_domain))) { *selected_domain = '\0'; } free(dsp_ptr); free(*entries); free(entries); if (*selected_domain != '\0') { tgWriteProfileString(gszDefaultDomainSec, NULL, NULL, gszDomainIniFile); tgWriteProfileString(gszDefaultDomainSec, selected_domain, "", gszDomainIniFile); tgWriteProfileString(NULL, NULL, NULL, gszDomainIniFile); } } void AddADomain() { int num_entries=0; DspList *dsp_ptr=NULL; char *pszKeys=NULL, **entries=NULL, spec[MAXSTRING]; if ((pszKeys=tgGetProfileString(gszDomainPathsSec, NULL, gszDomainIniFile)) == NULL) { CopyDomainInfoToIni(); } else { tgFreeProfileString(pszKeys); } if ((dsp_ptr=DomainListing(&num_entries, TRUE)) == NULL) { MsgBox(TgLoadString(STID_CANT_GET_LIST_OF_DOM_NAMES), TOOL_NAME, INFO_MB); return; } CleanUpTmpDomainName(); dsp_ptr = DomainListToDomainArray(dsp_ptr, num_entries, FALSE); ignoreDirectoryFlag = TRUE; entries = MakeNameDspItemArray(num_entries, dsp_ptr); ignoreDirectoryFlag = FALSE; *spec = '\0'; if (Dialog(TgLoadString(STID_PLS_SPEC_A_NEW_DOMAIN_NAME), NULL, spec) != INVALID) { UtilTrimBlanks(spec); if (*spec != '\0') { int i=0, dup_found=FALSE; for (i=0; i < num_entries; i++) { if (UtilStrICmp(dsp_ptr[i].itemstr, spec) == 0) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_DOMAIN_ALREADY_EXISTS), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); dup_found = TRUE; break; } } if (!dup_found) { tgWriteProfileString(gszDomainPathsSec, spec, ".", gszDomainIniFile); tgWriteProfileString(NULL, NULL, NULL, gszDomainIniFile); sprintf(gszMsgBox, TgLoadString(STID_GIVEN_DOM_ADDED_PATH_SET_TO), spec, "."); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } } free(dsp_ptr); free(*entries); free(entries); } void DeleteADomain() { int num_entries=0; DspList *dsp_ptr=NULL; char *pszKeys=NULL, **entries=NULL, selected_domain[MAXSTRING]; if ((pszKeys=tgGetProfileString(gszDomainPathsSec, NULL, gszDomainIniFile)) == NULL) { CopyDomainInfoToIni(); } else { tgFreeProfileString(pszKeys); } if ((dsp_ptr=DomainListing(&num_entries, TRUE)) == NULL) { MsgBox(TgLoadString(STID_CANT_GET_LIST_OF_DOM_NAMES), TOOL_NAME, INFO_MB); return; } CleanUpTmpDomainName(); dsp_ptr = DomainListToDomainArray(dsp_ptr, num_entries, FALSE); ignoreDirectoryFlag = TRUE; entries = MakeNameDspItemArray(num_entries, dsp_ptr); ignoreDirectoryFlag = FALSE; *selected_domain = '\0'; if (!DoSelectDefaultDomain(TgLoadString(STID_SEL_DOMAIN_TO_DELETE_DOTS), dsp_ptr, entries, num_entries, selected_domain, sizeof(selected_domain))) { *selected_domain = '\0'; } free(dsp_ptr); free(*entries); free(entries); if (*selected_domain != '\0') { sprintf(gszMsgBox, TgLoadString(STID_OK_TO_DELETE_NAMED_DOMAIN_YNC), selected_domain); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) == MB_ID_YES) { tgWriteProfileString(gszDomainPathsSec, selected_domain, NULL, gszDomainIniFile); tgWriteProfileString(NULL, NULL, NULL, gszDomainIniFile); } } } void ReloadDomainInfoFromX() { if (MsgBox(TgLoadString(STID_OK_TO_RELOAD_DOM_INFO_FROM_X), TOOL_NAME, YNC_MB) == MB_ID_YES) { tgWriteProfileString(gszDefaultDomainSec, NULL, NULL, gszDomainIniFile); tgWriteProfileString(gszDomainPathsSec, NULL, NULL, gszDomainIniFile); tgWriteProfileString(NULL, NULL, NULL, gszDomainIniFile); InitDomain(); CopyDomainInfoToIni(); tgWriteProfileString(gszDefaultDomainSec, curDomainName, "", gszDomainIniFile); tgWriteProfileString(NULL, NULL, NULL, gszDomainIniFile); } } int RefreshDomainMenu(menu) TgMenu *menu; { int ok=TRUE; /* EditDomainPaths */ ok &= TgEnableMenuItemById(menu, CMDID_EDITDOMAINPATHS, domainInIni); /* SelectDefaultDomain */ ok &= TgEnableMenuItemById(menu, CMDID_SELECTDEFAULTDOMAIN, domainInIni); /* AddADomain */ ok &= TgEnableMenuItemById(menu, CMDID_ADDADOMAIN, domainInIni); /* DeleteADomain */ ok &= TgEnableMenuItemById(menu, CMDID_DELETEADOMAIN, domainInIni); /* ReloadDomainInfoFromX */ ok &= TgEnableMenuItemById(menu, CMDID_RELOADDOMAININFOFROMX, domainInIni); return ok; } TgMenu *CreateDomainMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { menu->track_menubar = TRUE; if (!RefreshDomainMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshDomainMenu); } return menu; } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/nkf.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000000000�11602233314�013676� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tdgtsedt.c���������������������������������������������������������������������������0000644�0000764�0000764�00000046575�11602233313�014774� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtsedt.c,v 1.11 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TDGTSEDT_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "tidget.h" #include "auxtext.e" #include "choose.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "font.e" #include "inmethod.e" #include "menu.e" #include "msg.e" #include "raster.e" #include "rect.e" #include "setup.e" #include "tdgtbase.e" #include "tdgtsedt.e" #include "text.e" #include "tidget.e" #include "util.e" static void RedrawTdgtSmplEdit ARGS_DECL((TidgetInfo *pti)); static int TdgtSmplEditEventHandler ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo *handling_pti)); static int IsTdgtSmplEditEvent ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo **ppti_handler_tidget_return)); static void DestroyTdgtSmplEdit ARGS_DECL((TidgetInfo *pti)); static void MapTdgtSmplEdit ARGS_DECL((TidgetInfo *pti)); static void TdgtSmplEditMoveResize ARGS_DECL((TidgetInfo *pti, int x, int y, int w, int h)); static int TdgtSmplEditSendCmd ARGS_DECL((TidgetInfo *pti, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); /* --------------------- Utility Functions --------------------- */ /* --------------------- RedrawTdgtSmplEdit() --------------------- */ #define RIGHT_GAP 2 static char *TdgtSmplEditBinarySearch(caption, len, max_w, font_ptr, pf_text_width_func) char *caption; int len, max_w; XFontStruct *font_ptr; TidgetMsgTextWidthFunc *pf_text_width_func; { /* * When &caption[too_long-1] is too long and &caption[too_long] is not * long enough, return &caption[too_long]. */ int prev_too_long=INVALID, too_long=0, too_short=len, found=FALSE; while (!found) { int w=0; if (too_short < too_long) { #ifdef _TGIF_DBG /* debug, do not translate */ sprintf(gszMsgBox, "Programing error in TdgtSmplEditBinarySearch()!\n"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); #endif /* _TGIF_DBG */ } if (too_short-too_long <= 4) { w = (pf_text_width_func)(font_ptr, &caption[too_long], len-too_long); if (w > max_w) { prev_too_long = too_long; too_long++; } else { return (&caption[too_long]); } } else { int mid=((too_long+too_short)>>1); w = (pf_text_width_func)(font_ptr, &caption[mid], len-mid); if (w > max_w) { too_long = mid; } else { too_short = mid; } } } return caption; } static void TdgtSmplEditDrawCaption(pTdgtSmplEdit) TdgtSmplEdit *pTdgtSmplEdit; { int x=pTdgtSmplEdit->client_area.x, y=pTdgtSmplEdit->client_area.y, w=0; int font_asc=0, client_area_w=pTdgtSmplEdit->client_area.w; char *caption=TdgtSmplEditGetText(pTdgtSmplEdit), *psz_start=NULL; XFontStruct *font_ptr=NULL; TidgetDrawMsgStringFunc *pf_draw_string_func=NULL; TidgetMsgTextWidthFunc *pf_text_width_func=NULL; if (caption == NULL) return; TidgetGetFontInfoGivenStyle(pTdgtSmplEdit->font_style, &font_ptr, NULL, NULL, &font_asc, NULL); y += font_asc; switch (pTdgtSmplEdit->font_style) { case STYLE_NR: if (msgFontPtr != NULL) { XSetFont(mainDisplay, gTidgetManager.gc, msgFontPtr->fid); } pf_draw_string_func = DrawMsgString; pf_text_width_func = MsgTextWidth; break; case STYLE_BR: if (boldMsgFontPtr != NULL) { XSetFont(mainDisplay, gTidgetManager.gc, boldMsgFontPtr->fid); } pf_draw_string_func = DrawBoldMsgString; pf_text_width_func = BoldMsgTextWidth; break; case STYLE_NI: if (italicMsgFontPtr != NULL) { XSetFont(mainDisplay, gTidgetManager.gc, italicMsgFontPtr->fid); } pf_draw_string_func = DrawItalicMsgString; pf_text_width_func = ItalicMsgTextWidth; break; case STYLE_BI: if (boldItalicMsgFontPtr != NULL) { XSetFont(mainDisplay, gTidgetManager.gc, boldItalicMsgFontPtr->fid); } pf_draw_string_func = DrawBoldItalicMsgString; pf_text_width_func = BoldItalicMsgTextWidth; break; } w = (pf_text_width_func)(font_ptr, caption, strlen(caption)); if (w > client_area_w-RIGHT_GAP) { psz_start = TdgtSmplEditBinarySearch(caption, strlen(caption), client_area_w-RIGHT_GAP, font_ptr, pf_text_width_func); } else { psz_start = caption; } if (pTdgtSmplEdit->color_index == INVALID) { XSetForeground(mainDisplay, gTidgetManager.gc, myFgPixel); } else { XSetForeground(mainDisplay, gTidgetManager.gc, colorPixels[pTdgtSmplEdit->color_index]); } (pf_draw_string_func)(mainDisplay, pTdgtSmplEdit->pti->tci.win, gTidgetManager.gc, x, y, psz_start, strlen(psz_start)); if (TidgetIsFocus(pTdgtSmplEdit->pti)) { x = (pf_text_width_func)(font_ptr, psz_start, strlen(psz_start)) + pTdgtSmplEdit->client_area.x; XSetForeground(mainDisplay, gTidgetManager.gc, myFgPixel); XDrawLine(mainDisplay, pTdgtSmplEdit->pti->tci.win, gTidgetManager.gc, x+1, pTdgtSmplEdit->client_area.y+1, x+1, pTdgtSmplEdit->client_area.y+pTdgtSmplEdit->client_area.h-1); TidgetDrawFocusRect(pTdgtSmplEdit->pti, &pTdgtSmplEdit->client_area); } TidgetManagerResetGC(); } static void RedrawTdgtSmplEdit(pti) TidgetInfo *pti; { TdgtSmplEdit *pTdgtSmplEdit=(TdgtSmplEdit*)(pti->tidget); XClearWindow(mainDisplay, pTdgtSmplEdit->pti->tci.win); if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, pTdgtSmplEdit->pti->tci.win_info.w, pTdgtSmplEdit->pti->tci.win_info.h); switch (pTdgtSmplEdit->pti->tci.state) { case TGBS_NORMAL: break; default: TgDrawThreeDButton(mainDisplay, pTdgtSmplEdit->pti->tci.win, gTidgetManager.gc, &bbox, pTdgtSmplEdit->pti->tci.state, 2, FALSE); TidgetManagerResetGC(); break; } } else { /* * XDrawRectangle(mainDisplay, pTdgtSmplEdit->pti->tci.win, * gTidgetManager.gc, 0, 0, pTdgtSmplEdit->pti->tci.win_info.w, * pTdgtSmplEdit->pti->tci.win_info.h); */ } TdgtSmplEditDrawCaption(pTdgtSmplEdit); } /* --------------------- TdgtSmplEditEventHandler() --------------------- */ static XComposeStatus c_stat; static int TdgtSmplEditEventHandler(pti, input, handling_pti) TidgetInfo *pti, *handling_pti; XEvent *input; { TdgtSmplEdit *pTdgtSmplEdit=(TdgtSmplEdit*)(pti->tidget); if (pti != handling_pti) return FALSE; if (input->type == Expose) { XEvent ev; RedrawTdgtSmplEdit(pTdgtSmplEdit->pti); while (XCheckWindowEvent(mainDisplay, pTdgtSmplEdit->pti->tci.win, ExposureMask, &ev)) ; } else if (input->type == KeyPress) { int has_ch=0; char buf[80]; KeySym key_sym=(KeySym)0; XKeyEvent *key_ev=(&(input->xkey)); if (gnInputMethod != TGIM_NONE && /* * Cannot call: InputMethodTypeMatched(canvasFontDoubleByte) && */ tgIMExpectLookupString(mainDisplay, pTdgtSmplEdit->pti->tci.win)) { if (tgIMHandleLookupString(mainDisplay, pTdgtSmplEdit->pti->tci.win, key_ev, buf, sizeof(buf), &key_sym, &has_ch)) { if (has_ch > 0) buf[has_ch] = '\0'; has_ch = HandleDoubleByteUTF8Chars(buf, has_ch); } TranslateKeys(buf, &key_sym); } else { has_ch = XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); if (has_ch > 0) buf[has_ch] = '\0'; if (gnInputMethod != TGIM_NONE) { char s1[80]; *s1 = '\0'; if (tgIMTranslateKeyEvent(mainDisplay, mainWindow, key_ev, s1)) { strcpy(buf, s1); /* added by Ambrose Li <acli@mingpaoxpress.com> */ key_sym = (KeySym)0; } if (tgIMExpectClientMessage(mainDisplay, mainWindow)) { /* input characters only come from ClientMessage */ return FALSE; } } else { TranslateKeys(buf, &key_sym); } } if (CharIsCRorLF(key_ev, buf, key_sym, &has_ch)) { TidgetControlNotify(pTdgtSmplEdit->pti, TDGTNF_EDIT_ENTERED, 0, 0); return TRUE; } else if (CharIsBS(key_ev, buf, key_sym, &has_ch, FALSE)) { TdgtSmplEditDelLastChar(pTdgtSmplEdit); return TRUE; } else if (key_sym>='\040' && key_sym<='\377') { TdgtSmplEditAppendStr(pTdgtSmplEdit, buf, 1); return TRUE; } } else if (input->type == ButtonPress) { if (pTdgtSmplEdit->cursor_shown) { /* already has focus, don't do anythingn */ } else { TdgtBase *pTdgtBase= (TdgtBase*)(pTdgtSmplEdit->pti->tci.parent_tidgetinfo->tidget); if (TidgetSendCmd(pTdgtBase->pti, TDGTCMD_CAN_HANDLE_FOCUS_CHANGE, 0, NULL)) { TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); } TdgtSmplEditSetFocus(pTdgtSmplEdit, TRUE); } } return FALSE; } /* --------------------- IsTdgtSmplEditEvent() --------------------- */ static int IsTdgtSmplEditEvent(pti, input, ppti_handler_tidget_return) TidgetInfo *pti, **ppti_handler_tidget_return; XEvent *input; { TdgtSmplEdit *pTdgtSmplEdit=(TdgtSmplEdit*)(pti->tidget); if (input->xany.window == pTdgtSmplEdit->pti->tci.win) { *ppti_handler_tidget_return = pti; return TRUE; } return FALSE; } /* --------------------- DestroyTdgtSmplEdit() --------------------- */ static void DestroyTdgtSmplEdit(pti) TidgetInfo *pti; { TdgtSmplEdit *pTdgtSmplEdit=(TdgtSmplEdit*)(pti->tidget); TdgtSmplEditReset(pTdgtSmplEdit); free(pTdgtSmplEdit); } /* --------------------- MapTdgtSmplEdit() --------------------- */ static void MapTdgtSmplEdit(pti) TidgetInfo *pti; { TdgtSmplEdit *pTdgtSmplEdit=(TdgtSmplEdit*)(pti->tidget); #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, pTdgtSmplEdit->pti->tci.win); XSelectInput(mainDisplay, pTdgtSmplEdit->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); #else XSelectInput(mainDisplay, pTdgtSmplEdit->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, pTdgtSmplEdit->pti->tci.win); #endif } /* --------------------- TdgtSmplEditMoveResize() --------------------- */ static void TdgtSmplEditMoveResize(pti, x, y, w, h) TidgetInfo *pti; int x, y, w, h; { TdgtSmplEdit *pTdgtSmplEdit=(TdgtSmplEdit*)(pti->tidget); int h_pad=pti->tci.h_pad, v_pad=pti->tci.v_pad; /* there should be no need to resize a button */ pTdgtSmplEdit->pti->tci.win_info.x = x; pTdgtSmplEdit->pti->tci.win_info.y = y; pTdgtSmplEdit->pti->tci.win_info.w = w; pTdgtSmplEdit->pti->tci.win_info.h = h; XMoveResizeWindow(mainDisplay, pTdgtSmplEdit->pti->tci.win, x, y, w, h); pTdgtSmplEdit->client_area.x = windowPadding + h_pad; pTdgtSmplEdit->client_area.y = windowPadding + v_pad; pTdgtSmplEdit->client_area.w = w-(windowPadding<<1)-(h_pad<<1); pTdgtSmplEdit->client_area.h = h-(windowPadding<<1)-(v_pad<<1); } /* --------------------- TdgtSmplEditSendCmd() --------------------- */ static int TdgtSmplEditSendCmd(pti, cmd_type, cmd_arg, pv_cmd_userdata) TidgetInfo *pti; int cmd_type, cmd_arg; void *pv_cmd_userdata; { TdgtSmplEdit *pTdgtSmplEdit=(TdgtSmplEdit*)(pti->tidget); if (pTdgtSmplEdit != NULL) { } return FALSE; } /* --------------------- TdgtSmplEditReset() --------------------- */ void TdgtSmplEditReset(pTdgtSmplEdit) TdgtSmplEdit *pTdgtSmplEdit; { FreeDynStrBuf(&(pTdgtSmplEdit->pti->tci.dyn_str)); } /* --------------------- CreateTdgtSmplEdit() --------------------- */ static void TdgtSmplEditCalcHeight(font_style, pn_content_h) int font_style, *pn_content_h; { int font_height=0; TidgetGetFontInfoGivenStyle(font_style, NULL, NULL, &font_height, NULL, NULL); if (pn_content_h != NULL) *pn_content_h = font_height; } TdgtSmplEdit *CreateTdgtSmplEdit(parent_win, parent_tidgetinfo, ctl_id, x, y, content_w, h_pad, v_pad, caption, font_style, color_index) Window parent_win; TidgetInfo *parent_tidgetinfo; int ctl_id, x, y, content_w, h_pad, v_pad, font_style, color_index; char *caption; { int w=0, h=0, content_h=0; TdgtSmplEdit *pTdgtSmplEdit=NULL; TdgtSmplEditCalcHeight(font_style, &content_h); w = content_w + (windowPadding<<1) + (h_pad<<1); h = content_h + (windowPadding<<1) + (v_pad<<1); pTdgtSmplEdit = (TdgtSmplEdit*)malloc(sizeof(TdgtSmplEdit)); if (pTdgtSmplEdit == NULL) FailAllocMessage(); memset(pTdgtSmplEdit, 0, sizeof(TdgtSmplEdit)); pTdgtSmplEdit->pti = NewTidgetInfo(parent_tidgetinfo, TIDGET_TYPE_SEDT, pTdgtSmplEdit, ctl_id, NULL); if ((pTdgtSmplEdit->pti->tci.win=XCreateSimpleWindow(mainDisplay, parent_win, x, y, w, h, brdrW, myBorderPixel, myBgPixel)) == 0) { FailToCreateWindowMessage("CreateTdgtSmplEdit()", NULL, TRUE); return NULL; } XSelectInput(mainDisplay, pTdgtSmplEdit->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); SetTidgetInfoBasic(pTdgtSmplEdit->pti, TIDGET_TYPE_SEDT, pTdgtSmplEdit, parent_win, x, y, w, h, h_pad, v_pad, TGBS_LOWRED, caption); TidgetSetCallbacks(pTdgtSmplEdit->pti, RedrawTdgtSmplEdit, TdgtSmplEditEventHandler, IsTdgtSmplEditEvent, DestroyTdgtSmplEdit, MapTdgtSmplEdit, TdgtSmplEditMoveResize, TdgtSmplEditSendCmd); pTdgtSmplEdit->client_area.x = windowPadding + h_pad; pTdgtSmplEdit->client_area.y = windowPadding + v_pad; pTdgtSmplEdit->client_area.w = w-(windowPadding<<1)-(h_pad<<1); pTdgtSmplEdit->client_area.h = h-(windowPadding<<1)-(v_pad<<1); pTdgtSmplEdit->font_style = font_style; pTdgtSmplEdit->color_index = color_index; return pTdgtSmplEdit; } /* --------------------- TdgtSmplEditSetText() --------------------- */ int TdgtSmplEditSetText(pTdgtSmplEdit, str) TdgtSmplEdit *pTdgtSmplEdit; char *str; { int len=strlen(str); if (len+1 == pTdgtSmplEdit->pti->tci.dyn_str.sz && strcmp(str, pTdgtSmplEdit->pti->tci.dyn_str.s) == 0) { /* same string, no change */ return FALSE; } FreeDynStrBuf(&(pTdgtSmplEdit->pti->tci.dyn_str)); if (str != NULL) { DynStrSet(&(pTdgtSmplEdit->pti->tci.dyn_str), str); } RedrawTdgtSmplEdit(pTdgtSmplEdit->pti); return TRUE; } /* --------------------- TdgtSmplEditGetText() --------------------- */ char *TdgtSmplEditGetText(pTdgtSmplEdit) TdgtSmplEdit *pTdgtSmplEdit; { return pTdgtSmplEdit->pti->tci.dyn_str.s; } /*--------------------- TdgtSmplEditGetTextFormatInfo() -------------------- */ void TdgtSmplEditGetTextFormatInfo(pTdgtSmplEdit, pTextFormatInfo) TdgtSmplEdit *pTdgtSmplEdit; TextFormatInfo *pTextFormatInfo; { if (pTextFormatInfo != NULL) { pTextFormatInfo->font_style = pTdgtSmplEdit->font_style; pTextFormatInfo->color_index = pTdgtSmplEdit->color_index; if (pTextFormatInfo->color_index == INVALID) { *pTextFormatInfo->color_str = '\0'; } else { UtilStrCpyN(pTextFormatInfo->color_str, sizeof(pTextFormatInfo->color_str), colorMenuItems[pTextFormatInfo->color_index]); } } } /* --------------------- TdgtSmplEditSetColorIndex() --------------------- */ int TdgtSmplEditSetColorIndex(pTdgtSmplEdit, color_index) TdgtSmplEdit *pTdgtSmplEdit; int color_index; { int prev_color_index=pTdgtSmplEdit->color_index; if (prev_color_index != color_index) { pTdgtSmplEdit->color_index = color_index; RedrawTdgtSmplEdit(pTdgtSmplEdit->pti); } return prev_color_index; } /* --------------------- TdgtSmplEditGetColorIndex() --------------------- */ int TdgtSmplEditGetColorIndex(pTdgtSmplEdit) TdgtSmplEdit *pTdgtSmplEdit; { return pTdgtSmplEdit->color_index; } /* --------------------- TdgtSmplEditSetFontStyle() --------------------- */ int TdgtSmplEditSetFontStyle(pTdgtSmplEdit, font_style) TdgtSmplEdit *pTdgtSmplEdit; int font_style; { int prev_font_style=pTdgtSmplEdit->font_style; if (prev_font_style != font_style) { pTdgtSmplEdit->font_style = font_style; RedrawTdgtSmplEdit(pTdgtSmplEdit->pti); } return prev_font_style; } /* --------------------- TdgtSmplEditGetFontStyle() --------------------- */ int TdgtSmplEditGetFontStyle(pTdgtSmplEdit) TdgtSmplEdit *pTdgtSmplEdit; { return pTdgtSmplEdit->font_style; } /* --------------------- TdgtSmplEditAppendStr() --------------------- */ int TdgtSmplEditAppendStr(pTdgtSmplEdit, buf, len) TdgtSmplEdit *pTdgtSmplEdit; char *buf; int len; /* return TRUE if something changed */ { char *psz=NULL; if (len == 0 || *buf == '\0') return FALSE; /* Note: dyn_str.sz includes the '\0' */ psz = (char*)malloc(pTdgtSmplEdit->pti->tci.dyn_str.sz+len); if (psz == NULL) FailAllocMessage(); strcpy(psz, pTdgtSmplEdit->pti->tci.dyn_str.s); strncpy(&psz[pTdgtSmplEdit->pti->tci.dyn_str.sz-1], buf, len); psz[pTdgtSmplEdit->pti->tci.dyn_str.sz-1+len] = '\0'; DynStrSet(&(pTdgtSmplEdit->pti->tci.dyn_str), psz); free(psz); RedrawTdgtSmplEdit(pTdgtSmplEdit->pti); return TRUE; } /* --------------------- TdgtSmplEditDelLastChar() --------------------- */ int TdgtSmplEditDelLastChar(pTdgtSmplEdit) TdgtSmplEdit *pTdgtSmplEdit; /* return TRUE if something changed */ { int len=pTdgtSmplEdit->pti->tci.dyn_str.sz-1; if (len <= 0) return FALSE; pTdgtSmplEdit->pti->tci.dyn_str.s[len-1] = '\0'; pTdgtSmplEdit->pti->tci.dyn_str.sz = len; RedrawTdgtSmplEdit(pTdgtSmplEdit->pti); return TRUE; } /* --------------------- TdgtSmplEditSetFocus() --------------------- */ static int TdgtSmplEditShowCursor(pTdgtSmplEdit, show) TdgtSmplEdit *pTdgtSmplEdit; int show; /* return TRUE if changed */ { if (pTdgtSmplEdit->cursor_shown != show) { pTdgtSmplEdit->cursor_shown = show; return TRUE; } return FALSE; } void TdgtSmplEditSetFocus(pTdgtSmplEdit, nSet) TdgtSmplEdit *pTdgtSmplEdit; int nSet; { if (TdgtSmplEditShowCursor(pTdgtSmplEdit, nSet)) { if (nSet) { TidgetSetHasFocus(TRUE); TidgetSetFocusWindow(pTdgtSmplEdit->pti->tci.win); } else { TidgetSetHasFocus(FALSE); TidgetSetFocusWindow(None); } RedrawTdgtSmplEdit(pTdgtSmplEdit->pti); } } /* --------------------- Init & Clean Up --------------------- */ int InitTdgtSmplEdit() { return TRUE; } void CleanUpTdgtSmplEdit() { } �����������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/button.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000020645�11602233310�014450� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/button.c,v 1.6 2011/05/16 16:21:56 william Exp $ */ #define _INCLUDE_FROM_BUTTON_C_ #include "tgifdefs.h" #include "auxtext.e" #include "box.e" #include "button.e" #include "cursor.e" #include "file.e" #include "font.e" #include "mainloop.e" #include "mainmenu.e" #include "menu.e" #include "msg.e" #include "raster.e" #include "rect.e" #include "setup.e" #define BTN_DEFAULT_FONT 0 #define BTN_MSG_FONT 1 #define BTN_BOLD_MSG_FONT 2 #define BTN_ITALIC_MSG_FONT 3 #define BTN_BOLD_ITALIC_MSG_FONT 4 static int GetButtonFontStyle(pButtonFontInfo) ButtonFontInfo *pButtonFontInfo; { int font_style=INVALID; if (pButtonFontInfo == NULL) { if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { font_style = BTN_DEFAULT_FONT; } else { font_style = BTN_BOLD_MSG_FONT; } } else { switch (pButtonFontInfo->font_style) { case STYLE_NR: font_style = BTN_MSG_FONT; break; case STYLE_BR: if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { font_style = BTN_MSG_FONT; } else { font_style = BTN_BOLD_MSG_FONT; } break; case STYLE_NI: if (italicMsgFontSet == NULL && italicMsgFontPtr == NULL) { font_style = BTN_MSG_FONT; } else { font_style = BTN_ITALIC_MSG_FONT; } break; case STYLE_BI: if (boldItalicMsgFontSet == NULL && boldItalicMsgFontPtr == NULL) { font_style = BTN_MSG_FONT; } else { font_style = BTN_BOLD_ITALIC_MSG_FONT; } break; default: break; } } return font_style; } int ButtonWidth(Str, MinLen, pButtonFontInfo) char *Str; int MinLen; ButtonFontInfo *pButtonFontInfo; { int len=strlen(Str); if (pButtonFontInfo != NULL) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "ButtonWidth() is called with pButtonFontInfo != NULL\n"); #endif /* _TGIF_DBG */ } if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { return (defaultFontWidth * max(len+2, MinLen)); } else if (len > MinLen-2) { char buf[40]; int len1=0, len2=0; /* do not translate -- the string is used to measure things */ sprintf(buf, " %s ", Str); len1 = 4+BoldMsgTextWidth(boldMsgFontPtr, buf, len+4); len2 = 4+BoldMsgTextWidth(boldMsgFontPtr, " CANCEL ", 10); return max(len1,len2); } else { /* do not translate -- the string is used to measure things */ return 4+BoldMsgTextWidth(boldMsgFontPtr, " CANCEL ", 10); } } #define BTN_Y_MARGIN 2 void DisplayButtonInBBox(Win, Str, Len, BBox, Normal, HighLight, Width, pButtonFontInfo) Window Win; char *Str; int Len, HighLight, Width; struct BBRec *BBox; int Normal; ButtonFontInfo *pButtonFontInfo; /* Display a button in Win at location ((*BBox).ltx,(*BBox).lty), Str is */ /* centered in the button. The width of the button is given in BBox. */ /* Len must be strlen(Str) */ /* If HighLight is TRUE, Width is used to draw an outline around the box. */ { int button_w=0, button_h=0, left=0, top=0, text_w=0; int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); int btn_font_style=INVALID; button_w = BBox->rbx - BBox->ltx; button_h = BBox->rby - BBox->lty; btn_font_style = GetButtonFontStyle(pButtonFontInfo); switch (btn_font_style) { case BTN_DEFAULT_FONT: text_w = defaultFontWidth * Len; top = ((button_h - defaultFontHeight)>>1); break; case BTN_MSG_FONT: text_w = BoldMsgTextWidth(msgFontPtr, Str, Len); top = ((button_h - msgFontHeight)>>1); break; case BTN_BOLD_MSG_FONT: text_w = BoldMsgTextWidth(boldMsgFontPtr, Str, Len); top = ((button_h - boldMsgFontHeight)>>1); break; case BTN_ITALIC_MSG_FONT: text_w = BoldMsgTextWidth(italicMsgFontPtr, Str, Len); top = ((button_h - italicMsgFontHeight)>>1); break; case BTN_BOLD_ITALIC_MSG_FONT: text_w = BoldMsgTextWidth(boldItalicMsgFontPtr, Str, Len); top = ((button_h - boldItalicMsgFontHeight)>>1); break; } left = ((button_w - text_w)>>1); XSetForeground(mainDisplay, defaultGC, (Normal ? bg_pixel : myFgPixel)); XFillRectangle(mainDisplay, Win, defaultGC, BBox->ltx, BBox->lty, button_w, button_h); XSetForeground(mainDisplay, defaultGC, myFgPixel); if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, BBox->ltx, BBox->lty-windowPadding, BBox->ltx+button_w, BBox->lty+button_h+windowPadding); TgDrawThreeDButton(mainDisplay, Win, textMenuGC, &bbox, (Normal ? TGBS_RAISED : TGBS_LOWRED), 2, Normal); } else { XDrawRectangle(mainDisplay, Win, defaultGC, BBox->ltx, BBox->lty, button_w, button_h); } if (!Normal) { XSetForeground(mainDisplay, defaultGC, myBgPixel); } if (pButtonFontInfo == NULL) { if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { DrawBoldMsgString(mainDisplay, Win, defaultGC, BBox->ltx+left, BBox->lty+defaultFontAsc+BTN_Y_MARGIN, Str, Len); } else { if (boldMsgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, boldMsgFontPtr->fid); } DrawBoldMsgString(mainDisplay, Win, defaultGC, BBox->ltx+left, BBox->lty+boldMsgFontAsc+BTN_Y_MARGIN, Str, Len); XSetFont(mainDisplay, defaultGC, defaultFontPtr->fid); } } else { switch (btn_font_style) { case BTN_DEFAULT_FONT: if (defaultFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, defaultFontPtr->fid); } DrawMsgString(mainDisplay, Win, defaultGC, BBox->ltx+left, BBox->lty+defaultFontAsc+BTN_Y_MARGIN, Str, Len); break; case BTN_MSG_FONT: if (msgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, msgFontPtr->fid); } DrawMsgString(mainDisplay, Win, defaultGC, BBox->ltx+left, BBox->lty+msgFontAsc+BTN_Y_MARGIN, Str, Len); break; case BTN_BOLD_MSG_FONT: if (boldMsgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, boldMsgFontPtr->fid); } DrawBoldMsgString(mainDisplay, Win, defaultGC, BBox->ltx+left, BBox->lty+boldMsgFontAsc+BTN_Y_MARGIN, Str, Len); break; case BTN_ITALIC_MSG_FONT: if (italicMsgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, italicMsgFontPtr->fid); } DrawItalicMsgString(mainDisplay, Win, defaultGC, BBox->ltx+left, BBox->lty+italicMsgFontAsc+BTN_Y_MARGIN, Str, Len); break; case BTN_BOLD_ITALIC_MSG_FONT: if (boldItalicMsgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, boldItalicMsgFontPtr->fid); } DrawBoldItalicMsgString(mainDisplay, Win, defaultGC, BBox->ltx+left, BBox->lty+boldItalicMsgFontAsc+BTN_Y_MARGIN, Str, Len); break; } XSetFont(mainDisplay, defaultGC, defaultFontPtr->fid); } if (!Normal) { XSetForeground(mainDisplay, defaultGC, myFgPixel); } if (HighLight) { if (threeDLook) { XSetForeground(mainDisplay, defaultGC, myBorderPixel); XDrawRectangle(mainDisplay, Win, defaultGC, BBox->ltx-1, BBox->lty-windowPadding-1, button_w+1, button_h+(windowPadding<<1)+1); XSetForeground(mainDisplay, defaultGC, myFgPixel); } else { XDrawRectangle(mainDisplay, Win, defaultGC, BBox->ltx-Width, BBox->lty-Width, button_w+(Width<<1), button_h+(Width<<1)); } } } �������������������������������������������������������������������������������������������tgif-QPL-4.2.5/choose.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000005234�11602233311�014415� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/choose.e,v 1.6 2011/05/16 16:21:56 william Exp $ */ #ifndef _CHOOSE_E_ #define _CHOOSE_E_ extern GC nameGC; extern GC revNameGC; #ifdef _INCLUDE_FROM_CHOOSE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_CHOOSE_C_*/ extern int GetWorkingDirectory ARGS_DECL((char *buf, int buf_sz)); extern int SetWorkingDirectory ARGS_DECL((char *dir)); extern void CleanUpCheckArray ARGS_DECL((struct CheckArrayRec *)); extern int CopyCheckArray ARGS_DECL((struct CheckArrayRec *pTo, struct CheckArrayRec *pFrom)); extern void NamesSetTitle ARGS_DECL((char*)); extern void ResetNamesInfo ARGS_DECL((void)); extern void InitNamesInfo ARGS_DECL((void)); extern void CleanUpNamesInfo ARGS_DECL((void)); extern void NamesAddButton ARGS_DECL((char*, int)); extern void DrawCheckbox ARGS_DECL((Display*, Window, GC, int x, int y, int w, int h, int checked)); extern void NamesSetDefaultBtnId ARGS_DECL((int def_btn_id, int double_click_btn_id)); extern void NamesSetStyle ARGS_DECL((int edit_style, int loop_once)); extern void NamesSetEntries ARGS_DECL((DspList*, char**, int num_entries, struct CheckArrayRec*, int dont_free_entries, int marked_index, int leading)); extern void NamesSetCallback ARGS_DECL((GetEntriesFunc *pf_before_loop, AfterLoopFunc *pf_after_loop, CheckUpdateFunc *pf_check_update)); extern void NamesSetDir ARGS_DECL((char*)); extern int Names ARGS_DECL((char *win_name, int *pn_selected_index, char *selected_str, int str_sz, void*)); #ifdef _INCLUDE_FROM_CHOOSE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_CHOOSE_C_*/ #endif /*_CHOOSE_E_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/�������������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�014072� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/MN.sym�������������������������������������������������������������������������0000644�0000764�0000764�00000020416�10064674140�015147� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,0,2,0,0,0,2,1,0,'Courier',0,57600,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/MN.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','White'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 208,224,192,216],2,1,1,25,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 192,192,192,224],0,1,1,26,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,192,192,200],0,1,1,27,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 176,208,192,208],0,1,1,28,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,176,208,192],0,1,1,29,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,224,208,240],0,1,1,30,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 8981,0,0,[ ]), icon([ box('#ff0000','',200,232,216,248,0,1,0,9055,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,238,210,242,0,1,0,9053,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,253,1,1,1,104,14,9054,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,264,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,244,212,236],0,1,1,9051,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,236,212,244],0,1,1,9050,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 9049,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,253,1,1,1,128,14,9052,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,264,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",9048,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,270,1,1,1,84,12,9058,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,280,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "e", 0, 1, 1, text('#0000ff',208,254,1,1,1,42,12,9116,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,264,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=e")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,286,1,1,1,63,12,9056,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,296,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',200,168,216,184,0,1,0,9060,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,174,210,178,0,1,0,9061,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,189,1,1,1,104,14,9062,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,180,212,172],0,1,1,9064,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,172,212,180],0,1,1,9065,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 9063,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,189,1,1,1,128,14,9066,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",9059,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,206,1,1,1,84,12,9067,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "c", 0, 1, 1, text('#0000ff',208,190,1,1,1,42,12,9104,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=c")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,222,1,1,1,63,12,9069,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',168,200,184,216,0,1,0,9071,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,206,178,210,0,1,0,9072,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,221,1,1,1,104,14,9073,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,232,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,212,180,204],0,1,1,9075,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,204,180,212],0,1,1,9076,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 9074,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,221,1,1,1,128,14,9077,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,232,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",9070,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,238,1,1,1,84,12,9078,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,248,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',176,222,1,1,1,42,12,9092,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,232,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,254,1,1,1,63,12,9080,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,264,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 9517,0,0,[ attr("name=", "Q", 1, 0, 0, text('yellow',200,196,1,0,1,7,12,460,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,206,'',[ minilines(7,12,0,0,0,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "Q")]) ]) ])])), attr("model=", "MN", 1, 0, 0, text('yellow',200,208,1,0,1,14,12,461,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,218,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "MN")]) ]) ])])), attr("type=", "NPN", 0, 1, 0, text('yellow',172,202,1,2,1,56,12,462,10,2,0,0,0,0,2,56,12,0,0,"",0,0,0,0,212,'',[ minilines(56,12,0,0,2,0,0,[ mini_line(56,10,2,0,0,0,[ str_block(0,56,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,56,10,2,0,0,0,0,0,0,0, "type=NPN")]) ]) ])])) ]). ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/out.sym������������������������������������������������������������������������0000644�0000764�0000764�00000007161�10064674140�015446� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,0,2,0,0,0,2,1,0,'Courier',0,57600,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/out.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). page(1,"",1,''). sym([ group([ polygon('#ff0000','',6,[ 180,176,192,184,208,184,208,168,192,168,180,176],2,1,1,0,3484,0,0,0,0,0,'1',0, "00",[ ]), poly('#ff0000','',2,[ 180,176,168,176],0,1,1,3485,0,2,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 3483,0,0,[ ]), icon([ box('#ff0000','',160,168,176,184,0,1,0,3487,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',166,174,170,178,0,1,0,3488,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',168,189,1,1,1,104,14,3489,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,180,164,172],0,1,1,3491,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,172,164,180],0,1,1,3492,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 3490,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',168,189,1,1,1,128,14,3493,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",3486,0,2,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',168,206,1,1,1,84,12,3494,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',168,190,1,1,1,42,12,3495,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',168,222,1,1,1,63,12,3496,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 6276,0,0,[ attr("name=", "OUT", 1, 0, 0, text('yellow',212,170,1,0,1,21,12,535,10,2,0,0,0,0,2,21,12,0,0,"",0,0,0,0,180,'',[ minilines(21,12,0,0,0,0,0,[ mini_line(21,10,2,0,0,0,[ str_block(0,21,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,21,10,2,0,0,0,0,0,0,0, "OUT")]) ]) ])])), attr("type=", "outport", 0, 1, 0, text('yellow',212,182,1,0,1,84,12,536,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,192,'',[ minilines(84,12,0,0,0,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,-1,0,0,0,0,0, "type=outport")]) ]) ])])) ]). ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/MP.mod�������������������������������������������������������������������������0000644�0000764�0000764�00000000726�10064674140�015122� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������.MODEL MP PNP +BF=150 BR=3 XTB=1.90 EG=1.17 +VAF=55 VAR=10 IS=3.18E-16 XTI=3.00 +IKF=5.28E-03 IKR=1.79E-3 ISC=1.00E-16 NC=2.00 +TF=2.70E-10 TR=6.00E-08 ISE=1.00E-16 NE=1.50 +RC=355 RB=380 RBM=28.7 RE=3.3 +CJC=5.19E-13 VJC=0.5535 MJC=0.2995 XCJC=0.2360 +CJE=5.67E-13 VJE=0.6840 MJE=0.3440 KF=5.00E-16 +CJS=1.46E-13 VJS=1.00 MJS=0.00 AF=1.00 ������������������������������������������tgif-QPL-4.2.5/spice/SP.sym�������������������������������������������������������������������������0000644�0000764�0000764�00000020415�10064674140�015156� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,0,2,0,0,0,2,1,2,'Courier',0,57600,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/SP.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','White'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 208,192,192,200],1,1,1,8,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 192,192,192,224],0,1,1,11,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,224,192,216],0,1,1,12,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 176,208,192,208],0,1,1,13,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,176,208,192],0,1,1,14,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,224,208,240],0,1,1,15,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 7776,0,0,[ ]), icon([ box('#ff0000','',200,232,216,248,0,1,0,7854,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,238,210,242,0,1,0,7852,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,253,1,1,1,104,14,7853,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,264,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,244,212,236],0,1,1,7850,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,236,212,244],0,1,1,7849,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 7848,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,253,1,1,1,128,14,7851,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,264,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",7847,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,270,1,1,1,84,12,7857,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,280,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "e", 0, 1, 1, text('#0000ff',208,254,1,1,1,42,12,7915,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,264,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=e")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,286,1,1,1,63,12,7855,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,296,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',200,168,216,184,0,1,0,7859,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,174,210,178,0,1,0,7860,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,189,1,1,1,104,14,7861,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,180,212,172],0,1,1,7863,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,172,212,180],0,1,1,7864,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 7862,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,189,1,1,1,128,14,7865,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",7858,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,206,1,1,1,84,12,7866,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "c", 0, 1, 1, text('#0000ff',208,190,1,1,1,42,12,7903,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=c")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,222,1,1,1,63,12,7868,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',168,200,184,216,0,1,0,7870,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,206,178,210,0,1,0,7871,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,221,1,1,1,104,14,7872,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,232,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,212,180,204],0,1,1,7874,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,204,180,212],0,1,1,7875,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 7873,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,221,1,1,1,128,14,7876,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,232,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",7869,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,238,1,1,1,84,12,7877,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,248,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',176,222,1,1,1,42,12,7891,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,232,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,254,1,1,1,63,12,7879,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,264,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 7956,0,0,[ attr("type=", "PNP", 0, 1, 0, text('yellow',172,202,1,2,1,56,12,501,10,2,0,0,0,0,2,56,12,0,0,"",0,0,0,0,212,'',[ minilines(56,12,0,0,2,0,0,[ mini_line(56,10,2,0,0,0,[ str_block(0,56,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,56,10,2,0,0,0,0,0,0,0, "type=PNP")]) ]) ])])), attr("model=", "SP", 1, 0, 0, text('yellow',200,208,1,0,1,14,12,500,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,218,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "SP")]) ]) ])])), attr("name=", "Q", 1, 0, 0, text('yellow',200,196,1,0,1,7,12,499,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,206,'',[ minilines(7,12,0,0,0,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "Q")]) ]) ])])) ]). ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/ground.sym���������������������������������������������������������������������0000644�0000764�0000764�00000010152�10064674140�016127� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,0,2,0,0,0,2,1,0,'Courier',0,69120,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/ground.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). page(1,"",1,''). sym([ group([ box('#ff0000','',160,176,192,208,0,1,0,493,0,0,0,0,0,'1',0,[ ]), poly('#ff0000','',2,[ 184,192,180,200],0,1,1,230,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 176,192,172,200],0,1,1,231,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 168,192,164,200],0,1,1,232,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 176,176,176,192],0,1,1,233,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 168,192,184,192],0,1,1,234,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 4114,0,0,[ ]), icon([ box('#ff0000','',168,168,184,184,0,1,0,4160,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,174,178,178,0,1,0,4158,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,189,1,1,1,104,14,4159,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,180,180,172],0,1,1,4156,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,172,180,180],0,1,1,4155,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 4154,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,189,1,1,1,128,14,4157,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",4153,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,206,1,1,1,84,12,4163,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',176,190,1,1,1,42,12,4175,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,222,1,1,1,63,12,4161,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 6531,0,0,[ attr("name=", "GND", 0, 1, 0, text('yellow',176,160,1,1,1,56,12,4297,10,2,0,0,0,0,2,56,12,0,0,"",0,0,0,0,170,'',[ minilines(56,12,0,0,1,0,0,[ mini_line(56,10,2,0,0,0,[ str_block(0,56,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,56,10,2,0,0,0,0,0,0,0, "name=GND")]) ]) ])])), attr("type=", "ground", 0, 1, 0, text('yellow',176,148,1,1,1,77,12,494,10,2,0,0,0,0,2,77,12,0,0,"",0,0,0,0,158,'',[ minilines(77,12,0,0,1,0,0,[ mini_line(77,10,2,0,0,0,[ str_block(0,77,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,77,10,2,0,0,0,0,0,0,0, "type=ground")]) ]) ])])) ]). ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/gauge.sym����������������������������������������������������������������������0000644�0000764�0000764�00000010020�10064674140�015713� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,2,2,0,0,0,2,1,0,'Courier',0,69120,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/gauge.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). page(1,"",1,''). sym([ group([ box('#ff8000','',160,160,224,208,0,1,0,603,0,0,0,0,0,'1',0,[ ]), poly('#ff8000','',2,[ 192,208,192,224],0,4,6,27,0,0,0,0,0,0,0,'4',0,0, "0","",[ 0,14,6,0,'14','6','0'],[0,14,6,0,'14','6','0'],[ ]), oval('#ff8000','',168,160,216,208,2,4,6,604,0,0,0,0,0,'4',0,[ ]), poly('#ff8000','',2,[ 188,196,196,168],1,4,1,26,0,0,0,0,0,0,0,'4',0,0, "0","",[ 0,14,6,0,'14','6','0'],[0,14,6,0,'14','6','0'],[ ]) ], 6614,0,0,[ ]), icon([ box('#ff0000','',184,216,200,232,0,1,0,6915,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',190,222,194,226,0,1,0,6913,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',192,237,1,1,1,104,14,6914,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,248,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 188,228,196,220],0,1,1,6911,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 188,220,196,228],0,1,1,6910,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 6909,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',192,237,1,1,1,128,14,6912,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,248,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",6908,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',192,254,1,1,1,84,12,6918,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,264,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',192,238,1,1,1,42,12,6930,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,248,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',192,270,1,1,1,63,12,6916,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,280,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 10251,0,0,[ attr("type=", "gauge", 0, 1, 0, text('yellow',192,226,1,1,1,70,12,605,10,2,0,0,0,0,2,70,12,0,0,"",0,0,0,0,236,'',[ minilines(70,12,0,0,1,0,0,[ mini_line(70,10,2,0,0,0,[ str_block(0,70,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,70,10,2,0,0,0,0,0,0,0, "type=gauge")]) ]) ])])), attr("V=", "", 1, 1, 0, text('yellow',192,144,1,1,1,14,12,606,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,154,'',[ minilines(14,12,0,0,1,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "V=")]) ]) ])])), attr("name=", "G", 1, 0, 0, text('yellow',216,198,1,0,1,7,12,10229,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,208,'',[ minilines(7,12,0,0,0,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "G")]) ]) ])])) ]). ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/vcc.sym������������������������������������������������������������������������0000644�0000764�0000764�00000007674�10064674140�015423� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,0,2,0,0,0,2,1,0,'Courier',0,69120,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/vcc.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 176,160,176,176],0,1,1,237,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 168,160,184,160],0,1,1,238,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 752,0,0,[ ]), icon([ box('#ff0000','',168,168,184,184,0,1,0,807,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,174,178,178,0,1,0,805,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,189,1,1,1,104,14,806,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,180,180,172],0,1,1,803,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,172,180,180],0,1,1,802,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 801,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,189,1,1,1,128,14,804,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",800,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,206,1,1,1,84,12,810,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',176,190,1,1,1,42,12,1871,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,222,1,1,1,63,12,808,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 5493,0,0,[ attr("val=", "5V", 1, 0, 0, text('yellow',180,164,1,0,1,14,12,506,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,174,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "5V")]) ]) ])])), attr("name=", "VCC", 1, 0, 0, text('yellow',176,147,1,1,1,21,12,508,10,2,0,0,0,0,2,21,12,0,0,"",0,0,0,0,157,'',[ minilines(21,12,0,0,1,0,0,[ mini_line(21,10,2,0,0,0,[ str_block(0,21,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,21,10,2,0,0,0,0,0,0,0, "VCC")]) ]) ])])), attr("type=", "power", 0, 1, 0, text('yellow',176,176,1,1,1,70,12,507,10,2,0,0,0,0,2,70,12,0,0,"",0,0,0,0,186,'',[ minilines(70,12,0,0,1,0,0,[ mini_line(70,10,2,0,0,0,[ str_block(0,70,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,70,10,2,0,0,0,0,0,0,0, "type=power")]) ]) ])])) ]). ��������������������������������������������������������������������tgif-QPL-4.2.5/spice/DN.mod�������������������������������������������������������������������������0000644�0000764�0000764�00000000726�10064674140�015107� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������.MODEL DN NPN +BF=200 BR=45 XTB=1.80 EG=1.11 +VAF=175 VAR=12 IS=1.79E-15 XTI=3.00 +IKF=3.01E-02 IKR=6.38E-3 ISC=1.00E-16 NC=2.00 +TF=1.20E-10 TR=6.00E-08 ISE=4.01E-16 NE=1.50 +RC=93 RB=98 RBM=10.5 RE=0.4 +CJC=9.87E-13 VJC=0.4920 MJC=0.3200 XCJC=0.2919 +CJE=1.50E-12 VJE=0.5800 MJE=0.2900 KF=5.00E-15 +CJS=2.75E-13 VJS=1.00 MJS=0.00 AF=0.82 ������������������������������������������tgif-QPL-4.2.5/spice/MN.mod�������������������������������������������������������������������������0000644�0000764�0000764�00000000726�10064674140�015120� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������.MODEL MN NPN +BF=200 BR=45 XTB=1.80 EG=1.11 +VAF=175 VAR=12 IS=1.79E-15 XTI=3.00 +IKF=3.01E-02 IKR=6.38E-3 ISC=1.00E-16 NC=2.00 +TF=1.20E-10 TR=6.00E-08 ISE=4.01E-16 NE=1.50 +RC=78 RB=89 RBM=10.0 RE=0.4 +CJC=1.02E-12 VJC=0.4920 MJC=0.3200 XCJC=0.2832 +CJE=1.52E-12 VJE=0.5800 MJE=0.2900 KF=5.00E-15 +CJS=3.72E-13 VJS=1.00 MJS=0.00 AF=0.82 ������������������������������������������tgif-QPL-4.2.5/spice/DN.sym�������������������������������������������������������������������������0000644�0000764�0000764�00000020416�10064674140�015136� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,0,2,0,0,0,2,1,0,'Courier',0,57600,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/DN.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','White'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 208,224,192,216],2,1,1,25,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 192,192,192,224],0,1,1,26,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,192,192,200],0,1,1,27,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 176,208,192,208],0,1,1,28,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,176,208,192],0,1,1,29,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,224,208,240],0,1,1,30,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 9779,0,0,[ ]), icon([ box('#ff0000','',200,168,216,184,0,1,0,9871,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,174,210,178,0,1,0,9869,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,189,1,1,1,104,14,9870,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,180,212,172],0,1,1,9867,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,172,212,180],0,1,1,9866,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 9865,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,189,1,1,1,128,14,9868,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",9864,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,206,1,1,1,84,12,9874,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "c", 0, 1, 1, text('#0000ff',208,190,1,1,1,42,12,9920,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=c")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,222,1,1,1,63,12,9872,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',200,232,216,248,0,1,0,9876,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,238,210,242,0,1,0,9877,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,253,1,1,1,104,14,9878,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,264,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,244,212,236],0,1,1,9880,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,236,212,244],0,1,1,9881,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 9879,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,253,1,1,1,128,14,9882,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,264,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",9875,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,270,1,1,1,84,12,9883,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,280,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "e", 0, 1, 1, text('#0000ff',208,254,1,1,1,42,12,9932,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,264,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=e")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,286,1,1,1,63,12,9885,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,296,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',168,200,184,216,0,1,0,9887,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,206,178,210,0,1,0,9888,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,221,1,1,1,104,14,9889,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,232,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,212,180,204],0,1,1,9891,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,204,180,212],0,1,1,9892,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 9890,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,221,1,1,1,128,14,9893,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,232,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",9886,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,238,1,1,1,84,12,9894,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,248,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',176,222,1,1,1,42,12,9908,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,232,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,254,1,1,1,63,12,9896,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,264,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 9973,0,0,[ attr("type=", "NPN", 0, 1, 0, text('yellow',172,202,1,2,1,56,12,449,10,2,0,0,0,0,2,56,12,0,0,"",0,0,0,0,212,'',[ minilines(56,12,0,0,2,0,0,[ mini_line(56,10,2,0,0,0,[ str_block(0,56,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,56,10,2,0,0,0,0,0,0,0, "type=NPN")]) ]) ])])), attr("model=", "DN", 1, 0, 0, text('yellow',200,208,1,0,1,14,12,448,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,218,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "DN")]) ]) ])])), attr("name=", "Q", 1, 0, 0, text('yellow',200,196,1,0,1,7,12,447,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,206,'',[ minilines(7,12,0,0,0,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "Q")]) ]) ])])) ]). ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/SP.mod�������������������������������������������������������������������������0000644�0000764�0000764�00000000726�10064674140�015130� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������.MODEL SP PNP +BF=150 BR=3 XTB=1.90 EG=1.17 +VAF=55 VAR=10 IS=3.18E-16 XTI=3.00 +IKF=5.28E-03 IKR=1.79E-3 ISC=1.00E-16 NC=2.00 +TF=2.70E-10 TR=6.00E-08 ISE=1.00E-16 NE=1.50 +RC=355 RB=380 RBM=28.7 RE=3.3 +CJC=5.19E-13 VJC=0.5535 MJC=0.2995 XCJC=0.2360 +CJE=5.67E-13 VJE=0.6840 MJE=0.3440 KF=5.00E-16 +CJS=1.46E-13 VJS=1.00 MJS=0.00 AF=1.00 ������������������������������������������tgif-QPL-4.2.5/spice/MP.sym�������������������������������������������������������������������������0000644�0000764�0000764�00000020415�10064674140�015150� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,0,2,0,0,0,2,1,2,'Courier',0,57600,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/MP.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','White'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 208,192,192,200],1,1,1,8,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 192,192,192,224],0,1,1,11,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,224,192,216],0,1,1,12,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 176,208,192,208],0,1,1,13,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,176,208,192],0,1,1,14,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,224,208,240],0,1,1,15,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 8580,0,0,[ ]), icon([ box('#ff0000','',200,168,216,184,0,1,0,8661,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,174,210,178,0,1,0,8659,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,189,1,1,1,104,14,8660,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,180,212,172],0,1,1,8657,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,172,212,180],0,1,1,8656,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 8655,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,189,1,1,1,128,14,8658,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",8654,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,206,1,1,1,84,12,8664,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "c", 0, 1, 1, text('#0000ff',208,190,1,1,1,42,12,8710,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=c")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,222,1,1,1,63,12,8662,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',200,232,216,248,0,1,0,8666,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,238,210,242,0,1,0,8667,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,253,1,1,1,104,14,8668,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,264,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,244,212,236],0,1,1,8670,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,236,212,244],0,1,1,8671,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 8669,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,253,1,1,1,128,14,8672,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,264,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",8665,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,270,1,1,1,84,12,8673,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,280,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "e", 0, 1, 1, text('#0000ff',208,254,1,1,1,42,12,8722,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,264,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=e")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,286,1,1,1,63,12,8675,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,296,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',168,200,184,216,0,1,0,8677,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,206,178,210,0,1,0,8678,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,221,1,1,1,104,14,8679,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,232,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,212,180,204],0,1,1,8681,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,204,180,212],0,1,1,8682,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 8680,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,221,1,1,1,128,14,8683,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,232,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",8676,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,238,1,1,1,84,12,8684,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,248,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',176,222,1,1,1,42,12,8698,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,232,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,254,1,1,1,63,12,8686,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,264,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 8763,0,0,[ attr("type=", "PNP", 0, 1, 0, text('yellow',172,202,1,2,1,56,12,475,10,2,0,0,0,0,2,56,12,0,0,"",0,0,0,0,212,'',[ minilines(56,12,0,0,2,0,0,[ mini_line(56,10,2,0,0,0,[ str_block(0,56,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,56,10,2,0,0,0,0,0,0,0, "type=PNP")]) ]) ])])), attr("model=", "MP", 1, 0, 0, text('yellow',200,208,1,0,1,14,12,474,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,218,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "MP")]) ]) ])])), attr("name=", "Q", 1, 0, 0, text('yellow',200,196,1,0,1,7,12,473,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,206,'',[ minilines(7,12,0,0,0,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "Q")]) ]) ])])) ]). ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/resistor.sym�������������������������������������������������������������������0000644�0000764�0000764�00000014415�10064674140�016511� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,2,2,0,0,0,2,1,0,'Courier',0,57600,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/resistor.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','White'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 176,176,176,184],0,1,1,44,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 176,200,176,208],0,1,1,45,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',6,[ 176,184,168,186,184,190,168,194,184,198,176,200],0,1,1,46,0,0,0,0,0,0,0,'1',0,0, "00","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 752,0,0,[ ]), icon([ box('#ff0000','',168,200,184,216,0,1,0,838,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,206,178,210,0,1,0,836,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,221,1,1,1,104,14,837,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,232,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,212,180,204],0,1,1,834,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,204,180,212],0,1,1,833,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 832,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,221,1,1,1,128,14,835,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,232,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",831,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,238,1,1,1,84,12,841,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,248,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',176,222,1,1,1,42,12,1582,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,232,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,254,1,1,1,63,12,839,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,264,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',168,168,184,184,0,1,0,898,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,174,178,178,0,1,0,899,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,189,1,1,1,104,14,900,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,180,180,172],0,1,1,902,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,172,180,180],0,1,1,903,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 901,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,189,1,1,1,128,14,904,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",897,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,206,1,1,1,84,12,905,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',176,190,1,1,1,42,12,1570,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,222,1,1,1,63,12,907,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 4697,0,0,[ attr("tc=", "1E-4", 0, 1, 0, text('yellow',176,210,1,1,1,49,12,538,10,2,0,0,0,0,2,49,12,0,0,"",0,0,0,0,220,'',[ minilines(49,12,0,0,1,0,0,[ mini_line(49,10,2,0,0,0,[ str_block(0,49,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,49,10,2,0,-1,0,0,0,0,0, "tc=1E-4")]) ]) ])])), attr("type=", "resistor", 0, 1, 0, text('yellow',164,186,1,2,1,91,12,537,10,2,0,0,0,0,2,91,12,0,0,"",0,0,0,0,196,'',[ minilines(91,12,0,0,2,0,0,[ mini_line(91,10,2,0,0,0,[ str_block(0,91,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,91,10,2,0,0,0,0,0,0,0, "type=resistor")]) ]) ])])), attr("val=", "1K", 1, 0, 0, text('yellow',188,192,1,0,1,14,12,536,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,202,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "1K")]) ]) ])])), attr("name=", "R", 1, 0, 0, text('yellow',188,180,1,0,1,7,12,535,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,190,'',[ minilines(7,12,0,0,0,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "R")]) ]) ])])) ]). ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/BZ.mod�������������������������������������������������������������������������0000644�0000764�0000764�00000000067�10064674140�015117� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������.MODEL BZ D +RS=100 BV=5.45 IBV=500E-6 �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/in.sym�������������������������������������������������������������������������0000644�0000764�0000764�00000007156�10064674140�015251� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,0,2,0,0,0,2,1,2,'Courier',0,69120,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/in.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). page(1,"",1,''). sym([ group([ polygon('#ff0000','',6,[ 188,176,176,184,160,184,160,168,176,168,188,176],2,1,1,0,3968,0,0,0,0,0,'1',0, "00",[ ]), poly('#ff0000','',2,[ 188,176,200,176],0,1,1,3969,0,2,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 3967,0,0,[ ]), icon([ box('#ff0000','',192,168,208,184,0,1,0,3971,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',198,174,202,178,0,1,0,3972,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',200,189,1,1,1,104,14,3973,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 196,180,204,172],0,1,1,3975,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 196,172,204,180],0,1,1,3976,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 3974,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',200,189,1,1,1,128,14,3977,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",3970,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',200,206,1,1,1,84,12,3978,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',200,190,1,1,1,42,12,3979,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',200,222,1,1,1,63,12,3980,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 6397,0,0,[ attr("type=", "inport", 0, 1, 0, text('yellow',156,182,1,2,1,77,12,3982,10,2,0,0,0,0,2,77,12,0,0,"",0,0,0,0,192,'',[ minilines(77,12,0,0,2,0,0,[ mini_line(77,10,2,0,0,0,[ str_block(0,77,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,77,10,2,0,-1,0,0,0,0,0, "type=inport")]) ]) ])])), attr("name=", "IN", 1, 0, 0, text('yellow',156,170,1,2,1,14,12,3981,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,180,'',[ minilines(14,12,0,0,2,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "IN")]) ]) ])])) ]). ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/connection.sym�����������������������������������������������������������������0000644�0000764�0000764�00000007104�10064674140�016773� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,0,2,0,0,0,2,1,0,'Courier',0,69120,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/connection.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','White'). page(1,"",1,''). sym([ group([ box('#0000ff','',160,160,192,192,0,1,0,596,0,0,0,0,0,'1',0,[ ]), oval('#0000ff','',172,172,180,180,1,1,1,597,0,0,0,0,0,'1',0,[ ]) ], 7297,0,0,[ ]), icon([ box('#0000ff','',168,168,184,184,0,1,0,7261,0,0,0,0,0,'1',0,[ ]), box('#0000ff','',174,174,178,178,0,1,0,7259,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,189,1,1,1,104,14,7260,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#0000ff','',2,[ 174,178,178,174],0,1,1,7257,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#0000ff','',2,[ 174,174,178,178],0,1,1,7256,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 7255,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,189,1,1,1,128,14,7258,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port-small",7254,0,0,0,0,[ attr("type=", "port", 0, 1, 1, text('#0000ff',176,222,1,1,1,63,12,7264,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',176,190,1,1,1,42,12,7382,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,206,1,1,1,84,12,7262,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])) ]) ], 7399,0,0,[ attr("type=", "connection", 0, 1, 0, text('yellow',176,180,1,1,1,105,12,598,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,190,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "type=connection")]) ]) ])])), attr("name=", "CONN", 0, 1, 0, text('yellow',176,192,1,1,1,63,12,7383,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,202,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,0,0,0,0,0,0, "name=CONN")]) ]) ])])) ]). ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/demo.obj�����������������������������������������������������������������������0000644�0000764�0000764�00000213651�10064674140�015530� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.37 state(0,37,100.000,64,64,0,4,1,3,2,3,0,0,0,0,1,1,'Courier',0,80640,0,0,0,10,0,0,1,0,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/demo.obj,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(11,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). page(1,"",1,''). poly('#0000ff','',2,[ 272,288,320,288],0,1,1,11752,0,2,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "BASE", 1, 0, 0, text('#0000ff',296,289,1,1,1,32,14,11755,11,3,0,0,0,0,2,32,14,0,0,"",0,0,0,0,300,'',[ minilines(32,14,0,0,1,0,0,[ mini_line(32,11,3,0,0,0,[ str_block(0,32,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,32,11,3,0,0,0,0,0,0,0, "BASE")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',324,299,1,1,1,88,14,11756,11,3,2,0,0,0,2,88,14,0,0,"",0,0,0,0,310,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',2,[ 272,288,400,288],0,1,1,11835,0,2,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "BASE", 1, 0, 0, text('#0000ff',376,289,1,1,0,32,14,11838,11,3,2,0,0,0,2,32,14,0,0,"",0,0,0,0,300,'',[ minilines(32,14,0,0,1,0,0,[ mini_line(32,11,3,0,0,0,[ str_block(0,32,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,32,11,3,0,0,0,0,0,0,0, "BASE")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',412,367,1,1,1,88,14,11839,11,3,2,0,0,0,2,88,14,0,0,"",0,0,0,0,378,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',2,[ 432,160,432,192],0,1,1,12150,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "VCC", 1, 0, 0, text('#0000ff',446,169,1,1,1,24,14,12153,11,3,0,0,0,0,2,24,14,0,0,"",0,0,0,0,180,'',[ minilines(24,14,0,0,1,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "VCC")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',476,183,1,1,1,88,14,12154,11,3,0,0,0,0,2,88,14,0,0,"",0,0,0,0,194,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',4,[ 432,224,432,240,496,240,592,192],0,1,1,12443,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "OUT", 1, 0, 0, text('#0000ff',544,181,1,1,0,24,14,12446,11,3,0,0,0,0,2,24,14,0,0,"",0,0,0,0,192,'',[ minilines(24,14,0,0,1,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "OUT")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',576,195,1,1,1,88,14,12447,11,3,0,0,0,0,2,88,14,0,0,"",0,0,0,0,206,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',4,[ 352,256,352,240,432,240,432,224],0,1,1,11988,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "OUT", 1, 0, 0, text('#0000ff',392,225,1,1,0,24,14,11991,11,3,0,0,0,0,2,24,14,0,0,"",0,0,0,0,236,'',[ minilines(24,14,0,0,1,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "OUT")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',424,239,1,1,1,88,14,11992,11,3,0,0,0,0,2,88,14,0,0,"",0,0,0,0,250,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',2,[ 432,224,432,256],0,1,1,11899,0,2,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "OUT", 1, 0, 0, text('#0000ff',444,233,1,1,0,24,14,11902,11,3,0,0,0,0,2,24,14,0,0,"",0,0,0,0,244,'',[ minilines(24,14,0,0,1,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "OUT")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',476,247,1,1,1,88,14,11903,11,3,2,0,0,0,2,88,14,0,0,"",0,0,0,0,258,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',4,[ 432,224,432,240,576,240,576,272],0,1,1,12076,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "OUT", 1, 0, 0, text('#0000ff',540,241,1,1,1,24,14,12079,11,3,0,0,0,0,2,24,14,0,0,"",0,0,0,0,252,'',[ minilines(24,14,0,0,1,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "OUT")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',572,255,1,1,1,88,14,12080,11,3,0,0,0,0,2,88,14,0,0,"",0,0,0,0,266,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',4,[ 432,224,432,240,496,240,496,272],0,1,1,12037,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "OUT", 1, 0, 0, text('#0000ff',480,225,1,1,0,24,14,12040,11,3,0,0,0,0,2,24,14,0,0,"",0,0,0,0,236,'',[ minilines(24,14,0,0,1,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "OUT")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',512,239,1,1,1,88,14,12041,11,3,0,0,0,0,2,88,14,0,0,"",0,0,0,0,250,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',4,[ 496,304,496,336,432,336,432,352],0,1,1,12333,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "GND", 1, 0, 0, text('#0000ff',468,337,1,1,0,24,14,12336,11,3,0,0,0,0,2,24,14,0,0,"",0,0,0,0,348,'',[ minilines(24,14,0,0,1,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "GND")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',500,351,1,1,1,88,14,12337,11,3,0,0,0,0,2,88,14,0,0,"",0,0,0,0,362,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',4,[ 576,304,576,336,432,336,432,352],0,1,1,12372,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "GND", 1, 0, 0, text('#0000ff',540,337,1,1,1,24,14,12375,11,3,0,0,0,0,2,24,14,0,0,"",0,0,0,0,348,'',[ minilines(24,14,0,0,1,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "GND")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',572,351,1,1,1,88,14,12376,11,3,0,0,0,0,2,88,14,0,0,"",0,0,0,0,362,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',2,[ 432,320,432,352],0,1,1,12207,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "GND", 1, 0, 0, text('#0000ff',444,333,1,1,0,24,14,12210,11,3,0,0,0,0,2,24,14,0,0,"",0,0,0,0,344,'',[ minilines(24,14,0,0,1,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "GND")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',476,347,1,1,1,88,14,12211,11,3,0,0,0,0,2,88,14,0,0,"",0,0,0,0,358,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',4,[ 352,320,352,336,432,336,432,352],0,1,1,12281,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "GND", 1, 0, 0, text('#0000ff',408,341,1,1,0,24,14,12284,11,3,0,0,0,0,2,24,14,0,0,"",0,0,0,0,352,'',[ minilines(24,14,0,0,1,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "GND")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',440,355,1,1,1,88,14,12285,11,3,0,0,0,0,2,88,14,0,0,"",0,0,0,0,366,'',[ minilines(88,14,0,0,1,0,0,[ mini_line(88,11,3,0,0,0,[ str_block(0,88,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,88,11,3,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). poly('#0000ff','',2,[ 200,288,240,288],0,1,1,11388,0,2,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ attr("signal_name=", "VIN", 1, 0, 0, text('#0000ff',220,289,1,1,1,24,14,11391,11,3,0,0,0,0,2,24,14,0,0,"",0,0,0,0,300,'',[ minilines(24,14,0,0,1,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "VIN")]) ]) ])])), attr("type=", "tgWire", 0, 1, 0, text('#0000ff',252,306,1,1,1,77,12,11392,10,2,2,0,0,0,2,77,12,0,0,"",0,0,0,0,316,'',[ minilines(77,12,0,0,1,0,0,[ mini_line(77,10,2,0,0,0,[ str_block(0,77,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,77,10,2,0,0,0,0,0,0,0, "type=tgWire")]) ]) ])])) ]). icon([ group([ polygon('#ff0000','',6,[ 188,288,176,296,160,296,160,280,176,280,188,288],2,1,1,0,10650,0,0,0,0,0,'1',0, "00",[ ]), poly('#ff0000','',2,[ 188,288,200,288],0,1,1,10649,0,2,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10648,0,0,[ ]), icon([ box('#ff0000','',192,280,208,296,0,1,0,10644,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',198,286,202,290,1,1,0,10642,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',200,301,1,1,1,104,14,10643,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,312,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 196,292,204,284],0,1,0,10640,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 196,284,204,292],0,1,0,10639,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10638,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',200,301,1,1,1,128,14,10641,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,312,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10637,0,0,0,0,[ attr("signal_name=", "VIN", 0, 1, 1, text('#0000ff',200,318,1,1,1,105,12,10647,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,328,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=VIN")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',200,302,1,1,1,42,12,10646,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,312,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',200,334,1,1,1,63,12,10645,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,344,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], "in",10636,0,0,0,0,[ attr("type=", "inport", 0, 1, 1, text('yellow',156,294,1,2,1,77,12,10652,10,2,0,0,0,0,2,77,12,0,0,"",0,0,0,0,304,'',[ minilines(77,12,0,0,2,0,0,[ mini_line(77,10,2,0,0,0,[ str_block(0,77,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,77,10,2,0,-1,0,0,0,0,0, "type=inport")]) ]) ])])), attr("name=", "VIN", 1, 0, 1, text('yellow',156,282,1,2,1,21,12,10651,10,2,0,0,0,0,2,21,12,0,0,"",0,0,0,0,292,'',[ minilines(21,12,0,0,2,0,0,[ mini_line(21,10,2,0,0,0,[ str_block(0,21,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,21,10,2,0,0,0,0,0,0,0, "VIN")]) ]) ])])) ]). icon([ group([ poly('#ff0000','',2,[ 240,288,248,288],0,1,1,10760,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 264,288,272,288],0,1,1,10759,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',6,[ 248,288,250,296,254,280,258,296,262,280,264,288],0,1,1,10758,0,0,0,0,0,0,0,'1',0,0, "00","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10757,0,0,[ ]), icon([ box('#ff0000','',264,280,280,296,0,1,0,10753,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',270,286,274,290,1,1,0,10751,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',272,301,1,1,1,104,14,10752,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,312,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 268,292,276,284],0,1,0,10749,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 268,284,276,292],0,1,0,10748,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10747,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',272,301,1,1,1,128,14,10750,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,312,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10746,0,0,0,0,[ attr("signal_name=", "BASE", 0, 1, 1, text('#0000ff',272,318,1,1,1,112,12,10756,10,2,0,0,0,0,2,112,12,0,0,"",0,0,0,0,328,'',[ minilines(112,12,0,0,1,0,0,[ mini_line(112,10,2,0,0,0,[ str_block(0,112,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,112,10,2,0,0,0,0,0,0,0, "signal_name=BASE")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',272,302,1,1,1,42,12,10755,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,312,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',272,334,1,1,1,63,12,10754,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,344,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',232,280,248,296,0,1,0,10742,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',238,286,242,290,1,1,0,10740,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',240,301,1,1,1,104,14,10741,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,312,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 236,292,244,284],0,1,0,10738,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 236,284,244,292],0,1,0,10737,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10736,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',240,301,1,1,1,128,14,10739,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,312,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10735,0,0,0,0,[ attr("signal_name=", "VIN", 0, 1, 1, text('#0000ff',240,318,1,1,1,105,12,10745,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,328,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=VIN")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',240,302,1,1,1,42,12,10744,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,312,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',240,334,1,1,1,63,12,10743,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,344,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], "resistor.h",10734,0,0,0,0,[ attr("tc=", "1E-4", 0, 1, 1, text('yellow',256,302,1,1,1,49,12,10764,10,2,0,0,0,0,2,49,12,0,0,"",0,0,0,0,312,'',[ minilines(49,12,0,0,1,0,0,[ mini_line(49,10,2,0,0,0,[ str_block(0,49,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,49,10,2,0,-1,0,0,0,0,0, "tc=1E-4")]) ]) ])])), attr("type=", "resistor", 0, 1, 1, text('yellow',260,314,1,1,1,91,12,10763,10,2,0,0,0,0,2,91,12,0,0,"",0,0,0,0,324,'',[ minilines(91,12,0,0,1,0,0,[ mini_line(91,10,2,0,0,0,[ str_block(0,91,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,91,10,2,0,0,0,0,0,0,0, "type=resistor")]) ]) ])])), attr("val=", "10K", 1, 0, 1, text('yellow',256,264,1,1,1,21,12,10762,10,2,0,0,0,0,2,21,12,0,0,"",0,0,0,0,274,'',[ minilines(21,12,0,0,1,0,0,[ mini_line(21,10,2,0,0,0,[ str_block(0,21,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,21,10,2,0,0,0,0,0,0,0, "10K")]) ]) ])])), attr("name=", "R2", 1, 0, 1, text('yellow',256,252,1,1,1,14,12,10761,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,262,'',[ minilines(14,12,0,0,1,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,-1,0,0,0,0,0, "R2")]) ]) ])])) ]). icon([ group([ poly('#ff0000','',2,[ 352,304,336,296],2,1,1,10806,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 336,272,336,304],0,1,1,10805,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 352,272,336,280],0,1,1,10804,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 320,288,336,288],0,1,1,10803,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 352,256,352,272],0,1,1,10802,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 352,304,352,320],0,1,1,10801,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10800,0,0,[ ]), icon([ box('#ff0000','',344,312,360,328,0,1,0,10796,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',350,318,354,322,1,1,0,10794,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',352,333,1,1,1,104,14,10795,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,344,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 348,324,356,316],0,1,0,10792,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 348,316,356,324],0,1,0,10791,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10790,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',352,333,1,1,1,128,14,10793,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,344,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10789,0,0,0,0,[ attr("signal_name=", "GND", 0, 1, 1, text('#0000ff',352,350,1,1,1,105,12,10799,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,360,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=GND")]) ]) ])])), attr("name=", "e", 0, 1, 1, text('#0000ff',352,334,1,1,1,42,12,10798,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,344,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=e")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',352,366,1,1,1,63,12,10797,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,376,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',344,248,360,264,0,1,0,10785,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',350,254,354,258,1,1,0,10783,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',352,269,1,1,1,104,14,10784,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,280,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 348,260,356,252],0,1,0,10781,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 348,252,356,260],0,1,0,10780,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10779,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',352,269,1,1,1,128,14,10782,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,280,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10778,0,0,0,0,[ attr("signal_name=", "OUT", 0, 1, 1, text('#0000ff',352,286,1,1,1,105,12,10788,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,296,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=OUT")]) ]) ])])), attr("name=", "c", 0, 1, 1, text('#0000ff',352,270,1,1,1,42,12,10787,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,280,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=c")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',352,302,1,1,1,63,12,10786,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,312,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',312,280,328,296,0,1,0,10774,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',318,286,322,290,1,1,0,10772,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',320,301,1,1,1,104,14,10773,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,312,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 316,292,324,284],0,1,0,10770,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 316,284,324,292],0,1,0,10769,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10768,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',320,301,1,1,1,128,14,10771,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,312,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10767,0,0,0,0,[ attr("signal_name=", "BASE", 0, 1, 1, text('#0000ff',320,318,1,1,1,112,12,10777,10,2,0,0,0,0,2,112,12,0,0,"",0,0,0,0,328,'',[ minilines(112,12,0,0,1,0,0,[ mini_line(112,10,2,0,0,0,[ str_block(0,112,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,112,10,2,0,0,0,0,0,0,0, "signal_name=BASE")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',320,302,1,1,1,42,12,10776,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,312,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',320,334,1,1,1,63,12,10775,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,344,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], "SN",10766,0,0,0,0,[ attr("name=", "Q1", 1, 0, 1, text('yellow',344,276,1,0,1,14,12,10809,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,286,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,-1,0,0,0,0,0, "Q1")]) ]) ])])), attr("model=", "SN", 1, 0, 1, text('yellow',344,288,1,0,1,14,12,10808,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,298,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "SN")]) ]) ])])), attr("type=", "NPN", 0, 1, 1, text('yellow',316,282,1,2,1,56,12,10807,10,2,0,0,0,0,2,56,12,0,0,"",0,0,0,0,292,'',[ minilines(56,12,0,0,2,0,0,[ mini_line(56,10,2,0,0,0,[ str_block(0,56,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,56,10,2,0,0,0,0,0,0,0, "type=NPN")]) ]) ])])) ]). icon([ group([ poly('#ff0000','',2,[ 432,304,416,296],2,1,1,10812,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 416,272,416,304],0,1,1,10813,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 432,272,416,280],0,1,1,10814,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 400,288,416,288],0,1,1,10815,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 432,256,432,272],0,1,1,10816,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 432,304,432,320],0,1,1,10817,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10811,0,0,[ ]), icon([ box('#ff0000','',424,312,440,328,0,1,0,10819,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',430,318,434,322,1,1,0,10820,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',432,333,1,1,1,104,14,10821,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,344,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 428,324,436,316],0,1,0,10823,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 428,316,436,324],0,1,0,10824,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10822,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',432,333,1,1,1,128,14,10825,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,344,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10818,0,0,0,0,[ attr("signal_name=", "GND", 0, 1, 1, text('#0000ff',432,350,1,1,1,105,12,10826,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,360,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=GND")]) ]) ])])), attr("name=", "e", 0, 1, 1, text('#0000ff',432,334,1,1,1,42,12,10827,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,344,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=e")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',432,366,1,1,1,63,12,10828,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,376,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',424,248,440,264,0,1,0,10830,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',430,254,434,258,1,1,0,10831,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',432,269,1,1,1,104,14,10832,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,280,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 428,260,436,252],0,1,0,10834,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 428,252,436,260],0,1,0,10835,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10833,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',432,269,1,1,1,128,14,10836,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,280,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10829,0,0,0,0,[ attr("signal_name=", "OUT", 0, 1, 1, text('#0000ff',432,286,1,1,1,105,12,10837,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,296,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=OUT")]) ]) ])])), attr("name=", "c", 0, 1, 1, text('#0000ff',432,270,1,1,1,42,12,10838,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,280,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=c")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',432,302,1,1,1,63,12,10839,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,312,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',392,280,408,296,0,1,0,10841,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',398,286,402,290,1,1,0,10842,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',400,301,1,1,1,104,14,10843,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,312,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 396,292,404,284],0,1,0,10845,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 396,284,404,292],0,1,0,10846,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10844,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',400,301,1,1,1,128,14,10847,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,312,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10840,0,0,0,0,[ attr("signal_name=", "BASE", 0, 1, 1, text('#0000ff',400,318,1,1,1,112,12,10848,10,2,0,0,0,0,2,112,12,0,0,"",0,0,0,0,328,'',[ minilines(112,12,0,0,1,0,0,[ mini_line(112,10,2,0,0,0,[ str_block(0,112,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,112,10,2,0,0,0,0,0,0,0, "signal_name=BASE")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',400,302,1,1,1,42,12,10849,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,312,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',400,334,1,1,1,63,12,10850,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,344,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], "SN",10810,0,0,0,0,[ attr("name=", "Q2", 1, 0, 1, text('yellow',424,276,1,0,1,14,12,10851,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,286,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,-1,0,0,0,0,0, "Q2")]) ]) ])])), attr("model=", "SN", 1, 0, 1, text('yellow',424,288,1,0,1,14,12,10852,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,298,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "SN")]) ]) ])])), attr("type=", "NPN", 0, 1, 1, text('yellow',396,282,1,2,1,56,12,10853,10,2,0,0,0,0,2,56,12,0,0,"",0,0,0,0,292,'',[ minilines(56,12,0,0,2,0,0,[ mini_line(56,10,2,0,0,0,[ str_block(0,56,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,56,10,2,0,0,0,0,0,0,0, "type=NPN")]) ]) ])])) ]). icon([ group([ poly('#ff0000','',2,[ 496,272,496,280],0,1,1,10881,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 496,296,496,304],0,1,1,10880,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',6,[ 496,280,488,282,504,286,488,290,504,294,496,296],0,1,1,10879,0,0,0,0,0,0,0,'1',0,0, "00","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10878,0,0,[ ]), icon([ box('#ff0000','',488,296,504,312,0,1,0,10874,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',494,302,498,306,1,1,0,10872,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',496,317,1,1,1,104,14,10873,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,328,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 492,308,500,300],0,1,0,10870,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 492,300,500,308],0,1,0,10869,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10868,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',496,317,1,1,1,128,14,10871,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,328,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10867,0,0,0,0,[ attr("signal_name=", "GND", 0, 1, 1, text('#0000ff',496,334,1,1,1,105,12,10877,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,344,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=GND")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',496,318,1,1,1,42,12,10876,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,328,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',496,350,1,1,1,63,12,10875,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,360,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',488,264,504,280,0,1,0,10863,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',494,270,498,274,1,1,0,10861,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',496,285,1,1,1,104,14,10862,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,296,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 492,276,500,268],0,1,0,10859,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 492,268,500,276],0,1,0,10858,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10857,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',496,285,1,1,1,128,14,10860,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,296,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10856,0,0,0,0,[ attr("signal_name=", "OUT", 0, 1, 1, text('#0000ff',496,302,1,1,1,105,12,10866,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,312,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=OUT")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',496,286,1,1,1,42,12,10865,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,296,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',496,318,1,1,1,63,12,10864,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,328,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], "resistor",10855,0,0,0,0,[ attr("tc=", "1E-4", 0, 1, 1, text('yellow',496,306,1,1,1,49,12,10885,10,2,0,0,0,0,2,49,12,0,0,"",0,0,0,0,316,'',[ minilines(49,12,0,0,1,0,0,[ mini_line(49,10,2,0,0,0,[ str_block(0,49,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,49,10,2,0,-1,0,0,0,0,0, "tc=1E-4")]) ]) ])])), attr("type=", "resistor", 0, 1, 1, text('yellow',484,282,1,2,1,91,12,10884,10,2,0,0,0,0,2,91,12,0,0,"",0,0,0,0,292,'',[ minilines(91,12,0,0,2,0,0,[ mini_line(91,10,2,0,0,0,[ str_block(0,91,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,91,10,2,0,0,0,0,0,0,0, "type=resistor")]) ]) ])])), attr("val=", "100K", 1, 0, 1, text('yellow',508,288,1,0,1,28,12,10883,10,2,0,0,0,0,2,28,12,0,0,"",0,0,0,0,298,'',[ minilines(28,12,0,0,0,0,0,[ mini_line(28,10,2,0,0,0,[ str_block(0,28,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,28,10,2,0,0,0,0,0,0,0, "100K")]) ]) ])])), attr("name=", "R3", 1, 0, 1, text('yellow',508,276,1,0,1,14,12,10882,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,286,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,-1,0,0,0,0,0, "R3")]) ]) ])])) ]). icon([ group([ poly('#ff0000','',2,[ 576,272,576,284],0,1,1,10914,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 576,292,576,304],0,1,1,10913,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 568,284,584,284],0,1,1,10912,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 568,292,584,292],0,1,1,10911,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10910,0,0,[ ]), icon([ box('#ff0000','',568,264,584,280,0,1,0,10906,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',574,270,578,274,1,1,0,10904,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',576,285,1,1,1,104,14,10905,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,296,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 572,276,580,268],0,1,0,10902,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 572,268,580,276],0,1,0,10901,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10900,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',576,285,1,1,1,128,14,10903,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,296,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10899,0,0,0,0,[ attr("signal_name=", "OUT", 0, 1, 1, text('#0000ff',576,302,1,1,1,105,12,10909,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,312,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=OUT")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',576,286,1,1,1,42,12,10908,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,296,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',576,318,1,1,1,63,12,10907,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,328,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',568,296,584,312,0,1,0,10895,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',574,302,578,306,1,1,0,10893,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',576,317,1,1,1,104,14,10894,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,328,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 572,308,580,300],0,1,0,10891,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 572,300,580,308],0,1,0,10890,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10889,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',576,317,1,1,1,128,14,10892,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,328,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10888,0,0,0,0,[ attr("signal_name=", "GND", 0, 1, 1, text('#0000ff',576,334,1,1,1,105,12,10898,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,344,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=GND")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',576,318,1,1,1,42,12,10897,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,328,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',576,350,1,1,1,63,12,10896,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,360,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], "capacitor",10887,0,0,0,0,[ attr("name=", "C1", 1, 0, 1, text('yellow',588,276,1,0,1,14,12,10917,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,286,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,-1,0,0,0,0,0, "C1")]) ]) ])])), attr("val=", "1000pF", 1, 0, 1, text('yellow',588,288,1,0,1,42,12,10916,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,298,'',[ minilines(42,12,0,0,0,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "1000pF")]) ]) ])])), attr("type=", "capacitor", 0, 1, 1, text('yellow',564,282,1,2,1,98,12,10915,10,2,0,0,0,0,2,98,12,0,0,"",0,0,0,0,292,'',[ minilines(98,12,0,0,2,0,0,[ mini_line(98,10,2,0,0,0,[ str_block(0,98,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,98,10,2,0,0,0,0,0,0,0, "type=capacitor")]) ]) ])])) ]). icon([ group([ poly('#ff0000','',2,[ 432,192,432,200],0,1,1,10945,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 432,216,432,224],0,1,1,10944,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',6,[ 432,200,424,202,440,206,424,210,440,214,432,216],0,1,1,10943,0,0,0,0,0,0,0,'1',0,0, "00","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10942,0,0,[ ]), icon([ box('#ff0000','',424,216,440,232,0,1,0,10938,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',430,222,434,226,1,1,0,10936,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',432,237,1,1,1,104,14,10937,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,248,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 428,228,436,220],0,1,0,10934,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 428,220,436,228],0,1,0,10933,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10932,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',432,237,1,1,1,128,14,10935,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,248,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10931,0,0,0,0,[ attr("signal_name=", "OUT", 0, 1, 1, text('#0000ff',432,254,1,1,1,105,12,10941,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,264,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=OUT")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',432,238,1,1,1,42,12,10940,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,248,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',432,270,1,1,1,63,12,10939,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,280,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',424,184,440,200,0,1,0,10927,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',430,190,434,194,1,1,0,10925,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',432,205,1,1,1,104,14,10926,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,216,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 428,196,436,188],0,1,0,10923,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 428,188,436,196],0,1,0,10922,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10921,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',432,205,1,1,1,128,14,10924,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,216,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10920,0,0,0,0,[ attr("signal_name=", "VCC", 0, 1, 1, text('#0000ff',432,222,1,1,1,105,12,10930,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,232,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=VCC")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',432,206,1,1,1,42,12,10929,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,216,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',432,238,1,1,1,63,12,10928,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,248,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], "resistor",10919,0,0,0,0,[ attr("tc=", "1E-4", 0, 1, 1, text('yellow',432,226,1,1,1,49,12,10949,10,2,0,0,0,0,2,49,12,0,0,"",0,0,0,0,236,'',[ minilines(49,12,0,0,1,0,0,[ mini_line(49,10,2,0,0,0,[ str_block(0,49,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,49,10,2,0,-1,0,0,0,0,0, "tc=1E-4")]) ]) ])])), attr("type=", "resistor", 0, 1, 1, text('yellow',420,202,1,2,1,91,12,10948,10,2,0,0,0,0,2,91,12,0,0,"",0,0,0,0,212,'',[ minilines(91,12,0,0,2,0,0,[ mini_line(91,10,2,0,0,0,[ str_block(0,91,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,91,10,2,0,0,0,0,0,0,0, "type=resistor")]) ]) ])])), attr("val=", "10K", 1, 0, 1, text('yellow',444,208,1,0,1,21,12,10947,10,2,0,0,0,0,2,21,12,0,0,"",0,0,0,0,218,'',[ minilines(21,12,0,0,0,0,0,[ mini_line(21,10,2,0,0,0,[ str_block(0,21,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,21,10,2,0,0,0,0,0,0,0, "10K")]) ]) ])])), attr("name=", "R1", 1, 0, 1, text('yellow',444,196,1,0,1,14,12,10946,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,206,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,-1,0,0,0,0,0, "R1")]) ]) ])])) ]). icon([ group([ poly('#ff0000','',2,[ 432,144,432,160],0,1,1,10965,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 424,144,440,144],0,1,1,10964,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10963,0,0,[ ]), icon([ box('#ff0000','',424,152,440,168,0,1,0,10959,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',430,158,434,162,1,1,0,10957,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',432,173,1,1,1,104,14,10958,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,184,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 428,164,436,156],0,1,0,10955,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 428,156,436,164],0,1,0,10954,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10953,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',432,173,1,1,1,128,14,10956,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,184,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10952,0,0,0,0,[ attr("signal_name=", "VCC", 0, 1, 1, text('#0000ff',432,190,1,1,1,105,12,10962,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,200,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=VCC")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',432,174,1,1,1,42,12,10961,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,184,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',432,206,1,1,1,63,12,10960,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,216,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], "vcc",10951,0,0,0,0,[ attr("val=", "5V", 1, 0, 1, text('yellow',436,148,1,0,1,14,12,10968,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,158,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "5V")]) ]) ])])), attr("name=", "VCC", 1, 0, 1, text('yellow',432,131,1,1,1,21,12,10967,10,2,0,0,0,0,2,21,12,0,0,"",0,0,0,0,141,'',[ minilines(21,12,0,0,1,0,0,[ mini_line(21,10,2,0,0,0,[ str_block(0,21,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,21,10,2,0,0,0,0,0,0,0, "VCC")]) ]) ])])), attr("type=", "power", 0, 1, 1, text('yellow',432,160,1,1,1,70,12,10966,10,2,0,0,0,0,2,70,12,0,0,"",0,0,0,0,170,'',[ minilines(70,12,0,0,1,0,0,[ mini_line(70,10,2,0,0,0,[ str_block(0,70,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,70,10,2,0,0,0,0,0,0,0, "type=power")]) ]) ])])) ]). icon([ group([ box('#ff8000','',560,128,624,176,0,1,0,10986,0,0,0,0,0,'1',0,[ ]), poly('#ff8000','',2,[ 592,176,592,192],0,4,6,10985,0,0,0,0,0,0,0,'4',0,0, "0","",[ 0,14,6,0,'14','6','0'],[0,14,6,0,'14','6','0'],[ ]), oval('#ff8000','',568,128,616,176,2,4,6,10984,0,0,0,0,0,'4',0,[ ]), poly('#ff8000','',2,[ 588,164,596,136],1,4,1,10983,0,0,0,0,0,0,0,'4',0,0, "0","",[ 0,14,6,0,'14','6','0'],[0,14,6,0,'14','6','0'],[ ]) ], 10982,0,0,[ ]), icon([ box('#ff0000','',584,184,600,200,0,1,0,10978,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',590,190,594,194,1,1,0,10976,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',592,205,1,1,1,104,14,10977,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,216,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 588,196,596,188],0,1,0,10974,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 588,188,596,196],0,1,0,10973,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 10972,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',592,205,1,1,1,128,14,10975,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,216,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",10971,0,0,0,0,[ attr("signal_name=", "OUT", 0, 1, 1, text('#0000ff',592,222,1,1,1,105,12,10981,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,232,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=OUT")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',592,206,1,1,1,42,12,10980,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,216,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',592,238,1,1,1,63,12,10979,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,248,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], "gauge",10970,0,0,0,0,[ attr("type=", "gauge", 0, 1, 1, text('yellow',592,194,1,1,1,70,12,10989,10,2,0,0,0,0,2,70,12,0,0,"",0,0,0,0,204,'',[ minilines(70,12,0,0,1,0,0,[ mini_line(70,10,2,0,0,0,[ str_block(0,70,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,70,10,2,0,0,0,0,0,0,0, "type=gauge")]) ]) ])])), attr("V=", "0.066", 1, 1, 1, text('yellow',592,112,1,1,1,49,12,10988,10,2,0,0,0,0,2,49,12,0,0,"",0,0,0,0,122,'',[ minilines(49,12,0,0,1,0,0,[ mini_line(49,10,2,0,0,0,[ str_block(0,49,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,49,10,2,0,-1,0,0,0,0,0, "V=0.066")]) ]) ])])), attr("name=", "G1", 1, 0, 1, text('yellow',616,166,1,0,1,14,12,10987,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,176,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,-1,0,0,0,0,0, "G1")]) ]) ])])) ]). icon([ group([ box('#ff0000','',416,352,448,384,0,1,0,11385,0,0,0,0,0,'1',0,[ ]), poly('#ff0000','',2,[ 440,368,436,376],0,1,1,11384,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 432,368,428,376],0,1,1,11383,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 424,368,420,376],0,1,1,11382,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 432,352,432,368],0,1,1,11381,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 424,368,440,368],0,1,1,11380,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 11379,0,0,[ ]), icon([ box('#ff0000','',424,344,440,360,0,1,0,11375,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',430,350,434,354,1,1,0,11373,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',432,365,1,1,1,104,14,11374,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,376,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 428,356,436,348],0,1,0,11371,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 428,348,436,356],0,1,0,11370,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 11369,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',432,365,1,1,1,128,14,11372,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,376,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",11368,0,0,0,0,[ attr("signal_name=", "GND", 0, 1, 1, text('#0000ff',432,382,1,1,1,105,12,11378,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,392,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "signal_name=GND")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',432,366,1,1,1,42,12,11377,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,376,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',432,398,1,1,1,63,12,11376,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,408,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], "ground",11367,0,0,0,0,[ attr("name=", "GND", 0, 1, 1, text('yellow',432,336,1,1,1,56,12,11387,10,2,0,0,0,0,2,56,12,0,0,"",0,0,0,0,346,'',[ minilines(56,12,0,0,1,0,0,[ mini_line(56,10,2,0,0,0,[ str_block(0,56,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,56,10,2,0,0,0,0,0,0,0, "name=GND")]) ]) ])])), attr("type=", "ground", 0, 1, 1, text('yellow',432,324,1,1,1,77,12,11386,10,2,0,0,0,0,2,77,12,0,0,"",0,0,0,0,334,'',[ minilines(77,12,0,0,1,0,0,[ mini_line(77,10,2,0,0,0,[ str_block(0,77,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,77,10,2,0,0,0,0,0,0,0, "type=ground")]) ]) ])])) ]). icon([ group([ box('#0000ff','',480,224,512,256,0,1,0,12135,0,0,0,0,0,'1',0,[ ]), oval('#0000ff','',492,236,500,244,1,1,1,12136,0,0,0,0,0,'1',0,[ ]) ], 12134,0,0,[ ]), icon([ box('#0000ff','',488,232,504,248,0,1,0,12138,0,0,0,0,0,'1',0,[ ]), box('#0000ff','',494,238,498,242,0,1,0,12139,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',496,253,1,1,1,104,14,12140,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,264,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#0000ff','',2,[ 494,242,498,238],0,1,1,12142,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#0000ff','',2,[ 494,238,498,242],0,1,1,12143,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 12141,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',496,253,1,1,1,128,14,12144,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,264,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port-small",12137,0,0,0,0,[ attr("type=", "port", 0, 1, 1, text('#0000ff',496,286,1,1,1,63,12,12145,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,296,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',496,254,1,1,1,42,12,12146,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,264,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("signal_name=", "", 0, 1, 1, text('#0000ff',496,270,1,1,1,84,12,12147,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,280,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])) ]) ], "connection",12133,0,0,0,0,[ attr("type=", "connection", 0, 1, 1, text('yellow',496,244,1,1,1,105,12,12148,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,254,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "type=connection")]) ]) ])])), attr("name=", "CONN", 0, 1, 1, text('yellow',496,256,1,1,1,63,12,12149,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,266,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,0,0,0,0,0,0, "name=CONN")]) ]) ])])) ]). icon([ group([ box('#0000ff','',416,320,448,352,0,1,0,12410,0,0,0,0,0,'1',0,[ ]), oval('#0000ff','',428,332,436,340,1,1,1,12411,0,0,0,0,0,'1',0,[ ]) ], 12409,0,0,[ ]), icon([ box('#0000ff','',424,328,440,344,0,1,0,12413,0,0,0,0,0,'1',0,[ ]), box('#0000ff','',430,334,434,338,0,1,0,12414,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',432,349,1,1,1,104,14,12415,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,360,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#0000ff','',2,[ 430,338,434,334],0,1,1,12417,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#0000ff','',2,[ 430,334,434,338],0,1,1,12418,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 12416,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',432,349,1,1,1,128,14,12419,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,360,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port-small",12412,0,0,0,0,[ attr("type=", "port", 0, 1, 1, text('#0000ff',432,382,1,1,1,63,12,12420,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,392,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',432,350,1,1,1,42,12,12421,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,360,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("signal_name=", "", 0, 1, 1, text('#0000ff',432,366,1,1,1,84,12,12422,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,376,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])) ]) ], "connection",12408,0,0,0,0,[ attr("type=", "connection", 0, 1, 1, text('yellow',432,340,1,1,1,105,12,12423,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,350,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "type=connection")]) ]) ])])), attr("name=", "CONN", 0, 1, 1, text('yellow',432,352,1,1,1,63,12,12424,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,362,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,0,0,0,0,0,0, "name=CONN")]) ]) ])])) ]). icon([ group([ box('#0000ff','',480,320,512,352,0,1,0,12427,0,0,0,0,0,'1',0,[ ]), oval('#0000ff','',492,332,500,340,1,1,1,12428,0,0,0,0,0,'1',0,[ ]) ], 12426,0,0,[ ]), icon([ box('#0000ff','',488,328,504,344,0,1,0,12430,0,0,0,0,0,'1',0,[ ]), box('#0000ff','',494,334,498,338,0,1,0,12431,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',496,349,1,1,1,104,14,12432,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,360,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#0000ff','',2,[ 494,338,498,334],0,1,1,12434,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#0000ff','',2,[ 494,334,498,338],0,1,1,12435,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 12433,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',496,349,1,1,1,128,14,12436,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,360,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port-small",12429,0,0,0,0,[ attr("type=", "port", 0, 1, 1, text('#0000ff',496,382,1,1,1,63,12,12437,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,392,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',496,350,1,1,1,42,12,12438,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,360,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("signal_name=", "", 0, 1, 1, text('#0000ff',496,366,1,1,1,84,12,12439,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,376,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])) ]) ], "connection",12425,0,0,0,0,[ attr("type=", "connection", 0, 1, 1, text('yellow',496,340,1,1,1,105,12,12440,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,350,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "type=connection")]) ]) ])])), attr("name=", "CONN", 0, 1, 1, text('yellow',496,352,1,1,1,63,12,12441,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,362,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,0,0,0,0,0,0, "name=CONN")]) ]) ])])) ]). icon([ group([ box('#0000ff','',416,224,448,256,0,1,0,12130,0,0,0,0,0,'1',0,[ ]), oval('#0000ff','',428,236,436,244,1,1,1,12129,0,0,0,0,0,'1',0,[ ]) ], 12128,0,0,[ ]), icon([ box('#0000ff','',424,232,440,248,0,1,0,12124,0,0,0,0,0,'1',0,[ ]), box('#0000ff','',430,238,434,242,0,1,0,12122,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',432,253,1,1,1,104,14,12123,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,264,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#0000ff','',2,[ 430,242,434,238],0,1,1,12120,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#0000ff','',2,[ 430,238,434,242],0,1,1,12119,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 12118,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',432,253,1,1,1,128,14,12121,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,264,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port-small",12117,0,0,0,0,[ attr("type=", "port", 0, 1, 1, text('#0000ff',432,286,1,1,1,63,12,12127,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,296,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',432,254,1,1,1,42,12,12126,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,264,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("signal_name=", "", 0, 1, 1, text('#0000ff',432,270,1,1,1,84,12,12125,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,280,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])) ]) ], "connection",12116,0,0,0,0,[ attr("type=", "connection", 0, 1, 1, text('yellow',432,244,1,1,1,105,12,12132,10,2,0,0,0,0,2,105,12,0,0,"",0,0,0,0,254,'',[ minilines(105,12,0,0,1,0,0,[ mini_line(105,10,2,0,0,0,[ str_block(0,105,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,105,10,2,0,0,0,0,0,0,0, "type=connection")]) ]) ])])), attr("name=", "CONN", 0, 1, 1, text('yellow',432,256,1,1,1,63,12,12131,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,266,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,0,0,0,0,0,0, "name=CONN")]) ]) ])])) ]). ���������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/resistor.0tc.sym���������������������������������������������������������������0000644�0000764�0000764�00000014020�10064674140�017166� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,2,2,0,0,0,2,1,0,'Courier',0,69120,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/resistor.0tc.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 176,176,176,184],0,1,1,206,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 176,200,176,208],0,1,1,207,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',6,[ 176,184,168,186,184,190,168,194,184,198,176,200],0,1,1,208,0,0,0,0,0,0,0,'1',0,0, "00","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 2542,0,0,[ ]), icon([ box('#ff0000','',168,200,184,216,0,1,0,2595,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,206,178,210,0,1,0,2593,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,221,1,1,1,104,14,2594,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,232,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,212,180,204],0,1,1,2591,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,204,180,212],0,1,1,2590,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 2589,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,221,1,1,1,128,14,2592,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,232,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",2588,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,238,1,1,1,84,12,2598,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,248,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',176,222,1,1,1,42,12,2633,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,232,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,254,1,1,1,63,12,2596,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,264,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',168,168,184,184,0,1,0,2600,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,174,178,178,0,1,0,2601,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,189,1,1,1,104,14,2602,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,180,180,172],0,1,1,2604,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,172,180,180],0,1,1,2605,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 2603,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,189,1,1,1,128,14,2606,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",2599,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,206,1,1,1,84,12,2607,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',176,190,1,1,1,42,12,2621,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,222,1,1,1,63,12,2609,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 5946,0,0,[ attr("type=", "resistor", 0, 1, 0, text('yellow',164,186,1,2,1,91,12,546,10,2,0,0,0,0,2,91,12,0,0,"",0,0,0,0,196,'',[ minilines(91,12,0,0,2,0,0,[ mini_line(91,10,2,0,0,0,[ str_block(0,91,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,91,10,2,0,0,0,0,0,0,0, "type=resistor")]) ]) ])])), attr("val=", "1K", 1, 0, 0, text('yellow',188,192,1,0,1,14,12,547,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,202,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "1K")]) ]) ])])), attr("name=", "R", 1, 0, 0, text('yellow',188,180,1,0,1,7,12,548,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,190,'',[ minilines(7,12,0,0,0,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "R")]) ]) ])])) ]). ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/resistor.h.2tc.sym�������������������������������������������������������������0000644�0000764�0000764�00000014507�10064674140�017430� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,2,0,0,0,0,2,1,0,'Courier',0,57600,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/resistor.h.2tc.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 176,176,184,176],0,1,1,150,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 200,176,208,176],0,1,1,151,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',6,[ 184,176,186,184,190,168,194,184,198,168,200,176],0,1,1,152,0,0,0,0,0,0,0,'1',0,0, "00","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 1887,0,0,[ ]), icon([ box('#ff0000','',200,168,216,184,0,1,0,1959,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,174,210,178,0,1,0,1957,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,189,1,1,1,104,14,1958,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,180,212,172],0,1,1,1955,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,172,212,180],0,1,1,1954,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 1953,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,189,1,1,1,128,14,1956,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",1952,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,206,1,1,1,84,12,1962,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',208,190,1,1,1,42,12,1997,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,222,1,1,1,63,12,1960,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',168,168,184,184,0,1,0,1964,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,174,178,178,0,1,0,1965,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,189,1,1,1,104,14,1966,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,180,180,172],0,1,1,1968,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,172,180,180],0,1,1,1969,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 1967,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,189,1,1,1,128,14,1970,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",1963,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,206,1,1,1,84,12,1971,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',176,190,1,1,1,42,12,1985,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,222,1,1,1,63,12,1973,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 5255,0,0,[ attr("name=", "R", 1, 0, 0, text('yellow',192,140,1,1,1,7,12,578,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,150,'',[ minilines(7,12,0,0,1,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "R")]) ]) ])])), attr("val=", "1K", 1, 0, 0, text('yellow',192,152,1,1,1,14,12,579,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,162,'',[ minilines(14,12,0,0,1,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "1K")]) ]) ])])), attr("type=", "resistor", 0, 1, 0, text('yellow',196,202,1,1,1,91,12,580,10,2,0,0,0,0,2,91,12,0,0,"",0,0,0,0,212,'',[ minilines(91,12,0,0,1,0,0,[ mini_line(91,10,2,0,0,0,[ str_block(0,91,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,91,10,2,0,0,0,0,0,0,0, "type=resistor")]) ]) ])])), attr("tc=", "4.5E-3,2.15E-5", 0, 1, 0, text('yellow',192,190,1,1,1,119,12,581,10,2,0,0,0,0,2,119,12,0,0,"",0,0,0,0,200,'',[ minilines(119,12,0,0,1,0,0,[ mini_line(119,10,2,0,0,0,[ str_block(0,119,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,119,10,2,0,-1,0,0,0,0,0, "tc=4.5E-3,2.15E-5")]) ]) ])])) ]). �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/resistor.2tc.sym���������������������������������������������������������������0000644�0000764�0000764�00000014502�10064674140�017175� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,2,2,0,0,0,2,1,0,'Courier',0,57600,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/resistor.2tc.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 176,176,176,184],0,1,1,44,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 176,200,176,208],0,1,1,45,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',6,[ 176,184,168,186,184,190,168,194,184,198,176,200],0,1,1,46,0,0,0,0,0,0,0,'1',0,0, "00","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 2238,0,0,[ ]), icon([ box('#ff0000','',168,200,184,216,0,1,0,2294,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,206,178,210,0,1,0,2292,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,221,1,1,1,104,14,2293,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,232,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,212,180,204],0,1,1,2290,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,204,180,212],0,1,1,2289,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 2288,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,221,1,1,1,128,14,2291,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,232,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",2287,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,238,1,1,1,84,12,2297,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,248,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',176,222,1,1,1,42,12,2332,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,232,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,254,1,1,1,63,12,2295,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,264,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',168,168,184,184,0,1,0,2299,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,174,178,178,0,1,0,2300,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,189,1,1,1,104,14,2301,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,180,180,172],0,1,1,2303,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,172,180,180],0,1,1,2304,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 2302,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,189,1,1,1,128,14,2305,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",2298,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,206,1,1,1,84,12,2306,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',176,190,1,1,1,42,12,2320,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,222,1,1,1,63,12,2308,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 5673,0,0,[ attr("name=", "R", 1, 0, 0, text('yellow',188,180,1,0,1,7,12,556,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,190,'',[ minilines(7,12,0,0,0,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "R")]) ]) ])])), attr("val=", "1K", 1, 0, 0, text('yellow',188,192,1,0,1,14,12,557,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,202,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "1K")]) ]) ])])), attr("type=", "resistor", 0, 1, 0, text('yellow',164,186,1,2,1,91,12,558,10,2,0,0,0,0,2,91,12,0,0,"",0,0,0,0,196,'',[ minilines(91,12,0,0,2,0,0,[ mini_line(91,10,2,0,0,0,[ str_block(0,91,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,91,10,2,0,0,0,0,0,0,0, "type=resistor")]) ]) ])])), attr("tc=", "4.5E-3,2.15E-5", 0, 1, 0, text('yellow',176,210,1,1,1,119,12,559,10,2,0,0,0,0,2,119,12,0,0,"",0,0,0,0,220,'',[ minilines(119,12,0,0,1,0,0,[ mini_line(119,10,2,0,0,0,[ str_block(0,119,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,119,10,2,0,-1,0,0,0,0,0, "tc=4.5E-3,2.15E-5")]) ]) ])])) ]). ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/resistor.h.sym�����������������������������������������������������������������0000644�0000764�0000764�00000014451�10064674140�016737� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,2,0,0,0,0,2,1,0,'Courier',0,69120,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/resistor.h.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 176,176,184,176],0,1,1,225,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 200,176,208,176],0,1,1,226,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',6,[ 184,176,186,184,190,168,194,184,198,168,200,176],0,1,1,227,0,0,0,0,0,0,0,'1',0,0, "00","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 1185,0,0,[ ]), icon([ box('#ff0000','',200,168,216,184,0,1,0,1249,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,174,210,178,0,1,0,1247,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,189,1,1,1,104,14,1248,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,180,212,172],0,1,1,1245,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,172,212,180],0,1,1,1244,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 1243,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,189,1,1,1,128,14,1246,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",1242,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,206,1,1,1,84,12,1252,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',208,190,1,1,1,42,12,1287,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,222,1,1,1,63,12,1250,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',168,168,184,184,0,1,0,1254,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,174,178,178,0,1,0,1255,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,189,1,1,1,104,14,1256,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,180,180,172],0,1,1,1258,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,172,180,180],0,1,1,1259,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 1257,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,189,1,1,1,128,14,1260,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",1253,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,206,1,1,1,84,12,1261,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',176,190,1,1,1,42,12,1275,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,222,1,1,1,63,12,1263,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 4976,0,0,[ attr("tc=", "1E-4", 0, 1, 0, text('yellow',192,190,1,1,1,49,12,567,10,2,0,0,0,0,2,49,12,0,0,"",0,0,0,0,200,'',[ minilines(49,12,0,0,1,0,0,[ mini_line(49,10,2,0,0,0,[ str_block(0,49,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,49,10,2,0,-1,0,0,0,0,0, "tc=1E-4")]) ]) ])])), attr("type=", "resistor", 0, 1, 0, text('yellow',196,202,1,1,1,91,12,568,10,2,0,0,0,0,2,91,12,0,0,"",0,0,0,0,212,'',[ minilines(91,12,0,0,1,0,0,[ mini_line(91,10,2,0,0,0,[ str_block(0,91,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,91,10,2,0,0,0,0,0,0,0, "type=resistor")]) ]) ])])), attr("val=", "1K", 1, 0, 0, text('yellow',192,152,1,1,1,14,12,569,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,162,'',[ minilines(14,12,0,0,1,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "1K")]) ]) ])])), attr("name=", "R", 1, 0, 0, text('yellow',192,140,1,1,1,7,12,570,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,150,'',[ minilines(7,12,0,0,1,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "R")]) ]) ])])) ]). �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/SN.sym�������������������������������������������������������������������������0000644�0000764�0000764�00000020424�10064674140�015154� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,0,2,0,0,0,2,1,0,'Courier',0,69120,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/SN.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','White'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 208,224,192,216],2,1,1,187,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 192,192,192,224],0,1,1,188,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,192,192,200],0,1,1,189,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 176,208,192,208],0,1,1,190,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,176,208,192],0,1,1,191,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 208,224,208,240],0,1,1,192,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 8174,0,0,[ ]), icon([ box('#ff0000','',200,232,216,248,0,1,0,8252,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,238,210,242,0,1,0,8250,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,253,1,1,1,104,14,8251,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,264,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,244,212,236],0,1,1,8248,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,236,212,244],0,1,1,8247,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 8246,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,253,1,1,1,128,14,8249,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,264,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",8245,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,270,1,1,1,84,12,8255,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,280,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "e", 0, 1, 1, text('#0000ff',208,254,1,1,1,42,12,8321,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,264,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=e")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,286,1,1,1,63,12,8253,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,296,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',200,168,216,184,0,1,0,8265,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',206,174,210,178,0,1,0,8266,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',208,189,1,1,1,104,14,8267,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 204,180,212,172],0,1,1,8269,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 204,172,212,180],0,1,1,8270,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 8268,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',208,189,1,1,1,128,14,8271,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",8264,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',208,206,1,1,1,84,12,8272,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "c", 0, 1, 1, text('#0000ff',208,190,1,1,1,42,12,8309,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=c")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',208,222,1,1,1,63,12,8274,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',168,200,184,216,0,1,0,8276,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,206,178,210,0,1,0,8277,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,221,1,1,1,104,14,8278,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,232,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,212,180,204],0,1,1,8280,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,204,180,212],0,1,1,8281,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 8279,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,221,1,1,1,128,14,8282,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,232,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",8275,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,238,1,1,1,84,12,8283,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,248,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',176,222,1,1,1,42,12,8297,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,232,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,254,1,1,1,63,12,8285,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,264,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 8362,0,0,[ attr("name=", "Q", 1, 0, 0, text('yellow',200,196,1,0,1,7,12,488,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,206,'',[ minilines(7,12,0,0,0,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "Q")]) ]) ])])), attr("model=", "SN", 1, 0, 0, text('yellow',200,208,1,0,1,14,12,487,10,2,0,0,0,0,2,14,12,0,0,"",0,0,0,0,218,'',[ minilines(14,12,0,0,0,0,0,[ mini_line(14,10,2,0,0,0,[ str_block(0,14,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,14,10,2,0,0,0,0,0,0,0, "SN")]) ]) ])])), attr("type=", "NPN", 0, 1, 0, text('yellow',172,202,1,2,1,56,12,486,10,2,0,0,0,0,2,56,12,0,0,"",0,0,0,0,212,'',[ minilines(56,12,0,0,2,0,0,[ mini_line(56,10,2,0,0,0,[ str_block(0,56,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,56,10,2,0,0,0,0,0,0,0, "type=NPN")]) ]) ])])) ]). ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/capacitor.sym������������������������������������������������������������������0000644�0000764�0000764�00000014171�10064674140�016603� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,0,2,0,0,0,2,1,0,'Courier',0,69120,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/capacitor.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','White'). page(1,"",1,''). sym([ group([ poly('#ff0000','',2,[ 176,176,176,188],0,1,1,212,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 176,196,176,208],0,1,1,213,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 168,188,184,188],0,1,1,214,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 168,196,184,196],0,1,1,215,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 7483,0,0,[ ]), icon([ box('#ff0000','',168,168,184,184,0,1,0,7556,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,174,178,178,0,1,0,7554,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,189,1,1,1,104,14,7555,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,180,180,172],0,1,1,7552,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,172,180,180],0,1,1,7551,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 7550,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,189,1,1,1,128,14,7553,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",7549,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,206,1,1,1,84,12,7559,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "a", 0, 1, 1, text('#0000ff',176,190,1,1,1,42,12,7583,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,200,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=a")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,222,1,1,1,63,12,7557,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]), icon([ box('#ff0000','',168,200,184,216,0,1,0,7568,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,206,178,210,0,1,0,7566,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,221,1,1,1,104,14,7567,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,232,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,212,180,204],0,1,1,7564,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,204,180,212],0,1,1,7563,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 7562,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,221,1,1,1,128,14,7565,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,232,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], "port",7561,0,0,0,0,[ attr("signal_name=", "", 0, 1, 1, text('#0000ff',176,238,1,1,1,84,12,7571,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,248,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "b", 0, 1, 1, text('#0000ff',176,222,1,1,1,42,12,7595,10,2,0,0,0,0,2,42,12,0,0,"",0,0,0,0,232,'',[ minilines(42,12,0,0,1,0,0,[ mini_line(42,10,2,0,0,0,[ str_block(0,42,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,42,10,2,0,0,0,0,0,0,0, "name=b")]) ]) ])])), attr("type=", "port", 0, 1, 1, text('#0000ff',176,254,1,1,1,63,12,7569,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,264,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]) ], 7623,0,0,[ attr("name=", "C", 1, 0, 0, text('yellow',188,180,1,0,1,7,12,591,10,2,0,0,0,0,2,7,12,0,0,"",0,0,0,0,190,'',[ minilines(7,12,0,0,0,0,0,[ mini_line(7,10,2,0,0,0,[ str_block(0,7,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,7,10,2,0,0,0,0,0,0,0, "C")]) ]) ])])), attr("val=", "1pF", 1, 0, 0, text('yellow',188,192,1,0,1,21,12,590,10,2,0,0,0,0,2,21,12,0,0,"",0,0,0,0,202,'',[ minilines(21,12,0,0,0,0,0,[ mini_line(21,10,2,0,0,0,[ str_block(0,21,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,21,10,2,0,0,0,0,0,0,0, "1pF")]) ]) ])])), attr("type=", "capacitor", 0, 1, 0, text('yellow',164,186,1,2,1,98,12,589,10,2,0,0,0,0,2,98,12,0,0,"",0,0,0,0,196,'',[ minilines(98,12,0,0,2,0,0,[ mini_line(98,10,2,0,0,0,[ str_block(0,98,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,98,10,2,0,0,0,0,0,0,0, "type=capacitor")]) ]) ])])) ]). �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/SN.mod�������������������������������������������������������������������������0000644�0000764�0000764�00000000726�10064674140�015126� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������.MODEL SN NPN +BF=200 BR=45 XTB=1.80 EG=1.11 +VAF=175 VAR=12 IS=4.48E-16 XTI=3.00 +IKF=7.52E-03 IKR=1.60E-3 ISC=1.00E-16 NC=2.00 +TF=1.20E-10 TR=6.00E-08 ISE=1.00E-16 NE=1.50 +RC=248 RB=389 RBM=38.3 RE=1.6 +CJC=3.51E-13 VJC=0.4920 MJC=0.3200 XCJC=0.2360 +CJE=5.52E-13 VJE=0.5800 MJE=0.2900 KF=5.00E-15 +CJS=1.46E-13 VJS=1.00 MJS=0.00 AF=0.82 ������������������������������������������tgif-QPL-4.2.5/spice/README�������������������������������������������������������������������������0000644�0000764�0000764�00000013365�10064674212�014770� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/README,v 1.1 2004/06/18 23:19:38 william Exp $ */ This file is README in the spice subdirectory of the tgif distribution. Here are some notes on the ports and components feature of tgif. These features first appeared in tgif-4.1.35 and only works with the updated files in the spice subdirectory that was in the tgif-4.1.35 release. Also, please make sure you are running tgif-4.1.38 or newer since there have been bug fixed! Please read the CONNECTING OBJECTS section of the tgif man pages in addition to this note. tgif demo.obj Select NET as the export format Select Print() from the File Menu demo.net is the netlist file... Any port that's connected to the same signal name are considered "connected" For example, the signal name "BASE" is connected to 2 ports, "!R2!b" and "!Q2!b" (refer to the figure). R2 is a resistor and it has 2 ports, a and b. Q2 is a transistor of model type SN. It has 3 ports, c, b, and e (for collector, base, and emitter). The connection is between port b of R2 and port b (base) of Q2. demo.cmp is the component file... The beginning of each component is not indented. The first line of a component declares the component and has the format: <name>: <type> <name> corresponds to the "name" attribute of the component. <type> corresponds to the "type" attribute of the component. All other attributes of the component are listed (indented by a <TAB> character) following the first line. Note that the ports of a component are not listed. For example, if you right click on the Q1 transistor and select the Edit Attribute In Editor submenu of the Context Menu, you can see all the attributes of this component. Manipulating the connection... Select the wire named "VIN" and delete it. If you print the NetList, you will see that both the .net and the .cmp files are not changed! As I've said, this is a poorman's implemention of ports & connections. What happens is that port "a" of VIN has an attribute called "signal_name" whose value is still "VIN". Similarly, port "a" of R2 also has an attribute called "signal_name" whose value is still "VIN". When the wire is deleted, these ports don't know that their signalnames need to be cleared! Oh well... So, the truth is, there's really no "connection semantics" implemented in tgif. To clear them, select Clear Signal Name for a Port from the Ports and Signals submenu of the Special Menu. Mouse over a port (the port will be highlighted) and click the left mouse button. This will clear the signal_name attribute of the port. Keep finding ports you want to clear... When you are done with all the ports you want to clear, click the right mouse button. Go ahead and clear port "a" of VIN and port "a" of R2. The port should look different. To make a connection (which is just setting signal_name attributes of ports), there are 2 ways. One is to select Rename Signal Name for a Port from the Ports and Signals submenu of the Special Menu. This is very similiar to clearing signalnames. Let's not do this. The 2nd way is to select Connect Two Ports by a Wire from the Ports and Signals submenu of the Special Menu. You must click on 2 ports. At the end, it will prompt you for a signal name. Then it will ask you to place it. You can uncheck Show Wire Signal Name of the Ports and Signals submenu of the Special Menu if you don't want to see the signalname for the (useless) wire. How to constructor a component? Well, this is kind of involved... I'll just mention a few major points. 1) A component must be instantiated from a .sym file. So, you should build a symbol. To build the symbol, start with an empty file. First draw what it should look like. Don't add any attributes or ports yet. When you are done with the visual port of the symbol, select everything and select Group from the Arrange Menu. 2) Before you create the symbol object, you should add ports and attributes: a) For each port you need, instantiate "port.sym" from this directory. Right click on it and select the "name=" attribute from the Edit Attribute In Editor submenu of the Context Menu and enter the port name. b) For each attribute you need, create it simply as a text object. A component must have attributes named "name" and "type". Make sure you have created "name=" and "type=<sometype>" text objects (replace <sometype> with the actual type of the component). 3) Select all the text object and the visual part of the symbol, select Attach Attributes from the Attribute submenu of the Special Menu. Select Hide Attributes from the Attribute submenu of the Special Menu. 4) Move all the ports to the right places. Select Select All from the Edit Menu and selct Group from the Arrange Menu. Finally, select Make Symbolic from the Special Menu and save the file as <something>.sym. ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/spice/port.sym�����������������������������������������������������������������������0000644�0000764�0000764�00000005440�10064674140�015621� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.35 state(0,37,100.000,0,0,0,16,1,3,2,2,0,0,0,0,1,1,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/spice/port.sym,v 1.1 2004/06/18 23:18:56 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(12,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1 ]). script_frac("0.6"). fg_bg_colors('#0000ff','White'). page(1,"",1,''). sym([ box('#ff0000','',168,168,184,184,0,1,0,750,0,0,0,0,0,'1',0,[ ]), box('#ff0000','',174,174,178,178,0,1,0,541,0,0,0,0,0,'1',0,[ attr("view=", "conn,1,0", 0, 1, 0, text('#0000ff',176,189,1,1,1,104,14,561,11,3,0,0,0,0,2,104,14,0,0,"",0,0,0,0,200,'',[ minilines(104,14,0,0,1,0,0,[ mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "view=conn,1,0")]) ]) ])])) ]), group([ poly('#ff0000','',2,[ 172,180,180,172],0,1,1,532,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]), poly('#ff0000','',2,[ 172,172,180,180],0,1,1,537,0,0,0,0,0,0,0,'1',0,0, "0","",[ 0,8,3,0,'8','3','0'],[0,8,3,0,'8','3','0'],[ ]) ], 540,0,0,[ attr("view=", "disconn,0,1", 0, 1, 0, text('#0000ff',176,189,1,1,1,128,14,563,11,3,0,0,0,0,2,128,14,0,0,"",0,0,0,0,200,'',[ minilines(128,14,0,0,1,0,0,[ mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-1,0,0,0,0,0, "view=disconn,0,1")]) ]) ])])) ]) ], 784,0,0,[ attr("signal_name=", "", 0, 1, 0, text('#0000ff',176,206,1,1,1,84,12,559,10,2,0,0,0,0,2,84,12,0,0,"",0,0,0,0,216,'',[ minilines(84,12,0,0,1,0,0,[ mini_line(84,10,2,0,0,0,[ str_block(0,84,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,84,10,2,0,0,0,0,0,0,0, "signal_name=")]) ]) ])])), attr("name=", "", 0, 1, 0, text('#0000ff',176,190,1,1,1,35,12,612,10,2,0,0,0,0,2,35,12,0,0,"",0,0,0,0,200,'',[ minilines(35,12,0,0,1,0,0,[ mini_line(35,10,2,0,0,0,[ str_block(0,35,10,2,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,69120,35,10,2,0,0,0,0,0,0,0, "name=")]) ]) ])])), attr("type=", "port", 0, 1, 0, text('#0000ff',176,222,1,1,1,63,12,613,10,2,0,0,0,0,2,63,12,0,0,"",0,0,0,0,232,'',[ minilines(63,12,0,0,1,0,0,[ mini_line(63,10,2,0,0,0,[ str_block(0,63,10,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,69120,63,10,2,0,-1,0,0,0,0,0, "type=port")]) ]) ])])) ]). ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/exec.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000007577�11602233311�014075� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/exec.e,v 1.8 2011/05/16 16:21:57 william Exp $ */ #ifndef _EXEC_E_ #define _EXEC_E_ #include "list.e" extern int execAnimating; extern int execAnimateRedraw; extern int execCurDepth; extern int replaceAttrFirstValueRedraw; extern int execNavigateBack; extern int userAbortExec; extern struct AttrRec * warpToAttr; extern char * cmdToExecAfterHyperJump; extern struct StrRec * topTmpStr; extern struct StrRec * botTmpStr; typedef struct tagReplAttrValueCallbackInfo { struct ObjRec *obj_ptr; /* a top level object */ struct AttrRec *attr_ptr; char *new_attr_value; void *pv_userdata; } ReplAttrValueCallbackInfo; typedef int (ReplAttrValueCallback)ARGS_DECL((ReplAttrValueCallbackInfo*)); #ifdef _INCLUDE_FROM_EXEC_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_EXEC_C_*/ extern void CleanTmpStr ARGS_DECL((void)); extern int PrependToTmpStr ARGS_DECL((char*)); extern int AppendToTmpStr ARGS_DECL((char*)); extern int ExecuteCmdGetResult ARGS_DECL((char*, CVList*, int max_lines)); extern struct ObjRec * FindObjWithName ARGS_DECL((struct ObjRec *BotObj, struct ObjRec *ObjPtr, char *ObjName, int InsideRootObj, int InsideThisObj, struct ObjRec **OwnerObj, struct ObjRec **TopOwner)); extern int PipeReachedEOF ARGS_DECL((FILE*)); extern int WaitForEvent ARGS_DECL((FILE*, int fp_is_pipe, int fp_is_named_pipe, int *pn_quit, int what_to_do_with_x_events, AbortCallbackFunc*, void*)); extern int DoLaunch ARGS_DECL((struct AttrRec *, struct ObjRec *)); extern void SetReplaceAttrValueCallback ARGS_DECL((ReplAttrValueCallback*, void *pv_userdata)); extern int ReplaceAttrFirstValue ARGS_DECL((struct ObjRec *, struct AttrRec *, char *)); extern int ReplaceAttrAllValues ARGS_DECL((struct ObjRec *, struct AttrRec *, struct StrRec **ppTopStr, struct StrRec **ppBotStr)); extern void JustReadFileIntoAttr ARGS_DECL((FILE*, struct AttrRec *attr_ptr, struct ObjRec *attr_owner_obj)); extern int DoExec ARGS_DECL((struct AttrRec *, struct ObjRec *)); extern void ResetExec ARGS_DECL((int nStart)); extern void ExecCmdsFromFile ARGS_DECL((char*)); extern void ExecCmdsFromTmp ARGS_DECL((char *tmp_fname)); extern void StartExecCmdsFromFile ARGS_DECL((void)); extern int BeginExecCommandsFromBuffer ARGS_DECL((void)); extern int ExecACommandFromBuffer ARGS_DECL((char *buf, int *pn_quit)); extern void EndExecCommandsFromBuffer ARGS_DECL((void)); extern void CleanUpExec ARGS_DECL((void)); extern void InitExec ARGS_DECL((void)); #ifdef _INCLUDE_FROM_EXEC_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_EXEC_C_*/ #endif /*_EXEC_E_*/ ���������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tangram.sym��������������������������������������������������������������������������0000644�0000764�0000764�00000001213�11602233313�015145� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������state(0,14,100,0,0,0,16,1,4,1,1,0,0,1,0,1,0,0,0,7,0,0,0,10,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/tangram.sym,v 1.1 2004/06/18 23:20:01 william Exp $ % sym([ polygon('yellow',5,[ 128,96,96,128,128,160,160,128,128,96],0,0,1,0,79,0,0,[ ]), poly('yellow',2,[ 96,128,160,128],0,0,1,0,0,0,0,0,[ ]), poly('yellow',2,[ 112,112,144,112],0,0,1,1,0,0,0,0,[ ]), poly('yellow',2,[ 128,112,128,160],0,0,1,2,0,0,0,0,[ ]), poly('yellow',2,[ 112,112,112,128],0,0,1,3,0,0,0,0,[ ]), poly('yellow',2,[ 128,112,144,128],0,0,1,4,0,0,0,0,[ ]) ],[ attr("name=", "Tangram", 1, 0, 0, text('yellow',128,160,3,2,3,1,1,0,1,65,17,80,0,14,3,0,0,0,[ "Tangram"])) ]). �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/launch-demo.obj����������������������������������������������������������������������0000644�0000764�0000764�00000012401�11602233312�015652� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 2.12-p15 state(0,27,100,0,0,0,8,1,0,2,0,0,0,1,0,1,0,0,0,3,1,0,0,10,0,0,1,1,0,16,1). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/launch-demo.obj,v 1.1 2004/09/14 05:26:24 william Exp $ % %W% % group([ box('yellow',176,224,208,256,0,1,0,27,0,0,0,[ ]), polygon('yellow',8,[ 176,232,192,232,192,224,208,240,192,256,192,248,176,248,176,232],2,1,1,0,23,0,0,0,[ ]), polygon('yellow',5,[ 176,248,177,250,192,250,192,248,176,248],1,1,1,0,353,0,0,0,[ ]), polygon('yellow',5,[ 192,256,193,258,209,242,208,240,192,256],1,1,1,0,354,0,0,0,[ ]) ], 375,0,[ attr("warp_to=", "launch-demo-1", 1, 1, 0, text('yellow',192,256,0,0,3,1,1,0,1,198,22,28,1,18,4,0,0,0,0,[ "warp_to=launch-demo-1"])) ]). group([ text('green',88,64,0,0,3,5,0,0,1,241,118,388,1,18,4,0,2,0,0,[ "Modify the ""dir"" attributes.", "Hold down the <Shift> key", "and click the middle button on", "any one of these objects to see", "LAUNCH and WART demoes."]), text('green',64,64,0,0,3,1,0,0,1,16,22,390,1,18,4,0,0,0,0,[ "1)"]), text('green',64,88,0,0,3,1,0,0,1,16,22,392,1,18,4,0,0,0,0,[ "2)"]) ], 404,0,[ ]). xbm('cyan',460,288,500,331,0,223,0,40,43,0,0,0,0,0,0,0,0,0, "","", "0009f800000007fe000000fffe0000003fff0000003fff0000001fff0000001f ff0000001fff0000001ffe000c003ffe000e003fff000e000ffe00ce0003fe1c 6f0003fe3e3f00007efe3f00007ffe1f00003ffe0f0003ffff0e0007ffff1f00 07ffff1f0007fc3f9f0007f99f9f0007f99fbe4e07ff9fbe4307ff3ffcb307fe 7ffc7fa7fe7ffc3ffffffffc1ffffe7fd800fffe7fc001ffffffc000ffffffc0 003fffffc000177fffc000007fffc000007fffc00000ffffc00000ffffc00000 ffffc00000ff80c00000c0004000000000000000000000",[ attr("launch=", "xterm -rw -e man $(title)", 1, 1, 0, text('yellow',480,344,0,0,3,1,1,0,1,266,22,200,1,18,4,0,0,0,0,[ "launch=xterm -rw -e man $(title)"])), attr("title=", "tgif", 1, 1, 0, text('yellow',480,328,0,0,3,1,1,0,1,67,22,202,1,18,4,0,0,0,0,[ "title=tgif"])) ]). xbm('cyan',448,64,513,129,0,283,0,65,65,0,0,0,0,0,0,0,0,0, "","", "000000000000000001ffffffffffffffc0300000000000000606000000000000 0030400000000000000104000000000000001040000000000000010400000000 0000001040007fffffff000104000ffffffff800104000c0000001800104000d ffffffd800104000daaaaaad800104000d5555555800104000daaaaaad800104 000d5155555800104000daaaaaad800104000d5155555800104000da0aaaad80 0104000d4055555800104000da0aaaad800104000d5155555800104000daaaaa ad800104000d5155555800104000daaaaaad800104000d5555555800104000da aaaaad800104000d5555555800104000daaaaaad800104000dffffffd8001040 00c0000001800104000ffffffff8001040007fffffff00010400000000000000 10400000000000000104007fffffffff0010400c00000000180104018aaaaaaa a8c010403155555555460104062aaaaaaaaa301040600000000003010407ffff fffffff010407fffffffffff0104000000000000001040000000000000010400 0000000000001040000000000000010400000000000000104000000000000001 0400000000000000104000000000000001040000000000000010400000000000 0001040000000000000010400000000000000104000000000000001040000000 0000000104000000000000001040000000000000010400000000000000104000 000000000001060000000000000030300000000000000601ffffffffffffffc0 00000000000000000",[ attr("launch=", "xterm &", 1, 1, 0, text('yellow',480,128,0,0,3,1,1,0,1,127,22,285,1,18,4,0,0,0,0,[ "launch=xterm &"])), attr("", "local", 1, 1, 0, text('yellow',480,104,0,0,3,1,1,0,1,36,22,286,1,18,4,0,0,0,0,[ "local"])) ]). xbm('yellow',448,176,513,241,0,554,0,65,65,0,0,0,0,0,0,0,0,0, "","", "000000000000000001ffffffffffffffc0300000000000000606000000000000 0030400000000000000104000000000000001040000000000000010400000000 0000001040007fffffff000104000ffffffff800104000c0000001800104000d ffffffd800104000daaaaaad800104000d5555555800104000daaaaaad800104 000d5155555800104000daaaaaad800104000d5155555800104000da0aaaad80 0104000d4055555800104000da0aaaad800104000d5155555800104000daaaaa ad800104000d5155555800104000daaaaaad800104000d5555555800104000da aaaaad800104000d5555555800104000daaaaaad800104000dffffffd8001040 00c0000001800104000ffffffff8001040007fffffff00010400000000000000 10400000000000000104007fffffffff0010400c00000000180104018aaaaaaa a8c010403155555555460104062aaaaaaaaa301040600000000003010407ffff fffffff010407fffffffffff0104000000000000001040000000000000010400 0000000000001040000000000000010400000000000000104000000000000001 0400000000000000104000000000000001040000000000000010400000000000 0001040000000000000010400000000000000104000000000000001040000000 0000000104000000000000001040000000000000010400000000000000104000 000000000001060000000000000030300000000000000601ffffffffffffffc0 00000000000000000",[ attr("launch=", "xterm -rw -e rsh $(host) &", 1, 1, 0, text('yellow',480,240,0,0,3,1,1,0,1,277,22,555,1,18,4,0,0,0,0,[ "launch=xterm -rw -e rsh $(host) &"])), attr("host=", "lanai", 1, 1, 0, text('yellow',480,216,0,0,3,1,1,0,1,81,22,556,1,18,4,0,0,0,0,[ "host=lanai"])) ]). group([ text('green',88,320,0,0,3,7,0,0,1,292,166,615,1,18,4,0,2,0,0,[ "To get a fancier look. Select an", "object and type <Meta>m.", "Then use left button to get a popup", "menu; select an attribute; click right", "button to hide the attribute or click", "the middle button to hide the attribute", "name."]), text('green',64,320,0,0,3,1,0,0,1,16,22,616,1,18,4,0,0,0,0,[ "3)"]) ], 646,0,[ ]). ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tdgtbmpl.c���������������������������������������������������������������������������0000644�0000764�0000764�00000122601�11602233313�014750� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtbmpl.c,v 1.7 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_TDGTBMPL_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "auxtext.e" #include "choose.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "font.e" #include "mainloop.e" #include "menu.e" #include "msg.e" #include "names.e" #include "pattern.e" #include "raster.e" #include "rect.e" #include "scroll.e" #include "setup.e" #include "strtbl.e" #include "tdgtbmpl.e" #include "text.e" #include "tidget.e" #include "util.e" /* * A BmpList control looks like the following: * * +----------------------------------------------+ * | +-------------------------------------+----+ | * | | | | | * | | dsp_win |scr | | * | | |_win| | * | | | | | * | +-------------------------------------+----+ | * +----------------------------------------------+ * * The outside is windowPadding+[vh]_pad. * The inside windows have no decorations. The left one is the * dsp_win and the right one is scr_win. * The width of scr_win is 18 in 3D mode. This includes a 2-pixel * decoration all around. * The width of dsp_win is gap+(bmp_w+gap)*num_cols and the height of dsp_win * is gap+(bmp_h+gap)*num_visible_lines. */ static void RedrawTdgtBmpList ARGS_DECL((TidgetInfo *pti)); static int TdgtBmpListEventHandler ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo *handling_pti)); static int IsTdgtBmpListEvent ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo **ppti_handler_tidget_return)); static void DestroyTdgtBmpList ARGS_DECL((TidgetInfo *pti)); static void MapTdgtBmpList ARGS_DECL((TidgetInfo *pti)); static void TdgtBmpListMoveResize ARGS_DECL((TidgetInfo *pti, int x, int y, int w, int h)); static int TdgtBmpListSendCmd ARGS_DECL((TidgetInfo *pti, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); /* --------------------- Utility Functions --------------------- */ static void FreeBmpListItemInfo(pblii) BmpListItemInfo *pblii; { if (pblii->pf_free_callback != NULL) { /* the callback function must also free pblii */ (pblii->pf_free_callback)(pblii); } else { if (pblii->pixmap != None) { XFreePixmap(mainDisplay, pblii->pixmap); } free(pblii); } } static int TdgtBmpListGetNumRows(pTdgtBmpList) TdgtBmpList *pTdgtBmpList; { int num_bitmaps=ListLength(&pTdgtBmpList->list); int num_cols=pTdgtBmpList->num_cols; if ((num_bitmaps % num_cols) == 0) { return (int)(num_bitmaps / num_cols); } else { return 1+(int)(num_bitmaps / num_cols); } } /* --------------------- RedrawTdgtBmpList() --------------------- */ static void RedrawTdgtBmpListItem(pTdgtBmpList, index, x, y, pblii) TdgtBmpList *pTdgtBmpList; int index, x, y; BmpListItemInfo *pblii; { XGCValues values; if (pblii->depth == 1) { values.foreground = myFgPixel; values.background = myBgPixel; values.function = GXcopy; values.fill_style = FillStippled; values.ts_x_origin = x; values.ts_y_origin = y; values.stipple = pblii->pixmap; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground | GCBackground | GCFunction | GCFillStyle | GCTileStipXOrigin | GCTileStipYOrigin | GCStipple, &values); XFillRectangle(mainDisplay, pTdgtBmpList->dsp_win, gTidgetManager.gc, x, y, pblii->width, pblii->height); if (index == pTdgtBmpList->marked_index) { values.foreground = myFgPixel^myBgPixel; values.fill_style = FillSolid; values.function = GXxor; XChangeGC(mainDisplay, gTidgetManager.gc, GCForeground | GCFillStyle | GCFunction, &values); XFillRectangle(mainDisplay, pTdgtBmpList->dsp_win, gTidgetManager.gc, x, y, pblii->width, pblii->height); } TidgetManagerResetGC(); } else { #ifdef _TGIF_DBG /* debug, do not translate */ sprintf(gszMsgBox, "Bitmap depth of %1d not supported in %s().\n", pblii->depth, "RedrawTdgtBmpListItem"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); #endif /* _TGIF_DBG */ } } static void RedrawTdgtBmpListScrollWindow(pTdgtBmpList) TdgtBmpList *pTdgtBmpList; { double frac=(double)0, start_frac=(double)0; int block_h=0, block_start=0, scr_area_h=pTdgtBmpList->scr_win_info.h; int num_rows=TdgtBmpListGetNumRows(pTdgtBmpList); int first_visible_row=(pTdgtBmpList->first_index/pTdgtBmpList->num_cols); start_frac = (num_rows > 0) ? (double)(((double)first_visible_row) / ((double)num_rows)) : (((double)0)); /* starting pixel */ block_start = (int)(scr_area_h * start_frac); if (num_rows > pTdgtBmpList->num_visible_lines) { frac = (double)(((double)pTdgtBmpList->num_visible_lines) / ((double)num_rows)); } else { frac = (double)1; } if (pTdgtBmpList->first_index+pTdgtBmpList->num_visible_lines >= num_rows) { block_h = scr_area_h - block_start; } else { block_h = (int)(scr_area_h * frac); } TgDrawScrollBar(mainDisplay, pTdgtBmpList->scr_win, VERT_SCROLLBAR, 0, 0, scrollBarW, scr_area_h, start_frac, pTdgtBmpList->num_visible_lines, num_rows); } static void RedrawTdgtBmpListDspWindow(pTdgtBmpList) TdgtBmpList *pTdgtBmpList; { int i=0, x=0, y=0, gap=pTdgtBmpList->gap; CVListElem *pElem=NULL, *pNextElem=NULL; XClearWindow(mainDisplay, pTdgtBmpList->dsp_win); for (i=0, pElem=ListFirst(&pTdgtBmpList->list); pElem != NULL; pElem=ListNext(&pTdgtBmpList->list, pElem), i++) { if (i == pTdgtBmpList->first_index) { break; } } if (pElem == NULL) return; x = y = gap; for ( ; pElem != NULL; pElem=pNextElem, i++) { BmpListItemInfo *pblii=(BmpListItemInfo*)(pElem->obj); BmpListItemInfo *pblii_next=NULL; RedrawTdgtBmpListItem(pTdgtBmpList, i, x, y, pblii); x += pTdgtBmpList->one_bmp_w + gap; pNextElem = ListNext(&pTdgtBmpList->list, pElem); if (pNextElem != NULL) { pblii_next = (BmpListItemInfo*)(pNextElem->obj); if (x+pTdgtBmpList->one_bmp_w > pTdgtBmpList->dsp_win_info.w) { x = gap; y += pTdgtBmpList->one_bmp_h+gap; if (y >= pTdgtBmpList->dsp_win_info.h) { break; } } } } } static void RedrawTdgtBmpListBaseWindow(pTdgtBmpList) TdgtBmpList *pTdgtBmpList; { if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, pTdgtBmpList->pti->tci.win_info.w, pTdgtBmpList->pti->tci.win_info.h); TgDrawThreeDButton(mainDisplay, pTdgtBmpList->pti->tci.win, gTidgetManager.gc, &bbox, TGBS_LOWRED, 2, FALSE); TidgetManagerResetGC(); } } static void RedrawTdgtBmpList(pti) TidgetInfo *pti; { TdgtBmpList *pTdgtBmpList=(TdgtBmpList*)(pti->tidget); XEvent ev; RedrawTdgtBmpListScrollWindow(pTdgtBmpList); RedrawTdgtBmpListDspWindow(pTdgtBmpList); RedrawTdgtBmpListBaseWindow(pTdgtBmpList); while (XCheckWindowEvent(mainDisplay, pTdgtBmpList->pti->tci.win, ExposureMask, &ev)) ; } /* --------------------- TdgtBmpListEventHandler() --------------------- */ static int TdgtBmpListScrollItemCallback(pv_userdata) void *pv_userdata; /* returns TRUE to cancel scrolling */ { TdgtBmpList *pTdgtBmpList=((TdgtBmpList*)pv_userdata); int num_visible_lines=pTdgtBmpList->num_visible_lines; int num_cols=pTdgtBmpList->num_cols; int length=ListLength(&pTdgtBmpList->list); if (pTdgtBmpList->scr_dir == SCRL_UP) { if (pTdgtBmpList->first_index == 0) return FALSE; pTdgtBmpList->first_index -= num_cols; } else { if (length <= num_visible_lines || pTdgtBmpList->first_index+num_visible_lines == length) { return FALSE; } pTdgtBmpList->first_index += num_cols; } RedrawTidget(pTdgtBmpList->pti); XSync(mainDisplay, False); return FALSE; } static int TdgtBmpListScrollPageCallback(pv_userdata) void *pv_userdata; /* returns TRUE to cancel scrolling */ { TdgtBmpList *pTdgtBmpList=((TdgtBmpList*)pv_userdata); int num_visible_lines=pTdgtBmpList->num_visible_lines; int length=ListLength(&pTdgtBmpList->list); if (pTdgtBmpList->scr_dir == SCRL_UP) { if (pTdgtBmpList->first_index == 0) return FALSE; pTdgtBmpList->first_index -= num_visible_lines; if (pTdgtBmpList->first_index < 0) pTdgtBmpList->first_index = 0; } else { if (length <= num_visible_lines || pTdgtBmpList->first_index+num_visible_lines == length) { return FALSE; } pTdgtBmpList->first_index += num_visible_lines; if (pTdgtBmpList->first_index+num_visible_lines >= length) { pTdgtBmpList->first_index = length-num_visible_lines; } } RedrawTidget(pTdgtBmpList->pti); XSync(mainDisplay, False); return FALSE; } static int DoTdgtBmpListBtnScroll(pTdgtBmpList, scroll_page, scr_dir, pbbox) TdgtBmpList *pTdgtBmpList; int scroll_page, scr_dir; struct BBRec *pbbox; /* returns TRUE if the done scrolling */ { int num_visible_lines=pTdgtBmpList->num_visible_lines; int num_rows=TdgtBmpListGetNumRows(pTdgtBmpList); int num_cols=pTdgtBmpList->num_cols; ScrollBtnCallbackInfo sbci; pTdgtBmpList->scr_dir = scr_dir; memset(&sbci, 0, sizeof(ScrollBtnCallbackInfo)); if (scroll_page) { sbci.ms = 200; sbci.pv_userdata = pTdgtBmpList; sbci.pf_scroll_btn_callback = TdgtBmpListScrollPageCallback; if (TgPressButtonLoop(mainDisplay, pTdgtBmpList->scr_win, NULL, &sbci)) { if (scr_dir == SCRL_UP) { if (pTdgtBmpList->first_index == 0) return TRUE; pTdgtBmpList->first_index -= num_visible_lines; if (pTdgtBmpList->first_index < 0) pTdgtBmpList->first_index = 0; } else { if (num_rows <= num_visible_lines || (pTdgtBmpList->first_index/num_cols)+num_visible_lines == num_rows) { return TRUE; } pTdgtBmpList->first_index += num_visible_lines; if ((pTdgtBmpList->first_index/num_cols)+num_visible_lines >= num_rows) { pTdgtBmpList->first_index = (num_rows-num_visible_lines)*num_cols; } } } } else { sbci.ms = 50; sbci.pv_userdata = pTdgtBmpList; sbci.pf_scroll_btn_callback = TdgtBmpListScrollItemCallback; if (TgPressButtonLoop(mainDisplay, pTdgtBmpList->scr_win, pbbox, &sbci)) { if (scr_dir == SCRL_UP) { if (pTdgtBmpList->first_index == 0) return TRUE; pTdgtBmpList->first_index -= num_cols; } else { if (num_rows <= num_visible_lines || (pTdgtBmpList->first_index/num_cols)+num_visible_lines == num_rows) { return TRUE; } pTdgtBmpList->first_index += num_cols; } } } return FALSE; } static void DoDragInTdgtBmpList(pTdgtBmpList, button_ev, btn_y, btn_offset) TdgtBmpList *pTdgtBmpList; XButtonEvent *button_ev; int btn_y, btn_offset; { int num_rows=TdgtBmpListGetNumRows(pTdgtBmpList); int num_visible_lines=pTdgtBmpList->num_visible_lines; double frac=(double)0, start_frac=(double)0; int block_h=0, block_start=0, done=FALSE; int scr_area_h=pTdgtBmpList->scr_win_info.h; if (num_rows <= num_visible_lines) return; frac = (double)((double)num_visible_lines / (double)(num_rows)); block_h = (int)(scr_area_h * frac); if (num_rows > pTdgtBmpList->num_visible_lines) { frac = (double)((double)pTdgtBmpList->num_visible_lines / (double)(num_rows)); block_h = (int)(((double)(scr_area_h-(scrollBarW<<1))) * frac); } else { frac = 1.0; block_h = scr_area_h-(scrollBarW<<1); } if (threeDLook) { block_start = button_ev->y+btn_offset;; start_frac = (double)((double)(block_start-scrollBarW) / (double)(scr_area_h-(scrollBarW<<1))); if (block_start+block_h >= scr_area_h-scrollBarW) { pTdgtBmpList->first_index = (num_rows - num_visible_lines) * pTdgtBmpList->num_cols; } else { pTdgtBmpList->first_index = (int)(num_rows * start_frac) * pTdgtBmpList->num_cols; } } else { block_start = button_ev->y; start_frac = (double)((double)(block_start) / (double)(scr_area_h)); if (block_start+block_h >= scr_area_h) { pTdgtBmpList->first_index = (num_rows - num_visible_lines) * pTdgtBmpList->num_cols; } else { pTdgtBmpList->first_index = (int)(num_rows * start_frac) * pTdgtBmpList->num_cols; } } RedrawTidget(pTdgtBmpList->pti); XGrabPointer(mainDisplay, pTdgtBmpList->scr_win, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); while (!done) { XEvent ev; XNextEvent(mainDisplay, &ev); if (ev.type == Expose || ev.type == VisibilityNotify) { ExposeEventHandler(&ev, TRUE); } else if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); if (debugNoPointerGrab) XSync(mainDisplay, False); done = TRUE; } else if (ev.type == MotionNotify) { int new_name_first=0, y=ev.xmotion.y; if (threeDLook) { y += btn_offset; start_frac = (double)(((double)(y-scrollBarW)) / ((double)(scr_area_h-(scrollBarW<<1)))); if (y <= scrollBarW) { new_name_first = 0; } else if (y+block_h >= scr_area_h-scrollBarW) { new_name_first = (num_rows - num_visible_lines) * pTdgtBmpList->num_cols; } else { new_name_first = (int)(num_rows * start_frac) * pTdgtBmpList->num_cols; } } else { start_frac = (double)(((double)y) / ((double)scr_area_h)); if (y <= 0) { new_name_first = 0; } else if (y+block_h >= scr_area_h) { new_name_first = (num_rows - num_visible_lines) * pTdgtBmpList->num_cols; } else { new_name_first = (int)(num_rows * start_frac) * pTdgtBmpList->num_cols; } } if (pTdgtBmpList->first_index != new_name_first) { pTdgtBmpList->first_index = new_name_first; RedrawTidget(pTdgtBmpList->pti); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } } static void TdgtBmpListScrollHandler(pTdgtBmpList, button_ev) TdgtBmpList *pTdgtBmpList; XButtonEvent *button_ev; { int do_drag=FALSE, btn_offset=0, scr_area_h=pTdgtBmpList->scr_win_info.h; if (!threeDLook && button_ev->button == Button3 && button_ev->type == ButtonPress) { if (DoTdgtBmpListBtnScroll(pTdgtBmpList, ((button_ev->state & (ShiftMask|ControlMask)) != 0), SCRL_UP, NULL)) { return; } } else if (!threeDLook && button_ev->button == Button1 && button_ev->type == ButtonPress) { if (DoTdgtBmpListBtnScroll(pTdgtBmpList, ((button_ev->state & (ShiftMask|ControlMask)) != 0), SCRL_DN, NULL)) { return; } } else if (button_ev->button == Button1 && button_ev->type == ButtonPress) { if (button_ev->y < scrollBarW || button_ev->y >= scr_area_h-scrollBarW) { int which=0; struct BBRec bbox; if (button_ev->y < scrollBarW) { which = SCRL_UP; SetBBRec(&bbox, 0, 0, scrollBarW, scrollBarW); } else { which = SCRL_DN; SetBBRec(&bbox, 0, scr_area_h-scrollBarW, scrollBarW, scr_area_h); } if (DoTdgtBmpListBtnScroll(pTdgtBmpList, FALSE, which, &bbox)) { return; } } else { double start_frac=(double)0; int hit=0; int num_rows=TdgtBmpListGetNumRows(pTdgtBmpList); int first_visible_row= (pTdgtBmpList->first_index/pTdgtBmpList->num_cols); start_frac = (num_rows > 0) ? ((double)(((double)first_visible_row) / (double)num_rows)) : ((double)0); hit = TgGetScrollHit(button_ev->x, button_ev->y, VERT_SCROLLBAR, scrollBarW, scr_area_h, start_frac, pTdgtBmpList->num_visible_lines, num_rows, &btn_offset); if (hit == 0) { do_drag = TRUE; } else { if (DoTdgtBmpListBtnScroll(pTdgtBmpList, TRUE, (hit < 0 ? SCRL_UP : SCRL_DN), NULL)) { return; } } } } else if (!threeDLook && button_ev->button == Button2 && button_ev->type == ButtonPress) { do_drag = TRUE; } if (do_drag) { DoDragInTdgtBmpList(pTdgtBmpList, button_ev, button_ev->y, btn_offset); } else { RedrawTidget(pTdgtBmpList->pti); } } static int TdgtBmpListControlChar(pTdgtBmpList, key_ev, key_sym) TdgtBmpList *pTdgtBmpList; XKeyEvent *key_ev; KeySym key_sym; { int length=ListLength(&pTdgtBmpList->list); int num_visible_lines=pTdgtBmpList->num_visible_lines; int num_cols=pTdgtBmpList->num_cols; int i=0; if (key_ev->state & ControlMask) { switch (key_sym) { case XK_Left: return (BAD); case XK_KP_Left: return (BAD); case XK_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_KP_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_Right: return (BAD); case XK_KP_Right: return (BAD); case XK_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_KP_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_KP_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_KP_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; } } else { switch (key_sym) { case XK_Left: return BAD; case XK_KP_Left: return BAD; case XK_Up: key_sym = ((unsigned long)'k')&0xff; break; case XK_KP_Up: key_sym = ((unsigned long)'k')&0xff; break; case XK_Right: return BAD; case XK_KP_Right: return BAD; case XK_Down: key_sym = ((unsigned long)'j')&0xff; break; case XK_KP_Down: key_sym = ((unsigned long)'j')&0xff; break; case XK_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_KP_Page_Up: key_sym = ((unsigned long)'b')&0xff; break; case XK_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; case XK_KP_Page_Down: key_sym = ((unsigned long)'f')&0xff; break; } } switch (key_sym&0xff) { case 'w': /* erase */ case 'y': return INVALID; case 'n': /* down one */ case 'j': if (pTdgtBmpList->can_select) { /* * i = (pni->marked_index < length-1) ? * pni->marked_index+1 : length-1; */ } else { if (length > num_visible_lines) { if (pTdgtBmpList->first_index+num_visible_lines < length) { pTdgtBmpList->first_index += num_cols; } } } break; case 'p': /* up one */ case 'k': if (pTdgtBmpList->can_select) { /* * i = (pni->marked_index>0) ? pni->marked_index-1 : 0; */ } else { if (length > num_visible_lines) { if (pTdgtBmpList->first_index > 0) { pTdgtBmpList->first_index -= num_cols; } } } break; case 'd': /* down one page */ case 'f': if (pTdgtBmpList->can_select) { /* * if (pni->marked_index==INVALID) { * i = (length <= num_visible_lines) ? length-1 : * num_visible_lines; * } else if (pni->marked_index < length-num_visible_lines) { * i = pni->marked_index+num_visible_lines; * } else { * i = length-1; * } */ } else { if (length > num_visible_lines) { if (pTdgtBmpList->first_index+num_visible_lines < length) { pTdgtBmpList->first_index += num_visible_lines; if (pTdgtBmpList->first_index + num_visible_lines > length) { pTdgtBmpList->first_index = length - num_visible_lines; } } } } break; case 'u': /* up one page */ case 'b': if (pTdgtBmpList->can_select) { /* * i = (pni->marked_index > (num_visible_lines-1)) ? * pni->marked_index-num_visible_lines : 0; */ } else { pTdgtBmpList->first_index -= num_visible_lines; if (pTdgtBmpList->first_index < 0) pTdgtBmpList->first_index = 0; } break; default: return BAD; } return i; } static void SpecialKeyInTdgtBmpList(pTdgtBmpList, key_ev, key_sym, pn_changing, pn_selected_btn_index) TdgtBmpList *pTdgtBmpList; XKeyEvent *key_ev; KeySym key_sym; int *pn_changing, *pn_selected_btn_index; { int saved_first=pTdgtBmpList->first_index; int saved_marked=pTdgtBmpList->marked_index; int rc=TdgtBmpListControlChar(pTdgtBmpList, key_ev, key_sym); if (rc == BAD || rc == INVALID) return; if (saved_first != pTdgtBmpList->first_index || saved_marked != pTdgtBmpList->marked_index) { RedrawTidget(pTdgtBmpList->pti); } } static XComposeStatus c_stat; static int KeyPressInTdgtBmpList(pTdgtBmpList, key_ev, pn_changing, pn_selected_btn_index) TdgtBmpList *pTdgtBmpList; XKeyEvent *key_ev; int *pn_changing, *pn_selected_btn_index; { int length=ListLength(&pTdgtBmpList->list); char buf[80]; KeySym key_sym; int has_ch=FALSE; has_ch = XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); TranslateKeys(buf, &key_sym); if ((key_ev->state & ControlMask) && key_sym == XK_j) { SpecialKeyInTdgtBmpList(pTdgtBmpList, key_ev, key_sym, pn_changing, pn_selected_btn_index); } else if (CharIsCRorLF(key_ev, buf, key_sym, &has_ch)) { if (pTdgtBmpList->marked_index != INVALID) { TidgetControlNotify(pTdgtBmpList->pti, TDGTNF_LIST_DBL_CLICKED, pTdgtBmpList->marked_index, 0); return TRUE; } } else if (CharIsESC(key_ev, buf, key_sym, &has_ch)) { if (pTdgtBmpList->can_select) { /* * *pn_changing = FALSE; * *pn_selected_btn_index = GetBtnIndexFromBtnId(BUTTON_CANCEL); */ } } else if (CharIsBSorDEL(key_ev, buf, key_sym, &has_ch, FALSE)) { if (pTdgtBmpList->can_select) { /* * if (pni->edit_style == NAMES_SELECT_FILE && * (pni->faking_dot_dot || pni->pop_from_root)) { * *pn_changing = FALSE; * *pn_selected_btn_index = INVALID; * } else { * BackSpaceInNames(pn_changing, pn_selected_btn_index); * } */ } } else if (CharIsTAB(key_ev, buf, key_sym, &has_ch)) { if (pTdgtBmpList->can_select) { /* should tab out of focus?! */ } } else if (length != 0 && ((key_sym>'\040' && key_sym<='\177' && (key_ev->state & ControlMask)) || key_sym==XK_Up || key_sym==XK_Down || key_sym==XK_KP_Up || key_sym==XK_KP_Down || key_sym==XK_Page_Up || key_sym==XK_KP_Page_Up || key_sym==XK_Page_Down || key_sym==XK_KP_Page_Down)) { SpecialKeyInTdgtBmpList(pTdgtBmpList, key_ev, key_sym, pn_changing, pn_selected_btn_index); } else if (key_sym>='\040' && key_sym<='\177' && length != 0) { if (pTdgtBmpList->can_select) { /* * CharInNames(buf, pn_changing, pn_selected_btn_index); */ } return FALSE; } return FALSE; } static int TdgtBmpListDspHandler(pTdgtBmpList, button_ev) TdgtBmpList *pTdgtBmpList; XButtonEvent *button_ev; { int gap=pTdgtBmpList->gap; int btn_x=button_ev->x, btn_y=button_ev->y; int first_index=pTdgtBmpList->first_index; int num_cols=pTdgtBmpList->num_cols; int row_index=(btn_y-gap)/(pTdgtBmpList->one_bmp_h+gap); int col_index=(btn_x-gap)/(pTdgtBmpList->one_bmp_w+gap); int index=first_index+(row_index*num_cols)+col_index; int prev_marked_index=pTdgtBmpList->marked_index; Time click_time=button_ev->time; if (index >= ListLength(&pTdgtBmpList->list)) { pTdgtBmpList->marked_index = INVALID; } else { pTdgtBmpList->marked_index = index; } if (prev_marked_index != pTdgtBmpList->marked_index) { RedrawTdgtBmpListDspWindow(pTdgtBmpList); /* send notifications */ } TidgetControlNotify(pTdgtBmpList->pti, TDGTNF_LIST_CLICKED, pTdgtBmpList->marked_index, button_ev->button); /* now check for double-click */ if (pTdgtBmpList->marked_index != INVALID && pTdgtBmpList->last_selected_index == pTdgtBmpList->marked_index && (click_time-pTdgtBmpList->last_clicked_time) < doubleClickInterval) { /* send notifications */ TidgetControlNotify(pTdgtBmpList->pti, TDGTNF_LIST_DBL_CLICKED, pTdgtBmpList->marked_index, 0); } memcpy(&pTdgtBmpList->last_clicked_time, &click_time, sizeof(Time)); pTdgtBmpList->last_selected_index = pTdgtBmpList->marked_index; return TRUE; } static int ButtonPressInTdgtBmpList(pTdgtBmpList, button_ev) TdgtBmpList *pTdgtBmpList; XButtonEvent *button_ev; { if (button_ev->window == pTdgtBmpList->scr_win) { TdgtBmpListScrollHandler(pTdgtBmpList, button_ev); return TRUE; } else if (button_ev->window == pTdgtBmpList->dsp_win) { if (pTdgtBmpList->can_select != 0) { if ((button_ev->button == Button1 && (pTdgtBmpList->can_select & Button1Mask) == Button1Mask) || (button_ev->button == Button2 && (pTdgtBmpList->can_select & Button2Mask) == Button2Mask) || (button_ev->button == Button3 && (pTdgtBmpList->can_select & Button3Mask) == Button3Mask)) { return TdgtBmpListDspHandler(pTdgtBmpList, button_ev); } } } return FALSE; } static int TdgtBmpListEventHandler(pti, input, handling_pti) TidgetInfo *pti, *handling_pti; XEvent *input; { TdgtBmpList *pTdgtBmpList=(TdgtBmpList*)(pti->tidget); if (pti != handling_pti) return FALSE; if (input->type == Expose) { RedrawTidget(pTdgtBmpList->pti); } else if (input->type == EnterNotify) { if (pTdgtBmpList->mosi.one_line_status) { SetStringStatus(pTdgtBmpList->mosi.one_line_str); } else { MouseOverStatusInfo *pmosi=(&pTdgtBmpList->mosi); SetMouseStatus(pmosi->btn_str[0], pmosi->btn_str[1], pmosi->btn_str[2]); } } else if (input->type == LeaveNotify) { SetMouseStatus("", "", ""); } else if (input->type == KeyPress) { if (pTdgtBmpList->can_select) { /* * KeyPressInTdgtBmpList(pTdgtBmpList, &changing, * &selected_btn_index); */ } else { return KeyPressInTdgtBmpList(pTdgtBmpList, &input->xkey, NULL, NULL); } } else if (input->type == ButtonPress) { return ButtonPressInTdgtBmpList(pTdgtBmpList, &input->xbutton); } return FALSE; } /* --------------------- IsTdgtBmpListEvent() --------------------- */ static int IsTdgtBmpListEvent(pti, input, ppti_handler_tidget_return) TidgetInfo *pti, **ppti_handler_tidget_return; XEvent *input; { TdgtBmpList *pTdgtBmpList=(TdgtBmpList*)(pti->tidget); if (input->xany.window == pTdgtBmpList->dsp_win || input->xany.window == pTdgtBmpList->scr_win) { *ppti_handler_tidget_return = pti; return TRUE; } return FALSE; } /* --------------------- DestroyTdgtBmpList() --------------------- */ static void DestroyTdgtBmpList(pti) TidgetInfo *pti; { TdgtBmpList *pTdgtBmpList=(TdgtBmpList*)(pti->tidget); TdgtBmpListReset(pTdgtBmpList); free(pTdgtBmpList); } /* --------------------- MapTdgtBmpList() --------------------- */ static void MapTdgtBmpList(pti) TidgetInfo *pti; { TdgtBmpList *pTdgtBmpList=(TdgtBmpList*)(pti->tidget); #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, pTdgtBmpList->pti->tci.win); XSelectInput(mainDisplay, pTdgtBmpList->pti->tci.win, ExposureMask); XMapWindow(mainDisplay, pTdgtBmpList->dsp_win); XSelectInput(mainDisplay, pTdgtBmpList->dsp_win, KeyPressMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, pTdgtBmpList->scr_win); XSelectInput(mainDisplay, pTdgtBmpList->scr_win, KeyPressMask | ButtonPressMask | ExposureMask); #else XSelectInput(mainDisplay, pTdgtBmpList->pti->tci.win, ExposureMask); XMapWindow(mainDisplay, pTdgtBmpList->pti->tci.win); XSelectInput(mainDisplay, pTdgtBmpList->dsp_win, KeyPressMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, pTdgtBmpList->dsp_win); XSelectInput(mainDisplay, pTdgtBmpList->scr_win, KeyPressMask | ButtonPressMask | ExposureMask); XMapWindow(mainDisplay, pTdgtBmpList->scr_win); #endif } /* --------------------- TdgtBmpListMoveResize() --------------------- */ static void TdgtBmpListMoveResize(pti, x, y, w, h) TidgetInfo *pti; int x, y, w, h; { TdgtBmpList *pTdgtBmpList=(TdgtBmpList*)(pti->tidget); pTdgtBmpList->pti->tci.win_info.x = x; pTdgtBmpList->pti->tci.win_info.y = y; pTdgtBmpList->pti->tci.win_info.w = w; pTdgtBmpList->pti->tci.win_info.h = h; XMoveResizeWindow(mainDisplay, pTdgtBmpList->pti->tci.win, x, y, w, h); pTdgtBmpList->dsp_win_info.x = windowPadding; pTdgtBmpList->dsp_win_info.y = windowPadding; pTdgtBmpList->dsp_win_info.w = w-(windowPadding<<1)-scrollBarW; pTdgtBmpList->dsp_win_info.h = h-(windowPadding<<1); XMoveResizeWindow(mainDisplay, pTdgtBmpList->dsp_win, pTdgtBmpList->dsp_win_info.x, pTdgtBmpList->dsp_win_info.y, pTdgtBmpList->dsp_win_info.w, pTdgtBmpList->dsp_win_info.h); pTdgtBmpList->scr_win_info.x = w-windowPadding-scrollBarW; pTdgtBmpList->scr_win_info.y = windowPadding; pTdgtBmpList->scr_win_info.w = scrollBarW; pTdgtBmpList->scr_win_info.h = h-(windowPadding<<1); XMoveResizeWindow(mainDisplay, pTdgtBmpList->scr_win, pTdgtBmpList->scr_win_info.x, pTdgtBmpList->scr_win_info.y, pTdgtBmpList->scr_win_info.w, pTdgtBmpList->scr_win_info.h); } /* --------------------- TdgtBmpListSendCmd() --------------------- */ static int HandleSelectNext(pTdgtBmpList, cmd_arg) TdgtBmpList *pTdgtBmpList; int cmd_arg; /* one of TDGTARG_MOVE_* */ { int prev_marked_index=pTdgtBmpList->marked_index; int num_items=ListLength(&pTdgtBmpList->list); int num_cols=pTdgtBmpList->num_cols; int col=(prev_marked_index%num_cols); int last_row_first_item_index=0, this_row_first_item_index=0; int this_row_is_last_row=TRUE; if (num_items == 0) return TRUE; if (num_items%num_cols == 0) { last_row_first_item_index = num_cols * (round(((double)num_items) / ((double)num_cols))-1); } else { last_row_first_item_index = num_cols * ((int)(num_items / num_cols)); } if (prev_marked_index%num_cols == 0) { this_row_first_item_index = num_cols * round(((double)prev_marked_index) / ((double)num_cols)); } else { this_row_first_item_index = num_cols * ((int)(prev_marked_index / num_cols)); } this_row_is_last_row = (this_row_first_item_index+num_cols >= num_items); switch (cmd_arg) { case TDGTARG_MOVE_UP: if (prev_marked_index == INVALID) { pTdgtBmpList->marked_index = num_items-1; } else if (num_items <= num_cols) { /* do nothing */ } else { pTdgtBmpList->marked_index -= num_cols; if (pTdgtBmpList->marked_index < 0) { pTdgtBmpList->marked_index = last_row_first_item_index+col; } } break; case TDGTARG_MOVE_DOWN: if (prev_marked_index == INVALID) { pTdgtBmpList->marked_index = 0; } else if (num_items <= num_cols) { /* do nothing */ } else { pTdgtBmpList->marked_index += num_cols; if (pTdgtBmpList->marked_index >= num_items) { pTdgtBmpList->marked_index = col; } } break; case TDGTARG_MOVE_RIGHT: if (prev_marked_index == INVALID) { pTdgtBmpList->marked_index = 0; } else if (this_row_is_last_row) { if (prev_marked_index == num_items-1) { pTdgtBmpList->marked_index = this_row_first_item_index; } else { pTdgtBmpList->marked_index++; } } else if (col == num_cols-1) { pTdgtBmpList->marked_index = this_row_first_item_index; } else { pTdgtBmpList->marked_index++; } break; case TDGTARG_MOVE_LEFT: if (prev_marked_index == INVALID) { pTdgtBmpList->marked_index = 0; } else if (this_row_is_last_row) { if (col == 0) { pTdgtBmpList->marked_index = num_items-1; } else { pTdgtBmpList->marked_index--; } } else if (col == 0) { pTdgtBmpList->marked_index = this_row_first_item_index+num_cols-1; } else { pTdgtBmpList->marked_index--; } break; } RedrawTdgtBmpListDspWindow(pTdgtBmpList); return TRUE; } static int HandleGetCurSel(pTdgtBmpList, pn_selected_index) TdgtBmpList *pTdgtBmpList; int *pn_selected_index; { if (pn_selected_index != NULL) { *pn_selected_index = pTdgtBmpList->marked_index; } return TRUE; } static int HandleGetItem(pTdgtBmpList, index, ppblii) TdgtBmpList *pTdgtBmpList; int index; BmpListItemInfo **ppblii; { int i=0; CVListElem *pElem=NULL; if (index == INVALID) return FALSE; for (i=0, pElem=ListFirst(&pTdgtBmpList->list); pElem != NULL; pElem=ListNext(&pTdgtBmpList->list, pElem), i++) { if (i == index) { BmpListItemInfo *pblii=(BmpListItemInfo*)(pElem->obj); if (ppblii != NULL) { *ppblii = pblii; } return TRUE; } else if (i > index) { break; } } return FALSE; } int TdgtBmpListSendCmd(pti, cmd_type, cmd_arg, pv_cmd_userdata) TidgetInfo *pti; int cmd_type, cmd_arg; void *pv_cmd_userdata; { TdgtBmpList *pTdgtBmpList=(TdgtBmpList*)(pti->tidget); switch (cmd_type) { case TDGTCMD_LIST_SEL_NEXT: return HandleSelectNext(pTdgtBmpList, cmd_arg); case TDGTCMD_LIST_RESETCONTENT: TdgtBmpListCleanUpEntries(pTdgtBmpList); RedrawTidget(pTdgtBmpList->pti); return TRUE; case TDGTCMD_LIST_GETCURSEL: return HandleGetCurSel(pTdgtBmpList, (int*)pv_cmd_userdata); case TDGTCMD_LIST_GETITEM: return HandleGetItem(pTdgtBmpList, cmd_arg, (BmpListItemInfo**)pv_cmd_userdata); } return FALSE; } /* --------------------- TdgtBmpListReset() --------------------- */ void TdgtBmpListReset(pTdgtBmpList) TdgtBmpList *pTdgtBmpList; { TdgtBmpListCleanUpEntries(pTdgtBmpList); FreeDynStrBuf(&pTdgtBmpList->pti->tci.dyn_str); } /* --------------------- CreateTdgtBmpList() --------------------- */ static void TdgtBmpListCalcGeom(bmp_w, bmp_h, num_cols, num_visible_lines, gap, pn_content_w, pn_content_h) int bmp_w, bmp_h, num_cols, num_visible_lines, gap; int *pn_content_w, *pn_content_h; /* * The content area includes the bitmap display area and the scrollbar. */ { int w=gap+((bmp_w+gap)*num_cols), h=gap+((bmp_h+gap)*num_visible_lines); /* * Display area has *no* windowPadding around it (scrollBarW includes * (windowPadding<<1) already). */ w += scrollBarW; if (pn_content_w != NULL) *pn_content_w = w; if (pn_content_h != NULL) *pn_content_h = h; } TdgtBmpList *CreateTdgtBmpList(parent_win, parent_tidgetinfo, ctl_id, x, y, h_pad, v_pad, bmp_w, bmp_h, num_cols, num_visible_lines, gap, can_select, pmosi) Window parent_win; TidgetInfo *parent_tidgetinfo; int ctl_id, x, y, h_pad, v_pad, bmp_w, bmp_h, num_cols, num_visible_lines; int gap, can_select; MouseOverStatusInfo *pmosi; { int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel), w=0, h=0; int content_w=0, content_h=0; TdgtBmpList *pTdgtBmpList=NULL; TdgtBmpListCalcGeom(bmp_w, bmp_h, num_cols, num_visible_lines, gap, &content_w, &content_h); w = content_w + (windowPadding<<1) + (h_pad<<1); h = content_h + (windowPadding<<1) + (v_pad<<1); pTdgtBmpList = (TdgtBmpList*)malloc(sizeof(TdgtBmpList)); if (pTdgtBmpList == NULL) FailAllocMessage(); memset(pTdgtBmpList, 0, sizeof(TdgtBmpList)); pTdgtBmpList->pti = NewTidgetInfo(parent_tidgetinfo, TIDGET_TYPE_BMPL, pTdgtBmpList, ctl_id, NULL); if ((pTdgtBmpList->pti->tci.win=XCreateSimpleWindow(mainDisplay, parent_win, x, y, w, h, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("CreateTdgtBmpList()", NULL, TRUE); } XSelectInput(mainDisplay, pTdgtBmpList->pti->tci.win, ExposureMask); SetTidgetInfoBasic(pTdgtBmpList->pti, TIDGET_TYPE_BMPL, pTdgtBmpList, parent_win, x, y, w, h, v_pad, h_pad, TGBS_NORMAL, ""); TidgetSetCallbacks(pTdgtBmpList->pti, RedrawTdgtBmpList, TdgtBmpListEventHandler, IsTdgtBmpListEvent, DestroyTdgtBmpList, MapTdgtBmpList, TdgtBmpListMoveResize, TdgtBmpListSendCmd); CVListInit(&pTdgtBmpList->list); if (pmosi != NULL) { memcpy(&pTdgtBmpList->mosi, pmosi, sizeof(MouseOverStatusInfo)); } /* Note: scrollBarW accounts for windowPadding */ if ((pTdgtBmpList->dsp_win=XCreateSimpleWindow(mainDisplay, pTdgtBmpList->pti->tci.win, windowPadding, windowPadding, w-(windowPadding<<1)-scrollBarW, h-(windowPadding<<1), brdrW, myBorderPixel, myBgPixel)) == 0) { FailToCreateWindowMessage("CreateTdgtBmpList()", NULL, TRUE); } XSelectInput(mainDisplay, pTdgtBmpList->dsp_win, KeyPressMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); pTdgtBmpList->dsp_win_info.x = windowPadding; pTdgtBmpList->dsp_win_info.y = windowPadding; pTdgtBmpList->dsp_win_info.w = w-(windowPadding<<1)-scrollBarW; pTdgtBmpList->dsp_win_info.h = h-(windowPadding<<1); if ((pTdgtBmpList->scr_win=XCreateSimpleWindow(mainDisplay, pTdgtBmpList->pti->tci.win, w-windowPadding-scrollBarW, windowPadding, scrollBarW, h-(windowPadding<<1), brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("CreateTdgtBmpList()", NULL, TRUE); } XSelectInput(mainDisplay, pTdgtBmpList->scr_win, KeyPressMask | ButtonPressMask | ExposureMask); pTdgtBmpList->scr_win_info.x = w-windowPadding-scrollBarW; pTdgtBmpList->scr_win_info.y = windowPadding; pTdgtBmpList->scr_win_info.w = scrollBarW; pTdgtBmpList->scr_win_info.h = h-(windowPadding<<1); pTdgtBmpList->can_select = can_select; pTdgtBmpList->one_bmp_w = bmp_w; pTdgtBmpList->one_bmp_h = bmp_h; pTdgtBmpList->gap = gap; pTdgtBmpList->first_index = 0; pTdgtBmpList->marked_index = INVALID; pTdgtBmpList->num_cols = num_cols; pTdgtBmpList->num_visible_lines = num_visible_lines; return pTdgtBmpList; } /* --------------------- TdgtBmpListCleanUpEntries() --------------------- */ int TdgtBmpListCleanUpEntries(pTdgtBmpList) TdgtBmpList *pTdgtBmpList; { CVListElem *pElem=NULL; if (ListLength(&pTdgtBmpList->list) > 0) { TidgetSetDirty(pTdgtBmpList->pti, TRUE); } for (pElem=ListFirst(&pTdgtBmpList->list); pElem != NULL; pElem=ListNext(&pTdgtBmpList->list, pElem)) { BmpListItemInfo *pblii=(BmpListItemInfo*)(pElem->obj); FreeBmpListItemInfo(pblii); } ListUnlinkAll(&pTdgtBmpList->list); pTdgtBmpList->first_index = 0; pTdgtBmpList->marked_index = INVALID; return TRUE; } /* --------------------- TdgtBmpListScrollToBottom() --------------------- */ int TdgtBmpListScrollToBottom(pTdgtBmpList) TdgtBmpList *pTdgtBmpList; { int length=ListLength(&pTdgtBmpList->list); if (pTdgtBmpList->num_visible_lines < length) { pTdgtBmpList->first_index = length - pTdgtBmpList->num_visible_lines; } else { pTdgtBmpList->first_index = 0; } return TRUE; } /* --------------------- TdgtBmpListAddItem() --------------------- */ int TdgtBmpListAddItem(pTdgtBmpList, pblii) TdgtBmpList *pTdgtBmpList; BmpListItemInfo *pblii; { ListAppend(&pTdgtBmpList->list, pblii); TidgetSetDirty(pTdgtBmpList->pti, TRUE); RedrawTidget(pTdgtBmpList->pti); return TRUE; } /* --------------------- Init & Clean Up --------------------- */ int InitTdgtBmpList() { return TRUE; } void CleanUpTdgtBmpList() { } �������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/wb_mcast.e���������������������������������������������������������������������������0000644�0000764�0000764�00000001111�11602233314�014725� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Raphael S. de Moraes <raphael@land.ufrj.br> in April, 1999. * * (Obsoleted in tgif-4.1.41 by the TGWB group at land.ufrj.br.) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb_mcast.e,v 1.1 2004/06/18 23:19:10 william Exp $ */ #ifndef _WB_MCAST_E_ #define _WB_MCAST_E_ #ifdef _INCLUDE_FROM_WB_MCAST_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_WB_MCAST_C_*/ #ifdef _INCLUDE_FROM_WB_MCAST_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_WB_MCAST_C_*/ #endif /*_WB_MCAST_E*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/cmdids.h�����������������������������������������������������������������������������0000644�0000764�0000764�00000041775�11602233311�014415� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/cmdids.h,v 1.35 2011/06/09 15:55:15 cvsps Exp $ */ #ifndef _CMDIDS_H_ #define _CMDIDS_H_ #define TG_COMMAND ((short)0x8001) #define CMDID_BASE 100 #define CMDID_SELECTALL 100 #define CMDID_BACK 101 #define CMDID_CHANGEDOMAIN 102 #define CMDID_DUPLICATE 103 #define CMDID_PUSHCURCHOICE 104 #define CMDID_FRONT 105 #define CMDID_GROUP 106 #define CMDID_INSTANTIATE 107 #define CMDID_POP 108 #define CMDID_ALIGNOBJS 109 #define CMDID_NEW 110 #define CMDID_OPEN 111 #define CMDID_PRINT 112 #define CMDID_QUIT 113 #define CMDID_REDRAW 114 #define CMDID_SAVE 115 #define CMDID_ALIGNTOGRID 116 #define CMDID_UNGROUP 117 #define CMDID_PUSH 118 #define CMDID_DRAWTEXT 119 #define CMDID_DELETE 120 #define CMDID_COPY 121 #define CMDID_ANIMATE 122 #define CMDID_SCROLLLEFT 123 #define CMDID_SCROLLRIGHT 124 #define CMDID_PRINTWITHCMD 125 #define CMDID_ATTACHATTRS 126 #define CMDID_PROBE 127 #define CMDID_ROTATECOUNTER 128 #define CMDID_DECGRID 129 #define CMDID_ANIMATESEND 130 #define CMDID_ANIMATEFLASH 131 #define CMDID_TOGGLEGRID 132 #define CMDID_FLIPHORIZONTAL 133 #define CMDID_INCGRID 134 #define CMDID_HIDEATTRNAME 135 #define CMDID_SELECTMODE 136 #define CMDID_DISTRIBUTEOBJS 137 #define CMDID_MOVEJUSTIFYATTR 138 #define CMDID_SHOWATTRNAME 139 #define CMDID_ZOOMOUT 140 #define CMDID_IMPORT 141 #define CMDID_DRAWPOLY 142 #define CMDID_DRAWBOX 143 #define CMDID_SOLVE 144 #define CMDID_DETACHATTRS 145 #define CMDID_UNDO 146 #define CMDID_FLIPVERTICAL 147 #define CMDID_ROTATECLOCKWISE 148 #define CMDID_ESCAPE 149 #define CMDID_SIMULATE 150 #define CMDID_ZOOMIN 151 #define CMDID_SPECIFYANARC 152 #define CMDID_UPDATE 153 #define CMDID_SCROLLUP 154 #define CMDID_SCROLLDOWN 155 #define CMDID_SHOWATTR 156 #define CMDID_ALIGNOBJSTOP 157 #define CMDID_ALIGNOBJSMIDDLE 158 #define CMDID_ALIGNOBJSBOTTOM 159 #define CMDID_ALIGNOBJSLEFT 160 #define CMDID_ALIGNOBJSCENTER 161 #define CMDID_ALIGNOBJSRIGHT 162 #define CMDID_MAKEREGPOLYGON 163 #define CMDID_SETREDUCTION 164 #define CMDID_DEFAULTZOOM 165 #define CMDID_ZOOMWAYOUT 166 #define CMDID_SAVENEW 167 #define CMDID_CUTBITPIXMAP 168 #define CMDID_ABUTHORIZONTAL 169 #define CMDID_ABUTVERTICAL 170 #define CMDID_BREAKUPTEXT 171 #define CMDID_SCROLLTOORIG 172 #define CMDID_TOGGLEMOVEMODE 173 #define CMDID_SELECTVERTEXMODE 174 #define CMDID_ALIGNTOPAGE 175 #define CMDID_REDO 176 #define CMDID_IMPORTEPSFILE 177 #define CMDID_PRECISESCALE 178 #define CMDID_LOCK 179 #define CMDID_UNLOCK 180 #define CMDID_ADDPOINT 181 #define CMDID_BOLD 182 #define CMDID_CENTER 183 #define CMDID_DELETEPOINT 184 #define CMDID_DRAWRCBOX 185 #define CMDID_INVERTXBITMAP 186 #define CMDID_TOGGLESNAP 187 #define CMDID_HIDEATTR 188 #define CMDID_MAKEICONIC 189 #define CMDID_UNMAKEICONIC 190 #define CMDID_TOGGLEBWCOLORPS 191 #define CMDID_LEFT 192 #define CMDID_MAKESYMBOLIC 193 #define CMDID_UNMAKESYMBOLIC 194 #define CMDID_ROMAN 195 #define CMDID_BOLDITALIC 196 #define CMDID_DRAWPOLYGON 197 #define CMDID_RIGHT 198 #define CMDID_SAVESELECTEDAS 199 #define CMDID_ITALIC 200 #define CMDID_UPDATESYMBOLS 201 #define CMDID_DRAWOVAL 202 #define CMDID_TOGGLELINETYPE 203 #define CMDID_CYCLEPRINFORMAT 204 #define CMDID_PASTE 205 #define CMDID_DRAWARC 206 #define CMDID_IMPORTXBITMAP 207 #define CMDID_IMPORTXPIXMAP 208 #define CMDID_TOGGLEGRIDSYSTEM 209 #define CMDID_DRAWCORNEROVAL 210 #define CMDID_DRAWCENTEROVAL 211 #define CMDID_DRAWEDGEOVAL 212 #define CMDID_SCROLLPAGEUP 213 #define CMDID_SCROLLPAGEDOWN 214 #define CMDID_SCROLLPAGELEFT 215 #define CMDID_SCROLLPAGERIGHT 216 #define CMDID_FLUSHUNDOBUFFER 217 #define CMDID_PRINTMSGBUFFER 218 #define CMDID_SAVEORIGIN 219 #define CMDID_RESTOREIMAGEWH 220 #define CMDID_UPDATEEPS 221 #define CMDID_TOGGLEMAPSHOWN 222 #define CMDID_TOGGLEUSEGRAYSCALE 223 #define CMDID_FREEHANDMODE 224 #define CMDID_SAVESYMINLIBRARY 225 #define CMDID_CENTERANENDPOINT 226 #define CMDID_CENTERAVERTEX 227 #define CMDID_NEXTPAGE 228 #define CMDID_PREVPAGE 229 #define CMDID_NAMEPAGES 230 #define CMDID_GOTOPAGE 231 #define CMDID_ADDPAGEBEFORE 232 #define CMDID_ADDPAGEAFTER 233 #define CMDID_DELETECURPAGE 234 #define CMDID_TOGGLEPAGELINESHOWN 235 #define CMDID_SPECIFYDRAWINGSIZE 236 #define CMDID_PRINTONEPAGE 237 #define CMDID_ATTACHFILEATTRS 238 #define CMDID_DETACHFILEATTRS 239 #define CMDID_EDITFILEATTRS 240 #define CMDID_PRINTSELECTEDOBJS 241 #define CMDID_INPUTPOLYPTS 242 #define CMDID_INPUTPOLYGONPTS 243 #define CMDID_EDITATTRS 244 #define CMDID_CONVERTINTSPLINE 245 #define CMDID_PASTEFROMFILE 246 #define CMDID_TOGGLESHOWMEASUREMENT 247 #define CMDID_SETMEASUREUNIT 248 #define CMDID_CUT 249 #define CMDID_TOGGLESMOOTHHINGE 250 #define CMDID_TOGGLESHOWMENUBAR 251 #define CMDID_TOGGLESHOWSTATUS 252 #define CMDID_BROWSEXBITMAP 253 #define CMDID_BROWSEXPIXMAP 254 #define CMDID_SPECIFYPAPERSIZE 255 #define CMDID_TOGGLEONEMOTIONSELMOVE 256 #define CMDID_GOBACK 257 #define CMDID_GOFORWARD 258 #define CMDID_REFRESHCURRENT 259 #define CMDID_HOTLIST 260 #define CMDID_ADDCURRENTTOHOTLIST 261 #define CMDID_SESSIONHISTORY 262 #define CMDID_TOGGLEHYPERSPACE 263 #define CMDID_EMBEDEPSFILE 264 #define CMDID_SETSELLINEWIDTH 265 #define CMDID_ADDCOLOR 266 #define CMDID_IMPORTATTRS 267 #define CMDID_EXPORTATTRS 268 #define CMDID_MERGEWITHTABLE 269 #define CMDID_EXPORTTOTABLE 270 #define CMDID_DELETEPAGES 271 #define CMDID_PRINTONEFILEPERPAGE 272 #define CMDID_IMPORTGIFFILE 273 #define CMDID_SETEXPORTPIXELTRIM 274 #define CMDID_WHITEBOARD 275 #define CMDID_TOGGLECOLORLAYERS 276 #define CMDID_TOGGLESTRETCHABLETEXT 277 #define CMDID_BREAKUPBITPIXMAP 278 #define CMDID_LAYOUTONARC 279 #define CMDID_PRECISEROTATE 280 #define CMDID_JOINPOLY 281 #define CMDID_CUTPOLY 282 #define CMDID_GETBOUNDINGBOX 283 #define CMDID_SETTEMPLATE 284 #define CMDID_MAKEGRAY 285 #define CMDID_INVERTCOLOR 286 #define CMDID_INTERPOLATECOLOR 287 #define CMDID_BRIGHTENDARKEN 288 #define CMDID_CHANGESATURATION 289 #define CMDID_CHANGEHUE 290 #define CMDID_CONTRASTENHANCE 291 #define CMDID_COLORBALANCE 292 #define CMDID_GAMMA 293 #define CMDID_EDGEDETECT 294 #define CMDID_EMBOSS 295 #define CMDID_REDUCECOLORS 296 #define CMDID_REDUCETOPIXMAPCOLORS 297 #define CMDID_SETDEFAULTCOLORLEVELS 298 #define CMDID_REDUCETODEFAULTCOLORs 299 #define CMDID_DEFAULTERRORDIFFUSE 300 #define CMDID_SPREAD 301 #define CMDID_SHARPEN 302 #define CMDID_BLUR3 303 #define CMDID_BLUR5 304 #define CMDID_BLUR7 305 #define CMDID_RUNBGGEN 306 #define CMDID_CIRCULARBGGEN 307 #define CMDID_SIMPLERECTBGGEN 308 #define CMDID_REGENERATEIMAGE 309 #define CMDID_CROPIMAGE 310 #define CMDID_GETCOLOR 311 #define CMDID_REPLACECOLOR 312 #define CMDID_FLOODFILL 313 #define CMDID_CREATECONTOUR 314 #define CMDID_SUBTRACT 315 #define CMDID_ALPHACOMBINE 316 #define CMDID_VECTORWARP 317 #define CMDID_XORCOLORS 318 #define CMDID_IMPORTOTHERFILE 319 #define CMDID_BROWSEOTHER 320 #define CMDID_TOGGLESHOWCROSSHAIR 321 #define CMDID_SETSHAPESHADOW 322 #define CMDID_NOTRANSFORM 323 #define CMDID_ABOUT 324 #define CMDID_COPYRIGHT 325 #define CMDID_SETSELFONTSIZE 326 #define CMDID_ZOOMINATCURSOR 327 #define CMDID_CENTERATCURSOR 328 #define CMDID_SETEDITTEXTSIZE 329 #define CMDID_SETTEXTROTATION 330 #define CMDID_SETROTATIONINCREMENT 331 #define CMDID_FINDCASESENSITIVE 332 #define CMDID_FINDNOCASE 333 #define CMDID_FINDAGAIN 334 #define CMDID_CURRENTVERSIONINFO 335 #define CMDID_LATESTRELEASEINFO 336 #define CMDID_CONNECTPINS 337 #define CMDID_PASTECOMPOUNDTEXT 338 #define CMDID_COPYPROPERTIES 339 #define CMDID_SAVEPROPERTIES 340 #define CMDID_PASTEPROPERTIES 341 #define CMDID_RESTOREPROPERTIES 342 #define CMDID_ROTATESHEARMODE 343 #define CMDID_CHANGEALLSELFILL 344 #define CMDID_CHANGEALLSELPEN 345 #define CMDID_CHANGEALLSELLINEWIDTH 346 #define CMDID_CHANGEALLSELLINESTYLE 347 #define CMDID_CHANGEALLSELLINETYPE 348 #define CMDID_CHANGEALLSELLINEDASH 349 #define CMDID_CHANGEALLSELFONT 350 #define CMDID_CHANGEALLSELFONTSIZE 351 #define CMDID_CHANGEALLSELFONTSTYLE 352 #define CMDID_CHANGEALLSELFONTJUST 353 #define CMDID_CHANGEALLSELCOLOR 354 #define CMDID_LANDSCAPEMODE 355 #define CMDID_PORTRAITMODE 356 #define CMDID_SETWHERETOPRINT 357 #define CMDID_SETHORIZONTALALIGN 358 #define CMDID_SETVERTICALALIGN 359 #define CMDID_SETMOVEMODE 360 #define CMDID_SETSTRETCHTEXTMODE 361 #define CMDID_CREATESHAPE 362 #define CMDID_SETPAGELAYOUTMODE 363 #define CMDID_SETTRANSPATMODE 364 #define CMDID_TOGGLESHOWMODE 365 #define CMDID_TOGGLESLIDESHOW 366 #define CMDID_SETSLIDESHOWBRDRCOLOR 367 #define CMDID_SETSLIDESHOWWINOFFSETS 368 #define CMDID_EXPORTXPMDECKTOGIF 369 #define CMDID_IMPORTGIFTOXPMDECK 370 #define CMDID_INSERTTHINSPACE 371 #define CMDID_INSERTVERTICALOFFSET 372 #define CMDID_REMOVEVERTICALOFFSET 373 #define CMDID_INSERTRIGHTSUPERSCRIPT 374 #define CMDID_INSERTRIGHTSUBSCRIPT 375 #define CMDID_INSERTLEFTSUPERSCRIPT 376 #define CMDID_INSERTLEFTSUBSCRIPT 377 #define CMDID_INSERTCENTERSUPERSCRIPT 378 #define CMDID_INSERTCENTERSUBSCRIPT 379 #define CMDID_SETSCRIPTFRACTION 380 #define CMDID_FAKEUSERAGENT 381 #define CMDID_FAKEREFERER 382 #define CMDID_TOGGLEKEEPALIVE 383 #define CMDID_SIZETOWIDEST 384 #define CMDID_SIZETONARROWEST 385 #define CMDID_SIZETOTALLEST 386 #define CMDID_SIZETOSHORTEST 387 #define CMDID_SIZETOGIVENWIDTHHEIGHT 388 #define CMDID_SIZETOGIVENWIDTH 389 #define CMDID_SIZETOGIVENHEIGHT 390 #define CMDID_EXECCMDSFROMFILE 391 #define CMDID_STARTEXECCMDSFROMFILE 392 #define CMDID_COPYPLAINTEXTASOBJECT 393 #define CMDID_SETTEXTFILLPATTERNCOLOR 394 #define CMDID_DRAWEDGEARC 395 #define CMDID_ALIGNDIRECT 396 #define CMDID_DISTRIBUTEDIRECT 397 #define CMDID_VISIBLEGRIDINSLIDESHOW 398 #define CMDID_CHANGESCROLLMODE 399 #define CMDID_SETALTEDITTEXTBGCOLOR 400 #define CMDID_SETALTEDITTEXTHIGHLIGHTCOLOR 401 #define CMDID_TOGGLEALTEDITTEXTBGCOLOR 402 #define CMDID_CHANGEALLSELFONTUNDERLINE 403 #define CMDID_EDITPAGEFILENAMES 404 #define CMDID_EXPORTHALFTONEBITMAP 405 #define CMDID_EXPORTTHRESHOLDBITMAP 406 #define CMDID_SETEXPORTBITMAPTHRESHOLD 407 #define CMDID_PRECISESCALEEVERYTHING 408 #define CMDID_SETPAPERCOLOR 409 #define CMDID_TOGGLEEQATTRSHOWN 410 #define CMDID_SCREENCAPTURE 411 #define CMDID_FULLSCREENCAPTURE 412 #define CMDID_DELAYEDFULLSCREENCAPTURE 413 #define CMDID_TOGGLEHIDEDURINGCAPTURE 414 #define CMDID_EDITDOMAINPATHS 415 #define CMDID_SELECTDEFAULTDOMAIN 416 #define CMDID_ADDADOMAIN 417 #define CMDID_DELETEADOMAIN 418 #define CMDID_RELOADDOMAININFOFROMX 419 #define CMDID_IMPORTPNGFILE 420 #define CMDID_EDITATTRINEDITOR 421 #define CMDID_SETHTMLEXPORTTEMPLATE 422 #define CMDID_PRINTPAGES 423 #define CMDID_GOHYPERSPACEINSLIDESHOW 424 #define CMDID_FREEHANDMODEINSLIDESHOW 425 #define CMDID_RECENTLYUSEDFILES 426 #define CMDID_MOVEEDITTEXTBOX 427 #define CMDID_GETPROPERTY 428 #define CMDID_REPLACEGRAPHIC 429 #define CMDID_TOGGLESHOWMEASUREMENTINTT 430 #define CMDID_IMPORTJPEGFILE 431 #define CMDID_TOGGLEAUTOEPSPREVIEWBITMAP 432 #define CMDID_CREATETHUMBNAILS 433 #define CMDID_CONNECT2PORTSBYWIRE 434 #define CMDID_RENAMESIGNAMEFORAPORT 435 #define CMDID_CLEARSIGNAMEFORAPORT 436 #define CMDID_TOGGLESHOWWIRESIGNALNAME 437 #define CMDID_TOGGLESHOWCHOICEBAR 438 #define CMDID_MERGEPORTSWITHANOBJECT 439 #define CMDID_RENUMBER_OBJECT_IDS 440 #define CMDID_REPEATCONNECT2PORTSBYWIRE 441 #define CMDID_CONNECTPORTSTOBROADCAST 442 #define CMDID_IMPORTMULTIPAGETEXTFILE 443 #define CMDID_SETMARGINSONIMPORTTEXT 444 #define CMDID_TOGGLEWORDWRAPONIMPORTTEXT 445 #define CMDID_DATA_IN_MBUFF 446 #define CMDID_BENCHMARK 447 #define CMDID_CONVERTTOBEZIER 448 #define CMDID_SETBEZIERCONVERTNUMSEGS 449 #define CMDID_ADDSQUARETICKMARKS 450 #define CMDID_ADDTRIANGLETICKMARKS 451 #define CMDID_ADDCIRCLETICKMARKS 452 #define CMDID_ADDXTICKMARKS 453 #define CMDID_ADDDIAMONDTICKMARKS 454 #define CMDID_ADDBOWTIETICKMARKS 455 #define CMDID_ADDINVTRIANGLETICKMARKS 456 #define CMDID_ADDPLUSTICKMARKS 457 #define CMDID_ADDHOURGLASSTICKMARKS 458 #define CMDID_SETTICKMARKSIZE 459 #define CMDID_PEEKDIMENSION 460 #define CMDID_TOGGLESHOWCHAT 461 #define CMDID_SAVEPAGESAS 462 #define CMDID_IMPORTPPMFILE 463 #define CMDID_ADDPAGEBEFORECOPYALL 464 #define CMDID_ADDPAGEAFTERCOPYALL 465 #define CMDID_INSERTHEXOCTALCHAR 466 #define CMDID_RESETINMETHOD 467 #define CMDID_IMPORTPBMFILE 468 #define CMDID_IMPORTPGMFILE 469 #define CMDID_EDITATTRGROUPINEDITOR 470 #define CMDID_LINKEXTJPEGFILE 471 #define CMDID_NEXTSLIDE 472 #define CMDID_PREVSLIDE 473 #define CMDID_SETOBJSHADOWCOLOR 474 #define CMDID_SETOBJSHADOWOFFSETS 475 #define CMDID_ADDOBJSHADOW 476 #define CMDID_REMOVEOBJSHADOW 477 #define CMDID_COPYUTF8 478 #define CMDID_PASTEUTF8 479 #define CMDID_REDUCETOMOBILEWEBCOLORS 480 #define CMDID_CREATEPIXMAPFROMSEL 481 #define CMDID_TOGGLEROTATEPIVOT 482 #define CMDID_SPECIFYROTATEPIVOT 483 #define CMDID_RESETROTATEPIVOT 484 #define CMDID_NEXTPOLYROTATEPIVOT 485 #define CMDID_MOVEROTATEPIVOTARCCNTR 486 #define CMDID_MOVEROTATEPIVOTCENTER 487 #define CMDID_MOVEROTATEPIVOTLT 488 #define CMDID_MOVEROTATEPIVOTRT 489 #define CMDID_MOVEROTATEPIVOTLB 490 #define CMDID_MOVEROTATEPIVOTRB 491 #define CMDID_MOVEROTATEPIVOTLEFT 492 #define CMDID_MOVEROTATEPIVOTRIGHT 493 #define CMDID_MOVEROTATEPIVOTTOP 494 #define CMDID_MOVEROTATEPIVOTBOTTOM 495 #define CMDID_CHOOSEROTATEPIVOT 496 #define CMDID_COLORWHEEL 497 #define CMDID_EXTENDSEGMENT 498 #define CMDID_TOGGLETIGHTERSPLINES 499 #define CMDID_INSERTSYMBOL 500 #define CMDID_TOGGLERIGHTMARGIN 501 #define CMDID_SPECIFYRIGHTMARGIN 502 #define CMDID_CHANGEALLSELFONTOVERLINE 503 #define CMDID_TOGGLEFLOODREPLACECOLORTHRESH 504 #define CMDID_SETFLOODREPLACECOLORTHRESH 505 #define CMDID_REMOVETRANSPIXEL 506 #define CMDID_REPLACECOLORWITHTRANS 507 #define CMDID_NEWRECTFROMBOUNDINGBOX 508 #define CMDID_NEWOVALFROMBOUNDINGBOX 509 #define CMDID_NEWRCBOXFROMBOUNDINGBOX 510 #define MAXCMDIDS 511 #endif /*_CMDIDS_H_*/ ���tgif-QPL-4.2.5/cutpaste.e���������������������������������������������������������������������������0000644�0000764�0000764�00000013603�11602233311�014764� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/cutpaste.e,v 1.21 2011/05/19 16:46:22 william Exp $ */ #ifndef _CUTPASTE_E_ #define _CUTPASTE_E_ #define CBI_TGIF 0 #define CBI_UTF8 1 #define CBI_TEXT 2 typedef struct tagSetCutBufferInfo { int tgif_valid; int utf8_valid; int text_valid; struct DynStrRec tgif_dyn_str; struct DynStrRec utf8_dyn_str; struct DynStrRec text_dyn_str; } SetCutBufferInfo; extern int copyingToCutBuffer; extern int pastingFile; extern char gszFilesIniFile[MAXPATHLENGTH]; extern char *gpszRecentFilesSec; extern char *gpszRecentFilesCountKey; extern int cutBufferIsTgifObj; extern int cutBufferIsUTF8; extern struct DynStrRec dsCutBuffer; extern Time startSelectionOwnershipTime; extern Time endSelectionOwnershipTime; extern int startSelectionOwnershipTimeValid; extern int endSelectionOwnershipTimeValid; extern SetCutBufferInfo gSetCutBufferInfo; #ifdef _INCLUDE_FROM_CUTPASTE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_CUTPASTE_C_*/ extern int WriteBufToCutBuffer ARGS_DECL((char *buf, int buf_sz, int buf_is_simple_string, int buf_is_utf8_string, SetCutBufferInfo*)); extern void ClearSelection ARGS_DECL((void)); extern int CopyToCutBuffer ARGS_DECL((void)); extern int CopyPlainTextAsObject ARGS_DECL((void)); extern void CutToCutBuffer ARGS_DECL((void)); extern unsigned int PasteString ARGS_DECL((char*, int highlight, int record_cmd)); extern void AssignNewObjIds ARGS_DECL((struct ObjRec *)); extern void FreeSelectionOrCutBuffer ARGS_DECL((char*, int nFromSelection)); extern char * FetchSelectionOrCutBuffer ARGS_DECL((int *pnLen, int *pnFromSelection)); extern int PasteFromCutBuffer ARGS_DECL((void)); extern int PasteFromFile ARGS_DECL((void)); extern char * GetTextBytesFromSelection ARGS_DECL((int compound_text, unsigned long*)); extern int PasteCompoundText ARGS_DECL((void)); extern int CopyDoubleByteString ARGS_DECL((void)); extern int PasteDoubleByteString ARGS_DECL((void)); extern void CleanUpCutBuffer ARGS_DECL((void)); extern void SetIntPropertyMask ARGS_DECL((long lWhich, int nValue, char *pszValue, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void SetFontPropertyMask ARGS_DECL((int nDoubleByte, int nFont, int nStyle, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void SetCTMPropertyMask ARGS_DECL((struct XfrmMtrxRec *ctm, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void SetTextPropMask ARGS_DECL((struct ObjRec *, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void CleanUpProperties ARGS_DECL((void)); extern void InitProperties ARGS_DECL((void)); extern void DoGetProperty ARGS_DECL((int index)); extern EditAttrInfo *CreateGetPropertyInfo ARGS_DECL((void)); extern void CopyProperties ARGS_DECL((int nPrompt)); extern void SaveProperties ARGS_DECL((void)); extern void PasteProperties ARGS_DECL((int nPrompt)); extern void RestoreProperties ARGS_DECL((void)); extern void BackupCopiedProperties ARGS_DECL((void)); extern void RestoreCopiedProperties ARGS_DECL((void)); extern int EditIniSection ARGS_DECL((char *pszTitle, char *pszSection, char *pszIniFile, AfterLoopFunc*)); extern char *SelectFromIniSection ARGS_DECL((char *pszTitle, char *pszSection, char *pszIniFile)); extern void FreeRecentFilesListing ARGS_DECL((KeyValInfo*, int)); extern KeyValInfo *RecentFilesListing ARGS_DECL((int *pnEntries)); extern void OpenARecentlyUsedFile ARGS_DECL((int file_index)); extern void AddARecentlyUsedFile ARGS_DECL((char *path)); extern int InitRecentFiles ARGS_DECL((void)); extern void CleanUpRecentFiles ARGS_DECL((void)); extern int CreateSimpleStringObj ARGS_DECL((char*)); extern void SaveSimpleStringObj ARGS_DECL((FILE*, struct ObjRec *)); extern void ReadSimpleStringObj ARGS_DECL((FILE*, char*, struct ObjRec **)); extern void FreeSimpleStringObj ARGS_DECL((struct ObjRec *)); extern void ReplaceGraphic ARGS_DECL((void)); extern void ImportMultipageTextFile ARGS_DECL((void)); extern void SetMarginsForImportMultipageTextFile ARGS_DECL((void)); extern void ToggleWordWrapDuringImportMultipageTextFile ARGS_DECL((void)); extern int RefreshImportMutipageTextFileMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateImportMutipageTextFileMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern void CleanUpCutPaste ARGS_DECL((void)); extern int InitCutPaste ARGS_DECL((void)); #ifdef _INCLUDE_FROM_CUTPASTE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_CUTPASTE_C_*/ #endif /*_CUTPASTE_E_*/ �����������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/rect.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000013543�11602233312�014075� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/rect.e,v 1.6 2011/05/16 16:21:59 william Exp $ */ #ifndef _RECT_E_ #define _RECT_E_ #ifdef _INCLUDE_FROM_RECT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_RECT_C_*/ extern void DumpRectPath ARGS_DECL((FILE *, int LtX, int LtY, int RbX, int RbY, int Indent, int LastLF)); extern void SetPoint ARGS_DECL((IntPoint*, int X, int Y)); extern void ClipRect ARGS_DECL((struct BBRec *, int W, int H)); extern int CompareRect ARGS_DECL((struct BBRec *, struct BBRec *)); extern void SetRotateVs ARGS_DECL((XPoint *, int LtX, int LtY, int RbX, int RbY)); extern void SetBBRec ARGS_DECL((struct BBRec *, int LtX, int LtY, int RbX, int RbY)); extern void ConcatCTM ARGS_DECL((struct XfrmMtrxRec *ctm, struct XfrmMtrxRec *orig_ctm, struct XfrmMtrxRec *new_ctm)); extern void TransformDoublePointThroughCTM ARGS_DECL((double X, double Y, struct XfrmMtrxRec *, double *NewX, double *NewY)); extern void TransformPointThroughCTM ARGS_DECL((int X, int Y, struct XfrmMtrxRec *, int *NewX, int *NewY)); extern void ReverseTransformDoublePointThroughCTM ARGS_DECL((double X, double Y, struct XfrmMtrxRec *, double *NewDx, double *NewDy)); extern void ReverseTransformPointThroughCTM ARGS_DECL((int X, int Y, struct XfrmMtrxRec *, int *NewX, int *NewY)); extern void TransformObjectV ARGS_DECL((struct ObjRec *, IntPoint *VIn, IntPoint *VOut)); extern void ReversedTransformObjectV ARGS_DECL((struct ObjRec *, IntPoint *VIn, IntPoint *VOut)); extern void TransformOffsetBBoxThroughCTM ARGS_DECL((struct BBRec *, struct XfrmMtrxRec *, IntPoint *)); extern void GetTransformedOBBoxOffsetVs ARGS_DECL((struct ObjRec *, XPoint *)); extern void GetTransformedOBBoxAbsVs ARGS_DECL((struct ObjRec *, IntPoint *)); extern void SetCTM ARGS_DECL((struct ObjRec *, struct XfrmMtrxRec *)); extern void ExpandExtents ARGS_DECL((struct BBRec *pBBox, int *pnLtX, int *pnLtY, int *pnRbX, int *pnRbY)); extern void ExpandBBox ARGS_DECL((struct BBRec *pBBox, struct BBRec *pBBoxToExpand)); extern void InflateBBox ARGS_DECL((struct BBRec *pBBoxIn, int Dx, int Dy, struct BBRec *pBBoxOut)); extern void OffsetBBox ARGS_DECL((struct BBRec *pBBoxIn, int Dx, int Dy, struct BBRec *pBBoxOut)); extern int BBoxIntersect ARGS_DECL((struct BBRec BBox1, struct BBRec BBox2)); extern int IntersectRect ARGS_DECL((struct BBRec BBox1, struct BBRec BBox2, struct BBRec *BBox3)); extern void UnionRect ARGS_DECL((struct BBRec *BBox1, struct BBRec *BBox2, struct BBRec *UnionBBox)); extern int Inside ARGS_DECL((struct BBRec Rect1, struct BBRec Rect2)); extern int PointInBBox ARGS_DECL((int X, int Y, struct BBRec Rect)); extern int PointInIntPolygon ARGS_DECL((int X, int Y, int NumPts, IntPoint *)); extern int PointInPolygon ARGS_DECL((int X, int Y, int NumPts, XPoint *)); extern int PointInPoly ARGS_DECL((int X, int Y, int NumPts, XPoint *, int LineWidth)); extern int PointOnPoly ARGS_DECL((int X, int Y, int NumPts, XPoint *, int LineWidth)); extern int FindGoodText ARGS_DECL((int XOff, int YOff, struct ObjRec *)); extern int FindGoodXBm ARGS_DECL((int XOff, int YOff, struct ObjRec *)); extern int FindGoodXPm ARGS_DECL((int XOff, int YOff, struct ObjRec *)); extern int FindGoodBox ARGS_DECL((int XOff, int YOff, struct ObjRec *)); extern int FindGoodRCBox ARGS_DECL((int XOff, int YOff, struct ObjRec *)); extern int FindGoodOval ARGS_DECL((int XOff, int YOff, struct ObjRec *)); extern int FindGoodPoly ARGS_DECL((int XOff, int YOff, struct ObjRec *)); extern int FindGoodPolygon ARGS_DECL((int XOff, int YOff, struct ObjRec *)); extern int FindGoodArc ARGS_DECL((int XOff, int YOff, struct ObjRec *)); extern int FindGoodObj ARGS_DECL((int XOff, int YOff, struct ObjRec *First, struct ObjRec **SubObj, struct ObjRec **ImmediateChildObj)); #ifdef _INCLUDE_FROM_RECT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_RECT_C_*/ #endif /*_RECT_E_*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/polygon.e����������������������������������������������������������������������������0000644�0000764�0000764�00000004746�11602233312�014634� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/polygon.e,v 1.6 2011/05/16 16:21:59 william Exp $ */ #ifndef _POLYGON_E_ #define _POLYGON_E_ extern int polygonDrawn; #ifdef _INCLUDE_FROM_POLYGON_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_POLYGON_C_*/ extern XPoint * MakePolygonVertex ARGS_DECL((int XOff, int YOff, int NumVs, IntPoint *)); extern void DumpPoints ARGS_DECL((FILE *, int NumPts, IntPoint *, int Indent)); extern void DumpPolygonObj ARGS_DECL((FILE *, struct ObjRec *)); extern int NeedsToCachePolygonObj ARGS_DECL((struct ObjRec *)); extern void DrawPolygonObj ARGS_DECL((Window, int XOff, int YOff, struct ObjRec *)); extern void CreatePolygonObj ARGS_DECL((int NumPts, int CreateAbsolute)); extern void ResetCreatePolygon ARGS_DECL((void)); extern void AddPtToCreatePolygon ARGS_DECL((int AbsX, int AbsY)); extern void DrawPolygon ARGS_DECL((XEvent *)); extern void SelectAndHighLightNewObjects ARGS_DECL((struct ObjRec *)); extern void InputPolygonPts ARGS_DECL((void)); extern void GetBoundingBox ARGS_DECL((void)); extern void SavePolygonObj ARGS_DECL((FILE *, struct ObjRec *)); extern void ReadPolygonObj ARGS_DECL((FILE *, char *Inbuf, struct ObjRec **)); extern void SetPolygonPropMask ARGS_DECL((struct ObjRec *, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void FreePolygonObj ARGS_DECL((struct ObjRec *)); #ifdef _INCLUDE_FROM_POLYGON_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_POLYGON_C_*/ #endif /*_POLYGON_E_*/ ��������������������������tgif-QPL-4.2.5/Tgif.tmpl-hpux�����������������������������������������������������������������������0000644�0000764�0000764�00000005320�11602233313�015536� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-hpux,v 1.12 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif STD_INCLUDES = -I/usr/include/X11R5 USRLIBDIR = /usr/lib/X11R5 LDOPTIONS = $(CDEBUGFLAGS) $(CCOPTIONS) -L /usr/lib/X11R5 XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/lib/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_DL_SUPPORT -D_NO_LOCALE_SUPPORT \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_NO_RECURSIVE_EXTERN -D_NO_IDNLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) XCOMM SYS_LIBRARIES = -ldl -lm -lz SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r -m): XCOMM XCOMM HP-UX A.09.05 9000/715 XCOMM XCOMM HP-UX A.09.07 9000/735 XCOMM XCOMM HP-UX B.10.20 9000/735 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/wb_mcast.c���������������������������������������������������������������������������0000644�0000764�0000764�00000000507�11602233314�014733� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Raphael S. de Moraes <raphael@land.ufrj.br> in April, 1999 * * (Obsoleted in tgif-4.1.41 by the TGWB group at land.ufrj.br.) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb_mcast.c,v 1.2 2008/10/16 21:13:03 william Exp $ */ #define _INCLUDE_FROM_WB_MCAST_C_ #include "tgifdefs.h" #include "wb_mcast.e" �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/help.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000022042�11602233311�014057� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/help.c,v 1.7 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_HELP_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "color.e" #include "dialog.e" #include "file.e" #include "help.e" #include "menu.e" #include "menuinfo.e" #include "msg.e" #include "navigate.e" #include "remote.e" #include "setup.e" #include "strtbl.e" #include "util.e" #include "version.e" #define HELP_ABOUT 0 #define HELP_COPYRIGHT 1 #define HELP_CURRENT 2 #define MAXHELPS 3 int numHelp=MAXHELPS; /* ----------------------- About ----------------------- */ void About() { char *c_ptr=NULL; GetTgifVersionAndPatchLevel(gszMsgBox, sizeof(gszMsgBox)); c_ptr = (&gszMsgBox[strlen(gszMsgBox)]); sprintf(c_ptr, "\n\n%s", copyrightString); c_ptr = (&c_ptr[strlen(c_ptr)]); sprintf(c_ptr, TgLoadString(STID_HYPER_TEXT_HOME), homePageURL); c_ptr = (&c_ptr[strlen(c_ptr)]); sprintf(c_ptr, TgLoadString(STID_LATEST_REL_INFO), currentReleaseURL); c_ptr = (&c_ptr[strlen(c_ptr)]); sprintf(c_ptr, TgLoadString(STID_HYPER_GRAPHICS_INFO), hyperGraphicsURL); c_ptr = (&c_ptr[strlen(c_ptr)]); sprintf(c_ptr, TgLoadString(STID_MAILING_LIST_INFO), mailingList, joinMailingList, mailingURL); c_ptr = (&c_ptr[strlen(c_ptr)]); sprintf(c_ptr, TgLoadString(STID_SEND_BUG_REPORT_TO), "bill.cheng@acm.org"); c_ptr = (&c_ptr[strlen(c_ptr)]); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } /* ----------------------- Copyright ----------------------- */ /* do not translate -- program constants */ static char *gszCopyright[] = { "", #ifdef QPL_LICENSE "This software is distributed under the terms of the Q Public License", "as defined by Trolltech AS of Norway and appearing in the file", "LICENSE.QPL included in the packaging of this file.", "", "THIS SOFTWARE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING", "THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR", "PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL,", "INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING", "FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,", "NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION", "WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.", #else /* ~QPL_LICENSE */ "William Cheng (\"Author\") grants to the party hereby receiving \"tgif\"", "(\"Recipient\") a non-exclusive, royalty-free license limited to copy,", "display, and distribute without charging for a fee, and produce derivative", "works of \"tgif\", provided that the above copyright notice appears in", "all copies made of \"tgif\" and both the copyright notice and this license", "appear in supporting documentation, and that the name of Author not be", "used in advertising or publicity pertaining to \"tgif\". All other rights", "(including, but not limited to, the right to sell \"tgif\", the right to", "sell or distribute derivative", "works of \"tgif\", the right to distribute \"tgif\" for a fee, and", "the right to include \"tgif\" or derivative workds of \"tgif\" in a", "for-sale product) are reserved by the Author.", "", "\"Tgif\" is provided \"as is\" without express or implied warranty. Author", "does not and cannot warrant the performance of \"tgif\" or the results", "that may be obtained by its use or its fitness for any specific use by", "Recipient or any third party. In no event shall Author become liable", "to Recipient or any other party, for any loss or damages,", "consequential or otherwise, including but not limited to time, money,", "or goodwill, arising from use or possession, authorized or not, of", "\"tgif\" by Recipient or any other party.", #endif /* QPL_LICENSE */ NULL }; void Copyright() { char **s_ptr=gszCopyright, *c_ptr=gszMsgBox; sprintf(c_ptr, "%s ", copyrightString); c_ptr = (&gszMsgBox[strlen(c_ptr)]); for ( ; *s_ptr != NULL; s_ptr++) { if (**s_ptr == '\0') { strcpy(c_ptr, "\n\n"); } else { sprintf(c_ptr, "%s ", *s_ptr); } c_ptr = (&c_ptr[strlen(c_ptr)]); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } void LatestReleaseInfo() { char tmp_fname[MAXPATHLENGTH+1], final_url[MAXPATHLENGTH+1]; char current_url[MAXPATHLENGTH<<1]; char *content_type=NULL, *page_spec=NULL; int is_html=FALSE, rc=FALSE; *final_url = '\0'; strcpy(current_url, currentReleaseURL); navigateRefresh = TRUE; rc = DownloadRemoteFile(current_url, &content_type, &page_spec, &is_html, tmp_fname, final_url, sizeof(final_url)); navigateRefresh = FALSE; if (content_type != NULL) FreeRemoteBuf(content_type); if (page_spec != NULL) UtilFree(page_spec); if (rc) { FILE *fp=fopen(tmp_fname, "r"); char version_str[MAXPATHLENGTH<<1]; *version_str = '\0'; if (fp == NULL) { sprintf(gszMsgBox, TgLoadString(STID_OPEN_URL_FAIL_USE_BROWSER), currentReleaseURL, currentReleaseURL); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { /* do not translate -- program constants */ int len=strlen("The current release of tgif is"), scanning=TRUE; char *buf; while (scanning && (buf=UtilGetALine(fp)) != NULL) { /* do not translate -- program constants */ if (strncmp(buf, "The current release of tgif is", len) == 0) { char *buf1=UtilGetALine(fp); scanning = FALSE; if (buf1 != NULL) { /* do not translate -- program constants */ char *version_ptr=strstr(buf1, "Version"), *c_ptr=NULL; if (version_ptr != NULL && (c_ptr=strchr(version_ptr, '<')) != NULL) { *c_ptr = '\0'; strcpy(version_str, version_ptr); *c_ptr = '<'; } UtilFree(buf1); } } UtilFree(buf); } fclose(fp); if (*version_str == '\0') { sprintf(gszMsgBox, TgLoadString(STID_FIND_VER_FAIL_USE_BROWSER), currentReleaseURL, currentReleaseURL); } else if (TGIF_PATCHLEVEL == 0) { if (*specialBuild == '\0') { sprintf(gszMsgBox, TgLoadString(STID_TOOL_CUR_VER_IS_DIFF_INFO), TOOL_NAME, version_str, TOOL_NAME, versionString, (*final_url=='\0' ? currentReleaseURL : final_url)); } else { sprintf(gszMsgBox, TgLoadString(STID_TOOL_CUR_VER_IS_DIFF_SPC_INFO), TOOL_NAME, version_str, TOOL_NAME, versionString, specialBuild, (*final_url=='\0' ? currentReleaseURL : final_url)); } } else { if (*specialBuild == '\0') { sprintf(gszMsgBox, TgLoadString(STID_TOOL_CUR_VER_PATCH_INFO), TOOL_NAME, version_str, TOOL_NAME, versionString, TGIF_PATCHLEVEL, (*final_url=='\0' ? currentReleaseURL : final_url)); } else { sprintf(gszMsgBox, TgLoadString(STID_TOOL_CUR_VER_PATCH_SPC_INFO), TOOL_NAME, version_str, TOOL_NAME, versionString, TGIF_PATCHLEVEL, specialBuild, (*final_url=='\0' ? currentReleaseURL : final_url)); } } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_DOWNLOAD_VER_USE_BROWSER), currentReleaseURL, currentReleaseURL); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } if (*tmp_fname != '\0') unlink(tmp_fname); } /* ----------------------- Init and Clean Up ----------------------- */ void CleanUpHelp() { } void InitHelp() { } /* ----------------------- Menu Functions ----------------------- */ void RefreshHelpMenu(menu) TgMenu *menu; { } int HelpMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(helpMenuInfo.create_proc)(NULL, X, Y, &helpMenuInfo, FALSE); activeMenu = MENU_HELP; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/select.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000254024�11602233312�014416� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/select.c,v 1.26 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_SELECT_C_ #include "tgifdefs.h" #include "attr.e" #include "auxtext.e" #include "button.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "edit.e" #include "exec.e" #include "file.e" #include "font.e" #include "grid.e" #include "group.e" #include "http.e" #include "mainloop.e" #include "mark.e" #include "menu.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "pin.e" #include "poly.e" #include "raster.e" #include "rect.e" #include "remote.e" #include "ruler.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "special.e" #include "stk.e" #include "stretch.e" #include "strtbl.e" #include "util.e" #define FORWARD 0 #define REVERSE 1 int selLtX=0, selLtY=0, selRbX=0, selRbY=0; int selObjLtX=0, selObjLtY=0, selObjRbX=0, selObjRbY=0; int selNoLockLtX=0, selNoLockLtY=0, selNoLockRbX=0, selNoLockRbY=0; int selNoLockObjLtX=0, selNoLockObjLtY=0; int selNoLockObjRbX=0, selNoLockObjRbY=0; int numObjSelected=0; int numObjLocked=0; struct SelRec *topSel=NULL, *botSel=NULL; struct VSelRec *topVSel=NULL, *botVSel=NULL; int GetObjCurved(ObjPtr) struct ObjRec *ObjPtr; { switch (ObjPtr->type) { case OBJ_POLY: return ObjPtr->detail.p->curved; case OBJ_POLYGON: return ObjPtr->detail.g->curved; } #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "Unexpected object type in GetObjCurved()", NULL); #endif /* _TGIF_DBG */ return 0; } struct SelRec *SelectThisObject(ObjPtr) struct ObjRec *ObjPtr; { struct SelRec *sel_ptr=(struct SelRec *)malloc(sizeof(struct SelRec)); if (sel_ptr == NULL) FailAllocMessage(); memset(sel_ptr, 0, sizeof(struct SelRec)); sel_ptr->obj = ObjPtr; return sel_ptr; } int CountSelectedVertices() { struct VSelRec *vsel_ptr; int count = 0; for (vsel_ptr=topVSel; vsel_ptr != NULL; vsel_ptr=vsel_ptr->next) { int curved=GetObjCurved(vsel_ptr->obj); if (curved == LT_STRUCT_SPLINE) { /* can select at most one vertex for LT_STRUCT_SPLINE */ count++; } else { int n=vsel_ptr->n; count += n; if (vsel_ptr->obj->type == OBJ_POLYGON) { int i=0; for (i=0; i < n; i++) { if (vsel_ptr->v_index[i] == 0) { count--; break; } } } } } return count; } void CalcBBox(X1, Y1, X2, Y2, LtX, LtY, RbX, RbY) int X1, Y1, X2, Y2, * LtX, * LtY, * RbX, * RbY; { if (X1 < X2) { if (Y1 < Y2) { *LtX = X1; *LtY = Y1; *RbX = X2; *RbY = Y2; } else { *LtX = X1; *LtY = Y2; *RbX = X2; *RbY = Y1; } } else { if (Y1 < Y2) { *LtX = X2; *LtY = Y1; *RbX = X1; *RbY = Y2; } else { *LtX = X2; *LtY = Y2; *RbX = X1; *RbY = Y1; } } } void CalcVertexBBox(LtX, LtY, RbX, RbY) int *LtX, *LtY, *RbX, *RbY; { register int i, *x_ptr, *y_ptr; struct VSelRec *vsel_ptr; *LtX = selRbX; *LtY = selRbY; *RbX = selLtX; *RbY = selLtY; for (vsel_ptr=topVSel; vsel_ptr!=NULL; vsel_ptr=vsel_ptr->next) { for (i=0, x_ptr=vsel_ptr->x, y_ptr=vsel_ptr->y; i < vsel_ptr->n; i++, x_ptr++, y_ptr++) { if (*x_ptr < *LtX) *LtX = *x_ptr; if (*y_ptr < *LtY) *LtY = *y_ptr; if (*x_ptr > *RbX) *RbX = *x_ptr; if (*y_ptr > *RbY) *RbY = *y_ptr; } } } void UnSelNonVertexObjs(highlight, no_locked_obj_only) int highlight, no_locked_obj_only; { register struct ObjRec *obj_ptr; register struct SelRec *sel_ptr, *prev_sel; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=prev_sel) { prev_sel = sel_ptr->prev; obj_ptr = sel_ptr->obj; if ((obj_ptr->type==OBJ_POLY || obj_ptr->type==OBJ_POLYGON) && (!no_locked_obj_only || !obj_ptr->locked)) { continue; } if (highlight) HighLightAnObj(obj_ptr); if (sel_ptr->prev == NULL) { topSel = sel_ptr->next; } else { sel_ptr->prev->next = sel_ptr->next; } if (sel_ptr->next == NULL) { botSel = sel_ptr->prev; } else { sel_ptr->next->prev = sel_ptr->prev; } free(sel_ptr); } } void FreeTopSel() { struct SelRec *sel_ptr=topSel; topSel = topSel->next; if (topSel != NULL) { topSel->prev = NULL; } else { botSel = NULL; } free(sel_ptr); numObjSelected--; UpdSelBBox(); } void JustFreeSel(pTopSel, pBotSel) struct SelRec *pTopSel, *pBotSel; { struct SelRec *pNextSel=NULL; for ( ; pTopSel != NULL; pTopSel=pNextSel) { pNextSel = pTopSel->next; free(pTopSel); } } void UnlinkSel(pSel, ppTopSel, ppBotSel) struct SelRec *pSel, **ppTopSel, **ppBotSel; { if ((*ppTopSel) == pSel) { (*ppTopSel) = pSel->next; } else { pSel->prev->next = pSel->next; } if ((*ppBotSel) == pSel) { (*ppBotSel) = pSel->prev; } else { pSel->next->prev = pSel->prev; } } struct SelRec *FindObjInSel(pObj, pTopSel, pBotSel) struct ObjRec *pObj; struct SelRec *pTopSel, *pBotSel; { for ( ; pTopSel != NULL; pTopSel=pTopSel->next) { if (pTopSel->obj == pObj) { return pTopSel; } } return NULL; } int PrependObjToSel(pObj, ppTopSel, ppBotSel) struct ObjRec *pObj; struct SelRec **ppTopSel, **ppBotSel; { int nReturn=TRUE; struct SelRec *pSel=(struct SelRec *)malloc(sizeof(struct SelRec)); if (pSel == NULL) { FailAllocMessage(); nReturn = FALSE; } memset(pSel, 0, sizeof(struct SelRec)); pSel->obj = pObj; pSel->next = (*ppTopSel); pSel->prev = NULL; if ((*ppTopSel) == NULL) { (*ppBotSel) = pSel; } else { (*ppTopSel)->prev = pSel; } (*ppTopSel) = pSel; return nReturn; } struct SelRec *AddObjIntoSel(pObj, pPrevSel, pNextSel, ppTopSel, ppBotSel) struct ObjRec *pObj; struct SelRec *pPrevSel, *pNextSel, **ppTopSel, **ppBotSel; { struct SelRec *pSel=(struct SelRec *)malloc(sizeof(struct SelRec)); if (pSel == NULL) { FailAllocMessage(); return NULL; } memset(pSel, 0, sizeof(struct SelRec)); pSel->obj = pObj; pSel->next = pNextSel; pSel->prev = pPrevSel; if (pPrevSel == NULL) { (*ppTopSel) = pSel; } else { pPrevSel->next = pSel; } if (pNextSel == NULL) { (*ppBotSel) = pSel; } else { pNextSel->prev = pSel; } return pSel; } void JustRemoveAllVSel() { register struct VSelRec *next_vsel; while (topVSel != NULL) { next_vsel = topVSel->next; free(topVSel->v_index); free(topVSel->x); free(topVSel->y); free(topVSel); topVSel = next_vsel; } botVSel = NULL; } void RemoveAllSel() { register struct SelRec *next_sel; register struct VSelRec *next_vsel; while (topSel != NULL) { next_sel = topSel->next; free(topSel); topSel = next_sel; } botSel = NULL; while (topVSel != NULL) { next_vsel = topVSel->next; free(topVSel->v_index); free(topVSel->x); free(topVSel->y); free(topVSel); topVSel = next_vsel; } botVSel = NULL; numObjSelected = 0; } struct AttrRec *FindObjAttrWithName(ObjPtr, AttrName) struct ObjRec *ObjPtr; char *AttrName; /* AttrName here must not contain '.' */ { register struct AttrRec *attr_ptr; struct AttrRec *found_attr=NULL; int count=1, compare_name=(strchr(AttrName,'=') != NULL); if (ObjPtr == NULL) return NULL; for (attr_ptr=ObjPtr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (compare_name) { if (strcmp(attr_ptr->attr_name.s, AttrName) == 0) { found_attr = attr_ptr; break; } } else { if (strcmp(attr_ptr->attr_value.s, AttrName) == 0) { found_attr = attr_ptr; break; } } } if (attr_ptr == NULL) return NULL; if (GetTextObjFirstStrSeg(found_attr->obj)->color == colorIndex) { return found_attr; } for (attr_ptr=found_attr->next; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (compare_name) { if (strcmp(attr_ptr->attr_name.s, AttrName) == 0) { if (GetTextObjFirstStrSeg(attr_ptr->obj)->color == colorIndex) { break; } else if (GetTextObjFirstStrSeg(attr_ptr->obj)->color == GetTextObjFirstStrSeg(found_attr->obj)->color) { /* same color as found_attr's color, so don't increase count */ } else { count++; } } } else { if (strcmp(attr_ptr->attr_value.s, AttrName) == 0) { if (GetTextObjFirstStrSeg(attr_ptr->obj)->color == colorIndex) { break; } else if (GetTextObjFirstStrSeg(attr_ptr->obj)->color == GetTextObjFirstStrSeg(found_attr->obj)->color) { /* same color as found_attr's color, so don't increase count */ } else { count++; } } } } if (attr_ptr != NULL) { found_attr = attr_ptr; } else if (count != 1) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANT_FIND_ATTR_WITH_COLOR), AttrName, colorMenuItems[colorIndex]); Msg(gszMsgBox); return NULL; } return found_attr; } static struct ObjRec *FindAVertex(XOff, YOff, VIndex, AbsX, AbsY) int XOff, YOff, *VIndex, *AbsX, *AbsY; /* XOff and YOff are screen offsets */ { struct SelRec *sel_ptr; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; int n=0; IntPoint *vs=NULL; if (obj_ptr->type != OBJ_POLY && obj_ptr->type != OBJ_POLYGON) continue; if (!(XOff >= OFFSET_X(obj_ptr->bbox.ltx)-3 && YOff >= OFFSET_Y(obj_ptr->bbox.lty)-3 && XOff <= OFFSET_X(obj_ptr->bbox.rbx)+3 && YOff <= OFFSET_Y(obj_ptr->bbox.rby)+3)) { continue; } switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; if (poly_ptr->curved == LT_STRUCT_SPLINE) { n = poly_ptr->ssn; vs = poly_ptr->ssvlist; } else { n = poly_ptr->n; vs = poly_ptr->vlist; } if (PtInPolyMark(obj_ptr, XOff, YOff, n, vs, VIndex)) { if (obj_ptr->ctm == NULL) { *AbsX = vs[*VIndex].x; *AbsY = vs[*VIndex].y; } else { int x, y; TransformPointThroughCTM( vs[*VIndex].x-obj_ptr->x, vs[*VIndex].y-obj_ptr->y, obj_ptr->ctm, &x, &y); *AbsX = x+obj_ptr->x; *AbsY = y+obj_ptr->y; } return obj_ptr; } break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; if (polygon_ptr->curved == LT_STRUCT_SPLINE) { n = polygon_ptr->ssn; vs = polygon_ptr->ssvlist; } else { n = polygon_ptr->n; vs = polygon_ptr->vlist; } if (PtInPolyMark(obj_ptr, XOff, YOff, n, vs, VIndex)) { if (obj_ptr->ctm == NULL) { *AbsX = vs[*VIndex].x; *AbsY = vs[*VIndex].y; } else { int x, y; TransformPointThroughCTM(vs[*VIndex].x-obj_ptr->x, vs[*VIndex].y-obj_ptr->y, obj_ptr->ctm, &x, &y); *AbsX = x+obj_ptr->x; *AbsY = y+obj_ptr->y; } return obj_ptr; } break; } } return NULL; } static int CandidatePortOwner(obj_ptr) struct ObjRec *obj_ptr; { if (obj_ptr->type == OBJ_SYM || obj_ptr->type == OBJ_ICON) { return TRUE; } else if (obj_ptr->type == OBJ_GROUP) { struct AttrRec *attr_ptr=FindAttrWithName(obj_ptr, "type=", NULL); if (attr_ptr != NULL && strcmp(attr_ptr->attr_value.s, "tgBroadcastWire") == 0) { return TRUE; } } return FALSE; } struct ObjRec *FindAnObj(XOff, YOff, OwnerObj, ConnectObj, ReturnedObjName) int XOff, YOff; struct ObjRec **OwnerObj, **ConnectObj; char *ReturnedObjName; /* XOff and YOff are screen offsets */ { register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; struct ObjRec *sub_obj, *returned_obj=NULL, *actual_obj=NULL; struct ObjRec *owner_obj=NULL; int found_attr=FALSE; if (OwnerObj != NULL) *OwnerObj = NULL; if (ConnectObj != NULL) *ConnectObj = NULL; if (ReturnedObjName != NULL) *ReturnedObjName = '\0'; for (obj_ptr=topObj; returned_obj==NULL && obj_ptr!=NULL; obj_ptr=obj_ptr->next) { obj_ptr->tmp_child = NULL; obj_ptr->tmp_parent = NULL; if (colorLayers && !ObjInVisibleLayer(obj_ptr)) { continue; } actual_obj = obj_ptr; for (attr_ptr=obj_ptr->fattr; returned_obj==NULL && attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown && XOff >= OFFSET_X(attr_ptr->obj->bbox.ltx)-3 && YOff >= OFFSET_Y(attr_ptr->obj->bbox.lty)-3 && XOff <= OFFSET_X(attr_ptr->obj->bbox.rbx)+3 && YOff <= OFFSET_Y(attr_ptr->obj->bbox.rby)+3) { owner_obj = obj_ptr; returned_obj = attr_ptr->obj; found_attr = TRUE; break; } } if (returned_obj != NULL) break; if (XOff >= OFFSET_X(obj_ptr->bbox.ltx)-3 && YOff >= OFFSET_Y(obj_ptr->bbox.lty)-3 && XOff <= OFFSET_X(obj_ptr->bbox.rbx)+3 && YOff <= OFFSET_Y(obj_ptr->bbox.rby)+3) { struct ObjRec *next_level_child=NULL, *visible_obj=NULL; switch (obj_ptr->type) { case OBJ_TEXT: if (FindGoodText(XOff,YOff,obj_ptr)) returned_obj = obj_ptr; break; case OBJ_XBM: if (FindGoodXBm(XOff,YOff,obj_ptr)) returned_obj = obj_ptr; break; case OBJ_XPM: if (FindGoodXPm(XOff,YOff,obj_ptr)) returned_obj = obj_ptr; break; case OBJ_BOX: if (FindGoodBox(XOff,YOff,obj_ptr)) returned_obj = obj_ptr; break; case OBJ_OVAL: if (FindGoodOval(XOff,YOff,obj_ptr)) returned_obj = obj_ptr; break; case OBJ_POLY: if (FindGoodPoly(XOff,YOff,obj_ptr)) returned_obj = obj_ptr; break; case OBJ_POLYGON: if (FindGoodPolygon(XOff,YOff,obj_ptr)) returned_obj = obj_ptr; break; case OBJ_ARC: if (FindGoodArc(XOff,YOff,obj_ptr)) returned_obj = obj_ptr; break; case OBJ_RCBOX: if (FindGoodRCBox(XOff,YOff,obj_ptr)) returned_obj = obj_ptr; break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: if (colorLayers) { struct ObjRec *tmp_obj; for (tmp_obj=obj_ptr->detail.r->first; tmp_obj != NULL; tmp_obj=tmp_obj->next) { tmp_obj->tmp_parent = obj_ptr; } } if (FindGoodObj(XOff, YOff, obj_ptr->detail.r->first, &sub_obj, &next_level_child)) { obj_ptr->tmp_child = next_level_child; if (sub_obj == NULL) { owner_obj = NULL; returned_obj = obj_ptr; } else { owner_obj = obj_ptr; returned_obj = sub_obj; } } break; case OBJ_PIN: visible_obj = GetPinObj(obj_ptr); if (colorLayers) { struct ObjRec *tmp_obj; for (tmp_obj=visible_obj->detail.r->first; tmp_obj != NULL; tmp_obj=tmp_obj->next) { tmp_obj->tmp_parent = visible_obj; } } obj_ptr->tmp_child = visible_obj; if (FindGoodObj(XOff, YOff, GetPinObj(obj_ptr), &sub_obj, &next_level_child)) { visible_obj->tmp_child = next_level_child; if (sub_obj == NULL) { owner_obj = NULL; returned_obj = obj_ptr; } else { owner_obj = obj_ptr; returned_obj = sub_obj; } } break; } } } if (ReturnedObjName != NULL) { char *c_ptr; *ReturnedObjName = '\0'; c_ptr = ReturnedObjName; if (returned_obj != NULL) { struct ObjRec *prev_obj=NULL; int see_sym_or_icon=FALSE; for (obj_ptr=actual_obj; obj_ptr != NULL; obj_ptr=obj_ptr->tmp_child) { /* do not translate -- program constants */ if (connectingPortsFromInternalCommand) { /* this is pretty much left for compatibility only */ if ((attr_ptr=FindObjAttrWithName(obj_ptr, "name=")) != NULL) { *c_ptr++ = '!'; strcpy(c_ptr, attr_ptr->attr_value.s); c_ptr = &c_ptr[strlen(c_ptr)]; } else { if (prev_obj != NULL) prev_obj->tmp_child = NULL; break; } } else { int just_seen_sym_or_icon=FALSE; if (!see_sym_or_icon) { if (CandidatePortOwner(obj_ptr)) { see_sym_or_icon = TRUE; just_seen_sym_or_icon = TRUE; } } if (see_sym_or_icon) { if ((attr_ptr=FindObjAttrWithName(obj_ptr, "name=")) == NULL) { /* broken name is invalid */ c_ptr = ReturnedObjName; if (prev_obj != NULL) prev_obj->tmp_child = NULL; break; } else if (BlankStr(attr_ptr->attr_value.s)) { /* do not translate -- program constants */ *c_ptr++ = '!'; strcpy(c_ptr, "(unknown)"); c_ptr = &c_ptr[strlen(c_ptr)]; } else { *c_ptr++ = '!'; strcpy(c_ptr, attr_ptr->attr_value.s); c_ptr = &c_ptr[strlen(c_ptr)]; } if (!just_seen_sym_or_icon && CandidatePortOwner(obj_ptr)) { obj_ptr->tmp_child = NULL; prev_obj = obj_ptr; break; } } } prev_obj = obj_ptr; } if (ConnectObj != NULL) *ConnectObj = prev_obj; } if (c_ptr == ReturnedObjName) { *ReturnedObjName = '\0'; } else { *c_ptr = '\0'; } } if (OwnerObj != NULL) *OwnerObj = owner_obj; return returned_obj; } static int VertexAlreadySelected(ObjPtr, VIndex, VSelPtr) register struct ObjRec *ObjPtr; int VIndex; register struct VSelRec **VSelPtr; { register int i; for (*VSelPtr=topVSel; *VSelPtr != NULL; *VSelPtr=(*VSelPtr)->next) { if ((*VSelPtr)->obj == ObjPtr) { for (i = 0; i < (*VSelPtr)->n; i++) { if ((*VSelPtr)->v_index[i] == VIndex) { return TRUE; } } return FALSE; } } return FALSE; } struct SelRec *AlreadySelected(ObjPtr) register struct ObjRec *ObjPtr; { register struct SelRec *sel_ptr; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (sel_ptr->obj == ObjPtr) { return sel_ptr; } } return NULL; } void AddSel(PrevPtr, NextPtr, SelPtr) struct SelRec *PrevPtr, *NextPtr, *SelPtr; /* add SelPtr between PrevPtr and NextPtr */ { SelPtr->prev = PrevPtr; SelPtr->next = NextPtr; if (PrevPtr == NULL) { topSel = SelPtr; } else { PrevPtr->next = SelPtr; } if (NextPtr == NULL) { botSel = SelPtr; } else { NextPtr->prev = SelPtr; } numObjSelected++; } void AddNewSelObj(ObjPtr) register struct ObjRec *ObjPtr; { register struct ObjRec *obj_ptr=topObj; register struct SelRec *sel_ptr=topSel, *new_sel_ptr; new_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (new_sel_ptr == NULL) FailAllocMessage(); new_sel_ptr->obj = ObjPtr; for ( ; sel_ptr != NULL && obj_ptr != ObjPtr; obj_ptr=obj_ptr->next) { if (obj_ptr == sel_ptr->obj) { sel_ptr = sel_ptr->next; } } if (sel_ptr == NULL) { /* the object is below the last selected object */ if (botSel == NULL) { topSel = new_sel_ptr; } else { botSel->next = new_sel_ptr; } new_sel_ptr->prev = botSel; new_sel_ptr->next = NULL; botSel = new_sel_ptr; } else { /* the object is between sel_ptr and sel_ptr->prev */ if (sel_ptr->prev == NULL) { topSel = new_sel_ptr; } else { sel_ptr->prev->next = new_sel_ptr; } new_sel_ptr->next = sel_ptr; new_sel_ptr->prev = sel_ptr->prev; sel_ptr->prev = new_sel_ptr; } numObjSelected++; } void ExpandCurSelBBoxes(obj_ptr) struct ObjRec *obj_ptr; { if (obj_ptr->bbox.ltx < selLtX) selLtX = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < selLtY) selLtY = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx < selRbX) selRbX = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby < selRbY) selRbY = obj_ptr->bbox.rby; if (obj_ptr->obbox.ltx < selObjLtX) { selObjLtX = obj_ptr->obbox.ltx; } if (obj_ptr->obbox.lty < selObjLtY) { selObjLtY = obj_ptr->obbox.lty; } if (obj_ptr->obbox.rbx < selObjRbX) { selObjRbX = obj_ptr->obbox.rbx; } if (obj_ptr->obbox.rby < selObjRbY) { selObjRbY = obj_ptr->obbox.rby; } } static void SetNoLockBBox(ObjPtr) struct ObjRec *ObjPtr; { selNoLockLtX = ObjPtr->bbox.ltx; selNoLockLtY = ObjPtr->bbox.lty; selNoLockRbX = ObjPtr->bbox.rbx; selNoLockRbY = ObjPtr->bbox.rby; selNoLockObjLtX = ObjPtr->obbox.ltx; selNoLockObjLtY = ObjPtr->obbox.lty; selNoLockObjRbX = ObjPtr->obbox.rbx; selNoLockObjRbY = ObjPtr->obbox.rby; } void UpdSelBBox() /* update selLtX, selLtY, selRbX, selRbY */ { register struct ObjRec *obj_ptr; register struct SelRec *sel_ptr; int seen_no_locked=FALSE; numObjSelected = 0; numObjLocked = 0; if ((sel_ptr = topSel) == NULL) return; numObjSelected++; obj_ptr = sel_ptr->obj; if (obj_ptr->locked) numObjLocked++; selLtX = obj_ptr->bbox.ltx; selLtY = obj_ptr->bbox.lty; selRbX = obj_ptr->bbox.rbx; selRbY = obj_ptr->bbox.rby; selObjLtX = obj_ptr->obbox.ltx; selObjLtY = obj_ptr->obbox.lty; selObjRbX = obj_ptr->obbox.rbx; selObjRbY = obj_ptr->obbox.rby; if (!obj_ptr->locked) { SetNoLockBBox(obj_ptr); seen_no_locked = TRUE; } for (sel_ptr=topSel->next; sel_ptr != NULL; sel_ptr=sel_ptr->next) { numObjSelected++; obj_ptr = sel_ptr->obj; if (obj_ptr->bbox.ltx < selLtX) selLtX = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < selLtY) selLtY = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > selRbX) selRbX = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > selRbY) selRbY = obj_ptr->bbox.rby; if (obj_ptr->obbox.ltx < selObjLtX) selObjLtX = obj_ptr->obbox.ltx; if (obj_ptr->obbox.lty < selObjLtY) selObjLtY = obj_ptr->obbox.lty; if (obj_ptr->obbox.rbx > selObjRbX) selObjRbX = obj_ptr->obbox.rbx; if (obj_ptr->obbox.rby > selObjRbY) selObjRbY = obj_ptr->obbox.rby; if (obj_ptr->locked) { numObjLocked++; } else { if (seen_no_locked) { if (obj_ptr->bbox.ltx < selNoLockLtX) { selNoLockLtX = obj_ptr->bbox.ltx; } if (obj_ptr->bbox.lty < selNoLockLtY) { selNoLockLtY = obj_ptr->bbox.lty; } if (obj_ptr->bbox.rbx > selNoLockRbX) { selNoLockRbX = obj_ptr->bbox.rbx; } if (obj_ptr->bbox.rby > selNoLockRbY) { selNoLockRbY = obj_ptr->bbox.rby; } if (obj_ptr->obbox.ltx < selNoLockObjLtX) { selNoLockObjLtX = obj_ptr->obbox.ltx; } if (obj_ptr->obbox.lty < selNoLockObjLtY) { selNoLockObjLtY = obj_ptr->obbox.lty; } if (obj_ptr->obbox.rbx > selNoLockObjRbX) { selNoLockObjRbX = obj_ptr->obbox.rbx; } if (obj_ptr->obbox.rby > selNoLockObjRbY) { selNoLockObjRbY = obj_ptr->obbox.rby; } } else { SetNoLockBBox(obj_ptr); seen_no_locked = TRUE; } } } } static struct VSelRec *SelectOneVertex(XOff, YOff) int XOff, YOff; /* XOff and YOff are screen offsets */ { register struct ObjRec *obj_ptr; int v_index, x, y; JustRemoveAllVSel(); if ((obj_ptr=FindAVertex(XOff, YOff, &v_index, &x, &y)) == NULL) { return NULL; } topVSel = (struct VSelRec *)malloc(sizeof(struct VSelRec)); if (topVSel == NULL) FailAllocMessage(); memset(topVSel, 0, sizeof(struct VSelRec)); topVSel->obj = obj_ptr; topVSel->max_v = 10; topVSel->v_index = (int*)malloc(10*sizeof(int)); if (topVSel->v_index == NULL) FailAllocMessage(); topVSel->x = (int*)malloc(10*sizeof(int)); topVSel->y = (int*)malloc(10*sizeof(int)); if (topVSel->x == NULL || topVSel->y == NULL) FailAllocMessage(); topVSel->v_index[0] = v_index; topVSel->x[0] = x; topVSel->y[0] = y; if (obj_ptr->type==OBJ_POLYGON && v_index==0) { topVSel->n = 2; topVSel->v_index[1] = obj_ptr->detail.g->n-1; topVSel->x[1] = x; topVSel->y[1] = y; } else { topVSel->n = 1; } topVSel->next = NULL; topVSel->prev = NULL; botVSel = topVSel; UpdSelBBox(); return topVSel; } static struct SelRec *SelectOneObj(XOff, YOff, ppInnerObj) int XOff, YOff; struct ObjRec **ppInnerObj; /* XOff and YOff are screen offsets */ { register struct ObjRec *obj_ptr; struct ObjRec *owner_obj; RemoveAllSel(); if ((obj_ptr=FindAnObj(XOff,YOff,&owner_obj,NULL,NULL)) == NULL) { return NULL; } if (ppInnerObj != NULL) { *ppInnerObj = (owner_obj==NULL ? NULL : obj_ptr); } if (owner_obj != NULL) obj_ptr = owner_obj; topSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->next = NULL; topSel->obj = obj_ptr; topSel->prev = NULL; botSel = topSel; UpdSelBBox(); return topSel; } static int FindVertices(X1, Y1, X2, Y2, TopVSel, BotVSel, pn_struct_spline_msg) int X1, Y1, X2, Y2, *pn_struct_spline_msg; struct VSelRec **TopVSel, **BotVSel; /* X1, Y1, X2, Y2 are absolute coordinates */ { struct SelRec *sel_ptr=NULL; struct BBRec bbox; *TopVSel = *BotVSel = NULL; bbox.ltx = X1; bbox.lty = Y1; bbox.rbx = X2; bbox.rby = Y2; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { int i=0, n=0, count=0, max_count=0, j=0, curved=(-1); IntPoint *v=NULL; struct ObjRec *obj_ptr=sel_ptr->obj; if (obj_ptr->type != OBJ_POLY && obj_ptr->type != OBJ_POLYGON) continue; if (!BBoxIntersect(bbox, obj_ptr->bbox)) continue; switch (obj_ptr->type) { case OBJ_POLY: curved = obj_ptr->detail.p->curved; if (curved == LT_STRUCT_SPLINE) { n = obj_ptr->detail.p->ssn; v = obj_ptr->detail.p->ssvlist; } else { n = obj_ptr->detail.p->n; v = obj_ptr->detail.p->vlist; } break; case OBJ_POLYGON: curved = obj_ptr->detail.g->curved; if (curved == LT_STRUCT_SPLINE) { n = obj_ptr->detail.g->ssn; v = obj_ptr->detail.g->ssvlist; } else { n = obj_ptr->detail.g->n; v = obj_ptr->detail.g->vlist; } break; } if (obj_ptr->ctm == NULL) { for (i = 0, count = 0; i < n; i++) { if (v[i].x >= X1 && v[i].x <= X2 && v[i].y >= Y1 && v[i].y <= Y2) { count++; } } } else { for (i = 0, count = 0; i < n; i++) { int x, y; TransformPointThroughCTM(v[i].x-obj_ptr->x, v[i].y-obj_ptr->y, obj_ptr->ctm, &x, &y); if (x+obj_ptr->x >= X1 && x+obj_ptr->x <= X2 && y+obj_ptr->y >= Y1 && y+obj_ptr->y <= Y2) { count++; } } } if (count != 0) { struct VSelRec *vsel_ptr=NULL; if (curved == LT_STRUCT_SPLINE && count > 1) { if (!(*pn_struct_spline_msg)) { *pn_struct_spline_msg = TRUE; Msg(TgLoadString(STID_ONE_V_STRUCT_SPLINE_IN_V_MODE)); } count = 1; } vsel_ptr = (struct VSelRec *)malloc(sizeof(struct VSelRec)); if (vsel_ptr == NULL) FailAllocMessage(); memset(vsel_ptr, 0, sizeof(struct VSelRec)); vsel_ptr->obj = obj_ptr; vsel_ptr->next = *TopVSel; vsel_ptr->prev = NULL; if (*TopVSel == NULL) { *BotVSel = vsel_ptr; } else { (*TopVSel)->prev = vsel_ptr; } *TopVSel = vsel_ptr; vsel_ptr->n = count; max_count = ((count%10) == 0) ? 10*((int)(count/10)) : 10*((int)(count/10)+1); vsel_ptr->max_v = max_count; vsel_ptr->v_index = (int*)malloc(max_count*sizeof(int)); if (vsel_ptr->v_index == NULL) FailAllocMessage(); vsel_ptr->x = (int*)malloc(max_count*sizeof(int)); vsel_ptr->y = (int*)malloc(max_count*sizeof(int)); if (vsel_ptr->x == NULL || vsel_ptr->y == NULL) FailAllocMessage(); if (obj_ptr->ctm == NULL) { for (i = 0, j = 0; i < n; i++) { if (v[i].x >= X1 && v[i].x <= X2 && v[i].y >= Y1 && v[i].y <= Y2) { vsel_ptr->v_index[j] = i; vsel_ptr->x[j] = v[i].x; vsel_ptr->y[j] = v[i].y; j++; } } } else { for (i = 0, j = 0; i < n; i++) { int x, y; TransformPointThroughCTM(v[i].x-obj_ptr->x, v[i].y-obj_ptr->y, obj_ptr->ctm, &x, &y); if (x+obj_ptr->x >= X1 && x+obj_ptr->x <= X2 && y+obj_ptr->y >= Y1 && y+obj_ptr->y <= Y2) { vsel_ptr->v_index[j] = i; vsel_ptr->x[j] = x+obj_ptr->x; vsel_ptr->y[j] = y+obj_ptr->y; j++; } } } } } return (*TopVSel != NULL); } static struct SelRec *FindObjects(X1, Y1, X2, Y2, TopSel, BotSel) int X1, Y1, X2, Y2; struct SelRec **TopSel, **BotSel; /* X1, Y1, X2, Y2 are absolute coordinates */ { struct ObjRec *obj_ptr=NULL; *TopSel = *BotSel = NULL; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (colorLayers && !ObjInVisibleLayer(obj_ptr)) { continue; } if (X1 <= obj_ptr->bbox.ltx && X2 >= obj_ptr->bbox.rbx && Y1 <= obj_ptr->bbox.lty && Y2 >= obj_ptr->bbox.rby) { AddObjIntoSel(obj_ptr, NULL, *TopSel, TopSel, BotSel); } } return (*TopSel); } void SelBox(window, gc, x1, y1, x2, y2) Window window; GC gc; int x1, y1, x2, y2; { XPoint sv[5]; if (x1 == x2 || y1 == y2) { XDrawLine(mainDisplay, window, gc, x1, y1, x2, y2); } else { sv[0].x = (short)x1; sv[0].y = (short)y1; sv[1].x = (short)x1; sv[1].y = (short)y2; sv[2].x = (short)x2; sv[2].y = (short)y2; sv[3].x = (short)x2; sv[3].y = (short)y1; sv[4].x = (short)x1; sv[4].y = (short)y1; XDrawLines(mainDisplay, window, gc, sv, 5, CoordModeOrigin); } } static struct ObjRec *PtInObjList(XOff, YOff, FirstObjPtr) int XOff, YOff; struct ObjRec *FirstObjPtr; /* XOff and YOff are screen offsets */ { register struct ObjRec *obj_ptr, *obj_ptr1; register struct AttrRec *attr_ptr; for (obj_ptr=FirstObjPtr; obj_ptr != NULL; obj_ptr=obj_ptr->next) { for (attr_ptr=obj_ptr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown && XOff >= OFFSET_X(attr_ptr->obj->bbox.ltx)-3 && YOff >= OFFSET_Y(attr_ptr->obj->bbox.lty)-3 && XOff <= OFFSET_X(attr_ptr->obj->bbox.rbx)+3 && YOff <= OFFSET_Y(attr_ptr->obj->bbox.rby)+3) { return attr_ptr->obj; } } if (XOff >= OFFSET_X(obj_ptr->bbox.ltx)-3 && YOff >= OFFSET_Y(obj_ptr->bbox.lty)-3 && XOff <= OFFSET_X(obj_ptr->bbox.rbx)+3 && YOff <= OFFSET_Y(obj_ptr->bbox.rby)+3) { switch (obj_ptr->type) { case OBJ_TEXT: if (FindGoodText(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_XBM: if (FindGoodXBm(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_XPM: if (FindGoodXPm(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_BOX: if (FindGoodBox(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_OVAL: if (FindGoodOval(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_POLY: if (FindGoodPoly(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_POLYGON: if (FindGoodPolygon(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_ARC: if (FindGoodArc(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_RCBOX: if (FindGoodRCBox(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: obj_ptr1 = PtInObjList(XOff, YOff, obj_ptr->detail.r->first); if (obj_ptr1 != NULL) return obj_ptr1; break; case OBJ_PIN: obj_ptr1 = PtInObjList(XOff, YOff, GetPinObj(obj_ptr)->detail.r->first); if (obj_ptr1 != NULL) return obj_ptr1; break; } } } return NULL; } static struct ObjRec *PtInSelected(XOff, YOff) int XOff, YOff; /* XOff and YOff are screen offsets */ { register struct SelRec *sel_ptr; register struct ObjRec *obj_ptr, *obj_ptr1; register struct AttrRec *attr_ptr; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; for (attr_ptr=obj_ptr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown && XOff >= OFFSET_X(attr_ptr->obj->bbox.ltx)-3 && YOff >= OFFSET_Y(attr_ptr->obj->bbox.lty)-3 && XOff <= OFFSET_X(attr_ptr->obj->bbox.rbx)+3 && YOff <= OFFSET_Y(attr_ptr->obj->bbox.rby)+3) { return attr_ptr->obj; } } if (XOff >= OFFSET_X(obj_ptr->bbox.ltx)-3 && YOff >= OFFSET_Y(obj_ptr->bbox.lty)-3 && XOff <= OFFSET_X(obj_ptr->bbox.rbx)+3 && YOff <= OFFSET_Y(obj_ptr->bbox.rby)+3) { switch (obj_ptr->type) { case OBJ_TEXT: if (FindGoodText(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_XBM: if (FindGoodXBm(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_XPM: if (FindGoodXPm(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_BOX: if (FindGoodBox(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_OVAL: if (FindGoodOval(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_POLY: if (FindGoodPoly(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_POLYGON: if (FindGoodPolygon(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_ARC: if (FindGoodArc(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_RCBOX: if (FindGoodRCBox(XOff,YOff,obj_ptr)) return obj_ptr; break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: obj_ptr1 = PtInObjList(XOff, YOff, obj_ptr->detail.r->first); if (obj_ptr1 != NULL) return obj_ptr1; break; case OBJ_PIN: obj_ptr1 = PtInObjList(XOff, YOff, GetPinObj(obj_ptr)->detail.r->first); if (obj_ptr1 != NULL) return obj_ptr1; break; } } } return NULL; } static void ToggleVertexSelection(ObjPtr, VIndex, AbsX, AbsY, pn_struct_spline_msg) struct ObjRec *ObjPtr; int VIndex, AbsX, AbsY, *pn_struct_spline_msg; { int i, j, n=0, curved=(-1), last_polygon_vertex=FALSE; struct VSelRec *vsel_ptr=NULL; char *smooth=NULL; switch (ObjPtr->type) { case OBJ_POLY: curved = ObjPtr->detail.p->curved; if (curved == LT_STRUCT_SPLINE) { smooth = ObjPtr->detail.p->ssmooth; } else { smooth = ObjPtr->detail.p->smooth; } break; case OBJ_POLYGON: curved = ObjPtr->detail.g->curved; if (curved == LT_STRUCT_SPLINE) { smooth = ObjPtr->detail.g->ssmooth; if (VIndex == ObjPtr->detail.g->ssn-1) { last_polygon_vertex = TRUE; } } else { smooth = ObjPtr->detail.g->smooth; if (VIndex == ObjPtr->detail.g->n-1) { last_polygon_vertex = TRUE; } } break; } if (VertexAlreadySelected(ObjPtr, VIndex, &vsel_ptr)) { /* de-select a vertex */ if (vsel_ptr->n == 1) { if (vsel_ptr->prev == NULL) { topVSel = vsel_ptr->next; } else { vsel_ptr->prev->next = vsel_ptr->next; } if (vsel_ptr->next == NULL) { botVSel = vsel_ptr->prev; } else { vsel_ptr->next->prev = vsel_ptr->prev; } free(vsel_ptr->v_index); free(vsel_ptr->x); free(vsel_ptr->y); free(vsel_ptr); } else { for (j = 0; j < vsel_ptr->n; j++) { if (vsel_ptr->v_index[j] == VIndex) { break; } } if (j > vsel_ptr->n) { sprintf(gszMsgBox, TgLoadString(STID_INCONSIS_VERTEX_SEL_IN_FUNC), "ToggleVertexSelection()"); TgAssert(FALSE, gszMsgBox, NULL); } for (i=j; i < vsel_ptr->n-1; i++) { vsel_ptr->v_index[i] = vsel_ptr->v_index[i+1]; vsel_ptr->x[i] = vsel_ptr->x[i+1]; vsel_ptr->y[i] = vsel_ptr->y[i+1]; } vsel_ptr->n--; } } else { if (vsel_ptr == NULL) { /* a new object */ vsel_ptr = (struct VSelRec *)malloc(sizeof(struct VSelRec)); if (vsel_ptr == NULL) FailAllocMessage(); memset(vsel_ptr, 0, sizeof(struct VSelRec)); vsel_ptr->obj = ObjPtr; n = vsel_ptr->n = 1; vsel_ptr->max_v = 10; vsel_ptr->v_index = (int*)malloc(10*sizeof(int)); if (vsel_ptr->v_index == NULL) FailAllocMessage(); vsel_ptr->x = (int*)malloc(10*sizeof(int)); vsel_ptr->y = (int*)malloc(10*sizeof(int)); if (vsel_ptr->x == NULL || vsel_ptr->y == NULL) FailAllocMessage(); vsel_ptr->prev = NULL; vsel_ptr->next = topVSel; if (topVSel == NULL) { botVSel = vsel_ptr; } else { topVSel->prev = vsel_ptr; } topVSel = vsel_ptr; } else { if (!last_polygon_vertex && curved == LT_STRUCT_SPLINE) { if (!(*pn_struct_spline_msg)) { *pn_struct_spline_msg = TRUE; Msg(TgLoadString(STID_ONE_V_STRUCT_SPLINE_IN_V_MODE)); } return; } else { n = ++(vsel_ptr->n); if (n > vsel_ptr->max_v) { int max_v; vsel_ptr->max_v += 10; max_v = vsel_ptr->max_v; vsel_ptr->v_index = (int*)realloc(vsel_ptr->v_index, sizeof(int)*max_v); vsel_ptr->x = (int*)realloc(vsel_ptr->x, sizeof(int)*max_v); vsel_ptr->y = (int*)realloc(vsel_ptr->y, sizeof(int)*max_v); } } } vsel_ptr->v_index[n-1] = VIndex; vsel_ptr->x[n-1] = AbsX; vsel_ptr->y[n-1] = AbsY; } if (!last_polygon_vertex) { if (curved != LT_INTSPLINE && curved != (-1) && smooth != NULL) { if (smooth[VIndex]) { if (curved == LT_STRUCT_SPLINE) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(AbsX), OFFSET_Y(AbsY)); } else { MARKO(drawWindow, revDefaultGC, OFFSET_X(AbsX), OFFSET_Y(AbsY)); } } else { if (curved == LT_STRUCT_SPLINE) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(AbsX), OFFSET_Y(AbsY)); } else { MARK(drawWindow, revDefaultGC, OFFSET_X(AbsX), OFFSET_Y(AbsY)); } } } else { MARK(drawWindow, revDefaultGC, OFFSET_X(AbsX), OFFSET_Y(AbsY)); } MARKV(drawWindow, revDefaultGC, OFFSET_X(AbsX), OFFSET_Y(AbsY)); } } static void ToggleSelectedObjIfSelectedAlready(ObjPtr) register struct ObjRec *ObjPtr; { register struct SelRec *sel_ptr; if ((sel_ptr=AlreadySelected(ObjPtr)) != NULL) { /* de-select an object */ HighLightAnObj(ObjPtr); if (sel_ptr->prev == NULL) { topSel = sel_ptr->next; } else { sel_ptr->prev->next = sel_ptr->next; } if (sel_ptr->next == NULL) { botSel = sel_ptr->prev; } else { sel_ptr->next->prev = sel_ptr->prev; } free(sel_ptr); numObjSelected--; } else { /* add a newly selected object */ AddNewSelObj(ObjPtr); HighLightAnObj(ObjPtr); } } static void ContinueSel(XOff, YOff, ShiftKeyDown) int XOff, YOff, ShiftKeyDown; /* XOff and YOff are screen offsets, and they are not on grid */ { int i, end_x, end_y, v_index, new_end_x, new_end_y; int done=FALSE, ltx, lty, rbx, rby, dx, dy, x, y; int struct_spline_msg=FALSE; char buf[80], w_buf[80], h_buf[80], x_buf[80], y_buf[80]; XEvent input, ev; XMotionEvent *motion_ev=NULL; struct SelRec *sel_ptr=NULL, *top_sel_ptr=NULL, *bot_sel_ptr=NULL; struct VSelRec *vsel_ptr=NULL, *top_vsel_ptr=NULL, *bot_vsel_ptr=NULL; struct ObjRec *obj_ptr=NULL, *owner_obj=NULL; end_x = XOff; end_y = YOff; SelBox(drawWindow, revDefaultGC, XOff, YOff, end_x, end_y); PixelToMeasurementUnit(w_buf, 0); PixelToMeasurementUnit(h_buf, 0); PixelToMeasurementUnit(x_buf, ABS_X(end_x)); PixelToMeasurementUnit(y_buf, ABS_Y(end_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); StartShowMeasureCursor(end_x, end_y, buf, TRUE); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } while (!done) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(end_x-XOff))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(end_y-YOff))); PixelToMeasurementUnit(x_buf, ABS_X(end_x)); PixelToMeasurementUnit(y_buf, ABS_Y(end_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); EndShowMeasureCursor(end_x, end_y, buf, TRUE); SelBox(drawWindow, revDefaultGC, XOff, YOff, end_x, end_y); done = TRUE; } else if (input.type == MotionNotify) { motion_ev = &(input.xmotion); new_end_x = motion_ev->x; new_end_y = motion_ev->y; PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(end_x-XOff))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(end_y-YOff))); PixelToMeasurementUnit(x_buf, ABS_X(end_x)); PixelToMeasurementUnit(y_buf, ABS_Y(end_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); ShowMeasureCursor(end_x, end_y, buf, TRUE); SelBox(drawWindow, revDefaultGC, XOff, YOff, end_x, end_y); end_x = new_end_x; end_y = new_end_y; SelBox(drawWindow, revDefaultGC, XOff, YOff, end_x, end_y); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(end_x-XOff))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(end_y-YOff))); PixelToMeasurementUnit(x_buf, ABS_X(end_x)); PixelToMeasurementUnit(y_buf, ABS_Y(end_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); ShowMeasureCursor(end_x, end_y, buf, TRUE); MarkRulers(end_x, end_y); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } dx = abs(XOff - end_x); dy = abs(YOff - end_y); if (curChoice == VERTEXMODE) { if (dx <= 2 && dy <= 2) { if (topSel == NULL) { if (SelectOneObj(XOff, YOff, NULL) != NULL) { if ((topSel->obj->type == OBJ_POLY || topSel->obj->type == OBJ_POLYGON) && !topSel->obj->locked) { HighLightForward(); } else { RemoveAllSel(); } } } else if (ShiftKeyDown) { obj_ptr = FindAVertex(XOff, YOff, &v_index, &x, &y); if (obj_ptr != NULL) { ToggleVertexSelection(obj_ptr, v_index, x, y, &struct_spline_msg); if (obj_ptr->type==OBJ_POLYGON && v_index==0) { if (obj_ptr->detail.g->curved == LT_STRUCT_SPLINE) { ToggleVertexSelection(obj_ptr,obj_ptr->detail.g->ssn-1, x, y, &struct_spline_msg); } else { ToggleVertexSelection(obj_ptr,obj_ptr->detail.g->n-1, x, y, &struct_spline_msg); } } UpdSelBBox(); } } else { HighLightReverse(); SelectOneVertex(XOff, YOff); HighLightForward(); } } else { CalcBBox(XOff, YOff, end_x, end_y, <x, <y, &rbx, &rby); if (topSel == NULL) { if (FindObjects(ABS_X(ltx), ABS_Y(lty), ABS_X(rbx), ABS_Y(rby), &top_sel_ptr, &bot_sel_ptr) != NULL) { topSel = top_sel_ptr; botSel = bot_sel_ptr; UnSelNonVertexObjs(FALSE, TRUE); /* do not highlight */ UpdSelBBox(); HighLightForward(); } } else if (ShiftKeyDown) { if (FindVertices(ABS_X(ltx), ABS_Y(lty), ABS_X(rbx), ABS_Y(rby), &top_vsel_ptr, &bot_vsel_ptr, &struct_spline_msg)) { struct VSelRec *next_vsel; for (vsel_ptr=top_vsel_ptr; vsel_ptr!=NULL; vsel_ptr=next_vsel) { obj_ptr = vsel_ptr->obj; for (i = 0; i < vsel_ptr->n; i++) { ToggleVertexSelection(obj_ptr, vsel_ptr->v_index[i], vsel_ptr->x[i], vsel_ptr->y[i], &struct_spline_msg); } next_vsel = vsel_ptr->next; free(vsel_ptr->v_index); free(vsel_ptr->x); free(vsel_ptr->y); free(vsel_ptr); } UpdSelBBox(); } } else { HighLightReverse(); JustRemoveAllVSel(); if (FindVertices(ABS_X(ltx), ABS_Y(lty), ABS_X(rbx), ABS_Y(rby), &top_vsel_ptr, &bot_vsel_ptr, &struct_spline_msg)) { topVSel = top_vsel_ptr; botVSel = bot_vsel_ptr; UpdSelBBox(); } HighLightForward(); } } } else { if (dx <= 2 && dy <= 2) { if (ShiftKeyDown) { obj_ptr = FindAnObj(XOff, YOff, &owner_obj, NULL, NULL); if (obj_ptr != NULL) { if (owner_obj != NULL) obj_ptr = owner_obj; ToggleSelectedObjIfSelectedAlready(obj_ptr); UpdSelBBox(); } } else { if (topSel != NULL) HighLightReverse(); if (SelectOneObj(XOff, YOff, NULL) != NULL) { HighLightForward(); } } } else { CalcBBox(XOff, YOff, end_x, end_y, <x, <y, &rbx, &rby); if (ShiftKeyDown) { if (FindObjects(ABS_X(ltx), ABS_Y(lty), ABS_X(rbx), ABS_Y(rby), &top_sel_ptr, &bot_sel_ptr) != NULL) { struct SelRec *next_sel; for (sel_ptr=top_sel_ptr; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; obj_ptr = sel_ptr->obj; ToggleSelectedObjIfSelectedAlready(obj_ptr); free(sel_ptr); } UpdSelBBox(); } } else { if (topSel != NULL) HighLightReverse(); RemoveAllSel(); if (FindObjects(ABS_X(ltx), ABS_Y(lty), ABS_X(rbx), ABS_Y(rby), &top_sel_ptr, &bot_sel_ptr) != NULL) { topSel = top_sel_ptr; botSel = bot_sel_ptr; UpdSelBBox(); HighLightForward(); } } } } } static XComposeStatus c_stat; static void KeyPressInSelect(key_ev) XKeyEvent *key_ev; { XButtonEvent button_ev; char s[80]; KeySym key_sym; int delta, dx=0, dy=0, has_ch=FALSE; has_ch = XLookupString(key_ev, s, sizeof(s), &key_sym, &c_stat); TranslateKeys(s, &key_sym); if (inSlideShow) { if (CharIsESC(key_ev, s, key_sym, &has_ch)) { LeaveSlideShow(); return; } switch (key_sym) { case XK_Left: PrevSlide(); return; case XK_KP_Left: PrevSlide(); return; case XK_Up: PrevSlide(); return; case XK_KP_Up: PrevSlide(); return; case XK_Right: NextSlide(); return; case XK_KP_Right: NextSlide(); return; case XK_Down: NextSlide(); return; case XK_KP_Down: NextSlide(); return; default: break; } } button_ev.state = ShiftMask; if (key_sym == XK_Page_Up || key_sym == XK_KP_Page_Up) { ScrollUp(&button_ev); } else if (key_sym == XK_Page_Down || key_sym == XK_KP_Page_Down) { ScrollDown(&button_ev); } if (topSel==NULL && topVSel==NULL) { if (key_ev->state & ControlMask) { switch (key_sym) { case XK_Left: ScrollLeft(&button_ev); break; case XK_KP_Left: ScrollLeft(&button_ev); break; case XK_Up: ScrollUp(&button_ev); break; case XK_KP_Up: ScrollUp(&button_ev); break; case XK_Right: ScrollRight(&button_ev); break; case XK_KP_Right: ScrollRight(&button_ev); break; case XK_Down: ScrollDown(&button_ev); break; case XK_KP_Down: ScrollDown(&button_ev); break; } } else { switch (key_sym) { case XK_Left: ScrollLeft(NULL); break; case XK_KP_Left: ScrollLeft(NULL); break; case XK_Up: ScrollUp(NULL); break; case XK_KP_Up: ScrollUp(NULL); break; case XK_Right: ScrollRight(NULL); break; case XK_KP_Right: ScrollRight(NULL); break; case XK_Down: ScrollDown(NULL); break; case XK_KP_Down: ScrollDown(NULL); break; } } return; } if (CharIsDEL(key_ev, s, key_sym, &has_ch)) { DelAllSelObj(); } if (key_sym!=XK_Left && key_sym!=XK_Up && key_sym!=XK_Right && key_sym!=XK_Down && key_sym!=XK_KP_Left && key_sym!=XK_KP_Up && key_sym!=XK_KP_Right && key_sym!=XK_KP_Down) { return; } if (snapOn) { delta = (gridSystem==ENGLISH_GRID) ? GRID_ABS_SIZE(xyEnglishGrid) : GRID_ABS_SIZE(xyMetricGrid); } else { delta = GRID_ABS_SIZE(1); } HighLightReverse(); switch (key_sym) { case XK_Left: dx = -delta; dy = 0; break; case XK_KP_Left: dx = -delta; dy = 0; break; case XK_Up: dx = 0; dy = -delta; break; case XK_KP_Up: dx = 0; dy = -delta; break; case XK_Right: dx = delta; dy = 0; break; case XK_KP_Right: dx = delta; dy = 0; break; case XK_Down: dx = 0; dy = delta; break; case XK_KP_Down: dx = 0; dy = delta; break; } if (curChoice == VERTEXMODE) { MoveAllSelVs(dx, dy); } else if (numObjSelected == numObjLocked) { HighLightForward(); return; } else { MoveAllSel(dx, dy); } HighLightForward(); UpdSelBBox(); if (justDupped) { dupDx += dx; dupDy += dy; } SetFileModified(TRUE); } static int PtInObjAboveSelected(XOff, YOff) int XOff, YOff; /* * returns TRUE if there is an object under the mouse that's above all the * selected objects -- in this case, that object should be selected */ { struct ObjRec *obj_ptr=NULL, *owner_obj=NULL, *found_obj=NULL; found_obj = FindAnObj(XOff, YOff, &owner_obj, NULL, NULL); if (found_obj == NULL) { /* no object under the cursor */ return FALSE; } if (owner_obj != NULL) found_obj = owner_obj; if (topSel == NULL) { return TRUE; } for (obj_ptr=topObj; obj_ptr != NULL && obj_ptr != topSel->obj; obj_ptr=obj_ptr->next) { if (obj_ptr == found_obj) { return TRUE; } } return FALSE; } void Select(input) XEvent *input; { register int i; XButtonEvent *button_ev; struct SelRec *sel_ptr; struct VSelRec *vsel_ptr; struct ObjRec *obj_ptr; Time click_time; if (input->type == KeyPress) { KeyPressInSelect(&(input->xkey)); return; } else if (input->type != ButtonPress) { return; } button_ev = &(input->xbutton); if (button_ev->button == Button1) { static Time sSelectLastClickTime=(Time)0; static int snSelectJustClicked=FALSE; int mouse_x, mouse_y, grid_x, grid_y, corner; mouse_x = button_ev->x; mouse_y = button_ev->y; GridXY(mouse_x, mouse_y, &grid_x, &grid_y); click_time = button_ev->time; if (curChoice==VERTEXMODE && topSel!=NULL && snSelectJustClicked && (click_time-sSelectLastClickTime) < doubleClickInterval) { snSelectJustClicked = FALSE; HighLightReverse(); RemoveAllSel(); return; } else if (curChoice==NOTHING && topSel!=NULL && snSelectJustClicked && (click_time-sSelectLastClickTime) < doubleClickInterval) { snSelectJustClicked = FALSE; Teleport(button_ev); return; } snSelectJustClicked = TRUE; sSelectLastClickTime = click_time; if (button_ev->state & (ShiftMask | ControlMask)) { ContinueSel(mouse_x, mouse_y, TRUE); justDupped = FALSE; return; } else if (curChoice == VERTEXMODE && topVSel != NULL) { int found=FALSE; for (vsel_ptr=topVSel; vsel_ptr!=NULL && !found; vsel_ptr=vsel_ptr->next) { for (i = 0; i < vsel_ptr->n; i++) { if (PtInMark(mouse_x, mouse_y, OFFSET_X(vsel_ptr->x[i]), OFFSET_Y(vsel_ptr->y[i]))) { found = TRUE; break; } } } if (found) { MoveSelVs(grid_x, grid_y); return; } } else if (curChoice == NOTHING) { struct ObjRec *inner_obj=NULL; if (topSel != NULL) { if (oneMotionSelectMove && PtInSelMark(mouse_x, mouse_y, &corner) == NULL && PtInSelected(mouse_x, mouse_y) == NULL) { /* may be pointing in not already selected object */ HighLightReverse(); RemoveAllSel(); if (SelectOneObj(mouse_x, mouse_y, &inner_obj) != NULL) { HighLightForward(); MoveSel(grid_x, grid_y, (inner_obj==NULL ? topSel->obj : inner_obj), button_ev); return; } } else if ((sel_ptr=PtInSelMark(mouse_x,mouse_y,&corner)) != NULL) { StretchSel(grid_x, grid_y, sel_ptr->obj, corner); return; } else if (!PtInObjAboveSelected(mouse_x, mouse_y) && (obj_ptr=PtInSelected(mouse_x, mouse_y)) != NULL) { MoveSel(grid_x, grid_y, obj_ptr, button_ev); return; } } else if (oneMotionSelectMove && SelectOneObj(mouse_x, mouse_y, &inner_obj) != NULL) { HighLightForward(); MoveSel(grid_x, grid_y, (inner_obj==NULL ? topSel->obj : inner_obj), button_ev); return; } } else if (curChoice == ROTATEMODE && topSel != NULL) { if ((sel_ptr=PtInSelMark(mouse_x, mouse_y, &corner)) != NULL) { RotateShearSel(grid_x, grid_y, sel_ptr->obj, corner); return; } if (!autoRotatePivot && PtInRotatePivot(mouse_x, mouse_y)) { ContinueMoveRotatePivot(grid_x, grid_y); return; } } ContinueSel(mouse_x, mouse_y, FALSE); justDupped = FALSE; } } struct AttrRec *FindFileAttrWithName(AttrName) char *AttrName; { struct AttrRec *attr_ptr, *found_attr=NULL; int count=1, compare_name=(strchr(AttrName,'=') != NULL); if (tgifObj == NULL) return NULL; for (attr_ptr=tgifObj->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (compare_name) { if (strcmp(attr_ptr->attr_name.s, AttrName) == 0) { found_attr = attr_ptr; break; } } else { if (strcmp(attr_ptr->attr_value.s, AttrName) == 0) { found_attr = attr_ptr; break; } } } if (attr_ptr == NULL) return NULL; if (GetTextObjFirstStrSeg(found_attr->obj)->color == colorIndex) { return found_attr; } for (attr_ptr=found_attr->next; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (compare_name) { if (strcmp(attr_ptr->attr_name.s, AttrName) == 0) { if (GetTextObjFirstStrSeg(attr_ptr->obj)->color == colorIndex) { break; } else { count++; } } } else { if (strcmp(attr_ptr->attr_value.s, AttrName) == 0) { if (GetTextObjFirstStrSeg(attr_ptr->obj)->color == colorIndex) { break; } else { count++; } } } } if (attr_ptr != NULL) { found_attr = attr_ptr; } else if (count != 1) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANT_FIND_FILEATTR_WITH_COLOR), AttrName, colorMenuItems[colorIndex]); Msg(gszMsgBox); return NULL; } return found_attr; } struct AttrRec *FindAttrWithName(ObjPtr, AttrName, pp_top_owner) struct ObjRec *ObjPtr, **pp_top_owner; char *AttrName; { struct ObjRec *obj_ptr=NULL; char *dot_ptr=NULL; if (AttrName[0] == '!' && AttrName[1] == '*') { if (topSel == NULL) { return NULL; } if (pp_top_owner != NULL) *pp_top_owner = topSel->obj; return FindObjAttrWithName(topSel->obj, &AttrName[2]); } if ((dot_ptr=strchr(AttrName, '.')) == NULL) { if (pp_top_owner != NULL) *pp_top_owner = ObjPtr; return FindObjAttrWithName(ObjPtr, AttrName); } *dot_ptr = '\0'; if (strcmp(AttrName, "!") == 0) { *dot_ptr++ = '.'; if (pp_top_owner != NULL) *pp_top_owner = tgifObj; return FindFileAttrWithName(dot_ptr); } if (AttrName[0] == '#' && AttrName[1] == '#') { int obj_page_num=0; char *bang_ptr=strchr(&AttrName[2], '!'); if (bang_ptr == NULL) { *dot_ptr = '.'; return NULL; } *bang_ptr = '\0'; if (sscanf(&AttrName[2], "%d", &obj_page_num) != 1) { *bang_ptr = '!'; *dot_ptr = '.'; return NULL; } if (obj_page_num < 1 || obj_page_num > lastPageNum) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PAGE_NUM), &AttrName[2]), MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *bang_ptr = '!'; *dot_ptr = '.'; return NULL; } *bang_ptr = '!'; if (curPageNum == obj_page_num) { if ((obj_ptr=FindObjWithName(botObj, ObjPtr, bang_ptr, FALSE, FALSE, NULL, pp_top_owner)) == NULL) { *dot_ptr = '.'; return NULL; } } else { struct PageRec *page_ptr=NULL; int page_num=0; for (page_ptr=firstPage, page_num=1; page_ptr != NULL; page_ptr=page_ptr->next, page_num++) { if (page_num == obj_page_num) { struct PageRec *saved_cur_page_ptr=curPage; int saved_cur_page_num=curPageNum; curPageNum = page_num; curPage = page_ptr; topObj = curPage->top; botObj = curPage->bot; obj_ptr = FindObjWithName(botObj, NULL, bang_ptr, FALSE, FALSE, NULL, NULL); curPageNum = saved_cur_page_num; curPage = saved_cur_page_ptr; topObj = curPage->top; botObj = curPage->bot; if (obj_ptr == NULL) { *dot_ptr = '.'; return NULL; } break; } } if (page_ptr == NULL) { *dot_ptr++ = '.'; return NULL; } } } else { if ((obj_ptr=FindObjWithName(botObj, ObjPtr, AttrName, FALSE, FALSE, NULL, pp_top_owner)) == NULL) { *dot_ptr++ = '.'; return NULL; } } *dot_ptr++ = '.'; return FindObjAttrWithName(obj_ptr, dot_ptr); } struct AttrRec *ValidAttrArg(c_ptr, obj_ptr, new_c_ptr) char *c_ptr, **new_c_ptr; struct ObjRec *obj_ptr; { char name[MAXSTRING+1], *name_ptr; struct AttrRec *attr_ptr; name_ptr = name; if (c_ptr[0] == '$' && c_ptr[1] == '(') { for (c_ptr = &c_ptr[2]; *c_ptr != '\0'; c_ptr++) { switch (*c_ptr) { case '\\': c_ptr++; *name_ptr++ = *c_ptr; break; case ')': *name_ptr++ = '='; *name_ptr = '\0'; *new_c_ptr = c_ptr; attr_ptr = FindAttrWithName(obj_ptr, name, NULL); if (attr_ptr == NULL) { char msg[MAXSTRING+1]; sprintf(msg, TgLoadCachedString(CSTID_CANT_FIND_NAMED_ATTR), name); Msg(msg); } return attr_ptr; default: *name_ptr++ = *c_ptr; break; } } } return NULL; } int DoTeleport(teleport_attr) struct AttrRec *teleport_attr; { char file_name[MAXPATHLENGTH+1], msg[MAXSTRING+1], *page_spec=NULL; char *dest_ptr=NULL; int do_not_save=FALSE, rc=TRUE, just_goto_page=FALSE, referer_set=FALSE; while (!DirIsRemote(curDir) && fileModified && !IsFiletUnSavable()) { XBell(mainDisplay, 0); switch (MsgBox(TgLoadString(STID_FILE_MOD_SAVE_BEFORE_OPEN), TOOL_NAME, YNC_MB)) { case MB_ID_YES: SaveFile(); break; case MB_ID_NO: do_not_save = TRUE; SetFileModified(FALSE); break; case MB_ID_CANCEL: return FALSE; } } if (!DirIsRemote(curDir) && fileModified && IsFiletUnSavable()) { do_not_save = TRUE; SetFileModified(FALSE); } if (!FormNewFileName(curDir, teleport_attr->attr_value.s, (strcmp(teleport_attr->attr_name.s,TELEPORT_ATTR)==0 ? OBJ_FILE_EXT : NULL), file_name, &page_spec)) { sprintf(msg, TgLoadString(STID_INVALID_NAMED_TELEPORT_DEST), teleport_attr->attr_value.s); MsgBox(msg, TOOL_NAME, INFO_MB); if (do_not_save) SetFileModified(TRUE); rc = FALSE; } if (*teleport_attr->attr_value.s == '#') just_goto_page = TRUE; if (rc && page_spec != NULL && just_goto_page) { int new_page_num=(-1); if (!GetPageNumFromPageSpec(page_spec, &new_page_num)) { sprintf(msg, TgLoadString(STID_INVALID_NAMED_TELEPORT_DEST), teleport_attr->attr_value.s); MsgBox(msg, TOOL_NAME, INFO_MB); if (do_not_save) SetFileModified(TRUE); rc = FALSE; } else if (new_page_num != curPageNum) { BeforeNavigate(); GotoPageNum(new_page_num); ShowPage(); ClearAndRedrawDrawWindow(); RedrawTitleWindow(); RedrawRulers(); RedrawScrollBars(); CleanUpCmds(); CommitNavigate(); justDupped = FALSE; } if (page_spec != NULL) free(page_spec); return rc; } if (!rc) { if (page_spec != NULL) free(page_spec); return rc; } MakeQuiescent(); if (curFileDefined) { referer_set = TRUE; if (*curSymDir == '\0') { sprintf(gszMsgBox, "%s%c%s", curDir, DIR_SEP, curFileName); } else { sprintf(gszMsgBox, "%s%c%s", curSymDir, DIR_SEP, curFileName); } HttpSetReferer(gszMsgBox); } dest_ptr = UtilStrDup(teleport_attr->attr_value.s); if (dest_ptr == NULL) FailAllocMessage(); if (FileIsRemote(file_name)) { char *buf=NULL, *content_type=NULL, final_url[MAXPATHLENGTH+1]; int buf_sz=0, is_html=FALSE; *final_url = '\0'; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); rc = LoadRemoteFileInMem(file_name, &buf, &content_type, &buf_sz, &is_html, FALSE, final_url, sizeof(final_url)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (rc && buf != NULL) { if (*final_url != '\0') { UtilStrCpyN(file_name, sizeof(file_name), final_url); } LoadRemoteFileFromMem(file_name, buf, content_type, buf_sz, is_html); } else { if (do_not_save) SetFileModified(TRUE); rc = FALSE; } if (content_type != NULL) FreeRemoteBuf(content_type); if (buf != NULL) FreeRemoteBuf(buf); } else { int obj_file=FALSE, gzipped=FALSE; FILE *fp=fopen(file_name, "r"); if (fp == NULL) { sprintf(gszMsgBox, TgLoadString(STID_Q_FILE_NOT_EXIST_CREATE), file_name); switch (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB)) { case MB_ID_YES: MakeQuiescent(); SaveNewFile(TRUE, file_name); break; case MB_ID_NO: break; case MB_ID_CANCEL: if (do_not_save) SetFileModified(TRUE); rc = FALSE; break; } } else { fclose(fp); } obj_file = FileNameHasExtension(file_name, OBJ_FILE_TYPE, &gzipped, NULL); if (rc && !LoadFile(file_name, obj_file, obj_file && gzipped)) { if (do_not_save) SetFileModified(TRUE); rc = FALSE; } } /* At this point teleport_attr is no longer valid */ if (rc && page_spec != NULL && !just_goto_page) { int new_page_num=(-1); if (!GetPageNumFromPageSpec(page_spec, &new_page_num)) { sprintf(msg, TgLoadString(STID_INVALID_NAMED_TELEPORT_DEST), dest_ptr); MsgBox(msg, TOOL_NAME, INFO_MB); rc = FALSE; } else if (new_page_num != curPageNum) { /* * No need to call BeforeNavigate() here because either * LoadRemoteFileFromMem() is called (which calls LoadFile()) * or LoadFile() is called directly. */ GotoPageNum(new_page_num); ShowPage(); ClearAndRedrawDrawWindow(); RedrawTitleWindow(); RedrawRulers(); RedrawScrollBars(); justDupped = FALSE; } } if (dest_ptr != NULL) free(dest_ptr); if (page_spec != NULL) free(page_spec); if (referer_set) { HttpClearReferer(); } return rc; } #define DO_PAGE_BY_NUM 0 #define DO_PAGE_BY_NAME 1 int DoPageTeleport(teleport_attr, do_by_page_name) struct AttrRec *teleport_attr; int do_by_page_name; { int i, rc=TRUE; char msg[MAXSTRING+1]; if (do_by_page_name) { struct PageRec *page_ptr; for (i=1, page_ptr=firstPage; page_ptr!=NULL; page_ptr=page_ptr->next, i++) { if (page_ptr->name != NULL && strcmp(page_ptr->name, teleport_attr->attr_value.s) == 0) { if (curPageNum != i) SetCurPage(i); return TRUE; } } sprintf(msg, TgLoadString(STID_CANT_FIND_PAGE_NAMED_TO_TEL), teleport_attr->attr_value.s); MsgBox(msg, TOOL_NAME, INFO_MB); rc = FALSE; } else { i = atoi(teleport_attr->attr_value.s); if (i >= 1 && i <= lastPageNum) { if (curPageNum != i) SetCurPage(i); } else { sprintf(msg, TgLoadString(STID_CANT_FIND_PAGE_NUM_TO_TEL), i); MsgBox(msg, TOOL_NAME, INFO_MB); rc = FALSE; } } return rc; } static void ResetDeckIndices() { register struct ObjRec *obj_ptr; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: obj_ptr->detail.r->deck_index = (-1); break; default: break; } } } void DoExecLoop(obj_ptr, exec_attr) struct ObjRec *obj_ptr; struct AttrRec *exec_attr; { ResetExec(TRUE); while (exec_attr != NULL) { int saved_intr_check_interval=intrCheckInterval; int one_line_status=FALSE, exec_rc=TRUE, teleport_aborted=FALSE; int saved_history_depth=historyDepth; char status_buf[MAX_STATUS_BTNS+1][MAXSTRING+1]; MakeQuiescent(); intrCheckInterval = 1; ShowInterrupt(1); ResetDeckIndices(); SaveStatusStringsIntoBuf(status_buf, &one_line_status); if (cmdToExecAfterHyperJump != NULL) { free(cmdToExecAfterHyperJump); cmdToExecAfterHyperJump = NULL; } warpToAttr = NULL; execNavigateBack = FALSE; exec_rc = DoExec(exec_attr, obj_ptr); exec_attr = NULL; RemoveAllSel(); EndExecAnimate(); if (saved_history_depth != historyDepth) RestoreDefaultHistoryDepth(); if (exec_rc == TRUE && warpToAttr != NULL) { teleport_aborted = !DoTeleport(warpToAttr); } RestoreStatusStringsFromBuf(status_buf, one_line_status); while (HideInterrupt() > 0) ; intrCheckInterval = saved_intr_check_interval; if (exec_rc==TRUE && warpToAttr!=NULL && !teleport_aborted) { if (cmdToExecAfterHyperJump == NULL) { if ((exec_attr=FindFileAttrWithName("auto_exec=")) == NULL) { ResetExec(FALSE); return; } obj_ptr = NULL; continue; } else { exec_attr = FindAttrWithName(NULL, cmdToExecAfterHyperJump, &obj_ptr); if (exec_attr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_NAMED_ATTR_EXEC), cmdToExecAfterHyperJump, "hyperjump_then_exec"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ResetExec(FALSE); return; } continue; } } if (exec_rc==TRUE && execNavigateBack) { NavigateBack(); } ResetExec(FALSE); return; } TwoLineMsg(TgLoadCachedString(CSTID_CANT_FIND_INTERPRETABLE_ATTR), TgLoadCachedString(CSTID_NO_ACTION_TAKEN)); ResetExec(FALSE); } void Teleport(button_ev) XButtonEvent *button_ev; { struct AttrRec *teleport_attr, *launch_attr, *exec_attr; struct ObjRec *obj_ptr, *owner_obj; char buf[MAXSTRING+1]; int len; if ((obj_ptr=FindAnObj(button_ev->x,button_ev->y,&owner_obj,NULL,NULL)) == NULL) { if (inSlideShow) { NextSlide(); } return; } if (owner_obj != NULL) obj_ptr = owner_obj; teleport_attr = FindAttrWithName(obj_ptr, TELEPORT_ATTR, NULL); if (teleport_attr != NULL) { if (DoTeleport(teleport_attr)) { if ((exec_attr=FindFileAttrWithName("auto_exec=")) != NULL) { DoExecLoop(NULL, exec_attr); } } return; } teleport_attr = FindAttrWithName(obj_ptr, "href=", NULL); if (teleport_attr != NULL && *teleport_attr->attr_value.s != '\0') { if (DoTeleport(teleport_attr)) { if ((exec_attr=FindFileAttrWithName("auto_exec=")) != NULL) { DoExecLoop(NULL, exec_attr); } } return; } strcpy(buf, TELEPORT_ATTR); len = strlen(buf); if (buf[len-1] == '=') { sprintf(&buf[len-1], "_page#="); teleport_attr = FindAttrWithName(obj_ptr, buf, NULL); if (teleport_attr != NULL && *teleport_attr->attr_value.s != '\0') { DoPageTeleport(teleport_attr, DO_PAGE_BY_NUM); return; } sprintf(&buf[len-1], "_page="); teleport_attr = FindAttrWithName(obj_ptr, buf, NULL); if (teleport_attr != NULL && *teleport_attr->attr_value.s != '\0') { DoPageTeleport(teleport_attr, DO_PAGE_BY_NAME); return; } } launch_attr = FindAttrWithName(obj_ptr, LAUNCH_ATTR, NULL); if (launch_attr != NULL) { DoLaunch(launch_attr, obj_ptr); return; } exec_attr = FindAttrWithName(obj_ptr, EXEC_ATTR, NULL); if (exec_attr == NULL && inSlideShow) { NextSlide(); return; } DoExecLoop(obj_ptr, exec_attr); } void SelAllObj(high_light, ignore_slideshow) int high_light, ignore_slideshow; { struct ObjRec *obj_ptr=NULL; TieLooseEnds(); SetCurChoice(NOTHING); if (topSel != NULL) { HighLightReverse(); RemoveAllSel(); } if (inSlideShow && !ignore_slideshow) { SetCurChoice(curChoiceBeforeMakeQuiescent); return; } for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (colorLayers && !ObjInVisibleLayer(obj_ptr)) { continue; } AddObjIntoSel(obj_ptr, NULL, topSel, &topSel, &botSel); } UpdSelBBox(); if (high_light) HighLightForward(); justDupped = FALSE; } static struct ObjRec *tmpTopObj=NULL, *tmpBotObj=NULL; static void PushTmpObj(ObjPtr) struct ObjRec *ObjPtr; { ObjPtr->next = tmpTopObj; ObjPtr->prev = NULL; if (tmpBotObj == NULL) { tmpBotObj = ObjPtr; } else { tmpTopObj->prev = ObjPtr; } tmpTopObj = ObjPtr; } static void BreakSel() /* break off selected objects from the main stream objects */ /* when returns, tmpTopObj points to the top of the selected objects */ /* and tmpBotObj points to the bottom of the selected objects */ { struct SelRec *sel_ptr=NULL; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { UnlinkObj(sel_ptr->obj); PushTmpObj(sel_ptr->obj); } } void JustMoveSelToTop() { if (topSel == NULL) return; tmpTopObj = tmpBotObj = NULL; BreakSel(); tmpBotObj->next = topObj; if (topObj == NULL) { curPage->bot = botObj = tmpBotObj; } else { topObj->prev = tmpBotObj; } curPage->top = topObj = tmpTopObj; } void MoveSelToTop() { if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); JustMoveSelToTop(); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); } void MoveSelToBot() { if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); tmpTopObj = tmpBotObj = NULL; BreakSel(); tmpTopObj->prev = botObj; if (topObj == NULL) { curPage->top = topObj = tmpTopObj; } else { botObj->next = tmpTopObj; } curPage->bot = botObj = tmpBotObj; RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); } static void DeleteObjectInsteadOfVertex(obj_ptr) struct ObjRec *obj_ptr; { struct SelRec *sel_ptr=NULL, *saved_top_sel=NULL, *saved_bot_sel=NULL; for (sel_ptr=botSel; sel_ptr!=NULL; sel_ptr=sel_ptr->prev) { if (sel_ptr->obj == obj_ptr) { break; } } if (sel_ptr->prev == NULL) { topSel = sel_ptr->next; } else { sel_ptr->prev->next = sel_ptr->next; } if (sel_ptr->next == NULL) { botSel = sel_ptr->prev; } else { sel_ptr->next->prev = sel_ptr->prev; } saved_top_sel = topSel; saved_bot_sel = botSel; topSel = botSel = sel_ptr; sel_ptr->next = sel_ptr->prev = NULL; DelObj(obj_ptr); topSel = saved_top_sel; botSel = saved_bot_sel; free(sel_ptr); ChangeReplaceOneCmdToDeleteCmd(); } void DelAllSelObj() { struct ObjRec *obj_ptr=NULL; struct SelRec *sel_ptr=NULL; int j, i; struct VSelRec *vsel_ptr=NULL; IntPoint *vlist=NULL; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; int n=0; short *mark=NULL; if (topSel==NULL && topVSel==NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); if (curChoice == VERTEXMODE) { StartCompositeCmd(); for (vsel_ptr=botVSel; vsel_ptr!=NULL; vsel_ptr=vsel_ptr->prev) { int delete_it=FALSE, extra_vertex=FALSE, curved=(-1), ssn=0; char *smooth=NULL, *ssmooth=NULL; IntPoint *ssvlist=NULL; obj_ptr = vsel_ptr->obj; switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; curved = poly_ptr->curved; if (curved == LT_STRUCT_SPLINE) { ssvlist = poly_ptr->ssvlist; ssn = poly_ptr->ssn; ssmooth = poly_ptr->ssmooth; } else { vlist = poly_ptr->vlist; n = poly_ptr->n; smooth = poly_ptr->smooth; } if (vsel_ptr->n >= n-1) delete_it = TRUE; break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; curved = polygon_ptr->curved; if (curved == LT_STRUCT_SPLINE) { ssvlist = polygon_ptr->ssvlist; ssn = polygon_ptr->ssn; ssmooth = polygon_ptr->ssmooth; } else { vlist = polygon_ptr->vlist; n = polygon_ptr->n; smooth = polygon_ptr->smooth; } for (j=0; j < vsel_ptr->n; j++) { if (vsel_ptr->v_index[j] == 0) { extra_vertex = TRUE; break; } } if ((!extra_vertex && n-vsel_ptr->n <= 3) || (extra_vertex && n-vsel_ptr->n <= 2)) { delete_it = TRUE; } break; } if (curved == LT_STRUCT_SPLINE) { PrepareToReplaceAnObj(obj_ptr); if (DeleteStructuredSplinePoint(vsel_ptr->v_index[0], poly_ptr, polygon_ptr)) { AdjObjSplineVs(obj_ptr); if (poly_ptr != NULL) { UpdPolyBBox(obj_ptr, poly_ptr->n, poly_ptr->vlist); } else if (polygon_ptr != NULL) { UpdPolyBBox(obj_ptr, polygon_ptr->n, polygon_ptr->vlist); } AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); } else { /* delete the object */ DeleteObjectInsteadOfVertex(obj_ptr); } } else { PrepareToReplaceAnObj(obj_ptr); if (delete_it) { /* delete the object */ DeleteObjectInsteadOfVertex(obj_ptr); } else { mark = (short *)malloc(n*sizeof(short)); if (mark == NULL) FailAllocMessage(); for (j=0; j < n; j++) mark[j] = FALSE; for (j=0; j < vsel_ptr->n; j++) { mark[vsel_ptr->v_index[j]] = TRUE; } switch (obj_ptr->type) { case OBJ_POLY: for (i=n-1; i >= 0; i--) { if (mark[i]) { for (j=i+1; j < n; j++) { vlist[j-1] = vlist[j]; if (smooth != NULL) smooth[j-1] = smooth[j]; } if (smooth != NULL) { if (i == 0) { smooth[0] = FALSE; } else if (i == n-1) { smooth[n-2] = FALSE; } } n--; } } poly_ptr->n -= vsel_ptr->n; AdjObjSplineVs(obj_ptr); if (poly_ptr->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, poly_ptr->n, poly_ptr->vlist); } else { UpdPolyBBox(obj_ptr, poly_ptr->intn, poly_ptr->intvlist); } break; case OBJ_POLYGON: for (i=n-2; i >= 0; i--) { if (mark[i]) { for (j=i+1; j < n; j++) { vlist[j-1] = vlist[j]; if (smooth != NULL) smooth[j-1] = smooth[j]; } n--; if (smooth != NULL && i == 0) { smooth[n-1] = smooth[0]; } } } polygon_ptr->n -= vsel_ptr->n; if (extra_vertex) vlist[polygon_ptr->n++] = vlist[0]; AdjObjSplineVs(obj_ptr); if (polygon_ptr->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, polygon_ptr->n, polygon_ptr->vlist); } else { UpdPolyBBox(obj_ptr, polygon_ptr->intn, polygon_ptr->intvlist); } break; } free(mark); AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); } } } EndCompositeCmd(); JustRemoveAllVSel(); } else { struct SelRec *first_extra_poly_sel=NULL, *last_extra_poly_sel=NULL; struct BBRec extra_bbox; int extra_poly_count=0, delete_extra_poly=FALSE; delete_extra_poly = FindExtraPoly(topSel, botSel, &first_extra_poly_sel, &last_extra_poly_sel, &extra_poly_count, &extra_bbox); StartCompositeCmd(); PrepareToRecord(CMD_DELETE, topSel, botSel, numObjSelected); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { UnlinkObj(sel_ptr->obj); FreeObj(sel_ptr->obj); } RemoveAllSel(); RecordCmd(CMD_DELETE, NULL, NULL, NULL, 0); if (delete_extra_poly) { /* * Please note that FindExtraPoly() returns the poly in the * correct stacking order! */ PrepareToRecord(CMD_DELETE, first_extra_poly_sel, last_extra_poly_sel, extra_poly_count); for (sel_ptr=last_extra_poly_sel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { UnlinkObj(sel_ptr->obj); FreeObj(sel_ptr->obj); } JustFreeSel(first_extra_poly_sel, last_extra_poly_sel); RecordCmd(CMD_DELETE, NULL, NULL, NULL, 0); ExpandExtents(&extra_bbox, &selLtX, &selLtY, &selRbX, &selRbY); } EndCompositeCmd(); } RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } void GroupSingleObj(ForcePromoteAttrs) int ForcePromoteAttrs; { tmpTopObj = tmpBotObj = NULL; BreakSel(); CreateGroupObj(tmpTopObj, tmpBotObj); RemoveAllSel(); if (tmpTopObj == tmpBotObj && tmpTopObj->fattr != NULL && (ForcePromoteAttrs || !(tmpTopObj->type == OBJ_GROUP || tmpTopObj->type == OBJ_SYM || tmpTopObj->type == OBJ_ICON || tmpTopObj->type == OBJ_PIN))) { struct AttrRec *attr_ptr; topObj->fattr = tmpTopObj->fattr; topObj->lattr = tmpTopObj->lattr; tmpTopObj->fattr = tmpTopObj->lattr = NULL; for (attr_ptr=topObj->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { attr_ptr->owner = topObj; } } topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->obj = topObj; topSel->next = topSel->prev = NULL; numObjSelected = 1; } void GroupSelObj(highlight, record_cmd, redraw) int highlight, record_cmd, redraw; { if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (curChoice==VERTEXMODE && topSel!=NULL) { MsgBox(TgLoadString(STID_CANT_GROUP_IN_VERTEX_MODE), TOOL_NAME, INFO_MB); return; } if (topSel == botSel && topSel->obj->type != OBJ_POLY && topSel->obj->type != OBJ_POLYGON) { MsgBox(TgLoadString(STID_CANT_GROUP_SINGLE_OBJECT), TOOL_NAME, INFO_MB); return; } tmpTopObj = tmpBotObj = NULL; if (highlight) HighLightReverse(); if (record_cmd) PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); BreakSel(); CreateGroupObj(tmpTopObj, tmpBotObj); RemoveAllSel(); topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->obj = topObj; topSel->next = topSel->prev = NULL; UpdSelBBox(); if (record_cmd) RecordCmd(CMD_MANY_TO_ONE, NULL, topSel, botSel, 1); if (redraw) { RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } if (highlight) HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } void SelectTopObj() { if (topObj == NULL) return; topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->obj = topObj; topSel->next = topSel->prev = NULL; UpdSelBBox(); HighLightForward(); justDupped = FALSE; } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/stream.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000053630�11602233313�014433� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/stream.c,v 1.6 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_STREAM_C_ #include "tgifdefs.h" #include "dialog.e" #include "drawing.e" #include "file.e" #include "http.e" #include "import.e" #include "menu.e" #include "move.e" #include "msg.e" #include "navigate.e" #include "obj.e" #include "remote.e" #include "setup.e" #include "stream.e" #include "strtbl.e" #include "util.e" static int gnMultipartReplace=FALSE; static int gnPossibleMultipartReplace=TRUE; static int gnJustLF=0; static int gnHeaderLen=0; static int gnStartIndex=0; static int gnBoundaryLen=0; static char *gpszBoundary=NULL; static struct ObjRec *gpVideoObj=NULL; static char **gaszFilterForContentType=NULL; static int gnMaxStreamFilters=0; static void CleanUpFilter() { if (gaszFilterForContentType != NULL) { int i=0; for (i=0; i < (gnMaxStreamFilters<<1); i++) { UtilFree(gaszFilterForContentType[i]); UtilFree(gaszFilterForContentType[++i]); } free(gaszFilterForContentType); } gaszFilterForContentType = NULL; gnMaxStreamFilters = 0; } static void InitFilter() { char *c_ptr=NULL; int max_filters=0; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MaxStreamFilters")) != NULL) { max_filters = atoi(c_ptr); if (max_filters <= 0) { sprintf(gszMsgBox, TgLoadString(STID_BAD_XDEF_MUST_BE_GT_0), TOOL_NAME, "MaxStreamFilters", c_ptr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } gnMaxStreamFilters = 0; if (max_filters > 0) { int i=0; gaszFilterForContentType = (char**)malloc(((max_filters<<1)+1)*sizeof(char*)); if (gaszFilterForContentType == NULL) FailAllocMessage(); memset(gaszFilterForContentType, 0, ((max_filters<<1)+1)*sizeof(char*)); for (i=0; i < max_filters; i++) { char buf[80]; sprintf(buf, "StreamFilter%1d", i); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,buf)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_XDEF), TOOL_NAME, buf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); max_filters = i; break; } else { char *psz=strchr(c_ptr, ':'); int index=(i<<1); if (psz == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF), TOOL_NAME, buf, c_ptr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); max_filters = i; break; } *psz++ = '\0'; gaszFilterForContentType[index] = UtilStrDup(c_ptr); gaszFilterForContentType[index+1] = UtilStrDup(psz); if (gaszFilterForContentType[index] == NULL || gaszFilterForContentType[index+1] == NULL) { FailAllocMessage(); } UtilTrimBlanks(gaszFilterForContentType[index]); UtilTrimBlanks(gaszFilterForContentType[index+1]); } } if (max_filters == 0) { free(gaszFilterForContentType); gaszFilterForContentType = NULL; } } gnMaxStreamFilters = max_filters; } void CleanUpMime() { gnMultipartReplace = FALSE; gnPossibleMultipartReplace = TRUE; gnJustLF = gnHeaderLen = gnStartIndex = gnBoundaryLen = 0; UtilFree(gpszBoundary); gpszBoundary = NULL; if (gpVideoObj != NULL) { UnlinkObj(gpVideoObj); FreeObj(gpVideoObj); } gpVideoObj = NULL; CleanUpFilter(); } void InitMime() { gnMultipartReplace = FALSE; gnPossibleMultipartReplace = TRUE; gnJustLF = gnHeaderLen = gnStartIndex = gnBoundaryLen = 0; gpszBoundary = NULL; gpVideoObj = NULL; InitFilter(); } void ResetMultipartReplace(redraw) int redraw; { gnMultipartReplace = FALSE; gnPossibleMultipartReplace = TRUE; gnJustLF = gnHeaderLen = gnStartIndex = gnBoundaryLen = 0; UtilFree(gpszBoundary); gpszBoundary = NULL; if (gpVideoObj != NULL) { UnlinkObj(gpVideoObj); FreeObj(gpVideoObj); if (redraw) { ClearAndRedrawDrawWindow(); } } gpVideoObj = NULL; } int IsJustLF(buf) char *buf; { char *first_lf=strchr(buf, '\n'); if (first_lf == NULL) return TRUE; if (first_lf == buf) return TRUE; --first_lf; return (*first_lf != '\r'); } char *GetHeaderLine(psz_start, just_lf) char *psz_start; int just_lf; { if (just_lf) { return strchr(psz_start, '\n'); } else { return strstr(psz_start, "\r\n"); } } static char *gppszValidMultipartReplace[] = { "multipart/x-mixed-replace", /* only knows about JPEG movie */ NULL }; static int ValidMultipartReplace(buf, pn_multipart) char *buf; int *pn_multipart; { char *psz=NULL, *psz_copy=UtilStrDup(buf); char **ppsz=NULL; *pn_multipart = FALSE; if (psz_copy == NULL) FailAllocMessage(); UtilTrimBlanks(psz_copy); psz = strchr(psz_copy, '/'); if (psz != NULL) { *psz = '\0'; if (UtilStrICmp(psz_copy, "multipart") == 0) { *pn_multipart = TRUE; } *psz = '/'; } else { UtilFree(psz_copy); return FALSE; } for (ppsz=gppszValidMultipartReplace; *ppsz != NULL; ppsz++) { if (UtilStrICmp(*ppsz, psz_copy) == 0) { UtilFree(psz_copy); return TRUE; } } UtilFree(psz_copy); return FALSE; } static char *gppszValidImageContentType[] = { "image/jpeg", "JPEG-dither", /* JPEG movie or Motion JPEG */ "image/jpg", "JPEG-dither", /* JPEG movie or Motion JPEG */ "image/png", "PNG-dither", /* Netscape Server Push */ NULL }; static int ValidImageContentType(buf, ppsz_filter) char *buf, **ppsz_filter; { char *psz_copy=UtilStrDup(buf); char **ppsz=NULL; if (psz_copy == NULL) FailAllocMessage(); UtilTrimBlanks(psz_copy); ppsz = (gaszFilterForContentType==NULL ? gppszValidImageContentType: gaszFilterForContentType); for ( ; *ppsz != NULL; ppsz++) { if (UtilStrICmp(*ppsz, psz_copy) == 0) { if (ppsz_filter != NULL) *ppsz_filter = ppsz[1]; UtilFree(psz_copy); return TRUE; } ppsz++; } if (UtilStrICmp(psz_copy, "text/html") == 0) { if (ppsz_filter != NULL) *ppsz_filter = NULL; UtilFree(psz_copy); return TRUE; } UtilFree(psz_copy); return FALSE; } static void UpdateBoundary(buf) char *buf; { UtilFree(gpszBoundary); gpszBoundary = (char*)malloc(strlen(buf)+3); if (gpszBoundary == NULL) FailAllocMessage(); sprintf(gpszBoundary, "--%s", buf); UtilTrimBlanks(gpszBoundary); if (*gpszBoundary == '"') { int len=strlen(gpszBoundary); if (len > 2 && gpszBoundary[len-1] == '"') { char *psz=gpszBoundary, *psz1=(&gpszBoundary[1]); gpszBoundary[--len] = '\0'; while (*psz1 != '\0') { *psz++ = *psz1++; } *psz = '\0'; } } gnBoundaryLen = strlen(gpszBoundary); } static int FindBoundary(buf) char *buf; { char *semi_colon=NULL; int found=FALSE; while (*buf == ' ' || *buf == '\t') buf++; semi_colon = strchr(buf, ';'); while (!found) { char *equal_ptr=NULL; if (semi_colon != NULL) *semi_colon = '\0'; equal_ptr = strchr(buf, '='); if (equal_ptr != NULL) { *equal_ptr = '\0'; if (UtilStrICmp(buf, "boundary") == 0) { UpdateBoundary(&equal_ptr[1]); found = TRUE; } *equal_ptr = '='; } if (semi_colon == NULL) break; *semi_colon++ = ';'; buf = semi_colon; while (*buf == ' ' || *buf == '\t') buf++; semi_colon = strchr(buf, ';'); } return found; } static int GetContentLength(buf) char *buf; { char *c_ptr=NULL, *psz=NULL, *line_ptr=buf; int content_len=(-1), just_lf=IsJustLF(buf); int good_content_type=FALSE, last_line_is_content_type=FALSE; int inc=(just_lf?1:2); for (c_ptr=GetHeaderLine(line_ptr, just_lf); c_ptr != NULL; c_ptr=GetHeaderLine(line_ptr, just_lf)) { char *colon_ptr=NULL; if (c_ptr == line_ptr) { /* reach the end of header, now decide if the header is good */ gnJustLF = just_lf; gnHeaderLen = gnStartIndex = ((&c_ptr[inc]) - buf); if (good_content_type && gpszBoundary != NULL) { gnMultipartReplace = TRUE; if ((debugHttp % 100) == 99 && cmdLineDumpURL && cmdLineDumpURLWithHeader) { fprintf(stdout, "%s", buf); } } else { ResetMultipartReplace(FALSE); gnPossibleMultipartReplace = FALSE; } return (content_len==(-1) ? 0 : content_len); } *c_ptr = '\0'; if (*line_ptr == ' ' || *line_ptr == '\t') { if (last_line_is_content_type && good_content_type) { for (psz=line_ptr; *psz == ' ' || *psz == '\t'; psz++) ; FindBoundary(psz); } } else { last_line_is_content_type = FALSE; colon_ptr = strchr(line_ptr, ':'); if (colon_ptr != NULL) { *colon_ptr = '\0'; if (UtilStrICmp(line_ptr, "Content-Length") == 0) { char length_str[MAXSTRING]; int len=0; UtilStrCpyN(length_str, MAXSTRING-1, &colon_ptr[1]); UtilTrimBlanks(length_str); if (sscanf(length_str, "%d", &len) == 1) { content_len = len; } } else if (UtilStrICmp(line_ptr, "Content-Type") == 0) { int multipart=FALSE; last_line_is_content_type = TRUE; psz = strchr(&colon_ptr[1], ';'); if (psz != NULL) *psz = '\0'; good_content_type = ValidMultipartReplace(&colon_ptr[1], &multipart); if (!good_content_type && multipart) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "%s Content-Type: %s\n", "Does not know how to handle", &colon_ptr[1]); #endif /* _TGIF_DBG */ } if (psz != NULL) { *psz++ = ';'; if (good_content_type) { FindBoundary(psz); } } } *colon_ptr = ':'; } } *c_ptr = (just_lf ? '\n' : '\r'); line_ptr = (&c_ptr[inc]); } return (-1); } static void ScanHeader(buf) char *buf; { if (GetContentLength(buf) > 0) { /* the header contains Content-Length, no good! */ ResetMultipartReplace(FALSE); gnPossibleMultipartReplace = FALSE; } } typedef struct tagImageContentInfo { char sz_content_type[MAXSTRING]; char *psz_filter; int content_len; int header_len; } ImageContentInfo; /* * The data in the buffer is expected to have the following structure: * * HTTP/1.0 200 * Content-Type: multipart/x-mixed-replace: boundary=BOUNDARYPATTERN * * --BOUNDARYPATTERN * Content-Type: image/jpeg * * ~~~~..JFIF.....H.H..~~..Photoshop 3.0.8BIM.~.... * 3~O~~~~~~.~~~~?~G~~~~~~~~,~~~a~ \~~~ * * --BOUNDARYPATTERN * Content-Type: image/jpeg * * ~~~~..JFIF..........~~.C...........#!.$.M2.**.^C * ..................................~~ * * Notices that the first 3 bytes in a JPEG file is ff d8 ff and * the last 2 bytes are ff d9. This is how the code can figure * out the end of the JPEG file without Content-Length. */ static int GetContent(buf, buf_len, start_index, pici) char *buf; int buf_len, start_index; ImageContentInfo *pici; { char *c_ptr=NULL, *line_ptr=(&buf[start_index]); int content_len=(-1), just_lf=IsJustLF(line_ptr); int found_boundary=FALSE, inc=(just_lf?1:2), first_line=TRUE; int faked_found_boundary=FALSE, seen_none_blank_line=FALSE; memset(pici, 0, sizeof(ImageContentInfo)); for (c_ptr=GetHeaderLine(line_ptr, just_lf); c_ptr != NULL; c_ptr=GetHeaderLine(line_ptr, just_lf)) { char *colon_ptr=NULL; if (!found_boundary) { *c_ptr = '\0'; if (*line_ptr == ' ' || *line_ptr == '\t') { /* ignore */ } else if (first_line && *line_ptr == '\0') { /* * it may not have the boundary line, just pretend that the * boundary line is found */ found_boundary = TRUE; faked_found_boundary = TRUE; } else { if (strcmp(line_ptr, gpszBoundary) == 0) { found_boundary = TRUE; } else if (strncmp(gpszBoundary, "----", 4) == 0 && strcmp(line_ptr, &gpszBoundary[2]) == 0) { found_boundary = TRUE; UpdateBoundary(&line_ptr[2]); } seen_none_blank_line = TRUE; } first_line = FALSE; *c_ptr = (just_lf ? '\n' : '\r'); line_ptr = (&c_ptr[inc]); continue; } if (c_ptr == line_ptr && seen_none_blank_line) { /* reach the end of header, now decide if the header is good */ pici->header_len = ((&c_ptr[inc])-(&buf[start_index])); pici->content_len = (content_len==(-1) ? 0 : content_len); if (pici->content_len == 0) { /* * no content length information, see if it's really a JPEG file, * and if it is, just look for the EOI */ if (start_index+pici->header_len+3 <= buf_len) { char *psz=(&buf[start_index+pici->header_len]); if (psz[0] == ((char)0xff) && psz[1] == ((char)0xd8) && psz[2] == ((char)0xff)) { int index=0; /* now look for EOI, which is 0xffd9 */ for (index=start_index+pici->header_len; index < buf_len-1; index++, psz++) { if (*psz == ((char)0xff) && psz[1] == ((char)0xd9)) { /* got EOI, now we know the content length */ pici->content_len = content_len = index+2-(start_index+pici->header_len); break; } } } else if (psz[0] == ((char)0x89) && psz[1] == 'P' && psz[2] == 'N' && psz[3] == 'G') { /* * Well, Content-Length better be there! */ } else { /* this stream should be abandoned */ } } } if (start_index+pici->header_len+pici->content_len >= buf_len) { /* image is not in the buffer yet */ return (-1); } return (content_len==(-1) ? 0 : content_len); } *c_ptr = '\0'; if (*line_ptr == ' ' || *line_ptr == '\t' || *line_ptr == '\0') { /* ignore */ } else { seen_none_blank_line = TRUE; colon_ptr = strchr(line_ptr, ':'); if (colon_ptr != NULL) { *colon_ptr = '\0'; if (UtilStrICmp(line_ptr, "Content-Length") == 0) { char length_str[MAXSTRING]; int len; UtilStrCpyN(length_str, MAXSTRING-1, &colon_ptr[1]); UtilTrimBlanks(length_str); if (sscanf(length_str, "%d", &len) == 1) { content_len = len; } } else if (UtilStrICmp(line_ptr, "Content-Type") == 0) { char *psz=strchr(&colon_ptr[1], ';'); if (psz != NULL) *psz = '\0'; UtilStrCpyN(pici->sz_content_type, sizeof(pici->sz_content_type), &colon_ptr[1]); UtilTrimBlanks(pici->sz_content_type); if (!ValidImageContentType(&colon_ptr[1], &pici->psz_filter)) { fprintf(stderr, TgLoadCachedString(CSTID_DONT_KNOW_HOW_HANDLE_FRAME_CT), &colon_ptr[1]); fprintf(stderr, "\n"); } else if (pici->psz_filter == NULL) { /* content-type is text/html, pretend it's okay */ } if (psz != NULL) *psz++ = ';'; } *colon_ptr = ':'; } else if (faked_found_boundary) { if (strcmp(line_ptr, gpszBoundary) == 0) { faked_found_boundary = FALSE; } } } *c_ptr = (just_lf ? '\n' : '\r'); line_ptr = (&c_ptr[inc]); } return (-1); } static void ScanBody(buf, pn_buf_len) char *buf; int *pn_buf_len; { ImageContentInfo ici; memset(&ici, 0, sizeof(ImageContentInfo)); while (GetContent(buf, *pn_buf_len, gnStartIndex, &ici) > 0) { if (*ici.sz_content_type != '\0' && ici.psz_filter != NULL) { char *tmp_fname=WriteRemoteFileIntoTemp( &buf[gnStartIndex+ici.header_len], ici.content_len, NULL); if (tmp_fname != NULL) { int left_over=0; int saved_enable_failed_import_msgbox=GetEnableFailedImportMsgBox(); char *dest=NULL, *src=NULL; if (gpVideoObj != NULL) { UnlinkObj(gpVideoObj); FreeObj(gpVideoObj); } gpVideoObj = NULL; if (strcmp(ici.sz_content_type, "image/png") == 0) { SetEnableFailedImportMsgBox(FALSE); } if (ImportSpecifiedFileType(tmp_fname, ici.psz_filter)) { gpVideoObj = topObj; MoveObj(gpVideoObj, drawOrigX-gpVideoObj->obbox.ltx, drawOrigY-gpVideoObj->obbox.lty); DrawObj(drawWindow, gpVideoObj); } SetEnableFailedImportMsgBox(saved_enable_failed_import_msgbox); unlink(tmp_fname); free(tmp_fname); /* now we need to shrink the buffer */ left_over = *pn_buf_len - gnStartIndex - ici.header_len - ici.content_len; dest = (&buf[gnStartIndex]); src = (&buf[gnStartIndex+ici.header_len+ici.content_len]); if (left_over >= 5 && UtilStrNCaseCmp(src, "HTTP/", 5) == 0) { dest = buf; memcpy(dest, src, left_over*sizeof(char)); *pn_buf_len = left_over; ResetMultipartReplace(FALSE); ScanHeader(buf); if (!gnMultipartReplace) { return; } } else { memcpy(dest, src, left_over*sizeof(char)); *pn_buf_len = gnStartIndex + left_over; } } } } } void HandleMultipartReplace(buf, pn_buf_len) char *buf; int *pn_buf_len; { if (!gnPossibleMultipartReplace) return; if (gnMultipartReplace) { ScanBody(buf, pn_buf_len); } else { ScanHeader(buf); if (gnMultipartReplace) { ScanBody(buf, pn_buf_len); } } } void FakeUserAgent(buf) char *buf; { char prev_agent[MAXSTRING<<1], spec[MAXSTRING<<1]; if (buf != NULL && strcmp(buf, "-1") != 0) { int len=0; UtilStrCpyN(spec, sizeof(spec), buf); UtilTrimBlanks(spec); len = strlen(spec); if (len > 0 && spec[len-1] == ')') spec[len-1] = '\0'; } else { *prev_agent = '\0'; GetUserAgent(prev_agent, sizeof(prev_agent)); if (*prev_agent == '\0') { sprintf(gszMsgBox, TgLoadString(STID_ENTER_USERAGENT_FOR_HTTP)); } else { sprintf(gszMsgBox, TgLoadString(STID_ENTER_USERAGENT_FOR_HTTP_CUR), prev_agent); } *spec = '\0'; if (Dialog(gszMsgBox, TgLoadString(STID_PRESS_ENTER_FOR_DEF_USERAGENT), spec) == INVALID) { return; } } UtilTrimBlanks(spec); SetUserAgent(spec); *prev_agent = '\0'; GetUserAgent(prev_agent, sizeof(prev_agent)); if (*prev_agent == '\0') { sprintf(gszMsgBox, TgLoadString(STID_WILL_USE_DEF_USERAGENT_HTTP)); } else { sprintf(gszMsgBox, TgLoadString(STID_WILL_USE_NAMED_USERAGENT_HTTP), prev_agent); } Msg(gszMsgBox); } void FakeReferer(buf) char *buf; { char spec[MAXSTRING<<1]; *spec = '\0'; if (buf != NULL && strcmp(buf, "-1") != 0) { int len=0; UtilStrCpyN(spec, sizeof(spec), buf); UtilTrimBlanks(spec); len = strlen(spec); if (len > 0 && spec[len-1] == ')') spec[len-1] = '\0'; } else { if (gpszFakedReferer == NULL) { sprintf(gszMsgBox, TgLoadString(STID_ENTER_REFERRER_FOR_HTTP)); } else { sprintf(gszMsgBox, TgLoadString(STID_ENTER_REFERRER_FOR_HTTP_CUR), gpszFakedReferer); } *spec = '\0'; if (Dialog(gszMsgBox, TgLoadString(STID_PRESS_ENTER_FOR_NO_REFERRER), spec) == INVALID) { return; } } if (*spec != '\0') { if (!navigatingBackAndForth) BeforeNavigate(); ClearFileInfo(FALSE); RedrawTitleWindow(); } UtilTrimBlanks(spec); HttpFakeReferer(spec); if (gpszFakedReferer == NULL) { sprintf(gszMsgBox, TgLoadString(STID_WILL_NOT_USE_REFERRER_HTTP)); } else { sprintf(gszMsgBox, TgLoadString(STID_WILL_USE_NAMED_REFERRER_HTTP), gpszFakedReferer); } Msg(gszMsgBox); } void ToggleKeepAlive() { gnHttpKeepAlive = (!gnHttpKeepAlive); sprintf(gszMsgBox, TgLoadString(gnHttpKeepAlive ? STID_WILL_USE_KEEP_ALIVE_HTTP : STID_NOT_WILL_USE_KEEP_ALIVE_HTTP)); Msg(gszMsgBox); } ��������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tangram2.c���������������������������������������������������������������������������0000644�0000764�0000764�00000172467�11602233313�014665� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Daniel Ratton Figueiredo <ratton@land.ufrj.br> * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tangram2.c,v 1.19 2011/05/25 16:45:49 cvsps Exp $ */ #define _INCLUDE_FROM_TANGRAM2_C_ #include <ctype.h> #include "tgifdefs.h" #include "attr.e" #include "auxtext.e" #include "box.e" #include "cmd.e" #include "color.e" #include "dialog.e" #include "drawing.e" #include "exec.e" #include "menu.e" #include "msg.e" #include "miniline.e" #include "move.e" #include "obj.e" #include "pattern.e" #include "rcbox.e" #include "select.e" #include "setup.e" #include "strtbl.e" #include "tangram2.e" #include "text.e" #include "util.e" char cmdLineGenParser[MAXSTRING]; #define DO_CMD(cmd) ExecACommandFromBuffer(cmd,NULL) static TgMenuItemInfo tangram2MenuItemInfo[] = { { "About Tangram-II", NULL, "Information about Tangram-II", NULL, CMDID_ABOUT_TANGRAM2 }, { NULL, NULL, NULL, NULL, INVALID } }; TgMenuInfo tangram2MenuInfo={ TGMUTYPE_TEXT, tangram2MenuItemInfo, CreateTangram2Menu }; /* ======================= Init & CleanUp ======================= */ void CleanUpTangram2() { CleanUpTangram2ShortCut(); } int InitTangram2() { InitTangram2ShortCut(); return TRUE; } /* ======================= Tangram2 Shortcuts ======================= */ static struct ShortCutRec tangram2ShortCutXlateTbl[] = { { '\0', 0, "AboutTangram2()", 0, CMDID_ABOUT_TANGRAM2 }, { '\0', 0, "Tangram2GenerateChain()", 1, CMDID_TANGRAM2_GENERATE_CHAIN }, { '\0', 0, "Tangram2StartSimulator()", 1, CMDID_TANGRAM2_START_SIMULATOR }, { '\0', 0, "Tangram2SimulationStep()", 0, CMDID_TANGRAM2_SIMULATION_STEP }, { '\0', 0, "Tangram2EndSimulator()", 0, CMDID_TANGRAM2_END_SIMULATOR }, { '\0', 0, "", 0, 0 } }; static int tangram2ShortCutCmdIdIndex[MAXTANGRAM2CMDIDS-CMDID_TANGRAM2_BASE]; void CleanUpTangram2ShortCut() { } int InitTangram2ShortCut() { int i=0, num_cmdids=MAXTANGRAM2CMDIDS-CMDID_TANGRAM2_BASE; for (i=0; i < num_cmdids; i++) { tangram2ShortCutCmdIdIndex[i] = INVALID; } for (i=0; *(tangram2ShortCutXlateTbl[i].name) != '\0'; i++) { int cmdid=tangram2ShortCutXlateTbl[i].cmdid; if (cmdid != INVALID) { int index=cmdid-CMDID_TANGRAM2_BASE; if (tangram2ShortCutCmdIdIndex[index] == INVALID) { tangram2ShortCutCmdIdIndex[index] = i; } else { fprintf(stderr, "Warning: duplicate cmdid %1d.\n", cmdid); } } } return TRUE; } int ValidTangram2CmdName(buf, len, pn_num_args) char *buf; int len, *pn_num_args; /* * returns 0 if no match * otherwise, returns (CMDID_TANGRAM2_BASE|index) where index is the * index into tangram2ShortCutXlateTbl */ { int i; for (i=0; *(tangram2ShortCutXlateTbl[i].name) != '\0'; i++) { if (strncmp(tangram2ShortCutXlateTbl[i].name, buf, len) == 0) { *pn_num_args = tangram2ShortCutXlateTbl[i].num_args; return (i+CMDID_TANGRAM2_BASE); } } return 0; } int ValidTangram2CmdId(nCmdId) int nCmdId; { int cmd_index=nCmdId-CMDID_TANGRAM2_BASE, xlate_index=INVALID; if (nCmdId >= MAXTANGRAM2CMDIDS || nCmdId < CMDID_TANGRAM2_BASE) { return FALSE; } xlate_index = tangram2ShortCutCmdIdIndex[cmd_index]; if (xlate_index == INVALID || tangram2ShortCutXlateTbl[xlate_index].num_args != 0) { return FALSE; } return TRUE; } int DoTangram2Cmd(nCmdId, args) int nCmdId; char *args; /* returns INVALID if the event can be caught by other windows */ { switch (nCmdId) { case CMDID_ABOUT_TANGRAM2: AboutTangram2(); break; case CMDID_TANGRAM2_GENERATE_CHAIN: Tangram2GenerateChain(args); break; case CMDID_TANGRAM2_START_SIMULATOR: Tangram2StartSimulator(args); break; case CMDID_TANGRAM2_SIMULATION_STEP: Tangram2SimulationStep(); break; case CMDID_TANGRAM2_END_SIMULATOR: Tangram2EndSimulator(); break; default: break; } return BAD; } int FetchTangram2ShortCutNumArgs(index, pn_num_args) int index, *pn_num_args; { *pn_num_args = tangram2ShortCutXlateTbl[index].num_args; return TRUE; } int DoTangram2ShortCut(index, args) int index; char *args; /* return FALSE if cannot execute shortcut */ { if (index < 0 || index >= MAXTANGRAM2CMDIDS-CMDID_TANGRAM2_BASE) { return FALSE; } if (tangram2ShortCutXlateTbl[index].num_args == 0) { DoTangram2Cmd(tangram2ShortCutXlateTbl[index].cmdid, NULL); } else { DoTangram2Cmd(tangram2ShortCutXlateTbl[index].cmdid, args); } return TRUE; } /* ======================= Tangram2 Internal Commands ======================= */ void ExecStartSimulator ARGS_DECL((struct ObjRec *, char*)); void ExecSimulateStep ARGS_DECL((struct ObjRec *, char*)); void ExecEndSimulator ARGS_DECL((struct ObjRec *, char*)); static ExecInfo gTangram2ExecInfo[] = { { (NLFN*)ExecStartSimulator, "start_simulator", 0, 0}, { (NLFN*)ExecSimulateStep, "simulate_step", 0, 0}, { (NLFN*)ExecEndSimulator, "end_simulator", 0, 0}, { NULL, NULL, 0, 0 } }; ExecInfo *Tangram2GetExecInfo(func_name) char *func_name; { ExecInfo *pei=NULL; for (pei=gTangram2ExecInfo; pei->pfunc != NULL; pei++) { if (strcmp(pei->func_name, func_name) == 0) { return pei; } } return NULL; } /* --------------- Tangram2 Internal Commands Implementation --------------- */ #define MAXCONNECTTRIES 3 #define PORT 6743 static int simulator_socket=INVALID; static struct ObjRec *objGC=NULL; /* Generate Chain button */ static struct ObjRec *objSS=NULL; /* Start Simulation button */ static struct ObjRec *objSp=NULL; /* Simulation Step button */ #define SP_OPT_HAS_VALUE (1<<0) #define SP_OPT_HAS_FORMAT (1<<1) #define SP_OPT_IN_ARRAY (1<<2) #define SP_OPT_FIRST_IN_ARRAY (1<<3) #define SP_OPT_LAST_IN_ARRAY (1<<4) #define CT_CODE_INIT_SIMULATION 0 #define CT_CODE_END_OF_SIMULATION 1 #define CT_CODE_STEP_SIMULATION 2 #define MAXOBJECTNAME 120 #define MAXSYMBOLNAME 120 #define MAXVALUESIZE 240 #define MAXFORMATSIZE 24 #define MAXEVENTNAME 512 #define SKIP_WHITESPACE(x) { while( isspace((int)(*(x))) ) (x)++; } /* Control Packet */ typedef struct tagT_ControlPacket { int code; /* info to update TGIF's screen */ int step; double elapsed_time; /* number of Symbol packets following */ int symcount; /* name of latest event executed by the simulator */ char last_event[MAXEVENTNAME]; } T_ControlPacket; /* Symbol Packet */ typedef struct tagT_SymbolPacket { char object_name[MAXOBJECTNAME]; char symbol_name[MAXSYMBOLNAME]; int options; /* available options: SP_OPT_HAS_VALUE SP_OPT_HAS_FORMAT SP_OPT_IN_ARRAY SP_OPT_FIRST_IN_ARRAY SP_OPT_LAST_IN_ARRAY */ int array_index; /* if SP_OPT_IN_ARRAY this is the index */ char value_string[MAXVALUESIZE]; /* if SP_OPT_HAS_VALUE this is the value */ char value_format[MAXFORMATSIZE]; } T_SymbolPacket; /* Function prototypes */ static int sendSymbolPacket( int, T_SymbolPacket * ); static int recvSymbolPacket( int, T_SymbolPacket * ); static int sendControlPacket( int, T_ControlPacket * ); static int recvControlPacket( int, T_ControlPacket * ); static void addSymToBuffer ( T_SymbolPacket * ); static void sendAllSymPackets( int ); static T_SymbolPacket * packet_queue = NULL; static int packet_queue_size = 0, packet_queue_max_size = 0; static int sendSymbolPacket( int soc, T_SymbolPacket * pack_out ) { int bywrite; if( (bywrite = write( soc, pack_out, sizeof(T_SymbolPacket) )) < 0 ) { perror( "write" ); return(-1); } return(1); } static int recvSymbolPacket( int soc, T_SymbolPacket * pack_in ) { int byread; if( (byread = read( soc, pack_in, sizeof(T_SymbolPacket)) ) < 0 ) { perror( "read" ); return(-1); } return(1); } static int sendControlPacket( int soc, T_ControlPacket * pack_out ) { int bywrite; if( (bywrite = write( soc, pack_out, sizeof(T_ControlPacket) )) < 0 ) { perror( "write" ); return(-1); } return(1); } static int recvControlPacket( int soc, T_ControlPacket * pack_in ) { int byread; if( (byread = read( soc, pack_in, sizeof(T_ControlPacket)) ) < 0 ) { perror( "read" ); return(-1); } return(1); } static void addSymToBuffer( T_SymbolPacket * packet ) { if( !packet_queue ) { packet_queue_max_size = 8; packet_queue = malloc( packet_queue_max_size * sizeof(T_SymbolPacket) ); } else if( packet_queue_size+1 > packet_queue_max_size ) /* queue overflow */ { packet_queue_max_size <<= 1; packet_queue = realloc( packet_queue, packet_queue_max_size * sizeof(T_SymbolPacket) ); } memcpy( packet_queue+packet_queue_size, packet, sizeof(T_SymbolPacket) ); packet_queue_size++; } static void sendAllSymPackets( int soc ) { int i; for( i = 0; i < packet_queue_size; i++ ) sendSymbolPacket( soc, packet_queue+i ); if( packet_queue ) { free( packet_queue ); packet_queue = NULL; packet_queue_max_size = 0; } packet_queue_size = 0; } static int BadAttr_Simulator(attr_name, cmd_name) char *attr_name, *cmd_name; { char msg[MAXSTRING+1]; sprintf(msg, "Can not find the '%s' %s '%s' command.", attr_name, "attribute while executing the", cmd_name); MsgBox(msg, TOOL_NAME, INFO_MB); return FALSE; } void ExecStartSimulator(obj_ptr, orig_cmd) char *orig_cmd; struct ObjRec *obj_ptr; /* start_simulator(); */ { char host[ 10 ]; char *protocol = "udp"; struct hostent *phe; struct servent *pse; struct protoent *ppe; struct sockaddr_in sin; int sin_size; int s, type, max_desc; char buffer; fd_set soc_pool; struct timeval timeout; int one = 1; char *service = "6743"; strcpy( host, "localhost" ); memset( (char *)&sin, 0, sizeof( sin ) ); sin.sin_family = AF_INET; if( (pse = getservbyname( service, protocol )) != NULL ) sin.sin_port = pse->s_port; else if( (sin.sin_port = htons( (u_short)atoi( service ) )) == 0 ) { fprintf( stderr,"TGIF: Can't get \"%s\" service entry\n", service ); return; } if( (phe = gethostbyname( host )) != NULL ) memcpy( (char *)&sin.sin_addr, phe->h_addr, phe->h_length ); else { sin.sin_addr.s_addr = inet_addr( host ); #ifdef linux if( sin.sin_addr.s_addr == INADDR_NONE ) { fprintf( stderr, "TGIF: Can't get \"%s\" host entry\n", host ); return; } #endif /* linux */ } if( (ppe = getprotobyname( protocol )) == NULL ) { fprintf( stderr, "TGIF: Can't get \"%s\" protocol entry\n", protocol ); return; } if( strcmp( protocol, "udp" ) == 0 ) type = SOCK_DGRAM; else type = SOCK_STREAM; if( (s = socket( PF_INET, type, ppe->p_proto )) < 0 ) { fprintf( stderr, "TGIF: Can't create socket\n" ); return; } if( setsockopt( s, SOL_SOCKET, SO_REUSEADDR, (char *)&one, sizeof( one ) ) < 0 ) { perror( "TGIF: REUSEADDR" ); return; } if( bind( s, (struct sockaddr *)&sin, sizeof( sin ) ) < 0 ) { perror( "TGIF: bin" ); return; } if( type == SOCK_STREAM && listen( s, 0 ) < 0 ) { fprintf( stderr, "TGIF: Can't listen on %s port\n", service ); return; } fprintf(stdout,"TGIF: ready to receive data from the simulator.\n"); fflush(stdout); FD_ZERO( &soc_pool ); FD_SET( s, &soc_pool ); max_desc = s + 1; timeout.tv_sec = 10; timeout.tv_usec = 0; if( select( max_desc, &soc_pool, NULL, NULL, &timeout ) < 0 ) { perror( "TGIF: select" ); return; } if( FD_ISSET( s, &soc_pool ) ) { sin_size = sizeof( sin ); if( recvfrom( s, &buffer, sizeof(buffer), 0, (struct sockaddr *)&sin, (void*)(&sin_size) ) < 0 ) { perror( "TGIF: recv" ); return; } if( connect( s, (struct sockaddr *)&sin, sin_size ) < 0 ) { fprintf( stderr, "TGIF: Can't connect to %s.%s\n", host, service ); return; } sleep( 1 ); if( send( s, &buffer, sizeof(buffer), 0 ) < 0 ) { perror( "TGIF: send" ); return; } } else { fprintf( stderr, "TGIF: Timeout expired\n" ); return; } simulator_socket = s; printf("TGIF: Client Connected.\n"); } void ExecEndSimulator(obj_ptr, orig_cmd) char *orig_cmd; struct ObjRec *obj_ptr; /* end_simulator(); */ { T_ControlPacket pack_out; if (simulator_socket == INVALID) { perror("invalid simulator_socket"); return; } /* monta o pacote */ memset((char *)&pack_out, 0, sizeof(T_ControlPacket)); pack_out.code = CT_CODE_END_OF_SIMULATION; /* envia o pacote ao simulador */ sendControlPacket( simulator_socket, &pack_out ); close(simulator_socket); printf("TGIF: Simulation finished.\n"); } static void AppendLinesToAttr(attr_ptr, ppsz_lines) struct AttrRec *attr_ptr; char **ppsz_lines; { char **ppsz=NULL; struct TextRec *text_ptr=attr_ptr->obj->detail.t; for (ppsz=ppsz_lines; *ppsz != NULL; ppsz++) { MiniLineInfo *pFirstMiniLine=NULL, *pLastMiniLine=NULL; CreateMiniLineFromString(*ppsz, &pFirstMiniLine, &pLastMiniLine); text_ptr->minilines.last->next = pFirstMiniLine; pFirstMiniLine->prev = text_ptr->minilines.last; text_ptr->minilines.last = pLastMiniLine; text_ptr->lines++; } RecalcTextMetrics(text_ptr, attr_ptr->obj->x, text_ptr->baseline_y); UpdTextBBox(attr_ptr->obj); } static void UpdateStateVars( soc, obj_ptr, ct_pack_in ) int soc; struct ObjRec *obj_ptr; T_ControlPacket * ct_pack_in; { int i; int begin, end; int alignment_size, name_length; char line[ MAXSYMBOLNAME+MAXFORMATSIZE+MAXVALUESIZE ]; char line_format[ MAXFORMATSIZE ]; char var_value[ MAXSTRING + 1 ]; char last_object_name[ MAXOBJECTNAME ]; char name_string[ MAXSYMBOLNAME+MAXFORMATSIZE ]; char value_string[ MAXVALUESIZE ]; char att_name[ 15 ]; struct ObjRec *owner_obj=NULL, *named_obj; struct ObjRec *att_owner_obj=NULL; struct AttrRec *attr_ptr; T_SymbolPacket pack_in; begin = 0; last_object_name[0] = 0; CleanTmpStr(); alignment_size = 12; sprintf( line_format, "%%-%ds%%s", alignment_size ); for( i = 0; i < ct_pack_in->symcount; i++ ) { recvSymbolPacket( soc, &pack_in ); /* if we are changing between objects, must update 'Watches=' in the last object */ if( last_object_name[0] != 0 && strcmp( last_object_name, pack_in.object_name ) != 0 ) { named_obj = FindObjWithName( botObj, obj_ptr, last_object_name, FALSE, FALSE, &owner_obj, NULL ); strcpy( att_name, "Watches=" ); attr_ptr = FindAttrWithName( named_obj, att_name, &att_owner_obj ); if( attr_ptr != NULL ) { char *count_buf = (char*)malloc( (strlen(att_name)+40) * sizeof(char) ); if( count_buf == NULL ) FailAllocMessage(); sprintf( count_buf, "%s", att_name ); if( PrependToTmpStr( count_buf ) ) ReplaceAttrAllValues( named_obj, attr_ptr, &topTmpStr, &botTmpStr ); free(count_buf); } CleanTmpStr(); alignment_size = 12; sprintf( line_format, "%%-%ds%%s", alignment_size ); } strcpy( last_object_name, pack_in.object_name ); /* handle new packet */ /* packets without values report invalid variables */ if( !(pack_in.options & SP_OPT_HAS_VALUE) ) { continue; } if( !(pack_in.options & SP_OPT_IN_ARRAY) ) { if( pack_in.options & SP_OPT_HAS_FORMAT ) sprintf( name_string, "%s<%s>", pack_in.symbol_name, pack_in.value_format ); else sprintf( name_string, "%s", pack_in.symbol_name ); sprintf( value_string, "%s", pack_in.value_string ); name_length = strlen( name_string ); while( name_length >= alignment_size ) alignment_size += 4; sprintf( line_format, "%%-%ds%%s", alignment_size ); sprintf( line, line_format, name_string, value_string ); AppendToTmpStr( line ); } else { if( pack_in.options & SP_OPT_FIRST_IN_ARRAY ) { begin = pack_in.array_index; end = -1; strcpy( var_value, pack_in.value_string ); } else { strcat( var_value, ", " ); strcat( var_value, pack_in.value_string ); } if( pack_in.options & SP_OPT_LAST_IN_ARRAY ) { end = pack_in.array_index; if( pack_in.options & SP_OPT_HAS_FORMAT ) { if( end == begin ) sprintf( name_string, "%s[%d]<%s>", pack_in.symbol_name, begin, pack_in.value_format ); else sprintf( name_string, "%s[%d:%d]<%s>", pack_in.symbol_name, begin, end, pack_in.value_format ); } else { if( end == begin ) sprintf( name_string, "%s[%d]", pack_in.symbol_name, begin ); else sprintf( name_string, "%s[%d:%d]", pack_in.symbol_name, begin, end ); } if( end == begin ) sprintf( value_string, "%s", var_value ); else sprintf( value_string, "[%s]", var_value ); name_length = strlen( name_string ); while( name_length >= alignment_size ) alignment_size += 4; sprintf( line_format, "%%-%ds%%s", alignment_size ); sprintf( line, line_format, name_string, value_string ); AppendToTmpStr( line ); } } } /* if there was an object in the last packet, must update 'Watches=' */ if( last_object_name[0] != 0 ) { named_obj = FindObjWithName( botObj, obj_ptr, last_object_name, FALSE, FALSE, &owner_obj, NULL ); strcpy( att_name, "Watches=" ); attr_ptr = FindAttrWithName( named_obj, att_name, &att_owner_obj ); if( attr_ptr != NULL ) { char *count_buf = (char*)malloc( (strlen(att_name)+40) * sizeof(char) ); if( count_buf == NULL ) FailAllocMessage(); sprintf( count_buf, "%s", att_name ); if( PrependToTmpStr( count_buf ) ) ReplaceAttrAllValues( named_obj, attr_ptr, &topTmpStr, &botTmpStr ); free(count_buf); } CleanTmpStr(); } } int ParseFormat( format ) char * format; { char * pt; int n_params, open; /* Syntax for formats: [.]*%[.]*[dioxX eEfFgGaA][.]* */ n_params = 0; open = 0; pt = format; do { /* look for a parameter beginning with '%' */ while( *pt != '%' && *pt != '\0' ) pt++; if( *pt == '\0' ) break; pt++; if( *pt == '%' ) { pt++; continue; } open = 1; /* look for any of the acceptable characters for int's and doubles */ pt = strpbrk( pt, "dioxXeEfFgGaA" ); if( !pt ) break; open = 0; n_params++; pt++; } while( 1 ); if( n_params != 1 || open ) return -1; return 0; } int ParseStateVariable( buffer, symname, symvalue, symformat, options, initial_index, final_index ) char * buffer; char * symname; char * symvalue; char * symformat; int * options; int * initial_index; int * final_index; { int i; char * pt; /* Syntax for requests: symname([i(:f)])(<symformat>)=(symvalue) */ SKIP_WHITESPACE(buffer); if( !isalpha((int)(*buffer)) ) return -1; *options = 0; /* getting the variable name */ for( i = 0; isalpha((int)(*buffer)) || isdigit((int)(*buffer)) || *buffer == '_'; buffer++, i++ ) { symname[i] = *buffer; } symname[i] = 0; if( strlen( symname ) <= 0 || strncmp( symname, "Watches", 10 ) == 0 ) return(-1); SKIP_WHITESPACE(buffer); /* OPTIONAL: getting array indices */ if( *buffer == '[' ) { buffer++; *initial_index = strtol( buffer, &pt, 0 ); if( pt == buffer ) return(-1); buffer = pt; if( *initial_index < 0 ) return(-1); *final_index = *initial_index; SKIP_WHITESPACE(buffer); if( *buffer == ':' ) { buffer++; *final_index = strtol( buffer, &pt, 0 ); if( pt == buffer ) return(-1); buffer = pt; if( *final_index < *initial_index ) return(-1); } SKIP_WHITESPACE(buffer); if( *buffer != ']' ) return(-1); buffer++; *options |= SP_OPT_IN_ARRAY; } SKIP_WHITESPACE(buffer); /* OPTIONAL: getting format string */ if( *buffer == '<' ) { buffer++; pt = buffer; while( *pt != '>' && *pt != '\0' && *pt != '\n' ) pt++; if( pt != buffer ) { strncpy( symformat, buffer, pt-buffer ); symformat[ pt - buffer ] = 0; if( ParseFormat( symformat ) < 0 ) return(-1); } buffer = pt; if( *buffer == '>' ) { buffer++; *options |= SP_OPT_HAS_FORMAT; } } SKIP_WHITESPACE(buffer); /* OPTIONAL: getting the '=' sign */ if( *buffer == '=' ) { buffer++; SKIP_WHITESPACE(buffer); /* OPTIONAL: getting the value */ if( *buffer == '[' ) { buffer++; pt = buffer; while( *pt != ']' && *pt != '\0' && *pt != '\n' ) pt++; if( pt == buffer ) return(-1); strncpy( symvalue, buffer, pt-buffer ); symvalue[ pt - buffer ] = 0; buffer = pt; *options |= SP_OPT_HAS_VALUE; if( *buffer != ']' ) return(-1); } else { strtod( buffer, &pt ); if( pt != buffer ) { strncpy( symvalue, buffer, pt-buffer ); symvalue[ pt - buffer ] = 0; buffer = pt; *options |= SP_OPT_HAS_VALUE; } } } return(0); } static char * getNextValue( char * values, char ** endpt ) { static char value[MAXVALUESIZE]; char * buffer; buffer = values; SKIP_WHITESPACE(buffer); strtod( buffer, endpt ); if( *endpt == buffer ) return(NULL); strncpy( value, buffer, *endpt-buffer ); value[ *endpt - buffer ] = 0; SKIP_WHITESPACE(*endpt); if( **endpt == ',' ) (*endpt)++; else *endpt = NULL; return(value); } void SendStepInfo( soc, ct_pack_out ) int soc; T_ControlPacket * ct_pack_out; { int j; int need_to_free_tmp_buf; int initial_index, final_index; int options; char symvalue [ MAXVALUESIZE ]; char symbol_name[ MAXSYMBOLNAME ]; char symformat [ MAXFORMATSIZE ]; char * value_string, * pt; char *tmp_buf; struct ObjRec *first_obj_ptr, *optr; struct AttrRec *name_attr; struct AttrRec *stat_attr; MiniLineInfo *pMiniLine; T_SymbolPacket sympack; CleanTmpStr(); first_obj_ptr = topObj; for( optr = first_obj_ptr; optr != NULL; optr = optr->next ) { stat_attr = FindAttrWithName(optr,"Watches=",NULL); if( stat_attr != NULL ) { /* Found an object that has the Watches attribute */ /* Query the object's name */ name_attr = FindAttrWithName(optr,"name=",NULL); /* For each line in the Watches attribute */ for( pMiniLine=stat_attr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { /* Convert attribute line text to a string */ tmp_buf = ConvertMiniLineToString( pMiniLine, &need_to_free_tmp_buf ); /* if we can parse a valid state variable request */ if( ParseStateVariable( tmp_buf, symbol_name, symvalue, symformat, &options, &initial_index, &final_index ) == 0 ) { /* initialize packet's fields */ sympack.object_name[0] = 0; sympack.symbol_name[0] = 0; sympack.options = 0; sympack.array_index = -1; sympack.value_string[0] = 0; sympack.value_format[0] = 0; /* state variable name */ strcpy( sympack.object_name, name_attr->attr_value.s ); strcpy( sympack.symbol_name, symbol_name ); if( options & SP_OPT_HAS_FORMAT ) strcpy( sympack.value_format, symformat ); /* if state variable is part of an array */ if( options & SP_OPT_IN_ARRAY ) { pt = symvalue; for( j = initial_index; j <= final_index; j++ ) { /* initialize options to those parsed */ /* SP_OPT_IN_ARRAY is always present SP_OPT_HAS_FORMAT may or may not appear SP_OPT_HAS_VALUE may appear but is ignored */ sympack.options = options; /* add SP_OPT_FIRST_IN_ARRAY */ if( j == initial_index ) sympack.options |= SP_OPT_FIRST_IN_ARRAY; /* add SP_OPT_LAST_IN_ARRAY */ if( j == final_index ) sympack.options |= SP_OPT_LAST_IN_ARRAY; /* add current index */ sympack.array_index = j; /* check for value */ value_string = getNextValue( pt, &pt ); if( value_string ) { sympack.options |= SP_OPT_HAS_VALUE; strcpy( sympack.value_string, value_string ); } else sympack.options &= ~SP_OPT_HAS_VALUE; /* add variable to packet queue */ addSymToBuffer( &sympack ); /* if next call to getNextValue will fail break */ if( !pt ) { j++; break; } } /* add rest of variables without value */ for( ; j <= final_index; j++ ) { /* initialize options to those parsed */ /* SP_OPT_IN_ARRAY is always present SP_OPT_HAS_FORMAT may or may not appear SP_OPT_HAS_VALUE is ignored */ sympack.options = options & ~SP_OPT_HAS_VALUE; /* add SP_OPT_FIRST_IN_ARRAY */ if( j == initial_index ) sympack.options |= SP_OPT_FIRST_IN_ARRAY; /* add SP_OPT_LAST_IN_ARRAY */ if( j == final_index ) sympack.options |= SP_OPT_LAST_IN_ARRAY; /* add current index */ sympack.array_index = j; /* add variable to packet queue */ addSymToBuffer( &sympack ); } } else /* !( options & SP_OPT_IN_ARRAY ) */ { sympack.options = options; /* check for value */ if( sympack.options & SP_OPT_HAS_VALUE ) { pt = symvalue; value_string = getNextValue( pt, &pt ); if( value_string ) strcpy( sympack.value_string, value_string ); } /* add variable to packet queue */ addSymToBuffer( &sympack ); } } if( need_to_free_tmp_buf ) UtilFree(tmp_buf); } /* Clear the Watches= attribute after sending all symbols */ tmp_buf = (char*)malloc( 20 * sizeof(char) ); if( tmp_buf == NULL ) FailAllocMessage(); strcpy( tmp_buf, "Watches=" ); AppendToTmpStr( tmp_buf ); ReplaceAttrAllValues( optr, stat_attr, &topTmpStr, &botTmpStr ); CleanTmpStr(); free(tmp_buf); } } ct_pack_out->symcount = packet_queue_size; sendControlPacket( soc, ct_pack_out ); sendAllSymPackets( soc ); } void ExecSimulateStep(obj_ptr, orig_cmd) char *orig_cmd; struct ObjRec *obj_ptr; { struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; static char execDummyStr[MAXSTRING+1]; struct ObjRec *owner_obj=NULL, *named_obj; static char obj_name[MAXSTRING+1]; T_ControlPacket pack_out, pack_in; static int transitions = 0; static double tempo = 0; int step = 1; if (simulator_socket == INVALID) { perror("invalid simulator_socket"); return; } /* pega o valor do atributo step */ strcpy(execDummyStr, "Step="); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) { BadAttr_Simulator(execDummyStr, orig_cmd); return; } step = atoi(attr_ptr->attr_value.s); /* * step nao pode ser menor do que zero (se for zero entao esta com play_mode) */ if (step <= 0) { step = 1; } /* monta o pacote */ memset((char *)&pack_out, 0, sizeof(T_ControlPacket)); pack_out.code = CT_CODE_STEP_SIMULATION; pack_out.step = step; /* send information to mark_find */ SendStepInfo( simulator_socket, &pack_out ); /* receive control information */ if( recvControlPacket( simulator_socket, &pack_in ) < 0 ) return; /* desmonta o pacote */ tempo = pack_in.elapsed_time; transitions = step; /* set current text justification to center justified */ DO_CMD("set_selected_text_just(\"left\")"); /* set current text font to Helvetica Bold */ DO_CMD("set_selected_text_font(\"Courier\")"); /* set current text size to 14 */ DO_CMD("set_selected_text_size(14)"); /* set current text color to 'black' */ DO_CMD("set_selected_obj_color(\"black\")"); /* set o valor do step_time (tempo de duracao deste step) */ strcpy(execDummyStr, "step_time="); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) { BadAttr_Simulator(execDummyStr, orig_cmd); return; } sprintf(execDummyStr, "%.3f", tempo); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, execDummyStr); /* atualiza o valor do atributo Time do objeto "__START_SIMULATOR__" */ strcpy(obj_name, "__START_SIMULATOR__"); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, &owner_obj, NULL); strcpy(execDummyStr, "Time="); attr_ptr = FindAttrWithName(named_obj, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) { BadAttr_Simulator(execDummyStr, orig_cmd); return; } tempo += atof(attr_ptr->attr_value.s); sprintf(execDummyStr, "%.3f", tempo); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, execDummyStr); /* atualiza o valor do atributo Transitions do mesmo objeto */ strcpy(execDummyStr, "Transitions="); attr_ptr = FindAttrWithName(named_obj, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) { BadAttr_Simulator(execDummyStr, orig_cmd); return; } transitions += atof(attr_ptr->attr_value.s); sprintf(execDummyStr, "%d", transitions); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, execDummyStr); /* atualiza o valor do atributo Last_Event do mesmo objeto */ strcpy(execDummyStr, "Last_Event="); attr_ptr = FindAttrWithName(named_obj, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) { BadAttr_Simulator(execDummyStr, orig_cmd); return; } strcpy(execDummyStr, pack_in.last_event); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, execDummyStr); /* Update state vars shown in screen */ UpdateStateVars( simulator_socket, obj_ptr, &pack_in ); } /* ======================= Tangram2 Menu ======================= */ int RefreshTangram2Menu(menu) TgMenu *menu; { int ok=TRUE; return ok; } TgMenu *CreateTangram2Menu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshTangram2Menu(menu)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int Tangram2Menu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(tangram2MenuInfo.create_proc)(NULL, X, Y, &tangram2MenuInfo, INVALID); activeMenu = MENU_TANGRAM2; if (menu != NULL) { rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } /* ========================= Tangram2 Menu Data ========================= */ static char *GenerateChainInit[] = { "get_current_file(\"str\");", "read_file_into_attr(\"| basename $(str) .obj\", \"basename\");", "strcpy(file_name, \"$(basename).parser\");", "strcpy(str, \" \");", "write_attr_into_file(str, $(file_name));", NULL }; static char *GenerateChainExec[] = { "disable_undo();", "exec(init);", "exec(write_model);", "exec(write_global_rewards);", "exec(write_indep_chains);", "enable_undo();", NULL }; static char *GenerateChainWriteModel[] = { "find_obj_names_on_all_pages(obj_list,\"Declaration=*\");", "get_line_in_attr(total_objs,obj_list,0);", "for_i(i,1,$(total_objs),1,write_obj);", NULL }; static char *GenerateChainErrorParts[] = { "message_box(NULL,\"Objects must have these four parts: Variables_and_parameters, Events, Messages and Rewards. $(str)\",\"Mode Error\", \"stop\");", "exec(stop);", NULL }; static char *GenerateChainStop[] = { "enable_undo();", "stop();", NULL }; static char *GenerateChainAppendGlobalRewards[] = { "append_attr_into_file(__GLOBAL_REWARDS__.global_rewards, $(file_name));", NULL }; static char *GenerateChainWriteIndependentChains[] = { "strcpy(str, \"Independent_Chains {\");", "append_attr_into_file(str,$(file_name));", "is_attr(result, __INDEP_CHAINS__.independent_chains);", "if($(result) != 0, append_indep_chains, NULL);", "strcpy(str, \"}\");", "append_attr_into_file(str,$(file_name));", NULL }; static char *GenerateChainAppendIndepChains[] = { "append_attr_into_file(__INDEP_CHAINS__.independent_chains, $(file_name));", NULL }; static char *GenerateChainWriteGlobalRewards[] = { "strcpy(str, \"Global_Rewards {\");", "append_attr_into_file(str,$(file_name));", "is_attr(result, __GLOBAL_REWARDS__.global_rewards);", "if($(result) != 0, append_global_rewards, NULL);", "strcpy(str, \"}\");", "append_attr_into_file(str,$(file_name));", NULL }; static char *GenerateChainWriteMaxValues[] = { "strcpy(max_file_name, \"$(basename).maxvalues\");", "strcpy(str, \"$(__SETUP__.max_values)\");", "write_attr_into_file(__SETUP__.max_values, $(max_file_name));", NULL }; static char *GenerateChainWriteObj[] = { "get_line_in_attr(obj_name,obj_list,$(i));", "strcpy(str, \"Object_Desc $(obj_name) (\");", "append_attr_into_file(str,$(file_name));", "is_attr(result,$(obj_name).Declaration);", "strcpy(str,\"Missing Declaration part in object: $(obj_name).\");", "if($(result) == 0,error_parts,NULL);", "strcpy(str, \"Declaration {\");", "append_attr_into_file(str,$(file_name));", "append_attr_into_file($(obj_name).Declaration,$(file_name));", "strcpy(str, \"}\");", "append_attr_into_file(str,$(file_name));", "is_attr(result,$(obj_name).Initialization);", "strcpy(str,\"Missing Initialization part in object: $(obj_name).\");", "if($(result) == 0,error_parts,NULL);", "strcpy(str, \"Initialization {\");", "append_attr_into_file(str,$(file_name));", "append_attr_into_file($(obj_name).Initialization,$(file_name));", "strcpy(str, \"}\");", "append_attr_into_file(str,$(file_name));", "is_attr(result,$(obj_name).Events);", "strcpy(str,\"Missing Events part in object: $(obj_name).\");", "if($(result) == 0,error_parts,NULL);", "strcpy(str, \"Events {\");", "append_attr_into_file(str,$(file_name));", "append_attr_into_file($(obj_name).Events,$(file_name));", "strcpy(str, \"}\");", "append_attr_into_file(str,$(file_name));", "is_attr(result,$(obj_name).Messages);", "strcpy(str,\"Missing Messages part in object: $(obj_name).\");", "if($(result) == 0,error_parts,NULL);", "strcpy(str, \"Messages {\");", "append_attr_into_file(str,$(file_name));", "append_attr_into_file($(obj_name).Messages,$(file_name));", "strcpy(str, \"}\");", "append_attr_into_file(str,$(file_name));", "is_attr(result,$(obj_name).Rewards);", "strcpy(str,\"Missing Rewards part in object: $(obj_name).\");", "if($(result) == 0,error_parts,NULL);", "strcpy(str, \"Rewards {\");", "append_attr_into_file(str,$(file_name));", "append_attr_into_file($(obj_name).Rewards,$(file_name));", "strcpy(str, \"}\");", "append_attr_into_file(str,$(file_name));", "strcpy(str, \")\");", "append_attr_into_file(str,$(file_name));", NULL }; /*-----------------------------------------------------------------------*/ static char *StartSimulatorSetModeB[] = { NULL }; static char *StartSimulatorSetModeI[] = { "strcpy(Transitions, \"0\");", "strcpy(Time, \"0.0\");", "start_simulator();", NULL }; static char *StartSimulatorErrorMode[] = { "message_box(NULL,\"Please, Mode has to be I(Interactive) or B(Batch)!\",\"Mode Error\", \"stop\");", NULL }; static char *StartSimulatorExec[] = { "disable_undo();", "show_attr(Transitions);", "show_attr(Time);", "exec(__GENERATE_CHAIN__.init);", "if(\"$(Mode)\"!=\"I\"&&\"$(Mode)\"!=\"B\",error_mode,NULL);" "strcpy(file_name, \"$(__GENERATE_CHAIN__.file_name)\");", "strcpy(str, \" \");", "write_attr_into_file(str, $(file_name));", "exec(__GENERATE_CHAIN__.write_model);" "exec(__GENERATE_CHAIN__.write_global_rewards);" "exec(__GENERATE_CHAIN__.write_indep_chains);", "if(\"$(Mode)\"==\"I\",set_mode_I,NULL);", "if(\"$(Mode)\"==\"B\",set_mode_B,NULL);", "enable_undo();", NULL }; /*-----------------------------------------------------------------------*/ static char *SimulationStepLoopAnimation[] = { "for_i(Ani_C_Step,1,$(Ani_T_Steps),1,Do_Animation);", "round(sleep_time,$(Time_Scale)*$(step_time)*1000);", "sleep(NULL,$(sleep_time));", NULL }; static char *SimulationStepDoAnimation[] = { "find_obj_names(obj_list,\"\",\"Animation=*\");", "get_line_in_attr(no_objs,obj_list,0);", "for_i(obj_index,1,$(no_objs),1,Animate_Obj);", NULL }; static char *SimulationStepAnimateObj[] = { "get_line_in_attr(cur_obj,obj_list,$(obj_index));", "exec(\"$(cur_obj).Animation\");", NULL }; static char *SimulationStepCallSimulator[] = { "simulate_step();", NULL }; static char *SimulationStepPlayOneStep[] = { "set_allow_interrupt(FALSE);", "exec(step_simulation);", "set_allow_interrupt(TRUE);", "sleep(NULL,$(Delay));", NULL }; static char *SimulationStepStop[] = { "stop();", NULL }; static char *SimulationStepExec[] = { "disable_undo();", "if(\"$(Step)\"==\"0\",play_simulation,step_simulation);", "enable_undo();", "redraw_drawing_area();", NULL }; static char *SimulationStepPlaySimulation[] = { "while(1,play_one_step);", NULL }; static char *SimulationStepStepSimulation[] = { "exec(call_simulator);", "if(\"$(Animation)\"==\"ON\",Loop_Animation,NULL);", NULL }; /** static char *SimulationStepParseObj[] = { NULL }; static char *SimulationStepWriteVars[] = { NULL }; static char *SimulationStepWriteVarLine[] = { NULL }; static char *SimulationStepUpdateObjects[] = { NULL }; static char *SimulationStepUpdateVars[] = { NULL }; **/ /* ====================== Tangram2 Auxiliar Functions ======================= */ struct ObjRec *createGenerateChainButton( dbglevel, maxstates, output ) char *dbglevel; char *maxstates; char *output; { struct ObjRec *tmp_box_obj=NULL; CreateBoxObj(0,0,10,10,TRUE); tmp_box_obj = topObj; /* Note: AddAttrByNameAndValue() adds the new object at tmp_box_obj->fattr */ AddAttrByNameAndValue(tmp_box_obj, "i=", ""); AddAttrByNameAndValue(tmp_box_obj, "dbglevel=", dbglevel); AddAttrByNameAndValue(tmp_box_obj, "maxstates=", maxstates); AddAttrByNameAndValue(tmp_box_obj, "output=", output); AddAttrByNameAndValue(tmp_box_obj, "processID=", ""); AddAttrByNameAndValue(tmp_box_obj, "name=", "__GENERATE_CHAIN__"); AddAttrByNameAndValue(tmp_box_obj, "basename=", ""); AddAttrByNameAndValue(tmp_box_obj, "total_objs=", ""); AddAttrByNameAndValue(tmp_box_obj, "file_name=", ""); AddAttrByNameAndValue(tmp_box_obj, "command=", ""); AddAttrByNameAndValue(tmp_box_obj, "str=", ""); AddAttrByNameAndValue(tmp_box_obj, "result=", ""); AddAttrByNameAndValue(tmp_box_obj, "obj_name=", ""); AddAttrByNameAndValue(tmp_box_obj, "max_file_name=", ""); AddAttrByNameAndValue(tmp_box_obj, "obj_list=", ""); AddAttrByNameAndValue(tmp_box_obj, "init=", ""); AppendLinesToAttr(tmp_box_obj->fattr, GenerateChainInit); AddAttrByNameAndValue(tmp_box_obj, "exec=", ""); AppendLinesToAttr(tmp_box_obj->fattr, GenerateChainExec); AddAttrByNameAndValue(tmp_box_obj, "write_model=", ""); AppendLinesToAttr(tmp_box_obj->fattr, GenerateChainWriteModel); AddAttrByNameAndValue(tmp_box_obj, "write_obj=", ""); AppendLinesToAttr(tmp_box_obj->fattr, GenerateChainWriteObj); AddAttrByNameAndValue(tmp_box_obj, "stop=", ""); AppendLinesToAttr(tmp_box_obj->fattr, GenerateChainStop); AddAttrByNameAndValue(tmp_box_obj, "error_parts=", ""); AppendLinesToAttr(tmp_box_obj->fattr, GenerateChainErrorParts); AddAttrByNameAndValue(tmp_box_obj, "write_max_values=", ""); AppendLinesToAttr(tmp_box_obj->fattr, GenerateChainWriteMaxValues); AddAttrByNameAndValue(tmp_box_obj, "write_global_rewards=", ""); AppendLinesToAttr(tmp_box_obj->fattr, GenerateChainWriteGlobalRewards); AddAttrByNameAndValue(tmp_box_obj, "append_global_rewards=", ""); AppendLinesToAttr(tmp_box_obj->fattr, GenerateChainAppendGlobalRewards); AddAttrByNameAndValue(tmp_box_obj, "write_indep_chains=", ""); AppendLinesToAttr(tmp_box_obj->fattr, GenerateChainWriteIndependentChains); AddAttrByNameAndValue(tmp_box_obj, "append_indep_chains=", ""); AppendLinesToAttr(tmp_box_obj->fattr, GenerateChainAppendIndepChains); AddNewSelObj(tmp_box_obj); return( tmp_box_obj ); } struct ObjRec *createStartSimulatorButton( runs, event, trans, time, mode ) char *runs; char *event; char *trans; char *time; char *mode; { struct ObjRec *tmp_box_obj = NULL; int y = 5; CreateRCBoxObj(4,y,500,y+55,TRUE); tmp_box_obj = topObj; tmp_box_obj->color = 9; if (mainDisplay != NULL) { UtilStrCpyN(tmp_box_obj->color_str, sizeof(tmp_box_obj->color_str), colorMenuItems[tmp_box_obj->color]); } tmp_box_obj->detail.rcb->width = 2; y += 5; AddAttrByNameAndValue(tmp_box_obj, "Runs=", runs); AddAttrByNameAndValue(tmp_box_obj, "Time=", time); tmp_box_obj->fattr->shown = TRUE; MoveObj(tmp_box_obj->fattr->obj, 20, y - tmp_box_obj->fattr->obj->obbox.lty); y += 14; AddAttrByNameAndValue(tmp_box_obj, "Transitions=", trans); tmp_box_obj->fattr->shown = TRUE; MoveObj(tmp_box_obj->fattr->obj, 20, y - tmp_box_obj->fattr->obj->obbox.lty); y += 14; AddAttrByNameAndValue(tmp_box_obj, "Last_Event=", event); tmp_box_obj->fattr->shown = TRUE; MoveObj(tmp_box_obj->fattr->obj, 20, y - tmp_box_obj->fattr->obj->obbox.lty); y += 14; AddAttrByNameAndValue(tmp_box_obj, "Mode=", mode); AddAttrByNameAndValue(tmp_box_obj, "file_name=", ""); AddAttrByNameAndValue(tmp_box_obj, "command=", ""); AddAttrByNameAndValue(tmp_box_obj, "simulating=", ""); AddAttrByNameAndValue(tmp_box_obj, "str=", ""); AddAttrByNameAndValue(tmp_box_obj, "name=", "__START_SIMULATOR__"); AddAttrByNameAndValue(tmp_box_obj, "set_mode_B=", ""); AppendLinesToAttr(tmp_box_obj->fattr, StartSimulatorSetModeB); AddAttrByNameAndValue(tmp_box_obj, "set_mode_I=", ""); AppendLinesToAttr(tmp_box_obj->fattr, StartSimulatorSetModeI); AddAttrByNameAndValue(tmp_box_obj, "error_mode=", ""); AppendLinesToAttr(tmp_box_obj->fattr, StartSimulatorErrorMode); AddAttrByNameAndValue(tmp_box_obj, "exec=", ""); AppendLinesToAttr(tmp_box_obj->fattr, StartSimulatorExec); AdjObjBBox(tmp_box_obj); AddNewSelObj(tmp_box_obj); RedrawDrawWindow(botObj); return( tmp_box_obj ); } struct ObjRec *createSimulationStepButton( time, anim, delay, step ) char *time; char *anim; char *delay; char *step; { struct ObjRec *tmp_box_obj = NULL; CreateBoxObj(0,0,10,10,TRUE); tmp_box_obj = topObj; /* Note: AddAttrByNameAndValue() adds the new object at tmp_box_obj->fattr */ AddAttrByNameAndValue(tmp_box_obj, "Time_Scale=", time); AddAttrByNameAndValue(tmp_box_obj, "Animation=", anim); AddAttrByNameAndValue(tmp_box_obj, "Delay=", delay); AddAttrByNameAndValue(tmp_box_obj, "Step=", step); AddAttrByNameAndValue(tmp_box_obj, "state_var_str=", "1"); AddAttrByNameAndValue(tmp_box_obj, "line_size=", "7"); AddAttrByNameAndValue(tmp_box_obj, "obj_list=", ""); AddAttrByNameAndValue(tmp_box_obj, "sleep_time=", "2049"); AddAttrByNameAndValue(tmp_box_obj, "step_time=", "2049"); AddAttrByNameAndValue(tmp_box_obj, "name=", "__SIMULATION_STEP__"); AddAttrByNameAndValue(tmp_box_obj, "cur_obj=", ""); AddAttrByNameAndValue(tmp_box_obj, "obj_index=", ""); AddAttrByNameAndValue(tmp_box_obj, "no_objs=", ""); AddAttrByNameAndValue(tmp_box_obj, "Ani_T_Steps=", "10"); AddAttrByNameAndValue(tmp_box_obj, "Ani_C_Step=", "11"); AddAttrByNameAndValue(tmp_box_obj, "step_index=", ""); AddAttrByNameAndValue(tmp_box_obj, "no_state_vars=", "3"); AddAttrByNameAndValue(tmp_box_obj, "state_var_value=", "8"); AddAttrByNameAndValue(tmp_box_obj, "state_var_name=", "8"); AddAttrByNameAndValue(tmp_box_obj, "obj_name=", ""); AddAttrByNameAndValue(tmp_box_obj, "new_line=", ""); AddAttrByNameAndValue(tmp_box_obj, "buffer=", ""); AddAttrByNameAndValue(tmp_box_obj, "state_var_line=", ""); AddAttrByNameAndValue(tmp_box_obj, "state_var_list=", ""); AddAttrByNameAndValue(tmp_box_obj, "state_var_tok=", ""); AddAttrByNameAndValue(tmp_box_obj, "var_index=", ""); AddAttrByNameAndValue(tmp_box_obj, "Loop_Animation=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepLoopAnimation); AddAttrByNameAndValue(tmp_box_obj, "Animate_Obj=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepAnimateObj); AddAttrByNameAndValue(tmp_box_obj, "Do_Animation=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepDoAnimation); AddAttrByNameAndValue(tmp_box_obj, "call_simulator=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepCallSimulator); AddAttrByNameAndValue(tmp_box_obj, "play_one_step=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepPlayOneStep); AddAttrByNameAndValue(tmp_box_obj, "stop=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepStop); AddAttrByNameAndValue(tmp_box_obj, "step_simulation=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepStepSimulation); AddAttrByNameAndValue(tmp_box_obj, "play_simulation=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepPlaySimulation); /** AddAttrByNameAndValue(tmp_box_obj, "update_objects=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepUpdateObjects); AddAttrByNameAndValue(tmp_box_obj, "update_vars=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepUpdateVars); AddAttrByNameAndValue(tmp_box_obj, "parse_obj=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepParseObj); AddAttrByNameAndValue(tmp_box_obj, "write_vars=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepWriteVars); AddAttrByNameAndValue(tmp_box_obj, "write_var_line=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepWriteVarLine); **/ AddAttrByNameAndValue(tmp_box_obj, "exec=", ""); AppendLinesToAttr(tmp_box_obj->fattr, SimulationStepExec); AddNewSelObj(tmp_box_obj); return( tmp_box_obj ); } /******************************************************************************/ /* This function extracts the args that are comma separated in 'args' and */ /* stores them in 'dst'. */ /* return 0 if failed, no_args if success. */ /* arguments: */ /* args: comma separated list of tokens */ /* dst : char vector pointer where the tokens will be stored */ /* no_args: number of tokens in 'args' */ /* max_arg_length: max token's size */ /******************************************************************************/ int parseArgs( args, dst, no_args, max_arg_length ) char *args; char *dst; int no_args; int max_arg_length; { int i, j; char *ptr; memset( dst, 0, no_args * max_arg_length ); ptr = args; /* Remove leading " and spaces */ while( *ptr == '\"' || *ptr == ' ' ) ptr++; for( i = 0; i < no_args; i++ ) { j = 0; while( *ptr != '\0' && *ptr != ';' && *ptr != '\"' && j < max_arg_length ) *(dst + max_arg_length * i + j++) = *ptr++; if( *ptr == ';' || *ptr == '\"' ) ptr++; else if( *ptr != '\0' ) break; } return( i == no_args ); } /* ======================= Tangram2 Menu Functions ======================= */ void AboutTangram2() { sprintf(gszMsgBox, "%s\n\n%s %s.", "Welcome to Tangram-II!", "Brought to you by the Tangram-II team at the", "Universidade Federal do Rio de Janeiro"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } /******************************************************************************/ /* This function creates a invisible button, executes this button and removes */ /* it. This function also needs to extract three arguments that are colapsed */ /* in arg. This is done because tgif supports only one argument functions. */ /******************************************************************************/ void Tangram2GenerateChain( args ) char *args; /* semi-colon separated list (arg1;arg2;arg3) */ { int saved_fill=objFill, saved_pen=penPat; struct ObjRec *tmp_box_obj=NULL; struct AttrRec *exec_attr=NULL; char arg[3][1024]; /* Extracts parameters from args */ if( !parseArgs( args, arg, 3, 1024 ) ) { fprintf( stderr, "TGIF: Usage Tangram2GenerateChain( \"arg1;arg2;arg3\" )\n" ); return; } MakeQuiescent(); /* select nothing, edit nothing */ objFill = penPat = NONEPAT; tmp_box_obj = createGenerateChainButton( arg[0], arg[1], arg[2] ); objFill = saved_fill; penPat = saved_pen; exec_attr = FindAttrWithName(topSel->obj, "exec=", NULL); if (exec_attr != NULL) { DoExecLoop(topSel->obj, exec_attr); } MakeQuiescent(); AddNewSelObj(tmp_box_obj); PrepareToRecord(CMD_DELETE, topSel, botSel, numObjSelected); UnlinkObj(topSel->obj); FreeObj(topSel->obj); RemoveAllSel(); RecordCmd(CMD_DELETE, NULL, NULL, NULL, 0); } void Tangram2StartSimulator( args ) char *args; { int saved_fill=objFill, saved_pen=penPat; struct AttrRec *exec_attr=NULL; char arg[12][1024]; /* first 3 for generate_chain */ struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; static char execDummyStr[MAXSTRING+1]; struct ObjRec *owner_obj=NULL, *named_obj; static char obj_name[MAXSTRING+1]; T_ControlPacket pack_out, pack_in; /* Extracts parameters from args */ if( !parseArgs( args, arg, 12, 1024 ) ) { return; } MakeQuiescent(); /* select nothing, edit nothing */ objFill = penPat = NONEPAT; /* set current text justification to center justified */ DO_CMD("set_selected_text_just(\"left\")"); /* set current text font to Helvetica Bold */ DO_CMD("set_selected_text_font(\"Courier\")"); /* set current text size to 14 */ DO_CMD("set_selected_text_size(14)"); /* set current text color to 'black' */ DO_CMD("set_selected_obj_color(\"black\")"); objGC = createGenerateChainButton( arg[0], arg[1], arg[2] ); objSp = createSimulationStepButton( arg[8], arg[9], arg[10], arg[11] ); objFill = saved_fill; penPat = saved_pen; objSS = createStartSimulatorButton( arg[3], arg[4], arg[5], arg[6], arg[7] ); exec_attr = FindAttrWithName(objSS, "exec=", NULL); if (exec_attr != NULL) { DoExecLoop(objSS, exec_attr); } /* send initial simulation request packet */ memset((char *)&pack_out, 0, sizeof(T_ControlPacket)); pack_out.code = CT_CODE_INIT_SIMULATION; /* send information to mark_find */ SendStepInfo( simulator_socket, &pack_out ); /* receive control information */ if( recvControlPacket( simulator_socket, &pack_in ) < 0 ) return; /* atualiza o valor do atributo Time do objeto "__START_SIMULATOR__" */ strcpy(obj_name, "__START_SIMULATOR__"); named_obj = FindObjWithName(botObj, topObj, obj_name, FALSE, FALSE, &owner_obj, NULL); strcpy(execDummyStr, "Time="); attr_ptr = FindAttrWithName(named_obj, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) { return; } strcpy( execDummyStr, "0" ); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, execDummyStr); /* atualiza o valor do atributo Transitions do mesmo objeto */ strcpy(execDummyStr, "Transitions="); attr_ptr = FindAttrWithName(named_obj, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) { return; } strcpy( execDummyStr, "0" ); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, execDummyStr); /* atualiza o valor do atributo Last_Event do mesmo objeto */ strcpy(execDummyStr, "Last_Event="); attr_ptr = FindAttrWithName(named_obj, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) { return; } strcpy(execDummyStr, pack_in.last_event); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, execDummyStr); /* Update state vars shown in screen */ UpdateStateVars( simulator_socket, topObj, &pack_in ); } void Tangram2SimulationStep() { struct AttrRec *exec_attr=NULL; exec_attr = FindAttrWithName(objSp, "exec=", NULL); if (exec_attr != NULL) { DoExecLoop(objSp, exec_attr); } } void Tangram2EndSimulator() { ExecEndSimulator( NULL, NULL ); /* Delete all created buttons */ MakeQuiescent(); AddNewSelObj(objGC); AddNewSelObj(objSS); AddNewSelObj(objSp); DelAllSelObj(); RedrawDrawWindow(botObj); } /* ======================= Tangram2 Misc Functions ======================= */ void Tangram2UpdateInitAttr(port_obj, signal_name) struct ObjRec *port_obj; char *signal_name; { struct AttrRec *attr_ptr=FindAttrWithName(port_obj, "name=", NULL); MiniLinesInfo *minilines=NULL; MiniLineInfo *pMiniLine=NULL; struct TextRec *text_ptr=NULL; char *port_name=NULL, *new_line=NULL, *parent_obj_name=NULL; int port_name_len=0; if (attr_ptr == NULL) return; port_name = attr_ptr->attr_value.s; port_name_len = strlen(port_name); if (port_name_len == 0) { MsgBox(TgLoadString(STID_PORT_OBJ_HAS_EMPTY_NAME), TOOL_NAME, INFO_MB); return; } attr_ptr = FindAttrWithName(port_obj->tmp_parent, "type=", NULL); if (attr_ptr != NULL && strcmp(attr_ptr->attr_value.s, "tgBroadcastWire") == 0) { /* a tgBroadcastWire object is really not a Tangram-II object */ return; } attr_ptr = FindAttrWithName(port_obj->tmp_parent, "name=", NULL); if (attr_ptr != NULL) { parent_obj_name = attr_ptr->attr_value.s; } attr_ptr = FindAttrWithName(port_obj->tmp_parent, "Initialization=", NULL); if (attr_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_FIND_INIT_ATTR_PORT_PA), (parent_obj_name==NULL ? TgLoadCachedString(CSTID_PARANED_UNKNOWN) : parent_obj_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } text_ptr = attr_ptr->obj->detail.t; minilines = (&text_ptr->minilines); for (pMiniLine=minilines->first->next; pMiniLine != NULL; pMiniLine=pMiniLine->next) { int need_to_free_tmp_buf=FALSE, blank_count=0; char *tmp_buf=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); char *attr_value=UtilStrDup(tmp_buf), *psz=NULL, *start=NULL; if (attr_value == NULL) FailAllocMessage(); for (start=attr_value; *start == ' ' || *start == '\t'; start++) { blank_count++; } if (*start != '\0') { char *prefix=NULL; if (blank_count > 0) { char saved_ch=(*start); *start = '\0'; prefix = UtilStrDup(attr_value); if (prefix == NULL) FailAllocMessage(); *start = saved_ch; } psz = strchr(start, '='); if (psz != NULL) { *psz = '\0'; if (strncmp(port_name, start, port_name_len) == 0 && (start[port_name_len] == ' ' || start[port_name_len] == '\t' || start[port_name_len] == '\0')) { /* found it */ int misc_len=strlen(&start[port_name_len]); int len=blank_count+port_name_len+(misc_len<<1)+1+ strlen(signal_name); new_line = (char*)malloc(len); if (new_line == NULL) FailAllocMessage(); sprintf(new_line, "%s%s%s=%s%s", (prefix==NULL ? "" : prefix), port_name, &start[port_name_len], &start[port_name_len], signal_name); break; } *psz = '='; } UtilFree(prefix); } UtilFree(attr_value); if (need_to_free_tmp_buf) UtilFree(tmp_buf); } if (pMiniLine == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_FIND_VAR_IN_INIT_ATTR), port_name, (parent_obj_name==NULL ? TgLoadCachedString(CSTID_PARANED_UNKNOWN) : parent_obj_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } FreeStrBlockList(pMiniLine->first_block->next); pMiniLine->first_block->next = NULL; pMiniLine->last_block = pMiniLine->first_block; DynStrSet(&pMiniLine->first_block->seg->dyn_str, new_line); RecalcTextMetrics(text_ptr, attr_ptr->obj->x, text_ptr->baseline_y); UpdTextBBox(attr_ptr->obj); } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/frontend.c���������������������������������������������������������������������������0000644�0000764�0000764�00000001670�11602233311�014752� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/frontend.c,v 1.6 2011/05/16 16:21:57 william Exp $ */ int lastFile; short *pDrawFontAsc; short *pDrawFontDes; ������������������������������������������������������������������������tgif-QPL-4.2.5/file.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000022164�11602233311�014055� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/file.e,v 1.17 2011/05/16 16:21:57 william Exp $ */ #ifndef _FILE_E_ #define _FILE_E_ extern int PRTGIF; extern int prTgifFoundColorInfo; extern char curFileName[MAXPATHLENGTH+1]; extern int curFileDefined; extern int fileVersion; extern int curFileWriteVersion; extern int importingFile; extern int mergingFile; extern int serializingFile; extern int deserializingFile; extern int psDotsPerInch; extern float printMag; extern int saveTmpOnReturn; extern int warpToWinCenter; extern float tiledPageScaling; extern char * psXOffStr[]; extern float psXOff[]; extern char * * psYOffStr; extern float * psYOff; extern float * psPageWidthInInch; extern float * psPageHeightInInch; extern char printCommand[]; extern char outputDir[]; extern char * fileMenuStr[]; extern char * savedComments; extern int savedCommentsLen; extern int saveCommentsInSaveNew; extern int usePsAdobeString; extern char adobeString[]; extern char epsfString[]; extern int readingPageNum; extern int loadedCurPageNum; extern int writeFileFailed; extern int foundGoodStateObject; extern int cmdLineHasPageNum; extern int cmdLinePageNum; extern char cmdLinePageNumStr[80]; extern int cmdLineOneFilePerPage; extern int cmdLineA4; extern int cmdLineLetter; extern int cmdLineNoShowPageInEPS; extern int cmdLineColor; extern int cmdLineRequestedColor; extern int cmdLineDumpURL; extern int cmdLineDumpURLWithHeader; extern int cmdLineDumpURLHeaderOnly; extern int cmdLineDumpURLShowStatus; extern int cmdLineDosEpsFilter; extern int cmdLinePreviewOnly; extern int tmpFileMode; extern char cmdLineTmpFileModeStr[MAXSTRING]; extern int cmdLineOpenDisplay; extern int cmdLineStdOut; extern int cmdLineWhereToPrint; extern int cmdLineTiffEPSI; extern int cmdLinePdfSetPageDevice; extern int cmdLinePsSetup; extern char cmdLineFileToExec[MAXSTRING]; extern char cmdLineProducedBy[MAXSTRING]; extern char cmdLineOpenFile[MAXSTRING]; extern char cmdLineJpegToPpm6Cmd[MAXSTRING]; extern int cmdLineQuiet; extern char cmdLineCustomPatternDir[MAXSTRING]; extern char customPatDir[MAXSTRING]; extern int generateTiffEPSI; extern int showPageInEPS; extern int gnQuit; extern int myFileBgPixel; extern int myFileFgPixel; extern char *myFileBgColorStr; extern char *myFileFgColorStr; extern XColor myFileBgColor; extern int myFileBgPixmapW; extern int myFileBgPixmapH; extern Pixmap myFileBgPixmap; extern char *myFileBgGifURL; extern char *gpszProducedBy; extern int dumpOneFilePerPage; extern int bufferAsFileForWhiteBoard; extern int flushColormapOnOpen; extern struct BBRec *gpExportClipBBox; extern int gnNumFilePSFontAliases; extern KeyValInfo *gaFilePSFontAliases; extern SpecifyPagesInfo gPagesToPrintSpec; extern GenerateByInfo gGenerateByInfo; #ifdef _INCLUDE_FROM_FILE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_FILE_C_*/ extern char * MkTempFile ARGS_DECL((char *buf, int buf_sz, char *psz_dir, char *psz_prefix)); extern int IsFiletUnSavable ARGS_DECL((void)); extern void SetUnSavableFile ARGS_DECL((int unsavable)); extern void UpdateDocumentFonts ARGS_DECL((char*)); extern void UpdatePropagatedEPSInfo ARGS_DECL((char *line, int *status)); extern void SetCmdLineDontCondense ARGS_DECL((void)); extern void SetCmdLineCondensedPS ARGS_DECL((void)); extern int FindProgramInPath ARGS_DECL((char *cmd, char *msg, int no_msg)); extern int ExecuteCmd ARGS_DECL((char*, int done_msg)); extern void CleanUpComments ARGS_DECL((void)); extern void ClearFileInfo ARGS_DECL((int clean_up_comments)); extern int OkayToCreateFile ARGS_DECL((char*)); extern void SaveObj ARGS_DECL((FILE*, struct ObjRec *ObjPtr, int Level)); extern int FileNameHasExtension ARGS_DECL((char *file_name, int file_type, int *pn_gzipped, int *pn_no_name)); extern void RemoveFileNameExtension ARGS_DECL((char*)); extern int FixDecimalPoint ARGS_DECL((char*)); extern void Save ARGS_DECL((FILE *, struct ObjRec *BotObj, int Level, int PageNumber)); extern int SaveTmpFile ARGS_DECL((char *)); extern void SaveNewFile ARGS_DECL((int SaveSelectedOnly, char *pszNewFile)); extern void SaveSymInLibrary ARGS_DECL((void)); extern void SaveFile ARGS_DECL((void)); extern void SavePages ARGS_DECL((SpecifyPagesInfo*)); extern char * ParseStr ARGS_DECL((char *Str, int C, char *Left, int LeftSz)); extern char * FindChar ARGS_DECL((int C, char *Str)); extern void SaveCreatorID ARGS_DECL((FILE *FP, struct ObjRec *ObjPtr, char *pszPrefix)); extern int ReadCreatorID ARGS_DECL((FILE *FP, struct ObjRec **ObjPtr)); extern int ReadObj ARGS_DECL((FILE *, struct ObjRec **)); extern void AdjForOldVersion ARGS_DECL((struct ObjRec *)); extern int DownloadRemoteFile ARGS_DECL((char *file_name, char **ppsz_content_type, char **ppsz_page_spec, int *pn_is_html, char *return_tmp_fname, char *final_url, int cb_final_url)); extern int ImportGivenFile ARGS_DECL((char*, int group_and_lock, int highlight)); extern void ImportFile ARGS_DECL((void)); extern int ClearBgColorInfo ARGS_DECL((int nRedraw)); extern int ClearBgPixmapInfo ARGS_DECL((int nRedraw)); extern int SetFileBgColor ARGS_DECL((void)); extern int SetFileFgColor ARGS_DECL((void)); extern int SetFileBgPixmap ARGS_DECL((void)); extern void CheckFileAttrsInLoad ARGS_DECL((void)); extern int LoadFile ARGS_DECL((char *FileName, int ObjFile, int GzippedObjFile)); extern void DumpPatFill ARGS_DECL((FILE *, int Fill, struct BBRec, int Indent, int EOL)); extern void DumpSymOutline ARGS_DECL((FILE *, struct ObjRec *)); extern int DumpBBox ARGS_DECL((FILE *, int PageOnly, struct BBRec *)); extern void ModifyOutputFileName ARGS_DECL((char *)); extern void SetPsSetup ARGS_DECL((char *)); extern void SetBopHook ARGS_DECL((char *)); extern void SetEopHook ARGS_DECL((char *)); extern int GetCmdUsingDefAndXDef ARGS_DECL((char *buf, int buf_sz, char *def_cmd, char *option, int verify_count, int msg_box_if_error)); extern void SetOutputFileName ARGS_DECL((char *psz_file_return, char *psz_ext, int *pn_short_name, char **ppsz_rest)); extern void Dump ARGS_DECL((char *)); extern void DumpPages ARGS_DECL((void)); extern void DumpOnePageInTileMode ARGS_DECL((int Row, int Col)); extern void DumpOnePageInStackMode ARGS_DECL((void)); extern void DumpOneFilePerPage ARGS_DECL((void)); extern void PrintWithCommand ARGS_DECL((char *)); extern void PrintSelectedObjs ARGS_DECL((void)); extern void SetPrintReduction ARGS_DECL((void)); extern void NewProc ARGS_DECL((void)); extern int BeforeOpenURL ARGS_DECL((int *pn_do_not_save)); extern void OpenURL ARGS_DECL((char *psz_url, int do_not_save, int *pn_need_to_check_auto_exec)); extern void AfterOpenURL ARGS_DECL((int need_to_check_auto_exec)); extern void OpenProc ARGS_DECL((char*)); extern void SetTemplate ARGS_DECL((void)); extern int QuitProc ARGS_DECL((void)); extern int SolveProc ARGS_DECL((void)); extern int SimulateProc ARGS_DECL((void)); extern int ProbeProc ARGS_DECL((void)); extern int AnimateProc ARGS_DECL((void)); extern int EscapeProc ARGS_DECL((void)); extern int RefreshFileMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateFileMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int FileMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern TgMenu *CreateRecentFilesMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern char * ReadFileIntoBuf ARGS_DECL((char *fname, unsigned int *pn_buf_sz)); extern int WriteBufIntoTmpFile ARGS_DECL((char *buf, int buf_sz, char *tmp_fname, int tmp_fname_sz)); extern void CleanUpFiles ARGS_DECL((void)); #ifdef _INCLUDE_FROM_FILE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_FILE_C_*/ #endif /*_FILE_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgificon.obj�������������������������������������������������������������������������0000644�0000764�0000764�00000001627�11602233313�015271� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������state(0,18,100,0,0,0,16,1,0,0,3,0,0,1,0,1,0,3,0,5,0,0,0,10,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgificon.obj,v 1.1 2004/06/18 23:19:38 william Exp $ % group([ polygon('yellow',4,[ 0,40,40,40,40,80,0,40],0,1,1,0,11,0,0,[ ]), polygon('yellow',4,[ 40,40,40,80,80,40,40,40],0,1,1,0,12,0,0,[ ]), polygon('yellow',4,[ 40,0,20,20,60,20,40,0],0,1,1,0,13,0,0,[ ]), polygon('yellow',4,[ 20,20,0,40,20,40,20,20],0,1,1,0,14,0,0,[ ]), polygon('yellow',5,[ 20,20,20,40,40,40,40,20,20,20],0,1,1,0,15,0,0,[ ]), polygon('yellow',4,[ 40,20,40,40,60,40,40,20],0,1,1,0,16,0,0,[ ]), polygon('yellow',5,[ 40,20,60,40,80,40,60,20,40,20],0,1,1,0,17,0,0,[ ]) ],[ ]). text('yellow',40,4,0,3,3,1,1,0,1,10,17,18,0,14,3,0,0,0,[ "T"]). text('yellow',30,24,1,1,3,1,1,0,1,9,16,19,0,12,4,0,0,0,[ "G"]). text('yellow',50,43,3,3,3,1,1,0,1,6,17,20,0,14,3,0,0,0,[ "I"]). text('yellow',30,50,2,3,3,1,1,0,1,8,17,21,0,14,3,0,0,0,[ "F"]). ���������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/ps.c���������������������������������������������������������������������������������0000644�0000764�0000764�00000071725�11602233312�013566� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/ps.c,v 1.16 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_PS_C_ #include "tgifdefs.h" #include "file.e" #include "msg.e" #include "ps.e" #include "raster.e" #include "util.e" #define DEF_PS_DICT_COUNT 3 int preDumpSetup=FALSE; int needsTgifOrigCTM=TRUE; int psUseShortHand=FALSE; char **gPsCmd=NULL; static int psDictCount=DEF_PS_DICT_COUNT; static int psUsePSAdobe=TRUE; static int psUseMinRadius=FALSE; static int psUseEllipse=FALSE; static int psUseArrow=FALSE; static int psUseArc=FALSE; static int psUsePattern=FALSE; static int psUseBWPattern=FALSE; static int psUseColorImage=FALSE; static int psUseColorPattern=FALSE; static int psUseCenterText=FALSE; static int psUseRightText=FALSE; static int psUseMiniLines=FALSE; static int psUseReencode=FALSE; static int psUseReencodeFF8=FALSE; #ifdef _PS_USE_EUC_FONT static int psUseEucFont=FALSE; #endif /* _PS_USE_EUC_FONT */ void PSUsePSAdobe() { if (preDumpSetup && !psUsePSAdobe) { psUsePSAdobe = FALSE; } } void PSUseMinRadius() { if (preDumpSetup && !psUseMinRadius) { psUseMinRadius = TRUE; psDictCount++; } } void PSUseEllipse() { if (preDumpSetup && !psUseEllipse) { psUseEllipse = TRUE; psDictCount += 2; } } void PSUseArrow() { if (preDumpSetup && !psUseArrow) { psUseArrow = TRUE; psDictCount += 2; } } void PSUseArc() { if (preDumpSetup && !psUseArc) { psUseArc = TRUE; psDictCount += 3; } } static void PSUsePattern() { if (preDumpSetup && !psUsePattern) { psUsePattern = TRUE; psDictCount += 29; } } void PSUseBWPattern() { if (preDumpSetup && !psUseBWPattern) { PSUsePattern(); psUseBWPattern = TRUE; psDictCount += 5; } } void PSUseColorImage() { if (preDumpSetup && !psUseColorImage) { psUseColorImage = TRUE; psDictCount += 13; } } void PSUseColorPattern() { if (preDumpSetup && !psUseColorPattern) { PSUsePattern(); psUseColorPattern = TRUE; psDictCount += 4; } } void PSUseCenterText() { if (preDumpSetup && !psUseCenterText) { psUseCenterText = TRUE; psDictCount += 1; } } void PSUseRightText() { if (preDumpSetup && !psUseRightText) { psUseRightText = TRUE; psDictCount += 1; } } void PSUseMiniLines() { if (preDumpSetup && !psUseMiniLines) { psUseMiniLines = TRUE; psDictCount += 3; } } typedef struct ReEncodeRec { char *font_str; struct ReEncodeRec *next; } *ReEncodePtr; static struct ReEncodeRec *topReEncodeInfo=NULL; void PSUseReencode(font_str) char *font_str; { if (preDumpSetup && !psUseReencode) { psUseReencode = TRUE; psDictCount += 2; } #ifdef _PRTGIF_USE_ISO_LATIN_1_ALWAYS if (PRTGIF && !psUseReencodeFF8) { psUseReencodeFF8 = TRUE; psDictCount += 2; } #endif /* _PRTGIF_USE_ISO_LATIN_1_ALWAYS */ if (font_str != NULL && preDumpSetup && psUseReencode) { struct ReEncodeRec *p_reencode; for (p_reencode=topReEncodeInfo; p_reencode != NULL; p_reencode=p_reencode->next) { if (strcmp(p_reencode->font_str, font_str) == 0) { return; } } p_reencode = (struct ReEncodeRec *)malloc(sizeof(struct ReEncodeRec)); if (p_reencode == NULL) FailAllocMessage(); p_reencode->font_str = UtilStrDup(font_str); p_reencode->next = topReEncodeInfo; topReEncodeInfo = p_reencode; psDictCount += 1; } } static char *gaszPsShortHand[] = { "GS", /* "gsave", */ "GR", /* "grestore", */ "NP", /* "newpath", */ "CP", /* "closepath", */ "CHP", /* "charpath", */ "CT", /* "curveto", */ "L", /* "lineto", */ "RL", /* "rlineto", */ "M", /* "moveto", */ "RM", /* "rmoveto", */ "S", /* "stroke", */ "F", /* "fill", */ "TR", /* "translate", */ "RO", /* "rotate", */ "SC", /* "scale", */ "MU", /* "mul", */ "DI", /* "div", */ "DU", /* "dup", */ "NE", /* "neg", */ "AD", /* "add", */ "SU", /* "sub", */ "PO", /* "pop", */ "EX", /* "exch", */ "CO", /* "concat", */ "CL", /* "clip", */ "EC", /* "eoclip", */ "EF", /* "eofill", */ "IM", /* "image", */ "IMM", /* "imagemask", */ "ARY", /* "array", */ "SG", /* "setgray", */ "RG", /* "setrgbcolor", */ "SD", /* "setdash", */ "W", /* "setlinewidth", */ "SM", /* "setmiterlimit", */ "SLC", /* "setlinecap", */ "SLJ", /* "setlinejoin", */ "SH", /* "show", */ "FF", /* "findfont", */ "MS", /* "makefont setfont", */ "AR", /* "arcto 4 {pop} repeat", */ "CURP", /* "currentpoint", */ "FLAT", /* "flattenpath strokepath clip newpath", */ "\tTGSM", /* "tgiforigctm setmatrix", */ "\tTGRM", /* "savematrix setmatrix", */ NULL }; static char *gaszPsLongHand[] = { /* "GS", */ "gsave", /* "GR", */ "grestore", /* "NP", */ "newpath", /* "CP", */ "closepath", /* "CHP", */ "charpath", /* "CT", */ "curveto", /* "L", */ "lineto", /* "RL", */ "rlineto", /* "M", */ "moveto", /* "RM", */ "rmoveto", /* "S", */ "stroke", /* "F", */ "fill", /* "TR", */ "translate", /* "RO", */ "rotate", /* "SC", */ "scale", /* "MU", */ "mul", /* "DI", */ "div", /* "DU", */ "dup", /* "NE", */ "neg", /* "AD", */ "add", /* "SU", */ "sub", /* "PO", */ "pop", /* "EX", */ "exch", /* "CO", */ "concat", /* "CL", */ "clip", /* "EC", */ "eoclip", /* "EF", */ "eofill", /* "IM", */ "image", /* "IMM", */ "imagemask", /* "ARY", */ "array", /* "SG", */ "setgray", /* "RG", */ "setrgbcolor", /* "SD", */ "setdash", /* "W", */ "setlinewidth", /* "SM", */ "setmiterlimit", /* "SLC", */ "setlinecap", /* "SLJ", */ "setlinejoin", /* "SH", */ "show", /* "FF", */ "findfont", /* "MS", */ "makefont setfont", /* "AR", */ "arcto 4 {pop} repeat", /* "CURP", */ "currentpoint", /* "FLAT", */ "flattenpath strokepath clip newpath", /* "TGSM", */ "\ttgiforigctm setmatrix", /* "TGRM", */ "\tsavematrix setmatrix", NULL }; void PSDontUseShortHand() { if (preDumpSetup && psUseShortHand) { char **ppsz=NULL; psUseShortHand = FALSE; psDictCount -= 1; for (ppsz=gaszPsShortHand; *ppsz != NULL; ppsz++) { psDictCount--; } gPsCmd = gaszPsLongHand; } } void PSUseShortHand() { if (preDumpSetup && !psUseShortHand) { char **ppsz=NULL; psUseShortHand = TRUE; psDictCount += 1; for (ppsz=gaszPsShortHand; *ppsz != NULL; ppsz++) { psDictCount++; } gPsCmd = gaszPsShortHand; } } #ifdef _PS_USE_EUC_FONT void PSUseEucFont() { if (preDumpSetup && !psUseEucFont) { psUseEucFont = TRUE; psDictCount += 4; } } #endif /* _PS_USE_EUC_FONT */ static void CleanUpReEncodeInfo() { struct ReEncodeRec *p_next_reencode; for ( ; topReEncodeInfo != NULL; topReEncodeInfo=p_next_reencode) { p_next_reencode = topReEncodeInfo->next; if (topReEncodeInfo->font_str != NULL) free(topReEncodeInfo->font_str); free(topReEncodeInfo); } } void ResetPSInfo() { psDictCount = DEF_PS_DICT_COUNT; preDumpSetup = TRUE; needsTgifOrigCTM = TRUE; psUsePSAdobe = TRUE; #ifdef INVERT_CTM_BUG UseMinRadius(); #else /* ~INVERT_CTM_BUG */ psUseMinRadius = FALSE; #endif /* INVERT_CTM_BUG */ psUseEllipse = FALSE; psUseArrow = FALSE; psUseArc = FALSE; psUsePattern = FALSE; psUseBWPattern = FALSE; psUseColorImage = FALSE; psUseColorPattern = FALSE; psUseCenterText = FALSE; psUseRightText = FALSE; psUseMiniLines = FALSE; psUseReencode = FALSE; psUseReencodeFF8 = FALSE; psUseShortHand = FALSE; #ifdef _PS_USE_EUC_FONT psUseEucFont = FALSE; #endif /* _PS_USE_EUC_FONT */ CleanUpReEncodeInfo(); } void DoneResetPSInfo() { preDumpSetup = FALSE; CleanUpReEncodeInfo(); } static char *psAdobeMacro[] = { "%", "%\tDue to bugs in Transcript, the 'PS-Adobe-' stuff is omitted from line 1", "%", "", NULL }; static char *psMinRadiusMacro[] = { "%", "%\tUsing a zero value radius for an ellipse or an arc would result", "%\t\tin a non-invertible CTM matrix which causes problem when this", "%\t\twhen this PostScript is wrapped inside other routines, such as", "%\t\tthe multi.ps package from", "%\t\tftp.ucc.su.oz.au:/pub/ps_printing/multi. You can overcome such", "%\t\terror by uncommenting the sole line of the procedure below:", "%", "/tgif_min_radius", " {", "% dup 0.01 lt { pop 0.01 } if", " } bind def", "", NULL }; static char *psEllipseMacro[] = { "/tgifellipsedict 6 dict def", "tgifellipsedict /mtrx matrix put", "", "/TGEL % tgifellipse", " { tgifellipsedict begin", " /yrad exch def", " /xrad exch def", " /y exch def", " /x exch def", " /savematrix mtrx currentmatrix def", " x y translate", " xrad yrad scale", " 0 0 1 0 360 arc", " savematrix setmatrix", " end", " } def", "", NULL }; static char *psArrowMacro[] = { "/tgifarrowtipdict 8 dict def", "tgifarrowtipdict /mtrx matrix put", "", "/TGAT % tgifarrowtip", " { tgifarrowtipdict begin", " /dy exch def", " /dx exch def", " /h exch def", " /w exch def", " /y exch def", " /x exch def", " /savematrix mtrx currentmatrix def", " x y translate", " dy dx atan rotate", " 0 0 moveto", " w neg h lineto", " w neg h neg lineto", " savematrix setmatrix", " end", " } def", "", NULL }; static char *psArcMacro[] = { "/tgifarcdict 8 dict def", "tgifarcdict /mtrx matrix put", "", "/TGAN % tgifarcn", " { tgifarcdict begin", " /endangle exch def", " /startangle exch def", " /yrad exch def", " /xrad exch def", " /y exch def", " /x exch def", " /savematrix mtrx currentmatrix def", " x y translate", " xrad yrad scale", " 0 0 1 startangle endangle arc", " savematrix setmatrix", " end", " } def", "", "/TGAR % tgifarc", " { tgifarcdict begin", " /endangle exch def", " /startangle exch def", " /yrad exch def", " /xrad exch def", " /y exch def", " /x exch def", " /savematrix mtrx currentmatrix def", " x y translate", " xrad yrad scale", " 0 0 1 startangle endangle arcn", " savematrix setmatrix", " end", " } def", "", NULL }; static char *psBWPatternMacro[] = { "/tgifsetuserscreendict 22 dict def", "tgifsetuserscreendict begin", " /tempctm matrix def", " /temprot matrix def", " /tempscale matrix def", "", " /concatprocs", " { /proc2 exch cvlit def", " /proc1 exch cvlit def", " /newproc proc1 length proc2 length add array def", " newproc 0 proc1 putinterval", " newproc proc1 length proc2 putinterval", " newproc cvx", " } def", " /resmatrix matrix def", " /findresolution", " { 72 0 resmatrix defaultmatrix dtransform", " /yres exch def /xres exch def", " xres dup mul yres dup mul add sqrt", " } def", "end", "", "/tgifsetuserscreen", " { tgifsetuserscreendict begin", " /spotfunction exch def", " /screenangle exch def", " /cellsize exch def", "", " /m tempctm currentmatrix def", " /rm screenangle temprot rotate def", " /sm cellsize dup tempscale scale def", "", " sm rm m m concatmatrix m concatmatrix pop", "", " 1 0 m dtransform /y1 exch def /x1 exch def", "", " /veclength x1 dup mul y1 dup mul add sqrt def", " /frequency findresolution veclength div def", "", " /newscreenangle y1 x1 atan def", "", " m 2 get m 1 get mul m 0 get m 3 get mul sub 0 gt", "", " {{neg} /spotfunction load concatprocs", " /spotfunction exch def", " } if", "", " frequency newscreenangle /spotfunction load setscreen", " end", " } def", "", "/tgifsetpatterndict 18 dict def", "tgifsetpatterndict begin", " /bitison", " { /ybit exch def /xbit exch def", " /bytevalue bstring ybit bwidth mul xbit 8 idiv add get def", "", " /mask 1 7 xbit 8 mod sub bitshift def", " bytevalue mask and 0 ne", " } def", "end", "", "/tgifbitpatternspotfunction", " { tgifsetpatterndict begin", " /y exch def /x exch def", "", " /xindex x 1 add 2 div bpside mul cvi def", " /yindex y 1 add 2 div bpside mul cvi def", "", " xindex yindex bitison", " { /onbits onbits 1 add def 1 }", " { /offbits offbits 1 add def 0 }", " ifelse", " end", " } def", "", "/tgifsetpattern", " { tgifsetpatterndict begin", " /cellsz exch def", " /angle exch def", " /bwidth exch def", " /bpside exch def", " /bstring exch def", "", " /onbits 0 def /offbits 0 def", " cellsz angle /tgifbitpatternspotfunction load tgifsetuserscreen", " {} settransfer", " offbits offbits onbits add div setgray", " end", " } def", "", NULL }; static char *psColorImageMacro[] = { "/tgifxpmdict 4 dict def", "/tgifbwpicstr 1 string def", "/tgifcolorpicstr 3 string def", "", "/tgifsetpixels { tgifxpmdict begin /pixels exch def end } def", "", "/tgifsetpix { tgifxpmdict begin pixels 3 1 roll putinterval end } def", "", "/tgifsetppmtruetranspix", " { tgifxpmdict begin", " 3 array /transpixels exch def", " transpixels 2 3 -1 roll put", " transpixels 1 3 -1 roll put", " transpixels 0 3 -1 roll put", " /curpix 3 array def", " end", " } def", "", "/tgifcolorspot", " { tgifxpmdict begin", " /index exch def", " pixels index 3 mul 3 getinterval aload pop", " 255 mul cvi tgifcolorpicstr 2 3 -1 roll put", " 255 mul cvi tgifcolorpicstr 1 3 -1 roll put", " 255 mul cvi tgifcolorpicstr 0 3 -1 roll put", " tgifcolorpicstr", " end", " } def", "", "/tgifcolordict 4 dict def", "", "/colorimage where", " { pop }", " { /colorimage", " { tgifcolordict begin", " pop pop pop pop pop", " /ih exch def", " /iw exch def", " /x 0 def", " /y 0 def", " 1 1 ih", " { pop 1 1 iw", " { pop", " 3 { currentfile tgifbwpicstr readhexstring pop 0 get 255 div } repeat setrgbcolor", " newpath x y moveto 1 0 rlineto 0 1 rlineto -1 0 rlineto", " closepath fill", " /x x 1 add def", " } for", " /y y 1 add def", " /x 0 def", " } for", " end", " } def", " } ifelse", "", "/tgiftranscolorspot", " { tgifxpmdict begin", " /index exch def", " pixels index 3 mul 3 getinterval aload pop", " dup 0 lt { pop pop pop false } { setrgbcolor true } ifelse", " end", " } def", "", "/tgiftranscolorimage", " { tgifcolordict begin", " pop pop pop pop pop", " /ih exch def", " /iw exch def", " /x 0 def", " /y 0 def", " 1 1 ih", " { pop 1 1 iw", " { pop currentfile", " tgifbwpicstr readhexstring pop 0 get tgiftranscolorspot", " { newpath x y moveto 1 0 rlineto 0 1 rlineto -1 0 rlineto", " closepath fill", " }", " if", " /x x 1 add def", " } for", " /y y 1 add def", " /x 0 def", " } for", " end", " } def", "", "/tgiftransppmtruecolorspot", " { tgifxpmdict begin", " /count 0 def", " curpix 2 3 -1 roll put", " curpix 1 3 -1 roll put", " curpix 0 3 -1 roll put", " curpix 0 get transpixels 0 get ne { /count count 1 add def } if", " curpix 1 get transpixels 1 get ne { /count count 1 add def } if", " curpix 2 get transpixels 2 get ne { /count count 1 add def } if", " count 0 eq { false } { curpix 0 get 255 div curpix 1 get 255 div curpix 2 get 255 div setrgbcolor true } ifelse", " end", " } def", "", "/tgiftransppmtruecolorimage", " { tgifcolordict begin", " pop pop pop pop pop", " /ih exch def", " /iw exch def", " /x 0 def", " /y 0 def", " 1 1 ih", " { pop 1 1 iw", " { pop", " 3 { currentfile tgifbwpicstr readhexstring pop 0 get } repeat tgiftransppmtruecolorspot", " { newpath x y moveto 1 0 rlineto 0 1 rlineto -1 0 rlineto", " closepath fill", " }", " if", " /x x 1 add def", " } for", " /y y 1 add def", " /x 0 def", " } for", " end", " } def", "", NULL }; static char *psColorPatternMacro[] = { "/tgifpatdict 12 dict def", "", "/tgifpatbyte", " { currentdict /retstr get exch", " bytesperrow mul", " pat i cellh mod bytesperrow mul bytesperrow getinterval putinterval", " } def", "", "/tgifpatproc", " { 0 1 cells_wd 1 sub {tgifpatbyte} for retstr", " /i i 1 add def", " } def", "", "/TGPF % tgifpatfill", " { tgifpatdict begin", " /h exch def", " /w exch def", " /lty exch def", " /ltx exch def", " /cellh exch def", " /cellw exch def", " /pat exch def", "", " /cells_wd w cellw div cvi def", " /bytesperrow cellw 8 div ceiling cvi def", " /retstr cells_wd bytesperrow mul string def", " /i 0 def", "", " tgiforigctm setmatrix", " ltx lty translate", " w h true [1 0 0 1 0 0] {tgifpatproc} imagemask", " ltx neg lty neg translate", " end", " } def", "", NULL }; /* * No longer needed. * Now psDynamicPrintPatternDef() generates these from pixmap data. * * static char *psPatternMacro[] = { * "/pat3 <8000000008000000> def", * "/pat4 <8800000022000000> def", * "/pat5 <8800220088002200> def", * "/pat6 <8822882288228822> def", * "/pat7 <aa55aa55aa55aa55> def", * "/pat8 <77dd77dd77dd77dd> def", * "/pat9 <77ffddff77ffddff> def", * "/pat10 <77ffffffddffffff> def", * "/pat11 <7ffffffff7ffffff> def", * "/pat12 <8040200002040800> def", * "/pat13 <40a00000040a0000> def", * "/pat14 <ff888888ff888888> def", * "/pat15 <ff808080ff080808> def", * "/pat16 <f87422478f172271> def", * "/pat17 <038448300c020101> def", * "/pat18 <081c22c180010204> def", * "/pat19 <8080413e080814e3> def", * "/pat20 <8040201008040201> def", * "/pat21 <8844221188442211> def", * "/pat22 <77bbddee77bbddee> def", * "/pat23 <c1e070381c0e0783> def", * "/pat24 <7fbfdfeff7fbfdfe> def", * "/pat25 <3e1f8fc7e3f1f87c> def", * "/pat26 <0102040810204080> def", * "/pat27 <1122448811224488> def", * "/pat28 <eeddbb77eeddbb77> def", * "/pat29 <83070e1c3870e0c1> def", * "/pat30 <fefdfbf7efdfbf7f> def", * "/pat31 <7cf8f1e3c78f1f3e> def", * "", * NULL * }; */ void psDynamicPrintPatternDef(FP, index) FILE *FP; int index; { int b=0, numbytes=0, need_to_free=FALSE; unsigned char *bytes=NULL; bytes = (unsigned char *)GetPatternBytes(index, &numbytes, &need_to_free); fprintf(FP, "/pat%d <", index); for (b=0; b < numbytes; b++) { fprintf(FP, "%02hhx", ByteReverse(bytes[b])); } fprintf(FP, "> def\n"); if (need_to_free) UtilFree((char*)bytes); } static char *psCenterTextMacro[] = { "/TGCTX { dup stringwidth pop 2 div neg 0 rmoveto } def", "", NULL }; static char *psMiniLinesMacro[] = { "/TGMAX", " { exch dup 3 1 roll exch dup 3 1 roll gt { pop } { exch pop } ifelse", " } def", "/TGMIN", " { exch dup 3 1 roll exch dup 3 1 roll lt { pop } { exch pop } ifelse", " } def", "/TGSW { stringwidth pop } def", "/tgifstrw 0 def", "", NULL }; static char *psRightTextMacro[] = { "/TGRTX { dup stringwidth pop neg 0 rmoveto } def", "", NULL }; static char *psReencodeMacro[] = { "/tgifreencsmalldict 12 dict def", "/tgifReEncodeSmall", " { tgifreencsmalldict begin", " /newcodesandnames exch def", " /newfontname exch def", " /basefontname exch def", "", " /basefontdict basefontname findfont def", " /newfont basefontdict maxlength dict def", "", " basefontdict", " { exch dup /FID ne", #ifdef GS_REENCODE_BUG " 1 index /UniqueID ne and", #endif " { dup /Encoding eq", " { exch dup length array copy newfont 3 1 roll put }", " { exch newfont 3 1 roll put }", " ifelse", " }", " { pop pop }", " ifelse", " }", " forall", "", " newfont /FontName newfontname put", " newcodesandnames aload pop", "", " newcodesandnames length 2 idiv", " { newfont /Encoding get 3 1 roll put}", " repeat", "", " newfontname newfont definefont pop", " end", " } def", "", NULL }; #ifdef _PRTGIF_USE_ISO_LATIN_1_ALWAYS static char *psReEncodeFF8Macro[] = { "/TGFF8", " { FontDirectory 1 index known", " { pop findfont exch pop }", " { 1 index 4 1 roll tgifReEncodeSmall findfont } ifelse", " } bind def", "", NULL }; #endif /* _PRTGIF_USE_ISO_LATIN_1_ALWAYS */ static char *psShortHandMacro[] = { "/bd { bind def } bind def", "", NULL }; #ifdef _PS_USE_EUC_FONT static char *psEucFontMacro[] = { "%%Title: eucfont.ps", "% old eucfont.ps(OCFeucfont) and new eucfont.ps(CIDeucfont) were combined.", "% 1996-09, kawamata@sra.co.jp", "% Sample Usage:", "% Operands are only font names permitted. Don't put fontdict itself.", "% /Courier-Ryumin /Courier /Ryumin-Light-EUC-V eucfont", "", "%%Title: CIDeucfont.ps", "%%Creator: yohtaki@cis.ibaraki.ac.jp", "%%CreationDate: 1996-9-29", "%%EndComments", "%", "% <newfont> <asciifont> <kanjifont> CIDeucfont", "/CIDeucfont {", "dup findfont /WMode get 1 eq 4 1 roll % push direction info.", "12 dict begin", " /CIDInit /ProcSet findresource begin", " exch [ 3 1 roll ] beginrearrangedfont", " 3 -1 roll { % pop direction info", " /WMode 1 def % vertical font", #ifdef _VERT_FONT_OFFSET_POINT_4 " 0 beginusematrix [ 0 1 -1 0 0 0.4 ] endusematrix", #else /* ~_VERT_FONT_OFFSET_POINT_4 */ " 0 beginusematrix [ 0 1 -1 0 0 0.3 ] endusematrix", #endif /* _VERT_FONT_OFFSET_POINT_4 */ " } if", " 1 usefont", " 1 beginbfrange", " <00> <7F> <00>", " endbfrange", " endrearrangedfont", " end", "end", "} def", "", "%%Title: OCFeucfont.ps", "%%Creator: shikida@cs.titech.ac.jp, ueno@cs.titech.ac.jp", "%%CreationDate: 1991-2-27", "%%EndComments", "% <font> OCFcopyfont <font>", "/OCFcopyfont {", " dup maxlength 1 add dict begin", " {", " 1 index /FID ne 2 index /UniqueID ne and", " {def} {pop pop} ifelse", " } forall", " currentdict", " end", "} bind def", "% <newfont> <asciifont> <kanjifont> OCFeucfont", "/OCFeucfont {", " 12 dict begin", " dup type /nametype eq { findfont } if", " dup /WMode known {", " dup /WMode get /WMode exch def", " WMode 1 eq {", #ifdef _VERT_FONT_OFFSET_POINT_4 " [0.0 1.0 -1.0 0.0 0.0 0.40] makefont", #else /* ~_VERT_FONT_OFFSET_POINT_4 */ " [0.0 1.0 -1.0 0.0 0.0 0.30] makefont", #endif /* _VERT_FONT_OFFSET_POINT_4 */ " } if", " } if", " OCFcopyfont dup begin", " /Encoding Encoding", " FMapType dup 2 eq {", " pop 128 128", " } { 5 eq {", " 256 256", " } {", " /compositefont errordict /invalidfont get exec", " } ifelse", " } ifelse", " getinterval def", " end", " /kanjifont exch definefont", " exch", "", " dup type /nametype eq { findfont } if", " exch", "", " /FDepVector [ 4 2 roll ] def", " /FontType 0 def", " /FMapType 4 def", " /FontMatrix matrix def", " /Encoding [ 0 1 ] def", " /FontBBox {0 0 0 0} def", " dup /FontName exch def", " currentdict", " end", " definefont pop", "} def", "", "% <newfont> <asciifont> <kanjifont> eucfont", "/eucfont {", " dup findfont", " /FMapType get 9 eq", " { CIDeucfont}", " { OCFeucfont} ifelse", "} def", "", NULL }; #endif /* _PS_USE_EUC_FONT */ void DumpPSMacro(FP) FILE *FP; { register int i; fprintf(FP, "\n"); if (!psUsePSAdobe) { for (i=0; psAdobeMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psAdobeMacro[i]); } } fprintf(FP, "/tgifdict %1d dict def\n", psDictCount); fprintf(FP, "tgifdict begin\n"); fprintf(FP, "\n"); if (psUseMinRadius) { for (i=0; psMinRadiusMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psMinRadiusMacro[i]); } } if (psUseEllipse) { for (i=0; psEllipseMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psEllipseMacro[i]); } } if (psUseArrow) { for (i=0; psArrowMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psArrowMacro[i]); } } if (psUseArc) { for (i=0; psArcMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psArcMacro[i]); } } if (psUseBWPattern) { for (i=0; psBWPatternMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psBWPatternMacro[i]); } } if (psUseColorImage) { for (i=0; psColorImageMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psColorImageMacro[i]); } } if (psUseColorPattern) { for (i=0; psColorPatternMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psColorPatternMacro[i]); } } if (psUsePattern) { /* * for (i=0; psPatternMacro[i] != NULL; i++) { * fprintf(FP, "%s\n", psPatternMacro[i]); * } */ for (i=3; i < 32; i++) { psDynamicPrintPatternDef(FP, i); } fprintf(FP, "\n"); } if (psUseCenterText) { for (i=0; psCenterTextMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psCenterTextMacro[i]); } } if (psUseRightText) { for (i=0; psRightTextMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psRightTextMacro[i]); } } if (psUseMiniLines) { for (i=0; psMiniLinesMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psMiniLinesMacro[i]); } } #ifdef _PRTGIF_USE_ISO_LATIN_1_ALWAYS if (PRTGIF && psUseReencodeFF8) { for (i=0; psReEncodeFF8Macro[i] != NULL; i++) { fprintf(FP, "%s\n", psReEncodeFF8Macro[i]); } DumpReEncodeVector(FP, "latin1", ".vec", NULL); } #endif /* _PRTGIF_USE_ISO_LATIN_1_ALWAYS */ if (psUseReencode) { for (i=0; psReencodeMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psReencodeMacro[i]); } } if (psUseShortHand) { for (i=0; psShortHandMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psShortHandMacro[i]); } for (i=0; gaszPsLongHand[i] != NULL; i++) { if (*gaszPsLongHand[i] == '\t') { fprintf(FP, "/%s { %s } def\n", &(gaszPsShortHand[i])[1], &(gaszPsLongHand[i])[1]); } else { fprintf(FP, "/%s { %s } bd\n", gaszPsShortHand[i], gaszPsLongHand[i]); } } fprintf(FP, "\n"); gPsCmd = gaszPsShortHand; } else { gPsCmd = gaszPsLongHand; } #ifdef _PS_USE_EUC_FONT if (psUseEucFont) { for (i=0; psEucFontMacro[i] != NULL; i++) { fprintf(FP, "%s\n", psEucFontMacro[i]); } } #endif /* _PS_USE_EUC_FONT */ } int ParsePsAdobeString(buf, use_ps_adobe_string, adobe_str, epsf_str) char *buf, *adobe_str, *epsf_str; int *use_ps_adobe_string; { if (UtilStrICmp("false", buf) == 0 || UtilStrICmp("no", buf) == 0) { *use_ps_adobe_string = FALSE; } else if (UtilStrICmp("true", buf) == 0 || UtilStrICmp("yes", buf) == 0) { *use_ps_adobe_string = TRUE; } else if (*buf >= '0' && *buf <= '9') { char *c_ptr=buf, *c_ptr1=NULL; *use_ps_adobe_string = TRUE; for (c_ptr1=c_ptr; *c_ptr1 != '\0'; c_ptr1++) { if (*c_ptr1 == '/') { *c_ptr1 = ' '; break; } } sscanf(c_ptr, "%s", adobe_str); c_ptr = &c_ptr[strlen(adobe_str)]; switch (*c_ptr) { case '\0': break; case ' ': c_ptr++; if (*c_ptr >= '0' && *c_ptr <= '9') { sscanf(c_ptr, "%s", epsf_str); } else { return FALSE; } break; default: return FALSE; } } else { return FALSE; } return TRUE; } void CleanUpPS() { } void InitPS() { } �������������������������������������������tgif-QPL-4.2.5/tgtwb5xl.e���������������������������������������������������������������������������0000644�0000764�0000764�00000004070�11602233313�014714� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgtwb5xl.e,v 1.10 2011/05/16 16:22:00 william Exp $ */ #ifndef _NO_TGTWB5 #ifndef _TGTWB5XL_E_ #define _TGTWB5XL_E_ #define MAXZYFH_CHARS 16 #define PH_Er 8 #define PH_An 12 #define PH_En (PH_An+1) #define PH_Ang (PH_An+2) #define PH_Eng (PH_An+3) #define PH_Ai 16 #define PH_Ei (PH_Ai+1) #define PH_Ao (PH_Ai+2) #define PH_Ou (PH_Ai+3) #define PH_A 20 #define PH_O (PH_A+1) #define PH_E (PH_A+2) #define PH_Eh (PH_A+3) #define PH_Y 24 #define PH_W (PH_Y+1) #define PH_Yu (PH_Y+2) #define PH_Z 28 #define PH_C (PH_Z+1) #define PH_S (PH_Z+2) #define PH_Zh 32 #define PH_Ch (PH_Zh+1) #define PH_Sh (PH_Zh+2) #define PH_R (PH_Zh+3) #define PH_J 36 #define PH_Q (PH_J+1) #define PH_X (PH_J+2) #define PH_G 40 #define PH_K (PH_G+1) #define PH_H (PH_G+2) #define PH_D 44 #define PH_T (PH_D+1) #define PH_N (PH_D+2) #define PH_L (PH_D+3) #define PH_B 48 #define PH_P (PH_B+1) #define PH_M (PH_B+2) #define PH_F (PH_B+3) extern char *firstLargeTransTbl[]; extern char *secondLargeTransTbl[]; extern char *thirdLargeTransTbl[]; extern char *fourthLargeTransTbl[]; extern char *singleExtention[]; extern char *pinyin_et_big5[]; extern char *pinyin_gb2312[]; #endif /*_TGTWB5XL_E_*/ #endif /* ~_NO_TGTWB5 */ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/eq4-2x-nowin-jpg.sym�����������������������������������������������������������������0000644�0000764�0000764�00000033571�11602233311�016454� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.2.3 state(0,37,100.000,0,0,0,8,1,3,1,1,0,0,1,0,1,0,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/eq4-2x-nowin-jpg.sym,v 1.1 2010/02/05 04:44:20 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(16,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#00ffff", 0, 65535, 65535, 0, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "#42ff9c", 16962, 65535, 40092, 16896, 65280, 39936, 1, "#4040ff", 16448, 16448, 65535, 16384, 16384, 65280, 1, "#c0c0c0", 49344, 49344, 49344, 49152, 49152, 49152, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1 ]). slideshow_info('',-20,-20). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). dont_reencode("UtopiaFS:FFDingbests:ZapfDingbats"). ps_font_aliases([ "UtopiaFS-Regular=Utopia-Regular", "UtopiaFS-Bold=Utopia-Bold", "UtopiaFS-Italic=Utopia-Italic", "UtopiaFS-BoldItalic=Utopia-BoldItalic", "FooBar-Regular=Utopia-Regular", "FooBar-Bold=Utopia-Bold", "FooBar-Italic=Utopia-Italic", "FooBar-BoldItalic=Utopia-BoldItalic" ]). objshadow_info('#c0c0c0',2,2). rotate_pivot(0,0,0,0). spline_tightness(1). right_margin(1,480597). ps_char_subs("foo",[ "8#241/Aogonek", "8#306/Cacute", "8#312/eogonek" ]). ps_font_need_char_subs([ "FooBar-Regular=foo", "FooBar-Bold=foo", "FooBar-Italic=foo", "FooBar-BoldItalic=foo" ]). page(1,"2x resolution LaTeX equation symbol.",1,''). sym([ polygon('#0000ff','',5,[ 64,132,68,132,68,128,64,128,64,132],0,1,0,0,212,0,0,0,0,0,'1',0, "00",[ ]) ], 1116,0,0,[ attr("footer=", "", 0, 1, 0, text('#ff00ff',64,-19,3,0,1,112,42,613,11,3,0,0,0,0,2,112,42,0,0,"",0,0,0,0,-8,'',[ minilines(112,42,0,0,0,0,0,[ mini_line(56,11,3,0,0,0,[ str_block(0,56,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,56,11,3,0,0,0,0,0,0,0, "footer=")]) ]), mini_line(8,11,3,0,0,0,[ str_block(0,8,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,8,11,3,0,0,0,0,0,0,0, "%")]) ]), mini_line(112,11,3,0,0,0,[ str_block(0,112,11,3,0,-3,0,0,0,[ str_seg('#0000ff','Courier',0,80640,112,11,3,0,-3,0,0,0,0,0, "\\end{document}")]) ]) ])])), attr("header=", "", 0, 1, 0, text('#ff00ff',240,-19,11,0,1,240,154,608,11,3,0,0,0,0,2,240,154,0,0,"",0,0,0,0,-8,'',[ minilines(240,154,0,0,0,0,0,[ mini_line(56,11,3,0,0,0,[ str_block(0,56,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,56,11,3,0,0,0,0,0,0,0, "header=")]) ]), mini_line(232,11,3,0,0,0,[ str_block(0,232,11,3,0,-3,0,0,0,[ str_seg('#0000ff','Courier',0,80640,232,11,3,0,-3,0,0,0,0,0, "\\documentstyle[12pt]{article}")]) ]), mini_line(144,11,3,0,0,0,[ str_block(0,144,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,11,3,0,0,0,0,0,0,0, "\\oddsidemargin=0in")]) ]), mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,0,0,0,0,0,0, "\\textwidth=6.5in")]) ]), mini_line(112,11,3,0,0,0,[ str_block(0,112,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,112,11,3,0,0,0,0,0,0,0, "\\topmargin=0in")]) ]), mini_line(136,11,3,0,0,0,[ str_block(0,136,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,136,11,3,0,-1,0,0,0,0,0, "\\textheight=609pt")]) ]), mini_line(104,11,3,0,0,0,[ str_block(0,104,11,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,11,3,0,-1,0,0,0,0,0, "\\parskip=14pt")]) ]), mini_line(240,11,3,0,0,0,[ str_block(0,240,11,3,0,-3,0,0,0,[ str_seg('#0000ff','Courier',0,80640,240,11,3,0,-3,0,0,0,0,0, "\\setlength{\\unitlength}{0.5cm}")]) ]), mini_line(136,11,3,0,0,0,[ str_block(0,136,11,3,0,-3,0,0,0,[ str_seg('#0000ff','Courier',0,80640,136,11,3,0,-3,0,0,0,0,0, "\\pagestyle{empty}")]) ]), mini_line(128,11,3,0,0,0,[ str_block(0,128,11,3,0,-3,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,11,3,0,-3,0,0,0,0,0, "\\begin{document}")]) ]), mini_line(8,11,3,0,0,0,[ str_block(0,8,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,8,11,3,0,0,0,0,0,0,0, "%")]) ]) ])])), attr("exec=", "", 0, 1, 0, text('blue',64,-270,8,0,1,424,112,1483,11,3,0,0,0,0,2,424,112,0,0,"",0,0,0,0,-259,'',[ minilines(424,112,0,0,0,0,0,[ mini_line(40,11,3,0,0,0,[ str_block(0,40,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,40,11,3,0,0,0,0,0,0,0, "exec=")]) ]), mini_line(336,11,3,0,0,0,[ str_block(0,336,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,336,11,3,0,-3,0,0,0,0,0, " mktemp(\"/tmp/TgifXXXXXX\",\"file_name\");")]) ]), mini_line(416,11,3,0,0,0,[ str_block(0,416,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,416,11,3,0,-3,0,0,0,0,0, " write_attr_into_file(header,\"$(file_name).tex\");")]) ]), mini_line(392,11,3,0,0,0,[ str_block(0,392,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,392,11,3,0,-3,0,0,0,0,0, " append_attr_into_file(eq,\"$(file_name).tex\");")]) ]), mini_line(424,11,3,0,0,0,[ str_block(0,424,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,424,11,3,0,-3,0,0,0,0,0, " append_attr_into_file(footer,\"$(file_name).tex\");")]) ]), mini_line(144,11,3,0,0,0,[ str_block(0,144,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,144,11,3,0,-3,0,0,0,0,0, " launch(\"cmd\");")]) ]), mini_line(328,11,3,0,0,0,[ str_block(0,328,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,328,11,3,0,-3,0,0,0,0,0, " update_xpm_child(\"$(file_name).jpg\");")]) ]), mini_line(168,11,3,0,0,0,[ str_block(0,168,11,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,168,11,3,0,-4,0,0,0,0,0, " launch(\"cleanup\")")]) ]) ])])), attr("cmd=", "", 0, 1, 0, text('blue',64,-150,5,0,1,552,70,1505,11,3,0,0,0,0,2,552,70,0,0,"",0,0,0,0,-139,'',[ minilines(552,70,0,0,0,0,0,[ mini_line(32,11,3,0,0,0,[ str_block(0,32,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,32,11,3,0,0,0,0,0,0,0, "cmd=")]) ]), mini_line(96,11,3,0,0,0,[ str_block(0,96,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,96,11,3,0,-3,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(184,11,3,0,0,0,[ str_block(0,184,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,184,11,3,0,-3,0,0,0,0,0, " latex $(file_name);")]) ]), mini_line(400,11,3,0,0,0,[ str_block(0,400,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,400,11,3,0,-3,0,0,0,0,0, " dvips -E -n 1 -o $(file_name).ps $(file_name);")]) ]), mini_line(552,11,3,0,0,0,[ str_block(0,552,11,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,552,11,3,0,-3,0,0,0,0,0, " convert -scale 25% -density 576 $(file_name).ps $(file_name).jpg;")]) ]) ])])), attr("cleanup=", "", 0, 1, 0, text('blue',64,-70,3,0,1,480,42,1392,11,3,0,0,0,0,2,480,42,0,0,"",0,0,0,0,-59,'',[ minilines(480,42,0,0,0,0,0,[ mini_line(64,11,3,0,0,0,[ str_block(0,64,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,64,11,3,0,0,0,0,0,0,0, "cleanup=")]) ]), mini_line(480,11,3,0,0,0,[ str_block(0,480,11,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,480,11,3,0,-1,0,0,0,0,0, " rm -f $(file_name).tex $(file_name).aux $(file_name).dvi")]) ]), mini_line(456,11,3,0,0,0,[ str_block(0,456,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,456,11,3,0,0,0,0,0,0,0, " $(file_name).log $(file_name).ps $(file_name).jpg")]) ]) ])])), attr("file_name=", "", 0, 1, 0, text('blue',64,34,1,0,1,80,14,29,11,3,0,0,0,0,2,80,14,0,0,"",0,0,0,0,45,'',[ minilines(80,14,0,0,0,0,0,[ mini_line(80,11,3,0,0,0,[ str_block(0,80,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,80,11,3,0,0,0,0,0,0,0, "file_name=")]) ]) ])])), attr("eq=", "", 1, 1, 0, text('blue',64,50,5,0,1,120,70,25,11,3,0,0,0,0,2,120,70,0,0,"",0,0,0,0,61,'',[ minilines(120,70,0,0,0,0,0,[ mini_line(24,11,3,0,0,0,[ str_block(0,24,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "eq=")]) ]), mini_line(48,11,3,0,0,0,[ str_block(0,48,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,48,11,3,0,0,0,0,0,0,0, "\\LARGE")]) ]), mini_line(16,11,3,0,0,0,[ str_block(0,16,11,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,16,11,3,0,-1,0,0,0,0,0, "\\[")]) ]), mini_line(120,11,3,0,0,0,[ str_block(0,120,11,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,120,11,3,0,-1,0,0,0,0,0, " E\\,=\\,M\\,C^2")]) ]), mini_line(16,11,3,0,0,0,[ str_block(0,16,11,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,16,11,3,0,-4,0,0,0,0,0, "\\]")]) ]) ])])), attr("", "not_rigid", 0, 1, 0, text('blue',64,154,1,0,1,72,14,535,11,3,0,0,0,0,2,72,14,0,0,"",0,0,0,0,165,'',[ minilines(72,14,0,0,0,0,0,[ mini_line(72,11,3,0,0,0,[ str_block(0,72,11,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,72,11,3,0,0,0,0,0,0,0, "not_rigid")]) ]) ])])) ]). group([ group([ text('#0000ff',224,106,4,0,1,366,65,657,14,3,0,-1,0,0,2,366,65,0,2,"",0,0,0,0,120,'',[ minilines(366,65,0,2,0,-1,0,[ mini_line(360,14,3,0,2,0,[ str_block(0,360,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,360,14,3,0,2,0,0,0,0,0, "This version of the LaTeX equation symbol by default")]) ]), mini_line(353,14,3,0,2,0,[ str_block(0,44,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,44,14,3,0,2,0,0,0,0,0, "uses \"")]), str_block(0,52,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,52,14,3,0,2,0,0,0,0,0, "convert")]), str_block(0,257,14,3,0,-1,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,257,14,3,0,-1,0,0,0,0,0, "\" to add a preview bitmap to a PS file.")]) ]), mini_line(366,14,3,0,2,0,[ str_block(0,36,14,3,0,2,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,36,14,3,0,2,0,0,0,0,0, "The \"")]), str_block(0,52,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,52,14,3,0,2,0,0,0,0,0, "convert")]), str_block(0,278,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,278,14,3,0,1,0,0,0,0,0, "\" program is part of ImageMagick, which")]) ]), mini_line(199,14,3,0,0,0,[ str_block(0,199,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,199,14,3,0,-1,0,0,0,0,0, "is available on most systems.")]) ]) ])]), text('#0000ff',192,106,1,0,1,19,17,846,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,120,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(2)")]) ]) ])]) ], 1270,0,0,[ ]), group([ text('#0000ff',224,50,3,0,1,362,49,643,14,3,0,-1,0,0,2,362,49,0,1,"",0,0,0,0,64,'',[ minilines(362,49,0,1,0,-1,0,[ mini_line(317,14,3,0,1,0,[ str_block(0,189,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,189,14,3,0,-3,0,0,0,0,0, "Make sure you are running ")]), str_block(0,60,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,60,14,3,0,1,0,0,0,0,0, "tgif-4.2.2")]), str_block(0,68,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,68,14,3,0,-1,0,0,0,0,0, " or newer.")]) ]), mini_line(362,14,3,0,1,0,[ str_block(0,362,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,1,0,0,0,0,0, "You can find out what version of tgif you are running")]) ]), mini_line(300,14,3,0,0,0,[ str_block(0,300,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,300,14,3,0,-1,0,0,0,0,0, "by selecting About() from the Special menu.")]) ]) ])]), text('#0000ff',192,50,1,0,1,19,17,863,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,64,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(1)")]) ]) ])]) ], 1258,0,0,[ ]), group([ text('#0000ff',192,178,1,0,1,19,17,1021,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,192,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(3)")]) ]) ])]), text('#0000ff',224,178,4,0,1,392,65,1022,14,3,0,-1,0,0,2,392,65,0,2,"",0,0,0,0,192,'',[ minilines(392,65,0,2,0,-1,0,[ mini_line(392,14,3,0,2,0,[ str_block(0,107,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,107,14,3,0,-2,0,0,0,0,0, "Make sure that ")]), str_block(0,32,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,32,14,3,0,2,0,0,0,0,0, "latex")]), str_block(0,8,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,8,14,3,0,-3,0,0,0,0,0, ", ")]), str_block(0,38,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,38,14,3,0,1,0,0,0,0,0, "dvips")]), str_block(0,38,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,38,14,3,0,-2,0,0,0,0,0, ", and ")]), str_block(0,52,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,52,14,3,0,2,0,0,0,0,0, "convert")]), str_block(0,81,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,81,14,3,0,-2,0,0,0,0,0, " are in your ")]), str_block(0,32,12,3,0,0,0,0,0,[ str_seg('#ff00ff','Courier-Bold',1,80640,32,12,3,0,0,0,0,0,0,0, "PATH")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]), mini_line(370,14,3,0,1,0,[ str_block(0,228,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,228,14,3,0,-3,0,0,0,0,0, "After you instantiate this symbol, ")]), str_block(0,84,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,84,14,3,0,1,0,0,0,0,0, "double-click")]), str_block(0,58,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,58,14,3,0,1,0,0,0,0,0, " it to run")]) ]), mini_line(386,14,3,0,0,0,[ str_block(0,362,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,-3,0,0,0,0,0, "the latex scripts. Afterwards, you can hide/show the ")]), str_block(0,24,11,3,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,11,3,0,0,0,0,0,0,0, "eq=")]) ]), mini_line(247,14,3,0,1,0,[ str_block(0,148,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,148,14,3,0,-3,0,0,0,0,0, "attribute by pressing ")]), str_block(0,95,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,95,14,3,0,1,0,0,0,0,0, "<Alt><Cntrl>7")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]) ])]) ], 1264,0,0,[ ]) ], 1472,0,0,[ ]). ���������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbitmap.c����������������������������������������������������������������������������0000644�0000764�0000764�00000644735�11602233314�014621� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbitmap.c,v 1.43 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_XBITMAP_C_ #include "tgifdefs.h" #include "expfdefs.h" #include "cmdids.h" #include "attr.e" #include "auxtext.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "edit.e" #include "eps.e" #include "file.e" #include "font.e" #include "grid.e" #include "imgproc.e" #include "mainloop.e" #include "mark.e" #include "menu.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "names.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "remote.e" #include "select.e" #include "setup.e" #include "stretch.e" #include "strtbl.e" #include "util.e" #include "version.e" #include "xbitmap.e" #include "xpixmap.e" #include "xprtfltr.e" #include "z_intrf.e" GC xbmGC=NULL; int askForXBmSpec=FALSE; int stripEPSComments=FALSE; int saveEPSLines=FALSE; int leftExportPixelTrim=0; int topExportPixelTrim=0; int rightExportPixelTrim=0; int bottomExportPixelTrim=0; #ifdef _XPM3TOPPM int xpmOutputVersion=3; #else /* ~_XPM3TOPPM */ int xpmOutputVersion=1; #endif /* _XPM3TOPPM */ Pixmap dummyBitmap=None; char gszHhtmlExportTemplate[MAXPATHLENGTH]; /* do not translate -- program constants */ static char hexValue[]="0123456789abcdef"; static int importXBmRV=FALSE; static int numColorsToDump=0; static int charsPerPixel=1; static int *pixelValue=NULL; static int *colorIndexToDumpIndex=NULL; static int *dumpIndexToColorIndex=NULL; static char *colorChar=NULL; static char **colorStr=NULL; static int xpmInXGrabSCFormat=FALSE; static int halfToneBitmap=FALSE; /* has precedence over thresholdBitmap */ static int thresholdBitmap=FALSE; static float bitmapThreshold=0.5; static char bitmapThresholdStr[MAXSTRING+1]; static int unsignedInXBmExport=FALSE; static int commentInBitmapExport=FALSE; static int useImagePixelsForTrueColorExport=FALSE; #define IMF_FORMAT_NCSA 0 #define IMF_FORMAT_CERN 1 #define IMF_FORMAT_SPYG 2 static int generateImageMap=INVALID; static char xpmToGifCmd[MAXSTRING+1]; static char xpmToPngCmd[MAXSTRING+1]; static char xpmToJpegCmd[MAXSTRING+1]; static char ppmToGifCmd[MAXSTRING+1]; static char ppmToPngCmd[MAXSTRING+1]; static char ppmToPngWithTransCmd[MAXSTRING+1]; static char ppmToJpegCmd[MAXSTRING+1]; static char ppm6ToXpm3Cmd[MAXSTRING+1]; static char xpmDeckToGifAnimCmd[MAXSTRING+1]; static char imageMapFileExtension[MAXSTRING+1]; static char htmlFileExtension[MAXSTRING+1]; static char gifFileExtension[MAXSTRING+1]; static char pngFileExtension[MAXSTRING+1]; static char jpegFileExtension[MAXSTRING+1]; static int imageMapFileFormat=IMF_FORMAT_NCSA; #ifdef _XPM3TOPPM static int useXPmVersion1ForImageMap=FALSE; #else /* ~_XPM3TOPPM */ static int useXPmVersion1ForImageMap=TRUE; #endif /* _XPM3TOPPM */ static int useXPmVersion1ForXPmDeck=TRUE; static int generateHtmlHref=TRUE; static int epsiThresholdPreviewBitmap=FALSE; static double epsiPreviewBitmapThreshold=(double)0.5; void SetHtmlExportTemplate() { char spec[MAXSTRING<<1]; if (*gszHhtmlExportTemplate == '\0') { sprintf(gszMsgBox, TgLoadString(STID_ENTER_HTML_TEMPLATE)); } else { sprintf(gszMsgBox, TgLoadString(STID_ENTER_HTML_TEMPLATE_CUR_IS), gszHhtmlExportTemplate); } *spec = '\0'; strcpy(spec, gszHhtmlExportTemplate); if (Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), spec) == INVALID) { return; } UtilTrimBlanks(spec); if (strcmp(gszHhtmlExportTemplate, spec) == 0) { Msg(TgLoadString(STID_HTML_TEMPLATE_UNCHANGED)); return; } if (*spec != '\0' && !UtilPathExists(spec)) { sprintf(gszMsgBox, TgLoadString(STID_Q_FILE_NOT_EXIST_USE_ANYWAY), spec); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) != MB_ID_YES) { Msg(TgLoadString(STID_HTML_TEMPLATE_UNCHANGED)); return; } } UtilStrCpyN(gszHhtmlExportTemplate, sizeof(gszHhtmlExportTemplate), spec); if (*gszHhtmlExportTemplate == '\0') { sprintf(gszMsgBox, TgLoadString(STID_NO_HTML_TEMPLATE_FILE)); } else { sprintf(gszMsgBox, TgLoadString(STID_HTML_TEMPLATE_SET_TO_GIVEN), gszHhtmlExportTemplate); } Msg(gszMsgBox); SetFileModified(TRUE); } int ReadHtmlExportTemplate(buf) char *buf; { if (!importingFile) { char *s=FindChar((int)'(', buf), *c_ptr=NULL; c_ptr = FindChar((int)'"', s); s = ReadString(c_ptr); *(--s) = '\0'; *gszHhtmlExportTemplate = '\0'; UtilStrCpyN(gszHhtmlExportTemplate, sizeof(gszHhtmlExportTemplate), c_ptr); } return TRUE; } static void ExpandTmpStorage() { /* the size before are all maxColors+2 */ pixelValue = (int*)realloc(pixelValue, (maxColors+3)*sizeof(int)); colorIndexToDumpIndex = (int*)realloc(colorIndexToDumpIndex, (maxColors+3)*sizeof(int)); dumpIndexToColorIndex = (int*)realloc(dumpIndexToColorIndex, (maxColors+3)*sizeof(int)); if (maxColors > 20) { charsPerPixel = 2; colorChar = (char*)realloc(colorChar, ((maxColors<<1)+4)*sizeof(char)); } else { charsPerPixel = 1; colorChar = (char*)realloc(colorChar, (maxColors+3)*sizeof(char)); } colorStr = (char**)realloc(colorStr, (maxColors+3)*sizeof(char*)); if (colorStr == NULL) FailAllocMessage(); colorStr[maxColors+2] = NULL; colorIndexToDumpIndex[maxColors+2] = INVALID; dumpIndexToColorIndex[maxColors+2] = INVALID; } static void ParseExportPixelTrim(pszSpec, nInit) char *pszSpec; int nInit; { char *pszLeft, *pszTop=NULL, *pszRight=NULL, *pszBottom=NULL; int left, top, right, bottom; pszLeft = strtok(pszSpec, " ,\t"); if (pszLeft == NULL) return; pszTop = strtok(NULL, " ,\t"); if (pszTop != NULL) { pszRight = strtok(NULL, " ,\t"); if (pszRight != NULL) { pszBottom = strtok(NULL, " ,\t"); } } left = (pszLeft==NULL ? 0 : atoi(pszLeft)); top = (pszTop==NULL ? 0 : atoi(pszTop)); right = (pszRight==NULL ? 0 : atoi(pszRight)); bottom = (pszBottom==NULL ? 0 : atoi(pszBottom)); if (left < 0 || top < 0 || right < 0 || bottom < 0) { sprintf(gszMsgBox, TgLoadString(STID_NEG_VAL_IN_EXP_PXL_TRM_ALT), leftExportPixelTrim, topExportPixelTrim, rightExportPixelTrim, bottomExportPixelTrim); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { leftExportPixelTrim = left; topExportPixelTrim = top; rightExportPixelTrim = right; bottomExportPixelTrim = bottom; sprintf(gszMsgBox, TgLoadString(STID_EXP_PXL_TRM_VAL_SET_TO), leftExportPixelTrim, topExportPixelTrim, rightExportPixelTrim, bottomExportPixelTrim); if (!nInit) Msg(gszMsgBox); } } void SetExportPixelTrim(cur_val_is_too_large) int cur_val_is_too_large; { char szSpec[MAXSTRING+1]; *szSpec = '\0'; sprintf(gszMsgBox, TgLoadString(STID_SPECIFY_TO_TRIM_EXP_PXL_TRM), leftExportPixelTrim, topExportPixelTrim, rightExportPixelTrim, bottomExportPixelTrim); Dialog(gszMsgBox, TgLoadString(cur_val_is_too_large ? STID_ENTER_4_NUM_CUR_TOO_LARGE : STID_ENTER_4_NUM_OR_CR_ESC), szSpec); ParseExportPixelTrim(szSpec, FALSE); } int GetXpmOutputVersion() { return xpmOutputVersion; } void SetXpmOutputVersion(xpm_output_version) int xpm_output_version; { xpmOutputVersion = xpm_output_version; } void InitXBm() { XGCValues values; char *c_ptr; dummyBitmap = XCreatePixmap(mainDisplay, mainWindow, 1, 1, 1); values.foreground = 0; values.background = 0; values.function = GXcopy; values.fill_style = FillSolid; xbmGC = XCreateGC(mainDisplay, dummyBitmap, GCForeground | GCBackground | GCFunction | GCFillStyle, &values); *gszHhtmlExportTemplate = '\0'; importXBmRV = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"XBmReverseVideo")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { importXBmRV = TRUE; } askForXBmSpec = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"AskForXBmSpec")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { askForXBmSpec = TRUE; } stripEPSComments = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"StripEPSComments")) != NULL && UtilStrICmp(c_ptr, "false") != 0) { fprintf(stderr, TgLoadString(STID_OBSOLETE_XDEF_USE_IGNORED), TOOL_NAME, "StripEPSComments"); fprintf(stderr, "\n"); } #ifdef _XPM3TOPPM xpmOutputVersion = 3; #else /* ~_XPM3TOPPM */ xpmOutputVersion = 1; #endif /* _XPM3TOPPM */ if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"XPmOutputVersion")) != NULL) { xpmOutputVersion = atoi(c_ptr); if (xpmOutputVersion != 1 && xpmOutputVersion != 3) { #ifdef _XPM3TOPPM int def_version=3; #else /* ~_XPM3TOPPM */ int def_version=1; #endif /* _XPM3TOPPM */ fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "XPmOutputVersion", c_ptr, def_version); fprintf(stderr, "\n"); xpmOutputVersion = def_version; } } xpmInXGrabSCFormat = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"XPmInXGrabSCFormat"))!=NULL && UtilStrICmp(c_ptr, "true") == 0) { xpmInXGrabSCFormat = TRUE; } halfToneBitmap = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"HalfToneBitmap"))!=NULL && UtilStrICmp(c_ptr, "true") == 0) { halfToneBitmap = TRUE; } thresholdBitmap = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ThresholdBitmap")) != NULL && !halfToneBitmap && UtilStrICmp(c_ptr, "true") == 0) { thresholdBitmap = TRUE; } bitmapThreshold = (halfToneBitmap) ? 0.5 : 1.0; strcpy(bitmapThresholdStr, ((halfToneBitmap) ? "0.5" : "1.0")); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"BitmapThreshold"))!=NULL) { strcpy(bitmapThresholdStr, c_ptr); bitmapThreshold = (float) atof(c_ptr); if (bitmapThreshold < 0 || bitmapThreshold > 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "BitmapThreshold", c_ptr, ((halfToneBitmap) ? "0.5" : "1.0")); fprintf(stderr, "\n"); bitmapThreshold = (halfToneBitmap) ? 0.5 : 1.0; strcpy(bitmapThresholdStr, ((halfToneBitmap) ? "0.5" : "1.0")); } } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"InitExportPixelTrim")) != NULL) { ParseExportPixelTrim(c_ptr, TRUE); } unsignedInXBmExport = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"UnsignedInXBmExport")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { unsignedInXBmExport = TRUE; } commentInBitmapExport = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"CommentInBitmapExport")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { commentInBitmapExport = TRUE; } useImagePixelsForTrueColorExport = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseImagePixelsForTrueColorExport")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { useImagePixelsForTrueColorExport = TRUE; } epsiThresholdPreviewBitmap = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "EPSIThresholdPreviewBitmap")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { epsiThresholdPreviewBitmap = TRUE; } epsiPreviewBitmapThreshold = (float)0.5; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "EPSIPreviewBitmapThreshold")) != NULL) { epsiPreviewBitmapThreshold = (float) atof(c_ptr); if (epsiPreviewBitmapThreshold < ((float)0) || epsiPreviewBitmapThreshold > (((float)1)+INT_TOL)) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "EPSIPreviewBitmapThreshold", c_ptr, "0.5"); fprintf(stderr, "\n"); epsiPreviewBitmapThreshold = (float)0.5; } } InitEPS(); } void ExportHalfToneBitmap() { halfToneBitmap = !halfToneBitmap; Msg(TgLoadString(halfToneBitmap ? STID_WILL_USE_FS_HALFTONE_BMP : STID_WILL_NOT_USE_FS_HALFTONE_BMP)); } void ExportThresholdBitmap() { thresholdBitmap = !thresholdBitmap; if (thresholdBitmap) { sprintf(gszMsgBox, TgLoadString(STID_WILL_USE_GIVE_SMPLE_THRESHOLD), bitmapThresholdStr); } else { sprintf(gszMsgBox, TgLoadString(STID_WILL_NOT_USE_SIMPLE_THRESHOLD)); } Msg(gszMsgBox); } void SetExportBitmapThreshold(buf) char *buf; { float threshold=(float)0; char spec[MAXSTRING<<1]; *spec = '\0'; if (buf != NULL && strcmp(buf, "-1") != 0) { int len=0; UtilStrCpyN(spec, sizeof(spec), buf); UtilTrimBlanks(spec); len = strlen(spec); if (len > 0 && spec[len-1] == ')') spec[len-1] = '\0'; } else { sprintf(gszMsgBox, TgLoadString(STID_ENTER_BMP_THRESHOLD_CUR_VAL), bitmapThresholdStr); *spec = '\0'; if (Dialog(gszMsgBox, NULL, spec) == INVALID) { return; } } UtilTrimBlanks(spec); if (sscanf(spec, "%f", &threshold) != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_THRESHOLD_REMAINS), spec, bitmapThresholdStr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (threshold < (float)0 || threshold > (float)1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_THRESHOLD_REMAINS), spec, bitmapThresholdStr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { strcpy(bitmapThresholdStr, spec); bitmapThreshold = threshold; sprintf(gszMsgBox, TgLoadString(STID_USE_GIVEN_AS_BMP_THRESHOLD), bitmapThresholdStr); Msg(gszMsgBox); } } int RefreshBitPixmapMenu(menu) TgMenu *menu; { int ok=TRUE; /* ExportHalfToneBitmap */ ok &= TgSetMenuItemCheckById(menu, CMDID_EXPORTHALFTONEBITMAP, halfToneBitmap); /* ExportThresholdBitmap */ ok &= TgSetMenuItemCheckById(menu, CMDID_EXPORTTHRESHOLDBITMAP, thresholdBitmap); ok &= TgEnableMenuItemById(menu, CMDID_EXPORTHALFTONEBITMAP, (whereToPrint == XBM_FILE && !colorDump)); ok &= TgEnableMenuItemById(menu, CMDID_EXPORTTHRESHOLDBITMAP, (whereToPrint == XBM_FILE && !colorDump)); ok &= TgEnableMenuItemById(menu, CMDID_SETEXPORTBITMAPTHRESHOLD, (whereToPrint == XBM_FILE && !colorDump) && thresholdBitmap); return ok; } TgMenu *CreateBitPixmapMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { menu->track_menubar = TRUE; if (!RefreshBitPixmapMenu(menu)) { return TgDestroyMenu(menu, TRUE); } } return menu; } static int transparentIndex=INVALID; static void FreeCachedStrings() { register int i; if (colorChar != NULL) { for (i = 0; i < numColorsToDump+3; i++) { if (colorStr[i] != NULL) { free(colorStr[i]); } else { break; } } free(colorStr); free(colorChar); free(pixelValue); free(colorIndexToDumpIndex); free(dumpIndexToColorIndex); } colorStr = NULL; colorChar = NULL; pixelValue = colorIndexToDumpIndex = dumpIndexToColorIndex = NULL; transparentIndex = INVALID; } void CleanUpXBm() { FreeCachedStrings(); CleanUpEPS(); if (xbmGC != NULL) XFreeGC(mainDisplay, xbmGC); XFreePixmap(mainDisplay, dummyBitmap); importXBmRV = FALSE; askForXBmSpec = FALSE; } static void MultiplyTwoByTwo(m1, m2) float m1[2][2], m2[2][2]; { float m3[2][2]; m3[0][0] = m1[0][0]*m2[0][0] + m1[0][1]*m2[1][0]; m3[0][1] = m1[0][0]*m2[0][1] + m1[0][1]*m2[1][1]; m3[1][0] = m1[1][0]*m2[0][0] + m1[1][1]*m2[1][0]; m3[1][1] = m1[1][0]*m2[0][1] + m1[1][1]*m2[1][1]; m1[0][0]=m3[0][0]; m1[0][1]=m3[0][1]; m1[1][0]=m3[1][0]; m1[1][1]=m3[1][1]; } void CalcTransform(mtrx) register struct MtrxRec *mtrx; { float m1[2][2], m2[2][2], tmp_val; switch (mtrx->rotate) { case ROTATE0: case ROTATE180: mtrx->h_scale = mtrx->w / mtrx->image_w; mtrx->v_scale = mtrx->h / mtrx->image_h; break; case ROTATE90: case ROTATE270: mtrx->h_scale = mtrx->h / mtrx->image_w; mtrx->v_scale = mtrx->w / mtrx->image_h; break; } m1[0][0]=1.0; m1[0][1]=0.0; m1[1][0]=0.0; m1[1][1]=1.0; if (mtrx->flip & HORI_EVEN) { m2[0][0]=(-1.0); m2[0][1]=0.0; m2[1][0]=0.0; m2[1][1]=1.0; MultiplyTwoByTwo(m1, m2); } if (mtrx->flip & VERT_EVEN) { m2[0][0]=1.0; m2[0][1]=0.0; m2[1][0]=0.0; m2[1][1]=(-1.0); MultiplyTwoByTwo(m1, m2); } switch (mtrx->rotate) { case ROTATE0: if (mtrx->flip & (HORI_ODD | VERT_ODD)) { m2[0][0]=rotatedCosine[ROTATE90]; m2[0][1]=rotatedSine[ROTATE90]; m2[1][0]=(-rotatedSine[ROTATE90]); m2[1][1]=rotatedCosine[ROTATE90]; MultiplyTwoByTwo(m1, m2); if (mtrx->flip & HORI_ODD) { m2[0][0]=(-1.0); m2[0][1]=0.0; m2[1][0]=0.0; m2[1][1]=1.0; MultiplyTwoByTwo(m1, m2); } if (mtrx->flip & VERT_ODD) { m2[0][0]=1.0; m2[0][1]=0.0; m2[1][0]=0.0; m2[1][1]=(-1.0); MultiplyTwoByTwo(m1, m2); } m2[0][0]=rotatedCosine[ROTATE270]; m2[0][1]=rotatedSine[ROTATE270]; m2[1][0]=(-rotatedSine[ROTATE270]); m2[1][1]=rotatedCosine[ROTATE270]; MultiplyTwoByTwo(m1, m2); } break; case ROTATE90: m2[0][0]=rotatedCosine[ROTATE90]; m2[0][1]=rotatedSine[ROTATE90]; m2[1][0]=(-rotatedSine[ROTATE90]); m2[1][1]=rotatedCosine[ROTATE90]; MultiplyTwoByTwo(m1, m2); if (mtrx->flip & HORI_ODD) { m2[0][0]=(-1.0); m2[0][1]=0.0; m2[1][0]=0.0; m2[1][1]=1.0; MultiplyTwoByTwo(m1, m2); } if (mtrx->flip & VERT_ODD) { m2[0][0]=1.0; m2[0][1]=0.0; m2[1][0]=0.0; m2[1][1]=(-1.0); MultiplyTwoByTwo(m1, m2); } break; case ROTATE180: m2[0][0]=rotatedCosine[ROTATE90]; m2[0][1]=rotatedSine[ROTATE90]; m2[1][0]=(-rotatedSine[ROTATE90]); m2[1][1]=rotatedCosine[ROTATE90]; MultiplyTwoByTwo(m1, m2); if (mtrx->flip & HORI_ODD) { m2[0][0]=(-1.0); m2[0][1]=0.0; m2[1][0]=0.0; m2[1][1]=1.0; MultiplyTwoByTwo(m1, m2); } if (mtrx->flip & VERT_ODD) { m2[0][0]=1.0; m2[0][1]=0.0; m2[1][0]=0.0; m2[1][1]=(-1.0); MultiplyTwoByTwo(m1, m2); } m2[0][0]=rotatedCosine[ROTATE90]; m2[0][1]=rotatedSine[ROTATE90]; m2[1][0]=(-rotatedSine[ROTATE90]); m2[1][1]=rotatedCosine[ROTATE90]; MultiplyTwoByTwo(m1, m2); break; case ROTATE270: m2[0][0]=rotatedCosine[ROTATE270]; m2[0][1]=rotatedSine[ROTATE270]; m2[1][0]=(-rotatedSine[ROTATE270]); m2[1][1]=rotatedCosine[ROTATE270]; MultiplyTwoByTwo(m1, m2); if (mtrx->flip & HORI_ODD) { m2[0][0]=(-1.0); m2[0][1]=0.0; m2[1][0]=0.0; m2[1][1]=1.0; MultiplyTwoByTwo(m1, m2); } if (mtrx->flip & VERT_ODD) { m2[0][0]=1.0; m2[0][1]=0.0; m2[1][0]=0.0; m2[1][1]=(-1.0); MultiplyTwoByTwo(m1, m2); } break; } m2[0][0]=mtrx->h_scale; m2[0][1]=0.0; m2[1][0]=0.0; m2[1][1]=mtrx->v_scale; MultiplyTwoByTwo(m2, m1); mtrx->m[0][0]=m2[0][0]; mtrx->m[0][1]=m2[0][1]; mtrx->m[1][0]=m2[1][0]; mtrx->m[1][1]=m2[1][1]; tmp_val = m2[0][0]*m2[1][1] - m2[0][1]*m2[1][0]; if (fabs((double) tmp_val) < 1.0e-6) { tmp_val = ((float)1000000); } else { tmp_val = ((float)1.0)/tmp_val; } mtrx->rev_m[0][0] = tmp_val*m2[1][1]; mtrx->rev_m[0][1] = (-tmp_val)*m2[0][1]; mtrx->rev_m[1][0] = (-tmp_val)*m2[1][0]; mtrx->rev_m[1][1] = tmp_val*m2[0][0]; mtrx->transformed_w = mtrx->image_w*m2[0][0] + mtrx->image_h*m2[1][0]; mtrx->transformed_h = mtrx->image_w*m2[0][1] + mtrx->image_h*m2[1][1]; switch (mtrx->rotate) { case ROTATE0: mtrx->dump_h_scale=mtrx->m[0][0]; mtrx->dump_v_scale=mtrx->m[1][1]; mtrx->degree=0; break; case ROTATE90: mtrx->dump_h_scale=mtrx->m[1][0]; mtrx->dump_v_scale=(-mtrx->m[0][1]); mtrx->degree=(-90); break; case ROTATE180: mtrx->dump_h_scale=(-mtrx->m[0][0]); mtrx->dump_v_scale=(-mtrx->m[1][1]); mtrx->degree=(-180); break; case ROTATE270: mtrx->dump_h_scale=(-mtrx->m[1][0]); mtrx->dump_v_scale=mtrx->m[0][1]; mtrx->degree=(-270); break; } } void MakeCachedBitmap(ObjPtr) struct ObjRec *ObjPtr; { register int r, c; int w, h, flip, target_percent; int num_cols, num_rows, image_w, image_h, watch_cursor; int start_col, start_row, do_msg; struct XBmRec *xbm_ptr=ObjPtr->detail.xbm; struct MtrxRec mtrx; Pixmap dest_bitmap; XImage *src_image, *dest_image; if (xbm_ptr->real_type==XBM_EPS && xbm_ptr->bitmap==None) return; w = ObjPtr->obbox.rbx - ObjPtr->obbox.ltx; h = ObjPtr->obbox.rby - ObjPtr->obbox.lty; num_cols = (zoomedIn) ? (w<<zoomScale) : (w>>zoomScale); num_rows = (zoomedIn) ? (h<<zoomScale) : (h>>zoomScale); if (ObjPtr->ctm==NULL && xbm_ptr->cached_bitmap!=None && xbm_ptr->cached_zoomed==zoomedIn && xbm_ptr->cached_zoom==zoomScale && xbm_ptr->cached_w==num_cols && xbm_ptr->cached_h==num_rows && xbm_ptr->cached_flip==xbm_ptr->flip) { return; } if ((w>>zoomScale)==0 || (h>>zoomScale)==0) { if (xbm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xbm_ptr->cached_bitmap); } xbm_ptr->cached_bitmap = None; return; } watch_cursor = watchCursorOnMainWindow; if (!watch_cursor && !RedrawDuringScrolling()) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } else { CheckInterrupt(TRUE); } src_image = xbm_ptr->image; flip = xbm_ptr->flip; image_w = xbm_ptr->image_w; image_h = xbm_ptr->image_h; if (xbm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xbm_ptr->cached_bitmap); } xbm_ptr->cached_bitmap = None; if (src_image == NULL) { src_image = xbm_ptr->image = XGetImage(mainDisplay, xbm_ptr->bitmap, 0, 0, image_w, image_h, 1, ZPixmap); } do_msg = (((num_rows*num_cols)>=0x4000) && !RedrawDuringScrolling()); if (do_msg) { SaveStatusStrings(); SetStringStatus(TgLoadCachedString(CSTID_CACHING_BITMAP)); XSync(mainDisplay, False); } dest_bitmap = XCreatePixmap(mainDisplay,dummyBitmap,num_cols,num_rows,1); XFillRectangle(mainDisplay,dest_bitmap,xbmGC,0,0,num_cols,num_rows); dest_image = XGetImage(mainDisplay, dest_bitmap, 0, 0, num_cols, num_rows, 1, ZPixmap); if (ObjPtr->ctm == NULL) { mtrx.image_w = (float)image_w; mtrx.image_h = (float)image_h; mtrx.w = (float)num_cols; mtrx.h = (float)num_rows; mtrx.rotate = ROTATE0; mtrx.flip = flip; CalcTransform(&mtrx); start_col = (mtrx.transformed_w >= 0.0) ? 0 : (-num_cols)+1; start_row = (mtrx.transformed_h >= 0.0) ? 0 : (-num_rows)+1; target_percent = 5; for (r = 0; r < num_rows; r++) { double part_x, part_y; if (do_msg && ((r & 0xf) == 0)) { int percent=(r*10000/num_rows)/100; if (percent >= target_percent) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_PROGRESS_PERCENT), percent); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); while (target_percent <= percent) target_percent += 5; } } part_x = ((double)(r+start_row)+0.5)*(mtrx.rev_m[1][0]); part_y = ((double)(r+start_row)+0.5)*(mtrx.rev_m[1][1]); for (c = 0; c < num_cols; c++) { double x, y; x = part_x+((double)(c+start_col)+0.5)*(mtrx.rev_m[0][0]); y = part_y+((double)(c+start_col)+0.5)*(mtrx.rev_m[0][1]); if (x >= ((double)0) && x < ((double)image_w) && y >= ((double)0) && y < ((double)image_h)) { if (XGetPixel(src_image, (int)x, (int)y) == 1) { XPutPixel(dest_image, c, r, 1); } } } } } else { int abs_offset_x=ObjPtr->obbox.ltx-ObjPtr->x; int abs_offset_y=ObjPtr->obbox.lty-ObjPtr->y; double sx=(double)0.0, sy=(double)0.0; if (xbm_ptr->real_type != XBM_XBM) { sx = (((double)xbm_ptr->eps_w)/((double)image_w)); sy = (((double)xbm_ptr->eps_h)/((double)image_h)); } target_percent = 5; for (r=0; r < num_rows; r++) { int y=abs_offset_y+ABS_SIZE(r); double dy=((double)y)+0.5; if (do_msg && ((r & 0xf) == 0)) { int percent=(r*10000/num_rows)/100; if (percent >= target_percent) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_PROGRESS_PERCENT), percent); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); while (target_percent <= percent) target_percent += 5; } } for (c=0; c < num_cols; c++) { int x=abs_offset_x+ABS_SIZE(c); double dx=((double)x)+0.5; double new_dx=(double)0, new_dy=(double)0; ReverseTransformDoublePointThroughCTM(dx, dy, ObjPtr->ctm, &new_dx, &new_dy); if (xbm_ptr->real_type != XBM_XBM) { double tmp_dx=((double)new_dx)/sx; double tmp_dy=((double)new_dy)/sy; new_dx = tmp_dx + ((double)(ObjPtr->x - ObjPtr->orig_obbox.ltx)); new_dy = tmp_dy + ((double)(ObjPtr->y - ObjPtr->orig_obbox.lty)); } else { new_dx += (double)(ObjPtr->x-ObjPtr->orig_obbox.ltx); new_dy += (double)(ObjPtr->y-ObjPtr->orig_obbox.lty); } if (new_dx >= ((double)0) && new_dx < ((double)image_w) && new_dy >= ((double)0) && new_dy < ((double)image_h)) { int new_x=(int)new_dx, new_y=(int)new_dy; if (new_x < 0) new_x = 0; if (new_x >= image_w) new_x = image_w-1; if (new_y < 0) new_y = 0; if (new_y >= image_h) new_y = image_h-1; if (XGetPixel(src_image, new_x, new_y) == 1) { XPutPixel(dest_image, c, r, 1); } } } } memcpy(&xbm_ptr->cached_ctm, ObjPtr->ctm, sizeof(struct XfrmMtrxRec)); } if (do_msg) { SetStringStatus(TgLoadCachedString(CSTID_FINISHED_CACHEING_BITMAP)); XSync(mainDisplay, False); } XPutImage(mainDisplay, dest_bitmap, xbmGC, dest_image, 0, 0, 0, 0, num_cols, num_rows); if (do_msg) RestoreStatusStrings(); xbm_ptr->cached_bitmap = dest_bitmap; xbm_ptr->cached_zoomed = zoomedIn; xbm_ptr->cached_zoom = zoomScale; xbm_ptr->cached_flip = xbm_ptr->flip; xbm_ptr->cached_w = num_cols; xbm_ptr->cached_h = num_rows; XDestroyImage(dest_image); if (!watch_cursor && !RedrawDuringScrolling()) { SetDefaultCursor(mainWindow); ShowCursor(); } else { CheckInterrupt(TRUE); } } int ExtractBitmap(OrigBitmap, OrigImage, X, Y, W, H, Bitmap, Image) Pixmap OrigBitmap, *Bitmap; XImage *OrigImage, **Image; int X, Y, W, H; { register int j, i; XImage *src_image; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if ((*Bitmap=XCreatePixmap(mainDisplay,mainWindow,W,H,1)) == None) { FailAllocBitmapMessage(W, H); SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); return FALSE; } if ((*Image=XGetImage(mainDisplay, *Bitmap, 0, 0, W, H, 1, ZPixmap)) == NULL) { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); XFreePixmap(mainDisplay, *Bitmap); *Bitmap = None; SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); return FALSE; } if (OrigImage != NULL && X == 0 && Y == 0) { src_image = OrigImage; } else { if ((src_image=XGetImage(mainDisplay, OrigBitmap, X, Y, W, H, 1, ZPixmap)) == NULL) { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); XFreePixmap(mainDisplay, *Bitmap); *Bitmap = None; XDestroyImage(*Image); *Image = NULL; SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); return FALSE; } } for (i=0; i < H; i++) { for (j=0; j < W; j++) { XPutPixel(*Image, j, i, XGetPixel(src_image, j, i)); } } XPutImage(mainDisplay, *Bitmap, xbmGC, *Image, 0, 0, 0, 0, W, H); SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); if (!(OrigImage != NULL && X == 0 && Y == 0)) XDestroyImage(src_image); return TRUE; } int AutoTrimBitmap(OrigBitmap, pnImageW, pnImageH, pBitmap, pImage, pnEmptyImage, pnDontFreeOrigBitmap) Pixmap OrigBitmap, *pBitmap; int *pnImageW, *pnImageH, *pnEmptyImage, *pnDontFreeOrigBitmap; XImage **pImage; { int i=0, orig_w=(*pnImageW), orig_h=(*pnImageH); int top=orig_h, left=orig_w, bottom=(-1), right=(-1); XImage *image=NULL; *pnEmptyImage = *pnDontFreeOrigBitmap = FALSE; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); image = XGetImage(mainDisplay, OrigBitmap, 0, 0, orig_w, orig_h, 1, ZPixmap); if (image == NULL) { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); return FALSE; } for (i=0; i < orig_h; i++) { int j=0; for (j=0; j < orig_w; j++) { if (XGetPixel(image, j, i) != 0) { if (i < top) top = i; if (i > bottom) bottom = i; if (j < left) left = j; if (j > right) right = j; } } } SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); if (top == orig_h && left == orig_w && bottom == (-1) && right == (-1)) { /* no image */ *pnEmptyImage = TRUE; XDestroyImage(image); return FALSE; } else if (top == 0 && left == 0 && bottom == orig_w-1 && right == orig_h-1) { *pnImageW = orig_w; *pnImageH = orig_h; *pBitmap = OrigBitmap; *pImage = image; *pnDontFreeOrigBitmap = TRUE; } else { /* trim */ int rc=0; *pnImageW = right-left+1; *pnImageH = bottom-top+1; rc = ExtractBitmap(OrigBitmap, image, left, top, *pnImageW, *pnImageH, pBitmap, pImage); XDestroyImage(image); return rc; } return TRUE; } static void InvertXBmObject(ObjPtr) struct ObjRec *ObjPtr; { int i, j, image_w, image_h, pixel, watch_cursor=watchCursorOnMainWindow; Pixmap bitmap=None; XImage *image=NULL; if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } bitmap = ObjPtr->detail.xbm->bitmap; image_w = ObjPtr->detail.xbm->image_w; image_h = ObjPtr->detail.xbm->image_h; if (ObjPtr->detail.xbm->image == NULL) { if ((image=ObjPtr->detail.xbm->image = XGetImage(mainDisplay, bitmap, 0, 0, image_w, image_h, 1, ZPixmap)) == NULL) { fprintf(stderr, "%s\n", TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM)); fflush(stderr); SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } return; } } else { image = ObjPtr->detail.xbm->image; } for (i=0; i < image_h; i++) { for (j=0; j < image_w; j++) { pixel = XGetPixel(image, j, i); XPutPixel(image, j, i, ((pixel==1) ? 0 : 1)); } } XPutImage(mainDisplay, bitmap, xbmGC, image, 0, 0, 0, 0, image_w, image_h); if (ObjPtr->detail.xbm->cached_bitmap != None) { XFreePixmap(mainDisplay, ObjPtr->detail.xbm->cached_bitmap); } ObjPtr->detail.xbm->cached_bitmap = None; if (zoomScale != 0) { ObjPtr->detail.xbm->cached_zoom = 0; } if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } } static int ObjListInvertable(LastObjPtr) struct ObjRec *LastObjPtr; { struct ObjRec *obj_ptr; for (obj_ptr=LastObjPtr; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { switch (obj_ptr->type) { case OBJ_XBM: return TRUE; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: if (ObjListInvertable(obj_ptr->detail.r->last)) return TRUE; break; case OBJ_PIN: if (ObjListInvertable(GetPinObj(obj_ptr)->detail.r->last)) return TRUE; break; } } return FALSE; } static void InvertObjListXBitmap(LastObjPtr) struct ObjRec *LastObjPtr; { struct ObjRec *obj_ptr; for (obj_ptr=LastObjPtr; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { switch (obj_ptr->type) { case OBJ_XBM: InvertXBmObject(obj_ptr); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: InvertObjListXBitmap(obj_ptr->detail.r->last); break; case OBJ_PIN: InvertObjListXBitmap(GetPinObj(obj_ptr)->detail.r->last); break; } } } void InvertXBitmaps() { struct SelRec *sel_ptr; int changed=FALSE; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { switch (sel_ptr->obj->type) { case OBJ_XBM: changed = TRUE; PrepareToReplaceAnObj(sel_ptr->obj); InvertXBmObject(sel_ptr->obj); RecordReplaceAnObj(sel_ptr->obj); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: if (ObjListInvertable(sel_ptr->obj->detail.r->last)) { changed = TRUE; PrepareToReplaceAnObj(sel_ptr->obj); InvertObjListXBitmap(sel_ptr->obj->detail.r->last); RecordReplaceAnObj(sel_ptr->obj); } break; } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); HighLightReverse(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); } else { MsgBox(TgLoadString(STID_NO_X11_BITMAP_OBJ_SELECTED), TOOL_NAME, INFO_MB); } } static void ParseGeomSpec(geom_spec, image_w, image_h, src_x, src_y, src_w, src_h) char *geom_spec; int image_w, image_h, *src_x, *src_y, *src_w, *src_h; { int bitmask; XSizeHints sizehints; *src_x = *src_y = 0; *src_w = image_w; *src_h = image_h; bitmask = XParseGeometry(geom_spec, &(sizehints.x), &(sizehints.y), (unsigned int *)&(sizehints.width), (unsigned int *)&(sizehints.height)); if (bitmask & WidthValue) *src_w = sizehints.width; if (bitmask & HeightValue) *src_h = sizehints.height; if (bitmask & XValue) { *src_x = (bitmask & XNegative) ? image_w+sizehints.x : sizehints.x; if (bitmask & XNegative) { if (*src_w > image_w) *src_w = image_w; if (*src_x >= image_w || *src_x < 0) *src_x = image_w; if (*src_x-*src_w < 0) { *src_w = *src_x; *src_x = 0; } else { *src_x -= *src_w; } } else { if (*src_w > image_w) *src_w = image_w; if (*src_x >= image_w || *src_x < 0) *src_x = 0; if (*src_x+*src_w > image_w) *src_w = image_w-*src_x; } } if (bitmask & YValue) { *src_y = (bitmask & YNegative) ? image_h+sizehints.y : sizehints.y; if (bitmask & YNegative) { if (*src_h > image_h) *src_h = image_h; if (*src_y >= image_h || *src_y < 0) *src_y = image_h; if (*src_y-*src_h < 0) { *src_h = *src_y; *src_y = 0; } else { *src_y -= *src_h; } } else { if (*src_h > image_h) *src_h = image_h; if (*src_y >= image_h || *src_y < 0) *src_y = 0; if (*src_y+*src_h > image_h) *src_h = image_h-*src_y; } } if ((bitmask&WidthValue) && *src_x+*src_w>image_w) *src_w = image_w-*src_x; if ((bitmask&HeightValue) && *src_y+*src_h>image_h) *src_h = image_h-*src_y; } static char *FindEqual(s) register char *s; { while (*s != '=' && *s != '\0') s++; return ((*s == '=') ? (s) : (char*)NULL); } void ParseCutSpec(spec, image_w, image_h, mag, src_x, src_y, src_w, src_h) char *spec; int image_w, image_h, * src_x, * src_y, * src_w, * src_h; float *mag; { char *geom_spec; *mag = 1.0; if ((geom_spec=FindEqual(spec)) == NULL) { ParseGeomSpec(spec,image_w,image_h,src_x,src_y,src_w,src_h); } else { *geom_spec = '\0'; geom_spec++; ParseGeomSpec(geom_spec,image_w,image_h,src_x,src_y,src_w,src_h); sscanf(spec, "%f", mag); if (*mag <= 0.0) *mag = 1.0; } } void CutXBitmap() { int w, h, ltx, lty, rbx, rby, new_w, new_h; int src_x, src_y, src_w, src_h, image_w, image_h; char mag_spec[MAXSTRING]; float h_scale=1.0, v_scale=1.0, mag; Pixmap dest_bitmap=None; XImage *dest_image=NULL; struct ObjRec *obj_ptr=topSel->obj, *new_obj_ptr; struct XBmRec *new_xbm_ptr; if (obj_ptr->detail.xbm->real_type==XBM_EPS) { MsgBox(TgLoadString(STID_CANT_CUT_AN_EPS_OBJECT), TOOL_NAME, INFO_MB); return; } src_x = 0; src_y = 0; src_w = image_w = obj_ptr->detail.xbm->image_w; src_h = image_h = obj_ptr->detail.xbm->image_h; mag = 1.0; h_scale = ((float)((float)(obj_ptr->obbox.rbx-obj_ptr->obbox.ltx)) / ((float)image_w)); v_scale = ((float)((float)(obj_ptr->obbox.rby-obj_ptr->obbox.lty)) / ((float)image_h)); *mag_spec = '\0'; sprintf(gszMsgBox, TgLoadString(STID_ENTER_GEOM_SPEC_ORIG_SIZE), image_w, image_h); Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), mag_spec); UtilTrimBlanks(mag_spec); if (*mag_spec == '\0') return; ParseCutSpec(mag_spec,image_w,image_h,&mag,&src_x,&src_y,&src_w,&src_h); if (src_x==0 && src_y==0 && src_w==image_w && src_h==image_h && mag==1.0) { return; } if (src_w==0 || src_h==0) { MsgBox(TgLoadString(STID_XBM_CANT_HAVE_0_W_OR_H), TOOL_NAME, INFO_MB); return; } PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); if (!ExtractBitmap(obj_ptr->detail.xbm->bitmap, obj_ptr->detail.xbm->image, src_x, src_y, src_w, src_h, &dest_bitmap, &dest_image)) { AbortPrepareCmd(CMD_REPLACE); return; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_NEW_BMP_SIZE_IS_W_X_H), src_w, src_h); Msg(gszMsgBox); UnlinkObj(obj_ptr); ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); w = new_w = (int)(((float)src_w) * mag); h = new_h = (int)(((float)src_h) * mag); new_obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (new_obj_ptr == NULL) FailAllocMessage(); memset(new_obj_ptr, 0, sizeof(struct ObjRec)); DupObjBasics(obj_ptr, new_obj_ptr); new_xbm_ptr = (struct XBmRec *)malloc(sizeof(struct XBmRec)); if (new_xbm_ptr == NULL) FailAllocMessage(); memset(new_xbm_ptr, 0, sizeof(struct XBmRec)); new_obj_ptr->detail.xbm = new_xbm_ptr; new_xbm_ptr->image = dest_image; new_xbm_ptr->image_w = src_w; new_xbm_ptr->image_h = src_h; new_xbm_ptr->bitmap = dest_bitmap; new_xbm_ptr->data = NULL; new_xbm_ptr->fill = obj_ptr->detail.xbm->fill; new_xbm_ptr->flip = obj_ptr->detail.xbm->flip; new_xbm_ptr->cached_zoom = 0; new_xbm_ptr->cached_bitmap = None; new_xbm_ptr->cached_flip = 0; new_xbm_ptr->cached_w = 0; new_xbm_ptr->cached_h = 0; new_w = round(h_scale * ((float)w)); new_h = round(v_scale * ((float)h)); new_obj_ptr->obbox.ltx = obj_ptr->obbox.ltx; new_obj_ptr->obbox.lty = obj_ptr->obbox.lty; new_obj_ptr->obbox.rbx = new_obj_ptr->bbox.rbx = obj_ptr->obbox.ltx+new_w; new_obj_ptr->obbox.rby = new_obj_ptr->bbox.rby = obj_ptr->obbox.lty+new_h; AdjObjBBox(new_obj_ptr); topSel->obj = botSel->obj = new_obj_ptr; AddObj(NULL, topObj, new_obj_ptr); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); FreeObj(obj_ptr); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } static void UpdateColorsLookupTable(color_index) int color_index; { if (colorIndexToDumpIndex[color_index] == INVALID) { if (colorStr[numColorsToDump] != NULL) { free(colorStr[numColorsToDump]); } pixelValue[numColorsToDump] = colorPixels[color_index]; colorIndexToDumpIndex[color_index] = numColorsToDump; dumpIndexToColorIndex[numColorsToDump] = color_index; colorStr[numColorsToDump] = (char *) malloc( (strlen(colorMenuItems[color_index])+1)*sizeof(char)); if (colorStr[numColorsToDump] == NULL) FailAllocMessage(); strcpy(colorStr[numColorsToDump], colorMenuItems[color_index]); numColorsToDump++; } } static void BuildStrSegColors(pStrSeg, pUserData) StrSegInfo *pStrSeg; void *pUserData; { UpdateColorsLookupTable(pStrSeg->color); } static void BuildObjXPmColors(ObjPtr) struct ObjRec *ObjPtr; { register int i, color_index; register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; struct XPmRec *xpm_ptr; int start_index, new_alloc; switch (ObjPtr->type) { case OBJ_POLY: case OBJ_BOX: case OBJ_OVAL: case OBJ_POLYGON: case OBJ_ARC: case OBJ_RCBOX: case OBJ_XBM: UpdateColorsLookupTable(ObjPtr->color); if (ObjPtr->type == OBJ_XBM) { if (ObjPtr->detail.xbm->real_type==XBM_EPS && ObjPtr->detail.xbm->bitmap==None) { char color_str[COLORSTRLEN]; new_alloc = FALSE; GetDrawingFgColorStr(INVALID, INVALID, color_str, sizeof(color_str)); color_index = QuickFindColorIndex(NULL, color_str, &new_alloc, FALSE); if (color_index != INVALID) { if (new_alloc) ExpandTmpStorage(); UpdateColorsLookupTable(color_index); } } } break; case OBJ_TEXT: UpdateColorsLookupTable(ObjPtr->color); DoFuncOnStrSegForMiniLines(&ObjPtr->detail.t->minilines, BuildStrSegColors, NULL); break; case OBJ_XPM: xpm_ptr = ObjPtr->detail.xpm; start_index = (xpm_ptr->first_pixel_is_bg) ? 1 : 0; for (i=start_index; i < xpm_ptr->ncolors; i++) { /* do not translate -- program constants */ if (UtilStrICmp(xpm_ptr->color_str[i], "None") == 0) { if (whereToPrint == XBM_FILE && colorDump && transparentIndex == (-1)) { /* * Transparent stuff pretty much only works for straight * XPM output and nothing else. None of the * convertors (e.g., xpmtoppm) can handle the * None color in an XPM file. */ if (colorStr[numColorsToDump] != NULL) { free(colorStr[numColorsToDump]); } pixelValue[numColorsToDump] = (-1); colorStr[numColorsToDump] = UtilStrDup("None"); transparentIndex = numColorsToDump++; } } else if ((color_index=QuickFindColorIndex(NULL, xpm_ptr->color_str[i], &new_alloc, TRUE)) != INVALID) { if (new_alloc) ExpandTmpStorage(); UpdateColorsLookupTable(color_index); } } if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->first; obj_ptr != NULL; obj_ptr=obj_ptr->next) { BuildObjXPmColors(obj_ptr); } break; case OBJ_PIN: obj_ptr = GetPinObj(ObjPtr); BuildObjXPmColors(obj_ptr); break; } for (attr_ptr=ObjPtr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { BuildObjXPmColors(attr_ptr->obj); } } typedef struct tagTmpBucketInfo { int pixel; struct tagTmpBucketInfo *next; } TmpBucketInfo; static int numTmpBuckets=0; static TmpBucketInfo **ppTmpBuckets=NULL; static int tmpRedShift=0, tmpGreenShift=0, tmpBlueShift=0; static void CleanUpTmpBuckets() { int i=0; if (ppTmpBuckets != NULL) { for (i=0; i < numTmpBuckets; i++) { TmpBucketInfo *ptbi=NULL, *ptbi_next=NULL; for (ptbi=ppTmpBuckets[i]; ptbi != NULL; ptbi=ptbi_next) { ptbi_next = ptbi->next; free(ptbi); } } free(ppTmpBuckets); } tmpRedShift = tmpGreenShift = tmpBlueShift = 0; numTmpBuckets = 0; ppTmpBuckets = NULL; } static int SetTmpShift(mask, pn_shifts) unsigned long mask; int *pn_shifts; { int i=0; if (mask == 0L) return FALSE; while ((mask & 0x1) == 0) { i++; mask >>= 1; } *pn_shifts = i; return TRUE; } static int BadMask(cWhich, mask) char cWhich; unsigned long mask; { switch (cWhich) { case 'r': sprintf(gszMsgBox, TgLoadString(STID_BAD_RED_MASK_TRUE_COLOR_DPY), (long)mask, TOOL_NAME, "UseImagePixelsForTrueColorExport"); break; case 'g': sprintf(gszMsgBox, TgLoadString(STID_BAD_GREEN_MASK_TRUE_COLOR_DPY), (long)mask, TOOL_NAME, "UseImagePixelsForTrueColorExport"); break; case 'b': sprintf(gszMsgBox, TgLoadString(STID_BAD_BLUE_MASK_TRUE_COLOR_DPY), (long)mask, TOOL_NAME, "UseImagePixelsForTrueColorExport"); break; } if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } CleanUpTmpBuckets(); return FALSE; } static int InitTmpBuckets() { numTmpBuckets = 257; ppTmpBuckets = (TmpBucketInfo**)malloc(numTmpBuckets*sizeof(TmpBucketInfo*)); if (ppTmpBuckets == NULL) FailAllocMessage(); memset(ppTmpBuckets, 0, numTmpBuckets*sizeof(TmpBucketInfo*)); if (mainVisual->class != TrueColor) { return TRUE; } if (!SetTmpShift(mainVisual->red_mask, &tmpRedShift)) { return BadMask('r', mainVisual->red_mask); } if (!SetTmpShift(mainVisual->green_mask, &tmpGreenShift)) { return BadMask('g', mainVisual->green_mask); } if (!SetTmpShift(mainVisual->blue_mask, &tmpBlueShift)) { return BadMask('b', mainVisual->blue_mask); } return TRUE; } static int TmpPixelHash(pixel) int pixel; { return (((pixel)==(-1)) ? (numTmpBuckets-1) : (pixel % numTmpBuckets)); } static void GetTmpValue(pixel, mask, shift, pn_value) int pixel, shift, *pn_value; unsigned long mask; { double d_val=(double)0; int value=0; pixel = (int)(pixel & mask); pixel >>= shift; mask >>= shift; d_val = ((double)pixel) / ((double)mask) * ((double)0x0ff); value = round(d_val); if (value > 0x0ff) value = 0x0ff; if (value < 0) value = 0; *pn_value = value; } static void GetTmpColorStr(pixel, color_str) int pixel; char *color_str; { int red_value=0, green_value=0, blue_value=0; if (mainVisual->class == TrueColor) { GetTmpValue(pixel, mainVisual->red_mask, tmpRedShift, &red_value); GetTmpValue(pixel, mainVisual->green_mask, tmpGreenShift, &green_value); GetTmpValue(pixel, mainVisual->blue_mask, tmpBlueShift, &blue_value); sprintf(color_str, "#%c%c%c%c%c%c", hexValue[(red_value>>4)&0x0f], hexValue[red_value&0x0f], hexValue[(green_value>>4)&0x0f], hexValue[green_value&0x0f], hexValue[(blue_value>>4)&0x0f], hexValue[blue_value&0x0f]); } else { XColor xcolor; memset(&xcolor, 0, sizeof(XColor)); xcolor.pixel = pixel; XQueryColor(mainDisplay, mainColormap, &xcolor); red_value = xcolor.red; green_value = xcolor.green; blue_value = xcolor.blue; sprintf(color_str, "#%c%c%c%c%c%c", hexValue[(red_value>>12)&0x0f], hexValue[(red_value>>8)&0x0f], hexValue[(green_value>>12)&0x0f], hexValue[(green_value>>8)&0x0f], hexValue[(blue_value>>12)&0x0f], hexValue[(blue_value>>8)&0x0f]); } } static void UpdateColorsLookupTableForPixel(pixel, can_alloc) int pixel, can_alloc; { char color_str[COLORSTRLEN]; int bucket=TmpPixelHash(pixel); TmpBucketInfo *ptbi=NULL; for (ptbi=ppTmpBuckets[bucket]; ptbi != NULL; ptbi=ptbi->next) { if (ptbi->pixel == pixel) { return; } } ptbi = (TmpBucketInfo*)malloc(sizeof(TmpBucketInfo)); if (ptbi == NULL) FailAllocMessage(); memset(ptbi, 0, sizeof(TmpBucketInfo)); ptbi->next = ppTmpBuckets[bucket]; ppTmpBuckets[bucket] = ptbi; ptbi->pixel = pixel; if (can_alloc && numColorsToDump >= maxColors) { maxColors++; ExpandTmpStorage(); } UtilFree(colorStr[numColorsToDump]); pixelValue[numColorsToDump] = pixel; *color_str = '\0'; GetTmpColorStr(pixel, color_str); colorStr[numColorsToDump] = UtilStrDup(color_str); numColorsToDump++; } static void BuildXPmColors(image, w, h, left, top, right, bottom, use_pixels) XImage *image; int w, h, left, top, right, bottom, use_pixels; { int i; FreeCachedStrings(); if (colorChar == NULL) { pixelValue = (int*)malloc((maxColors+3)*sizeof(int)); if (pixelValue == NULL) FailAllocMessage(); colorIndexToDumpIndex = (int*)malloc((maxColors+3)*sizeof(int)); dumpIndexToColorIndex = (int*)malloc((maxColors+3)*sizeof(int)); if (colorIndexToDumpIndex == NULL || dumpIndexToColorIndex == NULL) { FailAllocMessage(); } if (maxColors > 20) { charsPerPixel = 2; colorChar = (char*)malloc(((maxColors<<1)+6)*sizeof(char)); } else { charsPerPixel = 1; colorChar = (char*)malloc((maxColors+3)*sizeof(char)); } if (colorChar == NULL) FailAllocMessage(); colorStr = (char**)malloc((maxColors+3)*sizeof(char*)); if (colorStr == NULL) FailAllocMessage(); memset(colorStr, 0, (maxColors+3)*sizeof(char*)); } for (i = 0; i < maxColors+3; i++) { colorIndexToDumpIndex[i] = dumpIndexToColorIndex[i] = INVALID; } pixelValue[0] = GetDrawingBgPixel(INVALID, INVALID); if (myFileBgColorStr == NULL) { colorStr[0] = (char*)malloc((strlen(myBgColorStr)+1)*sizeof(char)); if (colorStr[0] == NULL) FailAllocMessage(); strcpy(colorStr[0], myBgColorStr); } else { colorStr[0] = (char*)malloc((strlen(myFileBgColorStr)+1)*sizeof(char)); if (colorStr[0] == NULL) FailAllocMessage(); strcpy(colorStr[0], myFileBgColorStr); } numColorsToDump = 1; if ((use_pixels || (mainVisual->class == TrueColor && useImagePixelsForTrueColorExport)) && !InitTmpBuckets()) { if (!use_pixels) { useImagePixelsForTrueColorExport = FALSE; } else { use_pixels = FALSE; } } if ((use_pixels || (mainVisual->class == TrueColor && useImagePixelsForTrueColorExport))) { SetStringStatus(TgLoadCachedString(CSTID_BLD_COLOR_TBL_FROM_PIXEL_DOTS)); for (i=top; i < h-bottom; i++) { int j=0; for (j=left; j < w-right; j++) { int pixel=XGetPixel(image,j-left,i-top); UpdateColorsLookupTableForPixel(pixel, FALSE); } } CleanUpTmpBuckets(); } else { struct ObjRec *obj_ptr=NULL; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { BuildObjXPmColors(obj_ptr); } } colorChar[0] = '`'; if (charsPerPixel > 1) colorChar[1] = '`'; if (numColorsToDump >= 256) { for (i=1; i < numColorsToDump; i++) { if (charsPerPixel == 1) { colorChar[i] = (char)(((int)('a'))+i-1); } else { int left=(int)(i/80), right=(i%80); if (left >= 31) { colorChar[i*2] = (char)(((int)('/'))+left-31); } else { colorChar[i*2] = (char)(((int)('`'))+left); } if (right >= 31) { colorChar[i*2+1] = (char)(((int)('/'))+right-31); } else { colorChar[i*2+1] = (char)(((int)('`'))+right); } } } } else { for (i=1; i < numColorsToDump; i++) { if (charsPerPixel == 1) { colorChar[i] = (char)(((int)('a'))+i-1); } else { colorChar[i*2] = (char)(((int)('a'))+(int)(i/10)); colorChar[i*2+1] = (char)(((int)('0'))+(i%10)); } } } } static void ColorStrToXPmStr(index, color_str) int index; char *color_str; { char s[3]; int i, value; if (*(colorStr[index]) == '#') { strcpy(color_str, colorStr[index]); } else { for (i = 0; i < maxColors; i++) { if (colorPixels[i] == pixelValue[index]) { break; } } if (i == maxColors) { strcpy(color_str, colorStr[index]); } else { strcpy(color_str, "#"); value = (int)(((float)tgifColors[i].red/maxRGB) * 0x100); if (value > 255) { value = 255; } else if (value < 255) { value = 0; } sprintf(s, "%c%c", hexValue[(value>>4)&0x0f], hexValue[value&0x0f]); strcat(color_str, s); strcat(color_str, s); value = (int)(((float)tgifColors[i].green/maxRGB) * 0x100); if (value > 255) { value = 255; } else if (value < 255) { value = 0; } sprintf(s, "%c%c", hexValue[(value>>4)&0x0f], hexValue[value&0x0f]); strcat(color_str, s); strcat(color_str, s); value = (int)(((float)tgifColors[i].blue/maxRGB) * 0x100); if (value > 255) { value = 255; } else if (value < 255) { value = 0; } sprintf(s, "%c%c", hexValue[(value>>4)&0x0f], hexValue[value&0x0f]); strcat(color_str, s); strcat(color_str, s); } } } static void DumpXPmColors(FP) FILE *FP; { int i, j; char s[MAXSTRING]; if (xpmOutputVersion == 1) { if (xpmInXGrabSCFormat) { for (i=0; i < numColorsToDump-1; i++) { if (fprintf(FP, "\"") == EOF) writeFileFailed = TRUE; for (j = 0; j < charsPerPixel; j++) { if (fprintf(FP, "%c", colorChar[i*charsPerPixel+j]) == EOF) { writeFileFailed = TRUE; } } ColorStrToXPmStr(i, s); if (fprintf(FP, "\", \"%s\"\n", s) == EOF) writeFileFailed = TRUE; } if (fprintf(FP, "\"") == EOF) writeFileFailed = TRUE; for (j = 0; j < charsPerPixel; j++) { if (fprintf(FP, "%c", colorChar[i*charsPerPixel+j]) == EOF) { writeFileFailed = TRUE; } } ColorStrToXPmStr(i, s); if (fprintf(FP, "\", \"%s\"\n} ;\n", s) == EOF) { writeFileFailed = TRUE; } } else { for (i=0; i < numColorsToDump-1; i++) { if (fprintf(FP, " \"") == EOF) writeFileFailed = TRUE; for (j = 0; j < charsPerPixel; j++) { if (fprintf(FP, "%c", colorChar[i*charsPerPixel+j]) == EOF) { writeFileFailed = TRUE; } } if (fprintf(FP, "\", \"%s\",\n", colorStr[i]) == EOF) { writeFileFailed = TRUE; } } if (fprintf(FP, " \"") == EOF) writeFileFailed = TRUE; for (j = 0; j < charsPerPixel; j++) { if (fprintf(FP, "%c", colorChar[i*charsPerPixel+j]) == EOF) { writeFileFailed = TRUE; } } if (fprintf(FP, "\", \"%s\"\n};\n", colorStr[i]) == EOF) { writeFileFailed = TRUE; } } } else { /* xpmOutputVersion is 3 */ for (i=0; i < numColorsToDump; i++) { if (fprintf(FP, "\"") == EOF) writeFileFailed = TRUE; for (j = 0; j < charsPerPixel; j++) { if (fprintf(FP, "%c", colorChar[i*charsPerPixel+j]) == EOF) { writeFileFailed = TRUE; } } if (fprintf(FP, " c %s\",\n", colorStr[i]) == EOF) { writeFileFailed = TRUE; } } } } static int SetupTrueColorInfoFromImage(image, ptci) XImage *image; TrueColorInfo *ptci; { unsigned int r_mask=0, g_mask=0, b_mask=0; unsigned int r_maxval=0, g_maxval=0, b_maxval=0; unsigned int r_bits=0, g_bits=0, b_bits=0; int r_shift=(-1), g_shift=(-1), b_shift=(-1); unsigned int shifts=0; ptci->r_mask = r_mask = image->red_mask; ptci->g_mask = g_mask = image->green_mask; ptci->b_mask = b_mask = image->blue_mask; if (r_mask == 0 && g_mask == 0 && b_mask == 0) { if (PRTGIF && !cmdLineOpenDisplay) { FatalUnexpectedError( /* debug, do not translate */ "Unimplemented in SetupTrueColorInfoFromImage().", NULL); return FALSE; } return SetupTrueColorInfo(ptci); } for (shifts=0; r_mask|g_mask|b_mask; shifts++) { if (r_mask & 0x1) { if (r_shift == (-1)) { r_shift = shifts; r_maxval = r_mask; } r_bits++; } if (g_mask & 0x1) { if (g_shift == (-1)) { g_shift = shifts; g_maxval = g_mask; } g_bits++; } if (b_mask & 0x1) { if (b_shift == (-1)) { b_shift = shifts; b_maxval = b_mask; } b_bits++; } r_mask >>= 1; g_mask >>= 1; b_mask >>= 1; } ptci->r_shift = (unsigned int)r_shift; ptci->g_shift = (unsigned int)g_shift; ptci->b_shift = (unsigned int)b_shift; ptci->dr_maxval = (double)r_maxval; ptci->dg_maxval = (double)g_maxval; ptci->db_maxval = (double)b_maxval; ptci->dr_maxval_div255 = ptci->dr_maxval / ((double)255); ptci->dg_maxval_div255 = ptci->dg_maxval / ((double)255); ptci->db_maxval_div255 = ptci->db_maxval / ((double)255); ptci->num_r_bits = r_bits; ptci->num_g_bits = g_bits; ptci->num_b_bits = b_bits; if (r_shift==(-1) || g_shift==(-1) || b_shift==(-1)) { return FALSE; } return TRUE; } int InitTrueColorInfo(image, ptci, image_w) XImage *image; TrueColorInfo *ptci; int image_w; { unsigned int bytes_per_pixel=image->bits_per_pixel/8; memset(ptci, 0, sizeof(TrueColorInfo)); if (bytes_per_pixel > 4) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "bytes_per_pixel (%1d) > 4 in InitTrueColorInfo().\n", bytes_per_pixel); #endif /* _TGIF_DBG */ return FALSE; } if ((unsigned int)(image->bytes_per_line/image_w) != bytes_per_pixel) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "bytes_per_pixel (%1d) != %1d %s.\n", bytes_per_pixel, (unsigned int)(image->bytes_per_line/image_w), "in InitTrueColorInfo()"); #endif /* _TGIF_DBG */ return FALSE; } return SetupTrueColorInfoFromImage(image, ptci); } /* * static * void MapPixToEPSI(SrcX, SrcY, SrcW, SrcH, DestW, DestH, DestX, DestY) * int SrcX, SrcY, SrcW, SrcH, DestW, DestH, * DestX, * DestY; * { * if (pageStyle == LANDSCAPE) * { * *DestY = (int)round(((float)DestH) - * ((((float)DestH)*((float)SrcX))/((float)SrcW))); * *DestX = (int)round((((float)DestW)*((float)SrcY))/((float)SrcH)); * } * else * { * *DestX = (int)round((((float)DestW)*((float)SrcX))/((float)SrcW)); * *DestY = (int)round((((float)DestH)*((float)SrcY))/((float)SrcH)); * } * if (*DestX >= DestW) *DestX = DestW-1; if (*DestX < 0) *DestX = 0; * if (*DestY >= DestH) *DestY = DestH-1; if (*DestY < 0) *DestY = 0; * } */ static void MapEPSIToPix(DestX, DestY, DestW, DestH, SrcW, SrcH, SrcX, SrcY) int DestX, DestY, DestW, DestH, SrcW, SrcH, * SrcX, * SrcY; { if (pageStyle == LANDSCAPE) { *SrcX = (int)round(((float)(DestH-DestY))*((float)SrcW)/((float)DestH)); *SrcY = (int)round((((float)SrcH)*((float)DestX))/((float)DestW)); } else { *SrcX = (int)round((((float)SrcW)*((float)DestX))/((float)DestW)); *SrcY = (int)round((((float)SrcH)*((float)DestY))/((float)DestH)); } if (*SrcX >= SrcW) *SrcX = SrcW-1; if (*SrcX < 0) *SrcX = 0; if (*SrcY >= SrcH) *SrcY = SrcH-1; if (*SrcY < 0) *SrcY = 0; } void GenPreviewBitmap(FP, llxPage, llyPage, urxPage, uryPage) FILE *FP; int llxPage, llyPage, urxPage, uryPage; { int col=0, row=0, ltx=0, lty=0, w=0, h=0, x=0, y=0; int **data=NULL, num_image_bytes_per_row=0; int image_w=urxPage-llxPage, image_h=uryPage-llyPage, num_lines=0; Pixmap pixmap=None; XImage *image=NULL; TrueColorInfo tci; if (image_w == 0 || image_h == 0) return; if ((pixmap=DrawAllOnPixmap(<x, <y, &w, &h, TRUE)) == None) return; image = XGetImage(mainDisplay, pixmap, 0, 0, w, h, AllPlanes, ZPixmap); if (image == NULL) { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); XFreePixmap(mainDisplay, pixmap); return; } if (fullTrueColorMode) { if (!InitTrueColorInfo(image, &tci, w)) { XDestroyImage(image); XFreePixmap(mainDisplay, pixmap); return; } } if (image_w < 0) image_w = (-image_w); if (image_h < 0) image_h = (-image_h); num_image_bytes_per_row = ((image_w & 0x7) ? (image_w>>3)+1 : (image_w>>3)); num_lines = ((image_w & 0x7) ? (((image_w>>3)+1)<<1) : ((image_w>>3)<<1)); num_lines = ((num_lines & 0x3f) ? (num_lines>>6)+1 : (num_lines>>6)); if ((data=(int**)malloc(image_h*sizeof(int*))) == NULL) { FailAllocMessage(); return; } for (row=0; row < image_h; row++) { if ((data[row]=(int*)malloc(num_image_bytes_per_row*sizeof(int))) == NULL) { FailAllocMessage(); return; } else { for (col=0; col<num_image_bytes_per_row; col++) data[row][col] = 0; } } fprintf(FP, "%%%%BeginPreview: %1d %1d 1 %1d\n", image_w, image_h, num_lines*image_h); for (row=0; row < image_h; row++) { int bg_pixel=GetDrawingBgPixel(INVALID, INVALID); for (col=0; col < image_w; col++) { int pixel=XGetPixel(image, x, y); MapEPSIToPix(col, row, image_w, image_h, w, h, &x, &y); if (epsiThresholdPreviewBitmap) { double gray=(double)0; if (fullTrueColorMode) { uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; r = (pix & tci.r_mask) >> tci.r_shift; g = (pix & tci.g_mask) >> tci.g_shift; b = (pix & tci.b_mask) >> tci.b_shift; dr = ((double)r) / tci.dr_maxval; dg = ((double)g) / tci.dg_maxval; db = ((double)b) / tci.db_maxval; gray = (double)(0.299*dr + 0.587*dg + 0.114*db); } else { int k=0, found_index=INVALID; for (k=0; k < maxColors; k++) { if (colorPixels[k] == pixel) { found_index = k; break; } } if (found_index == INVALID) { if (pixel == bg_pixel) { gray = (double)1.0; } else { sprintf(gszMsgBox, TgLoadString(STID_UNRECOG_GIVEN_PIXEL_VAL_1_USE), pixel, (long)pixel); Msg(gszMsgBox); gray = (double)0.0; } } else { gray = 0.299*((double)tgifColors[found_index].red/maxRGB) + 0.587*((double)tgifColors[found_index].green/maxRGB) + 0.114*((double)tgifColors[found_index].blue/maxRGB); } } if (gray < epsiPreviewBitmapThreshold) { data[row][col>>3] |= (1<<(7 - (col & 0x7))); } } else { if (pixel != bg_pixel) { data[row][col>>3] |= (1<<(7 - (col & 0x7))); } } } } for (row=0; row < image_h; row++) { int byte_count=0; fprintf(FP, "%% "); for (col=0; col < num_image_bytes_per_row; col++) { if (byte_count++ == 32) { byte_count = 1; fprintf(FP, "\n%% "); } fprintf(FP, "%c", hexValue[(data[row][col]>>4) & 0xf]); fprintf(FP, "%c", hexValue[data[row][col] & 0xf]); } fprintf(FP, "\n"); } fprintf(FP, "%%%%EndImage\n"); fprintf(FP, "%%%%EndPreview\n"); for (row=0; row < image_h; row++) free(data[row]); free(data); XDestroyImage(image); XFreePixmap(mainDisplay, pixmap); } static char defXpmToGif[]="xpmtoppm %s | ppmtogif"; static char defXpmToPng[]="xpmtoppm %s | pnmtopng"; static char defXpmToJpeg[]="xpmtoppm %s | cjpeg"; static char defPpmToGif[]="ppmquant 222 %s | ppmtogif"; static char defPpmToPng[]="pnmtopng %s"; static char defPpmToPngWithTrans[]="pnmtopng -transparent %s %s"; static char defPpmToJpeg[]="cjpeg %s"; static char defPpm6ToXpm3[]="ppmtoxpm %s"; static char defXpmDeckToGifAnim[]="gifsicle -lforever --delay 10"; static void InitImageMap() { char *c_ptr; if (generateImageMap != INVALID) return; generateImageMap = FALSE; if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"GenerateImageMap")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { generateImageMap = TRUE; } } strcpy(xpmToGifCmd, defXpmToGif); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"XpmToGif")) != NULL) { int count=0; strcpy(xpmToGifCmd, c_ptr); UtilTrimBlanks(xpmToGifCmd); for (c_ptr=strstr(xpmToGifCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "XpmToGif", xpmToGifCmd, defXpmToGif); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(xpmToGifCmd, defXpmToGif); } } } strcpy(ppmToGifCmd, defPpmToGif); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PpmToGif")) != NULL) { int count=0; strcpy(ppmToGifCmd, c_ptr); UtilTrimBlanks(ppmToGifCmd); for (c_ptr=strstr(ppmToGifCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PpmToGif", ppmToGifCmd, defPpmToGif); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(ppmToGifCmd, defPpmToGif); } } } strcpy(gifFileExtension, "gif"); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"GifFileExtension")) != NULL) { strcpy(gifFileExtension, c_ptr); } } strcpy(xpmToPngCmd, defXpmToPng); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"XpmToPng")) != NULL) { int count=0; strcpy(xpmToPngCmd, c_ptr); UtilTrimBlanks(xpmToPngCmd); for (c_ptr=strstr(xpmToPngCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "XpmToPng", xpmToPngCmd, defXpmToPng); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(xpmToPngCmd, defXpmToPng); } } } strcpy(ppmToPngCmd, defPpmToPng); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PpmToPng")) != NULL) { int count=0; strcpy(ppmToPngCmd, c_ptr); UtilTrimBlanks(ppmToPngCmd); for (c_ptr=strstr(ppmToPngCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PpmToPng", ppmToPngCmd, defPpmToPng); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(ppmToPngCmd, defPpmToPng); } } } strcpy(ppmToPngWithTransCmd, defPpmToPngWithTrans); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "PpmToPngWithTransparentColor")) != NULL) { int count=0; strcpy(ppmToPngWithTransCmd, c_ptr); UtilTrimBlanks(ppmToPngWithTransCmd); for (c_ptr=strstr(ppmToPngWithTransCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 2) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PpmToPngWithTransparentColor", ppmToPngWithTransCmd, defPpmToPngWithTrans); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(ppmToPngWithTransCmd, defPpmToPngWithTrans); } } } strcpy(pngFileExtension, "png"); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PngFileExtension")) != NULL) { strcpy(pngFileExtension, c_ptr); } } strcpy(xpmToJpegCmd, defXpmToJpeg); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"XpmToJpeg")) != NULL) { int count=0; strcpy(xpmToJpegCmd, c_ptr); UtilTrimBlanks(xpmToJpegCmd); for (c_ptr=strstr(xpmToJpegCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "XpmToJpeg", xpmToJpegCmd, defXpmToJpeg); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(xpmToJpegCmd, defXpmToJpeg); } } } strcpy(ppmToJpegCmd, defPpmToJpeg); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PpmToJpeg")) != NULL) { int count=0; strcpy(ppmToJpegCmd, c_ptr); UtilTrimBlanks(ppmToJpegCmd); for (c_ptr=strstr(ppmToJpegCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PpmToJpeg", ppmToJpegCmd, defPpmToJpeg); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(ppmToJpegCmd, defPpmToJpeg); } } } strcpy(ppm6ToXpm3Cmd, defPpm6ToXpm3); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"Ppm6ToXpm3")) != NULL) { int count=0; strcpy(ppm6ToXpm3Cmd, c_ptr); UtilTrimBlanks(ppm6ToXpm3Cmd); for (c_ptr=strstr(ppm6ToXpm3Cmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PpmToJpeg", ppm6ToXpm3Cmd, defPpm6ToXpm3); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(ppm6ToXpm3Cmd, defPpm6ToXpm3); } } } strcpy(jpegFileExtension, "jpeg"); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"JpegFileExtension")) != NULL) { strcpy(jpegFileExtension, c_ptr); } } #ifdef _XPM3TOPPM useXPmVersion1ForImageMap = FALSE; #else /* ~_XPM3TOPPM */ useXPmVersion1ForImageMap = TRUE; #endif /* _XPM3TOPPM */ if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "UseXPmVersion1ForImageMap")) != NULL) { if (UtilStrICmp("false",c_ptr) == 0) { useXPmVersion1ForImageMap = FALSE; } else if (UtilStrICmp("true",c_ptr) == 0) { useXPmVersion1ForImageMap = TRUE; } } } useXPmVersion1ForXPmDeck = TRUE; if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "UseXPmVersion1ForXPmDeck")) != NULL && UtilStrICmp("false",c_ptr) == 0) { useXPmVersion1ForXPmDeck = FALSE; } } strcpy(imageMapFileExtension, "map"); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ImageMapFileExtension")) != NULL) { strcpy(imageMapFileExtension, c_ptr); } } imageMapFileFormat = IMF_FORMAT_NCSA; if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ImageMapFileFormat")) != NULL) { if (strcmp(c_ptr, "NCSA") == 0) { imageMapFileFormat = IMF_FORMAT_NCSA; } else if (strcmp(c_ptr, "CERN") == 0) { imageMapFileFormat = IMF_FORMAT_CERN; } else { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "ImageMapFileFormat", c_ptr, "NCSA"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } } strcpy(htmlFileExtension, "html"); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "HtmlFileExtension")) != NULL && (*c_ptr != '\0')) { strcpy(htmlFileExtension, c_ptr); } } generateHtmlHref = TRUE; if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "GenerateHtmlHref")) != NULL) { if (UtilStrICmp(c_ptr, "false") == 0) { generateHtmlHref = FALSE; } } } strcpy(xpmDeckToGifAnimCmd, defXpmDeckToGifAnim); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"XpmDeckToGifAnim")) != NULL) { strcpy(xpmDeckToGifAnimCmd, c_ptr); UtilTrimBlanks(xpmDeckToGifAnimCmd); if (strstr(xpmDeckToGifAnimCmd, "%s") != NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "XpmDeckToGifAnim", xpmDeckToGifAnimCmd, defXpmDeckToGifAnim); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(xpmDeckToGifAnimCmd, defXpmDeckToGifAnim); } } } } static char *ModifyToGenerateHtmlHref(value_str) char *value_str; /* data in value_str is not supposed to be touched on return */ { char *href=NULL, *name=NULL, *pound=NULL, *dot=NULL; int len=0; if (generateHtmlHref && imageMapFileFormat==IMF_FORMAT_SPYG) { if (value_str[0] == '#' && strchr(value_str, DIR_SEP) == NULL && (((!(PRTGIF && !cmdLineOpenDisplay)) && dumpOneFilePerPage) || (PRTGIF && !cmdLineOpenDisplay && cmdLineOneFilePerPage))) { char page_spec[MAXSTRING]; int page_num=0; if (GetPageNumFromPageSpec(&value_str[1], &page_num)) { sprintf(page_spec, "%1d", page_num); if ((name=UtilStrRChr(curFileName, DIR_SEP)) == NULL) { name = curFileName; } else { name++; } pound = strchr(name, '#'); if (pound != NULL) *pound = '\0'; dot = UtilStrRChr(name, '.'); if (dot != NULL) { *dot = '\0'; len = strlen(name)+strlen(page_spec)+strlen(htmlFileExtension)+3; href = (char*)malloc((len+1)*sizeof(char)); if (href == NULL) FailAllocMessage(); sprintf(href, "%s-%1d.%s", name, page_num, htmlFileExtension); *dot = '.'; } if (pound != NULL) *pound = '#'; } else { /* Cannot get page number information, may be it's okay! */ } } else { if ((name=UtilStrRChr(value_str, DIR_SEP)) == NULL) { name = value_str; } else { name++; } pound = strchr(name, '#'); if (pound != NULL) *pound = '\0'; dot = UtilStrRChr(name, '.'); if (dot != NULL && ((UtilStrICmp(&dot[1], "obj")==0 || UtilStrICmp(&dot[1], OBJ_FILE_EXT)==0) || UtilStrICmp(&dot[1], "sym")==0 || UtilStrICmp(&dot[1], SYM_FILE_EXT)==0)) { *dot = '\0'; len = strlen(value_str)+strlen(htmlFileExtension)+2; if (pound != NULL) len += strlen(£[1])+1; href = (char*)malloc((len+1)*sizeof(char)); if (href == NULL) FailAllocMessage(); if (pound != NULL) { sprintf(href, "%s.%s#%s", value_str, htmlFileExtension, £[1]); } else { sprintf(href, "%s.%s", value_str, htmlFileExtension); } *dot = '.'; } if (pound != NULL) *pound = '#'; } } return href; } static int GenerateObjImageMap(FP, ObjPtr, LtX, LtY) FILE *FP; struct ObjRec *ObjPtr; int LtX, LtY; { register int i; int n, something_generated=FALSE; struct AttrRec *attr_ptr; struct ObjRec *obj_ptr; IntPoint *v=NULL; if ((attr_ptr=FindAttrWithName(ObjPtr, "href=", NULL)) != NULL) { char *href=ModifyToGenerateHtmlHref(attr_ptr->attr_value.s); switch (ObjPtr->type) { case OBJ_POLY: case OBJ_POLYGON: if (ObjPtr->type == OBJ_POLY) { n = ObjPtr->detail.p->n; v = ObjPtr->detail.p->vlist; } else { n = ObjPtr->detail.g->n; v = ObjPtr->detail.g->vlist; } switch (imageMapFileFormat) { case IMF_FORMAT_NCSA: fprintf(FP, "\npoly %s", attr_ptr->attr_value.s); for (i=0; i < n; i++) { fprintf(FP, " %1d,%1d", v[i].x-LtX, v[i].y-LtY); } fprintf(FP, "\n"); break; case IMF_FORMAT_CERN: fprintf(FP, "\npoly"); for (i=0; i < n; i++) { fprintf(FP, " (%1d,%1d)", v[i].x-LtX, v[i].y-LtY); } fprintf(FP, " %s\n", attr_ptr->attr_value.s); break; case IMF_FORMAT_SPYG: fprintf(FP, "<AREA SHAPE=\"POLY\" COORDS=\""); for (i=0; i < n; i++) { fprintf(FP, "%s%1d,%1d", (i==0 ? "" : ","), v[i].x-LtX, v[i].y-LtY); } fprintf(FP, "\" HREF=\"%s\">\n", (href != NULL ? href : attr_ptr->attr_value.s)); break; default: break; } break; case OBJ_OVAL: if (ObjPtr->obbox.rbx-ObjPtr->obbox.ltx == ObjPtr->obbox.rby-ObjPtr->obbox.lty) { switch (imageMapFileFormat) { case IMF_FORMAT_NCSA: fprintf(FP, "\ncircle %s %1d,%1d %1d,%1d\n", attr_ptr->attr_value.s, ((ObjPtr->obbox.ltx+ObjPtr->obbox.rbx)>>1)-LtX, ((ObjPtr->obbox.lty+ObjPtr->obbox.rby)>>1)-LtY, ObjPtr->obbox.rbx-LtX, ((ObjPtr->obbox.lty+ObjPtr->obbox.rby)>>1)-LtY); break; case IMF_FORMAT_CERN: fprintf(FP, "\ncircle (%1d,%1d) %1d %s\n", ((ObjPtr->obbox.ltx+ObjPtr->obbox.rbx)>>1)-LtX, ((ObjPtr->obbox.lty+ObjPtr->obbox.rby)>>1)-LtY, (ObjPtr->obbox.rbx-ObjPtr->obbox.ltx)>>1, attr_ptr->attr_value.s); break; case IMF_FORMAT_SPYG: fprintf(FP, "<AREA SHAPE=\"CIRCLE\" COORDS=\""); fprintf(FP, "%1d,%1d,%1d", ((ObjPtr->obbox.ltx+ObjPtr->obbox.rbx)>>1)-LtX, ((ObjPtr->obbox.lty+ObjPtr->obbox.rby)>>1)-LtY, (ObjPtr->obbox.rbx-ObjPtr->obbox.ltx)>>1); fprintf(FP, "\" HREF=\"%s\">\n", (href != NULL ? href : attr_ptr->attr_value.s)); break; default: break; } } else { switch (imageMapFileFormat) { case IMF_FORMAT_NCSA: fprintf(FP, "\nrect %s %1d,%1d %1d,%1d\n", attr_ptr->attr_value.s, ObjPtr->obbox.ltx-LtX, ObjPtr->obbox.lty-LtY, ObjPtr->obbox.rbx-LtX, ObjPtr->obbox.rby-LtY); break; case IMF_FORMAT_CERN: fprintf(FP, "\nrect (%1d,%1d) (%1d,%1d) %s\n", ObjPtr->obbox.ltx-LtX, ObjPtr->obbox.lty-LtY, ObjPtr->obbox.rbx-LtX, ObjPtr->obbox.rby-LtY, attr_ptr->attr_value.s); break; case IMF_FORMAT_SPYG: fprintf(FP, "<AREA SHAPE=\"RECT\" COORDS=\""); fprintf(FP, "%1d,%1d,%1d,%1d", ObjPtr->obbox.ltx-LtX, ObjPtr->obbox.lty-LtY, ObjPtr->obbox.rbx-LtX, ObjPtr->obbox.rby-LtY); fprintf(FP, "\" HREF=\"%s\">\n", (href != NULL ? href : attr_ptr->attr_value.s)); break; default: break; } } break; default: switch (imageMapFileFormat) { case IMF_FORMAT_NCSA: fprintf(FP, "\nrect %s %1d,%1d %1d,%1d\n", attr_ptr->attr_value.s, ObjPtr->obbox.ltx-LtX, ObjPtr->obbox.lty-LtY, ObjPtr->obbox.rbx-LtX, ObjPtr->obbox.rby-LtY); break; case IMF_FORMAT_CERN: fprintf(FP, "\nrect (%1d,%1d) (%1d,%1d) %s\n", ObjPtr->obbox.ltx-LtX, ObjPtr->obbox.lty-LtY, ObjPtr->obbox.rbx-LtX, ObjPtr->obbox.rby-LtY, attr_ptr->attr_value.s); break; case IMF_FORMAT_SPYG: fprintf(FP, "<AREA SHAPE=\"RECT\" COORDS=\""); fprintf(FP, "%1d,%1d,%1d,%1d", ObjPtr->obbox.ltx-LtX, ObjPtr->obbox.lty-LtY, ObjPtr->obbox.rbx-LtX, ObjPtr->obbox.rby-LtY); fprintf(FP, "\" HREF=\"%s\">\n", (href != NULL ? href : attr_ptr->attr_value.s)); break; default: break; } break; } if (href != NULL) free(href); return TRUE; } switch (ObjPtr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->first; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (GenerateObjImageMap (FP, obj_ptr, LtX, LtY)) { something_generated = TRUE;; } } break; case OBJ_PIN: obj_ptr = GetPinObj(ObjPtr); if (GenerateObjImageMap(FP, obj_ptr, LtX, LtY)) { something_generated = TRUE;; } break; } return something_generated; } static void GenerateHtmlHeader(map_fp) FILE *map_fp; { struct AttrRec *attr_ptr; fprintf(map_fp, "<HTML>\n<HEAD>\n"); if (curPage->name != NULL && *curPage->name != '\0') { fprintf(map_fp, "<TITLE>\n%s\n\n", curPage->name); } else if ((attr_ptr=FindFileAttrWithName("title=")) != NULL) { fprintf(map_fp, "\n%s\n\n", attr_ptr->attr_value.s); } if ((attr_ptr=FindFileAttrWithName("base=")) != NULL) { fprintf(map_fp, "\n", attr_ptr->attr_value.s); } if ((attr_ptr=FindFileAttrWithName("made=")) != NULL) { fprintf(map_fp, "\n", attr_ptr->attr_value.s); } if ((attr_ptr=FindFileAttrWithName("keywords=")) != NULL) { fprintf(map_fp, "\n", attr_ptr->attr_value.s); } fprintf(map_fp, "\n\n"); } static void GenerateUseMapHeader(map_fp, gif_fname, map_fname) FILE *map_fp; char *gif_fname, *map_fname; { char *gif_fname_ptr=UtilStrRChr(gif_fname, DIR_SEP); char *map_fname_ptr=UtilStrRChr(map_fname, DIR_SEP); int page_num=0; struct AttrRec *attr_ptr; if (gif_fname_ptr != NULL) gif_fname_ptr++; if (map_fname_ptr != NULL) map_fname_ptr++; fprintf(map_fp, "

\n"); attr_ptr = FindFileAttrWithName("alt="); if (attr_ptr != NULL) { fprintf(map_fp, "\"%s\"\n", attr_ptr->attr_value.s, (gif_fname_ptr==NULL ? "unknown" : gif_fname_ptr), (map_fname_ptr==NULL ? "unknown" : map_fname_ptr), page_num); } else { fprintf(map_fp, "\n", (gif_fname_ptr==NULL ? "unknown" : gif_fname_ptr), (map_fname_ptr==NULL ? "unknown" : map_fname_ptr), page_num); } fprintf(map_fp, "

\n"); fprintf(map_fp, "\n", page_num); } static void GenerateUseMapTrailer(map_fp, W, H) FILE *map_fp; int W, H; { struct AttrRec *attr_ptr=FindFileAttrWithName("href="); if (attr_ptr != NULL) { char *href=ModifyToGenerateHtmlHref(attr_ptr->attr_value.s); fprintf(map_fp, "\n", (href != NULL ? href : attr_ptr->attr_value.s)); if (href != NULL) free(href); } fprintf(map_fp, "\n"); } static void GenerateHtmlTrailer(map_fp) FILE *map_fp; { fprintf(map_fp, "\n\n"); } static FILE *OpenMapFile(pszMapFile) char *pszMapFile; { FILE *pFile=fopen(pszMapFile, "w"); if (pFile == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), pszMapFile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } return pFile; } static void DumpCommentInBitmapExport(fp) FILE *fp; { if (commentInBitmapExport) { fprintf(fp, "/*\n"); fprintf(fp, " * @%s%s\n", "(#)$H", "eader$"); fprintf(fp, " */\n"); } } static void ColorNameToXPmStr(color_name, s) char *color_name, *s; { if (*color_name == '#') { strcpy(s, color_name); } else { XColor exact_def; if (TgifParseColor(color_name, &exact_def)) { unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; dr = ((double)exact_def.red) / ((double)maxRGB) * ((double)255); dg = ((double)exact_def.green) / ((double)maxRGB) * ((double)255); db = ((double)exact_def.blue) / ((double)maxRGB) * ((double)255); r = (unsigned int)round(dr); g = (unsigned int)round(dg); b = (unsigned int)round(db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; sprintf(s, "#%02x%02x%02x", r, g, b); } else { strcpy(s, color_name); } } } static int Xpm3ToXpm1(gif_fname) char *gif_fname; { int i=0, j=0, rc=0, ncolors=0, chars_per_pixel=0, line_len=0; int first_pixel_is_bg=FALSE, image_w=0, image_h=0, w=0, h=0; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL, *xpm_data_ptr=NULL; char *psz=NULL, name[MAXPATHLENGTH], s[MAXSTRING]; int watch_cursor=watchCursorOnMainWindow, saved_color_display=colorDisplay; FILE *fp=NULL; psz = UtilStrRChr(gif_fname, DIR_SEP); if (psz == NULL) { UtilStrCpyN(name, sizeof(name), gif_fname); } else { UtilStrCpyN(name, sizeof(name), &psz[1]); } psz = UtilStrRChr(name, '.'); if (psz != NULL) { *psz = '\0'; } UtilTrimBlanks(name); if (*name == '\0') { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "Unexpected empty string in Xpm3ToXpm1().\n"); #endif /* _TGIF_DBG */ return FALSE; } if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } colorDisplay = FALSE; rc = MyReadPixmapFile(gif_fname, &image_w, &image_h, &w, &h, NULL, NULL, NULL, NULL, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, NULL, &xpm_data); colorDisplay = saved_color_display; if (rc != BitmapSuccess) { if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), gif_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if ((fp=fopen(gif_fname, "w")) == NULL) { if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), gif_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } writeFileFailed = FALSE; /* DumpXpmHeader(fp, w, h, name, 0, 0, 0, 0); */ DumpCommentInBitmapExport(fp); /* do not translate -- program constants */ fprintf(fp, "#define %s_format 1\n", name); fprintf(fp, "#define %s_width %1d\n", name, image_w); fprintf(fp, "#define %s_height %1d\n", name, image_h); fprintf(fp, "#define %s_ncolors %1d\n", name, ncolors); fprintf(fp, "#define %s_chars_per_pixel %1d\n", name, chars_per_pixel); if (xpmInXGrabSCFormat) { fprintf(fp, "static char * %s_colors[] = {\n", name); } else { fprintf(fp, "static char *%s_colors[] = {\n", name); } /* DumpXPmColors(fp); */ if (xpmInXGrabSCFormat) { for (i=0; i < ncolors-1; i++) { if (fprintf(fp, "\"") == EOF) writeFileFailed = TRUE; for (j = 0; j < chars_per_pixel; j++) { if (fprintf(fp, "%c", color_char[i*chars_per_pixel+j]) == EOF) { writeFileFailed = TRUE; } } ColorNameToXPmStr(color_str[i], s); if (fprintf(fp, "\", \"%s\"\n", s) == EOF) writeFileFailed = TRUE; } if (fprintf(fp, "\"") == EOF) writeFileFailed = TRUE; for (j = 0; j < chars_per_pixel; j++) { if (fprintf(fp, "%c", color_char[i*chars_per_pixel+j]) == EOF) { writeFileFailed = TRUE; } } ColorNameToXPmStr(color_str[i], s); if (fprintf(fp, "\", \"%s\"\n} ;\n", s) == EOF) { writeFileFailed = TRUE; } } else { for (i=0; i < ncolors-1; i++) { if (fprintf(fp, " \"") == EOF) writeFileFailed = TRUE; for (j = 0; j < chars_per_pixel; j++) { if (fprintf(fp, "%c", color_char[i*chars_per_pixel+j]) == EOF) { writeFileFailed = TRUE; } } if (fprintf(fp, "\", \"%s\",\n", color_str[i]) == EOF) { writeFileFailed = TRUE; } } if (fprintf(fp, " \"") == EOF) writeFileFailed = TRUE; for (j = 0; j < chars_per_pixel; j++) { if (fprintf(fp, "%c", color_char[i*chars_per_pixel+j]) == EOF) { writeFileFailed = TRUE; } } if (fprintf(fp, "\", \"%s\"\n};\n", color_str[i]) == EOF) { writeFileFailed = TRUE; } } if (xpmInXGrabSCFormat) { fprintf(fp, "static char * %s_pixels[] = {\n", name); } else { fprintf(fp, "static char *%s_pixels[] = {\n", name); } line_len = chars_per_pixel * image_w; xpm_data_ptr = xpm_data; for (i=0; i < image_h; i++) { char saved_ch=xpm_data_ptr[line_len]; xpm_data_ptr[line_len] = '\0'; fprintf(fp, "\"%s\"", xpm_data_ptr); xpm_data_ptr[line_len] = saved_ch; xpm_data_ptr += line_len; if (i == image_h-1) { if (xpmInXGrabSCFormat) { if (fprintf(fp, ",\n} ;\n") == EOF) writeFileFailed = TRUE; } else { if (fprintf(fp, "\n};\n") == EOF) writeFileFailed = TRUE; } } else if (fprintf(fp, ",\n") == EOF) { writeFileFailed = TRUE; } } fclose(fp); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } return TRUE; } static int ConvertXpmToGif(xpm_fname, gif_fname, src_is_ppm, where_to_print) char *xpm_fname, *gif_fname; int src_is_ppm, where_to_print; { char cmd[MAXSTRING<<1], netpbm_msg[MAXSTRING<<1], buf[1024]; FILE *gif_fp=fopen(gif_fname,"w"), *pfp=NULL; int bytes_read=0, watch_cursor=watchCursorOnMainWindow; if (gif_fp == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), gif_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } switch (where_to_print) { case GIF_FILE: case HTML_FILE: *netpbm_msg = '\0'; if (src_is_ppm) { sprintf(cmd, ppmToGifCmd, xpm_fname); if (strncmp(cmd, "ppm", 3) == 0) { sprintf(netpbm_msg, TgLoadString(STID_NETPBM_PROGS_VISIT_HOME_PAGE), TOOL_NAME, homePageURL); } } else { sprintf(cmd, xpmToGifCmd, xpm_fname); if (strncmp(cmd, "xpmtop", 6) == 0) { sprintf(netpbm_msg, TgLoadString(STID_NETPBM_PROGS_VISIT_HOME_PAGE), TOOL_NAME, homePageURL); } } if (!FindProgramInPath(cmd, netpbm_msg, FALSE)) { fclose(gif_fp); unlink(gif_fname); return FALSE; } break; case PNG_FILE: *netpbm_msg = '\0'; if (src_is_ppm) { if (pngExportHasTransparentColor) { sprintf(cmd, ppmToPngWithTransCmd, pngExportTransparentColor, xpm_fname); if (strncmp(cmd, "pnmtop", 6) == 0) { sprintf(netpbm_msg, TgLoadString(STID_NETPBM_PNMTOPNG_VST_HOME_PAGE), TOOL_NAME, homePageURL); } } else { sprintf(cmd, ppmToPngCmd, xpm_fname); if (strncmp(cmd, "pnmtop", 6) == 0) { sprintf(netpbm_msg, TgLoadString(STID_NETPBM_PNMTOPNG_VST_HOME_PAGE), TOOL_NAME, homePageURL); } } } else { sprintf(cmd, xpmToPngCmd, xpm_fname); if (strncmp(cmd, "xpmtop", 6) == 0) { sprintf(netpbm_msg, TgLoadString(STID_NETPBM_PNMTOPNG_VST_HOME_PAGE), TOOL_NAME, homePageURL); } } if (!FindProgramInPath(cmd, netpbm_msg, FALSE)) { fclose(gif_fp); unlink(gif_fname); return FALSE; } break; case JPEG_FILE: *netpbm_msg = '\0'; if (src_is_ppm) { sprintf(cmd, ppmToJpegCmd, xpm_fname); if (strncmp(cmd, "cjpeg", 5) == 0) { sprintf(netpbm_msg, TgLoadString(STID_NETPBM_JPEG_VST_HOME_PAGE), TOOL_NAME, homePageURL); } } else { sprintf(cmd, xpmToJpegCmd, xpm_fname); if (strncmp(cmd, "xpmtop", 6) == 0) { sprintf(netpbm_msg, TgLoadString(STID_NETPBM_JPEG_VST_HOME_PAGE), TOOL_NAME, homePageURL); } } if (!FindProgramInPath(cmd, netpbm_msg, FALSE)) { fclose(gif_fp); unlink(gif_fname); return FALSE; } break; case XBM_FILE: sprintf(cmd, ppm6ToXpm3Cmd, xpm_fname); *netpbm_msg = '\0'; if (strncmp(cmd, "ppmtox", 6) == 0) { sprintf(netpbm_msg, TgLoadString(STID_NETPBM_JPEG_VST_HOME_PAGE), TOOL_NAME, homePageURL); } if (!FindProgramInPath(cmd, netpbm_msg, FALSE)) { fclose(gif_fp); unlink(gif_fname); return FALSE; } break; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), cmd); Msg(gszMsgBox); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pfp=(FILE*)popen(cmd, "r")) == NULL) { fclose(gif_fp); unlink(gif_fname); sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } while ((bytes_read=fread(buf, sizeof(char), sizeof(buf), pfp)) > 0) { if ((int)fwrite(buf, sizeof(char), bytes_read, gif_fp) <= 0) { writeFileFailed = TRUE; break; } } pclose(pfp); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); fclose(gif_fp); if (writeFileFailed) { return FailToWriteFileMessage(gif_fname); } if (whereToPrint == XBM_FILE && xpmOutputVersion == 1) { return Xpm3ToXpm1(gif_fname); } return TRUE; } #define TGV_FILE_NAME 0 #define TGV_CUR_NUM 1 #define TGV_FIRST_NUM 2 #define TGV_LAST_NUM 3 #define TGV_PREV_NUM 4 #define TGV_PREV_NUM_NO_WRAP 5 #define TGV_NEXT_NUM 6 #define TGV_NEXT_NUM_NO_WRAP 7 #define TGV_TITLE 8 #define TGV_MAP_WIDTH 9 #define TGV_MAP_HEIGHT 10 #define TGV_MAP_OBJS 11 struct tagTgVars { char *var_name; int var_type; } gszTgVars[] = { { "&tgvfilename", TGV_FILE_NAME }, { "&tgvcurnum", TGV_CUR_NUM }, { "&tgvfirstnum", TGV_FIRST_NUM }, { "&tgvlastnum", TGV_LAST_NUM }, { "&tgvprevnum", TGV_PREV_NUM }, { "&tgvprevnumnowrap", TGV_PREV_NUM_NO_WRAP }, { "&tgvnextnum", TGV_NEXT_NUM }, { "&tgvnextnumnowrap", TGV_NEXT_NUM_NO_WRAP }, { "&tgvtitle", TGV_TITLE }, { "&tgvmapwidth", TGV_MAP_WIDTH }, { "&tgvmapheight", TGV_MAP_HEIGHT }, { "&tgvmapobjs", TGV_MAP_OBJS }, { NULL, INVALID } }; static int FindTgVarType(buf) char *buf; { struct tagTgVars *ptv=NULL; for (ptv=gszTgVars; ptv->var_name != NULL; ptv++) { if (UtilStrICmp(buf, ptv->var_name) == 0) { return ptv->var_type; } } return INVALID; } static void GenerateTemplateHtmlVar(map_fp, var_type, gif_fname, map_fname, fname, LtX, LtY, RbX, RbY) FILE *map_fp; char *gif_fname, *map_fname, *fname; int var_type, LtX, LtY, RbX, RbY; { struct ObjRec *obj_ptr=NULL; struct AttrRec *attr_ptr=NULL; switch (var_type) { case TGV_FILE_NAME: fprintf(map_fp, "%s", fname); break; case TGV_CUR_NUM: fprintf(map_fp, "%1d", curPageNum); break; case TGV_FIRST_NUM: fprintf(map_fp, "1"); break; case TGV_LAST_NUM: fprintf(map_fp, "%1d", lastPageNum); break; case TGV_PREV_NUM: if (curPageNum == 1) { fprintf(map_fp, "%1d", lastPageNum); } else { fprintf(map_fp, "%1d", curPageNum-1); } break; case TGV_PREV_NUM_NO_WRAP: if (curPageNum == 1) { fprintf(map_fp, "1"); } else { fprintf(map_fp, "%1d", curPageNum-1); } break; case TGV_NEXT_NUM: if (curPageNum == lastPageNum) { fprintf(map_fp, "1"); } else { fprintf(map_fp, "%1d", curPageNum+1); } break; case TGV_NEXT_NUM_NO_WRAP: if (curPageNum == lastPageNum) { fprintf(map_fp, "%1d", lastPageNum); } else { fprintf(map_fp, "%1d", curPageNum+1); } break; case TGV_TITLE: if (curPage->name != NULL && *curPage->name != '\0') { fprintf(map_fp, "%s", curPage->name); } else if ((attr_ptr=FindFileAttrWithName("title=")) != NULL) { fprintf(map_fp, "%s", attr_ptr->attr_value.s); } else { fprintf(map_fp, TgLoadCachedString(CSTID_PARANED_UNKNOWN)); } break; case TGV_MAP_WIDTH: fprintf(map_fp, "%1d", RbX-LtX); break; case TGV_MAP_HEIGHT: fprintf(map_fp, "%1d", RbY-LtY); break; case TGV_MAP_OBJS: for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (GenerateObjImageMap(map_fp, obj_ptr, LtX, LtY)) { } } break; } } static void GenerateTemplateHtmlFile(map_fp, tmpl_fp, gif_fname, map_fname, LtX, LtY, RbX, RbY) FILE *map_fp, *tmpl_fp; char *gif_fname, *map_fname; int LtX, LtY, RbX, RbY; { char *buf=NULL, *fname=NULL, *c_ptr=NULL; int line_num=0; if ((c_ptr=UtilStrRChr(curFileName, DIR_SEP)) == NULL) { fname = UtilStrDup(curFileName); } else { fname = UtilStrDup(++c_ptr); } if (fname == NULL) FailAllocMessage(); if ((c_ptr=strchr(fname, '#')) != NULL) *c_ptr = '\0'; GetRealBaseName(fname); if ((c_ptr=UtilStrRChr(fname, '.')) != NULL) *c_ptr = '\0'; while ((buf=UtilGetALine(tmpl_fp)) != NULL) { char *psz_start=buf, *psz=NULL, *psz1=NULL; line_num++; if (*psz_start == '\0') { fprintf(map_fp, "%s\n", psz_start); UtilFree(buf); continue; } while ((psz=strstr(psz_start,"&tgv")) != NULL && (psz1=strchr(psz,';')) != NULL) { int var_type=INVALID; *psz1 = '\0'; if ((var_type=FindTgVarType(psz)) != INVALID) { *psz = '\0'; fprintf(map_fp, "%s", psz_start); *psz = '&'; psz_start = &psz1[1]; GenerateTemplateHtmlVar(map_fp, var_type, gif_fname, map_fname, fname, LtX, LtY, RbX, RbY); } else { fprintf(map_fp, "%s", psz_start); psz_start = psz1; } *psz1 = ';'; } if (psz_start != NULL) { fprintf(map_fp, "%s\n", psz_start); } else { fprintf(map_fp, "\n"); } UtilFree(buf); } UtilFree(fname); } static void GenerateImageMap(XpmFileName, src_is_ppm, LtX, LtY, RbX, RbY, nPageNumInFileName) char *XpmFileName; int src_is_ppm, LtX, LtY, RbX, RbY, nPageNumInFileName; { char map_fname[MAXPATHLENGTH+1], gif_fname[MAXPATHLENGTH+1]; char tmpl_fname[MAXPATHLENGTH+1]; struct ObjRec *obj_ptr=NULL; FILE *map_fp=NULL, *tmpl_fp=NULL; int xpm_ext_len, len, something_generated=FALSE, short_name=FALSE; struct AttrRec *attr_ptr=NULL; char *psz=UtilStrRChr(XpmFileName,DIR_SEP), *rest=NULL; *map_fname = *gif_fname = *tmpl_fname = '\0'; len = strlen(XpmFileName); if (psz == NULL) { psz = UtilStrRChr(XpmFileName, '.'); if (psz == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FNAME_FORMAT_ERROR_IN_FUNC), "GenerateImageMap()"); FatalUnexpectedError(gszMsgBox, NULL); return; } xpm_ext_len = strlen(psz); } else { char *psz1=NULL; *psz = '\0'; psz1 = UtilStrRChr(&psz[1], '.'); if (psz1 == NULL) { *psz = DIR_SEP; sprintf(gszMsgBox, TgLoadString(STID_FNAME_FORMAT_ERROR_IN_FUNC), "GenerateImageMap()"); FatalUnexpectedError(gszMsgBox, NULL); return; } xpm_ext_len = strlen(psz1); *psz = DIR_SEP; } if (XpmFileName[len-xpm_ext_len] != '.') { sprintf(gszMsgBox, TgLoadString(STID_FNAME_FORMAT_ERROR_IN_FUNC), "GenerateImageMap()"); FatalUnexpectedError(gszMsgBox, NULL); return; } XpmFileName[len-xpm_ext_len] = '\0'; switch (whereToPrint) { case GIF_FILE: sprintf(map_fname, "%s%s%s", XpmFileName, *imageMapFileExtension == '\0' ? "" : ".", imageMapFileExtension); sprintf(gif_fname, "%s%s%s", XpmFileName, *gifFileExtension == '\0' ? "" : ".", gifFileExtension); break; case HTML_FILE: if (*gszHhtmlExportTemplate != '\0') { if (*gszHhtmlExportTemplate == DIR_SEP) { strcpy(tmpl_fname, gszHhtmlExportTemplate); } else { char *psz=UtilStrRChr(XpmFileName, DIR_SEP); if (psz == NULL) { strcpy(tmpl_fname, gszHhtmlExportTemplate); } else { *psz = '\0'; sprintf(tmpl_fname, "%s%c%s", XpmFileName, DIR_SEP, gszHhtmlExportTemplate); *psz = DIR_SEP; } } } sprintf(map_fname, "%s%s%s", XpmFileName, *htmlFileExtension == '\0' ? "" : ".", htmlFileExtension); sprintf(gif_fname, "%s%s%s", XpmFileName, *gifFileExtension == '\0' ? "" : ".", gifFileExtension); break; case PNG_FILE: *map_fname = '\0'; sprintf(gif_fname, "%s%s%s", XpmFileName, *pngFileExtension == '\0' ? "" : ".", pngFileExtension); break; case JPEG_FILE: *map_fname = '\0'; sprintf(gif_fname, "%s%s%s", XpmFileName, *jpegFileExtension == '\0' ? "" : ".", jpegFileExtension); break; case XBM_FILE: *map_fname = '\0'; sprintf(gif_fname, "%s.xpm", XpmFileName); break; } XpmFileName[len-xpm_ext_len] = '.'; if ((short_name=IsPrefix(bootDir, gif_fname, &rest))) ++rest; sprintf(gszMsgBox, TgLoadString(STID_CONVERTING_INTO_NAMED_FILE), rest); if (PRTGIF && !cmdLineStdOut) { if (!cmdLineQuiet) { fprintf(stderr, "%s\n", gszMsgBox); } } else { Msg(gszMsgBox); } if (*tmpl_fname != '\0' && whereToPrint == HTML_FILE && ((tmpl_fp=fopen(tmpl_fname,"r")) == NULL)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_HTML_TMPL_READ), tmpl_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (!ConvertXpmToGif(XpmFileName, gif_fname, src_is_ppm, whereToPrint)) { if (tmpl_fp != NULL) fclose(tmpl_fp); return; } switch (whereToPrint) { case GIF_FILE: if ((attr_ptr=FindFileAttrWithName("href=")) != NULL) { map_fp = OpenMapFile(map_fname); if (map_fp != NULL) { Msg(TgLoadCachedString(CSTID_GENERATING_IMAGEMAP_FILE_DOTS)); fprintf(map_fp, "default %s\n", attr_ptr->attr_value.s); for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (GenerateObjImageMap(map_fp, obj_ptr, LtX, LtY)) { something_generated = TRUE; } } fclose(map_fp); Msg(""); sprintf(gszMsgBox, TgLoadString(STID_NAMED_IMAGEMAP_FILE_GEN), map_fname); Msg(gszMsgBox); } } else if (generateImageMap) { if (nPageNumInFileName) { /* surpress the error message if we are print one file per page */ } else if (something_generated) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FND_FATTR_IMGMAP_NOT_GEN), "href="); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_FND_FATTR_NO_IMGMAP_GIF), "href="); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } break; case HTML_FILE: map_fp = OpenMapFile(map_fname); if (map_fp != NULL) { int saved_image_map_file_format=imageMapFileFormat; if (tmpl_fp == NULL) { Msg(TgLoadCachedString(CSTID_GENERATING_HTML_FILE_DOTS)); GenerateHtmlHeader(map_fp); GenerateUseMapHeader(map_fp, gif_fname, map_fname); imageMapFileFormat = IMF_FORMAT_SPYG; for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (GenerateObjImageMap(map_fp, obj_ptr, LtX, LtY)) { something_generated = TRUE; } } GenerateUseMapTrailer(map_fp, RbX-LtX, RbY-LtY); GenerateHtmlTrailer(map_fp); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_GEN_TEMPLATE_HTML_FILE_DOTS), tmpl_fname); Msg(gszMsgBox); imageMapFileFormat = IMF_FORMAT_SPYG; GenerateTemplateHtmlFile(map_fp, tmpl_fp, gif_fname, map_fname, LtX, LtY, RbX, RbY); fclose(tmpl_fp); } Msg(""); fclose(map_fp); imageMapFileFormat = saved_image_map_file_format; sprintf(gszMsgBox, TgLoadString(STID_NAMED_HTML_FILE_GEN), map_fname); Msg(gszMsgBox); } break; case PNG_FILE: break; case JPEG_FILE: break; case PPM_FILE: break; case XBM_FILE: break; } } #ifdef NOT_DEFINED #ifdef _TGIF_DBG /* debug, do not translate */ static void DebugXPmColors() { int i=0; fprintf(stderr, "\nnumColorsToDump = %1d\n", numColorsToDump); fprintf(stderr, "maxColors = %1d\n", maxColors); fprintf(stderr, "\nThe following indices ranges from 0 to maxColors-1:\n"); for (i=0; i < maxColors; i++) { if (mainVisual->class == TrueColor) { fprintf(stderr, "%s[%3d]=%3d, %s[%3d]=0x%06lx\n", "colorIndexToDumpIndex", i, colorIndexToDumpIndex[i], "colorPixels", i, (long)colorPixels[i]); } else { fprintf(stderr, "%s[%3d]=%3d, %s[%3d]=%3d\n", "colorIndexToDumpIndex", i, colorIndexToDumpIndex[i], "colorPixels", i, colorPixels[i]); } } fprintf(stderr, "\n%s 0 to numColorsToDump-1:\n", "The following indices ranges from"); for (i=0; i < numColorsToDump; i++) { int j=0; if (mainVisual->class == TrueColor) { fprintf(stderr, "%s[%3d]=0x%06lx, %s[%3d]=", "pixelValue", i, (long)pixelValue[i], "colorChar", i); } else { fprintf(stderr, "%s[%3d]=%3d, %s[%3d]=", "pixelValue", i, pixelValue[i], "colorChar", i); } for (j = 0; j < charsPerPixel; j++) { fprintf(stderr, "%c", colorChar[i*charsPerPixel+j]); } fprintf(stderr, ", %s[%3d]=%s\n", "colorStr", i, colorStr[i]); } } #endif /* _TGIF_DBG */ #ifdef _TGIF_DBG /* debug, do not translate */ static void DebugXPmColorsAndExportImage(image, w, h, left, top, right, bottom) XImage *image; int w, h, left, top, right, bottom; { int i=0; DebugXPmColors(); fprintf(stderr, "\nHere is the image:\n"); fprintf(stderr, " (%s\n %s\n %s)\n", "recall that if colorIndexToDumpIndex[color_index] = index", "then pixelValue[index] == pixel, where pixel is a value seen below", "and color_index indexes colorPixels and colorMenuItems"); for (i=top; i < h-bottom; i++) { int j=0; for (j=left; j < w-right; j++) { int data=XGetPixel(image,j-left,i-top); if (j+1 == w-right) { if (mainVisual->class == TrueColor) { fprintf(stderr, "%06lx\n", (long)data); } else { fprintf(stderr, "%3d\n", data); } } else { if (mainVisual->class == TrueColor) { fprintf(stderr, "%06lx ", (long)data); } else { fprintf(stderr, "%3d ", data); } } } } } #endif /* _TGIF_DBG */ #endif /* NOT_DEFINED */ static void AdjustForRealBaseName(fname, gzipped, no_name) char *fname; int gzipped, no_name; { char *psz=NULL, *psz1=NULL; if (no_name) return; if ((psz1=UtilStrRChr(fname, '.')) == NULL) return; *psz1 = '\0'; if (!gzipped) return; if ((psz=UtilStrRChr(fname, '.')) == NULL) { *psz1 = '.'; return; } *psz = '\0'; } void GetRealBaseName(fname) char *fname; { int gzipped=FALSE, no_name=FALSE; if (FileNameHasExtension(fname, OBJ_FILE_TYPE, &gzipped, &no_name)) { AdjustForRealBaseName(fname, gzipped, no_name); return; } gzipped = no_name = FALSE; if (FileNameHasExtension(fname, SYM_FILE_TYPE, &gzipped, &no_name)) { AdjustForRealBaseName(fname, gzipped, no_name); return; } gzipped = no_name = FALSE; if (FileNameHasExtension(fname, PIN_FILE_TYPE, &gzipped, &no_name)) { AdjustForRealBaseName(fname, gzipped, no_name); return; } } static XImage *RotateImageForLandscape(src_image, p_w, p_h, p_left, p_top, p_right, p_bottom) XImage *src_image; int *p_w, *p_h, *p_left, *p_top, *p_right, *p_bottom; { int x=0, y=0; int new_w=(*p_h), new_h=(*p_w), new_left=(*p_top), new_top=(*p_right); int new_right=(*p_bottom), new_bottom=(*p_left); Pixmap dest_pixmap=None; XImage *dest_image=NULL; dest_pixmap = XCreatePixmap(mainDisplay, mainWindow, new_w, new_h, mainDepth); dest_image = (dest_pixmap==None ? NULL : XGetImage(mainDisplay, dest_pixmap, 0, 0, new_w, new_h, AllPlanes, ZPixmap)); if (dest_pixmap == None || dest_image == NULL) { FailAllocPixmapMessage(new_w, new_h); if (dest_pixmap != None) XFreePixmap(mainDisplay, dest_pixmap); if (dest_image != NULL) XDestroyImage(dest_image); return NULL; } for (y=0; y < new_w; y++) { for (x=0; x < new_h; x++) { XPutPixel(dest_image, y, (new_h-1)-x, XGetPixel(src_image, x, y)); } } *p_w = new_w; *p_h = new_h; *p_left = new_left; *p_top = new_top; *p_right = new_right; *p_bottom = new_bottom; XFreePixmap(mainDisplay, dest_pixmap); return dest_image; } static int dumpPpmPreferred=FALSE; static void DumpXpmHeader(fp, w, h, name, left, top, right, bottom) FILE *fp; int w, h, left, top, right, bottom; char *name; { if (whereToPrint == PPM_FILE || (whereToPrint != XBM_FILE && dumpPpmPreferred)) { fprintf(fp, "P6\n%1d %1d\n255\n", w-left-right, h-top-bottom); } else if (xpmOutputVersion == 1) { DumpCommentInBitmapExport(fp); /* do not translate -- program constants */ fprintf(fp, "#define %s_format 1\n", name); fprintf(fp, "#define %s_width %1d\n", name, w-left-right); fprintf(fp, "#define %s_height %1d\n", name, h-top-bottom); fprintf(fp, "#define %s_ncolors %1d\n", name, numColorsToDump); fprintf(fp, "#define %s_chars_per_pixel %1d\n", name, charsPerPixel); if (xpmInXGrabSCFormat) { fprintf(fp, "static char * %s_colors[] = {\n", name); } else { fprintf(fp, "static char *%s_colors[] = {\n", name); } DumpXPmColors(fp); if (xpmInXGrabSCFormat) { fprintf(fp, "static char * %s_pixels[] = {\n", name); } else { fprintf(fp, "static char *%s_pixels[] = {\n", name); } } else { /* xpmOutputVersion is 3 */ fprintf(fp, "/* XPM */\n"); DumpCommentInBitmapExport(fp); fprintf(fp, "static char * %s[] = {\n", name); fprintf(fp, "\"%1d %1d %1d %1d\",\n", w-left-right, h-top-bottom, numColorsToDump, charsPerPixel); DumpXPmColors(fp); } } static void DumpXbmHeader(fp, w, h, name, left, top, right, bottom) FILE *fp; int w, h, left, top, right, bottom; char *name; { if (whereToPrint == PPM_FILE) { fprintf(fp, "P4\n%1d %1d\n", w-left-right, h-top-bottom); } else { DumpCommentInBitmapExport(fp); /* do not translate -- program constants */ fprintf(fp, "#define %s_width %1d\n", name, w-left-right); fprintf(fp, "#define %s_height %1d\n", name, h-top-bottom); fprintf(fp, "#define %s_x_hot 0\n", name); fprintf(fp, "#define %s_y_hot 0\n", name); fprintf(fp, "static %schar %s_bits[] = {\n ", (unsignedInXBmExport ? "unsigned " : ""), name); } } void SetAColorByteInfo(pcb, pXColor) ColorBytes *pcb; XColor *pXColor; { double red=0, green=0, blue=0; int r=0, g=0, b=0; red = ((double)255)*((double)(pXColor->red))/((double)maxRGB); green = ((double)255)*((double)(pXColor->green))/((double)maxRGB); blue = ((double)255)*((double)(pXColor->blue))/((double)maxRGB); r = round(red); g = round(green); b = round(blue); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; if (r < 0) r = 0; if (g < 0) g = 0; if (b < 0) b = 0; pcb->r = (unsigned char)(r & 0x0ff); pcb->g = (unsigned char)(g & 0x0ff); pcb->b = (unsigned char)(b & 0x0ff); pcb->valid = TRUE; } static void SetColorBytes(pcb, index, table_size) ColorBytes *pcb; int index, table_size; { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(index >= 0 && index < table_size, "index out of range in SetColorBytes()", NULL); #endif /* _TGIF_DBG */ if (pcb[index].valid) return; SetAColorByteInfo(&pcb[index], &tgifColors[index]); } static int DumpPpmBody(fp, image, bitmap_image, w, h, left, top, right, bottom, nInImageProc, bg_pixel) FILE *fp; XImage *image, *bitmap_image; int w, h, left, top, right, bottom, nInImageProc, bg_pixel; { XColor *saved_tgif_colors=tgifColors; ColorBytes *pcb=(ColorBytes*)malloc((maxColors+3)*sizeof(ColorBytes)); ColorBytes my_bg_cb; int i=0, target_percent=5; if (pcb == NULL) FailAllocMessage(); memset(pcb, 0, (maxColors+3)*sizeof(ColorBytes)); memset(&my_bg_cb, 0, sizeof(ColorBytes)); if (printUsingRequestedColor) tgifColors = tgifRequestedColors; SetAColorByteInfo(&my_bg_cb, &myBgColor); for (i=top; i < h-bottom; i++) { int j=0, percent=((i-top)*10000/(h-top-bottom))/100; if (percent >= target_percent) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_PROGRESS_PERCENT), percent); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); while (target_percent <= percent) target_percent += 5; } for (j=left; j < w-right; j++) { int transparent=FALSE, data=0; if (nInImageProc && bitmap_image != NULL) { if (XGetPixel(bitmap_image,j-left,i-top) != 0) { data = XGetPixel(image,j-left,i-top); } else { transparent = TRUE; } } else { data = XGetPixel(image,j-left,i-top); } if (!nInImageProc && data == bg_pixel) { if (fprintf(fp, "%c%c%c", my_bg_cb.r, my_bg_cb.g, my_bg_cb.b) == EOF) { writeFileFailed = TRUE; } } else { int index=INVALID, color_index=BAD; if (transparent) { index = transparentIndex; } else { index = XPmLookUp(data, INVALID, NULL, &color_index); } if (index == INVALID || color_index == BAD || color_index == INVALID) { sprintf(gszMsgBox, TgLoadString(transparent ? STID_UNRECOG_GIVEN_TRPIX_VAL_PRINT : STID_UNRECOG_GIVEN_PIXEL_VAL_PRINT), j-left, i-top, data, (long)data); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; free(pcb); return FALSE; } SetColorBytes(pcb, color_index, (maxColors+3)); if (fprintf(fp, "%c%c%c", pcb[color_index].r, pcb[color_index].g, pcb[color_index].b) == EOF) { writeFileFailed = TRUE; } } } } if (printUsingRequestedColor) tgifColors = saved_tgif_colors; free(pcb); return TRUE; } static int DumpXpmBody(fp, image, bitmap_image, w, h, left, top, right, bottom, nInImageProc, bg_pixel) FILE *fp; XImage *image, *bitmap_image; int w, h, left, top, right, bottom, nInImageProc, bg_pixel; { int i=0, target_percent=5; if (whereToPrint == PPM_FILE || (whereToPrint != XBM_FILE && dumpPpmPreferred)) { return DumpPpmBody(fp, image, bitmap_image, w, h, left, top, right, bottom, nInImageProc, bg_pixel); } for (i=top; i < h-bottom; i++) { int j=0, percent=((i-top)*10000/(h-top-bottom))/100; if (percent >= target_percent) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_PROGRESS_PERCENT), percent); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); while (target_percent <= percent) target_percent += 5; } if (fprintf(fp, "\"") == EOF) writeFileFailed = TRUE; for (j=left; j < w-right; j++) { int transparent=FALSE, data=0; if (nInImageProc && bitmap_image != NULL) { if (XGetPixel(bitmap_image,j-left,i-top) != 0) { data = XGetPixel(image,j-left,i-top); } else { transparent = TRUE; } } else { data = XGetPixel(image,j-left,i-top); } if (!nInImageProc && data == bg_pixel) { switch (charsPerPixel) { case 1: if (fprintf(fp, "`") == EOF) writeFileFailed = TRUE; break; case 2: if (fprintf(fp, "``") == EOF) writeFileFailed = TRUE; break; } } else { int k=0, index=0; if (transparent) { index = transparentIndex; } else { index = XPmLookUp(data, INVALID, NULL, NULL); } if (index == INVALID) { sprintf(gszMsgBox, TgLoadString(transparent ? STID_UNRECOG_GIVEN_TRPIX_VAL_PRINT : STID_UNRECOG_GIVEN_PIXEL_VAL_PRINT), j-left, i-top, data, (long)data); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } for (k=0; k < charsPerPixel; k++) { if (fprintf(fp, "%c", colorChar[index*charsPerPixel+k]) == EOF) { writeFileFailed = TRUE; } } } } if (i == h-bottom-1) { if (xpmInXGrabSCFormat) { if (fprintf(fp, "\",\n} ;\n") == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(fp, "\"\n};\n") == EOF) { writeFileFailed = TRUE; } } } else if (fprintf(fp, "\",\n") == EOF) { writeFileFailed = TRUE; } } return TRUE; } #define FS_SCALE 0x400 #define HALF_FS_SCALE 0x200 static void DumpXbmHalfToneBody(fp, image, w, h, left, top, right, bottom, bg_pixel) FILE *fp; XImage *image; int w, h, left, top, right, bottom, bg_pixel; { int i=0, j=0, k=0, bit_count=0, data=0, pixel=0, byte_count=0; TrueColorInfo tci; ProgressInfo pi; /*--------------------------------------------------*/ /* the halftoning code is adapted from 'pgmopbm.c', */ /* which is part of the pbmplus package. */ /* */ /* Copyright (C) 1989 by Jef Poskanzer */ /*--------------------------------------------------*/ long *thiserr, *nexterr, *tmperr, threshval, sum; int fs_forward=TRUE, col, limitcol, found_index, *bits; float gray; sprintf(gszMsgBox, TgLoadCachedString(CSTID_FS_HALFTONE_BMP_THRESH_DOTS), bitmapThresholdStr); Msg(gszMsgBox); srand(0); thiserr = (long*)malloc((w-left-right+2)*sizeof(long)); nexterr = (long*)malloc((w-left-right+2)*sizeof(long)); bits = (int*)malloc((w-left-right+2)*sizeof(int)); if (thiserr==NULL || nexterr==NULL || bits==NULL) FailAllocMessage(); for (j = 0; j < w-left-right+2; j++) { thiserr[j] = (rand() % FS_SCALE - HALF_FS_SCALE) >> 2; } threshval = (long)(bitmapThreshold * (float)FS_SCALE); if (fullTrueColorMode) { if (!InitTrueColorInfo(image, &tci, w)) { return; } } byte_count = 0; BeginProgress(&pi, h-top-bottom); for (i=top; i < h-bottom; i++) { UpdateProgress(&pi, i-top); for (col = 0; col < w-left-right+2; col++) { nexterr[col] = bits[col] = 0; } bit_count = 0; col = (fs_forward) ? 0 : w-left-right-1; limitcol = (fs_forward) ? w-left-right : -1; do { found_index = INVALID; pixel = XGetPixel(image, col, i); if (fullTrueColorMode) { uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; r = (pix & tci.r_mask) >> tci.r_shift; g = (pix & tci.g_mask) >> tci.g_shift; b = (pix & tci.b_mask) >> tci.b_shift; dr = ((double)r) / tci.dr_maxval; dg = ((double)g) / tci.dg_maxval; db = ((double)b) / tci.db_maxval; gray = (float)(0.299*dr + 0.587*dg + 0.114*db); } else { for (k = 0; k < maxColors; k++) { if (colorPixels[k] == pixel) { found_index = k; break; } } if (found_index == INVALID) { if (pixel == bg_pixel) { gray = (float)1.0; } else { sprintf(gszMsgBox, TgLoadString(STID_UNRECOG_GIVEN_PIXEL_VAL_1_USE), pixel, (long)pixel); Msg(gszMsgBox); gray = (float)0.0; } } else { gray = 0.299*((float)tgifColors[found_index].red/maxRGB) + 0.587*((float)tgifColors[found_index].green/maxRGB) + 0.114*((float)tgifColors[found_index].blue/maxRGB); } } sum = ((long)(gray * FS_SCALE)) + thiserr[col+1]; if (sum >= threshval) { sum = sum-threshval-HALF_FS_SCALE; } else { bits[col] = 1; /* black bit */ } if (fs_forward) { thiserr[col+2] += (sum*7)>>4; nexterr[col ] += (sum*3)>>4; nexterr[col+1] += (sum*5)>>4; nexterr[col+2] += (sum )>>4; col++; } else { thiserr[col ] += (sum*7)>>4; nexterr[col+2] += (sum*3)>>4; nexterr[col+1] += (sum*5)>>4; nexterr[col ] += (sum )>>4; col--; } } while (col != limitcol); tmperr = thiserr; thiserr = nexterr; nexterr = tmperr; fs_forward = !fs_forward; bit_count = 0; data = 0; for (j = left; j < w-right; j++) { if (bits[j]) { if (whereToPrint == XBM_FILE || (whereToPrint == EPSI_FILE && generateTiffEPSI)) { data |= (1<>4) & 0xf]) == EOF) { writeFileFailed = TRUE; } if (i == h-bottom-1 && j == w-right-1) { if (fprintf(fp, "%c};\n", hexValue[data & 0xf]) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(fp, "%c, ", hexValue[data & 0xf]) == EOF) { writeFileFailed = TRUE; } } } else { if (fprintf(fp, "%c", (unsigned char)(data & 0x0ff)) == EOF) { writeFileFailed = TRUE; } } bit_count = 0; data = 0; } } if (((w-left-right) % 8) != 0) { if (byte_count++ == 12) { byte_count = 1; if (whereToPrint == XBM_FILE || (whereToPrint == EPSI_FILE && generateTiffEPSI)) { if (fprintf(fp, "\n ") == EOF) writeFileFailed = TRUE; } } if (whereToPrint == XBM_FILE || (whereToPrint == EPSI_FILE && generateTiffEPSI)) { for (j=((w-left-right)%8); j < 8; j++) data |= (1<>4) & 0xf]) == EOF) { writeFileFailed = TRUE; } if (i == h-bottom-1) { if (fprintf(fp, "%c};\n", hexValue[data & 0xf]) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(fp, "%c, ", hexValue[data & 0xf]) == EOF) { writeFileFailed = TRUE; } } } else { if (fprintf(fp, "%c", (unsigned char)(data & 0x0ff)) == EOF) { writeFileFailed = TRUE; } } } } } static void DumpXbmNoneHalfToneBody(fp, image, w, h, left, top, right, bottom, bg_pixel) FILE *fp; XImage *image; int w, h, left, top, right, bottom, bg_pixel; { int i=0, j=0, k=0, bit_count=0, data=0, pixel=0, byte_count=0; TrueColorInfo tci; ProgressInfo pi; if (thresholdBitmap) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_THRESHOLD_BMP_THRESH_DOTS), bitmapThresholdStr); Msg(gszMsgBox); } if (fullTrueColorMode) { if (!InitTrueColorInfo(image, &tci, w)) { return; } } byte_count = 0; BeginProgress(&pi, h-top-bottom); for (i=top; i < h-bottom; i++) { UpdateProgress(&pi, i-top); bit_count = 0; data = 0; for (j = left; j < w-right; j++) { if (thresholdBitmap) { pixel = XGetPixel(image, j, i); if (fullTrueColorMode) { uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; double dgray=(double)0; r = (pix & tci.r_mask) >> tci.r_shift; g = (pix & tci.g_mask) >> tci.g_shift; b = (pix & tci.b_mask) >> tci.b_shift; dr = ((double)r) / tci.dr_maxval; dg = ((double)g) / tci.dg_maxval; db = ((double)b) / tci.db_maxval; dgray = 0.299*dr + 0.587*dg + 0.114*db; if (dgray < (double)bitmapThreshold) { if (whereToPrint == XBM_FILE || (whereToPrint == EPSI_FILE && generateTiffEPSI)) { data |= (1<>4) & 0xf]) == EOF) { writeFileFailed = TRUE; } if (i == h-bottom-1 && j == w-right-1) { if (fprintf(fp, "%c};\n", hexValue[data & 0xf]) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(fp, "%c, ", hexValue[data & 0xf]) == EOF) { writeFileFailed = TRUE; } } } else { if (fprintf(fp, "%c", (unsigned char)(data & 0x0ff)) == EOF) { writeFileFailed = TRUE; } } bit_count = 0; data = 0; } } if (((w-left-right) % 8) != 0) { if (byte_count++ == 12) { byte_count = 1; if (whereToPrint == XBM_FILE || (whereToPrint == EPSI_FILE && generateTiffEPSI)) { if (fprintf(fp, "\n ") == EOF) writeFileFailed = TRUE; } } if (whereToPrint == XBM_FILE || (whereToPrint == EPSI_FILE && generateTiffEPSI)) { for (j=((w-left-right)%8); j < 8; j++) data |= (1<>4) & 0xf]) == EOF) { writeFileFailed = TRUE; } if (i == h-bottom-1) { if (fprintf(fp, "%c};\n", hexValue[data & 0xf]) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(fp, "%c, ", hexValue[data & 0xf]) == EOF) { writeFileFailed = TRUE; } } } else { if (fprintf(fp, "%c", (unsigned char)(data & 0x0ff)) == EOF) { writeFileFailed = TRUE; } } } } } static void DumpXbmBody(fp, image, w, h, left, top, right, bottom, bg_pixel) FILE *fp; XImage *image; int w, h, left, top, right, bottom, bg_pixel; { if (halfToneBitmap) { DumpXbmHalfToneBody(fp, image, w, h, left, top, right, bottom, bg_pixel); } else { DumpXbmNoneHalfToneBody(fp, image, w, h, left, top, right, bottom, bg_pixel); } } static void GetPixelTrims(w, h, pnLeft, pnTop, pnRight, pnBottom) int w, h, *pnLeft, *pnTop, *pnRight, *pnBottom; { *pnLeft = leftExportPixelTrim; *pnTop = topExportPixelTrim; *pnRight = rightExportPixelTrim; *pnBottom = bottomExportPixelTrim; if (leftExportPixelTrim+rightExportPixelTrim >= w || topExportPixelTrim+bottomExportPixelTrim >= h) { SetExportPixelTrim(TRUE); if (leftExportPixelTrim+rightExportPixelTrim >= w || topExportPixelTrim+bottomExportPixelTrim >= h) { sprintf(gszMsgBox, TgLoadString(STID_LARGE_EXP_PXL_TRM_WH_0_USED), leftExportPixelTrim, topExportPixelTrim, rightExportPixelTrim, bottomExportPixelTrim, w, h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *pnLeft = *pnTop = *pnRight = *pnBottom = 0; } else { *pnLeft = leftExportPixelTrim; *pnTop = topExportPixelTrim; *pnRight = rightExportPixelTrim; *pnBottom = bottomExportPixelTrim; } } } static void BuildXPmColorsFromImage(image, w, h) XImage *image; int w, h; { int i=0, saved_max_colors=maxColors; FreeCachedStrings(); maxColors = MAXXPMEXPORTCOLORS; pixelValue = (int*)malloc((maxColors+3)*sizeof(int)); if (pixelValue == NULL) FailAllocMessage(); colorIndexToDumpIndex = (int*)malloc((maxColors+3)*sizeof(int)); dumpIndexToColorIndex = (int*)malloc((maxColors+3)*sizeof(int)); if (colorIndexToDumpIndex == NULL || dumpIndexToColorIndex == NULL) { FailAllocMessage(); } if (maxColors > 20) { charsPerPixel = 2; colorChar = (char*)malloc(((maxColors<<1)+6)*sizeof(char)); } else { charsPerPixel = 1; colorChar = (char*)malloc((maxColors+3)*sizeof(char)); } if (colorChar == NULL) FailAllocMessage(); colorStr = (char**)malloc((maxColors+3)*sizeof(char*)); if (colorStr == NULL) FailAllocMessage(); memset(colorStr, 0, (maxColors+3)*sizeof(char*)); for (i = 0; i < maxColors+3; i++) { colorIndexToDumpIndex[i] = dumpIndexToColorIndex[i] = INVALID; } pixelValue[0] = GetDrawingBgPixel(INVALID, INVALID); if (myFileBgColorStr == NULL) { colorStr[0] = (char*)malloc((strlen(myBgColorStr)+1)*sizeof(char)); if (colorStr[0] == NULL) FailAllocMessage(); strcpy(colorStr[0], myBgColorStr); } else { colorStr[0] = (char*)malloc((strlen(myFileBgColorStr)+1)*sizeof(char)); if (colorStr[0] == NULL) FailAllocMessage(); strcpy(colorStr[0], myFileBgColorStr); } numColorsToDump = 1; if (InitTmpBuckets()) { SetStringStatus(TgLoadCachedString(CSTID_BLD_COLOR_TBL_FROM_PIXEL_DOTS)); for (i=0; i < h; i++) { int j=0; for (j=0; j < w; j++) { int pixel=XGetPixel(image,j,i); UpdateColorsLookupTableForPixel(pixel, TRUE); } } CleanUpTmpBuckets(); } colorChar[0] = '`'; if (charsPerPixel > 1) colorChar[1] = '`'; if (numColorsToDump >= 256) { for (i=1; i < numColorsToDump; i++) { if (charsPerPixel == 1) { colorChar[i] = (char)(((int)('a'))+i-1); } else { int left=(int)(i/80), right=(i%80); if (left >= 31) { colorChar[i*2] = (char)(((int)('/'))+left-31); } else { colorChar[i*2] = (char)(((int)('`'))+left); } if (right >= 31) { colorChar[i*2+1] = (char)(((int)('/'))+right-31); } else { colorChar[i*2+1] = (char)(((int)('`'))+right); } } } } else { for (i=1; i < numColorsToDump; i++) { if (charsPerPixel == 1) { colorChar[i] = (char)(((int)('a'))+i-1); } else { colorChar[i*2] = (char)(((int)('a'))+(int)(i/10)); colorChar[i*2+1] = (char)(((int)('0'))+(i%10)); } } } maxColors = saved_max_colors; } static int DumpXImageToXpmFile(image, w, h, fname) XImage *image; int w, h; char *fname; { FILE *fp=fopen(fname, "w"); int bg_pixel=GetDrawingBgPixel(INVALID, INVALID); int saved_xpm_output_version=xpmOutputVersion; BuildXPmColorsFromImage(image, w, h); if (numColorsToDump >= MAXXPMEXPORTCOLORS) { sprintf(gszMsgBox, TgLoadString(STID_TOO_MANY_COLORS_LIMIT_IS), numColorsToDump, MAXXPMEXPORTCOLORS); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (fp == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (useXPmVersion1ForImageMap) { xpmOutputVersion = 1; } writeFileFailed = FALSE; DumpXpmHeader(fp, w, h, TOOL_NAME, 0, 0, 0, 0); #ifdef NOT_DEFINED #ifdef _TGIF_DBG DebugXPmColorsAndExportImage(image, w, h, 0, 0, 0, 0); #endif /* _TGIF_DBG */ #endif /* NOT_DEFINED */ if (!BuildXPmBuckets(numColorsToDump, pixelValue, dumpIndexToColorIndex, INVALID, NULL, NULL)) { fclose(fp); xpmOutputVersion = saved_xpm_output_version; return FALSE; } if (!DumpXpmBody(fp, image, NULL, w, h, 0, 0, 0, 0, FALSE, bg_pixel)) { if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { fclose(fp); } xpmOutputVersion = saved_xpm_output_version; return FALSE; } fclose(fp); xpmOutputVersion = saved_xpm_output_version; if (writeFileFailed) { return FailAllocPixmapMessage(w, h); } return TRUE; } int DumpXImageToPpmFile(image, w, h, fname, deflate) XImage *image; int w, h, deflate; char *fname; { int row=0, col=0; TrueColorInfo tci; double dmaxval=(double)255; unsigned int bytes_per_pixel=image->bits_per_pixel/8; unsigned char *image_ptr=(unsigned char *)(image->data); char deflated_fname[MAXPATHLENGTH]; FILE *fp=NULL; ProgressInfo pi; *deflated_fname = '\0'; if (!InitTrueColorInfo(image, &tci, w)) { return FALSE; } fp = fopen(fname, "w"); if (fp == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } writeFileFailed = FALSE; if (fprintf(fp, "P6\n%1d %1d\n255\n", w, h) == EOF) writeFileFailed = TRUE; BeginProgress(&pi, h); for (row=0; row < h; row++) { UpdateProgress(&pi, row); for (col=0; col < w; col++, image_ptr+=bytes_per_pixel) { uint32_t pixel=0; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; memcpy(&pixel, image_ptr, bytes_per_pixel); r = (pixel & tci.r_mask) >> tci.r_shift; g = (pixel & tci.g_mask) >> tci.g_shift; b = (pixel & tci.b_mask) >> tci.b_shift; dr = ((double)r) * dmaxval / tci.dr_maxval; dg = ((double)g) * dmaxval / tci.dg_maxval; db = ((double)b) * dmaxval / tci.db_maxval; r = round(dr); g = round(dg); b = round(db); buf[0] = (unsigned char)(r&0xff); buf[1] = (unsigned char)(g&0xff); buf[2] = (unsigned char)(b&0xff); if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; } } EndProgress(&pi); fclose(fp); if (writeFileFailed) { return FailToWriteFileMessage(fname); } if (deflate) { snprintf(deflated_fname, sizeof(deflated_fname), "%s.ppm.z", fname); if (!DeflateFile(fname, deflated_fname)) { unlink(fname); return FALSE; } unlink(fname); } return TRUE; } static int DumpXImageToPpm6(fp, image, bitmap_image, w, h, left, top, right, bottom) FILE *fp; XImage *image, *bitmap_image; int w, h, left, top, right, bottom; { int i=0; TrueColorInfo tci; double dmaxval=(double)255; unsigned int bytes_per_pixel=image->bits_per_pixel/8; unsigned char *image_ptr=(unsigned char *)(image->data); ProgressInfo pi; if (!InitTrueColorInfo(image, &tci, w)) { return FALSE; } if (fprintf(fp, "P6\n%1d %1d\n255\n", w, h) == EOF) writeFileFailed = TRUE; image_ptr += (bytes_per_pixel*top*w); BeginProgress(&pi, h-top-bottom); for (i=top; i < h-bottom; i++, image_ptr+=bytes_per_pixel*right) { int j=0; UpdateProgress(&pi, i-top); for (j=left, image_ptr+=(bytes_per_pixel*left); j < w-right; j++, image_ptr+=bytes_per_pixel) { uint32_t pixel=0; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; memcpy(&pixel, image_ptr, bytes_per_pixel); r = (pixel & tci.r_mask) >> tci.r_shift; g = (pixel & tci.g_mask) >> tci.g_shift; b = (pixel & tci.b_mask) >> tci.b_shift; dr = ((double)r) * dmaxval / tci.dr_maxval; dg = ((double)g) * dmaxval / tci.dg_maxval; db = ((double)b) * dmaxval / tci.db_maxval; r = round(dr); g = round(dg); b = round(db); buf[0] = (unsigned char)(r&0xff); buf[1] = (unsigned char)(g&0xff); buf[2] = (unsigned char)(b&0xff); if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; } } EndProgress(&pi); return TRUE; } void DumpXBitmapFile(nInImageProc, nDumpPpmPreferred, nPageNumInFileName) int nInImageProc, nDumpPpmPreferred, nPageNumInFileName; { /* called when printing in the xbm or xpm format */ int ltx=0, lty=0, w=0, h=0, short_name=FALSE; int left=0, top=0, right=0, bottom=0; int bg_pixel=GetDrawingBgPixel(INVALID, INVALID); char xbm_file_name[MAXPATHLENGTH<<1], *rest=NULL, name[MAXPATHLENGTH+1]; FILE *fp=NULL; Pixmap pixmap=None; XImage *image=NULL, *bitmap_image=NULL; dumpPpmPreferred = nDumpPpmPreferred; if (nInImageProc) { *gszImageProcXPmFile = '\0'; if (MkTempFile(xbm_file_name, sizeof(xbm_file_name), tmpDir, TOOL_NAME) == NULL) { return; } strcpy(name, "unnamed"); if ((short_name=IsPrefix(bootDir, xbm_file_name, &rest))) ++rest; } else { strcpy(name, curFileName); GetRealBaseName(name); sprintf(xbm_file_name, "%s%c%s", curDir, DIR_SEP, name); if (PRTGIF) { char *tmp_name=(char*)name; if (whereToPrint == PPM_FILE || dumpPpmPreferred) { SetOutputFileName(xbm_file_name, colorDump?"ppm":"pbm", NULL, &tmp_name); } else { SetOutputFileName(xbm_file_name, colorDump?XPM_FILE_EXT:XBM_FILE_EXT, NULL, &tmp_name); } } else { if (whereToPrint == PPM_FILE || dumpPpmPreferred) { SetOutputFileName(xbm_file_name, colorDump?"ppm":"pbm", &short_name, &rest); } else { SetOutputFileName(xbm_file_name, colorDump?XPM_FILE_EXT:XBM_FILE_EXT, &short_name, &rest); } } } if (PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup) { fp = stdout; } else if ((fp=fopen(xbm_file_name, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FOR_WRITE_PRINT), (short_name ? rest : xbm_file_name)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (colorDump) InitImageMap(); Msg(TgLoadCachedString(CSTID_GENERATING_IMAGE)); /* if we are print one page per file, don't redraw */ if ((pixmap=DrawAllOnPixmap(<x, <y, &w, &h, !nPageNumInFileName)) == None) { if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { fclose(fp); unlink(xbm_file_name); } return; } sprintf(gszMsgBox, TgLoadString(STID_PRINTING_INTO_NAMED_FILE), (short_name ? rest : xbm_file_name)); Msg(gszMsgBox); GetPixelTrims(w, h, &left, &top, &right, &bottom); if ((image=XGetImage(mainDisplay, pixmap, left, top, w-left-right, h-top-bottom, AllPlanes, ZPixmap)) == NULL) { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { fclose(fp); unlink(xbm_file_name); } XFreePixmap(mainDisplay, pixmap); return; } if (nInImageProc && topSel != NULL && topSel == botSel && topSel->obj->type == OBJ_XPM) { /* if ((bitmap_image=XGetImage(mainDisplay, topSel->obj->detail.xpm->bitmap, left, top, w-left-right, h-top-bottom, 1, ZPixmap)) == NULL) { Msg("Cannot generate image, print aborted!"); if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { fclose(fp); unlink(xbm_file_name); } XDestroyImage(image); XFreePixmap(mainDisplay, pixmap); return; } */ } if (left != 0 || top != 0 || right != 0 || bottom != 0) { sprintf(gszMsgBox, TgLoadString(STID_APPLY_EXP_PXL_TRM_VALS), left, top, right, bottom); Msg(gszMsgBox); } if (whereToPrint == EPSI_FILE && generateTiffEPSI && pageStyle == LANDSCAPE) { /* for landscape mode TiffEPSI, we need to rotate the image */ XImage *rotated_image=RotateImageForLandscape(image, &w, &h, &left, &top, &right, &bottom); if (rotated_image == NULL) { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { fclose(fp); unlink(xbm_file_name); } if (bitmap_image != NULL) XDestroyImage(bitmap_image); XDestroyImage(image); XFreePixmap(mainDisplay, pixmap); return; } XDestroyImage(image); image = rotated_image; } writeFileFailed = FALSE; if (colorDump && nInImageProc && gnConvolving) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "Warning (unexpected): gnConvolving is TRUE in DumpXBitmapFile.\n"); #endif /* _TGIF_DBG */ if (!DoConvolution(fp, image, bitmap_image, w, h, NULL)) { if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { fclose(fp); unlink(xbm_file_name); } if (bitmap_image != NULL) XDestroyImage(bitmap_image); XDestroyImage(image); XFreePixmap(mainDisplay, pixmap); return; } } else if (colorDump) { if (dumpPpmPreferred) { /* don't do anything here, do it below */ } else { int saved_xpm_output_version=xpmOutputVersion; if (whereToPrint==GIF_FILE || whereToPrint==HTML_FILE || whereToPrint==PNG_FILE || whereToPrint==JPEG_FILE || whereToPrint==PPM_FILE) { if (useXPmVersion1ForImageMap) { xpmOutputVersion = 1; } } BuildXPmColors(image, w, h, left, top, right, bottom, FALSE); if (numColorsToDump >= MAXXPMEXPORTCOLORS) { sprintf(gszMsgBox, TgLoadString(STID_TOO_MANY_COLORS_LIMIT_IS), numColorsToDump, MAXXPMEXPORTCOLORS); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { fclose(fp); unlink(xbm_file_name); } if (bitmap_image != NULL) XDestroyImage(bitmap_image); XDestroyImage(image); XFreePixmap(mainDisplay, pixmap); return; } DumpXpmHeader(fp, w, h, name, left, top, right, bottom); xpmOutputVersion = saved_xpm_output_version; } } else { DumpXbmHeader(fp, w, h, name, left, top, right, bottom); } SaveStatusStrings(); if (colorDump && nInImageProc && gnConvolving) { } else if (colorDump) { if (dumpPpmPreferred) { if (!DumpXImageToPpm6(fp, image, bitmap_image, w, h, left, top, right, bottom)) { if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { fclose(fp); } if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { unlink(xbm_file_name); } if (bitmap_image != NULL) XDestroyImage(bitmap_image); XDestroyImage(image); XFreePixmap(mainDisplay, pixmap); return; } } else { #ifdef NOT_DEFINED #ifdef _TGIF_DBG DebugXPmColorsAndExportImage(image, w, h, left, top, right, bottom); #endif /* _TGIF_DBG */ #endif /* NOT_DEFINED */ if (!BuildXPmBuckets(numColorsToDump, pixelValue, dumpIndexToColorIndex, INVALID, NULL, NULL)) { if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { fclose(fp); unlink(xbm_file_name); } if (bitmap_image != NULL) XDestroyImage(bitmap_image); XDestroyImage(image); XFreePixmap(mainDisplay, pixmap); return; } if (!DumpXpmBody(fp, image, bitmap_image, w, h, left, top, right, bottom, nInImageProc, bg_pixel)) { if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { fclose(fp); } if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { unlink(xbm_file_name); } if (bitmap_image != NULL) XDestroyImage(bitmap_image); XDestroyImage(image); XFreePixmap(mainDisplay, pixmap); return; } } } else { DumpXbmBody(fp, image, w, h, left, top, right, bottom, bg_pixel); } RestoreStatusStrings(); if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { fclose(fp); } XDestroyImage(image); XFreePixmap(mainDisplay, pixmap); if (writeFileFailed) { writeFileFailed = FALSE; FailToWriteFileMessage(xbm_file_name); } else { if (whereToPrint == PPM_FILE || dumpPpmPreferred) { sprintf(gszMsgBox, TgLoadString(STID_FORMAT_FILE_WH_PRINTED_INTO), (colorDump ? "PPM" : "PBM"), w-left-right, h-top-bottom, (short_name ? rest : xbm_file_name)); } else { sprintf(gszMsgBox, TgLoadString(STID_FORMAT_FILE_WH_PRINTED_INTO), (colorDump ? "XPM" : "XBM"), w-left-right, h-top-bottom, (short_name ? rest : xbm_file_name)); } if (PRTGIF && !cmdLineStdOut) { if (!cmdLineQuiet) { fprintf(stderr, "%s\n", gszMsgBox); } } else { Msg(gszMsgBox); } if (colorDump && (whereToPrint==GIF_FILE || whereToPrint==HTML_FILE || whereToPrint==PNG_FILE || whereToPrint==JPEG_FILE || (dumpPpmPreferred && whereToPrint==XBM_FILE))) { int src_is_ppm=dumpPpmPreferred; SaveStatusStrings(); GenerateImageMap(xbm_file_name, src_is_ppm, ltx+left, lty+top, ltx+w-right, lty+h-bottom, nPageNumInFileName); RestoreStatusStrings(); if (!(PRTGIF && cmdLineStdOut && !(whereToPrint == EPSI_FILE && generateTiffEPSI) && !preDumpSetup)) { unlink(xbm_file_name); } } } if (nInImageProc) { strcpy(gszImageProcXPmFile, xbm_file_name); if (gnConvolving) { CleanUpConvolution(); } } if (bitmap_image != NULL) XDestroyImage(bitmap_image); } int DumpXImageToFile(image, w, h, fname, ext) XImage *image; int w, h; char *fname, *ext; { if (fullTrueColorMode && HasZlibSupport()) { if (DumpXImageToPpmFile(image, w, h, fname, TRUE)) { if (ext != NULL) strcpy(ext, ".ppm.z"); return TRUE; } } if (ext != NULL) strcpy(ext, ".xpm"); return DumpXImageToXpmFile(image, w, h, fname); } static void FailedExportXPixmapDeckToGIF(count, gif_fp, gif_fname, tmp_fnames) int count; FILE *gif_fp; char *gif_fname, *tmp_fnames; { if (gif_fp != NULL) fclose(gif_fp); if (*gif_fname != '\0') unlink(gif_fname); if (tmp_fnames != NULL) { int i=0, index=0; for (i=0, index=0; i < count; i++, index += MAXPATHLENGTH) { char *psz=NULL; if (tmp_fnames[index] == '\0') { break; } unlink(&tmp_fnames[index]); if ((psz=UtilStrRChr(&tmp_fnames[index], '.')) != NULL) { *psz = '\0'; unlink(&tmp_fnames[index]); } } free(tmp_fnames); } } void ExportXPixmapDeckToGIF() { struct ObjRec *obj_ptr=NULL, *xpm_obj=NULL; struct ObjRec *saved_top_obj=topObj, *saved_bot_obj=botObj; int i=0, first_one=TRUE, w=(-1), h=(-1), count=0, index=0, len=0, ok=TRUE; int short_name=FALSE, bytes_read=0, watch_cursor=watchCursorOnMainWindow; char *tmp_fnames=NULL, *cmd=NULL, *rest=NULL, gif_fname[MAXPATHLENGTH]; char buf[1024]; FILE *gif_fp=NULL, *pfp=NULL; if (!curDirIsLocal) { MsgBox(TgLoadString(STID_CANNOT_PRINT_REMOTE_FILE), TOOL_NAME, INFO_MB); return; } else if (!curFileDefined) { sprintf(gszMsgBox, TgLoadString(STID_NO_CUR_FILE_CANNOT_GEN_FORMAT), "GIF"), MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (topSel == NULL || topSel != botSel) { MsgBox(TgLoadString(STID_SEL_XPM_DECK_TO_EXPORT), TOOL_NAME, INFO_MB); return; } obj_ptr = topSel->obj; if (obj_ptr->type != OBJ_GROUP && obj_ptr->type != OBJ_SYM && obj_ptr->type != OBJ_ICON) { MsgBox(TgLoadString(STID_SEL_XPM_DECK_TO_EXPORT), TOOL_NAME, INFO_MB); return; } for (xpm_obj=obj_ptr->detail.r->first; xpm_obj != NULL; xpm_obj=xpm_obj->next) { if (xpm_obj->type == OBJ_XPM) { if (first_one) { w = xpm_obj->obbox.rbx-xpm_obj->obbox.ltx; h = xpm_obj->obbox.rby-xpm_obj->obbox.lty; first_one = FALSE; } else { if (w != xpm_obj->obbox.rbx-xpm_obj->obbox.ltx || h != xpm_obj->obbox.rby-xpm_obj->obbox.lty) { sprintf(gszMsgBox, TgLoadString(STID_MANY_SZ_FAIL_XPM_DESK_EXPORT), w, h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } count++; } } tmp_fnames = (char*)malloc(count*MAXPATHLENGTH*sizeof(char)); if (tmp_fnames == NULL) FailAllocMessage(); curPage->top = curPage->bot = topObj = botObj = NULL; SaveStatusStrings(); HighLightReverse(); RemoveAllSel(); PushPageInfo(); InitImageMap(); SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); len = strlen(xpmDeckToGifAnimCmd)+5; for (xpm_obj=obj_ptr->detail.r->first; xpm_obj != NULL; xpm_obj=xpm_obj->next) { if (xpm_obj->type == OBJ_XPM) { int saved_colordump=colorDump, saved_wheretoprint=whereToPrint; int saved_xpm_output_version=xpmOutputVersion; int dump_ppm_preferred=FALSE; curPage->top = curPage->bot = topObj = botObj = DupObj(xpm_obj); topSel = botSel = SelectThisObject(topObj); UpdSelBBox(); if (useXPmVersion1ForXPmDeck) { xpmOutputVersion = 1; } *gszImageProcXPmFile = '\0'; gnConvolving = FALSE; colorDump = TRUE; whereToPrint = XBM_FILE; gnInImageProc = TRUE; dump_ppm_preferred = fullTrueColorMode && (whereToPrint==XBM_FILE && xpmOutputVersion == 3); DumpXBitmapFile(gnInImageProc, dump_ppm_preferred, FALSE); RemoveAllSel(); DelAllObj(); gnInImageProc = FALSE; whereToPrint = saved_wheretoprint; colorDump = saved_colordump; xpmOutputVersion = saved_xpm_output_version; if (*gszImageProcXPmFile == '\0') { break; } sprintf(&tmp_fnames[index], "%s.gif", gszImageProcXPmFile); if (!ConvertXpmToGif(gszImageProcXPmFile, &tmp_fnames[index], FALSE, GIF_FILE)) { unlink(gszImageProcXPmFile); break; } len += strlen(&tmp_fnames[index])+1; index += MAXPATHLENGTH; } } SetDefaultCursor(mainWindow); ShowCursor(); *gif_fname = '\0'; SetOutputFileName(gif_fname, GetExportExt(GIF_FILE), &short_name, &rest); gif_fp = fopen(gif_fname,"w"); if (gif_fp == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), ((short_name && *outputDir=='\0') ? rest : gif_fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); FailedExportXPixmapDeckToGIF(count, gif_fp, gif_fname, tmp_fnames); ok = FALSE; } if (ok) { cmd = (char*)malloc(len+1); strcpy(cmd, xpmDeckToGifAnimCmd); len = strlen(cmd); for (i=0, index=0; i < count; i++, index += MAXPATHLENGTH) { if (tmp_fnames[index] == '\0') { break; } sprintf(&cmd[len], " %s", &tmp_fnames[index]); len += strlen(&cmd[len]); } if (FindProgramInPath(cmd, NULL, FALSE)) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), xpmDeckToGifAnimCmd); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pfp=(FILE*)popen(cmd, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_EXEC_FORMAT_NOT_GEN), cmd, "GIF"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); FailedExportXPixmapDeckToGIF(count, gif_fp, gif_fname, tmp_fnames); ok = FALSE; } else { if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } while ((bytes_read=fread(buf, sizeof(char), sizeof(buf), pfp)) > 0) { if ((int)fwrite(buf, sizeof(char), bytes_read, gif_fp) <= 0) { writeFileFailed = TRUE; break; } } pclose(pfp); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } fclose(gif_fp); gif_fp = NULL; if (writeFileFailed) { FailToWriteFileMessage( ((short_name && *outputDir=='\0') ? rest : gif_fname)); FailedExportXPixmapDeckToGIF(count, gif_fp, gif_fname, tmp_fnames); ok = FALSE; } } } } if (ok) { /* * GIF generated, set gif_fname to NULL so that the GIF file * doesn't get deleted FailedExportXPixmapDeckToGIF() */ *gif_fname = '\0'; FailedExportXPixmapDeckToGIF(count, gif_fp, gif_fname, tmp_fnames); } curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; PopPageInfo(); RedrawAnArea(botObj, obj_ptr->bbox.ltx-GRID_ABS_SIZE(1), obj_ptr->bbox.lty-GRID_ABS_SIZE(1), obj_ptr->bbox.rbx+GRID_ABS_SIZE(1), obj_ptr->bbox.rby+GRID_ABS_SIZE(1)); topSel = botSel = SelectThisObject(obj_ptr); UpdSelBBox(); HighLightForward(); RestoreStatusStrings(); } void DumpBitmap(FP, image, data, image_w, image_h, transformed, orig_x, orig_y, adj_x, pmtrx, indent) FILE *FP; XImage *image; char *data; int image_w, image_h, transformed, orig_x, orig_y, adj_x, indent; struct MtrxRec *pmtrx; { register int m; int row, h_blocks, v_blocks, nibbles_per_row; h_blocks = ((image_w&0xff) == 0) ? (image_w>>8) : ((image_w>>8)+1); v_blocks = ((image_h&0xff) == 0) ? (image_h>>8) : ((image_h>>8)+1); nibbles_per_row = ((image_w%4)==0) ? (int)(image_w>>2) : (int)(image_w>>2)+1; for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); for (m=0; m < indent; m++) fputc(' ', FP); if (transformed) { fprintf(FP, " %1d %1d %s\n", orig_x, orig_y, gPsCmd[PS_TRANSLATE]); } else { fprintf(FP, " %1d %1d %s %.3f %.3f %s %1d %s\n\n", orig_x, orig_y, gPsCmd[PS_TRANSLATE], pmtrx->dump_h_scale, pmtrx->dump_v_scale, gPsCmd[PS_SCALE], pmtrx->degree, gPsCmd[PS_ROTATE]); } for (row=0; row < v_blocks; row++) { int y, col, block_h; y = row<<8; block_h = (row == v_blocks-1) ? image_h-y : 0x100; for (col=0; col < h_blocks; col++) { int i, j, x, num_nibbles, nibble_count, block_w; x = col<<8; block_w = (col == h_blocks-1) ? image_w-x : 0x100; num_nibbles = ((block_w%4) == 0) ? (int)(block_w>>2) : (int)(block_w>>2)+1; for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, " %s\n", gPsCmd[PS_GSAVE]); for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, " %1d %1d %s\n", x+adj_x, y, gPsCmd[PS_TRANSLATE]); for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, " %1d %1d true [1 0 0 1 0 0]\n", block_w, block_h); for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, " {<"); if (PRTGIF && !cmdLineOpenDisplay) { nibble_count = 0; for (i=0; i < block_h; i++) { for (j=0; j < num_nibbles; j++) { if (nibble_count++ == 64) { nibble_count = 1; fprintf(FP, "\n"); for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, " "); } fprintf(FP, "%c", data[(i+y)*nibbles_per_row+j+(x>>2)]); } if ((num_nibbles & 0x1) == 1) { if (nibble_count++ == 64) { nibble_count = 1; fprintf(FP, "\n"); for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, " "); } fprintf(FP, "0"); } } } else { nibble_count = 0; for (i=0; i < block_h; i++) { int bit_count=0, data; data = 0; for (j=0; j < block_w; j++) { data = (XGetPixel(image, j+x, i+y) == 1) ? (data<<1) | 1 : (data<<1); if (++bit_count == 4) { if (nibble_count++ == 64) { nibble_count = 1; fprintf(FP, "\n"); for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, " "); } fprintf(FP, "%c", hexValue[data]); bit_count = 0; data = 0; } } if ((block_w % 4) != 0) { data <<= (4 - (block_w % 4)); if (nibble_count++ == 64) { nibble_count = 1; fprintf(FP, "\n"); for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, " "); } fprintf(FP, "%c", hexValue[data]); } if ((num_nibbles & 0x1) == 1) { if (nibble_count++ == 64) { nibble_count = 1; fprintf(FP, "\n"); for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, " "); } fprintf(FP, "0"); } } } fprintf(FP, ">}\n"); for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, " %s\n", gPsCmd[PS_IMAGEMASK]); for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, " %s\n", gPsCmd[PS_GRESTORE]); if (row!=v_blocks-1 || col!=h_blocks-1) { fprintf(FP, "\n"); } } } for (m=0; m < indent; m++) fputc(' ', FP); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); } void DumpXBmObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { /* called when printing in the PostScript format */ int ltx, lty, rbx, rby, w, h, trans_pat, fill, image_w, image_h; int color_index, flip, orig_x=ObjPtr->x, orig_y=ObjPtr->y; Pixmap bitmap=None; XImage *image=NULL; struct XBmRec *xbm_ptr=ObjPtr->detail.xbm; struct MtrxRec mtrx; if (xbm_ptr->real_type == XBM_EPS) { DumpEPSObj(FP, ObjPtr); if (preDumpSetup) hasReadHexString = TRUE; return; } if (ObjPtr->ctm == NULL) { ltx = ObjPtr->obbox.ltx; lty = ObjPtr->obbox.lty; rbx = ObjPtr->obbox.rbx; rby = ObjPtr->obbox.rby; } else { ltx = ObjPtr->orig_obbox.ltx; lty = ObjPtr->orig_obbox.lty; rbx = ObjPtr->orig_obbox.rbx; rby = ObjPtr->orig_obbox.rby; } trans_pat = ObjPtr->trans_pat; bitmap = xbm_ptr->bitmap; fill = xbm_ptr->fill; flip = xbm_ptr->flip; image_w = xbm_ptr->image_w; image_h = xbm_ptr->image_h; w = rbx - ltx; h = rby - lty; if (!(PRTGIF && !cmdLineOpenDisplay)) { if ((image=xbm_ptr->image) == NULL) { if ((image=xbm_ptr->image=XGetImage(mainDisplay, bitmap, 0, 0, image_w, image_h, 1, ZPixmap)) == NULL) { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); return; } } } color_index = ObjPtr->color; if (ObjPtr->ctm == NULL) { memset(&mtrx, 0, sizeof(struct MtrxRec)); mtrx.image_w = (float)image_w; mtrx.image_h = (float)image_h; mtrx.w = (float)w; mtrx.h = (float)h; mtrx.rotate = ROTATE0; mtrx.flip = flip; CalcTransform(&mtrx); orig_x = (mtrx.transformed_w >= 0.0) ? ltx : ltx+w; orig_y = (mtrx.transformed_h >= 0.0) ? lty : lty+h; } fprintf(FP, "%% XBM\n"); if (ObjPtr->ctm != NULL) { float m[6]; fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); m[CTM_SX] = ((float)ObjPtr->ctm->m[CTM_SX])/((float)1000.0); m[CTM_SY] = ((float)ObjPtr->ctm->m[CTM_SY])/((float)1000.0); m[CTM_SIN] = ((float)ObjPtr->ctm->m[CTM_SIN])/((float)1000.0); m[CTM_MSIN] = ((float)ObjPtr->ctm->m[CTM_MSIN])/((float)1000.0); fprintf(FP, " %1d %1d %s\n", ObjPtr->x, ObjPtr->y, gPsCmd[PS_TRANSLATE]); fprintf(FP, " [%.3f %.3f %.3f %.3f %1d %1d] %s\n", m[CTM_SX], m[CTM_SIN], m[CTM_MSIN], m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY], gPsCmd[PS_CONCAT]); fprintf(FP, " %1d %s %1d %s %s\n", ObjPtr->x, gPsCmd[PS_NEG], ObjPtr->y, gPsCmd[PS_NEG], gPsCmd[PS_TRANSLATE]); } DumpRGBColorLine(FP, color_index, 0, TRUE); switch (fill) { case NONEPAT: break; case SOLIDPAT: DumpRectPath(FP, ltx, lty, rbx, rby, 0, FALSE); fprintf(FP, "%s\n", gPsCmd[PS_FILL]); break; case BACKPAT: if (!trans_pat) { DumpRectPath(FP, ltx, lty, rbx, rby, 0, FALSE); fprintf(FP, "1 %s %s\n\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 0, TRUE); } break; default: /* patterned */ fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); if (!trans_pat) { DumpRectPath(FP, ltx, lty, rbx, rby, 3, FALSE); fprintf(FP, "1 %s %s\n\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 3, TRUE); } DumpRectPath(FP, ltx, lty, rbx, rby, 3, FALSE); fprintf(FP, "%s %s\n", gPsCmd[PS_EOCLIP], gPsCmd[PS_NEWPATH]); DumpPatFill(FP, fill, ObjPtr->bbox, 3, TRUE); } else { GrayCheck(fill); fprintf(FP, " %s %s\n", GrayStr(fill), gPsCmd[PS_SETGRAY]); DumpRectPath(FP, ltx, lty, rbx, rby, 3, FALSE); fprintf(FP, "%s\n", gPsCmd[PS_FILL]); } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); break; } DumpBitmap(FP, image, ObjPtr->detail.xbm->data, image_w, image_h, (ObjPtr->ctm!=0), orig_x, orig_y, 0, &mtrx, 0); if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); } int NeedsToCacheXBmObj(ObjPtr) struct ObjRec *ObjPtr; { register struct XBmRec *xbm_ptr=ObjPtr->detail.xbm; int w, h; w = ObjPtr->obbox.rbx - ObjPtr->obbox.ltx; h = ObjPtr->obbox.rby - ObjPtr->obbox.lty; return (ObjPtr->ctm != NULL || zoomScale != 0 || xbm_ptr->image_w != w || xbm_ptr->image_h != h || xbm_ptr->flip != 0 ); } static void DrawHiddenXBm(win, ctm, vs, x, y, w, h, s) Window win; struct XfrmMtrxRec *ctm; XPoint *vs; int x, y, w, h; char *s; { int str_w, len, sx, sy; XGCValues values; values.foreground = GetDrawingFgPixel(INVALID, INVALID); values.function = GXcopy;; values.fill_style = FillSolid; #ifdef NO_THIN_LINE values.line_width = 1; #else values.line_width = 0; #endif values.font = rulerFontPtr->fid; values.line_style = LineSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCLineWidth | GCFont | GCLineStyle, &values); if (ctm != NULL) { XDrawLines(mainDisplay, win, drawGC, vs, 5, CoordModeOrigin); } else { XDrawRectangle(mainDisplay, win, drawGC, x, y, w, h); } len = strlen(s); str_w = rulerFontWidth*len; if (str_w < w && rulerFontHeight < h) { sx = x + ((w-str_w)>>1); sy = y + ((h-rulerFontHeight)>>1); XDrawString(mainDisplay, win, drawGC, sx, sy+rulerFontAsc, s, len); } XSetFont(mainDisplay, drawGC, canvasFontPtr->fid); } void DrawXBmObj(win, XOff, YOff, ObjPtr) Window win; int XOff, YOff; struct ObjRec *ObjPtr; { int ltx, lty, rbx, rby, w, h, scr_w, scr_h, fill, trans_pat; int real_x_off, real_y_off; char s[80]; struct XBmRec *xbm_ptr=ObjPtr->detail.xbm; XGCValues values; if (userDisableRedraw) return; if (ObjPtr->prev != NULL && ObjPtr->prev->type == OBJ_XBM && ObjPtr->prev->detail.xbm->real_type == XBM_XBM && ObjPtr->prev->detail.xbm->fill != NONEPAT && Inside(ObjPtr->obbox, ObjPtr->prev->obbox)) { return; } trans_pat = ObjPtr->trans_pat; fill = xbm_ptr->fill; w = ObjPtr->obbox.rbx - ObjPtr->obbox.ltx; h = ObjPtr->obbox.rby - ObjPtr->obbox.lty; real_x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<>zoomScale)<obbox.ltx - real_x_off); lty = ZOOMED_SIZE(ObjPtr->obbox.lty - real_y_off); rbx = ZOOMED_SIZE(ObjPtr->obbox.rbx - real_x_off); rby = ZOOMED_SIZE(ObjPtr->obbox.rby - real_y_off); scr_w = rbx - ltx; scr_h = rby - lty; if (xbm_ptr->real_type==XBM_XBM && fill != NONEPAT) { values.foreground = GetDrawingBgPixel(fill, colorPixels[ObjPtr->color]); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[fill]; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple, &values); if (ObjPtr->ctm != NULL) { XFillPolygon(mainDisplay, win, drawGC, ObjPtr->rotated_obbox, 5, Convex, CoordModeOrigin); } else { XFillRectangle(mainDisplay, win, drawGC, ltx, lty, scr_w, scr_h); } } if (!mapShown) { if (xbm_ptr->real_type == XBM_EPS) { DrawHiddenXBm(win, ObjPtr->ctm, ObjPtr->rotated_obbox, ltx, lty, scr_w, scr_h, xbm_ptr->filename); } else { sprintf(s, "(%1dx%1d)", xbm_ptr->image_w, xbm_ptr->image_h); DrawHiddenXBm(win, ObjPtr->ctm, ObjPtr->rotated_obbox, ltx, lty, scr_w, scr_h, s); } return; } if (NeedsToCacheXBmObj(ObjPtr) && xbm_ptr->cached_bitmap == None) { MakeCachedBitmap(ObjPtr); } if (xbm_ptr->real_type==XBM_XBM || (xbm_ptr->real_type==XBM_EPS && xbm_ptr->bitmap!=None)) { values.foreground = colorPixels[ObjPtr->color]; values.function = GXcopy; values.fill_style = FillStippled; values.ts_x_origin = ltx; values.ts_y_origin = lty; if (ObjPtr->ctm==NULL && zoomScale==0 && xbm_ptr->flip==0 && xbm_ptr->image_w==w && xbm_ptr->image_h==h) { values.stipple = xbm_ptr->bitmap; } else { if (xbm_ptr->cached_bitmap == None) return; values.stipple = xbm_ptr->cached_bitmap; } XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, win, drawGC, ltx, lty, scr_w, scr_h); XSetTSOrigin(mainDisplay, drawGC, 0, 0); } else if (xbm_ptr->real_type==XBM_EPS && xbm_ptr->bitmap==None) { DrawHiddenXBm(win, ObjPtr->ctm, ObjPtr->rotated_obbox, ltx, lty, rbx-ltx, rby-lty, xbm_ptr->filename); } } struct ObjRec *CreateXBmObj(ImageW, ImageH, W, H, bitmap, image) int ImageW, ImageH, W, H; Pixmap bitmap; XImage *image; { struct XBmRec *xbm_ptr; struct ObjRec *obj_ptr; xbm_ptr = (struct XBmRec *)malloc(sizeof(struct XBmRec)); if (xbm_ptr == NULL) FailAllocMessage(); memset(xbm_ptr, 0, sizeof(struct XBmRec)); xbm_ptr->image = image; xbm_ptr->image_w = ImageW; xbm_ptr->image_h = ImageH; xbm_ptr->bitmap = bitmap; xbm_ptr->data = NULL; xbm_ptr->eps_w = xbm_ptr->eps_h = 0; xbm_ptr->fill = objFill; xbm_ptr->flip = xbm_ptr->cached_flip = 0; xbm_ptr->cached_zoom = 0; xbm_ptr->cached_bitmap = None; xbm_ptr->cached_w = xbm_ptr->cached_h = 0; xbm_ptr->real_type = XBM_XBM; xbm_ptr->filename = NULL; xbm_ptr->epsflines = NULL; xbm_ptr->num_epsf_lines = 0; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = drawOrigX; obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = drawOrigY; obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = W + drawOrigX; obj_ptr->bbox.rby = obj_ptr->obbox.rby = H + drawOrigY; obj_ptr->type = OBJ_XBM; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->id = objId++; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->locked = FALSE; obj_ptr->detail.xbm = xbm_ptr; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; obj_ptr->invisible = FALSE; obj_ptr->trans_pat = transPat; if (importXBmRV) InvertXBmObject(obj_ptr); return (obj_ptr); } static void CopyXBmProperties(DestXbmObj, SrcXbmObj) struct ObjRec *DestXbmObj, *SrcXbmObj; { struct XBmRec *dest_xbm_ptr=DestXbmObj->detail.xbm; struct XBmRec *src_xbm_ptr=SrcXbmObj->detail.xbm; dest_xbm_ptr->fill = src_xbm_ptr->fill; DestXbmObj->color = SrcXbmObj->color; memcpy(DestXbmObj->color_str, SrcXbmObj->color_str, sizeof(DestXbmObj->color_str)); DestXbmObj->trans_pat = SrcXbmObj->trans_pat; } static int FinishBreakUpXBitmap(obj_ptr, cols_and_rows, cols, rows) struct ObjRec *obj_ptr; int cols_and_rows, cols, rows; { struct XBmRec *xbm_ptr=obj_ptr->detail.xbm; int y, image_w=xbm_ptr->image_w, image_h=xbm_ptr->image_h; int chunk_w=0, chunk_h=0, total_chunks=0; int orig_x=obj_ptr->x, orig_y=obj_ptr->y; if (cols_and_rows) { chunk_w = (int)(image_w / cols); chunk_h = (int)(image_h / rows); } else { chunk_w = cols; chunk_h = rows; } for (y=0; y < image_h; y += chunk_h) { int h=min(image_h-y,chunk_h), x; for (x=0; x < image_w; x += chunk_w) { int w=min(image_w-x,chunk_w); struct ObjRec *new_obj_ptr; Pixmap dest_bitmap=None; XImage *dest_image=NULL; if (w <= 0 || h <= 0 || !ExtractBitmap(xbm_ptr->bitmap, xbm_ptr->image, x, y, w, h, &dest_bitmap, &dest_image)) { continue; } total_chunks++; new_obj_ptr = CreateXBmObj(w, h, w, h, dest_bitmap, dest_image); CopyXBmProperties(new_obj_ptr, obj_ptr); AdjObjBBox(new_obj_ptr); MoveObj(new_obj_ptr, orig_x+x, orig_y+y); AddObj(NULL, topObj, new_obj_ptr); } } if (total_chunks > 0) { int i; RemoveAllSel(); UnlinkObj(obj_ptr); FreeObj(obj_ptr); for (i=0, obj_ptr=topObj; obj_ptr != NULL && i < total_chunks; i++, obj_ptr=obj_ptr->next) { AddObjIntoSel(obj_ptr, botSel, NULL, &topSel, &botSel); } } return (total_chunks > 0); } void BreakUpXBitmap(obj_ptr, cols_and_rows, cols, rows) struct ObjRec *obj_ptr; int cols_and_rows, cols, rows; { struct XBmRec *xbm_ptr=obj_ptr->detail.xbm; if (xbm_ptr->real_type == XBM_EPS) { MsgBox(TgLoadString(STID_CANNOT_BREAKUP_EPS), TOOL_NAME, INFO_MB); return; } HighLightReverse(); PrepareToReplaceAnObj(obj_ptr); if (FinishBreakUpXBitmap(obj_ptr, cols_and_rows, cols, rows)) { UpdSelBBox(); RecordCmd(CMD_ONE_TO_MANY, NULL, topSel, botSel, numObjSelected); SetFileModified(TRUE); justDupped = FALSE; } else { AbortPrepareCmd(CMD_REPLACE); } HighLightForward(); } void DumpXBmData(FP, bitmap, image, W, H) FILE *FP; Pixmap bitmap; XImage **image; int W, H; { register int nibble_count, bit_count, data, i, j; if (*image == NULL) { if ((*image=XGetImage(mainDisplay,bitmap,0,0,W,H,1,ZPixmap)) == NULL) { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); return; } } nibble_count = 0; for (i=0; i < H; i++) { bit_count = 0; data = 0; for (j=0; j < W; j++) { data = (XGetPixel(*image, j, i) == 1) ? (data<<1) | 1 : (data<<1); if (++bit_count == 4) { if (nibble_count++ == 64) { nibble_count = 1; if (fprintf(FP, "\n ") == EOF) writeFileFailed = TRUE; } if (fprintf(FP, "%c", hexValue[data]) == EOF) { writeFileFailed = TRUE; } bit_count = 0; data = 0; } } if ((W % 4) != 0) { data <<= (4 - (W % 4)); if (nibble_count++ == 64) { nibble_count = 1; if (fprintf(FP, "\n ") == EOF) writeFileFailed = TRUE; } if (fprintf(FP, "%c", hexValue[data]) == EOF) writeFileFailed = TRUE; } } } void SaveXBmObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { register int i; int ltx, lty, rbx, rby, image_w, image_h; int no_bitmap, compressed=FALSE; struct XBmRec *xbm_ptr=ObjPtr->detail.xbm; no_bitmap = (xbm_ptr->real_type==XBM_EPS && !(xbm_ptr->save_epsf && xbm_ptr->bitmap != None)); ltx = ObjPtr->obbox.ltx; lty = ObjPtr->obbox.lty; rbx = ObjPtr->obbox.rbx; rby = ObjPtr->obbox.rby; if (no_bitmap) { image_w = xbm_ptr->eps_w; image_h = xbm_ptr->eps_h; } else { image_w = xbm_ptr->image_w; image_h = xbm_ptr->image_h; } if (fprintf(FP, "xbm('%s','',", colorMenuItems[ObjPtr->color]) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,0,%1d,%1d,%1d,%1d,%1d,%1d,", ltx, lty, rbx, rby, xbm_ptr->fill, ObjPtr->id, ObjPtr->rotation, image_w, image_h, xbm_ptr->flip, xbm_ptr->real_type, xbm_ptr->llx, xbm_ptr->lly, xbm_ptr->urx, xbm_ptr->ury) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,\n ", no_bitmap, ObjPtr->locked, xbm_ptr->save_epsf, compressed, ObjPtr->ctm!=NULL, ObjPtr->invisible, ObjPtr->trans_pat) == EOF) { writeFileFailed = TRUE; } switch (xbm_ptr->real_type) { case XBM_XBM: if (fprintf(FP, "\"\",\"\",") == EOF) writeFileFailed = TRUE; break; case XBM_EPS: if (fprintf(FP, "\"%s\",\"%s\",", xbm_ptr->write_date, xbm_ptr->filename) == EOF) { writeFileFailed = TRUE; } break; } if (xbm_ptr->save_epsf) { if (fprintf(FP, "%1d,[", xbm_ptr->num_epsf_lines) == EOF) { writeFileFailed = TRUE; } for (i = 0; i < xbm_ptr->num_epsf_lines; i++) { if (fprintf(FP, "\n \"%s\"%s,", xbm_ptr->epsflines[i], (i==xbm_ptr->num_epsf_lines-1 ? "]" : "")) == EOF) { writeFileFailed = TRUE; } } } if (!no_bitmap) { if (fprintf(FP, "\n \"") == EOF) writeFileFailed = TRUE; DumpXBmData(FP, xbm_ptr->bitmap, &(xbm_ptr->image), image_w, image_h); if (fprintf(FP, "\",") == EOF) writeFileFailed = TRUE; } if (ObjPtr->ctm != NULL && fprintf(FP, "[\n %1d,%1d,%1d,%1d,%1d,%1d,%g,%g,%g,%g,%1d,%1d],", ObjPtr->x, ObjPtr->y, ObjPtr->orig_obbox.ltx, ObjPtr->orig_obbox.lty, ObjPtr->orig_obbox.rbx, ObjPtr->orig_obbox.rby, ObjPtr->ctm->m[CTM_SX], ObjPtr->ctm->m[CTM_SIN], ObjPtr->ctm->m[CTM_MSIN], ObjPtr->ctm->m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY]) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, " "); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } static int ReadTransformAndAdjustForXBm(FP, ObjPtr, xbm_ptr, transformed, rotate, flip) FILE *FP; struct ObjRec **ObjPtr; struct XBmRec *xbm_ptr; int transformed, rotate, flip; { if (fileVersion >= 33 && transformed) { char inbuf[MAXSTRING]; struct XfrmMtrxRec *ctm=NULL; int real_x=0, real_y=0; struct BBRec orig_obbox; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, "); ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ctm == NULL) FailAllocMessage(); if (GETINT("xbitmap", real_x, "real_x") == INVALID || GETINT("xbitmap", real_y, "real_y") == INVALID || GETINT("xbitmap", orig_obbox.ltx, "orig_obbox.ltx") == INVALID || GETINT("xbitmap", orig_obbox.lty, "orig_obbox.lty") == INVALID || GETINT("xbitmap", orig_obbox.rbx, "orig_obbox.rbx") == INVALID || GETINT("xbitmap", orig_obbox.rby, "orig_obbox.rby") == INVALID || GETDBL("xbitmap", ctm->m[CTM_SX], "CTM_SX") == INVALID || GETDBL("xbitmap", ctm->m[CTM_SIN], "CTM_SIN") == INVALID || GETDBL("xbitmap", ctm->m[CTM_MSIN], "CTM_MSIN") == INVALID || GETDBL("xbitmap", ctm->m[CTM_SY], "CTM_SY") == INVALID || GETINT("xbitmap", ctm->t[CTM_TX], "CTM_TX") == INVALID || GETINT("xbitmap", ctm->t[CTM_TY], "CTM_TY") == INVALID) { return FALSE; } (*ObjPtr)->ctm = ctm; if (ctm != NULL) { memcpy(&(*ObjPtr)->orig_obbox, &orig_obbox, sizeof(struct BBRec)); (*ObjPtr)->x = real_x; (*ObjPtr)->y = real_y; GetTransformedOBBoxOffsetVs(*ObjPtr, (*ObjPtr)->rotated_obbox); } } if (fileVersion < 33 && (rotate != ROTATE0 || flip != NO_FLIP)) { int ltx, lty, rbx, rby; double dz=(double)0, d1=(double)1000.0, dm1=((double)-1000.0); if (rotate == ROTATE90 || rotate == ROTATE270) { int h=(*ObjPtr)->obbox.rbx-(*ObjPtr)->obbox.ltx; int w=(*ObjPtr)->obbox.rby-(*ObjPtr)->obbox.lty; (*ObjPtr)->obbox.rby = (*ObjPtr)->obbox.lty + h; (*ObjPtr)->obbox.rbx = (*ObjPtr)->obbox.ltx + w; } ltx = ((*ObjPtr)->obbox.ltx); lty = ((*ObjPtr)->obbox.lty); rbx = ((*ObjPtr)->obbox.rbx); rby = ((*ObjPtr)->obbox.rby); SetRotatePivotByObject(*ObjPtr); if ((*ObjPtr)->ctm == NULL) { int image_w=0, image_h=0; if (xbm_ptr->bitmap == None) { image_w = xbm_ptr->eps_w; image_h = xbm_ptr->eps_h; } else { image_w = xbm_ptr->image_w; image_h = xbm_ptr->image_h; } if (image_w != rbx-ltx || image_h != rby-lty) { float fval=(float)0; double dx_scale=(double)0, dy_scale=(double)0; struct XfrmMtrxRec ctm; memset(&ctm, 0, sizeof(struct XfrmMtrxRec)); fval = ((float)(rbx-ltx))/((float)image_w)*((float)1000.0); dx_scale = (double)fval; fval = ((float)(rby-lty))/((float)image_h)*((float)1000.0); dy_scale = (double)fval; (*ObjPtr)->obbox.rbx = ltx+image_w; (*ObjPtr)->obbox.rby = lty+image_h; ShearObj(*ObjPtr, CORNER_RB, dz, dz, dx_scale, dy_scale, NULL, NULL); } } if (flip & HORI_EVEN) { ShearObj(*ObjPtr, CORNER_LEFT, dz, dz, dm1, d1, <x, <y); } if (flip & VERT_EVEN) { ShearObj(*ObjPtr, CORNER_TOP, dz, dz, d1, dm1, <x, <y); } if (rotate == ROTATE0) { if (flip & (HORI_ODD | VERT_ODD)) { RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); if (flip & HORI_ODD) { ShearObj(*ObjPtr, CORNER_LEFT, dz, dz, dm1, d1, <x, <y); } if (flip & VERT_ODD) { ShearObj(*ObjPtr, CORNER_TOP, dz, dz, d1, dm1, <x, <y); } RotateObj(*ObjPtr, CORNER_LT, COUNTER90, <x, <y); } } else { switch (rotate) { case ROTATE90: RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); if (flip & HORI_ODD) { ShearObj(*ObjPtr, CORNER_LEFT, dz, dz, dm1, d1, <x, <y); } if (flip & VERT_ODD) { ShearObj(*ObjPtr, CORNER_TOP, dz, dz, d1, dm1, <x, <y); } break; case ROTATE180: RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); if (flip & HORI_ODD) { ShearObj(*ObjPtr, CORNER_LEFT, dz, dz, dm1, d1, <x, <y); } if (flip & VERT_ODD) { ShearObj(*ObjPtr, CORNER_TOP, dz, dz, d1, dm1, <x, <y); } RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); break; case ROTATE270: RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); if (flip & HORI_ODD) { ShearObj(*ObjPtr, CORNER_LEFT, dz, dz, dm1, d1, <x, <y); } if (flip & VERT_ODD) { ShearObj(*ObjPtr, CORNER_TOP, dz, dz, d1, dm1, <x, <y); } RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); break; } } xbm_ptr->flip = NO_FLIP; } return TRUE; } void ReadXBmObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { struct XBmRec *xbm_ptr=NULL; char color_str[40], bg_color_str[40], *s, inbuf[MAXSTRING], *c_ptr; int ltx, lty, rbx, rby, i, j, k, data=0, color_index; int nibble_count, bit_count, num_nibbles, fill, trans_pat=FALSE; int rotation=0, new_alloc, id=0, image_w=0, image_h=0; int rotate=ROTATE0, flip=NO_FLIP, real_type=XBM_XBM, len; int no_bitmap=FALSE, llx=0, lly=0, urx=0, ury=0; int locked=FALSE, save_epsf=FALSE, compressed=FALSE; int num_epsf_lines=0, transform_read=FALSE; int transformed=FALSE, invisible=FALSE; Pixmap bitmap; char **epsflines=NULL; char *xbm_data, write_date[32], *filename; XImage *image; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_str, sizeof(color_str)); if (fileVersion >= 37) { s = ParseStr(s, (int)',', bg_color_str, sizeof(bg_color_str)); } InitScan(s, "\t\n, "); if (fileVersion <= 8) { sprintf(inbuf, TgLoadCachedString(CSTID_INVALID_FILEVER_FOR_XBM), fileVersion); if (PRTGIF) { fprintf(stderr, "%s\n", inbuf); } else { Msg(inbuf); } return; } else if (fileVersion <= 13) { if (GETINT("xbitmap", ltx, "ltx") == INVALID || GETINT("xbitmap", lty, "lty") == INVALID || GETINT("xbitmap", rbx, "rbx") == INVALID || GETINT("xbitmap", rby, "rby") == INVALID || GETINT("xbitmap", fill, "fill") == INVALID || GETINT("xbitmap", id, "id") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 22) { if (GETINT("xbitmap", ltx, "ltx") == INVALID || GETINT("xbitmap", lty, "lty") == INVALID || GETINT("xbitmap", rbx, "rbx") == INVALID || GETINT("xbitmap", rby, "rby") == INVALID || GETINT("xbitmap", fill, "fill") == INVALID || GETINT("xbitmap", id, "id") == INVALID || GETINT("xbitmap", rotation, "rotation") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 23) { if (GETINT("xbitmap", ltx, "ltx") == INVALID || GETINT("xbitmap", lty, "lty") == INVALID || GETINT("xbitmap", rbx, "rbx") == INVALID || GETINT("xbitmap", rby, "rby") == INVALID || GETINT("xbitmap", fill, "fill") == INVALID || GETINT("xbitmap", id, "id") == INVALID || GETINT("xbitmap", rotation, "rotation") == INVALID || GETINT("xbitmap", image_w, "image_w") == INVALID || GETINT("xbitmap", image_h, "image_h") == INVALID || GETINT("xbitmap", rotate, "rotate") == INVALID || GETINT("xbitmap", flip, "flip") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 25) { if (GETINT("xbitmap", ltx, "ltx") == INVALID || GETINT("xbitmap", lty, "lty") == INVALID || GETINT("xbitmap", rbx, "rbx") == INVALID || GETINT("xbitmap", rby, "rby") == INVALID || GETINT("xbitmap", fill, "fill") == INVALID || GETINT("xbitmap", id, "id") == INVALID || GETINT("xbitmap", rotation, "rotation") == INVALID || GETINT("xbitmap", image_w, "image_w") == INVALID || GETINT("xbitmap", image_h, "image_h") == INVALID || GETINT("xbitmap", rotate, "rotate") == INVALID || GETINT("xbitmap", flip, "flip") == INVALID || GETINT("xbitmap", real_type, "real_type") == INVALID || GETINT("xbitmap", llx, "llx") == INVALID || GETINT("xbitmap", lly, "lly") == INVALID || GETINT("xbitmap", urx, "urx") == INVALID || GETINT("xbitmap", ury, "ury") == INVALID || GETINT("xbitmap", no_bitmap, "no_bitmap") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 28) { if (GETINT("xbitmap", ltx, "ltx") == INVALID || GETINT("xbitmap", lty, "lty") == INVALID || GETINT("xbitmap", rbx, "rbx") == INVALID || GETINT("xbitmap", rby, "rby") == INVALID || GETINT("xbitmap", fill, "fill") == INVALID || GETINT("xbitmap", id, "id") == INVALID || GETINT("xbitmap", rotation, "rotation") == INVALID || GETINT("xbitmap", image_w, "image_w") == INVALID || GETINT("xbitmap", image_h, "image_h") == INVALID || GETINT("xbitmap", rotate, "rotate") == INVALID || GETINT("xbitmap", flip, "flip") == INVALID || GETINT("xbitmap", real_type, "real_type") == INVALID || GETINT("xbitmap", llx, "llx") == INVALID || GETINT("xbitmap", lly, "lly") == INVALID || GETINT("xbitmap", urx, "urx") == INVALID || GETINT("xbitmap", ury, "ury") == INVALID || GETINT("xbitmap", no_bitmap, "no_bitmap") == INVALID || GETINT("xbitmap", locked, "locked") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 32) { if (GETINT("xbitmap", ltx, "ltx") == INVALID || GETINT("xbitmap", lty, "lty") == INVALID || GETINT("xbitmap", rbx, "rbx") == INVALID || GETINT("xbitmap", rby, "rby") == INVALID || GETINT("xbitmap", fill, "fill") == INVALID || GETINT("xbitmap", id, "id") == INVALID || GETINT("xbitmap", rotation, "rotation") == INVALID || GETINT("xbitmap", image_w, "image_w") == INVALID || GETINT("xbitmap", image_h, "image_h") == INVALID || GETINT("xbitmap", rotate, "rotate") == INVALID || GETINT("xbitmap", flip, "flip") == INVALID || GETINT("xbitmap", real_type, "real_type") == INVALID || GETINT("xbitmap", llx, "llx") == INVALID || GETINT("xbitmap", lly, "lly") == INVALID || GETINT("xbitmap", urx, "urx") == INVALID || GETINT("xbitmap", ury, "ury") == INVALID || GETINT("xbitmap", no_bitmap, "no_bitmap") == INVALID || GETINT("xbitmap", locked, "locked") == INVALID || GETINT("xbitmap", save_epsf, "save_epsf") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 34) { if (GETINT("xbitmap", ltx, "ltx") == INVALID || GETINT("xbitmap", lty, "lty") == INVALID || GETINT("xbitmap", rbx, "rbx") == INVALID || GETINT("xbitmap", rby, "rby") == INVALID || GETINT("xbitmap", fill, "fill") == INVALID || GETINT("xbitmap", id, "id") == INVALID || GETINT("xbitmap", rotation, "rotation") == INVALID || GETINT("xbitmap", image_w, "image_w") == INVALID || GETINT("xbitmap", image_h, "image_h") == INVALID || GETINT("xbitmap", rotate, "rotate") == INVALID || GETINT("xbitmap", flip, "flip") == INVALID || GETINT("xbitmap", real_type, "real_type") == INVALID || GETINT("xbitmap", llx, "llx") == INVALID || GETINT("xbitmap", lly, "lly") == INVALID || GETINT("xbitmap", urx, "urx") == INVALID || GETINT("xbitmap", ury, "ury") == INVALID || GETINT("xbitmap", no_bitmap, "no_bitmap") == INVALID || GETINT("xbitmap", locked, "locked") == INVALID || GETINT("xbitmap", save_epsf, "save_epsf") == INVALID || GETINT("xbitmap", compressed, "compressed") == INVALID || GETINT("xbitmap", transformed, "transformed") == INVALID || GETINT("xbitmap", invisible, "invisible") == INVALID) { return; } if (id >= objId) objId = id+1; } else { if (GETINT("xbitmap", ltx, "ltx") == INVALID || GETINT("xbitmap", lty, "lty") == INVALID || GETINT("xbitmap", rbx, "rbx") == INVALID || GETINT("xbitmap", rby, "rby") == INVALID || GETINT("xbitmap", fill, "fill") == INVALID || GETINT("xbitmap", id, "id") == INVALID || GETINT("xbitmap", rotation, "rotation") == INVALID || GETINT("xbitmap", image_w, "image_w") == INVALID || GETINT("xbitmap", image_h, "image_h") == INVALID || GETINT("xbitmap", rotate, "rotate") == INVALID || GETINT("xbitmap", flip, "flip") == INVALID || GETINT("xbitmap", real_type, "real_type") == INVALID || GETINT("xbitmap", llx, "llx") == INVALID || GETINT("xbitmap", lly, "lly") == INVALID || GETINT("xbitmap", urx, "urx") == INVALID || GETINT("xbitmap", ury, "ury") == INVALID || GETINT("xbitmap", no_bitmap, "no_bitmap") == INVALID || GETINT("xbitmap", locked, "locked") == INVALID || GETINT("xbitmap", save_epsf, "save_epsf") == INVALID || GETINT("xbitmap", compressed, "compressed") == INVALID || GETINT("xbitmap", transformed, "transformed") == INVALID || GETINT("xbitmap", invisible, "invisible") == INVALID || GETINT("xbitmap", trans_pat, "trans_pat") == INVALID) { return; } if (id >= objId) objId = id+1; } if (fileVersion <= 22) { image_w = rbx-ltx; image_h = rby-lty; rotate = ROTATE0; flip = 0; } if (fileVersion >= 24) { char *tmp_str, *s, *s1; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; tmp_str = FindChar((int)'"', inbuf); s = s1 = ReadString(tmp_str); s1++; *(--s) = '\0'; len = strlen(tmp_str); if (len > 24) { (void)sprintf(gszMsgBox, TgLoadCachedString(CSTID_FIELD_TOO_LONG_IN_OBJ_TRUNC), scanFileName, scanLineNum, "write_date", "xbm"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } tmp_str[23] = '\0'; } strcpy(write_date, tmp_str); tmp_str = FindChar((int)'"', s1); s = ReadString(tmp_str); *(--s) = '\0'; len = strlen(tmp_str); filename = (char*)malloc((len+1)*sizeof(char)); if (filename == NULL) FailAllocMessage(); strcpy(filename, tmp_str); if (save_epsf) { if (sscanf(&s[2], "%d", &num_epsf_lines) != 1) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_FILE_LINE_BAD_FLD_IN_OBJ_STR), scanFileName, scanLineNum, "num_epsf_lines", "xbm", &s[2]); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return; } epsflines = (char**)malloc(num_epsf_lines*sizeof(char*)); if (epsflines == NULL) FailAllocMessage(); for (i=0; i < num_epsf_lines; i++) { if (fgets(inbuf, MAXSTRING, FP) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanLineNum, scanFileName, "ReadXBmObj()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return; } scanLineNum++; len = strlen(inbuf); if ((c_ptr=strchr(inbuf, '"')) == NULL) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_MALFORMED_LINE_NUM_IN_FILE), scanLineNum, scanFileName); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return; } c_ptr++; len -= (c_ptr-inbuf); if (c_ptr[len-1] != '\n') { int cur_size=2*MAXSTRING-1, done=FALSE; char *line=(char*)malloc((cur_size+1)*sizeof(char)); if (line == NULL) FailAllocMessage(); strcpy(line, c_ptr); c_ptr = &(line[len]); while (!done && fgets(inbuf, MAXSTRING, FP) != NULL) { len = strlen(inbuf); if (inbuf[len-1] == '\r' || inbuf[len-1] == '\n') { done = TRUE; inbuf[len-1] = '\0'; strcpy(c_ptr, inbuf); } else { int n=c_ptr-line; cur_size += MAXSTRING-1; line = (char*)realloc(line, cur_size+1); c_ptr = line + n; strcpy(c_ptr, inbuf); c_ptr += MAXSTRING-1; } } if (!done) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanLineNum, scanFileName, "ReadXBmObj()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return; } epsflines[i] = line; len = strlen(line); } else { c_ptr[--len] = '\0'; epsflines[i] = (char*)malloc((len+1)*sizeof(char)); if (epsflines[i] == NULL) FailAllocMessage(); strncpy(epsflines[i], c_ptr, len); epsflines[i][len] = '\0'; } for (c_ptr=(&(epsflines[i])[len]); c_ptr != epsflines[i] && *c_ptr != '"'; c_ptr--) ; if (*c_ptr != '"') { sprintf(gszMsgBox, TgLoadCachedString(CSTID_MALFORMED_LINE_NUM_IN_FILE), scanLineNum, scanFileName); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return; } *c_ptr = '\0'; } } } else { *write_date = '\0'; filename = NULL; } fill = UpgradePenFill(fill); *ObjPtr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (*ObjPtr == NULL) FailAllocMessage(); memset(*ObjPtr, 0, sizeof(struct ObjRec)); xbm_ptr = (struct XBmRec *)malloc(sizeof(struct XBmRec)); if (xbm_ptr == NULL) FailAllocMessage(); memset(xbm_ptr, 0, sizeof(struct XBmRec)); color_index = QuickFindColorIndex(*ObjPtr, color_str, &new_alloc, TRUE); (*ObjPtr)->color = color_index; if (mainDisplay != NULL) { UtilStrCpyN((*ObjPtr)->color_str, sizeof((*ObjPtr)->color_str), colorMenuItems[color_index]); } (*ObjPtr)->dirty = FALSE; (*ObjPtr)->id = id; (*ObjPtr)->rotation = rotation; (*ObjPtr)->locked = locked; (*ObjPtr)->type = OBJ_XBM; (*ObjPtr)->obbox.ltx = (*ObjPtr)->bbox.ltx = (*ObjPtr)->x = ltx; (*ObjPtr)->obbox.lty = (*ObjPtr)->bbox.lty = (*ObjPtr)->y = lty; (*ObjPtr)->obbox.rbx = (*ObjPtr)->bbox.rbx = rbx; (*ObjPtr)->obbox.rby = (*ObjPtr)->bbox.rby = rby; (*ObjPtr)->detail.xbm = xbm_ptr; (*ObjPtr)->ctm = NULL; (*ObjPtr)->invisible = invisible; (*ObjPtr)->trans_pat = trans_pat; xbm_ptr->bitmap = None; xbm_ptr->image = NULL; xbm_ptr->cached_bitmap = None; xbm_ptr->cached_zoom = 0; xbm_ptr->data = NULL; xbm_ptr->fill = fill; xbm_ptr->flip = flip; xbm_ptr->cached_flip = 0; xbm_ptr->cached_w = xbm_ptr->cached_h = 0; xbm_ptr->image_w = image_w; xbm_ptr->image_h = image_h; xbm_ptr->llx = llx; xbm_ptr->lly = lly; xbm_ptr->urx = urx; xbm_ptr->ury = ury; xbm_ptr->real_type = real_type; strcpy(xbm_ptr->write_date, write_date); xbm_ptr->filename = filename; xbm_ptr->epsflines = epsflines; xbm_ptr->num_epsf_lines = num_epsf_lines; xbm_ptr->save_epsf = save_epsf; if (no_bitmap && xbm_ptr->real_type==XBM_EPS) { float file_llx=0.0, file_lly=0.0, file_urx=0.0, file_ury=0.0; xbm_ptr->eps_w = xbm_ptr->image_w; xbm_ptr->eps_h = xbm_ptr->image_h; xbm_ptr->image_w = 0; xbm_ptr->image_h = 0; if (!(PRTGIF && !cmdLineOpenDisplay)) { transform_read = TRUE; if (!ReadTransformAndAdjustForXBm(FP, ObjPtr, xbm_ptr, transformed, rotate, flip)) { return; } if (MyReadEPSFile(xbm_ptr->filename, &image_w, &image_h, &(xbm_ptr->bitmap), &(xbm_ptr->image), (save_epsf ? &(xbm_ptr->num_epsf_lines) : NULL), (save_epsf ? &(xbm_ptr->epsflines) : NULL), &(xbm_ptr->epsf_level), &file_llx, &file_lly, &file_urx, &file_ury, xbm_ptr->write_date) != BitmapSuccess) { return; } else if (xbm_ptr->bitmap == None) { xbm_ptr->eps_w = (file_urx >= file_llx) ? (int)(file_urx-file_llx) : (int)(file_llx-file_urx); xbm_ptr->eps_h = (file_ury >= file_lly) ? (int)(file_ury-file_lly) : (int)(file_lly-file_ury); } else { xbm_ptr->image_w = image_w; xbm_ptr->image_h = image_h; /* same as above! */ xbm_ptr->eps_w = (file_urx >= file_llx) ? (int)(file_urx-file_llx) : (int)(file_llx-file_urx); xbm_ptr->eps_h = (file_ury >= file_lly) ? (int)(file_ury-file_lly) : (int)(file_lly-file_ury); } xbm_ptr->llx = (int)(file_llx*1000.0); xbm_ptr->lly = (int)(file_lly*1000.0); xbm_ptr->urx = (int)(file_urx*1000.0); xbm_ptr->ury = (int)(file_ury*1000.0); } } else { if (xbm_ptr->real_type == XBM_EPS) { float file_llx=((float)xbm_ptr->llx)/1000.0; float file_lly=((float)xbm_ptr->lly)/1000.0; float file_urx=((float)xbm_ptr->urx)/1000.0; float file_ury=((float)xbm_ptr->ury)/1000.0; /* same as above! */ xbm_ptr->eps_w = (file_urx >= file_llx) ? (int)(file_urx-file_llx) : (int)(file_llx-file_urx); xbm_ptr->eps_h = (file_ury >= file_lly) ? (int)(file_ury-file_lly) : (int)(file_lly-file_ury); } else { xbm_ptr->eps_w = xbm_ptr->eps_h = 0; } num_nibbles = ((image_w % 4) == 0) ? (int)(image_w>>2) : (int)(image_w>>2)+1; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; c_ptr = &inbuf[5]; nibble_count = 0; if (PRTGIF && !cmdLineOpenDisplay) { xbm_data = (char*)malloc((image_h*num_nibbles)*sizeof(char)); if (xbm_data == NULL) FailAllocMessage(); for (i = 0; i < image_h; i++) { for (j = 0; j < num_nibbles; j++) { if (nibble_count++ == 64) { (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; c_ptr = &inbuf[5]; nibble_count = 1; } xbm_data[i*num_nibbles+j] = *c_ptr++; } } xbm_ptr->data = xbm_data; } else { bitmap = XCreatePixmap(mainDisplay, dummyBitmap, image_w, image_h, 1); XFillRectangle(mainDisplay, bitmap, xbmGC, 0, 0, image_w, image_h); image = XGetImage(mainDisplay,bitmap,0,0,image_w,image_h,1,ZPixmap); for (i = 0; i < image_h; i++) { bit_count = 0; for (j = 0; j < num_nibbles; j++) { if (nibble_count++ == 64) { (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; c_ptr = &inbuf[5]; nibble_count = 1; } if (*c_ptr >= '0' && *c_ptr <= '9') { data = (int)(*c_ptr++) - (int)('0'); } else if (*c_ptr >= 'a' && *c_ptr <= 'f') { data = (int)(*c_ptr++) - (int)('a') + 10; } for (k = 0; k < 4; k++) { if (bit_count++ == image_w) break; if (data & (1<<(3-k))) { XPutPixel(image, j*4+k, i, 1); } } } } XPutImage(mainDisplay,bitmap,xbmGC,image,0,0,0,0,image_w,image_h); xbm_ptr->bitmap = bitmap; xbm_ptr->image = image; } } if (!transform_read && !ReadTransformAndAdjustForXBm(FP, ObjPtr, xbm_ptr, transformed, rotate, flip)) { return; } if (!transform_read && (!(PRTGIF && !cmdLineOpenDisplay)) && (*ObjPtr)->ctm == NULL) { struct BBRec orig_obbox; SetBBRec(&orig_obbox, ltx, lty, rbx, rby); SetEPSObjCTM(*ObjPtr, &orig_obbox); } } void SetXBmPropMask(ObjPtr, plMask, plSkip, pProp) struct ObjRec *ObjPtr; long *plMask, *plSkip; struct PropertiesRec *pProp; { struct XBmRec *xbm_ptr=ObjPtr->detail.xbm; SetCTMPropertyMask(ObjPtr->ctm, plMask, plSkip, pProp); if (xbm_ptr->real_type != XBM_EPS) { SetIntPropertyMask(PROP_MASK_COLOR, ObjPtr->color, colorMenuItems[ObjPtr->color], plMask, plSkip, pProp); } } void FreeXBmObj(ObjPtr) struct ObjRec *ObjPtr; { register struct XBmRec *xbm_ptr=ObjPtr->detail.xbm; register int i; if (xbm_ptr->bitmap != None) XFreePixmap(mainDisplay, xbm_ptr->bitmap); if (xbm_ptr->image != NULL) XDestroyImage(xbm_ptr->image); if (xbm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xbm_ptr->cached_bitmap); } xbm_ptr->bitmap = None; xbm_ptr->image = NULL; xbm_ptr->cached_bitmap = None; xbm_ptr->cached_zoom = 0; if (xbm_ptr->data != NULL) free(xbm_ptr->data); if (xbm_ptr->filename != NULL) free(xbm_ptr->filename); if (xbm_ptr->real_type == XBM_EPS) { for (i = 0; i < xbm_ptr->num_epsf_lines; i++) { if (xbm_ptr->epsflines[i] != NULL) { free(xbm_ptr->epsflines[i]); } } if (xbm_ptr->epsflines != NULL) free(xbm_ptr->epsflines); } free(xbm_ptr); free(ObjPtr); } tgif-QPL-4.2.5/Tgif.tmpl-freebsd0000644000076400007640000000437411602233313016174 0ustar williamwilliamXCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-freebsd,v 1.12 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_NO_IDNLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) XCOMM SYS_LIBRARIES = -ldl -lm -lz SYS_LIBRARIES = -lm -lz tgif-QPL-4.2.5/align.c0000644000076400007640000020705611602233310014232 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/align.c,v 1.25 2011/05/16 16:21:56 william Exp $ */ #define _INCLUDE_FROM_ALIGN_C_ #include "tgifdefs.h" #include "cmdids.h" #include "align.e" #include "auxtext.e" #include "button.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "grid.e" #include "mark.e" #include "mainmenu.e" #include "menu.e" #include "menuinfo.e" #include "move.e" #include "msg.e" #include "obj.e" #include "poly.e" #include "raster.e" #include "rect.e" #include "select.e" #include "setup.e" #include "stretch.e" #include "strtbl.e" #include "util.e" typedef struct DistrVRec { struct ObjRec *obj; struct VSelRec *vsel; int index, vindex, x, y; struct DistrVRec *next, *prev; } * DistrVRecPtr; int horiAlign=ALIGN_L; int vertAlign=ALIGN_T; int alignDirectType=INVALID; static void SetSSSIForDistr(obj_ptr, vsel_ptr, update_pmvi) struct ObjRec *obj_ptr; struct VSelRec *vsel_ptr; int update_pmvi; { IntPoint *vlist=NULL; int i=0, n=0; StretchStructuredSplineInfo *psssi=NULL; switch (obj_ptr->type) { case OBJ_POLY: vlist = obj_ptr->detail.p->vlist; n = obj_ptr->detail.p->n; if (obj_ptr->userdata == NULL && obj_ptr->detail.p->curved == LT_STRUCT_SPLINE) { psssi = (StretchStructuredSplineInfo*)malloc( sizeof(StretchStructuredSplineInfo)); if (psssi == NULL) FailAllocMessage(); memset(psssi, 0, sizeof(StretchStructuredSplineInfo)); SetIPTInfoForStretchPoly(vsel_ptr->v_index[0], n, vlist, psssi); psssi->orig_abs_x = psssi->new_abs_x = vlist[vsel_ptr->v_index[0]].x; psssi->orig_abs_y = psssi->new_abs_y = vlist[vsel_ptr->v_index[0]].y; obj_ptr->userdata = psssi; if (obj_ptr->ctm != NULL) { psssi->rotated_orig_abs_x = psssi->rotated_new_abs_x = vsel_ptr->x[0]; psssi->rotated_orig_abs_y = psssi->rotated_new_abs_y = vsel_ptr->y[0]; } } if (update_pmvi && vsel_ptr->pmvi == NULL && obj_ptr->detail.p->curved != LT_STRUCT_SPLINE) { vsel_ptr->pmvi = (MoveVertexInfo*)malloc( vsel_ptr->n*sizeof(MoveVertexInfo)); memset(vsel_ptr->pmvi, 0, vsel_ptr->n*sizeof(MoveVertexInfo)); for (i=0; i < vsel_ptr->n; i++) { vsel_ptr->pmvi[i].orig_abs_x = vsel_ptr->pmvi[i].new_abs_x = vlist[vsel_ptr->v_index[i]].x; vsel_ptr->pmvi[i].orig_abs_y = vsel_ptr->pmvi[i].new_abs_y = vlist[vsel_ptr->v_index[i]].y; if (obj_ptr->ctm != NULL) { vsel_ptr->pmvi[i].rotated_orig_abs_x = vsel_ptr->pmvi[i].rotated_new_abs_x = vsel_ptr->x[i]; vsel_ptr->pmvi[i].rotated_orig_abs_y = vsel_ptr->pmvi[i].rotated_new_abs_y = vsel_ptr->y[i]; } } } break; case OBJ_POLYGON: vlist = obj_ptr->detail.g->vlist; n = obj_ptr->detail.g->n; if (obj_ptr->userdata == NULL && obj_ptr->detail.g->curved == LT_STRUCT_SPLINE) { psssi = (StretchStructuredSplineInfo*)malloc( sizeof(StretchStructuredSplineInfo)); if (psssi == NULL) FailAllocMessage(); memset(psssi, 0, sizeof(StretchStructuredSplineInfo)); SetIPTInfoForStretchPoly(vsel_ptr->v_index[0], n, vlist, psssi); psssi->orig_abs_x = psssi->new_abs_x = vlist[vsel_ptr->v_index[0]].x; psssi->orig_abs_y = psssi->new_abs_y = vlist[vsel_ptr->v_index[0]].y; obj_ptr->userdata = psssi; if (obj_ptr->ctm != NULL) { psssi->rotated_orig_abs_x = psssi->rotated_new_abs_x = vsel_ptr->x[0]; psssi->rotated_orig_abs_y = psssi->rotated_new_abs_y = vsel_ptr->y[0]; } } if (update_pmvi && vsel_ptr->pmvi == NULL && obj_ptr->detail.g->curved != LT_STRUCT_SPLINE) { vsel_ptr->pmvi = (MoveVertexInfo*)malloc( vsel_ptr->n*sizeof(MoveVertexInfo)); memset(vsel_ptr->pmvi, 0, vsel_ptr->n*sizeof(MoveVertexInfo)); for (i=0; i < vsel_ptr->n; i++) { vsel_ptr->pmvi[i].orig_abs_x = vsel_ptr->pmvi[i].new_abs_x = vlist[vsel_ptr->v_index[i]].x; vsel_ptr->pmvi[i].orig_abs_y = vsel_ptr->pmvi[i].new_abs_y = vlist[vsel_ptr->v_index[i]].y; if (obj_ptr->ctm != NULL) { vsel_ptr->pmvi[i].rotated_orig_abs_x = vsel_ptr->pmvi[i].rotated_new_abs_x = vsel_ptr->x[i]; vsel_ptr->pmvi[i].rotated_orig_abs_y = vsel_ptr->pmvi[i].rotated_new_abs_y = vsel_ptr->y[i]; } } } break; } } void DistrSelObjs() { int i=0, dx=0, dy=0, ltx, lty, rbx, rby, count, w, h; struct SelRec *sel_ptr=NULL, *next_sel=NULL; struct ObjRec *obj_ptr=NULL; struct VSelRec *vsel_ptr=NULL; double x=0.0, y=0.0, h_dist=0.0, v_dist=0.0; if ((topSel==NULL && topVSel==NULL) || (horiAlign==ALIGN_N && vertAlign==ALIGN_N)) { return; } if (numObjLocked != 0) { MsgBox(TgLoadString(STID_CANNOT_DISTRIBUTE_LOCKED_OBJS), TOOL_NAME, INFO_MB); return; } if (curChoice == VERTEXMODE) { int start=0, vertices_count=0; struct DistrVRec *dv_ptr=NULL, *left_dv=NULL, *right_dv=NULL; struct DistrVRec *top_dv=NULL, *bottom_dv=NULL; struct DistrVRec *ptr=NULL, *hori_dv=NULL, *vert_dv=NULL; struct SelRec *tmp_top_sel=NULL, *tmp_bot_sel=NULL, *tmp_sel_ptr=NULL; StretchStructuredSplineInfo *psssi=NULL; if ((vertices_count=CountSelectedVertices()) <= 2) return; HighLightReverse(); dv_ptr = (struct DistrVRec *)malloc( 2*vertices_count*sizeof(struct DistrVRec)); if (dv_ptr == NULL) FailAllocMessage(); start = 1; ptr = dv_ptr; ptr->obj = topVSel->obj; ptr->vsel = topVSel; ptr->index = topVSel->v_index[0]; ptr->vindex = 0; ptr->x = topVSel->x[0]; ptr->y = topVSel->y[0]; ptr->next = ptr->prev = NULL; left_dv = right_dv = ptr; ptr++; ptr->obj = topVSel->obj; ptr->vsel = topVSel; ptr->index = topVSel->v_index[0]; ptr->vindex = 0; ptr->x = topVSel->x[0]; ptr->y = topVSel->y[0]; ptr->next = ptr->prev = NULL; top_dv = bottom_dv = ptr; ptr++; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { sel_ptr->obj->marked = FALSE; sel_ptr->obj->userdata = NULL; } for (vsel_ptr=topVSel; vsel_ptr != NULL; vsel_ptr=vsel_ptr->next) { int obj_type=vsel_ptr->obj->type, last_index=0, n=0; if (obj_type == OBJ_POLYGON) { last_index = vsel_ptr->obj->detail.g->n-1; } obj_ptr = vsel_ptr->obj; n = vsel_ptr->n; for (i=start; i < n; i++) { if (!(obj_type==OBJ_POLYGON && vsel_ptr->v_index[i]==last_index)) { for (hori_dv=left_dv; hori_dv!=NULL; hori_dv=hori_dv->next) { if (hori_dv->x > vsel_ptr->x[i] || (hori_dv->x == vsel_ptr->x[i] && hori_dv->y > vsel_ptr->y[i])) { break; } } ptr->obj = obj_ptr; ptr->vsel = vsel_ptr; ptr->index = vsel_ptr->v_index[i]; ptr->vindex = i; ptr->x = vsel_ptr->x[i]; ptr->y = vsel_ptr->y[i]; ptr->next = hori_dv; if (hori_dv == NULL) { ptr->prev = right_dv; right_dv->next = ptr; right_dv = ptr; } else { ptr->prev = hori_dv->prev; if (hori_dv->prev == NULL) { left_dv = ptr; } else { hori_dv->prev->next = ptr; } hori_dv->prev = ptr; } ptr++; for (vert_dv=top_dv; vert_dv!=NULL; vert_dv=vert_dv->next) { if (vert_dv->y > vsel_ptr->y[i] || (vert_dv->y == vsel_ptr->y[i] && vert_dv->x > vsel_ptr->x[i])) { break; } } ptr->obj = obj_ptr; ptr->vsel = vsel_ptr; ptr->index = vsel_ptr->v_index[i]; ptr->vindex = i; ptr->x = vsel_ptr->x[i]; ptr->y = vsel_ptr->y[i]; ptr->next = vert_dv; if (vert_dv == NULL) { ptr->prev = bottom_dv; bottom_dv->next = ptr; bottom_dv = ptr; } else { ptr->prev = vert_dv->prev; if (vert_dv->prev == NULL) { top_dv = ptr; } else { vert_dv->prev->next = ptr; } vert_dv->prev = ptr; } ptr++; } } start = 0; } if (horiAlign != ALIGN_N) { for (ptr=left_dv; ptr->next!=right_dv; ptr=ptr->next) { obj_ptr = ptr->next->obj; vsel_ptr = ptr->next->vsel; if (!(obj_ptr->type==OBJ_POLYGON && ptr->next->index==obj_ptr->detail.g->n-1)) { obj_ptr->marked = TRUE; SetSSSIForDistr(obj_ptr, vsel_ptr, TRUE); } } } if (vertAlign != ALIGN_N) { for (ptr=top_dv; ptr->next!=bottom_dv; ptr=ptr->next) { obj_ptr = ptr->next->obj; vsel_ptr = ptr->next->vsel; if (!(obj_ptr->type==OBJ_POLYGON && ptr->next->index==obj_ptr->detail.g->n-1)) { obj_ptr->marked = TRUE; SetSSSIForDistr(obj_ptr, vsel_ptr, TRUE); } } } tmp_top_sel = tmp_bot_sel = NULL; count = 0; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; if (obj_ptr->marked) { count++; AddObjIntoSel(obj_ptr, tmp_bot_sel, NULL, &tmp_top_sel, &tmp_bot_sel); } } if (count != 0) { PrepareToRecord(CMD_REPLACE, tmp_top_sel, tmp_bot_sel, count); } if (horiAlign != ALIGN_N) { x = (double)(left_dv->x); h_dist = ((double)(right_dv->x-x))/((double)(vertices_count-1)); for (ptr=left_dv; ptr->next!=right_dv; ptr=ptr->next) { int new_x=0; obj_ptr = ptr->next->obj; vsel_ptr = ptr->next->vsel; if (obj_ptr->type==OBJ_POLYGON && ptr->next->index==obj_ptr->detail.g->n-1) { continue; } obj_ptr->marked = TRUE; new_x = round(x+h_dist); if (obj_ptr->userdata != NULL) { psssi = (StretchStructuredSplineInfo *)obj_ptr->userdata; if (obj_ptr->ctm == NULL) { psssi->new_abs_x = new_x; psssi->abs_dx = new_x - psssi->orig_abs_x; } else { psssi->rotated_new_abs_x = new_x; psssi->rotated_abs_dx = new_x - psssi->rotated_orig_abs_x; } } else { int vindex=ptr->next->vindex; MoveVertexInfo *pmvi=vsel_ptr->pmvi; if (obj_ptr->ctm == NULL) { pmvi[vindex].new_abs_x = new_x; pmvi[vindex].abs_dx = new_x - pmvi[vindex].orig_abs_x; } else { pmvi[vindex].rotated_new_abs_x = new_x; pmvi[vindex].rotated_abs_dx = new_x - pmvi[vindex].rotated_orig_abs_x; } } vsel_ptr->x[ptr->next->vindex] = new_x; x += h_dist; } } if (vertAlign != ALIGN_N) { y = (double)(top_dv->y); v_dist = ((double)(bottom_dv->y-y))/((double)(vertices_count-1)); for (ptr=top_dv; ptr->next!=bottom_dv; ptr=ptr->next) { int new_y=0; obj_ptr = ptr->next->obj; vsel_ptr = ptr->next->vsel; if (obj_ptr->type==OBJ_POLYGON && ptr->next->index==obj_ptr->detail.g->n-1) { continue; } obj_ptr->marked = TRUE; new_y = round(y+v_dist); if (obj_ptr->userdata != NULL) { psssi = (StretchStructuredSplineInfo *)obj_ptr->userdata; if (obj_ptr->ctm == NULL) { psssi->new_abs_y = new_y; psssi->abs_dy = new_y - psssi->orig_abs_y; } else { psssi->rotated_new_abs_y = new_y; psssi->rotated_abs_dy = new_y - psssi->rotated_orig_abs_y; } } else { int vindex=ptr->next->vindex; MoveVertexInfo *pmvi=vsel_ptr->pmvi; if (obj_ptr->ctm == NULL) { pmvi[vindex].new_abs_y = new_y; pmvi[vindex].abs_dy = new_y - pmvi[vindex].orig_abs_y; } else { pmvi[vindex].rotated_new_abs_y = new_y; pmvi[vindex].rotated_abs_dy = new_y - pmvi[vindex].rotated_orig_abs_y; } } vsel_ptr->y[ptr->next->vindex] = new_y; y += v_dist; } } for (vsel_ptr=topVSel; vsel_ptr != NULL; vsel_ptr=vsel_ptr->next) { obj_ptr = vsel_ptr->obj; if (obj_ptr->marked) { IntPoint *vlist=NULL; switch (obj_ptr->type) { case OBJ_POLY: vlist = obj_ptr->detail.p->vlist; break; case OBJ_POLYGON: vlist = obj_ptr->detail.g->vlist; break; } if (obj_ptr->type==OBJ_POLYGON) { struct PolygonRec *polygon_ptr=obj_ptr->detail.g; polygon_ptr->vlist[polygon_ptr->n-1].x = polygon_ptr->vlist[0].x; polygon_ptr->vlist[polygon_ptr->n-1].y = polygon_ptr->vlist[0].y; } if (obj_ptr->userdata != NULL) { StretchStructuredSplineInfo *psssi= (StretchStructuredSplineInfo *)obj_ptr->userdata; if (obj_ptr->ctm == NULL) { FinishMoveVertexForStretchStructSpline(vsel_ptr, psssi->abs_dx, psssi->abs_dy, psssi); } else { FinishMoveVertexForStretchStructSpline(vsel_ptr, psssi->rotated_abs_dx, psssi->rotated_abs_dy, psssi); } free(psssi); obj_ptr->userdata = NULL; } else { MoveVertexInfo *pmvi=vsel_ptr->pmvi; if (obj_ptr->ctm == NULL) { for (i=0; i < vsel_ptr->n; i++) { if (pmvi[i].abs_dx != 0 || pmvi[i].abs_dy != 0) { vlist[vsel_ptr->v_index[i]].x += pmvi[i].abs_dx; vlist[vsel_ptr->v_index[i]].y += pmvi[i].abs_dy; } } } else { for (i=0; i < vsel_ptr->n; i++) { if (pmvi[i].rotated_abs_dx != 0 || pmvi[i].rotated_abs_dy != 0) { int tmp_x=0, tmp_y=0; ReverseTransformPointThroughCTM( pmvi[i].rotated_new_abs_x-obj_ptr->x, pmvi[i].rotated_new_abs_y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); vlist[vsel_ptr->v_index[i]].x = tmp_x + obj_ptr->x; vlist[vsel_ptr->v_index[i]].y = tmp_y + obj_ptr->y; } } } free(pmvi); vsel_ptr->pmvi = NULL; } AdjObjSplineVs(obj_ptr); UpdPolyOrPolygonBBox(obj_ptr); } } if (count != 0) { RecordCmd(CMD_REPLACE, NULL, tmp_top_sel, tmp_bot_sel, count); } for (tmp_sel_ptr=tmp_top_sel; tmp_sel_ptr!=NULL; tmp_sel_ptr=next_sel) { next_sel = tmp_sel_ptr->next; free(tmp_sel_ptr); } free(dv_ptr); if (horiAlign != ALIGN_N) { sprintf(gszMsgBox, TgLoadString(STID_VERTICES_HORI_APART), round(h_dist)); Msg(gszMsgBox); } if (vertAlign != ALIGN_N) { sprintf(gszMsgBox, TgLoadString(STID_VERTICES_VERT_APART), round(v_dist)); Msg(gszMsgBox); } } else { struct SelRec *left_sel=NULL, *right_sel=NULL; struct SelRec *top_sel=NULL, *bottom_sel=NULL; struct SelRec *vert_sel=NULL, *hori_sel=NULL, *new_sel=NULL; struct SubCmdRec *sub_cmd=NULL; struct SelRec *tmp_sel_ptr=NULL; if (topSel==botSel || topSel->next==botSel) return; tmp_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (tmp_sel_ptr == NULL) FailAllocMessage(); tmp_sel_ptr->next = tmp_sel_ptr->prev = NULL; sub_cmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (sub_cmd == NULL) FailAllocMessage(); memset(sub_cmd, 0, sizeof(struct SubCmdRec)); StartCompositeCmd(); HighLightReverse(); left_sel = right_sel = (struct SelRec *)malloc(sizeof(struct SelRec)); top_sel = bottom_sel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (left_sel == NULL || right_sel == NULL || top_sel == NULL || bottom_sel == NULL) { FailAllocMessage(); } left_sel->obj = right_sel->obj = botSel->obj; top_sel->obj = bottom_sel->obj = botSel->obj; left_sel->prev = right_sel->next = NULL; top_sel->prev = bottom_sel->next = NULL; count = 1; w = left_sel->obj->obbox.rbx - left_sel->obj->obbox.ltx; h = left_sel->obj->obbox.rby - left_sel->obj->obbox.lty; for (sel_ptr=botSel->prev; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { count++; obj_ptr = sel_ptr->obj; w += obj_ptr->obbox.rbx - obj_ptr->obbox.ltx; h += obj_ptr->obbox.rby - obj_ptr->obbox.lty; switch (horiAlign) { case ALIGN_N: case ALIGN_L: case ALIGN_S: for (hori_sel=left_sel; hori_sel!=NULL; hori_sel=hori_sel->next) { if (hori_sel->obj->obbox.ltx > obj_ptr->obbox.ltx || (hori_sel->obj->obbox.ltx == obj_ptr->obbox.ltx && hori_sel->obj->obbox.lty > obj_ptr->obbox.lty)) { break; } } break; case ALIGN_C: for (hori_sel=left_sel; hori_sel!=NULL; hori_sel=hori_sel->next) { if (hori_sel->obj->obbox.ltx+hori_sel->obj->obbox.rbx > obj_ptr->obbox.ltx+obj_ptr->obbox.rbx || (hori_sel->obj->obbox.ltx+hori_sel->obj->obbox.rbx == obj_ptr->obbox.ltx+obj_ptr->obbox.rbx && hori_sel->obj->obbox.lty+hori_sel->obj->obbox.rby > obj_ptr->obbox.lty+obj_ptr->obbox.rby)) { break; } } break; case ALIGN_R: for (hori_sel=left_sel; hori_sel!=NULL; hori_sel=hori_sel->next) { if (hori_sel->obj->obbox.rbx > obj_ptr->obbox.rbx || (hori_sel->obj->obbox.rbx == obj_ptr->obbox.rbx && hori_sel->obj->obbox.rby > obj_ptr->obbox.rby)) { break; } } break; } new_sel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (new_sel == NULL) FailAllocMessage(); new_sel->obj = obj_ptr; new_sel->next = hori_sel; if (hori_sel == NULL) { new_sel->prev = right_sel; right_sel->next = new_sel; right_sel = new_sel; } else { new_sel->prev = hori_sel->prev; if (hori_sel->prev == NULL) { left_sel = new_sel; } else { hori_sel->prev->next = new_sel; } hori_sel->prev = new_sel; } switch (vertAlign) { case ALIGN_N: case ALIGN_T: case ALIGN_S: for (vert_sel=top_sel; vert_sel!=NULL; vert_sel=vert_sel->next) { if (vert_sel->obj->obbox.lty > obj_ptr->obbox.lty || (vert_sel->obj->obbox.lty == obj_ptr->obbox.lty && vert_sel->obj->obbox.ltx > obj_ptr->obbox.ltx)) { break; } } break; case ALIGN_M: for (vert_sel=top_sel; vert_sel!=NULL; vert_sel=vert_sel->next) { if (vert_sel->obj->obbox.lty+vert_sel->obj->obbox.rby > obj_ptr->obbox.lty+obj_ptr->obbox.rby || (vert_sel->obj->obbox.lty+vert_sel->obj->obbox.rby == obj_ptr->obbox.lty+obj_ptr->obbox.rby && vert_sel->obj->obbox.ltx+vert_sel->obj->obbox.rbx > obj_ptr->obbox.ltx+obj_ptr->obbox.rbx)) { break; } } break; case ALIGN_B: for (vert_sel=top_sel; vert_sel!=NULL; vert_sel=vert_sel->next) { if (vert_sel->obj->obbox.rby > obj_ptr->obbox.rby || (vert_sel->obj->obbox.rby == obj_ptr->obbox.rby && vert_sel->obj->obbox.rbx > obj_ptr->obbox.rbx)) { break; } } break; } new_sel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (new_sel == NULL) FailAllocMessage(); new_sel->obj = obj_ptr; new_sel->next = vert_sel; if (vert_sel == NULL) { new_sel->prev = bottom_sel; bottom_sel->next = new_sel; bottom_sel = new_sel; } else { new_sel->prev = vert_sel->prev; if (vert_sel->prev == NULL) { top_sel = new_sel; } else { vert_sel->prev->next = new_sel; } vert_sel->prev = new_sel; } } switch (horiAlign) { case ALIGN_N: case ALIGN_L: x = (double)(left_sel->obj->obbox.ltx); h_dist = ((double)(right_sel->obj->obbox.ltx-x))/((double)(count-1)); break; case ALIGN_C: x = (double)(left_sel->obj->obbox.rbx+left_sel->obj->obbox.ltx); h_dist = ((double)(right_sel->obj->obbox.rbx + right_sel->obj->obbox.ltx - x)) / ((double)(count-1)); break; case ALIGN_R: x = (double)(left_sel->obj->obbox.rbx); h_dist = ((double)(right_sel->obj->obbox.rbx-x))/((double)(count-1)); break; case ALIGN_S: x = (double)(left_sel->obj->obbox.rbx); h_dist = ((double)(right_sel->obj->obbox.rbx - left_sel->obj->obbox.ltx - w)) / ((double)(count-1)); break; } switch (vertAlign) { case ALIGN_N: case ALIGN_T: y = (double)(top_sel->obj->obbox.lty); v_dist = ((double)(bottom_sel->obj->obbox.lty-y))/((double)(count-1)); break; case ALIGN_M: y = (double)(top_sel->obj->obbox.rby+top_sel->obj->obbox.lty); v_dist = ((double)(bottom_sel->obj->obbox.rby + bottom_sel->obj->obbox.lty - y)) / ((double)(count-1)); break; case ALIGN_B: y = (double)(top_sel->obj->obbox.rby); v_dist = ((double)(bottom_sel->obj->obbox.rby-y))/((double)(count-1)); break; case ALIGN_S: y = (double)(top_sel->obj->obbox.rby); v_dist = ((double)(bottom_sel->obj->obbox.rby - top_sel->obj->obbox.lty - h)) / ((double)(count-1)); break; } for (sel_ptr=left_sel; sel_ptr->next!=right_sel; sel_ptr=next_sel) { switch (horiAlign) { case ALIGN_N: dx = 0; break; case ALIGN_L: dx = round(x+h_dist-sel_ptr->next->obj->obbox.ltx); break; case ALIGN_C: dx = round((x + h_dist - sel_ptr->next->obj->obbox.rbx - sel_ptr->next->obj->obbox.ltx) / ((double)2.0)); break; case ALIGN_R: dx = round(x+h_dist-sel_ptr->next->obj->obbox.rbx); break; case ALIGN_S: dx = round(x+h_dist-sel_ptr->next->obj->obbox.ltx); break; } if (dx != 0) { sub_cmd->detail.move.dx = dx; sub_cmd->detail.move.dy = 0; tmp_sel_ptr->obj = sel_ptr->next->obj; PrepareToRecord(CMD_MOVE, tmp_sel_ptr, tmp_sel_ptr, 1); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); MoveObj(sel_ptr->next->obj, dx, 0); } x += h_dist; if (horiAlign == ALIGN_S) { x += sel_ptr->next->obj->obbox.rbx - sel_ptr->next->obj->obbox.ltx; } next_sel = sel_ptr->next; free(sel_ptr); } free(sel_ptr); free(right_sel); for (sel_ptr=top_sel; sel_ptr->next!=bottom_sel; sel_ptr=next_sel) { switch (vertAlign) { case ALIGN_N: dy = 0; break; case ALIGN_T: dy = round(y+v_dist-sel_ptr->next->obj->obbox.lty); break; case ALIGN_M: dy = round((y + v_dist - sel_ptr->next->obj->obbox.rby - sel_ptr->next->obj->obbox.lty) / ((double)2.0)); break; case ALIGN_B: dy = round(y+v_dist-sel_ptr->next->obj->obbox.rby); break; case ALIGN_S: dy = round(y+v_dist-sel_ptr->next->obj->obbox.lty); break; } if (dy != 0) { sub_cmd->detail.move.dx = 0; sub_cmd->detail.move.dy = dy; tmp_sel_ptr->obj = sel_ptr->next->obj; PrepareToRecord(CMD_MOVE, tmp_sel_ptr, tmp_sel_ptr, 1); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); MoveObj(sel_ptr->next->obj, 0, dy); } y += v_dist; if (vertAlign == ALIGN_S) { y += sel_ptr->next->obj->obbox.rby - sel_ptr->next->obj->obbox.lty; } next_sel = sel_ptr->next; free(sel_ptr); } free(sel_ptr); free(bottom_sel); EndCompositeCmd(); free(sub_cmd); free(tmp_sel_ptr); switch (horiAlign) { case ALIGN_L: sprintf(gszMsgBox, TgLoadString(STID_LEFT_SIDES_APART), round(h_dist)); Msg(gszMsgBox); break; case ALIGN_C: sprintf(gszMsgBox, TgLoadString(STID_CENTERS_APART), round(h_dist/((double)2.0))); Msg(gszMsgBox); break; case ALIGN_R: sprintf(gszMsgBox, TgLoadString(STID_RIGHT_SIDES_APART), round(h_dist)); Msg(gszMsgBox); break; case ALIGN_S: sprintf(gszMsgBox, TgLoadString(STID_SPACED_APART_HORI), round(h_dist)); Msg(gszMsgBox); break; } switch (vertAlign) { case ALIGN_T: sprintf(gszMsgBox, TgLoadString(STID_TOP_SIDES_APART), round(v_dist)); Msg(gszMsgBox); break; case ALIGN_M: sprintf(gszMsgBox, TgLoadString(STID_MIDDLES_APART), round(v_dist/((double)2.0))); Msg(gszMsgBox); break; case ALIGN_B: sprintf(gszMsgBox, TgLoadString(STID_BOTTOM_SIDES_APART), round(v_dist)); Msg(gszMsgBox); break; case ALIGN_S: sprintf(gszMsgBox, TgLoadString(STID_SPACED_APART_VERT), round(v_dist)); Msg(gszMsgBox); break; } } ltx = selLtX; lty = selLtY; rbx = selRbX, rby = selRbY; UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } void DistributeDirect(alignment) int alignment; { int saved_h_align=horiAlign, saved_v_align=vertAlign; int v_mode=(alignment%MAXALIGNS); int h_mode=((alignment-v_mode)/MAXALIGNS); horiAlign = h_mode; vertAlign = v_mode; DistrSelObjs(); horiAlign = saved_h_align; vertAlign = saved_v_align; } static char *GetDistrDirectMenuStr(i) int i; /* returned string has been translated */ { char *psz=NULL, *msg=NULL; if (curChoice == VERTEXMODE) { int v_mode=(i%MAXALIGNS); int h_mode=((i-v_mode)/MAXALIGNS); if (v_mode == ALIGN_N) { if (h_mode == ALIGN_N) { msg = TgLoadCachedString(CSTID_PARANED_NONE); } else { msg = TgLoadString(STID_DISTR_VERTEX_HORI); } } else { if (h_mode == ALIGN_N) { msg = TgLoadString(STID_DISTR_VERTEX_VERT); } else { msg = TgLoadString(STID_DISTR_VERTEX_VERT_AND_HORI); } } } else { msg = DistrDirectLoadString(i); } psz = UtilStrDup(msg); if (psz == NULL) FailAllocMessage(); return psz; } TgMenu *CreateDistributeDirectMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { int i=0, num_entries=(MAXALIGNS*MAXALIGNS); TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); stMenuInfo.items = (TgMenuItemInfo*)malloc( (num_entries+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (num_entries+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < num_entries; item_info++, i++) { item_info->menu_str = (char*)(Pixmap*)(&distrDirectPixmap[i]); item_info->shortcut_str = NULL; item_info->status_str = GetDistrDirectMenuStr(i); item_info->submenu_info = NULL; item_info->cmdid = CMDID_DISTRIBUTEDIRECT; } stMenuInfo.items[num_entries].cmdid = INVALID; /* the status_str has been translated in GetDistrDirectMenuStr() */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < num_entries; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (num_entries+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, MAXALIGNS); } return menu; } static int AutoJustifiable(obj_ptr) struct ObjRec *obj_ptr; { struct TextRec *text_ptr; int auto_justifiable=TRUE, just; if (obj_ptr->type!=OBJ_TEXT || obj_ptr->detail.t->lines!=1) return FALSE; if (obj_ptr->ctm != NULL) return FALSE; text_ptr = obj_ptr->detail.t; just = text_ptr->minilines.just; if ((horiAlign==ALIGN_L && just==JUST_L) || (horiAlign==ALIGN_C && just==JUST_C) || (horiAlign==ALIGN_R && just==JUST_R)) { auto_justifiable = FALSE; } return auto_justifiable; } static void AutoJustify(obj_ptr) struct ObjRec *obj_ptr; { struct TextRec *text_ptr; int new_ltx, new_lty, dx, dy, ltx, lty; text_ptr = obj_ptr->detail.t; ltx = obj_ptr->obbox.ltx; lty = obj_ptr->obbox.lty; switch (horiAlign) { case ALIGN_L: text_ptr->minilines.just = JUST_L; break; case ALIGN_C: text_ptr->minilines.just = JUST_C; break; case ALIGN_R: text_ptr->minilines.just = JUST_R; break; } UpdTextBBox(obj_ptr); dx = dy = 0; new_ltx = obj_ptr->obbox.ltx; new_lty = obj_ptr->obbox.lty; dx = ltx-new_ltx; if (text_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, text_ptr->cached_bitmap); } text_ptr->cached_zoom = 0; text_ptr->cached_bitmap = None; MoveObj(obj_ptr, dx, dy); } void AlignSelObjs() { register int x=0, y=0, i; struct SelRec *sel_ptr=NULL; struct ObjRec *obj_ptr=NULL; struct VSelRec *vsel_ptr=NULL; int pivot_x=0, pivot_y=0, auto_justifiable=FALSE; int dx=0, dy=0, ltx=0, lty=0, rbx=0, rby=0; if (topSel == NULL && topVSel == NULL) return; if (curChoice == VERTEXMODE) { int changed=FALSE, n=0, first_time=TRUE, start; IntPoint *vlist=NULL; if (topVSel!=NULL && (topVSel->next!=NULL || topVSel->n>=3 || (topVSel->n==2 && !(topVSel->obj->type==OBJ_POLYGON && topVSel->v_index[0]==0))) && horiAlign!=ALIGN_N && horiAlign!=ALIGN_S && vertAlign!=ALIGN_N && vertAlign!=ALIGN_S) { if (MsgBox(TgLoadString(STID_MOVE_ALL_VERTICES_YNC), TOOL_NAME, YNC_MB) != MB_ID_YES) { return; } } StartCompositeCmd(); HighLightReverse(); for (vsel_ptr = topVSel; vsel_ptr != NULL; vsel_ptr = vsel_ptr->next) { if (first_time) { first_time = FALSE; ltx = vsel_ptr->x[0]; lty = vsel_ptr->y[0]; rbx = vsel_ptr->x[0]; rby = vsel_ptr->y[0]; start = 1; } else { start = 0; } for (i = start; i < vsel_ptr->n; i++) { if (vsel_ptr->x[i] < ltx) ltx = vsel_ptr->x[i]; if (vsel_ptr->y[i] < lty) lty = vsel_ptr->y[i]; if (vsel_ptr->x[i] > rbx) rbx = vsel_ptr->x[i]; if (vsel_ptr->y[i] > rby) rby = vsel_ptr->y[i]; } } switch (horiAlign) { case ALIGN_L: pivot_x = ltx; break; case ALIGN_C: pivot_x = (ltx + rbx) / 2; break; case ALIGN_R: pivot_x = rbx; break; } switch (vertAlign) { case ALIGN_T: pivot_y = lty; break; case ALIGN_M: pivot_y = (lty + rby) / 2; break; case ALIGN_B: pivot_y = rby; break; } for (vsel_ptr = topVSel; vsel_ptr != NULL; vsel_ptr = vsel_ptr->next) { StretchStructuredSplineInfo sssi; int curved=(-1), ssn=(-1); IntPoint *ssvlist=NULL; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; memset(&sssi, 0, sizeof(StretchStructuredSplineInfo)); obj_ptr = vsel_ptr->obj; switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; curved = poly_ptr->curved; n = poly_ptr->n; vlist = poly_ptr->vlist; if (curved == LT_STRUCT_SPLINE) { ssn = poly_ptr->ssn; ssvlist = poly_ptr->ssvlist; SetIPTInfoForStretchPoly(vsel_ptr->v_index[0], n, vlist, &sssi); } break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; curved = polygon_ptr->curved; n = polygon_ptr->n; vlist = polygon_ptr->vlist; if (curved == LT_STRUCT_SPLINE) { ssn = polygon_ptr->ssn; ssvlist = polygon_ptr->ssvlist; SetIPTInfoForStretchPolygon(vsel_ptr->v_index[0], n, vlist, &sssi); } break; } PrepareToReplaceAnObj(obj_ptr); for (i=0; i < vsel_ptr->n; i++) { int abs_dx=0, abs_dy=0; if (horiAlign!=ALIGN_N && horiAlign!=ALIGN_S && vsel_ptr->x[i]!=pivot_x) { changed = TRUE; abs_dx = pivot_x - vsel_ptr->x[i]; } if (vertAlign!=ALIGN_N && vertAlign!=ALIGN_S && vsel_ptr->y[i]!=pivot_y) { changed = TRUE; abs_dy = pivot_y - vsel_ptr->y[i]; } if (changed) { if (obj_ptr->ctm == NULL) { vsel_ptr->x[i] = pivot_x; vsel_ptr->y[i] = pivot_y; if (curved == LT_STRUCT_SPLINE) { /* * don't do anything here, will be handled in * FinishMoveVertexForStretchStructSpline(); */ } else { vlist[vsel_ptr->v_index[i]].x = pivot_x; vlist[vsel_ptr->v_index[i]].y = pivot_y; } } else { int tmp_x=0, tmp_y=0, tmp_x2=0, tmp_y2=0; ReverseTransformPointThroughCTM( pivot_x-obj_ptr->x, pivot_y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); if (curved == LT_STRUCT_SPLINE) { /* * don't do anything here, will be handled in * FinishMoveVertexForStretchStructSpline(); */ } else { dx = tmp_x + obj_ptr->x - vlist[vsel_ptr->v_index[i]].x; dy = tmp_y + obj_ptr->y - vlist[vsel_ptr->v_index[i]].y; vlist[vsel_ptr->v_index[i]].x = tmp_x + obj_ptr->x; vlist[vsel_ptr->v_index[i]].y = tmp_y + obj_ptr->y; } TransformPointThroughCTM(tmp_x, tmp_y, obj_ptr->ctm, &tmp_x2, &tmp_y2); vsel_ptr->x[i] = tmp_x2 + obj_ptr->x; vsel_ptr->y[i] = tmp_y2 + obj_ptr->y; } } if (curved == LT_STRUCT_SPLINE) { FinishMoveVertexForStretchStructSpline(vsel_ptr, abs_dx, abs_dy, &sssi); } } if (changed) { AdjObjSplineVs(obj_ptr); UpdNonIntSplinePolyBBox(obj_ptr, n, vlist); RecordReplaceAnObj(obj_ptr); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); } else { struct SubCmdRec *sub_cmd=NULL; struct SelRec *tmp_sel_ptr=NULL; struct ObjRec *locked_obj=NULL; char *psz=NULL; if (numObjLocked > 1) { MsgBox(TgLoadString(STID_CANNOT_ALIGN_OBJS_TOO_MANY), TOOL_NAME, INFO_MB); return; } else if (numObjLocked == 1) { for (sel_ptr=topSel; sel_ptr!=NULL; sel_ptr=sel_ptr->next) { if (sel_ptr->obj->locked) { locked_obj = sel_ptr->obj; break; } } } tmp_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (tmp_sel_ptr == NULL) FailAllocMessage(); tmp_sel_ptr->next = tmp_sel_ptr->prev = NULL; sub_cmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (sub_cmd == NULL) FailAllocMessage(); memset(sub_cmd, 0, sizeof(struct SubCmdRec)); StartCompositeCmd(); HighLightReverse(); switch (horiAlign) { case ALIGN_L: pivot_x = (locked_obj==NULL) ? selObjLtX : locked_obj->obbox.ltx; break; case ALIGN_C: pivot_x = (locked_obj==NULL) ? ((selObjLtX+selObjRbX)>>1) : ((locked_obj->obbox.ltx+locked_obj->obbox.rbx)>>1); break; case ALIGN_R: pivot_x = (locked_obj==NULL) ? selObjRbX : locked_obj->obbox.rbx; break; } switch (vertAlign) { case ALIGN_T: pivot_y = (locked_obj==NULL) ? selObjLtY : locked_obj->obbox.lty; break; case ALIGN_M: pivot_y = (locked_obj==NULL) ? ((selObjLtY+selObjRbY)>>1) : ((locked_obj->obbox.lty+locked_obj->obbox.rby)>>1); break; case ALIGN_B: pivot_y = (locked_obj==NULL) ? selObjRbY : locked_obj->obbox.rby; break; } for (sel_ptr = topSel; sel_ptr != NULL; sel_ptr = sel_ptr->next) { obj_ptr = sel_ptr->obj; if (obj_ptr->locked) continue; if ((auto_justifiable = AutoJustifiable(obj_ptr))) { PrepareToReplaceAnObj(obj_ptr); AutoJustify(obj_ptr); } switch (horiAlign) { case ALIGN_L: x = obj_ptr->obbox.ltx; break; case ALIGN_C: x = (obj_ptr->obbox.ltx+obj_ptr->obbox.rbx)/2; break; case ALIGN_R: x = obj_ptr->obbox.rbx; break; } switch (vertAlign) { case ALIGN_T: y = obj_ptr->obbox.lty; break; case ALIGN_M: y = (obj_ptr->obbox.lty+obj_ptr->obbox.rby)/2; break; case ALIGN_B: y = obj_ptr->obbox.rby; break; } if (horiAlign==ALIGN_N || horiAlign==ALIGN_S) x = pivot_x; if (vertAlign==ALIGN_N || vertAlign==ALIGN_S) y = pivot_y; dx = pivot_x - x; dy = pivot_y - y; if (dx != 0 || dy != 0) { if (auto_justifiable) { MoveObj(obj_ptr, dx, dy); RecordReplaceAnObj(obj_ptr); } else { sub_cmd->detail.move.dx = dx; sub_cmd->detail.move.dy = dy; tmp_sel_ptr->obj = obj_ptr; PrepareToRecord(CMD_MOVE, tmp_sel_ptr, tmp_sel_ptr, 1); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); MoveObj(obj_ptr, dx, dy); } } else if (auto_justifiable) { RecordReplaceAnObj(obj_ptr); } } EndCompositeCmd(); free(sub_cmd); free(tmp_sel_ptr); psz = AlignedLoadString(horiAlign, vertAlign); if (psz != NULL) Msg(psz); } ltx = selLtX; lty = selLtY; rbx = selRbX, rby = selRbY; UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } void AlignSelToPage() { int i=0; struct SelRec *sel_ptr=NULL; struct ObjRec *obj_ptr=NULL; struct VSelRec *vsel_ptr=NULL; int pivot_x=0, pivot_y=0, dx=0, dy=0, ltx=0, lty=0, rbx=0, rby=0; if (topSel == NULL && topVSel == NULL) return; if (curChoice == VERTEXMODE) { int changed=FALSE, n=0; IntPoint *vlist=NULL; if (topVSel!=NULL && (topVSel->next!=NULL || topVSel->n>=3 || (topVSel->n==2 && !(topVSel->obj->type==OBJ_POLYGON && topVSel->v_index[0]==0))) && horiAlign!=ALIGN_N && horiAlign!=ALIGN_S && vertAlign!=ALIGN_N && vertAlign!=ALIGN_S) { if (MsgBox(TgLoadString(STID_MOVE_ALL_VERTICES_YNC), TOOL_NAME, YNC_MB) != MB_ID_YES) { return; } } for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { sel_ptr->obj->userdata = NULL; } StartCompositeCmd(); HighLightReverse(); switch (horiAlign) { case ALIGN_L: pivot_x = 0; break; case ALIGN_C: pivot_x = paperWidth / 2; break; case ALIGN_R: pivot_x = paperWidth; break; } switch (vertAlign) { case ALIGN_T: pivot_y = 0; break; case ALIGN_M: pivot_y = paperHeight / 2; break; case ALIGN_B: pivot_y = paperHeight; break; } for (vsel_ptr=topVSel; vsel_ptr != NULL; vsel_ptr=vsel_ptr->next) { obj_ptr = vsel_ptr->obj; SetSSSIForDistr(obj_ptr, vsel_ptr, FALSE); switch (obj_ptr->type) { case OBJ_POLY: n = obj_ptr->detail.p->n; vlist = obj_ptr->detail.p->vlist; break; case OBJ_POLYGON: n = obj_ptr->detail.g->n; vlist = obj_ptr->detail.g->vlist; break; } PrepareToReplaceAnObj(obj_ptr); for (i = 0; i < vsel_ptr->n; i++) { if (horiAlign!=ALIGN_N && horiAlign!=ALIGN_S && vsel_ptr->x[i]!=pivot_x) { changed = TRUE; if (obj_ptr->userdata != NULL) { StretchStructuredSplineInfo *psssi= (StretchStructuredSplineInfo *)obj_ptr->userdata; if (obj_ptr->ctm == NULL) { psssi->new_abs_x = pivot_x; psssi->abs_dx = pivot_x - psssi->orig_abs_x; } else { psssi->rotated_new_abs_x = pivot_x; psssi->rotated_abs_dx = pivot_x - psssi->rotated_orig_abs_x; } } else { vlist[vsel_ptr->v_index[i]].x = pivot_x; } vsel_ptr->x[i] = pivot_x; } if (vertAlign!=ALIGN_N && vertAlign!=ALIGN_S && vsel_ptr->y[i]!=pivot_y) { changed = TRUE; if (obj_ptr->userdata != NULL) { StretchStructuredSplineInfo *psssi= (StretchStructuredSplineInfo *)obj_ptr->userdata; if (obj_ptr->ctm == NULL) { psssi->new_abs_y = pivot_y; psssi->abs_dy = pivot_y - psssi->orig_abs_y; } else { psssi->rotated_new_abs_y = pivot_y; psssi->rotated_abs_dy = pivot_y - psssi->rotated_orig_abs_y; } } else { vlist[vsel_ptr->v_index[i]].y = pivot_y; } vsel_ptr->y[i] = pivot_y; } if (obj_ptr->userdata != NULL) { StretchStructuredSplineInfo *psssi= (StretchStructuredSplineInfo *)obj_ptr->userdata; if (changed) { if (obj_ptr->ctm == NULL) { FinishMoveVertexForStretchStructSpline(vsel_ptr, psssi->abs_dx, psssi->abs_dy, psssi); } else { FinishMoveVertexForStretchStructSpline(vsel_ptr, psssi->rotated_abs_dx, psssi->rotated_abs_dy, psssi); } } free(psssi); obj_ptr->userdata = NULL; } } if (changed) { AdjObjSplineVs(obj_ptr); UpdNonIntSplinePolyBBox(obj_ptr, n, vlist); RecordReplaceAnObj(obj_ptr); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); } else { HighLightReverse(); dx = dy = 0; switch (horiAlign) { case ALIGN_L: dx = 0 - selLtX; break; case ALIGN_C: dx = (paperWidth>>1) - ((selRbX+selLtX)>>1); break; case ALIGN_R: dx = paperWidth - selRbX; break; } switch (vertAlign) { case ALIGN_T: dy = 0 - selLtY; break; case ALIGN_M: dy = (paperHeight>>1) - ((selRbY+selLtY)>>1); break; case ALIGN_B: dy = paperHeight - selRbY; break; } if (dx != 0 || dy != 0) { struct SubCmdRec *sub_cmd=NULL; sub_cmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (sub_cmd == NULL) FailAllocMessage(); memset(sub_cmd, 0, sizeof(struct SubCmdRec)); sub_cmd->detail.move.dx = dx; sub_cmd->detail.move.dy = dy; PrepareToRecord(CMD_MOVE, topSel, botSel, numObjSelected); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); for (sel_ptr = topSel; sel_ptr != NULL; sel_ptr = sel_ptr->next) { if (!sel_ptr->obj->locked) { MoveObj(sel_ptr->obj, dx, dy); } } free(sub_cmd); } } ltx = selLtX; lty = selLtY; rbx = selRbX, rby = selRbY; UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } void AlignSelToGrid() { int x=0, y=0, i; struct ObjRec *obj_ptr=NULL; struct SelRec *sel_ptr=NULL; struct VSelRec *vsel_ptr=NULL; int grid_x, grid_y, dx, dy, ltx, lty, rbx, rby, auto_justifiable; int saved_draw_orig_x=0, saved_draw_orig_y=0; if (topSel == NULL && topVSel == NULL) return; StartCompositeCmd(); HighLightReverse(); if (curChoice == VERTEXMODE) { for (vsel_ptr = topVSel; vsel_ptr != NULL; vsel_ptr = vsel_ptr->next) { int changed=FALSE, n=0, ssn=(-1), curved=(-1); IntPoint *vlist=NULL, *ssvlist=NULL; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; StretchStructuredSplineInfo sssi; memset(&sssi, 0, sizeof(StretchStructuredSplineInfo)); obj_ptr = vsel_ptr->obj; switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; curved = poly_ptr->curved; n = poly_ptr->n; vlist = poly_ptr->vlist; if (curved == LT_STRUCT_SPLINE) { ssn = poly_ptr->ssn; ssvlist = poly_ptr->ssvlist; SetIPTInfoForStretchPoly(vsel_ptr->v_index[0], n, vlist, &sssi); } break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; curved = polygon_ptr->curved; n = polygon_ptr->n; vlist = polygon_ptr->vlist; if (curved == LT_STRUCT_SPLINE) { ssn = polygon_ptr->ssn; ssvlist = polygon_ptr->ssvlist; SetIPTInfoForStretchPolygon(vsel_ptr->v_index[0], n, vlist, &sssi); } break; } PrepareToReplaceAnObj(obj_ptr); saved_draw_orig_x = drawOrigX; saved_draw_orig_y = drawOrigY; drawOrigX = drawOrigY = 0; for (i = 0; i < vsel_ptr->n; i++) { if (horiAlign!=ALIGN_N && horiAlign!=ALIGN_S) x = vsel_ptr->x[i]; if (vertAlign!=ALIGN_N && vertAlign!=ALIGN_S) y = vsel_ptr->y[i]; if (zoomedIn) { GridXY(ZOOMED_SIZE(x), ZOOMED_SIZE(y), &grid_x, &grid_y); if (horiAlign==ALIGN_N || horiAlign==ALIGN_S) { x = ABS_SIZE(grid_x); } if (vertAlign==ALIGN_N || vertAlign==ALIGN_S) { y = ABS_SIZE(grid_y); } dx = ABS_SIZE(grid_x) - x; dy = ABS_SIZE(grid_y) - y; } else { GridXY(ZOOMED_SIZE(x), ZOOMED_SIZE(y), &grid_x, &grid_y); if (horiAlign==ALIGN_N || horiAlign==ALIGN_S) x = grid_x; if (vertAlign==ALIGN_N || vertAlign==ALIGN_S) y = grid_y; dx = ABS_SIZE(grid_x) - x; dy = ABS_SIZE(grid_y) - y; } if (dx != 0 || dy != 0) { changed = TRUE; if (ssvlist != NULL) { /* LT_STRUCT_SPLINE */ if (obj_ptr->ctm == NULL) { vsel_ptr->x[i] += dx; vsel_ptr->y[i] += dy; } else { int tmp_x=0, tmp_y=0, tmp_x2=0, tmp_y2=0; /* * looks like of silly here, but it's to fix round-off * errors */ ReverseTransformPointThroughCTM( vsel_ptr->x[i]+dx-obj_ptr->x, vsel_ptr->y[i]+dy-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); TransformPointThroughCTM(tmp_x, tmp_y, obj_ptr->ctm, &tmp_x2, &tmp_y2); vsel_ptr->x[i] = tmp_x2 + obj_ptr->x; vsel_ptr->y[i] = tmp_y2 + obj_ptr->y; } FinishMoveVertexForStretchStructSpline(vsel_ptr, dx, dy, &sssi); } else { if (obj_ptr->ctm == NULL) { vlist[vsel_ptr->v_index[i]].x += dx; vlist[vsel_ptr->v_index[i]].y += dy; vsel_ptr->x[i] += dx; vsel_ptr->y[i] += dy; } else { int tmp_x=0, tmp_y=0, tmp_x2=0, tmp_y2=0; ReverseTransformPointThroughCTM( vsel_ptr->x[i]+dx-obj_ptr->x, vsel_ptr->y[i]+dy-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); vlist[vsel_ptr->v_index[i]].x = tmp_x+obj_ptr->x; vlist[vsel_ptr->v_index[i]].y = tmp_y+obj_ptr->y; TransformPointThroughCTM(tmp_x, tmp_y, obj_ptr->ctm, &tmp_x2, &tmp_y2); vsel_ptr->x[i] = tmp_x2 + obj_ptr->x; vsel_ptr->y[i] = tmp_y2 + obj_ptr->y; } } } } drawOrigX = saved_draw_orig_x; drawOrigY = saved_draw_orig_y; if (changed) { AdjObjSplineVs(obj_ptr); UpdNonIntSplinePolyBBox(obj_ptr, n, vlist); RecordReplaceAnObj(obj_ptr); } else { AbortPrepareCmd(CMD_REPLACE); } } } else { struct SubCmdRec *sub_cmd=NULL; struct SelRec *tmp_sel_ptr=NULL; tmp_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (tmp_sel_ptr == NULL) FailAllocMessage(); tmp_sel_ptr->next = tmp_sel_ptr->prev = NULL; sub_cmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (sub_cmd == NULL) FailAllocMessage(); memset(sub_cmd, 0, sizeof(struct SubCmdRec)); for (sel_ptr = topSel; sel_ptr != NULL; sel_ptr = sel_ptr->next) { obj_ptr = sel_ptr->obj; if (obj_ptr->locked) continue; if ((auto_justifiable=AutoJustifiable(obj_ptr))) { PrepareToReplaceAnObj(obj_ptr); AutoJustify(obj_ptr); } switch (horiAlign) { case ALIGN_L: x = obj_ptr->obbox.ltx; break; case ALIGN_C: x = (obj_ptr->obbox.ltx+obj_ptr->obbox.rbx)/2; break; case ALIGN_R: x = obj_ptr->obbox.rbx; break; } switch (vertAlign) { case ALIGN_T: y = obj_ptr->obbox.lty; break; case ALIGN_M: y = (obj_ptr->obbox.lty+obj_ptr->obbox.rby)/2; break; case ALIGN_B: y = obj_ptr->obbox.rby; break; } saved_draw_orig_x = drawOrigX; saved_draw_orig_y = drawOrigY; drawOrigX = drawOrigY = 0; if (zoomedIn) { GridXY(ZOOMED_SIZE(x), ZOOMED_SIZE(y), &grid_x, &grid_y); if (horiAlign==ALIGN_N || horiAlign==ALIGN_S) x = ABS_SIZE(grid_x); if (vertAlign==ALIGN_N || vertAlign==ALIGN_S) y = ABS_SIZE(grid_y); dx = ABS_SIZE(grid_x) - x; dy = ABS_SIZE(grid_y) - y; } else { GridXY(ZOOMED_SIZE(x), ZOOMED_SIZE(y), &grid_x, &grid_y); if (horiAlign==ALIGN_N || horiAlign==ALIGN_S) x = grid_x; if (vertAlign==ALIGN_N || vertAlign==ALIGN_S) y = grid_y; dx = ABS_SIZE(grid_x) - x; dy = ABS_SIZE(grid_y) - y; } drawOrigX = saved_draw_orig_x; drawOrigY = saved_draw_orig_y; if (dx != 0 || dy != 0) { if (auto_justifiable) { MoveObj(obj_ptr, dx, dy); RecordReplaceAnObj(obj_ptr); } else { sub_cmd->detail.move.dx = dx; sub_cmd->detail.move.dy = dy; tmp_sel_ptr->obj = obj_ptr; PrepareToRecord(CMD_MOVE, tmp_sel_ptr, tmp_sel_ptr, 1); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); MoveObj(obj_ptr, dx, dy); } } else if (auto_justifiable) { RecordReplaceAnObj(obj_ptr); } } free(sub_cmd); free(tmp_sel_ptr); } EndCompositeCmd(); ltx = selLtX; lty = selLtY; rbx = selRbX, rby = selRbY; UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } void HoriAlignSubMenu(index) int index; { char *psz=NULL; horiAlign = index; psz = HoriAlignLoadString(horiAlign); if (psz != NULL) Msg(psz); ShowHoriAlign(); UpdatePinnedMenu(MENU_HORIALIGN); } void RefreshHoriAlignMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == horiAlign); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateHoriAlignMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, MAXALIGNS); menu_item = (&menu->menuitems[horiAlign]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshHoriAlignMenu); } return menu; } int HoriAlignMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(horiAlignMenuInfo.create_proc)(NULL, X, Y, &horiAlignMenuInfo, INVALID); activeMenu = MENU_HORIALIGN; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } void VertAlignSubMenu(index) int index; { char *psz=NULL; vertAlign = index; psz = VertAlignLoadString(vertAlign); if (psz != NULL) Msg(psz); ShowVertAlign(); UpdatePinnedMenu(MENU_VERTALIGN); } void RefreshVertAlignMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == vertAlign); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateVertAlignMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, MAXALIGNS); menu_item = (&menu->menuitems[vertAlign]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshVertAlignMenu); } return menu; } int VertAlignMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(vertAlignMenuInfo.create_proc)(NULL, X, Y, &vertAlignMenuInfo, INVALID); activeMenu = MENU_VERTALIGN; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } void AlignDirect(alignment) int alignment; { int saved_h_align=horiAlign, saved_v_align=vertAlign; int v_align=(alignment%(MAXALIGNS-1)); int h_align=((alignment-v_align)/(MAXALIGNS-1)); horiAlign = h_align; vertAlign = v_align; switch (alignDirectType) { case ALIGN_OBJS_DIRECT: AlignSelObjs(); break; case ALIGN_TO_GRID_DIRECT: AlignSelToGrid(); break; case ALIGN_TO_PAGE_DIRECT: AlignSelToPage(); break; } horiAlign = saved_h_align; vertAlign = saved_v_align; } static char *GetAlignDirectMenuStr(i) int i; /* returned string has been translated */ { char *psz=NULL, *msg=NULL; if (curChoice == VERTEXMODE) { if (alignDirectType == ALIGN_TO_PAGE_DIRECT) { if (i == 0) { msg = TgLoadCachedString(CSTID_PARANED_NONE); } else { msg = AlignVerticesDirectToPageLoadString(i); } } else { int v_align=(i%(MAXALIGNS-1)); int h_align=((i-v_align)/(MAXALIGNS-1)); if (v_align == ALIGN_N) { if (h_align == ALIGN_N) { msg = TgLoadCachedString(CSTID_PARANED_NONE); } else { msg = (alignDirectType==ALIGN_TO_GRID_DIRECT ? TgLoadString(STID_ALIGN_VERTICES_HORI_TO_GRID) : TgLoadString(STID_ALIGN_VERTICES_VERT)); } } else { if (h_align == ALIGN_N) { msg = (alignDirectType==ALIGN_TO_GRID_DIRECT ? TgLoadString(STID_ALIGN_VERTICES_VERT_TO_GRID) : TgLoadString(STID_ALIGN_VERTICES_HORI)); } else { msg = (alignDirectType==ALIGN_TO_GRID_DIRECT ? TgLoadString(STID_ALIGN_VERTICES_TO_GRID) : TgLoadString(STID_ALIGN_VERTICES)); } } } } else { if (alignDirectType == ALIGN_TO_PAGE_DIRECT) { if (i == 0) { msg = TgLoadCachedString(CSTID_PARANED_NONE); } else { msg = AlignDirectToPageLoadString(i); } } else { if (i == 0) { msg = TgLoadCachedString(CSTID_PARANED_NONE); } else if (alignDirectType == ALIGN_TO_GRID_DIRECT) { msg = AlignDirectToGridLoadString(i); } else { msg = AlignDirectLoadString(i); } } } psz = UtilStrDup(msg); if (psz == NULL) FailAllocMessage(); return psz; } static TgMenu *CreateAlignDirectMenu(parent_menu, x, y, menu_info) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; { int i=0, num_entries=((MAXALIGNS-1)*(MAXALIGNS-1)); TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); stMenuInfo.items = (TgMenuItemInfo*)malloc( (num_entries+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (num_entries+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < num_entries; item_info++, i++) { item_info->menu_str = (char*)(Pixmap*)(&alignDirectPixmap[i]); item_info->shortcut_str = NULL; item_info->status_str = GetAlignDirectMenuStr(i); item_info->submenu_info = NULL; item_info->cmdid = CMDID_ALIGNDIRECT; } stMenuInfo.items[num_entries].cmdid = INVALID; /* the status_str has been translated in GetAlignDirectMenuStr() */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < num_entries; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (num_entries+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, (MAXALIGNS-1)); } return menu; } TgMenu *CreateAlignObjsDirectMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { alignDirectType = ALIGN_OBJS_DIRECT; return CreateAlignDirectMenu(parent_menu, x, y, menu_info); } TgMenu *CreateAlignToGridDirectMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { alignDirectType = ALIGN_TO_GRID_DIRECT; return CreateAlignDirectMenu(parent_menu, x, y, menu_info); } TgMenu *CreateAlignToPageDirectMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { alignDirectType = ALIGN_TO_PAGE_DIRECT; return CreateAlignDirectMenu(parent_menu, x, y, menu_info); } void CenterAnEndPoint() { struct ObjRec *other_obj=NULL, *poly_obj=NULL; IntPoint *v; int cx, cy, x1, y1, xn, yn, d1, dn, n=0, index, x, y, tmp_x, tmp_y; if (curChoice != NOTHING) return; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (numObjSelected != 2 || (!((topSel->obj->type == OBJ_POLY && botSel->obj->type != OBJ_POLY) || (topSel->obj->type != OBJ_POLY && botSel->obj->type == OBJ_POLY)))) { MsgBox(TgLoadString(STID_SELECT_ONE_POLY_ONE_NON_POLY), TOOL_NAME, INFO_MB); return; } if (topSel->obj->type == OBJ_POLY) { poly_obj = topSel->obj; other_obj = botSel->obj; } else { poly_obj = botSel->obj; other_obj = topSel->obj; } if (poly_obj->locked) { MsgBox(TgLoadString(STID_CANNOT_MOVE_A_VERTEX_LOCKED), TOOL_NAME, INFO_MB); return; } cx = (other_obj->obbox.ltx+other_obj->obbox.rbx)>>1; cy = (other_obj->obbox.lty+other_obj->obbox.rby)>>1; n = poly_obj->detail.p->n; v = poly_obj->detail.p->vlist; if (poly_obj->ctm == NULL) { x1 = v[0].x; y1 = v[0].y; xn = v[n-1].x; yn = v[n-1].y; } else { TransformPointThroughCTM(v[0].x-poly_obj->x, v[0].y-poly_obj->y, poly_obj->ctm, &tmp_x, &tmp_y); x1 = tmp_x+poly_obj->x; y1 = tmp_y+poly_obj->y; TransformPointThroughCTM(v[n-1].x-poly_obj->x, v[n-1].y-poly_obj->y, poly_obj->ctm, &tmp_x, &tmp_y); xn = tmp_x+poly_obj->x; yn = tmp_y+poly_obj->y; } d1 = (x1-cx)*(x1-cx)+(y1-cy)*(y1-cy); dn = (xn-cx)*(xn-cx)+(yn-cy)*(yn-cy); if (d1 <= dn) { index = 0; x = x1; y = y1; } else { index = n-1; x = xn; y = yn; } if (cx != x || cy != y) { int ltx=0, lty=0, rbx=0, rby=0; HighLightReverse(); PrepareToReplaceAnObj(poly_obj); if (poly_obj->ctm == NULL) { v[index].x = cx; v[index].y = cy; } else { ReverseTransformPointThroughCTM(cx-poly_obj->x, cy-poly_obj->y, poly_obj->ctm, &tmp_x, &tmp_y); v[index].x = tmp_x+poly_obj->x; v[index].y = tmp_y+poly_obj->y; } AdjObjSplineVs(poly_obj); switch (poly_obj->detail.p->curved) { case LT_STRAIGHT: case LT_SPLINE: case LT_STRUCT_SPLINE: UpdPolyBBox(poly_obj, n, v); break; case LT_INTSPLINE: UpdPolyBBox(poly_obj, poly_obj->detail.p->intn, poly_obj->detail.p->intvlist); break; } RecordReplaceAnObj(poly_obj); ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } } tgif-QPL-4.2.5/strtbl.c0000644000076400007640000063463711602233313014466 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/strtbl.c,v 1.135 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_STRTBL_C_ #include "tgifdefs.h" #include "choice.e" #include "drawing.e" #include "msg.e" #include "poly.e" #include "strtbl.e" #include "special.e" #include "text.e" #include "util.e" static char *gaszCachedStrTable[MAXCACHEDSTIDS]; static char *gaszCachedEnglishStrTable[] = { /* CSTID_OK */ N_("Ok"), /* CSTID_CANCEL */ N_("Cancel"), /* CSTID_PARANED_NONE */ N_("(none)"), /* CSTID_SET_FONT_TO */ N_("Set font to '%s'"), /* CSTID_NO_OBJ_SELECTED */ N_("No object selected."), /* CSTID_SPECIFY_ARC_END */ N_("Please specify the end of an arc."), /* CSTID_SPECIFY_ARC_START */ N_("Please specify the start of an arc."), /* CSTID_SPECIFY_ARC_THIRD */ N_("Please specify a 3rd point on the arc."), /* CSTID_SET_ARC_END */ N_("Set end of arc"), /* CSTID_SET_ARC_START */ N_("Set start of arc"), /* CSTID_SET_ARC_THIRD */ N_("Set 3rd point on arc"), /* CSTID_SPECIFY_ARC_END_CW */ N_("Please specify the end of the arc (clockwise)."), /* CSTID_SPECIFY_ARC_END_CCW */ N_("Please specify the end of the arc (counter-clockwise)."), /* CSTID_CANCEL_NOT_AVAIL */ N_("CANCEL is not a valid option."), /* CSTID_DLG_DEF_CONTINUE */ N_("( or to continue )"), /* CSTID_DLG_ACCEPT_CANCEL */ N_("( : accept, : cancel )"), /* CSTID_MALFORMED_INPUT_STR */ N_("Malformed input '%s'."), /* CSTID_CACHING_TEXT_BMP */ N_("Caching text bitmap..."), /* CSTID_PROGRESS_PERCENT */ N_("Progress: %1d%%"), /* CSTID_FINISHED_CACHEING_TEXT_BMP */ N_("Finishing caching text bitmap..."), /* CSTID_BAD_BOX_BBOX_ADJUSTED */ N_("Bad box bounding box. Adjusted."), /* CSTID_MAIN_MENU */ N_("Main Menu"), /* CSTID_MODE_MENU */ N_("Mode Menu"), /* CSTID_ROTATE_DEGREES_CW */ N_("Rotate %s degrees clock-wise"), /* CSTID_ROTATE_DEGREES_CCW */ N_("Rotate %s degrees counter-clock-wise"), /* CSTID_PRINT_MODE */ N_("%s print mode"), /* CSTID_EXPORT_MODE */ N_("%s export mode"), /* CSTID_PRINT_EXPORT_MENU */ N_("Print/ExportFormat Menu"), /* CSTID_FLUSH_UNDO_PERCENT */ N_("Flushing undo buffers... %1d%%"), /* CSTID_SET_COLOR_TO */ N_("Set color to '%s'"), /* CSTID_CANNOT_ALLOC_COLOR_USE_ALT */ N_("Cannot allocate color '%s', use '%s' instead."), /* CSTID_UPDATING_PIXELS */ N_("Updating pixels (%1d - %1dx%1d)..."), /* CSTID_NONE */ N_("none"), /* CSTID_PARANED_NULL */ N_("null"), /* CSTID_COPY */ N_("Copy"), /* CSTID_SAVE */ N_("Save"), /* CSTID_PASTE */ N_("Paste"), /* CSTID_RESTORE */ N_("Restore"), /* CSTID_YES */ N_("Yes"), /* CSTID_NO */ N_("No"), /* CSTID_EXTRA */ N_("Extra"), /* CSTID_INTERRUPT */ N_("interrupt"), /* CSTID_LEAVE_HYPERSPACE */ N_("Leave HyperSpace"), /* CSTID_ENTER_HYPERSPACE */ N_("Enter HyperSpace"), /* CSTID_CACHING_IMAGE */ N_("Caching images..."), /* CSTID_TOGGLE_SMOOTH_HINGE */ N_("Toggle smooth/hinge points"), /* CSTID_FINISH */ N_("Finish"), /* CSTID_DEL_A_VERTEX */ N_("Delete a vertex"), /* CSTID_ADD_A_VERTEX */ N_("Add a vertex"), /* CSTID_START_LAYOUT_ON_ARC */ N_("Start layout on arc"), /* CSTID_END_LAYOUT_ON_ARC */ N_("End layout on arc"), /* CSTID_EXECUTING_GIVEN_PROGRAM */ N_("Executing '%s'..."), /* CSTID_DOTS_DONE */ N_("...Done"), /* CSTID_IMPORTING_FILE */ N_("Importing '%s'..."), /* CSTID_LOADING_FILE */ N_("Loading '%s'..."), /* CSTID_EDIT_TEXT_SIZE_SUBSTR */ N_("edit text size"), /* CSTID_SET_FONT_SIZE_TO_PT */ N_("Set font size to %1dpt"), /* CSTID_SET_FONT_SIZE_TO */ N_("Set font size to %1d"), /* CSTID_MAKING_CONN_TO_HOST */ N_("%s: making connection to '%s'..."), /* CSTID_CONN_TO_HOST_ESTABLISHED */ N_("%s: connection to '%s' established."), /* CSTID_LOGIN_SUCC_RETRIEVE_DATA */ N_("%s: login successful; retrieving data..."), /* CSTID_LAYOUT_MENU */ N_("Layout Menu"), /* CSTID_MAKING_CONN_TO_HOST_PORT */ N_("%s: making connection to '%s:%1d'..."), /* CSTID_CONN_TO_HOST_PORT_ESTB */ N_("%s: connection to '%s:%1d' established."), /* CSTID_SENDING_REQUESTS_DOTS */ N_("%s: sending requests..."), /* CSTID_PARANED_UNKNOWN */ N_("(unknown)"), /* CSTID_READING_RESPONSE_DOTS */ N_("%s: reading responses..."), /* CSTID_RESPONSES_RECEIVED */ N_("%s: responses received."), /* CSTID_GEN_FINAL_PIXELS_PERC */ N_("Generating final pixels: %1d%%"), /* CSTID_BUILDING_HISTOGRAM_DOTS */ N_("Building histogram..."), /* CSTID_HISTOGRAM_PERC */ N_("Histogram: %1d%%"), /* CSTID_COMP_NEW_PIXELS_PERC */ N_("Computing new pixels: %1d%%"), /* CSTID_QUANTIZING_COLORS_DOTS */ N_("Quantizing from %1d to %1d colors..."), /* CSTID_REMAPPING_COLORS_DOTS */ N_("Remapping Colors..."), /* CSTID_COMPUTING_NEW_PIXELS_PERC */ N_("Computing new pixels: %1d%%"), /* CSTID_CALC_ERR_DIFF_PIX_VAL_PERC */ N_("Calculating error diffused pixel values: %1d%%"), /* CSTID_CALC_NEW_PIX_1_VAL_PERC */ N_("Calculating new pixel values (pass 1): %1d%%"), /* CSTID_CALC_NEW_PIX_2_VAL_PERC */ N_("Calculating new pixel values (pass 2): %1d%%"), /* CSTID_DLG_ACCEPT_CONTINUE */ N_("( : accept, : continue )"), /* CSTID_OPENING_GIVEN */ N_("Opening '%s'..."), /* CSTID_BACKGROUNDING_CMD */ N_("Backgrounding; '%s'."), /* CSTID_CNTRL_C_TO_INTR_AND_ABEND */ N_("Type ^C if you want to interrupt and end abnormally..."), /* CSTID_MOVE_PINNED_MENU */ N_("Move pinned menu"), /* CSTID_CLOSE_PINNED_MENU */ N_("Close pinned menu"), /* CSTID_RELEASE_MOUSE_TO_PIN_MENU */ N_("Release the mouse to pin down the menu"), /* CSTID_LOCKED_OBJS_NOT_MOVED */ N_("Locked objects are not moved."), /* CSTID_SCROLL_DOWN_1_LINE */ N_("scroll down 1 line"), /* CSTID_SCROLL_AROUND */ N_("scroll around"), /* CSTID_SCROLL_UP_1_LINE */ N_("scroll up 1 line"), /* CSTID_ENABLE_REDRAW */ N_("enable redraw"), /* CSTID_DISABLE_REDRAW */ N_("disable redraw"), /* CSTID_GET_DIR_LIST_PLEASE_WAIT */ N_("Getting directory listing of '%s', please wait..."), /* CSTID_ENTERING_HYPERSPACE */ N_("Entering hyperspace..."), /* CSTID_GOTO */ N_("Goto"), /* CSTID_DELETE */ N_("Delete"), /* CSTID_CLOSE */ N_("Close"), /* CSTID_BAD_OVAL_BBOX_ADJ */ N_("Bad oval bounding box. Adjusted."), /* CSTID_SHIFT_ALL_TABS_RIGHT */ N_("Shift All Tabs Right"), /* CSTID_SHIFT_TABS_RIGHT */ N_("Shift Tabs Right"), /* CSTID_SHIFT_TABS_LEFT */ N_("Shift Tabs Left"), NULL }; static char *gaszCachedEnglishStrTable100[] = { /* CSTID_SHIFT_ALL_TABS_LEFT */ N_("Shift All Tabs Left"), /* CSTID_SHIFT_10_TABS_RIGHT */ N_("Shift 10 Tabs Right"), /* CSTID_SHIFT_10_TABS_LEFT */ N_("Shift 10 Tabs Left"), /* CSTID_PAGE_MENU */ N_("Page Menu"), /* CSTID_GOTO_GIVEN_PAGE */ N_("Goto page %1d"), /* CSTID_GOTO_GIVEN_PAGE_WITH_NAME */ N_("Goto page %1d: \"%s\""), /* CSTID_GRAYSTR_CALLED_WITH_IDX_2 */ N_("Error: GrayStr() called with index <= 2."), /* CSTID_GRAY_SCALE_USED_FOR_PAT */ N_("Warning: Gray scales used instead of tiling patterns."), /* CSTID_SET_FILL_TO_NONE */ N_("Set fill pattern to NONE"), /* CSTID_SET_FILL_TO_SOLID */ N_("Set fill pattern to SOLID"), /* CSTID_SET_FILL_TO_BACKGROUND */ N_("Set fill pattern to BACKGROUND"), /* CSTID_SET_FILL_TO_PAT_NUMBER */ N_("Set fill pattern to pattern #%1d"), /* CSTID_SET_LINE_WIDTH_TO_GIVEN_S */ N_("Set line width to %s"), /* CSTID_SET_PEN_DASH_PAT_NO_DASH */ N_("Set dash pattern for the pen to be no dashes"), /* CSTID_SET_PEN_DASH_PAT_PAT_NUM */ N_("Set dash pattern for the pen to dash pattern #%1d"), /* CSTID_SET_PEN_TO_NONE */ N_("Set pen to NONE"), /* CSTID_SET_PEN_TO_SOLID */ N_("Set pen to SOLID"), /* CSTID_SET_PEN_TO_BACKGROUND */ N_("Set pen to BACKGROUND"), /* CSTID_SET_PEN_TO_PAT_NUM */ N_("Set pen to pattern #%1d"), /* CSTID_SEL_A_PIN_ESC_TO_END_DOTS */ N_("Please select a pin (or press to end)..."), /* CSTID_ADD_LAST_VERTEX */ N_("Add last vertex"), /* CSTID_SINGLE_PT_POLY_CONVERTED */ N_("Single point poly (%1d,%1d) converted to double point poly."), /* CSTID_BAD_SMOOTHHINGE_POLY_FIXED */ N_("Invalid poly smooth/hinge specification detected. Fixed."), /* CSTID_CLOSE_POLYGON_SPLINE */ N_("Close the polygon/spline"), /* CSTID_SNGL_PT_POLYGON_CONVERTED */ N_("Single point polygon (%1d,%1d) converted to 3-point point polygon."), /* CSTID_TWO_PT_POLYGON_CONVERTED */ N_("Two-point polygon [%1d,%1d,%1d,%1d] converted to 3-point point polygon."), /* CSTID_FILEVER_TOO_LARGE_FOR_RCBOX */ N_("Invalid file version (=%1d) for rcbox."), /* CSTID_BAD_RCBOX_BBOX_ADJUSTED */ N_("Bad rcbox bounding box. Adjusted."), /* CSTID_PARANED_SEC_ELAPSED_AVG_SPEED */ N_("(%1d sec elapsed, avg %.2fKB/sec)"), /* CSTID_UNZIPPING_WITH_CMD_DOTS */ N_("Unzipping with '%s'..."), /* CSTID_UNCOMPRESSING_WITH_CMD_DOTS */ N_("Uncompressing with '%s'..."), /* CSTID_DATA_RECEIVED */ N_("%s: data received."), /* CSTID_FORWARDING_URL_TO_URL */ N_("%s: forwarding '%s' to '%s'."), /* CSTID_SCROLL_UP */ N_("scroll up"), /* CSTID_SCROLL_DOWN */ N_("scroll down"), /* CSTID_SCROLL_PAGE_UP */ N_("scroll page up"), /* CSTID_SCROLL_PAGE_DOWN */ N_("scroll page down"), /* CSTID_SCROLL_VERTICALLY */ N_("scroll vertically"), /* CSTID_SCROLL_HORIZONTALLY */ N_("scroll horizontally"), /* CSTID_SCROLL_LEFT */ N_("scroll left"), /* CSTID_SCROLL_RIGHT */ N_("scroll right"), /* CSTID_SCROLL_PAGE_LEFT */ N_("scroll page left"), /* CSTID_SCROLL_PAGE_RIGHT */ N_("scroll page right"), /* CSTID_CANT_FIND_ATTR_WITH_COLOR */ N_("Cannot find the '%s' attribute with color %s."), /* CSTID_CANT_FIND_FILEATTR_WITH_COLOR */ N_("Cannot find the '%s' file attribute with color %s."), /* CSTID_CANT_FIND_NAMED_ATTR */ N_("Cannot find the '%s' attribute."), /* CSTID_CANT_FIND_INTERPRETABLE_ATTR */ N_("Cannot find interpretable attribute."), /* CSTID_NO_ACTION_TAKEN */ N_("No action taken."), /* CSTID_FAIL_READ_ICONPXMP_USE_BMP */ N_("Fail to read IconPixmap file: '%s'. Default icon bitmap is used."), /* CSTID_DRAG_MOUSE_CREATE_SHAPE_DOTS */ N_("Drag the mouse to create a shape..."), /* CSTID_CREATE_A_SHAPE_ABORTED */ N_("Create a shape aborted."), /* CSTID_INSTANTIATING_FILE_DOTS */ N_("Instantiating '%s'..."), /* CSTID_ATTR_PROMOTED_TO_NEW_SYMBOL */ N_("Object's attributes are promoted to the new symbol object."), /* CSTID_ATTR_PROMOTED_TO_NEW_ICON */ N_("Object's attributes are promoted to the new icon object."), /* CSTID_CREATING_FILE_DOTS */ N_("Creating '%s'..."), /* CSTID_NAMED_FILE_CREATED */ N_("File '%s' created."), /* CSTID_WRITING_ATTR_TO_NAMED_FILE */ N_("Writing attributes to '%s'..."), /* CSTID_SEMICOLON_USED_AS_SEPARATOR */ N_("';'s are used as separators."), /* CSTID_TAB_USED_AS_SEPARATOR */ N_("s are used as separators."), /* CSTID_PROCESSING_OBJ_NUMBER */ N_("Processing object %1d..."), /* CSTID_PLACING_NAMED_OBJ */ N_("Placing object '%s'..."), /* CSTID_WRITING_ATTRS_IN_TBL_FORM_TO */ N_("Writing attributes in table form to '%s'..."), /* CSTID_CORRUPTED_POLY_MKMULTISPLINE */ N_("Corrupted poly in MakeMultiSplinePolyVertex()."), /* CSTID_CORRUPTED_POLY_DMPMULTICURVE */ N_("Corrupted poly in DumpMultiCurvedPolyPoints()."), /* CSTID_FIX_ATTEMPTED */ N_("Fix attempted."), /* CSTID_PUSHING_INTO_NAMED */ N_("Pushing into '%s'..."), /* CSTID_CUR_FILE_IS */ N_("Current file is '%s'."), /* CSTID_DONT_KNOW_HOW_HANDLE_FRAME_CT */ N_("Does not know how to handle frame Content-Type: %s."), /* CSTID_CANT_FIND_OBJ_NAME_ON_RESIZE */ N_("Cannot find object named '%s' any more; on_resize script not invoked."), /* CSTID_PASTING_LINE_NUM_DOTS */ N_("Pasting line %1d..."), /* CSTID_CANT_PASTE_DEL */ N_("Cannot paste ."), /* CSTID_CANT_PASTE_BS */ N_("Cannot paste ."), /* CSTID_CANT_PASTE_ESC */ N_("Cannot paste ."), /* CSTID_CANT_PASTE_TAB_REPLACE_BY_SPC */ N_("Cannot paste , replaced by ."), /* CSTID_READING_FILE_DOTS */ N_("Reading '%s'..."), /* CSTID_RETURNED_FROM_BASIC_DRIVER */ N_("Returned from basic driver."), /* CSTID_CACHING_BITMAP */ N_("Caching bitmap..."), /* CSTID_FINISHED_CACHEING_BITMAP */ N_("Finishing caching bitmap..."), /* CSTID_NEW_BMP_SIZE_IS_W_X_H */ N_("New bitmap size is %1dx%1d."), /* CSTID_BLD_COLOR_TBL_FROM_PIXEL_DOTS */ N_("Building color table from pixels..."), /* CSTID_GENERATING_IMAGEMAP_FILE_DOTS */ N_("Generating imagemap file..."), /* CSTID_GENERATING_HTML_FILE_DOTS */ N_("Generating HTML file..."), /* CSTID_GENERATING_IMAGE */ N_("Generating image..."), /* CSTID_FS_HALFTONE_BMP_THRESH_DOTS */ N_("FS halftone bitmap (threshold=%s)..."), /* CSTID_THRESHOLD_BMP_THRESH_DOTS */ N_("Threshold bitmap (threshold=%s)..."), /* CSTID_INVALID_FILEVER_FOR_XBM */ N_("Invalid file version (%1d) for X11 Bitmap objects."), /* CSTID_FIELD_TOO_LONG_IN_OBJ_TRUNC */ N_("%s, %d: %s field too long in %s object. Truncated"), /* CSTID_FILE_LINE_BAD_FLD_IN_OBJ_STR */ N_("%s, %d: Bad %s in %s object [%s]."), /* CSTID_MALFORMED_LINE_NUM_IN_FILE */ N_("Malformed line %1d in '%s'."), /* CSTID_CACHING_PIXMAP */ N_("Caching pixmap..."), /* CSTID_FINISHED_CACHEING_PIXMAP */ N_("Finishing caching pixmap..."), /* CSTID_NEW_XPM_SIZE_IS_W_X_H */ N_("New pixmap size is %1dx%1d."), /* CSTID_MANY_COLORS_GT_255_SKIP_XPM */ N_("Too many colors (%1d, which is > 255) in an xpm objects. This object is skipped during printing."), /* CSTID_GIVEN_ADDTNL_COLOR_ALLOCATED */ N_("%1d additional color(s) allocated."), /* CSTID_INVALID_FILEVER_FOR_XPM */ N_("Invalid file version (%1d) for X11 Pixmap objects."), /* CSTID_COLOR_SUBS_FOR_UNRECOG_IN_XPM */ N_("'%s' is substituted for unrecognized colors in an X11 Pixmap object."), /* CSTID_CONTEXT_MENU */ N_("Context Menu"), /* CSTID_GEN_TEMPLATE_HTML_FILE_DOT */ N_("Generating HTML file through '%s' template..."), /* CSTID_SCALING_EVERYTHING_PAGE */ N_("Scaling everything for page %1d of %1d..."), /* CSTID_SQUARE_BRACK_MODIFIED */ N_("[Modified]"), NULL }; static char *gaszCachedEnglishStrTable200[] = { /* CSTID_SQUARE_BRACK_MODIFIED_UNSAV */ N_("[Modified/Unsavable]"), /* CSTID_SQUARE_BRACK_UNNAMED */ N_("[Unnamed]"), /* CSTID_PARANED_EMPTY */ N_("(Empty)"), /* CSTID_OPEN_FILE */ N_("Open '%s'"), /* CSTID_INC_GRID_SIZE */ N_("Increment grid size"), /* CSTID_DEC_GRID_SIZE */ N_("Decrement grid size"), /* CSTID_GRID_MENU */ N_("Grid menu"), /* CSTID_MOVE_EDIT_TEXT_BOX */ N_("Move edit text box"), /* CSTID_START_MOVE_EDIT_TEXT_BOX */ N_("Start moving the edit text box"), /* CSTID_EDIT_ATTR_IN_EDITOR */ N_("Edit the value of the '%s' attribute in a text editor"), /* CSTID_GET_NAMED_PROP_FROM_SEL_OBJ */ N_("Get the current '%s' property from the selected object"), /* CSTID_START_AN_EDGE_FROM_A_PORT */ N_("start an edge from a port"), /* CSTID_ABORT */ N_("abort"), /* CSTID_START_A_WIRE_FROM_NAMED_PORT */ N_("Start a wire from port '%s'... (Btn2 or Btn3 to abort)"), /* CSTID_END_A_WIRE_AT_NAMED_PORT */ N_("End the wire at port '%s'... (press to abort)"), /* CSTID_SET_SIGNAME_FOR_NAMED_PORT */ N_("Set signal name (currently '%s') for port '%s'..."), /* CSTID_CLK_ON_PORT_TO_RENAME_SIGNAME */ N_("Please click on a port to rename its signal name..."), /* CSTID_CLK_ON_PORT_TO_CLEAR_SIGNAME */ N_("Please click on a port to clear its signal name..."), /* CSTID_PORTNAME_TOO_LONG_SKIPPED */ N_("Port/pin name '%s...' too long. It is skipped in net-list generation."), /* CSTID_CLEAR_SIGNAME_FOR_NAMED_PORT */ N_("Clear signal name (currently '%s') for port '%s'..."), /* CSTID_EDIT_ATTR_GROUP_IN_EDITOR */ N_("Edit the '%s' attribute group (attribute list of '%s') in a text editor"), /* CSTID_INVALID_FILEVER_FOR_LINK_JPEG */ N_("Invalid file version (%1d) for linked JPEG objects."), /* CSTID_NO_SUCH_FONT */ N_("Warning: No such font: %s"), /* CSTID_ACCEPT */ N_("Accept"), /* CSTID_ADD_A_STRUCT_VERTEX */ N_("Add a vertex (drag to add control points)"), NULL }; static char *SetAndLoadCachedString(index) int index; { if (index < 100) { gaszCachedStrTable[index] = UtilStrDup(_(gaszCachedEnglishStrTable[index])); } else if (index < 200) { gaszCachedStrTable[index] = UtilStrDup(_(gaszCachedEnglishStrTable100[index-100])); } else { gaszCachedStrTable[index] = UtilStrDup(_(gaszCachedEnglishStrTable200[index-200])); } if (gaszCachedStrTable[index] == NULL) FailAllocMessage(); return gaszCachedStrTable[index]; } char *TgLoadCachedString(nID) int nID; /* * Note: once such a string is loaded, it will never change. * So, don't put any data-dependent stuff here. * Note: the returned string is translated already. */ { if (nID >= MINCACHEDSTIDS && nID < MAXCACHEDSTIDS) { int index=nID-MINCACHEDSTIDS; if (gaszCachedStrTable[index] != NULL) { return gaszCachedStrTable[index]; } return SetAndLoadCachedString(index); } #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "Cannot find cached string table entry with ID=%1d.\n", nID); #endif /* _TGIF_DBG */ return NULL; } static char *gaszStrTable[MAXNONCACHEDSTIDS]; static char *gaszEnglishStrTable[] = { /* STID_CANNOT_LOAD_FONTSET */ N_("Cannot load fontset specified by %s.%s: '%s'."), /* STID_CANNOT_LOAD_FONT */ N_("Cannot load font specified by %s.%s: '%s'."), /* STID_CANNOT_DISTRIBUTE_LOCKED_OBJS */ N_("Cannot distribute with locked objects."), /* STID_VERTICES_HORI_APART */ N_("Vertices are %1d pixels apart horizontally."), /* STID_VERTICES_VERT_APART */ N_("Vertices are %1d pixels apart vertically."), /* STID_LEFT_SIDES_APART */ N_("Left sides of objects are %1d pixels apart."), /* STID_CENTERS_APART */ N_("Center of objects are %1d pixels apart."), /* STID_RIGHT_SIDES_APART */ N_("Right sides of objects are %1d pixels apart."), /* STID_SPACED_APART_HORI */ N_("Objects are spaced %1d pixels apart horizontally."), /* STID_TOP_SIDES_APART */ N_("Top sides of objects are %1d pixels apart."), /* STID_MIDDLES_APART */ N_("Middles of objects are %1d pixels apart."), /* STID_BOTTOM_SIDES_APART */ N_("Bottom sides of objects are %1d pixels apart."), /* STID_SPACED_APART_VERT */ N_("Objects are spaced %1d pixels apart vertically."), /* STID_DISTR_VERTEX_HORI */ N_("Distribute selected vertices so that they are spaced equally horizontally"), /* STID_DISTR_VERTEX_VERT */ N_("Distribute selected vertices so that they are spaced equally vertically"), /* STID_DISTR_VERTEX_VERT_AND_HORI */ N_("Distribute selected vertices so that they are spaced equally horizontally and vertically"), /* STID_MOVE_ALL_VERTICES_YNC */ N_("Okay to move all vertices to one point? [ync](y)"), /* STID_CANNOT_ALIGN_OBJS_TOO_MANY */ N_("Cannot align objects. Too many objects locked."), /* STID_ALIGN_VERTICES_HORI_TO_GRID */ N_("Align selected vertices horizontally to the grid"), /* STID_ALIGN_VERTICES_VERT_TO_GRID */ N_("Align selected vertices vertically to the grid"), /* STID_ALIGN_VERTICES_HORI */ N_("Align selected vertices horizontally"), /* STID_ALIGN_VERTICES_VERT */ N_("Align selected vertices vertically"), /* STID_ALIGN_VERTICES_TO_GRID */ N_("Align selected vertices to the grid"), /* STID_ALIGN_VERTICES */ N_("Align selected vertices"), /* STID_SELECT_ONE_POLY_ONE_NON_POLY */ N_("Please select one polyline and one non-polyline object."), /* STID_CANNOT_MOVE_A_VERTEX_LOCKED */ N_("Cannot move a vertex for a locked polyline object."), /* STID_SELECT_ONLY_ONE_POLY */ N_("Please select only one POLY object."), /* STID_NO_ARC_CREATED */ N_("No arc created."), /* STID_INVALID_ARC_VERSION */ N_("Invalid arc version (%1d)."), /* STID_WARN_INCONSIST_ARC_DIR */ N_("Warning: Inconsistent arc direction. Corrected."), /* STID_ARC_SPEC */ N_("Please enter an arc specification: [radius,dir(+/-),theta1,theta2]"), /* STID_INVALID_ARC_SPEC_RADIUS */ N_("Invalid radius in arc specification '%s'."), /* STID_INVALID_ARC_SPEC_DIR */ N_("Invalid direction in arc specification '%s'."), /* STID_INVALID_ARC_SPEC_THETA1 */ N_("Invalid theta1 in arc specification '%s'."), /* STID_SELECT_AT_LEAST_ONE_TEXT */ N_("Must select at least one text object."), /* STID_MORE_THAN_ONE_NON_TEXT */ N_("More than one non-text objects selected."), /* STID_NO_TEXT_SELECTED_ADD_ATTRS */ N_("No text objects selected to add as attributes."), /* STID_NO_NON_TEXT_SELECTED */ N_("No objects (other than TEXT objects) selected."), /* STID_TEXT_ATTACHED */ N_("Text object(s) attached."), /* STID_TEXT_UNLOCKED_AND_ATTACHED */ N_("Text object(s) unlocked and attached."), /* STID_UNEXPECTED_EOF_IN_ABORT_READ */ N_("%s, %d: Unexpected EOF in %s. Read aborted."), /* STID_STRING_LEN_EXCEEDS_AND_TRUNC */ N_("String length exceeds %1d. String is truncated."), /* STID_MOVE_ONE_ATTR_MOUSE_MSG */ N_("LEFT--show and move. MIDDLE--toggle name shown. RIGHT--hide attr."), /* STID_CANNOT_MOVE_ATTR_IF_LOCKED */ N_("Cannot move attributes of locked object."), /* STID_SHOW_MOVE_ATTR */ N_("Show/move an attribute"), /* STID_TOGGLE_NAME_SHOWN */ N_("Toggle name shown"), /* STID_HIDE_ATTR */ N_("Hide an attribute"), /* STID_CHANGE_ATTR_JUST_MOUSE_MSG */ N_("LEFT--left justify. MIDDLE--center justify. RIGHT--right justify."), /* STID_LEFT_JUSTIFY */ N_("Left justify an attribute"), /* STID_CENTER_JUSTIFY */ N_("Center justify an attribute"), /* STID_RIGHT_JUSTIFY */ N_("Right justify an attribute"), /* STID_SELECT_ONLY_ONE_OBJ */ N_("Please select only ONE object."), /* STID_SELECT_HAS_NO_ATTR */ N_("Selected object currently has NO attributes."), /* STID_DRAG_LEFT_BTN_TO_SEE_ATTR */ N_("Drag left button to see attributes."), /* STID_CHANGE_ATTR_JUST */ N_("Change an attribute justification"), /* STID_IS_ATTR_OBSOLETE_FOR_ICON_YNC */ N_("Is the attribute '%s' obsolete for icon '%s'? [yn](y)"), /* STID_BAD_FORMAT_IN_SHORTCUT_SPEC */ N_("Invalid format in shortcut specification."), /* STID_CANNOT_FIND_NAMED_ATTR */ N_("Cannot find a '%s' attribute for the selected object."), /* STID_ATTACH_FILE_ATTRS_IN_WB */ N_("AttachFileAttrs() is disabled in WhiteBoard mode."), /* STID_CANNOT_ATTACH_NON_TEXT_OBJ */ N_("Cannot attach non-text objects."), /* STID_DETACH_FILE_ATTRS_IN_WB */ N_("DetachFileAttrs() is disabled in WhiteBoard mode."), /* STID_FILE_CONTAINS_NO_ATTRS */ N_("Current file contains no attributes."), /* STID_SHOW_ATTR_NAME_AND_VALUE */ N_("Will show both the name and the value for the '%s' attribute."), /* STID_SHOW_ATTR_VALUE_ONLY */ N_("Will only show the value of the '%s' attribute."), /* STID_NOT_SHOW_ATTR */ N_("Will not show the '%s' attribute."), /* STID_SHOW_ATTR */ N_("Will show the '%s' attribute."), /* STID_WONT_SHOW_VALUE */ N_("Will not show the '%s' value."), /* STID_TGIF_EDIT_ATTR_NAMES */ N_("%s - Edit Attribute Names"), /* STID_EDIT_FILE_ATTRS_IN_WB */ N_("EditFileAttrs() is disabled in WhiteBoard mode."), /* STID_EDIT_FILE_ATTRS_DOTS */ N_("Edit File Attributes..."), /* STID_FILE_ATTRS_UPDATED */ N_("File attribute(s) updated."), /* STID_SELECT_ONE_OBJ_FOR_EDITATTRS */ N_("Must select only one object for EditAttrs()."), /* STID_OBJ_CONTAINS_NO_ATTRS */ N_("Selected object contains no attributes."), /* STID_EDIT_OBJ_ATTRS_DOTS */ N_("Edit Object Attributes (show/hide, name shown)..."), /* STID_OBJ_ATTRS_UPDATED */ N_("Object attribute(s) updated."), /* STID_INPUT_OCTAL_STR */ N_("Please input an octal string (e.g., \"%s\"):"), /* STID_INPUT_STR */ N_("Please input a string:"), /* STID_WARN_PRINT_COURIER_IN_COLOR */ N_("Warning: Printing Courier fonts with non-solid pen in color."), /* STID_MAY_CAUSE_ERROR_IN_PRINTOUT */ N_(" This may cause error in the printout."), /* STID_BAD_OCTAL_STRING_ENCOUNTERED */ N_("Bad octal string \\%c%c%c encountered."), /* STID_SERVER_NOT_STARTED */ N_("Server not started."), /* STID_INVISIBLE_COLOR_SELECTED_YNC */ N_("Invisible color #%1d (%s) is selected for drawing.\n\nWould you like to make the color visible?"), /* STID_COLOR_IS_CURRENTLY_INVISIBLE */ N_("Color %1d (%s) is currently invisible."), /* STID_COLOR_SET_TO */ N_("Color set to '%s'."), /* STID_TEXT_VSPACE_TOO_SMALL_RESET_0 */ N_("Text vertical spacing too small.\n\nIt is reset to 0."), /* STID_FONT_AND_SIZE_NOT_AVAILABLE */ N_("%s-%1d not available."), /* STID_LINE_WIDTH_SET_TO */ N_("Line width set to %s."), /* STID_LINE_TYPE_IS_STRAIGHT */ N_("Line type is 'straight'."), /* STID_LINE_TYPE_IS_SPLINE */ N_("Line type is 'spline'."), /* STID_LINE_TYPE_IS_INTSPLINE */ N_("Line type is 'interpolated spline'."), /* STID_TAB_FOR_FILE_COMPLETION */ N_("Type for file completion..."), /* STID_FAIL_TO_CREATE_WINDOW */ N_("Fail to create a window."), /* STID_FAIL_TO_CREATE_NAMED_WINDOW */ N_("Fail to create the %s window."), /* STID_UNDO_REDO_MAY_CAUSE_CRASH */ N_("Further Undo()/Redo() may cause crashes."), /* STID_UNDO_IN_WB */ N_("Undo() is disabled in WhiteBoard mode."), /* STID_NO_COMMANDS_TO_UNDO */ N_("No commands to Undo."), /* STID_REDO_IN_WB */ N_("Redo() is disabled in WhiteBoard mode."), /* STID_NO_COMMANDS_TO_REDO */ N_("No commands to Redo."), /* STID_SELECT_LIST_NOT_SORTED_IN */ N_("Select list not sorted in %s."), /* STID_WARN_CANNOT_PARSE_NAMED_COLOR */ N_("Warning: Cannot parse color '%s'."), NULL }; static char *gaszEnglishStrTable100[] = { /* STID_CANNOT_ALLOC_NAMED_COLOR */ N_("Warning: Cannot allocate color '%s'."), /* STID_CANNOT_BREAKUP_EPS */ N_("Cannot break up an EPS object."), /* STID_INVALID_FILE_IN_X_DEFAULT */ N_("Invalid file '%s' specified by X default %s.%s."), /* STID_INVALID_XDEF_COLORXPM_GET */ N_("Invalid %s.%s: '%s' - Fail to get colors. Resource ignored."), /* STID_INVALID_XDEF_COLORXPM_TRANS */ N_("Invalid %s.%s: '%s' - Transparent color is not allowed. Resource ignored."), /* STID_FAIL_ALLOC_EDIT_TEXT_BGCOLOR */ N_("Fail to allocate the '%s' background color for use in editing existing text objects."), /* STID_FAIL_ALLOC_EDIT_TEXT_HICOLOR */ N_("Fail to allocate the '%s' highlight color for use in editing existing text objects"), /* STID_FAIL_ALLOC_DEF_BGCOLOR */ N_("Fail to allocate the default background color: '%s'."), /* STID_INVALID_XDEF_USE_ALT_VALUE */ N_("Invalid %s.%s: '%s', %1d is used instead."), /* STID_NORM_VIDEO_MODE_ASSUMED */ N_("Normal video mode assumed since %s is specified in the command line."), /* STID_ZERO_COLORS_SPECIFIED */ N_("0 colors specified (must be at least 1)."), /* STID_CANNOT_GET_X_DEFAULT */ N_("Cannot get X default %s.%s."), /* STID_INVALID_XDEF_WILL_TRY_STR */ N_("Invalid %s.%s: '%s'. Will try '%s'."), /* STID_FAIL_TO_ALLOC_3D_COLORS */ N_("Fail to allocate colors for 3DLook."), /* STID_FAIL_TO_ALLOC_COLOR_NUM */ N_("Fail to allocate color number %1d: '%s'. %s is aborted."), /* STID_DEFCOLORINDEX_GE_MAXCOLORS */ N_("Warning: %s.%s >= %s.%s. Use 0 for %s.%s."), /* STID_FAIL_ALLOC_NAMED_COLOR_ABORT */ N_("Fail to allocate the '%s' color. Abort."), /* STID_FAIL_ALLOC_COLOR_NUM_ABORT */ N_("Fail to allocate color number %1d: '%s'. Abort."), /* STID_UNEXPECTED_MAX_RGB_ZERO */ N_("Warning: Unexpected maximum RGB intensity of 0."), /* STID_FG_BG_SAME_COLOR_WARNING */ N_("Warning: Foreground and background colors are the same. You may not be able to see much."), /* STID_CANNOT_SET_FG_COLOR */ N_("Warning: Cannot set the foreground color to '%s'. The default color '%s' is used."), /* STID_INVISIBLE_COLOR_SELECTED */ N_("Invisible color #%1d (%s) is selected for drawing."), /* STID_ALL_COLOR_LAYERS_VISIBLE */ N_("All color layers are now visible."), /* STID_ALL_COLOR_LAYERS_INVISIBLE */ N_("All color layers are now invisible."), /* STID_A_COLOR_LAYER_TURNED_ON */ N_("Color '%s' (layer %1d) is turned on."), /* STID_A_COLOR_LAYER_TURNED_OFF */ N_("Color '%s' (layer %1d) is turned off."), /* STID_TURN_COLOR_LAYER_NUM_ON */ N_("Turn color '%s' (layer %1d) on"), /* STID_TURN_COLOR_LAYER_NUM_OFF */ N_("Turn color '%s' (layer %1d) off"), /* STID_COLORMAP_NOT_RESETED */ N_("Colormap not reseted due to the DONT_FREE_COLORMAP compile flag."), /* STID_ADDCOLOR_FOR_BW_DPY */ N_("Adding color is not available for a black and white display."), /* STID_ENTER_COLORS_TO_ADD */ N_("Please enter colors to add:"), /* STID_FAIL_ALLOC_NAMED_COLOR */ N_("Fail to allocate the '%s' color."), /* STID_ENTER_EDIT_BG_COLOR */ N_("Please enter the background color to be used in editing existing a text object when UseAltEditTextBgColor is selected (please enter 'NONE' to remove): [current - %s]"), /* STID_ENTER_EDIT_HILIGHT_COLOR */ N_("Please enter the highlight color to be used in editing existing a text object when UseAltEditTextBgColor is selected (please enter 'NONE' to remove): [current - %s]"), /* STID_COLOR_LAYERS_ENABLED */ N_("Color layers enabled."), /* STID_COLOR_LAYERS_DISABLED */ N_("Color layers disabled."), /* STID_TOO_MANY_LINES_IN_COLORINFO */ N_("Warning: Too many lines in color_info."), /* STID_WAIT_FOR_START_CONV */ N_("Waiting for start of input conversion."), /* STID_NO_NAMED_SELECTION_OWNER */ N_("There is no Selection Owner of %s."), /* STID_FAIL_TO_CHANGE_CONV_PROP */ N_("Fail to change conversion property."), /* STID_FAIL_TO_INTERN_NAMED_ATOM */ N_("Fail to intern the '%s' atom."), /* STID_FAIL_TO_CONNECT_TO_OWNER */ N_("Fail to connect to selection owner."), /* STID_FAIL_TO_GET_WIN_PROP */ N_("Cannot get window property."), /* STID_FAIL_TO_DISCONNECT_FROM_OWNER */ N_("Fail to disconnect from selection owner."), /* STID_LOCALE_IS */ N_("Locale is '%s'."), /* STID_MODIFIER_IS */ N_("Modifier is '%s'."), /* STID_CANNOT_OPEN_XIM */ N_("Cannot open the X Input Method."), /* STID_OVERTHESPOT_CONV */ N_("OverTheSpot conversion."), /* STID_ROOT_CONV */ N_("Root conversion."), /* STID_IM_NOT_SUPPORT_GIVEN_STYLE */ N_("This X Input Method does not support the '%s' input style."), /* STID_FAIL_TO_CREATE_INPUTCONTEXT */ N_("Fail to create InputContext."), /* STID_OPEN_XIM */ N_("Open X Input Method."), /* STID_CLOSE_XIM */ N_("Close X Input Method."), /* STID_INVALID_XDEF_USE_ALT_STR */ N_("Invalid %s.%s: '%s', '%s' is used instead."), /* STID_NO_OBJ_SELECTED_FOR_COPY */ N_("No object selected for the copy/cut operation."), /* STID_CANNOT_OPEN_FILE_FOR_WRITING */ N_("Cannot open '%s' for writing."), /* STID_CANNOT_OPEN_FILE_FOR_READING */ N_("Cannot open '%s' for reading."), /* STID_FAIL_TO_FSTAT_ABORT_COPY */ N_("Fail to fstat() '%s'. Copy aborted."), /* STID_ERR_READING_FILE_COPY_ABORT */ N_("Error reading from '%s'. Copy aborted."), /* STID_COPY_FAILED_OBJ_MAYBE_TOO_BIG */ N_("Copy to cut buffer failed. Selected object(s) may be too big."), /* STID_COPY_BUFFER_UPDATED */ N_("Copy buffer updated."), /* STID_ESC_KEY_PRESS_IGNORED */ N_("An key press is ignored."), /* STID_CUT_BUFFER_EMPTY */ N_("The cut buffer is empty or there was a problem getting data from the cut buffer."), /* STID_STR_EXCEEDS_NUM_CH_IGNORED */ N_("String length exceeds %1d. Character is ignored."), /* STID_PASTE_FROM_NON_TGIF */ N_("Paste from a non-tgif tool."), /* STID_ERR_WRITING_FILE_PASTE_ABORT */ N_("Error writing to '%s'. Paste aborted."), /* STID_FILEVER_TOO_LARGE_PASTE_ABORT */ N_("File version too large (=%1d). Paste aborted."), /* STID_CANNOT_PASTE_MIXED_TEXT */ N_("Cannot paste mixed text at the current cursor position."), /* STID_STR_BLOCKS_PASTED_FROM_TGIF */ N_("String blocks pasted from tgif."), /* STID_OBJS_PASTED_FROM_TGIF */ N_("Objects pasted from tgif."), /* STID_SEL_A_FILE_TO_PASTE_DOTS */ N_("Please select a file to PASTE..."), /* STID_PASTING_REMOTE_FILE_NOT_SUP */ N_("Pasting remote file not supported."), /* STID_NAMED_FILE_IS_EMPTY */ N_("File '%s' is empty."), /* STID_CANNOT_MALLOC_NUM_BYTES */ N_("Cannot malloc %1d bytes."), /* STID_NO_PRIMARY_SELECTION_OWNER */ N_("There is no selection owner of PRIMARY."), /* STID_CONVERTING_GIVEN_DOTS */ N_("Converting %s..."), /* STID_TIMEOUT_CONVERT_GIVEN */ N_("Timeout occurred when attempting to convert %s."), /* STID_PROBLEM_CONVERT_GIVEN */ N_("Problem encountered when converting %s."), /* STID_PASTE_COMP_TEXT_FROM_NON_TGIF */ N_("Paste compound-text from a non-tgif tool."), /* STID_CANNOT_FIND_SIZE_USE_ALT */ N_("Cannot find font size '%1d'. %1d is used instead."), /* STID_CANNOT_FIND_FONT_USE_ALT */ N_("Cannot find screen font for '%s'. '%s' font is used instead."), /* STID_CANNOT_PASTE_COMPOUND_OBJ */ N_("Cannot paste '%s' for compound objects. Therefore, '%s' cannot be selected."), /* STID_CUT_BUF_HAS_NON_ROT_COMP */ N_("The '%s' in the cut buffer contains non-rotational components. Text rotation of 0 degree is used."), /* STID_NO_PROPERTY_TO_PASTE */ N_("No property to paste."), /* STID_NO_PROPERTY_TO_COPY */ N_("No property to copy."), /* STID_INVALID_KEY_IN_SEC_OF_INIFILE */ N_("Invalid key: '%s' in the [%s] section of '%s'."), /* STID_ENTER_NAME_FOR_PROP_SET */ N_("Please enter a name for the property set."), /* STID_PROP_SET_EXISTS_OVERWRITE_YNC */ N_("Property set [%s] already exists. Okay to overwrite?"), /* STID_NO_PROP_TO_SAVE */ N_("No property to save."), /* STID_WILL_COPY_NAMED_PROP */ N_("Will copy the '%s' property."), /* STID_WILL_NOT_COPY_NAMED_PROP */ N_("Will not copy the '%s' property."), /* STID_WILL_SAVE_NAMED_PROP */ N_("Will save the '%s' property."), /* STID_WILL_NOT_SAVE_NAMED_PROP */ N_("Will not save the '%s' property."), /* STID_WILL_PASTE_NAMED_PROP */ N_("Will paste the '%s' property."), /* STID_WILL_NOT_PASTE_NAMED_PROP */ N_("Will not paste the '%s' property."), /* STID_WILL_RESTORE_NAMED_PROP */ N_("Will restore the '%s' property."), /* STID_WILL_NOT_RESTORE_NAMED_PROP */ N_("Will not restore the '%s' property."), /* STID_TOOL_COPY_PROP */ N_("%s - Copy Properties"), /* STID_TOOL_SAVE_PROP */ N_("%s - Save Properties"), /* STID_TOOL_PASTE_PROP */ N_("%s - Paste Properties"), NULL }; static char *gaszEnglishStrTable200[] = { /* STID_TOOL_RESTORE_PROP */ N_("%s - Restore Properties"), /* STID_SEL_ONLY_ONE_FOR_COPY_PROP */ N_("Please select only one object for CopyProperties()."), /* STID_SEL_ONLY_ONE_FOR_SAVE_PROP */ N_("Please select only one object for SaveProperties()."), /* STID_UNCHECK_PROP_FOR_COPY_DOTS */ N_("Please uncheck properties you don't want to copy..."), /* STID_UNCHECK_PROP_FOR_SAVE_DOTS */ N_("Please uncheck properties you don't want to save..."), /* STID_UNCHECK_PROP_FOR_PASTE_DOTS */ N_("Please uncheck properties you don't want to paste..."), /* STID_UNCHECK_PROP_FOR_RESTORE_DOTS */ N_("Please uncheck properties you don't want to restore..."), /* STID_MALFORMED_CUT_BUF_WHILE_PASTE */ N_("Malformed cut buffer read while pasting properties."), /* STID_NO_PROP_SETS_TO_RESTORE */ N_("Cannot find any property sets. Nothing to restore."), /* STID_SEL_A_PROP_SET_TO_RESTORE */ N_("Please select a property set to restore..."), /* STID_TOOL_EDIT_INI_SECTION */ N_("%s - Edit Ini Section"), /* STID_BAD_VALUE_FOR_KEY */ N_("Bad %s value: '%s'."), /* STID_NOTHING_TO_EDIT_SEC_EMPTY */ N_("The [%s] section of '%s' is empty.\n\nNothing to edit."), /* STID_EDIT_VALUES_FOR_DOTS */ N_("Edit values for [%s]..."), /* STID_TOOL_SEL_FROM_INI_SECTION */ N_("%s - Select From Ini Section"), /* STID_NOTHING_TO_SEL_SEC_EMPTY */ N_("The [%s] section of '%s' is empty.\n\nNothing to select from."), /* STID_SELECT_A_VALUE_FROM_SEC_DOTS */ N_("Select a value from [%s]..."), /* STID_COPY_PROP_BEFORE_PASTE */ N_("Please copy some properties before pasting properties."), /* STID_INVALID_PARAM_PASSED_TO_FUNC */ N_("Invalid parameters passed to %s."), /* STID_TOOL_INPUT */ N_("%s - Input"), /* STID_WARN_INVALID_NUMREDRAWBBOX */ N_("Warning: Invalid numRedrawBBox."), /* STID_USER_INTR_ABORT_REPAINT */ N_("User interrupt. Repaint aborted."), /* STID_CANNOT_ALLOC_XPM_NO_ANIM */ N_("Cannot allocate pixmap of size [%1dx%1d].\n\nCannot cache animation."), /* STID_SCROLLING_CANCELED */ N_("Scrolling canceled."), /* STID_CANNOT_ALLOC_PIXMAP_OF_SIZE */ N_("Cannot allocate pixmap of size [%1dx%1d]."), /* STID_FORCING_END_ANIMATE */ N_("Forcing an end_animate()."), /* STID_TOOL_NOT_FINISH_WITH_EXEC */ N_("%s is not finished with the previous ExecCmdsFromFile() yet."), /* STID_NO_INTSPLINE_SELECTED */ N_("No interpolated spline objects selected."), /* STID_INTSPLINE_CONVERTED_TO_SPLINE */ N_("Interpolated spline objects converted to splines."), /* STID_SELECT_ONLY_ONE_POLY_POLYGON */ N_("Please select only one POLY or POLYGON object."), /* STID_CANNOT_TOGGLE_FOR_INTSPLINE */ N_("Cannot toggle Smooth/Hinge points for interpolated spline objects."), /* STID_BAD_POLY_IN_TOGGLE_SMOOTH */ N_("Bad poly in SelectModeToggleSmoothHinge()."), /* STID_CLICK_LEFT_BUTTON_TO_TOGGLE */ N_("Click left mouse button to toggle Smooth/Hinge points."), /* STID_CLICK_OTHER_BUTTON_TO_QUIT */ N_("Click other buttons to quit."), /* STID_ONLY_TOGGLE_SMOOTH_IN_MODES */ N_("Can only toggle smooth/hinge points in VERTEX or SELECT mode."), /* STID_SMOOTHNESS_TOGGLED */ N_("The smoothness of selected vertices are toggled."), /* STID_BREAK_TEXT_CWL */ N_("Would you like to break text at char/word/line boundaries? [cwl](c)"), /* STID_BREAK_TEXT_CL */ N_("Would you like to break text at char/line boundaries? [cl](c)"), /* STID_BREAK_TEXT_CW */ N_("Would you like to break text at char/word boundaries? [cw](c)"), /* STID_INVALID_SPEC_ON_BREAK_TEXT */ N_("Invalid specification on how to break up text: '%s'."), /* STID_NO_TEXT_OBJ_TO_BREAK_UP */ N_("No text objects selected to break up."), /* STID_SOME_TEXT_NOT_BROKEN_UP_SIZE */ N_("Some text are not broken up due to unavailable text size."), /* STID_TEXT_BROKEN_INTO_CHARS */ N_("Text string is broken up into characters."), /* STID_CUR_TEXT_BG_SET_TO_NAMED */ N_("Current text object's background color has been set to '%s'."), /* STID_SOME_TEXT_BG_SET_TO_NAMED */ N_("Some text object's background color have been set to '%s'."), /* STID_SEL_ONE_POLYGON_TO_MAKE_REG */ N_("Please select one polygon object to make it regular."), /* STID_POLYGON_LOCKED */ N_("Selected polygon is locked."), /* STID_POLYGON_TOO_SMALL_FOR_REGULAR */ N_("Selected polygon is too small to make regular."), /* STID_VERTEX_AT_3_OCLOCK_YNC */ N_("Do you want a vertex at the 3 o'clock position? [ync](y)"), /* STID_CANNOT_DEL_PT_FOR_LOCKED */ N_("Cannot delete points for a locked object."), /* STID_LEFT_BTN_TO_DEL_PTS */ N_("Click left mouse button to DELETE points."), /* STID_CANNOT_ADD_PT_FOR_LOCKED */ N_("Cannot add points for a locked object."), /* STID_CANNOT_ADD_PT_FOR_AUTO_ARROW */ N_("Cannot add points for an auto_retracted_arrows object."), /* STID_LEFT_BTN_TO_ADD_PTS */ N_("Drag left mouse button to ADD points."), /* STID_UNDO_BUF_AND_CMAP_FLUSHED */ N_("Undo buffer and Colormap flushed."), /* STID_NUM_COLORS_ALLOCATED */ N_("%1d color(s) allocated."), /* STID_UNDO_BUF_FLUSHED */ N_("Undo buffer flushed."), /* STID_SEL_ONE_XBM_OR_XPM_TO_RESTORE */ N_("Please select one X11 Bitmap or X11 Pixmap object to restore."), /* STID_CANNOT_RESTORE_LOCKED */ N_("Cannot restore a locked object."), /* STID_SEL_ONE_XBM_OR_XPM_TO_CUT */ N_("Please select one X11 Bitmap or X11 Pixmap object to cut."), /* STID_CANNOT_CUT_LOCKED */ N_("Cannot cut a locked object."), /* STID_CANNOT_CUT_TRANSFORMED_X_OBJ */ N_("Cannot cut a stretched/rotated/sheared X11 Bitmap or X11 Pixmap object."), /* STID_SEL_ONE_XBM_OR_XPM_TO_BREAKUP */ N_("Please select one X11 Bitmap or X11 Pixmap object to break up."), /* STID_CANNOT_BREAK_XFORMED_X_OBJ */ N_("Cannot break up a stretched/rotated/sheared X11 Bitmap or X11 Pixmap object."), /* STID_CANNOT_BREAKUP_LOCKED */ N_("Cannot break up a locked object."), /* STID_ENTER_NUM_ROWCOL_TO_BREAK */ N_("Please enter the number of columns and rows to break into (original size is %1dx%1d): [Col x Row]"), /* STID_INVALID_ROWCOL_SPEC_REENTER */ N_("Invalid specification: '%s'.\n\nPlease enter [Cols x Rows] or [=WxH]"), /* STID_ENTER_CONCAVE_OR_CONVEX */ N_("Please specify concave (c) or convex (v):"), /* STID_INVALID_SPEC */ N_("Invalid specification: '%s'."), /* STID_SEL_AN_ARC_OBJ */ N_("Please select an arc object."), /* STID_NO_ARC_OBJ_SELECTED */ N_("No arc object selected."), /* STID_TOO_MANY_ARC_SEL_ONLY_ONE_ARC */ N_("Too many arc objects selected.\n\nPlease select only one arc object."), /* STID_NO_OTHER_OBJ_FOR_LAYOUTONARC */ N_("Nothing to layout on the selected arc.\n\nPlease select other objects in addition to the selected arc."), /* STID_CANNOT_LAYOUTONARC_LOCKED */ N_("Some objects are locked.\n\nPlease unlock them before retrying."), /* STID_ARC_XFORMED_FOR_LAYOUTONARC */ N_("Don't know how to layout objects on an arc object that has been stretched/sheared/rotated.\n\nPlease use a simple arc."), /* STID_ROT_NOT_AVAIL_ON_VERTEX_MODE */ N_("PreciseRotate() is not available in vertex mode."), /* STID_ENTER_AN_ANGLE_IN_DEGREES */ N_("Please specify an angle in degrees: (positive angle is clock-wise)"), /* STID_INVALID_SPEC_NUM_EXPECTED */ N_("Invalid specification '%s'.\n\nA numerical value is expected."), /* STID_SOME_GROUP_OBJ_NOT_MODIFIED */ N_("Some group/symbol/icon objects are not modified."), /* STID_CANNOT_REM_XFORM_FOR_GROUPED */ N_("Cannot remove transforms for group/symbol/icon objects."), /* STID_ENTER_EDIT_TEXT_SIZE */ N_("Please specify text size for editing text objects (enter 0 or a value between 4 and 34, 0 means to use the actual size of text): [current: %1d]"), /* STID_EDIT_TEXT_SIZE_OUT_OF_RANGE */ N_("The value entered: '%s' is out of range.\n\nPlease enter a value between 4 and 34."), /* STID_ACTUAL_EDIT_TEXT_SIZE */ N_("Actual text size will be used to edit existing text."), /* STID_USE_SPECIFIED_EDIT_TEXT_SIZE */ N_("Text size of %1d will be used to edit existing text."), /* STID_CANNOT_FIND_NAMED_STRING */ N_("Cannot find '%s'."), /* STID_FIND_CMD_WRAPPED */ N_("Find command is wrapped around."), /* STID_ENTER_CASE_STR_TO_FIND */ N_("Please enter a string to find (case sensitive):"), /* STID_ENTER_NOCASE_STR_TO_FIND */ N_("Please enter a string to find (case insensitive):"), /* STID_NO_PREVIOUS_FIND */ N_("No previous find specified.\n\nPlease select FindCaseSensitive() or FindNoCase()."), /* STID_CANNOT_ABUT_IN_VERTEX_MODE */ N_("Cannot abut in vertex mode."), /* STID_CANNOT_ABUT_LOCKED */ N_("Cannot abut. Too many objects locked."), /* STID_ABUTTED_HORI */ N_("Objects are abutted horizontally."), /* STID_ABUTTED_VERT */ N_("Objects are abutted vertically."), /* STID_ICONS_BROUGHT_UP_TO_DATE */ N_("Selected icons are brought up to date."), /* STID_SEL_AT_LEAST_TWO_OBJS */ N_("Please select at least two objects."), /* STID_CANNOT_SIZE_OF_GIVEN_WIDTH */ N_("Cannot size objects to width of %1d."), /* STID_CANNOT_SIZE_OF_GIVEN_HEIGHT */ N_("Cannot size objects to height of %1d."), /* STID_SPECIFY_WIDTH_HEIGHT */ N_("Please specify a width and a height [WxH]:"), /* STID_SPECIFY_WIDTH */ N_("Please specify a width:"), /* STID_SPECIFY_HEIGHT */ N_("Please specify a height:"), NULL }; static char *gaszEnglishStrTable300[] = { /* STID_NAMED_XDEF_IS_OBSOLETE */ N_("The %s.%s X default is obsolete."), /* STID_GIVEN_BPS_PREVIEW_NOT_SUP */ N_("%1d bits per sample preview bitmap is not supported."), /* STID_INVALID_PREVIEW_BMP_IN_EPS */ N_("Invalid preview bitmap in EPS file: '%s'."), /* STID_FAIL_TO_WRITE_TO_STDOUT */ N_("Fail to write to stdout.\n\nFile system may be full."), /* STID_FAIL_TO_PARSE_WINEPS_FILE */ N_("Fail to parse Windows EPS file '%s'."), /* STID_INVALID_PREVIEW_BOX_IN_EPS */ N_("Invalid preview box in EPS file: '%s'."), /* STID_CANNOT_BBOX_IN_GIVEN_FILE */ N_("Cannot find bounding box information in '%s'."), /* STID_CANNOT_CONVERT_WINEPS_PREVIEW */ N_("Unable to convert Windows EPS preview bitmap in '%s'."), /* STID_CANNOT_OPEN_EPS_FILE_FOR_READ */ N_("Cannot open EPS file '%s' for reading."), /* STID_EPS_OBJ_SKIPPED_FOR_PRINT */ N_("EPS object skipped during printing."), /* STID_EPS_FILE_NEWER_THAN_EPS_OBJ */ N_("Warning: EPS file '%s' is newer than the EPS object."), /* STID_NO_TOP_LEVEL_EPS_SELECTED */ N_("No top-level EPS object selected."), /* STID_CANNOT_IMPORT_GIVEN_EPS */ N_("Cannot import EPS file '%s'."), /* STID_EPS_OBJECT_UPDATED */ N_("EPS object(s) updated."), /* STID_CANNOT_EVAL_INVALID_OP_TYPE */ N_("Cannot evaluate '%s'.\n\nInvalid operand type for the '%s' operator."), /* STID_DIVIDE_BY_ZERO_FOR_OP_TYPE */ N_("Divide by zero encountered for the '%s' operator."), /* STID_ILLEGAL_EXPR_INVALID_OP_CODE */ N_("Illegal expression: '%s'.\n\nInvalid operator code: '%1d'."), /* STID_ILLEGAL_EXPR_EMPTY_OP_STACK */ N_("Illegal expression: '%s'.\n\nEmpty operator stack."), /* STID_ILLEGAL_EXPR_BAD_NUM_VALUE */ N_("Illegal expression: '%s'.\n\nBad numeric value: '%s'."), /* STID_ILLEGAL_EXPR_BAD_STR_VALUE */ N_("Illegal expression: '%s'.\n\nBad string value: '%s'."), /* STID_ILLEGAL_EXPR_BAD_IDENTIFIER */ N_("Illegal expression: '%s'.\n\nBad identifier: '%s'."), /* STID_ILLEGAL_EXPR_BAD_OPERATOR */ N_("Illegal expression: '%s'.\n\nBad operator: '%s'."), /* STID_ILLEGAL_EXPR_TOO_MANY_SYMBOL */ N_("Illegal expression: '%s'.\n\nToo many '%c'."), /* STID_ILL_EXPR_OP_STACK_NON_EMPTY */ N_("Illegal expression: '%s'.\n\nNon empty operator stack after evaluation."), /* STID_ILL_EXPR_VAL_STACK_NON_EMPTY */ N_("Illegal expression: '%s'.\n\nNon empty value stack after evaluation."), /* STID_ILL_EXPR_TOO_MANY_VALS_LEFT */ N_("Illegal expression: '%s'.\n\nToo many values left on the value stack after evaluation."), /* STID_CANNOT_OPEN_FOR_READ_PRINT */ N_("Cannot open '%s' for reading. Printing aborted."), /* STID_CANNOT_OPEN_FOR_WRITE_PRINT */ N_("Cannot open '%s' for writing. Printing aborted."), /* STID_CANNOT_FIND_CMD_EXEC */ N_("Cannot find '%s'.\n\nWould you like to execute '%s' anyway?"), /* STID_CANNOT_FIND_CMD_IN_PATH_EXEC */ N_("Cannot find '%s' in the PATH.\n\nWould you like to execute '%s' anyway?"), /* STID_CANT_FIND_CMD_MSG_EXEC */ N_("Cannot find '%s'. %s\n\nWould you like to execute '%s' anyway?"), /* STID_CANT_FIND_CMD_INPATH_MSG_EXEC */ N_("Cannot find '%s' in the PATH. %s\n\nWould you like to execute '%s' anyway?"), /* STID_FILE_EXISTS_OK_OVERWRITE_YNC */ N_("File '%s' exists, okay to overwrite? [ync](y)"), /* STID_ONE_PAGE_SYM_ABORT_SAVE */ N_("A symbol file can only have one page.\n\nSave aborted."), /* STID_ONE_PAGE_PIN_ABORT_SAVE */ N_("A pin file can only have one page.\n\nSave aborted."), /* STID_TOO_MANY_SYM_ABORT_SAVE */ N_("Too many symbols.\n\nSymbol file not saved."), /* STID_CANT_OPEN_WRITE_FILE_NOT_SAVE */ N_("Cannot open '%s' for writing. File not saved."), /* STID_SAVE_TMP_FILE_DOTS */ N_("Saving temporary file '%s'..."), /* STID_TMP_FILE_SAVED */ N_("Temporary file '%s' saved."), /* STID_CANNOT_CHMOD */ N_("Cannot chmod '%s' to 0%03o."), /* STID_WORKING_DIRECTORY_IS */ N_("( working directory: %s )"), /* STID_ENTER_NEW_FNAME_ACCEPT_CANCEL */ N_("Please enter new file name: ( : accept, : cancel )"), /* STID_CANT_SAVE_SYM_NO_SYM_FOUND */ N_("Cannot save as a symbol file.\n\nNo symbol defined."), /* STID_CANT_SAVE_PIN_NO_SYM_FOUND */ N_("Cannot save as a pin file.\n\nNo symbol defined."), /* STID_CANT_SAVE_OJB_ONE_SYM_FOUND */ N_("Cannot save as an object file.\n\nOne symbol defined."), /* STID_CANT_SAVE_SYM_SAVE_AS_PIN */ N_("Cannot save as a symbol file.\n\nPlease save the file as a pin file."), /* STID_CANT_SAVE_PIN_ONE_SYM_FOUND */ N_("Cannot save as a pin file.\n\nOnly one symbol is defined."), /* STID_CANT_SAVE_OJB_TWO_SYM_FOUND */ N_("Cannot save as an object file.\n\nTwo symbols defined."), /* STID_CANT_SAVE_SYM_TWO_SYM_FOUND */ N_("Cannot save as a symbol file.\n\nTwo symbols defined."), /* STID_CANT_FIND_TYPE_ATTR_NOT_SAVED */ N_("Cannot find an attribute name 'type'.\n\nPin file not saved."), /* STID_SYM_TYPE_WRONG_PIN_NOT_SAVED */ N_("Symbol type is not '%s'.\n\nPin file not saved."), /* STID_NO_FILE_NAME_FILE_NOT_SAVED */ N_("No file name specified.\n\nFile not saved."), /* STID_SAVING_DOTS */ N_("Saving '%s'..."), /* STID_PROBLEM_ZIPPING_PLEASE_SAVE */ N_("Problems encountered while (g)zipping '%s' to '%s'.\n\nThe unzipped file is '%s'. Please save a copy of it before proceeding."), /* STID_FILE_SAVED */ N_("File '%s' saved."), /* STID_FILE_NOT_SAVED */ N_("File '%s' is not saved."), /* STID_NO_SYM_FOUND_SYM_NOT_SAVED */ N_("No symbol found.\n\nSymbol file not saved."), /* STID_ENTER_NEW_FILE_NAME */ N_("Please enter new file name:"), /* STID_CANT_FIND_DOT_IN_SAVEFILE */ N_("Cannot find '.' in curFileName in %s."), /* STID_NO_SYM_FOUND_PIN_NOT_SAVED */ N_("No symbol found.\n\nPin file not saved."), /* STID_SYM_TYPE_IS_SHOULD_SAVE_PIN */ N_("The symbol is of type %s.\n\nIt should be saved as a pin file."), /* STID_TOO_MANY_SYM_FILE_NOT_SAVED */ N_("Too many symbols.\n\nFile not saved."), /* STID_BAD_FIELD_IN_FUNC_ABORT_READ */ N_("%s, %d: Invalid %s in %s. Read aborted."), /* STID_UNRECOG_PAGE_STYLE */ N_("Unrecognizable page style '%1d'."), /* STID_PORTRAIT_STYLE_ASSUMED */ N_("Portrait style assumed."), /* STID_CANT_FIND_COLOR_NUM_USE_CUR */ N_("In reading state, cannot find color #%1d, use '%s' as the current color."), /* STID_LINEWIDTH_IDX_RANGE_SET_TO_0 */ N_("File's linewidth index '%1d' is out of range. Set to 0."), /* STID_BAD_FIELD_IN_OBJ_ABORT_READ */ N_("%s, %d: Invalid %s field in reading the %s object. Read aborted."), /* STID_BAD_INPUT_WHILE_READ_PAGE */ N_("Malformed input file (apparently reading page %1d). Read aborted."), /* STID_BAD_PAGE_FILE_NAME_TRUNC_TO */ N_("Invalid page file name: '%s'. Truncated to '%s'."), /* STID_CUR_COLOR_CORRECTED_TO_BE */ N_("(Current color is corrected to be '%s'.)"), /* STID_FAIL_ALLOC_BGCOLOR_USE_DEF */ N_("Fail to allocate the background color: '%s'. The current default background color '%s' is used instead."), /* STID_ONLY_PAGE_1_IMPORTED */ N_("Only page 1 is imported from a multipage file."), /* STID_ONLY_GIVEN_PAGE_IMPORTED */ N_("Only page %1d is imported from a multipage file."), /* STID_INVALID_REMOTE_FNAME */ N_("Invalid remote file name '%s'."), /* STID_CANNOT_READ_TMP_FILE */ N_("Cannot read temporary file '%s'."), /* STID_CANNOT_IMPORT_FILE */ N_("Cannot import '%s'."), /* STID_INVALID_PAGE_NUM */ N_("Invalid page number '%s' specified."), /* STID_USER_INTR_ABORT_DRAW */ N_("User interrupt. Drawing aborted."), /* STID_FILE_VER_ABORT_IMPORT */ N_("File version (=%1d) too large.\n\nImport aborted.\n\nYou may need a more recent version of %s. Please check ."), /* STID_FILE_CORRUPTED_ABORT_IMPORT */ N_("File corrupted.\n\nImport aborted."), /* STID_FILE_IMPORTED */ N_("'%s' imported."), /* STID_SEL_AN_OBJ_FILE_TO_IMPORT */ N_("Please select an object file to import..."), /* STID_CANNOT_ALLOC_BGCOLOR_USE_DEF */ N_("Cannot allocate bg_color '%s', default bgcolor used."), /* STID_CANNOT_ALLOC_FGCOLOR_USE_DEF */ N_("Cannot allocate fg_color '%s', default fgcolor used."), /* STID_CANNOT_SET_BGXPM_TO */ N_("Cannot set background pixmap to '%s'."), /* STID_COLORMAP_FLUSHED */ N_("Colormap flushed."), /* STID_FILE_VER_ABORT_OPEN */ N_("File version (=%1d) too large.\n\nOpen aborted.\n\nYou may need a more recent version of %s. Please check ."), /* STID_FILE_CORRUPTED_ABORT_OPEN */ N_("File corrupted.\n\nOpen aborted."), /* STID_POP_BACK_TO_NAMED */ N_("Pop back to '%s'."), /* STID_WARN_PS_BBOX_EMPTY */ N_("Warning: The PostScript bounding box is empty."), /* STID_TIFFEPSI_DIRECTLY_SUPPORTED */ N_("Obsoleted %s.%s used. Ignored.\n\tTiffEPSI export is now supported by %s directly as an export format."), /* STID_INVALID_XDEF */ N_("Invalid %s.%s: '%s'."), /* STID_FAIL_EXEC_PROG_EPSI_NOT_GEN */ N_("Fail to execute '%s'.\n\nEPSI file not generated."), /* STID_FAIL_GET_FINFO_EPSI_NOT_GEN */ N_("Fail to get file info for '%s'.\n\nEPSI file not generated."), /* STID_CANNOT_OPEN_FILE_FOR_APPEND */ N_("Cannot open '%s' for appending."), /* STID_CANNOT_PRINT_REMOTE_FILE */ N_("Cannot print/export a remote file.\n\nPlease first save the file and then print/export again."), /* STID_NO_OBJ_TO_PRINT_ON_PAGE */ N_("No objects to print on page %1d."), /* STID_NO_OBJ_TO_PRINT */ N_("No objects to print."), /* STID_NO_CUR_FILE_CANNOT_GEN_FORMAT */ N_("No current file.\n\nCannot generate %s output."), NULL }; static char *gaszEnglishStrTable400[] = { /* STID_GENERATING_PRINT_FILE_DOTS */ N_("Generating print file..."), /* STID_NO_OBJ_TO_EXPORT */ N_("No objects to export."), /* STID_WRITING_TO_DOTS */ N_("Writing to '%s'..."), /* STID_GENERATING_PREVIEW_BITMAP */ N_("Generating preview bitmap..."), /* STID_OUTPUT_TRUNC_IN_PRINT_TILED */ N_("Output may get truncated because %s.%s is set to 1."), /* STID_RECOMMEND_REDUCING_SETTING */ N_("Reducing the above setting is recommended."), /* STID_PRINTING_WITH_GIVEN_CMD */ N_("Printing with the '%s' command."), /* STID_CANNOT_EXEC_ABORT_PRINT */ N_("Cannot execute '%s', print aborted."), /* STID_NAMED_FILE_PRINTED */ N_("'%s' printed."), /* STID_PRINT_COMPLETED */ N_("Print completed."), /* STID_PRINTING_INTO_NAMED_FILE */ N_("Printing into '%s'..."), /* STID_GENERATING_TIFF_PREVIEW_BMP */ N_("Generating TIFF preview bitmap..."), /* STID_FORMAT_FILE_NOT_GENERATED */ N_("%s file not generated."), /* STID_CONVERTING_INTO_NAMED_FILE */ N_("Converting into '%s'..."), /* STID_CANNOT_EXEC_FORMAT_NOT_GEN */ N_("Cannot execute '%s', %s file not generated."), /* STID_FORMAT_FILE_PRINTED_INTO */ N_("%s file printed into '%s'."), /* STID_NO_CUR_FILE_CANNOT_GEN_TEXT */ N_("No current file.\n\nCannot generate text output."), /* STID_TEXT_OUTPUT_NOT_GEN */ N_("Text output not generated."), /* STID_TEXT_PRINTED_INTO_NAMED_FILE */ N_("Text file printed into '%s'."), /* STID_TOO_MANY_COLOR_FOR_XPM_EXPORT */ N_("XPM objects that have more than 255 colors have been skipped during printing/exporting.\n\nYou can use ReduceColors() from the ReduceNumberOfColors Submenu of the ImageProc Menu to reduce their number of colors."), /* STID_CANNOT_PRINT_EPS_TILED_PAGE */ N_("Cannot print in EPS format in Tiled page mode."), /* STID_PREPROCESS_PAGE_OF */ N_("Preprocess page %1d of %1d..."), /* STID_GENERATING_PAGE_OF */ N_("Generating page %1d of %1d..."), /* STID_GIVEN_PAGE_NOT_GENERATED */ N_("Page %1d has not been generated."), /* STID_PAGE_RANGE_NOT_GENERATED */ N_("Pages %1d through %1d have not been generated."), /* STID_PRINTWITHCMD_WORKS_PRINTER */ N_("PrintWithCmd() only works when output device is the printer."), /* STID_ENTER_PRINT_CMD_NAME */ N_("Please enter print command name:"), /* STID_NO_OBJ_SEL_NOTHING_TO_PRINT */ N_("No objects selected.\n\nNothing printed."), /* STID_SPECIFY_PERCENT_REDUCTION */ N_("Please specify percent reduction (<100) or enlargement (>100):"), /* STID_INVALID_REDUCTION */ N_("Invalid reduction '%s'."), /* STID_NEW_REDUCTION_IS_PERCENT */ N_("New reduction is %s%%."), /* STID_NEW_ENLARGEMENT_IS_PERCENT */ N_("New enlargement is %s%%."), /* STID_OK_TO_CLEAR_WHITEBOARD */ N_("Okay to clear WhiteBoard?"), /* STID_FILE_MOD_SAVE_BEFORE_CLEAR */ N_("File modified, save file before clear? [ync](y)"), /* STID_EDITING_NO_FILE */ N_("Editing no file."), /* STID_OPEN_IN_WB */ N_("Open() is disabled in WhiteBoard mode."), /* STID_FILE_MOD_SAVE_BEFORE_OPEN */ N_("File modified, save file before open? [ync](y)"), /* STID_SELECT_A_FILE_TO_OPEN */ N_("Please select a file to OPEN..."), /* STID_INVALID_PAGE_SPECIFIED_FOR */ N_("Invalid page specified for '%s'."), /* STID_SETTEMPLATE_IN_WB */ N_("SetTemplate() is disabled in WhiteBoard mode."), /* STID_SELECT_FILE_AS_TEMPLATE */ N_("Please select a file to be used as template..."), /* STID_NOT_SUP_REMOTE_TEMPLATE_FILE */ N_("Using a remote template file is not supported."), /* STID_CANNOT_OPEN_STILL_TEMPLATE */ N_("Cannot open '%s' for reading.\n\nWould you still like to use it as a template file?"), /* STID_STILL_USE_AS_TEMPLATE */ N_("Would you still like to use '%s' as a template file?"), /* STID_TEMPLATE_SET_TO */ N_("Template set to '%s'."), /* STID_FILE_MOD_SAVE_BEFORE_QUIT */ N_("File modified, save file before quit? [ync](y)"), /* STID_ANCESTER_MOD_STILL_QUIT */ N_("Ancester file modified, still quitting? [ync](y)"), /* STID_ILLEGAL_DOUBLE_BYTE_TRUNC */ N_("Illegal double-byte string truncated:"), /* STID_TOOL_CANT_HANDLE_DB_FONT */ N_("The '%s' double-byte font has min_byte1=\\%03o and max_byte1=\\%03o.\n%s does not know how to handle this double-byte font.\nPlease don't use this font and e-mail this error message to %s."), /* STID_FAIL_LOAD_FONT_FONT_SUBS */ N_("Fail to load the following font: '%s'.\n\n%s-%1d substituted for %s-%1d."), /* STID_FONT_SUBSTITUTED */ N_("%s-%1d substituted for %s-%1d."), /* STID_CANNOT_GET_IMAGE_OF_SIZE */ N_("Cannot get image of size [%1dx%1d]. System resource may be low."), /* STID_UNRECOG_CHARCODE_DISCARD */ N_("Unrecognized character code \\03%o. Character discarded."), /* STID_CANT_FIND_FONT_USE_ALT */ N_("Cannot find the %s font. Use '%s' instead."), /* STID_BAD_XDEF_CANT_FIND_EQ_SKIP */ N_("Invalid entry '%s' (cannot find '=') in %s.%s, skipped."), /* STID_BAD_XDEF_MISS_FONT_NAME_SKIP */ N_("Invalid entry '%s' (missing font name) in %s.%s, skipped."), /* STID_MISS_FONT_SPEC_IN_XDEF */ N_("Missing font specification in '%s.%s'."), /* STID_INVALID_X_FONT_INFO_IN_XDEF */ N_("Invalid X font information in '%s.%s': '%s'."), /* STID_INVALID_X_REG_INFO_IN_XDEF */ N_("Invalid X registry information in '%s.%s': '%s'."), /* STID_INVALID_PS_INFO_IN_XDEF */ N_("Invalid PS font information in '%s.%s': '%s'."), /* STID_ERR_PROCESS_FONT_USE_ALT */ N_("Warning: Error in processing %s.%s: '%s'.\n\t'%s-%s-*-%%d-*-*-*-*-*-%s' used."), /* STID_INVALID_SB_FONT_USE_DB_FONT */ N_("Invalid %s.%s: '%s'. Please use a non-double-byte font."), /* STID_ERR_PROCESS_SIZE_USE_DEF_SIZE */ N_("Warning: Error in processing %s.%s. Default font sizes used."), /* STID_OBSOLETE_XDEF_USE_ALT */ N_("Obsoleted %s.%s used. Please use %s.%s instead."), /* STID_CANT_OPEN_DEF_MSG_FONT_ABORT */ N_("Cannot open the Default(Msg)Font '%s'."), /* STID_WARN_VERY_SMALL_DEF_FONT */ N_("Warning: Very small default font width/height (%1d/%1d).\n\tPossibly a problem with the font path.\n\tSet default font width to 9 and height to 14 as a temporary fix."), /* STID_CANT_OPEN_RULER_FONT_ABORT */ N_("Cannot open the RulerFont '%s'."), /* STID_WARN_VERY_SMALL_RULER_FONT */ N_("Warning: Very small ruler font width/height (%1d/%1d).\n\tPossibly a problem with the font path.\n\tSet ruler font width to 7 and height to 12 as a temporary fix."), /* STID_CANNOT_SET_INITIAL_FONT_TO */ N_("Warning: Cannot set InitialFont to '%s'."), /* STID_CANT_SET_INIT_FONTSTYLE_ALT */ N_("Warning: Cannot set InitialFontStyle to '%s'. '%s' font is used instead."), /* STID_CANT_SET_INIT_FONTJUST_ALT */ N_("Warning: Cannot set InitialFontJust to '%s'. '%s' is used instead."), /* STID_CANT_SET_INIT_FONTSIZE_ALT */ N_("Warning: Cannot set InitialFontSize to '%s'. '%s' is used instead."), /* STID_FONT_NOT_AVAILABLE */ N_("The '%s' font is not available."), /* STID_CANT_CHANGE_SIZEPT_TO_USE_ALT */ N_("Cannot change size to %1dpt. %1dpt used."), /* STID_CANT_CHANGE_SIZE_TO_USE_ALT */ N_("Cannot change size to %1d. %1d used."), /* STID_INVALID_VSPACE_NOT_CHANGED */ N_("Invalid vertical spacing for a text object. Vertical spacing for that object not changed."), /* STID_VSPACE_TOO_SMALL_NOT_CHANGED */ N_("Text vertical spacing too small. No change."), /* STID_ENTER_POINT_SIZE */ N_("Please enter point size:"), /* STID_ENTER_FONT_SIZE */ N_("Please enter font size:"), /* STID_FONT_SIZE_TOO_SMALL */ N_("Font size '%s' too small."), /* STID_FONT_SUB_NO_SUCH_FONT_USR_DEF */ N_("%s substituted for font number %d.\n\nThere is no such font. Use default."), /* STID_NO_KANJI_FONT_GIVEN_NUMBER */ N_("There is no kanji-font number %d."), /* STID_FAIL_TO_CONN_TO_HOST */ N_("%s: Fail to connect to server on '%s'."), /* STID_NETWORK_READ_ERROR */ N_("%s: Network read error."), /* STID_NETWORK_ERROR */ N_("%s: Network error."), /* STID_CONN_ABORT_BY_USER */ N_("%s: Aborted by the user."), /* STID_CONN_TERM_BY_SERVER */ N_("%s: Connection terminated by the server."), /* STID_FAIL_TO_OPEN_DATA_SOCKET */ N_("%s: Fail to open a socket for FTP data port."), /* STID_USING_METRIC_SYSTEM */ N_("Using Metric system."), /* STID_USING_ENGLISH_SYSTEM */ N_("Using English system."), /* STID_SNAP_NOT_ON_GRID_SZ_SAME */ N_("Snap is not on, grid size not changed."), /* STID_AT_MAX_GRID_GRID_SZ_SAME */ N_("Already at maximum grid, grid size not changed."), /* STID_AT_MIN_GRID_GRID_SZ_SAME */ N_("Already at minimum grid, grid size not changed."), /* STID_SNAP_TO_GRID_ACTV */ N_("Snapping to grid point activated."), /* STID_SNAP_TO_GRID_DISABLED */ N_("Snapping to grid point disabled."), /* STID_WILL_PRINT_IN_COLOR */ N_("Will print in color (PS and pixmap)."), /* STID_WILL_PRINT_IN_BW */ N_("Will print in black-and-white (PS and bitmap)."), /* STID_CONSTRAINED_MOVE */ N_("Constrained move."), /* STID_UNCONSTRAINED_MOVE */ N_("Unconstrained move."), /* STID_WILL_DISPLAY_XBM_XPM */ N_("Will display bitmap/pixmap."), NULL }; static char *gaszEnglishStrTable500[] = { /* STID_WILL_NOT_DISPLAY_XBM_XPM */ N_("Will not display bitmap/pixmap."), /* STID_GRAY_SCALE_IN_BW_PRINTING */ N_("Gray scale enabled in black&white printing."), /* STID_NO_GRAY_SCALE_IN_BW_PRINTING */ N_("Gray scale disabled in black&white printing."), /* STID_CURRENT_SPEC_IS */ N_("( current spec: '%s' )"), /* STID_ENTER_MEASURE_UNIT_SPEC */ N_("Please enter ' {pixel|cm|in}/' (e.g., 36 in/yd or 0.1 in/mil):"), /* STID_WILL_EXPORT_FORMAT_FILE */ N_("Will export %s file."), /* STID_PRINT_DEV_SET_TO_PRINTER */ N_("Print device set to printer."), /* STID_WILL_EXPORT_EPS_FILE */ N_("Will export Encapsulated PostScript (LaTeX-Figure) file."), /* STID_WILL_EXPORT_RAW_PS_FILE */ N_("Will export raw PostScript file."), /* STID_WILL_EXPORT_XPM_FILE */ N_("Will export X11 Pixmap file."), /* STID_WILL_EXPORT_XBM_FILE */ N_("Will export X11 Bitmap file."), /* STID_WILL_EXPORT_TEXT_FILE */ N_("Will export ASCII text file."), /* STID_WILL_EXPORT_EPSI_FILE */ N_("Will export EPSI file (EPS with preview bitmap)."), /* STID_WILL_EXPORT_GIF_FILE */ N_("Will export GIF/ISMAP (needs xpm->gif filter) file."), /* STID_WILL_EXPORT_HTML_FILE */ N_("Will export HTML (with Client-side imagemap) file."), /* STID_WILL_EXPORT_PDF_FILE */ N_("Will export PDF (needs ps->pdf filter) file."), /* STID_WILL_EXPORT_TIFFEPSI_FILE */ N_("Will export DOS/Windows EPS/EPSI file."), /* STID_ONE_MOTION_SEL_MOVE_MODE */ N_("Click-select-move in one motion mode selected."), /* STID_CLICK_SEL_CLICK_MOVE_MODE */ N_("Click-select-click-move mode selected."), /* STID_CANT_TOGGLE_COLOR_LAYER_BW */ N_("Cannot toggle color layers for a black and white display."), /* STID_STRETCHABLE_TEXT_MODE */ N_("Text objects are stretchable."), /* STID_NON_STRETCHABLE_TEXT_MODE */ N_("Text objects are not stretchable."), /* STID_TRANS_PAT_MODE */ N_("Fill and pen patterns are transparent."), /* STID_NON_TRANS_PAT_MODE */ N_("Fill and pen patterns are opaque."), /* STID_ALREADY_AT_DEF_ZOOM */ N_("Already at the default zoom."), /* STID_ALREADY_AT_HIGHEST_MAG */ N_("Already at highest magnification, can no longer zoom in."), /* STID_CURSOR_IGNORED_CSBTN1 */ N_("(the cursor position is ignored even though Btn1 is used)"), /* STID_ZOOMIN_AROUND_EDIT_TEXT */ N_("(Zooming in around text being edited..."), /* STID_SEL_ZOOM_CENTER */ N_("Select zoom center"), /* STID_ZOOMIN_CANCEL_BY_USER */ N_("ZoomIn canceled by the user."), /* STID_AT_PAPER_EDGE_CANT_ZOOMOUT */ N_("Already at paper boundaries, can no longer zoom out."), /* STID_PAGE_STYLE_CHANGE_TO_LAND */ N_("Page style changed to LandScape."), /* STID_PAGE_STYLE_CHANGE_TO_PORT */ N_("Page style changed to Portrait."), /* STID_WARN_PIN_NOT_SUPPORTED */ N_("Warning: Pins are not supported, yet."), /* STID_ONE_SIMPLE_GROUP_UNGROUP_ANY */ N_("Selected object is not a (simple) grouped object.\n\nUngroup anyway?"), /* STID_ALL_SIMPLE_GROUP_UNGROUP_ANY */ N_("None of the selected objects are (simple) grouped objects.\n\nUngroup anyway?"), /* STID_SEL_OBJ_ARE_UNGROUPED */ N_("Selected objects are ungrouped."), /* STID_NO_OBJ_TO_LOCK */ N_("No object to lock."), /* STID_CANNOT_LOCK_IN_VERTEX_MODE */ N_("Cannot lock in vertex mode."), /* STID_SEL_OBJ_ARE_LOCKED */ N_("Selected objects are locked."), /* STID_NO_OBJ_TO_UNLOCK */ N_("No object to unlock."), /* STID_CANNOT_UNLOCK_IN_VERTEX_MODE */ N_("Cannot unlock in vertex mode."), /* STID_SEL_OBJ_ARE_UNLOCKED */ N_("Selected objects are unlocked."), /* STID_TOOL_VERSION */ N_("%s Version %s"), /* STID_TOOL_VERSION_SPC_BUILD */ N_("%s Version %s (%s)"), /* STID_TOOL_VERSION_PATCH */ N_("%s Version %s (patchlevel %1d)"), /* STID_TOOL_VERSION_PATCH_SPC_BUILD */ N_("%s Version %s (patchlevel %1d - %s)"), /* STID_HYPER_TEXT_HOME */ N_("\n\nWWW Hypertext Home Page: %s"), /* STID_LATEST_REL_INFO */ N_("\n\nLatest Release Information: %s"), /* STID_HYPER_GRAPHICS_INFO */ N_("\n\nWWW Hyper-Graphics Home Page: %s"), /* STID_MAILING_LIST_INFO */ N_("\n\nThe tgif announcement mailing list is %s. To join, please send an empty message to %s (you do not need a Yahoo ID to join). Additional information regarding tgif mailing lists can be found at: %s"), /* STID_SEND_BUG_REPORT_TO */ N_("\n\nPlease send bug reports to %s."), /* STID_OPEN_URL_FAIL_USE_BROWSER */ N_("Fail to open '%s' for reading.\n\nPlease view %s with a web browser."), /* STID_FIND_VER_FAIL_USE_BROWSER */ N_("Fail to find version information in '%s'.\n\nPlease view %s with a web browser."), /* STID_TOOL_CUR_VER_IS_DIFF_INFO */ N_("The latest release of %s is %s.\nThe %s you are running is Version %s.\n\nFor download information, please visit %s with a web browser."), /* STID_TOOL_CUR_VER_IS_DIFF_SPC_INFO */ N_("The latest release of %s is %s.\nThe %s you are running is Version %s (%s).\n\nFor download information, please visit %s with a web browser."), /* STID_TOOL_CUR_VER_PATCH_INFO */ N_("The latest release of %s is %s.\nThe %s you are running is Version %s Patchlevel %1d.\n\nFor download information, please visit %s with a web browser."), /* STID_TOOL_CUR_VER_PATCH_SPC_INFO */ N_("The latest release of %s is %s.\nThe %s you are running is Version %s Patchlevel %1d (%s).\n\nFor download information, please visit %s with a web browser."), /* STID_CANT_DOWNLOAD_VER_USE_BROWSER */ N_("Cannot download '%s' to get version information.\n\nPlease view %s with a web browser."), /* STID_FAIL_TO_CONN_TO_HOST_PORT */ N_("%s: Fail to connect to server on '%s:%1d'."), /* STID_LINES_TOO_LONG_CONTENT_LENGTH */ N_("%s: Unexpected lines too long detected while reading content."), /* STID_FAIL_TO_SEND_REQ */ N_("%s: Fail to send requests."), /* STID_INVALID_FORMAT_IN_HEADER */ N_("%s: Invalid format in the header."), /* STID_CHECK_FONT_FAILED_FOR_BROWSE */ N_("The current font/size/style is not available for labeling objects.\n\nPlease use a different font/size/style for the browse operation you've selected."), /* STID_ERROR_ENCOUNTERED_WHILE_RECV */ N_("%s: Error encountered in receiving responses."), /* STID_SINGLE_XPM_IMGPROC */ N_("The command you have just selected: '%s' can only work with a single X11 Pixmap object."), /* STID_USER_INTR */ N_("User interrupt."), /* STID_CANNOT_IMPORT_XPM_FILE */ N_("Cannot import X11 Pixmap file '%s'."), /* STID_MAY_USED_UP_COLORS_RETRY */ N_("May have used up all the colors.\n\nWould you like to retry it once more?"), /* STID_ENTER_PAIR_COLORS_INTERPOLATE */ N_("Please enter a pair of colors (from dark to bright) for interpolation (e.g., Black Yellow):"), /* STID_GIVEN_IS_NOT_A_VALID_COLOR */ N_("'%s' is not a valid color."), /* STID_ENTER_VAL_MINUS_PLUS_ONE_BW */ N_("Please enter a value between -1.0 (all black) and +1.0 (all white):"), /* STID_FAIL_TO_PARSE_FOR_A_VAL */ N_("Fail to parse '%s' for a value."), /* STID_ENTER_VAL_MINUS_PLUS_ONE_SAT */ N_("Please enter a value between -1.0 (gray) and +1.0 (saturated):"), /* STID_ENTER_VAL_FOR_CHANGE_HUE */ N_("Please enter two pairs of (color,angle) values: (e.g., \"red 60 green 60\" maps all reddish to greenish colors)"), /* STID_FAIL_TO_PARSE_FOR_4_VAL */ N_("Fail to parse '%s' for 4 values."), /* STID_ENTER_VAL_FOR_CONTRAST_ENH */ N_("Please enter a non-negative value (1.0 means no adjustment):"), /* STID_GIVEN_NEG_VAL_NOT_ALLOWED */ N_("Nevative value: '%s' is not allowed."), /* STID_ENTER_VAL_FOR_COLOR_BAL */ N_("Please enter non-negative R G B factors (1.0 1.0 1.0 means no change):"), /* STID_FAIL_TO_PARSE_FOR_3_VAL */ N_("Fail to parse '%s' for 3 values."), /* STID_ENTER_VAL_FOR_GAMMA */ N_("Please enter a gamma value (1.0 means no change, 2.2 is brighter):"), /* STID_SEL_TOO_THIN_FLAT_FOR_EDGE */ N_("Selected object is too thin or flat for edge detection."), /* STID_SEL_TOO_THIN_FLAT_FOR_EMBOSS */ N_("Selected object is too thin or flat for embossing."), /* STID_ENTER_NUM_COLORS_TO_REDUCE_TO */ N_("Please enter the number of colors to reduce to (from %1d colors):"), /* STID_NUM_COLORS_BETWEEN_2_N_GIVEN */ N_("Number of colors: '%s' must be between 2 and %1d."), /* STID_SEL_XPM_FILE_FOR_RED_COLORS */ N_("Please select an X11 Pixmap file for colors..."), /* STID_INVALID_GIVEN_XPM_FILE */ N_("Invalid X11 Pixmap file '%s.'"), /* STID_Q_FS_ERROR_DIFFUSE */ N_("Would you like to apply Floyd-Steinberg error diffusion (slow)?"), /* STID_ENTER_NUM_BITS_IN_RGB */ N_("Please enter number of bits to use for R, G, and B (current [R G B] levels are [%1d %1d %1d]):"), /* STID_RGB_LEVELS_CHANGED_TO */ N_("Levels changed to: [%1d %1d %1d]."), /* STID_BAD_VAL_SUM_RGB_LEVEL */ N_("Bad values: '%s'. R+G+B must be <= 8."), /* STID_BAD_VAL_GT_0_RGB_LEVEL */ N_("Bad values: '%s'. Values must all be > 0."), /* STID_RGB_LEVELS_ARE */ N_("[R G B] levels are [%1d %1d %1d]."), /* STID_ENTER_INT_AMT_TO_SPREAD */ N_("Please enter an integer amount to spread:"), /* STID_SEL_TOO_THIN_FLAT_FOR_SHARPEN */ N_("Selected object is too thin or flat for sharpening."), /* STID_SEL_TOO_THIN_FLAT_FOR_BLUR */ N_("Selected object is too thin or flat for %1d by %1d blurring."), /* STID_IMAGE_PROC_CANT_USE_XFORMED */ N_("'%s' cannot operate on stretched/rotated/sheared pixmap objects.\n\nYou can use '%s' in the ImageProc Menu to regenerate these objects."), /* STID_SEL_3_XPM_FOR_IMAGEPROC_CMD */ N_("Please select 3 X11 Pixmap object for the '%s' command."), /* STID_SEL_2_XPM_FOR_IMAGEPROC_CMD */ N_("Please select 2 X11 Pixmap object for the '%s' command."), /* STID_PICK_PT_WITHIN_IMAGE_BOUND */ N_("Please pick a starting point within the image boundary"), NULL }; static char *gaszEnglishStrTable600[] = { /* STID_IMG_TOO_SMALL_FOR_IMAGEPROC_CMD */ N_("Image is too small for the '%s' command."), /* STID_NO_WARPING */ N_("No warping."), /* STID_START_LINE_SEG_DOTS */ N_("Start line segment..."), /* STID_ENDT_LINE_SEG_DOTS */ N_("End line segment..."), /* STID_ENTER_IMAGE_SIZE_IN_PIX_RC */ N_("Please enter image size in pixels: [Col x Row]"), /* STID_FAIL_TO_EXECUTE_CMD */ N_("Fail to execute '%s'."), /* STID_ENTER_CMD_OP_FOR_BGGEN */ N_("Please enter command options for 'bggen' (e.g., 'blue magenta'):"), /* STID_NEW_XPM_WH_GENERATED */ N_("New X11 Pixmap object (%1dx%1d) generated."), /* STID_ENTER_GRAY_LEVELS_222 */ N_("Please enter number of gray levels (between 2 and 222):"), /* STID_INVALID_GIVEN_VALUE_ENTERED */ N_("Invalid value '%s' entered."), /* STID_ENTER_COLOR_FOR_RECT_BGGEN */ N_("Please enter a color for the rectangle (e.g., magenta, #808080):"), /* STID_CANNOT_PARSE_NAMED_COLOR */ N_("Cannot parse color: '%s'."), /* STID_XPM_NOT_XFORMED_REGEN_ANYWAY */ N_("Selected object is not stretched/rotated/sheared.\n\nWould you like to regenerate it anyway?"), /* STID_DRAG_A_RECT_TO_CROP */ N_("Please drag out a rectangular area to crop..."), /* STID_START_CROP_IMAGE */ N_("Start crop image"), /* STID_END_CROP_IMAGE */ N_("End crop image"), /* STID_ABORT_CROP_IMAGE */ N_("Abort crop image"), /* STID_SELECT_A_COLOR */ N_("Select a color"), /* STID_SEL_A_COLOR_TO_USE_AS_CUR */ N_("Please select a color to be used as the current color..."), /* STID_SEL_AREA_NOT_INTERSECT_IMAGE */ N_("Selected area does not intersect selected image."), /* STID_SEL_PT_NOT_ON_IMAGE */ N_("Selected point is not on the selected image."), /* STID_ONE_PRIM_FOR_IMAGEPROC_CMD */ N_("Please select only one primitive object for the '%s' command."), /* STID_DARG_TO_FILL_AN_AREA */ N_("Drag to fill an area..."), /* STID_SEL_A_COLOR_TO_BE_REPLACED */ N_("Please select a color to be replaced by the current color..."), /* STID_SEL_A_COLOR_TO_REPLACE */ N_("Select a color to replace"), /* STID_BTN1_FLOODFILL_BTN3_SET_COLOR */ N_(": Flood-fill, : Set a pixel to current color."), /* STID_ESC_TO_FINISH */ N_(" to finish."), /* STID_FLOOD_FILL */ N_("Flood-fill"), /* STID_SET_A_PIXEL */ N_("Set a pixel"), /* STID_NO_CONTOUR_CAN_BE_GEN_HERE */ N_("No contour can be generated from here."), /* STID_SEL_A_COLOR_TO_BE_TRACED */ N_("Please select a color to be traced..."), /* STID_START_CONTOUR */ N_("Start contour"), /* STID_INVALID_XDEF_RNG_USE_ALT_VAL */ N_("Invalid %s.%s: '%s', (must be between %1d and %1d), %1d is used instead."), /* STID_VAL_TOO_LARGE_IN_XDEF_USE_ALT */ N_("Values too large in %s.%s: '%s', '%s' is used instead."), /* STID_VAL_TOO_SMALL_IN_XDEF_USE_ALT */ N_("Values too small in %s.%s: '%s', '%s' is used instead."), /* STID_INVALID_GIVEN_PATH_MUST_FULL */ N_("Invalid path: '%s'. Must use a full path name."), /* STID_CANNOT_SET_LOCALE_ENV_VARS */ N_("Cannot set to the locale specified by the environment variables."), /* STID_XT_CANNOT_SET_LOCALE_ENV_VARS */ N_("Xtoolkit cannot set to the locale specified by the environment variables."), /* STID_XLIB_CANT_SET_LOCALE_ENV_VARS */ N_("Xlib cannot set to the locale specified by the environment variables."), /* STID_CANT_SET_LOCALE_MODIFIERS */ N_("Cannot set locale modifiers."), /* STID_LOCALE_DIR_NOT_EXIST_USE_XDEF */ N_("Locale directory '%s' does not exist. Please specify locale direory with %s.%s."), /* STID_WARN_CANT_PUTENV_GIVEN */ N_("Warning: Cannot putenv(%s)."), /* STID_CANT_OPEN_DISPLAY_ABORT */ N_("Could not open the default display. Abort."), /* STID_CANT_OPEN_GIVEN_DPY_ABORT */ N_("Could not open display '%s'. Abort."), /* STID_CUR_EMPTY_FILE_IS */ N_("Current (empty) file is '%s'."), /* STID_LEFT_STEP_MID_RUN_RIGHT_STOP */ N_("Left:step. Middle:run. Right:stop."), /* STID_CANT_FIND_POLY_WITH_GIVEN_ID */ N_("Cannot find poly with id=%1d."), /* STID_CANT_FIND_OBJ_WITH_GIVEN_ID */ N_("Cannot find object with id=%1d."), /* STID_CANT_FIND_ATTR_NAME_AND_COLOR */ N_("Cannot find attr name '%s' and color '%s'."), /* STID_BAD_FLTR_SPEC_DEF */ N_("Invalid %s.%s: '%s'.\n\nFormat is ' ', e.g.,\n\n JPEG jpg;jpeg djpeg -gif -colors 222 %%s | giftopnm | ppmtoxpm"), /* STID_BAD_FLTR_SPEC_MISS_PERC_S */ N_("Invalid %s.%s: '%s' (missing %%s).\n\nFormat is ' ', e.g.,\n\n JPEG jpg;jpeg djpeg -gif -colors 222 %%s | giftopnm | ppmtoxpm"), /* STID_BAD_FLTR_SPEC_MANY_PERC_S */ N_("Invalid %s.%s: '%s' (too many %%s).\n\nFormat is ' ', e.g.,\n\n JPEG jpg;jpeg djpeg -gif -colors 222 %%s | giftopnm | ppmtoxpm"), /* STID_BAD_XDEF_MUST_BE_GT_0 */ N_("Invalid %s.%s: '%s'. Value must be > 0."), /* STID_CANT_FIND_XDEF_CONT_LOOK_FLTR */ N_("Cannot find %s.%s.\n\nWould you like to continue looking for filters?"), /* STID_SEL_XBM_FILE_TO_IMPORT */ N_("Please select an X11 Bitmap file to IMPORT..."), /* STID_CANNOT_IMPORT_XBM_FILE */ N_("Cannot import X11 Bitmap file '%s'."), /* STID_ENTER_GEOM_SPEC_ORIG_SIZE */ N_("Please enter geometry spec: [[MAG=]WxH+X+Y] (original size is %1dx%1d)"), /* STID_GIVEN_XBM_SIZE_FILE_IMPORTED */ N_("X11 Bitmap file (%1dx%1d) '%s' imported."), /* STID_GIVEN_XPM_SIZE_FILE_IMPORTED */ N_("X11 Pixmap file (%1dx%1d) '%s' imported."), /* STID_SEL_XPM_FILE_TO_IMPORT */ N_("Please select an X11 Pixmap file to IMPORT..."), /* STID_SEL_EPS_FILE_TO_IMPORT */ N_("Please select an EPS file to IMPORT..."), /* STID_IMPORT_REM_FILE_EMBED_INSTEAD */ N_("Link to a remote %s file is not supported. Would you like to embed the %s file instead?"), /* STID_GIVEN_EPS_FILE_IMPORTED */ N_("EPS file '%s' imported."), /* STID_SEL_GIF_FILE_TO_IMPORT */ N_("Please select a GIF file to IMPORT..."), /* STID_CANNOT_IMPORT_GIVEN_GIF */ N_("Cannot import GIF file '%s'."), /* STID_GIVEN_GIF_SIZE_FILE_IMPORTED */ N_("GIF file (%1dx%1d) '%s' imported."), /* STID_CANT_FIND_ANY_IMP_FLTR_SPEC */ N_("Cannot find any import filter specifications.\n\nImport filters are specified with %s.%s and %s.%s X resources."), /* STID_SEL_AN_IMPORT_FILTER */ N_("Please select an import filter..."), /* STID_SEL_A_TYPE_FILE_TO_IMPORT */ N_("Please select a %s file to IMPORT..."), /* STID_CANT_IMPORT_GIVEN_TYPE_FILE */ N_("Cannot import %s file '%s'."), /* STID_GIVEN_TYPE_SIZE_FILE_IMPORTED */ N_("%s file (%1dx%1d) '%s' imported."), /* STID_INVALID_FMT_IN_SHORTCUT_SPEC */ N_("Invalid format in shortcut specification of %s(%s)."), /* STID_CANT_FIND_NAMED_IMP_FLTR */ N_("Cannot find any import filter named '%s'."), /* STID_SEL_ANIM_GIF_FILE_TO_IMPORT */ N_("Please select an animated GIF file to IMPORT..."), /* STID_CANT_EXEC_CMD_IMPORT_ANIM_GIF */ N_("Cannot execute '%s'.\n\nAnimated GIF not imported."), /* STID_Q_LIKE_TO_USE_AN_IMP_FLTR_GIF */ N_("Would you like to use an import filter when importing individual GIF files?"), /* STID_CANT_CREATE_NAMED_TMP_FILE */ N_("Cannot create temporary file: '%s'."), /* STID_CANT_IMP_ANIM_GIF_TMP_DIR */ N_("Cannot import GIF animation file '%s'. Please make sure that you can write to the '%s' directory."), /* STID_CANT_IMP_GIVEN_ANIM_GIF */ N_("Cannot import GIF animation file '%s'."), /* STID_ONLY_ONE_GIF_COMP_EXTRACTED */ N_("Only one GIF component extracted from '%s'."), /* STID_ANIMATING_GIVEN */ N_("Animating '%s'..."), /* STID_GIF_ANIMATION_STOPPED */ N_("GIF animation stopped."), /* STID_PRESS_ESC_TO_STOP */ N_("(press to stop)"), /* STID_BROWSING_DIR_FOR_TYPE_FILES */ N_("Browsing '%s' for %s files..."), /* STID_SKIP_GIVEN_FILE_SYM_LINK */ N_("Skipping '%s' because it's a symbolic link."), /* STID_WORKING_DIR_IS_GIVEN */ N_("Working directory: '%s'"), /* STID_MORE_THAN_ONE_CMAP_INSTALLED */ N_("More than one colormap installed."), /* STID_FIRST_ONE_ON_LIST_USED */ N_("First one on the list is used."), /* STID_SPECIFY_AREA */ N_("Specify area"), /* STID_SPECIFY_DELAY_FULL_SCR_CAP */ N_("Please specify a delay (in seconds) for full screen capture:"), /* STID_WILL_HIDE_TOOL_WHILE_CAPTURE */ N_("Will hide %s during capturing."), /* STID_WILL_SHOW_TOOL_WHILE_CAPTURE */ N_("Will leave %s alone during capturing."), /* STID_FUNC_SELECT_SYS_CALL_FAILED */ N_("In %s: select() system call failed."), /* STID_FUNC_INVALID_RC_FOR_SELECT */ N_("In %s: Invalid return code of %1d from the select() system call."), /* STID_CNTRL_C_ABORT_LAUNCH */ N_("You have typed a ^C. Do you want to abort the command that's being executed? (If the command is running in an xterm, please try killing or destroying the xterm from the desktop first before doing an abort.)"), /* STID_CMD_ABORT_LAUNCH_CLOSE_TOOL */ N_("The '%s' command is aborted.\n\nHowever, it's not safe to actually kill the command. Therefore, please close %s at the next convenient point."), /* STID_INVALID_GIVEN_ATTR_SPEC */ N_("Invalid attribute specification: '%s'."), /* STID_LAUNCH_NOT_AUTO_IN_HYPER_EXEC */ N_("Launching is not automatic in hyperspace. Do you want to execute the following command?\n\n %s\n\n(If you are not sure about this, just click on NO.)"), /* STID_USER_ABORT_LAUNCH_IN_HYPER */ N_("Launching in hyperspace aborted at user's request."), /* STID_MALFORMED_CMD_EXEC_ABORT */ N_("Malformed '%s' command.\n\nCommand execution aborted."), NULL }; static char *gaszEnglishStrTable700[] = { /* STID_NO_OBJ_SEL_WHILE_EXEC_CMD */ N_("No object is selected while executing the '%s' command."), /* STID_CANT_FIND_NAMED_ATTR_EXEC */ N_("Cannot find the '%s' attribute while executing the '%s' command."), /* STID_FILE_ATTR_NOT_ALLOWED_FOR_CMD */ N_("File attribute '%s' is not appropriate for the '%s' command."), /* STID_CANT_FIND_NAMED_OBJ_EXEC */ N_("Cannot find object named '%s' while executing the '%s' command."), /* STID_INVALID_ARG_WHILE_EXEC_CMD */ N_("Invalid '%s' while executing the '%s' command."), /* STID_MODIFY_FILE_ATTR_IN_WB */ N_("Cannot modify file attributes in WhiteBoard mode."), /* STID_USER_INTR_TOOL_WAIT_CLEANUP */ N_("User interrupt received. %s is waiting for clean up to complete.\n\nAre you sure you don't want to wait for clean up to complete (this may leave the scripts in an inconsistent state)?"), /* STID_FUNC_USER_INTR */ N_("%s(): User interrupt."), /* STID_BAD_EVAL_INT_EXP_EXEC_CMD */ N_("Invalid evaluation '%s' used (integer expected) while executing the '%s' command."), /* STID_BAD_EVAL_FLOAT_EXP_EXEC_CMD */ N_("Invalid evaluation '%s' used (floating pointer number expected) while executing the '%s' command."), /* STID_FAIL_FUNC_CMD_EXEC_ABORT */ N_("Fail to %s. Command execution aborted."), /* STID_FUNC_ONLY_WORK_COMPOSITE_OBJ */ N_("%s() only works with composite objects."), /* STID_FUNC_FAIL_TO_IMPORT_GIVEN */ N_("%s(): Fail to import '%s'."), /* STID_FUNC_OBJ_NON_XBM_XPM_SUB_OBJS */ N_("%s(): Object contains non-Bitmap/Pixmap sub-objects."), /* STID_WILL_EXPORT_PNG_FILE */ N_("Will export PNG (needs xpm->png filter) file."), /* STID_CANNOT_IMPORT_GIVEN_PNG */ N_("Cannot import PNG file '%s'."), /* STID_GIVEN_PNG_SIZE_FILE_IMPORTED */ N_("PNG file (%1dx%1d) '%s' imported."), /* STID_SEL_PNG_FILE_TO_IMPORT */ N_("Please select a PNG file to IMPORT..."), /* STID_FUNC_DIFF_SZ_XBM_XPM_SUBOBJS */ N_("%s(): Different sizes Bitmap/Pixmap sub-objects."), /* STID_FUNC_MORE_1_XBM_XPM_SUBOBJS */ N_("%s(): Must have > 1 Bitmap/Pixmap sub-objects."), /* STID_FUNC_ARG_RANGE */ N_("%s(): '%s' must be between %1d and %1d (inclusive).\n\n%1d was specified."), /* STID_FUNC_UNDEFINED_ARG */ N_("%s(): Undefined '%s'."), /* STID_INTERNAL_CMD_SELECT_FAILED */ N_("%s(): select() system call failed."), /* STID_CANT_OPEN_FILE_READ_EXEC_CMD */ N_("Cannot open '%s' for reading while executing the '%s' command."), /* STID_FAIL_TO_EXECUTE_CMD_EXEC_CMD */ N_("Fail to execute '%s' while executing the '%s' command."), /* STID_UNEXP_ERR_EXEC_CMD_ABORT */ N_("Unexpected error while executing the '%s' command.\n\nCommand execution aborted."), /* STID_BAD_NAME_TOP_LEVEL_ONLY_CMD */ N_("Bad object name: '%s'.\n\nOnly top level object can be selected while executing the '%s' command."), /* STID_BAD_CURSOR_WHILE_EXEC_CMD */ N_("Cannot create the '%s' cursor while executing the '%s' command."), /* STID_BAD_COLOR_NAME_WHILE_EXEC_CMD */ N_("Fail to allocate the '%s' color while executing the '%s' command."), /* STID_WIDTH_RANGE_WHILE_EXEC_CMD */ N_("Line width of '%s' is out of range while executing the '%s' command."), /* STID_SPLINE_TYPE_WHILE_EXEC_CMD */ N_("Invalid spline type of '%s' used while executing the '%s' command."), /* STID_ARROW_STYLE_WHILE_EXEC_CMD */ N_("Invalid arrow style of '%s' used while executing the '%s' command."), /* STID_DASH_INDEX_WHILE_EXEC_CMD */ N_("Invalid dash index of '%s' used while executing the '%s' command."), /* STID_RCB_RAD_RANGE_WHILE_EXEC_CMD */ N_("Rcbox radius of '%s' is out of range while executing the '%s' command."), /* STID_BAD_TEXT_JUST_WHILE_EXEC_CMD */ N_("Invalid text justification of '%s' used while executing the '%s' command."), /* STID_BAD_FONT_NAME_WHILE_EXEC_CMD */ N_("Invalid font name of '%s' used while executing the '%s' command."), /* STID_UNDO_BUF_FLUSHED_BY_CMD */ N_("Undo buffer flushed by %s()."), /* STID_BAD_EVAL_NUM_EXP_EXEC_CMD */ N_("Invalid evaluation '%s' used (numeric value expected) while executing the '%s' command."), /* STID_WRITE_CUT_BUF_WHILE_EXEC_CMD */ N_("Writing to cut buffer failed while executing the '%s' command."), /* STID_CANT_FIND_DOT_WHILE_EXEC_CMD */ N_("Cannot find '.' in '%s%c%s' while executing the '%s' command."), /* STID_BAD_WIDTH_WHILE_EXEC_CMD */ N_("Invalid width of '%s' used while executing the '%s' command."), /* STID_BAD_HEIGHT_WHILE_EXEC_CMD */ N_("Invalid height of '%s' used while executing the '%s' command."), /* STID_BAD_STYLE_WHILE_EXEC_CMD */ N_("Invalid style of '%s' used while executing the '%s' command."), /* STID_TOO_MANY_OBJ_WHILE_EXEC_CMD */ N_("Too many objects selected while executing the '%s' command."), /* STID_BAD_ATTR_NAME_WHILE_EXEC_CMD */ N_("Illegal attribute name '%s' used while executing the '%s' command."), /* STID_END_AN_EDGE_AT_A_PORT */ N_("Please end an edge at a port..."), /* STID_DRAW_AN_EDGE_BETWEEN_PORTS */ N_("Please draw an edge between ports..."), /* STID_CANT_FIND_VRTX_WHILE_EXEC_CMD */ N_("Cannot find vertex %1d for an object named '%s' while executing the '%s' command."), /* STID_POLY_NOR_PGON_WHILE_EXEC_CMD */ N_("'%s' is neither a poly nor a polygon object while executing the '%s' command."), /* STID_BAD_REM_FNAME_WHILE_EXEC_CMD */ N_("Invalid remote file name '%s' used while executing the '%s' command."), /* STID_CANT_OPEN_FILE_WRITE_EXEC_CMD */ N_("Cannot open '%s' for writing while executing the '%s' command."), /* STID_GIVEN_CMD_EXECUTED */ N_("%s() command executed."), /* STID_SQRT_NEG_NUM_WHILE_EXEC_CMD */ N_("%s() domain error: Cannot take square-root of a negative number."), /* STID_CMD_NOT_AVAIL_ON_PLATFORM */ N_("The %s() command is not available on this platform."), /* STID_BAD_SHORTCUT_WHILE_EXEC_CMD */ N_("Invalid shortcut name '%s' used while executing the '%s' command."), /* STID_STAT_FAILED_WHILE_EXEC_CMD */ N_("Fail to get file info for '%s' while executing the '%s' command."), /* STID_NON_GROUPED_WHILE_EXEC_CMD */ N_("Non-compound object named '%s' specified while executing the '%s' command."), /* STID_BAD_SEP_LONG_WHILE_EXEC_CMD */ N_("Invalid separator '%s' specified while executing the '%s' command.\n\n(Separator must be a single charactor.)"), /* STID_BAD_SEP_WHILE_EXEC_CMD */ N_("Invalid separator '%s' specified while executing the '%s' command."), /* STID_MORE_THAN_ONE_WHILE_EXEC_CMD */ N_("More than one object selected while executing the '%s' command."), /* STID_MUST_FULL_PATH_WHILE_EXEC_CMD */ N_("Invalid path: '%s' specified while executing the '%s' command.\n\n(Must use an absolute path.)"), /* STID_OBJ_ALRDY_SEL_WHILE_EXEC_CMD */ N_("Object named '%s' is already selected while executing the '%s' command."), /* STID_INVALID_FNAME_WHILE_EXEC_CMD */ N_("Invalid file name '%s' specified while executing the '%s' command."), /* STID_INVALID_FMODE_WHILE_EXEC_CMD */ N_("Invalid file mode '%s' specified while executing the '%s' command."), /* STID_INVALID_FNUM_WHILE_EXEC_CMD */ N_("Invalid file number '%s' specified while executing the '%s' command."), /* STID_FNUM_ARDY_OPEN_WHILE_EXEC_CMD */ N_("File number %1d is already opened while executing the '%s' command."), /* STID_CANT_OPEN_FMOD_WRITE_EXEC_CMD */ N_("Cannot open '%s' in the '%s' mode for writing while executing the '%s' command."), /* STID_FNUM_NOT_OPEN_WHILE_EXEC_CMD */ N_("File number %1d is not opened while executing the '%s' command."), /* STID_EOF_FOR_FNUM_WHILE_EXEC_CMD */ N_("Cannot read beyond the end-of-file for file number %1d while executing the '%s' command."), /* STID_WRI_FNUM_FAIL_WHILE_EXEC_CMD */ N_("Fail to write to file number %1d while executing the '%s' command."), /* STID_WRI_FNN_FAIL_WHILE_EXEC_CMD */ N_("Fail to write to file number %1d ('%s') while executing the '%s' command."), /* STID_INVALID_PATH_WHILE_EXEC_CMD */ N_("File '%s' does not exist while executing the '%s' command."), /* STID_APPEND_FAILED_WHILE_EXEC_CMD */ N_("Appending '%s' to '%s' failed while executing the '%s' command."), /* STID_COPY_FAILED_WHILE_EXEC_CMD */ N_("Copying '%s' to '%s' failed while executing the '%s' command."), /* STID_INVALID_FORMAT_WHILE_EXEC_CMD */ N_("Invalid format '%s' specified while executing the '%s' command."), /* STID_INVALID_REC_WHILE_EXEC_CMD */ N_("Invalid rectangle '(%d,%d,%d,%d)' specified while executing the '%s' command."), /* STID_CONVERT_FORMAT_WHILE_EXEC_CMD */ N_("Fail to convert '%s' from the '%s' format to XPM format while executing the '%s' command."), /* STID_IMPORT_FAILED_WHILE_EXEC_CMD */ N_("Fail to import '%s' while executing the '%s' command."), /* STID_BAD_VER_NUM_WHILE_EXEC_CMD */ N_("Invalid version number '%1d' specified while executing the '%s' command."), /* STID_EMPTY_INI_SEC_WHILE_EXEC_CMD */ N_("The [%s] section of '%s' is empty or non-existent while executing the '%s' command."), /* STID_BAD_LINENUM_WHILE_EXEC_CMD */ N_("Invalid line number '%1d' specified while executing the '%s' command."), /* STID_BAD_SMALL_LNUM_WHILE_EXEC_CMD */ N_("Invalid line number '%1d' (too small) specified while executing the '%s' command."), /* STID_BAD_EMPTY_STR_WHILE_EXEC_CMD */ N_("Invalid empty string specified while executing the '%s' command."), /* STID_BAD_DIRECTION_WHILE_EXEC_CMD */ N_("Invalid direction '%s' specified while executing the '%s' command."), /* STID_NO_START_VRTX_WHILE_EXEC_CMD */ N_("No starting vertex specified while executing the '%s' command."), /* STID_TOO_FEW_VRTX_WHILE_EXEC_CMD */ N_("Too few vertices (%1d) specified while executing the '%s' command."), /* STID_NO_START_OBJ_WHILE_EXEC_CMD */ N_("No starting object specified by %s() while executing the '%s' command."), /* STID_CANT_FIND_MARK_WHILE_EXEC_CMD */ N_("Cannot find the object marker for %s() while executing the '%s' command."), /* STID_NO_OBJ_GROUP_WHILE_EXEC_CMD */ N_("No object to group while executing the '%s' command."), /* STID_CANT_GRP_SNGL_WHILE_EXEC_CMD */ N_("Cannot group a single object while executing the '%s' command."), /* STID_UNRECOG_CMD_MAY_BE_BLANKS_ABT */ N_("Unrecognized command: '%s' (may be caused by illegal trailing blanks in command name).\n\nCommand execution aborted."), /* STID_UNRECOG_CMD_DOWNLOAD_TOOL */ N_("Unrecognized command: '%s'.\n\nCommand execution aborted.\n\nIt is possible that the command is supported in a newer version of %s. Please visit '%s' to download the latest release."), /* STID_UNRECOG_CMD_ABORT */ N_("Unrecognized command. Command execution aborted."), /* STID_TOOL_NOT_DONE_WITH_PREV_FUNC */ N_("%s is not finished with the previous %s yet."), /* STID_ENTER_INTERN_CMD_FILE_NAME */ N_("Please specify the file name for a %s internal command file (enter '-' for standard input)."), /* STID_FINISH_EXEC_CMD_FROM_STDIN */ N_("Finished executing commands from the standard input."), /* STID_FATAL_ERROR_IN_FUNC_PLUS_DESC */ N_("Fatal Error in %s: %s"), /* STID_TOOL_ABORTED */ N_("%s aborted."), /* STID_ICON_FILEVER_TOO_LARGE */ N_("Icon file version too large (=%1d)."), /* STID_UNEQUAL_DEPTHS_IN_FUNC */ N_("Unequal depths in %s."), NULL }; static char *gaszEnglishStrTable800[] = { /* STID_BASELINE_YS_NOT_EQ_IN_FUNC */ N_("Error: left_baseline_y != right_baseline_y in %s."), /* STID_LOCKED_OBJS_CANT_BE_MOVED */ N_("Locked object(s) cannot be moved."), /* STID_HINT_CTL_MOVE_ATTR_ONLY */ N_("(HINT: You can hold down key to move only the attribute under the cursor.)"), /* STID_OUT_OF_VMEM_CANNOT_MALLOC */ N_("Out of virtual memory and cannot malloc()."), /* STID_CANT_ALLOC_BITMAP_OF_SIZE */ N_("Cannot allocate bitmap of size %1dx%1d."), /* STID_FAIL_TO_WRITE_TO_FILE */ N_("Fail to write to '%s'. File system may be full."), /* STID_SAFEST_SAVE_N_EXIT_REPRODUCE */ N_("Safest thing to do is to save file and exit.\nPlease try to reproduce this error and\n\tsend bug report to %s."), /* STID_FATAL_UNEXPECTED_ERROR */ N_("Fatal Unexpected Error: %s%s%s\n\nSafest thing to do is to save file and exit.\n\nPlease try to reproduce this error and send bug report to %s."), /* STID_ENTER_FNAME_TO_WRITE_MSG_BUF */ N_("Please enter a file name to write the message buffer content:"), /* STID_STDOUT_STDERR_ESC_CANCEL */ N_("( \"stdout\", \"stderr\", : cancel )"), /* STID_MSG_BUF_SAVED_INTO_GIVEN */ N_("Message buffer saved into '%s'."), /* STID_FILE_LINE_MISS_FIELD_IN_OBJ */ N_("%s, %d: Missing %s in %s object."), /* STID_FILE_LINE_BAD_FIELD_IN_OBJ */ N_("%s, %d: Bad %s in %s object."), /* STID_NAMED_SIG_RECV */ N_("%s signal received."), /* STID_ERR_COUNT_EXCEED_TOOL_ABORTED */ N_("Error count exceeds %1d in %s. %s aborted."), /* STID_WORKING_FILE_SAVED_TO */ N_("Working file saved to '%s.%s'."), /* STID_UNABLE_TO_SAVE_WORKING_FILE */ N_("Unable to save working file."), /* STID_X_ERROR_MSG */ N_("X Error: %s."), /* STID_BAD_COMPILE_OPT_USE_ALT_STR */ N_("Invalid compiler option %s=\"%s\", \"%s\" is used instead."), /* STID_MISSING_DISPLAY_NAME */ N_("Missing display name."), /* STID_MISSING_PAGE_NUMBER */ N_("Missing page number."), /* STID_INVALID_GIVEN_PAGE_NUMBER_STR */ N_("Invalid page number: '%s'."), /* STID_MISSING_ARG_FOR_CMDLINE_OPT */ N_("Missing command line argument for '%s'."), /* STID_INVALID_ARG_FOR_CMDLINE_OPT */ N_("Invalid command line argument for '%s': '%s'."), /* STID_TGIF_PATH_SHOULD_NOT_BE_USED */ N_("Warning: -tgif_path should not be used!"), /* STID_PRINT_TO_PRINTER_INCOMPAT */ N_("Printing to printer is incompatible with '%s'."), /* STID_BAD_EXEC_FNAME_DASH */ N_("Invalid exec file name (cannot start with '-')."), /* STID_CANNOT_OPEN_DIR_FOR_READING */ N_("Cannot open the '%s' directory for reading."), /* STID_FAIL_TO_STAT_GIVEN_FILE */ N_("Fail to stat() '%s'."), /* STID_SET_WORKING_DIR */ N_("SetWorkingDir"), /* STID_CLICK_SETWORKDIR_TO_SET_DIR */ N_("Click on the 'SetWorkingDir' button to set Open/SaveAs directory."), /* STID_SETWORKDIR_NOT_SUP_FOR_STR */ N_("SetWorkingDir not supported for '%s'."), /* STID_OPENSAVE_DIR_CHANGE_TO_REMAIN */ N_("Current open/save directory change to '%s'.\n\n(Current import directory remains '%s'.)"), /* STID_IMPORT_DIR_CHANGED_TO_REMAIN */ N_("Current import directory changed to '%s'.\n\n(Current open/save directory remains '%s'.)"), /* STID_GEN_LIST_OF_DOMAIN_NAMES_WAIT */ N_("Generating list of domain names, please wait..."), /* STID_CANT_GEN_DOM_NAMES_INI_ENTRY */ N_("Fail to generate a list of domain names.\n\nCannot find the '%s' entry in the [%s] section of '%s'."), /* STID_CANT_GEN_DOM_NAMES_XDEF */ N_("Fail to generate a list of domain names.\n\nCannot find %s.%s%1d."), /* STID_CANT_GET_LIST_OF_DOM_NAMES */ N_("Fail to get a list of domain names."), /* STID_PLEASE_SELECT_A_NEW_DOMAIN */ N_("Please select a new DOMAIN..."), /* STID_CURRENT_DOMAIN_IS */ N_("Current domain is '%s'."), /* STID_SYMBOL_PATH_SET_TO */ N_("Symbol path set to '%s'."), /* STID_PLS_SEL_A_DIR_IN_GIVEN_DOMAIN */ N_("Please select a DIRECTORY in the '%s' domain..."), /* STID_GEN_LIST_XBM_NAMES_WAIT */ N_("Generating list of bitmap names, please wait..."), /* STID_GEN_LIST_XPM_NAMES_WAIT */ N_("Generating list of pixmap names, please wait..."), /* STID_GEN_LIST_OBJ_NAMES_WAIT */ N_("Generating list of object file names, please wait..."), /* STID_GEN_LIST_SYM_NAMES_WAIT */ N_("Generating list of symbol names, please wait..."), /* STID_GEN_LIST_TYPE_FILE_NAMES_WAIT */ N_("Generating list of %s file names, please wait..."), /* STID_NO_GIVEN_TYPE_FILE_FOUND */ N_("No '%s' file found."), /* STID_NO_DIR_SEP_IN_FUNC_WORK_DIR */ N_("Error: No directory-separator found in %s.\n\nCurrent working directory set to '%s'."), /* STID_NO_DIR_SEP_IN_FUNC_SYM_DIR */ N_("Error: No directory-separator found in %s.\n\nCurrent symbol directory set to '%s'."), /* STID_NO_DIR_SEP_IN_FUNC_IMPORT_DIR */ N_("Error: No directory-separator found in %s.\n\nCurrent import directory set to '%s'."), /* STID_EMPTY_PATH_DISALLOW_FOR_DOM */ N_("Empty path is not allowed for the '%s' domain."), /* STID_TOOL_EDIT_DOM_PATHS */ N_("%s - Edit Domain Paths"), /* STID_EDIT_DOMAIN_PATHS_DOTS */ N_("Edit domain paths..."), /* STID_TOOL_SEL_DEFAULT_DOMAIN */ N_("%s - Select A Default Domain"), /* STID_SEL_DEFAULT_DOMAIN_DOTS */ N_("Please select a default domain..."), /* STID_PLS_SPEC_A_NEW_DOMAIN_NAME */ N_("Please specify a new domain name:"), /* STID_GIVEN_DOMAIN_ALREADY_EXISTS */ N_("Domain '%s' already exists!"), /* STID_GIVEN_DOM_ADDED_PATH_SET_TO */ N_("Domain '%s' added. Path set to \"%s\"."), /* STID_SEL_DOMAIN_TO_DELETE_DOTS */ N_("Please select a domain to delete..."), /* STID_OK_TO_DELETE_NAMED_DOMAIN_YNC */ N_("Okay to delete the '%s' domain? [ync](y)"), /* STID_OK_TO_RELOAD_DOM_INFO_FROM_X */ N_("Okay to reload domain information from X defaults? [ync](y)"), /* STID_ERR_IN_PARSE_STR_FOR_2_VAL */ N_("Error in parsing '%s' for 2 values."), /* STID_FILE_MOD_SAVE_BEFORE_BACK */ N_("File modified, save file before going back? [ync](y)"), /* STID_NOTHING_TO_GO_BACK_TO */ N_("Nothing to go back to."), /* STID_FILE_MOD_SAVE_BEFORE_FORWARD */ N_("File modified, save file before going forward? [ync](y)"), /* STID_NOTHING_TO_GO_FORWARD_TO */ N_("Nothing to go forward to."), /* STID_FAIL_TO_FIND_RECORD_IN_FUNC */ N_("Fail to find record in AdjustNavigate()."), /* STID_FURTHER_NAVIGATE_MAY_CRASH */ N_("Further navigating may crash."), /* STID_CANT_REFRESH_UNDEFINED_FILE */ N_("Canot refresh an undefined file."), /* STID_FILE_MOD_SAVE_BEFORE_RELOAD */ N_("File modified, save file before going reloading? [ync](y)"), /* STID_HOT_LIST_FILE_UNDEF_PLS_SPEC */ N_("Hot list file undefined. Please specify it in %s.%s."), /* STID_MALFORMED_NAMED_HOT_LIST_FILE */ N_("Malformed hot list file '%s'."), /* STID_HOT_LIST_FILE_IS_EMPTY */ N_("Hot list file is empty."), /* STID_Q_DEL_NAMED_FROM_HOT_LIST */ N_("Would you like to delete '%s' from the hot list? [ync](y)"), /* STID_FILE_MOD_SAVE_BEFORE_OPEN_ANO */ N_("File modified, save file before opening another file? [ync](y)"), /* STID_SESSION_HIST_NOT_ESTABLISHED */ N_("Sesion history has not been established yet."), /* STID_TOOL_HOT_LIST */ N_("%s - Hot List"), /* STID_TOOL_HISTORY */ N_("%s - History"), /* STID_HOT_LIST_DOTS */ N_("Hot list..."), /* STID_CANT_ADD_UNDEF_TO_HOT_LIST */ N_("Cannot add an undefined file to hot list."), /* STID_HOT_LIST_FILE_UPDATED */ N_("Hot list file updated."), /* STID_SESSION_HISTORY_DOTS */ N_("Session history..."), /* STID_ENTER_HYPERSPACE_DOTS */ N_("Enter hyperspace..."), /* STID_LEAVING_HYPERSPACE_DOTS */ N_("Leaving hyperspace..."), /* STID_CANT_SLIDESHOW_IN_TILED_PAGE */ N_("Cannot enter slideshow mode in TILED page mode. Would you like to switch to STACKED page mode (and mark the file unsavable) then proceed? [ync](y)"), /* STID_FILE_MOD_SAVE_BEFORE_SLIDE */ N_("File modified, save file before entering slideshow mode? [ync](y)"), /* STID_PAGE_NUM_MOD_IN_SLIDE_NOT_SAV - this string is not used! */ N_("Page numbers will be modified by %s in slideshow mode. It's probably a good idea NOT to do a Save() until you've re-opened the file."), /* STID_Q_PAGE_NUM_MOD_IN_SLIDE_YNC */ N_("Page numbers will be modified by %s in slideshow mode. The file will be marked unsavable if you continue.\n\nOkay to mark the file unsavable and enter slideshow mode? [ync](y)"), /* STID_ENTERING_SLIDESHOW_DOTS */ N_("Entering slideshow..."), /* STID_LEAVING_SLIDESHOW_DOTS */ N_("Leaving slideshow..."), /* STID_ENTER_A_COLOR_FOR_SLIDE_BRDR */ N_("Please enter a color for the slideshow border:"), /* STID_PRESS_ENTER_FOR_DEF_COLOR */ N_("( just press for the default color )"), /* STID_SLIDE_WILL_USE_DEF_BRDR_COLOR */ N_("Slideshow will use default border color."), /* STID_SLIDE_BRDR_COLOR_SET_TO_NAMED */ N_("Slideshow border color set to '%s'."), /* STID_ENTER_XY_OFFSET_FOR_SLIDE_WIN */ N_("Please enter X and Y offsets for the slideshow window: [current: %1d,%1d]"), /* STID_SLIDE_WIN_XY_OFFSETS_SET_TO */ N_("Slideshow window offsets set to: %1d, %1d."), /* STID_GRID_BE_VISIBLE_IN_SLIDE */ N_("Grid will be visible in slideshow mode."), /* STID_GRID_NOT_BE_VISIBLE_IN_SLIDE */ N_("Grid will not be visible in slideshow mode."), /* STID_CANT_DO_NEXTPAGE_IN_TILED */ N_("Cannot do NextPage() in TILED page mode."), NULL }; static char *gaszEnglishStrTable900[] = { /* STID_ALREADY_AT_LAST_PAGE */ N_("Already at last page."), /* STID_CANT_DO_PREFPAGE_IN_TILED */ N_("Cannot do PrevPage() in TILED page mode."), /* STID_ALREADY_AT_FIRST_PAGE */ N_("Already at first page."), /* STID_TOOL_NAME_PAGES */ N_("%s - Name Pages"), /* STID_TOOL_GOTO_PAGE */ N_("%s - Goto Page"), /* STID_CANT_DO_GOTOPAGE_IN_TILED */ N_("Cannot do GotoPage() in TILED page mode."), /* STID_GOTO_PAGE_DOTS */ N_("Goto page..."), /* STID_NO_PAGE_SELECTED */ N_("No page selected."), /* STID_INVALID_GIVEN_PAGE_NUMBER */ N_("Invalid page number '%1d'."), /* STID_ALREADY_AT_GIVEN_PAGE */ N_("Already at page %1d."), /* STID_CUR_PAGE_IS_GIVEN_PAGE_NUM */ N_("Current page is page %1d."), /* STID_CANT_DO_NAMEPAGES_IN_TILED */ N_("Cannot do NamePages() in TILED page mode."), /* STID_EDIT_PAGE_NAMES_DOTS */ N_("Edige page names..."), /* STID_CANT_EDITPAGEFNAME_IN_TILED */ N_("Cannot do EditPageFileNames() in TILED page mode."), /* STID_EDIT_PAGE_FILE_NAMES_DOTS */ N_("Edige page file names..."), /* STID_PAGE_FNAME_NO_SPACE_TRUNC */ N_("Page file name: '%s' must not contain space characters. It is truncated to '%s'."), /* STID_OK_TO_FLUSH_UNDO_AND_PROCEED */ N_("Okay to flush the undo buffer and proceed? [ync](y)"), /* STID_ADD_PAGE_BEFORE_GIVEN_FLUSH */ N_("Adding a page before page %1d will cause the undo buffer to be flushed."), /* STID_ADD_PAGE_AFTER_GIVEN_FLUSH */ N_("Adding a page after page %1d will cause the undo buffer to be flushed."), /* STID_DELETE_GIVEN_PAGE_CAUSE_FLUSH */ N_("Deleting page %1d will cause the undo buffer to be flushed."), /* STID_DELETE_A_PAGE_CAUSE_FLUSH */ N_("Deleting a page will cause the undo buffer to be flushed."), /* STID_DELETE_PAGES_PAGE_CAUSE_FLUSH */ N_("Deleting pages will cause the undo buffer to be flushed."), /* STID_CHNG_PAGE_LAYOUT_FLUSH */ N_("Changing the page layout mode will cause the undo buffer to be flushed."), /* STID_SET_PAPER_COLOR_CAUSE_FLUSH */ N_("Setting paper color will cause the undo buffer to be flushed."), /* STID_CANT_DO_ADDPAGE_IN_TILED */ N_("Cannot do AddPage() in TILED page mode."), /* STID_CANT_DO_DELETEPAGE_IN_TILED */ N_("Cannot do DeleteCurrentPage() in TILED page mode."), /* STID_CANT_DEL_ONLY_PAGE_IN_TILED */ N_("Cannot delete (the only) page in TILED page mode."), /* STID_CANT_DO_SPECDRAWSIZE_IN_TILED */ N_("Cannot do SpecifyDrawingSize() in TILED page mode."), /* STID_CANT_DO_DELETEPAGES_IN_TILED */ N_("Cannot do DeletePages() in TILED page mode."), /* STID_CANT_DO_POFPP_IN_TILED */ N_("Cannot do PrintOneFilePerPage() in TILED page mode."), /* STID_CANT_DO_POFPP_TO_PRINTER */ N_("Cannot do PrintOneFilePerPage() to printer."), /* STID_NAMED_TEMPLATE_LOADED */ N_("Template loaded: '%s'."), /* STID_PROB_LOADING_NAMED_TEMPLATE */ N_("Problem loading template file '%s'."), /* STID_GIVEN_PAGE_NUM_ADDED */ N_("Page %1d added."), /* STID_ADDPAGEBEFORE_IN_WB */ N_("AddPageBefore() is disabled in WhiteBoard mode."), /* STID_ADDPAGEAFTER_IN_WB */ N_("AddPageAfter() is disabled in WhiteBoard mode."), /* STID_GIVEN_PAGE_NUM_DELETED */ N_("Page %1d deleted."), /* STID_CANT_TPLS_IN_STACKED */ N_("Cannot TogglePageLineShown() in STACKED page mode."), /* STID_ENTER_DRAW_SIZE_SPEC_WH */ N_("Please enter drawing size specification: [W x H]"), /* STID_BAD_DRAW_SIZE_SPEC_WH */ N_("Invalid drawing size specification.\n\nMust specify both Width and Height."), /* STID_BAD_DRAW_SIZE_SPEC_W_TIMES_H */ N_("Invalid drawing size specification: W times H should be >= %1d."), /* STID_INVALID_DRAW_SIZE_SPEC */ N_("Invalid drawing size specified."), /* STID_CANT_PRINTONEPAGE_IN_FORMAT */ N_("Cannot do PrintOnePage() in the '%s' format."), /* STID_BTN1_SEL_PAGE_TO_PRINT */ N_("Left button selects a page to print,"), /* STID_OTHER_BTN_CANCEL_PRINTONEPAGE */ N_("other buttons cancel printing one page."), /* STID_SELECT_A_PAGE_TO_PRINT */ N_("Select a page to print"), /* STID_OPERATION_CANCEL_BY_USER */ N_("Operation canceled by the user."), /* STID_MUST_SEL_A_PT_ON_THE_PAPER */ N_("Must select a point on the paper."), /* STID_MUST_SEL_A_PT_IN_TOOL_WIN */ N_("Must select a point within the %s window."), /* STID_NEW_PAPER_SIZE_IS_GIVEN */ N_("New paper size: %.2fin x %.2fin (%.2fcm x %.2fcm)."), /* STID_INVALID_GIVEN_PAPER_SIZE_SPEC */ N_("Invalid paper size specification: '%s'."), /* STID_CUR_PAPER_SIZE_IS_GIVEN */ N_("( current paper size: '%s' )"), /* STID_ENTER_PAPER_SIZE_WH */ N_("Please enter physical paper size: [W x H] (e.g., 8.5in x 11in)"), /* STID_CANT_DEL_ONLY_PAGE_IN_STACKED */ N_("Cannot delete (the only) page."), /* STID_SPECIFY_PAGES_TO_DEL_EX */ N_("Please specify pages to delete: (e.g., 2,3,7-9,10)"), /* STID_GIVEN_PAGE_NUM_IS_OUT_OF_RNG */ N_("Page %1d is out of range."), /* STID_MALFORMED_SPECIFICATION_STR */ N_("Malformed specification: '%s'."), /* STID_CANT_DEL_ALL_PAGES */ N_("Cannot delete all pages."), /* STID_ONE_PAGE_DELETED */ N_("1 page deleted."), /* STID_MANY_PAGES_DELETED */ N_("%1d pages deleted."), /* STID_OBJ_OUTSIDE_PAGE_BNRDY_SWITCH */ N_("There are objects outside the page boundary.\n\nCannot switch to TILED mode."), /* STID_SWTCH_TO_TILED_LOSE_ALL_NAMES */ N_("Switching from TILED to STACKED mode loses all page names and page file names.\n\nOk to proceed? [ync](y)"), /* STID_CHANGE_PAGE_LAYOUT_MODE_IN_WB */ N_("Changing page layout mode is disabled in WhiteBoard mode."), /* STID_PAGE_LAYOUT_MODE_IS_STACKED */ N_("Page layout mode is STACKED."), /* STID_PAGE_LAYOUT_MODE_IS_TILED */ N_("Page layout mode is TILED."), /* STID_SPECIFY_A_PAPER_COLOR */ N_("Please specify a paper color:"), /* STID_SPECIFY_A_PAPER_COLOR_CUR_IS */ N_("Please specify a paper color: [current: %s]"), /* STID_ENTER_NONE_TO_REMOVE_COLOR */ N_("( Enter 'None' to remove the current paper color. )"), /* STID_PAPER_COLOR_REMOVED */ N_("Paper color removed."), /* STID_PAPER_COLOR_SET_TO_GIVEN */ N_("Paper color set to '%s'."), /* STID_GRAY_SCALE_USED_IN_PRINT_PAT */ N_("Gray scale used in printing tiling patterns."), /* STID_NOTE_SLOW_PRINT_DUE_USE_PAT */ N_("Note: slow printing due to the use of patterns."), /* STID_SUGGEST_USEGRAYSCALE_TO_SPEED */ N_("You may want to try UseGrayScale() to speed things up."), /* STID_FILL_PEN_PAT_OPAQUE */ N_("Fill and pen patterns are opaque."), /* STID_FILL_PEN_PAT_TRANSPARENT */ N_("Fill and pen patterns are transparent."), /* STID_LINE_WIDTH_SET_TO_GIVEN_STR */ N_("Line width set to %s."), /* STID_ENTER_LINE_WIDTH_OPT_AW_AH */ N_("Please enter line width (arrow width and height are optional):"), /* STID_INVALID_GIVEN_STR_WIDTH */ N_("Invalid width: '%s'."), /* STID_INVALID_GIVEN_STR_AW_AH */ N_("Invalid arrow width and height: '%s %s'."), /* STID_NO_PINS_FOUND_IN_CUR_DRAWING */ N_("No pins found in the current drawing."), /* STID_INPUT_PAIRS_OF_POINTS_POLY */ N_("Please input pairs of points: (terminate with \"d\" or \".\", continue to next poly with \";\")"), /* STID_READ_INT_ERROR_FOR_POLY_PTS */ N_("Error reading integer for poly points."), /* STID_TOO_FEW_POINTERS_ENTERED */ N_("Too few points entered."), /* STID_TOO_FEW_VER_TO_CLOSE_POLY */ N_("Too few vertices to close a polyline/open-spline."), /* STID_HUH_WHERE_ARE_THE_VERTICES */ N_("Huh? Where are the vertices?"), /* STID_HUH_TOPVSEL_NE_BOTVSEL */ N_("Huh? How can topVSel != botVSel?"), /* STID_CMD_ONLY_AVAIL_IN_VERSEL_MODE */ N_("This command is only available in vertex or select mode."), /* STID_SEL_2_ENDPOINT_VER_TO_JOIN */ N_("Please select 2 end-point vertices to join."), /* STID_SEL_VER_FROM_POLY_OPEN_ONLY */ N_("Please select vertices from polylines/open-splines only."), /* STID_SEL_2_POLYLINES_OPEN_SPLINES */ N_("Please select 2 polylines/open-splines."), /* STID_CANT_JOIN_INTSPLINE_W_NONEINT */ N_("Cannot join a interpolated spline with a non-interpolated polyline/open-spline."), /* STID_SEL_1_VERTEX_TO_CUT */ N_("Please select 1 vertex to cut."), /* STID_SEL_A_VERTEX_FROM_POLY_OR_GON */ N_("Please select a vertex from a polyline or polygon object."), /* STID_INVALID_SMOOTHHINGE_SPEC_POLY */ N_("%s, %d: Invalid smooth/hinge spec for a poly/polygon object. Read aborted"), /* STID_INVALID_NUM_PTS_IN_POLY */ N_("%s, %d: Invalid number of points in a poly object. Read aborted"), /* STID_INPUT_PAIRS_OF_POINTS_POLYGON */ N_("Please input pairs of points: (terminate with \"d\" or \".\", continue to next polygon with \";\")"), /* STID_READ_INT_ERR_FOR_POLYGON_PTS */ N_("Error reading integer for polygon points."), /* STID_INVALID_NUM_PTS_IN_POLYGON */ N_("%s, %d: Invalid number of points in a polygon. Read aborted"), /* STID_CANT_GET_XDEF_DEF_WIDTHS_USED */ N_("Error in getting X default %s.%s. Default widths used."), /* STID_ERR_SETCTM_CALLED_CTM_NONNULL */ N_("Error: SetCTM() is called with ObjPtr->ctm != NULL."), NULL }; static char *gaszEnglishStrTable1000[] = { /* STID_MEASUREMENT_SHOWN_IN_UNIT */ N_("Measurement will be shown in '%s' (%s %s)."), /* STID_BAD_MEASUREMENT_UNIT_SPEC */ N_("Bad measurement unit specification '%s'."), /* STID_SHOW_CROSSHAIR_ENABLED */ N_("Showing cross-hair enabled."), /* STID_SHOW_CROSSHAIR_DISABLED */ N_("Showing cross-hair disabled."), /* STID_SHOW_MEASUREMENT_ENABLED */ N_("Showing measurement enabled."), /* STID_SHOW_MEASUREMENT_DISABLED */ N_("Showing measurement disabled."), /* STID_CANNOT_EXECUTE_GIVEN_CMD */ N_("Cannot execute '%s'."), /* STID_CONNECTION_INTERRUPTED */ N_("%s: connection interrupted."), /* STID_CANT_CONN_TO_HOST_PORT */ N_("%s: cannot connect to %s%s%s."), /* STID_FAIL_TO_GET_DATA_FROM_URL */ N_("%s: fail to get data from '%s'."), /* STID_NETWORK_ERR_TALK_TO_HOST_PORT */ N_("%s: network error occurred when talking to %s%s%s."), /* STID_FAILED_TO_LOGIN_TO_HOST_PORT */ N_("%s: fail to login to %s%s%s."), /* STID_CANT_FIND_LOCATION_IN_HDR */ N_("%s: Cannot find forwarding 'Location' information in message header while getting data from '%s'."), /* STID_LNK_FWD_5_TIMES_LOAD_ABORT */ N_("%s: Links forwarded more than 5 times while getting data from '%s'.\n\nLoading is aborted."), /* STID_CANT_FIND_WWW_AUTHEN_IN_HDR */ N_("%s: Cannot find 'WWW-Authenticate' information in message header while getting data from '%s'."), /* STID_AUTHEN_REQ_FOR_REALM */ N_("%s: Authentication information for %s required..."), /* STID_ENTER_USERNAME_FOR_REALM */ N_("Please enter UserName for %s:"), /* STID_ENTER_PASSWORD_FOR_REALM */ N_("Please enter Password for %s:"), /* STID_FAIL_TO_PARSE_GIVEN_URL */ N_("Fail to parse URL: '%s'."), /* STID_TOOL_NOT_KNOW_HOW_TALK_PROTO */ N_("%s does not know how to talk using the '%s' protocol."), /* STID_LAUNCH_GIVEN_VIEWER */ N_("Launch viewer: %s"), /* STID_CANT_OPEN_GIVEN_MAILCAP_FILE */ N_("Cannot open mailcap file '%s'."), /* STID_MALFORMED_MAILCAP_ENTRY */ N_("Malformed mailcap entry:\n\n%s/%s; %s"), /* STID_MALFORMED_MAILCAP_ENTRY_PARAM */ N_("Malformed mailcap entry:\n\n%s/%s; %s; %s"), /* STID_TOOL_CANT_HANDLE_MP_MIME */ N_("%s does not know how to handle Multipart MIME types."), /* STID_CANT_FIND_RT_BRACK_MC */ N_("Cannot find matching '}' for mailcap entry:\n\n%s/%s; %s"), /* STID_CANT_FIND_RT_BRACK_MC_PARAM */ N_("Cannot find matching '}' for mailcap entry:\n\n%s/%s; %s; %s"), /* STID_CANT_FIND_NAMED_INFO_IN_CT */ N_("%s: cannot find the '%s' information in the message Content-Type."), /* STID_SAVE_GIVEN_STR_AS */ N_("Save %s as:"), /* STID_NO_VIEWER_SAVE_GIVEN_STR_AS */ N_("No viewer found. Save %s as:"), /* STID_UNKNOWN_ERR_IN_COPYING_FILES */ N_("Unknown error in copying files."), /* STID_CANT_GETHOSTNAME_USE_LOCALH */ N_("Cannot gethostname(), 'localhost' is used instead."), /* STID_TURN_OFF_AUTO_PAN_SET_XDEF */ N_("To turn off auto-panning, set %s.%s to false in X defaults."), /* STID_WILL_UPD_WIN_SMOOTH_SCROLL */ N_("Will update canvas window smoothly while scrolling."), /* STID_WILL_UPD_WIN_JUMP_SCROLL */ N_("Will jump update canvas window while scrolling."), /* STID_WILL_NOT_UPD_WIN_SCROLL */ N_("Will not update canvas window while scrolling."), /* STID_INCONSIS_VERTEX_SEL_IN_FUNC */ N_("Inconsistent vertex selection detected in %s."), /* STID_INVALID_NAMED_TELEPORT_DEST */ N_("Invalid teleport destination '%s'."), /* STID_Q_FILE_NOT_EXIST_CREATE */ N_("File '%s' does not exist.\n\nWould you like to create it?"), /* STID_CANT_FIND_PAGE_NAMED_TO_TEL */ N_("Cannot find page named '%s' to teleport to."), /* STID_CANT_FIND_PAGE_NUM_TO_TEL */ N_("Cannot find page %1d to teleport to."), /* STID_CANT_GROUP_IN_VERTEX_MODE */ N_("Cannot group in vertex mode."), /* STID_CANT_GROUP_SINGLE_OBJECT */ N_("Cannot group a single object."), /* STID_INVALID_XDEF_USE_ALT_OCTVALUE */ N_("Invalid %s.%s: '%s', 0%03o is used instead."), /* STID_INVALID_XDEF_RNG_USE_ALT_STR */ N_("Invalid %s.%s: '%s', (must be between %s and %s), %s is used instead."), /* STID_CANT_CREATE_NAMED_DIRECTORY */ N_("Cannot create the '%s' directory."), /* STID_OPR_USING_NAMED_DIR_WILL_FAIL */ N_("Operations using the '%s' directory (such as CopyProperties() and PasteProperties()) will fail."), /* STID_CREATE_A_SHAPE_FAILED */ N_("Create a shape failed."), /* STID_CREATE_SHADOW_SHAPE_NO_FILL */ N_("You are attempting to create a shadowed shape but the shape has no fill (the shadow will show through).\n\nWould you like to create such a shape without a shadow?"), /* STID_CREATE_SHADOW_SHAPE_TRAN_FILL */ N_("You are attempting to create a shadowed shape but the shape has transparent fill (the shadow will show through).\n\nWould you like to create such a shape without a shadow?"), /* STID_ENTER_XY_OFFSET_FOR_SHP_SHDW */ N_("Please enter X and Y offsets for the shape shadow: [current: %1d,%1d]"), /* STID_SHAPE_SHDW_XY_OFFSETS_SET_TO */ N_("Shape shadow offsets set to: %1d, %1d."), /* STID_INVALID_SHORTCUT_ENTRY_SKIP */ N_("Invalid shortcut entry: '%s'. It is skipped."), /* STID_DUP_SHORTCUT_ENTRY_FOR_CHAR */ N_("Warning: duplicate shortcut entry for '%c'."), /* STID_INVALID_SHORTCUT_ENTRY */ N_("Invalid shortcut entry: '%s'."), /* STID_WARN_DUP_CMDID */ N_("Warning: duplicate cmdid %1d."), /* STID_PUSH_IN_WB */ N_("Push() is disabled in WhiteBoard mode."), /* STID_FILE_VER_ABORT_READ_SYMBOL */ N_("File version (=%1d) too large.\n\nRead symbol aborted.\n\nYou may need a more recent version of %s. Please check ."), /* STID_CANT_FIND_NAMED_OBJ_IN_FUNC */ N_("Cannot find the '%s' text object in %s."), /* STID_SEL_A_SYM_TO_INSTAN_IN_DOMAIN */ N_("Please select a symbol to INSTANTIATE in the '%s' domain..."), /* STID_CANT_INSTAN_FILE_UNKNOWN_EXT */ N_("Cannot instantiate because '%s' has unknow file extension."), /* STID_CANT_MAKESYMBOLIC_VERTEX_MODE */ N_("Cannot MakeSymbolic() in vertex mode."), /* STID_SEL_ONLY_ONE_FOR_MAKESYMBOLIC */ N_("Please select only one object for MakeSymbolic()."), /* STID_PIN_CANT_MADE_INTO_SYMBOL */ N_("A pin object cannot be made into a symbol object."), /* STID_SEL_OBJ_IS_NOW_SYMBOLIC */ N_("Selected object is now SYMBOLIC."), /* STID_ENTER_NAME_FOR_THE_ICON */ N_("Please enter name for the icon:"), /* STID_NAME_NOT_SPEC_ICON_NOT_CREATE */ N_("Name not specified, icon not created."), /* STID_CANT_SAVE_OBJ_ICON_NOT_CREATE */ N_("Cannot save as an object file, icon not created."), /* STID_CANT_FIND_DOT_IN_ICON_NAME_MI */ N_("Cannot find '.' in icon_name in MakeIconic()."), /* STID_CANT_SAVE_PIN_ICON_NOT_CREATE */ N_("Cannot save as a pin file, icon not created."), /* STID_CANT_OPEN_FOR_WRITE_ICON_CRET */ N_("Cannot open '%s' for writing, icon not created."), /* STID_SEL_OBJ_IS_NOW_ICONIC */ N_("Selected object is now ICONIC."), /* STID_SEL_ONLY_ONE_FOR_MAKEICONIC */ N_("Please select one object to make it ICONIC."), /* STID_SEL_OBJS_ARE_NOW_GROUP */ N_("Selected ICONIC objects are GROUP objects now."), /* STID_GIVEN_LINE_SKIP_NOT_AN_ATTR */ N_("Line %1d in '%s' is skipped because it does not specify an attribute."), /* STID_GIVEN_LINE_SKIP_ILLEGAL_CHAR */ N_("Line %1d in '%s' is skipped because attribute name contains illegal characters such as '!' or '.'."), /* STID_SEL_ONE_OBJ_FOR_IMPORTATTRS */ N_("Please select only one object for ImportAttrs()."), /* STID_SEL_TEXT_FILE_OF_ATTR_TO_IMP */ N_("Please select a text file containing attributes to import..."), /* STID_CANT_IMPORT_REMOTE_TEXT_FILE */ N_("Importing remote text file not supported."), /* STID_SEL_ONE_OBJ_FOR_EXPORTATTRS */ N_("Please select only one object for ExportAttrs()."), /* STID_SEL_OBJ_HAS_NO_ATTR_TO_EXPORT */ N_("Select object has no attributes to export."), /* STID_ENTER_TXT_FILE_TO_EXPORT_CRES */ N_("Please enter a text file name to export to: ( : accept, : cancel )"), /* STID_ATTR_EXPORTED_TO_NAMED_FILE */ N_("Attributes exported to '%s'."), /* STID_CANT_FIND_ATTR_FOR_MERGEWTBL */ N_("Cannot find the '%s' attribute for MergeWithTable()."), /* STID_MALFORMED_ATTR_FOR_MERGEWTBL */ N_("Malformed '%s' attribute for MergeWithTable()."), /* STID_SEL_ONE_OBJ_FOR_MERGEWTBL */ N_("Please select only one object for MergeWithTable()."), /* STID_FILE_MOD_SAVE_BEFORE_MERGE */ N_("File modified, save file before merge? [ync](y)"), /* STID_Q_MERGEWTBL_CANT_UNDO_PROCEED */ N_("MergeWithTable cannot be undone.\n\nOk to proceed? [ync](y)"), /* STID_SEL_TEXT_FILE_FOR_MERGEWTBL */ N_("Please select a text file for MergeWithTable()."), /* STID_CANT_MERGE_W_REMOTE_TEXT_FILE */ N_("Merging remote text file not supported."), /* STID_FIND_COL_NAMES_IN_FILE_ABORT */ N_("Cannot find column names in '%s'.\n\nMerge aborted."), /* STID_MALFORMED_COL_NAMES_ABORT_MRG */ N_("Malformed column names in '%s'.\n\nMerge aborted."), /* STID_LF_BTN_PLACE_MRG_OTHER_CANCEL */ N_("Left button places a merged object, other buttons cancel merging."), /* STID_MALFORMED_TBL_LINE_ABORT_MRG */ N_("Malformed table at line %d in '%s'.\n\nMerge aborted."), /* STID_CANT_FND_NAMED_ATTR_ABORT_MRG */ N_("Cannot find attribute named '%s'.\n\nMerge aborted."), /* STID_NUM_OBJECTS_GENERATED */ N_("%1d object(s) generated."), /* STID_CANT_FND_TABLE_ATTRS_FILE_ATT */ N_("Cannot find the \"!.TABLE_ATTRS\" file attribute.\n\nCannot proceed with ExportToTable()."), /* STID_NUM_OBJECTS_EXPORTED */ N_("%1d object(s) exported."), /* STID_ATTRS_EXPORTED_TO_TBL_FILE */ N_("Attributes exported to table file '%s'."), /* STID_SEL_ONE_ICON_OBJ_TO_PUSH */ N_("Please select one ICON object to push into."), NULL }; static char *gaszEnglishStrTable1100[] = { /* STID_CANT_FND_SYM_FILE_IN_PATH */ N_("Cannot find '%s.%s' in %s."), /* STID_CANNOT_OPEN_FOR_READ_PUSH */ N_("Cannot open '%s' for reading. Icon not pushed into."), /* STID_FILE_VER_ABORT_PUSH */ N_("File version (=%1d) too large.\n\nPush aborted.\n\nYou may need a more recent version of %s. Please check ."), /* STID_POP_BACK_TO_PARENT_UNDEF */ N_("Poping back to parent level. Current file undefined."), /* STID_ALREADY_AT_TOP_LEVEL */ N_("Already at top level."), /* STID_FILE_MOD_SAVE_BEFORE_POP */ N_("File modified, save file before poping back to the parent level? [ync](y)"), /* STID_CANT_FND_SYM_IN_NAMED_TO_INST */ N_("Cannot find a symbol object in '%s' to instantiate."), /* STID_CANT_FIND_XDEF */ N_("Cannot find %s.%s."), /* STID_ENTER_USERAGENT_FOR_HTTP */ N_("Please specify 'UserAgent' to be used when making an HTTP request."), /* STID_ENTER_USERAGENT_FOR_HTTP_CUR */ N_("Please specify 'UserAgent' to be used when making an HTTP request (current value is '%s')."), /* STID_PRESS_ENTER_FOR_DEF_USERAGENT */ N_("( press for the default 'UserAgent' )"), /* STID_WILL_USE_DEF_USERAGENT_HTTP */ N_("Will use the default 'UserAgent' when making an HTTP request."), /* STID_WILL_USE_NAMED_USERAGENT_HTTP */ N_("Will use '%s' as 'UserAgent' when making an HTTP request."), /* STID_ENTER_REFERRER_FOR_HTTP */ N_("Please specify 'Referrer' to be used when making an HTTP request."), /* STID_ENTER_REFERRER_FOR_HTTP_CUR */ N_("Please specify 'Referrer' to be used when making an HTTP request (current value is '%s')."), /* STID_PRESS_ENTER_FOR_NO_REFERRER */ N_("( press for no 'Referrer' )"), /* STID_WILL_NOT_USE_REFERRER_HTTP */ N_("Will not use 'Referrer' when making an HTTP request."), /* STID_WILL_USE_NAMED_REFERRER_HTTP */ N_("Will use '%s' as 'Referrer' when making an HTTP request."), /* STID_WILL_USE_KEEP_ALIVE_HTTP */ N_("Will use Keep-Alive HTTP connections."), /* STID_NOT_WILL_USE_KEEP_ALIVE_HTTP */ N_("Will not use Keep-Alive HTTP connections."), /* STID_CANT_LOCATE_NAMED_SERVER_TRY */ N_("%s: unable to locate the server '%s'.\n\nPlease check the server name and try again."), /* STID_FAIL_TO_MAKE_SOCKET_BLOCK */ N_("Fail to make socket blocking."), /* STID_FAIL_TO_MAKE_SOCKET_NON_BLOCK */ N_("Fail to make socket non-blocking."), /* STID_BROKEN_PIPE_CONTACT_HOST */ N_("Broken pipe while contacting '%s'."), /* STID_WRITE_TO_SOCKET_FAILED */ N_("Writing to socket failed."), /* STID_READ_FROM_SOCKET_FAILED */ N_("Reading from socket failed."), /* STID_UNEXP_NETWORK_ERR_WRITE_SOCK */ N_("Unexpected network error while writing to socket."), /* STID_UNEXP_NETWORK_ERR_READ_SOCK */ N_("Unexpected network error while reading from socket."), /* STID_LOCKED_OBJS_CANT_BE_STRETCHED */ N_("Locked object(s) cannot be stretched."), /* STID_CANT_STRETCH_OBJ_HAS_0_WIDTH */ N_("Cannot stretch. Object has ZERO width."), /* STID_CANT_STRETCH_OBJ_HAS_0_HEIGHT */ N_("Cannot stretch. Object has ZERO height."), /* STID_LOCKED_OBJS_CANT_BE_SCALED */ N_("Locked object(s) cannot be scaled."), /* STID_ENTER_SCALING_FACTORS_XY */ N_("Please enter scaling factors: [X:Y] or [scale]"), /* STID_ENTER_A_SCALING_FACTOR */ N_("Please enter a scaling factor:"), /* STID_ONLY_INPUT_ONE_NUMERIC_VAL */ N_("Please only input only one numeric value."), /* STID_SCALING_EVERYTHING_LARGE_SURE */ N_("Scaling everything by %g times. Are you sure?"), /* STID_DISABLE_ON_RESIZE_ROTATE */ N_("The '%s' object has an on_resize() script.\n\nTo rotate it will disable the on_resize() script. Is it okay to rotate it?"), /* STID_DISABLE_ON_RESIZE_SHEAR */ N_("The '%s' object has an on_resize() script.\n\nTo shear it will disable the on_resize() script. Is it okay to shear it?"), /* STID_DISABLE_ON_RESIZE_TRANSFORM */ N_("The '%s' object has an on_resize() script.\n\nTo transform it will disable the on_resize() script. Is it okay to transform it?"), /* STID_LOCKED_OBJS_CANT_BE_FLIPPED */ N_("Locked object(s) cannot be flipped."), /* STID_LOCKED_OBJS_ARE_NOT_FLIPPED */ N_("Locked object(s) are not flipped."), /* STID_LOCKED_OBJS_ARE_NOT_STRETCHED */ N_("Locked object(s) are not stretched."), /* STID_LOCKED_OBJS_ARE_NOT_ROTATED */ N_("Locked object(s) are not rotated."), /* STID_LOCKED_OBJS_ARE_NOT_SHEARED */ N_("Locked object(s) are not sheared."), /* STID_LOCKED_OBJS_ARE_NOT_XFORMED */ N_("Transformation matrix not changed for locked object(s)."), /* STID_FLIPPED_HORIZONTALLY */ N_("Flipped horizontally."), /* STID_FLIPPED_VERTICALLY */ N_("Flipped vertically."), /* STID_LOCKED_OBJS_CANT_BE_ROTATED */ N_("Locked object(s) cannot be rotated."), /* STID_ROTATED_CLOCKWISE */ N_("Rotated clockwise."), /* STID_ROTATED_COUNTER_CLOCKWISE */ N_("Rotated counter-clockwise."), /* STID_ENTER_TEXT_ROT_IN_DEGREE_CUR */ N_("Please enter text rotation in degrees: (current value is %s)"), /* STID_CANT_PARSE_ENTER_ONE_NUM_VAL */ N_("Cannot parse '%s'.\n\nPlease enter a numeric value."), /* STID_INVALID_VAL_ENTERED_RNG_INC */ N_("Invalid value entered: '%s'. Please enter a numeric value between %1d and %1d (inclusive)."), /* STID_TEXT_ROTATION_SET_TO_GIVEN */ N_("Text rotation set to %s."), /* STID_ENTER_ROT_INC_IN_DEGREE_CUR */ N_("Please enter text rotation increment in degrees: (current value is %s)"), /* STID_INVALID_VAL_ENTERED_RNG_EXC */ N_("Invalid value entered: '%s'. Please enter a numeric value > %1d and < %1d."), /* STID_TEXT_ROT_INC_SET_TO_GIVEN */ N_("Text rotation increment set to %s."), /* STID_LOCKED_OBJS_CANT_BE_XFORMED */ N_("Cannot change transformation matrix for locked object(s)."), /* STID_SEL_OBJ_TOO_SMALL_ROT_ANOTHER */ N_("Selected object is too small to rotate.\n\nPlease select another object to rotate."), /* STID_SEL_OBJ_TOO_SMALL_SHEAR_ANO */ N_("Selected object is too small to shear.\n\nPlease select another object to shear."), /* STID_CANNOT_CREATE_GC */ N_("Cannot create GC."), /* STID_READ_ONLY_TEXT_CANT_BE_EDITED */ N_("Read-only text cannot be edited."), /* STID_TEXT_SZ_NOT_AVAIL_TRY_DIFF */ N_("Text size=%1d not available.\n\nPlease try a different size."), /* STID_CANT_INS_NON_DB_CH_AT_CUR_REM */ N_("Cannot insert a non-double-byte character at the text cursor position. The non-double-byte character is removed."), /* STID_TOO_MANY_BYTES_IN_CH_IGNORED */ N_("Cannot handle so many bytes in a character. Character is ignored."), /* STID_CANT_TAB_OUT_OF_NON_ATTR_TEXT */ N_("Cannot TAB out of a non-attribute text."), /* STID_COMPOUND_TEXT_BUF_IS_EMPTY */ N_("Compound-text buffer is empty."), /* STID_CUT_BUFFER_IS_EMPTY */ N_("Cut buffer is empty."), /* STID_AN_ESC_KEY_PRESS_IGNORED */ N_("An key press is ignored."), /* STID_GIVEN_NUM_LINES_PASTED */ N_("%1d line(s) pasted."), /* STID_COPY_FAIL_SEL_STR_MAY_TOO_LNG */ N_("Copy to cut buffer failed. Selected string may be too long."), /* STID_UNEXPECTED_TOK_IN_ABORT_READ */ N_("%s, %d: Unexpected token '%c' in %s. Read aborted."), /* STID_ILLEGAL_FIELD_IN_ABORT_READ */ N_("%s, %d: Illegal field '%s' in %s. Read aborted."), /* STID_INVALID_GIVEN_VALUE_SPECIFIED */ N_("Invalid value '%s' specified for script fraction."), /* STID_ENTER_SCRIPT_FRACTION_CUR_IS */ N_("Please enter a fraction for the super/subscript size (current fraction is %s):"), /* STID_SCRIPT_FRACTION_SET_TO_STR */ N_("Script fraction set to '%s'."), /* STID_ENTER_INT_WIDTH_FOR_THIN_SPC */ N_("Please enter an integer width value for the thin space (a negative value indicates a negative think space):"), /* STID_ENTER_INT_VAL_FOR_VERT_OFFSET */ N_("Please enter an integer value for the vertical offset (a negative value raises the current line):"), /* STID_FAIL_INSERT_SCRIPT_FONT_SZ */ N_("Failed to insert super/subscript because font size is not available."), /* STID_TOOL_DONT_KNOW_HOW_RUN_GUNZIP */ N_("%s does not know how to run gunzip."), /* STID_SPECIFY_DISPLAY_ON_CMD_LINE */ N_("Please specify '-display $DISPLAY' on the command line."), /* STID_FILE_VER_ABORT_TOOL */ N_("File version (=%1d) too large.\n\n%s aborted.\n\nYou may need a more recent version of %s. Please check ."), /* STID_FILE_SKIP_CONTAINS_ONE_PAGE */ N_("%s is skipped because it only contains 1 page."), /* STID_FILE_SKIP_CONTAINS_NUM_PAGE */ N_("%s is skipped because it only contains %1d pages."), /* STID_FILE_NOT_CONTAIN_COLOR_ABORT */ N_("File does not contain enough color information (it is not saved by tgif-3.0-p10 or beyond). %s aborted."), /* STID_SPEC_FILE_WHEN_STDOUT_USED */ N_("File name must be specified when -stdout is used."), /* STID_TOOL_FILE_NAME_TO_PRINT */ N_("%s File Name to Print"), /* STID_CANT_ONEFPPAGE_IN_TILED_PAGE */ N_("Cannot use -one_file_per_page in TILED page mode."), /* STID_ONE_FILE_ONLY_WITH_STDOUT */ N_("Only one file name can be specified with -stdout."), /* STID_ONE_FILE_ONLY_RAW_PLUS_H */ N_("Cannot process more than one file in -raw or -raw+h mode."), /* STID_ONE_FILE_ONLY_DOSEPSFILTER */ N_("Cannot process more than one file in -dosepsfilter mode."), /* STID_CANT_PRTGIF_OFPP_TILED_PAGE */ N_("Cannot use -one_file_per_page mode with a TILED page mode file."), /* STID_INVALID_SHARELIB_VER_IN_FILE */ N_("Invalid shared library version in '%s'."), /* STID_FAIL_LOAD_SHARELIB */ N_("Fail to load shared library '%s'."), /* STID_FAIL_GET_ENTRY_PT_IN_SHARELIB */ N_("Fail to get entry point '%s' in shared lib '%s'."), /* STID_SHARELIB_TGEF_MSG_INIT_FAIL */ N_("%s: TGEF_MSG_INIT failed with return code %ld."), /* STID_SHARELIB_CNFLCT_PROTOCOL_VER */ N_("Conflicting protocol version %1d implemented by '%s'."), /* STID_SHARELIB_TGEF_MSG_LOAD_FAIL */ N_("%s: TGEF_MSG_LOAD failed with return code %ld."), /* STID_SHARELIB_TGEF_MSG_NO_BMP_INFO */ N_("%s: TGEF_MSG_LOAD returned with no bitmap info."), /* STID_ALLOC_BMP_FAIL_FOR_SHARELIB */ N_("Failed to allocate bitmap for '%s'."), NULL }; static char *gaszEnglishStrTable1200[] = { /* STID_UNSUP_PROTOCOL_VER_SHARELIB */ N_("Unsupported protocol version %1d implemented by '%s'."), /* STID_SHARELIB_TGEF_MSG_DO_EXPORT_F */ N_("%s: TGEF_MSG_DO_EXPORT failed with return code %ld."), /* STID_NEG_VAL_IN_EXP_PXL_TRM_ALT */ N_("Error in parsing ExportPixelTrim values: negative values are not allowed.\n\n[%1d,%1d,%1d,%1d] used."), /* STID_EXP_PXL_TRM_VAL_SET_TO */ N_("ExportPixelTrim values set to [%1d,%1d,%1d,%1d]."), /* STID_SPECIFY_TO_TRIM_EXP_PXL_TRM */ N_("Please specify the number of pixels to trim when exporting (or printing) in bitmap-type format: [current: %1d,%1d,%1d,%1d]"), /* STID_ENTER_4_NUM_CUR_TOO_LARGE */ N_("Please enter 4 numbers or type or to use the current values (they are too large now):"), /* STID_ENTER_4_NUM_OR_CR_ESC */ N_("Please enter 4 numbers or type or to use the current values:"), /* STID_OBSOLETE_XDEF_USE_IGNORED */ N_("Obsoleted %s.%s used. Ignored."), /* STID_WILL_USE_FS_HALFTONE_BMP */ N_("Will use Floyd-Steinberg half-tone method when exporting an X11 bitmap file."), /* STID_WILL_NOT_USE_FS_HALFTONE_BMP */ N_("Will not use Floyd-Steinberg half-tone method when exporting an X11 bitmap file."), /* STID_WILL_USE_GIVE_SMPLE_THRESHOLD */ N_("Will use simple thresholding method with a threshold of '%s' when exporting an X11 bitmap file."), /* STID_WILL_NOT_USE_SIMPLE_THRESHOLD */ N_("Will not use simple thresholding method when exporting an X11 bitmap file."), /* STID_ENTER_BMP_THRESHOLD_CUR_VAL */ N_("Please specify bitmap threshold when exporting an X11 bitmap file (current value is '%s')."), /* STID_INVALID_THRESHOLD_REMAINS */ N_("Invalid threshold: '%s' specified. Threshold remains at '%s'."), /* STID_USE_GIVEN_AS_BMP_THRESHOLD */ N_("Will use '%s' as bitmap threshold when exporting an X11 bitmap file."), /* STID_XGETIMAGE_MAY_RUN_OUT_VMEM */ N_("XGetImage() failed. May have run out of virtual memory."), /* STID_NO_X11_BITMAP_OBJ_SELECTED */ N_("No X11 Bitmap objects selected."), /* STID_CANT_CUT_AN_EPS_OBJECT */ N_("Cannot cut an EPS object."), /* STID_XBM_CANT_HAVE_0_W_OR_H */ N_("Bitmap cannot have 0 width or height."), /* STID_BAD_RED_MASK_TRUE_COLOR_DPY */ N_("Unexpected red_mask value of 0x%06lx in the default visual for this TrueColor display. Proceed pretending that the display is not TrueColor. Please set %s.%s to FALSE to avoid this error message in the future."), /* STID_BAD_GREEN_MASK_TRUE_COLOR_DPY */ N_("Unexpected green_mask value of 0x%06lx in the default visual for this TrueColor display. Proceed pretending that the display is not TrueColor. Please set %s.%s to FALSE to avoid this error message in the future."), /* STID_BAD_BLUE_MASK_TRUE_COLOR_DPY */ N_("Unexpected blue_mask value of 0x%06lx in the default visual for this TrueColor display. Proceed pretending that the display is not TrueColor. Please set %s.%s to FALSE to avoid this error message in the future."), /* STID_NETPBM_PROGS_VISIT_HOME_PAGE */ N_("(These programs are part of the netpbm package. Please visit %s's home page at regarding where to obtain netpbm.)"), /* STID_NETPBM_PNMTOPNG_VST_HOME_PAGE */ N_("(These programs are part of the netpbm and pnmtopng packages. Please visit %s's home page at regarding where to obtain netpbm and pnmtopng.)"), /* STID_FNAME_FORMAT_ERROR_IN_FUNC */ N_("File name format error in %s."), /* STID_NAMED_IMAGEMAP_FILE_GEN */ N_("Imagemap file '%s' generated."), /* STID_CANT_FND_FATTR_IMGMAP_NOT_GEN */ N_("Cannot find a '%s' file attribute.\n\nImagemap not generated."), /* STID_CANT_FND_FATTR_NO_IMGMAP_GIF */ N_("Cannot find a '%s' file attribute.\n\nImagemap not generated. Only a GIF file is generated."), /* STID_NAMED_HTML_FILE_GEN */ N_("HTML file '%s' generated."), /* STID_LARGE_EXP_PXL_TRM_WH_0_USED */ N_("The ExportPixelTrim values of [%1d,%1d,%1d,%1d] are too large for the image (%1dx%1d). Zeroes are used."), /* STID_APPLY_EXP_PXL_TRM_VALS */ N_("Applying ExportPixelTrim of [%1d,%1d,%1d,%1d]..."), /* STID_TOO_MANY_COLORS_LIMIT_IS */ N_("Too many colors: %1d (limit is %1d) in the image."), /* STID_UNRECOG_GIVEN_PIXEL_VAL_PRINT */ N_("Unrecognized pixel value at (%1d,%1d): %1d (0x%08lx).\n\nPrinting/exporting aborted."), /* STID_UNRECOG_GIVEN_PIXEL_VAL_1_USE */ N_("Unrecognized pixel value: %1d (0x%08lx).\n\n1 used."), /* STID_FORMAT_FILE_WH_PRINTED_INTO */ N_("%s file [%1dx%1d] printed into '%s'."), /* STID_SEL_XPM_DECK_TO_EXPORT */ N_("Please select a deck of X Pixmap object to export."), /* STID_MANY_SZ_FAIL_XPM_DESK_EXPORT */ N_("Not all X Pixmap objects in the deck are of size. Expecting %1dx%1d.\n\nExport aborted."), /* STID_INVALID_CH_PER_PIX_IN_FUNC */ N_("Invalid chars_per_pixel (%1d) in %s."), /* STID_XPM_CANT_HAVE_0_W_OR_H */ N_("Pixmap cannot have 0 width or height."), /* STID_WARN_XPM_ALL_NON_BG_BE_BLACK */ N_("Warning (xpm object): all non-background color will be treated as black."), /* STID_SAVED_FILE_MAY_BE_CORRUPTED */ N_("Saved file may be corrupted."), /* STID_CANT_SAVE_XPM_ON_BW_DPY */ N_("Cannot save X11 Pixmap objects on a Black & White display."), /* STID_CANT_IMPORT_GIVEN_FORMAT_XPM */ N_("Does not know how to import an X11 Pixmap file with format: '%1d'."), /* STID_CANT_IMPORT_GIVEN_CPP_XPM */ N_("Does not know how to import an X11 Pixmap file with chars_per_pixel: '%1d'."), /* STID_EDIT_UNNAME_ATTR_DOTS */ N_("Edit an unnamed attribute..."), /* STID_EDIT_VAL_OF_ATTR_DOTS */ N_("Edit the value for the '%s' attribute..."), /* STID_EDIT_UNNAME_ATTR_WITH_CMD */ N_("Editing an unnamed attribute with '%s'..."), /* STID_EDIT_VAL_OF_ATTR_WITH_CMD */ N_("Editing the value for the '%s' attribute with '%s'..."), /* STID_STAT_FAIL_EDIT_ATTR_VAL_SAME */ N_("Fail to get file info for '%s' while editing an attribute. Attribute value is unchanged."), /* STID_ENTER_HTML_TEMPLATE */ N_("Please specify a file to be used as a template for generating HTML files:"), /* STID_ENTER_HTML_TEMPLATE_CUR_IS */ N_("Please specify a file to be used as a template for generating HTML files (current template is '%s'):"), /* STID_HTML_TEMPLATE_UNCHANGED */ N_("HTML export template file unchanged."), /* STID_HTML_TEMPLATE_SET_TO_GIVEN */ N_("HTML export template file set to '%s'."), /* STID_NO_HTML_TEMPLATE_FILE */ N_("Will not use an HTML export template file."), /* STID_Q_FILE_NOT_EXIST_USE_ANYWAY */ N_("File '%s' does not exist.\n\nWould you like to use it anyway?"), /* STID_CANNOT_OPEN_HTML_TMPL_READ */ N_("Cannot open HTML export template file '%s' for reading."), /* STID_OK_TO_FULL_SCREEN_CAPTURE_YNC */ N_("Okay to proceed with full screen capture? [ync](y)"), /* STID_Q_FILE_UNSAVABLE_SAVE_NEW_YNC */ N_("File is marked unsavable.\n\nWould you like to save to a new file name? [ync](y)"), /* STID_WONT_CONDENSE_READHEXSTRING */ N_("Will not condense exported PS/EPS file due to 'readhexstring'."), /* STID_CMD_ONLY_AVAIL_IN_VERTEX_MODE */ N_("This command is only available in vertex mode."), /* STID_CANNOT_MERGE_WITH_TILED_PAGE */ N_("Does not know how to merge files with '%s' because it is in TILED page mode. Merge aborted."), /* STID_SPECIFY_PAGES_TO_PRINT_EX */ N_("Please specify pages to print: (e.g., 2,3,7-9,10 or '*' for all pages)"), /* STID_CANT_PRINT_PAGES_IN_TILED */ N_("Cannot print pages in TILED page mode."), /* STID_CANT_PRINT_PAGES_IN_FORMAT */ N_("Cannot print pages in the '%s' format."), /* STID_PRECISE_SCALE_EV_CAUSE_FLUSH */ N_("Precise Scale Everything will cause the undo buffer to be flushed."), /* STID_GO_HYPERSPACE_IN_SLIDE */ N_("HyperSpace mode will be entered upon entering slideshow mode."), /* STID_DONT_GO_HYPERSPACE_IN_SLIDE */ N_("Freehand drawing mode will be entered upon entering slideshow mode."), /* STID_MOVE_EDIT_TEXT_BOX_ABORTED */ N_("Move edit text box aborted."), /* STID_DRAG_MOUSE_MOVE_EDITTEXT_DOTS */ N_("Drag the edit text box to move it around..."), /* STID_EXCEED_BUF_SIZE_LIMIT_IN_WB */ N_("Error: There's a buffer size limitation of %1d bytes in the current implementation of the whiteboard. The buffer size requirement (%1d bytes) for the operation you just performed has exceeded this limit.\n\nIn order to keep the whiteboard running, the operation in question is canceled."), /* STID_CANT_REPLACE_GRAPHIC_NOT_TGIF */ N_("Cannot replace graphical objects because cut buffer does not contain %s objects."), /* STID_CANT_REPLACE_GRAPHIC_TOO_MANY */ N_("Cannot replace graphical objects because cut buffer contain more than one objects."), /* STID_REPLACE_GRAPHIC_ICON_TO_GROUP */ N_("Some iconic objects have been converted to grouped objects during Replace Graphic."), /* STID_REPLACE_GRAPHIC_DONE */ N_("Graphical part of selected objects have been replaced and updated."), /* STID_TOO_MANY_ICON_REPLACE_GRAPHIC */ N_("More than one iconic objects are selected for Replace Graphic."), /* STID_Q_CVT_ICON_TO_GRP_IN_REPLACE */ N_("Replacing the graphic of an iconic object...\n\nWould you like to convert the object into a grouped object? [ync](y)\n\n(If you press the No button, you will be prompted with the name of a new symbol file the iconic object. If you press Cancel, this object will be skipped for Replace Graphic.)"), /* STID_SHOW_MEASUREMENT_IN_TT_ENAB */ N_("Showing measurement in tooltip enabled."), /* STID_SHOW_MEASUREMENT_IN_TT_DISB */ N_("Showing measurement in tooltip disabled. Measurement will be shown in the ruler window."), /* STID_SEL_JPEG_FILE_TO_IMPORT */ N_("Please select a JPEG file to IMPORT..."), /* STID_CANNOT_IMPORT_GIVEN_JPEG */ N_("Cannot import JPEG file '%s'."), /* STID_GIVEN_JPEG_SIZE_FILE_IMPORTED */ N_("JPEG file (%1dx%1d) '%s' imported."), /* STID_WILL_EXPORT_JPEG_FILE */ N_("Will export JPEG (needs xpm->jpg filter) file."), /* STID_NETPBM_JPEG_VST_HOME_PAGE */ N_("(These programs are part of the netpbm and jpeg packages. Please visit %s's home page at regarding where to obtain netpbm and jpeg.)"), /* STID_CANT_GEN_PREVIEW_FOR_PS */ N_("Cannot auto-generate a preview bitmap for '%s'."), /* STID_CANT_GEN_PREVIEW_FOR_EMPTY_PS */ N_("The auto-generate preview bitmap for '%s' is empty. Auto-generation skipped."), /* STID_WILL_AUTO_GEN_PREVIEW_BITMAP */ N_("Will auto-generate a preview bitmap when importing/embedding a PS/EPS file."), /* STID_WONT_AUTO_GEN_PREVIEW_BITMAP */ N_("Will not auto-generate a preview bitmap when importing/embedding a PS/EPS file."), /* STID_TMP_DIR_NOT_EXIST_USE_XDEF */ N_("Temporary directory '%s' does not exist. Please fix the %s.%s X default."), /* STID_INVALID_DIR_IN_X_DEFAULT */ N_("Invalid directory '%s' specified by X default %s.%s."), /* STID_RACE_IN_CREATE_TMP_FILE */ N_("Race condition detected in creating the '%s' temporary file. Possible causes are network problems, security problems, etc. This file will be removed before proceeding."), /* STID_INVALID_GEOM_USE_ALT_GEOM */ N_("Invalid %s.%s: '%s', the geometry must be at least '%s', '%s' is used instead."), /* STID_REDUCE_BY_FACTOR */ N_("Reducing by a factor of %.2f..."), /* STID_ENLARGE_BY_FACTOR */ N_("Enlarging by a factor of %.2f..."), /* STID_CREATE_THUMBNAIL_CAUSE_FLUSH */ N_("Create Thumbnails will cause the undo buffer to be flushed."), /* STID_CONNECT_PORTS_CANCEL_BY_USER */ N_("Connect ports canceled by the user."), /* STID_Q_CNFLCT_SIG_NAME_OKAY_TO_CLR */ N_("Conflicting signal names '%s' (at '%s') and '%s' (at '%s').\n\nOkay to clear both signal names? [ync](y)"), /* STID_PLS_ENT_SIG_NAME */ N_("Please enter a signal name:"), /* STID_SIGNAL_NAMES_CLEARED */ N_("Signal names at '%s' and '%s' have been cleared."), /* STID_PLACING_NAMED_SIGNAL */ N_("Click to place signal name '%s'"), /* STID_PLS_ENT_SIG_NAME_FOR_PORT */ N_("Please enter a signal name for the '%s' port:"), NULL }; static char *gaszEnglishStrTable1300[] = { /* STID_NO_CUR_FILE_CANNOT_GEN_NETLST */ N_("No current file.\n\nCannot generate a net list."), /* STID_NO_SIGNAME_FOUND_EMPTY_NETLST */ N_("No signal name found.\n\nNet list not generated."), /* STID_WILL_EXPORT_NETLIST_FILE */ N_("Will export net-list file."), /* STID_Q_OK_TO_CUT_INTO_SEGMENTS */ N_("Okay to cut selected polyline/polygon objects into segments? [ync](y)\n\n(If you would like to cut at a specific vertex of the polyline/polygon, please use the vertex mode.)"), /* STID_NO_POLY_OBJ_SELECTED */ N_("No polyline/polygon object selected."), /* STID_WILL_SHOW_WIRE_SIGNAL_NAME */ N_("Will show (and place) wire signal name when connecting ports."), /* STID_WILL_HIDE_WIRE_SIGNAL_NAME */ N_("Will hide wire signal name when connecting ports."), /* STID_TRY_AGAIN_AND_CLICK_IN_A_PORT */ N_("Please try again and click in a port."), /* STID_TRY_AGAIN_AND_END_IN_A_PORT */ N_("The last vertex did not end in a port, please try again."), /* STID_CANNOT_CREATE_ARC_WITH_RAD1 */ N_("%s cannot create an arc with radius %1d (must be at least 1)."), /* STID_SEL_ONE_NONE_PORT_PLUS_COMP */ N_("Please select at least one port object and a composite object."), /* STID_PORT_OBJ_HAS_EMPTY_NAME */ N_("The port object has an empty name."), /* STID_CANNOT_FIND_INIT_ATTR_PORT_PA */ N_("Cannot find the 'Initialization=' attribute of the '%s' object (parent of the port object)."), /* STID_CANNOT_FIND_VAR_IN_INIT_ATTR */ N_("Cannot find the '%s' variable in the 'Initialization=' attribute of the '%s' object (parent of the port object)."), /* STID_RENUMBER_OBJ_IDS_CAUSE_FLUSH */ N_("Renumber Object IDs will cause the undo buffer to be flushed."), /* STID_RENUMBER_OBJ_IDS_DONE */ N_("Renumbering object IDs done."), /* STID_RENUMBER_OBJ_IDS_IN_WB */ N_("RenumberObjectIDs() is disabled in WhiteBoard mode."), /* STID_SEL_ONE_NONE_PORT_PLUS_BRDCST */ N_("Please select at least one port object and a broadcast wire object."), /* STID_CONFLICT_SIG_NAME_ENT_NEW */ N_("Conflicting signal names detected. Please entry a valid signal name for all the ports:"), /* STID_BAD_SIG_NAME_UNDO_AND_REDO */ N_("Invalid or inconsistent signal names are given to the ports. Please undo the previous operation and redo it again."), /* STID_WILL_USE_WORDWRAP_IMPORT_TEXT */ N_("Will use word wrap when importing a multipage text file."), /* STID_NO_WORDWRAP_IMPORT_TEXT */ N_("Will not use word wrap when importing a multipage text file."), /* STID_CUR_MARGINS_ARE_GIVEN */ N_("( current margins (top, bottom, left, right) are: %s )"), /* STID_ENTER_MARGINS */ N_("Please enter margins to be used when importing a multipage text file: [top,bottom,left,right] (e.g., %s -- the three commas are mandatory)"), /* STID_NEW_MARGINS_ARE_GIVEN */ N_("New margins for import multipage text file are (top, bottom, left, right):"), /* STID_CANT_OBTAIN_TMP_FILE_NAME */ N_("Cannot obtain a temporary file name using mkstemp() from the following request: '%s'. Will use mktemp() instead."), /* STID_NO_OBJ_SPEC_WHILE_EXEC_CMD */ N_("Non object specified while executing the '%s' command."), /* STID_UNRECOG_GIVEN_TRPIX_VAL_PRINT */ N_("Unrecognized transparent pixel value at (%1d,%1d): %1d (0x%08lx).\n\nPrinting/exporting aborted."), /* STID_TGIF_DISTRUBITION */ N_(" [distribution: %s]"), /* STID_WRITE_TO_SELF_PIPE_FAIL */ N_("Fail to write to the pipe that talks to %s itself."), /* STID_CREATE_SELF_PIPE_FAIL */ N_("Fail to create the pipe that talks to %s itself."), /* STID_READ_FROM_SELF_PIPE_FAIL */ N_("Fail to read %1d byte from the pipe that talks to %s itself."), /* STID_ENTER_BEZIER_NUM_SEGS_CUR_IS */ N_("Please enter the number of segments for the Convert To Bezier command (current value is %1d):"), /* STID_BEZIER_NUM_SEGS_SET_TO_INT */ N_("Number of segments for the Convert To Bezier command set to %1d."), /* STID_ENT_VAL_RANGE_ENTER_GE_INT */ N_("The value entered: '%s' is out of range.\n\nPlease enter a value >= %1d."), /* STID_ENTER_TICK_MARK_SIZE_CUR_IS */ N_("Please enter the tick mark size for the various Add Tick Mark commands (current value is %1d):"), /* STID_TICK_MARK_SIZE_SET_TO_INT */ N_("Tick mark size set to %1d."), /* STID_NO_SPLINE_SELECTED */ N_("No polyline or simple spline objects selected."), /* STID_SPLINE_CONVERTED_TO_BEZIER */ N_("Spline objects converted to Bezier curves."), /* STID_PEEK_DIM_LEFT */ N_("The x-coordinate of the left most part of the selected object."), /* STID_PEEK_DIM_TOP */ N_("The y-coordinate of the top most part of the selected object."), /* STID_PEEK_DIM_RIGHT */ N_("The x-coordinate of the right most part of the selected object."), /* STID_PEEK_DIM_BOTTOM */ N_("The y-coordinate of the bottom most part of the selected object."), /* STID_PEEK_DIM_WIDTH */ N_("The width of the selected object."), /* STID_PEEK_DIM_HEIGHT */ N_("The height of the selected object."), /* STID_PEEK_DIM_CX */ N_("The x-coordinate of the center of the selected object."), /* STID_PEEK_DIM_CY */ N_("The y-coordinate of the center of the selected object."), /* STID_NO_POLY_ETC_SELECTED */ N_("No polyline/polygon/spline objects selected."), /* STID_SEL_A_SYM_TO_INSTAN_IN_NONE */ N_("Please select a symbol to INSTANTIATE..."), /* STID_WRITE_NOT_AUTO_IN_HYPER_EXEC */ N_("Writing into file is not automatic in hyperspace. Do you want to allow writing into '%s'?\n\n(If you are not sure about this, just click on NO.)"), /* STID_USER_ABORT_WRITE_IN_HYPER */ N_("Writing into file in hyperspace aborted at user's request."), /* STID_READ_FROM_SELF_PIPE_OVERFLOW */ N_("Buffer overflow while reading the pipe that talks to %s itself."), /* STID_BAD_CMDLINE_OPT_USE_ALT_STR */ N_("Invalid commandline option %s=\"%s\", \"%s\" is used instead."), /* STID_BAD_CMDLINE_OPT_IGNORED */ N_("Invalid commandline option %s=\"%s\"; it is ignored."), /* STID_OBSOLETE_CMDLINE_ASSUME */ N_("The %s commandline option is obsolete; assuming you mean %s."), /* STID_INVALID_XDEF_IGNORED */ N_("Invalid %s.%s: '%s'. Resource ignored."), /* STID_OBSOLETE_XDEF_REPLACED */ N_("Obsoleted %s.%s used. Assuming %s.%s to have the value of '%s' instead."), /* STID_FILE_IS_MARKED_UNSAVABLE */ N_("File is marked unsavable."), /* STID_ONLYONE_DBIM_OR_SBIM */ N_("Only one -dbim or -sbim can be used."), /* STID_DBIM_UNSUPPORTED */ N_("The double-byte input method: '%s' is not supported."), /* STID_SBIM_UNSUPPORTED */ N_("The single-byte input method: '%s' is not supported."), /* STID_CANNOT_OPEN_IN_SLIDESHOW */ N_("Please exit the slideshow mode before opening a new file."), /* STID_TOGGLE_AUTO_SCR_IN_CHAT */ N_("Toggle auto scroll mode in the chat list."), /* STID_TOGGLE_BOLD_IN_CHAT */ N_("Toggle bold font in chat."), /* STID_TOGGLE_ITALIC_IN_CHAT */ N_("Toggle italic font in chat."), /* STID_SEND_CHAT_TEXT */ N_("Send text to all whiteboard participants."), /* STID_MALFORMED_CHAT_LINE */ N_("Malformed chat line '%s'."), /* STID_UNRECOG_FIELD_IN_CHAT_LINE */ N_("Unrecognized '%s' field in a chat line."), /* STID_UNRECOG_BYTE_FROM_SELF_PIPE */ N_("Unrecognized byte value '%c' read from the pipe that talks to %s itself."), /* STID_JOIN_WB_IN_PROGRESS_IGNORED */ N_("Joining a whiteboard session already in progress. Request to open the '%s' file at startup is ignored."), /* STID_PEEK_AREA */ N_("The area of the selected object (polygon must not be self-intersecting)."), /* STID_CANT_DO_SAVEPAGEAS_IN_TILED */ N_("Cannot do SavePageAs() in TILED page mode."), /* STID_SPECIFY_PAGES_TO_SAVE_EX */ N_("Please specify pages to save into a new file: (e.g., 2,3,7-9,10)"), /* STID_ONE_PAGE_SAVED_INTO_GIVEN */ N_("1 page saved into '%s'."), /* STID_MANY_PAGES_SAVED_INTO_GIVEN */ N_("%1d pages saved into '%s'."), /* STID_CANT_IMP_ANIM_GIF_DIR_OR_PATH */ N_("Cannot import GIF animation file '%s'. Please make sure that you can write to the '%s' directory.\n\nPlease also make sure that '%s' is installed properly."), /* STID_WILL_EXPORT_PPM_FILE */ N_("Will export PPM file."), /* STID_NETPBM_VST_HOME_PAGE */ N_("(This program is part of the netpbm packages. Please visit %s's home page at regarding where to obtain netpbm.)"), /* STID_SEL_PPM_FILE_TO_IMPORT */ N_("Please select a PPM file to IMPORT..."), /* STID_CANNOT_IMPORT_GIVEN_PPM */ N_("Cannot import PPM file '%s'."), /* STID_GIVEN_PPM_SIZE_FILE_IMPORTED */ N_("PPM file (%1dx%1d) '%s' imported."), /* STID_IMPORT_FORMAT_WHILE_EXEC_CMD */ N_("Fail to import '%s' in the '%s' format while executing the '%s' command."), /* STID_NO_OBJ_TO_IMP_WHILE_EXEC_CMD */ N_("No object to import in '%s' while executing the '%s' command."), /* STID_CANNOT_LOAD_TGTWB5_FONT */ N_("Cannot load the '%s' font. Please specify a valid zh_TW.big5 font using the %s.%s X default (syntax is \"%s,FONTNAME\")."), /* STID_TOOL_BIG5_CHINESE_KEYPAD */ N_("%s - Traditional Chinese (zh_TW.big5) Keypad"), /* STID_USE_ZYFH_KEYPAD_OR_PINYING */ N_("Please select using zhu-yin-fu-hao keypad\nor enter pin-ying directly..."), /* STID_INVALID_PINYIN_SEQ */ N_("The sequence: '%s', is not a valid sequence."), /* STID_ADD_ZYFH */ N_("Add a zhu-yin-fu-hao symbol"), /* STID_FETCH_CHAR */ N_("Fetch characters"), /* STID_BACKOUT_ZYFH */ N_("Back out a zhu-yin-fu-hao symbol"), /* STID_SELECT_A_CHAR */ N_("Select a character."), /* STID_SEND_A_CHAR_TO_DRAWING_AREA */ N_("Select and send a character to the drawing area."), /* STID_CLICK_SEND_TO_SEND_CHAR */ N_("Click on the Send button to send selected character to the drawig area."), /* STID_FETCH_CHARS_FROM_DB */ N_("Fetch characters from the database."), /* STID_SEND_SEL_CHAR_TO_DRAWING_AREA */ N_("Send selected character to the drawing area."), /* STID_SEND_CR_TO_DRAWING_AREA */ N_("Send to the drawing area."), /* STID_OK_TO_RESET_GIVEN_IM */ N_("Okay to reset the connection to the '%s' input method?"), /* STID_GIVEN_IM_RESETED */ N_("Connection to the '%s' input method has been reset."), /* STID_WILL_EXPORT_PBM_FILE */ N_("Will export PBM file."), /* STID_SEL_PBM_FILE_TO_IMPORT */ N_("Please select a PBM file to IMPORT..."), NULL }; static char *gaszEnglishStrTable1400[] = { /* STID_CANNOT_IMPORT_GIVEN_PBM */ N_("Cannot import PBM file '%s'."), /* STID_GIVEN_PBM_SIZE_FILE_IMPORTED */ N_("PBM file (%1dx%1d) '%s' imported."), /* STID_WILL_EXPORT_PGM_FILE */ N_("Will export PGM file."), /* STID_SEL_PGM_FILE_TO_IMPORT */ N_("Please select a PGM file to IMPORT..."), /* STID_CANNOT_IMPORT_GIVEN_PGM */ N_("Cannot import PGM file '%s'."), /* STID_GIVEN_PGM_SIZE_FILE_IMPORTED */ N_("PGM file (%1dx%1d) '%s' imported."), /* STID_CANNOT_IDEN_GS */ N_("Problem identifying which version of ghostscript you are running ('%s')."), /* STID_TOOL_NOT_INTV_WHILE_EXEC_CMD */ N_("%s is not running in the interactive mode while executing the '%s' command."), /* STID_CONVERT_TO_XBM_WHILE_EXEC_CMD */ N_("Fail to convert '%s' from the '%s' format to XBM format while executing the '%s' command."), /* STID_FUNC_ARG_STRS_RANGE */ N_("%s(): '%s' must be between %s and %s (inclusive).\n\n%s was specified."), /* STID_WARN_CANNOT_FIND_SOME_ATTRS */ N_("Warning: some attributes in '%s' cannot be found.\n\nOkay to continue and edit the attributes which have been found? [ync](y)"), /* STID_BAD_LINE_MAY_HAVE_DEL_EQUAL */ N_("Malformed line: '%s'.\n\nYou may have accidentally deleted a '=' symbol. Please make a note of it."), /* STID_ATTR_NAME_CHANGED_IMPORT_Q */ N_("You may have changed the name of an attribute. The new attribute name is '%s'. Do you want to import this new attribute? [ync](y)"), /* STID_CANT_IMPORT_ATTR_GROUP_RETRY */ N_("Since there are malformed input lines, %s cannot import the attribute group. Please fix the malformed lines and try again.\n\nIf you would like to abort editing this attribute group, please exit your editor without saving the content."), /* STID_TGIF_FLAGS */ N_(" [flags: %s]"), /* STID_INVALID_COMPILER_OPT */ N_("Malformed compiler option -D%s: '%s'."), /* STID_EXECUTING_GIVEN_SCRIPT */ N_("Executing from '%s'..."), /* STID_STAT_FAILED_WHILE_IMPORT_LINK */ N_("Fail to get file info for '%s' while importing/linking %s file."), /* STID_SEL_JPEG_FILE_TO_LINKTO */ N_("Please select a JPEG file to link to..."), /* STID_INVALID_PARAM_LINKED_JPEG */ N_("Invalid parameters encountered while reading a linked JPEG object."), /* STID_INVALID_PATH_WHILE_READ_JPEG */ N_("File '%s' does not exist while reading a linked JPEG object."), /* STID_PRTGIF_LINK_JPEG_SKIPPED */ N_("Linked JPEG object (linked to '%s') skipped. Please consider running %s with the \"-display\" commandline option."), /* STID_DUP_SHORTCUT_FUNCTION_KEY */ N_("Warning: duplicate shortcut entry for 'F%1d'."), /* STID_BAD_STYLE_NAME_WHILE_EXEC_CMD */ N_("Invalid text style of '%s' used while executing the '%s' command."), /* STID_CANT_ACQUIRE_X_SELECTION */ N_("Cannot acquire the X selection while performing a paste operation. Will only copy to X cutbuffer."), /* STID_NO_TEXT_SELECTED_FOR_COPY */ N_("No text selected for the copy/cut operation."), /* STID_PASTE_FAILED_CONV_REFUSED */ N_("Paste failed because selection conversion was refused."), /* STID_BAD_XDEF_MISS_TOKEN_NAME_SKIP */ N_("Invalid entry '%s' (missing token name) in %s.%s, skipped."), /* STID_BAD_XDEF_CANT_FIND_TOKEN_SKIP */ N_("Invalid entry '%s' (cannot find %s) in %s.%s, skipped."), /* STID_BAD_XDEF_MISS_CHAR_NAME_SKIP */ N_("Malformed entry '%s' (missing character name) in %s.%s, skipped."), /* STID_DUP_CHAR_CODE_XDEF_IGNORED */ N_("Duplicate character code %1d (8#%03o) detected in %s.%s, new value ignored."), /* STID_FAIL_TO_PARSE_CHAR_CODE_XDEF */ N_("Fail to parse '%s' for a character code value for taken '%s' while processing X default %s.%s."), /* STID_CHAR_CODE_OUT_OF_RANGE_XDEF */ N_("Character code specified as '%s' for token '%s' is out of range in %s.%s. The value must be between 161 and 255 (inclusive)."), /* STID_BAD_FAKE_FONT_NAME_NO_ALIAS */ N_("In processing %s.%s, the fake font name '%s' is not valid because there is no corresponding entry in %s.%s."), /* STID_CANT_FIND_PS_CHAR_SUBS_READ */ N_("Cannot find ps_char_subs(\"%s\",[...]) object while reading the input file."), /* STID_DUP_TOKEN_PS_CHAR_SUBS_READ */ N_("Duplicate ps_char_subs(\"%s\",[...]) object detected reading the input file."), /* STID_FAIL_TO_PARSE_CHAR_CODE_FILE */ N_("Fail to parse '%s' for a character code value for taken '%s' while processing the input file."), /* STID_CHAR_CODE_OUT_OF_RANGE_FILE */ N_("Character code specified as '%s' for token '%s' is out of range while processing the input file. The value must be between 161 and 255 (inclusive)."), /* STID_DUP_CHAR_CODE_FILE_IGNORED */ N_("Duplicate character code %1d (8#%03o) detected while processing the input file, new value ignored."), /* STID_CMDLINE_ARG_GIVEN_TOO_LONG */ N_("The commandline argument for '%s' is too long. Please use a shorter one."), /* STID_CANT_IMPORT_GIVEN_PPM_MALFORM */ N_("Failed to import PPM file '%s'. The P6 format is expected but the file seems to be malformed."), /* STID_PPM6_DIM_NOT_MATCH */ N_("The dimension (%1dx%1d) of the PPM file '%s' does not match the stored dimension (%1dx%1d)."), /* STID_UNSUP_PPM6_MAX_VAL */ N_("The maximum color value (%1d) for the PPM file '%s' is not supported. Only the value of 255 is supported."), /* STID_JPEG_DIM_NOT_MATCH_DELETED */ N_("The dimension (%1dx%1d) of the linked JPEG file '%s' does not match the stored dimension (%1dx%1d). The JPEG object is removed."), /* STID_ENTER_XY_OFFSET_OBJ_SHADOW */ N_("Please enter X and Y offsets for generic object shadow: [current: %1d,%1d]"), /* STID_OBJ_SHADOW_XY_OFFSETS_SET_TO */ N_("Generic object shadow offsets set to: %1d, %1d."), /* STID_ENTER_A_COLOR_FOR_OBJ_SHADOW */ N_("Please enter a color for the generic object shadow: [current: %s]"), /* STID_OBJ_SHADOW_COLOR_SET_TO_NAMED */ N_("Generic object shadow color set to '%s'."), /* STID_NO_OBJ_SHADOW_FOUND */ N_("None of the selected object seem to have a generic object shadow."), /* STID_TRANS_XPM_TOO_MANY_COLORS_SKP */ N_("Too many colors (%1d, which is > 255) in an xpm objects with transparent pixels. This object is skipped during printing."), /* STID_NEED_DISABLE_UNDO_WILL_CRASH */ N_("Referencing an off page object while undo is enabled. If %s crashes, please modify your script to call \"disable_undo()\" before running it again."), /* STID_CANT_LOAD_INITIAL_FONT */ N_("Warning: Cannot load the following initial font: '%s'. To specify a different initial font, please use %s.InitialFont, %s.InitialFontStyle, and %s.InitialFontSize."), /* STID_CANT_CHNG_FONT_SUPSUB_CENTER */ N_("Cannot switch font in a center-script object."), /* STID_JOIN_WB_IN_PROGRESS_FAILED */ N_("Joining a whiteboard session already in progress has failed. The state of the whiteboard may not be consistent with other whiteboards. It's probably best to exit and restart."), /* STID_JOIN_WB_IN_FAILED_NO_CONTTYPE */ N_("Joining a whiteboard session already in progress has failed - cannot find Content-Type. The state of the whiteboard may not be consistent with other whiteboards. It's probably best to exit and restart."), /* STID_INVALID_RMCAST_DLIB_PATH */ N_("Invalid path: '%s' for the rmcast dynamic library. %s will exit now."), /* STID_NO_INFO_LIBRMCAST_SO */ N_("Fail to load shared library '%s'. There is no information about where to find %s. Please run %s with the -rmcastlibdir or the -rmcastlibpath commandline option. %s will exit now."), /* STID_BAD_VER_RMCAST_DLIB */ N_("Malformed interface version information: '%s' received from the rmcast dynamic library '%s'."), /* STID_CANNOT_HANDLE_VER_RMCAST_DLIB */ N_("%s does not know how to handle interface version: '%s' for the rmcast dynamic library '%s'."), /* STID_MISSING_RMCASTDIR */ N_("Directory for the '-rmcastlibdir' commandline argument is missing."), /* STID_NO_PTHREAD_CONTINUE */ N_("%s is not compiled with the -DPTHREAD flag and will not be able to run in the tgwb2 mode. Please restart %s without the -tgwb2 commandline option. %s will exit now."), /* STID_INVALID_GIVEN_PARAM_GIVEN_OBJ */ N_("Invalid %s parameters encountered while reading a %s object."), /* STID_CANNOT_INFLATE_GIVEN_OBJ */ N_("Cannot uncompress %s object with zlib because either zlib is not supported on this machine or %s is compiled with the -D_NO_ZLIB compiler option."), /* STID_BAD_LINE_READING_GIVEN_OBJ */ N_("Malformed input line while reading a %s object."), /* STID_INSUF_DATA_READING_GIVEN_OBJ */ N_("Insufficient data while reading a %s object."), /* STID_PATTERNDIR_NOT_EXIST */ N_("Customer pattern directory '%s' does not exist. Will use the default patterns."), /* STID_MISSING_RMCASTLIB */ N_("File path for the '-rmcastlibpath' commandline argument is missing."), /* STID_INVALID_XBM_CUST_PAT */ N_("Invalid X11 bitmap file '%s'. It cannot not be used as a customer pattern."), /* STID_TRANS_PIX_NOT_SUP_PPM_TRUE */ N_("Transparent pixel is not supported for ppm_true objects."), /* STID_XPM_HAS_ATTR_IMGPROC */ N_("The command you have just selected: '%s' can only work with a single X11 Pixmap object that does not have attached attributes. Please detach its attributes and try again."), /* STID_PPM_TRUE_LOSSY_CONV_TO_XPM */ N_("A ppm_true object has been converted to a regular XPM object (may have lost some colors)."), /* STID_SWITCHED_TO_AUTO_ROTATE_PIVOT */ N_("Switched to using automatic rotation pivot."), /* STID_SWITCHED_TO_USER_ROTATE_PIVOT */ N_("Switched to using user-specified rotation pivot."), /* STID_NEW_ROTATE_PIVOT_IS */ N_("Rotation pivot is at: (%1d,%1d)."), /* STID_ENTER_ROT_PIVOT */ N_("Please enter rotation pivot pixel coordinate: [X,Y]"), /* STID_ENTER_ROT_PIVOT_CUR_IS */ N_("Please enter rotation pivot pixel coordinate: [X,Y] (current rotation pivot is at (%1d,%1d))"), /* STID_ROT_PIVOT_SET_TO */ N_("Rotation pivot set to: (%1d,%1d)."), /* STID_VISIBLE_ROTATE_PIVOT */ N_("User-specified rotation pivit will be visible in select mode."), /* STID_NOT_VISIBLE_ROTATE_PIVOT */ N_("User-specified rotation pivit will not be visible in select mode."), /* STID_SELONLYONEPOLYOBJ */ N_("Please make sure that you have only a poly/polygon object selected and that you are in the rotate/shear mode with user-specified rotation pivot enabled."), /* STID_SELONLYONEARCOBJ */ N_("Please make sure that you have only an arc object selected and that you are in the rotate/shear mode with user-specified rotation pivot enabled."), /* STID_WILL_EXPORT_SVG_FILE */ N_("Will export SVG (needs eps->svg filter) file."), /* STID_TOOL_COLOR_WHEEL */ N_("%s - Choose A Color"), /* STID_COLOR_WHEEL_NOT_AVAIL */ N_("Color wheel is not available for your display type (must be a TrueColor display)."), /* STID_GIVEN_VAL_MUST_BE_LE */ N_("The %s value must be less than or equal to %1d)."), /* STID_TWO_VERTEX_POLY_ONLY */ N_("Please select a two-vertex polyline."), /* STID_ENTER_MULT_FACTOR */ N_("Please enter a multiplicative factor (1.0 means no adjustment and a negative value will extend the line segment in the opposite direction):"), /* STID_RES_LINESEG_HAVE_ZERO_LEN */ N_("Resulting line segment will have a length of zero and cannot be used."), /* STID_WILL_USE_TIGHTER_SPLINES */ N_("Will use tighter structured splines."), /* STID_WILL_USE_LOOSER_SPLINES */ N_("Will use original (looser) splines tightness for structured splines."), /* STID_TWO_CONSEC_VERTICES_ONLY */ N_("Please select two consecutive vertices of a polyline object."), /* STID_LINE_TYPE_IS_STRUCT_SPLINE */ N_("Line type is 'structured spline'."), /* STID_ONE_V_STRUCT_SPLINE_IN_V_MODE */ N_("Can only select one vertex for a structured spline object in vertex mode."), /* STID_SHUTTING_DOWN_WHITEBOARD */ N_("Shutting down whiteboard"), /* STID_SOME_LT_FAILED_TO_CONVERT */ N_("Some conversion of line types cannot be performed."), /* STID_CANNOT_CONVERT_SEL_LINETYPE */ N_("Cannot convert the line type for selected objects."), /* STID_CANNOT_CONVERT_TO_STRUCT_SPLN */ N_("Cannot convert selected objects to structures splines."), /* STID_ADD_HINGE_VERTEX */ N_("Add hinge vertex"), /* STID_ADD_A_SMOOTH_VERTEX */ N_("Add smooth vertex (for a hinge vertex)"), /* STID_CANNOT_ADD_SMOOTH_VERTEX */ N_("Cannot add a smooth vertex at this vertex."), NULL }; static char *gaszEnglishStrTable1500[] = { /* STID_LEFT_ADD_HINGE_MID_ADD_SMOOTH */ N_("Drag left mouse button to add a HINGE point and middle mouse button to add a SMOOTH point."), /* STID_CLICK_RIGHT_BUTTON_TO_QUIT */ N_("Click right mouse button to quit."), /* STID_SELECTION_CONV_REFUSED */ N_("X selection conversion was refused (may not be a seerious problem)."), /* STID_TRY_PASTE_WITH_OLD_X_MECH */ N_("Attempting to paste using an older X mechanism (may not be able to paste very large objects with this mechanism)..."), /* STID_CANNOT_TOGGLE_FOR_STRUCT_SPLN */ N_("Cannot toggle Smooth/Hinge points for a structured spline object."), /* STID_SEL_2_COMPAT_END_PTS_TO_JOIN */ N_("Please select 2 end-point vertices from lines/curves of similar types."), /* STID_CANNOT_CUT_AT_SMOOTH_PT */ N_("Cannot cut a structured spline object at a smooth point. Please select a hinge point and try again."), /* STID_RIGHT_MARGIN_IS */ N_("Simple right margin is %s."), /* STID_RIGHT_MARGIN_DISABLED */ N_("Simple right margin is off."), /* STID_ENTER_RIGHT_MARGIN */ N_("Please enter (simple) right margin ' {pixel|cm|in}' (e.g., 1.5 inch, 2 cm, etc.):"), /* STID_CURRENT_RIGHT_MARGIN_IS */ N_("( current right margin: '%s' )"), /* STID_ERR_PARSE_THRESH_COLORS */ N_("Error in parsing threshold for flood fill and replace color: '%s'."), /* STID_FLOOD_REPLACE_ENABLED */ N_("Threshold-based Flood Fill and Replace Color will be used with RGB thresholds of %1d,%1d,%1d (out of 255)."), /* STID_FLOOD_REPLACE_DISABLED */ N_("Threshold-based Flood Fill and Replace Color will not be used."), /* STID_SET_FLOOD_REPLACE_THRESH */ N_("Please enter either a single threshold value (between 0 and 255) to be applied to all color components or thress such values (separted by commas): [current: %1d,%1d,%1d]"), /* STID_FLOOD_REPLACE_THRESH_SET_TO */ N_("Flood Fill and Replace Color threshold has been set to: %1d,%1d,%1d."), /* STID_BADPNG_SHORT_HEADER */ N_("Malformed PNG file. Cannot read the 8 bytes header."), /* STID_BADPNG_BAD_HEADER */ N_("Malformed PNG file. Invalid bytes in header."), /* STID_BADPNG_BAD_PALETTE_LEN */ N_("Malformed PNG file. Palette length is not a multiple of 3."), /* STID_BADPNG_BAD_CHUNK_LEN */ N_("Malformed PNG file. Invalid chunk length of %1d."), /* STID_BADPNG_SHORT_CHUNK_TYPE */ N_("Malformed PNG file. Cannot read 4 bytes of chunk type."), /* STID_BADPNG_SHORT_CRC */ N_("Malformed PNG file. Cannot read 4 bytes CRC."), /* STID_BAD_TRANS_COLOR_NO_TRANS */ N_("Malformed transparent color in a PPM_TRUE object. Transparency removed."), /* STID_CUR_COLOR_IS_TRANS_PIXEL */ N_("The current color (%s) is the same as the color being used as transparent pixels in a PPM_TRUE object; therefore, it cannot be used for the %s command."), /* STID_BAD_CMD_FOR_TRANS_PPMTRUE */ N_("Selected object is a PPM_TRUE object with a transparent color and cannot be used for running the %s command."), /* STID_SEL_ONE_XPM_TRANSPIX */ N_("Please select at least one X11 Pixmap objects with a transparent pixel."), /* STID_CANNOT_FIND_GOOD_TRANSPIX */ N_("Cannot find a suitable pixel to use as a transparent color pixel. Abort!"), /* STID_CANNOT_SET_XDEF_TRUE_NO_ZLIB */ N_("Cannot set %s.%s to 'true' because %s is not compile with zlib support. The value of 'false' is used."), /* STID_BAD_GIVEN_LINE_WRITTEN */ N_("Invalid '%s' line written into file. This will be reported as a problem writing to the file."), /* STID_TWO_XDEF_ONE_IGNORED */ N_("Conflicting %s.%s and %s.%s (both cannot be defined at the same time). %s.%s is ignored."), /* STID_BAD_ENCODING_TGTWB5_FONT */ N_("Unsupported font encoding for the '%s' font. The only support font encodings are \"big5\" and \"gb2312.1980\". Please specify a valid zh_TW.big5 or zh_CN.euc font using the %s.%s X default."), /* STID_TOOL_GB_CHINESE_KEYPAD */ N_("%s - Simplified Chinese (zh_CN.euc) Keypad"), NULL }; char *TgLoadString(nID) int nID; /* * Note: if ENABLE_NLS is defined, every one of this call will pay * the panelty of gettext(). So, make sure these strings are * not often used (such as error messages). * Note: the returned string is translated already. */ { if (nID >= MINNONCACHEDSTIDS && nID < MAXNONCACHEDSTIDS) { int index=(nID-MINNONCACHEDSTIDS); int which=(int)(index/100); switch (which) { case 0: return _(gaszEnglishStrTable[index]); case 1: return _(gaszEnglishStrTable100[index-100]); case 2: return _(gaszEnglishStrTable200[index-200]); case 3: return _(gaszEnglishStrTable300[index-300]); case 4: return _(gaszEnglishStrTable400[index-400]); case 5: return _(gaszEnglishStrTable500[index-500]); case 6: return _(gaszEnglishStrTable600[index-600]); case 7: return _(gaszEnglishStrTable700[index-700]); case 8: return _(gaszEnglishStrTable800[index-800]); case 9: return _(gaszEnglishStrTable900[index-900]); case 10: return _(gaszEnglishStrTable1000[index-1000]); case 11: return _(gaszEnglishStrTable1100[index-1100]); case 12: return _(gaszEnglishStrTable1200[index-1200]); case 13: return _(gaszEnglishStrTable1300[index-1300]); case 14: return _(gaszEnglishStrTable1400[index-1400]); default: return _(gaszEnglishStrTable1500[index-1500]); } } #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "Cannot find string table entry with ID=%1d.\n", nID); #endif /* _TGIF_DBG */ return NULL; } /* ===================== Special LoadString Routines ===================== */ /* --------------------- align.c --------------------- */ static char *distrDirectMenuStr[] = { N_("(none)"), N_("Distribute selected objects so that their top edges are equally spaced"), N_("Distribute selected objects so that their vertical centers are equally spaced"), N_("Distribute selected objects so that their bottom edges are equally spaced"), N_("Distribute selected objects so that they are equally spaced vertically"), N_("Distribute selected objects so that their left edges are equally spaced"), N_("Distribute selected objects so that their left and top edges are equally spaced"), N_("Distribute selected objects so that their left and vertical centers are equally spaced"), N_("Distribute selected objects so that their left and bottom edges are equally spaced"), N_("Distribute selected objects so that they are equally spaced vertically and their left edges are spaced equally"), N_("Distribute selected objects so that their horizontal centers are equally spaced"), N_("Distribute selected objects so that their horizontal centers and top edges are equally spaced"), N_("Distribute selected objects so that their horizontal and vertical centers are equally spaced"), N_("Distribute selected objects so that their horizontal centers and bottom edges are equally spaced"), N_("Distribute selected objects so that they are equally spaced vertically and their horizontal centers are spaced equally"), N_("Distribute selected objects so that their right edges are equally spaced"), N_("Distribute selected objects so that their right and top edges are equally spaced"), N_("Distribute selected objects so that their right and vertical centers are equally spaced"), N_("Distribute selected objects so that their right and bottom edges are equally spaced"), N_("Distribute selected objects so that they are equally spaced vertically and their right edges are spaced equally"), N_("Distribute selected objects so that they are equally spaced horizontally"), N_("Distribute selected objects so that they are equally spaced horizontally and their top edges are spaced equally"), N_("Distribute selected objects so that they are equally spaced horizontally and their vertical centers are spaced equally"), N_("Distribute selected objects so that they are equally spaced horizontally and their bottom edges are spaced equally"), N_("Distribute selected objects so that they are equally spaced horizontally and vertically"), NULL }; char *DistrDirectLoadString(nIndex) int nIndex; /* well, this menu is hard to get to, no need to cache the strings */ { return _(distrDirectMenuStr[nIndex]); } char *AlignedLoadString(hori_align, vert_align) int hori_align, vert_align; { switch ((hori_align<l); UtilFree(pmssr->m); UtilFree(pmssr->r); pmssr->l = pmssr->m = pmssr->r = NULL; } static void CleanUpChoiceQuickMouseStatusStrings() { FreeChoiceQuickMouseStatusStrings(&colorMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&hAlignMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&vAlignMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&pageMouseStatus[(PAGE_STACK<<1)+1]); FreeChoiceQuickMouseStatusStrings(&pageMouseStatus[(PAGE_TILE<<1)+1]); FreeChoiceQuickMouseStatusStrings(&pageLayoutMouseStatus[(PAGE_STACK<<1)+1]); FreeChoiceQuickMouseStatusStrings(&pageLayoutMouseStatus[(PAGE_TILE<<1)+1]); FreeChoiceQuickMouseStatusStrings(&justMouseStatus[(JUST_L<<1)+1]); FreeChoiceQuickMouseStatusStrings(&justMouseStatus[(JUST_C<<1)+1]); FreeChoiceQuickMouseStatusStrings(&justMouseStatus[(JUST_R<<1)+1]); FreeChoiceQuickMouseStatusStrings(&fontMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&vspaceMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&textSizeMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&lineWidthMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&lineStyleMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&lineTypeMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&lineDashMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&rcbRadiusMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&zoomMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&moveModeMouseStatus[(CONST_MOVE<<1)+1]); FreeChoiceQuickMouseStatusStrings(&moveModeMouseStatus[(UNCONST_MOVE<<1)+1]); FreeChoiceQuickMouseStatusStrings(&shapeMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&stretchableTextModeMouseStatus[(NO_STRETCHABLE_TEXT<<1)+1]); FreeChoiceQuickMouseStatusStrings(&stretchableTextModeMouseStatus[(STRETCHABLE_TEXT<<1)+1]); FreeChoiceQuickMouseStatusStrings(&fileMouseStatus[(PORTRAIT<<1)+1]); FreeChoiceQuickMouseStatusStrings(&fileMouseStatus[(LANDSCAPE<<1)+1]); FreeChoiceQuickMouseStatusStrings(&fillMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&penMouseStatus[1]); FreeChoiceQuickMouseStatusStrings(&transPatMouseStatus[(NO_TRANSPAT_MODE<<1)+1]); FreeChoiceQuickMouseStatusStrings(&transPatMouseStatus[(TRANSPAT_MODE<<1)+1]); FreeChoiceQuickMouseStatusStrings(&autoRotatePivotMouseStatus[1]); } void QuickSetMouseStatus(pmssr, index) struct MouseStatusStrRec *pmssr; int index; { if (pmssr[(index<<1)+1].l == NULL) { pmssr[(index<<1)+1].l = UtilStrDup(_(pmssr[index<<1].l)); pmssr[(index<<1)+1].m = UtilStrDup(_(pmssr[index<<1].m)); pmssr[(index<<1)+1].r = UtilStrDup(_(pmssr[index<<1].r)); if (pmssr[(index<<1)+1].l == NULL || pmssr[(index<<1)+1].m == NULL || pmssr[(index<<1)+1].r == NULL) { FailAllocMessage(); } } SetMouseStatus(pmssr[(index<<1)+1].l, pmssr[(index<<1)+1].m, pmssr[(index<<1)+1].r); } /* --------------------- color.c --------------------- */ static struct MouseStatusStrRec colorTabMouseStatus[] = { /* * note: the m field is used for the localized strings */ { N_("Shift All Tabs Down"), NULL, NULL }, { N_("Shift Tabs Down"), NULL, NULL }, { N_("Check All"), NULL, NULL }, { N_("Uncheck All"), NULL, NULL }, { N_("Shift Tabs Up"), NULL, NULL }, { N_("Shift All Tabs Up"), NULL, NULL }, { NULL, NULL, NULL } }; static struct MouseStatusStrRec shiftColorTabMouseStatus[] = { /* * note: the m field is used for the localized strings */ { N_("Shift All Tabs Down"), NULL, NULL }, { N_("Shift 10 Tabs Down"), NULL, NULL }, { N_("Check All"), NULL, NULL }, { N_("Uncheck All"), NULL, NULL }, { N_("Shift 10 Tabs Up"), NULL, NULL }, { N_("Shift All Tabs Up"), NULL, NULL }, { NULL, NULL, NULL } }; static void CleanUpColorMouseStatusStrings() { int index=0; for (index=0; index < 6; index++) { UtilFree(colorTabMouseStatus[index].m); colorTabMouseStatus[index].m = NULL; } for (index=0; index < 6; index++) { UtilFree(shiftColorTabMouseStatus[index].m); shiftColorTabMouseStatus[index].m = NULL; } } void SetColorMouseStatusStrings(shift_or_cntrl_down, index) int shift_or_cntrl_down, index; /* * Note: once such a string is loaded, it will never change. * So, don't put any data-dependent stuff here. */ { if (shift_or_cntrl_down) { if (shiftColorTabMouseStatus[index].m == NULL) { shiftColorTabMouseStatus[index].m = UtilStrDup(_(shiftColorTabMouseStatus[index].l)); if (shiftColorTabMouseStatus[index].m == NULL) FailAllocMessage(); } SetMouseStatus(shiftColorTabMouseStatus[index].m, TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PARANED_NONE)); } else { if (colorTabMouseStatus[index].m == NULL) { colorTabMouseStatus[index].m = UtilStrDup(_(colorTabMouseStatus[index].l)); if (colorTabMouseStatus[index].m == NULL) FailAllocMessage(); } SetMouseStatus(colorTabMouseStatus[index].m, TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PARANED_NONE)); } } /* --------------------- cutpaste.c --------------------- */ struct PropInfoRec { long bit; char *localized; char *desc; }; static struct PropInfoRec gstPropStringTable[] = { /* * note: the localized field is used for the localized strings */ { PROP_MASK_AH, NULL, N_("arrow height") }, { PROP_MASK_AW, NULL, N_("arrow width") }, { PROP_MASK_ARROW_STYLE, NULL, N_("arrow style") }, { PROP_MASK_COLOR, NULL, N_("color") }, { PROP_MASK_DASH, NULL, N_("dash") }, { PROP_MASK_WIDTH, NULL, N_("line width") }, { PROP_MASK_TRANSPAT, NULL, N_("pattern transparency") }, { PROP_MASK_FILL, NULL, N_("fill") }, { PROP_MASK_PEN, NULL, N_("pen") }, { PROP_MASK_RCB_RADIUS, NULL, N_("rcbox radius") }, { PROP_MASK_CURVED, NULL, N_("spline") }, { PROP_MASK_TEXT_FONT, NULL, N_("text font") }, { PROP_MASK_TEXT_STYLE, NULL, N_("text style (no use, part of text font)") }, { PROP_MASK_TEXT_JUST, NULL, N_("text justification") }, { PROP_MASK_TEXT_SZ_UNIT, NULL, N_("text size") }, { PROP_MASK_VSPACE, NULL, N_("text vertical spacing") }, { PROP_MASK_UNDERLINE_ON, NULL, N_("text underline") }, { PROP_MASK_OVERLINE_ON, NULL, N_("text overline") }, { PROP_MASK_CTM, NULL, N_("transformation matrix") }, { PROP_MASK_WIDTH_INDEX, NULL, N_("line width index") }, { 0L, NULL, NULL } }; static void CleanUpPropertiesInfo() { struct PropInfoRec *ppir=NULL; for (ppir=gstPropStringTable; ppir->bit != 0L; ppir++) { UtilFree(ppir->localized); ppir->localized = NULL; } } char *PropLoadString(lWhich) long lWhich; /* * Note: once such a string is loaded, it will never change. * So, don't put any data-dependent stuff here. */ { struct PropInfoRec *ppir=NULL; for (ppir=gstPropStringTable; ppir->bit != 0L; ppir++) { if (ppir->bit == lWhich) { if (ppir->localized == NULL) { ppir->localized = UtilStrDup(_(ppir->desc)); if (ppir->localized == NULL) FailAllocMessage(); } return ppir->localized; } } #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "Cannot find properties string table entry with ID=0x%08lx.\n", lWhich); #endif /* _TGIF_DBG */ return NULL; } /* --------------------- grid.c --------------------- */ static struct MouseStatusStrRec exportFormatMouseStatus[] = { /* * note: the m field is used for the localized strings */ { N_("Set printing mode to print to a printer"), NULL, NULL }, { N_("Set printing mode to generate EPS files"), NULL, NULL }, { N_("Set printing mode to generate PS files"), NULL, NULL }, { N_("Set printing mode to generate X11 Bitmap files"), NULL, NULL }, { N_("Set printing mode to generate X11 Pixmap files"), NULL, NULL }, { N_("Set printing mode to generate ASCII files"), NULL, NULL }, { N_("Set printing mode to generate EPSI files"), NULL, NULL }, { N_("Set printing mode to generate GIF/ISMAP files"), NULL, NULL }, { N_("Set printing mode to generate HTML files"), NULL, NULL }, { N_("Set printing mode to generate PDF files"), NULL, NULL }, { N_("Set printing mode to generate DOS/Windows EPSI files"), NULL, NULL }, { N_("Set printing mode to generate PNG files"), NULL, NULL }, { N_("Set printing mode to generate JPEG files"), NULL, NULL }, { N_("Set printing mode to generate PBM files"), NULL, NULL }, { N_("Set printing mode to generate PPM files"), NULL, NULL }, { N_("Set printing mode to generate NetList files"), NULL, NULL }, { N_("Set printing mode to generate SVG files"), NULL, NULL }, { N_("Set printing mode to generate %s files"), NULL, NULL }, { NULL, NULL, NULL } }; static void CleanUpExportFormatMouseStatusStrings() { int index=0; for (index=0; index <= MAXDEFWHERETOPRINT+1; index++) { UtilFree(exportFormatMouseStatus[index].m); exportFormatMouseStatus[index].m = NULL; } } char *ExportFormatMenuLoadString(where_to_print, color_dump) int where_to_print, color_dump; /* returned string has been translated */ { if (where_to_print == XBM_FILE) { if (color_dump) { if (exportFormatMouseStatus[where_to_print+1].m == NULL) { exportFormatMouseStatus[where_to_print+1].m = UtilStrDup(_(exportFormatMouseStatus[where_to_print+1].l)); if (exportFormatMouseStatus[where_to_print+1].m == NULL) { FailAllocMessage(); } } return (exportFormatMouseStatus[where_to_print+1].m); } else { if (exportFormatMouseStatus[where_to_print].m == NULL) { exportFormatMouseStatus[where_to_print].m = UtilStrDup(_(exportFormatMouseStatus[where_to_print].l)); if (exportFormatMouseStatus[where_to_print].m == NULL) { FailAllocMessage(); } } return (exportFormatMouseStatus[where_to_print].m); } } else if (where_to_print == PPM_FILE) { if (color_dump) { if (exportFormatMouseStatus[where_to_print+2].m == NULL) { exportFormatMouseStatus[where_to_print+2].m = UtilStrDup(_(exportFormatMouseStatus[where_to_print+2].l)); if (exportFormatMouseStatus[where_to_print+2].m == NULL) { FailAllocMessage(); } } return (exportFormatMouseStatus[where_to_print+2].m); } else { if (exportFormatMouseStatus[where_to_print+1].m == NULL) { exportFormatMouseStatus[where_to_print+1].m = UtilStrDup(_(exportFormatMouseStatus[where_to_print+1].l)); if (exportFormatMouseStatus[where_to_print+1].m == NULL) { FailAllocMessage(); } } return (exportFormatMouseStatus[where_to_print+1].m); } } else if (where_to_print < XBM_FILE) { if (exportFormatMouseStatus[where_to_print].m == NULL) { exportFormatMouseStatus[where_to_print].m = UtilStrDup(_(exportFormatMouseStatus[where_to_print].l)); if (exportFormatMouseStatus[where_to_print].m == NULL) { FailAllocMessage(); } } return (exportFormatMouseStatus[where_to_print].m); } else if (where_to_print < PPM_FILE) { if (exportFormatMouseStatus[where_to_print+1].m == NULL) { exportFormatMouseStatus[where_to_print+1].m = UtilStrDup(_(exportFormatMouseStatus[where_to_print+1].l)); if (exportFormatMouseStatus[where_to_print+1].m == NULL) { FailAllocMessage(); } } return (exportFormatMouseStatus[where_to_print+1].m); } else if (where_to_print < MAXDEFWHERETOPRINT) { if (exportFormatMouseStatus[where_to_print+2].m == NULL) { exportFormatMouseStatus[where_to_print+2].m = UtilStrDup(_(exportFormatMouseStatus[where_to_print+2].l)); if (exportFormatMouseStatus[where_to_print+2].m == NULL) { FailAllocMessage(); } } return (exportFormatMouseStatus[where_to_print+2].m); } if (exportFormatMouseStatus[MAXDEFWHERETOPRINT+2].m == NULL) { exportFormatMouseStatus[MAXDEFWHERETOPRINT+2].m = UtilStrDup(_(exportFormatMouseStatus[MAXDEFWHERETOPRINT+2].l)); if (exportFormatMouseStatus[MAXDEFWHERETOPRINT+2].m == NULL) { FailAllocMessage(); } } return (exportFormatMouseStatus[MAXDEFWHERETOPRINT+2].m); } /* ===================== Init & CleanUp Routines ===================== */ void SetMouseStatusToAllNone() { SetMouseStatus(TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PARANED_NONE)); } void CleanUpStrTable() { int i=0; for (i=0; i < MAXCACHEDSTIDS; i++) { if (gaszCachedStrTable[i] != NULL) UtilFree(gaszCachedStrTable[i]); } for (i=0; i < MAXNONCACHEDSTIDS; i++) { if (gaszStrTable[i] != NULL) UtilFree(gaszStrTable[i]); } memset(gaszCachedStrTable, 0, sizeof(gaszCachedStrTable)); memset(gaszStrTable, 0, sizeof(gaszStrTable)); CleanUpChoiceMouseStatusStrings(); CleanUpChoiceQuickMouseStatusStrings(); CleanUpColorMouseStatusStrings(); CleanUpPropertiesInfo(); CleanUpExportFormatMouseStatusStrings(); } void InitStrTable() { memset(gaszStrTable, 0, sizeof(gaszStrTable)); } tgif-QPL-4.2.5/list.c0000644000076400007640000001263711602233312014114 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/list.c,v 1.6 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_LIST_C_ #include "tgifdefs.h" #include "list.e" #include "msg.e" /* -------------------- Utility Functions -------------------- */ int CompareForStringList(void *pv1, void *pv2) { return strcmp(((char*)pv1), ((char*)pv2)); } /* -------------------- CVListElem -------------------- */ static CVListElem *NewCVListElem(void *obj) { CVListElem *new_elem=(CVListElem*)malloc(sizeof(CVListElem)); if (new_elem == NULL) { FailAllocMessage(); return NULL; } memset(new_elem, 0, sizeof(CVListElem)); new_elem->obj = obj; return new_elem; } /* -------------------- CVList -------------------- */ int ListLength(CVList *list) { return list->num_members; } int ListEmpty(CVList *list) { return (list->num_members <= 0); } int ListAppend(CVList *list, void *obj) { CVListElem *new_elem=NewCVListElem(obj); if (new_elem == NULL) return FALSE; new_elem->next = &(list->anchor); new_elem->prev = list->anchor.prev; list->anchor.prev->next = new_elem; list->anchor.prev = new_elem; list->num_members++; return TRUE; } int ListPrepend(CVList *list, void *obj) { CVListElem *new_elem=NewCVListElem(obj); if (new_elem == NULL) return FALSE; new_elem->prev = &(list->anchor); new_elem->next = list->anchor.next; list->anchor.next->prev = new_elem; list->anchor.next = new_elem; list->num_members++; return TRUE; } void ListUnlink(CVList *list, CVListElem *elem) /* this will not free elem */ { elem->prev->next = elem->next; elem->next->prev = elem->prev; elem->next = elem->prev = NULL; list->num_members--; } void ListUnlinkAll(CVList *list) /* this frees all the elements */ { CVListElem *elem=NULL, *next_elem=NULL; for (elem=ListFirst(list); elem != NULL; elem=next_elem) { next_elem = ListNext(list, elem); elem->prev = elem->next = NULL; free(elem); } list->num_members = 0; list->anchor.next = list->anchor.prev = (&list->anchor); } int ListInsertAfter(CVList *list, void *obj, CVListElem *elem) { if (list->Empty(list) || elem == NULL) { return ListPrepend(list, obj); } else { CVListElem *new_elem=NewCVListElem(obj); if (new_elem == NULL) return FALSE; new_elem->next = elem->next; new_elem->prev = elem; new_elem->next->prev = new_elem; new_elem->prev->next = new_elem; list->num_members++; } return TRUE; } int ListInsertBefore(CVList *list, void *obj, CVListElem *elem) { if (list->Empty(list) || elem == NULL) { return ListAppend(list, obj); } else { CVListElem *new_elem=NewCVListElem(obj); if (new_elem == NULL) return FALSE; new_elem->prev = elem->prev; new_elem->next = elem; new_elem->next->prev = new_elem; new_elem->prev->next = new_elem; list->num_members++; } return TRUE; } CVListElem *ListFirst(CVList *list) { if (list->Empty(list)) return NULL; return list->anchor.next; } CVListElem *ListLast(CVList *list) { if (list->Empty(list)) return NULL; return list->anchor.prev; } CVListElem *ListNext(CVList *list, CVListElem *cur) { return (cur->next == (&list->anchor) ? NULL : cur->next); } CVListElem *ListPrev(CVList *list, CVListElem *cur) { return (cur->prev == (&list->anchor) ? NULL : cur->prev); } CVListElem *ListFind(CVList *list, void *obj, CMPFN *pcmpfunc) { CVListElem *ptr=NULL; for (ptr=ListFirst(list); ptr != NULL; ptr=ListNext(list, ptr)) { if (pcmpfunc == NULL) { if (ptr->obj == obj) { return ptr; } } else if ((pcmpfunc)(ptr->obj, obj) == 0) { return ptr; } } return NULL; } void CVListCleanUp(CVList *list) { if (list == NULL) return; if (list->num_members) { CVListElem *elem=NULL, *next_elem=NULL; for (elem=ListFirst(list); elem != NULL; elem=next_elem) { next_elem = ListNext(list, elem); free(elem); } } memset(list, 0, sizeof(CVList)); } int CVListInit(CVList *list) { if (list == NULL) return FALSE; memset(list, 0, sizeof(CVList)); list->num_members = 0; list->anchor.prev = list->anchor.next = (&list->anchor); list->First = ListFirst; list->Last = ListLast; list->Next = ListNext; list->Prev = ListPrev; list->Length = ListLength; list->Append = ListAppend; list->Prepend = ListPrepend; list->Unlink = ListUnlink; list->UnlinkAll = ListUnlinkAll; list->InsertBefore = ListInsertBefore; list->InsertAfter = ListInsertAfter; list->Find = ListFind; list->Empty = ListEmpty; return TRUE; } tgif-QPL-4.2.5/mainloop.c0000644000076400007640000017741711602233312014767 0ustar williamwilliam/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/mainloop.c,v 1.37 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_MAINLOOP_C_ #include "tgifdefs.h" #include "expfdefs.h" #include "patchlvl.h" #include "cmdids.h" #ifdef USE_XT_INITIALIZE #include #endif /* USE_XT_INITIALIZE */ #include "animate.e" #include "attr.e" #include "auxtext.e" #include "chat.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "edit.e" #include "eps.e" #include "exec.e" #include "expr.e" #include "file.e" #include "font.e" #include "ftp.e" #include "grid.e" #include "help.e" #include "http.e" #include "imgproc.e" #include "import.e" #include "ini.e" #include "inmethod.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "markup.e" #include "menu.e" #include "miniline.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "pin.e" #include "ps.e" #include "raster.e" #include "remote.e" #include "ruler.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "shape.e" #include "shortcut.e" #include "special.e" #include "stk.e" #include "strtbl.e" #include "tangram2.e" #include "text.e" #include "tgcwheel.e" #include "tginssym.e" #include "tidget.e" #include "util.e" #include "version.e" #include "wb.e" #include "xbitmap.e" #include "xpixmap.e" #include "xprtfltr.e" #ifdef USE_XT_INITIALIZE Widget toplevel=(Widget)0; #endif /* USE_XT_INITIALIZE */ int x11R6OrAbove=FALSE; int origArgC=0; char **origArgV=NULL; int cmdLineBW=FALSE; int cmdLineRV=INVALID; int cmdLineCWO=FALSE; int cmdLineBtn1Warp=FALSE; char *cmdLineForeground=NULL; char *cmdLineBackground=NULL; char *cmdLineBorder=NULL; int cmdLineMerge=FALSE; int cmdLineMergeArgc=0; char **cmdLineMergeArgv=NULL; int geometrySpecified=FALSE; int exitNormally=FALSE; char geometrySpec[80]; char *displayName=NULL; int initializingMain=FALSE; int cmdLineUseXlib=FALSE; int cmdLineVersion=FALSE; int cmdLineNoModeWindow=FALSE; int cmdLineNoChatWindow=FALSE; KeyOrBtnEvInfo lastKeyOrBtnEvInfo; int numExtraWins=0; struct WinInfoRec *extraWinInfo=NULL; PageInfo mergingPageInfo; static int maxExtraWins=0; static int quitDraw=TRUE; static int useXlib=FALSE; int AddExtraWinInfo(win, mapped, raise, expose_handler, ev_handler, cleanup_routine, userdata) Window win; int mapped, raise; void (*expose_handler)(); int (*ev_handler)(); void (*cleanup_routine)(); void *userdata; { register int i; for (i = 0; i < numExtraWins; i++) { if (extraWinInfo[i].window == None) { break; } } if (i == numExtraWins && numExtraWins == maxExtraWins) { maxExtraWins += 10; extraWinInfo = (struct WinInfoRec *)realloc(extraWinInfo, maxExtraWins*sizeof(struct WinInfoRec)); } extraWinInfo[i].window = win; extraWinInfo[i].mapped = mapped; extraWinInfo[i].raise = raise; extraWinInfo[i].expose_handler = expose_handler; extraWinInfo[i].ev_handler = ev_handler; extraWinInfo[i].cleanup = cleanup_routine; extraWinInfo[i].userdata = userdata; return ((i==numExtraWins) ? numExtraWins++ : i); } static void InitExtraWinInfo() { extraWinInfo = (struct WinInfoRec *)malloc(10*sizeof(struct WinInfoRec)); if (extraWinInfo == NULL) FailAllocMessage(); memset(extraWinInfo, 0, 10*sizeof(struct WinInfoRec)); maxExtraWins += 10; } static void CleanUpExtraWinInfo() { register int i; if (extraWinInfo != NULL) { for (i = 0; i < numExtraWins; i++) { if (extraWinInfo[i].window != None) { (*(extraWinInfo[i].cleanup))(&extraWinInfo[i]); } } free(extraWinInfo); } numExtraWins = 0; maxExtraWins = 0; extraWinInfo = NULL; } static void InitLastKeyOrBtnEvInfo() { memset(&lastKeyOrBtnEvInfo, 0, sizeof(KeyOrBtnEvInfo)); } void CleanUpTalkToSelfFiledes() { if (talkToSelfFiledesInitialized) { if (talkToSelfFiledes[0] != (-1)) close(talkToSelfFiledes[0]); if (talkToSelfFiledes[1] != (-1)) close(talkToSelfFiledes[1]); } talkToSelfFiledesInitialized = FALSE; talkToSelfFiledes[0] = talkToSelfFiledes[1] = (-1); } int InitTalkToSelfFiledes() { talkToSelfFiledesInitialized = FALSE; talkToSelfFiledes[0] = talkToSelfFiledes[1] = (-1); if (pipe(talkToSelfFiledes) != 0) { sprintf(gszMsgBox, TgLoadString(STID_CREATE_SELF_PIPE_FAIL), TOOL_NAME); fprintf(stderr, "%s\n", gszMsgBox); return FALSE; } talkToSelfFiledesInitialized = TRUE; return TRUE; } static char *MySetLocale(category, new_locale) int category; char *new_locale; { #ifndef _NO_LOCALE_SUPPORT return setlocale(category, new_locale); #else /* _NO_LOCALE_SUPPORT */ return NULL; #endif /* ~_NO_LOCALE_SUPPORT */ } static void ExecWithFile(CmdName, FileName) char *CmdName, *FileName; { char s[255]; #ifdef _BACKGROUND_DONT_FORK /* do not translate -- program constants */ sprintf(s, "xterm -bd red -e %s %s", CmdName, FileName); strcat(s, " &"); (void)system(s); #else /* ~_BACKGROUND_DONT_FORK */ int pid; /* do not translate -- program constants */ sprintf(s, "xterm -bd red -e %s %s", CmdName, FileName); pid = fork(); if (pid == 0) { (void)system(s); exit(0); } #endif /* _BACKGROUND_DONT_FORK */ } void DeallocStrings(FStr, Str1, Menu1, Str2, Menu2, Str3, Menu3) char **FStr, **Str1, **Menu1, **Str2, **Menu2, **Str3, **Menu3; { free(*FStr); free(*Str1); free(*Menu1); free(*Str2); free(*Menu2); free(*Str3); free(*Menu3); } static void AllocStrings(FStr, Str1, Menu1, Str2, Menu2, Str3, Menu3) char **FStr, **Str1, **Menu1, **Str2, **Menu2, **Str3, **Menu3; { char *s; if((s=(char*)malloc(80*sizeof(char))) == NULL) FailAllocMessage(); *FStr = s; **FStr = '\0'; if((s=(char*)malloc(80*sizeof(char))) == NULL) FailAllocMessage(); *Str1 = s; **Str1 = '\0'; if((s=(char*)malloc(80*sizeof(char))) == NULL) FailAllocMessage(); *Menu1 = s; **Menu1 = '\0'; if((s=(char*)malloc(80*sizeof(char))) == NULL) FailAllocMessage(); *Str2 = s; **Str2 = '\0'; if((s=(char*)malloc(80*sizeof(char))) == NULL) FailAllocMessage(); *Menu2 = s; **Menu2 = '\0'; if((s=(char*)malloc(80*sizeof(char))) == NULL) FailAllocMessage(); *Str3 = s; **Str3 = '\0'; if((s=(char*)malloc(80*sizeof(char))) == NULL) FailAllocMessage(); *Menu3 = s; **Menu3 = '\0'; } /* * static * int MyErrorHandler(display, event) * Display *display; * XErrorEvent *event; * { * if (event->type == 0) return TRUE; * printf("\tError: type -- %1d\n", event->type); * exit(-1); * } */ static void CleanUpMergeArgs() { if (cmdLineMergeArgv != NULL) { int i=0; for (i=0; i < cmdLineMergeArgc; i++) { UtilFree(cmdLineMergeArgv[i]); } free(cmdLineMergeArgv); } cmdLineMergeArgc = 0; cmdLineMergeArgv = NULL; } void CleanUp() { tgCleanUpProfile(); CleanUpChat(); CleanUpWhiteBoard(); TieLooseEnds(); if (cmdLineTgrm2) { CleanUpTangram2(); } CleanUpMiniLines(); CleanUpCutPaste(); CleanUpProperties(); CleanUpExportFilters(); ResetPSInfo(); CleanUpEdit(); CleanUpMark(); CleanUpShape(); CleanUpHelp(); CleanUpImport(); CleanUpImageProc(); CleanUpExec(); CleanUpCmds(); CleanUpExpr(); CleanUpNavigate(); CleanUpRemote(); CleanUpExtraWinInfo(); CleanUpDrawingWindow(); CleanUpPS(); CleanUpInputMethods(); CleanUpPins(); CleanUpPage(); CleanUpStk(); CleanUpStatus(); CleanUpChoices(); CleanUpScrolls(); CleanUpCursors(); CleanUpNames(); CleanUpRuler(); CleanUpRasters(); CleanUpFonts(); CleanUpMenu(); CleanUpText(); CleanUpColors(); CleanUpFiles(); CleanUpGrids(); CleanUpCutBuffer(); CleanUpXBm(); CleanUpXPm(); CleanUpMsg(); CleanUpShortCut(); CleanUpHtml(); CleanUpRecentFiles(); CleanUpMeasureTooltip(); CleanUpSpecial(); CleanUpAttr(); CleanUpTalkToSelfFiledes(); CleanUpInsertSymbol(); CleanUpColorWheel(); CleanUpTidget(); if (iconWindowCreated) { XDestroyWindow(mainDisplay, iconBaseWindow); iconWindowCreated = FALSE; } CleanUpResiduals(); CleanUpStrTable(); XDestroyWindow(mainDisplay, mainWindow); mainWindow = None; #ifndef DONT_FREE_COLORMAP if (newColormapUsed) { XFreeColormap(mainDisplay, mainColormap); newColormapUsed = FALSE; } #endif /* ~DONT_FREE_COLORMAP */ } void ExposeEventHandler(input, recursive) XEvent *input; int recursive; { int i=0; XEvent ev; TidgetInfo *handling_pti=NULL; if (input->xany.window == choiceWindow) { while (XCheckWindowEvent(mainDisplay, choiceWindow, ExposureMask, &ev)) ; RedrawChoiceWindow(); } else if (input->xany.window == drawWindow) { while (XCheckWindowEvent(mainDisplay, drawWindow, ExposureMask, &ev)) ; if (topSel != NULL || curChoice==VERTEXMODE || SomethingDirty() || showCrossHair) { ClearAndRedrawDrawWindow(); } else { RedrawDrawWindow(botObj); RedrawCurText(); } } else if (input->xany.window == vRuleWindow) { while (XCheckWindowEvent(mainDisplay, vRuleWindow, ExposureMask, &ev)) ; RedrawVRulerWindow(); } else if (input->xany.window == hRuleWindow) { while (XCheckWindowEvent(mainDisplay, hRuleWindow, ExposureMask, &ev)) ; RedrawHRulerWindow(); } else if (input->xany.window == iconWindow && input->type == Expose) { while (XCheckWindowEvent(mainDisplay, iconWindow, ExposureMask, &ev)) ; RedrawIconWindow(); } else if (input->xany.window == titleWindow) { while (XCheckWindowEvent(mainDisplay, titleWindow, ExposureMask, &ev)) ; RedrawTitleWindow(); } else if (input->xany.window == menubarWindow) { while (XCheckWindowEvent(mainDisplay,menubarWindow,ExposureMask,&ev)) ; RedrawMenubarWindow(); } else if (input->xany.window == msgWindow) { while (XCheckWindowEvent(mainDisplay, msgWindow, ExposureMask, &ev)) ; RedrawMsg(TRUE); } else if (input->xany.window == vSBarWindow) { while (XCheckWindowEvent(mainDisplay, vSBarWindow, ExposureMask, &ev)) ; RedrawVScrollWindow(); } else if (input->xany.window == hSBarWindow) { while (XCheckWindowEvent(mainDisplay, hSBarWindow, ExposureMask, &ev)) ; RedrawHScrollWindow(); } else if (input->xany.window == userRedrawWindow) { while (XCheckWindowEvent(mainDisplay,userRedrawWindow,ExposureMask,&ev)) ; RedrawUserRedrawWindow(); } else if (input->xany.window == statusWindow) { while (XCheckWindowEvent(mainDisplay, statusWindow, ExposureMask, &ev)) ; RedrawStatusWindow(); } else if (IsChatWindowEvent(input, &handling_pti)) { ChatEventHandler(input, handling_pti); } else if (input->xany.window == modeWindow) { while (XCheckWindowEvent(mainDisplay, modeWindow, ExposureMask, &ev)) ; RedrawModeWindow(); } else if (input->xany.window == dummyWindow1) { while (XCheckWindowEvent(mainDisplay, dummyWindow1, ExposureMask, &ev)) ; RedrawDummyWindow1(); } else if (input->xany.window == pageWindow) { RedrawPageWindow(); } else if (input->xany.window == pageDummyWindow) { RedrawPageDummyWindow(); } else if (input->xany.window == colorWindow) { RedrawColorWindow(); } else if (input->xany.window == colorDummyWindow) { RedrawColorDummyWindow(); } else if (input->xany.window==mainWindow && input->type==VisibilityNotify && input->xvisibility.state==VisibilityUnobscured) { XEvent tmp_ev; while (XCheckWindowEvent(mainDisplay, mainWindow, VisibilityChangeMask, &tmp_ev)) ; if (iconWindowShown) { UnIconify(); } else { if (pinnedMainMenu) XMapRaised(mainDisplay, mainMenuWindow); for (i = 0; i < numExtraWins; i++) { if (extraWinInfo[i].window != None && extraWinInfo[i].mapped && extraWinInfo[i].raise) { XMapRaised(mainDisplay, extraWinInfo[i].window); } } } } else if (TidgetManagerHandleEvent(input)) { /* input has been handled by the TidgetManager */ } else { for (i = 0; i < numExtraWins; i++) { if (input->xany.window == extraWinInfo[i].window && extraWinInfo[i].window != None) { while (XCheckWindowEvent(mainDisplay, extraWinInfo[i].window, ExposureMask, &ev)) ; (*(extraWinInfo[i].expose_handler))(input, &extraWinInfo[i]); break; } } } if (recursive) { while (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, FALSE); } } } int GzipFile(fname, gzipped_fname) char *fname, *gzipped_fname; { int rc=TRUE; FILE *pfp=NULL, *out_fp=NULL; char *compress_cmd=NULL, *cmd=NULL; if ((out_fp=fopen(gzipped_fname, "w")) == NULL) { return FailToOpenMessage(gzipped_fname, "w", NULL); } SaveStatusStrings(); compress_cmd = gzipCmd; cmd = (char*)malloc((strlen(fname)+strlen(compress_cmd)+20) * sizeof(char)); if (cmd == NULL) FailAllocMessage(); if (strstr(compress_cmd, "%s") == NULL) { sprintf(cmd, "%s %s", compress_cmd, fname); } else { sprintf(cmd, compress_cmd, fname); } if (!FindProgramInPath(cmd, NULL, FALSE)) { fclose(out_fp); free(cmd); RestoreStatusStrings(); return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), gzipCmd); SetStringStatus(gszMsgBox); if ((pfp=(FILE*)popen(cmd, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); fclose(out_fp); rc = FALSE; } else { int bytes_read=0, watch_cursor=watchCursorOnMainWindow; if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; while ((bytes_read=fread(gszMsgBox, sizeof(char), sizeof(gszMsgBox), pfp)) > 0) { if ((int)fwrite(gszMsgBox, sizeof(char), bytes_read, out_fp) <= 0) { writeFileFailed = TRUE; break; } } pclose(pfp); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } fclose(out_fp); if (writeFileFailed) { FailToWriteFileMessage(gzipped_fname); rc = FALSE; } } RestoreStatusStrings(); return rc; } char *GunzipFileIntoTemp(gzipped_fname) char *gzipped_fname; { FILE *pfp=NULL, *out_fp=NULL; char *uncompress_cmd=gunzipCmd, *tmp_fname=NULL, *cmd=NULL; tmp_fname = (char*)malloc((strlen(tmpDir)+20)*sizeof(char)); if (tmp_fname == NULL) { FailAllocMessage(); return NULL; } if (MkTempFile(tmp_fname, (strlen(tmpDir)+19)*sizeof(char), tmpDir, TOOL_NAME) == NULL) { return NULL; } if ((out_fp=fopen(tmp_fname, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), tmp_fname); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return NULL; } SaveStatusStrings(); uncompress_cmd = gunzipCmd; cmd = (char*)malloc((strlen(gzipped_fname)+strlen(uncompress_cmd)+20) * sizeof(char)); if (cmd == NULL) FailAllocMessage(); if (strstr(uncompress_cmd, "%s") == NULL) { sprintf(cmd, "%s %s", uncompress_cmd, gzipped_fname); } else { sprintf(cmd, uncompress_cmd, gzipped_fname); } if (!FindProgramInPath(cmd, NULL, FALSE)) { fclose(out_fp); unlink(tmp_fname); free(cmd); RestoreStatusStrings(); return NULL; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), gunzipCmd); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { SetStringStatus(gszMsgBox); } if ((pfp=(FILE*)popen(cmd, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), cmd); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } fclose(out_fp); unlink(tmp_fname); tmp_fname = NULL; } else { int bytes_read=0, watch_cursor=watchCursorOnMainWindow; if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; while ((bytes_read=fread(gszMsgBox, sizeof(char), sizeof(gszMsgBox), pfp)) > 0) { if ((int)fwrite(gszMsgBox, sizeof(char), bytes_read, out_fp) <= 0) { writeFileFailed = TRUE; break; } } pclose(pfp); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } fclose(out_fp); if (writeFileFailed) { FailToWriteFileMessage(tmp_fname); unlink(tmp_fname); tmp_fname = NULL; } } RestoreStatusStrings(); return tmp_fname; } #ifdef USE_XAPPLRESDIR static int FindXApplResDir(psz_srch_path, psz_target_dir, cb_target_dir) char *psz_srch_path, *psz_target_dir; int cb_target_dir; { char *c_ptr, *buf=UtilStrDup(psz_srch_path); if (buf == NULL) return FALSE; for (c_ptr=strtok(buf, ":"); c_ptr != NULL; c_ptr=strtok(NULL, ":")) { int len=strlen(c_ptr); char path[MAXPATHLENGTH+1]; FILE *fp; if (len > 0 && c_ptr[len-1] == DIR_SEP) c_ptr[--len] = DIR_SEP; sprintf(path, "%s%c%s", c_ptr, DIR_SEP, TOOL_NAME); if ((fp=fopen(path, "r")) != NULL) { UtilStrCpyN(psz_target_dir, cb_target_dir, c_ptr); UtilFree(buf); return TRUE; } } UtilFree(buf); return FALSE; } #endif /* USE_XAPPLRESDIR */ #ifndef _NO_LOCALE_SUPPORT #ifdef ENABLE_NLS static void InitLocale() { char *c_ptr=NULL; c_ptr = MySetLocale(LC_ALL, ""); if (c_ptr == NULL) { fprintf(stderr, "%s\n", TgLoadString(STID_CANNOT_SET_LOCALE_ENV_VARS)); } if (x11R6OrAbove) { if (useXlib) { if (!XSupportsLocale()) { fprintf(stderr, "%s\n", TgLoadString(STID_XLIB_CANT_SET_LOCALE_ENV_VARS)); MySetLocale(LC_ALL, "C"); } if (!XSetLocaleModifiers("")) { if (getenv("LANG") != NULL) { fprintf(stderr, "%s\n", TgLoadString(STID_CANT_SET_LOCALE_MODIFIERS)); } } } else { #ifdef USE_XT_INITIALIZE if (XtSetLanguageProc(NULL, NULL, NULL) == NULL) { fprintf(stderr, "%s\n", TgLoadString(STID_XT_CANNOT_SET_LOCALE_ENV_VARS)); MySetLocale(LC_ALL, "C"); } #endif /* USE_XT_INITIALIZE */ } } MySetLocale(LC_ALL, NULL); /* * Some locale uses "," as decimal point. That won't work in * saving files or generating EPS files. Must use "." * as decimal point. * From this point on, setlocale() should NEVER be called again! */ setlocale(LC_NUMERIC, "C"); } static void InitLocale2() { DIR *dirp=NULL; char package[80], *c_ptr=NULL, locale_dir[MAXPATHLENGTH]; *locale_dir = '\0'; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"LocaleDir")) != NULL) { strcpy(locale_dir, c_ptr); } else { strcpy(locale_dir, LOCALEDIR); } UtilTrimBlanks(locale_dir); strcpy(package, TOOL_NAME); UtilStrLower(package); if ((dirp=opendir(locale_dir)) == NULL) { fprintf(stderr, TgLoadString(STID_LOCALE_DIR_NOT_EXIST_USE_XDEF), locale_dir, TOOL_NAME, "LocaleDir"); fprintf(stderr, "\n"); } else { closedir(dirp); bindtextdomain(package, locale_dir); textdomain(package); } } #endif /* ENABLE_NLS */ #endif /* ~_NO_LOCALE_SUPPORT */ static int JustLoadAFile(pszFile, pnNeedToCheckAutoExec, nAttemptToMerge, pnAbortMerge) char *pszFile; int *pnNeedToCheckAutoExec, nAttemptToMerge, *pnAbortMerge; /* * return FALSE if nAttemptToMerge is TRUE and pszFile is in * TILED page mode * return TRUE otherwise */ { int short_name=FALSE, obj_file=TRUE; int tmp_linenum=0; char tmp_filename[MAXPATHLENGTH+1], tmp_filefullpath[MAXPATHLENGTH+1]; char full_name[MAXPATHLENGTH+1], *rest=NULL; char file_name[MAXPATHLENGTH+1], gzipped_fname[MAXPATHLENGTH+1]; int rc=0, gzipped_obj_file=FALSE; int file_is_remote=FALSE, remote_buf_sz=0, is_html=FALSE; char remote_fname[MAXPATHLENGTH+1], *tmp_remote_fname=NULL; char *remote_buf=NULL, *page_spec=NULL; struct ObjRec *obj_ptr=NULL; FILE *fp=NULL; *remote_fname = *gzipped_fname = '\0'; if (FileIsRemote(pszFile)) { if (!FormNewFileName(curDir, pszFile, NULL, remote_fname, &page_spec)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_REMOTE_FNAME), pszFile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *pszFile = '\0'; } else { char *content_type=NULL; char final_url[MAXPATHLENGTH+1]; *final_url = '\0'; SaveStatusStrings(); rc = LoadRemoteFileInMem(remote_fname, &remote_buf, &content_type, &remote_buf_sz, &is_html, TRUE, final_url, sizeof(final_url)); RestoreStatusStrings(); if (rc && remote_buf != NULL && (tmp_remote_fname=WriteRemoteFileIntoTemp(remote_buf, remote_buf_sz, NULL)) != NULL) { if (*final_url != '\0') { UtilStrCpyN(pszFile, MAXPATHLENGTH+1, final_url); UtilStrCpyN(remote_fname, MAXPATHLENGTH+1, final_url); } if (FileNameHasExtension(remote_fname, OBJ_FILE_TYPE, &gzipped_obj_file, NULL)) { file_is_remote = TRUE; } else if (UseExternalViewer(is_html, remote_fname, content_type, tmp_remote_fname) != FALSE) { unlink(tmp_remote_fname); FreeRemoteBuf(tmp_remote_fname); if (remote_buf != NULL) FreeRemoteBuf(remote_buf); remote_buf = tmp_remote_fname = NULL; file_is_remote = FALSE; *pszFile = '\0'; } else { file_is_remote = TRUE; } } else { if (remote_buf != NULL) FreeRemoteBuf(remote_buf); remote_buf = NULL; *pszFile = '\0'; } if (content_type != NULL) FreeRemoteBuf(content_type); } } *file_name = '\0'; if (file_is_remote) { if ((fp=fopen(tmp_remote_fname, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_READ_TMP_FILE), tmp_remote_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(tmp_remote_fname); FreeRemoteBuf(tmp_remote_fname); FreeRemoteBuf(remote_buf); remote_buf = tmp_remote_fname = NULL; file_is_remote = FALSE; } else { if (FileNameHasExtension(remote_fname, SYM_FILE_TYPE, NULL, NULL)) { obj_file = FALSE; } else if (FileNameHasExtension(remote_fname, PIN_FILE_TYPE, NULL, NULL)) { obj_file = FALSE; } else { obj_file = TRUE; } } } else { if (FileNameHasExtension(pszFile, OBJ_FILE_TYPE, &gzipped_obj_file, NULL)) { if (gzipped_obj_file) { char *tmp_fname=NULL; if ((tmp_fname=GunzipFileIntoTemp(pszFile)) == NULL) { *file_name = '\0'; } else { strcpy(gzipped_fname, pszFile); strcpy(file_name, tmp_fname); free(tmp_fname); } } else { strcpy(file_name, pszFile); } } else if (FileNameHasExtension(pszFile, SYM_FILE_TYPE, NULL, NULL)) { strcpy(file_name, pszFile); obj_file = FALSE; } else if (FileNameHasExtension(pszFile, PIN_FILE_TYPE, NULL, NULL)) { strcpy(file_name, pszFile); obj_file = FALSE; } else { sprintf(file_name, "%s.%s", pszFile, OBJ_FILE_EXT); } if (*gzipped_fname == '\0') { if ((short_name=IsPrefix(bootDir, file_name, &rest))) ++rest; } else { if ((short_name=IsPrefix(bootDir, gzipped_fname, &rest))) ++rest; } } if (*file_name != '\0' && (fp=fopen(file_name, "r")) == NULL) { DelAllPages(); lastPageNum = 1; InitPage(); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), (short_name ? rest : file_name)); Msg(gszMsgBox); if (*file_name == DIR_SEP) { strcpy(full_name, file_name); } else { sprintf(full_name, "%s%c%s", curDir, DIR_SEP, file_name); } if (!cmdLineMerge) { if (obj_file) { SetCurDir(full_name); *curSymDir = '\0'; } else { SetCurSymDir(full_name); } curFileDefined = TRUE; } SetFileModified(FALSE); sprintf(gszMsgBox, TgLoadString(STID_CUR_EMPTY_FILE_IS), (short_name ? rest : file_name)); Msg(gszMsgBox); } else if (file_is_remote || *file_name != '\0') { int read_status; SetFileModified(FALSE); SaveStatusStrings(); if (file_is_remote) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_LOADING_FILE), remote_fname); } else { if (short_name) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_LOADING_FILE), rest); } else { if (*gzipped_fname == '\0') { sprintf(gszMsgBox, TgLoadCachedString(CSTID_LOADING_FILE), file_name); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_LOADING_FILE), gzipped_fname); } } if (*gzipped_fname == '\0') { if (*file_name == DIR_SEP) { strcpy(full_name, file_name); } else { sprintf(full_name, "%s%c%s", curDir, DIR_SEP, file_name); } } else { if (*gzipped_fname == DIR_SEP) { strcpy(full_name, gzipped_fname); } else { sprintf(full_name, "%s%c%s", curDir, DIR_SEP, gzipped_fname); } } } SetStringStatus(gszMsgBox); strcpy(tmp_filefullpath, scanFileFullPath); strcpy(tmp_filename, scanFileName); tmp_linenum = scanLineNum; UtilStrCpyN(scanFileFullPath, sizeof(scanFileFullPath), (file_is_remote ? remote_fname : full_name)); if (file_is_remote) { strcpy(scanFileName, tmp_remote_fname); } else { strcpy(scanFileName, (short_name ? rest : file_name)); } scanLineNum = 0; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); readingPageNum = loadedCurPageNum = 0; foundGoodStateObject = FALSE; while ((read_status=ReadObj(fp, &obj_ptr)) == TRUE) { if (obj_ptr != NULL) { obj_ptr->tmp_parent = NULL; AdjForOldVersion(obj_ptr); AddObj(NULL, topObj, obj_ptr); } } strcpy(scanFileFullPath, tmp_filefullpath); strcpy(scanFileName, tmp_filename); scanLineNum = tmp_linenum; fclose(fp); if (!mergingFile && loadedCurPageNum <= 0) { DelAllPages(); loadedCurPageNum = curPageNum = lastPageNum = 1; InitPage(); } if (read_status == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FILE_VER_ABORT_OPEN), fileVersion, TOOL_NAME, homePageURL); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { if (loadedCurPageNum > 0 && curPage != NULL) { GotoPageNum(loadedCurPageNum); } CheckFileAttrsInLoad(); curFileDefined = TRUE; if (file_is_remote) { if (!cmdLineMerge) { SetCurDir(remote_fname); } if (!foundGoodStateObject) PasteString(remote_buf, TRUE, TRUE); } else { if (*gzipped_fname == '\0') { if (*file_name == DIR_SEP) { strcpy(full_name, file_name); } else { sprintf(full_name, "%s%c%s", curDir, DIR_SEP, file_name); } } else { if (*gzipped_fname == DIR_SEP) { strcpy(full_name, gzipped_fname); } else { sprintf(full_name, "%s%c%s", curDir, DIR_SEP, gzipped_fname); } } if (!cmdLineMerge) { if (obj_file) { SetCurDir(full_name); *curSymDir = '\0'; } else { SetCurSymDir(full_name); } } } if (file_is_remote) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CUR_FILE_IS), remote_fname); RedrawDrawWindow(botObj); } else if (short_name) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CUR_FILE_IS), rest); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CUR_FILE_IS), (*gzipped_fname == '\0' ? file_name : gzipped_fname)); } Msg(gszMsgBox); } RestoreStatusStrings(); GotoPageNum(loadedCurPageNum); SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); if (file_is_remote) { unlink(tmp_remote_fname); if (tmp_remote_fname != NULL) FreeRemoteBuf(tmp_remote_fname); if (remote_buf != NULL) FreeRemoteBuf(remote_buf); remote_buf = tmp_remote_fname = NULL; if (!nAttemptToMerge && !mergingFile) CommitNavigate(); } else { if (*gzipped_fname != '\0') { unlink(file_name); } } if (foundGoodStateObject && !nAttemptToMerge && !mergingFile) { struct AttrRec *exec_attr=FindFileAttrWithName("auto_exec="); if (!nAttemptToMerge && !mergingFile) CommitNavigate(); if (exec_attr != NULL) { XSync(mainDisplay, False); if (pnNeedToCheckAutoExec != NULL) *pnNeedToCheckAutoExec = TRUE; } } } if (page_spec != NULL) { int new_page_num=(-1); if (!GetPageNumFromPageSpec(page_spec, &new_page_num)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PAGE_SPECIFIED_FOR), pszFile); Msg(gszMsgBox); } else if (new_page_num != curPageNum) { GotoPageNum(new_page_num); } } if (page_spec != NULL) free(page_spec); if (pageLayoutMode == PAGE_TILE && nAttemptToMerge && pnAbortMerge != NULL) { if (file_is_remote) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_MERGE_WITH_TILED_PAGE), remote_fname); } else if (short_name) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_MERGE_WITH_TILED_PAGE), rest); } else { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_MERGE_WITH_TILED_PAGE), (*gzipped_fname == '\0' ? file_name : gzipped_fname)); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *pnAbortMerge = TRUE; } return TRUE; } static void SigchldHandler(sig) int sig; { int status; /* wait for all the zombie processes to terminate */ while(waitpid(-1, &status, WNOHANG) > 0); } int JustInit(pszFile, pnNeedToCheckAutoExec) char *pszFile; int *pnNeedToCheckAutoExec; { int cannot_opendisplay=FALSE, allow_open=TRUE; #ifdef USE_XT_INITIALIZE useXlib = cmdLineUseXlib; #else /* ~USE_XT_INITIALIZE */ #ifdef USE_XAPPLRESDIR FILE *xenv_fp=NULL; char *c_ptr=NULL, *xEnvStr=NULL, tmp_buf[MAXPATHLENGTH+1]; int len=0; #ifdef XAPPLOADDIR_DEF if (getenv("XENVIRONMENT") == NULL) { if (((c_ptr=getenv("XAPPLRESDIR")) == NULL)) { UtilStrCpyN(tmp_buf, sizeof(tmp_buf), XAPPLOADDIR_DEF); } else if (!FindXApplResDir(c_ptr, tmp_buf, sizeof(tmp_buf))) { UtilStrCpyN(tmp_buf, sizeof(tmp_buf), XAPPLOADDIR_DEF); } c_ptr = tmp_buf; len = strlen(c_ptr); #else /* ~XAPPLOADDIR_DEF */ if ((getenv("XENVIRONMENT") == NULL) && ((c_ptr=getenv("XAPPLRESDIR")) != NULL) && ((len=strlen(c_ptr)) > 0)) { if (FindXApplResDir(c_ptr, tmp_buf, sizeof(tmp_buf))) { c_ptr = tmp_buf; } len = strlen(c_ptr); #endif /* XAPPLOADDIR_DEF */ xEnvStr = (char*)malloc( (strlen("XENVIRONMENT=")+strlen(TOOL_NAME)+len+3)*sizeof(char)); if (xEnvStr == NULL) FailAllocMessage(); sprintf(xEnvStr, "%s%s%s", c_ptr, ((c_ptr[len-1] == DIR_SEP) ? "" : DIR_SEP_STR), TOOL_NAME); if ((xenv_fp=fopen(xEnvStr, "r")) != NULL) { fclose(xenv_fp); sprintf(xEnvStr, "XENVIRONMENT=%s%s%s", c_ptr, ((c_ptr[len-1] == DIR_SEP) ? "" : DIR_SEP_STR), TOOL_NAME); if (putenv(xEnvStr)) { sprintf(gszMsgBox, TgLoadString(STID_WARN_CANT_PUTENV_GIVEN), xEnvStr); Msg(gszMsgBox); *xEnvStr = '\0'; free(xEnvStr); xEnvStr = NULL; } } } #endif /* USE_XAPPLRESDIR */ useXlib = TRUE; #endif /* USE_XT_INITIALIZE */ #ifndef _NO_LOCALE_SUPPORT MySetLocale(LC_ALL, "C"); MySetLocale(LC_NUMERIC, "C"); #ifdef ENABLE_NLS InitLocale(); #endif /* ENABLE_NLS */ #endif /* ~_NO_LOCALE_SUPPORT */ if (useXlib) { cannot_opendisplay = ((mainDisplay=XOpenDisplay(displayName)) == 0); } else { #ifdef USE_XT_INITIALIZE toplevel = XtInitialize(TOOL_NAME, TOOL_NAME, NULL, 0, &origArgC, origArgV); cannot_opendisplay = (toplevel == NULL || (mainDisplay=XtDisplay(toplevel)) == 0); #endif /* USE_XT_INITIALIZE */ } if (cannot_opendisplay) { if (displayName == NULL) { fprintf(stderr, "%s\n", TgLoadString(STID_CANT_OPEN_DISPLAY_ABORT)); exit(-1); } else { fprintf(stderr, TgLoadString(STID_CANT_OPEN_GIVEN_DPY_ABORT), displayName); fprintf(stderr, "\n"); exit(-1); } } mainScreen = DefaultScreen(mainDisplay); mainColormap = DefaultColormap(mainDisplay, mainScreen); mainDepth = DefaultDepth(mainDisplay, mainScreen); mainVisual = DefaultVisual(mainDisplay, mainScreen); rootWindow = RootWindow(mainDisplay, mainScreen); #ifdef NOT_DEFINED /* debug, do not translate */ fprintf(stderr,"mainDepth =%d\n",mainDepth); fprintf(stderr,"mainVisual->class =%d\n",mainVisual->class); fprintf(stderr,"mainVisual->red_mask =0x%08lx\n",mainVisual->red_mask); fprintf(stderr,"mainVisual->green_mask =0x%08lx\n",mainVisual->green_mask); fprintf(stderr,"mainVisual->blue_mask =0x%08lx\n",mainVisual->blue_mask); fprintf(stderr,"mainVisual->bits_per_rgb=%d\n",mainVisual->bits_per_rgb); fprintf(stderr,"mainVisual->map_entries =%d\n",mainVisual->map_entries); #endif /* NOT_DEFINED */ XSetErrorHandler(EmergencySaveForX); XSetIOErrorHandler(IOEmergencySaveForX); signal(SIGHUP, EmergencySave); signal(SIGFPE, EmergencySave); #ifndef linux signal(SIGBUS, EmergencySave); #endif /* ~linux */ signal(SIGSEGV, EmergencySave); signal(SIGCHLD, SigchldHandler); #ifndef _NO_LOCALE_SUPPORT #ifdef ENABLE_NLS InitLocale2(); #endif /* ENABLE_NLS */ #endif /* ~_NO_LOCALE_SUPPORT */ InitWhiteBoard(); Setup(); InitExtraWinInfo(); InitLastKeyOrBtnEvInfo(); quitDraw = FALSE; prTgifFoundColorInfo = FALSE; InitWhiteBoard2(); if (pszFile == NULL) { /* Only gets here if PRTGIF of UrlDump() */ DelAllPages(); lastPageNum = 1; InitPage(); return TRUE; } initializingMain = TRUE; if (gstWBInfo.do_whiteboard) { static int initialized=FALSE; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(!initialized, "Whiteboard initialized too many times in JustInit()", NULL); #endif /* _TGIF_DBG */ if (gstWBInfo.join_session_in_progress) { allow_open = FALSE; } initialized = TRUE; } if (!allow_open) { char *fname=NULL; *gszMsgBox = '\0'; if (cmdLineMerge && cmdLineMergeArgc > 0 && cmdLineMergeArgv != NULL) { fname = cmdLineMergeArgv[0]; sprintf(gszMsgBox, TgLoadString(STID_JOIN_WB_IN_PROGRESS_IGNORED), fname); cmdLineMerge = FALSE; } else if (*pszFile != '\0') { fname = pszFile; sprintf(gszMsgBox, TgLoadString(STID_JOIN_WB_IN_PROGRESS_IGNORED), fname); *pszFile = '\0'; } if (fname != NULL) { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); UtilFree(fname); } } if (cmdLineMerge && cmdLineMergeArgc > 0 && cmdLineMergeArgv != NULL) { int arg_index=0, abort_merge=FALSE, num_argc=cmdLineMergeArgc; int identical=FALSE; char **ppsz_html_export_template=(char**)malloc(cmdLineMergeArgc* sizeof(char*)); if (ppsz_html_export_template == NULL) FailAllocMessage(); memset(ppsz_html_export_template, 0, cmdLineMergeArgc*sizeof(char*)); if (JustLoadAFile(cmdLineMergeArgv[0], NULL, TRUE, &abort_merge)) { ppsz_html_export_template[0] = UtilStrDup(gszHhtmlExportTemplate); if (ppsz_html_export_template[0] == NULL) FailAllocMessage(); if (!abort_merge) { PageInfo pi; memset(&pi, 0, sizeof(PageInfo)); GetPageInfo(&pi); CleanUpComments(); firstPage = lastPage = curPage = NULL; topObj = botObj = NULL; DelAllPages(); lastPageNum = 1; InitPage(); mergingFile = TRUE; for (arg_index=1; arg_index < cmdLineMergeArgc; arg_index++) { if (!JustLoadAFile(cmdLineMergeArgv[arg_index], NULL, FALSE, NULL)) { break; } ppsz_html_export_template[arg_index] = UtilStrDup(gszHhtmlExportTemplate); if (ppsz_html_export_template[arg_index] == NULL) { FailAllocMessage(); } CleanUpComments(); firstPage->prev = pi.last_page; if (pi.last_page == NULL) { pi.first_page = firstPage; } else { pi.last_page->next = firstPage; } pi.last_page = lastPage; pi.last_page_num += lastPageNum; firstPage = lastPage = curPage = NULL; topObj = botObj = NULL; DelAllPages(); lastPageNum = 1; InitPage(); } mergingFile = FALSE; DelAllPages(); curPageNum = pi.cur_page_num; lastPageNum = pi.last_page_num; firstPage = pi.first_page; lastPage = pi.last_page; curPage = pi.cur_page; topObj = curPage->top; botObj = curPage->bot; } } CleanUpMergeArgs(); ClearFileInfo(FALSE); SetFileModified(TRUE); identical = TRUE; for (arg_index=1; arg_index < num_argc; arg_index++) { if (strcmp(ppsz_html_export_template[0], ppsz_html_export_template[arg_index]) != 0) { identical = FALSE; break; } } if (!identical) { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_NO_HTML_TEMPLATE_FILE)); Msg(gszMsgBox); } else if (*ppsz_html_export_template[0] != '\0') { UtilStrCpyN(gszHhtmlExportTemplate, sizeof(gszHhtmlExportTemplate), ppsz_html_export_template[0]); sprintf(gszMsgBox, TgLoadString(STID_HTML_TEMPLATE_SET_TO_GIVEN), gszHhtmlExportTemplate); Msg(gszMsgBox); } for (arg_index=0; arg_index < num_argc; arg_index++) { UtilFree(ppsz_html_export_template[arg_index]); } free(ppsz_html_export_template); } else if (*pszFile != '\0') { JustLoadAFile(pszFile, pnNeedToCheckAutoExec, FALSE, NULL); } else { if (allow_open) { DelAllPages(); lastPageNum = 1; InitPage(); } else { SetFileModified(TRUE); } } SetDefaultDrawWinClipRecs(); UpdateDirInfo(); initializingMain = FALSE; return TRUE; } void HandleDataInMBuff() { if (gstWBInfo.do_whiteboard) { TryHandleWBInputData(); } } static int GetAnXEvent(pXEvent) XEvent *pXEvent; { if (gstWBInfo.do_whiteboard) { int rc=TRUE; gstWBInfo.BlockRemoteCmdDepth--; #ifdef DEBUG0 fprintf(stderr,"BlockRemoteCmdDepth (GetAnXEvent): %d\n", gstWBInfo.BlockRemoteCmdDepth); #endif /* DEBUG0 */ if (XPending(mainDisplay)) { if (gnInputMethod != TGIM_NONE && tgIMExpectNextEvent(mainDisplay, drawWindow)) { if (!tgIMHandleNextEvent(mainDisplay, drawWindow, pXEvent)) { } } else { XNextEvent(mainDisplay, pXEvent); } } else { struct timeval timeout; fd_set fdset; int select_width=XConnectionNumber(mainDisplay)+1, status=0, nfds=0; nfds = max(select_width, (int)(talkToSelfFiledes[0]+1)); timeout.tv_sec = 15; timeout.tv_usec = 0; FD_ZERO(&fdset); FD_SET(select_width-1, &fdset); /* X file descriptor */ FD_SET(talkToSelfFiledes[0], &fdset); /* pipe */ #ifdef __hpux status = select(nfds, (int*)&fdset, NULL, NULL, &timeout); #else /* !__hpux */ status = select(nfds, &fdset, NULL, NULL, &timeout); #endif /* __hpux */ if (status < 0) { if (errno == EINTR) { /* interrupted by a system call, not a problem */ } else { sprintf(gszMsgBox, TgLoadString(STID_FUNC_SELECT_SYS_CALL_FAILED), "GetAnXEvent()"), fprintf(stderr, "%s\n", gszMsgBox); } rc = FALSE; } else if (status == 0) { /* timeout */ rc = FALSE; } else if (status == 1) { if (FD_ISSET(talkToSelfFiledes[0], &fdset)) { char buf[2]; if (read(talkToSelfFiledes[0], buf, 1) != 1) { sprintf(gszMsgBox, TgLoadString(STID_READ_FROM_SELF_PIPE_FAIL), 1, TOOL_NAME), fprintf(stderr, "%s\n", gszMsgBox); } else { if (*buf == 'a') { SendCommandToSelf(CMDID_DATA_IN_MBUFF, 0); } else if (*buf == 'c') { /* * Get current tgwb state and establish * a TCP conection to send the data. */ HandleNewUserRequest(); } else { sprintf(gszMsgBox, TgLoadString(STID_UNRECOG_BYTE_FROM_SELF_PIPE), *buf, TOOL_NAME), fprintf(stderr, "%s\n", gszMsgBox); } } rc = FALSE; } else if (FD_ISSET(select_width-1, &fdset)) { if (gnInputMethod != TGIM_NONE && tgIMExpectNextEvent(mainDisplay, drawWindow)) { if (!tgIMHandleNextEvent(mainDisplay, drawWindow, pXEvent)) { } } else { XNextEvent(mainDisplay, pXEvent); } } else { rc = FALSE; } } else { sprintf(gszMsgBox, TgLoadString(STID_FUNC_INVALID_RC_FOR_SELECT), "GetAnXEvent()", status); fprintf(stderr, "%s\n", gszMsgBox); rc = FALSE; } } gstWBInfo.BlockRemoteCmdDepth++; #ifdef DEBUG0 fprintf(stderr,"BlockRemoteCmdDepth (GetAnXEvent): %d\n", gstWBInfo.BlockRemoteCmdDepth); #endif /* DEBUG0 */ if (!rc) return FALSE; } else { if (gnInputMethod != TGIM_NONE && tgIMExpectNextEvent(mainDisplay, drawWindow)) { if (!tgIMHandleNextEvent(mainDisplay, drawWindow, pXEvent)) { } } else { XNextEvent(mainDisplay, pXEvent); } } return TRUE; } int TryProcessAnXEvent(pnNeedToCheckAutoExec) int *pnNeedToCheckAutoExec; { XEvent input; int rc=0, drawtext_cursorshown_keypress_processed=FALSE; TidgetInfo *handling_pti=NULL; exitNormally = FALSE; if (pnNeedToCheckAutoExec != NULL && (*pnNeedToCheckAutoExec) && XPending(mainDisplay) <= 0) { struct AttrRec *exec_attr=FindFileAttrWithName("auto_exec="); *pnNeedToCheckAutoExec = FALSE; if (exec_attr != NULL) { DoExecLoop(NULL, exec_attr); } } if (!GetAnXEvent(&input)) { return 0; } /* set the lastKeyOrBtnEvInfo */ if (input.type == KeyPress) { SetLastKeyEvInfo(&input.xkey); } else if (input.type == ButtonPress) { SetLastBtnEvInfo(&input.xbutton); } if (input.type == FocusIn) { if (curChoice == DRAWTEXT && textCursorShown) { tgIMFocusIn(mainDisplay, input.xany.window); } } else if (input.type == FocusOut) { if (curChoice == DRAWTEXT && textCursorShown) { tgIMFocusOut(mainDisplay, input.xany.window); } } else if (input.type == KeyRelease) { return 0; } else if (input.type == KeyPress) { if (TidgetManagerWantAllKeyPressEvents()) { TidgetManagerHandleAllKeyPressEvent(&input); return 0; } rc = ShortHand(&input); switch (rc) { case BAD: /* or */ return 0; case INVALID: if (curChoice != DRAWTEXT || !textCursorShown) { escPressed = FALSE; } break; default: return rc; } } if (input.xany.window == choiceWindow) { if ((rc=ChoiceEventHandler(&input)) != INVALID) { return rc; } } else if (input.xany.window == drawWindow) { if (input.type == ButtonPress) { if (gstWBInfo.do_whiteboard) { gstWBInfo.BlockRemoteCmdDepth++; } } if (curChoice == DRAWTEXT && textCursorShown && input.type == KeyPress) { drawtext_cursorshown_keypress_processed = TRUE; } rc = DrawingEventHandler(&input); if (input.type == ButtonPress) { if (gstWBInfo.do_whiteboard) { gstWBInfo.BlockRemoteCmdDepth--; TryHandleWBInputData(); } } if (rc != INVALID) { return rc; } } else if (input.xany.window == mainWindow) { rc = mainWinEventHandler(&input); switch (rc) { case BAD: /* or */ return 0; case INVALID: break; default: return rc; } } else if (input.xany.window == vRuleWindow || input.xany.window == hRuleWindow) { RulersEventHandler(&input); } else if (input.xany.window == iconWindow || input.xany.window == iconBaseWindow) { IconEventHandler(&input); } else if (input.xany.window == titleWindow) { TitleEventHandler(&input); } else if (menubarWindow != None && input.xany.window == menubarWindow) { if ((rc=MenubarEventHandler(&input)) != INVALID) { return rc; } } else if (input.xany.window == msgWindow) { MsgEventHandler(&input); } else if (input.xany.window == vSBarWindow || input.xany.window == hSBarWindow) { ScrollEventHandler(&input); } else if (userRedrawWindow != None && input.xany.window == userRedrawWindow) { UserRedrawEventHandler(&input); } else if (statusWindow != None && input.xany.window == statusWindow) { StatusEventHandler(&input); } else if (chatWindow != None && IsChatWindowEvent(&input, &handling_pti)) { ChatEventHandler(&input, handling_pti); if (curChoice == DRAWTEXT && textCursorShown && input.type == KeyPress) { drawtext_cursorshown_keypress_processed = TRUE; } } else if (modeWindow != None && input.xany.window == modeWindow) { if ((rc=ModeEventHandler(&input)) != INVALID) { return rc; } } else if (input.xany.window == dummyWindow1 || input.xany.window == dummyWindow2) { DummiesEventHandler(&input); } else if (input.xany.type == MappingNotify) { XRefreshKeyboardMapping(&(input.xmapping)); } else if (input.xany.window == pageWindow) { PageEventHandler(&input); } else if (input.xany.window == pageDummyWindow) { PageDummyEventHandler(&input); } else if (input.xany.window == colorWindow) { ColorEventHandler(&input); } else if (input.xany.window == colorDummyWindow) { ColorDummyEventHandler(&input); } else if (TidgetManagerHandleEvent(&input)) { /* input has been handled by the TidgetManager */ } else { int i=0; for (i=0; i < numExtraWins; i++) { if (input.xany.window == extraWinInfo[i].window && extraWinInfo[i].window != None) { if ((rc=(*(extraWinInfo[i].ev_handler))(&input, &extraWinInfo[i])) != INVALID) { return rc; } break; } } } #ifndef _NO_ENTER_TEXT_EVERYWHERE if (curChoice == DRAWTEXT && textCursorShown && input.type == KeyPress && !drawtext_cursorshown_keypress_processed) { rc = DrawingEventHandler(&input); if (rc != INVALID) { return rc; } } #endif /* ~_NO_ENTER_TEXT_EVERYWHERE */ return 0; } static XComposeStatus c_stat; int TryProcessAnAbortXEvent(esc_to_abort, pf_abort_callback, p_void) int esc_to_abort; AbortCallbackFunc *pf_abort_callback; void *p_void; { XEvent input; exitNormally = FALSE; if (!GetAnXEvent(&input)) { return FALSE; } if (input.type == KeyPress || input.type == KeyRelease) { char s[80]; int has_ch=0; XKeyEvent *key_ev=NULL; KeySym key_sym=(KeySym)0; key_ev = (&(input.xkey)); has_ch = XLookupString(key_ev, s, sizeof(s), &key_sym, &c_stat); if (has_ch > 0) s[has_ch] = '\0'; TranslateKeys(s, &key_sym); if (esc_to_abort && CharIsESC(key_ev, s, key_sym, &has_ch)) { if (pf_abort_callback == NULL || (pf_abort_callback)(p_void)) { return TRUE; } } else if (!esc_to_abort && has_ch) { unsigned int state=key_ev->state; if ((state & ControlMask) && (!(state & METAMASK)) && s[0] == '\003') { if (pf_abort_callback == NULL || (pf_abort_callback)(p_void)) { return TRUE; } } } } else if (input.type == MotionNotify) { while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &input)) ; } else if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); while (XCheckMaskEvent(mainDisplay, ExposureMask | VisibilityChangeMask, &input)) { } } else if (input.type == ConfigureNotify) { Reconfigure(FALSE); } return FALSE; } void MainLoop(Op, FileName, FuncStr, Str1, Menu1, Str2, Menu2, Str3, Menu3) char *Op, *FileName, **FuncStr; char **Str1, **Menu1, **Str2, **Menu2, **Str3, **Menu3; { char *c_ptr=NULL, file_name[MAXPATHLENGTH+1]; int need_to_check_auto_exec=FALSE; /* printf("--> MainLoop(%s, %s, ...)\n", Op, FileName); */ /* do not translate -- program constants */ if (strcmp(Op, "init") == 0 || strcmp(Op, "justinit") == 0) { char szMsg1[80], szMsg2[80]; GetTgifVersionAndPatchLevel(szMsg1, sizeof(szMsg1)); sprintf(szMsg2, "%s (%s)", copyrightString, authorEmailString); TwoLineMsg(szMsg1, szMsg2); if (cmdLineVersion) { fprintf(stderr, "%s\n", szMsg1); fprintf(stderr, "%s\n", szMsg2); } fflush(stderr); exitNormally = FALSE; #ifdef X_PROTOCOL #ifdef XlibSpecificationRelease x11R6OrAbove = (X_PROTOCOL >= 11 && XlibSpecificationRelease >= 6); #endif /* XlibSpecificationRelease */ #endif /* X_PROTOCOL */ JustInit(FileName, &need_to_check_auto_exec); if (*cmdLineFileToExec != '\0') { SendCommandToSelf(CMDID_STARTEXECCMDSFROMFILE, 0); } } SaveDrawWinInfo(); if (strcmp(Op, "justinit") == 0) { XSync(mainDisplay, False); AllocStrings(FuncStr, Str1, Menu1, Str2, Menu2, Str3, Menu3); strcpy(*FuncStr, ""); return; } if (strcmp(Op, "save") == 0) { SaveFile(); AllocStrings(FuncStr, Str1, Menu1, Str2, Menu2, Str3, Menu3); strcpy(*FuncStr, ""); return; } if (strcmp(Op, "vi") == 0) { ExecWithFile("vi", FileName); } if (strcmp(Op, "less") == 0) { ExecWithFile("less", FileName); } if (strcmp(Op, "quit") == 0) { CleanUp(); quitDraw = TRUE; XFlush(mainDisplay); XSync(mainDisplay, True); if (useXlib) { XCloseDisplay(mainDisplay); mainDisplay = NULL; } else { #ifdef USE_XT_INITIALIZE XtDestroyWidget(toplevel); toplevel = (Widget)0; #endif /* USE_XT_INITIALIZE */ } exitNormally = TRUE; AllocStrings(FuncStr, Str1, Menu1, Str2, Menu2, Str3, Menu3); strcpy(*FuncStr, "Quit"); strcpy(*Str1, ""); return; } if (strcmp(Op, "msg") == 0) { Msg(FileName); AllocStrings(FuncStr, Str1, Menu1, Str2, Menu2, Str3, Menu3); strcpy(*FuncStr, ""); return; } if (strcmp(Op, "dialog") == 0) { *file_name = '\0'; Dialog(FileName, "", file_name); AllocStrings(FuncStr, Str1, Menu1, Str2, Menu2, Str3, Menu3); strcpy(*FuncStr, file_name); strcpy(*Str1, ""); return; } if (strcmp(Op, "mainmenu") == 0 && quitDraw) { AllocStrings(FuncStr, Str1, Menu1, Str2, Menu2, Str3, Menu3); strcpy(*FuncStr, "Fail"); strcpy(*Str1, ""); return; } while (TRUE) { int rc=TryProcessAnXEvent(&need_to_check_auto_exec); if (rc != 0) { AllocStrings(FuncStr, Str1, Menu1, Str2, Menu2, Str3, Menu3); strcpy(*FuncStr, fileMenuStr[rc]); strcpy(*Str1, curDomainName); sprintf(*Menu1, "tmpmodel.%s", OBJ_FILE_EXT); strcpy(*Str2, ""); for (c_ptr = *FuncStr; *c_ptr != '\0'; c_ptr++) { if (*c_ptr == ' ') { *c_ptr = '\0'; break; } } return; } } } void UrlDump(pszUrl) char *pszUrl; { int saved_http_debug=debugHttp; int saved_ftp_debug=debugFtp; debugHttp = 99; debugFtp = (-99); if (FileIsRemote(pszUrl)) { char tmp_fname[MAXPATHLENGTH+1], *content_type=NULL, *page_spec=NULL; int is_html=FALSE; *tmp_fname = '\0'; if (cmdLineDumpURL && cmdLineDumpURLWithHeader && cmdLineDumpURLHeaderOnly) { gettingHttpHeaderOnly = TRUE; } if (cmdLineParseHtml) { cmdLineDumpURL = FALSE; debugHttp = saved_http_debug; InitHtml(); } else { if (cmdLineOpenDisplay) { JustInit(NULL, NULL); } } DownloadRemoteFile(pszUrl, &content_type, &page_spec, &is_html, tmp_fname, NULL, 0); gettingHttpHeaderOnly = FALSE; if (content_type != NULL) FreeRemoteBuf(content_type); if (page_spec != NULL) UtilFree(page_spec); if (*tmp_fname != '\0') unlink(tmp_fname); } else { FILE *fp=fopen(pszUrl, "r"); if (fp == NULL) { fprintf(stderr, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), pszUrl); fprintf(stderr, "\n"); } else { char *buf; while ((buf=UtilGetALine(fp)) != NULL) { fprintf(stdout, "%s\n", buf); UtilFree(buf); } fclose(fp); } } debugHttp = saved_http_debug; debugFtp = saved_ftp_debug; } void DosEpsFilter(pszUrl) char *pszUrl; { if (MyReadEPSFile(pszUrl, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL)) { } } static void HandleSimpleEvent(input) XEvent input; { if ((input.type & (PointerMotionMask | EnterWindowMask | LeaveWindowMask)) != 0) { return; } if (input.xany.window == drawWindow) { DrawingEventHandler(&input); } else if (input.xany.window == choiceWindow) { ChoiceEventHandler(&input); } else if (input.xany.window==iconWindow || input.xany.window==iconBaseWindow) { IconEventHandler(&input); } else if (input.xany.window == titleWindow) { TitleEventHandler(&input); } else if (input.xany.window == msgWindow) { MsgEventHandler(&input); } else if (input.xany.window==vSBarWindow || input.xany.window==hSBarWindow) { ScrollEventHandler(&input); } else if (input.xany.window == hRuleWindow) { RedrawHRulerWindow(); } else if (input.xany.window == vRuleWindow) { RedrawVRulerWindow(); } } static void AllocReturnStr(ReturnStr) char **ReturnStr; { if((*ReturnStr=(char*)malloc(80*sizeof(char))) == NULL) FailAllocMessage(); } void Animate(TypeStr, PolyId, SpeedStr, ColorStr, ReturnStr) char *TypeStr, *PolyId, *SpeedStr, *ColorStr; char **ReturnStr; { struct ObjRec *obj_ptr; char s[80]; int i, poly_id, speed, pixel, clicked = FALSE; XEvent input; XButtonEvent *button_event; AllocReturnStr(ReturnStr); strcpy(*ReturnStr, ""); while (XPending(mainDisplay) != 0) { XPeekEvent(mainDisplay, &input); if ((input.type & (PointerMotionMask | ExposureMask | EnterWindowMask | LeaveWindowMask)) != 0) { XNextEvent(mainDisplay, &input); HandleSimpleEvent(input); } else { if (input.type == ButtonPress) clicked = TRUE; /* do not translate -- program constants */ strcpy(*ReturnStr, "Interrupt"); break; } } /* do not translate -- program constants */ printf("--> Animate(%s, %s, %s, %s)\n",TypeStr,PolyId,SpeedStr,ColorStr); if (strcmp(TypeStr, "waitclick") == 0) { Msg(TgLoadString(STID_LEFT_STEP_MID_RUN_RIGHT_STOP)); if (!clicked) { while (TRUE) { if (XPending(mainDisplay) != 0) { XNextEvent(mainDisplay, &input); if (input.type == ButtonPress) { break; } } } } else { XNextEvent(mainDisplay, &input); } button_event = &(input.xbutton); /* do not translate -- program constants */ switch (button_event->button) { case Button1 : strcpy(*ReturnStr, "Left"); break; case Button2 : strcpy(*ReturnStr, "Middle"); break; case Button3 : strcpy(*ReturnStr, "Right"); break; } Msg(""); } else { poly_id = atoi(PolyId); for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (obj_ptr->type == OBJ_POLY && obj_ptr->id == poly_id) { break; } } /* do not translate -- program constants */ if (obj_ptr == NULL) { sprintf(s, TgLoadString(STID_CANT_FIND_POLY_WITH_GIVEN_ID), poly_id); Msg(s); } else if (strcmp(TypeStr, "send") == 0) { speed = atoi(SpeedStr); pixel = (colorDisplay) ? xorColorPixels[obj_ptr->color] : 1; AnimateSend(obj_ptr->detail.p, speed, pixel); } else if (strcmp(TypeStr, "flash") == 0) { if (colorDisplay) { strcpy(s, ColorStr); } else { strcpy(s, "white"); } for (i = 0; i < maxColors; i++) { if (strcmp(colorMenuItems[i], s) == 0) { AnimateFlashColor(obj_ptr, i); break; } } } } } static void MyFormat(Str) char *Str; { register char *c_ptr=Str, *period_ptr=NULL; register int i; for ( ; *c_ptr != '\0'; c_ptr++) { if (*c_ptr >= '0' && *c_ptr <= '9') { continue; } else if (*c_ptr == '.') { if (period_ptr != NULL) return; period_ptr = c_ptr; continue; } else { return; } } if (period_ptr == NULL) return; for (c_ptr = period_ptr, i = 0; *c_ptr != '\0' && i < 7; c_ptr++, i++) ; if (*c_ptr != '\0') *c_ptr = '\0'; } void UpdAttrVal(ObjId, AttrName, AttrColor, AttrVal, ReturnStr) char *ObjId, *AttrName, *AttrColor, *AttrVal; char **ReturnStr; { struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; char s[MAXSTRING]; int obj_id; XEvent input; XButtonEvent *button_event; AllocReturnStr(ReturnStr); strcpy(*ReturnStr, ""); while (XPending(mainDisplay) != 0) { XPeekEvent(mainDisplay, &input); if ((input.type & (PointerMotionMask | ExposureMask | EnterWindowMask | LeaveWindowMask)) != 0) { XNextEvent(mainDisplay, &input); HandleSimpleEvent(input); } else { /* do not translate -- program constants */ strcpy(*ReturnStr, "Interrupt"); button_event = &(input.xbutton); switch (button_event->button) { case Button1 : strcpy(*ReturnStr, "Left"); break; case Button2 : strcpy(*ReturnStr, "Middle"); break; case Button3 : strcpy(*ReturnStr, "Right"); break; } break; } } /* do not translate -- program constants */ printf("--> UpdAttrVal(%s, %s, %s, %s)\n", ObjId, AttrName, AttrColor, AttrVal); obj_id = atoi(ObjId); for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (obj_ptr->id == obj_id) { break; } } if (obj_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_OBJ_WITH_GIVEN_ID), obj_id); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { attr_ptr = obj_ptr->fattr; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (strcmp(AttrName, attr_ptr->attr_name.s) == 0 && strcmp(AttrColor, colorMenuItems[attr_ptr->obj->color]) == 0) { break; } } if (attr_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_ATTR_NAME_AND_COLOR), AttrName, AttrColor); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { struct DynStrRec *dyn_str_ptr=NULL; DynStrSet(&attr_ptr->attr_value, AttrVal); MyFormat(attr_ptr->attr_value.s); if (attr_ptr->nameshown) { sprintf(s, "%s%s", attr_ptr->attr_name.s, attr_ptr->attr_value.s); } else { strcpy(s, attr_ptr->attr_value.s); } if (attr_ptr->shown) RepaintFirstStr(attr_ptr->obj, s); dyn_str_ptr = GetTextFirstDynStr(attr_ptr->obj); DynStrSet(dyn_str_ptr, s); } } } void SetLastKeyEvInfo(key_ev) XKeyEvent *key_ev; { lastKeyOrBtnEvInfo.type = key_ev->type; lastKeyOrBtnEvInfo.send_event = key_ev->send_event; lastKeyOrBtnEvInfo.display = key_ev->display; lastKeyOrBtnEvInfo.window = key_ev->window; memcpy(&lastKeyOrBtnEvInfo.time, &key_ev->time, sizeof(Time)); lastKeyOrBtnEvInfo.x = key_ev->x; lastKeyOrBtnEvInfo.y = key_ev->y; lastKeyOrBtnEvInfo.keycode_or_button = key_ev->keycode; lastKeyOrBtnEvInfo.state = key_ev->state; } void SetLastBtnEvInfo(button_ev) XButtonEvent *button_ev; { lastKeyOrBtnEvInfo.type = button_ev->type; lastKeyOrBtnEvInfo.send_event = button_ev->send_event; lastKeyOrBtnEvInfo.display = button_ev->display; lastKeyOrBtnEvInfo.window = button_ev->window; memcpy(&lastKeyOrBtnEvInfo.time, &button_ev->time, sizeof(Time)); lastKeyOrBtnEvInfo.x = button_ev->x; lastKeyOrBtnEvInfo.y = button_ev->y; lastKeyOrBtnEvInfo.keycode_or_button = button_ev->button; lastKeyOrBtnEvInfo.state = button_ev->state; } tgif-QPL-4.2.5/HISTORY0000644000076400007640000024123711602233311014060 0ustar williamwilliam-----------------------> tgif-4.2.4 => tgif-4.2.5 <----------------------- 1) Fix a crashing bug when copying a string with non-simple text (e.g., has superscript or subscript). -----------------------> tgif-4.2.3 => tgif-4.2.4 <----------------------- 1) Fix a bug that caused a crash during a Patse operation after the CopyPlainTextAsObject() command has been executed. 2) Fix a crashing bug with GetBoundingBox() when the current linetype is "structured splines". 3) Fix a few compiler-related bugs so that tgif can be compiled under Solaris. A new compiler option (_NO_XUTF8FUNCTIONS) is added so that the Xutf8TextListToTextProperty() is not referenced. 4) Further fix the license problem with "nkf.e", "chinput.e", and "cli_xcin.e". Thanks to Carlo U. Segre for pointing out the additional problems. -----------------------> tgif-4.2.2 => tgif-4.2.3 <----------------------- 1) Fix a bug with pasting garbage characters from Windows under cygwin. This used to cause file corruption. 2) Fix a bug with double-byte characters or international characters when eglibc is used. Thanks to Gunter Frenz , Hiroshi TSUTSUI , and Klaus Koepernik for pointing out the problem and Hiroshi TSUTSUI for the patch. 3) Allow Tgif.EnableTrueColorImages to be set to "true" only if tgif is compiled with zlib support. Also, starting with this version, if one has a TrueColor display, Tgif.EnableTrueColorImages is set to "true" by default. 4) Add support a new built-in double-byte input method, tgchgb, to support the input of gb2312 encoded simplified Chinese characters using a graphical zhu-yin-fu-hao keypad (would also accept pinyin directly). This input method is activated by typing when a double-byte chinese font is selected. On Windows systems, may be used by a Windows input method. If this is the case, one should type instead. 5) Allow Flood Fill and Replace Color to use a threshold value. Add new X defaults, Tgif.EnableThresholdFloodReplaceColor and Tgif.FloodReplaceColorThreshold to set default values for this feature. 6) Better support for transparent pixels for X11 pixmap objects. 7) Add -D_NO_LOCALE_SUPPORT to CFLAGS in Makefile.am so that, by default, tgif will be compiled without locale support if the configure script is used to build tgif. 8) Add a new X default, Tgif.NoOrientationIfPdfSetPageDevice, so that the "%%Orientation:" line is not used in the PostScript file if "setpagedevice" is active when exporting a PS/EPS/PDF file. 9) Add "eq4-2x-nowin-jpg.sym" to be used instead of "eq4-2x-jpg.sym" to run silently (i.e., no popup window). This should get around the problem that on cygwin, sometimes a popup window will not close by itself. 10) Add new X defaults, Tgif.PNGExportHasTransparentColor, Tgif.PNGExportTransparentColor, and Tgif.PpmToPngWithTransparentColor to suppor the generation of transparent PNG files. 11) Add new X defaults, Tgif.UseStdPalette8, Tgif.UseStdPalette27, Tgif.UseStdPalette64, Tgif.UseStdPalette216/Tgif.UseMobileWebSafePalette, Tgif.UseOpenOfficeGalaxyPalette, and Tgif.UseOpenOfficeGooglePalette to use a standard 8-color, 27-color, 64-color, 216-color, 53-color, and 80-color palette as the startup colors for tgif. Also added Tgif.AdditionalColors to take effect if any of these X defaults are used. 12) Add a new X default, Tgif.DefaultColor, so that the default tgif color can be specified using a color name. 13) Obsolete the Tgif.DeleteCmdAsCut X default. Now Cntrl+x is bound to the Cut command. To delete something without cutting it into the cut buffer, one can use the key on the keyboard or select Delete from the Edit Menu. 14) Fix a license problem. The files, "nkf.c", "chinput.c", and "cli_xcin.c" do not have compatible license with the QPL license. Therefore, starting with this release, they will be removed (and replaced by empty files) from the QPL distribution of tgif (and -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN must be used in MISCDEFINES in Tgif.tmpl to avoid compiler errors). These files will only be available in the free-of-charge distribution of tgif. Thanks to Carlo U. Segre for pointing out the problem. -----------------------> tgif-4.2.1 => tgif-4.2.2 <----------------------- 1) Fix a bug with parsing Tgif.AdditionalFonts. Thanks to Thomas Sefzick for pointing out the bug. 2) Fix a bug with copying and pasting in cygwin. By default, tgif no longer uses the old style X cut buffer. 3) Fix a bug with copying UTF-8 characters in cygwin. 4) Fix a bug when Tgif.EnableTrueColorImages is set to "true" and positions of true color (i.e., ppm_true) objects do not show up correctly. 5) In printing/exporting to a PS/EPS/PDF file, if a text object is simple (i.e., single line with no superscript, subscript, or horizontal thin space) and it has a background fill pattern, generate PostScript code to draw a horizontally tighter boundingbox. 6) Add InsertSymbol() under the Text submenu of the Edit Menu. 7) Add a very simple right-margin feature when entering text. This is far from a full-featured right-margin. It is only activated under the following conditions: text cursor is at the last position in the text object being edited (i.e., appending to the current text object), text object is not transformed, text is left-justified, text cursor is not inside a superscript or a subscript, no zoom, and Tgif.EditTextSize is not used. Tgif.RightMargin can be used to specify the right margin. Tgif.EnableRightMargin can be used to enable this feature. Add EnableRightMargin() and SpecifyRightMargin() under the Show/Hide submenu of the Layout Menu. 8) Add overline for text objects. 9) Add "eq4jpg.sym" and "eq4-2x-jpg.sym" to be used instead of "eq4xpm.sym" if "eq4xpm.sym" gives you an all-black or all-white image. The problem was that there is a bug in ImageMagick's "convert" when converting EPS file to a PPM file. With "eq4jpg.sym" and "eq4-2x-jpg.sym", "convert" will be called to convert an EPS file to a JPEG file with "-scale 25% -density 576" as commandline parameters. These two new symbol files are best used with Tgif.EnableTrueColorImages set to "true". 10) Remove Tgif.TighterStructuredSplines from the documentation since this X default is invalid. 11) Add the following internal commands: set_selected_text_overline() -----------------------> tgif-4.2 => tgif-4.2.1 <----------------------- 1) Fix a bug with rotated circles. 2) Fix a bug with c not working on Mac OS X. 3) Fix a bug in Imakefile which would fail to install some icon files during "make install". -----------------------> tgif-4.1.45 => tgif-4.2 <----------------------- 1) Fix bugs with copy and paste. Thanks to Dr. Ing. Dieter Jurzitza for pointing out the bug and helping to find the problem. 2) Fix a bug with the pstoepsi() internal command so that tgif does not crash if pbmtoxbm is not installed. Thanks to Yannick Morvan for pointing out the bug. 3) Fix a bug with pinned shape menu. The problem was that text cannot be entered immediately after a shape is created, Thanks to Paul Lew for pointing out the bug. 4) Fix a crashing bug which happens when Tgif.DefFixedWidthFont is used and a non-existent double-byte font is specified in the X resource file. 5) Fix a bug with Tgif.DeleteCmdAsCut. It was not handled like the way it said in the man pages. 6) Incorporate the following patches from the Fedora RPM package (tgif-4.1.45-5.fc8.src.rpm): tgif-4.1.35-overthespot_fix.patch tgif-4.1.44-xim-bad-focus.patch tgif-4.1.45-fontcheck.patch tgif-QPL-4.1.45-open-with-mode.patch tgif.gif tgif-4.1.41.ja.po (in po/ja) tgif-4.1ja9.tar.gz (in po/ja) tgif-wrapper.sh (in po/ja) tgif.desktop (in po/ja) tgif.spec (in po/ja) The following patch is not applied since it did not look correct. tgif-textcursor-a-urasim.patch I don't understand why the most-significant-bit is cleared no matter what. The original code in tgif right below this patch suppose to handle the situation correctly. 7) Fix a bug with composing international characters. In newer Linux releases, UTF8 characters are used by default when international characters are composed. These UTF8 characters are often multi-byte characters so they needed to be converted to single-byte in order to use X11 fonts. To get this to work, tgif loads "libidn" dynamically and calls functions in "libidn" to do the conversion. If your system does not have "libidn", you can use the -D_NO_IDNLIB compiler option so that tgif will not attempt to load "libidn". 8) Fix typos in "tgif.pl". Thanks to Carlo Segre for pointingn out the bugs. 9) Fix various mistakes in "tgif.man". Thanks to Shigeharu TAKENO for the patch. 10) Rename the Tgif.IconPixmap X default to Tgif.WMIconPixmap. If this is not done, Xtoolkit will interpret this X default and display an error message. Thanks to Dr. Ing. Dieter Jurzitza for pointing out the problem. 11) Export in the SVG (Scalable Vector Graphics) format. This requires "uniconvertor" (which is part of the "uniconvertor" package) and "pstoedit" (which is part of the "pstoedit" package). One known limitation of "uniconvertor" is that it cannot convert bitmap/pixmap patterns/objects. 12) Add support for user-specified rotation pivot. 13) Add support for "structured splines" where cubic Bezier curves are used. The Tgif.SplineRubberband X default became obsolete. 14) Add "eq4png.sym" to be used instead of "eq4xpm.sym" if "eq4xpm.sym" gives you an all-black or all-white image. The problem was that there is a bug in ImageMagick's "convert" when converting EPS file to a PPM file. With "eq4png.sym", "convert" will be called to convert an EPS file to a PNG file. 15) Integrate the Tangram Whiteboard feature into tgif on Linux machines. This feature used to be experimental (enabled if compiled with the -D_TGIF_WB2 option). Now the authors of the Reliable IP-multicast Library (distributed in the "rmcast" subdirectory of tgif) believe that "rmcast" is mature enough, the interface to "rmcast" is now enabled by default (but not activated unless you run tgif with the "-tgwb2" commandlinen optoin). If you want to try this feature, you might want to make sure that your network interface card has multicast turned on (using "ifconfig multicast") and your firewall is not blocking the multicast port used by the whiteboard (default address is 225.1.2.3). You can try adding "... -p udp -d 225.1.2.0/24 -s 127.0.0.1 -j ACCEPT" to /etc/sysconfig/iptables. The "libz" and "libpthread" libraries are required to interface with the "rmcast" library. Therefore, "-lz -lpthread" must be used in Tgif.tmpl. If your system does not have "libz", you can use the -D_NO_LIBZ compiler option and remove "-lz" from Tgif.tmpl. If your system does not have "libpthread", you can remove "-DPTHREAD" and "-lpthread" from Tgif.tmpl. Thanks to Jorge Allyson Azevedo and other members of the research group lead by Professor Edmundo de Souze e Silva at the Federal University of Rio de Janeiro. 16) Add a new X default, Tgif.EnableTrueColorImages, so that on TrueColor displays, X11 pixmap and JPEG objects can have all the colors. Internally, tgif stores them as deflated (using zlib) PPM files. Therefore, this feature requires zlib and pbmplus to be installed on your system. 17) Add a new X default, Tgif.CustomPatternDir, so that tgif can replace the default patterns for fills and pens with custom ones. Thanks to Daniel Bauer for the patch. 18) Add a new X default, Tgif.ReportMissingFonts, so that tgif can report missing fonts when it starts. 19) Add new X defaults, Tgif.@@@ConvFromUTF8 and Tgif.@@@ConvToUTF8, where @@@ is the name of a double-byte font, to convert between UTF8-encoded strings and strings of the named double-byte font. The specified commands are used in the new Copy and Paste Double Byte (UTF8) Strings operations under the Edit Menu. 20) Add a new X default, Tgif.DefaultLatin1FontCharEncoding, so that the 4 default fonts (Times, Courier, Helvetica, and NewCentury) can use character encoding other than iso8859-1. Newer Linux systems seem to have only a small number of font sizes available for these fonts. The scalable and pre-installed version of these fonts are all iso10646-1 encoded. This is best for creating new tgif files. There may be a slight compatibity problem with existing tgif files because the iso10646-1 fonts seem to be taller than their iso8859-1 counterparts. 21) Add Tgif.tmpl-dragonfly (identical to Tgif.tmpl-netbsd) for DragonFly BSD. 22) Enable printing for X11 pixmap objects having too many colors (as long as it does not have transparent pixels). 23) Add "configure" to the distribution so that on systems that does not have "imake", a "Makefile" can be created by running "./configure". This is new and has only been tested on a few platforms. If this does not work on certain systems, please send an e-mail to the author. Thanks! 24) Add a dependency in the tgif.spec file to declare that tgif depends on the xorg-x11-fonts-ISO8859-1-75dpi, ghostscript, and netpbm-progs packages. If you install tgif using an RPM file, you must have these three packages installed before you can install tgif. 25) Add the following internal commands: random_permute_lines_in_attr() find_obj_names_on_all_pages(,) -----------------------> tgif-4.1.44 => tgif-4.1.45 <----------------------- 1) Fix a bug with the create_arc_obj() internal command. Thanks to Jack Tucker for pointing out the bug. 2) Fix a bug with measurements in the ruler window when Tgif.ShowMeasure is active. Thanks to Olin Johnson for pointing out the bug. 3) Fix a bug with "tgif -print -pdf". Thanks to Rob for pointing out the problem. 4) Fix a bug with copy and paste in cygwin. Thanks to Tobias Naehring for fixing the bug. 5) Move tgif's web server to a standard web server port (80). The new tgif home page is now at: http://bourbon.usc.edu/tgif/ 6) Please note that as of 5/16/2006, postings to tgif related groups at Yahoo!Groups are restricted to members only. This is done to cut down SPAM. The affected groups are at: http://groups.yahoo.com/group/tgif4-discuss http://groups.yahoo.com/group/tgif4-howto http://groups.yahoo.com/group/tgif4-bugs http://groups.yahoo.com/group/tgif4-develop If you have registered as a member in a group above, you can now only post via the web interface or by sending an e-mail from your registered e-mail address. Sorry about this inconvenience. But there have been just too much SPAM on these lists. 7) Use the X Selections mechanism to perform copy and paste. 8) Add support for linking to an external JPEG file to save file size (under File->Import). Some editing operations cannot be performed on these linked JPEG objects. However, these objects do not have the color limitation of X11 pixmap objects. Therefore, when they are exported in the PS/EPS formation, they will have a lot more colors. 9) The standard Linux distribution now use Xtoolkit by default (this is done by including -DUSE_XT_INITIALIZE in the MISCDEFINES line and -lXt in the SYS_LIBRARIES line of Tgif.tmpl-linux). One advantage of this is that now it's easy to override X defaults. For example, one can use: tgif -xrm "Tgif.Foreground: red" 10) Add support for Tgif.PSDistillerNoImageCompress so that images in a generated PostScript file will not be compressed by a distiller program such as ps2pdf. Thanks to Dirk Farin for supplying the PostScript code. Please use Tgif.PSDistillerNoImageCompress with care. It has been noticed that generated EPS file may not work well with LaTeX. 11) Add support for Tgif.AdditionalPSSetup (and -pssetup commandline option) so that a user can add additiional user specified PostScript code in the PostScript file header (right before %%EndSetup). 12) Support a new commandline option "-noshowpageineps" so that the "showpage" PostScript command is not generated when printing/exporting in the EPS format when tgif is run with "-print".. 13) Add support for Tgif.PSFontNeedCharSubs and Tgif.PSCharSubs.* so that some characters in the non-ASCII portion of a non-iso8859-1 font can be replaced by user specified PostScript characters. Thanks to Peter Dembinski for the suggestion. 14) Add a new X default, Tgif.DrawTextFuncKey_F#, so that a function key can be associated with a list of internal commands (and activiated only in the text drawing mode). 15) Add the following internal commands: set_selected_text_style() objs_bbox_intersect(,,) delete_all_attr_from_selected_objs() -----------------------> tgif-4.1.43 => tgif-4.1.44 <----------------------- 1) Fix a bug with imagemap generation. Thanks to Jerry Nicholls for the patch. 2) Replace "eq4.sym" and "eq4-2x.sym". These new LaTeX equation symbols do *not* use pstoepsi, ps2epsi, etc. It only requires "latex", "dvips", and "gs" to function. 3) Add the following new internal command: pstoepsi(,,) -----------------------> tgif-4.1.42 => tgif-4.1.43 <----------------------- 1) Fix key problem with Mac OS X (Darwin). The Apple Command Key is mapped to Mod2Mask by default. This will be treated as the (or ) key in tgif. 2) Fix a bug with importing an EPS file generated by ps2epsi. Thanks to Ambrose Li for the patch. 3) Fix tgif to be able to import an EPS file with an 8 bit-per-sample preview bitmap (such as the ones generated by ps2epsi). 4) Get tgif to work with out-of-the-box xcin on Red Hat Linux. Thanks to Ambrose Li for all the help. 5) Add support a new built-in double-byte input method, tgtwb5, to support the input of big5 encoded traditional Chinese characters using a graphical zhu-yin-fu-hao keypad. This input method is activated by typing when a double-byte chinese font is selected. 6) Add chat to tgwb. 7) Support a new commandline option "-sbim xim" to use XIM as the input method for single-byte fonts. This is useful if the X Keyboard Extension is used in inputing international characters (with dead keys). Thanks to Daniel Sadoc Menasche for the contribution. 8) Add a new X default, Tgif.IgnoreSlideShowOfffsetsInFile, so that the slideshow offsets stored in a file can be ignored in the slideshow mode. The reason for this is that the offsets mainly depends on the display and not on the content of the file. The slideshow offsets should be set using the Tgif.SlideShowWindowOffset X default. 9) Add a new LaTeX equation symbol file "eq4-lyx-ps2epsi.sym" in the release to edit the equation with LyX. Thanks to Ed Gatzke for the contribution. 10) Update "ru.po". Thanks to Andrew W. Nosenko for the update. 11) Add -D__EMX__ in Tgif.tmpl-cygwin to fix the problem with calling stat() on pathnames that begins with "//". Thanks to Dr. Ing. Dieter Jurzitza for pointing out the problem. 12) Add support for importing tgif files with the import_file() internal command. 13) Add the following new internal commands: shuffle_obj_to_bottom() set_file_unsavable() -----------------------> tgif-4.1.41 => tgif-4.1.42 <----------------------- 1) Tgif's home has moved from University of Maryland to University of Southern California. The new tgif home page is now: http://bourbon.usc.edu:8001/tgif/ 2) If there's no domain resources specified in the X resource file, tgif will use the library path specified when tgif is compiled as the default. This is the directory where the equation symbols are installed. Thanks to A. Sengupta for pointing out the problem. 3) For Red Hat 7.2, /usr/bin/xpmtoppm cannot handle input file whose format is XPM version 1. Suport for a new compiler option, -D_XPM3TOPPM, is added so that tgif can generate XPM format version 3 by default. This is has the same effect as setting Tgif.XPmOutputVersion to 3 and Tgif.UseXPmVersion1ForImageMap to false. 4) Add more information in the tooltip when Tgif.MeasureTooltipVerbose is set to true. 5) Add a new LaTeX equation symbol file "eq4xpm.sym" in the release. Instead of generating and embedding an EPS file, this new object will generate and embed an XPM file with additional controls. Please open this file with tgif for more details and check out http://bourbon.usc.edu:8001/tgif/faq/eq4xpm.html. Thanks to Kai Sattler for the contribution. 6) Fix a bug in tgwb when a text object is being edited. 7) Obsolete the Tgif.LandscapePdfSetPageDevice X default (because the name was misleading) and add support for a new X default, Tgif.PdfSetPageDevice. As mentioned in the release notes for tgif-4.1.39, the use of this should not be necessary in the future (and is considered a bug in ps2pdf). The old commandline option, "-nolandpdfspd" is also obsolete and is replaced by "-pdfspd=yes" and "-pdfspd=no". 8) Add a new X default, Tgif.NoModeWindow, so that tgif can start without a mode window. 9) Add a new X default, Tgif.MakeUnsavableInSlideShow, so that the current file will be made unsavable when slideshow mode is entered. (If the current file contains auto page numbering objects, the file will be made unsavable regardless of the setting of this X default.) 10) Update the Reliable IP-multicast Library (distributed in the rmcast subdirectory of this distribution). The new version allows point-to-point connection between 2 whiteboards. Please see the updated README.tgwb file. Thanks to the team members of the research group lead by Professor Edmundo de Souze e Silva at the Federal University of Rio de Janeiro. -----------------------> tgif-4.1.40 => tgif-4.1.41 <----------------------- 1) A QPL version of this distribution of tgif is simultaneously released. 2) Update the output of the About command in the Help Menu to show that tgif's new mailing list address is tgif4-announce at yahoogroups.com. 3) Fix a bug with "on_resize=" attribute when multiple objects have the same name. Thanks to Alan M Stephenson for pointing out the problem. 4) Fix a bug with Tgif.DeleteCmdAsCut. Thanks to Ralphe Neill for pointing out the problem. 5) Fix a bug with the select_each_obj_and_exec() internal command. Thanks to Dan McMahilll for pointing out the problem. 6) Fix a uninitialized variable bug. This causes things to fail when running tgif with -print -eps commandline options. Thanks to Dan McMahilll for pointing out the problem. 7) Remove a redundant "a4" string in the generates PS file if A4 paper is requested by using the Tgif.PSA4PaperSize X default. This seems to causes ghostscript to generate problematic pnm file. Thanks to AMAKAWA Shuhei for the patch. 8) Add horizontal scroll for mouse wheel. When the key is held down, the mouse wheel can now scroll horizintall. Thanks to Shin-ichi KANNO for the patch. 9) Add a compiler option -D_DONT_REENCODE in Tgif.tmpl* so that a list of PostScript fonts for which reencoding is not allowed can be specified at compile time. Please see the explanation on Tgif.DontReencode in the X DEFAULTS section of the man pages regarding the format of this option. Tgif.DontReencode has precedence over -D_DONT_REENCODE. At run time, if you just want to add fonts to the list specified by -D_DONT_REENCODE, you should use the new Tgif.AdditionalDontReencode X default. A commandline option, -listdontreencode, is added to print out the value of the -D_DONT_REENCODE compiler option used in compiling tgif. 10) Add ConvertToBezier in the Poly/Polygon submenu of the Edit Menu to convert a spline object to a Bezier curve. Thanks to Jurgen Rusch for the conversion script. 11) Add a bunch of commands for adding tick marks to a poly/polygon/spline object. 12) New Tgif.tmpl-darwin file for Darwin/Mac OS X (with XFree86). Thanks to Eric Cronin for providing it. 13) Update tgwb (the tgif-based whiteboard application) to use a new Reliable IP-multicast Library (distributed in the rmcast subdirectory of this distribution). Thanks to the team members of the research group lead by Professor Edmundo de Souze e Silva at the Federal University of Rio de Janeiro. This update fix the problem with large objects mentioned in the README.tgwb file in prior releases. However, it still has the problem that there is no privison made for joining a whileboard in session (escept for selecting New from the File Menu of a tgwb to clear all whiteboards). Please see the updated README.tgwb file. 14) Add a new X default, Tgif.UseXPmVersion1ForXPmDeck, so that when converting a deck of X11 pixmap objects to a GIF animation file, the XPM version specified by Tgif.XPmOutputVersion X default can be used (instead of using version 1 XPM format). 15) Add new X defaults, Tgif.SlideShowWindowOffsets and Tgif.SlideShowBorderColor, so that when converting to set the initial window offsets and border color for the slideshow mode. 16) Add the following new internal commands: edit_attr_in_text_mode() -----------------------> tgif-4.1.39 => tgif-4.1.40 <----------------------- 1) Fix a crashing bug in Specify An Arc when the input is something like "0.9,-,10,20". Thanks to Adrian Bridgett and Jano van Hemert for pointing out the problem. 2) Fix a uninitialized variable bug. This causes crashes sometimes when running tgif with -print -xbm commandline options. Thanks to Alexander Tenbusch for pointing out the problem. 3) Fix a bug with exporting landscape TiffEPSI files. Thanks to Geert Carron for pointing out the bug. 4) Fix a bug with displaying text objects when Color Layers are used and some colors are turned off. Thanks to Johan Vromans for pointing out the bug. 5) Add scroll support for mouse wheel. By default, mouse wheel up is mapped to Button4 and mouse wheel down is mapped to Button5. A new X default, Tgif.EnableMouseWheel, is added so that this can be turned off. Some mouse wheel can generate Button2 events, and this may interfere with scrolling; therefore, another X default, Tgif.Btn2PopupMainMenu, is added so that Button2 events will not popup the Main Menu in the canvas window. Thanks to Juha Takala for providing the information. 6) New Tgif.tmpl-cgywin file. Thanks to Simon Moore for providing it. 7) New Tgif.tmpl-uw7 file. Thanks to Ron Record for providing it. 8) Add a new X default, Tgif.DeleteCmdAsCut so that x can be used Cut selected objects. (Pressing the key on the keyboard will still perform a regular Delete in this case.) -----------------------> tgif-4.1.38 => tgif-4.1.39 <----------------------- 1) Add a new X default, Tgif.LandscapePdfSetPageDevice. Currently, when exporting landscape PDF files, tgif will use a PostScript "setpagedevice" command to rotate the generated PostScript file 270 degrees before calling ps2pdf. This should not be necessary (and is considered a bug in ps2pdf). In the future, this X default can be used to turn off the generation of the "setpagedevice" command when ps2pdf can handle landscape PostScript files correctly. A new commandline option, -nolandpdfspd, to be used in conjunction with -print is also added for the same purpose. Thanks to Johan Vromans for the suggestion. -----------------------> tgif-4.1.37 => tgif-4.1.38 <----------------------- 1) Fix a bug in Print Selected Objects that imported EPS objects are not exporte. Thanks to Ralphe Neill for pointing out the problem. 2) For a tgif file in landscape mode, generate the correct (rotated) PDF file. Thanks to Johan Vromans and Goeran Hanke for the solutions. 3) Update ja.po. Thanks to Jun Nishii for the patch. 4) Add a README file in the spice subdirectory to include some notes on the ports and components feature of tgif. 5) Add a compiler option -D_PRTGIF_USE_ISO_LATIN_1_ALWAYS to always use ISO 8859-1 character set for single-byte characters when running tgif with the -print commandline option. Please only use this if you are sure that you will *never* use other encoding. You can selectively turn off reencoding by using either the Tgif.DontReencode X default or the -dontreencode commandline option. Thanks to Ambrose Li for the patch. -----------------------> tgif-4.1.36 => tgif-4.1.37 <----------------------- 1) Fix a bug that may cause seg faults when reading tgif files. Thanks to Hiroei IMAI for the patch. -----------------------> tgif-4.1.35 => tgif-4.1.36 <----------------------- 1) Fix a bug in Latest Release Info under the Help Menu. Thanks to Dr. Ing. Dieter Jurzitza for pointing out the bug. 2) Fix a bug in handling the Edit Attribute in Editor Context Menu when the edit_attrs_in_context_menu attribute is used. Thanks to Ana Paula for pointing out the problem. -----------------------> tgif-4.1.34 => tgif-4.1.35 <----------------------- 1) Fix a bug with Copy and Paste operations in edit text mode for mixed text objects when the Edit Text Size is non-zero. Thanks to Heiko Scheit for pointing out the problem. 2) Propagate certain DSC comments, such as %%DocumentFonts, %%LanguageLevel, %%Extensions, %%DocumentNeededFonts, and %%DocumentNeedResources, of imported EPS files when printing/exporting in PS/EPS formats. Please note that this does not work with embedded EPS files (until the next major release when a new file format is introduced). Thanks to Johan Vromans for pointing out the problem. 3) Support the use of tempnam() instead of mktemp() due to some security considerations. On systems that do support tempnam(), the _DONT_USE_MKTEMP compiler option can be used to use tempnam() instead of mktemp(). Tgif.tmpl-linux (which is identical to the default Tgif.tmpl), Tgif.tmpl-freebsd, Tgif.tmpl-openbsd, and Tgif.tmpl-netbsd uses -D_DONT_USE_MKTEMP by default. Thanks to Adrian Bridgett for pointing out the problem. 4) Add new X defaults: Tgif.TmpDirInHomeDir and Tgif.TmpDir. Together with the _TMP_DIR_IN_HOME_DIR compiler option, the temporary directory can be specified in a flexible way. 5) Add Create Thumbnails in the Browse submenu of the Import submenu of the File Menu. Add new X defaults, Tgif.ThumbnailGeometry, Tgif.ThumbnailPadding, Tgif.ThumbnailXGap, Tgif.ThumbnailYGap, Tgif.ThumbnailX, and Tgif.ThumbnailY to control the size and placement of the thumbnails. 6) Modify CutPoly() so that it can be used to cut polylines/polygons into segments in select mode. 7) New Tgif.tmpl-sco file. Thanks to Jason Moore for providing it. 8) Add Ports and Signals submenu to the Special Menu. Please see the CONNECTING OBJECTS section of the man pages for details. The symbol files in the spice directory is updated to use the new port symbol. 9) A new License file is included in this release. -----------------------> tgif-4.1.33 => tgif-4.1.34 <----------------------- 1) Fix a crashing bug in drawing linearly transformed arc objects. Apparently, this bug has been around for a long time. Thanks to Hari Radhakrishnan for pointing out the problem. 2) Support the JPEG export format. Add new X defaults, Tgif.XpmToJpeg and Tgif.JpegFileExtension. The default value them are "xpmtoppm %s | cjpeg" and "jpg", respectively. 3) Add a new X default, Tgif.AutoEPSPreviewBitmap, to enable the automatic generation of a preview bitmap when importing a PS/EPS file, if the file does not contain a preview bitmap. (This can be turned on and off from the Import submenu of the File Menu.) The feature also uses a new X default, Tgif.PsToXbm, so that the default PS/EPS to XBM filter can be overridden. The default value for Tgif.PsToXbm is: gs -q -dNOPAUSE -sDEVICE=pbm -sOutputFile=- -- "%s" | pbmtoxbm Please note that the above command usually generates a bitmap that's much larger than image in the file. Tgif automatically trims out the blank space similar to the way pbmtoepsi works. Thanks to Ed Vigmond for the suggestion. -----------------------> tgif-4.1.32 => tgif-4.1.33 <----------------------- 1) Fix a bug that was introduced in tgif-4.1.30 (see item 3 of tgif-4.1.29 => tgif-4.1.30 below). This bug only happens if you are printing black and white PS file with UseGrayScale enabled. Thanks to Dr Milos Ercegovac for pointing out the problem. 2) Fix a JoinPoly() bug in vertex mode. -----------------------> tgif-4.1.31 => tgif-4.1.32 <----------------------- 1) Fix a bug that was introduced in tgif-4.1.30 (see item 2 of tgif-4.1.29 => tgif-4.1.30 below). Thanks to Geert Carron for pointing out the problem. -----------------------> tgif-4.1.30 => tgif-4.1.31 <----------------------- 1) Fix a typo that cause link problems on Linux. 2) Add a new X default, Tgif.AutoWrapMenubar, so that menubar will automatically wrap around. If Tgif.MinimalMenubar is set to false, menubar will always wrap around automatically. -----------------------> tgif-4.1.29 => tgif-4.1.30 <----------------------- 1) There's a bug with measure tooltip that certain X servers would generate extra Expose events while others would not. The result is that rubber-banding does not work when measure tooltip is enabled. The simple solution here is to make the default value of Tgif.UseMeasureTooltip to be false. Also, the default values of both Tgif.MeasureTooltipXFollowMouse and MeasureTooltipYFollowMouse have been changed to false, also. Thanks to Helmut Jarausch for pointing out the problem. 2) Fix a bug with exporting text objects in PS format when the text object is scales or sheared such that its width or height is 0. This bug is detectable by gs6.0. Thanks to Ingo Jankowski for pointing out the problem. 3) Fix a bug with printing text objects in black&white PS file with UseGrayScale enabled. Thanks to Jurgen Rusch for pointing out the problem. 4) To build "tgwb", instead of using Imakefile.tgwb, use a new and easier to maintain file called Target.tmpl. 5) Add -usexlib commandline option to force tgif to ignore the -DUSE_XT_INITIALIZE compile option and use Xlib only. This is useful when the system resource file for tgif is not installed properly or messed up and needs to be bypassed. 6) Add a new X default, Tgif.NoMinWinSize, so that tgif can be started without a minimum size when it is set to true (which is the default value). The problem with the previous tgif is that, by having a minimum window size, some window managers will show the wrong window size when tgif is being resized. 7) Support the importing of JPEG files in the Import submenu of the File Menu. Add a new X default, Tgif.JpegToXpm, so that the import filter can be replaced. By default, it is set to "djpeg -gif -color 222 %s | giftopnm | ppmtoxpm". -----------------------> tgif-4.1.28 => tgif-4.1.29 <----------------------- 1) Fix a bug with mouse action status in the color window if Use Color Layers is selected in the Layout Menu. Thanks to Hal Snyder for pointing out the problem. 2) Add French locale in the distribution. Thanks to Roland Baudin for the contribution. 3) Add ImageProc context submenu for an XPM object. 4) Add Get Property context submenu. 5) If an object has an attribute called "edit_attrs_in_context_menu=", the values (starting from the 2nd line and separated by linebreaks) of this attribute are treated as attribute names. The named attributes will be visible in the Edit Attribute In Editor submenu of the Context Menu. 6) Add Replace Graphic in the Special Menu. After you have selected a graphical object and copy it into the cut buffer, you can select another object and select Replace Graphic to replace the graphical part of the selected object by what's in the cut buffer. All attributes of the object will be preserved. 7) Add tooltip support for Show Measurement. Thanks to Raphael Dechenaux for the contribution. The following new X defaults are supported (with their default values shown): Tgif.UseMeasureTooltip: true Tgif.MeasureTooltipXFollowMouse: true Tgif.MeasureTooltipYFollowMouse: true Tgif.MeasureTooltipHorizontalPosition: left Tgif.MeasureTooltipVerticalPosition: top Please see the man pages for details. 8) Add README.tgwb and Imakefile.tgwb to make tgif into "tgwb", which is a vector-drawing coorporative whiteboard application based on tgif. Tgwb is tested on Linux and Solaris platforms, and it requires IP-multicast. Thanks to the team members of the research group lead by Professor Edmundo de Souze e Silva at the Federal University of Rio de Janeiro. (Please note that the current release of tgwb has a few known bugs. The major ones being that (1) it uses fixed size buffers in communication; therefore, when you operate on a large object, you may get an error message saying that the operation is canceled. (2) There is no privison made for joining a whileboard in session; the way to get around this problem is to select New from the File Menu of a tgwb to clear all whiteboards.) -----------------------> tgif-4.1.27 => tgif-4.1.28 <----------------------- 1) Fix a bug in undoing and redoing delete operations. -----------------------> tgif-4.1.26 => tgif-4.1.27 <----------------------- 1) Fix a divide-by-zero bug in creating an arc (of the 2nd kind). Thanks to Christoph Kukulies for pointing out the problem. 2) Fix a crashing bug in exiting tgif. Thanks to Wolfgang Glunz for pointing out the problem. 3) Fix a menuing bug in using tgif with the NetManage PC X Server. Thanks to Wolfgang Glunz for pointing out the problem. 4) Fix a bug in exporting to PDF format. With the previous implementation, the PDF file may be generated in the wrong directory. The Tgif.PsToPdf X default now must contain 2 "%s" substrings. The new default value for it is "ps2pdf %s %s". 5) Fix a bug in exporting to GIF format using Print One File Per Page when page file names are specified. Thanks to Hal Snyder for pointing out the problem. 6) The current implementation of the whiteboard has a buffer size limitation. When the buffer size is exceeded, tgif will now print an error message and cancel the operation that causes the buffer overflow. -----------------------> tgif-4.1.25 => tgif-4.1.26 <----------------------- 1) Fix a bug with special characters in the page file name. Thanks to Kyle Bateman for pointing out the problem. 2) Fix NLS bugs for status line. Thanks to Jun Nishii for the patch. 3) Fix an offset problem for obj file generated by pstoedit. Thanks to Wolfgang Glunz for pointing out the problem. 4) Precise Scale Everything now flushes undo buffer and cannot be undone. Thanks to Heiko Scheit for pointing out the problem. 5) Add context menu for the edit text box (Move Edit Text Box can be select to move the edit text box). 6) Add Recently Used Files submenu under the File Menu. The size can be controlled by the Tgif.MaxRecentFiles X default. 7) Include "tgif.spec.in" for creating RPM files. Thanks to Tomasz Kloczko and Roberto A. Oppedisano for the contribution. 8) Assign Cntrl+1 and Cntrl+2 to Screen Capture and Full Screen Capture. 9) In a multipage drawing, will not change drawing mode when moving from page to page. 10) Freehand drawing mode will be entered automatically when entering slideshow mode. The can be overridden with the Tgif.GoHyperSpaceInSlideShow X default. A new X default, Tgif.LineWidthIndexInSlideShow, is added to override the default line width of 4 in slideshow mode. 11) Add a new X default, Tgif.ResetOriginOnAdvancePage, so that tgif can be forced to scroll to the left-top corner of the page with no zoom when pages are advanced. 12) Add a new X default, Tgif.FreeHandCursor, to override the default pencil curosr in the freehand drawing mode. -----------------------> tgif-4.1.24 => tgif-4.1.25 <----------------------- 1) Fix a crashing bug in Insert Right Superscript/Subscript when the text cursor is immediately to the right of a right superscript/subscript string segment. Thanks to Helmut Jarausch for pointing out the problem. -----------------------> tgif-4.1.23 => tgif-4.1.24 <----------------------- 1) Fix a couple of bugs in Print Pages. 2) Fix a bug in "-print -html/-gif -o". Thanks to Eddy De Greef for pointing out the problem. 3) Assign Alt+Cntrl+5 to Insert Right Subscript. 4) Fix Precise Scale Everything to scale line widths, arrow widths, and arrow heights. 5) Add NLS support for the status line. Thanks to Jun Nishii for the patch. 6) New Tgif.tmpl-openbsd. Thanks to Hal Snyder for providing the patch. -----------------------> tgif-4.1.22 => tgif-4.1.23 <----------------------- 1) Fix a bug in handling rotated text object exported from the gnuplot tgif terminal. Thanks to Leana Golubchik for pointing out the problem. 2) Fix a bug in handling the if() internal command when "!*" is used. Thanks to Marko Schuetz for pointing out the problem. 3) If a file contains only one page, Print One File Per Page will still produce a file with file name containing the page number. 4) Add a "-merge" commandline option to merge a list of obj files. 5) Add "Print Pages" to the File and Page Menu. 6) Print One File Page will now prompt to see if the user wants to print only selected pages. 7) Update po/ja/ja.po. Thanks to Jun Nishii for the udpate. 8) Change all Tgif.tmpl* files to use a default of _USE_PS_ADOBE_STRING=\"3.0/3.0\" -----------------------> tgif-4.1.21 => tgif-4.1.22 <----------------------- 1) Fix a crashing bug with right click on an non-existant text object. Thanks to Helmut Jarausch for pointing out the problem. 2) Make Import GIF To X Pixmap Desk under the GIF Animation Submenu of the File Menu work with gifsicle-1.16.1. Thanks to Francis Ngoh for pointing out the problem. 3) Fix a RTLD_NOW not-defined bug for FreeBSD 2.2.2. Thanks to Naofumi TSUJII for the patch. 4) Force non-condensed PS export if the file contains an XPM or an EPS object. 5) Add the following new internal commands: delete_eps_child() delete_xbm_child() delete_xpm_child() -----------------------> tgif-4.1.20 => tgif-4.1.21 <----------------------- 1) Fix a crashing bug with pasting compound object into a modified text object in text mode. 2) Fix a crashing bug with "-print -raw http://...". 3) Fix cursorkey bug. Thanks to Stefan Schippers for pointing out the bug. 4) Fix arrow problems with rotated interpolated splines. Thanks to Heiko Scheit for pointing out the problem. -----------------------> tgif-4.1.19 => tgif-4.1.20 <----------------------- 1) Fix a crashing bug with rotated arcs with very small angles. Thanks to Rainer Krienke for pointing out this ancient bug. 2) Fix a crashing bug when redrawing is interrupted immediately after objects are transformed. -----------------------> tgif-4.1.18 => tgif-4.1.19 <----------------------- 1) Fix a crashing bug with the "Edit Attribute In Editor" context menu when selected attribute has it's name not shown. Thanks to Mohammad Bahathir Hashim for pointing out the problem. -----------------------> tgif-4.1.17 => tgif-4.1.18 <----------------------- 1) Fix a crashing bug with PreciseScaleEverything(). 2) Fix a bug in locating a linked EPS file. Thanks to Ralphe Neill for pointing out the problem. 3) Fix a bug with downloading HTTP URL's. It was waiting when it doesn't need to. 4) Fix a bug with when zoomed all the way in. Thanks to Kyle Bateman for pointing out the problem. 5) Fix a crashing bug with entering into text mode under certain text editing sequence. 6) Fix a crashing bug with "-print -gif" when a tgif file contains XPM objects. Thanks to Eddy De Greef for pointing out the problem. 7) Make a file containing auto page numbering objects unsavable after it has been displayed in the slideshow mode. 8) Polyline drawn in the FreeHand mode will always be drawn with straight line segments. Also, use the current linewidth for creating polylines in the freehand mode. This makes creating polylines in the freehand mode more natural. Thanks to Thomas P. Witelski for the suggestion. -----------------------> tgif-4.1.16 => tgif-4.1.17 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a color bug with a depth 1 display. Thanks to Martin Butkus for the patch. 2) Fix incorrect %%Pages: line in generated PS/EPS files when PrintOnePage() or PageOneFilePerPage() is used. Thanks to Dietrich Bartel for pointing out the problem. 3) Fix an offset problem for obj file generated by external tools, such as pstoedit. Thanks to Wolfgang Glunz for pointing out the problem. 4) Fix a coordinate problem with polygon objects when exporting HTML files. Thanks to Peter Marquardt for pointing out the problem. 5) Fix a bug in locating a linked EPS file. Thanks to Ralphe Neill for pointing out the problem. 6) Move all user strings to a new file, "strtbl.c". Now all user strings (in menues, messageboxes, and dialogboxes) are either in "menuinfo.c" or "strtbl.c". This makes creating localized version of tgif easier. 7) Rename the compiler option _ENABLE_NLS to ENABLE_NLS. 8) Add context menu. If there's an object under the mouse when right-clicked, a context menu is popped up. If there isn't, Mode Menu is popped up. As a consequence, Tgif.Btn3PopupModeMenu is obsolete now. A new X default, Tgif.Editor, is added to specify a text editor to use for editing attributes (when "Edit Attribute in Editor" submenu of the context menu is used). 9) Add "Set HTML Export Template" to the File Menu. Print/export in HTML format will use the template file if it is set. Please see HTML EXPORT TEMPLATE section of the man pages for details. 10) Add a new compiler option, _PS_SEVENBIT_DOUBLEBYTE_TEXT, to allow the generation of JIS PostScript files. Thanks to Kan Sasaki for the patch. 11) Add new X defaults, Tgif.MenuRowsBeforeScroll and Tgif.MenuColsBeforeScroll to control the size of scrollable menus. 12) Add a new X default, Tgif.UndoRedoRestoreDrawingMode, to restore the drawing mode just before an undo/redo operation. 13) Add a new X default, Tgif.ProducedBy, to specify a text editor to use for editing attributes. 14) Allows the default PostScript fonts to be replaced. Please see the information about Tgif.HasAlternateDefaultFonts and related X defaults in the X DEFAULTS section of the man pages for details. Thanks to Victor Wagner for pointing out the problem with the previous implementation. 15) Switch the shortcuts for Undo() and Animate(). Now Cntrl+z is Undo() and Alt+u is Animate(). Also switch the shortcuts for Redo() and ChangeDomain(). Now Cntrl+y is Redo() and Alt+* is ChangeDomain(). -----------------------> tgif-4.1.15 => tgif-4.1.16 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a seg fault bug in InsertRightSuperscript(). Thanks to Shiou-Jhy Ja for pointing out the problem. 2) Fix color bugs with a depth 1 display. Thanks to Martin Butkus for pointing out the problem. 3) Fix a bug with inserting super/subscript while edit text size is non-zero. Thanks to Heiko Scheit for pointing out the problem. 4) Fix some grid lines redraw problems. 5) Fix bugs with TrueColor display for various commands in the ImageProc Menu. 6) Fix a bug with font names when the "-print" commandline argument is used. Thanks to Ambrose Li for pointing out the problem. 7) Add screen capture under the File Menu. 8) Add a new X default, Tgif.DomainInIni, to allow domain info to be stored in ~/.Tgif/domain.ini. This enables all the menu items in the Domain Submenu of the File Menu. 9) Add a new LaTeX equation symbol files "eq4-epstool.sym" in the release. Thanks to LECORDIER Bertrand for the contribution. 10) Assign Alt+Cntrl+6 shortcut key for InsertRightSuperscript(). -----------------------> tgif-4.1.14 => tgif-4.1.15 <----------------------- Here's a short list of added features/bug fixes. 1) Fix problems with multipage files that have imported complex EPS files. Thanks to Dietrich Bartel for pointing out the problem. 2) Fix problems with moving the text cursor with the cursor keys when the text object has a large vertical spacing. Thanks to Tyson Tuttle for pointing out the problem. 3) Switch 2 pairs of the default shortcut keys. Now c is Copy() and v is Paste(). ChangeDomain() now becomes y and Push() becomes y. 4) Support point sizes in Tgif.FontSizes. 5) Change the default value for the Tgif.DontCondensePSFile X default to "true" due to the problem that many EPS files generated by other tools are not compatible with the previous default value of this X default. -----------------------> tgif-4.1.13 => tgif-4.1.14 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug that the initial import directory is the root directory on Solaris and some other machines. -----------------------> tgif-4.1.12 => tgif-4.1.13 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug that importing a XBM/XPM/GIF file changes the working directory. Thanks to Ralphe Neill for pointing out the problem. -----------------------> tgif-4.1.11 => tgif-4.1.12 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a seg fault bug with creating a rotated text. Thanks to Ralphe Neill for pointing out the problem. 2) Fix some grid lines redraw problems. -----------------------> tgif-4.1.10 => tgif-4.1.11 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug with importing EPS file that doesn't have a preview bitmap. Thanks to Marlene Busch for pointing out the problem. 2) To support LaTeX equations better, 3 new LaTeX equation symbol files "eq4.sym", "eq4-ps2epsi.sym", and "eq4-2x.sym" are included in this release. The only difference between "eq4.sym" and "eq4-ps2epsi.sym" is that "eq4.sym" uses "pstoepsi" and "eq4-ps2epsi.sym" uses ghostscript's "ps2epsi". The "eq4-2x.sym" uses the latest "pbmtoepsi" (which uses the new [ -scale value ] command line option) from "netpbm-20may1999" and the latest "pstoepsi" (which knows how to handle the [ -2x ] command line option) to run ghostscript at the 144dpi resolution for generating the preview bitmap. This makes LaTex equations looks good in both X and PS/EPS! Also, all 3 symbol files do not require "simple.tex" which was needed in the old LaTeX Equation package. To obtain the latest "pstoepsi" and "netpbm-20may1999", please visit . 3) Added ToggleEqAttrShown() under the Attribute Submenu of the Special Menu to toggle the "eq=" attribute for the LaTeX equation object. ToggleEqAttrShown() can also be accessed via the 7 keyboard shortcut. -----------------------> tgif-4.1.9 => tgif-4.1.10 <----------------------- Here's a short list of added features/bug fixes. 1) Fix the bug that after you import an EPS file, the current file name is changed to the name of the EPS file. Thanks to Geert Carron for pointing out the bug. 2) Fix a locale bug for HP-UX and fix Tgif.tmpl-hpux. 3) Set the default value of Tgif.UsePsAdobeString back to "false", and the default value of Tgif.MinimalEPS back to "true". Added support to handle compiler options _USE_PS_ADOBE_STRING and _MINIMAL_EPS. -----------------------> tgif-4.1.8 => tgif-4.1.9 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug in handling the importing of PS files generated by xv. Thanks to Michal Bulik for pointing out the problem. 2) Fix locale bugs. Thanks to Atsushi Shimizu for pointing out the problems. 3) Fix a bug with "-print -gif". Thanks to David Richerby for pointing out the problem. 4) Fix a bug in printing/exporting condensed PS/EPS files when the drawing contains certain EPS files (such as the ones generated by Adobe Illustrator). Thanks to Ambrose Li for the patch. 5) Fix a memory hogging bug when objects are moved. Thanks to Robert Schwebel for pointing out the problem and Jason White for looking into the problem. 6) Fix a bug in the File Open dialogbox that if SetDir is pressed when something is selected, a bad directory name is used. Thanks to Andreas Scherbaum for pointing out the problem. 7) Fix a bug so that the actual directory will be used when the user select "../" from a file dialogbox. Thanks to Andreas Scherbaum for pointing out the problem. 8) Fix bugs with panning using and zooming using . Thanks to Kyle Bateman for pointing out the problems. 9) When in the edit text mode, dragging , will now move the edit text (but not the object being edited). Thanks to Shinichiro Shiratake for pointing out the problem with editing text at the left or top edge of the paper. 10) Allow text objects to be broken into lines in BreakUpText(). 11) Set the default stretchable text mode to TRUE. 12) Set the default value of Tgif.UsePaperSizeStoredInFile to TRUE. 13) Set the default print-in-color mode to TRUE (when the "-print" command line option is not used). 14) Remove the concept of a current import directory. 15) New Tgif.tmpl-os2 for OS/2. Also fix some OS/2 dependent stuff. Thanks to Alexander Mai for the patch. 16) Add new X defaults, Tgif.PsRegMarksInTiledPageMode and Tgif.PsRegMarksGray to draw small crosshairs at the corners defining the clipping regions when printing/exporting PS/EPS files in the tiled page mode. 17) Add a new X default, Tgif.PSFontAliases to allow fake font names in Tgif.AdditionalFonts. Using this X default, different encodings of the same PS font can be used. Please see the ADDITIONAL FONTS section of the man pages for details. Thanks to Johan Vromans for many helpful suggestions. 18) Add the following new internal command: set_allow_interrupt() size_named_obj_absolute(,,) get_named_obj_bbox(,,,, ) -----------------------> tgif-4.1.7 => tgif-4.1.8 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a seg fault bug where tgif can't ever start on machines with small amount of virtual memory. This bug was introduced in tgif-4.1.5. The solution is to move some huge data structures inside the experimental #ifdef _TGIF_WB2 sections. Thanks to Dan McMahilll and Doug Robinson for pointing out the problem. 2) Fix bugs with undefined XFontSet on X11R4 Ultrix machines. Thanks to Jason White for pointing out the problem. -----------------------> tgif-4.1.6 => tgif-4.1.7 <----------------------- Here's a short list of added features/bug fixes. 1) Fix bugs in using the wrong export file name when the obj file is gzipped. -----------------------> tgif-4.1.5 => tgif-4.1.6 <----------------------- Here's a short list of added features/bug fixes. 1) Fix typos in "menuinfo.c" and "const.h". -----------------------> tgif-4.1.4 => tgif-4.1.5 <----------------------- Here's a short list of added features/bug fixes. 1) Fix bugs with breaking multiple text objects. Thanks to Kouya SHIMURA for the patch. 2) Add NLS support for menus (can be turned on by the _ENABLE_NLS compiler define). A new X default, Tgif.MenuFontSet is added to have menus in a native language. A new X default, Tgif.LocaleDir, is added to override the compile time locale directory specified in Tgif.tmpl. Japanese menu support is provided in the po/ja subdirectory. Thanks to Jun Nishii for the patch. Please see po/README for more information about the tgifintl release. 3) Fix bugs with overthespot for the xim input method. Thanks to Shoji Matsumoto for the patch. 4) Open/Save/Import gzipped obj files. Add Tgif.GUnZipCmd and Tgif.GZipCmd X defaults so that the user can override the default "gunzip -c" and "gzip -c" commands. 5) Add the following internal commands to make it a little easier for third party code to drive tgif. Please see the updated man pages for the details of these commands. "Testdrive.c" is updated to show how some of these internal commands can be used to create and manipulate objects from the test driver when Animate() is selected from the Return Submenu of the File Menu. select_top_obj() delete_selected_obj() set_selected_obj_rcb_radius() set_selected_text_vspace() set_selected_text_just() set_selected_text_font() set_selected_text_size() set_selected_text_underline() copy_string_to_cut_buffer() delete_attr_from_selected_obj() select_from_ini_section(,,<section>,<ini_path>) create_text_obj(<abs_x>,<abs_baseline_y>,<string>) create_box_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) create_corner_oval_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) create_center_oval_obj(<abs_x>,<abs_y>,<radius>) create_edge_oval_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) create_rcbox_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) create_arc_obj(<abs_x>,<abs_y>,<radius>,<dir>,<angle1>,<angle2>) create_first_vertex(<abs_x>,<abs_y>) create_next_vertex(<abs_x>,<abs_y>) create_poly_obj() create_polygon_obj() start_create_group_obj() create_group_obj() -----------------------> tgif-4.1.3 => tgif-4.1.4 <----------------------- Here's a short list of added features/bug fixes. 1) Fix bugs with truncated text objects in exporting to GIF files where that are rotated text objects. 2) Fix bugs with underlined text. Sometimes, a thick line is used to draw the underline. 3) Add PS support the following 8-bit ISO-Latin-1 characters: "onesuperior", "onequarter", "onehalf", and "threequarters". Thanks to Antonio Miguel Corbi Bellot <acorbi at altea.dlsi.ua.es> for pointing out the problem. -----------------------> tgif-4.1.2 => tgif-4.1.3 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug with opening files in a non-existent directory. Thanks to Andreas Scherbaum <ads at htl.de> for pointing out the problem. 2) Add the following internal commands: append_line_into_attr(<attr_name>,<string>) insert_line_into_attr(<attr_name>,<string>,<line_number>) clear_attr(<attr_name>) -----------------------> tgif-4.1.1 => tgif-4.1.2 <----------------------- Here's a short list of added features/bug fixes. 1) Fix another bug with the File Menu flashing. Thanks to Andrew Sapuntzakis <andrewsa at cc701.comm.mot.com> for pointing out the problem. 2) Fix a bug with CopyProperties(). Thanks to Kouya SHIMURA <kouya at flab.fujitsu.co.jp> for the patch. 3) Fix bugs when no file name and only a file extension is specified as an input file name. Thanks to Holger Huesing <H.Huesing at tu-bs.de> for the patch. 4) Fix a locale bug. Should not #include <local.h> if _NO_LOCALE_SUPPORT is defined. Thanks to Ralphe Neill <ran at oberon.sub.net.au> for pointing out the problem. 5) Fix a problem with exporting XPM/GIF files under certain TrueColor visuals of Hummingbird's eXceed server. The fix is to compute the color table for the exported XPM/GIF file from the pixels in the actual image for TrueColor visuals if the new X default, Tgif.UseImagePixelsForTrueColorExport, is set to true. Thanks to Jurgen Rusch <rusch at natlab.research.philips.com> for pointing out the problem. 6) Fix a bug with UpdateSymbols(). Thanks to sven wilhelmsson <sven.wilhelmsson at swipnet.se> for the patch. -----------------------> tgif-4.1 => tgif-4.1.1 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a locale bug for non-X11R6 systems. Thanks to Miroslav Flidr <flidr at ori.zcu.cz> for pointing out the problem. 2) Fix a bug that if Tgif.NoMenubar is set to "true", some popup menus in the choice window doesn't work. Thanks to Hiroto Kagotani <kagotani at in.it.okayama-u.ac.jp> for pointing out the problem. 3) Fix a bug with the File Menu flashing. Thanks to Andrew Sapuntzakis <andrewsa at cc701.comm.mot.com> for pointing out the problem. -----------------------> tgif-4.0.18 => tgif-4.1 <----------------------- Here's a short list of added features/bug fixes. 1) Strings in text objects can now be underlined. 2) Fix a seg fault bug which happens if the .mailcap file is not present when downloading an URL. Thanks to Frank Koeck <Frank.Koeck at mpi-hd.mpg.de> for the patch. 3) Fix various bugs with edit text size. Thanks to Jeremy H. Brown <jhbrown at ai.mit.edu> for pointing out the problems. 4) Fix a bad status for the rotate/shear mode. Thanks to Dave Bodenstab <imdave at mcs.net> for the patch. 5) Fix negative offsets bug in SetSlideShowWindowOffsets(). 6) Reduce repaint when editing text objects. 7) Add EditPageFileNames() under the StackedPage Menu so that each page in a multipage drawing can have its own print/export file name when PrintOneFilePerPage() is invoked. -----------------------> tgif-4.0.17 => tgif-4.0.18 <----------------------- Here's a short list of added features/bug fixes. 1) Fix problems with internal commands to work better with non-simple (multi-color, multi-font, etc.) attributes. Thanks to Daniel Ratton Figueiredo <ratton at land.ufrj.br> for pointing out the problem. 2) Fix problems with menus with wm2. Thanks to <dshawhan at nyx.net> for pointing out the problem. 3) Fix a bug that creating a new text object when the edit text size is non-zero results in the font size of the text object being 0. Thanks to Jeremy H. Brown <jhbrown at ai.mit.edu> for pointing out the problem. 4) Fix page number bugs (as specified in the MULTIPAGE DRAWING section of tgif's man pages) in slideshow mode. 5) Allows the moving of individual attributes directly in select mode. -----------------------> tgif-4.0.16 => tgif-4.0.17 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug in clicking over the font size button in the Choice Window. 2) By default, don't use EUC PS fonts in printing/export PS files that contains Japanese characters. Thanks to Shinta Sato <shinta at crimson.q.t.u-tokyo.ac.jp> for the patch. -----------------------> tgif-4.0.15 => tgif-4.0.16 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug with Tgif.RubberBandColor that it leaves ghost images during editing text objects when one moves the text cursor with cursor keys. Thanks to Shinichiro Shiratake <shinichiro.shiratake at toshiba.co.jp> for pointing out the problems. 2) Rename SetTextBackgroundColor() in the Text Submenu of the Edit Menu to SetTextFillPatternColor() since this operation only changes the fill pattern color of a text object and not the background color. Also, since text doesn't reallly have a background color (but only has a fill pattern color), the fix to set the default background color in 4.0 patchlevel 15 is invalid. Now the current color is used as the fill pattern color for new text objects. Thanks to Shinichiro Shiratake <shinichiro.shiratake at toshiba.co.jp> for pointing out the problems. -----------------------> tgif-4.0.14 => tgif-4.0.15 <----------------------- Here's a short list of added features/bug fixes. 1) Fix the default background color for new text objects. Used to be that the first color is used. Now the background color of tgif is used as the default background color for text objects. 2) Add SetAltEditTextBgColor(), SetAltEditTextHighlightColor() and UseAltEditTextBgColor() under the Properties Menu so that an alternate background and highlight color can be used when editing/creating text objects. Thanks to Ralphe Neill <ran at oberon.sub.net.au> for the suggestion. -----------------------> tgif-4.0.13 => tgif-4.0.14 <----------------------- Here's a short list of added features/bug fixes. 1) Add Tgif.LightGrayColor and Tgif.DarkGrayColor so that the user can change the colors for the backgrounds and shadows of butons, menus, etc. 2) Split the Attribute submenu under the Special Menu into Attribute and FileAttribute submenus. -----------------------> tgif-4.0.12 => tgif-4.0.13 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug with stretching grouped objects that contain text objects. Also fix a bug with the TransPattern Menu. Thanks to Shinichiro Shiratake <shinichiro.shiratake at toshiba.co.jp> for pointing out the problems. 2) Improve scrolling and zooming. Allow smooth and jump scrolling of the canvas window. 3) Add visible-grid control in slideshow mode. -----------------------> tgif-4.0.11 => tgif-4.0.12 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a hanging bug with executing the lauch() internal command. Thanks to Leana Golubchik <leana at cs.umd.edu> for pointing out the problem. -----------------------> tgif-4.0.10 => tgif-4.0.11 <----------------------- Here's a short list of added features/bug fixes. 1) Obsolete Tgif.StripEPSComments and Tgif.StripCondensedPSComments X defaults. Turns out that it's not always okay to strip PostScript comments (an Adobe Illustrator 6.0 generated EPS file may have data that looks like a PostScript comment). So these values should alway be false. -----------------------> tgif-4.0.9 => tgif-4.0.10 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a hanging bug when choosing a non-existant font. If you specify additional fonts with Tgif.AdditionalFonts and a font doesn't exist on your machine, tgif would normally bring up a message box saying that the font is not available. If you re-expose tgif's main window at this time, you may get a second message box and hangs tgif. Thanks to Helmut Jarausch <jarausch at IGPM.Rwth-Aachen.DE> for pointing out the problem. -----------------------> tgif-4.0.8 => tgif-4.0.9 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a compatibility bug. If "file.obj" is produced by tgif-3.x, text objects in PostScript file are not positioned correctly for "tgif -print -ps file.obj". This is not a problem if tgif is run interactively (without "-print"). Thanks to Dan McMahill <mcmahill at mtl.mit.edu> for pointing out the problem. 2) Fix bugs in flipping grouped objects with text subobjects horizontally and vertically. Thanks to Stephan Shuichi Haupt <stephan at bios.t.u-tokyo.ac.jp> for pointing out the problem. -----------------------> tgif-4.0.7 => tgif-4.0.8 <----------------------- Here's a short list of added features/bug fixes. 1) Fix formating bug in DistributeObjsDirect(). Thanks to TSUKADA Satoru <tsukada at tcd.hitachi.co.jp> for the patch. 2) Fix a bug in retriving URL's. Sometimes, the last byte of the file is not retrieved (which doesn't usualy cause any problems for text files because the last byte is a <LF>). -----------------------> tgif-4.0.6 => tgif-4.0.7 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a crashing bug which can happen when you paste complex text objects at the text cursor. Thanks to TSUKADA Satoru <tsukada at tcd.hitachi.co.jp> for the patch. 2) Fix a bug in inserting <CR> in an text object. Sometimes, the <End> key will bring you to the wrong place after inserting <CR>. Thanks to TSUKADA Satoru <tsukada at tcd.hitachi.co.jp> for the patch. 3) Fix a bunch of bugs related to the handling of double-byte fonts. Thanks to TSUKADA Satoru <tsukada at tcd.hitachi.co.jp> for the patch. 4) Use the portable locale ("C") by default. Thanks to Gregor Zych <zych at pool.informatik.rwth-aachen.de> for the suggestion. 5) Add a new drawing mode to create arcs such that the user can specify the endpoints of an arc while tgif determines automatically the center of the circle on which the arc lies. Thanks to Dick Wesseling <ftu at fi.uu.nl> for the patch and suggestion. 6) Add 3 alignment submenus and 1 distribution submenu. Using these submenus, one can specify alignments directly while aligning objects, aligning objects to grid, aligning objects to page, and distribute objects. Thanks to Dick Wesseling <ftu at fi.uu.nl> for the suggestion. 7) Update "tgif.pl" Prolog code to document the new tgif file format (file version 37). -----------------------> tgif-4.0.5 => tgif-4.0.6 <----------------------- Here's a short list of added features/bug fixes. 1) Fix divide by zero bugs which causes a seg fault on OSF1 (apparently, this doesn't crash on either Solaris or Linux). 2) Handles <ESC> correctly when creating objects. Thanks to Dick Wesseling <ftu at fi.uu.nl> for pointing out the problem. 3) Add the following files: Tgif.tmpl-osf1 Also moved some code around so tgif will compile under Digital UNIX (OSF1). -----------------------> tgif-4.0.4 => tgif-4.0.5 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a bug that generates bad a GIF file when running tgif with "-print -gif" commandline arguments. Thanks to Dick Wesseling <ftu at fi.uu.nl> for pointing out this problem. 2) Support more tgif file name extensions. Allow ".tgo" to also be a tgif object file name extension and ".tgs" to also be a tgif symbol file name extension. -----------------------> tgif-4.0.3 => tgif-4.0.4 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a seg fault bug when Tgif.ShowFontSizeInPoints is used. Thanks to Levente NOVAK <novak at jaguar.dote.hu> for pointing out this problem (and a few other problems). 2) Allow URL's while importing XPM/XBM/GIF and other files (to specify an URL, type '/' in the file dialogbox before typing the URL). 3) Fix problems reading files generated by tgif-2.13J and tgif-2.16J. Thanks to TSUKADA Satoru <tsukada at tcd.hitachi.co.jp> for the patch. 4) Use auto _DL_EXPORT_UNDERSCORE determination on NetBSD. Thanks to Dan McMahill <mcmahill at mtl.mit.edu> for the patch. 5) Accept "cm" and "in" specifications in SpecifyAnArc() and SizeToGivenWidthHeight(). Thanks to Levente NOVAK <novak at jaguar.dote.hu> for pointing out the problems. -----------------------> tgif-4.0.2 => tgif-4.0.3 <----------------------- Here's a short list of added features/bug fixes. 1) Fix crashing bugs with super/subscripts. Thanks to Levente NOVAK <novak at jaguar.dote.hu> for pointing out the problem. 2) Make tgif compile under HP-UX. On an HP 9000/735, /bin/cc does not like "#define extern extern" which appears in all the .e files. 3) Add "#include <locale.h>" if _NO_LOCALE_SUPPORT is defined in "convxim.c". Thanks to Ralphe Neill <ran at oberon.sub.net.au> for pointing out the problem. 4) Fix offset into the tiff image is incorrect when exporting in the TiffEPSI format. Thanks for Leana Golubchik <leana at cs.umd.edu> for pointing out the problem. 5) Handle window manager Delete's properly. Thanks to Dick Wesseling <ftu at fi.uu.nl> for the patch. 6) Don't repaint so much when pasting. Thanks to Francis Ngoh <fngoh at ti.com> for pointing out the problem. 7) Fix the following problems when dealing with inputing Japanese characters. a) The File Modified flag was not set when inputing Japanese characters. b) After switching to a single-byte font, tgif was still talking to the input method. c) If Tgif.PreeditType is set to overthespot, the kinput2's window position was wrong. Thanks to TAKAHASHI Hitoshi <thitoshi at ne.scphys.kyoto-u.ac.jp> pointing out the problems. 8) Add the following files: Tgif.tmpl-netbsd Tgif.tmpl-irix Tgif.tmpl-hpux -----------------------> tgif-4.0.1 => tgif-4.0.2 <----------------------- Here's a short list of added features/bug fixes. 1) Fix a ``Fatal Unexpected Error'' when the Edit Menu is pinned and certain text cursor movement is performed when a text object is being edited. 2) Tgif.BoldMsgFont by default will now use the value of Tgif.MsgFont if Tgif.MsgFont is specified. 3) RTLD_GLOBAL, used in "xprtfltr.c", is not defined on FreeeBSD. Thanks to Dan McMahill <mcmahill at mtl.mit.edu> for pointing out the problem. 4) Add the following files to the distribution: Tgif.tmpl-linux Tgif.tmpl-solaris Tgif.tmpl-freebsd -----------------------> tgif-4.0 => tgif-4.0.1 <----------------------- Here's a short list of added features/bug fixes. 1) Tgif.MinimalEPS was not behaving and documented properly. Thanks to Koppa Vesa <Vesa.Koppa at nmp.nokia.com> for pointing out the problems. 2) Fix a few missing items in make.common and Makefile.noimake. Thanks to Koppa Vesa <Vesa.Koppa at nmp.nokia.com> for pointing out the problems. 3) Fix a few minor compiler warnings. for pointing out the problems. 4) Fix a few missing defines for certain machines. Thanks to Francis Ngoh <fngoh at ti.com> for pointing out the problems. 1) Support the _TGIF_WB2 compile option. Attempting to phase out _TGIF_WB. -----------------------> tgif-4.0 <----------------------- I'm happy to announce the availability of version 4.0 of tgif. This release is an alpha release. So it's probably a good idea not to use it on anything too serious. Please send bug reports to bill.cheng at acm.org as soon as you see bugs so I can release patches to fix major bugs. Unfortunately, I will be out of e-mail reach until 12/31, so I won't be able to respond until probably the next year. I apologize for that. Although version 4.0 is backward-compatible with old versions of tgif, the file format is not forward-compatible (you won't be able to read files generated by this version of tgif with an older versions of tgif). The tgif-4.0 source code is available at the following places for anonymous ftp (binaries are not available yet at the time of this release, please check the tgif current release and download page for availability): ftp://bourbon.cs.umd.edu/pub/tgif/tgif-4.0.tar.gz (primary) ftp://ftp.cs.ucla.edu/pub/tgif/tgif-4.0.tar.gz (1,098.938 bytes - running 'sum tgif-4.0.tar.gz' should get: 16385 1074) Here's a short list of the main features added in version 4.0. 1) 3-D look. 2) Allow a text object to have multiple font faces, sizes, styles, and colors. 3) Allow superscripts and subscripts in text objects. 4) Support double-byte fonts and their input methods such as kinput2 for Japanese and xcin and chinput for Chinese. 5) Slide show mode for multipage drawings using left and right cursor keys to advance pages. 6) Import/export GIF animation - requires gifsicle <URL:http://www.lcdf.org/gifsicle/> version 1.9.1 or newer. 7) Export PDF files - requires ps2pdf from the ghostscript 5.x distribution <URL:http://www.cs.wisc.edu/~ghost/>. 8) Copy/paste object properties (such as color, linewidth, etc.) ABOUT TGIF: Tgif is an Xlib-based 2-D drawing tool. It's also a hyper-graphics (or hyper-structured-graphics) browser on the World-Wide-Web. Its hyper-text home page is <URL:http://bourbon.cs.umd.edu:8001/tgif/> and its hyper-graphics home page is <URL:http://bourbon.cs.umd.edu:8001/tgif/index.obj>. (Please note that the Content-type of a tgif file sent by the httpd at bourbon.cs.umd.edu:8001 is applications/x-tgif.) Tgif is free-of-charge, but please read the Copyright file in the distribution (or select Copyright from the Help Menu in tgif) for restrictions. (Please note that tgif is NEITHER an html viewer NOR an html editor. It is also NOT directly related to GIF nor Transparent GIF.) TGIF RESOURCES: Home Page: http://bourbon.cs.umd.edu:8001/tgif/ FAQ: http://bourbon.cs.umd.edu:8001/tgif/faq/ Current Release & Download: http://bourbon.cs.umd.edu:8001/tgif/current.html Join to Mailing List: kragen-tgif-subscribe at kragen.dnaco.net Mailing List: kragen-tgif at kragen.dnaco.net Bug Reports Send To: bill.cheng at acm.org Happy New Year! /* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/HISTORY,v 1.114 2011/06/28 02:12:04 william Exp $ */ �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/attr.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000237665�11602233310�014123� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/attr.c,v 1.15 2011/05/16 16:21:56 william Exp $ */ #define _INCLUDE_FROM_ATTR_C_ #include "tgifdefs.h" #include "attr.e" #include "auxtext.e" #include "button.e" #include "choice.e" #include "choose.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "font.e" #include "grid.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "names.e" #include "obj.e" #include "pattern.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "stk.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "wb.e" int dropObsIconAttrWhenUpdate=FALSE; int maxAttrGroups=0; AttrGroupInfo **gAttrGroupInfo=NULL; EditAttrInfo *gpEditAttrInEditorAttrInfo=NULL; static struct AttrRec *topAttr=NULL, *botAttr=NULL; void LinkInAttr(PrevPtr, NextPtr, AttrPtr) struct AttrRec *PrevPtr, *NextPtr, *AttrPtr; /* add AttrPtr between PrevPtr and NextPtr */ { AttrPtr->prev = PrevPtr; AttrPtr->next = NextPtr; if (PrevPtr == NULL) { topAttr = AttrPtr; } else { PrevPtr->next = AttrPtr; } if (NextPtr == NULL) { botAttr = AttrPtr; } else { NextPtr->prev = AttrPtr; } } void FreeAttr(AttrPtr) struct AttrRec *AttrPtr; /* This routine only frees the attribute record, not */ /* the text record, which must be freed explicitly. */ { if (AttrPtr->attr_name.s != NULL) free(AttrPtr->attr_name.s); if (AttrPtr->attr_value.s != NULL) free(AttrPtr->attr_value.s); free(AttrPtr); } void UnlinkAttr(AttrPtr) struct AttrRec *AttrPtr; { struct ObjRec *own_ptr; struct AttrRec **top_attr_ad; struct AttrRec **bot_attr_ad; own_ptr = AttrPtr->owner; top_attr_ad = &(own_ptr->fattr); bot_attr_ad = &(own_ptr->lattr); if (*top_attr_ad == AttrPtr) { *top_attr_ad = AttrPtr->next; } else { AttrPtr->prev->next = AttrPtr->next; } if (*bot_attr_ad == AttrPtr) { *bot_attr_ad = AttrPtr->prev; } else { AttrPtr->next->prev = AttrPtr->prev; } } void UpdAttrOwner(first_attr, owner_obj) struct AttrRec *first_attr; struct ObjRec *owner_obj; { while (first_attr != NULL) { first_attr->owner = owner_obj; first_attr = first_attr->next; } } static char *FindEqual(s) char *s; { while (*s != '=' && *s != '\0') s++; return ((*s == '=') ? (s) : (char*)NULL); } void ParseAttrStr(buf, name, name_sz, value, value_sz) char *buf, *name, *value; int name_sz, value_sz; { char *eq_ptr=NULL, *str_ptr=NULL, *psz=NULL; if ((eq_ptr=FindEqual(buf)) != NULL) { eq_ptr++; if (name != NULL) { int index=0; psz = name; str_ptr = buf; for (;;) { *psz = *str_ptr; psz++; str_ptr++; index++; if (str_ptr == eq_ptr) { break; } else if (index >= name_sz-2) { *psz++ = '='; break; } } *psz = '\0'; } if (value != NULL) { int index=0; str_ptr = eq_ptr; psz = value; do { *psz = *str_ptr; psz++; str_ptr++; index++; } while (*str_ptr != '\0' && index < value_sz-1); *psz = '\0'; } } else { if (name != NULL) *name = '\0'; if (value != NULL) UtilStrCpyN(value, value_sz, buf); } } void UpdateAttr(TextPtr, AttrPtr) struct TextRec *TextPtr; struct AttrRec *AttrPtr; /* This routine updates the name and value in the AttrRec */ /* and its ObjRec after an attribute was edited. */ { if (AttrPtr->nameshown) { char *s=GetTextPtrFirstStrSeg(TextPtr)->dyn_str.s; int buf_sz=(strlen(s)<<1)+5; char *name=(char*)malloc(buf_sz), *value=(char*)malloc(buf_sz); if (name == NULL || value == NULL) FailAllocMessage(); *name = *value = '\0'; ParseAttrStr(GetTextPtrFirstStrSeg(TextPtr)->dyn_str.s, name, buf_sz, value, buf_sz); DynStrSet(&AttrPtr->attr_value, value); DynStrSet(&AttrPtr->attr_name, name); strcat(name, value); DynStrSet(&GetTextPtrFirstStrSeg(TextPtr)->dyn_str, name); free(name); free(value); } else { char *value=GetTextPtrFirstStrSeg(TextPtr)->dyn_str.s; DynStrSet(&AttrPtr->attr_value, value); DynStrSet(&GetTextPtrFirstStrSeg(TextPtr)->dyn_str, value); } UpdTextBBox(AttrPtr->obj); AdjObjCache(AttrPtr->obj); } void DrawAttrs(Win, XOff, YOff, AttrPtr) Window Win; int XOff, YOff; struct AttrRec *AttrPtr; { struct AttrRec *ptr; for (ptr=AttrPtr; ptr != NULL; ptr=ptr->next) { if (ptr->shown) { if (!editingText) { /* UpdAttr(ptr); */ /* ALERT - not sure if this is needed. */ } DrawTextObj(Win, XOff, YOff, ptr->obj); } } } void MoveAttrs(AttrPtr, Dx, Dy) int Dx, Dy; struct AttrRec *AttrPtr; { struct AttrRec *attr_ptr; for (attr_ptr=AttrPtr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { MoveObj(attr_ptr->obj, Dx, Dy); } } void DelAllAttrs(AttrPtr) struct AttrRec *AttrPtr; { struct AttrRec *ptr, *next_attr; for (ptr=AttrPtr; ptr != NULL; ptr=next_attr) { next_attr = ptr->next; FreeObj(ptr->obj); FreeAttr(ptr); } } struct AttrRec *AddAttrByNameAndValue(ObjPtr, AttrName, AttrValue) struct ObjRec *ObjPtr; char *AttrName, *AttrValue; { struct ObjRec *text_obj_ptr=NULL; struct TextRec *text_ptr=NULL; struct AttrRec *attr_ptr=NULL; StrSegInfo *pStrSeg=NULL; MiniLinesInfo *minilines=NULL; char *buf=(char*)malloc(strlen(AttrName)+strlen(AttrValue)+1); if (buf == NULL) FailAllocMessage(); sprintf(buf, "%s%s", AttrName, AttrValue); text_obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); text_ptr = (struct TextRec *)malloc(sizeof(struct TextRec)); attr_ptr = (struct AttrRec *)malloc(sizeof(struct AttrRec)); if (text_obj_ptr == NULL || text_ptr == NULL || attr_ptr == NULL) { FailAllocMessage(); } memset(text_obj_ptr, 0, sizeof(struct ObjRec)); memset(text_ptr, 0, sizeof(struct TextRec)); memset(attr_ptr, 0, sizeof(struct AttrRec)); minilines = (&text_ptr->minilines); CreateMiniLineFromString("", &minilines->first, &minilines->last); minilines->first->owner_minilines = minilines; CopyCurInfoIntoTextPtr(text_obj_ptr, text_ptr); text_ptr->lines = 1; text_ptr->cached_zoom = 0; text_ptr->cached_zoomed = FALSE; text_ptr->cached_bitmap = None; pStrSeg = GetTextPtrFirstStrSeg(text_ptr); DynStrSet(&pStrSeg->dyn_str, buf); pStrSeg->font = curFont; pStrSeg->style = curStyle; pStrSeg->sz_unit = GetCurSzUnit(); pStrSeg->underline_on = curUnderlineOn; pStrSeg->overline_on = curOverlineOn; pStrSeg->asc = canvasFontAsc; pStrSeg->des = canvasFontDes; pStrSeg->direction = canvasFontDirection; pStrSeg->dontreencode = canvasFontDontReencode; pStrSeg->double_byte = canvasFontDoubleByte; pStrSeg->double_byte_mod_bytes = canvasFontDoubleByteModBytes; pStrSeg->double_byte_vertical = canvasFontDoubleByteVertical; text_obj_ptr->x = ObjPtr->obbox.ltx; text_obj_ptr->y = ObjPtr->obbox.rby; text_obj_ptr->type = OBJ_TEXT; text_obj_ptr->color = ObjPtr->color; memcpy(text_obj_ptr->color_str, ObjPtr->color_str, sizeof(text_obj_ptr->color_str)); text_obj_ptr->dirty = FALSE; text_obj_ptr->id = objId++; text_obj_ptr->rotation = 0; text_obj_ptr->locked = FALSE; text_obj_ptr->ctm = NULL; text_obj_ptr->detail.t = text_ptr; UpdTextBBox(text_obj_ptr); attr_ptr->shown = FALSE; attr_ptr->nameshown = TRUE; attr_ptr->inherited = FALSE; attr_ptr->obj = text_obj_ptr; attr_ptr->owner = ObjPtr; DynStrSet(&attr_ptr->attr_name, AttrName); DynStrSet(&attr_ptr->attr_value, AttrValue); text_ptr->attr = attr_ptr; attr_ptr->prev = NULL; attr_ptr->next = ObjPtr->fattr; if (ObjPtr->fattr == NULL) { ObjPtr->lattr = attr_ptr; } else { ObjPtr->fattr->prev = attr_ptr; } ObjPtr->fattr = attr_ptr; AdjObjBBox(ObjPtr); return attr_ptr; } static struct AttrRec *NewAttr(OwnerObjPtr, ObjPtr, Inherited) struct ObjRec *ObjPtr; struct ObjRec *OwnerObjPtr; short Inherited; { struct AttrRec *attr_ptr; attr_ptr = (struct AttrRec *)malloc(sizeof(struct AttrRec)); if (attr_ptr == NULL) FailAllocMessage(); memset(attr_ptr, 0, sizeof(struct AttrRec)); attr_ptr->shown = TRUE; attr_ptr->nameshown = TRUE; attr_ptr->inherited = Inherited; attr_ptr->obj = ObjPtr; attr_ptr->next= attr_ptr->prev = NULL; attr_ptr->owner = OwnerObjPtr; DynStrSet(&attr_ptr->attr_name, ""); DynStrSet(&attr_ptr->attr_value, ""); ObjPtr->detail.t->attr = attr_ptr; return attr_ptr; } static void DupAnAttr(FromAttrPtr, ToAttrPtr) struct AttrRec *FromAttrPtr, *ToAttrPtr; { struct ObjRec *text_obj_ptr; text_obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (text_obj_ptr == NULL) FailAllocMessage(); memset(text_obj_ptr, 0, sizeof(struct ObjRec)); DupObjBasics(FromAttrPtr->obj, text_obj_ptr); DupTextObj(FromAttrPtr->obj->detail.t, FromAttrPtr->obj, text_obj_ptr); DynStrCpy(&ToAttrPtr->attr_name, &FromAttrPtr->attr_name); DynStrCpy(&ToAttrPtr->attr_value, &FromAttrPtr->attr_value); ToAttrPtr->shown = FromAttrPtr->shown; ToAttrPtr->nameshown = FromAttrPtr->nameshown; ToAttrPtr->inherited = FromAttrPtr->inherited; ToAttrPtr->obj = text_obj_ptr; ToAttrPtr->next= ToAttrPtr->prev = NULL; text_obj_ptr->detail.t->attr = ToAttrPtr; } void DupAttrs(FromObjPtr, ToObjPtr) struct ObjRec *FromObjPtr, *ToObjPtr; { struct AttrRec *to_attr_ptr, *from_attr_ptr; topAttr = botAttr = NULL; from_attr_ptr = FromObjPtr->lattr; for ( ; from_attr_ptr != NULL; from_attr_ptr=from_attr_ptr->prev) { to_attr_ptr = (struct AttrRec *)malloc(sizeof(struct AttrRec)); if (to_attr_ptr == NULL) FailAllocMessage(); memset(to_attr_ptr, 0, sizeof(struct AttrRec)); to_attr_ptr->owner = ToObjPtr; DupAnAttr(from_attr_ptr, to_attr_ptr); LinkInAttr((struct AttrRec *)NULL, topAttr, to_attr_ptr); } ToObjPtr->fattr = topAttr; ToObjPtr->lattr = botAttr; } static void AddAttr(ObjPtr, TextObjPtr) struct ObjRec *ObjPtr, *TextObjPtr; { struct AttrRec *attr_ptr=NULL; struct TextRec *text_ptr=TextObjPtr->detail.t; topAttr = ObjPtr->fattr; botAttr = ObjPtr->lattr; UnlinkObj(TextObjPtr); TextObjPtr->next = TextObjPtr->prev = NULL; attr_ptr = NewAttr(ObjPtr, TextObjPtr, FALSE); UpdateAttr(text_ptr, attr_ptr); LinkInAttr((struct AttrRec *)NULL, topAttr, attr_ptr); ObjPtr->fattr = topAttr; ObjPtr->lattr = botAttr; } void AddAttrs() { struct ObjRec *owner_ptr=NULL; struct SelRec *sel_ptr; int text_count=0, sel_ltx, sel_lty, sel_rbx, sel_rby; int locked_text_count=0; if (topSel == NULL) { MsgBox(TgLoadString(STID_SELECT_AT_LEAST_ONE_TEXT), TOOL_NAME, INFO_MB); return; } for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { switch (sel_ptr->obj->type) { case OBJ_TEXT: text_count++; break; default: if (owner_ptr != NULL) { MsgBox(TgLoadString(STID_MORE_THAN_ONE_NON_TEXT), TOOL_NAME, INFO_MB); return; } owner_ptr = sel_ptr->obj; break; } } if (text_count == 0) { MsgBox(TgLoadString(STID_NO_TEXT_SELECTED_ADD_ATTRS), TOOL_NAME, INFO_MB); return; } if (owner_ptr == NULL) { MsgBox(TgLoadString(STID_NO_NON_TEXT_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); sel_ltx = selLtX; sel_lty = selLtY; sel_rbx = selRbX; sel_rby = selRbY; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { if (sel_ptr->obj->type == OBJ_TEXT) { if (sel_ptr->obj->locked) { locked_text_count++; sel_ptr->obj->locked = FALSE; } AddAttr(owner_ptr, sel_ptr->obj); } } RemoveAllSel(); UnlinkObj(owner_ptr); AddObj(NULL, topObj, owner_ptr); topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->obj = owner_ptr; topSel->prev = NULL; botSel->next = NULL; AdjObjBBox(owner_ptr); UpdSelBBox(); RecordCmd(CMD_MANY_TO_ONE, NULL, topSel, botSel, 1); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; if (locked_text_count==0) { Msg(TgLoadString(STID_TEXT_ATTACHED)); } else { Msg(TgLoadString(STID_TEXT_UNLOCKED_AND_ATTACHED)); } } static void SaveAttr(FP, AttrPtr) FILE *FP; struct AttrRec *AttrPtr; { struct TextRec *text_ptr=AttrPtr->obj->detail.t; if (fprintf(FP, "attr(\"") == EOF) writeFileFailed = TRUE; if (GetTextPtrFirstStrSeg(text_ptr)->double_byte) { SaveDoubleByteString(FP, AttrPtr->attr_name.s); } else { SaveString(FP, AttrPtr->attr_name.s); } if (fprintf(FP, "\", \"") == EOF) writeFileFailed = TRUE; if (GetTextPtrFirstStrSeg(text_ptr)->double_byte) { SaveDoubleByteString(FP, AttrPtr->attr_value.s); } else { SaveString(FP, AttrPtr->attr_value.s); } if (fprintf(FP, "\", %1d, %1d, %1d,\n", AttrPtr->shown, AttrPtr->nameshown, AttrPtr->inherited) == EOF) { writeFileFailed = TRUE; } SaveTextObj(FP, AttrPtr->obj); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } void SaveAttrs(FP, BotAttrPtr) FILE *FP; struct AttrRec *BotAttrPtr; { struct AttrRec *ptr; if (fprintf(FP, "[\n") == EOF) writeFileFailed = TRUE; for (ptr=BotAttrPtr; ptr != NULL; ptr=ptr->prev) { SaveAttr(FP, ptr); if (ptr->prev != NULL) { if (fprintf(FP, ",\n") == EOF) { writeFileFailed = TRUE; } } } if (BotAttrPtr == NULL) { if (fprintf(FP, "]") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, "\n]") == EOF) writeFileFailed = TRUE; } } char *ReadAttrString(Str) char *Str; { char *s; for (s=Str; *s != '\0'; s++) { if (*s == '"') { if (s[1] == '"') { s++; } else { break; } } else if (*s == '\\') { s++; } } if (*s == '"') s++; return s; } static int FreeBufAndReturn(line, rc) char *line; int rc; { if (line != NULL) free(line); return rc; } int ReadAttr(FP, AttrPtr) FILE *FP; struct AttrRec **AttrPtr; { struct ObjRec *TextObj; char *s, *line; char *name, *value; int len, shown, nameshown, inherited; if ((line=UtilGetALine(FP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanFileName, scanLineNum, "ReadAttr()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } scanLineNum++; if (*line == ']') return FreeBufAndReturn(line, FALSE); *AttrPtr = NULL; len = strlen(line); name = (char *)malloc((len+1)*sizeof(char)); if (name == NULL) FailAllocMessage(); s = FindChar((int)'"', line); strcpy(name, s); s = ReadAttrString(s); s = FindChar((int)',', s); value = (char *)malloc((len+1)*sizeof(char)); if (value == NULL) FailAllocMessage(); strcpy(value, FindChar((int)'"', s)); s = ReadAttrString(value); s = FindChar((int)',', s); InitScan(s, "\t\n ,"); if (GETINT("attribute", shown, "shown") == INVALID || GETINT("attribute", nameshown, "name shown") == INVALID || GETINT("attribute", inherited, "inherited") == INVALID) { free(name); free(value); return FreeBufAndReturn(line, FALSE); } *AttrPtr = (struct AttrRec *)malloc(sizeof(struct AttrRec)); if (*AttrPtr == NULL) FailAllocMessage(); memset(*AttrPtr, 0, sizeof(struct AttrRec)); s = ReadString(name); *(--s) = '\0'; DynStrSet(&((*AttrPtr)->attr_name), name); s = ReadString(value); *(--s) = '\0'; DynStrSet(&((*AttrPtr)->attr_value), value); free(name); free(value); (*AttrPtr)->shown = shown; (*AttrPtr)->nameshown = nameshown; (*AttrPtr)->inherited = inherited; if (ReadObj(FP, &TextObj) == FALSE) { free(*AttrPtr); *AttrPtr = NULL; return FreeBufAndReturn(line, FALSE); } TextObj->detail.t->attr = *AttrPtr; (*AttrPtr)->obj = TextObj; return FreeBufAndReturn(line, TRUE); } struct ObjRec *FindTopLevelObjWithType(type_str) char *type_str; { struct ObjRec *obj_ptr=NULL; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { struct AttrRec *attr_ptr=NULL; for (attr_ptr=obj_ptr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (strcmp(attr_ptr->attr_name.s, "type=") == 0 && strcmp(attr_ptr->attr_value.s, type_str) == 0) { return obj_ptr; } } } return NULL; } static int ObjMightChangeForShowAndUpdAttrNames(ObjPtr) struct ObjRec *ObjPtr; { struct AttrRec *attr_ptr; if ((attr_ptr=ObjPtr->fattr) != NULL) { for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { if (!(attr_ptr->nameshown)) { return TRUE; } } } return FALSE; } static void UpdateFirstTextStringWithAttrNameAndValue(ObjPtr, AttrPtr) struct ObjRec *ObjPtr; struct AttrRec *AttrPtr; { char *buf=(char*)malloc(AttrPtr->attr_name.sz+AttrPtr->attr_value.sz); /* one extra char allocated, no big deal */ if (buf == NULL) FailAllocMessage(); sprintf(buf, "%s%s", AttrPtr->attr_name.s, AttrPtr->attr_value.s); DynStrSet(&GetTextObjFirstStrSeg(ObjPtr)->dyn_str, buf); free(buf); } static int DoShowAndUpdAttrNames(ObjPtr, Force) struct ObjRec *ObjPtr; int Force; /* Force will force attribute name to be shown whether the attribute */ /* is inherited or not. */ { struct AttrRec *attr_ptr=ObjPtr->fattr; int picture_changed=FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (!(attr_ptr->nameshown) && (Force || !(attr_ptr->inherited))) { UpdateFirstTextStringWithAttrNameAndValue(attr_ptr->obj, attr_ptr); attr_ptr->nameshown = TRUE; UpdTextBBox(attr_ptr->obj); if (attr_ptr->shown) { picture_changed = TRUE; if (attr_ptr->obj->detail.t->cached_bitmap != None) { XFreePixmap(mainDisplay, attr_ptr->obj->detail.t->cached_bitmap); } attr_ptr->obj->detail.t->cached_zoom = 0; attr_ptr->obj->detail.t->cached_bitmap = None; } } } AdjObjBBox(ObjPtr); return picture_changed; } static int ShowAndUpdAttrNames() /* returns TRUE if any attribute names are updated */ /* This routine concatinate the 'name' and 's' first of every */ /* attribute of the selected object and assign that to the */ /* first line of the text object the attribute pointer points to. */ { struct SelRec *sel_ptr; int picture_changed=FALSE; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (ObjMightChangeForShowAndUpdAttrNames(sel_ptr->obj)) { PrepareToReplaceAnObj(sel_ptr->obj); picture_changed = DoShowAndUpdAttrNames(sel_ptr->obj, TRUE); RecordReplaceAnObj(sel_ptr->obj); } } return picture_changed; } void ShowAllAttrNames() { HighLightReverse(); StartCompositeCmd(); if (ShowAndUpdAttrNames()) { UpdSelBBox(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } EndCompositeCmd(); HighLightForward(); } static int ShowAndUpdAttrs() /* returns TRUE if any attribute was not shown before */ { struct SelRec *sel_ptr; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; int picture_changed=FALSE; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; attr_ptr = obj_ptr->fattr; if (attr_ptr != NULL) { int obj_changed=FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (!attr_ptr->shown) { obj_changed = TRUE; break; } } if (obj_changed) { PrepareToReplaceAnObj(obj_ptr); for (attr_ptr=obj_ptr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (!attr_ptr->shown) { attr_ptr->shown = TRUE; } } picture_changed = TRUE; AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); } } } return picture_changed; } void ShowAllAttrs() { HighLightReverse(); StartCompositeCmd(); if (ShowAndUpdAttrs()) { UpdSelBBox(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } EndCompositeCmd(); HighLightForward(); } static int HideAndUpdAttrs() /* returns TRUE if any attribute was shown */ { struct SelRec *sel_ptr; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; int picture_changed=FALSE; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; attr_ptr = obj_ptr->fattr; if (attr_ptr != NULL) { int obj_changed= FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { obj_changed = TRUE; break; } } if (obj_changed) { PrepareToReplaceAnObj(obj_ptr); for (attr_ptr=obj_ptr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { attr_ptr->shown = FALSE; } } picture_changed = TRUE; AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); } } } return picture_changed; } void HideAllAttrs() { int sel_ltx, sel_lty, sel_rbx, sel_rby; sel_ltx = selLtX; sel_lty = selLtY; sel_rbx = selRbX; sel_rby = selRbY; HighLightReverse(); StartCompositeCmd(); if (HideAndUpdAttrs()) { UpdSelBBox(); RedrawAnArea(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } EndCompositeCmd(); HighLightForward(); } static int HideAndUpdAttrNames() /* returns TRUE if any attribute names are updated */ /* For all the first line of the selected object's attributes, */ /* this routine change them to the 's' field of the attribute. */ { struct SelRec *sel_ptr; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; int picture_changed=FALSE; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; attr_ptr = obj_ptr->fattr; if (attr_ptr != NULL) { int obj_change=FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->nameshown && *(attr_ptr->attr_name.s) != '\0') { obj_change = TRUE; break; } } if (obj_change) { PrepareToReplaceAnObj(obj_ptr); for (attr_ptr=obj_ptr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->nameshown && *(attr_ptr->attr_name.s) != '\0') { struct TextRec *text_ptr=attr_ptr->obj->detail.t; attr_ptr->nameshown = FALSE; DynStrCpy( &GetTextPtrFirstStrSeg(text_ptr)->dyn_str, &attr_ptr->attr_value); UpdTextBBox(attr_ptr->obj); if (attr_ptr->shown) { picture_changed = TRUE; if (attr_ptr->obj->detail.t->cached_bitmap != None) { XFreePixmap(mainDisplay, attr_ptr->obj->detail.t->cached_bitmap); } attr_ptr->obj->detail.t->cached_zoom = 0; attr_ptr->obj->detail.t->cached_bitmap = None; } } } AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); } } } return picture_changed; } void HideAllAttrNames() { int sel_ltx, sel_lty, sel_rbx, sel_rby; sel_ltx = selLtX; sel_lty = selLtY; sel_rbx = selRbX; sel_rby = selRbY; HighLightReverse(); StartCompositeCmd(); if (HideAndUpdAttrNames()) { UpdSelBBox(); RedrawAnArea(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } EndCompositeCmd(); HighLightForward(); } void DetachGroupAttrs(ObjPtr, TopSelPtr, BotSelPtr) struct ObjRec *ObjPtr; struct SelRec ** TopSelPtr, **BotSelPtr; { struct AttrRec *attr_ptr, *next_attr; struct SelRec *new_sel_ptr; for (attr_ptr=ObjPtr->fattr; attr_ptr!=NULL; attr_ptr=next_attr) { next_attr = attr_ptr->next; if (!(attr_ptr->nameshown)) { UpdateFirstTextStringWithAttrNameAndValue(attr_ptr->obj, attr_ptr); UpdTextBBox(attr_ptr->obj); } attr_ptr->obj->detail.t->attr = NULL; attr_ptr->obj->prev = NULL; attr_ptr->obj->next = ObjPtr->detail.r->first; if (attr_ptr->obj->next == NULL) { ObjPtr->detail.r->last = attr_ptr->obj; } else { attr_ptr->obj->next->prev = attr_ptr->obj; } ObjPtr->detail.r->first = attr_ptr->obj; new_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (new_sel_ptr == NULL) FailAllocMessage(); new_sel_ptr->obj = attr_ptr->obj; new_sel_ptr->prev = NULL; new_sel_ptr->next = *TopSelPtr; if (new_sel_ptr->next == NULL) { *BotSelPtr = new_sel_ptr; } else { (*TopSelPtr)->prev = new_sel_ptr; } *TopSelPtr = new_sel_ptr; FreeAttr(attr_ptr); } } void DetachAllObjAttrs(obj_ptr, TopSelPtr, BotSelPtr) struct ObjRec *obj_ptr; struct SelRec **TopSelPtr, **BotSelPtr; { struct AttrRec *attr_ptr, *prev_attr; DoShowAndUpdAttrNames(obj_ptr, FALSE); (*TopSelPtr) = (*BotSelPtr) = (struct SelRec *)malloc(sizeof(struct SelRec)); if (*TopSelPtr == NULL) FailAllocMessage(); (*TopSelPtr)->next = (*TopSelPtr)->prev = NULL; (*TopSelPtr)->obj = obj_ptr; topAttr = botAttr = NULL; for (attr_ptr=obj_ptr->lattr; attr_ptr!=NULL; attr_ptr=prev_attr) { struct SelRec *tmp_sel_ptr; prev_attr = attr_ptr->prev; tmp_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (tmp_sel_ptr == NULL) FailAllocMessage(); tmp_sel_ptr->prev = NULL; tmp_sel_ptr->next = (*TopSelPtr); (*TopSelPtr)->prev = tmp_sel_ptr; (*TopSelPtr) = tmp_sel_ptr; tmp_sel_ptr->obj = attr_ptr->obj; attr_ptr->obj->detail.t->attr = NULL; AddObj(obj_ptr->prev, obj_ptr, attr_ptr->obj); FreeAttr(attr_ptr); } obj_ptr->fattr = obj_ptr->lattr = NULL; } void DetachAttrs() { struct SelRec *sel_ptr, *new_sel_ptr; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr, *next_attr; int picture_changed=FALSE, name_changed=FALSE; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; attr_ptr = obj_ptr->fattr; if (attr_ptr != NULL) { int obj_change=FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (!attr_ptr->inherited) { obj_change = TRUE; break; } } if (obj_change) { struct SelRec *tmp_top_sel, *tmp_bot_sel; struct SelRec *tmp_sel_ptr, *next_sel; int count; PrepareToReplaceAnObj(obj_ptr); if (DoShowAndUpdAttrNames(obj_ptr, FALSE)) name_changed = TRUE; tmp_top_sel = tmp_bot_sel = (struct SelRec *)malloc( sizeof(struct SelRec)); if (tmp_top_sel == NULL) FailAllocMessage(); tmp_top_sel->next = tmp_top_sel->prev = NULL; tmp_top_sel->obj = obj_ptr; count = 1; topAttr = botAttr = NULL; for (attr_ptr=obj_ptr->fattr; attr_ptr!=NULL; attr_ptr=next_attr) { next_attr = attr_ptr->next; if (attr_ptr->inherited && (obj_ptr->type == OBJ_ICON || obj_ptr->type == OBJ_PIN)) { LinkInAttr((struct AttrRec *)NULL, topAttr, attr_ptr); continue; } picture_changed = TRUE; tmp_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (tmp_sel_ptr == NULL) FailAllocMessage(); tmp_sel_ptr->next = tmp_bot_sel; tmp_sel_ptr->obj = attr_ptr->obj; if (tmp_top_sel == tmp_bot_sel) { tmp_sel_ptr->prev = NULL; tmp_top_sel->prev = tmp_sel_ptr; tmp_top_sel = tmp_sel_ptr; } else { tmp_sel_ptr->prev = tmp_bot_sel->prev; tmp_bot_sel->prev->next = tmp_sel_ptr; tmp_bot_sel->prev = tmp_sel_ptr; } count++; attr_ptr->obj->detail.t->attr = NULL; AddObj(obj_ptr->prev, obj_ptr, attr_ptr->obj); new_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (new_sel_ptr == NULL) FailAllocMessage(); new_sel_ptr->obj = obj_ptr->prev; AddSel(sel_ptr->prev, sel_ptr, new_sel_ptr); FreeAttr(attr_ptr); } obj_ptr->fattr = topAttr; obj_ptr->lattr = botAttr; AdjObjBBox(obj_ptr); RecordCmd(CMD_ONE_TO_MANY, NULL, tmp_top_sel, tmp_bot_sel, count); for (tmp_sel_ptr=tmp_top_sel; tmp_sel_ptr!=NULL; tmp_sel_ptr=next_sel) { next_sel = tmp_sel_ptr->next; free(tmp_sel_ptr); } } } } EndCompositeCmd(); UpdSelBBox(); if (picture_changed || name_changed) { RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } HighLightForward(); } void UpdAttr(AttrPtr) struct AttrRec *AttrPtr; /* Update the text object's string value associated with AttrPtr */ { if (AttrPtr->nameshown) { UpdateFirstTextStringWithAttrNameAndValue(AttrPtr->obj, AttrPtr); } else { struct TextRec *text_ptr=AttrPtr->obj->detail.t; DynStrCpy(&GetTextPtrFirstStrSeg(text_ptr)->dyn_str, &AttrPtr->attr_value); } UpdTextBBox(AttrPtr->obj); } static int MoveOneAttr(ObjPtr, AttrPtr) struct ObjRec *ObjPtr; struct AttrRec *AttrPtr; { struct ObjRec *text_obj_ptr; int x, y, grid_x, grid_y, dx, dy, placing=TRUE; int ltx, lty, rbx, rby; int orig_x, orig_y, grid_orig_x, grid_orig_y; char buf[80], x_buf[80], y_buf[80]; XEvent input, ev; text_obj_ptr = AttrPtr->obj; Msg(TgLoadString(STID_MOVE_ONE_ATTR_MOUSE_MSG)); SetMouseStatus(TgLoadString(STID_SHOW_MOVE_ATTR), TgLoadString(STID_TOGGLE_NAME_SHOWN), TgLoadString(STID_HIDE_ATTR)); orig_x = OFFSET_X(text_obj_ptr->x); orig_y = OFFSET_Y(text_obj_ptr->y); GridXY(orig_x, orig_y, &grid_orig_x, &grid_orig_y); ltx = OFFSET_X(text_obj_ptr->bbox.ltx); lty = OFFSET_Y(text_obj_ptr->bbox.lty); rbx = OFFSET_X(text_obj_ptr->bbox.rbx)+1; rby = OFFSET_Y(text_obj_ptr->bbox.rby)+1; if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonPressMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } XWarpPointer(mainDisplay, None, drawWindow, 0, 0, 0, 0, orig_x, orig_y); dx = dy = 0; grid_x = grid_orig_x; grid_y = grid_orig_y; SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); PixelToMeasurementUnit(x_buf, 0); PixelToMeasurementUnit(y_buf, 0); sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); StartShowMeasureCursor(ltx, lty-(defaultFontHeight<<1), buf, TRUE); while (placing) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { PixelToMeasurementUnit(x_buf, ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, ABS_SIZE(dy)); sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); ShowMeasureCursor(ltx+dx, lty-(defaultFontHeight<<1)+dy, buf, TRUE); SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); ExposeEventHandler(&input, TRUE); SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); PixelToMeasurementUnit(x_buf, ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, ABS_SIZE(dy)); sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); ShowMeasureCursor(ltx+dx, lty-(defaultFontHeight<<1)+dy, buf, TRUE); } else if (input.type == MotionNotify) { x = input.xmotion.x; y = input.xmotion.y; GridXY(x, y, &grid_x, &grid_y); if (grid_x != grid_orig_x+dx || grid_y != grid_orig_y+dy) { PixelToMeasurementUnit(x_buf, ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, ABS_SIZE(dy)); sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); ShowMeasureCursor(ltx+dx, lty-(defaultFontHeight<<1)+dy, buf, TRUE); SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); dx = grid_x - grid_orig_x; dy = grid_y - grid_orig_y; SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); PixelToMeasurementUnit(x_buf, ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, ABS_SIZE(dy)); sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); ShowMeasureCursor(ltx+dx, lty-(defaultFontHeight<<1)+dy, buf, TRUE); MarkRulers(grid_x, grid_y); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } else if (input.type == ButtonPress) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); placing = FALSE; SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); PixelToMeasurementUnit(x_buf, ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, ABS_SIZE(dy)); sprintf(buf, "dx=%s\ndy=%s", x_buf, y_buf); EndShowMeasureCursor(ltx+dx, lty-(defaultFontHeight<<1)+dy, buf, TRUE); Msg(""); SetMouseStatus("", "", ""); switch (input.xbutton.button) { case Button1: if (dx != 0 || dy != 0) { if (ObjPtr->locked) { MsgBox(TgLoadString(STID_CANNOT_MOVE_ATTR_IF_LOCKED), TOOL_NAME, INFO_MB); return FALSE; } HighLightReverse(); PrepareToReplaceAnObj(ObjPtr); AttrPtr->shown = TRUE; MoveObj(text_obj_ptr, ABS_SIZE(dx), ABS_SIZE(dy)); AdjObjBBox(ObjPtr); RecordReplaceAnObj(ObjPtr); return TRUE; } else if (!(AttrPtr->shown)) { HighLightReverse(); PrepareToReplaceAnObj(ObjPtr); AttrPtr->shown = TRUE; AdjObjBBox(ObjPtr); RecordReplaceAnObj(ObjPtr); return TRUE; } return FALSE; case Button2: if (*(AttrPtr->attr_name.s) != '\0') { PrepareToReplaceAnObj(ObjPtr); } if (!(AttrPtr->nameshown && *(AttrPtr->attr_name.s)=='\0')) { AttrPtr->nameshown = !AttrPtr->nameshown; } UpdAttr(AttrPtr); if (AttrPtr->shown) { HighLightReverse(); AdjObjCache(ObjPtr); AdjObjBBox(ObjPtr); if (*(AttrPtr->attr_name.s) != '\0') { RecordReplaceAnObj(ObjPtr); } return TRUE; } if (*(AttrPtr->attr_name.s) != '\0') RecordReplaceAnObj(ObjPtr); return FALSE; case Button3: if (AttrPtr->shown) { HighLightReverse(); PrepareToReplaceAnObj(ObjPtr); AttrPtr->shown = FALSE; AdjObjBBox(ObjPtr); RecordReplaceAnObj(ObjPtr); return TRUE; } return FALSE; default: break; } } } return FALSE; } static int ChangeAttrJust(ObjPtr, AttrPtr) struct ObjRec *ObjPtr; struct AttrRec *AttrPtr; { struct ObjRec *text_obj_ptr; int x, y, grid_x, grid_y, dx, dy, placing=TRUE; int ltx, lty, rbx, rby; int orig_x, orig_y, grid_orig_x, grid_orig_y; int old_just, new_just=0; XEvent input, ev; text_obj_ptr = AttrPtr->obj; Msg(TgLoadString(STID_CHANGE_ATTR_JUST_MOUSE_MSG)); SetMouseStatus(TgLoadString(STID_LEFT_JUSTIFY), TgLoadString(STID_CENTER_JUSTIFY), TgLoadString(STID_RIGHT_JUSTIFY)); orig_x = OFFSET_X(text_obj_ptr->x); orig_y = OFFSET_Y(text_obj_ptr->y); GridXY(orig_x, orig_y, &grid_orig_x, &grid_orig_y); ltx = OFFSET_X(text_obj_ptr->bbox.ltx); lty = OFFSET_Y(text_obj_ptr->bbox.lty); rbx = OFFSET_X(text_obj_ptr->bbox.rbx)+1; rby = OFFSET_Y(text_obj_ptr->bbox.rby)+1; if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonPressMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } XWarpPointer(mainDisplay, None, drawWindow, 0, 0, 0, 0, orig_x, orig_y); dx = dy = 0; grid_x = grid_orig_x; grid_y = grid_orig_y; SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); StartShowMeasureCursor(ltx, lty, NULL, TRUE); while (placing) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); ExposeEventHandler(&input, TRUE); SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); } else if (input.type == MotionNotify) { x = input.xmotion.x; y = input.xmotion.y; GridXY(x, y, &grid_x, &grid_y); if (grid_x != grid_orig_x+dx || grid_y != grid_orig_y+dy) { SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); dx = grid_x - grid_orig_x; dy = grid_y - grid_orig_y; SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); MarkRulers(grid_x, grid_y); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } else if (input.type == ButtonPress) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); placing = FALSE; SelBox(drawWindow, revDefaultGC, ltx+dx, lty+dy, rbx+dx, rby+dy); EndShowMeasureCursor(ltx+dx, lty+dy, NULL, TRUE); Msg(""); SetMouseStatus("", "", ""); old_just = text_obj_ptr->detail.t->minilines.just; switch (input.xbutton.button) { case Button1: new_just = JUST_L; break; case Button2: new_just = JUST_C; break; case Button3: new_just = JUST_R; break; } if (old_just != new_just) { HighLightReverse(); PrepareToReplaceAnObj(ObjPtr); text_obj_ptr->detail.t->minilines.just = new_just; /* UpdAttr(AttrPtr); */ /* ALERT - not sure if this is needed. */ AdjObjCache(ObjPtr); UpdTextBBox(text_obj_ptr); AdjObjBBox(ObjPtr); RecordReplaceAnObj(ObjPtr); return TRUE; } } } return FALSE; } TgMenu *CreateAttrMenu(parent_menu, x, y, num_items, menu_strings, status_strings, pixels) TgMenu *parent_menu; int x, y, num_items, *pixels; char **menu_strings, **status_strings; { int i=0; TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memset(&stMenuInfo, 0, sizeof(TgMenuInfo)); stMenuInfo.type = TGMUTYPE_TEXT; stMenuInfo.items = (TgMenuItemInfo*)malloc( (num_items+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (num_items+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < num_items; item_info++, i++) { if (menu_strings[i] == TGMUITEM_SEPARATOR) { item_info->menu_str = TGMUITEM_SEPARATOR; } else { item_info->menu_str = UtilStrDup(menu_strings[i]); if (item_info->menu_str == NULL) FailAllocMessage(); } if (status_strings != NULL && status_strings[i] != NULL) { item_info->status_str = UtilStrDup(status_strings[i]); if (item_info->status_str == NULL) FailAllocMessage(); } item_info->submenu_info = NULL; item_info->cmdid = INVALID; } stMenuInfo.items[num_items].cmdid = INVALID; if (num_items >= menuRowsBeforeScroll) { stMenuInfo.type |= TGMUTYPE_CANSCROLL; } /* * Since these are real attribute names and values, no translation is needed. */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < num_items; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (num_items+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { TgMenuItem stMenuItem; menu->track_menubar = FALSE; memset(&stMenuItem, 0, sizeof(TgMenuItem)); for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menu->menuitems[i]); if (pixels != NULL) { stMenuItem.multicolor_pixel = pixels[i]; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_MULTICOLOR, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } } menu_item->menu_str_allocated = TRUE; } } return menu; } void FreeEditAttrInfo(pEditAttrInfo) EditAttrInfo *pEditAttrInfo; /* pEditAttrInfo will also be freed before returning */ { int i=0, num_attrs=0, *fore_colors=NULL, *attr_indices=NULL; char **attr_names=NULL, **attr_values=NULL, **attr_strings=NULL; char **status_strings=NULL; if (pEditAttrInfo == NULL) return; num_attrs = pEditAttrInfo->num_attrs; fore_colors = pEditAttrInfo->fore_colors; attr_indices = pEditAttrInfo->attr_indices; attr_names = pEditAttrInfo->attr_names; attr_values = pEditAttrInfo->attr_values; attr_strings = pEditAttrInfo->attr_strings; status_strings = pEditAttrInfo->status_strings; if (pEditAttrInfo->fore_colors != NULL) free(pEditAttrInfo->fore_colors); if (pEditAttrInfo->attr_indices != NULL) free(pEditAttrInfo->attr_indices); for (i=0; i < num_attrs; i++) { if (attr_names != NULL) UtilFree(attr_names[i]); if (attr_values != NULL) UtilFree(attr_values[i]); if (attr_strings != NULL) { if (attr_strings[i] != TGMUITEM_SEPARATOR) UtilFree(attr_strings[i]); } if (status_strings != NULL) UtilFree(status_strings[i]); } if (attr_names != NULL) free(attr_names); if (attr_values != NULL) free(attr_values); if (attr_strings != NULL) free(attr_strings); if (status_strings != NULL) free(status_strings); free(pEditAttrInfo); } int HasEditAttrsInContextMenu(obj_ptr, pp_name_attr) struct ObjRec *obj_ptr; struct AttrRec **pp_name_attr; { struct AttrRec *attr_ptr=NULL; if (pp_name_attr != NULL) *pp_name_attr = NULL; for (attr_ptr=obj_ptr->lattr; attr_ptr!=NULL; attr_ptr=attr_ptr->prev) { if (strcmp(attr_ptr->attr_name.s, "edit_attrs_in_context_menu=") == 0) { if (pp_name_attr != NULL) *pp_name_attr = attr_ptr; return TRUE; } } return FALSE; } void FreeRestrictedAttrNames(ppsz_restricted, num_restricted) char **ppsz_restricted; int num_restricted; { if (ppsz_restricted != NULL) { int i=0; for (i=0; i < num_restricted; i++) { if (ppsz_restricted[i] != NULL) { UtilFree(ppsz_restricted[i]); } } free(ppsz_restricted); } } void GetRestrictedAttrNames(restricted_attr_obj, pppsz_restricted, pn_num_restricted) struct ObjRec *restricted_attr_obj; char ***pppsz_restricted; int *pn_num_restricted; { MiniLinesInfo *minilines=(&restricted_attr_obj->detail.t->minilines); MiniLineInfo *miniline=minilines->first->next; char **ppsz_restricted=NULL; int num_restricted=0, index=0; if (pppsz_restricted != NULL) (*pppsz_restricted) = NULL; if (pn_num_restricted != NULL) (*pn_num_restricted) = 0; if (miniline == NULL) return; for ( ; miniline != NULL; miniline=miniline->next, num_restricted++) { } ppsz_restricted = (char**)malloc(num_restricted*sizeof(char*)); if (ppsz_restricted == NULL) FailAllocMessage(); memset(ppsz_restricted, 0, num_restricted*sizeof(char*)); miniline = minilines->first->next; for ( ; miniline != NULL; miniline=miniline->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=ConvertMiniLineToString(miniline, &need_to_free_tmp_buf); if (tmp_buf != NULL) { UtilTrimBlanks(tmp_buf); if (*tmp_buf == '\0') { num_restricted--; } else { int len=strlen(tmp_buf)+2; /* extra char for '=' */ ppsz_restricted[index] = (char*)malloc((len+1)*sizeof(char)); if (ppsz_restricted[index] == NULL) FailAllocMessage(); sprintf(ppsz_restricted[index], "%s=", tmp_buf); index++; } if (need_to_free_tmp_buf) UtilFree(tmp_buf); } else { num_restricted--; } if (num_restricted <= 0) break; } if (num_restricted <= 0) { free(pppsz_restricted); } else { if (pppsz_restricted != NULL) (*pppsz_restricted) = ppsz_restricted; if (pn_num_restricted != NULL) (*pn_num_restricted) = num_restricted; } } void GetAttrGroupAttrNames(restricted_attr_obj, group_index, pppsz_restricted, pn_num_restricted) struct ObjRec *restricted_attr_obj; int group_index, *pn_num_restricted; char ***pppsz_restricted; { char **ppsz_restricted=NULL, **attr_name_array=NULL; int num_attrs_in_attr_group=0, i=0; num_attrs_in_attr_group = gAttrGroupInfo[group_index]->num_attrs; attr_name_array = gAttrGroupInfo[group_index]->attr_name; if (pppsz_restricted != NULL) (*pppsz_restricted) = NULL; if (pn_num_restricted != NULL) (*pn_num_restricted) = 0; ppsz_restricted = (char**)malloc(num_attrs_in_attr_group*sizeof(char*)); if (ppsz_restricted == NULL) FailAllocMessage(); memset(ppsz_restricted, 0, num_attrs_in_attr_group*sizeof(char*)); for (i=0; i < num_attrs_in_attr_group; i++) { int len=strlen(attr_name_array[i])+2; /* extra char for '=' */ ppsz_restricted[i] = (char*)malloc((len+1)*sizeof(char)); if (ppsz_restricted[i] == NULL) FailAllocMessage(); sprintf(ppsz_restricted[i], "%s=", attr_name_array[i]); } if (pppsz_restricted != NULL) (*pppsz_restricted) = ppsz_restricted; if (pn_num_restricted != NULL) { (*pn_num_restricted) = num_attrs_in_attr_group; } } int IsRestrictedAttr(attr_name, ppsz_restricted, num_restricted) char *attr_name, **ppsz_restricted; int num_restricted; { int i=0; for (i=0; i < num_restricted; i++) { if (strcmp(attr_name, ppsz_restricted[i]) == 0) { return TRUE; } } return FALSE; } EditAttrInfo *CreateEditAttrInfo(obj_ptr) struct ObjRec *obj_ptr; { int i=0, num_attrs=0, *fore_colors=NULL, *pixel_ptr=NULL, restricted=FALSE; int num_restricted=0, num_created=0, *attr_indices=NULL; struct AttrRec *attr_ptr=NULL, *attr_ptr1=NULL, *restricted_attr=NULL; EditAttrInfo *pEditAttrInfo=NULL; char **attr_names=NULL, **attr_values=NULL, **attr_strings=NULL; char **status_strings=NULL, **ppsz_restricted=NULL; pEditAttrInfo = (EditAttrInfo*)malloc(sizeof(EditAttrInfo)); if (pEditAttrInfo == NULL) FailAllocMessage(); memset(pEditAttrInfo, 0, sizeof(EditAttrInfo)); attr_ptr1 = attr_ptr = obj_ptr->fattr; for ( ; attr_ptr1 != NULL; attr_ptr1=attr_ptr1->next, num_attrs++) { } if (num_attrs == 0) { free(pEditAttrInfo); return NULL; } restricted = HasEditAttrsInContextMenu(obj_ptr, &restricted_attr); if (restricted) { GetRestrictedAttrNames(restricted_attr->obj, &ppsz_restricted, &num_restricted); if (ppsz_restricted == NULL || num_restricted <= 0) { free(pEditAttrInfo); return NULL; } } attr_names = (char**)malloc(num_attrs*sizeof(char*)); attr_values = (char**)malloc(num_attrs*sizeof(char*)); attr_strings = (char**)malloc(num_attrs*sizeof(char*)); status_strings = (char**)malloc(num_attrs*sizeof(char*)); fore_colors = pixel_ptr = (int*)malloc(num_attrs*sizeof(int)); attr_indices = (int*)malloc(num_attrs*sizeof(int)); if (attr_names == NULL || attr_values == NULL || attr_strings == NULL || status_strings == NULL || fore_colors == NULL || attr_indices == NULL) { FailAllocMessage(); } attr_ptr1 = attr_ptr; for (i=0; i < num_attrs; i++, attr_ptr1=attr_ptr1->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=NULL; MiniLinesInfo *minilines=(&attr_ptr1->obj->detail.t->minilines); tmp_buf = ConvertAttrNameFirstMiniLineToString(attr_ptr1, &need_to_free_tmp_buf); if (restricted) { if (!IsRestrictedAttr(attr_ptr1->attr_name.s, ppsz_restricted, num_restricted)) { if (need_to_free_tmp_buf) UtilFree(tmp_buf); continue; } } attr_names[num_created] = UtilStrDup(attr_ptr1->attr_name.s); attr_values[num_created] = UtilStrDup(attr_ptr1->attr_value.s); attr_strings[num_created] = UtilStrDup(tmp_buf); sprintf(gszMsgBox, TgLoadCachedString(CSTID_EDIT_ATTR_IN_EDITOR), tmp_buf); status_strings[num_created] = UtilStrDup(gszMsgBox); if (attr_names[num_created] == NULL || attr_values[num_created] == NULL || attr_strings[num_created] == NULL || status_strings[num_created] == NULL) { FailAllocMessage(); } pixel_ptr[num_created] = colorPixels[minilines->first->first_block->seg->color]; attr_indices[num_created] = i; if (need_to_free_tmp_buf) UtilFree(tmp_buf); num_created++; } pEditAttrInfo->num_attrs = num_created; pEditAttrInfo->fore_colors = fore_colors; pEditAttrInfo->attr_indices = attr_indices; pEditAttrInfo->attr_names = attr_names; pEditAttrInfo->attr_values = attr_values; pEditAttrInfo->attr_strings = attr_strings; pEditAttrInfo->status_strings = status_strings; FreeRestrictedAttrNames(ppsz_restricted, num_restricted); return pEditAttrInfo; } EditAttrInfo *CreateEditAttrGroupInfo(obj_ptr) struct ObjRec *obj_ptr; { int i=0, num_attrs=maxAttrGroups, *fore_colors=NULL; EditAttrInfo *pEditAttrInfo=NULL; char **attr_strings=NULL, **status_strings=NULL; if (num_attrs == 0) { return NULL; } pEditAttrInfo = (EditAttrInfo*)malloc(sizeof(EditAttrInfo)); if (pEditAttrInfo == NULL) FailAllocMessage(); memset(pEditAttrInfo, 0, sizeof(EditAttrInfo)); /* * For this function, we do not need to call HasEditAttrsInContextMenu() * because the "edit_attrs_in_context_menu=" attribute is only for the * "Edit Attribute In Editor" submenu and *not* for the * "Edit Attribute Group In Editor" submenu. */ attr_strings = (char**)malloc(num_attrs*sizeof(char*)); status_strings = (char**)malloc(num_attrs*sizeof(char*)); fore_colors = (int*)malloc(num_attrs*sizeof(int)); if (attr_strings == NULL || status_strings == NULL || fore_colors == NULL) { FailAllocMessage(); } for (i=0; i < num_attrs; i++) { attr_strings[i] = UtilStrDup(gAttrGroupInfo[i]->group_name); sprintf(gszMsgBox, TgLoadCachedString(CSTID_EDIT_ATTR_GROUP_IN_EDITOR), gAttrGroupInfo[i]->group_name, gAttrGroupInfo[i]->displayed_names); status_strings[i] = UtilStrDup(gszMsgBox); if (attr_strings[i] == NULL || status_strings[i] == NULL) { FailAllocMessage(); } fore_colors[i] = myFgPixel; } pEditAttrInfo->num_attrs = num_attrs; pEditAttrInfo->attr_strings = attr_strings; pEditAttrInfo->status_strings = status_strings; pEditAttrInfo->fore_colors = fore_colors; return pEditAttrInfo; } void MoveAttr() { struct ObjRec *obj_ptr=NULL; struct AttrRec *attr_ptr=NULL, *attr_ptr1=NULL; int num_attrs=0, i, index=INVALID, x, y; int sel_ltx, sel_lty, sel_rbx, sel_rby; int *fore_colors=NULL, *pixel_ptr=NULL; char **attr_strings=NULL; unsigned int button; if (topSel != botSel || topSel == NULL) { MsgBox(TgLoadString(STID_SELECT_ONLY_ONE_OBJ), TOOL_NAME, INFO_MB); return; } obj_ptr = topSel->obj; attr_ptr1 = attr_ptr = obj_ptr->fattr; for ( ; attr_ptr1 != NULL; attr_ptr1=attr_ptr1->next, num_attrs++) { } if (num_attrs == 0) { MsgBox(TgLoadString(STID_SELECT_HAS_NO_ATTR), TOOL_NAME, INFO_MB); return; } attr_strings = (char**)malloc(num_attrs*sizeof(char*)); fore_colors = pixel_ptr = (int*)malloc(num_attrs*sizeof(int)); if (attr_strings == NULL || fore_colors == NULL) { FailAllocMessage(); } attr_ptr1 = attr_ptr; for (i=0; i < num_attrs; i++, attr_ptr1=attr_ptr1->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=NULL; MiniLinesInfo *minilines=(&attr_ptr1->obj->detail.t->minilines); tmp_buf = ConvertAttrNameFirstMiniLineToString(attr_ptr1, &need_to_free_tmp_buf); if ((attr_strings[i]=UtilStrDup(tmp_buf)) == NULL) FailAllocMessage(); *pixel_ptr++ = colorPixels[minilines->first->first_block->seg->color]; if (need_to_free_tmp_buf) UtilFree(tmp_buf); } Msg(TgLoadString(STID_DRAG_LEFT_BTN_TO_SEE_ATTR)); SetMouseStatus(TgLoadString(STID_SHOW_MOVE_ATTR), TgLoadString(STID_CHANGE_ATTR_JUST), TgLoadCachedString(CSTID_PARANED_NONE)); button = CornerLoop(&x, &y); activeMenu = INVALID; if (button == Button1 || button == Button2) { TgMenu *menu=CreateAttrMenu(NULL, x, y, num_attrs, attr_strings, NULL, fore_colors); if (menu != NULL) { index = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } free(fore_colors); } if (index != INVALID) { attr_ptr1 = attr_ptr; for (i=0; i < index; i++, attr_ptr1=attr_ptr1->next) { } sel_ltx = selLtX; sel_lty = selLtY; sel_rbx = selRbX; sel_rby = selRbY; if (button == Button1) { if (MoveOneAttr(obj_ptr, attr_ptr1)) { /* HighLightReverse() is expected to be called */ UpdSelBBox(); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); HighLightForward(); } } else if (button == Button2) { if (ChangeAttrJust(obj_ptr, attr_ptr1)) { /* HighLightReverse() is expected to be called */ UpdSelBBox(); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); HighLightForward(); } } } for (i=0; i < num_attrs; i++) UtilFree(attr_strings[i]); free(attr_strings); justDupped = FALSE; } void CopyAndUpdateAttrs(ToObjPtr, FromObjPtr) struct ObjRec *ToObjPtr, *FromObjPtr; { struct AttrRec *to_attr_ptr, *from_attr_ptr; int confirm_status=MB_ID_CANCEL; topAttr = botAttr = NULL; from_attr_ptr = FromObjPtr->fattr; for ( ; from_attr_ptr != NULL; from_attr_ptr=from_attr_ptr->next) { to_attr_ptr = ToObjPtr->fattr; for ( ; to_attr_ptr != NULL; to_attr_ptr=to_attr_ptr->next) { if (from_attr_ptr->obj->color==to_attr_ptr->obj->color && strcmp(from_attr_ptr->attr_name.s, to_attr_ptr->attr_name.s)==0) { if (*(from_attr_ptr->attr_value.s) != '\0') { DynStrCpy(&to_attr_ptr->attr_value, &from_attr_ptr->attr_value); UpdAttr(to_attr_ptr); } break; } } if (to_attr_ptr == NULL) { /* cannot find the same attribute in the new one */ confirm_status = MB_ID_NO; if (from_attr_ptr->inherited) { char msg[MAXSTRING]; /* obsolete attribute? */ confirm_status = (dropObsIconAttrWhenUpdate) ? MB_ID_YES : MB_ID_CANCEL; if (*from_attr_ptr->attr_name.s == '\0') { sprintf(msg, TgLoadString(STID_IS_ATTR_OBSOLETE_FOR_ICON_YNC), from_attr_ptr->attr_value.s, FromObjPtr->detail.r->s); } else { sprintf(msg, TgLoadString(STID_IS_ATTR_OBSOLETE_FOR_ICON_YNC), from_attr_ptr->attr_name.s, FromObjPtr->detail.r->s); } while (confirm_status == MB_ID_CANCEL) { confirm_status = MsgBox(msg, TOOL_NAME, YN_MB); if (confirm_status == MB_ID_CANCEL) { MsgBox(TgLoadCachedString(CSTID_CANCEL_NOT_AVAIL), TOOL_NAME, INFO_MB); } } } if (confirm_status == MB_ID_NO) { /* new attribute */ to_attr_ptr = (struct AttrRec *)malloc(sizeof(struct AttrRec)); if (to_attr_ptr == NULL) FailAllocMessage(); memset(to_attr_ptr, 0, sizeof(struct AttrRec)); to_attr_ptr->owner = ToObjPtr; DupAnAttr(from_attr_ptr, to_attr_ptr); LinkInAttr((struct AttrRec *)NULL, topAttr, to_attr_ptr); } } else { to_attr_ptr->shown = from_attr_ptr->shown; to_attr_ptr->nameshown = from_attr_ptr->nameshown; } } if (topAttr != NULL) { topAttr->prev = NULL; botAttr->next = ToObjPtr->fattr; if (ToObjPtr->fattr != NULL) ToObjPtr->fattr->prev = botAttr; ToObjPtr->fattr = topAttr; if (ToObjPtr->lattr == NULL) ToObjPtr->lattr = botAttr; } AdjObjBBox(ToObjPtr); } void ToggleNamedAttrShown(attr_name) char *attr_name; { char *paren_ptr; struct AttrRec *attr_ptr; int ltx, lty, rbx, rby; if (topSel != botSel || topSel == NULL) { MsgBox(TgLoadString(STID_SELECT_ONLY_ONE_OBJ), TOOL_NAME, INFO_MB); return; } if ((paren_ptr=strchr(attr_name, ')')) == NULL) { MsgBox(TgLoadString(STID_BAD_FORMAT_IN_SHORTCUT_SPEC), TOOL_NAME, INFO_MB); return; } *paren_ptr = '\0'; if ((attr_ptr=FindAttrWithName(topSel->obj, attr_name, NULL)) == NULL) { char msg[MAXSTRING+1]; sprintf(msg, TgLoadString(STID_CANNOT_FIND_NAMED_ATTR), attr_name); MsgBox(msg, TOOL_NAME, INFO_MB); return; } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); PrepareToReplaceAnObj(topSel->obj); attr_ptr->shown = !attr_ptr->shown; AdjObjBBox(topSel->obj); RecordReplaceAnObj(topSel->obj); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); HighLightForward(); } void ToggleEqAttrShown() { char buf[80]; strcpy(buf, "eq=)"); ToggleNamedAttrShown(buf); } void AddFileAttrs() { struct SelRec *sel_ptr; int ltx, lty, rbx, rby; if (gstWBInfo.do_whiteboard) { /* * Now it's allowed. * * MsgBox(TgLoadString(STID_ATTACH_FILE_ATTRS_IN_WB), TOOL_NAME, INFO_MB); * return; */ } if (topSel == NULL) { MsgBox(TgLoadString(STID_SELECT_AT_LEAST_ONE_TEXT), TOOL_NAME, INFO_MB); return; } for (sel_ptr=topSel; sel_ptr!=NULL; sel_ptr=sel_ptr->next) { if (sel_ptr->obj->type != OBJ_TEXT) { MsgBox(TgLoadString(STID_CANNOT_ATTACH_NON_TEXT_OBJ), TOOL_NAME, INFO_MB); return; } } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); AddObj(NULL, topObj, tgifObj); AddNewSelObj(topObj); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); for (sel_ptr=topSel->next; sel_ptr!=NULL; sel_ptr=sel_ptr->next) { AddAttr(topObj, sel_ptr->obj); } RemoveAllSel(); AddNewSelObj(topObj); UpdSelBBox(); recordCmdIncludeTgifObj = TRUE; RecordCmd(CMD_MANY_TO_ONE, NULL, topSel, botSel, 1); recordCmdIncludeTgifObj = FALSE; RemoveAllSel(); UnlinkObj(topObj); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; } void DetachFileAttrs() { struct AttrRec *attr_ptr, *next_attr; struct SelRec *sel_ptr; if (gstWBInfo.do_whiteboard) { /* * Now it's allowed. * * MsgBox(TgLoadString(STID_DETACH_FILE_ATTRS_IN_WB), TOOL_NAME, INFO_MB); * return; */ } if (tgifObj->fattr == NULL) { MsgBox(TgLoadString(STID_FILE_CONTAINS_NO_ATTRS), TOOL_NAME, INFO_MB); return; } MakeQuiescent(); AddObj(NULL, topObj, tgifObj); AddNewSelObj(topObj); PrepareToReplaceAnObj(topObj); for (attr_ptr=topObj->fattr; attr_ptr!=NULL; attr_ptr=next_attr) { next_attr = attr_ptr->next; sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (sel_ptr == NULL) FailAllocMessage(); sel_ptr->obj = attr_ptr->obj; AddSel(topSel, topSel->next, sel_ptr); attr_ptr->obj->detail.t->attr = NULL; AddObj(topObj, topObj->next, attr_ptr->obj); FreeAttr(attr_ptr); } topObj->fattr = topObj->lattr = NULL; recordCmdIncludeTgifObj = TRUE; RecordCmd(CMD_ONE_TO_MANY, NULL, topSel, botSel, numObjSelected); recordCmdIncludeTgifObj = FALSE; UnlinkObj(topObj); FreeTopSel(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; SetCurChoice(curChoiceBeforeMakeQuiescent); } #define SHOWN_COL 0 #define NSHOWN_COL 1 static DspList *fileAttrNameDspPtr=NULL; static DspList *FileAttrNameListing(ObjPtr, pn_entries, pCheckArray) /* * If pCheckArray != NULL, this routine sets pCheckArray->num_cols, * pCheckArray->num_rows and pCheckArray->value. */ struct ObjRec *ObjPtr; int *pn_entries; struct CheckArrayRec *pCheckArray; { int i, num_rows=0; DspList *dsp_ptr; struct AttrRec *attr_ptr; for (num_rows=0, attr_ptr=ObjPtr->fattr; attr_ptr!=NULL; attr_ptr=attr_ptr->next, num_rows++) { } if (pCheckArray != NULL) { pCheckArray->num_cols = 2; pCheckArray->num_rows = num_rows; pCheckArray->value = (int**)malloc(2*sizeof(int*)); if (pCheckArray->value == NULL) FailAllocMessage(); memset(pCheckArray->value, 0, 2*sizeof(int*)); pCheckArray->value[SHOWN_COL] = (int*)malloc(num_rows*sizeof(int)); pCheckArray->value[NSHOWN_COL] = (int*)malloc(num_rows*sizeof(int)); if (pCheckArray->value[SHOWN_COL] == NULL || pCheckArray->value[NSHOWN_COL] == NULL) { FailAllocMessage(); } memset(pCheckArray->value[SHOWN_COL], 0, num_rows*sizeof(int)); memset(pCheckArray->value[NSHOWN_COL], 0, num_rows*sizeof(int)); } fileAttrNameDspPtr = (DspList*)malloc(num_rows*sizeof(DspList)); if (fileAttrNameDspPtr == NULL) FailAllocMessage(); memset(fileAttrNameDspPtr, 0, num_rows*sizeof(DspList)); for (i=1, dsp_ptr=fileAttrNameDspPtr, attr_ptr=ObjPtr->fattr; i<=num_rows; i++, dsp_ptr++, attr_ptr=attr_ptr->next) { if (*attr_ptr->attr_name.s == '\0') { UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), attr_ptr->attr_value.s); } else { sprintf(gszMsgBox, "%s%s", attr_ptr->attr_name.s, attr_ptr->attr_value.s); UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), gszMsgBox); } /* use the directory field for inherited */ dsp_ptr->directory = attr_ptr->inherited; dsp_ptr->next = ((i == num_rows) ? NULL : &dsp_ptr[1]); if (pCheckArray != NULL) { if (attr_ptr->shown) pCheckArray->value[SHOWN_COL][i-1] = TRUE; if (attr_ptr->nameshown) pCheckArray->value[NSHOWN_COL][i-1] = TRUE; } } *pn_entries = num_rows; return fileAttrNameDspPtr; } static int EditAttrCheckUpdate(pp_dsp_ptr, ppsz_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, col, row, p_void) DspList **pp_dsp_ptr; char ***ppsz_entries, *cur_buf; int *pn_num_entries, *pn_marked_index, col, row; struct CheckArrayRec **pp_check_array; void *p_void; { char *psz=NULL, saved_ch='\0', *buf=NULL; int shown=FALSE, nameshown=FALSE; if (ppsz_entries == NULL || *ppsz_entries == NULL || (*ppsz_entries)[row] == NULL || pp_check_array == NULL || (*pp_check_array) == NULL || (*pp_check_array)->value == NULL) { return FALSE; } buf = (*ppsz_entries)[row]; shown = (*pp_check_array)->value[SHOWN_COL][row]; nameshown = (*pp_check_array)->value[NSHOWN_COL][row]; psz = strchr(buf, '='); if (psz != NULL) { saved_ch = *psz; *psz = '\0'; if (shown) { if (nameshown) { sprintf(gszMsgBox, TgLoadString(STID_SHOW_ATTR_NAME_AND_VALUE), buf); } else { sprintf(gszMsgBox, TgLoadString(STID_SHOW_ATTR_VALUE_ONLY), buf); } } else { sprintf(gszMsgBox, TgLoadString(STID_NOT_SHOW_ATTR), buf); } *psz = saved_ch; } else { if (shown) { sprintf(gszMsgBox, TgLoadString(STID_SHOW_ATTR), buf); } else { sprintf(gszMsgBox, TgLoadString(STID_WONT_SHOW_VALUE), buf); } } SetStringStatus(gszMsgBox); return TRUE; } static int EditAttrNames(TopStr, ObjAttrDspList, entries, num_entries, pCheckArray) char *TopStr, **entries; DspList *ObjAttrDspList; int num_entries; struct CheckArrayRec *pCheckArray; { char win_name[128]; sprintf(win_name, TgLoadString(STID_TGIF_EDIT_ATTR_NAMES), TOOL_NAME); ResetNamesInfo(); NamesSetTitle(TopStr); NamesAddButton(TgLoadCachedString(CSTID_OK), BUTTON_OK); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); /* ignore double-click and <CR> */ NamesSetDefaultBtnId(BUTTON_OK, INVALID); NamesSetStyle(NAMES_EDIT_ATTR, NAMES_LOOP_ONCE); if (pCheckArray != NULL) { NamesSetCallback(NULL, NULL, (CheckUpdateFunc*)EditAttrCheckUpdate); } NamesSetEntries(ObjAttrDspList, entries, num_entries, pCheckArray, TRUE, INVALID, 0); return (Names(win_name, NULL, NULL, 0, NULL)==BUTTON_OK); } int BlankStr(s) char *s; { while (*s == ' ') s++; return (*s == '\0'); } void EditFileAttrs() { int i, num_entries=0; DspList *dsp_ptr; char **entries=NULL; if (gstWBInfo.do_whiteboard) { /* * Now it's allowed. * * MsgBox(TgLoadString(STID_EDIT_FILE_ATTRS_IN_WB), TOOL_NAME, INFO_MB); * return; */ } if (tgifObj->fattr == NULL) { MsgBox(TgLoadString(STID_FILE_CONTAINS_NO_ATTRS), TOOL_NAME, INFO_MB); return; } MakeQuiescent(); dsp_ptr = FileAttrNameListing(tgifObj, &num_entries, NULL); ignoreDirectoryFlag = TRUE; entries = MakeNameDspItemArray(num_entries, dsp_ptr); ignoreDirectoryFlag = FALSE; if (EditAttrNames(TgLoadString(STID_EDIT_FILE_ATTRS_DOTS), NULL, entries, num_entries, NULL)) { int modified=FALSE; struct AttrRec *attr_ptr, *next_attr; AddObj(NULL, topObj, tgifObj); AddNewSelObj(topObj); PrepareToReplaceAnObj(topObj); for (attr_ptr=tgifObj->fattr, i=0; attr_ptr!=NULL; attr_ptr=next_attr, i++) { int blank_str=BlankStr(entries[i]); struct TextRec *text_ptr=attr_ptr->obj->detail.t; next_attr = attr_ptr->next; if ((blank_str && text_ptr->minilines.first==text_ptr->minilines.last) || strcmp(GetTextPtrFirstStrSeg(text_ptr)->dyn_str.s, entries[i]) != 0) { modified = TRUE; if (blank_str && text_ptr->minilines.first==text_ptr->minilines.last) { UnlinkAttr(attr_ptr); FreeTextObj(attr_ptr->obj); FreeAttr(attr_ptr); } else { DynStrSet(&GetTextPtrFirstStrSeg(text_ptr)->dyn_str, entries[i]); UpdateAttr(text_ptr, attr_ptr); } } } if (modified) { recordCmdIncludeTgifObj = TRUE; RecordReplaceAnObj(topObj); recordCmdIncludeTgifObj = FALSE; RemoveAllSel(); UnlinkObj(topObj); SetFileModified(TRUE); Msg(TgLoadString(STID_FILE_ATTRS_UPDATED)); } else { AbortPrepareCmd(CMD_REPLACE); RemoveAllSel(); UnlinkObj(topObj); } } free(dsp_ptr); free(*entries); free(entries); fileAttrNameDspPtr = NULL; Msg(""); SetCurChoice(curChoiceBeforeMakeQuiescent); } void EditAttrs() { int i, num_entries=0; DspList *dsp_ptr; char **entries=NULL; struct CheckArrayRec check_array, orig_check_array; if (topSel == NULL || topSel != botSel) { MsgBox(TgLoadString(STID_SELECT_ONE_OBJ_FOR_EDITATTRS), TOOL_NAME, INFO_MB); return; } if (topSel->obj->fattr == NULL) { MsgBox(TgLoadString(STID_OBJ_CONTAINS_NO_ATTRS), TOOL_NAME, INFO_MB); return; } memset(&check_array, 0, sizeof(struct CheckArrayRec)); memset(&orig_check_array, 0, sizeof(struct CheckArrayRec)); dsp_ptr = FileAttrNameListing(topSel->obj, &num_entries, &check_array); ignoreDirectoryFlag = TRUE; entries = MakeNameDspItemArray(num_entries, dsp_ptr); ignoreDirectoryFlag = FALSE; CopyCheckArray(&orig_check_array, &check_array); if (EditAttrNames(TgLoadString(STID_EDIT_OBJ_ATTRS_DOTS), dsp_ptr, entries, num_entries, &check_array)) { int modified=FALSE, sel_ltx, sel_lty, sel_rbx, sel_rby; struct AttrRec *attr_ptr, *next_attr; sel_ltx = selLtX; sel_lty = selLtY; sel_rbx = selRbX; sel_rby = selRbY; HighLightReverse(); PrepareToReplaceAnObj(topSel->obj); for (attr_ptr=topSel->obj->fattr, i=0; attr_ptr!=NULL; attr_ptr=next_attr, i++) { int blank_str=BlankStr(entries[i]); char orig_str[MAXPATHLENGTH+1]; struct TextRec *text_ptr=attr_ptr->obj->detail.t; next_attr = attr_ptr->next; if (*attr_ptr->attr_name.s == '\0') { strcpy(orig_str, attr_ptr->attr_value.s); } else { sprintf(orig_str, "%s%s", attr_ptr->attr_name.s, attr_ptr->attr_value.s); } if ((blank_str && text_ptr->minilines.first==text_ptr->minilines.last) || strcmp(orig_str, entries[i]) != 0 || (check_array.value[SHOWN_COL][i] != orig_check_array.value[SHOWN_COL][i]) || (check_array.value[NSHOWN_COL][i] != orig_check_array.value[NSHOWN_COL][i])) { modified = TRUE; if (blank_str && text_ptr->minilines.first==text_ptr->minilines.last) { UnlinkAttr(attr_ptr); FreeTextObj(attr_ptr->obj); FreeAttr(attr_ptr); } else { int saved_nameshown; attr_ptr->shown = check_array.value[SHOWN_COL][i]; attr_ptr->nameshown = check_array.value[NSHOWN_COL][i]; saved_nameshown = attr_ptr->nameshown; DynStrSet(&GetTextPtrFirstStrSeg(text_ptr)->dyn_str, entries[i]); attr_ptr->nameshown = TRUE; UpdateAttr(text_ptr, attr_ptr); if (!saved_nameshown) { if (*attr_ptr->attr_name.s != '\0') { attr_ptr->nameshown = saved_nameshown; } UpdAttr(attr_ptr); UpdateAttr(text_ptr, attr_ptr); } } } } if (modified) { AdjObjBBox(topSel->obj); RecordReplaceAnObj(topSel->obj); UpdSelBBox(); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; Msg(TgLoadString(STID_OBJ_ATTRS_UPDATED)); } else { AbortPrepareCmd(CMD_REPLACE); } HighLightForward(); } free(dsp_ptr); free(*entries); free(entries); CleanUpCheckArray(&orig_check_array); CleanUpCheckArray(&check_array); fileAttrNameDspPtr = NULL; Msg(""); } static int GetAttrNamesCount(buf) char *buf; { int count=0; while (*buf != '\0') { char *psz=NULL; if (*buf == ':') return INVALID; psz = strchr(buf, ':'); if (psz == NULL) { count++; break; } else { count++; buf = (&psz[1]); } } return count; } static void SetAttrGroupInfoDisplayedNames(pagi) AttrGroupInfo *pagi; { int i=0, total=0; char *psz=NULL; for (i=0; i < pagi->num_attrs; i++) { total += strlen(pagi->attr_name[i])+1; } total += 1; pagi->displayed_names = (char*)malloc(total*sizeof(char)); if (pagi->displayed_names == NULL) FailAllocMessage(); memset(pagi->displayed_names, 0, total*sizeof(char)); for (i=0, psz=pagi->displayed_names; i < pagi->num_attrs; i++) { if (i == pagi->num_attrs-1) { sprintf(psz, "%s", pagi->attr_name[i]); psz += strlen(pagi->attr_name[i]); } else { sprintf(psz, "%s:", pagi->attr_name[i]); psz += strlen(pagi->attr_name[i])+1; } } } static void FreeAttrGroupInfo(pagi) AttrGroupInfo *pagi; { UtilFree(pagi->group_name); UtilFree(pagi->group_value); UtilFree(pagi->displayed_names); if (pagi->num_attrs > 0 && pagi->attr_name != NULL) { free(pagi->attr_name); } } static void CleanUpAttrGroup() { int i=0; if (maxAttrGroups != 0 && gAttrGroupInfo != NULL) { for (i=0; i < maxAttrGroups; i++) { FreeAttrGroupInfo(gAttrGroupInfo[i]); free(gAttrGroupInfo[i]); } free(gAttrGroupInfo); } maxAttrGroups = 0; gAttrGroupInfo = NULL; } void CleanUpAttr() { CleanUpAttrGroup(); } static int ParseAttrGroupXDef(group_index, xdef_line, buf) int group_index; char *xdef_line, *buf; { char *psz_attr_names=strchr(buf, ':'), *psz_attr=NULL; int count=0, index=0; if (psz_attr_names == NULL) { if (xdef_line == NULL) { fprintf(stderr, TgLoadString(STID_INVALID_COMPILER_OPT), "DEFATTRGROUP", buf); } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF), TOOL_NAME, xdef_line, buf); } fprintf(stderr, "\n"); return FALSE; } *psz_attr_names++ = '\0'; count = GetAttrNamesCount(psz_attr_names); if (count == INVALID) { if (xdef_line == NULL) { fprintf(stderr, TgLoadString(STID_INVALID_COMPILER_OPT), "DEFATTRGROUP", buf); } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF), TOOL_NAME, xdef_line, buf); } fprintf(stderr, "\n"); return FALSE; } gAttrGroupInfo[group_index]->group_name = UtilStrDup(buf); if (gAttrGroupInfo[group_index]->group_name == NULL) { FailAllocMessage(); } UtilTrimBlanks(gAttrGroupInfo[group_index]->group_name); gAttrGroupInfo[group_index]->group_value = UtilStrDup(psz_attr_names); if (gAttrGroupInfo[group_index]->group_value == NULL) { FailAllocMessage(); } UtilTrimBlanks(gAttrGroupInfo[group_index]->group_value); gAttrGroupInfo[group_index]->attr_name = (char**)malloc( count*sizeof(char*)); if (gAttrGroupInfo[group_index]->attr_name == NULL) { FailAllocMessage(); } memset(gAttrGroupInfo[group_index]->attr_name, 0, count*sizeof(char*)); psz_attr = gAttrGroupInfo[group_index]->group_value; while (*psz_attr != '\0') { char *psz_colon=strchr(psz_attr, ':'); if (psz_colon != NULL) *psz_colon = '\0'; UtilTrimBlanks(psz_attr); gAttrGroupInfo[group_index]->attr_name[index] = psz_attr; index++; if (psz_colon != NULL) { psz_attr = ++psz_colon; } else { break; } } gAttrGroupInfo[group_index]->num_attrs = count; SetAttrGroupInfoDisplayedNames(gAttrGroupInfo[group_index]); return TRUE; } int InitAttr() { char *c_ptr=NULL, buf[MAXSTRING]; int i=0, attr_group_in_xdef=TRUE; maxAttrGroups = 0; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MaxAttributeGroups")) != NULL) { maxAttrGroups = atoi(c_ptr); } if (cmdLineTgrm2) { #ifdef DEFATTRGROUP if (maxAttrGroups == 0) { maxAttrGroups = 1; attr_group_in_xdef = FALSE; } #endif /* DEFATTRGROUP */ } if (maxAttrGroups > 0) { gAttrGroupInfo = (AttrGroupInfo**)malloc(maxAttrGroups * sizeof(AttrGroupInfo*)); if (gAttrGroupInfo == NULL) FailAllocMessage(); memset(gAttrGroupInfo, 0, maxAttrGroups*sizeof(AttrGroupInfo*)); for (i=0; i < maxAttrGroups; i++) { gAttrGroupInfo[i] = (AttrGroupInfo*)malloc(sizeof(AttrGroupInfo)); if (gAttrGroupInfo[i] == NULL) FailAllocMessage(); memset(gAttrGroupInfo[i], 0, sizeof(AttrGroupInfo)); if (attr_group_in_xdef) { sprintf(buf, "AttributeGroup%1d", i); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,buf)) != NULL) { ParseAttrGroupXDef(i, buf, c_ptr); } else { fprintf(stderr, TgLoadString(STID_CANNOT_GET_X_DEFAULT), TOOL_NAME, buf); fprintf(stderr, "\n"); } } else if (cmdLineTgrm2) { #ifdef DEFATTRGROUP char *tmp_buf=UtilStrDup(DEFATTRGROUP); if (tmp_buf == NULL) FailAllocMessage(); if (!ParseAttrGroupXDef(i, NULL, tmp_buf)) { CleanUpAttrGroup(); } UtilFree(tmp_buf); #endif /* DEFATTRGROUP */ } } } else if (maxAttrGroups == 0) { /* nothing to do */ } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "MaxAttributeGroups", c_ptr, 0); fprintf(stderr, "\n"); } return TRUE; } ���������������������������������������������������������������������������tgif-QPL-4.2.5/example.tex��������������������������������������������������������������������������0000644�0000764�0000764�00000003323�11602233311�015141� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������% % @(#)$Header: /mm2/home/cvs/bc-src/tgif/example.tex,v 1.1 2004/06/18 23:20:49 william Exp $ % \documentstyle[12pt]{article} % \oddsidemargin=0in \textwidth=6.5in \topmargin=0in \textheight=609pt \parskip=14pt \setlength{\unitlength}{0.5cm} \begin{document} % Figure \ref{fig:psfig} is an example of a tgif \LaTeX\,\, figure printed with the ``psfig'' macro. As you can see, the figure fits nicely between the surrounding text. % \begin{figure*}[htb] \input{psfig} \centerline{\psfig{figure=an-sr-flip-flop.eps}} \caption{Example Tgif Diagram Printed with ``psfig'' Macro.\label{fig:psfig}} \end{figure*} % The bounding box seems to be pretty tight. In Figure \ref{fig:epsf} below, the same figure is generated with the ``epsf'' construct. % \begin{figure*}[htb] \input{epsf} \centerline{\epsffile{an-sr-flip-flop.eps}} \caption{Example Tgif Diagram Printed with ``epsf'' Macro.\label{fig:epsf}} \end{figure*} % All these are just trying the illustrate that the bounding boxes generated by tgif is pretty tight, and there's really no need for the ``psfile'' construct. I don't know if there are cases where some documentation generation software only supports the ``psfile'' construct, but I an putting in the example anyways. Figure \ref{fig:psfile} is an example of a tgif \LaTeX\,\, figure printed with the ``psfile'' macro. Notice the \\rule command. % \begin{figure*}[htb] \special{psfile="an-sr-flip-flop.eps" hoffset=-72 voffset=-792} \rule{0in}{1.1in} \caption{Example Tgif Diagram Printed with ``psfile'' Macro.\label{fig:psfile}} \end{figure*} % It is reserving a space of 1.1 inch for the figure. This can be figured out from the ruler within tgif. As a general rule, the ``psfile'' construct should be avoided. \end{document} �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/ruler.c������������������������������������������������������������������������������0000644�0000764�0000764�00000127746�11602233312�014302� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/ruler.c,v 1.20 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_RULER_C_ #include "tgifdefs.h" #include "choice.e" #include "cursor.e" #include "dialog.e" #include "file.e" #include "font.e" #include "grid.e" #include "mainloop.e" #include "mainmenu.e" #include "menu.e" #include "msg.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "xpixmap.e" #define INCH_H (RULER_W-2) #define HALF_INCH_H 10 #define QUARTER_INCH_H 6 #define MIN_INCH_H 3 #define HALF_CM_H 8 #define MIN_CM_H 4 int showMeasurement=FALSE; int showMeasurementInTooltip=TRUE; int simpleMotionInDrawWin=FALSE; int showCrossHair=FALSE; static int measureTooltipVerbose=FALSE; static float gfPixelsPerUnit=(float)1.0; static float gfNumUnits=(float)1.0; static float gfNumFracUnits=(float)1.0; static char numUnitStr[80], baseUnitStr[80], unitStr[80], formatUnitStr[80]; static GC rulerGC; static int oldXOff=(-1), oldYOff=(-1); static int rulerLen=0; static int hRulerJustRedrawn=TRUE, justUnFrozen=FALSE; static int freezeMarkRulerText=FALSE, frozenXOff=0, frozenYOff=0; static char *gpszFrozenDeltaStr=NULL; static char *gpszOldDeltaStr=NULL; void GetUnitSpec(buf) char *buf; { if (*formatUnitStr == '\0') { sprintf(buf, "%s %s/%s", (*numUnitStr)=='\0' ? "1" : numUnitStr, (*baseUnitStr)=='\0' ? "pixel" : baseUnitStr, (*unitStr)=='\0' ? "pixel" : unitStr); } else { char buf1[80]; FormatFloat(&gfNumFracUnits, buf1); sprintf(buf, "%s %s/%s;%s;%s", (*numUnitStr)=='\0' ? "1" : numUnitStr, (*baseUnitStr)=='\0' ? "pixel" : baseUnitStr, (*unitStr)=='\0' ? "pixel" : unitStr, formatUnitStr, buf1); } } void ShowUnitMsg() { sprintf(gszMsgBox, TgLoadString(STID_MEASUREMENT_SHOWN_IN_UNIT), (*unitStr)=='\0' ? "pixel" : unitStr, (*numUnitStr)=='\0' ? "1" : numUnitStr, (*baseUnitStr)=='\0' ? "pixel" : baseUnitStr); Msg(gszMsgBox); } static int BadUnit(spec) char *spec; { if (msgWindow != None) { sprintf(gszMsgBox, TgLoadString(STID_BAD_MEASUREMENT_UNIT_SPEC), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } static int VerifyFormatUnitStr(format_unit_str) char *format_unit_str; { char *c_ptr=format_unit_str, *semi_ptr=NULL; int seek_percent=TRUE, count=0; if ((semi_ptr=strchr(format_unit_str, ';')) == NULL) { return FALSE; } else { float fval; *semi_ptr++ = '\0'; UtilTrimBlanks(semi_ptr); if (sscanf(semi_ptr, "%f", &fval) != 1) { return FALSE; } gfNumFracUnits = fval; } for (c_ptr=format_unit_str; *c_ptr != '\0'; c_ptr++) { if (seek_percent) { if (*c_ptr == '%') { seek_percent = FALSE; } } else if (*c_ptr == 'f') { seek_percent = TRUE; count++; } else if (!(*c_ptr == '.' || (*c_ptr >= '0' && *c_ptr <= '9'))) { return FALSE; } } if (seek_percent && count==2) { strcpy(formatUnitStr, format_unit_str); return TRUE; } return FALSE; } int SetUnit(spec) char *spec; { char *spec_copy=UtilStrDup(spec); char *num_ptr=NULL, *base_ptr=NULL, *unit_ptr=NULL, *semi_ptr=NULL; int ok=TRUE; if (spec_copy == NULL) { return FALSE; } if ((semi_ptr=strchr(spec_copy, ';')) != NULL) { *semi_ptr++ = '\0'; if (!VerifyFormatUnitStr(semi_ptr)) { ok = BadUnit(spec); } } else { *formatUnitStr = '\0'; } if ((num_ptr=strtok(spec_copy, " \t\n\r")) != NULL && (base_ptr=strtok(NULL, "/ \t\n\r")) != NULL && (unit_ptr=strtok(NULL, "/ \t\n\r")) != NULL) { float fval; if (sscanf(num_ptr, "%f", &fval) == 1 && fval > INT_TOL && *base_ptr != '\0' && *unit_ptr != '\0') { gfNumUnits = fval; strcpy(numUnitStr, num_ptr); if (UtilStrICmp("pixel", unit_ptr) == 0) { *unitStr = '\0'; } else { strcpy(unitStr, unit_ptr); } switch (*base_ptr) { case 'i': case 'I': gfPixelsPerUnit = gfNumUnits * ((float)ONE_INCH); strcpy(baseUnitStr, "in"); break; case 'c': case 'C': gfPixelsPerUnit = gfNumUnits * ((float)ONE_CM); strcpy(baseUnitStr, "cm"); break; case 'p': case 'P': gfPixelsPerUnit = gfNumUnits; *baseUnitStr = '\0'; break; default: ok = BadUnit(spec); break; } } else { ok = BadUnit(spec); } } else { ok = BadUnit(spec); } if (!ok) { gfPixelsPerUnit = gfNumUnits = (float)1.0; *numUnitStr = *baseUnitStr = *unitStr = *formatUnitStr = '\0'; } free(spec_copy); return ok; } void InitRuler() { XGCValues values; char *c_ptr; values.foreground = myFgPixel; values.background = (threeDLook ? myLtGryPixel : myBgPixel); values.fill_style = FillSolid; values.font = rulerFontPtr->fid; rulerGC = XCreateGC(mainDisplay, mainWindow, GCForeground | GCBackground | GCFillStyle | GCFont, &values); showMeasurement = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ShowMeasurement")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { showMeasurement = TRUE; } showCrossHair = FALSE; /* if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ShowCrossHair")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { showCrossHair = TRUE; } */ gfPixelsPerUnit = gfNumUnits = (float)1.0; *numUnitStr = *baseUnitStr = *unitStr = *formatUnitStr = '\0'; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ShowMeasurementUnit")) != NULL) { char spec[80]; if (strcmp("pixel", c_ptr) == 0) { strcpy(spec, "1 pixel/pixel"); } else if (strcmp("inch", c_ptr) == 0) { sprintf(spec, "%1d pixel/in", ONE_INCH); } else if (strcmp("cm", c_ptr) == 0) { sprintf(spec, "%1d pixel/cm", ONE_CM); } else { strcpy(spec, c_ptr); } if (!SetUnit(spec)) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "ShowMeasurementUnit", spec, "pixel"); fprintf(stderr, "\n"); } } rulerLen = rulerW-1; } void CleanUpRuler() { XFreeGC(mainDisplay, rulerGC); } void PixelToMeasurementUnit(Buf, NumPixels) char *Buf; int NumPixels; { float fval; int ival; if (*unitStr == '\0') { sprintf(Buf, "%+1d", NumPixels); } else { fval = (float)((float)NumPixels*1000.0)/(gfPixelsPerUnit); ival = ((int)round(fval)); fval = ((float)ival)/((float)1000.0); if (*formatUnitStr == '\0') { sprintf(Buf, "%+.3f%s", fval, unitStr); } else { float frac; ival = (int)fval; frac = ((ival >= 0) ? fval-((float)ival) : ((float)ival)-fval); fval = (float)ival; sprintf(Buf, formatUnitStr, fval, frac*gfNumFracUnits); } } } void SquarePixelToMeasurementUnit(Buf, NumSquarePixels) char *Buf; int NumSquarePixels; { float fval; int ival; if (*unitStr == '\0') { sprintf(Buf, "%+1d", NumSquarePixels); } else { fval = (float)((float)NumSquarePixels*1000.0)/(gfPixelsPerUnit); fval = (float)(fval/gfPixelsPerUnit); ival = ((int)round(fval)); fval = ((float)ival)/((float)1000.0); if (*formatUnitStr == '\0') { sprintf(Buf, "%+.3f sq %s", fval, unitStr); } else { float frac; ival = (int)fval; frac = ((ival >= 0) ? fval-((float)ival) : ((float)ival)-fval); fval = (float)ival; sprintf(Buf, formatUnitStr, fval, frac*gfNumFracUnits); } } } void PixelToCurrentUnit(Buf, NumPixels) char *Buf; int NumPixels; { int unit_str_was_empty=(*unitStr == '\0'); char num_unit_str[80], base_unit_str[80]; float pixel_per_unit=gfPixelsPerUnit, num_units=gfNumUnits; if (unit_str_was_empty) { UtilStrCpyN(num_unit_str, sizeof(num_unit_str), numUnitStr); UtilStrCpyN(base_unit_str, sizeof(base_unit_str), baseUnitStr); switch (gridSystem) { case ENGLISH_GRID: gfPixelsPerUnit = 128; gfNumUnits = 1; UtilStrCpyN(unitStr, sizeof(unitStr), "inch"); break; case METRIC_GRID: gfPixelsPerUnit = 50; gfNumUnits = 2.5; UtilStrCpyN(unitStr, sizeof(unitStr), "cm"); break; } PixelToMeasurementUnit(Buf, NumPixels); } else { PixelToMeasurementUnit(Buf, NumPixels); } if (unit_str_was_empty) { gfPixelsPerUnit = pixel_per_unit; gfNumUnits = num_units; *unitStr = '\0'; UtilStrCpyN(numUnitStr, sizeof(numUnitStr), num_unit_str); UtilStrCpyN(baseUnitStr, sizeof(baseUnitStr), base_unit_str); } } static int RightMarginMarkVisible() { return ((rightMarginEnabled == TRUE) && (drawOrigX+drawWinW > paperWidth-(rightMargin>>TIK_PER_PIXEL_SHIFTS))); } static void GetRightMarginMarkVs(vs) XPoint vs[6]; { int x=OFFSET_X(paperWidth-(rightMargin>>TIK_PER_PIXEL_SHIFTS))-1; int delta=(rulerW>>2); int y_end=rulerW-(threeDLook ? ((windowPadding>>1)+2) : 1); int y_start=(threeDLook ? ((windowPadding>>1)-2) : (-1))+(delta<<1); vs[0].x = x; vs[0].y = y_start; vs[1].x = x-delta; vs[1].y = y_start+delta; vs[2].x = x-delta; vs[2].y = y_end; vs[3].x = x+delta; vs[3].y = y_end; vs[4].x = x+delta; vs[4].y = y_start+delta; vs[5].x = x; vs[5].y = y_start; } static int PtInRightMarginMark(button_x, button_y) int button_x, button_y; { XPoint vs[6]; GetRightMarginMarkVs(vs); return PointInPolygon(button_x, button_y, 6, vs); } static void RedrawRightMargin(dpy, win) Display *dpy; Window win; { if (rightMarginEnabled != TRUE) return; if (drawOrigX+drawWinW > paperWidth-(rightMargin>>TIK_PER_PIXEL_SHIFTS)) { int delta=(rulerW>>2); int x=OFFSET_X(paperWidth-(rightMargin>>TIK_PER_PIXEL_SHIFTS))-1; int y_end=rulerW-(threeDLook ? ((windowPadding>>1)+2) : 1); int y_start=(threeDLook ? ((windowPadding>>1)-2) : (-1))+(delta<<1); int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); GC gc=defaultGC; XPoint vs[6]; GetRightMarginMarkVs(vs); if (threeDLook) { XSetForeground(mainDisplay, textMenuGC, bg_pixel); XFillPolygon(dpy, win, textMenuGC, vs, 6, Convex, CoordModeOrigin); XDrawLines(dpy, win, gc, vs, 6, CoordModeOrigin); } else { XDrawLines(dpy, win, gc, vs, 6, CoordModeOrigin); } rightMarginActive = ShouldRightMarginBeActive(); if (!rightMarginActive) { XDrawLine(dpy, win, gc, x-delta, y_start+1, x+delta-1, y_end); XDrawLine(dpy, win, gc, x-delta+1, y_start+1, x+delta, y_end); /* * The code doesn't look right, but it look symmetrical on the screen! * * XDrawLine(dpy, win, gc, x+delta, y_start+1, x-delta+1, y_end); * XDrawLine(dpy, win, gc, x+delta-1, y_start+1, x-delta, y_end); */ XDrawLine(dpy, win, gc, x+delta+1, y_start, x-delta+1, y_end); XDrawLine(dpy, win, gc, x+delta, y_start, x-delta, y_end); } } } void RedrawHRuler(dpy, win) Display *dpy; Window win; { register int i, pos, len, index; int inc, abs_inc, y=rulerW-(threeDLook ? (windowPadding>>1) : 0); char s[5]; switch (gridSystem) { case ENGLISH_GRID: inc = (zoomedIn ? (xyEnglishGrid<<zoomScale) : xyEnglishGrid); abs_inc = ABS_SIZE(inc); if (drawOrigX % abs_inc == 0) { i = 0; pos = 0; } else { i = ((int)(drawOrigX / abs_inc) + 1) * abs_inc - drawOrigX; pos = ZOOMED_SIZE(i); } pos--; /* since drawWindow has no border */ for ( ; i<drawWinW; i+=abs_inc, pos+=inc) { if ((GRID_ZOOMED_SIZE(i+drawOrigX)) % ONE_INCH == 0) { index = (int)((GRID_ZOOMED_SIZE(i+drawOrigX)) / ONE_INCH); sprintf(s, "%1d", GRID_ABS_SIZE(index)); len = strlen(s); XDrawString(dpy, win, rulerGC, pos+2, y-INCH_H+rulerFontAsc, s, len); XDrawLine(dpy, win, defaultGC, pos, y, pos, y-INCH_H); } else if ((GRID_ZOOMED_SIZE(i+drawOrigX)) % HALF_INCH == 0) { XDrawLine(dpy, win, defaultGC, pos, y, pos, y-HALF_INCH_H); } else if ((GRID_ZOOMED_SIZE(i+drawOrigX)) % QUARTER_INCH == 0) { XDrawLine(dpy, win, defaultGC, pos, y, pos, y-QUARTER_INCH_H); } else { XDrawLine(dpy, win, defaultGC, pos, y, pos, y-MIN_INCH_H); } } break; case METRIC_GRID: inc = (zoomedIn ? (xyMetricGrid<<zoomScale) : xyMetricGrid); abs_inc = ABS_SIZE(inc); if (drawOrigX % abs_inc == 0) { i = 0; pos = 0; } else { i = ((int)(drawOrigX / abs_inc) + 1) * abs_inc - drawOrigX; pos = ZOOMED_SIZE(i); } pos--; /* since drawWindow has no border */ for ( ; i<drawWinW; i+=abs_inc, pos+=inc) { if ((GRID_ZOOMED_SIZE(i+drawOrigX)) % ONE_CM == 0) { index = (int)((GRID_ZOOMED_SIZE(i+drawOrigX)) / ONE_CM); sprintf(s, "%1d", GRID_ABS_SIZE(index)); len = strlen(s); XDrawString(dpy, win, rulerGC, pos+2, y-INCH_H+rulerFontAsc, s, len); XDrawLine(dpy, win, defaultGC, pos, y, pos, y-INCH_H); } else if ((GRID_ZOOMED_SIZE(i+drawOrigX)) % FIVE_MM == 0) { XDrawLine(dpy, win, defaultGC, pos, y, pos, y-HALF_CM_H); } else { XDrawLine(dpy, win, defaultGC, pos, y, pos, y-MIN_CM_H); } } break; } RedrawRightMargin(dpy, win); } static void DrawHRuleTick(XOff) int XOff; { XDrawLine(mainDisplay, hRuleWindow, revDefaultGC, XOff, 0, XOff, rulerLen); } static void DrawVRuleTick(YOff) { XDrawLine(mainDisplay, vRuleWindow, revDefaultGC, 0, YOff, rulerLen, YOff); } void RedrawHRulerWindow() { XEvent ev; XClearWindow(mainDisplay, hRuleWindow); XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, hRuleWindow, ExposureMask, &ev)) ; RedrawHRuler(mainDisplay, hRuleWindow); oldXOff = (-1); DrawHRuleTick(oldXOff-1); hRulerJustRedrawn = TRUE; justUnFrozen = FALSE; } void RedrawVRuler(dpy, win) Display *dpy; Window win; { register int i, pos, len, index; int inc, abs_inc, x=rulerW-(threeDLook ? (windowPadding>>1) : 0); char s[5]; switch (gridSystem) { case ENGLISH_GRID: inc = (zoomedIn ? (xyEnglishGrid<<zoomScale) : xyEnglishGrid); abs_inc = ABS_SIZE(inc); if (drawOrigY % abs_inc == 0) { i = 0; pos = 0; } else { i = ((int)(drawOrigY / abs_inc) + 1) * abs_inc - drawOrigY; pos = ZOOMED_SIZE(i); } pos--; /* since drawWindow has no border */ for ( ; i<drawWinH; i+=abs_inc, pos+=inc) { if ((GRID_ZOOMED_SIZE(i+drawOrigY)) % ONE_INCH == 0) { index = (int)((GRID_ZOOMED_SIZE(i+drawOrigY)) / ONE_INCH); sprintf(s, "%1d", GRID_ABS_SIZE(index)); len = strlen(s); XDrawString(dpy, win, rulerGC, 1, pos+rulerFontAsc+2, s, len); XDrawLine(dpy, win, defaultGC, x, pos, x-INCH_H, pos); } else if ((GRID_ZOOMED_SIZE(i+drawOrigY)) % HALF_INCH == 0) { XDrawLine(dpy, win, defaultGC, x, pos, x-HALF_INCH_H, pos); } else if ((GRID_ZOOMED_SIZE(i+drawOrigY)) % QUARTER_INCH == 0) { XDrawLine(dpy, win, defaultGC, x, pos, x-QUARTER_INCH_H, pos); } else { XDrawLine(dpy, win, defaultGC, x, pos, x-MIN_INCH_H, pos); } } break; case METRIC_GRID: inc = (zoomedIn ? (xyMetricGrid<<zoomScale) : xyMetricGrid); abs_inc = ABS_SIZE(inc); if (drawOrigY % abs_inc == 0) { i = 0; pos = 0; } else { i = ((int)(drawOrigY / abs_inc) + 1) * abs_inc - drawOrigY; pos = ZOOMED_SIZE(i); } pos--; /* since drawWindow has no border */ for ( ; i<drawWinH; i+=abs_inc, pos+=inc) { if ((GRID_ZOOMED_SIZE(i+drawOrigY)) % ONE_CM == 0) { index = (int)((GRID_ZOOMED_SIZE(i+drawOrigY)) / ONE_CM); sprintf(s, "%1d", GRID_ABS_SIZE(index)); len = strlen(s); XDrawString(dpy, win, rulerGC, 1, pos+rulerFontAsc+2, s, len); XDrawLine(dpy, win, defaultGC, x, pos, x-INCH_H, pos); } else if ((GRID_ZOOMED_SIZE(i+drawOrigY)) % FIVE_MM == 0) { XDrawLine(dpy, win, defaultGC, x, pos, x-HALF_CM_H, pos); } else { XDrawLine(dpy, win, defaultGC, x, pos, x-MIN_CM_H, pos); } } break; } } void RedrawVRulerWindow() { XEvent ev; XClearWindow(mainDisplay, vRuleWindow); XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, vRuleWindow, ExposureMask, &ev)) ; RedrawVRuler(mainDisplay, vRuleWindow); if (!freezeMarkRulerText && showMeasurement && !hRulerJustRedrawn && oldYOff != 0) { char x_buf[80], y_buf[80], buf[80]; PixelToMeasurementUnit(x_buf, ABS_X(oldXOff)); PixelToMeasurementUnit(y_buf, ABS_Y(oldYOff)); sprintf(buf, "[%s,%s]", x_buf, y_buf); if (!showMeasurementInTooltip) { XDrawString(mainDisplay, hRuleWindow, revDefaultGC, 8, 2+defaultFontAsc, buf, strlen(buf)); } hRulerJustRedrawn = TRUE; } oldYOff = (-1); DrawVRuleTick(oldYOff-1); } void MarkRulers(XOff, YOff) int XOff, YOff; { char x_buf[80], y_buf[80], buf[MAXSTRING]; DrawHRuleTick(oldXOff-1); DrawVRuleTick(oldYOff-1); if (showCrossHair) { XDrawLine(mainDisplay, drawWindow, revDefaultGC, oldXOff, 0, oldXOff, ZOOMED_SIZE(drawWinH)); XDrawLine(mainDisplay, drawWindow, revDefaultGC, 0, oldYOff, ZOOMED_SIZE(drawWinW), oldYOff); } if (hRulerJustRedrawn) { hRulerJustRedrawn= FALSE; } else if (!freezeMarkRulerText && showMeasurement) { if (justUnFrozen) { justUnFrozen = FALSE; PixelToMeasurementUnit(x_buf, ABS_X(frozenXOff)); PixelToMeasurementUnit(y_buf, ABS_Y(frozenYOff)); sprintf(buf, "[%s,%s]", x_buf, y_buf); } else { PixelToMeasurementUnit(x_buf, ABS_X(oldXOff)); PixelToMeasurementUnit(y_buf, ABS_Y(oldYOff)); sprintf(buf, "[%s,%s]", x_buf, y_buf); } if (!showMeasurementInTooltip) { XDrawString(mainDisplay, hRuleWindow, revDefaultGC, 8, 2+defaultFontAsc, buf, strlen(buf)); } } DrawHRuleTick(XOff-1); DrawVRuleTick(YOff-1); if (showCrossHair) { XDrawLine(mainDisplay, drawWindow, revDefaultGC, XOff, 0, XOff, ZOOMED_SIZE(drawWinH)); XDrawLine(mainDisplay, drawWindow, revDefaultGC, 0, YOff, ZOOMED_SIZE(drawWinW), YOff); } if (!freezeMarkRulerText && showMeasurement) { PixelToMeasurementUnit(x_buf, ABS_X(XOff)); PixelToMeasurementUnit(y_buf, ABS_Y(YOff)); if (simpleMotionInDrawWin && curChoice == NOTHING && topSel != NULL && VerboseMeasureTooltip()) { char w_buf[80], h_buf[80]; char lx_buf[80], ty_buf[80], rx_buf[80], by_buf[80]; PixelToMeasurementUnit(w_buf, selObjRbX-selObjLtX); PixelToMeasurementUnit(h_buf, selObjRbY-selObjLtY); PixelToMeasurementUnit(lx_buf, selObjLtX); PixelToMeasurementUnit(rx_buf, selObjRbX); PixelToMeasurementUnit(ty_buf, selObjLtY); PixelToMeasurementUnit(by_buf, selObjRbY); sprintf(buf, "[%s,%s]\nsel_lx=%s sel_rx=%s\nsel_ty=%s sel_by=%s\nsel_w=%s sel_h=%s", x_buf, y_buf, lx_buf, rx_buf, ty_buf, by_buf, w_buf, h_buf); } else { sprintf(buf, "[%s,%s]", x_buf, y_buf); } if (showMeasurementInTooltip) { SetMeasureTooltip(buf); } else { XDrawString(mainDisplay, hRuleWindow, revDefaultGC, 8, 2+defaultFontAsc, buf, strlen(buf)); } } else if (VerboseMeasureTooltip()) { switch (curChoice) { case NOTHING: case DRAWPOLY: case DRAWPOLYGON: case VERTEXMODE: DoIntervalMeasureTooltip(frozenXOff, frozenYOff, XOff, YOff, (frozenXOff+XOff)>>1, (frozenYOff+YOff)>>1, gpszFrozenDeltaStr); break; } } oldXOff = XOff; oldYOff = YOff; } void RedrawRulers() { RedrawHRulerWindow(); RedrawVRulerWindow(); } void GetCrossHairPosition(pnXOff, pnYOff, pnShown) int *pnXOff, *pnYOff, *pnShown; { if (pnXOff != NULL) *pnXOff = oldXOff; if (pnYOff != NULL) *pnYOff = oldYOff; if (pnShown != NULL) *pnShown = showCrossHair; } void RedrawCrossHair() { if (showCrossHair) { XDrawLine(mainDisplay, drawWindow, revDefaultGC, oldXOff, 0, oldXOff, ZOOMED_SIZE(drawWinH)); XDrawLine(mainDisplay, drawWindow, revDefaultGC, 0, oldYOff, ZOOMED_SIZE(drawWinW), oldYOff); } } void ToggleShowCrossHair() { /* the cross-hair stuff is disabled -- cannot get it to work right */ if (!showCrossHair) return; RedrawCrossHair(); /* showCrossHair = !showCrossHair; */ showCrossHair = FALSE; RedrawRulers(); if (showCrossHair) { Msg(TgLoadString(STID_SHOW_CROSSHAIR_ENABLED)); SetNullCursor(drawWindow); } else { SetDefaultCursor(drawWindow); ShowCursor(); Msg(TgLoadString(STID_SHOW_CROSSHAIR_DISABLED)); } } static void ContinueMoveRightMarginMark(dpy, OrigX, OrigY) Display *dpy; int OrigX, OrigY; /* these are mouse coordinates */ { int moving=TRUE, dx=0, grid_x=0, grid_y=0, h=ZOOMED_SIZE(drawWinH); int prev_x=0, orig_grid_x=0, orig_grid_y=0, orig_right_margin=0; char buf[80], buf2[80]; double dval=(double)0; XPoint orig_vs[6], vs[6]; XEvent ev; XFlush(dpy); XSync(dpy, False); if (XCheckMaskEvent(dpy, ExposureMask, &ev) || XCheckMaskEvent(dpy, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } GridXY(OrigX, OrigY, &grid_x, &grid_y); orig_grid_x = grid_x; orig_grid_y = grid_y; orig_right_margin = OFFSET_X(paperWidth-(rightMargin>>TIK_PER_PIXEL_SHIFTS)); prev_x = orig_right_margin+0; GetRightMarginMarkVs(orig_vs); memcpy(vs, orig_vs, 6*sizeof(XPoint)); dval = ((double)rightMargin) * ((double)printMag) / ((double)TIK_PER_PIXEL); dval /= ((double)100); PixelToMeasurementUnit(buf, round(dval)); sprintf(buf2, "margin=%s", buf); StartShowMeasureCursor(OrigX, 4, buf2, FALSE); /* draw */ XDrawLine(dpy, drawWindow, revDefaultGC, prev_x, 0, prev_x, h); XDrawLines(dpy, hRuleWindow, revDefaultGC, vs, 6, CoordModeOrigin); if (!debugNoPointerGrab) { XGrabPointer(dpy, drawWindow, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, moveCursor, CurrentTime); } while (moving) { XEvent input; XNextEvent(dpy, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { int abs_dx=ABS_SIZE(dx); XUngrabPointer(dpy, CurrentTime); XSync(dpy, False); moving = FALSE; /* erase */ XDrawLine(dpy, drawWindow, revDefaultGC, prev_x, 0, prev_x, h); XDrawLines(dpy, hRuleWindow, revDefaultGC, vs, 6, CoordModeOrigin); EndShowMeasureCursor(OrigX+dx, 4, buf2, FALSE); rightMargin -= (abs_dx<<TIK_PER_PIXEL_SHIFTS); RedrawHRulerWindow(); } else if (input.type == MotionNotify) { int i=0, mouse_x=0, mouse_y=0; /* erase */ XDrawLine(dpy, drawWindow, revDefaultGC, prev_x, 0, prev_x, h); XDrawLines(dpy, hRuleWindow, revDefaultGC, vs, 6, CoordModeOrigin); ShowMeasureCursor(OrigX+dx, 4, buf2, FALSE); mouse_x = input.xmotion.x; mouse_y = input.xmotion.y; GridXY(mouse_x, mouse_y, &grid_x, &grid_y); dx = grid_x - orig_grid_x; prev_x = orig_right_margin+0+dx; for (i=0; i < 6; i++) { vs[i].x = orig_vs[i].x+dx; } /* draw */ XDrawLine(dpy, drawWindow, revDefaultGC, prev_x, 0, prev_x, h); XDrawLines(dpy, hRuleWindow, revDefaultGC, vs, 6, CoordModeOrigin); dval = (((double)(rightMargin-(ABS_SIZE(dx)<<TIK_PER_PIXEL_SHIFTS))) * ((double)printMag) / ((double)TIK_PER_PIXEL)) / ((double)100); PixelToMeasurementUnit(buf, round(dval)); sprintf(buf2, "margin=%s", buf); ShowMeasureCursor(OrigX+dx, 4, buf2, FALSE); } } } void RulersEventHandler(input) XEvent *input; { if (input->type == ButtonPress) { XButtonEvent *button_ev=(&input->xbutton); int mouse_x=button_ev->x, mouse_y=button_ev->y; if (RightMarginMarkVisible() && PtInRightMarginMark(mouse_x, mouse_y)) { ContinueMoveRightMarginMark(mainDisplay, mouse_x, mouse_y); } else if (button_ev->button == Button1) { IncGrid(); } else if (button_ev->button == Button2) { GridMenu(button_ev->x_root, button_ev->y_root, FALSE); } else if (button_ev->button == Button3) { DecGrid(); } } else if (input->xany.window == vRuleWindow) { if (input->type == Expose) { RedrawVRulerWindow(); } else if (input->type == EnterNotify) { SetMouseStatus(TgLoadCachedString(CSTID_INC_GRID_SIZE), TgLoadCachedString(CSTID_GRID_MENU), TgLoadCachedString(CSTID_DEC_GRID_SIZE)); } } else if (input->xany.window == hRuleWindow) { if (input->type == Expose) { RedrawHRulerWindow(); } else if (input->type == EnterNotify) { SetMouseStatus(TgLoadCachedString(CSTID_INC_GRID_SIZE), TgLoadCachedString(CSTID_GRID_MENU), TgLoadCachedString(CSTID_DEC_GRID_SIZE)); } } } void FreezeMarkRulerText() { if (!freezeMarkRulerText) { EndMeasureTooltip(FALSE); } freezeMarkRulerText = TRUE; frozenXOff = oldXOff; frozenYOff = oldYOff; UtilFree(gpszFrozenDeltaStr); if (gpszOldDeltaStr != NULL) { gpszFrozenDeltaStr = UtilStrDup(gpszOldDeltaStr); if (gpszFrozenDeltaStr == NULL) FailAllocMessage(); } } void UnFreezeMarkRulerText() { freezeMarkRulerText = FALSE; justUnFrozen = TRUE; } static int oldLtX, oldLtY, oldRbX, oldRbY, oldMdX, oldMdY; int VerboseMeasureTooltip() { return (showMeasurement && showMeasurementInTooltip && measureTooltipVerbose); } static void DoIntervalRulers() { if (oldLtX == oldRbX) { XDrawLine(mainDisplay, hRuleWindow, revDefaultGC, oldLtX-1, 0, oldLtX-1, rulerLen); } else if (oldLtX==oldMdX || oldRbX==oldMdX) { XDrawLine(mainDisplay, hRuleWindow, revDefaultGC, oldLtX-1, 0, oldLtX-1, rulerLen); XDrawLine(mainDisplay, hRuleWindow, revDefaultGC, oldRbX-1, 0, oldRbX-1, rulerLen); } else { XDrawLine(mainDisplay, hRuleWindow, revDefaultGC, oldLtX-1, 0, oldLtX-1, rulerLen); XDrawLine(mainDisplay, hRuleWindow, revDefaultGC, oldMdX-1, 0, oldMdX-1, rulerLen); XDrawLine(mainDisplay, hRuleWindow, revDefaultGC, oldRbX-1, 0, oldRbX-1, rulerLen); } if (oldLtY == oldRbY) { XDrawLine(mainDisplay, vRuleWindow, revDefaultGC, 0, oldLtY-1, rulerLen-1, oldLtY); } else if (oldLtY==oldMdY || oldRbY==oldMdY) { XDrawLine(mainDisplay, vRuleWindow, revDefaultGC, 0, oldLtY-1, rulerLen-1, oldLtY); XDrawLine(mainDisplay, vRuleWindow, revDefaultGC, 0, oldRbY-1, rulerLen-1, oldRbY); } else { XDrawLine(mainDisplay, vRuleWindow, revDefaultGC, 0, oldLtY-1, rulerLen, oldLtY-1); XDrawLine(mainDisplay, vRuleWindow, revDefaultGC, 0, oldMdY-1, rulerLen, oldMdY-1); XDrawLine(mainDisplay, vRuleWindow, revDefaultGC, 0, oldRbY-1, rulerLen, oldRbY-1); } if (showCrossHair) { XDrawLine(mainDisplay, drawWindow, revDefaultGC, oldRbX, 0, oldRbX, ZOOMED_SIZE(drawWinH)); XDrawLine(mainDisplay, drawWindow, revDefaultGC, 0, oldRbY, ZOOMED_SIZE(drawWinW), oldRbY); } if (VerboseMeasureTooltip()) { DoIntervalMeasureTooltip(oldLtX, oldLtY, oldRbX, oldRbY, oldMdX, oldMdY, gpszOldDeltaStr); } } void BeginIntervalRulers(ltx, lty, rbx, rby) int ltx, lty, rbx, rby; { DrawHRuleTick(oldXOff-1); DrawVRuleTick(oldYOff-1); if (showCrossHair) { XDrawLine(mainDisplay, drawWindow, revDefaultGC, oldXOff, 0, oldXOff, ZOOMED_SIZE(drawWinH)); XDrawLine(mainDisplay, drawWindow, revDefaultGC, 0, oldYOff, ZOOMED_SIZE(drawWinW), oldYOff); } oldLtX = ltx; oldLtY = lty; oldRbX = rbx; oldRbY = rby; oldMdX = (oldLtX+oldRbX)>>1; oldMdY = (oldLtY+oldRbY)>>1; gpszOldDeltaStr = NULL; if (showMeasurement) FreezeMarkRulerText(); DoIntervalRulers(); } void DrawIntervalRulers(ltx, lty, rbx, rby, delta_str) int ltx, lty, rbx, rby; char *delta_str; { DoIntervalRulers(); oldLtX = ltx; oldLtY = lty; oldRbX = rbx; oldRbY = rby; oldMdX = (oldLtX+oldRbX)>>1; oldMdY = (oldLtY+oldRbY)>>1; if (delta_str != NULL) { gpszOldDeltaStr = UtilStrDup(delta_str); if (gpszOldDeltaStr == NULL) FailAllocMessage(); } DoIntervalRulers(); if (showMeasurement) UnFreezeMarkRulerText(); } void EndIntervalRulers(x, y) int x, y; { DoIntervalRulers(); oldXOff = x; oldYOff = y; UtilFree(gpszOldDeltaStr); gpszOldDeltaStr = NULL; DrawHRuleTick(oldXOff-1); DrawVRuleTick(oldYOff-1); if (showCrossHair) { XDrawLine(mainDisplay, drawWindow, revDefaultGC, oldXOff, 0, oldXOff, ZOOMED_SIZE(drawWinH)); XDrawLine(mainDisplay, drawWindow, revDefaultGC, 0, oldYOff, ZOOMED_SIZE(drawWinW), oldYOff); } MarkRulers(x, y); frozenXOff = oldXOff; frozenYOff = oldYOff; } void StartShowMeasureCursor(XOff, YOff, Str, ExtraSpace) int XOff, YOff, ExtraSpace; char *Str; { if (!showMeasurement) return; MarkRulers(XOff, YOff); FreezeMarkRulerText(); if (Str == NULL || *Str == '\0') return; if (showMeasurementInTooltip) { if (!measureTooltipVerbose) { StartMeasureTooltip(Str); } } else { int x=(ExtraSpace ? XOff+18 : XOff+4), y=YOff+defaultFontAsc; char *c_ptr=strchr(Str, '\n'), *line=Str; while (line != NULL) { if (c_ptr != NULL) *c_ptr = '\0'; XDrawString(mainDisplay, drawWindow, revDefaultGC, x, y, line, strlen(line)); if (c_ptr != NULL) { *c_ptr++ = '\n'; line = c_ptr; c_ptr = strchr(line, '\n'); y += defaultFontHeight; } else { break; } } } } void ShowMeasureCursor(XOff, YOff, Str, ExtraSpace) int XOff, YOff, ExtraSpace; char *Str; { if (!showMeasurement) return; if (Str == NULL || *Str == '\0') return; if (showMeasurementInTooltip) { if (measureTooltipVerbose) { switch (curChoice) { case DRAWARC: case DRAWEDGEARC: case FREEHAND: case ROTATEMODE: SetMeasureTooltip(Str); break; } } else { SetMeasureTooltip(Str); } } else { int x=(ExtraSpace ? XOff+18 : XOff+4), y=YOff+defaultFontAsc; char *c_ptr=strchr(Str, '\n'), *line=Str; while (line != NULL) { if (c_ptr != NULL) *c_ptr = '\0'; XDrawString(mainDisplay, drawWindow, revDefaultGC, x, y, line, strlen(line)); if (c_ptr != NULL) { *c_ptr++ = '\n'; line = c_ptr; c_ptr = strchr(line, '\n'); y += defaultFontHeight; } else { break; } } } } void EndShowMeasureCursor(XOff, YOff, Str, ExtraSpace) int XOff, YOff, ExtraSpace; char *Str; { if (!showMeasurement) return; if (Str == NULL || *Str == '\0') return; if (showMeasurementInTooltip) { if (!measureTooltipVerbose) { StartMeasureTooltip(Str); } } else { int x=(ExtraSpace ? XOff+18 : XOff+4), y=YOff+defaultFontAsc; char *c_ptr=strchr(Str, '\n'), *line=Str; while (line != NULL) { if (c_ptr != NULL) *c_ptr = '\0'; XDrawString(mainDisplay, drawWindow, revDefaultGC, x, y, line, strlen(line)); if (c_ptr != NULL) { *c_ptr++ = '\n'; line = c_ptr; c_ptr = strchr(line, '\n'); y += defaultFontHeight; } else { break; } } } UnFreezeMarkRulerText(); } void ToggleShowMeasurement() { showMeasurement = !showMeasurement; RedrawRulers(); if (showMeasurement) { Msg(TgLoadString(STID_SHOW_MEASUREMENT_ENABLED)); } else { Msg(TgLoadString(STID_SHOW_MEASUREMENT_DISABLED)); } } void ToggleShowMeasurementInTooltip() { showMeasurementInTooltip = !showMeasurementInTooltip; RedrawRulers(); if (showMeasurementInTooltip) { Msg(TgLoadString(STID_SHOW_MEASUREMENT_IN_TT_ENAB)); } else { Msg(TgLoadString(STID_SHOW_MEASUREMENT_IN_TT_DISB)); } EndMeasureTooltip(TRUE); } /* ------------------- Measure Tooltip Related Routines ------------------- */ /* * Some code in the rest of this file is based on the contributed code * by Raphael Dechenaux <raph_d@club-internet.fr>. */ typedef struct tagMeasureTooltipInfo { int ltx, lty, w, h; /* this is for the window */ int bbox_w, bbox_h; /* this is for the text */ int x_padding, y_padding; /* padding around the text */ int mapped; Window win; GC gc; /* configuration parameters -- how to display */ int x_follow_mouse, y_follow_mouse, position_x, position_y; } MeasureTooltipInfo; static MeasureTooltipInfo gmti; static Pixmap tooltipBgPixmap=None; static void CalcMeasureTooltipPosition() { if (gmti.x_follow_mouse || gmti.y_follow_mouse) { Window root_win=None, child_win=None; unsigned int status; int root_x=0, root_y=0; XQueryPointer(mainDisplay, rootWindow, &root_win, &child_win, &root_x, &root_y, &gmti.ltx, &gmti.lty, &status); if (gmti.x_follow_mouse) gmti.ltx += 16; if (gmti.y_follow_mouse) gmti.lty += 16; if (gmti.x_follow_mouse && gmti.y_follow_mouse) { return; } } if (!gmti.x_follow_mouse) { int dpy_w=DisplayWidth(mainDisplay,mainScreen); switch (gmti.position_x) { case ALIGN_L: gmti.ltx = 0; break; case ALIGN_C: gmti.ltx = ((dpy_w-gmti.bbox_w-gmti.x_padding)>>1); break; case ALIGN_R: gmti.ltx = (dpy_w-gmti.bbox_w-(gmti.x_padding<<1)); break; default: gmti.ltx = 0; break; } } if (!gmti.y_follow_mouse) { int dpy_h=DisplayHeight(mainDisplay,mainScreen); switch (gmti.position_y) { case ALIGN_T: gmti.lty = 0; break; case ALIGN_M: gmti.lty = ((dpy_h-gmti.bbox_h-gmti.y_padding)>>1); break; case ALIGN_B: gmti.lty = (dpy_h-gmti.bbox_h-(gmti.y_padding<<1)); break; default: gmti.lty = 0; break; } } } static void SetMeasureTooltipBBox(msg) char *msg; { int bbox_w=0, bbox_h=0; char *psz=NULL, *line=NULL; bbox_h = ((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontHeight : msgFontHeight); line = msg; psz = strchr(line, '\n'); while (line != NULL) { char saved_ch='\0'; int len=0, w=0; if (psz != NULL) { saved_ch = (*psz); *psz = '\0'; } len = strlen(line); if (msgFontSet == NULL && msgFontPtr == NULL) { w = (defaultFontWidth*len); } else { w = MsgTextWidth(msgFontPtr, line, len); } if (w > bbox_w) bbox_w = w; if (psz == NULL) { break; } *psz = saved_ch; line = &psz[1]; psz = strchr(line, '\n'); bbox_h += ((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontHeight : msgFontHeight); } gmti.bbox_w = bbox_w; gmti.bbox_h = bbox_h; gmti.w = bbox_w+((gmti.x_padding)<<1); gmti.h = bbox_h+((gmti.y_padding)<<1); CalcMeasureTooltipPosition(); } void DoIntervalMeasureTooltip(ltx, lty, rbx, rby, mdx, mdy, delta_str) int ltx, lty, rbx, rby, mdx, mdy; char *delta_str; { char w_buf[80], h_buf[80], buf[256]; char lx_buf[80], cx_buf[80], rx_buf[80]; char ty_buf[80], my_buf[80], by_buf[80]; PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(rbx-ltx))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(rby-lty))); PixelToMeasurementUnit(lx_buf, ABS_X(ltx < rbx ? ltx : rbx)); PixelToMeasurementUnit(cx_buf, ABS_X(mdx)); PixelToMeasurementUnit(rx_buf, ABS_X(ltx > rbx ? ltx : rbx)); PixelToMeasurementUnit(ty_buf, ABS_Y(lty < rby ? lty : rby)); PixelToMeasurementUnit(my_buf, ABS_Y(mdy)); PixelToMeasurementUnit(by_buf, ABS_Y(lty > rby ? lty : rby)); if (delta_str != NULL) { sprintf(buf, "lx=%s cx=%s rx=%s\nty=%s my=%s by=%s\nw=%s h=%s\n%s", lx_buf, cx_buf, rx_buf, ty_buf, my_buf, by_buf, w_buf, h_buf, delta_str); } else { sprintf(buf, "lx=%s cx=%s rx=%s\nty=%s my=%s by=%s\nw=%s h=%s", lx_buf, cx_buf, rx_buf, ty_buf, my_buf, by_buf, w_buf, h_buf); } SetMeasureTooltip(buf); } void StartMeasureTooltip(msg) char *msg; { SetMeasureTooltip(msg); } void SetMeasureTooltip(msg) char *msg; { int x=0, y=0; char *psz=NULL, *line=NULL; if (!showMeasurementInTooltip) return; if (!gmti.mapped) { XMapWindow(mainDisplay, gmti.win); gmti.mapped = TRUE; } XRaiseWindow(mainDisplay, gmti.win); SetMeasureTooltipBBox(msg); XMoveResizeWindow(mainDisplay, gmti.win, gmti.ltx, gmti.lty, gmti.w, gmti.h); XClearWindow(mainDisplay, gmti.win); x = gmti.x_padding; y = gmti.y_padding + ((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontAsc : msgFontAsc);; line = msg; psz = strchr(line, '\n'); while (line != NULL) { char saved_ch='\0'; if (psz != NULL) { saved_ch = (*psz); *psz = '\0'; } DrawMsgString(mainDisplay, gmti.win, gmti.gc, x, y, line, strlen(line)); if (psz == NULL) { break; } *psz = saved_ch; line = &psz[1]; psz = strchr(line, '\n'); y += ((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontHeight : msgFontHeight); } } void EndMeasureTooltip(force) int force; { if (force || (showMeasurement && showMeasurementInTooltip)) { if (gmti.mapped) { XUnmapWindow(mainDisplay, gmti.win); gmti.mapped = FALSE; } } } void CleanUpMeasureTooltip() { if (tooltipBgPixmap != None) { XFreePixmap(mainDisplay, tooltipBgPixmap); tooltipBgPixmap = None; } if (gmti.gc != NULL) { XFreeGC(mainDisplay, gmti.gc); } if (gmti.win != None) { XDestroyWindow(mainDisplay, gmti.win); } memset(&gmti, 0, sizeof(MeasureTooltipInfo)); showMeasurementInTooltip = FALSE; gmti.win = None; } static int CreateMeasureTooltipWindow() { int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); XGCValues values; XWMHints wmhints; XSizeHints sizehints; XSetWindowAttributes win_attrs; if ((gmti.win=XCreateSimpleWindow(mainDisplay, rootWindow, 0, 0, 10, 10, 1, myBorderPixel, bg_pixel)) == 0) { return FailToCreateWindowMessage("CreateMeasureTooltipWindow()", NULL, FALSE); } win_attrs.save_under = True; win_attrs.override_redirect = True; win_attrs.colormap = mainColormap; XChangeWindowAttributes(mainDisplay, gmti.win, CWSaveUnder | CWOverrideRedirect | CWColormap, &win_attrs); wmhints.flags = InputHint | StateHint; wmhints.input = True; wmhints.initial_state = NormalState; XSetWMHints(mainDisplay, gmti.win, &wmhints); sizehints.flags = PPosition | PSize | USPosition | PMinSize | PMaxSize; sizehints.x = 0; sizehints.y = 0; sizehints.width = sizehints.min_width = sizehints.max_width = 10; sizehints.height = sizehints.min_height = sizehints.max_height = 10; #ifdef NOTR4MODE XSetNormalHints(mainDisplay, gmti.win, &sizehints); #else XSetWMNormalHints(mainDisplay, gmti.win, &sizehints); #endif XSetTransientForHint(mainDisplay, gmti.win, mainWindow); values.foreground = myFgPixel; values.background = bg_pixel; values.font = (msgFontPtr==NULL ? defaultFontPtr->fid : msgFontPtr->fid); gmti.gc = XCreateGC(mainDisplay, gmti.win, GCForeground | GCBackground | GCFont, &values); return TRUE; } static void CreateLightYellowBackgroundPixmapForTooltip() { XImage *image=NULL; tooltipBgPixmap = XCreatePixmap(mainDisplay, mainWindow, 2, 2, mainDepth); XSetForeground(mainDisplay, xpmGC, myYellowPixel); XFillRectangle(mainDisplay, tooltipBgPixmap, xpmGC, 0, 0, 2, 2); XSetForeground(mainDisplay, xpmGC, myFgPixel); image = XGetImage(mainDisplay, tooltipBgPixmap, 0, 0, 2, 2, AllPlanes, ZPixmap); XPutPixel(image, 0, 0, myWhitePixel); XPutPixel(image, 1, 1, myWhitePixel); XPutImage(mainDisplay, tooltipBgPixmap, xpmGC, image, 0, 0, 0, 0, 2, 2); XDestroyImage(image); XSetWindowBackgroundPixmap(mainDisplay, gmti.win, tooltipBgPixmap); } int InitMeasureTooltip() { char *c_ptr=NULL; tooltipBgPixmap = None; memset(&gmti, 0, sizeof(MeasureTooltipInfo)); gmti.win = None; gmti.mapped = FALSE; gmti.x_padding = 4; gmti.y_padding = 2; showMeasurementInTooltip = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseMeasureTooltip")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { showMeasurementInTooltip = TRUE; } measureTooltipVerbose = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "MeasureTooltipVerbose")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { measureTooltipVerbose = TRUE; } gmti.x_follow_mouse = gmti.y_follow_mouse = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "MeasureTooltipXFollowMouse")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { gmti.x_follow_mouse = TRUE; } if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "MeasureTooltipYFollowMouse")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { gmti.y_follow_mouse = TRUE; } gmti.position_y = ALIGN_T; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "MeasureTooltipVerticalPosition")) != NULL) { if (UtilStrICmp(c_ptr, "top") == 0) { gmti.position_y = ALIGN_T; } else if (UtilStrICmp(c_ptr, "middle") == 0) { gmti.position_y = ALIGN_M; } else if (UtilStrICmp(c_ptr, "bottom") == 0) { gmti.position_y = ALIGN_B; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "MeasureTooltipVerticalPosition", c_ptr, "Top"); fprintf(stderr, "\n"); } } gmti.position_x = ALIGN_L; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "MeasureTooltipHorizontalPosition")) != NULL) { if (UtilStrICmp(c_ptr, "left") == 0) { gmti.position_x = ALIGN_L; } else if (UtilStrICmp(c_ptr, "center") == 0) { gmti.position_x = ALIGN_C; } else if (UtilStrICmp(c_ptr, "right") == 0) { gmti.position_x = ALIGN_R; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "MeasureTooltipHorizontalPosition", c_ptr, "Left"); fprintf(stderr, "\n"); } } if (!CreateMeasureTooltipWindow()) { gmti.win = None; } else if (threeDLook) { CreateLightYellowBackgroundPixmapForTooltip(); } return TRUE; } ��������������������������tgif-QPL-4.2.5/prtgif.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000002472�11602233312�014432� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/prtgif.e,v 1.6 2011/05/16 16:21:59 william Exp $ */ #ifndef _PRTGIF_E_ #define _PRTGIF_E_ extern int lastFile; extern short pDrawFontAsc[]; extern short pDrawFontDes[]; #ifdef _INCLUDE_FROM_PRTGIF_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_PRTGIF_C_*/ /* * extern function declarations */ #ifdef _INCLUDE_FROM_PRTGIF_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_PRTGIF_C_*/ #endif /*_PRTGIF_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/setup.c������������������������������������������������������������������������������0000644�0000764�0000764�00000257273�11602233312�014310� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/setup.c,v 1.86 2011/06/02 17:35:50 cvsps Exp $ */ #define _INCLUDE_FROM_SETUP_C_ #include "tgifdefs.h" #include "cmdids.h" #include "expfdefs.h" #include "attr.e" #include "auxtext.e" #include "chat.e" #include "choice.e" #include "choose.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "edit.e" #include "exec.e" #include "file.e" #include "font.e" #include "grid.e" #include "help.e" #include "imgproc.e" #include "import.e" #include "inmethod.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "markup.e" #include "menu.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "nkf.e" #include "page.e" #include "pattern.e" #include "pin.e" #include "poly.e" #include "ps.e" #include "raster.e" #include "remote.e" #include "ruler.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "shape.e" #include "shortcut.e" #include "special.e" #include "spline.e" #include "stk.e" #include "stretch.e" #include "strtbl.e" #include "tangram2.e" #include "tdgtlist.e" #include "text.e" #include "tgcwheel.e" #include "tginssym.e" #include "tidget.e" #include "util.e" #include "version.e" #include "wb.e" #include "xbitmap.e" #include "xpixmap.e" #include "xprtfltr.e" #include "z_intrf.e" #include "tgificon.xbm" #define DEF_VSBAR_H 64 #define DEF_HSBAR_W 128 #define DRAW_WINDOW_W (5*ONE_INCH) #define DRAW_WINDOW_H (4*ONE_INCH) #define CHOICE_WINDOW_W (12*CHOICE_IMAGE_W) #define CHOICE_WINDOW_H (CHOICE_IMAGE_H<<1) #define VSBAR_H (DRAW_WINDOW_H+RULER_W+(BRDR_W<<1)) #define HSBAR_W 128 #define PAGE_DUMMY_WINDOW_W 3 #define PAGE_WINDOW_W (DRAW_WINDOW_W+RULER_W-HSBAR_W-PAGE_DUMMY_WINDOW_W) #define COLOR_DUMMY_WINDOW_H 3 #define COLOR_WINDOW_H (DRAW_WINDOW_H+RULER_W-VSBAR_H-COLOR_DUMMY_WINDOW_H) #define TITLE_WINDOW_W (DRAW_WINDOW_W+RULER_W+BRDR_W+SCROLLBAR_W+(BRDR_W<<1)) #define TITLE_WINDOW_H (MENU_IMAGE_H<<1) #define MSG_WINDOW_W (TITLE_WINDOW_W-CHOICE_WINDOW_W-(BRDR_W<<1)) #define MSG_WINDOW_H (CHOICE_WINDOW_H) #define ICON_WINDOW_W 64 #define ICON_WINDOW_H 64 #define MENUBAR_WINDOW_W (TITLE_WINDOW_W) #define MENUBAR_WINDOW_H 20 #define USER_REDRAW_WINDOW_W 44 #define USER_REDRAW_WINDOW_H 20 #define STATUS_WINDOW_W (TITLE_WINDOW_W-USER_REDRAW_WINDOW_W-(BRDR_W<<1)) #define STATUS_WINDOW_H 20 #define MODE_WINDOW_W (CHOICE_IMAGE_W) #define MODE_WINDOW_H (DRAW_WINDOW_H+RULER_W+(BRDR_W<<1)) #define CHAT_WINDOW_W (TITLE_WINDOW_W) #define CHAT_WINDOW_H 40 int debugNoPointerGrab=FALSE; int debugCopyPaste=FALSE; unsigned int mainWinW = 0; unsigned int mainWinH = 0; int vSBarH = VSBAR_H; int hSBarW = HSBAR_W; int scrollBarW = SCROLLBAR_W; int rulerW = RULER_W; int brdrW = BRDR_W; int windowPadding = 0; int pageWindowW = PAGE_WINDOW_W; int pageDummyWindowW = PAGE_DUMMY_WINDOW_W; int colorWindowH = COLOR_WINDOW_H; int colorDummyWindowH = COLOR_DUMMY_WINDOW_H; int msgWindowW = MSG_WINDOW_W; int msgWindowH = MSG_WINDOW_H; int choiceImageW = CHOICE_IMAGE_W; int choiceImageH = CHOICE_IMAGE_H; int choiceWindowW = CHOICE_WINDOW_W; int choiceWindowH = CHOICE_WINDOW_H; int menuImageW = MENU_IMAGE_W; int menuImageH = MENU_IMAGE_H; int titleWindowW = TITLE_WINDOW_W; int titleWindowH = TITLE_WINDOW_H; int iconWindowW = ICON_WINDOW_W; int iconWindowH = ICON_WINDOW_H; int menubarWindowW = MENUBAR_WINDOW_W; int menubarWindowH = MENUBAR_WINDOW_H; int userRedrawWindowW = USER_REDRAW_WINDOW_W; int userRedrawWindowH = USER_REDRAW_WINDOW_H; int statusWindowW = STATUS_WINDOW_W; int statusWindowH = STATUS_WINDOW_H; int statusSubWindowW[MAX_STATUS_BTNS]; int statusSubWindowH[MAX_STATUS_BTNS]; int modeWindowW = MODE_WINDOW_W; int modeWindowH = MODE_WINDOW_H; int chatWindowW = CHAT_WINDOW_W; int chatWindowH = CHAT_WINDOW_H; int initialMenubarWindowH=MENUBAR_WINDOW_H; static int statusSubWindowX[MAX_STATUS_BTNS]; static int statusSubWindowY[MAX_STATUS_BTNS]; Display * mainDisplay=NULL; Colormap mainColormap=(Colormap)0; unsigned int mainDepth; int mainScreen; Visual * mainVisual=NULL; Window rootWindow=None; Window mainWindow=None; Window drawWindow=None; Window choiceWindow=None; Window titleWindow=None; Window msgWindow=None; Window vSBarWindow=None; Window hSBarWindow=None; Window vRuleWindow=None; Window hRuleWindow=None; Window iconWindow=None; Window iconBaseWindow=None; Window menubarWindow=None; Window userRedrawWindow=None; Window statusWindow=None; Window modeWindow=None; Window pageWindow=None; Window pageDummyWindow=None; Window colorWindow=None; Window colorDummyWindow=None; Window chatWindow=None; #ifndef A4PAPER int onePageWidth = (85*ONE_INCH)/10; int onePageHeight = 11*ONE_INCH; int paperWidth = (85*ONE_INCH)/10; int paperHeight = 11*ONE_INCH; #else /* A4PAPER */ int onePageWidth = (825*ONE_INCH)/100; int onePageHeight = (117*ONE_INCH)/10; int paperWidth = (825*ONE_INCH)/100; int paperHeight = (117*ONE_INCH)/10; #endif /* A4PAPER */ int drawOrigX = 0; int drawOrigY = 0; int drawWinW = DRAW_WINDOW_W; int drawWinH = DRAW_WINDOW_H; int zoomScale = 0; int zoomedIn = FALSE; struct BBRec drawWinBBox; int colorDisplay = FALSE; int fullTrueColorMode = FALSE; int noAntiAlias = TRUE; int threeDLook = FALSE; int fileModified = FALSE; int objId = 0; int myBgPixel=INVALID; int myFgPixel=INVALID; int myRubberBandPixel=INVALID; int myBorderPixel=INVALID; int myWhitePixel=INVALID; int myBlackPixel=INVALID; int myLtGryPixel=INVALID; int myDkGryPixel=INVALID; int myVryLtPixel=INVALID; int myYellowPixel=INVALID; int reverseVideo = FALSE; char drawPath[MAXPATHLENGTH]; /* last char is NOT '/' */ char bootDir[MAXPATHLENGTH+2]; char homeDir[MAXPATHLENGTH]; char tgifDir[MAXPATHLENGTH]; char tmpDir[MAXPATHLENGTH]; int symPathNumEntries = INVALID; char * * symPath=NULL; int initDrawWinW=INVALID, initDrawWinH=INVALID; short handleSize=3; int resizeTextOnStretch=FALSE; Window dummyWindow1=None, dummyWindow2=None; Window statusSubWindow[MAX_STATUS_BTNS]; int noMenubar=FALSE; int noStatusWindow=FALSE; int noChoiceWindow=FALSE; int noModeWindow=FALSE; int noChatWindow=TRUE; Atom executeCmdByIDAtom=(Atom)0; int curChoiceBeforeMakeQuiescent=NOTHING; int noMinWinSize=TRUE; int canvasWindowOnly=FALSE; int talkToSelfFiledesInitialized=FALSE; int talkToSelfFiledes[2]; Atom compoundTextAtom=(Atom)0; Atom textAtom=(Atom)0; Atom utf8StringAtom=(Atom)0; Atom tgifProtocolAtom=(Atom)0; Atom tmpSelectionAtom=(Atom)0; static Atom wmDeleteWindowAtom=(Atom)0; static Atom targetsAtom=(Atom)0; static int baseScrollBarW=SCROLLBAR_W; void RegisterWM_DELETE_WINDOW(win) Window win; { #ifndef NOTR4MODE XSetWMProtocols(mainDisplay, win, &wmDeleteWindowAtom, 1); #endif } int IsWM_DELETE_WINDOW(pXEvent) XEvent *pXEvent; { if (pXEvent->type == ClientMessage) { char *psz=XGetAtomName(mainDisplay, pXEvent->xclient.message_type); if (psz == NULL) { /* this should not happen, but just in case */ } else if (strcmp("WM_PROTOCOLS", psz) == 0 && pXEvent->xclient.data.l[0] == wmDeleteWindowAtom) { XFree((void*)psz); return TRUE; } if (psz != NULL) XFree((void*)psz); } return FALSE; } void UpdDrawWinWH() { drawWinW = ABS_SIZE(initDrawWinW); drawWinH = ABS_SIZE(initDrawWinH); } void UpdDrawWinBBox() { drawWinBBox.ltx = drawOrigX; drawWinBBox.lty = drawOrigY; drawWinBBox.rbx = drawOrigX + drawWinW-1; drawWinBBox.rby = drawOrigY + drawWinH-1; } #include "xbm/btn1.xbm" static void CalcStatusSubWinGeom() { register int i; int left=0, w=(int)(statusWindowW/3), win_y, right=0, win_h; win_y = 1; if (threeDLook) { win_y += (windowPadding>>1); win_h = statusWindowH-4; } else { win_h = statusWindowH-2-(brdrW<<1); } for (i=0; i < MAX_STATUS_BTNS; i++) { int win_x, win_w; right += w; if (right >= statusWindowW) right = statusWindowW-1; win_x = left+(brdrW<<2)+btn1_width+2+(windowPadding>>1); win_w = right-left-(brdrW*6)-btn1_width-2-(windowPadding>>1); statusSubWindowX[i] = win_x; statusSubWindowY[i] = win_y; statusSubWindowW[i] = win_w; statusSubWindowH[i] = win_h; left += w; } } void InitWinSizes() { int choice_cols=(CHOICE_WINDOW_W/choiceImageW); int choice_rows=(CHOICE_WINDOW_H/choiceImageH); int min_draw_win_w=0; initDrawWinW = drawWinW; initDrawWinH = drawWinH; choiceWindowW = CHOICE_WINDOW_W+windowPadding*(choice_cols+2); choiceWindowH = CHOICE_WINDOW_H+windowPadding*(choice_rows+2); msgWindowW = ((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontWidth : msgFontWidth) + (windowPadding<<1); msgWindowH = choiceWindowH; titleWindowH = (((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontHeight : msgFontHeight) << (showVersion ? 1 : 0)) + windowPadding + 4; userRedrawWindowH = statusWindowH; rulerW = RULER_W + windowPadding; scrollBarW = baseScrollBarW+windowPadding; modeWindowW = CHOICE_IMAGE_W+windowPadding+(windowPadding<<1); if (drawWinH < ONE_INCH) drawWinH = ONE_INCH; min_draw_win_w = choiceWindowW + msgWindowW - (noModeWindow ? 0 : modeWindowW+(brdrW<<1)) - rulerW - scrollBarW; if (drawWinW < min_draw_win_w) drawWinW = min_draw_win_w; modeWindowH = drawWinH+rulerW+(brdrW<<2)+windowPadding; if (threeDLook) { colorDummyWindowH = COLOR_DUMMY_WINDOW_H + windowPadding; pageDummyWindowW = PAGE_DUMMY_WINDOW_W + windowPadding; } pageWindowW = drawWinW+rulerW-hSBarW-pageDummyWindowW; if (pageWindowW <= 0) pageWindowW = 1; colorWindowH = drawWinH+rulerW-DEF_VSBAR_H-colorDummyWindowH; vSBarH = drawWinH+rulerW+(brdrW<<1); titleWindowW = (noModeWindow ? 0 : modeWindowW+(brdrW<<1)) + drawWinW+rulerW+brdrW+scrollBarW+(brdrW<<1); menubarWindowW = titleWindowW; statusWindowW = titleWindowW-userRedrawWindowW-(brdrW<<1); chatWindowW = titleWindowW; CalcMenubarWindowHeight(); msgWindowW = titleWindowW-choiceWindowW-(brdrW<<1); mainWinW = titleWindowW+(brdrW<<1); mainWinH = (noMenubar ? 0 : menubarWindowH+(brdrW<<1)) + (noStatusWindow ? 0 : statusWindowH+(brdrW<<1)) + (noChoiceWindow ? 0 : msgWindowH+(brdrW<<1)) + (noChatWindow ? 0 : chatWindowH+(brdrW<<1)) + titleWindowH+vSBarH+scrollBarW+6*brdrW; if (colorLayers) vSBarH = DEF_VSBAR_H; CalcStatusSubWinGeom(); SetChatWindowGeom(); } void InverseInitWinSizes() /* derive other win sizes from mainWinW and mainWinH */ { titleWindowW = mainWinW-(brdrW<<1); menubarWindowW = titleWindowW; chatWindowW = titleWindowW; statusWindowW = titleWindowW-userRedrawWindowW-(brdrW<<1); CalcMenubarWindowHeight(); msgWindowW = titleWindowW-choiceWindowW-(brdrW<<1); vSBarH = mainWinH - titleWindowH - scrollBarW - 6*brdrW - (noMenubar ? 0 : menubarWindowH+(brdrW<<1)) - (noStatusWindow ? 0 : statusWindowH+(brdrW<<1)) - (noChoiceWindow ? 0 : msgWindowH+(brdrW<<1)) - (noChatWindow ? 0 : chatWindowH+(brdrW<<1)); drawWinH = initDrawWinH = vSBarH-rulerW-(brdrW<<1); drawWinW = initDrawWinW = titleWindowW-scrollBarW-rulerW-(brdrW<<2) - (noModeWindow ? 0 : modeWindowW+(brdrW<<1)); modeWindowH = drawWinH+rulerW+(brdrW<<2); pageWindowW = titleWindowW-scrollBarW-hSBarW-pageDummyWindowW-(brdrW<<2); if (pageWindowW <= 0) pageWindowW = 1; colorWindowH = drawWinH+rulerW-DEF_VSBAR_H-colorDummyWindowH; if (colorLayers) vSBarH = DEF_VSBAR_H; CalcMenubarWindowHeight(); CalcStatusSubWinGeom(); SetChatWindowGeom(); } void ComputeMainWinXY(MainWinX, MainWinY) int *MainWinX, *MainWinY; { int win_x, win_y, done = FALSE; unsigned int win_w, win_h, win_brdr_w, win_d, num_child; Window win=mainWindow, root_win, parent_win, *child_wins; *MainWinX = *MainWinY = 0; while (!done) { XGetGeometry(mainDisplay, win, &root_win, &win_x, &win_y, &win_w, &win_h, &win_brdr_w, &win_d); *MainWinX += win_x; *MainWinY += win_y; if (XQueryTree(mainDisplay, win, &root_win, &parent_win, &child_wins, &num_child) == 0) { return; } if (child_wins != NULL) XFree((void *)child_wins); if (parent_win == rootWindow) { done = TRUE; } else { win = parent_win; } } } static void DoReconfigure() { int cur_y=0, x_offset=(noModeWindow ? 0 : modeWindowW+(brdrW<<1)); int draw_win_x_offset=0, draw_win_y_offset=0; XResizeWindow(mainDisplay, titleWindow, titleWindowW, titleWindowH); cur_y += titleWindowH + (brdrW<<1); if (!noMenubar) { XResizeWindow(mainDisplay, menubarWindow, menubarWindowW, menubarWindowH); cur_y += menubarWindowH + (brdrW<<1); } if (!noChoiceWindow) { XMoveWindow(mainDisplay, choiceWindow, 0, cur_y); if (msgWindowW > 0) { XMoveResizeWindow(mainDisplay, msgWindow, choiceWindowW+(brdrW<<1), cur_y, msgWindowW, msgWindowH); } else { XMoveWindow(mainDisplay, msgWindow, choiceWindowW+(brdrW<<1), cur_y); } cur_y += msgWindowH + (brdrW<<1); } if (!noModeWindow) { XMoveResizeWindow(mainDisplay, modeWindow, 0, cur_y, modeWindowW, modeWindowH); } XMoveResizeWindow(mainDisplay, dummyWindow1, x_offset, cur_y, rulerW, rulerW); XMoveResizeWindow(mainDisplay, hRuleWindow, x_offset+rulerW+(brdrW<<1), cur_y, drawWinW, rulerW-windowPadding); if (colorLayers) { XMoveResizeWindow(mainDisplay, colorWindow, x_offset+drawWinW+rulerW+(brdrW<<2), cur_y, scrollBarW, colorWindowH); XMoveWindow(mainDisplay, colorDummyWindow, x_offset+drawWinW+rulerW+(brdrW<<2), cur_y+colorWindowH+(brdrW<<1)); XMoveResizeWindow(mainDisplay, vSBarWindow, x_offset+drawWinW+rulerW+(brdrW<<2), cur_y+colorWindowH+colorDummyWindowH+(brdrW<<2), scrollBarW, DEF_VSBAR_H); } else { XMoveResizeWindow(mainDisplay, vSBarWindow, x_offset+drawWinW+rulerW+(brdrW<<2), cur_y, scrollBarW, vSBarH); } cur_y += rulerW + (brdrW<<1); XMoveResizeWindow(mainDisplay, vRuleWindow, x_offset, cur_y, rulerW-windowPadding, drawWinH); XMoveResizeWindow(mainDisplay, drawWindow, x_offset+rulerW+(brdrW<<1), cur_y, drawWinW, drawWinH); if (inSlideShow) { draw_win_x_offset = x_offset+rulerW+(brdrW<<1); draw_win_y_offset = cur_y; } cur_y += drawWinH + (brdrW<<1); if (pageWindowW > 0) { XMoveResizeWindow(mainDisplay, pageWindow, 0, cur_y, pageWindowW, scrollBarW+(brdrW<<1)); MakeCurPageTabVisible(); } else { XMoveWindow(mainDisplay, pageWindow, 0, cur_y); } XMoveWindow(mainDisplay, pageDummyWindow, pageWindowW, cur_y); XMoveWindow(mainDisplay, hSBarWindow, pageWindowW+pageDummyWindowW+(brdrW<<1), cur_y); XMoveWindow(mainDisplay, dummyWindow2, x_offset+drawWinW+rulerW+(brdrW<<2), cur_y); cur_y += scrollBarW + (brdrW<<1); if (!noStatusWindow) { int i; XMoveWindow(mainDisplay, userRedrawWindow, 0, cur_y); XMoveResizeWindow(mainDisplay, statusWindow, userRedrawWindowW+(brdrW<<1), cur_y, statusWindowW, statusWindowH); for (i=0; i < MAX_STATUS_BTNS; i++) { XMoveResizeWindow(mainDisplay, statusSubWindow[i], statusSubWindowX[i], statusSubWindowY[i], statusSubWindowW[i], statusSubWindowH[i]); } cur_y += statusWindowH + (brdrW<<1); } if (!noChatWindow) { MoveResizeChatWindow(0, cur_y, chatWindowW, chatWindowH); cur_y += chatWindowH + (brdrW<<1); } if (inSlideShow) { int dpy_w=DisplayWidth(mainDisplay,mainScreen); int dpy_h=DisplayHeight(mainDisplay,mainScreen); int x_off=((dpy_w-ZOOMED_SIZE(onePageWidth))>>1); int y_off=((dpy_h-ZOOMED_SIZE(onePageHeight))>>1); int new_x=slideShowXOffset+x_off; int new_y=slideShowYOffset+y_off; int changed=FALSE; XMoveResizeWindow(mainDisplay, drawWindow, new_x+draw_win_x_offset, new_y+draw_win_y_offset, ZOOMED_SIZE(onePageWidth)-(slideShowXOffset<<1), ZOOMED_SIZE(onePageHeight-(slideShowYOffset<<1))); if (ZOOMED_SIZE(onePageWidth) > drawWinW) { drawWinW = ZOOMED_SIZE(onePageWidth); changed = TRUE; } if (ZOOMED_SIZE(onePageHeight) > drawWinH) { drawWinH = ZOOMED_SIZE(onePageHeight); changed = TRUE; } if (changed) { InitWinSizes(); } } } void Reconfigure(Forced) int Forced; { int i; Window root_win; int win_x, win_y, main_win_x, main_win_y; unsigned int win_w, win_h, win_brdr_w, win_d; XEvent ev; ComputeMainWinXY(&main_win_x, &main_win_y); XGetGeometry(mainDisplay, mainWindow, &root_win, &win_x, &win_y, &win_w, &win_h, &win_brdr_w, &win_d); if (!iconWindowShown && !Forced && win_w == mainWinW && win_h == mainWinH) { SaveStackingOrder(); if (pinnedMainMenu) { MoveMainMenuWindow(main_win_x, main_win_y); } else { SaveMainWinPosition(main_win_x, main_win_y); } for (i = 0; i < numStacking; i++) { XMapRaised(mainDisplay, stackingWins[i]); } while (XCheckWindowEvent(mainDisplay, mainWindow, VisibilityChangeMask | StructureNotifyMask, &ev)) ; XFlush(mainDisplay); return; } if (!Forced && !iconWindowShown) { SaveStackingOrder(); for (i = 0; i < numStacking; i++) { XMapRaised(mainDisplay, stackingWins[i]); } } mainWinW = win_w; mainWinH = win_h; menubarWindowW = mainWinW - (brdrW<<1); CalcMenubarWindowHeight(); if (canvasWindowOnly) { initDrawWinW = mainWinW-(brdrW<<1); initDrawWinH = mainWinH-(brdrW<<1); } else { initDrawWinW = mainWinW - rulerW - scrollBarW - 6*brdrW - (noModeWindow ? 0 : modeWindowW+(brdrW<<1)); initDrawWinH = mainWinH - titleWindowH - (noMenubar ? 0 : menubarWindowH+(brdrW<<1)) - (noStatusWindow ? 0 : statusWindowH+(brdrW<<1)) - (noChoiceWindow ? 0 : msgWindowH+(brdrW<<1)) - (noChatWindow ? 0 : chatWindowH+(brdrW<<1)) - rulerW - scrollBarW - 8*brdrW; } drawWinW = initDrawWinW; drawWinH = initDrawWinH; modeWindowH = drawWinH+rulerW+(brdrW<<2); colorWindowH = initDrawWinH+rulerW-DEF_VSBAR_H-colorDummyWindowH-(brdrW<<1); vSBarH = (colorLayers ? DEF_VSBAR_H : initDrawWinH + rulerW + (brdrW<<1)); if (noModeWindow) { pageWindowW = initDrawWinW+rulerW-hSBarW-pageDummyWindowW; titleWindowW = initDrawWinW + rulerW + scrollBarW + (brdrW<<2); } else { pageWindowW = initDrawWinW+rulerW+modeWindowW+(brdrW<<1)-hSBarW- pageDummyWindowW; titleWindowW = initDrawWinW + rulerW + modeWindowW + scrollBarW + (brdrW*6); } if (pageWindowW <= 0) pageWindowW = 1; menubarWindowW = titleWindowW; chatWindowW = titleWindowW; if (!noChatWindow) SetChatWindowGeom(); statusWindowW = titleWindowW-userRedrawWindowW-(brdrW<<1); CalcMenubarWindowHeight(); msgWindowW = titleWindowW - choiceWindowW - (brdrW<<1); CalcStatusSubWinGeom(); if (canvasWindowOnly) { XResizeWindow(mainDisplay, drawWindow, drawWinW, drawWinH); } else { DoReconfigure(); } UpdDrawWinWH(); UpdDrawWinBBox(); UpdScrollWinWH(); SetDefaultDrawWinClipRecs(); SaveMainWinPosition(main_win_x, main_win_y); } int TgHandleCmdEvent(pXEv) XEvent *pXEv; /* must call TgIsCmdEvent() right before calling this function */ { return ExecuteCmdById((int)(pXEv->xclient.data.s[1]), (int)(pXEv->xclient.data.s[2])); } int TgIsCmdEvent(pXEv) XEvent *pXEv; { if (pXEv->xany.window == mainWindow && pXEv->type == ClientMessage) { if (executeCmdByIDAtom == pXEv->xclient.message_type && pXEv->xclient.data.s[0] == TG_COMMAND) { return TRUE; } } return FALSE; } static void HandleSelectionClear(input) XEvent *input; { Window win=(Window)0; Atom selection=(Atom)0; Time time; win = input->xselectionclear.window; selection = input->xselectionclear.selection; time = input->xselectionclear.time; if (debugCopyPaste) { static int id=0; char *atom_name=NULL; printf("\n%1d: SelectionClear.\n", ++id); atom_name = XGetAtomName(mainDisplay, selection); printf("%1d: Selection name is '%s'.\n", id, atom_name); XFree(atom_name); } if (startSelectionOwnershipTimeValid) { endSelectionOwnershipTime = time; endSelectionOwnershipTimeValid = TRUE; } ClearSelection(); } static void DebugSelectRequest(property, target, level, msg) Atom property, target; int level; char *msg; { if (debugCopyPaste > level) { /* * After tgif does a Copy, tgif will get SelectionRequest at * a regular interval */ static int id=0; char *atom_name=NULL; if (msg == NULL) { printf("\n%1d: SelectionRequest.\n", ++id); } else { printf("\n%1d: SelectionRequest (%s).\n", ++id, msg); } atom_name = XGetAtomName(mainDisplay, property); printf("%1d: Property name is '%s'.\n", id, atom_name); XFree(atom_name); atom_name = XGetAtomName(mainDisplay, target); printf("%1d: Target name is '%s'.\n", id, atom_name); XFree(atom_name); } } void HandleSelectionRequest(input) XEvent *input; { Window requestor=(Window)0; Atom property=(Atom)0, target=(Atom)0, selection=(Atom)0; Time time=(Time)0; XEvent sent_ev; unsigned char empty_buf[1]; *empty_buf = '\0'; requestor = input->xselectionrequest.requestor; selection = input->xselectionrequest.selection; target = input->xselectionrequest.target; property = input->xselectionrequest.property; time = input->xselectionrequest.time; /* do not translate -- program constants */ DebugSelectRequest(property, target, 1, "function entry point"); memset(&sent_ev, 0, sizeof(XEvent)); sent_ev.xselection.type = SelectionNotify; sent_ev.xselection.display = mainDisplay; sent_ev.xselection.requestor = requestor; sent_ev.xselection.selection = selection; sent_ev.xselection.time = input->xselectionrequest.time; sent_ev.xselection.target = target; sent_ev.xselection.property = None; if (target == targetsAtom) { /* * The selection manager is asking tgif what can you convert the * object copied into (i.e., what are the possobiel targets)? */ Atom targets[5]; int num_targets=0; DebugSelectRequest(property, target, 0, "TARGETS"); if (gSetCutBufferInfo.tgif_valid) { targets[num_targets++] = tgifProtocolAtom; } if (gSetCutBufferInfo.utf8_valid) { targets[num_targets++] = utf8StringAtom; } if (gSetCutBufferInfo.text_valid) { targets[num_targets++] = compoundTextAtom; targets[num_targets++] = textAtom; targets[num_targets++] = XA_STRING; } XChangeProperty(mainDisplay, requestor, property, target, 32, PropModeReplace, (unsigned char *)targets, num_targets); sent_ev.xselection.property = property; } else if (target == XA_STRING || target == textAtom) { DebugSelectRequest(property, target, 0, "XA_STRING or TEXT"); if (gSetCutBufferInfo.text_valid) { XChangeProperty(mainDisplay, requestor, property, target, 8, PropModeReplace, (unsigned char *)(gSetCutBufferInfo.text_dyn_str.s), gSetCutBufferInfo.text_dyn_str.sz); } else { XChangeProperty(mainDisplay, requestor, property, target, 8, PropModeReplace, empty_buf, 0); } sent_ev.xselection.property = property; } else if (target == utf8StringAtom) { DebugSelectRequest(property, target, 0, "UTF8_STRING"); if (gSetCutBufferInfo.utf8_valid) { XChangeProperty(mainDisplay, requestor, property, target, 8, PropModeReplace, (unsigned char *)(gSetCutBufferInfo.utf8_dyn_str.s), gSetCutBufferInfo.utf8_dyn_str.sz); } else { XChangeProperty(mainDisplay, requestor, property, target, 8, PropModeReplace, empty_buf, 0); } sent_ev.xselection.property = property; } else if (target == tgifProtocolAtom) { DebugSelectRequest(property, target, 0, "_TGIF_PROTOCOL_ATOM"); if (gSetCutBufferInfo.tgif_valid) { XChangeProperty(mainDisplay, requestor, property, target, 8, PropModeReplace, (unsigned char *)(gSetCutBufferInfo.tgif_dyn_str.s), gSetCutBufferInfo.tgif_dyn_str.sz); } else { XChangeProperty(mainDisplay, requestor, property, target, 8, PropModeReplace, empty_buf, 0); } sent_ev.xselection.property = property; } else if (target == compoundTextAtom) { XTextProperty text_property; if (gSetCutBufferInfo.utf8_valid) { DebugSelectRequest(property, target, 0, "COMPOUND_TEXT for UTF8"); #ifndef _NO_XUTF8FUNCTIONS Xutf8TextListToTextProperty(mainDisplay, &(gSetCutBufferInfo.utf8_dyn_str.s), 1, XCompoundTextStyle, &text_property); #endif /* ~_NO_XUTF8FUNCTIONS */ } else if (gSetCutBufferInfo.text_valid) { DebugSelectRequest(property, target, 0, "COMPOUND_TEXT not UTF8"); XmbTextListToTextProperty(mainDisplay, &(gSetCutBufferInfo.text_dyn_str.s), 1, XCompoundTextStyle, &text_property); } else { char *psz_buf=(char*)empty_buf; DebugSelectRequest(property, target, 0, "COMPOUND_TEXT (none)"); XmbTextListToTextProperty(mainDisplay, &psz_buf, 1, XCompoundTextStyle, &text_property); } XChangeProperty(mainDisplay, requestor, property, target, text_property.format, PropModeReplace, text_property.value, text_property.nitems); sent_ev.xselection.property = property; } XSendEvent(mainDisplay, requestor, False, NoEventMask, &sent_ev); } static XComposeStatus c_stat; int mainWinEventHandler(input) XEvent *input; { register int i; int configure=FALSE; if (inSlideShow && input->type == KeyPress) { char s[80]; KeySym key_sym; int has_ch=FALSE; XKeyEvent *key_ev=(&(input->xkey)); has_ch = XLookupString(key_ev, s, sizeof(s), &key_sym, &c_stat); TranslateKeys(s, &key_sym); if (CharIsESC(key_ev, s, key_sym, &has_ch)) { LeaveSlideShow(); return INVALID; } switch (key_sym) { case XK_Left: PrevSlide(); return INVALID; case XK_KP_Left: PrevSlide(); return INVALID; case XK_Right: NextSlide(); return INVALID; case XK_KP_Right: NextSlide(); return INVALID; default: break; } } else if (input->type == SelectionRequest) { HandleSelectionRequest(input); return INVALID; } else if (input->type == SelectionClear) { HandleSelectionClear(input); return INVALID; } else if (input->type == UnmapNotify) { Iconify(); } else if (input->type == MapNotify) { UnIconify(); } else if (input->type == ConfigureNotify) { #ifdef _DO_BENCHMARK_AT_START static int first_time=TRUE; if (first_time) { SendCommandToSelf(CMDID_BENCHMARK, INVALID); first_time = FALSE; } #endif /* _DO_BENCHMARK_AT_START */ configure = TRUE; } else if (input->type == VisibilityNotify && input->xvisibility.state == VisibilityUnobscured) { if (iconWindowShown) { UnIconify(); } else { SaveStackingOrder(); for (i = 0; i < numStacking; i++) { XMapRaised(mainDisplay, stackingWins[i]); } } } else if (input->type == ClientMessage) { if (executeCmdByIDAtom == input->xclient.message_type && input->xclient.data.s[0] == TG_COMMAND) { return ExecuteCmdById((int)(input->xclient.data.s[1]), (int)(input->xclient.data.s[2])); } else { char *c_ptr=NULL; c_ptr = XGetAtomName(mainDisplay, input->xclient.message_type); if (c_ptr == NULL) { /* this should not happen, but just in case */ } else if (strcmp("WM_MOVED", c_ptr) == 0) { configure = TRUE; } else if (strcmp("WM_PROTOCOLS", c_ptr) == 0 && input->xclient.data.l[0] == wmDeleteWindowAtom) { XFree((void*)c_ptr); return QuitProc(); } else if (curChoice == DRAWTEXT && canvasFontDoubleByte && textCursorShown && tgIMExpectClientMessage(mainDisplay, mainWindow)) { char buf[80]; XKeyEvent key_ev; *buf = '\0'; memset(&key_ev, 0, sizeof(XKeyEvent)); key_ev.type = KeyPress; key_ev.display = mainDisplay; key_ev.window = drawWindow; key_ev.root = rootWindow; key_ev.same_screen = 1; if (tgIMHandleClientMessage(mainDisplay, mainWindow, &(input->xclient), &key_ev, buf)) { int has_ch=TRUE; KeySym key_sym=(KeySym)0; if (((*buf) & 0x80) != '\0') { key_sym = XK_space; has_ch = strlen(buf); } else { key_sym = (KeySym)(key_ev.keycode); TranslateKeys(buf, &key_sym); } /* * This is probably not needed. * * ClearCopyUTF8Info(); * if (textHighlight) { * if (!CanCopyHighLightedTextAsUTF8Strings(NULL)) { * ClearCopyUTF8Info(); * } else if (gstCopyUTF8Info.double_byte_valid && * !gstCopyUTF8Info.single_byte_valid) { * CalcSingleByteInfoForCopyUTF8(NULL); * } * } */ HandleTextFromBuffer(&key_ev, buf, key_sym, has_ch); } } else { sprintf(gszMsgBox, "mainWindow ClientMessage: '%s'.", c_ptr); Msg(gszMsgBox); } if (c_ptr != NULL) XFree((void*)c_ptr); } } if (configure) Reconfigure(FALSE); if (showCrossHair) { SetNullCursor(drawWindow); } return INVALID; } void CleanUpPaperSize() { if (psPageHeightInInch != NULL) free(psPageHeightInInch); if (psPageWidthInInch != NULL) free(psPageWidthInInch); if (psYOff != NULL) free(psYOff); if (psYOffStr != NULL) { free(psYOffStr[0]); free(psYOffStr[1]); free(psYOffStr); } psYOffStr = NULL; psYOff = psPageWidthInInch = psPageHeightInInch = NULL; } void InitPaperSize() { float fval=(float)0; if (psYOffStr != NULL) CleanUpPaperSize(); psYOffStr = (char**)malloc(MAXPAGESTYLES*sizeof(char *)); if (psYOffStr == NULL) FailAllocMessage(); psYOffStr[0] = (char*)malloc(20*sizeof(char)); psYOffStr[1] = (char*)malloc(2*sizeof(char)); if (psYOffStr[0] == NULL || psYOffStr[1] == NULL) FailAllocMessage(); fval = (float)(((float)onePageHeight)/((float)ONE_INCH)); FormatFloat(&fval, psYOffStr[0]); sprintf(psYOffStr[1], "0"); psYOff = (float*)malloc(MAXPAGESTYLES*sizeof(float)); if (psYOff == NULL) FailAllocMessage(); psYOff[0] = ((float)onePageHeight)/((float)ONE_INCH); psYOff[1] = (float)0.0; psPageWidthInInch = (float*)malloc(MAXPAGESTYLES*sizeof(float)); if (psPageWidthInInch == NULL) FailAllocMessage(); psPageWidthInInch[0] = ((float)onePageWidth)/((float)ONE_INCH); psPageWidthInInch[1] = ((float)onePageHeight)/((float)ONE_INCH); psPageHeightInInch = (float*)malloc(MAXPAGESTYLES*sizeof(float)); if (psPageHeightInInch == NULL) FailAllocMessage(); psPageHeightInInch[0] = ((float)onePageHeight)/((float)ONE_INCH); psPageHeightInInch[1] = ((float)onePageWidth)/((float)ONE_INCH); } static Pixmap wmIconPixmap=None, wmIconPixmapMask=None; static int GetWMIconPixmap(pPixmap, pPixmapMask) Pixmap *pPixmap, *pPixmapMask; { Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; int rc=0, image_w=0, image_h=0, w=0, h=0, ncolors=0, chars_per_pixel=0; int first_pixel_is_bg=FALSE, *pixels=NULL; char fname[MAXPATHLENGTH], *color_char=NULL, **color_str=NULL; char *xpm_data=NULL; char *c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "WMIconPixmap"); *pPixmap = *pPixmapMask = None; if (c_ptr == NULL) return FALSE; if (*c_ptr == DIR_SEP) { strncpy(fname, c_ptr, sizeof(fname)); } else { sprintf(fname, "%s%c%s", drawPath, DIR_SEP, c_ptr); } c_ptr = UtilStrRChr(fname, '.'); if (c_ptr != NULL && UtilStrICmp(c_ptr, ".xpm") == 0) { rc = MyReadPixmapFile(fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); } else { int x_hot=0, y_hot=0; unsigned int tmp_w=0, tmp_h=0; rc = XReadBitmapFile(mainDisplay, mainWindow, fname, &tmp_w, &tmp_h, &pixmap, &x_hot, &y_hot); } if (rc != BitmapSuccess) { fprintf(stderr, TgLoadCachedString(CSTID_FAIL_READ_ICONPXMP_USE_BMP), fname); fprintf(stderr, "\n"); return FALSE; } if (image != NULL) XDestroyImage(image); if (bitmap_image != NULL) XDestroyImage(bitmap_image); if (color_char != NULL) free(color_char); if (color_str != NULL) { int i; for (i=0; i < ncolors; i++) free(color_str[i]); free(color_str); } if (pixels != NULL) free(pixels); *pPixmap = pixmap; *pPixmapMask = bitmap; return TRUE; } void InitTmpDir() { int tmp_dir_in_x_def=FALSE; char *c_ptr=NULL; struct stat stat_buf; if ((c_ptr=getenv("HOME")) == NULL) { strcpy(homeDir, DIR_SEP_STR); } else if (strlen(c_ptr) >= MAXPATHLENGTH-1) { strcpy(homeDir, DIR_SEP_STR); } else { strcpy(homeDir, c_ptr); } sprintf(tgifDir, "%s%c.%s", homeDir, DIR_SEP, TOOL_NAME); memset(&stat_buf, 0, sizeof(struct stat)); if (stat(tgifDir, &stat_buf) != 0) { /* directory does not exist */ if (mkdir(tgifDir, 0755) != 0) { fprintf(stderr, TgLoadString(STID_CANT_CREATE_NAMED_DIRECTORY), tgifDir); fprintf(stderr, "\n"); if (!PRTGIF) { fprintf(stderr, "\t"); fprintf(stderr, TgLoadString(STID_OPR_USING_NAMED_DIR_WILL_FAIL), tgifDir); fprintf(stderr, "\n"); } } } if (*bootDir == '\0') { GetWorkingDirectory(bootDir, sizeof(bootDir)); } if (!PRTGIF || cmdLineOpenDisplay) { /* do not translate -- program constants */ if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "TmpDir")) != NULL) { UtilTrimBlanks(c_ptr); if (*c_ptr == '\0') { fprintf(stderr, TgLoadString(STID_INVALID_DIR_IN_X_DEFAULT), c_ptr, TOOL_NAME, "TmpDir"); fprintf(stderr, "\n"); } else { UtilStrCpyN(tmpDir, sizeof(tmpDir)-1, c_ptr); strcat(tmpDir, DIR_SEP_STR); if (UtilIsDirectory(tmpDir)) { tmp_dir_in_x_def = TRUE; } else { fprintf(stderr, TgLoadString(STID_TMP_DIR_NOT_EXIST_USE_XDEF), tmpDir, TOOL_NAME, "TmpDir"); fprintf(stderr, "\n"); } } } } if (!tmp_dir_in_x_def) { #ifndef _TMP_DIR_IN_HOME_DIR UtilStrCpyN(tmpDir, sizeof(tmpDir), TMP_DIR); if (!PRTGIF || cmdLineOpenDisplay) { if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "TmpDirInHomeDir")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { UtilStrCpyN(tmpDir, sizeof(tmpDir)-1, tgifDir); strcat(tmpDir, DIR_SEP_STR); } } #else /* _TMP_DIR_IN_HOME_DIR */ UtilStrCpyN(tmpDir, sizeof(tmpDir)-1, tgifDir); strcat(tmpDir, DIR_SEP_STR); if (!PRTGIF || cmdLineOpenDisplay) { if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "TmpDirInHomeDir")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { UtilStrCpyN(tmpDir, sizeof(tmpDir), TMP_DIR); } } #endif /* ~_TMP_DIR_IN_HOME_DIR */ } } static int InitAntiAlias() /* * Get here because fullTrueColorMode is TRUE. So, by default, we * will use antialiased fonts, unless Tgif.NoAntialias is set * to TRUE. * Need to add code to talk to the xft server. */ { #ifdef NOT_DEFINED char *c_ptr=NULL; noAntiAlias = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "NoAntialias")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { noAntiAlias = TRUE; } #endif /* NOT_DEFINED */ /* * Add code here to talk to the xft server. */ return TRUE; } void Setup() { int bitmask=0, x_neg_in_def=FALSE, y_neg_in_def=FALSE; int x_in_cmdline=FALSE, y_in_cmdline=FALSE, cur_y=0, i, x_offset=0; int bg_pixel=(-1), def_x_neg=0, def_y_neg=0, paper_size_set=FALSE; char *c_ptr=NULL; double dval=(double)0; XWMHints wmhints; XSizeHints sizehints; XClassHint classhints; *homeDir = *bootDir = *tgifDir = '\0'; debugNoPointerGrab = FALSE; #ifdef _TGIF_DBG if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DebugNoPointerGrab")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { debugNoPointerGrab = TRUE; } #endif /* _TGIF_DBG */ if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "Synchronize")) != NULL) { if (UtilStrICmp(c_ptr, "on") == 0 || UtilStrICmp(c_ptr, "true") == 0) { XSynchronize(mainDisplay, True); } } showVersion = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DontShowVersion")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { showVersion = TRUE; } *printCommand = '\0'; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "PrintCommand")) != NULL) { strcpy(printCommand, c_ptr); } else { #ifdef PRINT_CMD strcpy(printCommand, PRINT_CMD); #else #ifdef VMS strcpy(printCommand, "print"); #else #ifdef SYSV strcpy(printCommand, "lp -dpostscript"); #else strcpy(printCommand, "lpr"); #endif /* SYSV */ #endif /* VMS */ #endif /* PRINT_CMD */ } if (!PRTGIF) *outputDir = '\0'; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "PrintDirectory")) != NULL) { strcpy(outputDir, c_ptr); } whereToPrint = LATEX_FIG; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "WhereToPrint")) != NULL) { if (UtilStrICmp(c_ptr, "Printer") == 0) { whereToPrint = PRINTER; } else if (UtilStrICmp(c_ptr, "EPS") == 0) { whereToPrint = LATEX_FIG; } else if (UtilStrICmp(c_ptr, "PS") == 0) { whereToPrint = PS_FILE; } else if (UtilStrICmp(c_ptr, "Bitmap") == 0) { whereToPrint = XBM_FILE; } else if (UtilStrICmp(c_ptr, "Text") == 0) { whereToPrint = TEXT_FILE; } else if (UtilStrICmp(c_ptr, "EPSI") == 0) { whereToPrint = EPSI_FILE; } else if (UtilStrICmp(c_ptr, "GIF") == 0) { whereToPrint = GIF_FILE; } else if (UtilStrICmp(c_ptr, "HTML") == 0) { whereToPrint = HTML_FILE; } else if (UtilStrICmp(c_ptr, "PDF") == 0) { whereToPrint = PDF_FILE; } else if (UtilStrICmp(c_ptr, "TiffEPSI") == 0 || UtilStrICmp(c_ptr, "WinEPSI") == 0) { whereToPrint = TIFFEPSI_FILE; } else if (UtilStrICmp(c_ptr, "PNG") == 0) { whereToPrint = PNG_FILE; } else if (UtilStrICmp(c_ptr, "JPEG") == 0) { whereToPrint = JPEG_FILE; } else if (UtilStrICmp(c_ptr, "PPM") == 0 || UtilStrICmp(c_ptr, "PBM") == 0) { whereToPrint = PPM_FILE; } else if (UtilStrICmp(c_ptr, "NetList") == 0) { whereToPrint = NETLIST_FILE; } else if (UtilStrICmp(c_ptr, "SVG") == 0) { whereToPrint = SVG_FILE; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "WhereToPrint", c_ptr, "EPS"); fprintf(stderr, "\n"); } } useGray = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"UseGrayScale")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { useGray = TRUE; } } autoPan = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"AutoPanInEditText")) != NULL) { if (UtilStrICmp("false", c_ptr) == 0) { autoPan = FALSE; } } moveMode = UNCONST_MOVE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ConstrainedMove")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { moveMode = CONST_MOVE; } } doubleQuoteDoubleQuote = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DoubleQuoteDoubleQuote")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { doubleQuoteDoubleQuote = TRUE; } } gridSystem = ENGLISH_GRID; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "GridSystem")) != NULL) { if (UtilStrICmp("Metric", c_ptr) == 0) { gridSystem = METRIC_GRID; } } xyEnglishGrid = DEFAULT_ENGLISH_GRID; xyMetricGrid = DEFAULT_METRIC_GRID; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "InitialGrid")) != NULL) { int grid_size=atoi(c_ptr); switch (gridSystem) { case ENGLISH_GRID: if (grid_size < -2 || grid_size > 2) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "InitialGrid", c_ptr, 0); fprintf(stderr, "\n"); } else { xyEnglishGrid = HALF_INCH>>(2-grid_size); } break; case METRIC_GRID: if (grid_size < -1 || grid_size > 2) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "InitialGrid", c_ptr, 0); fprintf(stderr, "\n"); } else { switch (grid_size) { case -1: xyMetricGrid = ONE_MM; break; case 0: xyMetricGrid = TWO_MM; break; case 1: xyMetricGrid = FIVE_MM; break; case 2: xyMetricGrid = ONE_CM; break; } } break; } } splineTol = 9; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"SplineTolerance")) != NULL) { splineTol = atoi(c_ptr); if (splineTol < 3 || splineTol > 13) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "SplineTolerance", c_ptr, 9); fprintf(stderr, "\n"); splineTol = 9; } } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"SplineRubberband")) != NULL) { if (UtilStrICmp(c_ptr, "false") == 0) { sprintf(gszMsgBox, TgLoadString(STID_NAMED_XDEF_IS_OBSOLETE), TOOL_NAME, "SplineRubberband"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } saveTmpOnReturn = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"SaveTmpOnReturn")) != NULL) { if (UtilStrICmp(c_ptr, "false") == 0) { saveTmpOnReturn = FALSE; } } dropObsIconAttrWhenUpdate = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DropObsIconAttrWhenUpdate")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { dropObsIconAttrWhenUpdate = TRUE; } } useRecentDupDistance = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseRecentDupDistance")) != NULL) { if (UtilStrICmp("false", c_ptr) == 0) { useRecentDupDistance = FALSE; } } handleSize = 3; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "HandleSize")) != NULL) { handleSize = atoi(c_ptr); if (handleSize < 2 || handleSize > 6) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "HandleSize", c_ptr, 3); fprintf(stderr, "\n"); handleSize = 3; } } historyDepth = -1; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "HistoryDepth")) != NULL) { historyDepth = atoi(c_ptr); } defaultHistoryDepth = historyDepth; undoRedoRestoreDrawingMode = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UndoRedoRestoreDrawingMode")) != NULL && UtilStrICmp("false", c_ptr) == 0) { undoRedoRestoreDrawingMode = FALSE; } canvasWindowOnly = FALSE; if (cmdLineCWO) { canvasWindowOnly = TRUE; } else if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"CanvasWindowOnly")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { canvasWindowOnly = TRUE; } } btn1Warp = FALSE; if (canvasWindowOnly) { if (cmdLineBtn1Warp) { btn1Warp = TRUE; } else if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "QuickWarp")) != NULL) { if (UtilStrICmp("on", c_ptr) == 0 || UtilStrICmp("true", c_ptr) == 0) { btn1Warp = TRUE; } } else if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "SingleButtonWarp")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { btn1Warp = TRUE; } } } saveCommentsInSaveNew = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "SaveCommentsInSaveNew")) != NULL) { if (UtilStrICmp("false", c_ptr) == 0 ) { saveCommentsInSaveNew = FALSE; } } usePsAdobeString = FALSE; *adobeString = *epsfString = '\0'; #ifdef _USE_PS_ADOBE_STRING { char buf[MAXSTRING]; UtilStrCpyN(buf, sizeof(buf), _USE_PS_ADOBE_STRING); if (!ParsePsAdobeString(buf,&usePsAdobeString,adobeString,epsfString)) { fprintf(stderr, TgLoadString(STID_BAD_COMPILE_OPT_USE_ALT_STR), "_USE_PS_ADOBE_STRING", _USE_PS_ADOBE_STRING, "false"); fprintf(stderr, "\n"); usePsAdobeString = FALSE; *adobeString = *epsfString = '\0'; } } #endif /* _USE_PS_ADOBE_STRING */ if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"UsePsAdobeString")) != NULL) { char tmp_str[80]; usePsAdobeString = FALSE; *adobeString = *epsfString = '\0'; UtilStrCpyN(tmp_str, sizeof(tmp_str), c_ptr); if (!ParsePsAdobeString(tmp_str, &usePsAdobeString, adobeString, epsfString)) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "UsePsAdobeString", tmp_str, "false"); fprintf(stderr, "\n"); usePsAdobeString = FALSE; *adobeString = *epsfString = '\0'; } } groupedTextEditable = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "GroupedTextEditable")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { groupedTextEditable = FALSE; } intrCheckInterval = 10; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"IntrCheckInterval")) != NULL) { intrCheckInterval = atoi(c_ptr); } tiledPageScaling = 0.9; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"TiledPageScaling")) != NULL) { tiledPageScaling = (float)atof(c_ptr); if (tiledPageScaling <= 0.0 || tiledPageScaling > 1.0) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "TiledPageScaling", c_ptr, "0.9"); fprintf(stderr, "\n"); tiledPageScaling = 0.9; } } stickyMenuSelection = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "StickyMenuSelection")) != NULL && UtilStrICmp("false", c_ptr) == 0) { stickyMenuSelection = FALSE; } gridShown = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"InitialShowGrid")) != NULL) { if (UtilStrICmp("false", c_ptr) == 0) { gridShown = FALSE; } } snapOn = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"InitialSnapOn")) != NULL) { if (UtilStrICmp("false", c_ptr) == 0) { snapOn = FALSE; } } noMenubar = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"NoMenubar")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { noMenubar = TRUE; } } noStatusWindow = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"NoStatusWindow")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { noStatusWindow = TRUE; } } noChoiceWindow = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"NoChoiceWindow")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { noChoiceWindow = TRUE; } } if (cmdLineNoModeWindow) { noModeWindow = TRUE; } else { noModeWindow = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"NoModeWindow")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { noModeWindow = TRUE; } } } if (gstWBInfo.do_whiteboard) { if (cmdLineNoChatWindow) { noChatWindow = TRUE; } else { noChatWindow = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"NoChatWindow")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { noChatWindow = TRUE; } } } } scrollBarW = baseScrollBarW = SCROLLBAR_W; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ScrollBarWidth")) != NULL) { baseScrollBarW = atoi(c_ptr); if (baseScrollBarW < 2 || baseScrollBarW > 16) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_RNG_USE_ALT_VAL), TOOL_NAME, "ScrollBarWidth", c_ptr, 2, 16, SCROLLBAR_W); fprintf(stderr, "\n"); baseScrollBarW = SCROLLBAR_W; } } paper_size_set = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"InitialPaperSize")) != NULL) { paper_size_set = SetPaperSize(c_ptr); } if (cmdLineLetter) { paper_size_set = SetPaperSize("letter"); } pageStyle = PORTRAIT; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PageStyleLandscape")) != NULL && UtilStrICmp("true", c_ptr) == 0) { pageStyle = LANDSCAPE; paper_size_set = TRUE; } /* do not translate -- program constants */ wmDeleteWindowAtom = XInternAtom(mainDisplay, "WM_DELETE_WINDOW", False); targetsAtom = XInternAtom(mainDisplay, "TARGETS", False); utf8StringAtom = XInternAtom(mainDisplay, "UTF8_STRING", False); tgifProtocolAtom = XInternAtom(mainDisplay, TGIF_PROTOCOL_ATOM, False); tmpSelectionAtom = XInternAtom(mainDisplay, "TGIF_TMP_SELECTION_ATOM", False); compoundTextAtom = XInternAtom(mainDisplay, "COMPOUND_TEXT", False); textAtom = XInternAtom(mainDisplay, "TEXT", False); executeCmdByIDAtom = XInternAtom(mainDisplay, "TGIF_EXECUTE_CMD_BY_ID", False); InitStrTable(); InitPaperSize(); printMag = (float)100.0; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PercentPrintReduction")) != NULL) { float print_reduction=(float)0.0; if (sscanf(c_ptr, "%f", &print_reduction) != 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "PercentPrintReduction", c_ptr, 100); fprintf(stderr, "\n"); print_reduction = (float)100.0; } if (printMag != print_reduction) { printMag = print_reduction; paper_size_set = TRUE; } } if (paper_size_set) UpdPageStyle(pageStyle); usePaperSizeStoredInFile = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"UsePaperSizeStoredInFile")) != NULL && UtilStrICmp("false", c_ptr) == 0) { usePaperSizeStoredInFile = FALSE; } oneMotionSelectMove = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"OneMotionSelMove")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { oneMotionSelectMove = TRUE; } } queryZoomInPoint = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"QueryZoomInPoint")) != NULL) { if (UtilStrICmp("true",c_ptr)==0 || UtilStrICmp("always",c_ptr)==0) { queryZoomInPoint = TRUE; } else if (UtilStrICmp("no_select",c_ptr) == 0) { queryZoomInPoint = INVALID; } else if (UtilStrICmp("no_query",c_ptr) == 0) { queryZoomInPoint = BAD; } } lineStyle = LS_RIGHT; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"InitialArrowStyle")) != NULL) { if (UtilStrICmp("NONE",c_ptr) == 0) { lineStyle = LS_PLAIN; } else if (UtilStrICmp("RIGHT",c_ptr) == 0) { lineStyle = LS_RIGHT; } else if (UtilStrICmp("LEFT",c_ptr) == 0) { lineStyle = LS_LEFT; } else if (UtilStrICmp("DOUBLE",c_ptr) == 0) { lineStyle = LS_DOUBLE; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "InitialArrowStyle", c_ptr, "RIGHT"); fprintf(stderr, "\n"); } } showPageInEPS = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ShowPageInEPS")) != NULL && UtilStrICmp("false", c_ptr) == 0) { showPageInEPS = FALSE; } oneMotionTimeout = 200; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"OneMotionTimeout")) != NULL) { oneMotionTimeout = atoi(c_ptr); if (oneMotionTimeout < 0 || oneMotionTimeout >= 1000) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_RNG_USE_ALT_VAL), TOOL_NAME, "OneMotionTimeout", c_ptr, 0, 1000, 200); fprintf(stderr, "\n"); oneMotionTimeout = 200; } } minMoveInterval = 0; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MinMoveInterval")) != NULL) { minMoveInterval = atoi(c_ptr); if (minMoveInterval < 0 || minMoveInterval >= 1000) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_RNG_USE_ALT_VAL), TOOL_NAME, "MinMoveInterval", c_ptr, 0, 1000, 0); fprintf(stderr, "\n"); minMoveInterval = 0; } } rotationIncrement = (45<<6); /* initially 45 degrees */ if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"RotationIncrement")) != NULL) { float fval; if (sscanf(c_ptr, "%f", &fval) != 1 || fval < (float)0.0) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "RotationIncrement", c_ptr, 45); fprintf(stderr, "\n"); } else { while (fval < (float)360.0) fval += (float)360.0; while (fval >= (float)360.0) fval -= (float)360.0; fval *= 64.0; rotationIncrement = round(fval); } } stretchableText = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "StretchableText")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { stretchableText = FALSE; } compoundObjWithTextStretchableForPSE = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "CompoundObjWithTextStretchableForPSE")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { compoundObjWithTextStretchableForPSE = TRUE; } SetEditTextSizeValue(0); if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "EditTextSize")) != NULL) { int new_edit_text_size=atoi(c_ptr); if (new_edit_text_size == 0) { } else if (new_edit_text_size < 4 || new_edit_text_size > 34) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_RNG_USE_ALT_VAL), TOOL_NAME, "EditTextSize", c_ptr, 4, 34, 14); fprintf(stderr, "\n"); SetEditTextSizeValue(14); } else { SetEditTextSizeValue(new_edit_text_size); } } tmpFileMode = PSFILE_MOD; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "TmpFileMode")) != NULL) { int nFileMode=0; strcpy(gszMsgBox, c_ptr); UtilTrimBlanks(gszMsgBox); if (*gszMsgBox != '\0' && sscanf(gszMsgBox, "%o", &nFileMode) == 1) { if (nFileMode >= 0) { tmpFileMode = nFileMode; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_OCTVALUE), TOOL_NAME, "TmpFileMode", gszMsgBox, PSFILE_MOD); fprintf(stderr, "\n"); } } } titledPinnedMenu = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "TitledPinnedMenu")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { titledPinnedMenu = FALSE; } gfVectorWarpSoftness = (float)2.0; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"VectorWarpSoftness")) != NULL) { if (sscanf(c_ptr, "%f", &gfVectorWarpSoftness) != 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "VectorWarpSoftness", c_ptr, "2.0"); fprintf(stderr, "\n"); gfVectorWarpSoftness = (float)2.0; } else if (gfVectorWarpSoftness > 4.0 || gfVectorWarpSoftness < 1.0) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_RNG_USE_ALT_STR), TOOL_NAME, "VectorWarpSoftness", c_ptr, "1.0", "4.0", "2.0"); fprintf(stderr, "\n"); gfVectorWarpSoftness = (float)2.0; } } queryPolyNameOnConnect = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "QueryPolyNameOnConnect")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { queryPolyNameOnConnect = FALSE; } shiftForDiagMouseMove = TRUE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ShiftForDiagMouseMove")) != NULL) { if (UtilStrICmp(c_ptr, "true") == 0) { shiftForDiagMouseMove = TRUE; } else if (UtilStrICmp(c_ptr, "false") == 0) { shiftForDiagMouseMove = FALSE; } } useRecentForDiagMouseMove = FALSE; #ifdef RESTRICTED_MOUSE_MOVE useRecentForDiagMouseMove = TRUE; #endif /* RESTRICTED_MOUSE_MOVE */ if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseRecentForDiagMouseMove")) != NULL) { if (UtilStrICmp(c_ptr, "true") == 0) { useRecentForDiagMouseMove = TRUE; } else if (UtilStrICmp(c_ptr, "false") == 0) { useRecentForDiagMouseMove = FALSE; } } flushColormapOnOpen = FALSE; #ifdef USE_FLUSH_COLORMAP flushColormapOnOpen = TRUE; #endif /* USE_FLUSH_COLORMAP */ if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "FlushColormapOnOpen")) != NULL) { if (UtilStrICmp(c_ptr, "true") == 0) { flushColormapOnOpen = TRUE; } else if (UtilStrICmp(c_ptr, "false") == 0) { flushColormapOnOpen = FALSE; } } transPat = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "TransparentPattern")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { transPat = TRUE; } initialMenubarWindowH = MENUBAR_WINDOW_H; *scanFileFullPath = *scanFileName = '\0'; scanLineNum = 0; colorDisplay = (cmdLineBW || DisplayPlanes(mainDisplay,mainScreen)==1 || mainVisual->class==StaticGray) ? FALSE : TRUE; fullTrueColorMode = FALSE; if (colorDisplay && mainVisual->class == TrueColor) { if (HasZlibSupport()) { /* starting with tgif-4.2.3, this is the default */ fullTrueColorMode = TRUE; #ifdef _TGIF_DBG } else { fprintf(stderr, TgLoadString(STID_CANNOT_SET_XDEF_TRUE_NO_ZLIB), TOOL_NAME, "EnableTrueColorImages", TOOL_NAME); fprintf(stderr, "\n"); #endif /* _TGIF_DBG */ } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"EnableTrueColorImages")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { fullTrueColorMode = FALSE; } } noAntiAlias = TRUE; if (fullTrueColorMode) { InitAntiAlias(); } threeDLook = colorDisplay; if (threeDLook && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "3DLook")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { threeDLook = FALSE; } dialogboxUse3DBorder = threeDLook; if (threeDLook && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DialogboxUse3DBorder")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { dialogboxUse3DBorder = FALSE; } if (threeDLook) { windowPadding = WINDOW_PADDING; brdrW = 0; } InitColor(); bg_pixel = (threeDLook ? myLtGryPixel : myBgPixel); if ((c_ptr=getenv("TGIFPATH")) == NULL) { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "TGIFPATH")) != NULL) { strcpy(drawPath, c_ptr); } else { strcpy(drawPath, TGIF_PATH); } } else if (strlen(c_ptr) >= 255) { strcpy(drawPath, TGIF_PATH); } else { strcpy(drawPath, c_ptr); } i = strlen(drawPath); if (drawPath[i-1] == DIR_SEP) drawPath[i-1] = '\0'; InitTmpDir(); enableMouseWheel = TRUE; if (threeDLook && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "EnableMouseWheel")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { enableMouseWheel = FALSE; } btn2PopupMainMenu = TRUE; if (threeDLook && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "Btn2PopupMainMenu")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { btn2PopupMainMenu = FALSE; } defRightMarginEnabled = INVALID; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"EnableRightMargin")) != NULL) { if (UtilStrICmp("true", c_ptr) == 0) { defRightMarginEnabled = TRUE; } else { defRightMarginEnabled = FALSE; } } if (gridSystem == ENGLISH_GRID) { defRightMargin = ONE_INCH; } else { defRightMargin = (ONE_CM<<1)+(ONE_CM>>1); } dval = ((double)defRightMargin) * ((double)100) * ((double)TIK_PER_PIXEL) / ((double)printMag); defRightMargin = round(dval); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"RightMargin")) != NULL) { char spec_buf[40]; UtilStrCpyN(spec_buf, sizeof(spec_buf), c_ptr); UtilTrimBlanks(spec_buf); if (GetDimensionInDouble(spec_buf, TRUE, &dval)) { dval = dval * ((double)100) * ((double)TIK_PER_PIXEL) / ((double)printMag); defRightMargin = round(dval); } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "RightMargin", c_ptr, (gridSystem==ENGLISH_GRID) ? "1 in" : "2.5 cm"); fprintf(stderr, "\n"); } } rightMargin = defRightMargin; rightMarginEnabled = defRightMarginEnabled; rightMarginActive = (rightMarginEnabled == TRUE); InitFonts(); initialMenubarWindowH = defaultFontHeight; if (msgFontSet==NULL && msgFontPtr == NULL) { statusSubWindowH[0] = defaultFontHeight+2+windowPadding; } else { statusSubWindowH[0] = msgFontHeight+2+windowPadding; } statusWindowH = max(statusSubWindowH[0]+(brdrW<<1)+2, btn1_height+2); if (threeDLook) { statusWindowH += windowPadding; } userRedrawWindowH = statusWindowH; InitChat(); chatWindowH = GetInitialChatWindowHeight(); if (threeDLook) { chatWindowH += windowPadding; } noMinWinSize = TRUE; if (threeDLook && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "NoMinWinSize")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { noMinWinSize = FALSE; } if (noMinWinSize) { sizehints.flags = PSize; } else { sizehints.flags = PSize | PMinSize; } sizehints.x = 0; sizehints.y = 0; sizehints.width = mainWinW; sizehints.height = mainWinH; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "Geometry")) != NULL) { bitmask = XParseGeometry(c_ptr, &(sizehints.x), &(sizehints.y), (unsigned int *)&(sizehints.width), (unsigned int *)&(sizehints.height)); if (bitmask & (XValue | YValue)) sizehints.flags |= USPosition; if (bitmask & (WidthValue | HeightValue)) { sizehints.flags |= USSize; drawWinW = sizehints.width; drawWinH = sizehints.height; InitWinSizes(); mainWinW = sizehints.width; mainWinH = sizehints.height; InverseInitWinSizes(); } if (bitmask & XNegative) { x_neg_in_def = TRUE; def_x_neg = sizehints.x; } if (bitmask & YNegative) { y_neg_in_def = TRUE; def_y_neg = sizehints.y; } } if (geometrySpecified && *geometrySpec != '\0') { bitmask = XParseGeometry(geometrySpec, &(sizehints.x), &(sizehints.y), (unsigned int *)&(sizehints.width), (unsigned int *)&(sizehints.height)); if (bitmask & (XValue | YValue)) sizehints.flags |= USPosition; if (bitmask & (WidthValue | HeightValue)) { sizehints.flags |= USSize; drawWinW = sizehints.width; drawWinH = sizehints.height; InitWinSizes(); mainWinW = sizehints.width; mainWinH = sizehints.height; InverseInitWinSizes(); } if (bitmask & XValue) x_in_cmdline = TRUE; if (bitmask & YValue) y_in_cmdline = TRUE; } InitWinSizes(); if (canvasWindowOnly) { noMenubar = TRUE; noStatusWindow = TRUE; noChoiceWindow = TRUE; noModeWindow = TRUE; noChatWindow = TRUE; mainWinW = initDrawWinW; mainWinH = initDrawWinH; switch (gridSystem) { case ENGLISH_GRID: sizehints.min_width = HALF_INCH+3*brdrW; sizehints.min_height = HALF_INCH+3*brdrW; break; case METRIC_GRID: sizehints.min_width = ONE_CM+3*brdrW; sizehints.min_height = ONE_CM+3*brdrW; break; } if (mainWinW > sizehints.min_width) { sizehints.width = mainWinW; } else { sizehints.width = sizehints.min_width = mainWinW; } if (mainWinH > sizehints.min_height) { sizehints.height = mainWinH; } else { sizehints.height = sizehints.min_height = mainWinH; } drawWinW = initDrawWinW = mainWinW-(brdrW<<1); drawWinH = initDrawWinH = mainWinH-(brdrW<<1); if (msgWindowW <= 0) msgWindowW = 1; } else { sizehints.min_width = (noModeWindow ? 0 : modeWindowW+(brdrW<<1))+ choiceWindowW+(brdrW<<2)+defaultFontWidth; sizehints.min_height = (noMenubar ? 0 : menubarWindowH+(brdrW<<1))+ (noStatusWindow ? 0 : statusWindowH+(brdrW<<1))+ (noChoiceWindow ? 0 : msgWindowH+(brdrW<<1))+ (noChatWindow ? 0 : chatWindowH+(brdrW<<1))+ titleWindowH+ONE_INCH+rulerW+scrollBarW+8*brdrW; if (mainWinW > sizehints.min_width) { sizehints.width = mainWinW; } else { mainWinW = sizehints.width = sizehints.min_width; } if (mainWinH > sizehints.min_height) { sizehints.height = mainWinH; } else { mainWinH = sizehints.height = sizehints.min_height; } InverseInitWinSizes(); } if (bitmask & XNegative) { sizehints.x += DisplayWidth(mainDisplay,mainScreen)-mainWinW-1; } else if (!x_in_cmdline && x_neg_in_def) { sizehints.x = def_x_neg+DisplayWidth(mainDisplay,mainScreen)-mainWinW-1; } if (bitmask & YNegative) { sizehints.y += DisplayHeight(mainDisplay,mainScreen)-mainWinH-1; } else if (!y_in_cmdline && y_neg_in_def) { sizehints.y = def_y_neg+DisplayHeight(mainDisplay,mainScreen)-mainWinH-1; } if ((mainWindow=XCreateSimpleWindow(mainDisplay, rootWindow, sizehints.x, sizehints.y, sizehints.width, sizehints.height, brdrW, myBorderPixel, myBgPixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if (gstWBInfo.do_whiteboard) { if ( cmdLineParentWindowID > 0 ) { XReparentWindow(mainDisplay, mainWindow, cmdLineParentWindowID, 0, 0); } } else { if ( cmdLineTgrm2 && cmdLineParentWindowID > 0 ) { XReparentWindow(mainDisplay, mainWindow, cmdLineParentWindowID, 0, 0); } } if (newColormapUsed) { XSetWindowColormap(mainDisplay, mainWindow, mainColormap); } InitMenu(); InitPattern(); InitRuler(); InitNames(); InitStk(); InitXBm(); InitXPm(); CreateCursor(); lastPageNum = 1; InitPage(); InitPins(); InitInputMethods(); InitPS(); if ((titleWindow=XCreateSimpleWindow(mainDisplay, mainWindow, 0, 0, titleWindowW, titleWindowH, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } cur_y += titleWindowH + (brdrW<<1); if ((menubarWindow=XCreateSimpleWindow(mainDisplay, mainWindow, 0, cur_y, menubarWindowW, menubarWindowH, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if (!noMenubar) { cur_y += menubarWindowH + (brdrW<<1); } if ((choiceWindow=XCreateSimpleWindow(mainDisplay, mainWindow, 0, cur_y, choiceWindowW, choiceWindowH, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if ((msgWindow=XCreateSimpleWindow(mainDisplay, mainWindow, choiceWindowW+(brdrW<<1), cur_y, msgWindowW, msgWindowH, brdrW, myBorderPixel, myBgPixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if (!noChoiceWindow) { cur_y += msgWindowH + (brdrW<<1); } InitChoice(); if ((modeWindow=XCreateSimpleWindow(mainDisplay, mainWindow, 0, cur_y, modeWindowW, modeWindowH, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } x_offset = (noModeWindow ? 0 : modeWindowW+(brdrW<<1)); if ((dummyWindow1=XCreateSimpleWindow(mainDisplay, mainWindow, x_offset, cur_y, rulerW, rulerW, 1, myBorderPixel, myBgPixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if ((hRuleWindow=XCreateSimpleWindow(mainDisplay, mainWindow, x_offset+rulerW+(brdrW<<1), cur_y, drawWinW, rulerW-windowPadding, 1, myBorderPixel, myBgPixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if ((colorWindow=XCreateSimpleWindow(mainDisplay, mainWindow, x_offset+(brdrW<<2)+rulerW+drawWinW, cur_y, scrollBarW, colorWindowH, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if ((colorDummyWindow=XCreateSimpleWindow(mainDisplay, mainWindow, x_offset+(brdrW<<2)+rulerW+drawWinW, cur_y+colorWindowH+(brdrW<<1), scrollBarW, colorDummyWindowH, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if ((vSBarWindow=XCreateSimpleWindow(mainDisplay, mainWindow, x_offset+(brdrW<<2)+rulerW+drawWinW, colorLayers ? cur_y+colorWindowH+colorDummyWindowH+(brdrW<<2) : cur_y, scrollBarW, vSBarH, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } cur_y += rulerW + (brdrW<<1); if ((vRuleWindow=XCreateSimpleWindow(mainDisplay, mainWindow, x_offset, cur_y, rulerW-windowPadding, drawWinH, 1, myBorderPixel, myBgPixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if ((drawWindow=XCreateSimpleWindow(mainDisplay, mainWindow, x_offset+rulerW+(brdrW<<1), cur_y, drawWinW, drawWinH, 0, myBorderPixel, myBgPixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } cur_y += drawWinH + (brdrW<<1); if ((pageWindow=XCreateSimpleWindow(mainDisplay, mainWindow, 0, cur_y, pageWindowW, scrollBarW+(brdrW<<1), 0, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if ((pageDummyWindow=XCreateSimpleWindow(mainDisplay, mainWindow, pageWindowW, cur_y, pageDummyWindowW, scrollBarW, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if ((hSBarWindow=XCreateSimpleWindow(mainDisplay, mainWindow, pageWindowW+pageDummyWindowW+(brdrW<<1), cur_y, hSBarW, scrollBarW, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if ((dummyWindow2=XCreateSimpleWindow(mainDisplay, mainWindow, x_offset+rulerW+drawWinW+(brdrW<<2), cur_y, scrollBarW, scrollBarW, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } cur_y += scrollBarW + (brdrW<<1); if ((userRedrawWindow=XCreateSimpleWindow(mainDisplay, mainWindow, 0, cur_y, userRedrawWindowW, userRedrawWindowH, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if ((statusWindow=XCreateSimpleWindow(mainDisplay, mainWindow, userRedrawWindowW+(brdrW<<1), cur_y, statusWindowW, statusWindowH, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } cur_y += statusWindowH + (brdrW<<1); if ((chatWindow=XCreateSimpleWindow(mainDisplay, mainWindow, 0, cur_y, chatWindowW, chatWindowH, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } InitScroll(); CalcStatusSubWinGeom(); for (i=0; i < MAX_STATUS_BTNS; i++) { if ((statusSubWindow[i]=XCreateSimpleWindow(mainDisplay, statusWindow, statusSubWindowX[i], statusSubWindowY[i], statusSubWindowW[i], statusSubWindowH[i], brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } } InitTidget(); InitColorWheel(); InitInsertSymbol(); if (!CreateChatSubWindows()) { FailToCreateWindowMessage("Setup()", NULL, TRUE); } if (!noChatWindow) { cur_y += chatWindowH + (brdrW<<1); } if (!noStatusWindow) { cur_y += statusWindowH + (brdrW<<1); } if (canvasWindowOnly) { XMoveResizeWindow(mainDisplay, drawWindow, 0, 0, drawWinW, drawWinH); XResizeWindow(mainDisplay, mainWindow, mainWinW, mainWinH); } #ifdef NOTR4MODE XSetNormalHints(mainDisplay, mainWindow, &sizehints); #else /* ~NOTR4MODE */ XSetWMNormalHints(mainDisplay, mainWindow, &sizehints); #endif /* NOTR4MODE */ XStoreName(mainDisplay, mainWindow, TOOL_NAME); UpdDrawWinBBox(); InitTitle(); InitStatus(); SetCanvasFont(); InitText(); InitRemote(); InitNavigate(); InitExec(); InitImageProc(); InitImport(); InitHelp(); InitShape(); InitExportFilters(); InitProperties(); InitCutPaste(); InitEdit(); InitMark(); InitVersion(); InitMiniLines(); if (PRTGIF) { return; } #ifndef _NO_NKF InitNKF(); #endif /* ~_NO_NKF */ if (cmdLineTgrm2) { InitTangram2(); } InitShortCut(); InitHtml(); InitRecentFiles(); InitMeasureTooltip(); InitPoly(); InitSpecial(); InitAttr(); InitTalkToSelfFiledes(); #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, mainWindow); XSelectInput(mainDisplay, mainWindow, KeyPressMask | StructureNotifyMask | VisibilityChangeMask | FocusChangeMask); #else XSelectInput(mainDisplay, mainWindow, KeyPressMask | StructureNotifyMask | VisibilityChangeMask | FocusChangeMask); XMapWindow(mainDisplay, mainWindow); #endif XDefineCursor(mainDisplay, mainWindow, defaultCursor); RegisterWM_DELETE_WINDOW(mainWindow); #ifdef MAPBEFORESELECT if (canvasWindowOnly) { XMapWindow(mainDisplay, drawWindow); XSelectInput(mainDisplay, drawWindow, ButtonReleaseMask | ButtonPressMask | PointerMotionMask | KeyPressMask | KeyReleaseMask | ExposureMask | EnterWindowMask | LeaveWindowMask | PropertyChangeMask); } else { XMapWindow(mainDisplay, titleWindow); XSelectInput(mainDisplay, titleWindow, ExposureMask | EnterWindowMask | LeaveWindowMask | ButtonPressMask | PointerMotionMask); if (menubarWindow != None) XMapWindow(mainDisplay, menubarWindow); XSelectInput(mainDisplay, menubarWindow, ExposureMask | EnterWindowMask | LeaveWindowMask | ButtonPressMask | PointerMotionMask); if (!noChoiceWindow) XMapWindow(mainDisplay, msgWindow); XSelectInput(mainDisplay, msgWindow, ButtonPressMask | ButtonReleaseMask | PointerMotionMask | ExposureMask | EnterWindowMask); if (!noChoiceWindow) XMapWindow(mainDisplay, choiceWindow); XSelectInput(mainDisplay, choiceWindow, ButtonReleaseMask | ButtonPressMask | ExposureMask | PointerMotionMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, hRuleWindow); XSelectInput(mainDisplay, hRuleWindow, ButtonPressMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, vRuleWindow); XSelectInput(mainDisplay, vRuleWindow, ButtonPressMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, drawWindow); XSelectInput(mainDisplay, drawWindow, ButtonReleaseMask | ButtonPressMask | PointerMotionMask | KeyPressMask | KeyReleaseMask | ExposureMask | EnterWindowMask | LeaveWindowMask | PropertyChangeMask); if (colorLayers) { XMapWindow(mainDisplay, colorWindow); XSelectInput(mainDisplay, colorWindow, ButtonPressMask | PointerMotionMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, colorDummyWindow); XSelectInput(mainDisplay, colorDummyWindow, ButtonPressMask | ExposureMask | EnterWindowMask); } else { XSelectInput(mainDisplay, colorWindow, ButtonPressMask | PointerMotionMask | ExposureMask | EnterWindowMask); XSelectInput(mainDisplay, colorDummyWindow, ButtonPressMask | ExposureMask | EnterWindowMask); } XMapWindow(mainDisplay, vSBarWindow); XSelectInput(mainDisplay, vSBarWindow, ButtonPressMask | ExposureMask | EnterWindowMask | PointerMotionMask); XMapWindow(mainDisplay, pageWindow); XSelectInput(mainDisplay, pageWindow, ButtonPressMask | PointerMotionMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, pageDummyWindow); XSelectInput(mainDisplay, pageDummyWindow, ButtonPressMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, hSBarWindow); XSelectInput(mainDisplay, hSBarWindow, ButtonPressMask | ExposureMask | EnterWindowMask | PointerMotionMask); XMapWindow(mainDisplay, dummyWindow1); XSelectInput(mainDisplay, dummyWindow1, ButtonPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, dummyWindow2); XSelectInput(mainDisplay, dummyWindow2, ExposureMask | EnterWindowMask); if (!noChatWindow) { XMapWindow(mainDisplay, chatWindow); } MapChatSubWindows(); XSelectInput(mainDisplay, chatWindow, KeyPressMask | ButtonPressMask | ExposureMask | StructureNotifyMask | EnterWindowMask | LeaveWindowMask); if (!noStatusWindow) { XMapWindow(mainDisplay, userRedrawWindow); XSelectInput(mainDisplay, userRedrawWindow, ButtonPressMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, statusWindow); XSelectInput(mainDisplay, statusWindow, ExposureMask | EnterWindowMask); for (i=0; i < MAX_STATUS_BTNS; i++) { XMapWindow(mainDisplay, statusSubWindow[i]); } } else { XSelectInput(mainDisplay, userRedrawWindow, ButtonPressMask | ExposureMask | EnterWindowMask); XSelectInput(mainDisplay, statusWindow, ExposureMask | EnterWindowMask); } if (!noModeWindow) XMapWindow(mainDisplay, modeWindow); XSelectInput(mainDisplay, modeWindow, ButtonPressMask | ExposureMask | PointerMotionMask | EnterWindowMask | LeaveWindowMask); } #else /* ~MAPBEFORESELECT */ if (canvasWindowOnly) { XSelectInput(mainDisplay, drawWindow, ButtonReleaseMask | ButtonPressMask | PointerMotionMask | KeyPressMask | KeyReleaseMask | ExposureMask | EnterWindowMask | LeaveWindowMask | PropertyChangeMask); XMapWindow(mainDisplay, drawWindow); } else { XSelectInput(mainDisplay, titleWindow, ExposureMask | EnterWindowMask | LeaveWindowMask | ButtonPressMask | PointerMotionMask); XMapWindow(mainDisplay, titleWindow); XSelectInput(mainDisplay, menubarWindow, ExposureMask | EnterWindowMask | LeaveWindowMask | ButtonPressMask | PointerMotionMask); if (menubarWindow != None) XMapWindow(mainDisplay, menubarWindow); XSelectInput(mainDisplay, msgWindow, ButtonPressMask | ButtonReleaseMask | PointerMotionMask | ExposureMask | EnterWindowMask); if (!noChoiceWindow) XMapWindow(mainDisplay, msgWindow); XSelectInput(mainDisplay, choiceWindow, ButtonReleaseMask | ButtonPressMask | ExposureMask | PointerMotionMask | EnterWindowMask | LeaveWindowMask); if (!noChoiceWindow) XMapWindow(mainDisplay, choiceWindow); XSelectInput(mainDisplay, hRuleWindow, ButtonPressMask | ButtonReleaseMask | PointerMotionMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, hRuleWindow); XSelectInput(mainDisplay, vRuleWindow, ButtonPressMask | ButtonReleaseMask | PointerMotionMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, vRuleWindow); XSelectInput(mainDisplay, drawWindow, ButtonReleaseMask | ButtonPressMask | PointerMotionMask | KeyPressMask | KeyReleaseMask | ExposureMask | EnterWindowMask | LeaveWindowMask | PropertyChangeMask); XMapWindow(mainDisplay, drawWindow); if (colorLayers) { XSelectInput(mainDisplay, colorWindow, ButtonPressMask | PointerMotionMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, colorWindow); XSelectInput(mainDisplay, colorDummyWindow, ButtonPressMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, colorDummyWindow); } else { XSelectInput(mainDisplay, colorWindow, ButtonPressMask | PointerMotionMask | ExposureMask | EnterWindowMask); XSelectInput(mainDisplay, colorDummyWindow, ButtonPressMask | ExposureMask | EnterWindowMask); } XSelectInput(mainDisplay, vSBarWindow, ButtonPressMask | ExposureMask | EnterWindowMask | PointerMotionMask); XMapWindow(mainDisplay, vSBarWindow); XSelectInput(mainDisplay, pageWindow, ButtonPressMask | PointerMotionMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, pageWindow); XSelectInput(mainDisplay, pageDummyWindow, ButtonPressMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, pageDummyWindow); XSelectInput(mainDisplay, hSBarWindow, ButtonPressMask | ExposureMask | EnterWindowMask | PointerMotionMask); XMapWindow(mainDisplay, hSBarWindow); XSelectInput(mainDisplay, dummyWindow1, ButtonPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, dummyWindow1); XSelectInput(mainDisplay, dummyWindow2, ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, dummyWindow2); XSelectInput(mainDisplay, chatWindow, KeyPressMask | ButtonPressMask | ExposureMask | StructureNotifyMask | EnterWindowMask | LeaveWindowMask); if (!noChatWindow) { XMapWindow(mainDisplay, chatWindow); } MapChatSubWindows(); if (!noStatusWindow) { XSelectInput(mainDisplay, userRedrawWindow, ButtonPressMask | ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, userRedrawWindow); XSelectInput(mainDisplay, statusWindow, ExposureMask | EnterWindowMask); XMapWindow(mainDisplay, statusWindow); for (i=0; i < MAX_STATUS_BTNS; i++) { XMapWindow(mainDisplay, statusSubWindow[i]); } } else { XSelectInput(mainDisplay, userRedrawWindow, ButtonPressMask | ExposureMask | EnterWindowMask); XSelectInput(mainDisplay, statusWindow, ExposureMask | EnterWindowMask); } XSelectInput(mainDisplay, modeWindow, ButtonPressMask | ExposureMask | PointerMotionMask | EnterWindowMask | LeaveWindowMask); if (!noModeWindow) XMapWindow(mainDisplay, modeWindow); } #endif wmhints.flags = InputHint; wmhints.input = True; wmhints.icon_pixmap = None; if (iconWindowCreated) { unsigned int dummy_icon_w, dummy_icon_h; sizehints.flags = PSize | PMinSize | PMaxSize; sizehints.width = sizehints.min_width = sizehints.max_width = iconWindowW+(brdrW<<1); sizehints.height = sizehints.min_height = sizehints.max_height = iconWindowH+(brdrW<<1); wmhints.flags |= IconWindowHint; wmhints.icon_window = iconBaseWindow; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"IconGeometry")) != NULL) { bitmask = XParseGeometry(c_ptr, &(sizehints.x), &(sizehints.y), &dummy_icon_w, &dummy_icon_h); if ((bitmask & XValue) && (bitmask & YValue)) { if (bitmask & XNegative) sizehints.x += DisplayWidth (mainDisplay, mainScreen) - iconWindowW - (brdrW<<1) - 1; if (bitmask & YNegative) sizehints.y += DisplayHeight(mainDisplay, mainScreen) - iconWindowH - (brdrW<<1) - 1; sizehints.flags |= USPosition; wmhints.flags |= IconPositionHint; wmhints.icon_x = sizehints.x; wmhints.icon_y = sizehints.y; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF), TOOL_NAME, "IconGeometry", c_ptr); fprintf(stderr, "\n"); } } #ifdef NOTR4MODE XSetNormalHints(mainDisplay, iconBaseWindow, &sizehints); #else /* ~NOTR4MODE */ XSetWMNormalHints(mainDisplay, iconBaseWindow, &sizehints); #endif /* NOTR4MODE */ } else { if (((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UseWMIconPixmap")) == NULL) || UtilStrICmp(c_ptr, "false") != 0) { wmhints.icon_mask = None; wmhints.initial_state = NormalState; if (!GetWMIconPixmap(&wmIconPixmap, &wmIconPixmapMask)) { wmhints.icon_pixmap = wmIconPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char*)tgificon_bits, tgificon_width, tgificon_height); } else { wmhints.icon_pixmap = wmIconPixmap; if (wmIconPixmapMask != None) { wmhints.icon_mask = wmIconPixmapMask; wmhints.flags |= IconMaskHint; } } wmhints.flags |= IconPixmapHint | StateHint; /* FlushUndoBuffer(); */ } } XSetWMHints(mainDisplay, mainWindow, &wmhints); wmhints.flags = InputHint; wmhints.input = True; XSetWMHints(mainDisplay, drawWindow, &wmhints); memset(&classhints, 0, sizeof(XClassHint)); classhints.res_name = TOOL_NAME; classhints.res_class = TOOL_NAME; #ifdef NOTR4MODE XSetClassHint(mainDisplay, mainWindow, &classhints); #else /* ~NOTR4MODE */ XSetWMProperties(mainDisplay, mainWindow, NULL, NULL, NULL, 0, NULL, NULL, &classhints); #endif /* NOTR4MODE */ } void CleanUpResiduals() { if (wmIconPixmap != None) { XFreePixmap(mainDisplay, wmIconPixmap); wmIconPixmap = None; } if (wmIconPixmapMask != None) { XFreePixmap(mainDisplay, wmIconPixmapMask); wmIconPixmapMask = None; } CleanUpPaperSize(); if (displayName != NULL) { UtilFree(displayName); displayName = NULL; } if (btn1_bits == NULL) { } } int TieLooseEnds() /* returns TRUE if something got created */ /* returns FALSE otherwise */ { if (curChoice == DRAWTEXT) return CreateTextObj(TRUE, TRUE); return FALSE; } void MakeQuiescent() { curChoiceBeforeMakeQuiescent = curChoice; TieLooseEnds(); SetCurChoice(NOTHING); if (topSel != NULL) { HighLightReverse(); RemoveAllSel(); } UpdSelBBox(); } void SetFileModified(modified) int modified; { if (modified != fileModified) { fileModified = modified; if (fileModified && gstWBInfo.do_whiteboard) { SetUnSavableFile(TRUE); } if (!PRTGIF) { RedrawTitleWindow(); } } } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/group.e������������������������������������������������������������������������������0000644�0000764�0000764�00000004157�11602233311�014274� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/group.e,v 1.7 2011/05/16 16:21:57 william Exp $ */ #ifndef _GROUP_E_ #define _GROUP_E_ extern int gnDeleteAttrsWhileUngrouping; #ifdef _INCLUDE_FROM_GROUP_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_GROUP_C_*/ extern struct ObjRec *JustCreateGroupObj ARGS_DECL((void)); extern void CreateGroupObj ARGS_DECL((struct ObjRec *Top, struct ObjRec *Bot)); extern void SaveGroupObj ARGS_DECL((FILE *, struct ObjRec *, int Level)); extern void SaveCompObj ARGS_DECL((FILE *, struct ObjRec *, int Level)); extern void SaveIconObj ARGS_DECL((FILE *, struct ObjRec *, int Level)); extern void SavePinObj ARGS_DECL((FILE *, struct ObjRec *, int Level)); extern void ReadGroupObj ARGS_DECL((FILE *, int Type, struct ObjRec **)); extern void FreeGroupObj ARGS_DECL((struct ObjRec *)); extern void UngroupObj ARGS_DECL((struct ObjRec *ObjPtr, struct SelRec **TopSelPtr, struct SelRec **BotSelPtr)); extern void UngroupSelObj ARGS_DECL((int highlight, int record_cmd)); extern void LockSelObj ARGS_DECL((void)); extern void UnlockSelObj ARGS_DECL((void)); #ifdef _INCLUDE_FROM_GROUP_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_GROUP_C_*/ #endif /*_GROUP_E_*/ �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/font.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000025305�11602233311�014104� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/font.e,v 1.20 2011/05/16 16:21:57 william Exp $ */ #ifndef _FONT_E_ #define _FONT_E_ #define CONVERT_TO_UTF8 (TRUE) #define CONVERT_FROM_UTF8 (FALSE) extern XFontStruct * canvasFontPtr; extern int canvasFontHeight; extern int canvasFontAsc; extern int canvasFontDes; extern int canvasFontDirection; extern int canvasFontDontReencode; extern int canvasFontDoubleByte; extern int canvasFontDoubleByteModBytes; extern int canvasFontDoubleByteVertical; extern int canvasFontSize; extern int canvasFontIsFaked; extern int canvasLineAsc; extern int canvasLineDes; extern XFontStruct * rulerFontPtr; extern int rulerFontWidth; extern int rulerFontHeight; extern int rulerFontAsc; extern int rulerFontDes; extern XFontStruct * defaultFontPtr; extern int defaultFontWidth; extern int defaultFontHeight; extern int defaultFontAsc; extern int defaultFontDes; extern XFontStruct * menuFontPtr; extern int menuFontWidth; extern int menuFontHeight; extern int menuFontAsc; extern int menuFontDes; #ifdef ENABLE_NLS extern XFontSet menuFontSet; extern XFontSet msgFontSet; extern XFontSet boldMsgFontSet; extern XFontSet italicMsgFontSet; extern XFontSet boldItalicMsgFontSet; #else /* ~ENABLE_NLS */ extern char *menuFontSet; extern char *msgFontSet; extern char *boldMsgFontSet; extern char *italicMsgFontSet; extern char *boldItalicMsgFontSet; #endif /* ENABLE_NLS */ extern int boldMsgFontDoubleByte; extern XFontStruct * boldMsgFontPtr; extern int boldMsgFontWidth; extern int boldMsgFontHeight; extern int boldMsgFontAsc; extern int boldMsgFontDes; extern XFontStruct * italicMsgFontPtr; extern int italicMsgFontWidth; extern int italicMsgFontHeight; extern int italicMsgFontAsc; extern int italicMsgFontDes; extern XFontStruct * boldItalicMsgFontPtr; extern int boldItalicMsgFontWidth; extern int boldItalicMsgFontHeight; extern int boldItalicMsgFontAsc; extern int boldItalicMsgFontDes; extern XFontStruct * msgFontPtr; extern int msgFontWidth; extern int msgFontHeight; extern int msgFontAsc; extern int msgFontDes; extern int curFont; extern int curSzUnit, curRealSzUnit; extern int curStyle; extern int textRotation; extern int curUnderlineOn; extern int curOverlineOn; extern int actualCurFont; extern int actualCurSzUnit; extern int actualCurStyle; extern int curUnderlineYOffset; extern int curOverlineYOffset; extern int changePropertiesOfAttrs; extern char * * fontMenuStr; extern char * defFontMenuStr[]; extern char * * sizeMenuStr; extern int * fontSzUnits; extern int numFonts; extern int numFontSizes; extern int changingFontSizeFromRead; extern int allowFontFaceSubstitution; extern char cmdLineDontReencode[]; extern int defaultFontSize; extern int showFontSizeInPoints; extern int substitutedFont; extern int substitutedFontSzUnit; extern int defaultSingleByteFont; extern int gnNumPSFontAliases; extern KeyValInfo *gaPSFontAliases; #ifdef _INCLUDE_FROM_FONT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_FONT_C_*/ extern int IsFontDoubleByte ARGS_DECL((int font_index)); extern int IsDoubleByteFontVertical ARGS_DECL((int font_index, int style)); extern int CanConvertUTF8ToFont ARGS_DECL((int font_index)); extern int CanConvertFontToUTF8 ARGS_DECL((int font_index)); extern int ConvertToOrFromUTF8 ARGS_DECL((int which, int font_index, char **ppsz_cut_buffer)); extern int GetInitialFont ARGS_DECL((void)); extern int SzUnitToFontSize ARGS_DECL((int sz_unit)); extern int SzUnitToPointSize ARGS_DECL((int sz_unit)); extern int BadDoubleByteString ARGS_DECL((char *pszStr, char *pszZero)); extern char * GetPrevChar ARGS_DECL((int nDoubleByte, char *pszStr, char *pszCur)); extern char * GetShowFontChar ARGS_DECL((int FontIndex)); extern void GetCurFontInfoStr ARGS_DECL((char *buf, int buf_sz)); extern XFontStruct *LoadAFontByName ARGS_DECL((char *font_name, int double_byte, int can_debug)); extern void GetPSFontStr ARGS_DECL((int FontIndex, int Style, char *)); extern XFontStruct *LoadASymbolFont ARGS_DECL((int font_size)); extern void MapAliasedPSFontName ARGS_DECL((char *buf, int buf_sz)); extern void SetTextExtentsInfo ARGS_DECL((TextExtentsInfo*)); extern struct StrRec *SegmentDoubleByteString ARGS_DECL((char*)); extern void MyTextExtents ARGS_DECL((XFontStruct *xfs, char *pszStr, int nLen, XCharStruct *pxcs)); extern int MyTextWidth ARGS_DECL((XFontStruct *xfs, char *pszStr, int nLen)); extern void MyDrawString ARGS_DECL((Display*, Drawable, GC gc, int nDepth, int x, int y, char *pszStr, int nLen)); extern Pixmap PaintVertChar ARGS_DECL((TextExtentsInfo*, int nRotate)); extern int ValidCharCode ARGS_DECL((char *)); extern char * CharCodeTranslate ARGS_DECL((char *)); extern void SaveDontReencode ARGS_DECL((FILE*)); extern int ReadDontReencode ARGS_DECL((char*)); extern void SavePSFontAliases ARGS_DECL((FILE*)); extern void SaveDoubleByteModBytes ARGS_DECL((FILE*)); extern void SavePSFontNeedCharSubs ARGS_DECL((FILE*)); extern void SavePSCharSubs ARGS_DECL((FILE*)); extern int ReadPSFontAliases ARGS_DECL((FILE*, char*)); extern int ReadPSFontNeedCharSubs ARGS_DECL((FILE*, char*)); extern int ReadPSCharSubs ARGS_DECL((FILE*, char*)); extern void PrepareMiniLines ARGS_DECL((MiniLinesInfo*)); extern void PrepareEightBitFontInfo ARGS_DECL((void)); extern int NeedEncode ARGS_DECL((char *FontName, int FontIndex, int Style)); extern int GetFontIndex ARGS_DECL((char *FontStr, int Style, int MustFind)); extern int GetFontAndStyle ARGS_DECL((char *FontStr, int *pnFont, int *pnStyle, int MustFind)); extern int GetFontIndexFromPSFontAndStyle ARGS_DECL((char *FontStr, int Style, int *pnDoubleByte, int *pnModified)); extern void CleanUpDontReencode ARGS_DECL((void)); extern void InitDontReencode ARGS_DECL((char*)); extern void InitPSFontCharSubs ARGS_DECL((void)); extern void PrTgifInitBaseFonts ARGS_DECL((void)); extern int GetCurSzUnit ARGS_DECL((void)); extern void PutCurSzUnit ARGS_DECL((int sz_unit)); extern void GetCurFontMsg ARGS_DECL((char*, StrSegInfo*)); extern void CurFontMsg ARGS_DECL((int nShowInMsgWindow, int nShowInStatusWindow, StrSegInfo*)); extern void DumpReEncodeVector ARGS_DECL((FILE*, char *vec_prefix, char *vec_suffix, short *flag_ptr)); extern void DumpEightBitFontInfo ARGS_DECL((FILE*)); extern int GetCompatibleSize ARGS_DECL((int FontDPI, int FontSize)); extern int SetCanvasFont ARGS_DECL((void)); extern int CurFontCheck ARGS_DECL((void)); extern int TrySetCanvasFont ARGS_DECL((int font, int style, int size, int must_find_requested, int *pnGotRequested)); extern void ObjFontInfoToCurFontInfo ARGS_DECL((struct TextRec *)); extern void StrSegInfoToCurFontInfo ARGS_DECL((StrSegInfo*)); extern void InitFonts ARGS_DECL((void)); extern void SaveCurFont ARGS_DECL((void)); extern void RestoreCurFont ARGS_DECL((void)); extern struct PushedFontRec *GetTopFontStk ARGS_DECL((void)); extern struct PushedFontRec *PushCurFont ARGS_DECL((void)); extern void PopCurFont ARGS_DECL((void)); extern void SetPushedFontValue ARGS_DECL((int Which, int Value)); extern int ChangeMiniLinesFontProp ARGS_DECL((MiniLinesInfo*, int which, int value)); extern int ChangeObjTextStyle ARGS_DECL((struct ObjRec *, int Style)); extern void ChangeFontStyle ARGS_DECL((int Style)); extern int ChangeObjTextJust ARGS_DECL((struct ObjRec *, int Just)); extern void ChangeFontJust ARGS_DECL((int Just)); extern int ChangeObjTextUnderline ARGS_DECL((struct ObjRec *, int Underline)); extern void ChangeFontUnderline ARGS_DECL((int Underline)); extern int ChangeObjTextOverline ARGS_DECL((struct ObjRec *, int Overline)); extern void ChangeFontOverline ARGS_DECL((int Overline)); extern int RefreshFontStyleMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateFontStyleMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int StyleMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int GetSizeMenuIndex ARGS_DECL((void)); extern int ChangeObjTextSzUnit ARGS_DECL((struct ObjRec *, int sz_unit)); extern void ChangeFontSize ARGS_DECL((int SizeIndex)); extern int RefreshFontSizeMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateFontSizeMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int SizeMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int ChangeObjTextFont ARGS_DECL((struct ObjRec *, int FontIndex)); extern int ChangeFont ARGS_DECL((int FontIndex, int ForceNewChoice)); extern int RefreshFontMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateFontMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int FontMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int ChangeObjVSpace ARGS_DECL((struct ObjRec *, int VSpace)); extern void ChangeVSpace ARGS_DECL((int VSpace)); extern void ChangeAllSelRealSzUnit ARGS_DECL((int sz_unit, int HighLight)); extern void SetSelFontSize ARGS_DECL((char*)); extern void CleanUpFonts ARGS_DECL((void)); extern void VerifyCompatibleFontIndex ARGS_DECL((int*)); extern void GetCompatibleFontName ARGS_DECL((int old_font_index, int style, char *font_str)); #ifdef _INCLUDE_FROM_FONT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_FONT_C_*/ #endif /*_FONT_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/���������������������������������������������������������������������������������0000755�0000764�0000764�00000000000�11602233315�013555� 5����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lt0.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014776� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lt0.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lt0_width 64 #define lt0_height 20 #define lt0_x_hot 0 #define lt0_y_hot 0 static unsigned char lt0_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw0s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015157� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw0s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw0s_width 32 #define lw0s_height 20 #define lw0s_x_hot 0 #define lw0s_y_hot 0 static unsigned char lw0s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x97, 0x8a, 0x00, 0x00, 0x92, 0x9a, 0x00, 0x00, 0xf2, 0xaa, 0x00, 0x00, 0x92, 0xaa, 0x00, 0x00, 0x92, 0xca, 0x00, 0x00, 0x92, 0x8a, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lt2.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�015000� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lt2.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lt2_width 64 #define lt2_height 20 #define lt2_x_hot 0 #define lt2_y_hot 0 static unsigned char lt2_bits[] = { 0x00, 0xc0, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd8, 0x01, 0x00, 0x00, 0xc0, 0x1f, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x3c, 0xe0, 0x39, 0x00, 0x02, 0x00, 0x00, 0x80, 0x03, 0x00, 0x7e, 0x00, 0x01, 0x00, 0x00, 0x70, 0x00, 0x00, 0x7c, 0x00, 0x01, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x7c, 0x80, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x38, 0x00, 0x01, 0x00, 0x9c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x3e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0xc0, 0x1d, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_ns.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016075� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_ns.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_ns_width 32 #define align_ns_height 20 #define align_ns_x_hot 0 #define align_ns_y_hot 0 static unsigned char align_ns_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x7f}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape2.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015462� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape2.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape2_width 32 #define shape2_height 20 #define shape2_x_hot 0 #define shape2_y_hot 0 static unsigned char shape2_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x20, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x08, 0x10, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_n.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674124�015705� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_n.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_n_width 32 #define align_n_height 20 #define align_n_x_hot 0 #define align_n_y_hot 0 static unsigned char align_n_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x1f, 0x00, 0x00, 0xfc, 0x1f, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0xf0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ls3s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015156� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ls3s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ls3s_width 32 #define ls3s_height 20 #define ls3s_x_hot 0 #define ls3s_y_hot 0 static unsigned char ls3s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x10, 0x00, 0x00, 0x06, 0x60, 0x00, 0x80, 0x01, 0x80, 0x01, 0x60, 0x00, 0x00, 0x06, 0xf8, 0xff, 0xff, 0x1f, 0x60, 0x00, 0x00, 0x06, 0x80, 0x01, 0x80, 0x01, 0x00, 0x06, 0x60, 0x00, 0x00, 0x08, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld0s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015134� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld0s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld0s_width 32 #define ld0s_height 20 #define ld0s_x_hot 0 #define ld0s_y_hot 0 static unsigned char ld0s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x39, 0xd1, 0x03, 0x20, 0x44, 0x51, 0x04, 0xe0, 0x44, 0x51, 0x04, 0x00, 0x45, 0x51, 0x04, 0x00, 0x45, 0x51, 0x04, 0xe0, 0x38, 0xd7, 0x03, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw2s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015161� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw2s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw2s_width 32 #define lw2s_height 20 #define lw2s_x_hot 0 #define lw2s_y_hot 0 static unsigned char lw2s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/special.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015717� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/special.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define special_width 32 #define special_height 20 #define special_x_hot 0 #define special_y_hot 0 static unsigned char special_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0xe0, 0x0f, 0x00, 0x00, 0xe0, 0x0f, 0x00, 0x00, 0xe0, 0x0f, 0x00, 0x00, 0xe0, 0x0f, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape7.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015467� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape7.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape7_width 32 #define shape7_height 20 #define shape7_x_hot 0 #define shape7_y_hot 0 static unsigned char shape7_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x0c, 0x30, 0x00, 0x00, 0x03, 0xc0, 0x00, 0x80, 0x00, 0x00, 0x01, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x00, 0x03, 0xc0, 0x00, 0x00, 0x0c, 0x30, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/btn1.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000654�10064674124�015146� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/btn1.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define btn1_width 16 #define btn1_height 16 #define btn1_x_hot 0 #define btn1_y_hot 0 static unsigned char btn1_bits[] = { 0xfe, 0x3f, 0x01, 0x40, 0x01, 0x40, 0xdd, 0x5d, 0x5d, 0x55, 0x5d, 0x55, 0x5d, 0x55, 0x5d, 0x55, 0xdd, 0x5d, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0xfe, 0x3f}; ������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/scrl_lf.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000000465�10064674125�015727� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/scrl_lf.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define scrl_lf_width 9 #define scrl_lf_height 9 static unsigned char scrl_lf_bits[] = { 0x00, 0x00, 0x20, 0x00, 0x30, 0x00, 0x38, 0x00, 0x3c, 0x00, 0x38, 0x00, 0x30, 0x00, 0x20, 0x00, 0x00, 0x00}; �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ls2s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015155� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ls2s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ls2s_width 32 #define ls2s_height 20 #define ls2s_x_hot 0 #define ls2s_y_hot 0 static unsigned char ls2s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0x60, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape6.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015466� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape6.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape6_width 32 #define shape6_height 20 #define shape6_x_hot 0 #define shape6_y_hot 0 static unsigned char shape6_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x10, 0x08, 0x00, 0x00, 0x10, 0x08, 0x00, 0x00, 0x10, 0x08, 0x00, 0x00, 0x10, 0x08, 0x00, 0x80, 0x1f, 0xf8, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x1f, 0xf8, 0x01, 0x00, 0x10, 0x08, 0x00, 0x00, 0x10, 0x08, 0x00, 0x00, 0x10, 0x08, 0x00, 0x00, 0x10, 0x08, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/stop.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000002004�10064674125�015257� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/stop.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define stop_width 32 #define stop_height 32 #define stop_x_hot 0 #define stop_y_hot 0 static unsigned char stop_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0xff, 0xff, 0x00, 0x80, 0xff, 0xff, 0x01, 0xc0, 0xff, 0xff, 0x03, 0xe0, 0xff, 0xff, 0x07, 0xf0, 0xff, 0xff, 0x0f, 0xf8, 0xff, 0xff, 0x1f, 0xfc, 0xff, 0xff, 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0x7e, 0x06, 0x73, 0x7c, 0xbe, 0xdd, 0x6d, 0x7b, 0xbe, 0xdd, 0x6d, 0x7b, 0xbe, 0xdf, 0x6d, 0x7b, 0xbe, 0xdf, 0x6d, 0x7b, 0x7e, 0xde, 0x6d, 0x7c, 0xfe, 0xdd, 0x6d, 0x7f, 0xfe, 0xdd, 0x6d, 0x7f, 0xbe, 0xdd, 0x6d, 0x7f, 0xbe, 0xdd, 0x6d, 0x7f, 0xbe, 0xdd, 0x6d, 0x7f, 0x7e, 0xde, 0x73, 0x7f, 0xfe, 0xff, 0xff, 0x7f, 0xfc, 0xff, 0xff, 0x3f, 0xf8, 0xff, 0xff, 0x1f, 0xf0, 0xff, 0xff, 0x0f, 0xe0, 0xff, 0xff, 0x07, 0xc0, 0xff, 0xff, 0x03, 0x80, 0xff, 0xff, 0x01, 0x00, 0xff, 0xff, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ovalcent.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001360�10064674124�016110� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ovalcent.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ovalcent_width 32 #define ovalcent_height 20 #define ovalcent_x_hot 0 #define ovalcent_y_hot 0 static unsigned char ovalcent_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0x0c, 0x60, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x01, 0x00, 0xc1, 0x07, 0x01, 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x01, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x0c, 0x60, 0x01, 0x00, 0x30, 0x18, 0x01, 0x00, 0xc0, 0xc7, 0x07, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_lm.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016065� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_lm.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_lm_width 32 #define align_lm_height 20 #define align_lm_x_hot 0 #define align_lm_y_hot 0 static unsigned char align_lm_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0xc6, 0x1f, 0x00, 0x00, 0x3a, 0x60, 0x00, 0x00, 0x1a, 0x80, 0xff, 0x00, 0x1a, 0x00, 0xd5, 0x00, 0x26, 0x00, 0xaa, 0x00, 0x62, 0x00, 0xd6, 0x00, 0x52, 0x00, 0xaa, 0x00, 0x8a, 0x00, 0xd6, 0x00, 0xc6, 0x01, 0xab, 0x00, 0x22, 0x81, 0xff, 0x00, 0x12, 0x63, 0x00, 0x00, 0x8a, 0x1e, 0x00, 0x00, 0xfe, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_b.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674124�015671� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_b.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_b_width 32 #define align_b_height 20 #define align_b_x_hot 0 #define align_b_y_hot 0 static unsigned char align_b_bits[] = { 0x00, 0xfc, 0x03, 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, 0x0c, 0x0e, 0x00, 0x00, 0xec, 0x0c, 0x00, 0x00, 0x2c, 0x2c, 0x00, 0x00, 0x2c, 0x2c, 0x00, 0x00, 0x0c, 0x2e, 0x00, 0x00, 0xfc, 0x27, 0x00, 0x00, 0xfc, 0x0f, 0x00, 0x00, 0x0c, 0x1c, 0x00, 0x00, 0xec, 0x19, 0x00, 0x00, 0x2c, 0x58, 0x00, 0x00, 0x2c, 0x58, 0x00, 0x00, 0x2c, 0x58, 0x00, 0x00, 0x0c, 0x5c, 0x00, 0x00, 0xfc, 0x4f, 0x00, 0x00, 0xfc, 0x67, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0xf0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_ls.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016073� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_ls.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_ls_width 32 #define align_ls_height 20 #define align_ls_x_hot 0 #define align_ls_y_hot 0 static unsigned char align_ls_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x7f, 0xf8, 0x03, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0xf8, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x7f, 0xf8, 0x03, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0xf8, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x7f, 0xf8, 0x03, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0xf8, 0x03, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x7f}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_m.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674124�015704� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_m.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_m_width 32 #define align_m_height 20 #define align_m_x_hot 0 #define align_m_y_hot 0 static unsigned char align_m_bits[] = { 0x80, 0x01, 0x60, 0x00, 0x80, 0x03, 0x70, 0x00, 0x80, 0x03, 0x70, 0x01, 0x80, 0x07, 0x78, 0x01, 0x80, 0x07, 0x78, 0x01, 0x80, 0x0f, 0x7c, 0x01, 0x80, 0x0d, 0x6e, 0x01, 0x80, 0x19, 0x66, 0x01, 0x80, 0x39, 0x67, 0x01, 0x80, 0x31, 0x63, 0x01, 0x80, 0xf5, 0x6b, 0x01, 0x80, 0xe5, 0x69, 0x01, 0x80, 0xc5, 0x6c, 0x01, 0x80, 0x05, 0x66, 0x01, 0x80, 0x05, 0x63, 0x01, 0x80, 0x05, 0x60, 0x01, 0x80, 0x05, 0x60, 0x01, 0x00, 0x04, 0x00, 0x01, 0x00, 0x06, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_lb.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016052� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_lb.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_lb_width 32 #define align_lb_height 20 #define align_lb_x_hot 0 #define align_lb_y_hot 0 static unsigned char align_lb_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0xca, 0x1f, 0x00, 0x00, 0x3e, 0x60, 0x00, 0x00, 0x12, 0x80, 0x00, 0x00, 0x32, 0x00, 0x01, 0x00, 0x6a, 0x00, 0xfe, 0x00, 0x46, 0x00, 0xaa, 0x00, 0xa2, 0x00, 0xd6, 0x00, 0x92, 0x01, 0xaa, 0x00, 0x8a, 0x01, 0xd5, 0x00, 0x46, 0x82, 0xaa, 0x00, 0x22, 0x62, 0xd5, 0x00, 0xfe, 0xff, 0xff, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape14.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015544� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape14.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape14_width 32 #define shape14_height 20 #define shape14_x_hot 0 #define shape14_y_hot 0 static unsigned char shape14_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x02, 0x00, 0x00, 0x80, 0x04, 0x00, 0x00, 0xff, 0x08, 0x00, 0x00, 0x01, 0x10, 0x00, 0x00, 0x01, 0x20, 0x00, 0x00, 0x01, 0x40, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x40, 0x00, 0x00, 0x01, 0x20, 0x00, 0x00, 0x01, 0x10, 0x00, 0x00, 0xff, 0x08, 0x00, 0x00, 0x80, 0x04, 0x00, 0x00, 0x80, 0x02, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/just_r.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674124�015605� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/just_r.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define just_r_width 32 #define just_r_height 20 #define just_r_x_hot 0 #define just_r_y_hot 0 static unsigned char just_r_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/rot_mode.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001360�10064674125�016106� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/rot_mode.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define rot_mode_width 32 #define rot_mode_height 20 #define rot_mode_x_hot 0 #define rot_mode_y_hot 0 static unsigned char rot_mode_bits[] = { 0x00, 0x20, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x0c, 0x10, 0x00, 0x00, 0x8a, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0xff, 0xff, 0x01, 0x86, 0x00, 0x00, 0x01, 0x9e, 0x00, 0x00, 0x05, 0x8c, 0x00, 0x00, 0x29, 0x94, 0x00, 0x00, 0x31, 0xa0, 0x00, 0x00, 0x79, 0x80, 0x00, 0x00, 0x61, 0x80, 0xff, 0xff, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x51, 0x00, 0x00, 0x08, 0x30, 0x00, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x04, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_cm.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016054� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_cm.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_cm_width 32 #define align_cm_height 20 #define align_cm_x_hot 0 #define align_cm_y_hot 0 static unsigned char align_cm_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x78, 0x30, 0x00, 0xe0, 0xd7, 0xc0, 0x0f, 0x60, 0x93, 0x80, 0x0d, 0xa0, 0x51, 0x01, 0x0b, 0x60, 0x31, 0x03, 0x0d, 0xa0, 0x11, 0x03, 0x0b, 0x60, 0x91, 0x04, 0x0d, 0xa0, 0x52, 0x8c, 0x0a, 0xe0, 0x37, 0xca, 0x0f, 0x00, 0x18, 0x31, 0x00, 0x00, 0x90, 0x18, 0x00, 0x00, 0xf0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lt2s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015156� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lt2s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lt2s_width 32 #define lt2s_height 20 #define lt2s_x_hot 0 #define lt2s_y_hot 0 static unsigned char lt2s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x00, 0x00, 0xf8, 0x00, 0x00, 0x00, 0xf8, 0x00, 0xf0, 0x01, 0x70, 0x00, 0x0e, 0x3e, 0x10, 0x80, 0x01, 0x7c, 0x08, 0x40, 0x00, 0x7c, 0x08, 0x20, 0x00, 0x7c, 0x08, 0x1e, 0x00, 0x38, 0x04, 0x1f, 0x00, 0x00, 0x04, 0x1f, 0x00, 0x00, 0x04, 0x1f, 0x00, 0x00, 0xc8, 0x0e, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/radio.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000455�10064674125�015400� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/radio.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define radio_width 9 #define radio_height 9 static unsigned char radio_bits[] = { 0x00, 0x00, 0x38, 0x00, 0x7c, 0x00, 0xfe, 0x00, 0xfe, 0x00, 0xfe, 0x00, 0x7c, 0x00, 0x38, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/mag_mask.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001162�10064674124�016054� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/mag_mask.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define mag_mask_width 20 #define mag_mask_height 20 #define mag_mask_x_hot 8 #define mag_mask_y_hot 8 static unsigned char mag_mask_bits[] = { 0xc0, 0x07, 0x00, 0xf0, 0x1f, 0x00, 0xfc, 0x7f, 0x00, 0xfc, 0x7f, 0x00, 0xbe, 0xfb, 0x00, 0xde, 0xf7, 0x00, 0xef, 0xef, 0x01, 0xff, 0xff, 0x01, 0xff, 0xff, 0x01, 0xff, 0xff, 0x01, 0xef, 0xef, 0x01, 0xde, 0xf7, 0x00, 0xbe, 0xfb, 0x01, 0xfc, 0xff, 0x03, 0xfc, 0xff, 0x07, 0xf0, 0xff, 0x0f, 0xc0, 0xf7, 0x0f, 0x00, 0xe0, 0x0f, 0x00, 0xc0, 0x07, 0x00, 0x80, 0x03}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/flood.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000001141�10064674124�015375� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/flood.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define flood_width 20 #define flood_height 20 #define flood_x_hot 9 #define flood_y_hot 18 static unsigned char flood_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0x03, 0x04, 0x00, 0x01, 0x08, 0x80, 0x00, 0x50, 0x55, 0x00, 0xa0, 0x2a, 0x00, 0xc0, 0x1d, 0x00, 0x80, 0x0a, 0x00, 0x00, 0x07, 0x00, 0x00, 0x07, 0x00, 0x00, 0x05, 0x00, 0xc0, 0x1d, 0x00, 0x80, 0x0d, 0x00, 0x00, 0x07, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape8.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001345�10064674125�015471� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape8.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape8_width 32 #define shape8_height 20 #define shape8_x_hot 0 #define shape8_y_hot 19 static unsigned char shape8_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x00, 0x80, 0x00, 0x00, 0x01, 0x40, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x00, 0xe3, 0xff, 0x00, 0x00, 0x12, 0x00, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat7.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000352�10064674125�015151� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat7.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat7_width 8 #define pat7_height 8 static unsigned char pat7_bits[] = { 0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape9.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015471� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape9.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape9_width 32 #define shape9_height 20 #define shape9_x_hot 0 #define shape9_y_hot 0 static unsigned char shape9_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x01, 0x80, 0x00, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x40, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x00, 0x01, 0x80, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/check.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000455�10064674124�015356� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/check.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define check_width 9 #define check_height 9 static unsigned char check_bits[] = { 0x00, 0x00, 0x80, 0x00, 0xc0, 0x00, 0xe2, 0x00, 0x76, 0x00, 0x3e, 0x00, 0x1c, 0x00, 0x08, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape11.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015541� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape11.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape11_width 32 #define shape11_height 20 #define shape11_x_hot 0 #define shape11_y_hot 0 static unsigned char shape11_bits[] = { 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x43, 0x61, 0x00, 0x00, 0x4d, 0x59, 0x00, 0x00, 0x32, 0x26, 0x00, 0xf0, 0x03, 0xe0, 0x0f, 0x60, 0x00, 0x00, 0x06, 0xc0, 0x00, 0x00, 0x03, 0x30, 0x00, 0x00, 0x0c, 0x0e, 0x00, 0x00, 0x70, 0x30, 0x00, 0x00, 0x0c, 0xc0, 0x00, 0x00, 0x03, 0x60, 0x00, 0x00, 0x06, 0xf0, 0x07, 0xf0, 0x0f, 0x00, 0x32, 0x26, 0x00, 0x00, 0x4d, 0x59, 0x00, 0x00, 0x43, 0x61, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/netlist.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674124�015760� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/netlist.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define netlist_width 32 #define netlist_height 20 #define netlist_x_hot 0 #define netlist_y_hot 0 static unsigned char netlist_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x0f, 0x00, 0x00, 0x01, 0x18, 0x00, 0x00, 0x01, 0x28, 0x00, 0x00, 0x01, 0x48, 0x00, 0x00, 0x01, 0x88, 0x00, 0x00, 0x01, 0xf8, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0xa5, 0x77, 0x01, 0x00, 0xad, 0x20, 0x01, 0x00, 0xad, 0x20, 0x01, 0x00, 0xb5, 0x23, 0x01, 0x00, 0xb5, 0x20, 0x01, 0x00, 0xa5, 0x20, 0x01, 0x00, 0xa5, 0x27, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw2.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�015003� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw2.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw2_width 64 #define lw2_height 20 #define lw2_x_hot 0 #define lw2_y_hot 0 static unsigned char lw2_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_rb.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016060� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_rb.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_rb_width 32 #define align_rb_height 20 #define align_rb_x_hot 0 #define align_rb_y_hot 0 static unsigned char align_rb_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0xf0, 0x07, 0x00, 0x00, 0x4c, 0x1b, 0x00, 0x00, 0x42, 0x22, 0x00, 0x00, 0x41, 0x45, 0x00, 0xfe, 0xc0, 0x8c, 0x00, 0xaa, 0x40, 0x8c, 0x00, 0xd6, 0x40, 0x92, 0x00, 0xaa, 0x40, 0xb1, 0x00, 0x56, 0xc1, 0xe8, 0x00, 0xaa, 0x42, 0xc4, 0x00, 0x56, 0x4d, 0xe2, 0x00, 0xfe, 0xff, 0xff}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ls0s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015153� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ls0s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ls0s_width 32 #define ls0s_height 20 #define ls0s_x_hot 0 #define ls0s_y_hot 0 static unsigned char ls0s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x04, 0x51, 0x04, 0x20, 0x05, 0xd1, 0x04, 0x20, 0x85, 0x52, 0x05, 0xe0, 0x84, 0x53, 0x05, 0x20, 0x44, 0x54, 0x06, 0x20, 0x5c, 0x54, 0x04, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/svg.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000001326�11212261046�015065� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/svg.xbm,v 1.1 2009/06/05 18:21:26 cvsps Exp $ */ #define svg_width 32 #define svg_height 20 #define svg_x_hot 0 #define svg_y_hot 0 static unsigned char svg_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x1f, 0x00, 0x40, 0x00, 0x30, 0x00, 0x40, 0x00, 0xd0, 0x00, 0x40, 0x00, 0x90, 0x01, 0x40, 0x00, 0x10, 0x02, 0x40, 0x00, 0xf0, 0x07, 0x40, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x04, 0x40, 0x2e, 0xc8, 0x04, 0x40, 0x41, 0x24, 0x05, 0x40, 0x41, 0x24, 0x04, 0x40, 0x46, 0xa4, 0x05, 0x40, 0x88, 0x22, 0x05, 0x40, 0x88, 0x22, 0x05, 0x40, 0x07, 0xc1, 0x04, 0x40, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x04, 0xc0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/scrl_rt.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000000465�10064674125�015753� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/scrl_rt.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define scrl_rt_width 9 #define scrl_rt_height 9 static unsigned char scrl_rt_bits[] = { 0x00, 0x00, 0x08, 0x00, 0x18, 0x00, 0x38, 0x00, 0x78, 0x00, 0x38, 0x00, 0x18, 0x00, 0x08, 0x00, 0x00, 0x00}; �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/abc.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000000540�10064674124�015021� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/abc.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define abc_width 20 #define abc_height 7 #define abc_x_hot 0 #define abc_y_hot 0 static unsigned char abc_bits[] = { 0x80, 0x01, 0xf0, 0x00, 0x01, 0xf0, 0x1e, 0x0f, 0xff, 0x10, 0x91, 0xf0, 0x1e, 0x91, 0xf0, 0x11, 0x91, 0xf0, 0xbe, 0x0f, 0xff}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/gsubmenu.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000000471�10064674124�016124� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/gsubmenu.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define gsubmenu_width 9 #define gsubmenu_height 9 static unsigned char gsubmenu_bits[] = { 0x00, 0x00, 0x08, 0x00, 0x10, 0x00, 0x28, 0x00, 0x50, 0x00, 0x28, 0x00, 0x10, 0x00, 0x08, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/const_mv.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001276�10064674124�016133� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/const_mv.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define const_mv_width 32 #define const_mv_height 20 static unsigned char const_mv_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x02, 0x02, 0x00, 0x00, 0x02, 0xfe, 0xff, 0x07, 0x02, 0x02, 0x00, 0x04, 0x02, 0x82, 0x00, 0x04, 0x02, 0x02, 0x00, 0x04, 0xfe, 0x83, 0x00, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00, 0xa8, 0xca, 0x7f, 0x00, 0x00, 0x40, 0x40, 0x00, 0x08, 0x48, 0x40, 0x00, 0x00, 0x40, 0x40, 0x00, 0x08, 0x48, 0x40, 0x00, 0x00, 0x40, 0x40, 0x00, 0xa8, 0xca, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x80, 0xff, 0x07, 0x00, 0x00, 0x00, 0x03}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/rot_270.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015473� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/rot_270.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define rot_270_width 32 #define rot_270_height 20 #define rot_270_x_hot 0 #define rot_270_y_hot 0 static unsigned char rot_270_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0x0c, 0x60, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x31, 0x00, 0x01, 0x00, 0xfd, 0x01, 0x01, 0x00, 0x31, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x0c, 0x60, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld3.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014761� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld3.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld3_width 64 #define ld3_height 20 #define ld3_x_hot 0 #define ld3_y_hot 0 static unsigned char ld3_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xf9, 0xf9, 0xf9, 0xf9, 0xf9, 0xf9, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/leftend.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000000676�10064674124�015727� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/leftend.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define leftend_width 16 #define leftend_height 16 #define leftend_x_hot 0 #define leftend_y_hot 0 static unsigned char leftend_bits[] = { 0xff, 0xff, 0x01, 0x80, 0x09, 0x90, 0x09, 0x9c, 0x09, 0x92, 0x89, 0x91, 0x69, 0x90, 0x19, 0x90, 0x19, 0x90, 0x69, 0x90, 0x89, 0x91, 0x09, 0x92, 0x09, 0x9c, 0x09, 0x90, 0x01, 0x80, 0xff, 0xff}; ������������������������������������������������������������������tgif-QPL-4.2.5/xbm/oval.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015233� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/oval.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define oval_width 32 #define oval_height 20 #define oval_x_hot 0 #define oval_y_hot 0 static unsigned char oval_bits[] = { 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0xc0, 0xc7, 0x07, 0x00, 0x00, 0x31, 0x18, 0x00, 0x00, 0x0d, 0x60, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x0c, 0x60, 0x01, 0x00, 0x30, 0x18, 0x01, 0x00, 0xc0, 0xc7, 0x07, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/wire.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674125�015241� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/wire.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define wire_width 32 #define wire_height 20 #define wire_x_hot 0 #define wire_y_hot 0 static unsigned char wire_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x50, 0xe7, 0x01, 0x40, 0x52, 0x29, 0x00, 0x40, 0x52, 0x29, 0x00, 0x40, 0x52, 0xe7, 0x00, 0x40, 0x55, 0x23, 0x00, 0x80, 0x4d, 0x25, 0x00, 0x80, 0x48, 0xe9, 0x01, 0x1c, 0x00, 0x00, 0x38, 0x22, 0x00, 0x00, 0x44, 0xfa, 0xff, 0xff, 0x5f, 0x22, 0x00, 0x00, 0x44, 0x1c, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_ct.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016063� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_ct.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_ct_width 32 #define align_ct_height 20 #define align_ct_x_hot 0 #define align_ct_y_hot 0 static unsigned char align_ct_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x0f, 0x60, 0x3d, 0x70, 0x0d, 0xa0, 0x36, 0xc0, 0x0a, 0x60, 0x53, 0x80, 0x0d, 0xa0, 0xd1, 0x00, 0x0b, 0x60, 0xb1, 0x00, 0x0d, 0xa0, 0x11, 0x01, 0x0b, 0xe0, 0x91, 0x03, 0x0f, 0x00, 0x52, 0x82, 0x00, 0x00, 0x34, 0x46, 0x00, 0x00, 0x18, 0x3d, 0x00, 0x00, 0x90, 0x08, 0x00, 0x00, 0x50, 0x14, 0x00, 0x00, 0x30, 0x12, 0x00, 0x00, 0xf0, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ovaledge.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001360�10064674124�016063� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ovaledge.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ovaledge_width 32 #define ovaledge_height 20 #define ovaledge_x_hot 0 #define ovaledge_y_hot 0 static unsigned char ovaledge_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x47, 0x00, 0x00, 0x30, 0x58, 0x00, 0x00, 0x0c, 0xf0, 0x01, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0xc0, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x02, 0x80, 0x00, 0x00, 0x06, 0x80, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x1f, 0x60, 0x00, 0x00, 0x34, 0x18, 0x00, 0x00, 0xc4, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/hhand_mk.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001207�10064674124�016046� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/hhand_mk.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define hhand_mk_width 18 #define hhand_mk_height 21 #define hhand_mk_x_hot 0 #define hhand_mk_y_hot 0 static unsigned char hhand_mk_bits[] = { 0x20, 0x00, 0xfc, 0x70, 0x00, 0xfc, 0xf8, 0x00, 0xfc, 0xf8, 0x01, 0xfc, 0xf8, 0x01, 0xfc, 0xf8, 0x1b, 0xfc, 0xf8, 0x3f, 0xfc, 0xfc, 0xff, 0xfc, 0xfe, 0xff, 0xfd, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x97, 0xa4, 0xff, 0x07, 0x80, 0xff, 0x0e, 0x80, 0xff, 0x1c, 0xc0, 0xfd, 0x1c, 0xc0, 0xfd, 0x1c, 0xc0, 0xfd, 0xfc, 0xff, 0xfd, 0xf8, 0xff, 0xfc, 0xf0, 0x7f, 0xfc}; �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat32.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674125�015233� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat32.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat32_width 8 #define pat32_height 8 static unsigned char pat32_bits[] = { 0x01, 0x08, 0x40, 0x04, 0x80, 0x10, 0x02, 0x20}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/landscap.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001360�10064674124�016062� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/landscap.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define landscap_width 32 #define landscap_height 20 #define landscap_x_hot 0 #define landscap_y_hot 0 static unsigned char landscap_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x0f, 0x00, 0x80, 0x00, 0x18, 0x00, 0x80, 0x00, 0x28, 0x00, 0x80, 0x00, 0x48, 0x00, 0x80, 0x00, 0x88, 0x00, 0x80, 0x00, 0xf8, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_c.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674124�015672� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_c.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_c_width 32 #define align_c_height 20 #define align_c_x_hot 0 #define align_c_y_hot 0 static unsigned char align_c_bits[] = { 0x00, 0xf0, 0x07, 0x00, 0x00, 0xf8, 0x0f, 0x00, 0x00, 0x1c, 0x1c, 0x00, 0x00, 0xcc, 0x18, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x0c, 0x18, 0x00, 0x00, 0x1c, 0x1c, 0x00, 0x00, 0xf8, 0x4f, 0x00, 0x00, 0xf0, 0x47, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0xc0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape12.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015542� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape12.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape12_width 32 #define shape12_height 20 #define shape12_x_hot 0 #define shape12_y_hot 0 static unsigned char shape12_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x80, 0x02, 0x00, 0x00, 0x80, 0x02, 0x00, 0x00, 0x80, 0x02, 0x00, 0x00, 0x40, 0x04, 0x00, 0xc0, 0x3f, 0xf8, 0x07, 0x80, 0x01, 0x00, 0x03, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x18, 0x30, 0x00, 0x00, 0x10, 0x10, 0x00, 0x00, 0x10, 0x11, 0x00, 0x00, 0x88, 0x22, 0x00, 0x00, 0x68, 0x2c, 0x00, 0x00, 0x18, 0x30, 0x00, 0x00, 0x0c, 0x60, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_cb.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016041� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_cb.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_cb_width 32 #define align_cb_height 20 #define align_cb_x_hot 0 #define align_cb_y_hot 0 static unsigned char align_cb_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0xd0, 0x0f, 0x00, 0x00, 0xd8, 0x30, 0x00, 0x00, 0xb4, 0x40, 0x00, 0x00, 0x12, 0x81, 0x00, 0xe0, 0x91, 0x03, 0x0f, 0xa0, 0x51, 0x02, 0x0b, 0x60, 0x31, 0x06, 0x0d, 0xa0, 0x11, 0x0d, 0x0b, 0x60, 0x93, 0x88, 0x0d, 0xa0, 0x56, 0xd4, 0x0a, 0x60, 0x3d, 0x72, 0x0d, 0xe0, 0xff, 0xff, 0x0f}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat11.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674124�015227� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat11.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat11_width 8 #define pat11_height 8 static unsigned char pat11_bits[] = { 0xfe, 0xff, 0xff, 0xff, 0xef, 0xff, 0xff, 0xff}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/dialog.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000002020�10064674124�015526� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/dialog.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define dialog_width 32 #define dialog_height 32 #define dialog_x_hot 0 #define dialog_y_hot 0 static unsigned char dialog_bits[] = { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x03, 0x38, 0x00, 0xc0, 0x03, 0x38, 0x00, 0xc0, 0x03, 0x38, 0x00, 0xc0, 0x03, 0x38, 0xfe, 0xce, 0x03, 0x38, 0xfe, 0xce, 0xc3, 0x38, 0x00, 0xc0, 0xc3, 0x38, 0x00, 0xc0, 0xc3, 0x38, 0xde, 0xc7, 0xc3, 0x38, 0xde, 0xc7, 0xc3, 0x38, 0x00, 0xc0, 0xc3, 0x38, 0x00, 0xc0, 0xc3, 0x38, 0xfe, 0xc1, 0xc3, 0x38, 0xfe, 0xc1, 0x03, 0x38, 0x00, 0xc0, 0x03, 0x38, 0x00, 0xc0, 0x03, 0x38, 0xfe, 0xc3, 0x03, 0x38, 0xfe, 0xc3, 0x03, 0x38, 0x00, 0xc0, 0x03, 0x38, 0x00, 0xc0, 0xe3, 0x3f, 0x7e, 0xc7, 0xe3, 0x3f, 0x7e, 0xc7, 0xe3, 0x3f, 0x00, 0xc0, 0x03, 0x0e, 0x00, 0xc0, 0x03, 0x0e, 0xfe, 0xc1, 0x03, 0x0e, 0xfe, 0xc1, 0x03, 0x0e, 0x00, 0xc0, 0x03, 0x0e, 0x00, 0xc0, 0x03, 0x0e, 0x00, 0xc0, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_sm.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016074� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_sm.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_sm_width 32 #define align_sm_height 20 #define align_sm_x_hot 0 #define align_sm_y_hot 0 static unsigned char align_sm_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0xe0, 0xcf, 0x00, 0x00, 0x18, 0x70, 0x01, 0xfe, 0x07, 0x40, 0x03, 0x56, 0x03, 0xc0, 0x02, 0xaa, 0x01, 0x40, 0x04, 0x56, 0x01, 0x40, 0x0e, 0xaa, 0x01, 0x40, 0x09, 0x56, 0x01, 0xc0, 0x18, 0xaa, 0x02, 0x40, 0x34, 0xfe, 0x07, 0x40, 0x22, 0x00, 0x18, 0x70, 0x51, 0x00, 0xe0, 0xcf, 0x48, 0x00, 0x00, 0xc0, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld0.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014756� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld0.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld0_width 64 #define ld0_height 20 #define ld0_x_hot 0 #define ld0_y_hot 0 static unsigned char ld0_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x39, 0xd1, 0x03, 0x00, 0x00, 0x00, 0x00, 0x20, 0x44, 0x51, 0x04, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x44, 0x51, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x45, 0x51, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x45, 0x51, 0x04, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x38, 0xd7, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld2s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015136� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld2s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld2s_width 32 #define ld2s_height 20 #define ld2s_x_hot 0 #define ld2s_y_hot 0 static unsigned char ld2s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x78, 0x78, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/polygon.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015766� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/polygon.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define polygon_width 32 #define polygon_height 20 #define polygon_x_hot 0 #define polygon_y_hot 0 static unsigned char polygon_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0e, 0x00, 0x00, 0x00, 0xf2, 0x01, 0x00, 0x00, 0x01, 0x1e, 0x00, 0x00, 0x01, 0xe0, 0x03, 0x80, 0x00, 0x00, 0x1c, 0x80, 0x00, 0x80, 0x07, 0x40, 0x00, 0x70, 0x00, 0x40, 0x00, 0x0f, 0x00, 0x20, 0xc0, 0x00, 0x00, 0x20, 0x00, 0x03, 0x00, 0x10, 0x00, 0x0c, 0x00, 0x10, 0x00, 0x30, 0x00, 0x08, 0x00, 0xc0, 0x00, 0xf8, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/a1.xbm���������������������������������������������������������������������������0000644�0000764�0000764�00000001122�10064674124�014572� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/a1.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define a1_width 20 #define a1_height 20 #define a1_x_hot 0 #define a1_y_hot 0 static unsigned char a1_bits[] = { 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x04, 0xf0, 0x00, 0x04, 0xf0, 0x00, 0x0a, 0xf0, 0x00, 0x0a, 0xf0, 0x00, 0x11, 0xf0, 0x00, 0x11, 0xf0, 0x00, 0x1f, 0xf0, 0x80, 0x20, 0xf0, 0x80, 0x20, 0xf0, 0xc0, 0x71, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/rot_90.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015414� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/rot_90.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define rot_90_width 32 #define rot_90_height 20 #define rot_90_x_hot 0 #define rot_90_y_hot 0 static unsigned char rot_90_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0x0c, 0x60, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x18, 0x01, 0x00, 0x01, 0x7f, 0x01, 0x00, 0x01, 0x18, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x0c, 0x60, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw0.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�015001� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw0.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw0_width 64 #define lw0_height 20 #define lw0_x_hot 0 #define lw0_y_hot 0 static unsigned char lw0_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x97, 0x8a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x92, 0x9a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf2, 0xaa, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x92, 0xaa, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x92, 0xca, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x92, 0x8a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape13.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015543� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape13.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape13_width 32 #define shape13_height 20 #define shape13_x_hot 0 #define shape13_y_hot 0 static unsigned char shape13_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x3f, 0x00, 0x00, 0x03, 0xc0, 0x00, 0x80, 0x00, 0x00, 0x01, 0x80, 0x03, 0xc0, 0x01, 0x80, 0xfc, 0x3f, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x00, 0x03, 0xc0, 0x00, 0x00, 0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape1.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015461� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape1.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape1_width 32 #define shape1_height 20 #define shape1_x_hot 0 #define shape1_y_hot 0 static unsigned char shape1_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0xff, 0x07, 0x00, 0x10, 0x00, 0x04, 0x00, 0x08, 0x00, 0x02, 0x00, 0x08, 0x00, 0x02, 0x00, 0x04, 0x00, 0x01, 0x00, 0x04, 0x00, 0x01, 0x00, 0x04, 0x00, 0x01, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x40, 0x00, 0x00, 0x01, 0x40, 0x00, 0x80, 0x00, 0x20, 0x00, 0x80, 0x00, 0x20, 0x00, 0x80, 0x00, 0x20, 0x00, 0x40, 0x00, 0x10, 0x00, 0x40, 0x00, 0x10, 0x00, 0x20, 0x00, 0x08, 0x00, 0xe0, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/latex.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000001336�10064674124�015415� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/latex.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define latex_width 32 #define latex_height 20 #define latex_x_hot 0 #define latex_y_hot 0 static unsigned char latex_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x84, 0xfd, 0x81, 0x20, 0x84, 0x21, 0x00, 0x11, 0x44, 0x22, 0x7f, 0x0a, 0xc4, 0x23, 0x01, 0x04, 0x24, 0x24, 0x01, 0x04, 0x24, 0x24, 0x3f, 0x0a, 0x04, 0x20, 0x01, 0x11, 0xfc, 0x21, 0x81, 0x20, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x7f, 0x00, 0x10, 0x00, 0x00, 0x08, 0xc8, 0xef, 0xe3, 0x11, 0x44, 0x20, 0x14, 0x22, 0x44, 0x20, 0x14, 0x20, 0xc4, 0xe7, 0xe3, 0x21, 0x44, 0x20, 0x00, 0x22, 0x44, 0x20, 0x10, 0x22, 0xc8, 0x2f, 0xe0, 0x11, 0x10, 0x00, 0x00, 0x08}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/btn3.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000654�10064674124�015150� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/btn3.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define btn3_width 16 #define btn3_height 16 #define btn3_x_hot 0 #define btn3_y_hot 0 static unsigned char btn3_bits[] = { 0xfe, 0x3f, 0x01, 0x40, 0x01, 0x40, 0xdd, 0x5d, 0x55, 0x5d, 0x55, 0x5d, 0x55, 0x5d, 0x55, 0x5d, 0xdd, 0x5d, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0xfe, 0x3f}; ������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape18.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015550� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape18.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape18_width 32 #define shape18_height 20 #define shape18_x_hot 0 #define shape18_y_hot 0 static unsigned char shape18_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x0f, 0x00, 0x80, 0x00, 0x10, 0x00, 0x80, 0x00, 0x20, 0x00, 0x80, 0x00, 0x40, 0x00, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x80, 0x00, 0x80, 0x00, 0x40, 0x00, 0x80, 0x00, 0x20, 0x00, 0x80, 0x00, 0x10, 0x00, 0x80, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/unchkall.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000000704�10064674125�016100� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/unchkall.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define unchkall_width 16 #define unchkall_height 16 #define unchkall_x_hot 0 #define unchkall_y_hot 0 static unsigned char unchkall_bits[] = { 0xff, 0xff, 0x01, 0x80, 0xfd, 0x81, 0x05, 0x81, 0x05, 0x81, 0x05, 0x81, 0x05, 0x81, 0x05, 0x81, 0xfd, 0x81, 0x01, 0x80, 0x01, 0x9c, 0x01, 0x8c, 0x01, 0x94, 0x01, 0xa0, 0x01, 0x80, 0xff, 0xff}; ������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_sb.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016061� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_sb.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_sb_width 32 #define align_sb_height 20 #define align_sb_x_hot 0 #define align_sb_y_hot 0 static unsigned char align_sb_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0xee, 0xfb, 0xbe, 0xef, 0xee, 0xfb, 0xbe, 0xef, 0xee, 0xfb, 0xbe, 0xef, 0xc6, 0x71, 0x1c, 0xc7, 0xc6, 0x71, 0x1c, 0xc7, 0xc6, 0x71, 0x1c, 0xc7, 0xc6, 0x71, 0x1c, 0xc7, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/uncon_mv.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001276�10064674125�016130� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/uncon_mv.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define uncon_mv_width 32 #define uncon_mv_height 20 static unsigned char uncon_mv_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x02, 0x02, 0x00, 0x00, 0x02, 0xfe, 0x00, 0x00, 0x02, 0x82, 0x00, 0x00, 0x02, 0x82, 0x00, 0x00, 0x02, 0x82, 0x00, 0x00, 0xfe, 0x83, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0xa8, 0xca, 0x7f, 0x00, 0x00, 0x40, 0x40, 0x00, 0x08, 0x48, 0x40, 0x00, 0x00, 0x40, 0x40, 0x00, 0x08, 0x48, 0x40, 0x00, 0x00, 0x40, 0x40, 0x00, 0xa8, 0xca, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x80, 0xff, 0x07, 0x00, 0x00, 0x00, 0x03}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat20.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674125�015230� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat20.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat20_width 8 #define pat20_height 8 static unsigned char pat20_bits[] = { 0x01, 0x02, 0x04, 0x08, 0x10, 0x20, 0x40, 0x80}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lt3s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�11226722462�015157� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lt3s.xbm,v 1.2 2009/07/13 21:20:50 william Exp $ */ #define lt3s_width 32 #define lt3s_height 20 #define lt3s_x_hot 0 #define lt3s_y_hot 0 static unsigned char lt3s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x40, 0x04, 0x00, 0x00, 0x40, 0x04, 0x00, 0x00, 0x40, 0x06, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x1f, 0x00, 0x00, 0x7c, 0x13, 0x00, 0x00, 0xc2, 0x13, 0x00, 0x00, 0x01, 0x11, 0x00, 0x80, 0x01, 0x3f, 0x00, 0xc0, 0x00, 0x80, 0x00, 0x7c, 0x00, 0x00, 0x39, 0x64, 0x00, 0x00, 0x4c, 0x54, 0x00, 0x00, 0x44, 0x44, 0x00, 0x00, 0x44, 0x7c, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/patopaq.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001360�10064674125�015743� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/patopaq.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define patopaq_width 32 #define patopaq_height 20 #define patopaq_x_hot 0 #define patopaq_y_hot 0 static unsigned char patopaq_bits[] = { 0x11, 0x11, 0x11, 0x11, 0x22, 0x22, 0x62, 0x22, 0x44, 0x44, 0x74, 0x44, 0x88, 0x88, 0x9c, 0x08, 0x11, 0x11, 0x8b, 0x11, 0x22, 0xe2, 0x84, 0x22, 0x44, 0x34, 0x02, 0x45, 0x88, 0x18, 0x01, 0x09, 0x11, 0x87, 0x80, 0x11, 0xa2, 0x41, 0x40, 0x22, 0x64, 0x20, 0x20, 0x46, 0x18, 0x10, 0x10, 0x0a, 0x0d, 0x08, 0x08, 0x14, 0xf2, 0x04, 0x04, 0x24, 0x44, 0x0f, 0x02, 0x46, 0x88, 0xf8, 0x01, 0x09, 0x11, 0x91, 0x87, 0x18, 0x22, 0x22, 0x7a, 0x28, 0x44, 0x44, 0xc4, 0x57, 0x88, 0x88, 0x88, 0x18}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pbm.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000001322�10064674125�015052� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pbm.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pbm_width 32 #define pbm_height 20 #define pbm_x_hot 0 #define pbm_y_hot 0 static unsigned char pbm_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x1f, 0x00, 0x80, 0x00, 0x30, 0x00, 0x80, 0x00, 0x50, 0x00, 0x80, 0x00, 0x90, 0x00, 0x80, 0x00, 0x10, 0x01, 0x80, 0x00, 0xf0, 0x03, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0xce, 0x89, 0x02, 0x80, 0x52, 0x8a, 0x02, 0x80, 0x52, 0xda, 0x02, 0x80, 0xce, 0xd9, 0x02, 0x80, 0x42, 0xaa, 0x02, 0x80, 0x42, 0xaa, 0x02, 0x80, 0xc2, 0x89, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/stack.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000001336�10064674125�015406� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/stack.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define stack_width 32 #define stack_height 20 #define stack_x_hot 0 #define stack_y_hot 0 static unsigned char stack_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x81, 0x01, 0x00, 0x00, 0x81, 0x02, 0x00, 0x00, 0x81, 0x04, 0x00, 0x00, 0x81, 0x0f, 0x00, 0x00, 0x01, 0x18, 0x00, 0x00, 0x01, 0x28, 0x00, 0x00, 0x01, 0x68, 0x00, 0x00, 0x01, 0xa8, 0x00, 0x00, 0x01, 0xa8, 0x00, 0x00, 0x01, 0xa8, 0x00, 0x00, 0x01, 0xa8, 0x00, 0x00, 0x01, 0xa8, 0x00, 0x00, 0xff, 0xaf, 0x00, 0x00, 0x04, 0xa0, 0x00, 0x00, 0xfc, 0xbf, 0x00, 0x00, 0x10, 0x80, 0x00, 0x00, 0xf0, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/scrl_dn.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000000465�10064674125�015727� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/scrl_dn.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define scrl_dn_width 9 #define scrl_dn_height 9 static unsigned char scrl_dn_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x00, 0x7c, 0x00, 0x38, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00}; �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/redraw.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015564� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/redraw.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define redraw_width 38 #define redraw_height 16 #define redraw_x_hot 0 #define redraw_y_hot 0 static unsigned char redraw_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x3c, 0x00, 0x02, 0x00, 0xc0, 0x44, 0x00, 0x02, 0x00, 0xc0, 0x44, 0xc6, 0xaa, 0x93, 0xc4, 0x3c, 0x29, 0x1b, 0x94, 0xc4, 0x44, 0x2f, 0x0a, 0xa7, 0xc2, 0x44, 0x21, 0x8a, 0xa4, 0xc2, 0x44, 0x29, 0x8b, 0x44, 0xc1, 0x44, 0xc6, 0x0a, 0x4f, 0xc1, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0xc0}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/file.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015211� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/file.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define file_width 32 #define file_height 20 #define file_x_hot 0 #define file_y_hot 0 static unsigned char file_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x02, 0x06, 0x00, 0x00, 0x02, 0x0a, 0x00, 0x00, 0x02, 0x12, 0x00, 0x00, 0x02, 0x22, 0x00, 0x00, 0x02, 0x7e, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lt0s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015154� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lt0s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lt0s_width 32 #define lt0s_height 20 #define lt0s_x_hot 0 #define lt0s_y_hot 0 static unsigned char lt0s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pdf.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000001322�10064674125�015045� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pdf.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pdf_width 32 #define pdf_height 20 #define pdf_x_hot 0 #define pdf_y_hot 0 static unsigned char pdf_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x1f, 0x00, 0x80, 0x00, 0x30, 0x00, 0x80, 0x00, 0x50, 0x00, 0x80, 0x00, 0x90, 0x00, 0x80, 0x00, 0x10, 0x01, 0x80, 0x00, 0xf0, 0x03, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0xce, 0xf1, 0x02, 0x80, 0x52, 0x12, 0x02, 0x80, 0x52, 0x14, 0x02, 0x80, 0x4e, 0x74, 0x02, 0x80, 0x42, 0x14, 0x02, 0x80, 0x42, 0x12, 0x02, 0x80, 0xc2, 0x11, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/freehand.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001360�10064674124�016051� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/freehand.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define freehand_width 32 #define freehand_height 20 #define freehand_x_hot 0 #define freehand_y_hot 0 static unsigned char freehand_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1e, 0x10, 0x00, 0x00, 0xe0, 0x0f, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0x0c, 0x00, 0x00, 0xf0, 0x07, 0x00, 0x00, 0xd8, 0x02, 0x00, 0x00, 0x40, 0x1a, 0x70, 0x38, 0x20, 0xf9, 0x58, 0x2c, 0x20, 0x88, 0x68, 0x34, 0x20, 0xc8, 0x38, 0x1c, 0x10, 0xcc, 0x30, 0x18, 0x10, 0x86, 0x31, 0x18, 0x18, 0x02, 0xcf, 0x27, 0x0c, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_rs.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016101� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_rs.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_rs_width 32 #define align_rs_height 20 #define align_rs_x_hot 0 #define align_rs_y_hot 0 static unsigned char align_rs_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0x00, 0x00, 0x80, 0x3f, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x80, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0x00, 0x00, 0x80, 0x3f, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x80, 0x3f, 0xfe, 0xff, 0xff, 0xff, 0x00, 0x00, 0x80, 0x3f, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x80, 0x3f, 0xfe, 0xff, 0xff, 0xff}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/upend.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000662�10064674125�015415� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/upend.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define upend_width 16 #define upend_height 16 #define upend_x_hot 0 #define upend_y_hot 0 static unsigned char upend_bits[] = { 0xff, 0xff, 0x01, 0x80, 0x01, 0x80, 0xfd, 0xbf, 0x81, 0x81, 0x41, 0x82, 0x41, 0x82, 0x21, 0x84, 0x21, 0x84, 0x11, 0x88, 0x09, 0x90, 0x09, 0x90, 0xfd, 0xbf, 0x01, 0x80, 0x01, 0x80, 0xff, 0xff}; ������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/helphand.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001207�10064674124�016060� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/helphand.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define helphand_width 18 #define helphand_height 21 #define helphand_x_hot 5 #define helphand_y_hot 1 static unsigned char helphand_bits[] = { 0x00, 0x00, 0xfc, 0x20, 0x00, 0xfc, 0x50, 0x00, 0xfc, 0x90, 0x00, 0xfc, 0x90, 0x00, 0xfc, 0x90, 0x00, 0xfc, 0x90, 0x1b, 0xfc, 0x90, 0x24, 0xfc, 0x9c, 0xe4, 0xfc, 0x92, 0x24, 0xfd, 0x92, 0x24, 0xfd, 0x92, 0x24, 0xfd, 0x02, 0x00, 0xfd, 0x02, 0x00, 0xfd, 0x04, 0x00, 0xfd, 0x08, 0x80, 0xfc, 0x08, 0x80, 0xfc, 0x08, 0x80, 0xfc, 0x08, 0x80, 0xfc, 0xf0, 0x7f, 0xfc, 0x00, 0x00, 0xfc}; �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/intr90.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000000670�10064674124�015425� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/intr90.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define intr90_width 16 #define intr90_height 16 #define intr90_x_hot 0 #define intr90_y_hot 0 static unsigned char intr90_bits[] = { 0xe0, 0x03, 0x98, 0x0f, 0x84, 0x1f, 0x82, 0x3f, 0x82, 0x3f, 0x81, 0x7f, 0x81, 0x7f, 0xff, 0x7f, 0xff, 0x40, 0xff, 0x40, 0xfe, 0x20, 0xfe, 0x20, 0xfc, 0x10, 0xf8, 0x0c, 0xe0, 0x03, 0x00, 0x00}; ������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld6.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014764� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld6.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld6_width 64 #define ld6_height 20 #define ld6_x_hot 0 #define ld6_y_hot 0 static unsigned char ld6_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x99, 0xf9, 0x99, 0xf9, 0x99, 0xf9, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/downend.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000000676�10064674124�015744� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/downend.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define downend_width 16 #define downend_height 16 #define downend_x_hot 0 #define downend_y_hot 0 static unsigned char downend_bits[] = { 0xff, 0xff, 0x01, 0x80, 0x01, 0x80, 0xfd, 0xbf, 0x09, 0x90, 0x09, 0x90, 0x11, 0x88, 0x21, 0x84, 0x21, 0x84, 0x41, 0x82, 0x41, 0x82, 0x81, 0x81, 0xfd, 0xbf, 0x01, 0x80, 0x01, 0x80, 0xff, 0xff}; ������������������������������������������������������������������tgif-QPL-4.2.5/xbm/vmode.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000001336�10064674125�015413� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/vmode.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define vmode_width 32 #define vmode_height 20 #define vmode_x_hot 0 #define vmode_y_hot 0 static unsigned char vmode_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3e, 0x06, 0x00, 0x00, 0x3e, 0x7a, 0x00, 0x00, 0x36, 0x82, 0xc7, 0x07, 0x3a, 0x04, 0xb8, 0x07, 0x3a, 0x04, 0x40, 0x06, 0x02, 0x04, 0x40, 0x07, 0x01, 0x04, 0x80, 0x87, 0x00, 0x04, 0x20, 0x80, 0x00, 0x08, 0x10, 0x40, 0x00, 0x08, 0x08, 0x20, 0x00, 0x08, 0x06, 0x0f, 0x00, 0x08, 0x01, 0x17, 0x00, 0x88, 0x00, 0x23, 0x00, 0x50, 0x00, 0xdf, 0x0f, 0x30, 0x00, 0x1f, 0x70, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/edit.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015217� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/edit.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define edit_width 32 #define edit_height 20 #define edit_x_hot 0 #define edit_y_hot 0 static unsigned char edit_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x7c, 0x20, 0x7f, 0x02, 0x84, 0x21, 0x08, 0x02, 0x04, 0x21, 0x08, 0x02, 0x04, 0x22, 0x08, 0x02, 0x04, 0x22, 0x08, 0x7e, 0x04, 0x22, 0x08, 0x02, 0x04, 0x22, 0x08, 0x02, 0x04, 0x22, 0x08, 0x02, 0x04, 0x21, 0x08, 0x02, 0x84, 0x21, 0x08, 0xfe, 0x7c, 0x20, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld4s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015140� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld4s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld4s_width 32 #define ld4s_height 20 #define ld4s_x_hot 0 #define ld4s_y_hot 0 static unsigned char ld4s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x9f, 0xf9, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/png.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000001322�10064674125�015060� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/png.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define png_width 32 #define png_height 20 #define png_x_hot 0 #define png_y_hot 0 static unsigned char png_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x0f, 0x00, 0x80, 0x00, 0x18, 0x00, 0x80, 0x00, 0x28, 0x00, 0x80, 0x00, 0x48, 0x00, 0x80, 0x00, 0x88, 0x00, 0x80, 0x00, 0xf8, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x4e, 0x32, 0x01, 0x80, 0xd2, 0x4a, 0x01, 0x80, 0xd2, 0x0a, 0x01, 0x80, 0xce, 0x6b, 0x01, 0x80, 0x42, 0x4b, 0x01, 0x80, 0x42, 0x4b, 0x01, 0x80, 0x42, 0x32, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0xff, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape16.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015546� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape16.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape16_width 32 #define shape16_height 20 #define shape16_x_hot 0 #define shape16_y_hot 0 static unsigned char shape16_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0xfe, 0x02, 0x00, 0x00, 0x02, 0x04, 0x00, 0x00, 0x02, 0x08, 0x00, 0x00, 0x02, 0x10, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x10, 0x00, 0x00, 0x02, 0x08, 0x00, 0x00, 0x02, 0x04, 0x00, 0x00, 0xfe, 0x02, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape19.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015551� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape19.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape19_width 32 #define shape19_height 20 #define shape19_x_hot 0 #define shape19_y_hot 0 static unsigned char shape19_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x40, 0x01, 0x00, 0x00, 0x20, 0x02, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0x04, 0x10, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0xfe, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat28.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000432�10064674125�015233� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat28.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat28_width 8 #define pat28_height 8 #define pat28_x_hot 0 #define pat28_y_hot 0 static unsigned char pat28_bits[] = { 0x77, 0xbb, 0xdd, 0xee, 0x77, 0xbb, 0xdd, 0xee}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/rot_180.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015473� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/rot_180.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define rot_180_width 32 #define rot_180_height 20 #define rot_180_x_hot 0 #define rot_180_y_hot 0 static unsigned char rot_180_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0x0c, 0x60, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x01, 0x00, 0x82, 0x83, 0x00, 0x00, 0x82, 0x83, 0x00, 0x00, 0x04, 0x41, 0x00, 0x00, 0x0c, 0x61, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat30.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674125�015231� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat30.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat30_width 8 #define pat30_height 8 static unsigned char pat30_bits[] = { 0x7f, 0xbf, 0xdf, 0xef, 0xf7, 0xfb, 0xfd, 0xfe}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lt3.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�11226722462�015001� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lt3.xbm,v 1.2 2009/07/13 21:20:50 william Exp $ */ #define lt3_width 64 #define lt3_height 20 #define lt3_x_hot 0 #define lt3_y_hot 0 static unsigned char lt3_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x74, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc4, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x38, 0x18, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x45, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x01, 0x5f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0xc4, 0x01, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x7c, 0x18, 0x38, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x80, 0x45, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x4c, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x44, 0x00, 0xc0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x38, 0x00, 0x40, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/arrow.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000001336�10064674124�015432� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/arrow.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define arrow_width 32 #define arrow_height 20 #define arrow_x_hot 0 #define arrow_y_hot 0 static unsigned char arrow_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, 0x00, 0xfe, 0x00, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0xfe, 0x07, 0x00, 0x00, 0xfe, 0x1f, 0x00, 0x00, 0x7e, 0x00, 0x00, 0x00, 0xde, 0x00, 0x00, 0x00, 0x9e, 0x01, 0x00, 0x00, 0x0e, 0x01, 0x00, 0x00, 0x06, 0x03, 0x00, 0x00, 0x02, 0x06, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/null.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000510�10064674124�015243� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/null.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define null_width 8 #define null_height 16 #define null_x_hot 0 #define null_y_hot 0 static unsigned char null_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/question.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000002034�10064674125�016144� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/question.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define question_width 32 #define question_height 32 #define question_x_hot 0 #define question_y_hot 0 static unsigned char question_bits[] = { 0x00, 0xf0, 0x0f, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x80, 0xff, 0xff, 0x01, 0xc0, 0x1f, 0xf8, 0x03, 0xe0, 0x07, 0xe0, 0x07, 0xf0, 0x03, 0xc0, 0x0f, 0xf8, 0x03, 0xc0, 0x1f, 0xfc, 0x01, 0x80, 0x3f, 0xfc, 0x01, 0x80, 0x3f, 0xfe, 0x81, 0x81, 0x7f, 0xfe, 0x81, 0x81, 0x7f, 0xfe, 0x81, 0x81, 0x7f, 0xff, 0xff, 0xc0, 0xff, 0xff, 0xff, 0xc0, 0xff, 0xff, 0x7f, 0xe0, 0xff, 0xff, 0x7f, 0xe0, 0xff, 0xff, 0x3f, 0xf0, 0xff, 0xff, 0x3f, 0xf0, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xfe, 0x1f, 0xf8, 0x7f, 0xfe, 0xff, 0xff, 0x7f, 0xfe, 0x7f, 0xfe, 0x7f, 0xfc, 0x1f, 0xf8, 0x3f, 0xfc, 0x1f, 0xf8, 0x3f, 0xf8, 0x0f, 0xf0, 0x1f, 0xf0, 0x0f, 0xf0, 0x0f, 0xe0, 0x1f, 0xf8, 0x07, 0xc0, 0x1f, 0xf8, 0x03, 0x80, 0x7f, 0xfe, 0x01, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0xf0, 0x0f, 0x00}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/text_cur.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001047�10064674125�016135� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/text_cur.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define text_cur_width 16 #define text_cur_height 24 #define text_cur_x_hot 0 #define text_cur_y_hot 0 static unsigned char text_cur_bits[] = { 0x00, 0x00, 0xee, 0x00, 0x38, 0x00, 0x10, 0x00, 0x10, 0x00, 0x10, 0x00, 0x10, 0x00, 0x10, 0x00, 0x10, 0x00, 0x10, 0x00, 0x10, 0x00, 0x10, 0x00, 0x10, 0x00, 0x38, 0x00, 0xee, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/trek.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001132�10064674125�015240� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/trek.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define trek_width 20 #define trek_height 20 #define trek_x_hot 0 #define trek_y_hot 0 static unsigned char trek_bits[] = { 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x1f, 0xf0, 0x80, 0x20, 0xf0, 0x40, 0x40, 0xf0, 0x20, 0x80, 0xf0, 0x20, 0x80, 0xf0, 0x20, 0x80, 0xf0, 0x20, 0x80, 0xf0, 0x20, 0x80, 0xf0, 0x40, 0x40, 0xf0, 0x80, 0x20, 0xf0, 0x70, 0xdf, 0xf1, 0x50, 0x4a, 0xf1, 0xd0, 0x7b, 0xf1, 0x50, 0x4e, 0xf1, 0x50, 0x40, 0xf1, 0x50, 0x40, 0xf1, 0x70, 0xc0, 0xf1, 0x00, 0x00, 0xf0}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/uparrow.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000000676�10064674125�016006� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/uparrow.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define uparrow_width 16 #define uparrow_height 16 #define uparrow_x_hot 0 #define uparrow_y_hot 0 static unsigned char uparrow_bits[] = { 0xff, 0xff, 0x01, 0x80, 0x01, 0x80, 0x81, 0x81, 0x41, 0x82, 0x41, 0x82, 0x21, 0x84, 0x21, 0x84, 0x11, 0x88, 0x09, 0x90, 0x09, 0x90, 0xfd, 0xbf, 0x01, 0x80, 0x01, 0x80, 0x01, 0x80, 0xff, 0xff}; ������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_lt.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016074� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_lt.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_lt_width 32 #define align_lt_height 20 #define align_lt_x_hot 0 #define align_lt_y_hot 0 static unsigned char align_lt_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x00, 0x36, 0x60, 0xd5, 0x00, 0x0e, 0x80, 0xaa, 0x00, 0x0a, 0x00, 0xd5, 0x00, 0x1e, 0x00, 0xaa, 0x00, 0x12, 0x00, 0xd6, 0x00, 0x32, 0x00, 0xaa, 0x00, 0x6a, 0x00, 0xfe, 0x00, 0x46, 0x00, 0x01, 0x00, 0xa2, 0x80, 0x00, 0x00, 0x92, 0x61, 0x00, 0x00, 0x8a, 0x1f, 0x00, 0x00, 0x46, 0x02, 0x00, 0x00, 0x22, 0x02, 0x00, 0x00, 0xfe, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat29.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674125�015241� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat29.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat29_width 8 #define pat29_height 8 static unsigned char pat29_bits[] = { 0xc1, 0xe0, 0x70, 0x38, 0x1c, 0x0e, 0x07, 0x83}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld5s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015141� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld5s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld5s_width 32 #define ld5s_height 20 #define ld5s_x_hot 0 #define ld5s_y_hot 0 static unsigned char ld5s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x98, 0x99, 0x99, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lt1s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015155� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lt1s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lt1s_width 32 #define lt1s_height 20 #define lt1s_x_hot 0 #define lt1s_y_hot 0 static unsigned char lt1s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0xc0, 0x18, 0x00, 0x00, 0x20, 0x20, 0x00, 0x00, 0x10, 0x40, 0x00, 0x00, 0x08, 0x80, 0x00, 0x00, 0x00, 0x00, 0x01, 0x10, 0x00, 0x00, 0x02, 0x08, 0x00, 0x00, 0x04, 0x04, 0x00, 0x00, 0x18, 0x03, 0x00, 0x00, 0xe0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/rot_mode2.xbm��������������������������������������������������������������������0000644�0000764�0000764�00000001374�11212015777�016173� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/rot_mode2.xbm,v 1.1 2009/06/04 19:09:51 william Exp $ */ #define rot_mode2_width 32 #define rot_mode2_height 20 #define rot_mode2_x_hot 0 #define rot_mode2_y_hot 0 static unsigned char rot_mode2_bits[] = { 0x00, 0x20, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x1e, 0x00, 0x00, 0x00, 0x0c, 0x10, 0x00, 0x00, 0x8a, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x81, 0xff, 0xff, 0x01, 0x86, 0x80, 0x03, 0x01, 0x9e, 0x40, 0x05, 0x05, 0x8c, 0x20, 0x09, 0x29, 0x94, 0xe0, 0x0f, 0x31, 0xa0, 0x20, 0x09, 0x79, 0x80, 0x40, 0x05, 0x61, 0x80, 0xff, 0xff, 0x81, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x51, 0x00, 0x00, 0x08, 0x30, 0x00, 0x00, 0x00, 0x78, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x04, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape3.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015463� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape3.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape3_width 32 #define shape3_height 20 #define shape3_x_hot 0 #define shape3_y_hot 0 static unsigned char shape3_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x40, 0x01, 0x00, 0x00, 0x20, 0x02, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0x04, 0x10, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x01, 0x40, 0x00, 0x80, 0x00, 0x80, 0x00, 0x00, 0x01, 0x40, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x04, 0x10, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x20, 0x02, 0x00, 0x00, 0x40, 0x01, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat16.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674124�015234� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat16.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat16_width 8 #define pat16_height 8 static unsigned char pat16_bits[] = { 0x1f, 0x2e, 0x44, 0xe2, 0xf1, 0xe8, 0x44, 0x8e}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/rcb_rad.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015673� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/rcb_rad.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define rcb_rad_width 32 #define rcb_rad_height 20 #define rcb_rad_x_hot 0 #define rcb_rad_y_hot 0 static unsigned char rcb_rad_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x80, 0x05, 0x00, 0x00, 0x60, 0x0e, 0x00, 0x00, 0x10, 0x15, 0x00, 0x00, 0x08, 0x04, 0x00, 0x00, 0x08, 0x04, 0x00, 0x00, 0x04, 0x04, 0x00, 0x00, 0x04, 0x04, 0x00, 0x00, 0x02, 0x15, 0x00, 0x00, 0x02, 0x0e, 0x00, 0x00, 0x02, 0x04, 0x00, 0x00, 0x02, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat21.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674125�015231� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat21.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat21_width 8 #define pat21_height 8 static unsigned char pat21_bits[] = { 0x11, 0x22, 0x44, 0x88, 0x11, 0x22, 0x44, 0x88}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw6.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�015007� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw6.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw6_width 64 #define lw6_height 20 #define lw6_x_hot 0 #define lw6_y_hot 0 static unsigned char lw6_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw5.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�015006� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw5.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw5_width 64 #define lw5_height 20 #define lw5_x_hot 0 #define lw5_y_hot 0 static unsigned char lw5_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld1.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014757� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld1.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld1_width 64 #define ld1_height 20 #define ld1_x_hot 0 #define ld1_y_hot 0 static unsigned char ld1_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw4.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�015005� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw4.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw4_width 64 #define lw4_height 20 #define lw4_x_hot 0 #define lw4_y_hot 0 static unsigned char lw4_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/gif.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000001322�10064674124�015040� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/gif.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define gif_width 32 #define gif_height 20 #define gif_x_hot 0 #define gif_y_hot 0 static unsigned char gif_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x7f, 0x00, 0x20, 0x00, 0xc0, 0x00, 0x20, 0xe7, 0x5e, 0x01, 0xa0, 0x40, 0x42, 0x02, 0xa0, 0x4c, 0x4e, 0x04, 0xa0, 0x48, 0xc2, 0x0f, 0x20, 0xe7, 0x02, 0x08, 0x20, 0x00, 0x00, 0x08, 0x20, 0x00, 0x00, 0x08, 0xa0, 0x2c, 0x92, 0x09, 0xa0, 0x62, 0x93, 0x0a, 0xa0, 0x62, 0xab, 0x0a, 0xa0, 0xa4, 0xba, 0x09, 0xa0, 0xa8, 0xaa, 0x08, 0xa0, 0x28, 0xaa, 0x08, 0xa0, 0x26, 0xaa, 0x08, 0x20, 0x00, 0x00, 0x08, 0xe0, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_rt.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016102� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_rt.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_rt_width 32 #define align_rt_height 20 #define align_rt_x_hot 0 #define align_rt_y_hot 0 static unsigned char align_rt_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0x00, 0x56, 0xcd, 0xd8, 0x00, 0xaa, 0xc2, 0xa0, 0x00, 0x56, 0xc1, 0xc1, 0x00, 0xaa, 0x40, 0x83, 0x00, 0xd6, 0x40, 0x82, 0x00, 0xaa, 0x40, 0x85, 0x00, 0xfe, 0xc0, 0x8c, 0x00, 0x00, 0x41, 0x4c, 0x00, 0x00, 0x42, 0x32, 0x00, 0x00, 0x4c, 0x31, 0x00, 0x00, 0xf0, 0x28, 0x00, 0x00, 0x40, 0x44, 0x00, 0x00, 0x40, 0x62, 0x00, 0x00, 0xc0, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld5.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014763� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld5.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld5_width 64 #define ld5_height 20 #define ld5_x_hot 0 #define ld5_y_hot 0 static unsigned char ld5_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x98, 0x99, 0x99, 0x99, 0x99, 0x99, 0x99, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw1s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015160� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw1s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw1s_width 32 #define lw1s_height 20 #define lw1s_x_hot 0 #define lw1s_y_hot 0 static unsigned char lw1s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/psfile.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015562� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/psfile.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define psfile_width 32 #define psfile_height 20 #define psfile_x_hot 0 #define psfile_y_hot 0 static unsigned char psfile_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x02, 0x06, 0x00, 0x00, 0x02, 0x0a, 0x00, 0x00, 0x02, 0x12, 0x00, 0x00, 0x02, 0x22, 0x00, 0x00, 0x02, 0x7e, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x3a, 0x4e, 0x00, 0x00, 0x4a, 0x41, 0x00, 0x00, 0x4a, 0x41, 0x00, 0x00, 0x3a, 0x46, 0x00, 0x00, 0x0a, 0x48, 0x00, 0x00, 0x0a, 0x48, 0x00, 0x00, 0x0a, 0x47, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/nullmask.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000000540�10064674124�016122� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/nullmask.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define nullmask_width 8 #define nullmask_height 16 #define nullmask_x_hot 7 #define nullmask_y_hot 0 static unsigned char nullmask_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/stretch.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015753� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/stretch.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define stretch_width 32 #define stretch_height 20 #define stretch_x_hot 0 #define stretch_y_hot 0 static unsigned char stretch_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x80, 0x12, 0x00, 0x00, 0x80, 0x43, 0x00, 0x00, 0x40, 0x04, 0x01, 0x00, 0x40, 0x04, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x04, 0x60, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x10, 0x90, 0x00, 0x00, 0x00, 0x90, 0x00, 0x00, 0x40, 0xf8, 0x01, 0x00, 0x00, 0xf8, 0x01, 0x00, 0x00, 0x0c, 0x03, 0x00, 0x00, 0x0c, 0x03, 0x00, 0x00, 0x0c, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat23.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674125�015233� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat23.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat23_width 8 #define pat23_height 8 static unsigned char pat23_bits[] = { 0x83, 0x07, 0x0e, 0x1c, 0x38, 0x70, 0xe0, 0xc1}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld4.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014762� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld4.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld4_width 64 #define ld4_height 20 #define ld4_x_hot 0 #define ld4_y_hot 0 static unsigned char ld4_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x9f, 0xf9, 0x9f, 0xf9, 0x9f, 0xf9, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/html.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015236� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/html.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define html_width 32 #define html_height 20 #define html_x_hot 0 #define html_y_hot 0 static unsigned char html_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x3f, 0x00, 0x20, 0x00, 0x60, 0x00, 0x20, 0x00, 0xa0, 0x00, 0x20, 0x00, 0x20, 0x01, 0x20, 0x00, 0x20, 0x02, 0x20, 0x00, 0xe0, 0x07, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0xa0, 0x74, 0x51, 0x04, 0xa0, 0x24, 0x51, 0x04, 0xa0, 0x24, 0x5b, 0x04, 0xa0, 0x27, 0x5b, 0x04, 0xa0, 0x24, 0x55, 0x04, 0xa0, 0x24, 0x55, 0x04, 0xa0, 0x24, 0xd1, 0x05, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat22.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000432�10064674125�015225� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat22.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat22_width 8 #define pat22_height 8 #define pat22_x_hot 0 #define pat22_y_hot 0 static unsigned char pat22_bits[] = { 0xee, 0xdd, 0xbb, 0x77, 0xee, 0xdd, 0xbb, 0x77}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat14.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674124�015232� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat14.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat14_width 8 #define pat14_height 8 static unsigned char pat14_bits[] = { 0xff, 0x11, 0x11, 0x11, 0xff, 0x11, 0x11, 0x11}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/flood_mk.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001163�10064674124�016070� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/flood_mk.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define flood_mk_width 20 #define flood_mk_height 20 #define flood_mk_x_hot 9 #define flood_mk_y_hot 18 static unsigned char flood_mk_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0x07, 0xff, 0xff, 0x07, 0xff, 0xff, 0x07, 0xfe, 0xff, 0x03, 0xfc, 0xff, 0x01, 0xf8, 0xff, 0x00, 0xf0, 0x7f, 0x00, 0xe0, 0x3f, 0x00, 0xc0, 0x1f, 0x00, 0x80, 0x0f, 0x00, 0xe0, 0x3f, 0x00, 0xe0, 0x3f, 0x00, 0xe0, 0x3f, 0x00, 0xc0, 0x1f, 0x00, 0x80, 0x0f, 0x00, 0x00, 0x07, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/vspace.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015561� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/vspace.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define vspace_width 32 #define vspace_height 20 #define vspace_x_hot 0 #define vspace_y_hot 0 static unsigned char vspace_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0xa0, 0x02, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0xf8, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x0f, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0xc0, 0x01, 0x00, 0x00, 0xa0, 0x02, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/dnarrow.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000000676�10064674124�015762� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/dnarrow.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define dnarrow_width 16 #define dnarrow_height 16 #define dnarrow_x_hot 0 #define dnarrow_y_hot 0 static unsigned char dnarrow_bits[] = { 0xff, 0xff, 0x01, 0x80, 0x01, 0x80, 0x01, 0x80, 0xfd, 0xbf, 0x09, 0x90, 0x09, 0x90, 0x11, 0x88, 0x21, 0x84, 0x21, 0x84, 0x41, 0x82, 0x41, 0x82, 0x81, 0x81, 0x01, 0x80, 0x01, 0x80, 0xff, 0xff}; ������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat25.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674125�015235� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat25.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat25_width 8 #define pat25_height 8 static unsigned char pat25_bits[] = { 0x7c, 0xf8, 0xf1, 0xe3, 0xc7, 0x8f, 0x1f, 0x3e}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat26.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674125�015236� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat26.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat26_width 8 #define pat26_height 8 static unsigned char pat26_bits[] = { 0x80, 0x40, 0x20, 0x10, 0x08, 0x04, 0x02, 0x01}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat0.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015136� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat0.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat0_width 32 #define pat0_height 20 #define pat0_x_hot 0 #define pat0_y_hot 0 static unsigned char pat0_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x42, 0x3c, 0x42, 0x7e, 0x42, 0x42, 0x42, 0x02, 0x46, 0x42, 0x46, 0x02, 0x46, 0x42, 0x46, 0x02, 0x4a, 0x42, 0x4a, 0x02, 0x4a, 0x42, 0x4a, 0x7e, 0x52, 0x42, 0x52, 0x02, 0x52, 0x42, 0x52, 0x02, 0x62, 0x42, 0x62, 0x02, 0x62, 0x42, 0x62, 0x02, 0x42, 0x42, 0x42, 0x02, 0x42, 0x3c, 0x42, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ls1.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014776� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ls1.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ls1_width 64 #define ls1_height 20 #define ls1_x_hot 0 #define ls1_y_hot 0 static unsigned char ls1_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_l.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674124�015703� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_l.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_l_width 32 #define align_l_height 20 #define align_l_x_hot 0 #define align_l_y_hot 0 static unsigned char align_l_bits[] = { 0x00, 0x0c, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x2c, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0xfc, 0x1f, 0x00, 0x00, 0xfc, 0x5f, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0xf0, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat3.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000352�10064674125�015145� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat3.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat3_width 8 #define pat3_height 8 static unsigned char pat3_bits[] = { 0x01, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape17.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015547� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape17.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape17_width 32 #define shape17_height 20 #define shape17_x_hot 0 #define shape17_y_hot 0 static unsigned char shape17_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x40, 0x01, 0x00, 0x00, 0x20, 0x02, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0x04, 0x10, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x01, 0x40, 0x00, 0x80, 0x03, 0xe0, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0xfe, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw3.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�015004� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw3.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw3_width 64 #define lw3_height 20 #define lw3_x_hot 0 #define lw3_y_hot 0 static unsigned char lw3_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat18.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674124�015236� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat18.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat18_width 8 #define pat18_height 8 static unsigned char pat18_bits[] = { 0x10, 0x38, 0x44, 0x83, 0x01, 0x80, 0x40, 0x20}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape0.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015460� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape0.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape0_width 32 #define shape0_height 20 #define shape0_x_hot 0 #define shape0_y_hot 0 static unsigned char shape0_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld7s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015143� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld7s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld7s_width 32 #define ld7s_height 20 #define ld7s_x_hot 0 #define ld7s_y_hot 0 static unsigned char ld7s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw6s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015165� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw6s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw6s_width 32 #define lw6s_height 20 #define lw6s_x_hot 0 #define lw6s_y_hot 0 static unsigned char lw6s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/rcbox.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000001336�10064674125�015416� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/rcbox.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define rcbox_width 32 #define rcbox_height 20 #define rcbox_x_hot 0 #define rcbox_y_hot 0 static unsigned char rcbox_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x80, 0x01, 0x80, 0x01, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x80, 0x01, 0x80, 0x01, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_ss.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016102� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_ss.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_ss_width 32 #define align_ss_height 20 #define align_ss_x_hot 0 #define align_ss_y_hot 0 static unsigned char align_ss_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xfe, 0xff, 0xff, 0xff, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0xfe, 0xff, 0xff, 0xff, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0xfe, 0xff, 0xff, 0xff, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0xfe, 0xff, 0xff, 0x7f}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/tgtwb5.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000025033�10064674125�015515� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/tgtwb5.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define tgtwb5_width 208 #define tgtwb5_height 64 #define tgtwb5_x_hot 0 #define tgtwb5_y_hot 0 static unsigned char tgtwb5_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x07, 0x00, 0x00, 0x08, 0x10, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x04, 0x00, 0x00, 0x20, 0x00, 0x10, 0x00, 0xc0, 0x07, 0x00, 0x01, 0x20, 0x01, 0x10, 0x04, 0xfe, 0x3f, 0x10, 0x08, 0x00, 0x00, 0xfc, 0x0f, 0x80, 0x00, 0x20, 0x04, 0x40, 0x04, 0x20, 0x00, 0x10, 0x00, 0x40, 0x00, 0x00, 0x01, 0x20, 0x01, 0x10, 0x04, 0x90, 0x00, 0x20, 0x04, 0x00, 0x00, 0x20, 0x08, 0x88, 0x08, 0x20, 0x04, 0x40, 0x04, 0x10, 0x00, 0x08, 0x00, 0x40, 0x00, 0x80, 0x01, 0x20, 0x01, 0x10, 0x04, 0x90, 0x00, 0x40, 0x02, 0x00, 0x00, 0x20, 0x08, 0x88, 0x08, 0x20, 0x04, 0x20, 0x02, 0xf8, 0x1f, 0xfc, 0x1f, 0x20, 0x00, 0x40, 0x01, 0x20, 0x01, 0x08, 0x02, 0x88, 0x00, 0x00, 0x01, 0x00, 0x00, 0x20, 0x08, 0x88, 0x08, 0x20, 0x04, 0x20, 0x02, 0x80, 0x10, 0x00, 0x10, 0xe0, 0x01, 0x00, 0x01, 0x20, 0x01, 0x08, 0x02, 0xf8, 0x1f, 0x80, 0x00, 0x00, 0x00, 0x20, 0x08, 0x88, 0x08, 0x20, 0x04, 0x10, 0x01, 0x80, 0x10, 0x00, 0x10, 0x20, 0x02, 0x00, 0x01, 0x20, 0x01, 0xf8, 0x1f, 0x80, 0x10, 0x80, 0x00, 0x00, 0x00, 0x20, 0x08, 0x88, 0x08, 0x20, 0x04, 0x10, 0x01, 0x80, 0x10, 0x00, 0x10, 0x00, 0x04, 0x00, 0x01, 0x20, 0x01, 0x00, 0x10, 0x80, 0x10, 0x80, 0x00, 0xfe, 0x7f, 0x20, 0x04, 0x88, 0x08, 0x10, 0x06, 0x88, 0x00, 0x80, 0x10, 0x00, 0x10, 0x00, 0x04, 0x00, 0x01, 0x20, 0x01, 0x00, 0x10, 0x80, 0x10, 0x80, 0x00, 0x00, 0x00, 0xa0, 0x04, 0xf8, 0x0f, 0x90, 0x05, 0x10, 0x01, 0x40, 0x10, 0x00, 0x10, 0x00, 0x04, 0x00, 0x01, 0x20, 0x01, 0x00, 0x10, 0x40, 0x10, 0x80, 0x00, 0x00, 0x00, 0x20, 0x03, 0x80, 0x00, 0x70, 0x04, 0x10, 0x01, 0x40, 0x10, 0x00, 0x10, 0x10, 0x04, 0x00, 0x01, 0x10, 0x01, 0x00, 0x08, 0x40, 0x10, 0x80, 0x00, 0x00, 0x00, 0x20, 0x00, 0x80, 0x00, 0x00, 0x04, 0x20, 0x02, 0x20, 0x10, 0x00, 0x10, 0x20, 0x02, 0x00, 0x01, 0x10, 0x21, 0x00, 0x08, 0x20, 0x08, 0x80, 0x00, 0x00, 0x00, 0x20, 0x00, 0x80, 0x00, 0x00, 0x04, 0x20, 0x02, 0x10, 0x08, 0x00, 0x08, 0xc0, 0x01, 0x00, 0x01, 0x08, 0x21, 0x00, 0x04, 0x10, 0x08, 0x80, 0x00, 0x00, 0x00, 0x20, 0x00, 0xfe, 0x3f, 0x00, 0x04, 0x40, 0x04, 0x88, 0x08, 0x80, 0x08, 0x00, 0x00, 0x00, 0x00, 0x06, 0x3e, 0x00, 0x02, 0x08, 0x04, 0x80, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x04, 0x40, 0x04, 0x04, 0x05, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x02, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x40, 0x00, 0x00, 0x02, 0x00, 0x01, 0x00, 0x00, 0x80, 0x00, 0x20, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x10, 0x00, 0x38, 0x00, 0xfe, 0x3f, 0x00, 0x08, 0x40, 0x00, 0x00, 0x01, 0x00, 0x01, 0xfe, 0x3f, 0x80, 0x00, 0x20, 0x00, 0x00, 0x00, 0x40, 0x04, 0x00, 0x00, 0x10, 0x00, 0x20, 0x00, 0x80, 0x00, 0x00, 0x08, 0x40, 0x00, 0x80, 0x00, 0x00, 0x01, 0x40, 0x00, 0x80, 0x00, 0x10, 0x00, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x10, 0x00, 0x20, 0x00, 0x80, 0x00, 0x10, 0x04, 0xfe, 0x3f, 0x40, 0x00, 0x80, 0x00, 0x40, 0x00, 0x80, 0x00, 0xf8, 0x1f, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x08, 0x00, 0x20, 0x00, 0x80, 0x00, 0x20, 0x04, 0x20, 0x00, 0x20, 0x02, 0x80, 0x00, 0x20, 0x00, 0xfe, 0x3f, 0x00, 0x10, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x08, 0x00, 0x40, 0x00, 0xf0, 0x00, 0x40, 0x02, 0x20, 0x00, 0x10, 0x01, 0x40, 0x00, 0x10, 0x00, 0x80, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x08, 0x00, 0x40, 0x00, 0x08, 0x00, 0x80, 0x02, 0x20, 0x00, 0x88, 0x00, 0x20, 0x00, 0xf8, 0x0f, 0x80, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0xf8, 0x1f, 0x40, 0x00, 0x04, 0x00, 0x00, 0x01, 0xf0, 0x0f, 0xc0, 0x00, 0x40, 0x00, 0x00, 0x08, 0x40, 0x00, 0x80, 0x08, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x10, 0x80, 0x00, 0x04, 0x00, 0x00, 0x01, 0x00, 0x08, 0xa0, 0x00, 0x80, 0x00, 0x00, 0x08, 0x40, 0x00, 0x00, 0x05, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x10, 0x80, 0x00, 0x04, 0x00, 0x80, 0x02, 0x00, 0x08, 0x90, 0x00, 0x80, 0x00, 0x00, 0x08, 0x20, 0x00, 0x00, 0x02, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x01, 0x04, 0x10, 0x40, 0x04, 0x00, 0x04, 0x88, 0x00, 0x00, 0x01, 0x00, 0x08, 0x10, 0x04, 0x00, 0x05, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x02, 0x08, 0x08, 0x20, 0x08, 0x00, 0x04, 0x80, 0x00, 0x00, 0x01, 0x00, 0x08, 0xf8, 0x0f, 0xc0, 0x08, 0x00, 0x00, 0xe0, 0x0f, 0x00, 0x00, 0x00, 0x08, 0x00, 0x04, 0xf0, 0x07, 0x18, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x00, 0x04, 0x00, 0x10, 0x30, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x18, 0x00, 0x00, 0x06, 0x00, 0x40, 0x01, 0x80, 0x00, 0x00, 0x02, 0x00, 0x05, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x40, 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x40, 0x00, 0x40, 0x00, 0x80, 0x00, 0x00, 0x00, 0x80, 0x00, 0xf8, 0x1f, 0xfe, 0x3f, 0xfc, 0x3f, 0xfc, 0x03, 0x00, 0x00, 0x00, 0x00, 0x40, 0x04, 0x00, 0x00, 0x40, 0x00, 0x20, 0x04, 0x80, 0x00, 0x00, 0x10, 0x80, 0x00, 0x00, 0x10, 0x80, 0x00, 0x08, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x40, 0x00, 0x20, 0x04, 0xfe, 0x3f, 0x08, 0x10, 0x80, 0x00, 0x00, 0x10, 0x80, 0x00, 0x08, 0x00, 0x00, 0x01, 0xfc, 0x1f, 0xfe, 0x7f, 0x20, 0x08, 0x00, 0x00, 0xfe, 0x3f, 0x10, 0x02, 0x80, 0x00, 0x08, 0x10, 0x40, 0x00, 0x00, 0x10, 0x80, 0x00, 0x08, 0x00, 0x80, 0x00, 0x04, 0x10, 0xfe, 0x7f, 0x00, 0x04, 0x00, 0x00, 0x40, 0x01, 0x10, 0x02, 0x80, 0x00, 0x08, 0x10, 0x40, 0x00, 0xf8, 0x1f, 0x80, 0x00, 0x08, 0x00, 0xc0, 0x1f, 0x04, 0x10, 0xfe, 0x7f, 0x80, 0x03, 0x00, 0x00, 0x40, 0x01, 0xf8, 0x01, 0xf0, 0x00, 0x08, 0x10, 0x40, 0x00, 0x08, 0x00, 0x80, 0x00, 0x08, 0x00, 0x00, 0x10, 0x04, 0x10, 0x1e, 0x78, 0x00, 0x04, 0x00, 0x00, 0x40, 0x01, 0x80, 0x00, 0x08, 0x00, 0x08, 0x10, 0x20, 0x00, 0x08, 0x00, 0x80, 0x00, 0x08, 0x00, 0x00, 0x10, 0x04, 0x10, 0x06, 0x60, 0x00, 0x08, 0x00, 0x00, 0x20, 0x01, 0x40, 0x00, 0x04, 0x00, 0x04, 0x10, 0x20, 0x00, 0x08, 0x00, 0x80, 0x00, 0x08, 0x00, 0x00, 0x10, 0x04, 0x10, 0x02, 0x40, 0x20, 0x08, 0x00, 0x00, 0x20, 0x01, 0x20, 0x02, 0x04, 0x00, 0x04, 0x1e, 0x10, 0x02, 0x08, 0x00, 0x80, 0x00, 0x08, 0x00, 0x00, 0x10, 0x04, 0x10, 0x00, 0x00, 0x20, 0x08, 0x00, 0x00, 0x20, 0x01, 0x10, 0x04, 0x04, 0x00, 0xfc, 0x11, 0x08, 0x04, 0x08, 0x00, 0x80, 0x00, 0x04, 0x00, 0x00, 0x10, 0x04, 0x10, 0x00, 0x00, 0x40, 0x04, 0x00, 0x00, 0x10, 0x01, 0xf8, 0x0f, 0x04, 0x10, 0x00, 0x10, 0xfc, 0x0f, 0x04, 0x00, 0x80, 0x00, 0x04, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x80, 0x03, 0x00, 0x00, 0x08, 0x01, 0x00, 0x08, 0x08, 0x08, 0x00, 0x00, 0x00, 0x10, 0x04, 0x00, 0x80, 0x00, 0x02, 0x00, 0x80, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x3e, 0x00, 0x00, 0xf0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x80, 0x00, 0x01, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x30, 0x0c, 0x00, 0x03, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x10, 0x02, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x90, 0x00, 0xfc, 0x1f, 0x08, 0x10, 0x80, 0x02, 0x00, 0x00, 0x80, 0x00, 0xf8, 0x0f, 0x10, 0x02, 0x00, 0x00, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x00, 0x00, 0x90, 0x00, 0x08, 0x00, 0x04, 0x20, 0x80, 0x02, 0x00, 0x00, 0x80, 0x00, 0x00, 0x08, 0x10, 0x02, 0x00, 0x00, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x00, 0x00, 0x88, 0x00, 0x08, 0x00, 0xf4, 0x2f, 0x40, 0x02, 0x00, 0x00, 0x40, 0x00, 0x00, 0x04, 0xfe, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x1f, 0x08, 0x00, 0x02, 0x41, 0x40, 0x02, 0x00, 0x00, 0x40, 0x00, 0x20, 0x04, 0x10, 0x02, 0x00, 0x00, 0x00, 0x00, 0x50, 0x04, 0x00, 0x00, 0x00, 0x00, 0x80, 0x10, 0x08, 0x00, 0x02, 0x41, 0x20, 0x02, 0x00, 0x00, 0x20, 0x00, 0x40, 0x02, 0x10, 0x02, 0x00, 0x00, 0x00, 0x00, 0x90, 0x04, 0x00, 0x00, 0x00, 0x00, 0x80, 0x10, 0x08, 0x00, 0x22, 0x47, 0x20, 0x02, 0x00, 0x00, 0x20, 0x00, 0x80, 0x02, 0x10, 0x02, 0x00, 0x00, 0x00, 0x00, 0x10, 0x05, 0x00, 0x00, 0x00, 0x00, 0x80, 0x10, 0x08, 0x00, 0x22, 0x41, 0x10, 0x02, 0x00, 0x00, 0x10, 0x00, 0x00, 0x01, 0x10, 0x01, 0x00, 0x00, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x00, 0x00, 0x40, 0x10, 0x08, 0x00, 0x24, 0x21, 0xf0, 0x0f, 0x00, 0x00, 0x08, 0x00, 0x00, 0x01, 0x10, 0x01, 0x00, 0x00, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x00, 0x00, 0x40, 0x10, 0x08, 0x00, 0xf4, 0x2f, 0x00, 0x02, 0x00, 0x00, 0x04, 0x00, 0x80, 0x02, 0x90, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x00, 0x00, 0x20, 0x10, 0x08, 0x00, 0x08, 0x10, 0x00, 0x02, 0x00, 0x00, 0xfc, 0x1f, 0x40, 0x04, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x00, 0x00, 0x20, 0x10, 0x08, 0x00, 0x30, 0x0c, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0xe0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x10, 0x08, 0xf0, 0x3f, 0xc0, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x04, 0x00, 0x00}; �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_cs.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016062� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_cs.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_cs_width 32 #define align_cs_height 20 #define align_cs_x_hot 0 #define align_cs_y_hot 0 static unsigned char align_cs_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x0f, 0x60, 0x55, 0x55, 0x0d, 0xa0, 0xaa, 0xaa, 0x0a, 0x60, 0x55, 0x55, 0x0d, 0xa0, 0xfa, 0xaf, 0x0a, 0x60, 0x3d, 0x70, 0x0d, 0xa0, 0x36, 0xc0, 0x0a, 0xe0, 0x53, 0x80, 0x0f, 0x00, 0xd1, 0x00, 0x01, 0x00, 0xb1, 0x00, 0x01, 0x00, 0x11, 0x01, 0x01, 0x00, 0x91, 0x03, 0x01, 0x00, 0x52, 0x82, 0x00, 0x00, 0x34, 0x46, 0x00, 0x00, 0x18, 0x3d, 0x00, 0x00, 0x90, 0x08, 0x00, 0x00, 0x50, 0x14, 0x00, 0x00, 0x30, 0x12, 0x00, 0x00, 0xf0, 0x3f, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/rightend.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000000704�10064674125�016103� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/rightend.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define rightend_width 16 #define rightend_height 16 #define rightend_x_hot 0 #define rightend_y_hot 0 static unsigned char rightend_bits[] = { 0xff, 0xff, 0x01, 0x80, 0x09, 0x90, 0x39, 0x90, 0x49, 0x90, 0x89, 0x91, 0x09, 0x96, 0x09, 0x98, 0x09, 0x98, 0x09, 0x96, 0x89, 0x91, 0x49, 0x90, 0x39, 0x90, 0x09, 0x90, 0x01, 0x80, 0xff, 0xff}; ������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_rm.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016073� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_rm.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_rm_width 32 #define align_rm_height 20 #define align_rm_x_hot 0 #define align_rm_y_hot 0 static unsigned char align_rm_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00, 0xf0, 0x07, 0x00, 0x00, 0x4c, 0x19, 0x00, 0xfe, 0x43, 0xe3, 0x00, 0x56, 0xc1, 0xc2, 0x00, 0xaa, 0x40, 0x84, 0x00, 0xd6, 0x40, 0x8e, 0x00, 0xaa, 0x40, 0x89, 0x00, 0xd6, 0xc0, 0x98, 0x00, 0xaa, 0x41, 0xf4, 0x00, 0xfe, 0x43, 0xe2, 0x00, 0x00, 0x4c, 0x51, 0x00, 0x00, 0xf0, 0x48, 0x00, 0x00, 0xc0, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/mag.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000001124�10064674124�015037� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/mag.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define mag_width 20 #define mag_height 20 #define mag_x_hot 8 #define mag_y_hot 8 static unsigned char mag_bits[] = { 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0xf0, 0x1f, 0x00, 0x38, 0x38, 0x00, 0x0c, 0x60, 0x00, 0x8c, 0x63, 0x00, 0x86, 0xc3, 0x00, 0xe6, 0xcf, 0x00, 0xe6, 0xcf, 0x00, 0xe6, 0xcf, 0x00, 0x86, 0xc3, 0x00, 0x8c, 0x63, 0x00, 0x0c, 0x60, 0x00, 0x38, 0xf8, 0x01, 0xf0, 0xff, 0x03, 0xc0, 0xe7, 0x07, 0x00, 0xa0, 0x07, 0x00, 0x40, 0x07, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/arc.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000001322�10064674124�015040� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/arc.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define arc_width 32 #define arc_height 20 #define arc_x_hot 0 #define arc_y_hot 0 static unsigned char arc_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x00, 0x00, 0x00, 0x90, 0x01, 0x00, 0x00, 0x08, 0x06, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0x08, 0x10, 0x00, 0x00, 0x08, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x04, 0x80, 0x00, 0x00, 0x02, 0xfc, 0x00, 0x00, 0x02, 0x7c, 0x00, 0x00, 0x02, 0x3f, 0x00, 0x00, 0xe3, 0x18, 0x00, 0x00, 0x1d, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_t.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674124�015713� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_t.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_t_width 32 #define align_t_height 20 #define align_t_x_hot 0 #define align_t_y_hot 0 static unsigned char align_t_bits[] = { 0x00, 0xfc, 0x0f, 0x00, 0x00, 0xfc, 0x0f, 0x00, 0x00, 0xc0, 0x20, 0x00, 0x00, 0xc0, 0x3e, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0xc0, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld2.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014760� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld2.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld2_width 64 #define ld2_height 20 #define ld2_x_hot 0 #define ld2_y_hot 0 static unsigned char ld2_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x78, 0x78, 0x78, 0x78, 0x78, 0x78, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/box.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000001322�10064674124�015063� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/box.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define box_width 32 #define box_height 20 #define box_x_hot 0 #define box_y_hot 0 static unsigned char box_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/just_c.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674124�015566� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/just_c.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define just_c_width 32 #define just_c_height 20 #define just_c_x_hot 0 #define just_c_y_hot 0 static unsigned char just_c_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfc, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/intr.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000654�10064674124�015256� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/intr.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define intr_width 16 #define intr_height 16 #define intr_x_hot 0 #define intr_y_hot 0 static unsigned char intr_bits[] = { 0xe0, 0x03, 0xf8, 0x0c, 0xfc, 0x10, 0xfe, 0x20, 0xfe, 0x20, 0xff, 0x40, 0xff, 0x40, 0xff, 0x7f, 0x81, 0x7f, 0x81, 0x7f, 0x82, 0x3f, 0x82, 0x3f, 0x84, 0x1f, 0x98, 0x0f, 0xe0, 0x03, 0x00, 0x00}; ������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/printer.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015762� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/printer.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define printer_width 32 #define printer_height 20 #define printer_x_hot 0 #define printer_y_hot 0 static unsigned char printer_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x7f, 0x80, 0x00, 0x00, 0x40, 0x80, 0x00, 0x00, 0x40, 0x80, 0x00, 0x00, 0x40, 0x80, 0xff, 0xff, 0x7f, 0x80, 0x22, 0x00, 0x41, 0x80, 0x2a, 0x00, 0x41, 0x80, 0x2a, 0x00, 0x41, 0x80, 0x22, 0x00, 0x21, 0x86, 0xff, 0xff, 0x11, 0xb8, 0x02, 0x00, 0x0a, 0xc0, 0xf3, 0x7f, 0x14, 0x00, 0x02, 0x00, 0x70, 0x80, 0xf3, 0x7f, 0x10, 0x80, 0x03, 0x00, 0x10, 0x00, 0xfe, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat9.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000352�10064674125�015153� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat9.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat9_width 8 #define pat9_height 8 static unsigned char pat9_bits[] = { 0xee, 0xff, 0xbb, 0xff, 0xee, 0xff, 0xbb, 0xff}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/tiffepsi.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001360�10064674125�016107� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/tiffepsi.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define tiffepsi_width 32 #define tiffepsi_height 20 #define tiffepsi_x_hot 0 #define tiffepsi_y_hot 0 static unsigned char tiffepsi_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x1f, 0x00, 0x40, 0x00, 0x30, 0x00, 0x40, 0xd7, 0x56, 0x00, 0x40, 0x52, 0x92, 0x00, 0x40, 0xd2, 0x16, 0x01, 0x40, 0x52, 0xf2, 0x03, 0x40, 0x52, 0x02, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x6f, 0xec, 0x02, 0x40, 0xa1, 0x42, 0x02, 0x40, 0xa1, 0x42, 0x02, 0x40, 0x67, 0x44, 0x02, 0x40, 0x21, 0x48, 0x02, 0x40, 0x21, 0x48, 0x02, 0x40, 0x2f, 0xe6, 0x02, 0x40, 0x00, 0x00, 0x02, 0xc0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat15.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674124�015233� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat15.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat15_width 8 #define pat15_height 8 static unsigned char pat15_bits[] = { 0xff, 0x01, 0x01, 0x01, 0xff, 0x10, 0x10, 0x10}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ls1s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015154� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ls1s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ls1s_width 32 #define ls1s_height 20 #define ls1s_x_hot 0 #define ls1s_y_hot 0 static unsigned char ls1s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x06, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_st.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016103� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_st.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_st_width 32 #define align_st_height 20 #define align_st_x_hot 0 #define align_st_y_hot 0 static unsigned char align_st_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0xc6, 0x71, 0x1c, 0xc7, 0xc6, 0x71, 0x1c, 0xc7, 0xc6, 0x71, 0x1c, 0xc7, 0xc6, 0x71, 0x1c, 0xc7, 0xee, 0xfb, 0xbe, 0xef, 0xee, 0xfb, 0xbe, 0xef, 0xee, 0xfb, 0xbe, 0xef, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat1.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000424�10064674124�015142� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat1.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat1_width 8 #define pat1_height 8 #define pat1_x_hot 0 #define pat1_y_hot 0 static unsigned char pat1_bits[] = { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pattrans.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674125�016140� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pattrans.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pattrans_width 32 #define pattrans_height 20 #define pattrans_x_hot 0 #define pattrans_y_hot 0 static unsigned char pattrans_bits[] = { 0x11, 0x11, 0x11, 0x11, 0x22, 0x22, 0x62, 0x22, 0x44, 0x44, 0x74, 0x44, 0x88, 0x88, 0x9c, 0x08, 0x11, 0x11, 0x9b, 0x11, 0x22, 0xe2, 0xa6, 0x22, 0x44, 0x74, 0x46, 0x45, 0x88, 0x98, 0x89, 0x09, 0x11, 0x97, 0x91, 0x11, 0xa2, 0x63, 0x62, 0x22, 0x64, 0x64, 0x64, 0x46, 0x98, 0x98, 0x98, 0x0a, 0x1d, 0x19, 0x19, 0x15, 0xf2, 0x26, 0x26, 0x26, 0x44, 0x4f, 0x46, 0x46, 0x88, 0xf8, 0x89, 0x09, 0x11, 0x91, 0x97, 0x19, 0x22, 0x22, 0x7a, 0x2a, 0x44, 0x44, 0xc4, 0x57, 0x88, 0x88, 0x88, 0x18}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ls2.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014777� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ls2.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ls2_width 64 #define ls2_height 20 #define ls2_x_hot 0 #define ls2_y_hot 0 static unsigned char ls2_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat8.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000352�10064674125�015152� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat8.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat8_width 8 #define pat8_height 8 static unsigned char pat8_bits[] = { 0xee, 0xbb, 0xee, 0xbb, 0xee, 0xbb, 0xee, 0xbb}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat31.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674125�015232� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat31.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat31_width 8 #define pat31_height 8 static unsigned char pat31_bits[] = { 0x3e, 0x1f, 0x8f, 0xc7, 0xe3, 0xf1, 0xf8, 0x7c}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/btn2.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000654�10064674124�015147� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/btn2.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define btn2_width 16 #define btn2_height 16 #define btn2_x_hot 0 #define btn2_y_hot 0 static unsigned char btn2_bits[] = { 0xfe, 0x3f, 0x01, 0x40, 0x01, 0x40, 0xdd, 0x5d, 0xd5, 0x55, 0xd5, 0x55, 0xd5, 0x55, 0xd5, 0x55, 0xdd, 0x5d, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0x01, 0x40, 0xfe, 0x3f}; ������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape4.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015464� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape4.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape4_width 32 #define shape4_height 20 #define shape4_x_hot 0 #define shape4_y_hot 0 static unsigned char shape4_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x80, 0x01, 0x80, 0x01, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x80, 0x01, 0x80, 0x01, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/text.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674125�015257� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/text.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define text_width 32 #define text_height 20 #define text_x_hot 0 #define text_y_hot 0 static unsigned char text_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0xff, 0x01, 0x80, 0x83, 0xc1, 0x01, 0x80, 0x81, 0x81, 0x01, 0x80, 0x80, 0x01, 0x01, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0xc0, 0x03, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_sn.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001366�10064674124�016075� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_sn.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_sn_width 32 #define align_sn_height 20 #define align_sn_x_hot 0 #define align_sn_y_hot 0 static unsigned char align_sn_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x82, 0x20, 0x08, 0x82, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat13.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674124�015231� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat13.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat13_width 8 #define pat13_height 8 static unsigned char pat13_bits[] = { 0x02, 0x05, 0x00, 0x00, 0x20, 0x50, 0x00, 0x00}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/run.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000000646�10064674125�015110� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/run.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define run_width 16 #define run_height 16 #define run_x_hot 0 #define run_y_hot 0 static unsigned char run_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x80, 0x04, 0x80, 0x04, 0x00, 0x03, 0x00, 0x07, 0x00, 0x0b, 0x80, 0x13, 0x60, 0x03, 0x00, 0x07, 0x00, 0x0b, 0xc0, 0x10, 0x30, 0x0c, 0x00, 0x00, 0xfe, 0x03}; ������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/corner.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000000670�10064674124�015570� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/corner.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define corner_width 16 #define corner_height 16 #define corner_x_hot 0 #define corner_y_hot 0 static unsigned char corner_bits[] = { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x0f, 0x00, 0x0f, 0x00, 0x0f, 0x00, 0x0f, 0x00, 0x0f, 0x00, 0x0f, 0x00, 0x0f, 0x00, 0x0f, 0x00, 0x0f, 0x00, 0x0f, 0x00, 0x0f, 0x00, 0x0f, 0x00}; ������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/poly.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674125�015256� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/poly.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define poly_width 32 #define poly_height 20 #define poly_x_hot 0 #define poly_y_hot 0 static unsigned char poly_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x03, 0x10, 0x00, 0xf0, 0x02, 0x20, 0x00, 0x0e, 0x02, 0x20, 0xe0, 0x01, 0x02, 0x20, 0x18, 0x00, 0x04, 0x20, 0x30, 0x00, 0x04, 0x20, 0x40, 0x00, 0x04, 0x20, 0x80, 0x01, 0x04, 0x20, 0x00, 0x06, 0x04, 0x40, 0x00, 0x08, 0x04, 0x40, 0x00, 0x30, 0x08, 0x40, 0x80, 0x7f, 0x08, 0xc0, 0x7f, 0x00, 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat4.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000352�10064674125�015146� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat4.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat4_width 8 #define pat4_height 8 static unsigned char pat4_bits[] = { 0x11, 0x00, 0x00, 0x00, 0x44, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw4s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015163� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw4s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw4s_width 32 #define lw4s_height 20 #define lw4s_x_hot 0 #define lw4s_y_hot 0 static unsigned char lw4s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape10.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015540� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape10.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape10_width 32 #define shape10_height 20 #define shape10_x_hot 0 #define shape10_y_hot 0 static unsigned char shape10_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x00, 0x40, 0x02, 0x00, 0x00, 0x40, 0x02, 0x00, 0x00, 0x20, 0x04, 0x00, 0x00, 0x20, 0x04, 0x00, 0x00, 0x10, 0x08, 0x00, 0x00, 0x10, 0x08, 0x00, 0x00, 0x08, 0x10, 0x00, 0x00, 0x08, 0x10, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0xc0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/arc_edge.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001360�10064674124�016026� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/arc_edge.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define arc_edge_width 32 #define arc_edge_height 20 #define arc_edge_x_hot 0 #define arc_edge_y_hot 0 static unsigned char arc_edge_bits[] = { 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x90, 0x01, 0x00, 0x00, 0x18, 0x06, 0x00, 0x00, 0x08, 0x48, 0x00, 0x00, 0x08, 0x70, 0x00, 0x00, 0x08, 0x70, 0x00, 0x00, 0x04, 0x7c, 0x00, 0x00, 0x04, 0x70, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x04, 0x80, 0x00, 0x00, 0x02, 0xc0, 0x00, 0x00, 0x02, 0x38, 0x00, 0x00, 0x02, 0x07, 0x00, 0x00, 0xe2, 0x00, 0x00, 0x00, 0x1d, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/just_l.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674124�015577� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/just_l.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define just_l_width 32 #define just_l_height 20 #define just_l_x_hot 0 #define just_l_y_hot 0 static unsigned char just_l_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/jpeg.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015217� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/jpeg.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define jpeg_width 32 #define jpeg_height 20 #define jpeg_x_hot 0 #define jpeg_y_hot 0 static unsigned char jpeg_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xe0, 0xff, 0x7f, 0x00, 0x20, 0x00, 0xc0, 0x00, 0x20, 0x00, 0x40, 0x01, 0x20, 0x00, 0x40, 0x02, 0x20, 0x00, 0x40, 0x04, 0x20, 0x00, 0xc0, 0x0f, 0x20, 0x00, 0x00, 0x08, 0x20, 0x00, 0x00, 0x08, 0x20, 0x77, 0x9e, 0x09, 0x20, 0x92, 0x42, 0x0a, 0x20, 0x92, 0x42, 0x08, 0x20, 0x72, 0x4e, 0x0b, 0x20, 0x12, 0x42, 0x0a, 0xa0, 0x12, 0x42, 0x0a, 0x20, 0x11, 0x9e, 0x09, 0x20, 0x00, 0x00, 0x08, 0x20, 0x00, 0x00, 0x08, 0xe0, 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/epsi.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015232� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/epsi.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define epsi_width 32 #define epsi_height 20 #define epsi_x_hot 0 #define epsi_y_hot 0 static unsigned char epsi_bits[] = { 0x00, 0x00, 0x00, 0x00, 0xc0, 0xff, 0x1f, 0x00, 0x40, 0x00, 0x30, 0x00, 0x40, 0x00, 0x50, 0x00, 0x40, 0x00, 0x90, 0x00, 0x40, 0x00, 0x10, 0x01, 0x40, 0x00, 0xf0, 0x03, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x6f, 0xec, 0x02, 0x40, 0xa1, 0x42, 0x02, 0x40, 0xa1, 0x42, 0x02, 0x40, 0x67, 0x44, 0x02, 0x40, 0x21, 0x48, 0x02, 0x40, 0x21, 0x48, 0x02, 0x40, 0x2f, 0xe6, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0xc0, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/submenu.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000000465�10064674125�015761� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/submenu.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define submenu_width 9 #define submenu_height 9 static unsigned char submenu_bits[] = { 0x00, 0x00, 0x08, 0x00, 0x18, 0x00, 0x38, 0x00, 0x78, 0x00, 0x38, 0x00, 0x18, 0x00, 0x08, 0x00, 0x00, 0x00}; �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld3s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015137� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld3s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld3s_width 32 #define ld3s_height 20 #define ld3s_x_hot 0 #define ld3s_y_hot 0 static unsigned char ld3s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xf9, 0xf9, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/chkall.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000000670�10064674124�015536� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/chkall.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define chkall_width 16 #define chkall_height 16 #define chkall_x_hot 0 #define chkall_y_hot 0 static unsigned char chkall_bits[] = { 0xff, 0xff, 0x01, 0x80, 0xfd, 0x81, 0x8d, 0x81, 0x55, 0x81, 0x25, 0x81, 0x55, 0x81, 0x8d, 0x81, 0xfd, 0x81, 0x01, 0x80, 0x01, 0x9c, 0x01, 0x8c, 0x01, 0x94, 0x01, 0xa0, 0x01, 0x80, 0xff, 0xff}; ������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat17.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674124�015235� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat17.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat17_width 8 #define pat17_height 8 static unsigned char pat17_bits[] = { 0xc0, 0x21, 0x12, 0x0c, 0x30, 0x40, 0x80, 0x80}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat24.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674125�015234� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat24.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat24_width 8 #define pat24_height 8 static unsigned char pat24_bits[] = { 0xfe, 0xfd, 0xfb, 0xf7, 0xef, 0xdf, 0xbf, 0x7f}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld7.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014765� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld7.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld7_width 64 #define ld7_height 20 #define ld7_x_hot 0 #define ld7_y_hot 0 static unsigned char ld7_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0xf8, 0x07, 0xf8, 0x07, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lt1.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014777� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lt1.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lt1_width 64 #define lt1_height 20 #define lt1_x_hot 0 #define lt1_y_hot 0 static unsigned char lt1_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x03, 0x0e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1c, 0x00, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x30, 0x00, 0x80, 0x03, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw1.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�015002� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw1.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw1_width 64 #define lw1_height 20 #define lw1_x_hot 0 #define lw1_y_hot 0 static unsigned char lw1_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/info.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000002004�10064674124�015224� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/info.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define info_width 32 #define info_height 32 #define info_x_hot 0 #define info_y_hot 0 static unsigned char info_bits[] = { 0x00, 0xf0, 0x0f, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x80, 0x3f, 0xfc, 0x01, 0xc0, 0x1f, 0xf8, 0x03, 0xe0, 0x0f, 0xf0, 0x07, 0xf0, 0x0f, 0xf0, 0x0f, 0xf8, 0x0f, 0xf0, 0x1f, 0xfc, 0x1f, 0xf8, 0x3f, 0xfc, 0x3f, 0xfc, 0x3f, 0xfe, 0xff, 0xff, 0x7f, 0xfe, 0xff, 0xff, 0x7f, 0xfe, 0x07, 0xf0, 0x7f, 0xff, 0x07, 0xf0, 0xff, 0xff, 0x3f, 0xf0, 0xff, 0xff, 0x3f, 0xf0, 0xff, 0xff, 0x3f, 0xf0, 0xff, 0xff, 0x3f, 0xf0, 0xff, 0xff, 0x3f, 0xf0, 0xff, 0xff, 0x3f, 0xf0, 0xff, 0xff, 0x3f, 0xf0, 0xff, 0xfe, 0x3f, 0xf0, 0x7f, 0xfe, 0x3f, 0xf0, 0x7f, 0xfe, 0x3f, 0xf0, 0x7f, 0xfc, 0x3f, 0xf0, 0x3f, 0xfc, 0x3f, 0xf0, 0x3f, 0xf8, 0x07, 0x80, 0x1f, 0xf0, 0x07, 0x80, 0x0f, 0xe0, 0x07, 0x80, 0x07, 0xc0, 0xff, 0xff, 0x03, 0x80, 0xff, 0xff, 0x01, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0xf0, 0x0f, 0x00}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/tile.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674125�015230� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/tile.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define tile_width 32 #define tile_height 20 #define tile_x_hot 0 #define tile_y_hot 0 static unsigned char tile_bits[] = { 0xc0, 0xe7, 0xf3, 0x01, 0x20, 0x0c, 0x06, 0x03, 0x20, 0x1c, 0x0e, 0x07, 0x20, 0x10, 0x08, 0x04, 0x20, 0x10, 0x08, 0x04, 0x20, 0x10, 0x08, 0x04, 0x20, 0x10, 0x08, 0x04, 0x20, 0x10, 0x08, 0x04, 0x20, 0x10, 0x08, 0x04, 0xc0, 0xe7, 0xf3, 0x01, 0x20, 0x0c, 0x06, 0x03, 0x20, 0x1c, 0x0e, 0x07, 0x20, 0x10, 0x08, 0x04, 0x20, 0x10, 0x08, 0x04, 0x20, 0x10, 0x08, 0x04, 0x20, 0x10, 0x08, 0x04, 0x20, 0x10, 0x08, 0x04, 0x20, 0x10, 0x08, 0x04, 0xc0, 0xe7, 0xf3, 0x03, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_r.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674124�015711� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_r.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_r_width 32 #define align_r_height 20 #define align_r_x_hot 0 #define align_r_y_hot 0 static unsigned char align_r_bits[] = { 0x00, 0xfc, 0x07, 0x00, 0x00, 0xfc, 0x0f, 0x00, 0x00, 0x0c, 0x1c, 0x00, 0x00, 0xec, 0x19, 0x00, 0x00, 0x2c, 0x58, 0x00, 0x00, 0x2c, 0x58, 0x00, 0x00, 0x2c, 0x58, 0x00, 0x00, 0x0c, 0x5c, 0x00, 0x00, 0xfc, 0x4f, 0x00, 0x00, 0xfc, 0x67, 0x00, 0x00, 0xcc, 0x31, 0x00, 0x00, 0x8c, 0x13, 0x00, 0x00, 0x2c, 0x07, 0x00, 0x00, 0x2c, 0x0e, 0x00, 0x00, 0x2c, 0x1c, 0x00, 0x00, 0x2c, 0x38, 0x00, 0x00, 0x2c, 0x30, 0x00, 0x00, 0x20, 0x80, 0x00, 0x00, 0x30, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld1s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015135� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld1s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld1s_width 32 #define ld1s_height 20 #define ld1s_x_hot 0 #define ld1s_y_hot 0 static unsigned char ld1s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat19.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674124�015237� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat19.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat19_width 8 #define pat19_height 8 static unsigned char pat19_bits[] = { 0x01, 0x01, 0x82, 0x7c, 0x10, 0x10, 0x28, 0xc7}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lfarrow.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000000676�10064674124�015762� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lfarrow.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lfarrow_width 16 #define lfarrow_height 16 #define lfarrow_x_hot 0 #define lfarrow_y_hot 0 static unsigned char lfarrow_bits[] = { 0xff, 0xff, 0x01, 0x80, 0x01, 0x88, 0x01, 0x8e, 0x01, 0x89, 0xc1, 0x88, 0x31, 0x88, 0x09, 0x88, 0x09, 0x88, 0x31, 0x88, 0xc1, 0x88, 0x01, 0x89, 0x01, 0x8e, 0x01, 0x88, 0x01, 0x80, 0xff, 0xff}; ������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ascii.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000001336�10064674124�015370� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ascii.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ascii_width 32 #define ascii_height 20 #define ascii_x_hot 0 #define ascii_y_hot 0 static unsigned char ascii_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x03, 0x00, 0x00, 0x02, 0x06, 0x00, 0x00, 0x02, 0x0a, 0x00, 0x00, 0x02, 0x12, 0x00, 0x00, 0x02, 0x22, 0x00, 0x00, 0x02, 0x7e, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0xe2, 0x43, 0x00, 0x00, 0x82, 0x40, 0x00, 0x00, 0x82, 0x40, 0x00, 0x00, 0x82, 0x40, 0x00, 0x00, 0x82, 0x40, 0x00, 0x00, 0x82, 0x40, 0x00, 0x00, 0x82, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0xfe, 0x7f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ppm.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000001322�10064674125�015070� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ppm.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define ppm_width 32 #define ppm_height 20 #define ppm_x_hot 0 #define ppm_y_hot 0 static unsigned char ppm_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x80, 0xff, 0x1f, 0x00, 0x80, 0x00, 0x30, 0x00, 0x80, 0x00, 0x50, 0x00, 0x80, 0x00, 0x90, 0x00, 0x80, 0x00, 0x10, 0x01, 0x80, 0x00, 0xf0, 0x03, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0xce, 0x89, 0x02, 0x80, 0x52, 0x8a, 0x02, 0x80, 0x52, 0xda, 0x02, 0x80, 0xce, 0xd9, 0x02, 0x80, 0x42, 0xa8, 0x02, 0x80, 0x42, 0xa8, 0x02, 0x80, 0x42, 0x88, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0xff, 0xff, 0x03, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ls3.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�015000� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ls3.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ls3_width 64 #define ls3_height 20 #define ls3_x_hot 0 #define ls3_y_hot 0 static unsigned char ls3_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x80, 0x01, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld8.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014766� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld8.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld8_width 64 #define ld8_height 20 #define ld8_x_hot 0 #define ld8_y_hot 0 static unsigned char ld8_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa8, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat10.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674124�015226� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat10.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat10_width 8 #define pat10_height 8 static unsigned char pat10_bits[] = { 0xee, 0xff, 0xff, 0xff, 0xbb, 0xff, 0xff, 0xff}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw5s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015164� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw5s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw5s_width 32 #define lw5s_height 20 #define lw5s_x_hot 0 #define lw5s_y_hot 0 static unsigned char lw5s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat27.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674125�015237� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat27.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat27_width 8 #define pat27_height 8 static unsigned char pat27_bits[] = { 0x88, 0x44, 0x22, 0x11, 0x88, 0x44, 0x22, 0x11}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape5.xbm�����������������������������������������������������������������������0000644�0000764�0000764�00000001344�10064674125�015465� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape5.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape5_width 32 #define shape5_height 20 #define shape5_x_hot 0 #define shape5_y_hot 0 static unsigned char shape5_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x08, 0x10, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x01, 0x80, 0x00, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x00, 0x01, 0x80, 0x00, 0x00, 0x02, 0x40, 0x00, 0x00, 0x04, 0x20, 0x00, 0x00, 0x08, 0x10, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat12.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000000356�10064674124�015230� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat12.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define pat12_width 8 #define pat12_height 8 static unsigned char pat12_bits[] = { 0x01, 0x02, 0x04, 0x00, 0x40, 0x20, 0x10, 0x00}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/nstretch.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001360�10064674124�016127� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/nstretch.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define nstretch_width 32 #define nstretch_height 20 #define nstretch_x_hot 0 #define nstretch_y_hot 0 static unsigned char nstretch_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x25, 0x00, 0x00, 0x00, 0x87, 0x00, 0x00, 0x80, 0x08, 0x02, 0x00, 0x80, 0x08, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x40, 0x00, 0x00, 0x20, 0x40, 0x00, 0x00, 0x80, 0xa0, 0x00, 0x00, 0x00, 0xe2, 0x00, 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x10, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/drip_msk.xbm���������������������������������������������������������������������0000644�0000764�0000764�00000001164�10064674124�016107� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/drip_msk.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define drip_msk_width 20 #define drip_msk_height 20 #define drip_msk_x_hot 10 #define drip_msk_y_hot 18 static unsigned char drip_msk_bits[] = { 0x80, 0x0f, 0x00, 0xe0, 0x3f, 0x00, 0xe0, 0x3f, 0x00, 0xf0, 0x7f, 0x00, 0xf0, 0x7f, 0x00, 0xf0, 0x7f, 0x00, 0xf0, 0x7f, 0x00, 0xf0, 0x7f, 0x00, 0xf0, 0x7f, 0x00, 0xe0, 0x3f, 0x00, 0xe0, 0x3f, 0x00, 0xc0, 0x1f, 0x00, 0x80, 0x0f, 0x00, 0x80, 0x0f, 0x00, 0x80, 0x0f, 0x00, 0x80, 0x0f, 0x00, 0x80, 0x0f, 0x00, 0x00, 0x0f, 0x00, 0x00, 0x0a, 0x00, 0x00, 0x0e, 0x00}; ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ls0.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000002307�10064674124�014775� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ls0.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ls0_width 64 #define ls0_height 20 #define ls0_x_hot 0 #define ls0_y_hot 0 static unsigned char ls0_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x04, 0x51, 0x04, 0x00, 0x00, 0x00, 0x00, 0x20, 0x05, 0xd1, 0x04, 0x00, 0x00, 0x00, 0x00, 0x20, 0x85, 0x52, 0x05, 0x00, 0x00, 0x00, 0x00, 0xe0, 0x84, 0x53, 0x05, 0x00, 0x00, 0x00, 0x00, 0x20, 0x44, 0x54, 0x06, 0x00, 0x00, 0x00, 0x00, 0x20, 0x5c, 0x54, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/italic1.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001160�10064674124�015621� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/italic1.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define italic1_width 20 #define italic1_height 20 #define italic1_x_hot 0 #define italic1_y_hot 0 static unsigned char italic1_bits[] = { 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x1c, 0xf0, 0x00, 0x08, 0xf0, 0x00, 0x08, 0xf0, 0x00, 0x04, 0xf0, 0x00, 0x04, 0xf0, 0x00, 0x04, 0xf0, 0x00, 0x02, 0xf0, 0x00, 0x02, 0xf0, 0x00, 0x02, 0xf0, 0x00, 0x07, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/rot_0.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000001336�10064674125�015324� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/rot_0.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define rot_0_width 32 #define rot_0_height 20 #define rot_0_x_hot 0 #define rot_0_y_hot 0 static unsigned char rot_0_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0x0c, 0x61, 0x00, 0x00, 0x04, 0x41, 0x00, 0x00, 0x82, 0x83, 0x00, 0x00, 0x82, 0x83, 0x00, 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x01, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x01, 0x00, 0x02, 0x80, 0x00, 0x00, 0x02, 0x80, 0x00, 0x00, 0x04, 0x40, 0x00, 0x00, 0x0c, 0x60, 0x00, 0x00, 0x30, 0x18, 0x00, 0x00, 0xc0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/shape15.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674125�015545� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/shape15.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define shape15_width 32 #define shape15_height 20 #define shape15_x_hot 0 #define shape15_y_hot 0 static unsigned char shape15_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x40, 0x01, 0x00, 0x00, 0x20, 0x02, 0x00, 0x00, 0x10, 0x04, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0x04, 0x10, 0x00, 0x00, 0x02, 0x20, 0x00, 0x00, 0x01, 0x40, 0x00, 0x80, 0x0f, 0xf8, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0x08, 0x08, 0x00, 0x00, 0xf8, 0x0f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/align_s.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000001352�10064674124�015712� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/align_s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define align_s_width 32 #define align_s_height 20 #define align_s_x_hot 0 #define align_s_y_hot 0 static unsigned char align_s_bits[] = { 0x00, 0xf0, 0x07, 0x00, 0x00, 0xf8, 0x0f, 0x00, 0x00, 0x1c, 0x1c, 0x00, 0x00, 0xcc, 0x19, 0x00, 0x00, 0x6c, 0x00, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00, 0x00, 0xf0, 0x0f, 0x00, 0x00, 0x00, 0x1c, 0x00, 0x00, 0xc0, 0x19, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x0c, 0x58, 0x00, 0x00, 0x1c, 0x5c, 0x00, 0x00, 0xf8, 0x4f, 0x00, 0x00, 0xf0, 0x47, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0xc0, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat6.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000352�10064674125�015150� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat6.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat6_width 8 #define pat6_height 8 static unsigned char pat6_bits[] = { 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat2.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000352�10064674125�015144� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat2.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat2_width 8 #define pat2_height 8 static unsigned char pat2_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/drip.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001134�10064674124�015232� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/drip.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define drip_width 20 #define drip_height 20 #define drip_x_hot 10 #define drip_y_hot 18 static unsigned char drip_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0xc0, 0x1a, 0x00, 0x40, 0x15, 0x00, 0xa0, 0x2a, 0x00, 0x60, 0x35, 0x00, 0xa0, 0x2a, 0x00, 0x60, 0x35, 0x00, 0xc0, 0x1a, 0x00, 0x40, 0x15, 0x00, 0x80, 0x0f, 0x00, 0x00, 0x07, 0x00, 0x00, 0x05, 0x00, 0x00, 0x05, 0x00, 0x00, 0x05, 0x00, 0x00, 0x05, 0x00, 0x00, 0x06, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/bold1.xbm������������������������������������������������������������������������0000644�0000764�0000764�00000001144�10064674124�015276� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/bold1.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define bold1_width 20 #define bold1_height 20 #define bold1_x_hot 0 #define bold1_y_hot 0 static unsigned char bold1_bits[] = { 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0xc0, 0x1f, 0xf0, 0x80, 0x31, 0xf0, 0x80, 0x31, 0xf0, 0x80, 0x31, 0xf0, 0x80, 0x1f, 0xf0, 0x80, 0x31, 0xf0, 0x80, 0x31, 0xf0, 0x80, 0x31, 0xf0, 0x80, 0x31, 0xf0, 0xc0, 0x1f, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0, 0x00, 0x00, 0xf0}; ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld8s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015144� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld8s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld8s_width 32 #define ld8s_height 20 #define ld8s_x_hot 0 #define ld8s_y_hot 0 static unsigned char ld8s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xa8, 0xaa, 0xaa, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/xbm.xbm��������������������������������������������������������������������������0000644�0000764�0000764�00000001322�10064674125�015062� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/xbm.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define xbm_width 32 #define xbm_height 20 #define xbm_x_hot 0 #define xbm_y_hot 0 static unsigned char xbm_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x07, 0x00, 0x00, 0x01, 0x0c, 0x00, 0x00, 0x41, 0x15, 0x00, 0x00, 0x55, 0x25, 0x00, 0x00, 0x49, 0x45, 0x00, 0x00, 0x49, 0xfd, 0x00, 0x00, 0x55, 0x81, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0x39, 0x91, 0x00, 0x00, 0x49, 0x9b, 0x00, 0x00, 0x49, 0x9b, 0x00, 0x00, 0x39, 0x95, 0x00, 0x00, 0x49, 0x95, 0x00, 0x00, 0x49, 0x91, 0x00, 0x00, 0x39, 0x91, 0x00, 0x00, 0x01, 0x80, 0x00, 0x00, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/pat5.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000000352�10064674125�015147� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/pat5.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define pat5_width 8 #define pat5_height 8 static unsigned char pat5_bits[] = { 0x11, 0x00, 0x44, 0x00, 0x11, 0x00, 0x44, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/lw3s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015162� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/lw3s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define lw3s_width 32 #define lw3s_height 20 #define lw3s_x_hot 0 #define lw3s_y_hot 0 static unsigned char lw3s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0xf8, 0xff, 0xff, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/rtarrow.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000000676�10064674125�016007� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/rtarrow.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define rtarrow_width 16 #define rtarrow_height 16 #define rtarrow_x_hot 0 #define rtarrow_y_hot 0 static unsigned char rtarrow_bits[] = { 0xff, 0xff, 0x01, 0x80, 0x11, 0x80, 0x71, 0x80, 0x91, 0x80, 0x11, 0x83, 0x11, 0x8c, 0x11, 0x90, 0x11, 0x90, 0x11, 0x8c, 0x11, 0x83, 0x91, 0x80, 0x71, 0x80, 0x11, 0x80, 0x01, 0x80, 0xff, 0xff}; ������������������������������������������������������������������tgif-QPL-4.2.5/xbm/ld6s.xbm�������������������������������������������������������������������������0000644�0000764�0000764�00000001330�10064674124�015142� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/ld6s.xbm,v 1.1 2004/06/18 23:18:44 william Exp $ */ #define ld6s_width 32 #define ld6s_height 20 #define ld6s_x_hot 0 #define ld6s_y_hot 0 static unsigned char ld6s_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x99, 0xf9, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xbm/scrl_up.xbm����������������������������������������������������������������������0000644�0000764�0000764�00000000465�10064674125�015752� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xbm/scrl_up.xbm,v 1.1 2004/06/18 23:18:45 william Exp $ */ #define scrl_up_width 9 #define scrl_up_height 9 static unsigned char scrl_up_bits[] = { 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x38, 0x00, 0x7c, 0x00, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00}; �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Makefile.distr�����������������������������������������������������������������������0000644�0000764�0000764�00000063444�11602233424�015567� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# Makefile.in generated by automake 1.10 from Makefile.am. # Makefile. Generated from Makefile.in by configure. # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005, 2006 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. pkgdatadir = $(datadir)/tgif pkglibdir = $(libdir)/tgif pkgincludedir = $(includedir)/tgif am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : bin_PROGRAMS = tgif$(EXEEXT) subdir = . DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in $(srcdir)/config.h.in \ $(top_srcdir)/configure AUTHORS ChangeLog NEWS depcomp \ install-sh missing mkinstalldirs ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(tgifdir)" binPROGRAMS_INSTALL = $(INSTALL_PROGRAM) PROGRAMS = $(bin_PROGRAMS) am_tgif_OBJECTS = align.$(OBJEXT) animate.$(OBJEXT) arc.$(OBJEXT) \ attr.$(OBJEXT) auxtext.$(OBJEXT) box.$(OBJEXT) \ button.$(OBJEXT) chat.$(OBJEXT) chinput.$(OBJEXT) \ choice.$(OBJEXT) choose.$(OBJEXT) cli_xcin.$(OBJEXT) \ convkinput.$(OBJEXT) convxim.$(OBJEXT) cmd.$(OBJEXT) \ color.$(OBJEXT) cutpaste.$(OBJEXT) cursor.$(OBJEXT) \ dialog.$(OBJEXT) drawing.$(OBJEXT) dup.$(OBJEXT) \ edit.$(OBJEXT) eps.$(OBJEXT) exec.$(OBJEXT) expr.$(OBJEXT) \ file.$(OBJEXT) font.$(OBJEXT) ftp.$(OBJEXT) grid.$(OBJEXT) \ group.$(OBJEXT) hash.$(OBJEXT) help.$(OBJEXT) http.$(OBJEXT) \ imgproc.$(OBJEXT) import.$(OBJEXT) ini.$(OBJEXT) \ inmethod.$(OBJEXT) list.$(OBJEXT) mainloop.$(OBJEXT) \ mainmenu.$(OBJEXT) mark.$(OBJEXT) markup.$(OBJEXT) \ menu.$(OBJEXT) menuinfo.$(OBJEXT) miniline.$(OBJEXT) \ move.$(OBJEXT) msg.$(OBJEXT) names.$(OBJEXT) \ navigate.$(OBJEXT) nkf.$(OBJEXT) obj.$(OBJEXT) oval.$(OBJEXT) \ page.$(OBJEXT) pattern.$(OBJEXT) pin.$(OBJEXT) \ pngtrans.$(OBJEXT) poly.$(OBJEXT) polygon.$(OBJEXT) \ ps.$(OBJEXT) raster.$(OBJEXT) rcbox.$(OBJEXT) rect.$(OBJEXT) \ remote.$(OBJEXT) rm_intrf.$(OBJEXT) ruler.$(OBJEXT) \ scroll.$(OBJEXT) select.$(OBJEXT) setup.$(OBJEXT) \ shape.$(OBJEXT) shortcut.$(OBJEXT) special.$(OBJEXT) \ spline.$(OBJEXT) stk.$(OBJEXT) stream.$(OBJEXT) \ stretch.$(OBJEXT) strtbl.$(OBJEXT) tangram2.$(OBJEXT) \ tdgtbase.$(OBJEXT) tdgtbmpl.$(OBJEXT) tdgtbrow.$(OBJEXT) \ tdgtbtn.$(OBJEXT) tdgtdraw.$(OBJEXT) tdgtlist.$(OBJEXT) \ tdgtmsg.$(OBJEXT) tdgtsedt.$(OBJEXT) tgif_dbg.$(OBJEXT) \ tgcwheel.$(OBJEXT) tgcwdl.$(OBJEXT) tginssym.$(OBJEXT) \ tgisdl.$(OBJEXT) tgtwb5.$(OBJEXT) tgif.$(OBJEXT) \ tgtwb5dl.$(OBJEXT) tgtwb5xl.$(OBJEXT) tidget.$(OBJEXT) \ tcp.$(OBJEXT) text.$(OBJEXT) util.$(OBJEXT) version.$(OBJEXT) \ vms_comp.$(OBJEXT) wb.$(OBJEXT) wb1.$(OBJEXT) wb2.$(OBJEXT) \ wb3.$(OBJEXT) wb_buff.$(OBJEXT) wb_mcast.$(OBJEXT) \ wb_seg.$(OBJEXT) xbitmap.$(OBJEXT) xpixmap.$(OBJEXT) \ xprtfltr.$(OBJEXT) z_intrf.$(OBJEXT) tgif_OBJECTS = $(am_tgif_OBJECTS) tgif_DEPENDENCIES = DEFAULT_INCLUDES = -I. depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ SOURCES = $(tgif_SOURCES) DIST_SOURCES = $(tgif_SOURCES) am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = `echo $$p | sed -e 's|^.*/||'`; tgifDATA_INSTALL = $(INSTALL_DATA) DATA = $(tgif_DATA) ETAGS = etags CTAGS = ctags DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ { test ! -d $(distdir) \ || { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \ && rm -fr $(distdir); }; } DIST_ARCHIVES = $(distdir).tar.gz GZIP_ENV = --best distuninstallcheck_listfiles = find . -type f -print distcleancheck_listfiles = find . -type f -print ACLOCAL = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run aclocal-1.10 AMTAR = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run tar AUTOCONF = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run autoconf AUTOHEADER = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run autoheader AUTOMAKE = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run automake-1.10 AWK = gawk CC = gcc CCDEPMODE = depmode=gcc3 CFLAGS = -DVERSION=\"$(VERSION)\" -DPROG="\"$(PACKAGE)\"" \ -Wall -I/usr/X11R6/include -DHAVE_CONFIG_H -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 -DLOCALEDIR=\"/usr/share/locale\" -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" -DEPSF_FILE_EXT=\"eps\" -DPS_FILE_EXT=\"ps\" -DXBM_FILE_EXT=\"xbm\" -DXPM_FILE_EXT=\"xpm\" -DOBJ_FILE_EXT=\"obj\" -DSYM_FILE_EXT=\"sym\" -DTEXT_FILE_EXT=\"txt\" -DPIN_FILE_EXT=\"pin\" -DNETLIST_FILE_EXT=\"net\" -DCOMP_FILE_EXT=\"cmp\" -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" -DDEFATTRGROUP=\"TANGRAM-II:Declaration:Events:Messages:Rewards:Initialization:Watches\" -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN -DUSE_XT_INITIALIZE -D_NO_LOCALE_SUPPORT CPP = gcc -E CPPFLAGS = CYGPATH_W = echo DEFS = -DHAVE_CONFIG_H DEPDIR = .deps ECHO_C = ECHO_N = -n ECHO_T = EGREP = /bin/grep -E EXEEXT = GREP = /bin/grep INSTALL = /usr/bin/install -c INSTALL_DATA = ${INSTALL} -m 644 INSTALL_PROGRAM = ${INSTALL} INSTALL_SCRIPT = ${INSTALL} INSTALL_STRIP_PROGRAM = $(install_sh) -c -s LDFLAGS = LIBOBJS = LIBS = -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 LTLIBOBJS = MAKEINFO = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run makeinfo MKDIR_P = /bin/mkdir -p OBJEXT = o PACKAGE = tgif PACKAGE_BUGREPORT = bill.cheng@acm.org PACKAGE_NAME = tgif PACKAGE_STRING = tgif 4.2.5 PACKAGE_TARNAME = tgif PACKAGE_VERSION = 4.2.5 PATH_SEPARATOR = : POW_LIB = SET_MAKE = SHELL = /bin/sh STRIP = VERSION = 4.2.5 XMKMF = abs_builddir = /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5 abs_srcdir = /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5 abs_top_builddir = /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5 abs_top_srcdir = /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5 ac_ct_CC = gcc am__include = include am__leading_dot = . am__quote = am__tar = ${AMTAR} chof - "$$tardir" am__untar = ${AMTAR} xf - bindir = ${exec_prefix}/bin build_alias = builddir = . datadir = ${datarootdir} datarootdir = ${prefix}/share docdir = ${datarootdir}/doc/${PACKAGE_TARNAME} dvidir = ${docdir} exec_prefix = ${prefix} host_alias = htmldir = ${docdir} includedir = ${prefix}/include infodir = ${datarootdir}/info install_sh = $(SHELL) /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/install-sh libdir = ${exec_prefix}/lib libexecdir = ${exec_prefix}/libexec localedir = ${datarootdir}/locale localstatedir = ${prefix}/var mandir = ${datarootdir}/man mkdir_p = /bin/mkdir -p oldincludedir = /usr/include pdfdir = ${docdir} prefix = /usr/local program_transform_name = s,x,x, psdir = ${docdir} sbindir = ${exec_prefix}/sbin sharedstatedir = ${prefix}/com srcdir = . sysconfdir = ${prefix}/etc target_alias = top_builddir = . top_srcdir = . # # @(#)$Header: /mm2/home/cvs/bc-src/tgif/Makefile.am,v 1.21 2011/01/18 05:17:27 william Exp $ # AUTOMAKE_OPTIONS = foreign TGIFDIR = $(libdir)/X11/tgif tgif_SOURCES = \ align.c animate.c arc.c attr.c auxtext.c \ box.c button.c \ chat.c chinput.c choice.c choose.c cli_xcin.c \ convkinput.c convxim.c cmd.c color.c cutpaste.c \ cursor.c \ dialog.c drawing.c dup.c \ edit.c eps.c exec.c expr.c \ file.c font.c ftp.c \ grid.c group.c \ hash.c help.c http.c \ imgproc.c import.c ini.c inmethod.c \ list.c \ mainloop.c mainmenu.c mark.c markup.c menu.c \ menuinfo.c miniline.c move.c msg.c \ names.c navigate.c nkf.c \ obj.c oval.c \ page.c pattern.c pin.c pngtrans.c poly.c polygon.c ps.c \ raster.c rcbox.c rect.c remote.c rm_intrf.c ruler.c \ scroll.c select.c setup.c shape.c shortcut.c \ special.c spline.c stk.c stream.c stretch.c \ strtbl.c \ tangram2.c tdgtbase.c tdgtbmpl.c tdgtbrow.c tdgtbtn.c tdgtdraw.c \ tdgtlist.c tdgtmsg.c tdgtsedt.c tgif_dbg.c tgcwheel.c \ tgcwdl.c tginssym.c tgisdl.c tgtwb5.c tgif.c tgtwb5dl.c \ tgtwb5xl.c tidget.c tcp.c text.c \ util.c \ version.c vms_comp.c \ wb.c wb1.c wb2.c wb3.c wb_buff.c wb_mcast.c \ wb_seg.c \ xbitmap.c xpixmap.c xprtfltr.c \ z_intrf.c tgif_LDADD = -L/usr/X11R6/lib -lXext -lX11 -lXt -lSM -lICE -lXmu -lm -lz tgifdir = $(TGIFDIR) tgif_DATA = tgif.Xdefaults tgificon.eps tgificon.obj tgificon.xbm tgificon.xpm tgif.gif tangram.sym eq4.sym eq4-2x.sym eq4-ps2epsi.sym eq4-epstool.sym eq4xpm.sym eq4-lyx-ps2epsi.sym eq4xpm-land.sym eq4png.sym eq4jpg.sym eq4-2x-jpg.sym eq4-2x-nowin-jpg.sym keys.obj Copyright License all: config.h $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .o .obj am--refresh: @: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ echo ' cd $(srcdir) && $(AUTOMAKE) --foreign '; \ cd $(srcdir) && $(AUTOMAKE) --foreign \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --foreign Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ echo ' $(SHELL) ./config.status'; \ $(SHELL) ./config.status;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck $(top_srcdir)/configure: $(am__configure_deps) cd $(srcdir) && $(AUTOCONF) $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) config.h: stamp-h1 @if test ! -f $@; then \ rm -f stamp-h1; \ $(MAKE) $(AM_MAKEFLAGS) stamp-h1; \ else :; fi stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status @rm -f stamp-h1 cd $(top_builddir) && $(SHELL) ./config.status config.h $(srcdir)/config.h.in: $(am__configure_deps) cd $(top_srcdir) && $(AUTOHEADER) rm -f stamp-h1 touch $@ distclean-hdr: -rm -f config.h stamp-h1 install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; for p in $$list; do \ p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ if test -f $$p \ ; then \ f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \ echo " $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ else :; fi; \ done uninstall-binPROGRAMS: @$(NORMAL_UNINSTALL) @list='$(bin_PROGRAMS)'; for p in $$list; do \ f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \ echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \ rm -f "$(DESTDIR)$(bindir)/$$f"; \ done clean-binPROGRAMS: -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) tgif$(EXEEXT): $(tgif_OBJECTS) $(tgif_DEPENDENCIES) @rm -f tgif$(EXEEXT) $(LINK) $(tgif_OBJECTS) $(tgif_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c include ./$(DEPDIR)/align.Po include ./$(DEPDIR)/animate.Po include ./$(DEPDIR)/arc.Po include ./$(DEPDIR)/attr.Po include ./$(DEPDIR)/auxtext.Po include ./$(DEPDIR)/box.Po include ./$(DEPDIR)/button.Po include ./$(DEPDIR)/chat.Po include ./$(DEPDIR)/chinput.Po include ./$(DEPDIR)/choice.Po include ./$(DEPDIR)/choose.Po include ./$(DEPDIR)/cli_xcin.Po include ./$(DEPDIR)/cmd.Po include ./$(DEPDIR)/color.Po include ./$(DEPDIR)/convkinput.Po include ./$(DEPDIR)/convxim.Po include ./$(DEPDIR)/cursor.Po include ./$(DEPDIR)/cutpaste.Po include ./$(DEPDIR)/dialog.Po include ./$(DEPDIR)/drawing.Po include ./$(DEPDIR)/dup.Po include ./$(DEPDIR)/edit.Po include ./$(DEPDIR)/eps.Po include ./$(DEPDIR)/exec.Po include ./$(DEPDIR)/expr.Po include ./$(DEPDIR)/file.Po include ./$(DEPDIR)/font.Po include ./$(DEPDIR)/ftp.Po include ./$(DEPDIR)/grid.Po include ./$(DEPDIR)/group.Po include ./$(DEPDIR)/hash.Po include ./$(DEPDIR)/help.Po include ./$(DEPDIR)/http.Po include ./$(DEPDIR)/imgproc.Po include ./$(DEPDIR)/import.Po include ./$(DEPDIR)/ini.Po include ./$(DEPDIR)/inmethod.Po include ./$(DEPDIR)/list.Po include ./$(DEPDIR)/mainloop.Po include ./$(DEPDIR)/mainmenu.Po include ./$(DEPDIR)/mark.Po include ./$(DEPDIR)/markup.Po include ./$(DEPDIR)/menu.Po include ./$(DEPDIR)/menuinfo.Po include ./$(DEPDIR)/miniline.Po include ./$(DEPDIR)/move.Po include ./$(DEPDIR)/msg.Po include ./$(DEPDIR)/names.Po include ./$(DEPDIR)/navigate.Po include ./$(DEPDIR)/nkf.Po include ./$(DEPDIR)/obj.Po include ./$(DEPDIR)/oval.Po include ./$(DEPDIR)/page.Po include ./$(DEPDIR)/pattern.Po include ./$(DEPDIR)/pin.Po include ./$(DEPDIR)/pngtrans.Po include ./$(DEPDIR)/poly.Po include ./$(DEPDIR)/polygon.Po include ./$(DEPDIR)/ps.Po include ./$(DEPDIR)/raster.Po include ./$(DEPDIR)/rcbox.Po include ./$(DEPDIR)/rect.Po include ./$(DEPDIR)/remote.Po include ./$(DEPDIR)/rm_intrf.Po include ./$(DEPDIR)/ruler.Po include ./$(DEPDIR)/scroll.Po include ./$(DEPDIR)/select.Po include ./$(DEPDIR)/setup.Po include ./$(DEPDIR)/shape.Po include ./$(DEPDIR)/shortcut.Po include ./$(DEPDIR)/special.Po include ./$(DEPDIR)/spline.Po include ./$(DEPDIR)/stk.Po include ./$(DEPDIR)/stream.Po include ./$(DEPDIR)/stretch.Po include ./$(DEPDIR)/strtbl.Po include ./$(DEPDIR)/tangram2.Po include ./$(DEPDIR)/tcp.Po include ./$(DEPDIR)/tdgtbase.Po include ./$(DEPDIR)/tdgtbmpl.Po include ./$(DEPDIR)/tdgtbrow.Po include ./$(DEPDIR)/tdgtbtn.Po include ./$(DEPDIR)/tdgtdraw.Po include ./$(DEPDIR)/tdgtlist.Po include ./$(DEPDIR)/tdgtmsg.Po include ./$(DEPDIR)/tdgtsedt.Po include ./$(DEPDIR)/text.Po include ./$(DEPDIR)/tgcwdl.Po include ./$(DEPDIR)/tgcwheel.Po include ./$(DEPDIR)/tgif.Po include ./$(DEPDIR)/tgif_dbg.Po include ./$(DEPDIR)/tginssym.Po include ./$(DEPDIR)/tgisdl.Po include ./$(DEPDIR)/tgtwb5.Po include ./$(DEPDIR)/tgtwb5dl.Po include ./$(DEPDIR)/tgtwb5xl.Po include ./$(DEPDIR)/tidget.Po include ./$(DEPDIR)/util.Po include ./$(DEPDIR)/version.Po include ./$(DEPDIR)/vms_comp.Po include ./$(DEPDIR)/wb.Po include ./$(DEPDIR)/wb1.Po include ./$(DEPDIR)/wb2.Po include ./$(DEPDIR)/wb3.Po include ./$(DEPDIR)/wb_buff.Po include ./$(DEPDIR)/wb_mcast.Po include ./$(DEPDIR)/wb_seg.Po include ./$(DEPDIR)/xbitmap.Po include ./$(DEPDIR)/xpixmap.Po include ./$(DEPDIR)/xprtfltr.Po include ./$(DEPDIR)/z_intrf.Po .c.o: $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po # source='$<' object='$@' libtool=no \ # DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) \ # $(COMPILE) -c $< .c.obj: $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po # source='$<' object='$@' libtool=no \ # DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) \ # $(COMPILE) -c `$(CYGPATH_W) '$<'` install-tgifDATA: $(tgif_DATA) @$(NORMAL_INSTALL) test -z "$(tgifdir)" || $(MKDIR_P) "$(DESTDIR)$(tgifdir)" @list='$(tgif_DATA)'; for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ f=$(am__strip_dir) \ echo " $(tgifDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(tgifdir)/$$f'"; \ $(tgifDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(tgifdir)/$$f"; \ done uninstall-tgifDATA: @$(NORMAL_UNINSTALL) @list='$(tgif_DATA)'; for p in $$list; do \ f=$(am__strip_dir) \ echo " rm -f '$(DESTDIR)$(tgifdir)/$$f'"; \ rm -f "$(DESTDIR)$(tgifdir)/$$f"; \ done ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS TAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique; \ fi ctags: CTAGS CTAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) $(am__remove_distdir) test -d $(distdir) || mkdir $(distdir) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done -find $(distdir) -type d ! -perm -777 -exec chmod a+rwx {} \; -o \ ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r $(distdir) dist-gzip: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 $(am__remove_distdir) dist-tarZ: distdir tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z $(am__remove_distdir) dist-shar: distdir shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz $(am__remove_distdir) dist-zip: distdir -rm -f $(distdir).zip zip -rq $(distdir).zip $(distdir) $(am__remove_distdir) dist dist-all: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) # This target untars the dist file and tries a VPATH configuration. Then # it guarantees that the distribution is self-contained by making another # tarfile. distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac chmod -R a-w $(distdir); chmod a+w $(distdir) mkdir $(distdir)/_build mkdir $(distdir)/_inst chmod a-w $(distdir) dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ && cd $(distdir)/_build \ && ../configure --srcdir=.. --prefix="$$dc_install_base" \ $(DISTCHECK_CONFIGURE_FLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(MAKE) $(AM_MAKEFLAGS) check \ && $(MAKE) $(AM_MAKEFLAGS) install \ && $(MAKE) $(AM_MAKEFLAGS) installcheck \ && $(MAKE) $(AM_MAKEFLAGS) uninstall \ && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ distuninstallcheck \ && chmod -R a-w "$$dc_install_base" \ && ({ \ (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ } || { rm -rf "$$dc_destdir"; exit 1; }) \ && rm -rf "$$dc_destdir" \ && $(MAKE) $(AM_MAKEFLAGS) dist \ && rm -rf $(DIST_ARCHIVES) \ && $(MAKE) $(AM_MAKEFLAGS) distcleancheck $(am__remove_distdir) @(echo "$(distdir) archives ready for distribution: "; \ list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' distuninstallcheck: @cd $(distuninstallcheck_dir) \ && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ || { echo "ERROR: files left after uninstall:" ; \ if test -n "$(DESTDIR)"; then \ echo " (check DESTDIR support)"; \ fi ; \ $(distuninstallcheck_listfiles) ; \ exit 1; } >&2 distcleancheck: distclean @if test '$(srcdir)' = . ; then \ echo "ERROR: distcleancheck can only run from a VPATH build" ; \ exit 1 ; \ fi @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left in build directory after distclean:" ; \ $(distcleancheck_listfiles) ; \ exit 1; } >&2 check-am: all-am check: check-am all-am: Makefile $(PROGRAMS) $(DATA) config.h installdirs: for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(tgifdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-binPROGRAMS clean-generic mostlyclean-am distclean: distclean-am -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-hdr distclean-tags dvi: dvi-am dvi-am: html: html-am info: info-am info-am: install-data-am: install-tgifDATA install-dvi: install-dvi-am install-exec-am: install-binPROGRAMS install-html: install-html-am install-info: install-info-am install-man: install-pdf: install-pdf-am install-ps: install-ps-am installcheck-am: maintainer-clean: maintainer-clean-am -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-binPROGRAMS uninstall-tgifDATA .MAKE: install-am install-strip .PHONY: CTAGS GTAGS all all-am am--refresh check check-am clean \ clean-binPROGRAMS clean-generic ctags dist dist-all dist-bzip2 \ dist-gzip dist-shar dist-tarZ dist-zip distcheck distclean \ distclean-compile distclean-generic distclean-hdr \ distclean-tags distcleancheck distdir distuninstallcheck dvi \ dvi-am html html-am info info-am install install-am \ install-binPROGRAMS install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-ps install-ps-am \ install-strip install-tgifDATA installcheck installcheck-am \ installdirs maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-compile mostlyclean-generic pdf pdf-am \ ps ps-am tags uninstall uninstall-am uninstall-binPROGRAMS \ uninstall-tgifDATA # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/edit.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000656661�11602233311�014100� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/edit.c,v 1.108 2011/06/18 04:44:51 william Exp $ */ #define _INCLUDE_FROM_EDIT_C_ #include "tgifdefs.h" #include "cmdids.h" #include "align.e" #include "arc.e" #include "attr.e" #include "auxtext.e" #include "button.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cutpaste.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "edit.e" #include "eps.e" #include "exec.e" #include "file.e" #include "font.e" #include "grid.e" #include "group.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "menuinfo.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "pin.e" #include "poly.e" #include "polygon.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "shape.e" #include "special.e" #include "spline.e" #include "stretch.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "xbitmap.e" #include "xpixmap.e" struct SelRec *outerSelForFind=NULL; struct SelRec *innerSelForFind=NULL; int ignoreObjectShadowInfoInFile=TRUE; int objShadowXOffset=2, objShadowYOffset=2; char objShadowColorStr[MAXSTRING]; int pngExportHasTransparentColor=FALSE; static struct ObjRec *tmpTopObj=NULL, *tmpBotObj=NULL; static struct SelRec *tmpTopSel=NULL, *tmpBotSel=NULL; static char *gpszSearch=NULL; static int gnSearchLen=0; static int gnSearchCaseSensitive=TRUE; static int gnFoundStartCharIndex=0, gnFoundEndCharIndex=0; static StrBlockInfo *gpFoundStartStrBlock=NULL, *gpFoundEndStrBlock=NULL; static int convertToBezierNumSegs=50; void CleanOuterInnerSelForFind() { struct SelRec *sel_ptr=NULL, *next_sel=NULL; if (outerSelForFind != NULL) { for (sel_ptr=outerSelForFind; sel_ptr != NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } outerSelForFind = innerSelForFind = NULL; } } static void CopyOuterSelToOuterSelForFind() { struct SelRec *sel_ptr=NULL; CleanOuterInnerSelForFind(); for (sel_ptr=outerSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { AddObjIntoSel(sel_ptr->obj, NULL, outerSelForFind, &outerSelForFind, &innerSelForFind); } } void CleanUpEdit() { CleanOuterInnerSelForFind(); if (gpszSearch != NULL) free(gpszSearch); gpszSearch = NULL; } void InitEdit() { char *c_ptr=NULL, spec[MAXSTRING]; if (PRTGIF && !cmdLineOpenDisplay) return; convertToBezierNumSegs = 50; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "ConvertToBezierSegments")) != NULL) { SetBezierConvertNumSegsValue(c_ptr); } objShadowXOffset = objShadowYOffset = 2; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "ObjectShadowOffsets")) != NULL) { UtilStrCpyN(spec, sizeof(spec), c_ptr); UtilTrimBlanks(spec); if (!ParseXYSpec(spec, &objShadowXOffset, &objShadowYOffset)) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "ObjectShadowOffsets", spec, "2,2"); fprintf(stderr, "\n"); } } strcpy(objShadowColorStr, "#c0c0c0"); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ObjectShadowColor")) != NULL) { int new_alloc=0; UtilStrCpyN(spec, sizeof(spec), c_ptr); UtilTrimBlanks(spec); if (QuickFindColorIndex(NULL, spec, &new_alloc, FALSE) == INVALID) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_COLORXPM_GET), TOOL_NAME, "ObjectShadowColor", spec); fprintf(stderr, "\n"); return; } UtilStrCpyN(objShadowColorStr, sizeof(objShadowColorStr), spec); } ignoreObjectShadowInfoInFile = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "IgnoreObjectShadowInfoInFile")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { ignoreObjectShadowInfoInFile = FALSE; } pngExportHasTransparentColor = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "PNGExportHasTransparentColor")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { pngExportHasTransparentColor = TRUE; } tighterStructSplines = TRUE; } int CanPerformImageProc() { struct SelRec *sel_ptr=NULL; if (topSel == NULL) return FALSE; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (sel_ptr->obj->type != OBJ_XPM) return FALSE; } return TRUE; /* * if (topSel != NULL && topSel == botSel && topSel->obj->type == OBJ_XPM) { * return !IsLinkedJpegObj(topSel->obj); * } * return FALSE; */ } /* --------------------- ConvertIntSpline() --------------------- */ static int ConvertObjIntSpline(ObjPtr) struct ObjRec *ObjPtr; { register struct ObjRec *obj_ptr; register int i, changed=FALSE; switch (ObjPtr->type) { case OBJ_POLY: if (ObjPtr->detail.p->curved == LT_INTSPLINE) { struct PolyRec *poly_ptr=ObjPtr->detail.p; int new_n, n, index=0; char *smooth=poly_ptr->smooth; IntPoint *vs; changed = TRUE; if (smooth != NULL) free(smooth); n = poly_ptr->n; new_n = (n == 2 ? n : ((n-2)<<1)+n); vs = (IntPoint*)malloc((new_n+1)*sizeof(IntPoint)); if (vs == NULL) FailAllocMessage(); smooth = (char*)malloc((new_n+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); smooth[0] = smooth[new_n-1] = FALSE; vs[0] = poly_ptr->vlist[0]; vs[new_n-1] = poly_ptr->vlist[n-1]; for (i=1; i < n-1; i++) { index++; smooth[index] = TRUE; vs[index] = poly_ptr->intvlist[(i<<1)-1]; index++; smooth[index] = FALSE; vs[index] = poly_ptr->vlist[i]; index++; smooth[index] = TRUE; vs[index] = poly_ptr->intvlist[i<<1]; } poly_ptr->curved = LT_SPLINE; free(poly_ptr->vlist); free(poly_ptr->intvlist); poly_ptr->vlist = vs; poly_ptr->n = new_n; poly_ptr->smooth = smooth; poly_ptr->intvlist = NULL; poly_ptr->intn = 0; AdjObjSplineVs(ObjPtr); UpdPolyBBox(ObjPtr, poly_ptr->n, poly_ptr->vlist); } break; case OBJ_POLYGON: if (ObjPtr->detail.g->curved == LT_INTSPLINE) { struct PolygonRec *polygon_ptr=ObjPtr->detail.g; int new_n, n, index=0; char *smooth=polygon_ptr->smooth; IntPoint *vs; changed = TRUE; if (smooth != NULL) free(smooth); n = polygon_ptr->n; new_n = ((n-1)<<1)+n; vs = (IntPoint*)malloc((new_n+1)*sizeof(IntPoint)); if (vs == NULL) FailAllocMessage(); smooth = (char*)malloc((new_n+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); smooth[0] = FALSE; vs[0] = polygon_ptr->vlist[0]; for (i=0; i < n-1; i++) { index++; smooth[index] = TRUE; vs[index] = polygon_ptr->intvlist[i<<1]; index++; smooth[index] = TRUE; vs[index] = polygon_ptr->intvlist[(i<<1)+1]; index++; smooth[index] = FALSE; vs[index] = polygon_ptr->vlist[i+1]; } polygon_ptr->curved = LT_SPLINE; free(polygon_ptr->vlist); free(polygon_ptr->intvlist); polygon_ptr->vlist = vs; polygon_ptr->n = new_n; polygon_ptr->smooth = smooth; polygon_ptr->intvlist = NULL; polygon_ptr->intn = 0; AdjObjSplineVs(ObjPtr); UpdPolyBBox(ObjPtr, polygon_ptr->n, polygon_ptr->vlist); } break; case OBJ_GROUP: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { if (ConvertObjIntSpline(obj_ptr)) { changed = TRUE; } } break; } if (changed) AdjObjBBox(ObjPtr); return changed; } void ConvertIntSpline() { struct SelRec *sel_ptr=NULL; int changed=FALSE; if (topSel == NULL) { MsgBox(TgLoadString(STID_NO_INTSPLINE_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ConvertObjIntSpline(sel_ptr->obj)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); UpdSelBBox(); justDupped = FALSE; Msg(TgLoadString(STID_INTSPLINE_CONVERTED_TO_SPLINE)); } else { HighLightForward(); MsgBox(TgLoadString(STID_NO_INTSPLINE_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightForward(); } /* --------------------- ConvertToBezier() --------------------- */ static void SetBezierPoints(n, vs, new_n, bezier_vs) int n, new_n; IntPoint *vs, *bezier_vs; { int i=0, *n_choose_i=(int*)malloc((n+1)*sizeof(int)), index=0; double t=(double)0, dt=(((double)1.0)/((double)(new_n-1))); double final_t=((double)1)+(dt/((double)2)); if (n_choose_i == NULL) FailAllocMessage(); memset(n_choose_i, 0, (n+1)*sizeof(int)); n--; n_choose_i[0] = 1; for (i=1; i <= n; i++) { n_choose_i[i] = n_choose_i[i-1] * (n-i+1) / i; } for (t=(double)0; t <= final_t; t+=dt, index++) { double s=((double)1)-t, xt=(double)0, yt=(double)0; for (i=0; i <= n; i++) { /* Bi = B_{i,n}(t) */ double Bi=((double)(n_choose_i[i])); int j=0; for (j=1; j <= (n-i); j++) Bi *= s; for (j=1; j <= i; j++) Bi *= t; xt += Bi * ((double)(vs[i].x)); yt += Bi * ((double)(vs[i].y)); } bezier_vs[index].x = round(xt); bezier_vs[index].y = round(yt); } free(n_choose_i); } static int ConvertObjToBezier(ObjPtr) struct ObjRec *ObjPtr; { struct ObjRec *obj_ptr=NULL; int i=0, changed=FALSE; switch (ObjPtr->type) { case OBJ_POLY: if (ObjPtr->detail.p->curved == LT_STRAIGHT || ObjPtr->detail.p->curved == LT_SPLINE) { struct PolyRec *poly_ptr=ObjPtr->detail.p; int n=poly_ptr->n; char *smooth=poly_ptr->smooth; if (n == 3) { if (!smooth[1]) { smooth[1] = TRUE; changed = TRUE; poly_ptr->curved = LT_SPLINE; AdjObjSplineVs(ObjPtr); UpdPolyBBox(ObjPtr, poly_ptr->n, poly_ptr->vlist); } } else if (n > 3) { int new_n=convertToBezierNumSegs+1; IntPoint *vs=NULL; changed = TRUE; if (smooth != NULL) free(smooth); vs = (IntPoint*)malloc((new_n+1)*sizeof(IntPoint)); if (vs == NULL) FailAllocMessage(); memset(vs, 0, (new_n+1)*sizeof(IntPoint)); smooth = (char*)malloc((new_n+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); memset(smooth, 0, (new_n+1)*sizeof(char)); SetBezierPoints(n, poly_ptr->vlist, new_n, vs); smooth[0] = smooth[new_n-1] = FALSE; for (i=1; i < new_n-1; i++) smooth[i] = TRUE; poly_ptr->curved = LT_SPLINE; free(poly_ptr->vlist); poly_ptr->vlist = vs; poly_ptr->n = new_n; poly_ptr->smooth = smooth; AdjObjSplineVs(ObjPtr); UpdPolyBBox(ObjPtr, poly_ptr->n, poly_ptr->vlist); } } break; case OBJ_GROUP: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { if (ConvertObjToBezier(obj_ptr)) { changed = TRUE; } } break; } if (changed) AdjObjBBox(ObjPtr); return changed; } void ConvertToBezier() { struct SelRec *sel_ptr=NULL; int changed=FALSE; if (topSel == NULL) { MsgBox(TgLoadString(STID_NO_SPLINE_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ConvertObjToBezier(sel_ptr->obj)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); UpdSelBBox(); justDupped = FALSE; Msg(TgLoadString(STID_SPLINE_CONVERTED_TO_BEZIER)); } else { HighLightForward(); MsgBox(TgLoadString(STID_NO_SPLINE_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightForward(); } int SetBezierConvertNumSegsValue(spec) char *spec; { int ival=0; if (sscanf(spec, "%d", &ival) != 1) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_MALFORMED_INPUT_STR), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (ival < 2) { sprintf(gszMsgBox, TgLoadString(STID_ENT_VAL_RANGE_ENTER_GE_INT), spec, 3); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } convertToBezierNumSegs = ival; return TRUE; } void SetBezierConvertNumSegs(psz_num_segs) char *psz_num_segs; { char spec[MAXSTRING+1]; *spec = '\0'; if (psz_num_segs != NULL && strcmp(psz_num_segs, "-1") != 0) { UtilStrCpyN(spec, sizeof(spec), psz_num_segs); } else { sprintf(gszMsgBox, TgLoadString(STID_ENTER_BEZIER_NUM_SEGS_CUR_IS), convertToBezierNumSegs); if (Dialog(gszMsgBox, NULL, spec) == INVALID) return; } UtilTrimBlanks(spec); if (*spec == '\0') return; if (SetBezierConvertNumSegsValue(spec)) { sprintf(gszMsgBox, TgLoadString(STID_BEZIER_NUM_SEGS_SET_TO_INT), convertToBezierNumSegs); Msg(gszMsgBox); } } static void SelectModeToggleSmoothHinge() { register struct ObjRec *obj_ptr; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; int index, n, pt_toggled=FALSE, toggling=TRUE; int root_x, root_y, old_x, old_y, curved=(-1); unsigned int status; Window root_win, child_win; XEvent input, ev; char *smooth=NULL; if (!(topSel != NULL && topSel == botSel && (topSel->obj->type == OBJ_POLY || topSel->obj->type == OBJ_POLYGON))) { MsgBox(TgLoadString(STID_SELECT_ONLY_ONE_POLY_POLYGON), TOOL_NAME, INFO_MB); return; } obj_ptr = topSel->obj; switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; smooth = poly_ptr->smooth; curved = poly_ptr->curved; break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; smooth = polygon_ptr->smooth; curved = polygon_ptr->curved; break; } if (curved == LT_INTSPLINE) { MsgBox(TgLoadString(STID_CANNOT_TOGGLE_FOR_INTSPLINE), TOOL_NAME, INFO_MB); return; } else if (curved == LT_STRUCT_SPLINE) { MsgBox(TgLoadString(STID_CANNOT_TOGGLE_FOR_STRUCT_SPLN), TOOL_NAME, INFO_MB); return; } if (smooth == NULL) { FatalUnexpectedError(TgLoadString(STID_BAD_POLY_IN_TOGGLE_SMOOTH), NULL); return; } PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); SaveStatusStrings(); SetMouseStatus(TgLoadCachedString(CSTID_TOGGLE_SMOOTH_HINGE), TgLoadCachedString(CSTID_FINISH), TgLoadCachedString(CSTID_FINISH)); TwoLineMsg(TgLoadString(STID_CLICK_LEFT_BUTTON_TO_TOGGLE), TgLoadString(STID_CLICK_OTHER_BUTTON_TO_QUIT)); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonPressMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, defaultCursor, CurrentTime); } XQueryPointer(mainDisplay, drawWindow, &root_win, &child_win, &root_x, &root_y, &old_x, &old_y, &status); XSetFont(mainDisplay, revDefaultGC, defaultFontPtr->fid); /* do not translate -- program constants */ XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "S/H", 3); MarkRulers(old_x, old_y); while (toggling) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonPress) { if (input.xbutton.button == Button1) { if ((obj_ptr->type == OBJ_POLY && PtInPolyMark(obj_ptr, input.xbutton.x, input.xbutton.y, poly_ptr->n, poly_ptr->vlist, &index) && index != 0 && index != poly_ptr->n-1) || (obj_ptr->type == OBJ_POLYGON && PtInPolyMark(obj_ptr, input.xbutton.x, input.xbutton.y, polygon_ptr->n-1, polygon_ptr->vlist, &index))) { int sel_ltx=selLtX, sel_lty=selLtY; int sel_rbx=selRbX, sel_rby=selRbY; pt_toggled = TRUE; HighLightReverse(); switch (obj_ptr->type) { case OBJ_POLY: n = poly_ptr->n; if (smooth[index]) { smooth[index] = FALSE; } else { smooth[index] = TRUE; } AdjObjSplineVs(obj_ptr); UpdPolyBBox(obj_ptr, poly_ptr->n, poly_ptr->vlist); break; case OBJ_POLYGON: n = polygon_ptr->n; if (smooth[index]) { smooth[index] = FALSE; } else { smooth[index] = TRUE; } if (index == 0) smooth[n-1] = smooth[0]; AdjObjSplineVs(obj_ptr); UpdPolyBBox(obj_ptr, polygon_ptr->n, polygon_ptr->vlist); break; } AdjObjBBox(obj_ptr); XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "S/H", 3); old_x = input.xbutton.x; old_y = input.xbutton.y; UpdSelBBox(); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); if (obj_ptr != NULL) { XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "S/H", 3); } SetFileModified(TRUE); justDupped = FALSE; } } else { XUngrabPointer(mainDisplay, CurrentTime); Msg(""); toggling = FALSE; XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "S/H", 3); } } else if (input.type == MotionNotify) { XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "S/H", 3); old_x = input.xmotion.x; old_y = input.xmotion.y; XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "S/H", 3); MarkRulers(old_x, old_y); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } RestoreStatusStrings(); if (pt_toggled) { RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); } else { AbortPrepareCmd(CMD_REPLACE); } } void ToggleSmoothHinge() { register int i; int changed=FALSE, ltx=selLtX, lty=selLtY, rbx=selRbX, rby=selRbY; struct VSelRec *vsel_ptr; struct ObjRec *obj_ptr; if (curChoice == NOTHING) { SelectModeToggleSmoothHinge(); return; } if (curChoice != VERTEXMODE) { MsgBox(TgLoadString(STID_ONLY_TOGGLE_SMOOTH_IN_MODES), TOOL_NAME, INFO_MB); return; } if (topVSel == NULL) { if (topSel == NULL) return; HighLightReverse(); JustRemoveAllVSel(); HighLightForward(); SelectModeToggleSmoothHinge(); return; } for (vsel_ptr=topVSel; vsel_ptr != NULL; vsel_ptr=vsel_ptr->next) { if ((vsel_ptr->obj->type == OBJ_POLY && vsel_ptr->obj->detail.p->curved == LT_INTSPLINE) || (vsel_ptr->obj->type == OBJ_POLYGON && vsel_ptr->obj->detail.g->curved == LT_INTSPLINE)) { MsgBox(TgLoadString(STID_CANNOT_TOGGLE_FOR_INTSPLINE), TOOL_NAME, INFO_MB); return; } else if ((vsel_ptr->obj->type == OBJ_POLY && vsel_ptr->obj->detail.p->curved == LT_STRUCT_SPLINE) || (vsel_ptr->obj->type == OBJ_POLYGON && vsel_ptr->obj->detail.g->curved == LT_STRUCT_SPLINE)) { MsgBox(TgLoadString(STID_CANNOT_TOGGLE_FOR_STRUCT_SPLN), TOOL_NAME, INFO_MB); return; } } HighLightReverse(); StartCompositeCmd(); for (vsel_ptr=botVSel; vsel_ptr != NULL; vsel_ptr=vsel_ptr->prev) { int obj_changed=FALSE, n; IntPoint *v; char *smooth=NULL; obj_ptr = vsel_ptr->obj; switch (obj_ptr->type) { case OBJ_POLY: v = obj_ptr->detail.p->vlist; n = obj_ptr->detail.p->n; smooth = obj_ptr->detail.p->smooth; for (i=0; i < vsel_ptr->n; i++) { if (vsel_ptr->v_index[i] != 0 || vsel_ptr->v_index[i] != n-1) { break; } } if (i == vsel_ptr->n) continue; break; case OBJ_POLYGON: v = obj_ptr->detail.g->vlist; n = obj_ptr->detail.g->n; smooth = obj_ptr->detail.g->smooth; break; default: continue; } PrepareToReplaceAnObj(obj_ptr); for (i=0; i < vsel_ptr->n; i++) { int index=vsel_ptr->v_index[i]; if (!(obj_ptr->type == OBJ_POLY && (index == 0 || index == n-1))) { smooth[index] = (smooth[index] ? FALSE : TRUE); obj_changed = TRUE; } } AdjObjSplineVs(obj_ptr); UpdPolyBBox(obj_ptr, n, v); if (obj_changed) { RecordReplaceAnObj(obj_ptr); changed = TRUE; } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { Msg(TgLoadString(STID_SMOOTHNESS_TOGGLED)); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; } HighLightForward(); } static void BreakATextObj(ObjPtr, how, poli) struct ObjRec *ObjPtr; int how; ObjListInfo *poli; { struct ObjRec *prototype=NULL; struct TextRec *text_ptr=NULL; struct SelRec *sel_ptr=NULL; MiniLinesInfo *minilines=NULL; int tx_to_move=0, ty_to_move=0; char proto_buf[3]; prototype = DupObj(ObjPtr); text_ptr = prototype->detail.t; InvalidateTextCache(text_ptr); minilines = (&text_ptr->minilines); FreeMiniLines(minilines, FALSE); /* do not translate -- program constants */ strcpy(proto_buf, "XX"); CreateMiniLineFromString(proto_buf, &minilines->first, &minilines->last); minilines->first->owner_minilines = minilines; text_ptr->lines = 1; text_ptr = ObjPtr->detail.t; minilines = (&text_ptr->minilines); PushCurFont(); ObjFontInfoToCurFontInfo(text_ptr); SetCanvasFont(); if (ObjPtr->ctm != NULL) { TransformPointThroughCTM(0, 0, prototype->ctm, &tx_to_move, &ty_to_move); } BreakMiniLines(minilines, how, ObjPtr->x, text_ptr->baseline_y, prototype, tx_to_move, ty_to_move, poli); PopCurFont(); FreeTextObj(prototype); for (sel_ptr=poli->top_sel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; UpdTextBBox(obj_ptr); AdjObjSplineVs(obj_ptr); AdjObjBBox(obj_ptr); } } static int GetBreakSpec() /* return TRUE if breaking into words */ { int how=INVALID, can_do_lines=FALSE, can_do_words=FALSE; char spec[MAXSTRING+1]; struct SelRec *sel_ptr=NULL; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; if (obj_ptr->type == OBJ_TEXT && !obj_ptr->locked) { struct TextRec *text_ptr=obj_ptr->detail.t; MiniLinesInfo *minilines=(&text_ptr->minilines); if (text_ptr->read_only) continue; if (CanBreakMiniLinesIntoWords(&text_ptr->minilines)) { can_do_words = TRUE; } if (minilines->first->next != NULL) can_do_lines = TRUE; } if (can_do_lines && can_do_words) break; } if (can_do_lines) { if (can_do_words) { strcpy(gszMsgBox, TgLoadString(STID_BREAK_TEXT_CWL)); } else { strcpy(gszMsgBox, TgLoadString(STID_BREAK_TEXT_CL)); } } else if (can_do_words) { strcpy(gszMsgBox, TgLoadString(STID_BREAK_TEXT_CW)); } else { return BREAK_CHAR; } *spec = '\0'; if (Dialog(gszMsgBox, NULL, spec) == INVALID) { return INVALID; } UtilTrimBlanks(spec); if (*spec == '\0') strcpy(spec, "c"); strcpy(gszMsgBox, spec); gszMsgBox[1] = '\0'; UtilStrLower(gszMsgBox); if (can_do_lines) { if (can_do_words) { switch (*gszMsgBox) { case 'c': how = BREAK_CHAR; break; case 'w': how = BREAK_WORD; break; case 'l': how = BREAK_LINE; break; } } else { switch (*gszMsgBox) { case 'c': how = BREAK_CHAR; break; case 'l': how = BREAK_LINE; break; } } } else if (can_do_words) { switch (*gszMsgBox) { case 'c': how = BREAK_CHAR; break; case 'w': how = BREAK_WORD; break; } } if (how == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC_ON_BREAK_TEXT), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return how; } static int GetBreakSpecFromCh(spec) char *spec; { char buf[2]; int how=INVALID; buf[0] = *spec; buf[1] = '\0'; UtilStrLower(buf); switch (*buf) { case 'c': how = BREAK_CHAR; break; case 'w': how = BREAK_WORD; break; case 'l': how = BREAK_LINE; break; } if (how == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC_ON_BREAK_TEXT), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return how; } void DoBreakUpText(spec, forced_justify) char *spec; int forced_justify; { struct ObjRec *obj_ptr=NULL; struct SelRec *sel_ptr=NULL, *next_sel=NULL; int sel_ltx=selLtX, sel_lty=selLtY, sel_rbx=selRbX, sel_rby=selRbY; int how=INVALID, changed=FALSE, read_only_text_exists=FALSE; if (topSel == NULL) { MsgBox(TgLoadString(STID_NO_TEXT_OBJ_TO_BREAK_UP), TOOL_NAME, INFO_MB); return; } if (spec == NULL || *spec == '\0' || strcmp(spec, "-1") == 0) { if ((how=GetBreakSpec()) == INVALID) return; } else { if ((how=GetBreakSpecFromCh(spec)) == INVALID) return; } HighLightReverse(); StartCompositeCmd(); for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; obj_ptr = sel_ptr->obj; if (obj_ptr->type == OBJ_TEXT && !obj_ptr->locked) { ObjListInfo oli; if (obj_ptr->detail.t->read_only) { read_only_text_exists = TRUE; continue; } memset(&oli, 0, sizeof(ObjListInfo)); changed = TRUE; PrepareToReplaceAnObj(obj_ptr); BreakATextObj(obj_ptr, how, &oli); oli.top_sel->obj->prev = obj_ptr->prev; if (obj_ptr->prev == NULL) { curPage->top = topObj = oli.top_sel->obj; } else { obj_ptr->prev->next = oli.top_sel->obj; } oli.bot_sel->obj->next = obj_ptr->next; if (obj_ptr->next == NULL) { curPage->bot = botObj = oli.bot_sel->obj; } else { obj_ptr->next->prev = oli.bot_sel->obj; } RecordCmd(CMD_ONE_TO_MANY, NULL, oli.top_sel, oli.bot_sel, oli.count); oli.top_sel->prev = sel_ptr->prev; if (sel_ptr->prev == NULL) { topSel = oli.top_sel; } else { sel_ptr->prev->next = oli.top_sel; } oli.bot_sel->next = sel_ptr->next; if (sel_ptr->next == NULL) { botSel = oli.bot_sel; } else { sel_ptr->next->prev = oli.bot_sel; } FreeObj(obj_ptr); free(sel_ptr); } } EndCompositeCmd(); if (read_only_text_exists) { MsgBox(TgLoadString(STID_SOME_TEXT_NOT_BROKEN_UP_SIZE), TOOL_NAME, INFO_MB); } if (changed) { UpdSelBBox(); RedrawAreas(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1), sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; Msg(TgLoadString(STID_TEXT_BROKEN_INTO_CHARS)); } else if (!read_only_text_exists) { MsgBox(TgLoadString(STID_NO_TEXT_OBJ_TO_BREAK_UP), TOOL_NAME, INFO_MB); } HighLightForward(); } void BreakUpText(spec) char *spec; { DoBreakUpText(spec, '\0'); } static int DoSetTextFillPatternColor(ObjPtr) struct ObjRec *ObjPtr; { struct ObjRec *obj_ptr=NULL; int changed=FALSE; switch (ObjPtr->type) { case OBJ_TEXT: if (ObjPtr->color != colorIndex) { ObjPtr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), colorMenuItems[colorIndex]); } changed = TRUE; } break; case OBJ_SYM: case OBJ_GROUP: case OBJ_ICON: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (DoSetTextFillPatternColor(obj_ptr)) { changed = TRUE; } } break; case OBJ_PIN: obj_ptr = GetPinObj(ObjPtr); if (DoSetTextFillPatternColor(obj_ptr)) { changed = TRUE; } break; } return changed; } void SetTextFillPatternColor() { struct SelRec *sel_ptr=NULL; int changed=FALSE; if (curChoice == DRAWTEXT) { if (curTextObj->color != colorIndex) { curTextObj->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(curTextObj->color_str, sizeof(curTextObj->color_str), colorMenuItems[colorIndex]); } SetFileModified(TRUE); sprintf(gszMsgBox, TgLoadString(STID_CUR_TEXT_BG_SET_TO_NAMED), colorMenuItems[colorIndex]); Msg(gszMsgBox); } return; } if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); StartCompositeCmd(); for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; PrepareToReplaceAnObj(obj_ptr); if (DoSetTextFillPatternColor(obj_ptr)) { changed = TRUE; RecordReplaceAnObj(obj_ptr); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; sprintf(gszMsgBox, TgLoadString(STID_SOME_TEXT_BG_SET_TO_NAMED), colorMenuItems[colorIndex]); Msg(gszMsgBox); } } void MakeRegularPolygon() { register int i; int vertex_at_right, xc, yc; int sel_ltx, sel_lty, sel_rbx, sel_rby, sides, radius; int ltx, lty, rbx, rby; double inc, angle, r; struct ObjRec *obj_ptr, *new_obj_ptr; struct PolygonRec *polygon_ptr; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } else if (topSel != botSel || topSel->obj->type != OBJ_POLYGON) { MsgBox(TgLoadString(STID_SEL_ONE_POLYGON_TO_MAKE_REG), TOOL_NAME, INFO_MB); return; } else if (topSel->obj->locked) { MsgBox(TgLoadString(STID_POLYGON_LOCKED), TOOL_NAME, INFO_MB); return; } PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); sel_ltx = selLtX; sel_lty = selLtY; sel_rbx = selRbX; sel_rby = selRbY; obj_ptr = topSel->obj; radius = (min(obj_ptr->obbox.rbx-obj_ptr->obbox.ltx, obj_ptr->obbox.rby-obj_ptr->obbox.lty))>>1; if (radius < 1) { MsgBox(TgLoadString(STID_POLYGON_TOO_SMALL_FOR_REGULAR), TOOL_NAME, INFO_MB); return; } sprintf(gszMsgBox, TgLoadString(STID_VERTEX_AT_3_OCLOCK_YNC)); if ((vertex_at_right=MsgBox(gszMsgBox, TOOL_NAME, YNC_MB)) == MB_ID_CANCEL) { return; } tmpTopObj = tmpBotObj = NULL; tmpTopSel = tmpBotSel = NULL; HighLightReverse(); new_obj_ptr = DupObj(obj_ptr); UnlinkObj(obj_ptr); polygon_ptr = new_obj_ptr->detail.g; sides = polygon_ptr->n-1; inc = 2*M_PI/sides; angle = (vertex_at_right==MB_ID_YES) ? 0 : inc/2; xc = obj_ptr->obbox.ltx+radius; yc = obj_ptr->obbox.lty+radius; if ((sides%4)==0 && vertex_at_right==MB_ID_NO) { r = ((double)(min(obj_ptr->obbox.rbx-obj_ptr->obbox.ltx, obj_ptr->obbox.rby-obj_ptr->obbox.lty)) / cos(angle)) / 2; } else { r = radius; } ltx = obj_ptr->obbox.rbx; lty = obj_ptr->obbox.rby; rbx = obj_ptr->obbox.ltx; rby = obj_ptr->obbox.lty; for (i=0; i < sides; i++, angle+=inc) { polygon_ptr->vlist[i].x = xc + round(r*cos(angle)); polygon_ptr->vlist[i].y = yc - round(r*sin(angle)); if (polygon_ptr->vlist[i].x < ltx) ltx = polygon_ptr->vlist[i].x; if (polygon_ptr->vlist[i].y < lty) lty = polygon_ptr->vlist[i].y; if (polygon_ptr->vlist[i].x > rbx) rbx = polygon_ptr->vlist[i].x; if (polygon_ptr->vlist[i].y > rby) rby = polygon_ptr->vlist[i].y; } polygon_ptr->vlist[sides].x = polygon_ptr->vlist[0].x; polygon_ptr->vlist[sides].y = polygon_ptr->vlist[0].y; new_obj_ptr->obbox.ltx = ltx; new_obj_ptr->obbox.lty = lty; new_obj_ptr->obbox.rbx = rbx; new_obj_ptr->obbox.rby = rby; AdjObjSplineVs(new_obj_ptr); AdjObjBBox(new_obj_ptr); topSel->obj = botSel->obj = new_obj_ptr; AddObj(NULL, topObj, new_obj_ptr); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); FreeObj(obj_ptr); UpdSelBBox(); RedrawAnArea(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; HighLightForward(); } int DeleteStructuredSplinePoint(index, poly_ptr, polygon_ptr) int index; /* index into ssvlist */ struct PolyRec *poly_ptr; struct PolygonRec *polygon_ptr; /* return FALSE if the object should be deleted */ { int i=0, j=0, n=0, idx=0, num_hinge_points=0, ssn=0; IntPoint *vs=NULL; StretchStructuredSplineInfo sssi; memset(&sssi, 0, sizeof(StretchStructuredSplineInfo)); if (poly_ptr != NULL) { ssn = poly_ptr->ssn; n = poly_ptr->n; vs = poly_ptr->vlist; SetIPTInfoForStretchPoly(index, n, vs, &sssi); } else if (polygon_ptr != NULL) { ssn = polygon_ptr->ssn; n = polygon_ptr->n; vs = polygon_ptr->vlist; SetIPTInfoForStretchPolygon(index, n, vs, &sssi); } if (sssi.hinge) { num_hinge_points = (n+2)/3; if ((poly_ptr != NULL && num_hinge_points-1 < 2) || (polygon_ptr != NULL && num_hinge_points-1 < 3)) { return FALSE; } if (!sssi.prev_valid) { /* first point of poly */ if (sssi.ipt.later_valid) { if (ssn-2 < 2) return FALSE; } else { if (ssn-1 < 2) return FALSE; } for (i=0; i < n-3; i++) { vs[i].x = vs[i+3].x; vs[i].y = vs[i+3].y; } poly_ptr->n = n-3; } else if (!sssi.next_valid) { /* last point of poly */ if (sssi.ipt.earlier_valid) { if (ssn-2 < 2) return FALSE; } else { if (ssn-1 < 2) return FALSE; } poly_ptr->n = n-3; } else { if (poly_ptr != NULL) { if (sssi.ipt.earlier_valid) { if (ssn-3 < 2) return FALSE; } else { if (ssn-1 < 2) return FALSE; } for (i=0, j=0; i < num_hinge_points; i++, j+=3) { if (j != sssi.orig_hinge_index) { if (i == 0) { vs[idx].x = vs[j].x; vs[idx].y = vs[j].y; vs[idx+1].x = vs[j+1].x; vs[idx+1].y = vs[j+1].y; idx += 2; } else if (i == num_hinge_points-1) { vs[idx].x = vs[j-1].x; vs[idx].y = vs[j-1].y; vs[idx+1].x = vs[j].x; vs[idx+1].y = vs[j].y; idx += 2; } else { vs[idx].x = vs[j-1].x; vs[idx].y = vs[j-1].y; vs[idx+1].x = vs[j].x; vs[idx+1].y = vs[j].y; vs[idx+2].x = vs[j+1].x; vs[idx+2].y = vs[j+1].y; idx += 3; } } } poly_ptr->n = n-3; } else if (polygon_ptr != NULL) { if (sssi.orig_hinge_index == 0 || sssi.orig_hinge_index == n-1) { IntPoint v2, v3; if ((sssi.orig_hinge_index == 0 && sssi.ipt.later_valid) || (sssi.orig_hinge_index == n-1 && sssi.ipt.earlier_valid)) { if (ssn-3 < 4) return FALSE; } else { if (ssn-1 < 4) return FALSE; } v2.x = vs[2].x; v2.y = vs[2].y; v3.x = vs[3].x; v3.y = vs[3].y; for (j=0; j < n-5; j++) { vs[j].x = vs[j+3].x; vs[j].y = vs[j+3].y; } vs[n-5].x = v2.x; vs[n-5].y = v2.y; vs[n-4].x = v3.x; vs[n-4].y = v3.y; } else { if (sssi.ipt.later_valid) { if (ssn-3 < 4) return FALSE; } else { if (ssn-1 < 4) return FALSE; } for (i=0, j=0; i < num_hinge_points; i++, j+=3) { if (j != sssi.orig_hinge_index) { if (i == 0) { vs[idx].x = vs[j].x; vs[idx].y = vs[j].y; vs[idx+1].x = vs[j+1].x; vs[idx+1].y = vs[j+1].y; idx += 2; } else if (i == num_hinge_points-1) { vs[idx].x = vs[j-1].x; vs[idx].y = vs[j-1].y; vs[idx+1].x = vs[j].x; vs[idx+1].y = vs[j].y; idx += 2; } else { vs[idx].x = vs[j-1].x; vs[idx].y = vs[j-1].y; vs[idx+1].x = vs[j].x; vs[idx+1].y = vs[j].y; vs[idx+2].x = vs[j+1].x; vs[idx+2].y = vs[j+1].y; idx += 3; } } } } polygon_ptr->n = n-3; } } } else { if (!sssi.prev_valid) { /* first point of poly */ ssn--; if ((poly_ptr != NULL && ssn < 2) || (polygon_ptr != NULL && ssn < 4)) { return FALSE; } vs[1].x = vs[0].x; vs[1].y = vs[0].y; } else if (!sssi.next_valid) { /* last point of poly */ ssn--; if ((poly_ptr != NULL && ssn < 2) || (polygon_ptr != NULL && ssn < 4)) { return FALSE; } vs[n-2].x = vs[n-1].x; vs[n-2].y = vs[n-1].y; } else { ssn -= 2; if ((poly_ptr != NULL && ssn < 2) || (polygon_ptr != NULL && ssn < 4)) { return FALSE; } if (poly_ptr != NULL) { vs[sssi.orig_hinge_index-1].x = vs[sssi.orig_hinge_index].x; vs[sssi.orig_hinge_index-1].y = vs[sssi.orig_hinge_index].y; vs[sssi.orig_hinge_index+1].x = vs[sssi.orig_hinge_index].x; vs[sssi.orig_hinge_index+1].y = vs[sssi.orig_hinge_index].y; } else if (polygon_ptr != NULL) { if (sssi.orig_hinge_index == 0 || sssi.orig_hinge_index == n-1) { vs[1].x = vs[0].x; vs[1].y = vs[0].y; vs[n-2].x = vs[n-1].x; vs[n-2].y = vs[n-1].y; } else { vs[sssi.orig_hinge_index-1].x = vs[sssi.orig_hinge_index].x; vs[sssi.orig_hinge_index-1].y = vs[sssi.orig_hinge_index].y; vs[sssi.orig_hinge_index+1].x = vs[sssi.orig_hinge_index].x; vs[sssi.orig_hinge_index+1].y = vs[sssi.orig_hinge_index].y; } } } } return TRUE; } void DeletePoint() { int i=0, n=0, pt_deleted=FALSE, deleting=TRUE, curved=(-1); int root_x=0, root_y=0, old_x=0, old_y=0, delete_obj=FALSE; struct ObjRec *obj_ptr=NULL; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; unsigned int status; Window root_win, child_win; IntPoint *vs=NULL; char *smooth=NULL; if (!(topSel != NULL && topSel == botSel && (topSel->obj->type == OBJ_POLY || topSel->obj->type == OBJ_POLYGON))) { MsgBox(TgLoadString(STID_SELECT_ONLY_ONE_POLY_POLYGON), TOOL_NAME, INFO_MB); return; } else if (topSel->obj->locked) { MsgBox(TgLoadString(STID_CANNOT_DEL_PT_FOR_LOCKED), TOOL_NAME, INFO_MB); return; } if (curChoice == VERTEXMODE) { HighLightReverse(); JustRemoveAllVSel(); HighLightForward(); } PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); obj_ptr = topSel->obj; if (!GetPolyOrPolygonControlPoints(obj_ptr, &poly_ptr, &polygon_ptr, &curved, &n, &vs, &smooth)) { return; } SaveStatusStrings(); SetMouseStatus(TgLoadCachedString(CSTID_DEL_A_VERTEX), TgLoadCachedString(CSTID_FINISH), TgLoadCachedString(CSTID_FINISH)); TwoLineMsg(TgLoadString(STID_LEFT_BTN_TO_DEL_PTS), TgLoadString(STID_CLICK_OTHER_BUTTON_TO_QUIT)); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonPressMask, GrabModeAsync, GrabModeAsync, None, defaultCursor, CurrentTime); } XQueryPointer(mainDisplay, drawWindow, &root_win, &child_win, &root_x, &root_y, &old_x, &old_y, &status); XSetFont(mainDisplay, revDefaultGC, defaultFontPtr->fid); /* do not translate -- program constants */ XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "DEL", 3); MarkRulers(old_x, old_y); while (deleting) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonPress) { if (input.xbutton.button == Button1) { int index=0; if (curved == LT_STRUCT_SPLINE) { if ((poly_ptr != NULL && PtInPolyMark(obj_ptr, input.xbutton.x, input.xbutton.y, poly_ptr->ssn, poly_ptr->ssvlist, &index)) || (polygon_ptr != NULL && PtInPolyMark(obj_ptr, input.xbutton.x, input.xbutton.y, polygon_ptr->ssn-1, polygon_ptr->ssvlist, &index))) { int sel_ltx=selLtX, sel_lty=selLtY; int sel_rbx=selRbX, sel_rby=selRbY; /* index is the index into ssvlist */ pt_deleted = TRUE; HighLightReverse(); if (DeleteStructuredSplinePoint(index, poly_ptr, polygon_ptr)) { AdjObjSplineVs(obj_ptr); if (poly_ptr != NULL) { UpdPolyBBox(obj_ptr, poly_ptr->n, poly_ptr->vlist); } else if (polygon_ptr != NULL) { UpdPolyBBox(obj_ptr, polygon_ptr->n, polygon_ptr->vlist); } AdjObjBBox(obj_ptr); XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "DEL", 3); old_x = input.xbutton.x; old_y = input.xbutton.y; UpdSelBBox(); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); if (obj_ptr != NULL) { XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "DEL", 3); } } else { XUngrabPointer(mainDisplay, CurrentTime); Msg(""); deleting = FALSE; delete_obj = TRUE; } SetFileModified(TRUE); justDupped = FALSE; } } else if ((obj_ptr->type == OBJ_POLY && PtInPolyMark(obj_ptr, input.xbutton.x, input.xbutton.y, poly_ptr->n, poly_ptr->vlist, &index)) || (obj_ptr->type == OBJ_POLYGON && PtInPolyMark(obj_ptr, input.xbutton.x, input.xbutton.y, polygon_ptr->n-1, polygon_ptr->vlist, &index))) { pt_deleted = TRUE; HighLightReverse(); if ((obj_ptr->type == OBJ_POLY && poly_ptr->n == 2) || (obj_ptr->type == OBJ_POLYGON && polygon_ptr->n == 4)) { XUngrabPointer(mainDisplay, CurrentTime); Msg(""); deleting = FALSE; delete_obj = TRUE; } else { int sel_ltx=selLtX, sel_lty=selLtY; int sel_rbx=selRbX, sel_rby=selRbY; switch (obj_ptr->type) { case OBJ_POLY: n = poly_ptr->n; smooth = poly_ptr->smooth; for (i = index+1; i < n; i++) { poly_ptr->vlist[i-1] = poly_ptr->vlist[i]; if (smooth != NULL) smooth[i-1] = smooth[i]; } if (smooth != NULL) { if (index == 0) { smooth[0] = FALSE; } else if (index == n-1) { smooth[n-2] = FALSE; } } poly_ptr->n--; AdjObjSplineVs(obj_ptr); if (poly_ptr->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, poly_ptr->n, poly_ptr->vlist); } else { UpdPolyBBox(obj_ptr, poly_ptr->intn, poly_ptr->intvlist); } break; case OBJ_POLYGON: n = polygon_ptr->n; smooth = polygon_ptr->smooth; for (i = index+1; i < n; i++) { polygon_ptr->vlist[i-1] = polygon_ptr->vlist[i]; if (smooth != NULL) smooth[i-1] = smooth[i]; } polygon_ptr->n--; n--; if (index == 0) { polygon_ptr->vlist[n-1] = polygon_ptr->vlist[0]; if (smooth != NULL) smooth[n-1] = smooth[0]; } AdjObjSplineVs(obj_ptr); if (polygon_ptr->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, polygon_ptr->n, polygon_ptr->vlist); } else { UpdPolyBBox(obj_ptr, polygon_ptr->intn, polygon_ptr->intvlist); } break; } AdjObjBBox(obj_ptr); XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "DEL", 3); old_x = input.xbutton.x; old_y = input.xbutton.y; UpdSelBBox(); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); if (obj_ptr != NULL) { XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "DEL", 3); } } SetFileModified(TRUE); justDupped = FALSE; } } else { XUngrabPointer(mainDisplay, CurrentTime); Msg(""); deleting = FALSE; XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "DEL", 3); } } else if (input.type == MotionNotify && input.xany.window == drawWindow) { XEvent ev; XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "DEL", 3); old_x = input.xmotion.x; old_y = input.xmotion.y; XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "DEL", 3); MarkRulers(old_x, old_y); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } if (delete_obj) { DelObj(obj_ptr); obj_ptr = NULL; free(topSel); topSel = botSel = NULL; XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "DEL", 3); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); UpdSelBBox(); } RestoreStatusStrings(); if (pt_deleted) { if (topSel == NULL) { ChangeReplaceOneCmdToDeleteCmd(); } else { RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); } } else { AbortPrepareCmd(CMD_REPLACE); } } #define ADDPOINT_DRAW (FALSE) #define ADDPOINT_ERASE (TRUE) #define ADDPOINT_CLICK (FALSE) #define ADDPOINT_DRAG (TRUE) #define ADDPOINT_STARTSHOW 0 #define ADDPOINT_DOSHOW 1 #define ADDPOINT_ENDSHOW 2 static void AddPointMeasureCursor(start, abs_w, abs_h, abs_x, abs_y) int start, abs_w, abs_h, abs_x, abs_y; { char buf[MAXSTRING], w_buf[80], h_buf[80], x_buf[80], y_buf[80]; PixelToMeasurementUnit(w_buf, abs_w); PixelToMeasurementUnit(h_buf, abs_h); PixelToMeasurementUnit(x_buf, abs_x); PixelToMeasurementUnit(y_buf, abs_y); /* do not translate -- program constants */ sprintf(buf, "ADD: dx=%s\n dy=%s\n x=%s\n y=%s", w_buf, h_buf, x_buf, y_buf); switch (start) { case ADDPOINT_STARTSHOW: StartShowMeasureCursor(OFFSET_X(abs_x), OFFSET_Y(abs_y), buf, FALSE); break; case ADDPOINT_DOSHOW: ShowMeasureCursor(OFFSET_X(abs_x), OFFSET_Y(abs_y), buf, FALSE); break; case ADDPOINT_ENDSHOW: EndShowMeasureCursor(OFFSET_X(abs_x), OFFSET_Y(abs_y), buf, FALSE); break; } } static int DetermineBefore(prev_dist, next_dist, new_prev_dist, new_next_dist) double prev_dist, next_dist, new_prev_dist, new_next_dist; { double prev_diff, next_diff; int before=FALSE; if (new_prev_dist < prev_dist) { if (new_next_dist < next_dist) { /* got closer to both previous and next vertices */ prev_diff = prev_dist-new_prev_dist; next_diff = next_dist-new_next_dist; if (prev_diff < next_diff) { before = FALSE; } else if (prev_diff > next_diff) { before = TRUE; } else { before = INVALID; } } else { /* got closer to previous vertex */ before = TRUE; } } else if (new_prev_dist > prev_dist) { if (new_next_dist > next_dist) { /* got further from both previous and next vertices */ prev_diff = prev_dist-new_prev_dist; next_diff = next_dist-new_next_dist; if (prev_diff < next_diff) { before = FALSE; } else if (prev_diff > next_diff) { before = TRUE; } else { before = INVALID; } } else { /* got closer to next vertex */ before = FALSE; } } else { /* same distance from previous vertex */ if (new_next_dist < next_dist) { before = FALSE; } else if (new_next_dist > next_dist) { before = TRUE; } else { /* same distance from both previous and next vertices */ before = INVALID; } } return before; } static int CanAddSmoothPointForStructuredSpline(button, psssi) unsigned int button; StretchStructuredSplineInfo *psssi; { if (button == Button2) { if (psssi->hinge) { if (!psssi->prev_valid) { /* first point of poly */ if (psssi->ipt.later_valid) { return FALSE; } } else if (!psssi->next_valid) { /* last point of poly */ if (psssi->ipt.earlier_valid) { return FALSE; } } else { if (psssi->ipt.later_valid) { return FALSE; } } } else { return FALSE; } } return TRUE; } typedef struct tagAddStructuredPointInfo { struct ObjRec *obj_ptr; struct PolyRec *poly_ptr; struct PolygonRec *polygon_ptr; unsigned int button; int index; /* index into ssvlist */ int start_mouse_x, start_mouse_y, n, ssn, already_moved, before; IntPoint *vlist, *ssvlist, vs[5], vs2[5]; char smooth[5], smooth2[5]; int num_vs, num_vs2, sn, sn2, saved_sn, saved_sn2; int dx_off, dy_off, extra_smooth, extra_smooth2; XPoint *sv, *sv2, dashed_vs[2]; StretchStructuredSplineInfo sssi; int prev_x, prev_y, prev_tx, prev_ty, x, y, tx, ty; int next_x, next_y, next_tx, next_ty, ruler_abs_x, ruler_abs_y; int orig_grid_x, orig_grid_y, grid_x, grid_y, mouse_x, mouse_y; int sel_ltx, sel_lty, sel_rbx, sel_rby; double prev_angle, next_angle, prev_dist, next_dist, ddx, ddy; } AddStructuredPointInfo; static int ContinueAddStructuredPolyOrPolygonPointSetup(paspi) AddStructuredPointInfo *paspi; { int i=0, tmp_x=0, tmp_y=0; IntPoint *vs=NULL, *vs2=NULL, *ssvlist=NULL; IntPoint *obj_ssvlist=NULL, *obj_vlist=NULL; char *smooth=NULL, *smooth2=NULL; struct ObjRec *obj_ptr=paspi->obj_ptr; struct PolyRec *poly_ptr=paspi->poly_ptr; struct PolygonRec *polygon_ptr=paspi->polygon_ptr; if (poly_ptr != NULL) { paspi->ssn = poly_ptr->ssn; paspi->n = poly_ptr->n; obj_ssvlist = poly_ptr->ssvlist; obj_vlist = poly_ptr->vlist; } else if (polygon_ptr != NULL) { paspi->ssn = polygon_ptr->ssn; paspi->n = polygon_ptr->n; obj_ssvlist = polygon_ptr->ssvlist; obj_vlist = polygon_ptr->vlist; } paspi->ssvlist = (IntPoint*)malloc((paspi->ssn+1)*sizeof(IntPoint)); if (paspi->ssvlist == NULL) FailAllocMessage(); for (i=0; i < paspi->ssn; i++) { paspi->ssvlist[i].x = obj_ssvlist[i].x; paspi->ssvlist[i].y = obj_ssvlist[i].y; } if (obj_ptr->ctm != NULL) { for (i=0; i < paspi->ssn; i++) { TransformPointThroughCTM(paspi->ssvlist[i].x-obj_ptr->x, paspi->ssvlist[i].y-obj_ptr->y, paspi->obj_ptr->ctm, &tmp_x, &tmp_y); paspi->ssvlist[i].x = obj_ptr->x+tmp_x; paspi->ssvlist[i].y = obj_ptr->y+tmp_y; } } paspi->vlist = (IntPoint*)malloc((paspi->n+1)*sizeof(IntPoint)); if (paspi->vlist == NULL) FailAllocMessage(); for (i=0; i < paspi->n; i++) { paspi->vlist[i].x = obj_vlist[i].x; paspi->vlist[i].y = obj_vlist[i].y; } if (obj_ptr->ctm != NULL) { for (i=0; i < paspi->n; i++) { TransformPointThroughCTM(paspi->vlist[i].x-obj_ptr->x, paspi->vlist[i].y-obj_ptr->y, paspi->obj_ptr->ctm, &tmp_x, &tmp_y); paspi->vlist[i].x = obj_ptr->x+tmp_x; paspi->vlist[i].y = obj_ptr->y+tmp_y; } } if (poly_ptr != NULL) { SetIPTInfoForStretchPoly(paspi->index, paspi->n, paspi->vlist, &paspi->sssi); } else if (polygon_ptr != NULL) { SetIPTInfoForStretchPolygon(paspi->index, paspi->n, paspi->vlist, &paspi->sssi); } if (!CanAddSmoothPointForStructuredSpline(paspi->button, &paspi->sssi)) { Msg(TgLoadString(STID_CANNOT_ADD_SMOOTH_VERTEX)); return FALSE; } paspi->sel_ltx = selLtX; paspi->sel_lty = selLtY; paspi->sel_rbx = selRbX; paspi->sel_rby = selRbY; ssvlist = paspi->ssvlist; vs = paspi->vs; smooth = paspi->smooth; vs2 = paspi->vs2; smooth2 = paspi->smooth2; memset(smooth, 0, sizeof(5*sizeof(char))); memset(smooth2, 0, sizeof(5*sizeof(char))); paspi->x = paspi->tx = ssvlist[paspi->index].x; paspi->y = paspi->ty = ssvlist[paspi->index].y; if (paspi->sssi.hinge) { /* hinge point, need to wait */ } else { /* must be adding a hinge point, i.e., Button1 is clicked */ if (!paspi->sssi.prev_valid) { /* first point of poly */ paspi->before = FALSE; paspi->num_vs = 3; vs[0].x = ssvlist[1].x; vs[0].y = ssvlist[1].y; vs[1].x = ssvlist[1].x; vs[1].y = ssvlist[1].y; vs[2].x = ssvlist[0].x; vs[2].y = ssvlist[0].y; smooth[1] = TRUE; vs2[0].x = ssvlist[1].x; vs2[0].y = ssvlist[1].y; if (paspi->sssi.ipt_next.earlier_valid) { paspi->num_vs2 = 3; vs2[1].x = paspi->sssi.ipt_next.earlier_smooth_pt.x; vs2[1].y = paspi->sssi.ipt_next.earlier_smooth_pt.y; smooth2[1] = TRUE; } else { paspi->num_vs2 = 2; } vs2[paspi->num_vs2-1].x = paspi->sssi.ipt_next.hinge_pt.x; vs2[paspi->num_vs2-1].y = paspi->sssi.ipt_next.hinge_pt.y; } else if (!paspi->sssi.next_valid) { /* last point of poly */ paspi->before = TRUE; vs[0].x = ssvlist[paspi->ssn-2].x; vs[0].y = ssvlist[paspi->ssn-2].y; if (paspi->sssi.ipt_prev.later_valid) { paspi->num_vs = 3; vs[1].x = paspi->sssi.ipt_prev.later_smooth_pt.x; vs[1].y = paspi->sssi.ipt_prev.later_smooth_pt.y; smooth[1] = TRUE; } else { paspi->num_vs = 2; } vs[paspi->num_vs-1].x = paspi->sssi.ipt_prev.hinge_pt.x; vs[paspi->num_vs-1].y = paspi->sssi.ipt_prev.hinge_pt.y; paspi->num_vs2 = 3; vs2[0].x = ssvlist[paspi->ssn-2].x; vs2[0].y = ssvlist[paspi->ssn-2].y; vs2[1].x = ssvlist[paspi->ssn-2].x; vs2[1].y = ssvlist[paspi->ssn-2].y; vs2[2].x = ssvlist[paspi->ssn-1].x; vs2[2].y = ssvlist[paspi->ssn-1].y; smooth2[1] = TRUE; } else { if (paspi->sssi.earlier_smooth_selected) { paspi->before = TRUE; vs[0].x = ssvlist[paspi->index].x; vs[0].y = ssvlist[paspi->index].y; if (paspi->sssi.ipt_prev.later_valid) { paspi->num_vs = 3; vs[1].x = paspi->sssi.ipt_prev.later_smooth_pt.x; vs[1].y = paspi->sssi.ipt_prev.later_smooth_pt.y; smooth[1] = TRUE; } else { paspi->num_vs = 2; } vs[paspi->num_vs-1].x = paspi->sssi.ipt_prev.hinge_pt.x; vs[paspi->num_vs-1].y = paspi->sssi.ipt_prev.hinge_pt.y; vs2[0].x = ssvlist[paspi->index].x; vs2[0].y = ssvlist[paspi->index].y; vs2[1].x = paspi->sssi.ipt.earlier_smooth_pt.x; vs2[1].y = paspi->sssi.ipt.earlier_smooth_pt.y; vs2[2].x = paspi->sssi.ipt.hinge_pt.x; vs2[2].y = paspi->sssi.ipt.hinge_pt.y; smooth2[1] = TRUE; paspi->num_vs2 = 3; } else { paspi->before = FALSE; vs[0].x = ssvlist[paspi->index].x; vs[0].y = ssvlist[paspi->index].y; vs[1].x = paspi->sssi.ipt.later_smooth_pt.x; vs[1].y = paspi->sssi.ipt.later_smooth_pt.y; vs[2].x = paspi->sssi.ipt.hinge_pt.x; vs[2].y = paspi->sssi.ipt.hinge_pt.y; smooth[1] = TRUE; paspi->num_vs = 3; vs2[0].x = ssvlist[paspi->index].x; vs2[0].y = ssvlist[paspi->index].y; if (paspi->sssi.ipt_next.earlier_valid) { paspi->num_vs2 = 3; vs2[1].x = paspi->sssi.ipt_next.earlier_smooth_pt.x; vs2[1].y = paspi->sssi.ipt_next.earlier_smooth_pt.y; smooth2[1] = TRUE; } else { paspi->num_vs2 = 2; } vs2[paspi->num_vs2-1].x = paspi->sssi.ipt_next.hinge_pt.x; vs2[paspi->num_vs2-1].y = paspi->sssi.ipt_next.hinge_pt.y; } } paspi->already_moved = TRUE; paspi->sv = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &paspi->sn, paspi->smooth, drawOrigX, drawOrigY, paspi->num_vs, vs); paspi->sv2 = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &paspi->sn2, paspi->smooth2, drawOrigX, drawOrigY, paspi->num_vs2, vs2); XDrawLines(mainDisplay, drawWindow, revDefaultGC, paspi->sv, paspi->sn, CoordModeOrigin); XDrawLines(mainDisplay, drawWindow, revDefaultGC, paspi->sv2, paspi->sn2, CoordModeOrigin); GridXY(paspi->start_mouse_x, paspi->start_mouse_y, &paspi->orig_grid_x, &paspi->orig_grid_y); paspi->grid_x = paspi->orig_grid_x; paspi->grid_y = paspi->orig_grid_y; paspi->mouse_x = paspi->start_mouse_x; paspi->mouse_y = paspi->start_mouse_y; paspi->ruler_abs_x = paspi->tx; paspi->ruler_abs_y = paspi->ty; MARKHR(drawWindow, revDefaultGC, OFFSET_X(paspi->ruler_abs_x), OFFSET_Y(paspi->ruler_abs_y)); AddPointMeasureCursor(ADDPOINT_STARTSHOW, 0, 0, paspi->tx, paspi->ty); return TRUE; } if (paspi->index == 0) { paspi->next_x = paspi->next_tx = paspi->ssvlist[1].x; paspi->next_y = paspi->next_ty = paspi->ssvlist[1].y; paspi->prev_x = paspi->prev_tx = (paspi->x<<1)-paspi->next_x; paspi->prev_y = paspi->prev_ty = (paspi->y<<1)-paspi->next_y; } else if (paspi->index == paspi->n-1) { paspi->prev_x = paspi->prev_tx = paspi->ssvlist[paspi->n-2].x; paspi->prev_y = paspi->prev_ty = paspi->ssvlist[paspi->n-2].y; paspi->next_x = paspi->next_tx = (paspi->x<<1)-paspi->prev_x; paspi->next_y = paspi->next_ty = (paspi->y<<1)-paspi->prev_y; } else { paspi->prev_x = paspi->prev_tx = ssvlist[paspi->index-1].x; paspi->prev_y = paspi->prev_ty = ssvlist[paspi->index-1].y; paspi->next_x = paspi->next_tx = ssvlist[paspi->index+1].x; paspi->next_y = paspi->next_ty = ssvlist[paspi->index+1].y; } paspi->ddx = (double)(paspi->prev_tx - paspi->tx); paspi->ddy = (double)(paspi->prev_ty - paspi->ty); paspi->prev_dist = paspi->ddx*paspi->ddx+paspi->ddy*paspi->ddy; paspi->ddx = (double)(paspi->next_tx - paspi->tx); paspi->ddy = (double)(paspi->next_ty - paspi->ty); paspi->next_dist = paspi->ddx*paspi->ddx+paspi->ddy*paspi->ddy; paspi->prev_angle = (paspi->prev_tx==paspi->tx) ? ((paspi->prev_ty>=paspi->ty) ? M_PI/2.0 : -M_PI/2.0) : atan2((double)(paspi->prev_ty-paspi->ty), (double)(paspi->prev_tx-paspi->tx)); paspi->next_angle = (paspi->next_tx==paspi->tx) ? ((paspi->next_ty>=paspi->ty) ? M_PI/2.0 : -M_PI/2.0) : atan2((double)(paspi->next_ty-paspi->ty), (double)(paspi->next_tx-paspi->tx)); GridXY(paspi->start_mouse_x, paspi->start_mouse_y, &paspi->orig_grid_x, &paspi->orig_grid_y); paspi->grid_x = paspi->orig_grid_x; paspi->grid_y = paspi->orig_grid_y; paspi->mouse_x = paspi->start_mouse_x; paspi->mouse_y = paspi->start_mouse_y; AddPointMeasureCursor(ADDPOINT_STARTSHOW, 0, 0, paspi->tx, paspi->ty); return TRUE; } static void ContinueAddStructuredPolyOrPolygonPointFirstMoved(paspi) AddStructuredPointInfo *paspi; { double new_prev_dist=(double)0, new_next_dist=(double)0; int new_x=paspi->ruler_abs_x, new_y=paspi->ruler_abs_y; paspi->already_moved = TRUE; paspi->ddx = (double)(paspi->prev_tx - paspi->mouse_x); paspi->ddy = (double)(paspi->prev_ty - paspi->mouse_y); new_prev_dist = paspi->ddx*paspi->ddx+paspi->ddy*paspi->ddy; paspi->ddx = (double)(paspi->next_tx - paspi->mouse_x); paspi->ddy = (double)(paspi->next_ty - paspi->mouse_y); new_next_dist = paspi->ddx*paspi->ddx+paspi->ddy*paspi->ddy; paspi->before = DetermineBefore(paspi->prev_dist, paspi->next_dist, new_prev_dist, new_next_dist); if (paspi->before == INVALID) { double new_angle=(double)0, theta_1=(double)0, theta_2=(double)0; new_angle = (new_x==paspi->tx) ? ((new_y>=paspi->ty) ? M_PI/2.0 : -M_PI/2.0) : atan2((double)(new_y-paspi->ty), (double)(new_x-paspi->tx)); theta_1 = fabs(paspi->prev_angle - new_angle); theta_2 = fabs(paspi->next_angle - new_angle); if (theta_1 > M_PI) theta_1 = 2*M_PI-theta_1; if (theta_2 > M_PI) theta_2 = 2*M_PI-theta_2; paspi->before = (theta_1 <= theta_2); } #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(paspi->sssi.hinge, "paspi->sssi.hinge is FALSE in ContinueAddStructuredPolyOrPolygonPointFirstMoved()", NULL); #endif /* _TGIF_DBG */ if (paspi->button == Button1) { IntPoint *vs=paspi->vs, *vs2=paspi->vs2; char *smooth=paspi->smooth, *smooth2=paspi->smooth2; memset(smooth, 0, sizeof(5*sizeof(char))); memset(smooth2, 0, sizeof(5*sizeof(char))); if (paspi->before) { /* Add a point between the current and the previous point */ if (!paspi->sssi.prev_valid) { /* first point of poly */ paspi->num_vs = 0; vs2[0].x = new_x; vs2[0].y = new_y; if (paspi->sssi.ipt.later_valid) { paspi->num_vs2 = 3; vs2[1].x = (paspi->sssi.ipt.hinge_pt.x<<1) - paspi->sssi.ipt.later_smooth_pt.x; vs2[1].y = (paspi->sssi.ipt.hinge_pt.y<<1) - paspi->sssi.ipt.later_smooth_pt.y; smooth2[1] = TRUE; paspi->extra_smooth2 = TRUE; MARKHO(drawWindow, revDefaultGC, OFFSET_X(vs2[1].x), OFFSET_Y(vs2[1].y)); } else { paspi->num_vs2 = 2; } vs2[paspi->num_vs2-1].x = paspi->sssi.ipt.hinge_pt.x; vs2[paspi->num_vs2-1].y = paspi->sssi.ipt.hinge_pt.y; } else if (!paspi->sssi.next_valid) { /* last point of poly */ vs[0].x = new_x; vs[0].y = new_y; if (paspi->sssi.ipt.earlier_valid) { paspi->num_vs = 3; vs[1].x = paspi->sssi.ipt.earlier_smooth_pt.x; vs[1].y = paspi->sssi.ipt.earlier_smooth_pt.y; smooth[1] = TRUE; } else { paspi->num_vs = 2; } vs[paspi->num_vs-1].x = paspi->sssi.ipt.hinge_pt.x; vs[paspi->num_vs-1].y = paspi->sssi.ipt.hinge_pt.y; vs2[0].x = new_x; vs2[0].y = new_y; if (paspi->sssi.ipt_prev.later_valid) { paspi->num_vs2 = 3; vs2[1].x = paspi->sssi.ipt_prev.later_smooth_pt.x; vs2[1].y = paspi->sssi.ipt_prev.later_smooth_pt.y; smooth2[1] = TRUE; } else { paspi->num_vs2 = 2; } vs2[paspi->num_vs2-1].x = paspi->sssi.ipt_prev.hinge_pt.x; vs2[paspi->num_vs2-1].y = paspi->sssi.ipt_prev.hinge_pt.y; } else { vs[0].x = new_x; vs[0].y = new_y; if (paspi->sssi.ipt_prev.later_valid) { paspi->num_vs = 3; vs[1].x = paspi->sssi.ipt_prev.later_smooth_pt.x; vs[1].y = paspi->sssi.ipt_prev.later_smooth_pt.y; smooth[1] = TRUE; } else { paspi->num_vs = 2; } vs[paspi->num_vs-1].x = paspi->sssi.ipt_prev.hinge_pt.x; vs[paspi->num_vs-1].y = paspi->sssi.ipt_prev.hinge_pt.y; vs2[0].x = new_x; vs2[0].y = new_y; if (paspi->sssi.ipt.earlier_valid) { paspi->num_vs2 = 3; vs2[1].x = paspi->sssi.ipt.earlier_smooth_pt.x; vs2[1].y = paspi->sssi.ipt.earlier_smooth_pt.y; smooth2[1] = TRUE; } else { paspi->num_vs2 = 2; } vs2[paspi->num_vs2-1].x = paspi->sssi.ipt.hinge_pt.x; vs2[paspi->num_vs2-1].y = paspi->sssi.ipt.hinge_pt.y; } } else { /* Add a point between the current and the next point */ if (!paspi->sssi.prev_valid) { /* first point of poly */ vs[0].x = new_x; vs[0].y = new_y; if (paspi->sssi.ipt.later_valid) { paspi->num_vs = 3; vs[1].x = paspi->sssi.ipt.later_smooth_pt.x; vs[1].y = paspi->sssi.ipt.later_smooth_pt.y; smooth[1] = TRUE; } else { paspi->num_vs = 2; } vs[paspi->num_vs-1].x = paspi->sssi.ipt.hinge_pt.x; vs[paspi->num_vs-1].y = paspi->sssi.ipt.hinge_pt.y; vs2[0].x = new_x; vs2[0].y = new_y; if (paspi->sssi.ipt_next.earlier_valid) { paspi->num_vs2 = 3; vs2[1].x = paspi->sssi.ipt_next.earlier_smooth_pt.x; vs2[1].y = paspi->sssi.ipt_next.earlier_smooth_pt.y; smooth2[1] = TRUE; } else { paspi->num_vs2 = 2; } vs2[paspi->num_vs2-1].x = paspi->sssi.ipt_next.hinge_pt.x; vs2[paspi->num_vs2-1].y = paspi->sssi.ipt_next.hinge_pt.y; } else if (!paspi->sssi.next_valid) { /* last point of poly */ vs[0].x = new_x; vs[0].y = new_y; if (paspi->sssi.ipt.earlier_valid) { paspi->num_vs = 3; vs[1].x = (paspi->sssi.ipt.hinge_pt.x<<1) - paspi->sssi.ipt.earlier_smooth_pt.x; vs[1].y = (paspi->sssi.ipt.hinge_pt.y<<1) - paspi->sssi.ipt.earlier_smooth_pt.y; smooth[1] = TRUE; paspi->extra_smooth = TRUE; MARKHO(drawWindow, revDefaultGC, OFFSET_X(vs[1].x), OFFSET_Y(vs[1].y)); } else { paspi->num_vs = 2; } vs[paspi->num_vs-1].x = paspi->sssi.ipt.hinge_pt.x; vs[paspi->num_vs-1].y = paspi->sssi.ipt.hinge_pt.y; paspi->num_vs2 = 0; } else { vs[0].x = new_x; vs[0].y = new_y; if (paspi->sssi.ipt.later_valid) { paspi->num_vs = 3; vs[1].x = paspi->sssi.ipt.later_smooth_pt.x; vs[1].y = paspi->sssi.ipt.later_smooth_pt.y; smooth[1] = TRUE; } else { paspi->num_vs = 2; } vs[paspi->num_vs-1].x = paspi->sssi.ipt.hinge_pt.x; vs[paspi->num_vs-1].y = paspi->sssi.ipt.hinge_pt.y; vs2[0].x = new_x; vs2[0].y = new_y; if (paspi->sssi.ipt_next.earlier_valid) { paspi->num_vs2 = 3; vs2[1].x = paspi->sssi.ipt_next.earlier_smooth_pt.x; vs2[1].y = paspi->sssi.ipt_next.earlier_smooth_pt.y; smooth2[1] = TRUE; } else { paspi->num_vs2 = 2; } vs2[paspi->num_vs2-1].x = paspi->sssi.ipt_next.hinge_pt.x; vs2[paspi->num_vs2-1].y = paspi->sssi.ipt_next.hinge_pt.y; } } } else { IntPoint *vs=paspi->vs, *vs2=paspi->vs2; char *smooth=paspi->smooth, *smooth2=paspi->smooth2; memset(smooth, 0, sizeof(5*sizeof(char))); memset(smooth2, 0, sizeof(5*sizeof(char))); if (!paspi->sssi.prev_valid) { /* first point of poly */ paspi->num_vs = 0; vs2[0].x = paspi->sssi.ipt.hinge_pt.x; vs2[0].y = paspi->sssi.ipt.hinge_pt.y; vs2[1].x = new_x; vs2[1].y = new_y; smooth2[1] = TRUE; if (paspi->sssi.ipt_next.earlier_valid) { paspi->num_vs2 = 4; vs2[2].x = paspi->sssi.ipt_next.earlier_smooth_pt.x; vs2[2].y = paspi->sssi.ipt_next.earlier_smooth_pt.y; smooth2[2] = TRUE; } else { paspi->num_vs2 = 3; } vs2[paspi->num_vs2-1].x = paspi->sssi.ipt_next.hinge_pt.x; vs2[paspi->num_vs2-1].y = paspi->sssi.ipt_next.hinge_pt.y; } else if (!paspi->sssi.next_valid) { /* last point of poly */ vs[0].x = paspi->sssi.ipt.hinge_pt.x; vs[0].y = paspi->sssi.ipt.hinge_pt.y; vs[1].x = new_x; vs[1].y = new_y; smooth[1] = TRUE; if (paspi->sssi.ipt_prev.later_valid) { paspi->num_vs = 4; vs[2].x = paspi->sssi.ipt_prev.later_smooth_pt.x; vs[2].y = paspi->sssi.ipt_prev.later_smooth_pt.y; smooth[2] = TRUE; } else { paspi->num_vs = 3; } vs[paspi->num_vs-1].x = paspi->sssi.ipt_prev.hinge_pt.x; vs[paspi->num_vs-1].y = paspi->sssi.ipt_prev.hinge_pt.y; paspi->num_vs2 = 0; } else { int new_x_prime=(paspi->sssi.ipt.hinge_pt.x<<1)-new_x; int new_y_prime=(paspi->sssi.ipt.hinge_pt.y<<1)-new_y; vs[0].x = paspi->sssi.ipt.hinge_pt.x; vs[0].y = paspi->sssi.ipt.hinge_pt.y; if (paspi->before) { vs[1].x = new_x; vs[1].y = new_y; } else { vs[1].x = new_x_prime; vs[1].y = new_y_prime; } smooth[1] = TRUE; if (paspi->sssi.ipt_prev.later_valid) { paspi->num_vs = 4; vs[2].x = paspi->sssi.ipt_prev.later_smooth_pt.x; vs[2].y = paspi->sssi.ipt_prev.later_smooth_pt.y; smooth[2] = TRUE; } else { paspi->num_vs = 3; } vs[paspi->num_vs-1].x = paspi->sssi.ipt_prev.hinge_pt.x; vs[paspi->num_vs-1].y = paspi->sssi.ipt_prev.hinge_pt.y; vs2[0].x = paspi->sssi.ipt.hinge_pt.x; vs2[0].y = paspi->sssi.ipt.hinge_pt.y; if (paspi->before) { vs2[1].x = new_x_prime; vs2[1].y = new_y_prime; } else { vs2[1].x = new_x; vs2[1].y = new_y; } smooth2[1] = TRUE; if (paspi->sssi.ipt_next.earlier_valid) { paspi->num_vs2 = 4; vs2[2].x = paspi->sssi.ipt_next.earlier_smooth_pt.x; vs2[2].y = paspi->sssi.ipt_next.earlier_smooth_pt.y; smooth2[2] = TRUE; } else { paspi->num_vs2 = 3; } vs2[paspi->num_vs2-1].x = paspi->sssi.ipt_next.hinge_pt.x; vs2[paspi->num_vs2-1].y = paspi->sssi.ipt_next.hinge_pt.y; } } } static void ContinueAddStructuredPolyOrPolygonPointRestMoved(paspi) AddStructuredPointInfo *paspi; { if (paspi->button == Button1) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(paspi->ruler_abs_x), OFFSET_Y(paspi->ruler_abs_y)); paspi->vs[0].x = paspi->vs2[0].x = paspi->ruler_abs_x; paspi->vs[0].y = paspi->vs2[0].y = paspi->ruler_abs_y; } else { XGCValues values; XSetDashes(mainDisplay, revDefaultGC, 0, dashList[8], dashListLength[8]); if (!paspi->sssi.prev_valid) { /* first point of poly */ paspi->vs2[1].x = paspi->ruler_abs_x; paspi->vs2[1].y = paspi->ruler_abs_y; paspi->dashed_vs[0].x = OFFSET_X(paspi->vs2[1].x); paspi->dashed_vs[0].y = OFFSET_Y(paspi->vs2[1].y); paspi->dashed_vs[1].x = OFFSET_X(paspi->vs2[0].x); paspi->dashed_vs[1].y = OFFSET_Y(paspi->vs2[0].y); MARKHO(drawWindow, revDefaultGC, paspi->dashed_vs[0].x, paspi->dashed_vs[0].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, paspi->dashed_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } else if (!paspi->sssi.next_valid) { /* last point of poly */ paspi->vs[1].x = paspi->ruler_abs_x; paspi->vs[1].y = paspi->ruler_abs_y; paspi->dashed_vs[0].x = OFFSET_X(paspi->vs[1].x); paspi->dashed_vs[0].y = OFFSET_Y(paspi->vs[1].y); paspi->dashed_vs[1].x = OFFSET_X(paspi->vs[0].x); paspi->dashed_vs[1].y = OFFSET_Y(paspi->vs[0].y); MARKHO(drawWindow, revDefaultGC, paspi->dashed_vs[0].x, paspi->dashed_vs[0].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, paspi->dashed_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } else { if (paspi->before) { paspi->vs[1].x = paspi->ruler_abs_x; paspi->vs[1].y = paspi->ruler_abs_y; paspi->vs2[1].x = (paspi->vs[0].x<<1) - paspi->ruler_abs_x; paspi->vs2[1].y = (paspi->vs[0].y<<1) - paspi->ruler_abs_y; paspi->dashed_vs[0].x = OFFSET_X(paspi->vs[1].x); paspi->dashed_vs[0].y = OFFSET_Y(paspi->vs[1].y); paspi->dashed_vs[1].x = OFFSET_X(paspi->vs2[1].x); paspi->dashed_vs[1].y = OFFSET_Y(paspi->vs2[1].y); MARKHO(drawWindow, revDefaultGC, paspi->dashed_vs[0].x, paspi->dashed_vs[0].y); MARKHO(drawWindow, revDefaultGC, paspi->dashed_vs[1].x, paspi->dashed_vs[1].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, paspi->dashed_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } else { paspi->vs2[1].x = paspi->ruler_abs_x; paspi->vs2[1].y = paspi->ruler_abs_y; paspi->vs[1].x = (paspi->vs2[0].x<<1) - paspi->ruler_abs_x; paspi->vs[1].y = (paspi->vs2[0].y<<1) - paspi->ruler_abs_y; paspi->dashed_vs[0].x = OFFSET_X(paspi->vs2[1].x); paspi->dashed_vs[0].y = OFFSET_Y(paspi->vs2[1].y); paspi->dashed_vs[1].x = OFFSET_X(paspi->vs[1].x); paspi->dashed_vs[1].y = OFFSET_Y(paspi->vs[1].y); MARKHO(drawWindow, revDefaultGC, paspi->dashed_vs[0].x, paspi->dashed_vs[0].y); MARKHO(drawWindow, revDefaultGC, paspi->dashed_vs[1].x, paspi->dashed_vs[1].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, paspi->dashed_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } } if (paspi->num_vs > 0) { paspi->sv = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &paspi->sn, paspi->smooth, drawOrigX, drawOrigY, paspi->num_vs, paspi->vs); XDrawLines(mainDisplay, drawWindow, revDefaultGC, paspi->sv, paspi->sn, CoordModeOrigin); } if (paspi->num_vs2 > 0) { paspi->sv2 = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &paspi->sn2, paspi->smooth2, drawOrigX, drawOrigY, paspi->num_vs2, paspi->vs2); XDrawLines(mainDisplay, drawWindow, revDefaultGC, paspi->sv2, paspi->sn2, CoordModeOrigin); } MarkRulers(OFFSET_X(paspi->ruler_abs_x), OFFSET_Y(paspi->ruler_abs_y)); AddPointMeasureCursor(ADDPOINT_DOSHOW, ABS_SIZE(paspi->dx_off), ABS_SIZE(paspi->dy_off), paspi->ruler_abs_x, paspi->ruler_abs_y); } static int ContinueAddStructuredPolyOrPolygonPointFinished(paspi) AddStructuredPointInfo *paspi; { int i=0, tmp_x=0, tmp_y=0, new_abs_x=0, new_abs_y=0, orig_hinge_index=0; int ok=TRUE; IntPoint *obj_vlist=NULL; struct ObjRec *obj_ptr=paspi->obj_ptr; struct PolyRec *poly_ptr=paspi->poly_ptr; struct PolygonRec *polygon_ptr=paspi->polygon_ptr; if (paspi->extra_smooth) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(paspi->vs[1].x), OFFSET_Y(paspi->vs[1].y)); } if (paspi->extra_smooth2) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(paspi->vs2[1].x), OFFSET_Y(paspi->vs2[1].y)); } if (!paspi->already_moved) { ok = FALSE; } else { if (paspi->ruler_abs_x == paspi->sssi.ipt.hinge_pt.x && paspi->ruler_abs_y == paspi->sssi.ipt.hinge_pt.y) { ok = FALSE; } if (paspi->before) { if (paspi->ruler_abs_x == paspi->sssi.ipt_prev.hinge_pt.x && paspi->ruler_abs_y == paspi->sssi.ipt_prev.hinge_pt.y) { ok = FALSE; } } else { if (paspi->ruler_abs_x == paspi->sssi.ipt_next.hinge_pt.x && paspi->ruler_abs_y == paspi->sssi.ipt_next.hinge_pt.y) { ok = FALSE; } } } if (!ok) { free(paspi->ssvlist); free(paspi->vlist); return FALSE; } if (poly_ptr != NULL) { obj_vlist = poly_ptr->vlist; } else if (polygon_ptr != NULL) { obj_vlist = polygon_ptr->vlist; } HighLightReverse(); if (paspi->button == Button1) { /* add a hinge point */ IntPoint *new_vlist=(IntPoint*)malloc((paspi->n+4)*sizeof(IntPoint)); if (new_vlist == NULL) FailAllocMessage(); memset(new_vlist, 0, (paspi->n+4)*sizeof(IntPoint)); obj_ptr = paspi->obj_ptr; new_abs_x = paspi->ruler_abs_x; new_abs_y = paspi->ruler_abs_y; if (obj_ptr->ctm != NULL) { ReverseTransformPointThroughCTM(new_abs_x-obj_ptr->x, new_abs_y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); new_abs_x = obj_ptr->x+tmp_x; new_abs_y = obj_ptr->y+tmp_y; } if (paspi->before) { if (!paspi->sssi.prev_valid) { /* first point of poly */ new_vlist[0].x = new_vlist[1].x = new_abs_x; new_vlist[0].y = new_vlist[1].y = new_abs_y; if (paspi->sssi.ipt.later_valid) { new_vlist[2].x = (obj_vlist[0].x<<1) - obj_vlist[1].x; new_vlist[2].y = (obj_vlist[0].y<<1) - obj_vlist[1].y; } else { new_vlist[2].x = obj_vlist[0].x; new_vlist[2].y = obj_vlist[0].y; } for (i=0; i < paspi->n; i++) { new_vlist[i+3].x = obj_vlist[i].x; new_vlist[i+3].y = obj_vlist[i].y; } } else if (!paspi->sssi.next_valid) { /* last point of poly */ for (i=0; i < paspi->n-2; i++) { new_vlist[i].x = obj_vlist[i].x; new_vlist[i].y = obj_vlist[i].y; } new_vlist[paspi->n-2].x = new_vlist[paspi->n-1].x = new_vlist[paspi->n].x = new_abs_x; new_vlist[paspi->n-2].y = new_vlist[paspi->n-1].y = new_vlist[paspi->n].y = new_abs_y; new_vlist[paspi->n+1].x = obj_vlist[paspi->n-2].x; new_vlist[paspi->n+1].y = obj_vlist[paspi->n-2].y; new_vlist[paspi->n+2].x = obj_vlist[paspi->n-1].x; new_vlist[paspi->n+2].y = obj_vlist[paspi->n-1].y; } else { orig_hinge_index = paspi->sssi.orig_hinge_index; if (polygon_ptr != NULL && orig_hinge_index == 0) { orig_hinge_index = polygon_ptr->n-1; } for (i=0; i < orig_hinge_index-1; i++) { new_vlist[i].x = obj_vlist[i].x; new_vlist[i].y = obj_vlist[i].y; } new_vlist[orig_hinge_index-1].x = new_vlist[orig_hinge_index].x = new_vlist[orig_hinge_index+1].x = new_abs_x; new_vlist[orig_hinge_index-1].y = new_vlist[orig_hinge_index].y = new_vlist[orig_hinge_index+1].y = new_abs_y; for (i=orig_hinge_index-1; i < paspi->n; i++) { new_vlist[i+3].x = obj_vlist[i].x; new_vlist[i+3].y = obj_vlist[i].y; } } } else { if (!paspi->sssi.prev_valid) { /* first point of poly */ for (i=0; i < 2; i++) { new_vlist[i].x = obj_vlist[i].x; new_vlist[i].y = obj_vlist[i].y; } new_vlist[2].x = new_vlist[3].x = new_vlist[4].x = new_abs_x; new_vlist[2].y = new_vlist[3].y = new_vlist[4].y = new_abs_y; for (i=2; i < paspi->n; i++) { new_vlist[i+3].x = obj_vlist[i].x; new_vlist[i+3].y = obj_vlist[i].y; } } else if (!paspi->sssi.next_valid) { /* last point of poly */ for (i=0; i < paspi->n; i++) { new_vlist[i].x = obj_vlist[i].x; new_vlist[i].y = obj_vlist[i].y; } if (paspi->sssi.ipt.earlier_valid) { new_vlist[paspi->n].x = (obj_vlist[paspi->n-1].x<<1) - obj_vlist[paspi->n-2].x; new_vlist[paspi->n].y = (obj_vlist[paspi->n-1].y<<1) - obj_vlist[paspi->n-2].y; } else { new_vlist[paspi->n].x = obj_vlist[paspi->n-1].x; new_vlist[paspi->n].y = obj_vlist[paspi->n-1].y; } new_vlist[paspi->n+1].x = new_vlist[paspi->n+2].x = new_abs_x; new_vlist[paspi->n+1].y = new_vlist[paspi->n+2].y = new_abs_y; } else { orig_hinge_index = paspi->sssi.orig_hinge_index; for (i=0; i < orig_hinge_index+2; i++) { new_vlist[i].x = obj_vlist[i].x; new_vlist[i].y = obj_vlist[i].y; } new_vlist[orig_hinge_index+2].x = new_vlist[orig_hinge_index+3].x = new_vlist[orig_hinge_index+4].x = new_abs_x; new_vlist[orig_hinge_index+2].y = new_vlist[orig_hinge_index+3].y = new_vlist[orig_hinge_index+4].y = new_abs_y; for (i=orig_hinge_index+2; i < paspi->n; i++) { new_vlist[i+3].x = obj_vlist[i].x; new_vlist[i+3].y = obj_vlist[i].y; } } } free(obj_vlist); if (poly_ptr != NULL) { paspi->poly_ptr->vlist = new_vlist; paspi->poly_ptr->n += 3; } else if (polygon_ptr != NULL) { paspi->polygon_ptr->vlist = new_vlist; paspi->polygon_ptr->n += 3; } } else { /* paspi->button == Button2 */ obj_ptr = paspi->obj_ptr; new_abs_x = paspi->ruler_abs_x; new_abs_y = paspi->ruler_abs_y; if (obj_ptr->ctm != NULL) { ReverseTransformPointThroughCTM(new_abs_x-obj_ptr->x, new_abs_y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); new_abs_x = obj_ptr->x+tmp_x; new_abs_y = obj_ptr->y+tmp_y; } if (!paspi->sssi.prev_valid) { /* first point of poly */ obj_vlist[1].x = new_abs_x; obj_vlist[1].y = new_abs_y; } else if (!paspi->sssi.next_valid) { /* last point of poly */ obj_vlist[paspi->n-2].x = new_abs_x; obj_vlist[paspi->n-2].y = new_abs_y; } else { orig_hinge_index = paspi->sssi.orig_hinge_index; if (paspi->before) { if (polygon_ptr != NULL && orig_hinge_index == 0) { obj_vlist[paspi->n-2].x = new_abs_x; obj_vlist[paspi->n-2].y = new_abs_y; obj_vlist[orig_hinge_index+1].x = (obj_vlist[orig_hinge_index].x<<1) - new_abs_x; obj_vlist[orig_hinge_index+1].y = (obj_vlist[orig_hinge_index].y<<1) - new_abs_y; } else { obj_vlist[orig_hinge_index-1].x = new_abs_x; obj_vlist[orig_hinge_index-1].y = new_abs_y; obj_vlist[orig_hinge_index+1].x = (obj_vlist[orig_hinge_index].x<<1) - new_abs_x; obj_vlist[orig_hinge_index+1].y = (obj_vlist[orig_hinge_index].y<<1) - new_abs_y; } } else { if (polygon_ptr != NULL && orig_hinge_index == 0) { obj_vlist[orig_hinge_index+1].x = new_abs_x; obj_vlist[orig_hinge_index+1].y = new_abs_y; obj_vlist[paspi->n-2].x = (obj_vlist[orig_hinge_index].x<<1) - new_abs_x; obj_vlist[paspi->n-2].y = (obj_vlist[orig_hinge_index].y<<1) - new_abs_y; } else { obj_vlist[orig_hinge_index+1].x = new_abs_x; obj_vlist[orig_hinge_index+1].y = new_abs_y; obj_vlist[orig_hinge_index-1].x = (obj_vlist[orig_hinge_index].x<<1) - new_abs_x; obj_vlist[orig_hinge_index-1].y = (obj_vlist[orig_hinge_index].y<<1) - new_abs_y; } } } } AdjObjSplineVs(obj_ptr); if (poly_ptr != NULL) { UpdPolyBBox(obj_ptr, poly_ptr->n, poly_ptr->vlist); } else if (polygon_ptr != NULL) { UpdPolyBBox(obj_ptr, polygon_ptr->n, polygon_ptr->vlist); } AdjObjBBox(obj_ptr); UpdSelBBox(); RedrawAreas(botObj, paspi->sel_ltx-GRID_ABS_SIZE(1), paspi->sel_lty-GRID_ABS_SIZE(1), paspi->sel_rbx+GRID_ABS_SIZE(1), paspi->sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; free(paspi->ssvlist); free(paspi->vlist); return TRUE; } static void EraseHighLightForAddStructuredPolyPoint(paspi, abs_dx, abs_dy, measure_cursor_mode) AddStructuredPointInfo *paspi; int abs_dx, abs_dy, measure_cursor_mode; { if (paspi->sv != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, paspi->sv, paspi->sn, CoordModeOrigin); free(paspi->sv); paspi->sv = NULL; } if (paspi->sv2 != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, paspi->sv2, paspi->sn2, CoordModeOrigin); free(paspi->sv2); paspi->sv2 = NULL; } AddPointMeasureCursor(measure_cursor_mode, abs_dx, abs_dy, paspi->tx+abs_dx, paspi->ty+abs_dy); if (paspi->button == Button1) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(paspi->ruler_abs_x), OFFSET_Y(paspi->ruler_abs_y)); } else { XGCValues values; if (paspi->num_vs > 0) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(paspi->vs[1].x), OFFSET_Y(paspi->vs[1].y)); } if (paspi->num_vs2 > 0) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(paspi->vs2[1].x), OFFSET_Y(paspi->vs2[1].y)); } XSetDashes(mainDisplay, revDefaultGC, 0, dashList[8], dashListLength[8]); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, paspi->dashed_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } static int ContinueAddStructuredPolyOrPolygonPoint(obj_ptr, button, start_mouse_x, start_mouse_y, index, poly_ptr, polygon_ptr, pn_last_mouse_x, pn_last_mouse_y) struct ObjRec *obj_ptr; unsigned int button; int start_mouse_x, start_mouse_y, index, *pn_last_mouse_x, *pn_last_mouse_y; struct PolyRec *poly_ptr; struct PolygonRec *polygon_ptr; /* (start_mouse_x,start_mouse_y) is the mouse's origin in screen offsets */ { AddStructuredPointInfo aspi; int done=FALSE; memset(&aspi, 0, sizeof(AddStructuredPointInfo)); aspi.before = INVALID; aspi.obj_ptr = obj_ptr; aspi.button = button; aspi.start_mouse_x = start_mouse_x; aspi.start_mouse_y = start_mouse_y; aspi.index = index; if (poly_ptr != NULL) { aspi.poly_ptr = poly_ptr; } else if (polygon_ptr != NULL) { aspi.polygon_ptr = polygon_ptr; } else { /* should not come here */ return FALSE; } if (!ContinueAddStructuredPolyOrPolygonPointSetup(&aspi)) { return FALSE; } while (!done) { XEvent input, ev; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == MotionNotify || input.type == KeyPress || input.type == KeyRelease) { if (input.type == KeyPress || input.type == KeyRelease) { aspi.mouse_x = aspi.grid_x; aspi.mouse_y = aspi.grid_y; } else { aspi.mouse_x = input.xmotion.x; aspi.mouse_y = input.xmotion.y; } if (shiftForDiagMouseMove && DiagEventCheck(&input)) { if (input.type == KeyRelease) { aspi.mouse_x = input.xkey.x; aspi.mouse_y = input.xkey.y; } else { DiagGridXY(aspi.orig_grid_x, aspi.orig_grid_y, &aspi.mouse_x, &aspi.mouse_y); } } GridXY(aspi.mouse_x, aspi.mouse_y, &aspi.grid_x, &aspi.grid_y); /* erase */ EraseHighLightForAddStructuredPolyPoint(&aspi, ABS_SIZE(aspi.dx_off), ABS_SIZE(aspi.dy_off), ADDPOINT_DOSHOW); aspi.dx_off = aspi.grid_x - aspi.orig_grid_x; aspi.dy_off = aspi.grid_y - aspi.orig_grid_y; aspi.ruler_abs_x = aspi.tx + ABS_SIZE(aspi.dx_off); aspi.ruler_abs_y = aspi.ty + ABS_SIZE(aspi.dy_off); MarkRulers(OFFSET_X(aspi.ruler_abs_x), OFFSET_Y(aspi.ruler_abs_y)); if (!aspi.already_moved) { ContinueAddStructuredPolyOrPolygonPointFirstMoved(&aspi); } ContinueAddStructuredPolyOrPolygonPointRestMoved(&aspi); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } else if (input.type == ButtonRelease) { done = TRUE; *pn_last_mouse_x = aspi.mouse_x; *pn_last_mouse_y = aspi.mouse_y; /* erase */ EraseHighLightForAddStructuredPolyPoint(&aspi, ABS_SIZE(aspi.dx_off), ABS_SIZE(aspi.dy_off), ADDPOINT_DOSHOW); return ContinueAddStructuredPolyOrPolygonPointFinished(&aspi); } } return TRUE; } static int ContinueAddPolyPoint(ObjPtr, MouseX, MouseY, Index, PolyPtr, LastMouseX, LastMouseY) struct ObjRec *ObjPtr; int MouseX, MouseY, Index; struct PolyRec *PolyPtr; int *LastMouseX, *LastMouseY; /* * (MouseX,MouseY) is the mouse's origin in screen offsets * * This routine is only called for LT_STRAIGHT, LT_SPLINE, or LT_INTSPLINE. */ { int n=PolyPtr->n, sn=0, curved=PolyPtr->curved; int already_moved=FALSE, done=FALSE, before=INVALID; XPoint v[3], *sv=NULL; IntPoint *vs=PolyPtr->vlist, *pv=NULL, *cntrlv=NULL; int prev_x, prev_y, prev_tx, prev_ty, x, y, tx, ty, tmp_x, tmp_y; int next_x, next_y, next_tx, next_ty; int orig_x, orig_y, grid_x, grid_y, new_mouse_x, new_mouse_y; int sel_ltx, sel_lty, sel_rbx, sel_rby, num=0, i, intn=0; char *smooth=PolyPtr->smooth, *tmp_smooth=NULL; double prev_angle, next_angle, prev_dist, next_dist, dx, dy; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(curved != LT_STRUCT_SPLINE, "curved == LT_STRUCT_SPLINE in ContinueAddPolyPoint()", NULL); #endif /* _TGIF_DBG */ memset(v, 0, sizeof(XPoint)*3); sel_ltx = selLtX; sel_lty = selLtY; sel_rbx = selRbX; sel_rby = selRbY; x = tx = vs[Index].x; y = ty = vs[Index].y; if (ObjPtr->ctm != NULL) { TransformPointThroughCTM(x-ObjPtr->x, y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); tx = ObjPtr->x+tmp_x; ty = ObjPtr->y+tmp_y; } if (curved == LT_INTSPLINE || smooth == NULL || !smooth[Index]) { MARK(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } else { MARKO(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } if (Index == 0) { next_x = next_tx = vs[1].x; next_y = next_ty = vs[1].y; prev_x = prev_tx = 2*x-next_x; prev_y = prev_ty = 2*y-next_y; } else if (Index == n-1) { prev_x = prev_tx = vs[n-2].x; prev_y = prev_ty = vs[n-2].y; next_x = next_tx = 2*x-prev_x; next_y = next_ty = 2*y-prev_y; } else { prev_x = prev_tx = vs[Index-1].x; prev_y = prev_ty = vs[Index-1].y; next_x = next_tx = vs[Index+1].x; next_y = next_ty = vs[Index+1].y; } if (ObjPtr->ctm != NULL) { TransformPointThroughCTM(next_x-ObjPtr->x, next_y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); next_tx = ObjPtr->x+tmp_x; next_ty = ObjPtr->y+tmp_y; TransformPointThroughCTM(prev_x-ObjPtr->x, prev_y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); prev_tx = ObjPtr->x+tmp_x; prev_ty = ObjPtr->y+tmp_y; } dx = (double)(prev_tx - tx); dy = (double)(prev_ty - ty); prev_dist = dx*dx+dy*dy; dx = (double)(next_tx - tx); dy = (double)(next_ty - ty); next_dist = dx*dx+dy*dy; prev_angle = (prev_tx==tx) ? ((prev_ty>=ty) ? M_PI/2.0 : -M_PI/2.0) : atan2((double)(prev_ty-ty), (double)(prev_tx-tx)); next_angle = (next_tx==tx) ? ((next_ty>=ty) ? M_PI/2.0 : -M_PI/2.0) : atan2((double)(next_ty-ty), (double)(next_tx-tx)); pv = (IntPoint*)malloc((n+2)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); if (curved != LT_INTSPLINE && smooth != NULL) { tmp_smooth = (char*)malloc((n+2)*sizeof(char)); if (tmp_smooth == NULL) FailAllocMessage(); } if (ObjPtr->ctm == NULL) { for (i = 0; i <= Index; i++) { pv[i].x = vs[i].x; pv[i].y = vs[i].y; if (tmp_smooth != NULL) tmp_smooth[i] = smooth[i]; } for (i = Index; i < n; i++) { pv[i+1].x = vs[i].x; pv[i+1].y = vs[i].y; if (tmp_smooth != NULL) tmp_smooth[i+1] = smooth[i]; } } else { for (i = 0; i <= Index; i++) { TransformPointThroughCTM(vs[i].x-ObjPtr->x, vs[i].y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); pv[i].x = ObjPtr->x+tmp_x; pv[i].y = ObjPtr->y+tmp_y; if (tmp_smooth != NULL) tmp_smooth[i] = smooth[i]; } for (i = Index; i < n; i++) { TransformPointThroughCTM(vs[i].x-ObjPtr->x, vs[i].y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); pv[i+1].x = ObjPtr->x+tmp_x; pv[i+1].y = ObjPtr->y+tmp_y; if (tmp_smooth != NULL) tmp_smooth[i+1] = smooth[i]; } } GridXY(MouseX, MouseY, &orig_x, &orig_y); grid_x = orig_x; grid_y = orig_y; new_mouse_x = MouseX; new_mouse_y = MouseY; AddPointMeasureCursor(ADDPOINT_STARTSHOW, 0, 0, tx, ty); while (!done) { double new_angle, theta_1, theta_2; XEvent input, ev; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == MotionNotify || input.type == KeyPress || input.type == KeyRelease) { int new_x, new_y; if (input.type == KeyPress || input.type == KeyRelease) { new_mouse_x = grid_x; new_mouse_y = grid_y; } else { new_mouse_x = input.xmotion.x; new_mouse_y = input.xmotion.y; } if (shiftForDiagMouseMove && DiagEventCheck(&input)) { if (input.type == KeyRelease) { new_mouse_x = input.xkey.x; new_mouse_y = input.xkey.y; } else { DiagGridXY(orig_x, orig_y, &new_mouse_x, &new_mouse_y); } } GridXY(new_mouse_x, new_mouse_y, &grid_x, &grid_y); new_x = ABS_SIZE(new_mouse_x-MouseX) + tx; new_y = ABS_SIZE(new_mouse_y-MouseY) + ty; if (!already_moved) { double new_prev_dist, new_next_dist; already_moved = TRUE; dx = (double)(prev_tx - new_mouse_x); dy = (double)(prev_ty - new_mouse_y); new_prev_dist = dx*dx+dy*dy; dx = (double)(next_tx - new_mouse_x); dy = (double)(next_ty - new_mouse_y); new_next_dist = dx*dx+dy*dy; before = DetermineBefore(prev_dist, next_dist, new_prev_dist, new_next_dist); if (before == INVALID) { new_angle = (new_x==tx) ? ((new_y>=ty) ? M_PI/2.0 : -M_PI/2.0) : atan2((double)(new_y-ty), (double)(new_x-tx)); theta_1 = fabs(prev_angle - new_angle); theta_2 = fabs(next_angle - new_angle); if (theta_1 > M_PI) theta_1 = 2*M_PI-theta_1; if (theta_2 > M_PI) theta_2 = 2*M_PI-theta_2; before = (theta_1 <= theta_2); } if (before) { /* Add a point between the current and the previous point */ if (Index == 0) { num = 2; v[0].x = OFFSET_X(tx); v[0].y = OFFSET_Y(ty); v[1].x = OFFSET_X(tx); v[1].y = OFFSET_Y(ty); } else { num = 3; v[0].x = OFFSET_X(prev_tx); v[0].y = OFFSET_Y(prev_ty); v[1].x = OFFSET_X(tx); v[1].y = OFFSET_Y(ty); v[2].x = OFFSET_X(tx); v[2].y = OFFSET_Y(ty); } } else { /* Add a point between the current and the next point */ if (Index == n-1) { num = 2; v[0].x = OFFSET_X(tx); v[0].y = OFFSET_Y(ty); v[1].x = OFFSET_X(tx); v[1].y = OFFSET_Y(ty); } else { num = 3; v[0].x = OFFSET_X(tx); v[0].y = OFFSET_Y(ty); v[1].x = OFFSET_X(tx); v[1].y = OFFSET_Y(ty); v[2].x = OFFSET_X(next_tx); v[2].y = OFFSET_Y(next_ty); } } switch (curved) { case LT_STRAIGHT: case LT_SPLINE: sv = MakeMultiSplinePolyVertex(curved, &sn, tmp_smooth, drawOrigX, drawOrigY, n+1, pv); break; case LT_INTSPLINE: sv = MakeIntSplinePolyVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n+1, pv); break; case LT_STRUCT_SPLINE: /* should never get here */ break; } XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); } else { AddPointMeasureCursor(ADDPOINT_DOSHOW, abs(ABS_X(v[1].x)-tx), abs(ABS_Y(v[1].y)-ty), ABS_X(v[1].x), ABS_Y(v[1].y)); XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); v[1].x = OFFSET_X(tx) + grid_x - orig_x; v[1].y = OFFSET_Y(ty) + grid_y - orig_y; free(sv); if (before) { pv[Index].x = tx + ABS_SIZE(grid_x-orig_x); pv[Index].y = ty + ABS_SIZE(grid_y-orig_y); } else { pv[Index+1].x = tx + ABS_SIZE(grid_x-orig_x); pv[Index+1].y = ty + ABS_SIZE(grid_y-orig_y); } switch (curved) { case LT_STRAIGHT: case LT_SPLINE: sv = MakeMultiSplinePolyVertex(curved, &sn, tmp_smooth, drawOrigX, drawOrigY, n+1, pv); break; case LT_INTSPLINE: free(cntrlv); sv = MakeIntSplinePolyVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n+1, pv); break; case LT_STRUCT_SPLINE: /* should never get here */ break; } XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); MarkRulers(v[1].x, v[1].y); AddPointMeasureCursor(ADDPOINT_DOSHOW, abs(ABS_X(v[1].x)-tx), abs(ABS_Y(v[1].y)-ty), ABS_X(v[1].x), ABS_Y(v[1].y)); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } else if (input.type == ButtonRelease) { done = TRUE; *LastMouseX = new_mouse_x; *LastMouseY = new_mouse_y; if (curved == LT_INTSPLINE || smooth == NULL || !smooth[Index]) { MARK(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } else { MARKO(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } if (already_moved) { AddPointMeasureCursor(ADDPOINT_ENDSHOW, abs(ABS_X(v[1].x)-tx), abs(ABS_Y(v[1].y)-ty), ABS_X(v[1].x), ABS_Y(v[1].y)); } else { AddPointMeasureCursor(ADDPOINT_STARTSHOW, 0, 0, tx, ty); } if (!already_moved) { return FALSE; } else { XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); if (grid_x == orig_x && grid_y == orig_y) { return FALSE; } } HighLightReverse(); vs = (IntPoint*)realloc(vs, (n+2)*sizeof(IntPoint)); if (vs == NULL) return FailAllocMessage(); if (smooth != NULL) { smooth = (char*)realloc(smooth, (n+2)*sizeof(char)); if (smooth == NULL) return FailAllocMessage(); } PolyPtr->vlist = vs; PolyPtr->smooth = smooth; if (before) { for (i = n-1; i >= Index; i--) { vs[i+1] = vs[i]; if (smooth != NULL) smooth[i+1] = smooth[i]; } if (ObjPtr->ctm == NULL) { vs[Index].x = x + ABS_SIZE(grid_x-orig_x); vs[Index].y = y + ABS_SIZE(grid_y-orig_y); } else { vs[Index].x = tx + ABS_SIZE(grid_x-orig_x); vs[Index].y = ty + ABS_SIZE(grid_y-orig_y); ReverseTransformPointThroughCTM(vs[Index].x-ObjPtr->x, vs[Index].y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); vs[Index].x = ObjPtr->x+tmp_x; vs[Index].y = ObjPtr->y+tmp_y; } if (smooth != NULL) smooth[Index] = smooth[Index+1]; } else { for (i = n-1; i > Index; i--) { vs[i+1] = vs[i]; if (smooth != NULL) smooth[i+1] = smooth[i]; } if (ObjPtr->ctm == NULL) { vs[Index+1].x = x + ABS_SIZE(grid_x-orig_x); vs[Index+1].y = y + ABS_SIZE(grid_y-orig_y); } else { vs[Index+1].x = tx + ABS_SIZE(grid_x-orig_x); vs[Index+1].y = ty + ABS_SIZE(grid_y-orig_y); ReverseTransformPointThroughCTM(vs[Index+1].x-ObjPtr->x, vs[Index+1].y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); vs[Index+1].x = ObjPtr->x+tmp_x; vs[Index+1].y = ObjPtr->y+tmp_y; } if (smooth != NULL) smooth[Index+1] = smooth[Index]; } if (sv != NULL) { free(sv); sv = NULL; } if (pv != NULL) { free(pv); pv = NULL; } if (tmp_smooth != NULL) free(tmp_smooth); if (curved == LT_INTSPLINE && cntrlv != NULL) free(cntrlv); PolyPtr->n++; n++; AdjObjSplineVs(ObjPtr); if (curved != LT_INTSPLINE) { UpdPolyBBox(ObjPtr, PolyPtr->n, PolyPtr->vlist); } else { UpdPolyBBox(ObjPtr, PolyPtr->intn, PolyPtr->intvlist); } AdjObjBBox(ObjPtr); UpdSelBBox(); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { done = TRUE; *LastMouseX = new_mouse_x; *LastMouseY = new_mouse_y; if (curved == LT_INTSPLINE || smooth == NULL || !smooth[Index]) { MARK(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } else { MARKO(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } if (already_moved) { AddPointMeasureCursor(ADDPOINT_ENDSHOW, abs(ABS_X(v[1].x)-tx), abs(ABS_Y(v[1].y)-ty), ABS_X(v[1].x), ABS_Y(v[1].y)); } else { AddPointMeasureCursor(ADDPOINT_STARTSHOW, 0, 0, tx, ty); } if (already_moved) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); if (grid_x == orig_x && grid_y == orig_y) { return FALSE; } } return FALSE; } } } return TRUE; } static int ContinueAddPolygonPoint(ObjPtr, MouseX, MouseY, Index, PolygonPtr, LastMouseX, LastMouseY) struct ObjRec *ObjPtr; int MouseX, MouseY, Index; struct PolygonRec *PolygonPtr; int *LastMouseX, *LastMouseY; /* * (MouseX,MouseY) is the mouse's origin in screen offsets * * This routine is only called for LT_STRAIGHT, LT_SPLINE, or LT_INTSPLINE. */ { int n=PolygonPtr->n, sn=0, curved=PolygonPtr->curved; int already_moved=FALSE, done=FALSE, before=FALSE; XPoint v[3], *sv=NULL; IntPoint *vs=PolygonPtr->vlist, *pv=NULL, *cntrlv=NULL; int prev_x, prev_y, prev_tx, prev_ty, x, y, tx, ty, tmp_x, tmp_y; int next_x, next_y, next_tx, next_ty; int orig_x, orig_y, grid_x, grid_y, new_mouse_x, new_mouse_y; int sel_ltx, sel_lty, sel_rbx, sel_rby, i, intn=0; char *smooth=PolygonPtr->smooth, *tmp_smooth=NULL; double prev_angle, next_angle, prev_dist, next_dist, dx, dy; memset(v, 0, sizeof(XPoint)*3); #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(curved != LT_STRUCT_SPLINE, "curved == LT_STRUCT_SPLINE in ContinueAddPolygonPoint()", NULL); #endif /* _TGIF_DBG */ sel_ltx = selLtX; sel_lty = selLtY; sel_rbx = selRbX; sel_rby = selRbY; x = tx = vs[Index].x; y = ty = vs[Index].y; if (ObjPtr->ctm != NULL) { TransformPointThroughCTM(x-ObjPtr->x, y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); tx = ObjPtr->x+tmp_x; ty = ObjPtr->y+tmp_y; } if (curved == LT_INTSPLINE || smooth == NULL || !smooth[Index]) { MARK(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } else { MARKO(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } if (Index == 0 || Index == n-1) { next_x = next_tx = vs[1].x; next_y = next_ty = vs[1].y; prev_x = prev_tx = vs[n-2].x; prev_y = prev_ty = vs[n-2].y; } else { prev_x = prev_tx = vs[Index-1].x; prev_y = prev_ty = vs[Index-1].y; next_x = next_tx = vs[Index+1].x; next_y = next_ty = vs[Index+1].y; } if (ObjPtr->ctm != NULL) { TransformPointThroughCTM(next_x-ObjPtr->x, next_y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); next_tx = ObjPtr->x+tmp_x; next_ty = ObjPtr->y+tmp_y; TransformPointThroughCTM(prev_x-ObjPtr->x, prev_y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); prev_tx = ObjPtr->x+tmp_x; prev_ty = ObjPtr->y+tmp_y; } dx = (double)(prev_tx - tx); dy = (double)(prev_ty - ty); prev_dist = dx*dx+dy*dy; dx = (double)(next_tx - tx); dy = (double)(next_ty - ty); next_dist = dx*dx+dy*dy; prev_angle = (prev_tx==tx) ? ((prev_ty>=ty) ? M_PI/2.0 : -M_PI/2.0) : atan2((double)(prev_ty-ty), (double)(prev_tx-tx)); next_angle = (next_tx==tx) ? ((next_ty>=ty) ? M_PI/2.0 : -M_PI/2.0) : atan2((double)(next_ty-ty), (double)(next_tx-tx)); pv = (IntPoint *)malloc((n+2)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); if (curved != LT_INTSPLINE && smooth != NULL) { tmp_smooth = (char*)malloc((n+2)*sizeof(char)); if (tmp_smooth == NULL) FailAllocMessage(); } if (ObjPtr->ctm == NULL) { for (i = 0; i <= Index; i++) { pv[i].x = vs[i].x; pv[i].y = vs[i].y; if (tmp_smooth != NULL) tmp_smooth[i] = smooth[i]; } for (i = Index; i < n; i++) { pv[i+1].x = vs[i].x; pv[i+1].y = vs[i].y; if (tmp_smooth != NULL) tmp_smooth[i+1] = smooth[i]; } } else { for (i = 0; i <= Index; i++) { TransformPointThroughCTM(vs[i].x-ObjPtr->x, vs[i].y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); pv[i].x = ObjPtr->x+tmp_x; pv[i].y = ObjPtr->y+tmp_y; if (tmp_smooth != NULL) tmp_smooth[i] = smooth[i]; } for (i = Index; i < n; i++) { TransformPointThroughCTM(vs[i].x-ObjPtr->x, vs[i].y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); pv[i+1].x = ObjPtr->x+tmp_x; pv[i+1].y = ObjPtr->y+tmp_y; if (tmp_smooth != NULL) tmp_smooth[i+1] = smooth[i]; } } GridXY(MouseX, MouseY, &orig_x, &orig_y); grid_x = orig_x; grid_y = orig_y; new_mouse_x = MouseX; new_mouse_y = MouseY; AddPointMeasureCursor(ADDPOINT_STARTSHOW, 0, 0, tx, ty); while (!done) { double new_angle, theta_1, theta_2; XEvent input, ev; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == MotionNotify || input.type == KeyPress || input.type == KeyRelease) { int new_x, new_y; if (input.type == KeyPress || input.type == KeyRelease) { new_mouse_x = grid_x; new_mouse_y = grid_y; } else { new_mouse_x = input.xmotion.x; new_mouse_y = input.xmotion.y; } if (shiftForDiagMouseMove && DiagEventCheck(&input)) { if (input.type == KeyRelease) { new_mouse_x = input.xkey.x; new_mouse_y = input.xkey.y; } else { DiagGridXY(orig_x, orig_y, &new_mouse_x, &new_mouse_y); } } GridXY(new_mouse_x, new_mouse_y, &grid_x, &grid_y); new_x = ABS_SIZE(new_mouse_x-MouseX) + tx; new_y = ABS_SIZE(new_mouse_y-MouseY) + ty; if (!already_moved) { double new_prev_dist, new_next_dist; already_moved = TRUE; dx = (double)(prev_tx - new_mouse_x); dy = (double)(prev_ty - new_mouse_y); new_prev_dist = dx*dx+dy*dy; dx = (double)(next_tx - new_mouse_x); dy = (double)(next_ty - new_mouse_y); new_next_dist = dx*dx+dy*dy; before = DetermineBefore(prev_dist, next_dist, new_prev_dist, new_next_dist); if (before == INVALID) { new_angle = (new_x==tx) ? ((new_y>=ty) ? M_PI/2.0 : -M_PI/2.0) : atan2((double)(new_y-ty), (double)(new_x-tx)); theta_1 = fabs(prev_angle - new_angle); theta_2 = fabs(next_angle - new_angle); if (theta_1 > M_PI) theta_1 = 2*M_PI-theta_1; if (theta_2 > M_PI) theta_2 = 2*M_PI-theta_2; before = (theta_1 <= theta_2); } if (before) { /* Add a point between the current and the previous point */ v[0].x = OFFSET_X(prev_tx); v[0].y = OFFSET_Y(prev_ty); v[1].x = OFFSET_X(tx); v[1].y = OFFSET_Y(ty); v[2].x = OFFSET_X(tx); v[2].y = OFFSET_Y(ty); } else { /* Add a point between the current and the next point */ v[0].x = OFFSET_X(tx); v[0].y = OFFSET_Y(ty); v[1].x = OFFSET_X(tx); v[1].y = OFFSET_Y(ty); v[2].x = OFFSET_X(next_tx); v[2].y = OFFSET_Y(next_ty); } switch (curved) { case LT_STRAIGHT: case LT_SPLINE: sv = MakeMultiSplinePolygonVertex(curved, &sn, tmp_smooth, drawOrigX, drawOrigY, n+1, pv); break; case LT_INTSPLINE: sv = MakeIntSplinePolygonVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n+1, pv); break; case LT_STRUCT_SPLINE: /* should never get here */ break; } XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); } else { AddPointMeasureCursor(ADDPOINT_DOSHOW, abs(ABS_X(v[1].x)-tx), abs(ABS_Y(v[1].y)-ty), ABS_X(v[1].x), ABS_Y(v[1].y)); XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); v[1].x = OFFSET_X(tx) + grid_x - orig_x; v[1].y = OFFSET_Y(ty) + grid_y - orig_y; if (sv != NULL) { free(sv); sv = NULL; } if (before) { pv[Index].x = tx + ABS_SIZE(grid_x-orig_x); pv[Index].y = ty + ABS_SIZE(grid_y-orig_y); if (Index == 0) { pv[n].x = tx + ABS_SIZE(grid_x-orig_x); pv[n].y = ty + ABS_SIZE(grid_y-orig_y); } } else { pv[Index+1].x = tx + ABS_SIZE(grid_x-orig_x); pv[Index+1].y = ty + ABS_SIZE(grid_y-orig_y); if (Index == n-1) { pv[0].x = tx + ABS_SIZE(grid_x-orig_x); pv[0].y = ty + ABS_SIZE(grid_y-orig_y); } } switch (curved) { case LT_STRAIGHT: case LT_SPLINE: sv = MakeMultiSplinePolygonVertex(curved, &sn, tmp_smooth, drawOrigX, drawOrigY, n+1, pv); break; case LT_INTSPLINE: free(cntrlv); sv = MakeIntSplinePolygonVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n+1, pv); break; case LT_STRUCT_SPLINE: /* should never get here */ break; } XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); MarkRulers(v[1].x, v[1].y); AddPointMeasureCursor(ADDPOINT_DOSHOW, abs(ABS_X(v[1].x)-tx), abs(ABS_Y(v[1].y)-ty), ABS_X(v[1].x), ABS_Y(v[1].y)); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } else if (input.type == ButtonRelease) { done = TRUE; *LastMouseX = new_mouse_x; *LastMouseY = new_mouse_y; if (curved == LT_INTSPLINE || smooth == NULL || !smooth[Index]) { MARK(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } else { MARKO(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } if (already_moved) { AddPointMeasureCursor(ADDPOINT_ENDSHOW, abs(ABS_X(v[1].x)-tx), abs(ABS_Y(v[1].y)-ty), ABS_X(v[1].x), ABS_Y(v[1].y)); } else { AddPointMeasureCursor(ADDPOINT_STARTSHOW, 0, 0, tx, ty); } if (!already_moved) { return FALSE; } else { XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); if (grid_x == orig_x && grid_y == orig_y) { return FALSE; } } HighLightReverse(); vs = (IntPoint*)realloc(vs, (n+2)*sizeof(IntPoint)); if (vs == NULL) return FailAllocMessage(); if (smooth != NULL) { smooth = (char*)realloc(smooth, (n+2)*sizeof(char)); if (smooth == NULL) return FailAllocMessage(); } PolygonPtr->vlist = vs; PolygonPtr->smooth = smooth; if (Index == 0 || Index == n-1) { if (before) { vs[n].x = vs[n-1].x; vs[n].y = vs[n-1].y; if (ObjPtr->ctm == NULL) { vs[n-1].x = x + ABS_SIZE(grid_x-orig_x); vs[n-1].y = y + ABS_SIZE(grid_y-orig_y); } else { vs[n-1].x = tx + ABS_SIZE(grid_x-orig_x); vs[n-1].y = ty + ABS_SIZE(grid_y-orig_y); ReverseTransformPointThroughCTM(vs[n-1].x-ObjPtr->x, vs[n-1].y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); vs[n-1].x = ObjPtr->x+tmp_x; vs[n-1].y = ObjPtr->y+tmp_y; } if (smooth != NULL) smooth[n] = smooth[n-1]; } else { for (i = n-1; i > 0; i--) { vs[i+1].x = vs[i].x; vs[i+1].y = vs[i].y; if (smooth != NULL) smooth[i+1] = smooth[i]; } if (ObjPtr->ctm == NULL) { vs[1].x = x + ABS_SIZE(grid_x-orig_x); vs[1].y = y + ABS_SIZE(grid_y-orig_y); } else { vs[1].x = tx + ABS_SIZE(grid_x-orig_x); vs[1].y = ty + ABS_SIZE(grid_y-orig_y); ReverseTransformPointThroughCTM(vs[1].x-ObjPtr->x, vs[1].y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); vs[1].x = ObjPtr->x+tmp_x; vs[1].y = ObjPtr->y+tmp_y; } if (smooth != NULL) smooth[1] = smooth[0]; } } else { if (before) { for (i = n-1; i >= Index; i--) { vs[i+1].x = vs[i].x; vs[i+1].y = vs[i].y; if (smooth != NULL) smooth[i+1] = smooth[i]; } if (ObjPtr->ctm == NULL) { vs[Index].x = x + ABS_SIZE(grid_x-orig_x); vs[Index].y = y + ABS_SIZE(grid_y-orig_y); } else { vs[Index].x = tx + ABS_SIZE(grid_x-orig_x); vs[Index].y = ty + ABS_SIZE(grid_y-orig_y); ReverseTransformPointThroughCTM(vs[Index].x-ObjPtr->x, vs[Index].y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); vs[Index].x = ObjPtr->x+tmp_x; vs[Index].y = ObjPtr->y+tmp_y; } if (smooth != NULL) smooth[Index] = smooth[Index+1]; } else { for (i = n-1; i > Index; i--) { vs[i+1].x = vs[i].x; vs[i+1].y = vs[i].y; if (smooth != NULL) smooth[i+1] = smooth[i]; } if (ObjPtr->ctm == NULL) { vs[Index+1].x = x + ABS_SIZE(grid_x-orig_x); vs[Index+1].y = y + ABS_SIZE(grid_y-orig_y); } else { vs[Index+1].x = tx + ABS_SIZE(grid_x-orig_x); vs[Index+1].y = ty + ABS_SIZE(grid_y-orig_y); ReverseTransformPointThroughCTM(vs[Index+1].x-ObjPtr->x, vs[Index+1].y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); vs[Index+1].x = ObjPtr->x+tmp_x; vs[Index+1].y = ObjPtr->y+tmp_y; } if (smooth != NULL) smooth[Index+1] = smooth[Index]; } } if (sv != NULL) { free(sv); sv = NULL; } if (pv != NULL) { free(pv); pv = NULL; } if (tmp_smooth != NULL) { free(tmp_smooth); tmp_smooth = NULL; } if (curved == LT_INTSPLINE && cntrlv != NULL) { free(cntrlv); cntrlv = NULL; } PolygonPtr->n++; n++; AdjObjSplineVs(ObjPtr); if (curved != LT_INTSPLINE) { UpdPolyBBox(ObjPtr, PolygonPtr->n, PolygonPtr->vlist); } else { UpdPolyBBox(ObjPtr, PolygonPtr->intn, PolygonPtr->intvlist); } AdjObjBBox(ObjPtr); UpdSelBBox(); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { done = TRUE; *LastMouseX = new_mouse_x; *LastMouseY = new_mouse_y; if (curved == LT_INTSPLINE || smooth == NULL || !smooth[Index]) { MARK(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } else { MARKO(drawWindow, revDefaultGC, OFFSET_X(tx), OFFSET_Y(ty)); } if (already_moved) { AddPointMeasureCursor(ADDPOINT_ENDSHOW, abs(ABS_X(v[1].x)-tx), abs(ABS_Y(v[1].y)-ty), ABS_X(v[1].x), ABS_Y(v[1].y)); } else { AddPointMeasureCursor(ADDPOINT_STARTSHOW, 0, 0, tx, ty); } if (already_moved) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); if (grid_x == orig_x && grid_y == orig_y) { return FALSE; } } return FALSE; } } } return TRUE; } void AddPoint() { int adding=TRUE, pt_added=FALSE, root_x=0, root_y=0, old_x=0, old_y=0; int curved=(-1); struct ObjRec *obj_ptr; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; unsigned int status=0; Window root_win=None, child_win=None; if (!(topSel != NULL && topSel == botSel && (topSel->obj->type == OBJ_POLY || topSel->obj->type == OBJ_POLYGON))) { MsgBox(TgLoadString(STID_SELECT_ONLY_ONE_POLY_POLYGON), TOOL_NAME, INFO_MB); return; } else if (topSel->obj->locked) { MsgBox(TgLoadString(STID_CANNOT_ADD_PT_FOR_LOCKED), TOOL_NAME, INFO_MB); return; } else if (AutoRetractedArrowAttr(topSel->obj, TRUE)) { MsgBox(TgLoadString(STID_CANNOT_ADD_PT_FOR_AUTO_ARROW), TOOL_NAME, INFO_MB); return; } if (curChoice == VERTEXMODE) { HighLightReverse(); JustRemoveAllVSel(); HighLightForward(); } PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); obj_ptr = topSel->obj; switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; curved = poly_ptr->curved; break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; curved = polygon_ptr->curved; break; } SaveStatusStrings(); if (curved == LT_STRUCT_SPLINE) { SetMouseStatus(TgLoadString(STID_ADD_HINGE_VERTEX), TgLoadString(STID_ADD_A_SMOOTH_VERTEX), TgLoadCachedString(CSTID_FINISH)); TwoLineMsg(TgLoadString(STID_LEFT_ADD_HINGE_MID_ADD_SMOOTH), TgLoadString(STID_CLICK_RIGHT_BUTTON_TO_QUIT)); } else { SetMouseStatus(TgLoadCachedString(CSTID_ADD_A_VERTEX), TgLoadCachedString(CSTID_FINISH), TgLoadCachedString(CSTID_FINISH)); TwoLineMsg(TgLoadString(STID_LEFT_BTN_TO_ADD_PTS), TgLoadString(STID_CLICK_OTHER_BUTTON_TO_QUIT)); } if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonPressMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, defaultCursor, CurrentTime); } XQueryPointer(mainDisplay, drawWindow, &root_win, &child_win, &root_x, &root_y, &old_x, &old_y, &status); XSetFont(mainDisplay, revDefaultGC, defaultFontPtr->fid); /* do not translate -- program constants */ XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "ADD", 3); MarkRulers(old_x, old_y); while (adding) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonPress) { int index=0; /* erase */ XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "ADD", 3); if (curved == LT_STRUCT_SPLINE) { if (input.xbutton.button == Button1 || input.xbutton.button == Button2) { if (obj_ptr->type == OBJ_POLY && PtInPolyMark(obj_ptr, input.xbutton.x, input.xbutton.y, poly_ptr->ssn, poly_ptr->ssvlist, &index)) { if (ContinueAddStructuredPolyOrPolygonPoint(obj_ptr, input.xbutton.button, input.xbutton.x, input.xbutton.y, index, poly_ptr, NULL, &old_x, &old_y)) { pt_added = TRUE; } } else if (obj_ptr->type == OBJ_POLYGON && PtInPolyMark(obj_ptr, input.xbutton.x, input.xbutton.y, polygon_ptr->ssn-1, polygon_ptr->ssvlist, &index)) { if (ContinueAddStructuredPolyOrPolygonPoint(obj_ptr, input.xbutton.button, input.xbutton.x, input.xbutton.y, index, NULL, polygon_ptr, &old_x, &old_y)) { pt_added = TRUE; } } XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "ADD", 3); } else { XUngrabPointer(mainDisplay, CurrentTime); Msg(""); adding = FALSE; } } else if (input.xbutton.button == Button1) { if (obj_ptr->type == OBJ_POLY && PtInPolyMark(obj_ptr, input.xbutton.x, input.xbutton.y, poly_ptr->n, poly_ptr->vlist, &index)) { if (ContinueAddPolyPoint(obj_ptr, input.xbutton.x, input.xbutton.y, index, poly_ptr, &old_x, &old_y)) { pt_added = TRUE; } } else if (obj_ptr->type == OBJ_POLYGON && PtInPolyMark(obj_ptr, input.xbutton.x, input.xbutton.y, polygon_ptr->n-1, polygon_ptr->vlist, &index)) { if (ContinueAddPolygonPoint(obj_ptr, input.xbutton.x, input.xbutton.y, index, polygon_ptr, &old_x, &old_y)) { pt_added = TRUE; } } XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "ADD", 3); } else { XUngrabPointer(mainDisplay, CurrentTime); Msg(""); adding = FALSE; } } else if (input.type == MotionNotify) { XEvent ev; /* erase */ XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "ADD", 3); old_x = input.xmotion.x; old_y = input.xmotion.y; /* draw */ XDrawString(mainDisplay, drawWindow, revDefaultGC, old_x+4, old_y+defaultFontAsc, "ADD", 3); MarkRulers(old_x, old_y); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } RestoreStatusStrings(); if (pt_added) { RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); } else { AbortPrepareCmd(CMD_REPLACE); } } void FlushUndoBuffer() { CleanUpMsg(); CleanUpCmds(); if (FlushColormap()) { Msg(TgLoadString(STID_UNDO_BUF_AND_CMAP_FLUSHED)); sprintf(gszMsgBox, TgLoadString(STID_NUM_COLORS_ALLOCATED), maxColors); Msg(gszMsgBox); } else { Msg(TgLoadString(STID_UNDO_BUF_FLUSHED)); } } void RestoreImageWH() { struct XBmRec *xbm_ptr=NULL; struct XPmRec *xpm_ptr=NULL; int w, h, image_w=0, image_h=0; int ltx, lty, rbx, rby; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } else if (topSel != botSel || (!(topSel->obj->type==OBJ_XBM || topSel->obj->type==OBJ_XPM))) { MsgBox(TgLoadString(STID_SEL_ONE_XBM_OR_XPM_TO_RESTORE), TOOL_NAME, INFO_MB); return; } else if (topSel->obj->locked) { MsgBox(TgLoadString(STID_CANNOT_RESTORE_LOCKED), TOOL_NAME, INFO_MB); return; } w = topSel->obj->obbox.rbx - topSel->obj->obbox.ltx; h = topSel->obj->obbox.rby - topSel->obj->obbox.lty; switch (topSel->obj->type) { case OBJ_XBM: xbm_ptr = topSel->obj->detail.xbm; if (xbm_ptr->real_type==XBM_EPS && xbm_ptr->bitmap==None) { image_w = xbm_ptr->eps_w; image_h = xbm_ptr->eps_h; } else { image_w = xbm_ptr->image_w; image_h = xbm_ptr->image_h; } if (w == image_w && h == image_h) return; break; case OBJ_XPM: xpm_ptr = topSel->obj->detail.xpm; image_w = xpm_ptr->image_w; image_h = xpm_ptr->image_h; if (w == image_w && h == image_h) return; break; } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); PrepareToReplaceAnObj(topSel->obj); if (topSel->obj->ctm == NULL) { topSel->obj->obbox.rbx = topSel->obj->obbox.ltx+image_w; topSel->obj->obbox.rby = topSel->obj->obbox.lty+image_h; } else { topSel->obj->obbox.rbx = topSel->obj->obbox.ltx+image_w; topSel->obj->obbox.rby = topSel->obj->obbox.lty+image_h; free(topSel->obj->ctm); topSel->obj->ctm = NULL; } topSel->obj->x = topSel->obj->obbox.ltx; topSel->obj->y = topSel->obj->obbox.lty; switch (topSel->obj->type) { case OBJ_XBM: if (xbm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xbm_ptr->cached_bitmap); } xbm_ptr->cached_bitmap = None; xbm_ptr->cached_zoom = 0; break; case OBJ_XPM: if (xpm_ptr->cached_pixmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_pixmap); } xpm_ptr->cached_pixmap = None; if (xpm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_bitmap); } xpm_ptr->cached_bitmap = None; if (xpm_ptr->clip_mask != None) { XFreePixmap(mainDisplay, xpm_ptr->clip_mask); } xpm_ptr->clip_mask = None; xpm_ptr->cached_zoom = 0; xpm_ptr->cached_color = (-1); break; } AdjObjBBox(topSel->obj); RecordReplaceAnObj(topSel->obj); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } void CutMaps() { if (topSel == NULL || topSel != botSel) { MsgBox(TgLoadString(STID_SEL_ONE_XBM_OR_XPM_TO_CUT), TOOL_NAME, INFO_MB); return; } else if (topSel->obj->locked) { MsgBox(TgLoadString(STID_CANNOT_CUT_LOCKED), TOOL_NAME, INFO_MB); return; } else if (topSel->obj->ctm != NULL) { MsgBox(TgLoadString(STID_CANNOT_CUT_TRANSFORMED_X_OBJ), TOOL_NAME, INFO_MB); return; } switch (topSel->obj->type) { case OBJ_XBM: CutXBitmap(); break; case OBJ_XPM: CutXPixmap(NULL, NULL, NULL, NULL, NULL); break; default: MsgBox(TgLoadString(STID_SEL_ONE_XBM_OR_XPM_TO_CUT), TOOL_NAME, INFO_MB); break; } } void BreakUpMaps() { int cols=0, rows=0, cols_and_rows=TRUE, ok=TRUE, image_w=0, image_h=0; char spec[MAXSTRING+1], *dup_spec=NULL, *part1=NULL, *part2=NULL; struct ObjRec *obj_ptr=NULL; if (topSel == NULL || topSel != botSel || (topSel->obj->type != OBJ_XBM && topSel->obj->type != OBJ_XPM)) { MsgBox(TgLoadString(STID_SEL_ONE_XBM_OR_XPM_TO_BREAKUP), TOOL_NAME, INFO_MB); return; } else if (topSel->obj->ctm != NULL) { MsgBox(TgLoadString(STID_CANNOT_BREAK_XFORMED_X_OBJ), TOOL_NAME, INFO_MB); return; } else if (topSel->obj->locked) { MsgBox(TgLoadString(STID_CANNOT_BREAKUP_LOCKED), TOOL_NAME, INFO_MB); return; } obj_ptr = topSel->obj; switch (obj_ptr->type) { case OBJ_XBM: image_w=obj_ptr->detail.xbm->image_w; image_h=obj_ptr->detail.xbm->image_h; break; case OBJ_XPM: image_w=obj_ptr->detail.xpm->image_w; image_h=obj_ptr->detail.xpm->image_h; break; default: return; } sprintf(gszMsgBox, TgLoadString(STID_ENTER_NUM_ROWCOL_TO_BREAK), image_w, image_h); *spec = '\0'; if (Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), spec) == INVALID) { return; } UtilTrimBlanks(spec); if (*spec == '\0') return; if ((dup_spec=UtilStrDup(spec)) == NULL) { FailAllocMessage(); return; } if (*dup_spec == '=') cols_and_rows = FALSE; /* do not translate -- program constants */ if ((part1=strtok(dup_spec, " ,xX=[]")) != NULL && (part2=strtok(NULL, " ,xX=[]")) != NULL) { cols = atoi(part1); rows = atoi(part2); if (cols > 0 && rows > 0) { switch (obj_ptr->type) { case OBJ_XBM: BreakUpXBitmap(obj_ptr, cols_and_rows, cols, rows); break; case OBJ_XPM: BreakUpXPixmap(obj_ptr, cols_and_rows, cols, rows); break; } } else { ok = FALSE; } } else { ok = FALSE; } if (!ok) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_ROWCOL_SPEC_REENTER), dup_spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } free(dup_spec); } /* ----------------------- RemoveTransparentPixel ----------------------- */ static int ReproducePixmap(pixel_to_use, orig_pixmap, orig_image, orig_bitmap, orig_bitmap_image, w, h, pixmap_return, image_return, bitmap_return, bitmap_image_return) int pixel_to_use, w, h; Pixmap orig_pixmap, orig_bitmap, *pixmap_return, *bitmap_return; XImage *orig_image, *orig_bitmap_image, **image_return, **bitmap_image_return; { int i=0; XImage *src_image=NULL, *src_bitmap_image=NULL; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); *pixmap_return = XCreatePixmap(mainDisplay, mainWindow, w, h, mainDepth); *bitmap_return = XCreatePixmap(mainDisplay, mainWindow, w, h, 1); XFillRectangle(mainDisplay, *pixmap_return, xpmGC, 0, 0, w, h); XSetForeground(mainDisplay, xbmGC, 1); XFillRectangle(mainDisplay, *bitmap_return, xbmGC, 0, 0, w, h); XSetForeground(mainDisplay, xbmGC, 0); *image_return = (*pixmap_return==None ? NULL : XGetImage(mainDisplay, *pixmap_return, 0, 0, w, h, AllPlanes, ZPixmap)); *bitmap_image_return = (*bitmap_return==None ? NULL : XGetImage(mainDisplay, *bitmap_return, 0, 0, w, h, 1, ZPixmap)); if (orig_image != NULL) { src_image = orig_image; } else { src_image = XGetImage(mainDisplay, orig_pixmap, 0, 0, w, h, AllPlanes, ZPixmap); } if (orig_bitmap_image != NULL) { src_bitmap_image = orig_bitmap_image; } else { src_bitmap_image = XGetImage(mainDisplay, orig_bitmap, 0, 0, w, h, 1, ZPixmap); } if (*pixmap_return == None || *bitmap_return == None || *image_return==NULL || *bitmap_image_return==NULL || src_image==NULL || src_bitmap_image==NULL) { if (*pixmap_return == None) { FailAllocPixmapMessage(w, h); } else if (*bitmap_return == None) { FailAllocBitmapMessage(w, h); } else { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); } if (*pixmap_return != None) XFreePixmap(mainDisplay, *pixmap_return); if (*bitmap_return != None) XFreePixmap(mainDisplay, *bitmap_return); if (*image_return != NULL) XDestroyImage(*image_return); if (*bitmap_image_return != NULL) XDestroyImage(*bitmap_image_return); if (orig_image != NULL) XDestroyImage(src_image); if (orig_bitmap_image != NULL) XDestroyImage(src_bitmap_image); if (orig_image == NULL && src_image != NULL) XDestroyImage(src_image); if (orig_bitmap_image == NULL && src_bitmap_image != NULL) XDestroyImage(src_bitmap_image); *pixmap_return = *bitmap_return = None; *image_return = *bitmap_image_return = NULL; SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); return FALSE; } for (i=0; i < h; i++) { int j=0; for (j=0; j < w; j++) { if (src_bitmap_image == NULL) { XPutPixel(*image_return, j, i, XGetPixel(src_image, j, i)); } else { if (XGetPixel(src_bitmap_image, j, i) != 0) { XPutPixel(*image_return, j, i, XGetPixel(src_image, j, i)); } else { XPutPixel(*image_return, j, i, pixel_to_use); } } } } XPutImage(mainDisplay, *pixmap_return, xpmGC, *image_return, 0, 0, 0, 0, w, h); XPutImage(mainDisplay, *bitmap_return, xbmGC, *bitmap_image_return, 0, 0, 0, 0, w, h); SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); if (orig_image == NULL && src_image != NULL) XDestroyImage(src_image); if (orig_bitmap_image == NULL && src_bitmap_image != NULL) XDestroyImage(src_bitmap_image); return TRUE; } static int RemoveObjTransPixel(obj_ptr, ptci) struct ObjRec *obj_ptr; TrueColorInfo *ptci; { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; Pixmap dest_pixmap=None, dest_bitmap=None; XImage *dest_image=NULL, *dest_bitmap_image=NULL; int index=(-1); unsigned char trans_color_r='\0', trans_color_g='\0', trans_color_b='\0'; switch (xpm_ptr->real_type) { case XPM_XPM: if (ObjHasIndexedTransPixel(obj_ptr, &index)) { xpm_ptr->pixels[index] = colorPixels[colorIndex]; UtilFree(xpm_ptr->color_str[index]); xpm_ptr->color_str[index] = UtilStrDup(colorMenuItems[colorIndex]); if (xpm_ptr->color_str[index] == NULL) FailAllocMessage(); if (!ReproducePixmap(colorPixels[colorIndex], xpm_ptr->pixmap, xpm_ptr->image, xpm_ptr->bitmap, xpm_ptr->bitmap_image, xpm_ptr->image_w, xpm_ptr->image_h, &dest_pixmap, &dest_image, &dest_bitmap, &dest_bitmap_image)) { return FALSE; } xpm_ptr->pixmap = dest_pixmap; xpm_ptr->image = dest_image; xpm_ptr->bitmap = dest_bitmap; xpm_ptr->bitmap_image = dest_bitmap_image; return TRUE; } break; case XPM_JPEG: break; case PPM_TRUE: if (ObjHasTrueColorTransPixel(obj_ptr, &trans_color_r, &trans_color_g, &trans_color_b)) { unsigned int r=(unsigned int)trans_color_r; unsigned int g=(unsigned int)trans_color_g; unsigned int b=(unsigned int)trans_color_b; int pixel_to_use=((r << ptci->r_shift) & mainVisual->red_mask) | ((g << ptci->g_shift) & mainVisual->green_mask) | ((b << ptci->b_shift) & mainVisual->blue_mask) ; if (!ReproducePixmap(pixel_to_use, xpm_ptr->pixmap, xpm_ptr->image, xpm_ptr->bitmap, xpm_ptr->bitmap_image, xpm_ptr->image_w, xpm_ptr->image_h, &dest_pixmap, &dest_image, &dest_bitmap, &dest_bitmap_image)) { return FALSE; } xpm_ptr->pixmap = dest_pixmap; xpm_ptr->image = dest_image; xpm_ptr->bitmap = dest_bitmap; xpm_ptr->bitmap_image = dest_bitmap_image; xpm_ptr->has_transparent_color = FALSE; xpm_ptr->transparent_color[0] = (unsigned char)0; xpm_ptr->transparent_color[1] = (unsigned char)0; xpm_ptr->transparent_color[2] = (unsigned char)0; return TRUE; } break; } /* no change */ return FALSE; } void RemoveTransparentPixel() { struct ObjRec *obj_ptr=NULL; struct SelRec *sel_ptr=NULL, *tmp_top_sel=NULL, *tmp_bot_sel=NULL; int count=0, ltx=0, lty=0, rbx=0, rby=0; TrueColorInfo tci; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; if (obj_ptr->type == OBJ_XPM && ObjHasTransPixel(obj_ptr)) { AddObjIntoSel(obj_ptr, tmp_bot_sel, NULL, &tmp_top_sel, &tmp_bot_sel); count++; } } if (count == 0) { MsgBox(TgLoadString(STID_SEL_ONE_XPM_TRANSPIX), TOOL_NAME, INFO_MB); return; } if (fullTrueColorMode && !SetupTrueColorInfo(&tci)) return; HighLightReverse(); RemoveAllSel(); topSel = tmp_top_sel; botSel = tmp_bot_sel; tmp_top_sel = tmp_bot_sel = NULL; ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; StartCompositeCmd(); for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; PrepareToReplaceAnObj(obj_ptr); if (RemoveObjTransPixel(obj_ptr, &tci)) { RecordReplaceAnObj(obj_ptr); AdjObjCache(obj_ptr); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); UpdSelBBox(); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } /* ----------------------- LayoutOnArc ----------------------- */ typedef struct BoxInfoRec { struct ObjRec *obj; int w, h; int valid_v; double half_w, angle_in_radian, angle_to_rotate; XPoint v[5]; } *BoxInfoPtr; #define LAYOUT_DIR_NONE 0 #define LAYOUT_DIR_S 1 /* convex */ #define LAYOUT_DIR_N 2 /* concave */ int gnLayoutDirection=LAYOUT_DIR_NONE; static void RotateXY(x, y, angle_in_radian, new_x, new_y) int x, y; double angle_in_radian; short *new_x, *new_y; { if (x == 0 && y == 0) { *new_x = 0; *new_y = 0; } else { double sin_val = sin(angle_in_radian); double cos_val = cos(angle_in_radian); *new_x = (short)round(x*cos_val - y*sin_val); *new_y = (short)round(x*sin_val + y*cos_val); } } static void RotateBBoxByRadian(bbox, angle_in_radian, v) struct BBRec *bbox; double angle_in_radian; XPoint *v; /* array of 5 points */ { RotateXY(bbox->ltx, bbox->lty, angle_in_radian, &(v[0].x), &(v[0].y)); RotateXY(bbox->rbx, bbox->lty, angle_in_radian, &(v[1].x), &(v[1].y)); RotateXY(bbox->rbx, bbox->rby, angle_in_radian, &(v[2].x), &(v[2].y)); RotateXY(bbox->ltx, bbox->rby, angle_in_radian, &(v[3].x), &(v[3].y)); v[4].x = v[0].x; v[4].y = v[0].y; } #define SET_LAYOUT_VS (FALSE) #define FINALIZE_LAYOUT (TRUE) static int HighLightOrFinalLayout(arc_ptr, box_info_ptr, grid_x, grid_y, finalize) struct ArcRec *arc_ptr; struct BoxInfoRec *box_info_ptr; int grid_x, grid_y, finalize; { int i, num_objects=numObjSelected-1, circular=FALSE; int abs_cx, abs_cy, abs_x=ABS_X(grid_x), abs_y=ABS_Y(grid_y), dx, dy; double abs_radius, total_arc_radian, total_radian=0, inc_radian=0, angle; if (abs(arc_ptr->angle2) == (360<<6)) { circular = TRUE; } abs_cx = arc_ptr->xc; abs_cy = arc_ptr->yc; dx = abs_x - abs_cx; dy = abs_y - abs_cy; if (dx == 0 && dy == 0) { box_info_ptr[0].valid_v = FALSE; return FALSE; } box_info_ptr[0].valid_v = TRUE; total_arc_radian = ((double)arc_ptr->angle2)*M_PI/((double)180.0*64.0); abs_radius = (double)sqrt((double)(dx*dx+dy*dy)); for (i=0; i < num_objects; i++) { if (!finalize) { box_info_ptr[i].angle_in_radian = atan2(box_info_ptr[i].half_w, abs_radius) * ((double)2.0); } total_radian += fabs(box_info_ptr[i].angle_in_radian); } switch (gnLayoutDirection) { case LAYOUT_DIR_S: if (circular) { inc_radian = (total_arc_radian-total_radian)/((double)num_objects); } else { inc_radian = (total_arc_radian-total_radian)/((double)(num_objects-1)); } break; case LAYOUT_DIR_N: if (circular) { inc_radian = (total_arc_radian+total_radian)/((double)num_objects); } else { inc_radian = (total_arc_radian+total_radian)/((double)(num_objects-1)); } break; } angle = arc_ptr->angle1*M_PI/((double)180.0*64.0); for (i=0; i < num_objects; i++, angle+=inc_radian) { struct ObjRec *obj_ptr=box_info_ptr[i].obj; int x=0, y=0, w=0, h=0, orig_x=0, orig_y=0; XPoint v[5]; struct BBRec bbox; double half_way_angle=(double)0.0; w = box_info_ptr[i].w; h = box_info_ptr[i].h; if (finalize) { if (obj_ptr->type == OBJ_TEXT && obj_ptr->detail.t->minilines.just != JUST_C) { ChangeObjTextJust(obj_ptr, JUST_C); } } /* * half_way_angle measures angle in the arc sense (see the beginning * of "arc.c"). * the RoateaBBoxByRadian() rotates things in the drawing sense * (the one that's vertically flipped w.r.t. PostScript) */ switch (gnLayoutDirection) { case LAYOUT_DIR_S: half_way_angle = angle+(box_info_ptr[i].angle_in_radian/2.0); if (finalize) { orig_x = ((obj_ptr->obbox.rbx+obj_ptr->obbox.ltx)>>1); orig_y = obj_ptr->obbox.lty; RotateObjForLayout(obj_ptr, box_info_ptr[i].angle_to_rotate, CORNER_BOTTOM); x = abs_cx + (int)((abs_radius-h)*cos(half_way_angle)); y = abs_cy - (int)((abs_radius-h)*sin(half_way_angle)); } else { SetBBRec(&bbox, -(w>>1), -h, w-(w>>1), 0); box_info_ptr[i].angle_to_rotate = (-half_way_angle-(M_PI/2.0)); RotateBBoxByRadian(&bbox, box_info_ptr[i].angle_to_rotate, v); x = abs_cx + (int)(abs_radius*cos(half_way_angle)); y = abs_cy - (int)(abs_radius*sin(half_way_angle)); } break; case LAYOUT_DIR_N: half_way_angle = angle-(box_info_ptr[i].angle_in_radian/2.0); if (finalize) { orig_x = ((obj_ptr->obbox.rbx+obj_ptr->obbox.ltx)>>1); orig_y = obj_ptr->obbox.rby; RotateObjForLayout(obj_ptr, box_info_ptr[i].angle_to_rotate, CORNER_TOP); x = abs_cx + (int)((abs_radius-h)*cos(half_way_angle)); y = abs_cy - (int)((abs_radius-h)*sin(half_way_angle)); } else { SetBBRec(&bbox, -(w>>1), 0, w-(w>>1), h); box_info_ptr[i].angle_to_rotate = (-half_way_angle+(M_PI/2.0)); RotateBBoxByRadian(&bbox, box_info_ptr[i].angle_to_rotate, v); x = abs_cx + (int)(abs_radius*cos(half_way_angle)); y = abs_cy - (int)(abs_radius*sin(half_way_angle)); } break; } if (finalize) { MoveObj(obj_ptr, x-orig_x, y-orig_y); } else { box_info_ptr[i].v[0].x = OFFSET_X(x + v[0].x); box_info_ptr[i].v[0].y = OFFSET_Y(y + v[0].y); box_info_ptr[i].v[1].x = OFFSET_X(x + v[1].x); box_info_ptr[i].v[1].y = OFFSET_Y(y + v[1].y); box_info_ptr[i].v[2].x = OFFSET_X(x + v[2].x); box_info_ptr[i].v[2].y = OFFSET_Y(y + v[2].y); box_info_ptr[i].v[3].x = OFFSET_X(x + v[3].x); box_info_ptr[i].v[3].y = OFFSET_Y(y + v[3].y); box_info_ptr[i].v[4].x = box_info_ptr[i].v[0].x; box_info_ptr[i].v[4].y = box_info_ptr[i].v[0].y; } switch (gnLayoutDirection) { case LAYOUT_DIR_S: angle += box_info_ptr[i].angle_in_radian; break; case LAYOUT_DIR_N: angle -= box_info_ptr[i].angle_in_radian; break; } } return TRUE; } #define NO_GENERATE 0 #define GENERATE 1 static void HighLightLayout(arc_ptr, box_info_ptr, grid_x, grid_y, generate) struct ArcRec *arc_ptr; struct BoxInfoRec *box_info_ptr; int grid_x, grid_y, generate; { int i, num_objects=numObjSelected-1; if (generate) { HighLightOrFinalLayout(arc_ptr, box_info_ptr, grid_x, grid_y, SET_LAYOUT_VS); } if (box_info_ptr[0].valid_v) { for (i=0; i < num_objects; i++) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, box_info_ptr[i].v, 5, CoordModeOrigin); } } } static void DoLayoutOnArc(arc_obj, box_info_ptr) struct ObjRec *arc_obj; struct BoxInfoRec *box_info_ptr; { struct ArcRec *arc_ptr=arc_obj->detail.a; int done=FALSE, something_changed=FALSE, grid_x=0, grid_y=0; SetMouseStatus(TgLoadCachedString(CSTID_START_LAYOUT_ON_ARC), TgLoadCachedString(CSTID_FINISH), TgLoadCachedString(CSTID_FINISH)); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonPressMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } while (!done) { XEvent input; XNextEvent(mainDisplay, &input); switch (input.type) { case Expose: ExposeEventHandler(&input, TRUE); break; case VisibilityNotify: ExposeEventHandler(&input, TRUE); break; case ButtonPress: if (input.xbutton.button == Button1) { SetMouseStatus(TgLoadCachedString(CSTID_END_LAYOUT_ON_ARC), "", ""); GridXY(input.xbutton.x, input.xbutton.y, &grid_x, &grid_y); HighLightLayout(arc_ptr, box_info_ptr, grid_x, grid_y, GENERATE); something_changed = TRUE; } else { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); done = TRUE; } break; case MotionNotify: if (something_changed) { HighLightLayout(arc_ptr, box_info_ptr, grid_x, grid_y, NO_GENERATE); GridXY(input.xmotion.x, input.xmotion.y, &grid_x, &grid_y); HighLightLayout(arc_ptr, box_info_ptr, grid_x, grid_y, GENERATE); } break; case ButtonRelease: XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); done = TRUE; HighLightLayout(arc_ptr, box_info_ptr, grid_x, grid_y, NO_GENERATE); } } if (something_changed && box_info_ptr[0].valid_v) { int ltx=selLtX, lty=selLtY, rbx=selRbX, rby=selRbY; HighLightReverse(); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); if (HighLightOrFinalLayout(arc_ptr, box_info_ptr, grid_x, grid_y, FINALIZE_LAYOUT)) { RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; } else { AbortPrepareCmd(CMD_REPLACE); } HighLightForward(); } } static int ObjsAlreadySorted(box_info_ptr, min_index, max_index) struct BoxInfoRec *box_info_ptr; int min_index, max_index; { int i; for (i=min_index; i < max_index; i++) { int d=box_info_ptr[i].obj->obbox.ltx-box_info_ptr[i+1].obj->obbox.ltx; if (d > 0) { return FALSE; } else if (d == 0 && box_info_ptr[i].obj->obbox.lty > box_info_ptr[i+1].obj->obbox.lty) { return FALSE; } } return TRUE; } static void QuickSortObjs(box_info_ptr, min_index, max_index, level) struct BoxInfoRec *box_info_ptr; int min_index, max_index, level; { int i, j, pivot_index, pivot_x_value, pivot_y_value, something_swapped; struct ObjRec *tmp_obj; if (min_index > max_index) return; if (ObjsAlreadySorted(box_info_ptr, min_index, max_index)) return; pivot_index = max_index; pivot_x_value = box_info_ptr[pivot_index].obj->obbox.ltx; pivot_y_value = box_info_ptr[pivot_index].obj->obbox.lty; i = min_index; j = max_index-1; something_swapped = FALSE; do { int d; while (TRUE) { d = box_info_ptr[i].obj->obbox.ltx-pivot_x_value; if (d < 0 || (d == 0 && box_info_ptr[i].obj->obbox.lty < pivot_y_value)) { i++; } else { break; } } while (j > i) { d = box_info_ptr[j].obj->obbox.ltx-pivot_x_value; if (d > 0 || (d == 0 && box_info_ptr[j].obj->obbox.lty > pivot_y_value)) { j--; } else { break; } } if (j > i) { tmp_obj = box_info_ptr[j].obj; box_info_ptr[j].obj = box_info_ptr[i].obj; box_info_ptr[i].obj = tmp_obj; something_swapped = TRUE; if (j == i+1) break; i++; j--; } else { break; } } while (TRUE); if (i == max_index) { /* pivot corresponds to the largest */ if (something_swapped) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "Huh? min_index=%1d, max_index=%1d, level=%1d\n", min_index, max_index, level); #endif /* _TGIF_DBG */ } else { QuickSortObjs(box_info_ptr, min_index, j, level+1); } } else if (j > i) { tmp_obj = box_info_ptr[max_index].obj; box_info_ptr[max_index].obj = box_info_ptr[j].obj; box_info_ptr[j].obj = tmp_obj; QuickSortObjs(box_info_ptr, min_index, j-1, level+1); QuickSortObjs(box_info_ptr, j+1, max_index, level+1); } else { tmp_obj = box_info_ptr[max_index].obj; box_info_ptr[max_index].obj = box_info_ptr[i].obj; box_info_ptr[i].obj = tmp_obj; QuickSortObjs(box_info_ptr, min_index, i-1, level+1); QuickSortObjs(box_info_ptr, i+1, max_index, level+1); } } static int DecideLayoutDirection(obj_ptr) struct ObjRec *obj_ptr; { struct ArcRec *arc_ptr=obj_ptr->detail.a; struct BBRec *p_obbox=(&obj_ptr->obbox); int cx=arc_ptr->xc, cy=arc_ptr->yc, h_slack, v_slack; char spec[MAXSTRING+1]; h_slack = ((p_obbox->ltx+p_obbox->rbx)>>1) - cx; v_slack = ((p_obbox->lty+p_obbox->rby)>>1) - cy; if (h_slack == 0) { if (v_slack == 0) { return LAYOUT_DIR_S; } else if (v_slack > 0) { return LAYOUT_DIR_S; } else { return LAYOUT_DIR_N; } } *spec = '\0'; if (Dialog(TgLoadString(STID_ENTER_CONCAVE_OR_CONVEX), NULL, spec) == INVALID) { return LAYOUT_DIR_NONE; } UtilTrimBlanks(spec); /* do not translate -- program constants */ if (UtilStrICmp(spec, "concave") == 0) { return LAYOUT_DIR_N; } else if (UtilStrICmp(spec, "convex") == 0) { return LAYOUT_DIR_S; } else { switch (*spec) { case 'c': case 'C': return LAYOUT_DIR_N; case 'v': case 'V': return LAYOUT_DIR_S; } } sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return LAYOUT_DIR_NONE; } void LayoutOnArc() { struct SelRec *sel_ptr; struct ObjRec *arc_obj=NULL; int arc_obj_count=0, i, something_locked=FALSE; struct BoxInfoRec *box_info_ptr; if (curChoice != NOTHING) { MsgBox(TgLoadString(STID_SEL_AN_ARC_OBJ), TOOL_NAME, INFO_MB); return; } for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; if (obj_ptr->type == OBJ_ARC) { arc_obj_count++; arc_obj = obj_ptr; } else if (obj_ptr->locked) { something_locked = TRUE; } } if (arc_obj_count == 0) { MsgBox(TgLoadString(STID_NO_ARC_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } else if (arc_obj_count > 1) { MsgBox(TgLoadString(STID_TOO_MANY_ARC_SEL_ONLY_ONE_ARC), TOOL_NAME, INFO_MB); return; } else if (numObjSelected == 1) { MsgBox(TgLoadString(STID_NO_OTHER_OBJ_FOR_LAYOUTONARC), TOOL_NAME, INFO_MB); return; } else if (something_locked) { MsgBox(TgLoadString(STID_CANNOT_LAYOUTONARC_LOCKED), TOOL_NAME, INFO_MB); return; } if (arc_obj->ctm != NULL || arc_obj->detail.a->w != arc_obj->detail.a->h) { MsgBox(TgLoadString(STID_ARC_XFORMED_FOR_LAYOUTONARC), TOOL_NAME, INFO_MB); return; } gnLayoutDirection = DecideLayoutDirection(arc_obj); if (gnLayoutDirection == LAYOUT_DIR_NONE) { return; } box_info_ptr = (struct BoxInfoRec *)malloc( (numObjSelected-1)*sizeof(struct BoxInfoRec)); if (box_info_ptr == NULL) { FailAllocMessage(); return; } for (i=0, sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; if (obj_ptr->type != OBJ_ARC) { box_info_ptr[i].obj = obj_ptr; i++; } } QuickSortObjs(box_info_ptr, 0, numObjSelected-2, 0); for (i=0; i < numObjSelected-1; i++) { struct ObjRec *obj_ptr=box_info_ptr[i].obj; box_info_ptr[i].w = obj_ptr->obbox.rbx-obj_ptr->obbox.ltx; box_info_ptr[i].h = obj_ptr->obbox.rby-obj_ptr->obbox.lty; box_info_ptr[i].half_w = (double)(box_info_ptr[i].w>>1); box_info_ptr[i].valid_v = FALSE; } SaveStatusStrings(); DoLayoutOnArc(arc_obj, box_info_ptr); RestoreStatusStrings(); free(box_info_ptr); } /* ----------------------- PreciseRotate ----------------------- */ static int FinishPreciseRotate(angle_spec, pivot_x, pivot_y) double angle_spec; int pivot_x, pivot_y; { struct SelRec *sel_ptr; double angle_in_radian=angle_spec*M_PI/180.0; double sin_val=sin(angle_in_radian); double cos_val=cos(angle_in_radian); for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; int orig_x=((obj_ptr->obbox.ltx+obj_ptr->obbox.rbx)>>1); int orig_y=obj_ptr->obbox.lty; int x=0, y=0, dx=orig_x-pivot_x, dy=orig_y-pivot_y; if (dx != 0 || dy != 0) { x = (short)round(dx*cos_val - dy*sin_val); y = (short)round(dx*sin_val + dy*cos_val); } x += pivot_x; y += pivot_y; /* RotateObjForLayout() rotates about center-top */ RotateObjForLayout(obj_ptr, angle_in_radian, CORNER_BOTTOM); MoveObj(obj_ptr, x-orig_x, y-orig_y); } return TRUE; } void PreciseRotate() { char spec[MAXSTRING+1]; double angle_spec; int arc_count=0, pivot_x=0, pivot_y=0, ltx, lty, rbx, rby; struct SelRec *sel_ptr; struct ObjRec *arc_obj=NULL; if (curChoice == VERTEXMODE) { MsgBox(TgLoadString(STID_ROT_NOT_AVAIL_ON_VERTEX_MODE), TOOL_NAME, INFO_MB); return; } else if (curChoice != NOTHING || topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (sel_ptr->obj->type == OBJ_ARC) { arc_obj = sel_ptr->obj; arc_count++; } } if (!autoRotatePivot && rotatePivotAbsXYValid) { pivot_x = rotatePivotAbsX; pivot_y = rotatePivotAbsY; } else { if (arc_count == 1) { if (arc_obj->ctm == NULL) { pivot_x = arc_obj->detail.a->xc; pivot_y = arc_obj->detail.a->yc; } else { struct ArcRec *arc_ptr=arc_obj->detail.a; int x, y; TransformPointThroughCTM(arc_ptr->xc-arc_obj->x, arc_ptr->yc-arc_obj->y, arc_obj->ctm, &x, &y); pivot_x = x + arc_obj->x; pivot_y = y + arc_obj->y; } } else { pivot_x = (selObjLtX+selObjRbX)>>1; pivot_y = (selObjLtY+selObjRbY)>>1; } } *spec = '\0'; Dialog(TgLoadString(STID_ENTER_AN_ANGLE_IN_DEGREES), NULL, spec); UtilTrimBlanks(spec); if (*spec == '\0') return; if (sscanf(spec, "%lf", &angle_spec) != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC_NUM_EXPECTED), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (fabs(angle_spec) < (1.0e-5)) return; ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); if (FinishPreciseRotate(angle_spec, pivot_x, pivot_y)) { RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; } else { AbortPrepareCmd(CMD_REPLACE); } HighLightForward(); } void RotateAllSelObj(angle_spec) double angle_spec; { int arc_count=0, pivot_x=0, pivot_y=0, ltx, lty, rbx, rby; struct SelRec *sel_ptr; struct ObjRec *arc_obj=NULL; if (curChoice != NOTHING || topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (sel_ptr->obj->type == OBJ_ARC) { arc_obj = sel_ptr->obj; arc_count++; } } if (arc_count == 1) { if (arc_obj->ctm == NULL) { pivot_x = arc_obj->detail.a->xc; pivot_y = arc_obj->detail.a->yc; } else { struct ArcRec *arc_ptr=arc_obj->detail.a; int x, y; TransformPointThroughCTM(arc_ptr->xc-arc_obj->x, arc_ptr->yc-arc_obj->y, arc_obj->ctm, &x, &y); pivot_x = x + arc_obj->x; pivot_y = y + arc_obj->y; } } else { pivot_x = (selObjLtX+selObjRbX)>>1; pivot_y = (selObjLtY+selObjRbY)>>1; } if (fabs(angle_spec) < (1.0e-5)) return; ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); FinishPreciseRotate(angle_spec, pivot_x, pivot_y); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } void NoTransform() { struct SelRec *sel_ptr; int changed=FALSE, grouped=FALSE; int ltx=selLtX, lty=selLtY, rbx=selRbX, rby=selRbY; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); StartCompositeCmd(); for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; if (obj_ptr->ctm != NULL) { int cx=0, cy=0; switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: case OBJ_PIN: grouped = TRUE; break; default: cx = ((obj_ptr->obbox.ltx+obj_ptr->obbox.rbx)>>1); cy = ((obj_ptr->obbox.lty+obj_ptr->obbox.rby)>>1); changed = TRUE; PrepareToReplaceAnObj(obj_ptr); free(obj_ptr->ctm); obj_ptr->ctm = NULL; memcpy(&obj_ptr->obbox, &obj_ptr->orig_obbox, sizeof(struct BBRec)); if (obj_ptr->type == OBJ_TEXT) { memcpy(&obj_ptr->bbox, &obj_ptr->detail.t->orig_bbox, sizeof(struct BBRec)); } AdjObjSplineVs(obj_ptr); AdjObjCache(obj_ptr); AdjObjBBox(obj_ptr); MoveObj(obj_ptr, cx-((obj_ptr->obbox.ltx+obj_ptr->obbox.rbx)>>1), cy-((obj_ptr->obbox.lty+obj_ptr->obbox.rby)>>1)); RecordReplaceAnObj(obj_ptr); break; } } else { switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: case OBJ_PIN: grouped = TRUE; break; default: break; } } } EndCompositeCmd(); if (changed) { UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; if (grouped) { Msg(TgLoadString(STID_SOME_GROUP_OBJ_NOT_MODIFIED)); } } else { if (grouped) { MsgBox(TgLoadString(STID_CANNOT_REM_XFORM_FOR_GROUPED), TOOL_NAME, INFO_MB); } HighLightForward(); } } void SetEditTextSize() { char spec[MAXSTRING+1]; int size=0; MakeQuiescent(); *spec = '\0'; sprintf(gszMsgBox, TgLoadString(STID_ENTER_EDIT_TEXT_SIZE), editTextSize); *spec = '\0'; Dialog(gszMsgBox, NULL, spec); UtilTrimBlanks(spec); if (*spec == '\0') return; size = atoi(spec); if (size != 0 && (size < 4 || size > 34)) { sprintf(gszMsgBox, TgLoadString(STID_EDIT_TEXT_SIZE_OUT_OF_RANGE), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { SetEditTextSizeValue(size); if (editTextSize == 0) { Msg(TgLoadString(STID_ACTUAL_EDIT_TEXT_SIZE)); } else { sprintf(gszMsgBox, TgLoadString(STID_USE_SPECIFIED_EDIT_TEXT_SIZE), editTextSize); Msg(gszMsgBox); } } } static void UpdateOuterInnerSelForFind(obj_ptr) struct ObjRec *obj_ptr; /* outerSel is at the top of the chain and innerSel is at the bottom */ { AddObjIntoSel(obj_ptr, NULL, outerSelForFind, &outerSelForFind, &innerSelForFind); } static struct ObjRec *DoFind(obj_ptr) struct ObjRec *obj_ptr; { int found_starting_point=TRUE; MiniLinesInfo *minilines=NULL; struct ObjRec *ptr=NULL; struct ObjRec *return_obj=NULL; if (obj_ptr->type != OBJ_TEXT) { struct AttrRec *attr_ptr; for (attr_ptr=obj_ptr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { return_obj = DoFind(attr_ptr->obj); if (return_obj != NULL) { return return_obj; } } } } switch (obj_ptr->type) { case OBJ_SYM: case OBJ_GROUP: case OBJ_ICON: for (ptr=obj_ptr->detail.r->last; ptr != NULL; ptr=ptr->prev) { ptr->tmp_parent = obj_ptr; return_obj = DoFind(ptr); if (return_obj != NULL) { UpdateOuterInnerSelForFind(obj_ptr); return return_obj; } } break; case OBJ_PIN: ptr = GetPinObj(obj_ptr); ptr->tmp_parent = obj_ptr; return_obj = DoFind(ptr); if (return_obj != NULL) { return return_obj; } break; case OBJ_TEXT: found_starting_point = TRUE; minilines = (&obj_ptr->detail.t->minilines); SaveCursorPositionInCurText(); curStrBlock = minilines->first->first_block; textCurIndex = 0; ResetOnCursorKey(FALSE); SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); if (FindStringInMiniLines(minilines, &found_starting_point, gpszSearch, gnSearchLen, gnSearchCaseSensitive, &gpFoundStartStrBlock, &gnFoundStartCharIndex, &gpFoundEndStrBlock, &gnFoundEndCharIndex)) { return obj_ptr; } RestoreCursorPositionInCurText(); break; default: break; } return NULL; } static int gnFoundStartingPoint=FALSE; static struct ObjRec *DoFindAlready(obj_ptr, bottom_half, pn_give_up) struct ObjRec *obj_ptr; int bottom_half; /* TRUE if searching from curTextObj to topObj */ int *pn_give_up; { struct ObjRec *ptr=NULL; struct ObjRec *return_obj=NULL; if (obj_ptr->type != OBJ_TEXT) { struct AttrRec *attr_ptr; for (attr_ptr=obj_ptr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { return_obj = DoFindAlready(attr_ptr->obj, bottom_half, pn_give_up); if (return_obj != NULL) { return return_obj; } if (pn_give_up != NULL && *pn_give_up) { return NULL; } } } } switch (obj_ptr->type) { case OBJ_SYM: case OBJ_GROUP: case OBJ_ICON: for (ptr=obj_ptr->detail.r->last; ptr != NULL; ptr=ptr->prev) { ptr->tmp_parent = obj_ptr; return_obj = DoFindAlready(ptr, bottom_half, pn_give_up); if (return_obj != NULL) { UpdateOuterInnerSelForFind(obj_ptr); return return_obj; } if (pn_give_up != NULL && *pn_give_up) { return NULL; } } break; case OBJ_PIN: ptr = GetPinObj(obj_ptr); ptr->tmp_parent = obj_ptr; return_obj = DoFindAlready(ptr, bottom_half, pn_give_up); if (return_obj != NULL) { return return_obj; } if (pn_give_up != NULL && *pn_give_up) { return NULL; } break; case OBJ_TEXT: if ((bottom_half && gnFoundStartingPoint) || (!bottom_half && obj_ptr != curTextObj)) { int found_starting_point=TRUE; MiniLinesInfo *minilines=(&obj_ptr->detail.t->minilines); SaveCursorPositionInCurText(); curStrBlock = minilines->first->first_block; textCurIndex = 0; ResetOnCursorKey(FALSE); SetTextHighlight(); UpdatePinnedMenu(MENU_EDIT); if (FindStringInMiniLines(minilines, &found_starting_point, gpszSearch, gnSearchLen, gnSearchCaseSensitive, &gpFoundStartStrBlock, &gnFoundStartCharIndex, &gpFoundEndStrBlock, &gnFoundEndCharIndex)) { return obj_ptr; } RestoreCursorPositionInCurText(); } else if (bottom_half) { if (obj_ptr == curTextObj) { gnFoundStartingPoint = TRUE; } } else { if (obj_ptr == curTextObj) { if (pn_give_up != NULL) *pn_give_up = TRUE; } } break; default: break; } return NULL; } static void Find() { int wrapped=FALSE; struct ObjRec *obj_ptr=NULL; struct ObjRec *found_obj=NULL; CleanOuterInnerSelForFind(); UpdatePinnedMenu(MENU_EDIT); if (gpszSearch == NULL) return; gnSearchLen = strlen(gpszSearch); gnFoundStartCharIndex = 0; gpFoundStartStrBlock = NULL; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if (curChoice == DRAWTEXT) { if (curTextObj != NULL && FindTextInCurTextObj(gpszSearch, gnSearchLen, gnSearchCaseSensitive, &gpFoundStartStrBlock, &gnFoundStartCharIndex, &gpFoundEndStrBlock, &gnFoundEndCharIndex)) { found_obj = curTextObj; CopyOuterSelToOuterSelForFind(); } if (found_obj == NULL) { gnFoundStartingPoint = FALSE; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (!ObjInVisibleLayer(obj_ptr)) { continue; } found_obj = DoFindAlready(obj_ptr, TRUE, NULL); if (found_obj != NULL) { break; } } if (found_obj == NULL && gnFoundStartingPoint) { wrapped = TRUE; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { int give_up=FALSE; obj_ptr->tmp_parent = NULL; if (!ObjInVisibleLayer(obj_ptr)) { continue; } found_obj = DoFindAlready(obj_ptr, FALSE, &give_up); if (found_obj != NULL) { break; } if (give_up) { break; } } } } } if (found_obj == NULL) { if (curChoice == DRAWTEXT) { wrapped = TRUE; } for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (!ObjInVisibleLayer(obj_ptr)) { continue; } found_obj = DoFind(obj_ptr); if (found_obj != NULL) { break; } } if (found_obj != NULL) { if (curChoice != DRAWTEXT) { SetCurChoice(DRAWTEXT); } } } SetDefaultCursor(mainWindow); ShowCursor(); if (found_obj == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_FIND_NAMED_STRING), gpszSearch); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { HighLightText(found_obj, gpFoundStartStrBlock, gnFoundStartCharIndex, gpFoundEndStrBlock, gnFoundEndCharIndex); if (wrapped) { Msg(TgLoadString(STID_FIND_CMD_WRAPPED)); } } } void FindCaseSensitive() { char spec[MAXSTRING]; *spec = '\0'; Dialog(TgLoadString(STID_ENTER_CASE_STR_TO_FIND), NULL, spec); if (*spec == '\0') { return; } if (gpszSearch != NULL) free(gpszSearch); if ((gpszSearch=UtilStrDup(spec)) == NULL) FailAllocMessage(); gnSearchCaseSensitive = TRUE; if (curChoice != DRAWTEXT) { MakeQuiescent(); } Find(); } void FindNoCase() { char spec[MAXSTRING]; *spec = '\0'; Dialog(TgLoadString(STID_ENTER_NOCASE_STR_TO_FIND), NULL, spec); if (*spec == '\0') { return; } if (gpszSearch != NULL) free(gpszSearch); if ((gpszSearch=UtilStrDup(spec)) == NULL) FailAllocMessage(); gnSearchCaseSensitive = FALSE; if (curChoice != DRAWTEXT) { MakeQuiescent(); } Find(); } void FindAgain() { if (gpszSearch == NULL) { MsgBox(TgLoadString(STID_NO_PREVIOUS_FIND), TOOL_NAME, INFO_MB); } else { Find(); } } /* ----------------------- EditMenu ----------------------- */ int RefreshEditMenu(menu) TgMenu *menu; { int ok=TRUE; StrSegInfo ssi; memset(&ssi, 0, sizeof(StrSegInfo)); /* CopyPlainTextAsObject */ ok &= TgEnableMenuItemById(menu, CMDID_COPYPLAINTEXTASOBJECT, (curChoice == DRAWTEXT && textHighlight)); /* CopyUTF8String */ ok &= TgEnableMenuItemById(menu, CMDID_COPYUTF8, (curChoice == DRAWTEXT && textHighlight && CanCopyHighLightedTextAsUTF8Strings(NULL))); /* PasteUTF8String */ ok &= TgEnableMenuItemById(menu, CMDID_PASTEUTF8, (curChoice == DRAWTEXT && textCursorShown && CanPasteUTF8StringIntoText(&ssi))); /* ImageProc submenu */ ok &= TgEnableMenuItemById(menu, MENU_IMAGEPROC, CanPerformImageProc()); /* FindAgain */ ok &= TgEnableMenuItemById(menu, CMDID_FINDAGAIN, (gpszSearch != NULL)); return ok; } TgMenu *CreateEditMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshEditMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshEditMenu); } return menu; } int EditMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(editMenuInfo.create_proc)(NULL, X, Y, &editMenuInfo, INVALID); activeMenu = MENU_EDIT; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } /* ======================= ArrangeMenu Related ======================= */ void FrontProc() { if (topSel != NULL) { HighLightReverse(); MoveSelToTop(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); } } void BackProc() { if (topSel != NULL) { HighLightReverse(); MoveSelToBot(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); } } void AlignObjsTop() { register int saved_h_align = horiAlign, saved_v_align = vertAlign; horiAlign = ALIGN_N; vertAlign = ALIGN_T; AlignSelObjs(); horiAlign = saved_h_align; vertAlign = saved_v_align; } void AlignObjsMiddle() { register int saved_h_align = horiAlign, saved_v_align = vertAlign; horiAlign = ALIGN_N; vertAlign = ALIGN_M; AlignSelObjs(); horiAlign = saved_h_align; vertAlign = saved_v_align; } void AlignObjsBottom() { register int saved_h_align = horiAlign, saved_v_align = vertAlign; horiAlign = ALIGN_N; vertAlign = ALIGN_B; AlignSelObjs(); horiAlign = saved_h_align; vertAlign = saved_v_align; } void AlignObjsLeft() { register int saved_h_align = horiAlign, saved_v_align = vertAlign; horiAlign = ALIGN_L; vertAlign = ALIGN_N; AlignSelObjs(); horiAlign = saved_h_align; vertAlign = saved_v_align; } void AlignObjsCenter() { register int saved_h_align = horiAlign, saved_v_align = vertAlign; horiAlign = ALIGN_C; vertAlign = ALIGN_N; AlignSelObjs(); horiAlign = saved_h_align; vertAlign = saved_v_align; } void AlignObjsRight() { register int saved_h_align = horiAlign, saved_v_align = vertAlign; horiAlign = ALIGN_R; vertAlign = ALIGN_N; AlignSelObjs(); horiAlign = saved_h_align; vertAlign = saved_v_align; } static void Abut(Dir) int Dir; { struct ObjRec *obj_ptr=NULL; struct SelRec *sel_ptr=NULL; struct SelRec *top_sort=NULL, *bot_sort=NULL, *sort_ptr=NULL; struct SelRec *new_sort_ptr=NULL, *tmp_sel_ptr=NULL, *next_sort=NULL; struct ObjRec *sorted_obj=NULL, *locked_obj=NULL; struct SubCmdRec *sub_cmd=NULL; int sel_ltx=0, sel_lty=0, sel_rbx=0, sel_rby=0, rbx=0, rby=0; int found=FALSE, delta=0, dx=0, dy=0; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } else if (curChoice == VERTEXMODE) { MsgBox(TgLoadString(STID_CANNOT_ABUT_IN_VERTEX_MODE), TOOL_NAME, INFO_MB); return; } else if (numObjLocked > 1) { MsgBox(TgLoadString(STID_CANNOT_ABUT_LOCKED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); StartCompositeCmd(); sel_ltx = selLtX; sel_lty = selLtY; sel_rbx = selRbX; sel_rby = selRbY; top_sort = (struct SelRec *)malloc(sizeof(struct SelRec)); if (top_sort == NULL) FailAllocMessage(); top_sort->next = top_sort->prev = NULL; top_sort->obj = sorted_obj = botSel->obj; if (botSel->obj->locked) locked_obj = botSel->obj; for (sel_ptr=botSel->prev; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { obj_ptr = sel_ptr->obj; if (obj_ptr->locked) locked_obj = obj_ptr; switch (Dir) { case ABUT_HORIZONTAL: if (obj_ptr->obbox.ltx < sorted_obj->obbox.ltx || (obj_ptr->obbox.ltx == sorted_obj->obbox.ltx && obj_ptr->obbox.lty < sorted_obj->obbox.lty)) { top_sort->obj = sorted_obj = sel_ptr->obj; } break; case ABUT_VERTICAL: if (obj_ptr->obbox.lty < sorted_obj->obbox.lty || (obj_ptr->obbox.lty == sorted_obj->obbox.lty && obj_ptr->obbox.ltx < sorted_obj->obbox.ltx)) { top_sort->obj = sorted_obj = sel_ptr->obj; } break; } } bot_sort = top_sort; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { if (sel_ptr->obj == top_sort->obj) continue; obj_ptr = sel_ptr->obj; new_sort_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (new_sort_ptr == NULL) FailAllocMessage(); new_sort_ptr->obj = obj_ptr; found = FALSE; for (sort_ptr=top_sort->next; sort_ptr!=NULL; sort_ptr=sort_ptr->next) { switch (Dir) { case ABUT_HORIZONTAL: if (sort_ptr->obj->obbox.ltx > obj_ptr->obbox.ltx || (sort_ptr->obj->obbox.ltx == obj_ptr->obbox.ltx && sort_ptr->obj->obbox.lty > obj_ptr->obbox.lty)) { found = TRUE; } break; case ABUT_VERTICAL: if (sort_ptr->obj->obbox.lty > obj_ptr->obbox.lty || (sort_ptr->obj->obbox.lty == obj_ptr->obbox.lty && sort_ptr->obj->obbox.ltx > obj_ptr->obbox.ltx)) { found = TRUE; } break; } if (found) break; } new_sort_ptr->next = sort_ptr; if (sort_ptr == NULL) { new_sort_ptr->prev = bot_sort; bot_sort->next = new_sort_ptr; bot_sort = new_sort_ptr; } else { new_sort_ptr->prev = sort_ptr->prev; sort_ptr->prev->next = new_sort_ptr; sort_ptr->prev = new_sort_ptr; } } tmp_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (tmp_sel_ptr == NULL) FailAllocMessage(); tmp_sel_ptr->next = tmp_sel_ptr->prev = NULL; if (locked_obj != NULL) { switch (Dir) { case ABUT_HORIZONTAL: rbx = top_sort->obj->obbox.rbx; for (sort_ptr=top_sort; sort_ptr->obj!=locked_obj && sort_ptr->next!=NULL; sort_ptr=next_sort) { next_sort = sort_ptr->next; delta = rbx-next_sort->obj->obbox.ltx; dx = (-delta); rbx = next_sort->obj->obbox.rbx+delta; } break; case ABUT_VERTICAL: rby = top_sort->obj->obbox.rby; for (sort_ptr=top_sort; sort_ptr->obj!=locked_obj && sort_ptr->next!=NULL; sort_ptr=next_sort) { next_sort = sort_ptr->next; delta = rby-next_sort->obj->obbox.lty; dy = (-delta); rby = next_sort->obj->obbox.rby+delta; } break; } } sub_cmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (sub_cmd == NULL) FailAllocMessage(); memset(sub_cmd, 0, sizeof(struct SubCmdRec)); rbx = top_sort->obj->obbox.rbx; rby = top_sort->obj->obbox.rby; found = (locked_obj == NULL); if (!found && locked_obj != top_sort->obj) { tmp_sel_ptr->obj = top_sort->obj; switch (Dir) { case ABUT_HORIZONTAL: sub_cmd->detail.move.dx = dx; sub_cmd->detail.move.dy = 0; PrepareToRecord(CMD_MOVE, tmp_sel_ptr, tmp_sel_ptr, 1); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); MoveObj(top_sort->obj, dx, 0); break; case ABUT_VERTICAL: sub_cmd->detail.move.dx = 0; sub_cmd->detail.move.dy = dy; PrepareToRecord(CMD_MOVE, tmp_sel_ptr, tmp_sel_ptr, 1); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); MoveObj(top_sort->obj, 0, dy); break; } } for (sort_ptr=top_sort; sort_ptr->next!=NULL; sort_ptr=next_sort) { next_sort = sort_ptr->next; tmp_sel_ptr->obj = next_sort->obj; switch (Dir) { case ABUT_HORIZONTAL: delta = rbx-next_sort->obj->obbox.ltx; rbx = next_sort->obj->obbox.rbx+delta; if (!found) delta += dx; sub_cmd->detail.move.dx = delta; sub_cmd->detail.move.dy = 0; PrepareToRecord(CMD_MOVE, tmp_sel_ptr, tmp_sel_ptr, 1); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); MoveObj(next_sort->obj, delta, 0); break; case ABUT_VERTICAL: delta = rby-next_sort->obj->obbox.lty; rby = next_sort->obj->obbox.rby+delta; if (!found) delta += dy; sub_cmd->detail.move.dx = 0; sub_cmd->detail.move.dy = delta; PrepareToRecord(CMD_MOVE, tmp_sel_ptr, tmp_sel_ptr, 1); RecordCmd(CMD_MOVE, sub_cmd, NULL, NULL, 0); MoveObj(next_sort->obj, 0, delta); break; } free(sort_ptr); } EndCompositeCmd(); free(sort_ptr); free(sub_cmd); free(tmp_sel_ptr); UpdSelBBox(); RedrawAreas(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1), sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1)); HighLightForward(); justDupped = FALSE; switch (Dir) { case ABUT_HORIZONTAL: Msg(TgLoadString(STID_ABUTTED_HORI)); break; case ABUT_VERTICAL: Msg(TgLoadString(STID_ABUTTED_VERT)); break; } SetFileModified(TRUE); } void AbutHorizontal() { Abut(ABUT_HORIZONTAL); } void AbutVertical() { Abut(ABUT_VERTICAL); } void RefreshArrangeMenu(menu) TgMenu *menu; { } int ArrangeMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(arrangeMenuInfo.create_proc)(NULL, X, Y, &arrangeMenuInfo, FALSE); activeMenu = MENU_ARRANGE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } int RefreshPropertiesMenu(menu) TgMenu *menu; { int ok=TRUE; /* UseAltEditTextBgColor */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEALTEDITTEXTBGCOLOR, useAltEditTextBgColor); /* AddColor */ ok &= TgEnableMenuItemById(menu, CMDID_ADDCOLOR, colorDisplay); return ok; } TgMenu *CreatePropertiesMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshPropertiesMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshPropertiesMenu); } return menu; } int PropertiesMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(propertiesMenuInfo.create_proc)(NULL, X, Y, &propertiesMenuInfo, INVALID); activeMenu = MENU_PROPERTIES; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } void UpdateSymbols() { int dx=0, dy=0, changed=FALSE; int sel_ltx, sel_lty, sel_rbx, sel_rby, file_type=INVALID; char path_name[MAXPATHLENGTH], sym_name[MAXPATHLENGTH]; struct ObjRec *obj_ptr, *new_obj_ptr; struct SelRec *sel_ptr; struct GroupRec *icon_ptr; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } tmpTopObj = tmpBotObj = NULL; tmpTopSel = tmpBotSel = NULL; sel_ltx = selLtX; sel_lty = selLtY; sel_rbx = selRbX; sel_rby = selRbY; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { obj_ptr = sel_ptr->obj; if (obj_ptr->type != OBJ_ICON && obj_ptr->type != OBJ_PIN) { continue; } icon_ptr = obj_ptr->detail.r; strcpy(sym_name, icon_ptr->s); if (obj_ptr->type == OBJ_ICON) { file_type = SYM_FILE_TYPE; } else { file_type = PIN_FILE_TYPE; } if (GetSymbolPath(icon_ptr->s, obj_ptr->type==OBJ_PIN, path_name)) { if ((new_obj_ptr=GetObjRepresentation(path_name, sym_name, file_type)) != NULL) { PrepareToReplaceAnObj(obj_ptr); if (icon_ptr->flip != NO_FLIP) { if (icon_ptr->flip & HORI_EVEN) FlipIconHorizontal(new_obj_ptr); if (icon_ptr->flip & VERT_EVEN) FlipIconVertical(new_obj_ptr); if (icon_ptr->flip & (HORI_ODD | VERT_ODD)) { RotateIconClockWise(new_obj_ptr); if (icon_ptr->flip & HORI_ODD) { FlipIconHorizontal(new_obj_ptr); } if (icon_ptr->flip & VERT_ODD) { FlipIconVertical(new_obj_ptr); } RotateIconCounter(new_obj_ptr); } } switch (horiAlign) { case ALIGN_L: dx = obj_ptr->obbox.ltx - new_obj_ptr->obbox.ltx; break; case ALIGN_N: case ALIGN_S: case ALIGN_C: dx = (int)(((obj_ptr->obbox.ltx+obj_ptr->obbox.rbx) - (new_obj_ptr->obbox.ltx+new_obj_ptr->obbox.rbx))/2); break; case ALIGN_R: dx = obj_ptr->obbox.rbx - new_obj_ptr->obbox.rbx; break; } switch (vertAlign) { case ALIGN_T: dy = obj_ptr->obbox.lty - new_obj_ptr->obbox.lty; break; case ALIGN_N: case ALIGN_S: case ALIGN_M: dy = (int)(((obj_ptr->obbox.lty+obj_ptr->obbox.rby) - (new_obj_ptr->obbox.lty+new_obj_ptr->obbox.rby))/2); break; case ALIGN_B: dy = obj_ptr->obbox.rby - new_obj_ptr->obbox.rby; break; } MoveObj(new_obj_ptr, dx, dy); changed = TRUE; UnlinkObj(obj_ptr); CopyAndUpdateAttrs(new_obj_ptr, obj_ptr); ExpandCurSelBBoxes(new_obj_ptr); sel_ptr->obj = new_obj_ptr; AssignNewObjIds(new_obj_ptr); AddObj(NULL, topObj, new_obj_ptr); RecordReplaceAnObj(new_obj_ptr); FreeObj(obj_ptr); } } } EndCompositeCmd(); if (changed) { UpdSelBBox(); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; Msg(TgLoadString(STID_ICONS_BROUGHT_UP_TO_DATE)); } HighLightForward(); } void SizeToWidest() { struct SelRec *sel_ptr=NULL; int abs_w=0; if (topSel == NULL || topSel == botSel) { MsgBox(TgLoadString(STID_SEL_AT_LEAST_TWO_OBJS), TOOL_NAME, INFO_MB); return; } for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; int w=obj_ptr->obbox.rbx-obj_ptr->obbox.ltx; if (w > abs_w) abs_w = w; } if (abs_w <= 1) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_SIZE_OF_GIVEN_WIDTH), abs_w); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } SizeAllSelToGivenWidth(abs_w); } void SizeToNarrowest() { struct SelRec *sel_ptr=NULL; int abs_w=0; if (topSel == NULL || topSel == botSel) { MsgBox(TgLoadString(STID_SEL_AT_LEAST_TWO_OBJS), TOOL_NAME, INFO_MB); return; } abs_w = topSel->obj->obbox.rbx-topSel->obj->obbox.ltx; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; int w=obj_ptr->obbox.rbx-obj_ptr->obbox.ltx; if (w < abs_w) abs_w = w; } if (abs_w <= 1) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_SIZE_OF_GIVEN_WIDTH), abs_w); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } SizeAllSelToGivenWidth(abs_w); } void SizeToTallest() { struct SelRec *sel_ptr=NULL; int abs_h=0; if (topSel == NULL || topSel == botSel) { MsgBox(TgLoadString(STID_SEL_AT_LEAST_TWO_OBJS), TOOL_NAME, INFO_MB); return; } for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; int h=obj_ptr->obbox.rby-obj_ptr->obbox.lty; if (h > abs_h) abs_h = h; } if (abs_h <= 1) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_SIZE_OF_GIVEN_HEIGHT), abs_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } SizeAllSelToGivenHeight(abs_h); } void SizeToShortest() { struct SelRec *sel_ptr=NULL; int abs_h=0; if (topSel == NULL || topSel == botSel) { MsgBox(TgLoadString(STID_SEL_AT_LEAST_TWO_OBJS), TOOL_NAME, INFO_MB); return; } abs_h = topSel->obj->obbox.rby-topSel->obj->obbox.lty; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; int h=obj_ptr->obbox.rby-obj_ptr->obbox.lty; if (h < abs_h) abs_h = h; } if (abs_h <= 1) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_SIZE_OF_GIVEN_HEIGHT), abs_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } SizeAllSelToGivenHeight(abs_h); } void SizeToGivenWidthHeight() { int abs_w=0, abs_h=0; char spec[MAXSTRING]; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } *spec = '\0'; if (Dialog(TgLoadString(STID_SPECIFY_WIDTH_HEIGHT), NULL, spec) == INVALID) { return; } UtilTrimBlanks(spec); if (*spec == '\0') return; if (!ParseWHSpec(spec, &abs_w, &abs_h)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (abs_w <= 1) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_SIZE_OF_GIVEN_WIDTH), abs_w); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (abs_h <= 1) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_SIZE_OF_GIVEN_HEIGHT), abs_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } SizeAllSelToGivenWidthHeight(abs_w, abs_h); } void SizeToGivenWidth() { int abs_w=0; char spec[MAXSTRING]; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } *spec = '\0'; if (Dialog(TgLoadString(STID_SPECIFY_WIDTH), NULL, spec) == INVALID) return; UtilTrimBlanks(spec); if (*spec == '\0') return; if (!GetDimension(spec, FALSE, &abs_w)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (abs_w <= 1) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_SIZE_OF_GIVEN_WIDTH), abs_w); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } SizeAllSelToGivenWidth(abs_w); } void SizeToGivenHeight() { int abs_h=0; char spec[MAXSTRING]; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } *spec = '\0'; if (Dialog(TgLoadString(STID_SPECIFY_HEIGHT), NULL, spec) == INVALID) return; UtilTrimBlanks(spec); if (*spec == '\0') return; if (!GetDimension(spec, FALSE, &abs_h)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (abs_h <= 1) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_SIZE_OF_GIVEN_HEIGHT), abs_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } SizeAllSelToGivenHeight(abs_h); } /* ----------------------- Generic Object Shadow ----------------------- */ void SetObjectShadowColor() { char spec[MAXSTRING], buf[MAXSTRING]; int new_alloc=0; *spec = '\0'; sprintf(buf, TgLoadString(STID_ENTER_A_COLOR_FOR_OBJ_SHADOW), objShadowColorStr); UtilStrCpyN(spec, sizeof(spec), objShadowColorStr); if (Dialog(buf, TgLoadString(STID_PRESS_ENTER_FOR_DEF_COLOR), spec) == INVALID) { return; } UtilTrimBlanks(spec); if (*spec == '\0') { strcpy(objShadowColorStr, "#c0c0c0"); sprintf(gszMsgBox, TgLoadString(STID_OBJ_SHADOW_COLOR_SET_TO_NAMED), objShadowColorStr); Msg(gszMsgBox); return; } if (QuickFindColorIndex(NULL, spec, &new_alloc, FALSE) == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } UtilStrCpyN(objShadowColorStr, sizeof(objShadowColorStr), spec); sprintf(gszMsgBox, TgLoadString(STID_OBJ_SHADOW_COLOR_SET_TO_NAMED), objShadowColorStr); Msg(gszMsgBox); } void SetObjectShadowOffsets() { char spec[MAXSTRING]; *spec = '\0'; sprintf(gszMsgBox, TgLoadString(STID_ENTER_XY_OFFSET_OBJ_SHADOW), objShadowXOffset, objShadowYOffset); if (Dialog(gszMsgBox, NULL, spec) == INVALID) return; UtilTrimBlanks(spec); if (*spec == '\0') return; if (ParseXYSpec(spec, &objShadowXOffset, &objShadowYOffset)) { sprintf(gszMsgBox, TgLoadString(STID_OBJ_SHADOW_XY_OFFSETS_SET_TO), objShadowXOffset, objShadowYOffset); Msg(gszMsgBox); } } static void DoAddObjectShadow() { struct SelRec *sel_ptr=NULL; int new_alloc=0, color_index=QuickFindColorIndex(NULL, objShadowColorStr, &new_alloc, FALSE); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { struct ObjRec *obj_ptr=sel_ptr->obj, *dup_obj_ptr=NULL, *group_obj=NULL; struct GroupRec *group_ptr=NULL; struct BBRec obbox, bbox; int locked=obj_ptr->locked; dup_obj_ptr = DupObj(obj_ptr); AdjObjSplineVs(dup_obj_ptr); MoveObj(dup_obj_ptr, objShadowXOffset, objShadowYOffset); ChangeObjColor(dup_obj_ptr, color_index); UnionRect(&(obj_ptr->obbox), &(dup_obj_ptr->obbox), &obbox); UnionRect(&(obj_ptr->bbox), &(dup_obj_ptr->bbox), &bbox); group_obj = JustCreateGroupObj(); group_ptr = group_obj->detail.r; group_obj->prev = obj_ptr->prev; group_obj->next = obj_ptr->next; if (obj_ptr == topObj) { curPage->top = topObj = group_obj; } else { obj_ptr->prev->next = group_obj; } if (obj_ptr == botObj) { curPage->bot = botObj = group_obj; } else { obj_ptr->next->prev = group_obj; } obj_ptr->prev = NULL; obj_ptr->next = dup_obj_ptr; dup_obj_ptr->prev = obj_ptr; dup_obj_ptr->next = NULL; group_ptr->first = obj_ptr; group_ptr->last = dup_obj_ptr; obj_ptr->x = min(obj_ptr->x, dup_obj_ptr->x); obj_ptr->y = min(obj_ptr->y, dup_obj_ptr->y); memcpy(&group_obj->obbox, &obbox, sizeof(struct BBRec)); memcpy(&group_obj->bbox, &bbox, sizeof(struct BBRec)); group_obj->locked = locked; sel_ptr->obj = group_obj; } UpdSelBBox(); } void AddObjectShadow() { if (curChoice != NOTHING || topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); DoAddObjectShadow(); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } static void DoRemoveObjectShadow() { struct SelRec *sel_ptr=NULL; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { struct ObjRec *obj_ptr=sel_ptr->obj; if (obj_ptr->type == OBJ_GROUP) { struct GroupRec *group_ptr=obj_ptr->detail.r; struct ObjRec *first_obj=group_ptr->first; if (first_obj != NULL) { struct ObjRec *second_obj=first_obj->next; if (second_obj->next == NULL) { int first_w=(first_obj->obbox.rbx-first_obj->obbox.ltx); int first_h=(first_obj->obbox.rby-first_obj->obbox.lty); int second_w=(second_obj->obbox.rbx-second_obj->obbox.ltx); int second_h=(second_obj->obbox.rby-second_obj->obbox.lty); if (first_w == second_w && first_h == second_h) { group_ptr->first = group_ptr->last = NULL; first_obj->prev = obj_ptr->prev; first_obj->next = obj_ptr->next; if (obj_ptr == topObj) { curPage->top = topObj = first_obj; } else { obj_ptr->prev->next = first_obj; } if (obj_ptr == botObj) { curPage->bot = botObj = first_obj; } else { obj_ptr->next->prev = first_obj; } obj_ptr->prev = NULL; obj_ptr->next = NULL; FreeObj(second_obj); FreeObj(obj_ptr); sel_ptr->obj = first_obj; } } } } } } static int CountObjectWithShadow() { struct SelRec *sel_ptr=NULL; int count=0; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { struct ObjRec *obj_ptr=sel_ptr->obj; if (obj_ptr->type == OBJ_GROUP) { struct GroupRec *group_ptr=obj_ptr->detail.r; struct ObjRec *first_obj=group_ptr->first; if (first_obj != NULL) { struct ObjRec *second_obj=first_obj->next; if (second_obj->next == NULL) { int first_w=(first_obj->obbox.rbx-first_obj->obbox.ltx); int first_h=(first_obj->obbox.rby-first_obj->obbox.lty); int second_w=(second_obj->obbox.rbx-second_obj->obbox.ltx); int second_h=(second_obj->obbox.rby-second_obj->obbox.lty); if (first_w == second_w && first_h == second_h) { count++; } } } } } return count; } void RemoveObjectShadow() { if (curChoice != NOTHING || topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (CountObjectWithShadow() == 0) { sprintf(gszMsgBox, TgLoadString(STID_NO_OBJ_SHADOW_FOUND)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } HighLightReverse(); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); DoRemoveObjectShadow(); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } int ReadObjectShadowInfo(buf) char *buf; { int x=0, y=0; char color_str[40], *psz=NULL; if (importingFile) return TRUE; psz = FindChar((int)'(', buf); *color_str = '\0'; psz = ParseStr(psz, (int)',', color_str, sizeof(color_str)); InitScan(psz, "\t\n, []"); if (GETINT("objshadow_info", x, "x offset") == INVALID || GETINT("objshadow_info", y, "y offset") == INVALID) { return FALSE; } UtilTrimBlanks(color_str); if (!ignoreObjectShadowInfoInFile) { UtilStrCpyN(objShadowColorStr, sizeof(objShadowColorStr), color_str); objShadowXOffset = x; objShadowYOffset = y; } return TRUE; } /* ----------------------- ExtendSegment ----------------------- */ static int ConsecutiveVerticesSelected(pn_index0, pn_index1) int *pn_index0, *pn_index1; { int index0=topVSel->v_index[0], index1=topVSel->v_index[1]; if (index0+1 == index1) { *pn_index0 = index0; *pn_index1 = index1; return TRUE; } else if (index1+1 == index0) { *pn_index0 = index1; *pn_index1 = index0; return TRUE; } return FALSE; } void ExtendSegment() { char *c_ptr=NULL, sz_value[MAXSTRING+1]; char sz_spec[MAXSTRING+1], sz_spec_copy[MAXSTRING+1]; double dval=(double)0; struct ObjRec *obj_ptr=NULL; struct PolyRec *poly_ptr=NULL; int dx=0, dy=0, x0=0, y0=0, x1=0, y1=0; double dnew_x=0, dnew_y=0; double ddx=(double)0, ddy=(double)0; struct AttrRec *name_attr=NULL, *on_reshape_attr=NULL; int ltx, lty, rbx, rby, auto_center_attr=FALSE; int has_on_reshape=FALSE, two_point_polyline=TRUE, index0=0, index1=1; if (curChoice != NOTHING && curChoice != VERTEXMODE) { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_TWO_VERTEX_POLY_ONLY)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } else if (curChoice == NOTHING) { if (topSel == NULL || topSel != botSel || topSel->obj->type != OBJ_POLY || topSel->obj->detail.p->n != 2) { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_TWO_VERTEX_POLY_ONLY)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } obj_ptr = topSel->obj; } else if (curChoice == VERTEXMODE) { if (topVSel == NULL) { if (topSel == NULL || topSel != botSel || topSel->obj->type != OBJ_POLY || topSel->obj->detail.p->n != 2) { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_TWO_VERTEX_POLY_ONLY)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } obj_ptr = topSel->obj; } else if (topVSel == botVSel && topVSel->n == 1 && topVSel->obj->type == OBJ_POLY && topVSel->obj->detail.p->n == 2) { /* treat this as if only the poly object is selected */ obj_ptr = topVSel->obj; } else if (topVSel == botVSel && topVSel->n == 2 && topVSel->obj->type == OBJ_POLY && ConsecutiveVerticesSelected(&index0, &index1)) { /* treat this as if only the poly object is selected */ obj_ptr = topVSel->obj; two_point_polyline = FALSE; } else { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_TWO_CONSEC_VERTICES_ONLY)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; poly_ptr = obj_ptr->detail.p; *sz_spec = '\0'; Dialog(TgLoadString(STID_ENTER_MULT_FACTOR), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), sz_spec); UtilTrimBlanks(sz_spec); if (*sz_spec == '\0') return; strcpy(sz_spec_copy, sz_spec); if ((c_ptr=strtok(sz_spec, " ,\t\n\r")) == NULL) return; if (*c_ptr == '+') { UtilStrCpyN(sz_value, sizeof(sz_value), &c_ptr[1]); } else { UtilStrCpyN(sz_value, sizeof(sz_value), c_ptr); } if (sscanf(sz_value, "%lf", &dval) != 1) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_FOR_A_VAL), sz_spec_copy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (obj_ptr->ctm == NULL) { dx = poly_ptr->vlist[index1].x - poly_ptr->vlist[index0].x; dy = poly_ptr->vlist[index1].y - poly_ptr->vlist[index0].y; ddx = ((double)dx) * dval; ddy = ((double)dy) * dval; dx = round(ddx); dy = round(ddy); if (dx == 0 && dy == 0) { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_RES_LINESEG_HAVE_ZERO_LEN)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } else { TransformPointThroughCTM(poly_ptr->vlist[index0].x-obj_ptr->x, poly_ptr->vlist[index0].y-obj_ptr->y, obj_ptr->ctm, &x0, &y0); TransformPointThroughCTM(poly_ptr->vlist[index1].x-obj_ptr->x, poly_ptr->vlist[index1].y-obj_ptr->y, obj_ptr->ctm, &x1, &y1); dx = x1 - x0; dy = y1 - y0; ddx = ((double)dx) * dval; ddy = ((double)dy) * dval; dx = round(ddx); dy = round(ddy); if (dx == 0 && dy == 0) { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_RES_LINESEG_HAVE_ZERO_LEN)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } auto_center_attr = AutoCenterAttr(obj_ptr); has_on_reshape = HasOnReshape(obj_ptr, &name_attr); if (has_on_reshape && name_attr != NULL) { on_reshape_attr = FindAttrWithName(obj_ptr, "on_reshape=", NULL); } HighLightReverse(); if (on_reshape_attr != NULL) { StartCompositeCmd(); } PrepareToReplaceAnObj(obj_ptr); if (obj_ptr->ctm == NULL) { if (dval > (double)0) { poly_ptr->vlist[index1].x = poly_ptr->vlist[index0].x + dx; poly_ptr->vlist[index1].y = poly_ptr->vlist[index0].y + dy; } else { poly_ptr->vlist[index0].x = poly_ptr->vlist[index1].x + dx; poly_ptr->vlist[index0].y = poly_ptr->vlist[index1].y + dy; } if (!two_point_polyline) { topVSel->x[0] = poly_ptr->vlist[index0].x; topVSel->y[0] = poly_ptr->vlist[index0].y; topVSel->x[1] = poly_ptr->vlist[index1].x; topVSel->y[1] = poly_ptr->vlist[index1].y; } } else { if (dval > (double)0) { x1 = x0 + obj_ptr->x + ddx; y1 = y0 + obj_ptr->y + ddy; ReverseTransformDoublePointThroughCTM(((double)x0)+ddx, ((double)y0)+ddy, obj_ptr->ctm, &dnew_x, &dnew_y); poly_ptr->vlist[index1].x = round(dnew_x) + obj_ptr->x; poly_ptr->vlist[index1].y = round(dnew_y) + obj_ptr->y; } else { x0 = x1 + obj_ptr->x + dx; y0 = y1 + obj_ptr->y + dy; ReverseTransformDoublePointThroughCTM(((double)x1)+ddx, ((double)y1)+ddy, obj_ptr->ctm, &dnew_x, &dnew_y); poly_ptr->vlist[index0].x = round(dnew_x) + obj_ptr->x; poly_ptr->vlist[index0].y = round(dnew_y) + obj_ptr->y; } if (!two_point_polyline) { int new_x=0, new_y=0; TransformPointThroughCTM(poly_ptr->vlist[index0].x-obj_ptr->x, poly_ptr->vlist[index0].y-obj_ptr->y, obj_ptr->ctm, &new_x, &new_y); topVSel->x[0] = obj_ptr->x + new_x; topVSel->y[0] = obj_ptr->y + new_y; TransformPointThroughCTM(poly_ptr->vlist[index1].x-obj_ptr->x, poly_ptr->vlist[index1].y-obj_ptr->y, obj_ptr->ctm, &new_x, &new_y); topVSel->x[1] = obj_ptr->x + new_x; topVSel->y[1] = obj_ptr->y + new_y; } } AdjObjSplineVs(obj_ptr); if (poly_ptr->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, poly_ptr->n, poly_ptr->vlist); } else { UpdPolyBBox(obj_ptr, poly_ptr->intn, poly_ptr->intvlist); } if (auto_center_attr) { struct AttrRec *attr_ptr=obj_ptr->fattr; int modified=FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { struct BBRec bbox; CenterObjInOBBox(attr_ptr->obj, obj_ptr->obbox, &bbox); if (bbox.ltx < ltx) ltx = bbox.ltx; if (bbox.lty < lty) lty = bbox.lty; if (bbox.rbx > rbx) rbx = bbox.rbx; if (bbox.rby > rby) rby = bbox.rby; modified = TRUE; } } if (modified) AdjObjBBox(obj_ptr); } RecordReplaceAnObj(obj_ptr); if (on_reshape_attr != NULL) { DoExec(on_reshape_attr, obj_ptr); } if (on_reshape_attr != NULL) { EndCompositeCmd(); } UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), obj_ptr->bbox.ltx-GRID_ABS_SIZE(1), obj_ptr->bbox.lty-GRID_ABS_SIZE(1), obj_ptr->bbox.rbx+GRID_ABS_SIZE(1), obj_ptr->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; HighLightForward(); } /* -------------------- ToggleTighterStructuredSplines() -------------------- */ void ToggleTighterStructuredSplines() { tighterStructSplines = !tighterStructSplines; AdjSplineVs(); SetFileModified(TRUE); UpdSelBBox(); justDupped = FALSE; ClearAndRedrawDrawWindow(); UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), TgLoadString(tighterStructSplines ? STID_WILL_USE_TIGHTER_SPLINES : STID_WILL_USE_LOOSER_SPLINES)); Msg(gszMsgBox); } /* ----------------------- CreatePolySplineMenu() ----------------------- */ int RefreshPolySplineMenu(menu) TgMenu *menu; { int ok=TRUE; /* UseTighterSplines */ #ifdef NOT_DEFINED ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLETIGHTERSPLINES, tighterStructSplines); #endif /* NOT_DEFINED */ return ok; } TgMenu *CreatePolySplineMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshPolySplineMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshPolySplineMenu); } return menu; } �������������������������������������������������������������������������������tgif-QPL-4.2.5/raster.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000160502�11602233312�014434� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/raster.c,v 1.21 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_RASTER_C_ #include "tgifdefs.h" #include "expfdefs.h" #include "choice.e" #include "color.e" #include "dialog.e" #include "file.e" #include "font.e" #include "menu.e" #include "miniline.e" #include "msg.e" #include "pattern.e" #include "poly.e" #include "shape.e" #include "raster.e" #include "setup.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "xprtfltr.e" #include "xbm/arrow.xbm" #include "xbm/text.xbm" #include "xbm/box.xbm" #include "xbm/oval.xbm" #include "xbm/ovalcent.xbm" #include "xbm/ovaledge.xbm" #include "xbm/poly.xbm" #include "xbm/polygon.xbm" #include "xbm/arc.xbm" #include "xbm/arc_edge.xbm" #include "xbm/rcbox.xbm" #include "xbm/freehand.xbm" #include "xbm/vmode.xbm" #include "xbm/rot_mode.xbm" #include "xbm/rot_mode2.xbm" #include "xbm/pat0.xbm" #include "xbm/pat1.xbm" #include "xbm/pat2.xbm" #include "xbm/pat3.xbm" #include "xbm/pat4.xbm" #include "xbm/pat5.xbm" #include "xbm/pat6.xbm" #include "xbm/pat7.xbm" #include "xbm/pat8.xbm" #include "xbm/pat9.xbm" #include "xbm/pat10.xbm" #include "xbm/pat11.xbm" #include "xbm/pat12.xbm" #include "xbm/pat13.xbm" #include "xbm/pat14.xbm" #include "xbm/pat15.xbm" #include "xbm/pat16.xbm" #include "xbm/pat17.xbm" #include "xbm/pat18.xbm" #include "xbm/pat19.xbm" #include "xbm/pat20.xbm" #include "xbm/pat21.xbm" #include "xbm/pat22.xbm" #include "xbm/pat23.xbm" #include "xbm/pat24.xbm" #include "xbm/pat25.xbm" #include "xbm/pat26.xbm" #include "xbm/pat27.xbm" #include "xbm/pat28.xbm" #include "xbm/pat29.xbm" #include "xbm/pat30.xbm" #include "xbm/pat31.xbm" #include "xbm/pat32.xbm" #include "xbm/shape0.xbm" #include "xbm/shape1.xbm" #include "xbm/shape2.xbm" #include "xbm/shape3.xbm" #include "xbm/shape4.xbm" #include "xbm/shape5.xbm" #include "xbm/shape6.xbm" #include "xbm/shape7.xbm" #include "xbm/shape8.xbm" #include "xbm/shape9.xbm" #include "xbm/shape10.xbm" #include "xbm/shape11.xbm" #include "xbm/shape12.xbm" #include "xbm/shape13.xbm" #include "xbm/shape14.xbm" #include "xbm/shape15.xbm" #include "xbm/shape16.xbm" #include "xbm/shape17.xbm" #include "xbm/shape18.xbm" #include "xbm/shape19.xbm" #include "xbm/just_l.xbm" #include "xbm/just_c.xbm" #include "xbm/just_r.xbm" #include "xbm/align_n.xbm" #include "xbm/align_l.xbm" #include "xbm/align_c.xbm" #include "xbm/align_r.xbm" #include "xbm/align_t.xbm" #include "xbm/align_m.xbm" #include "xbm/align_b.xbm" #include "xbm/align_s.xbm" #include "xbm/align_lt.xbm" #include "xbm/align_lm.xbm" #include "xbm/align_lb.xbm" #include "xbm/align_ct.xbm" #include "xbm/align_cm.xbm" #include "xbm/align_cb.xbm" #include "xbm/align_rt.xbm" #include "xbm/align_rm.xbm" #include "xbm/align_rb.xbm" #include "xbm/align_sn.xbm" #include "xbm/align_st.xbm" #include "xbm/align_sm.xbm" #include "xbm/align_sb.xbm" #include "xbm/align_ns.xbm" #include "xbm/align_ls.xbm" #include "xbm/align_cs.xbm" #include "xbm/align_rs.xbm" #include "xbm/align_ss.xbm" #include "xbm/lw0.xbm" #include "xbm/lw1.xbm" #include "xbm/lw2.xbm" #include "xbm/lw3.xbm" #include "xbm/lw4.xbm" #include "xbm/lw5.xbm" #include "xbm/lw6.xbm" #include "xbm/lt0.xbm" #include "xbm/lt1.xbm" #include "xbm/lt2.xbm" #include "xbm/lt3.xbm" #include "xbm/ls0.xbm" #include "xbm/ls1.xbm" #include "xbm/ls2.xbm" #include "xbm/ls3.xbm" #include "xbm/ld0.xbm" #include "xbm/ld1.xbm" #include "xbm/ld2.xbm" #include "xbm/ld3.xbm" #include "xbm/ld4.xbm" #include "xbm/ld5.xbm" #include "xbm/ld6.xbm" #include "xbm/ld7.xbm" #include "xbm/ld8.xbm" #include "xbm/lw0s.xbm" #include "xbm/lw1s.xbm" #include "xbm/lw2s.xbm" #include "xbm/lw3s.xbm" #include "xbm/lw4s.xbm" #include "xbm/lw5s.xbm" #include "xbm/lw6s.xbm" #include "xbm/lt0s.xbm" #include "xbm/lt1s.xbm" #include "xbm/lt2s.xbm" #include "xbm/lt3s.xbm" #include "xbm/ls0s.xbm" #include "xbm/ls1s.xbm" #include "xbm/ls2s.xbm" #include "xbm/ls3s.xbm" #include "xbm/ld0s.xbm" #include "xbm/ld1s.xbm" #include "xbm/ld2s.xbm" #include "xbm/ld3s.xbm" #include "xbm/ld4s.xbm" #include "xbm/ld5s.xbm" #include "xbm/ld6s.xbm" #include "xbm/ld7s.xbm" #include "xbm/ld8s.xbm" #include "xbm/printer.xbm" #include "xbm/latex.xbm" #include "xbm/psfile.xbm" #include "xbm/xbm.xbm" #include "xbm/ascii.xbm" #include "xbm/epsi.xbm" #include "xbm/gif.xbm" #include "xbm/html.xbm" #include "xbm/pdf.xbm" #include "xbm/tiffepsi.xbm" #include "xbm/png.xbm" #include "xbm/jpeg.xbm" #include "xbm/pbm.xbm" #include "xbm/netlist.xbm" #include "xbm/svg.xbm" #include "xbm/file.xbm" #include "xbm/landscap.xbm" #include "xbm/special.xbm" #include "xbm/vspace.xbm" #include "xbm/rcb_rad.xbm" #include "xbm/const_mv.xbm" #include "xbm/uncon_mv.xbm" #include "xbm/edit.xbm" #include "xbm/intr.xbm" #include "xbm/intr90.xbm" #include "xbm/trek.xbm" #include "xbm/stack.xbm" #include "xbm/tile.xbm" #include "xbm/leftend.xbm" #include "xbm/lfarrow.xbm" #include "xbm/rtarrow.xbm" #include "xbm/rightend.xbm" #include "xbm/upend.xbm" #include "xbm/uparrow.xbm" #include "xbm/dnarrow.xbm" #include "xbm/downend.xbm" #include "xbm/chkall.xbm" #include "xbm/unchkall.xbm" #include "xbm/scrl_up.xbm" #include "xbm/scrl_dn.xbm" #include "xbm/scrl_lf.xbm" #include "xbm/scrl_rt.xbm" #include "xbm/stretch.xbm" #include "xbm/nstretch.xbm" #include "xbm/pattrans.xbm" #include "xbm/patopaq.xbm" #include "xbm/rot_0.xbm" #include "xbm/rot_90.xbm" #include "xbm/rot_180.xbm" #include "xbm/rot_270.xbm" #include "xbm/wire.xbm" #include "xbm/run.xbm" #include "xbm/check.xbm" #include "xbm/radio.xbm" #include "xbm/submenu.xbm" #include "xbm/gsubmenu.xbm" #include "xbm/redraw.xbm" #include "xbm/btn1.xbm" #include "xbm/btn2.xbm" #include "xbm/btn3.xbm" #include "xbm/stop.xbm" #include "xbm/question.xbm" #include "xbm/info.xbm" #include "xbm/dialog.xbm" GC rasterGC=NULL; GC patGC=NULL; unsigned long xorOne=0L; unsigned long xorZero=0L; GC drawGC=NULL; GC drawSBGC=NULL; GC defaultGC=NULL; GC revDefaultGC=NULL; GC revGrayGC=NULL; Pixmap rotateModePixmap[2]; Pixmap choicePixmap[MAXCHOICES]; Pixmap patPixmap[MAXPATTERNS+1]; Pixmap *lineWidthPixmap=NULL; Pixmap lineTypePixmap[MAXLINETYPES]; Pixmap lineDashPixmap[MAXDASHES]; Pixmap lineStylePixmap[MAXLINESTYLES]; Pixmap justPixmap[MAXJUSTS]; Pixmap alignHoriPixmap[MAXALIGNS]; Pixmap alignVertPixmap[MAXALIGNS]; Pixmap alignDirectPixmap[(MAXALIGNS-1)*(MAXALIGNS-1)]; Pixmap distrDirectPixmap[MAXALIGNS*MAXALIGNS]; Pixmap *shortLineWidthPixmap=NULL; Pixmap filePixmap=None; Pixmap landscapePixmap=None; Pixmap specialPixmap=None; Pixmap vspacePixmap=None; Pixmap rcbRadiusPixmap=None; Pixmap moveModePixmap[MAXMOVEMODES]; Pixmap editPixmap=None; Pixmap intrPixmap[MAXINTRS]; Pixmap trekPixmap=None; Pixmap pageLayoutPixmap[MAXPAGELAYOUTMODES]; Pixmap scrollPixmap[MAXSCROLLBUTTONS]; Pixmap scrlBitmap[4]; Pixmap shapePixmap[MAXSHAPES]; Pixmap stretchableModePixmap[MAXSTRETCHABLEMODES]; Pixmap transPatPixmap[MAXTRANSPATMODES]; Pixmap rotatePixmap[4]; Pixmap *whereToPrintPixmap=NULL; Pixmap shortLineTypePixmap[MAXLINETYPES]; Pixmap shortLineStylePixmap[MAXLINESTYLES]; Pixmap shortDashPixmap[MAXDASHES]; Pixmap wireBitmap=None; Pixmap runBitmap=None; Pixmap checkBitmap=None; Pixmap radioBitmap=None; Pixmap submenuBitmap=None; Pixmap graySubmenuBitmap=None; Pixmap userRedrawBitmap=None; Pixmap statusBtnPixmap[MAX_STATUS_BTNS]; Pixmap msgBoxPixmap[MAX_MB_ICONS]; int maxLineWidths=MAXLINEWIDTHS; int maxWhereToPrint=MAXDEFWHERETOPRINT; int dashListLength[MAXDASHES] = { 0, 2, 2, 2, 4, 2, 6, 2, 2 }; char *dashList[MAXDASHES] = {"","\004\014","\010\010","\014\004","\024\004\004\004", "\004\004","\014\004\004\004\004\004","\020\020","\002\002"}; static int pat_w[MAXPATTERNS+1], pat_h[MAXPATTERNS+1]; static int shape_w[MAXSHAPES+1], shape_h[MAXSHAPES+1]; static unsigned char *patData[MAXPATTERNS+1]; static int needToFreePat[MAXPATTERNS+1]; static unsigned char *shapeData[MAXSHAPES+1]; static int newLineWidthAllocated=FALSE; static Pixmap defaultLineWidthPixmap[MAXLINEWIDTHS]; static Pixmap defaultShortLineWidthPixmap[MAXLINEWIDTHS]; static void InitLines() { int i, j, y, short_y, len, x; char *c_ptr, buf[80], s[MAXSTRING]; XGCValues values; GC tmp_gc, tmp_rev_gc; Pixmap dummy_pixmap; newLineWidthAllocated = FALSE; maxLineWidths = MAXLINEWIDTHS; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "MaxLineWidths")) != NULL) { maxLineWidths = atoi(c_ptr); if (maxLineWidths <= 0) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "MaxLineWidths", c_ptr, MAXLINEWIDTHS); maxLineWidths = MAXLINEWIDTHS; } } curWidthOfLine = (short*)malloc(maxLineWidths*sizeof(short)); curArrowHeadW = (short*)malloc(maxLineWidths*sizeof(short)); curArrowHeadH = (short*)malloc(maxLineWidths*sizeof(short)); curWidthOfLineSpec = (char**)malloc(maxLineWidths*sizeof(char*)); curArrowHeadWSpec = (char**)malloc(maxLineWidths*sizeof(char*)); curArrowHeadHSpec = (char**)malloc(maxLineWidths*sizeof(char*)); memset(curWidthOfLineSpec, 0, sizeof(maxLineWidths*sizeof(char*))); memset(curArrowHeadWSpec, 0, sizeof(maxLineWidths*sizeof(char*))); memset(curArrowHeadHSpec, 0, sizeof(maxLineWidths*sizeof(char*))); *buf = '\0'; for (i = 0; i < maxLineWidths; i++) { float fval; char *sval; sprintf(buf, "LineWidth%1d", i); if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, buf)) != NULL) { strcpy(gszMsgBox, c_ptr); sval = strtok(gszMsgBox, ", \t\n\r"); if (sval == NULL) break; if (sscanf(sval, "%f", &fval) != 1) break; curWidthOfLine[i] = round(fval); curWidthOfLineSpec[i] = UtilStrDup(sval); } else if (i < MAXLINEWIDTHS) { curWidthOfLine[i] = origWidthOfLine[i]; sprintf(gszMsgBox, "%1d", curWidthOfLine[i]); curWidthOfLineSpec[i] = UtilStrDup(gszMsgBox); } else { break; } sprintf(buf, "ArrowWidth%1d", i); if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, buf)) != NULL) { strcpy(gszMsgBox, c_ptr); sval = strtok(gszMsgBox, ", \t\n\r"); if (sval == NULL) break; if (sscanf(sval, "%f", &fval) != 1) break; curArrowHeadW[i] = round(fval); curArrowHeadWSpec[i] = UtilStrDup(sval); } else if (i < MAXLINEWIDTHS) { curArrowHeadW[i] = origArrowHeadW[i]; sprintf(gszMsgBox, "%1d", curArrowHeadW[i]); curArrowHeadWSpec[i] = UtilStrDup(gszMsgBox); } else { break; } sprintf(buf, "ArrowHeight%1d", i); if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, buf)) != NULL) { strcpy(gszMsgBox, c_ptr); sval = strtok(gszMsgBox, ", \t\n\r"); if (sval == NULL) break; if (sscanf(sval, "%f", &fval) != 1) break; curArrowHeadH[i] = round(fval); curArrowHeadHSpec[i] = UtilStrDup(sval); } else if (i < MAXLINEWIDTHS) { curArrowHeadH[i] = origArrowHeadH[i]; sprintf(gszMsgBox, "%1d", curArrowHeadH[i]); curArrowHeadHSpec[i] = UtilStrDup(gszMsgBox); } else { break; } } if (i != maxLineWidths) { fprintf(stderr, TgLoadString(STID_CANT_GET_XDEF_DEF_WIDTHS_USED), TOOL_NAME, buf); fprintf(stderr, "\n"); free(curWidthOfLine); free(curArrowHeadW); free(curArrowHeadH); for (j=0; j < i; j++) { if (curWidthOfLineSpec[j] != NULL) free(curWidthOfLineSpec[j]); if (curArrowHeadWSpec[j] != NULL) free(curArrowHeadWSpec[j]); if (curArrowHeadHSpec[j] != NULL) free(curArrowHeadHSpec[j]); } free(curWidthOfLine); free(curArrowHeadW); free(curArrowHeadH); } else { y = HALF_W(menuImageH); short_y = HALF_W(choiceImageH); lineWidthPixmap = (Pixmap*)malloc(maxLineWidths*sizeof(Pixmap)); if (lineWidthPixmap == NULL) FailAllocMessage(); shortLineWidthPixmap = (Pixmap*)malloc(maxLineWidths*sizeof(Pixmap)); if (shortLineWidthPixmap == NULL) FailAllocMessage(); dummy_pixmap = XCreatePixmap(mainDisplay, mainWindow, 1, 1, 1); values.foreground = 1; values.background = 0; values.fill_style = FillSolid; values.function = GXcopy; values.font = rulerFontPtr->fid; tmp_gc = XCreateGC(mainDisplay, dummy_pixmap, GCForeground | GCBackground | GCFillStyle | GCFunction | GCFont, &values); values.foreground = 0; tmp_rev_gc = XCreateGC(mainDisplay, dummy_pixmap, GCForeground | GCBackground | GCFillStyle | GCFunction | GCFont, &values); for (i = 0; i < maxLineWidths; i++) { lineWidthPixmap[i] = XCreatePixmap(mainDisplay, mainWindow, menuImageW, menuImageH, 1); shortLineWidthPixmap[i] = XCreatePixmap(mainDisplay, mainWindow, choiceImageW, choiceImageH, 1); XFillRectangle(mainDisplay, lineWidthPixmap[i], tmp_rev_gc, 0, 0, menuImageW, menuImageH); XFillRectangle(mainDisplay, shortLineWidthPixmap[i], tmp_rev_gc, 0, 0, choiceImageW, choiceImageH); values.line_width = curWidthOfLine[i]; #ifdef NO_THIN_LINE if (values.line_width < 1) values.line_width = 1; #endif XChangeGC(mainDisplay, tmp_gc, GCLineWidth, &values); XDrawLine(mainDisplay, lineWidthPixmap[i], tmp_gc, 4, y, menuImageW-4, y); XDrawLine(mainDisplay, shortLineWidthPixmap[i], tmp_gc, 4, short_y, choiceImageW-4, short_y); sprintf(s, "%1d", curWidthOfLine[i]); len = strlen(s); x = HALF_W(menuImageW-len*rulerFontWidth); if (curWidthOfLine[i] > menuImageH-4) { XDrawString(mainDisplay, lineWidthPixmap[i], tmp_rev_gc, x, y+HALF_W(rulerFontHeight)-rulerFontDes, s, len); } x = HALF_W(choiceImageW-len*rulerFontWidth); if (curWidthOfLine[i] > choiceImageH-4) { XDrawString(mainDisplay, shortLineWidthPixmap[i], tmp_rev_gc, x, y+HALF_W(rulerFontHeight)-rulerFontDes, s, len); } } XFreeGC(mainDisplay, tmp_gc); XFreeGC(mainDisplay, tmp_rev_gc); XFreePixmap(mainDisplay, dummy_pixmap); newLineWidthAllocated = TRUE; } if (!newLineWidthAllocated) { maxLineWidths = MAXLINEWIDTHS; curWidthOfLine = (short*)malloc(maxLineWidths*sizeof(short)); curArrowHeadW = (short*)malloc(maxLineWidths*sizeof(short)); curArrowHeadH = (short*)malloc(maxLineWidths*sizeof(short)); curWidthOfLineSpec = (char**)malloc(maxLineWidths*sizeof(char*)); curArrowHeadWSpec = (char**)malloc(maxLineWidths*sizeof(char*)); curArrowHeadHSpec = (char**)malloc(maxLineWidths*sizeof(char*)); memset(curWidthOfLineSpec, 0, sizeof(maxLineWidths*sizeof(char*))); memset(curArrowHeadWSpec, 0, sizeof(maxLineWidths*sizeof(char*))); memset(curArrowHeadHSpec, 0, sizeof(maxLineWidths*sizeof(char*))); lineWidthPixmap = (Pixmap*)malloc(maxLineWidths*sizeof(Pixmap)); if (lineWidthPixmap == NULL) FailAllocMessage(); shortLineWidthPixmap = (Pixmap*)malloc(maxLineWidths*sizeof(Pixmap)); if (shortLineWidthPixmap == NULL) FailAllocMessage(); for (i = 0; i < maxLineWidths; i++) { curWidthOfLine[i] = origWidthOfLine[i]; curArrowHeadW[i] = origArrowHeadW[i]; curArrowHeadH[i] = origArrowHeadH[i]; lineWidthPixmap[i] = defaultLineWidthPixmap[i]; shortLineWidthPixmap[i] = defaultShortLineWidthPixmap[i]; sprintf(gszMsgBox, "%1d", curWidthOfLine[i]); curWidthOfLineSpec[i] = UtilStrDup(gszMsgBox); sprintf(gszMsgBox, "%s", curArrowHeadWSpec[i]); curArrowHeadWSpec[i] = UtilStrDup(gszMsgBox); sprintf(gszMsgBox, "%s", curArrowHeadHSpec[i]); curArrowHeadHSpec[i] = UtilStrDup(gszMsgBox); } } lineWidth = 0; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DefaultLineWidth"))!=NULL) { lineWidth = atoi(c_ptr); if (lineWidth < 0 || lineWidth >= maxLineWidths) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "DefaultLineWidth", c_ptr, 0); } } } static void SetCustomPatDir() { *customPatDir = '\0'; if (*cmdLineCustomPatternDir != '\0') { UtilStrCpyN(customPatDir, sizeof(customPatDir), cmdLineCustomPatternDir); } else if (!PRTGIF || cmdLineOpenDisplay) { char *c_ptr=NULL; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"CustomPatternDir"))!=NULL) { if (c_ptr != NULL && *c_ptr != '\0' && UtilIsDirectory(c_ptr)) { int len=0; UtilStrCpyN(customPatDir, sizeof(customPatDir), c_ptr); len = strlen(customPatDir); if (len > 0 && customPatDir[len-1] == DIR_SEP) { customPatDir[len-1] = '\0'; } } } } } void InitPatFill() { register int i; pat_w[0] = pat0_width; pat_h[0] = pat0_height; patData[0] = pat0_bits; pat_w[1] = pat1_width; pat_h[1] = pat1_height; patData[1] = pat1_bits; pat_w[2] = pat2_width; pat_h[2] = pat2_height; patData[2] = pat2_bits; pat_w[3] = pat3_width; pat_h[3] = pat3_height; patData[3] = pat3_bits; pat_w[4] = pat4_width; pat_h[4] = pat4_height; patData[4] = pat4_bits; pat_w[5] = pat5_width; pat_h[5] = pat5_height; patData[5] = pat5_bits; pat_w[6] = pat6_width; pat_h[6] = pat6_height; patData[6] = pat6_bits; pat_w[7] = pat7_width; pat_h[7] = pat7_height; patData[7] = pat7_bits; pat_w[8] = pat8_width; pat_h[8] = pat8_height; patData[8] = pat8_bits; pat_w[9] = pat9_width; pat_h[9] = pat9_height; patData[9] = pat9_bits; pat_w[10] = pat10_width; pat_h[10] = pat10_height; patData[10] = pat10_bits; pat_w[11] = pat11_width; pat_h[11] = pat11_height; patData[11] = pat11_bits; pat_w[12] = pat12_width; pat_h[12] = pat12_height; patData[12] = pat12_bits; pat_w[13] = pat13_width; pat_h[13] = pat13_height; patData[13] = pat13_bits; pat_w[14] = pat14_width; pat_h[14] = pat14_height; patData[14] = pat14_bits; pat_w[15] = pat15_width; pat_h[15] = pat15_height; patData[15] = pat15_bits; pat_w[16] = pat16_width; pat_h[16] = pat16_height; patData[16] = pat16_bits; pat_w[17] = pat17_width; pat_h[17] = pat17_height; patData[17] = pat17_bits; pat_w[18] = pat18_width; pat_h[18] = pat18_height; patData[18] = pat18_bits; pat_w[19] = pat19_width; pat_h[19] = pat19_height; patData[19] = pat19_bits; pat_w[20] = pat20_width; pat_h[20] = pat20_height; patData[20] = pat20_bits; pat_w[21] = pat21_width; pat_h[21] = pat21_height; patData[21] = pat21_bits; pat_w[22] = pat22_width; pat_h[22] = pat22_height; patData[22] = pat22_bits; pat_w[23] = pat23_width; pat_h[23] = pat23_height; patData[23] = pat23_bits; pat_w[24] = pat24_width; pat_h[24] = pat24_height; patData[24] = pat24_bits; pat_w[25] = pat25_width; pat_h[25] = pat25_height; patData[25] = pat25_bits; pat_w[26] = pat26_width; pat_h[26] = pat26_height; patData[26] = pat26_bits; pat_w[27] = pat27_width; pat_h[27] = pat27_height; patData[27] = pat27_bits; pat_w[28] = pat28_width; pat_h[28] = pat28_height; patData[28] = pat28_bits; pat_w[29] = pat29_width; pat_h[29] = pat29_height; patData[29] = pat29_bits; pat_w[30] = pat30_width; pat_h[30] = pat30_height; patData[30] = pat30_bits; pat_w[31] = pat31_width; pat_h[31] = pat31_height; patData[31] = pat31_bits; pat_w[32] = pat32_width; pat_h[32] = pat32_height; patData[32] = pat32_bits; for (i=0; i < MAXPATTERNS+1; i++) { needToFreePat[i] = FALSE; } } static int gnPatFillInitialized=FALSE; void Init2PatFill() { register int i; if (gnPatFillInitialized) return; SetCustomPatDir(); for (i=3; i < MAXPATTERNS+1; i++) { if (*customPatDir != '\0') { unsigned int w_return=0, h_return=0; int x_hot=0, y_hot=0; unsigned char *data_return=NULL; char path[MAXPATHLENGTH<<1]; snprintf(path, sizeof(path), "%s%cpat%1d.xbm", customPatDir, DIR_SEP, i); if (UtilPathExists(path)) { if (XReadBitmapFileData(path, &w_return, &h_return, &data_return, &x_hot, &y_hot) == BitmapSuccess) { pat_w[i] = w_return; pat_h[i] = h_return; patData[i] = data_return; needToFreePat[i] = TRUE; } else { fprintf(stderr, TgLoadString(STID_INVALID_XBM_CUST_PAT), path); fprintf(stderr, "\n"); } } } } gnPatFillInitialized = TRUE; } void InitPattern() { register int i; XGCValues values; values.foreground = myFgPixel; values.background = (threeDLook ? myLtGryPixel : myBgPixel); values.fill_style = FillOpaqueStippled; rasterGC = XCreateGC(mainDisplay, mainWindow, GCForeground | GCBackground | GCFillStyle, &values); values.fill_style = FillOpaqueStippled; patGC = XCreateGC(mainDisplay, mainWindow, GCForeground | GCBackground | GCFillStyle, &values); values.background = myBgPixel; values.graphics_exposures = False; drawGC = XCreateGC(mainDisplay, mainWindow, GCBackground | GCGraphicsExposures, &values); drawSBGC = XCreateGC(mainDisplay, mainWindow, GCBackground | GCGraphicsExposures, &values); values.background = (threeDLook ? myLtGryPixel : myBgPixel); values.font = defaultFontPtr->fid; values.line_width = 1; defaultGC = XCreateGC(mainDisplay, mainWindow, GCForeground | GCBackground | GCFont | GCLineWidth, &values); values.foreground = xorOne; values.background = xorZero; values.function = GXxor; values.fill_style = FillSolid; revDefaultGC = XCreateGC(mainDisplay, mainWindow, GCForeground | GCBackground | GCFunction | GCFillStyle | GCFont, &values); InitPatFill(); Init2PatFill(); for (i = 0; i < MAXPATTERNS+1; i++) { patPixmap[i] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)patData[i], pat_w[i], pat_h[i]); } values.foreground = xorOne; values.background = xorZero; values.function = GXxor; values.line_width = 1; values.fill_style = FillStippled; values.stipple = patPixmap[SCROLLPAT]; revGrayGC = XCreateGC(mainDisplay, mainWindow, GCForeground | GCBackground | GCFunction | GCLineWidth | GCFillStyle | GCStipple, &values); justPixmap[JUST_L] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)just_l_bits, just_l_width, just_l_height); justPixmap[JUST_C] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)just_c_bits, just_c_width, just_c_height); justPixmap[JUST_R] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)just_r_bits, just_r_width, just_r_height); alignHoriPixmap[ALIGN_N] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_n_bits, align_n_width, align_n_height); alignHoriPixmap[ALIGN_L] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_l_bits, align_l_width, align_l_height); alignHoriPixmap[ALIGN_C] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_c_bits, align_c_width, align_c_height); alignHoriPixmap[ALIGN_R] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_r_bits, align_r_width, align_r_height); alignHoriPixmap[ALIGN_S] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_s_bits, align_s_width, align_s_height); alignVertPixmap[ALIGN_N] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_n_bits, align_n_width, align_n_height); alignVertPixmap[ALIGN_T] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_t_bits, align_t_width, align_t_height); alignVertPixmap[ALIGN_M] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_m_bits, align_m_width, align_m_height); alignVertPixmap[ALIGN_B] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_b_bits, align_b_width, align_b_height); alignVertPixmap[ALIGN_S] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_s_bits, align_s_width, align_s_height); distrDirectPixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)patData[0], pat_w[0], pat_h[0]); distrDirectPixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_t_bits, align_t_width, align_t_height); distrDirectPixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_m_bits, align_m_width, align_m_height); distrDirectPixmap[3] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_b_bits, align_b_width, align_b_height); distrDirectPixmap[4] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_ns_bits, align_ns_width, align_ns_height); distrDirectPixmap[5] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_l_bits, align_l_width, align_l_height); distrDirectPixmap[6] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_lt_bits, align_lt_width, align_lt_height); distrDirectPixmap[7] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_lm_bits, align_lm_width, align_lm_height); distrDirectPixmap[8] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_lb_bits, align_lb_width, align_lb_height); distrDirectPixmap[9] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_ls_bits, align_ls_width, align_ls_height); distrDirectPixmap[10] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_c_bits, align_c_width, align_c_height); distrDirectPixmap[11] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_ct_bits, align_ct_width, align_ct_height); distrDirectPixmap[12] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_cm_bits, align_cm_width, align_cm_height); distrDirectPixmap[13] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_cb_bits, align_cb_width, align_cb_height); distrDirectPixmap[14] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_cs_bits, align_cs_width, align_cs_height); distrDirectPixmap[15] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_r_bits, align_r_width, align_r_height); distrDirectPixmap[16] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_rt_bits, align_rt_width, align_rt_height); distrDirectPixmap[17] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_rm_bits, align_rm_width, align_rm_height); distrDirectPixmap[18] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_rb_bits, align_rb_width, align_rb_height); distrDirectPixmap[19] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_rs_bits, align_rs_width, align_rs_height); distrDirectPixmap[20] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_sn_bits, align_sn_width, align_sn_height); distrDirectPixmap[21] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_st_bits, align_st_width, align_st_height); distrDirectPixmap[22] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_sm_bits, align_sm_width, align_sm_height); distrDirectPixmap[23] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_sb_bits, align_sb_width, align_sb_height); distrDirectPixmap[24] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)align_ss_bits, align_ss_width, align_ss_height); alignDirectPixmap[0] = distrDirectPixmap[0]; alignDirectPixmap[1] = distrDirectPixmap[1]; alignDirectPixmap[2] = distrDirectPixmap[2]; alignDirectPixmap[3] = distrDirectPixmap[3]; alignDirectPixmap[4] = distrDirectPixmap[5]; alignDirectPixmap[5] = distrDirectPixmap[6]; alignDirectPixmap[6] = distrDirectPixmap[7]; alignDirectPixmap[7] = distrDirectPixmap[8]; alignDirectPixmap[8] = distrDirectPixmap[10]; alignDirectPixmap[9] = distrDirectPixmap[11]; alignDirectPixmap[10] = distrDirectPixmap[12]; alignDirectPixmap[11] = distrDirectPixmap[13]; alignDirectPixmap[12] = distrDirectPixmap[15]; alignDirectPixmap[13] = distrDirectPixmap[16]; alignDirectPixmap[14] = distrDirectPixmap[17]; alignDirectPixmap[15] = distrDirectPixmap[18]; defaultLineWidthPixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw0_bits, lw0_width, lw0_height); defaultLineWidthPixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw1_bits, lw1_width, lw1_height); defaultLineWidthPixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw2_bits, lw2_width, lw2_height); defaultLineWidthPixmap[3] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw3_bits, lw3_width, lw3_height); defaultLineWidthPixmap[4] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw4_bits, lw4_width, lw4_height); defaultLineWidthPixmap[5] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw5_bits, lw5_width, lw5_height); defaultLineWidthPixmap[6] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw6_bits, lw6_width, lw6_height); lineStylePixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ls0_bits, ls0_width, ls0_height); lineStylePixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ls1_bits, ls1_width, ls1_height); lineStylePixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ls2_bits, ls2_width, ls2_height); lineStylePixmap[3] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ls3_bits, ls3_width, ls3_height); lineTypePixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lt0_bits, lt0_width, lt0_height); lineTypePixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lt1_bits, lt1_width, lt1_height); lineTypePixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lt2_bits, lt2_width, lt2_height); lineTypePixmap[3] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lt3_bits, lt3_width, lt3_height); lineDashPixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld0_bits, ld0_width, ld0_height); lineDashPixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld1_bits, ld1_width, ld1_height); lineDashPixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld2_bits, ld2_width, ld2_height); lineDashPixmap[3] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld3_bits, ld3_width, ld3_height); lineDashPixmap[4] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld4_bits, ld4_width, ld4_height); lineDashPixmap[5] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld5_bits, ld5_width, ld5_height); lineDashPixmap[6] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld6_bits, ld6_width, ld6_height); lineDashPixmap[7] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld7_bits, ld7_width, ld7_height); lineDashPixmap[8] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld8_bits, ld8_width, ld8_height); shortLineStylePixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ls0s_bits, ls0s_width, ls0s_height); shortLineStylePixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ls1s_bits, ls1s_width, ls1s_height); shortLineStylePixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ls2s_bits, ls2s_width, ls2s_height); shortLineStylePixmap[3] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ls3s_bits, ls3s_width, ls3s_height); filePixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)file_bits, file_width, file_height); landscapePixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)landscap_bits, landscap_width, landscap_height); specialPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)special_bits, special_width, special_height); vspacePixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)vspace_bits, vspace_width, vspace_height); rcbRadiusPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)rcb_rad_bits, rcb_rad_width, rcb_rad_height); moveModePixmap[CONST_MOVE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)const_mv_bits, const_mv_width, const_mv_height); moveModePixmap[UNCONST_MOVE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)uncon_mv_bits, uncon_mv_width, uncon_mv_height); editPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)edit_bits, edit_width, edit_height); intrPixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)intr_bits, intr_width, intr_height); intrPixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)intr90_bits, intr90_width, intr90_height); trekPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)trek_bits, trek_width, trek_height); pageLayoutPixmap[PAGE_STACK] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)stack_bits, stack_width, stack_height); pageLayoutPixmap[PAGE_TILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)tile_bits, tile_width, tile_height); scrollPixmap[SCROLL_LEFTEND] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)leftend_bits, leftend_width, leftend_height); scrollPixmap[SCROLL_LEFT] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lfarrow_bits, lfarrow_width, lfarrow_height); scrollPixmap[SCROLL_RIGHT] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)rtarrow_bits, rtarrow_width, rtarrow_height); scrollPixmap[SCROLL_RIGHTEND] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)rightend_bits, rightend_width, rightend_height); scrollPixmap[SCROLL_UPEND] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)upend_bits, upend_width, upend_height); scrollPixmap[SCROLL_UP] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)uparrow_bits, uparrow_width, uparrow_height); scrollPixmap[SCROLL_CHECKALL] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)chkall_bits, chkall_width, chkall_height); scrollPixmap[SCROLL_UNCHECKALL] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)unchkall_bits, unchkall_width, unchkall_height); scrollPixmap[SCROLL_DOWN] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)dnarrow_bits, dnarrow_width, dnarrow_height); scrollPixmap[SCROLL_DOWNEND] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)downend_bits, downend_width, downend_height); scrlBitmap[SCRL_UP] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)scrl_up_bits, scrl_up_width, scrl_up_height); scrlBitmap[SCRL_DN] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)scrl_dn_bits, scrl_dn_width, scrl_dn_height); scrlBitmap[SCRL_LF] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)scrl_lf_bits, scrl_lf_width, scrl_lf_height); scrlBitmap[SCRL_RT] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)scrl_rt_bits, scrl_rt_width, scrl_rt_height); shape_w[0] = shape0_width; shape_h[0] = shape0_height; shapeData[0] = shape0_bits; shape_w[1] = shape1_width; shape_h[1] = shape1_height; shapeData[1] = shape1_bits; shape_w[2] = shape2_width; shape_h[2] = shape2_height; shapeData[2] = shape2_bits; shape_w[3] = shape3_width; shape_h[3] = shape3_height; shapeData[3] = shape3_bits; shape_w[4] = shape4_width; shape_h[4] = shape4_height; shapeData[4] = shape4_bits; shape_w[5] = shape5_width; shape_h[5] = shape5_height; shapeData[5] = shape5_bits; shape_w[6] = shape6_width; shape_h[6] = shape6_height; shapeData[6] = shape6_bits; shape_w[7] = shape7_width; shape_h[7] = shape7_height; shapeData[7] = shape7_bits; shape_w[8] = shape8_width; shape_h[8] = shape8_height; shapeData[8] = shape8_bits; shape_w[9] = shape9_width; shape_h[9] = shape9_height; shapeData[9] = shape9_bits; shape_w[10] = shape10_width; shape_h[10] = shape10_height; shapeData[10] = shape10_bits; shape_w[11] = shape11_width; shape_h[11] = shape11_height; shapeData[11] = shape11_bits; shape_w[12] = shape12_width; shape_h[12] = shape12_height; shapeData[12] = shape12_bits; shape_w[13] = shape13_width; shape_h[13] = shape13_height; shapeData[13] = shape13_bits; shape_w[14] = shape14_width; shape_h[14] = shape14_height; shapeData[14] = shape14_bits; shape_w[15] = shape15_width; shape_h[15] = shape15_height; shapeData[15] = shape15_bits; shape_w[16] = shape16_width; shape_h[16] = shape16_height; shapeData[16] = shape16_bits; shape_w[17] = shape17_width; shape_h[17] = shape17_height; shapeData[17] = shape17_bits; shape_w[18] = shape18_width; shape_h[18] = shape18_height; shapeData[18] = shape18_bits; shape_w[19] = shape19_width; shape_h[19] = shape19_height; shapeData[19] = shape19_bits; for (i=0; i < MAXSHAPES; i++) { shapePixmap[i] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)shapeData[i], shape_w[i], shape_h[i]); } stretchableModePixmap[NO_STRETCHABLE_TEXT] = XCreateBitmapFromData( mainDisplay, mainWindow, (char *)nstretch_bits, nstretch_width, nstretch_height); stretchableModePixmap[STRETCHABLE_TEXT] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)stretch_bits, stretch_width, stretch_height); transPatPixmap[NO_TRANSPAT_MODE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)patopaq_bits, patopaq_width, patopaq_height); transPatPixmap[TRANSPAT_MODE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)pattrans_bits, pattrans_width, pattrans_height); rotatePixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)rot_0_bits, rot_0_width, rot_0_height); rotatePixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)rot_90_bits, rot_90_width, rot_90_height); rotatePixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)rot_180_bits, rot_180_width, rot_180_height); rotatePixmap[3] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)rot_270_bits, rot_270_width, rot_270_height); whereToPrintPixmap = (Pixmap*)malloc(MAXDEFWHERETOPRINT*sizeof(Pixmap)); if (whereToPrintPixmap == NULL) FailAllocMessage(); whereToPrintPixmap[PRINTER] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)printer_bits, printer_width, printer_height); whereToPrintPixmap[LATEX_FIG] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)latex_bits, latex_width, latex_height); whereToPrintPixmap[PS_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)psfile_bits, psfile_width, psfile_height); whereToPrintPixmap[XBM_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)xbm_bits, xbm_width, xbm_height); whereToPrintPixmap[TEXT_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ascii_bits, ascii_width, ascii_height); whereToPrintPixmap[EPSI_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)epsi_bits, epsi_width, epsi_height); whereToPrintPixmap[GIF_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)gif_bits, gif_width, gif_height); whereToPrintPixmap[HTML_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)html_bits, html_width, html_height); whereToPrintPixmap[PDF_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)pdf_bits, pdf_width, pdf_height); whereToPrintPixmap[TIFFEPSI_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)tiffepsi_bits, tiffepsi_width, tiffepsi_height); whereToPrintPixmap[PNG_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)png_bits, png_width, png_height); whereToPrintPixmap[JPEG_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)jpeg_bits, jpeg_width, jpeg_height); whereToPrintPixmap[PPM_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)pbm_bits, pbm_width, pbm_height); whereToPrintPixmap[NETLIST_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)netlist_bits, netlist_width, netlist_height); whereToPrintPixmap[SVG_FILE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)svg_bits, svg_width, svg_height); shortLineTypePixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lt0s_bits, lt0s_width, lt0s_height); shortLineTypePixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lt1s_bits, lt1s_width, lt1s_height); shortLineTypePixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lt2s_bits, lt2s_width, lt2s_height); shortLineTypePixmap[3] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lt3s_bits, lt3s_width, lt3s_height); shortDashPixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld0s_bits, ld0s_width, ld0s_height); shortDashPixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld1s_bits, ld1s_width, ld1s_height); shortDashPixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld2s_bits, ld2s_width, ld2s_height); shortDashPixmap[3] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld3s_bits, ld3s_width, ld3s_height); shortDashPixmap[4] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld4s_bits, ld4s_width, ld4s_height); shortDashPixmap[5] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld5s_bits, ld5s_width, ld5s_height); shortDashPixmap[6] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld6s_bits, ld6s_width, ld6s_height); shortDashPixmap[7] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld7s_bits, ld7s_width, ld7s_height); shortDashPixmap[8] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ld8s_bits, ld8s_width, ld8s_height); defaultShortLineWidthPixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw0s_bits, lw0s_width, lw0s_height); defaultShortLineWidthPixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw1s_bits, lw1s_width, lw1s_height); defaultShortLineWidthPixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw2s_bits, lw2s_width, lw2s_height); defaultShortLineWidthPixmap[3] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw3s_bits, lw3s_width, lw3s_height); defaultShortLineWidthPixmap[4] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw4s_bits, lw4s_width, lw4s_height); defaultShortLineWidthPixmap[5] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw5s_bits, lw5s_width, lw5s_height); defaultShortLineWidthPixmap[6] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)lw6s_bits, lw6s_width, lw6s_height); rotateModePixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)rot_mode_bits, rot_mode_width, rot_mode_height); rotateModePixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)rot_mode2_bits, rot_mode2_width, rot_mode2_height); choicePixmap[NOTHING] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)arrow_bits, arrow_width, arrow_height); choicePixmap[DRAWTEXT] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)text_bits, text_width, text_height); choicePixmap[DRAWBOX] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)box_bits, box_width, box_height); choicePixmap[DRAWCORNEROVAL] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)oval_bits, oval_width, oval_height); choicePixmap[DRAWCENTEROVAL] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ovalcent_bits, ovalcent_width, ovalcent_height); choicePixmap[DRAWEDGECIRCLE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)ovaledge_bits, ovaledge_width, ovaledge_height); choicePixmap[DRAWPOLY] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)poly_bits, poly_width, poly_height); choicePixmap[DRAWPOLYGON] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)polygon_bits, polygon_width, polygon_height); choicePixmap[DRAWARC] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)arc_bits, arc_width, arc_height); choicePixmap[DRAWEDGEARC] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)arc_edge_bits, arc_edge_width, arc_edge_height); choicePixmap[DRAWRCBOX] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)rcbox_bits, rcbox_width, rcbox_height); choicePixmap[FREEHAND] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)freehand_bits, freehand_width, freehand_height); choicePixmap[VERTEXMODE] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)vmode_bits, vmode_width, vmode_height); choicePixmap[ROTATEMODE] = rotateModePixmap[1]; wireBitmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)wire_bits, wire_width, wire_height); runBitmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)run_bits, run_width, run_height); checkBitmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)check_bits, check_width, check_height); radioBitmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)radio_bits, radio_width, radio_height); submenuBitmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)submenu_bits, submenu_width, submenu_height); graySubmenuBitmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)gsubmenu_bits, gsubmenu_width, gsubmenu_height); userRedrawBitmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)redraw_bits, redraw_width, redraw_height); statusBtnPixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)btn1_bits, btn1_width, btn1_height); statusBtnPixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)btn2_bits, btn2_width, btn2_height); statusBtnPixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)btn3_bits, btn3_width, btn3_height); msgBoxPixmap[0] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)stop_bits, stop_width, stop_height); msgBoxPixmap[1] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)question_bits, question_width, question_height); msgBoxPixmap[2] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)info_bits, info_width, info_height); msgBoxPixmap[3] = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)dialog_bits, dialog_width, dialog_height); InitLines(); } void RedrawChoiceWindow() { if (threeDLook) { struct BBRec bbox; bbox.ltx = 0; bbox.lty = 0; bbox.rbx = choiceWindowW; bbox.rby = choiceWindowH; TgDrawThreeDButton(mainDisplay, choiceWindow, textMenuGC, &bbox, TGBS_RAISED, 1, FALSE); } ShowColor(FALSE); ShowFile(); ShowWhereToPrint(); ShowHoriAlign(); ShowVertAlign(); ShowRotate(); ShowMoveMode(); ShowRCBRadius(); ShowZoom(); ShowJust(); ShowCurFont(); ShowTextSize(); ShowTextVSpace(); ShowShape(); ShowStretchableTextMode(); ShowLineWidth(); ShowLineStyle(); ShowLineType(); ShowDash(); ShowFill(); ShowTransPatMode(); ShowPen(); ShowPage(); ShowPageLayout(); } void CleanUpPatFill() { register int i; if (!gnPatFillInitialized) return; for (i = 0; i < MAXPATTERNS+1; i++) { if (needToFreePat[i]) { XFree(patData[i]); } } gnPatFillInitialized = FALSE; } void CleanUpRasters() { register int i; CleanUpPatFill(); XFreePixmap(mainDisplay, rotateModePixmap[0]); XFreePixmap(mainDisplay, rotateModePixmap[1]); for (i = 0; i < MAXCHOICES-1; i++) XFreePixmap(mainDisplay, choicePixmap[i]); for (i = 0; i < MAXPATTERNS+1; i++) XFreePixmap(mainDisplay, patPixmap[i]); for (i = 0; i < MAXLINEWIDTHS; i++) { XFreePixmap(mainDisplay, defaultLineWidthPixmap[i]); } for (i = 0; i < MAXLINESTYLES; i++) { XFreePixmap(mainDisplay, lineStylePixmap[i]); } for (i = 0; i < MAXLINETYPES; i++) { XFreePixmap(mainDisplay, lineTypePixmap[i]); } for (i = 0; i < MAXDASHES; i++) { XFreePixmap(mainDisplay, lineDashPixmap[i]); } for (i = 0; i < MAXJUSTS; i++) XFreePixmap(mainDisplay, justPixmap[i]); for (i = 0; i < MAXALIGNS; i++) { XFreePixmap(mainDisplay, alignHoriPixmap[i]); } for (i = 0; i < MAXALIGNS; i++) { XFreePixmap(mainDisplay, alignVertPixmap[i]); } for (i = 0; i < MAXALIGNS*MAXALIGNS; i++) { XFreePixmap(mainDisplay, distrDirectPixmap[i]); } for (i = 0; i < MAXLINEWIDTHS; i++) { XFreePixmap(mainDisplay, defaultShortLineWidthPixmap[i]); } XFreePixmap(mainDisplay, filePixmap); XFreePixmap(mainDisplay, landscapePixmap); XFreePixmap(mainDisplay, specialPixmap); XFreePixmap(mainDisplay, vspacePixmap); XFreePixmap(mainDisplay, rcbRadiusPixmap); for (i = 0; i < MAXMOVEMODES; i++) { XFreePixmap(mainDisplay, moveModePixmap[i]); } XFreePixmap(mainDisplay, editPixmap); for (i = 0; i < MAXINTRS; i++) { XFreePixmap(mainDisplay, intrPixmap[i]); } XFreePixmap(mainDisplay, trekPixmap); for (i = 0; i < MAXPAGELAYOUTMODES; i++) { XFreePixmap(mainDisplay, pageLayoutPixmap[i]); } for (i = 0; i < MAXSCROLLBUTTONS; i++) { XFreePixmap(mainDisplay, scrollPixmap[i]); } for (i = 0; i < 4; i++) { XFreePixmap(mainDisplay, scrlBitmap[i]); } for (i = 0; i < MAXSHAPES; i++) { XFreePixmap(mainDisplay, shapePixmap[i]); } for (i = 0; i < MAXSTRETCHABLEMODES; i++) { XFreePixmap(mainDisplay, stretchableModePixmap[i]); } for (i = 0; i < MAXTRANSPATMODES; i++) { XFreePixmap(mainDisplay, transPatPixmap[i]); } for (i = 0; i < 4; i++) { XFreePixmap(mainDisplay, rotatePixmap[i]); } for (i = 0; i < MAXDEFWHERETOPRINT; i++) { XFreePixmap(mainDisplay, whereToPrintPixmap[i]); } free(whereToPrintPixmap); whereToPrintPixmap = NULL; for (i = 0; i < MAXLINETYPES; i++) { XFreePixmap(mainDisplay, shortLineTypePixmap[i]); } for (i = 0; i < MAXLINESTYLES; i++) { XFreePixmap(mainDisplay, shortLineStylePixmap[i]); } for (i = 0; i < MAXDASHES; i++) { XFreePixmap(mainDisplay, shortDashPixmap[i]); } XFreePixmap(mainDisplay, wireBitmap); XFreePixmap(mainDisplay, runBitmap); XFreePixmap(mainDisplay, checkBitmap); XFreePixmap(mainDisplay, radioBitmap); XFreePixmap(mainDisplay, submenuBitmap); XFreePixmap(mainDisplay, graySubmenuBitmap); XFreePixmap(mainDisplay, userRedrawBitmap); for (i = 0; i < MAX_STATUS_BTNS; i++) { XFreePixmap(mainDisplay, statusBtnPixmap[i]); } for (i = 0; i < MAX_MB_ICONS; i++) { XFreePixmap(mainDisplay, msgBoxPixmap[i]); } if (newLineWidthAllocated) { for (i = 0; i < maxLineWidths; i++) XFreePixmap(mainDisplay, lineWidthPixmap[i]); for (i = 0; i < maxLineWidths; i++) XFreePixmap(mainDisplay, shortLineWidthPixmap[i]); } free(lineWidthPixmap); lineWidthPixmap = NULL; free(shortLineWidthPixmap); shortLineWidthPixmap = NULL; free(curWidthOfLine); curWidthOfLine = NULL; free(curArrowHeadW); curArrowHeadW = NULL; free(curArrowHeadH); curArrowHeadH = NULL; for (i=0; i < maxLineWidths; i++) { if (curWidthOfLineSpec[i] != NULL) free(curWidthOfLineSpec[i]); if (curArrowHeadWSpec[i] != NULL) free(curArrowHeadWSpec[i]); if (curArrowHeadHSpec[i] != NULL) free(curArrowHeadHSpec[i]); } free(curWidthOfLineSpec); curWidthOfLineSpec = NULL; free(curArrowHeadWSpec); curArrowHeadWSpec = NULL; free(curArrowHeadHSpec); curArrowHeadHSpec = NULL; XFreeGC(mainDisplay, rasterGC); XFreeGC(mainDisplay, patGC); XFreeGC(mainDisplay, drawGC); drawGC = NULL; XFreeGC(mainDisplay, drawSBGC); drawSBGC = NULL; XFreeGC(mainDisplay, defaultGC); defaultGC = NULL; XFreeGC(mainDisplay, revDefaultGC); revDefaultGC = NULL; XFreeGC(mainDisplay, revGrayGC); revGrayGC = NULL; } int UpgradePenFill(pen_or_fill) int pen_or_fill; { if (fileVersion <= 17 && pen_or_fill >= 8 && pen_or_fill < 12) { return (pen_or_fill+12); } else { return pen_or_fill; } } unsigned char ByteReverse(byte) unsigned char byte; { int b=0; unsigned char flip=0, mask=1; for (b=0; b < 8; b++) { flip <<= 1; flip += byte&mask; byte >>= 1; } return flip; } void GetPatternCellsize(fill_or_pen, pn_cell_w, pn_cell_h) int fill_or_pen, *pn_cell_w, *pn_cell_h; { int w=pat_w[fill_or_pen]; int bits_in_last_byte=(w & 0x07); int bytes_per_row_out=0; switch (bits_in_last_byte) { case 1: bytes_per_row_out = (w+1); break; case 2: bytes_per_row_out = ((w>>3)<<2)+1; break; case 3: bytes_per_row_out = (w+3); break; case 4: bytes_per_row_out = ((w>>3)<<1)+1; break; case 5: bytes_per_row_out = (w+5); break; case 6: bytes_per_row_out = ((w>>3)<<2)+3; break; case 7: bytes_per_row_out = (w+7); break; default: bytes_per_row_out = (w>>3); break; } if (pn_cell_w != NULL) *pn_cell_w = (bytes_per_row_out<<3); if (pn_cell_h != NULL) *pn_cell_h = pat_h[fill_or_pen]; } static void SetBit(buf, bit_offset, ival) unsigned char *buf; int bit_offset, ival; { int byte_index=(bit_offset>>3); int bit_in_byte=(7-(bit_offset&0x7)); unsigned char *psz=(&buf[byte_index]); if (ival) { *psz |= (((unsigned char)0x1) << bit_in_byte); } else { *psz &= (~(((unsigned char)0x1) << bit_in_byte)); } } static unsigned char GetBit(buf, bit_offset) unsigned char *buf; int bit_offset; { int byte_index=(bit_offset>>3); int bit_in_byte=(7-(bit_offset&0x7)); unsigned char uch=buf[byte_index]; return ((uch >> bit_in_byte) & ((unsigned char)0x1)); } unsigned char *GetPatternBytes(fill_or_pen, pn_num_bytes, pn_need_to_free) int fill_or_pen, *pn_num_bytes, *pn_need_to_free; { int w=pat_w[fill_or_pen]; int h=pat_h[fill_or_pen]; int bits_in_last_byte=(w & 0x07); int multiple_of_8=(bits_in_last_byte == 0); int bytes_per_row_in=0, bytes_per_row_out=0, total_bytes=0; bytes_per_row_in = (multiple_of_8 ? (w>>3) : (w>>3)+1); switch (bits_in_last_byte) { case 1: bytes_per_row_out = (w+1); break; case 2: bytes_per_row_out = ((w>>3)<<2)+1; break; case 3: bytes_per_row_out = (w+3); break; case 4: bytes_per_row_out = ((w>>3)<<1)+1; break; case 5: bytes_per_row_out = (w+5); break; case 6: bytes_per_row_out = ((w>>3)<<2)+3; break; case 7: bytes_per_row_out = (w+7); break; default: bytes_per_row_out = (w>>3); break; } total_bytes = h * bytes_per_row_out; if (pn_num_bytes != NULL) *pn_num_bytes = total_bytes; if (!multiple_of_8) { unsigned char *buf=(unsigned char *)malloc(total_bytes); unsigned char *buf_in=patData[fill_or_pen], *buf_out=NULL; int r=0, i=0; if (buf == NULL) FailAllocMessage(); /* first reverse all the bits in buf_in */ for (i=0; i < bytes_per_row_in*h; i++) { buf_in[i] = ByteReverse(buf_in[i]); } buf_out = buf; for (r=0; r < h; r++) { int c=0; for (c=0; c < (bytes_per_row_out<<3); c++) { int bit_offset_in=(c % w); SetBit(buf_out, c, GetBit(buf_in, bit_offset_in)); } buf_in += bytes_per_row_in; buf_out += bytes_per_row_out; } /* reverse all the bits in buf_in back to what they were */ buf_in = patData[fill_or_pen]; for (i=0; i < bytes_per_row_in*h; i++) { buf_in[i] = ByteReverse(buf_in[i]); } for (i=0; i < total_bytes; i++) { buf[i] = ByteReverse(buf[i]); } if (pn_need_to_free != NULL) *pn_need_to_free = TRUE; return buf; } if (pn_need_to_free != NULL) *pn_need_to_free = FALSE; return patData[fill_or_pen]; } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/markup.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000007474�11602233312�014443� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/markup.c,v 1.6 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_MARKUP_C_ #include "tgifdefs.h" #include "file.e" #include "http.e" #include "markup.e" #include "msg.e" #include "setup.e" #include "util.e" int cmdLineParseHtml=FALSE; static int parseHtml=FALSE; /* ===================== Parse Routines ===================== */ static int DumpHtmlBuf(in_tag, psz_start) int in_tag; char *psz_start; { int last_ch_is_lf=FALSE; char *psz=NULL; if (in_tag) { for (psz=psz_start; *psz != '\0'; psz++) { switch (*psz) { case '\r': if (psz[1] == '\n') { psz++; } printf("\n"); last_ch_is_lf = TRUE; break; case '\n': printf("\n"); last_ch_is_lf = TRUE; break; default: fputc(*psz, stdout); last_ch_is_lf = FALSE; break; } } } else { for (psz=psz_start; *psz != '\0'; psz++) { switch (*psz) { case '\r': if (psz[1] == '\n') { psz++; } printf("\n"); last_ch_is_lf = TRUE; break; case '\n': printf("\n"); last_ch_is_lf = TRUE; break; default: fputc(*psz, stdout); last_ch_is_lf = FALSE; break; } } } if (!last_ch_is_lf) { printf("\n"); } return TRUE; } static int DoParseMarkUpFile(buf) char *buf; { int in_tag=FALSE; /* TRUE if inside a tag (and looking for '>') */ char *psz_start=buf; in_tag = (*psz_start == '<'); while (psz_start != NULL && *psz_start != '\0') { char *psz=NULL, saved_ch='\0'; if (in_tag) { if ((psz=strchr(psz_start, '>')) == NULL) break; saved_ch = (*(++psz)); *psz = '\0'; DumpHtmlBuf(in_tag, psz_start); *psz = saved_ch; in_tag = FALSE; } else { if ((psz=strchr(psz_start, '<')) == NULL) break; *psz = '\0'; DumpHtmlBuf(in_tag, psz_start); *psz = '<'; in_tag = TRUE; } psz_start = psz; } if (psz_start != NULL) { DumpHtmlBuf(in_tag, psz_start); } printf("\n"); fflush(stdout); return TRUE; } int ParseMarkUpFile(buf, buf_sz, pn_html, psz_content_type) char *buf, *psz_content_type; int buf_sz, *pn_html; { if (parseHtml) { if (*pn_html || *buf == '>') { if (!DoParseMarkUpFile(buf)) { } } } return TRUE; } /* ===================== Init & CleanUp Routines ===================== */ void CleanUpHtml() { } int InitHtml() { parseHtml = FALSE; if (!PRTGIF || cmdLineOpenDisplay) { char *c_ptr=FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ParseHtml")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { parseHtml = TRUE; } } if (PRTGIF && cmdLineParseHtml) { parseHtml = TRUE; } return TRUE; } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/exec.c�������������������������������������������������������������������������������0000644�0000764�0000764�00001233352�11602233311�014064� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/exec.c,v 1.59 2011/05/18 22:41:20 william Exp $ */ #define _INCLUDE_FROM_EXEC_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "expfdefs.h" #include "cmdids.h" #include "align.e" #include "arc.e" #include "attr.e" #include "auxtext.e" #include "box.e" #include "cmd.e" #include "color.e" #include "choice.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "edit.e" #include "eps.e" #include "exec.e" #include "expr.e" #include "file.e" #include "font.e" #include "grid.e" #include "import.e" #include "ini.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "obj.e" #include "oval.e" #include "page.e" #include "pattern.e" #include "pngtrans.e" #include "poly.e" #include "polygon.e" #include "raster.e" #include "rcbox.e" #include "rect.e" #include "remote.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "shortcut.e" #include "special.e" #include "stk.e" #include "stretch.e" #include "strtbl.e" #include "tangram2.e" #include "tcp.e" #include "text.e" #include "util.e" #include "version.e" #include "wb.e" #include "xbitmap.e" #include "xpixmap.e" #include "xprtfltr.e" #include "z_intrf.e" int execAnimating=FALSE; int execAnimateRedraw=FALSE; int execCurDepth=0; int replaceAttrFirstValueRedraw=TRUE; int execNavigateBack=FALSE; int userAbortExec=FALSE; static char gsPath[MAXSTRING+1]; static int execInterruptEnabled=TRUE; static int execInterruptQueued=FALSE; struct AttrRec *warpToAttr=NULL; char *cmdToExecAfterHyperJump=NULL; struct StrRec *topTmpStr=NULL; struct StrRec *botTmpStr=NULL; #define MAXEXECOPENFILES 16 struct OpenFileRec { FILE *fp; char *fname; int eof; } gaOpenFileInfo[MAXEXECOPENFILES]; #define TOK_INVALID (INVALID) #define TOK_EMPTY 0 #define TOK_STR 1 #define TOK_LEFT_P 2 #define TOK_RIGHT_P 3 #define TOK_LEFT_B 4 #define TOK_RIGHT_B 5 #define TOK_LEFT_CB 6 #define TOK_RIGHT_CB 7 #define TOK_COMMA 8 #define TOK_SEMI 9 static char execDummyStr[2048]; static int gnAbortExec=FALSE; static int gnStopCmdExecuted=TRUE; int ExecLaunch ARGS_DECL((char**, struct ObjRec *, char*)); int ExecExec ARGS_DECL((char**, struct ObjRec *, char*)); int ExecMktemp ARGS_DECL((char**, struct ObjRec *, char*)); int ExecUseTemplate ARGS_DECL((char**, struct ObjRec *, char*)); int ExecUpdEPSChild ARGS_DECL((char**, struct ObjRec *, char*)); int ExecUpdXBMChild ARGS_DECL((char**, struct ObjRec *, char*)); int ExecUpdXPMChild ARGS_DECL((char**, struct ObjRec *, char*)); int ExecDelEPSChild ARGS_DECL((char**, struct ObjRec *, char*)); int ExecDelXBMChild ARGS_DECL((char**, struct ObjRec *, char*)); int ExecDelXPMChild ARGS_DECL((char**, struct ObjRec *, char*)); int ExecFlipDeck ARGS_DECL((char**, struct ObjRec *, char*)); int ExecReadFileIntoAttr ARGS_DECL((char**, struct ObjRec *, char*)); int ExecWriteAttrIntoFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecAppendAttrIntoFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSelectObjByName ARGS_DECL((char**, struct ObjRec *, char*)); void ExecSelectTopObj ARGS_DECL((struct ObjRec *, char*)); void ExecDelAllSelObj ARGS_DECL((struct ObjRec *, char*)); void ExecUnSelectAllObj ARGS_DECL((struct ObjRec *, char*)); int ExecMoveSelObjRel ARGS_DECL((char**, struct ObjRec *, char*)); int ExecRepeat ARGS_DECL((char**, struct ObjRec *, char*)); int ExecHyperJump ARGS_DECL((char**, struct ObjRec *, char*)); int ExecMakeCGIQuery ARGS_DECL((char**, struct ObjRec *, char*)); int ExecWaitClick ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSleep ARGS_DECL((char**, struct ObjRec *, char*)); void ExecBeginAnimate ARGS_DECL((struct ObjRec *, char*)); void ExecEndAnimate ARGS_DECL((struct ObjRec *, char*)); int ExecSetRedraw ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelObjColor ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelObjFill ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelObjPen ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelObjLineWidth ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelObjSpline ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelObjArrow ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelObjDash ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelObjTransPat ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelObjRCBRadius ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelTextVSpace ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelTextJust ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelTextFont ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelTextStyle ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelTextSize ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelTextUnderline ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetSelTextOverline ARGS_DECL((char**, struct ObjRec *, char*)); int ExecInc ARGS_DECL((char**, struct ObjRec *, char*)); int ExecDec ARGS_DECL((char**, struct ObjRec *, char*)); int ExecShuffleObjToTop ARGS_DECL((char**, struct ObjRec *, char*)); int ExecShuffleObjToBot ARGS_DECL((char**, struct ObjRec *, char*)); void ExecDisableUndo ARGS_DECL((struct ObjRec *, char*)); void ExecEnableUndo ARGS_DECL((struct ObjRec *, char*)); int ExecGetDrawingArea ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetSelObjBBox ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetNamedObjBBox ARGS_DECL((char**, struct ObjRec *, char*)); int ExecMoveSelObjAbs ARGS_DECL((char**, struct ObjRec *, char*)); int ExecAssign ARGS_DECL((char**, struct ObjRec *, char*)); int ExecStrCpy ARGS_DECL((char**, struct ObjRec *, char*)); int ExecStrCat ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCopyStrToCutBuffer ARGS_DECL((char**, struct ObjRec *, char*)); int ExecWhile ARGS_DECL((char**, char**, struct ObjRec *, char*)); int ExecIf ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetCurrentFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetCurrentExportFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetCurrentDir ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetEnv ARGS_DECL((char**, struct ObjRec *, char*)); int ExecStrLen ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSubStr ARGS_DECL((char**, struct ObjRec *, char*)); int ExecStrStr ARGS_DECL((char**, struct ObjRec *, char*)); int ExecStrRStr ARGS_DECL((char**, struct ObjRec *, char*)); void ExecUnMakeSelObjIconic ARGS_DECL((struct ObjRec *, char*)); int ExecHyperJumpThenExec ARGS_DECL((char**, struct ObjRec *, char*)); int ExecShowAttr ARGS_DECL((char**, struct ObjRec *, char*)); int ExecHideAttr ARGS_DECL((char**, struct ObjRec *, char*)); int ExecShowAttrName ARGS_DECL((char**, struct ObjRec *, char*)); int ExecHideAttrName ARGS_DECL((char**, struct ObjRec *, char*)); int ExecShowValue ARGS_DECL((char**, struct ObjRec *, char*)); int ExecHideValue ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetAttrBBox ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSizeSelObjAbs ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSizeNamedObjAbs ARGS_DECL((char**, struct ObjRec *, char*)); int ExecMessageBox ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetUserInput ARGS_DECL((char**, struct ObjRec *, char*)); int ExecAddAttrToSelObj ARGS_DECL((char**, struct ObjRec *, char*)); int ExecDelAttrFromSelObj ARGS_DECL((char**, struct ObjRec *, char*)); int ExecUserEndAnEdge ARGS_DECL((char**, struct ObjRec *, char*)); int ExecUserDrawAnEdge ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetAPolyVertexAbs ARGS_DECL((char**, struct ObjRec *, char*)); int ExecMoveAPolyVertexAbs ARGS_DECL((char**, struct ObjRec *, char*)); int ExecPostAttrAndGetCGI ARGS_DECL((char**, struct ObjRec *, char*)); void ExecNavigateBack ARGS_DECL((struct ObjRec *, char*)); void ExecStop ARGS_DECL((struct ObjRec *, char*)); int ExecSqrt ARGS_DECL((char**, struct ObjRec *, char*)); int ExecRandom ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSRand48 ARGS_DECL((char**, struct ObjRec *, char*)); int ExecDRand48 ARGS_DECL((char**, struct ObjRec *, char*)); int ExecRound ARGS_DECL((char**, struct ObjRec *, char*)); int ExecRedrawObj ARGS_DECL((char**, struct ObjRec *, char*)); void ExecRedrawDrawingArea ARGS_DECL((struct ObjRec *, char*)); int ExecIntToHex ARGS_DECL((char**, struct ObjRec *, char*)); int ExecForI ARGS_DECL((char**, struct ObjRec *, char*)); void ExecSetFileNotModified ARGS_DECL((struct ObjRec *, char*)); int ExecNewId ARGS_DECL((char**, struct ObjRec *, char*)); int ExecRotateSelObj ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCallSimpleShortCut ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCallOneArgShortCut ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSubstituteAttr ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetFileSize ARGS_DECL((char**, struct ObjRec *, char*)); int ExecIsFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecIndex ARGS_DECL((char**, struct ObjRec *, char*)); int ExecRIndex ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetNumberOfLines ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetLineInAttr ARGS_DECL((char**, struct ObjRec *, char*)); int ExecTrim ARGS_DECL((char**, struct ObjRec *, char*)); int ExecIsAttr ARGS_DECL((char**, struct ObjRec *, char*)); int ExecFindObjNames ARGS_DECL((char**, struct ObjRec *, char*)); int ExecFindObjNamesOnAllPgs ARGS_DECL((char**, struct ObjRec *, char*)); int ExecTg2FindObjNsOnAllPgs ARGS_DECL((char**, struct ObjRec *, char*)); int ExecTokenize ARGS_DECL((char**, struct ObjRec *, char*)); int ExecMoveAttrRel ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetNumberOfVs ARGS_DECL((char**, struct ObjRec *, char*)); int ExecIsObjTransformed ARGS_DECL((char**, struct ObjRec *, char*)); int ExecMakeSelObjIconic ARGS_DECL((char**, struct ObjRec *, char*)); int ExecMoveNamedObjRel ARGS_DECL((char**, struct ObjRec *, char*)); int ExecMoveNamedObjAbs ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetTgifVersion ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetTgifDir ARGS_DECL((char**, struct ObjRec *, char*)); int ExecGetProfileString ARGS_DECL((char**, struct ObjRec *, char*)); int ExecWriteProfileString ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSelectAdditionalObj ARGS_DECL((char**, struct ObjRec *, char*)); int ExecOpenFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCloseFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecReadFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecWriteFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecFlushFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecAppendFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetOutputFormat ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetExportClipRect ARGS_DECL((char**, struct ObjRec *, char*)); int ExecImportFile ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSetXpmOutputVersion ARGS_DECL((char**, struct ObjRec *, char*)); int ExecEditIniSection ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSelectFromIniSection ARGS_DECL((char**, struct ObjRec *, char*)); int ExecAppendLineIntoAttr ARGS_DECL((char**, struct ObjRec *, char*)); int ExecInsertLineIntoAttr ARGS_DECL((char**, struct ObjRec *, char*)); int ExecClearAttr ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCreateText ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCreateBox ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCreateCornerOval ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCreateCenterOval ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCreateEdgeOval ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCreateRCBox ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCreateArc ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCreateFirstVertex ARGS_DECL((char**, struct ObjRec *, char*)); int ExecCreateNextVertex ARGS_DECL((char**, struct ObjRec *, char*)); void ExecCreatePoly ARGS_DECL((struct ObjRec *, char*)); void ExecCreatePolygon ARGS_DECL((struct ObjRec *, char*)); void ExecStartCreateGroup ARGS_DECL((struct ObjRec *, char*)); void ExecCreateGroup ARGS_DECL((struct ObjRec *, char*)); int ExecSetAllowInterrupt ARGS_DECL((char**, struct ObjRec *, char*)); int ExecSelectEachObjAndExec ARGS_DECL((char**, struct ObjRec *, char*)); int ExecEditAttrInTextMode ARGS_DECL((char**, struct ObjRec *, char*)); void ExecSetFileUnSavable ARGS_DECL((struct ObjRec *, char*)); int ExecPsToEpsi ARGS_DECL((char**, struct ObjRec *, char*)); int ExecObjsBBoxIntersect ARGS_DECL((char**, struct ObjRec *, char*)); void ExecDelAllAttrFromSelObj ARGS_DECL((struct ObjRec *, char*)); int ExecRndPermLinesInAttr ARGS_DECL((char**, struct ObjRec *, char*)); static ExecInfo gExecInfo[] = { /* do not translate -- program constants */ { (NLFN*)ExecLaunch, "launch", 1, 0}, { (NLFN*)ExecExec, "exec", 1, 0}, { (NLFN*)ExecMktemp, "mktemp", 2, 0}, { (NLFN*)ExecUseTemplate, "create_file_using_simple_template", 4, 0}, { (NLFN*)ExecUpdEPSChild, "update_eps_child", 1, 0}, { (NLFN*)ExecUpdXBMChild, "update_xbm_child", 1, 0}, { (NLFN*)ExecUpdXPMChild, "update_xpm_child", 1, 0}, { (NLFN*)ExecDelEPSChild, "delete_eps_child", 1, 0}, { (NLFN*)ExecDelXBMChild, "delete_xbm_child", 1, 0}, { (NLFN*)ExecDelXPMChild, "delete_xpm_child", 1, 0}, { (NLFN*)ExecFlipDeck, "flip_deck", 3, 0}, { (NLFN*)ExecReadFileIntoAttr, "read_file_into_attr", 2, 0}, { (NLFN*)ExecWriteAttrIntoFile, "write_attr_into_file", 2, 0}, { (NLFN*)ExecAppendAttrIntoFile, "append_attr_into_file", 2, 0}, { (NLFN*)ExecSelectObjByName, "select_obj_by_name", 1, 0}, { (NLFN*)ExecSelectTopObj, "select_top_obj", 0, 0}, { (NLFN*)ExecDelAllSelObj, "delete_selected_obj", 0, 0}, { (NLFN*)ExecUnSelectAllObj, "unselect_all_obj", 0, 0}, { (NLFN*)ExecMoveSelObjRel, "move_selected_obj_relative", 2, 0}, { (NLFN*)ExecRepeat, "repeat", 2, 0}, { (NLFN*)ExecHyperJump, "hyperjump", 1, 0}, { (NLFN*)ExecMakeCGIQuery, "make_cgi_query", 3, 0}, { (NLFN*)ExecWaitClick, "wait_click", 3, 0}, { (NLFN*)ExecSleep, "sleep", 2, 0}, { (NLFN*)ExecBeginAnimate, "begin_animate", 0, 0}, { (NLFN*)ExecEndAnimate, "end_animate", 0, 0}, { (NLFN*)ExecSetRedraw, "set_redraw", 1, 0}, { (NLFN*)ExecSetSelObjColor, "set_selected_obj_color", 1, 0}, { (NLFN*)ExecSetSelObjFill, "set_selected_obj_fill", 1, 0}, { (NLFN*)ExecSetSelObjPen, "set_selected_obj_pen", 1, 0}, { (NLFN*)ExecSetSelObjLineWidth, "set_selected_obj_line_width", 3, 0}, { (NLFN*)ExecSetSelObjSpline, "set_selected_obj_spline", 1, 0}, { (NLFN*)ExecSetSelObjArrow, "set_selected_obj_arrow", 1, 0}, { (NLFN*)ExecSetSelObjDash, "set_selected_obj_dash", 1, 0}, { (NLFN*)ExecSetSelObjTransPat, "set_selected_obj_trans_pat", 1, 0}, { (NLFN*)ExecSetSelObjRCBRadius, "set_selected_obj_rcb_radius", 1, 0}, { (NLFN*)ExecSetSelTextVSpace, "set_selected_text_vspace", 1, 0}, { (NLFN*)ExecSetSelTextJust, "set_selected_text_just", 1, 0}, { (NLFN*)ExecSetSelTextFont, "set_selected_text_font", 1, 0}, { (NLFN*)ExecSetSelTextStyle, "set_selected_text_style", 1, 0}, { (NLFN*)ExecSetSelTextSize, "set_selected_text_size", 1, 0}, { (NLFN*)ExecSetSelTextUnderline, "set_selected_text_underline", 1, 0}, { (NLFN*)ExecSetSelTextOverline, "set_selected_text_overline", 1, 0}, { (NLFN*)ExecInc, "inc", 2, 0}, { (NLFN*)ExecDec, "dec", 2, 0}, { (NLFN*)ExecShuffleObjToTop, "shuffle_obj_to_top", 1, 0}, { (NLFN*)ExecShuffleObjToBot, "shuffle_obj_to_bottom", 1, 0}, { (NLFN*)ExecDisableUndo, "disable_undo", 0, 0}, { (NLFN*)ExecEnableUndo, "enable_undo", 0, 0}, { (NLFN*)ExecGetDrawingArea, "get_drawing_area", 4, 0}, { (NLFN*)ExecGetSelObjBBox, "get_selected_obj_bbox", 4, 0}, { (NLFN*)ExecGetNamedObjBBox, "get_named_obj_bbox", 5, 0}, { (NLFN*)ExecMoveSelObjAbs, "move_selected_obj_absolute", 2, 0}, { (NLFN*)ExecAssign, "assign", 2, 0}, { (NLFN*)ExecStrCpy, "strcpy", 2, 0}, { (NLFN*)ExecStrCat, "strcat", 2, 0}, { (NLFN*)ExecCopyStrToCutBuffer, "copy_string_to_cut_buffer", 1, 0}, { (NLFN*)ExecWhile, "while", -2, 1}, { (NLFN*)ExecIf, "if", 3, 1}, { (NLFN*)ExecGetCurrentFile, "get_current_file", 1, 0}, { (NLFN*)ExecGetCurrentExportFile,"get_current_export_file", 1, 0}, { (NLFN*)ExecGetCurrentDir, "get_current_dir", 1, 0}, { (NLFN*)ExecGetEnv, "getenv", 2, 0}, { (NLFN*)ExecStrLen, "strlen", 2, 1}, { (NLFN*)ExecSubStr, "substr", 4, 1}, { (NLFN*)ExecStrStr, "strstr", 3, 1}, { (NLFN*)ExecStrRStr, "strrstr", 3, 1}, { (NLFN*)ExecUnMakeSelObjIconic, "unmake_selected_obj_iconic", 0, 0}, { (NLFN*)ExecHyperJumpThenExec, "hyperjump_then_exec", 2, 0}, { (NLFN*)ExecShowAttr, "show_attr", 1, 0}, { (NLFN*)ExecHideAttr, "hide_attr", 1, 0}, { (NLFN*)ExecShowAttrName, "show_attr_name", 1, 0}, { (NLFN*)ExecHideAttrName, "hide_attr_name", 1, 0}, { (NLFN*)ExecShowValue, "show_value", 1, 0}, { (NLFN*)ExecHideValue, "hide_value", 1, 0}, { (NLFN*)ExecGetAttrBBox, "get_attr_bbox", 5, 0}, { (NLFN*)ExecSizeSelObjAbs, "size_selected_obj_absolute", 2, 0}, { (NLFN*)ExecSizeNamedObjAbs, "size_named_obj_absolute", 3, 0}, { (NLFN*)ExecMessageBox, "message_box", 4, 0}, { (NLFN*)ExecGetUserInput, "get_user_input", 3, 0}, { (NLFN*)ExecAddAttrToSelObj, "add_attr_to_selected_obj", 4, 1}, { (NLFN*)ExecDelAttrFromSelObj, "delete_attr_from_selected_obj", 1, 0}, { (NLFN*)ExecUserEndAnEdge, "user_end_an_edge", 3, 1}, { (NLFN*)ExecUserDrawAnEdge, "user_draw_an_edge", 2, 0}, { (NLFN*)ExecGetAPolyVertexAbs, "get_a_poly_vertex_absolute", 4, 0}, { (NLFN*)ExecMoveAPolyVertexAbs, "move_a_poly_vertex_absolute", 4, 0}, { (NLFN*)ExecPostAttrAndGetCGI, "post_attr_and_get_cgi_result", 3, 0}, { (NLFN*)ExecNavigateBack, "navigate_back", 0, 0}, { (NLFN*)ExecStop, "stop", 0, 0}, { (NLFN*)ExecSqrt, "sqrt", 2, 0}, { (NLFN*)ExecRandom, "random", 1, 0}, { (NLFN*)ExecSRand48, "srand48", 1, 0}, { (NLFN*)ExecDRand48, "drand48", 1, 0}, { (NLFN*)ExecRound, "round", 2, 0}, { (NLFN*)ExecRedrawObj, "redraw_obj", 1, 0}, { (NLFN*)ExecRedrawDrawingArea, "redraw_drawing_area", 0, 0}, { (NLFN*)ExecIntToHex, "itox", 3, 0}, { (NLFN*)ExecForI, "for_i", 5, 0}, { (NLFN*)ExecSetFileNotModified, "set_file_not_modified", 0, 0}, { (NLFN*)ExecNewId, "new_id", 1, 0}, { (NLFN*)ExecRotateSelObj, "rotate_selected_obj", 1, 0}, { (NLFN*)ExecCallSimpleShortCut, "call_simple_shortcut", 1, 0}, { (NLFN*)ExecCallOneArgShortCut, "call_one_arg_shortcut", 2, 0}, { (NLFN*)ExecSubstituteAttr, "substitute_attr", 4, 0}, { (NLFN*)ExecGetFileSize, "get_file_size", 2, 0}, { (NLFN*)ExecIsFile, "is_file", 2, 0}, { (NLFN*)ExecIndex, "index", 3, 1}, { (NLFN*)ExecRIndex, "rindex", 3, 1}, { (NLFN*)ExecGetNumberOfLines, "get_number_of_lines_in_attr", 2, 0}, { (NLFN*)ExecGetLineInAttr, "get_line_in_attr", 3, 0}, { (NLFN*)ExecTrim, "trim", 1, 1}, { (NLFN*)ExecIsAttr, "is_attr", 2, 0}, { (NLFN*)ExecFindObjNames, "find_obj_names", 3, 0}, { (NLFN*)ExecFindObjNamesOnAllPgs,"find_obj_names_on_all_pages", 2, 0}, { (NLFN*)ExecTg2FindObjNsOnAllPgs,"tg2_find_obj_names_on_all_pages", 2, 0}, { (NLFN*)ExecTokenize, "tokenize", 3, 0}, { (NLFN*)ExecMoveAttrRel, "move_attr_relative", 3, 0}, { (NLFN*)ExecGetNumberOfVs, "get_number_of_vertices", 2, 0}, { (NLFN*)ExecIsObjTransformed, "is_obj_transformed", 2, 0}, { (NLFN*)ExecMakeSelObjIconic, "make_selected_obj_iconic", 1, 0}, { (NLFN*)ExecMoveNamedObjRel, "move_named_obj_relative", 3, 0}, { (NLFN*)ExecMoveNamedObjAbs, "move_named_obj_absolute", 3, 0}, { (NLFN*)ExecGetTgifVersion, "get_tgif_version", 4, 0}, { (NLFN*)ExecGetTgifDir, "get_tgif_dir", 1, 0}, { (NLFN*)ExecGetProfileString, "get_profile_string", 5, 0}, { (NLFN*)ExecWriteProfileString, "write_profile_string", 4, 0}, { (NLFN*)ExecSelectAdditionalObj, "select_additional_obj", 1, 0}, { (NLFN*)ExecOpenFile, "open_file", 3, 0}, { (NLFN*)ExecCloseFile, "close_file", 1, 0}, { (NLFN*)ExecReadFile, "read_file", 2, 0}, { (NLFN*)ExecWriteFile, "write_file", 2, 0}, { (NLFN*)ExecFlushFile, "flush_file", 1, 0}, { (NLFN*)ExecAppendFile, "append_file", 2, 0}, { (NLFN*)ExecSetOutputFormat, "set_output_format", 2, 0}, { (NLFN*)ExecSetExportClipRect, "set_export_clip_rect", 4, 0}, { (NLFN*)ExecImportFile, "import_file", 4, 0}, { (NLFN*)ExecSetXpmOutputVersion, "set_xpm_output_version", 1, 0}, { (NLFN*)ExecEditIniSection, "edit_ini_section", 4, 0}, { (NLFN*)ExecSelectFromIniSection,"select_from_ini_section", 4, 0}, { (NLFN*)ExecAppendLineIntoAttr, "append_line_into_attr", 2, 0}, { (NLFN*)ExecInsertLineIntoAttr, "insert_line_into_attr", 3, 0}, { (NLFN*)ExecClearAttr, "clear_attr", 1, 0}, { (NLFN*)ExecCreateText, "create_text_obj", 3, 0}, { (NLFN*)ExecCreateBox, "create_box_obj", 4, 0}, { (NLFN*)ExecCreateCornerOval, "create_corner_oval_obj", 4, 0}, { (NLFN*)ExecCreateCenterOval, "create_center_oval_obj", 3, 0}, { (NLFN*)ExecCreateEdgeOval, "create_edge_oval_obj", 4, 0}, { (NLFN*)ExecCreateRCBox, "create_rcbox_obj", 4, 0}, { (NLFN*)ExecCreateArc, "create_arc_obj", 6, 0}, { (NLFN*)ExecCreateFirstVertex, "create_first_vertex", 2, 0}, { (NLFN*)ExecCreateNextVertex, "create_next_vertex", 2, 0}, { (NLFN*)ExecCreatePoly, "create_poly_obj", 0, 0}, { (NLFN*)ExecCreatePolygon, "create_polygon_obj", 0, 0}, { (NLFN*)ExecStartCreateGroup, "start_create_group_obj", 0, 0}, { (NLFN*)ExecCreateGroup, "create_group_obj", 0, 0}, { (NLFN*)ExecSetAllowInterrupt, "set_allow_interrupt", 1, 0}, { (NLFN*)ExecSelectEachObjAndExec,"select_each_obj_and_exec", 1, 0}, { (NLFN*)ExecEditAttrInTextMode, "edit_attr_in_text_mode", 1, 0}, { (NLFN*)ExecSetFileUnSavable, "set_file_unsavable", 0, 0}, { (NLFN*)ExecPsToEpsi, "pstoepsi", 3, 0}, { (NLFN*)ExecObjsBBoxIntersect, "objs_bbox_intersect", 3, 0}, { (NLFN*)ExecDelAllAttrFromSelObj,"delete_all_attr_from_selected_objs",0, 0}, { (NLFN*)ExecRndPermLinesInAttr, "random_permute_lines_in_attr", 1, 0}, { NULL, NULL, 0, 0 } }; void CleanTmpStr() { struct StrRec *next_str=NULL; for ( ; topTmpStr != NULL; topTmpStr=next_str) { next_str = topTmpStr->next; FreeStr(topTmpStr); } topTmpStr = botTmpStr = NULL; } int PrependToTmpStr(psz) char *psz; { struct StrRec *str_ptr=NewStr(); if (str_ptr == NULL) return FALSE; DynStrSet(&str_ptr->dyn_str, psz); str_ptr->prev = NULL; str_ptr->next = topTmpStr; if (topTmpStr == NULL) { botTmpStr = str_ptr; } else { topTmpStr->prev = str_ptr; } topTmpStr = str_ptr; return TRUE; } int AppendToTmpStr(psz) char *psz; { struct StrRec *str_ptr=NewStr(); if (str_ptr == NULL) return FALSE; DynStrSet(&str_ptr->dyn_str, psz); str_ptr->prev = botTmpStr; str_ptr->next = NULL; if (botTmpStr == NULL) { topTmpStr = str_ptr; } else { botTmpStr->next = str_ptr; } botTmpStr = str_ptr; return TRUE; } int AppendToTmpStr2(psz1, psz2, tg2) char *psz1, *psz2; { int len1=strlen(psz1), len2=strlen(psz2), rc=0; char *psz=(char*)malloc((len1+len2+1)*sizeof(char)); if (psz == NULL) FailAllocMessage(); if (tg2) { sprintf(psz, "%s%s", psz2, psz1); } else { sprintf(psz, "%s%s", psz1, psz2); } rc = AppendToTmpStr(psz); free(psz); return rc; } int ExecuteCmdGetResult(cmd, result_list, max_lines) char *cmd; CVList *result_list; int max_lines; { char *buf=NULL; FILE *pfp=NULL; int count=0; EndMeasureTooltip(FALSE); if (!FindProgramInPath(cmd, NULL, FALSE)) { return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), cmd); SetStringStatus(gszMsgBox); if (!PRTGIF) XSync(mainDisplay, False); if ((pfp=(FILE*)popen(cmd, "r")) == NULL) { return FALSE; } while ((buf=UtilGetALine(pfp)) != NULL) { if (PRTGIF) { fprintf(stderr, "%s", buf); } else { Msg(buf); } if (max_lines == (-1) || count++ < max_lines) { ListAppend(result_list, buf); } } pclose(pfp); SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); if (max_lines != (-1) && count < max_lines) { return FALSE; } return TRUE; } struct ObjRec *FindObjWithName(BotObj, OrigObj, obj_name, inside_root_obj, inside_this_obj, pp_owner_obj, pp_top_owner) struct ObjRec *BotObj, *OrigObj, **pp_owner_obj, **pp_top_owner; char *obj_name; int inside_root_obj, inside_this_obj; { register struct AttrRec *attr_ptr=NULL; register struct ObjRec *obj_ptr=NULL; struct ObjRec *bot_obj=BotObj; char *bang_ptr=NULL; if (obj_name == NULL || *obj_name == '\0') return NULL; if (*obj_name == '!') { if (inside_root_obj || inside_this_obj) return NULL; obj_name++; inside_root_obj = TRUE; inside_this_obj = FALSE; if (pp_owner_obj != NULL) *pp_owner_obj = NULL; if (pp_top_owner != NULL) *pp_top_owner = NULL; bot_obj = botObj; if (*obj_name == '*') { if (topSel == NULL) return NULL; obj_name++; if (pp_owner_obj != NULL) *pp_owner_obj = topSel->obj; if (pp_top_owner != NULL) *pp_top_owner = topSel->obj; if (*obj_name == '\0') { return topSel->obj; } switch (topSel->obj->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: return NULL; } return FindObjWithName(topSel->obj->detail.r->last, OrigObj, obj_name, TRUE, FALSE, pp_owner_obj, pp_top_owner); } } if (*obj_name == '!') return NULL; if ((bang_ptr=strchr(obj_name, '!')) != NULL) { *bang_ptr = '\0'; /* do not translate -- program constants */ if (OrigObj != NULL && strcmp(obj_name, "THIS") == 0) { int this_ok=FALSE; *bang_ptr++ = '!'; if (inside_root_obj || inside_this_obj) return NULL; switch (OrigObj->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: return NULL; } for (obj_ptr=botObj; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { if (obj_ptr == OrigObj) { this_ok = TRUE; break; } } if (!this_ok) return NULL; if (pp_top_owner != NULL) *pp_top_owner = OrigObj; if (pp_owner_obj != NULL) *pp_owner_obj = OrigObj; return FindObjWithName(OrigObj->detail.r->last, OrigObj, bang_ptr, FALSE, TRUE, pp_owner_obj, pp_top_owner); } else { for (obj_ptr=bot_obj; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { if (obj_ptr->fattr != NULL && (attr_ptr=FindAttrWithName(obj_ptr,"name=",NULL)) != NULL && strcmp(attr_ptr->attr_value.s, obj_name) == 0) { *bang_ptr++ = '!'; switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: return NULL; } if (pp_owner_obj != NULL) *pp_owner_obj = obj_ptr; if (pp_top_owner != NULL && bot_obj == botObj) { *pp_top_owner = obj_ptr; } return FindObjWithName(obj_ptr->detail.r->last, obj_ptr, bang_ptr, inside_root_obj, inside_this_obj, pp_owner_obj, pp_top_owner); } } *bang_ptr = '!'; return NULL; } } else if (strcmp(obj_name, "THIS") == 0) { int this_ok=FALSE; if (inside_root_obj || inside_this_obj) return NULL; for (obj_ptr=botObj; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { if (obj_ptr == OrigObj) { this_ok = TRUE; break; } } if (!this_ok) return NULL; if (pp_top_owner != NULL) *pp_top_owner = NULL; if (pp_owner_obj != NULL) *pp_owner_obj = NULL; return OrigObj; } for (obj_ptr=bot_obj; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { if (obj_ptr->fattr != NULL && (attr_ptr=FindAttrWithName(obj_ptr,"name=",NULL)) != NULL && strcmp(attr_ptr->attr_value.s, obj_name) == 0) { if (pp_top_owner != NULL && bot_obj == botObj) { *pp_top_owner = obj_ptr; } return (obj_ptr); } } return NULL; } static int gnSeenLeftParan=FALSE; static int EndingRightParan(inbuf) char *inbuf; { for ( ; *inbuf != '\0'; inbuf++) { if (*inbuf != ' ' && *inbuf != '\t') { return (*inbuf == ';'); } } return TRUE; } static int OnlyBlanksLeft(inbuf) char *inbuf; { for ( ; *inbuf != '\0'; inbuf++) { if (*inbuf != ' ' && *inbuf != '\t') { return FALSE; } } return TRUE; } static char *GetToken(inbuf, outbuf, obuf_sz, tok_type) char *inbuf, *outbuf; int obuf_sz, *tok_type; /* returns NULL of the input string is invalid */ /* otherwise, the return value points to the character */ /* immediately following the end of the token */ /* *tok_type contains the token type */ { register char *c_ptr, *obuf_ptr=outbuf; int obuf_index=0; *tok_type = TOK_INVALID; while (*inbuf == ' ' || *inbuf == '\t') inbuf++; switch (*inbuf) { case '\0': *tok_type = TOK_EMPTY; return (inbuf); /* case '\'': case '"': *tok_type = TOK_STR; for (c_ptr=(&inbuf[1]); *c_ptr!=(*inbuf) && *c_ptr!='\0'; c_ptr++, obuf_ptr++) { switch (*c_ptr) { case '\\': switch (*(++c_ptr)) { case 'n': *obuf_ptr = '\n'; break; case 'r': *obuf_ptr = '\r'; break; case 't': *obuf_ptr = '\t'; break; default: *obuf_ptr = *c_ptr; break; } break; default: *obuf_ptr = *c_ptr; break; } } if (*c_ptr == '\0') return (NULL); *obuf_ptr++ = '\0'; return (++c_ptr); */ case '(': if (gnSeenLeftParan) { break; } else { strcpy(obuf_ptr,"("); *tok_type = TOK_LEFT_P; gnSeenLeftParan = TRUE; return(&inbuf[1]); } case ')': if (gnSeenLeftParan && !EndingRightParan(&inbuf[1])) { break; } else { strcpy(obuf_ptr,")"); *tok_type = TOK_RIGHT_P; return(&inbuf[1]); } /* case '[': strcpy(obuf_ptr,"["); *tok_type=TOK_LEFT_B; return(&inbuf[1]); */ /* case ']': strcpy(obuf_ptr,"]"); *tok_type=TOK_RIGHT_B; return(&inbuf[1]); */ /* case '{': strcpy(obuf_ptr,"{"); *tok_type=TOK_LEFT_CB; return(&inbuf[1]); */ /* case '}': strcpy(obuf_ptr,"}"); *tok_type=TOK_RIGHT_CB; return(&inbuf[1]); */ case ',': strcpy(obuf_ptr,","); *tok_type=TOK_COMMA; return(&inbuf[1]); case ';': strcpy(obuf_ptr,";"); *tok_type=TOK_SEMI; return(&inbuf[1]); } *tok_type = TOK_STR; c_ptr = inbuf; /* while (*c_ptr != '\0' && strchr (" \t()[]{},;", *c_ptr) == NULL) { if (*c_ptr == '$' && c_ptr[1] == '(') { *obuf_ptr++ = *c_ptr++; *obuf_ptr++ = *c_ptr++; while (*c_ptr != '\0' && *c_ptr != ')') *obuf_ptr++ = *c_ptr++; if (*c_ptr == '\0') return NULL; } else { *obuf_ptr++ = *c_ptr++; } } */ while (*c_ptr != '\0') { int max_obuf_index=0; if (*c_ptr == '$' && c_ptr[1] == '(') { max_obuf_index = (obuf_sz-3); if (obuf_index >= max_obuf_index) return NULL; *obuf_ptr++ = (*c_ptr++); *obuf_ptr++ = (*c_ptr++); obuf_index += 2; max_obuf_index++; while (*c_ptr != '\0' && *c_ptr != ')') { if (obuf_index++ >= max_obuf_index) return NULL; *obuf_ptr++ = *c_ptr++; } if (*c_ptr == '\0') return NULL; } else if (*c_ptr == '"' || *c_ptr == '\'') { char *tmp_c_ptr=NULL; max_obuf_index = (obuf_sz-2); if (obuf_index++ >= max_obuf_index) return NULL; *obuf_ptr++ = (*c_ptr); for (tmp_c_ptr=(&c_ptr[1]); *tmp_c_ptr!=(*c_ptr) && *tmp_c_ptr!='\0'; tmp_c_ptr++) { if (obuf_index++ >= max_obuf_index) return NULL; switch (*tmp_c_ptr) { case '\\': switch (*(++tmp_c_ptr)) { case 'n': *obuf_ptr++ = '\n'; break; case 'r': *obuf_ptr++ = '\r'; break; case 't': *obuf_ptr++ = '\t'; break; default: *obuf_ptr++ = *tmp_c_ptr; break; } break; default: *obuf_ptr++ = *tmp_c_ptr; break; } } if (*tmp_c_ptr == '\0') return NULL; c_ptr = tmp_c_ptr; if (obuf_index++ >= max_obuf_index) return NULL; *obuf_ptr++ = *c_ptr++; } else { if (obuf_index++ >= obuf_sz-2) return NULL; *obuf_ptr++ = *c_ptr++; } if (*c_ptr == ')') { if (!gnSeenLeftParan || EndingRightParan(&c_ptr[1])) { break; } } else if (*c_ptr == '(') { if (!gnSeenLeftParan) { break; } } else if (*c_ptr == ',' || *c_ptr == ';') { break; } } *obuf_ptr = '\0'; return (c_ptr); } static char *convert_str(inbuf, obj_ptr, double_quotes_for_null) char *inbuf; struct ObjRec *obj_ptr; int double_quotes_for_null; { register char *buf_ptr; char *return_str, *return_ptr, quote_char='\0'; int cur_size=(MAXSTRING<<1), count=0, return_len=0, inside_quote=FALSE; return_ptr = return_str = (char *)malloc((cur_size+2)*sizeof(char)); if (return_str == NULL) return (char*)(long)FailAllocMessage(); *return_str = '\0'; buf_ptr = inbuf; while (*inbuf != '\0') { struct AttrRec *attr_ptr; int null_string=FALSE, n, need_to_free_tmp_buf=FALSE; char *c_ptr=inbuf, *new_c_ptr=NULL, *cp, *cp1; char *tmp_buf=NULL, *attr_value=NULL; MiniLineInfo *pMiniLine=NULL; while (new_c_ptr == NULL) { if (inside_quote) { for ( ; *c_ptr != '\0'; c_ptr++) { if (*c_ptr == quote_char) { inside_quote = FALSE; c_ptr++; break; } else if (*c_ptr == '$' && c_ptr[1] == '(') { new_c_ptr = c_ptr; break; } } } else { for ( ; *c_ptr != '\0'; c_ptr++) { if (*c_ptr == '"' || *c_ptr == '\'') { quote_char = *c_ptr; inside_quote = TRUE; c_ptr++; break; } else if (*c_ptr == '$' && c_ptr[1] == '(') { new_c_ptr = c_ptr; break; } } } if (*c_ptr == '\0') break; } if (new_c_ptr == NULL) { count = strlen(inbuf); if (count != 0) { if (count+return_len >= cur_size) { n = return_ptr-return_str; cur_size += count+MAXSTRING; return_str = (char*)realloc(return_str, (cur_size+2)*sizeof(char)); return_ptr = &return_str[n]; } strncpy(return_ptr, inbuf, count); return_ptr += count; *return_ptr = '\0'; } return return_str; } buf_ptr = new_c_ptr; count = buf_ptr-inbuf; return_len += count; if (count != 0) { if (count+return_len >= cur_size) { n = return_ptr-return_str; cur_size += count+MAXSTRING; return_str = (char*)realloc(return_str, (cur_size+2)*sizeof(char)); return_ptr = &return_str[n]; } strncpy(return_ptr, inbuf, count); return_ptr += count; *return_ptr = '\0'; } if ((attr_ptr=ValidAttrArg(buf_ptr, obj_ptr, &new_c_ptr)) == NULL) { free(return_str); return NULL; } pMiniLine = attr_ptr->obj->detail.t->minilines.first; tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); attr_value = UtilStrDup(tmp_buf); if (attr_value == NULL) FailAllocMessage(); ParseAttrStr(tmp_buf, NULL, 0, attr_value, strlen(attr_value)+1); if (need_to_free_tmp_buf) UtilFree(tmp_buf); need_to_free_tmp_buf = TRUE; count = strlen(attr_value); if (count == 0 && double_quotes_for_null && !inside_quote) { null_string = TRUE; count += 2; } if (count+return_len >= cur_size) { n = return_ptr-return_str; cur_size += count+MAXSTRING; return_str = (char*)realloc(return_str, (cur_size+2)*sizeof(char)); return_ptr = &return_str[n]; } if (null_string) { return_ptr[0] = return_ptr[1] = '"'; return_ptr[2] = '\0'; } else { strcpy(return_ptr, attr_value); } UtilFree(attr_value); if ((cp=strstr(return_ptr, "//")) != NULL) { *cp = '\0'; count = cp-return_ptr; } if (!double_quotes_for_null && *return_ptr == '"' && return_ptr[count-1] == '"') { int n; for (n=1, cp1=return_ptr, cp=(&return_ptr[1]); n < count-1; n++) { *cp1++ = *cp++; } *cp1 = '\0'; count -= 2; } return_ptr += count; inbuf = buf_ptr = ++new_c_ptr; } return return_str; } int PipeReachedEOF(fp) FILE *fp; { if (feof(fp)) return TRUE; /* this works because of non-blocking I/O */ while (getc(fp) != EOF) ; #ifdef EAGAIN if (errno == EINPROGRESS || errno == EAGAIN) { #else /* ~EAGAIN */ if (errno == EINPROGRESS) { #endif /* EAGAIN */ /* do nothing */ return FALSE; } /* a real EOF */ return TRUE; } int WaitForEvent(fp, fp_is_pipe, fp_is_named_pipe, pn_quit, what_to_do_with_x_events, pf_abort_callback, p_void) FILE *fp; int fp_is_pipe, fp_is_named_pipe, *pn_quit, what_to_do_with_x_events; AbortCallbackFunc *pf_abort_callback; void *p_void; /* * returns TRUE if there's character waiting in fp * * This routine is not really general purpose because characters can * swallowed in the PipeReachedEOF() routine. * So if for any reason the content of the pipe is required, don't * use this function! * fp_is_pipe is TRUE if fp is opened with popen(). This is not the * same as a named pipe. * fp_is_named_pipe is TRUE if fp is a named pipe (S_IFIFO). */ { int rc=FALSE; *pn_quit = FALSE; if (fp != stdin && !fp_is_pipe && !fp_is_named_pipe) { return TRUE; } for (;;) { struct timeval timeout; fd_set fdset; int select_width=XConnectionNumber(mainDisplay)+1, status=0, nfds=0; nfds = max(select_width, (int)(fileno(fp)+1)); timeout.tv_sec = 0; timeout.tv_usec = 100000; FD_ZERO(&fdset); FD_SET(select_width-1, &fdset); FD_SET(fileno(fp), &fdset); #ifdef __hpux status = select(nfds, (int*)&fdset, NULL, NULL, &timeout); #else /* !__hpux */ status = select(nfds, &fdset, NULL, NULL, &timeout); #endif /* __hpux */ if (status < 0) { if (errno == EINTR) { /* interrupted by a system call, not a problem */ if (fp_is_pipe && !fp_is_named_pipe && PipeReachedEOF(fp)) { return FALSE; } CheckInterrupt(TRUE); } else { sprintf(gszMsgBox, TgLoadString(STID_FUNC_SELECT_SYS_CALL_FAILED), "WaitForEvent()"), MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; } } else if (status == 0) { if (fp_is_pipe && !fp_is_named_pipe && PipeReachedEOF(fp)) { return FALSE; } CheckInterrupt(TRUE); } else if (status == 1) { if (FD_ISSET(fileno(fp), &fdset)) { /* character waiting to be processed at fp */ return TRUE; } else if (FD_ISSET(select_width-1, &fdset)) { switch (what_to_do_with_x_events) { case DO_ALL_X_EV: while (XPending(mainDisplay) > 0) { if (TryProcessAnXEvent(NULL) != 0) { *pn_quit = TRUE; return FALSE; } } break; case EXPOSE_AND_ESC_X_EV_ONLY: while (XPending(mainDisplay) > 0) { CheckInterrupt(FALSE); if (TryProcessAnAbortXEvent(FALSE, pf_abort_callback, p_void)) { if (fp_is_pipe && !fp_is_named_pipe && PipeReachedEOF(fp)) { return FALSE; } *pn_quit = TRUE; return TRUE; } } break; } if (fp_is_pipe && !fp_is_named_pipe && PipeReachedEOF(fp)) { return FALSE; } } } else if (status == 2) { rc = TRUE; break; } else { sprintf(gszMsgBox, TgLoadString(STID_FUNC_INVALID_RC_FOR_SELECT), "WaitForEvent()", status); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; } } return rc; } static int AbortLaunch(pVoid) void *pVoid; { if (MsgBox(TgLoadString(STID_CNTRL_C_ABORT_LAUNCH), TOOL_NAME, YNC_MB) == MB_ID_YES) { return TRUE; } return FALSE; } static void LaunchIt(cmd) char *cmd; { int len=strlen(cmd); while (len > 0 && (cmd[len-1] == ' ')) cmd[--len] = '\0'; if (cmd[0] != '\0' && FindProgramInPath(cmd, NULL, FALSE)) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if (cmd[len-1] == '&') { cmd[--len] = '\0'; while (len > 0 && (cmd[len-1] == ' ')) cmd[--len] = '\0'; if (cmd[0] != '\0') { #ifdef _BACKGROUND_DONT_FORK fprintf(stderr, TgLoadCachedString(CSTID_BACKGROUNDING_CMD), cmd); fprintf(stderr, "\n"); strcat(cmd, " &"); (void)system(cmd); #else /* ~_BACKGROUND_DONT_FORK */ int pid; fprintf(stderr, TgLoadCachedString(CSTID_BACKGROUNDING_CMD), cmd); fprintf(stderr, "\n"); pid = fork(); if (pid == 0) { (void)system(cmd); exit(0); } #endif /* _BACKGROUND_DONT_FORK */ } } else { FILE *fp=NULL; sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), cmd); SetStringStatus(gszMsgBox); Msg(TgLoadCachedString(CSTID_CNTRL_C_TO_INTR_AND_ABEND)); EndMeasureTooltip(FALSE); XSync(mainDisplay, False); if ((fp=(FILE*)popen(cmd, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { int quit=FALSE, got_eof=FALSE, fd=fileno(fp); SetSocketBlockingState(&fd, FALSE); /* * Note: Calling WaitForEvent() with the second argument being * TRUE can lose data in the pipe. Can do this here * because the data in the pipe is ignored. */ while (WaitForEvent(fp, TRUE, FALSE, &quit, EXPOSE_AND_ESC_X_EV_ONLY, AbortLaunch, NULL)) { if (quit) { break; } else if (PipeReachedEOF(fp)) { got_eof = TRUE; break; } } if (quit && !got_eof) { sprintf(gszMsgBox, TgLoadString(STID_CMD_ABORT_LAUNCH_CLOSE_TOOL), cmd, TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { pclose(fp); } } Msg(""); SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); } SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); } } int DoLaunch(launch_attr, obj_ptr) struct AttrRec *launch_attr; struct ObjRec *obj_ptr; { char *c_ptr=NULL, *buf_ptr=NULL; char *new_c_ptr=NULL, buf[MAXSTRING+1], *cmd=NULL, *cmd_ptr=NULL; int cur_size=2*MAXSTRING, count=0, cmd_len=0, n, first_time=TRUE; MiniLineInfo *pMiniLine=NULL; cmd = (char *)malloc((cur_size+1)*sizeof(char)); if (cmd == NULL) return FailAllocMessage(); cmd_ptr = cmd; buf_ptr = buf; for (pMiniLine=launch_attr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { struct AttrRec *attr_ptr=NULL; int need_to_free_tmp_buf=FALSE; char *tmp_buf=NULL; if (first_time) { char *attr_value=NULL; first_time = FALSE; tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); attr_value = UtilStrDup(tmp_buf); if (attr_value == NULL) FailAllocMessage(); ParseAttrStr(tmp_buf, NULL, 0, attr_value, strlen(attr_value)+1); if (need_to_free_tmp_buf) UtilFree(tmp_buf); need_to_free_tmp_buf = TRUE; c_ptr = tmp_buf = attr_value; } else { tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); c_ptr = tmp_buf; } for ( ; *c_ptr != '\0'; c_ptr++, count++) { switch (*c_ptr) { case '\\': c_ptr++; *buf_ptr++ = *c_ptr; break; case '$': if (count != 0) { *buf_ptr = '\0'; if (count+cmd_len >= cur_size) { n = cmd_ptr-cmd; cur_size += MAXSTRING; cmd = (char*)realloc(cmd, (cur_size+2)*sizeof(char)); cmd_ptr = cmd+n; } strcpy(cmd_ptr, buf); cmd_ptr += count; count = 0; buf_ptr = buf; } if ((attr_ptr=ValidAttrArg(c_ptr,obj_ptr,&new_c_ptr)) == NULL) { free(cmd); sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_ATTR_SPEC), c_ptr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } count = attr_ptr->attr_value.sz-1; if (count+cmd_len >= cur_size) { n = cmd_ptr-cmd; cur_size += MAXSTRING; cmd = (char*)realloc(cmd, (cur_size+2)*sizeof(char)); cmd_ptr = cmd+n; } strcpy(cmd_ptr, attr_ptr->attr_value.s); cmd_ptr += count; count = -1; c_ptr = new_c_ptr; break; default: *buf_ptr++ = *c_ptr; break; } } if (need_to_free_tmp_buf) UtilFree(tmp_buf); if (count != 0) { *buf_ptr = '\0'; if (count+cmd_len >= cur_size) { n = cmd_ptr-cmd; cur_size += MAXSTRING; cmd = (char*)realloc(cmd, (cur_size+2)*sizeof(char)); cmd_ptr = cmd+n; } strcpy(cmd_ptr, buf); cmd_ptr += count; count = 0; buf_ptr = buf; } if (pMiniLine->next != NULL) { *cmd_ptr++ = ' '; *cmd_ptr = '\0'; } } if (inHyperSpace && !allowLaunchInHyperSpace) { XFlush(mainDisplay); XSync(mainDisplay, False); sprintf(gszMsgBox, TgLoadString(STID_LAUNCH_NOT_AUTO_IN_HYPER_EXEC), cmd); if (MsgBox(gszMsgBox, TOOL_NAME, YN_MB) != MB_ID_YES) { MsgBox(TgLoadString(STID_USER_ABORT_LAUNCH_IN_HYPER), TOOL_NAME, INFO_MB); return FALSE; } } SaveStatusStrings(); LaunchIt(cmd); RestoreStatusStrings(); free(cmd); return TRUE; } static int BadCmd(cmd_name) char *cmd_name; { sprintf(gszMsgBox, TgLoadString(STID_MALFORMED_CMD_EXEC_ABORT), cmd_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } static int BadSelectedObj(cmd_name) char *cmd_name; { sprintf(gszMsgBox, TgLoadString(STID_NO_OBJ_SEL_WHILE_EXEC_CMD), cmd_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } static int BadAttr(attr_name, cmd_name) char *attr_name, *cmd_name; { char msg[MAXSTRING+1]; sprintf(msg, TgLoadString(STID_CANT_FIND_NAMED_ATTR_EXEC), attr_name, cmd_name); MsgBox(msg, TOOL_NAME, INFO_MB); return FALSE; } static int FileAttrNotAllowed(attr_name, cmd_name) char *attr_name, *cmd_name; { char msg[MAXSTRING+1]; sprintf(msg, TgLoadString(STID_FILE_ATTR_NOT_ALLOWED_FOR_CMD), attr_name, cmd_name); MsgBox(msg, TOOL_NAME, INFO_MB); return FALSE; } static int BadObjName(obj_name, cmd_name) char *obj_name, *cmd_name; { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_NAMED_OBJ_EXEC), obj_name, cmd_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } static int BadArg(arg_name, cmd_name) char *arg_name, *cmd_name; { sprintf(gszMsgBox, TgLoadString(STID_INVALID_ARG_WHILE_EXEC_CMD), arg_name, cmd_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } static ReplAttrValueCallback *gpfReplaceAttrValueCallback=NULL; static void *gpvReplAttrValueCallbackUserData=NULL; void SetReplaceAttrValueCallback(pf_replace_attr_value, pv_userdata) ReplAttrValueCallback *pf_replace_attr_value; void *pv_userdata; { gpfReplaceAttrValueCallback = pf_replace_attr_value; gpvReplAttrValueCallbackUserData = pv_userdata; } int ReplaceAttrFirstValue(obj_ptr, attr_ptr, new_value) struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; char *new_value; /* obj_ptr better be a top-level object */ { int value_len=0, same=FALSE; MiniLineInfo *pFirstMiniLine=attr_ptr->obj->detail.t->minilines.first; if (obj_ptr == NULL && historyDepth != 0) { sprintf(gszMsgBox, TgLoadString(STID_NEED_DISABLE_UNDO_WILL_CRASH), TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, STOP_MB); } value_len = strlen(new_value); if (value_len >= 2 && (*new_value == '\'' || *new_value == '"') && new_value[value_len-1] == *new_value) { new_value[value_len-1] = '\0'; if (strcmp(attr_ptr->attr_value.s, &new_value[1]) == 0 && (obj_ptr == tgifObj || pFirstMiniLine->first_block->next == NULL)) { same = TRUE; } new_value[value_len-1] = *new_value; } else { if (strcmp(attr_ptr->attr_value.s, new_value) == 0 && (obj_ptr == tgifObj || pFirstMiniLine->first_block->next == NULL)) { same = TRUE; } } if (!same) { int ltx=0, lty=0, rbx=0, rby=0, switch_selected=FALSE; struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; if (obj_ptr != NULL && obj_ptr == tgifObj && gstWBInfo.do_whiteboard) { /* * Now it's allowed. * * MsgBox(TgLoadString(STID_MODIFY_FILE_ATTR_IN_WB), TOOL_NAME, * INFO_MB); * gnAbortExec = TRUE; * return FALSE; */ } if (obj_ptr != NULL && (topSel == NULL || topSel != botSel || topSel->obj != obj_ptr)) { switch_selected = TRUE; topSel = botSel = NULL; if (obj_ptr == tgifObj) AddObj(NULL, topObj, tgifObj); UpdSelBBox(); } if (obj_ptr != NULL) { ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; } PrepareToReplaceAnObj(obj_ptr); if (value_len >= 2 && (*new_value == '\'' || *new_value == '"') && new_value[value_len-1] == *new_value) { new_value[value_len-1] = '\0'; DynStrSet(&attr_ptr->attr_value, &new_value[1]); new_value[value_len-1] = *new_value; } else { DynStrSet(&attr_ptr->attr_value, new_value); } FreeStrBlockList(pFirstMiniLine->first_block->next); pFirstMiniLine->first_block->next = NULL; pFirstMiniLine->last_block = pFirstMiniLine->first_block; UpdAttr(attr_ptr); attr_ptr->obj->detail.t->cached_zoom = 0; if (attr_ptr->obj->detail.t->cached_bitmap != None) { XFreePixmap(mainDisplay, attr_ptr->obj->detail.t->cached_bitmap); attr_ptr->obj->detail.t->cached_bitmap = None; } if (obj_ptr != NULL && attr_ptr->shown) { AdjObjCache(obj_ptr); AdjObjBBox(obj_ptr); } if (gpfReplaceAttrValueCallback != NULL) { ReplAttrValueCallbackInfo ravci; memset(&ravci, 0, sizeof(ReplAttrValueCallbackInfo)); ravci.obj_ptr = obj_ptr; ravci.attr_ptr = attr_ptr; ravci.new_attr_value = new_value; ravci.pv_userdata = gpvReplAttrValueCallbackUserData; if ((gpfReplaceAttrValueCallback)(&ravci)) { } } if (obj_ptr != NULL && obj_ptr == tgifObj) recordCmdIncludeTgifObj = TRUE; RecordReplaceAnObj(obj_ptr); if (obj_ptr != NULL && obj_ptr == tgifObj) recordCmdIncludeTgifObj = FALSE; if (obj_ptr != NULL && switch_selected) { RemoveAllSel(); if (obj_ptr == tgifObj) UnlinkObj(topObj); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); } if (obj_ptr != NULL && replaceAttrFirstValueRedraw && obj_ptr != tgifObj && attr_ptr->shown) { RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), obj_ptr->bbox.ltx-GRID_ABS_SIZE(1), obj_ptr->bbox.lty-GRID_ABS_SIZE(1), obj_ptr->bbox.rbx+GRID_ABS_SIZE(1), obj_ptr->bbox.rby+GRID_ABS_SIZE(1)); } SetFileModified(TRUE); } return (!same); } int ReplaceAttrAllValues(obj_ptr, attr_ptr, ppTopStr, ppBotStr) struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; struct StrRec **ppTopStr, **ppBotStr; /* obj_ptr better be a top-level object */ { int count=0, need_to_change=TRUE; struct StrRec *str_ptr=NULL; MiniLineInfo *pMiniLine=NULL; for (str_ptr=(*ppTopStr); str_ptr != NULL; str_ptr=str_ptr->next) { count++; } /* * if (count != attr_ptr->obj->detail.t->lines) { * need_to_change = TRUE; * } else { * for (str_ptr=(*ppTopStr), * pMiniLine=attr_ptr->obj->detail.t->minilines.first; * str_ptr != NULL; * str_ptr=str_ptr->next, pMiniLine=pMiniLine->next) { * if (pMiniLine == NULL) { * need_to_change = TRUE; * break; * } else { * if (pMiniLine == attr_ptr->obj->detail.t->minilines.first) { * if (strcmp(attr_ptr->attr_value.s, str_ptr->dyn_str.s) != 0) { * need_to_change = TRUE; * break; * } * } else { * if (strcmp(str_ptr->dyn_str.s, str_ptr->dyn_str.s) != 0) { * need_to_change = TRUE; * break; * } * } * } * } * } */ if (need_to_change) { int ltx, lty, rbx, rby, switch_selected=FALSE; MiniLineInfo *pFirstMiniLine=NULL, *pLastMiniLine=NULL; struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; struct StrRec *next_str=NULL; if (obj_ptr == tgifObj && gstWBInfo.do_whiteboard) { /* * Now it's allowed. * * MsgBox(TgLoadString(STID_MODIFY_FILE_ATTR_IN_WB), TOOL_NAME, * INFO_MB); * gnAbortExec = TRUE; * return FALSE; */ } if (topSel == NULL || topSel != botSel || topSel->obj != obj_ptr) { switch_selected = TRUE; topSel = botSel = NULL; if (obj_ptr == tgifObj) AddObj(NULL, topObj, tgifObj); UpdSelBBox(); } ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; PrepareToReplaceAnObj(obj_ptr); FreeMiniLines(&attr_ptr->obj->detail.t->minilines, FALSE); for (str_ptr=(*ppTopStr); str_ptr != NULL; str_ptr=next_str) { next_str = str_ptr->next; pMiniLine = CreateMiniLineFromString(str_ptr->dyn_str.s, &pFirstMiniLine, &pLastMiniLine); FreeStr(str_ptr); } attr_ptr->obj->detail.t->minilines.first = pFirstMiniLine; attr_ptr->obj->detail.t->minilines.last = pLastMiniLine; attr_ptr->obj->detail.t->lines = count; (*ppTopStr) = (*ppBotStr) = NULL; UpdateAttr(attr_ptr->obj->detail.t, attr_ptr); AdjObjCache(obj_ptr); AdjObjBBox(obj_ptr); if (obj_ptr == tgifObj) recordCmdIncludeTgifObj = TRUE; RecordReplaceAnObj(obj_ptr); if (obj_ptr == tgifObj) recordCmdIncludeTgifObj = FALSE; if (switch_selected) { RemoveAllSel(); if (obj_ptr == tgifObj) UnlinkObj(topObj); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); } if (obj_ptr != tgifObj && attr_ptr->shown) { RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), obj_ptr->bbox.ltx-GRID_ABS_SIZE(1), obj_ptr->bbox.lty-GRID_ABS_SIZE(1), obj_ptr->bbox.rbx+GRID_ABS_SIZE(1), obj_ptr->bbox.rby+GRID_ABS_SIZE(1)); } SetFileModified(TRUE); } return need_to_change; } void JustReadFileIntoAttr(FP, attr_ptr, attr_owner_obj) FILE *FP; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj; { int ltx=attr_owner_obj->bbox.ltx, lty=attr_owner_obj->bbox.ltx; int rbx=attr_owner_obj->bbox.rbx, rby=attr_owner_obj->bbox.rby; int saved_color_index=colorIndex; int x=attr_ptr->obj->x, baseline_y=attr_ptr->obj->detail.t->baseline_y; struct ObjRec *text_obj_ptr=NULL; struct TextRec *text_ptr=attr_ptr->obj->detail.t; colorIndex = text_ptr->minilines.first->first_block->seg->color; PushCurFont(); ObjFontInfoToCurFontInfo(text_ptr); StrSegInfoToCurFontInfo(GetTextPtrFirstStrSeg(text_ptr)); penPat = attr_ptr->obj->detail.t->pen; objFill = attr_ptr->obj->detail.t->fill; transPat = attr_ptr->obj->trans_pat; SetCanvasFont(); FreeTextObj(attr_ptr->obj); attr_ptr->obj = NULL; text_obj_ptr = FormTextObjectFromFile(FP, x, baseline_y); PopCurFont(); colorIndex = saved_color_index; if (text_obj_ptr == NULL) { DynStrSet(&attr_ptr->attr_value, ""); } else { MiniLineInfo *pMiniLine=text_obj_ptr->detail.t->minilines.first; if (pMiniLine != NULL) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); DynStrSet(&attr_ptr->attr_value, tmp_buf); if (need_to_free_tmp_buf) UtilFree(tmp_buf); } else { DynStrSet(&attr_ptr->attr_value, ""); } } attr_ptr->obj = text_obj_ptr; text_obj_ptr->detail.t->attr = attr_ptr; UpdAttr(attr_ptr); if (attr_ptr->shown) { AdjObjCache(attr_owner_obj); AdjObjBBox(attr_owner_obj); } RecordReplaceAnObj(attr_owner_obj); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), attr_owner_obj->bbox.ltx-GRID_ABS_SIZE(1), attr_owner_obj->bbox.lty-GRID_ABS_SIZE(1), attr_owner_obj->bbox.rbx+GRID_ABS_SIZE(1), attr_owner_obj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } static int ReturnInterruptedExec() { if (!execInterruptEnabled) { if (execInterruptQueued) { sprintf(gszMsgBox, TgLoadString(STID_USER_INTR_TOOL_WAIT_CLEANUP), TOOL_NAME); return (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) == MB_ID_YES); } execInterruptQueued = TRUE; return FALSE; } return TRUE; } static int execTightLoopWait=FALSE; static int execTightLoopOneLineStatus=FALSE; static char execTightLoopStatusBuf[MAX_STATUS_BTNS+1][MAXSTRING+1]; static void ExitExecTightLoop() { RestoreStatusStringsFromBuf(execTightLoopStatusBuf, execTightLoopOneLineStatus); execTightLoopWait = FALSE; } static void EnterExecTightLoop() { SaveStatusStringsIntoBuf(execTightLoopStatusBuf, &execTightLoopOneLineStatus); execTightLoopWait = TRUE; } static int CheckExecInterrupt(orig_cmd) char *orig_cmd; { int check_any_button=execInterruptEnabled; XEvent ev; if (mainDisplay == NULL) return FALSE; while (XCheckMaskEvent(mainDisplay, StructureNotifyMask, &ev)) { if (iconWindowShown) { if ((ev.xany.window == iconBaseWindow && ev.type == UnmapNotify) || (ev.xany.window == mainWindow && ev.type == MapNotify)) { XPutBackEvent(mainDisplay, &ev); return ReturnInterruptedExec(); } } else if ((ev.xany.window == iconBaseWindow && ev.type == MapNotify) || (ev.xany.window == mainWindow && ev.type == UnmapNotify)) { XPutBackEvent(mainDisplay, &ev); return ReturnInterruptedExec(); } else if (ev.type == ConfigureNotify) { Reconfigure(FALSE); } } while (XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { if (iconWindowShown) { if (ev.xany.window == mainWindow && ev.type == VisibilityNotify && ev.xvisibility.state == VisibilityUnobscured) { XPutBackEvent(mainDisplay, &ev); return ReturnInterruptedExec(); } else { ExposeEventHandler(&ev, TRUE); } } else { if (ev.xany.window == iconBaseWindow && ev.type == VisibilityNotify && ev.xvisibility.state == VisibilityUnobscured) { XPutBackEvent(mainDisplay, &ev); return ReturnInterruptedExec(); } else { ExposeEventHandler(&ev, TRUE); } } } if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); while (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) ; } if (ESCPressed() || (check_any_button && XCheckMaskEvent(mainDisplay, ButtonPressMask | KeyPressMask, &ev)) || CheckInterrupt(TRUE)) { if (orig_cmd == NULL) { sprintf(gszMsgBox, TgLoadString(STID_USER_INTR)); } else { sprintf(gszMsgBox, TgLoadString(STID_FUNC_USER_INTR), orig_cmd); } Msg(gszMsgBox); return ReturnInterruptedExec(); } if (execTightLoopWait) { while (XCheckWindowEvent(mainDisplay, dummyWindow1, EnterWindowMask|LeaveWindowMask, &ev)) { switch (ev.type) { case EnterNotify: SetMouseStatus(TgLoadCachedString(CSTID_INTERRUPT), TgLoadCachedString(CSTID_INTERRUPT), TgLoadCachedString(CSTID_INTERRUPT)); break; case LeaveNotify: RestoreStatusStringsFromBuf(execTightLoopStatusBuf, execTightLoopOneLineStatus); break; } } } if (!check_any_button) { while (XCheckMaskEvent(mainDisplay, ButtonPressMask|KeyPressMask, &ev)) ; } return FALSE; } static int IntExpression(expr, p_ival, orig_cmd) char *expr, *orig_cmd; int *p_ival; { struct VRec v; if (EvalExpr(expr, &v)) { switch (v.vtype) { case NULL_VAL: break; case INT_VAL: if (p_ival != NULL) *p_ival = v.val.i; return TRUE; case DBL_VAL: break; case STR_VAL: break; default: break; } } sprintf(gszMsgBox, TgLoadString(STID_BAD_EVAL_INT_EXP_EXEC_CMD), expr, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } static int FloatExpression(expr, p_dval, orig_cmd) char *expr, *orig_cmd; double *p_dval; { struct VRec v; if (EvalExpr(expr, &v)) { switch (v.vtype) { case NULL_VAL: break; case INT_VAL: if (p_dval != NULL) *p_dval = (double)v.val.i; return TRUE; case DBL_VAL: if (p_dval != NULL) *p_dval = v.val.d; return TRUE; case STR_VAL: break; default: break; } } sprintf(gszMsgBox, TgLoadString(STID_BAD_EVAL_FLOAT_EXP_EXEC_CMD), expr, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } static void SelectAnObj(sub_obj, owner_obj, top_owner, pp_saved_top_sel, pp_saved_bot_sel) struct ObjRec *sub_obj, *owner_obj, *top_owner; struct SelRec **pp_saved_top_sel, **pp_saved_bot_sel; { if (pp_saved_top_sel != NULL && pp_saved_bot_sel != NULL) { *pp_saved_top_sel = topSel; *pp_saved_bot_sel = botSel; } else { if (topSel != NULL) RemoveAllSel(); } topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->next = topSel->prev = NULL; topSel->obj = (owner_obj==NULL ? sub_obj : top_owner); UpdSelBBox(); } /* --------------------- Exec Routines --------------------- */ int ExecLaunch(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* launch(attribute_to_launch); */ { char *attr_name=argv[0]; struct AttrRec *attr_ptr; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); return (DoLaunch(attr_ptr, obj_ptr)); } int ExecExec(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* exec(attribute_to_exec); */ { char *attr_name=argv[0]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); return (DoExec(attr_ptr, attr_owner_obj)); } int ExecMktemp(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* mktemp(str,result_attribute); */ { char *file_name=argv[0], *attr_name=argv[1]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; int rc=TRUE; UtilRemoveQuotes(file_name); UtilRemoveQuotes(attr_name); UtilTrimBlanks(file_name); UtilTrimBlanks(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); #ifndef _DONT_USE_MKTEMP if (mktemp(file_name) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_FUNC_CMD_EXEC_ABORT), "mktemp()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); rc = FALSE; } else { char *psz=UtilStrRChr(file_name, DIR_SEP); int changed=FALSE; if (psz != NULL) { for (psz++; *psz != '\0'; psz++) { if ((*psz >= '0' && *psz <= '9') || (*psz >= 'a' && *psz <= 'z') || (*psz >= 'A' && *psz <= 'Z')) { } else { *psz = 'Q'; changed = TRUE; } } } if (changed && mktemp(file_name) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_FUNC_CMD_EXEC_ABORT), "mktemp()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); rc = FALSE; } else { unlink(file_name); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, file_name); } } #else /* _DONT_USE_MKTEMP */ { int fd=(-1); char *dup_fname=UtilStrDup(file_name), path[MAXPATHLENGTH]; if (dup_fname == NULL) FailAllocMessage(); if ((fd=mkstemp(dup_fname)) == (-1)) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OBTAIN_TMP_FILE_NAME), file_name); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } rc = FALSE; } else { close(fd); UtilStrCpyN(path, sizeof(path), dup_fname); } UtilFree(dup_fname); /* * int len=0; * char *psz=NULL, fname[MAXPATHLENGTH], path[MAXPATHLENGTH]; * * UtilStrCpyN(fname, sizeof(fname), file_name); * len = strlen(fname); * while (len > 0 && fname[len-1] == 'X') { * fname[--len] = '\0'; * } * psz = UtilStrRChr(fname, DIR_SEP); * if (psz == NULL) { * UtilStrCpyN(path, sizeof(path), (char*)tempnam(NULL, fname)); * } else { * *psz = '\0'; * UtilStrCpyN(path, sizeof(path), (char*)tempnam(fname, &psz[1])); * *psz = DIR_SEP; * } */ UtilTrimBlanks(path); unlink(path); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, path); } #endif /* ~_DONT_USE_MKTEMP */ return rc; } int ExecUseTemplate(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* create_file_using_simple_template(template_file, */ /* output_file,string_to_match,substitution_attribute); */ { char *template_name=argv[0], *file_name=argv[1]; char *match_str=argv[2], *attr_name=argv[3], msg[MAXSTRING+1]; struct AttrRec *attr_ptr=NULL; struct TextRec *text_ptr=NULL; FILE *in_fp=NULL, *out_fp=NULL; UtilRemoveQuotes(template_name); UtilRemoveQuotes(file_name); UtilRemoveQuotes(match_str); UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if ((out_fp=fopen(file_name, "w")) != NULL && (in_fp=fopen(template_name, "r")) != NULL) { int len_to_match=strlen(match_str), len, rc=TRUE; char tmp_buf[MAXSTRING+1]; writeFileFailed = FALSE; while (fgets(tmp_buf, MAXSTRING, in_fp) != NULL) { len = strlen(tmp_buf); if (tmp_buf[len-1] == '\n') { tmp_buf[--len] = '\0'; if (len==len_to_match && strcmp(tmp_buf, match_str)==0) { if (*attr_ptr->attr_value.s != '\0') { if (fprintf(out_fp, "%s\n", attr_ptr->attr_value.s) == EOF) { writeFileFailed = TRUE; } } text_ptr = attr_ptr->obj->detail.t; if (text_ptr->minilines.first != NULL) { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=text_ptr->minilines.first->next; pMiniLine != NULL; pMiniLine = pMiniLine->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); if (fprintf(out_fp, "%s\n", tmp_buf) == EOF) { writeFileFailed = TRUE; } if (need_to_free_tmp_buf) UtilFree(tmp_buf); if (writeFileFailed) break; } } } else if (fprintf(out_fp, "%s\n", tmp_buf) == EOF) { writeFileFailed = TRUE; } } else if (len==len_to_match && strcmp(tmp_buf, match_str)==0) { if (*attr_ptr->attr_value.s != '\0') { if (fprintf(out_fp, "%s\n", attr_ptr->attr_value.s) == EOF) { writeFileFailed = TRUE; } } text_ptr = attr_ptr->obj->detail.t; if (text_ptr->minilines.first != NULL) { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=text_ptr->minilines.first->next; pMiniLine != NULL; pMiniLine = pMiniLine->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); if (fprintf(out_fp, "%s\n", tmp_buf) == EOF) { writeFileFailed = TRUE; } if (need_to_free_tmp_buf) UtilFree(tmp_buf); if (writeFileFailed) break; } } } else if (fprintf(out_fp, "%s\n", tmp_buf) == EOF) { writeFileFailed = TRUE; } } if (writeFileFailed) { FailToWriteFileMessage(file_name); rc = FALSE; } fclose(in_fp); fclose(out_fp); return rc; } else if (out_fp == NULL) { sprintf(msg, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), file_name); MsgBox(msg, TOOL_NAME, INFO_MB); } else if (in_fp == NULL) { sprintf(msg, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), template_name); MsgBox(msg, TOOL_NAME, INFO_MB); } if (out_fp != NULL) fclose(out_fp); if (in_fp != NULL) fclose(in_fp); return FALSE; } #define UPDATE_EPS_CHILD 0 #define UPDATE_XBM_CHILD 1 #define UPDATE_XPM_CHILD 2 #define UPDATE_CHILD_NO_ALIGNMENT 0 #define UPDATE_CHILD_NORMAL_ALIGNMENT 1 #define UPDATE_CHILD_NO_OVERLAP_ALIGNMENT 2 static int updateChildUsingAlignment=INVALID; static int ExecUpdChild(argv, obj_ptr, orig_cmd, upd_type) char **argv, *orig_cmd; struct ObjRec *obj_ptr; int upd_type; /* update_eps_child(eps_file_name); */ /* update_xbm_child(xbm_file_name); */ /* update_xpm_child(xpm_file_name); */ { struct XPmRec *xpm_ptr=NULL; char *file_name=argv[0], png_fname[MAXPATHLENGTH], ppm6_fname[MAXPATHLENGTH]; char jpg_fname[MAXPATHLENGTH]; char msg[MAXPATHLENGTH+1], deflated_fname[MAXPATHLENGTH]; char **lines=NULL, write_date[32]; struct ObjRec *sub_obj_ptr=NULL, *del_obj=NULL, *tmp_obj; int rc=BitmapOpenFailed, len=0, png_not_xpm=FALSE, jpg_not_xpm=FALSE; int num_lines=0, epsf_level=0, image_w=0, image_h=0; int del_obj_ltx=0, del_obj_lty=0, ltx=0, lty=0; int rbx=0, rby=0, x_hot, y_hot, w=0, h=0, ncolors=0; int chars_per_pixel=0, first_pixel_is_bg=0, *pixels=NULL; struct BBRec parent_obbox; unsigned int ui_image_w=0, ui_image_h=0; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL; float llx=0, lly=0, urx=0, ury=0; Pixmap bitmap=None, pixmap=None; XImage *image=NULL, *bitmap_image=NULL; *png_fname = *jpg_fname = *ppm6_fname = '\0'; if (obj_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_NO_OBJ_SPEC_WHILE_EXEC_CMD), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } UtilRemoveQuotes(file_name); if (updateChildUsingAlignment == INVALID) { char *c_ptr; updateChildUsingAlignment = UPDATE_CHILD_NO_ALIGNMENT; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UpdateChildUsingAlignment")) != NULL) { if (UtilStrICmp(c_ptr, "true") == 0) { updateChildUsingAlignment = UPDATE_CHILD_NORMAL_ALIGNMENT; } else if (UtilStrICmp(c_ptr, "no_overlap") == 0) { updateChildUsingAlignment = UPDATE_CHILD_NO_OVERLAP_ALIGNMENT; } } } switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: sprintf(msg, TgLoadString(STID_FUNC_ONLY_WORK_COMPOSITE_OBJ), orig_cmd); MsgBox(msg, TOOL_NAME, INFO_MB); return FALSE; } parent_obbox.ltx = obj_ptr->obbox.rbx; parent_obbox.lty = obj_ptr->obbox.rby; parent_obbox.rbx = obj_ptr->obbox.ltx; parent_obbox.rby = obj_ptr->obbox.lty; switch (upd_type) { case UPDATE_EPS_CHILD: for (tmp_obj=obj_ptr->detail.r->last; tmp_obj!=NULL; tmp_obj=tmp_obj->prev) { if (tmp_obj->type==OBJ_XBM && tmp_obj->detail.xbm->real_type!=XBM_XBM) { del_obj_ltx = tmp_obj->obbox.ltx; del_obj_lty = tmp_obj->obbox.lty; del_obj = tmp_obj; if (!updateChildUsingAlignment) break; } else if (updateChildUsingAlignment) { if (tmp_obj->obbox.ltx < parent_obbox.ltx) parent_obbox.ltx = tmp_obj->obbox.ltx; if (tmp_obj->obbox.lty < parent_obbox.lty) parent_obbox.lty = tmp_obj->obbox.lty; if (tmp_obj->obbox.rbx > parent_obbox.rbx) parent_obbox.rbx = tmp_obj->obbox.rbx; if (tmp_obj->obbox.rby > parent_obbox.rby) parent_obbox.rby = tmp_obj->obbox.rby; } } break; case UPDATE_XBM_CHILD: for (tmp_obj=obj_ptr->detail.r->last; tmp_obj!=NULL; tmp_obj=tmp_obj->prev) { if (tmp_obj->type==OBJ_XBM && tmp_obj->detail.xbm->real_type==XBM_XBM) { del_obj_ltx = tmp_obj->obbox.ltx; del_obj_lty = tmp_obj->obbox.lty; del_obj = tmp_obj; if (!updateChildUsingAlignment) break; } else if (updateChildUsingAlignment) { if (tmp_obj->obbox.ltx < parent_obbox.ltx) parent_obbox.ltx = tmp_obj->obbox.ltx; if (tmp_obj->obbox.lty < parent_obbox.lty) parent_obbox.lty = tmp_obj->obbox.lty; if (tmp_obj->obbox.rbx > parent_obbox.rbx) parent_obbox.rbx = tmp_obj->obbox.rbx; if (tmp_obj->obbox.rby > parent_obbox.rby) parent_obbox.rby = tmp_obj->obbox.rby; } } break; case UPDATE_XPM_CHILD: for (tmp_obj=obj_ptr->detail.r->last; tmp_obj!=NULL; tmp_obj=tmp_obj->prev) { if (tmp_obj->type==OBJ_XPM) { del_obj_ltx = tmp_obj->obbox.ltx; del_obj_lty = tmp_obj->obbox.lty; del_obj = tmp_obj; if (!updateChildUsingAlignment) break; } else if (updateChildUsingAlignment) { if (tmp_obj->obbox.ltx < parent_obbox.ltx) parent_obbox.ltx = tmp_obj->obbox.ltx; if (tmp_obj->obbox.lty < parent_obbox.lty) parent_obbox.lty = tmp_obj->obbox.lty; if (tmp_obj->obbox.rbx > parent_obbox.rbx) parent_obbox.rbx = tmp_obj->obbox.rbx; if (tmp_obj->obbox.rby > parent_obbox.rby) parent_obbox.rby = tmp_obj->obbox.rby; } } len = strlen(file_name); if (len > 4 && UtilStrNCaseCmp(&file_name[len-4], ".png", 4) == 0) { png_not_xpm = TRUE; UtilStrCpyN(png_fname, sizeof(png_fname), file_name); strcpy(&file_name[len-4], ".xpm"); } else if (len > 4 && UtilStrNCaseCmp(&file_name[len-4], ".jpg", 4) == 0) { jpg_not_xpm = TRUE; UtilStrCpyN(jpg_fname, sizeof(jpg_fname), file_name); strcpy(&file_name[len-4], ".xpm"); } break; default: return BadCmd(orig_cmd); } if (del_obj == NULL) { del_obj_ltx = obj_ptr->obbox.ltx; /* * Use lty to cover the invisible object. * Use to use rby to tile below the invisible object. */ del_obj_lty = obj_ptr->obbox.lty; } importingFile = TRUE; switch (upd_type) { case UPDATE_EPS_CHILD: rc = MyReadEPSFile(file_name, &image_w, &image_h, &bitmap, &image, &num_lines, &lines, &epsf_level, &llx, &lly, &urx, &ury, write_date); break; case UPDATE_XBM_CHILD: rc = XReadBitmapFile(mainDisplay, mainWindow, file_name, &ui_image_w, &ui_image_h, &bitmap, &x_hot, &y_hot); image_w = ui_image_w; image_h = ui_image_h; break; case UPDATE_XPM_CHILD: if (png_not_xpm || jpg_not_xpm) { if (fullTrueColorMode && HasZlibSupport()) { if (png_not_xpm) { rc = ConvertPngToPpm6(png_fname, ppm6_fname, sizeof(ppm6_fname)); } else if (jpg_not_xpm) { rc = ConvertJpegToPpm6(jpg_fname, ppm6_fname, sizeof(ppm6_fname)); } else { /* should not come here */ rc = BitmapFileInvalid; } if (rc) { ResetPngHeaderInfo(&gPngHeaderInfo); sub_obj_ptr = CreatePpmTrueObjFromFile(ppm6_fname); } if (sub_obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile(ppm6_fname, deflated_fname)) { /* nothing to do here */ } else { unlink(ppm6_fname); if (sub_obj_ptr != NULL) FreeObj(sub_obj_ptr); importingFile = FALSE; return FALSE; } unlink(ppm6_fname); xpm_ptr = sub_obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; unlink(deflated_fname); rc = BitmapSuccess; } else { if (png_not_xpm) { rc = ConvertPngToXpm(png_fname, file_name, strlen(file_name)+1); } else if (jpg_not_xpm) { rc = ConvertJpegToXpm(jpg_fname, file_name, strlen(file_name)+1); } else { /* should not come here */ rc = BitmapFileInvalid; } if (rc) { rc = MyReadPixmapFile(file_name, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); } else { rc = BitmapFileInvalid; } } } else { rc = MyReadPixmapFile(file_name, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); } break; } if (rc != BitmapSuccess) { importingFile = FALSE; sprintf(msg, TgLoadString(STID_FUNC_FAIL_TO_IMPORT_GIVEN), orig_cmd, file_name); MsgBox(msg, TOOL_NAME, INFO_MB); return FALSE; } ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; PrepareToReplaceAnObj(obj_ptr); switch (upd_type) { case UPDATE_EPS_CHILD: saveEPSLines = TRUE; sub_obj_ptr = CreateEPSObj(file_name, image_w, image_h, bitmap, image, num_lines, lines, epsf_level, &llx, &lly, &urx, &ury, write_date); saveEPSLines = FALSE; if (strcmp(defaultEPSScalingStr,"1") != 0) { ScaleAnEPSObj(sub_obj_ptr, &defaultEPSScaling); } break; case UPDATE_XBM_CHILD: sub_obj_ptr = CreateXBmObj(image_w, image_h, image_w, image_h, bitmap, image); break; case UPDATE_XPM_CHILD: if (sub_obj_ptr == NULL) { sub_obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); } else { /* already created */ } break; } if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } if (updateChildUsingAlignment != UPDATE_CHILD_NO_ALIGNMENT) { switch (horiAlign) { case ALIGN_N: case ALIGN_L: del_obj_ltx = parent_obbox.ltx; break; case ALIGN_C: case ALIGN_S: del_obj_ltx = ((parent_obbox.ltx+parent_obbox.rbx)>>1) - ((sub_obj_ptr->obbox.rbx-sub_obj_ptr->obbox.ltx)>>1); break; case ALIGN_R: del_obj_ltx = parent_obbox.rbx - (sub_obj_ptr->obbox.rbx-sub_obj_ptr->obbox.ltx); break; } switch (updateChildUsingAlignment) { case UPDATE_CHILD_NORMAL_ALIGNMENT: switch (vertAlign) { case ALIGN_T: del_obj_lty = parent_obbox.lty; break; case ALIGN_M: case ALIGN_S: del_obj_lty = ((parent_obbox.lty+parent_obbox.rby)>>1) - ((sub_obj_ptr->obbox.rby-sub_obj_ptr->obbox.lty)>>1); break; case ALIGN_B: del_obj_lty = parent_obbox.rby - (sub_obj_ptr->obbox.rby-sub_obj_ptr->obbox.lty); break; case ALIGN_N: del_obj_lty = parent_obbox.rby; break; } break; case UPDATE_CHILD_NO_OVERLAP_ALIGNMENT: switch (vertAlign) { case ALIGN_T: del_obj_lty = parent_obbox.lty - (sub_obj_ptr->obbox.rby-sub_obj_ptr->obbox.lty); break; case ALIGN_M: case ALIGN_S: del_obj_lty = ((parent_obbox.lty+parent_obbox.rby)>>1) - ((sub_obj_ptr->obbox.rby-sub_obj_ptr->obbox.lty)>>1); break; case ALIGN_B: case ALIGN_N: del_obj_lty = parent_obbox.rby; break; } break; } } MoveObj(sub_obj_ptr, del_obj_ltx-sub_obj_ptr->obbox.ltx, del_obj_lty-sub_obj_ptr->obbox.lty); if (del_obj != NULL) { if (del_obj == obj_ptr->detail.r->first) { obj_ptr->detail.r->first = del_obj->next; } else { del_obj->prev->next = del_obj->next; } if (del_obj == obj_ptr->detail.r->last) { obj_ptr->detail.r->last = del_obj->prev; } else { del_obj->next->prev = del_obj->prev; } FreeObj(del_obj); } sub_obj_ptr->prev = NULL; sub_obj_ptr->next = obj_ptr->detail.r->first; if (obj_ptr->detail.r->first == NULL) { obj_ptr->detail.r->last = sub_obj_ptr; } else { obj_ptr->detail.r->first->prev = sub_obj_ptr; } obj_ptr->detail.r->first = sub_obj_ptr; AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), obj_ptr->bbox.ltx-GRID_ABS_SIZE(1), obj_ptr->bbox.lty-GRID_ABS_SIZE(1), obj_ptr->bbox.rbx+GRID_ABS_SIZE(1), obj_ptr->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); importingFile = FALSE; return TRUE; } int ExecUpdEPSChild(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; { return ExecUpdChild(argv, obj_ptr, orig_cmd, UPDATE_EPS_CHILD); } int ExecUpdXBMChild(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; { return ExecUpdChild(argv, obj_ptr, orig_cmd, UPDATE_XBM_CHILD); } int ExecUpdXPMChild(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; { return ExecUpdChild(argv, obj_ptr, orig_cmd, UPDATE_XPM_CHILD); } static int ExecDelChild(argv, obj_ptr, orig_cmd, upd_type) char **argv, *orig_cmd; struct ObjRec *obj_ptr; int upd_type; /* delete_eps_child(obj_name); */ /* delete_xbm_child(obj_name); */ /* delete_xpm_child(obj_name); */ { char *obj_name=argv[0]; struct ObjRec *top_owner=NULL, *named_obj=NULL; struct ObjRec *del_obj=NULL, *tmp_obj=NULL; int ltx=0, lty=0, rbx=0, rby=0; UtilRemoveQuotes(obj_name); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, NULL, &top_owner); if (named_obj == NULL) { return BadObjName(obj_name, orig_cmd); } switch (named_obj->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: sprintf(gszMsgBox, TgLoadString(STID_FUNC_ONLY_WORK_COMPOSITE_OBJ), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ltx = top_owner->bbox.ltx; lty = top_owner->bbox.lty; rbx = top_owner->bbox.rbx; rby = top_owner->bbox.rby; switch (upd_type) { case UPDATE_EPS_CHILD: for (tmp_obj=named_obj->detail.r->last; tmp_obj!=NULL; tmp_obj=tmp_obj->prev) { if (tmp_obj->type==OBJ_XBM && tmp_obj->detail.xbm->real_type!=XBM_XBM) { del_obj = tmp_obj; break; } } break; case UPDATE_XBM_CHILD: for (tmp_obj=named_obj->detail.r->last; tmp_obj!=NULL; tmp_obj=tmp_obj->prev) { if (tmp_obj->type==OBJ_XBM && tmp_obj->detail.xbm->real_type==XBM_XBM) { del_obj = tmp_obj; break; } } break; case UPDATE_XPM_CHILD: for (tmp_obj=named_obj->detail.r->last; tmp_obj!=NULL; tmp_obj=tmp_obj->prev) { if (tmp_obj->type==OBJ_XPM) { del_obj = tmp_obj; break; } } break; default: return BadCmd(orig_cmd); } if (del_obj == NULL) { /* no child to delete, no problem */ return TRUE; } PrepareToReplaceAnObj(top_owner); if (del_obj != NULL) { if (del_obj == named_obj->detail.r->first) { named_obj->detail.r->first = del_obj->next; } else { del_obj->prev->next = del_obj->next; } if (del_obj == named_obj->detail.r->last) { named_obj->detail.r->last = del_obj->prev; } else { del_obj->next->prev = del_obj->prev; } FreeObj(del_obj); } AdjObjBBox(top_owner); RecordReplaceAnObj(top_owner); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), top_owner->bbox.ltx-GRID_ABS_SIZE(1), top_owner->bbox.lty-GRID_ABS_SIZE(1), top_owner->bbox.rbx+GRID_ABS_SIZE(1), top_owner->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecDelEPSChild(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; { return ExecDelChild(argv, obj_ptr, orig_cmd, UPDATE_EPS_CHILD); } int ExecDelXBMChild(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; { return ExecDelChild(argv, obj_ptr, orig_cmd, UPDATE_XBM_CHILD); } int ExecDelXPMChild(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; { return ExecDelChild(argv, obj_ptr, orig_cmd, UPDATE_XPM_CHILD); } #ifndef _NO_GETTIMEOFDAY static long ms_time(tv) struct timeval *tv; { return ((long)(tv->tv_usec / 1000.0)) + ((long)(tv->tv_sec * 1000)); } #endif /* ~_NO_GETTIMEOFDAY */ #define FD_STYLE_LINEAR 0 #define FD_STYLE_PINGPONG 1 #define FD_FORWARD 0 #define FD_REVERSE 1 int ExecFlipDeck(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* flip_deck(times,frames_per_second,style); */ /* style=[linear | pingpong] */ { char *times_str=argv[0]; char *fps_str=argv[1], *style_str=argv[2]; int num_bm, iteration, times, fps, style; int rc=TRUE; struct ObjRec *bm_obj=NULL, *cur_obj=NULL, *prev_obj=NULL, *next_obj=NULL; struct BBRec obbox; int select_width=XConnectionNumber(mainDisplay)+1; #ifdef _NO_GETTIMEOFDAY struct timeb start; #else /* ~_NO_GETTIMEOFDAY */ struct timeval start; struct timezone zone; #endif /* _NO_GETTIMEOFDAY */ long ms_start_time, ms_frame_interval; fd_set fdset; memset(&obbox, 0, sizeof(struct BBRec)); if (obj_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_NO_OBJ_SPEC_WHILE_EXEC_CMD), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } UtilRemoveQuotes(times_str); UtilRemoveQuotes(fps_str); UtilRemoveQuotes(style_str); switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: sprintf(execDummyStr, TgLoadString(STID_FUNC_ONLY_WORK_COMPOSITE_OBJ), orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } num_bm = 0; for (bm_obj=obj_ptr->detail.r->last; bm_obj != NULL; bm_obj=bm_obj->prev) { if (bm_obj->type != OBJ_XBM && bm_obj->type != OBJ_XPM) { sprintf(gszMsgBox, TgLoadString(STID_FUNC_OBJ_NON_XBM_XPM_SUB_OBJS), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return (FALSE); } else if (num_bm++ == 0) { obbox.ltx = bm_obj->obbox.ltx; obbox.lty = bm_obj->obbox.lty; obbox.rbx = bm_obj->obbox.rbx; obbox.rby = bm_obj->obbox.rby; } else { if (obbox.ltx!=bm_obj->obbox.ltx || obbox.lty!=bm_obj->obbox.lty || obbox.rbx!=bm_obj->obbox.rbx || obbox.rby!=bm_obj->obbox.rby) { sprintf(gszMsgBox, TgLoadString(STID_FUNC_DIFF_SZ_XBM_XPM_SUBOBJS), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } } if (num_bm < 2) { sprintf(gszMsgBox, TgLoadString(STID_FUNC_MORE_1_XBM_XPM_SUBOBJS), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (!IntExpression(fps_str, &fps, orig_cmd)) { return FALSE; } if (fps < 1 || fps > 60) { sprintf(gszMsgBox, TgLoadString(STID_FUNC_ARG_RANGE), orig_cmd, "frames_per_second", 1, 60, fps); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ms_frame_interval = round(1000 / fps) - 1; if (strcmp(style_str, "linear") == 0) { style = FD_STYLE_LINEAR; } else if (strcmp(style_str, "ping_pong") == 0) { style = FD_STYLE_PINGPONG; } else { sprintf(gszMsgBox, TgLoadString(STID_FUNC_UNDEFINED_ARG), orig_cmd, "style", 1, 60); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (strcmp(times_str, "infinite") == 0) { times = (-1); } else { if (!IntExpression(times_str, ×, orig_cmd)) { return FALSE; } } iteration = 0; #ifdef _NO_GETTIMEOFDAY ftime(&start); ms_start_time = ((long)start.time * 1000) + ((long)start.millitm); #else /* ~_NO_GETTIMEOFDAY */ gettimeofday(&start, &zone); ms_start_time = ms_time(&start); #endif /* _NO_GETTIMEOFDAY */ while (rc == TRUE && (times < 0 || iteration < times)) { int looping=TRUE, direction=FD_FORWARD; if (times >= 0) iteration++; cur_obj = obj_ptr->detail.r->first; while (looping) { struct timeval timeout; #ifdef _NO_GETTIMEOFDAY struct timeb now; #else /* ~_NO_GETTIMEOFDAY */ struct timeval now; #endif /* _NO_GETTIMEOFDAY */ long ms_cur_time, ms_interval; int status; prev_obj = cur_obj->prev; next_obj = cur_obj->next; cur_obj->prev = cur_obj->next = NULL; switch (cur_obj->type) { case OBJ_XBM: if (iconWindowShown) { DrawXBmObj(iconWindow, 0, 0, cur_obj); } else { DrawXBmObj(drawWindow, drawOrigX, drawOrigY, cur_obj); } break; case OBJ_XPM: if (iconWindowShown) { DrawXPmObj(iconWindow, 0, 0, cur_obj); } else { DrawXPmObj(drawWindow, drawOrigX, drawOrigY, cur_obj); } break; } XSync(mainDisplay, FALSE); cur_obj->prev = prev_obj; cur_obj->next = next_obj; switch (style) { case FD_STYLE_LINEAR: if ((cur_obj=cur_obj->next) == NULL) looping = FALSE; break; case FD_STYLE_PINGPONG: switch (direction) { case FD_FORWARD: if (cur_obj->next == NULL) { if ((cur_obj=cur_obj->prev) == obj_ptr->detail.r->first) { looping = FALSE; } else { direction = FD_REVERSE; } } else { cur_obj = cur_obj->next; } break; case FD_REVERSE: if ((cur_obj=cur_obj->prev) == obj_ptr->detail.r->first) { looping = FALSE; } break; } break; } EnterExecTightLoop(); do { FD_ZERO(&fdset); FD_SET(select_width-1, &fdset); #ifdef _NO_GETTIMEOFDAY ftime(&now); ms_cur_time = ((long)now.time * 1000) + ((long)now.millitm); #else /* ~_NO_GETTIMEOFDAY */ gettimeofday(&now, &zone); ms_cur_time = ms_time(&now); #endif /* _NO_GETTIMEOFDAY */ ms_interval = ms_start_time + ms_frame_interval - ms_cur_time; while (ms_interval <= 0) { ms_start_time = ms_cur_time; ms_interval = ms_start_time + ms_frame_interval - ms_cur_time; } timeout.tv_sec = 0; timeout.tv_usec = 1000 * ms_interval; #ifdef __hpux status = select(select_width, (int*)&fdset, NULL, NULL, &timeout); #else /* !__hpux */ status = select(select_width, &fdset, NULL, NULL, &timeout); #endif /* __hpux */ if (status < 0) { if (errno == EINTR) { /* interrupted by a system call, minor timing problem */ CheckInterrupt(TRUE); } else { sprintf(gszMsgBox, TgLoadString(STID_FUNC_SELECT_SYS_CALL_FAILED), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); looping = FALSE; rc = FALSE; break; } } else if (status == 0) { /* timeout without any X events */ CheckInterrupt(TRUE); break; } else { if (CheckExecInterrupt(orig_cmd)) { looping = FALSE; rc = FALSE; userAbortExec = TRUE; break; } } } while (looping && ms_interval > 0); ExitExecTightLoop(); } } /* RedrawAnArea(botObj, obj_ptr->bbox.ltx-GRID_ABS_SIZE(1), obj_ptr->bbox.lty-GRID_ABS_SIZE(1), obj_ptr->bbox.rbx+GRID_ABS_SIZE(1), obj_ptr->bbox.rby+GRID_ABS_SIZE(1)); */ cur_obj = obj_ptr->detail.r->first; prev_obj = cur_obj->prev; next_obj = cur_obj->next; cur_obj->prev = cur_obj->next = NULL; switch (cur_obj->type) { case OBJ_XBM: if (iconWindowShown) { DrawXBmObj(iconWindow, 0, 0, cur_obj); } else { DrawXBmObj(drawWindow, drawOrigX, drawOrigY, cur_obj); } break; case OBJ_XPM: if (iconWindowShown) { DrawXPmObj(iconWindow, 0, 0, cur_obj); } else { DrawXPmObj(drawWindow, drawOrigX, drawOrigY, cur_obj); } break; } XSync(mainDisplay, FALSE); cur_obj->prev = prev_obj; cur_obj->next = next_obj; return rc; } static int DoReadFileIntoAttr(attr_ptr, attr_owner_obj, file_name, orig_cmd) struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj; char *file_name, *orig_cmd; { FILE *fp=NULL; if (*file_name == '|') { if (inHyperSpace && !allowLaunchInHyperSpace) { XFlush(mainDisplay); XSync(mainDisplay, False); sprintf(gszMsgBox, TgLoadString(STID_LAUNCH_NOT_AUTO_IN_HYPER_EXEC), &file_name[1]); if (MsgBox(gszMsgBox, TOOL_NAME, YN_MB) != MB_ID_YES) { MsgBox(TgLoadString(STID_USER_ABORT_LAUNCH_IN_HYPER), TOOL_NAME, INFO_MB); return FALSE; } } if (!FindProgramInPath(&file_name[1], NULL, FALSE)) { return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), &file_name[1]); SetStringStatus(gszMsgBox); if (!PRTGIF) XSync(mainDisplay, False); fp = (FILE*)popen(&file_name[1], "r"); } else { fp = fopen(file_name, "r"); } if (fp == NULL) { if (*file_name == '|') { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD_EXEC_CMD), &file_name[1], orig_cmd); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_FILE_READ_EXEC_CMD), file_name, orig_cmd); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } PrepareToReplaceAnObj(attr_owner_obj); JustReadFileIntoAttr(fp, attr_ptr, attr_owner_obj); if (*file_name == '|') { pclose(fp); SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); } else { fclose(fp); } return TRUE; } int ExecReadFileIntoAttr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* read_file_into_attr(file_name,result_attribute); */ { char *file_name=argv[0], *attr_name=argv[1]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj; int rc; UtilRemoveQuotes(file_name); UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); SaveStatusStrings(); rc = DoReadFileIntoAttr(attr_ptr, attr_owner_obj, file_name, orig_cmd); RestoreStatusStrings(); return rc; } static int ExecWriteOrAppendAttrIntoFile(argv, obj_ptr, orig_cmd, open_mode) char **argv, *orig_cmd, *open_mode; struct ObjRec *obj_ptr; /* write_attr_into_file(attribute,file_name); */ /* append_attr_into_file(attribute,file_name); */ { char *attr_name=argv[0], *file_name=argv[1]; struct AttrRec *attr_ptr=NULL; FILE *fp=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(file_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (inHyperSpace && !allowLaunchInHyperSpace) { XFlush(mainDisplay); XSync(mainDisplay, False); sprintf(gszMsgBox, TgLoadString(STID_WRITE_NOT_AUTO_IN_HYPER_EXEC), file_name); if (MsgBox(gszMsgBox, TOOL_NAME, YN_MB) != MB_ID_YES) { MsgBox(TgLoadString(STID_USER_ABORT_WRITE_IN_HYPER), TOOL_NAME, INFO_MB); return FALSE; } } if ((fp=fopen(file_name, open_mode)) == NULL) { sprintf(execDummyStr, TgLoadString(STID_CANT_OPEN_FILE_READ_EXEC_CMD), file_name, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } writeFileFailed = FALSE; fprintf(fp, "%s\n", attr_ptr->attr_value.s); if (attr_ptr->obj->detail.t->minilines.first != NULL) { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=attr_ptr->obj->detail.t->minilines.first->next; pMiniLine != NULL; pMiniLine=pMiniLine->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); if (fprintf(fp, "%s\n", tmp_buf) == EOF) { writeFileFailed = TRUE; } if (need_to_free_tmp_buf) UtilFree(tmp_buf); if (writeFileFailed) break; } } fclose(fp); if (writeFileFailed) return FailToWriteFileMessage(file_name); return TRUE; } int ExecWriteAttrIntoFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* write_attr_into_file(attribute,file_name); */ { return ExecWriteOrAppendAttrIntoFile(argv, obj_ptr, orig_cmd, "w"); } int ExecAppendAttrIntoFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* append_attr_into_file(attribute,file_name); */ { return ExecWriteOrAppendAttrIntoFile(argv, obj_ptr, orig_cmd, "a"); } int ExecSelectObjByName(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* select_obj_by_name(obj_name); */ { char *obj_name=argv[0]; struct ObjRec *owner_obj=NULL, *named_obj; UtilRemoveQuotes(obj_name); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, &owner_obj, NULL); if (topSel != NULL) RemoveAllSel(); if (named_obj == NULL) { return BadObjName(obj_name, orig_cmd); } if (owner_obj != NULL) { sprintf(execDummyStr, TgLoadString(STID_BAD_NAME_TOP_LEVEL_ONLY_CMD), obj_name, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } AddNewSelObj(named_obj); UpdSelBBox(); return TRUE; } void ExecSelectTopObj(obj_ptr, orig_cmd) char *orig_cmd; struct ObjRec *obj_ptr; /* select_top_obj(); */ { if (topObj == NULL) { sprintf(execDummyStr, TgLoadString(STID_NO_OBJ_SEL_WHILE_EXEC_CMD), orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); gnAbortExec = TRUE; } else { if (topSel != NULL) RemoveAllSel(); SelectTopObj(); } } void ExecDelAllSelObj(obj_ptr, orig_cmd) char *orig_cmd; struct ObjRec *obj_ptr; /* delete_selected_obj(); */ { if (topSel == NULL) { sprintf(execDummyStr, TgLoadString(STID_NO_OBJ_SEL_WHILE_EXEC_CMD), orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); gnAbortExec = TRUE; } else { DelAllSelObj(); } } void ExecUnSelectAllObj(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* unselect_all_obj(); */ { RemoveAllSel(); } int ExecMoveSelObjRel(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* move_selected_obj_relative(dx,dy); */ { char *dx_str=argv[0], *dy_str=argv[1]; int dx, dy; if (topSel == NULL) return BadSelectedObj(orig_cmd); UtilRemoveQuotes(dx_str); UtilRemoveQuotes(dy_str); if (!IntExpression(dx_str, &dx, orig_cmd) || !IntExpression(dy_str, &dy, orig_cmd)) { return FALSE; } if (dx != 0 || dy != 0) { MoveAllSel(dx, dy); UpdSelBBox(); SetFileModified(TRUE); } return TRUE; } int ExecRepeat(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* repeat(attr_name,times); */ { char *attr_name=argv[0], *times_str=argv[1]; int i, times=(-1), rc=TRUE; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(times_str); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (strcmp(times_str, "infinite") != 0) { if (!IntExpression(times_str, ×, orig_cmd)) { return FALSE; } } for (i=0; times < 0 || i < times; i++) { rc = DoExec(attr_ptr, attr_owner_obj); if (!rc) break; if (times < 0) i--; } return rc; } int ExecHyperJump(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* hyperjump(attr_name); */ { char *attr_name=argv[0]; struct AttrRec *attr_ptr; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); warpToAttr = attr_ptr; return TRUE; } /* do not translate -- program constants */ static char *CGICharMap[] = { " ", "+ * -. 0123456789 ", "@ABCDEFGHIJKLMNOPQRSTUVWXYZ _", " abcdefghijklmnopqrstuvwxyz ", NULL }; static int MapCGIChars(buf, buf_sz, orig_str) char *buf, *orig_str; int buf_sz; { int count=0; for ( ; *orig_str != '\0'; orig_str++) { unsigned char orig_code=(unsigned char)(*orig_str); char code; if (orig_code < 0x20) { code = ' '; } else if (orig_code < 0x40) { code = CGICharMap[1][orig_code-0x20]; } else if (orig_code < 0x60) { code = CGICharMap[2][orig_code-0x40]; } else if (orig_code < 0x80) { code = CGICharMap[3][orig_code-0x60]; } else { code = ' '; } if (code == ' ') { if (count+3 >= buf_sz) break; sprintf(&buf[count], "%%%02X", (int)orig_code); count += 3; } else { if (count+1 >= buf_sz) break; buf[count++] = code; } } buf[count] = '\0'; return count; } int ExecMakeCGIQuery(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* make_cgi_query(dest_attr_name,url_name,list_attr_name); */ { char *dest_attr_name=argv[0], *url_name=argv[1], *list_attr_name=argv[2]; struct AttrRec *dest_attr=NULL, *list_attr=NULL; struct ObjRec *dest_attr_owner_obj=NULL; MiniLineInfo *pMiniLine=NULL; char *buf=NULL, *c_ptr, *attr_names_buf=NULL; int buf_sz=0, buf_len=0, tmp_sz=0, num_attrs=0; int found_name=FALSE, seen_first_attr=FALSE, null_url=FALSE; UtilRemoveQuotes(dest_attr_name); UtilRemoveQuotes(url_name); UtilRemoveQuotes(list_attr_name); if (strcmp(url_name, "NULL") == 0) { null_url = TRUE; *url_name = '\0'; } buf_sz = strlen(url_name); buf = (char*)malloc((buf_sz+1)*sizeof(char)); if (buf == NULL) return FailAllocMessage(); sprintf(buf, "%s", url_name); buf_len = buf_sz; sprintf(execDummyStr, "%s=", dest_attr_name); dest_attr = FindAttrWithName(obj_ptr, execDummyStr, &dest_attr_owner_obj); if (dest_attr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", list_attr_name); list_attr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (list_attr == NULL) return BadAttr(execDummyStr, orig_cmd); tmp_sz = 0; for (pMiniLine=list_attr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); tmp_sz += strlen(tmp_buf)+1; if (need_to_free_tmp_buf) UtilFree(tmp_buf); } attr_names_buf = (char*)malloc((tmp_sz+2)*sizeof(char)); if (attr_names_buf == NULL) { free(buf); return FailAllocMessage(); } tmp_sz = 0; found_name = (!list_attr->nameshown); for (pMiniLine=list_attr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); if (found_name) { strcpy(&attr_names_buf[tmp_sz], tmp_buf); tmp_sz += strlen(tmp_buf); } else if ((c_ptr=strchr(tmp_buf, '=')) != NULL) { found_name = TRUE; strcpy(&attr_names_buf[tmp_sz], ++c_ptr); tmp_sz += strlen(c_ptr); } else { continue; } if (need_to_free_tmp_buf) UtilFree(tmp_buf); attr_names_buf[tmp_sz++] = '\n'; } attr_names_buf[tmp_sz] = '\0'; for (num_attrs=0, c_ptr=strtok(attr_names_buf, " ,\t\n\r"); c_ptr != NULL; num_attrs++, c_ptr=strtok(NULL, " ,\t\n\r")) { struct AttrRec *attr_ptr; int len, buf1_index; char *buf1=NULL; sprintf(execDummyStr, "%s=", c_ptr); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (attr_ptr == NULL) { free(buf); free(attr_names_buf); return BadAttr(execDummyStr, orig_cmd); } len = strlen(execDummyStr); for (pMiniLine=attr_ptr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=NULL; if (pMiniLine == attr_ptr->obj->detail.t->minilines.first) { char *attr_value=NULL; tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); attr_value = UtilStrDup(tmp_buf); if (attr_value == NULL) FailAllocMessage(); ParseAttrStr(tmp_buf, NULL, 0, attr_value, strlen(attr_value)+1); if (need_to_free_tmp_buf) UtilFree(tmp_buf); len += strlen(attr_value)+1; UtilFree(attr_value); } else { tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); len += strlen(tmp_buf)+1; if (need_to_free_tmp_buf) UtilFree(tmp_buf); } } len = len*3; buf1 = (char*)malloc((len+1)*sizeof(char)); if (buf1 == NULL) { free(buf); free(attr_names_buf); return FailAllocMessage(); } if (seen_first_attr) { *buf1 = '&'; } else { *buf1 = '?'; seen_first_attr = TRUE; } buf1_index = 1+MapCGIChars(&buf1[1], len-1, c_ptr); buf1[buf1_index++] = '='; for (pMiniLine=attr_ptr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=NULL; if (pMiniLine == attr_ptr->obj->detail.t->minilines.first) { char *attr_value=NULL; tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); attr_value = UtilStrDup(tmp_buf); if (attr_value == NULL) FailAllocMessage(); ParseAttrStr(tmp_buf, NULL, 0, attr_value, strlen(attr_value)+1); if (need_to_free_tmp_buf) UtilFree(tmp_buf); buf1_index += MapCGIChars(&buf1[buf1_index], len-buf1_index, attr_value); UtilFree(attr_value); } else { tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); buf1_index += MapCGIChars(&buf1[buf1_index], len-buf1_index, tmp_buf); if (need_to_free_tmp_buf) UtilFree(tmp_buf); } if (pMiniLine->next != NULL && buf1_index < len-1) { buf1_index += MapCGIChars(&buf1[buf1_index], len-buf1_index, "\n"); } } buf1[buf1_index] = '\0'; if ((buf=(char*)realloc(buf, buf1_index+buf_sz+1)) == NULL) { free(buf); free(attr_names_buf); free(buf1); return FailAllocMessage(); } strcpy(&buf[buf_sz], buf1); buf_sz += buf1_index; free(buf1); } if (null_url && *buf == '?') { char *psz=buf, *psz1=(&buf[1]); while (*psz1 != '\0') { *psz++ = *psz1++; } *psz = '\0'; } ReplaceAttrFirstValue(dest_attr_owner_obj, dest_attr, buf); free(buf); free(attr_names_buf); return TRUE; } static XComposeStatus c_stat; int ExecWaitClick(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* wait_click(cursor_name,grab,attr_name); */ { char *cursor_name=argv[0], *grab_str=argv[1], *attr_name=argv[2], buf[80]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; Cursor cursor=(Cursor)0; int grab=FALSE, rc=TRUE, done=FALSE; UtilRemoveQuotes(cursor_name); UtilRemoveQuotes(grab_str); UtilRemoveQuotes(attr_name); grab = (strcmp(grab_str, "TRUE") == 0); if (strcmp(cursor_name, "NULL") != 0) { cursor = NewFontCursor(cursor_name); if (cursor == (Cursor)0) { sprintf(gszMsgBox, TgLoadString(STID_BAD_CURSOR_WHILE_EXEC_CMD), cursor_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) { if (cursor != (Cursor)0) DeleteFontCursor(cursor); return BadAttr(execDummyStr, orig_cmd); } if (cursor != (Cursor)0) { SetWindowCursor(drawWindow, cursor); SetWindowCursor(mainWindow, cursor); } if (grab) { XGrabPointer(mainDisplay, rootWindow, False, ButtonPressMask, GrabModeAsync, GrabModeAsync, None, cursor==(Cursor)0 ? defaultCursor : cursor, CurrentTime); } while (!done) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == KeyPress) { char s[80]; XKeyEvent *key_ev=(&(input.xkey)); KeySym key_sym; int has_ch=FALSE; has_ch = XLookupString(key_ev, s, sizeof(s), &key_sym, &c_stat); TranslateKeys(s, &key_sym); if (CharIsESC(key_ev, s, key_sym, &has_ch)) { userAbortExec = TRUE; rc = FALSE; done = TRUE; } else { int button_num=INVALID; switch (key_sym) { case XK_Up: case XK_KP_Up: button_num = 0; break; case XK_Left: case XK_KP_Left: button_num = 1; break; case XK_space: case XK_KP_Space: case XK_Tab: case XK_Return: case XK_KP_Enter: button_num = 2; break; case XK_Right: case XK_KP_Right: button_num = 3; break; case XK_Down: case XK_KP_Down: button_num = 4; break; default: break; } if (button_num != INVALID) { sprintf(buf, "%1d", button_num); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); done = TRUE; } } } else if (input.type == ButtonPress) { int button_num=0; if (grab) { XUngrabPointer(mainDisplay, CurrentTime); } switch (input.xbutton.button) { case Button1: button_num = 1; break; case Button2: button_num = 2; break; case Button3: button_num = 3; break; default: button_num = (input.xbutton.button-Button1)+1; break; } sprintf(buf, "%1d", button_num); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); done = TRUE; } } if (cursor != (Cursor)0) { SetDefaultCursor(mainWindow); ShowCursor(); DeleteFontCursor(cursor); } return rc; } int ExecSleep(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* sleep(cursor_name,ms_interval); */ { char *cursor_name=argv[0], *ms_interval_str=argv[1]; Cursor cursor=(Cursor)0; int select_width=XConnectionNumber(mainDisplay)+1, rc=TRUE, val; long ms_start_time, ms_interval, ms_togo; struct timeval timeout; #ifdef _NO_GETTIMEOFDAY struct timeb now; #else /* ~_NO_GETTIMEOFDAY */ struct timeval now; struct timezone zone; #endif /* _NO_GETTIMEOFDAY */ fd_set fdset; UtilRemoveQuotes(cursor_name); UtilRemoveQuotes(ms_interval_str); if (!IntExpression(ms_interval_str, &val, orig_cmd)) { return FALSE; } ms_interval = (long)val; if (strcmp(cursor_name, "NULL") != 0) { cursor = NewFontCursor(cursor_name); if (cursor == (Cursor)0) { sprintf(gszMsgBox, TgLoadString(STID_BAD_CURSOR_WHILE_EXEC_CMD), cursor_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } if (cursor != (Cursor)0) { SetWindowCursor(drawWindow, cursor); SetWindowCursor(mainWindow, cursor); XSync(mainDisplay, False); } #ifdef _NO_GETTIMEOFDAY ftime(&now); ms_start_time = ((long)now.time * 1000) + ((long)now.millitm); #else /* ~_NO_GETTIMEOFDAY */ gettimeofday(&now, &zone); ms_start_time = ms_time(&now); #endif /* _NO_GETTIMEOFDAY */ ms_togo = ms_interval; EnterExecTightLoop(); while (rc && ms_togo > 0) { int status; long ms_cur_time; FD_ZERO(&fdset); FD_SET(select_width-1, &fdset); timeout.tv_sec = (long)(ms_togo/1000); timeout.tv_usec = 1000 * (ms_togo % 1000); #ifdef __hpux status = select(select_width, (int*)&fdset, NULL, NULL, &timeout); #else /* !__hpux */ status = select(select_width, &fdset, NULL, NULL, &timeout); #endif /* __hpux */ if (status < 0) { if (errno == EINTR) { /* interrupted by a system call, not a problem */ CheckInterrupt(TRUE); } else { sprintf(gszMsgBox, TgLoadString(STID_INTERNAL_CMD_SELECT_FAILED), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); rc = FALSE; } } else if (status == 0) { /* good timeout */ CheckInterrupt(TRUE); break; } else { rc = (!CheckExecInterrupt(orig_cmd)); if (!rc) { userAbortExec = TRUE; } } if (rc) { #ifdef _NO_GETTIMEOFDAY ftime(&now); ms_cur_time = ((long)now.time * 1000) + ((long)now.millitm); #else /* ~_NO_GETTIMEOFDAY */ gettimeofday(&now, &zone); ms_cur_time = ms_time(&now); #endif /* _NO_GETTIMEOFDAY */ ms_togo = ms_start_time+ms_interval-ms_cur_time; } } ExitExecTightLoop(); if (cursor != (Cursor)0) { SetDefaultCursor(mainWindow); ShowCursor(); DeleteFontCursor(cursor); } return rc; } void ExecBeginAnimate(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* begin_animate(); */ { if (!BeginExecAnimate()) { gnAbortExec = TRUE; } else { ShowInterrupt(1); } } void ExecEndAnimate(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* end_animate(); */ { EndExecAnimate(); while (HideInterrupt() > 0) ; } int ExecSetRedraw(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_redraw(true_or_false); */ { char *redraw_str=argv[0]; UtilRemoveQuotes(redraw_str); if (strcmp(redraw_str, "TRUE") == 0) { execAnimateRedraw = TRUE; } else if (strcmp(redraw_str, "FALSE") == 0) { execAnimateRedraw = FALSE; } else { return BadArg("true_or_false", orig_cmd); } return TRUE; } int ExecSetSelObjColor(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_obj_color(color_str); */ { char *color_str=argv[0]; int index, new_alloc; UtilRemoveQuotes(color_str); UtilTrimBlanks(color_str); if ((index=QuickFindColorIndex(NULL, color_str, &new_alloc, FALSE)) == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_BAD_COLOR_NAME_WHILE_EXEC_CMD), color_str, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (obj_ptr != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[index]); } ChangeAllSelColor(index, FALSE); return TRUE; } int ExecSetSelObjFill(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_obj_fill(fill_index); */ { char *index_str=argv[0]; int index; UtilRemoveQuotes(index_str); if (!IntExpression(index_str, &index, orig_cmd)) { return FALSE; } if (index < 0 || index >= MAXPATTERNS) { sprintf(gszMsgBox, TgLoadString(STID_FUNC_ARG_RANGE), orig_cmd, "fill_index", 0, MAXPATTERNS-1, index); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ChangeAllSelFill(index, FALSE); return TRUE; } int ExecSetSelObjPen(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_obj_pen(pen_index); */ { char *index_str=argv[0]; int index; UtilRemoveQuotes(index_str); if (!IntExpression(index_str, &index, orig_cmd)) { return FALSE; } if (index < 0 || index >= MAXPATTERNS) { sprintf(gszMsgBox, TgLoadString(STID_FUNC_ARG_RANGE), orig_cmd, "pen_index", 0, MAXPATTERNS-1, index); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ChangeAllSelPen(index, FALSE); return TRUE; } int ExecSetSelObjLineWidth(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_obj_line_width(width,aw,ah); */ { char *width_str=argv[0], *aw_str=argv[1], *ah_str=argv[2]; int width=0, aw=0, ah=0; UtilRemoveQuotes(width_str); UtilRemoveQuotes(aw_str); UtilRemoveQuotes(ah_str); if (!IntExpression(width_str, &width, orig_cmd) || !IntExpression(aw_str, &aw, orig_cmd) || !IntExpression(ah_str, &ah, orig_cmd)) { return FALSE; } if (width < 0) { sprintf(gszMsgBox, TgLoadString(STID_WIDTH_RANGE_WHILE_EXEC_CMD), width_str, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (topSel == NULL) { int index=GetBestLineWidthIndex(width, aw, ah); ChangeAllSelLineWidth(index, FALSE); } else { char width_spec[40], aw_spec[40], ah_spec[40]; sprintf(width_spec, "%1d", width); sprintf(aw_spec, "%1d", aw); sprintf(ah_spec, "%1d", ah); ChangeAllSelRealLineWidth(CHANGE_LINE_ALL, width, aw, ah, width_spec, aw_spec, ah_spec, FALSE); } return TRUE; } int ExecSetSelObjSpline(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_obj_spline(spline_type); */ { char *spline_spec=argv[0]; int index; UtilRemoveQuotes(spline_spec); UtilTrimBlanks(spline_spec); if (strcmp(spline_spec,"straight") == 0) { index = LT_STRAIGHT; } else if (strcmp(spline_spec,"spline") == 0) { index = LT_SPLINE; } else if (strcmp(spline_spec,"interpolated") == 0) { index = LT_INTSPLINE; } else if (strcmp(spline_spec,"structured") == 0) { index = LT_STRUCT_SPLINE; } else { sprintf(gszMsgBox, TgLoadString(STID_SPLINE_TYPE_WHILE_EXEC_CMD), spline_spec, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ChangeAllSelLineType(index, FALSE); return TRUE; } int ExecSetSelObjArrow(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_obj_arrow(arrow_type); */ { char *arrow_spec=argv[0]; int index; UtilRemoveQuotes(arrow_spec); UtilTrimBlanks(arrow_spec); if (strcmp(arrow_spec,"none") == 0) { index = LS_PLAIN; } else if (strcmp(arrow_spec,"right") == 0) { index = LS_RIGHT; } else if (strcmp(arrow_spec,"left") == 0) { index = LS_LEFT; } else if (strcmp(arrow_spec,"double") == 0) { index = LS_DOUBLE; } else { sprintf(gszMsgBox, TgLoadString(STID_ARROW_STYLE_WHILE_EXEC_CMD), arrow_spec, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ChangeAllSelLineStyle(index, FALSE); return TRUE; } int ExecSetSelObjDash(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_obj_dash(dash_index); */ { char *index_str=argv[0]; int index; UtilRemoveQuotes(index_str); if (!IntExpression(index_str, &index, orig_cmd)) { return FALSE; } if (index < 0 || index >= MAXDASHES) { sprintf(gszMsgBox, TgLoadString(STID_FUNC_ARG_RANGE), orig_cmd, "dash_index", 0, MAXDASHES-1, index); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ChangeAllSelLineDash(index, FALSE); return TRUE; } int ExecSetSelObjTransPat(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_obj_trans_pat(trans_pat); */ { char *trans_pat_str=argv[0]; int trans_pat=0; UtilRemoveQuotes(trans_pat_str); if (!IntExpression(trans_pat_str, &trans_pat, orig_cmd)) { return FALSE; } if (trans_pat != 0) { trans_pat = TRANSPAT_MODE; } else { trans_pat = NO_TRANSPAT_MODE; } ChangeAllSelTransPat(trans_pat, FALSE); return TRUE; } int ExecSetSelObjRCBRadius(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_obj_rcb_radius(rcb_radius); */ { char *rcb_radius_str=argv[0]; int rcb_radius=0; UtilRemoveQuotes(rcb_radius_str); if (!IntExpression(rcb_radius_str, &rcb_radius, orig_cmd)) { return FALSE; } if (rcb_radius < 4) { sprintf(gszMsgBox, TgLoadString(STID_RCB_RAD_RANGE_WHILE_EXEC_CMD), rcb_radius_str, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ChangeAllSelRCBRadius(rcb_radius); return TRUE; } int ExecSetSelTextVSpace(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_text_vspace(v_space); */ { char *v_space_str=argv[0]; int v_space=0; UtilRemoveQuotes(v_space_str); if (!IntExpression(v_space_str, &v_space, orig_cmd)) { return FALSE; } ChangeVSpace(v_space); return TRUE; } int ExecSetSelTextJust(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_text_just(just_type); */ { char *just_spec=argv[0]; int just=JUST_L; UtilRemoveQuotes(just_spec); UtilTrimBlanks(just_spec); if (strcmp(just_spec,"left") == 0) { just = JUST_L; } else if (strcmp(just_spec,"center") == 0) { just = JUST_C; } else if (strcmp(just_spec,"right") == 0) { just = JUST_R; } else { sprintf(gszMsgBox, TgLoadString(STID_BAD_TEXT_JUST_WHILE_EXEC_CMD), just_spec, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ChangeFontJust(just); return TRUE; } int ExecSetSelTextFont(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_text_font(font_spec); */ { char *font_spec=argv[0]; int font=0, style=0; UtilRemoveQuotes(font_spec); UtilTrimBlanks(font_spec); if (!GetFontAndStyle(font_spec, &font, &style, TRUE)) { if (PRTGIF && !cmdLineOpenDisplay) { for (font=0; font < MAXFONTS; font++) { if (strcmp(font_spec, defFontMenuStr[font]) == 0) { ChangeFont(font, TRUE); return TRUE; } } } else { for (font=0; font < numFonts; font++) { if (strcmp(font_spec, fontMenuStr[font]) == 0) { ChangeFont(font, TRUE); return TRUE; } } } sprintf(gszMsgBox, TgLoadString(STID_BAD_FONT_NAME_WHILE_EXEC_CMD), font_spec, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ChangeFont(font, TRUE); ChangeFontStyle(style); return TRUE; } int ExecSetSelTextStyle(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_text_style(textstyle); */ { char *style_spec=argv[0]; int style=0; UtilRemoveQuotes(style_spec); UtilTrimBlanks(style_spec); if (strcmp(style_spec, "r") == 0) { style = STYLE_NR; } else if (strcmp(style_spec, "b") == 0) { style = STYLE_BR; } else if (strcmp(style_spec, "i") == 0) { style = STYLE_NI; } else if (strcmp(style_spec, "bi") == 0) { style = STYLE_BI; } else { sprintf(gszMsgBox, TgLoadString(STID_BAD_STYLE_NAME_WHILE_EXEC_CMD), style_spec, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ChangeFontStyle(style); return TRUE; } int ExecSetSelTextSize(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_text_size(size); */ { char *size_spec=argv[0], *psz=NULL; int size=INVALID, sz_unit=INVALID, use_point_size=FALSE; int size_index=0, min_diff=0, min_size_index=0; UtilRemoveQuotes(size_spec); if ((psz=strstr(size_spec, "point")) != NULL || (psz=strstr(size_spec, "pt")) != NULL) { *psz = '\0'; use_point_size = TRUE; } if (!IntExpression(size_spec, &size, orig_cmd)) { return FALSE; } if (use_point_size) { sz_unit = PointSizeToSzUnit(size); } else { sz_unit = FontSizeToSzUnit(size); } if (topSel == NULL) { min_diff = abs(fontSzUnits[0] - sz_unit); for (size_index=1; size_index < numFontSizes; size_index++) { int diff=abs(fontSzUnits[size_index]-sz_unit); if (diff < min_diff) { min_diff = diff; min_size_index = size_index; } } ChangeFontSize(min_size_index); } else { ChangeAllSelRealSzUnit(sz_unit, FALSE); } return TRUE; } int ExecSetSelTextUnderline(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_text_underline(underline); */ { char *underline_on_str=argv[0]; int underline_on=0; UtilRemoveQuotes(underline_on_str); if (!IntExpression(underline_on_str, &underline_on, orig_cmd)) { return FALSE; } ChangeFontUnderline(underline_on != 0); return TRUE; } int ExecSetSelTextOverline(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_selected_text_overline(overline); */ { char *overline_on_str=argv[0]; int overline_on=0; UtilRemoveQuotes(overline_on_str); if (!IntExpression(overline_on_str, &overline_on, orig_cmd)) { return FALSE; } ChangeFontOverline(overline_on != 0); return TRUE; } int ExecInc(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* inc(attr_name,expr); */ { char *attr_name=argv[0], *expr=argv[1], buf[40]; int orig_ival, val; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(expr); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); orig_ival = atoi(attr_ptr->attr_value.s); if (!IntExpression(expr, &val, orig_cmd)) return FALSE; if (val != 0) { sprintf(buf, "%1d", orig_ival+val); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); } return TRUE; } int ExecDec(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* dec(attr_name,expr); */ { char *attr_name=argv[0], *expr=argv[1], buf[40]; int orig_ival, val; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(expr); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); orig_ival = atoi(attr_ptr->attr_value.s); if (!IntExpression(expr, &val, orig_cmd)) return FALSE; if (val != 0) { sprintf(buf, "%1d", orig_ival-val); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); } return TRUE; } #define SHUFFLE_TO_TOP (TRUE) #define SHUFFLE_TO_BOT (FALSE) static int DoShuffleObjToTopOrBottom(argv, obj_ptr, orig_cmd, to_top) char **argv, *orig_cmd; struct ObjRec *obj_ptr; int to_top; /* shuffle_obj_to_top(obj_name); */ /* shuffle_obj_to_bottom(obj_name); */ { char *obj_name=argv[0]; struct ObjRec *owner_obj=NULL, *top_owner=NULL, *named_obj; int ltx, lty, rbx, rby; struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; UtilRemoveQuotes(obj_name); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, &owner_obj, &top_owner); if (named_obj == NULL) return BadObjName(obj_name, orig_cmd); if (owner_obj == NULL) { if (to_top) { if (named_obj == topObj) return TRUE; } else { if (named_obj == botObj) return TRUE; } ltx = named_obj->bbox.ltx; lty = named_obj->bbox.lty; rbx = named_obj->bbox.rbx; rby = named_obj->bbox.rby; } else { if (to_top) { if (named_obj == owner_obj->detail.r->first) return TRUE; } else { if (named_obj == owner_obj->detail.r->last) return TRUE; } ltx = top_owner->bbox.ltx; lty = top_owner->bbox.lty; rbx = top_owner->bbox.rbx; rby = top_owner->bbox.rby; } topSel = botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) { FailAllocMessage(); topSel = saved_top_sel; botSel = saved_bot_sel; return FALSE; } topSel->next = topSel->prev = NULL; topSel->obj = (owner_obj==NULL ? named_obj : top_owner); UpdSelBBox(); if (owner_obj == NULL) { if (to_top) { MoveSelToTop(); } else { MoveSelToBot(); } } else { PrepareToRecord (CMD_REPLACE, topSel, botSel, numObjSelected); if (to_top) { named_obj->prev->next = named_obj->next; if (named_obj == owner_obj->detail.r->last) { owner_obj->detail.r->last = named_obj->prev; } else { named_obj->next->prev = named_obj->prev; } named_obj->prev = NULL; named_obj->next = owner_obj->detail.r->first; owner_obj->detail.r->first->prev = named_obj; owner_obj->detail.r->first = named_obj; } else { named_obj->next->prev = named_obj->prev; if (named_obj == owner_obj->detail.r->first) { owner_obj->detail.r->first = named_obj->next; } else { named_obj->prev->next = named_obj->next; } named_obj->next = NULL; named_obj->prev = owner_obj->detail.r->last; owner_obj->detail.r->last->next = named_obj; owner_obj->detail.r->last = named_obj; } RecordCmd (CMD_REPLACE, NULL, topSel, botSel, numObjSelected); } free(topSel); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecShuffleObjToTop(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* shuffle_obj_to_top(obj_name); */ { return DoShuffleObjToTopOrBottom(argv, obj_ptr, orig_cmd, SHUFFLE_TO_TOP); } int ExecShuffleObjToBot(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* shuffle_obj_to_bottom(obj_name); */ { return DoShuffleObjToTopOrBottom(argv, obj_ptr, orig_cmd, SHUFFLE_TO_BOT); } void ExecDisableUndo(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* disable_undo(); */ { if (historyDepth != 0) { sprintf(gszMsgBox, TgLoadString(STID_UNDO_BUF_FLUSHED_BY_CMD), orig_cmd); Msg(gszMsgBox); } DisableUndo(); } void ExecEnableUndo(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* enable_undo(); */ { EnableUndo(); } int ExecGetDrawingArea(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_drawing_area(ltx_attr,lty_attr,rbx_attr,rby_attr); */ { char *ltx_attr_name=argv[0], *lty_attr_name=argv[1]; char *rbx_attr_name=argv[2], *rby_attr_name=argv[3], buf[40]; struct AttrRec *ltx_attr_ptr, *lty_attr_ptr, *rbx_attr_ptr, *rby_attr_ptr; struct ObjRec *ltx_attr_owner_obj=NULL, *lty_attr_owner_obj=NULL; struct ObjRec *rbx_attr_owner_obj=NULL, *rby_attr_owner_obj=NULL; UtilRemoveQuotes(ltx_attr_name); UtilRemoveQuotes(lty_attr_name); UtilRemoveQuotes(rbx_attr_name); UtilRemoveQuotes(rby_attr_name); sprintf(execDummyStr, "%s=", ltx_attr_name); ltx_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, <x_attr_owner_obj); if (ltx_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", lty_attr_name); lty_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, <y_attr_owner_obj); if (lty_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", rbx_attr_name); rbx_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &rbx_attr_owner_obj); if (rbx_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", rby_attr_name); rby_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &rby_attr_owner_obj); if (rby_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(buf, "%1d", drawOrigX); ReplaceAttrFirstValue(ltx_attr_owner_obj, ltx_attr_ptr, buf); sprintf(buf, "%1d", drawOrigY); ReplaceAttrFirstValue(lty_attr_owner_obj, lty_attr_ptr, buf); sprintf(buf, "%1d", drawOrigX+drawWinW); ReplaceAttrFirstValue(rbx_attr_owner_obj, rbx_attr_ptr, buf); sprintf(buf, "%1d", drawOrigY+drawWinH); ReplaceAttrFirstValue(rby_attr_owner_obj, rby_attr_ptr, buf); SetFileModified(TRUE); return TRUE; } int ExecGetSelObjBBox(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_selected_obj_bbox(ltx_attr,lty_attr,rbx_attr,rby_attr); */ { char *ltx_attr_name=argv[0], *lty_attr_name=argv[1]; char *rbx_attr_name=argv[2], *rby_attr_name=argv[3], buf[40]; struct AttrRec *ltx_attr_ptr, *lty_attr_ptr, *rbx_attr_ptr, *rby_attr_ptr; struct ObjRec *ltx_attr_owner_obj=NULL, *lty_attr_owner_obj=NULL; struct ObjRec *rbx_attr_owner_obj=NULL, *rby_attr_owner_obj=NULL; UtilRemoveQuotes(ltx_attr_name); UtilRemoveQuotes(lty_attr_name); UtilRemoveQuotes(rbx_attr_name); UtilRemoveQuotes(rby_attr_name); if (topSel == NULL) return BadSelectedObj(orig_cmd); sprintf(execDummyStr, "%s=", ltx_attr_name); ltx_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, <x_attr_owner_obj); if (ltx_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", lty_attr_name); lty_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, <y_attr_owner_obj); if (lty_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", rbx_attr_name); rbx_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &rbx_attr_owner_obj); if (rbx_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", rby_attr_name); rby_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &rby_attr_owner_obj); if (rby_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(buf, "%1d", selObjLtX); ReplaceAttrFirstValue(ltx_attr_owner_obj, ltx_attr_ptr, buf); sprintf(buf, "%1d", selObjLtY); ReplaceAttrFirstValue(lty_attr_owner_obj, lty_attr_ptr, buf); sprintf(buf, "%1d", selObjRbX); ReplaceAttrFirstValue(rbx_attr_owner_obj, rbx_attr_ptr, buf); sprintf(buf, "%1d", selObjRbY); ReplaceAttrFirstValue(rby_attr_owner_obj, rby_attr_ptr, buf); SetFileModified(TRUE); return TRUE; } int ExecGetNamedObjBBox(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_named_obj_bbox(obj_name,ltx_attr,lty_attr,rbx_attr,rby_attr); */ { char *obj_name=argv[0]; char *ltx_attr_name=argv[1], *lty_attr_name=argv[2]; char *rbx_attr_name=argv[3], *rby_attr_name=argv[4], buf[40]; struct ObjRec *top_owner=NULL, *named_obj=NULL; struct AttrRec *ltx_attr_ptr, *lty_attr_ptr, *rbx_attr_ptr, *rby_attr_ptr; struct ObjRec *ltx_attr_owner_obj=NULL, *lty_attr_owner_obj=NULL; struct ObjRec *rbx_attr_owner_obj=NULL, *rby_attr_owner_obj=NULL; UtilRemoveQuotes(obj_name); UtilTrimBlanks(obj_name); UtilRemoveQuotes(ltx_attr_name); UtilRemoveQuotes(lty_attr_name); UtilRemoveQuotes(rbx_attr_name); UtilRemoveQuotes(rby_attr_name); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, NULL, &top_owner); if (named_obj == NULL) { return BadObjName(obj_name, orig_cmd); } sprintf(execDummyStr, "%s=", ltx_attr_name); ltx_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, <x_attr_owner_obj); if (ltx_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", lty_attr_name); lty_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, <y_attr_owner_obj); if (lty_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", rbx_attr_name); rbx_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &rbx_attr_owner_obj); if (rbx_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", rby_attr_name); rby_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &rby_attr_owner_obj); if (rby_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(buf, "%1d", named_obj->obbox.ltx); ReplaceAttrFirstValue(ltx_attr_owner_obj, ltx_attr_ptr, buf); sprintf(buf, "%1d", named_obj->obbox.lty); ReplaceAttrFirstValue(lty_attr_owner_obj, lty_attr_ptr, buf); sprintf(buf, "%1d", named_obj->obbox.rbx); ReplaceAttrFirstValue(rbx_attr_owner_obj, rbx_attr_ptr, buf); sprintf(buf, "%1d", named_obj->obbox.rby); ReplaceAttrFirstValue(rby_attr_owner_obj, rby_attr_ptr, buf); SetFileModified(TRUE); return TRUE; } int ExecMoveSelObjAbs(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* move_selected_obj_absolute(ltx,lty); */ { char *ltx_str=argv[0], *lty_str=argv[1]; int ltx, lty; UtilRemoveQuotes(ltx_str); UtilRemoveQuotes(lty_str); if (topSel == NULL) return BadSelectedObj(orig_cmd); if (!IntExpression(ltx_str, <x, orig_cmd) || !IntExpression(lty_str, <y, orig_cmd)) { return FALSE; } if (ltx != selObjLtX || lty != selObjLtY) { MoveAllSel(ltx-selObjLtX, lty-selObjLtY); UpdSelBBox(); SetFileModified(TRUE); } return TRUE; } int ExecAssign(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* assign(attr_name,expr); */ { char *attr_name=argv[0], *expr=argv[1], buf[40]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; struct VRec v; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(expr); UtilTrimBlanks(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (!EvalExpr(expr, &v)) return FALSE; switch (v.vtype) { case INT_VAL: sprintf(buf, "%1d", v.val.i); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); break; case DBL_VAL: sprintf(buf, "%.12f", (float)(v.val.d)); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); break; case NULL_VAL: case STR_VAL: sprintf(gszMsgBox, TgLoadString(STID_BAD_EVAL_NUM_EXP_EXEC_CMD), expr, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (v.vtype == STR_VAL && v.val.s != NULL) free(v.val.s); return FALSE; } return TRUE; } int ExecStrCpy(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* strcpy(attr_name,str); */ { char *attr_name=argv[0], *the_str=argv[1]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(the_str); UtilTrimBlanks(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, the_str); return TRUE; } int ExecStrCat(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* strcat(attr_name,str); */ { char *attr_name=argv[0], *the_str=argv[1], *new_str=NULL; int len=0; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(the_str); UtilTrimBlanks(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); len = strlen(attr_ptr->attr_value.s)+strlen(the_str); new_str = (char*)malloc(len+1); if (new_str == NULL) FailAllocMessage(); sprintf(new_str, "%s%s", attr_ptr->attr_value.s, the_str); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, new_str); free(new_str); return TRUE; } int ExecCopyStrToCutBuffer(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* copy_string_to_cut_buffer(str); */ { char *the_str=argv[0]; int len=0; UtilRemoveQuotes(the_str); len = strlen(the_str); if (!WriteBufToCutBuffer(the_str, strlen(the_str), TRUE, FALSE, NULL)) { sprintf(gszMsgBox, TgLoadString(STID_WRITE_CUT_BUF_WHILE_EXEC_CMD), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return TRUE; } int ExecWhile(argv, raw_argv, obj_ptr, orig_cmd) char **argv, **raw_argv, *orig_cmd; struct ObjRec *obj_ptr; /* while(expr,attr_to_exec); */ { char *raw_expr=raw_argv[0], *attr_name=argv[1]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; int rc=TRUE; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); while (rc) { int val; char *expr=convert_str(raw_expr, obj_ptr, TRUE); if (expr == NULL) { BadAttr(raw_expr, orig_cmd); return FALSE; } else if (!IntExpression(expr, &val, orig_cmd)) { free(expr); return FALSE; } free(expr); if (val == 0) break; if (!DoExec(attr_ptr, attr_owner_obj)) return FALSE; rc = (!CheckExecInterrupt(orig_cmd)); if (!rc) { userAbortExec = TRUE; } } return rc; } int ExecIf(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* if(expr,then_attr_to_exec,else_attr_to_exec); */ { char *expr=argv[0], *then_attr_name=argv[1], *else_attr_name=argv[2]; int val=0; UtilRemoveQuotes(then_attr_name); UtilRemoveQuotes(else_attr_name); if (!IntExpression(expr, &val, orig_cmd)) return FALSE; if (val) { struct AttrRec *then_attr_ptr=NULL; struct ObjRec *then_attr_owner_obj=NULL; if (strcmp(then_attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", then_attr_name); then_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &then_attr_owner_obj); if (then_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); } if (then_attr_ptr != NULL && !DoExec(then_attr_ptr, then_attr_owner_obj)) { return FALSE; } } else { struct AttrRec *else_attr_ptr=NULL; struct ObjRec *else_attr_owner_obj=NULL; if (strcmp(else_attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", else_attr_name); else_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &else_attr_owner_obj); if (else_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); } if (else_attr_ptr != NULL && !DoExec(else_attr_ptr, else_attr_owner_obj)) { return FALSE; } } return TRUE; } int ExecGetCurrentFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_current_file(attr_name); */ { char *attr_name=argv[0], *full_name=NULL; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilTrimBlanks(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (curFileDefined) { if (*curSymDir == '\0') { sprintf(gszMsgBox, "%s%c%s", curDir, DIR_SEP, curFileName); } else { sprintf(gszMsgBox, "%s%c%s", curSymDir, DIR_SEP, curFileName); } full_name = UtilStrDup(gszMsgBox); } ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, (full_name==NULL ? "" : full_name)); if (full_name != NULL) free(full_name); return TRUE; } int ExecGetCurrentExportFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_current_export_file(attr_name); */ { char *attr_name=argv[0], *full_name=NULL; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilTrimBlanks(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (curFileDefined) { char *psz=NULL; sprintf(gszMsgBox, "%s%c%s", curDir, DIR_SEP, curFileName); if ((psz=UtilStrRChr(gszMsgBox, '.')) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_DOT_WHILE_EXEC_CMD), curDir, DIR_SEP, curFileName, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } strcpy(++psz, GetExportExt(whereToPrint)); full_name = UtilStrDup(gszMsgBox); if (full_name == NULL) FailAllocMessage(); } ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, (full_name==NULL ? "" : full_name)); if (full_name != NULL) free(full_name); return TRUE; } int ExecGetCurrentDir(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_current_dir(attr_name); */ { char *attr_name=argv[0]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilTrimBlanks(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, curDir); return TRUE; } int ExecGetEnv(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* getenv(attr_name,env_var_name); */ { char *attr_name=argv[0], *env_var_name=argv[1], *c_ptr, *env_var_value=NULL; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(env_var_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if ((c_ptr=getenv(env_var_name)) != NULL) { env_var_value = UtilStrDup(c_ptr); } ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, (env_var_value==NULL ? "" : env_var_value)); if (env_var_value != NULL) free(env_var_value); return TRUE; } int ExecStrLen(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* strlen(attr_name,str); */ { char *attr_name=argv[0], *the_str=argv[1], val_str[40]; int len; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(the_str); len = strlen(the_str); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(val_str, "%1d", len); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, val_str); return TRUE; } int ExecSubStr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* substr(attr_name,str,start_index,length); */ { char *attr_name=argv[0], *the_str=argv[1]; char *start_index_str=argv[2], *length_str=argv[3], *buf; int len, start_index=(-1), length=(-1); struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(the_str); UtilRemoveQuotes(start_index_str); len = strlen(the_str); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (!IntExpression(start_index_str, &start_index, orig_cmd) || !IntExpression(length_str, &length, orig_cmd)) { return FALSE; } if (start_index < 0) start_index = 0; if (length+start_index > len) { length = len-start_index; } if (length < 0) length = 0; if ((buf=UtilStrDup(the_str)) == NULL) { FailAllocMessage(); } else { strncpy(buf, &the_str[start_index], length); buf[length] = '\0'; } ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, (buf==NULL ? "" : buf)); if (buf != NULL) free(buf); return TRUE; } int ExecStrStr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* strstr(attr_name,str,substr); */ { char *attr_name=argv[0], *the_str=argv[1], *sub_str=argv[2], *c_ptr; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(the_str); UtilRemoveQuotes(sub_str); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); c_ptr = strstr(the_str, sub_str); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, (c_ptr==NULL ? "" : c_ptr)); return TRUE; } int ExecStrRStr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* strrstr(attr_name,str,substr); */ { char *attr_name=argv[0], *the_str=argv[1], *sub_str=argv[2]; char *c_ptr, *last_match=NULL; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(the_str); UtilRemoveQuotes(sub_str); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); for (c_ptr=strstr(the_str, sub_str); c_ptr != NULL; c_ptr=strstr(&last_match[1], sub_str)) { last_match = c_ptr; } ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, (last_match==NULL ? "" : last_match)); return TRUE; } void ExecUnMakeSelObjIconic(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* unmake_selected_obj_iconic(); */ { struct SelRec *sel_ptr; int modified=FALSE; if (topSel == NULL) { BadSelectedObj(orig_cmd); gnAbortExec = TRUE; return; } StartCompositeCmd(); for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; if (obj_ptr->type == OBJ_ICON || obj_ptr->type == OBJ_PIN) { struct AttrRec *attr_ptr; modified = TRUE; PrepareToReplaceAnObj(obj_ptr); obj_ptr->type = OBJ_GROUP; attr_ptr = obj_ptr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { attr_ptr->inherited = FALSE; } AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); } } EndCompositeCmd(); if (modified) { SetFileModified(TRUE); } } int ExecHyperJumpThenExec(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* hyperjump_then_exec(attr_name,attr_name_to_exec); */ { char *attr_name=argv[0], *attr_name_to_exec=argv[1]; struct AttrRec *attr_ptr; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(attr_name_to_exec); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); warpToAttr = attr_ptr; if (cmdToExecAfterHyperJump != NULL) free(cmdToExecAfterHyperJump); sprintf(execDummyStr, "%s=", attr_name_to_exec); cmdToExecAfterHyperJump = UtilStrDup(execDummyStr); return TRUE; } #define SHOW_ATTR 0 #define HIDE_ATTR 1 #define SHOW_ATTR_NAME 2 #define HIDE_ATTR_NAME 3 #define SHOW_VALUE 4 #define HIDE_VALUE 5 static void ReplaceAttrShown(obj_ptr, attr_ptr, show_type) struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; int show_type; /* obj_ptr better be a top-level object */ { int ltx, lty, rbx, rby, needs_redraw=FALSE; ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; PrepareToReplaceAnObj(obj_ptr); switch (show_type) { case SHOW_ATTR: case SHOW_VALUE: attr_ptr->shown = TRUE; needs_redraw = TRUE; break; case HIDE_ATTR: case HIDE_VALUE: attr_ptr->shown = FALSE; needs_redraw = TRUE; break; case SHOW_ATTR_NAME: attr_ptr->nameshown = TRUE; if (attr_ptr->shown) needs_redraw = TRUE; UpdAttr(attr_ptr); break; case HIDE_ATTR_NAME: attr_ptr->nameshown = FALSE; if (attr_ptr->shown) needs_redraw = TRUE; UpdAttr(attr_ptr); break; } attr_ptr->obj->detail.t->cached_zoom = 0; if (attr_ptr->obj->detail.t->cached_bitmap != None) { XFreePixmap(mainDisplay, attr_ptr->obj->detail.t->cached_bitmap); attr_ptr->obj->detail.t->cached_bitmap = None; } if (attr_ptr->shown) { AdjObjCache(obj_ptr); AdjObjBBox(obj_ptr); } RecordReplaceAnObj(obj_ptr); if (needs_redraw) { RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), obj_ptr->bbox.ltx-GRID_ABS_SIZE(1), obj_ptr->bbox.lty-GRID_ABS_SIZE(1), obj_ptr->bbox.rbx+GRID_ABS_SIZE(1), obj_ptr->bbox.rby+GRID_ABS_SIZE(1)); } SetFileModified(TRUE); } static int ExecShowHideAttr(argv, obj_ptr, orig_cmd, show_type) char **argv, *orig_cmd; struct ObjRec *obj_ptr; int show_type; /* show_attr(attr_name); */ /* hide_attr(attr_name); */ /* show_attr_name(attr_name); */ /* hide_attr_name(attr_name); */ { char *attr_name=argv[0]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (attr_owner_obj == tgifObj) { return FileAttrNotAllowed(execDummyStr, orig_cmd); } switch (show_type) { case SHOW_ATTR: if (attr_ptr->shown) return TRUE; break; case HIDE_ATTR: if (!attr_ptr->shown) return TRUE; break; case SHOW_ATTR_NAME: if (*attr_ptr->attr_name.s == '\0' || attr_ptr->nameshown) return TRUE; break; case HIDE_ATTR_NAME: if (*attr_ptr->attr_name.s == '\0' || !attr_ptr->nameshown) return TRUE; break; } ReplaceAttrShown(attr_owner_obj, attr_ptr, show_type); return TRUE; } int ExecShowAttr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* show_attr(attr_name); */ { return ExecShowHideAttr(argv, obj_ptr, orig_cmd, SHOW_ATTR); } int ExecHideAttr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* hide_attr(attr_name); */ { return ExecShowHideAttr(argv, obj_ptr, orig_cmd, HIDE_ATTR); } int ExecShowAttrName(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* show_attr_name(attr_name); */ { return ExecShowHideAttr(argv, obj_ptr, orig_cmd, SHOW_ATTR_NAME); } int ExecHideAttrName(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* hide_attr_name(attr_name); */ { return ExecShowHideAttr(argv, obj_ptr, orig_cmd, HIDE_ATTR_NAME); } static int ExecShowHideValue(argv, obj_ptr, orig_cmd, show_type) char **argv, *orig_cmd; struct ObjRec *obj_ptr; int show_type; /* show_value(attr_value); */ /* hide_value(attr_value); */ { char *attr_value=argv[0]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_value); sprintf(execDummyStr, "%s", attr_value); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (attr_owner_obj == tgifObj) { return FileAttrNotAllowed(execDummyStr, orig_cmd); } switch (show_type) { case SHOW_VALUE: if (attr_ptr->shown) return TRUE; break; case HIDE_VALUE: if (!attr_ptr->shown) return TRUE; break; } ReplaceAttrShown(attr_owner_obj, attr_ptr, show_type); return TRUE; } int ExecShowValue(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* show_value(attr_value); */ { return ExecShowHideValue(argv, obj_ptr, orig_cmd, SHOW_VALUE); } int ExecHideValue(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* hide_value(attr_value); */ { return ExecShowHideValue(argv, obj_ptr, orig_cmd, HIDE_VALUE); } int ExecGetAttrBBox(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_attr_bbox(ltx_attr,lty_attr,rbx_attr,rby_attr,attr_name); */ { char *ltx_attr_name=argv[0], *lty_attr_name=argv[1]; char *rbx_attr_name=argv[2], *rby_attr_name=argv[3], buf[40]; char *attr_name=argv[4]; struct AttrRec *ltx_attr_ptr, *lty_attr_ptr, *rbx_attr_ptr, *rby_attr_ptr; struct AttrRec *attr_ptr; struct ObjRec *ltx_attr_owner_obj=NULL, *lty_attr_owner_obj=NULL; struct ObjRec *rbx_attr_owner_obj=NULL, *rby_attr_owner_obj=NULL; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(ltx_attr_name); UtilRemoveQuotes(lty_attr_name); UtilRemoveQuotes(rbx_attr_name); UtilRemoveQuotes(rby_attr_name); UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (attr_owner_obj == tgifObj) { return FileAttrNotAllowed(execDummyStr, orig_cmd); } sprintf(execDummyStr, "%s=", ltx_attr_name); ltx_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, <x_attr_owner_obj); if (ltx_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", lty_attr_name); lty_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, <y_attr_owner_obj); if (lty_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", rbx_attr_name); rbx_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &rbx_attr_owner_obj); if (rbx_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", rby_attr_name); rby_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &rby_attr_owner_obj); if (rby_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(buf, "%1d", attr_ptr->obj->obbox.ltx); ReplaceAttrFirstValue(ltx_attr_owner_obj, ltx_attr_ptr, buf); sprintf(buf, "%1d", attr_ptr->obj->obbox.lty); ReplaceAttrFirstValue(lty_attr_owner_obj, lty_attr_ptr, buf); sprintf(buf, "%1d", attr_ptr->obj->obbox.rbx); ReplaceAttrFirstValue(rbx_attr_owner_obj, rbx_attr_ptr, buf); sprintf(buf, "%1d", attr_ptr->obj->obbox.rby); ReplaceAttrFirstValue(rby_attr_owner_obj, rby_attr_ptr, buf); SetFileModified(TRUE); return TRUE; } int ExecSizeSelObjAbs(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* size_selected_obj_absolute(abs_w,abs_h); */ { char *abs_w_str=argv[0], *abs_h_str=argv[1]; int abs_w, abs_h; UtilRemoveQuotes(abs_w_str); UtilRemoveQuotes(abs_h_str); if (topSel == NULL) return BadSelectedObj(orig_cmd); if (!IntExpression(abs_w_str, &abs_w, orig_cmd) || !IntExpression(abs_h_str, &abs_h, orig_cmd)) { return FALSE; } if (abs_w < 0 || abs_h < 0) { if (abs_w < 0) { sprintf(gszMsgBox, TgLoadString(STID_BAD_WIDTH_WHILE_EXEC_CMD), abs_w_str, orig_cmd); } else { sprintf(gszMsgBox, TgLoadString(STID_BAD_HEIGHT_WHILE_EXEC_CMD), abs_h_str, orig_cmd); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (abs_w != selObjRbX-selObjLtX || abs_h != selObjRbY-selObjLtY) { SizeAllSelObj(abs_w, abs_h); } return TRUE; } int ExecSizeNamedObjAbs(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* size_named_obj_absolute(obj_name,abs_w,abs_h); */ { char *obj_name=argv[0], *abs_w_str=argv[1], *abs_h_str=argv[2]; int abs_w=0, abs_h=0; struct ObjRec *top_owner=NULL, *named_obj=NULL; UtilRemoveQuotes(obj_name); UtilTrimBlanks(obj_name); UtilRemoveQuotes(abs_w_str); UtilRemoveQuotes(abs_h_str); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, NULL, &top_owner); if (named_obj == NULL) { return BadObjName(obj_name, orig_cmd); } if (!IntExpression(abs_w_str, &abs_w, orig_cmd) || !IntExpression(abs_h_str, &abs_h, orig_cmd)) { return FALSE; } if (abs_w < 0 || abs_h < 0) { if (abs_w < 0) { sprintf(gszMsgBox, TgLoadString(STID_BAD_WIDTH_WHILE_EXEC_CMD), abs_w_str, orig_cmd); } else { sprintf(gszMsgBox, TgLoadString(STID_BAD_HEIGHT_WHILE_EXEC_CMD), abs_h_str, orig_cmd); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (abs_w != named_obj->obbox.rbx-named_obj->obbox.ltx || abs_h != named_obj->obbox.lty-named_obj->obbox.rby) { /* SizeAnObj() can only be called from within an internal command */ SizeAnObj(named_obj, top_owner, abs_w, abs_h); } return TRUE; } int ExecMessageBox(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* message_box(attr_name,msg,title,style); */ { char *attr_name=argv[0], *msg=argv[1], *title=argv[2], *style_str=argv[3]; char buf[MAXSTRING]; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; int style=INFO_MB; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(msg); UtilRemoveQuotes(title); UtilRemoveQuotes(style_str); if (strcmp(attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); } if (strcmp(title, "NULL") == 0) { title = TOOL_NAME; } if (strcmp(style_str, "NULL") == 0) { style = INFO_MB; } else if (strcmp(style_str, "info") == 0) { style = INFO_MB; } else if (strcmp(style_str, "ync") == 0) { style = YNC_MB; } else if (strcmp(style_str, "yn") == 0) { style = YN_MB; } else if (strcmp(style_str, "stop") == 0) { style = STOP_MB; } else { sprintf(gszMsgBox, TgLoadString(STID_BAD_STYLE_WHILE_EXEC_CMD), style_str, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } /* do not translate -- program constants */ switch (MsgBox(msg, title, style)) { case MB_ID_FAILED: strcpy(buf, "FAILED"); break; case MB_ID_OK: strcpy(buf, "OK"); break; case MB_ID_CANCEL: strcpy(buf, "CANCEL"); break; case MB_ID_YES: strcpy(buf, "YES"); break; case MB_ID_NO: strcpy(buf, "NO"); break; case MB_ID_EXTRA: strcpy(buf, "EXTRA"); break; default: strcpy(buf, "(unknown)"); break; } if (attr_ptr != NULL) { ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); } return TRUE; } int ExecGetUserInput(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_user_input(attr_name,msg1,msg2); */ { char *attr_name=argv[0], *msg1=argv[1], *msg2=argv[2]; char buf[MAXPATHLENGTH+1]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; int rc=INVALID; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(msg1); UtilRemoveQuotes(msg2); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); *buf = '\0'; if (strcmp(msg2, "USE_CURRENT_DIR") == 0) { if (curDirIsLocal) { sprintf(gszMsgBox, TgLoadString(STID_WORKING_DIRECTORY_IS), curDir); } else { sprintf(gszMsgBox, TgLoadString(STID_WORKING_DIRECTORY_IS), curLocalDir); } rc = Dialog(msg1, gszMsgBox, buf); } else if (strcmp(msg2, "NULL") == 0) { rc = Dialog(msg1, NULL, buf); } else { rc = Dialog(msg1, msg2, buf); } if (rc == INVALID) *buf = '\0'; ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); return TRUE; } int ExecAddAttrToSelObj(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* add_attr_to_selected_obj(attr_name,attr_value,abs_x,abs_y); */ { char *attr_name=argv[0], *attr_value=argv[1]; char *abs_x_str=argv[2], *abs_y_str=argv[3]; struct AttrRec *attr_ptr=NULL; struct ObjRec *selected_obj=NULL; int abs_x=0, abs_y=0, ignore_x=FALSE, ignore_y=FALSE; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(attr_value); UtilRemoveQuotes(abs_x_str); UtilRemoveQuotes(abs_y_str); if (attr_name[0] == '!' && attr_name[1] == '.') { struct ObjRec *attr_owner_obj=NULL; sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) { AddObj(NULL, topObj, tgifObj); AddNewSelObj(topObj); PrepareToReplaceAnObj(tgifObj); attr_ptr = AddAttrByNameAndValue(tgifObj, &execDummyStr[2], attr_value); recordCmdIncludeTgifObj = TRUE; RecordReplaceAnObj(tgifObj); recordCmdIncludeTgifObj = FALSE; UnlinkObj(topObj); FreeTopSel(); SetFileModified(TRUE); } else if (attr_owner_obj != tgifObj) { sprintf(gszMsgBox, TgLoadString(STID_BAD_ATTR_NAME_WHILE_EXEC_CMD), attr_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { ReplaceAttrFirstValue(tgifObj, attr_ptr, attr_value); } return TRUE; } else if (topSel == NULL) { return BadSelectedObj(orig_cmd); } else if (topSel != botSel) { sprintf(gszMsgBox, TgLoadString(STID_TOO_MANY_OBJ_WHILE_EXEC_CMD), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (strchr(attr_name, '.') != NULL) { sprintf(gszMsgBox, TgLoadString(STID_BAD_ATTR_NAME_WHILE_EXEC_CMD), attr_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (strcmp(abs_x_str, "NULL") == 0) { ignore_x = TRUE; } else if (!IntExpression(abs_x_str, &abs_x, orig_cmd)) { return FALSE; } if (strcmp(abs_y_str, "NULL") == 0) { ignore_y = TRUE; } else if (!IntExpression(abs_y_str, &abs_y, orig_cmd)) { return FALSE; } selected_obj = topSel->obj; if (strcmp(attr_name, "NULL") == 0 || *attr_name == '\0') { *execDummyStr = '\0'; } else { sprintf(execDummyStr, "%s=", attr_name); } attr_ptr = FindAttrWithName(selected_obj, execDummyStr, NULL); if (attr_ptr == NULL) { int ltx, lty, rbx, rby, x, y; ltx = selected_obj->bbox.ltx; lty = selected_obj->bbox.lty; rbx = selected_obj->bbox.rbx; rby = selected_obj->bbox.rby; x = (ignore_x ? selected_obj->obbox.ltx : abs_x); y = (ignore_y ? selected_obj->obbox.rby : abs_y); PrepareToReplaceAnObj(selected_obj); attr_ptr = AddAttrByNameAndValue(selected_obj, execDummyStr, attr_value); attr_ptr->shown = TRUE; attr_ptr->obj->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(attr_ptr->obj->color_str, sizeof(attr_ptr->obj->color_str), colorMenuItems[colorIndex]); } MoveObj(attr_ptr->obj, x-attr_ptr->obj->x, y-attr_ptr->obj->y); UpdTextBBox(attr_ptr->obj); AdjObjBBox(selected_obj); UpdSelBBox(); RecordReplaceAnObj(selected_obj); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selected_obj->bbox.ltx-GRID_ABS_SIZE(1), selected_obj->bbox.lty-GRID_ABS_SIZE(1), selected_obj->bbox.rbx+GRID_ABS_SIZE(1), selected_obj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } else { ReplaceAttrFirstValue(selected_obj, attr_ptr, attr_value); } return TRUE; } int ExecDelAttrFromSelObj(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* delete_attr_from_selected_obj(attr_name); */ { char *attr_name=argv[0]; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; int ltx=0, lty=0, rbx=0, rby=0; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (attr_owner_obj == tgifObj) { AddObj(NULL, topObj, tgifObj); AddNewSelObj(topObj); PrepareToReplaceAnObj(attr_owner_obj); UnlinkAttr(attr_ptr); FreeTextObj(attr_ptr->obj); FreeAttr(attr_ptr); AdjObjBBox(attr_owner_obj); recordCmdIncludeTgifObj = TRUE; RecordReplaceAnObj(attr_owner_obj); recordCmdIncludeTgifObj = FALSE; UnlinkObj(topObj); FreeTopSel(); SetFileModified(TRUE); return TRUE; } ltx = attr_owner_obj->bbox.ltx; lty = attr_owner_obj->bbox.lty; rbx = attr_owner_obj->bbox.rbx; rby = attr_owner_obj->bbox.rby; PrepareToReplaceAnObj(attr_owner_obj); UnlinkAttr(attr_ptr); FreeTextObj(attr_ptr->obj); FreeAttr(attr_ptr); AdjObjBBox(attr_owner_obj); if (outerSel != NULL) AdjAncestorsBBox(); UpdSelBBox(); RecordReplaceAnObj(attr_owner_obj); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecUserEndAnEdge(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* user_end_an_edge(attr_name,abs_x,abs_y); */ { char *attr_name=argv[0], *abs_x_str=argv[1], *abs_y_str=argv[2]; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj; int abs_x, abs_y, poly_created=FALSE, already_in_hyperspace=inHyperSpace; XEvent ev; XButtonEvent *button_ev_ptr; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(abs_x_str); UtilRemoveQuotes(abs_y_str); if (strcmp(attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); } if (topSel != NULL) { RemoveAllSel(); } if (!IntExpression(abs_x_str, &abs_x, orig_cmd) || !IntExpression(abs_y_str, &abs_y, orig_cmd)) { return FALSE; } ResetWiringNodeInfo(); SetCurChoice(DRAWPOLY); SetStringStatus(TgLoadString(STID_END_AN_EDGE_AT_A_PORT)); ev.type = ButtonPress; button_ev_ptr = &(ev.xbutton); button_ev_ptr->button = Button1; button_ev_ptr->x = OFFSET_X(abs_x); button_ev_ptr->y = OFFSET_Y(abs_y); polyDrawn = FALSE; gstWiringInfo.num_ports_to_connect = 1; DrawPoly(&ev); gstWiringInfo.num_ports_to_connect = 0; poly_created = polyDrawn; SetCurChoice(NOTHING); if (already_in_hyperspace && !inHyperSpace) ToggleHyperSpace(TRUE); if (attr_ptr != NULL) { ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, (poly_created ? gstWiringInfo.last_port_name : "")); } return TRUE; } int ExecUserDrawAnEdge(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* user_draw_an_edge(start_attr_name,end_attr_name); */ { char *start_attr_name=argv[0], *end_attr_name=argv[1]; struct AttrRec *start_attr_ptr=NULL, *end_attr_ptr=NULL; struct ObjRec *start_attr_owner_obj, *end_attr_owner_obj; int poly_created=FALSE, already_in_hyperspace=inHyperSpace; XGCValues values; UtilRemoveQuotes(start_attr_name); UtilRemoveQuotes(end_attr_name); if (strcmp(start_attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", start_attr_name); start_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &start_attr_owner_obj); if (start_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); } if (strcmp(end_attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", end_attr_name); end_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &end_attr_owner_obj); if (end_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); } if (topSel != NULL) { RemoveAllSel(); } ResetWiringNodeInfo(); connectingPortsByWire = TRUE; UseWireMenuItemInModeItem(TRUE); values.line_width = 3; XChangeGC(mainDisplay, revGrayGC, GCLineWidth, &values); SetCurChoice(DRAWPOLY); gstWiringInfo.num_ports_to_connect = 2; drawPolyHighlightedNode = NULL; SetStringStatus(TgLoadString(STID_DRAW_AN_EDGE_BETWEEN_PORTS)); polyDrawn = FALSE; for (;;) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose) { ExposeEventHandler(&input, TRUE); } else if (input.xany.window == drawWindow) { polyDrawn = FALSE; DrawingEventHandler(&input); if (curChoice == DRAWPOLY) { if (polyDrawn) { break; } else if (gstWiringInfo.num_ports_to_connect == (-1)) { break; } } else { polyDrawn = FALSE; break; } } } gstWiringInfo.num_ports_to_connect = 0; poly_created = polyDrawn; values.line_width = 1; XChangeGC(mainDisplay, revGrayGC, GCLineWidth, &values); connectingPortsByWire = FALSE; SetCurChoice(NOTHING); RedrawModeWindow(); UseWireMenuItemInModeItem(FALSE); UpdatePinnedMenu(MENU_MODE); if (already_in_hyperspace && !inHyperSpace) ToggleHyperSpace(TRUE); if (start_attr_ptr != NULL) { ReplaceAttrFirstValue(start_attr_owner_obj, start_attr_ptr, (poly_created ? gstWiringInfo.first_port_name : "")); } if (end_attr_ptr != NULL) { ReplaceAttrFirstValue(end_attr_owner_obj, end_attr_ptr, (poly_created ? gstWiringInfo.last_port_name : "")); } return TRUE; } int ExecGetAPolyVertexAbs(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_a_poly_vertex_absolute(x_attr,y_attr,obj_name,v_index); */ { char *x_attr_name=argv[0], *y_attr_name=argv[1], *obj_name=argv[2]; char *v_index_str=argv[3], buf[40]; int v_index=0, abs_x=0, abs_y=0; struct AttrRec *x_attr_ptr, *y_attr_ptr; struct ObjRec *x_attr_owner_obj=NULL, *y_attr_owner_obj=NULL; struct ObjRec *owner_obj=NULL, *named_obj; UtilRemoveQuotes(x_attr_name); UtilRemoveQuotes(y_attr_name); UtilRemoveQuotes(obj_name); UtilRemoveQuotes(v_index_str); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, &owner_obj, NULL); if (named_obj == NULL) { return BadObjName(obj_name, orig_cmd); } if (!IntExpression(v_index_str, &v_index, orig_cmd)) return FALSE; switch (named_obj->type) { case OBJ_POLY: if (v_index < 0 || v_index >= named_obj->detail.p->n) { sprintf(execDummyStr, TgLoadString(STID_CANT_FIND_VRTX_WHILE_EXEC_CMD), v_index, obj_name, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } abs_x = (int)named_obj->detail.p->vlist[v_index].x; abs_y = (int)named_obj->detail.p->vlist[v_index].y; break; case OBJ_POLYGON: if (v_index < 0 || v_index >= named_obj->detail.g->n) { sprintf(execDummyStr, TgLoadString(STID_CANT_FIND_VRTX_WHILE_EXEC_CMD), v_index, obj_name, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } abs_x = (int)named_obj->detail.g->vlist[v_index].x; abs_y = (int)named_obj->detail.g->vlist[v_index].y; break; default: sprintf(execDummyStr, TgLoadString(STID_POLY_NOR_PGON_WHILE_EXEC_CMD), obj_name, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } sprintf(execDummyStr, "%s=", x_attr_name); x_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &x_attr_owner_obj); if (x_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", y_attr_name); y_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &y_attr_owner_obj); if (y_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(buf, "%1d", abs_x); ReplaceAttrFirstValue(x_attr_owner_obj, x_attr_ptr, buf); sprintf(buf, "%1d", abs_y); ReplaceAttrFirstValue(y_attr_owner_obj, y_attr_ptr, buf); SetFileModified(TRUE); return TRUE; } int ExecMoveAPolyVertexAbs(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* move_a_poly_vertex_absolute(obj_name,v_index,abs_x,abs_y); */ { char *obj_name=argv[0], *v_index_str=argv[1]; char *abs_x_str=argv[2], *abs_y_str=argv[3]; int v_index=0, abs_x=0, abs_y=0, cur_x=0, cur_y=0, ltx, lty, rbx, rby; int auto_center_attr; struct ObjRec *owner_obj=NULL, *top_owner=NULL, *named_obj; struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; UtilRemoveQuotes(obj_name); UtilRemoveQuotes(v_index_str); UtilRemoveQuotes(abs_x_str); UtilRemoveQuotes(abs_y_str); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, &owner_obj, &top_owner); if (named_obj == NULL) { return BadObjName(obj_name, orig_cmd); } if (!IntExpression(v_index_str, &v_index, orig_cmd)) return FALSE; if (!IntExpression(abs_x_str, &abs_x, orig_cmd)) return FALSE; if (!IntExpression(abs_y_str, &abs_y, orig_cmd)) return FALSE; switch (named_obj->type) { case OBJ_POLY: if (v_index < 0 || v_index >= named_obj->detail.p->n) { sprintf(execDummyStr, TgLoadString(STID_CANT_FIND_VRTX_WHILE_EXEC_CMD), v_index, obj_name, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } cur_x = named_obj->detail.p->vlist[v_index].x; cur_y = named_obj->detail.p->vlist[v_index].y; break; case OBJ_POLYGON: if (v_index < 0 || v_index >= named_obj->detail.g->n) { sprintf(execDummyStr, TgLoadString(STID_CANT_FIND_VRTX_WHILE_EXEC_CMD), v_index, obj_name, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } cur_x = named_obj->detail.g->vlist[v_index].x; cur_y = named_obj->detail.g->vlist[v_index].y; break; default: sprintf(execDummyStr, TgLoadString(STID_POLY_NOR_PGON_WHILE_EXEC_CMD), obj_name, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } if (cur_x == abs_x && cur_y == abs_y) return TRUE; if (owner_obj == NULL) { ltx = named_obj->bbox.ltx; lty = named_obj->bbox.lty; rbx = named_obj->bbox.rbx; rby = named_obj->bbox.rby; } else { ltx = top_owner->bbox.ltx; lty = top_owner->bbox.lty; rbx = top_owner->bbox.rbx; rby = top_owner->bbox.rby; } SelectAnObj(named_obj, owner_obj, top_owner, &saved_top_sel, &saved_bot_sel); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); switch (named_obj->type) { case OBJ_POLY: named_obj->detail.p->vlist[v_index].x = abs_x; named_obj->detail.p->vlist[v_index].y = abs_y; AdjObjSplineVs(named_obj); if (named_obj->detail.p->curved != LT_INTSPLINE) { UpdPolyBBox(named_obj, named_obj->detail.p->n, named_obj->detail.p->vlist); } else { UpdPolyBBox(named_obj, named_obj->detail.p->intn, named_obj->detail.p->intvlist); } break; case OBJ_POLYGON: named_obj->detail.g->vlist[v_index].x = abs_x; named_obj->detail.g->vlist[v_index].y = abs_y; if (v_index == 0) { named_obj->detail.g->vlist[named_obj->detail.g->n-1].x = abs_x; named_obj->detail.g->vlist[named_obj->detail.g->n-1].y = abs_y; } else if (v_index == named_obj->detail.g->n-1) { named_obj->detail.g->vlist[0].x = abs_x; named_obj->detail.g->vlist[0].y = abs_y; } AdjObjSplineVs(named_obj); if (named_obj->detail.g->curved != LT_INTSPLINE) { UpdPolyBBox(named_obj, named_obj->detail.g->n, named_obj->detail.g->vlist); } else { UpdPolyBBox(named_obj, named_obj->detail.g->intn, named_obj->detail.g->intvlist); } break; } auto_center_attr = AutoCenterAttr(named_obj); if (auto_center_attr) { struct AttrRec *attr_ptr; int modified=FALSE; for (attr_ptr=named_obj->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { struct BBRec bbox; CenterObjInOBBox(attr_ptr->obj, named_obj->obbox, &bbox); if (bbox.ltx < ltx) ltx = bbox.ltx; if (bbox.lty < lty) lty = bbox.lty; if (bbox.rbx > rbx) rbx = bbox.rbx; if (bbox.rby > rby) rby = bbox.rby; modified = TRUE; } } if (modified) AdjObjBBox(named_obj); } RecursivelyAdjObjBBox(named_obj, owner_obj, top_owner); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); UpdSelBBox(); if (owner_obj == NULL) { if (named_obj->bbox.ltx < ltx) ltx = named_obj->bbox.ltx; if (named_obj->bbox.lty < lty) lty = named_obj->bbox.lty; if (named_obj->bbox.rbx > rbx) rbx = named_obj->bbox.rbx; if (named_obj->bbox.rby > rby) rby = named_obj->bbox.rby; } else { if (top_owner->bbox.ltx < ltx) ltx = top_owner->bbox.ltx; if (top_owner->bbox.lty < lty) lty = top_owner->bbox.lty; if (top_owner->bbox.rbx > rbx) rbx = top_owner->bbox.rbx; if (top_owner->bbox.rby > rby) rby = top_owner->bbox.rby; } free(topSel); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecPostAttrAndGetCGI(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* post_attr_and_get_cgi_result(url_attr,query_attr,result_attr); */ { char *url_attr_name=argv[0], *query_attr_name=argv[1]; char *result_attr_name=argv[2]; struct AttrRec *url_attr, *query_attr, *result_attr; struct ObjRec *result_attr_owner_obj=NULL; char *remote_buf=NULL, *tmp_remote_fname=NULL; int is_html=FALSE, remote_buf_sz=0, rc; FILE *fp; UtilRemoveQuotes(url_attr_name); UtilRemoveQuotes(query_attr_name); UtilRemoveQuotes(result_attr_name); sprintf(execDummyStr, "%s=", url_attr_name); url_attr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (url_attr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", query_attr_name); query_attr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (query_attr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", result_attr_name); result_attr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr == NULL) return BadAttr(execDummyStr, orig_cmd); if (!FileIsRemote(url_attr->attr_value.s)) { sprintf(gszMsgBox, TgLoadString(STID_BAD_REM_FNAME_WHILE_EXEC_CMD), url_attr->attr_value.s, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } fnameForPostingCGIQuery = (char*)malloc((strlen(tmpDir)+20)*sizeof(char)); if (fnameForPostingCGIQuery == NULL) { FailAllocMessage(); return FALSE; } if (MkTempFile(fnameForPostingCGIQuery, (strlen(tmpDir)+19)*sizeof(char), tmpDir, TOOL_NAME) == NULL) { free(fnameForPostingCGIQuery); fnameForPostingCGIQuery = NULL; return FALSE; } if ((fp=fopen(fnameForPostingCGIQuery, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_FILE_WRITE_EXEC_CMD), fnameForPostingCGIQuery, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(fnameForPostingCGIQuery); fnameForPostingCGIQuery = NULL; return FALSE; } writeFileFailed = FALSE; fprintf(fp, "%s\r\n", query_attr->attr_value.s); if (query_attr->obj->detail.t->minilines.first != NULL) { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=query_attr->obj->detail.t->minilines.first->next; pMiniLine != NULL; pMiniLine=pMiniLine->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); if (fprintf(fp, "%s\r\n", tmp_buf) == EOF) { writeFileFailed = TRUE; } if (need_to_free_tmp_buf) UtilFree(tmp_buf); if (writeFileFailed) break; } } fclose(fp); if (writeFileFailed) { FailToWriteFileMessage(fnameForPostingCGIQuery); unlink(fnameForPostingCGIQuery); free(fnameForPostingCGIQuery); fnameForPostingCGIQuery = NULL; return FALSE; } postingCGIQuery = TRUE; SaveStatusStrings(); rc = LoadRemoteFileInMem(url_attr->attr_value.s, &remote_buf, NULL, &remote_buf_sz, &is_html, TRUE, NULL, 0); RestoreStatusStrings(); postingCGIQuery = FALSE; unlink(fnameForPostingCGIQuery); free(fnameForPostingCGIQuery); fnameForPostingCGIQuery = NULL; if (!rc) { sprintf(gszMsgBox, TgLoadString(STID_UNEXP_ERR_EXEC_CMD_ABORT), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } tmp_remote_fname = WriteRemoteFileIntoTemp(remote_buf, remote_buf_sz, NULL); if (tmp_remote_fname == NULL) { return FALSE; } SaveStatusStrings(); rc = DoReadFileIntoAttr(result_attr, result_attr_owner_obj, tmp_remote_fname, orig_cmd); RestoreStatusStrings(); if (remote_buf != NULL) FreeRemoteBuf(remote_buf); if (tmp_remote_fname != NULL) { unlink(tmp_remote_fname); FreeRemoteBuf(tmp_remote_fname); } return rc; } void ExecNavigateBack(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* navigate_back(); */ { execNavigateBack = TRUE; } void ExecStop(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* stop(); */ { gnAbortExec = TRUE; gnStopCmdExecuted = TRUE; sprintf(gszMsgBox, TgLoadString(STID_GIVEN_CMD_EXECUTED), orig_cmd); Msg(gszMsgBox); } int ExecSqrt(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* sqrt(attr_name,expr); */ { char *attr_name=argv[0], *expr=argv[1], buf[40]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; struct VRec v; double d_val=(double)0.0; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(expr); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (!EvalExpr(expr, &v)) return FALSE; switch (v.vtype) { case INT_VAL: d_val = (double)v.val.i; break; case DBL_VAL: d_val = (double)v.val.d; break; case NULL_VAL: case STR_VAL: sprintf(gszMsgBox, TgLoadString(STID_BAD_EVAL_NUM_EXP_EXEC_CMD), expr, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (v.vtype == STR_VAL && v.val.s != NULL) free(v.val.s); return FALSE; } if (d_val < (double)0.0) { sprintf(gszMsgBox, TgLoadString(STID_SQRT_NEG_NUM_WHILE_EXEC_CMD), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } d_val = (double)sqrt((double)d_val); sprintf(buf, "%.12f", (float)(d_val)); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); return TRUE; } int ExecRandom(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* random(attr_name); */ { static int snSeeded=FALSE; char *attr_name=argv[0], buf[40]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilTrimBlanks(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (!snSeeded) { snSeeded = TRUE; srand(0); } sprintf(buf, "%1d", rand()); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); return TRUE; } #ifndef _NO_RAND48 static int gnDRand48Seeded=FALSE; #endif /* ~_NO_RAND48 */ #ifdef _NO_RAND48 static int NoRand48(orig_cmd) char *orig_cmd; { sprintf(gszMsgBox, TgLoadString(STID_CMD_NOT_AVAIL_ON_PLATFORM), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } #endif /* _NO_RAND48 */ int ExecSRand48(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* srand48(use_cur_time_as_seed); */ { #ifndef _NO_RAND48 char *use_cur_time_str=argv[0]; int use_cur_time=0; UtilRemoveQuotes(use_cur_time_str); UtilTrimBlanks(use_cur_time_str); if (!IntExpression(use_cur_time_str, &use_cur_time, orig_cmd)) { return FALSE; } if (use_cur_time == 0) { srand48(0L); } else { time_t tloc; time(&tloc); srand48((long)tloc); } gnDRand48Seeded = TRUE; return TRUE; #else /* _NO_RAND48 */ return NoRand48(orig_cmd); #endif /* ~_NO_RAND48 */ } int ExecDRand48(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* drand48(attr_name); */ { #ifndef _NO_RAND48 char *attr_name=argv[0], buf[40]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; double d_val=(double)0; UtilRemoveQuotes(attr_name); UtilTrimBlanks(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (!gnDRand48Seeded) { gnDRand48Seeded = TRUE; srand48(0L); } d_val = (double)drand48(); sprintf(buf, "%.12f", (float)(d_val)); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); return TRUE; #else /* _NO_RAND48 */ return NoRand48(orig_cmd); #endif /* ~_NO_RAND48 */ } int ExecRound(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* round(attr_name,expr); */ { char *attr_name=argv[0], *expr=argv[1], buf[40]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; struct VRec v; double d_val=(double)0.0; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(expr); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (!EvalExpr(expr, &v)) return FALSE; switch (v.vtype) { case INT_VAL: d_val = (double)v.val.i; break; case DBL_VAL: d_val = (double)v.val.d; break; case NULL_VAL: case STR_VAL: sprintf(gszMsgBox, TgLoadString(STID_BAD_EVAL_NUM_EXP_EXEC_CMD), expr, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (v.vtype == STR_VAL && v.val.s != NULL) free(v.val.s); return FALSE; } sprintf(buf, "%1d", round(d_val)); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); return TRUE; } int ExecRedrawObj(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* redraw_obj(obj_name); */ { char *obj_name=argv[0]; struct ObjRec *owner_obj=NULL, *top_owner=NULL, *named_obj; int ltx, lty, rbx, rby; UtilRemoveQuotes(obj_name); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, &owner_obj, &top_owner); if (named_obj == NULL) return BadObjName(obj_name, orig_cmd); ltx = named_obj->bbox.ltx; lty = named_obj->bbox.lty; rbx = named_obj->bbox.rbx; rby = named_obj->bbox.rby; RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); return TRUE; } void ExecRedrawDrawingArea(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* redraw_drawing_area(); */ { RedrawDrawWindow(botObj); } int ExecIntToHex(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* itox(attr_name,digits,expr); */ { char *attr_name=argv[0], *digits_str=argv[1], *expr=argv[2]; char buf[40], buf1[40]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; struct VRec v; int digits=0, i_val=0; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(digits_str); UtilRemoveQuotes(expr); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (!IntExpression(digits_str, &digits, orig_cmd)) { return FALSE; } if (digits <= 0 || digits > 8) { sprintf(gszMsgBox, TgLoadString(STID_FUNC_ARG_RANGE), orig_cmd, "digits", 1, 8, digits); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (!EvalExpr(expr, &v)) return FALSE; switch (v.vtype) { case INT_VAL: i_val = v.val.i; break; case DBL_VAL: i_val = round(v.val.d); break; case NULL_VAL: case STR_VAL: sprintf(gszMsgBox, TgLoadString(STID_BAD_EVAL_NUM_EXP_EXEC_CMD), expr, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (v.vtype == STR_VAL && v.val.s != NULL) free(v.val.s); return FALSE; } sprintf(buf1, "%%0%1dx", digits); sprintf(buf, buf1, i_val); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); return TRUE; } int ExecForI(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* for_i(attr_name,min_val,max_val,inc,attr_to_exec); */ { char *attr_name=argv[0], *min_str=argv[1], *max_str=argv[2]; char *inc_str=argv[3], *exec_attr_name=argv[4], num_buf[40]; char *compare_buf=NULL, *assign_buf=NULL; struct AttrRec *attr_ptr=NULL, *exec_attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL, *exec_attr_owner_obj=NULL; int min_val=0, max_val=0, inc_val=1, ok=TRUE; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(min_str); UtilRemoveQuotes(max_str); UtilRemoveQuotes(inc_str); UtilRemoveQuotes(exec_attr_name); if (strcmp(attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); } sprintf(execDummyStr, "%s=", exec_attr_name); exec_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &exec_attr_owner_obj); if (exec_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (!IntExpression(min_str, &min_val, orig_cmd) || !IntExpression(max_str, &max_val, orig_cmd) || !IntExpression(inc_str, &inc_val, orig_cmd)) { return FALSE; } if (attr_ptr != NULL) { compare_buf = (char*)malloc((strlen(attr_name)+40)*sizeof(char)); assign_buf = (char*)malloc((strlen(attr_name)+40)*sizeof(char)); if (compare_buf == NULL || assign_buf == NULL) { FailAllocMessage(); if (compare_buf != NULL) free(compare_buf); if (assign_buf != NULL) free(assign_buf); return FALSE; } sprintf(compare_buf, "$(%s) <= %1d", attr_name, max_val); sprintf(assign_buf, "$(%s)", attr_name); sprintf(num_buf, "%1d", min_val); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, num_buf); } while (ok) { if (attr_ptr != NULL) { int val; char *expr=convert_str(compare_buf, obj_ptr, TRUE); if (expr == NULL) { BadAttr(compare_buf, orig_cmd); free(compare_buf); return FALSE; } else if (!IntExpression(expr, &val, orig_cmd)) { free(expr); free(compare_buf); return FALSE; } free(expr); if (val == 0) break; } else { if (min_val > max_val) break; } if (!DoExec(exec_attr_ptr, exec_attr_owner_obj)) return FALSE; if (attr_ptr != NULL) { int val; char *expr=convert_str(assign_buf, obj_ptr, TRUE); if (expr == NULL) { BadAttr(assign_buf, orig_cmd); free(assign_buf); return FALSE; } else if (!IntExpression(expr, &val, orig_cmd)) { free(expr); free(assign_buf); return FALSE; } free(expr); min_val = val + inc_val; sprintf(num_buf, "%1d", min_val); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, num_buf); } else { min_val += inc_val; } ok = (!CheckExecInterrupt(orig_cmd)); if (!ok) { userAbortExec = TRUE; } } if (compare_buf != NULL) free(compare_buf); if (assign_buf != NULL) free(assign_buf); return ok; } void ExecSetFileNotModified(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* set_file_not_modified(); */ { justDupped = FALSE; SetFileModified(FALSE); RedrawTitleWindow(); } int ExecNewId(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* new_id(attr_name); */ { char *attr_name=argv[0], buf[40]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(buf, "%1d", objId++); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); return TRUE; } int ExecRotateSelObj(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* rotate_selected_obj(angle); */ { char *expr=argv[0]; struct VRec v; double d_val=(double)0.0; UtilRemoveQuotes(expr); if (topSel == NULL) return BadSelectedObj(orig_cmd); if (!EvalExpr(expr, &v)) return FALSE; switch (v.vtype) { case INT_VAL: d_val = (double)v.val.i; break; case DBL_VAL: d_val = (double)v.val.d; break; case NULL_VAL: case STR_VAL: sprintf(gszMsgBox, TgLoadString(STID_BAD_EVAL_NUM_EXP_EXEC_CMD), expr, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (v.vtype == STR_VAL && v.val.s != NULL) free(v.val.s); return FALSE; } RotateAllSelObj(d_val); return TRUE; } int ExecCallSimpleShortCut(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* call_simple_shortcut(shortcut_name); */ { char *shortcut_name=argv[0], *func_name=NULL, *buf=NULL, code='\0'; unsigned int state=0; int len, rc=TRUE; UtilRemoveQuotes(shortcut_name); if (!ValidShortCut(shortcut_name, 0, &code, &state)) { int found=FALSE; if (cmdLineTgrm2) { int actual_num_args=0; int index=ValidTangram2CmdName(shortcut_name, strlen(shortcut_name), &actual_num_args); if (index != 0 && actual_num_args == 0) { found = TRUE; DoTangram2ShortCut(index-CMDID_TANGRAM2_BASE, ""); } } if (!found) { sprintf(gszMsgBox, TgLoadString(STID_BAD_SHORTCUT_WHILE_EXEC_CMD), shortcut_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return found; } len = strlen(shortcut_name); if ((func_name=(char*)malloc((len+3)*sizeof(char))) == NULL) { FailAllocMessage(); return FALSE; } sprintf(func_name, "%s()", shortcut_name); if ((buf=UtilStrDup(func_name)) == NULL) { free(func_name); FailAllocMessage(); return FALSE; } rc = CallShortCut(func_name, 1, &buf, &code, state); free(buf); free(func_name); if (!rc) { sprintf(gszMsgBox, TgLoadString(STID_BAD_SHORTCUT_WHILE_EXEC_CMD), shortcut_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { /* do not translate -- program constants */ if (UtilStrICmp(shortcut_name, "Quit") == 0) { gnAbortExec = TRUE; } } return rc; } int ExecCallOneArgShortCut(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* call_one_arg_shortcut(shortcut_name,arg); */ { char *shortcut_name=argv[0], *arg=argv[1], **ppsz_buf=NULL, code='\0'; char *func_name=NULL; unsigned int state; int len=0; UtilRemoveQuotes(shortcut_name); UtilRemoveQuotes(arg); /* do not translate -- program constants */ if (strcmp(shortcut_name, "Quit") == 0 || !ValidShortCut(shortcut_name, 1, &code, &state)) { int found=FALSE; if (cmdLineTgrm2) { int actual_num_args=0; int index=ValidTangram2CmdName(shortcut_name, strlen(shortcut_name), &actual_num_args); if (index != 0 && actual_num_args == 1) { found = TRUE; DoTangram2ShortCut(index-CMDID_TANGRAM2_BASE, arg); } } if (!found) { sprintf(gszMsgBox, TgLoadString(STID_BAD_SHORTCUT_WHILE_EXEC_CMD), shortcut_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return found; } len = strlen(shortcut_name); if ((func_name=(char*)malloc((len+3)*sizeof(char))) == NULL) { FailAllocMessage(); return FALSE; } sprintf(func_name, "%s()", shortcut_name); if ((ppsz_buf=(char**)malloc(2*sizeof(char*))) == NULL) { free(func_name); FailAllocMessage(); return FALSE; } if ((ppsz_buf[0]=UtilStrDup(func_name)) == NULL) { free(ppsz_buf); free(func_name); FailAllocMessage(); return FALSE; } len = strlen(arg); if ((ppsz_buf[1]=(char*)malloc((len+2)*sizeof(char))) == NULL) { free(ppsz_buf[0]); free(ppsz_buf); free(func_name); FailAllocMessage(); return FALSE; } sprintf(ppsz_buf[1], "%s)", arg); CallShortCut(func_name, 2, ppsz_buf, &code, state); free(ppsz_buf[1]); free(ppsz_buf[0]); free(ppsz_buf); free(func_name); return TRUE; } int ExecSubstituteAttr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* substitute_attr(attr_name,src_attr_name,replace_attr_name,pattern_str); */ { char *attr_name=argv[0], *src_attr_name=argv[1]; char *replace_attr_name=argv[2], *pattern_str=argv[3]; char tmp_fname[MAXPATHLENGTH+1]; struct AttrRec *attr_ptr=NULL, *src_attr_ptr=NULL, *replace_attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; MiniLineInfo *pMiniLine=NULL; int rc, pattern_len=0; FILE *fp; if (*pattern_str == '\0') return BadArg("pattern_str", orig_cmd); UtilRemoveQuotes(attr_name); UtilRemoveQuotes(src_attr_name); UtilRemoveQuotes(replace_attr_name); UtilRemoveQuotes(pattern_str); pattern_len = strlen(pattern_str); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", src_attr_name); src_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (src_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", replace_attr_name); replace_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (replace_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { return FALSE; } if ((fp=fopen(tmp_fname, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_FILE_WRITE_EXEC_CMD), tmp_fname, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } writeFileFailed = FALSE; for (pMiniLine=src_attr_ptr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { char *c_ptr, *buf=NULL; int need_to_free_tmp_buf=FALSE; char *tmp_buf=NULL; if (pMiniLine == src_attr_ptr->obj->detail.t->minilines.first) { char *attr_value=NULL; tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); attr_value = UtilStrDup(tmp_buf); if (attr_value == NULL) FailAllocMessage(); ParseAttrStr(tmp_buf, NULL, 0, attr_value, strlen(attr_value)+1); if (need_to_free_tmp_buf) UtilFree(tmp_buf); need_to_free_tmp_buf = TRUE; buf = tmp_buf = attr_value; } else { tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); buf = tmp_buf; } for (c_ptr=strstr(buf, pattern_str); c_ptr != NULL; c_ptr=strstr(buf, pattern_str)) { char saved_ch=(*c_ptr); MiniLineInfo *pReplaceMiniLine=NULL; *c_ptr = '\0'; if (fprintf(fp, "%s", buf) == EOF) { writeFileFailed = TRUE; } for (pReplaceMiniLine=replace_attr_ptr->obj->detail.t->minilines.first; pReplaceMiniLine != NULL; pReplaceMiniLine=pReplaceMiniLine->next) { char *buf1=NULL; int need_to_free_tmp_buf1=FALSE; char *tmp_buf1=ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf1); if (pReplaceMiniLine == replace_attr_ptr->obj->detail.t->minilines.first) { char *attr_value=NULL; tmp_buf1 = ConvertMiniLineToString(pReplaceMiniLine, &need_to_free_tmp_buf1); attr_value = UtilStrDup(tmp_buf1); if (attr_value == NULL) FailAllocMessage(); ParseAttrStr(tmp_buf1, NULL, 0, attr_value, strlen(attr_value)+1); if (need_to_free_tmp_buf1) UtilFree(tmp_buf1); need_to_free_tmp_buf1 = TRUE; buf1 = tmp_buf1 = attr_value; } else { tmp_buf1 = ConvertMiniLineToString(pReplaceMiniLine, &need_to_free_tmp_buf1); buf1 = tmp_buf1; } if (fprintf(fp, "%s%s", buf1, pReplaceMiniLine->next==NULL ? "" : "\n") == EOF) { writeFileFailed = TRUE; } if (need_to_free_tmp_buf1) UtilFree(tmp_buf1); if (writeFileFailed) break; } *c_ptr = saved_ch; buf = (&c_ptr[pattern_len]); } if (buf != NULL) { if (fprintf(fp, "%s\n", buf) == EOF) { writeFileFailed = TRUE; } } if (need_to_free_tmp_buf) UtilFree(tmp_buf); if (writeFileFailed) break; } fclose(fp); if (writeFileFailed) { FailToWriteFileMessage(tmp_fname); unlink(tmp_fname); return FALSE; } SaveStatusStrings(); rc = DoReadFileIntoAttr(attr_ptr, attr_owner_obj, tmp_fname, orig_cmd); RestoreStatusStrings(); unlink(tmp_fname); return rc; } int ExecGetFileSize(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_file_size(attr_name,file_name); */ { char *attr_name=argv[0], *file_name=argv[1], buf[40]; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; struct stat stat_buf; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(file_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (stat(file_name, &stat_buf) != 0) { sprintf(gszMsgBox, TgLoadString(STID_STAT_FAILED_WHILE_EXEC_CMD), file_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } sprintf(buf, "%ld", (long)stat_buf.st_size); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); return TRUE; } int ExecIsFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* is_file(attr_name,file_name); */ { char *attr_name=argv[0], *file_name=argv[1], buf[40]; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; FILE *fp; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(file_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if ((fp=fopen(file_name, "r")) != NULL) { fclose(fp); strcpy(buf, "1"); } else { strcpy(buf, "0"); } ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); return TRUE; } int ExecIndex(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* index(attr_name,str,substr); */ { char *attr_name=argv[0], *the_str=argv[1], *sub_str=argv[2], *c_ptr, buf[40]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(the_str); UtilRemoveQuotes(sub_str); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); c_ptr = strstr(the_str, sub_str); if (c_ptr == NULL) { strcpy(buf, "-1"); } else { sprintf(buf, "%1d", (int)(c_ptr-the_str)); } ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); return TRUE; } int ExecRIndex(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* rindex(attr_name,str,substr); */ { char *attr_name=argv[0], *the_str=argv[1], *sub_str=argv[2]; char *c_ptr, *last_match=NULL, buf[40]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(the_str); UtilRemoveQuotes(sub_str); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); for (c_ptr=strstr(the_str, sub_str); c_ptr != NULL; c_ptr=strstr(&last_match[1], sub_str)) { last_match = c_ptr; } if (last_match == NULL) { strcpy(buf, "-1"); } else { sprintf(buf, "%1d", (int)(last_match-the_str)); } ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); return TRUE; } int ExecGetNumberOfLines(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_number_of_lines_in_attr(result_attr,attr_name); */ { char *result_attr_name=argv[0], *attr_name=argv[1], buf[40]; int count; MiniLineInfo *pMiniLine=NULL; struct AttrRec *result_attr_ptr, *attr_ptr; struct ObjRec *result_attr_owner_obj=NULL, *attr_owner_obj=NULL; UtilRemoveQuotes(result_attr_name); UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", result_attr_name); result_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); count = 0; for (pMiniLine=attr_ptr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { count++; } sprintf(buf, "%1d", count); ReplaceAttrFirstValue(result_attr_owner_obj, result_attr_ptr, buf); SetFileModified(TRUE); return TRUE; } int ExecGetLineInAttr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_line_in_attr(result_attr,attr_name,line_number); */ { char *result_attr_name=argv[0], *attr_name=argv[1]; char *line_number_str=argv[2], *psz=NULL; int count, line_number=(-1); MiniLineInfo *pMiniLine=NULL; struct AttrRec *result_attr_ptr, *attr_ptr; struct ObjRec *result_attr_owner_obj=NULL, *attr_owner_obj=NULL; UtilRemoveQuotes(result_attr_name); UtilRemoveQuotes(attr_name); UtilRemoveQuotes(line_number_str); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(execDummyStr, "%s=", result_attr_name); result_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (!IntExpression(line_number_str, &line_number, orig_cmd)) { return FALSE; } count = 0; for (pMiniLine=attr_ptr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (count == line_number) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=NULL; if (pMiniLine == attr_ptr->obj->detail.t->minilines.first) { char *attr_value=NULL; tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); attr_value = UtilStrDup(tmp_buf); if (attr_value == NULL) FailAllocMessage(); ParseAttrStr(tmp_buf, NULL, 0, attr_value, strlen(attr_value)+1); if (need_to_free_tmp_buf) UtilFree(tmp_buf); psz = UtilStrDup(attr_value); UtilFree(attr_value); } else { tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); psz = UtilStrDup(tmp_buf); if (need_to_free_tmp_buf) UtilFree(tmp_buf); } if (psz == NULL) FailAllocMessage(); break; } count++; } if (psz == NULL) psz = UtilStrDup(""); ReplaceAttrFirstValue(result_attr_owner_obj, result_attr_ptr, psz); UtilFree(psz); SetFileModified(TRUE); return TRUE; } int ExecTrim(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* trim(attr_name); */ { char *attr_name=argv[0], *psz; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); psz = UtilStrDup(attr_ptr->attr_value.s); if (psz == NULL) FailAllocMessage(); UtilTrimBlanks(psz); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, psz); UtilFree(psz); return TRUE; } int ExecIsAttr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* is_attr(result_attr,attr_name); */ { char *result_attr_name=argv[0], *attr_name=argv[1], buf[40]; struct AttrRec *result_attr_ptr, *attr_ptr; struct ObjRec *result_attr_owner_obj=NULL, *attr_owner_obj=NULL; UtilRemoveQuotes(result_attr_name); UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); strcpy(buf, (attr_ptr==NULL ? "0" : "1")); sprintf(execDummyStr, "%s=", result_attr_name); result_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); ReplaceAttrFirstValue(result_attr_owner_obj, result_attr_ptr, buf); SetFileModified(TRUE); return TRUE; } int ExecFindObjNames(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* find_obj_names(result_attr,obj_name,attr_name_value); */ { char *result_attr_name=argv[0], *obj_name=argv[1], *attr_str=argv[2]; char *psz=NULL, *attr_name=NULL, *attr_value=NULL; struct AttrRec *result_attr_ptr=NULL; struct ObjRec *result_attr_owner_obj=NULL, *optr=NULL; struct ObjRec *parent_obj_ptr=NULL, *first_obj_ptr=NULL; int ok=TRUE; UtilRemoveQuotes(result_attr_name); UtilRemoveQuotes(obj_name); UtilRemoveQuotes(attr_str); sprintf(execDummyStr, "%s=", result_attr_name); result_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (*obj_name == '\0') { parent_obj_ptr = NULL; } else if ((parent_obj_ptr=FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, NULL, NULL)) == NULL) { return BadObjName(obj_name, orig_cmd); } else { switch (parent_obj_ptr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: sprintf(gszMsgBox, TgLoadString(STID_NON_GROUPED_WHILE_EXEC_CMD), obj_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } if (strcmp(attr_str, "") == 0) { attr_name = attr_value = NULL; } else if ((psz=strchr(attr_str,'=')) != NULL) { if (*(++psz) != '\0') { if (strcmp(psz, "*") == 0) { attr_value = NULL; } else { attr_value = UtilStrDup(psz); if (attr_value == NULL) FailAllocMessage(); } *psz = '\0'; } else { attr_value = UtilStrDup(""); if (attr_value == NULL) FailAllocMessage(); } attr_name = attr_str; } else { attr_name = NULL; attr_value = UtilStrDup(attr_str); if (attr_value == NULL) FailAllocMessage(); } CleanTmpStr(); if (parent_obj_ptr == NULL) { first_obj_ptr = topObj; } else { first_obj_ptr = parent_obj_ptr->detail.r->first; } for (optr=first_obj_ptr; optr != NULL; optr=optr->next) { struct AttrRec *name_attr=FindAttrWithName(optr,"name=",NULL); if (name_attr != NULL) { if (attr_name == NULL && attr_value == NULL) { if (!AppendToTmpStr(name_attr->attr_value.s)) { ok = FALSE; break; } } else { struct AttrRec *aptr=NULL; for (aptr=optr->fattr; aptr != NULL; aptr=aptr->next) { if (attr_name == NULL) { if (*aptr->attr_name.s == '\0' && strcmp(aptr->attr_value.s, attr_value) == 0) { break; } } else if (attr_value == NULL) { if (strcmp(aptr->attr_name.s, attr_name) == 0) { break; } } else { if (strcmp(aptr->attr_name.s, attr_name) == 0 && strcmp(aptr->attr_value.s, attr_value) == 0) { break; } } } if (aptr != NULL && !AppendToTmpStr(name_attr->attr_value.s)) { ok = FALSE; break; } } } } if (ok) { int count=0; char *count_buf=(char*)malloc((strlen(result_attr_name)+40)*sizeof(char)); struct StrRec *str_ptr; if (count_buf == NULL) FailAllocMessage(); for (str_ptr=topTmpStr; str_ptr != NULL; str_ptr=str_ptr->next) { count++; } sprintf(count_buf, "%s=%d", result_attr_name, count); if (PrependToTmpStr(count_buf)) { ReplaceAttrAllValues(result_attr_owner_obj, result_attr_ptr, &topTmpStr, &botTmpStr); } free(count_buf); } CleanTmpStr(); if (attr_value != NULL) UtilFree(attr_value); return TRUE; } static int FindObjNamesOnAllPgs(argv, obj_ptr, orig_cmd, tg2) char **argv, *orig_cmd; struct ObjRec *obj_ptr; int tg2; /* * find_obj_names_on_all_pages(result_attr,attr_name_value) or * tg2_find_obj_names_on_all_pages(result_attr,attr_name_value) */ { char *result_attr_name=argv[0], *attr_str=argv[1]; char *psz=NULL, *attr_name=NULL, *attr_value=NULL; struct AttrRec *result_attr_ptr=NULL; struct ObjRec *result_attr_owner_obj=NULL; struct PageRec *page_ptr=NULL; int ok=TRUE, page_num=0; UtilRemoveQuotes(result_attr_name); UtilRemoveQuotes(attr_str); sprintf(execDummyStr, "%s=", result_attr_name); result_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (strcmp(attr_str, "") == 0) { attr_name = attr_value = NULL; } else if ((psz=strchr(attr_str,'=')) != NULL) { if (*(++psz) != '\0') { if (strcmp(psz, "*") == 0) { attr_value = NULL; } else { attr_value = UtilStrDup(psz); if (attr_value == NULL) FailAllocMessage(); } *psz = '\0'; } else { attr_value = UtilStrDup(""); if (attr_value == NULL) FailAllocMessage(); } attr_name = attr_str; } else { attr_name = NULL; attr_value = UtilStrDup(attr_str); if (attr_value == NULL) FailAllocMessage(); } CleanTmpStr(); for (page_ptr=firstPage, page_num=1; page_ptr != NULL; page_ptr=page_ptr->next, page_num++) { char prefix[80]; struct ObjRec *optr=NULL; if (tg2) { sprintf(prefix, "_Page%1d", page_num); } else { sprintf(prefix, "##%1d!", page_num); } for (optr=page_ptr->top; optr != NULL; optr=optr->next) { struct AttrRec *name_attr=FindAttrWithName(optr,"name=",NULL); if (name_attr != NULL) { if (attr_name == NULL && attr_value == NULL) { if (firstPage == lastPage) { if (!AppendToTmpStr(name_attr->attr_value.s)) { ok = FALSE; break; } } else { if (!AppendToTmpStr2(prefix, name_attr->attr_value.s, tg2)) { ok = FALSE; break; } } } else { struct AttrRec *aptr=NULL; for (aptr=optr->fattr; aptr != NULL; aptr=aptr->next) { if (attr_name == NULL) { if (*aptr->attr_name.s == '\0' && strcmp(aptr->attr_value.s, attr_value) == 0) { break; } } else if (attr_value == NULL) { if (strcmp(aptr->attr_name.s, attr_name) == 0) { break; } } else { if (strcmp(aptr->attr_name.s, attr_name) == 0 && strcmp(aptr->attr_value.s, attr_value) == 0) { break; } } } if (aptr != NULL) { if (firstPage == lastPage) { if (!AppendToTmpStr(name_attr->attr_value.s)) { ok = FALSE; break; } } else { if (!AppendToTmpStr2(prefix, name_attr->attr_value.s, tg2)) { ok = FALSE; break; } } } } } } } if (ok) { int count=0; char *count_buf=(char*)malloc((strlen(result_attr_name)+40)*sizeof(char)); struct StrRec *str_ptr; if (count_buf == NULL) FailAllocMessage(); for (str_ptr=topTmpStr; str_ptr != NULL; str_ptr=str_ptr->next) { count++; } sprintf(count_buf, "%s=%d", result_attr_name, count); if (PrependToTmpStr(count_buf)) { ReplaceAttrAllValues(result_attr_owner_obj, result_attr_ptr, &topTmpStr, &botTmpStr); } free(count_buf); } CleanTmpStr(); if (attr_value != NULL) UtilFree(attr_value); return TRUE; } int ExecFindObjNamesOnAllPgs(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* find_obj_names_on_all_pages(result_attr,attr_name_value); */ { char *result_attr_name=argv[0], *attr_str=argv[1]; struct AttrRec *result_attr_ptr=NULL; struct ObjRec *result_attr_owner_obj=NULL; UtilRemoveQuotes(result_attr_name); UtilRemoveQuotes(attr_str); sprintf(execDummyStr, "%s=", result_attr_name); result_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); return FindObjNamesOnAllPgs(argv, obj_ptr, orig_cmd, FALSE); } int ExecTg2FindObjNsOnAllPgs(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* tg2_find_obj_names_on_all_pages(result_attr,attr_name_value); */ { char *result_attr_name=argv[0], *attr_str=argv[1]; struct AttrRec *result_attr_ptr=NULL; struct ObjRec *result_attr_owner_obj=NULL; UtilRemoveQuotes(result_attr_name); UtilRemoveQuotes(attr_str); sprintf(execDummyStr, "%s=", result_attr_name); result_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); return FindObjNamesOnAllPgs(argv, obj_ptr, orig_cmd, TRUE); } int ExecTokenize(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* tokenize(result_attr,string,separator); */ { char *result_attr_name=argv[0], *str=argv[1], *separator=argv[2], *psz; int ok=TRUE, just_got_sep=FALSE; struct AttrRec *result_attr_ptr; struct ObjRec *result_attr_owner_obj=NULL; UtilRemoveQuotes(result_attr_name); UtilRemoveQuotes(str); UtilRemoveQuotes(separator); sprintf(execDummyStr, "%s=", result_attr_name); result_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (strlen(separator) != 1) { sprintf(gszMsgBox, TgLoadString(STID_BAD_SEP_LONG_WHILE_EXEC_CMD), separator, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (*separator == ' ' || *separator == '"' || *separator == '\'') { sprintf(gszMsgBox, TgLoadString(STID_BAD_SEP_WHILE_EXEC_CMD), separator, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } CleanTmpStr(); psz = str; while (*psz != '\0') { char sep=(*separator), quote='\0', *start=NULL; int done=FALSE, inc=TRUE; while (*psz == ' ') psz++; start = psz; if (*psz == '\0') { if (just_got_sep) { UtilRightTrim(start); ok = AppendToTmpStr(start); just_got_sep = FALSE; } break; } if (*psz == '"' || *psz == '\'') { just_got_sep = FALSE; quote = (*psz); for (psz++; *psz != '\0' && *psz != quote; psz++) ; if (*psz == quote) { start = (&start[1]); *psz = '\0'; ok = AppendToTmpStr(start); *psz = quote; if (ok) { psz++; while (*psz == ' ') psz++; if (*psz == '\0') { done = TRUE; } else if (*psz == sep) { just_got_sep = TRUE; } else { inc = FALSE; } } } else { done = TRUE; UtilRightTrim(start); ok = AppendToTmpStr(start); } } else if (*psz == sep) { *psz = '\0'; UtilRightTrim(start); ok = AppendToTmpStr(start); *psz = sep; just_got_sep = TRUE; if (!ok) break; } else { just_got_sep = FALSE; for (psz++; *psz != '\0' && *psz != sep; psz++) ; if (*psz == '\0') { if (start != psz) { char ch=(*psz); *psz = '\0'; UtilRightTrim(start); ok = AppendToTmpStr(start); *psz = ch; } done = TRUE; } else if (*psz == sep) { *psz = '\0'; UtilRightTrim(start); ok = AppendToTmpStr(start); *psz = sep; just_got_sep = TRUE; } } if (!ok || done) break; if (inc) psz++; } if (ok && just_got_sep) { ok = AppendToTmpStr(""); } if (ok) { int count=0; char *count_buf=(char*)malloc((strlen(result_attr_name)+40)*sizeof(char)); struct StrRec *str_ptr; if (count_buf == NULL) FailAllocMessage(); for (str_ptr=topTmpStr; str_ptr != NULL; str_ptr=str_ptr->next) { count++; } sprintf(count_buf, "%s%d", result_attr_ptr->attr_name.s, count); if (PrependToTmpStr(count_buf)) { ReplaceAttrAllValues(result_attr_owner_obj, result_attr_ptr, &topTmpStr, &botTmpStr); } free(count_buf); } CleanTmpStr(); return TRUE; } int ExecMoveAttrRel(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* move_attr_relative(attr_name,dx,dy); */ { char *attr_name=argv[0]; char *dx_str=argv[1], *dy_str=argv[2]; int dx, dy; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); UtilRemoveQuotes(dx_str); UtilRemoveQuotes(dy_str); if (!IntExpression(dx_str, &dx, orig_cmd) || !IntExpression(dy_str, &dy, orig_cmd)) { return FALSE; } if (dx != 0 || dy != 0) { MoveAnAttr(attr_ptr, attr_owner_obj, dx, dy); SetFileModified(TRUE); } return TRUE; } int ExecGetNumberOfVs(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_number_of_vertices(result_attr,obj_name); */ { char *result_attr_name=argv[0], *obj_name=argv[1], buf[40]; int count=0; struct AttrRec *result_attr_ptr=NULL; struct ObjRec *result_attr_owner_obj=NULL, *owner_obj=NULL, *named_obj=NULL; UtilRemoveQuotes(result_attr_name); UtilRemoveQuotes(obj_name); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, &owner_obj, NULL); if (named_obj == NULL) return BadObjName(obj_name, orig_cmd); sprintf(execDummyStr, "%s=", result_attr_name); result_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); switch (named_obj->type) { case OBJ_POLY: count = named_obj->detail.p->n; break; case OBJ_POLYGON: count = named_obj->detail.g->n-1; break; default: sprintf(execDummyStr, TgLoadString(STID_POLY_NOR_PGON_WHILE_EXEC_CMD), obj_name, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } sprintf(buf, "%1d", count); ReplaceAttrFirstValue(result_attr_owner_obj, result_attr_ptr, buf); SetFileModified(TRUE); return TRUE; } int ExecIsObjTransformed(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* is_obj_transformed(result_attr,obj_name); */ { char *result_attr_name=argv[0], *obj_name=argv[1], buf[40]; struct AttrRec *result_attr_ptr=NULL; struct ObjRec *result_attr_owner_obj=NULL, *owner_obj=NULL, *named_obj=NULL; UtilRemoveQuotes(result_attr_name); UtilRemoveQuotes(obj_name); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, &owner_obj, NULL); if (named_obj == NULL) return BadObjName(obj_name, orig_cmd); strcpy(buf, (named_obj->ctm==NULL ? "0" : "1")); sprintf(execDummyStr, "%s=", result_attr_name); result_attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); ReplaceAttrFirstValue(result_attr_owner_obj, result_attr_ptr, buf); SetFileModified(TRUE); return TRUE; } int ExecMakeSelObjIconic(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* make_selected_obj_iconic(sym_path); */ { char *sym_path=argv[0]; UtilRemoveQuotes(sym_path); if (topSel == NULL) return BadSelectedObj(orig_cmd); if (topSel != botSel) { sprintf(execDummyStr, TgLoadString(STID_MORE_THAN_ONE_WHILE_EXEC_CMD), orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } if (*sym_path != DIR_SEP) { sprintf(execDummyStr, TgLoadString(STID_MUST_FULL_PATH_WHILE_EXEC_CMD), sym_path, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } if (!MakeIconic(sym_path, TRUE)) { return FALSE; } return TRUE; } int ExecMoveNamedObjRel(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* move_named_obj_relative(obj_name,dx,dy); */ { char *obj_name=argv[0], *dx_str=argv[1], *dy_str=argv[2]; int dx=0, dy=0; struct ObjRec *top_owner=NULL, *named_obj=NULL; UtilRemoveQuotes(obj_name); UtilTrimBlanks(obj_name); UtilRemoveQuotes(dx_str); UtilRemoveQuotes(dy_str); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, NULL, &top_owner); if (named_obj == NULL) { return BadObjName(obj_name, orig_cmd); } if (!IntExpression(dx_str, &dx, orig_cmd) || !IntExpression(dy_str, &dy, orig_cmd)) { return FALSE; } if (dx == 0 && dy == 0) { return TRUE; } /* MoveAnObj() can only be called from within an internal command */ MoveAnObj(named_obj, top_owner, dx, dy); SetFileModified(TRUE); return TRUE; } int ExecMoveNamedObjAbs(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* move_named_obj_absolute(obj_name,ltx,lty); */ { char *obj_name=argv[0], *ltx_str=argv[1], *lty_str=argv[2]; int ltx=0, lty=0; struct ObjRec *top_owner=NULL, *named_obj=NULL; UtilRemoveQuotes(obj_name); UtilTrimBlanks(obj_name); UtilRemoveQuotes(ltx_str); UtilRemoveQuotes(lty_str); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, NULL, &top_owner); if (named_obj == NULL) { return BadObjName(obj_name, orig_cmd); } if (!IntExpression(ltx_str, <x, orig_cmd) || !IntExpression(lty_str, <y, orig_cmd)) { return FALSE; } if (ltx == named_obj->obbox.ltx && lty == named_obj->obbox.lty) { return TRUE; } /* MoveAnObj() can only be called from within an internal command */ MoveAnObj(named_obj, top_owner, ltx-named_obj->obbox.ltx, lty-named_obj->obbox.lty); SetFileModified(TRUE); return TRUE; } int ExecGetTgifVersion(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_tgif_version(major_attr,minor_attr,patchlevel_attr,build_attr); */ { char *major_attr_name=argv[0], *minor_attr_name=argv[1]; char *patchlevel_attr_name=argv[2], *build_attr_name=argv[3]; char buf[40], *psz=NULL; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(major_attr_name); UtilRemoveQuotes(minor_attr_name); UtilRemoveQuotes(patchlevel_attr_name); UtilRemoveQuotes(build_attr_name); if (strcmp(major_attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", major_attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); strcpy(buf, versionString); if ((psz=strchr(buf, '.')) != NULL) { *psz = '\0'; } ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); } if (strcmp(minor_attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", minor_attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); strcpy(buf, versionString); if ((psz=strchr(buf, '.')) != NULL) { ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, ++psz); } else { ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, ""); } } if (strcmp(patchlevel_attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", patchlevel_attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); sprintf(buf, "%1d", TGIF_PATCHLEVEL); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); } if (strcmp(build_attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", build_attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, specialBuild); } return TRUE; } int ExecGetTgifDir(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_tgif_dir(attr_name); */ { char *attr_name=argv[0]; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, tgifDir); return TRUE; } int ExecGetProfileString(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* get_profile_string(attr_name,section,key,def_value,ini_path); */ { char *attr_name=argv[0], *section=argv[1], *key=argv[2], *def_value=argv[3]; char *ini_path=argv[4]; char *values=NULL; struct AttrRec *attr_ptr; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(section); UtilRemoveQuotes(key); UtilRemoveQuotes(ini_path); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (*ini_path != DIR_SEP) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_PATH_MUST_FULL), ini_path); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } values = tgGetProfileString((*section=='\0' ? NULL : section), (*key=='\0' ? NULL : key), ini_path); if (values != NULL) { if (*section == '\0' || *key == '\0') { int count=0, ok=TRUE; char *psz=NULL; char *count_buf=(char*)malloc((strlen(attr_name)+40)*sizeof(char)); if (count_buf == NULL) FailAllocMessage(); CleanTmpStr(); for (psz=values; *psz != '\0'; psz++) { if (!AppendToTmpStr(psz)) { ok = FALSE; break; } psz += strlen(psz); count++; } if (ok) { sprintf(count_buf, "%s=%d", attr_name, count); if (PrependToTmpStr(count_buf)) { ReplaceAttrAllValues(attr_owner_obj, attr_ptr, &topTmpStr, &botTmpStr); } } free(count_buf); CleanTmpStr(); } else { ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, values); } tgFreeProfileString(values); } else { ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, def_value); } return TRUE; } int ExecWriteProfileString(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* write_profile_string(section,key,value,ini_path); */ { char *section=argv[0], *key=argv[1], *value=argv[2], *ini_path=argv[3]; UtilRemoveQuotes(section); UtilRemoveQuotes(key); UtilRemoveQuotes(value); UtilRemoveQuotes(ini_path); if (inHyperSpace && !allowLaunchInHyperSpace) { XFlush(mainDisplay); XSync(mainDisplay, False); sprintf(gszMsgBox, TgLoadString(STID_WRITE_NOT_AUTO_IN_HYPER_EXEC), ini_path); if (MsgBox(gszMsgBox, TOOL_NAME, YN_MB) != MB_ID_YES) { MsgBox(TgLoadString(STID_USER_ABORT_WRITE_IN_HYPER), TOOL_NAME, INFO_MB); return FALSE; } } if (*ini_path != DIR_SEP) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_PATH_MUST_FULL), ini_path); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (tgWriteProfileString((*section=='\0' ? NULL : section), (*key=='\0' ? NULL : key), value, ini_path)) { tgWriteProfileString(NULL, NULL, NULL, ini_path); } return TRUE; } int ExecSelectAdditionalObj(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* select_additional_obj(obj_name); */ { char *obj_name=argv[0]; struct ObjRec *owner_obj=NULL, *named_obj=NULL; UtilRemoveQuotes(obj_name); UtilTrimBlanks(obj_name); named_obj = FindObjWithName(botObj, obj_ptr, obj_name, FALSE, FALSE, &owner_obj, NULL); if (named_obj == NULL) { return BadObjName(obj_name, orig_cmd); } if (owner_obj != NULL) { sprintf(execDummyStr, TgLoadString(STID_BAD_NAME_TOP_LEVEL_ONLY_CMD), obj_name, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } if (AlreadySelected(named_obj)) { sprintf(execDummyStr, TgLoadString(STID_OBJ_ALRDY_SEL_WHILE_EXEC_CMD), obj_name, orig_cmd); MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return FALSE; } AddNewSelObj(named_obj); UpdSelBBox(); return TRUE; } int ExecOpenFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* open_file(file_number,file_name,file_mode); */ { char *file_number_str=argv[0], *file_name=argv[1], *file_mode=argv[2]; int file_number=(-1); UtilRemoveQuotes(file_number_str); UtilRemoveQuotes(file_name); UtilRemoveQuotes(file_mode); UtilTrimBlanks(file_name); UtilTrimBlanks(file_mode); if (*file_name == '\0') { sprintf(gszMsgBox, TgLoadString(STID_INVALID_FNAME_WHILE_EXEC_CMD), file_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (*file_mode == '\0') { sprintf(gszMsgBox, TgLoadString(STID_INVALID_FMODE_WHILE_EXEC_CMD), file_mode, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (!IntExpression(file_number_str, &file_number, orig_cmd)) { return FALSE; } if (inHyperSpace && !allowLaunchInHyperSpace && (*file_mode == 'w' || *file_mode == 'a')) { XFlush(mainDisplay); XSync(mainDisplay, False); sprintf(gszMsgBox, TgLoadString(STID_WRITE_NOT_AUTO_IN_HYPER_EXEC), file_name); if (MsgBox(gszMsgBox, TOOL_NAME, YN_MB) != MB_ID_YES) { MsgBox(TgLoadString(STID_USER_ABORT_WRITE_IN_HYPER), TOOL_NAME, INFO_MB); return FALSE; } } if (file_number == 0) { rewind(stdin); } else if (file_number < 0 || file_number == 1 || file_number == 2 || file_number >= MAXEXECOPENFILES) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_FNUM_WHILE_EXEC_CMD), file_number_str, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (gaOpenFileInfo[file_number].fp != NULL) { sprintf(gszMsgBox, TgLoadString(STID_FNUM_ARDY_OPEN_WHILE_EXEC_CMD), file_number, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if ((gaOpenFileInfo[file_number].fp=fopen(file_name, file_mode)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_FMOD_WRITE_EXEC_CMD), file_name, file_mode, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if ((gaOpenFileInfo[file_number].fname=UtilStrDup(file_name)) == NULL) { FailAllocMessage(); } gaOpenFileInfo[file_number].eof = FALSE; return TRUE; } int ExecCloseFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* close_file(file_number); */ { char *file_number_str=argv[0]; int file_number=(-1); UtilRemoveQuotes(file_number_str); if (!IntExpression(file_number_str, &file_number, orig_cmd)) { return FALSE; } if (file_number == 0) { rewind(stdin); } else if (file_number < 0 || file_number == 1 || file_number == 2 || file_number >= MAXEXECOPENFILES) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_FNUM_WHILE_EXEC_CMD), file_number_str, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (gaOpenFileInfo[file_number].fp == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FNUM_NOT_OPEN_WHILE_EXEC_CMD), file_number, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { fclose(gaOpenFileInfo[file_number].fp); UtilFree(gaOpenFileInfo[file_number].fname); gaOpenFileInfo[file_number].fp = NULL; gaOpenFileInfo[file_number].fname = NULL; gaOpenFileInfo[file_number].eof = FALSE; } return TRUE; } int ExecReadFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* read_file(file_number,result_attr); */ { char *file_number_str=argv[0], *result_attr_name=argv[1], *buf=NULL; int file_number=(-1); struct AttrRec *result_attr=NULL; struct ObjRec *result_attr_owner_obj=NULL; UtilRemoveQuotes(file_number_str); UtilRemoveQuotes(result_attr_name); UtilTrimBlanks(result_attr_name); if (!IntExpression(file_number_str, &file_number, orig_cmd)) { return FALSE; } sprintf(execDummyStr, "%s=", result_attr_name); result_attr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr == NULL) return BadAttr(execDummyStr, orig_cmd); if (file_number < 0 || file_number == 1 || file_number == 2 || file_number >= MAXEXECOPENFILES) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_FNUM_WHILE_EXEC_CMD), file_number_str, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (gaOpenFileInfo[file_number].fp == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FNUM_NOT_OPEN_WHILE_EXEC_CMD), file_number, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (gaOpenFileInfo[file_number].eof) { sprintf(gszMsgBox, TgLoadString(STID_EOF_FOR_FNUM_WHILE_EXEC_CMD), file_number, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { buf = UtilGetALine(gaOpenFileInfo[file_number].fp); if (buf == NULL) { gaOpenFileInfo[file_number].eof = TRUE; sprintf(gszMsgBox, TgLoadString(STID_EOF_FOR_FNUM_WHILE_EXEC_CMD), file_number, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } ReplaceAttrFirstValue(result_attr_owner_obj, result_attr, (buf==NULL ? "" : buf)); if (buf != NULL) UtilFree(buf); return TRUE; } int ExecWriteFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* write_file(file_number,string); */ { char *file_number_str=argv[0], *str=argv[1]; int file_number=(-1); UtilRemoveQuotes(file_number_str); UtilRemoveQuotes(str); if (!IntExpression(file_number_str, &file_number, orig_cmd)) { return FALSE; } if (file_number < 0 || file_number >= MAXEXECOPENFILES) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_FNUM_WHILE_EXEC_CMD), file_number_str, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (gaOpenFileInfo[file_number].fp == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FNUM_NOT_OPEN_WHILE_EXEC_CMD), file_number, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (fprintf(gaOpenFileInfo[file_number].fp, "%s", str) == EOF) { if (file_number < 3) { sprintf(gszMsgBox, TgLoadString(STID_WRI_FNUM_FAIL_WHILE_EXEC_CMD), file_number, orig_cmd); } else { sprintf(gszMsgBox, TgLoadString(STID_WRI_FNN_FAIL_WHILE_EXEC_CMD), file_number, gaOpenFileInfo[file_number].fname, orig_cmd); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return TRUE; } int ExecFlushFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* flush_file(file_number); */ { char *file_number_str=argv[0]; int file_number=(-1); UtilRemoveQuotes(file_number_str); if (!IntExpression(file_number_str, &file_number, orig_cmd)) { return FALSE; } if (file_number <= 0 || file_number >= MAXEXECOPENFILES) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_FNUM_WHILE_EXEC_CMD), file_number_str, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (gaOpenFileInfo[file_number].fp == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FNUM_NOT_OPEN_WHILE_EXEC_CMD), file_number, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } fflush(gaOpenFileInfo[file_number].fp); return TRUE; } int ExecAppendFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* append_file(dest_file_name,src_file_name); */ { char *dest_file_name=argv[0], *src_file_name=argv[1]; UtilRemoveQuotes(dest_file_name); UtilRemoveQuotes(src_file_name); UtilTrimBlanks(dest_file_name); UtilTrimBlanks(src_file_name); if (!UtilPathExists(src_file_name)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PATH_WHILE_EXEC_CMD), src_file_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (UtilPathExists(dest_file_name)) { char buf[0x1000]; int fd1=(-1), fd2=(-1), failed=TRUE, bytes_read=0; if ((fd1=open(src_file_name, O_RDONLY)) != (-1) && (fd2=open(dest_file_name, O_WRONLY|O_APPEND)) != (-1)) { failed = FALSE; while ((bytes_read=read(fd1, buf, sizeof(buf))) > 0) { if (write(fd2, buf, bytes_read) != bytes_read) { failed = TRUE; break; } } } if (fd1 != (-1)) close(fd1); if (fd2 != (-1)) close(fd2); if (failed) { sprintf(gszMsgBox, TgLoadString(STID_APPEND_FAILED_WHILE_EXEC_CMD), src_file_name, dest_file_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } else if (UtilCopyFile(src_file_name, dest_file_name) != TG_REMOTE_STATUS_OK) { sprintf(gszMsgBox, TgLoadString(STID_COPY_FAILED_WHILE_EXEC_CMD), src_file_name, dest_file_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return TRUE; } /* do not translate -- program constants */ static char *gaszOutputFormats[MAXDEFWHERETOPRINT+1] = { "Printer", "EPS", "PS", "Bitmap", "Text", "EPSI", "GIF", "HTML", "PDF", "TiffEPSI", "PNG", "JPEG", "PPM", "NetList", NULL }; int ExecSetOutputFormat(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_output_format(format,color_output); */ { char *format=argv[0], *color_output_str=argv[1]; int i, color_output=(-1); UtilRemoveQuotes(format); UtilRemoveQuotes(color_output_str); UtilTrimBlanks(format); if (!IntExpression(color_output_str, &color_output, orig_cmd)) { return FALSE; } if (*format == '\0') { sprintf(gszMsgBox, TgLoadString(STID_INVALID_FORMAT_WHILE_EXEC_CMD), format, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (color_output != 0) color_output = TRUE; for (i=0; i < MAXDEFWHERETOPRINT; i++) { if (UtilStrICmp(format, gaszOutputFormats[i]) == 0) { SetWhereToPrint(i); if (color_output != colorDump) ToggleColorPostScript(); return TRUE; } } if (color_output != colorDump) ToggleColorPostScript(); for (i=MAXDEFWHERETOPRINT; i < maxWhereToPrint; i++) { if (UtilStrICmp(format, GetExportName(i, EXPORT_THIS)) == 0) { SetWhereToPrint(i); return TRUE; } } sprintf(gszMsgBox, TgLoadString(STID_INVALID_FORMAT_WHILE_EXEC_CMD), format, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } int ExecSetExportClipRect(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_export_clip_rect(ltx,lty,rbx,rby); */ { char *ltx_str=argv[0], *lty_str=argv[1], *rbx_str=argv[2], *rby_str=argv[3]; int ltx=0, lty=0, rbx=0, rby=0; UtilRemoveQuotes(ltx_str); UtilRemoveQuotes(lty_str); UtilRemoveQuotes(rbx_str); UtilRemoveQuotes(rby_str); if (!IntExpression(ltx_str, <x, orig_cmd) || !IntExpression(lty_str, <y, orig_cmd) || !IntExpression(rbx_str, &rbx, orig_cmd) || !IntExpression(rby_str, &rby, orig_cmd)) { return FALSE; } if (ltx >= rbx || lty >= rby) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_REC_WHILE_EXEC_CMD), ltx, lty, rbx, rby, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (gpExportClipBBox == NULL) { gpExportClipBBox = (struct BBRec *)malloc(sizeof(struct BBRec)); if (gpExportClipBBox == NULL) FailAllocMessage(); } gpExportClipBBox->ltx = ltx; gpExportClipBBox->lty = lty; gpExportClipBBox->rbx = rbx; gpExportClipBBox->rby = rby; return TRUE; } int ExecImportFile(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* import_file(file_name,format,ltx,lty); */ { char *file_name=argv[0], *format=argv[1], *ltx_str=argv[2], *lty_str=argv[3]; int ltx=0, lty=0, import_type=INVALID, x_hot, y_hot, w=0, h=0, ncolors=0; unsigned int ui_image_w=0, ui_image_h=0; Pixmap bitmap=None, pixmap=None; XImage *image=NULL, *bitmap_image=NULL; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL; char xpm_fname[MAXPATHLENGTH]; int chars_per_pixel=0, first_pixel_is_bg=0, *pixels=NULL; int rc=BitmapOpenFailed, image_w=0, image_h=0; struct ObjRec *new_obj_ptr=NULL; UtilRemoveQuotes(file_name); UtilRemoveQuotes(format); UtilRemoveQuotes(ltx_str); UtilRemoveQuotes(lty_str); UtilTrimBlanks(file_name); UtilTrimBlanks(format); if (*file_name == '\0') { sprintf(gszMsgBox, TgLoadString(STID_INVALID_FNAME_WHILE_EXEC_CMD), file_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (!IntExpression(ltx_str, <x, orig_cmd) || !IntExpression(lty_str, <y, orig_cmd)) { return FALSE; } if (topSel != NULL) RemoveAllSel(); if (UtilStrICmp(format, "TGIF") == 0) { int dx=0, dy=0, saved_ltx=0, saved_lty=0, saved_rbx=0, saved_rby=0; int saved_move_mode=moveMode; import_type = FILE_IMPORT; StartCompositeCmd(); importingFile = TRUE; importingFromExec = TRUE; rc = ImportGivenFile(file_name, FALSE, FALSE); importingFromExec = FALSE; importingFile = FALSE; if (rc != TRUE) { EndCompositeCmd(); sprintf(gszMsgBox, TgLoadString(STID_IMPORT_FORMAT_WHILE_EXEC_CMD), file_name, format, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (topSel == NULL) { EndCompositeCmd(); sprintf(gszMsgBox, TgLoadString(STID_NO_OBJ_TO_IMP_WHILE_EXEC_CMD), file_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } UpdSelBBox(); saved_ltx = selLtX; saved_lty = selLtY; saved_rbx = selRbX; saved_rby = selRbY; dx = ltx-selLtX; dy = lty-selLtY; moveMode = UNCONST_MOVE; MoveAllSel(dx, dy); moveMode = saved_move_mode; RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); EndCompositeCmd(); return TRUE; } if (UtilStrICmp(format, "XBM") == 0) { import_type = FILE_IMPORTXBM; rc = XReadBitmapFile(mainDisplay, mainWindow, file_name, &ui_image_w, &ui_image_h, &bitmap, &x_hot, &y_hot); image_w = ui_image_w; image_h = ui_image_h; } else if (UtilStrICmp(format, "XPM") == 0) { import_type = FILE_IMPORTXPM; rc = MyReadPixmapFile(file_name, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); } else if (UtilStrICmp(format, "GIF") == 0) { import_type = FILE_IMPORTXPM; *xpm_fname = '\0'; if (!ConvertGifToXpm(file_name, xpm_fname, sizeof(xpm_fname))) { sprintf(gszMsgBox, TgLoadString(STID_CONVERT_FORMAT_WHILE_EXEC_CMD), file_name, format, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { rc = MyReadPixmapFile(xpm_fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); unlink(xpm_fname); } } else if (UtilStrICmp(format, "PNG") == 0) { import_type = FILE_IMPORTXPM; *xpm_fname = '\0'; if (!ConvertPngToXpm(file_name, xpm_fname, sizeof(xpm_fname))) { sprintf(gszMsgBox, TgLoadString(STID_CONVERT_FORMAT_WHILE_EXEC_CMD), file_name, format, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { rc = MyReadPixmapFile(xpm_fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); unlink(xpm_fname); } } else if (UtilStrICmp(format, "JPEG") == 0) { import_type = FILE_IMPORTXPM; *xpm_fname = '\0'; if (!ConvertJpegToXpm(file_name, xpm_fname, sizeof(xpm_fname))) { sprintf(gszMsgBox, TgLoadString(STID_CONVERT_FORMAT_WHILE_EXEC_CMD), file_name, format, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { rc = MyReadPixmapFile(xpm_fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); unlink(xpm_fname); } } else if (UtilStrICmp(format, "PPM") == 0) { import_type = FILE_IMPORTXPM; *xpm_fname = '\0'; if (!ConvertPpmToXpm(file_name, xpm_fname, sizeof(xpm_fname))) { sprintf(gszMsgBox, TgLoadString(STID_CONVERT_FORMAT_WHILE_EXEC_CMD), file_name, format, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { rc = MyReadPixmapFile(xpm_fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); unlink(xpm_fname); } } else if (UtilStrICmp(format, "PGM") == 0) { import_type = FILE_IMPORTXPM; *xpm_fname = '\0'; if (!ConvertPgmToXpm(file_name, xpm_fname, sizeof(xpm_fname))) { sprintf(gszMsgBox, TgLoadString(STID_CONVERT_FORMAT_WHILE_EXEC_CMD), file_name, format, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { rc = MyReadPixmapFile(xpm_fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); unlink(xpm_fname); } } else if (UtilStrICmp(format, "PBM") == 0) { import_type = FILE_IMPORTXBM; *xpm_fname = '\0'; if (!ConvertPbmToXbm(file_name, xpm_fname, sizeof(xpm_fname))) { sprintf(gszMsgBox, TgLoadString(STID_CONVERT_TO_XBM_WHILE_EXEC_CMD), file_name, format, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { rc = XReadBitmapFile(mainDisplay, mainWindow, xpm_fname, &ui_image_w, &ui_image_h, &bitmap, &x_hot, &y_hot); image_w = ui_image_w; image_h = ui_image_h; unlink(xpm_fname); } } else { import_type = FILE_IMPORTXPM; *xpm_fname = '\0'; if (!ConvertOtherToXpm(file_name, format, xpm_fname, sizeof(xpm_fname))) { sprintf(gszMsgBox, TgLoadString(STID_CONVERT_FORMAT_WHILE_EXEC_CMD), file_name, format, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { rc = MyReadPixmapFile(xpm_fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); unlink(xpm_fname); } } importingFile = TRUE; if (rc != BitmapSuccess) { importingFile = FALSE; sprintf(gszMsgBox, TgLoadString(STID_IMPORT_FAILED_WHILE_EXEC_CMD), file_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } switch (import_type) { case FILE_IMPORTXBM: new_obj_ptr = CreateXBmObj(image_w, image_h, image_w, image_h, bitmap, image); break; case FILE_IMPORTXPM: new_obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); break; default: importingFile = FALSE; return FALSE; } importingFile = FALSE; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } MoveObj(new_obj_ptr, ltx-new_obj_ptr->obbox.ltx, lty-new_obj_ptr->obbox.lty); AddObj(NULL, topObj, new_obj_ptr); SelectTopObj(); UpdSelBBox(); RecordNewObjCmd(); RedrawAnArea(botObj, new_obj_ptr->bbox.ltx-GRID_ABS_SIZE(1), new_obj_ptr->bbox.lty-GRID_ABS_SIZE(1), new_obj_ptr->bbox.rbx+GRID_ABS_SIZE(1), new_obj_ptr->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecSetXpmOutputVersion(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_xpm_output_version(version_number); */ { char *version_number_str=argv[0]; int version_number=(-1); UtilRemoveQuotes(version_number_str); if (!IntExpression(version_number_str, &version_number, orig_cmd)) { return FALSE; } if (version_number != 1 && version_number != 3) { sprintf(gszMsgBox, TgLoadString(STID_BAD_VER_NUM_WHILE_EXEC_CMD), version_number, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } SetXpmOutputVersion(version_number); return TRUE; } int ExecEditIniSection(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* edit_ini_section(attr_name,title,section,ini_path); */ { char *attr_name=argv[0], *title=argv[1], *section=argv[2], *ini_path=argv[3]; char buf[40], *psz_keys=NULL; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(title); UtilRemoveQuotes(section); UtilRemoveQuotes(ini_path); if (strcmp(attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); } if (strcmp(title, "NULL") == 0) { title = NULL; } if ((psz_keys=tgGetProfileString(section, NULL, ini_path)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_EMPTY_INI_SEC_WHILE_EXEC_CMD), section, ini_path, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { tgFreeProfileString(psz_keys); } if (EditIniSection(title, section, ini_path, NULL)) { strcpy(buf, "OK"); } else { strcpy(buf, "CANCEL"); } if (attr_ptr != NULL) { ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, buf); } return TRUE; } int ExecSelectFromIniSection(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* select_from_ini_section(attr_name,title,section,ini_path); */ { char *attr_name=argv[0], *title=argv[1], *section=argv[2], *ini_path=argv[3]; char *psz_keys=NULL, *buf=NULL; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(title); UtilRemoveQuotes(section); UtilRemoveQuotes(ini_path); if (strcmp(attr_name, "NULL") != 0) { sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); } if (strcmp(title, "NULL") == 0) { title = NULL; } if ((psz_keys=tgGetProfileString(section, NULL, ini_path)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_EMPTY_INI_SEC_WHILE_EXEC_CMD), section, ini_path, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { tgFreeProfileString(psz_keys); } buf = SelectFromIniSection(title, section, ini_path); if (attr_ptr != NULL) { ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, (buf==NULL ? "" : buf)); } UtilFree(buf); return TRUE; } int ExecAppendLineIntoAttr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* append_line_into_attr(attr_name,str); */ { char *attr_name=argv[0], *the_str=argv[1]; MiniLineInfo *pFirstMiniLine=NULL, *pLastMiniLine=NULL; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; struct TextRec *text_ptr=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(the_str); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); PrepareToReplaceAnObj(attr_owner_obj); text_ptr = attr_ptr->obj->detail.t; CreateMiniLineFromString(the_str, &pFirstMiniLine, &pLastMiniLine); text_ptr->minilines.last->next = pFirstMiniLine; pFirstMiniLine->prev = text_ptr->minilines.last; text_ptr->minilines.last = pLastMiniLine; text_ptr->lines++; RecalcTextMetrics(text_ptr, attr_ptr->obj->x, text_ptr->baseline_y); UpdTextBBox(attr_ptr->obj); AdjObjBBox(attr_owner_obj); RecordReplaceAnObj(attr_owner_obj); RedrawAnArea(attr_ptr->obj, topObj->bbox.ltx-GRID_ABS_SIZE(1), attr_ptr->obj->bbox.lty-GRID_ABS_SIZE(1), attr_ptr->obj->bbox.rbx+GRID_ABS_SIZE(1), attr_ptr->obj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecInsertLineIntoAttr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* insert_line_into_attr(attr_name,str,line_number); */ { char *attr_name=argv[0], *the_str=argv[1]; char *line_number_str=argv[2]; int count=0, line_number=(-1), ltx=0, lty=0, rbx=0, rby=0, found=FALSE; MiniLineInfo *pMiniLine=NULL, *pFirstMiniLine=NULL, *pLastMiniLine=NULL; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; struct TextRec *text_ptr=NULL; UtilRemoveQuotes(attr_name); UtilRemoveQuotes(the_str); UtilRemoveQuotes(line_number_str); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); if (!IntExpression(line_number_str, &line_number, orig_cmd)) { return FALSE; } if (line_number <= 0) { if (line_number == 0) { sprintf(gszMsgBox, TgLoadString(STID_BAD_LINENUM_WHILE_EXEC_CMD), line_number, orig_cmd); } else { sprintf(gszMsgBox, TgLoadString(STID_BAD_SMALL_LNUM_WHILE_EXEC_CMD), line_number, orig_cmd); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ltx = attr_ptr->obj->bbox.ltx; lty = attr_ptr->obj->bbox.lty; rbx = attr_ptr->obj->bbox.rbx; rby = attr_ptr->obj->bbox.rby; PrepareToReplaceAnObj(attr_owner_obj); text_ptr = attr_ptr->obj->detail.t; count = 0; for (pMiniLine=attr_ptr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next, count++) { if (count == line_number) { CreateMiniLineFromString(the_str, &pFirstMiniLine, &pLastMiniLine); pMiniLine->prev->next = pFirstMiniLine; pFirstMiniLine->prev = pMiniLine->prev; pFirstMiniLine->next = pMiniLine; pMiniLine->prev = pFirstMiniLine; text_ptr->lines++; found = TRUE; break; } } while (!found) { if (count++ == line_number) { CreateMiniLineFromString(the_str, &pFirstMiniLine, &pLastMiniLine); text_ptr->minilines.last->next = pFirstMiniLine; pFirstMiniLine->prev = text_ptr->minilines.last; text_ptr->minilines.last = pLastMiniLine; found = TRUE; } else { CreateMiniLineFromString("", &pFirstMiniLine, &pLastMiniLine); text_ptr->minilines.last->next = pFirstMiniLine; pFirstMiniLine->prev = text_ptr->minilines.last; text_ptr->minilines.last = pLastMiniLine; pFirstMiniLine = pLastMiniLine = NULL; } text_ptr->lines++; } RecalcTextMetrics(text_ptr, attr_ptr->obj->x, text_ptr->baseline_y); UpdTextBBox(attr_ptr->obj); AdjObjBBox(attr_owner_obj); RecordReplaceAnObj(attr_owner_obj); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), attr_ptr->obj->bbox.ltx-GRID_ABS_SIZE(1), attr_ptr->obj->bbox.lty-GRID_ABS_SIZE(1), attr_ptr->obj->bbox.rbx+GRID_ABS_SIZE(1), attr_ptr->obj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecClearAttr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* clear_attr(attr_name); */ { char *attr_name=argv[0]; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; struct TextRec *text_ptr=NULL; int changed=FALSE, ltx=0, lty=0, rbx=0, rby=0; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); ltx = attr_ptr->obj->bbox.ltx; lty = attr_ptr->obj->bbox.lty; rbx = attr_ptr->obj->bbox.rbx; rby = attr_ptr->obj->bbox.rby; StartCompositeCmd(); text_ptr = attr_ptr->obj->detail.t; if (text_ptr->minilines.first->next != NULL) { MiniLineInfo *pMiniLine=NULL, *pNextMiniLine=NULL; if (attr_owner_obj == tgifObj) { AddObj(NULL, topObj, tgifObj); AddNewSelObj(topObj); } PrepareToReplaceAnObj(attr_owner_obj); for (pMiniLine=text_ptr->minilines.first->next; pMiniLine != NULL; pMiniLine=pNextMiniLine) { pNextMiniLine = pMiniLine->next; UnlinkMiniLine(pMiniLine); FreeMiniLine(pMiniLine); } if (attr_owner_obj == tgifObj) recordCmdIncludeTgifObj = TRUE; RecordReplaceAnObj(attr_owner_obj); if (attr_owner_obj == tgifObj) { recordCmdIncludeTgifObj = FALSE; UnlinkObj(topObj); FreeTopSel(); } changed = TRUE; } replaceAttrFirstValueRedraw = FALSE; if (ReplaceAttrFirstValue(attr_owner_obj, attr_ptr, "")) { changed = TRUE; } replaceAttrFirstValueRedraw = TRUE; if (changed) { RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), attr_ptr->obj->bbox.ltx-GRID_ABS_SIZE(1), attr_ptr->obj->bbox.lty-GRID_ABS_SIZE(1), attr_ptr->obj->bbox.rbx+GRID_ABS_SIZE(1), attr_ptr->obj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } EndCompositeCmd(); return TRUE; } int ExecCreateText(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* create_text_obj(abs_x,abs_baseline_y,str); */ { char *abs_x_str=argv[0], *abs_baseline_y_str=argv[1]; char *the_str=argv[2]; int abs_x=0, abs_baseline_y=0; UtilRemoveQuotes(abs_x_str); UtilRemoveQuotes(abs_baseline_y_str); UtilRemoveQuotes(the_str); if (!IntExpression(abs_x_str, &abs_x, orig_cmd) || !IntExpression(abs_baseline_y_str, &abs_baseline_y, orig_cmd)) { return FALSE; } if (*the_str == '\0') { sprintf(gszMsgBox, TgLoadString(STID_BAD_EMPTY_STR_WHILE_EXEC_CMD), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } MakeQuiescent(); NewCurText(); PrepareToReplaceAnObj(curTextObj); DynStrSet(&GetTextObjFirstStrSeg(topObj)->dyn_str, the_str); curTextModified = TRUE; CreateTextObj(TRUE, FALSE); curTextModified = FALSE; MoveObj(topObj, abs_x-topObj->x, abs_baseline_y-topObj->detail.t->baseline_y); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecCreateBox(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* create_box_obj(abs_ltx,abs_lty,abs_rbx,abs_rby); */ { char *abs_ltx_str=argv[0], *abs_lty_str=argv[1]; char *abs_rbx_str=argv[2], *abs_rby_str=argv[3]; int abs_ltx=0, abs_lty=0, abs_rbx=0, abs_rby=0; UtilRemoveQuotes(abs_ltx_str); UtilRemoveQuotes(abs_lty_str); UtilRemoveQuotes(abs_rbx_str); UtilRemoveQuotes(abs_rby_str); if (!IntExpression(abs_ltx_str, &abs_ltx, orig_cmd) || !IntExpression(abs_lty_str, &abs_lty, orig_cmd) || !IntExpression(abs_rbx_str, &abs_rbx, orig_cmd) || !IntExpression(abs_rby_str, &abs_rby, orig_cmd)) { return FALSE; } MakeQuiescent(); CreateBoxObj(abs_ltx, abs_lty, abs_rbx, abs_rby, TRUE); RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecCreateCornerOval(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* create_corner_oval_obj(abs_ltx,abs_lty,abs_rbx,abs_rby); */ { char *abs_ltx_str=argv[0], *abs_lty_str=argv[1]; char *abs_rbx_str=argv[2], *abs_rby_str=argv[3]; int abs_ltx=0, abs_lty=0, abs_rbx=0, abs_rby=0; struct BBRec obbox; UtilRemoveQuotes(abs_ltx_str); UtilRemoveQuotes(abs_lty_str); UtilRemoveQuotes(abs_rbx_str); UtilRemoveQuotes(abs_rby_str); if (!IntExpression(abs_ltx_str, &abs_ltx, orig_cmd) || !IntExpression(abs_lty_str, &abs_lty, orig_cmd) || !IntExpression(abs_rbx_str, &abs_rbx, orig_cmd) || !IntExpression(abs_rby_str, &abs_rby, orig_cmd)) { return FALSE; } MakeQuiescent(); SetBBRec(&obbox, abs_ltx, abs_lty, abs_rbx, abs_rby); CreateOvalObj(&obbox, TRUE); RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecCreateCenterOval(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* create_center_oval_obj(abs_cx,abs_cy,radius); */ { char *abs_cx_str=argv[0], *abs_cy_str=argv[1], *radius_str=argv[2]; int abs_cx=0, abs_cy=0, radius=0; struct BBRec obbox; UtilRemoveQuotes(abs_cx_str); UtilRemoveQuotes(abs_cy_str); UtilRemoveQuotes(radius_str); if (!IntExpression(abs_cx_str, &abs_cx, orig_cmd) || !IntExpression(abs_cy_str, &abs_cy, orig_cmd) || !IntExpression(radius_str, &radius, orig_cmd)) { return FALSE; } MakeQuiescent(); SetBBRec(&obbox, abs_cx-radius, abs_cy-radius, abs_cx+radius, abs_cy+radius); CreateOvalObj(&obbox, TRUE); RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecCreateEdgeOval(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* create_edge_oval_obj(abs_ltx,abs_lty,abs_rbx,abs_rby); */ { char *abs_ltx_str=argv[0], *abs_lty_str=argv[1]; char *abs_rbx_str=argv[2], *abs_rby_str=argv[3]; int abs_ltx=0, abs_lty=0, abs_rbx=0, abs_rby=0, cx=0, cy=0, w=0; double dx=(double)0, dy=(double)0, r=(double)0; struct BBRec obbox; UtilRemoveQuotes(abs_ltx_str); UtilRemoveQuotes(abs_lty_str); UtilRemoveQuotes(abs_rbx_str); UtilRemoveQuotes(abs_rby_str); if (!IntExpression(abs_ltx_str, &abs_ltx, orig_cmd) || !IntExpression(abs_lty_str, &abs_lty, orig_cmd) || !IntExpression(abs_rbx_str, &abs_rbx, orig_cmd) || !IntExpression(abs_rby_str, &abs_rby, orig_cmd)) { return FALSE; } MakeQuiescent(); cx = ((abs_rbx + abs_ltx) >> 1); cy = ((abs_rby + abs_lty) >> 1); dx = (double)(cx - abs_ltx); dy = (double)(cy - abs_lty); r = (double)sqrt(dx*dx+dy*dy); w = round(r); SetBBRec(&obbox, cx-w, cy-w, cx+w, cy+w); CreateOvalObj(&obbox, TRUE); RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecCreateRCBox(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* create_rcbox_obj(abs_ltx,abs_lty,abs_rbx,abs_rby); */ { char *abs_ltx_str=argv[0], *abs_lty_str=argv[1]; char *abs_rbx_str=argv[2], *abs_rby_str=argv[3]; int abs_ltx=0, abs_lty=0, abs_rbx=0, abs_rby=0; UtilRemoveQuotes(abs_ltx_str); UtilRemoveQuotes(abs_lty_str); UtilRemoveQuotes(abs_rbx_str); UtilRemoveQuotes(abs_rby_str); if (!IntExpression(abs_ltx_str, &abs_ltx, orig_cmd) || !IntExpression(abs_lty_str, &abs_lty, orig_cmd) || !IntExpression(abs_rbx_str, &abs_rbx, orig_cmd) || !IntExpression(abs_rby_str, &abs_rby, orig_cmd)) { return FALSE; } MakeQuiescent(); CreateRCBoxObj(abs_ltx, abs_lty, abs_rbx, abs_rby, TRUE); RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } int ExecCreateArc(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* create_arc_obj(abs_cx,abs_cy,radius,dir,theta1,theta2); */ { char *abs_cx_str=argv[0], *abs_cy_str=argv[1], *radius_str=argv[2]; char *dir_str=argv[3], *theta1_str=argv[4], *theta2_str=argv[5]; int abs_cx=0, abs_cy=0, radius=0, dir=0, x1=0, y1=0, x2=0, y2=0; double theta1=(double)0, theta2=(double)0; double angle_in_radian=(double)0, angle2=(double)0; UtilRemoveQuotes(abs_cx_str); UtilRemoveQuotes(abs_cy_str); UtilRemoveQuotes(radius_str); UtilRemoveQuotes(dir_str); UtilRemoveQuotes(theta1_str); UtilRemoveQuotes(theta2_str); if (!IntExpression(abs_cx_str, &abs_cx, orig_cmd) || !IntExpression(abs_cy_str, &abs_cy, orig_cmd) || !IntExpression(radius_str, &radius, orig_cmd) || !FloatExpression(theta1_str, &theta1, orig_cmd) || !FloatExpression(theta2_str, &theta2, orig_cmd)) { return FALSE; } UtilTrimBlanks(dir_str); switch (*dir_str) { case '+': dir = ARC_CW; break; case '-': dir = ARC_CCW; break; default: sprintf(gszMsgBox, TgLoadString(STID_BAD_DIRECTION_WHILE_EXEC_CMD), dir_str, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (radius < 1) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CREATE_ARC_WITH_RAD1), TOOL_NAME, radius); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } MakeQuiescent(); switch (dir) { case ARC_CCW: theta1 += (double)90; theta2 += (double)90; break; case ARC_CW: theta1 = -theta1+((double)90); theta2 = -theta2+((double)90); break; } angle_in_radian = theta1 * M_PI / ((double)180); x1 = round(((double)radius)*cos(angle_in_radian)); y1 = -round(((double)radius)*sin(angle_in_radian)); angle_in_radian = theta2 * M_PI / ((double)180); x2 = round(((double)radius)*cos(angle_in_radian)); y2 = -round(((double)radius)*sin(angle_in_radian)); while (theta1 < (double)0) theta1 += (double)360; while (theta2 > theta1) theta2 -= (double)360; while (theta2 < theta1) theta2 += (double)360; switch (dir) { case ARC_CCW: angle2 = theta2-theta1; if (angle2 == 0) angle2 = (double)360; break; case ARC_CW: angle2 = theta2-theta1-((double)360); break; } CreateArcObj(abs_cx, abs_cy, abs_cx+x1, abs_cy+y1, abs_cx+x2, abs_cy+y2, dir, -radius, -radius, (radius<<1), (radius<<1), round(theta1*((double)64)), round(angle2*((double)64)), TRUE); RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); return TRUE; } static IntPoint firstVertexInCreate, lastVertexInCreate; int ExecCreateFirstVertex(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* create_first_vertex(abs_x,abs_y); */ { char *abs_x_str=argv[0], *abs_y_str=argv[1]; int abs_x=0, abs_y=0; UtilRemoveQuotes(abs_x_str); UtilRemoveQuotes(abs_y_str); if (!IntExpression(abs_x_str, &abs_x, orig_cmd) || !IntExpression(abs_y_str, &abs_y, orig_cmd)) { return FALSE; } MakeQuiescent(); ResetCreatePoly(); AddPtToCreatePoly(abs_x, abs_y); firstVertexInCreate.x = abs_x; firstVertexInCreate.y = abs_y; return TRUE; } int ExecCreateNextVertex(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* create_next_vertex(abs_x,abs_y); */ { char *abs_x_str=argv[0], *abs_y_str=argv[1]; int abs_x=0, abs_y=0; UtilRemoveQuotes(abs_x_str); UtilRemoveQuotes(abs_y_str); if (!IntExpression(abs_x_str, &abs_x, orig_cmd) || !IntExpression(abs_y_str, &abs_y, orig_cmd)) { return FALSE; } if (numPtsInPoly == 0) { sprintf(gszMsgBox, TgLoadString(STID_NO_START_VRTX_WHILE_EXEC_CMD), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } AddPtToCreatePoly(abs_x, abs_y); lastVertexInCreate.x = abs_x; lastVertexInCreate.y = abs_y; return TRUE; } void ExecCreatePoly(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* create_poly_obj(); */ { if (numPtsInPoly <= 1) { sprintf(gszMsgBox, TgLoadString(STID_TOO_FEW_VRTX_WHILE_EXEC_CMD), numPtsInPoly, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ResetCreatePoly(); gnAbortExec = TRUE; return; } MakeQuiescent(); CreatePolyObj(numPtsInPoly, TRUE); RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } void ExecCreatePolygon(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* create_polygon_obj(); */ { if (numPtsInPoly <= 2) { sprintf(gszMsgBox, TgLoadString(STID_TOO_FEW_VRTX_WHILE_EXEC_CMD), numPtsInPoly, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ResetCreatePoly(); } else { MakeQuiescent(); if (firstVertexInCreate.x != lastVertexInCreate.x || firstVertexInCreate.y != lastVertexInCreate.y) { AddPtToCreatePoly(firstVertexInCreate.x, firstVertexInCreate.y); lastVertexInCreate.x = firstVertexInCreate.x; lastVertexInCreate.y = firstVertexInCreate.y; } CreatePolygonObj(numPtsInPoly, TRUE); RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } } static struct SelRec *topSelBeforeCreateGroup=NULL; static int createGroupDepth=0; static void ResetCreateGroup() { struct SelRec *next_sel=NULL; while (topSelBeforeCreateGroup != NULL) { next_sel = topSelBeforeCreateGroup->next; free(topSelBeforeCreateGroup); topSelBeforeCreateGroup = next_sel; } createGroupDepth = 0; } void ExecStartCreateGroup(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* start_create_group_obj(); */ { struct SelRec *sel_ptr=NULL; MakeQuiescent(); sel_ptr = SelectThisObject(topObj); sel_ptr->next = topSelBeforeCreateGroup; topSelBeforeCreateGroup = sel_ptr; createGroupDepth++; } void ExecCreateGroup(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* create_group_obj(); */ { struct SelRec *next_sel=NULL; struct ObjRec *optr=NULL, *start_obj=NULL; int num_objs=0; if (createGroupDepth <= 0 || topSelBeforeCreateGroup == NULL) { sprintf(gszMsgBox, TgLoadString(STID_NO_START_OBJ_WHILE_EXEC_CMD), "start_create_group_obj", orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ResetCreateGroup(); gnAbortExec = TRUE; return; } MakeQuiescent(); if (topSelBeforeCreateGroup->obj != NULL) { for (optr=topObj; optr != NULL; optr=optr->next) { if (optr == topSelBeforeCreateGroup->obj) { break; } } if (optr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_MARK_WHILE_EXEC_CMD), "start_create_group_obj", orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ResetCreateGroup(); gnAbortExec = TRUE; return; } } if (topSelBeforeCreateGroup->obj == NULL) { start_obj = botObj; } else { start_obj = topSelBeforeCreateGroup->obj->prev; } for (optr=start_obj, num_objs=0; optr != NULL; optr=optr->prev, num_objs++) { } if (num_objs == 0) { sprintf(gszMsgBox, TgLoadString(STID_NO_OBJ_GROUP_WHILE_EXEC_CMD), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ResetCreateGroup(); gnAbortExec = TRUE; return; } else if (num_objs == 1) { if (start_obj->type != OBJ_POLY && start_obj->type != OBJ_POLYGON) { sprintf(gszMsgBox, TgLoadString(STID_CANT_GRP_SNGL_WHILE_EXEC_CMD), orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ResetCreateGroup(); gnAbortExec = TRUE; return; } } for (optr=start_obj; optr != NULL; optr=optr->prev) { struct SelRec *sel_ptr=SelectThisObject(optr); sel_ptr->next = topSel; sel_ptr->prev = NULL; if (topSel == NULL) { botSel = sel_ptr; } else { topSel->prev = sel_ptr; } topSel = sel_ptr; } UpdSelBBox(); GroupSelObj(TRUE, TRUE, TRUE); RemoveAllSel(); justDupped = FALSE; next_sel = topSelBeforeCreateGroup->next; free(topSelBeforeCreateGroup); topSelBeforeCreateGroup = next_sel; createGroupDepth--; } int ExecSetAllowInterrupt(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* set_allow_interrupt(true_or_false); */ { char *allow_str=argv[0]; int currently_enabled=execInterruptEnabled; UtilRemoveQuotes(allow_str); if (strcmp(allow_str, "TRUE") == 0) { execInterruptEnabled = TRUE; } else if (strcmp(allow_str, "FALSE") == 0) { execInterruptEnabled = FALSE; } else { return BadArg("true_or_false", orig_cmd); } if (!currently_enabled && execInterruptEnabled && execInterruptQueued) { gnAbortExec = TRUE; return FALSE; } return TRUE; } static int DoExecSelectEachObjAndExec(attr_name) char *attr_name; { struct ObjRec *optr=NULL; int rc=TRUE; for (optr=botObj; rc && optr != NULL; optr=optr->prev) { struct AttrRec *attr_ptr=NULL; attr_ptr = FindAttrWithName(optr, attr_name, NULL); if (attr_ptr != NULL) { struct SelRec *sel_ptr=SelectThisObject(optr); AddSel(NULL, topSel, sel_ptr); UpdSelBBox(); if (!DoExec(attr_ptr, optr)) { rc = FALSE; } RemoveAllSel(); } } return rc; } int ExecSelectEachObjAndExec(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* select_each_obj_and_exec(attr_name_to_exec); */ { char *attr_name_to_exec=argv[0]; int rc=TRUE; UtilRemoveQuotes(attr_name_to_exec); if (topSel != NULL) { struct AttrRec *attr_ptr=NULL; sprintf(execDummyStr, "%s=", attr_name_to_exec); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, NULL); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); rc = DoExecSelectEachObjAndExec(execDummyStr); } else { char *attr_name=(char*)malloc(strlen(attr_name_to_exec)+2); if (attr_name == NULL) FailAllocMessage(); sprintf(attr_name, "%s=", attr_name_to_exec); MakeQuiescent(); StartCompositeCmd(); if (lastPageNum == 1) { rc = DoExecSelectEachObjAndExec(attr_name); } else { int saved_cur_page_num=curPageNum, prev_page_num=curPageNum; for (curPageNum=1; rc && curPageNum <= lastPageNum; curPageNum++) { if (prev_page_num != curPageNum) { PrepareToRecord(CMD_GOTO_PAGE, NULL, NULL, prev_page_num); GotoPageNum(curPageNum); ShowPage(); XSync(mainDisplay, False); RecordCmd(CMD_GOTO_PAGE, NULL, NULL, NULL, curPageNum); ClearAndRedrawDrawWindow(); prev_page_num = curPageNum; } rc = DoExecSelectEachObjAndExec(attr_name); } if (prev_page_num != curPageNum) { PrepareToRecord(CMD_GOTO_PAGE, NULL, NULL, prev_page_num); GotoPageNum(saved_cur_page_num); ShowPage(); RecordCmd(CMD_GOTO_PAGE, NULL, NULL, NULL, saved_cur_page_num); ClearAndRedrawDrawWindow(); prev_page_num = curPageNum; } } EndCompositeCmd(); UtilFree(attr_name); } return rc; } int ExecEditAttrInTextMode(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* edit_attr_in_text_mode(attr_name); */ { char *attr_name=argv[0]; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); EditTextInAttr(attr_ptr); return TRUE; } void ExecSetFileUnSavable(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* set_file_unsavable(); */ { if (!IsFiletUnSavable()) { if (!fileModified) SetFileModified(TRUE); SetUnSavableFile(TRUE); RedrawTitleWindow(); } } static void ExternalPsToEpsi(scale_val, src_file_name, dest_file_name) int scale_val; char *src_file_name, *dest_file_name; { char cmd[MAXSTRING<<1]; switch (scale_val) { case 1: snprintf(cmd, sizeof(cmd), "pstoepsi %s %s", src_file_name, dest_file_name); break; case 2: snprintf(cmd, sizeof(cmd), "pstoepsi -2x %s %s", src_file_name, dest_file_name); break; } ExecuteCmd(cmd, FALSE); } #define GS_TYPE_GNU 0 #define GS_TYPE_AFPL 1 static void FindGsVersion(gs_copyright, pn_gs_type, pn_gs_version) char *gs_copyright; int *pn_gs_type, *pn_gs_version; { char *psz_type=NULL, *psz_name=NULL, *psz_copy=UtilStrDup(gs_copyright); if (psz_copy == NULL) FailAllocMessage(); psz_type = strtok(psz_copy, " \t\r\n"); if (psz_type != NULL) { if (UtilStrICmp(psz_type, "GNU") == 0) { if (pn_gs_type != NULL) *pn_gs_type = GS_TYPE_GNU; } else if (UtilStrICmp(psz_type, "GPL") == 0) { if (pn_gs_type != NULL) *pn_gs_type = GS_TYPE_GNU; } else if (UtilStrICmp(psz_type, "AFPL") == 0) { if (pn_gs_type != NULL) *pn_gs_type = GS_TYPE_AFPL; } else if (UtilStrICmp(psz_type, "Aladdin") == 0) { if (pn_gs_type != NULL) *pn_gs_type = GS_TYPE_AFPL; } else { /* unrecognized type */ psz_type = NULL; } } if (psz_type != NULL) { psz_name = strtok(NULL, " \t\r\n"); if (UtilStrICmp(psz_name, "Ghostscript") != 0) { /* shouldn't come here */ psz_name = NULL; } } if (psz_type != NULL && psz_name != NULL) { for (;;) { char *psz=strtok(NULL, " \t\r\n"); if (psz == NULL) break; if (*psz >= '0' && *psz <= '9') { int gs_version=(-1); if (sscanf(psz, "%d", &gs_version) == 1) { if (pn_gs_version != NULL) *pn_gs_version = gs_version; break; } } } } UtilFree(psz_copy); } static int PbmToEpsi(d_scale, pbm_fname, out_fname, orig_cmd) double d_scale; char *pbm_fname, *out_fname, *orig_cmd; { char xbm_fname[MAXPATHLENGTH]; int rc=0, x_hot=0, y_hot=0, image_w=0, image_h=0; Pixmap bitmap=None; FILE *out_fp=NULL; *xbm_fname = '\0'; out_fp = fopen(out_fname, "w"); if (out_fp == NULL) { FailToOpenMessage(out_fname, "w", NULL); return FALSE; } if (!ConvertPbmToXbm(pbm_fname, xbm_fname, sizeof(xbm_fname))) { sprintf(gszMsgBox, TgLoadString(STID_CONVERT_TO_XBM_WHILE_EXEC_CMD), pbm_fname, "PBM", orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); fclose(out_fp); return FALSE; } rc = XReadBitmapFile(mainDisplay, mainWindow, xbm_fname, (unsigned int *)(&image_w), (unsigned int *)(&image_h), &bitmap, &x_hot, &y_hot); unlink(xbm_fname); if (rc == BitmapSuccess) { int watch_cursor=watchCursorOnMainWindow; XImage *image=NULL; if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } image = XGetImage(mainDisplay, bitmap, 0, 0, image_w, image_h, 1, ZPixmap); if (image == NULL) { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); } else { int row=0, col=0, llx=0, lly=0, urx=0, ury=0; int top=image_h+1, bottom=(-1), left=image_w+1, right=(-1); double dllx=(double)0, dlly=(double)0, durx=(double)0, dury=(double)0; for (row=0; row < image_h; row++) { for (col=0; col < image_w; col++) { if (XGetPixel(image, col, row)) { if (row < top) top = row; if (row > bottom) bottom = row; if (col < left) left = col; if (col > right) right = col; } } } dllx = ((double)(left))/d_scale; dlly = ((double)(image_h-bottom))/d_scale; durx = ((double)(right))/d_scale; dury = ((double)(image_h-top))/d_scale; llx = round(dllx); lly = round(dlly); urx = round(durx); ury = round(dury); #ifdef _NOT_DEFINED fprintf(stderr, "image_w = %1d\n", image_w); fprintf(stderr, "image_h = %1d\n", image_h); fprintf(stderr, "llx = %1d\n", left); fprintf(stderr, "lly = %1d\n", image_h-bottom); fprintf(stderr, "urx = %1d\n", right); fprintf(stderr, "ury = %1d\n", image_h-top); fprintf(stderr, "%%!PS-Adobe-2.0 EPSF-1.2\n"); fprintf(stderr, "%%%%BoundingBox: %d %d %d %d\n", llx, lly, urx, ury); fprintf(stderr, "%%%%BeginPreview: %d %d 1 %d\n", right-left+1, bottom-top+1, bottom-top+1); fprintf(stderr, "%%%%EndImage\n"); fprintf(stderr, "%%%%EndPreview\n"); #endif /* _NOT_DEFINED */ fprintf(out_fp, "%%!PS-Adobe-2.0 EPSF-1.2\n"); fprintf(out_fp, "%%%%BoundingBox: %d %d %d %d\n", llx, lly, urx, ury); fprintf(out_fp, "%%%%BeginPreview: %d %d 1 %d\n", right-left+1, bottom-top+1, bottom-top+1); for (row=top; row <= bottom; row++) { int even=TRUE; fprintf(out_fp, "%% "); for (col=left; col <= right; col+=4) { int nibble=0; if (XGetPixel(image, col, row)) nibble |= 0x08; if (XGetPixel(image, col+1, row)) nibble |= 0x04; if (XGetPixel(image, col+2, row)) nibble |= 0x02; if (XGetPixel(image, col+3, row)) nibble |= 0x01; fprintf(out_fp, "%x", nibble); even = !even; } fprintf(out_fp, "%s\n", (even ? "" : "0")); } fprintf(out_fp, "%%%%EndImage\n"); fprintf(out_fp, "%%%%EndPreview\n"); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } XDestroyImage(image); } } else { sprintf(gszMsgBox, TgLoadString(STID_IMPORT_FAILED_WHILE_EXEC_CMD), xbm_fname, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } if (bitmap != None) XFreePixmap(mainDisplay, bitmap); fclose(out_fp); return TRUE; } static int InternalPsToEpsi(scale, src_file_name, dest_file_name, orig_cmd) double scale; char *src_file_name, *dest_file_name, *orig_cmd; { CVList list; CVListElem *elem=NULL; char cmd[MAXSTRING<<1], *gs_copyright=NULL; char tmp_fname1[MAXPATHLENGTH], tmp_pbm_fname[MAXPATHLENGTH]; int gs_type=(-1), gs_version=(-1), ps_scale=0; double tmp_scale=(double)0; if (MkTempFile(tmp_fname1, sizeof(tmp_fname1), tmpDir, TOOL_NAME) == NULL) { return FALSE; } sprintf(tmp_pbm_fname, "%s.pbm", tmp_fname1); unlink(tmp_pbm_fname); CVListInit(&list); snprintf(cmd, sizeof(cmd), "%s -help | grep Ghostscript", gsPath); if (!ExecuteCmdGetResult(cmd, &list, 1)) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD_EXEC_CMD), cmd, orig_cmd); return FALSE; } for (elem=ListFirst(&list); elem != NULL; elem=ListNext(&list, elem)) { gs_copyright = UtilStrDup((char*)(elem->obj)); FindGsVersion(gs_copyright, &gs_type, &gs_version); break; } if (gs_type == (-1) || gs_version == (-1)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IDEN_GS), gs_copyright); Msg(gszMsgBox); } tmp_scale = ((double)72)*scale; ps_scale = round(tmp_scale); if (ps_scale < 1) ps_scale = 1; if (fabs(scale-((double)1)) < EQ_TOL) { snprintf(cmd, sizeof(cmd), "%s %s -sOutputFile=%s -- %s", gsPath, "-q -dBATCH -dNOPAUSE -sDEVICE=pbm", tmp_pbm_fname, src_file_name); } else { snprintf(cmd, sizeof(cmd), "%s %s -r%1dx%1d -sOutputFile=%s -- %s", gsPath, "-q -dBATCH -dNOPAUSE -sDEVICE=pbm", ps_scale, ps_scale, tmp_pbm_fname, src_file_name); } ExecuteCmd(cmd, FALSE); PbmToEpsi(scale, tmp_pbm_fname, tmp_fname1, orig_cmd); UtilConcatFile(tmp_fname1, src_file_name, dest_file_name); unlink(tmp_fname1); unlink(tmp_pbm_fname); /* clean up */ for (elem=ListFirst(&list); elem != NULL; elem=ListNext(&list, elem)) { UtilFree((char*)(elem->obj)); } ListUnlinkAll(&list); if (gs_copyright != NULL) UtilFree(gs_copyright); return TRUE; } static int externalPsToEpsi=INVALID; int ExecPsToEpsi(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* pstoepsi(dest_file_name,src_file_name,scale); */ { char *dest_file_name=argv[0], *src_file_name=argv[1], *scale_str=argv[2]; double scale=(double)0; UtilRemoveQuotes(dest_file_name); UtilRemoveQuotes(src_file_name); UtilTrimBlanks(dest_file_name); UtilTrimBlanks(src_file_name); if (PRTGIF && !cmdLineOpenDisplay) { sprintf(gszMsgBox, TgLoadString(STID_TOOL_NOT_INTV_WHILE_EXEC_CMD), TOOL_NAME, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (!UtilPathExists(src_file_name)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PATH_WHILE_EXEC_CMD), src_file_name, orig_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (!FloatExpression(scale_str, &scale, orig_cmd)) { return FALSE; } if (scale < ((double)0.1) || scale > ((double)10)) { sprintf(gszMsgBox, TgLoadString(STID_FUNC_ARG_STRS_RANGE), orig_cmd, "scale", "0.1", "10", scale_str); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (externalPsToEpsi == INVALID) { char *c_ptr; externalPsToEpsi = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ExternalPsToEpsi")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { externalPsToEpsi = TRUE; } } if (externalPsToEpsi) { int scale_val=round(scale); if (scale_val < 1 || scale_val > 2) { sprintf(gszMsgBox, TgLoadString(STID_FUNC_ARG_RANGE), orig_cmd, "scale", 1, 2, scale_val); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ExternalPsToEpsi(scale_val, src_file_name, dest_file_name); } else { if (!InternalPsToEpsi(scale, src_file_name, dest_file_name, orig_cmd)) { /* failed, try external one? */ } } return TRUE; } int ExecObjsBBoxIntersect(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* objs_bbox_intersect(obj1_name,obj2_name,result_attr); */ { char *obj1_name=argv[0], *obj2_name=argv[1], *result_attr_name=argv[2]; char buf[40]; struct ObjRec *named_obj1=NULL, *named_obj2=NULL; struct ObjRec *top_owner1=NULL, *top_owner2=NULL; struct ObjRec *result_attr_owner_obj=NULL; struct AttrRec *result_attr=NULL; UtilRemoveQuotes(obj1_name); UtilRemoveQuotes(obj2_name); UtilRemoveQuotes(result_attr_name); UtilTrimBlanks(obj1_name); UtilTrimBlanks(obj2_name); UtilTrimBlanks(result_attr_name); named_obj1 = FindObjWithName(botObj, obj_ptr, obj1_name, FALSE, FALSE, NULL, &top_owner1); if (named_obj1 == NULL) { return BadObjName(obj1_name, orig_cmd); } named_obj2 = FindObjWithName(botObj, obj_ptr, obj2_name, FALSE, FALSE, NULL, &top_owner2); if (named_obj2 == NULL) { return BadObjName(obj2_name, orig_cmd); } sprintf(execDummyStr, "%s=", result_attr_name); result_attr = FindAttrWithName(obj_ptr, execDummyStr, &result_attr_owner_obj); if (result_attr == NULL) return BadAttr(execDummyStr, orig_cmd); strcpy(buf, (BBoxIntersect(named_obj1->bbox, named_obj2->bbox) ? "1" : "0")); ReplaceAttrFirstValue(result_attr_owner_obj, result_attr, (buf==NULL ? "" : buf)); return TRUE; } void ExecDelAllAttrFromSelObj(obj_ptr, orig_cmd) struct ObjRec *obj_ptr; char *orig_cmd; /* delete_all_attr_from_selected_objs(); */ { struct SelRec *sel_ptr=NULL; int changed=FALSE; if (topSel == NULL) return; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { if (sel_ptr->obj->fattr != NULL) { changed = TRUE; PrepareToReplaceAnObj(sel_ptr->obj); DelAllAttrs(sel_ptr->obj->fattr); sel_ptr->obj->fattr = sel_ptr->obj->lattr = NULL; AdjObjBBox(sel_ptr->obj); RecordReplaceAnObj(sel_ptr->obj); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); UpdSelBBox(); justDupped = FALSE; } HighLightForward(); } typedef struct tagRandomPermutationInfo { int num_states; unsigned int *iv; unsigned int *state; } RandomPermutationInfo; static void Swap(psz, i, j) unsigned int *psz; int i, j; { unsigned int t=psz[i]; psz[i] = psz[j]; psz[j] = t; } static void RandomPermutation(prpi, num_states) RandomPermutationInfo *prpi; int num_states; { int i=0, j=0; time_t tloc; memset(prpi, 0, sizeof(RandomPermutationInfo)); prpi->num_states = num_states; prpi->iv = (unsigned int *)malloc(num_states*sizeof(unsigned int)); prpi->state = (unsigned int *)malloc(num_states*sizeof(unsigned int)); if (prpi->iv == NULL || prpi->state == NULL) FailAllocMessage(); memset(prpi->iv, 0, num_states*sizeof(unsigned int)); memset(prpi->state, 0, num_states*sizeof(unsigned int)); for (i=0; i < num_states; i++) prpi->state[i] = i; time(&tloc); #ifndef _NO_RAND48 srand48((long)tloc); for (i=0; i < num_states; i++) { double dval=drand48(); int ival=0; if (num_states > 256) { ival = (unsigned int)(dval*((double)num_states)); if (ival >= num_states) ival = num_states - 1; if (ival < 0) ival = 0; } else { ival = (unsigned int)(dval*((double)256)); if (ival >= 256) ival = 255; if (ival < 0) ival = 0; } prpi->iv[i] = (unsigned int)ival; } #else /* _NO_RAND48 */ srand((unsigned int)tloc); for (i=0; i < num_states; i++) { unsigned int uival=(rand() & 0x0ffff); uival *= 60013; if (num_states > 256) { uival = uival % num_states; } else { uival = (uival & 0x0ff); } prpi->iv[i] = uival; } #endif /* ~_NO_RAND48 */ for (i=0, j=0; i < num_states; i++) { j = j + (int)(prpi->state[i]) + (int)(prpi->iv[i]); j = j % num_states; Swap(prpi->state, i, j); } } int ExecRndPermLinesInAttr(argv, obj_ptr, orig_cmd) char **argv, *orig_cmd; struct ObjRec *obj_ptr; /* random_permute_lines_in_attr(attr); */ { char *attr_name=argv[0], *tmp_buf=NULL, **word_array=NULL; int i=0, count=0, index=0, need_to_free_tmp_buf=FALSE; MiniLinesInfo *minilines=NULL; MiniLineInfo *pMiniLine=NULL; struct AttrRec *attr_ptr=NULL; struct ObjRec *attr_owner_obj=NULL; RandomPermutationInfo rpi; UtilRemoveQuotes(attr_name); sprintf(execDummyStr, "%s=", attr_name); attr_ptr = FindAttrWithName(obj_ptr, execDummyStr, &attr_owner_obj); if (attr_ptr == NULL) return BadAttr(execDummyStr, orig_cmd); count = 0; for (pMiniLine=attr_ptr->obj->detail.t->minilines.first->next; pMiniLine != NULL; pMiniLine=pMiniLine->next) { count++; } if (count <= 0) return TRUE; word_array = (char**)malloc(count*sizeof(char*)); if (word_array == NULL) FailAllocMessage(); memset(word_array, 0, count*sizeof(char*)); for (pMiniLine=attr_ptr->obj->detail.t->minilines.first->next; pMiniLine != NULL; pMiniLine=pMiniLine->next, index++) { need_to_free_tmp_buf = FALSE; tmp_buf = NULL; if (pMiniLine == attr_ptr->obj->detail.t->minilines.first) { char *attr_value=NULL; tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); attr_value = UtilStrDup(tmp_buf); if (attr_value == NULL) FailAllocMessage(); ParseAttrStr(tmp_buf, NULL, 0, attr_value, strlen(attr_value)+1); if (need_to_free_tmp_buf) UtilFree(tmp_buf); word_array[index] = UtilStrDup(attr_value); UtilFree(attr_value); } else { tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); word_array[index] = UtilStrDup(tmp_buf); if (need_to_free_tmp_buf) UtilFree(tmp_buf); } if (word_array[index] == NULL) FailAllocMessage(); } memset(&rpi, 0, sizeof(RandomPermutationInfo)); RandomPermutation(&rpi, count); CleanTmpStr(); need_to_free_tmp_buf = FALSE; tmp_buf = NULL; minilines = (&attr_ptr->obj->detail.t->minilines); tmp_buf = ConvertAttrNameFirstMiniLineToString(attr_ptr, &need_to_free_tmp_buf); if (!AppendToTmpStr(tmp_buf)) FailAllocMessage(); if (need_to_free_tmp_buf) UtilFree(tmp_buf); for (i=0; i < count; i++) { AppendToTmpStr(word_array[rpi.state[i]]); } ReplaceAttrAllValues(attr_owner_obj, attr_ptr, &topTmpStr, &botTmpStr); CleanTmpStr(); return TRUE; } /* --------------------- End of Exec Routines --------------------- */ static char *ExecFreeArgv(need_raw_argv, argc, p_argv, p_raw_argv) int need_raw_argv, argc; char ***p_argv, ***p_raw_argv; { register int i; for (i=0; i < argc; i++) { if ((*p_argv)[i] == NULL) break; free((*p_argv)[i]); } if (*p_argv != NULL) free(*p_argv); if (need_raw_argv) { for (i=0; i < argc; i++) { if ((*p_raw_argv)[i] == NULL) break; free((*p_raw_argv)[i]); } if (*p_raw_argv != NULL) free(*p_raw_argv); } return NULL; } static void ShowExecStatus(need_raw_argv, argc, argv, raw_argv, func_name) int need_raw_argv, argc; char **argv, **raw_argv, *func_name; { register int i, index; sprintf(execDummyStr, "EXEC: %s", func_name); index = strlen(execDummyStr); for (i=0; index < sizeof(execDummyStr)-7 && i < argc; i++) { int len=strlen(need_raw_argv ? raw_argv[i] : argv[i]); if (index+len+1 >= sizeof(execDummyStr)-7) { break; } if (i == 0) { execDummyStr[index++] = '('; } else { execDummyStr[index++] = ','; } strcpy(&execDummyStr[index], need_raw_argv ? raw_argv[i] : argv[i]); index += len; } if (i == argc) { if (argc == 0) execDummyStr[index++] = '('; execDummyStr[index++] = ')'; execDummyStr[index] = '\0'; } else { strcpy(&execDummyStr[index], ",...)"); } SetStringStatus(execDummyStr); if (mainDisplay != NULL) XSync(mainDisplay, False); } static char *ExecuteACommand(cmd_ptr, obj_ptr) char * cmd_ptr; struct ObjRec * obj_ptr; { ExecInfo *pei=NULL; int i, tok_type, rc=TRUE, func_argc=0, need_raw_argv=FALSE; char buf[MAXSTRING<<2], **argv=NULL, **raw_argv=NULL; char *c_ptr=GetToken(cmd_ptr, buf, sizeof(buf), &tok_type); if (c_ptr == NULL) return NULL; if (*c_ptr == '\0') return c_ptr; for (pei=gExecInfo; pei->pfunc != NULL; pei++) { if (strcmp(pei->func_name, buf) == 0) { break; } } if (cmdLineTgrm2) { if (pei->pfunc == NULL) { pei = Tangram2GetExecInfo(buf); } } if (pei == NULL || pei->pfunc == NULL) { int len=strlen(buf); if (len > 0 && buf[len-1] == ' ') { sprintf(execDummyStr, TgLoadString(STID_UNRECOG_CMD_MAY_BE_BLANKS_ABT), buf); } else { sprintf(execDummyStr, TgLoadString(STID_UNRECOG_CMD_DOWNLOAD_TOOL), buf, TOOL_NAME, currentReleaseURL); } MsgBox(execDummyStr, TOOL_NAME, INFO_MB); return NULL; } func_argc = pei->func_argc; if (func_argc < 0) { func_argc = (-func_argc); need_raw_argv = TRUE; } if (func_argc > 0) { if (need_raw_argv) { raw_argv = (char**)malloc(func_argc*sizeof(char*)); if (raw_argv == NULL) return (char*)(long)FailAllocMessage(); for (i=0; i < func_argc; i++) raw_argv[i] = NULL; } argv = (char**)malloc(func_argc*sizeof(char*)); if (argv == NULL) return (char*)(long)FailAllocMessage(); for (i=0; i < func_argc; i++) argv[i] = NULL; } for (i=0; i < func_argc; i++) { if ((c_ptr=GetToken(c_ptr, buf, sizeof(buf), &tok_type)) == NULL || tok_type == TOK_EMPTY) { BadCmd(pei->func_name); return ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); } if (i == 0) { if (tok_type != TOK_LEFT_P) { BadCmd(pei->func_name); return ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); } } else { if (tok_type != TOK_COMMA) { BadCmd(pei->func_name); return ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); } } if ((c_ptr=GetToken(c_ptr, buf, sizeof(buf), &tok_type)) == NULL || tok_type == TOK_EMPTY) { BadCmd(pei->func_name); return ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); } if (tok_type != TOK_STR) { BadCmd(pei->func_name); return ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); } if (need_raw_argv) { raw_argv[i] = UtilStrDup(buf); if (raw_argv[i] == NULL) { FailAllocMessage(); return ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); } } argv[i] = convert_str(buf, obj_ptr, pei->double_quotes_for_null); if (argv[i] == NULL) { BadAttr(buf, pei->func_name); return ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); } } if (func_argc == 0) { if ((c_ptr=GetToken(c_ptr, buf, sizeof(buf), &tok_type)) == NULL || tok_type == TOK_EMPTY) { BadCmd(pei->func_name); return ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); } if (tok_type != TOK_LEFT_P) { BadCmd(pei->func_name); return ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); } } if ((c_ptr=GetToken(c_ptr, buf, sizeof(buf), &tok_type)) == NULL || tok_type == TOK_EMPTY) { BadCmd(pei->func_name); return ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); } if (tok_type != TOK_RIGHT_P) { BadCmd(pei->func_name); return ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); } ShowExecStatus(need_raw_argv, func_argc, argv, raw_argv, pei->func_name); if (func_argc > 0) { if (need_raw_argv) { rc = ((RawExecFunc*)(pei->pfunc))(argv, raw_argv, obj_ptr, pei->func_name); } else { rc = ((ExecFunc*)(pei->pfunc))(argv, obj_ptr, pei->func_name); } } else if (func_argc == 0) { gnAbortExec = FALSE; ((SimpleExecFunc*)(pei->pfunc))(obj_ptr, pei->func_name); if (gnAbortExec) rc = FALSE; } ExecFreeArgv(need_raw_argv, func_argc, &argv, &raw_argv); return (rc ? c_ptr : NULL); } static int ExecuteCommands(cmd, obj_ptr) char *cmd; struct ObjRec *obj_ptr; { int tok_type=TOK_INVALID, rc=TRUE; char *cmd_ptr=cmd; while (rc && *cmd_ptr != '\0') { gnSeenLeftParan = FALSE; if ((cmd_ptr=ExecuteACommand(cmd_ptr, obj_ptr)) == NULL) { rc = FALSE; } else if (*cmd_ptr != '\0') { char buf[MAXSTRING<<2]; if (execNavigateBack) { break; } else if (warpToAttr != NULL) { break; } else if (OnlyBlanksLeft(cmd_ptr)) { break; } else if ((cmd_ptr=GetToken(cmd_ptr, buf, sizeof(buf), &tok_type)) == NULL) { rc = FALSE; } else if (tok_type != TOK_SEMI) { MsgBox(TgLoadString(STID_UNRECOG_CMD_ABORT), TOOL_NAME, INFO_MB); rc = FALSE; } } if (rc && CheckExecInterrupt(NULL)) { Msg(TgLoadString(STID_USER_INTR)); rc = FALSE; userAbortExec = TRUE; } } return rc; } static int CommentLine(buf) char *buf; { while (*buf == ' ') buf++; return (buf[0] == '/' && buf[1] == '/'); } int DoExec(exec_attr, obj_ptr) struct AttrRec *exec_attr; struct ObjRec *obj_ptr; { char *c_ptr, *cmd, *cmd_ptr; int cur_size=2*MAXSTRING, count=0, cmd_len=0, n; int first_time=TRUE, rc=TRUE; MiniLineInfo *pMiniLine=NULL; executingCommands = TRUE; escPressedWhileExecutingCommands = FALSE; cmd = (char*)malloc((cur_size+4)*sizeof(char)); if (cmd == NULL) FailAllocMessage(); cmd_ptr = cmd; for (pMiniLine=exec_attr->obj->detail.t->minilines.first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { int need_to_free_tmp_buf=FALSE; char *tmp_buf=NULL; if (first_time) { char *attr_value=NULL; first_time = FALSE; tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); attr_value = UtilStrDup(tmp_buf); if (attr_value == NULL) FailAllocMessage(); ParseAttrStr(tmp_buf, NULL, 0, attr_value, strlen(attr_value)+1); if (need_to_free_tmp_buf) UtilFree(tmp_buf); need_to_free_tmp_buf = TRUE; c_ptr = tmp_buf = attr_value; } else { tmp_buf = ConvertMiniLineToString(pMiniLine, &need_to_free_tmp_buf); c_ptr = tmp_buf; } if (CommentLine(tmp_buf)) { } else if ((count=strlen(c_ptr)) != 0) { if (count+cmd_len >= cur_size) { n = cmd_ptr-cmd; cur_size += count+MAXSTRING; cmd = (char*)realloc(cmd, (cur_size+4)*sizeof(char)); cmd_ptr = &cmd[n]; } strncpy(cmd_ptr, c_ptr, count); cmd_ptr[count] = '\0'; cmd_ptr += count; cmd_len += count; if (pMiniLine->next != NULL) { *cmd_ptr++ = ' '; *cmd_ptr = '\0'; cmd_len++; } } if (need_to_free_tmp_buf) UtilFree(tmp_buf); } *cmd_ptr = '\0'; justDupped = FALSE; execCurDepth++; StartCompositeCmd(); rc = ExecuteCommands(cmd, obj_ptr); EndCompositeCmd(); execCurDepth--; justDupped = FALSE; free(cmd); return rc; } void ResetExec(nBegin) int nBegin; { static int sSavedXpmOutputVersion=(-1); static struct BBRec sTrimBBox; int i; executingCommands = FALSE; escPressedWhileExecutingCommands = FALSE; for (i=3; i < MAXEXECOPENFILES; i++) { if (gaOpenFileInfo[i].fp != NULL) { fclose(gaOpenFileInfo[i].fp); UtilFree(gaOpenFileInfo[i].fname); } } memset(gaOpenFileInfo, 0, MAXEXECOPENFILES*sizeof(struct OpenFileRec)); gaOpenFileInfo[0].fp = stdin; gaOpenFileInfo[1].fp = stdout; gaOpenFileInfo[2].fp = stderr; rewind(stdin); if (gpExportClipBBox != NULL) { free(gpExportClipBBox); gpExportClipBBox = NULL; } if (nBegin) { userAbortExec = FALSE; execInterruptEnabled = TRUE; execInterruptQueued = FALSE; sSavedXpmOutputVersion = GetXpmOutputVersion(); sTrimBBox.ltx = leftExportPixelTrim; sTrimBBox.lty = topExportPixelTrim; sTrimBBox.rbx = rightExportPixelTrim; sTrimBBox.rby = bottomExportPixelTrim; leftExportPixelTrim = topExportPixelTrim = rightExportPixelTrim = bottomExportPixelTrim = 0; } else { SetXpmOutputVersion(sSavedXpmOutputVersion); leftExportPixelTrim = sTrimBBox.ltx; topExportPixelTrim = sTrimBBox.lty; rightExportPixelTrim = sTrimBBox.rbx; bottomExportPixelTrim = sTrimBBox.rby; } ResetCreatePoly(); ResetCreateGroup(); } static char *ReadACmdFromFile(fp, is_named_pipe, pn_quit) FILE *fp; int is_named_pipe, *pn_quit; { char *buf=NULL; while (WaitForEvent(fp, FALSE, is_named_pipe, pn_quit, DO_ALL_X_EV, NULL, NULL) && (buf=UtilGetALine(fp)) != NULL) { int len=0; UtilTrimBlanks(buf); if (*buf == '\0') { UtilFree(buf); continue; } else if (strcmp(buf, ".\n") == 0) { UtilFree(buf); return NULL; } if (buf[0] == '/' && buf[1] == '/') { /* lines that start with "//" are comments */ UtilFree(buf); continue; } len = strlen(buf); if (len > 0 && buf[len-1] == '\\') { char *buf1=NULL; int done=FALSE; buf[len-1] = ' '; while (!done && WaitForEvent(fp, FALSE, is_named_pipe, pn_quit, DO_ALL_X_EV, NULL, NULL) && (buf1=UtilGetALine(fp)) != NULL) { int len1=0; UtilTrimBlanks(buf1); len1 = strlen(buf1); if (len1 > 0 && buf1[len1-1] == '\\') { buf1[len1-1] = ' '; } else { done = TRUE; } buf = (char*)realloc(buf, len+len1+1); if (buf == NULL) FailAllocMessage(); strcpy(&buf[len], buf1); len += len1; UtilFree(buf1); } } break; } if (buf == NULL && fp == stdin) { printf("\n"); } return buf; } static void DoExecCmdsFromFile(fp, is_named_pipe, pn_quit) FILE *fp; int is_named_pipe, *pn_quit; { char prompt[MAXSTRING]; if (fp == stdin) rewind(stdin); XSync(mainDisplay, False); executingCommands = TRUE; escPressedWhileExecutingCommands = FALSE; justDupped = FALSE; execCurDepth++; sprintf(prompt, "(%s) ", TOOL_NAME); UtilStrLower(prompt); while (!gnQuit && !gnStopCmdExecuted) { char *buf=NULL; int exec_rc=INVALID; if (fp == stdin) { printf("%s", prompt); fflush(stdout); } buf = ReadACmdFromFile(fp, is_named_pipe, pn_quit); if (buf == NULL) { if (fp == stdin) rewind(stdin); break; } if (fp == stdin || is_named_pipe) { gnDisableShortcuts = FALSE; } warpToAttr = NULL; exec_rc = ExecuteCommands(buf, NULL); if (exec_rc == TRUE && warpToAttr != NULL) { struct AttrRec *exec_attr=NULL; DoTeleport(warpToAttr); if ((exec_attr=FindFileAttrWithName("auto_exec=")) != NULL) { DoExecLoop(NULL, exec_attr); } } if (fp == stdin || is_named_pipe) { XSync(mainDisplay, False); gnDisableShortcuts = TRUE; } UtilFree(buf); } if (gnQuit) *pn_quit = TRUE; execCurDepth--; justDupped = FALSE; } void ExecCmdsFromFile(buf) char *buf; { static int stnExecutingCmdsFromFile=FALSE; FILE *fp=NULL; char spec[MAXSTRING<<1], fname[MAXPATHLENGTH]; int quit=FALSE, is_named_pipe=FALSE; *fname = '\0'; gnStopCmdExecuted = FALSE; if (stnExecutingCmdsFromFile) { /* do not translate -- program constants */ sprintf(gszMsgBox, TgLoadString(STID_TOOL_NOT_DONE_WITH_PREV_FUNC), TOOL_NAME, "ExecCmdsFromFile()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } *spec = '\0'; if (buf != NULL && strcmp(buf, "-1") != 0) { int len=0; UtilStrCpyN(spec, sizeof(spec), buf); UtilTrimBlanks(spec); len = strlen(spec); if (len > 0 && spec[len-1] == ')') spec[len-1] = '\0'; } else { sprintf(gszMsgBox, TgLoadString(STID_ENTER_INTERN_CMD_FILE_NAME), TOOL_NAME); *spec = '\0'; if (Dialog(gszMsgBox, NULL, spec) == INVALID) { return; } } UtilTrimBlanks(spec); if (strcmp(spec, "-") != 0) { struct stat stat_buf; if (*spec == DIR_SEP) { strcpy(fname, spec); } else { sprintf(fname, "%s%c%s", bootDir, DIR_SEP, spec); } if (stat(fname, &stat_buf) != 0) { int show_msg=TRUE; #ifndef _NO_LSTAT if (lstat(fname, &stat_buf) == 0 && ((stat_buf.st_mode & S_IFLNK) == S_IFLNK)) { show_msg = FALSE; } #endif /* _NO_LSTAT */ if (show_msg) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_STAT_GIVEN_FILE), fname); Msg(gszMsgBox); /* ummm... continue below anyway */ } #ifdef S_IFIFO } else if ((stat_buf.st_mode & S_IFIFO) == S_IFIFO) { is_named_pipe = TRUE; #endif /* S_IFIFO */ } if ((fp=fopen(fname, (is_named_pipe ? "r+" : "r"))) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } else { fp = stdin; } MakeQuiescent(); stnExecutingCmdsFromFile = TRUE; if (fp == stdin || is_named_pipe) { gnDisableShortcuts = TRUE; RedrawDummyWindow2(); } ResetExec(TRUE); if (fp == stdin) { DoExecCmdsFromFile(fp, FALSE, &quit); fprintf(stdin, "%s\n", TgLoadString(STID_FINISH_EXEC_CMD_FROM_STDIN)); } else if (is_named_pipe) { for (;;) { DoExecCmdsFromFile(fp, TRUE, &quit); if (quit || gnStopCmdExecuted) break; fclose(fp); if ((fp=fopen(fname, "r+")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; } } if (fp != NULL) fclose(fp); } else { DoExecCmdsFromFile(fp, FALSE, &quit); fclose(fp); } if (fp == stdin || is_named_pipe) { gnDisableShortcuts = FALSE; RedrawDummyWindow2(); } stnExecutingCmdsFromFile = FALSE; if (quit) { SendCommandToSelf(CMDID_QUIT, 0); } } void ExecCmdsFromTmp(tmp_fname) char *tmp_fname; { static int stnExecutingCmdsFromTmp=FALSE; FILE *fp=NULL; int quit=FALSE; gnStopCmdExecuted = FALSE; if (stnExecutingCmdsFromTmp) { /* do not translate -- program constants */ sprintf(gszMsgBox, TgLoadString(STID_TOOL_NOT_DONE_WITH_PREV_FUNC), TOOL_NAME, "ExecCmdsFromTmp()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if ((fp=fopen(tmp_fname, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } stnExecutingCmdsFromTmp = TRUE; ResetExec(TRUE); DoExecCmdsFromFile(fp, FALSE, &quit); fclose(fp); stnExecutingCmdsFromTmp = FALSE; if (quit) { SendCommandToSelf(CMDID_QUIT, 0); } } void StartExecCmdsFromFile() { if (*cmdLineFileToExec == '\0') return; ExecCmdsFromFile(cmdLineFileToExec); } int BeginExecCommandsFromBuffer() { ResetExec(TRUE); executingCommands = TRUE; escPressedWhileExecutingCommands = FALSE; justDupped = FALSE; execCurDepth++; return TRUE; } int ExecACommandFromBuffer(buf, pn_quit) char *buf; int *pn_quit; { int exec_rc=INVALID; warpToAttr = NULL; exec_rc = ExecuteCommands(buf, NULL); if (exec_rc == TRUE && warpToAttr != NULL) { struct AttrRec *exec_attr=NULL; DoTeleport(warpToAttr); if ((exec_attr=FindFileAttrWithName("auto_exec=")) != NULL) { DoExecLoop(NULL, exec_attr); } } if (gnQuit) { if (pn_quit != NULL) *pn_quit = TRUE; execCurDepth--; justDupped = FALSE; SendCommandToSelf(CMDID_QUIT, 0); return FALSE; } return TRUE; } void EndExecCommandsFromBuffer() { execCurDepth--; justDupped = FALSE; ShowCurChoiceMouseStatus(curChoice, 0, FALSE); } void CleanUpExec() { if (gpExportClipBBox != NULL) { free(gpExportClipBBox); gpExportClipBBox = NULL; } if (cmdToExecAfterHyperJump != NULL) { free(cmdToExecAfterHyperJump); cmdToExecAfterHyperJump = NULL; } } static char defGsPath[]="gs"; void InitExec() { char *c_ptr=NULL; gpExportClipBBox = NULL; executingCommands = FALSE; escPressedWhileExecutingCommands = FALSE; memset(gaOpenFileInfo, 0, MAXEXECOPENFILES*sizeof(struct OpenFileRec)); cmdToExecAfterHyperJump = NULL; UtilStrCpyN(gsPath, sizeof(gsPath), defGsPath); if (!PRTGIF || cmdLineOpenDisplay) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"GsPath")) != NULL) { if (!FindProgramInPath(c_ptr, NULL, TRUE)) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_INVALID_FILE_IN_X_DEFAULT), c_ptr, TOOL_NAME, "GsPath"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { UtilStrCpyN(gsPath, sizeof(gsPath), c_ptr); } } } } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/remote.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000006555�11602233312�014440� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/remote.e,v 1.6 2011/05/16 16:21:59 william Exp $ */ #ifndef _TGIF_REMOTE_E_ #define _TGIF_REMOTE_E_ extern int postingCGIQuery; extern int gettingHttpHeaderOnly; extern char *fnameForPostingCGIQuery; extern char gszLocalPID[]; extern char gzipCmd[]; extern char gunzipCmd[]; #ifdef _INCLUDE_FROM_REMOTE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_REMOTE_C_*/ extern void CleanUpDownloadStats ARGS_DECL((void)); extern int UpdateDownloadStats ARGS_DECL((int bytes, char *psz_buf)); extern int GetClientID ARGS_DECL((char *psz_buf, int buf_sz)); extern void GetUserAgent ARGS_DECL((char *buf, int buf_sz)); extern void SetUserAgent ARGS_DECL((char*)); extern int GetUserID ARGS_DECL((char *psz_buf, int buf_sz)); extern int UserAbortComm ARGS_DECL((void)); extern int OtherAbortComm ARGS_DECL((void)); extern int GetPageNumFromPageSpec ARGS_DECL((char *psz_spec, int *pn_page_num)); extern void FreeRemoteBuf ARGS_DECL((char*)); extern int DirIsRemote ARGS_DECL((char*)); extern int FileIsRemote ARGS_DECL((char*)); extern int UrlIsHtml ARGS_DECL((char*)); extern int FormRemoteName ARGS_DECL((char *psz_file, char *psz_def_ext, char *psz_return)); extern int FormNewFileName ARGS_DECL((char *psz_dir, char *psz_file, char *psz_def_ext, char *psz_return, char **ppsz_page_spec)); extern void ShowRemoteStatus ARGS_DECL((char*)); extern int LoadRemoteFileInMem ARGS_DECL((char *url, char **ppsz_buf, char **ppsz_content_type, int *pn_buf_sz, int *pn_html, int force_load, char *psz_final, int cb_final)); extern char *WriteRemoteFileIntoTemp ARGS_DECL((char *psz_buf, int buf_sz, char *psz_ext)); extern int UseExternalViewer ARGS_DECL((int is_html, char *psz_url, char *psz_content_type, char *tmp_fname)); extern int LoadRemoteFileFromMem ARGS_DECL((char *psz_url, char *psz_buf, char *psz_content_type, int buf_sz, int is_html)); extern void InitLocalPID ARGS_DECL((void)); extern void InitRemote ARGS_DECL((void)); extern void CleanUpRemote ARGS_DECL((void)); #ifdef _INCLUDE_FROM_REMOTE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_REMOTE_C_*/ #endif /*_TGIF_REMOTE_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/http.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000126323�11602233311�014115� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Some code in this file is derived from the public domain code in * WWW/Library/Implementation/HTTP.c distributed with lynx-2.2, * whose original author is Tim Berners-lee <timbl@info.cern.ch>. * * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/http.c,v 1.11 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_HTTP_C_ #include "tgifdefs.h" #include "dialog.e" #include "drawing.e" #include "file.e" #include "http.e" #include "mainloop.e" #include "msg.e" #include "remote.e" #include "setup.e" #include "stream.e" #include "strtbl.e" #include "tcp.e" #include "util.e" #include "version.e" int debugHttp=0; int gnHttpKeepAlive=FALSE; char *gpszFakedReferer=NULL; typedef struct TgifHttpLineInfo { char *name; char *value; struct TgifHttpLineInfo *next; } *TgifHttpLinePtr; typedef struct TgifHttpHeaderInfo { char *version; int resp_code; char *resp_status; char *last_modified; char *server; char *connection; char *location; char *www_authenticate; char *content_encoding; char *content_type; long content_length; struct TgifHttpLineInfo *misc; } *TgifHttpHeaderPtr; typedef struct AuthInfo { char *host; int port; char *scheme; /* e.g., Basic */ char *realm; /* e.g., WallyWorld */ char *authorization; /* base64 encoded */ struct AuthInfo *next, *prev; } *AuthInfoPtr; static struct AuthInfo *topAuthInfo=NULL, *botAuthInfo=NULL; static struct AuthInfo curAuthorization; static struct TgifHttpHeaderInfo tgifHttpHeaderInfo; static char SZ_HTTP_VERSION[]="HTTP/1.0"; static char SZ_USER_AGENT[128]; static char SZ_USER_NAME[128]; typedef struct tagRefererInfo { char *referer; struct tagRefererInfo *next; } RefererInfo; static RefererInfo *topReferer=NULL; void HttpFreeBuf(buf) char *buf; { free(buf); } void HttpDebug(val) int val; { debugHttp = val; } static void CleanUpAuthInfo() { struct AuthInfo *next_pai; for ( ; topAuthInfo != NULL; topAuthInfo=next_pai) { next_pai = topAuthInfo->next; if (topAuthInfo->host != NULL) free(topAuthInfo->host); if (topAuthInfo->scheme != NULL) free(topAuthInfo->scheme); if (topAuthInfo->realm != NULL) free(topAuthInfo->realm); if (topAuthInfo->authorization != NULL) free(topAuthInfo->authorization); free(topAuthInfo); } botAuthInfo = NULL; } /* do not translate -- program constants */ static char gszEncode[] = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; static int gnDecode[] = { -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 62, -1, -1, -1, 63, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, -1, -1, -1, -1, -1, -1, -1, 0, 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, -1, -1, -1, -1, -1, -1, 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, -1, -1, -1, -1, -1 }; void DoBase64Encode(buf_in, buf_len, return_buf_in) char *buf_in, *return_buf_in; int buf_len; { unsigned char *buf=(unsigned char *)buf_in; unsigned char *return_buf=(unsigned char *)return_buf_in; while (buf_len > 0) { switch (buf_len) { case 1: return_buf[0] = gszEncode[(int)((buf[0]>>2) & 0x3f)]; return_buf[1] = gszEncode[(int)((buf[0]<<4) & 0x3f)]; return_buf[2] = '='; return_buf[3] = '='; return_buf[4] = '\0'; buf++; buf_len--; return; case 2: return_buf[0] = gszEncode[(int)((buf[0]>>2) & 0x3f)]; return_buf[1] = gszEncode[(int)(((buf[0]<<4) | (buf[1]>>4)) & 0x3f)]; return_buf[2] = gszEncode[(int)((buf[1]<<2) & 0x3f)]; return_buf[3] = '='; return_buf[4] = '\0'; buf += 2; buf_len -= 2; return; default: /* convert 3 bytes */ return_buf[0] = gszEncode[(int)((buf[0]>>2) & 0x3f)]; return_buf[1] = gszEncode[(int)(((buf[0]<<4) | (buf[1]>>4)) & 0x3f)]; return_buf[2] = gszEncode[(int)(((buf[1]<<2) | (buf[2]>>6)) & 0x3f)]; return_buf[3] = gszEncode[(int)(buf[2] & 0x3f)]; return_buf[4] = '\0'; buf += 3; buf_len -= 3; break; } return_buf += 4; } } char *Base64Encode(buf) char *buf; { int len=strlen(buf), new_len; char *return_buf; new_len = (int)(len/3); new_len += 3; new_len <<= 2; return_buf = (char*)malloc(new_len*sizeof(char)); if (return_buf == NULL) return NULL; DoBase64Encode(buf, len, return_buf); return return_buf; } static int Convert(buf4, count, buf3) int *buf4, count; char *buf3; { switch (count) { case 2: buf3[0] = ((buf4[0]<<2) & 0xfc) | ((buf4[1]>>4) & 0x03); buf3[1] = '\0'; return 1; case 3: buf3[0] = ((buf4[0]<<2) & 0xfc) | ((buf4[1]>>4) & 0x03); buf3[1] = ((buf4[1]<<4) & 0xf0) | ((buf4[2]>>2) & 0x0f); buf3[2] = '\0'; return 2; case 4: buf3[0] = (char)(((buf4[0]<<2) & 0xfc) | ((buf4[1]>>4) & 0x03)); buf3[1] = (char)(((buf4[1]<<4) & 0xf0) | ((buf4[2]>>2) & 0x0f)); buf3[2] = (char)(((buf4[2]<<6) & 0xc0) | (buf4[3] & 0x3f)); buf3[3] = '\0'; return 3; default: #ifdef _TGIF_DBG /* debug, do not translate */ Error("Convert()", "Bad count passed to Convert()."); #endif /* _TGIF_DBG */ break; } return 0; } int DoBase64Decode(buf, buf_sz, return_buf) char *buf, *return_buf; int buf_sz; { int i=0, j=0, bytes_decoded=0, intbuf[5]; intbuf[4] = (-1); for (i=0, j=0; i < buf_sz; i++) { intbuf[j++] = gnDecode[(int)buf[i]]; if (j == 4) { char out_buf[4]; int k=0, bytes=0; if (intbuf[3] == (-1)) { if (intbuf[2] == (-1)) { bytes = Convert(intbuf, 2, out_buf); } else { bytes = Convert(intbuf, 3, out_buf); } } else { bytes = Convert(intbuf, 4, out_buf); } for (k=0; k < bytes; k++) { *return_buf++ = (char)(out_buf[k] & 0x0ff); } j = 0; bytes_decoded += bytes; } } *return_buf = '\0'; return bytes_decoded; } char *Base64Decode(buf) char *buf; { int len=strlen(buf); char *return_buf=(char*)malloc(len*sizeof(char)); if (return_buf == NULL) { FailAllocMessage(); return NULL; } (void)DoBase64Decode(buf, len, return_buf); return return_buf; } static void BubbleAuthInfoToTop(pai) struct AuthInfo *pai; { if (pai == topAuthInfo) return; if (pai->next != NULL) { pai->next->prev = pai->prev; } else { botAuthInfo = pai->prev; } pai->prev->next = pai->next; pai->prev = NULL; pai->next = topAuthInfo; topAuthInfo = pai; } char *FindAuthorization(pszHost, nPort, pszScheme, pszRealm) char *pszHost, *pszScheme, *pszRealm; int nPort; { struct AuthInfo *pai; for (pai=topAuthInfo; pai != NULL; pai=pai->next) { if (pai->port == nPort && pai->host != NULL && UtilStrICmp(pai->host, pszHost) == 0 && pai->scheme != NULL && UtilStrICmp(pai->scheme, pszScheme) == 0 && pai->realm != NULL && UtilStrICmp(pai->realm, pszRealm) == 0) { BubbleAuthInfoToTop(pai); return pai->authorization; } } return NULL; } void CommitAuthorization() { struct AuthInfo *pai=(struct AuthInfo *)malloc(sizeof(struct AuthInfo)); if (pai == NULL) { FailAllocMessage(); return; } memset(pai, 0, sizeof(struct AuthInfo)); if (curAuthorization.host != NULL) { pai->host = UtilStrDup(curAuthorization.host); } if (curAuthorization.scheme != NULL) { pai->scheme = UtilStrDup(curAuthorization.scheme); } if (curAuthorization.realm != NULL) { pai->realm = UtilStrDup(curAuthorization.realm); } if (curAuthorization.authorization != NULL) { pai->authorization = UtilStrDup(curAuthorization.authorization); } pai->port = curAuthorization.port; if (topAuthInfo != NULL) { topAuthInfo->prev = pai; } else { botAuthInfo = pai; } pai->prev = NULL; pai->next = topAuthInfo; topAuthInfo = pai; } void ResetAuthorization() { if (curAuthorization.host != NULL) free(curAuthorization.host); if (curAuthorization.scheme != NULL) free(curAuthorization.scheme); if (curAuthorization.realm != NULL) free(curAuthorization.realm); if (curAuthorization.authorization != NULL) { free(curAuthorization.authorization); } memset(&curAuthorization, 0, sizeof(struct AuthInfo)); } int SetAuthorization(pszHost, nPort, pszScheme, pszRealm, pszEncodedAuth) char *pszHost, *pszScheme, *pszRealm, *pszEncodedAuth; int nPort; { ResetAuthorization(); curAuthorization.host = UtilStrDup(pszHost); curAuthorization.scheme = UtilStrDup(pszScheme); curAuthorization.realm = UtilStrDup(pszRealm); curAuthorization.authorization = UtilStrDup(pszEncodedAuth); curAuthorization.port = nPort; if (curAuthorization.host==NULL || curAuthorization.scheme==NULL || curAuthorization.realm==NULL || curAuthorization.authorization==NULL) { ResetAuthorization(); return FALSE; } return TRUE; } void HttpClearReferer() { RefererInfo *pri=topReferer; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pri != NULL, "NULL topReferer in HttpClearReferer()", NULL); #endif /* TGIF_DBG */ if (pri == NULL) return; pri = pri->next; UtilFree(topReferer->referer); free(topReferer); topReferer = pri; } void HttpSetReferer(buf) char *buf; { RefererInfo *pri=(RefererInfo*)malloc(sizeof(RefererInfo)); if (pri == NULL) FailAllocMessage(); pri->next = topReferer; pri->referer = UtilStrDup(buf); if (pri->referer == NULL) FailAllocMessage(); topReferer = pri; } void HttpFakeReferer(buf) char *buf; { UtilFree(gpszFakedReferer); gpszFakedReferer = NULL; if (buf != NULL && *buf != '\0') { gpszFakedReferer = UtilStrDup(buf); if (gpszFakedReferer == NULL) FailAllocMessage(); } } static void CleanUpHttpReferer() { while (topReferer != NULL) { HttpClearReferer(); } } static void CleanUpHttpHeaderInfo() { struct TgifHttpLineInfo *pthli, *next_thli; if (tgifHttpHeaderInfo.version != NULL) free(tgifHttpHeaderInfo.version); if (tgifHttpHeaderInfo.resp_status != NULL) { free(tgifHttpHeaderInfo.resp_status); } if (tgifHttpHeaderInfo.last_modified != NULL) { free(tgifHttpHeaderInfo.last_modified); } if (tgifHttpHeaderInfo.server != NULL) free(tgifHttpHeaderInfo.server); if (tgifHttpHeaderInfo.connection != NULL) { free(tgifHttpHeaderInfo.connection); } if (tgifHttpHeaderInfo.location != NULL) free(tgifHttpHeaderInfo.location); if (tgifHttpHeaderInfo.www_authenticate != NULL) { free(tgifHttpHeaderInfo.www_authenticate); } if (tgifHttpHeaderInfo.content_encoding != NULL) { free(tgifHttpHeaderInfo.content_encoding); } if (tgifHttpHeaderInfo.content_type != NULL) { free(tgifHttpHeaderInfo.content_type); } for (pthli=tgifHttpHeaderInfo.misc; pthli != NULL; pthli=next_thli) { next_thli = pthli->next; if (pthli->name != NULL) free(pthli->name); if (pthli->value != NULL) free(pthli->value); free(pthli); } memset(&tgifHttpHeaderInfo, 0, sizeof(struct TgifHttpHeaderInfo)); } void CleanUpHttp() { ResetAuthorization(); CleanUpAuthInfo(); CleanUpHttpHeaderInfo(); CleanUpHttpReferer(); UtilFree(gpszFakedReferer); gpszFakedReferer = NULL; } void InitHttp() { topAuthInfo = botAuthInfo = NULL; memset(&curAuthorization, 0, sizeof(struct AuthInfo)); memset(&tgifHttpHeaderInfo, 0, sizeof(struct TgifHttpHeaderInfo)); topReferer = NULL; } char *HttpHeaderGetVersion() { return tgifHttpHeaderInfo.version; } int HttpHeaderGetResponseCode() { return tgifHttpHeaderInfo.resp_code; } char *HttpHeaderGetResponseStatus() { return tgifHttpHeaderInfo.resp_status; } char *HttpHeaderGetLastModified() { return tgifHttpHeaderInfo.last_modified; } char *HttpHeaderGetServer() { return tgifHttpHeaderInfo.server; } char *HttpHeaderGetConnection() { return tgifHttpHeaderInfo.connection; } char *HttpHeaderGetLocation() { return tgifHttpHeaderInfo.location; } char *HttpHeaderGetWWWAuthentication() { return tgifHttpHeaderInfo.www_authenticate; } char *HttpHeaderGetContentEncoding() { return tgifHttpHeaderInfo.content_encoding; } char *HttpHeaderGetContentType() { return tgifHttpHeaderInfo.content_type; } long HttpHeaderGetContentLength() { return tgifHttpHeaderInfo.content_length; } char *HttpHeaderGetOtherField(name) char *name; { struct TgifHttpLineInfo *pthli; for (pthli=tgifHttpHeaderInfo.misc; pthli != NULL; pthli=pthli->next) { if (pthli->name != NULL && UtilStrICmp(pthli->name, name) == 0) { return pthli->value; } } return NULL; } static int gnUserAgentNameInitialized=FALSE; static void InitUserAgentName() { if (gnUserAgentNameInitialized) return; gnUserAgentNameInitialized = TRUE; GetClientID(SZ_USER_AGENT, sizeof(SZ_USER_AGENT)); GetUserID(SZ_USER_NAME, sizeof(SZ_USER_NAME)); } int HttpDoConnect(psz_host, us_port, pn_socket) char *psz_host; int us_port, *pn_socket; { int rc, len=strlen(psz_host)+80; char *msg=(char*)malloc((len+1)*sizeof(char)); if (msg == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } sprintf(msg, TgLoadCachedString(CSTID_MAKING_CONN_TO_HOST_PORT), "HTTP", psz_host, us_port); ShowRemoteStatus(msg); rc = TcpDoConnect(psz_host, us_port, pn_socket); if (rc == TG_REMOTE_STATUS_OK) { sprintf(msg, TgLoadCachedString(CSTID_CONN_TO_HOST_PORT_ESTB), "HTTP", psz_host, us_port); } else { sprintf(msg, TgLoadString(STID_FAIL_TO_CONN_TO_HOST_PORT), "HTTP", psz_host, us_port); } ShowRemoteStatus(msg); free(msg); return rc; } static char *AppendSimpleString(buf, name, value) char *buf, *name, *value; { int cur_len=strlen(buf); if (name == NULL && value == NULL) { int new_len=cur_len+2; if ((buf=(char*)realloc(buf, new_len+1)) == NULL) { return NULL; } sprintf(&buf[cur_len], "\r\n"); } else { int new_len=cur_len+strlen(name)+2+strlen(value)+2; if ((buf=(char*)realloc(buf, new_len+1)) == NULL) { return NULL; } sprintf(&buf[cur_len], "%s: %s\r\n", name, value); } return buf; } /* do not translate -- program constants */ static char SZ_CONTENT_TYPE[]="Content-type:"; static char SZ_CONTENT_LENGTH[]="Content-length:"; static char SZ_POST_CONTENT_TYPE[]="application/x-www-form-urlencoded"; static char *pszAccept[] = { /* "image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, image/png", */ "text/plain", "text/html", "application/x-tgif", "*/*", NULL }; static char *AppendAcceptStrings(buf) char *buf; { char **s_ptr; int cur_len=strlen(buf); for (s_ptr=pszAccept; *s_ptr != NULL; s_ptr++) { int len=strlen(*s_ptr); int new_len=cur_len+len+2+8; if ((buf=(char*)realloc(buf, new_len+1)) == NULL) { return NULL; } /* do not translate -- program constants */ sprintf(&buf[cur_len], "Accept: %s\r\n", *s_ptr); cur_len = new_len; } return buf; } static char *AppendKeepAliveStrings(buf) char *buf; { if (gnHttpKeepAlive == FALSE) return buf; /* do not translate -- program constants */ return AppendSimpleString(buf, "Connection", "Keep-Alive"); } static char *AppendRefererStrings(buf) char *buf; { if (topReferer == NULL) { if (gpszFakedReferer == NULL) { return buf; } /* do not translate -- program constants */ return AppendSimpleString(buf, "Referer", gpszFakedReferer); } /* do not translate -- program constants */ return AppendSimpleString(buf, "Referer", topReferer->referer); } static char *AppendUserAgentString(buf) char *buf; { InitUserAgentName(); /* do not translate -- program constants */ return AppendSimpleString(buf, "User-Agent", SZ_USER_AGENT); } static char *AppendFromString(buf) char *buf; { InitUserAgentName(); /* do not translate -- program constants */ return AppendSimpleString(buf, "From", SZ_USER_NAME); } static char *AppendHostString(buf, psz_host, us_port) char *buf, *psz_host; int us_port; { char tmp_buf[MAXSTRING]; sprintf(tmp_buf, "%s:%1d", psz_host, us_port); /* do not translate -- program constants */ return AppendSimpleString(buf, "Host", tmp_buf); } static char *AppendAuthorizationString(buf) char *buf; { char *pszReturn; char *pszAuth=(char*)malloc( (strlen(curAuthorization.scheme)+ strlen(curAuthorization.authorization)+2)*sizeof(char)); if (pszAuth == NULL) return NULL; sprintf(pszAuth, "%s %s", curAuthorization.scheme, curAuthorization.authorization); /* do not translate -- program constants */ pszReturn = AppendSimpleString(buf, "Authorization", pszAuth); free(pszAuth); return pszReturn; } static char *AppendPostContentTypeString(buf) char *buf; { /* do not translate -- program constants */ return AppendSimpleString(buf, "Content-type", SZ_POST_CONTENT_TYPE); } static char *AppendPostContentLengthString(buf, content_length) char *buf; int content_length; { char len_str[20]; sprintf(len_str, "%1d", content_length); /* do not translate -- program constants */ return AppendSimpleString(buf, "Content-length", len_str); } static char *AppendPostContentString(buf, fp, content_length) char *buf; FILE *fp; int content_length; { int cur_len=strlen(buf), bytes_read, total_read=0; int new_len=cur_len+content_length; char tmp_buf[512]; if ((buf=(char*)realloc(buf, new_len+1)) == NULL) { return NULL; } while ((bytes_read=fread(tmp_buf, sizeof(char), sizeof(tmp_buf), fp)) > 0) { if (bytes_read+total_read > content_length) { bytes_read = content_length-total_read; fprintf(stderr, TgLoadString(STID_LINES_TOO_LONG_CONTENT_LENGTH), "HTTP"); fprintf(stderr, "\n"); } strncpy(&buf[cur_len+total_read], tmp_buf, bytes_read); total_read += bytes_read; } buf[cur_len+content_length] = '\0'; return buf; } static char *AppendCRLFString(buf) char *buf; { return AppendSimpleString(buf, NULL, NULL); } int HttpDoWrite(n_socket, psz_path, psz_host, us_port) int n_socket, us_port; char *psz_path, *psz_host; { int status=0, total_sz=0; FILE *fp=NULL; char *buf=(char*)malloc((strlen(psz_path)+5+2+31)*sizeof(char)), msg[40]; if (buf == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } if (postingCGIQuery) { /* do not translate -- program constants */ sprintf(buf, "POST %s %s\r\n", psz_path, SZ_HTTP_VERSION); } else if (gettingHttpHeaderOnly) { /* do not translate -- program constants */ sprintf(buf, "HEAD %s %s\r\n", psz_path, SZ_HTTP_VERSION); } else { /* do not translate -- program constants */ sprintf(buf, "GET %s %s\r\n", psz_path, SZ_HTTP_VERSION); } if ((buf=AppendKeepAliveStrings(buf)) == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } if ((buf=AppendRefererStrings(buf)) == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } if ((buf=AppendAcceptStrings(buf)) == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } if ((buf=AppendUserAgentString(buf)) == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } if ((buf=AppendFromString(buf)) == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } if ((buf=AppendHostString(buf, psz_host, us_port)) == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } if (curAuthorization.scheme != NULL && curAuthorization.authorization != NULL) { if ((buf=AppendAuthorizationString(buf)) == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } } if (postingCGIQuery && fnameForPostingCGIQuery != NULL) { int bytes_read; char tmp_buf[512]; if ((fp=fopen(fnameForPostingCGIQuery, "r")) == NULL) { fprintf(stderr, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), fnameForPostingCGIQuery); fprintf(stderr, "\n"); return TG_REMOTE_STATUS_READ; } while ((bytes_read=fread(tmp_buf, sizeof(char), sizeof(tmp_buf), fp)) > 0) { total_sz += bytes_read; } rewind(fp); if ((buf=AppendPostContentTypeString(buf)) == NULL) { fclose(fp); FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } if ((buf=AppendPostContentLengthString(buf, total_sz)) == NULL) { fclose(fp); FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } } if ((buf=AppendCRLFString(buf)) == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } if (fp != NULL) { buf = AppendPostContentString(buf, fp, total_sz); fclose(fp); if (buf == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } } sprintf(msg, TgLoadCachedString(CSTID_SENDING_REQUESTS_DOTS), "HTTP"); ShowRemoteStatus(msg); if (debugHttp == 999 || ((debugHttp % 100) == 99 && cmdLineDumpURL && cmdLineDumpURLWithHeader)) { /* debug, do not translate */ fprintf(stderr, "************************\n"); fprintf(stderr, "* Begin Request Header *\n"); fprintf(stderr, "************************\n"); (void)fwrite(buf, sizeof(char), strlen(buf), stderr); fprintf(stderr, "************************\n"); fprintf(stderr, "* End Request Header *\n"); fprintf(stderr, "************************\n"); } status = TcpDoWrite(n_socket, buf, (int)strlen(buf)); free(buf); if (status != TG_REMOTE_STATUS_OK) { sprintf(msg, TgLoadString(STID_FAIL_TO_SEND_REQ), "HTTP"); ShowRemoteStatus(msg); } return status; } #ifdef NOT_DEFINED #ifdef _TGIF_DBG /* debug, do not translate */ static char SZ_DEF_GIF_NAME[]="/tmp/htclient.gif"; static void DebugHttpDumpResponse(buf) char *buf; { char *c_ptr=strchr(buf, '\n'), *line_ptr=buf, *content_type=NULL; int content_length=(-1), gif87a=FALSE; int len1=strlen(SZ_CONTENT_TYPE), len2=strlen(SZ_CONTENT_LENGTH); FILE *fp=stderr; while (c_ptr != NULL) { char *prev_ptr=c_ptr; if (prev_ptr != line_ptr && *(--prev_ptr) == '\r') { *prev_ptr = '\0'; } else { prev_ptr = NULL; *c_ptr = '\0'; } fprintf(fp, "%s\n", line_ptr); if (content_type == NULL && UtilStrNCaseCmp(line_ptr, SZ_CONTENT_TYPE, len1) == 0) { content_type = UtilStrDup(&line_ptr[len1]); if (content_type != NULL) { UtilTrimBlanks(content_type); } } else if (content_length == (-1) && UtilStrNCaseCmp(line_ptr, SZ_CONTENT_LENGTH, len2) == 0) { char *tmp_ptr=UtilStrDup(&line_ptr[len2]); if (tmp_ptr != NULL) { UtilTrimBlanks(tmp_ptr); content_length = atoi(tmp_ptr); free(tmp_ptr); } } if (prev_ptr == NULL) { *c_ptr = '\n'; } else { *prev_ptr = '\r'; } line_ptr = &c_ptr[1]; if (content_type != NULL && content_length != (-1)) { /* do not translate -- program constants */ if (UtilStrICmp(content_type, "image/gif") == 0 && UtilStrNCaseCmp(line_ptr, "GIF87a", 6) == 0) { gif87a = TRUE; break; } } c_ptr = strchr(line_ptr, '\n'); } if (gif87a) { FILE *gif_fp; if ((gif_fp=fopen(SZ_DEF_GIF_NAME, "w")) == NULL) { fprintf(stderr, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), SZ_DEF_GIF_NAME); fprintf(stderr, "\n"); } else { if (fwrite(line_ptr, sizeof(char), content_length, gif_fp) != content_length) { FailToWriteFileMessage(SZ_DEF_GIF_NAME); } else { /* debug, do not translate */ fprintf(stderr, "GIF87a image written to '%s'.\n", SZ_DEF_GIF_NAME); } fclose(gif_fp); } } else if (line_ptr != NULL) { int len=strlen(line_ptr); if (len > 0 && line_ptr[len-1] == '\r') { line_ptr[len-1] = '\0'; fprintf(fp, "%s\n", line_ptr); line_ptr[len-1] = '\r'; } else { fprintf(fp, "%s\n", line_ptr); } } } #endif /* _TGIF_DBG */ #endif /* NOT_DEFINED */ static int ParseBadFormat(buf) char *buf; { fprintf(stderr, TgLoadString(STID_INVALID_FORMAT_IN_HEADER), "HTTP"); fprintf(stderr, "\n"); if (buf != NULL) free(buf); return TG_REMOTE_STATUS_FORMAT; } static int ParseNoMem(buf) char *buf; { FailAllocMessage(); if (buf != NULL) free(buf); return TG_REMOTE_STATUS_MEM; } static int HttpParseHeaderLine(buf, first_line) char *buf; int first_line; { char *dup_buf, *colon_ptr; if (*buf == '\0') return TG_REMOTE_STATUS_OK; if (first_line) { char *version_ptr, *code_ptr, *status_ptr; dup_buf = UtilStrDup(buf); if (dup_buf == NULL) return ParseNoMem(NULL);; version_ptr = strtok(dup_buf, " \t\n\r"); code_ptr = (version_ptr == NULL ? NULL : strtok(NULL, " \t\n\r")); status_ptr = (code_ptr == NULL ? NULL : strtok(NULL, " \t\n\r")); if (version_ptr == NULL) return ParseBadFormat(dup_buf); tgifHttpHeaderInfo.version = UtilStrDup(version_ptr); if (code_ptr == NULL) return ParseBadFormat(dup_buf); tgifHttpHeaderInfo.resp_code = atoi(code_ptr); if (status_ptr != NULL) { tgifHttpHeaderInfo.resp_status = UtilStrDup(status_ptr); if (tgifHttpHeaderInfo.resp_status == NULL) { return ParseBadFormat(dup_buf); } } free(dup_buf); return TG_REMOTE_STATUS_OK; } dup_buf = UtilStrDup(buf); if (dup_buf == NULL) return ParseNoMem(NULL); colon_ptr = strchr(dup_buf, ':'); if (colon_ptr == NULL) return ParseBadFormat(dup_buf); *colon_ptr = '\0'; UtilTrimBlanks(dup_buf); /* do not translate -- program constants */ if (UtilStrICmp(dup_buf, "Last-Modified") == 0) { tgifHttpHeaderInfo.last_modified = UtilStrDup(&colon_ptr[1]); if (tgifHttpHeaderInfo.last_modified == NULL) return ParseNoMem(dup_buf);; UtilTrimBlanks(tgifHttpHeaderInfo.last_modified); } else if (UtilStrICmp(dup_buf, "Server") == 0) { tgifHttpHeaderInfo.server = UtilStrDup(&colon_ptr[1]); if (tgifHttpHeaderInfo.server == NULL) return ParseNoMem(dup_buf);; UtilTrimBlanks(tgifHttpHeaderInfo.server); } else if (UtilStrICmp(dup_buf, "Connection") == 0) { tgifHttpHeaderInfo.connection = UtilStrDup(&colon_ptr[1]); if (tgifHttpHeaderInfo.connection == NULL) return ParseNoMem(dup_buf);; UtilTrimBlanks(tgifHttpHeaderInfo.connection); } else if (UtilStrICmp(dup_buf, "Location") == 0) { tgifHttpHeaderInfo.location = UtilStrDup(&colon_ptr[1]); if (tgifHttpHeaderInfo.location == NULL) return ParseNoMem(dup_buf);; UtilTrimBlanks(tgifHttpHeaderInfo.location); } else if (UtilStrICmp(dup_buf, "WWW-Authenticate") == 0) { tgifHttpHeaderInfo.www_authenticate = UtilStrDup(&colon_ptr[1]); if (tgifHttpHeaderInfo.www_authenticate == NULL) { return ParseNoMem(dup_buf);; } UtilTrimBlanks(tgifHttpHeaderInfo.www_authenticate); } else if (UtilStrICmp(dup_buf, "Content-Encoding") == 0) { tgifHttpHeaderInfo.content_encoding = UtilStrDup(&colon_ptr[1]); if (tgifHttpHeaderInfo.content_encoding == NULL) { return ParseNoMem(dup_buf);; } UtilTrimBlanks(tgifHttpHeaderInfo.content_encoding); } else if (UtilStrICmp(dup_buf, "Content-Type") == 0) { tgifHttpHeaderInfo.content_type = UtilStrDup(&colon_ptr[1]); if (tgifHttpHeaderInfo.content_type == NULL) return ParseNoMem(dup_buf);; UtilTrimBlanks(tgifHttpHeaderInfo.content_type); } else if (UtilStrICmp(dup_buf, "Content-Length") == 0) { char *length_ptr=(&colon_ptr[1]); UtilTrimBlanks(length_ptr); if (sscanf(length_ptr, "%ld", &tgifHttpHeaderInfo.content_length) != 1) { tgifHttpHeaderInfo.content_length = 0L; } } else { struct TgifHttpLineInfo *pthli; pthli = (struct TgifHttpLineInfo*)malloc(sizeof(struct TgifHttpLineInfo)); if (pthli == NULL) return ParseNoMem(dup_buf);; memset(pthli, 0, sizeof(struct TgifHttpLineInfo)); pthli->name = UtilStrDup(dup_buf); if (pthli->name == NULL) return ParseNoMem(dup_buf);; pthli->value = UtilStrDup(&colon_ptr[1]); if (pthli->value == NULL) return ParseNoMem(dup_buf);; pthli->next = tgifHttpHeaderInfo.misc; tgifHttpHeaderInfo.misc = pthli; } *colon_ptr = ':'; free(dup_buf); return TG_REMOTE_STATUS_OK; } void HttpDumpHeader() { struct TgifHttpLineInfo *pthli; if (tgifHttpHeaderInfo.version != NULL) { fprintf(stderr, "%s %1d", tgifHttpHeaderInfo.version, tgifHttpHeaderInfo.resp_code); if (tgifHttpHeaderInfo.resp_status != NULL) { fprintf(stderr, " %s", tgifHttpHeaderInfo.resp_status); } fprintf(stderr, "\n"); } /* do not translate -- program constants */ if (tgifHttpHeaderInfo.last_modified != NULL) { fprintf(stderr, "Last-Modified: %s\n", tgifHttpHeaderInfo.last_modified); } if (tgifHttpHeaderInfo.server != NULL) { fprintf(stderr, "Server: %s\n", tgifHttpHeaderInfo.server); } if (tgifHttpHeaderInfo.connection != NULL) { fprintf(stderr, "Connection: %s\n", tgifHttpHeaderInfo.connection); } if (tgifHttpHeaderInfo.location != NULL) { fprintf(stderr, "Location: %s\n", tgifHttpHeaderInfo.location); } if (tgifHttpHeaderInfo.www_authenticate != NULL) { fprintf(stderr, "WWW-Authentication: %s\n", tgifHttpHeaderInfo.www_authenticate); } if (tgifHttpHeaderInfo.content_encoding != NULL) { fprintf(stderr, "Content-Encoding: %s\n", tgifHttpHeaderInfo.content_encoding); } if (tgifHttpHeaderInfo.content_type != NULL) { fprintf(stderr, "Content-Type: %s\n", tgifHttpHeaderInfo.content_type); } if (tgifHttpHeaderInfo.content_length != 0) { fprintf(stderr, "Content-Length: %ld\n", tgifHttpHeaderInfo.content_length); } for (pthli=tgifHttpHeaderInfo.misc; pthli != NULL; pthli=pthli->next) { fprintf(stderr, "%s: %s\n", (pthli->name == NULL ? TgLoadCachedString(CSTID_PARANED_UNKNOWN) : pthli->name), (pthli->value == NULL ? TgLoadCachedString(CSTID_PARANED_NONE) : pthli->value)); } } char *HttpExtractText(buf, pn_buf_sz, pn_html, ppsz_content_type) char *buf, **ppsz_content_type; int *pn_buf_sz, *pn_html; { char *c_ptr=strchr(buf, '\n'), *line_ptr=buf, *content_type=NULL; int content_length=(-1), text_type=FALSE, first_line=TRUE; int len1=strlen(SZ_CONTENT_TYPE), len2=strlen(SZ_CONTENT_LENGTH); FILE *fp=stderr; CleanUpHttpHeaderInfo(); if (pn_buf_sz != NULL) *pn_buf_sz = 0; if (pn_html != NULL) *pn_html = FALSE; if (ppsz_content_type != NULL) *ppsz_content_type = NULL; while (c_ptr != NULL) { char *prev_ptr=c_ptr; int rc; if (prev_ptr != line_ptr && *(--prev_ptr) == '\r') { *prev_ptr = '\0'; } else { prev_ptr = NULL; *c_ptr = '\0'; } if (debugHttp > 0) { if ((debugHttp % 100) == 99 && cmdLineDumpURL && !cmdLineDumpURLWithHeader) { } else if (!deserializingFile) { fprintf(fp, "%s\n", line_ptr); } } rc = HttpParseHeaderLine(line_ptr, first_line); if (rc != TG_REMOTE_STATUS_OK) { /* well, should break... */ } first_line = FALSE; if (*line_ptr == '\0') { /* empty line, end of header */ if (prev_ptr == NULL) { *c_ptr = '\n'; } else { *prev_ptr = '\r'; } line_ptr = &c_ptr[1]; break; } if (content_type == NULL && UtilStrNCaseCmp(line_ptr, SZ_CONTENT_TYPE, len1) == 0) { content_type = UtilStrDup(&line_ptr[len1]); if (content_type != NULL) { char *psz; UtilTrimBlanks(content_type); if ((psz=strchr(content_type, ';')) != NULL) *psz = '\0'; if (ppsz_content_type != NULL) { *ppsz_content_type = UtilStrDup(content_type); } /* do not translate -- program constants */ if (UtilStrNCaseCmp(content_type, "text/", 5) == 0) { text_type = TRUE; if (strcmp(&content_type[5], "html") == 0) { if (pn_html != NULL) *pn_html = TRUE; } } } } else if (content_length == (-1) && UtilStrNCaseCmp(line_ptr, SZ_CONTENT_LENGTH, len2) == 0) { char *tmp_ptr=UtilStrDup(&line_ptr[len2]); if (tmp_ptr != NULL) { UtilTrimBlanks(tmp_ptr); content_length = atoi(tmp_ptr); free(tmp_ptr); } } if (prev_ptr == NULL) { *c_ptr = '\n'; } else { *prev_ptr = '\r'; } line_ptr = &c_ptr[1]; c_ptr = strchr(line_ptr, '\n'); } if (content_type != NULL) free(content_type); if (cmdLineDumpURL && cmdLineDumpURLWithHeader && cmdLineDumpURLHeaderOnly) { /* only want the header */ } else if (text_type || content_length == (-1)) { int buf_len=strlen(line_ptr); char *return_buf; if (content_length == (-1)) { content_length = buf_len; return_buf = (char*)malloc((buf_len+1)*sizeof(char)); } else { return_buf = (char*)malloc((content_length+1)*sizeof(char)); } if (return_buf == NULL) { FailAllocMessage(); return NULL; } if (buf_len <= content_length) { memcpy(return_buf, line_ptr, content_length); } else { while (buf_len > content_length) { if (*line_ptr == '\r' || *line_ptr == '\n') { line_ptr++; buf_len--; } else { break; } } memcpy(return_buf, line_ptr, content_length); } return_buf[content_length] = '\0'; if (pn_buf_sz != NULL) *pn_buf_sz = content_length; return return_buf; } else if (content_length != (-1)) { char *return_buf=(char*)malloc((content_length+1)*sizeof(char)); if (return_buf == NULL) { FailAllocMessage(); return NULL; } memcpy(return_buf, line_ptr, content_length); return_buf[content_length] = '\0'; if (pn_buf_sz != NULL) *pn_buf_sz = content_length; return return_buf; } return NULL; } static int GetContentLength(buf, pn_header_len) char *buf; int *pn_header_len; { char *c_ptr, *line_ptr=buf; int content_len=(-1), just_lf=IsJustLF(buf); int inc=(just_lf?1:2); for (c_ptr=GetHeaderLine(line_ptr, just_lf); c_ptr != NULL; c_ptr=GetHeaderLine(line_ptr, just_lf)) { char *colon_ptr=NULL; if (c_ptr == line_ptr) { /* reach the end of header, now decide if the header is good */ *pn_header_len = ((&c_ptr[inc]) - buf); return (content_len==(-1) ? 0 : content_len); } *c_ptr = '\0'; colon_ptr = strchr(line_ptr, ':'); if (colon_ptr != NULL) { *colon_ptr = '\0'; /* do not translate -- program constants */ if (UtilStrICmp(line_ptr, "Content-Length") == 0) { char length_str[MAXSTRING]; int len=0; UtilStrCpyN(length_str, MAXSTRING-1, &colon_ptr[1]); UtilTrimBlanks(length_str); if (sscanf(length_str, "%d", &len) == 1) { content_len = len; } } *colon_ptr = ':'; } *c_ptr = (just_lf ? '\n' : '\r'); line_ptr = (&c_ptr[inc]); } return (-1); } static int ReadFromSocket(n_socket) int n_socket; /* return TRUE means there's data at n_socket */ /* return FALSE means abort */ { for (;;) { struct timeval timeout; fd_set fdset; int select_width=XConnectionNumber(mainDisplay)+1, status=0, nfds=0; nfds = max(select_width, n_socket+1); timeout.tv_sec = 0; timeout.tv_usec = 100000; FD_ZERO(&fdset); FD_SET(select_width-1, &fdset); FD_SET(n_socket, &fdset); #ifdef __hpux status = select(nfds, (int*)&fdset, NULL, NULL, &timeout); #else /* !__hpux */ status = select(nfds, &fdset, NULL, NULL, &timeout); #endif /* __hpux */ if (status < 0) { if (errno == EINTR) { /* interrupted by a system call, not a problem */ CheckInterrupt(TRUE); } else { sprintf(gszMsgBox, TgLoadString(STID_FUNC_SELECT_SYS_CALL_FAILED), "ReadFromSocket()"), MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; } } else if (status == 0) { /* spin the interrupt thing */ CheckInterrupt(TRUE); } else if (status == 1) { if (FD_ISSET(n_socket, &fdset)) { /* character waiting to be processed at n_socket */ return TRUE; } else if (FD_ISSET(select_width-1, &fdset)) { while (XPending(mainDisplay) > 0) { if (TryProcessAnAbortXEvent(TRUE, NULL, NULL) != 0) { return FALSE; } } } } else if (status == 2) { return TRUE; } else { sprintf(gszMsgBox, TgLoadString(STID_FUNC_INVALID_RC_FOR_SELECT), "ReadFromSocket()", status); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; } } return FALSE; } #define MIN_READ_SIZE 0x100 int HttpDoRead(n_socket, ppsz_buf, pn_buf_sz) int n_socket, *pn_buf_sz; char **ppsz_buf; { int buf_sz=0x400, len=0, end_of_file=FALSE; int status=TG_REMOTE_STATUS_OK, content_len=(-1), header_len=0; char *buf=(char*)malloc(buf_sz*sizeof(char)), msg[MAXSTRING]; if (pn_buf_sz != NULL) *pn_buf_sz = 0; *ppsz_buf = NULL; if (buf == NULL) { FailAllocMessage(); return TG_REMOTE_STATUS_MEM; } sprintf(msg, TgLoadCachedString(CSTID_READING_RESPONSE_DOTS), "HTTP"); ShowRemoteStatus(msg); CleanUpDownloadStats(); ResetMultipartReplace(FALSE); do { int bytes_read=0; char progress_buf[MAXSTRING]; *progress_buf = '\0'; if (buf_sz - len < MIN_READ_SIZE) { buf_sz += 0x400; if ((buf=(char*)realloc(buf, buf_sz)) == NULL) { FailAllocMessage(); status = TG_REMOTE_STATUS_MEM; break; } } if (PRTGIF || ReadFromSocket(n_socket)) { bytes_read = read(n_socket, &buf[len], buf_sz-len-1); } else { /* abort */ status = TG_REMOTE_STATUS_INTR; break; } if (bytes_read <= 0) { if (bytes_read < 0 && (errno == ENOTCONN || errno == ECONNRESET || errno == EPIPE)) { fprintf(stderr, TgLoadString(STID_NETWORK_READ_ERROR), "HTTP"); fprintf(stderr, "\n"); status = TG_REMOTE_STATUS_READ; } else if (bytes_read < 0) { fprintf(stderr, TgLoadString(STID_NETWORK_ERROR), "HTTP"); fprintf(stderr, "\n"); status = TG_REMOTE_STATUS_NET; } if (!UpdateDownloadStats(0, progress_buf)) { *progress_buf = '\0'; } end_of_file = TRUE; } else { if (!UpdateDownloadStats(bytes_read, progress_buf)) { *progress_buf = '\0'; } len += bytes_read; } if (status == TG_REMOTE_STATUS_OK && !end_of_file && (UserAbortComm() || OtherAbortComm())) { /* abort */ status = TG_REMOTE_STATUS_INTR; break; } else { int chopped_len=(-1); if (status == TG_REMOTE_STATUS_OK && content_len == (-1)) { buf[len] = '\0'; content_len = GetContentLength(buf, &header_len); } if (content_len == (-1) || content_len == 0) { /* do not translate -- program constants */ sprintf(msg, "HTTP: %1d bytes %s...", len, (*progress_buf=='\0' ? "" : progress_buf)); if (len >= 200) { chopped_len = len; HandleMultipartReplace(buf, &chopped_len); } } else { /* do not translate -- program constants */ sprintf(msg, "HTTP: %1d of %1d bytes %s...", len-header_len, content_len, (*progress_buf=='\0' ? "" : progress_buf)); if (status == TG_REMOTE_STATUS_OK && len == header_len+content_len) { end_of_file = TRUE; } } ShowRemoteStatus(msg); if (PRTGIF && cmdLineDumpURL && cmdLineDumpURLShowStatus) { if (content_len == (-1) || content_len == 0) { /* do not translate -- program constants */ fprintf(stderr, "HTTP: %1d bytes %s...\r", len, (*progress_buf=='\0' ? "" : progress_buf)); } else { /* do not translate -- program constants */ fprintf(stderr, "HTTP: %1d of %1d bytes %s...\r", len-header_len, content_len, (*progress_buf=='\0' ? "" : progress_buf)); } } if (chopped_len != (-1)) { len = chopped_len; } } } while (status == TG_REMOTE_STATUS_OK && !end_of_file); if (status == TG_REMOTE_STATUS_OK) { buf[len] = '\0'; *ppsz_buf = buf; if (pn_buf_sz != NULL) *pn_buf_sz = len; sprintf(msg, TgLoadCachedString(CSTID_RESPONSES_RECEIVED), "HTTP"); if ((debugHttp % 100) == 99) { /* debug, do not translate */ if (!cmdLineDumpURL) { fprintf(stderr, "\n==========>>>\n"); (void)fwrite(buf, sizeof(char), len, stderr); fprintf(stderr, "\n<<<==========\n"); } } } else { if (buf != NULL) free(buf); if (status == TG_REMOTE_STATUS_INTR) { if (PRTGIF && cmdLineDumpURL && cmdLineDumpURLShowStatus) { fprintf(stderr, "\n"); } /* should get rid of all key presses */ while (ESCPressed()) ; ResetMultipartReplace(TRUE); sprintf(msg, TgLoadString(STID_CONN_ABORT_BY_USER), "HTTP"); } else { sprintf(msg, TgLoadString(STID_ERROR_ENCOUNTERED_WHILE_RECV), "HTTP"); } } ShowRemoteStatus(msg); if (PRTGIF && cmdLineDumpURL && cmdLineDumpURLShowStatus) { fprintf(stderr, "\n"); } return status; } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/nkf.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000001160�11602233312�013706� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/nkf.e,v 1.4 2011/06/14 02:32:19 william Exp $ */ #ifndef _NO_NKF #ifndef _NKF_E_ #define _NKF_E_ #ifdef _INCLUDE_FROM_NKF_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_NKF_C_*/ extern int Tg_useNKF ARGS_DECL((void)); extern int Tg_do_kconv ARGS_DECL((char *i, char *o, int siz)); extern void CleanUpNKF ARGS_DECL((void)); extern int InitNKF ARGS_DECL((void)); #ifdef _INCLUDE_FROM_NKF_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_NKF_C_*/ #endif /*_NKF_E_*/ #endif /* ~_NO_NKF */ ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/cursor.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000042215�11602233311�014450� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/cursor.c,v 1.7 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_CURSOR_C_ #include "tgifdefs.h" #include "choice.e" #include "color.e" #include "cursor.e" #include "file.e" #include "setup.e" #include "strtbl.e" #include "xbitmap.e" #include "xbm/null.xbm" #include "xbm/nullmask.xbm" #include "xbm/text_cur.xbm" #include "xbm/helphand.xbm" #include "xbm/hhand_mk.xbm" #include "xbm/mag.xbm" #include "xbm/mag_mask.xbm" #include "xbm/flood.xbm" #include "xbm/flood_mk.xbm" #include "xbm/drip.xbm" #include "xbm/drip_msk.xbm" Cursor nullCursor=(Cursor)0; Cursor cornerCursor=(Cursor)0; Cursor handCursor=(Cursor)0; Cursor defaultCursor=(Cursor)0; Cursor watchCursor=(Cursor)0; Cursor drawCursor=(Cursor)0; Cursor freehandCursor=(Cursor)0; Cursor vertexCursor=(Cursor)0; Cursor rotateCursor=(Cursor)0; Cursor rotatingCursor=(Cursor)0; Cursor horiShearCursor=(Cursor)0; Cursor vertShearCursor=(Cursor)0; Cursor moveCursor=(Cursor)0; Cursor textCursor=(Cursor)0; Cursor hyperSpaceCursor=(Cursor)0; Cursor magCursor=(Cursor)0; Cursor floodCursor=(Cursor)0; Cursor dripCursor=(Cursor)0; int watchCursorOnMainWindow=FALSE; static GC textCursorGC=NULL; static Pixmap textPixmap=None; static Pixmap nullPixmap=None; static Pixmap nullMaskPixmap=None; static Pixmap hyperSpacePixmap=None; static Pixmap hyperSpaceMaskPixmap=None; static Pixmap magPixmap=None; static Pixmap magMaskPixmap=None; static Pixmap floodPixmap=None; static Pixmap floodMaskPixmap=None; static Pixmap dripPixmap=None; static Pixmap dripMaskPixmap=None; static char *cursorName[] = { /* do not translate -- program constants */ "X_cursor", "arrow", "based_arrow_down", "based_arrow_up", "boat", "bogosity", "bottom_left_corner", "bottom_right_corner", "bottom_side", "bottom_tee", "box_spiral", "center_ptr", "circle", "clock", "coffee_mug", "cross", "cross_reverse", "crosshair", "diamond_cross", "dot", "dotbox", "double_arrow", "draft_large", "draft_small", "draped_box", "exchange", "fleur", "gobbler", "gumby", "hand1", "hand2", "heart", "icon", "iron_cross", "left_ptr", "left_side", "left_tee", "leftbutton", "ll_angle", "lr_angle", "man", "middlebutton", "mouse", "pencil", "pirate", "plus", "question_arrow", "right_ptr", "right_side", "right_tee", "rightbutton", "rtl_logo", "sailboat", "sb_down_arrow", "sb_h_double_arrow", "sb_left_arrow", "sb_right_arrow", "sb_up_arrow", "sb_v_double_arrow", "shuttle", "sizing", "spider", "spraycan", "star", "target", "tcross", "top_left_arrow", "top_left_corner", "top_right_corner", "top_side", "top_tee", "trek", "ul_angle", "umbrella", "ur_angle", "watch", "xterm", "" }; static unsigned int cursorID[] = { XC_X_cursor, XC_arrow, XC_based_arrow_down, XC_based_arrow_up, XC_boat, XC_bogosity, XC_bottom_left_corner, XC_bottom_right_corner, XC_bottom_side, XC_bottom_tee, XC_box_spiral, XC_center_ptr, XC_circle, XC_clock, XC_coffee_mug, XC_cross, XC_cross_reverse, XC_crosshair, XC_diamond_cross, XC_dot, XC_dotbox, XC_double_arrow, XC_draft_large, XC_draft_small, XC_draped_box, XC_exchange, XC_fleur, XC_gobbler, XC_gumby, XC_hand1, XC_hand2, XC_heart, XC_icon, XC_iron_cross, XC_left_ptr, XC_left_side, XC_left_tee, XC_leftbutton, XC_ll_angle, XC_lr_angle, XC_man, XC_middlebutton, XC_mouse, XC_pencil, XC_pirate, XC_plus, XC_question_arrow, XC_right_ptr, XC_right_side, XC_right_tee, XC_rightbutton, XC_rtl_logo, XC_sailboat, XC_sb_down_arrow, XC_sb_h_double_arrow, XC_sb_left_arrow, XC_sb_right_arrow, XC_sb_up_arrow, XC_sb_v_double_arrow, XC_shuttle, XC_sizing, XC_spider, XC_spraycan, XC_star, XC_target, XC_tcross, XC_top_left_arrow, XC_top_left_corner, XC_top_right_corner, XC_top_side, XC_top_tee, XC_trek, XC_ul_angle, XC_umbrella, XC_ur_angle, XC_watch, XC_xterm }; void SetTextCursor(window) Window window; { XDefineCursor(mainDisplay, window, textCursor); } void SetNullCursor(window) Window window; { XDefineCursor(mainDisplay, window, nullCursor); } void SetWatchCursor(window) Window window; { if (!PRTGIF || cmdLineOpenDisplay) { XDefineCursor(mainDisplay, window, watchCursor); if (window == mainWindow) watchCursorOnMainWindow = TRUE; XSync(mainDisplay, False); } } void SetDrawCursor(window) Window window; { XDefineCursor(mainDisplay, window, drawCursor); } void SetFreeHandCursor(window) Window window; { XDefineCursor(mainDisplay, window, freehandCursor); } void SetVertexCursor(window) Window window; { XDefineCursor(mainDisplay, window, vertexCursor); } void SetRotateCursor(window) Window window; { XDefineCursor(mainDisplay, window, rotateCursor); } void SetRotatingCursor(window) Window window; { XDefineCursor(mainDisplay, window, rotatingCursor); } void SetHoriShearCursor(window) Window window; { XDefineCursor(mainDisplay, window, horiShearCursor); } void SetVertShearCursor(window) Window window; { XDefineCursor(mainDisplay, window, vertShearCursor); } void SetMoveCursor(window) Window window; { XDefineCursor(mainDisplay, window, moveCursor); } void SetHyperSpaceCursor(window) Window window; { XDefineCursor(mainDisplay, window, hyperSpaceCursor); } void SetFloodFillCursor(window) Window window; { XDefineCursor(mainDisplay, window, floodCursor); } void SetDripCursor(window) Window window; { XDefineCursor(mainDisplay, window, dripCursor); } void SetHandCursor(window) Window window; { XDefineCursor(mainDisplay, window, handCursor); } void SetDefaultCursor(window) Window window; { if (!PRTGIF || cmdLineOpenDisplay) { XDefineCursor(mainDisplay, window, defaultCursor); if (window == mainWindow && watchCursorOnMainWindow) { watchCursorOnMainWindow = FALSE; } } } void ShowCursor() { if (curChoice == DRAWTEXT) { SetTextCursor(drawWindow); } else if (curChoice == NOTHING) { SetDefaultCursor(drawWindow); } else if (curChoice == FREEHAND) { SetFreeHandCursor(drawWindow); } else if (curChoice == VERTEXMODE) { SetVertexCursor(drawWindow); } else if (curChoice == ROTATEMODE) { SetRotateCursor(drawWindow); } else { SetDrawCursor(drawWindow); } } void CreateCursor() { int i; XGCValues values; XColor color, fg_color, bg_color; char *c_ptr; int default_cursor_id=XC_arrow, rotate_shear_cursor_id; int draw_cursor_id, drag_cursor_id, freehand_cursor_id, vertex_cursor_id; textPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)text_cur_bits, text_cur_width, text_cur_height); values.foreground = myFgPixel; values.background = (threeDLook ? myLtGryPixel : myBgPixel); values.fill_style = FillOpaqueStippled; values.stipple = textPixmap; textCursorGC = XCreateGC(mainDisplay, mainWindow, GCForeground | GCBackground | GCFillStyle | GCStipple, &values); XParseColor(mainDisplay, mainColormap, myFgColorStr, &fg_color); XAllocColor(mainDisplay, mainColormap, &fg_color); XParseColor(mainDisplay, mainColormap, myBgColorStr, &bg_color); XAllocColor(mainDisplay, mainColormap, &bg_color); textCursor = XCreateFontCursor(mainDisplay, XC_xterm); cornerCursor = XCreateFontCursor(mainDisplay, XC_ul_angle); watchCursor = XCreateFontCursor(mainDisplay, XC_watch); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DefaultCursor")) != NULL) { for (i = 0; *cursorName[i] != '\0'; i++) { if (strcmp(c_ptr, cursorName[i]) == 0) { default_cursor_id = cursorID[i]; break; } } if (*cursorName[i] == '\0') { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "DefaultCursor", c_ptr, cursorName[default_cursor_id>>1]); fprintf(stderr, "\n"); } } defaultCursor = XCreateFontCursor(mainDisplay, default_cursor_id); draw_cursor_id = default_cursor_id; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DrawCursor")) != NULL) { for (i = 0; *cursorName[i] != '\0'; i++) { if (strcmp(c_ptr, cursorName[i]) == 0) { draw_cursor_id = cursorID[i]; break; } } if (*cursorName[i] == '\0') { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "DrawCursor", c_ptr, cursorName[draw_cursor_id>>1]); fprintf(stderr, "\n"); } } drawCursor = XCreateFontCursor(mainDisplay, draw_cursor_id); drag_cursor_id = XC_hand2; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DragCursor")) != NULL) { for (i = 0; *cursorName[i] != '\0'; i++) { if (strcmp(c_ptr, cursorName[i]) == 0) { drag_cursor_id = cursorID[i]; break; } } if (*cursorName[i] == '\0') { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "DragCursor", c_ptr, cursorName[drag_cursor_id>>1]); fprintf(stderr, "\n"); } } handCursor = XCreateFontCursor(mainDisplay, drag_cursor_id); freehand_cursor_id = XC_pencil; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"FreeHandCursor")) != NULL) { for (i = 0; *cursorName[i] != '\0'; i++) { if (strcmp(c_ptr, cursorName[i]) == 0) { freehand_cursor_id = cursorID[i]; break; } } if (*cursorName[i] == '\0') { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "FreeHandCursor", c_ptr, cursorName[freehand_cursor_id>>1]); fprintf(stderr, "\n"); } } freehandCursor = XCreateFontCursor(mainDisplay, freehand_cursor_id); vertex_cursor_id = XC_plus; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"VertexCursor")) != NULL) { for (i = 0; *cursorName[i] != '\0'; i++) { if (strcmp(c_ptr, cursorName[i]) == 0) { vertex_cursor_id = cursorID[i]; break; } } if (*cursorName[i] == '\0') { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "VertexCursor", c_ptr, cursorName[vertex_cursor_id>>1]); fprintf(stderr, "\n"); } } vertexCursor = XCreateFontCursor(mainDisplay, vertex_cursor_id); rotate_shear_cursor_id = XC_crosshair; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"RotateCursor")) != NULL) { for (i = 0; *cursorName[i] != '\0'; i++) { if (strcmp(c_ptr, cursorName[i]) == 0) { rotate_shear_cursor_id = cursorID[i]; break; } } if (*cursorName[i] == '\0') { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "RotateCursor", c_ptr, cursorName[rotate_shear_cursor_id>>1]); fprintf(stderr, "\n"); } } rotateCursor = XCreateFontCursor(mainDisplay, rotate_shear_cursor_id); rotatingCursor = XCreateFontCursor(mainDisplay, XC_exchange); horiShearCursor = XCreateFontCursor(mainDisplay, XC_sb_h_double_arrow); vertShearCursor = XCreateFontCursor(mainDisplay, XC_sb_v_double_arrow); moveCursor = XCreateFontCursor(mainDisplay, XC_fleur); XRecolorCursor(mainDisplay, textCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, cornerCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, handCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, watchCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, defaultCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, drawCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, freehandCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, vertexCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, rotateCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, rotatingCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, horiShearCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, vertShearCursor, &fg_color, &bg_color); XRecolorCursor(mainDisplay, moveCursor, &fg_color, &bg_color); nullPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)null_bits, null_width, null_height); nullMaskPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)nullmask_bits, nullmask_width, nullmask_height); nullCursor = XCreatePixmapCursor(mainDisplay, nullPixmap, nullMaskPixmap, &color, &color, 7, 0); hyperSpacePixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)helphand_bits, helphand_width, helphand_height); hyperSpaceMaskPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)hhand_mk_bits, hhand_mk_width, hhand_mk_height); hyperSpaceCursor = XCreatePixmapCursor(mainDisplay, hyperSpacePixmap, hyperSpaceMaskPixmap, &fg_color, &bg_color, 5, 1); XRecolorCursor(mainDisplay, hyperSpaceCursor, &fg_color, &bg_color); magPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)mag_bits, mag_width, mag_height); magMaskPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)mag_mask_bits, mag_mask_width, mag_mask_height); magCursor = XCreatePixmapCursor(mainDisplay, magPixmap, magMaskPixmap, &fg_color, &bg_color, 8, 8); floodPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)flood_bits, flood_width, flood_height); floodMaskPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)flood_mk_bits, flood_mk_width, flood_mk_height); floodCursor = XCreatePixmapCursor(mainDisplay, floodPixmap, floodMaskPixmap, &fg_color, &bg_color, 9, 18); dripPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)drip_bits, drip_width, drip_height); dripMaskPixmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char *)drip_msk_bits, drip_msk_width, drip_msk_height); dripCursor = XCreatePixmapCursor(mainDisplay, dripPixmap, dripMaskPixmap, &fg_color, &bg_color, 10, 18); XRecolorCursor(mainDisplay, hyperSpaceCursor, &fg_color, &bg_color); } void PutCursor(window, x, y, foreground) Window window; int x, y, foreground; { XGCValues values; values.foreground = foreground; values.ts_x_origin = x; values.ts_y_origin = y; XChangeGC(mainDisplay, textCursorGC, GCForeground | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, window, textCursorGC, x, y, text_cur_width, text_cur_height); } void CleanUpCursors() { XFreePixmap(mainDisplay, textPixmap); XFreeGC(mainDisplay, textCursorGC); XFreeCursor(mainDisplay, textCursor); XFreeCursor(mainDisplay, cornerCursor); XFreeCursor(mainDisplay, handCursor); XFreeCursor(mainDisplay, defaultCursor); XFreeCursor(mainDisplay, watchCursor); XFreeCursor(mainDisplay, drawCursor); XFreeCursor(mainDisplay, freehandCursor); XFreeCursor(mainDisplay, vertexCursor); XFreeCursor(mainDisplay, rotateCursor); XFreeCursor(mainDisplay, rotatingCursor); XFreeCursor(mainDisplay, horiShearCursor); XFreeCursor(mainDisplay, vertShearCursor); XFreeCursor(mainDisplay, moveCursor); XFreeCursor(mainDisplay, hyperSpaceCursor); XFreeCursor(mainDisplay, magCursor); XFreeCursor(mainDisplay, floodCursor); XFreeCursor(mainDisplay, dripCursor); XFreePixmap(mainDisplay, nullPixmap); XFreePixmap(mainDisplay, nullMaskPixmap); XFreeCursor(mainDisplay, nullCursor); XFreePixmap(mainDisplay, hyperSpacePixmap); XFreePixmap(mainDisplay, hyperSpaceMaskPixmap); XFreePixmap(mainDisplay, magPixmap); XFreePixmap(mainDisplay, magMaskPixmap); XFreePixmap(mainDisplay, floodPixmap); XFreePixmap(mainDisplay, floodMaskPixmap); XFreePixmap(mainDisplay, dripPixmap); XFreePixmap(mainDisplay, dripMaskPixmap); } Cursor NewFontCursor(cursor_name) char *cursor_name; { register int i; for (i = 0; *cursorName[i] != '\0'; i++) { if (strcmp(cursor_name, cursorName[i]) == 0) { return XCreateFontCursor(mainDisplay, cursorID[i]); } } return (Cursor)0; } void SetWindowCursor(window, cursor) Window window; Cursor cursor; { XDefineCursor(mainDisplay, window, cursor); } void DeleteFontCursor(cursor) Cursor cursor; { if (handCursor != (Cursor)0) XFreeCursor(mainDisplay, cursor); } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Imakefile.tgwb�����������������������������������������������������������������������0000644�0000764�0000764�00000000300�11602233311�015527� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������This file is obsolete. Please see README.tgwb regarding how to build tgwb. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Imakefile.tgwb,v 1.1 2004/06/18 23:21:01 william Exp $ XCOMM ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tidget.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000052436�11602233313�014423� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tidget.c,v 1.8 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TIDGET_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "tidget.h" #include "font.e" #include "msg.e" #include "raster.e" #include "setup.e" #include "tdgtbase.e" #include "tdgtbmpl.e" #include "tdgtbrow.e" #include "tdgtbtn.e" #include "tdgtdraw.e" #include "tdgtlist.e" #include "tdgtmsg.e" #include "tdgtsedt.e" #include "text.e" #include "tidget.e" #include "util.e" TidgetManager gTidgetManager; /* --------------------- TidgetWindowNotify --------------------- */ void TidgetWindowNotify(win, ctl_id, nf_type, nf_arg, nf_arg2) Window win; int ctl_id, nf_type, nf_arg, nf_arg2; { XClientMessageEvent client_ev; memset(&client_ev, 0, sizeof(XClientMessageEvent)); client_ev.type = ClientMessage; client_ev.window = win; client_ev.message_type = gTidgetManager.notify_atom; client_ev.format = 32; client_ev.data.l[0] = (long)(TDGT_NOTIFY & 0x0ffffffff); client_ev.data.l[1] = (long)(ctl_id & 0x0ffffffff); client_ev.data.l[2] = (long)(nf_type & 0x0ffffffff); client_ev.data.l[3] = (long)(nf_arg & 0x0ffffffff); client_ev.data.l[4] = (long)(nf_arg2 & 0x0ffffffff); XSendEvent(mainDisplay, win, False, NoEventMask, (XEvent*)&client_ev); } /* --------------------- TidgetNotify --------------------- */ void TidgetNotify(pti, ctl_id, nf_type, nf_arg, nf_arg2) TidgetInfo *pti; /* referring to a base tidget */ int ctl_id, nf_type, nf_arg, nf_arg2; { TidgetWindowNotify(pti->tci.win, ctl_id, nf_type, nf_arg, nf_arg2); } /* --------------------- TidgetControlNotify --------------------- */ static void DoTidgetControlNotify(pti, ctl_id, nf_type, nf_arg, nf_arg2) TidgetInfo *pti; /* referring to tidget, e.g., a button */ int ctl_id, nf_type, nf_arg, nf_arg2; { if (pti->tci.parent_tidgetinfo == NULL) { TidgetWindowNotify(pti->tci.parent_win, ctl_id, nf_type, nf_arg, nf_arg2); } else if (pti->tci.parent_tidgetinfo->type == TIDGET_TYPE_BASE) { TidgetWindowNotify(pti->tci.parent_win, ctl_id, nf_type, nf_arg, nf_arg2); } else { DoTidgetControlNotify(pti->tci.parent_tidgetinfo, ctl_id, nf_type, nf_arg, nf_arg2); } } void TidgetControlNotify(pti, nf_type, nf_arg, nf_arg2) TidgetInfo *pti; /* referring to tidget, e.g., a button */ int nf_type, nf_arg, nf_arg2; { DoTidgetControlNotify(pti, pti->tci.ctl_id, nf_type, nf_arg, nf_arg2); } /* --------------------- IsTdgtWindowNotifyEvent --------------------- */ int IsTdgtWindowNotifyEvent(win, pXEv, pTdgtNtfy) Window win; XEvent *pXEv; TdgtNtfy *pTdgtNtfy; { if (pXEv->xany.window == win && pXEv->type == ClientMessage) { if (pXEv->xclient.message_type == gTidgetManager.notify_atom && pXEv->xclient.format == 32 && pXEv->xclient.data.l[0] == TDGT_NOTIFY) { if (pTdgtNtfy != NULL) { memset(pTdgtNtfy, 0, sizeof(TdgtNtfy)); pTdgtNtfy->ctl_id = (int)(pXEv->xclient.data.l[1]); pTdgtNtfy->nf_type = (int)(pXEv->xclient.data.l[2]); pTdgtNtfy->nf_arg = (int)(pXEv->xclient.data.l[3]); pTdgtNtfy->nf_arg2 = (int)(pXEv->xclient.data.l[4]); } return TRUE; } } return FALSE; } /* --------------------- IsTdgtNotifyEvent --------------------- */ int IsTdgtNotifyEvent(pti, pXEv, pTdgtNtfy) TidgetInfo *pti; /* referring to a base tidget */ XEvent *pXEv; TdgtNtfy *pTdgtNtfy; { return IsTdgtWindowNotifyEvent(pti->tci.win, pXEv, pTdgtNtfy); } /* --------------------- TidgetDrawFocusRect --------------------- */ void TidgetDrawFocusRect(pti, pswi) TidgetInfo *pti; SimpleWinInfo *pswi; { Window win=pti->tci.win; XGCValues values; int x=pswi->x, y=pswi->y, w=pswi->w, h=pswi->h; XSetDashes(mainDisplay, revDefaultGC, 0, dashList[8], dashListLength[8]); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); XDrawRectangle(mainDisplay, win, revDefaultGC, x-1, y-1, w+2, h+2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } /* --------------------- RedrawTidget --------------------- */ void RedrawTidget(pti) TidgetInfo *pti; { if (pti->tci.pf_redraw_callback != NULL) { if (!pti->tci.redraw_disabled) { (pti->tci.pf_redraw_callback)(pti); TidgetSetDirty(pti, FALSE); } } } /* --------------------- TidgetEventHandler --------------------- */ int TidgetEventHandler(pti, input, pti_handler_tidget) /* * Returns TRUE if the event has been handled. */ TidgetInfo *pti, *pti_handler_tidget; XEvent *input; { if (pti == pti_handler_tidget) { if (pti->tci.pf_ev_handler_callback != NULL) { (pti->tci.pf_ev_handler_callback)(pti, input, pti_handler_tidget); } return TRUE; } /* iterate through tidget-based child windows */ if (pti->tci.can_have_children) { CVListElem *pElem=NULL; for (pElem=ListFirst(&pti->tci.clist); pElem != NULL; pElem=ListNext(&pti->tci.clist, pElem)) { TidgetInfo *child_pti=(TidgetInfo*)(pElem->obj); if (TidgetEventHandler(child_pti, input, pti_handler_tidget)) { return TRUE; } } } return FALSE; } /* --------------------- TestAndHandleEventForTidget --------------------- */ #ifdef NOT_DEFINED int TestAndHandleEventForTidget(pti, input) TidgetInfo *pti; XEvent *input; { if (input->xany.window == pti->tci.win) { if (pti->tci.pf_ev_handler_callback != NULL) { (pti->tci.pf_ev_handler_callback)(pti, input); } return TRUE; } /* * If a tidget has non-tidget child windows, then it should * have an is_event callback function. */ if (pti->tci.pf_is_event_callback != NULL && (pti->tci.pf_is_event_callback)(pti, input)) { /* gets here if the tidget has other non-tidget child windows */ if (pti->tci.pf_ev_handler_callback != NULL) { (pti->tci.pf_ev_handler_callback)(pti, input); } return TRUE; } /* iterate through tidget-based child windows */ if (pti->tci.can_have_children) { CVListElem *pElem=NULL; for (pElem=ListFirst(&pti->tci.clist); pElem != NULL; pElem=ListNext(&pti->tci.clist, pElem)) { TidgetInfo *child_pti=(TidgetInfo*)(pElem->obj); if (TestAndHandleEventForTidget(child_pti, input)) { return TRUE; } } } return FALSE; } #endif /* NOT_DEFINED */ /* --------------------- IsTidgetEvent --------------------- */ int IsTidgetEvent(pti, input, ppti_handler_tidget_return) TidgetInfo *pti, **ppti_handler_tidget_return; XEvent *input; { if (input->xany.window == pti->tci.win) { *ppti_handler_tidget_return = pti; return TRUE; } /* * If a tidget has non-tidget child windows, then it should * have an is_event callback function. */ if (pti->tci.pf_is_event_callback != NULL && (pti->tci.pf_is_event_callback)(pti, input, ppti_handler_tidget_return)) { return TRUE; } /* iterate through tidget-based child windows */ if (pti->tci.can_have_children) { CVListElem *pElem=NULL; for (pElem=ListFirst(&pti->tci.clist); pElem != NULL; pElem=ListNext(&pti->tci.clist, pElem)) { TidgetInfo *child_pti=(TidgetInfo*)(pElem->obj); if (IsTidgetEvent(child_pti, input, ppti_handler_tidget_return)) { return TRUE; } } } return FALSE; } /* --------------------- DestroyTidget --------------------- */ void DestroyTidget(ppti) TidgetInfo **ppti; { TidgetInfo *pti=(*ppti); if (pti->tci.parent_tidgetinfo == NULL) { CVListElem *pElem=ListFind(&gTidgetManager.toplevel_tidgets, pti, NULL); if (pElem == NULL) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "Cannot find a TidgetInfo in DestroyTidget().\n"); #endif /* _TGIF_DBG */ } else { ListUnlink(&gTidgetManager.toplevel_tidgets, pElem); free(pElem); } } if (pti->tci.pf_destroy_callback != NULL) { (pti->tci.pf_destroy_callback)(pti); } free(pti); *ppti = NULL; } /* --------------------- SetTidgetInfoBasic --------------------- */ void SetTidgetInfoBasic(pti, tidget_type, tidget, parent_win, x, y, w, h, h_pad, v_pad, state, caption) TidgetInfo *pti; int tidget_type, x, y, w, h, h_pad, v_pad, state; void *tidget; Window parent_win; char *caption; { pti->type = tidget_type; pti->tidget = tidget; pti->tci.parent_win = parent_win; pti->tci.win_info.x = x; pti->tci.win_info.y = y; pti->tci.win_info.w = w; pti->tci.win_info.h = h; pti->tci.h_pad = h_pad; pti->tci.v_pad = v_pad; pti->tci.content_w = w-(windowPadding<<1)-(h_pad<<1); pti->tci.content_h = h-(windowPadding<<1)-(v_pad<<1); pti->tci.state = state; if (caption != NULL) { DynStrSet(&(pti->tci.dyn_str), caption); } } /* --------------------- TidgetCanHaveChildren --------------------- */ void TidgetCanHaveChildren(pti, can_have_children) TidgetInfo *pti; int can_have_children; { pti->tci.can_have_children = can_have_children; } /* --------------------- TidgetSetCallbacks --------------------- */ void TidgetSetCallbacks(pti, pf_redraw_callback, pf_ev_handler_callback, pf_is_event_callback, pf_destroy_callback, pf_map_callback, pf_moveresize_callback, pf_sendcmd_callback) TidgetInfo *pti; TidgetRedrawCallbackFunc *pf_redraw_callback; TidgetEvHandlerCallbackFunc *pf_ev_handler_callback; TidgetIsEventCallbackFunc *pf_is_event_callback; TidgetDestroyCallbackFunc *pf_destroy_callback; TidgetMapCallbackFunc *pf_map_callback; TidgetMoveResizeCallbackFunc *pf_moveresize_callback; TidgetSendCmdCallbackFunc *pf_sendcmd_callback; { pti->tci.pf_redraw_callback = pf_redraw_callback; pti->tci.pf_ev_handler_callback = pf_ev_handler_callback; pti->tci.pf_is_event_callback = pf_is_event_callback; pti->tci.pf_destroy_callback = pf_destroy_callback; pti->tci.pf_map_callback = pf_map_callback; pti->tci.pf_moveresize_callback = pf_moveresize_callback; pti->tci.pf_sendcmd_callback = pf_sendcmd_callback; } /* --------------------- NewTidgetInfo --------------------- */ TidgetInfo *NewTidgetInfo(parent_tidgetinfo, type, tidget, ctl_id, userdata) TidgetInfo *parent_tidgetinfo; int type, ctl_id; void *tidget; void *userdata; { TidgetInfo *pti=(TidgetInfo*)malloc(sizeof(TidgetInfo)); if (pti == NULL) FailAllocMessage(); memset(pti, 0, sizeof(TidgetInfo)); pti->type = type; pti->tidget = tidget; pti->userdata = userdata; pti->tci.ctl_id = ctl_id; pti->tci.parent_tidgetinfo = parent_tidgetinfo; CVListInit(&pti->tci.clist); if (parent_tidgetinfo == NULL) { ListAppend(&gTidgetManager.toplevel_tidgets, pti); } else if (parent_tidgetinfo->type == TIDGET_TYPE_BASE && parent_tidgetinfo->tidget != NULL) { if (!TdgtBaseAddChild((TdgtBase*)(parent_tidgetinfo->tidget), pti)) { /* this should not happen */ } } return pti; } /* --------------------- MapTidget --------------------- */ void MapTidget(pti) TidgetInfo *pti; { if (pti->tci.pf_map_callback != NULL) { (pti->tci.pf_map_callback)(pti); } } /* --------------------- TidgetMoveResize --------------------- */ void TidgetMoveResize(pti, x, y, w, h) TidgetInfo *pti; int x, y, w, h; { if (pti->tci.pf_moveresize_callback != NULL) { (pti->tci.pf_moveresize_callback)(pti, x, y, w, h); } } /* --------------------- ResetTidgetCommon --------------------- */ void ResetTidgetCommon(ptci) TidgetCommonInfo *ptci; { TidgetInfo *saved_parent_tidgetinfo=NULL; if (ptci == NULL) return; saved_parent_tidgetinfo = ptci->parent_tidgetinfo; XDestroyWindow(mainDisplay, ptci->win); FreeDynStrBuf(&(ptci->dyn_str)); memset(ptci, 0, sizeof(TidgetCommonInfo)); ptci->parent_tidgetinfo = saved_parent_tidgetinfo; CVListInit(&ptci->clist); } /* --------------------- TidgetSendCmd --------------------- */ int TidgetSendCmd(pti, cmd_type, cmd_arg, pv_cmd_userdata) TidgetInfo *pti; int cmd_type, cmd_arg; void *pv_cmd_userdata; { if (pti->tci.pf_sendcmd_callback != NULL) { return (pti->tci.pf_sendcmd_callback)(pti, cmd_type, cmd_arg, pv_cmd_userdata); } return FALSE; } /* --------------------- TidgetEnableRedraw --------------------- */ int TidgetDisableRedraw(pti, redraw_disabled) TidgetInfo *pti; int redraw_disabled; { int prev_redraw_disabled=(pti->tci.redraw_disabled); pti->tci.redraw_disabled = redraw_disabled; if (!redraw_disabled && prev_redraw_disabled && pti->tci.dirty) { RedrawTidget(pti); } return prev_redraw_disabled; } /* --------------------- TidgetSetDirty --------------------- */ int TidgetSetDirty(pti, dirty) TidgetInfo *pti; int dirty; { int prev_dirty=(pti->tci.dirty); pti->tci.dirty = dirty; return prev_dirty; } /* --------------------- TidgetHasFocus --------------------- */ static int gnTidgetHasFocus=FALSE; int TidgetHasFocus() { return gnTidgetHasFocus; } /* --------------------- TidgetSetHasFocus --------------------- */ int TidgetSetHasFocus(has_focus) int has_focus; { int prev_has_focus=gnTidgetHasFocus; gnTidgetHasFocus = has_focus; return prev_has_focus; } /* --------------------- TidgetGetFocusWindow --------------------- */ static Window gFocusWindow=None; Window TidgetGetFocusWindow() { return gFocusWindow; } /* --------------------- TidgetSetFocusWindow --------------------- */ Window TidgetSetFocusWindow(win) Window win; { Window prev_win=gFocusWindow; gFocusWindow = win; return prev_win; } /* --------------------- TidgetIsFocus --------------------- */ int TidgetIsFocus(pti) TidgetInfo *pti; { if (gFocusWindow == None) return FALSE; return (pti->tci.win == gFocusWindow); } /* --------------------- TidgetGetFontInfo --------------------- */ void TidgetGetFontInfo(pnFontIndex, pnSzUnit) int *pnFontIndex, *pnSzUnit; { if (pnFontIndex != NULL) *pnFontIndex = FONT_HEL; if (pnSzUnit != NULL) *pnSzUnit = FontSizeToSzUnit(14); } /* --------------------- TidgetGetFontInfoGivenStyle --------------------- */ void TidgetGetFontInfoGivenStyle(font_style, pp_font_ptr, pn_font_width, pn_font_height, pn_font_asc, pn_font_des) int font_style, *pn_font_width, *pn_font_height, *pn_font_asc, *pn_font_des; XFontStruct **pp_font_ptr; { int font_width=defaultFontWidth; int font_height=defaultFontHeight; int font_asc=defaultFontAsc; int font_des=defaultFontDes; XFontStruct *font_ptr=defaultFontPtr; if (msgFontSet != NULL || msgFontPtr != NULL) { font_width = msgFontWidth; font_height = msgFontHeight; font_asc = msgFontAsc; font_des = msgFontDes; font_ptr = msgFontPtr; } switch (font_style) { case STYLE_NR: if (msgFontSet != NULL || msgFontPtr != NULL) { font_width = msgFontWidth; font_height = msgFontHeight; font_asc = msgFontAsc; font_des = msgFontDes; font_ptr = msgFontPtr; } break; case STYLE_BR: if (boldMsgFontSet != NULL || boldMsgFontPtr != NULL) { font_width = boldMsgFontWidth; font_height = boldMsgFontHeight; font_asc = boldMsgFontAsc; font_des = boldMsgFontDes; font_ptr = boldMsgFontPtr; } break; case STYLE_NI: if (italicMsgFontSet != NULL || italicMsgFontPtr != NULL) { font_width = italicMsgFontWidth; font_height = italicMsgFontHeight; font_asc = italicMsgFontAsc; font_des = italicMsgFontDes; font_ptr = italicMsgFontPtr; } break; case STYLE_BI: if (boldItalicMsgFontSet != NULL || boldItalicMsgFontPtr != NULL) { font_width = boldItalicMsgFontWidth; font_height = boldItalicMsgFontHeight; font_asc = boldItalicMsgFontAsc; font_des = boldItalicMsgFontDes; font_ptr = boldItalicMsgFontPtr; } break; } if (pp_font_ptr != NULL) *pp_font_ptr = font_ptr; if (pn_font_width != NULL) *pn_font_width = font_width; if (pn_font_height != NULL) *pn_font_height = font_height; if (pn_font_asc != NULL) *pn_font_asc = font_asc; if (pn_font_des != NULL) *pn_font_des = font_des; } /* --------------------- TidgetManagerResetGC --------------------- */ void TidgetManagerResetGC() { if (gTidgetManager.gc != NULL) { XGCValues values; values.background = myBgPixel; values.foreground = myFgPixel; values.font = defaultFontPtr->fid; values.fill_style = FillSolid; values.function = GXcopy; values.ts_x_origin = values.ts_y_origin = 0; XChangeGC(mainDisplay, gTidgetManager.gc, GCBackground | GCForeground | GCFont | GCFillStyle | GCFunction | GCTileStipXOrigin | GCTileStipYOrigin, &values); } } /* --------------------- TidgetManagerHandleEvent --------------------- */ int TidgetManagerHandleEvent(pXEv) /* return TRUE if the event is handled */ XEvent *pXEv; { CVListElem *pElem=NULL; for (pElem=ListFirst(&gTidgetManager.toplevel_tidgets); pElem != NULL; pElem=ListNext(&gTidgetManager.toplevel_tidgets, pElem)) { TidgetInfo *pti=(TidgetInfo*)(pElem->obj); if (pti != NULL) { TidgetInfo *handling_pti=NULL; if (IsTidgetEvent(pti, pXEv, &handling_pti)) { TidgetEventHandler(pti, pXEv, handling_pti); return TRUE; } } } return FALSE; } /* ------------------ TidgetManagerHandleAllKeyPressEvent ------------------ */ int TidgetManagerHandleAllKeyPressEvent(pXEv) /* return TRUE if the event is handled */ XEvent *pXEv; { TidgetInfo *pti=(gTidgetManager.key_press_base_tidgetinfo); TdgtBase *pTdgtBase=NULL; if (pti == NULL) return FALSE; if (pti->type != TIDGET_TYPE_BASE) return FALSE; pTdgtBase = pti->tidget; if (pTdgtBase == NULL) return FALSE; if (pTdgtBase->pf_key_press_ev_handler_callback != NULL) { return (pTdgtBase->pf_key_press_ev_handler_callback)(pTdgtBase, pXEv); } return FALSE; } /* ------------------- TidgetManagerWantAllKeyPressEvents ------------------- */ int TidgetManagerWantAllKeyPressEvents() { return gTidgetManager.want_all_key_press_events; } /* ----------------- TidgetManagerSetWantAllKeyPressEvents ----------------- */ int TidgetManagerSetWantAllKeyPressEvents(pti, want_all_key_press_events) TidgetInfo *pti; int want_all_key_press_events; { int prev_want_all_key_press_events=gTidgetManager.want_all_key_press_events; gTidgetManager.want_all_key_press_events = want_all_key_press_events; gTidgetManager.key_press_base_tidgetinfo = pti; return prev_want_all_key_press_events; } /* --------------------- Init & Clean Up --------------------- */ int InitTidget() { int ok=TRUE; XGCValues values; memset(&gTidgetManager, 0, sizeof(TidgetManager)); CVListInit(&gTidgetManager.toplevel_tidgets); if (mainDisplay != NULL) { values.background = myBgPixel; values.foreground = myFgPixel; values.fill_style = FillSolid; values.function = GXcopy; gTidgetManager.gc = XCreateGC(mainDisplay, mainWindow, GCBackground | GCForeground | GCFillStyle | GCFunction, &values); gTidgetManager.notify_atom = XInternAtom(mainDisplay, "TDGT_NOTIFY", False); } if (!InitTdgtBase()) ok = FALSE; if (!InitTdgtList()) ok = FALSE; if (!InitTdgtBtn()) ok = FALSE; if (!InitTdgtDraw()) ok = FALSE; if (!InitTdgtMsg()) ok = FALSE; if (!InitTdgtBtnRow()) ok = FALSE; if (!InitTdgtBmpList()) ok = FALSE; if (!InitTdgtSmplEdit()) ok = FALSE; return ok; } void CleanUpTidget() { CVListElem *pElem=NULL; if (ListLength(&gTidgetManager.toplevel_tidgets) > 0) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "gTidgetManager.toplevel_tidgets is not empty. %1d left.\n", ListLength(&gTidgetManager.toplevel_tidgets)); #endif /* _TGIF_DBG */ for (pElem=ListFirst(&gTidgetManager.toplevel_tidgets); pElem != NULL; pElem=ListNext(&gTidgetManager.toplevel_tidgets, pElem)) { } ListUnlinkAll(&gTidgetManager.toplevel_tidgets); } CleanUpTdgtBase(); CleanUpTdgtList(); CleanUpTdgtBtn(); CleanUpTdgtDraw(); CleanUpTdgtMsg(); CleanUpTdgtBtnRow(); CleanUpTdgtBmpList(); CleanUpTdgtSmplEdit(); if (gTidgetManager.gc != NULL) { XFreeGC(mainDisplay, gTidgetManager.gc); gTidgetManager.gc = NULL; } memset(&gTidgetManager, 0, sizeof(TidgetManager)); } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tdgtlist.e���������������������������������������������������������������������������0000644�0000764�0000764�00000005560�11602233313�014777� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtlist.e,v 1.6 2011/05/16 16:22:00 william Exp $ */ #ifndef _TDGTLIST_E_ #define _TDGTLIST_E_ #include "tidget.h" #include "list.e" #define TDGTLIST_DEF_H_PAD 1 #define TDGTLIST_DEF_V_PAD 1 typedef struct tagListInfo { char **entries; /* this is a cache, updated by TdgtListUpdateEntries() */ DspList *dsp_ptr; int first_index; int marked_index; int num_visible_lines; struct CheckArrayRec *p_check_array; CVList list; } ListInfo; typedef struct tagTdgtList { TidgetInfo *pti; Window dsp_win, scr_win; SimpleWinInfo dsp_win_info, scr_win_info; int can_select; /* if FALSE, cannot select an item */ int multicolor; int auto_scroll_on_insert; int scr_area_h; int scr_dir; /* temporary variable, which direction it's scrolling */ ListInfo list_info; } TdgtList; typedef struct tagListItemInfo { char nick_name[MAXSTRING]; int color_index, font_style; char *buf; } ListItemInfo; #ifdef _INCLUDE_FROM_TDGTLIST_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TDGTLIST_C_*/ extern void TdgtListReset ARGS_DECL((TdgtList*)); extern TdgtList *CreateTdgtList ARGS_DECL((Window parent_win, TidgetInfo *parent_tidgetinfo, int ctl_id, int x, int y, int w, int h_pad, int v_pad, int num_visible_lines, int can_select, int multicolor, int auto_scroll_on_insert)); extern int TdgtListCleanUpEntries ARGS_DECL((TdgtList*)); extern int TdgtListUpdateEntries ARGS_DECL((TdgtList*)); extern int TdgtListScrollToBottom ARGS_DECL((TdgtList*)); extern int TdgtListInsertString ARGS_DECL((TdgtList*, char*)); extern int TdgtListInsertListItemInfo ARGS_DECL((TdgtList*, ListItemInfo*)); extern int TdgtListSetAutoScrollOnInsert ARGS_DECL((TdgtList*, int)); extern int TdgtListGetAutoScrollOnInsert ARGS_DECL((TdgtList*)); extern int InitTdgtList ARGS_DECL((void)); extern void CleanUpTdgtList ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TDGTLIST_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TDGTLIST_C_*/ #endif /*_TDGTLIST_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgisdl.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000004515�11602233313�014426� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgisdl.e,v 1.8 2011/05/16 16:22:00 william Exp $ */ #ifndef _TGISDL_E_ #define _TGISDL_E_ #include "tidget.h" #define TGIS_COLS 16 #define TGIS_ROWS 13 #define ID_INSSYM_DIALOG 101 #define ID_INSSYM_SYM_AREA 102 #define ID_INSSYM_BTN_ADD 103 #define ID_INSSYM_BTN_OK 104 #define ID_INSSYM_BTN_CANCEL 105 typedef struct tagInsertSymbolInfo { int initialized; int mapped; XFontStruct *xfs; GC gc; int font_width, font_asc, font_des, font_height; int padding; int a_symbol_w, a_symbol_h; int pixmap_w, pixmap_h; int something_selected, selected_row, selected_col; int sym_x, sym_y; Pixmap sym_pixmap; Time last_click_time; TidgetInfo *dialogbox_tidgetinfo; } InsertSymbolInfo; extern InsertSymbolInfo gInsertSymbolInfo; #ifdef _INCLUDE_FROM_TGISDL_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TGISDL_C_*/ extern void ShowTdgtInsertSymbolDialogBox ARGS_DECL((void)); extern void HideTdgtInsertSymbolDialogBox ARGS_DECL((void)); extern TidgetInfo *CreateTdgtInsertSymbolDialogBox ARGS_DECL((Display*, Window)); extern void DestroyTdgtInsertSymbolDialogBox ARGS_DECL((Display*, TidgetInfo*)); extern int TdgtInsertSymbolDlgLoop ARGS_DECL((TidgetInfo*)); extern int InitTdgtInsertSymbolDlg ARGS_DECL((void)); extern void CleanUpTdgtInsertSymbolDlg ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TGISDL_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TGISDL_C_*/ #endif /*_TGISDL_E_*/ �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/eq4-epstool.sym����������������������������������������������������������������������0000644�0000764�0000764�00000034646�11602233311�015706� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.43 state(0,37,100.000,0,0,0,8,1,3,1,1,0,0,1,0,1,0,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/eq4-epstool.sym,v 1.1 2004/06/18 23:20:01 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(15,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "White", 65535, 65535, 65535, 65535, 65535, 65535, 1 ]). slideshow_info('',-20,-20). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). dont_reencode("UtopiaFS:FFDingbests:ZapfDingbats"). ps_font_aliases([ "UtopiaFS-Regular=Utopia-Regular", "UtopiaFS-Bold=Utopia-Bold", "UtopiaFS-Italic=Utopia-Italic", "UtopiaFS-BoldItalic=Utopia-BoldItalic" ]). page(1,"LaTeX equation symbol (uses ghostscript's ps2epsi).",1,''). group([ text('#0000ff',224,194,4,0,1,390,69,1039,14,3,0,-1,0,0,2,390,69,0,2,"",0,0,0,0,208,'',[ minilines(390,69,0,2,0,-1,0,[ mini_line(390,14,5,0,2,0,[ str_block(0,107,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,107,14,3,0,-2,0,0,0,0,0, "Make sure that ")]), str_block(0,32,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,32,14,3,0,2,0,0,0,0,0, "latex")]), str_block(0,8,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,8,14,3,0,-3,0,0,0,0,0, ", ")]), str_block(0,38,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,38,14,3,0,1,0,0,0,0,0, "dvips")]), str_block(0,38,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,38,14,3,0,-2,0,0,0,0,0, ", and ")]), str_block(0,50,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,50,14,3,0,2,0,0,0,0,0, "epstool")]), str_block(0,81,14,3,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,81,14,3,0,-2,0,0,0,0,0, " are in your ")]), str_block(0,32,13,5,0,0,0,0,0,[ str_seg('#ff00ff','Courier-Bold',1,80640,32,13,5,0,0,0,0,0,0,0, "PATH")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]), mini_line(370,14,3,0,1,0,[ str_block(0,228,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,228,14,3,0,-3,0,0,0,0,0, "After you instantiate this symbol, ")]), str_block(0,84,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,84,14,3,0,1,0,0,0,0,0, "double-click")]), str_block(0,58,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,58,14,3,0,1,0,0,0,0,0, " it to run")]) ]), mini_line(386,14,5,0,0,0,[ str_block(0,362,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,-3,0,0,0,0,0, "the latex scripts. Afterwards, you can hide/show the ")]), str_block(0,24,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,13,5,0,0,0,0,0,0,0, "eq=")]) ]), mini_line(247,14,3,0,1,0,[ str_block(0,148,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,148,14,3,0,-3,0,0,0,0,0, "attribute by pressing ")]), str_block(0,95,14,3,0,1,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,95,14,3,0,1,0,0,0,0,0, "<Alt><Cntrl>7")]), str_block(0,4,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,4,14,3,0,-1,0,0,0,0,0, ".")]) ]) ])]), text('#0000ff',192,194,1,0,1,19,17,651,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,208,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(3)")]) ]) ])]), text('#0000ff',192,106,1,0,1,19,17,656,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,120,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(2)")]) ]) ])]), text('#0000ff',224,106,5,0,1,433,81,657,14,3,0,-1,0,0,2,433,81,0,2,"",0,0,0,0,120,'',[ minilines(433,81,0,2,0,-1,0,[ mini_line(325,14,3,0,1,0,[ str_block(0,325,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,325,14,3,0,1,0,0,0,0,0, "This version of the LaTeX equation symbol uses")]) ]), mini_line(285,14,3,0,2,0,[ str_block(0,7,14,3,0,2,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,7,14,3,0,2,0,0,0,0,0, "\"")]), str_block(0,50,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,50,14,3,0,2,0,0,0,0,0, "epstool")]), str_block(0,228,14,3,0,1,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,228,14,3,0,1,0,0,0,0,0, "\" to add a preview bitmap to a PS")]) ]), mini_line(354,14,3,0,2,0,[ str_block(0,129,14,3,0,-3,0,0,0,[ str_seg('#ff0000','Helvetica-BoldOblique',3,80640,129,14,3,0,-3,0,0,0,0,0, "file. If want to use ")]), str_block(0,7,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,7,14,3,0,2,0,0,0,0,0, "\"")]), str_block(0,59,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,59,14,3,0,2,0,0,0,0,0, "pstoepsi")]), str_block(0,96,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,96,14,3,0,2,0,0,0,0,0, "\", please use\"")]), str_block(0,56,14,3,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,56,14,3,0,1,0,0,0,0,0, "eq4.sym")]), str_block(0,7,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,7,14,3,0,2,0,0,0,0,0, "\"")]) ]), mini_line(401,14,3,0,2,0,[ str_block(0,195,14,3,0,2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,195,14,3,0,2,0,0,0,0,0, "instead. Information about \"")]), str_block(0,50,14,3,0,2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,80640,50,14,3,0,2,0,0,0,0,0, "epstool")]), str_block(0,156,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,156,14,3,0,1,0,0,0,0,0, "\" can be obtained from")]) ]), mini_line(433,14,3,0,2,0,[ str_block(0,42,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,42,14,3,0,1,0,0,0,0,0, "<URL:")]), str_block(0,378,14,3,0,2,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,378,14,3,0,2,0,0,0,0,0, "http://bourbon.cs.umd.edu:8001/tgif/tools.html#epstool")]), str_block(0,13,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,13,14,3,0,-1,0,0,0,0,0, ">.")]) ]) ])]), text('#0000ff',224,50,3,0,1,362,49,643,14,3,0,-1,0,0,2,362,49,0,1,"",0,0,0,0,64,'',[ minilines(362,49,0,1,0,-1,0,[ mini_line(325,14,3,0,0,0,[ str_block(0,189,14,3,0,-3,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,189,14,3,0,-3,0,0,0,0,0, "Make sure you are running ")]), str_block(0,68,14,3,0,0,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,80640,68,14,3,0,0,0,0,0,0,0, "tgif-4.1.11")]), str_block(0,68,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,68,14,3,0,-1,0,0,0,0,0, " or newer.")]) ]), mini_line(362,14,3,0,1,0,[ str_block(0,362,14,3,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,362,14,3,0,1,0,0,0,0,0, "You can find out what version of tgif you are running")]) ]), mini_line(300,14,3,0,0,0,[ str_block(0,300,14,3,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,300,14,3,0,-1,0,0,0,0,0, "by selecting About() from the Special menu.")]) ]) ])]), text('#0000ff',192,50,1,0,1,19,17,863,14,3,0,0,0,0,2,19,17,0,0,"",0,0,0,0,64,'',[ minilines(19,17,0,0,0,0,0,[ mini_line(19,14,3,0,0,0,[ str_block(0,19,14,3,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,80640,19,14,3,0,0,0,0,0,0,0, "(1)")]) ]) ])]) ], 1058,0,0,[ ]). sym([ polygon('#0000ff','',5,[ 64,132,68,132,68,128,64,128,64,132],0,1,0,0,212,0,0,0,0,0,'1',0, "00",[ ]) ], 1117,0,0,[ attr("footer=", "", 0, 1, 0, text('#ff00ff',64,-21,3,0,1,112,54,613,13,5,0,0,0,0,2,112,54,0,0,"",0,0,0,0,-8,'',[ minilines(112,54,0,0,0,0,0,[ mini_line(56,13,5,0,0,0,[ str_block(0,56,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,56,13,5,0,0,0,0,0,0,0, "footer=")]) ]), mini_line(8,13,5,0,0,0,[ str_block(0,8,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,8,13,5,0,-1,0,0,0,0,0, "%")]) ]), mini_line(112,13,5,0,0,0,[ str_block(0,112,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,112,13,5,0,-1,0,0,0,0,0, "\\end{document}")]) ]) ])])), attr("header=", "", 0, 1, 0, text('#ff00ff',240,-21,11,0,1,240,198,608,13,5,0,0,0,0,2,240,198,0,0,"",0,0,0,0,-8,'',[ minilines(240,198,0,0,0,0,0,[ mini_line(56,13,5,0,0,0,[ str_block(0,56,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,56,13,5,0,0,0,0,0,0,0, "header=")]) ]), mini_line(232,13,5,0,0,0,[ str_block(0,232,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,232,13,5,0,-1,0,0,0,0,0, "\\documentstyle[12pt]{article}")]) ]), mini_line(144,13,5,0,0,0,[ str_block(0,144,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,5,0,0,0,0,0,0,0, "\\oddsidemargin=0in")]) ]), mini_line(128,13,5,0,0,0,[ str_block(0,128,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,13,5,0,0,0,0,0,0,0, "\\textwidth=6.5in")]) ]), mini_line(112,13,5,0,0,0,[ str_block(0,112,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,112,13,5,0,0,0,0,0,0,0, "\\topmargin=0in")]) ]), mini_line(136,13,5,0,0,0,[ str_block(0,136,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,136,13,5,0,-1,0,0,0,0,0, "\\textheight=609pt")]) ]), mini_line(104,13,5,0,0,0,[ str_block(0,104,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,104,13,5,0,-1,0,0,0,0,0, "\\parskip=14pt")]) ]), mini_line(240,13,5,0,0,0,[ str_block(0,240,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,240,13,5,0,-1,0,0,0,0,0, "\\setlength{\\unitlength}{0.5cm}")]) ]), mini_line(136,13,5,0,0,0,[ str_block(0,136,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,136,13,5,0,-1,0,0,0,0,0, "\\pagestyle{empty}")]) ]), mini_line(128,13,5,0,0,0,[ str_block(0,128,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,128,13,5,0,-1,0,0,0,0,0, "\\begin{document}")]) ]), mini_line(8,13,5,0,0,0,[ str_block(0,8,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,8,13,5,0,-1,0,0,0,0,0, "%")]) ]) ])])), attr("exec=", "", 0, 1, 0, text('blue',64,-272,8,0,1,424,144,23,13,5,0,0,0,0,2,424,144,0,0,"",0,0,0,0,-259,'',[ minilines(424,144,0,0,0,0,0,[ mini_line(40,13,5,0,0,0,[ str_block(0,40,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,40,13,5,0,0,0,0,0,0,0, "exec=")]) ]), mini_line(336,13,5,0,0,0,[ str_block(0,336,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,336,13,5,0,-2,0,0,0,0,0, " mktemp(\"/tmp/TgifXXXXXX\",\"file_name\");")]) ]), mini_line(416,13,5,0,0,0,[ str_block(0,416,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,416,13,5,0,-2,0,0,0,0,0, " write_attr_into_file(header,\"$(file_name).tex\");")]) ]), mini_line(392,13,5,0,0,0,[ str_block(0,392,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,392,13,5,0,-2,0,0,0,0,0, " append_attr_into_file(eq,\"$(file_name).tex\");")]) ]), mini_line(424,13,5,0,0,0,[ str_block(0,424,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,424,13,5,0,-2,0,0,0,0,0, " append_attr_into_file(footer,\"$(file_name).tex\");")]) ]), mini_line(144,13,5,0,0,0,[ str_block(0,144,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,5,0,-2,0,0,0,0,0, " launch(\"cmd\");")]) ]), mini_line(328,13,5,0,0,0,[ str_block(0,328,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,328,13,5,0,-2,0,0,0,0,0, " update_eps_child(\"$(file_name).eps\");")]) ]), mini_line(168,13,5,0,0,0,[ str_block(0,168,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,168,13,5,0,-2,0,0,0,0,0, " launch(\"cleanup\")")]) ]) ])])), attr("cmd=", "", 0, 1, 0, text('blue',64,-152,5,0,1,640,90,27,13,5,0,0,0,0,2,640,90,0,0,"",0,0,0,0,-139,'',[ minilines(640,90,0,0,0,0,0,[ mini_line(32,13,5,0,0,0,[ str_block(0,32,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,32,13,5,0,0,0,0,0,0,0, "cmd=")]) ]), mini_line(96,13,5,0,0,0,[ str_block(0,96,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,96,13,5,0,-2,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(408,13,5,0,0,0,[ str_block(0,408,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,408,13,5,0,-2,0,0,0,0,0, " xterm -geom 40x8+200+400 -e latex $(file_name);")]) ]), mini_line(624,13,5,0,0,0,[ str_block(0,624,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,624,13,5,0,-2,0,0,0,0,0, " xterm -geom 40x8+200+400 -e dvips -E -n 1 -o $(file_name).ps $(file_name);")]) ]), mini_line(640,13,5,0,0,0,[ str_block(0,640,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,640,13,5,0,-1,0,0,0,0,0, " xterm -geom 40x8+200+400 -e epstool -b -i -o$(file_name).eps $(file_name).ps")]) ]) ])])), attr("cleanup=", "", 0, 1, 0, text('blue',64,-72,3,0,1,480,54,165,13,5,0,0,0,0,2,480,54,0,0,"",0,0,0,0,-59,'',[ minilines(480,54,0,0,0,0,0,[ mini_line(64,13,5,0,0,0,[ str_block(0,64,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,64,13,5,0,0,0,0,0,0,0, "cleanup=")]) ]), mini_line(480,13,5,0,0,0,[ str_block(0,480,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,480,13,5,0,0,0,0,0,0,0, " rm -f $(file_name).tex $(file_name).aux $(file_name).dvi")]) ]), mini_line(456,13,5,0,0,0,[ str_block(0,456,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,456,13,5,0,-1,0,0,0,0,0, " $(file_name).log $(file_name).ps $(file_name).eps")]) ]) ])])), attr("file_name=", "", 0, 1, 0, text('blue',64,32,1,0,1,80,18,29,13,5,0,0,0,0,2,80,18,0,0,"",0,0,0,0,45,'',[ minilines(80,18,0,0,0,0,0,[ mini_line(80,13,5,0,0,0,[ str_block(0,80,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,80,13,5,0,0,0,0,0,0,0, "file_name=")]) ]) ])])), attr("eq=", "", 1, 1, 0, text('blue',64,48,5,0,1,120,90,25,13,5,0,0,0,0,2,120,90,0,0,"",0,0,0,0,61,'',[ minilines(120,90,0,0,0,0,0,[ mini_line(24,13,5,0,0,0,[ str_block(0,24,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,24,13,5,0,0,0,0,0,0,0, "eq=")]) ]), mini_line(48,13,5,0,0,0,[ str_block(0,48,13,5,0,0,0,0,0,[ str_seg('#0000ff','Courier',0,80640,48,13,5,0,0,0,0,0,0,0, "\\LARGE")]) ]), mini_line(16,13,5,0,0,0,[ str_block(0,16,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,16,13,5,0,-2,0,0,0,0,0, "\\[")]) ]), mini_line(120,13,5,0,0,0,[ str_block(0,120,13,5,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,120,13,5,0,-1,0,0,0,0,0, " E\\,=\\,M\\,C^2")]) ]), mini_line(16,13,5,0,0,0,[ str_block(0,16,13,5,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,16,13,5,0,-2,0,0,0,0,0, "\\]")]) ]) ])])), attr("", "not_rigid", 0, 1, 0, text('blue',64,152,1,0,1,72,18,535,13,5,0,0,0,0,2,72,18,0,1,"",0,0,0,0,165,'',[ minilines(72,18,0,1,0,0,0,[ mini_line(72,13,5,0,1,0,[ str_block(0,72,13,5,0,1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,72,13,5,0,1,0,0,0,0,0, "not_rigid")]) ]) ])])) ]). ������������������������������������������������������������������������������������������tgif-QPL-4.2.5/stream.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000003214�11602233313�014426� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/stream.e,v 1.6 2011/05/16 16:21:59 william Exp $ */ #ifndef _TGIF_STREAM_E_ #define _TGIF_STREAM_E_ #ifdef _INCLUDE_FROM_STREAM_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_STREAM_C_*/ extern void CleanUpMime ARGS_DECL((void)); extern void InitMime ARGS_DECL((void)); extern void ResetMultipartReplace ARGS_DECL((int redraw)); extern int IsJustLF ARGS_DECL((char*)); extern char * GetHeaderLine ARGS_DECL((char*, int just_lf)); extern void HandleMultipartReplace ARGS_DECL((char*, int*)); extern void FakeUserAgent ARGS_DECL((char*)); extern void FakeReferer ARGS_DECL((char*)); extern void ToggleKeepAlive ARGS_DECL((void)); #ifdef _INCLUDE_FROM_STREAM_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_STREAM_C_*/ #endif /*_TGIF_STREAM_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgwb.man�����������������������������������������������������������������������������0000644�0000764�0000764�00000007266�11602233313�014440� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������.\" Tgwb's man pages. .\" .\" @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgwb.man,v 1.1 2004/06/18 23:20:01 william Exp $ .\" .\" .\" .\" .\" .\" .\" .TH tgwb n "Version 4.1 Patchlevel 43 and Above" "Tgwb" .\"================================================================ .SH NAME .\" \fItgwb\fR \- a shared vector-based drawing whiteboard, based on \fItgif\fR, for collaborating over the Internet. .\"================================================================ .SH SYNOPSIS .\" .B tgwb [\fB-no-wb\fR] [\fB-no-chat\fR] [\fB-chatnick\fR <nickname>] [\fB<tgif-options>\fR] .\"================================================================ .SH DESCRIPTION .\" \fITgwb\fR is a shared vector-based drawing whiteboard, based on tgif(n), for collaborating over the Internet. .\"================================================================ .SH OPTIONS .\" The command line arguments can be: .TP .B -no-wb Disable whiteboard. .TP .B -no-chat No chat window will be initially visible. The chat window can be made visible by selecting \fIShow Chat\fR in the Show/Hide submenu of the Layout Menu. .TP .B -chatnick \fR<nickname>\fB User's nickname will be set to <nickname>. This overrides the Tgif.ChatNickName X default. .PP All other commandline options (<tgif-options>) are treated as options for tgif(n). .\"================================================================ .SH CHAT WINDOW .\" In addition to tgif's windows, tgwb has a Chat window which has a message display area and a toolbar on the bottom. The toolbar contains the following items (from left to right): .TP .I Auto-scroll Button If this button is depressed, the message display area will scroll automatically to the bottom when a new message entered by another user arrives. .TP .I Color Button Clicking with the left/right mouse button or dragging with the middle mouse button can change the user's chat color. .TP .I Bold Button If this button is depressed, bold font will be used. .TP .I Italic Button If this button is depressed, italic font will be used. .TP .I Edit Area This is where the user can enter a message to be sent. Pressing the <Enter> key has the same effect as clicking on the Send Button. .TP .I Send Button Click on this button sends the message in the Edit Area. .\"================================================================ .SH X DEFAULTS .\" .TP .I Tgif.NoChatWindow: [true,false] If set to ``true'', no Chat Window will be shown initially. The default is false. .TP .I Tgif.ChatNickName: STRING The STRING specifies a nickname to be used in chat. By default, the value of the USER environment variable is used as the user's nickname. The nickname specified here can be overridden by the -chatnick commandline option. .\"================================================================ .SH SEE ALSO .\" \fBtgif\fR(n) .\"================================================================ .SH IDIOSYNCRASIES .\" Some idiosyncrasies are mentioned here. .PP Font size in the chat window cannot be changed dynamically. .\"================================================================ .SH BUGS .\" Joining the existing chat session does not work. .\" .\"================================================================ .SH COPYRIGHT .\" Please see the ``Copyright'' file for details on the copyrights of tgif(n). Please see the ``README.tgwb'' file for additional copyright information. .\"================================================================ .SH STATUS .\" The current status of tgif(n) can be obtained from tgif's World-Wide-Web home page at <URL:http://bourbon.usc.edu:8001/tgif/>. .\"================================================================ .SH AUTHOR .\" William Chia-Wei Cheng (bill.cheng@acm.org) .br <URL:http://bourbon.usc.edu/william/> ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgif.pl������������������������������������������������������������������������������0000644�0000764�0000764�00000414641�11602233313�014265� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������% % Author: William Chia-Wei Cheng (bill.cheng@acm.org) % % Copyright (C) 2001-2009, William Chia-Wei Cheng. % % This file may be distributed under the terms of the Q Public License % as defined by Trolltech AS of Norway and appearing in the file % LICENSE.QPL included in the packaging of this file. % % THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING % THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR % PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, % INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING % FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, % NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION % WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgif.pl,v 1.7 2011/05/16 16:26:57 william Exp $ % % 1) Call tgif_clean/0 each time before step (2). % 2) Consult a '.obj' or a '.sym' file. % 3) Call tgif_state/2. This must be called before any other tgif goals % are called. % 4) Trace any other goals. % % Note: tgif_pin() is not documented because its implementation is not done. % tgif_pin() first appears in file version 34. % internal_file_version(FileVersion) :- nl, write('Sorry, FileVersion '), write(FileVersion), write(' belongs to an internal release and it is not supported.'), nl. check_file_version(34) :- internal_file_version(34), !, fail. check_file_version(35) :- internal_file_version(35), !, fail. check_file_version(36) :- internal_file_version(36), !, fail. check_file_version(_). tgif_state(FileVersion,Obj) :- tgif_state(FileVersion,Obj,_), !, check_file_version(FileVersion). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_OrigX,_OrigY,_Zoom, _GridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize), tgif_chk_output(OutputObj,Obj), FileVersion =< 3, Parms = [page_style=_PageStyle,file_version=FileVersion, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_OrigX,_OrigY,_Zoom, _GridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize), tgif_chk_output(OutputObj,Obj), FileVersion =< 7, Parms = [page_style=_PageStyle,file_version=FileVersion, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_OrigX,_OrigY,_Zoom, _GridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize,_TextDPI), tgif_chk_output(OutputObj,Obj), FileVersion =< 8, Parms = [page_style=_PageStyle,file_version=FileVersion, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize,text_dpi=_TextDPI], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_OrigX,_OrigY,_Zoom, _GridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize,_TextDPI,_Dash), tgif_chk_output(OutputObj,Obj), FileVersion =< 11, Parms = [page_style=_PageStyle,file_version=FileVersion, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize,text_dpi=_TextDPI,line_dash=_Dash], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize,_TextDPI,_Dash,_GridSystem, _MetricGridSize), tgif_chk_output(OutputObj,Obj), FileVersion =< 12, Parms = [page_style=_PageStyle,file_version=FileVersion, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize,text_dpi=_TextDPI,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize,_TextDPI,_Dash,_GridSystem, _MetricGridSize,_TextVSpace), tgif_chk_output(OutputObj,Obj), FileVersion =< 13, Parms = [page_style=_PageStyle,file_version=FileVersion, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize,text_dpi=_TextDPI,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize,_TextDPI,_Dash,_GridSystem, _MetricGridSize,_TextVSpace), tgif_chk_output(OutputObj,Obj), FileVersion =< 18, Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize,text_dpi=_TextDPI,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize,_TextDPI,_Dash,_GridSystem, _MetricGridSize,_TextVSpace,_ZoomIn), tgif_chk_output(OutputObj,Obj), FileVersion =< 19, Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize,text_dpi=_TextDPI,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace,zoom_in=_ZoomIn], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize,_TextDPI,_Dash,_GridSystem, _MetricGridSize,_TextVSpace,_ZoomIn,_GridShown,_MoveMode), tgif_chk_output(OutputObj,Obj), FileVersion =< 21, Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize,text_dpi=_TextDPI,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace,zoom_in=_ZoomIn,grid_shown=_GridShown, move_mode=_ModeMode], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize,_TextDPI,_Dash,_GridSystem, _MetricGridSize,_TextVSpace,_ZoomIn,_GridShown,_MoveMode, _TextRotate,_RCBoxRadius), tgif_chk_output(OutputObj,Obj), FileVersion =< 26, Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize,text_dpi=_TextDPI,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace,zoom_in=_ZoomIn,grid_shown=_GridShown, move_mode=_ModeMode,text_rotate=_TextRotate, rcb_radius=_RCBoxRadius], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize,_TextDPI,_Dash,_GridSystem, _MetricGridSize,_TextVSpace,_ZoomIn,_GridShown,_MoveMode, _TextRotate,_RCBoxRadius,_UseGray), tgif_chk_output(OutputObj,Obj), FileVersion =< 27, Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize,text_dpi=_TextDPI,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace,zoom_in=_ZoomIn,grid_shown=_GridShown, move_mode=_ModeMode,text_rotate=_TextRotate, rcb_radius=_RCBoxRadius,use_gray=_UseGray], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- % Mstsuda's Version ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize,_TextDPI,_Dash,_GridSystem, _MetricGridSize,_TextVSpace,_ZoomIn,_GridShown,_MoveMode, _TextRotate,_RCBoxRadius,_UseGray,_PaperCol,_PaperRow, _CurPageNum,_LastPageNum), tgif_chk_output(OutputObj,Obj), FileVersion =< 28, Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize,text_dpi=_TextDPI,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace,zoom_in=_ZoomIn,grid_shown=_GridShown, move_mode=_ModeMode,text_rotate=_TextRotate, rcb_radius=_RCBoxRadius,use_gray=_UseGray, papge_col=_PaperCol,papge_row=_PaperRow, cur_page_num=_CurPageNum,last_page_num=_LastPageNum], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_Font, _TextStyle,_TextSize,_TextDPI,_Dash,_GridSystem, _MetricGridSize,_TextVSpace,_ZoomIn,_GridShown,_MoveMode, _TextRotate,_RCBoxRadius,_UseGray,_PageLayoutMode,_PageArg1, _PageArg2,_PageLineShownInTileMode), tgif_chk_output(OutputObj,Obj), FileVersion =< 29, ( (_PageLayoutMode == 0) -> % stack mode _CurPageNum = _PageArg1, _LastPageNum = _PageArg2, _PaperRow = 1, _PaperCol = 1 ; _PaperCol = _PageArg1, _PaperRow = _PageArg2, _CurPageNum = 1, _LastPageNum = 1 ), Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font=_Font,text_style=_TextStyle, text_size=_TextSize,text_dpi=_TextDPI,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace,zoom_in=_ZoomIn,grid_shown=_GridShown, move_mode=_ModeMode,text_rotate=_TextRotate, rcb_radius=_RCBoxRadius,use_gray=_UseGray, page_layout_mode=_PageLayoutMode, page_line_shown_in_tile_mode=_PageLineShownInTileMode, papge_col=_PaperCol,papge_row=_PaperRow, cur_page_num=_CurPageNum,last_page_num=_LastPageNum], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_FontName, _TextStyle,_FontSize,0,_Dash,_GridSystem, _MetricGridSize,_TextVSpace,_ZoomIn,_GridShown,_MoveMode, _TextRotate,_RCBoxRadius,_UseGray,_PageLayoutMode,_PageArg1, _PageArg2,_PageLineShownInTileMode), tgif_chk_output(OutputObj,Obj), FileVersion =< 30, ( (_PageLayoutMode == 0) -> % stack mode _CurPageNum = _PageArg1, _LastPageNum = _PageArg2, _PaperRow = 1, _PaperCol = 1 ; _PaperCol = _PageArg1, _PaperRow = _PageArg2, _CurPageNum = 1, _LastPageNum = 1 ), Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font_name=_FontName,text_style=_TextStyle, font_size=_FontSize,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace,zoom_in=_ZoomIn,grid_shown=_GridShown, move_mode=_ModeMode,text_rotate=_TextRotate, rcb_radius=_RCBoxRadius,use_gray=_UseGray, page_layout_mode=_PageLayoutMode, page_line_shown_in_tile_mode=_PageLineShownInTileMode, papge_col=_PaperCol,papge_row=_PaperRow, cur_page_num=_CurPageNum,last_page_num=_LastPageNum], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_FontName, _TextStyle,_FontSize,0,_Dash,_GridSystem, _MetricGridSize,_TextVSpace,_ZoomIn,_GridShown,_MoveMode, _TextRotate,_RCBoxRadius,_UseGray,_PageLayoutMode,_PageArg1, _PageArg2,_PageLineShownInTileMode,_ColorDump), tgif_chk_output(OutputObj,Obj), FileVersion =< 31, ( (_PageLayoutMode == 0) -> % stack mode _CurPageNum = _PageArg1, _LastPageNum = _PageArg2, _PaperRow = 1, _PaperCol = 1 ; _PaperCol = _PageArg1, _PaperRow = _PageArg2, _CurPageNum = 1, _LastPageNum = 1 ), Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font_name=_FontName,text_style=_TextStyle, font_size=_FontSize,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace,zoom_in=_ZoomIn,grid_shown=_GridShown, move_mode=_ModeMode,text_rotate=_TextRotate, rcb_radius=_RCBoxRadius,use_gray=_UseGray, page_layout_mode=_PageLayoutMode, page_line_shown_in_tile_mode=_PageLineShownInTileMode, papge_col=_PaperCol,papge_row=_PaperRow, cur_page_num=_CurPageNum,last_page_num=_LastPageNum, color_dump=_ColorDump], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_FontName, _TextStyle,_FontSize,0,_Dash,_GridSystem, _MetricGridSize,_TextVSpace,_ZoomIn,_GridShown,_MoveMode, _TextRotate,_RCBoxRadius,_UseGray,_PageLayoutMode,_PageArg1, _PageArg2,_PageLineShownInTileMode,_ColorDump, _OnePageWidth,_OnePageHeight), tgif_chk_output(OutputObj,Obj), FileVersion =< 32, ( (_PageLayoutMode == 0) -> % stack mode _CurPageNum = _PageArg1, _LastPageNum = _PageArg2, _PaperRow = 1, _PaperCol = 1 ; _PaperCol = _PageArg1, _PaperRow = _PageArg2, _CurPageNum = 1, _LastPageNum = 1 ), Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font_name=_FontName,text_style=_TextStyle, font_size=_FontSize,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace,zoom_in=_ZoomIn,grid_shown=_GridShown, move_mode=_ModeMode,text_rotate=_TextRotate, rcb_radius=_RCBoxRadius,use_gray=_UseGray, page_layout_mode=_PageLayoutMode, page_line_shown_in_tile_mode=_PageLineShownInTileMode, papge_col=_PaperCol,papge_row=_PaperRow, cur_page_num=_CurPageNum,last_page_num=_LastPageNum, color_dump=_ColorDump,one_page_width=_OnePageWidth, one_page_height=_OnePageHeight], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_FontName, _TextStyle,_FontSize,0,_Dash,_GridSystem, _MetricGridSize,_TextVSpace,_ZoomIn,_GridShown,_MoveMode, _TextRotate,_RCBoxRadius,_UseGray,_PageLayoutMode,_PageArg1, _PageArg2,_PageLineShownInTileMode,_ColorDump, _OnePageWidth,_OnePageHeight,_StretchableText,_TextRotation, _RotationIncrement), tgif_chk_output(OutputObj,Obj), FileVersion =< 34, ( (_PageLayoutMode == 0) -> % stack mode _CurPageNum = _PageArg1, _LastPageNum = _PageArg2, _PaperRow = 1, _PaperCol = 1 ; _PaperCol = _PageArg1, _PaperRow = _PageArg2, _CurPageNum = 1, _LastPageNum = 1 ), Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font_name=_FontName,text_style=_TextStyle, font_size=_FontSize,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace,zoom_in=_ZoomIn,grid_shown=_GridShown, move_mode=_ModeMode,text_rotate=_TextRotate, rcb_radius=_RCBoxRadius,use_gray=_UseGray, page_layout_mode=_PageLayoutMode, page_line_shown_in_tile_mode=_PageLineShownInTileMode, papge_col=_PaperCol,papge_row=_PaperRow, cur_page_num=_CurPageNum,last_page_num=_LastPageNum, color_dump=_ColorDump,one_page_width=_OnePageWidth, one_page_height=_OnePageHeight, stretchable_text=_StretchableText,text_rotation=_TextRotation, rotation_increment=_RotationIncrement], !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). tgif_state(FileVersion,Obj,Parms) :- ( var(Obj) -> OutputObj = true, current_predicate(state, state(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_,_)) ; OutputObj = false ), Obj = state(_PageStyle,FileVersion,_PrintMag,_OrigX,_OrigY,_Zoom, _EnglishGridSize,_Grid,_Color,_HoriAlign,_VertAlign,_LineWidth, _Spline,_LineStyle,_ObjFill,_PenPat,_TextJust,_FontName, _TextStyle,_FontSize,0,_Dash,_GridSystem, _MetricGridSize,_TextVSpace,_ZoomIn,_GridShown,_MoveMode, _TextRotate,_RCBoxRadius,_UseGray,_PageLayoutMode,_PageArg1, _PageArg2,_PageLineShownInTileMode,_ColorDump, _OnePageWidth,_OnePageHeight,_StretchableText,_TextRotation, _RotationIncrement,_TransPat), tgif_chk_output(OutputObj,Obj), FileVersion >= 35, ( (_PageLayoutMode == 0) -> % stack mode _CurPageNum = _PageArg1, _LastPageNum = _PageArg2, _PaperRow = 1, _PaperCol = 1 ; _PaperCol = _PageArg1, _PaperRow = _PageArg2, _CurPageNum = 1, _LastPageNum = 1 ), Parms = [page_style=_PageStyle,file_version=FileVersion, print_mag=_PrintMag, orig_x=_OrigX,orig_y=_OrigY,zoom=_Zoom, english_grid_size=_GridSize,snap_on=_Grid,color=_Color, h_align=_HoriAlign,v_align=_VertAlign,line_width=_LineWidth, line_type=_Spline, line_style=_LineStyle,obj_fill=_ObjFill,pen_pat=_PenPat, text_just=_TextJust,font_name=_FontName,text_style=_TextStyle, _font_size_or_sz_unit=_FontSize,line_dash=_Dash, grid_system=_GridSystem,metric_grid=_MetricGridSize, text_v_space=_TextVSpace,zoom_in=_ZoomIn,grid_shown=_GridShown, move_mode=_ModeMode,text_rotate=_TextRotate, rcb_radius=_RCBoxRadius,use_gray=_UseGray, page_layout_mode=_PageLayoutMode, page_line_shown_in_tile_mode=_PageLineShownInTileMode, papge_col=_PaperCol,papge_row=_PaperRow, cur_page_num=_CurPageNum,last_page_num=_LastPageNum, color_dump=_ColorDump,one_page_width=_OnePageWidth, one_page_height=_OnePageHeight, stretchable_text=_StretchableText,text_rotation=_TextRotation, rotation_increment=_RotationIncrement,trans_pat=_TransPat], FileVersion >= 35, ( (FileVersion == 35) -> % stack mode _font_size_or_sz_unit = 'font_size' ; _font_size_or_sz_unit = 'font_sz_unit' ), !, abolish(tgif_file_version/1), !, assert(tgif_file_version(FileVersion)). % --------------------------------------------------------------------- % tgif_text(Obj) :- tgif_text(Obj,_). tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 2, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = text(_Color,_X,_Y,_Font,_TextStyle,_TextSize,_NumLines,_TextJust, StrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,x=_X,y=_Y,font=_Font,text_style=_TextStyle, text_size=_TextSize,num_lines=_NumLines,text_just=_TextJust, strs=StrList], tgif_strs(StrList). tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 6, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = text(_Color,_X,_Y,_Font,_TextStyle,_TextSize,_NumLines,_TextJust, _TextRotate,_PenPat,StrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,x=_X,y=_Y,font=_Font,text_style=_TextStyle, text_size=_TextSize,num_lines=_NumLines,text_just=_TextJust, text_rotate=_TextRotate,pen_pat=_PenPat,strs=StrList], tgif_strs(StrList). tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 7, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = text(_Color,_X,_Y,_Font,_TextStyle,_TextSize,_NumLines,_TextJust, _TextRotate,_PenPat,_BBoxW,_BBoxH,StrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,x=_X,y=_Y,font=_Font,text_style=_TextStyle, text_size=_TextSize,num_lines=_NumLines,text_just=_TextJust, text_rotate=_TextRotate,pen_pat=_PenPat,bbox_w=_BBoxW, bbox_h=_BBoxH,strs=StrList], tgif_strs(StrList). tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 9, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = text(_Color,_X,_Y,_Font,_TextStyle,_TextSize,_NumLines,_TextJust, _TextRotate,_PenPat,_BBoxW,_BBoxH,_Id,_TextDPI,StrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,x=_X,y=_Y,font=_Font,text_style=_TextStyle, text_size=_TextSize,num_lines=_NumLines,text_just=_TextJust, text_rotate=_TextRotate,pen_pat=_PenPat,bbox_w=_BBoxW, bbox_h=_BBoxH,id=_Id,text_dpi=_TextDPI,strs=StrList], tgif_strs(StrList). tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 10, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = text(_Color,_X,_Y,_Font,_TextStyle,_TextSize,_NumLines,_TextJust, _TextRotate,_PenPat,_BBoxW,_BBoxH,_Id,_TextDPI,_Asc,_Des, StrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,x=_X,y=_Y,font=_Font,text_style=_TextStyle, text_size=_TextSize,num_lines=_NumLines,text_just=_TextJust, text_rotate=_TextRotate,pen_pat=_PenPat,bbox_w=_BBoxW, bbox_h=_BBoxH,id=_Id,text_dpi=_TextDPI,asc=_Asc,des=_Des, strs=StrList], tgif_strs(StrList). tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 12, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = text(_Color,_X,_Y,_Font,_TextStyle,_TextSize,_NumLines,_TextJust, _TextRotate,_PenPat,_BBoxW,_BBoxH,_Id,_TextDPI,_Asc,_Des, _ObjFill,StrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,x=_X,y=_Y,font=_Font,text_style=_TextStyle, text_size=_TextSize,num_lines=_NumLines,text_just=_TextJust, text_rotate=_TextRotate,pen_pat=_PenPat,bbox_w=_BBoxW, bbox_h=_BBoxH,id=_Id,text_dpi=_TextDPI,asc=_Asc,des=_Des, obj_fill=_ObjFill,strs=StrList], tgif_strs(StrList). tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 13, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = text(_Color,_X,_Y,_Font,_TextStyle,_TextSize,_NumLines,_TextJust, _TextRotate,_PenPat,_BBoxW,_BBoxH,_Id,_TextDPI,_Asc,_Des, _ObjFill,_VSpace,StrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,x=_X,y=_Y,font=_Font,text_style=_TextStyle, text_size=_TextSize,num_lines=_NumLines,text_just=_TextJust, text_rotate=_TextRotate,pen_pat=_PenPat,bbox_w=_BBoxW, bbox_h=_BBoxH,id=_Id,text_dpi=_TextDPI,asc=_Asc,des=_Des, obj_fill=_ObjFill,v_space=_VSpace,strs=StrList], tgif_strs(StrList). tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = text(_Color,_X,_Y,_Font,_TextStyle,_TextSize,_NumLines,_TextJust, _TextRotate,_PenPat,_BBoxW,_BBoxH,_Id,_TextDPI,_Asc,_Des, _ObjFill,_VSpace,_Rotation,StrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,x=_X,y=_Y,font=_Font,text_style=_TextStyle, text_size=_TextSize,num_lines=_NumLines,text_just=_TextJust, text_rotate=_TextRotate,pen_pat=_PenPat,bbox_w=_BBoxW, bbox_h=_BBoxH,id=_Id,text_dpi=_TextDPI,asc=_Asc,des=_Des, obj_fill=_ObjFill,v_space=_VSpace,rotation=_Rotation, strs=StrList], tgif_strs(StrList). tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 29, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = text(_Color,_X,_Y,_Font,_TextStyle,_TextSize,_NumLines,_TextJust, _TextRotate,_PenPat,_BBoxW,_BBoxH,_Id,_TextDPI,_Asc,_Des, _ObjFill,_VSpace,_Rotation,_Locked,StrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,x=_X,y=_Y,font=_Font,text_style=_TextStyle, text_size=_TextSize,num_lines=_NumLines,text_just=_TextJust, text_rotate=_TextRotate,pen_pat=_PenPat,bbox_w=_BBoxW, bbox_h=_BBoxH,id=_Id,text_dpi=_TextDPI,asc=_Asc,des=_Des, obj_fill=_ObjFill,v_space=_VSpace,rotation=_Rotation, obj_locked=_Locked,strs=StrList], tgif_strs(StrList). tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, % From version 30 on, the FontSize is the actual size; % the TextSize in older versions is a size index. ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = text(_Color,_X,_Y,_FontName,_TextStyle,_FontSize,_NumLines, _TextJust,_TextRotate,_PenPat,_BBoxW,_BBoxH,_Id,0,_Asc,_Des, _ObjFill,_VSpace,_Rotation,_Locked,StrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,x=_X,y=_Y,font_name=_FontName, text_style=_TextStyle,font_size=_FontSize,num_lines=_NumLines, text_just=_TextJust,text_rotate=_TextRotate,pen_pat=_PenPat, bbox_w=_BBoxW,bbox_h=_BBoxH,id=_Id,asc=_Asc,des=_Des, obj_fill=_ObjFill,v_space=_VSpace,rotation=_Rotation, obj_locked=_Locked,strs=StrList], tgif_strs(StrList). tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = text(_Color,_X,_Y,_FontName,_TextStyle,_FontSize, _NumLines,_TextJust,_TextRotate,_PenPat,_BBoxW,_BBoxH, _Id,0,_Asc,_Des,_ObjFill,_VSpace,_Rotation,_Locked, _UnderlineOn,_Underline,_MinLBearing,_MaxRExtra, _DoubleByte,_Direction,_CustomFontName,_Compressed, _Transformed,_Invisible,StrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,x=_X,y=_Y,font_name=_FontName, text_style=_TextStyle,font_size=_FontSize, num_lines=_NumLines,text_just=_TextJust, text_rotate=_TextRotate,pen_pat=_PenPat,bbox_w=_BBoxW, bbox_h=_BBoxH,id=_Id,asc=_Asc,des=_Des, obj_fill=_ObjFill,v_space=_VSpace,rotation=_Rotation, obj_locked=_Locked,underline_on=_UnderlineOn, underline=_Underline,min_lbearing=_MinLBearing, max_rextra=_MaxRExtra,double_byte=_DoubleByte, direction=_Direction,custom_font_name=_CustomFontName, compressed=_Compressed,transformed=_Transformed, invisible=_Invisible,strs=StrList] | _Transformed = 1, Obj = text(_Color,_X,_Y,_FontName,_TextStyle,_FontSize, _NumLines,_TextJust,_TextRotate,_PenPat,_BBoxW,_BBoxH, _Id,0,_Asc,_Des,_ObjFill,_VSpace,_Rotation,_Locked, _UnderlineOn,_Underline,_MinLBearing,_MaxRExtra, _DoubleByte,_Direction,_CustomFontName,_Compressed, _Transformed,_Invisible,TransformSpec,StrList), tgif_chk_output(OutputObj,Obj), tgif_text_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,x=_X,y=_Y,font_name=_FontName, text_style=_TextStyle,font_size=_FontSize, num_lines=_NumLines,text_just=_TextJust, text_rotate=_TextRotate,pen_pat=_PenPat,bbox_w=_BBoxW, bbox_h=_BBoxH,id=_Id,asc=_Asc,des=_Des, obj_fill=_ObjFill,v_space=_VSpace,rotation=_Rotation, obj_locked=_Locked,underline_on=_UnderlineOn, underline=_Underline,min_lbearing=_MinLBearing, max_rextra=_MaxRExtra,double_byte=_DoubleByte, direction=_Direction,custom_font_name=_CustomFontName, compressed=_Compressed,transformed=_Transformed, invisible=_Invisible,transform_spec=TransformParms, strs=StrList] ), tgif_strs(StrList). % % Note: FileVersions 34, 35, and 36 are skipped. See check_file_version/1. % tgif_text(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, ( Obj = text(_FillPatColor,_X,_Y, _NumLines,_TextJust,_PenPat,_BBoxW,_BBoxH,_Id, _Asc,_Des,_ObjFill,_VSpace,_Rotation,_Locked,_Underline, _TextW,_TextH,_MinLBearing,_MaxRExtra,_CustomFontName, _Compressed,_Transformed,_Invisible,_TransPat,_BaselineY, MinilinesList), _BgColor = '' | Obj = text(_FillPatColor,_X,_Y, _NumLines,_TextJust,_PenPat,_BBoxW,_BBoxH,_Id, _Asc,_Des,_ObjFill,_VSpace,_Rotation,_Locked,_Underline, _TextW,_TextH,_MinLBearing,_MaxRExtra,_CustomFontName, _Compressed,_Transformed,_Invisible,_TransPat,_BaselineY, _BgColor,MinilinesList) ), tgif_chk_output(OutputObj,Obj), Parms = [fill_pat_color=_FillPatColor,x=_X,y=_Y,num_lines=_NumLines, text_just=_TextJust,pen_pat=_PenPat,bbox_w=_BBoxW,bbox_h=_BBoxH, id=_Id,asc=_Asc,des=_Des,obj_fill=_ObjFill,v_space=_VSpace, rotation=_Rotation,obj_locked=_Locked,underline=_Underline, text_w=_TextW,text_h=_TextH,min_lbearing=_MinLBearing, max_rextra=_MaxRExtra,custom_font_name=_CustomFontName, compressed=_Compressed,transformed=_Transformed, invisible=_Invisible,trans_pat=_TransPat,baseline_y=_BaselineY, bg_color=_BgColor,minilines=MinilinesList] | _Transformed = 1, ( Obj = text(_FillPatColor,_X,_Y, _NumLines,_TextJust,_PenPat,_BBoxW,_BBoxH,_Id, _Asc,_Des,_ObjFill,_VSpace,_Rotation,_Locked,_Underline, _TextW,_TextH,_MinLBearing,_MaxRExtra,_CustomFontName, _Compressed,_Transformed,_Invisible,_TransPat,_BaselineY, TransformSpec,MinilinesList), _BgColor = '' | Obj = text(_FillPatColor,_X,_Y, _NumLines,_TextJust,_PenPat,_BBoxW,_BBoxH,_Id, _Asc,_Des,_ObjFill,_VSpace,_Rotation,_Locked,_Underline, _TextW,_TextH,_MinLBearing,_MaxRExtra,_CustomFontName, _Compressed,_Transformed,_Invisible,_TransPat,_BaselineY, _BgColor,TransformSpec,MinilinesList) ), tgif_chk_output(OutputObj,Obj), tgif_text_transform_spec(TransformSpec,TransformParms), Parms = [fill_pat_color=_FillPatColor,x=_X,y=_Y,num_lines=_NumLines, text_just=_TextJust,pen_pat=_PenPat,bbox_w=_BBoxW,bbox_h=_BBoxH, id=_Id,asc=_Asc,des=_Des,obj_fill=_ObjFill,v_space=_VSpace, rotation=_Rotation,obj_locked=_Locked,underline=_Underline, text_w=_TextW,text_h=_TextH,min_lbearing=_MinLBearing, max_rextra=_MaxRExtra,custom_font_name=_CustomFontName, compressed=_Compressed,transformed=_Transformed, invisible=_Invisible,trans_pat=_TransPat,baseline_y=_BaselineY, transform_spec=TransformParms,bg_color=_BgColor, minilines=MinilinesList] ), tgif_minilines_list(MinilinesList). % --------------------------------------------------------------------- % tgif_box(Obj) :- tgif_box(Obj,_). tgif_box(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 7, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = box(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat]. tgif_box(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 8, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = box(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat,_Id, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, id=_Id,attrs=AttrList], tgif_attrs(AttrList). tgif_box(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 13, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = box(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat,_Id,_Dash, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, id=_Id,line_dash=_Dash,attrs=AttrList], tgif_attrs(AttrList). tgif_box(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = box(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat,_Id,_Dash, _Rotation,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, id=_Id,line_dash=_Dash,rotation=_Rotation,attrs=AttrList], tgif_attrs(AttrList). tgif_box(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = box(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat,_Id,_Dash, _Rotation,_Locked,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, id=_Id,line_dash=_Dash,rotation=_Rotation,obj_locked=_Locked, attrs=AttrList], tgif_attrs(AttrList). tgif_box(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = box(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat, _Id,_Dash,_Rotation,_Locked,_Transformed,_Invisible, _LineWidthSpec,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, id=_Id,line_dash=_Dash,rotation=_Rotation, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, attrs=AttrList] | _Transformed = 1, Obj = box(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat, _Id,_Dash,_Rotation,_Locked,_Transformed,_Invisible, _LineWidthSpec,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, id=_Id,line_dash=_Dash,rotation=_Rotation, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % % Note: FileVersions 34, 35, and 36 are skipped. See check_file_version/1. % tgif_box(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = box(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat, _Id,_Dash,_Rotation,_Locked,_Transformed,_Invisible, _LineWidthSpec,_TransPat,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, id=_Id,line_dash=_Dash,rotation=_Rotation, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, trans_pat=_TransPat,attrs=AttrList] | _Transformed = 1, Obj = box(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat, _Id,_Dash,_Rotation,_Locked,_Transformed,_Invisible, _LineWidthSpec,_TransPat,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, id=_Id,line_dash=_Dash,rotation=_Rotation, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, trans_pat=_TransPat,transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % --------------------------------------------------------------------- % tgif_oval(Obj) :- tgif_oval(Obj,_). tgif_oval(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 7, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = oval(_Color,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY,_ObjFill, _LineWidth,_PenPat), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_LeftTopX,lty=_LeftTopY,rbx=_RightBotX, rby=_RightBotY,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat]. tgif_oval(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 8, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = oval(_Color,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY,_ObjFill, _LineWidth,_PenPat,_Id,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_LeftTopX,lty=_LeftTopY,rbx=_RightBotX, rby=_RightBotY,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat,id=_Id,attrs=AttrList], tgif_attrs(AttrList). tgif_oval(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 13, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = oval(_Color,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY,_ObjFill, _LineWidth,_PenPat,_Id,_Dash,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_LeftTopX,lty=_LeftTopY,rbx=_RightBotX, rby=_RightBotY,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat,id=_Id,line_dash=_Dash,attrs=AttrList], tgif_attrs(AttrList). tgif_oval(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = oval(_Color,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY,_ObjFill, _LineWidth,_PenPat,_Id,_Dash,_Rotation,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_LeftTopX,lty=_LeftTopY,rbx=_RightBotX, rby=_RightBotY,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat,id=_Id,line_dash=_Dash,rotation=_Rotation, attrs=AttrList], tgif_attrs(AttrList). tgif_oval(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = oval(_Color,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY,_ObjFill, _LineWidth,_PenPat,_Id,_Dash,_Rotation,_Locked,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_LeftTopX,lty=_LeftTopY,rbx=_RightBotX, rby=_RightBotY,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat,id=_Id,line_dash=_Dash,rotation=_Rotation, obj_locked=_Locked,attrs=AttrList], tgif_attrs(AttrList). tgif_oval(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = oval(_Color,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY, _ObjFill,_LineWidth,_PenPat,_Id,_Dash,_Rotation, _Locked,_Transformed,_Invisible,_LineWidthSpec, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_LeftTopX,lty=_LeftTopY, rbx=_RightBotX,rby=_RightBotY,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,id=_Id, line_dash=_Dash,rotation=_Rotation,obj_locked=_Locked, transformed=_Transformed,invisible=_Invisible, line_width_spec=_LineWidthSpec,attrs=AttrList] | _Transformed = 1, Obj = oval(_Color,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY, _ObjFill,_LineWidth,_PenPat,_Id,_Dash,_Rotation, _Locked,_Transformed,_Invisible,_LineWidthSpec, TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,ltx=_LeftTopX,lty=_LeftTopY, rbx=_RightBotX,rby=_RightBotY,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,id=_Id, line_dash=_Dash,rotation=_Rotation,obj_locked=_Locked, transformed=_Transformed,invisible=_Invisible, line_width_spec=_LineWidthSpec, transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % % Note: FileVersions 34, 35, and 36 are skipped. See check_file_version/1. % tgif_oval(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = oval(_Color,_BgColor,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY, _ObjFill,_LineWidth,_PenPat,_Id,_Dash,_Rotation, _Locked,_Transformed,_Invisible,_LineWidthSpec,_TransPat, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,bg_color=_BgColor,ltx=_LeftTopX,lty=_LeftTopY, rbx=_RightBotX,rby=_RightBotY,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,id=_Id, line_dash=_Dash,rotation=_Rotation,obj_locked=_Locked, transformed=_Transformed,invisible=_Invisible, line_width_spec=_LineWidthSpec,trans_pat=_TransPat,attrs=AttrList] | _Transformed = 1, Obj = oval(_Color,_BgColor,_LeftTopX,_LeftTopY,_RightBotX,_RightBotY, _ObjFill,_LineWidth,_PenPat,_Id,_Dash,_Rotation, _Locked,_Transformed,_Invisible,_LineWidthSpec,_TransPat, TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,bg_color=_BgColor,ltx=_LeftTopX,lty=_LeftTopY, rbx=_RightBotX,rby=_RightBotY,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,id=_Id, line_dash=_Dash,rotation=_Rotation,obj_locked=_Locked, transformed=_Transformed,invisible=_Invisible, line_width_spec=_LineWidthSpec,trans_pat=_TransPat, transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % --------------------------------------------------------------------- % tgif_poly(Obj) :- tgif_poly(Obj,_). tgif_poly(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 3, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,line_style=_LineStyle, line_width=_LineWidth,pen_pat=_PenPat,id=_Id,attrs=AttrList], tgif_attrs(AttrList). tgif_poly(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 4, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id,_Spline, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,line_style=_LineStyle, line_width=_LineWidth,pen_pat=_PenPat,id=_Id,line_type=_Spline, attrs=AttrList], tgif_attrs(AttrList). tgif_poly(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 8, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id,_Spline, _ObjFill,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,line_style=_LineStyle, line_width=_LineWidth,pen_pat=_PenPat,id=_Id,line_type=_Spline, obj_fill=_ObjFill,attrs=AttrList], tgif_attrs(AttrList). tgif_poly(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 13, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id,_Spline, _ObjFill,_Dash,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,line_style=_LineStyle, line_width=_LineWidth,pen_pat=_PenPat,id=_Id,line_type=_Spline, obj_fill=_ObjFill,line_dash=_Dash,attrs=AttrList], tgif_attrs(AttrList). tgif_poly(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 16, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id,_Spline, _ObjFill,_Dash,_Rotation,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,line_style=_LineStyle, line_width=_LineWidth,pen_pat=_PenPat,id=_Id,line_type=_Spline, obj_fill=_ObjFill,line_dash=_Dash,rotation=_Rotation, attrs=AttrList], tgif_attrs(AttrList). tgif_poly(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id,_Spline, _ObjFill,_Dash,_Rotation,_ArrowHeadW,_ArrowHeadH,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,line_style=_LineStyle, line_width=_LineWidth,pen_pat=_PenPat,id=_Id,line_type=_Spline, obj_fill=_ObjFill,line_dash=_Dash,rotation=_Rotation, arrow_head_w=_ArrowHeadW,arrow_head_h=_ArrowHeadH, attrs=AttrList], tgif_attrs(AttrList). tgif_poly(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 30, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id,_Spline, _ObjFill,_Dash,_Rotation,_ArrowHeadW,_ArrowHeadH,_Locked, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,line_style=_LineStyle, line_width=_LineWidth,pen_pat=_PenPat,id=_Id,line_type=_Spline, obj_fill=_ObjFill,line_dash=_Dash,rotation=_Rotation, arrow_head_w=_ArrowHeadW,arrow_head_h=_ArrowHeadH, obj_locked=_Locked,attrs=AttrList], tgif_attrs(AttrList). tgif_poly(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id,_Spline, _ObjFill,_Dash,_Rotation,_ArrowHeadW,_ArrowHeadH,_Locked, _SmoothSpecStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,line_style=_LineStyle, line_width=_LineWidth,pen_pat=_PenPat,id=_Id,line_type=_Spline, obj_fill=_ObjFill,line_dash=_Dash,rotation=_Rotation, arrow_head_w=_ArrowHeadW,arrow_head_h=_ArrowHeadH, obj_locked=_Locked,smooth_spec=_SmoothSpecStr,attrs=AttrList], tgif_attrs(AttrList). tgif_poly(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id, _Spline,_ObjFill,_Dash,_Rotation,_ArrowHeadW, _ArrowHeadH,_Locked,_Transformed,_Invisible, _LineWidthSpec,_ArrowHeadWSpec,_ArrowHeadHSpec, _SmoothSpecStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs, line_style=_LineStyle,line_width=_LineWidth, pen_pat=_PenPat,id=_Id,line_type=_Spline, obj_fill=_ObjFill,line_dash=_Dash,rotation=_Rotation, arrow_head_w=_ArrowHeadW,arrow_head_h=_ArrowHeadH, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, arrow_head_w_spec=_ArrowHeadWSpec, arrow_head_h_spec=_ArrowHeadHSpec, smooth_spec=_SmoothSpecStr,attrs=AttrList] | _Transformed = 1, Obj = poly(_Color,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id, _Spline,_ObjFill,_Dash,_Rotation,_ArrowHeadW, _ArrowHeadH,_Locked,_Transformed,_Invisible, _LineWidthSpec,_ArrowHeadWSpec,_ArrowHeadHSpec, _SmoothSpecStr,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs, line_style=_LineStyle,line_width=_LineWidth, pen_pat=_PenPat,id=_Id,line_type=_Spline, obj_fill=_ObjFill,line_dash=_Dash,rotation=_Rotation, arrow_head_w=_ArrowHeadW,arrow_head_h=_ArrowHeadH, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, arrow_head_w_spec=_ArrowHeadWSpec, arrow_head_h_spec=_ArrowHeadHSpec, smooth_spec=_SmoothSpecStr, transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % % Note: FileVersions 34, 35, and 36 are skipped. See check_file_version/1. % tgif_poly(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = poly(_Color,_BgColor,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id, _Spline,_ObjFill,_Dash,_Rotation,_Locked,_Transformed,_Invisible, _LineWidthSpec,_TransPat,_LineCap, _SmoothSpecStr,_TensionSpec,LeftArrowSpec,RightArrowSpec,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,bg_color=_BgColor,num_vs=_NumVs,vs=_Vs, line_style=_LineStyle,line_width=_LineWidth, pen_pat=_PenPat,id=_Id,line_type=_Spline, obj_fill=_ObjFill,line_dash=_Dash,rotation=_Rotation, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, smooth_spec=_SmoothSpecStr,attrs=AttrList] | _Transformed = 1, Obj = poly(_Color,_BgColor,_NumVs,_Vs,_LineStyle,_LineWidth,_PenPat,_Id, _Spline,_ObjFill,_Dash,_Rotation,_Locked,_Transformed,_Invisible, _LineWidthSpec,_TransPat,_LineCap, _SmoothSpecStr,_TensionSpec,LeftArrowSpec,RightArrowSpec, TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,bg_color=_BgColor,num_vs=_NumVs,vs=_Vs, line_style=_LineStyle,line_width=_LineWidth, pen_pat=_PenPat,id=_Id,line_type=_Spline, obj_fill=_ObjFill,line_dash=_Dash,rotation=_Rotation, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, smooth_spec=_SmoothSpecStr, transform_spec=TransformParms,attrs=AttrList] ), tgif_arrow(LeftArrowSpec), tgif_arrow(RightArrowSpec), tgif_attrs(AttrList). % --------------------------------------------------------------------- % tgif_polygon(Obj) :- tgif_polygon(Obj,_). tgif_polygon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 3, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat]. tgif_polygon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 7, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat,_Spline), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,line_type=_Spline]. tgif_polygon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 8, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat,_Spline, _Id,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,line_type=_Spline, id=_Id,attrs=AttrList], tgif_attrs(AttrList). tgif_polygon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 13, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat,_Spline, _Id,_Dash,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,line_type=_Spline, id=_Id,line_dash=_Dash,attrs=AttrList], tgif_attrs(AttrList). tgif_polygon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat,_Spline, _Id,_Dash,_Rotation,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,line_type=_Spline, id=_Id,line_dash=_Dash,rotation=_Rotation,attrs=AttrList], tgif_attrs(AttrList). tgif_polygon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 30, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat,_Spline, _Id,_Dash,_Rotation,_Locked,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,line_type=_Spline, id=_Id,line_dash=_Dash,rotation=_Rotation,obj_locked=_Locked, attrs=AttrList], tgif_attrs(AttrList). tgif_polygon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat,_Spline, _Id,_Dash,_Rotation,_Locked,_SmoothSpecStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,line_type=_Spline, id=_Id,line_dash=_Dash,rotation=_Rotation,obj_locked=_Locked, smooth_spec=_SmoothSpecStr,attrs=AttrList], tgif_attrs(AttrList). tgif_polygon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat, _Spline,_Id,_Dash,_Rotation,_Locked,_Transformed, _Invisible,_LineWidthSpec,_SmoothSpecStr, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat, line_type=_Spline,id=_Id,line_dash=_Dash, rotation=_Rotation,obj_locked=_Locked, transformed=_Transformed,invisible=_Invisible, line_width_spec=_LineWidthSpec, smooth_spec=_SmoothSpecStr,attrs=AttrList] | _Transformed = 1, Obj = polygon(_Color,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat, _Spline,_Id,_Dash,_Rotation,_Locked,_Transformed, _Invisible,_LineWidthSpec,_SmoothSpecStr,TransformSpec, AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,num_vs=_NumVs,vs=_Vs,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat, line_type=_Spline,id=_Id,line_dash=_Dash, rotation=_Rotation,obj_locked=_Locked, transformed=_Transformed,invisible=_Invisible, line_width_spec=_LineWidthSpec, smooth_spec=_SmoothSpecStr, transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % % Note: FileVersions 34, 35, and 36 are skipped. See check_file_version/1. % tgif_polygon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = polygon(_Color,_BgColor,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat, _Spline,_Id,_Dash,_Rotation,_Locked,_Transformed, _Invisible,_LineWidthSpec,_TransPat,_SmoothSpecStr, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,bg_color=_BgColor,num_vs=_NumVs,vs=_Vs, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, line_type=_Spline,id=_Id,line_dash=_Dash, rotation=_Rotation,obj_locked=_Locked, transformed=_Transformed,invisible=_Invisible, line_width_spec=_LineWidthSpec,trans_pat=_TransPat, smooth_spec=_SmoothSpecStr,attrs=AttrList] | _Transformed = 1, Obj = polygon(_Color,_BgColor,_NumVs,_Vs,_ObjFill,_LineWidth,_PenPat, _Spline,_Id,_Dash,_Rotation,_Locked,_Transformed, _Invisible,_LineWidthSpec,_TransPat,_SmoothSpecStr,TransformSpec, AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,bg_color=_BgColor,num_vs=_NumVs,vs=_Vs, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, line_type=_Spline,id=_Id,line_dash=_Dash, rotation=_Rotation,obj_locked=_Locked, transformed=_Transformed,invisible=_Invisible, line_width_spec=_LineWidthSpec,trans_pat=_TransPat, smooth_spec=_SmoothSpecStr, transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % --------------------------------------------------------------------- % tgif_rcbox(Obj) :- tgif_rcbox(Obj,_). tgif_rcbox(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 13, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = rcbox(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat,_Dash, _Radius,_Id,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, line_dash=_Dash,radius=_Radius,id=_Id,attrs=AttrList], tgif_attrs(AttrList). tgif_rcbox(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = rcbox(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat,_Dash, _Radius,_Id,_Rotation,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, line_dash=_Dash,radius=_Radius,id=_Id,rotation=_Rotation, attrs=AttrList], tgif_attrs(AttrList). tgif_rcbox(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = rcbox(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat,_Dash, _Radius,_Id,_Rotation,_Locked,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, line_dash=_Dash,radius=_Radius,id=_Id,rotation=_Rotation, obj_locked=_Locked,attrs=AttrList], tgif_attrs(AttrList). tgif_rcbox(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = rcbox(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat, _Dash,_Radius,_Id,_Rotation,_Locked,_Transformed, _Invisible,_LineWidthSpec,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, line_dash=_Dash,radius=_Radius,id=_Id,rotation=_Rotation, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, attrs=AttrList] | _Transformed = 1, Obj = rcbox(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat, _Dash,_Radius,_Id,_Rotation,_Locked,_Transformed, _Invisible,_LineWidthSpec,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, line_dash=_Dash,radius=_Radius,id=_Id,rotation=_Rotation, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % % Note: FileVersions 34, 35, and 36 are skipped. See check_file_version/1. % tgif_rcbox(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = rcbox(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat, _Dash,_Radius,_Id,_Rotation,_Locked,_Transformed, _Invisible,_LineWidthSpec,_TransPat,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, line_dash=_Dash,radius=_Radius,id=_Id,rotation=_Rotation, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, trans_pat=_TransPat,attrs=AttrList] | _Transformed = 1, Obj = rcbox(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_LineWidth,_PenPat, _Dash,_Radius,_Id,_Rotation,_Locked,_Transformed, _Invisible,_LineWidthSpec,_TransPat,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,line_width=_LineWidth,pen_pat=_PenPat, line_dash=_Dash,radius=_Radius,id=_Id,rotation=_Rotation, obj_locked=_Locked,transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, trans_pat=_TransPat,transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % --------------------------------------------------------------------- % tgif_arc(Obj) :- tgif_arc(Obj,_). tgif_arc(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 13, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = arc(_Color,_ObjFill,_LineWidth,_PenPat,_Dash,_LtX,_LtY,_Xc,_Yc, _X1,_Y1,_X2,_Y2,_Dir,_W,_H,_Angle1,_Angle2,_Id,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat,line_dash=_Dash,ltx=_LtX,lty=_LtY, xc=_Xc,yc=_Yc,x1=_X1,y1=_Y1,x2=_X2,y2=_Y2,clock_wise=_Dir, major_axis=_W,minor_axis_H,angle1=_Angle1,angle2=_Angle2, id=_Id,attrs=AttrList], tgif_attrs(AttrList). tgif_arc(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 15, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = arc(_Color,_ObjFill,_LineWidth,_PenPat,_Dash,_LtX,_LtY,_Xc,_Yc, _X1,_Y1,_X2,_Y2,_Dir,_W,_H,_Angle1,_Angle2,_Id,_Rotation, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat,line_dash=_Dash,ltx=_LtX,lty=_LtY, xc=_Xc,yc=_Yc,x1=_X1,y1=_Y1,x2=_X2,y2=_Y2,clock_wise=_Dir, major_axis=_W,minor_axis_H,angle1=_Angle1,angle2=_Angle2, id=_Id,rotation=_Rotation,attrs=AttrList], tgif_attrs(AttrList). tgif_arc(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 16, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = arc(_Color,_ObjFill,_LineWidth,_PenPat,_Dash,_LtX,_LtY,_Xc,_Yc, _X1,_Y1,_X2,_Y2,_Dir,_W,_H,_Angle1,_Angle2,_Id,_Rotation, _Style,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat,line_dash=_Dash,ltx=_LtX,lty=_LtY, xc=_Xc,yc=_Yc,x1=_X1,y1=_Y1,x2=_X2,y2=_Y2,clock_wise=_Dir, major_axis=_W,minor_axis_H,angle1=_Angle1,angle2=_Angle2, id=_Id,rotation=_Rotation,line_style=_Style,attrs=AttrList], tgif_attrs(AttrList). tgif_arc(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = arc(_Color,_ObjFill,_LineWidth,_PenPat,_Dash,_LtX,_LtY,_Xc,_Yc, _X1,_Y1,_X2,_Y2,_Dir,_W,_H,_Angle1,_Angle2,_Id,_Rotation, _Style,_ArrowHeadW,_ArrowHeadH,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat,line_dash=_Dash,ltx=_LtX,lty=_LtY, xc=_Xc,yc=_Yc,x1=_X1,y1=_Y1,x2=_X2,y2=_Y2,clock_wise=_Dir, major_axis=_W,minor_axis_H,angle1=_Angle1,angle2=_Angle2, id=_Id,rotation=_Rotation,line_style=_Style, arrow_head_w=_ArrowHeadW,arrow_head_h=_ArrowHeadH, attrs=AttrList], tgif_attrs(AttrList). tgif_arc(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = arc(_Color,_ObjFill,_LineWidth,_PenPat,_Dash,_LtX,_LtY,_Xc,_Yc, _X1,_Y1,_X2,_Y2,_Dir,_W,_H,_Angle1,_Angle2,_Id,_Rotation, _Style,_ArrowHeadW,_ArrowHeadH,_Locked,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat,line_dash=_Dash,ltx=_LtX,lty=_LtY, xc=_Xc,yc=_Yc,x1=_X1,y1=_Y1,x2=_X2,y2=_Y2,clock_wise=_Dir, major_axis=_W,minor_axis_H,angle1=_Angle1,angle2=_Angle2, id=_Id,rotation=_Rotation,line_style=_Style, arrow_head_w=_ArrowHeadW,arrow_head_h=_ArrowHeadH, obj_locked=_Locked,attrs=AttrList], tgif_attrs(AttrList). tgif_arc(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = arc(_Color,_ObjFill,_LineWidth,_PenPat,_Dash,_LtX,_LtY, _Xc,_Yc,_X1,_Y1,_X2,_Y2,_Dir,_W,_H,_Angle1,_Angle2,_Id, _Rotation,_Style,_ArrowHeadW,_ArrowHeadH,_Locked, _Transformed,_Invisible,_LineWidthSpec,_ArrowHeadWSpec, _ArrowHeadHSpec,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat,line_dash=_Dash,ltx=_LtX,lty=_LtY, xc=_Xc,yc=_Yc,x1=_X1,y1=_Y1,x2=_X2,y2=_Y2, clock_wise=_Dir,major_axis=_W,minor_axis_H, angle1=_Angle1,angle2=_Angle2,id=_Id,rotation=_Rotation, line_style=_Style,arrow_head_w=_ArrowHeadW, arrow_head_h=_ArrowHeadH,obj_locked=_Locked, transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, arrow_head_w_spec=_ArrowHeadWSpec, arrow_head_h_spec=_ArrowHeadHSpec,attrs=AttrList] | _Transformed = 1, Obj = arc(_Color,_ObjFill,_LineWidth,_PenPat,_Dash,_LtX,_LtY, _Xc,_Yc,_X1,_Y1,_X2,_Y2,_Dir,_W,_H,_Angle1,_Angle2,_Id, _Rotation,_Style,_ArrowHeadW,_ArrowHeadH,_Locked, _Transformed,_Invisible,_LineWidthSpec,_ArrowHeadWSpec, _ArrowHeadHSpec,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,obj_fill=_ObjFill,line_width=_LineWidth, pen_pat=_PenPat,line_dash=_Dash,ltx=_LtX,lty=_LtY, xc=_Xc,yc=_Yc,x1=_X1,y1=_Y1,x2=_X2,y2=_Y2, clock_wise=_Dir,major_axis=_W,minor_axis_H, angle1=_Angle1,angle2=_Angle2,id=_Id,rotation=_Rotation, line_style=_Style,arrow_head_w=_ArrowHeadW, arrow_head_h=_ArrowHeadH,obj_locked=_Locked, transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, arrow_head_w_spec=_ArrowHeadWSpec, arrow_head_h_spec=_ArrowHeadHSpec, transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % % Note: FileVersions 34, 35, and 36 are skipped. See check_file_version/1. % tgif_arc(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = arc(_Color,_BgColor,_ObjFill,_LineWidth,_PenPat,_Dash,_LtX,_LtY, _Xc,_Yc,_X1,_Y1,_X2,_Y2,_Dir,_W,_H,_Angle1,_Angle2,_Id, _Rotation,_Style,_ArrowHeadW,_ArrowHeadH,_Locked, _Transformed,_Invisible,_LineWidthSpec,_ArrowHeadWSpec, _ArrowHeadHSpec,_TransPat,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,bg_color=_BgColor,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,line_dash=_Dash, ltx=_LtX,lty=_LtY,xc=_Xc,yc=_Yc,x1=_X1,y1=_Y1,x2=_X2,y2=_Y2, clock_wise=_Dir,major_axis=_W,minor_axis_H, angle1=_Angle1,angle2=_Angle2,id=_Id,rotation=_Rotation, line_style=_Style,arrow_head_w=_ArrowHeadW, arrow_head_h=_ArrowHeadH,obj_locked=_Locked, transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, arrow_head_w_spec=_ArrowHeadWSpec, arrow_head_h_spec=_ArrowHeadHSpec,trans_pat=_TransPat, attrs=AttrList] | _Transformed = 1, Obj = arc(_Color,_BgColor,_ObjFill,_LineWidth,_PenPat,_Dash,_LtX,_LtY, _Xc,_Yc,_X1,_Y1,_X2,_Y2,_Dir,_W,_H,_Angle1,_Angle2,_Id, _Rotation,_Style,_ArrowHeadW,_ArrowHeadH,_Locked, _Transformed,_Invisible,_LineWidthSpec,_ArrowHeadWSpec, _ArrowHeadHSpec,_TransPat,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,bg_color=_BgColor,obj_fill=_ObjFill, line_width=_LineWidth,pen_pat=_PenPat,line_dash=_Dash, ltx=_LtX,lty=_LtY,xc=_Xc,yc=_Yc,x1=_X1,y1=_Y1,x2=_X2,y2=_Y2, clock_wise=_Dir,major_axis=_W,minor_axis_H, angle1=_Angle1,angle2=_Angle2,id=_Id,rotation=_Rotation, line_style=_Style,arrow_head_w=_ArrowHeadW, arrow_head_h=_ArrowHeadH,obj_locked=_Locked, transformed=_Transformed, invisible=_Invisible,line_width_spec=_LineWidthSpec, arrow_head_w_spec=_ArrowHeadWSpec, arrow_head_h_spec=_ArrowHeadHSpec,trans_pat=_TransPat, transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % --------------------------------------------------------------------- % tgif_xbm(Obj) :- tgif_xbm(Obj,_). tgif_xbm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 13, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_BitmapStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2,obj_fill=_ObjFill, id=_Id,xbm_str=_BitmapStr,attrs=AttrList], tgif_attrs(AttrList). tgif_xbm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 22, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation,_BitmapStr, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2,obj_fill=_ObjFill, id=_Id,rotation=_Rotation,xbm_str=_BitmapStr,attrs=AttrList], tgif_attrs(AttrList). tgif_xbm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 23, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation,_ImageW,_ImageH, _Rotate,_Flip,_BitmapStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2,obj_fill=_ObjFill, id=_Id,rotation=_Rotation,image_w=_ImageW,image_h=_ImageH, rotate=_Rotate,flip=_Flip,xbm_str=_BitmapStr,attrs=AttrList], tgif_attrs(AttrList). tgif_xbm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _RealType = 0, _NoBitmap = 0, Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Date,_File,_BitmapStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='xbm',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap, xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 1, _NoBitmap = 0, Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Date,_File,_BitmapStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap, date=_Date,file=_File,xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 1, _NoBitmap = 1, Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Date,_File,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap, date=_Date,file=_File,attrs=AttrList] ), tgif_attrs(AttrList). tgif_xbm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 28, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _RealType = 0, _NoBitmap = 0, Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_Date,_File,_BitmapStr, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='xbm',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, date=_Date,file=_File,xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 1, _NoBitmap = 0, Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_Date,_File,_BitmapStr, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, date=_Date,file=_File,xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 1, _NoBitmap = 1, Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_Date,_File,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, date=_Date,file=_File,attrs=AttrList] ), tgif_attrs(AttrList). tgif_xbm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _RealType = 0, _NoBitmap = 0, _SaveEPSF = 0, Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Date,_File,_BitmapStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='xbm',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF, date=_Date,file=_File,xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 1, _NoBitmap = 0, _SaveEPSF = 0, Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Date,_File,_BitmapStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF, date=_Date,file=_File,xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 1, _NoBitmap = 1, _SaveEPSF = 0, Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Date,_File,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF, date=_Date,file=_File,attrs=AttrList] | _RealType = 1, _NoBitmap = 0, _SaveEPSF = 1, Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Date,_File,_NumEPSFLines,_EPSFLines,_BitmapStr, AttrList), tgif_chk_output(OutputObj,Obj), length(_EPSFLines,_NumEPSFLines), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,num_epsf_lines=_NumEPSFLines, epsf_lines=_EPSFLines,date=_Date,file=_File, xbm_str=_BitmapStr,attrs=AttrList] ), tgif_attrs(AttrList). tgif_xbm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _RealType = 0, _NoBitmap = 0, _SaveEPSF = 0, _Transformed = 0, % Just XBM Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible, _Date,_File,_BitmapStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='xbm',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible, date=_Date,file=_File,xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 1, _NoBitmap = 0, _SaveEPSF = 0, _Transformed = 0, % What type is this? Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible, _Date,_File,_BitmapStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible, date=_Date,file=_File,xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 1, _NoBitmap = 1, _SaveEPSF = 0, _Transformed = 0, % Linked EPS Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible, _Date,_File,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible, date=_Date,file=_File,attrs=AttrList] | _RealType = 1, _NoBitmap = 0, _SaveEPSF = 1, _Transformed = 0, % Embeded EPS Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible, _Date,_File,_NumEPSFLines,_EPSFLines,_BitmapStr, AttrList), tgif_chk_output(OutputObj,Obj), length(_EPSFLines,_NumEPSFLines), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible, num_epsf_lines=_NumEPSFLines,epsf_lines=_EPSFLines, date=_Date,file=_File,xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 0, _NoBitmap = 0, _SaveEPSF = 0, _Transformed = 1, % Just XBM Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible, _Date,_File,_BitmapStr,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='xbm',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible, date=_Date,file=_File,xbm_str=_BitmapStr, transform_spec=TransformParms,attrs=AttrList] | _RealType = 1, _NoBitmap = 0, _SaveEPSF = 0, _Transformed = 1, % What type is this? Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible, _Date,_File,_BitmapStr,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible, date=_Date,file=_File,xbm_str=_BitmapStr, transform_spec=TransformParms,attrs=AttrList] | _RealType = 1, _NoBitmap = 1, _SaveEPSF = 0, _Transformed = 1, % Linked EPS Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible, _Date,_File,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible, date=_Date,file=_File,transform_spec=TransformParms, attrs=AttrList] | _RealType = 1, _NoBitmap = 0, _SaveEPSF = 1, _Transformed = 1, % Embeded EPS Obj = xbm(_Color,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible, _Date,_File,_NumEPSFLines,_EPSFLines,_BitmapStr, TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), length(_EPSFLines,_NumEPSFLines), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible, num_epsf_lines=_NumEPSFLines,epsf_lines=_EPSFLines, date=_Date,file=_File,xbm_str=_BitmapStr, transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % % Note: FileVersions 34, 35, and 36 are skipped. See check_file_version/1. % tgif_xbm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _RealType = 0, _NoBitmap = 0, _SaveEPSF = 0, _Transformed = 0, % Just XBM Obj = xbm(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible,_TransPat, _Date,_File,_BitmapStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='xbm',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible,trans_pat=_TransPat, date=_Date,file=_File,xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 1, _NoBitmap = 0, _SaveEPSF = 0, _Transformed = 0, % What type is this? Obj = xbm(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible,_TransPat, _Date,_File,_BitmapStr,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible,trans_pat=_TransPat, date=_Date,file=_File,xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 1, _NoBitmap = 1, _SaveEPSF = 0, _Transformed = 0, % Linked EPS Obj = xbm(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible,_TransPat, _Date,_File,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible,trans_pat=_TransPat, date=_Date,file=_File,attrs=AttrList] | _RealType = 1, _NoBitmap = 0, _SaveEPSF = 1, _Transformed = 0, % Embeded EPS Obj = xbm(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible,_TransPat, _Date,_File,_NumEPSFLines,_EPSFLines,_BitmapStr, AttrList), tgif_chk_output(OutputObj,Obj), length(_EPSFLines,_NumEPSFLines), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible,trans_pat=_TransPat, num_epsf_lines=_NumEPSFLines,epsf_lines=_EPSFLines, date=_Date,file=_File,xbm_str=_BitmapStr,attrs=AttrList] | _RealType = 0, _NoBitmap = 0, _SaveEPSF = 0, _Transformed = 1, % Just XBM Obj = xbm(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible,_TransPat, _Date,_File,_BitmapStr,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='xbm',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible,trans_pat=_TransPat, date=_Date,file=_File,xbm_str=_BitmapStr, transform_spec=TransformParms,attrs=AttrList] | _RealType = 1, _NoBitmap = 0, _SaveEPSF = 0, _Transformed = 1, % What type is this? Obj = xbm(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible,_TransPat, _Date,_File,_BitmapStr,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible,trans_pat=_TransPat, date=_Date,file=_File,xbm_str=_BitmapStr, transform_spec=TransformParms,attrs=AttrList] | _RealType = 1, _NoBitmap = 1, _SaveEPSF = 0, _Transformed = 1, % Linked EPS Obj = xbm(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible,_TransPat, _Date,_File,TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible,trans_pat=_TransPat, date=_Date,file=_File,transform_spec=TransformParms, attrs=AttrList] | _RealType = 1, _NoBitmap = 0, _SaveEPSF = 1, _Transformed = 1, % Embeded EPS Obj = xbm(_Color,_BgColor,_X1,_Y1,_X2,_Y2,_ObjFill,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_RealType,_LLX,_LLY, _URX,_URY,_NoBitmap,_Locked,_SaveEPSF, _Compressed,_Transformed,_Invisible,_TransPat, _Date,_File,_NumEPSFLines,_EPSFLines,_BitmapStr, TransformSpec,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), length(_EPSFLines,_NumEPSFLines), Parms = [color=_Color,bg_color=_BgColor,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_ObjFill,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate, flip=_Flip,real_type='eps',llx=_LLX,lly=_LLY, urx=_URX,ury=_URY,no_bitmap=_NoBitmap,obj_locked=_Locked, save_epsf=_SaveEPSF,compressed=_Compressed, transformed=_Transformed,invisible=_Invisible,trans_pat=_TransPat, num_epsf_lines=_NumEPSFLines,epsf_lines=_EPSFLines, date=_Date,file=_File,xbm_str=_BitmapStr, transform_spec=TransformParms,attrs=AttrList] ), tgif_attrs(AttrList). % --------------------------------------------------------------------- % tgif_xpm(Obj) :- tgif_xpm(Obj,_). tgif_xpm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 13, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = xpm(_Color,_X1,_Y1,_X2,_Y2,_UnUsedObjFill,_NumColors,_Id, ColorNames,Pixels,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_UnUsedObjFill,num_colors=_NumColors,id=_Id, color_names=ColorNames,pixels=Pixels,attrs=AttrList], tgif_color_info(ColorNames), tgif_pixels(Pixels), tgif_attrs(AttrList). tgif_xpm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 14, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = xpm(_Color,_X1,_Y1,_X2,_Y2,_UnUsedObjFill,_NumColors,_Id, _Rotation,ColorNames,Pixels,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_UnUsedObjFill,num_colors=_NumColors,id=_Id, rotation=_Rotation,color_names=ColorNames,pixels=Pixels, attrs=AttrList], tgif_color_info(ColorNames), tgif_pixels(Pixels), tgif_attrs(AttrList). tgif_xpm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 22, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = xpm(_Color,_X1,_Y1,_X2,_Y2,_UnUsedObjFill,_NumColors, _CharsPerPixel,_FirstPixelIsBg,_Id,_Rotation,ColorNames,Pixels, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_UnUsedObjFill,num_colors=_NumColors, chars_per_pixel=_CharsPerPixel, first_pixel_is_bg=_FirstPixelIsBg,id=_Id, rotation=_Rotation,color_names=ColorNames,pixels=Pixels, attrs=AttrList], tgif_color_info(ColorNames), tgif_pixels(Pixels), tgif_attrs(AttrList). tgif_xpm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = xpm(_Color,_X1,_Y1,_X2,_Y2,_UnUsedObjFill,_NumColors, _CharsPerPixel,_FirstPixelIsBg,_Id,_Rotation,_ImageW,_ImageH, _Rotate,_Flip,ColorNames,Pixels,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_UnUsedObjFill,num_colors=_NumColors, chars_per_pixel=_CharsPerPixel, first_pixel_is_bg=_FirstPixelIsBg,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate,flip=_Flip, color_names=ColorNames,pixels=Pixels,attrs=AttrList], tgif_color_info(ColorNames), tgif_pixels(Pixels), tgif_attrs(AttrList). tgif_xpm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = xpm(_Color,_X1,_Y1,_X2,_Y2,_UnUsedObjFill,_NumColors, _CharsPerPixel,_FirstPixelIsBg,_Id,_Rotation,_ImageW,_ImageH, _Rotate,_Flip,_Locked,ColorNames,Pixels,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_UnUsedObjFill,num_colors=_NumColors, chars_per_pixel=_CharsPerPixel, first_pixel_is_bg=_FirstPixelIsBg,id=_Id,rotation=_Rotation, image_w=_ImageW,image_h=_ImageH,rotate=_Rotate,flip=_Flip, obj_locked=_Locked,color_names=ColorNames,pixels=Pixels, attrs=AttrList], tgif_color_info(ColorNames), tgif_pixels(Pixels), tgif_attrs(AttrList). tgif_xpm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = xpm(_Color,_X1,_Y1,_X2,_Y2,_UnUsedObjFill,_NumColors, _CharsPerPixel,_FirstPixelIsBg,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_Locked,_Compressed, _Transformed,_Invisible,ColorNames,Pixels,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_UnUsedObjFill,num_colors=_NumColors, chars_per_pixel=_CharsPerPixel, first_pixel_is_bg=_FirstPixelIsBg,id=_Id, rotation=_Rotation,image_w=_ImageW,image_h=_ImageH, rotate=_Rotate,flip=_Flip,obj_locked=_Locked, compressed=_Compressed,transformed=_Transformed, invisible=_Invisible,color_names=ColorNames, pixels=Pixels,attrs=AttrList] | _Transformed = 1, Obj = xpm(_Color,_X1,_Y1,_X2,_Y2,_UnUsedObjFill,_NumColors, _CharsPerPixel,_FirstPixelIsBg,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_Locked,_Compressed, _Transformed,_Invisible,TransformSpec,ColorNames, Pixels,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2, obj_fill=_UnUsedObjFill,num_colors=_NumColors, chars_per_pixel=_CharsPerPixel, first_pixel_is_bg=_FirstPixelIsBg,id=_Id, rotation=_Rotation,image_w=_ImageW,image_h=_ImageH, rotate=_Rotate,flip=_Flip,obj_locked=_Locked, compressed=_Compressed,transformed=_Transformed, invisible=_Invisible,transform_spec=TransformParms, color_names=ColorNames,pixels=Pixels,attrs=AttrList] ), tgif_color_info(ColorNames), tgif_pixels(Pixels), tgif_attrs(AttrList). % % Note: FileVersions 34, 35, and 36 are skipped. See check_file_version/1. % tgif_xpm(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( _Transformed = 0, Obj = xpm(_Color,_TransColor,_X1,_Y1,_X2,_Y2,_UnUsedObjFill,_NumColors, _CharsPerPixel,_FirstPixelIsBg,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_Locked,_Compressed, _Transformed,_Invisible,ColorNames,Pixels,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,trans_color=_TransColor, ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2,obj_fill=_UnUsedObjFill, num_colors=_NumColors,chars_per_pixel=_CharsPerPixel, first_pixel_is_bg=_FirstPixelIsBg,id=_Id, rotation=_Rotation,image_w=_ImageW,image_h=_ImageH, rotate=_Rotate,flip=_Flip,obj_locked=_Locked, compressed=_Compressed,transformed=_Transformed, invisible=_Invisible,color_names=ColorNames, pixels=Pixels,attrs=AttrList] | _Transformed = 1, Obj = xpm(_Color,_TransColor,_X1,_Y1,_X2,_Y2,_UnUsedObjFill,_NumColors, _CharsPerPixel,_FirstPixelIsBg,_Id,_Rotation, _ImageW,_ImageH,_Rotate,_Flip,_Locked,_Compressed, _Transformed,_Invisible,TransformSpec,ColorNames, Pixels,AttrList), tgif_chk_output(OutputObj,Obj), tgif_obj_transform_spec(TransformSpec,TransformParms), Parms = [color=_Color,trans_color=_TransColor, ltx=_X1,lty=_Y1,rbx=_X2,rby=_Y2,obj_fill=_UnUsedObjFill, num_colors=_NumColors,chars_per_pixel=_CharsPerPixel, first_pixel_is_bg=_FirstPixelIsBg,id=_Id, rotation=_Rotation,image_w=_ImageW,image_h=_ImageH, rotate=_Rotate,flip=_Flip,obj_locked=_Locked, compressed=_Compressed,transformed=_Transformed, invisible=_Invisible,transform_spec=TransformParms, color_names=ColorNames,pixels=Pixels,attrs=AttrList] ), tgif_color_info(ColorNames), tgif_pixels(Pixels), tgif_attrs(AttrList). % --------------------------------------------------------------------- % tgif_group(Obj) :- tgif_group(Obj,_). tgif_group(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 20, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = group(ObjList,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [objs=ObjList,attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). tgif_group(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = group(ObjList,_Id,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [objs=ObjList,id=_Id,attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). tgif_group(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = group(ObjList,_Id,_Locked,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [objs=ObjList,id=_Id,obj_locked=_Locked,attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). tgif_group(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = group(ObjList,_Id,_Locked,_Invisible,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [objs=ObjList,id=_Id,obj_locked=_Locked,invisible=_Invisible, attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). % --------------------------------------------------------------------- % tgif_sym(Obj) :- tgif_sym(Obj,_). tgif_sym(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 20, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = sym(ObjList,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [objs=ObjList,attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). tgif_sym(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = sym(ObjList,_Id,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [objs=ObjList,id=_Id,attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). tgif_sym(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = sym(ObjList,_Id,_Locked,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [objs=ObjList,id=_Id,obj_locked=_Locked,attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). tgif_sym(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = sym(ObjList,_Id,_Locked,_Invisible,_AttrList), tgif_chk_output(OutputObj,Obj), Parms = [objs=ObjList,id=_Id,obj_locked=_Locked,invisible=_Invisible, attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). % --------------------------------------------------------------------- % tgif_icon(Obj) :- tgif_icon(Obj,_). tgif_icon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 12, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = icon(ObjList,_Name,_Id,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [name=_Name,id=_Id,objs=ObjList,attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). tgif_icon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 25, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = icon(ObjList,_Name,_Id,_Rotation,_Flip,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [name=_Name,id=_Id,rotation=_Rotation,objs=ObjList, attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). tgif_icon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = icon(ObjList,_Name,_Id,_Rotation,_Flip,_Locked,AttrList), tgif_chk_output(OutputObj,Obj), Parms = [name=_Name,id=_Id,rotation=_Rotation,obj_locked=_Locked, objs=ObjList,attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). tgif_icon(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = icon(ObjList,_Name,_Id,_Rotation,_Flip,_Locked,_Invisible, AttrList), tgif_chk_output(OutputObj,Obj), Parms = [name=_Name,id=_Id,rotation=_Rotation,obj_locked=_Locked, invisible=_Invisible,objs=ObjList,attrs=AttrList], tgif_objs(ObjList), tgif_attrs(AttrList). % ======================== support routines =========================== % tgif_clean :- tgif_clean(state). tgif_real_clean :- tgif_clean(state), tgif_clean(text), tgif_clean(box), tgif_clean(oval), tgif_clean(poly), tgif_clean(polygon), tgif_clean(rcbox), tgif_clean(arc), tgif_clean(xbm), tgif_clean(xpm), tgif_clean(group), tgif_clean(sym), tgif_clean(icon). tgif_clean(Type) :- current_predicate(Type,Term), functor(Term,_F,A), abolish(Type,A), fail. tgif_clean(_Type) :- !. tgif_chk_output(true,Obj) :- !, functor(Obj,Functor,Arity), functor(DummyObj,Functor,Arity), current_predicate(Functor,DummyObj), !, call(Obj). tgif_chk_output(_OutputObj,_Obj). % --------------------------------------------------------------------- % tgif_strs([]) :- !. tgif_strs([Str|Strs]) :- atom_chars(_Line,Str), !, tgif_strs(Strs). % --------------------------------------------------------------------- % tgif_strseg(Obj) :- tgif_strseg(Obj,_). tgif_strseg(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = str_seg(_Color,_FontName,_TextStyle,_FontSzUnit, _W,_Asc,_Des,_MinLBearing,_MaxRExtra,_UnderlineOn, _DoubleByte,_DBModBytes,_DBVertical,_Direction,Str), tgif_chk_output(OutputObj,Obj), Parms = [color=_Color,font_name=_FontName,text_style=_TextStyle, font_sz_unit=_FontSzUnit,w=_W,asc=_Asc,des=_Des, min_lbearing=_MinLBearing,max_rextra=_MaxRExtra, underline_on=_UnderlineOn,double_byte=_DoubleByte, db_mod_bytes=_DBModBytes,db_vertical=_DBVertical,direction=_Direction, str=Str], atom_chars(_Str,Str). % --------------------------------------------------------------------- % tgif_strblock_list([SimpleStrBlock]) :- !, tgif_simple_strblock(SimpleStrBlock). tgif_strblock_list([SimpleStrBlock1,SimpleStrBlock2|StrBlocks]) :- tgif_simple_strblock(SimpleStrBlock1), tgif_simple_strblock(SimpleStrBlock2), !, tgif_strblock_list([SimpleStrBlock2|StrBlocks]). tgif_strblock_list([SimpleStrBlock,ComplexStrBlock|StrBlocks]) :- tgif_simple_strblock(SimpleStrBlock), tgif_complex_strblock(ComplexStrBlock), !, tgif_strblock_list(StrBlocks). tgif_simple_strblock(StrBlock) :- tgif_simple_strblock(StrBlock,_). tgif_simple_strblock(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = str_block(0,_W,_Asc,_Des,_MinLBearing,_MaxRExtra,_,_,_, [_StrSeg]), tgif_chk_output(OutputObj,Obj), Parms = [w=_W,asc=_Asc,des=_Des,min_lbearing=_MinLBearing, max_rextra=_MaxRExtra,str_seg=_StrSeg], tgif_strseg(_StrSeg). tgif_complex_strblock(StrBlock) :- tgif_complex_strblock(StrBlock,_). tgif_complex_strblock(StrBlock,Parms) :- tgif_space_strblock(StrBlock,Parms), !. tgif_complex_strblock(StrBlock,Parms) :- tgif_center_supsub_strblock(StrBlock,Parms), !. tgif_complex_strblock(StrBlock,Parms) :- tgif_leftright_supsub_strblock(StrBlock,Parms), !. tgif_space_strblock(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = str_block(4,_W,_,_,_,_,_SpaceW,0,0), !, tgif_chk_output(OutputObj,Obj), Parms = [type=4,w=_W,space_w=_SpaceW]. tgif_center_supsub_strblock(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = str_block(2,_W,_Asc,_Des,_MinLBearing,_MaxRExtra,_,1,1, [_SupMinilines,_SubMinilines,_StrSeg]), !, tgif_chk_output(OutputObj,Obj), Parms = [type=2,w=_W,asc=_Asc,des=_Des,min_lbearing=_MinLBearing, max_rextra=_MaxRExtra,sup_minilines=_SupMinilines, _sub_minilines=_SubMinilines,str_seg=_StrSeg], !, tgif_minilines(_SupMinilines), !, tgif_minilines(_SubMinilines), !, tgif_strseg(_StrSeg). tgif_leftright_supsub_strblock(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = str_block(_Type,_W,_Asc,_Des,_MinLBearing,_MaxRExtra,_,1,1, [_SupMinilines,_SubMinilines]), ( _Type == 1 | _Type == 3 ), !, tgif_chk_output(OutputObj,Obj), Parms = [type=_Type,w=_W,asc=_Asc,des=_Des,min_lbearing=_MinLBearing, max_rextra=_MaxRExtra,sup_minilines=_SupMinilines, _sub_minilines=_SubMinilines], !, tgif_minilines(_SupMinilines), !, tgif_minilines(_SubMinilines). % --------------------------------------------------------------------- % tgif_miniline_list([]) :- !. tgif_miniline_list([Miniline|MinilineList]) :- tgif_miniline(Miniline), !, tgif_miniline_list(MinilineList). tgif_miniline(Obj) :- tgif_miniline(Obj,_). tgif_miniline(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = mini_line(_W,_Asc,_Des,_MinLBearing,_MaxRExtra,_VGap,_StrBlockList), tgif_chk_output(OutputObj,Obj), Parms = [w=_W,asc=_Asc,des=_Des,min_lbearing=_MinLBearing, max_rextra=_MaxRExtra,v_gap=_VGap, miniline_list=_StrBlockList], tgif_strblock_list(_StrBlockList). % --------------------------------------------------------------------- % tgif_minilines_list([]) :- !. tgif_minilines_list([Minilines|MinilinesList]) :- tgif_minilines(Minilines), !, tgif_minilines_list(MinilinesList). tgif_minilines(Obj) :- tgif_minilines(Obj,_). tgif_minilines(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = minilines(_W,_H,_MinLBearing,_MaxRExtra,_Just,_VSpace, _BaselineOffset,_MiniLineList), tgif_chk_output(OutputObj,Obj), Parms = [w=_W,h=_H,min_lbearing=_MinLBearing,max_rextra=_MaxRExtra, just=_Just,v_space=_VSpace,baseline_offset=_BaselineOffset, miniline_list=_MiniLineList], tgif_miniline_list(_MiniLineList). % --------------------------------------------------------------------- % tgif_obj(Obj) :- var(Obj), !, tgif_obj(_,Obj). tgif_obj(Obj) :- functor(Obj,Functor,_Arity), tgif_obj(Functor,Obj). tgif_obj(text,Obj) :- tgif_text(Obj). tgif_obj(box,Obj) :- tgif_box(Obj). tgif_obj(oval,Obj) :- tgif_oval(Obj). tgif_obj(poly,Obj) :- tgif_poly(Obj). tgif_obj(polygon,Obj) :- tgif_polygon(Obj). tgif_obj(rcbox,Obj) :- tgif_rcbox(Obj). tgif_obj(arc,Obj) :- tgif_arc(Obj). tgif_obj(xbm,Obj) :- tgif_xbm(Obj). tgif_obj(xpm,Obj) :- tgif_xpm(Obj). tgif_obj(group,Obj) :- tgif_group(Obj). tgif_obj(sym,Obj) :- tgif_sym(Obj). tgif_obj(icon,Obj) :- tgif_icon(Obj). tgif_objs([]) :- !. tgif_objs([Obj|Objs]) :- tgif_obj(Obj), !, tgif_objs(Objs). % --------------------------------------------------------------------- % tgif_attrs([]) :- !. tgif_attrs([Attr|Attrs]) :- tgif_attr(Attr), !, tgif_attrs(Attrs). tgif_attr(Attr) :- tgif_attr(Attr,_). tgif_attr(Attr,Parms) :- Attr = attr(_Name,_Value,_ShowAll,_NameShown,_Inherited,TextObj), tgif_text(TextObj), Parms = [name=_Name,value=_Value,show_all=_ShowAll, name_shown=_NameShown,inherited=_Inherited,text_obj=TextObj], tgif_text(TextObj). % --------------------------------------------------------------------- % tgif_arrow(Obj) :- tgif_arrow(Obj,_). tgif_arrow(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 37, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = [_ArrowHeadStyle,_ArrowHeadW,_ArrowHeadH,_ArrowHeadIndent, _ArrowHeadWSpec,_ArrowHeadHSpec,_ArrowHeadIndentSpec], tgif_chk_output(OutputObj,Obj), Parms = [arrow_head_style=_ArrowHeadStyle, arrow_head_w=_ArrowHeadW,arrow_head_h=_ArrowHeadH, arrow_head_indent=_ArrowHeadIndent, arrow_head_w_spec=_ArrowHeadWSpec, arrow_head_h_spec=_ArrowHeadHSpec, arrow_head_indent_spec=_ArrowHeadIndentSpec]. % --------------------------------------------------------------------- % tgif_color_info([]) :- !. tgif_color_info([ColorChar,ColorName,_Red,_Green,_Blue|ColorInfos]) :- atom_chars(_Char,ColorChar), atom_chars(_Color,ColorName), !, tgif_color_info(ColorInfos). % --------------------------------------------------------------------- % tgif_pixels([]) :- !. tgif_pixels([_RowOfChar|Pixels]) :- !, tgif_pixels(Pixels). % --------------------------------------------------------------------- % tgif_obj_transform_spec(Spec,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 33, !, Spec = [_OrigX,_OrigY,_OrigLtX,_OrigLtY,_OrigRbX,_OrigRbY, _CTM_SX,_CTM_SIN,_CTM_MSIN,_CTM_SY,_CTM_TX,_CTM_TY], Parms = [orig_x=_OrigX,orig_x=_OrigY,orig_ltx=_OrigLtX, orig_lty=_OrigLtY,orig_rbx=_OrigRbX,orig_rby=_OrigRbY, ctm_sx=_CTM_SX,ctm_sin=_CTM_SIN,ctm_msin=_CTM_MSIN, ctm_sy=_CTM_SY,ctm_tx=_CTM_TX,ctm_ty=_CTM_TY]. tgif_text_transform_spec(Spec,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 33, !, Spec = [_OrigX,_OrigY, _OrigOBBoxLtX,_OrigOBBoxLtY,_OrigOBBoxRbX,_OrigOBBoxRbY, _CTM_SX,_CTM_SIN,_CTM_MSIN,_CTM_SY,_CTM_TX,_CTM_TY, _OrigBBoxLtX,_OrigBBoxLtY,_OrigBBoxRbX,_OrigBBoxRbY], Parms = [orig_x=_OrigX,orig_x=_OrigY,orig_obbox_ltx=_OrigOBBoxLtX, orig_obbox_lty=_OrigOBBoxLtY,orig_obbox_rbx=_OrigOBBoxRbX, orig_obbox_rby=_OrigOBBoxRbY, ctm_sx=_CTM_SX,ctm_sin=_CTM_SIN,ctm_msin=_CTM_MSIN, ctm_sy=_CTM_SY,ctm_tx=_CTM_TX,ctm_ty=_CTM_TY, orig_bbox_ltx=_OrigBBoxLtX,orig_bbox_lty=_OrigBBoxLtY, orig_bbox_rbx=_OrigBBoxRbX,orig_bbox_rby=_OrigBBoxRbY]. % ======================= non=graphical objects ======================= % % --------------------------------------------------------------------- % tgif_page(Obj) :- tgif_page(Obj,_). tgif_page(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion =< 32, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = page(_PageNum,_PageName), tgif_chk_output(OutputObj,Obj), Parms = [page_num=_PageNum,page_name=_PageName]. tgif_page(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), ( Obj = page(_PageNum,_PageName,_) | Obj = page(_PageNum,_PageName,_,_) ), tgif_chk_output(OutputObj,Obj), Parms = [page_num=_PageNum,page_name=_PageName]. % --------------------------------------------------------------------- % tgif_unit(Obj) :- tgif_unit(Obj,_). tgif_unit(Obj,Parms) :- current_predicate(tgif_file_version,tgif_file_version(_)), tgif_file_version(FileVersion), FileVersion >= 33, !, ( var(Obj) -> OutputObj = true ; OutputObj = false ), Obj = unit(_UnitSpec), tgif_chk_output(OutputObj,Obj), Parms = [unit_spec=_UnitSpec]. �����������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Makefile.in��������������������������������������������������������������������������0000644�0000764�0000764�00000073433�11602233376�015055� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# Makefile.in generated by automake 1.10 from Makefile.am. # @configure_input@ # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005, 2006 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. @SET_MAKE@ VPATH = @srcdir@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : bin_PROGRAMS = tgif$(EXEEXT) subdir = . DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in $(srcdir)/config.h.in \ $(top_srcdir)/configure AUTHORS ChangeLog NEWS depcomp \ install-sh missing mkinstalldirs ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(tgifdir)" binPROGRAMS_INSTALL = $(INSTALL_PROGRAM) PROGRAMS = $(bin_PROGRAMS) am_tgif_OBJECTS = align.$(OBJEXT) animate.$(OBJEXT) arc.$(OBJEXT) \ attr.$(OBJEXT) auxtext.$(OBJEXT) box.$(OBJEXT) \ button.$(OBJEXT) chat.$(OBJEXT) chinput.$(OBJEXT) \ choice.$(OBJEXT) choose.$(OBJEXT) cli_xcin.$(OBJEXT) \ convkinput.$(OBJEXT) convxim.$(OBJEXT) cmd.$(OBJEXT) \ color.$(OBJEXT) cutpaste.$(OBJEXT) cursor.$(OBJEXT) \ dialog.$(OBJEXT) drawing.$(OBJEXT) dup.$(OBJEXT) \ edit.$(OBJEXT) eps.$(OBJEXT) exec.$(OBJEXT) expr.$(OBJEXT) \ file.$(OBJEXT) font.$(OBJEXT) ftp.$(OBJEXT) grid.$(OBJEXT) \ group.$(OBJEXT) hash.$(OBJEXT) help.$(OBJEXT) http.$(OBJEXT) \ imgproc.$(OBJEXT) import.$(OBJEXT) ini.$(OBJEXT) \ inmethod.$(OBJEXT) list.$(OBJEXT) mainloop.$(OBJEXT) \ mainmenu.$(OBJEXT) mark.$(OBJEXT) markup.$(OBJEXT) \ menu.$(OBJEXT) menuinfo.$(OBJEXT) miniline.$(OBJEXT) \ move.$(OBJEXT) msg.$(OBJEXT) names.$(OBJEXT) \ navigate.$(OBJEXT) nkf.$(OBJEXT) obj.$(OBJEXT) oval.$(OBJEXT) \ page.$(OBJEXT) pattern.$(OBJEXT) pin.$(OBJEXT) \ pngtrans.$(OBJEXT) poly.$(OBJEXT) polygon.$(OBJEXT) \ ps.$(OBJEXT) raster.$(OBJEXT) rcbox.$(OBJEXT) rect.$(OBJEXT) \ remote.$(OBJEXT) rm_intrf.$(OBJEXT) ruler.$(OBJEXT) \ scroll.$(OBJEXT) select.$(OBJEXT) setup.$(OBJEXT) \ shape.$(OBJEXT) shortcut.$(OBJEXT) special.$(OBJEXT) \ spline.$(OBJEXT) stk.$(OBJEXT) stream.$(OBJEXT) \ stretch.$(OBJEXT) strtbl.$(OBJEXT) tangram2.$(OBJEXT) \ tdgtbase.$(OBJEXT) tdgtbmpl.$(OBJEXT) tdgtbrow.$(OBJEXT) \ tdgtbtn.$(OBJEXT) tdgtdraw.$(OBJEXT) tdgtlist.$(OBJEXT) \ tdgtmsg.$(OBJEXT) tdgtsedt.$(OBJEXT) tgif_dbg.$(OBJEXT) \ tgcwheel.$(OBJEXT) tgcwdl.$(OBJEXT) tginssym.$(OBJEXT) \ tgisdl.$(OBJEXT) tgtwb5.$(OBJEXT) tgif.$(OBJEXT) \ tgtwb5dl.$(OBJEXT) tgtwb5xl.$(OBJEXT) tidget.$(OBJEXT) \ tcp.$(OBJEXT) text.$(OBJEXT) util.$(OBJEXT) version.$(OBJEXT) \ vms_comp.$(OBJEXT) wb.$(OBJEXT) wb1.$(OBJEXT) wb2.$(OBJEXT) \ wb3.$(OBJEXT) wb_buff.$(OBJEXT) wb_mcast.$(OBJEXT) \ wb_seg.$(OBJEXT) xbitmap.$(OBJEXT) xpixmap.$(OBJEXT) \ xprtfltr.$(OBJEXT) z_intrf.$(OBJEXT) tgif_OBJECTS = $(am_tgif_OBJECTS) tgif_DEPENDENCIES = DEFAULT_INCLUDES = -I.@am__isrc@ depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ SOURCES = $(tgif_SOURCES) DIST_SOURCES = $(tgif_SOURCES) am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = `echo $$p | sed -e 's|^.*/||'`; tgifDATA_INSTALL = $(INSTALL_DATA) DATA = $(tgif_DATA) ETAGS = etags CTAGS = ctags DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ { test ! -d $(distdir) \ || { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \ && rm -fr $(distdir); }; } DIST_ARCHIVES = $(distdir).tar.gz GZIP_ENV = --best distuninstallcheck_listfiles = find . -type f -print distcleancheck_listfiles = find . -type f -print ACLOCAL = @ACLOCAL@ AMTAR = @AMTAR@ AUTOCONF = @AUTOCONF@ AUTOHEADER = @AUTOHEADER@ AUTOMAKE = @AUTOMAKE@ AWK = @AWK@ CC = @CC@ CCDEPMODE = @CCDEPMODE@ CFLAGS = -DVERSION=\"$(VERSION)\" -DPROG="\"$(PACKAGE)\"" \ -Wall -I/usr/X11R6/include -DHAVE_CONFIG_H -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 -DLOCALEDIR=\"/usr/share/locale\" -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" -DEPSF_FILE_EXT=\"eps\" -DPS_FILE_EXT=\"ps\" -DXBM_FILE_EXT=\"xbm\" -DXPM_FILE_EXT=\"xpm\" -DOBJ_FILE_EXT=\"obj\" -DSYM_FILE_EXT=\"sym\" -DTEXT_FILE_EXT=\"txt\" -DPIN_FILE_EXT=\"pin\" -DNETLIST_FILE_EXT=\"net\" -DCOMP_FILE_EXT=\"cmp\" -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" -DDEFATTRGROUP=\"TANGRAM-II:Declaration:Events:Messages:Rewards:Initialization:Watches\" -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN -DUSE_XT_INITIALIZE -D_NO_LOCALE_SUPPORT CPP = @CPP@ CPPFLAGS = @CPPFLAGS@ CYGPATH_W = @CYGPATH_W@ DEFS = @DEFS@ DEPDIR = @DEPDIR@ ECHO_C = @ECHO_C@ ECHO_N = @ECHO_N@ ECHO_T = @ECHO_T@ EGREP = @EGREP@ EXEEXT = @EXEEXT@ GREP = @GREP@ INSTALL = @INSTALL@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ LDFLAGS = @LDFLAGS@ LIBOBJS = @LIBOBJS@ LIBS = @LIBS@ LTLIBOBJS = @LTLIBOBJS@ MAKEINFO = @MAKEINFO@ MKDIR_P = @MKDIR_P@ OBJEXT = @OBJEXT@ PACKAGE = @PACKAGE@ PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ PACKAGE_NAME = @PACKAGE_NAME@ PACKAGE_STRING = @PACKAGE_STRING@ PACKAGE_TARNAME = @PACKAGE_TARNAME@ PACKAGE_VERSION = @PACKAGE_VERSION@ PATH_SEPARATOR = @PATH_SEPARATOR@ POW_LIB = @POW_LIB@ SET_MAKE = @SET_MAKE@ SHELL = @SHELL@ STRIP = @STRIP@ VERSION = @VERSION@ XMKMF = @XMKMF@ abs_builddir = @abs_builddir@ abs_srcdir = @abs_srcdir@ abs_top_builddir = @abs_top_builddir@ abs_top_srcdir = @abs_top_srcdir@ ac_ct_CC = @ac_ct_CC@ am__include = @am__include@ am__leading_dot = @am__leading_dot@ am__quote = @am__quote@ am__tar = @am__tar@ am__untar = @am__untar@ bindir = @bindir@ build_alias = @build_alias@ builddir = @builddir@ datadir = @datadir@ datarootdir = @datarootdir@ docdir = @docdir@ dvidir = @dvidir@ exec_prefix = @exec_prefix@ host_alias = @host_alias@ htmldir = @htmldir@ includedir = @includedir@ infodir = @infodir@ install_sh = @install_sh@ libdir = @libdir@ libexecdir = @libexecdir@ localedir = @localedir@ localstatedir = @localstatedir@ mandir = @mandir@ mkdir_p = @mkdir_p@ oldincludedir = @oldincludedir@ pdfdir = @pdfdir@ prefix = @prefix@ program_transform_name = @program_transform_name@ psdir = @psdir@ sbindir = @sbindir@ sharedstatedir = @sharedstatedir@ srcdir = @srcdir@ sysconfdir = @sysconfdir@ target_alias = @target_alias@ top_builddir = @top_builddir@ top_srcdir = @top_srcdir@ # # @(#)$Header: /mm2/home/cvs/bc-src/tgif/Makefile.am,v 1.21 2011/01/18 05:17:27 william Exp $ # AUTOMAKE_OPTIONS = foreign TGIFDIR = $(libdir)/X11/tgif tgif_SOURCES = \ align.c animate.c arc.c attr.c auxtext.c \ box.c button.c \ chat.c chinput.c choice.c choose.c cli_xcin.c \ convkinput.c convxim.c cmd.c color.c cutpaste.c \ cursor.c \ dialog.c drawing.c dup.c \ edit.c eps.c exec.c expr.c \ file.c font.c ftp.c \ grid.c group.c \ hash.c help.c http.c \ imgproc.c import.c ini.c inmethod.c \ list.c \ mainloop.c mainmenu.c mark.c markup.c menu.c \ menuinfo.c miniline.c move.c msg.c \ names.c navigate.c nkf.c \ obj.c oval.c \ page.c pattern.c pin.c pngtrans.c poly.c polygon.c ps.c \ raster.c rcbox.c rect.c remote.c rm_intrf.c ruler.c \ scroll.c select.c setup.c shape.c shortcut.c \ special.c spline.c stk.c stream.c stretch.c \ strtbl.c \ tangram2.c tdgtbase.c tdgtbmpl.c tdgtbrow.c tdgtbtn.c tdgtdraw.c \ tdgtlist.c tdgtmsg.c tdgtsedt.c tgif_dbg.c tgcwheel.c \ tgcwdl.c tginssym.c tgisdl.c tgtwb5.c tgif.c tgtwb5dl.c \ tgtwb5xl.c tidget.c tcp.c text.c \ util.c \ version.c vms_comp.c \ wb.c wb1.c wb2.c wb3.c wb_buff.c wb_mcast.c \ wb_seg.c \ xbitmap.c xpixmap.c xprtfltr.c \ z_intrf.c tgif_LDADD = -L/usr/X11R6/lib -lXext -lX11 -lXt -lSM -lICE -lXmu -lm -lz tgifdir = $(TGIFDIR) tgif_DATA = tgif.Xdefaults tgificon.eps tgificon.obj tgificon.xbm tgificon.xpm tgif.gif tangram.sym eq4.sym eq4-2x.sym eq4-ps2epsi.sym eq4-epstool.sym eq4xpm.sym eq4-lyx-ps2epsi.sym eq4xpm-land.sym eq4png.sym eq4jpg.sym eq4-2x-jpg.sym eq4-2x-nowin-jpg.sym keys.obj Copyright License all: config.h $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .o .obj am--refresh: @: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ echo ' cd $(srcdir) && $(AUTOMAKE) --foreign '; \ cd $(srcdir) && $(AUTOMAKE) --foreign \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --foreign Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ echo ' $(SHELL) ./config.status'; \ $(SHELL) ./config.status;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck $(top_srcdir)/configure: $(am__configure_deps) cd $(srcdir) && $(AUTOCONF) $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) config.h: stamp-h1 @if test ! -f $@; then \ rm -f stamp-h1; \ $(MAKE) $(AM_MAKEFLAGS) stamp-h1; \ else :; fi stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status @rm -f stamp-h1 cd $(top_builddir) && $(SHELL) ./config.status config.h $(srcdir)/config.h.in: $(am__configure_deps) cd $(top_srcdir) && $(AUTOHEADER) rm -f stamp-h1 touch $@ distclean-hdr: -rm -f config.h stamp-h1 install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; for p in $$list; do \ p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ if test -f $$p \ ; then \ f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \ echo " $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ else :; fi; \ done uninstall-binPROGRAMS: @$(NORMAL_UNINSTALL) @list='$(bin_PROGRAMS)'; for p in $$list; do \ f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \ echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \ rm -f "$(DESTDIR)$(bindir)/$$f"; \ done clean-binPROGRAMS: -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) tgif$(EXEEXT): $(tgif_OBJECTS) $(tgif_DEPENDENCIES) @rm -f tgif$(EXEEXT) $(LINK) $(tgif_OBJECTS) $(tgif_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/align.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/animate.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/arc.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/attr.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/auxtext.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/box.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/button.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/chat.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/chinput.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/choice.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/choose.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cli_xcin.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cmd.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/color.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/convkinput.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/convxim.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cursor.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cutpaste.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dialog.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/drawing.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dup.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/edit.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/eps.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/exec.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/expr.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/file.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/font.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ftp.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/grid.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/group.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hash.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/help.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/http.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/imgproc.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/import.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ini.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/inmethod.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/list.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mainloop.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mainmenu.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mark.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/markup.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/menu.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/menuinfo.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/miniline.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/move.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/msg.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/names.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/navigate.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/nkf.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/obj.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/oval.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/page.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pattern.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pin.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pngtrans.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/poly.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/polygon.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ps.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/raster.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rcbox.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rect.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/remote.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rm_intrf.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ruler.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/scroll.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/select.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/setup.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/shape.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/shortcut.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/special.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/spline.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stk.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stream.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stretch.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/strtbl.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tangram2.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tcp.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdgtbase.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdgtbmpl.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdgtbrow.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdgtbtn.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdgtdraw.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdgtlist.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdgtmsg.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tdgtsedt.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/text.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgcwdl.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgcwheel.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgif.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgif_dbg.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tginssym.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgisdl.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgtwb5.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgtwb5dl.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tgtwb5xl.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tidget.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/util.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/version.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vms_comp.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wb.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wb1.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wb2.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wb3.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wb_buff.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wb_mcast.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wb_seg.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xbitmap.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xpixmap.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xprtfltr.Po@am__quote@ @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/z_intrf.Po@am__quote@ .c.o: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< @am__fastdepCC_TRUE@ mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c $< .c.obj: @am__fastdepCC_TRUE@ $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` @am__fastdepCC_TRUE@ mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ @am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` install-tgifDATA: $(tgif_DATA) @$(NORMAL_INSTALL) test -z "$(tgifdir)" || $(MKDIR_P) "$(DESTDIR)$(tgifdir)" @list='$(tgif_DATA)'; for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ f=$(am__strip_dir) \ echo " $(tgifDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(tgifdir)/$$f'"; \ $(tgifDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(tgifdir)/$$f"; \ done uninstall-tgifDATA: @$(NORMAL_UNINSTALL) @list='$(tgif_DATA)'; for p in $$list; do \ f=$(am__strip_dir) \ echo " rm -f '$(DESTDIR)$(tgifdir)/$$f'"; \ rm -f "$(DESTDIR)$(tgifdir)/$$f"; \ done ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS TAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique; \ fi ctags: CTAGS CTAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) $(am__remove_distdir) test -d $(distdir) || mkdir $(distdir) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done -find $(distdir) -type d ! -perm -777 -exec chmod a+rwx {} \; -o \ ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r $(distdir) dist-gzip: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 $(am__remove_distdir) dist-tarZ: distdir tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z $(am__remove_distdir) dist-shar: distdir shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz $(am__remove_distdir) dist-zip: distdir -rm -f $(distdir).zip zip -rq $(distdir).zip $(distdir) $(am__remove_distdir) dist dist-all: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) # This target untars the dist file and tries a VPATH configuration. Then # it guarantees that the distribution is self-contained by making another # tarfile. distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac chmod -R a-w $(distdir); chmod a+w $(distdir) mkdir $(distdir)/_build mkdir $(distdir)/_inst chmod a-w $(distdir) dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ && cd $(distdir)/_build \ && ../configure --srcdir=.. --prefix="$$dc_install_base" \ $(DISTCHECK_CONFIGURE_FLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(MAKE) $(AM_MAKEFLAGS) check \ && $(MAKE) $(AM_MAKEFLAGS) install \ && $(MAKE) $(AM_MAKEFLAGS) installcheck \ && $(MAKE) $(AM_MAKEFLAGS) uninstall \ && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ distuninstallcheck \ && chmod -R a-w "$$dc_install_base" \ && ({ \ (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ } || { rm -rf "$$dc_destdir"; exit 1; }) \ && rm -rf "$$dc_destdir" \ && $(MAKE) $(AM_MAKEFLAGS) dist \ && rm -rf $(DIST_ARCHIVES) \ && $(MAKE) $(AM_MAKEFLAGS) distcleancheck $(am__remove_distdir) @(echo "$(distdir) archives ready for distribution: "; \ list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' distuninstallcheck: @cd $(distuninstallcheck_dir) \ && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ || { echo "ERROR: files left after uninstall:" ; \ if test -n "$(DESTDIR)"; then \ echo " (check DESTDIR support)"; \ fi ; \ $(distuninstallcheck_listfiles) ; \ exit 1; } >&2 distcleancheck: distclean @if test '$(srcdir)' = . ; then \ echo "ERROR: distcleancheck can only run from a VPATH build" ; \ exit 1 ; \ fi @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left in build directory after distclean:" ; \ $(distcleancheck_listfiles) ; \ exit 1; } >&2 check-am: all-am check: check-am all-am: Makefile $(PROGRAMS) $(DATA) config.h installdirs: for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(tgifdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-binPROGRAMS clean-generic mostlyclean-am distclean: distclean-am -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-hdr distclean-tags dvi: dvi-am dvi-am: html: html-am info: info-am info-am: install-data-am: install-tgifDATA install-dvi: install-dvi-am install-exec-am: install-binPROGRAMS install-html: install-html-am install-info: install-info-am install-man: install-pdf: install-pdf-am install-ps: install-ps-am installcheck-am: maintainer-clean: maintainer-clean-am -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-binPROGRAMS uninstall-tgifDATA .MAKE: install-am install-strip .PHONY: CTAGS GTAGS all all-am am--refresh check check-am clean \ clean-binPROGRAMS clean-generic ctags dist dist-all dist-bzip2 \ dist-gzip dist-shar dist-tarZ dist-zip distcheck distclean \ distclean-compile distclean-generic distclean-hdr \ distclean-tags distcleancheck distdir distuninstallcheck dvi \ dvi-am html html-am info info-am install install-am \ install-binPROGRAMS install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-ps install-ps-am \ install-strip install-tgifDATA installcheck installcheck-am \ installdirs maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-compile mostlyclean-generic pdf pdf-am \ ps ps-am tags uninstall uninstall-am uninstall-binPROGRAMS \ uninstall-tgifDATA # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/miniline.c���������������������������������������������������������������������������0000644�0000764�0000764�00000607114�11602233312�014745� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/miniline.c,v 1.38 2011/05/18 22:41:20 william Exp $ */ #define _INCLUDE_FROM_MINILINE_C_ #include "tgifdefs.h" #include "auxtext.e" #include "choice.e" #include "color.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "font.e" #include "inmethod.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "obj.e" #include "pattern.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "setup.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "wb.e" #define USE_SEG 0 #define USE_SUP 1 #define USE_SUB 2 TextHighlightInfo gstTextHighlightInfo; CopyUTF8Info gstCopyUTF8Info; /* * textOrigX, textOrigY, textCurX, textCurY, textCurBaselineY are * UNSCALED screen offsets * textAbsX, and textAbsY are absolute coordinates */ int textOrigX=20, textOrigY=20, textOrigBaselineY=20; int textAbsX=INVALID, textAbsY=INVALID, textAbsBaselineY=INVALID; int textCurX=20, textCurY=20, textCurBaselineY=0; int textCurIndex=0; int textEndX=20, textEndY=20, textEndBaselineY=0; int textEndIndex=0; /* * The following is updated to grown in UpdateEditTextArea(). */ int textAbsMinLBearing=0, textAbsMaxRExtra=0; int textW=0, textH=0; /* absolute for the current text font */ int textHighlight=FALSE; struct ObjRec *curTextObj=NULL; struct BBRec curTextOBBox, curTextBBox; StrBlockInfo *curStrBlock=NULL; /* block must always be SB_SIMPLE */ StrBlockInfo *endStrBlock=NULL; /* block must always be SB_SIMPLE */ MiniLineInfo *firstMiniLine=NULL, *lastMiniLine=NULL; int escPressed=FALSE; int dontRecalcStrSegMetrics=FALSE; int curTextOutlineW=7, curTextOutlineHalfW=3; int drawWinHasFocus=FALSE; /* --------------------- ClearCopyUTF8Info() --------------------- */ void ClearCopyUTF8Info() { memset(&gstCopyUTF8Info, 0, sizeof(CopyUTF8Info)); } static void DebugCopyUTF8Info() { #ifdef NOT_DEFINED if (gstCopyUTF8Info.single_byte_valid) { fprintf(stderr, "Single byte:\n"); fprintf(stderr, "\tFont: %s\n", fontMenuStr[gstCopyUTF8Info.single_byte_seg.font]); fprintf(stderr, "\tStyle: %1d\n", gstCopyUTF8Info.single_byte_seg.style); fprintf(stderr, "\tSize: %1d\n", SzUnitToFontSize(gstCopyUTF8Info.single_byte_seg.sz_unit)); } if (gstCopyUTF8Info.double_byte_valid) { fprintf(stderr, "Double byte:\n"); fprintf(stderr, "\tFont: %s\n", fontMenuStr[gstCopyUTF8Info.double_byte_seg.font]); fprintf(stderr, "\tStyle: %1d\n", gstCopyUTF8Info.double_byte_seg.style); fprintf(stderr, "\tSize: %1d\n", SzUnitToFontSize(gstCopyUTF8Info.double_byte_seg.sz_unit)); } #endif /* NOT_DEFINED */ } void SetCopyUTF8FontInfo(pStrSeg, double_byte) StrSegInfo *pStrSeg; int double_byte; { if (double_byte) { memcpy(&gstCopyUTF8Info.double_byte_seg, pStrSeg, sizeof(StrSegInfo)); gstCopyUTF8Info.double_byte_seg.font_name = NULL; gstCopyUTF8Info.double_byte_seg.dyn_str.sz = 0; gstCopyUTF8Info.double_byte_seg.dyn_str.s = NULL; gstCopyUTF8Info.double_byte_seg.owner = NULL; gstCopyUTF8Info.double_byte_valid = TRUE; } else { memcpy(&gstCopyUTF8Info.single_byte_seg, pStrSeg, sizeof(StrSegInfo)); gstCopyUTF8Info.single_byte_seg.font_name = NULL; gstCopyUTF8Info.single_byte_seg.dyn_str.sz = 0; gstCopyUTF8Info.single_byte_seg.dyn_str.s = NULL; gstCopyUTF8Info.single_byte_seg.owner = NULL; gstCopyUTF8Info.single_byte_valid = TRUE; } } int CalcSingleByteInfoForCopyUTF8(pn_font_index) int *pn_font_index; { StrBlockInfo *pStrBlock=NULL; if (curStrBlock != endStrBlock || curStrBlock->type != SB_SIMPLE || !curStrBlock->seg->double_byte) { return FALSE; } for (pStrBlock=curStrBlock->prev; pStrBlock != NULL; pStrBlock=pStrBlock->prev) { if (pStrBlock->type == SB_SIMPLE && !pStrBlock->seg->double_byte) { SetCopyUTF8FontInfo(pStrBlock->seg, FALSE); DebugCopyUTF8Info(); return TRUE; } } return FALSE; } static int FoundSingleByteFontAtStrBlock(pStrBlock, pStrSeg, double_byte) StrBlockInfo *pStrBlock; StrSegInfo *pStrSeg; int double_byte; { if (pStrBlock->type == SB_SIMPLE && pStrBlock->seg->double_byte == double_byte) { SetCopyUTF8FontInfo(pStrBlock->seg, FALSE); DebugCopyUTF8Info(); if (pStrSeg != NULL) { memcpy(pStrSeg, pStrBlock->seg, sizeof(StrSegInfo)); pStrSeg->font_name = NULL; pStrSeg->dyn_str.sz = 0; pStrSeg->dyn_str.s = NULL; pStrSeg->owner = NULL; } return TRUE; } return FALSE; } static int CanFindSingleOrDoubleByteFontAtCursor(pStrSeg, double_byte) StrSegInfo *pStrSeg; int double_byte; { StrBlockInfo *pStrBlock=NULL; MiniLineInfo *pMiniLine=NULL; if (curStrBlock->type != SB_SIMPLE) { return FALSE; } if (curStrBlock->seg->double_byte == double_byte) { return TRUE; } for (pStrBlock=curStrBlock->prev; pStrBlock != NULL; pStrBlock=pStrBlock->prev) { if (FoundSingleByteFontAtStrBlock(pStrBlock, pStrSeg, double_byte)) { return TRUE; } } for (pMiniLine=curStrBlock->owner_mini_line->prev; pMiniLine != NULL; pMiniLine=pMiniLine->prev) { for (pStrBlock=pMiniLine->last_block; pStrBlock != NULL; pStrBlock=pStrBlock->prev) { if (FoundSingleByteFontAtStrBlock(pStrBlock, pStrSeg, double_byte)) { return TRUE; } } } for (pStrBlock=curStrBlock->next; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (FoundSingleByteFontAtStrBlock(pStrBlock, pStrSeg, double_byte)) { return TRUE; } } for (pMiniLine=curStrBlock->owner_mini_line->next; pMiniLine != NULL; pMiniLine=pMiniLine->next) { for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (FoundSingleByteFontAtStrBlock(pStrBlock, pStrSeg, double_byte)) { return TRUE; } } } return FALSE; } int CanFindSingleByteFontAtCursor(pStrSeg) StrSegInfo *pStrSeg; { return CanFindSingleOrDoubleByteFontAtCursor(pStrSeg, FALSE); } int CanFindDoubleByteFontAtCursor(pStrSeg) StrSegInfo *pStrSeg; { return CanFindSingleOrDoubleByteFontAtCursor(pStrSeg, TRUE); } /* --------------------- DrawTextInfo Functions --------------------- */ static DrawTextInfo gstDrawTextInfo; static int gnDrawTextInfoValid=FALSE; void SaveDrawTextInfo(pDrawTextInfo) DrawTextInfo *pDrawTextInfo; { memset(pDrawTextInfo, 0, sizeof(DrawTextInfo)); memcpy(&pDrawTextInfo->text_highlight_info, &gstTextHighlightInfo, sizeof(TextHighlightInfo)); pDrawTextInfo->text_orig_x = textOrigX; pDrawTextInfo->text_orig_y = textOrigY; pDrawTextInfo->text_orig_baseline_y = textOrigBaselineY; pDrawTextInfo->text_abs_x = textAbsX; pDrawTextInfo->text_abs_y = textAbsY; pDrawTextInfo->text_abs_baseline_y = textAbsBaselineY; pDrawTextInfo->text_cur_x = textCurX; pDrawTextInfo->text_cur_y = textCurY; pDrawTextInfo->text_cur_baseline_y = textCurBaselineY; pDrawTextInfo->text_cur_index = textCurIndex; pDrawTextInfo->text_end_x = textEndX; pDrawTextInfo->text_end_y = textEndY; pDrawTextInfo->text_end_baseline_y = textEndBaselineY; pDrawTextInfo->text_end_index = textEndIndex; pDrawTextInfo->text_abs_min_lbearing = textAbsMinLBearing; pDrawTextInfo->text_abs_max_rextra = textAbsMaxRExtra; pDrawTextInfo->text_w = textW; pDrawTextInfo->text_h = textH; pDrawTextInfo->text_highlight = textHighlight; pDrawTextInfo->cur_text_obj = curTextObj; memcpy(&pDrawTextInfo->cur_text_obbox, &curTextOBBox, sizeof(struct BBRec)); memcpy(&pDrawTextInfo->cur_text_bbox, &curTextBBox, sizeof(struct BBRec)); pDrawTextInfo->cur_str_block = curStrBlock; pDrawTextInfo->end_str_block = endStrBlock; pDrawTextInfo->first_miniLine = firstMiniLine; pDrawTextInfo->last_miniLine = lastMiniLine; pDrawTextInfo->esc_pressed = escPressed; pDrawTextInfo->cur_text_outline_w = curTextOutlineW; pDrawTextInfo->cur_text_outline_half_w = curTextOutlineHalfW; /* the following are from text.e */ pDrawTextInfo->text_drawn = textDrawn; pDrawTextInfo->cur_text_modified = curTextModified; pDrawTextInfo->text_vspace = textVSpace; pDrawTextInfo->text_just = textJust; pDrawTextInfo->text_cursor_shown = textCursorShown; pDrawTextInfo->text_cursor_h = textCursorH; pDrawTextInfo->editing_text = editingText; pDrawTextInfo->cur_text_is_new = curTextIsNew; pDrawTextInfo->edit_text_size = editTextSize; } void RestoreDrawTextInfo(pDrawTextInfo) DrawTextInfo *pDrawTextInfo; { memcpy(&gstTextHighlightInfo, &pDrawTextInfo->text_highlight_info, sizeof(TextHighlightInfo)); textOrigX = pDrawTextInfo->text_orig_x; textOrigY = pDrawTextInfo->text_orig_y; textOrigBaselineY = pDrawTextInfo->text_orig_baseline_y; textAbsX = pDrawTextInfo->text_abs_x; textAbsY = pDrawTextInfo->text_abs_y; textAbsBaselineY = pDrawTextInfo->text_abs_baseline_y; textCurX = pDrawTextInfo->text_cur_x; textCurY = pDrawTextInfo->text_cur_y; textCurBaselineY = pDrawTextInfo->text_cur_baseline_y; textCurIndex = pDrawTextInfo->text_cur_index; textEndX = pDrawTextInfo->text_end_x; textEndY = pDrawTextInfo->text_end_y; textEndBaselineY = pDrawTextInfo->text_end_baseline_y; textEndIndex = pDrawTextInfo->text_end_index; textAbsMinLBearing = pDrawTextInfo->text_abs_min_lbearing; textAbsMaxRExtra = pDrawTextInfo->text_abs_max_rextra; textW = pDrawTextInfo->text_w; textH = pDrawTextInfo->text_h; textHighlight = pDrawTextInfo->text_highlight; curTextObj = pDrawTextInfo->cur_text_obj; memcpy(&curTextOBBox, &pDrawTextInfo->cur_text_obbox, sizeof(struct BBRec)); memcpy(&curTextBBox, &pDrawTextInfo->cur_text_bbox, sizeof(struct BBRec)); curStrBlock = pDrawTextInfo->cur_str_block; endStrBlock = pDrawTextInfo->end_str_block; firstMiniLine = pDrawTextInfo->first_miniLine; lastMiniLine = pDrawTextInfo->last_miniLine; escPressed = pDrawTextInfo->esc_pressed; curTextOutlineW = pDrawTextInfo->cur_text_outline_w; curTextOutlineHalfW = pDrawTextInfo->cur_text_outline_half_w; /* the following are from text.e */ textDrawn = pDrawTextInfo->text_drawn; curTextModified = pDrawTextInfo->cur_text_modified; textVSpace = pDrawTextInfo->text_vspace; textJust = pDrawTextInfo->text_just; textCursorShown = pDrawTextInfo->text_cursor_shown; textCursorH = pDrawTextInfo->text_cursor_h; editingText = pDrawTextInfo->editing_text; curTextIsNew = pDrawTextInfo->cur_text_is_new; editTextSize = pDrawTextInfo->edit_text_size; } void ResetDrawTextInfo() { memset(&gstDrawTextInfo, 0, sizeof(DrawTextInfo)); RestoreDrawTextInfo(&gstDrawTextInfo); } void SaveDrawWinDrawTextInfo(forced) int forced; { if (gstWBInfo.do_whiteboard) { if (curChoice == DRAWTEXT) { if (!forced && textCursorShown) { PutTextCursor(); } SaveDrawTextInfo(&gstDrawTextInfo); gnDrawTextInfoValid = TRUE; } if (!forced) { drawWinHasFocus = FALSE; } } } void RestoreDrawWinDrawTextInfo(forced) int forced; { if (!forced) { drawWinHasFocus = TRUE; } if (gstWBInfo.do_whiteboard) { if (gnDrawTextInfoValid && curChoice == DRAWTEXT) { if (forced) { RestoreDrawTextInfo(&gstDrawTextInfo); } if (!forced) { gnDrawTextInfoValid = FALSE; if (textCursorShown) { PutTextCursor(); } } } } } /* --------------------- DirtyBBox Functions --------------------- */ static DirtyBBoxInfo gstDirtyBBoxInfo; void ResetDirtyBBoxInfo() { memset(&gstDirtyBBoxInfo, 0, sizeof(DirtyBBoxInfo)); gstDirtyBBoxInfo.valid = FALSE; gstDirtyBBoxInfo.force_redraw_all = FALSE; } void AddToDirtyBBox(pBBox) struct BBRec *pBBox; { if (gstDirtyBBoxInfo.valid) { UnionRect(&gstDirtyBBoxInfo.bbox, pBBox, &gstDirtyBBoxInfo.bbox); } else { gstDirtyBBoxInfo.valid = TRUE; memcpy(&gstDirtyBBoxInfo.bbox, pBBox, sizeof(struct BBRec)); } } void ForceDirtyBBoxToRedrawAll() { gstDirtyBBoxInfo.force_redraw_all = TRUE; } int GetDirtyBBox(pBBox) struct BBRec *pBBox; { if (pBBox != NULL) { if (gstDirtyBBoxInfo.valid) { memcpy(pBBox, &gstDirtyBBoxInfo.bbox, sizeof(struct BBRec)); } else { memset(pBBox, 0, sizeof(struct BBRec)); } } return (gstDirtyBBoxInfo.valid && !gstDirtyBBoxInfo.force_redraw_all); } static int IntersectDirtyBBox(pBBox) struct BBRec *pBBox; { return BBoxIntersect(*pBBox, gstDirtyBBoxInfo.bbox); } /* --------------------- Indent Functions --------------------- */ static char **gaszIndentStrings=NULL; static int gnMaxIndent=0; void CleanUpIndentStrings() { if (gaszIndentStrings != NULL) { int i=0; for (i=0; i < gnMaxIndent; i++) { UtilFree(gaszIndentStrings[i]); } free(gaszIndentStrings); } gaszIndentStrings = NULL; gnMaxIndent = 0; } static void InitIndentStrings() { gaszIndentStrings = NULL; gnMaxIndent = 0; } char *GetIndentString(indent) int indent; { int i=0; if (indent < 0) return NULL; if (indent == 0) return ""; if (gaszIndentStrings == NULL) { gaszIndentStrings = (char**)malloc(indent*sizeof(char*)); if (gaszIndentStrings == NULL) FailAllocMessage(); memset(gaszIndentStrings, 0, indent*sizeof(char*)); gnMaxIndent = indent; } else if (indent > gnMaxIndent) { gaszIndentStrings = (char**)realloc(gaszIndentStrings, indent*sizeof(char*)); if (gaszIndentStrings == NULL) FailAllocMessage(); for (i=gnMaxIndent; i < indent; i++) { gaszIndentStrings[i] = NULL; } gnMaxIndent = indent; } else { if (gaszIndentStrings[indent-1] != NULL) { return gaszIndentStrings[indent-1]; } } gaszIndentStrings[indent-1] = (char*)malloc((indent+1)*sizeof(char)); if (gaszIndentStrings[indent-1] == NULL) FailAllocMessage(); memset(gaszIndentStrings[indent-1], 0, sizeof((indent+1)*sizeof(char))); for (i=0; i < indent; i++) { gaszIndentStrings[indent-1][i] = ' '; } gaszIndentStrings[indent-1][i] = '\0'; return gaszIndentStrings[indent-1]; } void DumpIndentString(FP, indent) FILE *FP; int indent; { char *psz=GetIndentString(indent); if (psz != NULL) { fprintf(FP, "%s", psz); } } /* --------------------- Init Functions --------------------- */ void CleanUpMiniLines() { CleanUpIndentStrings(); memset(&gstDrawTextInfo, 0, sizeof(DrawTextInfo)); gnDrawTextInfoValid = FALSE; } int InitMiniLines() { InitIndentStrings(); memset(&gstDrawTextInfo, 0, sizeof(DrawTextInfo)); gnDrawTextInfoValid = FALSE; return TRUE; } /* --------------------- Free Functions --------------------- */ void FreeStrSeg(pStrSeg) StrSegInfo *pStrSeg; { if (pStrSeg->font_name != NULL) free(pStrSeg->font_name); if (pStrSeg->dyn_str.s != NULL) free(pStrSeg->dyn_str.s); free(pStrSeg); } void FreeStrBlock(pStrBlock) StrBlockInfo *pStrBlock; { switch (pStrBlock->type) { case SB_SIMPLE: FreeStrSeg(pStrBlock->seg); break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) FreeMiniLines(pStrBlock->sup, TRUE); if (pStrBlock->sub != NULL) FreeMiniLines(pStrBlock->sub, TRUE); if (pStrBlock->type == SB_SUPSUB_CENTER) FreeStrSeg(pStrBlock->seg); break; } free(pStrBlock); } void FreeMiniLine(pMiniLine) MiniLineInfo *pMiniLine; { StrBlockInfo *pStrBlock=NULL, *pNextStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pNextStrBlock) { pNextStrBlock = pStrBlock->next; FreeStrBlock(pStrBlock); } free(pMiniLine); } void FreeMiniLines(minilines, free_minilines) MiniLinesInfo *minilines; int free_minilines; { MiniLineInfo *pMiniLine=NULL, *pNextMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pNextMiniLine) { pNextMiniLine = pMiniLine->next; FreeMiniLine(pMiniLine); } if (free_minilines) { free(minilines); } else { minilines->first = minilines->last = NULL; } } void FreeStrBlockList(pFirstStrBlock) StrBlockInfo *pFirstStrBlock; { StrBlockInfo *pNextStrBlock=NULL; while (pFirstStrBlock != NULL) { pNextStrBlock = pFirstStrBlock->next; FreeStrBlock(pFirstStrBlock); pFirstStrBlock = pNextStrBlock; } } void FreeMiniLineList(pFirstMiniLine) MiniLineInfo *pFirstMiniLine; { MiniLineInfo *pNextMiniLine=NULL; while (pFirstMiniLine != NULL) { pNextMiniLine = pFirstMiniLine->next; FreeMiniLine(pFirstMiniLine); pFirstMiniLine = pNextMiniLine; } } void UnlinkStrBlock(pStrBlock) StrBlockInfo *pStrBlock; { MiniLineInfo *pOwnerMiniLine=pStrBlock->owner_mini_line; if (pStrBlock->prev == NULL) { pOwnerMiniLine->first_block = pStrBlock->next; } else { pStrBlock->prev->next = pStrBlock->next; } if (pStrBlock->next == NULL) { pOwnerMiniLine->last_block = pStrBlock->prev; } else { pStrBlock->next->prev = pStrBlock->prev; } pStrBlock->prev = pStrBlock->next = NULL; } void UnlinkMiniLine(pMiniLine) MiniLineInfo *pMiniLine; { MiniLinesInfo *pOwnerMiniLines=pMiniLine->owner_minilines; if (pMiniLine->prev == NULL) { pOwnerMiniLines->first = pMiniLine->next; } else { pMiniLine->prev->next = pMiniLine->next; } if (pMiniLine->next == NULL) { pOwnerMiniLines->last = pMiniLine->prev; } else { pMiniLine->next->prev = pMiniLine->prev; } pMiniLine->prev = pMiniLine->next = NULL; } StrSegInfo *NewStrSeg() { StrSegInfo *pStrSeg=(StrSegInfo*)malloc(sizeof(StrSegInfo)); if (pStrSeg == NULL) FailAllocMessage(); memset(pStrSeg, 0, sizeof(StrSegInfo)); DynStrSet(&pStrSeg->dyn_str, ""); return pStrSeg; } StrBlockInfo *NewStrBlock() { StrBlockInfo *pStrBlock=(StrBlockInfo*)malloc(sizeof(StrBlockInfo)); if (pStrBlock == NULL) FailAllocMessage(); memset(pStrBlock, 0, sizeof(StrBlockInfo)); return pStrBlock; } MiniLineInfo *NewMiniLine() { MiniLineInfo *pMiniLine=(MiniLineInfo*)malloc(sizeof(MiniLineInfo)); if (pMiniLine == NULL) FailAllocMessage(); memset(pMiniLine, 0, sizeof(MiniLineInfo)); return pMiniLine; } MiniLinesInfo *NewMiniLines() { MiniLinesInfo *minilines=(MiniLinesInfo*)malloc(sizeof(MiniLinesInfo)); if (minilines == NULL) FailAllocMessage(); memset(minilines, 0, sizeof(MiniLinesInfo)); return minilines; } void InsertStrBlock(pPrevStrBlock, pNextStrBlock, pStrBlock, ppFirstStrBlock, ppLastStrBlock) StrBlockInfo *pPrevStrBlock, *pNextStrBlock, *pStrBlock; StrBlockInfo **ppFirstStrBlock, **ppLastStrBlock; { pStrBlock->prev = pPrevStrBlock; pStrBlock->next = pNextStrBlock; if (pPrevStrBlock == NULL) { (*ppFirstStrBlock) = pStrBlock; } else { pPrevStrBlock->next = pStrBlock; } if (pNextStrBlock == NULL) { (*ppLastStrBlock) = pStrBlock; } else { pNextStrBlock->prev = pStrBlock; } } void InsertMiniLine(pPrevMiniLine, pNextMiniLine, pMiniLine, ppFirstMiniLine, ppLastMiniLine) MiniLineInfo *pPrevMiniLine, *pNextMiniLine, *pMiniLine; MiniLineInfo **ppFirstMiniLine, **ppLastMiniLine; { pMiniLine->prev = pPrevMiniLine; pMiniLine->next = pNextMiniLine; if (pPrevMiniLine == NULL) { (*ppFirstMiniLine) = pMiniLine; } else { pPrevMiniLine->next = pMiniLine; } if (pNextMiniLine == NULL) { (*ppLastMiniLine) = pMiniLine; } else { pNextMiniLine->prev = pMiniLine; } } int BlankStrSeg(pStrSeg) StrSegInfo *pStrSeg; { return (*pStrSeg->dyn_str.s == '\0'); } int BlankStrBlock(pStrBlock) StrBlockInfo *pStrBlock; { switch (pStrBlock->type) { case SB_SIMPLE: return BlankStrSeg(pStrBlock->seg); case SB_CHAR_SPACE: return (pStrBlock->special_char_w == 0); case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) { if (!BlankMiniLines(pStrBlock->sup)) { return FALSE; } } if (pStrBlock->sub != NULL) { if (!BlankMiniLines(pStrBlock->sub)) { return FALSE; } } if (pStrBlock->type == SB_SUPSUB_CENTER) { return BlankStrSeg(pStrBlock->seg); } break; } return TRUE; } int BlankMiniLine(pMiniLine) MiniLineInfo *pMiniLine; { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (!BlankStrBlock(pStrBlock)) { return FALSE; } } return TRUE; } int BlankMiniLines(minilines) MiniLinesInfo *minilines; { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (!BlankMiniLine(pMiniLine)) { return FALSE; } } return TRUE; } StrSegInfo *GetTextFirstStrSeg(obj_ptr) struct ObjRec *obj_ptr; { StrBlockInfo *pStrBlock=obj_ptr->detail.t->minilines.first->first_block; for ( ; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (pStrBlock->type == SB_SIMPLE) { return (pStrBlock->seg); } } return NULL; } struct DynStrRec *GetTextFirstDynStr(obj_ptr) struct ObjRec *obj_ptr; { StrBlockInfo *pStrBlock=obj_ptr->detail.t->minilines.first->first_block; for ( ; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (pStrBlock->type == SB_SIMPLE) { return (&pStrBlock->seg->dyn_str); } } return NULL; } /* ===================== TextRec Routines ===================== */ void CopyCurInfoIntoStrSeg(pStrBlock, pStrSeg) StrBlockInfo *pStrBlock; StrSegInfo *pStrSeg; { pStrSeg->color = colorIndex; UtilStrCpyN(pStrSeg->color_str, sizeof(pStrSeg->color_str), colorMenuItems[colorIndex]); pStrSeg->font = curFont; pStrSeg->style = curStyle; pStrSeg->sz_unit = curSzUnit; pStrSeg->double_byte = canvasFontDoubleByte; pStrSeg->double_byte_mod_bytes = canvasFontDoubleByteModBytes; pStrSeg->double_byte_vertical = canvasFontDoubleByteVertical; pStrSeg->direction = canvasFontDirection; pStrSeg->dontreencode = canvasFontDontReencode; pStrSeg->underline_on = curUnderlineOn; pStrSeg->overline_on = curOverlineOn; pStrSeg->asc = canvasFontAsc; pStrSeg->des = canvasFontDes; /* * The following are set in RecalcTextMetrics(): * w, min_lbearing, max_rextra */ /* * If read_only is TRUE, the following are set in ReadTextObj(): * read_only, orig_w, orig_h, orig_asc, orig_des */ /* * These fields are not touched: font_name, dyn_str, owner */ } void CopyCurInfoFromStrSeg(pStrSeg) StrSegInfo *pStrSeg; { colorIndex = pStrSeg->color; curFont = pStrSeg->font; curStyle = pStrSeg->style; curSzUnit = pStrSeg->sz_unit; if (PRTGIF) { canvasFontDoubleByte = pStrSeg->double_byte; canvasFontDoubleByteModBytes = pStrSeg->double_byte_mod_bytes; canvasFontDoubleByteVertical = pStrSeg->double_byte_vertical; canvasFontDirection = pStrSeg->direction; canvasFontDontReencode = pStrSeg->dontreencode; canvasFontAsc = pStrSeg->asc; canvasFontDes = pStrSeg->des; } else { SetCanvasFont(); } curUnderlineOn = pStrSeg->underline_on; curOverlineOn = pStrSeg->overline_on; } void CopyCurInfoIntoTextPtr(obj_ptr, text_ptr) struct ObjRec *obj_ptr; struct TextRec *text_ptr; { obj_ptr->trans_pat = transPat; text_ptr->minilines.just = textJust; text_ptr->minilines.v_space = textVSpace; text_ptr->pen = penPat; text_ptr->fill = objFill; text_ptr->minilines.first->asc = canvasLineAsc; text_ptr->minilines.first->des = canvasLineDes; text_ptr->underline_y_offset = curUnderlineYOffset; text_ptr->overline_y_offset = curOverlineYOffset; /* * The following are set in RecalcTextMetrics(): * w, h, min_lbearing, max_rextra */ text_ptr->w = 0; text_ptr->h = 0; text_ptr->min_lbearing = 0; text_ptr->max_rextra = 0; /* * If read_only is TRUE, the following are set in ReadTextObj(): * read_only, orig_w, orig_h, orig_asc, orig_des */ text_ptr->read_only = FALSE; text_ptr->orig_w = text_ptr->orig_h = 0; /* * The following fields are not touched: cached_ctm, orig_bbox, baseline_y, * cached_bitmap, cached_zoom, cached_zoomed. */ } void CopyCurInfoFromTextPtr(obj_ptr, text_ptr) struct ObjRec *obj_ptr; struct TextRec *text_ptr; { transPat = obj_ptr->trans_pat; textJust = text_ptr->minilines.just; textVSpace = text_ptr->minilines.v_space; penPat = text_ptr->pen; objFill = text_ptr->fill; canvasLineAsc = text_ptr->minilines.first->asc; canvasLineDes = text_ptr->minilines.first->des; curUnderlineYOffset = text_ptr->underline_y_offset; curOverlineYOffset = text_ptr->overline_y_offset; } /* ===================== RecalcTextMetrics() ===================== */ static int RecalcStrSegMetrics(pStrSeg, prmi) StrSegInfo *pStrSeg; RecalcMetricsInfo *prmi; /* * This function recomputes text metrics of the string segments pStrSeg. * Returns FALSE if the block is read_only. */ { int read_only=FALSE; XCharStruct xcs; curFont = pStrSeg->font; curStyle = pStrSeg->style; curSzUnit = pStrSeg->sz_unit; if (mainDisplay == NULL) return FALSE; SetCanvasFont(); if (SzUnitToFontSize(curSzUnit) != canvasFontSize) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "RecalcStrSegMetrics(): read_only detected.\n"); #endif /* _TGIF_DBG */ read_only = TRUE; } else { MyTextExtents(canvasFontPtr, pStrSeg->dyn_str.s, pStrSeg->dyn_str.sz-1, &xcs); pStrSeg->w = xcs.width; pStrSeg->min_lbearing = (xcs.lbearing >= 0 ? 0 : xcs.lbearing); pStrSeg->max_rextra = xcs.rbearing-xcs.width; pStrSeg->asc = canvasFontAsc; pStrSeg->des = canvasFontDes; } if (read_only && readingTextObject) { pStrSeg->read_only = TRUE; } return (!read_only); } static void UpdateMetricsFromValues(p_found, w, asc, des, min_lbearing, max_rextra, pTextExtents) int *p_found, w, asc, des, min_lbearing, max_rextra; TextExtentsInfo *pTextExtents; { if (p_found == NULL || !(*p_found)) { pTextExtents->w = w; pTextExtents->lbearing = min_lbearing; pTextExtents->rextra = max_rextra; pTextExtents->asc = asc; pTextExtents->des = des; if (p_found != NULL) *p_found = TRUE; } else { if (w > (pTextExtents->w)) pTextExtents->w = w; if (min_lbearing > (pTextExtents->lbearing)) { pTextExtents->lbearing = min_lbearing; } if (max_rextra > (pTextExtents->rextra)) { pTextExtents->rextra = max_rextra; } if (asc > pTextExtents->asc) { pTextExtents->asc = asc; } if (des > pTextExtents->des) { pTextExtents->des = des; } } pTextExtents->bbox_w = pTextExtents->w - pTextExtents->lbearing + pTextExtents->rextra; pTextExtents->bbox_h = pTextExtents->asc + pTextExtents->des; } static void UpdateMetricsFromStrSegInfo(p_found, pStrSeg, pTextExtents) int *p_found; StrSegInfo *pStrSeg; TextExtentsInfo *pTextExtents; { UpdateMetricsFromValues(p_found, pStrSeg->w, pStrSeg->asc, pStrSeg->des, pStrSeg->min_lbearing, pStrSeg->max_rextra, pTextExtents); } static int StrBlockTypeToMiniLinesJust(type) int type; { switch (type) { case SB_SUPSUB_LEFT: return JUST_R; case SB_SUPSUB_CENTER: return JUST_C; case SB_SUPSUB_RIGHT: return JUST_L; } return JUST_L; } static int RecalcStrBlockMetrics(pStrBlock, prmi) StrBlockInfo *pStrBlock; RecalcMetricsInfo *prmi; /* * This function recursively recomputes all text metrics of the * string segments and mini-lines in pStrBlock. * Returns FALSE if the block is read_only. */ { int found=FALSE, saved_baseline_y=prmi->baseline_y; int read_only=FALSE; TextExtentsInfo stTextExtents; pStrBlock->depth = prmi->depth; pStrBlock->pre_order = (prmi->pre_order)++; memset(&stTextExtents, 0, sizeof(TextExtentsInfo)); switch (pStrBlock->type) { case SB_SIMPLE: /* * For a simple block, the block only contains a string segment. * Other than the vertical offset, the metrics between the string * segment and this block are identical. */ pStrBlock->seg->owner = pStrBlock; if (!dontRecalcStrSegMetrics) { if (!RecalcStrSegMetrics(pStrBlock->seg, prmi)) { read_only = TRUE; } } UpdateMetricsFromStrSegInfo(NULL, pStrBlock->seg, &stTextExtents); break; /* * Special characters are very much like simple blocks, except for * the differences noted below. */ case SB_CHAR_SPACE: /* * The space character is not the same as (char*)0x20. It's used for * ``extra space'' or ``negative space''. The width of it is * in special_char_w. All other metrics are 0. Since it * doesn't have an ascent, its vertical offset from the parent * block is meaningless. */ stTextExtents.w = pStrBlock->special_char_w; stTextExtents.lbearing = stTextExtents.rextra = 0; stTextExtents.asc = stTextExtents.des = 0; break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: prmi->depth++; if (pStrBlock->type == SB_SUPSUB_CENTER) { /* pStrBlock->seg better not be NULL or it will crash */ pStrBlock->depth = prmi->depth; pStrBlock->seg->owner = pStrBlock; if (!dontRecalcStrSegMetrics) { if (!RecalcStrSegMetrics(pStrBlock->seg, prmi)) { read_only = TRUE; } } UpdateMetricsFromStrSegInfo(&found, pStrBlock->seg, &stTextExtents); } if (pStrBlock->sup != NULL) { MiniLinesInfo *minilines=pStrBlock->sup; int asc=0, des=0; pStrBlock->sup->owner_block = pStrBlock; prmi->baseline_y = saved_baseline_y+minilines->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { /* * Note, by default, for SB_SUPSUB_CENTER, * minilines.baseline_offset is the descent of the * superscript font. Adding the ascent of the font for * the string segment below makes the superscript sits * right on top of the string segment. * Doing it this way, when you change the font of the string * segment, the relative position of the superscript and * the string segment doesn't change. */ prmi->baseline_y -= pStrBlock->seg->asc; } if (!RecalcMiniLinesMetrics(minilines, prmi)) { read_only = TRUE; } if (pStrBlock->type == SB_SUPSUB_CENTER) { asc = (-minilines->baseline_offset) + minilines->first->asc + pStrBlock->seg->asc; des = minilines->h - asc; } else { asc = (-minilines->baseline_offset) + minilines->first->asc; des = minilines->h - asc; } UpdateMetricsFromValues(&found, minilines->w, asc, des, minilines->min_lbearing, minilines->max_rextra, &stTextExtents); minilines->just = StrBlockTypeToMiniLinesJust(pStrBlock->type); } if (pStrBlock->sub != NULL) { MiniLinesInfo *minilines=pStrBlock->sub; int asc=0, des=0; pStrBlock->sub->owner_block = pStrBlock; prmi->baseline_y = saved_baseline_y+pStrBlock->sub->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { /* * Note, by default, for SB_SUPSUB_CENTER, * pStrBlock->sub->baseline_offset is the ascent of the * subscript font. Adding the descent of the font for * the string segment below makes the subscript sits * right below the string segment. * Doing it this way, when you change the font of the string * segment, the relative position of the subscript and * the string segment doesn't change. */ prmi->baseline_y += pStrBlock->seg->des; } if (!RecalcMiniLinesMetrics(minilines, prmi)) { read_only = TRUE; } if (pStrBlock->type == SB_SUPSUB_CENTER) { asc = minilines->first->asc - minilines->baseline_offset - pStrBlock->seg->des; des = minilines->h - asc; } else { asc = minilines->first->asc - minilines->baseline_offset; des = minilines->h - asc; } UpdateMetricsFromValues(&found, minilines->w, asc, des, minilines->min_lbearing, minilines->max_rextra, &stTextExtents); minilines->just = StrBlockTypeToMiniLinesJust(pStrBlock->type); } prmi->depth--; break; } pStrBlock->w = stTextExtents.w; pStrBlock->min_lbearing = stTextExtents.lbearing; pStrBlock->max_rextra = stTextExtents.rextra; pStrBlock->asc = stTextExtents.asc; pStrBlock->des = stTextExtents.des; prmi->baseline_y = saved_baseline_y; if (read_only && readingTextObject) { pStrBlock->read_only = TRUE; } return (!read_only); } int RecalcMiniLineMetrics(pMiniLine, prmi) MiniLineInfo *pMiniLine; RecalcMetricsInfo *prmi; /* * This function recursively recomputes all text metrics of the * blocks in pMiniLine. * Returns FALSE if the text is read_only. */ { StrBlockInfo *pStrBlock=NULL; int min_lbearing=0, max_rextra=0, max_asc=0, max_des=0; int saved_baseline_y=prmi->baseline_y; int saved_x=prmi->x, read_only=FALSE; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { pStrBlock->owner_mini_line = pMiniLine; if (!RecalcStrBlockMetrics(pStrBlock, prmi)) { read_only = FALSE; } if (pStrBlock->asc > max_asc) max_asc = pStrBlock->asc; if (pStrBlock->des > max_des) max_des = pStrBlock->des; if (pStrBlock->min_lbearing < min_lbearing) { min_lbearing = pStrBlock->min_lbearing; } if (pStrBlock->max_rextra > max_rextra) { max_rextra = pStrBlock->max_rextra; } prmi->x += pStrBlock->w; } pMiniLine->w = prmi->x - saved_x; pMiniLine->min_lbearing = min_lbearing; pMiniLine->max_rextra = max_rextra; pMiniLine->asc = max_asc; pMiniLine->des = max_des; prmi->x = saved_x; prmi->baseline_y = saved_baseline_y; if (read_only && readingTextObject) { pMiniLine->read_only = TRUE; } return (!read_only); } int RecalcMiniLinesMetrics(minilines, prmi) MiniLinesInfo *minilines; RecalcMetricsInfo *prmi; /* * This function recursively recomputes all text metrics of the minilines. * Returns FALSE if the text is read_only. */ { MiniLineInfo *pMiniLine=NULL; int v_space=minilines->v_space; int saved_x=prmi->x, saved_baseline_y=prmi->baseline_y; int min_y=prmi->baseline_y, max_y=prmi->baseline_y; int max_w=0, min_lbearing=0, max_rextra=0; int read_only=FALSE, saved_depth=prmi->depth; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { pMiniLine->owner_minilines = minilines; #ifdef _TGIF_DBG /* debug, do not translate */ if (pMiniLine == minilines->first) { TgAssert(pMiniLine->v_gap == 0, "First mini_line has non-zero v_gap in RecalcMiniLinesMetrics()", NULL); } #endif /* _TGIF_DBG */ prmi->baseline_y += pMiniLine->v_gap; if (!RecalcMiniLineMetrics(pMiniLine, prmi)) { read_only = TRUE; } if (pMiniLine != minilines->first) { prmi->baseline_y += pMiniLine->asc; } if (prmi->baseline_y-pMiniLine->asc < min_y) { min_y = prmi->baseline_y-pMiniLine->asc; } if (prmi->baseline_y+pMiniLine->des > max_y) { max_y = prmi->baseline_y+pMiniLine->des; } if (pMiniLine->min_lbearing < min_lbearing) { min_lbearing = pMiniLine->min_lbearing; } if (pMiniLine->max_rextra > max_rextra) { max_rextra = pMiniLine->max_rextra; } if (pMiniLine->w > max_w) max_w = pMiniLine->w; prmi->baseline_y += pMiniLine->des + v_space; } minilines->w = max_w; minilines->h = max_y-min_y; if (minilines->h < 0) minilines->h = min_y-max_y; minilines->min_lbearing = min_lbearing; minilines->max_rextra = max_rextra; prmi->x = saved_x; prmi->baseline_y = saved_baseline_y; prmi->depth = saved_depth; if (read_only && readingTextObject) { minilines->read_only = TRUE; } return (!read_only); } int RecalcTextMetrics(text_ptr, x, orig_baseline_y) struct TextRec *text_ptr; int x, orig_baseline_y; /* * Returns FALSE if the text is read_only. */ { MiniLinesInfo *minilines=(&text_ptr->minilines); int read_only=FALSE; RecalcMetricsInfo rmi; if (text_ptr->read_only) return FALSE; memset(&rmi, 0, sizeof(RecalcMetricsInfo)); rmi.x = rmi.orig_x = x; rmi.baseline_y = rmi.orig_baseline_y = orig_baseline_y; PushCurFont(); if (!RecalcMiniLinesMetrics(minilines, &rmi)) { read_only = TRUE; } PopCurFont(); text_ptr->w = minilines->w; text_ptr->h = minilines->h; text_ptr->min_lbearing = minilines->min_lbearing; text_ptr->max_rextra = minilines->max_rextra; text_ptr->lines = GetNumberOfMiniLines(minilines); if (read_only && readingTextObject) { text_ptr->read_only = TRUE; } return (!read_only); } /* --------------------- UpdateCurTextBBoxes() --------------------- */ static void UpdateStrBlockBBoxes(pStrBlock, x, baseline_y, clean) StrBlockInfo *pStrBlock; int x, baseline_y, clean; { int saved_baseline_y=baseline_y; int block_w=pStrBlock->w; SetBBRec((clean ? &pStrBlock->clean_bbox : &pStrBlock->bbox), x+textAbsMinLBearing, baseline_y-pStrBlock->asc, x+pStrBlock->w+textAbsMaxRExtra, baseline_y+pStrBlock->des); switch (pStrBlock->type) { case SB_SIMPLE: break; case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: switch (pStrBlock->type) { case SB_SUPSUB_LEFT: x += block_w; break; case SB_SUPSUB_CENTER: x += (block_w>>1); break; case SB_SUPSUB_RIGHT: break; } if (pStrBlock->sup != NULL) { baseline_y = saved_baseline_y + pStrBlock->sup->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { baseline_y -= pStrBlock->seg->asc; } UpdateMiniLinesBBoxes(pStrBlock->sup, x, baseline_y, clean); } if (pStrBlock->sub != NULL) { baseline_y = saved_baseline_y + pStrBlock->sub->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { baseline_y += pStrBlock->seg->des; } UpdateMiniLinesBBoxes(pStrBlock->sub, x, baseline_y, clean); } break; } if (clean) { pStrBlock->clean = TRUE; memcpy(&pStrBlock->bbox, &pStrBlock->clean_bbox, sizeof(struct BBRec)); } else if (!pStrBlock->clean || CompareRect(&pStrBlock->clean_bbox, &pStrBlock->bbox) != 0) { pStrBlock->clean = FALSE; AddToDirtyBBox(&pStrBlock->clean_bbox); AddToDirtyBBox(&pStrBlock->bbox); } } static void UpdateMiniLineBBoxes(pMiniLine, x, baseline_y, clean) MiniLineInfo *pMiniLine; int x, baseline_y, clean; { int saved_x=x; StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { UpdateStrBlockBBoxes(pStrBlock, x, baseline_y, clean); x += pStrBlock->w; } SetBBRec((clean ? &pMiniLine->clean_bbox : &pMiniLine->bbox), saved_x+textAbsMinLBearing, baseline_y-pMiniLine->asc, saved_x+pMiniLine->w+textAbsMaxRExtra, baseline_y+pMiniLine->des); if (clean) { pMiniLine->clean = TRUE; memcpy(&pMiniLine->bbox, &pMiniLine->clean_bbox, sizeof(struct BBRec)); } else if (!pMiniLine->clean || CompareRect(&pMiniLine->clean_bbox, &pMiniLine->bbox) != 0) { pMiniLine->clean = FALSE; AddToDirtyBBox(&pMiniLine->clean_bbox); AddToDirtyBBox(&pMiniLine->bbox); } } void UpdateMiniLinesBBoxes(minilines, x, baseline_y, clean) MiniLinesInfo *minilines; int x, baseline_y, clean; { MiniLineInfo *pMiniLine=NULL; int v_space=minilines->v_space; int saved_x=x, saved_baseline_y=baseline_y; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { baseline_y += pMiniLine->v_gap; switch (minilines->just) { case JUST_L: x = saved_x; break; case JUST_C: x = saved_x - ((pMiniLine->w)>>1); break; case JUST_R: x = saved_x - pMiniLine->w; break; } UpdateMiniLineBBoxes(pMiniLine, x, baseline_y, clean); baseline_y += pMiniLine->des + v_space; if (pMiniLine->next != NULL) { baseline_y += pMiniLine->next->asc; } } switch (minilines->just) { case JUST_L: x = saved_x; break; case JUST_C: x = saved_x - ((minilines->w)>>1); break; case JUST_R: x = saved_x - minilines->w; break; } SetBBRec((clean ? &minilines->clean_bbox : &minilines->bbox), x+textAbsMinLBearing, saved_baseline_y-minilines->first->asc, x+minilines->w+textAbsMaxRExtra, saved_baseline_y-minilines->first->asc+minilines->h); if (clean) { minilines->clean = TRUE; memcpy(&minilines->bbox, &minilines->clean_bbox, sizeof(struct BBRec)); } else if (!minilines->clean || CompareRect(&minilines->clean_bbox, &minilines->bbox) != 0) { minilines->clean = FALSE; AddToDirtyBBox(&minilines->clean_bbox); AddToDirtyBBox(&minilines->bbox); } } void UpdateCurTextBBoxes(clean) int clean; { struct TextRec *text_ptr=curTextObj->detail.t; if (text_ptr->read_only) return; UpdateMiniLinesBBoxes(&text_ptr->minilines, textOrigX, textOrigBaselineY, clean); } /* --------------------- DoFuncOnStrSegForMiniLines() --------------------- */ static void DoFuncOnStrSegForStrSeg(pStrSeg, pFunc, pUserData) StrSegInfo *pStrSeg; STRSEGFN *pFunc; void *pUserData; { (pFunc)(pStrSeg, pUserData); } static void DoFuncOnStrSegForStrBlock(pStrBlock, pFunc, pUserData) StrBlockInfo *pStrBlock; STRSEGFN *pFunc; void *pUserData; { switch (pStrBlock->type) { case SB_SIMPLE: DoFuncOnStrSegForStrSeg(pStrBlock->seg, pFunc, pUserData); break; case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) { DoFuncOnStrSegForMiniLines(pStrBlock->sup, pFunc, pUserData); } if (pStrBlock->sub != NULL) { DoFuncOnStrSegForMiniLines(pStrBlock->sub, pFunc, pUserData); } if (pStrBlock->type == SB_SUPSUB_CENTER) { DoFuncOnStrSegForStrSeg(pStrBlock->seg, pFunc, pUserData); } break; } } static void DoFuncOnStrSegForMiniLine(pMiniLine, pFunc, pUserData) MiniLineInfo *pMiniLine; STRSEGFN *pFunc; void *pUserData; { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { DoFuncOnStrSegForStrBlock(pStrBlock, pFunc, pUserData); } } void DoFuncOnStrSegForMiniLines(minilines, pFunc, pUserData) MiniLinesInfo *minilines; STRSEGFN *pFunc; void *pUserData; { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { DoFuncOnStrSegForMiniLine(pMiniLine, pFunc, pUserData); } } /* ===================== Text Routines ===================== */ /* --------------------- ResetOnCursorKey() --------------------- */ void ResetOnCursorKey(drag) int drag; { escPressed = FALSE; if (!drag) { endStrBlock = NULL; textEndIndex = INVALID; textHighlight = FALSE; } } /* --------------------- PutTextCursor() --------------------- */ void PutTextCursor() { int asc=curStrBlock->seg->asc; int des=curStrBlock->seg->des; if (!textHighlight) { if (drawWinHasFocus) { XDrawLine(mainDisplay, drawWindow, revDefaultGC, textCurX, textCurBaselineY-asc, textCurX, textCurBaselineY+des); } } if (canvasFontDoubleByte && gnInputMethod != TGIM_NONE && gnOverTheSpot) { if (!tgIMTellCursorPosition(mainDisplay, drawWindow, textCurX, textCurBaselineY+des)) { } } SetRightMarginActive(); } /* --------------------- EraseTextCursor() --------------------- */ void EraseTextCursor() { int asc=curStrBlock->seg->asc; int des=curStrBlock->seg->des; XDrawLine(mainDisplay, drawWindow, revDefaultGC, textCurX, textCurBaselineY-asc, textCurX, textCurBaselineY+des); } /* --------------------- GetCurTextBBoxes() --------------------- */ void GetCurTextBBoxes(pOBBox, pBBox) struct BBRec *pOBBox, *pBBox; /* * pOBBox bounds the inner curTextObj * pBBox bounds the outer curTextObj and textW and textH */ { struct TextRec *text_ptr=curTextObj->detail.t; MiniLinesInfo *minilines=(&text_ptr->minilines); int ltx=0, lty=0, w=0, h=0; if (pOBBox != NULL) { ltx = textOrigX; lty = textOrigBaselineY-minilines->first->asc; w = minilines->w; h = minilines->h; switch (minilines->just) { case JUST_L: break; case JUST_C: ltx -= (w>>1); break; case JUST_R: ltx -= w; break; } SetBBRec(pOBBox, ltx, lty, ltx+w, lty+h); } if (pBBox != NULL) { ltx = textOrigX; lty = textOrigY; w = textW; h = textH; switch (minilines->just) { case JUST_L: break; case JUST_C: ltx -= (w>>1); break; case JUST_R: ltx -= w; break; } SetBBRec(pBBox, ltx+textAbsMinLBearing, lty, ltx+w+textAbsMaxRExtra, lty+h); } } /* --------------------- RedrawCurText() --------------------- */ static int UpdateTextHighlightInfo() { int min_y_1=0, max_y_1=0, min_y_2=0, max_y_2=0; int reverse=FALSE; if (curStrBlock->depth != endStrBlock->depth) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "curStrBlock->depth = %1d, endStrBlock->depth = %1d\n", curStrBlock->depth, endStrBlock->depth); #endif /* _TGIF_DBG */ sprintf(gszMsgBox, TgLoadString(STID_UNEQUAL_DEPTHS_IN_FUNC), "UpdateTextHighlightInfo()"); FatalUnexpectedError(gszMsgBox, NULL); return FALSE; } if (curStrBlock->type == SB_SUPSUB_CENTER) { min_y_1 = textCurBaselineY - curStrBlock->seg->asc; max_y_1 = textCurBaselineY + curStrBlock->seg->des; } else { min_y_1 = textCurBaselineY - curStrBlock->owner_mini_line->asc; max_y_1 = textCurBaselineY + curStrBlock->owner_mini_line->des; } if (endStrBlock->type == SB_SUPSUB_CENTER) { min_y_2 = textEndBaselineY - endStrBlock->seg->asc; max_y_2 = textEndBaselineY + endStrBlock->seg->des; } else { min_y_2 = textEndBaselineY - endStrBlock->owner_mini_line->asc; max_y_2 = textEndBaselineY + endStrBlock->owner_mini_line->des; } if (curStrBlock->pre_order == endStrBlock->pre_order) { if (textCurX < textEndX) { reverse = FALSE; } else if (textCurX > textEndX) { reverse = TRUE; } else { textHighlight = FALSE; endStrBlock = NULL; textEndIndex = INVALID; return FALSE; } } else if (curStrBlock->pre_order < endStrBlock->pre_order) { reverse = FALSE; } else { reverse = TRUE; } if (reverse) { gstTextHighlightInfo.start_x = textEndX; gstTextHighlightInfo.start_min_y = min_y_2; gstTextHighlightInfo.start_max_y = max_y_2; gstTextHighlightInfo.start_baseline_y = textEndBaselineY; gstTextHighlightInfo.end_x = textCurX; gstTextHighlightInfo.end_min_y = min_y_1; gstTextHighlightInfo.end_max_y = max_y_1; gstTextHighlightInfo.end_baseline_y = textCurBaselineY; gstTextHighlightInfo.start_str_block_ptr = endStrBlock; gstTextHighlightInfo.start_index = textEndIndex; gstTextHighlightInfo.end_str_block_ptr = curStrBlock; gstTextHighlightInfo.end_index = textCurIndex; } else { gstTextHighlightInfo.start_x = textCurX; gstTextHighlightInfo.start_min_y = min_y_1; gstTextHighlightInfo.start_max_y = max_y_1; gstTextHighlightInfo.start_baseline_y = textCurBaselineY; gstTextHighlightInfo.end_x = textEndX; gstTextHighlightInfo.end_min_y = min_y_2; gstTextHighlightInfo.end_max_y = max_y_2; gstTextHighlightInfo.end_baseline_y = textEndBaselineY; gstTextHighlightInfo.start_str_block_ptr = curStrBlock; gstTextHighlightInfo.start_index = textCurIndex; gstTextHighlightInfo.end_str_block_ptr = endStrBlock; gstTextHighlightInfo.end_index = textEndIndex; } return TRUE; } static void GetMinilineHomeXY(pMiniLine, pn_x, pn_baseline_y) MiniLineInfo *pMiniLine; int *pn_x, *pn_baseline_y; { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pMiniLine->first_block->type == SB_SIMPLE || pMiniLine->first_block->type == SB_SUPSUB_CENTER, "First StrBlock has invalid type in GetMinilineHomeXY()", NULL); #endif /* _TGIF_DBG */ GetTextXY(pMiniLine->first_block, 0, pn_x, pn_baseline_y); } static void GetMinilineEndXY(pMiniLine, pn_x, pn_baseline_y) MiniLineInfo *pMiniLine; int *pn_x, *pn_baseline_y; { StrBlockInfo *pStrBlock=NULL; int index=INVALID; for (pStrBlock=pMiniLine->first_block; pStrBlock->next != NULL; pStrBlock=pStrBlock->next) { } switch (pStrBlock->type) { case SB_SIMPLE: case SB_SUPSUB_CENTER: index = pStrBlock->seg->dyn_str.sz-1; break; case SB_CHAR_SPACE: #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "Last StrBlock has type of SB_CHAR_SPACE in GetMinilineEndXY()", NULL); #endif /* _TGIF_DBG */ index = 1; break; } GetTextXY(pStrBlock, index, pn_x, pn_baseline_y); } static void PaintTextHighlight() { XGCValues values; if (!UpdateTextHighlightInfo()) return; if (useAltEditTextBgColor) { if (altEditTextHighlightIndex == INVALID) { values.foreground = myBgPixel; } else { values.foreground = colorPixels[altEditTextHighlightIndex]; } } else { values.foreground = myFgPixel; } values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle, &values); if (gstTextHighlightInfo.start_min_y == gstTextHighlightInfo.end_min_y) { int w=(gstTextHighlightInfo.end_x-gstTextHighlightInfo.start_x); int h=(gstTextHighlightInfo.start_max_y-gstTextHighlightInfo.start_min_y); XFillRectangle(mainDisplay, drawWindow, drawGC, gstTextHighlightInfo.start_x, gstTextHighlightInfo.start_min_y, w, h); } else { int start_x=0, end_x=0, min_y=0, max_y=0; MiniLineInfo *pMiniLine=NULL; MiniLineInfo *pStartMiniLine= gstTextHighlightInfo.start_str_block_ptr->owner_mini_line; MiniLineInfo *pEndMiniLine= gstTextHighlightInfo.end_str_block_ptr->owner_mini_line; start_x = gstTextHighlightInfo.start_x; GetMinilineEndXY(pStartMiniLine, &end_x, NULL); min_y = gstTextHighlightInfo.start_min_y; max_y = gstTextHighlightInfo.start_max_y; XFillRectangle(mainDisplay, drawWindow, drawGC, start_x, min_y, end_x-start_x, max_y-min_y); for (pMiniLine=pStartMiniLine->next; pMiniLine != pEndMiniLine; pMiniLine=pMiniLine->next) { int left_baseline_y=0, right_baseline_y=0; GetMinilineHomeXY(pMiniLine, &start_x, &left_baseline_y); GetMinilineEndXY(pMiniLine, &end_x, &right_baseline_y); if (left_baseline_y != right_baseline_y) { sprintf(gszMsgBox, TgLoadString(STID_BASELINE_YS_NOT_EQ_IN_FUNC), "PaintTextHighlight()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } min_y = left_baseline_y - pMiniLine->asc; max_y = left_baseline_y + pMiniLine->des; XFillRectangle(mainDisplay, drawWindow, drawGC, start_x, min_y, end_x-start_x, max_y-min_y); } GetMinilineHomeXY(pMiniLine, &start_x, NULL); end_x = gstTextHighlightInfo.end_x; min_y = gstTextHighlightInfo.end_min_y; max_y = gstTextHighlightInfo.end_max_y; XFillRectangle(mainDisplay, drawWindow, drawGC, start_x, min_y, end_x-start_x, max_y-min_y); } } static void GetPaintMode(pStrBlock, pnMode, pnFirstIndex, pnSecondIndex) int *pnMode, *pnFirstIndex, *pnSecondIndex; StrBlockInfo *pStrBlock; { *pnMode = gstTextHighlightInfo.mode; *pnFirstIndex = INVALID; *pnSecondIndex = INVALID; if (gstTextHighlightInfo.highlighting) { if (pStrBlock == gstTextHighlightInfo.end_str_block_ptr) { if (pStrBlock == gstTextHighlightInfo.end_str_block_ptr) { *pnMode = PAINT_INV_NORM; *pnFirstIndex = gstTextHighlightInfo.end_index; } else { *pnMode = PAINT_INV; } } } else { if (pStrBlock == gstTextHighlightInfo.start_str_block_ptr) { if (pStrBlock == gstTextHighlightInfo.end_str_block_ptr) { *pnMode = PAINT_NORM_INV_NORM; *pnFirstIndex = gstTextHighlightInfo.start_index; *pnSecondIndex = gstTextHighlightInfo.end_index; } else { *pnMode = PAINT_NORM_INV; *pnFirstIndex = gstTextHighlightInfo.start_index; gstTextHighlightInfo.highlighting = TRUE; } } } gstTextHighlightInfo.mode = (*pnMode); } static void PaintString(dpy, d, gc, depth, x, baseline_y, buf, len, color_pixel, underline_on, overline_on, mode, first_index, second_index) Display *dpy; Drawable d; GC gc; int depth, x, baseline_y, len, color_pixel, underline_on, overline_on; int mode, first_index, second_index; char *buf; /* * x is the left edge of the string. */ { int inv_pixel=myBgPixel, w=0; int underline_yoffset=curUnderlineYOffset; int overline_yoffset=curOverlineYOffset; int overunder=(underline_on || overline_on); if (useAltEditTextBgColor) { if (altEditTextBgIndex == INVALID) { inv_pixel = myFgPixel; } else { inv_pixel = colorPixels[altEditTextBgIndex]; } } else { inv_pixel = myBgPixel; } if (mode & PAINT) { switch (mode) { case PAINT_NORM: XSetForeground(dpy, gc, color_pixel); MyDrawString(dpy, d, gc, depth, x, baseline_y, buf, len); if (overunder) { w = MyTextWidth(canvasFontPtr, buf, len); if (underline_on) { XDrawLine(dpy, d, gc, x, baseline_y+underline_yoffset, x+w, baseline_y+underline_yoffset); } if (overline_on) { XDrawLine(dpy, d, gc, x, baseline_y-canvasFontAsc-overline_yoffset, x+w, baseline_y-canvasFontAsc-overline_yoffset); } } break; case PAINT_INV: XSetForeground(dpy, gc, inv_pixel); MyDrawString(dpy, d, gc, depth, x, baseline_y, buf, len); if (overunder) { w = MyTextWidth(canvasFontPtr, buf, len); if (underline_on) { XDrawLine(dpy, d, gc, x, baseline_y+underline_yoffset, x+w, baseline_y+underline_yoffset); } if (overline_on) { XDrawLine(dpy, d, gc, x, baseline_y-canvasFontAsc-overline_yoffset, x+w, baseline_y-canvasFontAsc-overline_yoffset); } } break; case PAINT_NORM_INV: XSetForeground(dpy, gc, color_pixel); MyDrawString(dpy, d, gc, depth, x, baseline_y, buf, first_index); w = MyTextWidth(canvasFontPtr, buf, first_index); if (underline_on) { XDrawLine(dpy, d, gc, x, baseline_y+underline_yoffset, x+w, baseline_y+underline_yoffset); } if (overline_on) { XDrawLine(dpy, d, gc, x, baseline_y-canvasFontAsc-overline_yoffset, x+w, baseline_y-canvasFontAsc-overline_yoffset); } x += w; XSetForeground(dpy, gc, inv_pixel); MyDrawString(dpy, d, gc, depth, x, baseline_y, &buf[first_index], len-first_index); if (overunder) { w = MyTextWidth(canvasFontPtr, &buf[first_index], len-first_index); if (underline_on) { XDrawLine(dpy, d, gc, x, baseline_y+underline_yoffset, x+w, baseline_y+underline_yoffset); } if (overline_on) { XDrawLine(dpy, d, gc, x, baseline_y-canvasFontAsc-overline_yoffset, x+w, baseline_y-canvasFontAsc-overline_yoffset); } } break; case PAINT_INV_NORM: XSetForeground(dpy, gc, inv_pixel); MyDrawString(dpy, d, gc, depth, x, baseline_y, buf, first_index); w = MyTextWidth(canvasFontPtr, buf, first_index); if (underline_on) { XDrawLine(dpy, d, gc, x, baseline_y+underline_yoffset, x+w, baseline_y+underline_yoffset); } if (overline_on) { XDrawLine(dpy, d, gc, x, baseline_y-canvasFontAsc-overline_yoffset, x+w, baseline_y-canvasFontAsc-overline_yoffset); } x += w; XSetForeground(dpy, gc, color_pixel); MyDrawString(dpy, d, gc, depth, x, baseline_y, &buf[first_index], len-first_index); if (overunder) { w = MyTextWidth(canvasFontPtr, &buf[first_index], len-first_index); if (underline_on) { XDrawLine(dpy, d, gc, x, baseline_y+underline_yoffset, x+w, baseline_y+underline_yoffset); } if (overline_on) { XDrawLine(dpy, d, gc, x, baseline_y-canvasFontAsc-overline_yoffset, x+w, baseline_y-canvasFontAsc-overline_yoffset); } } break; case PAINT_NORM_INV_NORM: XSetForeground(dpy, gc, color_pixel); MyDrawString(dpy, d, gc, depth, x, baseline_y, buf, first_index); w = MyTextWidth(canvasFontPtr, buf, first_index); if (underline_on) { XDrawLine(dpy, d, gc, x, baseline_y+underline_yoffset, x+w, baseline_y+underline_yoffset); } if (overline_on) { XDrawLine(dpy, d, gc, x, baseline_y-canvasFontAsc-overline_yoffset, x+w, baseline_y-canvasFontAsc-overline_yoffset); } x += w; XSetForeground(dpy, gc, inv_pixel); MyDrawString(dpy, d, gc, depth, x, baseline_y, &buf[first_index], second_index-first_index); w = MyTextWidth(canvasFontPtr, &buf[first_index], second_index-first_index); if (underline_on) { XDrawLine(dpy, d, gc, x, baseline_y+underline_yoffset, x+w, baseline_y+underline_yoffset); } if (overline_on) { XDrawLine(dpy, d, gc, x, baseline_y-canvasFontAsc-overline_yoffset, x+w, baseline_y-canvasFontAsc-overline_yoffset); } x += w; XSetForeground(dpy, gc, color_pixel); MyDrawString(dpy, d, gc, depth, x, baseline_y, &buf[second_index], len-second_index); if (overunder) { w = MyTextWidth(canvasFontPtr, &buf[second_index], len-second_index); if (underline_on) { XDrawLine(dpy, d, gc, x, baseline_y+underline_yoffset, x+w, baseline_y+underline_yoffset); } if (overline_on) { XDrawLine(dpy, d, gc, x, baseline_y-canvasFontAsc-overline_yoffset, x+w, baseline_y-canvasFontAsc-overline_yoffset); } } break; } } } static void PaintStrSeg(dpy, d, gc, depth, x, baseline_y, pStrSeg, use_highlight, use_as_mask, mode, first_index, second_index) Display *dpy; Drawable d; GC gc; int depth, x, baseline_y, use_highlight, use_as_mask; int mode, first_index, second_index; StrSegInfo *pStrSeg; /* * x is the left edge of the string segment. */ { XGCValues values; curFont = pStrSeg->font; curStyle = pStrSeg->style; curSzUnit = pStrSeg->sz_unit; SetCanvasFont(); if (use_as_mask) { values.foreground = 1; } else if (colorDisplay) { values.foreground = colorPixels[pStrSeg->color]; } else { values.foreground = myFgPixel; } values.function = GXcopy; values.fill_style = (transPat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[penPat]; values.font = canvasFontPtr->fid; values.line_width = 1; values.line_style = LineSolid; XChangeGC(dpy, gc, GCForeground | GCFunction | GCFillStyle | GCStipple | GCFont | GCLineWidth | GCLineStyle, &values); if (use_highlight && !use_as_mask) { PaintString(dpy, d, gc, depth, x, baseline_y, pStrSeg->dyn_str.s, pStrSeg->dyn_str.sz-1, (colorDisplay ? colorPixels[pStrSeg->color] : myFgPixel), pStrSeg->underline_on, pStrSeg->overline_on, mode, first_index, second_index); switch (mode) { case PAINT_NORM: case PAINT_INV_NORM: case PAINT_NORM_INV_NORM: gstTextHighlightInfo.mode = PAINT_NORM; break; case PAINT_INV: case PAINT_NORM_INV: gstTextHighlightInfo.mode = PAINT_INV; break; } } else { MyDrawString(dpy, d, gc, depth, x, baseline_y, pStrSeg->dyn_str.s, pStrSeg->dyn_str.sz-1); if (pStrSeg->underline_on) { int offset=curUnderlineYOffset; XDrawLine(dpy, d, gc, x, baseline_y+offset, x+pStrSeg->w, baseline_y+offset); } if (pStrSeg->overline_on) { int offset=curOverlineYOffset; XDrawLine(dpy, d, gc, x, baseline_y-canvasFontAsc-offset, x+pStrSeg->w, baseline_y-canvasFontAsc-offset); } } } static void PaintStrBlock(dpy, d, gc, depth, x, baseline_y, pStrBlock, use_highlight, use_as_mask) Display *dpy; Drawable d; GC gc; int depth, x, baseline_y, use_highlight, use_as_mask; StrBlockInfo *pStrBlock; /* * x is the left edge of the string block. */ { int saved_baseline_y=baseline_y; int block_w=pStrBlock->w; int mode=INVALID, first_index=INVALID, second_index=INVALID; if (GetDirtyBBox(NULL) && !IntersectDirtyBBox(&pStrBlock->bbox)) { return; } if (use_highlight && !use_as_mask) { switch (pStrBlock->type) { case SB_SIMPLE: case SB_CHAR_SPACE: case SB_SUPSUB_CENTER: GetPaintMode(pStrBlock, &mode, &first_index, &second_index); break; } } switch (pStrBlock->type) { case SB_SIMPLE: PaintStrSeg(dpy, d, gc, depth, x, baseline_y, pStrBlock->seg, use_highlight, use_as_mask, mode, first_index, second_index); break; case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: switch (pStrBlock->type) { case SB_SUPSUB_LEFT: x += block_w; break; case SB_SUPSUB_CENTER: x += (block_w>>1); break; case SB_SUPSUB_RIGHT: break; } if (pStrBlock->type == SB_SUPSUB_CENTER) { /* pStrBlock->seg better not be NULL or it will crash */ baseline_y = saved_baseline_y; PaintStrSeg(dpy, d, gc, depth, x-((pStrBlock->seg->w)>>1), baseline_y, pStrBlock->seg, use_highlight, use_as_mask, mode, first_index, second_index); } if (pStrBlock->sup != NULL) { baseline_y = saved_baseline_y + pStrBlock->sup->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { baseline_y -= pStrBlock->seg->asc; } PaintMiniLines(dpy, d, gc, depth, x, baseline_y, pStrBlock->sup, use_highlight, use_as_mask); } if (pStrBlock->sub != NULL) { baseline_y = saved_baseline_y + pStrBlock->sub->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { baseline_y += pStrBlock->seg->des; } PaintMiniLines(dpy, d, gc, depth, x, baseline_y, pStrBlock->sub, use_highlight, use_as_mask); } break; } } static void PaintMiniLine(dpy, d, gc, depth, x, baseline_y, pMiniLine, use_highlight, use_as_mask) Display *dpy; Drawable d; GC gc; int depth, x, baseline_y, use_highlight, use_as_mask; MiniLineInfo *pMiniLine; /* * x is the left edge of the miniline and baseline_y has been adjusted by * pMiniLine->v_gap. */ { StrBlockInfo *pStrBlock=NULL; if (GetDirtyBBox(NULL) && !IntersectDirtyBBox(&pMiniLine->bbox)) { return; } for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { PaintStrBlock(dpy, d, gc, depth, x, baseline_y, pStrBlock, use_highlight, use_as_mask); x += pStrBlock->w; } } void PaintMiniLines(dpy, d, gc, depth, x, baseline_y, minilines, use_highlight, use_as_mask) Display *dpy; Drawable d; GC gc; int depth, x, baseline_y, use_highlight, use_as_mask; MiniLinesInfo *minilines; /* * x is the origin of the minilines (not the left edge) */ { MiniLineInfo *pMiniLine=NULL; int v_space=minilines->v_space; int saved_x=x; if (GetDirtyBBox(NULL) && !IntersectDirtyBBox(&minilines->bbox)) { return; } for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { #ifdef _TGIF_DBG /* debug, do not translate */ if (pMiniLine == minilines->first) { TgAssert(pMiniLine->v_gap == 0, "First mini_line has non-zero v_gap in PaintMiniLines()", NULL); } #endif /* _TGIF_DBG */ baseline_y += pMiniLine->v_gap; switch (minilines->just) { case JUST_L: x = saved_x; break; case JUST_C: x = saved_x - ((pMiniLine->w)>>1); break; case JUST_R: x = saved_x - pMiniLine->w; break; } PaintMiniLine(dpy, d, gc, depth, x, baseline_y, pMiniLine, use_highlight, use_as_mask); baseline_y += pMiniLine->des + v_space; if (pMiniLine->next != NULL) { baseline_y += pMiniLine->next->asc; } } } static void PaintCurText() { struct TextRec *text_ptr=curTextObj->detail.t; MiniLinesInfo *minilines=(&text_ptr->minilines); int baseline_y=textOrigBaselineY, saved_pen=penPat; PushCurFont(); memset(&gstTextHighlightInfo, 0, sizeof(TextHighlightInfo)); if (textHighlight) { PaintTextHighlight(); } gstTextHighlightInfo.highlighting = FALSE; gstTextHighlightInfo.mode = PAINT_NORM; curUnderlineYOffset = text_ptr->underline_y_offset; curOverlineYOffset = text_ptr->overline_y_offset; penPat = SOLIDPAT; PaintMiniLines(mainDisplay, drawWindow, drawGC, mainDepth, textOrigX, baseline_y, minilines, TRUE, FALSE); penPat = saved_pen; PopCurFont(); } void DrawCurTextOutLine(x, y, w, h) int x, y, w, h; { XGCValues values; values.foreground = myFgPixel; values.function = GXcopy; values.fill_style = FillOpaqueStippled; values.stipple = patPixmap[SCROLLPAT]; values.line_width = curTextOutlineW; values.line_style = LineSolid; values.join_style = JoinMiter; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | GCLineStyle | GCJoinStyle, &values); XDrawRectangle(mainDisplay, drawWindow, drawGC, x-curTextOutlineHalfW, y-curTextOutlineHalfW, w+(curTextOutlineHalfW<<1), h+(curTextOutlineHalfW<<1)); } void RedrawCurText() { int x=0, y=0, w=0, h=0, clipped=FALSE; XGCValues values; if (curChoice != DRAWTEXT || !textCursorShown) return; if (GetDirtyBBox(NULL)) { struct BBRec draw_win_bbox; draw_win_bbox.ltx = draw_win_bbox.lty = 0; draw_win_bbox.rbx = initDrawWinW; draw_win_bbox.rby = initDrawWinH; if (!IntersectRect(gstDirtyBBoxInfo.bbox, draw_win_bbox, &gstDirtyBBoxInfo.bbox)) { return; } SetRecVals(clipRecs[0], gstDirtyBBoxInfo.bbox.ltx, gstDirtyBBoxInfo.bbox.lty, gstDirtyBBoxInfo.bbox.rbx-gstDirtyBBoxInfo.bbox.ltx+1, gstDirtyBBoxInfo.bbox.rby-gstDirtyBBoxInfo.bbox.lty+1); numClipRecs = 1; clipOrdering = YXBanded; XSetClipRectangles(mainDisplay, drawGC, 0, 0, clipRecs, numClipRecs, clipOrdering); clipped = TRUE; } GetCurTextBBoxes(NULL, &curTextBBox); x = curTextBBox.ltx-2; y = curTextBBox.lty-2; w = curTextBBox.rbx-curTextBBox.ltx+4; h = curTextBBox.rby-curTextBBox.lty+4; if (useAltEditTextBgColor) { if (altEditTextBgIndex == INVALID) { values.foreground = myFgPixel; } else { values.foreground = colorPixels[altEditTextBgIndex]; } } else { values.foreground = GetDrawingBgPixel(INVALID, INVALID); } values.function = GXcopy; values.fill_style = FillSolid; values.line_width = 1; values.line_style = LineSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCLineWidth | GCLineStyle, &values); XFillRectangle(mainDisplay, drawWindow, drawGC, x, y, w, h); DrawCurTextOutLine(x, y, w, h); PaintCurText(); if (clipped) { SetDefaultDrawWinClipRecs(); } PutTextCursor(); ResetDirtyBBoxInfo(); UpdateCurTextBBoxes(TRUE); } /* --------------------- UpdateHighLightedTextBBoxes() --------------------- */ void UpdateHighLightedTextBBoxes(clean) int clean; { if (clean) { ResetDirtyBBoxInfo(); } else { UpdateCurTextBBoxes(FALSE); } AddToDirtyBBox(&curStrBlock->clean_bbox); if (textHighlight && UpdateTextHighlightInfo()) { int w=(gstTextHighlightInfo.end_x-gstTextHighlightInfo.start_x); int h=(gstTextHighlightInfo.start_max_y-gstTextHighlightInfo.start_min_y); struct BBRec bbox; SetBBRec(&bbox, gstTextHighlightInfo.start_x, gstTextHighlightInfo.start_min_y, gstTextHighlightInfo.start_x+w, gstTextHighlightInfo.start_min_y+h); AddToDirtyBBox(&endStrBlock->clean_bbox); AddToDirtyBBox(&bbox); if (gstTextHighlightInfo.start_min_y != gstTextHighlightInfo.end_min_y) { int start_x=0, end_x=0, min_y=0, max_y=0; MiniLineInfo *pMiniLine=NULL; MiniLineInfo *pStartMiniLine= gstTextHighlightInfo.start_str_block_ptr->owner_mini_line; MiniLineInfo *pEndMiniLine= gstTextHighlightInfo.end_str_block_ptr->owner_mini_line; AddToDirtyBBox(&endStrBlock->clean_bbox); start_x = gstTextHighlightInfo.start_x; GetMinilineEndXY(pStartMiniLine, &end_x, NULL); min_y = gstTextHighlightInfo.start_min_y; max_y = gstTextHighlightInfo.start_max_y; SetBBRec(&bbox, start_x, min_y, end_x, max_y); AddToDirtyBBox(&bbox); for (pMiniLine=pStartMiniLine->next; pMiniLine != pEndMiniLine; pMiniLine=pMiniLine->next) { int left_baseline_y=0, right_baseline_y=0; GetMinilineHomeXY(pMiniLine, &start_x, &left_baseline_y); GetMinilineEndXY(pMiniLine, &end_x, &right_baseline_y); if (left_baseline_y != right_baseline_y) { sprintf(gszMsgBox, TgLoadString(STID_BASELINE_YS_NOT_EQ_IN_FUNC), "PaintTextHighlight()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } min_y = left_baseline_y - pMiniLine->asc; max_y = left_baseline_y + pMiniLine->des; SetBBRec(&bbox, start_x, min_y, end_x, max_y); AddToDirtyBBox(&bbox); } GetMinilineHomeXY(pMiniLine, &start_x, NULL); end_x = gstTextHighlightInfo.end_x; min_y = gstTextHighlightInfo.end_min_y; max_y = gstTextHighlightInfo.end_max_y; SetBBRec(&bbox, start_x, min_y, end_x, max_y); AddToDirtyBBox(&bbox); } } } /* --------------------- DeleteHighlightedText() --------------------- */ static int DeleteHighlightedTextInStrSeg(pStrSeg, mode, first_index, second_index) StrSegInfo *pStrSeg; int mode, first_index, second_index; /* return TRUE if all done deleting */ { char *psz=NULL, *psz1=NULL, *psz2=NULL; switch (mode) { case PAINT_NORM: break; case PAINT_INV: break; case PAINT_NORM_INV: /* delete the tail */ pStrSeg->dyn_str.s[first_index] = '\0'; if ((psz=UtilStrDup(pStrSeg->dyn_str.s)) == NULL) FailAllocMessage(); DynStrSet(&pStrSeg->dyn_str, psz); UtilFree(psz); gstTextHighlightInfo.mode = PAINT_INV; break; case PAINT_INV_NORM: if ((psz=UtilStrDup(&pStrSeg->dyn_str.s[first_index])) == NULL) { FailAllocMessage(); } DynStrSet(&pStrSeg->dyn_str, psz); UtilFree(psz); gstTextHighlightInfo.mode = PAINT_NORM; return TRUE; case PAINT_NORM_INV_NORM: if ((psz=UtilStrDup(pStrSeg->dyn_str.s)) == NULL) { FailAllocMessage(); } for (psz1=(&psz[first_index]), psz2=(&psz[second_index]); *psz2 != '\0'; psz1++, psz2++) { *psz1 = *psz2; } *psz1 = '\0'; DynStrSet(&pStrSeg->dyn_str, psz); UtilFree(psz); gstTextHighlightInfo.mode = PAINT_NORM; return TRUE; } return FALSE; } void MergeNextMiniLineWhileDeleting(pMiniLine) MiniLineInfo *pMiniLine; /* combine pMiniLine and pMiniLine->next */ { StrBlockInfo *pStrBlock=NULL; MiniLineInfo *pMiniLineToFree=pMiniLine->next; #ifdef _TGIF_DBG /* debug, do not translate */ if (pMiniLine->next == NULL) { sprintf(gszMsgBox, "%s: %s %s.", "Failed assertion", "pMiniLine->next == NULL in", "MergeNextMiniLineWhileDeleting()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } #endif /* _TGIF_DBG */ for (pStrBlock=pMiniLineToFree->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { pStrBlock->owner_mini_line = pMiniLine; } pMiniLine->last_block->next = pMiniLineToFree->first_block; pMiniLineToFree->first_block->prev = pMiniLine->last_block; pMiniLine->last_block = pMiniLineToFree->last_block; UnlinkMiniLine(pMiniLineToFree); pMiniLineToFree->first_block = pMiniLineToFree->last_block = NULL; FreeMiniLine(pMiniLineToFree); } int StrBlocksHasSameProperties(pStrBlock1, pStrBlock2) StrBlockInfo *pStrBlock1, *pStrBlock2; { if (pStrBlock1->type != pStrBlock2->type) { return FALSE; } else if (pStrBlock1->type == SB_SIMPLE) { StrSegInfo *pStrSeg1=pStrBlock1->seg, *pStrSeg2=pStrBlock2->seg; if (pStrSeg1->color == pStrSeg2->color && pStrSeg1->underline_on == pStrSeg2->underline_on && pStrSeg1->overline_on == pStrSeg2->overline_on && pStrSeg1->font == pStrSeg2->font && pStrSeg1->style == pStrSeg2->style && pStrSeg1->sz_unit == pStrSeg2->sz_unit) { return TRUE; } } else if (pStrBlock1->type == SB_CHAR_SPACE) { return TRUE; } return FALSE; } static void MergeNextStrBlockWhileDeleting(pStrBlock, pNextStrBlock) StrBlockInfo *pStrBlock, *pNextStrBlock; /* combine pStrBlock and pNextStrBlock */ { int len=pStrBlock->seg->dyn_str.sz+pNextStrBlock->seg->dyn_str.sz-1; char *psz=(char*)malloc(len+1); if (psz == NULL) FailAllocMessage(); sprintf(psz, "%s%s", pStrBlock->seg->dyn_str.s, pNextStrBlock->seg->dyn_str.s); DynStrSet(&pStrBlock->seg->dyn_str, psz); free(psz); UnlinkStrBlock(pNextStrBlock); FreeStrBlock(pNextStrBlock); } int MergeStrBlocks(pStrBlock, pNextStrBlock) StrBlockInfo *pStrBlock, *pNextStrBlock; { if (pStrBlock->type == SB_SIMPLE && StrBlocksHasSameProperties(pStrBlock, pNextStrBlock)) { MergeNextStrBlockWhileDeleting(pStrBlock, pNextStrBlock); return TRUE; } return FALSE; } void DeleteHighlightedText() { MiniLineInfo *pOwnerMiniLine=NULL; StrBlockInfo *saved_str_block=NULL, *pStrBlock=NULL, *pNextStrBlock=NULL; int saved_index=INVALID, first_index=0, second_index=0, mode=PAINT_NORM; if (!textHighlight) return; /* setup gstTextHighlightInfo */ if (!UpdateTextHighlightInfo()) return; gstTextHighlightInfo.highlighting = FALSE; gstTextHighlightInfo.mode = PAINT_NORM; pStrBlock = saved_str_block = gstTextHighlightInfo.start_str_block_ptr; saved_index = gstTextHighlightInfo.start_index; pOwnerMiniLine = pStrBlock->owner_mini_line; AddToDirtyBBox(&pStrBlock->clean_bbox); GetPaintMode(pStrBlock, &mode, &first_index, &second_index); DeleteHighlightedTextInStrSeg(pStrBlock->seg, mode, first_index, second_index); mode = gstTextHighlightInfo.mode; pStrBlock = pStrBlock->next; while (mode != PAINT_NORM) { if (pStrBlock == NULL) { /* combine pOwnerMiniLine and pOwnerMiniLine->next */ pNextStrBlock = pOwnerMiniLine->next->first_block; MergeNextMiniLineWhileDeleting(pOwnerMiniLine); pStrBlock = pNextStrBlock; continue; } pNextStrBlock = pStrBlock->next; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); AddToDirtyBBox(&pStrBlock->clean_bbox); if (mode == PAINT_INV) { UnlinkStrBlock(pStrBlock); FreeStrBlock(pStrBlock); pStrBlock = NULL; } else { /* pStrBlock->type better be SB_SIMPLE */ #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pStrBlock->type == SB_SIMPLE, "pStrBlock->type != SB_SIMPLE in DeleteHighlightedText()", NULL); #endif /* _TGIF_DBG */ DeleteHighlightedTextInStrSeg(pStrBlock->seg, mode, first_index, second_index); } mode = gstTextHighlightInfo.mode; pStrBlock = pNextStrBlock; } curStrBlock = saved_str_block; textCurIndex = saved_index; ResetOnCursorKey(FALSE); textHighlight = FALSE; while (*curStrBlock->seg->dyn_str.s == '\0' && curStrBlock->next != NULL && curStrBlock->next->type == SB_SIMPLE && *curStrBlock->next->seg->dyn_str.s == '\0') { pStrBlock = curStrBlock->next; UnlinkStrBlock(pStrBlock); FreeStrBlock(pStrBlock); pStrBlock = NULL; } while (curStrBlock->next != NULL) { if (!MergeStrBlocks(curStrBlock, curStrBlock->next)) { break; } } SetTextCurXY(); } /* --------------------- DoInsertThinSpace() --------------------- */ static void DetermineWhatToDoForSpace(pnSplitAtIndex, pnInsertBefore) int *pnSplitAtIndex, *pnInsertBefore; { if (textCurIndex == 0 && curStrBlock->seg->dyn_str.sz != 1) { if (curStrBlock->prev == NULL || curStrBlock->prev->type != SB_SIMPLE) { *pnSplitAtIndex = TRUE; } else { *pnInsertBefore = TRUE; } } else if (textCurIndex == curStrBlock->seg->dyn_str.sz-1) { if (curStrBlock->next == NULL || curStrBlock->next->type != SB_SIMPLE) { *pnSplitAtIndex = TRUE; } else { *pnInsertBefore = FALSE; } } else { *pnSplitAtIndex = TRUE; } } void DoInsertThinSpace(thin_space_w) int thin_space_w; { int split_at_index=FALSE, insert_before=FALSE; MiniLineInfo *owner_mini_line=curStrBlock->owner_mini_line; StrBlockInfo *pThinSpaceStrBlock=NewStrBlock(); pThinSpaceStrBlock->type = SB_CHAR_SPACE; pThinSpaceStrBlock->special_char_w = pThinSpaceStrBlock->w = thin_space_w; pThinSpaceStrBlock->owner_mini_line = owner_mini_line; DetermineWhatToDoForSpace(&split_at_index, &insert_before); if (split_at_index) { StrBlockInfo *pLeftStrBlock=NULL; char *psz=UtilStrDup(curStrBlock->seg->dyn_str.s), saved_ch='\0'; if (psz == NULL) FailAllocMessage(); DupStrBlock(curStrBlock, owner_mini_line, &pLeftStrBlock, &pLeftStrBlock); saved_ch = psz[textCurIndex]; psz[textCurIndex] = '\0'; DynStrSet(&pLeftStrBlock->seg->dyn_str, psz); psz[textCurIndex] = saved_ch; DynStrSet(&curStrBlock->seg->dyn_str, &psz[textCurIndex]); UtilFree(psz); pLeftStrBlock->prev = curStrBlock->prev; if (curStrBlock->prev == NULL) { owner_mini_line->first_block = pLeftStrBlock; } else { curStrBlock->prev->next = pLeftStrBlock; } pLeftStrBlock->next = pThinSpaceStrBlock; pThinSpaceStrBlock->prev = pLeftStrBlock; pThinSpaceStrBlock->next = curStrBlock; curStrBlock->prev = pThinSpaceStrBlock; textCurIndex = 0; } else if (insert_before) { pThinSpaceStrBlock->prev = curStrBlock->prev; curStrBlock->prev->next = pThinSpaceStrBlock; pThinSpaceStrBlock->next = curStrBlock; curStrBlock->prev = pThinSpaceStrBlock; } else { /* insert after */ pThinSpaceStrBlock->next = curStrBlock->next; curStrBlock->next->prev = pThinSpaceStrBlock; pThinSpaceStrBlock->prev = curStrBlock; curStrBlock->next = pThinSpaceStrBlock; } } /* --------------------- InsertHighlightedThinSpace() --------------------- */ static int InsertHighlightedThinSpaceInStrSeg(pStrSeg, mode, first_index, second_index) StrSegInfo *pStrSeg; int mode, first_index, second_index; /* return TRUE if all done deleting */ { char *psz=NULL, *psz1=NULL, *psz2=NULL; switch (mode) { case PAINT_NORM: break; case PAINT_INV: break; case PAINT_NORM_INV: /* delete the tail */ pStrSeg->dyn_str.s[first_index] = '\0'; if ((psz=UtilStrDup(pStrSeg->dyn_str.s)) == NULL) FailAllocMessage(); DynStrSet(&pStrSeg->dyn_str, psz); UtilFree(psz); gstTextHighlightInfo.mode = PAINT_INV; break; case PAINT_INV_NORM: if ((psz=UtilStrDup(&pStrSeg->dyn_str.s[first_index])) == NULL) { FailAllocMessage(); } DynStrSet(&pStrSeg->dyn_str, psz); UtilFree(psz); gstTextHighlightInfo.mode = PAINT_NORM; return TRUE; case PAINT_NORM_INV_NORM: if ((psz=UtilStrDup(pStrSeg->dyn_str.s)) == NULL) { FailAllocMessage(); } for (psz1=(&psz[first_index]), psz2=(&psz[second_index]); *psz2 != '\0'; psz1++, psz2++) { *psz1 = *psz2; } *psz1 = '\0'; DynStrSet(&pStrSeg->dyn_str, psz); UtilFree(psz); gstTextHighlightInfo.mode = PAINT_NORM; return TRUE; } return FALSE; } void InsertHighlightedThinSpace(thin_space_w) int thin_space_w; { MiniLineInfo *pOwnerMiniLine=NULL; StrBlockInfo *saved_str_block=NULL, *pStrBlock=NULL, *pNextStrBlock=NULL; int saved_index=INVALID, first_index=0, second_index=0, mode=PAINT_NORM; if (!textHighlight) return; /* setup gstTextHighlightInfo */ if (!UpdateTextHighlightInfo()) return; gstTextHighlightInfo.highlighting = FALSE; gstTextHighlightInfo.mode = PAINT_NORM; pStrBlock = saved_str_block = gstTextHighlightInfo.start_str_block_ptr; saved_index = gstTextHighlightInfo.start_index; pOwnerMiniLine = pStrBlock->owner_mini_line; AddToDirtyBBox(&pStrBlock->clean_bbox); GetPaintMode(pStrBlock, &mode, &first_index, &second_index); InsertHighlightedThinSpaceInStrSeg(pStrBlock->seg, mode, first_index, second_index); mode = gstTextHighlightInfo.mode; pStrBlock = pStrBlock->next; while (mode != PAINT_NORM) { if (pStrBlock == NULL) { /* combine pOwnerMiniLine and pOwnerMiniLine->next */ pNextStrBlock = pOwnerMiniLine->next->first_block; pStrBlock = pNextStrBlock; continue; } pNextStrBlock = pStrBlock->next; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); AddToDirtyBBox(&pStrBlock->clean_bbox); if (mode == PAINT_INV) { UnlinkStrBlock(pStrBlock); FreeStrBlock(pStrBlock); pStrBlock = NULL; } else { /* pStrBlock->type better be SB_SIMPLE */ #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pStrBlock->type == SB_SIMPLE, "pStrBlock->type != SB_SIMPLE in InsertHighlightedThinSpace()", NULL); #endif /* _TGIF_DBG */ InsertHighlightedThinSpaceInStrSeg(pStrBlock->seg, mode, first_index, second_index); } mode = gstTextHighlightInfo.mode; pStrBlock = pNextStrBlock; } curStrBlock = saved_str_block; textCurIndex = saved_index; ResetOnCursorKey(FALSE); textHighlight = FALSE; while (*curStrBlock->seg->dyn_str.s == '\0' && curStrBlock->next != NULL && curStrBlock->next->type == SB_SIMPLE && *curStrBlock->next->seg->dyn_str.s == '\0') { pStrBlock = curStrBlock->next; UnlinkStrBlock(pStrBlock); FreeStrBlock(pStrBlock); pStrBlock = NULL; } SetTextCurXY(); } /* --------------------- ShrinkMiniLines() --------------------- */ static int ShrinkMiniLine(pMiniLine, pn_retry) MiniLineInfo *pMiniLine; int *pn_retry; { StrBlockInfo *pStrBlock=pMiniLine->first_block; int changed=FALSE; while (pStrBlock != NULL) { StrBlockInfo *pNextStrBlock=pStrBlock->next; int advance=TRUE; switch (pStrBlock->type) { case SB_SIMPLE: if (pNextStrBlock != NULL && pNextStrBlock->type == SB_SIMPLE) { if (*pNextStrBlock->seg->dyn_str.s == '\0' || StrBlocksHasSameProperties(pStrBlock, pNextStrBlock)) { MergeNextStrBlockWhileDeleting(pStrBlock, pNextStrBlock); changed = TRUE; advance = FALSE; } else if (*pStrBlock->seg->dyn_str.s == '\0') { UnlinkStrBlock(pStrBlock); FreeStrBlock(pStrBlock); *pn_retry = TRUE; changed = TRUE; advance = FALSE; pStrBlock = pNextStrBlock; } } break; case SB_CHAR_SPACE: if (pStrBlock->special_char_w == 0) { UnlinkStrBlock(pStrBlock); FreeStrBlock(pStrBlock); *pn_retry = TRUE; changed = TRUE; advance = FALSE; pStrBlock = pNextStrBlock; } break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) { if (ShrinkMiniLines(pStrBlock->sup, pn_retry)) { changed = TRUE; } } if (pStrBlock->sub != NULL) { if (ShrinkMiniLines(pStrBlock->sub, pn_retry)) { changed = TRUE; } } if (pStrBlock->sup != NULL && pStrBlock->sub != NULL && BlankMiniLines(pStrBlock->sup) && BlankMiniLines(pStrBlock->sub)) { if ((pStrBlock->type == SB_SUPSUB_CENTER && *pStrBlock->seg->dyn_str.s == '\0') || pStrBlock->type != SB_SUPSUB_CENTER) { UnlinkStrBlock(pStrBlock); FreeStrBlock(pStrBlock); *pn_retry = TRUE; changed = TRUE; advance = FALSE; pStrBlock = pNextStrBlock; } else if (pStrBlock->type == SB_SUPSUB_CENTER && *pStrBlock->seg->dyn_str.s != '\0') { if (pStrBlock->sup != NULL) FreeMiniLines(pStrBlock->sup, TRUE); if (pStrBlock->sub != NULL) FreeMiniLines(pStrBlock->sub, TRUE); pStrBlock->sup = pStrBlock->sub = NULL; pStrBlock->type = SB_SIMPLE; *pn_retry = TRUE; changed = TRUE; advance = FALSE; } } break; } if (advance) { pStrBlock = pStrBlock->next; } } return changed; } int ShrinkMiniLines(minilines, pn_retry) MiniLinesInfo *minilines; int *pn_retry; { MiniLineInfo *pMiniLine=NULL; int changed=FALSE; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (ShrinkMiniLine(pMiniLine, pn_retry)) { changed = TRUE; } } return changed; } /* --------------------- GetTextXY() --------------------- */ static int GetTextXYInStrSeg(pStrSeg, index_to_match, pn_dx) StrSegInfo *pStrSeg; int index_to_match, *pn_dx; /* * *pn_x is the amount moved by this routine */ { curFont = pStrSeg->font; curSzUnit = pStrSeg->sz_unit; curStyle = pStrSeg->style; SetCanvasFont(); *pn_dx += MyTextWidth(canvasFontPtr, pStrSeg->dyn_str.s, index_to_match); return TRUE; } static int GetTextXYInStrBlock(pStrBlock, pStrBlockToMatch, index_to_match, pn_dx, pn_dy) StrBlockInfo *pStrBlock; StrBlockInfo *pStrBlockToMatch; int index_to_match, *pn_dx, *pn_dy; /* * *pn_x and *pn_y are the amount moved by this routine */ { int dx=0, dy=0; switch (pStrBlock->type) { case SB_SIMPLE: if (pStrBlockToMatch == pStrBlock) { return GetTextXYInStrSeg(pStrBlock->seg, index_to_match, pn_dx); } break; case SB_CHAR_SPACE: if (pStrBlockToMatch == pStrBlock) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "StrBlock has type of SB_CHAR_SPACE in GetTextXYInStrBlock()", NULL); #endif /* _TGIF_DBG */ if (index_to_match == 1) { *pn_dx += pStrBlock->special_char_w; } return TRUE; } break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: dx = dy = 0; if (pStrBlock->sup != NULL) { switch (pStrBlock->type) { case SB_SUPSUB_LEFT: dx += (-pStrBlock->w); break; case SB_SUPSUB_CENTER: dx += (-((pStrBlock->w)>>1)); break; case SB_SUPSUB_RIGHT: break; } dy += pStrBlock->sup->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { dy -= pStrBlock->seg->asc; } if (GetTextXYInMiniLines(pStrBlock->sup, pStrBlockToMatch, index_to_match, pn_dx, pn_dy)) { *pn_dx -= dx; *pn_dy += dy; return TRUE; } } dx = dy = 0; if (pStrBlock->sub != NULL) { switch (pStrBlock->type) { case SB_SUPSUB_LEFT: dx += (-pStrBlock->w); break; case SB_SUPSUB_CENTER: dx += (-((pStrBlock->w)>>1)); break; case SB_SUPSUB_RIGHT: break; } dy += pStrBlock->sub->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { dy += pStrBlock->seg->des; } if (GetTextXYInMiniLines(pStrBlock->sub, pStrBlockToMatch, index_to_match, pn_dx, pn_dy)) { *pn_dx -= dx; *pn_dy += dy; return TRUE; } } dx = dy = 0; if (pStrBlock->type == SB_SUPSUB_CENTER && pStrBlockToMatch == pStrBlock) { dx -= ((pStrBlock->w-pStrBlock->seg->w)>>1); if (GetTextXYInStrSeg(pStrBlock->seg, index_to_match, pn_dx)) { *pn_dx -= dx; *pn_dy += dy; return TRUE; } break; } break; } return FALSE; } static int GetTextXYInMiniLine(pMiniLine, pStrBlockToMatch, index_to_match, pn_dx, pn_dy) MiniLineInfo *pMiniLine; StrBlockInfo *pStrBlockToMatch; int index_to_match, *pn_dx, *pn_dy; /* * *pn_x and *pn_y are the amount moved by this routine */ { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { int w=pStrBlock->w; if (GetTextXYInStrBlock(pStrBlock, pStrBlockToMatch, index_to_match, pn_dx, pn_dy)) { return TRUE; } *pn_dx += w; } return FALSE; } int GetTextXYInMiniLines(minilines, pStrBlockToMatch, index_to_match, pn_dx, pn_dy) MiniLinesInfo *minilines; StrBlockInfo *pStrBlockToMatch; int index_to_match, *pn_dx, *pn_dy; /* * *pn_x and *pn_y are the amount moved by this routine */ { MiniLineInfo *pMiniLine=NULL; int v_space=minilines->v_space; int dx=0, dy=0; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { int saved_dx=(*pn_dx), saved_dy=(*pn_dy); #ifdef _TGIF_DBG /* debug, do not translate */ if (pMiniLine == minilines->first) { TgAssert(pMiniLine->v_gap == 0, "First mini_line has non-zero v_gap in GetTextXYInMiniLines()", NULL); } #endif /* _TGIF_DBG */ dy += pMiniLine->v_gap; switch (minilines->just) { case JUST_L: break; case JUST_C: dx += ((pMiniLine->w)>>1); break; case JUST_R: dx += pMiniLine->w; break; } if (GetTextXYInMiniLine(pMiniLine, pStrBlockToMatch, index_to_match, pn_dx, pn_dy)) { *pn_dx -= dx; *pn_dy += dy; return TRUE; } *pn_dx = saved_dx; *pn_dy = saved_dy; switch (minilines->just) { case JUST_L: break; case JUST_C: dx -= ((pMiniLine->w)>>1); break; case JUST_R: dx -= pMiniLine->w; break; } dy += pMiniLine->des + v_space; if (pMiniLine->next != NULL) { dy += pMiniLine->next->asc; } } return FALSE; } void GetTextXY(pStrBlock, nIndex, pn_x, pn_baseline_y) StrBlockInfo *pStrBlock; int nIndex, *pn_x, *pn_baseline_y; { int dx=0, dy=0; struct TextRec *text_ptr=curTextObj->detail.t; PushCurFont(); GetTextXYInMiniLines(&text_ptr->minilines, pStrBlock, nIndex, &dx, &dy); PopCurFont(); if (pn_x != NULL) { *pn_x = textOrigX + dx; } if (pn_baseline_y != NULL) { *pn_baseline_y = textOrigBaselineY + dy; } } /* --------------------- SetTextCurXY() --------------------- */ void SetTextCurXY() /* set textCurX & textCurBaselineY according to curStrBlock & textCurIndex */ { GetTextXY(curStrBlock, textCurIndex, &textCurX, &textCurBaselineY); } /* --------------------- SetTextEndXY() --------------------- */ void SetTextEndXY() /* set textEndX & textEndBaselineY according to endStrBlock & textEndIndex */ { GetTextXY(endStrBlock, textEndIndex, &textEndX, &textEndBaselineY); } /* --------------------- CurStrBlockInMiniLines() --------------------- */ int CurStrBlockInStrBlock(pStrBlock) StrBlockInfo *pStrBlock; { switch (pStrBlock->type) { case SB_SIMPLE: if (curStrBlock == pStrBlock) { return TRUE; } break; case SB_CHAR_SPACE: if (curStrBlock == pStrBlock) { for (pStrBlock=pStrBlock->prev; pStrBlock != NULL; pStrBlock=pStrBlock->prev) { if (pStrBlock->type == SB_SIMPLE) { curStrBlock = pStrBlock; textCurIndex = pStrBlock->seg->dyn_str.sz-1; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "curStrBlock->type is SB_CHAR_SPACE in CurStrBlockInStrBlock()", "Fixed by returning to end of the previous SB_SIMPLE block"); #endif /* _TGIF_DBG */ return TRUE; } } #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "curStrBlock->type is SB_CHAR_SPACE in CurStrBlockInStrBlock()", "Don't know how to fix this one"); #endif /* _TGIF_DBG */ return FALSE; } break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) { if (CurStrBlockInMiniLines(pStrBlock->sup)) { return TRUE; } } if (pStrBlock->sub != NULL) { if (CurStrBlockInMiniLines(pStrBlock->sub)) { return TRUE; } } if (pStrBlock->type == SB_SUPSUB_CENTER && curStrBlock == pStrBlock) { return TRUE; } break; } return FALSE; } int CurStrBlockInMiniLine(pMiniLine) MiniLineInfo *pMiniLine; { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (CurStrBlockInStrBlock(pStrBlock)) { return TRUE; } } return FALSE; } int CurStrBlockInMiniLines(minilines) MiniLinesInfo *minilines; { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (CurStrBlockInMiniLine(pMiniLine)) { return TRUE; } } return FALSE; } /* --------------------- GetCursorPositionInMiniLines() --------------------- */ static void GetCursorPositionInStrSeg(pStrSeg, dx, pn_dx, ppStrBlock, pnIndex) StrSegInfo *pStrSeg; int dx, *pn_dx, *pnIndex; StrBlockInfo **ppStrBlock; /* * dx is relative to the left side of the string segment * dy is relative to the baseline of the string segment * *pn_x is the amount moved by this routine */ { char *psz=NULL; int inc=0, index=0; curFont = pStrSeg->font; curSzUnit = pStrSeg->sz_unit; curStyle = pStrSeg->style; SetCanvasFont(); inc = (canvasFontDoubleByte ? 2 : 1); for (psz=pStrSeg->dyn_str.s; *psz != '\0'; psz=(&psz[inc]), index+=inc) { int w=MyTextWidth(canvasFontPtr, psz, inc); if (dx < (w>>1)) { break; } dx -= w; *pn_dx += w; } *pnIndex = index; } static void GetCursorPositionInStrBlock(pStrBlock, dx, dy, pn_dx, pn_dy, ppStrBlock, pnIndex) StrBlockInfo *pStrBlock; int dx, dy, *pn_dx, *pn_dy, *pnIndex; StrBlockInfo **ppStrBlock; /* * dx is relative to the left side of the string block * dy is relative to the baseline of the string block * *pn_x and *pn_y are the amount moved by this routine */ { int which=USE_SEG, saved_dx=dx, saved_dy=dy; switch (pStrBlock->type) { case SB_SIMPLE: GetCursorPositionInStrSeg(pStrBlock->seg, dx, pn_dx, ppStrBlock, pnIndex); *ppStrBlock = pStrBlock; break; case SB_CHAR_SPACE: #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "StrBlock has type SB_CHAR_SPACE in GetCursorPositionInStrBlock()", NULL); #endif /* _TGIF_DBG */ *ppStrBlock = pStrBlock; *pn_dx += pStrBlock->special_char_w; break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->type == SB_SUPSUB_CENTER) { which = USE_SUB; if (pStrBlock->sup != NULL) { if (dy < (-pStrBlock->seg->asc)+pStrBlock->sup->baseline_offset- pStrBlock->sup->first->asc+pStrBlock->sup->h) { which = USE_SUP; } } if (which == USE_SUB) { if (dy < pStrBlock->seg->des) { which = USE_SEG; } } } else { if (pStrBlock->sup != NULL && pStrBlock->sub != NULL) { int y=0, half_h=0; y = dy+pStrBlock->asc; half_h = ((pStrBlock->asc+pStrBlock->des)>>1); if (y < half_h) { which = USE_SUP; } else { which = USE_SUB; } } else if (pStrBlock->sup != NULL) { which = USE_SUP; } else { which = USE_SUB; } } switch (pStrBlock->type) { case SB_SUPSUB_LEFT: dx += (-pStrBlock->w); break; case SB_SUPSUB_CENTER: dx += (-((pStrBlock->w)>>1)); break; case SB_SUPSUB_RIGHT: break; } switch (which) { case USE_SUP: dy += pStrBlock->sup->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { dy -= pStrBlock->seg->asc; } GetCursorPositionInMiniLines(pStrBlock->sup, dx, dy, pn_dx, pn_dy, ppStrBlock, pnIndex); break; case USE_SUB: dy += pStrBlock->sub->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { dy += pStrBlock->seg->des; } GetCursorPositionInMiniLines(pStrBlock->sub, dx, dy, pn_dx, pn_dy, ppStrBlock, pnIndex); break; case USE_SEG: dx += ((pStrBlock->seg->w)>>1); GetCursorPositionInStrSeg(pStrBlock->seg, dx, pn_dx, ppStrBlock, pnIndex); *ppStrBlock = pStrBlock; break; } *pn_dx += saved_dx - dx; *pn_dy += dy - saved_dy; break; } } static void GetCursorPositionInMiniLine(pMiniLine, dx, dy, pn_dx, pn_dy, ppStrBlock, pnIndex) MiniLineInfo *pMiniLine; int dx, dy, *pn_dx, *pn_dy, *pnIndex; StrBlockInfo **ppStrBlock; /* * dx is relative to the left side of the miniline * dy is relative to the baseline of the miniline * *pn_x and *pn_y are the amount moved by this routine */ { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { int w=pStrBlock->w; if (pStrBlock->type != SB_CHAR_SPACE && (pStrBlock->next == NULL || dx < w)) { GetCursorPositionInStrBlock(pStrBlock, dx, dy, pn_dx, pn_dy, ppStrBlock, pnIndex); return; } dx -= w; *pn_dx += w; } } int GetCursorPositionInMiniLines(minilines, dx, dy, pn_dx, pn_dy, ppStrBlock, pnIndex) MiniLinesInfo *minilines; int dx, dy, *pn_dx, *pn_dy, *pnIndex; StrBlockInfo **ppStrBlock; /* * returns 0 if *pn_dx and *pn_dy are set * returns 1 if the caller needs to figure out where the end is * dx is relative to the origin of the miniline * dy is relative to the baseline of the miniline * *pn_x and *pn_y are the amount moved by this routine */ { MiniLineInfo *pMiniLine=NULL; int v_space=minilines->v_space; int saved_dx=dx, saved_dy=dy; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { #ifdef _TGIF_DBG /* debug, do not translate */ if (pMiniLine == minilines->first) { TgAssert(pMiniLine->v_gap == 0, "First mini_line has non-zero v_gap in GetCursorPositionInMiniLines()", NULL); } #endif /* _TGIF_DBG */ dy -= pMiniLine->v_gap; if ((pMiniLine->next == NULL && minilines->owner_block != NULL) || dy < pMiniLine->des+minilines->v_space) { switch (minilines->just) { case JUST_L: break; case JUST_C: dx += ((pMiniLine->w)>>1); break; case JUST_R: dx += pMiniLine->w; break; } GetCursorPositionInMiniLine(pMiniLine, dx, dy, pn_dx, pn_dy, ppStrBlock, pnIndex); *pn_dx += saved_dx - dx; *pn_dy += saved_dy - dy; return 0; } dy -= pMiniLine->des + v_space; if (pMiniLine->next != NULL) { dy -= pMiniLine->next->asc; } } #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(minilines->owner_block == NULL, "Invalid position reached in GetCursorPositionInMiniLines()", NULL); #endif /* _TGIF_DBG */ return 1; } /* --------------------- SameProperty() --------------------- */ int SameProperty(lWhich, nValue, pStrSeg, nCheckDoubleByte) long lWhich; int nValue, nCheckDoubleByte; StrSegInfo *pStrSeg; /* * If lWhich is PROP_MASK_TEXT_FONT and nCheckDoubleByte is TRUE, if * pStrSeg->double_byte != IsFontDoubleByte(nValue), this function * should return TRUE because the font cannot be changed. */ { switch (lWhich) { case PROP_MASK_COLOR: return (pStrSeg->color == nValue); case PROP_MASK_TEXT_FONT: if (pStrSeg->font == nValue) return TRUE; return (nCheckDoubleByte && (pStrSeg->double_byte != IsFontDoubleByte(nValue))); case PROP_MASK_TEXT_STYLE: return (pStrSeg->style == nValue); case PROP_MASK_TEXT_SZ_UNIT: return (pStrSeg->sz_unit == nValue); case PROP_MASK_UNDERLINE_ON: return (pStrSeg->underline_on == nValue); case PROP_MASK_OVERLINE_ON: return (pStrSeg->overline_on == nValue); } return FALSE; } /* --------------------- SetMiniLinesProperty() --------------------- */ int SetStrSegProperty(lWhich, nValue, pStrSeg) long lWhich; int nValue; StrSegInfo *pStrSeg; { int changed=FALSE, got_requested_size=TRUE; PushCurFont(); switch (lWhich) { case PROP_MASK_COLOR: if (pStrSeg->color != nValue) { pStrSeg->color = nValue; UtilStrCpyN(pStrSeg->color_str, sizeof(pStrSeg->color_str), colorMenuItems[pStrSeg->color]); changed = TRUE; } break; case PROP_MASK_TEXT_FONT: if (pStrSeg->font != nValue && pStrSeg->double_byte == IsFontDoubleByte(nValue)) { if (TrySetCanvasFont(nValue, pStrSeg->style, SzUnitToFontSize(pStrSeg->sz_unit), FALSE, &got_requested_size)) { pStrSeg->font = nValue; if (pStrSeg->double_byte) { pStrSeg->double_byte_vertical = canvasFontDoubleByteVertical; pStrSeg->double_byte_mod_bytes = canvasFontDoubleByteModBytes; } else { pStrSeg->double_byte_vertical = FALSE; pStrSeg->double_byte_mod_bytes = FALSE; } if (!got_requested_size) { pStrSeg->sz_unit = FontSizeToSzUnit(canvasFontSize); } changed = TRUE; } } break; case PROP_MASK_TEXT_STYLE: if (pStrSeg->style != nValue) { if (TrySetCanvasFont(pStrSeg->font, nValue, SzUnitToFontSize(pStrSeg->sz_unit), FALSE, &got_requested_size)) { pStrSeg->style = nValue; if (!got_requested_size) { pStrSeg->sz_unit = FontSizeToSzUnit(canvasFontSize); } changed = TRUE; } } break; case PROP_MASK_TEXT_SZ_UNIT: if (pStrSeg->sz_unit != nValue) { if (TrySetCanvasFont(pStrSeg->font, pStrSeg->style, SzUnitToFontSize(nValue), TRUE, &got_requested_size) && got_requested_size) { pStrSeg->sz_unit = nValue; changed = TRUE; } } break; case PROP_MASK_UNDERLINE_ON: if (pStrSeg->underline_on != nValue) { pStrSeg->underline_on = nValue; changed = TRUE; } break; case PROP_MASK_OVERLINE_ON: if (pStrSeg->overline_on != nValue) { pStrSeg->overline_on = nValue; changed = TRUE; } break; } PopCurFont(); return changed; } static int SetStrBlockProperty(lWhich, nValue, pStrBlock) long lWhich; int nValue; StrBlockInfo *pStrBlock; { int changed=FALSE; switch (pStrBlock->type) { case SB_SIMPLE: changed = SetStrSegProperty(lWhich, nValue, pStrBlock->seg); break; case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) { if (SetMiniLinesProperty(lWhich, nValue, pStrBlock->sup)) { changed = TRUE; } } if (pStrBlock->sub != NULL) { if (SetMiniLinesProperty(lWhich, nValue, pStrBlock->sub)) { changed = TRUE; } } if (pStrBlock->type == SB_SUPSUB_CENTER) { if (SetStrSegProperty(lWhich, nValue, pStrBlock->seg)) { changed = TRUE; } } break; } return changed; } static int SetMiniLineProperty(lWhich, nValue, pMiniLine) long lWhich; int nValue; MiniLineInfo *pMiniLine; { StrBlockInfo *pStrBlock=NULL; int changed=FALSE; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (SetStrBlockProperty(lWhich, nValue, pStrBlock)) { changed = TRUE; } } return changed; } int SetMiniLinesProperty(lWhich, nValue, minilines) long lWhich; int nValue; MiniLinesInfo *minilines; { MiniLineInfo *pMiniLine=NULL; int changed=FALSE; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (SetMiniLineProperty(lWhich, nValue, pMiniLine)) { changed = TRUE; } } return changed; } /* -------------------- ChangeHighlightedTextProperty() -------------------- */ static int ChangeStrSegPropertyForTail(pStrBlock, first_index, lWhich, nValue) StrBlockInfo *pStrBlock; int first_index, nValue; long lWhich; /* return TRUE anything is changed */ { StrSegInfo *pStrSeg=pStrBlock->seg; StrBlockInfo *pNewStrBlock=NULL; MiniLineInfo *owner_mini_line=pStrBlock->owner_mini_line; int changed=FALSE; DupStrBlock(pStrBlock, owner_mini_line, &pNewStrBlock, &pNewStrBlock); DynStrSet(&pNewStrBlock->seg->dyn_str, &pStrSeg->dyn_str.s[first_index]); pStrSeg->dyn_str.s[first_index] = '\0'; DynStrSet(&pStrSeg->dyn_str, pStrSeg->dyn_str.s); if (!SetStrSegProperty(lWhich, nValue, pNewStrBlock->seg)) { /* * don't call UnlinkStrBlock() because DupStrBlock() does not * insert pNewStrBlock into owner_mini_line */ FreeStrBlock(pNewStrBlock); } else { /* insert after */ pNewStrBlock->next = pStrBlock->next; if (pStrBlock->next == NULL) { owner_mini_line->last_block = pNewStrBlock; } else { pStrBlock->next->prev = pNewStrBlock; } pNewStrBlock->prev = pStrBlock; pStrBlock->next = pNewStrBlock; changed = TRUE; } if (changed) { if (pStrBlock == gstTextHighlightInfo.start_str_block_ptr) { if (curStrBlock == endStrBlock) { if (textCurIndex == first_index) { curStrBlock = endStrBlock = pNewStrBlock; textCurIndex = 0; textEndIndex = endStrBlock->seg->dyn_str.sz-1; } else { endStrBlock = curStrBlock = pNewStrBlock; textEndIndex = 0; textCurIndex = endStrBlock->seg->dyn_str.sz-1; } } else if (pStrBlock == curStrBlock) { curStrBlock = pNewStrBlock; textCurIndex = 0; } else { endStrBlock = pNewStrBlock; textEndIndex = 0; } } } return changed; } static int ChangeStrSegPropertyForHead(pStrBlock, first_index, lWhich, nValue) StrBlockInfo *pStrBlock; int first_index, nValue; long lWhich; /* return TRUE anything is changed */ { StrSegInfo *pStrSeg=pStrBlock->seg; StrBlockInfo *pNewStrBlock=NULL; MiniLineInfo *owner_mini_line=pStrBlock->owner_mini_line; char saved_ch=pStrSeg->dyn_str.s[first_index]; int changed=FALSE; pStrSeg->dyn_str.s[first_index] = '\0'; DupStrBlock(pStrBlock, owner_mini_line, &pNewStrBlock, &pNewStrBlock); DynStrSet(&pNewStrBlock->seg->dyn_str, pStrSeg->dyn_str.s); pStrSeg->dyn_str.s[first_index] = saved_ch; DynStrSet(&pStrSeg->dyn_str, &pStrSeg->dyn_str.s[first_index]); if (!SetStrSegProperty(lWhich, nValue, pNewStrBlock->seg)) { /* * don't call UnlinkStrBlock() because DupStrBlock() does not * insert pNewStrBlock into owner_mini_line */ FreeStrBlock(pNewStrBlock); } else { /* insert before */ pNewStrBlock->prev = pStrBlock->prev; if (pStrBlock->prev == NULL) { owner_mini_line->first_block = pNewStrBlock; } else { pStrBlock->prev->next = pNewStrBlock; } pNewStrBlock->next = pStrBlock; pStrBlock->prev = pNewStrBlock; changed = TRUE; } if (changed) { if (pStrBlock == gstTextHighlightInfo.end_str_block_ptr) { if (curStrBlock == endStrBlock) { if (textCurIndex == first_index) { curStrBlock = endStrBlock = pNewStrBlock; textCurIndex = 0; textEndIndex = endStrBlock->seg->dyn_str.sz-1; } else { endStrBlock = curStrBlock = pNewStrBlock; textEndIndex = 0; textCurIndex = endStrBlock->seg->dyn_str.sz-1; } } else if (pStrBlock == curStrBlock) { textCurIndex = 0; } else { textEndIndex = 0; } } } return changed; } static int ChangeStrSegPropertyForMiddle(pStrBlock, first_index, second_index, lWhich, nValue) StrBlockInfo *pStrBlock; int first_index, second_index, nValue; long lWhich; /* return TRUE anything is changed */ { StrSegInfo *pStrSeg=pStrBlock->seg; StrBlockInfo *pNewStrBlock=NULL; MiniLineInfo *owner_mini_line=pStrBlock->owner_mini_line; int changed=FALSE; DupStrBlock(pStrBlock, owner_mini_line, &pNewStrBlock, &pNewStrBlock); if (!SetStrSegProperty(lWhich, nValue, pNewStrBlock->seg)) { /* * don't call UnlinkStrBlock() because DupStrBlock() does not * insert pNewStrBlock into owner_mini_line */ FreeStrBlock(pNewStrBlock); } else { /* split */ StrBlockInfo *pLeftStrBlock=NULL; char *psz=NULL, *psz1=NULL, *psz2=NULL, saved_ch='\0'; DupStrBlock(pStrBlock, owner_mini_line, &pLeftStrBlock, &pLeftStrBlock); if ((psz=UtilStrDup(pStrSeg->dyn_str.s)) == NULL) { FailAllocMessage(); } saved_ch = psz[first_index]; psz[first_index] = '\0'; DynStrSet(&pLeftStrBlock->seg->dyn_str, psz); psz[first_index] = saved_ch; DynStrSet(&pStrBlock->seg->dyn_str, &psz[second_index]); psz[second_index] = '\0'; for (psz1=psz, psz2=(&psz[first_index]); *psz2 != '\0'; ) { *psz1++ = *psz2++; } *psz1 = '\0'; DynStrSet(&pNewStrBlock->seg->dyn_str, psz); UtilFree(psz); pLeftStrBlock->prev = pStrBlock->prev; if (pStrBlock->prev == NULL) { owner_mini_line->first_block = pLeftStrBlock; } else { pStrBlock->prev->next = pLeftStrBlock; } pLeftStrBlock->next = pNewStrBlock; pNewStrBlock->prev = pLeftStrBlock; pNewStrBlock->next = pStrBlock; pStrBlock->prev = pNewStrBlock; changed = TRUE; } if (changed) { if (pStrBlock == gstTextHighlightInfo.end_str_block_ptr) { if (curStrBlock == endStrBlock) { if (textCurIndex == first_index) { curStrBlock = endStrBlock = pNewStrBlock; textCurIndex = 0; textEndIndex = endStrBlock->seg->dyn_str.sz-1; } else { endStrBlock = curStrBlock = pNewStrBlock; textEndIndex = 0; textCurIndex = endStrBlock->seg->dyn_str.sz-1; } } } } return changed; } static int ChangePropertyForHighlightedTextInStrSeg(pStrBlock, mode, first_index, second_index, lWhich, nValue) StrBlockInfo *pStrBlock; int mode, first_index, second_index, nValue; long lWhich; /* return TRUE anything is changed */ { StrSegInfo *pStrSeg=pStrBlock->seg; int changed=FALSE; switch (mode) { case PAINT_NORM: break; case PAINT_INV: /* can only get here if pStrBlock->type is SB_SIMPLE */ changed = SetStrSegProperty(lWhich, nValue, pStrSeg); break; case PAINT_NORM_INV: /* change the tail */ if (SameProperty(lWhich, nValue, pStrSeg, TRUE)) { /* nothing need to change */ } else if (first_index == pStrSeg->dyn_str.sz-1) { /* nothing need to change */ } else { changed = ChangeStrSegPropertyForTail(pStrBlock, first_index, lWhich, nValue); } gstTextHighlightInfo.mode = PAINT_INV; break; case PAINT_INV_NORM: /* change the head */ if (SameProperty(lWhich, nValue, pStrSeg, TRUE)) { /* nothing need to change */ } else if (first_index == 0) { /* nothing need to change */ } else { changed = ChangeStrSegPropertyForHead(pStrBlock, first_index, lWhich, nValue); } gstTextHighlightInfo.mode = PAINT_NORM; break; case PAINT_NORM_INV_NORM: if (SameProperty(lWhich, nValue, pStrSeg, TRUE)) { /* nothing need to change */ } else if (first_index == 0 && second_index == pStrSeg->dyn_str.sz-1) { changed = SetStrSegProperty(lWhich, nValue, pStrSeg); } else if (first_index == 0) { /* just change the head */ changed = ChangeStrSegPropertyForHead(pStrBlock, second_index, lWhich, nValue); } else if (second_index == pStrSeg->dyn_str.sz-1) { /* just change the tail */ changed = ChangeStrSegPropertyForTail(pStrBlock, first_index, lWhich, nValue); } else { /* change the middle */ changed = ChangeStrSegPropertyForMiddle(pStrBlock, first_index, second_index, lWhich, nValue); } gstTextHighlightInfo.mode = PAINT_NORM; break; } return changed; } int ChangeHighlightedTextProperty(lWhich, nValue) long lWhich; int nValue; /* returns TRUE if anything is changed */ { MiniLineInfo *pOwnerMiniLine=NULL; StrBlockInfo *pStrBlock=NULL, *pNextStrBlock=NULL; int first_index=0, second_index=0, mode=PAINT_NORM; int changed=FALSE; /* setup gstTextHighlightInfo */ if (!UpdateTextHighlightInfo()) return FALSE; gstTextHighlightInfo.highlighting = FALSE; gstTextHighlightInfo.mode = PAINT_NORM; pStrBlock = gstTextHighlightInfo.start_str_block_ptr; pOwnerMiniLine = pStrBlock->owner_mini_line; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); if (ChangePropertyForHighlightedTextInStrSeg(pStrBlock, mode, first_index, second_index, lWhich, nValue)) { changed = TRUE; } mode = gstTextHighlightInfo.mode; pStrBlock = pStrBlock->next; while (mode != PAINT_NORM) { if (pStrBlock == NULL) { pOwnerMiniLine = pOwnerMiniLine->next; if (pOwnerMiniLine == NULL) { break; } pStrBlock = pOwnerMiniLine->first_block; continue; } pNextStrBlock = pStrBlock->next; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); if (mode == PAINT_INV) { if (SetStrBlockProperty(lWhich, nValue, pStrBlock)) { changed = TRUE; } } else { /* pStrBlock->type better be SB_SIMPLE */ #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pStrBlock->type == SB_SIMPLE, "pStrBlock->type != SB_SIMPLE in ChangeHighlightedTextProperty()", NULL); #endif /* _TGIF_DBG */ if (ChangePropertyForHighlightedTextInStrSeg(pStrBlock, mode, first_index, second_index, lWhich, nValue)) { changed = TRUE; } } mode = gstTextHighlightInfo.mode; pStrBlock = pNextStrBlock; } return changed; } /* --------------------- OnePropertyMiniLines() --------------------- */ static int OnePropertyStrBlock(lWhich, nValue, pStrBlock, nCheckDoubleByte) long lWhich; int nValue, nCheckDoubleByte; StrBlockInfo *pStrBlock; { switch (pStrBlock->type) { case SB_SIMPLE: return SameProperty(lWhich, nValue, pStrBlock->seg, nCheckDoubleByte); case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) { if (!OnePropertyMiniLines(lWhich, nValue, pStrBlock->sup, nCheckDoubleByte)) { return FALSE; } } if (pStrBlock->sub != NULL) { if (!OnePropertyMiniLines(lWhich, nValue, pStrBlock->sub, nCheckDoubleByte)) { return FALSE; } } if (pStrBlock->type == SB_SUPSUB_CENTER) { if (!SameProperty(lWhich, nValue, pStrBlock->seg, nCheckDoubleByte)) { return FALSE; } } break; } return TRUE; } static int OnePropertyMiniLine(lWhich, nValue, pMiniLine, nCheckDoubleByte) long lWhich; int nValue, nCheckDoubleByte; MiniLineInfo *pMiniLine; { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (!OnePropertyStrBlock(lWhich, nValue, pStrBlock, nCheckDoubleByte)) { return FALSE; } } return TRUE; } int OnePropertyMiniLines(lWhich, nValue, minilines, nCheckDoubleByte) long lWhich; int nValue, nCheckDoubleByte; MiniLinesInfo *minilines; { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (!OnePropertyMiniLine(lWhich, nValue, pMiniLine, nCheckDoubleByte)) { return FALSE; } } return TRUE; } /* --------------------- SingleFontText() --------------------- */ static int SingleFontStrSeg(pStrSeg, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn) StrSegInfo *pStrSeg; int *pnSzUnit, *pnDoubleByte, *pnFont, *pnStyle, *pnUnderlineOn; int *pnOverlineOn; { if (*pnDoubleByte == INVALID) { *pnSzUnit = pStrSeg->sz_unit; *pnDoubleByte = pStrSeg->double_byte; *pnFont = pStrSeg->font; *pnStyle = pStrSeg->style; *pnUnderlineOn = pStrSeg->underline_on; *pnOverlineOn = pStrSeg->overline_on; return TRUE; } return ((*pnSzUnit) == pStrSeg->sz_unit && (*pnDoubleByte) == pStrSeg->double_byte && (*pnFont) == pStrSeg->font && (*pnStyle) == pStrSeg->style && (*pnUnderlineOn) == pStrSeg->underline_on && (*pnOverlineOn) == pStrSeg->overline_on); } static int SingleFontStrBlock(pStrBlock, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn) StrBlockInfo *pStrBlock; int *pnSzUnit, *pnDoubleByte, *pnFont, *pnStyle, *pnUnderlineOn; int *pnOverlineOn; { switch (pStrBlock->type) { case SB_SIMPLE: return SingleFontStrSeg(pStrBlock->seg, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn); break; case SB_CHAR_SPACE: return TRUE; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL && !SingleFontMiniLines(pStrBlock->sup, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn)) { return FALSE; } if (pStrBlock->sub != NULL && !SingleFontMiniLines(pStrBlock->sub, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn)) { return FALSE; } if (pStrBlock->type == SB_SUPSUB_CENTER) { return SingleFontStrSeg(pStrBlock->seg, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn); } break; } return TRUE; } static int SingleFontMiniLine(pMiniLine, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn) MiniLineInfo *pMiniLine; int *pnSzUnit, *pnDoubleByte, *pnFont, *pnStyle, *pnUnderlineOn; int *pnOverlineOn; { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (!SingleFontStrBlock(pStrBlock, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn)) { return FALSE; } } return TRUE; } int SingleFontMiniLines(minilines, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn) MiniLinesInfo *minilines; int *pnSzUnit, *pnDoubleByte, *pnFont, *pnStyle, *pnUnderlineOn; int *pnOverlineOn; { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (!SingleFontMiniLine(pMiniLine, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn)) { return FALSE; } } return TRUE; } int SingleFontText(text_ptr, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn) struct TextRec *text_ptr; int *pnSzUnit, *pnDoubleByte, *pnFont, *pnStyle, *pnUnderlineOn; int *pnOverlineOn; { MiniLinesInfo *minilines=(&text_ptr->minilines); *pnDoubleByte = *pnFont = *pnStyle = INVALID; if (!SingleFontMiniLines(minilines, pnSzUnit, pnDoubleByte, pnFont, pnStyle, pnUnderlineOn, pnOverlineOn)) { return FALSE; } return ((*pnDoubleByte) != INVALID && (*pnFont) != INVALID && (*pnStyle) != INVALID); } /* --------------------- SingleColorText() --------------------- */ static int SingleColorStrSeg(pStrSeg, pnColorIndex) StrSegInfo *pStrSeg; int *pnColorIndex; { if (*pnColorIndex == INVALID) { *pnColorIndex = pStrSeg->color; return TRUE; } return ((*pnColorIndex) == pStrSeg->color); } static int SingleColorStrBlock(pStrBlock, pnColorIndex) StrBlockInfo *pStrBlock; int *pnColorIndex; { switch (pStrBlock->type) { case SB_SIMPLE: return SingleColorStrSeg(pStrBlock->seg, pnColorIndex); break; case SB_CHAR_SPACE: return TRUE; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL && !SingleColorMiniLines(pStrBlock->sup, pnColorIndex)) { return FALSE; } if (pStrBlock->sub != NULL && !SingleColorMiniLines(pStrBlock->sub, pnColorIndex)) { return FALSE; } if (pStrBlock->type == SB_SUPSUB_CENTER) { return SingleColorStrSeg(pStrBlock->seg, pnColorIndex); } break; } return TRUE; } static int SingleColorMiniLine(pMiniLine, pnColorIndex) MiniLineInfo *pMiniLine; int *pnColorIndex; { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (!SingleColorStrBlock(pStrBlock, pnColorIndex)) { return FALSE; } } return TRUE; } int SingleColorMiniLines(minilines, pnColorIndex) MiniLinesInfo *minilines; int *pnColorIndex; { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (!SingleColorMiniLine(pMiniLine, pnColorIndex)) { return FALSE; } } return TRUE; } int SingleColorText(text_ptr, pnColorIndex) struct TextRec *text_ptr; int *pnColorIndex; { MiniLinesInfo *minilines=(&text_ptr->minilines); *pnColorIndex = INVALID; if (!SingleColorMiniLines(minilines, pnColorIndex)) { return FALSE; } return ((*pnColorIndex) != INVALID); } /* -------------------- HighlightedTextHasSameProperty() -------------------- */ static int HighlightedStrSegHasSameProperty(pStrBlock, mode, lWhich, nValue, nCheckDoubleByte) StrBlockInfo *pStrBlock; int mode, nValue, nCheckDoubleByte; long lWhich; { StrSegInfo *pStrSeg=pStrBlock->seg; int rc=TRUE; if (mode == PAINT_NORM) return TRUE; rc = SameProperty(lWhich, nValue, pStrSeg, nCheckDoubleByte); switch (mode) { case PAINT_INV: break; case PAINT_NORM_INV: gstTextHighlightInfo.mode = PAINT_INV; break; case PAINT_INV_NORM: gstTextHighlightInfo.mode = PAINT_NORM; break; case PAINT_NORM_INV_NORM: gstTextHighlightInfo.mode = PAINT_NORM; break; } return rc; } int HighlightedTextHasSameProperty(lWhich, nValue, nCheckDoubleByte) long lWhich; int nValue, nCheckDoubleByte; /* returns TRUE if anything is changed */ { MiniLineInfo *pOwnerMiniLine=NULL; StrBlockInfo *pStrBlock=NULL, *pNextStrBlock=NULL; int first_index=0, second_index=0, mode=PAINT_NORM; /* setup gstTextHighlightInfo */ if (!UpdateTextHighlightInfo()) return FALSE; gstTextHighlightInfo.highlighting = FALSE; gstTextHighlightInfo.mode = PAINT_NORM; pStrBlock = gstTextHighlightInfo.start_str_block_ptr; pOwnerMiniLine = pStrBlock->owner_mini_line; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); if (!HighlightedStrSegHasSameProperty(pStrBlock, mode, lWhich, nValue, nCheckDoubleByte)) { return FALSE; } mode = gstTextHighlightInfo.mode; pStrBlock = pStrBlock->next; while (mode != PAINT_NORM) { if (pStrBlock == NULL) { pOwnerMiniLine = pOwnerMiniLine->next; if (pOwnerMiniLine == NULL) { break; } pStrBlock = pOwnerMiniLine->first_block; continue; } pNextStrBlock = pStrBlock->next; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); if (mode == PAINT_INV) { if (!OnePropertyStrBlock(lWhich, nValue, pStrBlock, nCheckDoubleByte)) { return FALSE; } } else { /* pStrBlock->type better be SB_SIMPLE */ #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pStrBlock->type == SB_SIMPLE, "pStrBlock->type != SB_SIMPLE in HighlightedTextHasSameProperty()", NULL); #endif /* _TGIF_DBG */ if (!HighlightedStrSegHasSameProperty(pStrBlock, mode, lWhich, nValue, nCheckDoubleByte)) { return FALSE; } } mode = gstTextHighlightInfo.mode; pStrBlock = pNextStrBlock; } return TRUE; } /* --------------------- CheckMiniLinesProperties() --------------------- */ static int CheckStrSegProperties(pStrSeg, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on) StrSegInfo *pStrSeg; int *pn_valid, *pn_font, *pn_style, *pn_sz_unit, *pn_color, *pn_underline_on; int *pn_overline_on; /* return FALSE if any property is different */ { if (*pn_valid) { return (*pn_font == pStrSeg->font && *pn_style == pStrSeg->style && *pn_sz_unit == pStrSeg->sz_unit && *pn_color == pStrSeg->color && *pn_underline_on == pStrSeg->underline_on && *pn_overline_on == pStrSeg->overline_on); } else { *pn_valid = TRUE; *pn_font = pStrSeg->font; *pn_style = pStrSeg->style; *pn_sz_unit = pStrSeg->sz_unit; *pn_color = pStrSeg->color; *pn_underline_on = pStrSeg->underline_on; *pn_overline_on = pStrSeg->overline_on; } return TRUE; } static int CheckStrBlockProperties(pStrBlock, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on) StrBlockInfo *pStrBlock; int *pn_valid, *pn_font, *pn_style, *pn_sz_unit, *pn_color, *pn_underline_on; int *pn_overline_on; /* return FALSE if any property is different */ { switch (pStrBlock->type) { case SB_SIMPLE: return CheckStrSegProperties(pStrBlock->seg, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on); case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) { if (!CheckMiniLinesProperties(pStrBlock->sup, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on)) { return FALSE; } } if (pStrBlock->sub != NULL) { if (!CheckMiniLinesProperties(pStrBlock->sub, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on)) { return FALSE; } } if (pStrBlock->type == SB_SUPSUB_CENTER) { if (!CheckStrSegProperties(pStrBlock->seg, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on)) { return FALSE; } } break; } return TRUE; } static int CheckMiniLineProperties(pMiniLine, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on) MiniLineInfo *pMiniLine; int *pn_valid, *pn_font, *pn_style, *pn_sz_unit, *pn_color, *pn_underline_on; int *pn_overline_on; /* return FALSE if any property is different */ { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (!CheckStrBlockProperties(pStrBlock, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on)) { return FALSE; } } return TRUE; } int CheckMiniLinesProperties(minilines, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on) MiniLinesInfo *minilines; int *pn_valid, *pn_font, *pn_style, *pn_sz_unit, *pn_color, *pn_underline_on; int *pn_overline_on; /* return FALSE if any property is different */ { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (!CheckMiniLineProperties(pMiniLine, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on)) { return FALSE; } } return TRUE; } /* ------------------- CanCopyHighLightedTextAsStrings() ------------------- */ static int CheckHighlightedStrSegProperties(pStrBlock, mode, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on) StrBlockInfo *pStrBlock; int mode, *pn_valid, *pn_font, *pn_style, *pn_sz_unit, *pn_color; int *pn_underline_on, *pn_overline_on; /* return FALSE if any property is different */ { StrSegInfo *pStrSeg=pStrBlock->seg; int rc=TRUE; if (mode == PAINT_NORM) return TRUE; rc = CheckStrSegProperties(pStrSeg, pn_valid, pn_font, pn_style, pn_sz_unit, pn_color, pn_underline_on, pn_overline_on); switch (mode) { case PAINT_INV: break; case PAINT_NORM_INV: gstTextHighlightInfo.mode = PAINT_INV; break; case PAINT_INV_NORM: gstTextHighlightInfo.mode = PAINT_NORM; break; case PAINT_NORM_INV_NORM: gstTextHighlightInfo.mode = PAINT_NORM; break; } return rc; } int CanCopyHighLightedTextAsStrings() /* returns TRUE if highlighted text is to be copied as simple text */ /* if the font is a double-byte font, don't treat it like a simple text */ { MiniLineInfo *pOwnerMiniLine=NULL; StrBlockInfo *pStrBlock=NULL, *pNextStrBlock=NULL; int first_index=0, second_index=0, mode=PAINT_NORM, valid=FALSE; int font=INVALID, style=INVALID, sz_unit=INVALID, color=INVALID; int underline_on=INVALID, overline_on=INVALID; /* setup gstTextHighlightInfo */ if (!UpdateTextHighlightInfo()) return FALSE; gstTextHighlightInfo.highlighting = FALSE; gstTextHighlightInfo.mode = PAINT_NORM; pStrBlock = gstTextHighlightInfo.start_str_block_ptr; pOwnerMiniLine = pStrBlock->owner_mini_line; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); if (!CheckHighlightedStrSegProperties(pStrBlock, mode, &valid, &font, &style, &sz_unit, &color, &underline_on, &overline_on)) { return FALSE; } if (valid && IsFontDoubleByte(font)) { return FALSE; } mode = gstTextHighlightInfo.mode; pStrBlock = pStrBlock->next; while (mode != PAINT_NORM) { if (pStrBlock == NULL) { pOwnerMiniLine = pOwnerMiniLine->next; if (pOwnerMiniLine == NULL) { break; } pStrBlock = pOwnerMiniLine->first_block; continue; } pNextStrBlock = pStrBlock->next; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); if (mode == PAINT_INV) { if (pStrBlock->type == SB_SIMPLE) { if (!CheckStrBlockProperties(pStrBlock, &valid, &font, &style, &sz_unit, &color, &underline_on, &overline_on)) { return FALSE; } if (valid && IsFontDoubleByte(font)) { return FALSE; } } else { return FALSE; } } else { /* pStrBlock->type better be SB_SIMPLE */ #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pStrBlock->type == SB_SIMPLE, "pStrBlock->type != SB_SIMPLE in CanCopyHighLightedTextAsStrings()", NULL); #endif /* _TGIF_DBG */ if (!CheckHighlightedStrSegProperties(pStrBlock, mode, &valid, &font, &style, &sz_unit, &color, &underline_on, &overline_on)) { return FALSE; } if (valid && IsFontDoubleByte(font)) { return FALSE; } } mode = gstTextHighlightInfo.mode; pStrBlock = pNextStrBlock; } return TRUE; } /* ----------------- CanCopyHighLightedTextAsUTF8Strings() ----------------- */ static void CheckHighlightedStrSegPropertiesForCopyHighLightedTextAsUTF8Strings(mode) int mode; { if (mode == PAINT_NORM) return; switch (mode) { case PAINT_INV: break; case PAINT_NORM_INV: gstTextHighlightInfo.mode = PAINT_INV; break; case PAINT_INV_NORM: gstTextHighlightInfo.mode = PAINT_NORM; break; case PAINT_NORM_INV_NORM: gstTextHighlightInfo.mode = PAINT_NORM; break; } } static int CheckDoubleByteFontForCopyHighLightedTextAsUTF8Strings(mode, pStrSeg, pn_double_byte_font, pn_valid) int mode, *pn_double_byte_font, *pn_valid; StrSegInfo *pStrSeg; { int font_index=pStrSeg->font; if (mode == PAINT_NORM) return TRUE; if (IsFontDoubleByte(font_index)) { if (CanConvertUTF8ToFont(font_index)) { if (*pn_valid) { if (*pn_double_byte_font != font_index) { return FALSE; } } else { *pn_double_byte_font = font_index; *pn_valid = TRUE; SetCopyUTF8FontInfo(pStrSeg, TRUE); } } else { return FALSE; } } else { if (!gstCopyUTF8Info.single_byte_valid) { SetCopyUTF8FontInfo(pStrSeg, FALSE); } } switch (mode) { case PAINT_INV: break; case PAINT_NORM_INV: gstTextHighlightInfo.mode = PAINT_INV; break; case PAINT_INV_NORM: gstTextHighlightInfo.mode = PAINT_NORM; break; case PAINT_NORM_INV_NORM: gstTextHighlightInfo.mode = PAINT_NORM; break; } return TRUE; } int CanCopyHighLightedTextAsUTF8Strings(pn_double_byte_font_index) int *pn_double_byte_font_index; /* returns TRUE if highlighted text is to be copied as simple text */ /* if the font is a double-byte font, don't treat it like a simple text */ { MiniLineInfo *pOwnerMiniLine=NULL; StrBlockInfo *pStrBlock=NULL, *pNextStrBlock=NULL; int first_index=0, second_index=0, mode=PAINT_NORM, valid=FALSE; int double_byte_font=INVALID; /* setup gstTextHighlightInfo */ if (!UpdateTextHighlightInfo()) return FALSE; ClearCopyUTF8Info(); gstTextHighlightInfo.highlighting = FALSE; gstTextHighlightInfo.mode = PAINT_NORM; pStrBlock = gstTextHighlightInfo.start_str_block_ptr; pOwnerMiniLine = pStrBlock->owner_mini_line; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); CheckHighlightedStrSegPropertiesForCopyHighLightedTextAsUTF8Strings(mode); if (IsFontDoubleByte(pStrBlock->seg->font)) { if (CanConvertUTF8ToFont(pStrBlock->seg->font)) { double_byte_font = pStrBlock->seg->font; valid = TRUE; SetCopyUTF8FontInfo(pStrBlock->seg, TRUE); } else { return FALSE; } } else { SetCopyUTF8FontInfo(pStrBlock->seg, FALSE); } mode = gstTextHighlightInfo.mode; pStrBlock = pStrBlock->next; while (mode != PAINT_NORM) { if (pStrBlock == NULL) { pOwnerMiniLine = pOwnerMiniLine->next; if (pOwnerMiniLine == NULL) { break; } pStrBlock = pOwnerMiniLine->first_block; continue; } pNextStrBlock = pStrBlock->next; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); if (mode == PAINT_INV) { if (pStrBlock->type == SB_SIMPLE) { if (!CheckDoubleByteFontForCopyHighLightedTextAsUTF8Strings( mode, pStrBlock->seg, &double_byte_font, &valid)) { return FALSE; } } else { return FALSE; } } else { /* pStrBlock->type better be SB_SIMPLE */ #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pStrBlock->type == SB_SIMPLE, "pStrBlock->type != SB_SIMPLE in CanCopyHighLightedTextAsUTF8Strings()", NULL); #endif /* _TGIF_DBG */ if (!CheckDoubleByteFontForCopyHighLightedTextAsUTF8Strings( mode, pStrBlock->seg, &double_byte_font, &valid)) { return FALSE; } } mode = gstTextHighlightInfo.mode; pStrBlock = pNextStrBlock; } if (valid && pn_double_byte_font_index != NULL) { *pn_double_byte_font_index = double_byte_font; } if (valid) { DebugCopyUTF8Info(); } return valid; } /* ----------------- CanPasteUTF8StringIntoText() ----------------- */ int CanPasteUTF8StringIntoText(pssi) StrSegInfo *pssi; /* returns TRUE if highlighted text is to be copied as simple text */ /* if the font is a double-byte font, don't treat it like a simple text */ { StrBlockInfo *pStrBlock=NULL; if (!textHighlight) { if (CanConvertUTF8ToFont(curFont)) { return TRUE; } if (CanFindDoubleByteFontAtCursor(pssi)) { return CanConvertUTF8ToFont(pssi->font); } return FALSE; } /* setup gstTextHighlightInfo */ if (!UpdateTextHighlightInfo()) return FALSE; if (FixHighlightedStrBlockDepths() < 0) { SwitchTextCurAndEndStrBlocks(); } pStrBlock = gstTextHighlightInfo.start_str_block_ptr; if (pStrBlock->seg->double_byte) { return TRUE; } if (CanFindDoubleByteFontAtCursor(pssi)) { return CanConvertUTF8ToFont(pssi->font); } return FALSE; } /* -------------------- GatherHighLightedTextAsStrings() -------------------- */ static void GatherString(buf, len, ppsz_buf, pn_buf_sz) char *buf, **ppsz_buf; int len, *pn_buf_sz; /* *pn_buf_sz includes the terminating '\0' */ { if (*ppsz_buf == NULL) { *ppsz_buf = (char*)malloc(len+1); if (*ppsz_buf == NULL) FailAllocMessage(); memcpy(*ppsz_buf, buf, len+1); *pn_buf_sz = len+1; } else { *ppsz_buf = (char*)realloc(*ppsz_buf, (*pn_buf_sz)+len); if (*ppsz_buf == NULL) FailAllocMessage(); memcpy(&(*ppsz_buf)[*pn_buf_sz-1], buf, len+1); *pn_buf_sz += len; } } static void GatherStrSeg(pStrSeg, ppsz_buf, pn_buf_sz) StrSegInfo *pStrSeg; char **ppsz_buf; int *pn_buf_sz; /* *pn_buf_sz includes the terminating '\0' */ { GatherString(pStrSeg->dyn_str.s, pStrSeg->dyn_str.sz-1, ppsz_buf, pn_buf_sz); } static void GatherHighlightedStrSeg(pStrBlock, mode, first_index, second_index, ppsz_buf, pn_buf_sz) StrBlockInfo *pStrBlock; int mode, first_index, second_index, *pn_buf_sz; char **ppsz_buf; { StrSegInfo *pStrSeg=pStrBlock->seg; char *buf=NULL, saved_ch='\0'; int len=0; if (mode == PAINT_NORM) return; switch (mode) { case PAINT_INV: /* can only get here if pStrBlock->type is SB_SIMPLE */ GatherStrSeg(pStrSeg, ppsz_buf, pn_buf_sz); break; case PAINT_NORM_INV: /* gathering the tail */ if (first_index == pStrSeg->dyn_str.sz-1) { /* nothing need to change */ } else { buf = (&pStrSeg->dyn_str.s[first_index]); len = pStrSeg->dyn_str.sz-1-first_index; GatherString(buf, len, ppsz_buf, pn_buf_sz); } gstTextHighlightInfo.mode = PAINT_INV; break; case PAINT_INV_NORM: /* gathering the head */ if (first_index == 0) { /* nothing need to change */ } else { buf = pStrSeg->dyn_str.s; saved_ch = buf[first_index]; buf[first_index] = '\0'; GatherString(buf, first_index, ppsz_buf, pn_buf_sz); buf[first_index] = saved_ch; } gstTextHighlightInfo.mode = PAINT_NORM; break; case PAINT_NORM_INV_NORM: if (first_index == 0 && second_index == pStrSeg->dyn_str.sz-1) { GatherStrSeg(pStrSeg, ppsz_buf, pn_buf_sz); } else if (first_index == 0) { /* just change the head */ buf = pStrSeg->dyn_str.s; saved_ch = buf[second_index]; buf[second_index] = '\0'; GatherString(buf, second_index, ppsz_buf, pn_buf_sz); buf[second_index] = saved_ch; } else if (second_index == pStrSeg->dyn_str.sz-1) { /* just change the tail */ buf = (&pStrSeg->dyn_str.s[first_index]); len = pStrSeg->dyn_str.sz-1-first_index; GatherString(buf, len, ppsz_buf, pn_buf_sz); } else { /* change the middle */ buf = pStrSeg->dyn_str.s; saved_ch = buf[second_index]; buf[second_index] = '\0'; GatherString(&buf[first_index], second_index-first_index, ppsz_buf, pn_buf_sz); buf[second_index] = saved_ch; } gstTextHighlightInfo.mode = PAINT_NORM; break; } } void GatherHighLightedTextAsStrings(ppsz_buf, pn_buf_sz) char **ppsz_buf; int *pn_buf_sz; /* *pn_buf_sz will include the terminating '\0' */ { MiniLineInfo *pOwnerMiniLine=NULL; StrBlockInfo *pStrBlock=NULL, *pNextStrBlock=NULL; int first_index=0, second_index=0, mode=PAINT_NORM; /* setup gstTextHighlightInfo */ if (!UpdateTextHighlightInfo()) return; gstTextHighlightInfo.highlighting = FALSE; gstTextHighlightInfo.mode = PAINT_NORM; pStrBlock = gstTextHighlightInfo.start_str_block_ptr; pOwnerMiniLine = pStrBlock->owner_mini_line; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); GatherHighlightedStrSeg(pStrBlock, mode, first_index, second_index, ppsz_buf, pn_buf_sz); mode = gstTextHighlightInfo.mode; pStrBlock = pStrBlock->next; while (mode != PAINT_NORM) { if (pStrBlock == NULL) { pOwnerMiniLine = pOwnerMiniLine->next; if (pOwnerMiniLine == NULL) { break; } pStrBlock = pOwnerMiniLine->first_block; GatherString("\n", 1, ppsz_buf, pn_buf_sz); continue; } pNextStrBlock = pStrBlock->next; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); /* pStrBlock->type better be SB_SIMPLE */ #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pStrBlock->type == SB_SIMPLE, "pStrBlock->type != SB_SIMPLE in GatherHighLightedTextAsStrings()", NULL); #endif /* _TGIF_DBG */ if (mode == PAINT_INV) { GatherStrSeg(pStrBlock->seg, ppsz_buf, pn_buf_sz); } else { GatherHighlightedStrSeg(pStrBlock, mode, first_index, second_index, ppsz_buf, pn_buf_sz); } mode = gstTextHighlightInfo.mode; pStrBlock = pNextStrBlock; } } /* ------------------- CreateTextObjFromHighLightedText() ------------------- */ static void CopyHighlightedStrSeg(pStrBlock, mode, first_index, second_index, pNewOwnerMiniLine) StrBlockInfo *pStrBlock; int mode, first_index, second_index; MiniLineInfo *pNewOwnerMiniLine; /* owner miniline of the new string block */ { StrSegInfo *pStrSeg=pStrBlock->seg; char *buf=NULL; int faked_simple_type=FALSE; if (pStrBlock->type == SB_SUPSUB_CENTER) { /* only coping the string segment */ faked_simple_type = TRUE; pStrBlock->type = SB_SIMPLE; } switch (mode) { case PAINT_NORM: break; case PAINT_INV: DupStrBlock(pStrBlock, pNewOwnerMiniLine, &pNewOwnerMiniLine->first_block, &pNewOwnerMiniLine->last_block); break; case PAINT_NORM_INV: /* copying the tail */ buf = (&pStrSeg->dyn_str.s[first_index]); DupStrBlock(pStrBlock, pNewOwnerMiniLine, &pNewOwnerMiniLine->first_block, &pNewOwnerMiniLine->last_block); DynStrSet(&pNewOwnerMiniLine->last_block->seg->dyn_str, buf); gstTextHighlightInfo.mode = PAINT_INV; break; case PAINT_INV_NORM: /* copying the head */ if (first_index == 0) { /* nothing to copy */ } else { char saved_ch='\0'; buf = pStrSeg->dyn_str.s; saved_ch = buf[first_index]; buf[first_index] = '\0'; DupStrBlock(pStrBlock, pNewOwnerMiniLine, &pNewOwnerMiniLine->first_block, &pNewOwnerMiniLine->last_block); DynStrSet(&pNewOwnerMiniLine->last_block->seg->dyn_str, buf); buf[first_index] = saved_ch; } gstTextHighlightInfo.mode = PAINT_NORM; break; case PAINT_NORM_INV_NORM: if (first_index == 0 && second_index == pStrSeg->dyn_str.sz-1) { DupStrBlock(pStrBlock, pNewOwnerMiniLine, &pNewOwnerMiniLine->first_block, &pNewOwnerMiniLine->last_block); } else if (first_index == 0) { /* just copy the head */ char saved_ch='\0'; buf = pStrSeg->dyn_str.s; saved_ch = buf[second_index]; buf[second_index] = '\0'; DupStrBlock(pStrBlock, pNewOwnerMiniLine, &pNewOwnerMiniLine->first_block, &pNewOwnerMiniLine->last_block); DynStrSet(&pNewOwnerMiniLine->last_block->seg->dyn_str, buf); buf[second_index] = saved_ch; } else if (second_index == pStrSeg->dyn_str.sz-1) { /* just copy the tail */ buf = (&pStrSeg->dyn_str.s[first_index]); DupStrBlock(pStrBlock, pNewOwnerMiniLine, &pNewOwnerMiniLine->first_block, &pNewOwnerMiniLine->last_block); DynStrSet(&pNewOwnerMiniLine->last_block->seg->dyn_str, buf); } else { /* change the middle */ char saved_ch='\0'; buf = pStrSeg->dyn_str.s; saved_ch = buf[second_index]; buf[second_index] = '\0'; DupStrBlock(pStrBlock, pNewOwnerMiniLine, &pNewOwnerMiniLine->first_block, &pNewOwnerMiniLine->last_block); DynStrSet(&pNewOwnerMiniLine->last_block->seg->dyn_str, &buf[first_index]); buf[second_index] = saved_ch; } gstTextHighlightInfo.mode = PAINT_NORM; break; } if (faked_simple_type) { pStrBlock->type = SB_SUPSUB_CENTER; } } struct ObjRec *CreateTextObjFromHighLightedText() { MiniLinesInfo *minilines=NULL; MiniLineInfo *pOwnerMiniLine=NULL, *pFirstMiniLine=NULL, *pLastMiniLine=NULL; StrBlockInfo *pStrBlock=NULL, *pNextStrBlock=NULL; int first_index=0, second_index=0, mode=PAINT_NORM, num_lines=1; struct ObjRec *partial_text_obj_ptr=NULL; struct TextRec *text_ptr=NULL; /* setup gstTextHighlightInfo */ if (!UpdateTextHighlightInfo()) return NULL; partial_text_obj_ptr = DupObj(curTextObj); if (partial_text_obj_ptr == NULL) return NULL; text_ptr = partial_text_obj_ptr->detail.t; minilines = (&text_ptr->minilines); FreeMiniLines(minilines, FALSE); InvalidateTextCache(text_ptr); pFirstMiniLine = pLastMiniLine = NewMiniLine(); pLastMiniLine->owner_minilines = minilines; gstTextHighlightInfo.highlighting = FALSE; gstTextHighlightInfo.mode = PAINT_NORM; pStrBlock = gstTextHighlightInfo.start_str_block_ptr; pOwnerMiniLine = pStrBlock->owner_mini_line; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); CopyHighlightedStrSeg(pStrBlock, mode, first_index, second_index, pLastMiniLine); mode = gstTextHighlightInfo.mode; pStrBlock = pStrBlock->next; while (mode != PAINT_NORM) { if (pStrBlock == NULL) { MiniLineInfo *pNewMiniLine=NULL; pOwnerMiniLine = pOwnerMiniLine->next; if (pOwnerMiniLine == NULL) { break; } pStrBlock = pOwnerMiniLine->first_block; pNewMiniLine = NewMiniLine(); pNewMiniLine->owner_minilines = minilines; num_lines++; InsertMiniLine(pLastMiniLine, NULL, pNewMiniLine, &pFirstMiniLine, &pLastMiniLine); continue; } pNextStrBlock = pStrBlock->next; GetPaintMode(pStrBlock, &mode, &first_index, &second_index); if (mode == PAINT_INV) { DupStrBlock(pStrBlock, pLastMiniLine, &pLastMiniLine->first_block, &pLastMiniLine->last_block); } else { /* pStrBlock->type better be SB_SIMPLE */ #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pStrBlock->type == SB_SIMPLE, "pStrBlock->type != SB_SIMPLE in CreateTextObjFromHighLightedText()", NULL); #endif /* _TGIF_DBG */ CopyHighlightedStrSeg(pStrBlock, mode, first_index, second_index, pLastMiniLine); } mode = gstTextHighlightInfo.mode; pStrBlock = pNextStrBlock; } minilines->first = pFirstMiniLine; minilines->last = pLastMiniLine; text_ptr->lines = num_lines; text_ptr->baseline_y = curTextObj->detail.t->baseline_y; RecalcTextMetrics(text_ptr, partial_text_obj_ptr->x, text_ptr->baseline_y); UpdTextBBox(partial_text_obj_ptr); return partial_text_obj_ptr; } /* --------------------- ReorderCursorStrBlocks() --------------------- */ void ReorderCursorStrBlocks() { /* setup gstTextHighlightInfo */ if (!UpdateTextHighlightInfo()) return; curStrBlock = gstTextHighlightInfo.start_str_block_ptr; textCurIndex = gstTextHighlightInfo.start_index; endStrBlock = gstTextHighlightInfo.end_str_block_ptr; textEndIndex = gstTextHighlightInfo.end_index; } /* --------------------- FindStringInMiniLines() --------------------- */ static int CaseDependentStrNCmp(buf1, buf2, str_len, case_sensitive) char *buf1, *buf2; int str_len, case_sensitive; { return (case_sensitive ? strncmp(buf1, buf2, str_len) : UtilStrNCaseCmp(buf1, buf2, str_len)); } static int MatchStringInOnlyThisStrBlock(pStrBlock, nIndex, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index) StrBlockInfo *pStrBlock; int nIndex, str_len_to_match, case_sensitive; char *str_to_match; StrBlockInfo **ppStartStrBlock, **ppEndStrBlock; int *pn_start_index, *pn_end_index; /* return TRUE if found */ { char *buf=(&pStrBlock->seg->dyn_str.s[nIndex]); int buf_len=pStrBlock->seg->dyn_str.sz-nIndex-1; int inc=(pStrBlock->seg->double_byte?2:1); for ( ; buf_len >= str_len_to_match; buf+=inc, buf_len-=inc) { if (CaseDependentStrNCmp(buf, str_to_match, str_len_to_match, case_sensitive) == 0) { /* match! */ *ppStartStrBlock = *ppEndStrBlock = pStrBlock; *pn_start_index = buf-pStrBlock->seg->dyn_str.s; *pn_end_index = (*pn_start_index)+str_len_to_match; return TRUE; } } return FALSE; } static int MatchStringFromCursor(pStrBlock, nIndex, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index) StrBlockInfo *pStrBlock; int nIndex, str_len_to_match, case_sensitive; char *str_to_match; StrBlockInfo **ppStartStrBlock, **ppEndStrBlock; int *pn_start_index, *pn_end_index; /* * return TRUE if found * * If *ppStartStrBlock is NULL, this means that we are still trying to * find a prefix match. * If *ppStartStrBlock is non-NULL, that means the prefix is found, so * we must match starting at the beginning of every string. */ { char *buf=NULL; int buf_len=0; if (pStrBlock == NULL || pStrBlock->type != SB_SIMPLE) { return FALSE; } buf = (&pStrBlock->seg->dyn_str.s[nIndex]); buf_len = pStrBlock->seg->dyn_str.sz-nIndex-1; if (*ppStartStrBlock == NULL) { /* still trying to find a prefix match */ int inc=(pStrBlock->seg->double_byte?2:1); if (buf_len >= str_len_to_match) { if (MatchStringInOnlyThisStrBlock(pStrBlock, nIndex, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index)) { return TRUE; } for ( ; buf_len >= str_len_to_match; buf+=inc, buf_len-=inc) { } } for ( ; buf_len > 0; buf+=inc, buf_len-=inc) { if (CaseDependentStrNCmp(buf, str_to_match, buf_len, case_sensitive) == 0) { /* got a prefix match */ *ppStartStrBlock = pStrBlock; *pn_start_index = buf-pStrBlock->seg->dyn_str.s; if (MatchStringFromCursor(pStrBlock->next, 0, &str_to_match[buf_len], str_len_to_match-buf_len, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index)) { return TRUE; } *ppStartStrBlock = NULL; *pn_start_index = INVALID; } } } else { /* the leading chars of buf much match str_to_match */ if (buf_len >= str_len_to_match) { if (CaseDependentStrNCmp(buf, str_to_match, str_len_to_match, case_sensitive) == 0) { /* match! */ *ppEndStrBlock = pStrBlock; *pn_end_index = buf-pStrBlock->seg->dyn_str.s+str_len_to_match; return TRUE; } } else { if (CaseDependentStrNCmp(buf, str_to_match, buf_len, case_sensitive) == 0) { if (MatchStringFromCursor(pStrBlock->next, nIndex, str_to_match, str_len_to_match-buf_len, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index)) { return TRUE; } } } } return FALSE; } static int FindStringInStrBlock(pStrBlock, pn_found_starting_point, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index) StrBlockInfo *pStrBlock; int *pn_found_starting_point, str_len_to_match, case_sensitive; char *str_to_match; StrBlockInfo **ppStartStrBlock, **ppEndStrBlock; int *pn_start_index, *pn_end_index; /* return TRUE if found */ { switch (pStrBlock->type) { case SB_SIMPLE: if (*pn_found_starting_point) { if (MatchStringFromCursor(pStrBlock, 0, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index)) { return TRUE; } } else if (pStrBlock == curStrBlock) { *pn_found_starting_point = TRUE; if (textCurIndex != pStrBlock->seg->dyn_str.sz-1 && MatchStringFromCursor(pStrBlock, textCurIndex+(textHighlight?1:0), str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index)) { return TRUE; } } else { /* still looking for curStrBlock */ } break; case SB_CHAR_SPACE: return FALSE; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) { if (FindStringInMiniLines(pStrBlock->sup, pn_found_starting_point, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index)) { return TRUE; } } if (pStrBlock->type == SB_SUPSUB_CENTER) { if (*pn_found_starting_point) { if (MatchStringInOnlyThisStrBlock(pStrBlock, 0, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index)) { return TRUE; } } else if (pStrBlock == curStrBlock) { *pn_found_starting_point = TRUE; if (textCurIndex != pStrBlock->seg->dyn_str.sz-1 && MatchStringInOnlyThisStrBlock(pStrBlock, textCurIndex+(textHighlight?1:0), str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index)) { return TRUE; } } else { /* still looking for curStrBlock */ } } if (pStrBlock->sub != NULL) { if (FindStringInMiniLines(pStrBlock->sub, pn_found_starting_point, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index)) { return TRUE; } } break; } return FALSE; } static int FindStringInMiniLine(pMiniLine, pn_found_starting_point, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index) MiniLineInfo *pMiniLine; int *pn_found_starting_point, str_len_to_match, case_sensitive; char *str_to_match; StrBlockInfo **ppStartStrBlock, **ppEndStrBlock; int *pn_start_index, *pn_end_index; /* return TRUE if found */ { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (FindStringInStrBlock(pStrBlock, pn_found_starting_point, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index)) { return TRUE; } } return FALSE; } int FindStringInMiniLines(minilines, pn_found_starting_point, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index) MiniLinesInfo *minilines; int *pn_found_starting_point, str_len_to_match, case_sensitive; char *str_to_match; StrBlockInfo **ppStartStrBlock, **ppEndStrBlock; int *pn_start_index, *pn_end_index; /* return TRUE if found */ { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (FindStringInMiniLine(pMiniLine, pn_found_starting_point, str_to_match, str_len_to_match, case_sensitive, ppStartStrBlock, pn_start_index, ppEndStrBlock, pn_end_index)) { return TRUE; } } return FALSE; } /* --------------------- CanBreakMiniLinesIntoWords() --------------------- */ static int CanBreakStrSegIntoWords(pStrSeg) StrSegInfo *pStrSeg; { return (strchr(pStrSeg->dyn_str.s, ' ') != NULL); } static int CanBreakStrBlockIntoWords(pStrBlock) StrBlockInfo *pStrBlock; { switch (pStrBlock->type) { case SB_SIMPLE: return CanBreakStrSegIntoWords(pStrBlock->seg); case SB_CHAR_SPACE: return TRUE; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) { if (!BlankMiniLines(pStrBlock->sup)) { return TRUE; } } if (pStrBlock->sub != NULL) { if (!BlankMiniLines(pStrBlock->sub)) { return TRUE; } } if (pStrBlock->type == SB_SUPSUB_CENTER) { /* pStrBlock->seg better not be NULL or it will crash */ if (CanBreakStrSegIntoWords(pStrBlock->seg)) { return TRUE; } } break; } return FALSE; } static int CanBreakMiniLineIntoWords(pMiniLine) MiniLineInfo *pMiniLine; { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (pStrBlock->next != NULL) { return TRUE; } if (CanBreakStrBlockIntoWords(pStrBlock)) { return TRUE; } } return FALSE; } int CanBreakMiniLinesIntoWords(minilines) MiniLinesInfo *minilines; { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (pMiniLine->next != NULL) { return TRUE; } if (CanBreakMiniLineIntoWords(pMiniLine)) { return TRUE; } } return FALSE; } /* --------------------- BreakMiniLines() --------------------- */ static void FinalizeBreakStrSeg(new_obj, x, baseline_y, prototype, tx_to_move, ty_to_move, poli) struct ObjRec *new_obj; int x, baseline_y; struct ObjRec *prototype; int tx_to_move, ty_to_move; ObjListInfo *poli; { struct SelRec *new_sel_ptr=NULL; struct TextRec *text_ptr=new_obj->detail.t; MiniLinesInfo *minilines=(&text_ptr->minilines); int x_pos=x, y_pos=0, w=0, dx=0, dy=0; minilines->first->v_gap = 0; new_obj->x = x; text_ptr->baseline_y = baseline_y; UpdTextBBox(new_obj); y_pos = new_obj->y; dx = dy = 0; w = minilines->w; switch (minilines->just) { case JUST_L: break; case JUST_C: dx = (w>>1); break; case JUST_R: dx = w; break; } if (new_obj->ctm != NULL) { int new_x=0, new_y=0; TransformPointThroughCTM(x_pos+dx-prototype->x, y_pos+dy-prototype->y, prototype->ctm, &new_x, &new_y); new_x += prototype->x; new_y += prototype->y; free(new_obj->ctm); new_obj->ctm = NULL; UpdTextBBox(new_obj); SetCTM(new_obj, prototype->ctm); MoveObj(new_obj, new_x-new_obj->x-tx_to_move, new_y-new_obj->y-ty_to_move); } else { MoveObj(new_obj, dx, dy); } new_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (new_sel_ptr == NULL) FailAllocMessage(); new_sel_ptr->obj = new_obj; new_sel_ptr->next = poli->top_sel; new_obj->next = poli->top_obj; if (poli->top_sel == NULL) { poli->bot_sel = new_sel_ptr; poli->bot_obj = new_obj; } else { poli->top_sel->prev = new_sel_ptr; poli->top_obj->prev = new_obj; } poli->top_sel = new_sel_ptr; poli->top_obj = new_obj; poli->top_sel->prev = NULL; poli->top_obj->prev = NULL; poli->count++; } static void BreakStrSeg(pSrcStrSeg, into_words, x, baseline_y, prototype, tx_to_move, ty_to_move, poli) StrSegInfo *pSrcStrSeg; int into_words, x, baseline_y; struct ObjRec *prototype; int tx_to_move, ty_to_move; ObjListInfo *poli; /* * x is the left edge of the string segment. */ { char *c_ptr=pSrcStrSeg->dyn_str.s; int is_gap=(*c_ptr == ' ' || *c_ptr == '\t'); if (!TrySetCanvasFont(pSrcStrSeg->font, pSrcStrSeg->style, SzUnitToFontSize(pSrcStrSeg->sz_unit), TRUE, NULL)) { return; } while (*c_ptr != '\0') { struct ObjRec *new_obj=DupObj(prototype); StrSegInfo *pDestStrSeg=NULL; char *word_start=NULL, saved_ch='\0'; int w=0, all_blanks=FALSE; FreeStrSeg(GetTextObjFirstStrSeg(new_obj)); DupStrSeg(new_obj->detail.t->minilines.first->first_block, pSrcStrSeg); pDestStrSeg = GetTextObjFirstStrSeg(new_obj); if (into_words) { char *prev_ptr=NULL; word_start = c_ptr; if (is_gap) { for ( ; *c_ptr == ' ' || *c_ptr == '\t'; c_ptr++) { prev_ptr = c_ptr; } /* all_blanks = TRUE; */ } else { for ( ; *c_ptr != ' ' && *c_ptr != '\t' && *c_ptr != '\0'; c_ptr++) { prev_ptr = c_ptr; } } saved_ch = *c_ptr; *c_ptr = '\0'; DynStrSet(&pDestStrSeg->dyn_str, word_start); w = MyTextWidth(canvasFontPtr, pDestStrSeg->dyn_str.s, pDestStrSeg->dyn_str.sz-1); *c_ptr = saved_ch; if (prev_ptr != NULL) c_ptr = prev_ptr; is_gap = !is_gap; } else { if (pSrcStrSeg->double_byte) { strncpy(pDestStrSeg->dyn_str.s, c_ptr, 2); pDestStrSeg->dyn_str.s[2] = '\0'; pDestStrSeg->dyn_str.sz = 3; w = MyTextWidth(canvasFontPtr, pDestStrSeg->dyn_str.s, 2); } else { *pDestStrSeg->dyn_str.s = *c_ptr; pDestStrSeg->dyn_str.s[1] = '\0'; pDestStrSeg->dyn_str.sz = 2; w = MyTextWidth(canvasFontPtr, pDestStrSeg->dyn_str.s, 1); } } if (c_ptr == NULL) { FreeObj(new_obj); break; } else if (all_blanks) { FreeObj(new_obj); } else { FinalizeBreakStrSeg(new_obj, x, baseline_y, prototype, tx_to_move, ty_to_move, poli); } x += w; if (*c_ptr == '\0') break; if (pSrcStrSeg->double_byte) { c_ptr += 2; } else { c_ptr++; } } } static void BreakStrBlock(pStrBlock, into_words, x, baseline_y, prototype, tx_to_move, ty_to_move, poli) StrBlockInfo *pStrBlock; int into_words, x, baseline_y; struct ObjRec *prototype; int tx_to_move, ty_to_move; ObjListInfo *poli; /* * x is the left edge of the string block. */ { int saved_baseline_y=baseline_y; int block_w=pStrBlock->w; switch (pStrBlock->type) { case SB_SIMPLE: BreakStrSeg(pStrBlock->seg, into_words, x, baseline_y, prototype, tx_to_move, ty_to_move, poli); break; case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: switch (pStrBlock->type) { case SB_SUPSUB_LEFT: x += block_w; break; case SB_SUPSUB_CENTER: x += (block_w>>1); break; case SB_SUPSUB_RIGHT: break; } if (pStrBlock->type == SB_SUPSUB_CENTER) { /* pStrBlock->seg better not be NULL or it will crash */ baseline_y = saved_baseline_y; BreakStrSeg(pStrBlock->seg, into_words, x-((pStrBlock->seg->w)>>1), baseline_y, prototype, tx_to_move, ty_to_move, poli); } if (pStrBlock->sup != NULL) { baseline_y = saved_baseline_y+pStrBlock->sup->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { baseline_y -= pStrBlock->seg->asc; } BreakMiniLines(pStrBlock->sup, into_words, x, baseline_y, prototype, tx_to_move, ty_to_move, poli); } if (pStrBlock->sub != NULL) { baseline_y = saved_baseline_y+pStrBlock->sub->baseline_offset; if (pStrBlock->type == SB_SUPSUB_CENTER) { baseline_y += pStrBlock->seg->des; } BreakMiniLines(pStrBlock->sub, into_words, x, baseline_y, prototype, tx_to_move, ty_to_move, poli); } break; } } static void BreakMiniLine(pMiniLine, into_words, x, baseline_y, prototype, tx_to_move, ty_to_move, poli) MiniLineInfo *pMiniLine; int into_words, x, baseline_y; struct ObjRec *prototype; int tx_to_move, ty_to_move; ObjListInfo *poli; /* * x is the left edge of the miniline and baseline_y has been adjusted by * pMiniLine->v_gap. */ { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { BreakStrBlock(pStrBlock, into_words, x, baseline_y, prototype, tx_to_move, ty_to_move, poli); x += pStrBlock->w; } } void BreakMiniLines(minilines, how, x, baseline_y, prototype, tx_to_move, ty_to_move, poli) MiniLinesInfo *minilines; int how, x, baseline_y; struct ObjRec *prototype; int tx_to_move, ty_to_move; ObjListInfo *poli; /* * x is the origin of the minilines (not the left edge) */ { MiniLineInfo *pMiniLine=NULL, *pNextMiniLine=NULL; int v_space=minilines->v_space; int saved_x=x; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pNextMiniLine) { pNextMiniLine = pMiniLine->next; baseline_y += pMiniLine->v_gap; switch (minilines->just) { case JUST_L: x = saved_x; break; case JUST_C: x = saved_x - ((pMiniLine->w)>>1); break; case JUST_R: x = saved_x - pMiniLine->w; break; } if (how == BREAK_LINE) { struct ObjRec *new_obj=DupObj(prototype); MiniLinesInfo *new_minilines=(&new_obj->detail.t->minilines); FreeMiniLines(new_minilines, FALSE); DupMiniLine(pMiniLine, new_minilines, NULL, &new_minilines->first, &new_minilines->last); FinalizeBreakStrSeg(new_obj, x, baseline_y, prototype, tx_to_move, ty_to_move, poli); } else { BreakMiniLine(pMiniLine, (how==BREAK_WORD), x, baseline_y, prototype, tx_to_move, ty_to_move, poli); } baseline_y += pMiniLine->des + v_space; if (pMiniLine->next != NULL) { baseline_y += pMiniLine->next->asc; } } } /* --------------------- DumpMiniLines() --------------------- */ static void DumpGSave(FP, do_dump, indent) FILE *FP; int do_dump, indent; { if (do_dump) { DumpIndentString(FP, indent); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); } } static void DumpGRestore(FP, do_dump, indent) FILE *FP; int do_dump, indent; { if (do_dump) { DumpIndentString(FP, indent); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); } } static void DumpSetFont(FP, font, font_name, double_byte, style, sz_unit) FILE *FP; int font, double_byte, style, sz_unit; char *font_name; { char buf[MAXSTRING], font_str[MAXSTRING], real_font_str[MAXSTRING]; char *ps_findfont_cmd=gPsCmd[PS_FINDFONT]; float fSize=(float)0; if (double_byte) { #ifdef _PS_USE_EUC_FONT int euc_font=FALSE; char combined_font_str[MAXSTRING]; #endif /* _PS_USE_EUC_FONT */ if (PRTGIF && font_name != NULL) { sprintf(font_str, "/%s", font_name); } else { GetPSFontStr(font, style, font_str); } strcpy(real_font_str, font_str); MapAliasedPSFontName(real_font_str, sizeof(real_font_str)); #ifdef _PS_USE_EUC_FONT /* do not translate -- program constants */ euc_font = (strstr(font_str, "-EUC-") != NULL); if (euc_font) { if (preDumpSetup) PSUseEucFont(); sprintf(combined_font_str, "/Courier-%s", &font_str[1]); fprintf(FP, "%s /Courier %s eucfont\n", combined_font_str, font_str); fprintf(FP, "%s ", combined_font_str); UpdateDocumentFonts(&font_str[1]); UpdateDocumentFonts("Courier"); } else { fprintf(FP, "%s ", font_str); UpdateDocumentFonts(&font_str[1]); } #else /* ~_PS_USE_EUC_FONT */ fprintf(FP, "%s ", font_str); UpdateDocumentFonts(&real_font_str[1]); #endif /* _PS_USE_EUC_FONT */ } else { if (PRTGIF && font_name != NULL) { sprintf(font_str, "/%s", font_name); } else { GetPSFontStr(font, style, font_str); } strcpy(real_font_str, font_str); MapAliasedPSFontName(real_font_str, sizeof(real_font_str)); if (NeedEncode(&font_str[1], font, style)) { #ifdef _PRTGIF_USE_ISO_LATIN_1_ALWAYS if (PRTGIF && !cmdLineOpenDisplay) { if (preDumpSetup) PSUseReencode(NULL); fprintf(FP, "%s %s-8 latin1.vec ", real_font_str, font_str); ps_findfont_cmd = "TGFF8"; } else { fprintf(FP, "%s-8 ", font_str); } #else /* ~_PRTGIF_USE_ISO_LATIN_1_ALWAYS */ fprintf(FP, "%s-8 ", font_str); #endif /* _PRTGIF_USE_ISO_LATIN_1_ALWAYS */ } else { fprintf(FP, "%s ", real_font_str); } UpdateDocumentFonts(&real_font_str[1]); } fSize = (float)(((float)sz_unit)/((float)NUM_SZ_UNIT_PER_FONT_SIZE)); FormatFloat(&fSize, buf); fprintf(FP, "%s ", ps_findfont_cmd); #ifndef _PS_USE_EUC_FONT if (double_byte) { fprintf(FP, "dup /WMode known {dup /WMode get 1 eq "); #ifdef _VERT_FONT_OFFSET_POINT_4 fprintf(FP, "{[0 1 -1 0 0 0.4] makefont} if} if\n"); #else /* ~_VERT_FONT_OFFSET_POINT_4 */ fprintf(FP, "{[0 1 -1 0 0 0.3] makefont} if} if\n"); #endif /* _VERT_FONT_OFFSET_POINT_4 */ } #endif /* ~_PS_USE_EUC_FONT */ fprintf(FP, "[%s 0 0 -%s 0 0] %s\n", buf, buf, gPsCmd[PS_MAKESETFONT]); } static void DumpStrSeg(pStrSeg, just, x, baseline_y, FP, pBBox, do_dump, indent) StrSegInfo *pStrSeg; int just, x, baseline_y, do_dump, indent; FILE *FP; struct BBRec *pBBox; { int font=pStrSeg->font, style=pStrSeg->style, sz_unit=pStrSeg->sz_unit; int double_byte=pStrSeg->double_byte, color_index=pStrSeg->color; int double_byte_mod_bytes=pStrSeg->double_byte_mod_bytes; int asc=(pStrSeg->read_only ? pStrSeg->orig_asc : pStrSeg->asc); char *font_name=pStrSeg->font_name; if (*pStrSeg->dyn_str.s == '\0') { if (!do_dump) { DumpIndentString(FP, indent); fprintf(FP, "0\n"); } return; } if (do_dump) { DumpIndentString(FP, indent); if (penPat == BACKPAT) { fprintf(FP, "1 %s\n", gPsCmd[PS_SETGRAY]); } else if (colorDump || !useGray) { DumpRGBColorLine(FP, color_index, 0, TRUE); } else if (penPat == SOLIDPAT) { fprintf(FP, "0 %s\n", gPsCmd[PS_SETGRAY]); } else { GrayCheck(penPat); fprintf(FP, "%s %s\n", GrayStr(penPat), gPsCmd[PS_SETGRAY]); } } DumpIndentString(FP, indent); DumpSetFont(FP, font, font_name, double_byte, style, sz_unit); DumpIndentString(FP, indent); fprintf(FP, "("); DumpOneStr(FP, font, double_byte, double_byte_mod_bytes, pStrSeg->dyn_str.s); if (do_dump) { int underline_on=pStrSeg->underline_on; int overline_on=pStrSeg->overline_on; if (just == JUST_C && preDumpSetup) PSUseCenterText(); if ((colorDump || !useGray) && penPat > BACKPAT) { if (just == JUST_C) { fprintf(FP, ") TGCTX %s TGSW %s %s true %s %s %s\n", gPsCmd[PS_DUP], gPsCmd[PS_EXCH], gPsCmd[PS_GSAVE], gPsCmd[PS_CHARPATH], gPsCmd[PS_CLIP], gPsCmd[PS_NEWPATH]); } else { fprintf(FP, ") %s TGSW %s %s true %s %s %s\n", gPsCmd[PS_DUP], gPsCmd[PS_EXCH], gPsCmd[PS_GSAVE], gPsCmd[PS_CHARPATH], gPsCmd[PS_CLIP], gPsCmd[PS_NEWPATH]); } if (preDumpSetup) PSUseColorPattern(); DumpPatFill(FP, penPat, *pBBox, indent, FALSE); if (underline_on && overline_on) { fprintf(FP, " %s %s %s 0 %s\n", gPsCmd[PS_GRESTORE], gPsCmd[PS_DUP], gPsCmd[PS_DUP], gPsCmd[PS_RMOVETO]); } else if (underline_on || overline_on) { fprintf(FP, " %s %s 0 %s\n", gPsCmd[PS_GRESTORE], gPsCmd[PS_DUP], gPsCmd[PS_RMOVETO]); } else { fprintf(FP, " %s 0 %s\n", gPsCmd[PS_GRESTORE], gPsCmd[PS_RMOVETO]); } } else { if (just == JUST_C) { if (underline_on && overline_on) { fprintf(FP, ") %s %s TGSW %s TGCTX %s\n", gPsCmd[PS_DUP], gPsCmd[PS_DUP], gPsCmd[PS_EXCH], gPsCmd[PS_SHOW]); } else if (underline_on || overline_on) { fprintf(FP, ") %s TGSW %s TGCTX %s\n", gPsCmd[PS_DUP], gPsCmd[PS_EXCH], gPsCmd[PS_SHOW]); } else { fprintf(FP, ") TGCTX %s\n", gPsCmd[PS_SHOW]); } } else { if (underline_on && overline_on) { fprintf(FP, ") %s %s TGSW %s %s\n", gPsCmd[PS_DUP], gPsCmd[PS_DUP], gPsCmd[PS_EXCH], gPsCmd[PS_SHOW]); } else if (underline_on || overline_on) { fprintf(FP, ") %s TGSW %s %s\n", gPsCmd[PS_DUP], gPsCmd[PS_EXCH], gPsCmd[PS_SHOW]); } else { fprintf(FP, ") %s\n", gPsCmd[PS_SHOW]); } } } if (underline_on) { DumpIndentString(FP, indent); fprintf(FP, "%s %s %s 0 %1d %s %s 0 %s %s %s\n", gPsCmd[PS_GSAVE], gPsCmd[PS_CURRENTPOINT], gPsCmd[PS_MOVETO], curUnderlineYOffset, gPsCmd[PS_RMOVETO], gPsCmd[PS_NEG], gPsCmd[PS_RLINETO], gPsCmd[PS_STROKE], gPsCmd[PS_GRESTORE]); } if (overline_on) { DumpIndentString(FP, indent); fprintf(FP, "%s %s %s 0 %1d %s %s 0 %1d %s %s %s 0 %s %s %s\n", gPsCmd[PS_GSAVE], gPsCmd[PS_CURRENTPOINT], gPsCmd[PS_MOVETO], curOverlineYOffset, gPsCmd[PS_NEG], gPsCmd[PS_RMOVETO], asc, gPsCmd[PS_NEG], gPsCmd[PS_RMOVETO], gPsCmd[PS_NEG], gPsCmd[PS_RLINETO], gPsCmd[PS_STROKE], gPsCmd[PS_GRESTORE]); } } else { fprintf(FP, ") TGSW \n"); } } static void DumpSupSubBlock(pStrBlock, x, baseline_y, FP, pBBox, do_dump, indent) StrBlockInfo *pStrBlock; int x, baseline_y, do_dump, indent; FILE *FP; struct BBRec *pBBox; { int saved_baseline_y=baseline_y; if (!do_dump) { DumpIndentString(FP, indent); fprintf(FP, "0\n"); } if (pStrBlock->type == SB_SUPSUB_CENTER) { /* pStrBlock->seg better not be NULL or it will crash */ DumpGSave(FP, do_dump, indent); baseline_y = saved_baseline_y; DumpStrSeg(pStrBlock->seg, JUST_C, x-((pStrBlock->seg->w)>>1), baseline_y, FP, pBBox, do_dump, indent+2); if (!do_dump) { DumpIndentString(FP, indent); fprintf(FP, "TGMAX\n"); } DumpGRestore(FP, do_dump, indent); } if (pStrBlock->sup != NULL) { if (!BlankMiniLines(pStrBlock->sup)) { DumpGSave(FP, do_dump, indent); baseline_y = saved_baseline_y+pStrBlock->sup->baseline_offset; if (do_dump && pStrBlock->sup->baseline_offset != 0) { DumpIndentString(FP, indent+2); fprintf(FP, "0 %1d %s\n", pStrBlock->sup->baseline_offset, gPsCmd[PS_RMOVETO]); } if (pStrBlock->type == SB_SUPSUB_CENTER && do_dump && pStrBlock->seg->asc != 0) { /* * shift the superscript up more because SB_SUPSUB_CENTER */ baseline_y -= pStrBlock->seg->asc; DumpIndentString(FP, indent); fprintf(FP, "0 %1d %s %s\n", pStrBlock->seg->asc, gPsCmd[PS_NEG], gPsCmd[PS_RMOVETO]); } DumpMiniLines(pStrBlock->sup, x, baseline_y, FP, pBBox, do_dump, indent+2); if (!do_dump) { DumpIndentString(FP, indent); fprintf(FP, "TGMAX\n"); } DumpGRestore(FP, do_dump, indent); } } if (pStrBlock->sub != NULL) { if (!BlankMiniLines(pStrBlock->sub)) { DumpGSave(FP, do_dump, indent); baseline_y = saved_baseline_y+pStrBlock->sub->baseline_offset; if (do_dump && pStrBlock->sub->baseline_offset != 0) { DumpIndentString(FP, indent+2); fprintf(FP, "0 %1d %s\n", pStrBlock->sub->baseline_offset, gPsCmd[PS_RMOVETO]); } if (pStrBlock->type == SB_SUPSUB_CENTER && do_dump && pStrBlock->seg->des != 0) { /* * shift the subscript down more because SB_SUPSUB_CENTER */ baseline_y += pStrBlock->seg->des; DumpIndentString(FP, indent); fprintf(FP, "0 %1d %s\n", pStrBlock->seg->des, gPsCmd[PS_RMOVETO]); } DumpMiniLines(pStrBlock->sub, x, baseline_y, FP, pBBox, do_dump, indent+2); if (!do_dump) { DumpIndentString(FP, indent); fprintf(FP, "TGMAX\n"); } DumpGRestore(FP, do_dump, indent); } } } static void DumpStrBlock(pStrBlock, x, baseline_y, FP, pBBox, do_dump, indent) StrBlockInfo *pStrBlock; int x, baseline_y, do_dump, indent; FILE *FP; struct BBRec *pBBox; /* * x is the left edge of the string block. */ { int block_w=pStrBlock->w; switch (pStrBlock->type) { case SB_SIMPLE: DumpStrSeg(pStrBlock->seg, JUST_L, x, baseline_y, FP, pBBox, do_dump, indent+2); break; case SB_CHAR_SPACE: if (do_dump) { fprintf(FP, "%1d 0 %s\n", pStrBlock->special_char_w, gPsCmd[PS_RMOVETO]); } else { fprintf(FP, "%1d \n", pStrBlock->special_char_w); } break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (!do_dump) { DumpIndentString(FP, indent); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); DumpIndentString(FP, indent); fprintf(FP, "0\n"); } if (do_dump) { switch (pStrBlock->type) { case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: if (do_dump) { DumpGSave(FP, do_dump, indent); DumpIndentString(FP, indent); fprintf(FP, "0\n"); } if (pStrBlock->type == SB_SUPSUB_CENTER) { x += (block_w>>1); } else { x += block_w; } DumpSupSubBlock(pStrBlock, x, baseline_y, FP, pBBox, FALSE, indent+2); DumpIndentString(FP, indent); fprintf(FP, "TGMAX\n"); DumpGRestore(FP, do_dump, indent); DumpGSave(FP, do_dump, indent); DumpIndentString(FP, indent); fprintf(FP, "%s\n", gPsCmd[PS_DUP]); DumpIndentString(FP, indent); if (pStrBlock->type == SB_SUPSUB_CENTER) { fprintf(FP, "2 %s 0 %s\n", gPsCmd[PS_DIV], gPsCmd[PS_RMOVETO]); } else { fprintf(FP, "0 %s\n", gPsCmd[PS_RMOVETO]); } /* now dump it */ DumpSupSubBlock(pStrBlock, x, baseline_y, FP, pBBox, TRUE, indent+2); DumpGRestore(FP, do_dump, indent); DumpIndentString(FP, indent); fprintf(FP, "0 %s\n", gPsCmd[PS_RMOVETO]); break; case SB_SUPSUB_RIGHT: DumpGSave(FP, do_dump, indent); DumpSupSubBlock(pStrBlock, x, baseline_y, FP, pBBox, TRUE, indent+2); DumpGRestore(FP, do_dump, indent); DumpSupSubBlock(pStrBlock, x, baseline_y, FP, pBBox, FALSE, indent+2); DumpIndentString(FP, indent); fprintf(FP, "0 %s\n", gPsCmd[PS_RMOVETO]); break; } } else { DumpSupSubBlock(pStrBlock, x, baseline_y, FP, pBBox, FALSE, indent+2); DumpIndentString(FP, indent); fprintf(FP, "TGMAX\n"); } if (!do_dump) { DumpIndentString(FP, indent); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); } break; } } static void DumpMiniLine(pMiniLine, x, baseline_y, FP, pBBox, do_dump, indent) MiniLineInfo *pMiniLine; int x, baseline_y, do_dump, indent; FILE *FP; struct BBRec *pBBox; /* * x is the left edge of the miniline and baseline_y has been adjusted by * pMiniLine->v_gap. */ { StrBlockInfo *pStrBlock=NULL; if (!do_dump) { /* * compute the sum of the widths and leave it on the stop of stack */ DumpIndentString(FP, indent); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); DumpIndentString(FP, indent); fprintf(FP, "0\n"); } for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { DumpStrBlock(pStrBlock, x, baseline_y, FP, pBBox, do_dump, indent+2); if (!do_dump) { DumpIndentString(FP, indent); fprintf(FP, "%s\n", gPsCmd[PS_ADD]); } x += pStrBlock->w; } if (!do_dump) { DumpIndentString(FP, indent); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); } } void DumpMiniLines(minilines, x, baseline_y, FP, pBBox, do_dump, indent) MiniLinesInfo *minilines; int x, baseline_y, do_dump, indent; FILE *FP; struct BBRec *pBBox; /* * x is the origin of the minilines (not the left edge) */ { MiniLineInfo *pMiniLine=NULL; int v_space=minilines->v_space, just=minilines->just; int saved_x=x; if (!do_dump) { /* * compute the max of the widths and leave it on the stop of stack */ DumpIndentString(FP, indent); fprintf(FP, "0\n"); } for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { baseline_y += pMiniLine->v_gap; if (do_dump && pMiniLine->v_gap != 0) { DumpIndentString(FP, indent); fprintf(FP, "0 %1d %s\n", pMiniLine->v_gap, gPsCmd[PS_RMOVETO]); } DumpGSave(FP, do_dump, indent); if (do_dump) { switch (just) { case JUST_L: DumpMiniLine(pMiniLine, saved_x, baseline_y, FP, pBBox, TRUE, indent+2); break; case JUST_C: case JUST_R: /* get the length of the string on top of the stack */ DumpMiniLine(pMiniLine, x, baseline_y, FP, pBBox, FALSE, indent+2); DumpIndentString(FP, indent); if (just == JUST_C) { fprintf(FP, "2 %s %s 0 %s\n", gPsCmd[PS_DIV], gPsCmd[PS_NEG], gPsCmd[PS_RMOVETO]); } else { fprintf(FP, "%s 0 %s\n", gPsCmd[PS_NEG], gPsCmd[PS_RMOVETO]); } /* now dump it */ DumpMiniLine(pMiniLine, x, baseline_y, FP, pBBox, TRUE, indent+2); break; } } else { DumpMiniLine(pMiniLine, x, baseline_y, FP, pBBox, FALSE, indent+2); DumpIndentString(FP, indent); fprintf(FP, "TGMAX\n"); } DumpGRestore(FP, do_dump, indent); if (pMiniLine->next != NULL) { baseline_y += pMiniLine->des + v_space + pMiniLine->next->asc; if (do_dump && (pMiniLine->des+v_space+pMiniLine->next->asc) != 0) { DumpIndentString(FP, indent); fprintf(FP, "0 %1d %s\n", (pMiniLine->des+v_space+pMiniLine->next->asc), gPsCmd[PS_RMOVETO]); } } } } /* --------------------- DumpSimpleTextPath() --------------------- */ int SimpleTextObj(text_ptr) struct TextRec *text_ptr; { MiniLinesInfo *minilines=(&text_ptr->minilines); MiniLineInfo *pMiniLine=minilines->first; StrBlockInfo *pStrBlock=NULL; if (text_ptr->fill == NONEPAT) { /* * Return FALSE here does not mean that the text object is simple. * * Since there is no fill, there is no need to measure the width of * text in this case. Therefore, return FALSE; */ return FALSE; } if (pMiniLine != minilines->last) return FALSE; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (pStrBlock->type != SB_SIMPLE) return FALSE; } return TRUE; } void DumpSimpleTextPath(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { struct TextRec *text_ptr=ObjPtr->detail.t; MiniLinesInfo *minilines=(&text_ptr->minilines); MiniLineInfo *pMiniLine=minilines->first; StrBlockInfo *pStrBlock=NULL; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(SimpleTextObj(text_ptr), "Text is not a simple text object in DumpSimpleTextPath()", NULL); #endif /* _TGIF_DBG */ for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { fprintf(FP, " /tgifstrw tgifstrw\n"); DumpStrSeg(pStrBlock->seg, JUST_L, 0, 0, FP, &ObjPtr->obbox, FALSE, 6); fprintf(FP, " add def\n"); } } /* --------------------- DumpMiniLinesInAscii() --------------------- */ static void DumpStrSegInAscii(FP, pStrSeg, pnSomethingPrinted) FILE *FP; StrSegInfo *pStrSeg; int *pnSomethingPrinted; { if (*pStrSeg->dyn_str.s == '\0') return; if (fprintf(FP, "%s", pStrSeg->dyn_str.s) == EOF) { writeFileFailed = TRUE; } if (pnSomethingPrinted != NULL) *pnSomethingPrinted = TRUE; } static void DumpStrBlockInAscii(FP, pStrBlock, pnSomethingPrinted) FILE *FP; StrBlockInfo *pStrBlock; int *pnSomethingPrinted; { switch (pStrBlock->type) { case SB_SIMPLE: DumpStrSegInAscii(FP, pStrBlock->seg, pnSomethingPrinted); break; case SB_CHAR_SPACE: if (fprintf(FP, " ") == EOF) writeFileFailed = TRUE; break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: fprintf(FP, "\n"); if (pStrBlock->type == SB_SUPSUB_CENTER) { /* pStrBlock->seg better not be NULL or it will crash */ DumpStrSegInAscii(FP, pStrBlock->seg, pnSomethingPrinted); if (fprintf(FP, "\n") == EOF) writeFileFailed = TRUE; } if (pStrBlock->sup != NULL) { if (!BlankMiniLines(pStrBlock->sup)) { DumpMiniLinesInAscii(FP, pStrBlock->sup, pnSomethingPrinted); } } if (pStrBlock->sub != NULL) { if (!BlankMiniLines(pStrBlock->sub)) { DumpMiniLinesInAscii(FP, pStrBlock->sub, pnSomethingPrinted); } } break; } } void DumpMiniLineInAscii(FP, pMiniLine, pnSomethingPrinted) FILE *FP; MiniLineInfo *pMiniLine; int *pnSomethingPrinted; { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { DumpStrBlockInAscii(FP, pStrBlock, pnSomethingPrinted); } } void DumpMiniLinesInAscii(FP, minilines, pnSomethingPrinted) FILE *FP; MiniLinesInfo *minilines; int *pnSomethingPrinted; { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { DumpMiniLineInAscii(FP, pMiniLine, pnSomethingPrinted); if (fprintf(FP, "\n") == EOF) writeFileFailed = TRUE; } } /* --------------------- ConvertMiniLineToString() --------------------- */ static void ConvertStrSegToString(pStrSeg, ppsz_buf, pn_len) StrSegInfo *pStrSeg; char **ppsz_buf; int *pn_len; { int len=0; if (*pStrSeg->dyn_str.s == '\0') return; len = strlen(pStrSeg->dyn_str.s); (*ppsz_buf) = realloc(*ppsz_buf, ((*pn_len)+len+1)*sizeof(char)); if ((*ppsz_buf) == NULL) FailAllocMessage(); strcpy(&(*ppsz_buf)[*pn_len], pStrSeg->dyn_str.s); *pn_len += len; } static int ConvertStrBlockToString(pStrBlock, ppsz_buf, pn_len) StrBlockInfo *pStrBlock; char **ppsz_buf; int *pn_len; /* returns TRUE to continue to the next block */ /* returns FALSE if this string block contains super/subscripts */ { switch (pStrBlock->type) { case SB_SIMPLE: ConvertStrSegToString(pStrBlock->seg, ppsz_buf, pn_len); break; case SB_CHAR_SPACE: if (pStrBlock->special_char_w > 0) { /* only generate a space if the width of the thin space is > 0 */ (*ppsz_buf) = realloc(*ppsz_buf, ((*pn_len)+2)*sizeof(char)); if ((*ppsz_buf) == NULL) FailAllocMessage(); strcpy(&(*ppsz_buf)[*pn_len], " "); (*pn_len)++; } break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (!BlankMiniLines(pStrBlock->sup) || !BlankMiniLines(pStrBlock->sub)) { return FALSE; } if (pStrBlock->type == SB_SUPSUB_CENTER) { /* pStrBlock->seg better not be NULL or it will crash */ ConvertStrSegToString(pStrBlock->seg, ppsz_buf, pn_len); } break; } return TRUE; } char *ConvertMiniLineToString(pMiniLine, pnNeedToFree) MiniLineInfo *pMiniLine; int *pnNeedToFree; /* must free the returned string with UtilFree() */ { char *buf=NULL; int len=0; StrBlockInfo *pStrBlock=NULL; *pnNeedToFree = FALSE; if (pMiniLine->first_block->next == NULL) { return pMiniLine->first_block->seg->dyn_str.s; } buf = UtilStrDup(pMiniLine->first_block->seg->dyn_str.s); if (buf == NULL) FailAllocMessage(); len = strlen(buf); for (pStrBlock=pMiniLine->first_block->next; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (!ConvertStrBlockToString(pStrBlock, &buf, &len)) { break; } } *pnNeedToFree = TRUE; return buf; } /* ----------------- ConvertAttrNameFirstMiniLineToString() ----------------- */ char *ConvertAttrNameFirstMiniLineToString(attr_ptr, pnNeedToFree) struct AttrRec *attr_ptr; int *pnNeedToFree; /* must not be NULL */ /* must free the returned string with UtilFree() */ { char *tmp_buf=NULL; tmp_buf = ConvertMiniLineToString(attr_ptr->obj->detail.t->minilines.first, pnNeedToFree); if (*attr_ptr->attr_name.s != '\0' && !attr_ptr->nameshown) { char *psz=(char*)malloc(sizeof(char) * (attr_ptr->attr_name.sz+strlen(tmp_buf))); if (psz == NULL) FailAllocMessage(); sprintf(psz, "%s%s", attr_ptr->attr_name.s, tmp_buf); if (*pnNeedToFree) UtilFree(tmp_buf); tmp_buf = psz; *pnNeedToFree = TRUE; } return tmp_buf; } /* ----------------- MiniLinesInVisibleLayer() ----------------- */ static int StrSegInVisibleLayer(pStrSeg) StrSegInfo *pStrSeg; { return colorLayerOn[pStrSeg->color]; } static int StrBlockInVisibleLayer(pStrBlock) StrBlockInfo *pStrBlock; { switch (pStrBlock->type) { case SB_SIMPLE: return StrSegInVisibleLayer(pStrBlock->seg); case SB_CHAR_SPACE: return FALSE; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->type == SB_SUPSUB_CENTER) { if (StrSegInVisibleLayer(pStrBlock->seg)) { return TRUE; } } if (pStrBlock->sup != NULL) { if (MiniLinesInVisibleLayer(pStrBlock->sup)) { return TRUE; } } if (pStrBlock->sub != NULL) { if (MiniLinesInVisibleLayer(pStrBlock->sub)) { return TRUE; } } break; } return FALSE; } static int MiniLineInVisibleLayer(pMiniLine) MiniLineInfo *pMiniLine; { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (StrBlockInVisibleLayer(pStrBlock)) { return TRUE; } } return FALSE; } int MiniLinesInVisibleLayer(minilines) MiniLinesInfo *minilines; { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (MiniLineInVisibleLayer(pMiniLine)) { return TRUE; } } return FALSE; } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xpixmap.c����������������������������������������������������������������������������0000644�0000764�0000764�00000572105�11602233314�014632� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xpixmap.c,v 1.89 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_XPIXMAP_C_ #include "tgifdefs.h" #include "attr.e" #include "auxtext.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "font.e" #include "grid.e" #include "hash.e" #include "http.e" #include "imgproc.e" #include "import.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "move.e" #include "msg.e" #include "names.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "pngtrans.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "select.e" #include "setup.e" #include "stretch.e" #include "strtbl.e" #include "util.e" #include "xbitmap.e" #include "xpixmap.e" #include "z_intrf.e" struct BucketRec { int pixel, index, color_index; char s[40]; }; #define XPM_BUCKETS 67 #define XPM_BUCKET_INC 10 #define TYPE_PPM3 3 #define TYPE_PPM5 5 #define TYPE_PPM6 6 GC xpmGC=NULL; int newColormapUsed=FALSE; int allocColorFailed=FALSE; int myReadTransparentPixmap=FALSE; int xpmIsArray=FALSE; long xpmArraySeek=(-1L); int xpmHasTooManyColorsForPrinting=FALSE; int hasReadHexString=FALSE; PngHeaderInfo gPngHeaderInfo; double rotatedSine[4]={ 0.0, 1.0, 0.0, -1.0 }; double rotatedCosine[4]={ 1.0, 0.0, -1.0, 0.0 }; static Pixmap dummyPixmap=None; /* do not translate -- program constants */ static char hexValue[]="0123456789abcdef"; static int askForXPmSpec=FALSE; static int guessXPmBgColor=FALSE; static int littleEndianPpm6=FALSE; static struct BucketRec **xpmBucket=NULL; static int *xpmBucketSize=NULL; static int *xpmBucketMaxSize=NULL; static int shownXPmErrorMessage=FALSE; static TgHash gColorsHashForPrinting; static int gnColorsHashForPrintingValid=FALSE; void ResetXPmErrorMessage() { shownXPmErrorMessage = FALSE; } void InitXPm() { register int i; XGCValues values; char *c_ptr; dummyPixmap = XCreatePixmap(mainDisplay, mainWindow, 1, 1, mainDepth); values.foreground = myFgPixel; values.background = myBgPixel; values.function = GXcopy; values.fill_style = FillSolid; xpmGC = XCreateGC(mainDisplay, dummyPixmap, GCForeground | GCBackground | GCFunction | GCFillStyle, &values); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"AskForXPmSpec")) != NULL) { if (UtilStrICmp(c_ptr, "true") == 0) { askForXPmSpec = TRUE; } else { askForXPmSpec = FALSE; } } guessXPmBgColor = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"GuessXPmBgColor"))!=NULL) { if (UtilStrICmp(c_ptr, "true") == 0) { guessXPmBgColor = TRUE; } } littleEndianPpm6 = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"LittleEndianPpm6"))!=NULL) { if (UtilStrICmp(c_ptr, "true") == 0) { littleEndianPpm6 = TRUE; } } newColormapUsed = FALSE; xpmBucket = (struct BucketRec **)malloc(XPM_BUCKETS*sizeof(struct BucketRec *)); xpmBucketSize = (int*)malloc((XPM_BUCKETS+1)*sizeof(int)); xpmBucketMaxSize = (int*)malloc(XPM_BUCKETS*sizeof(int)); if (xpmBucket == NULL || xpmBucketSize == NULL || xpmBucketMaxSize == NULL) { FailAllocMessage(); } for (i=0; i < XPM_BUCKETS; i++) { xpmBucket[i] = (struct BucketRec *)malloc(XPM_BUCKET_INC*sizeof(struct BucketRec)); if (xpmBucket[i] == NULL) FailAllocMessage(); xpmBucketSize[i] = 0; xpmBucketMaxSize[i] = XPM_BUCKET_INC; } xpmBucketSize[XPM_BUCKETS] = INVALID; memset(&gPngHeaderInfo, 0, sizeof(PngHeaderInfo)); } void CleanUpXPm() { register int i; if (xpmGC != NULL) XFreeGC(mainDisplay, xpmGC); XFreePixmap(mainDisplay, dummyPixmap); askForXPmSpec = FALSE; for (i = 0; i < XPM_BUCKETS; i++) free(xpmBucket[i]); free(xpmBucket); free(xpmBucketSize); free(xpmBucketMaxSize); xpmBucket = NULL; xpmBucketSize = xpmBucketMaxSize = NULL; } int IsLinkedJpegObj(obj_ptr) struct ObjRec *obj_ptr; { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; int real_type=xpm_ptr->real_type, linked_jpeg=xpm_ptr->linked_jpeg; char *jpeg_filename=xpm_ptr->filename; /* if the object is a linked JPEG file, will not perform imageproc */ return (real_type == XPM_JPEG && linked_jpeg && jpeg_filename != NULL); } int IsPpmTrueObj(real_type, ppm_data_compress, ppm_data) int real_type, ppm_data_compress; char *ppm_data; { return (real_type == PPM_TRUE && (ppm_data_compress == PPM_JPEG_COMPRESS || ppm_data_compress == PPM_DATA_DEFLATED) && ppm_data != NULL); } int ObjHasIndexedTransPixel(obj_ptr, pn_index) struct ObjRec *obj_ptr; int *pn_index; { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; int i=0, ncolors=xpm_ptr->ncolors, *pixels=xpm_ptr->pixels; switch (xpm_ptr->real_type) { case XPM_XPM: for (i=0; i < ncolors; i++) { if (pixels[i] == (-1)) { if (pn_index != NULL) *pn_index = i; return TRUE; } } break; case XPM_JPEG: break; case PPM_TRUE: break; } return FALSE; } int ObjHasTrueColorTransPixel(obj_ptr, puch_trans_color_r, puch_trans_color_g, puch_trans_color_b) struct ObjRec *obj_ptr; unsigned char *puch_trans_color_r, *puch_trans_color_g, *puch_trans_color_b; { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; switch (xpm_ptr->real_type) { case XPM_XPM: break; case XPM_JPEG: break; case PPM_TRUE: if (((PRTGIF && !cmdLineOpenDisplay) || fullTrueColorMode) && xpm_ptr->has_transparent_color) { if (puch_trans_color_r != NULL) *puch_trans_color_r = xpm_ptr->transparent_color[0]; if (puch_trans_color_g != NULL) *puch_trans_color_g = xpm_ptr->transparent_color[1]; if (puch_trans_color_b != NULL) *puch_trans_color_b = xpm_ptr->transparent_color[2]; return TRUE; } break; } return FALSE; } int ObjHasTransPixel(obj_ptr) struct ObjRec *obj_ptr; { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; switch (xpm_ptr->real_type) { case XPM_XPM: return ObjHasIndexedTransPixel(obj_ptr, NULL); case XPM_JPEG: break; case PPM_TRUE: return ObjHasTrueColorTransPixel(obj_ptr, NULL, NULL, NULL); } return FALSE; } #define xpmpixelhash(X) (((X)==(-1)) ? (XPM_BUCKETS-1) : ((X)%XPM_BUCKETS)) static int xpmcharhash(chars_per_pixel, color_char) int chars_per_pixel; char *color_char; { register int i, val=0; for (i = 0; i < chars_per_pixel; i++) val = (val<<1)+(int)(color_char[i]); return (xpmpixelhash(val)); } int BuildXPmBuckets(ncolors, pixels, dump_index_to_color_index, chars_per_pixel, color_char, pxtii) int ncolors, *pixels, *dump_index_to_color_index, chars_per_pixel; char *color_char; XpmTransIndexInfo *pxtii; { register int *ptr=NULL, i; int bucket=0; if (xpmBucketSize == NULL) { xpmBucket = (struct BucketRec **)malloc(XPM_BUCKETS*sizeof(struct BucketRec *)); xpmBucketSize = (int*)malloc((XPM_BUCKETS+1)*sizeof(int)); xpmBucketMaxSize = (int*)malloc(XPM_BUCKETS*sizeof(int)); if (xpmBucket==NULL || xpmBucketSize==NULL || xpmBucketMaxSize==NULL) { FailAllocMessage(); } for (i=0; i < XPM_BUCKETS; i++) { xpmBucket[i] = (struct BucketRec *)malloc( XPM_BUCKET_INC*sizeof(struct BucketRec)); if (xpmBucket[i] == NULL) FailAllocMessage(); xpmBucketSize[i] = 0; xpmBucketMaxSize[i] = XPM_BUCKET_INC; } xpmBucketSize[XPM_BUCKETS] = INVALID; } for (ptr = xpmBucketSize; *ptr != INVALID; ptr++) *ptr = 0; if (chars_per_pixel == INVALID) { /* build the hash table according to the pixels */ for (i=0; i < ncolors; i++) { if (pxtii != NULL) { if (pxtii->has_transparent_pixel && pixels[i] == INVALID) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(pxtii->found_transparent_pixel == FALSE || pxtii->transparent_pixel_index == i, "more than one transparent pixel in BuildXPmBuckets()", NULL); #endif /* _TGIF_DBG */ pxtii->found_transparent_pixel = TRUE; pxtii->transparent_pixel_index = i; if (pxtii->dump_index_to_color_index != NULL) { pxtii->dump_index_to_color_index[i] = INVALID; } } else if (pxtii->dump_index_to_color_index != NULL) { int pixel=pixels[i], found_index=INVALID; if (HashLookUpInt(&gColorsHashForPrinting, (char*)(&pixel), sizeof(int), &found_index)) { pxtii->dump_index_to_color_index[i] = found_index; } else { pxtii->dump_index_to_color_index[i] = INVALID; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "invalid found_index in BuildXPmBuckets()", NULL); #endif /* _TGIF_DBG */ } } } bucket = xpmpixelhash(pixels[i]); if (xpmBucketSize[bucket] == xpmBucketMaxSize[bucket]) { xpmBucket[bucket] = (struct BucketRec *)realloc(xpmBucket[bucket], (xpmBucketMaxSize[bucket]+XPM_BUCKET_INC) * sizeof(struct BucketRec)); xpmBucketMaxSize[bucket] += XPM_BUCKET_INC; } xpmBucket[bucket][xpmBucketSize[bucket]].index = i; xpmBucket[bucket][xpmBucketSize[bucket]].pixel = pixels[i]; if (dump_index_to_color_index == NULL) { xpmBucket[bucket][xpmBucketSize[bucket]].color_index = BAD; } else { xpmBucket[bucket][xpmBucketSize[bucket]].color_index = dump_index_to_color_index[i]; } (xpmBucketSize[bucket])++; } } else { /* build the hash table according to the color_char */ if (chars_per_pixel >= 9) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_CH_PER_PIX_IN_FUNC), chars_per_pixel, "BuildXPmBuckets()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } for (i=0; i < ncolors; i++) { bucket = xpmcharhash(chars_per_pixel, &color_char[i*chars_per_pixel]); if (xpmBucketSize[bucket] == xpmBucketMaxSize[bucket]) { xpmBucket[bucket] = (struct BucketRec *)realloc(xpmBucket[bucket], (xpmBucketMaxSize[bucket]+XPM_BUCKET_INC) * sizeof(struct BucketRec)); xpmBucketMaxSize[bucket] += XPM_BUCKET_INC; } xpmBucket[bucket][xpmBucketSize[bucket]].index = i; strncpy(xpmBucket[bucket][xpmBucketSize[bucket]].s, &color_char[i*chars_per_pixel], chars_per_pixel); (xpmBucketSize[bucket])++; } } return TRUE; } int XPmLookUp(pixel, chars_per_pixel, color_char, pn_color_index_return) int pixel, chars_per_pixel, *pn_color_index_return; char *color_char; { register int i; register struct BucketRec *ptr; int size, bucket; if (chars_per_pixel == INVALID) { /* hash according to the pixels */ bucket = xpmpixelhash(pixel); size = xpmBucketSize[bucket]; for (i = 0, ptr = xpmBucket[bucket]; i < size; i++, ptr++) { if (ptr->pixel == pixel) { if (pn_color_index_return != NULL) { *pn_color_index_return = ptr->color_index; } return (ptr->index); } } } else { /* hash according to the color_char */ bucket = xpmcharhash(chars_per_pixel, color_char); size = xpmBucketSize[bucket]; for (i=0, ptr=xpmBucket[bucket]; i < size; i++, ptr++) { if (strncmp(color_char, ptr->s, chars_per_pixel) == 0) { if (pn_color_index_return != NULL) { *pn_color_index_return = ptr->color_index; } return (ptr->index); } } } return INVALID; } void MakeCachedPixmap(ObjPtr) struct ObjRec *ObjPtr; { register int c, r; int w, h, flip, target_percent; int num_cols, num_rows, image_w, image_h, watch_cursor; int start_col, start_row, do_msg; struct XPmRec *xpm_ptr=ObjPtr->detail.xpm; struct MtrxRec mtrx; Pixmap dest_pixmap=None, dest_bitmap=None; XImage *src_image=NULL, *src_bitmap_image=NULL; XImage *dest_image=NULL, *dest_bitmap_image=NULL; w = ObjPtr->obbox.rbx - ObjPtr->obbox.ltx; h = ObjPtr->obbox.rby - ObjPtr->obbox.lty; num_cols = (zoomedIn) ? (w<<zoomScale) : (w>>zoomScale); num_rows = (zoomedIn) ? (h<<zoomScale) : (h>>zoomScale); if (ObjPtr->ctm==NULL && xpm_ptr->cached_pixmap!=None && xpm_ptr->cached_color!=(-1) && xpm_ptr->cached_color==ObjPtr->color && xpm_ptr->cached_zoomed==zoomedIn && xpm_ptr->cached_zoom==zoomScale && xpm_ptr->cached_w==num_cols && xpm_ptr->cached_h==num_rows && xpm_ptr->cached_flip==xpm_ptr->flip) return; if ((w>>zoomScale)==0 || (h>>zoomScale)==0) { if (xpm_ptr->cached_pixmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_pixmap); } if (xpm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_bitmap); } xpm_ptr->cached_pixmap = None; xpm_ptr->cached_bitmap = None; xpm_ptr->cached_color = (-1); return; } watch_cursor = watchCursorOnMainWindow; if (!watch_cursor && !RedrawDuringScrolling()) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } else { CheckInterrupt(TRUE); } src_image = xpm_ptr->image; src_bitmap_image = xpm_ptr->bitmap_image; flip = xpm_ptr->flip; image_w = xpm_ptr->image_w; image_h = xpm_ptr->image_h; if (xpm_ptr->cached_pixmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_pixmap); } xpm_ptr->cached_pixmap = None; if (xpm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_bitmap); } xpm_ptr->cached_bitmap = None; xpm_ptr->cached_color = (-1); if (xpm_ptr->clip_mask != None) { XFreePixmap(mainDisplay, xpm_ptr->clip_mask); } xpm_ptr->clip_mask = None; if (src_image == NULL) { src_image = xpm_ptr->image = XGetImage(mainDisplay, xpm_ptr->pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); } if (src_bitmap_image == NULL) { src_bitmap_image = xpm_ptr->bitmap_image = XGetImage(mainDisplay, xpm_ptr->bitmap, 0, 0, image_w, image_h, 1, ZPixmap); } do_msg = (((num_rows*num_cols)>=0x4000) && !RedrawDuringScrolling()); if (do_msg) { SaveStatusStrings(); SetStringStatus(TgLoadCachedString(CSTID_CACHING_PIXMAP)); XSync(mainDisplay, False); } dest_pixmap = XCreatePixmap(mainDisplay, dummyPixmap, num_cols, num_rows, mainDepth); dest_bitmap = XCreatePixmap(mainDisplay, dummyBitmap, num_cols, num_rows, 1); XFillRectangle(mainDisplay,dest_pixmap,xpmGC,0,0,num_cols,num_rows); XSetForeground(mainDisplay,xbmGC,1); XFillRectangle(mainDisplay,dest_bitmap,xbmGC,0,0,num_cols,num_rows); XSetForeground(mainDisplay,xbmGC,0); dest_image = XGetImage(mainDisplay, dest_pixmap, 0, 0, num_cols, num_rows, AllPlanes, ZPixmap); dest_bitmap_image = XGetImage(mainDisplay, dest_bitmap, 0, 0, num_cols, num_rows, 1, ZPixmap); if (ObjPtr->ctm == NULL) { mtrx.image_w = (float)image_w; mtrx.image_h = (float)image_h; mtrx.w = (float)num_cols; mtrx.h = (float)num_rows; mtrx.rotate = ROTATE0; mtrx.flip = flip; CalcTransform(&mtrx); start_col = (mtrx.transformed_w >= 0.0) ? 0 : (-num_cols)+1; start_row = (mtrx.transformed_h >= 0.0) ? 0 : (-num_rows)+1; target_percent = 5; for (r=0; r < num_rows; r++) { double part_x, part_y; if (do_msg && ((r & 0xf) == 0)) { int percent=(r*10000/num_rows)/100; if (percent >= target_percent) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_PROGRESS_PERCENT), percent); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); while (target_percent <= percent) target_percent += 5; } } part_x = ((double)(r+start_row)+0.5)*(mtrx.rev_m[1][0]); part_y = ((double)(r+start_row)+0.5)*(mtrx.rev_m[1][1]); for (c=0; c < num_cols; c++) { double x, y; x = part_x+((double)(c+start_col)+0.5)*(mtrx.rev_m[0][0]); y = part_y+((double)(c+start_col)+0.5)*(mtrx.rev_m[0][1]); if (x >= ((double)0) && x < ((double)image_w) && y >= ((double)0) && y < ((double)image_h)) { int new_x=(int)x, new_y=(int)y; if (XGetPixel(src_bitmap_image,new_x,new_y) != 0) { XPutPixel(dest_image, c, r, XGetPixel(src_image,new_x,new_y)); } else { XPutPixel(dest_bitmap_image, c, r, 0); XPutPixel(dest_image, c, r, colorPixels[ObjPtr->color]); } } } } } else { Pixmap clip_mask; XImage *clip_mask_image; int bg_pixel=GetDrawingBgPixel(INVALID, INVALID); int abs_offset_x=ObjPtr->obbox.ltx-ObjPtr->x; int abs_offset_y=ObjPtr->obbox.lty-ObjPtr->y; clip_mask = XCreatePixmap(mainDisplay,dummyBitmap,num_cols,num_rows,1); XSetForeground(mainDisplay, xbmGC, 1); XFillRectangle(mainDisplay, clip_mask, xbmGC, 0, 0, num_cols, num_rows); XSetForeground(mainDisplay, xbmGC, 0); clip_mask_image = XGetImage(mainDisplay, clip_mask, 0, 0, num_cols, num_rows, 1, ZPixmap); target_percent = 5; for (r=0; r < num_rows; r++) { int y=abs_offset_y+ABS_SIZE(r); double dy=((double)y)+0.5; if (do_msg && ((r & 0xf) == 0)) { int percent=(r*10000/num_rows)/100; if (percent >= target_percent) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_PROGRESS_PERCENT), percent); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); while (target_percent <= percent) target_percent += 5; } } for (c=0; c < num_cols; c++) { int x=abs_offset_x+ABS_SIZE(c); double dx=((double)x)+0.5; double new_dx=(double)0, new_dy=(double)0; ReverseTransformDoublePointThroughCTM(dx, dy, ObjPtr->ctm, &new_dx, &new_dy); new_dx += (double)(ObjPtr->x-ObjPtr->orig_obbox.ltx); new_dy += (double)(ObjPtr->y-ObjPtr->orig_obbox.lty); if (new_dx >= ((double)0) && new_dx < ((double)image_w) && new_dy >= ((double)0) && new_dy < ((double)image_h)) { int new_x=(int)new_dx, new_y=(int)new_dy; if (new_x < 0) new_x = 0; if (new_x >= image_w) new_x = image_w-1; if (new_y < 0) new_y = 0; if (new_y >= image_h) new_y = image_h-1; if (XGetPixel(src_bitmap_image,new_x,new_y) != 0) { XPutPixel(dest_image, c, r, XGetPixel(src_image,new_x,new_y)); } else { XPutPixel(clip_mask_image, c, r, 0); XPutPixel(dest_image, c, r, bg_pixel); } } else { XPutPixel(clip_mask_image, c, r, 0); } } } XPutImage(mainDisplay, clip_mask, xbmGC, clip_mask_image, 0, 0, 0, 0, num_cols, num_rows); xpm_ptr->clip_mask = clip_mask; XDestroyImage(clip_mask_image); memcpy(&xpm_ptr->cached_ctm, ObjPtr->ctm, sizeof(struct XfrmMtrxRec)); } if (do_msg) { SetStringStatus(TgLoadCachedString(CSTID_FINISHED_CACHEING_PIXMAP)); XSync(mainDisplay, False); } XPutImage(mainDisplay, dest_pixmap, xpmGC, dest_image, 0, 0, 0, 0, num_cols, num_rows); XPutImage(mainDisplay, dest_bitmap, xbmGC, dest_bitmap_image, 0, 0, 0, 0, num_cols, num_rows); if (do_msg) RestoreStatusStrings(); xpm_ptr->cached_pixmap = dest_pixmap; xpm_ptr->cached_bitmap = dest_bitmap; xpm_ptr->cached_zoomed = zoomedIn; xpm_ptr->cached_zoom = zoomScale; xpm_ptr->cached_flip = xpm_ptr->flip; xpm_ptr->cached_w = num_cols; xpm_ptr->cached_h = num_rows; xpm_ptr->cached_color = ObjPtr->color; if (dest_image != NULL) XDestroyImage(dest_image); if (dest_bitmap_image != NULL) XDestroyImage(dest_bitmap_image); if (!watch_cursor && !RedrawDuringScrolling()) { SetDefaultCursor(mainWindow); ShowCursor(); } else { CheckInterrupt(TRUE); } } int ExtractPixmap(orig_pixmap, orig_image, orig_bitmap, orig_bitmap_image, x, y, w, h, pixmap, image, bitmap, bitmap_image) Pixmap orig_pixmap, orig_bitmap, *pixmap, *bitmap; XImage *orig_image, *orig_bitmap_image, **image, **bitmap_image; int x, y, w, h; { register int j, i; XImage *src_image=NULL, *src_bitmap_image=NULL; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); *pixmap = XCreatePixmap(mainDisplay, dummyPixmap, w, h, mainDepth); *bitmap = XCreatePixmap(mainDisplay, dummyBitmap, w, h, 1); *image = (*pixmap==None ? NULL : XGetImage(mainDisplay, *pixmap, 0, 0, w, h, AllPlanes, ZPixmap)); *bitmap_image = (*bitmap==None ? NULL : XGetImage(mainDisplay, *bitmap, 0, 0, w, h, 1, ZPixmap)); if (orig_image != NULL && x == 0 && y == 0) { src_image = orig_image; } else { src_image = XGetImage(mainDisplay, orig_pixmap, x, y, w, h, AllPlanes, ZPixmap); } if (orig_bitmap_image != NULL && x == 0 && y == 0) { src_bitmap_image = orig_bitmap_image; } else { src_bitmap_image = XGetImage(mainDisplay, orig_bitmap, x, y, w, h, 1, ZPixmap); } if (*pixmap == None || *bitmap == None || *image==NULL || *bitmap_image==NULL || src_image==NULL || src_bitmap_image==NULL) { if (*pixmap == None) { FailAllocPixmapMessage(w, h); } else if (*bitmap == None) { FailAllocBitmapMessage(w, h); } else { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); } if (*pixmap != None) XFreePixmap(mainDisplay, *pixmap); if (*bitmap != None) XFreePixmap(mainDisplay, *bitmap); if (*image != NULL) XDestroyImage(*image); if (*bitmap_image != NULL) XDestroyImage(*bitmap_image); if (orig_image != NULL) XDestroyImage(src_image); if (orig_bitmap_image != NULL) XDestroyImage(src_bitmap_image); if (!(orig_image != NULL && x==0 && y==0) && src_image != NULL) { XDestroyImage(src_image); } if (!(orig_bitmap_image != NULL && x==0 && y==0) && src_bitmap_image != NULL) { XDestroyImage(src_bitmap_image); } *pixmap = *bitmap = None; *image = *bitmap_image = NULL; SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); return FALSE; } for (i = 0; i < h; i++) { for (j = 0; j < w; j++) { XPutPixel(*image, j, i, XGetPixel(src_image, j, i)); XPutPixel(*bitmap_image, j, i, XGetPixel(src_bitmap_image, j, i)); } } XPutImage(mainDisplay, *pixmap, xpmGC, *image, 0, 0, 0, 0, w, h); XPutImage(mainDisplay, *bitmap, xbmGC, *bitmap_image, 0, 0, 0, 0, w, h); SetDefaultCursor(mainWindow); SetDefaultCursor(drawWindow); if (!(orig_image != NULL && x == 0 && y == 0)) XDestroyImage(src_image); if (!(orig_bitmap_image != NULL && x == 0 && y == 0)) { XDestroyImage(src_bitmap_image); } return TRUE; } struct ObjRec *CutXPixmap(ObjPtrToCut, pAbsX, pAbsY, pAbsW, pAbsH) struct ObjRec *ObjPtrToCut; /* if NULL, use topSel->obj */ int *pAbsX, *pAbsY, *pAbsW, *pAbsH; /* * if (ObjPtrToCut != NULL) { * return new_obj_ptr if cut was done successfully * return ObjPtrToCut if there is no need to cut anything * return NULL if something is wrong and object needs to be deleted * } * Note: if ObjPtrToCut is not NULL, then ObjPtrToCut is topSel->obj and * it's called from CropImage() with topSel->obj->ctm != NULL * with fullTrueColorMode == TRUE && HasZlibSupport() == TRUE */ { register int j, i; int w, h, chars_per_pixel, ncolors=0, *pixels=NULL, len; int ltx, lty, rbx, rby, new_w, new_h; int src_x=0, src_y=0, src_w=0, src_h=0, image_w=0, image_h=0; char *color_char, **color_str; float h_scale=1.0, v_scale=1.0, mag=1.0; Pixmap dest_pixmap=None, dest_bitmap=None; XImage *dest_image=NULL, *dest_bitmap_image=NULL; struct ObjRec *obj_ptr=topSel->obj, *new_obj_ptr=NULL; struct XPmRec *xpm_ptr=obj_ptr->detail.xpm, *new_xpm_ptr=NULL; src_x = 0; src_y = 0; if (ObjPtrToCut != NULL && pAbsX != NULL && pAbsY != NULL && pAbsW != NULL && pAbsH != NULL) { obj_ptr = ObjPtrToCut; xpm_ptr = obj_ptr->detail.xpm; image_w = xpm_ptr->image_w; image_h = xpm_ptr->image_h; src_x = *pAbsX; src_y = *pAbsY; src_w = *pAbsW; src_h = *pAbsH; if (src_x==0 && src_y==0 && src_w==image_w && src_h==image_h && mag==1.0) { return obj_ptr; } if (src_w==0 || src_h==0) { MsgBox(TgLoadString(STID_XPM_CANT_HAVE_0_W_OR_H), TOOL_NAME, INFO_MB); return NULL; } } else { src_w = image_w = xpm_ptr->image_w; src_h = image_h = xpm_ptr->image_h; mag = 1.0; h_scale = ((float)((float)(obj_ptr->obbox.rbx-obj_ptr->obbox.ltx)) / ((float)image_w)); v_scale = ((float)((float)(obj_ptr->obbox.rby-obj_ptr->obbox.lty)) / ((float)image_h)); if (pAbsX == NULL && pAbsY == NULL && pAbsW == NULL && pAbsH == NULL) { char mag_spec[MAXSTRING]; sprintf(gszMsgBox, TgLoadString(STID_ENTER_GEOM_SPEC_ORIG_SIZE), image_w, image_h); *mag_spec = '\0'; Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), mag_spec); UtilTrimBlanks(mag_spec); if (*mag_spec == '\0') return obj_ptr; ParseCutSpec(mag_spec, image_w, image_h, &mag, &src_x, &src_y, &src_w, &src_h); } else { src_x = *pAbsX; src_y = *pAbsY; src_w = *pAbsW; src_h = *pAbsH; } if (src_x==0 && src_y==0 && src_w==image_w && src_h==image_h && mag==1.0) { return obj_ptr; } if (src_w==0 || src_h==0) { MsgBox(TgLoadString(STID_XPM_CANT_HAVE_0_W_OR_H), TOOL_NAME, INFO_MB); return NULL; } PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); } if (!ExtractPixmap(xpm_ptr->pixmap, xpm_ptr->image, xpm_ptr->bitmap, xpm_ptr->bitmap_image, src_x, src_y, src_w, src_h, &dest_pixmap, &dest_image, &dest_bitmap, &dest_bitmap_image)) { if (ObjPtrToCut == NULL || pAbsX == NULL || pAbsY == NULL || pAbsW == NULL || pAbsH == NULL) { AbortPrepareCmd(CMD_REPLACE); } return NULL; } if ((xpm_ptr->real_type == XPM_JPEG || xpm_ptr->real_type == PPM_TRUE) && fullTrueColorMode && HasZlibSupport()) { char tmp_fname[MAXPATHLENGTH]; if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { if (ObjPtrToCut == NULL || pAbsX == NULL || pAbsY == NULL || pAbsW == NULL || pAbsH == NULL) { AbortPrepareCmd(CMD_REPLACE); } return NULL; } if (DumpXImageToPpmFile(dest_image, src_w, src_h, tmp_fname, TRUE)) { char deflated_fname[MAXPATHLENGTH]; unsigned int data_size=0; char *ppm_data=NULL; snprintf(deflated_fname, sizeof(deflated_fname), "%s.ppm.z", tmp_fname); ppm_data = ReadFileIntoBuf(deflated_fname, &data_size); unlink(deflated_fname); unlink(tmp_fname); if (ppm_data) { new_obj_ptr = CreatePpmTrueObjFromImage(dest_image, src_w, src_h, ppm_data, data_size); } } XFreePixmap(mainDisplay, dest_pixmap); XFreePixmap(mainDisplay, dest_bitmap); XDestroyImage(dest_image); XDestroyImage(dest_bitmap_image); dest_pixmap = dest_bitmap = None; dest_image = dest_bitmap_image = NULL; if (new_obj_ptr == NULL) { if (ObjPtrToCut == NULL || pAbsX == NULL || pAbsY == NULL || pAbsW == NULL || pAbsH == NULL) { AbortPrepareCmd(CMD_REPLACE); } return NULL; } MoveObj(new_obj_ptr, obj_ptr->x, obj_ptr->y); } sprintf(gszMsgBox, TgLoadCachedString(CSTID_NEW_XPM_SIZE_IS_W_X_H), src_w, src_h); Msg(gszMsgBox); if (ObjPtrToCut != NULL && pAbsX != NULL && pAbsY != NULL && pAbsW != NULL && pAbsH != NULL) { return new_obj_ptr; } else { UnlinkObj(obj_ptr); ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); w = new_w = (int)(((float)src_w) * mag); h = new_h = (int)(((float)src_h) * mag); } if (new_obj_ptr == NULL) { new_obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (new_obj_ptr == NULL) FailAllocMessage(); memset(new_obj_ptr, 0, sizeof(struct ObjRec)); DupObjBasics(obj_ptr, new_obj_ptr); new_xpm_ptr = (struct XPmRec *)malloc(sizeof(struct XPmRec)); if (new_xpm_ptr == NULL) FailAllocMessage(); memset(new_xpm_ptr, 0, sizeof(struct XPmRec)); new_obj_ptr->detail.xpm = new_xpm_ptr; new_xpm_ptr->image_w = src_w; new_xpm_ptr->image_h = src_h; new_xpm_ptr->pixmap = dest_pixmap; new_xpm_ptr->image = dest_image; new_xpm_ptr->bitmap = dest_bitmap; new_xpm_ptr->bitmap_image = dest_bitmap_image; new_xpm_ptr->data = NULL; new_xpm_ptr->fill = xpm_ptr->fill; new_xpm_ptr->flip = xpm_ptr->flip; new_xpm_ptr->cached_zoom = 0; new_xpm_ptr->cached_pixmap = None; new_xpm_ptr->cached_bitmap = None; new_xpm_ptr->cached_flip = 0; new_xpm_ptr->cached_w = 0; new_xpm_ptr->cached_h = 0; new_xpm_ptr->cached_color = (-1); chars_per_pixel = new_xpm_ptr->chars_per_pixel = xpm_ptr->chars_per_pixel; new_xpm_ptr->first_pixel_is_bg = xpm_ptr->first_pixel_is_bg; ncolors = new_xpm_ptr->ncolors = xpm_ptr->ncolors; color_char = new_xpm_ptr->color_char = (char*)malloc((ncolors*chars_per_pixel)*sizeof(char)); if (color_char == NULL) FailAllocMessage(); color_str = new_xpm_ptr->color_str = (char**)malloc(ncolors*sizeof(char*)); if (color_str == NULL) FailAllocMessage(); pixels = new_xpm_ptr->pixels = (int*)malloc(ncolors*sizeof(int)); if (pixels == NULL) FailAllocMessage(); for (i = 0; i < ncolors; i++) { pixels[i] = xpm_ptr->pixels[i]; for (j = 0; j < chars_per_pixel; j++) { color_char[i*chars_per_pixel+j] = xpm_ptr->color_char[i*chars_per_pixel+j]; } len = strlen(xpm_ptr->color_str[i]); color_str[i] = (char*)malloc((len+1)*sizeof(char)); if (color_str[i] == NULL) FailAllocMessage(); strcpy(color_str[i], xpm_ptr->color_str[i]); } new_w = round(h_scale * ((float)w)); new_h = round(v_scale * ((float)h)); new_obj_ptr->obbox.ltx = obj_ptr->obbox.ltx; new_obj_ptr->obbox.lty = obj_ptr->obbox.lty; new_obj_ptr->obbox.rbx = new_obj_ptr->bbox.rbx = obj_ptr->obbox.ltx+new_w; new_obj_ptr->obbox.rby = new_obj_ptr->bbox.rby = obj_ptr->obbox.lty+new_h; AdjObjBBox(new_obj_ptr); } topSel->obj = botSel->obj = new_obj_ptr; AddObj(NULL, topObj, new_obj_ptr); if (pAbsX != NULL && pAbsY != NULL) { MoveObj(new_obj_ptr, *pAbsX, *pAbsY); } RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); FreeObj(obj_ptr); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; return new_obj_ptr; } static void SaveXPmColors(FP, def_color_index, xpm_ptr, ncolors, chars_per_pixel, color_char, color_str, pixels) FILE *FP; int def_color_index, ncolors, chars_per_pixel, *pixels; struct XPmRec *xpm_ptr; char *color_char, **color_str; { register int i, j; int cur_pixel, found_index; if (!colorDisplay && xpm_ptr->red != NULL) { for (i=0; i < ncolors; i++) { if (fprintf(FP, " \"") == EOF) writeFileFailed = TRUE; for (j=0; j < chars_per_pixel; j++) { if (fprintf(FP, "%c", color_char[i*chars_per_pixel+j]) == EOF) { writeFileFailed = TRUE; } } if (i == ncolors-1) { if (fprintf(FP, "\", \"%s\", %1d, %1d, %1d],[\n", color_str[i], (int)(xpm_ptr->red[i]), (int)(xpm_ptr->green[i]), (int)(xpm_ptr->blue[i])) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(FP, "\", \"%s\", %1d, %1d, %1d,\n", color_str[i], (int)(xpm_ptr->red[i]), (int)(xpm_ptr->green[i]), (int)(xpm_ptr->blue[i])) == EOF) { writeFileFailed = TRUE; } } } } else { for (i=0; i < ncolors; i++) { found_index = def_color_index; cur_pixel = pixels[i]; if (cur_pixel != (-1)) { for (j=0; j < maxColors; j++) { if (colorPixels[j] == cur_pixel) { found_index = j; break; } } } if (fprintf(FP, " \"") == EOF) writeFileFailed = TRUE; for (j = 0; j < chars_per_pixel; j++) { if (fprintf(FP, "%c", color_char[i*chars_per_pixel+j]) == EOF) { writeFileFailed = TRUE; } } if (i == ncolors-1) { if (fprintf(FP, "\", \"%s\", %1d, %1d, %1d],[\n", color_str[i], (int)(10000*((int)tgifColors[found_index].red)/maxRGB), (int)(10000*((int)tgifColors[found_index].green)/maxRGB), (int)(10000*((int)tgifColors[found_index].blue)/maxRGB)) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(FP, "\", \"%s\", %1d, %1d, %1d,\n", color_str[i], (int)(10000*((int)tgifColors[found_index].red)/maxRGB), (int)(10000*((int)tgifColors[found_index].green)/maxRGB), (int)(10000*((int)tgifColors[found_index].blue)/maxRGB)) == EOF) { writeFileFailed = TRUE; } } } } } static void PrTgifDumpOldXPmObj(FP, ObjPtr, pmtrx) FILE *FP; struct ObjRec *ObjPtr; struct MtrxRec *pmtrx; { int row=0, i=0, index=0, col=0, j=0, num_nibbles=0, nibble_count=0; int ltx=0, lty=0, rbx=0, rby=0, w=0, h=0, image_w=0, image_h=0; int ncolors=0, *pixels=NULL, flip=0, orig_x=0, orig_y=0; int chars_per_pixel=0, x=0, y=0; int h_blocks=0, v_blocks=0, block_w=0, block_h=0, bit_count=0, data=0; char *xpm_data=NULL, bg_char[2]; Pixmap pixmap, bitmap=(Pixmap)0; struct XPmRec *xpm_ptr=NULL; bg_char[0] = bg_char[1] = '\0'; ltx = ObjPtr->obbox.ltx; lty = ObjPtr->obbox.lty; rbx = ObjPtr->obbox.rbx; rby = ObjPtr->obbox.rby; xpm_ptr = ObjPtr->detail.xpm; pixmap = xpm_ptr->pixmap; bitmap = xpm_ptr->bitmap; pixels = xpm_ptr->pixels; ncolors = xpm_ptr->ncolors; flip = xpm_ptr->flip; image_w = xpm_ptr->image_w; image_h = xpm_ptr->image_h; w = rbx - ltx; h = rby - lty; orig_x = (pmtrx->transformed_w >= 0.0) ? ltx : ltx+w; orig_y = (pmtrx->transformed_h >= 0.0) ? lty : lty+h; xpm_data = xpm_ptr->data; chars_per_pixel = xpm_ptr->chars_per_pixel; fprintf(stderr, "%s\n", TgLoadString(STID_WARN_XPM_ALL_NON_BG_BE_BLACK)); switch (chars_per_pixel) { case 1: bg_char[0] = xpm_ptr->color_char[0]; bg_char[1] = '\0'; if (*bg_char != '`' && *bg_char != ' ') { bg_char[0] = bg_char[1] = '\0'; } break; case 2: bg_char[0] = xpm_ptr->color_char[0]; bg_char[1] = xpm_ptr->color_char[1]; if (!(bg_char[0] == '`' && bg_char[1] == '`') && !(bg_char[0] == ' ' && bg_char[1] == ' ')) { bg_char[0] = '\0'; } break; } h_blocks = ((image_w&0xff) == 0) ? (image_w>>8) : ((image_w>>8)+1); v_blocks = ((image_h&0xff) == 0) ? (image_h>>8) : ((image_h>>8)+1); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); fprintf(FP, " %1d %1d %s %.3f %.3f %s %1d %s\n\n", orig_x, orig_y, gPsCmd[PS_TRANSLATE], pmtrx->dump_h_scale, pmtrx->dump_v_scale, gPsCmd[PS_SCALE], pmtrx->degree, gPsCmd[PS_ROTATE]); for (row=0; row < v_blocks; row++) { y = row<<8; block_h = (row == v_blocks-1) ? image_h-y : 0x100; for (col=0; col < h_blocks; col++) { x = col<<8; block_w = (col == h_blocks-1) ? image_w-x : 0x100; num_nibbles = ((block_w%4) == 0) ? (int)(block_w>>2) : (int)(block_w>>2)+1; fprintf(FP, " %s\n", gPsCmd[PS_GSAVE]); fprintf(FP, " %1d %1d %s\n", x, y, gPsCmd[PS_TRANSLATE]); fprintf(FP, " %1d %1d true [1 0 0 1 0 0]\n {<", block_w, block_h); nibble_count = 0; for (i=0; i < block_h; i++) { bit_count = 0; data = 0; for (j=0; j < block_w; j++) { switch (chars_per_pixel) { case 1: data = (xpm_data[(i+y)*image_w+j+x] != *bg_char) ? (data<<1) | 1 : (data<<1); break; case 2: index = ((i+y)*image_w+j+x)*chars_per_pixel; data = (xpm_data[index] == bg_char[0] && xpm_data[index+1] == bg_char[1]) ? (data<<1) : (data<<1) | 1; break; } if (++bit_count == 4) { if (nibble_count++ == 64) { nibble_count = 1; fprintf(FP, "\n "); } fprintf(FP, "%c", hexValue[data]); bit_count = 0; data = 0; } } if ((block_w % 4) != 0) { data <<= (4 - (block_w % 4)); if (nibble_count++ == 64) { nibble_count = 1; fprintf(FP, "\n "); } fprintf(FP, "%c", hexValue[data]); } if ((num_nibbles & 0x1) == 1) { if (nibble_count++ == 64) { nibble_count = 1; fprintf(FP, "\n "); } fprintf(FP, "0"); } } fprintf(FP, ">}\n"); fprintf(FP, " %s\n", gPsCmd[PS_IMAGEMASK]); fprintf(FP, " %s\n", gPsCmd[PS_GRESTORE]); if (row!=v_blocks-1 || col!=h_blocks-1) fprintf(FP, "\n"); } } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); } static int MalformedPpmMessage(tmp_fname) char *tmp_fname; { sprintf(gszMsgBox, TgLoadString(STID_CANT_IMPORT_GIVEN_PPM_MALFORM), tmp_fname); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } static int ReadPpmHeaderStr(ppm_fp, tmp_fname, buf, sz_buf) FILE *ppm_fp; char *tmp_fname, *buf; int sz_buf; { int i=0, write_index=0; for (i=0; i < sz_buf-1; i++) { char ch='\0'; if (fread(&ch, sizeof(char), 1, ppm_fp) != 1) { /* failed */ break; } if (i == 0 && ch == '#') { /* skip a comment line */ char *line_buf=UtilGetALine(ppm_fp); if (line_buf != NULL) { UtilFree(line_buf); i = (-1); } else { break; } } else if (ch == ' ' || ch == '\t' || ch == '\n' || ch == '\r') { if (write_index != 0) { buf[write_index++] = '\0'; return TRUE; } } else { buf[write_index++] = ch; } } return MalformedPpmMessage(tmp_fname); } static int ReadPpmHeader(ppm_fp, tmp_fname, pn_format, pn_w, pn_h, pn_max_val) FILE *ppm_fp; char *tmp_fname; int *pn_format, *pn_w, *pn_h, *pn_max_val; { char buf[MAXSTRING]; if (!ReadPpmHeaderStr(ppm_fp, tmp_fname, buf, sizeof(buf))) { return FALSE; } if (strcmp(buf, "P3") == 0) { if (pn_format != NULL) *pn_format = TYPE_PPM3; } else if (strcmp(buf, "P6") == 0) { if (pn_format != NULL) *pn_format = TYPE_PPM6; } else if (strcmp(buf, "P5") == 0) { if (pn_format != NULL) *pn_format = TYPE_PPM5; } else { return MalformedPpmMessage(tmp_fname); } if (!ReadPpmHeaderStr(ppm_fp, tmp_fname, buf, sizeof(buf))) { return FALSE; } if (sscanf(buf, "%d", pn_w) != 1) { return MalformedPpmMessage(tmp_fname); } if (!ReadPpmHeaderStr(ppm_fp, tmp_fname, buf, sizeof(buf))) { return FALSE; } if (sscanf(buf, "%d", pn_h) != 1) { return MalformedPpmMessage(tmp_fname); } if (!ReadPpmHeaderStr(ppm_fp, tmp_fname, buf, sizeof(buf))) { return FALSE; } if (sscanf(buf, "%d", pn_max_val) != 1) { return MalformedPpmMessage(tmp_fname); } return TRUE; } static void DumpPpm6File(FP, image_w, image_h, tmp_fname) FILE *FP; int image_w, image_h; char *tmp_fname; { FILE *ppm_fp=fopen(tmp_fname, "r"); int format=0, w=0, h=0, max_val=0, row=0, col=0; if (ppm_fp == NULL) { FailToOpenMessage(tmp_fname, "r", NULL); return; } if (!ReadPpmHeader(ppm_fp, tmp_fname, &format, &w, &h, &max_val)) { fclose(ppm_fp); return; } if (w != image_w || h != image_h) { sprintf(gszMsgBox, TgLoadString(STID_PPM6_DIM_NOT_MATCH), w, h, tmp_fname, image_w, image_h); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } fclose(ppm_fp); return; } if (max_val != 255 && max_val != 65535) { sprintf(gszMsgBox, TgLoadString(STID_UNSUP_PPM6_MAX_VAL), max_val, tmp_fname); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } fclose(ppm_fp); return; } for (row=0; row < image_h; row++) { for (col=0; col < image_w; col++) { unsigned char buf[4]; if (format == TYPE_PPM6) { if (max_val == 65535) { unsigned char r_buf[2], g_buf[2], b_buf[2]; if (fread(r_buf, sizeof(char), 2, ppm_fp) != 2 || fread(g_buf, sizeof(char), 2, ppm_fp) != 2 || fread(b_buf, sizeof(char), 2, ppm_fp) != 2) { MalformedPpmMessage(tmp_fname); fclose(ppm_fp); return; } if (littleEndianPpm6) { buf[0] = r_buf[1]; buf[1] = g_buf[1]; buf[2] = b_buf[1]; } else { buf[0] = r_buf[0]; buf[1] = g_buf[0]; buf[2] = b_buf[0]; } } else { if (fread(buf, sizeof(char), 3, ppm_fp) != 3) { MalformedPpmMessage(tmp_fname); fclose(ppm_fp); return; } } } else if (format == TYPE_PPM5) { if (max_val == 65535) { unsigned char g_buf[2]; if (fread(g_buf, sizeof(char), 2, ppm_fp) != 2) { MalformedPpmMessage(tmp_fname); fclose(ppm_fp); return; } if (littleEndianPpm6) { buf[0] = buf[1] = buf[2] = g_buf[1]; } else { buf[0] = buf[1] = buf[2] = g_buf[0]; } } else { if (fread(buf, sizeof(char), 1, ppm_fp) != 1) { MalformedPpmMessage(tmp_fname); fclose(ppm_fp); return; } buf[1] = buf[2] = buf[0]; } } else { int red=0, green=0, blue=0; if (fscanf(FP, "%d %d %d", &red, &green, &blue) != 3) { MalformedPpmMessage(tmp_fname); fclose(ppm_fp); return; } buf[0] = (unsigned char)(red & 0x0ff); buf[1] = (unsigned char)(green & 0x0ff); buf[2] = (unsigned char)(blue & 0x0ff); } buf[3] = '\0'; if (!colorDump) { double dr=(double)0, dg=(double)0, db=(double)0, dgray=(double)0; int igray=0; dr = (double)(unsigned int)(buf[0]); dg = (double)(unsigned int)(buf[1]); db = (double)(unsigned int)(buf[2]); dgray = (0.299*dr)+(0.587*dg)+(0.114*db); igray = round(dgray); if (igray > 255) igray = 255; if (igray < 0) igray = 0; buf[0] = buf[1] = buf[2] = (unsigned char)(igray & 0x0ff); } fprintf(FP, "%02x%02x%02x", (unsigned int)(buf[0]), (unsigned int)(buf[1]), (unsigned int)(buf[2])); if (col%12 == 11) fprintf(FP, "\n "); } if (col%12 != 11) fprintf(FP, "\n"); if (row != image_h-1) fprintf(FP, " "); } fclose(ppm_fp); } static int ObjHasXpmObj(ObjPtr) struct ObjRec *ObjPtr; { switch (ObjPtr->type) { case OBJ_XPM: if (!colorLayers || ObjInVisibleLayer(ObjPtr)) { return TRUE; } return FALSE; case OBJ_SYM: case OBJ_ICON: case OBJ_GROUP: if (!colorLayers || ObjInVisibleLayer(ObjPtr)) { struct ObjRec *obj_ptr=ObjPtr->detail.r->last; for ( ; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = ObjPtr; if (ObjHasXpmObj(obj_ptr)) return TRUE; } return TRUE; } return FALSE; case OBJ_PIN: if (!colorLayers || ObjInVisibleLayer(ObjPtr)) { struct ObjRec *obj_ptr=GetPinObj(ObjPtr); for ( ; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = ObjPtr; if (ObjHasXpmObj(obj_ptr)) return TRUE; } return TRUE; } return FALSE; default: break; } return FALSE; } static int PageHasXpmObj(page_ptr) struct PageRec *page_ptr; { struct ObjRec *obj_ptr=NULL; for (obj_ptr=page_ptr->bot; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (ObjHasXpmObj(obj_ptr)) return TRUE; } return FALSE; } static int FileHasXpmObj() { struct PageRec *page_ptr=NULL; for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next) { if (PageHasXpmObj(page_ptr)) return TRUE; } return FALSE; } static void HashAllColorPixels() { int i=0; for (i=0; i < maxColors; i++) { int pixel=colorPixels[i]; HashStoreInt(&gColorsHashForPrinting, (char*)(&pixel), sizeof(int), i); } } void CleanUpCachedColorsForPrinting() { if (gnColorsHashForPrintingValid) { CleanUpHash(&gColorsHashForPrinting); gnColorsHashForPrintingValid = FALSE; } } void CacheColorsForPrinting() { XColor *saved_tgif_colors=tgifColors; if (PRTGIF && !cmdLineOpenDisplay) return; if (!FileHasXpmObj()) return; gnColorsHashForPrintingValid = TRUE; InitHash(&gColorsHashForPrinting, TG_HASH_SIZE_LARGE); if (printUsingRequestedColor) tgifColors = tgifRequestedColors; HashAllColorPixels(); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; } typedef struct tagImagePixelInfo { int image_w, image_h; int **image_pixels; /* * transparent is not used for now because the only to create a pixmap * object with too many colors is to import a XPM object * we assume that people just use JPEG and GIF import */ unsigned char **transparent; } ImagePixelInfo; static void FreeImagePixels(pipi) ImagePixelInfo *pipi; { int row=0, image_h=pipi->image_h; int **image_pixels=NULL; unsigned char **transparent=NULL; if (pipi == NULL) return; image_pixels = pipi->image_pixels; transparent = pipi->transparent; if (image_pixels != NULL) { for (row=0; row < image_h; row++) { if (image_pixels[row] != NULL) free(image_pixels[row]); } free(image_pixels); } if (transparent != NULL) { for (row=0; row < image_h; row++) { if (transparent[row] != NULL) free(transparent[row]); } free(transparent); } memset(pipi, 0, sizeof(ImagePixelInfo)); } static void SetAColorByteInfoByXpmRGB(pcb, xpm_ptr, pixel_index) ColorBytes *pcb; struct XPmRec *xpm_ptr; int pixel_index; { double red=0, green=0, blue=0; int r=0, g=0, b=0; red = ((double)255) * ((double)(xpm_ptr->red[pixel_index])) / ((double)10000.0); green = ((double)255) * ((double)(xpm_ptr->green[pixel_index])) / ((double)10000.0); blue = ((double)255) * ((double)(xpm_ptr->blue[pixel_index])) / ((double)10000.0); r = round(red); g = round(green); b = round(blue); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; if (r < 0) r = 0; if (g < 0) g = 0; if (b < 0) b = 0; pcb->r = (unsigned char)(r & 0x0ff); pcb->g = (unsigned char)(g & 0x0ff); pcb->b = (unsigned char)(b & 0x0ff); pcb->valid = TRUE; } static void SetAColorByteByXpmRGB(pcb, xpm_ptr, index, table_size) ColorBytes *pcb; struct XPmRec *xpm_ptr; int index, table_size; { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(index >= 0 && index < table_size, "index out of range in SetAColorByteByXpmRGB()", NULL); #endif /* _TGIF_DBG */ if (pcb[index].valid) return; SetAColorByteInfoByXpmRGB(&pcb[index], xpm_ptr, index); } static void SetAColorByteByMaxRGB(pcb, xpm_color_index, global_color_index, table_size) ColorBytes *pcb; int xpm_color_index, global_color_index, table_size; { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(xpm_color_index >= 0 && xpm_color_index < table_size, "xpm_color_index out of range in SetAColorByteByXpmRGB()", NULL); #endif /* _TGIF_DBG */ if (pcb[xpm_color_index].valid) return; SetAColorByteInfo(&pcb[xpm_color_index], &tgifColors[global_color_index]); } int ConvertPpmTrueToPpm6(ppm_data, ppm_data_size, ppm_data_compress, tmp_ppm6_fname, tmp_ppm6_sz) char *ppm_data, *tmp_ppm6_fname; int ppm_data_size, ppm_data_compress, tmp_ppm6_sz; { *tmp_ppm6_fname = '\0'; if (ppm_data_compress == PPM_JPEG_COMPRESS) { char jpeg_fname[MAXPATHLENGTH+1]; if (!WriteBufIntoTmpFile(ppm_data, ppm_data_size, jpeg_fname, sizeof(jpeg_fname))) { return FALSE; } if (!ConvertJpegToPpm6(jpeg_fname, tmp_ppm6_fname, tmp_ppm6_sz)) { unlink(jpeg_fname); return FALSE; } unlink(jpeg_fname); } else if (ppm_data_compress == PPM_DATA_DEFLATED) { FILE *fp=NULL; int rc=0; if (MkTempFile(tmp_ppm6_fname, tmp_ppm6_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } if ((fp=fopen(tmp_ppm6_fname, "w")) == NULL) { FailToOpenMessage(tmp_ppm6_fname, "w", NULL); return FALSE; } if (!DoInflate(ppm_data, ppm_data_size, fp, FALSE, &rc)) { fclose(fp); unlink(tmp_ppm6_fname); ZlibError(rc, FALSE); return FALSE; } fclose(fp); } return TRUE; } static int GetImagePixels(ObjPtr, xpm_ptr, pipi, pxtii, pcb) struct ObjRec *ObjPtr; struct XPmRec *xpm_ptr; ImagePixelInfo *pipi; XpmTransIndexInfo *pxtii; ColorBytes *pcb; /* * can only get here if the object has too many colors and colorDump * also, this object canont have transparent pixels */ { int row=0, image_w=xpm_ptr->image_w, image_h=xpm_ptr->image_h; int chars_per_pixel=0, pixel_index=0; int ncolors=0; char *xpm_data=NULL, *color_char=NULL; Pixmap pixmap=(Pixmap)0, bitmap=(Pixmap)0; XImage *image=NULL, *bitmap_image=NULL; memset(pipi, 0, sizeof(ImagePixelInfo)); if (image_h == 0) return FALSE; pixmap = xpm_ptr->pixmap; bitmap = xpm_ptr->bitmap; if ((!PRTGIF || cmdLineOpenDisplay) && (image=xpm_ptr->image) == NULL) { if ((image=xpm_ptr->image=XGetImage(mainDisplay, pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap)) == NULL) { Msg(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM)); return FALSE; } } if ((!PRTGIF || cmdLineOpenDisplay) && (bitmap_image=xpm_ptr->bitmap_image) == NULL) { if ((bitmap_image=xpm_ptr->bitmap_image=XGetImage(mainDisplay, bitmap, 0, 0, image_w, image_h, 1, ZPixmap)) == NULL) { Msg(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM)); return FALSE; } } pipi->image_pixels = (int**)malloc(image_h*sizeof(int*)); pipi->transparent = (unsigned char **)malloc(image_h*sizeof(unsigned char *)); if (pipi->image_pixels == NULL || pipi->transparent == NULL) { FailAllocMessage(); } memset(pipi->image_pixels, 0, image_h*sizeof(int*)); memset(pipi->transparent, 0, image_h*sizeof(unsigned char *)); for (row=0; row < image_h; row++) { pipi->image_pixels[row] = (int*)malloc(image_w*sizeof(int)); pipi->transparent[row] = (unsigned char *)malloc(image_w*sizeof(unsigned char)); if (pipi->image_pixels[row] == NULL || pipi->transparent[row] == NULL) { FailAllocMessage(); } memset(pipi->image_pixels[row], 0, image_w*sizeof(int)); memset(pipi->transparent[row], 0, image_w*sizeof(unsigned char)); } ncolors = xpm_ptr->ncolors; xpm_data = xpm_ptr->data; chars_per_pixel = xpm_ptr->chars_per_pixel; color_char = xpm_ptr->color_char; for (row=0; row < image_h; row++) { int col=0; for (col=0; col < image_w; col++) { int transparent_pixel=INVALID; #ifdef NOT_DEFINED float gray=(float)0; int value=0; #endif /* NOT_DEFINED */ if (PRTGIF && !cmdLineOpenDisplay) { /* this works! */ pixel_index = XPmLookUp(INVALID, chars_per_pixel, &(xpm_data[(row*image_w+col)*chars_per_pixel]), NULL); SetAColorByteByXpmRGB(pcb, xpm_ptr, pixel_index, ncolors+3); if (!pxtii->has_transparent_pixel) { if (!colorDump) { /* should never get here */ #ifdef NOT_DEFINED gray = 0.299*((float)xpm_ptr->red[pixel_index]/10000.0) + 0.587*((float)xpm_ptr->green[pixel_index]/10000.0) + 0.114*((float)xpm_ptr->blue[pixel_index]/10000.0); value = gray*256; pixel_index = ((value>255) ? 255 : ((value<0) ? 0 : value)); #endif /* NOT_DEFINED */ } else { if (pxtii->has_transparent_pixel && pxtii->found_transparent_pixel && pxtii->transparent_pixel_index == pixel_index) { pipi->transparent[row][col] = TRUE; } } } else { /* should never get here */ if (pxtii->has_transparent_pixel && pxtii->found_transparent_pixel && pxtii->transparent_pixel_index == pixel_index) { pipi->transparent[row][col] = TRUE; } } } else { if (colorDump || pxtii->has_transparent_pixel) { if (!colorDisplay && xpm_ptr->red != NULL) { pixel_index = XPmLookUp(INVALID, chars_per_pixel, &(xpm_data[(row*image_w+col)*chars_per_pixel]), NULL); SetAColorByteByXpmRGB(pcb, xpm_ptr, pixel_index, ncolors+3); } else if (XGetPixel(bitmap_image,col,row) != 0) { /* this works! */ int pixel=XGetPixel(image,col,row), global_color_index=(-1); pixel_index = XPmLookUp(pixel, INVALID, NULL, NULL); if (HashLookUpInt(&gColorsHashForPrinting, (char*)(&pixel), sizeof(int), &global_color_index)) { SetAColorByteByMaxRGB(pcb, pixel_index, global_color_index, ncolors+3); } else { } } else { /* transparent pixel */ pixel_index = XPmLookUp((-1), INVALID, NULL, NULL); transparent_pixel = pixel_index; } if (pxtii->has_transparent_pixel && pxtii->found_transparent_pixel && pxtii->transparent_pixel_index == pixel_index) { pipi->transparent[row][col] = TRUE; } } else { /* should never get here */ #ifdef NOT_DEFINED if (!colorDisplay && xpm_ptr->red != NULL) { pixel_index = XPmLookUp(INVALID, chars_per_pixel, &(xpm_data[(row*image_w+col)*chars_per_pixel]), NULL); gray = 0.299*((float)xpm_ptr->red[pixel_index]/10000.0) + 0.587*((float)xpm_ptr->green[pixel_index]/10000.0) + 0.114*((float)xpm_ptr->blue[pixel_index]/10000.0); } else { int cur_pixel=0, found_index=0; if (XGetPixel(bitmap_image, col, row) != 0) { cur_pixel = XGetPixel(image, col, row); } else { found_index = ObjPtr->color; cur_pixel = (-1); } if (cur_pixel != (-1)) { int i=0; for (i=0; i < maxColors; i++) { if (colorPixels[i] == cur_pixel) { found_index = i; break; } } } gray = 0.299*((float)tgifColors[found_index].red/maxRGB) + 0.587*((float)tgifColors[found_index].green/maxRGB) + 0.114*((float)tgifColors[found_index].blue/maxRGB); SetAColorByteByMaxRGB(pcb, pixel_index, ncolors+3); } value = gray*256; pixel_index = ((value>255) ? 255 : ((value<0) ? 0 : value)); #endif /* NOT_DEFINED */ } } pipi->image_pixels[row][col] = pixel_index; } } return TRUE; } static int PrepareColorsForConvertObjToPpm6(xpm_ptr, pxtii) struct XPmRec *xpm_ptr; XpmTransIndexInfo *pxtii; { int index=0, ncolors=xpm_ptr->ncolors; int chars_per_pixel=xpm_ptr->chars_per_pixel; char *color_char=xpm_ptr->color_char; int *pixels=xpm_ptr->pixels; if (colorDump) { if ((PRTGIF && !cmdLineOpenDisplay) || (!colorDisplay && xpm_ptr->red != NULL)) { if (!BuildXPmBuckets(ncolors, NULL, NULL, chars_per_pixel, color_char, pxtii)) { return FALSE; } for (index=0; index < ncolors; index++) { if (xpm_ptr->red[index] == (-1)) { if (pxtii->has_transparent_pixel) { if (pxtii->found_transparent_pixel) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "Found transparent pixel again in PrepareColorsForConvertObjToPpm6()", NULL); #endif /* _TGIF_DBG */ } else { pxtii->found_transparent_pixel = TRUE; pxtii->transparent_pixel_index = index; } } } } } else { /* interactive printing */ pxtii->dump_index_to_color_index = (int*)malloc((maxColors+3)*sizeof(int)); if (pxtii->dump_index_to_color_index == NULL) FailAllocMessage(); for (index=0; index < maxColors+3; index++) { pxtii->dump_index_to_color_index[index] = INVALID; } if (!BuildXPmBuckets(ncolors, pixels, pxtii->dump_index_to_color_index, INVALID, NULL, pxtii)) { return FALSE; } } } else if ((PRTGIF && !cmdLineOpenDisplay) || (!colorDisplay && xpm_ptr->red != NULL)) { if (!BuildXPmBuckets(ncolors, NULL, NULL, chars_per_pixel, color_char, pxtii)) { return FALSE; } } else if (pxtii->has_transparent_pixel) { /* * should never get here since such object is not suppose to have * transparent pixels! */ pxtii->dump_index_to_color_index = (int*)malloc((maxColors+3)*sizeof(int)); if (pxtii->dump_index_to_color_index == NULL) FailAllocMessage(); for (index=0; index < maxColors+3; index++) { pxtii->dump_index_to_color_index[index] = INVALID; } if (!BuildXPmBuckets(ncolors, pixels, pxtii->dump_index_to_color_index, INVALID, NULL, pxtii)) { return FALSE; } } return TRUE; } static int ConvertObjToPpm6(ObjPtr, xpm_ptr, psz_ppm6_path, ppm6_path_sz, pxtii) struct ObjRec *ObjPtr; struct XPmRec *xpm_ptr; char *psz_ppm6_path; int ppm6_path_sz; XpmTransIndexInfo *pxtii; { FILE *ppm_fp=NULL; int row=0, image_w=xpm_ptr->image_w, image_h=xpm_ptr->image_h, pixel_index=0; int ncolors=xpm_ptr->ncolors; XColor *saved_tgif_colors=tgifColors; ColorBytes *pcb=(ColorBytes*)malloc((ncolors+3)*sizeof(ColorBytes)); ImagePixelInfo ipi; if (!PrepareColorsForConvertObjToPpm6(xpm_ptr, pxtii)) return FALSE; /* * pcb maps an object color index to an RGB value */ if (pcb == NULL) FailAllocMessage(); memset(pcb, 0, (ncolors+3)*sizeof(ColorBytes)); if (printUsingRequestedColor) tgifColors = tgifRequestedColors; if (MkTempFile(psz_ppm6_path, ppm6_path_sz, tmpDir, TOOL_NAME) == NULL) { free(pcb); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; return FALSE; } if ((ppm_fp=fopen(psz_ppm6_path, "w")) == NULL) { free(pcb); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; return FailToOpenMessage(psz_ppm6_path, "w", NULL); } memset(&ipi, 0, sizeof(ImagePixelInfo)); if (!GetImagePixels(ObjPtr, xpm_ptr, &ipi, pxtii, pcb)) { free(pcb); if (printUsingRequestedColor) tgifColors = saved_tgif_colors; return FALSE; } writeFileFailed = FALSE; fprintf(ppm_fp, "P6\n%1d %1d\n255\n", image_w, image_h); for (row=0; row < image_h; row++) { int col=0; for (col=0; col < image_w; col++) { pixel_index = ipi.image_pixels[row][col]; if (fprintf(ppm_fp, "%c%c%c", pcb[pixel_index].r, pcb[pixel_index].g, pcb[pixel_index].b) == EOF) { writeFileFailed = TRUE; } } } fclose(ppm_fp); FreeImagePixels(&ipi); if (writeFileFailed) { FailToWriteFileMessage(psz_ppm6_path); } if (printUsingRequestedColor) tgifColors = saved_tgif_colors; free(pcb); return TRUE; } void DumpXPmObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { int row=0, i=0, index=0, col=0, too_many_colors=FALSE; int ltx=0, lty=0, rbx=0, rby=0, w=0, h=0, image_w=0, image_h=0; int ncolors=0, *pixels=NULL, flip=0, orig_x=0, orig_y=0; int cur_pixel=0, chars_per_pixel=0, x=0, y=0, found_index=0, pixel_index=0; int has_transparent_pixel=FALSE, is_linked_jpeg=IsLinkedJpegObj(ObjPtr); unsigned int trans_color_pixel_r=0, trans_color_pixel_g=0, trans_color_pixel_b=0; int is_ppm_true=FALSE; char *xpm_data=NULL, *color_char=NULL; Pixmap pixmap=(Pixmap)0, bitmap=(Pixmap)0; XImage *image=NULL, *bitmap_image=NULL; struct XPmRec *xpm_ptr=NULL; struct MtrxRec mtrx; XpmTransIndexInfo xtii; memset(&mtrx, 0, sizeof(struct MtrxRec)); memset(&xtii, 0, sizeof(XpmTransIndexInfo)); ltx = ObjPtr->obbox.ltx; lty = ObjPtr->obbox.lty; rbx = ObjPtr->obbox.rbx; rby = ObjPtr->obbox.rby; xpm_ptr = ObjPtr->detail.xpm; pixmap = xpm_ptr->pixmap; bitmap = xpm_ptr->bitmap; pixels = xpm_ptr->pixels; ncolors = xpm_ptr->ncolors; flip = xpm_ptr->flip; image_w = xpm_ptr->image_w; image_h = xpm_ptr->image_h; w = rbx - ltx; h = rby - lty; is_ppm_true = IsPpmTrueObj(xpm_ptr->real_type, xpm_ptr->ppm_data_compress, xpm_ptr->ppm_data); if ((!PRTGIF || cmdLineOpenDisplay) && (image=xpm_ptr->image) == NULL) { if ((image=xpm_ptr->image=XGetImage(mainDisplay, pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap)) == NULL) { Msg(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM)); return; } } if ((!PRTGIF || cmdLineOpenDisplay) && (bitmap_image=xpm_ptr->bitmap_image) == NULL) { if ((bitmap_image=xpm_ptr->bitmap_image=XGetImage(mainDisplay, bitmap, 0, 0, image_w, image_h, 1, ZPixmap)) == NULL) { Msg(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM)); return; } } mtrx.image_w = (float)image_w; mtrx.image_h = (float)image_h; mtrx.w = (float)w; mtrx.h = (float)h; mtrx.rotate = ROTATE0; mtrx.flip = flip; CalcTransform(&mtrx); orig_x = (mtrx.transformed_w >= 0.0) ? ltx : ltx+w; orig_y = (mtrx.transformed_h >= 0.0) ? lty : lty+h; fprintf(FP, "%% XPM\n"); xpm_data = xpm_ptr->data; chars_per_pixel = xpm_ptr->chars_per_pixel; color_char = xpm_ptr->color_char; if (PRTGIF && !cmdLineOpenDisplay && fileVersion < 25) { /* can't print color with PRTGIF, treat it like a bitmap */ PrTgifDumpOldXPmObj(FP, ObjPtr, &mtrx); return; } if ((PRTGIF && !cmdLineOpenDisplay) || (!colorDisplay && xpm_ptr->red != NULL)) { if (xpm_ptr->real_type == PPM_TRUE && xpm_ptr->has_transparent_color) { has_transparent_pixel = TRUE; trans_color_pixel_r = (unsigned int)xpm_ptr->transparent_color[0]; trans_color_pixel_g = (unsigned int)xpm_ptr->transparent_color[1]; trans_color_pixel_b = (unsigned int)xpm_ptr->transparent_color[2]; } else { int *red_ptr=xpm_ptr->red; if (ncolors > 0xff) { too_many_colors = TRUE; } for (index = 0; index < ncolors; index++) { if (red_ptr[index] == (-1)) { has_transparent_pixel = TRUE; break; } } } } else { if (fullTrueColorMode && xpm_ptr->real_type == PPM_TRUE && xpm_ptr->has_transparent_color) { has_transparent_pixel = TRUE; trans_color_pixel_r = (unsigned int)xpm_ptr->transparent_color[0]; trans_color_pixel_g = (unsigned int)xpm_ptr->transparent_color[1]; trans_color_pixel_b = (unsigned int)xpm_ptr->transparent_color[2]; } else { if (ncolors > 0xff) { too_many_colors = TRUE; } for (index = 0; index < ncolors; index++) { if (pixels[index] == (-1)) { has_transparent_pixel = TRUE; break; } } } } if (has_transparent_pixel) { xtii.has_transparent_pixel = TRUE; if (((PRTGIF && !cmdLineOpenDisplay) || fullTrueColorMode) && xpm_ptr->real_type == PPM_TRUE && xpm_ptr->has_transparent_color) { } else if (too_many_colors && colorDump) { sprintf(gszMsgBox, TgLoadString(STID_TRANS_XPM_TOO_MANY_COLORS_SKP), ncolors); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } xpmHasTooManyColorsForPrinting = TRUE; return; } } x = (mtrx.transformed_w >= 0.0) ? ltx : ltx+w; y = (mtrx.transformed_h >= 0.0) ? lty : lty+h; fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if (is_linked_jpeg) { if (!ConvertJpegToPpm6(xpm_ptr->filename, xpm_ptr->tmp_ppm6_fname, sizeof(xpm_ptr->tmp_ppm6_fname))) { return; } } else if (is_ppm_true) { if (!ConvertPpmTrueToPpm6(xpm_ptr->ppm_data, xpm_ptr->ppm_data_size, xpm_ptr->ppm_data_compress, xpm_ptr->tmp_ppm6_fname, sizeof(xpm_ptr->tmp_ppm6_fname))) { return; } } else if (too_many_colors && colorDump) { if (!ConvertObjToPpm6(ObjPtr, xpm_ptr, xpm_ptr->tmp_ppm6_fname, sizeof(xpm_ptr->tmp_ppm6_fname), &xtii)) { return; } } else if (colorDump) { fprintf(FP, " 3 %1d %s %s tgifsetpixels\n", ncolors, gPsCmd[PS_MUL], gPsCmd[PS_ARRAY]); if ((PRTGIF && !cmdLineOpenDisplay) || (!colorDisplay && xpm_ptr->red != NULL)) { if (!BuildXPmBuckets(ncolors, NULL, NULL, chars_per_pixel, color_char, &xtii)) { return; } for (index = 0; index < ncolors; index++) { if (xpm_ptr->red[index] == (-1)) { fprintf(FP, "%s%3d [ -1.00 -1.00 -1.00 ] tgifsetpix", ((index & 0x1) ? "" : " "), index*3); } else { fprintf(FP, "%s%3d [ %.3f %.3f %.3f ] tgifsetpix", ((index & 0x1) ? "" : " "), index*3, ((float)xpm_ptr->red[index])/((float)10000.0), ((float)xpm_ptr->green[index])/((float)10000.0), ((float)xpm_ptr->blue[index])/((float)10000.0)); } fprintf(FP, "%s", ((index & 0x1) ? "\n" : " ")); } } else { if (!BuildXPmBuckets(ncolors, pixels, NULL, INVALID, NULL, &xtii)) { return; } for (index = 0; index < ncolors; index++) { cur_pixel = pixels[index]; if (cur_pixel != (-1)) { found_index = ObjPtr->color; for (i = 0; i < maxColors; i++) { if (colorPixels[i] == cur_pixel) { found_index = i; break; } } fprintf(FP, "%s%3d [ %.3f %.3f %.3f ] tgifsetpix", ((index & 0x1) ? "" : " "), index*3, ((float)tgifColors[found_index].red/maxRGB), ((float)tgifColors[found_index].green/maxRGB), ((float)tgifColors[found_index].blue/maxRGB)); } else { fprintf(FP, "%s%3d [ -1.00 -1.00 -1.00 ] tgifsetpix", ((index & 0x1) ? "" : " "), index*3); } fprintf(FP, "%s", ((index & 0x1) ? "\n" : " ")); } } if (ncolors & 0x1) fprintf(FP, "\n"); } else if ((PRTGIF && !cmdLineOpenDisplay) || (!colorDisplay && xpm_ptr->red != NULL)) { if (!BuildXPmBuckets(ncolors, NULL, NULL, chars_per_pixel, color_char, &xtii)) { return; } if (has_transparent_pixel) { fprintf(FP, " 3 %1d %s %s tgifsetpixels\n", ncolors, gPsCmd[PS_MUL], gPsCmd[PS_ARRAY]); for (index = 0; index < ncolors; index++) { if (xpm_ptr->red[index] == (-1)) { fprintf(FP, "%s%3d [ -1.00 -1.00 -1.00 ] tgifsetpix", ((index & 0x1) ? "" : " "), index*3); } else { float gray; gray = 0.299*((float)xpm_ptr->red[index]/10000.0) + 0.587*((float)xpm_ptr->green[index]/10000.0) + 0.114*((float)xpm_ptr->blue[index]/10000.0); fprintf(FP, "%s%3d [ %.3f %.3f %.3f ] tgifsetpix", ((index & 0x1) ? "" : " "), index*3, gray, gray, gray); } fprintf(FP, "%s", ((index & 0x1) ? "\n" : " ")); } } } else if (has_transparent_pixel) { if (!BuildXPmBuckets(ncolors, pixels, NULL, INVALID, NULL, &xtii)) { return; } fprintf(FP, " 3 %1d %s %s tgifsetpixels\n", ncolors, gPsCmd[PS_MUL], gPsCmd[PS_ARRAY]); for (index = 0; index < ncolors; index++) { cur_pixel = pixels[index]; if (cur_pixel != (-1)) { float gray; found_index = ObjPtr->color; for (i = 0; i < maxColors; i++) { if (colorPixels[i] == cur_pixel) { found_index = i; break; } } gray = 0.299*((float)tgifColors[found_index].red)/((float)maxRGB) + 0.587*((float)tgifColors[found_index].green)/((float)maxRGB) + 0.114*((float)tgifColors[found_index].blue)/((float)maxRGB); fprintf(FP, "%s%3d [ %.3f %.3f %.3f ] tgifsetpix", ((index & 0x1) ? "" : " "), index*3, gray, gray, gray); } else { fprintf(FP, "%s%3d [ -1.00 -1.00 -1.00 ] tgifsetpix", ((index & 0x1) ? "" : " "), index*3); } fprintf(FP, "%s", ((index & 0x1) ? "\n" : " ")); } } else { /* grayscale */ } if (((PRTGIF && !cmdLineOpenDisplay) || fullTrueColorMode) && xpm_ptr->real_type == PPM_TRUE && xpm_ptr->has_transparent_color) { fprintf(FP, " %1d %1d %1d tgifsetppmtruetranspix\n", trans_color_pixel_r, trans_color_pixel_g, trans_color_pixel_b); } if (ObjPtr->ctm == NULL) { fprintf(FP, " %1d %1d %s %.3f %.3f %s %1d %s\n", x, y, gPsCmd[PS_TRANSLATE], mtrx.dump_h_scale, mtrx.dump_v_scale, gPsCmd[PS_SCALE], mtrx.degree, gPsCmd[PS_ROTATE]); } else { float m[6]; m[CTM_SX] = ((float)ObjPtr->ctm->m[CTM_SX])/((float)1000.0); m[CTM_SY] = ((float)ObjPtr->ctm->m[CTM_SY])/((float)1000.0); m[CTM_SIN] = ((float)ObjPtr->ctm->m[CTM_SIN])/((float)1000.0); m[CTM_MSIN] = ((float)ObjPtr->ctm->m[CTM_MSIN])/((float)1000.0); fprintf(FP, " %1d %1d %s\n", ObjPtr->x, ObjPtr->y, gPsCmd[PS_TRANSLATE]); fprintf(FP, " [%.3f %.3f %.3f %.3f %1d %1d] %s\n", m[CTM_SX], m[CTM_SIN], m[CTM_MSIN], m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY], gPsCmd[PS_CONCAT]); } fprintf(FP, " %1d %1d 8\n [1 0 0 1 0 0]\n", image_w, image_h); if (preDumpSetup) { PSUseColorImage(); hasReadHexString = TRUE; } if (is_linked_jpeg || is_ppm_true || (too_many_colors && colorDump)) { if (((PRTGIF && !cmdLineOpenDisplay) || fullTrueColorMode) && xpm_ptr->real_type == PPM_TRUE && xpm_ptr->has_transparent_color) { fprintf(FP, " { }\n"); fprintf(FP, " false 3 tgiftransppmtruecolorimage\n "); } else { fprintf(FP, " {currentfile\n"); fprintf(FP, " tgifbwpicstr readhexstring pop}\n"); fprintf(FP, " false 3 colorimage\n "); } } else if (colorDump) { fprintf(FP, " {currentfile\n"); fprintf(FP, " tgifbwpicstr readhexstring pop 0 get tgifcolorspot}\n"); if (has_transparent_pixel) { fprintf(FP, " false 3 tgiftranscolorimage\n "); } else { fprintf(FP, " false 3 colorimage\n "); } } else { /* grayscale */ if (has_transparent_pixel) { fprintf(FP, " {currentfile\n"); fprintf(FP, " %s}\n", "tgifbwpicstr readhexstring pop 0 get tgifcolorspot"); fprintf(FP, " false 3 tgiftranscolorimage\n "); } else { fprintf(FP, " {currentfile\n"); fprintf(FP, " tgifbwpicstr readhexstring pop}\n"); fprintf(FP, " %s\n ", gPsCmd[PS_IMAGE]); } } /* * Transparent_pixel is dealt with a little bit differently here. * When generating colors for a particular pixel, if the pixel is * suppose to be transparent, the color components are all * (-1). The postscript code will take care of it and not * put down any ink. * Whether we are doing colorDump or not doesn't matter here. */ if (is_linked_jpeg || is_ppm_true || (too_many_colors && colorDump)) { DumpPpm6File(FP, image_w, image_h, xpm_ptr->tmp_ppm6_fname); unlink(xpm_ptr->tmp_ppm6_fname); *xpm_ptr->tmp_ppm6_fname = '\0'; if (xtii.dump_index_to_color_index != NULL) { free(xtii.dump_index_to_color_index); } } else if (PRTGIF && !cmdLineOpenDisplay) { for (row=0; row < image_h; row++) { for (col=0; col < image_w; col++) { float gray; int value; pixel_index = XPmLookUp(INVALID, chars_per_pixel, &(xpm_data[(row*image_w+col)*chars_per_pixel]), NULL); if (!has_transparent_pixel) { if (!colorDump) { gray = 0.299*((float)xpm_ptr->red[pixel_index]/10000.0) + 0.587*((float)xpm_ptr->green[pixel_index]/10000.0) + 0.114*((float)xpm_ptr->blue[pixel_index]/10000.0); value = gray*256; pixel_index = ((value>255) ? 255 : ((value<0) ? 0 : value)); } } fprintf(FP, "%c", hexValue[(pixel_index>>4)&0x0f]); fprintf(FP, "%c", hexValue[pixel_index&0x0f]); if (col%36 == 35) fprintf(FP, "\n "); } if (col%36 != 0) fprintf(FP, "\n"); if (row != image_h-1) fprintf(FP, " "); } } else { for (row=0; row < image_h; row++) { for (col=0; col < image_w; col++) { if (colorDump || has_transparent_pixel) { if (!colorDisplay && xpm_ptr->red != NULL) { pixel_index = XPmLookUp(INVALID, chars_per_pixel, &(xpm_data[(row*image_w+col)*chars_per_pixel]), NULL); } else if (XGetPixel(bitmap_image,col,row) != 0) { pixel_index = XPmLookUp(XGetPixel(image,col,row), INVALID, NULL, NULL); } else { pixel_index = XPmLookUp((-1), INVALID, NULL, NULL); } } else { float gray; int value; if (!colorDisplay && xpm_ptr->red != NULL) { pixel_index = XPmLookUp(INVALID, chars_per_pixel, &(xpm_data[(row*image_w+col)*chars_per_pixel]), NULL); gray = 0.299*((float)xpm_ptr->red[pixel_index]/10000.0) + 0.587*((float)xpm_ptr->green[pixel_index]/10000.0) + 0.114*((float)xpm_ptr->blue[pixel_index]/10000.0); } else { if (XGetPixel(bitmap_image, col, row) != 0) { cur_pixel = XGetPixel(image, col, row); } else { found_index = ObjPtr->color; cur_pixel = (-1); } if (cur_pixel != (-1)) { for (i = 0; i < maxColors; i++) { if (colorPixels[i] == cur_pixel) { found_index = i; break; } } } gray = 0.299*((float)tgifColors[found_index].red/maxRGB) + 0.587*((float)tgifColors[found_index].green/maxRGB) + 0.114*((float)tgifColors[found_index].blue/maxRGB); } value = gray*256; pixel_index = ((value>255) ? 255 : ((value<0) ? 0 : value)); } fprintf(FP, "%c", hexValue[(pixel_index>>4)&0x0f]); fprintf(FP, "%c", hexValue[pixel_index&0x0f]); if (col%36 == 35) { fprintf(FP, "\n%s", (col==image_w-1 && row==image_h-1) ? "" : " "); } } if (col%36 != 0) fprintf(FP, "\n"); if (row != image_h-1 && (col%36) != 0) fprintf(FP, " "); } } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); } int NeedsToCacheXPmObj(ObjPtr) struct ObjRec *ObjPtr; { register struct XPmRec *xpm_ptr=ObjPtr->detail.xpm; int w, h; w = ObjPtr->obbox.rbx - ObjPtr->obbox.ltx; h = ObjPtr->obbox.rby - ObjPtr->obbox.lty; return (ObjPtr->ctm != NULL || zoomScale != 0 || xpm_ptr->image_w != w || xpm_ptr->image_h != h || xpm_ptr->flip != 0); } static void DrawHiddenXPm(win, ctm, vs, x, y, w, h, s) Window win; struct XfrmMtrxRec *ctm; XPoint *vs; int x, y, w, h; char *s; { int str_w, len, sx, sy; XGCValues values; values.foreground = GetDrawingBgPixel(INVALID, INVALID); values.function = GXcopy;; values.fill_style = FillSolid; #ifdef NO_THIN_LINE values.line_width = 1; #else values.line_width = 0; #endif values.font = rulerFontPtr->fid; values.line_style = LineSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCLineWidth | GCFont | GCLineStyle, &values); if (ctm != NULL) { XFillPolygon(mainDisplay, win, drawGC, vs, 5, Convex, CoordModeOrigin); } else { XFillRectangle(mainDisplay, win, drawGC, x, y, w, h); } XSetForeground(mainDisplay, drawGC, GetDrawingFgPixel(INVALID, INVALID)); if (ctm != NULL) { XDrawLines(mainDisplay, win, drawGC, vs, 5, CoordModeOrigin); } else { XDrawRectangle(mainDisplay, win, drawGC, x, y, w, h); } XSetForeground(mainDisplay, drawGC, colorPixels[colorIndex]); len = strlen(s); str_w = rulerFontWidth*len; if (str_w < w && rulerFontHeight < h) { sx = x + ((w-str_w)>>1); sy = y + ((h-rulerFontHeight)>>1); XDrawString(mainDisplay, win, drawGC, sx, sy+rulerFontAsc, s, len); } XSetFont(mainDisplay, drawGC, canvasFontPtr->fid); } void RecolorXPmObj(obj_ptr, color_index) struct ObjRec *obj_ptr; int color_index; { register int c, r; struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; int image_w=xpm_ptr->image_w, image_h=xpm_ptr->image_h; Pixmap pixmap=None; XImage *image=NULL; xpm_ptr->cached_color = (-1); if (xpm_ptr->bitmap_image == NULL) { xpm_ptr->bitmap_image = XGetImage(mainDisplay, xpm_ptr->bitmap, 0, 0, image_w, image_h, 1, ZPixmap); if (xpm_ptr->bitmap_image == NULL) return; } if (xpm_ptr->image == NULL) { xpm_ptr->image = XGetImage(mainDisplay, xpm_ptr->pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (xpm_ptr->image == NULL) return; } pixmap = XCreatePixmap(mainDisplay, dummyPixmap, image_w, image_h, mainDepth); if (pixmap == None) return; XFillRectangle(mainDisplay, pixmap, xpmGC, 0, 0, image_w, image_h); image = XGetImage(mainDisplay, pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (image == NULL) { XFreePixmap(mainDisplay, pixmap); return; } for (r=0; r < image_h; r++) { for (c=0; c < image_w; c++) { if (XGetPixel(xpm_ptr->bitmap_image, c, r) != 0) { XPutPixel(image, c, r, XGetPixel(xpm_ptr->image, c, r)); } else { XPutPixel(image, c, r, colorPixels[color_index]); } } } XPutImage(mainDisplay, pixmap, xpmGC, image, 0, 0, 0, 0, image_w, image_h); XFreePixmap(mainDisplay, xpm_ptr->pixmap); XDestroyImage(xpm_ptr->image); xpm_ptr->pixmap = pixmap; xpm_ptr->image = image; if (obj_ptr->ctm != NULL) { MakeCachedPixmap(obj_ptr); } } void DrawXPmObj(win, XOff, YOff, ObjPtr) Window win; int XOff, YOff; struct ObjRec *ObjPtr; { int ltx, lty, rbx, rby, w, h, scr_w, scr_h, real_x_off, real_y_off; char s[80]; struct XPmRec *xpm_ptr=ObjPtr->detail.xpm; XGCValues values; if (userDisableRedraw) return; if (ObjPtr->prev != NULL && ObjPtr->prev->type == OBJ_XPM && Inside(ObjPtr->obbox, ObjPtr->prev->obbox) && ObjPtr->prev->detail.xpm->bitmap == None) { return; } w = ObjPtr->obbox.rbx - ObjPtr->obbox.ltx; h = ObjPtr->obbox.rby - ObjPtr->obbox.lty; real_x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); real_y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); ltx = ZOOMED_SIZE(ObjPtr->obbox.ltx - real_x_off); lty = ZOOMED_SIZE(ObjPtr->obbox.lty - real_y_off); rbx = ZOOMED_SIZE(ObjPtr->obbox.rbx - real_x_off); rby = ZOOMED_SIZE(ObjPtr->obbox.rby - real_y_off); scr_w = rbx - ltx; scr_h = rby - lty; if (!mapShown) { sprintf(s, "(%1dx%1d)", xpm_ptr->image_w, xpm_ptr->image_h); DrawHiddenXPm(win, ObjPtr->ctm, ObjPtr->rotated_obbox, ltx, lty, scr_w, scr_h, s); return; } if (NeedsToCacheXPmObj(ObjPtr) && (ObjPtr->ctm == NULL || (ObjPtr->ctm != NULL && (xpm_ptr->cached_pixmap == None || xpm_ptr->clip_mask == None)))) { MakeCachedPixmap(ObjPtr); } XSetFunction(mainDisplay, drawGC, GXcopy); if (ObjPtr->ctm==NULL && zoomScale==0 && xpm_ptr->flip==0 && xpm_ptr->image_w==w && xpm_ptr->image_h==h) { if (xpm_ptr->bitmap == None) { XCopyArea(mainDisplay, xpm_ptr->pixmap, win, drawGC, 0, 0, w, h, ltx, lty); } else { values.function = GXcopy; values.clip_x_origin = ltx; values.clip_y_origin = lty; values.clip_mask = xpm_ptr->bitmap; XChangeGC(mainDisplay, drawGC, GCFunction | GCClipXOrigin | GCClipYOrigin | GCClipMask, &values); DrawClippedPixmap(xpm_ptr->pixmap, win, drawGC, scr_w, scr_h, ltx, lty); values.clip_x_origin = 0; values.clip_y_origin = 0; values.clip_mask = None; XChangeGC(mainDisplay, drawGC, GCClipXOrigin | GCClipYOrigin | GCClipMask, &values); if (numClipRecs > 0) { XSetClipRectangles(mainDisplay, drawGC, 0, 0, clipRecs, numClipRecs, clipOrdering); } } } else { if (xpm_ptr->cached_pixmap == None) return; if (ObjPtr->ctm == NULL) { if (xpm_ptr->cached_bitmap == None) { XCopyArea(mainDisplay, xpm_ptr->cached_pixmap, win, drawGC, 0, 0, scr_w, scr_h, ltx, lty); } else { values.function = GXcopy; values.clip_x_origin = ltx; values.clip_y_origin = lty; values.clip_mask = xpm_ptr->cached_bitmap; XChangeGC(mainDisplay, drawGC, GCFunction | GCClipXOrigin | GCClipYOrigin | GCClipMask, &values); DrawClippedPixmap(xpm_ptr->cached_pixmap, win, drawGC, scr_w, scr_h, ltx, lty); values.clip_x_origin = 0; values.clip_y_origin = 0; values.clip_mask = None; XChangeGC(mainDisplay, drawGC, GCClipXOrigin | GCClipYOrigin | GCClipMask, &values); if (numClipRecs > 0) { XSetClipRectangles(mainDisplay, drawGC, 0, 0, clipRecs, numClipRecs, clipOrdering); } } } else if (xpm_ptr->clip_mask == None) { XCopyArea(mainDisplay, xpm_ptr->cached_pixmap, win, drawGC, 0, 0, scr_w, scr_h, ltx, lty); } else { values.function = GXcopy; values.clip_x_origin = ltx; values.clip_y_origin = lty; values.clip_mask = xpm_ptr->clip_mask; XChangeGC(mainDisplay, drawGC, GCFunction | GCClipXOrigin | GCClipYOrigin | GCClipMask, &values); DrawClippedPixmap(xpm_ptr->cached_pixmap, win, drawGC, scr_w, scr_h, ltx, lty); values.clip_x_origin = 0; values.clip_y_origin = 0; values.clip_mask = None; XChangeGC(mainDisplay, drawGC, GCClipXOrigin | GCClipYOrigin | GCClipMask, &values); if (numClipRecs > 0) { XSetClipRectangles(mainDisplay, drawGC, 0, 0, clipRecs, numClipRecs, clipOrdering); } } } } int PrTgifFindColorIndex(ObjPtr, s) struct ObjRec *ObjPtr; char *s; { int i; for (i=0; i < maxColors; i++) { int valid=FALSE; char *s1=s, *s2=colorMenuItems[i]; if (*s1 == *s2) { valid = TRUE; } else if (*s1 >= 'a' && *s1 <= 'z') { if (*s1+'A'-'a' == *s2) { valid = TRUE; } } else if (*s >= 'A' && *s <= 'Z') { if (*s1+'a'-'A' == *s2) { valid = TRUE; } } if (valid && (UtilStrICmp(++s1,++s2) == 0)) { if (ObjPtr != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), colorMenuItems[i]); } return i; } } return INVALID; } int QuickFindColorIndex(ObjPtr, s, new_alloc, use_default) struct ObjRec *ObjPtr; char *s; int *new_alloc, use_default; { register int i; XColor exact_def, screen_def; if (new_alloc != NULL) *new_alloc = FALSE; if (PRTGIF && cmdLineColor && (prTgifFoundColorInfo || !cmdLineOpenDisplay)) { int color_index=PrTgifFindColorIndex(ObjPtr, s); if (color_index != INVALID || !cmdLineOpenDisplay) { return color_index; } } if (ObjPtr != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), s); } if (colorMenuItems == NULL) { return INVALID; } if (*s == '#') { if (!TgifParseColor(s, &exact_def)) { if (use_default) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANNOT_ALLOC_COLOR_USE_ALT), s, colorMenuItems[colorIndex]); if (!PRTGIF) Msg(gszMsgBox); allocColorFailed = TRUE; if (ObjPtr != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), colorMenuItems[colorIndex]); } return colorIndex; } return INVALID; } } else { for (i=0; i < maxColors; i++) { int valid=FALSE; char *s1=s, *s2=colorMenuItems[i]; if (*s1 == *s2) { valid = TRUE; } else if (*s1 >= 'a' && *s1 <= 'z') { if (*s1+'A'-'a' == *s2) { valid = TRUE; } } else if (*s >= 'A' && *s <= 'Z') { if (*s1+'a'-'A' == *s2) { valid = TRUE; } } if (valid && (UtilStrICmp(++s1,++s2) == 0)) { if (ObjPtr != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), colorMenuItems[i]); } return i; } } if (!TgifParseColor(s, &exact_def)) { if (use_default) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANNOT_ALLOC_COLOR_USE_ALT), s, colorMenuItems[colorIndex]); if (!PRTGIF) Msg(gszMsgBox); allocColorFailed = TRUE; if (ObjPtr != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), colorMenuItems[colorIndex]); } return colorIndex; } return INVALID; } } for (i=0; i < maxColors; i++) { if (tgifRequestedColors[i].red == exact_def.red && tgifRequestedColors[i].green == exact_def.green && tgifRequestedColors[i].blue == exact_def.blue) { if (ObjPtr != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), colorMenuItems[i]); } return i; } } memcpy(&screen_def, &exact_def, sizeof(XColor)); if (!XAllocColor(mainDisplay, mainColormap, &screen_def)) { Colormap colormap; if (newColormapUsed) { if (use_default) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANNOT_ALLOC_COLOR_USE_ALT), s, colorMenuItems[colorIndex]); if (!PRTGIF) Msg(gszMsgBox); allocColorFailed = TRUE; if (ObjPtr != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), colorMenuItems[colorIndex]); } return colorIndex; } return INVALID; } colormap = XCopyColormapAndFree(mainDisplay, mainColormap); mainColormap = colormap; newColormapUsed = TRUE; XSetWindowColormap(mainDisplay, mainWindow, mainColormap); if (!XAllocColor(mainDisplay, mainColormap, &screen_def)) { if (use_default) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANNOT_ALLOC_COLOR_USE_ALT), s, colorMenuItems[colorIndex]); if (!PRTGIF) Msg(gszMsgBox); allocColorFailed = TRUE; if (ObjPtr != NULL) { UtilStrCpyN(ObjPtr->color_str, sizeof(ObjPtr->color_str), colorMenuItems[colorIndex]); } return colorIndex; } return INVALID; } } colorPixels = (int*)realloc(colorPixels, (maxColors+1)*sizeof(int)); xorColorPixels = (int*)realloc(xorColorPixels, (maxColors+1)*sizeof(int)); colorLayerOn = (int*)realloc(colorLayerOn, (maxColors+1)*sizeof(int)); colorMenuItems = (char**)realloc(colorMenuItems, (maxColors+1)*sizeof(char*)); colorMenuItems[maxColors] = (char*)malloc((strlen(s)+1)*sizeof(char)); if (colorMenuItems[maxColors] == NULL) FailAllocMessage(); tgifColors = (XColor*)realloc(tgifColors, (maxColors+1)*sizeof(XColor)); tgifRequestedColors = (XColor*)realloc(tgifRequestedColors, (maxColors+1)*sizeof(XColor)); colorPixels[maxColors] = screen_def.pixel; xorColorPixels[maxColors] = screen_def.pixel ^ GetDrawingBgPixel(INVALID, INVALID); colorLayerOn[maxColors] = TRUE; strcpy(colorMenuItems[maxColors], s); tgifRequestedColors[maxColors].red = exact_def.red; tgifRequestedColors[maxColors].green = exact_def.green; tgifRequestedColors[maxColors].blue = exact_def.blue; tgifColors[maxColors].red = screen_def.red; tgifColors[maxColors].green = screen_def.green; tgifColors[maxColors].blue = screen_def.blue; maxColors++; *new_alloc = TRUE; DestroyPinnedMenu(MENU_COLOR); if (!PRTGIF && colorLayers) { needToRedrawColorWindow = TRUE; } return (maxColors-1); } struct ObjRec *CreateXPmObj(ImageW, ImageH, W, H, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data) int ImageW, ImageH, W, H; Pixmap pixmap, bitmap; XImage *image, *bitmap_image; int ncolors, chars_per_pixel, first_pixel_is_bg; char *color_char; char **color_str; int *pixels; char *xpm_data; { struct XPmRec *xpm_ptr; struct ObjRec *obj_ptr; xpm_ptr = (struct XPmRec *)malloc(sizeof(struct XPmRec)); if (xpm_ptr == NULL) FailAllocMessage(); memset(xpm_ptr, 0, sizeof(struct XPmRec)); xpm_ptr->pixmap = pixmap; xpm_ptr->image = image; xpm_ptr->bitmap = bitmap; xpm_ptr->bitmap_image = bitmap_image; xpm_ptr->image_w = ImageW; xpm_ptr->image_h = ImageH; xpm_ptr->data = xpm_data; xpm_ptr->fill = objFill; xpm_ptr->flip = xpm_ptr->cached_flip = 0; xpm_ptr->cached_zoom = 0; xpm_ptr->cached_pixmap = None; xpm_ptr->cached_bitmap = None; xpm_ptr->cached_w = xpm_ptr->cached_h = 0; xpm_ptr->cached_color = (-1); xpm_ptr->ncolors = ncolors; xpm_ptr->chars_per_pixel = chars_per_pixel; xpm_ptr->first_pixel_is_bg = first_pixel_is_bg; xpm_ptr->color_char = color_char; xpm_ptr->color_str = color_str; xpm_ptr->pixels = pixels; if (colorDisplay || ncolors == (-1)) { xpm_ptr->red = xpm_ptr->green = xpm_ptr->blue = NULL; } else { int i; xpm_ptr->red = (int*)malloc(ncolors*sizeof(int)); xpm_ptr->green = (int*)malloc(ncolors*sizeof(int)); xpm_ptr->blue = (int*)malloc(ncolors*sizeof(int)); if (xpm_ptr->red==NULL || xpm_ptr->green==NULL || xpm_ptr->blue==NULL) { FailAllocMessage(); } for (i=0; i < ncolors; i++) { int new_alloc; int index=QuickFindColorIndex(NULL, color_str[i], &new_alloc, TRUE); xpm_ptr->red[i] = (int)(10000*((int)tgifRequestedColors[index].red)/maxRGB); xpm_ptr->green[i] = (int)(10000*((int)tgifRequestedColors[index].green)/maxRGB); xpm_ptr->blue[i] = (int)(10000*((int)tgifRequestedColors[index].blue)/maxRGB); } } xpm_ptr->clip_mask = None; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = drawOrigX; obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = drawOrigY; obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = W + drawOrigX; obj_ptr->bbox.rby = obj_ptr->obbox.rby = H + drawOrigY; obj_ptr->type = OBJ_XPM; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->id = objId++; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->locked = FALSE; obj_ptr->detail.xpm = xpm_ptr; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; obj_ptr->invisible = FALSE; return obj_ptr; } static void CopyXPmProperties(DestXpmObj, SrcXpmObj) struct ObjRec *DestXpmObj, *SrcXpmObj; { struct XPmRec *dest_xpm_ptr=DestXpmObj->detail.xpm; struct XPmRec *src_xpm_ptr=SrcXpmObj->detail.xpm; dest_xpm_ptr->fill = src_xpm_ptr->fill; DestXpmObj->color = SrcXpmObj->color; memcpy(DestXpmObj->color_str, SrcXpmObj->color_str, sizeof(DestXpmObj->color_str)); } static int FinishBreakUpXPixmap(obj_ptr, cols_and_rows, cols, rows) struct ObjRec *obj_ptr; int cols_and_rows, cols, rows; { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; int y, image_w=xpm_ptr->image_w, image_h=xpm_ptr->image_h; int chunk_w=0, chunk_h=0, total_chunks=0; int orig_x=obj_ptr->x, orig_y=obj_ptr->y; int ncolors, chars_per_pixel, first_pixel_is_bg; char tmp_fname[MAXPATHLENGTH]; if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { return FALSE; } ncolors = xpm_ptr->ncolors; chars_per_pixel = xpm_ptr->chars_per_pixel; first_pixel_is_bg = xpm_ptr->first_pixel_is_bg; if (cols_and_rows) { chunk_w = (int)(image_w / cols); chunk_h = (int)(image_h / rows); } else { chunk_w = cols; chunk_h = rows; } for (y=0; y < image_h; y += chunk_h) { int h=min(image_h-y,chunk_h), x; for (x=0; x < image_w; x += chunk_w) { int w=min(image_w-x,chunk_w), i, *pixels=NULL; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL; struct ObjRec *new_obj_ptr=NULL; Pixmap dest_pixmap=None, dest_bitmap=None; XImage *dest_image=NULL, *dest_bitmap_image=NULL; if (w <= 0 || h <= 0 || !ExtractPixmap(xpm_ptr->pixmap, xpm_ptr->image, xpm_ptr->bitmap, xpm_ptr->bitmap_image, x, y, w, h, &dest_pixmap, &dest_image, &dest_bitmap, &dest_bitmap_image)) { continue; } if ((xpm_ptr->real_type == XPM_JPEG || xpm_ptr->real_type == PPM_TRUE) && fullTrueColorMode && HasZlibSupport()) { if (DumpXImageToPpmFile(dest_image, w, h, tmp_fname, TRUE)) { char deflated_fname[MAXPATHLENGTH]; unsigned int data_size=0; char *ppm_data=NULL; snprintf(deflated_fname, sizeof(deflated_fname), "%s.ppm.z", tmp_fname); ppm_data = ReadFileIntoBuf(deflated_fname, &data_size); unlink(deflated_fname); unlink(tmp_fname); if (ppm_data) { new_obj_ptr = CreatePpmTrueObjFromImage(dest_image, w, h, ppm_data, data_size); } } if (dest_pixmap != None) XFreePixmap(mainDisplay, dest_pixmap); if (dest_bitmap != None) XFreePixmap(mainDisplay, dest_bitmap); if (dest_image != NULL) XDestroyImage(dest_image); if (dest_bitmap_image != NULL) XDestroyImage(dest_bitmap_image); dest_pixmap = dest_bitmap = None; dest_image = dest_bitmap_image = NULL; if (new_obj_ptr != NULL) { total_chunks++; } } else { pixels = (int*)malloc(ncolors*sizeof(int)); if (pixels == NULL) FailAllocMessage(); memcpy(pixels, xpm_ptr->pixels, (size_t)(ncolors*sizeof(int))); color_char = (char*)malloc(ncolors*chars_per_pixel*sizeof(char)); if (color_char == NULL) FailAllocMessage(); memcpy(color_char, xpm_ptr->color_char, (size_t)(ncolors*chars_per_pixel*sizeof(char))); color_str = (char**)malloc(ncolors*sizeof(char*)); if (color_str == NULL) FailAllocMessage(); for (i=0; i < ncolors; i++) { if ((color_str[i]=UtilStrDup(xpm_ptr->color_str[i])) == NULL) { FailAllocMessage(); } } total_chunks++; new_obj_ptr = CreateXPmObj(w, h, w, h, dest_pixmap, dest_image, dest_bitmap, dest_bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); CopyXPmProperties(new_obj_ptr, obj_ptr); } if (new_obj_ptr != NULL) { AdjObjBBox(new_obj_ptr); MoveObj(new_obj_ptr, orig_x+x, orig_y+y); AddObj(NULL, topObj, new_obj_ptr); } } } if (total_chunks > 0) { int i; RemoveAllSel(); UnlinkObj(obj_ptr); FreeObj(obj_ptr); for (i=0, obj_ptr=topObj; obj_ptr != NULL && i < total_chunks; i++, obj_ptr=obj_ptr->next) { AddObjIntoSel(obj_ptr, botSel, NULL, &topSel, &botSel); } } return (total_chunks > 0); } void BreakUpXPixmap(obj_ptr, cols_and_rows, cols, rows) struct ObjRec *obj_ptr; int cols_and_rows, cols, rows; { HighLightReverse(); PrepareToReplaceAnObj(obj_ptr); if (FinishBreakUpXPixmap(obj_ptr, cols_and_rows, cols, rows)) { UpdSelBBox(); RecordCmd(CMD_ONE_TO_MANY, NULL, topSel, botSel, numObjSelected); SetFileModified(TRUE); justDupped = FALSE; } else { AbortPrepareCmd(CMD_REPLACE); } HighLightForward(); } static void SaveXPmPixels(FP, xpm_ptr, pixmap, image, bitmap, bitmap_image, w, h, ncolors, chars_per_pixel, color_char, pixels) FILE *FP; struct XPmRec *xpm_ptr; Pixmap pixmap, bitmap; XImage **image, **bitmap_image; int w, h, ncolors, chars_per_pixel, *pixels; char *color_char; { register int j, data, index, i, k; char *xpm_data=NULL; if (*image == NULL) { *image = XGetImage(mainDisplay, pixmap, 0, 0, w, h, AllPlanes, ZPixmap); if (*image == NULL) { sprintf(gszMsgBox, "%s\n\n%s", TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TgLoadString(STID_SAVED_FILE_MAY_BE_CORRUPTED)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } if (*bitmap_image == NULL) { *bitmap_image = XGetImage(mainDisplay, bitmap, 0, 0, w, h, 1, ZPixmap); if (*bitmap_image == NULL) { sprintf(gszMsgBox, "%s\n\n%s", TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TgLoadString(STID_SAVED_FILE_MAY_BE_CORRUPTED)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } xpm_data = xpm_ptr->data; for (i=0; i < h; i++) { if (fprintf(FP, " \"") == EOF) writeFileFailed = TRUE; for (j=0; j < w; j++) { if (!colorDisplay && xpm_data != NULL && xpm_ptr->red != NULL) { for (k=0; k < chars_per_pixel; k++) { if (fprintf(FP, "%c", xpm_data[j*chars_per_pixel+k]) == EOF) { writeFileFailed = TRUE; } } } else { if (XGetPixel(*bitmap_image, j, i) != 0) { data = XGetPixel(*image,j,i); } else { data = (-1); } index = XPmLookUp(data, INVALID, NULL, NULL); if (index == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_UNRECOG_GIVEN_PIXEL_VAL_PRINT), j, i, data, (long)data); Msg(gszMsgBox); return; } for (k=0; k < chars_per_pixel; k++) { if (fprintf(FP, "%c", color_char[index*chars_per_pixel+k]) == EOF) { writeFileFailed = TRUE; } } } } if (xpm_data != NULL) xpm_data += w*chars_per_pixel; if (i == h-1) { if (fprintf(FP, "\"],") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, "\",\n") == EOF) writeFileFailed = TRUE; } } } static int WritePpmTrueData(FP, xpm_ptr) FILE *FP; struct XPmRec *xpm_ptr; { char *psz=xpm_ptr->ppm_data; int total_bytes_to_write=xpm_ptr->ppm_data_size; while (total_bytes_to_write > 0) { int bytes_to_read=min(48, total_bytes_to_write), bytes_to_write=0; char out_buf[65]; bytes_to_write = (bytes_to_read / 3); if ((bytes_to_read % 3) == 0) { bytes_to_write = bytes_to_write << 2; } else { bytes_to_write = (bytes_to_write+1) << 2; } *out_buf = '\0'; DoBase64Encode(psz, bytes_to_read, out_buf); if (fprintf(FP, " \"") == EOF) writeFileFailed = TRUE; if (fwrite(out_buf, 1, bytes_to_write, FP) != bytes_to_write) { writeFileFailed = TRUE; } psz += bytes_to_read; total_bytes_to_write -= bytes_to_read; if (total_bytes_to_write > 0) { if (fprintf(FP, "\",\n") == EOF) writeFileFailed = TRUE; } else { if (fprintf(FP, "\"],[\n") == EOF) writeFileFailed = TRUE; } } if (xpm_ptr->ppm_mask_data != NULL) { TgAssert(FALSE, "xpm_ptr->ppm_mask_data != NULL in WritePpmTrueData()", NULL); } if (fprintf(FP, " ],") == EOF) writeFileFailed = TRUE; return TRUE; } static char *ReadPpmTrueData(fp, ppm_data_size) FILE *fp; int ppm_data_size; { char line[64+20], *write_ptr=NULL; char *buf_return=(char*)malloc(ppm_data_size+1); if (buf_return == NULL) FailAllocMessage(); write_ptr = buf_return; while (fgets(line, sizeof(line), fp) != NULL) { int len=strlen(line), bytes_converted=0; char *s=NULL, buf[64+20], out_buf[49]; scanLineNum++; if (len > 0 && line[len-1] != '\n') { sprintf(gszMsgBox, TgLoadString(STID_BAD_LINE_READING_GIVEN_OBJ), "ppm_true"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } UtilFree(buf_return); return NULL; } s = FindChar((int)'"', line); s = ParseStr(s, (int)'"', buf, sizeof(buf)); len = strlen(buf); if (len > 64 || (len & 0x3) != 0) { sprintf(gszMsgBox, TgLoadString(STID_BAD_LINE_READING_GIVEN_OBJ), "ppm_true"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } UtilFree(buf_return); return NULL; } /* bytes_converted = (len >> 2) * 3; */ bytes_converted = DoBase64Decode(buf, len, out_buf); ppm_data_size -= bytes_converted; if (ppm_data_size < 0) { sprintf(gszMsgBox, TgLoadString(STID_INSUF_DATA_READING_GIVEN_OBJ), "ppm_true"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } UtilFree(buf_return); return NULL; } memcpy(write_ptr, out_buf, bytes_converted); write_ptr += bytes_converted; if (ppm_data_size == 0) break; } if (ppm_data_size != 0) { sprintf(gszMsgBox, TgLoadString(STID_BAD_LINE_READING_GIVEN_OBJ), "ppm_true"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } UtilFree(buf_return); return NULL; } return buf_return; } static char *ReadPpmTrueMask(fp, ppm_mask_size) FILE *fp; int ppm_mask_size; { char line[64+20]; while (fgets(line, sizeof(line), fp) != NULL) { /* this feature has not been implemented yet */ break; } return NULL; } void SaveXPmObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { int ltx, lty, rbx, rby, fill, ncolors, *pixels=NULL; int chars_per_pixel, first_pixel_is_bg, image_w, image_h; int compressed=FALSE, real_type=0, linked_jpeg=FALSE, jpeg=FALSE; int ppm_z=FALSE; struct XPmRec *xpm_ptr=ObjPtr->detail.xpm; char *color_char=NULL, **color_str=NULL, *jpeg_filename=NULL; ltx = ObjPtr->obbox.ltx; lty = ObjPtr->obbox.lty; rbx = ObjPtr->obbox.rbx; rby = ObjPtr->obbox.rby; image_w = xpm_ptr->image_w; image_h = xpm_ptr->image_h; fill = xpm_ptr->fill; ncolors = xpm_ptr->ncolors; chars_per_pixel = xpm_ptr->chars_per_pixel; first_pixel_is_bg = xpm_ptr->first_pixel_is_bg; color_char = xpm_ptr->color_char; color_str = xpm_ptr->color_str; pixels = xpm_ptr->pixels; real_type = xpm_ptr->real_type; linked_jpeg = xpm_ptr->linked_jpeg; jpeg_filename = xpm_ptr->filename; /* only doing linked JPEG */ jpeg = (real_type == XPM_JPEG && linked_jpeg && jpeg_filename != NULL); ppm_z = (real_type == PPM_TRUE); if (!colorDisplay && xpm_ptr->red == NULL && !shownXPmErrorMessage) { MsgBox(TgLoadString(STID_CANT_SAVE_XPM_ON_BW_DPY), TOOL_NAME, INFO_MB); shownXPmErrorMessage = TRUE; return; } if (jpeg) { if (fprintf(FP, "jpeg('%s','',", colorMenuItems[ObjPtr->color]) == EOF) { writeFileFailed = TRUE; } } else if (ppm_z) { if (fprintf(FP, "ppm_true('%s',", colorMenuItems[ObjPtr->color]) == EOF) { writeFileFailed = TRUE; } if (xpm_ptr->has_transparent_color) { if (fprintf(FP, "'#%02x%02x%02x',1,", xpm_ptr->transparent_color[0], xpm_ptr->transparent_color[1], xpm_ptr->transparent_color[2]) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(FP, "'#ffffff',0,") == EOF) { writeFileFailed = TRUE; } } } else { if (fprintf(FP, "xpm('%s','',", colorMenuItems[ObjPtr->color]) == EOF) { writeFileFailed = TRUE; } } if (ppm_z) { if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,", ltx, lty, rbx, rby, ObjPtr->id, ObjPtr->rotation, image_w, image_h) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,", ltx, lty, rbx, rby, fill, ncolors, chars_per_pixel, first_pixel_is_bg, ObjPtr->id, ObjPtr->rotation, image_w, image_h) == EOF) { writeFileFailed = TRUE; } } if (jpeg) { if (fprintf(FP, "0,%1d,%1d,%1d,%1d,%1d,%1d,%1d,\n \"%s\",", xpm_ptr->flip, ObjPtr->locked, compressed, ObjPtr->ctm!=NULL, ObjPtr->invisible, real_type, linked_jpeg, jpeg_filename) == EOF) { writeFileFailed = TRUE; } } else if (ppm_z) { if (fprintf(FP, "0,%1d,%1d,%1d,%1d,%1d,%1d,%1d,", xpm_ptr->flip, ObjPtr->locked, ObjPtr->ctm!=NULL, ObjPtr->invisible, xpm_ptr->ppm_data_compress, xpm_ptr->ppm_data_size, xpm_ptr->ppm_mask_size) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(FP, "0,%1d,%1d,%1d,%1d,%1d,", xpm_ptr->flip, ObjPtr->locked, compressed, ObjPtr->ctm!=NULL, ObjPtr->invisible) == EOF) { writeFileFailed = TRUE; } } if (ObjPtr->ctm != NULL && fprintf(FP, "[\n %1d,%1d,%1d,%1d,%1d,%1d,%g,%g,%g,%g,%1d,%1d],", ObjPtr->x, ObjPtr->y, ObjPtr->orig_obbox.ltx, ObjPtr->orig_obbox.lty, ObjPtr->orig_obbox.rbx, ObjPtr->orig_obbox.rby, ObjPtr->ctm->m[CTM_SX], ObjPtr->ctm->m[CTM_SIN], ObjPtr->ctm->m[CTM_MSIN], ObjPtr->ctm->m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY]) == EOF) { writeFileFailed = TRUE; } if (jpeg) { /* nothing to write here */ } else if (ppm_z) { if (fprintf(FP, "[\n") == EOF) writeFileFailed = TRUE; if (!WritePpmTrueData(FP, xpm_ptr)) { return; } } else { if (fprintf(FP, "[\n") == EOF) writeFileFailed = TRUE; if (!colorDisplay && xpm_ptr->red != NULL) { if (!BuildXPmBuckets(ncolors, NULL, NULL, chars_per_pixel, color_char, NULL)) { return; } } else { if (!BuildXPmBuckets(ncolors, pixels, NULL, INVALID, NULL, NULL)) { return; } } SaveXPmColors(FP, ObjPtr->color, xpm_ptr, ncolors, chars_per_pixel, color_char, color_str, pixels); SaveXPmPixels(FP, xpm_ptr, xpm_ptr->pixmap, &(xpm_ptr->image), xpm_ptr->bitmap, &(xpm_ptr->bitmap_image), image_w, image_h, ncolors, chars_per_pixel, color_char, pixels); } if (serializingFile) SaveCreatorID(FP, ObjPtr, " "); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } static void FreeAuxData(fp, ncolors, color_char, color_str, p_pixels, pixels_used, p_pixmap, p_image, p_bitmap, p_bitmap_image) FILE *fp; int ncolors; char *color_char, **color_str; int **p_pixels, *pixels_used; Pixmap *p_pixmap, *p_bitmap; XImage **p_image, **p_bitmap_image; { register int i; for (i = 0; i < ncolors; i++) free(color_str[i]); free(color_char); free(color_str); if (p_pixels != NULL && *p_pixels != NULL) free(*p_pixels); if (pixels_used != NULL) free(pixels_used); if (p_pixmap != NULL && *p_pixmap != None) { XFreePixmap(mainDisplay, *p_pixmap); } if (p_bitmap != NULL && *p_bitmap != None){ XFreePixmap(mainDisplay, *p_bitmap); } if (p_image != NULL && *p_image != NULL) XDestroyImage(*p_image); if (p_bitmap_image != NULL && *p_bitmap_image != NULL) { XDestroyImage(*p_bitmap_image); } fclose(fp); } int MyReadPixmapFile(file_name, image_w_return, image_h_return, w_return, h_return, pixmap_return, image_return, bitmap_return, bitmap_image_return, ncolors_return, chars_per_pixel_return, first_pixel_is_bg_return, color_char, color_str, pixels, xpm_data) char *file_name; int *image_w_return, *image_h_return, *w_return, *h_return; int *ncolors_return; int *chars_per_pixel_return, *first_pixel_is_bg_return; Pixmap *pixmap_return, *bitmap_return; XImage **image_return, **bitmap_image_return; char **color_char, ***color_str; int **pixels; char **xpm_data; { register int j, k; register char *c_ptr; FILE *fp; char inbuf[MAXSTRING], *line, s[MAXSTRING]; char mag_spec[MAXSTRING], *xpm_data_ptr=NULL; int i, len, format, found=FALSE, index, saved_max_colors, xpm_version=1; int x, y, w, h, chars_per_pixel, new_alloc, image_w=0, image_h=0; int *pixels_used=NULL, bg_pixel; float mag=(float)0; myReadTransparentPixmap = FALSE; if (xpm_data != NULL) *xpm_data = NULL; gnNumNewColorsInPixmapFile = 0; if ((fp=fopen(file_name, "r")) == NULL) return BitmapOpenFailed; saved_max_colors = maxColors; while (fgets(inbuf, MAXSTRING, fp) != NULL) { if (strncmp(inbuf, "#define ", 8) == 0) { xpm_version = 1; found = TRUE; break; } else if (strncmp(inbuf, "/* XPM */", 9) == 0) { xpm_version = 3; found = TRUE; break; } } if (!found) return BitmapFileInvalid; if (xpm_version == 1) { c_ptr = FindChar((int)' ', inbuf); c_ptr = ParseStr(c_ptr, (int)' ', s, sizeof(s)); len = strlen(s); if (len <= 7 || strcmp(&s[len-7], "_format") != 0) { return BitmapFileInvalid; } sscanf(c_ptr, "%d", &format); if (format != 1) { sprintf(gszMsgBox, TgLoadString(STID_CANT_IMPORT_GIVEN_FORMAT_XPM), format); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return BitmapFileInvalid; } if (fgets(inbuf, MAXSTRING, fp)==NULL) return BitmapFileInvalid; c_ptr = FindChar((int)' ', inbuf); c_ptr = ParseStr(c_ptr, (int)' ', s, sizeof(s)); len = strlen(s); if (len <= 6 || strcmp(&s[len-6], "_width") != 0) { return BitmapFileInvalid; } sscanf(c_ptr, "%d", &image_w); if (image_w_return != NULL) *image_w_return = image_w; if (fgets(inbuf, MAXSTRING, fp)==NULL) return BitmapFileInvalid; c_ptr = FindChar((int)' ', inbuf); c_ptr = ParseStr(c_ptr, (int)' ', s, sizeof(s)); len = strlen(s); if (len <= 7 || strcmp(&s[len-7], "_height") != 0) { return BitmapFileInvalid; } sscanf(c_ptr, "%d", &image_h); if (image_h_return != NULL) *image_h_return = image_h; if (fgets(inbuf, MAXSTRING, fp)==NULL) return BitmapFileInvalid; c_ptr = FindChar((int)' ', inbuf); c_ptr = ParseStr(c_ptr, (int)' ', s, sizeof(s)); len = strlen(s); if (len <= 8 || strcmp(&s[len-8], "_ncolors") != 0) { return BitmapFileInvalid; } sscanf(c_ptr, "%d", ncolors_return); if (fgets(inbuf, MAXSTRING, fp)==NULL) return BitmapFileInvalid; c_ptr = FindChar((int)' ', inbuf); c_ptr = ParseStr(c_ptr, (int)' ', s, sizeof(s)); len = strlen(s); if (len <= 16 || strcmp(&s[len-16], "_chars_per_pixel") != 0) { return BitmapFileInvalid; } sscanf(c_ptr, "%d", &chars_per_pixel); if (chars_per_pixel_return != NULL) { *chars_per_pixel_return = chars_per_pixel; } if (chars_per_pixel > 2) { sprintf(gszMsgBox, TgLoadString(STID_CANT_IMPORT_GIVEN_CPP_XPM), chars_per_pixel); Msg(gszMsgBox); return BitmapFileInvalid; } if (fgets(inbuf, MAXSTRING, fp)==NULL) return BitmapFileInvalid; len = strlen(inbuf); if (len <= 27 || strncmp(inbuf, "static char *", 13) != 0 || strncmp(&inbuf[len-14], "_colors[] = {\n", 14) != 0) { return BitmapFileInvalid; } } else { /* xpm_version is 3 */ found = FALSE; while (fgets(inbuf, MAXSTRING, fp) != NULL) { if (*inbuf == '"') { found = TRUE; break; } } if (!found) return BitmapFileInvalid; c_ptr = &inbuf[1]; if (sscanf(c_ptr, "%d %d %d %d", &image_w, &image_h, ncolors_return, &chars_per_pixel) != 4) { return BitmapFileInvalid; } if (image_w_return != NULL) *image_w_return = image_w; if (image_h_return != NULL) *image_h_return = image_h; if (chars_per_pixel_return != NULL) { *chars_per_pixel_return = chars_per_pixel; } } *color_char = (char*)malloc((*ncolors_return)*(chars_per_pixel)*sizeof(char)+1); *color_str = (char**)malloc((*ncolors_return)*sizeof(char*)); if (color_char == NULL || color_str == NULL) FailAllocMessage(); if (pixels != NULL) { *pixels = (int*)malloc((*ncolors_return)*sizeof(int)); pixels_used = (int*)malloc((*ncolors_return)*sizeof(int)); if (*pixels == NULL || pixels_used == NULL) FailAllocMessage(); memset(pixels_used, 0, (*ncolors_return)*sizeof(int)); } if (pixmap_return != NULL) *pixmap_return = None; if (bitmap_return != NULL) *bitmap_return = None; if (image_return != NULL) *image_return = NULL; if (bitmap_image_return != NULL) *bitmap_image_return = NULL; if (first_pixel_is_bg_return != NULL) *first_pixel_is_bg_return = FALSE; bg_pixel = GetDrawingBgPixel(INVALID, INVALID); if (xpm_version == 1) { for (i = 0; i < *ncolors_return; i++) { if (fgets(inbuf, MAXSTRING, fp) == NULL) { FreeAuxData(fp, i, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); return BitmapFileInvalid; } c_ptr = FindChar((int)'"', inbuf); for (j = 0; j < chars_per_pixel; j++) { (*color_char)[i*(chars_per_pixel)+j] = c_ptr[j]; } if (guessXPmBgColor && i == 0 && ((chars_per_pixel == 1 && (*c_ptr=='`' || *c_ptr==' ')) || (chars_per_pixel == 2 && ((c_ptr[0]=='`' && c_ptr[1]=='`') || (c_ptr[0]==' ' && c_ptr[1]==' '))))) { strcpy(s, (myFileBgColorStr==NULL ? myBgColorStr : myFileBgColorStr)); if (pixels != NULL) (*pixels)[0] = bg_pixel; if (first_pixel_is_bg_return != NULL) { *first_pixel_is_bg_return = TRUE; } } else { c_ptr = FindChar((int)'"', c_ptr); c_ptr = FindChar((int)'"', c_ptr); ParseStr(c_ptr, (int)'"', s, sizeof(s)); if (pixels != NULL) { if (UtilStrICmp(s, "None") == 0) { (*pixels)[i] = (-1); myReadTransparentPixmap = TRUE; } else if ((index=QuickFindColorIndex(NULL, s, &new_alloc, TRUE)) == INVALID) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANNOT_ALLOC_COLOR_USE_ALT), s, colorMenuItems[colorIndex]); Msg(gszMsgBox); strcpy(s, colorMenuItems[colorIndex]); (*pixels)[i] = colorPixels[colorIndex]; allocColorFailed = TRUE; } else { (*pixels)[i] = colorPixels[index]; } } else { if (UtilStrICmp(s, "None") == 0) { myReadTransparentPixmap = TRUE; } } } len = strlen(s); (*color_str)[i] = (char*)malloc((len+1)*sizeof(char)); if ((*color_str)[i] == NULL) FailAllocMessage(); strcpy((*color_str)[i], s); } if (fgets(inbuf, MAXSTRING, fp) == NULL || inbuf[0] != '}' || fgets(inbuf, MAXSTRING, fp) == NULL) { FreeAuxData(fp, *ncolors_return, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); return BitmapFileInvalid; } len = strlen(inbuf); if (len <= 27 || strncmp(inbuf, "static char *", 13) != 0 || strncmp(&inbuf[len-14], "_pixels[] = {\n", 14) != 0) { return BitmapFileInvalid; } } else { /* xpm_version is 3 */ for (i=0; i < *ncolors_return; i++) { if (i == 0) { found = FALSE; while (fgets(inbuf, MAXSTRING, fp) != NULL) { if (*inbuf == '"') { found = TRUE; break; } } if (!found) { FreeAuxData(fp, i, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); return BitmapFileInvalid; } } else if (fgets(inbuf, MAXSTRING, fp) == NULL) { FreeAuxData(fp, i, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); return BitmapFileInvalid; } c_ptr = FindChar((int)'"', inbuf); for (j = 0; j < chars_per_pixel; j++) { (*color_char)[i*(chars_per_pixel)+j] = c_ptr[j]; } if (guessXPmBgColor && i == 0 && ((chars_per_pixel == 1 && (*c_ptr=='`' || *c_ptr==' ')) || (chars_per_pixel == 2 && ((c_ptr[0]=='`' && c_ptr[1]=='`') || (c_ptr[0]==' ' && c_ptr[1]==' '))))) { strcpy(s, (myFileBgColorStr==NULL ? myBgColorStr : myFileBgColorStr)); if (pixels != NULL) (*pixels)[0] = bg_pixel; if (first_pixel_is_bg_return != NULL) { *first_pixel_is_bg_return = TRUE; } } else { char *ptr; c_ptr += chars_per_pixel; while (*c_ptr != '\0') { while (*c_ptr == ' ' || *c_ptr == '\t') c_ptr++; if ((*c_ptr == 'c' || *c_ptr == 'm') && (c_ptr[1]==' ' || c_ptr[1]=='\t')) { break; } while (*c_ptr!=' ' && *c_ptr!='\t' && *c_ptr!='\0') c_ptr++; while (*c_ptr == ' ' || *c_ptr == '\t') c_ptr++; while (*c_ptr!=' ' && *c_ptr!='\t' && *c_ptr!='\0') c_ptr++; } if (*c_ptr++ == '\0') { FreeAuxData(fp, i, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); return BitmapFileInvalid; } while (*c_ptr == ' ' || *c_ptr == '\t') c_ptr++; for (ptr=c_ptr; *ptr != '"' && *ptr != '\0'; ptr++) { if (*ptr == ' ' || *ptr == '\t') { char tmp_ch=ptr[1]; if (tmp_ch == 'm' || tmp_ch == 's') { tmp_ch = ptr[2]; if (tmp_ch == ' ' || tmp_ch == '\t') { break; } } else if (tmp_ch == 'g') { tmp_ch = ptr[2]; if (tmp_ch == ' ' || tmp_ch == '\t') { break; } else if (tmp_ch == '4') { tmp_ch = ptr[4]; if (tmp_ch == ' ' || tmp_ch == '\t') { break; } } } } } if (*ptr == '\0') { FreeAuxData(fp, i, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); return BitmapFileInvalid; } while (ptr >= c_ptr) { if (*ptr == ' ' || *ptr == '\t' || *ptr == '"') { ptr--; } else { break; } } if (ptr < c_ptr) { FreeAuxData(fp, i, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); return BitmapFileInvalid; } *(++ptr) = '\0'; strcpy(s, c_ptr); if (pixels != NULL) { if (UtilStrICmp(s, "None") == 0) { (*pixels)[i] = (-1); myReadTransparentPixmap = TRUE; } else if ((index=QuickFindColorIndex(NULL, s, &new_alloc, TRUE)) == INVALID) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANNOT_ALLOC_COLOR_USE_ALT), s, colorMenuItems[colorIndex]); Msg(gszMsgBox); strcpy(s, colorMenuItems[colorIndex]); (*pixels)[i] = colorPixels[colorIndex]; allocColorFailed = TRUE; } else { (*pixels)[i] = colorPixels[index]; } } else { if (UtilStrICmp(s, "None") == 0) { myReadTransparentPixmap = TRUE; } } } len = strlen(s); (*color_str)[i] = (char*)malloc((len+1)*sizeof(char)); if ((*color_str)[i] == NULL) FailAllocMessage(); strcpy((*color_str)[i], s); } } if (chars_per_pixel_return == NULL && first_pixel_is_bg_return == NULL && pixels == NULL && xpm_data == NULL) { /* just getting the colors, so no need to read data */ if (pixels_used != NULL) free(pixels_used); return BitmapSuccess; } x = 0; y = 0; w = image_w; h = image_h; if (pixmap_return != NULL && bitmap_return != NULL && image_return != NULL && bitmap_image_return != NULL) { mag = 1.0; if (askForXPmSpec) { sprintf(gszMsgBox, TgLoadString(STID_ENTER_GEOM_SPEC_ORIG_SIZE), image_w, image_h); *mag_spec = '\0'; Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CONTINUE), mag_spec); if (*mag_spec != '\0') { ParseCutSpec(mag_spec, image_w, image_h, &mag, &x, &y, &w, &h); } } *pixmap_return = XCreatePixmap(mainDisplay, dummyPixmap, w, h, mainDepth); *bitmap_return = XCreatePixmap(mainDisplay, dummyBitmap, w, h, 1); if (*pixmap_return == None || *bitmap_return == None) { FreeAuxData(fp, *ncolors_return, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); return BitmapNoMemory; } XFillRectangle(mainDisplay, *pixmap_return, xpmGC, 0, 0, w, h); XSetForeground(mainDisplay, xbmGC, 1); XFillRectangle(mainDisplay, *bitmap_return, xbmGC, 0, 0, w, h); XSetForeground(mainDisplay, xbmGC, 0); *image_return = XGetImage(mainDisplay, *pixmap_return, 0, 0, w, h, AllPlanes, ZPixmap); *bitmap_image_return = XGetImage(mainDisplay, *bitmap_return, 0, 0, w, h, 1, ZPixmap); if (*image_return == NULL || *bitmap_image_return == NULL) { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); FreeAuxData(fp, *ncolors_return, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); return BitmapNoMemory; } } if (!BuildXPmBuckets(*ncolors_return, NULL, NULL, chars_per_pixel, *color_char, NULL)) { FreeAuxData(fp, *ncolors_return, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); return BitmapFileInvalid; } if (!colorDisplay) { if (xpm_data != NULL) { xpm_data_ptr = *xpm_data = (char*)malloc( image_w*image_h*chars_per_pixel*sizeof(char)+1); if (*xpm_data == NULL) FailAllocMessage(); } } line = (char*)malloc((image_w*chars_per_pixel+20)*sizeof(char)); if (line == NULL) FailAllocMessage(); for (i=0; i < y+h; i++) { if (xpm_version == 3 && i == 0) { found = FALSE; while (fgets(line, image_w*chars_per_pixel+20, fp) != NULL) { if (*line == '"') { found = TRUE; break; } } if (!found) { FreeAuxData(fp, *ncolors_return, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); return BitmapFileInvalid; } } else if (fgets(line, image_w*chars_per_pixel+20, fp)==NULL) { FreeAuxData(fp, *ncolors_return, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); free(line); return BitmapFileInvalid; } if (i >= y) { c_ptr = FindChar((int)'"', line); if (xpm_data_ptr != NULL) { strncpy(xpm_data_ptr, c_ptr, image_w*chars_per_pixel); xpm_data_ptr += image_w*chars_per_pixel; } if (pixels != NULL) { for (j=0; j < x+w; j++, c_ptr+=chars_per_pixel) { if (j >= x) { k = XPmLookUp(INVALID, chars_per_pixel, c_ptr, NULL); if (k == INVALID) { FreeAuxData(fp, *ncolors_return, *color_char, *color_str, pixels, pixels_used, pixmap_return, image_return, bitmap_return, bitmap_image_return); free(line); return BitmapFileInvalid; } if (pixels_used != NULL) pixels_used[k] = TRUE; if ((*pixels)[k] == (-1)) { if (bitmap_image_return != NULL) { XPutPixel(*bitmap_image_return, j-x, i-y, 0); } if (image_return != NULL) { XPutPixel(*image_return, j-x, i-y, colorPixels[colorIndex]); } } else { if (image_return != NULL) { XPutPixel(*image_return, j-x, i-y, (*pixels)[k]); } } } } } } } if (xpm_data_ptr != NULL) *xpm_data_ptr = '\0'; free(line); fclose(fp); if (pixmap_return != NULL && image_return != NULL) { XPutImage(mainDisplay,*pixmap_return,xpmGC,*image_return,0,0,0,0,w,h); } if (bitmap_return != NULL && bitmap_image_return != NULL) { XPutImage(mainDisplay, *bitmap_return, xbmGC, *bitmap_image_return, 0, 0, 0, 0, w, h); } if (image_w_return != NULL) *image_w_return = w; if (image_h_return != NULL) *image_h_return = h; if (w_return != NULL) *w_return = (int)(((float)w) * mag); if (h_return != NULL) *h_return = (int)(((float)h) * mag); if (pixels != NULL) { int new_ncolors=0; for (i=0; i < *ncolors_return; i++) { if (pixels_used[i]) { new_ncolors++; } } if (new_ncolors < *ncolors_return) { /* some pixels are not used */ char *new_color_char=(char*)malloc( new_ncolors*chars_per_pixel*sizeof(char)); char **new_color_str=(char**)malloc(new_ncolors*sizeof(char *)); int *new_pixels=(int*)malloc(new_ncolors*sizeof(int)); if (new_color_char == NULL || new_color_str == NULL || new_pixels == NULL) { FailAllocMessage(); } else { int new_index=0, ok=TRUE; for (i=0; i < *ncolors_return; i++) { if (pixels_used[i]) { int j; strncpy(&new_color_char[new_index*chars_per_pixel], &(*color_char)[i*chars_per_pixel], chars_per_pixel*sizeof(char)); new_color_str[new_index] = UtilStrDup((*color_str)[i]); if (new_color_str[new_index] == NULL) { for (j=0; j < i; j++) { free(new_color_str[j]); } free(new_color_char); free(new_color_str); free(new_pixels); new_color_char = NULL; new_color_str = NULL; new_pixels = NULL; ok = FALSE; break; } new_pixels[new_index] = (*pixels)[i]; new_index++; } } if (ok) { free(*color_char); *color_char = new_color_char; for (i=0; i < *ncolors_return; i++) { free((*color_str)[i]); } free(*color_str); *color_str = new_color_str; free(*pixels); *pixels = new_pixels; if (first_pixel_is_bg_return != NULL && *first_pixel_is_bg_return && pixels_used[0]) { *first_pixel_is_bg_return = FALSE; } new_color_char = NULL; new_color_str = NULL; new_pixels = NULL; *ncolors_return = new_ncolors; } } if (new_color_char != NULL) free(new_color_char); if (new_color_str != NULL) free(new_color_str); if (new_pixels != NULL) free(new_pixels); } } if (pixels_used != NULL) free(pixels_used); gnNumNewColorsInPixmapFile = maxColors - saved_max_colors; if (gnNumNewColorsInPixmapFile != 0) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_GIVEN_ADDTNL_COLOR_ALLOCATED), gnNumNewColorsInPixmapFile); Msg(gszMsgBox); } return BitmapSuccess; } void ReadXPmObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { struct XPmRec *xpm_ptr; char color_s[40], trans_color_s[40], *s, inbuf[MAXSTRING], *c_ptr, *line; int ltx, lty, rbx, rby, i, j, k, image_w, image_h; int ncolors, * pixels, len, index, fill, color_index; int *red=NULL, *green=NULL, *blue=NULL; int unrecognized_color = FALSE, rotation, chars_per_pixel; int first_pixel_is_bg, first_pixel_maybe_bg, new_alloc; int id=0, rotate=ROTATE0, flip=NO_FLIP, locked=FALSE; int compressed=FALSE, real_x=0, real_y=0; int transformed=FALSE, invisible=FALSE, bg_pixel; char *xpm_data=NULL, *color_char, **color_str; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; struct XfrmMtrxRec *ctm=NULL; struct BBRec orig_obbox; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_s, sizeof(color_s)); if (fileVersion >= 37) { s = ParseStr(s, (int)',', trans_color_s, sizeof(trans_color_s)); } InitScan(s, "\t\n, "); rotation = 0; chars_per_pixel = 1; first_pixel_maybe_bg = TRUE; first_pixel_is_bg = TRUE; if (fileVersion <= 9) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_INVALID_FILEVER_FOR_XPM), fileVersion); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return; } else if (fileVersion <= 13) { if (GETINT("xpixmap", ltx, "ltx") == INVALID || GETINT("xpixmap", lty, "lty") == INVALID || GETINT("xpixmap", rbx, "rbx") == INVALID || GETINT("xpixmap", rby, "rby") == INVALID || GETINT("xpixmap", fill, "fill") == INVALID || GETINT("xpixmap", ncolors, "ncolors") == INVALID || GETINT("xpixmap", id, "id") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 14) { if (GETINT("xpixmap", ltx, "ltx") == INVALID || GETINT("xpixmap", lty, "lty") == INVALID || GETINT("xpixmap", rbx, "rbx") == INVALID || GETINT("xpixmap", rby, "rby") == INVALID || GETINT("xpixmap", fill, "fill") == INVALID || GETINT("xpixmap", ncolors, "ncolors") == INVALID || GETINT("xpixmap", id, "id") == INVALID || GETINT("xpixmap", rotation, "rotation") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 22) { if (GETINT("xpixmap", ltx, "ltx") == INVALID || GETINT("xpixmap", lty, "lty") == INVALID || GETINT("xpixmap", rbx, "rbx") == INVALID || GETINT("xpixmap", rby, "rby") == INVALID || GETINT("xpixmap", fill, "fill") == INVALID || GETINT("xpixmap", ncolors, "ncolors") == INVALID || GETINT("xpixmap", chars_per_pixel, "chars_per_pixel") == INVALID || GETINT("xpixmap", first_pixel_is_bg,"first_pixel_is_bg") == INVALID || GETINT("xpixmap", id, "id") == INVALID || GETINT("xpixmap", rotation, "rotation") == INVALID) { return; } if (id >= objId) objId = id+1; first_pixel_maybe_bg = FALSE; } else if (fileVersion <= 25) { if (GETINT("xpixmap", ltx, "ltx") == INVALID || GETINT("xpixmap", lty, "lty") == INVALID || GETINT("xpixmap", rbx, "rbx") == INVALID || GETINT("xpixmap", rby, "rby") == INVALID || GETINT("xpixmap", fill, "fill") == INVALID || GETINT("xpixmap", ncolors, "ncolors") == INVALID || GETINT("xpixmap", chars_per_pixel, "chars_per_pixel") == INVALID || GETINT("xpixmap", first_pixel_is_bg,"first_pixel_is_bg") == INVALID || GETINT("xpixmap", id, "id") == INVALID || GETINT("xpixmap", rotation, "rotation") == INVALID || GETINT("xpixmap", image_w, "image_w") == INVALID || GETINT("xpixmap", image_h, "image_h") == INVALID || GETINT("xpixmap", rotate, "rotate") == INVALID || GETINT("xpixmap", flip, "flip") == INVALID) { return; } if (id >= objId) objId = id+1; first_pixel_maybe_bg = FALSE; } else if (fileVersion <= 32) { if (GETINT("xpixmap", ltx, "ltx") == INVALID || GETINT("xpixmap", lty, "lty") == INVALID || GETINT("xpixmap", rbx, "rbx") == INVALID || GETINT("xpixmap", rby, "rby") == INVALID || GETINT("xpixmap", fill, "fill") == INVALID || GETINT("xpixmap", ncolors, "ncolors") == INVALID || GETINT("xpixmap", chars_per_pixel, "chars_per_pixel") == INVALID || GETINT("xpixmap", first_pixel_is_bg,"first_pixel_is_bg") == INVALID || GETINT("xpixmap", id, "id") == INVALID || GETINT("xpixmap", rotation, "rotation") == INVALID || GETINT("xpixmap", image_w, "image_w") == INVALID || GETINT("xpixmap", image_h, "image_h") == INVALID || GETINT("xpixmap", rotate, "rotate") == INVALID || GETINT("xpixmap", flip, "flip") == INVALID || GETINT("xpixmap", locked, "locked") == INVALID) { return; } if (id >= objId) objId = id+1; first_pixel_maybe_bg = FALSE; } else { if (GETINT("xpixmap", ltx, "ltx") == INVALID || GETINT("xpixmap", lty, "lty") == INVALID || GETINT("xpixmap", rbx, "rbx") == INVALID || GETINT("xpixmap", rby, "rby") == INVALID || GETINT("xpixmap", fill, "fill") == INVALID || GETINT("xpixmap", ncolors, "ncolors") == INVALID || GETINT("xpixmap", chars_per_pixel, "chars_per_pixel") == INVALID || GETINT("xpixmap", first_pixel_is_bg,"first_pixel_is_bg") == INVALID || GETINT("xpixmap", id, "id") == INVALID || GETINT("xpixmap", rotation, "rotation") == INVALID || GETINT("xpixmap", image_w, "image_w") == INVALID || GETINT("xpixmap", image_h, "image_h") == INVALID || GETINT("xpixmap", rotate, "rotate") == INVALID || GETINT("xpixmap", flip, "flip") == INVALID || GETINT("xpixmap", locked, "locked") == INVALID || GETINT("xpixmap", compressed, "compressed") == INVALID || GETINT("xpixmap", transformed, "transformed") == INVALID || GETINT("xpixmap", invisible, "invisible") == INVALID) { return; } if (id >= objId) objId = id+1; first_pixel_maybe_bg = FALSE; } if (fileVersion <= 22) { image_w = rbx-ltx; image_h = rby-lty; rotate = ROTATE0; flip = 0; } if (fileVersion >= 33 && transformed) { (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, "); ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ctm == NULL) FailAllocMessage(); if (GETINT("xpixmap", real_x, "real_x") == INVALID || GETINT("xpixmap", real_y, "real_y") == INVALID || GETINT("xpixmap", orig_obbox.ltx, "orig_obbox.ltx") == INVALID || GETINT("xpixmap", orig_obbox.lty, "orig_obbox.lty") == INVALID || GETINT("xpixmap", orig_obbox.rbx, "orig_obbox.rbx") == INVALID || GETINT("xpixmap", orig_obbox.rby, "orig_obbox.rby") == INVALID || GETDBL("xpixmap", ctm->m[CTM_SX], "CTM_SX") == INVALID || GETDBL("xpixmap", ctm->m[CTM_SIN], "CTM_SIN") == INVALID || GETDBL("xpixmap", ctm->m[CTM_MSIN], "CTM_MSIN") == INVALID || GETDBL("xpixmap", ctm->m[CTM_SY], "CTM_SY") == INVALID || GETINT("xpixmap", ctm->t[CTM_TX], "CTM_TX") == INVALID || GETINT("xpixmap", ctm->t[CTM_TY], "CTM_TY") == INVALID) { return; } } fill = UpgradePenFill(fill); *ObjPtr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (*ObjPtr == NULL) FailAllocMessage(); memset(*ObjPtr, 0, sizeof(struct ObjRec)); xpm_ptr = (struct XPmRec *)malloc(sizeof(struct XPmRec)); if (xpm_ptr == NULL) FailAllocMessage(); memset(xpm_ptr, 0, sizeof(struct XPmRec)); color_index = QuickFindColorIndex(*ObjPtr, color_s, &new_alloc, TRUE); (*ObjPtr)->color = color_index; if (mainDisplay != NULL) { UtilStrCpyN((*ObjPtr)->color_str, sizeof((*ObjPtr)->color_str), colorMenuItems[color_index]); } (*ObjPtr)->dirty = FALSE; (*ObjPtr)->id = id; (*ObjPtr)->rotation = rotation; (*ObjPtr)->locked = locked; (*ObjPtr)->type = OBJ_XPM; (*ObjPtr)->obbox.ltx = (*ObjPtr)->bbox.ltx = (*ObjPtr)->x = ltx; (*ObjPtr)->obbox.lty = (*ObjPtr)->bbox.lty = (*ObjPtr)->y = lty; (*ObjPtr)->obbox.rbx = (*ObjPtr)->bbox.rbx = rbx; (*ObjPtr)->obbox.rby = (*ObjPtr)->bbox.rby = rby; (*ObjPtr)->detail.xpm = xpm_ptr; (*ObjPtr)->ctm = ctm; (*ObjPtr)->invisible = invisible; if (ctm != NULL) { memcpy(&(*ObjPtr)->orig_obbox, &orig_obbox, sizeof(struct BBRec)); (*ObjPtr)->x = real_x; (*ObjPtr)->y = real_y; GetTransformedOBBoxOffsetVs(*ObjPtr, (*ObjPtr)->rotated_obbox); } color_char = (char*)malloc(ncolors*chars_per_pixel*sizeof(char)); color_str = (char**)malloc(ncolors*sizeof(char*)); pixels = (int*)malloc(ncolors*sizeof(int)); if (color_char == NULL || color_str == NULL || pixels == NULL) { FailAllocMessage(); } if (fileVersion >= 25 && ((PRTGIF && !cmdLineOpenDisplay) || !colorDisplay)) { red = (int*)malloc(ncolors*sizeof(int)); green = (int*)malloc(ncolors*sizeof(int)); blue = (int*)malloc(ncolors*sizeof(int)); if (red == NULL || green == NULL || blue == NULL) FailAllocMessage(); } xpm_ptr->pixmap = None; xpm_ptr->image = NULL; xpm_ptr->bitmap = None; xpm_ptr->bitmap_image = NULL; xpm_ptr->cached_pixmap = None; xpm_ptr->cached_bitmap = None; xpm_ptr->cached_zoom = 0; xpm_ptr->data = NULL; xpm_ptr->fill = fill; xpm_ptr->flip = flip; xpm_ptr->cached_flip = 0; xpm_ptr->cached_w = xpm_ptr->cached_h = 0; xpm_ptr->cached_color = (-1); xpm_ptr->image_w = image_w; xpm_ptr->image_h = image_h; xpm_ptr->ncolors = ncolors; xpm_ptr->chars_per_pixel = chars_per_pixel; xpm_ptr->first_pixel_is_bg = first_pixel_is_bg; xpm_ptr->color_char = color_char; xpm_ptr->color_str = color_str; xpm_ptr->pixels = pixels; xpm_ptr->red = red; xpm_ptr->green = green; xpm_ptr->blue = blue; bg_pixel = GetDrawingBgPixel(INVALID, INVALID); for (i=0; i < ncolors; i++) { (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; c_ptr = FindChar((int)'"', inbuf); for (j = 0; j < chars_per_pixel; j++) { color_char[i*chars_per_pixel+j] = c_ptr[j]; } c_ptr = FindChar((int)'"', c_ptr); c_ptr = FindChar((int)'"', c_ptr); c_ptr = ParseStr(c_ptr, (int)'"', color_s, sizeof(color_s)); if (!PRTGIF || cmdLineOpenDisplay) { if (i == 0 && (first_pixel_is_bg || (first_pixel_maybe_bg && (color_char[i]=='`' || color_char[i]==' ')))) { strcpy(color_s, (myFileBgColorStr==NULL ? myBgColorStr : myFileBgColorStr)); pixels[i] = bg_pixel; xpm_ptr->first_pixel_is_bg = first_pixel_is_bg = TRUE; } else if (UtilStrICmp(color_s, "None") == 0) { pixels[i] = (-1); } else if ((index = QuickFindColorIndex(NULL, color_s, &new_alloc, TRUE)) == INVALID) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANNOT_ALLOC_COLOR_USE_ALT), color_s, colorMenuItems[colorIndex]); Msg(gszMsgBox); allocColorFailed = TRUE; strcpy(color_s, colorMenuItems[colorIndex]); pixels[i] = colorPixels[colorIndex]; } else { pixels[i] = colorPixels[index]; } len = strlen(color_s); color_str[i] = (char*)malloc((len+1)*sizeof(char)); if (color_str[i] == NULL) FailAllocMessage(); strcpy(color_str[i], color_s); } if (fileVersion >= 25 && ((PRTGIF && !cmdLineOpenDisplay) || !colorDisplay)) { /* has RGB information for PRTGIF */ InitScan(c_ptr, "\t\n, "); if (GETINT("xpixmap", red[i], "red") == INVALID || GETINT("xpixmap", green[i], "green") == INVALID || GETINT("xpixmap", blue[i], "blue") == INVALID) { return; } if (UtilStrICmp(color_s, "None") == 0) { red[i] = green[i] = blue[i] = (-1); } else if (PRTGIF && cmdLineColor && (prTgifFoundColorInfo || !cmdLineOpenDisplay)) { int found_index=PrTgifFindColorIndex(NULL, color_s); if (found_index != INVALID) { red[i] = (int)(10000*((int)tgifColors[found_index].red)/maxRGB); green[i] = (int)(10000*((int)tgifColors[found_index].green)/maxRGB); blue[i] = (int)(10000*((int)tgifColors[found_index].blue)/maxRGB); } } } } xpm_ptr->clip_mask = None; if (PRTGIF && !cmdLineOpenDisplay) { xpm_data = (char*)malloc(image_w*image_h*chars_per_pixel*sizeof(char)); if (xpm_data == NULL) FailAllocMessage(); xpm_ptr->data = xpm_data; line = (char*)malloc((image_w*chars_per_pixel+20)*sizeof(char)); if (line == NULL) FailAllocMessage(); for (i=0; i < image_h; i++, xpm_data += image_w*chars_per_pixel) { (void)fgets(line, image_w*chars_per_pixel+20, FP); scanLineNum++; c_ptr = &line[4]; strncpy(xpm_data, c_ptr, image_w*chars_per_pixel); } free(line); } else { if (fileVersion >= 25 && !colorDisplay) { xpm_data = (char*)malloc(image_w*image_h*chars_per_pixel*sizeof(char)); if (xpm_data == NULL) FailAllocMessage(); xpm_ptr->data = xpm_data; } pixmap = XCreatePixmap(mainDisplay, dummyPixmap, image_w, image_h, mainDepth); bitmap = XCreatePixmap(mainDisplay, dummyPixmap, image_w, image_h, 1); XFillRectangle(mainDisplay, pixmap, xpmGC, 0, 0, image_w, image_h); XSetForeground(mainDisplay, xbmGC, 1); XFillRectangle(mainDisplay, bitmap, xbmGC, 0, 0, image_w, image_h); XSetForeground(mainDisplay, xbmGC, 0); image = XGetImage(mainDisplay, pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); bitmap_image = XGetImage(mainDisplay, bitmap, 0, 0, image_w, image_h, 1, ZPixmap); if (image == NULL || bitmap_image == NULL) { MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); XFreePixmap(mainDisplay, pixmap); XFreePixmap(mainDisplay, bitmap); if (image != NULL) XDestroyImage(image); if (bitmap_image != NULL) XDestroyImage(bitmap_image); return; } if (!BuildXPmBuckets(ncolors, NULL, NULL, chars_per_pixel, color_char, NULL)) { XFreePixmap(mainDisplay, pixmap); XFreePixmap(mainDisplay, bitmap); if (image != NULL) XDestroyImage(image); if (bitmap_image != NULL) XDestroyImage(bitmap_image); return; } line = (char*)malloc((image_w*chars_per_pixel+20)*sizeof(char)); if (line == NULL) FailAllocMessage(); for (i=0; i < image_h; i++) { (void)fgets(line, image_w*chars_per_pixel+20, FP); scanLineNum++; c_ptr = &line[4]; if (xpm_data != NULL) { strncpy(xpm_data, c_ptr, image_w*chars_per_pixel); } for (j = 0; j < image_w; j++, c_ptr+=chars_per_pixel) { k = XPmLookUp(INVALID, chars_per_pixel, c_ptr, NULL); if (k == INVALID) { XPutPixel(image, j, i, pixels[0]); unrecognized_color = TRUE; } else if (pixels[k] == (-1)) { XPutPixel(bitmap_image, j, i, 0); XPutPixel(image, j, i, colorPixels[color_index]); } else { XPutPixel(image, j, i, pixels[k]); } } if (xpm_data != NULL) xpm_data += image_w*chars_per_pixel; } free(line); XPutImage(mainDisplay,pixmap,xpmGC,image,0,0,0,0,image_w,image_h); XPutImage(mainDisplay,bitmap,xbmGC,bitmap_image,0,0,0,0,image_w,image_h); xpm_ptr->pixmap = pixmap; xpm_ptr->image = image; xpm_ptr->bitmap = bitmap; xpm_ptr->bitmap_image = bitmap_image; if (unrecognized_color) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_COLOR_SUBS_FOR_UNRECOG_IN_XPM), color_str[0]); Msg(gszMsgBox); } } if (fileVersion < 33 && (rotate != ROTATE0 || flip != NO_FLIP)) { double dz=(double)0.0, d1=(double)1000.0, dm1=((double)-1000.0); if (rotate == ROTATE90 || rotate == ROTATE270) { int h=(*ObjPtr)->obbox.rbx-(*ObjPtr)->obbox.ltx; int w=(*ObjPtr)->obbox.rby-(*ObjPtr)->obbox.lty; (*ObjPtr)->obbox.rby = (*ObjPtr)->obbox.lty + h; (*ObjPtr)->obbox.rbx = (*ObjPtr)->obbox.ltx + w; } ltx = ((*ObjPtr)->obbox.ltx); lty = ((*ObjPtr)->obbox.lty); SetRotatePivotByObject(*ObjPtr); if (flip & HORI_EVEN) { ShearObj(*ObjPtr, CORNER_LEFT, dz, dz, dm1, d1, <x, <y); } if (flip & VERT_EVEN) { ShearObj(*ObjPtr, CORNER_TOP, dz, dz, d1, dm1, <x, <y); } if (rotate == ROTATE0) { if (flip & (HORI_ODD | VERT_ODD)) { RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); if (flip & HORI_ODD) { ShearObj(*ObjPtr, CORNER_LEFT, dz, dz, dm1, d1, <x, <y); } if (flip & VERT_ODD) { ShearObj(*ObjPtr, CORNER_TOP, dz, dz, d1, dm1, <x, <y); } RotateObj(*ObjPtr, CORNER_LT, COUNTER90, <x, <y); } } else { switch (rotate) { case ROTATE90: RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); if (flip & HORI_ODD) { ShearObj(*ObjPtr, CORNER_LEFT, dz, dz, dm1, d1, <x, <y); } if (flip & VERT_ODD) { ShearObj(*ObjPtr, CORNER_TOP, dz, dz, d1, dm1, <x, <y); } break; case ROTATE180: RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); if (flip & HORI_ODD) { ShearObj(*ObjPtr, CORNER_LEFT, dz, dz, dm1, d1, <x, <y); } if (flip & VERT_ODD) { ShearObj(*ObjPtr, CORNER_TOP, dz, dz, d1, dm1, <x, <y); } RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); break; case ROTATE270: RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); if (flip & HORI_ODD) { ShearObj(*ObjPtr, CORNER_LEFT, dz, dz, dm1, d1, <x, <y); } if (flip & VERT_ODD) { ShearObj(*ObjPtr, CORNER_TOP, dz, dz, d1, dm1, <x, <y); } RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); RotateObj(*ObjPtr, CORNER_LT, CLOCKWISE90, <x, <y); break; } } xpm_ptr->flip = NO_FLIP; } } static struct ObjRec *MyReadJpegFileSkipData(jpeg_filename, expected_image_w, expected_image_h) char *jpeg_filename; int expected_image_w, expected_image_h; { FILE *ppm_fp=NULL; char tmp_fname[MAXPATHLENGTH+1]; int rc=0, format=0, image_w=0, image_h=0, max_val=0; struct ObjRec *obj_ptr=NULL; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); rc = ConvertJpegToPpm6(jpeg_filename, tmp_fname, sizeof(tmp_fname)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (!rc) { return NULL; } ppm_fp = fopen(tmp_fname, "r"); if (ppm_fp == NULL) { FailToOpenMessage(tmp_fname, "r", NULL); return NULL; } if (!ReadPpmHeader(ppm_fp, tmp_fname, &format, &image_w, &image_h, &max_val)) { fclose(ppm_fp); return NULL; } fclose(ppm_fp); if (expected_image_w != (-1) && expected_image_h != (-1) && (image_w != expected_image_w || image_h != expected_image_h)) { sprintf(gszMsgBox, TgLoadString(STID_JPEG_DIM_NOT_MATCH_DELETED), image_w, image_h, jpeg_filename, expected_image_w, expected_image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } obj_ptr = CreateXPmObj(image_w, image_h, image_w, image_h, None, NULL, None, NULL, (-1), 1, FALSE, NULL, NULL, NULL, NULL); unlink(tmp_fname); return obj_ptr; } static struct ObjRec *MyReadJpegFile(jpeg_filename, expected_image_w, expected_image_h) char *jpeg_filename; int expected_image_w, expected_image_h; { char tmp_fname[MAXPATHLENGTH+1]; int rc=0, ncolors=0, chars_per_pixel=0, *pixels=NULL; int first_pixel_is_bg=FALSE, image_w=0, image_h=0, w=0, h=0; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; char *color_char, **color_str=NULL, *xpm_data=NULL; struct ObjRec *obj_ptr=NULL; if (fullTrueColorMode && HasZlibSupport()) { struct XPmRec *xpm_ptr=NULL; char ppm6_fname[MAXPATHLENGTH+1]; rc = ConvertJpegToPpm6(jpeg_filename, ppm6_fname, sizeof(ppm6_fname)); if (!rc) return NULL; ResetPngHeaderInfo(&gPngHeaderInfo); obj_ptr = CreatePpmTrueObjFromFile(ppm6_fname); unlink(ppm6_fname); if (obj_ptr == NULL) return NULL; xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_JPEG_COMPRESS; xpm_ptr->ppm_data = ReadFileIntoBuf( jpeg_filename, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; if (expected_image_w != (-1) && expected_image_h != (-1) && (xpm_ptr->image_w != expected_image_w || xpm_ptr->image_h != expected_image_h)) { sprintf(gszMsgBox, TgLoadString(STID_JPEG_DIM_NOT_MATCH_DELETED), xpm_ptr->image_w, xpm_ptr->image_h, jpeg_filename, expected_image_w, expected_image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } return obj_ptr; } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); *tmp_fname = '\0'; rc = ConvertJpegToXpm(jpeg_filename, tmp_fname, sizeof(tmp_fname)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (!rc) { return NULL; } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(tmp_fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if (rc != BitmapSuccess) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } if (expected_image_w != (-1) && expected_image_h != (-1) && (image_w != expected_image_w || image_h != expected_image_h)) { sprintf(gszMsgBox, TgLoadString(STID_JPEG_DIM_NOT_MATCH_DELETED), image_w, image_h, jpeg_filename, expected_image_w, expected_image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); unlink(tmp_fname); return obj_ptr; } void ReadJpegObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { struct XPmRec *xpm_ptr=NULL; char color_s[40], trans_color_s[40], *s=NULL, inbuf[MAXSTRING]; char *jpeg_filename=NULL; int ltx, lty, rbx, rby, image_w=0, image_h=0; int ncolors, fill, color_index; int rotation, chars_per_pixel; int first_pixel_is_bg, first_pixel_maybe_bg, new_alloc; int id=0, rotate=ROTATE0, flip=NO_FLIP, locked=FALSE; int compressed=FALSE, real_x=0, real_y=0, real_type=0, linked_jpeg=FALSE; int transformed=FALSE, invisible=FALSE; struct XfrmMtrxRec *ctm=NULL; struct BBRec orig_obbox; struct ObjRec *new_obj_ptr=NULL; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_s, sizeof(color_s)); if (fileVersion >= 37) { s = ParseStr(s, (int)',', trans_color_s, sizeof(trans_color_s)); } InitScan(s, "\t\n, "); rotation = 0; chars_per_pixel = 1; first_pixel_maybe_bg = TRUE; first_pixel_is_bg = TRUE; if (fileVersion < 37) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_INVALID_FILEVER_FOR_LINK_JPEG), fileVersion); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return; } else { if (GETINT("jpeg", ltx, "ltx") == INVALID || GETINT("jpeg", lty, "lty") == INVALID || GETINT("jpeg", rbx, "rbx") == INVALID || GETINT("jpeg", rby, "rby") == INVALID || GETINT("jpeg", fill, "fill") == INVALID || GETINT("jpeg", ncolors, "ncolors") == INVALID || GETINT("jpeg", chars_per_pixel, "chars_per_pixel") == INVALID || GETINT("jpeg", first_pixel_is_bg,"first_pixel_is_bg") == INVALID || GETINT("jpeg", id, "id") == INVALID || GETINT("jpeg", rotation, "rotation") == INVALID || GETINT("jpeg", image_w, "image_w") == INVALID || GETINT("jpeg", image_h, "image_h") == INVALID || GETINT("jpeg", rotate, "rotate") == INVALID || GETINT("jpeg", flip, "flip") == INVALID || GETINT("jpeg", locked, "locked") == INVALID || GETINT("jpeg", compressed, "compressed") == INVALID || GETINT("jpeg", transformed, "transformed") == INVALID || GETINT("jpeg", invisible, "invisible") == INVALID || GETINT("jpeg", real_type, "real_type") == INVALID || GETINT("jpeg", linked_jpeg, "linked_jpeg") == INVALID) { return; } if (id >= objId) objId = id+1; first_pixel_maybe_bg = FALSE; } if (real_type == XPM_JPEG && linked_jpeg) { char *tmp_str=NULL; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; tmp_str = FindChar((int)'"', inbuf); s = ReadString(tmp_str); *(--s) = '\0'; jpeg_filename = UtilStrDup(tmp_str); if (jpeg_filename == NULL) FailAllocMessage(); } else { strcpy(gszMsgBox, TgLoadString(STID_INVALID_PARAM_LINKED_JPEG)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return; } if (transformed) { (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, "); ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ctm == NULL) FailAllocMessage(); if (GETINT("xpixmap", real_x, "real_x") == INVALID || GETINT("xpixmap", real_y, "real_y") == INVALID || GETINT("xpixmap", orig_obbox.ltx, "orig_obbox.ltx") == INVALID || GETINT("xpixmap", orig_obbox.lty, "orig_obbox.lty") == INVALID || GETINT("xpixmap", orig_obbox.rbx, "orig_obbox.rbx") == INVALID || GETINT("xpixmap", orig_obbox.rby, "orig_obbox.rby") == INVALID || GETDBL("xpixmap", ctm->m[CTM_SX], "CTM_SX") == INVALID || GETDBL("xpixmap", ctm->m[CTM_SIN], "CTM_SIN") == INVALID || GETDBL("xpixmap", ctm->m[CTM_MSIN], "CTM_MSIN") == INVALID || GETDBL("xpixmap", ctm->m[CTM_SY], "CTM_SY") == INVALID || GETINT("xpixmap", ctm->t[CTM_TX], "CTM_TX") == INVALID || GETINT("xpixmap", ctm->t[CTM_TY], "CTM_TY") == INVALID) { return; } } fill = UpgradePenFill(fill); if (!UtilPathExists(jpeg_filename)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PATH_WHILE_READ_JPEG), jpeg_filename); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } if (ctm != NULL) free(ctm); UtilFree(jpeg_filename); return; } if (PRTGIF && !cmdLineOpenDisplay) { new_obj_ptr = MyReadJpegFileSkipData(jpeg_filename, image_w, image_h); } else { new_obj_ptr = MyReadJpegFile(jpeg_filename, image_w, image_h); } if (new_obj_ptr == NULL) return; new_obj_ptr->id = id; MoveObj(new_obj_ptr, ltx, lty); if (ctm != NULL) { new_obj_ptr->obbox.ltx = new_obj_ptr->bbox.ltx = new_obj_ptr->x = ltx; new_obj_ptr->obbox.lty = new_obj_ptr->bbox.lty = new_obj_ptr->y = lty; new_obj_ptr->obbox.rbx = new_obj_ptr->bbox.rbx = rbx; new_obj_ptr->obbox.rby = new_obj_ptr->bbox.rby = rby; new_obj_ptr->ctm = ctm; memcpy(&new_obj_ptr->orig_obbox, &orig_obbox, sizeof(struct BBRec)); new_obj_ptr->x = real_x; new_obj_ptr->y = real_y; GetTransformedOBBoxOffsetVs(new_obj_ptr, new_obj_ptr->rotated_obbox); } xpm_ptr = new_obj_ptr->detail.xpm; xpm_ptr->real_type = real_type; xpm_ptr->linked_jpeg = linked_jpeg; xpm_ptr->filename = jpeg_filename; color_index = QuickFindColorIndex(new_obj_ptr, color_s, &new_alloc, TRUE); new_obj_ptr->color = color_index; UtilStrCpyN(new_obj_ptr->color_str, sizeof(new_obj_ptr->color_str), color_s); *ObjPtr = new_obj_ptr; } static struct ObjRec *MyReadPpmTrueFileSkipData(ppm_fname, expected_image_w, expected_image_h) char *ppm_fname; int expected_image_w, expected_image_h; { FILE *ppm_fp=NULL; int format=0, image_w=0, image_h=0, max_val=0; struct ObjRec *obj_ptr=NULL; struct XPmRec *xpm_ptr=NULL; ppm_fp = fopen(ppm_fname, "r"); if (ppm_fp == NULL) { FailToOpenMessage(ppm_fname, "r", NULL); return NULL; } if (!ReadPpmHeader(ppm_fp, ppm_fname, &format, &image_w, &image_h, &max_val)) { fclose(ppm_fp); return NULL; } fclose(ppm_fp); if (expected_image_w != (-1) && expected_image_h != (-1) && (image_w != expected_image_w || image_h != expected_image_h)) { sprintf(gszMsgBox, TgLoadString(STID_PPM6_DIM_NOT_MATCH), image_w, image_h, ppm_fname, expected_image_w, expected_image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } obj_ptr = CreateXPmObj(image_w, image_h, image_w, image_h, None, NULL, None, NULL, (-1), 1, FALSE, NULL, NULL, NULL, NULL); if (obj_ptr == NULL) return NULL; xpm_ptr = obj_ptr->detail.xpm; UtilStrCpyN(xpm_ptr->tmp_ppm6_fname, sizeof(xpm_ptr->tmp_ppm6_fname), ppm_fname); xpm_ptr->real_type = PPM_TRUE; return obj_ptr; } static struct ObjRec *MyReadPpmFile(ppm_fname, expected_image_w, expected_image_h) char *ppm_fname; int expected_image_w, expected_image_h; { char tmp_fname[MAXPATHLENGTH+1]; int rc=0, ncolors=0, chars_per_pixel=0, *pixels=NULL; int first_pixel_is_bg=FALSE, image_w=0, image_h=0, w=0, h=0; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; char *color_char, **color_str=NULL, *xpm_data=NULL; struct ObjRec *obj_ptr=NULL; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); rc = ConvertPpmToXpm(ppm_fname, tmp_fname, sizeof(tmp_fname)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (!rc) { return NULL; } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(tmp_fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if (rc != BitmapSuccess) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } if (expected_image_w != (-1) && expected_image_h != (-1) && (image_w != expected_image_w || image_h != expected_image_h)) { sprintf(gszMsgBox, TgLoadString(STID_PPM6_DIM_NOT_MATCH), image_w, image_h, ppm_fname, expected_image_w, expected_image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); unlink(tmp_fname); return obj_ptr; } int SetupTrueColorInfo(ptci) TrueColorInfo *ptci; { unsigned int r_mask=0, g_mask=0, b_mask=0; unsigned int r_maxval=0, g_maxval=0, b_maxval=0; unsigned int r_bits=0, g_bits=0, b_bits=0; int r_shift=(-1), g_shift=(-1), b_shift=(-1); unsigned int shifts=0; ptci->r_mask = r_mask = mainVisual->red_mask; ptci->g_mask = g_mask = mainVisual->green_mask; ptci->b_mask = b_mask = mainVisual->blue_mask; for (shifts=0; r_mask|g_mask|b_mask; shifts++) { if (r_mask & 0x1) { if (r_shift == (-1)) { r_shift = shifts; r_maxval = r_mask; } r_bits++; } if (g_mask & 0x1) { if (g_shift == (-1)) { g_shift = shifts; g_maxval = g_mask; } g_bits++; } if (b_mask & 0x1) { if (b_shift == (-1)) { b_shift = shifts; b_maxval = b_mask; } b_bits++; } r_mask >>= 1; g_mask >>= 1; b_mask >>= 1; } ptci->r_shift = (unsigned int)r_shift; ptci->g_shift = (unsigned int)g_shift; ptci->b_shift = (unsigned int)b_shift; ptci->dr_maxval = (double)r_maxval; ptci->dg_maxval = (double)g_maxval; ptci->db_maxval = (double)b_maxval; ptci->dr_maxval_div255 = ptci->dr_maxval / ((double)255); ptci->dg_maxval_div255 = ptci->dg_maxval / ((double)255); ptci->db_maxval_div255 = ptci->db_maxval / ((double)255); ptci->num_r_bits = r_bits; ptci->num_g_bits = g_bits; ptci->num_b_bits = b_bits; if (r_shift==(-1) || g_shift==(-1) || b_shift==(-1)) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "unexpected error in SetupTrueColorInfo()", NULL); #endif /* _TGIF_DBG */ return FALSE; } return TRUE; } static struct ObjRec *MyReadPpmTrueFile2(ppm_fname, expected_image_w, expected_image_h) char *ppm_fname; int expected_image_w, expected_image_h; { FILE *ppm_fp=NULL; int row=0, format=0, image_w=0, image_h=0, max_val=0; struct ObjRec *obj_ptr=NULL; struct XPmRec *xpm_ptr=NULL; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; TrueColorInfo tci; double dmaxval=(double)0; int can_have_trans_pixel=FALSE, has_trans_pixel=FALSE; unsigned int trans_pixel_r=0, trans_pixel_g=0, trans_pixel_b=0; memset(&tci, 0, sizeof(TrueColorInfo)); if (!SetupTrueColorInfo(&tci)) return NULL; ppm_fp = fopen(ppm_fname, "r"); if (ppm_fp == NULL) { FailToOpenMessage(ppm_fname, "r", NULL); return NULL; } if (!ReadPpmHeader(ppm_fp, ppm_fname, &format, &image_w, &image_h, &max_val)) { fclose(ppm_fp); return NULL; } if (max_val != 255 && max_val != 65535) { sprintf(gszMsgBox, TgLoadString(STID_UNSUP_PPM6_MAX_VAL), max_val, ppm_fname); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } fclose(ppm_fp); return NULL; } if (expected_image_w != (-1) && expected_image_h != (-1) && (image_w != expected_image_w || image_h != expected_image_h)) { sprintf(gszMsgBox, TgLoadString(STID_PPM6_DIM_NOT_MATCH), image_w, image_h, ppm_fname, expected_image_w, expected_image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); fclose(ppm_fp); return NULL; } dmaxval = (double)255; pixmap = XCreatePixmap(mainDisplay, mainWindow, image_w, image_h, mainDepth); bitmap = XCreatePixmap(mainDisplay, dummyBitmap, image_w, image_h, 1); if (pixmap == None || bitmap == None) { if (pixmap != None) XFreePixmap(mainDisplay, pixmap); if (bitmap != None) XFreePixmap(mainDisplay, bitmap); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); fclose(ppm_fp); return NULL; } XFillRectangle(mainDisplay, pixmap, xpmGC, 0, 0, image_w, image_h); XSetForeground(mainDisplay, xbmGC, 1); XFillRectangle(mainDisplay, bitmap, xbmGC, 0, 0, image_w, image_h); XSetForeground(mainDisplay, xbmGC, 0); bitmap_image = XGetImage(mainDisplay, bitmap, 0, 0, image_w, image_h, 1, ZPixmap); image = XGetImage(mainDisplay, pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (image == NULL || bitmap_image == NULL) { XFreePixmap(mainDisplay, pixmap); XFreePixmap(mainDisplay, bitmap); if (image != NULL) XDestroyImage(image); if (bitmap_image != NULL) XDestroyImage(bitmap_image); MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); return NULL; } if (gPngHeaderInfo.valid && gPngHeaderInfo.trans_color_pixel_found) { can_have_trans_pixel = TRUE; trans_pixel_r = (unsigned int)gPngHeaderInfo.trans_color_pixel_red; trans_pixel_g = (unsigned int)gPngHeaderInfo.trans_color_pixel_green; trans_pixel_b = (unsigned int)gPngHeaderInfo.trans_color_pixel_blue; if (max_val == 65535) { trans_pixel_r = trans_pixel_r | ((trans_pixel_r<<8)&0x0ff00); trans_pixel_g = trans_pixel_g | ((trans_pixel_g<<8)&0x0ff00); trans_pixel_b = trans_pixel_b | ((trans_pixel_b<<8)&0x0ff00); } } for (row=0; row < image_h; row++) { int col=0; for (col=0; col < image_w; col++) { unsigned char buf[3]; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; int bytes_read=0; uint32_t pixel=0; if (format == TYPE_PPM6) { if (max_val == 65535) { unsigned char r_buf[2], g_buf[2], b_buf[2]; if (fread(r_buf, sizeof(char), 2, ppm_fp) != 2 || fread(g_buf, sizeof(char), 2, ppm_fp) != 2 || fread(b_buf, sizeof(char), 2, ppm_fp) != 2) { XFreePixmap(mainDisplay, pixmap); XFreePixmap(mainDisplay, bitmap); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); fclose(ppm_fp); return NULL; } if (littleEndianPpm6) { buf[0] = r_buf[1]; buf[1] = g_buf[1]; buf[2] = b_buf[1]; } else { buf[0] = r_buf[0]; buf[1] = g_buf[0]; buf[2] = b_buf[0]; } } else { if ((bytes_read=fread(buf, sizeof(char), 3, ppm_fp)) != 3) { XFreePixmap(mainDisplay, pixmap); XFreePixmap(mainDisplay, bitmap); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); fclose(ppm_fp); return NULL; } } } else if (format == TYPE_PPM5) { if (max_val == 65535) { unsigned char g_buf[2]; if (fread(g_buf, sizeof(char), 2, ppm_fp) != 2) { XFreePixmap(mainDisplay, pixmap); XFreePixmap(mainDisplay, bitmap); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); fclose(ppm_fp); return NULL; } if (littleEndianPpm6) { buf[0] = buf[1] = buf[2] = g_buf[1]; } else { buf[0] = buf[1] = buf[2] = g_buf[0]; } } else { if ((bytes_read=fread(buf, sizeof(char), 1, ppm_fp)) != 1) { XFreePixmap(mainDisplay, pixmap); XFreePixmap(mainDisplay, bitmap); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); fclose(ppm_fp); return NULL; } buf[1] = buf[2] = buf[0]; } } else { int red=0, green=0, blue=0; if (fscanf(ppm_fp, "%d %d %d", &red, &green, &blue) != 3) { XFreePixmap(mainDisplay, pixmap); XFreePixmap(mainDisplay, bitmap); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); fclose(ppm_fp); return NULL; } buf[0] = (unsigned char)(red & 0x0ff); buf[1] = (unsigned char)(green & 0x0ff); buf[2] = (unsigned char)(blue & 0x0ff); } r = (unsigned int)buf[0]; g = (unsigned int)buf[1]; b = (unsigned int)buf[2]; dr = ((double)r) / dmaxval * tci.dr_maxval; dg = ((double)g) / dmaxval * tci.dg_maxval; db = ((double)b) / dmaxval * tci.db_maxval; r = round(dr); g = round(dg); b = round(db); pixel = ((r << tci.r_shift) & mainVisual->red_mask) | ((g << tci.g_shift) & mainVisual->green_mask) | ((b << tci.b_shift) & mainVisual->blue_mask) ; XPutPixel(image, col, row, pixel); if (can_have_trans_pixel && trans_pixel_r == r && trans_pixel_g == g && trans_pixel_b == b) { XPutPixel(bitmap_image, col, row, 0); has_trans_pixel = TRUE; } } } fclose(ppm_fp); XPutImage(mainDisplay, pixmap, xpmGC, image, 0, 0, 0, 0, image_w, image_h); if (has_trans_pixel) { XPutImage(mainDisplay, bitmap, xbmGC, bitmap_image, 0, 0, 0, 0, image_w, image_h); } else { /* * It seems to be a waste not to do the following. But it's done * this way so that other code (such as in "dup.c") do not * have to be changed. * * XDestroyImage(bitmap_image); * XFreePixmap(mainDisplay, bitmap); * bitmap_image = NULL; * bitmap = None; */ } obj_ptr = CreateXPmObj(image_w, image_h, image_w, image_h, pixmap, image, bitmap, bitmap_image, 0, 0, FALSE, NULL, NULL, NULL, NULL); xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; if (obj_ptr == NULL) return NULL; return obj_ptr; } static struct ObjRec *MyReadPpmTrueFile(ppm_fname, expected_image_w, expected_image_h) char *ppm_fname; int expected_image_w, expected_image_h; { struct ObjRec *obj_ptr=NULL; struct XPmRec *xpm_ptr=NULL; if (PRTGIF && !cmdLineOpenDisplay) { obj_ptr = MyReadPpmTrueFileSkipData(ppm_fname, expected_image_w, expected_image_h); } else { if (fullTrueColorMode && HasZlibSupport()) { obj_ptr = MyReadPpmTrueFile2(ppm_fname, expected_image_w, expected_image_h); if (obj_ptr != NULL) { MoveObj(obj_ptr, -drawOrigX, -drawOrigY); return obj_ptr; } else { return NULL; } } obj_ptr = MyReadPpmFile(ppm_fname, expected_image_w, expected_image_h); if (obj_ptr == NULL) { return NULL; } xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = XPM_XPM; } MoveObj(obj_ptr, -drawOrigX, -drawOrigY); return obj_ptr; } struct ObjRec *CreatePpmTrueObjFromFile(ppm_fname) char *ppm_fname; { return MyReadPpmTrueFile(ppm_fname, (-1), (-1)); } void ReadPpmTrueObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { struct XPmRec *xpm_ptr=NULL; char *s=NULL, inbuf[MAXSTRING], *ppm_data=NULL, *ppm_mask_data=NULL; char color_s[40], trans_color_s[40], tmp_fname[MAXPATHLENGTH]; int ltx=0, lty=0, rbx=0, rby=0, image_w=0, image_h=0, color_index=(-1); int rotation=0, new_alloc=FALSE, id=0, rotate=ROTATE0, flip=NO_FLIP; int locked=FALSE, has_transp_color=FALSE, real_x=0, real_y=0; int transformed=FALSE, invisible=FALSE; int ppm_data_compress=FALSE, ppm_data_size=0, ppm_mask_size=0; struct XfrmMtrxRec *ctm=NULL; struct BBRec orig_obbox; struct ObjRec *new_obj_ptr=NULL; unsigned char trans_color_pixel_r='\0', trans_color_pixel_g='\0', trans_color_pixel_b='\0'; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_s, sizeof(color_s)); s = ParseStr(s, (int)',', trans_color_s, sizeof(trans_color_s)); InitScan(s, "\t\n, "); rotation = 0; if (fileVersion < 37) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_INVALID_FILEVER_FOR_LINK_JPEG), fileVersion); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return; } else { if (GETINT("ppm_true", has_transp_color, "has_transparent_color") == INVALID || GETINT("ppm_true", ltx, "ltx") == INVALID || GETINT("ppm_true", lty, "lty") == INVALID || GETINT("ppm_true", rbx, "rbx") == INVALID || GETINT("ppm_true", rby, "rby") == INVALID || GETINT("ppm_true", id, "id") == INVALID || GETINT("ppm_true", rotation, "rotation") == INVALID || GETINT("ppm_true", image_w, "image_w") == INVALID || GETINT("ppm_true", image_h, "image_h") == INVALID || GETINT("ppm_true", rotate, "rotate") == INVALID || GETINT("ppm_true", flip, "flip") == INVALID || GETINT("ppm_true", locked, "locked") == INVALID || GETINT("ppm_true", transformed, "transformed") == INVALID || GETINT("ppm_true", invisible, "invisible") == INVALID || GETINT("ppm_true", ppm_data_compress,"ppm_data_compress") == INVALID || GETINT("ppm_true", ppm_data_size, "ppm_data_size") == INVALID || GETINT("ppm_true", ppm_mask_size, "ppm_mask_size") == INVALID) { return; } if (id >= objId) objId = id+1; } if (ppm_data_compress == PPM_JPEG_COMPRESS) { /* this is fine */ } else if (ppm_data_compress == PPM_DATA_DEFLATED) { if (!HasZlibSupport()) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_INFLATE_GIVEN_OBJ), "ppm_true", TOOL_NAME); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return; } } else { /* including PPM_DATA_RAW -- not supported, must be an error */ sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_PARAM_GIVEN_OBJ), "ppm_data_compress", "ppm_true"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return; } if (transformed) { (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, "); ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ctm == NULL) FailAllocMessage(); if (GETINT("xpixmap", real_x, "real_x") == INVALID || GETINT("xpixmap", real_y, "real_y") == INVALID || GETINT("xpixmap", orig_obbox.ltx, "orig_obbox.ltx") == INVALID || GETINT("xpixmap", orig_obbox.lty, "orig_obbox.lty") == INVALID || GETINT("xpixmap", orig_obbox.rbx, "orig_obbox.rbx") == INVALID || GETINT("xpixmap", orig_obbox.rby, "orig_obbox.rby") == INVALID || GETDBL("xpixmap", ctm->m[CTM_SX], "CTM_SX") == INVALID || GETDBL("xpixmap", ctm->m[CTM_SIN], "CTM_SIN") == INVALID || GETDBL("xpixmap", ctm->m[CTM_MSIN], "CTM_MSIN") == INVALID || GETDBL("xpixmap", ctm->m[CTM_SY], "CTM_SY") == INVALID || GETINT("xpixmap", ctm->t[CTM_TX], "CTM_TX") == INVALID || GETINT("xpixmap", ctm->t[CTM_TY], "CTM_TY") == INVALID) { return; } } ppm_data = ReadPpmTrueData(FP, ppm_data_size); ppm_mask_data = ReadPpmTrueMask(FP, ppm_mask_size); if (ppm_data == NULL) return; *tmp_fname = '\0'; if (IsPpmTrueObj(PPM_TRUE, ppm_data_compress, ppm_data)) { if (!ConvertPpmTrueToPpm6(ppm_data, ppm_data_size, ppm_data_compress, tmp_fname, sizeof(tmp_fname))) { UtilFree(ppm_data); return; } } else { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "unsupported format in ReadPpmTrueObj()", NULL); #endif /* _TGIF_DBG */ } if (has_transp_color) { if (!ParseTransColor(trans_color_s, &trans_color_pixel_r, &trans_color_pixel_g, &trans_color_pixel_b)) { strcpy(gszMsgBox, TgLoadString(STID_BAD_TRANS_COLOR_NO_TRANS)); if (PRTGIF && !cmdLineOpenDisplay) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } has_transp_color = FALSE; } } ResetPngHeaderInfo(&gPngHeaderInfo); if (has_transp_color) { SetPngHeaderInfoForTransColor(&gPngHeaderInfo, trans_color_pixel_r, trans_color_pixel_g, trans_color_pixel_b); } new_obj_ptr = MyReadPpmTrueFile(tmp_fname, image_w, image_h); ResetPngHeaderInfo(&gPngHeaderInfo); if (new_obj_ptr == NULL) { unlink(tmp_fname); UtilFree(ppm_data); return; } unlink(tmp_fname); /* must set real_type set in MyReadPpmTrueFile() */ color_index = QuickFindColorIndex(new_obj_ptr, color_s, &new_alloc, TRUE); new_obj_ptr->color = color_index; UtilStrCpyN(new_obj_ptr->color_str, sizeof(new_obj_ptr->color_str), color_s); new_obj_ptr->id = id; MoveObj(new_obj_ptr, ltx, lty); if (ctm != NULL) { new_obj_ptr->obbox.ltx = new_obj_ptr->bbox.ltx = new_obj_ptr->x = ltx; new_obj_ptr->obbox.lty = new_obj_ptr->bbox.lty = new_obj_ptr->y = lty; new_obj_ptr->obbox.rbx = new_obj_ptr->bbox.rbx = rbx; new_obj_ptr->obbox.rby = new_obj_ptr->bbox.rby = rby; new_obj_ptr->ctm = ctm; memcpy(&new_obj_ptr->orig_obbox, &orig_obbox, sizeof(struct BBRec)); new_obj_ptr->x = real_x; new_obj_ptr->y = real_y; GetTransformedOBBoxOffsetVs(new_obj_ptr, new_obj_ptr->rotated_obbox); } xpm_ptr = new_obj_ptr->detail.xpm; if (xpm_ptr->real_type == PPM_TRUE) { xpm_ptr->ppm_data_compress = ppm_data_compress; xpm_ptr->ppm_data = ppm_data; xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; xpm_ptr->ppm_data_size = ppm_data_size; xpm_ptr->has_transparent_color = has_transp_color; if (xpm_ptr->has_transparent_color) { xpm_ptr->transparent_color[0] = trans_color_pixel_r; xpm_ptr->transparent_color[1] = trans_color_pixel_g; xpm_ptr->transparent_color[2] = trans_color_pixel_b; } } else { /* something didn't work, revert back to a regular XPM object */ if (!PRTGIF || cmdLineOpenDisplay) { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_PPM_TRUE_LOSSY_CONV_TO_XPM)); Msg(gszMsgBox); SetFileModified(TRUE); } UtilFree(ppm_data); } *ObjPtr = new_obj_ptr; } void SetXPmPropMask(ObjPtr, plMask, plSkip, pProp) struct ObjRec *ObjPtr; long *plMask, *plSkip; struct PropertiesRec *pProp; { SetCTMPropertyMask(ObjPtr->ctm, plMask, plSkip, pProp); } void FreeXPmObj(ObjPtr) struct ObjRec *ObjPtr; { register int i, ncolors; struct XPmRec *xpm_ptr=ObjPtr->detail.xpm; if (xpm_ptr->pixmap != None) { if (xpm_ptr->pixels != NULL) free(xpm_ptr->pixels); if (xpm_ptr->red != NULL) free(xpm_ptr->red); if (xpm_ptr->green != NULL) free(xpm_ptr->green); if (xpm_ptr->blue != NULL) free(xpm_ptr->blue); if (xpm_ptr->color_char != NULL) free(xpm_ptr->color_char); if (xpm_ptr->color_str != NULL) { ncolors = xpm_ptr->ncolors; for (i = 0; i < ncolors; i++) free(xpm_ptr->color_str[i]); free(xpm_ptr->color_str); } XFreePixmap(mainDisplay, xpm_ptr->pixmap); } if (xpm_ptr->bitmap != None) XFreePixmap(mainDisplay, xpm_ptr->bitmap); if (xpm_ptr->image != NULL) XDestroyImage(xpm_ptr->image); if (xpm_ptr->bitmap_image != NULL) XDestroyImage(xpm_ptr->bitmap_image); if (xpm_ptr->cached_pixmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_pixmap); } if (xpm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_bitmap); } if (xpm_ptr->clip_mask != None) { XFreePixmap(mainDisplay, xpm_ptr->clip_mask); } if (xpm_ptr->data != NULL) free(xpm_ptr->data); if (xpm_ptr->filename != NULL) free(xpm_ptr->filename); if (xpm_ptr->ppm_data != NULL) free(xpm_ptr->ppm_data); if (xpm_ptr->ppm_mask_data != NULL) free(xpm_ptr->ppm_mask_data); free(xpm_ptr); free(ObjPtr); } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/const.h������������������������������������������������������������������������������0000644�0000764�0000764�00000060024�11602233311�014264� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/const.h,v 1.24 2011/05/16 16:21:57 william Exp $ */ #ifndef _TGIF_CONST_H_ #define _TGIF_CONST_H_ #if __STDC__ || defined(__cplusplus) || defined(c_plusplus) /* ANSI || C++ */ #ifdef _NO_PROTO /* just in case ANSI or C++ doesn't handle function prototypes well */ #define ARGS_DECL(args) () #undef ARGS_DECL_USED #else /* ~_NO_PROTO */ #define ARGS_DECL(args) args #undef ARGS_DECL_USED #define ARGS_DECL_USED 1 #endif /* _NO_PROTO */ #else /* ~(__STDC__ || defined(__cplusplus) || defined(c_plusplus)) */ #define ARGS_DECL(args) () #undef ARGS_DECL_USED #endif /* __STDC__ || defined(__cplusplus) || defined(c_plusplus) */ #include "tgif_dbg.h" #ifndef _NO_LOCALE_SUPPORT #ifdef ENABLE_NLS #define _(text) gettext(text) #define N_(text) text #else /* ~ENABLE_NLS */ #define _(text) text #define N_(text) text #endif /* ENABLE_NLS */ #else /* _NO_LOCALE_SUPPORT */ #define _(text) text #define N_(text) text #endif /* ~_NO_LOCALE_SUPPORT */ #define TOOL_NAME "Tgif" #ifndef NULL #define NULL 0 #endif /* ~NULL */ #ifndef TRUE #define FALSE 0 #define TRUE 1 #endif /* ~TRUE */ #define INVALID (-1) #undef BAD #define BAD (-2) #ifdef WIN32 #define DIR_SEP '\\' #define DIR_SEP_STR "\\" #else /* ~WIN32 */ #define DIR_SEP '/' #define DIR_SEP_STR "/" #endif /* WIN32 */ #define SINGLECOLOR (FALSE) #define MULTICOLOR (TRUE) #define BUTTONSMASK ((Button1Mask)|(Button2Mask)|(Button3Mask)) #ifndef max #define max(A,B) (((A)>(B)) ? (A) : (B)) #define min(A,B) (((A)>(B)) ? (B) : (A)) #endif /* ~max */ #ifndef round #define round(X) (((X) >= 0) ? (int)((X)+0.5) : (int)((X)-0.5)) #endif /* ~round */ #ifndef M_PI #define M_PI 3.14159265358979323846 #endif /* ~M_PI */ #define INT_TOL (1.0e-5) #define EQ_TOL (1.0e-8) #ifndef XK_KP_Left #define XK_KP_Left 0xFF96 #define XK_KP_Up 0xFF97 #define XK_KP_Right 0xFF98 #define XK_KP_Down 0xFF99 #endif /* ~XK_KP_LEFT */ #ifndef XK_KP_Delete #define XK_KP_Insert 0xFF9E #define XK_KP_Delete 0xFF9F #endif /* ~XK_KP_Delete */ #ifndef XK_Page_Up #define XK_Page_Up 0xFF55 #define XK_Page_Down 0xFF56 #endif /* ~XK_Page_Up */ #ifndef XK_KP_Page_Up #define XK_KP_Page_Up 0xFF9A #define XK_KP_Page_Down 0xFF9B #endif /* ~XK_KP_Page_Up */ #ifndef XK_KP_Home #define XK_KP_Home 0xFF95 #define XK_KP_End 0xFF9C #endif /* ~XK_KP_Home */ #ifndef XK_Home #define XK_Home 0xFF50 #define XK_End 0xFF57 #endif /* ~XK_Home */ #define MAX_ZOOMED_IN 3 #define HALF_W(w) (((w)&0x1) ? ((w)>>1)+1 : ((w)>>1)) #define ZOOMED_HALF_W(w) ((zoomedIn) ? ((w)<<(zoomScale-1)) : \ ((((w)>>(zoomScale))&0x1) ? (((w)>>(zoomScale+1))+1) : \ ((w)>>(zoomScale+1)))) #define OFFSET_X(AbsX) ((zoomedIn) ? (((AbsX)-drawOrigX)<<zoomScale) : \ (((AbsX)-drawOrigX)>>zoomScale)) #define OFFSET_Y(AbsY) ((zoomedIn) ? (((AbsY)-drawOrigY)<<zoomScale) : \ (((AbsY)-drawOrigY)>>zoomScale)) #define OFFSET_DOUBLE_X(AbsX) \ ((zoomedIn) ? \ (((AbsX)-((double)drawOrigX))*((double)(1<<zoomScale))) : \ (((AbsX)-((double)drawOrigX))/((double)(1<<zoomScale)))) #define OFFSET_DOUBLE_Y(AbsY) \ ((zoomedIn) ? \ (((AbsY)-((double)drawOrigY))*((double)(1<<zoomScale))) : \ (((AbsY)-((double)drawOrigY))/((double)(1<<zoomScale)))) #define ABS_X(OffsetX) ((zoomedIn) ? (((OffsetX)>>zoomScale)+drawOrigX) : \ (((OffsetX)<<zoomScale)+drawOrigX)) #define ABS_Y(OffsetY) ((zoomedIn) ? (((OffsetY)>>zoomScale)+drawOrigY) : \ (((OffsetY)<<zoomScale)+drawOrigY)) #define ZOOMED_SIZE(AbsSize) ((zoomedIn) ? ((AbsSize)<<zoomScale) : \ ((AbsSize)>>zoomScale)) #define ZOOMED_DOUBLE_SIZE(AbsSize) ((zoomedIn) ? \ ((AbsSize)*((double)(1<<zoomScale))) : \ ((AbsSize)/((double)(1<<zoomScale)))) #define GRID_ZOOMED_SIZE(AbsSize) ((zoomedIn) ? (AbsSize) : \ ((AbsSize)>>zoomScale)) #define ABS_SIZE(ZoomedSize) ((zoomedIn) ? ((ZoomedSize)>>zoomScale) : \ ((ZoomedSize)<<zoomScale)) #define GRID_ABS_SIZE(ZoomedSize) ((zoomedIn) ? (ZoomedSize) : \ ((ZoomedSize)<<zoomScale)) #define SetRecVals(R,X,Y,W,H) ((R).x=(X),(R).y=(Y),(R).width=(W),(R).height=(H)) #define MARK(W,GC,X,Y) XFillRectangle(mainDisplay,W,GC, \ (X)-handleSize,(Y)-handleSize,(handleSize<<1)+1,(handleSize<<1)+1) #define MARKHR(W,GC,X,Y) XDrawRectangle(mainDisplay,W,GC, \ (X)-handleSize,(Y)-handleSize,(handleSize<<1),(handleSize<<1)) #define MARKV(W,GC,X,Y) XDrawLine(mainDisplay,W,GC, \ (X)-(handleSize+1),(Y),(X)+(handleSize+1),(Y)); \ XDrawLine(mainDisplay,W,GC,(X),(Y)-(handleSize+1),(X),(Y)+(handleSize+1)) #define MARKO(W,GC,X,Y) XFillArc(mainDisplay,W,GC, \ (X)-handleSize,(Y)-handleSize,(handleSize<<1)+1,(handleSize<<1)+1, \ 0,(360<<6)) #define MARKHO(W,GC,X,Y) XDrawArc(mainDisplay,W,GC, \ (X)-handleSize,(Y)-handleSize,(handleSize<<1),(handleSize<<1), \ 0,(360<<6)) #define PtInMark(PtX,PtY,MarkX,MarkY) ((PtX) >= (MarkX)-handleSize && \ (PtY) >= (MarkY)-handleSize && (PtX) <= (MarkX)+handleSize && \ (PtY) <= (MarkY)+handleSize) #define MyDashedLine(W,GC,V,N) XDrawLines(mainDisplay,W,GC,V,N,CoordModeOrigin) #define GETINT(category,val,name) ScanValue("%d", &(val), name, category) #define GETFLT(category,val,name) ScanValue("%f", &(val), name, category) #define GETDBL(category,val,name) ScanValue("%lg", &(val), name, category) #define GETSTR(category,val,name) ScanValue("%s", (val), name, category) #define GETDYN(category,val,name) ScanDynStrValue(&(val), name, category) #define GetPinObj(ObjPtr) ((ObjPtr)->detail.r->pin_connected ? \ (ObjPtr)->detail.r->last : (ObjPtr)->detail.r->first) #define GetTextObjFirstStrSeg(ObjPtr) \ ((ObjPtr)->detail.t->minilines.first->first_block->seg) #define GetTextPtrFirstStrSeg(TextPtr) \ ((TextPtr)->minilines.first->first_block->seg) #define MAXSTRING 256 #define MAXPATHLENGTH 256 #define COLORSTRLEN 40 /* geometry stuff */ #define MENU_IMAGE_W 64 #define MENU_IMAGE_H 20 #define CHOICE_IMAGE_W 32 #define CHOICE_IMAGE_H 20 #define SCROLLBAR_W 16 #define RULER_W 20 #define BRDR_W 1 #define WINDOW_PADDING 2 /* object types */ #define OBJ_POLY 0 #define OBJ_BOX 1 #define OBJ_OVAL 2 #define OBJ_TEXT 3 #define OBJ_POLYGON 4 #define OBJ_GROUP 5 #define OBJ_SYM 6 #define OBJ_ICON 7 #define OBJ_ARC 8 #define OBJ_RCBOX 9 #define OBJ_XBM 10 #define OBJ_XPM 11 #define OBJ_PIN 12 /* Please note that pins are not implemented yet! */ #define OBJ_SS 13 /* This is reserved */ /* drawing modes */ #define NOTHING 0 #define DRAWTEXT 1 #define DRAWBOX 2 #define DRAWCORNEROVAL 3 #define DRAWCENTEROVAL 4 #define DRAWEDGECIRCLE 5 #define DRAWPOLY 6 #define DRAWPOLYGON 7 #define DRAWARC 8 #define DRAWEDGEARC 9 #define DRAWRCBOX 10 #define FREEHAND 11 #define VERTEXMODE 12 #define ROTATEMODE 13 #define MAXCHOICES 14 /* stipple patterns */ #define NONEPAT 0 #define SOLIDPAT 1 #define BACKPAT 2 #define SCROLLPAT 7 #define MAXPATTERNS 32 #define NO_TRANSPAT_MODE 0 #define TRANSPAT_MODE 1 #define MAXTRANSPATMODES 2 /* line stuff */ #define LINE_THIN 0 #define LINE_MEDIUM 1 #define LINE_THICK 2 #define LINE_CURVED 3 /* compatibility hack for fileVersion <= 3 */ #define MAXLINEWIDTHS 7 #define LT_STRAIGHT 0 #define LT_SPLINE 1 #define LT_INTSPLINE 2 #define LT_STRUCT_SPLINE 3 #define MAXLINETYPES 4 #define LS_PLAIN 0 #define LS_RIGHT 1 #define LS_LEFT 2 #define LS_DOUBLE 3 #define MAXLINESTYLES 4 #define MAXDASHES 9 #define NOCONT (FALSE) #define CONT (TRUE) #define NORB (FALSE) #define RB (TRUE) #define CHANGE_WIDTH 0x1 #define CHANGE_AW 0x2 #define CHANGE_AH 0x4 #define CHANGE_LINE_ALL (CHANGE_WIDTH|CHANGE_AW|CHANGE_AH) #define LCAP_BUTT 0 #define LCAP_ROUND 1 #define LCAP_SQUARE 2 #define MAXLINECAPS 3 #define ASTY_MASK_COMPAT 0x0001 #define ASTY_MASK_FILL 0x0002 #define ASTY_MASK_HALVES 0x000c #define ASTY_MASK_SHAPES 0x0010 #define ASTY_COMPAT 0x0 /* ASTY_MASK_COMPAT */ #define ASTY_FLEX 0x1 /* ASTY_MASK_COMPAT */ #define ASTY_SOLIDPAT 0x0 /* ASTY_MASK_FILL */ #define ASTY_BACKPAT 0x2 /* ASTY_MASK_FILL */ #define ASTY_LF_HALF_ONLY 0x4 /* ASTY_MASK_HALVES */ #define ASTY_RT_HALF_ONLY 0x8 /* ASTY_MASK_HALVES */ #define ASTY_CIRCLE 1 /* not used */ #define ASTY_BOX 2 /* not used */ /* font stuff */ #define FONT_TIM 0 #define FONT_COU 1 #define FONT_HEL 2 #define FONT_CEN 3 #define FONT_SYM 4 #define MAXFONTS 5 #define STYLE_NR 0 #define STYLE_BR 1 #define STYLE_NI 2 #define STYLE_BI 3 #define MAXFONTSTYLES 4 #define FONT_DPI_75 0 #define FONT_DPI_100 1 #define MAXFONTDPIS 2 #define MAXFONTSIZES 6 #define JUST_L 0 #define JUST_C 1 #define JUST_R 2 #define MAXJUSTS 3 #define PUSH_FONT 0 #define PUSH_SZ_UNIT 1 #define PUSH_STYLE 2 #define PUSH_JUST 3 #define PUSH_ROTATE 4 #define PUSH_PEN 5 #define PUSH_FILL 6 #define PUSH_TRANSPAT 7 #define PUSH_VSPACE 8 #define PUSH_COLORINDEX 9 #define PUSH_UNDERLINE_ON 10 #define PUSH_UNDERLINE_Y_OFFSET 11 #define PUSH_DOUBLEBYTE 12 #define PUSH_OVERLINE_ON 13 #define PUSH_OVERLINE_Y_OFFSET 14 #define NUM_SZ_UNIT_PER_FONT_SIZE 5760 #define NUM_SZ_UNIT_PER_POINT_SIZE 10240 #define FontSizeToSzUnit(font_sz) ((font_sz)*NUM_SZ_UNIT_PER_FONT_SIZE) #define PointSizeToSzUnit(point_sz) ((point_sz)*NUM_SZ_UNIT_PER_POINT_SIZE) /* alignment */ #define ALIGN_N 0 #define ALIGN_L 1 #define ALIGN_C 2 #define ALIGN_R 3 #define ALIGN_T 1 #define ALIGN_M 2 #define ALIGN_B 3 #define ALIGN_S 4 #define MAXALIGNS 5 #define ALIGN_SHIFT (MAXALIGNS) #define ALIGN_NN ((ALIGN_N<<ALIGN_SHIFT)|ALIGN_N) #define ALIGN_NT ((ALIGN_N<<ALIGN_SHIFT)|ALIGN_T) #define ALIGN_NM ((ALIGN_N<<ALIGN_SHIFT)|ALIGN_M) #define ALIGN_NB ((ALIGN_N<<ALIGN_SHIFT)|ALIGN_B) #define ALIGN_NS ((ALIGN_N<<ALIGN_SHIFT)|ALIGN_S) #define ALIGN_LN ((ALIGN_L<<ALIGN_SHIFT)|ALIGN_N) #define ALIGN_LT ((ALIGN_L<<ALIGN_SHIFT)|ALIGN_T) #define ALIGN_LM ((ALIGN_L<<ALIGN_SHIFT)|ALIGN_M) #define ALIGN_LB ((ALIGN_L<<ALIGN_SHIFT)|ALIGN_B) #define ALIGN_LS ((ALIGN_L<<ALIGN_SHIFT)|ALIGN_S) #define ALIGN_CN ((ALIGN_C<<ALIGN_SHIFT)|ALIGN_N) #define ALIGN_CT ((ALIGN_C<<ALIGN_SHIFT)|ALIGN_T) #define ALIGN_CM ((ALIGN_C<<ALIGN_SHIFT)|ALIGN_M) #define ALIGN_CB ((ALIGN_C<<ALIGN_SHIFT)|ALIGN_B) #define ALIGN_CS ((ALIGN_C<<ALIGN_SHIFT)|ALIGN_S) #define ALIGN_RN ((ALIGN_R<<ALIGN_SHIFT)|ALIGN_N) #define ALIGN_RT ((ALIGN_R<<ALIGN_SHIFT)|ALIGN_T) #define ALIGN_RM ((ALIGN_R<<ALIGN_SHIFT)|ALIGN_M) #define ALIGN_RB ((ALIGN_R<<ALIGN_SHIFT)|ALIGN_B) #define ALIGN_RS ((ALIGN_R<<ALIGN_SHIFT)|ALIGN_S) #define ALIGN_SN ((ALIGN_S<<ALIGN_SHIFT)|ALIGN_N) #define ALIGN_ST ((ALIGN_S<<ALIGN_SHIFT)|ALIGN_T) #define ALIGN_SM ((ALIGN_S<<ALIGN_SHIFT)|ALIGN_M) #define ALIGN_SB ((ALIGN_S<<ALIGN_SHIFT)|ALIGN_B) #define ALIGN_SS ((ALIGN_S<<ALIGN_SHIFT)|ALIGN_S) #define ALIGN_OBJS_DIRECT 0 #define ALIGN_TO_GRID_DIRECT 1 #define ALIGN_TO_PAGE_DIRECT 2 /* color */ #define MAXCOLORS 11 /* button stuff */ #define BUTTON_INVERT 0 #define BUTTON_NORMAL 1 /* page style */ #define PORTRAIT 0 #define LANDSCAPE 1 #define HIGHPORT 2 /* obsolete */ #define HIGHLAND 3 /* obsolete */ #define SLIDEPORT 4 /* obsolete */ #define SLIDELAND 5 /* obsolete */ #define MAXPAGESTYLES 2 /* where to print */ #define PRINTER 0 #define LATEX_FIG 1 #define PS_FILE 2 #define XBM_FILE 3 #define TEXT_FILE 4 #define EPSI_FILE 5 #define GIF_FILE 6 #define HTML_FILE 7 #define PDF_FILE 8 #define TIFFEPSI_FILE 9 #define PNG_FILE 10 #define JPEG_FILE 11 #define PPM_FILE 12 #define NETLIST_FILE 13 #define SVG_FILE 14 #define MAXDEFWHERETOPRINT 15 /* measurement */ #define TIK_PER_PIXEL_SHIFTS 12 #define TIK_PER_PIXEL (1<<TIK_PER_PIXEL_SHIFTS) #define ENGLISH_GRID 0 #define METRIC_GRID 1 #define PIX_PER_INCH 128 #define ONE_INCH (PIX_PER_INCH) #define HALF_INCH (PIX_PER_INCH/2) #define QUARTER_INCH (PIX_PER_INCH/4) #define EIGHTH_INCH (PIX_PER_INCH/8) #define DEFAULT_ENGLISH_GRID (EIGHTH_INCH) #define PIX_PER_MM 5 #define ONE_MM (PIX_PER_MM) #define TWO_MM (PIX_PER_MM*2) #define FIVE_MM (PIX_PER_MM*5) #define ONE_CM (PIX_PER_MM*10) #define DEFAULT_METRIC_GRID (TWO_MM) /* rotation -- clockwise */ #define ROTATE0 0 #define ROTATE90 1 #define ROTATE180 2 #define ROTATE270 3 #define CLOCKWISE90 (90<<6) #define COUNTER90 ((-90)<<6) #define CLOCKWISE180 (180<<6) #define COUNTER180 ((-180)<<6) #define CLOCKWISE270 (270<<6) #define COUNTER270 ((-270)<<6) /* flipping */ #define NO_FLIP 0 #define HORI_ODD (1<<0) #define HORI_EVEN (1<<1) #define VERT_ODD (1<<2) #define VERT_EVEN (1<<3) /* arc */ #define ARC_CCW 0 /* counter-clock-wise */ #define ARC_CW 1 /* clock-wise */ /* main menu */ #define MENU_FILE 0 #define MENU_EDIT 1 #define MENU_LAYOUT 2 #define MENU_ARRANGE 3 #define MENU_PROPERTIES 4 #define MENU_MOVEMODE 5 #define MENU_STACKEDPAGE 6 #define MENU_TILEDPAGE 7 #define MENU_PAGE 8 #define MENU_PAGELAYOUT 9 #define MENU_HORIALIGN 10 #define MENU_VERTALIGN 11 #define MENU_FONT 12 #define MENU_STYLE 13 #define MENU_SIZE 14 #define MENU_SHAPE 15 #define MENU_STRETCHTEXT 16 #define MENU_LINEDASH 17 #define MENU_LINESTYLE 18 #define MENU_LINETYPE 19 #define MENU_LINEWIDTH 20 #define MENU_FILL 21 #define MENU_PEN 22 #define MENU_TRANSPAT 23 #define MENU_COLOR 24 #define MENU_IMAGEPROC 25 #define MENU_NAVIGATE 26 #define MENU_SPECIAL 27 #define MENU_HELP 28 #define MENU_MODE 29 #define MENU_TANGRAM2 30 #define MAXMENUS 31 #define MENU_MAIN 31 /* mainMenu is treated differently */ /* file menu */ #define FILE_NEW 0 #define FILE_OPEN 1 #define FILE_SAVE 2 #define FILE_SAVENEW 3 #define FILE_IMPORT 4 #define FILE_IMPORTXBM 5 #define FILE_IMPORTXPM 6 #define FILE_IMPORTEPS 7 #define FILE_IMPORTGIF 8 #define FILE_IMPORTOTHERS 9 #define FILE_EMBEDEPS 10 #define FILE_BROWSEXBM 11 #define FILE_BROWSEXPM 12 #define FILE_BROWSEOTHERS 13 #define FILE_DOMAIN 14 #define FILE_DUMP 15 #define FILE_USR_DUMP 16 #define FILE_DUMPSELECTED 17 #define FILE_PRINTONE 18 #define FILE_SETEXPORTTRIM 19 #define FILE_INPUT_POLY 20 #define FILE_INPUT_POLYGON 21 #define FILE_SET_TEMPLATE 22 #define FILE_SOLVE 23 #define FILE_SIMULATE 24 #define FILE_PROBE 25 #define FILE_ANIMATE 26 #define FILE_ESCAPE 27 #define FILE_SAVESELAS 28 #define FILE_SAVESYMINLIB 29 #define FILE_QUIT 30 #define FILEMENUENTRIES 31 /* move mode stuff */ #define CONST_MOVE 0 #define UNCONST_MOVE 1 #define MAXMOVEMODES 2 /* stretchable text stuff */ #define NO_STRETCHABLE_TEXT 0 #define STRETCHABLE_TEXT 1 #define MAXSTRETCHABLEMODES 2 /* arrange menu */ #define ABUT_HORIZONTAL 0 #define ABUT_VERTICAL 1 /* nagivate menu */ #define NAVIGATE_BACK 0 #define NAVIGATE_FORWARD 1 #define NAVIGATE_REFRESH 2 #define NAVIGATE_HOTLIST 3 #define NAVIGATE_ADD 4 #define NAVIGATE_HISTORY 5 #define NAVIGATE_HYPERSPACE 6 #define MAXNAVIGATEMENUS 7 /* page menu */ #define PAGE_NEXT 0 #define PAGE_PREV 1 #define PAGE_NAME 2 #define PAGE_GOTO 3 #define PAGE_ADDBEFORE 4 #define PAGE_ADDAFTER 5 #define PAGE_DEL 6 #define PAGE_PRINT_ONE_IN_STACK 7 #define PAGE_PAPER_SIZE_IN_STACK 8 #define PAGE_DEL_MANY 9 #define PAGE_PRINT_ONE_FILE_PER_PAGE 10 #define MAXPAGESTACKMENUS 11 #define PAGE_TOGGLELINE 0 #define PAGE_SIZING 1 #define PAGE_PRINT_ONE 2 #define PAGE_PAPER_SIZE 3 #define MAXPAGETILEMENUS 4 #define PAGE_STACK 0 #define PAGE_TILE 1 #define MAXPAGELAYOUTMODES 2 /* scroll stuff */ #define VERT_SCROLLBAR 0 #define HORI_SCROLLBAR 1 #define SCROLL_LEFTEND 0 #define SCROLL_LEFT 1 #define SCROLL_RIGHT 2 #define SCROLL_RIGHTEND 3 #define SCROLL_UPEND 4 #define SCROLL_UP 5 #define SCROLL_CHECKALL 6 #define SCROLL_UNCHECKALL 7 #define SCROLL_DOWN 8 #define SCROLL_DOWNEND 9 #define MAXSCROLLBUTTONS 10 #define SCRL_UP 0 #define SCRL_DN 1 #define SCRL_LF 2 #define SCRL_RT 3 #define NO_UPDATE_SCROLLING 0 #define JUMP_SCROLLING 1 #define SMOOTH_SCROLLING 2 /* pixel stuff */ #ifdef sun #define PUT_A_POINT(dpy,win,gc,x,y) XDrawPoint(dpy,win,gc,x,y) #else /* ~sun */ #ifdef ultrix #define PUT_A_POINT(dpy,win,gc,x,y) XDrawPoint(dpy,win,gc,x,y) #else /* ~ultrix */ #ifdef _USE_XDRAWPOINT_TO_PUT_A_POINT #define PUT_A_POINT(dpy,win,gc,x,y) XDrawPoint(dpy,win,gc,x,y) #else /* ~_USE_XDRAWPOINT_TO_PUT_A_POINT */ #define PUT_A_POINT(dpy,win,gc,x,y) XDrawLine(dpy,win,gc,x,y,x,y) #endif /* _USE_XDRAWPOINT_TO_PUT_A_POINT */ #endif /* ultrix */ #endif /* sun */ /* file stuff */ #define OBJ_FILE_TYPE 0 #define SYM_FILE_TYPE 1 #define PIN_FILE_TYPE 2 /* xbm real_type */ #define XBM_XBM 0 #define XBM_EPS 1 #define XBM_EPSI 2 /* xpm real_type */ #define XPM_XPM 0 #define XPM_JPEG 1 #define PPM_TRUE 2 #define XPM_EPS 3 /* not implemented */ #define XPM_EPSI 4 /* not implemented */ #define PPM_DATA_RAW 0 /* not used */ #define PPM_JPEG_COMPRESS 1 #define PPM_DATA_DEFLATED 2 /* cmd stuff */ #define CMD_COMPOSITE 0 #define CMD_NEW 1 #define CMD_DELETE 2 #define CMD_MOVE 3 #define CMD_STRETCH 4 #define CMD_ONE_TO_MANY 5 #define CMD_MANY_TO_ONE 6 #define CMD_REPLACE 7 #define CMD_GOTO_PAGE 8 #define CMD_WB_CLEARALL 9 #define CMD_CHAT_A_LINE 10 #define CMD_WB_SLIDESHOW 11 /* rcb radius stuff */ #define DEF_RCB_RADIUS (EIGHTH_INCH) #define MIN_RCB_RADIUS 4 /* select name dialog box stuff */ #define ITEM_DSPED 10 #define ITEM_LEN 30 #define ROW_HEIGHT \ ((msgFontSet==NULL&&msgFontPtr==NULL)?(defaultFontHeight+1):(msgFontHeight+1)) #define BUTTON_OK 0 #define BUTTON_SETDIR 1 #define BUTTON_CANCEL 2 #define MAXBUTTONS 3 /* user redraw window stuff */ #define MAX_USER_REDRAWS 2 /* status window stuff */ #define MAX_STATUS_BTNS 3 /* copypaste stuff */ #define TGIF_HEADER 0x80 #define TGIF_PROTOCOL_ATOM "_TGIF_PROTOCOL_ATOM" /* interrupt stuff */ #define MAXINTRS 2 /* remote status */ #define TG_REMOTE_STATUS_OK 0 #define TG_REMOTE_STATUS_INTR 1 /* user interrupt */ #define TG_REMOTE_STATUS_MEM 2 /* memory allocation failed */ #define TG_REMOTE_STATUS_WRITE 3 /* write failed */ #define TG_REMOTE_STATUS_READ 4 /* read failed */ #define TG_REMOTE_STATUS_NET 5 /* unexpect network error */ #define TG_REMOTE_STATUS_HOST 6 /* gethostbyname failed */ #define TG_REMOTE_STATUS_FORMAT 7 /* format error */ #define TG_REMOTE_STATUS_TERM 8 /* terminated by the server */ #define TG_REMOTE_STATUS_FILE 9 /* fail to open file/socket */ #define FTP_LOGGED_IN 0x10000 /* corner stuff */ #define CORNER_NONE 0 #define CORNER_LT 1 #define CORNER_TOP 2 #define CORNER_RT 3 #define CORNER_RIGHT 4 #define CORNER_RB 5 #define CORNER_BOTTOM 6 #define CORNER_LB 7 #define CORNER_LEFT 8 /* free rotation stuff */ #define CTM_SX 0 #define CTM_SIN 1 #define CTM_MSIN 2 #define CTM_SY 3 #define CTM_TX 0 #define CTM_TY 1 /* msgbox stuff */ #define MB_ID_FAILED 0 #define MB_ID_OK 1 #define MB_ID_CANCEL 2 #define MB_ID_YES 3 #define MB_ID_NO 4 #define MB_ID_EXTRA 5 #define MB_BTN_NONE 0 #define MB_BTN_OK 1 #define MB_BTN_YESNOCANCEL 2 #define MB_BTN_OKCANCEL 3 #define MB_BTN_YESNO 4 #define MB_BTN_EXTRA 0x0008 #define MB_ICON_STOP 0x0010 #define MB_ICON_QUESTION 0x0020 #define MB_ICON_INFORMATION 0x0040 #define MB_ICON_DIALOG 0x0080 #define MB_BTNMASK 0x0007 #define MB_ICONMASK 0x00f0 #define INFO_MB (MB_BTN_OK | MB_ICON_INFORMATION) #define YNC_MB (MB_BTN_YESNOCANCEL | MB_ICON_QUESTION) #define YN_MB (MB_BTN_YESNO | MB_ICON_QUESTION) #define STOP_MB (MB_BTN_OK | MB_ICON_STOP) #define MB_PIXMAP_STOP 0 #define MB_PIXMAP_QUESTION 1 #define MB_PIXMAP_INFORMATION 2 #define MB_PIXMAP_DIALOG 3 #define MAX_MB_ICONS 4 /* expr stuff */ #define NULL_VAL 0 #define INT_VAL 1 #define DBL_VAL 2 #define STR_VAL 3 /* file version stuff */ #define START_HAVING_ATTRS 8 /* input method stuff */ #define TGIM_NONE INVALID #define TGIM_XCIN 0 #define TGIM_CHINPUT 1 #define TGIM_KINPUT 2 #define TGIM_XIM 3 #define TGIM_TGTWB5 4 #define TGIM_DBIM 0x1 #define TGIM_SBIM 0x2 /* postscript stuff */ #define PS_GSAVE 0 #define PS_GRESTORE 1 #define PS_NEWPATH 2 #define PS_CLOSEPATH 3 #define PS_CHARPATH 4 #define PS_CURVETO 5 #define PS_LINETO 6 #define PS_RLINETO 7 #define PS_MOVETO 8 #define PS_RMOVETO 9 #define PS_STROKE 10 #define PS_FILL 11 #define PS_TRANSLATE 12 #define PS_ROTATE 13 #define PS_SCALE 14 #define PS_MUL 15 #define PS_DIV 16 #define PS_DUP 17 #define PS_NEG 18 #define PS_ADD 19 #define PS_SUB 20 #define PS_POP 21 #define PS_EXCH 22 #define PS_CONCAT 23 #define PS_CLIP 24 #define PS_EOCLIP 25 #define PS_EOFILL 26 #define PS_IMAGE 27 #define PS_IMAGEMASK 28 #define PS_ARRAY 29 #define PS_SETGRAY 30 #define PS_SETRGBCOLOR 31 #define PS_SETDASH 32 #define PS_SETLINEWIDTH 33 #define PS_SETMITERLIMIT 34 #define PS_SETLINECAP 35 #define PS_SETLINEJOIN 36 #define PS_SHOW 37 #define PS_FINDFONT 38 #define PS_MAKESETFONT 39 #define PS_ARCTO4 40 #define PS_CURRENTPOINT 41 #define PS_FLATTENPATH 42 #define PS_TGIFSETMATRIX 43 #define PS_TGIFRESTOREMATRIX 44 /* shape stuff */ #define SHAPE_BOX 0 #define SHAPE_PARALLEL 1 #define SHAPE_TRAPEZOID 2 #define SHAPE_RHOMBUS 3 #define SHAPE_RCBOX 4 #define SHAPE_OCTAGON 5 #define SHAPE_CROSS 6 #define SHAPE_OVAL 7 #define SHAPE_WORDS 8 #define SHAPE_HEXAGON 9 #define SHAPE_TRIANGLE 10 #define SHAPE_BLAST 11 #define SHAPE_STAR 12 #define SHAPE_DISK 13 #define SHAPE_RIGHTARROW 14 #define SHAPE_UPARROW 15 #define SHAPE_FATRIGHTARROW 16 #define SHAPE_FATUPARROW 17 #define SHAPE_RIGHTTAB 18 #define SHAPE_UPTAB 19 #define MAXSHAPES 20 /* export filter stuff */ #define EXPORT_NEXT 1 #define EXPORT_PREV -1 #define EXPORT_THIS 0 /* generic object stuff */ #define TGO_STRING 0 #define TGO_VISUAL 1 #define TGO_MATH 2 #define TGO_DATE 3 #define TGO_USER 4 /* break up text stuff */ #define BREAK_CHAR 0 #define BREAK_WORD 1 #define BREAK_LINE 2 /* xpm stuff */ #define MAXXPMEXPORTCOLORS 6400 /* choose a file stuff */ #define NAMES_SIMPLE_SELECT_NAME 0 #define NAMES_COMPLEX_SELECT_NAME 1 #define NAMES_SELECT_FILE 2 #define NAMES_EDIT_ATTR 3 #define NAMES_EDIT_NAME 4 #define NAMES_LOOP_MANY 0 #define NAMES_LOOP_ONCE 1 /* properties stuff */ #define PROP_MASK_CTM 0x00000001 #define PROP_MASK_COLOR 0x00000002 #define PROP_MASK_WIDTH 0x00000004 #define PROP_MASK_AW 0x00000008 #define PROP_MASK_AH 0x00000010 #define PROP_MASK_TRANSPAT 0x00000020 #define PROP_MASK_FILL 0x00000040 #define PROP_MASK_PEN 0x00000080 #define PROP_MASK_DASH 0x00000100 #define PROP_MASK_ARROW_STYLE 0x00000200 #define PROP_MASK_CURVED 0x00000400 #define PROP_MASK_RCB_RADIUS 0x00000800 #define PROP_MASK_TEXT_JUST 0x00001000 #define PROP_MASK_TEXT_SZ_UNIT 0x00002000 #define PROP_MASK_TEXT_FONT 0x00004000 #define PROP_MASK_TEXT_STYLE 0x00008000 /* ChangeEditTextProperty() only */ #define PROP_MASK_VSPACE 0x00010000 #define PROP_MASK_UNDERLINE_ON 0x00020000 #define PROP_MASK_OVERLINE_ON 0x00040000 #define PROP_MASK_WIDTH_INDEX 0x00100000 /* GetProperty() only */ /* mark stuff */ #define FORWARD 0 #define REVERSE 1 /* auto rotate pivot stuff */ #define AUTO_ROTATE_PIVOT 0 #define USER_ROTATE_PIVOT 1 #define MAX_ROTATE_PIVOT 2 #endif /*_TGIF_CONST_H_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/cmd.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000207112�11602233311�013675� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/cmd.c,v 1.15 2011/05/16 16:21:56 william Exp $ */ #define _INCLUDE_FROM_CMD_C_ #include "tgifdefs.h" #include "attr.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "grid.e" #include "imgproc.e" #include "mainmenu.e" #include "mark.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "remote.e" #include "select.e" #include "setup.e" #include "stk.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "wb.e" #include "xpixmap.e" int recordCmdIncludeTgifObj=FALSE; int recordCmdUsesNewColormap=FALSE; int undoingOrRedoing=FALSE; int historyDepth=(-1), historyCount=0, defaultHistoryDepth=(-1); struct CmdRec *firstCmd=NULL, *lastCmd=NULL, *curCmd=NULL; struct SelRec *topSelBeforeInCmd=NULL, *botSelBeforeInCmd=NULL; int *stackingPosition=NULL; int stackingCount=0; int stackingPositionHasIds=FALSE; int composingCommand=FALSE; int undoRedoRestoreDrawingMode=FALSE; Colormap preparedColormap=None; void InsertCmd(PrevCmd, NextCmd, CmdPtr, ppFirstCmd, ppLastCmd) struct CmdRec *PrevCmd, *NextCmd, *CmdPtr; struct CmdRec **ppFirstCmd, **ppLastCmd; /* add CmdPtr between PrevCmd and NextCmd */ /* update *ppFirstCmd and *ppLastCmd */ { CmdPtr->prev = PrevCmd; CmdPtr->next = NextCmd; if (PrevCmd == NULL) { (*ppFirstCmd) = CmdPtr; } else { PrevCmd->next = CmdPtr; } if (NextCmd == NULL) { (*ppLastCmd) = CmdPtr; } else { NextCmd->prev = CmdPtr; } } static char *GetCmdType(CmdType) int CmdType; { switch (CmdType) { case CMD_COMPOSITE: return "CMD_COMPOSITE"; case CMD_NEW: return "CMD_NEW"; case CMD_DELETE: return "CMD_DELETE"; case CMD_MOVE: return "CMD_MOVE"; case CMD_STRETCH: return "CMD_STRETCH"; case CMD_ONE_TO_MANY: return "CMD_ONE_TO_MANY"; case CMD_MANY_TO_ONE: return "CMD_MANY_TO_ONE"; case CMD_REPLACE: return "CMD_REPLACE"; case CMD_GOTO_PAGE: return "CMD_GOTO_PAGE"; case CMD_WB_CLEARALL: return "CMD_WB_CLEARALL"; case CMD_CHAT_A_LINE: return "CMD_CHAT_A_LINE"; case CMD_WB_SLIDESHOW: return "CMD_WB_SLIDESHOW"; default: return "(unknown)"; } } static struct CmdRec *CreateCmdFromSerializationBuf(cmd_type, buf) int cmd_type; char *buf; { struct CmdRec *cmd_ptr=NULL; cmd_ptr = (struct CmdRec *)malloc(sizeof(struct CmdRec)); if (cmd_ptr == NULL) FailAllocMessage(); memset(cmd_ptr, 0, sizeof(struct CmdRec)); cmd_ptr->type = cmd_type; cmd_ptr->serialization_buf = UtilStrDup(buf); if (cmd_ptr->serialization_buf == NULL) FailAllocMessage(); return cmd_ptr; } void CopyAndInsertCmd(from_remote, serialization_buf, PrevCmd, NextCmd, CmdPtr, ppFirstCmd, ppLastCmd) int from_remote; char *serialization_buf; struct CmdRec *PrevCmd, *NextCmd, *CmdPtr; struct CmdRec **ppFirstCmd, **ppLastCmd; /* add CmdPtr between PrevCmd and NextCmd */ /* update *ppFirstCmd and *ppLastCmd */ { if ((!from_remote && CmdPtr->undone) || (from_remote && !CmdPtr->undone)) { sprintf(gszMsgBox, "(%s) Found an %s command, type = %s.", (from_remote ? "from_remote" : "local"), (CmdPtr->undone ? "undone" : "not undone"), GetCmdType(CmdPtr->type)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { struct CmdRec *cmd_ptr=NULL; #ifdef _TGIF_DBG_WB2 fprintf(stdout, "<*><*><*>(%s) CopyAndInsertCmd() a command of type: %s.\n", (from_remote ? "from_remote" : "local"), GetCmdType(CmdPtr->type)); fflush(stdout); #endif /* _TGIF_DBG_WB2 */ cmd_ptr = CreateCmdFromSerializationBuf(CmdPtr->type, serialization_buf); cmd_ptr->prev = PrevCmd; cmd_ptr->next = NextCmd; if (PrevCmd == NULL) { (*ppFirstCmd) = cmd_ptr; } else { PrevCmd->next = cmd_ptr; } if (NextCmd == NULL) { (*ppLastCmd) = cmd_ptr; } else { NextCmd->prev = cmd_ptr; } } } static void UnlinkCmd(CmdPtr, ppFirstCmd, ppLastCmd) struct CmdRec *CmdPtr; struct CmdRec **ppFirstCmd, **ppLastCmd; { if ((*ppFirstCmd) == CmdPtr) { (*ppFirstCmd) = CmdPtr->next; } else { CmdPtr->prev->next = CmdPtr->next; } if ((*ppLastCmd) == CmdPtr) { (*ppLastCmd) = CmdPtr->prev; } else { CmdPtr->next->prev = CmdPtr->prev; } } void DeleteARedoRecord(CmdPtr, percent_start, percent_end) struct CmdRec *CmdPtr; double percent_start, percent_end; { struct SelRec *sel_ptr=NULL, *next_sel=NULL; struct CmdRec *cmd_ptr=NULL, *prev_cmd=NULL; int num_records=0; double inc=0; if (CmdPtr->pos_before_has_ids) { if (CmdPtr->pos_before != NULL) { int i=0; char **s_ptr=(char**)(CmdPtr->pos_before); for (i=0; i < CmdPtr->count_before; i++) { if (s_ptr[i] != NULL) { UtilFree(s_ptr[i]); } else { break; } } free(CmdPtr->pos_before); } } else { if (CmdPtr->pos_before != NULL) free(CmdPtr->pos_before); } if (CmdPtr->pos_after != NULL) free(CmdPtr->pos_after); if (percent_start >= 0.0) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_FLUSH_UNDO_PERCENT), round(percent_start)); SetStringStatus(gszMsgBox); CheckInterrupt(TRUE); } switch (CmdPtr->type) { case CMD_NEW: for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; if (CmdPtr->undone) FreeObj(sel_ptr->obj); free(sel_ptr); } break; case CMD_DELETE: for (sel_ptr=CmdPtr->top_before; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; if (!CmdPtr->undone) FreeObj(sel_ptr->obj); free(sel_ptr); } break; case CMD_MOVE: for (sel_ptr=CmdPtr->top_before; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } if (CmdPtr->subcmd != NULL) { free(CmdPtr->subcmd); } break; case CMD_STRETCH: for (sel_ptr=CmdPtr->top_before; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; FreeObj(sel_ptr->obj); free(sel_ptr); } if (CmdPtr->serialized) { for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } } break; case CMD_REPLACE: for (sel_ptr=CmdPtr->top_before; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; FreeObj(sel_ptr->obj); free(sel_ptr); } if (CmdPtr->serialized) { for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } } break; case CMD_ONE_TO_MANY: for (sel_ptr=CmdPtr->top_before; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; if (!CmdPtr->undone) FreeObj(sel_ptr->obj); free(sel_ptr); } for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; if (CmdPtr->undone) FreeObj(sel_ptr->obj); free(sel_ptr); } break; case CMD_MANY_TO_ONE: for (sel_ptr=CmdPtr->top_before; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; if (!CmdPtr->undone) FreeObj(sel_ptr->obj); free(sel_ptr); } for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; if (CmdPtr->undone) FreeObj(sel_ptr->obj); free(sel_ptr); } break; case CMD_COMPOSITE: if (percent_start >= 0) { for (cmd_ptr=CmdPtr->first; cmd_ptr!=NULL; cmd_ptr=cmd_ptr->next) { num_records++; } if (num_records > 0) { inc = (percent_end-percent_start)/((double)num_records); } } for (cmd_ptr=CmdPtr->last; cmd_ptr!=NULL; cmd_ptr=prev_cmd) { prev_cmd = cmd_ptr->prev; if (percent_start >= 0) { DeleteARedoRecord(cmd_ptr, percent_start, min(((double)percent_start+inc),((double)100.0))); percent_start += inc; } else { DeleteARedoRecord(cmd_ptr, percent_start, percent_end); } } break; case CMD_CHAT_A_LINE: if (CmdPtr->subcmd != NULL) { UtilFree(CmdPtr->subcmd->detail.chat.buf); free(CmdPtr->subcmd); } break; case CMD_WB_SLIDESHOW: if (CmdPtr->subcmd != NULL) free(CmdPtr->subcmd); break; case CMD_WB_CLEARALL: if (CmdPtr->subcmd != NULL) free(CmdPtr->subcmd); break; } if (gstWBInfo.do_whiteboard) { if (CmdPtr->sender_process_id != NULL) { UtilFree(CmdPtr->sender_process_id); } if (CmdPtr->serialization_buf != NULL) { UtilFree(CmdPtr->serialization_buf); } } free(CmdPtr); } void ClearRedoRecords(CmdPtr) struct CmdRec *CmdPtr; { struct CmdRec *cmd_ptr=NULL, *prev_cmd=NULL; for (cmd_ptr=lastCmd; cmd_ptr != curCmd; cmd_ptr=prev_cmd) { prev_cmd = cmd_ptr->prev; DeleteARedoRecord(cmd_ptr, (-1.0), (-1.0)); historyCount--; } if ((lastCmd=curCmd) == NULL) firstCmd = NULL; } void CleanUpCmds() { struct CmdRec *cmd_ptr=NULL, *prev_cmd=NULL; int num_records=0; for (cmd_ptr=lastCmd; cmd_ptr != NULL; cmd_ptr=cmd_ptr->prev) { num_records++; } if (num_records > 0) { double inc=(100.0/((double)num_records)), percent_start=0.0; ShowInterrupt(1); SaveStatusStrings(); for (cmd_ptr=lastCmd; cmd_ptr != NULL; cmd_ptr=prev_cmd, percent_start += inc) { prev_cmd = cmd_ptr->prev; DeleteARedoRecord(cmd_ptr, percent_start, min(((double)percent_start+inc),((double)100.0))); } RestoreStatusStrings(); HideInterrupt(); } firstCmd = lastCmd = curCmd = NULL; historyCount = 0; } void CopySel(from_top_sel, count, to_top_sel, to_bot_sel) struct SelRec *from_top_sel; int count; struct SelRec **to_top_sel, **to_bot_sel; { struct SelRec *sel_ptr=NULL; *to_top_sel = *to_bot_sel = NULL; for (sel_ptr=from_top_sel; sel_ptr!=NULL; sel_ptr=sel_ptr->next, count--) { AddObjIntoSel(sel_ptr->obj, *to_bot_sel, NULL, to_top_sel, to_bot_sel); } if (count != 0) { FatalUnexpectedError( "Count != 0 in CopySel().", /* debug, do not translate */ TgLoadString(STID_UNDO_REDO_MAY_CAUSE_CRASH)); } } static void LinkJustTheObjects(TopSel, BotSel) struct SelRec *TopSel, *BotSel; { struct SelRec *sel_ptr=NULL, *sel_ptr_next=NULL; sel_ptr = TopSel; sel_ptr_next = TopSel->next; sel_ptr->obj->prev = NULL; for ( ; sel_ptr_next!=NULL; sel_ptr=sel_ptr_next, sel_ptr_next=sel_ptr->next) { sel_ptr->obj->next = sel_ptr_next->obj; sel_ptr_next->obj->prev = sel_ptr->obj; } sel_ptr->obj->next = NULL; } static void UndoNewCmd(CmdPtr) struct CmdRec *CmdPtr; { struct SelRec *sel_ptr=NULL; struct ObjRec *obj_ptr=NULL, *next_obj=NULL; int pos=0, count=0; topSel = CmdPtr->top_after; botSel = CmdPtr->bot_after; sel_ptr = topSel; pos = count = 0; for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=next_obj, pos++) { next_obj = obj_ptr->next; if (pos == CmdPtr->pos_after[count]) { count++; sel_ptr->obj = obj_ptr; UnlinkObj(obj_ptr); sel_ptr = sel_ptr->next; if (count == CmdPtr->count_after) break; } } LinkJustTheObjects(CmdPtr->top_after, CmdPtr->bot_after); UpdSelBBox(); topSel = botSel = NULL; RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; } static void RedoNewCmd(CmdPtr) struct CmdRec *CmdPtr; { struct ObjRec *saved_top_obj, *saved_bot_obj; CopySel(CmdPtr->top_after, CmdPtr->count_after, &topSel, &botSel); saved_top_obj = topObj; saved_bot_obj = botObj; curPage->top = topObj = CmdPtr->top_after->obj; curPage->bot = botObj = CmdPtr->bot_after->obj; AdjSplineVs(); AdjCaches(); curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; if (topObj == NULL) { curPage->bot = botObj = botSel->obj; } else { topObj->prev = botSel->obj; } botSel->obj->next = topObj; curPage->top = topObj = topSel->obj; UpdSelBBox(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); if (!deserializingFile) HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } static int ObjHasFullID(obj_ptr, psz_full_id) struct ObjRec *obj_ptr; char *psz_full_id; { if (*psz_full_id != '#') { if (gstWBInfo.do_whiteboard) { /* debug, do not translate */ sprintf(gszMsgBox, "%s, psz_full_id = %s, pid = %ld.", "Unexpected *psz_full_id != '#' in ObjHasFullID()", psz_full_id, gstWBInfo.pid); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } psz_full_id = strchr(psz_full_id, ':'); psz_full_id++; if (obj_ptr->creator_full_id == NULL) { char buf[MAXSTRING]; sprintf(buf, "%1d/%s", obj_ptr->id, gszLocalPID); return (strcmp(buf, psz_full_id) == 0); } return (strcmp(obj_ptr->creator_full_id, psz_full_id) == 0); } static int GetPositionFromFullID(psz_full_id) char *psz_full_id; { int pos_to_match=INVALID; char *psz=NULL; if (*psz_full_id != '#') { if (gstWBInfo.do_whiteboard) { /* debug, do not translate */ sprintf(gszMsgBox, "%s, psz_full_id = %s, pid = %ld.", "Unexpected *psz_full_id != '#' in GetPositionFromFullID()", psz_full_id, gstWBInfo.pid); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } psz = strchr(++psz_full_id, ':'); *psz = '\0'; if (sscanf(psz_full_id, "%d", &pos_to_match) != 1 || pos_to_match == INVALID) { if (gstWBInfo.do_whiteboard) { /* debug, do not translate */ sprintf(gszMsgBox, "%s %s (%s), psz_full_id = %s, pid = %ld.", "Format error in parsing pos_to_match in", "GetPositionFromFullID()", "cannot get pos_to_match", psz_full_id, gstWBInfo.pid); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } *psz = ':'; return pos_to_match; } static void UndoDeleteCmd(CmdPtr) struct CmdRec *CmdPtr; { struct SelRec *sel_ptr=NULL; struct ObjRec *obj_ptr=NULL, *next_obj=NULL; struct ObjRec *saved_top_obj=NULL, *saved_bot_obj=NULL; int count=0, pos=0, pos_to_match=INVALID; CopySel(CmdPtr->top_before, CmdPtr->count_before, &topSel, &botSel); saved_top_obj = topObj; saved_bot_obj = botObj; LinkJustTheObjects(CmdPtr->top_before, CmdPtr->bot_before); curPage->top = topObj = CmdPtr->top_before->obj; curPage->bot = botObj = CmdPtr->bot_before->obj; AdjSplineVs(); AdjCaches(); curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; count = 0; sel_ptr = topSel; if (CmdPtr->pos_before_has_ids) { pos_to_match = GetPositionFromFullID( (char*)(long)(CmdPtr->pos_before[count])); } else { pos_to_match = CmdPtr->pos_before[count]; } for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=next_obj, pos++) { if (pos == pos_to_match) { AddObj(obj_ptr->prev, obj_ptr, sel_ptr->obj); next_obj = obj_ptr; count++; sel_ptr = sel_ptr->next; if (count == CmdPtr->count_before) break; if (CmdPtr->pos_before_has_ids) { pos_to_match = GetPositionFromFullID( (char*)(long)(CmdPtr->pos_before[count])); } else { pos_to_match = CmdPtr->pos_before[count]; } } else { next_obj = obj_ptr->next; } } for ( ; sel_ptr != NULL; sel_ptr=sel_ptr->next) { AddObj(botObj, NULL, sel_ptr->obj); } UpdSelBBox(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); if (!deserializingFile) HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } static int SetupBeforePointers(CmdPtr, modify_before_pointers, pp_actual_pos_before) struct CmdRec *CmdPtr; int modify_before_pointers, **pp_actual_pos_before; /* * CmdPtr->pos_before is an array of strings containing * "#<pos>:<oid>/<pid>:<hostname>". * CmdPtr->count_before is assumed to be the number of elements in * CmdPtr->pos_before. * * if (modify_before_pointers) { * Setup CmdPtr->top_before and CmdPtr->bot_before. * For these cases, <oid>/<pid>:<hostname> is used to locate the * object positions to build the actual before pointers. * } else { * This can only happen if (CmdPtr->serialized && * CmdPtr->type == CMD_REPLACE && !CmdPtr->undone) * In this case, the #<pos> should be used to setup up the actual * before pointers. * } * if (pp_actual_pos_before != NULL) { * Create an array of integers containing the positions of the * objects referenced in CmdPtr->pos_before and return this array. * } */ { int index, ok=TRUE, cur_pos=0; struct ObjRec *obj_ptr=topObj; struct SelRec *sel_ptr=NULL, *next_sel=NULL, *top_sel=NULL, *bot_sel=NULL; if (modify_before_pointers) { for (sel_ptr=CmdPtr->top_before; sel_ptr != NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } CmdPtr->top_before = CmdPtr->bot_before = NULL; } if (pp_actual_pos_before != NULL) { *pp_actual_pos_before = (int*)malloc(CmdPtr->count_before*sizeof(int)); if (*pp_actual_pos_before == NULL) FailAllocMessage(); memset(*pp_actual_pos_before, 0, CmdPtr->count_before*sizeof(int)); } for (index=0; index < CmdPtr->count_before; index++) { char *psz_full_id=(((char**)CmdPtr->pos_before)[index]), *psz=NULL; char pid_and_host[MAXSTRING]; int id=(-1), found=FALSE, pos_to_match=INVALID, obj_is_tgifobj=FALSE; if (*psz_full_id == '#') { psz = strchr(++psz_full_id, ':'); *psz = '\0'; if (!modify_before_pointers) { if (sscanf(psz_full_id, "%d", &pos_to_match) != 1 || pos_to_match == INVALID) { if (gstWBInfo.do_whiteboard) { /* debug, do not translate */ sprintf(gszMsgBox, "%s %s (%s), psz_full_id = %s, pid = %ld.", "Format error in parsing pos_to_match in", "SetupBeforePointers()", "cannot get pos_to_match", psz_full_id, gstWBInfo.pid); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } } *psz++ = ':'; psz_full_id = psz; } psz = strchr(psz_full_id, '/'); *pid_and_host = '\0'; if (psz == NULL) { if (gstWBInfo.do_whiteboard) { /* debug, do not translate */ sprintf(gszMsgBox, "%s (%s), psz_full_id = %s, pid = %ld.", "Format error in parsing id in SetupBeforePointers()", "cannot find ':'", psz_full_id, gstWBInfo.pid); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } ok = FALSE; break; } else { *psz = '\0'; if (sscanf(psz_full_id, "%d", &id) == 1) { strcpy(pid_and_host, &psz[1]); if (id == INVALID) { obj_is_tgifobj = TRUE; } } else { if (gstWBInfo.do_whiteboard) { /* debug, do not translate */ sprintf(gszMsgBox, "%s (%s), psz_full_id = %s, pid = %ld.", "Format error in parsing id in SetupBeforePointers()", "cannot find id", psz_full_id, gstWBInfo.pid); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } ok = FALSE; break; } *psz = '/'; } if (ok) { for (obj_ptr=topObj, cur_pos=0 ; ok && obj_ptr != NULL; obj_ptr=obj_ptr->next, cur_pos++) { if (pos_to_match == INVALID) { if (obj_ptr->creator_full_id == NULL) { if (obj_ptr->id == id && strcmp(pid_and_host, gszLocalPID) == 0) { found = TRUE; } else if (obj_ptr->id == INVALID && CmdPtr->include_tgif_obj && obj_is_tgifobj) { found = TRUE; } } else { if (strcmp(obj_ptr->creator_full_id, psz_full_id) == 0) { found = TRUE; } } } else if (pos_to_match == cur_pos) { found = TRUE; } if (found) { if (modify_before_pointers) { AddObjIntoSel(obj_ptr, bot_sel, NULL, &top_sel, &bot_sel); } if (pp_actual_pos_before != NULL) { (*pp_actual_pos_before)[index] = cur_pos; } obj_ptr = obj_ptr->next; cur_pos++; break; } } } if (ok && !found) { if (gstWBInfo.do_whiteboard) { /* debug, do not translate */ #ifdef _TGIF_DBG_WB2 /* debug, do not translate */ fprintf(stderr, "%s: '%s' %s, pid = %ld.\n\t(%s=%1d, %s='%s')\n", "@*@ Cannot find object id", psz_full_id, "in SetupBeforePointers()", gstWBInfo.pid, "id", id, "pid_and_host", pid_and_host); #endif /* _TGIF_DBG_WB2 */ } ok = FALSE; break; } } if (ok && index != CmdPtr->count_before) { if (gstWBInfo.do_whiteboard) { /* debug, do not translate */ sprintf(gszMsgBox, "%s (%1d) %s (%1d) %s, pid = %ld.", "Index", index, "!= CmdPtr->count_before", CmdPtr->count_before, "in SetupBeforePointers()", gstWBInfo.pid); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } ok = FALSE; } if (!ok) { for (sel_ptr=top_sel; sel_ptr != NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } if (pp_actual_pos_before != NULL) { free(*pp_actual_pos_before); *pp_actual_pos_before = NULL; } } else { if (modify_before_pointers) { CmdPtr->top_before = top_sel; CmdPtr->bot_before = bot_sel; } } return ok; } static int RedoDeleteCmd(CmdPtr) struct CmdRec *CmdPtr; { struct SelRec *sel_ptr; if (CmdPtr->serialized) { if (CmdPtr->include_tgif_obj) { AddObj(NULL, topObj, tgifObj); } if (!SetupBeforePointers(CmdPtr, TRUE, NULL)) { if (CmdPtr->include_tgif_obj) { UnlinkObj(topObj); } return FALSE; } if (CmdPtr->include_tgif_obj) { UnlinkObj(topObj); } } topSel = CmdPtr->top_before; botSel = CmdPtr->bot_before; sel_ptr = topSel; if (CmdPtr->serialized) { for ( ; sel_ptr != NULL; sel_ptr=sel_ptr->next) { UnlinkObj(sel_ptr->obj); } } else { struct ObjRec *obj_ptr=NULL, *next_obj=NULL; int count=0; if (CmdPtr->pos_before_has_ids) { for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=next_obj) { next_obj = obj_ptr->next; if (ObjHasFullID(obj_ptr, (char*)(long)(CmdPtr->pos_before[count]))) { count++; sel_ptr->obj = obj_ptr; UnlinkObj(obj_ptr); sel_ptr = sel_ptr->next; if (count == CmdPtr->count_before) break; } } } else { int pos=0; for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=next_obj, pos++) { next_obj = obj_ptr->next; if (pos == CmdPtr->pos_before[count]) { count++; sel_ptr->obj = obj_ptr; UnlinkObj(obj_ptr); sel_ptr = sel_ptr->next; if (count == CmdPtr->count_before) break; } } } } LinkJustTheObjects(CmdPtr->top_before, CmdPtr->bot_before); UpdSelBBox(); topSel = botSel = NULL; RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; return TRUE; } static int UndoOrRedoMoveCmd(CmdPtr) struct CmdRec *CmdPtr; { struct SelRec *sel_ptr; struct ObjRec *obj_ptr; int dx, dy; if (CmdPtr->serialized) { if (CmdPtr->include_tgif_obj) { AddObj(NULL, topObj, tgifObj); } if (!SetupBeforePointers(CmdPtr, TRUE, NULL)) { if (CmdPtr->include_tgif_obj) { UnlinkObj(topObj); } return FALSE; } if (CmdPtr->include_tgif_obj) { UnlinkObj(topObj); } } dx = (CmdPtr->undone) ? CmdPtr->subcmd->detail.move.dx : -(CmdPtr->subcmd->detail.move.dx); dy = (CmdPtr->undone) ? CmdPtr->subcmd->detail.move.dy : -(CmdPtr->subcmd->detail.move.dy); CopySel(CmdPtr->top_before, CmdPtr->count_before, &topSel, &botSel); sel_ptr = topSel; if (CmdPtr->serialized) { for ( ; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; if (!obj_ptr->locked) MoveObj(obj_ptr, dx, dy); } } else { struct ObjRec *next_obj; int count=0; if (CmdPtr->pos_before_has_ids) { for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=next_obj) { next_obj = obj_ptr->next; if (ObjHasFullID(obj_ptr, (char*)(long)(CmdPtr->pos_before[count]))) { count++; sel_ptr->obj = obj_ptr; if (!obj_ptr->locked) MoveObj(obj_ptr, dx, dy); sel_ptr = sel_ptr->next; if (count == CmdPtr->count_before) break; } } } else { int pos=0; for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=next_obj, pos++) { next_obj = obj_ptr->next; if (pos == CmdPtr->pos_before[count]) { count++; sel_ptr->obj = obj_ptr; if (!obj_ptr->locked) MoveObj(obj_ptr, dx, dy); sel_ptr = sel_ptr->next; if (count == CmdPtr->count_before) break; } } } } UpdSelBBox(); RedrawAreas(botObj, selLtX-GRID_ABS_SIZE(1)-dx, selLtY-GRID_ABS_SIZE(1)-dy, selRbX+GRID_ABS_SIZE(1)-dx, selRbY+GRID_ABS_SIZE(1)-dy, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); if (!deserializingFile) HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; return TRUE; } static void UpdateXPmObjectsInACmd(CmdPtr) struct CmdRec *CmdPtr; { struct CmdRec *cmd_ptr; struct SelRec *sel_ptr; switch (CmdPtr->type) { case CMD_COMPOSITE: for (cmd_ptr=CmdPtr->first; cmd_ptr!=NULL; cmd_ptr=cmd_ptr->next) { UpdateXPmObjectsInACmd(cmd_ptr); } break; case CMD_NEW: for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=sel_ptr->next) { UpdateXPmObjects(sel_ptr->obj); } break; case CMD_DELETE: break; case CMD_MOVE: break; case CMD_STRETCH: break; case CMD_REPLACE: for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=sel_ptr->next) { UpdateXPmObjects(sel_ptr->obj); } break; case CMD_ONE_TO_MANY: break; case CMD_MANY_TO_ONE: for (sel_ptr=CmdPtr->top_before; sel_ptr!=NULL; sel_ptr=sel_ptr->next) { UpdateXPmObjects(sel_ptr->obj); } for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=sel_ptr->next) { UpdateXPmObjects(sel_ptr->obj); } break; case CMD_GOTO_PAGE: break; } } static int UpdatePixelInACmd(CmdPtr) struct CmdRec *CmdPtr; { struct CmdRec *cmd_ptr; struct SelRec *sel_ptr; int changed=FALSE; switch (CmdPtr->type) { case CMD_COMPOSITE: for (cmd_ptr=CmdPtr->first; cmd_ptr!=NULL; cmd_ptr=cmd_ptr->next) { if (UpdatePixelInACmd(cmd_ptr)) { changed = TRUE; } } break; case CMD_NEW: for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=sel_ptr->next) { if (UpdatePixel(sel_ptr->obj)) { changed = TRUE; } } break; case CMD_DELETE: break; case CMD_MOVE: break; case CMD_STRETCH: break; case CMD_REPLACE: for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=sel_ptr->next) { if (UpdatePixel(sel_ptr->obj)) { changed = TRUE; } } break; case CMD_ONE_TO_MANY: break; case CMD_MANY_TO_ONE: for (sel_ptr=CmdPtr->top_before; sel_ptr!=NULL; sel_ptr=sel_ptr->next) { if (UpdatePixel(sel_ptr->obj)) { changed = TRUE; } } for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=sel_ptr->next) { if (UpdatePixel(sel_ptr->obj)) { changed = TRUE; } } break; case CMD_GOTO_PAGE: break; } return changed; } static int RefreshColormap(nRedoing, CmdPtr) int nRedoing; struct CmdRec *CmdPtr; /* * This function mimics FlushColormap() in color.c. */ { int changed=FALSE, saved_color_layers; struct ObjRec *obj_ptr=NULL; struct PageRec *page_ptr=NULL; Colormap colormap=XCopyColormapAndFree(mainDisplay, mainColormap); mainColormap = colormap; newColormapUsed = TRUE; XSetWindowColormap(mainDisplay, mainWindow, mainColormap); if (nRedoing) { /* need to scan forward to pick up objects */ struct CmdRec *cmd_ptr; for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next) { for (obj_ptr=page_ptr->bot; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { UpdateXPmObjects(obj_ptr); } } for (cmd_ptr=CmdPtr->next; cmd_ptr != NULL; cmd_ptr=cmd_ptr->next) { UpdateXPmObjectsInACmd(cmd_ptr); } } else { for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next) { for (obj_ptr=page_ptr->bot; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { UpdateXPmObjects(obj_ptr); } } } initColorDontReload = TRUE; CleanUpColors(); XFreeColormap(mainDisplay, mainColormap); mainColormap = DefaultColormap(mainDisplay, mainScreen); XSetWindowColormap(mainDisplay, mainWindow, mainColormap); newColormapUsed = FALSE; saved_color_layers = colorLayers; InitColor(); initColorDontReload = FALSE; colorLayers = saved_color_layers; ShowColor(TRUE); SaveStatusStrings(); gnUpdatePixelObjCount = 0; if (nRedoing) { /* need to scan forward to pick up objects */ struct CmdRec *cmd_ptr; for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next) { for (obj_ptr=page_ptr->bot; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { if (UpdatePixel(obj_ptr)) { changed = TRUE; } } } for (cmd_ptr=CmdPtr->next; cmd_ptr != NULL; cmd_ptr=cmd_ptr->next) { if (UpdatePixelInACmd(cmd_ptr)) { changed = TRUE; } } } else { for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next) { for (obj_ptr=page_ptr->bot; obj_ptr!=NULL; obj_ptr=obj_ptr->prev) { if (UpdatePixel(obj_ptr)) { changed = TRUE; } } } } RestoreStatusStrings(); DestroyPinnedMenu(MENU_COLOR); if (colorLayers) { RedrawColorWindow(); } return changed; } static int UndoOrRedoReplaceCmd(CmdPtr, HighLightSingleObj) struct CmdRec *CmdPtr; int HighLightSingleObj; { struct ObjRec *obj_ptr=NULL, *next_obj=NULL; struct SelRec *sel_ptr=NULL; struct SelRec *saved_top_sel=NULL, *saved_bot_sel=NULL; struct ObjRec *saved_top_obj=NULL, *saved_bot_obj=NULL; int ltx, lty, rbx, rby, pos, count, *pos_table, max_count; int need_clear_and_redraw=FALSE; int *actual_pos_before=NULL; #ifdef _TGIF_DBG_WB2 /* debug, do not translate */ if (gstWBInfo.do_whiteboard) { fprintf(stderr, "@@@ Beginning of UndoOrRedoReplaceCmd()...\n"); fprintf(stderr, "\tCmdPtr->serialized=%1d...\n", CmdPtr->serialized); } #endif /* _TGIF_DBG_WB2 */ if (CmdPtr->serialized) { int shuffle=FALSE; if (CmdPtr->first_redo_after_deserialize && CmdPtr->undone) { CmdPtr->first_redo_after_deserialize = FALSE; shuffle = TRUE; } #ifdef _TGIF_DBG_WB2 /* debug, do not translate */ if (gstWBInfo.do_whiteboard) { fprintf(stderr, "In UndoOrRedoReplaceCmd(), shuffle=%1d.\n", shuffle); } #endif /* _TGIF_DBG_WB2 */ if (CmdPtr->include_tgif_obj) { AddObj(NULL, topObj, tgifObj); } if (shuffle) { if (!SetupBeforePointers(CmdPtr, TRUE, NULL)) { if (CmdPtr->include_tgif_obj) { UnlinkObj(topObj); } return FALSE; } topSel = CmdPtr->top_before; botSel = CmdPtr->bot_before; CmdPtr->top_before = CmdPtr->top_after; CmdPtr->bot_before = CmdPtr->bot_after; CmdPtr->top_after = topSel; CmdPtr->bot_after = botSel; topSel = botSel = NULL; } else { if (CmdPtr->undone) { struct SelRec *next_sel=NULL; for (sel_ptr=CmdPtr->top_after; sel_ptr != NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } CmdPtr->top_after = CmdPtr->bot_after = NULL; saved_top_sel = CmdPtr->top_before; saved_bot_sel = CmdPtr->bot_before; CmdPtr->top_before = CmdPtr->bot_before = NULL; if (!SetupBeforePointers(CmdPtr, TRUE, NULL)) { if (CmdPtr->include_tgif_obj) { UnlinkObj(topObj); } return FALSE; } CmdPtr->top_after = CmdPtr->top_before; CmdPtr->bot_after = CmdPtr->bot_before; CmdPtr->top_before = saved_top_sel; CmdPtr->bot_before = saved_bot_sel; } else { if (!SetupBeforePointers(CmdPtr, FALSE, &actual_pos_before)) { if (CmdPtr->include_tgif_obj) { UnlinkObj(topObj); } return FALSE; } } } if (CmdPtr->include_tgif_obj) { UnlinkObj(topObj); } } LinkJustTheObjects(CmdPtr->top_before, CmdPtr->bot_before); CopySel(CmdPtr->top_before, CmdPtr->count_before, &topSel, &botSel); if (CmdPtr->include_tgif_obj) { AddObj(NULL, topObj, tgifObj); } pos_table = (CmdPtr->undone) ? CmdPtr->pos_before : CmdPtr->pos_after; max_count = (CmdPtr->undone) ? CmdPtr->count_before : CmdPtr->count_after; sel_ptr = topSel; if (CmdPtr->serialized && CmdPtr->undone) { struct SelRec *sel_ptr1; for (sel_ptr1=CmdPtr->top_after; sel_ptr1 != NULL; sel_ptr1=sel_ptr1->next) { sel_ptr->obj = sel_ptr1->obj; UnlinkObj(sel_ptr1->obj); sel_ptr = sel_ptr->next; } } else { if (CmdPtr->serialized && !CmdPtr->undone) { pos_table = actual_pos_before; } pos = count = 0; for (obj_ptr=topObj; obj_ptr!=NULL; obj_ptr=next_obj, pos++) { next_obj = obj_ptr->next; if (pos == pos_table[count]) { count++; sel_ptr->obj = obj_ptr; UnlinkObj(obj_ptr); sel_ptr = sel_ptr->next; if (count == max_count) break; } } } UpdSelBBox(); ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; saved_top_sel = topSel; saved_bot_sel = botSel; topSel = CmdPtr->top_before; botSel = CmdPtr->bot_before; CmdPtr->top_before = saved_top_sel; CmdPtr->bot_before = saved_bot_sel; saved_top_obj = topObj; saved_bot_obj = botObj; curPage->top = topObj = topSel->obj; curPage->bot = botObj = botSel->obj; AdjSplineVs(); AdjCaches(); curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; pos_table = (CmdPtr->undone) ? CmdPtr->pos_after : CmdPtr->pos_before; max_count = (CmdPtr->undone) ? CmdPtr->count_after : CmdPtr->count_before; pos = count = 0; sel_ptr = topSel; if (CmdPtr->serialized && !CmdPtr->undone) { pos_table = actual_pos_before; } for (obj_ptr=topObj; obj_ptr!=NULL; obj_ptr=next_obj, pos++) { if (pos == pos_table[count]) { AddObj(obj_ptr->prev, obj_ptr, sel_ptr->obj); next_obj = obj_ptr; count++; sel_ptr = sel_ptr->next; if (count == max_count) break; } else { next_obj = obj_ptr->next; } } for ( ; sel_ptr != NULL; sel_ptr=sel_ptr->next) { AddObj(botObj, NULL, sel_ptr->obj); } if (CmdPtr->include_tgif_obj) { tgifObj = topObj; UnlinkObj(topObj); sel_ptr = topSel; topSel = topSel->next; if (topSel == NULL) { botSel = NULL; } else { topSel->prev = NULL; } free(sel_ptr); } if (CmdPtr->new_colormap) { if (RefreshColormap(CmdPtr->undone, CmdPtr)) { need_clear_and_redraw = TRUE; } } UpdSelBBox(); if (need_clear_and_redraw) { ClearAndRedrawDrawWindow(); } else { RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } if (HighLightSingleObj && topSel != NULL) { if (!need_clear_and_redraw) { if (!deserializingFile) HighLightForward(); } } else { RemoveAllSel(); } SetFileModified(TRUE); justDupped = FALSE; if (actual_pos_before != NULL) free(actual_pos_before); return TRUE; } static int UndoOrRedoOneToManyCmd(CmdPtr) struct CmdRec *CmdPtr; { struct ObjRec *obj_ptr, *next_obj; struct SelRec *sel_ptr; struct ObjRec *saved_top_obj, *saved_bot_obj; int ltx, lty, rbx, rby, pos, count, *pos_table, max_count; int need_clear_and_redraw=FALSE; int *actual_pos_before=NULL; if (CmdPtr->serialized) { if (CmdPtr->include_tgif_obj) { AddObj(NULL, topObj, tgifObj); } if (CmdPtr->undone) { if (!SetupBeforePointers(CmdPtr, TRUE, &actual_pos_before)) { if (CmdPtr->include_tgif_obj) { UnlinkObj(topObj); } return FALSE; } } if (CmdPtr->include_tgif_obj) { UnlinkObj(topObj); } } if (CmdPtr->include_tgif_obj) { AddObj(NULL, topObj, tgifObj); AddNewSelObj(topObj); } sel_ptr = (CmdPtr->undone) ? CmdPtr->top_before : CmdPtr->top_after; if (CmdPtr->serialized && CmdPtr->undone) { for ( ; sel_ptr != NULL; sel_ptr=sel_ptr->next) { UnlinkObj(sel_ptr->obj); } } else { pos_table = (CmdPtr->undone) ? CmdPtr->pos_before : CmdPtr->pos_after; max_count = (CmdPtr->undone) ? CmdPtr->count_before : CmdPtr->count_after; if (CmdPtr->serialized && CmdPtr->undone) { pos_table = actual_pos_before; } pos = count = 0; for (obj_ptr=topObj; obj_ptr!=NULL; obj_ptr=next_obj, pos++) { next_obj = obj_ptr->next; if (pos == pos_table[count]) { count++; sel_ptr->obj = obj_ptr; UnlinkObj(obj_ptr); sel_ptr = sel_ptr->next; if (count == max_count) break; } } } topSel = (CmdPtr->undone) ? CmdPtr->top_before : CmdPtr->top_after; botSel = (CmdPtr->undone) ? CmdPtr->bot_before : CmdPtr->bot_after; UpdSelBBox(); ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; if (CmdPtr->undone) { CopySel(CmdPtr->top_after, CmdPtr->count_after, &topSel, &botSel); } else { CopySel(CmdPtr->top_before, CmdPtr->count_before, &topSel, &botSel); } LinkJustTheObjects(topSel, botSel); saved_top_obj = topObj; saved_bot_obj = botObj; curPage->top = topObj = topSel->obj; curPage->bot = botObj = botSel->obj; AdjSplineVs(); AdjCaches(); curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; pos_table = (CmdPtr->undone) ? CmdPtr->pos_after : CmdPtr->pos_before; max_count = (CmdPtr->undone) ? CmdPtr->count_after : CmdPtr->count_before; pos = count = 0; sel_ptr = topSel; if (CmdPtr->serialized && CmdPtr->undone) { pos_table = actual_pos_before; } for (obj_ptr=topObj; obj_ptr!=NULL; obj_ptr=next_obj, pos++) { if (pos == pos_table[count]) { AddObj(obj_ptr->prev, obj_ptr, sel_ptr->obj); next_obj = obj_ptr; count++; sel_ptr = sel_ptr->next; if (count == max_count) break; } else { next_obj = obj_ptr->next; } } for ( ; sel_ptr != NULL; sel_ptr=sel_ptr->next) { AddObj(botObj, NULL, sel_ptr->obj); } if (CmdPtr->include_tgif_obj) { tgifObj = topObj; UnlinkObj(topObj); sel_ptr = topSel; topSel = topSel->next; if (topSel == NULL) { botSel = NULL; } else { topSel->prev = NULL; } free(sel_ptr); } if (CmdPtr->new_colormap) { if (RefreshColormap(CmdPtr->undone, CmdPtr)) { need_clear_and_redraw = TRUE; } } UpdSelBBox(); if (need_clear_and_redraw) { ClearAndRedrawDrawWindow(); } else { RedrawAreas(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1), ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); } if (!need_clear_and_redraw) { if (!deserializingFile) HighLightForward(); } SetFileModified(TRUE); justDupped = FALSE; if (actual_pos_before != NULL) free(actual_pos_before); return TRUE; } static void UndoOrRedoGotoPageCmd(CmdPtr) struct CmdRec *CmdPtr; { int new_page_num; new_page_num = (CmdPtr->undone) ? CmdPtr->count_after : CmdPtr->count_before; GotoPageNum(new_page_num); ClearAndRedrawDrawWindow(); ShowPage(); } static void UndoOrRedoWBSlideShow(CmdPtr) struct CmdRec *CmdPtr; { int into_slideshow=CmdPtr->subcmd->detail.slideshow.into_slideshow; if (CmdPtr->undone) { /* executing the command */ if (!inSlideShow && into_slideshow) { EnterSlideShow(); } else if (inSlideShow && !into_slideshow) { LeaveSlideShow(); } } } typedef struct tagUndoRedoRestoreDrawingModeRec { int cur_choice; int text_cursor_shown; int editing_text; int cur_text_modified; int text_orig_x; int text_orig_baseline_y; } UndoRedoRestoreDrawingModeInfo; static void SetUndoRedoRestoreDrawingModeInfo(p_urrdmi, cur_choice, text_cursor_shown, editing_text, cur_text_modified, text_orig_x, text_orig_baseline_y) UndoRedoRestoreDrawingModeInfo *p_urrdmi; int cur_choice, text_cursor_shown, editing_text, cur_text_modified; int text_orig_x, text_orig_baseline_y; { p_urrdmi->cur_choice = cur_choice; p_urrdmi->text_cursor_shown = text_cursor_shown; p_urrdmi->editing_text = editing_text; p_urrdmi->cur_text_modified = cur_text_modified; p_urrdmi->text_orig_x = text_orig_x; p_urrdmi->text_orig_baseline_y = text_orig_baseline_y; } static void UndoRedoRestoreDrawingMode(p_urrdmi) UndoRedoRestoreDrawingModeInfo *p_urrdmi; { if (inHyperSpace || !undoRedoRestoreDrawingMode) return; switch (p_urrdmi->cur_choice) { case NOTHING: break; case DRAWTEXT: if (p_urrdmi->text_cursor_shown) { if (!p_urrdmi->cur_text_modified) { /* just leave things in text mode */ SetCurChoice(p_urrdmi->cur_choice); } else if (p_urrdmi->editing_text) { /* * editing text should be undone, but the cursor should be * placed back to where it starts (in p_urrdmi->cur_text_obj) */ SetCurChoice(p_urrdmi->cur_choice); } else { /* * creating a new text object * should just put the cursor where it starts * (but this may be difficult) */ XEvent ev; memset(&ev, 0, sizeof(XEvent)); ev.type = ButtonPress; ev.xbutton.button = Button1; ev.xbutton.state = 0; ev.xbutton.x = p_urrdmi->text_orig_x; ev.xbutton.y = p_urrdmi->text_orig_baseline_y; SetCurChoice(p_urrdmi->cur_choice); DrawText(&ev); } } else { SetCurChoice(p_urrdmi->cur_choice); } break; default: SetCurChoice(p_urrdmi->cur_choice); break; } } void UndoACmd(CmdPtr, HighLight, nPerformAction) struct CmdRec *CmdPtr; int HighLight, nPerformAction; { struct CmdRec *cmd_ptr; if (topSel != NULL) { HighLightReverse(); RemoveAllSel(); } switch (CmdPtr->type) { case CMD_COMPOSITE: if (CmdPtr->first->type==CMD_MOVE || CmdPtr->first->type==CMD_STRETCH) { for (cmd_ptr=CmdPtr->last; cmd_ptr!=NULL; cmd_ptr=cmd_ptr->prev) { UndoACmd(cmd_ptr, FALSE, nPerformAction); } } else { for (cmd_ptr=CmdPtr->last; cmd_ptr!=NULL; cmd_ptr=cmd_ptr->prev) { UndoACmd(cmd_ptr, TRUE, nPerformAction); } } break; case CMD_NEW: UndoNewCmd(CmdPtr); break; case CMD_DELETE: UndoDeleteCmd(CmdPtr); break; case CMD_MOVE: UndoOrRedoMoveCmd(CmdPtr); break; case CMD_STRETCH: UndoOrRedoReplaceCmd(CmdPtr, TRUE); break; case CMD_REPLACE: UndoOrRedoReplaceCmd(CmdPtr, HighLight); break; case CMD_ONE_TO_MANY: UndoOrRedoOneToManyCmd(CmdPtr); break; case CMD_MANY_TO_ONE: UndoOrRedoOneToManyCmd(CmdPtr); break; case CMD_GOTO_PAGE: UndoOrRedoGotoPageCmd(CmdPtr); break; } CmdPtr->undone = TRUE; } void UndoCmd() { UndoRedoRestoreDrawingModeInfo urrdmi; if (gstWBInfo.do_whiteboard) { MsgBox(TgLoadString(STID_UNDO_IN_WB), TOOL_NAME, INFO_MB); return; } SetUndoRedoRestoreDrawingModeInfo(&urrdmi, curChoice, textCursorShown, editingText, curTextModified, textOrigX, textOrigBaselineY); TieLooseEnds(); SetCurChoice(NOTHING); if (curCmd == NULL) { if (!inHyperSpace && undoRedoRestoreDrawingMode) { SetCurChoice(urrdmi.cur_choice); } MsgBox(TgLoadString(STID_NO_COMMANDS_TO_UNDO), TOOL_NAME, INFO_MB); return; } undoingOrRedoing = TRUE; UndoACmd(curCmd, TRUE, TRUE); curCmd = curCmd->prev; undoingOrRedoing = FALSE; UndoRedoRestoreDrawingMode(&urrdmi); } int RedoACmd(CmdPtr, HighLight, nPerformAction) struct CmdRec *CmdPtr; int HighLight, nPerformAction; { int ok=TRUE; struct CmdRec *cmd_ptr; if (topSel != NULL) { HighLightReverse(); RemoveAllSel(); } switch (CmdPtr->type) { case CMD_COMPOSITE: if (CmdPtr->first->type==CMD_MOVE || CmdPtr->first->type==CMD_STRETCH) { for (cmd_ptr=CmdPtr->first->next; cmd_ptr!=NULL; cmd_ptr=cmd_ptr->next) { if (!RedoACmd(cmd_ptr, FALSE, nPerformAction)) { ok = FALSE; break; } } if (ok) { if (!RedoACmd(CmdPtr->first, TRUE, nPerformAction)) { ok = FALSE; } } } else { for (cmd_ptr=CmdPtr->first; cmd_ptr!=NULL; cmd_ptr=cmd_ptr->next) { if (!RedoACmd(cmd_ptr, TRUE, nPerformAction)) { ok = FALSE; break; } } } break; case CMD_NEW: RedoNewCmd(CmdPtr); break; case CMD_DELETE: ok = RedoDeleteCmd(CmdPtr); break; case CMD_MOVE: ok = UndoOrRedoMoveCmd(CmdPtr); break; case CMD_STRETCH: ok = UndoOrRedoReplaceCmd(CmdPtr, TRUE); break; case CMD_REPLACE: ok = UndoOrRedoReplaceCmd(CmdPtr, HighLight); break; case CMD_ONE_TO_MANY: ok = UndoOrRedoOneToManyCmd(CmdPtr); break; case CMD_MANY_TO_ONE: ok = UndoOrRedoOneToManyCmd(CmdPtr); break; case CMD_GOTO_PAGE: UndoOrRedoGotoPageCmd(CmdPtr); break; case CMD_WB_SLIDESHOW: UndoOrRedoWBSlideShow(CmdPtr); break; } CmdPtr->undone = FALSE; return ok; } void RedoCmd() { UndoRedoRestoreDrawingModeInfo urrdmi; if (gstWBInfo.do_whiteboard) { MsgBox(TgLoadString(STID_REDO_IN_WB), TOOL_NAME, INFO_MB); return; } SetUndoRedoRestoreDrawingModeInfo(&urrdmi, curChoice, textCursorShown, editingText, curTextModified, textOrigX, textOrigBaselineY); TieLooseEnds(); SetCurChoice(NOTHING); if (firstCmd==NULL || (curCmd!=NULL && curCmd->next==NULL)) { if (!inHyperSpace && undoRedoRestoreDrawingMode) { SetCurChoice(urrdmi.cur_choice); } MsgBox(TgLoadString(STID_NO_COMMANDS_TO_REDO), TOOL_NAME, INFO_MB); return; } if (curCmd == NULL) { curCmd = firstCmd; } else { curCmd = curCmd->next; } undoingOrRedoing = TRUE; RedoACmd(curCmd, TRUE, TRUE); undoingOrRedoing = FALSE; UndoRedoRestoreDrawingMode(&urrdmi); } struct CmdStkRec { struct CmdRec *first, *last, *cur; int history_count; struct CmdStkRec *next; }; static struct CmdStkRec *topCompositeCmdStk=NULL; void StartCompositeCmd() { struct CmdStkRec *cmd_stk_ptr; if (historyDepth == 0) return; cmd_stk_ptr = (struct CmdStkRec *)malloc(sizeof(struct CmdStkRec)); if (cmd_stk_ptr == NULL) FailAllocMessage(); memset(cmd_stk_ptr, 0, sizeof(struct CmdStkRec)); cmd_stk_ptr->next = topCompositeCmdStk; cmd_stk_ptr->first = firstCmd; cmd_stk_ptr->last = lastCmd; cmd_stk_ptr->cur = curCmd; cmd_stk_ptr->history_count = historyCount; topCompositeCmdStk = cmd_stk_ptr; firstCmd = lastCmd = curCmd = NULL; historyCount = 0; composingCommand = TRUE; } void EndCompositeCmd() { struct CmdRec *composite_cmd=NULL; int empty=FALSE; if (historyDepth == 0) return; if (firstCmd == NULL) { empty = TRUE; } else { composite_cmd = (struct CmdRec *)malloc(sizeof(struct CmdRec)); if (composite_cmd == NULL) FailAllocMessage(); memset(composite_cmd, 0, sizeof(struct CmdRec)); composite_cmd->type = CMD_COMPOSITE; composite_cmd->include_tgif_obj = FALSE; composite_cmd->first = firstCmd; composite_cmd->last = lastCmd; composite_cmd->top_before = composite_cmd->bot_before = NULL; composite_cmd->top_after = composite_cmd->bot_after = NULL; } if (topCompositeCmdStk != NULL) { struct CmdStkRec *cmd_stk_ptr; firstCmd = topCompositeCmdStk->first; lastCmd = topCompositeCmdStk->last; curCmd = topCompositeCmdStk->cur; historyCount = topCompositeCmdStk->history_count; cmd_stk_ptr = topCompositeCmdStk; topCompositeCmdStk = topCompositeCmdStk->next; free(cmd_stk_ptr); } else { firstCmd = lastCmd = curCmd = NULL; historyCount = 0; } if (!empty) { if (curCmd == NULL) { ClearRedoRecords(firstCmd); } else if (curCmd != lastCmd) { ClearRedoRecords(curCmd); } if (++historyCount == historyDepth) { struct CmdRec *new_first_cmd=firstCmd->next; new_first_cmd->prev = NULL; firstCmd->next = NULL; DeleteARedoRecord(firstCmd, (-1.0), (-1.0)); historyCount--; firstCmd = new_first_cmd; } curCmd = composite_cmd; InsertCmd(lastCmd, NULL, curCmd, &firstCmd, &lastCmd); } composingCommand = (topCompositeCmdStk != NULL); } void RestoreDefaultHistoryDepth() { CleanUpCmds(); historyDepth = defaultHistoryDepth; historyCount = 0; firstCmd = lastCmd = curCmd = NULL; } void DisableUndo() { if (gstWBInfo.do_whiteboard) { /* ``Undo'' is already disabled in whiteboard mode */ return; } CleanUpCmds(); while (composingCommand) { EndCompositeCmd(); CleanUpCmds(); } historyDepth = 0; } void EnableUndo() { if (gstWBInfo.do_whiteboard) { /* ``Redo'' is already disabled in whiteboard mode */ return; } RestoreDefaultHistoryDepth(); } struct SelRec *PrepareStackingInfo(TopSel, BotSel, NumObjs, PreparePhase, ppnStackingPosition, pnStackingCount, pnStackingPositionHasIds) struct SelRec *TopSel, *BotSel; int NumObjs, PreparePhase; int **ppnStackingPosition, *pnStackingCount, *pnStackingPositionHasIds; /* * In whiteboard mode and PreparePhase, *ppnStackingPosition will * be a list of full_ids. Otherwise, it will just be a * list of indices. */ { int pos=0; struct SelRec *sel_ptr=NULL; struct ObjRec *obj_ptr=NULL; if (gstWBInfo.do_whiteboard && PreparePhase) { char **ppsz_full_ids=(char**)malloc(NumObjs*sizeof(char*)); if (ppsz_full_ids == NULL) FailAllocMessage(); memset(ppsz_full_ids, 0, NumObjs*sizeof(char*)); *ppnStackingPosition = NULL; *pnStackingCount = 0; pos = 0; sel_ptr = TopSel; for (obj_ptr=topObj; obj_ptr!=NULL; obj_ptr=obj_ptr->next, pos++) { if (obj_ptr == sel_ptr->obj) { char buf[MAXSTRING]; if (obj_ptr->creator_full_id == NULL) { sprintf(buf, "#%1d:%1d/%s", pos, obj_ptr->id, gszLocalPID); } else { sprintf(buf, "#%1d:%s", pos, obj_ptr->creator_full_id); } ppsz_full_ids[(*pnStackingCount)++] = UtilStrDup(buf); if (ppsz_full_ids[(*pnStackingCount)-1] == NULL) FailAllocMessage(); sel_ptr = sel_ptr->next; if (*pnStackingCount == NumObjs) break; } } *ppnStackingPosition = (int*)ppsz_full_ids; if (pnStackingPositionHasIds != NULL) *pnStackingPositionHasIds = TRUE; } else { *ppnStackingPosition = (int*)malloc(NumObjs*sizeof(int)); if (*ppnStackingPosition == NULL) FailAllocMessage(); memset(*ppnStackingPosition, 0, NumObjs*sizeof(int)); *pnStackingCount = 0; pos = 0; sel_ptr = TopSel; for (obj_ptr=topObj; obj_ptr!=NULL; obj_ptr=obj_ptr->next, pos++) { if (obj_ptr == sel_ptr->obj) { (*ppnStackingPosition)[(*pnStackingCount)++] = pos; sel_ptr = sel_ptr->next; if (*pnStackingCount == NumObjs) break; } } if (pnStackingPositionHasIds != NULL) *pnStackingPositionHasIds = FALSE; } return sel_ptr; } static void PrepareStacking(TopSel, BotSel, NumObjs, PreparePhase) struct SelRec *TopSel, *BotSel; int NumObjs, PreparePhase; { struct SelRec *sel_ptr; stackingPosition = NULL; stackingCount = 0; sel_ptr = PrepareStackingInfo(TopSel, BotSel, NumObjs, PreparePhase, &stackingPosition, &stackingCount, &stackingPositionHasIds); if (sel_ptr != NULL || stackingCount != NumObjs) { sprintf(gszMsgBox, TgLoadString(STID_SELECT_LIST_NOT_SORTED_IN), "PrepareStacking()"); FatalUnexpectedError(gszMsgBox, TgLoadString(STID_UNDO_REDO_MAY_CAUSE_CRASH)); } } void PrepareToRecord(CmdType, TopSel, BotSel, NumObjs) int CmdType, NumObjs; struct SelRec *TopSel, *BotSel; { struct SelRec *sel_ptr=NULL, *to_sel_ptr=NULL; if (historyDepth == 0) return; preparedColormap = (gnInImageProc ? mainColormap : None); topSelBeforeInCmd = botSelBeforeInCmd = NULL; stackingPosition = NULL; stackingCount = 0; stackingPositionHasIds = FALSE; switch (CmdType) { case CMD_NEW: break; case CMD_DELETE: case CMD_MOVE: case CMD_STRETCH: case CMD_REPLACE: PrepareStacking(TopSel, BotSel, NumObjs, TRUE); if (CmdType == CMD_MOVE) { CopySel(TopSel, NumObjs, &topSelBeforeInCmd, &botSelBeforeInCmd); } else { /* stackingPositionHasIds is TRUE if we are doing whiteboard */ DupTheseObjects(TopSel, BotSel, &topSelBeforeInCmd, &botSelBeforeInCmd); for (sel_ptr=TopSel, to_sel_ptr=topSelBeforeInCmd; to_sel_ptr!=NULL; sel_ptr=sel_ptr->next, to_sel_ptr=to_sel_ptr->next) { CopyObjId(sel_ptr->obj, to_sel_ptr->obj); CopyObjLocks(sel_ptr->obj, to_sel_ptr->obj); } } break; case CMD_GOTO_PAGE: stackingCount = NumObjs; break; case CMD_WB_CLEARALL: break; } return; } void FreeAfterSel(CmdPtr) struct CmdRec *CmdPtr; { struct SelRec *sel_ptr=NULL, *next_sel=NULL; for (sel_ptr=CmdPtr->top_after; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } CmdPtr->top_after = CmdPtr->bot_after = NULL; } static void PrepareExtendedSerializationInfoForRecordCmd(SubCmdPtr, TopSel, BotSel, NumObjs, psi) struct SubCmdRec *SubCmdPtr; struct SelRec *TopSel, *BotSel; int NumObjs; SerializationInfo *psi; { psi->subcmd = SubCmdPtr; psi->top_sel = TopSel; psi->bot_sel = BotSel; psi->num_objs = NumObjs; psi->include_tgif_obj = recordCmdIncludeTgifObj; psi->new_colormap = recordCmdUsesNewColormap; psi->logical_clock = gstWBInfo.logical_clock; psi->sender_process_id = gszLocalPID; psi->top_before = topSelBeforeInCmd; psi->bot_before = botSelBeforeInCmd; psi->pos_before = stackingPosition; psi->count_before = stackingCount; psi->pos_before_has_ids = stackingPositionHasIds; } void RecordCmd(CmdType, SubCmdPtr, TopSel, BotSel, NumObjs) int CmdType, NumObjs; struct SubCmdRec *SubCmdPtr; struct SelRec *TopSel, *BotSel; { int logical_clock=0; int wb_send_data_failed=FALSE, plain_wb_data_sz=0; char *psz_wb_data=NULL, *psz_plain_wb_data=NULL; if (gstWBInfo.do_whiteboard) { if (gstWBInfo.dont_serialize || CmdType == CMD_GOTO_PAGE) { /* * One of the important thing that happens in SerializeCmd() * is that the local logical clock got incremented. * If we don't increment the logical clock, we may * create a new command that have the same logical clock * as the one created last time we got here and that's * illegal. Therefore, we must increment the logical clock. */ logical_clock = gstWBInfo.logical_clock++; } else { SerializationInfo si; memset(&si, 0, sizeof(SerializationInfo)); PrepareExtendedSerializationInfoForRecordCmd(SubCmdPtr, TopSel, BotSel, NumObjs, &si); serializingFile = TRUE; psz_plain_wb_data = NULL; plain_wb_data_sz = 0; if ((psz_wb_data=SerializeCmd(CmdType, &si, &logical_clock, &psz_plain_wb_data, &plain_wb_data_sz)) != NULL) { if (!SendWBData(psz_wb_data,logical_clock)) { wb_send_data_failed = TRUE; } } serializingFile = FALSE; } } else { if (historyDepth == 0) return; if (curCmd == NULL) { ClearRedoRecords(firstCmd); } else if (curCmd != lastCmd) { ClearRedoRecords(curCmd); } if (++historyCount == historyDepth && !composingCommand) { struct CmdRec *new_first_cmd=firstCmd->next; new_first_cmd->prev = NULL; firstCmd->next = NULL; DeleteARedoRecord(firstCmd, (-1.0), (-1.0)); historyCount--; firstCmd = new_first_cmd; } } curCmd = (struct CmdRec *)malloc(sizeof(struct CmdRec)); if (curCmd == NULL) FailAllocMessage(); memset(curCmd, 0, sizeof(struct CmdRec)); curCmd->top_before = topSelBeforeInCmd; curCmd->bot_before = botSelBeforeInCmd; if (gstWBInfo.do_whiteboard) { curCmd->serialized = TRUE; } curCmd->pos_before = stackingPosition; curCmd->count_before = stackingCount; curCmd->pos_before_has_ids = stackingPositionHasIds; curCmd->type = CmdType; curCmd->undone = FALSE; curCmd->include_tgif_obj = recordCmdIncludeTgifObj; curCmd->new_colormap = recordCmdUsesNewColormap; if (TopSel != NULL) { CopySel(TopSel, NumObjs, &(curCmd->top_after), &(curCmd->bot_after)); PrepareStacking(TopSel, BotSel, NumObjs, FALSE); curCmd->pos_after = stackingPosition; curCmd->count_after = stackingCount; } else { curCmd->top_after = curCmd->bot_after = NULL; curCmd->pos_after = NULL; curCmd->count_after = 0; } if (gstWBInfo.do_whiteboard) { struct CmdRec *immed_right_cmd=NULL; curCmd->logical_clock = logical_clock; curCmd->sender_process_id = UtilStrDup(gszLocalPID); if (curCmd->sender_process_id == NULL) FailAllocMessage(); if (!wb_send_data_failed) { /* * FindShadowCmdInsertionPoint() examine the logical clock of the new * command and decides where to insert it in the shadow cmd list. */ FindCmdInsertionPoint(curCmd, &immed_right_cmd); if (immed_right_cmd == NULL) { /* append */ CopyAndInsertCmd(FALSE, (psz_plain_wb_data==NULL ? psz_wb_data : psz_plain_wb_data), gstWBInfo.last_shadow_cmd, NULL, curCmd, &gstWBInfo.first_shadow_cmd, &gstWBInfo.last_shadow_cmd); } else { /* insert */ CopyAndInsertCmd(FALSE, (psz_plain_wb_data==NULL ? psz_wb_data : psz_plain_wb_data), immed_right_cmd->prev, immed_right_cmd, curCmd, &gstWBInfo.first_shadow_cmd, &gstWBInfo.last_shadow_cmd); } } immed_right_cmd = NULL; /* * FindCmdInsertionPoint() examine the logical clock of the new command * and decides where to insert it. */ FindCmdInsertionPoint(curCmd, &immed_right_cmd); if (immed_right_cmd == NULL) { /* append */ InsertCmd(gstWBInfo.last_cmd, NULL, curCmd, &gstWBInfo.first_cmd, &gstWBInfo.last_cmd); } else { /* insert */ InsertCmd(immed_right_cmd->prev, immed_right_cmd, curCmd, &gstWBInfo.first_cmd, &gstWBInfo.last_cmd); } if (CmdType == CMD_WB_CLEARALL) { CleanUpObsoletedWBCmds(curCmd); } } else { InsertCmd(lastCmd, NULL, curCmd, &firstCmd, &lastCmd); } switch (CmdType) { case CMD_NEW: break; case CMD_DELETE: break; case CMD_MOVE: curCmd->subcmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (curCmd->subcmd == NULL) FailAllocMessage(); memset(curCmd->subcmd, 0, sizeof(struct SubCmdRec)); curCmd->subcmd->detail.move.dx = SubCmdPtr->detail.move.dx; curCmd->subcmd->detail.move.dy = SubCmdPtr->detail.move.dy; break; case CMD_STRETCH: FreeAfterSel(curCmd); break; case CMD_REPLACE: FreeAfterSel(curCmd); break; case CMD_ONE_TO_MANY: break; case CMD_MANY_TO_ONE: break; case CMD_GOTO_PAGE: curCmd->count_after = NumObjs; break; case CMD_WB_CLEARALL: curCmd->subcmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (curCmd->subcmd == NULL) FailAllocMessage(); memset(curCmd->subcmd, 0, sizeof(struct SubCmdRec)); curCmd->subcmd->detail.clearall.page_style = SubCmdPtr->detail.clearall.page_style; curCmd->subcmd->detail.clearall.print_mag = SubCmdPtr->detail.clearall.print_mag; break; case CMD_CHAT_A_LINE: /* intentionally forget what has been chatted */ break; case CMD_WB_SLIDESHOW: curCmd->subcmd = (struct SubCmdRec *)malloc(sizeof(struct SubCmdRec)); if (curCmd->subcmd == NULL) FailAllocMessage(); memset(curCmd->subcmd, 0, sizeof(struct SubCmdRec)); curCmd->subcmd->detail.slideshow.into_slideshow = SubCmdPtr->detail.slideshow.into_slideshow; break; } if (gstWBInfo.do_whiteboard) { if (wb_send_data_failed) { UndoACmd(curCmd, FALSE, TRUE); UnlinkCmd(curCmd, &gstWBInfo.first_cmd, &gstWBInfo.last_cmd); DeleteARedoRecord(curCmd, (-1.0), (-1.0)); } if (psz_wb_data != NULL) { SerializeFreeBuf(psz_wb_data); } if (psz_plain_wb_data != NULL) { UtilFree(psz_plain_wb_data); } } curCmd = lastCmd; } void AbortPrepareCmd(CmdType) int CmdType; { struct SelRec *sel_ptr=NULL, *next_sel=NULL; if (historyDepth == 0) return; for (sel_ptr=topSelBeforeInCmd; sel_ptr!=NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; switch (CmdType) { case CMD_REPLACE: FreeObj(sel_ptr->obj); break; } free(sel_ptr); } if (stackingPosition != NULL) { if (stackingPositionHasIds) { int i=0; for (i=0; i < stackingCount; i++) { UtilFree((char*)(long)(stackingPosition[i])); } } free(stackingPosition); } stackingPosition = NULL; stackingCount = 0; stackingPositionHasIds = FALSE; topSelBeforeInCmd = botSelBeforeInCmd = NULL; } void RecordNewObjCmd() { if (historyDepth == 0) return; if (topSel==NULL) { struct SelRec *sel_ptr; sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (sel_ptr == NULL) FailAllocMessage(); memset(sel_ptr, 0, sizeof(struct SelRec)); sel_ptr->next = sel_ptr->prev = NULL; sel_ptr->obj = topObj; PrepareToRecord(CMD_NEW, NULL, NULL, 0); RecordCmd(CMD_NEW, NULL, sel_ptr, sel_ptr, 1); free(sel_ptr); } else { PrepareToRecord(CMD_NEW, NULL, NULL, 0); RecordCmd(CMD_NEW, NULL, topSel, botSel, 1); } } void PrepareToReplaceAnObj(BeforeObjPtr) struct ObjRec *BeforeObjPtr; { struct SelRec *sel_ptr; if (historyDepth == 0) return; sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (sel_ptr == NULL) FailAllocMessage(); memset(sel_ptr, 0, sizeof(struct SelRec)); sel_ptr->next = sel_ptr->prev = NULL; sel_ptr->obj = BeforeObjPtr; PrepareToRecord(CMD_REPLACE, sel_ptr, sel_ptr, 1); free(sel_ptr); } void RecordReplaceAnObj(AfterObjPtr) struct ObjRec *AfterObjPtr; { struct SelRec *sel_ptr; if (historyDepth == 0) return; sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (sel_ptr == NULL) FailAllocMessage(); memset(sel_ptr, 0, sizeof(struct SelRec)); sel_ptr->next = sel_ptr->prev = NULL; sel_ptr->obj = AfterObjPtr; RecordCmd(CMD_REPLACE, NULL, sel_ptr, sel_ptr, 1); free(sel_ptr); } void ChangeReplaceOneCmdToDeleteCmd() { RecordCmd(CMD_DELETE, NULL, NULL, NULL, 0); } void RecordWBClearAll() { if (gstWBInfo.do_whiteboard) { struct SubCmdRec subcmd; memset(&subcmd, 0, sizeof(struct SubCmdRec)); subcmd.detail.clearall.page_style = pageStyle; subcmd.detail.clearall.print_mag = printMag; PrepareToRecord(CMD_WB_CLEARALL, NULL, NULL, 0); RecordCmd(CMD_WB_CLEARALL, &subcmd, NULL, NULL, 0); } } void RecordWBSlideShow(into_slideshow) int into_slideshow; { if (gstWBInfo.do_whiteboard) { if (pageLayoutMode == PAGE_STACK && firstPage != lastPage) { struct SubCmdRec subcmd; memset(&subcmd, 0, sizeof(struct SubCmdRec)); subcmd.detail.slideshow.into_slideshow = into_slideshow; PrepareToRecord(CMD_WB_SLIDESHOW, NULL, NULL, 0); RecordCmd(CMD_WB_SLIDESHOW, &subcmd, NULL, NULL, 0); } } } void RecordWBChatALine(pSubCmdPtr) struct SubCmdRec *pSubCmdPtr; { if (gstWBInfo.do_whiteboard) { PrepareToRecord(CMD_CHAT_A_LINE, NULL, NULL, 0); RecordCmd(CMD_CHAT_A_LINE, pSubCmdPtr, NULL, NULL, 0); } } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/ps.e���������������������������������������������������������������������������������0000644�0000764�0000764�00000004530�11602233312�013556� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/ps.e,v 1.6 2011/05/16 16:21:59 william Exp $ */ #ifndef _PS_E_ #define _PS_E_ extern int preDumpSetup; extern int needsTgifOrigCTM; extern int psUseShortHand; extern char **gPsCmd; #ifdef _INCLUDE_FROM_PS_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_PS_C_*/ extern void PSUsePSAdobe ARGS_DECL((void)); extern void PSUseMinRadius ARGS_DECL((void)); extern void PSUseEllipse ARGS_DECL((void)); extern void PSUseArrow ARGS_DECL((void)); extern void PSUseArc ARGS_DECL((void)); extern void PSUseBWPattern ARGS_DECL((void)); extern void PSUseColorImage ARGS_DECL((void)); extern void PSUseColorPattern ARGS_DECL((void)); extern void PSUseCenterText ARGS_DECL((void)); extern void PSUseRightText ARGS_DECL((void)); extern void PSUseMiniLines ARGS_DECL((void)); extern void PSUseReencode ARGS_DECL((char *FontName)); extern void PSDontUseShortHand ARGS_DECL((void)); extern void PSUseShortHand ARGS_DECL((void)); #ifdef _PS_USE_EUC_FONT extern void PSUseEucFont ARGS_DECL((void)); #endif /* _PS_USE_EUC_FONT */ extern void ResetPSInfo ARGS_DECL((void)); extern void DoneResetPSInfo ARGS_DECL((void)); extern void DumpPSMacro ARGS_DECL((FILE *)); extern int ParsePsAdobeString ARGS_DECL((char *Str, int *UsePSAdobeStr, char *AdobeStr, char *EPSFStr)); extern void CleanUpPS ARGS_DECL((void)); extern void InitPS ARGS_DECL((void)); #ifdef _INCLUDE_FROM_PS_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_PS_C_*/ #endif /*_PS_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Tgif.tmpl-irix�����������������������������������������������������������������������0000644�0000764�0000764�00000005105�11602233313�015526� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-irix,v 1.12 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif OPTIMIZER = -O2 -Olimit 1500 XCOMM for IRIX 5.3 OPTIMIZER = -O2 -OPT:Olimit=1500 XCOMM for IRIX 6.2 EXTRA_LDOPTIONS = PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/lib/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_NO_IDNLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) XCOMM SYS_LIBRARIES = -ldl -lm -lz SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM IRIX 5.3 XCOMM XCOMM IRIX 6.2 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/convxim.e����������������������������������������������������������������������������0000644�0000764�0000764�00000004525�11602233311�014622� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Yoichiro Ueno (ueno@cs.titech.ac.jp) * * Copyright (C) 1991, 1992, Yoichiro Ueno. * * Permission to use, copy, modify, and distribute this software and * its documentation for any purpose is hereby granted by the Author without * fee, provided that the above copyright notice appear in all copies and * that both the copyright notice and this permission notice appear in * supporting documentation, and that the name of the Author not be used * in advertising or publicity pertaining to distribution of the software * without specific, written prior permission. The Author makes no * representations about the suitability of this software for any purpose. * It is provided "as is" without express or implied warranty. * * THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO * EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR * OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR * PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/convxim.e,v 1.1 2004/06/18 23:19:08 william Exp $ */ #ifndef _NO_XIM #ifndef _CONVXIM_E_ #define _CONVXIM_E_ #define COMPOSE_STATUS 0 #define MB_STATUS 1 typedef struct _XIMStatus { char valid; XComposeStatus status; Status mb_status; } XIMStatus; extern char ximConvModifiers[]; extern char ximConvLang[]; #ifdef _INCLUDE_FROM_CONVXIM_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_CONVXIM_C_*/ extern void XIMSetICFocus ARGS_DECL((Display*, Window)); extern void XIMNextEvent ARGS_DECL((Display*, Window, XEvent*)); extern int XIMLookupString ARGS_DECL((XKeyEvent*, char*, int, KeySym*, XIMStatus*)); extern void XIMUnsetICFocus ARGS_DECL((Window)); extern void XIMSetConvOverSpot ARGS_DECL((Bool)); extern void XIMTellCursorPosition ARGS_DECL((Display*, Window, int, int)); extern void XIMCleanUp ARGS_DECL((void)); extern int XIMInit ARGS_DECL((void)); #ifdef _INCLUDE_FROM_CONVXIM_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_CONVXIM_C_*/ #endif /*_CONVXIM_E_*/ #endif /* ~_NO_XIM */ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgificon.xpm�������������������������������������������������������������������������0000644�0000764�0000764�00000014327�11602233313�015324� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#define tgificon1_format 1 #define tgificon1_width 53 #define tgificon1_height 53 #define tgificon1_ncolors 13 #define tgificon1_chars_per_pixel 2 static char *tgificon1_colors[] = { "``", "None", "a1", "White", "a2", "#00000000c000", "a3", "yellow", "a4", "#820782070000", "a5", "#ffff00000000", "a6", "#3cf3fbee34d2", "a7", "#3cf3fbed34d3", "a8", "#ffffa6990000", "a9", "#ffff0000fffe", "b0", "black", "b1", "#fffe0000fffe", "b2", "#fffe00000000" }; static char *tgificon1_pixels[] = { "````````````````````````````````````````````````a2a2a2````````````````````````````````````````````````````", "``````````````````````````````````````````````a2a2a2a2a2``````````````````````````````````````````````````", "````````````````````````````````````````````a2a2a2a2a2a2a2````````````````````````````````````````````````", "``````````````````````````````````````````a2a2a2a2a2a2a2a2a2``````````````````````````````````````````````", "````````````````````````````````````````a2a2a2a2a2a3a2a2a2a2a2````````````````````````````````````````````", "``````````````````````````````````````a2a2a2a2a2a3a3a3a2a2a2a2a2``````````````````````````````````````````", "````````````````````````````````````a2a2a2a2a2a3a3a3a3a3a2a2a2a2a2````````````````````````````````````````", "``````````````````````````````````a2a2a2a2a2a3a3a3a3a3a3a3a2a2a2a2a2``````````````````````````````````````", "````````````````````````````````a2a2a2a2a2a3a3a3a3a3a3a3a3a3a2a2a2a2a2````````````````````````````````````", "``````````````````````````````a2a2a2a2a2a3a3a3a3a3a3a3a3a3a3a3a2a2a2a2a2``````````````````````````````````", "````````````````````````````a2a2a2a2a2a3a3a3a3a3a3a3a3a3a3a3a3a3a2a2a2a2a2````````````````````````````````", "``````````````````````````a2a2a2a2a2a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a2a2a2a2a2``````````````````````````````", "````````````````````````a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2````````````````````````````", "``````````````````````a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2``````````````````````````", "````````````````````a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2````````````````````````", "``````````````````a2a2a2a2a2a2a3a3a3a3a3a3a3a3a3a2a2a2a2a2a2a3a3a3a3a3a3a3a2a2a2a2a2``````````````````````", "````````````````a2a2a2a2a2a2a2a3a3a3a3a3a3a3a3a3a2a2a2a2a2a2a2a3a3a3a3a3a3a3a2a2a2a2a2````````````````````", "``````````````a2a2a2a2a2a2a2a2a3a3a3a3a3a3a3a3a3a2a2a2a2a2a2a2a2a3a3a3a3a3a3a3a2a2a2a2a2``````````````````", "````````````a2a2a2a2a2a3a2a2a2a3a3a3a3a3a3a3a3a3a2a2a2a3a2a2a2a2a2a3a3a3a3a3a3a3a2a2a2a2a2````````````````", "``````````a2a2a2a2a2a3a3a2a2a2a3a3a3a3a3a3a3a3a3a2a2a2a3a3a2a2a2a2a2a3a3a3a3a3a3a3a2a2a2a2a2``````````````", "````````a2a2a2a2a2a3a3a3a2a2a2a3a3a3a3a3a3a3a3a3a2a2a2a3a3a3a2a2a2a2a2a3a3a3a3a3a3a3a2a2a2a2a2````````````", "``````a2a2a2a2a2a3a3a3a3a2a2a2a3a3a3a3a3a3a3a3a3a2a2a2a3a3a3a3a2a2a2a2a2a3a3a3a3a3a3a3a2a2a2a2a2``````````", "````a2a2a2a2a2a3a3a3a3a3a2a2a2a3a3a3a3a3a3a3a3a3a2a2a2a3a3a3a3a3a2a2a2a2a2a3a3a3a3a3a3a3a2a2a2a2a2````````", "``a2a2a2a2a2a3a3a3a3a3a3a2a2a2a3a3a3a3a3a3a3a3a3a2a2a2a3a3a3a3a3a3a2a2a2a2a2a3a3a3a3a3a3a3a2a2a2a2a2``````", "a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2````", "a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a4``", "a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a2a4a4", "``a2a2a2a2a2a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a2a2a2a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a2a2a2a2a2a4a4a4", "````a2a2a2a2a2a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a2a2a2a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a3a2a2a2a2a2a4a4a4a4", "``````a2a2a2a2a2a3a3a5a5a5a5a5a5a5a5a3a3a3a3a6a6a6a6a2a3a3a3a3a8a8a3a3a3a9a9a9a9a9a9a9a2a2a2a2a2a4a4a4a4``", "````````a2a2a2a2a2a5a5a5a5a5a5a5a5b0b0a3a6a6a6a6a6a6a6a3a3a3a3a8a8b0a3a3a9a9a9a9a9a9a9b0a2a2a2a4a4a4a4````", "``````````a2a2a2a2a2b0b0a5a5b0b0b0b0a3a6a6a6b0b0b0a6a6a6a3a3a3a8a8b0a3a3a9a9b0b0b0b0b0b0a2a2a4a4a4a4``````", "````````````a2a2a2a2a2a3a5a5b0a3a3a3a3a6a6b0b0a3a2a2a6a6b0a3a8a8a8b0a3a9a9a9b0a3a2a2a2a2a2a4a4a4a4````````", "``````````````a2a2a2a2a2a5a5b0a3a3a3a6a6b0b0a3a3a2a2a2b0b0a3a8a8b0b0a3a9a9a9a9a9a9a9a2a2a4a4a4a4``````````", "````````````````a2a2a2a5a5b0b0a3a3a3a6a6b0a3a3a6a6a6a6a6a3a3a8a8b0a3a3a9a9a9a9a9a9a9b0a4a4a4a4````````````", "``````````````````a2a2a5a5b0a3a3a3a3a6a6b0a3a3a6a6a6a6b0b0a3a8a8b0a3a3a9a9b0b0b0b0b0b0a4a4a4``````````````", "````````````````````a2a5a5b0a2a3a3a3a6a6b0a3a3a3b0a6a6b0a3a8a8a8b0a3a3a9a9b0a2a2a2a4a4a4a4````````````````", "````````````````````a5a5b0b0a2a2a3a3a6a6a6a3a3a3a6a6a6b0a3a8a8b0b0a3a9a9a9b0a2a2a4a4a4a4``````````````````", "````````````````````a5a5b0a2a2a2a2a3a3a6a6a6a6a6a6a6a6b0a3a8a8b0a3a3a9a9b0b0a2a4a4a4a4````````````````````", "````````````````````a5a5b0a2a2a2a2a2a3a3a6a6a6a6b0a6a6b0a3a8a8b0a3a2a9a9b0a2a4a4a4a4``````````````````````", "``````````````````````b0b0``a2a2a2a2a2a3a3b0b0b0b0a2b0b0a3a3b0b0a2a2a2b0b0a4a4a4a4````````````````````````", "``````````````````````````````a2a2a2a2a2a3a3a3a3a2a2a2a3a3a3a3a2a2a2a2a2a4a4a4a4``````````````````````````", "````````````````````````````````a2a2a2a2a2a3a3a3a2a2a2a3a3a3a2a2a2a2a2a4a4a4a4````````````````````````````", "``````````````````````````````````a2a2a2a2a2a3a3a2a2a2a3a3a2a2a2a2a2a4a4a4a4``````````````````````````````", "````````````````````````````````````a2a2a2a2a2a3a2a2a2a3a2a2a2a2a2a4a4a4a4````````````````````````````````", "``````````````````````````````````````a2a2a2a2a2a2a2a2a2a2a2a2a2a4a4a4a4``````````````````````````````````", "````````````````````````````````````````a2a2a2a2a2a2a2a2a2a2a2a4a4a4a4````````````````````````````````````", "``````````````````````````````````````````a2a2a2a2a2a2a2a2a2a4a4a4a4``````````````````````````````````````", "````````````````````````````````````````````a2a2a2a2a2a2a2a4a4a4a4````````````````````````````````````````", "``````````````````````````````````````````````a2a2a2a2a2a4a4a4a4``````````````````````````````````````````", "````````````````````````````````````````````````a2a2a2a4a4a4a4````````````````````````````````````````````", "``````````````````````````````````````````````````a4a4a4a4a4``````````````````````````````````````````````", "````````````````````````````````````````````````````a4a4a4````````````````````````````````````````````````" }; ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Makefile.am��������������������������������������������������������������������������0000644�0000764�0000764�00000004653�11602233312�015030� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# # @(#)$Header: /mm2/home/cvs/bc-src/tgif/Makefile.am,v 1.21 2011/01/18 05:17:27 william Exp $ # AUTOMAKE_OPTIONS = foreign TGIFDIR = $(libdir)/X11/tgif CFLAGS=-DVERSION=\"$(VERSION)\" -DPROG="\"$(PACKAGE)\"" \ -Wall -I/usr/X11R6/include -DHAVE_CONFIG_H -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 -DLOCALEDIR=\"/usr/share/locale\" -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" -DEPSF_FILE_EXT=\"eps\" -DPS_FILE_EXT=\"ps\" -DXBM_FILE_EXT=\"xbm\" -DXPM_FILE_EXT=\"xpm\" -DOBJ_FILE_EXT=\"obj\" -DSYM_FILE_EXT=\"sym\" -DTEXT_FILE_EXT=\"txt\" -DPIN_FILE_EXT=\"pin\" -DNETLIST_FILE_EXT=\"net\" -DCOMP_FILE_EXT=\"cmp\" -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" -DDEFATTRGROUP=\"TANGRAM-II:Declaration:Events:Messages:Rewards:Initialization:Watches\" -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN -DUSE_XT_INITIALIZE -D_NO_LOCALE_SUPPORT bin_PROGRAMS = tgif tgif_SOURCES = \ align.c animate.c arc.c attr.c auxtext.c \ box.c button.c \ chat.c chinput.c choice.c choose.c cli_xcin.c \ convkinput.c convxim.c cmd.c color.c cutpaste.c \ cursor.c \ dialog.c drawing.c dup.c \ edit.c eps.c exec.c expr.c \ file.c font.c ftp.c \ grid.c group.c \ hash.c help.c http.c \ imgproc.c import.c ini.c inmethod.c \ list.c \ mainloop.c mainmenu.c mark.c markup.c menu.c \ menuinfo.c miniline.c move.c msg.c \ names.c navigate.c nkf.c \ obj.c oval.c \ page.c pattern.c pin.c pngtrans.c poly.c polygon.c ps.c \ raster.c rcbox.c rect.c remote.c rm_intrf.c ruler.c \ scroll.c select.c setup.c shape.c shortcut.c \ special.c spline.c stk.c stream.c stretch.c \ strtbl.c \ tangram2.c tdgtbase.c tdgtbmpl.c tdgtbrow.c tdgtbtn.c tdgtdraw.c \ tdgtlist.c tdgtmsg.c tdgtsedt.c tgif_dbg.c tgcwheel.c \ tgcwdl.c tginssym.c tgisdl.c tgtwb5.c tgif.c tgtwb5dl.c \ tgtwb5xl.c tidget.c tcp.c text.c \ util.c \ version.c vms_comp.c \ wb.c wb1.c wb2.c wb3.c wb_buff.c wb_mcast.c \ wb_seg.c \ xbitmap.c xpixmap.c xprtfltr.c \ z_intrf.c tgif_LDADD = -L/usr/X11R6/lib -lXext -lX11 -lXt -lSM -lICE -lXmu -lm -lz tgifdir = $(TGIFDIR) tgif_DATA = tgif.Xdefaults tgificon.eps tgificon.obj tgificon.xbm tgificon.xpm tgif.gif tangram.sym eq4.sym eq4-2x.sym eq4-ps2epsi.sym eq4-epstool.sym eq4xpm.sym eq4-lyx-ps2epsi.sym eq4xpm-land.sym eq4png.sym eq4jpg.sym eq4-2x-jpg.sym eq4-2x-nowin-jpg.sym keys.obj Copyright License �������������������������������������������������������������������������������������tgif-QPL-4.2.5/eq4jpg.sym���������������������������������������������������������������������������0000644�0000764�0000764�00000056210�11602233311�014713� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.46 state(0,37,100.000,0,64,0,32,1,3,1,1,0,0,1,0,1,0,'Courier',0,57600,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/eq4jpg.sym,v 1.1 2009/11/01 00:13:26 william Exp $ % %W% % unit("1 pixel/pixel"). shapeshadow(3,3). color_info(15,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). slideshow_info('#0000b2',-50,-130). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). dont_reencode("UtopiaFS:FFDingbests:ZapfDingbats"). ps_font_aliases([ "UtopiaFS-Regular=Utopia-Regular", "UtopiaFS-Bold=Utopia-Bold", "UtopiaFS-Italic=Utopia-Italic", "UtopiaFS-BoldItalic=Utopia-BoldItalic" ]). objshadow_info('#c0c0c0',2,2). rotate_pivot(0,0,0,0). spline_tightness(1). page(1,"LaTeX equation symbol (uses ps2epsi).",1,''). group([ text('#0000ff',192,229,22,0,1,355,265,1059,11,2,0,-1,0,0,2,355,265,-1,1,"",0,0,0,0,240,'',[ minilines(355,265,-1,1,0,-1,0,[ mini_line(295,11,2,0,1,0,[ str_block(0,79,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,79,11,2,0,-2,0,0,0,0,0, "Make sure that ")]), str_block(0,24,11,2,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,57600,24,11,2,0,1,0,0,0,0,0, "latex")]), str_block(0,6,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,6,11,2,0,-2,0,0,0,0,0, ", ")]), str_block(0,27,11,2,0,0,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,57600,27,11,2,0,0,0,0,0,0,0, "dvips")]), str_block(0,6,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,6,11,2,0,-2,0,0,0,0,0, ", ")]), str_block(0,113,11,2,0,-2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,57600,113,11,2,0,-2,0,0,0,0,0, "convert (ImageMagic) ")]), str_block(0,40,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,40,11,2,0,-2,0,0,0,0,0, "and the ")]) ]), mini_line(167,11,2,-1,0,0,[ str_block(0,40,11,2,0,-2,0,0,0,[ str_seg('blue','Helvetica-BoldOblique',3,57600,40,11,2,0,-2,0,0,0,0,0, "netpbm ")]), str_block(0,100,11,2,-1,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,100,11,2,-1,-2,0,0,0,0,0, "package are in your ")]), str_block(0,24,9,2,-1,-1,0,0,0,[ str_seg('#ff00ff','Courier-Bold',1,57600,24,9,2,-1,-1,0,0,0,0,0, "PATH")]), str_block(0,3,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,3,11,2,0,-1,0,0,0,0,0, ".")]) ]), mini_line(321,11,2,0,0,0,[ str_block(0,321,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,321,11,2,0,-2,0,0,0,0,0, "After you instantiate this symbol, you can change the resolution ")]) ]), mini_line(290,11,2,0,0,0,[ str_block(0,42,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,42,9,2,0,-1,0,0,0,0,0, "density")]), str_block(0,3,11,2,0,-2,0,0,0,[ str_seg('green','Helvetica-BoldOblique',3,57600,3,11,2,0,-2,0,0,0,0,0, " ")]), str_block(0,40,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,40,11,2,0,-2,0,0,0,0,0, "and the ")]), str_block(0,48,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,48,9,2,0,-1,0,0,0,0,0, "geometry")]), str_block(0,3,11,2,0,-2,0,0,0,[ str_seg('green','Helvetica-BoldOblique',3,57600,3,11,2,0,-2,0,0,0,0,0, " ")]), str_block(0,154,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,154,11,2,0,-1,0,0,0,0,0, "in order to enhance the quality.")]) ]), mini_line(319,11,2,0,0,0,[ str_block(0,319,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,319,11,2,0,-2,0,0,0,0,0, "In addition, you can set the number of colors used in the image. ")]) ]), mini_line(313,11,2,0,0,0,[ str_block(0,55,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,55,11,2,0,-2,0,0,0,0,0, "To do this, ")]), str_block(0,50,11,2,0,0,0,0,0,[ str_seg('magenta','Helvetica-BoldOblique',3,57600,50,11,2,0,0,0,0,0,0,0, "right-click")]), str_block(0,208,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,208,11,2,0,0,0,0,0,0,0, " on the symbol and choose \"Edit Attribute")]) ]), mini_line(329,11,2,0,0,0,[ str_block(0,159,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,159,11,2,0,-2,0,0,0,0,0, "in Editor\". Ther you can find the ")]), str_block(0,48,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,48,9,2,0,-1,0,0,0,0,0, "density=")]), str_block(0,25,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,25,11,2,0,-2,0,0,0,0,0, ", the ")]), str_block(0,54,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,54,9,2,0,-1,0,0,0,0,0, "geometry=")]), str_block(0,43,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,43,11,2,0,-2,0,0,0,0,0, " and the ")]) ]), mini_line(355,11,2,0,0,0,[ str_block(0,48,9,2,0,-5,0,0,0,[ str_seg('blue','Courier',0,57600,48,9,2,0,-5,0,0,0,0,0, "colors= ")]), str_block(0,307,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,307,11,2,0,0,0,0,0,0,0, "Attributes. The default values already give quite a reasonable")]) ]), mini_line(326,11,2,0,1,0,[ str_block(0,326,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,326,11,2,0,1,0,0,0,0,0, "quality of the equation image. Under this menue, you can also find")]) ]), mini_line(316,11,2,0,0,0,[ str_block(0,19,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,19,11,2,0,-2,0,0,0,0,0, "the ")]), str_block(0,18,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,18,9,2,0,-1,0,0,0,0,0, "eq=")]), str_block(0,279,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,279,11,2,0,-1,0,0,0,0,0, " Attribute, where you can edit the equation in TeX-style.")]) ]), mini_line(328,11,2,0,1,0,[ str_block(0,129,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,129,11,2,0,-2,0,0,0,0,0, "As soon as the symbol is ")]), str_block(0,60,11,2,0,0,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,57600,60,11,2,0,0,0,0,0,0,0, "double-click")]), str_block(0,139,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,139,11,2,0,1,0,0,0,0,0, "ed for the first time, you will")]) ]), mini_line(329,11,2,0,0,0,[ str_block(0,329,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,329,11,2,0,0,0,0,0,0,0, "be prompted for an equation name, which you just can answer with")]) ]), mini_line(339,11,2,0,0,0,[ str_block(0,37,11,2,0,-1,0,0,0,[ str_seg('magenta','Helvetica-BoldOblique',3,57600,37,11,2,0,-1,0,0,0,0,0, "ENTER,")]), str_block(0,302,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,302,11,2,0,0,0,0,0,0,0, " if you don't need to refer to the equation. The equation name")]) ]), mini_line(324,11,2,0,0,0,[ str_block(0,324,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,324,11,2,0,0,0,0,0,0,0, "will then be a unique number. After this the LaTeX scripts will run")]) ]), mini_line(171,11,2,0,0,0,[ str_block(0,171,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,171,11,2,0,-2,0,0,0,0,0, "as well as the image conversions. ")]) ]), mini_line(347,11,2,0,1,0,[ str_block(0,28,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,28,11,2,0,-2,0,0,0,0,0, "If the ")]), str_block(0,30,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,30,9,2,0,-1,0,0,0,0,0, "proc=")]), str_block(0,94,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,94,11,2,0,-2,0,0,0,0,0, " attribute contains ")]), str_block(0,18,9,2,0,0,0,0,0,[ str_seg('blue','Courier',0,57600,18,9,2,0,0,0,0,0,0,0, "cmd")]), str_block(0,177,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,177,11,2,0,1,0,0,0,0,0, ", then the image will directly appear")]) ]), mini_line(327,11,2,-1,0,0,[ str_block(0,98,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,98,11,2,0,-2,0,0,0,0,0, "in tgif. If it contains ")]), str_block(0,24,9,2,0,0,0,0,0,[ str_seg('blue','Courier',0,57600,24,9,2,0,0,0,0,0,0,0, "ecmd")]), str_block(0,31,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,31,11,2,0,-2,0,0,0,0,0, ", then ")]), str_block(0,11,11,2,-1,0,0,0,0,[ str_seg('blue','Helvetica-BoldOblique',3,57600,11,11,2,-1,0,0,0,0,0,0, "xv")]), str_block(0,163,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,163,11,2,0,0,0,0,0,0,0, " will be launched before inclusion")]) ]), mini_line(348,11,2,0,0,0,[ str_block(0,348,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,348,11,2,0,0,0,0,0,0,0, "of the equation image. You then have the possibility to manipulate the")]) ]), mini_line(337,11,2,0,1,0,[ str_block(0,337,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,337,11,2,0,1,0,0,0,0,0, "image. NOTE that you have to save the image then as XPM and quit")]) ]), mini_line(189,11,2,-1,0,0,[ str_block(0,11,11,2,-1,0,0,0,0,[ str_seg('blue','Helvetica-BoldOblique',3,57600,11,11,2,-1,0,0,0,0,0,0, "xv")]), str_block(0,178,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,178,11,2,0,-1,0,0,0,0,0, " in order to include the image in tgif.")]) ]), mini_line(316,11,2,0,1,0,[ str_block(0,21,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,21,11,2,0,-2,0,0,0,0,0, "The ")]), str_block(0,18,9,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,57600,18,9,2,0,-1,0,0,0,0,0, "eq=")]), str_block(0,277,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,277,11,2,0,1,0,0,0,0,0, "attribute visible in the beginning is hidden after the first")]) ]), mini_line(60,11,2,0,0,0,[ str_block(0,60,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,60,11,2,0,-1,0,0,0,0,0, "compilation.")]) ]) ])]), text('#0000ff',192,194,3,0,1,257,37,643,11,2,0,-1,0,0,2,257,37,0,0,"",0,0,0,0,205,'',[ minilines(257,37,0,0,0,-1,0,[ mini_line(221,11,2,0,0,0,[ str_block(0,136,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,136,11,2,0,-2,0,0,0,0,0, "Make sure you are running ")]), str_block(0,36,11,2,0,0,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,57600,36,11,2,0,0,0,0,0,0,0, "tgif-4.2")]), str_block(0,49,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,49,11,2,0,-1,0,0,0,0,0, " or newer.")]) ]), mini_line(257,11,2,0,0,0,[ str_block(0,257,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,257,11,2,0,0,0,0,0,0,0, "You can find out what version of tgif you are running")]) ]), mini_line(219,11,2,0,0,0,[ str_block(0,219,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,219,11,2,0,-1,0,0,0,0,0, "by selecting About() from the Special menu.")]) ]) ])]), text('#0000ff',160,229,1,0,1,16,13,848,11,2,0,0,0,0,2,16,13,0,0,"",0,0,0,0,240,'',[ minilines(16,13,0,0,0,0,0,[ mini_line(16,11,2,0,0,0,[ str_block(0,16,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,16,11,2,0,0,0,0,0,0,0, "(2)")]) ]) ])]), text('#0000ff',160,194,1,0,1,16,13,863,11,2,0,0,0,0,2,16,13,0,0,"",0,0,0,0,205,'',[ minilines(16,13,0,0,0,0,0,[ mini_line(16,11,2,0,0,0,[ str_block(0,16,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,16,11,2,0,0,0,0,0,0,0, "(1)")]) ]) ])]) ], 13509,0,0,[ ]). sym([ polygon('yellow','',5,[ 64,150,128,150,128,134,64,134,64,150],0,1,0,0,212,0,0,0,0,0,'1',0, "00",[ ]) ], 593,0,0,[ attr("ecmd=", "", 0, 1, 0, text('blue',160,449,6,0,1,1215,96,14196,13,3,0,0,0,0,2,1215,96,0,0,"",0,0,0,0,462,'',[ minilines(1215,96,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "ecmd=")]) ]), mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-4,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(459,13,3,0,0,0,[ str_block(0,459,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,459,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e latex $(file_name);")]) ]), mini_line(711,13,3,0,0,0,[ str_block(0,711,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,711,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e dvips -E -n 1 -o $(file_name).eps $(file_name);")]) ]), mini_line(1215,13,3,0,0,0,[ str_block(0,1215,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1215,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e convert -geometry $(geometry) -density $(density) -colors $(colors) $(file_name).eps $(file_name).ppm;")]) ]), mini_line(369,13,3,0,0,0,[ str_block(0,369,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,369,13,3,0,-4,0,0,0,0,0, " xv -geometry +50+50 $(file_name).ppm;")]) ]) ])])), attr("eq=", "", 1, 1, 0, text('blue',160,98,5,0,1,135,80,25,13,3,0,0,0,0,2,135,80,0,0,"",0,0,0,0,111,'',[ minilines(135,80,0,0,0,0,0,[ mini_line(27,13,3,0,0,0,[ str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, "eq=")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "\\LARGE")]) ]), mini_line(18,13,3,0,0,0,[ str_block(0,18,13,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,18,13,3,0,-3,0,0,0,0,0, "\\[")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,135,13,3,0,-2,0,0,0,0,0, " E\\,=\\,M\\,C^2")]) ]), mini_line(18,13,3,0,0,0,[ str_block(0,18,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,18,13,3,0,-4,0,0,0,0,0, "\\]")]) ]) ])])), attr("file_name=", "", 0, 1, 0, text('blue',161,939,1,0,1,90,16,29,13,3,0,0,0,0,2,90,16,0,0,"",0,0,0,0,952,'',[ minilines(90,16,0,0,0,0,0,[ mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, "file_name=")]) ]) ])])), attr("cleanup=", "", 0, 1, 0, text('blue',162,644,4,0,1,675,64,14750,13,3,0,0,0,0,2,675,64,0,0,"",0,0,0,0,657,'',[ minilines(675,64,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "cleanup=")]) ]), mini_line(540,13,3,0,0,0,[ str_block(0,540,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,540,13,3,0,-2,0,0,0,0,0, " rm -f $(file_name).tex $(file_name).aux $(file_name).dvi")]) ]), mini_line(513,13,3,0,0,0,[ str_block(0,513,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,513,13,3,0,-2,0,0,0,0,0, " $(file_name).log $(file_name).ps $(file_name).eps")]) ]), mini_line(675,13,3,0,0,0,[ str_block(0,675,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,675,13,3,0,-1,0,0,0,0,0, " $(file_name).ppm $(file_name).xpm $(file_name).gif $(file_name).jpg")]) ]) ])])), attr("exec=", "", 0, 1, 0, text('blue',161,179,14,0,1,477,224,14710,13,3,0,0,0,0,2,477,224,0,0,"",0,0,0,0,192,'',[ minilines(477,224,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "exec=")]) ]), mini_line(378,13,3,0,0,0,[ str_block(0,378,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,378,13,3,0,-4,0,0,0,0,0, " mktemp(\"/tmp/TgifXXXXXX\",\"file_name\");")]) ]), mini_line(306,13,3,0,0,0,[ str_block(0,306,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,306,13,3,0,-4,0,0,0,0,0, " strlen(name_assigned,$(name));")]) ]), mini_line(405,13,3,0,0,0,[ str_block(0,405,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,405,13,3,0,-4,0,0,0,0,0, " if($(name_assigned)==0,assign_name,NULL);")]) ]), mini_line(306,13,3,0,0,0,[ str_block(0,306,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,306,13,3,0,-4,0,0,0,0,0, " strlen(name_assigned,$(name));")]) ]), mini_line(468,13,3,0,0,0,[ str_block(0,468,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,468,13,3,0,-4,0,0,0,0,0, " if($(name_assigned)==0,assign_random_name,NULL);")]) ]), mini_line(468,13,3,0,0,0,[ str_block(0,468,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,468,13,3,0,-4,0,0,0,0,0, " write_attr_into_file(header,\"$(file_name).tex\");")]) ]), mini_line(441,13,3,0,0,0,[ str_block(0,441,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,441,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(eq,\"$(file_name).tex\");")]) ]), mini_line(477,13,3,0,0,0,[ str_block(0,477,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,477,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(footer,\"$(file_name).tex\");")]) ]), mini_line(180,13,3,0,0,0,[ str_block(0,180,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,180,13,3,0,-4,0,0,0,0,0, " launch($(proc));")]) ]), mini_line(369,13,3,0,0,0,[ str_block(0,369,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,369,13,3,0,-4,0,0,0,0,0, " update_xpm_child(\"$(file_name).jpg\");")]) ]), mini_line(288,13,3,0,0,0,[ str_block(0,288,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,288,13,3,0,-4,0,0,0,0,0, " select_obj_by_name($(name));")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,162,13,3,0,-4,0,0,0,0,0, " hide_attr(eq);")]) ]), mini_line(189,13,3,0,0,0,[ str_block(0,189,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,189,13,3,0,-4,0,0,0,0,0, " launch(\"cleanup\")")]) ]) ])])), attr("header=", "", 0, 1, 0, text('#0000ff',161,711,11,0,1,270,176,14136,13,3,0,0,0,0,2,270,176,0,0,"",0,0,0,0,724,'',[ minilines(270,176,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "header=")]) ]), mini_line(261,13,3,0,0,0,[ str_block(0,261,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,261,13,3,0,-4,0,0,0,0,0, "\\documentclass[12pt]{article}")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,162,13,3,0,-1,0,0,0,0,0, "\\oddsidemargin=0in")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "\\textwidth=6.5in")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,13,3,0,-2,0,0,0,0,0, "\\topmargin=0pt")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,13,3,0,-2,0,0,0,0,0, "\\textheight=609pt")]) ]), mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,117,13,3,0,-2,0,0,0,0,0, "\\parskip=14pt")]) ]), mini_line(270,13,3,0,0,0,[ str_block(0,270,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,270,13,3,0,-4,0,0,0,0,0, "\\setlength{\\unitlength}{0.5cm}")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,13,3,0,-4,0,0,0,0,0, "\\pagestyle{empty}")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,3,0,-4,0,0,0,0,0, "\\begin{document}")]) ]), mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,13,3,0,-1,0,0,0,0,0, "%")]) ]) ])])), attr("footer=", "", 0, 1, 0, text('#ff00ff',162,887,3,0,1,126,48,613,13,3,0,0,0,0,2,126,48,0,0,"",0,0,0,0,900,'',[ minilines(126,48,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "footer=")]) ]), mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,13,3,0,-1,0,0,0,0,0, "%")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,13,3,0,-4,0,0,0,0,0, "\\end{document}")]) ]) ])])), attr("", "not_rigid", 0, 1, 0, text('blue',161,953,1,0,1,81,16,535,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,966,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "not_rigid")]) ]) ])])), attr("name=", "", 0, 1, 0, text('blue',161,5,1,0,1,45,16,13584,13,3,0,0,0,0,2,45,16,0,0,"",0,0,0,0,18,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "name=")]) ]) ])])), attr("name_assigned=", "", 0, 1, 0, text('blue',161,21,1,0,1,126,16,13738,13,3,0,0,0,0,2,126,16,0,0,"",0,0,0,0,34,'',[ minilines(126,16,0,0,0,0,0,[ mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,126,13,3,0,-1,0,0,0,0,0, "name_assigned=")]) ]) ])])), attr("assign_name=", "", 0, 1, 0, text('blue',161,37,2,0,1,1413,32,14586,13,3,0,0,0,0,2,1413,32,0,0,"",0,0,0,0,50,'',[ minilines(1413,32,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "assign_name=")]) ]), mini_line(1413,13,3,0,0,0,[ str_block(0,1413,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1413,13,3,0,-4,0,0,0,0,0, " get_user_input(name,\"Please give a name to this equation object:\",\"( A random name will be assigned if an empty string is entered or <ESC> is pressed. )\");")]) ]) ])])), attr("assign_random_name=", "", 0, 1, 0, text('blue',161,69,2,0,1,171,32,13960,13,3,0,0,0,0,2,171,32,0,0,"",0,0,0,0,82,'',[ minilines(171,32,0,0,0,0,0,[ mini_line(171,13,3,0,0,0,[ str_block(0,171,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,171,13,3,0,-1,0,0,0,0,0, "assign_random_name=")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,135,13,3,0,-4,0,0,0,0,0, " new_id(name);")]) ]) ])])), attr("geometry=", "25%", 0, 1, 0, text('blue',161,401,1,0,1,108,16,14529,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,414,'',[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "geometry=25%")]) ]) ])])), attr("density=", "576", 0, 1, 0, text('blue',161,413,1,0,1,99,16,14548,13,3,0,0,0,0,2,99,16,0,0,"",0,0,0,0,426,'',[ minilines(99,16,0,0,0,0,0,[ mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,99,13,3,0,-2,0,0,0,0,0, "density=576")]) ]) ])])), attr("cmd=", "", 0, 1, 0, text('blue',160,545,5,0,1,1197,80,14690,13,3,0,0,0,0,2,1197,80,0,0,"",0,0,0,0,558,'',[ minilines(1197,80,0,0,0,0,0,[ mini_line(36,13,3,0,0,0,[ str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, "cmd=")]) ]), mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-4,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(459,13,3,0,0,0,[ str_block(0,459,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,459,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e latex $(file_name);")]) ]), mini_line(702,13,3,0,0,0,[ str_block(0,702,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,702,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e dvips -E -n 1 -o $(file_name).ps $(file_name);")]) ]), mini_line(1197,13,3,0,0,0,[ str_block(0,1197,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1197,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e convert -scale $(geometry) -density $(density) $(file_name).ps $(file_name).jpg;")]) ]) ])])), attr("proc=", "cmd", 0, 1, 0, text('blue',161,437,1,0,1,72,16,14332,13,3,0,0,0,0,2,72,16,0,0,"",0,0,0,0,450,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "proc=cmd")]) ]) ])])), attr("colors=", "16", 0, 1, 0, text('blue',161,425,1,0,1,81,16,14647,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,438,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-2,0,0,0,0,0, "colors=16")]) ]) ])])) ]). ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/wb3.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000000543�11602233313�013626� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Renato Santana, <renato@nce.ufrj.br> in January, 1996. * * (Obsoleted in tgif-4.1.9 by the TangramII group at land.ufrj.br.) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb3.c,v 1.1 2004/06/18 23:19:10 william Exp $ */ #define _INCLUDE_FROM_WB3_C_ #include "tgifdefs.h" #ifdef _TGIF_WB #include "wb3.e" #endif /* _TGIF_WB */ �������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/hash.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000003456�11602233311�014064� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/hash.e,v 1.5 2011/05/16 16:21:57 william Exp $ */ #ifndef _HASH_E_ #define _HASH_E_ #include "list.e" #define TG_HASH_SIZE_SMALL 251 #define TG_HASH_SIZE_MEDIUM 509 #define TG_HASH_SIZE_LARGE 2039 typedef struct tagTgHash { int num_buckets; CVList *buckets; } TgHash; #ifdef _INCLUDE_FROM_HASH_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_HASH_C_*/ extern void CleanUpHash ARGS_DECL((TgHash*)); extern int InitHash ARGS_DECL((TgHash*, int which)); extern int HashStoreInt ARGS_DECL((TgHash*, char *key, int key_sz, int value)); extern int HashStoreStr ARGS_DECL((TgHash*, char *key, int key_sz, char *value)); extern int HashLookUpInt ARGS_DECL((TgHash*, char *key, int key_sz, int *pn_value_return)); extern char *HashLookUpStr ARGS_DECL((TgHash*, char *key, int key_sz)); #ifdef _INCLUDE_FROM_HASH_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_HASH_C_*/ #endif /*_HASH_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/mkinstalldirs������������������������������������������������������������������������0000755�0000764�0000764�00000006647�11602233316�015613� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#! /bin/sh # mkinstalldirs --- make directory hierarchy scriptversion=2006-05-11.19 # Original author: Noah Friedman <friedman@prep.ai.mit.edu> # Created: 1993-05-16 # Public domain. # # This file is maintained in Automake, please report # bugs to <bug-automake@gnu.org> or send patches to # <automake-patches@gnu.org>. nl=' ' IFS=" "" $nl" errstatus=0 dirmode= usage="\ Usage: mkinstalldirs [-h] [--help] [--version] [-m MODE] DIR ... Create each directory DIR (with mode MODE, if specified), including all leading file name components. Report bugs to <bug-automake@gnu.org>." # process command line arguments while test $# -gt 0 ; do case $1 in -h | --help | --h*) # -h for help echo "$usage" exit $? ;; -m) # -m PERM arg shift test $# -eq 0 && { echo "$usage" 1>&2; exit 1; } dirmode=$1 shift ;; --version) echo "$0 $scriptversion" exit $? ;; --) # stop option processing shift break ;; -*) # unknown option echo "$usage" 1>&2 exit 1 ;; *) # first non-opt arg break ;; esac done for file do if test -d "$file"; then shift else break fi done case $# in 0) exit 0 ;; esac # Solaris 8's mkdir -p isn't thread-safe. If you mkdir -p a/b and # mkdir -p a/c at the same time, both will detect that a is missing, # one will create a, then the other will try to create a and die with # a "File exists" error. This is a problem when calling mkinstalldirs # from a parallel make. We use --version in the probe to restrict # ourselves to GNU mkdir, which is thread-safe. case $dirmode in '') if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then echo "mkdir -p -- $*" exec mkdir -p -- "$@" else # On NextStep and OpenStep, the `mkdir' command does not # recognize any option. It will interpret all options as # directories to create, and then abort because `.' already # exists. test -d ./-p && rmdir ./-p test -d ./--version && rmdir ./--version fi ;; *) if mkdir -m "$dirmode" -p --version . >/dev/null 2>&1 && test ! -d ./--version; then echo "mkdir -m $dirmode -p -- $*" exec mkdir -m "$dirmode" -p -- "$@" else # Clean up after NextStep and OpenStep mkdir. for d in ./-m ./-p ./--version "./$dirmode"; do test -d $d && rmdir $d done fi ;; esac for file do case $file in /*) pathcomp=/ ;; *) pathcomp= ;; esac oIFS=$IFS IFS=/ set fnord $file shift IFS=$oIFS for d do test "x$d" = x && continue pathcomp=$pathcomp$d case $pathcomp in -*) pathcomp=./$pathcomp ;; esac if test ! -d "$pathcomp"; then echo "mkdir $pathcomp" mkdir "$pathcomp" || lasterr=$? if test ! -d "$pathcomp"; then errstatus=$lasterr else if test ! -z "$dirmode"; then echo "chmod $dirmode $pathcomp" lasterr= chmod "$dirmode" "$pathcomp" || lasterr=$? if test ! -z "$lasterr"; then errstatus=$lasterr fi fi fi fi pathcomp=$pathcomp/ done done exit $errstatus # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: �����������������������������������������������������������������������������������������tgif-QPL-4.2.5/ini.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000017461�11602233311�013721� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/ini.e,v 1.6 2011/05/16 16:21:58 william Exp $ */ #ifndef _INI_E_ #define _INI_E_ #ifdef _INCLUDE_FROM_INI_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_INI_C_*/ /* * tgCleanUpProfile() frees all file information. */ extern void tgCleanUpProfile ARGS_DECL((void)); /* * tgFreeProfileString() must be called to free any string returned by * tgGetProfileString(). * NULL is always returned; */ extern char * tgFreeProfileString ARGS_DECL((char *pszStr)); /* * tgBeginFastProfile() turns off file time checking for pszFile. * tgEndFastProfile() turns on file time checking for pszFile. * Normally, any of the tgGet...() and tgWrite...() routines below checks * to see if the INI file is modified. If the INI file is modified, * the cache is flushed before any action is take. * Surrounding a set of tgGet...() and tgWrite...() routines by a * tgBeginFastProfile() and tgEndFastProfile() pair turns off file * time checking. This approach should only be used if the tg...() * routines are called in a tight loop. */ extern void tgBeginFastProfile ARGS_DECL((char *pszFile)); extern void tgEndFastProfile ARGS_DECL((char *pszFile)); /* * tgSetProfileStripQuotes() turns on/off single and double quotes stripping * for pszFile. By default, quotes-stripping is turned on (TRUE). If * you are using an encrypted file, you should call this function with * bStripQuotes set to FALSE. * It returns the current quotes-stripping setting for pszFile. */ extern int tgSetProfileStripQuotes ARGS_DECL((char *pszFile, int bStripQuotes)); /* * tgGetProfileString() works the same way as GetPrivateProfileString() * except that when pszSection is NULL, all sections are returned (in * the way similar to the case where pszEntry is NULL). * If the returned string is non-NULL, it must be freed by calling * tgFreeProfileString(); */ extern char * tgGetProfileString ARGS_DECL((char *pszSection, char *pszEntry, char *pszFile)); /* * tgGetProfileInt() works the same way as GetPrivateProfileInt() except * that when pszSection is NULL, the information cached for pszFile is * discarded. If pszSection is NULL and the file can not be written, * the returned value will be !nDefault. */ extern int tgGetProfileInt ARGS_DECL((char *pszSection, char *pszEntry, int nDefault, char *pszFile)); /* * tgWriteProfileString() works the same way as WritePrivateProfileString() * except that if pszSection is not NULL, the write is doesn't update * pszFile (it uses write-back instead of write-through). Therefore, * one should always call this function again with a NULL pszSection to * force out the write. * Returns FALSE if memory allocation fails. */ extern int tgWriteProfileString ARGS_DECL((char *pszSection, char *pszEntry, char *pszString, char *pszFile)); /* * tgBeginDupKeySection() turns on duplicate key retrieval for the pszSection * of pszFile. The pszSection can NOT be NULL. * tgEndFastProfile() turns it off. * Normally, any of the tgGet...() and tgWrite...() routines behaves like * their Windows API counter-parts where duplicate entries are removed. * Surrounding a set of tgGet...() and tgWrite...() routines by a * tgBeginDupKeySection() and tgEndDupKeySection() enables retrieval of * entries with duplicate keys. This approach should only be used if * the tg...() routines are called in a tight loop. Also, the * pszSection in the tg...() calls must be the same as the pszSection * used in tgBeginDupKeySection() and tgEndDupKeySection(). */ extern void tgBeginDupKeySection ARGS_DECL((char *pszSection, char *pszFile)); extern void tgEndDupKeySection ARGS_DECL((char *pszSection, char *pszFile)); /* * tgBeginValuelessKeySection() turns on valueless key writes for the * pszSection of pszFile. The pszSection can NOT be NULL. Examples of * valueless key section are sections in Ios.ini. * tgBeginValuelessKeySection() returns TRUE if pszSection of pszFile is * valueless. * tgEndFastProfile() sets the valueless key flag for pszSection of pszFile * to be bValuelessKey. * These two functions has no effect on reads! * * Surrounding a set of tgWriteProfileString() calls by * tgBeginValuelessKeySection() and tgEndValuelessKeySection() enables * writes of lines with valueless keys. The pszSection in the * tgWriteProfileString() calls must use the same pszSection as the * pszSection used in tgBeginValuelessKeySection() and * tgEndValuelessKeySection(). Furthermore, tgWriteProfileString() must * be called with NULL pszValue. Also, please make sure that * tgWriteProfileString() is called with a NULL pszSection to force out * the write before tgEndValuelessKeySection() is called. * * The following is an example of how to use these functions. * * BOOL bValuelessKey=faBeginValuelessKeySection(pszSection, pszFile); * * tgWriteProfileString(pszSection, pszEntry1, NULL, pszFile); * tgWriteProfileString(pszSection, pszEntry2, NULL, pszFile); * ... * tgWriteProfileString(NULL, NULL, NULL, pszFile); * * tgEndValuelessKeySection(pszSection, pszFile, bValuelessKey); */ extern int tgBeginValuelessKeySection ARGS_DECL((char *pszSection, char *pszFile)); extern void tgEndValuelessKeySection ARGS_DECL((char *pszSection, char *pszFile, int bValuelessKey)); /* * tgIsValuelessKeySection() returns TRUE if pszSection of pszFile is a * valueless key section. */ extern int tgIsValuelessKeySection ARGS_DECL((char *pszSection, char *pszFile)); /* * tgDeleteDupKeyValue() deletes the key/value pair specified by * pszEntry/pszValue in pszSection of pszFile. * Returns FALSE if any of the parameters is NULL. * Internally, this function calls tgBeginDupKeySection() and * tgEndDupKeySection() but it does NOT write out the file. */ extern int tgDeleteDupKeyValue ARGS_DECL((char *pszSection, char *pszEntry, char *pszValue, char *pszFile)); #ifdef _INCLUDE_FROM_INI_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_INI_C_*/ #endif /*_INI_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/msg.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000013140�11602233312�013717� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/msg.e,v 1.14 2011/05/16 16:21:58 william Exp $ */ #ifndef _MSG_E_ #define _MSG_E_ extern char scanFileFullPath[MAXPATHLENGTH+1]; extern char scanFileName[]; extern int scanLineNum; extern char progName[MAXPATHLENGTH+1]; extern char fatalMsgBuf1[]; extern char fatalMsgBuf2[]; extern int cmdLineParentWindowID; extern int cmdLineTgrm2; extern int cmdLineWb2; #ifdef _INCLUDE_FROM_MSG_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_MSG_C_*/ extern int ShowOrPrintMsg ARGS_DECL((char*, int use_msgbox)); extern int FailAllocMessage ARGS_DECL((void)); extern int FailAllocBitmapMessage ARGS_DECL((int W, int H)); extern int FailAllocPixmapMessage ARGS_DECL((int W, int H)); extern int FailToWriteFileMessage ARGS_DECL((char *file_name)); extern int FailToOpenMessage ARGS_DECL((char *file_name, char *rwa, char *extra_msg)); extern int FailToCreateWindowMessage ARGS_DECL((char *where, char *win_name, int do_exit)); extern int FatalUnexpectedError ARGS_DECL((char*, char*)); extern int TgAssert ARGS_DECL((int must_be_true, char*, char*)); extern int BoldMsgCharBytes ARGS_DECL((char*)); extern char *BoldMsgNextChar ARGS_DECL((char*)); extern char *BoldMsgLastChar ARGS_DECL((char*)); extern char *BoldMsgStrChr ARGS_DECL((char*, int)); extern int MenuTextWidth ARGS_DECL((XFontStruct*, char *psz, int nLen)); extern int MsgTextWidth ARGS_DECL((XFontStruct*, char *psz, int nLen)); extern int BoldMsgTextWidth ARGS_DECL((XFontStruct*, char *psz, int nLen)); extern int ItalicMsgTextWidth ARGS_DECL((XFontStruct*, char *psz, int nLen)); extern int BoldItalicMsgTextWidth ARGS_DECL((XFontStruct*, char *psz, int nLen)); extern void DrawMenuString ARGS_DECL((Display*, Window, GC, int x, int baseline_y, char *psz, int nLen)); extern void DrawMsgString ARGS_DECL((Display*, Window, GC, int x, int baseline_y, char *psz, int nLen)); extern void DrawBoldMsgString ARGS_DECL((Display*, Window, GC, int x, int baseline_y, char *psz, int nLen)); extern void DrawItalicMsgString ARGS_DECL((Display*, Window, GC, int x, int baseline_y, char *psz, int nLen)); extern void DrawBoldItalicMsgString ARGS_DECL((Display*, Window, GC, int x, int baseline_y, char *psz, int nLen)); extern void CleanUpMsg ARGS_DECL((void)); extern void RedrawMsg ARGS_DECL((int erase_background)); extern void Msg ARGS_DECL((char *)); extern void TwoLineMsg ARGS_DECL((char *Msg1, char *Msg2)); extern void PrintMsgBuffer ARGS_DECL((void)); extern void RedrawStatusWindow ARGS_DECL((void)); extern void SetMouseStatus ARGS_DECL((char *Left, char *Middle, char *Right)); extern void SetStringStatus ARGS_DECL((char *StatusStr)); extern void SaveStatusStrings ARGS_DECL((void)); extern void RestoreStatusStrings ARGS_DECL((void)); extern void SaveStatusStringsIntoBuf ARGS_DECL(( char ppsz_buf[MAX_STATUS_BTNS+1][MAXSTRING+1], int*)); extern void RestoreStatusStringsFromBuf ARGS_DECL(( char ppsz_buf[MAX_STATUS_BTNS+1][MAXSTRING+1], int)); extern void BeginProgress ARGS_DECL((ProgressInfo*, int total_size)); extern void UpdateProgress ARGS_DECL((ProgressInfo*, int cur_size)); extern void EndProgress ARGS_DECL((ProgressInfo*)); extern void MsgEventHandler ARGS_DECL((XEvent*)); extern void StatusEventHandler ARGS_DECL((XEvent*)); extern void RedrawUserRedrawWindow ARGS_DECL((void)); extern void UserRedrawEventHandler ARGS_DECL((XEvent*)); extern void InitStatus ARGS_DECL((void)); extern void CleanUpStatus ARGS_DECL((void)); extern void InitScan ARGS_DECL((char *Str, char *Pat)); extern int ScanValue ARGS_DECL((char *Fmt, void *Value, char *Item, char *SType)); extern int ScanDynStrValue ARGS_DECL((struct DynStrRec *Value, char *Item, char *SType)); extern void EmergencySave ARGS_DECL((int Sig)); extern int EmergencySaveForX ARGS_DECL((Display*, XErrorEvent*)); extern int IOEmergencySaveForX ARGS_DECL((Display *)); extern void Error ARGS_DECL((char *where, char *msg)); extern void GetTgifVersionAndPatchLevel ARGS_DECL((char *buf, int buf_sz)); extern void Usage ARGS_DECL((char*)); extern int ProcessPrTgifOptions ARGS_DECL((int argc, char *argv[], int)); extern int ProcessTgifOptions ARGS_DECL((int argc, char *argv[], char *file_name, int name_sz)); #ifdef _INCLUDE_FROM_MSG_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_MSG_C_*/ #endif /*_MSG_E_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/wb.e���������������������������������������������������������������������������������0000644�0000764�0000764�00000011433�11602233313�013545� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb.e,v 1.15 2011/05/16 16:22:00 william Exp $ */ #ifndef _WB_E_ #define _WB_E_ #define WB_PACK 60000 typedef struct WhiteBoardRec { int do_whiteboard; char send_fname[MAXPATHLENGTH]; char gz_send_fname[MAXPATHLENGTH]; /* zlib, not gzip */ FILE *send_fp; FILE *gz_send_fp; /* zlib, not gzip */ int send_socket; int listening; char listen_fname[MAXPATHLENGTH]; char gz_listen_fname[MAXPATHLENGTH]; /* zlib, not gzip */ FILE *listen_fp; FILE *gz_listen_fp; /* zlib, not gzip */ int listen_socket; int MCastSock; int bd_commands; int BlockRemoteCmdDepth; int logical_clock; long pid; int dont_serialize; /* true will skip the call to SerializeCmd() */ struct CmdRec *first_cmd, *last_cmd, *cur_cmd; struct CmdRec *first_shadow_cmd, *last_shadow_cmd; int join_session_in_progress; /* there is current WB state info */ } *WhiteBoardPtr; typedef struct WbMessage{ char WbCmd[WB_PACK]; }wbmsgPtr; typedef struct tagSerializationInfo { struct SubCmdRec *subcmd; struct SelRec *top_sel; /* TopSel */ struct SelRec *bot_sel; /* BotSel */ int num_objs; /* NumObjs */ int include_tgif_obj; /* recordCmdIncludeTgifObj */ int new_colormap; /* recordCmdUsesNewColormap */ int logical_clock; /* gstWBInfo.logical_clock */ char *sender_process_id; /* just a pointer, gszLocalPID */ struct SelRec *top_before; /* topSelBeforeInCmd */ struct SelRec *bot_before; /* botSelBeforeInCmd */ int *pos_before; /* stackingPosition */ int count_before; /* stackingCount */ int pos_before_has_ids; /* stackingPositionHasIds */ } SerializationInfo; extern struct WhiteBoardRec gstWBInfo; extern int cmdLineNoWhiteBoard; extern int cmdLineWhiteBoardListenOnly; #ifdef _INCLUDE_FROM_WB_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_WB_C_*/ /* =================== Remote Related Functions =================== */ extern void PrintFullIDsOfObjects ARGS_DECL((char *psz_prefix)); extern int WBHasReadData ARGS_DECL((int *pn_flag, int *pn_retry)); extern int RecvWBData ARGS_DECL(( int flag, /* *pn_flag of WBHasReadData() */ char **ppsz_buf, int *pn_buf_sz)); extern void TryHandleWBInputData ARGS_DECL((void)); extern int SendWBData ARGS_DECL((char *pszWBData, int logical_clock)); //extern int SendWBData ARGS_DECL((char *pszWBData)); /* =================== Cmd Related Functions =================== */ extern char *SerializeCmd ARGS_DECL((int CmdType, SerializationInfo*, int *pnAssignedLogicalClock, char **ppszPlainWBData, int *pnPlainWBDataSz)); extern void SerializeFreeBuf ARGS_DECL((char *psz_buf)); extern int ReadExtendedCmd ARGS_DECL((FILE *FP, char *Inbuf)); extern int ReadExtendedCmdInfo ARGS_DECL((FILE *FP, char *Inbuf)); extern int ReadCmd ARGS_DECL((FILE *FP, char *Inbuf)); extern int ReadBeforeImage ARGS_DECL((FILE *FP, char *Inbuf)); extern int ReadAfterPositions ARGS_DECL((FILE *FP, char *Inbuf)); extern int ReadAfterImage ARGS_DECL((FILE *FP, char *Inbuf)); extern void FindCmdInsertionPoint ARGS_DECL((struct CmdRec *cmd_to_insert, struct CmdRec **pp_immed_right_cmd)); extern void FindShadowCmdInsertionPoint ARGS_DECL(( struct CmdRec *cmd_to_insert, struct CmdRec **pp_immed_right_cmd)); extern void CleanUpObsoletedWBCmds ARGS_DECL((struct CmdRec *)); extern void ProcessRemoteCmd ARGS_DECL((char *psz_content_type, char *psz_buf, int buf_sz)); /* =================== Handle New User Requests =================== */ extern void HandleNewUserRequest ARGS_DECL((void)); /* =================== Init and CleanUp Functions =================== */ extern void CleanUpWhiteBoard ARGS_DECL((void)); extern int InitWhiteBoard ARGS_DECL((void)); extern int InitWhiteBoard2 ARGS_DECL((void)); extern void RMcallback_terminate ARGS_DECL((void)); #ifdef _INCLUDE_FROM_WB_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_WB_C_*/ #endif /*_WB_E_*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/import.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000370761�11602233311�014457� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/import.c,v 1.52 2011/06/14 03:22:14 william Exp $ */ #define _INCLUDE_FROM_IMPORT_C_ #include "tgifdefs.h" #include "cmdids.h" #include "attr.e" #include "auxtext.e" #include "box.e" #include "choice.e" #include "choose.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "eps.e" #include "file.e" #include "font.e" #include "grid.e" #include "imgproc.e" #include "import.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "msg.e" #include "menu.e" #include "move.e" #include "names.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "pngtrans.e" #include "raster.e" #include "rect.e" #include "remote.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "special.e" #include "stretch.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "xbitmap.e" #include "xpixmap.e" #include "z_intrf.e" typedef struct ImportInfoRec { char *name, *ext, *cmd; struct ImportInfoRec *next; } *ImportInfoPtr; static struct ImportInfoRec *topImportInfo=NULL, *botImportInfo=NULL; static int gnMaxImportFilters=0; static int showFileNameOnBrowse=TRUE; static int thumbnailW=160; static int thumbnailH=120; static int thumbnailPadding=8; static int thumbnailXGap=16; static int thumbnailYGap=0; static int thumbnailX=32; static int thumbnailY=32; void MillisecondSleep(ms) int ms; { struct timeval timeout; fd_set fdset; timeout.tv_sec = 0; timeout.tv_usec = ms*1000; FD_ZERO(&fdset); #ifdef __hpux select(0, (int*)&fdset, NULL, NULL, &timeout); #else /* !__hpux */ select(0, &fdset, NULL, NULL, &timeout); #endif /* __hpux */ } int ExtensionMatch(Spec, DirName) char *Spec, *DirName; { char *c_ptr, other_ext_str[MAXSTRING]; int len; if (Spec == NULL || *Spec == '\0') return FALSE; len = strlen(DirName); strcpy(other_ext_str, Spec); for (c_ptr=strtok(other_ext_str,";"); c_ptr != NULL; c_ptr=strtok(NULL, ";")) { int other_ext_len=strlen(c_ptr); if (len > other_ext_len && UtilStrICmp(c_ptr, &DirName[len-other_ext_len]) == 0) { return TRUE; } } return FALSE; } char *SetUpExtStr(cbBuf, pszExt, pszOtherExt) int cbBuf; char *pszExt, *pszOtherExt; /* pszExt="gif;GIF", pszOtherExt=".jpg;.jpeg" */ { char *c_ptr, *buf=(char*)malloc(cbBuf*sizeof(char)), *start_ptr, *dest_ptr; if (buf == NULL) { FailAllocMessage(); return NULL; } *buf = '\0'; dest_ptr = buf; start_ptr = pszExt; while (*start_ptr == ' ') start_ptr++; c_ptr = strchr(start_ptr, ';'); while (start_ptr != NULL) { if (c_ptr != NULL) *c_ptr = '\0'; if(dest_ptr == buf) { sprintf(dest_ptr, ".%s", start_ptr); } else { sprintf(dest_ptr, ";.%s", start_ptr); } dest_ptr = (&dest_ptr[strlen(dest_ptr)]); if (c_ptr != NULL) *c_ptr++ = ';'; if (c_ptr == NULL) break; start_ptr = c_ptr; while (*start_ptr == ' ') start_ptr++; c_ptr = strchr(start_ptr, ';'); } if (dest_ptr == buf) { strcpy(buf, pszOtherExt); } else if (*pszOtherExt == '\0') { *dest_ptr = '\0'; } else { sprintf(dest_ptr, ";%s", pszOtherExt); } return buf; } void CleanUpImport() { struct ImportInfoRec *next_import; while (topImportInfo != NULL) { next_import = topImportInfo->next; if(topImportInfo->name != NULL) free(topImportInfo->name); if(topImportInfo->ext != NULL) free(topImportInfo->ext); if(topImportInfo->cmd != NULL) free(topImportInfo->cmd); free(topImportInfo); topImportInfo = next_import; } topImportInfo = botImportInfo = NULL; } #define INVALID_FILTER_SPEC_DEFAULT 0 #define INVALID_FILTER_SPEC_MISSING_PERC_S 1 #define INVALID_FILTER_SPEC_TOO_MANY_PERC_S 2 static void InvalidFilterSpecMsg(pszEntry, pszValue, nExplain) char *pszEntry, *pszValue; int nExplain; { switch (nExplain) { case INVALID_FILTER_SPEC_DEFAULT: sprintf(gszMsgBox, TgLoadString(STID_BAD_FLTR_SPEC_DEF), TOOL_NAME, pszEntry, pszValue); break; case INVALID_FILTER_SPEC_MISSING_PERC_S: sprintf(gszMsgBox, TgLoadString(STID_BAD_FLTR_SPEC_MISS_PERC_S), TOOL_NAME, pszEntry, pszValue); break; case INVALID_FILTER_SPEC_TOO_MANY_PERC_S: sprintf(gszMsgBox, TgLoadString(STID_BAD_FLTR_SPEC_MANY_PERC_S), TOOL_NAME, pszEntry, pszValue); break; } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } static int CountPercentS(buf) char *buf; { int count=0; char *c_ptr; for (c_ptr=strstr(buf, "%s"); c_ptr != NULL; c_ptr=strstr(++c_ptr, "%s")) { count++; } return count; } static char *FindBlank(pszStr, ppszEnd) char *pszStr, **ppszEnd; { char *c_ptr=pszStr, ch; if (!(*c_ptr == '"' || *c_ptr == '\'')) { *ppszEnd = strchr(pszStr, ' '); return pszStr; } for (ch=(*c_ptr++); *c_ptr != '\0'; c_ptr++) { if (*c_ptr == '\\') { c_ptr++; } else if (*c_ptr == ch) { *ppszEnd = c_ptr; return &pszStr[1]; } } *ppszEnd = NULL; return pszStr; } void InitImport() { char *c_ptr; int max_filters=0; showFileNameOnBrowse = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ShowFileNameOnBrowse")) != NULL) { if (UtilStrICmp(c_ptr, "false") == 0) { showFileNameOnBrowse = FALSE; } } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MaxImportFilters")) != NULL) { max_filters = atoi(c_ptr); if (max_filters <= 0) { sprintf(gszMsgBox, TgLoadString(STID_BAD_XDEF_MUST_BE_GT_0), TOOL_NAME, "MaxImportFilters", c_ptr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } gnMaxImportFilters = 0; if (max_filters > 0) { int i; for (i=0; i < max_filters; i++) { char buf[80]; sprintf(buf, "ImportFilter%1d", i); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,buf)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_XDEF_CONT_LOOK_FLTR), TOOL_NAME, buf); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) != MB_ID_YES) { break; } } else { char *name_ptr=UtilStrDup(c_ptr), *dup_buf=UtilStrDup(c_ptr); char *ext_ptr; if (name_ptr == NULL || dup_buf == NULL) FailAllocMessage(); for (c_ptr=name_ptr; *c_ptr != '\0'; c_ptr++) { if (*c_ptr == '\t' || *c_ptr == '\n' || *c_ptr == '\r') { *c_ptr = ' '; } } for (c_ptr=dup_buf; *c_ptr != '\0'; c_ptr++) { if (*c_ptr == '\t' || *c_ptr == '\n' || *c_ptr == '\r') { *c_ptr = ' '; } } UtilTrimBlanks(name_ptr); name_ptr = FindBlank(name_ptr, &ext_ptr); if (ext_ptr == NULL) { InvalidFilterSpecMsg(buf, dup_buf, INVALID_FILTER_SPEC_DEFAULT); } else { char *cmd_ptr; *ext_ptr++ = '\0'; UtilTrimBlanks(ext_ptr); ext_ptr = FindBlank(ext_ptr, &cmd_ptr); if (cmd_ptr == NULL) { InvalidFilterSpecMsg(buf, dup_buf, INVALID_FILTER_SPEC_DEFAULT); } else { int len, count; *cmd_ptr++ = '\0'; UtilTrimBlanks(cmd_ptr); len = strlen(cmd_ptr); if (len >= 2 && ((*cmd_ptr == '"' && cmd_ptr[len-1] == '"') || (*cmd_ptr == '\'' && cmd_ptr[len-1] == '\''))) { cmd_ptr[len-1] = '\0'; cmd_ptr++; UtilTrimBlanks(cmd_ptr); } count = CountPercentS(cmd_ptr); if (count < 1) { InvalidFilterSpecMsg(buf, dup_buf, INVALID_FILTER_SPEC_MISSING_PERC_S); } else if (count > 1) { InvalidFilterSpecMsg(buf, dup_buf, INVALID_FILTER_SPEC_TOO_MANY_PERC_S); } else { struct ImportInfoRec *pii=(struct ImportInfoRec*)malloc( sizeof(struct ImportInfoRec)); if (pii == NULL) FailAllocMessage(); memset(pii, 0, sizeof(struct ImportInfoRec)); pii->next = NULL; pii->name = UtilStrDup(name_ptr); pii->ext = UtilStrDup(ext_ptr); pii->cmd = UtilStrDup(cmd_ptr); if (pii->name==NULL || pii->ext==NULL || pii->cmd==NULL) { FailAllocMessage(); if (pii->name != NULL) free(pii->name); if (pii->ext != NULL) free(pii->ext); if (pii->cmd != NULL) free(pii->cmd); } else { if (botImportInfo != NULL) { botImportInfo->next = pii; } else { topImportInfo = pii; } botImportInfo = pii; gnMaxImportFilters++; } } } } if (name_ptr != NULL) free(name_ptr); if (dup_buf != NULL) free(dup_buf); } } } thumbnailW = 160; thumbnailH = 120; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ThumbnailGeometry")) != NULL) { int w=0, h=0; if (ParseWHSpec(c_ptr, &w, &h) && w >= 40 && h >= 30) { if (w >= 40 && h >= 30) { thumbnailW = w; thumbnailH = h; } else { fprintf(stderr, TgLoadString(STID_INVALID_GEOM_USE_ALT_GEOM), TOOL_NAME, "ThumbnailGeometry", c_ptr, "40x30", "160x120"); fprintf(stderr, "\n"); } } } thumbnailPadding = 8; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ThumbnailPadding")) != NULL) { int padding=0; UtilTrimBlanks(c_ptr); if (sscanf(c_ptr, "%d", &padding) != 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "ThumbnailPadding", c_ptr, 8); fprintf(stderr, "\n"); } else if (padding < 0 || padding > 100) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_RNG_USE_ALT_VAL), TOOL_NAME, "ThumbnailPadding", c_ptr, 0, 100, 8); fprintf(stderr, "\n"); } else { thumbnailPadding = padding; } } thumbnailXGap = 16; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ThumbnailXGap")) != NULL) { int gap=0; UtilTrimBlanks(c_ptr); if (sscanf(c_ptr, "%d", &gap) != 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "ThumbnailXGap", c_ptr, 16); fprintf(stderr, "\n"); } else if (gap < 0) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "ThumbnailXGap", c_ptr, 16); fprintf(stderr, "\n"); } else { thumbnailXGap = gap; } } thumbnailYGap = 0; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ThumbnailYGap")) != NULL) { int gap=0; UtilTrimBlanks(c_ptr); if (sscanf(c_ptr, "%d", &gap) != 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "ThumbnailYGap", c_ptr, 16); fprintf(stderr, "\n"); } else if (gap < 0) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "ThumbnailYGap", c_ptr, 16); fprintf(stderr, "\n"); } else { thumbnailYGap = gap; } } thumbnailX = 32; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ThumbnailX")) != NULL) { int x=0; UtilTrimBlanks(c_ptr); if (sscanf(c_ptr, "%d", &x) != 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "ThumbnailX", c_ptr, 32); fprintf(stderr, "\n"); } else { thumbnailX = x; } } thumbnailY = 32; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ThumbnailY")) != NULL) { int y=0; UtilTrimBlanks(c_ptr); if (sscanf(c_ptr, "%d", &y) != 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "ThumbnailY", c_ptr, 32); fprintf(stderr, "\n"); } else { thumbnailY = y; } } } static int ImportGivenXBitmapFile(remote_file, tmp_fname, xbm_fname, stid_success, stid_failure, pn_image_w, pn_image_h) int remote_file, stid_success, stid_failure, *pn_image_w, *pn_image_h; char *tmp_fname, *xbm_fname; { char *rest=NULL, mag_spec[MAXSTRING+1]; unsigned int tmp_w, tmp_h; int rc=0, short_name=FALSE, x=0, y=0, w=0, h=0; int x_hot=0, y_hot=0, orig_w=0, orig_h=0; float mag=(float)0; Pixmap orig_bitmap=None, bitmap=None; XImage *image=NULL; struct ObjRec *obj_ptr=NULL; if (pn_image_w != NULL) *pn_image_w = 0; if (pn_image_h != NULL) *pn_image_h = 0; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = XReadBitmapFile(mainDisplay, mainWindow, (remote_file ? tmp_fname : xbm_fname), &tmp_w, &tmp_h, &orig_bitmap, &x_hot, &y_hot); orig_w = tmp_w; orig_h = tmp_h; SetDefaultCursor(mainWindow); ShowCursor(); if (remote_file) { short_name = FALSE; } else { if ((short_name=IsPrefix(bootDir, xbm_fname, &rest))) ++rest; } if (rc != BitmapSuccess) { sprintf(gszMsgBox, TgLoadString(stid_failure), (short_name ? rest : xbm_fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (remote_file) unlink(tmp_fname); return FALSE; } x = 0; y = 0; w = orig_w; h = orig_h; mag = 1.0; if (askForXBmSpec) { sprintf(gszMsgBox, TgLoadString(STID_ENTER_GEOM_SPEC_ORIG_SIZE), orig_w, orig_h); *mag_spec = '\0'; Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CONTINUE), mag_spec); if (*mag_spec != '\0') { ParseCutSpec(mag_spec, orig_w, orig_h, &mag, &x, &y, &w, &h); } if (x==0 && y==0 && w==orig_w && h==orig_h && mag==1.0) { bitmap = orig_bitmap; } else { orig_w = w; orig_h = h; if (!ExtractBitmap(orig_bitmap, NULL, x, y, w, h, &bitmap, &image)) { if (remote_file) unlink(tmp_fname); XFreePixmap(mainDisplay, orig_bitmap); return FALSE; } XFreePixmap(mainDisplay, orig_bitmap); w = (int)(((float)w) * mag); h = (int)(((float)h) * mag); } } else { bitmap = orig_bitmap; } obj_ptr = CreateXBmObj(orig_w, orig_h, w, h, bitmap, image); AddObj(NULL, topObj, obj_ptr); PlaceTopObj(obj_ptr, NULL, NULL); SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; if (!importFromLibrary && !remote_file) SetCurImportDir(xbm_fname); if (stid_success != INVALID) { sprintf(gszMsgBox, TgLoadString(stid_success), orig_w, orig_h, (short_name ? rest : xbm_fname)); Msg(gszMsgBox); } if (pn_image_w != NULL) *pn_image_w = orig_w; if (pn_image_h != NULL) *pn_image_h = orig_h; return TRUE; } void ImportXBitmapFile() { char xbm_fname[MAXPATHLENGTH+1], tmp_fname[MAXPATHLENGTH+1]; int remote_file=FALSE; XEvent ev; MakeQuiescent(); importingFile = TRUE; *xbm_fname = *tmp_fname = '\0'; if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_XBM_FILE_TO_IMPORT), XBM_FILE_EXT, name, path) == INVALID) { importingFile = FALSE; return; } sprintf(xbm_fname, "%s%c%s", path, DIR_SEP, name); } else if (SelectFileNameToImport(TgLoadString(STID_SEL_XBM_FILE_TO_IMPORT), XBM_FILE_EXT, xbm_fname) == INVALID) { importingFile = FALSE; return; } else if (FileIsRemote(xbm_fname)) { int is_html=FALSE; if (!DownloadRemoteFile(xbm_fname, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { importingFile = FALSE; return; } remote_file = TRUE; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } ImportGivenXBitmapFile(remote_file, tmp_fname, xbm_fname, STID_GIVEN_XBM_SIZE_FILE_IMPORTED, STID_CANNOT_IMPORT_XBM_FILE, NULL, NULL); if (remote_file) unlink(tmp_fname); importingFile = FALSE; } static int ImportGivenXPixmapFile(remote_file, tmp_fname, xpm_fname, stid_success, stid_failure, pn_image_w, pn_image_h) int remote_file, stid_success, stid_failure, *pn_image_w, *pn_image_h; char *tmp_fname, *xpm_fname; { char *rest=NULL; int rc=0, ncolors=0, chars_per_pixel=0, *pixels=NULL, short_name=FALSE; int first_pixel_is_bg=FALSE, image_w=0, image_h=0, w=0, h=0; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; char *color_char, **color_str=NULL, *xpm_data=NULL; struct ObjRec *obj_ptr=NULL; if (pn_image_w != NULL) *pn_image_w = 0; if (pn_image_h != NULL) *pn_image_h = 0; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(remote_file ? tmp_fname : xpm_fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if (remote_file) { short_name = FALSE; } else { if ((short_name=IsPrefix(bootDir, xpm_fname, &rest))) ++rest; } if (rc != BitmapSuccess) { if (stid_failure != INVALID) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), (short_name ? rest : xpm_fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); AddObj(NULL, topObj, obj_ptr); PlaceTopObj(obj_ptr, NULL, NULL); SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } if (!importFromLibrary && !remote_file && tmp_fname != NULL) { SetCurImportDir(xpm_fname); } if (stid_success != INVALID) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_XPM_SIZE_FILE_IMPORTED), image_w, image_h, (short_name ? rest : xpm_fname)); Msg(gszMsgBox); } if (pn_image_w != NULL) *pn_image_w = image_w; if (pn_image_h != NULL) *pn_image_h = image_h; return TRUE; } void ImportXPixmapFile() { char xpm_fname[MAXPATHLENGTH+1], tmp_fname[MAXPATHLENGTH+1]; int remote_file=FALSE; XEvent ev; MakeQuiescent(); importingFile = TRUE; *xpm_fname = *tmp_fname = '\0'; if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_XPM_FILE_TO_IMPORT), XPM_FILE_EXT, name, path) == INVALID) { importingFile = FALSE; return; } sprintf(xpm_fname, "%s%c%s", path, DIR_SEP, name); } else if (SelectFileNameToImport(TgLoadString(STID_SEL_XPM_FILE_TO_IMPORT), XPM_FILE_EXT, xpm_fname) == INVALID) { importingFile = FALSE; return; } else if (FileIsRemote(xpm_fname)) { int is_html=FALSE; if (!DownloadRemoteFile(xpm_fname, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { importingFile = FALSE; return; } remote_file = TRUE; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } ImportGivenXPixmapFile(remote_file, tmp_fname, xpm_fname, STID_GIVEN_XPM_SIZE_FILE_IMPORTED, STID_CANNOT_IMPORT_XPM_FILE, NULL, NULL); if (remote_file) unlink(tmp_fname); importingFile = FALSE; } void ImportEPSFile(Embed, psz_fname_spec) int Embed; char *psz_fname_spec; { char eps_fname[MAXPATHLENGTH+1], *rest=NULL, tmp_fname[MAXPATHLENGTH+1]; char **lines=NULL, write_date[32]; int i, rc, short_name, num_lines=0, epsf_level, image_w, image_h; int remote_file=FALSE; float llx, lly, urx, ury; Pixmap bitmap=None; XImage *image=NULL; XEvent ev; struct ObjRec *obj_ptr=NULL; MakeQuiescent(); importingFile = TRUE; *eps_fname = *tmp_fname = '\0'; if (psz_fname_spec != NULL && strcmp(psz_fname_spec, "-1") != 0) { int len=strlen(psz_fname_spec); if (len > 0 && psz_fname_spec[len-1] == ')') { psz_fname_spec[len-1] = '\0'; UtilStrCpyN(tmp_fname, sizeof(tmp_fname), psz_fname_spec); psz_fname_spec[len-1] = ')'; } else { UtilStrCpyN(tmp_fname, sizeof(tmp_fname), psz_fname_spec); } if (*tmp_fname == DIR_SEP) { strcpy(eps_fname, tmp_fname); } else if (curDirIsLocal) { sprintf(eps_fname, "%s%c%s", curDir, DIR_SEP, tmp_fname); } else { sprintf(eps_fname, "%s%c%s", curLocalDir, DIR_SEP, tmp_fname); } *tmp_fname = '\0'; } else { if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_EPS_FILE_TO_IMPORT), EPSF_FILE_EXT, name, path) == INVALID) { importingFile = FALSE; return; } sprintf(eps_fname, "%s%c%s", path, DIR_SEP, name); } else if (SelectFileNameToImport( TgLoadString(STID_SEL_EPS_FILE_TO_IMPORT), EPSF_FILE_EXT, eps_fname) == INVALID) { importingFile = FALSE; return; } } if (FileIsRemote(eps_fname)) { int is_html=FALSE; if (!Embed) { sprintf(gszMsgBox, TgLoadString(STID_IMPORT_REM_FILE_EMBED_INSTEAD), "EPS", "EPS"); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) != MB_ID_YES) { importingFile = FALSE; return; } Embed = TRUE; } if (!DownloadRemoteFile(eps_fname, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { importingFile = FALSE; return; } remote_file = TRUE; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadEPSFile(remote_file ? tmp_fname : eps_fname, &image_w, &image_h, &bitmap, &image, (Embed ? &num_lines : NULL), (Embed ? &lines : NULL), &epsf_level, &llx, &lly, &urx, &ury, write_date); if (remote_file) { short_name = FALSE; } else { if ((short_name=IsPrefix(bootDir, eps_fname, &rest))) ++rest; } if (rc != BitmapSuccess) { SetDefaultCursor(mainWindow); ShowCursor(); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_EPS), (short_name ? rest : eps_fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } if (Embed) saveEPSLines = TRUE; if (short_name) { obj_ptr = CreateEPSObj(rest, image_w, image_h, bitmap, image, num_lines, lines, epsf_level, &llx, &lly, &urx, &ury, write_date); } else { obj_ptr = CreateEPSObj(remote_file ? tmp_fname : eps_fname, image_w, image_h, bitmap, image, num_lines, lines, epsf_level, &llx, &lly, &urx, &ury, write_date); } saveEPSLines = FALSE; if (!Embed && lines != NULL) { for (i=0; i < num_lines; i++) { if (lines[i] != NULL) free(lines[i]); } free(lines); } if (strcmp(defaultEPSScalingStr,"1") != 0) { ScaleAnEPSObj(obj_ptr, &defaultEPSScaling); } SetDefaultCursor(mainWindow); ShowCursor(); AddObj(NULL, topObj, obj_ptr); if (psz_fname_spec == NULL) { PlaceTopObj(obj_ptr, NULL, NULL); } else { MoveObj(obj_ptr, 0-obj_ptr->obbox.ltx, 0-obj_ptr->obbox.lty); } SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; if (!importFromLibrary && !remote_file) SetCurImportDir(eps_fname); sprintf(gszMsgBox, TgLoadString(STID_GIVEN_EPS_FILE_IMPORTED), (short_name ? rest : eps_fname)); Msg(gszMsgBox); if (remote_file) unlink(tmp_fname); importingFile = FALSE; } static char gifToXpmCmd[MAXSTRING+1]; static char pngToXpmCmd[MAXSTRING+1]; static char jpegToXpmCmd[MAXSTRING+1]; static char jpegToPpm6Cmd[MAXSTRING+1]; static char pngToPpm6Cmd[MAXSTRING+1]; static char gifToPpm6Cmd[MAXSTRING+1]; static char pbmToXbmCmd[MAXSTRING+1]; static char pgmToXpmCmd[MAXSTRING+1]; static char ppmToXpmCmd[MAXSTRING+1]; static char gifAnimExplodeCmd[MAXSTRING+1]; static char defGifToXpm[]="giftopnm %s | ppmtoxpm"; static char defPngToXpm[]= "pngtopnm %s | pnmdepth 255 | ppmquant 222 | ppmtoxpm"; static char defJpegToXpm[]="djpeg -gif -color 222 %s | giftopnm | ppmtoxpm"; static char defJpegToPpm6[]="djpeg -ppm \"%s\""; static char defPngToPpm6[]="pngtopnm \"%s\""; static char defGifToPpm6[]="giftopnm \"%s\""; static char defPbmToXbm[]="pbmtoxbm %s"; static char defPgmToXpm[]="ppmtoxpm %s"; static char defPpmToXpm[]="ppmquant 222 %s | ppmtoxpm"; static void InitGifToXpm() { static int nInitialized=FALSE; if (!nInitialized) { char *c_ptr; nInitialized = TRUE; if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"GifToXpm")) != NULL) { int count=0; strcpy(gifToXpmCmd, c_ptr); for (c_ptr=strstr(gifToXpmCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "GifToXpm", gifToXpmCmd, defGifToXpm); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(gifToXpmCmd, defGifToXpm); } } else { strcpy(gifToXpmCmd, defGifToXpm); } if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PngToXpm")) != NULL) { int count=0; strcpy(pngToXpmCmd, c_ptr); for (c_ptr=strstr(pngToXpmCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PngToXpm", pngToXpmCmd, defPngToXpm); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(pngToXpmCmd, defPngToXpm); } } else { strcpy(pngToXpmCmd, defPngToXpm); } if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"JpegToXpm")) != NULL) { int count=0; strcpy(jpegToXpmCmd, c_ptr); for (c_ptr=strstr(jpegToXpmCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "JpegToXpm", jpegToXpmCmd, defJpegToXpm); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(jpegToXpmCmd, defJpegToXpm); } } else { strcpy(jpegToXpmCmd, defJpegToXpm); } if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"JpegToPpm6")) != NULL) { int count=0; strcpy(jpegToPpm6Cmd, c_ptr); for (c_ptr=strstr(jpegToPpm6Cmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "JpegToPpm6", jpegToPpm6Cmd, defJpegToPpm6); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(jpegToPpm6Cmd, defJpegToPpm6); } } else { strcpy(jpegToPpm6Cmd, defJpegToPpm6); } if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PngToPpm6")) != NULL) { int count=0; strcpy(pngToPpm6Cmd, c_ptr); for (c_ptr=strstr(pngToPpm6Cmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PngToPpm6", pngToPpm6Cmd, defPngToPpm6); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(pngToPpm6Cmd, defPngToPpm6); } } else { strcpy(pngToPpm6Cmd, defPngToPpm6); } if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"GifToPpm6")) != NULL) { int count=0; strcpy(gifToPpm6Cmd, c_ptr); for (c_ptr=strstr(gifToPpm6Cmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "GifToPpm6", gifToPpm6Cmd, defPngToPpm6); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(gifToPpm6Cmd, defGifToPpm6); } } else { strcpy(gifToPpm6Cmd, defGifToPpm6); } if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PbmToXbm")) != NULL) { int count=0; strcpy(pbmToXbmCmd, c_ptr); for (c_ptr=strstr(pbmToXbmCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PbmToXbm", pbmToXbmCmd, defPbmToXbm); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(pbmToXbmCmd, defPbmToXbm); } } else { strcpy(pbmToXbmCmd, defPbmToXbm); } if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PgmToXpm")) != NULL) { int count=0; strcpy(pgmToXpmCmd, c_ptr); for (c_ptr=strstr(pgmToXpmCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PgmToXpm", pgmToXpmCmd, defPgmToXpm); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(pgmToXpmCmd, defPgmToXpm); } } else { strcpy(pgmToXpmCmd, defPgmToXpm); } if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PpmToXpm")) != NULL) { int count=0; strcpy(ppmToXpmCmd, c_ptr); for (c_ptr=strstr(ppmToXpmCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PpmToXpm", ppmToXpmCmd, defPpmToXpm); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(ppmToXpmCmd, defPpmToXpm); } } else { strcpy(ppmToXpmCmd, defPpmToXpm); } if (mainDisplay != NULL && (c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"GifAnimExplode")) != NULL) { strcpy(gifAnimExplodeCmd, c_ptr); UtilTrimBlanks(gifAnimExplodeCmd); if (strstr(gifAnimExplodeCmd, "%s") != NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "GifAnimExplode", gifAnimExplodeCmd, "gifsicle -eU"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(gifAnimExplodeCmd, "gifsicle -eU"); } } else { strcpy(gifAnimExplodeCmd, "gifsicle -eU"); } } } int ConvertGifToXpm(pszGifPath, pszXpmPath, xpm_path_sz) char *pszGifPath, *pszXpmPath; int xpm_path_sz; { FILE *pFile=NULL, *pPipe=NULL; char *pszCmd=NULL, szBuf[MAXSTRING]; int bytes_read=0, watch_cursor=watchCursorOnMainWindow; InitGifToXpm(); if (MkTempFile(pszXpmPath, xpm_path_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } pszCmd = (char*)malloc( (strlen(gifToXpmCmd)+strlen(pszGifPath)+10)*sizeof(char)); if (pszCmd == NULL) { FailAllocMessage(); return FALSE; } sprintf(pszCmd, gifToXpmCmd, pszGifPath); if (!FindProgramInPath(pszCmd, NULL, FALSE)) { free(pszCmd); return FALSE; } if ((pFile=fopen(pszXpmPath,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), pszXpmPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), pszCmd); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pPipe=(FILE*)popen(pszCmd,"r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), pszCmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); fclose(pFile); unlink(pszXpmPath); return FALSE; } if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; while ((bytes_read=fread(szBuf, sizeof(char), sizeof(szBuf), pPipe)) > 0) { if ((int)fwrite(szBuf, sizeof(char), bytes_read, pFile) <= 0) { writeFileFailed = TRUE; break; } } pclose(pPipe); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); free(pszCmd); fclose(pFile); if (writeFileFailed) { FailToWriteFileMessage(pszXpmPath); unlink(pszXpmPath); return FALSE; } return TRUE; } int ConvertPngToXpm(pszPngPath, pszXpmPath, xpm_path_sz) char *pszPngPath, *pszXpmPath; int xpm_path_sz; { FILE *pFile=NULL, *pPipe=NULL; char *pszCmd=NULL, szBuf[MAXSTRING]; int bytes_read=0, watch_cursor=watchCursorOnMainWindow; InitGifToXpm(); if (*pszXpmPath == '\0' && xpm_path_sz > 0) { if (MkTempFile(pszXpmPath, xpm_path_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } } pszCmd = (char*)malloc( (strlen(pngToXpmCmd)+strlen(pszPngPath)+10)*sizeof(char)); if (pszCmd == NULL) { FailAllocMessage(); return FALSE; } sprintf(pszCmd, pngToXpmCmd, pszPngPath); if (!FindProgramInPath(pszCmd, NULL, FALSE)) { free(pszCmd); return FALSE; } if ((pFile=fopen(pszXpmPath,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), pszXpmPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), pszCmd); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pPipe=(FILE*)popen(pszCmd,"r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), pszCmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); fclose(pFile); unlink(pszXpmPath); return FALSE; } if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; while ((bytes_read=fread(szBuf, sizeof(char), sizeof(szBuf), pPipe)) > 0) { if ((int)fwrite(szBuf, sizeof(char), bytes_read, pFile) <= 0) { writeFileFailed = TRUE; break; } } pclose(pPipe); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); free(pszCmd); fclose(pFile); if (writeFileFailed) { FailToWriteFileMessage(pszXpmPath); unlink(pszXpmPath); return FALSE; } return TRUE; } int ConvertJpegToXpm(pszJpegPath, pszXpmPath, xpm_path_sz) char *pszJpegPath, *pszXpmPath; int xpm_path_sz; { FILE *pFile=NULL, *pPipe=NULL; char *pszCmd=NULL, szBuf[MAXSTRING]; int bytes_read=0, watch_cursor=watchCursorOnMainWindow; InitGifToXpm(); if (*pszXpmPath == '\0' && xpm_path_sz > 0) { if (MkTempFile(pszXpmPath, xpm_path_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } } pszCmd = (char*)malloc( (strlen(jpegToXpmCmd)+strlen(pszJpegPath)+10)*sizeof(char)); if (pszCmd == NULL) { FailAllocMessage(); return FALSE; } sprintf(pszCmd, jpegToXpmCmd, pszJpegPath); if (!FindProgramInPath(pszCmd, NULL, FALSE)) { free(pszCmd); return FALSE; } if ((pFile=fopen(pszXpmPath,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), pszXpmPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), pszCmd); SetStringStatus(gszMsgBox); if (mainDisplay != NULL) XSync(mainDisplay, False); if ((pPipe=(FILE*)popen(pszCmd,"r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), pszCmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); fclose(pFile); unlink(pszXpmPath); return FALSE; } if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; while ((bytes_read=fread(szBuf, sizeof(char), sizeof(szBuf), pPipe)) > 0) { if ((int)fwrite(szBuf, sizeof(char), bytes_read, pFile) <= 0) { writeFileFailed = TRUE; break; } } pclose(pPipe); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); free(pszCmd); fclose(pFile); if (writeFileFailed) { FailToWriteFileMessage(pszXpmPath); unlink(pszXpmPath); return FALSE; } return TRUE; } int ConvertImageFileToPpm6(pszImageFilePath, pszPpm6Path, ppm6_path_sz, format) char *pszImageFilePath, *pszPpm6Path; int ppm6_path_sz, format; { FILE *pFile=NULL, *pPipe=NULL; char *pszCmd=NULL, szBuf[MAXSTRING], *psz_convert_cmd=NULL; int bytes_read=0, watch_cursor=watchCursorOnMainWindow; InitGifToXpm(); if (MkTempFile(pszPpm6Path, ppm6_path_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } switch (format) { case JPEG_FILE: if (PRTGIF && !cmdLineOpenDisplay && *cmdLineJpegToPpm6Cmd != '\0') { psz_convert_cmd = cmdLineJpegToPpm6Cmd; } else { psz_convert_cmd = jpegToPpm6Cmd; } break; case PNG_FILE: psz_convert_cmd = pngToPpm6Cmd; break; case GIF_FILE: psz_convert_cmd = gifToPpm6Cmd; break; } pszCmd = (char*)malloc( (strlen(psz_convert_cmd)+strlen(pszImageFilePath)+10)*sizeof(char)); if (pszCmd == NULL) { FailAllocMessage(); return FALSE; } sprintf(pszCmd, psz_convert_cmd, pszImageFilePath); if (!FindProgramInPath(pszCmd, NULL, FALSE)) { free(pszCmd); return FALSE; } if ((pFile=fopen(pszPpm6Path,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), pszPpm6Path); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), pszCmd); SetStringStatus(gszMsgBox); if (mainDisplay != NULL) XSync(mainDisplay, False); if ((pPipe=(FILE*)popen(pszCmd,"r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), pszCmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); fclose(pFile); unlink(pszPpm6Path); return FALSE; } if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; while ((bytes_read=fread(szBuf, sizeof(char), sizeof(szBuf), pPipe)) > 0) { if ((int)fwrite(szBuf, sizeof(char), bytes_read, pFile) <= 0) { writeFileFailed = TRUE; break; } } pclose(pPipe); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); free(pszCmd); fclose(pFile); if (writeFileFailed) { FailToWriteFileMessage(pszPpm6Path); unlink(pszPpm6Path); return FALSE; } return TRUE; } int ConvertJpegToPpm6(pszJpegPath, pszPpm6Path, ppm6_path_sz) char *pszJpegPath, *pszPpm6Path; int ppm6_path_sz; { return ConvertImageFileToPpm6(pszJpegPath, pszPpm6Path, ppm6_path_sz, JPEG_FILE); } int ConvertPngToPpm6(pszPngPath, pszPpm6Path, ppm6_path_sz) char *pszPngPath, *pszPpm6Path; int ppm6_path_sz; { return ConvertImageFileToPpm6(pszPngPath, pszPpm6Path, ppm6_path_sz, PNG_FILE); } int ConvertGifToPpm6(pszGifPath, pszPpm6Path, ppm6_path_sz) char *pszGifPath, *pszPpm6Path; int ppm6_path_sz; { return ConvertImageFileToPpm6(pszGifPath, pszPpm6Path, ppm6_path_sz, GIF_FILE); } #define IMPORTING_JPEG 0 #define IMPORTING_PPM 1 #define IMPORTING_PNG 2 static int FinishImport(remote_file, remote_tmp_fname, local_fname, which, pn_image_w, pn_image_h) int remote_file, *pn_image_w, *pn_image_h; char *remote_tmp_fname, *local_fname; { char xpm_fname[MAXPATHLENGTH+1], *rest=NULL, *psz_format=NULL; int rc=0, short_name=FALSE, image_w=0, image_h=0; XEvent ev; switch (which) { case IMPORTING_JPEG: psz_format = "JPEG"; break; case IMPORTING_PPM: psz_format = "PPM"; break; case IMPORTING_PNG: psz_format = "PNG"; break; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } if (remote_file) { short_name = FALSE; } else { if ((short_name=IsPrefix(bootDir, local_fname, &rest))) ++rest; } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); if (fullTrueColorMode && HasZlibSupport()) { struct ObjRec *obj_ptr=NULL; struct XPmRec *xpm_ptr=NULL; char ppm6_fname[MAXPATHLENGTH+1]; char deflated_fname[MAXPATHLENGTH+1]; switch (which) { case IMPORTING_JPEG: rc = ConvertJpegToPpm6((remote_file ? remote_tmp_fname : local_fname), ppm6_fname, sizeof(ppm6_fname)); if (rc) { ResetPngHeaderInfo(&gPngHeaderInfo); obj_ptr = CreatePpmTrueObjFromFile(ppm6_fname); unlink(ppm6_fname); } if (obj_ptr == NULL) { RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (remote_file) unlink(remote_tmp_fname); importingFile = FALSE; return FALSE; } xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_JPEG_COMPRESS; xpm_ptr->ppm_data = ReadFileIntoBuf( (remote_file ? remote_tmp_fname : local_fname), &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; break; case IMPORTING_PPM: ResetPngHeaderInfo(&gPngHeaderInfo); obj_ptr = CreatePpmTrueObjFromFile(remote_file ? remote_tmp_fname : local_fname); if (obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile((remote_file ? remote_tmp_fname : local_fname), deflated_fname)) { } else { if (obj_ptr != NULL) FreeObj(obj_ptr); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (remote_file) unlink(remote_tmp_fname); importingFile = FALSE; return FALSE; } xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; unlink(deflated_fname); break; case IMPORTING_PNG: rc = ConvertPngToPpm6((remote_file ? remote_tmp_fname : local_fname), ppm6_fname, sizeof(ppm6_fname)); if (rc) { ResetPngHeaderInfo(&gPngHeaderInfo); if (PngFileGetTransColorInit(&gPngHeaderInfo, (remote_file ? remote_tmp_fname : local_fname)) && PngFileGetTransColor(&gPngHeaderInfo)) { } obj_ptr = CreatePpmTrueObjFromFile(ppm6_fname); } if (obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile(ppm6_fname, deflated_fname)) { /* nothing to do here */ } else { unlink(ppm6_fname); if (obj_ptr != NULL) FreeObj(obj_ptr); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (remote_file) unlink(remote_tmp_fname); importingFile = FALSE; return FALSE; } unlink(ppm6_fname); xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; if (gPngHeaderInfo.valid && gPngHeaderInfo.trans_color_pixel_found) { xpm_ptr->has_transparent_color = TRUE; xpm_ptr->transparent_color[0] = gPngHeaderInfo.trans_color_pixel_red; xpm_ptr->transparent_color[1] = gPngHeaderInfo.trans_color_pixel_green; xpm_ptr->transparent_color[2] = gPngHeaderInfo.trans_color_pixel_blue; } unlink(deflated_fname); break; } RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (obj_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_IMPORT_GIVEN_TYPE_FILE), psz_format, (short_name ? rest : local_fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (remote_file) unlink(remote_tmp_fname); importingFile = FALSE; return FALSE; } AddObj(NULL, topObj, obj_ptr); PlaceTopObj(obj_ptr, NULL, NULL); SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; if (!importFromLibrary && !remote_file) { SetCurImportDir(local_fname); } if (pn_image_w != NULL) *pn_image_w = xpm_ptr->image_w; if (pn_image_h != NULL) *pn_image_h = xpm_ptr->image_h; return TRUE; } *xpm_fname = '\0'; switch (which) { case IMPORTING_JPEG: rc = ConvertJpegToXpm((remote_file ? remote_tmp_fname : local_fname), xpm_fname, sizeof(xpm_fname)); break; case IMPORTING_PPM: rc = ConvertPpmToXpm((remote_file ? remote_tmp_fname : local_fname), xpm_fname, sizeof(xpm_fname)); break; case IMPORTING_PNG: rc = ConvertPngToXpm((remote_file ? remote_tmp_fname : local_fname), xpm_fname, sizeof(xpm_fname)); break; } RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (!rc) { if (remote_file) unlink(remote_tmp_fname); importingFile = FALSE; return FALSE; } if (!ImportGivenXPixmapFile(FALSE, NULL, xpm_fname, INVALID, INVALID, &image_w, &image_h)) { sprintf(gszMsgBox, TgLoadString(STID_CANT_IMPORT_GIVEN_TYPE_FILE), psz_format, (short_name ? rest : local_fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(xpm_fname); if (remote_file) unlink(remote_tmp_fname); importingFile = FALSE; return FALSE; } unlink(xpm_fname); return TRUE; } void ImportPNGFile() { char *rest=NULL, tmp_fname[MAXPATHLENGTH+1]; char szPngPath[MAXPATHLENGTH+1]; int short_name=FALSE, image_w=0, image_h=0, remote_file=FALSE; MakeQuiescent(); importingFile = TRUE; *szPngPath = *tmp_fname = '\0'; if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_PNG_FILE_TO_IMPORT), "png", name, path) == INVALID) { importingFile = FALSE; return; } sprintf(szPngPath, "%s%c%s", path, DIR_SEP, name); } else if (SelectFileNameToImport(TgLoadString(STID_SEL_PNG_FILE_TO_IMPORT), "png", szPngPath) == INVALID) { importingFile = FALSE; return; } else if (FileIsRemote(szPngPath)) { int is_html=FALSE; if (!DownloadRemoteFile(szPngPath, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { importingFile = FALSE; return; } remote_file = TRUE; } if (!FinishImport(remote_file, tmp_fname, szPngPath, IMPORTING_PNG, &image_w, &image_h)) { if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } if (!importFromLibrary && !remote_file) SetCurImportDir(szPngPath); sprintf(gszMsgBox, TgLoadString(STID_GIVEN_PNG_SIZE_FILE_IMPORTED), image_w, image_h, (short_name ? rest : szPngPath)); Msg(gszMsgBox); if (remote_file) unlink(tmp_fname); importingFile = FALSE; } void ImportJPEGFile(Embed, psz_fname_spec) int Embed; char *psz_fname_spec; { char *rest=NULL, tmp_fname[MAXPATHLENGTH+1]; char szJpegPath[MAXPATHLENGTH+1]; int short_name=FALSE, image_w=0, image_h=0, remote_file=FALSE; MakeQuiescent(); importingFile = TRUE; *szJpegPath = *tmp_fname = '\0'; if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_JPEG_FILE_TO_IMPORT), "jpeg", name, path) == INVALID) { importingFile = FALSE; return; } sprintf(szJpegPath, "%s%c%s", path, DIR_SEP, name); } else if (SelectFileNameToImport(TgLoadString(Embed ? STID_SEL_JPEG_FILE_TO_IMPORT : STID_SEL_JPEG_FILE_TO_LINKTO), "jpeg", szJpegPath) == INVALID) { importingFile = FALSE; return; } else if (FileIsRemote(szJpegPath)) { int is_html=FALSE; if (!Embed) { sprintf(gszMsgBox, TgLoadString(STID_IMPORT_REM_FILE_EMBED_INSTEAD), "JPEG", "JPEG"); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) != MB_ID_YES) { importingFile = FALSE; return; } Embed = TRUE; } if (!DownloadRemoteFile(szJpegPath, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { importingFile = FALSE; return; } remote_file = TRUE; } if (!FinishImport(remote_file, tmp_fname, szJpegPath, IMPORTING_JPEG, &image_w, &image_h)) { if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } if (!Embed) { topObj->detail.xpm->real_type = XPM_JPEG; topObj->detail.xpm->linked_jpeg = TRUE; topObj->detail.xpm->filename = UtilStrDup(short_name ? rest : szJpegPath); } if (!importFromLibrary && !remote_file) SetCurImportDir(szJpegPath); sprintf(gszMsgBox, TgLoadString(STID_GIVEN_JPEG_SIZE_FILE_IMPORTED), image_w, image_h, (short_name ? rest : szJpegPath)); Msg(gszMsgBox); if (remote_file) unlink(tmp_fname); importingFile = FALSE; } void ImportGIFFile() { char file_name[MAXPATHLENGTH+1], *rest=NULL, tmp_fname[MAXPATHLENGTH+1]; char szGifPath[MAXPATHLENGTH+1]; int rc, short_name=FALSE, image_w=0, image_h=0, remote_file=FALSE; XEvent ev; MakeQuiescent(); importingFile = TRUE; *szGifPath = *tmp_fname = *file_name = '\0'; if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_GIF_FILE_TO_IMPORT), "gif", name, path) == INVALID) { importingFile = FALSE; return; } sprintf(szGifPath, "%s%c%s", path, DIR_SEP, name); } else if (SelectFileNameToImport(TgLoadString(STID_SEL_GIF_FILE_TO_IMPORT), "gif", szGifPath) == INVALID) { importingFile = FALSE; return; } else if (FileIsRemote(szGifPath)) { int is_html=FALSE; if (!DownloadRemoteFile(szGifPath, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { importingFile = FALSE; return; } remote_file = TRUE; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); if (fullTrueColorMode && HasZlibSupport()) { struct ObjRec *obj_ptr=NULL; struct XPmRec *xpm_ptr=NULL; char ppm6_fname[MAXPATHLENGTH+1]; char deflated_fname[MAXPATHLENGTH+1]; rc = ConvertGifToPpm6((remote_file ? tmp_fname : szGifPath), ppm6_fname, sizeof(ppm6_fname)); if (rc) { ResetPngHeaderInfo(&gPngHeaderInfo); if (PngFileGetTransColorInit(&gPngHeaderInfo, (remote_file ? tmp_fname : szGifPath)) && PngFileGetTransColor(&gPngHeaderInfo)) { } obj_ptr = CreatePpmTrueObjFromFile(ppm6_fname); } if (obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile(ppm6_fname, deflated_fname)) { /* nothing to do here */ } else { unlink(ppm6_fname); if (obj_ptr != NULL) FreeObj(obj_ptr); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } unlink(ppm6_fname); xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; if (gPngHeaderInfo.valid && gPngHeaderInfo.trans_color_pixel_found) { xpm_ptr->has_transparent_color = TRUE; xpm_ptr->transparent_color[0] = gPngHeaderInfo.trans_color_pixel_red; xpm_ptr->transparent_color[1] = gPngHeaderInfo.trans_color_pixel_green; xpm_ptr->transparent_color[2] = gPngHeaderInfo.trans_color_pixel_blue; } unlink(deflated_fname); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (obj_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_GIF), (short_name ? rest : szGifPath)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } AddObj(NULL, topObj, obj_ptr); PlaceTopObj(obj_ptr, NULL, NULL); SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; if (!importFromLibrary && !remote_file) { SetCurImportDir(szGifPath); } sprintf(gszMsgBox, TgLoadString(STID_GIVEN_GIF_SIZE_FILE_IMPORTED), xpm_ptr->image_w, xpm_ptr->image_h, (short_name ? rest : szGifPath)); Msg(gszMsgBox); return; } *file_name = '\0'; rc = ConvertGifToXpm((remote_file ? tmp_fname : szGifPath), file_name, sizeof(file_name)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (!rc) { if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } if (remote_file) { short_name = FALSE; } else { if ((short_name=IsPrefix(bootDir, szGifPath, &rest))) ++rest; } if (!ImportGivenXPixmapFile(FALSE, NULL, file_name, INVALID, INVALID, &image_w, &image_h)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_GIF), (short_name ? rest : szGifPath)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(file_name); if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } unlink(file_name); if (!importFromLibrary && !remote_file) SetCurImportDir(szGifPath); sprintf(gszMsgBox, TgLoadString(STID_GIVEN_GIF_SIZE_FILE_IMPORTED), image_w, image_h, (short_name ? rest : szGifPath)); Msg(gszMsgBox); if (remote_file) unlink(tmp_fname); importingFile = FALSE; } int ConvertPbmToXbm(pszPbmPath, pszXbmPath, xbm_path_sz) char *pszPbmPath, *pszXbmPath; int xbm_path_sz; { FILE *pFile=NULL, *pPipe=NULL; char *pszCmd=NULL, szBuf[MAXSTRING]; int bytes_read=0, watch_cursor=watchCursorOnMainWindow;; InitGifToXpm(); if (MkTempFile(pszXbmPath, xbm_path_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } pszCmd = (char*)malloc( (strlen(pbmToXbmCmd)+strlen(pszPbmPath)+10)*sizeof(char)); if (pszCmd == NULL) { FailAllocMessage(); return FALSE; } sprintf(pszCmd, pbmToXbmCmd, pszPbmPath); if (!FindProgramInPath(pszCmd, NULL, FALSE)) { free(pszCmd); return FALSE; } if ((pFile=fopen(pszXbmPath,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), pszXbmPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), pszCmd); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pPipe=(FILE*)popen(pszCmd,"r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), pszCmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); fclose(pFile); unlink(pszXbmPath); return FALSE; } if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; while ((bytes_read=fread(szBuf, sizeof(char), sizeof(szBuf), pPipe)) > 0) { if ((int)fwrite(szBuf, sizeof(char), bytes_read, pFile) <= 0) { writeFileFailed = TRUE; break; } } pclose(pPipe); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); free(pszCmd); fclose(pFile); if (writeFileFailed) { FailToWriteFileMessage(pszXbmPath); unlink(pszXbmPath); return FALSE; } return TRUE; } void ImportPBMFile() { char file_name[MAXPATHLENGTH+1], *rest=NULL, tmp_fname[MAXPATHLENGTH+1]; char szPbmPath[MAXPATHLENGTH+1]; int rc, short_name=FALSE, image_w=0, image_h=0, remote_file=FALSE; XEvent ev; MakeQuiescent(); importingFile = TRUE; *szPbmPath = *tmp_fname = '\0'; if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_PBM_FILE_TO_IMPORT), "pbm", name, path) == INVALID) { importingFile = FALSE; return; } sprintf(szPbmPath, "%s%c%s", path, DIR_SEP, name); } else if (SelectFileNameToImport(TgLoadString(STID_SEL_PBM_FILE_TO_IMPORT), "pbm", szPbmPath) == INVALID) { importingFile = FALSE; return; } else if (FileIsRemote(szPbmPath)) { int is_html=FALSE; if (!DownloadRemoteFile(szPbmPath, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { importingFile = FALSE; return; } remote_file = TRUE; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); rc = ConvertPbmToXbm((remote_file ? tmp_fname : szPbmPath), file_name, sizeof(file_name)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (!rc) { if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } if (remote_file) { short_name = FALSE; } else { if ((short_name=IsPrefix(bootDir, szPbmPath, &rest))) ++rest; } if (!ImportGivenXBitmapFile(FALSE, NULL, file_name, INVALID, INVALID, &image_w, &image_h)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_PBM), (short_name ? rest : szPbmPath)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(file_name); if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } unlink(file_name); if (!importFromLibrary && !remote_file) SetCurImportDir(szPbmPath); sprintf(gszMsgBox, TgLoadString(STID_GIVEN_PBM_SIZE_FILE_IMPORTED), image_w, image_h, (short_name ? rest : szPbmPath)); Msg(gszMsgBox); if (remote_file) unlink(tmp_fname); importingFile = FALSE; } int ConvertPgmToXpm(pszPgmPath, pszXpmPath, xpm_path_sz) char *pszPgmPath, *pszXpmPath; int xpm_path_sz; { FILE *pFile=NULL, *pPipe=NULL; char *pszCmd=NULL, szBuf[MAXSTRING]; int bytes_read=0, watch_cursor=watchCursorOnMainWindow; InitGifToXpm(); if (MkTempFile(pszXpmPath, xpm_path_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } pszCmd = (char*)malloc( (strlen(pgmToXpmCmd)+strlen(pszPgmPath)+10)*sizeof(char)); if (pszCmd == NULL) { FailAllocMessage(); return FALSE; } sprintf(pszCmd, pgmToXpmCmd, pszPgmPath); if (!FindProgramInPath(pszCmd, NULL, FALSE)) { free(pszCmd); return FALSE; } if ((pFile=fopen(pszXpmPath,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), pszXpmPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), pszCmd); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pPipe=(FILE*)popen(pszCmd,"r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), pszCmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); fclose(pFile); unlink(pszXpmPath); return FALSE; } if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; while ((bytes_read=fread(szBuf, sizeof(char), sizeof(szBuf), pPipe)) > 0) { if ((int)fwrite(szBuf, sizeof(char), bytes_read, pFile) <= 0) { writeFileFailed = TRUE; break; } } pclose(pPipe); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); free(pszCmd); fclose(pFile); if (writeFileFailed) { FailToWriteFileMessage(pszXpmPath); unlink(pszXpmPath); return FALSE; } return TRUE; } void ImportPGMFile() { char file_name[MAXPATHLENGTH+1], *rest=NULL, tmp_fname[MAXPATHLENGTH+1]; char szPgmPath[MAXPATHLENGTH+1]; int rc, short_name=FALSE, image_w=0, image_h=0, remote_file=FALSE; XEvent ev; MakeQuiescent(); importingFile = TRUE; *szPgmPath = *tmp_fname = '\0'; if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_PGM_FILE_TO_IMPORT), "pgm", name, path) == INVALID) { importingFile = FALSE; return; } sprintf(szPgmPath, "%s%c%s", path, DIR_SEP, name); } else if (SelectFileNameToImport(TgLoadString(STID_SEL_PGM_FILE_TO_IMPORT), "pgm", szPgmPath) == INVALID) { importingFile = FALSE; return; } else if (FileIsRemote(szPgmPath)) { int is_html=FALSE; if (!DownloadRemoteFile(szPgmPath, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { importingFile = FALSE; return; } remote_file = TRUE; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); rc = ConvertPgmToXpm((remote_file ? tmp_fname : szPgmPath), file_name, sizeof(file_name)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (!rc) { if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } if (remote_file) { short_name = FALSE; } else { if ((short_name=IsPrefix(bootDir, szPgmPath, &rest))) ++rest; } if (!ImportGivenXPixmapFile(FALSE, NULL, file_name, INVALID, INVALID, &image_w, &image_h)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_PGM), (short_name ? rest : szPgmPath)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(file_name); if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } unlink(file_name); if (!importFromLibrary && !remote_file) SetCurImportDir(szPgmPath); sprintf(gszMsgBox, TgLoadString(STID_GIVEN_PGM_SIZE_FILE_IMPORTED), image_w, image_h, (short_name ? rest : szPgmPath)); Msg(gszMsgBox); if (remote_file) unlink(tmp_fname); importingFile = FALSE; } int ConvertPpmToXpm(pszPpmPath, pszXpmPath, xpm_path_sz) char *pszPpmPath, *pszXpmPath; int xpm_path_sz; { FILE *pFile=NULL, *pPipe=NULL; char *pszCmd=NULL, szBuf[MAXSTRING]; int bytes_read=0, watch_cursor=watchCursorOnMainWindow; InitGifToXpm(); if (MkTempFile(pszXpmPath, xpm_path_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } pszCmd = (char*)malloc( (strlen(ppmToXpmCmd)+strlen(pszPpmPath)+10)*sizeof(char)); if (pszCmd == NULL) { FailAllocMessage(); return FALSE; } sprintf(pszCmd, ppmToXpmCmd, pszPpmPath); if (!FindProgramInPath(pszCmd, NULL, FALSE)) { free(pszCmd); return FALSE; } if ((pFile=fopen(pszXpmPath,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), pszXpmPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), pszCmd); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pPipe=(FILE*)popen(pszCmd,"r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), pszCmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); fclose(pFile); unlink(pszXpmPath); return FALSE; } if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; while ((bytes_read=fread(szBuf, sizeof(char), sizeof(szBuf), pPipe)) > 0) { if ((int)fwrite(szBuf, sizeof(char), bytes_read, pFile) <= 0) { writeFileFailed = TRUE; break; } } pclose(pPipe); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); free(pszCmd); fclose(pFile); if (writeFileFailed) { FailToWriteFileMessage(pszXpmPath); unlink(pszXpmPath); return FALSE; } return TRUE; } void ImportPPMFile() { char *rest=NULL, tmp_fname[MAXPATHLENGTH+1]; char szPpmPath[MAXPATHLENGTH+1]; int short_name=FALSE, image_w=0, image_h=0, remote_file=FALSE; MakeQuiescent(); importingFile = TRUE; *szPpmPath = *tmp_fname = '\0'; if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_PPM_FILE_TO_IMPORT), "ppm", name, path) == INVALID) { importingFile = FALSE; return; } sprintf(szPpmPath, "%s%c%s", path, DIR_SEP, name); } else if (SelectFileNameToImport(TgLoadString(STID_SEL_PPM_FILE_TO_IMPORT), "ppm", szPpmPath) == INVALID) { importingFile = FALSE; return; } else if (FileIsRemote(szPpmPath)) { int is_html=FALSE; if (!DownloadRemoteFile(szPpmPath, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { importingFile = FALSE; return; } remote_file = TRUE; } if (!FinishImport(remote_file, tmp_fname, szPpmPath, IMPORTING_PPM, &image_w, &image_h)) { if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } if (!importFromLibrary && !remote_file) SetCurImportDir(szPpmPath); sprintf(gszMsgBox, TgLoadString(STID_GIVEN_PPM_SIZE_FILE_IMPORTED), image_w, image_h, (short_name ? rest : szPpmPath)); Msg(gszMsgBox); if (remote_file) unlink(tmp_fname); importingFile = FALSE; } DspList *ImportFilterListing(pnEntries) int *pnEntries; { int i; struct ImportInfoRec *pii=topImportInfo; DspList *pdl, *dsp_ptr; if (gnMaxImportFilters == 0) return NULL; pdl = (DspList*)malloc(gnMaxImportFilters*sizeof(DspList)); if (pdl == NULL) { FailAllocMessage(); return NULL; } for (i=0, dsp_ptr=pdl; i < gnMaxImportFilters; i++, dsp_ptr++) { sprintf(gszMsgBox, "%s (%s)", pii->name, pii->ext); UtilStrCpyN(dsp_ptr->itemstr, sizeof(dsp_ptr->itemstr), gszMsgBox); UtilStrCpyN(dsp_ptr->pathstr, sizeof(dsp_ptr->pathstr), pii->cmd); dsp_ptr->directory = FALSE; dsp_ptr->next = ((i == gnMaxImportFilters-1) ? NULL : (&dsp_ptr[1])); pii = pii->next; } if (pnEntries != NULL) *pnEntries = gnMaxImportFilters; return pdl; } static int ChooseAnImportFilter(top_str, entries, num_entries) char *top_str, **entries; int num_entries; { char win_name[128]; int selected_index=INVALID; ResetNamesInfo(); NamesSetTitle(top_str); NamesAddButton(TgLoadCachedString(CSTID_OK), BUTTON_OK); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); NamesSetEntries(NULL, entries, num_entries, NULL, TRUE, INVALID, 0); NamesSetStyle(NAMES_COMPLEX_SELECT_NAME, NAMES_LOOP_ONCE); sprintf(win_name, "%s - %s", TOOL_NAME, top_str); if (Names(win_name, &selected_index, NULL, 0, NULL) == BUTTON_OK) { return selected_index; } return INVALID; } static int SelectAnImportFilter(pszSelected) char *pszSelected; { int num_entries=0, index=0; DspList *dsp_ptr=ImportFilterListing(&num_entries); char **entries; if (pszSelected != NULL) *pszSelected = '\0'; if (dsp_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_ANY_IMP_FLTR_SPEC), TOOL_NAME, "MaxImportFilters", TOOL_NAME, "ImportFilter#"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return INVALID; } entries = MakeNameDspItemArray(num_entries, dsp_ptr); if (entries == NULL) { free(dsp_ptr); return INVALID; } if ((index=ChooseAnImportFilter(TgLoadString(STID_SEL_AN_IMPORT_FILTER), entries, num_entries)) == INVALID) { if (pszSelected != NULL) *pszSelected = '\0'; } else { if (pszSelected != NULL) { strcpy(pszSelected, entries[index]); } } free(*entries); free(entries); free(dsp_ptr); return index; } static int ConvertAnyToXpm(pii, pszAnyPath, pszXpmPath, xpm_path_sz) struct ImportInfoRec *pii; char *pszAnyPath, *pszXpmPath; int xpm_path_sz; { FILE *pFile=NULL, *pPipe=NULL; char *pszCmd=NULL, szBuf[MAXSTRING]; int bytes_read=0, watch_cursor=watchCursorOnMainWindow; if (MkTempFile(pszXpmPath, xpm_path_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } pszCmd = (char*)malloc((strlen(pii->cmd)+strlen(pszAnyPath)+10)*sizeof(char)); if (pszCmd == NULL) { FailAllocMessage(); return FALSE; } sprintf(pszCmd, pii->cmd, pszAnyPath); if (!FindProgramInPath(pszCmd, NULL, FALSE)) { free(pszCmd); return FALSE; } if ((pFile=fopen(pszXpmPath,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), pszXpmPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), pszCmd); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pPipe=(FILE*)popen(pszCmd,"r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), pszCmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); fclose(pFile); unlink(pszXpmPath); return FALSE; } if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; while ((bytes_read=fread(szBuf, sizeof(char), sizeof(szBuf), pPipe)) > 0) { if ((int)fwrite(szBuf, sizeof(char), bytes_read, pFile) <= 0) { writeFileFailed = TRUE; break; } } pclose(pPipe); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); free(pszCmd); fclose(pFile); if (writeFileFailed) { FailToWriteFileMessage(pszXpmPath); unlink(pszXpmPath); return FALSE; } return TRUE; } static int gnEnableFailedImportMsgBox=TRUE; int GetEnableFailedImportMsgBox() { return gnEnableFailedImportMsgBox; } int SetEnableFailedImportMsgBox(int enable) { int saved_enable_failed_import_msgbox=gnEnableFailedImportMsgBox; gnEnableFailedImportMsgBox = enable; return saved_enable_failed_import_msgbox; } static int ReadFourBytes(psz_path, magic_buf, magic_buf_sz) char *psz_path, *magic_buf; int magic_buf_sz; { FILE *fp=fopen(psz_path, "r"); int rc=TRUE; if (fp == NULL) { return FailToOpenMessage(psz_path, "r", NULL); } if (fread(magic_buf, sizeof(char), magic_buf_sz, fp) != magic_buf_sz) { rc = FALSE; } fclose(fp); return rc; } static int DoImportOtherFile(pii, psz_path) struct ImportInfoRec *pii; char *psz_path; { char szTop[MAXSTRING+1], tmp_fname[MAXPATHLENGTH+1]; char szOtherPath[MAXPATHLENGTH+1], szXpmPath[MAXPATHLENGTH+1], magic_buf[4]; int rc, ncolors, chars_per_pixel, *pixels=NULL, short_name=FALSE; int first_pixel_is_bg, image_w, image_h, w, h, remote_file=FALSE, ppm=FALSE; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL, *rest=NULL; struct ObjRec *obj_ptr=NULL; XEvent ev; importingFile = TRUE; *szOtherPath = *tmp_fname = '\0'; if (psz_path != NULL) { UtilStrCpyN(szOtherPath, sizeof(szOtherPath), psz_path); } else { MakeQuiescent(); sprintf(szTop, TgLoadString(STID_SEL_A_TYPE_FILE_TO_IMPORT), pii->name); if (importFromLibrary) { char name[MAXSTRING+1], dir_name[MAXSTRING+1]; if (SelectFromLibrary(szTop, pii->ext, name, dir_name) == INVALID) { importingFile = FALSE; return FALSE; } sprintf(szOtherPath, "%s%c%s", dir_name, DIR_SEP, name); } else if (SelectFileNameToImport(szTop, pii->ext, szOtherPath) == INVALID) { importingFile = FALSE; return FALSE; } else if (FileIsRemote(szOtherPath)) { int is_html=FALSE; if (!DownloadRemoteFile(szOtherPath, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { importingFile = FALSE; return FALSE; } remote_file = TRUE; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); rc = ConvertAnyToXpm(pii, (remote_file ? tmp_fname : szOtherPath), szXpmPath, sizeof(szXpmPath)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (!rc) return FALSE; if (ReadFourBytes(szXpmPath, magic_buf, sizeof(magic_buf))) { if (magic_buf[0] == 'P' && (magic_buf[1] == '3' || magic_buf[1] == '5' || magic_buf[1] == '6')) { ppm = TRUE; } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if (ppm) { char deflated_fname[MAXPATHLENGTH+1]; ResetPngHeaderInfo(&gPngHeaderInfo); obj_ptr = CreatePpmTrueObjFromFile(szXpmPath); if (obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile(szXpmPath, deflated_fname)) { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; unlink(deflated_fname); rc = BitmapSuccess; } else { rc = BitmapFileInvalid; } } else { rc = MyReadPixmapFile(szXpmPath, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); } SetDefaultCursor(mainWindow); ShowCursor(); } else { rc = BitmapFileInvalid; } if (remote_file) { short_name = FALSE; } else { if ((short_name=IsPrefix(bootDir, szOtherPath, &rest))) ++rest; } if (rc != BitmapSuccess) { sprintf(gszMsgBox, TgLoadString(STID_CANT_IMPORT_GIVEN_TYPE_FILE), pii->name, (short_name ? rest : szOtherPath)); if (gnEnableFailedImportMsgBox) { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } unlink(szXpmPath); if (remote_file) unlink(tmp_fname); importingFile = FALSE; return FALSE; } unlink(szXpmPath); if (!ppm) { obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); } AddObj(NULL, topObj, obj_ptr); if (psz_path == NULL) { PlaceTopObj(obj_ptr, NULL, NULL); SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; if (!importFromLibrary && !remote_file) SetCurImportDir(szOtherPath); sprintf(gszMsgBox, TgLoadString(STID_GIVEN_TYPE_SIZE_FILE_IMPORTED), pii->name, image_w, image_h, (short_name ? rest : szOtherPath)); Msg(gszMsgBox); } if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } if (remote_file) unlink(tmp_fname); importingFile = FALSE; return TRUE; } void ImportOtherFile() { int i, index; struct ImportInfoRec *pii; XEvent ev; if ((index=SelectAnImportFilter(NULL)) == INVALID) { return; } for (i=0, pii=topImportInfo; i < index && pii != NULL; i++, pii=pii->next) { } if (pii == NULL) return; XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } DoImportOtherFile(pii, NULL); } void ImportOtherFileType(pszName) char *pszName; { char *paren_ptr=(pszName == NULL ? NULL : strchr(pszName, ')')); struct ImportInfoRec *pii; if (paren_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_FMT_IN_SHORTCUT_SPEC), "ImportOtherFileType", (pszName == NULL ? "" : pszName)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } *paren_ptr = '\0'; for (pii=topImportInfo; pii != NULL; pii=pii->next) { if (strcmp(pii->name, pszName) == 0) { break; } } if (pii == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_NAMED_IMP_FLTR), pszName); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } DoImportOtherFile(pii, NULL); } int ImportSpecifiedFileType(psz_path, psz_filter) char *psz_path, *psz_filter; { struct ImportInfoRec *pii=NULL; for (pii=topImportInfo; pii != NULL; pii=pii->next) { if (strcmp(pii->name, psz_filter) == 0) { break; } } if (pii == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_NAMED_IMP_FLTR), psz_filter); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return DoImportOtherFile(pii, psz_path); } int ConvertOtherToXpm(pszFile, pszFormat, pszXpmPath, xpm_path_sz) char *pszFile, *pszFormat, *pszXpmPath; int xpm_path_sz; { struct ImportInfoRec *pii=NULL; for (pii=topImportInfo; pii != NULL; pii=pii->next) { if (strcmp(pii->name, pszFormat) == 0) { break; } } if (pii == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_NAMED_IMP_FLTR), pszFormat); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return ConvertAnyToXpm(pii, pszFile, pszXpmPath, xpm_path_sz); } void ImportGIFToXPixmapDeck() { char szTop[MAXSTRING+1], cmd[MAXSTRING<<1], part_fname_format[MAXSTRING]; char gif_fname[MAXPATHLENGTH+1], name[MAXSTRING], tmp_fname[MAXPATHLENGTH+1]; int i=0, import_other_index=0, rc=0, placed=FALSE; int ltx=0, lty=0, rbx=0, rby=0, remote_file=FALSE, real_remote_file=FALSE; XEvent ev; struct ImportInfoRec ii; struct ObjRec *saved_top_obj=topObj, *saved_bot_obj=botObj; struct AttrRec *exec_attr=NULL; MakeQuiescent(); memset(&ii, 0, sizeof(struct ImportInfoRec)); /* pick an animated GIF file */ sprintf(szTop, TgLoadString(STID_SEL_ANIM_GIF_FILE_TO_IMPORT)); importingFile = TRUE; *gif_fname = *tmp_fname = '\0'; if (importFromLibrary) { char name[MAXSTRING+1], dir_name[MAXSTRING+1]; if (SelectFromLibrary(szTop, "gif", name, dir_name) == INVALID) { importingFile = FALSE; return; } sprintf(gif_fname, "%s%c%s", dir_name, DIR_SEP, name); } else if (SelectFileNameToImport(szTop, "gif", gif_fname) == INVALID) { importingFile = FALSE; return; } else if (FileIsRemote(gif_fname)) { int is_html=FALSE; if (!DownloadRemoteFile(gif_fname, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { importingFile = FALSE; return; } remote_file = real_remote_file = TRUE; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } if (!remote_file) { if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { importingFile = FALSE; return; } if (UtilCopyFile(gif_fname, tmp_fname) != TG_REMOTE_STATUS_OK) { sprintf(gszMsgBox, TgLoadString(STID_CANT_CREATE_NAMED_TMP_FILE), tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); importingFile = FALSE; return; } remote_file = TRUE; } /* explode the animated GIF file into parts */ InitGifToXpm(); sprintf(cmd, "cd %s; %s %s", tmpDir, gifAnimExplodeCmd, (remote_file ? tmp_fname : gif_fname)); SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = ExecuteCmd(cmd, FALSE); SetDefaultCursor(mainWindow); ShowCursor(); if (!rc) { sprintf(gszMsgBox, TgLoadString(STID_CANT_EXEC_CMD_IMPORT_ANIM_GIF), cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } /* determine how many to import */ strcpy(name, tmp_fname); /* pick a GIF import filter */ if (gnMaxImportFilters > 0) { struct ImportInfoRec *pii=NULL; switch (MsgBox(TgLoadString(STID_Q_LIKE_TO_USE_AN_IMP_FLTR_GIF), TOOL_NAME, YNC_MB)) { case MB_ID_YES: if ((import_other_index=SelectAnImportFilter(NULL)) == INVALID) { if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } for (i=0, pii=topImportInfo; i < import_other_index && pii != NULL; i++, pii=pii->next) { } if (pii == NULL) { if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } memcpy(&ii, pii, sizeof(struct ImportInfoRec)); ii.name = NULL; ii.next = NULL; break; case MB_ID_NO: ii.ext = "gif"; ii.cmd = gifToXpmCmd; break; case MB_ID_CANCEL: if (remote_file) unlink(tmp_fname); importingFile = FALSE; return; } } else { ii.ext = "gif"; ii.cmd = gifToXpmCmd; } curPage->top = curPage->bot = topObj = botObj = NULL; /* import the GIF parts */ strcpy(part_fname_format, "%s.%1d"); SaveStatusStrings(); SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); for (i=0; ; i++) { char part_fname[MAXPATHLENGTH], xpm_fname[MAXPATHLENGTH]; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL; int image_w=0, image_h=0, w=0, h=0, ncolors=0, chars_per_pixel=0; int first_pixel_is_bg=FALSE, *pixels=NULL; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; struct ObjRec *obj_ptr=NULL; struct SelRec *sel_ptr=NULL; *xpm_fname = '\0'; sprintf(part_fname, part_fname_format, name, i); if (i == 0) { if (!UtilPathExists(part_fname)) { strcpy(part_fname_format, "%s.%03d"); sprintf(part_fname, part_fname_format, name, i); if (!UtilPathExists(part_fname)) { if (i == 0 && !FindProgramInPath(gifAnimExplodeCmd, NULL, TRUE)) { char *psz=strchr(gifAnimExplodeCmd, ' '); if (psz != NULL) *psz = '\0'; sprintf(gszMsgBox, TgLoadString(STID_CANT_IMP_ANIM_GIF_DIR_OR_PATH), part_fname, tmpDir, gifAnimExplodeCmd); if (psz != NULL) *psz = ' '; MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_IMP_ANIM_GIF_TMP_DIR), part_fname, tmpDir); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } break; } } } else if (!UtilPathExists(part_fname)) { /* got all the GIF parts */ break; } rc = ConvertAnyToXpm(&ii, part_fname, xpm_fname, sizeof(xpm_fname)); if (!rc) { unlink(part_fname); break; } unlink(part_fname); rc = MyReadPixmapFile(xpm_fname, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); if (rc != BitmapSuccess) { sprintf(gszMsgBox, TgLoadString(STID_CANT_IMP_GIVEN_ANIM_GIF), part_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(xpm_fname); break; } unlink(xpm_fname); obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); AddObj(botObj, NULL, obj_ptr); if (!placed) { PlaceTopObj(obj_ptr, NULL, NULL); placed = TRUE; ltx = obj_ptr->bbox.ltx; lty = obj_ptr->bbox.lty; rbx = obj_ptr->bbox.rbx; rby = obj_ptr->bbox.rby; } else { MoveObj(obj_ptr, ltx-obj_ptr->bbox.ltx, lty-obj_ptr->bbox.lty); if (obj_ptr->bbox.rbx > rbx) rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > rby) rby = obj_ptr->bbox.rby; } DrawObj(drawWindow, obj_ptr); sel_ptr = SelectThisObject(obj_ptr); AddSel(botSel, NULL, sel_ptr); } SetDefaultCursor(mainWindow); ShowCursor(); if (remote_file) unlink(tmp_fname); if (topObj != NULL) { curPage->top = topObj; } else { curPage->top = topObj = saved_top_obj; } if (botObj != NULL) { botObj->next = saved_top_obj; } if (saved_top_obj != NULL) { saved_top_obj->prev = botObj; } if (saved_bot_obj != NULL) { curPage->bot = botObj = saved_bot_obj; } else { curPage->bot = botObj; } if (topSel == NULL) { RestoreStatusStrings(); return; } UpdSelBBox(); if (topSel == botSel) { sprintf(gszMsgBox, TgLoadString(STID_ONLY_ONE_GIF_COMP_EXTRACTED), gif_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); RecordNewObjCmd(); } else { int saved_history_depth=historyDepth; HighLightForward(); historyDepth = 0; GroupSelObj(TRUE, TRUE, TRUE); historyDepth = saved_history_depth; HighLightReverse(); exec_attr = AddAttrByNameAndValue(topObj, "exec=", "flip_deck(infinite,10,linear)"); exec_attr->shown = FALSE; MoveObj(exec_attr->obj, ltx, lty); UpdTextBBox(exec_attr->obj); AdjObjBBox(topObj); UpdSelBBox(); RecordNewObjCmd(); } RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); HighLightForward(); if (!importFromLibrary && !real_remote_file) { SetCurImportDir(gif_fname); } if (colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } importingFile = FALSE; if (exec_attr != NULL) { sprintf(gszMsgBox, TgLoadString(STID_ANIMATING_GIVEN), gif_fname); TwoLineMsg(gszMsgBox, TgLoadString(STID_PRESS_ESC_TO_STOP)); DoExecLoop(topObj, exec_attr); Msg(TgLoadString(STID_GIF_ANIMATION_STOPPED)); } RestoreStatusStrings(); } /* ----------------------- Browse Functions ----------------------- */ static int origBrowseX=0, origBrowseY=0, maxBrowseX=0, maxBrowseY=0; static int curBrowseX=0, curBrowseY=0, curBrowseRowHeight=0; static int savedDirNameLen=0; static int browseObjType=INVALID; static char savedDirName[MAXPATHLENGTH+1]; static void InitBrowse(pszDir, ObjType) char *pszDir; int ObjType; { browseObjType = ObjType; if (ObjType == OBJ_ICON) { curBrowseX = origBrowseX = thumbnailX; maxBrowseX = paperWidth - curBrowseX; curBrowseY = origBrowseY = thumbnailY; maxBrowseY = paperHeight - curBrowseY; curBrowseRowHeight = 0; } else { curBrowseX = origBrowseX = drawOrigX+ABS_SIZE(EIGHTH_INCH); maxBrowseX = drawOrigX+drawWinW; curBrowseY = origBrowseY = drawOrigY+ABS_SIZE(EIGHTH_INCH); maxBrowseY = drawOrigY+drawWinH; curBrowseRowHeight = 0; } if (pszDir != NULL) { strcpy(savedDirName, pszDir); savedDirNameLen = strlen(savedDirName); } } static int CheckExecInterrupt() { XEvent ev; while (XCheckMaskEvent(mainDisplay, StructureNotifyMask, &ev)) { if (iconWindowShown) { if ((ev.xany.window == iconBaseWindow && ev.type == UnmapNotify) || (ev.xany.window == mainWindow && ev.type == MapNotify)) { XPutBackEvent(mainDisplay, &ev); return TRUE; } } else if ((ev.xany.window == iconBaseWindow && ev.type == MapNotify) || (ev.xany.window == mainWindow && ev.type == UnmapNotify)) { XPutBackEvent(mainDisplay, &ev); return TRUE; } else if (ev.type == ConfigureNotify) { Reconfigure(FALSE); if (browseObjType != OBJ_ICON) { maxBrowseX = drawOrigX+drawWinW; } } } while (XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { if (iconWindowShown) { if (ev.xany.window == mainWindow && ev.type == VisibilityNotify && ev.xvisibility.state == VisibilityUnobscured) { XPutBackEvent(mainDisplay, &ev); return TRUE; } else { ExposeEventHandler(&ev, TRUE); } } else { if (ev.xany.window == iconBaseWindow && ev.type == VisibilityNotify && ev.xvisibility.state == VisibilityUnobscured) { XPutBackEvent(mainDisplay, &ev); return TRUE; } else { ExposeEventHandler(&ev, TRUE); } } } if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); while (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) ; } if (ESCPressed() || CheckInterrupt(TRUE)) { return TRUE; } while (XCheckMaskEvent(mainDisplay, ButtonPressMask|KeyPressMask, &ev)) ; return FALSE; } static struct ObjRec *ImportForThumbnails(fname, p_bbox_w, p_bbox_h) char *fname; int *p_bbox_w, *p_bbox_h; { struct ObjRec *imported_obj=NULL; struct ObjRec *saved_top_obj=topObj, *saved_bot_obj=botObj; struct BBRec saved_draw_win_bbox; (*p_bbox_w) = (*p_bbox_h) = 0; curPage->top = curPage->bot = topObj = botObj = NULL; importingFile = TRUE; pastingFile = TRUE; memcpy(&saved_draw_win_bbox, &drawWinBBox, sizeof(struct BBRec)); drawWinBBox.ltx = drawWinBBox.rbx = drawOrigX-128; drawWinBBox.lty = drawWinBBox.rby = drawOrigY-128; if (ImportGivenFile(fname, FALSE, FALSE) == TRUE) { if (numObjSelected > 0) { struct BoxRec *box_ptr=NULL; struct ObjRec *obj_ptr=NULL; int changed=FALSE; for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { if (obj_ptr->type == OBJ_SYM) { obj_ptr->type = OBJ_GROUP; AdjObjBBox(obj_ptr); changed = TRUE; } } if (changed) { UpdSelBBox(); } CreateBoxObj(selLtX, selLtY, selRbX, selRbY, TRUE); box_ptr = topObj->detail.b; box_ptr->fill = NONEPAT; box_ptr->pen = NONEPAT; RemoveAllSel(); SelAllObj(FALSE, FALSE); GroupSelObj(FALSE, FALSE, FALSE); imported_obj = topObj; *p_bbox_w = imported_obj->bbox.rbx-imported_obj->bbox.ltx; *p_bbox_h = imported_obj->bbox.rby-imported_obj->bbox.lty; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(topObj == botObj, "too many objects found in ImportForThumbnails()", NULL); #endif /* _TGIF_DBG */ RemoveAllSel(); } MakeQuiescent(); } memcpy(&drawWinBBox, &saved_draw_win_bbox, sizeof(struct BBRec)); importingFile = FALSE; pastingFile = FALSE; curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; return imported_obj; } static int RegenerateImageFile(pszPath) char *pszPath; { int saved_colordump=colorDump, saved_wheretoprint=whereToPrint; *gszImageProcXPmFile = '\0'; gnConvolving = FALSE; colorDump = TRUE; whereToPrint = XBM_FILE; gnInImageProc = TRUE; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); DumpXBitmapFile(gnInImageProc, FALSE, TRUE); SetDefaultCursor(mainWindow); ShowCursor(); gnInImageProc = FALSE; whereToPrint = saved_wheretoprint; colorDump = saved_colordump; if (*gszImageProcXPmFile == '\0') return FALSE; strcpy(pszPath, gszImageProcXPmFile); return TRUE; } static struct ObjRec *MyRegenerateImage(obj_ptr) struct ObjRec *obj_ptr; { int image_w=0, image_h=0, w=0, h=0, short_name=FALSE, rc=INVALID; int ltx=0, lty=0; int ncolors=0, chars_per_pixel=0, first_pixel_is_bg=0, *pixels=NULL; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL, *rest=NULL; char szPath[MAXPATHLENGTH+1]; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; struct ObjRec *new_obj=NULL; ltx = obj_ptr->obbox.ltx; lty = obj_ptr->obbox.lty; AddObj(NULL, topObj, obj_ptr); PushPageInfo(); rc = RegenerateImageFile(szPath); DelAllObj(); PopPageInfo(); if (!rc) { return NULL; } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(szPath, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if ((short_name=IsPrefix(bootDir, szPath, &rest))) ++rest; if (rc != BitmapSuccess) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), (short_name ? rest : szPath)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); return NULL; } unlink(szPath); new_obj = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); MoveObj(new_obj, ltx-new_obj->obbox.ltx, lty-new_obj->obbox.lty); new_obj->tmp_parent = NULL; SetFileModified(TRUE); justDupped = FALSE; return new_obj; } static struct ObjRec *GenerateXpmThumbnail(imported_obj) struct ObjRec *imported_obj; { struct ObjRec *saved_top_obj=topObj, *saved_bot_obj=botObj, *new_obj=NULL; double orig_aspect_ratio=(double)0, aspect_ratio=(double)0; struct BBRec saved_draw_win_bbox; int bbox_w=(imported_obj->bbox.rbx-imported_obj->bbox.ltx); int bbox_h=(imported_obj->bbox.rby-imported_obj->bbox.lty); int final_w=0, final_h=0; curPage->top = curPage->bot = topObj = botObj = NULL; aspect_ratio = (((double)thumbnailW)/((double)thumbnailH)); orig_aspect_ratio = (((double)bbox_w)/((double)bbox_h)); memcpy(&saved_draw_win_bbox, &drawWinBBox, sizeof(struct BBRec)); drawWinBBox.ltx = drawWinBBox.rbx = drawOrigX-128; drawWinBBox.lty = drawWinBBox.rby = drawOrigY-128; if (bbox_w <= thumbnailW && bbox_h <= thumbnailH) { /* do not scale */ final_w = thumbnailW; final_h = thumbnailH; } else { double scale=(double)0; if (orig_aspect_ratio > aspect_ratio) { final_w = thumbnailW; final_h = round(((double)thumbnailW) / orig_aspect_ratio); scale = ((double)bbox_w) / ((double)thumbnailW); } else { final_h = thumbnailH; final_w = round(((double)thumbnailH) * orig_aspect_ratio); scale = ((double)bbox_h) / ((double)thumbnailH); } ScaleObjLikeScaleEverything(imported_obj, scale, FALSE); } new_obj = MyRegenerateImage(imported_obj); /* imported_obj is freed here */ if (new_obj != NULL) { struct BoxRec *box_ptr=NULL; int obj_w=(new_obj->obbox.rbx-new_obj->obbox.ltx); int obj_h=(new_obj->obbox.rby-new_obj->obbox.lty); int new_ltx=((thumbnailW+(thumbnailPadding<<1)-obj_w)>>1); int new_lty=((thumbnailH+(thumbnailPadding<<1)-obj_h)>>1); CreateBoxObj(0, 0, thumbnailW+(thumbnailPadding<<1), thumbnailH+(thumbnailPadding<<1), TRUE); box_ptr = topObj->detail.b; box_ptr->fill = BACKPAT; box_ptr->pen = SOLIDPAT; box_ptr->dash = 0; box_ptr->width = 0; strcpy(box_ptr->width_spec, "0"); AdjObjBBox(topObj); MoveObj(new_obj, new_ltx-new_obj->obbox.ltx, new_lty-new_obj->obbox.lty); AddObj(NULL, topObj, new_obj); SelAllObj(FALSE, FALSE); GroupSelObj(FALSE, FALSE, FALSE); RemoveAllSel(); new_obj = topObj; UnlinkObj(topObj); } memcpy(&drawWinBBox, &saved_draw_win_bbox, sizeof(struct BBRec)); curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; return new_obj; } static int BrowseDir(DirName, ExtStr, ExtStrLen, ObjType, pii) char *DirName, *ExtStr; int ExtStrLen, ObjType; struct ImportInfoRec *pii; /* returns TRUE if interrupted */ { char name[MAXPATHLENGTH+1]; int interrupted=FALSE, esave_len=0; #ifdef VMS int len; #endif /* VMS */ DIR *dirp; DIR_ENTRY *d; if ((dirp=opendir(DirName)) == NULL) return interrupted; esave_len = strlen("EmergencySave."); if (pii == NULL) { sprintf(gszMsgBox, TgLoadString(STID_BROWSING_DIR_FOR_TYPE_FILES), DirName, ExtStr); } else { sprintf(gszMsgBox, TgLoadString(STID_BROWSING_DIR_FOR_TYPE_FILES), DirName, pii->name); } Msg(gszMsgBox); while ((d=readdir(dirp)) != NULL) { int ncolors, chars_per_pixel, first_pixel_is_bg, * pixels; int image_w=0, image_h=0, w=0, h=0, x_hot, y_hot, rc=INVALID; unsigned int tmp_w, tmp_h; char *color_char, **color_str, *xpm_data=NULL; Pixmap bitmap=None, pixmap=None; XImage *image=NULL, *bitmap_image=NULL; struct ObjRec *imported_obj=NULL; if (CheckExecInterrupt()) { interrupted = TRUE; break; } if (!ExtensionMatch(ExtStr, d->d_name)) { continue; } if (strncmp(d->d_name, "EmergencySave.", esave_len) == 0) { continue; } sprintf(name, "%s%c%s", DirName, DIR_SEP, d->d_name); sprintf(gszMsgBox, TgLoadCachedString(CSTID_OPENING_GIVEN), &name[savedDirNameLen+1]); SetStringStatus(gszMsgBox); if (ObjType == OBJ_XBM) { rc = XReadBitmapFile(mainDisplay, mainWindow, name, &tmp_w, &tmp_h, &bitmap, &x_hot, &y_hot); w = (int)tmp_w; h = (int)tmp_h; } else if (ObjType == OBJ_XPM) { if (pii != NULL) { char szXpmPath[MAXPATHLENGTH+1]; SaveStatusStrings(); rc = ConvertAnyToXpm(pii, name, szXpmPath, sizeof(szXpmPath)); RestoreStatusStrings(); if (!rc) continue; rc = MyReadPixmapFile(szXpmPath, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); unlink(szXpmPath); } else { rc = MyReadPixmapFile(name, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); } } else if (ObjType == OBJ_ICON) { imported_obj = ImportForThumbnails(name, (int*)&tmp_w, (int*)&tmp_h); if (imported_obj == NULL) continue; rc = BitmapSuccess; w = (int)tmp_w; h = (int)tmp_h; } else { } if (rc == BitmapSuccess) { struct ObjRec *obj_ptr=NULL; int short_name; char *rest=NULL; if (ObjType == OBJ_XBM) { obj_ptr = CreateXBmObj(w, h, w, h, bitmap, NULL); } else if (ObjType == OBJ_XPM) { obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); } else if (ObjType == OBJ_ICON) { obj_ptr = GenerateXpmThumbnail(imported_obj); /* imported_obj is deleted in GenerateXpmThumbnail() */ if (obj_ptr == NULL) { continue; } w = (int)(obj_ptr->obbox.rbx-obj_ptr->obbox.ltx); h = (int)(obj_ptr->obbox.rby-obj_ptr->obbox.lty); } else { } if ((short_name=IsPrefix((curDirIsLocal ? curDir : curLocalDir), name, &rest))) { ++rest; } if (ObjType == OBJ_ICON) { if (imported_obj->type != OBJ_TEXT) { AddAttrByNameAndValue(obj_ptr, "href=", (short_name ? rest : name)); } } else { AddAttrByNameAndValue(obj_ptr, "file_name=", (short_name ? rest : name)); } if (showFileNameOnBrowse && obj_ptr->fattr != NULL && obj_ptr->fattr == obj_ptr->lattr) { struct AttrRec *attr_ptr=obj_ptr->fattr; int attr_h, attr_w, attr_ltx, attr_lty; attr_ptr->shown = TRUE; attr_ptr->nameshown = FALSE; UpdAttr(attr_ptr); AdjObjBBox(attr_ptr->obj); attr_w = attr_ptr->obj->obbox.rbx-attr_ptr->obj->obbox.ltx; attr_h = attr_ptr->obj->bbox.rby-attr_ptr->obj->bbox.lty; attr_ltx = ((obj_ptr->obbox.ltx+obj_ptr->obbox.rbx)>>1)-(attr_w>>1); attr_lty = obj_ptr->bbox.rby; MoveObj(attr_ptr->obj, attr_ltx-attr_ptr->obj->obbox.ltx, attr_lty-attr_ptr->obj->obbox.lty); if (attr_w > w && ObjType != OBJ_ICON) w = attr_w; h += attr_h; } AdjObjBBox(obj_ptr); if (ObjType == OBJ_ICON) { if (curBrowseX+w > maxBrowseX-origBrowseX) { curBrowseX = origBrowseX; curBrowseY += curBrowseRowHeight+thumbnailYGap; while (curBrowseY > maxBrowseY) { ForceScrollDown(TRUE); maxBrowseY = drawOrigY+drawWinH; } curBrowseRowHeight = h; } else if (h > curBrowseRowHeight) { curBrowseRowHeight = h; } } else { if (curBrowseX+w > maxBrowseX) { curBrowseX = origBrowseX; curBrowseY += curBrowseRowHeight; while (curBrowseY > maxBrowseY) { ForceScrollDown(TRUE); maxBrowseY = drawOrigY+drawWinH; } curBrowseRowHeight = h; } else if (h > curBrowseRowHeight) { curBrowseRowHeight = h; } } obj_ptr->tmp_parent = NULL; AddObj(NULL, topObj, obj_ptr); MoveObj(topObj, curBrowseX-topObj->obbox.ltx, curBrowseY-topObj->obbox.lty); numRedrawBBox = 0; DrawObj(drawWindow, topObj); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; XSync(mainDisplay, False); if (ObjType == OBJ_ICON) { curBrowseX += w + thumbnailXGap; } else { curBrowseX += w; } } else { } } closedir(dirp); if ((dirp=opendir(DirName)) == NULL) return interrupted; while (!interrupted && (d=readdir(dirp)) != NULL) { if (CheckExecInterrupt()) { interrupted = TRUE; break; } #ifdef VMS len = strlen(d->d_name); if (len > 4 && (strcmp(".dir", &d->d_name[len-4]) == 0)) { sprintf(name, "%s%c%s", DirName, DIR_SEP, d->d_name); if (BrowseDir(name, ExtStr, ExtStrLen, ObjType, pii)) { interrupted = TRUE; break; } } #endif /* VMS */ if (strcmp(d->d_name, ".") != 0 && strcmp(d->d_name, "..") != 0) { struct stat stat_buf; sprintf(name, "%s%c%s", DirName, DIR_SEP, d->d_name); if (stat(name, &stat_buf) == 0 && (stat_buf.st_mode & S_IFDIR)) { int skip=FALSE; #ifndef _NO_LSTAT if (lstat(name, &stat_buf) == 0 && ((stat_buf.st_mode & S_IFLNK) == S_IFLNK)) { sprintf(gszMsgBox, TgLoadString(STID_SKIP_GIVEN_FILE_SYM_LINK), &name[savedDirNameLen+1]); Msg(gszMsgBox); skip = TRUE; } #endif /* _NO_LSTAT */ if (!interrupted && !skip && BrowseDir(name, ExtStr, ExtStrLen, ObjType, pii)) { interrupted = TRUE; break; } } } } closedir(dirp); return interrupted; } static void StartBrowse(DirName, ExtStr, ExtStrLen, ObjType, pii) char *DirName, *ExtStr; int ExtStrLen, ObjType; struct ImportInfoRec *pii; { int saved_text_just=textJust; if (!CurFontCheck()) { MsgBox(TgLoadString(STID_CHECK_FONT_FAILED_FOR_BROWSE), TOOL_NAME, INFO_MB); return; } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); MakeQuiescent(); SaveStatusStrings(); InitBrowse(DirName, ObjType); StartCompositeCmd(); ShowInterrupt(1); textJust = JUST_C; if (BrowseDir(DirName, ExtStr, ExtStrLen, ObjType, pii)) { Msg(TgLoadString(STID_USER_INTR)); } textJust = saved_text_just; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } HideInterrupt(); EndCompositeCmd(); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); XFlush(mainDisplay); } void CreateThumbnails() { static char stszObjFileExt[20], stszGzObjFileExt[20]; static char stszSymFileExt[20], stszPinFileExt[20]; static int initialized=FALSE; char buf[MAXSTRING]; int len=0; MakeQuiescent(); if (firstCmd != NULL) { if (!OkToFlushUndoBuffer( TgLoadString(STID_CREATE_THUMBNAIL_CAUSE_FLUSH))) { SetCurChoice(curChoiceBeforeMakeQuiescent); return; } } if (!initialized) { sprintf(stszObjFileExt, ".%s", OBJ_FILE_EXT); sprintf(stszGzObjFileExt, ".%s.gz", OBJ_FILE_EXT); sprintf(stszSymFileExt, ".%s", SYM_FILE_EXT); sprintf(stszPinFileExt, ".%s", PIN_FILE_EXT); initialized = TRUE; } sprintf(buf, "%s;%s;%s;%s", stszObjFileExt, stszGzObjFileExt, stszSymFileExt, stszPinFileExt); len = strlen(buf); if (strcmp(OBJ_FILE_EXT,"obj") != 0) { strcat(buf, ";.obj"); } strcat(buf, ";.obj.gz;.tgo;.tgo.gz"); StartBrowse((curDirIsLocal ? curDir : curLocalDir), buf, strlen(buf), OBJ_ICON, NULL); CleanUpCmds(); } void BrowseXBitmap() { StartBrowse((curDirIsLocal ? curDir : curLocalDir), XBM_FILE_EXT, strlen(XBM_FILE_EXT), OBJ_XBM, NULL); } void BrowseXPixmap() { StartBrowse((curDirIsLocal ? curDir : curLocalDir), XPM_FILE_EXT, strlen(XPM_FILE_EXT), OBJ_XPM, NULL); } void BrowseOther() { int i, index; char *ext_str; struct ImportInfoRec *pii; XEvent ev; sprintf(gszMsgBox, TgLoadString(STID_WORKING_DIR_IS_GIVEN), (curDirIsLocal ? curDir : curLocalDir)); SetStringStatus(gszMsgBox); if ((index=SelectAnImportFilter(NULL)) == INVALID) { return; } for (i=0, pii=topImportInfo; i < index && pii != NULL; i++, pii=pii->next) { } if (pii == NULL) return; XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } if ((ext_str=SetUpExtStr((strlen(pii->ext)<<1)+3, pii->ext, "")) != NULL) { StartBrowse((curDirIsLocal ? curDir : curLocalDir), ext_str, strlen(pii->ext), OBJ_XPM, pii); free(ext_str); } } void BrowseOtherType(pszName) char *pszName; { char *paren_ptr=(pszName == NULL ? NULL : strchr(pszName, ')')), *ext_str; struct ImportInfoRec *pii; if (paren_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_FMT_IN_SHORTCUT_SPEC), "ImportOtherFileType", (pszName == NULL ? "" : pszName)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } *paren_ptr = '\0'; for (pii=topImportInfo; pii != NULL; pii=pii->next) { if (strcmp(pii->name, pszName) == 0) { break; } } if (pii == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_NAMED_IMP_FLTR), pszName); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if ((ext_str=SetUpExtStr((strlen(pii->ext)<<1)+3, pii->ext, "")) != NULL) { StartBrowse((curDirIsLocal ? curDir : curLocalDir), ext_str, strlen(pii->ext), OBJ_XPM, pii); free(ext_str); } } /* ----------------------- Screen Capture Functions ----------------------- */ static void FlushAllRedrawEvents() { XEvent ev; XFlush(mainDisplay); XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } } static int hideDuringCapture=FALSE; static XImage *capturedImage=NULL; static Colormap *installedColormaps=NULL; static int numInstalledColormaps=0; static int capturedWidth=0, capturedHeight=0; static void CaptureCleanUp() { if (capturedImage != NULL) XDestroyImage(capturedImage); if (installedColormaps != NULL) XFree(installedColormaps); capturedImage = NULL; installedColormaps = NULL; numInstalledColormaps = 0; capturedWidth = capturedHeight = 0; } static int EnumPopupMenuProcToHide(menu_index, win, pUserData) int menu_index; Window win; void *pUserData; /* return FALSE will stop the enumeration */ { XUnmapWindow(mainDisplay, win); return TRUE; } static void BeginHideDuringCapture() { CaptureCleanUp(); MakeQuiescent(); if (hideDuringCapture) { EnumPopupMenuWindow(EnumPopupMenuProcToHide, NULL); XUnmapWindow(mainDisplay, mainWindow); FlushAllRedrawEvents(); } else { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } XBell(mainDisplay, 0); } static int EnumPopupMenuProcToShow(menu_index, win, pUserData) int menu_index; Window win; void *pUserData; /* return FALSE will stop the enumeration */ { XMapWindow(mainDisplay, win); return TRUE; } static int EnumPopupMenuProcToUpdate(menu_index, win, pUserData) int menu_index; Window win; void *pUserData; /* return FALSE will stop the enumeration */ { UpdatePinnedMenu(menu_index); return TRUE; } static void EndHideDuringCapture() { if (hideDuringCapture) { XEvent ev; EnumPopupMenuWindow(EnumPopupMenuProcToShow, NULL); XMapWindow(mainDisplay, mainWindow); XSync(mainDisplay, False); while (XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } EnumPopupMenuWindow(EnumPopupMenuProcToUpdate, NULL); } else { SetDefaultCursor(mainWindow); ShowCursor(); } ShowCurChoiceMouseStatus(curChoice, 0, FALSE); XBell(mainDisplay, 0); XSync(mainDisplay, False); MillisecondSleep(120); XBell(mainDisplay, 0); } struct ObjRec *CreatePpmTrueObjFromImage(image, image_w, image_h, ppm_data, data_size) XImage *image; int image_w, image_h; char *ppm_data; unsigned int data_size; { Pixmap pixmap=None, bitmap=None; XImage *bitmap_image=NULL; struct ObjRec *obj_ptr=NULL; struct XPmRec *xpm_ptr=NULL; pixmap = XCreatePixmap(mainDisplay, mainWindow, image_w, image_h, mainDepth); bitmap = XCreatePixmap(mainDisplay, dummyBitmap, image_w, image_h, 1); if (pixmap == None || bitmap == None) { if (pixmap != None) XFreePixmap(mainDisplay, pixmap); if (bitmap != None) XFreePixmap(mainDisplay, bitmap); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } XSetForeground(mainDisplay, xbmGC, 1); XFillRectangle(mainDisplay, bitmap, xbmGC, 0, 0, image_w, image_h); XSetForeground(mainDisplay, xbmGC, 0); bitmap_image = XGetImage(mainDisplay, bitmap, 0, 0, image_w, image_h, 1, ZPixmap); XPutImage(mainDisplay, pixmap, xpmGC, image, 0, 0, 0, 0, image_w, image_h); image = XGetImage(mainDisplay, pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (image == NULL || bitmap_image == NULL) { XFreePixmap(mainDisplay, pixmap); XFreePixmap(mainDisplay, bitmap); if (image != NULL) XDestroyImage(image); if (bitmap_image != NULL) XDestroyImage(bitmap_image); MsgBox(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM), TOOL_NAME, INFO_MB); return NULL; } obj_ptr = CreateXPmObj(image_w, image_h, image_w, image_h, pixmap, image, bitmap, bitmap_image, 0, 0, FALSE, NULL, NULL, NULL, NULL); xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ppm_data; xpm_ptr->ppm_data_size = data_size; xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; return obj_ptr; } static void ImportCapturedImage() { int no_image=FALSE; unsigned int data_size=0; char tmp_fname[MAXPATHLENGTH], ext[MAXPATHLENGTH], *ppm_data=NULL; Colormap saved_colormap=None; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { return; } if (installedColormaps != NULL) { saved_colormap = mainColormap; mainColormap = (*installedColormaps); } if (!DumpXImageToFile(capturedImage, capturedWidth, capturedHeight, tmp_fname, ext)) { no_image = TRUE; } else if (strcmp(ext, ".ppm.z") == 0) { char deflated_fname[MAXPATHLENGTH]; snprintf(deflated_fname, sizeof(deflated_fname), "%s%s", tmp_fname, ext); ppm_data = ReadFileIntoBuf(deflated_fname, &data_size); unlink(deflated_fname); } if (saved_colormap != None) { mainColormap = saved_colormap; } SetDefaultCursor(mainWindow); ShowCursor(); if (!no_image) { if (ppm_data == NULL) { ImportGivenXPixmapFile(FALSE, NULL, tmp_fname, STID_GIVEN_XPM_SIZE_FILE_IMPORTED, STID_CANNOT_IMPORT_XPM_FILE, NULL, NULL); } else { struct ObjRec *obj_ptr=CreatePpmTrueObjFromImage(capturedImage, capturedWidth, capturedHeight, ppm_data, data_size); if (obj_ptr != NULL) { AddObj(NULL, topObj, obj_ptr); PlaceTopObj(obj_ptr, NULL, NULL); SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } } } } CaptureCleanUp(); unlink(tmp_fname); } static void CaptureUpdateBox(OrigX, OrigY, end_x, end_y) int OrigX, OrigY, end_x, end_y; { char buf[80]; int w=abs(OrigX-end_x), h=abs(OrigY-end_y); SelBox(rootWindow, revDefaultGC, OrigX, OrigY, end_x, end_y); sprintf(buf, "%dx%d", w, h); XDrawString(mainDisplay, rootWindow, revDefaultGC, end_x+18, end_y+defaultFontAsc, buf, strlen(buf)); } static void ContinueScreenCapture(OrigX, OrigY) int OrigX, OrigY; { int done=FALSE; int end_x=OrigX, end_y=OrigY; XSetSubwindowMode(mainDisplay, revDefaultGC, IncludeInferiors); XGrabPointer(mainDisplay, rootWindow, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); CaptureUpdateBox(OrigX, OrigY, end_x, end_y); while (!done) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); CaptureUpdateBox(OrigX, OrigY, end_x, end_y); done = TRUE; } else if (input.type == MotionNotify) { XEvent ev; int cur_x=input.xmotion.x, cur_y=input.xmotion.y; if (cur_x != end_x || cur_y != end_y) { CaptureUpdateBox(OrigX, OrigY, end_x, end_y); end_x = cur_x; end_y = cur_y; CaptureUpdateBox(OrigX, OrigY, end_x, end_y); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } XSetSubwindowMode(mainDisplay, revDefaultGC, ClipByChildren); XSync(mainDisplay, False); if (OrigX != end_x && OrigY != end_y) { struct BBRec bbox; int dest_w=0, dest_h=0; SetBBRec(&bbox, OrigX, OrigY, end_x, end_y); dest_w = bbox.rbx - bbox.ltx; dest_h = bbox.rby - bbox.lty; capturedImage = XGetImage(mainDisplay, rootWindow, bbox.ltx, bbox.lty, dest_w, dest_h, AllPlanes, ZPixmap); if (capturedImage == NULL) { FailAllocMessage(); } else { capturedWidth = dest_w; capturedHeight = dest_h; installedColormaps = XListInstalledColormaps(mainDisplay, rootWindow, &numInstalledColormaps); if (numInstalledColormaps == 0) { if (installedColormaps != NULL) XFree(installedColormaps); installedColormaps = NULL; } else if (numInstalledColormaps > 1) { TwoLineMsg(TgLoadString(STID_MORE_THAN_ONE_CMAP_INSTALLED), TgLoadString(STID_FIRST_ONE_ON_LIST_USED)); } } } } void ScreenCapture() { int mouse_x=0, mouse_y=0; if (!colorDisplay && mainDepth <= 1) return; BeginHideDuringCapture(); SetMouseStatus(TgLoadString(STID_SPECIFY_AREA), TgLoadCachedString(CSTID_CANCEL), TgLoadCachedString(CSTID_CANCEL)); if (CornerLoop(&mouse_x, &mouse_y) == Button1) { ContinueScreenCapture(mouse_x, mouse_y); } EndHideDuringCapture(); if (capturedImage != NULL) { ImportCapturedImage(); } } static void DoFullScreenCapture() { struct BBRec bbox; int dpy_w=DisplayWidth(mainDisplay,mainScreen); int dpy_h=DisplayHeight(mainDisplay,mainScreen); SetBBRec(&bbox, 0, 0, dpy_w, dpy_h); capturedImage = XGetImage(mainDisplay, rootWindow, bbox.ltx, bbox.lty, dpy_w, dpy_h, AllPlanes, ZPixmap); if (capturedImage == NULL) { FailAllocMessage(); } else { capturedWidth = dpy_w; capturedHeight = dpy_h; installedColormaps = XListInstalledColormaps(mainDisplay, rootWindow, &numInstalledColormaps); if (numInstalledColormaps == 0) { if (installedColormaps != NULL) XFree(installedColormaps); installedColormaps = NULL; } else if (numInstalledColormaps > 1) { TwoLineMsg(TgLoadString(STID_MORE_THAN_ONE_CMAP_INSTALLED), TgLoadString(STID_FIRST_ONE_ON_LIST_USED)); } } } void FullScreenCapture() { if (!colorDisplay && mainDepth <= 1) return; if (MsgBox(TgLoadString(STID_OK_TO_FULL_SCREEN_CAPTURE_YNC), TOOL_NAME, YNC_MB) != MB_ID_YES) { return; } FlushAllRedrawEvents(); BeginHideDuringCapture(); DoFullScreenCapture(); EndHideDuringCapture(); if (capturedImage != NULL) { ImportCapturedImage(); } } void DelayedFullScreenCapture() { char spec[80]; int delay=0; if (!colorDisplay && mainDepth <= 1) return; *spec = '\0'; if (Dialog(TgLoadString(STID_SPECIFY_DELAY_FULL_SCR_CAP), NULL, spec) == INVALID) { return; } UtilTrimBlanks(spec); if (*spec == '\0') return; if (sscanf(spec, "%d", &delay) != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC_NUM_EXPECTED), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } FlushAllRedrawEvents(); BeginHideDuringCapture(); if (delay != 0) { sleep(delay); } DoFullScreenCapture(); EndHideDuringCapture(); if (capturedImage != NULL) { ImportCapturedImage(); } } void ToggleHideDuringCapture() { if (!colorDisplay && mainDepth <= 1) return; hideDuringCapture = !hideDuringCapture; sprintf(gszMsgBox, TgLoadString(hideDuringCapture ? STID_WILL_HIDE_TOOL_WHILE_CAPTURE : STID_WILL_SHOW_TOOL_WHILE_CAPTURE), TOOL_NAME); Msg(gszMsgBox); } int RefreshScreenCaptureMenu(menu) TgMenu *menu; { int ok=TRUE; if (!colorDisplay && mainDepth <= 1) { /* Screen Capture */ ok &= TgEnableMenuItemById(menu, CMDID_SCREENCAPTURE, FALSE); /* Full Screen Capture */ ok &= TgEnableMenuItemById(menu, CMDID_FULLSCREENCAPTURE, FALSE); /* Delayed Full Screen Capture */ ok &= TgEnableMenuItemById(menu, CMDID_DELAYEDFULLSCREENCAPTURE, FALSE); /* Hide During Capture */ ok &= TgEnableMenuItemById(menu, CMDID_TOGGLEHIDEDURINGCAPTURE, FALSE); } /* Hide During Capture */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEHIDEDURINGCAPTURE, hideDuringCapture); return ok; } TgMenu *CreateScreenCaptureMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshScreenCaptureMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshScreenCaptureMenu); } return menu; } void ToggleAutoEPSPreviewBitmap() { autoEPSPreviewBitmap = !autoEPSPreviewBitmap; sprintf(gszMsgBox, TgLoadString(autoEPSPreviewBitmap ? STID_WILL_AUTO_GEN_PREVIEW_BITMAP : STID_WONT_AUTO_GEN_PREVIEW_BITMAP), TOOL_NAME); Msg(gszMsgBox); } int RefreshImportMenu(menu) TgMenu *menu; { int ok=TRUE; /* Auto EPS Preview Bitmap */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEAUTOEPSPREVIEWBITMAP, autoEPSPreviewBitmap); return ok; } TgMenu *CreateImportMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshImportMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshImportMenu); } return menu; } ���������������tgif-QPL-4.2.5/obj.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000004662�11602233312�013714� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/obj.e,v 1.6 2011/05/16 16:21:58 william Exp $ */ #ifndef _OBJ_E_ #define _OBJ_E_ extern struct ObjRec * topObj, * botObj; #ifdef _INCLUDE_FROM_OBJ_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_OBJ_C_*/ extern void AddObj ARGS_DECL((struct ObjRec *Prev, struct ObjRec *Next, struct ObjRec *)); extern void UnlinkObj ARGS_DECL((struct ObjRec *)); extern void ReplaceObj ARGS_DECL((struct ObjRec *old_obj, struct ObjRec *new_obj)); extern void FreeObj ARGS_DECL((struct ObjRec *)); extern void DelObj ARGS_DECL((struct ObjRec *)); extern void DelAllObj ARGS_DECL((void)); extern void AdjObjOBBox ARGS_DECL((struct ObjRec *)); extern void AdjObjBBox ARGS_DECL((struct ObjRec *)); extern void RecursivelyAdjObjBBox ARGS_DECL((struct ObjRec *sub_obj, struct ObjRec *owner_obj, struct ObjRec *top_owner)); extern void AdjObjCache ARGS_DECL((struct ObjRec *)); extern void AdjCaches ARGS_DECL((void)); extern void AdjObjSplineVs ARGS_DECL((struct ObjRec *)); extern void AdjSplineVs ARGS_DECL((void)); extern void ClearObjCachesInAllPages ARGS_DECL((void)); extern void MoveRotatedObjCache ARGS_DECL((struct ObjRec *, int, int)); extern void AdjObjHotSpot ARGS_DECL((void)); extern void AdjHotSpots ARGS_DECL((void)); extern int IsTopLevelObject ARGS_DECL((struct ObjRec *)); extern struct ObjRec *GetTopOwner ARGS_DECL((struct ObjRec *)); #ifdef _INCLUDE_FROM_OBJ_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_OBJ_C_*/ #endif /*_OBJ_E_*/ ������������������������������������������������������������������������������tgif-QPL-4.2.5/Makefile.noimake���������������������������������������������������������������������0000644�0000764�0000764�00000037727�11602233312�016066� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# # Author: William Chia-Wei Cheng (bill.cheng@acm.org) # # Copyright (C) 2001-2009, William Chia-Wei Cheng. # # This file may be distributed under the terms of the Q Public License # as defined by Trolltech AS of Norway and appearing in the file # LICENSE.QPL included in the packaging of this file. # # THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING # THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR # PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, # INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING # FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, # NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION # WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. # # @(#)$Header: /mm2/home/cvs/bc-src/tgif/Makefile.noimake,v 1.9 2011/05/16 16:25:17 william Exp $ # INSTALLPATH = /usr/local MANSECTION = n O = .o XBM = xbm/ CC = cc BINDIR = $(INSTALLPATH)/bin TGIFDIR = $(INSTALLPATH)/lib/tgif MANPATH = $(INSTALLPATH)/man MANDIR = $(MANPATH)/man$(MANSECTION) XDIR = /usr/openwin MOTIFDIR = /usr/dt INCROOT = /usr/X11R6/include USRLIBDIR = /usr/X11R6/lib # # Change INSTALL to /usr/ucb/install if INSTPGMFLAGS doesn't mean strip on # your machine (such as an RS6000). Stripping gets rid of # symbol talbe and relocation bits in a binary file. # 'make install' will not work with Solaris because it requires the install # directory right after the -c option. So, if you are running # Solaris, please install the files manually. # INSTALL = install CFLAGS = -O $(DEFINES) -I$(INCROOT) LDFLAGS = -L$(USRLIBDIR) -lc -lX11 -ldl -lm #################################################################### # Try the following instead of the above on a Solaris machine # #CFLAGS = -O $(DEFINES) -I/usr/local/include \ # -I$(XDIR)/include -I$(MOTIFDIR)/include #LDFLAGS = -L$(XDIR)/lib -L$(MOTIFDIR)/lib \ # -lc -lXmu -lXt -lX11 -ldl -lm -lsocket -lnsl #################################################################### # Try the following instead of the above on a AIX machine # #CFLAGS = -O $(DEFINES) -I/usr/local/include #LDFLAGS = -L/usr/local/lib -lc -lX11 -ldl -lm #################################################################### # Try the following instead of the above on an IRIX machine # #CFLAGS = -O2 -xansi -32 -mips2 -Wf,-XNh2000 -nostdinc \ # -DSYSV -DSVR4 -DFUNCPROTO=7 -DNARROWPROTO $(DEFINES) \ # -I/usr/local/include \ # -I$(XDIR)/include -I$(MOTIFDIR)/include #LDFLAGS = -O2 -xansi -32 -mips2 -Wf,-XNh2000 \ # -L$(XDIR)/lib -L$(MOTIFDIR)/lib \ # -lXexe -lX11 -lm -L/usr/lib/mips2 -L/usr/lib -ldl -lm #################################################################### ########################################################################### # For a simple install, hopefully, you only need to change the above lines. ########################################################################### COMPILE.c = $(CC) -c $(CFLAGS) $(CPPFLAGS) LINK.c = $(CC) $(CFLAGS) $(CPPFLAGS) $(LDFLAGS) INSTPGMFLAGS = -s INSTMANFLAGS = -m 0444 DEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \ -DEPSF_FILE_EXT=\"eps\" -DPS_FILE_EXT=\"ps\" \ -DXBM_FILE_EXT=\"xbm\" -DXPM_FILE_EXT=\"xpm\" \ -DOBJ_FILE_EXT=\"obj\" -DSYM_FILE_EXT=\"sym\" \ -DTEXT_FILE_EXT=\"txt\" -DPIN_FILE_EXT=\"pin\" \ -DNETLIST_FILE_EXT=\"net\" -DCOMP_FILE_EXT=\"cmp\" \ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" \ -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT #-D_NO_ZLIB # Include the above line if you do not have zlib installed in your # system. Zlib is only used in tgif when _TGIF_WB2 (see below) is # used. #-D_NO_ENTER_TEXT_EVERYWHERE # Include the above line if you do not want to be able to enter # text from the keyboard in tgif unless the drawing area of tgif # has the keyboard focus. #-D_DARWIN_MOD1_AS_META # Include the above line if you are compiling for Mac OS X and # you want to use the Mod1 key as the <Meta> key. By default, # the Mod2 key is treated as the <Meta> key (at the time this # option was added). #-D_XPM3TOPPM # Include the above line if the xpmtoppm you have only knows how to # handle XPM format version 3. (This is the case with xpm-9.14.) # This has the same effect as setting Tgif.XPmOutputVersion to 3 and # Tgif.UseXPmVersion1ForImageMap to false. #-D_NO_LANDSCAPE_PDF_SETPAGEDEVICE # Include the above line if you want tgif to *not* generate # "setpagedevice" PostScript command to rotate the generated PostScript # file. (This is meant to be used when ps2pdf can handle landscape # PostScript files correctly.) #-D_PRTGIF_USE_ISO_LATIN_1_ALWAYS # Include the above line if you want to always use ISO 8859-1 character # set for single-byte characters when running tgif with the -print # commandline option. Please only use this if you are sure that you # will *never* use other encodings. You can selectively turn off # reencoding by using either the Tgif.DontReencode X default or the # -dontreencode commandline option. #-D_TMP_DIR_IN_HOME_DIR # Include the above line if you want the temporary directory to be # a user's $HOME/.Tgif directory by default. #-D_DONT_USE_MKTEMP # Include the above line if you do not want to use mktemp() and your # system supports tempnam(). The use of mktemp() is not recommanded # due to some security considerations. #-D_PS_SEVENBIT_DOUBLEBYTE_TEXT # Include the above line if bit 7 in both bytes of a double-byte # character should be masked out when printing/exporting double-byte # text to a PostScript file. #-D_USE_PS_ADOBE_STRING=\"true\" # Include the above line in the DEFINES if you want to configure tgif # to use a default Tgif.UsePsAdobeString value. #-D_MINIMAL_EPS=1 # Include the above line in the DEFINES if you want to configure tgif # to use a default Tgif.MinimalEPS value. #-DENABLE_NLS # Include the above line if you want to enable NLS (Native Language # Support). #-D_DONT_USE_PORTABLE_LOCALE (obsoleted) # Include the above line if don't want to use the portable locale. # (Portable locale is "C" for all locale categories.) #-D_NO_RECURSIVE_EXTERN # Include the above line if your C compiler cannot handle # "#define extern extern". The /bin/cc compiler on HP-UX reports a # Recursion in macro "extern" when the above define is used. #-D_DL_EXPORT_UNDERSCORE # Include the above line if you use export filters and there is an entry # point to an export filter named "_TgifExportFilterMain" (and there's # no entry point named "TgifExportFilterMain"). One can see all the # entry points to an export filter by running 'nm' against it. #-D_NO_TGTWB5 # Include the above line if you do not want to include the code # that handles tgtwb5. Please also remove "tgtwb5.o" and "tgtwb5xl.o" # from OBJ1 in Imakefile. #-D_NO_XCIN # Include the above line if you do not want to include the code # that handles xcin. Please also remove "cli_xcin.o" from # OBJ1 in Imakefile. #-D_NO_CHINPUT # Include the above line if you do not want to include the code # that handles chinput. Please also remove "chinput.o" from # OBJ1 in Imakefile. #-D_NO_KINPUT # Include the above line if you do not want to include the code # that handles kinput. Please also remove "convkinput.o" from # OBJ1 in Imakefile. #-D_NO_XIM # Include the above line if you do not want to include the code # that handles X Input Method. Please also remove "convxim.o" from # OBJ1 in Imakefile. #-D_NO_NKF # Include the above line if you do not want to include the code # that handles Network Kanji Filter (NKF). Please also remove # "nkf.o" from OBJ1 in Imakefile. #-D_NO_DL_SUPPORT # Include the above line if you don't have <dlfcn.h>. If you define # _NO_DL_SUPPORT, please use the SYS_LIBRARIES that does not contain # -ldl above. #-D_NO_LOCALE_SUPPORT # Include the above line if you don't have <X11/Xlocale.h>. If this # is the case and you don't have <locale.h>, you must also use # -D_NO_XIM because "convxim.c" assumes that you have <locale.h>. #-D_METRIC_PIX_PER_INCH # Include the above line if you want to use 127 pixels per inch # when printing in the metric system. If this line is not # included, 128 pixels per inch is used. #-D_NO_GETTIMEOFDAY # Include the above line if you do not have the gettimeofday() # function but have the ftime() function. #-D_TANGRAM_II # Include the above line if you want to include the Tangram-II features # by Carlos Fisch de Brito, Luiz Rogerio Goncalves de Carvalho, and # Denise Jorge de Oliveira <fisch,luiz,dezinha@land.ufrj.br> of the # Tangram-II team of the Universidade Federal do Rio de Janeiro. These # features are under development and highly experimental. #-D_TGIF_WB (obsoleted) # Include the above line if you want to include the whiteboard feature # by Renato Santana <renato@nce.ufrj.br>. #-D_TGIF_WB2 # Include the above line if you want to include the whiteboard feature # by Magnos Martinello <magnos@land.ufrj.br> and Raphael S. de Moraes # <raphael@land.ufrj.br>. The whiteboard needs IP multicast support, # and therefore, can only run on IP multicast enabled kernels. This # code is experimental and have know bugs (such as buffer overflow) and # only runs on Solaris 2.6 or above or Linux 6.x or above. If you would # like to try it, please manipulate only small objects at this time. #-D_HAS_STREAMS_SUPPORT # Include the above line in addition to -D_TGIF_WB2 if you have the # /usr/include/stropts.h file (such as Solaris 2.6 or above or Linux # 6.x or above. #-DBSD_COMP # Include the above line if you are compiling on a Solaris (or # possibly an SGI) machine which requires it in <sys/ioctl.h>. # (If you see the error that FIONBIO is not defined when compiling # tcp.c, then you probably need this.) #-D_BACKGROUND_DONT_FORK # Try the above line if there are defunct tgif child processes. #-D_NO_LSTAT # Include the above line if lstat() is not available. In this case, # using BrowseXBitmap and BrowseXPixmap under the File Menu may cause # infinite loop if the directory structure is infinitely recursive. #-D_USE_XDRAWPOINT_TO_PUT_A_POINT # Include the above line if the grid points are not visible. This can # be used to bypass some X server bugs (such as certain Linux X server # using VGA16 screen) where the XDrawLine() Xlib call does not work # properly. #-D_NO_EXTERN (obsoleted) # Include the above line in the DEFINES if you don't want to include # the extern definition for functions defined in a module. For example, # if this option is set, then file "foo.c" will not include "foo.e", # and certain other extern definition in "foo.c" will be omitted. #-D_NO_PROTO # Include the above line in the DEFINES if checking for function # prototypes is not desired. Checking for function prototypes # are automatically enabled if you are using an ANSI or C++ compilor. # However, not all ANSI/C++ compilors are created equal. #-D_BSD # Include the above line in the DEFINES if the select() function can # does not be found for AIX systems (such as RS6000). Also, on AIX # systems, if you see garbage file names when you try to open files, # try this flag to make direct and dirent equivalent (in <sys/dir.h>). #-D_NO_RAND48 # Include the above line in the DEFINES if you do not have the # srand48() or drand48() functions in your system's library. #-DNO_STRSTR # Include the above line in the DEFINES if you do not have the strstr() # function in your system's string library. #-DINVERT_CTM_BUG # Include the above line in the DEFINES if you are using PostScript # utilities which fails when trying to invert non-invertible CTM # (e.g., muluti.ps from ftp.ucc.su.oz.au:/pub/ps_printing/multi). #-DHP_LINE_BUG # Include the above line in the DEFINES if two-vertices horizontal and # verticle line segments don't draw properly on a buggy HP server. #-DDONTFREECOLORS # Include the above line in the DEFINES if you don't want the black and # the white colors to be freed when tgif initializes itself. You should # not need to do this unless you need to get around some server bugs. #-DUSE_XAPPLRESDIR # Include the above line in the DEFINES if $XAPPLRESDIR/Tgif is used to # specify the resource file. If your system does not have putenv() # (such as IBM-RT), then this won't work. #-DXAPPLOADDIR_DEF # If you define USE_XAPPLRESDIR, define this to a default directory # to use in case $XAPPLRESDIR isn't set. #-DUSE_XT_INITIALIZE # This will cause the XToolkit to be initialized so that the X defaults # are obtained from the Xt directories. This should only be used when # USE_XAPPLRESDIR option is NOT used. Please remember to use the # LOCAL_LIBRARIES with $(XTOOLLIB) $(XMULIB) above. #-DNO_THIN_LINE # Include the above line in the DEFINES if a line width of 0 causes # your server to crash. This is to get around a bug in some X servers. #-DTHIN_OVAL_AND_ARC # Include the above line in the DEFINES if you want 0 width arcs to # be used when the width of an arc is less than or equal to 1. # (Sun3 server has a bug that makes drawing ovals and arcs with # width other than 0 VERY slow). #-DKEEP_WHEN_PRINT # Include the above line in the DEFINES if you don't want the temp # file to be deleted after sending the print job to the printer. # (Some VMS systems might require this flag to be used.) #-DPRINT_CMD=\"lpr\" # Include the above line in the DEFINES if you want to configure tgif # to use a default print command. #-DNOTR4MODE # Include the above line in the DEFINES if you are running X11R3. # This will cause tgif NOT to use some X11R4 window manager related # functions that's not present in R3. #-DMAPBEFORESELECT # Include the above line in the DEFINES to call XMapWindow() before # calling XSelectInput(). This might be needed to get around some # server bugs. #-DDONT_FREE_COLORMAP # Include the above line in the DEFINES if you don't want the colormap # to be freed when tgif exits. #-DA4PAPER # Include the above line in the DEFINES if you want to print on A4 paper # (8.25in by 11.7in or about 21cm by 29.7cm). include make.common tgif: $(OBJS) # $(CC) -o tgif $(OBJS) /usr/lib/debug/malloc.o -g $(LDFLAGS) $(CC) -o tgif $(OBJS) -g $(LDFLAGS) all: tgif #prtgif frontend11.o testdrive @echo Making all ... prtgif: prtgif.o $(OBJ1) # $(CC) -o prtgif prtgif.o $(OBJ1) /usr/lib/debug/malloc.o -O $(LDFLAGS) $(CC) -o prtgif prtgif.o -O $(LDFLAGS) testdrive: testdrive.o $(OBJ1) # $(CC) -o prtgif prtgif.o $(OBJ1) /usr/lib/debug/malloc.o -O $(LDFLAGS) $(CC) -o testdrive testdrive.o $(OBJ1) -O $(LDFLAGS) frontend11.o: $(OBJ1) ld -o frontend11.o -r $(OBJ1) install: $(BINDIR)/tgif $(BINDIR)/prtgif \ $(TGIFDIR)/tgificon.eps $(TGIFDIR)/tgificon.obj \ $(TGIFDIR)/tgificon.xbm $(TGIFDIR)/tgificon.xpm \ $(TGIFDIR)/tangram.sym $(TGIFDIR)/tgif.Xdefaults \ $(TGIFDIR)/keys.obj @echo Making install ... $(BINDIR)/tgif: tgif $(INSTALL) -c $(INSTPGMFLAGS) tgif $(BINDIR)/tgif $(BINDIR)/prtgif: prtgif $(INSTALL) -c $(INSTPGMFLAGS) prtgif $(BINDIR)/prtgif $(TGIFDIR)/tgificon.eps: tgificon.eps $(INSTALL) -c tgificon.eps $(TGIFDIR)/tgificon.eps $(TGIFDIR)/tgificon.obj: tgificon.obj $(INSTALL) -c tgificon.obj $(TGIFDIR)/tgificon.obj $(TGIFDIR)/tgificon.xbm: tgificon.xbm $(INSTALL) -c tgificon.xbm $(TGIFDIR)/tgificon.xbm $(TGIFDIR)/tgificon.xpm: tgificon.xpm $(INSTALL) -c tgificon.xpm $(TGIFDIR)/tgificon.xpm $(TGIFDIR)/tangram.sym: tangram.sym $(INSTALL) -c tangram.sym $(TGIFDIR)/tangram.sym $(TGIFDIR)/tgif.Xdefaults: tgif.Xdefaults $(INSTALL) -c tgif.Xdefaults $(TGIFDIR)/tgif.Xdefaults $(TGIFDIR)/keys.obj: keys.obj $(INSTALL) -c keys.obj $(TGIFDIR)/keys.obj install.man: $(MANDIR)/tgif.$(MANSECTION) $(MANDIR)/prtgif.$(MANSECTION) @echo Making install.man ... $(MANDIR)/tgif.$(MANSECTION): tgif.man $(INSTALL) -c $(INSTMANFLAGS) tgif.man $(MANDIR)/tgif.$(MANSECTION) $(MANDIR)/prtgif.$(MANSECTION): prtgif.man $(INSTALL) -c $(INSTMANFLAGS) prtgif.man $(MANDIR)/prtgif.$(MANSECTION) .e.o: clean: rm -f tgif prtgif *.o core include make.comdep �����������������������������������������tgif-QPL-4.2.5/tgtwb5.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000003074�11602233313�014353� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgtwb5.e,v 1.6 2011/05/16 16:22:00 william Exp $ */ #ifndef _NO_TGTWB5 #ifndef _TGTWB5_E_ #define _TGTWB5_E_ #ifdef _INCLUDE_FROM_TGTWB5_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TGTWB5_C_*/ extern void Tgtwb5_CleanUp ARGS_DECL((Display*, Window)); extern int Tgtwb5_Init ARGS_DECL((Display*, Window, char *arg)); extern int Tgtwb5_SendKey ARGS_DECL((Display*, Window, XKeyEvent*, char*)); extern int Tgtwb5_HandleCntrlSpace ARGS_DECL((Display*, Window)); extern int Tgtwb5_HandleCreateText ARGS_DECL((Display*, Window)); #ifdef _INCLUDE_FROM_TGTWB5_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TGTWB5_C_*/ #endif /*_TGTWB5_E_*/ #endif /* ~_NO_TGTWB5 */ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/expr.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000101304�11602233311�014104� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/expr.c,v 1.6 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_EXPR_C_ #include "tgifdefs.h" #include "dialog.e" #include "expr.e" #include "msg.e" #include "setup.e" #include "strtbl.e" #include "util.e" #define OP_BEGIN 0 #define OP_IFTHEN 1 #define OP_ELSE 2 #define OP_OR 3 #define OP_AND 4 #define OP_BIT_OR 5 #define OP_BIT_XOR 6 #define OP_BIT_AND 7 #define OP_EQ 8 #define OP_NE 9 #define OP_GT 10 #define OP_LT 11 #define OP_GE 12 #define OP_LE 13 #define OP_SHIFT_LEFT 14 #define OP_SHIFT_RIGHT 15 #define OP_ADD 16 #define OP_SUB 17 #define OP_MUL 18 #define OP_DIV 19 #define OP_INTDIV 20 #define OP_MOD 21 #define OP_NOT 22 #define OP_BIT_NOT 23 #define OP_CLOSE 24 #define OP_OPEN 25 #define OP_END 26 struct OpRec { int op_code; int prec; struct OpRec *next; }; struct ValRec { struct VRec v; struct ValRec *next; }; static char *pszCurExpr=NULL; static char *pszExpr=NULL; static struct OpRec *topOpStk=NULL; static struct ValRec *topValStk=NULL; #ifdef NOT_DEFINED #ifdef _TGIF_DBG static int gnExprDebug=FALSE; #endif /* _TGIF_DBG */ #endif /* NOT_DEFINED */ static int BadOperandType(operator_str) char *operator_str; { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_EVAL_INVALID_OP_TYPE), pszCurExpr, operator_str); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } static int DivByZero(operator_str) char *operator_str; { sprintf(gszMsgBox, TgLoadString(STID_DIVIDE_BY_ZERO_FOR_OP_TYPE), operator_str); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } static int OpPrec(op_code) int op_code; { switch (op_code) { case OP_BEGIN: return INVALID; case OP_IFTHEN: return 1; /* '?' */ case OP_ELSE: return 2; /* ':' */ case OP_OR: return 3; /* || */ case OP_AND: return 4; /* && */ case OP_BIT_OR: return 5; /* | */ case OP_BIT_XOR: return 5; /* ^ */ case OP_BIT_AND: return 5; /* & */ case OP_EQ: return 6; /* == */ case OP_NE: return 6; /* != */ case OP_GT: return 7; /* > */ case OP_LT: return 7; /* < */ case OP_GE: return 7; /* >= */ case OP_LE: return 7; /* <= */ case OP_SHIFT_LEFT: return 8; /* << */ case OP_SHIFT_RIGHT: return 8; /* >> */ case OP_ADD: return 9; /* '+' */ case OP_SUB: return 9; /* '-' */ case OP_MUL: return 10; /* '*' */ case OP_DIV: return 10; /* '/' */ case OP_INTDIV: return 10; /* // */ case OP_MOD: return 10; /* % */ case OP_NOT: return 11; /* '!' */ case OP_BIT_NOT: return 11; /* ~ */ case OP_CLOSE: return 12; /* ')' */ case OP_OPEN: return 13; /* '(' */ case OP_END: return INVALID; } return 99; } #define MAX_OP_PREC 14 static int OpArity(op_code) int op_code; { switch (op_code) { case OP_BEGIN: return INVALID; case OP_IFTHEN: return 3; /* '?' */ case OP_ELSE: return 0; /* ':' */ case OP_OR: return 2; /* || */ case OP_AND: return 2; /* && */ case OP_BIT_OR: return 2; /* | */ case OP_BIT_XOR: return 2; /* ^ */ case OP_BIT_AND: return 2; /* & */ case OP_EQ: return 2; /* == */ case OP_NE: return 2; /* != */ case OP_GT: return 2; /* > */ case OP_LT: return 2; /* < */ case OP_GE: return 2; /* >= */ case OP_LE: return 2; /* <= */ case OP_SHIFT_LEFT: return 2; /* << */ case OP_SHIFT_RIGHT: return 2; /* >> */ case OP_ADD: return 2; /* '+' */ case OP_SUB: return 2; /* '-' */ case OP_MUL: return 2; /* '*' */ case OP_DIV: return 2; /* '/' */ case OP_INTDIV: return 2; /* // */ case OP_MOD: return 2; /* % */ case OP_NOT: return 1; /* '!' */ case OP_BIT_NOT: return 1; /* '~' */ case OP_CLOSE: return 0; /* ')' */ case OP_OPEN: return 0; /* '(' */ case OP_END: return INVALID; } sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_INVALID_OP_CODE), pszCurExpr, op_code); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return INVALID; } static int OpPush(op_code, cur_depth) int op_code; int cur_depth; { struct OpRec *op_ptr=(struct OpRec *)malloc(sizeof(struct OpRec)); if (op_ptr == NULL) return FailAllocMessage(); memset(op_ptr, 0, sizeof(struct OpRec)); op_ptr->op_code = op_code; op_ptr->prec = OpPrec(op_code)+cur_depth; op_ptr->next = topOpStk; topOpStk = op_ptr; return TRUE; } static int ValPush(v_ptr) struct VRec *v_ptr; { struct ValRec *val_ptr=(struct ValRec *)malloc(sizeof(struct ValRec)); if (val_ptr == NULL) return FailAllocMessage(); memset(val_ptr, 0, sizeof(struct ValRec)); memcpy(&val_ptr->v, v_ptr, sizeof(val_ptr->v)); val_ptr->next = topValStk; topValStk = val_ptr; return TRUE; } static int PopOpStk() { int op_code=topOpStk->op_code; struct OpRec *op_ptr=topOpStk; topOpStk = topOpStk->next; free(op_ptr); return op_code; } static void PopValStk(v_ptr) struct VRec *v_ptr; { struct ValRec *val_ptr=topValStk; topValStk = topValStk->next; if (v_ptr != NULL) { v_ptr->vtype = val_ptr->v.vtype; if (v_ptr->vtype == INT_VAL) { v_ptr->val.i = val_ptr->v.val.i; } else { v_ptr->val.d = val_ptr->v.val.d; } } free(val_ptr); } void CleanUpExpr() { if (pszCurExpr != NULL) { free(pszCurExpr); pszCurExpr = NULL; } if (pszExpr != NULL) { free(pszExpr); pszExpr = NULL; } while (topOpStk != NULL) PopOpStk(); while (topValStk != NULL) PopValStk(NULL); } int ExprAtomType(expr) char *expr; { char *dup_str, *c_ptr; int rc=INVALID; UtilTrimBlanks(expr); if (*expr == '\0') return NULL_VAL; dup_str = UtilStrDup(expr); if (dup_str == NULL) { FailAllocMessage(); return INVALID; } c_ptr = dup_str; if (*c_ptr == '-') c_ptr++; /* do not translate -- program constants */ if (strtok(c_ptr, "0123456789") == NULL) rc = INT_VAL; free(dup_str); if (rc != INVALID) return rc; dup_str = UtilStrDup(expr); if (dup_str == NULL) { FailAllocMessage(); return INVALID; } c_ptr = dup_str; if (*c_ptr == '-') c_ptr++; /* do not translate -- program constants */ rc = (strtok(c_ptr, ".0123456789") == NULL ? DBL_VAL : STR_VAL); free(dup_str); return rc; } static int EvalEquality(op_code, v, result_ptr) int op_code; struct VRec *v, *result_ptr; { int equal=TRUE; if (!(((v[1].vtype == INT_VAL || v[1].vtype == DBL_VAL) && (v[0].vtype == INT_VAL || v[0].vtype == DBL_VAL)) || ((v[1].vtype == NULL_VAL || v[1].vtype == STR_VAL) && (v[0].vtype == NULL_VAL || v[0].vtype == STR_VAL)))) { result_ptr->vtype = INT_VAL; switch (op_code) { case OP_EQ: result_ptr->val.i = FALSE; break; case OP_NE: result_ptr->val.i = TRUE; break; } return TRUE; } switch (v[1].vtype) { case INT_VAL: switch (v[0].vtype) { case INT_VAL: equal = (v[1].val.i == v[0].val.i); break; case DBL_VAL: equal = (fabs(((double)v[1].val.i)-v[0].val.d) < EQ_TOL); break; } break; case DBL_VAL: switch (v[0].vtype) { case INT_VAL: equal = (fabs(v[1].val.d-((double)v[0].val.i)) < EQ_TOL); break; case DBL_VAL: equal = (fabs(v[1].val.d-v[0].val.d) < EQ_TOL); break; } break; case NULL_VAL: switch (v[0].vtype) { case NULL_VAL: equal = TRUE; break; case STR_VAL: equal = (*v[0].val.s == '\0'); break; } case STR_VAL: switch (v[0].vtype) { case NULL_VAL: equal = (*v[1].val.s == '\0'); break; case STR_VAL: equal = (strcmp(v[1].val.s, v[0].val.s) == 0); break; } break; } result_ptr->vtype = INT_VAL; switch (op_code) { case OP_EQ: result_ptr->val.i = equal; break; case OP_NE: result_ptr->val.i = (!equal); break; } return TRUE; } static int EvalInequality(op_code, v, result_ptr) int op_code; struct VRec *v, *result_ptr; { int equal=TRUE, greater=FALSE; if (!(((v[1].vtype == INT_VAL || v[1].vtype == DBL_VAL) && (v[0].vtype == INT_VAL || v[0].vtype == DBL_VAL)) || ((v[1].vtype == NULL_VAL || v[1].vtype == STR_VAL) && (v[0].vtype == NULL_VAL || v[0].vtype == STR_VAL)))) { return FALSE; } switch (v[1].vtype) { case INT_VAL: switch (v[0].vtype) { case INT_VAL: equal = (v[1].val.i == v[0].val.i); if (!equal) { greater = (v[1].val.i > v[0].val.i); } break; case DBL_VAL: equal = (fabs(((double)v[1].val.i)-v[0].val.d) < EQ_TOL); if (!equal) { greater = (((double)v[1].val.i) > v[0].val.d); } break; } break; case DBL_VAL: switch (v[0].vtype) { case INT_VAL: equal = (fabs(v[1].val.d-((double)v[0].val.i)) < EQ_TOL); if (!equal) { greater = (v[1].val.d > ((double)v[0].val.i)); } break; case DBL_VAL: equal = (fabs(v[1].val.d-v[0].val.d) < EQ_TOL); if (!equal) { greater = (v[1].val.d > v[0].val.d); } break; } break; case NULL_VAL: switch (v[0].vtype) { case NULL_VAL: equal = TRUE; break; case STR_VAL: equal = (*v[0].val.s == '\0'); if (!equal) { greater = FALSE; } break; } case STR_VAL: switch (v[0].vtype) { case NULL_VAL: equal = (*v[1].val.s == '\0'); if (!equal) { greater = TRUE; } break; case STR_VAL: equal = strcmp(v[1].val.s, v[0].val.s); if (equal != 0) { greater = (equal > 0); equal = FALSE; } else { equal = TRUE; } break; } break; } result_ptr->vtype = INT_VAL; switch (op_code) { case OP_GT: result_ptr->val.i = ((!equal) && greater); break; case OP_LT: result_ptr->val.i = ((!equal) && (!greater)); break; case OP_GE: result_ptr->val.i = (equal || greater); break; case OP_LE: result_ptr->val.i = (equal || (!greater)); break; } return TRUE; } static int EvalMod(left, right) int left, right; { return (left-(right*((int)(left/right)))); } static int MultipleOf(left, right) double left, right; { double dmod=(left-(right*((int)(left/right)))); if (fabs(dmod) < EQ_TOL) return TRUE; return FALSE; } static int EvalArithmaticOp(op_code, op_str, v, result_ptr) int op_code; char *op_str; struct VRec *v, *result_ptr; { int left_ival, right_ival; double left_dval, right_dval; if (!((v[1].vtype == INT_VAL || v[1].vtype == DBL_VAL) && (v[0].vtype == INT_VAL || v[0].vtype == DBL_VAL))) { return BadOperandType(op_str); } left_ival = right_ival = 0; left_dval = right_dval = (double)0.0; switch (v[1].vtype) { case INT_VAL: switch (v[0].vtype) { case INT_VAL: switch (op_code) { case OP_ADD: result_ptr->vtype = INT_VAL; result_ptr->val.i = v[1].val.i + v[0].val.i; break; case OP_SUB: result_ptr->vtype = INT_VAL; result_ptr->val.i = v[1].val.i - v[0].val.i; break; case OP_MUL: result_ptr->vtype = INT_VAL; result_ptr->val.i = v[1].val.i * v[0].val.i; break; case OP_DIV: if (v[0].val.i == 0) { DivByZero(op_str); return FALSE; } if (EvalMod(v[1].val.i, v[0].val.i) == 0) { result_ptr->vtype = INT_VAL; result_ptr->val.i = v[1].val.i / v[0].val.i; } else { result_ptr->vtype = DBL_VAL; result_ptr->val.d = ((double)v[1].val.i) / ((double)v[0].val.i); } break; case OP_INTDIV: if (v[0].val.i == 0) { DivByZero(op_str); return FALSE; } result_ptr->vtype = INT_VAL; result_ptr->val.i = v[1].val.i / v[0].val.i; break; case OP_MOD: if (v[0].val.i == 0) { DivByZero(op_str); return FALSE; } result_ptr->vtype = INT_VAL; result_ptr->val.i = EvalMod(v[1].val.i, v[0].val.i); break; } break; case DBL_VAL: /* int op double */ switch (op_code) { case OP_ADD: result_ptr->vtype = DBL_VAL; result_ptr->val.d = ((double)v[1].val.i) + v[0].val.d; break; case OP_SUB: result_ptr->vtype = DBL_VAL; result_ptr->val.d = ((double)v[1].val.i) - v[0].val.d; break; case OP_MUL: result_ptr->vtype = DBL_VAL; result_ptr->val.d = ((double)v[1].val.i) * v[0].val.d; break; case OP_DIV: if (fabs(v[0].val.d) < EQ_TOL) { DivByZero(op_str); return FALSE; } result_ptr->vtype = DBL_VAL; result_ptr->val.d = ((double)v[1].val.i) / v[0].val.d; break; case OP_INTDIV: if (fabs(v[0].val.d) < EQ_TOL) { DivByZero(op_str); return FALSE; } result_ptr->vtype = INT_VAL; result_ptr->val.i = (int)(((double)v[1].val.i) / v[0].val.d); break; case OP_MOD: return BadOperandType(op_str); } break; } break; case DBL_VAL: switch (v[0].vtype) { case INT_VAL: /* double op int */ switch (op_code) { case OP_ADD: result_ptr->vtype = DBL_VAL; result_ptr->val.d = v[1].val.d + ((double)v[0].val.i); break; case OP_SUB: result_ptr->vtype = DBL_VAL; result_ptr->val.d = v[1].val.d - ((double)v[0].val.i); break; case OP_MUL: result_ptr->vtype = DBL_VAL; result_ptr->val.d = v[1].val.d * ((double)v[0].val.i); break; case OP_DIV: if (v[0].val.i == 0) { DivByZero(op_str); return FALSE; } result_ptr->vtype = DBL_VAL; result_ptr->val.d = v[1].val.d / ((double)v[0].val.i); break; case OP_INTDIV: if (v[0].val.i == 0) { DivByZero(op_str); return FALSE; } result_ptr->vtype = INT_VAL; result_ptr->val.i = (int)(v[1].val.d / ((double)v[0].val.i)); break; case OP_MOD: return BadOperandType(op_str); } break; case DBL_VAL: switch (op_code) { case OP_ADD: result_ptr->vtype = DBL_VAL; result_ptr->val.d = v[1].val.d + v[0].val.d; break; case OP_SUB: result_ptr->vtype = DBL_VAL; result_ptr->val.d = v[1].val.d - v[0].val.d; break; case OP_MUL: result_ptr->vtype = DBL_VAL; result_ptr->val.d = v[1].val.d * v[0].val.d; break; case OP_DIV: if (fabs(v[0].val.d) < EQ_TOL) { DivByZero(op_str); return FALSE; } if (MultipleOf(v[1].val.d, v[0].val.d)) { result_ptr->vtype = INT_VAL; result_ptr->val.i = round(v[1].val.d / v[0].val.d); } else { result_ptr->vtype = DBL_VAL; result_ptr->val.d = v[1].val.d / v[0].val.d; } break; case OP_INTDIV: if (fabs(v[0].val.d) < EQ_TOL) { DivByZero(op_str); return FALSE; } result_ptr->vtype = INT_VAL; result_ptr->val.i = (int)(v[1].val.d / v[0].val.d); break; case OP_MOD: return BadOperandType(op_str); } break; } break; } return TRUE; } static int Operate() { register int i; int arity, op_code; struct VRec v[3], result; if (topOpStk == NULL) { sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_EMPTY_OP_STACK), pszCurExpr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } op_code = PopOpStk(); arity = OpArity(op_code); if (arity == INVALID) return TRUE; for (i=0; i < 3; i++) memset(&v[i], 0, sizeof(struct VRec)); memset(&result, 0, sizeof(struct VRec)); for (i=0; i < arity; i++) { if (topValStk == NULL) { sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_EMPTY_OP_STACK), pszCurExpr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } PopValStk(&v[i]); } /* do not translate -- program constants */ switch (op_code) { case OP_IFTHEN: if (v[2].vtype != INT_VAL) return BadOperandType("?"); result.vtype = (v[2].val.i ? v[1].vtype : v[0].vtype); switch (result.vtype) { case NULL_VAL: return BadOperandType("?"); case INT_VAL: result.val.i = (v[2].val.i ? v[1].val.i : v[0].val.i); break; case DBL_VAL: result.val.d = (v[2].val.d ? v[1].val.d : v[0].val.d); break; case STR_VAL: return BadOperandType("?"); } break; case OP_ELSE: break; case OP_OR: if (v[1].vtype != INT_VAL || v[0].vtype != INT_VAL) { return BadOperandType("||"); } result.vtype = INT_VAL; result.val.i = (v[1].val.i || v[0].val.i); break; case OP_AND: if (v[1].vtype != INT_VAL || v[0].vtype != INT_VAL) { return BadOperandType("&&"); } result.vtype = INT_VAL; result.val.i = (v[1].val.i && v[0].val.i); break; case OP_BIT_OR: if (v[1].vtype != INT_VAL || v[0].vtype != INT_VAL) { return BadOperandType("|"); } result.vtype = INT_VAL; result.val.i = (v[1].val.i | v[0].val.i); break; case OP_BIT_XOR: if (v[1].vtype != INT_VAL || v[0].vtype != INT_VAL) { return BadOperandType("^"); } result.vtype = INT_VAL; result.val.i = (v[1].val.i ^ v[0].val.i); break; case OP_BIT_AND: if (v[1].vtype != INT_VAL || v[0].vtype != INT_VAL) { return BadOperandType("&"); } result.vtype = INT_VAL; result.val.i = (v[1].val.i & v[0].val.i); break; case OP_EQ: if (!EvalEquality(OP_EQ, v, &result)) { return BadOperandType("=="); } break; case OP_NE: if (!EvalEquality(OP_NE, v, &result)) { return BadOperandType("!="); } break; case OP_GT: if (!EvalInequality(OP_GT, v, &result)) { return BadOperandType(">"); } break; case OP_LT: if (!EvalInequality(OP_LT, v, &result)) { return BadOperandType("<"); } break; case OP_GE: if (!EvalInequality(OP_GE, v, &result)) { return BadOperandType(">="); } break; case OP_LE: if (!EvalInequality(OP_LE, v, &result)) { return BadOperandType("<="); } break; case OP_SHIFT_LEFT: if (v[1].vtype != INT_VAL || v[0].vtype != INT_VAL) { return BadOperandType("<<"); } result.vtype = INT_VAL; result.val.i = (v[1].val.i << v[0].val.i); break; case OP_SHIFT_RIGHT: if (v[1].vtype != INT_VAL || v[0].vtype != INT_VAL) { return BadOperandType(">>"); } result.vtype = INT_VAL; result.val.i = (v[1].val.i >> v[0].val.i); break; case OP_ADD: if (!EvalArithmaticOp(OP_ADD, "+", v, &result)) { return FALSE; } break; case OP_SUB: if (!EvalArithmaticOp(OP_SUB, "-", v, &result)) { return FALSE; } break; case OP_MUL: if (!EvalArithmaticOp(OP_MUL, "*", v, &result)) { return FALSE; } break; case OP_DIV: if (!EvalArithmaticOp(OP_DIV, "/", v, &result)) { return FALSE; } break; case OP_INTDIV: if (!EvalArithmaticOp(OP_INTDIV, "//", v, &result)) { return FALSE; } break; case OP_MOD: if (!EvalArithmaticOp(OP_MOD, "%", v, &result)) { return FALSE; } break; case OP_NOT: if (v[0].vtype != INT_VAL) { return BadOperandType("!"); } result.vtype = INT_VAL; result.val.i = (v[0].val.i == 0); break; case OP_BIT_NOT: if (v[0].vtype != INT_VAL) { return BadOperandType("~"); } result.vtype = INT_VAL; result.val.i = (~v[0].val.i); break; case OP_CLOSE: case OP_OPEN: break; } for (i=0; i < arity; i++) { if (v[i].vtype == STR_VAL && v[i].val.s != NULL) { free(v[i].val.s); v[i].val.s = NULL; } } return ValPush(&result); } static char szNumericChars[]=".0123456789"; static int ParseForNumericVal(ppsz_token, v) char **ppsz_token; struct VRec *v; { int seen_dot=FALSE; char saved_ch, *token=(*ppsz_token); for ( ; **ppsz_token != '\0'; (*ppsz_token)++) { char *c_ptr=strchr(szNumericChars, **ppsz_token); if (c_ptr == NULL) break; if (c_ptr == szNumericChars) { if (seen_dot) break; seen_dot = TRUE; } } memset(v, 0, sizeof(struct VRec)); saved_ch = **ppsz_token; **ppsz_token = '\0'; if (seen_dot) { v->vtype = DBL_VAL; if (sscanf(token, "%lf", &(v->val.d)) != 1) { **ppsz_token = saved_ch; sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_BAD_NUM_VALUE), pszCurExpr, token); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } else { v->vtype = INT_VAL; if (sscanf(token, "%d", &(v->val.i)) != 1) { **ppsz_token = saved_ch; sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_BAD_NUM_VALUE), pszCurExpr, token); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } **ppsz_token = saved_ch; return TRUE; } static int ParseForStringVal(ppsz_token, v) char **ppsz_token; struct VRec *v; { char *token=(*ppsz_token); for ((*ppsz_token)++; **ppsz_token != '\0'; (*ppsz_token)++) { if (**ppsz_token == '\\') { (*ppsz_token)++; } else if (**ppsz_token == '"') { break; } } if (**ppsz_token == '\0') { sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_BAD_STR_VALUE), pszCurExpr, token); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } memset(v, 0, sizeof(struct VRec)); **ppsz_token = '\0'; v->vtype = STR_VAL; v->val.s = UtilStrDup(&token[1]); **ppsz_token = '"'; (*ppsz_token)++; if (v->val.s == NULL) { sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_BAD_STR_VALUE), pszCurExpr, token); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return TRUE; } static int ParseForIDVal(ppsz_token, v) char **ppsz_token; struct VRec *v; { char *token=(*ppsz_token), saved_ch; for ( ; **ppsz_token != '\0'; (*ppsz_token)++) { if (!(**ppsz_token == '_' || (**ppsz_token >= 'a' && **ppsz_token <= 'z') || (**ppsz_token >= 'A' && **ppsz_token <= 'Z') || (**ppsz_token >= '0' && **ppsz_token <= '9'))) { break; } } memset(v, 0, sizeof(struct VRec)); saved_ch = **ppsz_token; **ppsz_token = '\0'; v->vtype = STR_VAL; v->val.s = UtilStrDup(token); **ppsz_token = saved_ch; if (v->val.s == NULL) { sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_BAD_IDENTIFIER), pszCurExpr, token); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return TRUE; } #ifdef NOT_DEFINED #ifdef _TGIF_DBG /* debug, do not translate */ static char *opName[] = { "BEGIN", "?", ":", "||", "&&", "|", "^", "&", "==", "!=", ">", "<", ">=", "<=", "<<", ">>", "+", "-", "*", "/", "//", "%", "!", "~", ")", "(", "END", NULL }; #define MAXOP 27 static void DebugOpStk() { struct OpRec *op_ptr=NULL; if (gnExprDebug) { } fprintf(stderr, "top of op stack -->\n"); for (op_ptr=topOpStk; op_ptr != NULL; op_ptr=op_ptr->next) { fprintf(stderr, " | %2s, %2d |\n", opName[op_ptr->op_code], OpPrec(op_ptr->op_code)); } fprintf(stderr, " |________|\n"); } #endif /* _TGIF_DBG */ #ifdef _TGIF_DBG /* debug, do not translate */ static void DebugValStk() { struct ValRec *v_ptr=NULL; if (gnExprDebug) { } fprintf(stderr, "top of val stack ->\n"); for (v_ptr=topValStk; v_ptr != NULL; v_ptr=v_ptr->next) { switch (v_ptr->v.vtype) { case NULL_VAL: fprintf(stderr, " | NULL\n"); break; case INT_VAL: fprintf(stderr, " | INT, %1d\n", v_ptr->v.val.i); break; case DBL_VAL: fprintf(stderr, " | DBL, %.3f\n", (float)(v_ptr->v.val.d)); break; case STR_VAL: fprintf(stderr, " | STR, \"%s\"\n", (v_ptr->v.val.s==NULL ? "NULL" : v_ptr->v.val.s)); break; } } fprintf(stderr, " |________...\n"); } #endif /* _TGIF_DBG */ #endif /* NOT_DEFINED */ static int ProcessOp(prec) int prec; { while (topOpStk != NULL && prec <= topOpStk->prec) { if (!Operate()) { return FALSE; } } return TRUE; } int EvalExpr(orig_expr, v_ptr) char *orig_expr; struct VRec *v_ptr; { int cur_depth=0, ok=TRUE, prev_token_is_op=TRUE; char *token; CleanUpExpr(); pszCurExpr = UtilStrDup(orig_expr); if (pszCurExpr == NULL) return FailAllocMessage(); UtilTrimBlanks(pszCurExpr); if (*pszCurExpr == '\0') { v_ptr->vtype = NULL_VAL; return TRUE; } memset(v_ptr, 0, sizeof(struct VRec)); pszExpr = UtilStrDup(pszCurExpr); if (pszExpr == NULL) return FailAllocMessage(); if (!OpPush(OP_BEGIN, cur_depth)) return FALSE; token = pszExpr; while (ok && *token != '\0') { struct VRec v; int op_code=INVALID; switch (*token) { case ' ': case '\t': case '\n': case '\r': token++; break; case '-': if (!prev_token_is_op || strchr(szNumericChars, token[1]) == NULL) { op_code = OP_SUB; token++; } else { char *new_token=(&token[1]); if (ParseForNumericVal(&new_token, &v)) { if (v.vtype == INT_VAL) { v.val.i = (-v.val.i); } else { v.val.d = (-v.val.d); } if (!ValPush(&v)) { ok = FALSE; } else { prev_token_is_op = FALSE; } } else { ok = FALSE; } token = new_token; } break; case '.': case '0': case '1': case '2': case '3': case '4': case '5': case '6': case '7': case '8': case '9': if (ParseForNumericVal(&token, &v)) { if (!ValPush(&v)) { ok = FALSE; } else { prev_token_is_op = FALSE; } } else { ok = FALSE; } break; case '"': if (ParseForStringVal(&token, &v)) { if (!ValPush(&v)) { ok = FALSE; } else { prev_token_is_op = FALSE; } } else { ok = FALSE; } break; case '?': op_code = OP_IFTHEN; token++; break; case ':': op_code = OP_ELSE; token++; break; case '|': if (token[1] == '|') { op_code = OP_BIT_OR; token = &token[2]; } else { op_code = OP_OR; token++; } break; case '^': op_code = OP_BIT_XOR; token++; break; case '&': if (token[1] == '&') { op_code = OP_BIT_AND; token = &token[2]; } else { op_code = OP_AND; token++; } break; case '=': if (token[1] == '=') { op_code = OP_EQ; token = &token[2]; } else { sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_BAD_OPERATOR), pszCurExpr, "="); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } break; case '>': switch (token[1]) { case '=': op_code = OP_GE; token = &token[2]; break; case '>': op_code = OP_SHIFT_RIGHT; token = &token[2]; break; default: op_code = OP_GT; token++; break; } break; case '<': switch (token[1]) { case '=': op_code = OP_LE; token = &token[2]; break; case '<': op_code = OP_SHIFT_LEFT; token = &token[2]; break; default: op_code = OP_LT; token++; break; } break; case '+': op_code = OP_ADD; token++; break; case '*': op_code = OP_MUL; token++; break; case '/': if (token[1] == '/') { op_code = OP_INTDIV; token = &token[2]; } else if (token[1] == '*') { for (token=(&token[2]); *token != '\0'; token++) { if (*token == '*' && token[1] == '/') { token = &token[2]; break; } } } else { op_code = OP_DIV; token++; } break; case '%': op_code = OP_MOD; token++; break; case '!': if (token[1] == '=') { op_code = OP_NE; token = &token[2]; } else { op_code = OP_NOT; token++; } break; case '~': op_code = OP_BIT_NOT; token++; break; case ')': op_code = OP_CLOSE; token++; break; case '(': op_code = OP_OPEN; token++; break; default: if (*token == '_' || (*token >= 'a' && *token <= 'z') || (*token >= 'A' && *token <= 'Z')) { if (ParseForIDVal(&token, &v)) { /* * if (*token == '(') { * push a function on the stack! * token++; * } */ if (!ValPush(&v)) { ok = FALSE; } else { prev_token_is_op = FALSE; } } else { ok = FALSE; } } else { sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_BAD_IDENTIFIER), pszCurExpr, token); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } break; } if (!ok) break; if (op_code != INVALID) { switch (op_code) { case OP_CLOSE: if (cur_depth == 0) { sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_TOO_MANY_SYMBOL), pszCurExpr, ')'); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else { cur_depth -= MAX_OP_PREC; if (!ProcessOp(OpPrec(op_code)+cur_depth)) { ok = FALSE; } } break; case OP_OPEN: cur_depth += MAX_OP_PREC; break; default: if (ProcessOp(OpPrec(op_code)+cur_depth)) { if (!OpPush(op_code, cur_depth)) { ok = FALSE; } } else { ok = FALSE; } break; } prev_token_is_op = TRUE; } } if (ok) { if (cur_depth != 0) { sprintf(gszMsgBox, TgLoadString(STID_ILLEGAL_EXPR_TOO_MANY_SYMBOL), pszCurExpr, '('); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else if (!ProcessOp((-1))) { ok = FALSE; } else if (topOpStk != NULL) { sprintf(gszMsgBox, TgLoadString(STID_ILL_EXPR_OP_STACK_NON_EMPTY), pszCurExpr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else if (topValStk == NULL) { sprintf(gszMsgBox, TgLoadString(STID_ILL_EXPR_VAL_STACK_NON_EMPTY), pszCurExpr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else if (topValStk->next != NULL) { sprintf(gszMsgBox, TgLoadString(STID_ILL_EXPR_TOO_MANY_VALS_LEFT), pszCurExpr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } else { memcpy(v_ptr, &topValStk->v, sizeof(struct VRec)); } } return ok; } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/version.c����������������������������������������������������������������������������0000644�0000764�0000764�00000004301�11602233313�014614� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/version.c,v 1.16 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_VERSION_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "version.e" char *versionString="4.2"; char *authorEmailString="bill.cheng@acm.org"; #ifdef QPL_LICENSE char *copyrightString="Copyright (C) 2001-2011, William Chia-Wei Cheng"; #else /* ~QPL_LICENSE */ char *copyrightString="Copyright (C) 1990-2011, William Chia-Wei Cheng"; #endif /* QPL_LICENSE */ char *homePageURL="http://bourbon.usc.edu/tgif/"; char *oldMailingList="kragen-tgif@kragen.dnaco.net"; char *mailingList="tgif4-announce@yahoogroups.com"; char *joinMailingList="tgif4-announce-subscribe@yahoogroups.com"; char *mailingURL="http://bourbon.usc.edu/tgif/faq/mailings.html"; char *currentReleaseURL="http://bourbon.usc.edu/tgif/download.html"; char *hyperGraphicsURL="http://bourbon.usc.edu/tgif/index.obj"; char fullVersionString[MAXSTRING]; char fullToolName[MAXSTRING]; #ifdef QPL_LICENSE char *specialBuild="QPL"; #else /* ~QPL_LICENSE */ char *specialBuild=""; #endif /* QPL_LICENSE */ void SetFullVersionString() { if (*specialBuild == '\0') { sprintf(fullVersionString, "%s.%1d", versionString, TGIF_PATCHLEVEL); } else { sprintf(fullVersionString, "%s.%1d-%s", versionString, TGIF_PATCHLEVEL, specialBuild); } sprintf(fullToolName, "%s-%s", TOOL_NAME, fullVersionString); } void InitVersion() { } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Tgif.tmpl-netbsd���������������������������������������������������������������������0000644�0000764�0000764�00000004373�11602233313�016040� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-netbsd,v 1.12 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_NO_IDNLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) XCOMM SYS_LIBRARIES = -ldl -lm -lz SYS_LIBRARIES = -lm -lz ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/shape.e������������������������������������������������������������������������������0000644�0000764�0000764�00000003445�11602233312�014240� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/shape.e,v 1.6 2011/05/16 16:21:59 william Exp $ */ #ifndef _SHAPE_E_ #define _SHAPE_E_ extern int numShapes; extern int curShape; extern int shapeShadowInResource; extern int shapeShadowDx; extern int shapeShadowDy; #ifdef _INCLUDE_FROM_SHAPE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_SHAPE_C_*/ extern void CleanUpShape ARGS_DECL((void)); extern void InitShape ARGS_DECL((void)); extern void ShapeSubMenu ARGS_DECL((int Index)); extern void RefreshShapeMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateShapeMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int ShapeMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void SetShapeShadow ARGS_DECL((void)); #ifdef _INCLUDE_FROM_SHAPE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_SHAPE_C_*/ #endif /*_SHAPE_E_*/ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/font.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000561517�11602233311�014114� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/font.c,v 1.42 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_FONT_C_ #include "tgifdefs.h" #include "cmdids.h" #include "auxtext.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "exec.e" #include "file.e" #include "font.e" #include "ini.e" #include "list.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "menuinfo.e" #include "miniline.e" #include "msg.e" #include "obj.e" #include "pattern.e" #include "page.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "select.e" #include "setup.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "version.e" #include "xpixmap.e" #define DEFAULT_FONT_SIZE 14 struct FontSizeRec { /* * For a font (given face and style), the xfs for various font sizes * are stored in a link list. * If the font is not scalable (faked==TRUE), the head of the link list * is used to scale fonts. * The vert field is TRUE for double-byte vertical fonts. */ XFontStruct *xfs; int sz_unit, faked, vert; struct FontSizeRec *next; }; struct FontFmlyRec { /* fr[i] points to the default size used for the given font */ /* this font is used if the requested size is not found */ struct FontSizeRec fr[MAXFONTSTYLES]; char *name_faked; int bitmapped_ps_font; int double_byte; char choice_char[3]; char *conv_from_utf8_cmd, *conv_to_utf8_cmd; }; typedef struct tagPSCharSubs { char *token_name; char *ps_char_name[128]; } PSCharSubs; XFontStruct *canvasFontPtr=NULL; int canvasFontHeight=0; int canvasFontAsc=0; int canvasFontDes=0; int canvasFontDirection=0; int canvasFontDontReencode=FALSE; int canvasFontDoubleByte=FALSE; int canvasFontDoubleByteModBytes=FALSE; int canvasFontDoubleByteVertical=FALSE; int canvasFontSize=0; int canvasFontIsFaked=FALSE; int canvasLineAsc=0; int canvasLineDes=0; XFontStruct *rulerFontPtr=NULL; int rulerFontWidth=0; int rulerFontHeight=0; int rulerFontAsc=0; int rulerFontDes=0; static char *rulerFontName=NULL; XFontStruct *defaultFontPtr=NULL; int defaultFontWidth=0; int defaultFontHeight=0; int defaultFontAsc=0; int defaultFontDes=0; static char *defaultFontName=NULL; XFontStruct *menuFontPtr=NULL; int menuFontWidth=0; int menuFontHeight=0; int menuFontAsc=0; int menuFontDes=0; static char *menuFontName=NULL; #ifdef ENABLE_NLS XFontSet menuFontSet=NULL; XFontSet msgFontSet=NULL; XFontSet boldMsgFontSet=NULL; XFontSet italicMsgFontSet=NULL; XFontSet boldItalicMsgFontSet=NULL; #else /* ~ENABLE_NLS */ char *menuFontSet=NULL; char *msgFontSet=NULL; char *boldMsgFontSet=NULL; char *italicMsgFontSet=NULL; char *boldItalicMsgFontSet=NULL; #endif /* ENABLE_NLS */ int boldMsgFontDoubleByte=FALSE; static char *menuFontSetName=NULL; static char *msgFontSetName=NULL; static char *boldMsgFontSetName=NULL; static char *italicMsgFontSetName=NULL; static char *boldItalicMsgFontSetName=NULL; XFontStruct *boldMsgFontPtr=NULL; int boldMsgFontWidth=0; int boldMsgFontHeight=0; int boldMsgFontAsc=0; int boldMsgFontDes=0; static char *boldMsgFontName=NULL; XFontStruct *italicMsgFontPtr=NULL; int italicMsgFontWidth=0; int italicMsgFontHeight=0; int italicMsgFontAsc=0; int italicMsgFontDes=0; static char *italicMsgFontName=NULL; XFontStruct *boldItalicMsgFontPtr=NULL; int boldItalicMsgFontWidth=0; int boldItalicMsgFontHeight=0; int boldItalicMsgFontAsc=0; int boldItalicMsgFontDes=0; static char *boldItalicMsgFontName=NULL; XFontStruct *msgFontPtr=NULL; int msgFontWidth=0; int msgFontHeight=0; int msgFontAsc=0; int msgFontDes=0; static char *msgFontName=NULL; int curFont=FONT_COU; int initialFont=FONT_COU; int curSzUnit=(20*NUM_SZ_UNIT_PER_FONT_SIZE), curRealSzUnit=INVALID; int curStyle=STYLE_NR; int textRotation=0; /* degrees*64 */ int curUnderlineOn=FALSE; int curOverlineOn=FALSE; int actualCurFont=(-1); int actualCurSzUnit=(-1); int actualCurStyle=(-1); int curUnderlineYOffset=2; int curOverlineYOffset=(-1); int changePropertiesOfAttrs=FALSE; static int defaultCurFont=(-1); static int defaultCurSzUnit=(-1); static int defaultCurStyle=(-1); static char *initSizeMenuStr[] = { "8", "10", "11", "12", "14", "17", "18", "20", "24", "25", "34" }; char **fontMenuStr=NULL; char *defFontMenuStr[] = { "Times", "Courier", "Helvetica", "NewCenturySchlbk", "Symbol" }; char **sizeMenuStr=NULL; int *fontSzUnits=NULL; int numFonts=MAXFONTS; int numFontSizes=MAXFONTS; int changingFontSizeFromRead=TRUE; int allowFontFaceSubstitution=TRUE; char cmdLineDontReencode[MAXSTRING<<1]; int defaultFontSize=DEFAULT_FONT_SIZE; int showFontSizeInPoints=FALSE; int substitutedFont=INVALID; int substitutedFontSzUnit=0; int defaultSingleByteFont=FONT_TIM; int gnNumPSFontAliases=0; KeyValInfo *gaPSFontAliases=NULL; int gnNumPSFontNeedCharSubs=0; KeyValInfo *gaPSFontNeedCharSubs=NULL; CVList psCharSubsList; static int numFakedFonts=0; static char fontNamePrefix[MAXSTRING+1]; static char defaultLatin1FontCharEncoding[MAXSTRING+1]; static int hasAlternateDefaultFonts=FALSE; static int reportMissingFonts=FALSE; static struct FontFmlyRec *fontFamilies=NULL; static char *initFontInfoStr[]={ /* do not translate -- program constants */ "times-medium-r-normal", "iso8859-1", "Times-Roman", "times-bold-r-normal", "iso8859-1", "Times-Bold", "times-medium-i-normal", "iso8859-1", "Times-Italic", "times-bold-i-normal", "iso8859-1", "Times-BoldItalic", "courier-medium-r-normal", "iso8859-1", "Courier", "courier-bold-r-normal", "iso8859-1", "Courier-Bold", "courier-medium-o-normal", "iso8859-1", "Courier-Oblique", "courier-bold-o-normal", "iso8859-1", "Courier-BoldOblique", "helvetica-medium-r-normal", "iso8859-1", "Helvetica", "helvetica-bold-r-normal", "iso8859-1", "Helvetica-Bold", "helvetica-medium-o-normal", "iso8859-1", "Helvetica-Oblique", "helvetica-bold-o-normal", "iso8859-1", "Helvetica-BoldOblique", "new century schoolbook-medium-r-normal", "iso8859-1", "NewCenturySchlbk-Roman", "new century schoolbook-bold-r-normal", "iso8859-1", "NewCenturySchlbk-Bold", "new century schoolbook-medium-i-normal", "iso8859-1", "NewCenturySchlbk-Italic", "new century schoolbook-bold-i-normal", "iso8859-1", "NewCenturySchlbk-BoldItalic", "*symbol*-medium-r-normal", "adobe-fontspecific", "Symbol", "*symbol*-medium-r-normal", "adobe-fontspecific", "Symbol", "*symbol*-medium-r-normal", "adobe-fontspecific", "Symbol", "*symbol*-medium-r-normal", "adobe-fontspecific", "Symbol", NULL, NULL, NULL }; static char **altFontInfoStr=NULL; static char **fontInfoStr=NULL; static char *charCodeToName[] = { /* do not translate -- program constants */ /* \200 */ "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", /* \220 */ "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", "", /* \240 */ "x", "8#241 /exclamdown", "8#242 /cent", "8#243 /sterling", "8#244 /currency", "8#245 /yen", "8#246 /bar", "8#247 /section", "8#250 /dieresis", "8#251 /copyright", "8#252 /ordfeminine", "8#253 /guillemotleft", "8#254 /logicalnot", "8#255 /emdash", "8#256 /registered", "8#257 /macron", /* \260 */ "8#260 /degree", "8#261 /plusminus", "8#262 /twosuperior", "8#263 /threesuperior", "8#264 /acute", "8#265 /mu", "8#266 /paragraph", "8#267 /periodcentered", "8#270 /cedilla", "8#271 /onesuperior", "8#272 /ordmasculine", "8#273 /guillemotright", "8#274 /onequarter", "8#275 /onehalf", "8#276 /threequarters", "8#277 /questiondown", /* \300 */ "8#300 /Agrave", "8#301 /Aacute", "8#302 /Acircumflex", "8#303 /Atilde", "8#304 /Adieresis", "8#305 /Aring", "8#306 /AE", "8#307 /Ccedilla", "8#310 /Egrave", "8#311 /Eacute", "8#312 /Ecircumflex", "8#313 /Edieresis", "8#314 /Igrave", "8#315 /Iacute", "8#316 /Icircumflex", "8#317 /Idieresis", /* \320 */ "8#320 /Eth", "8#321 /Ntilde", "8#322 /Ograve", "8#323 /Oacute", "8#324 /Ocircumflex", "8#325 /Otilde", "8#326 /Odieresis", "8#327 /multiply", "8#330 /Oslash", "8#331 /Ugrave", "8#332 /Uacute", "8#333 /Ucircumflex", "8#334 /Udieresis", "8#335 /Yacute", "8#336 /Thorn", "8#337 /germandbls", /* \340 */ "8#340 /agrave", "8#341 /aacute", "8#342 /acircumflex", "8#343 /atilde", "8#344 /adieresis", "8#345 /aring", "8#346 /ae", "8#347 /ccedilla", "8#350 /egrave", "8#351 /eacute", "8#352 /ecircumflex", "8#353 /edieresis", "8#354 /igrave", "8#355 /iacute", "8#356 /icircumflex", "8#357 /idieresis", /* \360 */ "8#360 /eth", "8#361 /ntilde", "8#362 /ograve", "8#363 /oacute", "8#364 /ocircumflex", "8#365 /otilde", "8#366 /odieresis", "8#367 /divide", "8#370 /oslash", "8#371 /ugrave", "8#372 /uacute", "8#373 /ucircumflex", "8#374 /udieresis", "8#375 /yacute", "8#376 /thorn", "8#377 /ydieresis" }; #define InfoIndex(FontIdx,StyleIdx) (((FontIdx)*MAXFONTSTYLES+(StyleIdx))*3) #define InfoIndexToFontIndex(InfoIdx) ((int)(((int)(InfoIdx/3))/MAXFONTSTYLES)) static int debugScalableFonts=FALSE; /* debug scalable font */ static char gszAttemptedFontName[MAXSTRING+1]; static struct PushedFontRec gstSavedFontInfo; int IsFontDoubleByte(font_index) int font_index; { return fontFamilies[font_index].double_byte; } int IsDoubleByteFontVertical(font_index, style) int font_index, style; { return fontFamilies[font_index].fr[style].vert; } int CanConvertUTF8ToFont(font_index) int font_index; { return (fontFamilies[font_index].double_byte && fontFamilies[font_index].conv_from_utf8_cmd != NULL); } int CanConvertFontToUTF8(font_index) int font_index; { return (fontFamilies[font_index].double_byte && fontFamilies[font_index].conv_to_utf8_cmd != NULL); } int ConvertToOrFromUTF8(which, font_index, ppsz_cut_buffer) int which, font_index; char **ppsz_cut_buffer; { int bytes_read=0, len=strlen(*ppsz_cut_buffer), total_bytes=0; char *cmd=NULL, buf[1024], tmp_fname[MAXPATHLENGTH], *c_ptr=NULL; FILE *fp=NULL, *pfp=NULL; CVList list; CVListElem *pElem=NULL; if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { return FALSE; } if ((fp=fopen(tmp_fname, "w")) == NULL) { return FailToOpenMessage(tmp_fname, "w", NULL); } if ((int)fwrite(*ppsz_cut_buffer, sizeof(char), len, fp) <= 0) { fclose(fp); FailToWriteFileMessage(tmp_fname); unlink(tmp_fname); return FALSE; } fclose(fp); if (which == CONVERT_TO_UTF8) { if (strstr(fontFamilies[font_index].conv_to_utf8_cmd, "%s") == NULL) { snprintf(gszMsgBox, sizeof(gszMsgBox), "%s %s", fontFamilies[font_index].conv_to_utf8_cmd, tmp_fname); } else { snprintf(gszMsgBox, sizeof(gszMsgBox), fontFamilies[font_index].conv_to_utf8_cmd, tmp_fname); } } else { if (strstr(fontFamilies[font_index].conv_from_utf8_cmd, "%s") == NULL) { snprintf(gszMsgBox, sizeof(gszMsgBox), "%s %s", fontFamilies[font_index].conv_from_utf8_cmd, tmp_fname); } else { snprintf(gszMsgBox, sizeof(gszMsgBox), fontFamilies[font_index].conv_from_utf8_cmd, tmp_fname); } } cmd = UtilStrDup(gszMsgBox); if (cmd == NULL) FailAllocMessage(); sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), cmd); Msg(gszMsgBox); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pfp=(FILE*)popen(cmd, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(tmp_fname); UtilFree(cmd); return FALSE; } CVListInit(&list); *buf = '\0'; while ((bytes_read=fread(buf, sizeof(char), sizeof(buf), pfp)) > 0) { struct DynStrRec *dyn_str=NewDynStr(); total_bytes += bytes_read; dyn_str->s = (char*)malloc(bytes_read+1); if (dyn_str->s == NULL) FailAllocMessage(); memcpy(dyn_str->s, buf, bytes_read); dyn_str->sz = bytes_read+1; ListAppend(&list, dyn_str); } pclose(pfp); unlink(tmp_fname); UtilFree(cmd); UtilFree(*ppsz_cut_buffer); *ppsz_cut_buffer = (char*)malloc(total_bytes+1); if (*ppsz_cut_buffer == NULL) FailAllocMessage(); c_ptr = (*ppsz_cut_buffer); for (pElem=ListFirst(&list); pElem != NULL; pElem=ListNext(&list, pElem)) { struct DynStrRec *dyn_str=(struct DynStrRec *)(pElem->obj); memcpy(c_ptr, dyn_str->s, dyn_str->sz-1); c_ptr += dyn_str->sz-1; FreeDynStrBuf(dyn_str); } ListUnlinkAll(&list); *c_ptr = '\0'; return TRUE; } int GetInitialFont() { return initialFont; } static int DoesFontExist(font_name, double_byte) char *font_name; int double_byte; { char *buf=NULL, **font_list=NULL; int actual_count_return=FALSE; if (font_name == NULL) return FALSE; UtilTrimBlanks(font_name); buf = (char*)malloc((strlen(font_name)<<1) + 1); if (buf == NULL) FailAllocMessage(); memset(buf, 0, (strlen(font_name)<<1) + 1); /* replace "%d" to "*" */ if (strchr(font_name, '%') == NULL) { sprintf(buf, "*%s*", font_name); } else { char *dest=NULL, *src=NULL; dest = buf; if (!double_byte) { *dest++ = '*'; } for (src=font_name; *src != '\0'; src++) { char ch2=src[1]; if (*src=='%' && ((ch2>='a' && ch2<='z') || (ch2>='A' && ch2<='Z'))) { src++; *dest++ = '*'; } else { *dest++ = (*src); } } if (!double_byte) { *dest++ = '*'; } *dest = '\0'; } font_list = XListFonts(mainDisplay, buf, 1, &actual_count_return); if (font_list) { XFreeFontNames(font_list); } free(buf); return (actual_count_return > 0); } int SzUnitToFontSize(sz_unit) int sz_unit; { double d=(double)(((double)sz_unit)/((double)NUM_SZ_UNIT_PER_FONT_SIZE)); return ((int)(round(d))); } int SzUnitToPointSize(sz_unit) int sz_unit; { double d=(double)(((double)sz_unit)/((double)NUM_SZ_UNIT_PER_POINT_SIZE)); return ((int)(round(d))); } int BadDoubleByteString(pszStr, pszZero) char *pszStr, *pszZero; { fprintf(stderr, "%s\n", TgLoadString(STID_ILLEGAL_DOUBLE_BYTE_TRUNC)); SaveDoubleByteString(stderr, pszStr); fprintf(stderr, "\n"); *(--pszZero) = '\0'; return FALSE; } char *GetPrevChar(nDoubleByte, pszStr, pszCur) int nDoubleByte; char *pszStr, *pszCur; { if (pszStr == pszCur) return NULL; if (nDoubleByte) { char *psz=NULL, *pszLast=NULL; for (psz=pszStr; *psz != '\0'; psz++) { int double_byte=FALSE; if (psz == pszCur) return pszLast; pszLast = psz; double_byte = ((*psz)&0x80); if (double_byte) { if (*(++psz) == '\0') { BadDoubleByteString(pszStr, psz); return NULL; } } } return pszLast; } else { return (--pszCur); } } char *GetShowFontChar(FontIndex) int FontIndex; { if (*fontFamilies[FontIndex].choice_char == '\0') { if (canvasFontDoubleByte) { int min_byte1=canvasFontPtr->min_byte1; int max_byte1=canvasFontPtr->max_byte1; int min_byte2=canvasFontPtr->min_char_or_byte2; int max_byte2=canvasFontPtr->max_char_or_byte2; fontFamilies[FontIndex].choice_char[0] = ((min_byte1+max_byte1)>>1); fontFamilies[FontIndex].choice_char[1] = ((min_byte2+max_byte2)>>1); fontFamilies[FontIndex].choice_char[2] = '\0'; return fontFamilies[FontIndex].choice_char; } return NULL; } return fontFamilies[FontIndex].choice_char; } static void RecordDoubleByteFontInfo(xfs, pszSection) XFontStruct *xfs; char *pszSection; { #ifdef _TGIF_DBG /* debug, do not translate */ char szIniFile[MAXPATHLENGTH]; sprintf(szIniFile, "%s%cfontinfo.ini", tgifDir, DIR_SEP); tgWriteProfileString(pszSection, NULL, NULL, szIniFile); sprintf(gszMsgBox, "\\%03o", (int)(xfs->min_byte1)); tgWriteProfileString(pszSection, "min_byte1", gszMsgBox, szIniFile); sprintf(gszMsgBox, "\\%03o", (int)(xfs->max_byte1)); tgWriteProfileString(pszSection, "max_byte1", gszMsgBox, szIniFile); sprintf(gszMsgBox, "\\%03o", (int)(xfs->min_char_or_byte2)); tgWriteProfileString(pszSection, "min_byte2", gszMsgBox, szIniFile); sprintf(gszMsgBox, "\\%03o", (int)(xfs->max_char_or_byte2)); tgWriteProfileString(pszSection, "max_byte2", gszMsgBox, szIniFile); sprintf(gszMsgBox, "%1d", (int)(xfs->ascent)); tgWriteProfileString(pszSection, "ascent", gszMsgBox, szIniFile); sprintf(gszMsgBox, "%1d", (int)(xfs->descent)); tgWriteProfileString(pszSection, "descent", gszMsgBox, szIniFile); tgWriteProfileString(NULL, NULL, NULL, szIniFile); #endif /* _TGIF_DBG */ } #define X_FONT_PREFIX 0 #define X_FONT_SUFFIX 1 #define PS_FONT_NAME 2 void GetCurFontInfoStr(buf, buf_sz) char* buf; int buf_sz; { int font_index=curFont; int style_index=curStyle; int size=SzUnitToFontSize(curSzUnit); int info_index=InfoIndex(font_index, style_index); if (strstr(fontInfoStr[info_index], "%d") != NULL) { sprintf(gszAttemptedFontName, fontInfoStr[info_index], size); } else { sprintf(gszAttemptedFontName, "%s-%s-*-%1d-*-*-*-*-*-%s", fontNamePrefix, fontInfoStr[info_index+X_FONT_PREFIX], size, fontInfoStr[info_index+X_FONT_SUFFIX]); } UtilStrCpyN(buf, buf_sz, gszAttemptedFontName); } XFontStruct *LoadAFontByName(psz_font_name, double_byte, can_debug) char *psz_font_name; int double_byte, can_debug; { XFontStruct *xfs=NULL; sprintf(gszMsgBox, TgLoadCachedString(CSTID_LOADING_FILE), psz_font_name); SetStringStatus(gszMsgBox); xfs = XLoadQueryFont(mainDisplay, psz_font_name); if (xfs != NULL && double_byte && can_debug && (xfs->min_byte1 != 0 || xfs->max_byte1 != 0)) { RecordDoubleByteFontInfo(xfs, psz_font_name); if ((xfs->min_byte1 & 0x80) != (xfs->max_byte1 & 0x80)) { sprintf(gszMsgBox, TgLoadString(STID_TOOL_CANT_HANDLE_DB_FONT), psz_font_name, (int)(xfs->min_byte1), (int)(xfs->max_byte1), TOOL_NAME, authorEmailString); fprintf(stderr, "%s\n", gszMsgBox); MsgBox(gszMsgBox, TOOL_NAME, STOP_MB); } } return xfs; } static void LoadAFont(info_index, size, can_debug, pxfs, pn_vert) int info_index, size, can_debug, *pn_vert; XFontStruct **pxfs; { int watch_cursor=watchCursorOnMainWindow; int font_index=InfoIndexToFontIndex(info_index); int supposedly_double_byte=fontFamilies[font_index].double_byte; XFontStruct *xfs=NULL; *pxfs = NULL; *pn_vert = FALSE; if (!watch_cursor && mainWindow != None && !RedrawDuringScrolling()) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } if (strstr(fontInfoStr[info_index], "%d") != NULL) { sprintf(gszAttemptedFontName, fontInfoStr[info_index], size); if (UtilStrICmp(fontInfoStr[info_index+X_FONT_SUFFIX], "V") == 0) { *pn_vert = TRUE; } } else { sprintf(gszAttemptedFontName, "%s-%s-*-%1d-*-*-*-*-*-%s", fontNamePrefix, fontInfoStr[info_index+X_FONT_PREFIX], size, fontInfoStr[info_index+X_FONT_SUFFIX]); } xfs = LoadAFontByName(gszAttemptedFontName, supposedly_double_byte, can_debug); if (xfs != NULL && can_debug && debugScalableFonts) { int i; for (i=0; i < (MAXFONTSIZES<<1)-1; i++) { if (atoi(initSizeMenuStr[i]) == size) { break; } } if (i >= (MAXFONTSIZES<<1)-1) { XFreeFont(mainDisplay, xfs); xfs = NULL; } } if (!watch_cursor && mainWindow != None && !RedrawDuringScrolling()) { SetDefaultCursor(mainWindow); ShowCursor(); } *pxfs = xfs; } static struct FontSizeRec *FindFontInfo(font_index, style_index, sz_unit, must_find) int font_index, style_index, sz_unit, must_find; { struct FontSizeRec *fs_ptr, *prev_fs=NULL, *new_fs_ptr; int info_index, watch_cursor=watchCursorOnMainWindow, vert=FALSE; XFontStruct *xfs=NULL; canvasFontIsFaked = FALSE; *gszAttemptedFontName = '\0'; for (fs_ptr=fontFamilies[font_index].fr[style_index].next; fs_ptr != NULL; fs_ptr=fs_ptr->next) { if (fs_ptr->sz_unit == sz_unit) { canvasFontIsFaked = fs_ptr->faked; return (canvasFontIsFaked ? &fontFamilies[font_index].fr[style_index] : fs_ptr); } if (fs_ptr->sz_unit > sz_unit) break; prev_fs = fs_ptr; } info_index = InfoIndex(font_index, style_index); SaveStatusStrings(); LoadAFont(info_index, SzUnitToFontSize(sz_unit), TRUE, &xfs, &vert); if (xfs == NULL) { if (must_find) return NULL; canvasFontIsFaked = TRUE; xfs = fontFamilies[font_index].fr[style_index].xfs; if (xfs == NULL) { LoadAFont(info_index, defaultFontSize, FALSE, &xfs, &vert); fontFamilies[font_index].fr[style_index].xfs = xfs; fontFamilies[font_index].fr[style_index].sz_unit = FontSizeToSzUnit(defaultFontSize); if (xfs != NULL && defaultCurFont == (-1) && !IsFontDoubleByte(font_index)) { defaultCurFont = font_index; defaultCurStyle = style_index; defaultCurSzUnit = FontSizeToSzUnit(defaultFontSize); } if (xfs == NULL) { if (allowFontFaceSubstitution) { /* * Even for a double-byte font, substitute Courier font anyway! */ int default_info_index=(-1); char failed_font_name[MAXSTRING]; if (defaultCurFont == (-1)) { defaultCurFont = FONT_COU; defaultCurStyle = STYLE_NR; defaultCurSzUnit = FontSizeToSzUnit(14); } default_info_index = InfoIndex(defaultCurFont,defaultCurStyle); LoadAFont(default_info_index, defaultFontSize, FALSE, &xfs, &vert); fontFamilies[font_index].fr[style_index].xfs = xfs; fontFamilies[font_index].fr[style_index].sz_unit = defaultCurSzUnit; if (xfs == NULL) { if (!watch_cursor && mainWindow!=None) { SetDefaultCursor(mainWindow); ShowCursor(); } RestoreStatusStrings(); return NULL; } GetCurFontInfoStr(failed_font_name, sizeof(failed_font_name)); sprintf(gszMsgBox, TgLoadString(STID_FAIL_LOAD_FONT_FONT_SUBS), gszAttemptedFontName, fontInfoStr[default_info_index+PS_FONT_NAME], SzUnitToFontSize(defaultCurSzUnit), fontInfoStr[info_index+PS_FONT_NAME], SzUnitToFontSize(sz_unit)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); actualCurFont = defaultCurFont; actualCurStyle = defaultCurStyle; actualCurSzUnit = defaultCurSzUnit; } } else if (changingFontSizeFromRead) { sprintf(gszMsgBox, TgLoadString(STID_FONT_SUBSTITUTED), fontInfoStr[info_index+PS_FONT_NAME], defaultFontSize, fontInfoStr[info_index+PS_FONT_NAME], SzUnitToFontSize(sz_unit)); Msg(gszMsgBox); } } } else if (defaultCurFont == (-1) && !IsFontDoubleByte(font_index)) { defaultCurFont = font_index; defaultCurStyle = style_index; defaultCurSzUnit = sz_unit; } if (!watch_cursor && mainWindow!=None) { SetDefaultCursor(mainWindow); ShowCursor(); } RestoreStatusStrings(); if (xfs == NULL) return NULL; new_fs_ptr = (struct FontSizeRec *)malloc(sizeof(struct FontSizeRec)); if (new_fs_ptr == NULL) FailAllocMessage(); memset(new_fs_ptr, 0, sizeof(struct FontSizeRec)); new_fs_ptr->next = fs_ptr; new_fs_ptr->faked = canvasFontIsFaked; new_fs_ptr->xfs = xfs; new_fs_ptr->sz_unit = sz_unit; new_fs_ptr->vert = vert; if (prev_fs == NULL) { fontFamilies[font_index].fr[style_index].next = new_fs_ptr; } else { prev_fs->next = new_fs_ptr; } return (canvasFontIsFaked ? &fontFamilies[font_index].fr[style_index]: new_fs_ptr); } void GetPSFontStr(FontIndex, StyleIndex, FontStr) int FontIndex, StyleIndex; char *FontStr; { if (PRTGIF && !cmdLineOpenDisplay) { if (FontIndex < MAXFONTS) { sprintf(FontStr, "/%s", initFontInfoStr[InfoIndex(FontIndex,StyleIndex)+PS_FONT_NAME]); } else { sprintf(FontStr, "/%s", fontFamilies[FontIndex].name_faked); } } else { if (FontIndex < numFonts) { sprintf(FontStr, "/%s", fontInfoStr[InfoIndex(FontIndex,StyleIndex)+PS_FONT_NAME]); } else { sprintf(FontStr, "/%s", fontFamilies[FontIndex].name_faked); } } } XFontStruct *LoadASymbolFont(font_size) int font_size; { int info_index=InfoIndex(FONT_SYM, STYLE_NR), vert=FALSE; XFontStruct *xfs=NULL; SaveStatusStrings(); LoadAFont(info_index, font_size, TRUE, &xfs, &vert); RestoreStatusStrings(); return xfs; } static char *LookupPSFontAliases(buf) char *buf; { int i=0; for (i=0; i < gnNumPSFontAliases; i++) { KeyValInfo *pKeyValue=(&gaPSFontAliases[i]); if (pKeyValue == NULL) return FALSE; if (pKeyValue != NULL && pKeyValue->key != NULL && strcmp(pKeyValue->key, buf) == 0) { return pKeyValue->value; } } return NULL; } void MapAliasedPSFontName(buf, buf_sz) char *buf; int buf_sz; { char *real_ps_font_name=NULL; if ((real_ps_font_name=LookupPSFontAliases(&buf[1])) != NULL) { UtilStrCpyN(&buf[1], buf_sz-1, real_ps_font_name); } } void SetTextExtentsInfo(pTextExtents) TextExtentsInfo *pTextExtents; { if (pTextExtents->buf == NULL || pTextExtents->len == 0) { pTextExtents->w = pTextExtents->lbearing = pTextExtents->rextra = 0; pTextExtents->bbox_w = 0; } else { XCharStruct xcs; MyTextExtents(canvasFontPtr, pTextExtents->buf, pTextExtents->len, &xcs); pTextExtents->w = xcs.width; pTextExtents->lbearing = (xcs.lbearing >= 0 ? 0 : xcs.lbearing); pTextExtents->rextra = xcs.rbearing - xcs.width; pTextExtents->bbox_w = pTextExtents->w - pTextExtents->lbearing + pTextExtents->rextra; } pTextExtents->bbox_h = canvasFontHeight; pTextExtents->asc = canvasFontAsc; pTextExtents->des = canvasFontDes; } struct StrRec *SegmentDoubleByteString(pszStr) char *pszStr; { struct StrRec *pFirstStr=NULL, *pLastStr=NULL; int nLen=strlen(pszStr), nIndex=0; if (nLen == 0) { return NewStr(); } while (nIndex < nLen) { int nSubStrIndex=0, nDoubleByte; char *psz=NULL, *pszStart=NULL, saved_ch='\0'; struct StrRec *pStr=NULL; pszStart = &pszStr[nIndex]; nDoubleByte = ((*pszStart) & 0x80); if (nDoubleByte) { int nOdd=FALSE; for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && (nOdd || ((*psz)&0x80) == nDoubleByte); psz++, nSubStrIndex++) { nOdd = !nOdd; } } else { for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && ((*psz)&0x80) == 0; psz++, nSubStrIndex++) { } } pStr = NewStr(); saved_ch = (*psz); *psz = '\0'; DynStrSet(&pStr->dyn_str, pszStart); *psz = saved_ch; pStr->prev = pLastStr; pStr->next = NULL; if (pFirstStr == NULL) { pFirstStr = pStr; } else { pLastStr->next = pStr; } pLastStr = pStr; nIndex += nSubStrIndex; } return pFirstStr; } static char *gpszTmpStr=NULL; static XChar2b *gpszTmpStr16=NULL; static int gnTmpStrLen=0; static void AllocTmp16Strings(pszStr, nLen) char *pszStr; int nLen; { if (nLen > gnTmpStrLen) { char *psz=(char*)malloc(nLen+3); XChar2b *psz16=(XChar2b*)malloc((nLen+3)*sizeof(XChar2b)); if (psz == NULL || psz16 == NULL) FailAllocMessage(); if (gpszTmpStr != NULL) free(gpszTmpStr); if (gpszTmpStr16 != NULL) free(gpszTmpStr16); gpszTmpStr = psz; gpszTmpStr16 = psz16; gnTmpStrLen = nLen; } if (gpszTmpStr != NULL) *gpszTmpStr = '\0'; if (gpszTmpStr16 != NULL) { gpszTmpStr16[0].byte1 = gpszTmpStr16[0].byte2 = (unsigned char)0; } } void MyTextExtents(xfs, pszStr, nLen, pxcs) XFontStruct *xfs; char *pszStr; int nLen; XCharStruct *pxcs; /* nLen does not include trailing '\0' */ { int dir=0, asc=0, des=0; memset(pxcs, 0, sizeof(XCharStruct)); if (canvasFontDoubleByte) { int nDoubleByte, nIndex=0; XCharStruct xcs; memset(&xcs, 0, sizeof(XCharStruct)); AllocTmp16Strings(pszStr, nLen); while (nIndex < nLen) { int nSubStrIndex=0; char *psz=NULL, *pszStart=NULL; pszStart = &pszStr[nIndex]; nDoubleByte = ((*pszStart) & 0x80); if (nDoubleByte) { int nDoubleByteIndex=0, nOdd=FALSE; for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && (nOdd || ((*psz)&0x80) == nDoubleByte); psz++, nSubStrIndex++) { if (nOdd) { gpszTmpStr16[nDoubleByteIndex].byte2 = (unsigned char)(*psz); nDoubleByteIndex++; } else { gpszTmpStr16[nDoubleByteIndex].byte1 = (unsigned char)(*psz); } nOdd = !nOdd; } if (canvasFontDoubleByteModBytes) { int i; for (i=0; i < nDoubleByteIndex; i++) { gpszTmpStr16[i].byte1 &= 0x7f; gpszTmpStr16[i].byte2 &= 0x7f; } } XTextExtents16(xfs, gpszTmpStr16, nDoubleByteIndex, &dir, &asc, &des, &xcs); } else { for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && ((*psz)&0x80) == 0; psz++, nSubStrIndex++) { } XTextExtents(xfs, pszStart, nSubStrIndex, &dir, &asc, &des, &xcs); } if (pszStart == pszStr) { pxcs->lbearing = xcs.lbearing; } pxcs->width += xcs.width; pxcs->rbearing = xcs.rbearing-xcs.width; nIndex += nSubStrIndex; } pxcs->rbearing += pxcs->width; } else { XTextExtents(xfs, pszStr, nLen, &dir, &asc, &des, pxcs); } } int MyTextWidth(xfs, pszStr, nLen) XFontStruct *xfs; char *pszStr; int nLen; /* nLen does not include trailing '\0' */ { if (canvasFontDoubleByte) { int nDoubleByte, nIndex=0, nTotal=0; AllocTmp16Strings(pszStr, nLen); while (nIndex < nLen) { int nSubStrIndex=0; char *psz=NULL, *pszStart=NULL; pszStart = &pszStr[nIndex]; nDoubleByte = ((*pszStart) & 0x80); if (nDoubleByte) { int nDoubleByteIndex=0, nOdd=FALSE; for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && (nOdd || ((*psz)&0x80) == nDoubleByte); psz++, nSubStrIndex++) { if (nOdd) { gpszTmpStr16[nDoubleByteIndex].byte2 = (unsigned char)(*psz); nDoubleByteIndex++; } else { gpszTmpStr16[nDoubleByteIndex].byte1 = (unsigned char)(*psz); } nOdd = !nOdd; } nTotal += XTextWidth16(xfs, gpszTmpStr16, nDoubleByteIndex); } else { for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && ((*psz)&0x80) == 0; psz++, nSubStrIndex++) { } nTotal += XTextWidth(xfs, pszStart, nSubStrIndex); } nIndex += nSubStrIndex; } return nTotal; } else { return XTextWidth(xfs, pszStr, nLen); } } void MyDrawString(dpy, d, gc, nDepth, x, y, pszStr, nLen) Display *dpy; Drawable d; GC gc; int nDepth, x, y, nLen; char *pszStr; /* nLen does not include trailing '\0' */ { if (canvasFontDoubleByte) { int nDoubleByte, nIndex=0, nTotal=0; AllocTmp16Strings(pszStr, nLen); while (nIndex < nLen) { int nSubStrIndex=0; char *psz=NULL, *pszStart=NULL; pszStart = &pszStr[nIndex]; nDoubleByte = ((*pszStart) & 0x80); if (nDoubleByte) { int nDoubleByteIndex=0, nOdd=FALSE, w=0, i=0; for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && (nOdd || ((*psz)&0x80) == nDoubleByte); psz++, nSubStrIndex++) { if (nOdd) { gpszTmpStr16[nDoubleByteIndex].byte2 = (unsigned char)(*psz); nDoubleByteIndex++; } else { gpszTmpStr16[nDoubleByteIndex].byte1 = (unsigned char)(*psz); } nOdd = !nOdd; } if (canvasFontDoubleByteModBytes) { for (i=0; i < nDoubleByteIndex; i++) { gpszTmpStr16[i].byte1 &= 0x7f; gpszTmpStr16[i].byte2 &= 0x7f; } } if (canvasFontDoubleByteVertical) { for (i=0; i < nDoubleByteIndex; i++) { char buf[3]; Pixmap bitmap=None; TextExtentsInfo stTextExtents; w = XTextWidth16(canvasFontPtr, &gpszTmpStr16[i], 1); buf[0] = pszStart[i<<1]; buf[1] = pszStart[(i<<1)+1]; buf[2] = '\0'; memset(&stTextExtents, 0, sizeof(TextExtentsInfo)); stTextExtents.buf = buf; stTextExtents.len = 2; bitmap = PaintVertChar(&stTextExtents, ROTATE270); if (bitmap != None) { XGCValues values; values.clip_mask = bitmap; values.clip_x_origin = x+nTotal; values.clip_y_origin = y-canvasFontAsc; XChangeGC(dpy, gc, GCClipMask | GCClipXOrigin | GCClipYOrigin, &values); XFillRectangle(dpy, d, gc, x+nTotal, y-canvasFontAsc, stTextExtents.bbox_h, stTextExtents.bbox_w); values.clip_mask = None; values.clip_x_origin = 0; values.clip_y_origin = 0; XChangeGC(dpy, gc, GCClipMask | GCClipXOrigin | GCClipYOrigin, &values); } nTotal += w; } } else { XDrawString16(dpy, d, gc, x+nTotal, y, gpszTmpStr16, nDoubleByteIndex); w = XTextWidth16(canvasFontPtr, gpszTmpStr16, nDoubleByteIndex); nTotal += w; } } else { for (psz=pszStart, nSubStrIndex=0; nIndex+nSubStrIndex < nLen && ((*psz)&0x80) == 0; psz++, nSubStrIndex++) { } XDrawString(dpy, d, gc, x+nTotal, y, pszStart, nSubStrIndex); nTotal += XTextWidth(canvasFontPtr, pszStart, nSubStrIndex); } nIndex += nSubStrIndex; } } else { XDrawString(dpy, d, gc, x, y, pszStr, nLen); } } static Pixmap vertFontBitmap=None, rotatedVertFontBitmap=None; static XImage *rotatedVertFontImage=NULL; static int vertFontBitmapW=0, vertFontBitmapH=0; Pixmap PaintVertChar(pTextExtents, nRotate) TextExtentsInfo *pTextExtents; int nRotate; /* Caller must not delete the returned pixmap! */ { int w=0, lbearing=0, rextra=0, image_w=0, image_h=0; int r=0, dest_cols=0, dest_rows=0; int saved_db_vert=canvasFontDoubleByteVertical; XImage *src_image=NULL; XGCValues values; SetTextExtentsInfo(pTextExtents); w = pTextExtents->w; lbearing = pTextExtents->lbearing; rextra = pTextExtents->rextra; image_w = pTextExtents->bbox_w; image_h = pTextExtents->bbox_h; if (image_w > vertFontBitmapW || image_h > vertFontBitmapH) { int tmp_w, tmp_h; if (vertFontBitmap != None) XFreePixmap(mainDisplay, vertFontBitmap); if (rotatedVertFontBitmap != None) { XFreePixmap(mainDisplay, rotatedVertFontBitmap); } tmp_w = max(image_w, vertFontBitmapW); tmp_h = max(image_h, vertFontBitmapH); vertFontBitmap = XCreatePixmap(mainDisplay, mainWindow, tmp_w, tmp_h, 1); rotatedVertFontBitmap = XCreatePixmap(mainDisplay, mainWindow, tmp_h, tmp_w, 1); if (vertFontBitmap == None) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), tmp_w, tmp_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else if (rotatedVertFontBitmap == None) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), tmp_h, tmp_w); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } vertFontBitmapW = tmp_w; vertFontBitmapH = tmp_h; } dest_cols = image_h; dest_rows = image_w; XSetForeground(mainDisplay, rotateGC, 0); XFillRectangle(mainDisplay, vertFontBitmap, rotateGC, 0, 0, vertFontBitmapW, vertFontBitmapH); XFillRectangle(mainDisplay, rotatedVertFontBitmap, rotateGC, 0, 0, image_h, image_w); values.foreground = 1; values.font = canvasFontPtr->fid; XChangeGC(mainDisplay, rotateGC, GCForeground | GCFont, &values); canvasFontDoubleByteVertical = FALSE; MyDrawString(mainDisplay, vertFontBitmap, rotateGC, 1, -lbearing, canvasFontAsc, pTextExtents->buf, pTextExtents->len); canvasFontDoubleByteVertical = saved_db_vert; src_image = XGetImage(mainDisplay, vertFontBitmap, 0, 0, image_w, image_h, 1, ZPixmap); if (src_image == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (rotatedVertFontImage != NULL) XDestroyImage(rotatedVertFontImage); rotatedVertFontImage = XGetImage(mainDisplay, rotatedVertFontBitmap, 0, 0, dest_cols, dest_rows, 1, ZPixmap); if (rotatedVertFontImage == NULL) { XDestroyImage(src_image); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), dest_cols, dest_rows); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } switch (nRotate) { case ROTATE90: for (r=0; r < dest_rows; r++) { int c=0; for (c=0; c < dest_cols; c++) { int x=r; int y=image_h-c-1; if (XGetPixel(src_image, x, y)==1) { XPutPixel(rotatedVertFontImage, c, r, 1); } } } break; case ROTATE270: for (r=0; r < dest_rows; r++) { int c=0; for (c=0; c < dest_cols; c++) { int x=image_w-r-1; int y=c; if (XGetPixel(src_image, x, y)==1) { XPutPixel(rotatedVertFontImage, c, r, 1); } } } break; } XPutImage(mainDisplay, rotatedVertFontBitmap, rotateGC, rotatedVertFontImage, 0, 0, 0, 0, dest_cols, dest_rows); XDestroyImage(src_image); return rotatedVertFontBitmap; } static void CleanUpTmpStrings() { if (gpszTmpStr != NULL) free(gpszTmpStr); if (gpszTmpStr16 != NULL) free(gpszTmpStr16); gpszTmpStr = NULL; gpszTmpStr16 = NULL; gnTmpStrLen = 0; } int ValidCharCode(c_ptr) char *c_ptr; { int index=(int)(*c_ptr - '\200'); if (*charCodeToName[index] == '\0' || *charCodeToName[index] == '8' || *charCodeToName[index] == '\\') { return TRUE; } sprintf(gszMsgBox, TgLoadString(STID_UNRECOG_CHARCODE_DISCARD), (*c_ptr)&0xff); Msg(gszMsgBox); return FALSE; } char *CharCodeTranslate(c_ptr) char *c_ptr; { int index=(int)(*c_ptr - '\200'); if (*charCodeToName[index] == '\\' || *charCodeToName[index] == '8') { return charCodeToName[index]; } return NULL; } static int *encodeFont=NULL; static short **encodeCharFlags=NULL; static int encodeCharFlagsAllocated=FALSE; static int numEncodeCharFonts=0; static int gnDontReencodeInitialized=FALSE; static char *gpszDontReencode=NULL; static void CleanUpEncodeCharFonts() { int i; if (encodeCharFlagsAllocated) { for (i = 0; i < numEncodeCharFonts*MAXFONTSTYLES; i++) { free(encodeCharFlags[i]); } free(encodeFont); free(encodeCharFlags); encodeCharFlagsAllocated = FALSE; numEncodeCharFonts = 0; encodeFont = NULL; encodeCharFlags = NULL; } *cmdLineDontReencode = '\0'; } static void RemovePSFontNameVariations(ps_font_name_str) char *ps_font_name_str; /* * Get rid of the '-' as in 'ZapfChancery-MediumItalic'. * Also get rid of the '--' as in 'Helvetica-Narrow--Bold' and * 'Helvetica-Narrow--'. */ { char *psz=NULL; if ((psz=strstr(ps_font_name_str, "--")) != NULL) { *psz = '\0'; } else if ((psz=strchr(ps_font_name_str, '-')) != NULL) { *psz = '\0'; } } void SaveDontReencode(FP) FILE *FP; { char *c_ptr=NULL; if (gpszDontReencode == NULL) return; if (fprintf(FP, "dont_reencode(\"") == EOF) { writeFileFailed = TRUE; } for (c_ptr=gpszDontReencode; *c_ptr != '\0'; c_ptr++) { if (fprintf(FP, "%s", c_ptr) == EOF) writeFileFailed = TRUE; c_ptr += strlen(c_ptr); if (c_ptr[1] != '\0') { if (fprintf(FP, ":") == EOF) writeFileFailed = TRUE; } } if (fprintf(FP, "\").\n") == EOF) writeFileFailed = TRUE; } int ReadDontReencode(buf) char *buf; { char *s=NULL, *c_ptr=NULL; if (!PRTGIF || cmdLineOpenDisplay) return TRUE; #ifndef _PRTGIF_USE_ISO_LATIN_1_ALWAYS s = FindChar((int)'(', buf); c_ptr = FindChar((int)'"', s); s = ReadString(c_ptr); *(--s) = '\0'; InitDontReencode(c_ptr); #endif /* ~_PRTGIF_USE_ISO_LATIN_1_ALWAYS */ return TRUE; } void SavePSFontAliases(FP) FILE *FP; { int i=0, count=0, total=0; if (gnNumPSFontAliases == 0 || gaPSFontAliases == NULL) return; for (i=0; i < gnNumPSFontAliases; i++) { KeyValInfo *pKeyValue=(&gaPSFontAliases[i]); if (pKeyValue == NULL || pKeyValue->key == NULL || pKeyValue->value == NULL) { continue; } count++; } if (count == 0) return; if (fprintf(FP, "ps_font_aliases([\n") == EOF) { writeFileFailed = TRUE; } for (i=0; i < gnNumPSFontAliases; i++) { KeyValInfo *pKeyValue=(&gaPSFontAliases[i]); if (pKeyValue == NULL || pKeyValue->key == NULL || pKeyValue->value == NULL) { continue; } total++; if (fprintf(FP, "\t\"%s=%s\"", pKeyValue->key, pKeyValue->value) == EOF) { writeFileFailed = TRUE; } if (total != count) { if (fprintf(FP, ",\n") == EOF) writeFileFailed = TRUE; } } /* * For the next file version, the '\t' below should be removed. */ if (fprintf(FP, "\n\t]).\n") == EOF) writeFileFailed = TRUE; } void SaveDoubleByteModBytes(FP) FILE *FP; /* This function doesn't do anything. May be there is no need for this. */ { int i=0; for (i=0; i < numFonts; i++) { if (IsFontDoubleByte(i)) { } } } void SavePSFontNeedCharSubs(FP) FILE *FP; { int i=0, count=0, total=0; if (gnNumPSFontNeedCharSubs == 0 || gaPSFontNeedCharSubs == NULL) return; for (i=0; i < gnNumPSFontNeedCharSubs; i++) { KeyValInfo *pKeyValue=(&gaPSFontNeedCharSubs[i]); if (pKeyValue == NULL || pKeyValue->key == NULL || pKeyValue->value == NULL) { continue; } count++; } if (count == 0) return; if (fprintf(FP, "ps_font_need_char_subs([\n") == EOF) { writeFileFailed = TRUE; } for (i=0; i < gnNumPSFontNeedCharSubs; i++) { KeyValInfo *pKeyValue=(&gaPSFontNeedCharSubs[i]); if (pKeyValue == NULL || pKeyValue->key == NULL || pKeyValue->value == NULL) { continue; } total++; if (fprintf(FP, "\t\"%s=%s\"", pKeyValue->key, pKeyValue->value) == EOF) { writeFileFailed = TRUE; } if (total != count) { if (fprintf(FP, ",\n") == EOF) writeFileFailed = TRUE; } } /* * For the next file version, the '\t' below should be removed. */ if (fprintf(FP, "\n\t]).\n") == EOF) writeFileFailed = TRUE; } void SavePSCharSubs(FP) FILE *FP; { CVListElem *elem=NULL; for (elem=ListFirst(&psCharSubsList); elem != NULL; elem=ListNext(&psCharSubsList, elem)) { PSCharSubs *ppscs=(PSCharSubs*)elem->obj; if (ppscs != NULL && ppscs->token_name != NULL) { int i=0, first_one=TRUE; if (fprintf(FP, "ps_char_subs(\"%s\",[\n", ppscs->token_name) == EOF) { writeFileFailed = TRUE; } for (i=0; i < 128; i++) { char *ps_char_name=ppscs->ps_char_name[i]; if (ps_char_name != NULL) { if (first_one) { if (fprintf(FP, "\t\"8#%03o%s\"", (i|0x080), ps_char_name) == EOF) { writeFileFailed = TRUE; } first_one = FALSE; } else { if (fprintf(FP, ",\n\t\"8#%03o%s\"", (i|0x080), ps_char_name) == EOF) { writeFileFailed = TRUE; } } } } if (fprintf(FP, "\n\t]).\n") == EOF) writeFileFailed = TRUE; } } } static void ProcessAPSFontAlias(fake_font_name, real_font_name) char *fake_font_name, *real_font_name; { if (gaPSFontAliases == NULL) { gaPSFontAliases = (KeyValInfo*)malloc(sizeof(KeyValInfo)); } else { gaPSFontAliases = (KeyValInfo*)realloc(gaPSFontAliases, (gnNumPSFontAliases+1)*sizeof(KeyValInfo)); } if (gaPSFontAliases == NULL) FailAllocMessage(); memset(&gaPSFontAliases[gnNumPSFontAliases], 0, sizeof(KeyValInfo)); gaPSFontAliases[gnNumPSFontAliases].key = UtilStrDup(fake_font_name); gaPSFontAliases[gnNumPSFontAliases].value = UtilStrDup(&real_font_name[1]); if (gaPSFontAliases[gnNumPSFontAliases].key == NULL || gaPSFontAliases[gnNumPSFontAliases].value == NULL) { FailAllocMessage(); } *real_font_name = '='; UtilTrimBlanks(gaPSFontAliases[gnNumPSFontAliases].key); UtilTrimBlanks(gaPSFontAliases[gnNumPSFontAliases].value); gnNumPSFontAliases++; } int ReadPSFontAliases(FP, buf) FILE *FP; char *buf; { char *line=NULL; int skip_processing=FALSE; if (!PRTGIF || cmdLineOpenDisplay) skip_processing = TRUE; if (gaPSFontAliases != NULL || gnNumPSFontAliases > 0) { skip_processing = TRUE; } while ((line=UtilGetALine(FP)) != NULL) { char *c_ptr=NULL, *fake_font_name=NULL, *real_font_name=NULL; char info[MAXSTRING]; scanLineNum++; if (*line == ']' || (line[0] == '\t' && line[1] == ']')) { free(line); break; } if (!skip_processing) { #ifndef _PRTGIF_USE_ISO_LATIN_1_ALWAYS c_ptr = FindChar((int)'"', line); c_ptr = ParseStr(c_ptr, (int)'"', info, sizeof(info)); fake_font_name = info; real_font_name = strchr(fake_font_name, '='); if (real_font_name == NULL || real_font_name[1] == '\0') { free(line); continue; } *real_font_name = '\0'; ProcessAPSFontAlias(fake_font_name, real_font_name); *real_font_name = '='; #endif /* ~_PRTGIF_USE_ISO_LATIN_1_ALWAYS */ } free(line); } return TRUE; } static void FreePSCharSubs(pppscs) PSCharSubs **pppscs; { PSCharSubs *ppscs=(*pppscs); if (ppscs != NULL) { int i=0; UtilFree(ppscs->token_name); for (i=0; i < 128; i++) { if (ppscs->ps_char_name[i] != NULL) { free(ppscs->ps_char_name[i]); } } free(ppscs); } *pppscs = NULL; } static int ValidCharCodeSpec(psz_char_code, token_name, pn_char_code, resource_name) char *psz_char_code, *token_name, *resource_name; int *pn_char_code; { int char_code=0; if (strncmp(psz_char_code, "8#", 2) == 0) { if (sscanf(&psz_char_code[2], "%o", &char_code) != 1) { if (resource_name == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_CHAR_CODE_FILE), psz_char_code, token_name); } else { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_CHAR_CODE_XDEF), psz_char_code, token_name, TOOL_NAME, resource_name); } fprintf(stderr, "%s\n", gszMsgBox); return FALSE; } } else if (strncmp(psz_char_code, "0x", 2) == 0) { if (sscanf(&psz_char_code[2], "%x", &char_code) != 1) { if (resource_name == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_CHAR_CODE_FILE), psz_char_code, token_name); } else { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_CHAR_CODE_XDEF), psz_char_code, token_name, TOOL_NAME, resource_name); } fprintf(stderr, "%s\n", gszMsgBox); return FALSE; } } else { if (sscanf(psz_char_code, "%d", &char_code) != 1) { if (resource_name == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_CHAR_CODE_FILE), psz_char_code, token_name); } else { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_CHAR_CODE_XDEF), psz_char_code, token_name, TOOL_NAME, resource_name); } fprintf(stderr, "%s\n", gszMsgBox); return FALSE; } } if (char_code < 161 || char_code > 255) { if (resource_name == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CHAR_CODE_OUT_OF_RANGE_FILE), psz_char_code, token_name); } else { sprintf(gszMsgBox, TgLoadString(STID_CHAR_CODE_OUT_OF_RANGE_XDEF), psz_char_code, token_name, TOOL_NAME, resource_name); } fprintf(stderr, "%s\n", gszMsgBox); return FALSE; } *pn_char_code = char_code; return TRUE; } static void ProcessCharSubs(ppscs, psz_char_code, ps_char_name, resource_name) PSCharSubs *ppscs; char *psz_char_code, *ps_char_name, *resource_name; { int char_code=0, len=strlen(ps_char_name)+1; if (!ValidCharCodeSpec(psz_char_code, ppscs->token_name, &char_code, resource_name)) { return; } if (ppscs->ps_char_name[char_code-128] != NULL) { if (resource_name == NULL) { sprintf(gszMsgBox, TgLoadString(STID_DUP_CHAR_CODE_FILE_IGNORED), char_code, char_code, TOOL_NAME, resource_name); } else { sprintf(gszMsgBox, TgLoadString(STID_DUP_CHAR_CODE_XDEF_IGNORED), char_code, char_code, TOOL_NAME, resource_name); } fprintf(stderr, "%s\n", gszMsgBox); return; } ppscs->ps_char_name[char_code-128] = (char*)malloc(len+1); if (ppscs->ps_char_name[char_code-128] == NULL) FailAllocMessage(); sprintf(ppscs->ps_char_name[char_code-128], "/%s", ps_char_name); } static int ParsePSCharSubs(ppscs, c_ptr, resource_name) PSCharSubs *ppscs; char *c_ptr, *resource_name; { char *buf=UtilStrDup(c_ptr), *buf1=NULL, *psz_state=NULL; if (buf == NULL) FailAllocMessage(); for (buf1=UtilStrTok(buf, " ,\t\n\r", &psz_state); buf1 != NULL; buf1=UtilStrTok(NULL, " ,\t\n\r", &psz_state)) { char *ps_char_name=strchr(buf1, '/'); if (ps_char_name == NULL) { fprintf(stderr, TgLoadString(STID_BAD_XDEF_CANT_FIND_TOKEN_SKIP), buf1, "'='", TOOL_NAME, resource_name); fprintf(stderr, "\n"); continue; } if (ps_char_name[1] == '\0') { fprintf(stderr, TgLoadString(STID_BAD_XDEF_MISS_CHAR_NAME_SKIP), buf1, TOOL_NAME, resource_name); fprintf(stderr, "\n"); continue; } *ps_char_name = '\0'; ProcessCharSubs(ppscs, buf1, &ps_char_name[1], resource_name); *ps_char_name = '/'; } UtilFree(buf); return TRUE; } static char *FindPSFontNeedCharSubs(ps_font_name) char *ps_font_name; { int i=0; for (i=0; i < gnNumPSFontNeedCharSubs; i++) { if (strcmp(ps_font_name, gaPSFontNeedCharSubs[i].key) == 0) { return gaPSFontNeedCharSubs[i].value; } } return NULL; } static PSCharSubs *FindTokenInPSCharSubs(token_name) char *token_name; { CVListElem *elem=NULL; for (elem=ListFirst(&psCharSubsList); elem != NULL; elem=ListNext(&psCharSubsList, elem)) { PSCharSubs *ppscs=(PSCharSubs*)elem->obj; if (ppscs != NULL && ppscs->token_name != NULL && strcmp(ppscs->token_name, token_name) == 0) { return ppscs; } } return NULL; } static PSCharSubs *FindPSCharSubs(ps_font_name) char *ps_font_name; { char *token_name=FindPSFontNeedCharSubs(ps_font_name); if (token_name == NULL) return NULL; return FindTokenInPSCharSubs(token_name); } static void ProcessPSCharSubs(font_name, token_name) char *font_name, *token_name; { if (gaPSFontNeedCharSubs == NULL) { gaPSFontNeedCharSubs = (KeyValInfo*)malloc(sizeof(KeyValInfo)); } else { gaPSFontNeedCharSubs = (KeyValInfo*)realloc(gaPSFontNeedCharSubs, (gnNumPSFontNeedCharSubs+1)*sizeof(KeyValInfo)); } if (gaPSFontNeedCharSubs == NULL) FailAllocMessage(); memset(&gaPSFontNeedCharSubs[gnNumPSFontNeedCharSubs], 0, sizeof(KeyValInfo)); gaPSFontNeedCharSubs[gnNumPSFontNeedCharSubs].key = UtilStrDup(font_name); gaPSFontNeedCharSubs[gnNumPSFontNeedCharSubs].value = UtilStrDup(token_name); if (gaPSFontNeedCharSubs[gnNumPSFontNeedCharSubs].key == NULL || gaPSFontNeedCharSubs[gnNumPSFontNeedCharSubs].value == NULL) { FailAllocMessage(); } UtilTrimBlanks(gaPSFontNeedCharSubs[gnNumPSFontNeedCharSubs].key); UtilTrimBlanks(gaPSFontNeedCharSubs[gnNumPSFontNeedCharSubs].value); gnNumPSFontNeedCharSubs++; if (FindTokenInPSCharSubs(token_name) == NULL) { if (mainDisplay != NULL) { char *c_ptr=NULL, buf[MAXSTRING]; sprintf(buf, "PSCharSubs_%s", token_name); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,buf)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_X_DEFAULT), TOOL_NAME, buf); fprintf(stderr, "%s\n", gszMsgBox); } else { PSCharSubs *ppscs=NULL; ppscs = (PSCharSubs*)malloc(sizeof(PSCharSubs)); if (ppscs == NULL) FailAllocMessage(); memset(ppscs, 0, sizeof(PSCharSubs)); ppscs->token_name = UtilStrDup(token_name); if (ppscs->token_name == NULL) FailAllocMessage(); if (ParsePSCharSubs(ppscs, c_ptr, buf)) { ListAppend(&psCharSubsList, ppscs); } else { FreePSCharSubs(&ppscs); } } } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_PS_CHAR_SUBS_READ), token_name); fprintf(stderr, "%s\n", gszMsgBox); } } } static void CleanUpPSFontCharSubs() { if (gnNumPSFontNeedCharSubs > 0) { CVListElem *elem=NULL; for (elem=ListFirst(&psCharSubsList); elem != NULL; elem=ListNext(&psCharSubsList, elem)) { PSCharSubs *ppscs=(PSCharSubs*)elem->obj; if (ppscs != NULL) { FreePSCharSubs(&ppscs); } } ListUnlinkAll(&psCharSubsList); while (gnNumPSFontNeedCharSubs-- > 0) { UtilFree(gaPSFontNeedCharSubs[gnNumPSFontNeedCharSubs].key); UtilFree(gaPSFontNeedCharSubs[gnNumPSFontNeedCharSubs].value); } free(gaPSFontNeedCharSubs); } gaPSFontNeedCharSubs = NULL; gnNumPSFontNeedCharSubs = 0; } int ReadPSFontNeedCharSubs(FP, buf) FILE *FP; char *buf; { char *line=NULL; int skip_processing=FALSE; if (!PRTGIF || cmdLineOpenDisplay) skip_processing = TRUE; if (gaPSFontNeedCharSubs != NULL || gnNumPSFontNeedCharSubs > 0) { skip_processing = TRUE; } while ((line=UtilGetALine(FP)) != NULL) { char *c_ptr=NULL, *font_name=NULL, *token_name=NULL; char info[MAXSTRING]; scanLineNum++; if (*line == ']' || (line[0] == '\t' && line[1] == ']')) { free(line); break; } if (!skip_processing) { #ifndef _PRTGIF_USE_ISO_LATIN_1_ALWAYS c_ptr = FindChar((int)'"', line); c_ptr = ParseStr(c_ptr, (int)'"', info, sizeof(info)); font_name = info; token_name = strchr(font_name, '='); if (token_name == NULL || token_name[1] == '\0') { free(line); continue; } *token_name = '\0'; ProcessPSCharSubs(font_name, &token_name[1]); *token_name = '='; #endif /* ~_PRTGIF_USE_ISO_LATIN_1_ALWAYS */ } free(line); } return TRUE; } int ReadPSCharSubs(FP, buf) FILE *FP; char *buf; { char *line=NULL; int skip_processing=FALSE, ok=FALSE; PSCharSubs *ppscs=NULL; if (!PRTGIF || cmdLineOpenDisplay) skip_processing = TRUE; if (!skip_processing) { char *s=FindChar((int)'(', buf), *c_ptr=NULL; c_ptr = FindChar((int)'"', s); s = ReadString(c_ptr); *(--s) = '\0'; if (FindTokenInPSCharSubs(c_ptr) != NULL) { sprintf(gszMsgBox, TgLoadString(STID_DUP_TOKEN_PS_CHAR_SUBS_READ), c_ptr); fprintf(stderr, "%s\n", gszMsgBox); skip_processing = TRUE; } else { ppscs = (PSCharSubs*)malloc(sizeof(PSCharSubs)); if (ppscs == NULL) FailAllocMessage(); memset(ppscs, 0, sizeof(PSCharSubs)); ppscs->token_name = UtilStrDup(c_ptr); if (ppscs->token_name == NULL) FailAllocMessage(); ok = TRUE; } } while ((line=UtilGetALine(FP)) != NULL) { char *c_ptr=NULL, *buf1=NULL, *ps_char_name=NULL; char info[MAXSTRING]; scanLineNum++; if (*line == ']' || (line[0] == '\t' && line[1] == ']')) { free(line); break; } if (!skip_processing) { #ifndef _PRTGIF_USE_ISO_LATIN_1_ALWAYS c_ptr = FindChar((int)'"', line); c_ptr = ParseStr(c_ptr, (int)'"', info, sizeof(info)); buf1 = info; ps_char_name = strchr(buf1, '/'); if (ps_char_name == NULL || ps_char_name[1] == '\0') { free(line); continue; } *ps_char_name = '\0'; ProcessCharSubs(ppscs, buf1, &ps_char_name[1], NULL); *ps_char_name = '/'; #endif /* ~_PRTGIF_USE_ISO_LATIN_1_ALWAYS */ } free(line); } if (ppscs != NULL) { if (ok) { ListAppend(&psCharSubsList, ppscs); } else { FreePSCharSubs(&ppscs); } } return TRUE; } static int DontReencodeInXDefOrCmdLine(pszFontName, nFontIndex, nFontStyle) char *pszFontName; int nFontIndex, nFontStyle; { char *c_ptr=NULL; if (gpszDontReencode != NULL) { char szFontStr[MAXSTRING]; *szFontStr = '\0'; if (pszFontName == NULL) { GetPSFontStr(nFontIndex, nFontStyle, szFontStr); if (strncmp(szFontStr, "/(", 2) == 0) { /* bitmapped PS font! */ return FALSE; } else if (*szFontStr == '/') { *szFontStr = ' '; } } else { UtilStrCpyN(szFontStr, sizeof(szFontStr), pszFontName); } RemovePSFontNameVariations(szFontStr); UtilTrimBlanks(szFontStr); pszFontName = szFontStr; for (c_ptr=gpszDontReencode; *c_ptr != '\0'; c_ptr++) { if (UtilStrICmp(c_ptr, pszFontName) == 0) { return TRUE; } c_ptr += strlen(c_ptr); } } return FALSE; } static void UpdateEncodeCharInfo(nIndex, psz) int nIndex; char *psz; { int byte_index=(int)(((*psz) & 0x7f)>>3); short *flag_ptr=encodeCharFlags[nIndex]; encodeFont[nIndex] = TRUE; flag_ptr[byte_index] |= (1<<((*psz) & 0x07)); } static void PrepareStrSeg(pStrSeg) StrSegInfo *pStrSeg; { char *c_ptr=NULL; int font_and_style_index=0; if (pStrSeg->double_byte) return; if (pStrSeg->font_name == NULL) { if (pStrSeg->font == FONT_SYM) { return; } } else if (strcmp(pStrSeg->font_name, "Symbol") == 0) { return; } if (DontReencodeInXDefOrCmdLine(pStrSeg->font_name, pStrSeg->font, pStrSeg->style)) { return; } else if (PRTGIF && !cmdLineOpenDisplay && pStrSeg->font < 0) { /* * Since pStrSeg->font is < 0, there's no way to call * UpdateEncodeCharInfo()! Therefore, font encoding is forced! */ return; } font_and_style_index = pStrSeg->font*MAXFONTSTYLES + pStrSeg->style; for (c_ptr=pStrSeg->dyn_str.s; *c_ptr != '\0'; c_ptr++) { if (((*c_ptr)&0x80) && *charCodeToName[(int)(*c_ptr-'\200')]=='8') { UpdateEncodeCharInfo(font_and_style_index, c_ptr); } } } static void PrepareStrBlock(pStrBlock) StrBlockInfo *pStrBlock; { switch (pStrBlock->type) { case SB_SIMPLE: PrepareStrSeg(pStrBlock->seg); break; case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) PrepareMiniLines(pStrBlock->sup); if (pStrBlock->sub != NULL) PrepareMiniLines(pStrBlock->sub); if (pStrBlock->type == SB_SUPSUB_CENTER) { PrepareStrSeg(pStrBlock->seg); } break; } } static void PrepareMiniLine(pMiniLine) MiniLineInfo *pMiniLine; { StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { PrepareStrBlock(pStrBlock); } } void PrepareMiniLines(minilines) MiniLinesInfo *minilines; { MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { PrepareMiniLine(pMiniLine); } } static void PrepareText(ObjPtr) struct ObjRec *ObjPtr; { MiniLinesInfo *minilines=(&ObjPtr->detail.t->minilines); PrepareMiniLines(minilines); } static void PrepareObjFontInfo(ObjPtr) struct ObjRec *ObjPtr; { struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; for (obj_ptr=ObjPtr; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { switch (obj_ptr->type) { case OBJ_TEXT: PrepareText(obj_ptr); break; case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: PrepareObjFontInfo(obj_ptr->detail.r->last); break; case OBJ_PIN: PrepareObjFontInfo(GetPinObj(obj_ptr)->detail.r->last); break; } for (attr_ptr=obj_ptr->lattr; attr_ptr!=NULL; attr_ptr=attr_ptr->prev) { PrepareText(attr_ptr->obj); } } } void PrepareEightBitFontInfo() { struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; int j, i; short *flag_ptr; struct PageRec *page_ptr; if (encodeCharFlagsAllocated && numEncodeCharFonts < numFonts) { CleanUpEncodeCharFonts(); } if (!encodeCharFlagsAllocated) { int font_count=0; font_count = ((PRTGIF && !cmdLineOpenDisplay) ? MAXFONTS+numFakedFonts : numFonts+numFakedFonts); encodeCharFlags = (short**)malloc(font_count*MAXFONTSTYLES*sizeof(short*)); if (encodeCharFlags == NULL) FailAllocMessage(); encodeFont = (int*)malloc(font_count*MAXFONTSTYLES*sizeof(int)); if (encodeFont == NULL) FailAllocMessage(); memset(encodeFont, 0, font_count*MAXFONTSTYLES*sizeof(int)); for (i = 0; i < font_count*MAXFONTSTYLES; i++) { encodeCharFlags[i] = (short*)malloc(16*sizeof(short)); if (encodeCharFlags[i] == NULL) FailAllocMessage(); memset(encodeCharFlags[i], 0, 16*sizeof(short)); } encodeCharFlagsAllocated = TRUE; numEncodeCharFonts = font_count; } for (i=0; i < numEncodeCharFonts*MAXFONTSTYLES; i++) { encodeFont[i] = FALSE; flag_ptr = encodeCharFlags[i]; for (j=0; j < 16; j++) flag_ptr[j] = 0; } for (page_ptr=firstPage; page_ptr != NULL; page_ptr=page_ptr->next) { for (obj_ptr=page_ptr->bot; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { switch (obj_ptr->type) { case OBJ_TEXT: PrepareText(obj_ptr); break; case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: PrepareObjFontInfo(obj_ptr->detail.r->last); break; case OBJ_PIN: PrepareObjFontInfo(GetPinObj(obj_ptr)->detail.r->last); break; } for (attr_ptr=obj_ptr->lattr; attr_ptr!=NULL; attr_ptr=attr_ptr->prev) { PrepareText(attr_ptr->obj); } } } } int NeedEncode(FontName, FontIndex, StyleIndex) char *FontName; int FontIndex, StyleIndex; { if (PRTGIF && !cmdLineOpenDisplay) { /* No need to do anything here because encodeFont[] takes care of it */ if (FontIndex < 0) { /* * Since FontIndex is < 0, there's no way to compute an index into * encodeFont[]! Therefore, the decision to encode a font * or not must be made here! (By default, a font is encoded!) */ return (FontName==NULL ? FALSE : !DontReencodeInXDefOrCmdLine(FontName, FontIndex, StyleIndex)); } } if (FontIndex == FONT_SYM) { return FALSE; } return encodeFont[FontIndex*MAXFONTSTYLES+StyleIndex]; } int GetFontIndex(FontStr, StyleIndex, MustFind) char *FontStr; int StyleIndex, MustFind; { int i; int num_base_fonts=((PRTGIF && !cmdLineOpenDisplay) ? MAXFONTS : numFonts); char **base_font_info_str=((PRTGIF && !cmdLineOpenDisplay) ? initFontInfoStr : fontInfoStr); for (i=0; i < num_base_fonts; i++) { if (strcmp( base_font_info_str[(i*MAXFONTSTYLES+StyleIndex)*3+PS_FONT_NAME], FontStr) == 0) { return i; } } for ( ; i < num_base_fonts+numFakedFonts; i++) { if (strcmp(fontFamilies[i].name_faked, FontStr) == 0) { return i; } } if (MustFind) return INVALID; numFakedFonts++; if (fontFamilies == NULL) { fontFamilies = (struct FontFmlyRec *)malloc( (num_base_fonts+numFakedFonts)*sizeof(struct FontFmlyRec)); if (fontFamilies == NULL) FailAllocMessage(); memset(fontFamilies, 0, (num_base_fonts+numFakedFonts)*sizeof(struct FontFmlyRec)); } else { fontFamilies = (struct FontFmlyRec *)realloc(fontFamilies, (num_base_fonts+numFakedFonts)*sizeof(struct FontFmlyRec)); if (fontFamilies == NULL) FailAllocMessage(); memset(&fontFamilies[num_base_fonts+numFakedFonts-1], 0, sizeof(struct FontFmlyRec)); } fontFamilies[num_base_fonts+numFakedFonts-1].name_faked = (char*)malloc((strlen(FontStr)+1)*sizeof(char)); if (fontFamilies[num_base_fonts+numFakedFonts-1].name_faked == NULL) { FailAllocMessage(); } strcpy(fontFamilies[num_base_fonts+numFakedFonts-1].name_faked, FontStr); for (i=0; i < MAXFONTSTYLES; i++) { fontFamilies[num_base_fonts+numFakedFonts-1].fr[i].next = NULL; fontFamilies[num_base_fonts+numFakedFonts-1].fr[i].xfs = NULL; } return (num_base_fonts+numFakedFonts-1); } int GetFontAndStyle(FontStr, pnFont, pnStyle, MustFind) char *FontStr; int *pnFont, *pnStyle, MustFind; { int font=0; int num_fonts=((PRTGIF && !cmdLineOpenDisplay) ? MAXFONTS : numFonts); for (font=0; font < num_fonts; font++) { int style=0; for (style=0; style < MAXFONTSTYLES; style++) { char font_str[MAXSTRING]; GetPSFontStr(font, style, font_str); /* font_str[0] is '/' */ if (UtilStrICmp(FontStr, &font_str[1]) == 0) { if (pnFont != NULL) *pnFont = font; if (pnStyle != NULL) *pnStyle = style; return TRUE; } } } if (MustFind) return FALSE; return TRUE; } int GetFontIndexFromPSFontAndStyle(font_str, style, pnDoubleByte, pnModified) char *font_str; int style, *pnDoubleByte, *pnModified; { int len=strlen(font_str), font=FONT_TIM; if (pnModified != NULL) *pnModified = FALSE; if (len > 1 && *font_str == '\'' && font_str[len-1] == '\'') { char *psz1=(&font_str[1]), *psz2=NULL; font_str[len-1] = '\0'; psz2 = font_str; while (*psz1 != '\0') *psz2++ = *psz1++; *psz2 = '\0'; } font = GetFontIndex(font_str, style, (!PRTGIF || cmdLineOpenDisplay)); if (font == INVALID && (!PRTGIF || cmdLineOpenDisplay)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_FIND_FONT_USE_ALT), font_str, "Times"); Msg(gszMsgBox); if (pnModified != NULL) *pnModified = TRUE; font = FONT_TIM; if (pnDoubleByte != NULL && *pnDoubleByte) { /* * font would have been the double-byte font. * But since it can't be found and Times is used, it should * not be double-byte any more. */ *pnDoubleByte = FALSE; } } return font; } void CleanUpDontReencode() { if (gpszDontReencode != NULL) { UtilFree(gpszDontReencode); gpszDontReencode = NULL; } gnDontReencodeInitialized = FALSE; } void InitDontReencode(buf) char *buf; { char *c_ptr=NULL, *pszDontReencode=NULL; if (buf == NULL && gnDontReencodeInitialized) return; if (buf == NULL) { gnDontReencodeInitialized = TRUE; } if (buf != NULL) { if (gpszDontReencode != NULL) { /* if it is already initialized, don't parse the content of buf */ return; } if ((pszDontReencode=UtilStrDup(buf)) == NULL) FailAllocMessage(); UtilTrimBlanks(pszDontReencode); } else if (PRTGIF && !cmdLineOpenDisplay) { if (*cmdLineDontReencode != '\0') { UtilTrimBlanks(cmdLineDontReencode); if ((pszDontReencode=UtilStrDup(cmdLineDontReencode)) == NULL) { FailAllocMessage(); } #ifdef _DONT_REENCODE } else { if ((pszDontReencode=UtilStrDup(_DONT_REENCODE)) == NULL) { FailAllocMessage(); } UtilTrimBlanks(pszDontReencode); #endif /* _DONT_REENCODE */ } } else { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DontReencode")) != NULL) { if ((pszDontReencode=UtilStrDup(c_ptr)) == NULL) FailAllocMessage(); UtilTrimBlanks(pszDontReencode); #ifdef _DONT_REENCODE } else { if ((pszDontReencode=UtilStrDup(_DONT_REENCODE)) == NULL) { FailAllocMessage(); } UtilTrimBlanks(pszDontReencode); #endif /* _DONT_REENCODE */ } if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "AdditionalDontReencode")) != NULL) { while (*c_ptr == ':') c_ptr++; if (pszDontReencode == NULL) { if ((pszDontReencode=UtilStrDup(c_ptr)) == NULL) FailAllocMessage(); } else { int len=strlen(pszDontReencode); char *psz=(char*)malloc(sizeof(char)*(len+2+strlen(c_ptr))); if (psz == NULL) FailAllocMessage(); sprintf(psz, "%s:%s", pszDontReencode, c_ptr); UtilFree(pszDontReencode); pszDontReencode = psz; } UtilTrimBlanks(pszDontReencode); } } if (pszDontReencode != NULL && *pszDontReencode != '\0') { char *c_ptr1=NULL; gpszDontReencode = (char*)malloc(strlen(pszDontReencode)+2); if (gpszDontReencode == NULL) FailAllocMessage(); for (c_ptr1=gpszDontReencode, c_ptr=strtok(pszDontReencode, " ,:;\t\n\r"); c_ptr != NULL; c_ptr=strtok(NULL, " ,:;\t\n\r")) { strcpy(c_ptr1, c_ptr); c_ptr1 += strlen(c_ptr)+1; } *c_ptr1 = '\0'; } UtilFree(pszDontReencode); } void InitPSFontCharSubs() { char *c_ptr=NULL; gaPSFontNeedCharSubs = NULL; gnNumPSFontNeedCharSubs = 0; CVListInit(&psCharSubsList); if (mainDisplay == NULL) return; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PSFontNeedCharSubs")) != NULL) { char *buf=UtilStrDup(c_ptr), *buf1=NULL, *psz_state=NULL; if (buf == NULL) FailAllocMessage(); for (buf1=UtilStrTok(buf, " ,\t\n\r", &psz_state); buf1 != NULL; buf1=UtilStrTok(NULL, " ,\t\n\r", &psz_state)) { char *token_name=strchr(buf1, '='); if (token_name == NULL) { fprintf(stderr, TgLoadString(STID_BAD_XDEF_CANT_FIND_EQ_SKIP), buf1, TOOL_NAME, "PSFontNeedCharSubs"); fprintf(stderr, "\n"); continue; } if (token_name[1] == '\0') { fprintf(stderr, TgLoadString(STID_BAD_XDEF_MISS_TOKEN_NAME_SKIP), buf1, TOOL_NAME, "PSFontNeedCharSubs"); fprintf(stderr, "\n"); continue; } *token_name = '\0'; if (LookupPSFontAliases(buf1) == NULL) { fprintf(stderr, TgLoadString(STID_BAD_FAKE_FONT_NAME_NO_ALIAS), TOOL_NAME, "PSFontNeedCharSubs", buf1, TOOL_NAME, "PSFontAliases"); fprintf(stderr, "\n"); *token_name = '='; continue; } ProcessPSCharSubs(buf1, &token_name[1]); *token_name = '='; } UtilFree(buf); } } void PrTgifInitBaseFonts() { int i; if (fontFamilies != NULL) return; fontFamilies = (struct FontFmlyRec *)malloc( MAXFONTS*sizeof(struct FontFmlyRec)); if (fontFamilies == NULL) FailAllocMessage(); memset(fontFamilies, 0, MAXFONTS*sizeof(struct FontFmlyRec)); for (i=0; i < MAXFONTS; i++) { int j; fontFamilies[i].name_faked = NULL; fontFamilies[i].bitmapped_ps_font = FALSE; *fontFamilies[i].choice_char = '\0'; for (j=0; j < MAXFONTSTYLES; j++) { fontFamilies[i].fr[j].next = NULL; fontFamilies[i].fr[j].xfs = NULL; } } } int GetCurSzUnit() { if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { return curRealSzUnit; } else { return curSzUnit; } } void PutCurSzUnit(sz_unit) int sz_unit; { if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { curRealSzUnit = sz_unit; } else { curSzUnit = sz_unit; } } void GetCurFontMsg(buf, pStrSeg) char *buf; StrSegInfo *pStrSeg; { char font_str[MAXSTRING]; GetPSFontStr(curFont, curStyle, font_str); if (pStrSeg != NULL && editTextSize != 0) { if (showFontSizeInPoints) { sprintf(buf, "%s-%1dpt (%s %1dpt)", &font_str[1], SzUnitToPointSize(pStrSeg->real_sz_unit), TgLoadCachedString(CSTID_EDIT_TEXT_SIZE_SUBSTR), SzUnitToPointSize(curSzUnit)); } else { sprintf(buf, "%s-%1d (%s %1d)", &font_str[1], SzUnitToFontSize(pStrSeg->real_sz_unit), TgLoadCachedString(CSTID_EDIT_TEXT_SIZE_SUBSTR), SzUnitToFontSize(curSzUnit)); } } else { if (showFontSizeInPoints) { sprintf(buf, "%s-%1dpt", &font_str[1], SzUnitToPointSize(curSzUnit)); } else { sprintf(buf, "%s-%1d", &font_str[1], SzUnitToFontSize(curSzUnit)); } } } void CurFontMsg(nShowInMsgWindow, nShowInStatusWindow, pStrSeg) int nShowInMsgWindow, nShowInStatusWindow; StrSegInfo *pStrSeg; { char buf[MAXSTRING]; GetCurFontMsg(buf, pStrSeg); if (nShowInMsgWindow) Msg(buf); if (nShowInStatusWindow) SetStringStatus(buf); } void DumpReEncodeVector(FP, vec_prefix, vec_suffix, flag_ptr) FILE *FP; char *vec_prefix, *vec_suffix; short *flag_ptr; { int j=0; PSCharSubs *ppscs=FindPSCharSubs(&vec_prefix[1]); fprintf(FP, "%s%s%s [\n", ((vec_prefix != NULL && *vec_prefix == '/') ? "" : "/"), vec_prefix, vec_suffix); for (j=0; j < 16; j++) { short flag=0; if (flag_ptr != NULL) { flag = *flag_ptr++; } else { /* dump the whole vector if flag_ptr is NULL */ flag = 0xff; } if ((flag & 0xff) != 0) { int k=0; for (k=0; k < 8; k++) { if (flag & (1<<k)) { char *spec=charCodeToName[(j<<3)+k]; if (spec && *spec && *spec != 'x') { int index=((j<<3)+k); /* avoid writing blank lines and "x" */ if (ppscs != NULL && ppscs->ps_char_name[index] != NULL) { fprintf(FP, " 8#%03o %s\n", (index|0x080), ppscs->ps_char_name[index]); } else { fprintf(FP, " %s\n", spec); } } } } } } fprintf(FP, " ] def\n"); } void DumpEightBitFontInfo(FP) FILE *FP; { int font_index=0, style_index=0, font_count=0; font_count = ((PRTGIF && !cmdLineOpenDisplay) ? MAXFONTS+numFakedFonts : numFonts+numFakedFonts); for (font_index=0; font_index < font_count; font_index++) { for (style_index=0; style_index < MAXFONTSTYLES; style_index++) { if (NeedEncode(NULL, font_index, style_index)) { char font_str[MAXSTRING]; *font_str = '\0'; GetPSFontStr(font_index, style_index, font_str); if (strncmp(font_str, "/(", 2) == 0) { /* bitmapped PS font! */ } else { char real_font_str[MAXSTRING]; DumpReEncodeVector(FP, font_str, "-vec", encodeCharFlags[font_index*MAXFONTSTYLES+style_index]); strcpy(real_font_str, font_str); MapAliasedPSFontName(real_font_str, sizeof(real_font_str)); fprintf(FP, "%s %s-8 %s-vec tgifReEncodeSmall\n\n", real_font_str, font_str, &font_str[1]); if (preDumpSetup) PSUseReencode(font_str); } } } } } static int fontSize75[]={ 8, 10, 12, 14, 18, 24 }; static int fontSize100[]={ 11, 14, 17, 20, 25, 34 }; int GetCompatibleSize(font_dpi, font_size) int font_dpi, font_size; { switch (font_dpi) { case FONT_DPI_75: return fontSize75[font_size]; case FONT_DPI_100: return fontSize100[font_size]; } return INVALID; } int SetCanvasFont() /* * Use curFont, curStyle, and curSzUnit to setup canvasFontPtr, * canvasFontDoubleByte, metrics related to the font, etc. * Returns TRUE to mean this font should be ``read-only''. */ { struct FontSizeRec *fs_ptr=NULL; int vert=FALSE, rc=TRUE; if (mainDisplay == NULL) return TRUE; actualCurFont = curFont; actualCurStyle = curStyle; actualCurSzUnit = curSzUnit; fs_ptr = FindFontInfo(curFont, curStyle, curSzUnit, FALSE); if (allowFontFaceSubstitution && fs_ptr == NULL) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "Font substitution detected in SetCanvasFont()", NULL); #endif /* _TGIF_DBG */ actualCurFont = defaultCurFont; actualCurStyle = defaultCurStyle; actualCurSzUnit = defaultCurSzUnit; fs_ptr = FindFontInfo(defaultCurFont, defaultCurStyle, defaultCurSzUnit, FALSE); } if (!allowFontFaceSubstitution && fs_ptr == NULL) { canvasFontSize = INVALID; return TRUE; } if (fs_ptr == NULL) { char buf[MAXSTRING]; GetCurFontMsg(buf, NULL); fprintf(stderr, TgLoadString(STID_CANT_FIND_FONT_USE_ALT), buf, defaultFontName); fprintf(stderr, "\n"); canvasFontPtr = defaultFontPtr; canvasFontSize = INVALID; } else { canvasFontPtr = fs_ptr->xfs; canvasFontSize = SzUnitToFontSize(fs_ptr->sz_unit); vert = fs_ptr->vert; rc = FALSE; } canvasFontAsc = canvasFontPtr->max_bounds.ascent; canvasFontDes = canvasFontPtr->max_bounds.descent; canvasFontDirection = canvasFontPtr->direction; /* * Need to fix this. */ canvasFontDontReencode = FALSE; /* * The following does not seem to work any more because of UTF-8 fonts * such as the ones that are iso10646-1 encoded. * canvasFontDoubleByte = (canvasFontPtr->min_byte1 != 0 || * canvasFontPtr->max_byte1 != 0); */ canvasFontDoubleByte = (canvasFontPtr->min_byte1 != 0); if (canvasFontDoubleByte) { canvasFontDoubleByteModBytes = ((canvasFontPtr->min_byte1 & 0x80) == 0); canvasFontDoubleByteVertical = vert; } else { canvasFontDoubleByteModBytes = FALSE; } canvasFontHeight = canvasFontAsc + canvasFontDes; XSetFont(mainDisplay, drawGC, canvasFontPtr->fid); textCursorH = canvasFontHeight; return rc; } int CurFontCheck() { changingFontSizeFromRead = FALSE; allowFontFaceSubstitution = FALSE; SetCanvasFont(); allowFontFaceSubstitution = TRUE; changingFontSizeFromRead = TRUE; return (SzUnitToFontSize(curSzUnit) == canvasFontSize); } int TrySetCanvasFont(font, style, size, must_find_requested, pnGotRequested) int font, style, size, must_find_requested, *pnGotRequested; /* * if size is not available, try all sizes in fontSzUnits[] */ { int i, last=0, saved_size=size, saved_sz_unit=curSzUnit, sz_unit=0; if (pnGotRequested != NULL) *pnGotRequested = FALSE; curFont = font; curStyle = style; sz_unit = FontSizeToSzUnit(size); curSzUnit = sz_unit; SetCanvasFont(); if (canvasFontSize != INVALID) { if (SzUnitToFontSize(curSzUnit) != canvasFontSize) { if (must_find_requested) { curSzUnit = saved_sz_unit; SetCanvasFont(); return FALSE; } SetFileModified(TRUE); curSzUnit = FontSizeToSzUnit(canvasFontSize); } if (pnGotRequested != NULL) { *pnGotRequested = (canvasFontSize==saved_size); } return TRUE; } if (must_find_requested) { curSzUnit = saved_sz_unit; SetCanvasFont(); return FALSE; } /* now try to find something close to the requested font */ for (i=0; i < numFontSizes; i++) { int size1=SzUnitToFontSize(fontSzUnits[i]); if (size1 >= saved_size) { break; } } if (i == numFontSizes) { return FALSE; } last = i; for (i=0; i < last; i++) { curSzUnit = fontSzUnits[i]; SetCanvasFont(); if (canvasFontSize != INVALID) { if (SzUnitToFontSize(curSzUnit) != canvasFontSize) { SetFileModified(TRUE); curSzUnit = FontSizeToSzUnit(canvasFontSize); } if (pnGotRequested != NULL) { *pnGotRequested = (canvasFontSize==saved_size); } return TRUE; } } if (SzUnitToFontSize(fontSzUnits[last]) == saved_size) { last++; } for (i=last; i < numFontSizes; i++) { curSzUnit = fontSzUnits[i]; SetCanvasFont(); if (canvasFontSize != INVALID) { if (SzUnitToFontSize(curSzUnit) != canvasFontSize) { SetFileModified(TRUE); curSzUnit = FontSizeToSzUnit(canvasFontSize); } if (pnGotRequested != NULL) { *pnGotRequested = (canvasFontSize==saved_size); } return TRUE; } } curSzUnit = saved_sz_unit; SetCanvasFont(); return FALSE; } void ObjFontInfoToCurFontInfo(TextPtr) struct TextRec *TextPtr; { textJust = TextPtr->minilines.just; textVSpace = TextPtr->minilines.v_space; curUnderlineYOffset = TextPtr->underline_y_offset; curOverlineYOffset = TextPtr->overline_y_offset; } void StrSegInfoToCurFontInfo(pStrSeg) StrSegInfo *pStrSeg; { curFont = pStrSeg->font; curStyle = pStrSeg->style; curSzUnit = pStrSeg->sz_unit; curUnderlineOn = pStrSeg->underline_on; curOverlineOn = pStrSeg->overline_on; } struct TmpFontFmlyRec { char **font_strings; int double_byte; struct TmpFontFmlyRec *next, *prev; }; static void SetupFontInfoStr(num_new_fonts, first_fmly) int num_new_fonts; struct TmpFontFmlyRec *first_fmly; { struct TmpFontFmlyRec *fmly_ptr=NULL, *next_fmly=NULL; int index=0, fmly_index=0; numFonts = MAXFONTS+num_new_fonts; fontFamilies = (struct FontFmlyRec *)malloc( numFonts*sizeof(struct FontFmlyRec)); if (fontFamilies == NULL) FailAllocMessage(); memset(fontFamilies, 0, numFonts*sizeof(struct FontFmlyRec)); fontInfoStr = (char**)malloc(numFonts*MAXFONTSTYLES*3*sizeof(char*)); fontMenuStr = (char**)malloc(numFonts*sizeof(char*)); if (fontInfoStr == NULL || fontMenuStr == NULL) FailAllocMessage(); memset(fontInfoStr, 0, numFonts*MAXFONTSTYLES*3*sizeof(char*)); memset(fontMenuStr, 0, numFonts*sizeof(char*)); index = MAXFONTS*MAXFONTSTYLES*3; for (fmly_ptr=first_fmly, fmly_index=MAXFONTS; fmly_ptr != NULL; fmly_ptr=next_fmly, fmly_index++) { char *c_ptr=NULL, font_name[MAXSTRING], choice_char[3]; int i=0, j=0, bitmapped_ps_font=FALSE; char *ps_font_name=fmly_ptr->font_strings[PS_FONT_NAME]; int font_name_len=strlen(ps_font_name); *choice_char = '\0'; next_fmly = fmly_ptr->next; if (*ps_font_name == '(' && ps_font_name[font_name_len-1] == ')') { strcpy(font_name, &ps_font_name[1]); font_name[font_name_len-2] = '\0'; strcpy(ps_font_name, font_name); RemovePSFontNameVariations(font_name); bitmapped_ps_font = TRUE; } else { strcpy(font_name, ps_font_name); RemovePSFontNameVariations(font_name); } for (i=0, j=0; i<MAXFONTSTYLES; i++, j+=3) { char *psz=fmly_ptr->font_strings[j+PS_FONT_NAME]; int len=strlen(psz); if (len > 0 && *psz == '(' && psz[len-1] == ')') { strcpy(gszMsgBox, &psz[1]); gszMsgBox[len-2] = '\0'; strcpy(psz, gszMsgBox); } } fontMenuStr[fmly_index] = (char*)malloc((strlen(font_name)+3)*sizeof(char)); if (fontMenuStr[fmly_index] == NULL) FailAllocMessage(); strcpy(fontMenuStr[fmly_index], font_name); if (strstr(fmly_ptr->font_strings[X_FONT_PREFIX], "%d") != NULL && UtilStrICmp(fmly_ptr->font_strings[X_FONT_SUFFIX], "V") == 0) { strcat(fontMenuStr[fmly_index], "-V"); } for (i=0, j=0; i<MAXFONTSTYLES; i++) { if (UtilStrICmp(fmly_ptr->font_strings[j+X_FONT_SUFFIX], "V") == 0) { fontFamilies[fmly_index].fr[i].vert = TRUE; } fontInfoStr[index++] = fmly_ptr->font_strings[j++]; fontInfoStr[index++] = fmly_ptr->font_strings[j++]; fontInfoStr[index++] = fmly_ptr->font_strings[j++]; } fontFamilies[fmly_index].double_byte = fmly_ptr->double_byte; free(fmly_ptr->font_strings); free(fmly_ptr); fontFamilies[fmly_index].fr[STYLE_NR].next = fontFamilies[fmly_index].fr[STYLE_BR].next = fontFamilies[fmly_index].fr[STYLE_NI].next = fontFamilies[fmly_index].fr[STYLE_BI].next = NULL; fontFamilies[fmly_index].fr[STYLE_NR].xfs = fontFamilies[fmly_index].fr[STYLE_BR].xfs = fontFamilies[fmly_index].fr[STYLE_NI].xfs = fontFamilies[fmly_index].fr[STYLE_BI].xfs = NULL; fontFamilies[fmly_index].bitmapped_ps_font = bitmapped_ps_font; *fontFamilies[fmly_index].choice_char = '\0'; sprintf(gszMsgBox, "%sShowFontChar", font_name); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,gszMsgBox)) != NULL) { int len=0; UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), c_ptr); UtilTrimBlanks(gszMsgBox); len = strlen(gszMsgBox); if (len > 0) { if (((*gszMsgBox) & 0x80) == 0) { if (gszMsgBox[len-1] == '"') gszMsgBox[--len] = '\0'; gszMsgBox[len++] = '"'; gszMsgBox[len] = '\0'; c_ptr = ReadString(gszMsgBox); if (c_ptr != gszMsgBox) c_ptr--; *c_ptr = '\0'; } strcpy(fontFamilies[fmly_index].choice_char, gszMsgBox); } } if (fontFamilies[fmly_index].double_byte) { char resource_name[MAXSTRING]; int count=0; sprintf(resource_name, "%sConvFromUTF8", font_name); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,resource_name)) != NULL) { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), c_ptr); UtilTrimBlanks(gszMsgBox); if (*gszMsgBox != '\0') { for (count=0, c_ptr=strstr(gszMsgBox,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count > 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF), TOOL_NAME, resource_name, gszMsgBox); fprintf(stderr, "\n"); } else { fontFamilies[fmly_index].conv_from_utf8_cmd = UtilStrDup(gszMsgBox); if (fontFamilies[fmly_index].conv_from_utf8_cmd == NULL) { FailAllocMessage(); } } } } sprintf(resource_name, "%sConvToUTF8", font_name); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,resource_name)) != NULL) { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), c_ptr); UtilTrimBlanks(gszMsgBox); if (*gszMsgBox != '\0') { for (count=0, c_ptr=strstr(gszMsgBox,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count > 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF), TOOL_NAME, resource_name, gszMsgBox); fprintf(stderr, "\n"); } else { fontFamilies[fmly_index].conv_to_utf8_cmd = UtilStrDup(gszMsgBox); if (fontFamilies[fmly_index].conv_to_utf8_cmd == NULL) { FailAllocMessage(); } } } } } } } static void CleanUpPSFontAliases() { if (gnNumPSFontAliases > 0) { while (gnNumPSFontAliases-- > 0) { UtilFree(gaPSFontAliases[gnNumPSFontAliases].key); UtilFree(gaPSFontAliases[gnNumPSFontAliases].value); } free(gaPSFontAliases); } gaPSFontAliases = NULL; gnNumPSFontAliases = 0; } static void InitPSFontAliases() { char *c_ptr=NULL; gaPSFontAliases = NULL; gnNumPSFontAliases = 0; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PSFontAliases")) != NULL) { char *buf=UtilStrDup(c_ptr), *fake_font_name=NULL; if (buf == NULL) FailAllocMessage(); for (fake_font_name=strtok(buf, ",\t\n\r"); fake_font_name != NULL; fake_font_name=strtok(NULL, ",\t\n\r")) { char *real_font_name=strchr(fake_font_name, '='); if (real_font_name == NULL) { fprintf(stderr, TgLoadString(STID_BAD_XDEF_CANT_FIND_EQ_SKIP), fake_font_name, TOOL_NAME, "PSFontAliases"); fprintf(stderr, "\n"); continue; } *real_font_name = '\0'; if (real_font_name[1] == '\0') { *real_font_name = '='; fprintf(stderr, TgLoadString(STID_BAD_XDEF_MISS_FONT_NAME_SKIP), fake_font_name, TOOL_NAME, "PSFontAliases"); fprintf(stderr, "\n"); continue; } ProcessAPSFontAlias(fake_font_name, real_font_name); *real_font_name = '='; } UtilFree(buf); } } static void InitAdditionalFonts() { int i, j, len, fmly_index, style_index, num_new_fonts=0; int got_double_fonts=FALSE; char *c_ptr=NULL, *buf=NULL; struct TmpFontFmlyRec *first_fmly=NULL, *last_fmly=NULL; fontFamilies = NULL; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"AdditionalFonts")) != NULL) { char *font_ptr=NULL; len = strlen(c_ptr); buf = (char*)malloc((len+1)*sizeof(char)); if (buf == NULL) FailAllocMessage(); strcpy(buf, c_ptr); for (font_ptr=buf; *font_ptr != '\0' && strchr(" ,\t\n\r",*font_ptr) != NULL; font_ptr++) { } if (font_ptr != NULL && *font_ptr != '\0') { int ok=TRUE, index=0, font_exists=FALSE; char **font_strings=NULL; struct TmpFontFmlyRec *fmly_ptr=NULL; while (ok && font_ptr != NULL && *font_ptr != '\0') { font_strings = (char**)malloc((MAXFONTSTYLES*3)*sizeof(char*)); if (font_strings == NULL) FailAllocMessage(); memset(font_strings, 0, (MAXFONTSTYLES*3)*sizeof(char*)); for (i=0, index=0; i<MAXFONTSTYLES; i++) { char *rgstry=NULL, *ps_name=NULL, *dup_ptr; dup_ptr = (font_ptr == NULL ? NULL : UtilStrDup(font_ptr)); if ((font_ptr=strtok(font_ptr,",\t\n\r")) != NULL && (rgstry=strtok(NULL,",\t\n\r")) != NULL && (ps_name=strtok(NULL," ,\t\n\r")) != NULL && (font_exists=DoesFontExist(font_ptr,FALSE)) != FALSE) { font_strings[index] = (char*)malloc(MAXSTRING*sizeof(char)); if (font_strings[index] == NULL) FailAllocMessage(); strcpy(font_strings[index], font_ptr); UtilTrimBlanks(font_strings[index++]); font_strings[index] = (char*)malloc(MAXSTRING*sizeof(char)); if (font_strings[index] == NULL) FailAllocMessage(); strcpy(font_strings[index], rgstry); UtilTrimBlanks(font_strings[index++]); font_strings[index] = (char*)malloc(MAXSTRING*sizeof(char)); if (font_strings[index] == NULL) FailAllocMessage(); strcpy(font_strings[index], ps_name); UtilTrimBlanks(font_strings[index++]); for (font_ptr=(&ps_name[strlen(ps_name)+1]); *font_ptr != '\0' && strchr(" ,\t\n\r",*font_ptr) != NULL; font_ptr++) { } } else { int dup_len=(dup_ptr == NULL ? 0 : strlen(dup_ptr)); if (dup_len > 128) { strcpy(&dup_ptr[128-3], "..."); } ok = FALSE; *gszMsgBox = '\0'; if (dup_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_MISS_FONT_SPEC_IN_XDEF), TOOL_NAME, "AdditionalFonts"); } else if (font_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_X_FONT_INFO_IN_XDEF), TOOL_NAME, "AdditionalFonts", dup_ptr); } else if (rgstry == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_X_REG_INFO_IN_XDEF), TOOL_NAME, "AdditionalFonts", dup_ptr); } else if (ps_name == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PS_INFO_IN_XDEF), TOOL_NAME, "AdditionalFonts", dup_ptr); } else if (!font_exists) { ok = TRUE; if (reportMissingFonts) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_NO_SUCH_FONT), font_ptr); } for (font_ptr=(&ps_name[strlen(ps_name)+1]); *font_ptr != '\0' && strchr(" ,\t\n\r",*font_ptr) != NULL; font_ptr++) { } } if (*gszMsgBox != '\0') { fprintf(stderr, "%s\n", gszMsgBox); } } if (dup_ptr != NULL) free(dup_ptr); if (!ok) break; } if (ok && font_exists) { num_new_fonts++; fmly_ptr = (struct TmpFontFmlyRec *)malloc( sizeof(struct TmpFontFmlyRec)); if (fmly_ptr == NULL) FailAllocMessage(); memset(fmly_ptr, 0, sizeof(struct TmpFontFmlyRec)); fmly_ptr->next = NULL; fmly_ptr->prev = last_fmly; fmly_ptr->font_strings = font_strings; if (last_fmly == NULL) { first_fmly = fmly_ptr; } else { last_fmly->next = fmly_ptr; } last_fmly = fmly_ptr; } else if (!font_exists) { if (font_strings != NULL) { for (i=0; i<MAXFONTSTYLES*3; i++) { UtilFree(font_strings[i]); } free(font_strings); } } if (font_ptr-buf >= len) break; } } free(buf); } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"SquareDoubleByteFonts")) != NULL) { char *font_ptr=NULL; len = strlen(c_ptr); buf = (char*)malloc((len+1)*sizeof(char)); if (buf == NULL) FailAllocMessage(); strcpy(buf, c_ptr); for (font_ptr=buf; *font_ptr != '\0' && strchr(" ,\t\n\r",*font_ptr) != NULL; font_ptr++) { } if (font_ptr != NULL && *font_ptr != '\0') { int ok=TRUE, index=0, font_exists=FALSE; char **font_strings=NULL; struct TmpFontFmlyRec *fmly_ptr=NULL; while (ok && font_ptr != NULL && *font_ptr != '\0') { font_strings = (char**)malloc((MAXFONTSTYLES*3)*sizeof(char *)); if (font_strings == NULL) FailAllocMessage(); memset(font_strings, 0, (MAXFONTSTYLES*3)*sizeof(char*)); for (i=0, index=0; i<MAXFONTSTYLES; i++) { char *rgstry=NULL, *ps_name=NULL, *dup_ptr; dup_ptr = (font_ptr == NULL ? NULL : UtilStrDup(font_ptr)); if ((font_ptr=strtok(font_ptr,",\t\n\r")) != NULL && (rgstry=strtok(NULL,",\t\n\r")) != NULL && (ps_name=strtok(NULL," ,\t\n\r")) != NULL && (font_exists=DoesFontExist(font_ptr,TRUE)) != FALSE) { font_strings[index] = (char*)malloc(MAXSTRING*sizeof(char)); if (font_strings[index] == NULL) FailAllocMessage(); strcpy(font_strings[index], font_ptr); UtilTrimBlanks(font_strings[index++]); font_strings[index] = (char*)malloc(MAXSTRING*sizeof(char)); if (font_strings[index] == NULL) FailAllocMessage(); strcpy(font_strings[index], rgstry); UtilTrimBlanks(font_strings[index++]); font_strings[index] = (char*)malloc(MAXSTRING*sizeof(char)); if (font_strings[index] == NULL) FailAllocMessage(); strcpy(font_strings[index], ps_name); UtilTrimBlanks(font_strings[index++]); for (font_ptr=(&ps_name[strlen(ps_name)+1]); *font_ptr != '\0' && strchr(" ,\t\n\r",*font_ptr) != NULL; font_ptr++) { } } else { int dup_len=(dup_ptr == NULL ? 0 : strlen(dup_ptr)); if (dup_len > 128) { strcpy(&dup_ptr[128-3], "..."); } ok = FALSE; *gszMsgBox = '\0'; if (dup_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_MISS_FONT_SPEC_IN_XDEF), TOOL_NAME, "SquareDoubleByteFonts", dup_ptr); } else if (font_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_X_FONT_INFO_IN_XDEF), TOOL_NAME, "SquareDoubleByteFonts", dup_ptr); } else if (rgstry == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_X_REG_INFO_IN_XDEF), TOOL_NAME, "SquareDoubleByteFonts", dup_ptr); } else if (ps_name == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PS_INFO_IN_XDEF), TOOL_NAME, "SquareDoubleByteFonts", dup_ptr); } else if (!font_exists) { ok = TRUE; if (reportMissingFonts) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_NO_SUCH_FONT), font_ptr); } for (font_ptr=(&ps_name[strlen(ps_name)+1]); *font_ptr != '\0' && strchr(" ,\t\n\r",*font_ptr) != NULL; font_ptr++) { } } if (*gszMsgBox != '\0') { fprintf(stderr, "%s\n", gszMsgBox); } } if (dup_ptr != NULL) free(dup_ptr); if (!ok) break; } if (ok && font_exists) { num_new_fonts++; fmly_ptr = (struct TmpFontFmlyRec *)malloc( sizeof(struct TmpFontFmlyRec)); if (fmly_ptr == NULL) FailAllocMessage(); memset(fmly_ptr, 0, sizeof(struct TmpFontFmlyRec)); fmly_ptr->next = NULL; fmly_ptr->prev = last_fmly; fmly_ptr->font_strings = font_strings; fmly_ptr->double_byte = TRUE; if (last_fmly == NULL) { first_fmly = fmly_ptr; } else { last_fmly->next = fmly_ptr; } last_fmly = fmly_ptr; } else if (!font_exists) { if (font_strings != NULL) { for (i=0; i<MAXFONTSTYLES*3; i++) { UtilFree(font_strings[i]); } free(font_strings); } } if (font_ptr-buf >= len) break; } } free(buf); got_double_fonts = TRUE; } if (num_new_fonts > 0 && first_fmly != NULL) { /* setup fontInfoStr[] */ SetupFontInfoStr(num_new_fonts, first_fmly); } if (fontFamilies == NULL) { fontFamilies = (struct FontFmlyRec *)malloc(numFonts*sizeof(struct FontFmlyRec)); if (fontFamilies == NULL) FailAllocMessage(); memset(fontFamilies, 0, numFonts*sizeof(struct FontFmlyRec)); fontInfoStr = (char**)malloc(numFonts*MAXFONTSTYLES*3*sizeof(char*)); fontMenuStr = (char**)malloc(numFonts*sizeof(char*)); if (fontInfoStr == NULL || fontMenuStr == NULL) FailAllocMessage(); memset(fontInfoStr, 0, numFonts*MAXFONTSTYLES*3*sizeof(char*)); memset(fontMenuStr, 0, numFonts*sizeof(char*)); } altFontInfoStr = (char**)malloc(MAXFONTS*MAXFONTSTYLES*3*sizeof(char*)); if (altFontInfoStr == NULL) FailAllocMessage(); for (j=0; j<MAXFONTS*MAXFONTSTYLES*3; j++) altFontInfoStr[j] = NULL; i = 0; fmly_index = 0; for (fmly_index=0; fmly_index < MAXFONTS; fmly_index++) { char s[MAXSTRING]; int bitmapped_ps_font=FALSE; int font_name_len=strlen(initFontInfoStr[i+PS_FONT_NAME]); if (*initFontInfoStr[i+PS_FONT_NAME] == '(' && initFontInfoStr[i+PS_FONT_NAME][font_name_len-1] == ')') { /* * This shouldn't happen because none of the initFontInfoStr * should have the bitmapped_ps_font! */ strcpy(s, &(initFontInfoStr[i+PS_FONT_NAME])[1]); s[font_name_len-2] = '\0'; strcpy(initFontInfoStr[i+PS_FONT_NAME], s); RemovePSFontNameVariations(s); bitmapped_ps_font = TRUE; } else { strcpy(s, initFontInfoStr[i+PS_FONT_NAME]); RemovePSFontNameVariations(s); } fontMenuStr[fmly_index] = (char*)malloc((strlen(s)+1)*sizeof(char)); if (fontMenuStr[fmly_index] == NULL) FailAllocMessage(); strcpy(fontMenuStr[fmly_index], s ); for (style_index=0; style_index < MAXFONTSTYLES; style_index++) { if (hasAlternateDefaultFonts && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, initFontInfoStr[i+PS_FONT_NAME])) != NULL) { char *ps_font_name=strchr(c_ptr, ','); if (ps_font_name != NULL) *ps_font_name++ = '\0'; if (strstr(c_ptr, "%d") != NULL) { altFontInfoStr[i] = UtilStrDup(c_ptr); if (altFontInfoStr[i] == NULL) FailAllocMessage(); fontInfoStr[i] = altFontInfoStr[i]; } else { fprintf(stderr, TgLoadString(STID_ERR_PROCESS_FONT_USE_ALT), TOOL_NAME, initFontInfoStr[i+PS_FONT_NAME], c_ptr, fontNamePrefix, initFontInfoStr[i], initFontInfoStr[i+X_FONT_SUFFIX]); fprintf(stderr, "\n"); fontInfoStr[i] = initFontInfoStr[i]; } i++; fontInfoStr[i] = initFontInfoStr[i]; i++; if (ps_font_name != NULL) { altFontInfoStr[i] = UtilStrDup(ps_font_name); if (altFontInfoStr[i] == NULL) FailAllocMessage(); fontInfoStr[i] = altFontInfoStr[i]; } else { fontInfoStr[i] = initFontInfoStr[i]; } i++; } else { fontInfoStr[i] = initFontInfoStr[i]; i++; if (fmly_index == FONT_TIM || fmly_index == FONT_COU || fmly_index == FONT_HEL || fmly_index == FONT_CEN) { fontInfoStr[i] = defaultLatin1FontCharEncoding; i++; } else { fontInfoStr[i] = initFontInfoStr[i]; i++; } fontInfoStr[i] = initFontInfoStr[i]; i++; } } fontFamilies[fmly_index].fr[STYLE_NR].next = fontFamilies[fmly_index].fr[STYLE_BR].next = fontFamilies[fmly_index].fr[STYLE_NI].next = fontFamilies[fmly_index].fr[STYLE_BI].next = NULL; fontFamilies[fmly_index].fr[STYLE_NR].xfs = fontFamilies[fmly_index].fr[STYLE_BR].xfs = fontFamilies[fmly_index].fr[STYLE_NI].xfs = fontFamilies[fmly_index].fr[STYLE_BI].xfs = NULL; fontFamilies[fmly_index].bitmapped_ps_font = bitmapped_ps_font; *fontFamilies[fmly_index].choice_char = '\0'; } defaultSingleByteFont = FONT_TIM; if (got_double_fonts) { if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DefaultSingleByteFont")) != NULL) { for (i=0; i < numFonts; i++) { if (UtilStrICmp(c_ptr, fontMenuStr[i]) == 0) { if (IsFontDoubleByte(i)) { fprintf(stderr, TgLoadString(STID_INVALID_SB_FONT_USE_DB_FONT), TOOL_NAME, "DefaultSingleByteFont", c_ptr); fprintf(stderr, "\n"); } else { defaultSingleByteFont = i; } break; } } } } } /* do not translate -- program constants */ static char *gaszFontStyles[]={ "Roman", "Bold", "Italic", "BoldItalic", NULL }; static char *gaszFontJusts[]={ "Left", "Center", "Right", NULL }; #ifndef _NO_LOCALE_SUPPORT #ifdef ENABLE_NLS static void InitABasicFontSet(pFontSet, ppszFontSetName, opt_name, pnFontWidth, pnFontAsc, pnFontDes, pnFontHeight, def_font_name) XFontSet *pFontSet; char **ppszFontSetName, *opt_name, *def_font_name; int *pnFontWidth, *pnFontAsc, *pnFontDes, *pnFontHeight; { char *c_ptr=NULL; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, opt_name)) != NULL) { if (UtilStrICmp(c_ptr, "none") == 0) { /* don't attempt to call XCreateFontSet() */ } else { char **missing_charsets=NULL, *default_string=NULL; int num_missing_charsets=0; XFontSet xfset=NULL; *ppszFontSetName = UtilStrDup(c_ptr); if (*ppszFontSetName == NULL) FailAllocMessage(); xfset = XCreateFontSet(mainDisplay, *ppszFontSetName, &missing_charsets, &num_missing_charsets, &default_string); if (xfset == NULL) { fprintf(stderr, TgLoadString(STID_CANNOT_LOAD_FONTSET), TOOL_NAME, opt_name, *ppszFontSetName); fprintf(stderr, "\n"); if (*ppszFontSetName != NULL) free(*ppszFontSetName); *ppszFontSetName = NULL; } else { *pFontSet = xfset; } } } else { char **missing_charsets=NULL, *default_string=NULL; int num_missing_charsets=0; char *fn1=def_font_name; char *fn2="-*-*-medium-r-*--12-*-*-*-*-*-*-*"; int sz=strlen(fn1)+strlen(fn2)+1; XFontSet xfset=NULL; memset(&xfset, 0, sizeof(XFontSet)); *ppszFontSetName = (char*)malloc((sz+1)*sizeof(char)); if (*ppszFontSetName == NULL) FailAllocMessage(); sprintf(*ppszFontSetName, "%s,%s", fn1, fn2); xfset = XCreateFontSet(mainDisplay, *ppszFontSetName, &missing_charsets, &num_missing_charsets, &default_string); if (xfset == NULL) { fprintf(stderr, TgLoadString(STID_CANNOT_LOAD_FONTSET), TOOL_NAME, opt_name, *ppszFontSetName); fprintf(stderr, "\n"); if (*ppszFontSetName != NULL) free(*ppszFontSetName); *ppszFontSetName = NULL; } else { *pFontSet = xfset; } } if (*pFontSet != NULL) { XFontStruct **xfset_list=NULL; char **font_name_list=NULL; int n=0; n = XFontsOfFontSet(*pFontSet, &xfset_list, &font_name_list); /* do not translate -- the string is used to measure things */ *pnFontWidth = XmbTextEscapement(*pFontSet, "x", 1); *pnFontAsc = (*xfset_list)->max_bounds.ascent; *pnFontDes = (*xfset_list)->max_bounds.descent; *pnFontHeight = menuFontAsc + menuFontDes; } } #endif /* ENABLE_NLS */ #endif /* ~_NO_LOCALE_SUPPORT */ static void InitABasicFontPtr(ppFontPtr, ppszFontName, opt_name, def_font_name, pnFontWidth, pnFontAsc, pnFontDes, pnFontHeight, pnFoundInXDefault, msg_font_name) XFontStruct **ppFontPtr; char **ppszFontName, *opt_name, *def_font_name, *msg_font_name; int *pnFontWidth, *pnFontAsc, *pnFontDes, *pnFontHeight, *pnFoundInXDefault; { XFontStruct *xfs=NULL; char *c_ptr=NULL; *ppFontPtr = NULL; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, opt_name)) != NULL) { /* First try to see if the default is overridden by an X default */ *ppszFontName = UtilStrDup(c_ptr); if (*ppszFontName == NULL) FailAllocMessage(); xfs = XLoadQueryFont(mainDisplay, *ppszFontName); if (xfs == NULL) { fprintf(stderr, TgLoadString(STID_CANNOT_LOAD_FONT), TOOL_NAME, opt_name, *ppszFontName); fprintf(stderr, "\n"); if (*ppszFontName != NULL) free(*ppszFontName); *ppszFontName = NULL; } else { *ppFontPtr = xfs; if (pnFoundInXDefault != NULL && msg_font_name == NULL) { *pnFoundInXDefault = TRUE; } } } else { /* Not in X default, now try the default value */ *ppszFontName = UtilStrDup(def_font_name); if (*ppszFontName == NULL) FailAllocMessage(); xfs = XLoadQueryFont(mainDisplay, *ppszFontName); if (xfs == NULL) { if (*ppszFontName != NULL) free(*ppszFontName); *ppszFontName = NULL; } else { *ppFontPtr = xfs; } } if (*ppszFontName == NULL && pnFoundInXDefault != NULL && (*pnFoundInXDefault) && msg_font_name != NULL) { /* * If it's not in X default and the default value does not work, * if MsgFont is valid (from a previous call to this function * with opt_name being "MsgFont", use it! */ *ppszFontName = UtilStrDup(msg_font_name); if (*ppszFontName == NULL) FailAllocMessage(); xfs = XLoadQueryFont(mainDisplay, *ppszFontName); if (xfs == NULL) { fprintf(stderr, TgLoadString(STID_CANNOT_LOAD_FONT), TOOL_NAME, opt_name, *ppszFontName); fprintf(stderr, "\n"); if (*ppszFontName != NULL) free(*ppszFontName); *ppszFontName = NULL; } else { *ppFontPtr = xfs; } } if (*ppFontPtr != NULL) { /* do not translate -- the string is used to measure things */ *pnFontWidth = XTextWidth(*ppFontPtr, "x", 1); *pnFontAsc = (*ppFontPtr)->max_bounds.ascent; *pnFontDes = (*ppFontPtr)->max_bounds.descent; *pnFontHeight = menuFontAsc + menuFontDes; } } static void InitFontSetsAndBasicFonts() { int user_msg_font=FALSE; boldMsgFontDoubleByte = FALSE; #ifndef _NO_LOCALE_SUPPORT #ifdef ENABLE_NLS if (boldMsgFontSet != NULL) { char *c_ptr=NULL; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"BoldMsgFontDoubleByte")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { boldMsgFontDoubleByte = TRUE; } } #endif /* ENABLE_NLS */ #endif /* ~_NO_LOCALE_SUPPORT */ menuFontSet = NULL; #ifndef _NO_LOCALE_SUPPORT #ifdef ENABLE_NLS InitABasicFontSet(&menuFontSet, &menuFontSetName, "MenuFontSet", &menuFontWidth, &menuFontAsc, &menuFontDes, &menuFontHeight, "-*-helvetica-medium-r-normal--12-*-*-*-*-*-*-*"); #endif /* ENABLE_NLS */ #endif /* ~_NO_LOCALE_SUPPORT */ if (menuFontSet == NULL) { menuFontPtr = NULL; InitABasicFontPtr(&menuFontPtr, &menuFontName, "MenuFont", "-*-helvetica-medium-r-normal--12-*-*-*-*-*-*-*", &menuFontWidth, &menuFontAsc, &menuFontDes, &menuFontHeight, NULL, NULL); } msgFontSet = NULL; #ifndef _NO_LOCALE_SUPPORT #ifdef ENABLE_NLS InitABasicFontSet(&msgFontSet, &msgFontSetName, "MsgFontSet", &msgFontWidth, &msgFontAsc, &msgFontDes, &msgFontHeight, "-*-helvetica-medium-r-normal--12-*-*-*-*-*-*-*"); #endif /* ENABLE_NLS */ #endif /* ~_NO_LOCALE_SUPPORT */ if (msgFontSet == NULL) { msgFontPtr = NULL; InitABasicFontPtr(&msgFontPtr, &msgFontName, "MsgFont", "-*-helvetica-medium-r-normal--12-*-*-*-*-*-*-*", &msgFontWidth, &msgFontAsc, &msgFontDes, &msgFontHeight, &user_msg_font, NULL); } boldMsgFontSet = NULL; #ifndef _NO_LOCALE_SUPPORT #ifdef ENABLE_NLS InitABasicFontSet(&boldMsgFontSet, &boldMsgFontSetName, "BoldMsgFontSet", &boldMsgFontWidth, &boldMsgFontAsc, &boldMsgFontDes, &boldMsgFontHeight, "-*-helvetica-bold-r-normal--12-*-*-*-*-*-*-*"); #endif /* ENABLE_NLS */ #endif /* ~_NO_LOCALE_SUPPORT */ if (boldMsgFontSet == NULL) { boldMsgFontPtr = NULL; InitABasicFontPtr(&boldMsgFontPtr, &boldMsgFontName, "BoldMsgFont", "-*-helvetica-bold-r-normal--12-*-*-*-*-*-*-*", &boldMsgFontWidth, &boldMsgFontAsc, &boldMsgFontDes, &boldMsgFontHeight, &user_msg_font, msgFontName); } italicMsgFontSet = NULL; #ifndef _NO_LOCALE_SUPPORT #ifdef ENABLE_NLS InitABasicFontSet(&italicMsgFontSet, &italicMsgFontSetName, "ItalicMsgFontSet", &italicMsgFontWidth, &italicMsgFontAsc, &italicMsgFontDes, &italicMsgFontHeight, "-*-helvetica-medium-o-normal--12-*-*-*-*-*-*-*"); #endif /* ENABLE_NLS */ #endif /* ~_NO_LOCALE_SUPPORT */ if (italicMsgFontSet == NULL) { italicMsgFontPtr = NULL; InitABasicFontPtr(&italicMsgFontPtr, &italicMsgFontName, "ItalicMsgFont", "-*-helvetica-medium-o-normal--12-*-*-*-*-*-*-*", &italicMsgFontWidth, &italicMsgFontAsc, &italicMsgFontDes, &italicMsgFontHeight, &user_msg_font, msgFontName); } boldItalicMsgFontSet = NULL; #ifndef _NO_LOCALE_SUPPORT #ifdef ENABLE_NLS InitABasicFontSet(&boldItalicMsgFontSet, &boldItalicMsgFontSetName, "BoldItalicMsgFontSet", &boldItalicMsgFontWidth, &boldItalicMsgFontAsc, &boldItalicMsgFontDes, &boldItalicMsgFontHeight, "-*-helvetica-bold-o-normal--12-*-*-*-*-*-*-*"); #endif /* ENABLE_NLS */ #endif /* ~_NO_LOCALE_SUPPORT */ if (boldItalicMsgFontSet == NULL) { boldItalicMsgFontPtr = NULL; InitABasicFontPtr(&boldItalicMsgFontPtr, &boldItalicMsgFontName, "BoldItalicMsgFont", "-*-helvetica-bold-o-normal--12-*-*-*-*-*-*-*", &boldItalicMsgFontWidth, &boldItalicMsgFontAsc, &boldItalicMsgFontDes, &boldItalicMsgFontHeight, &user_msg_font, msgFontName); } } void InitFonts() { int i=0, ruler_font_size=0; char *c_ptr=NULL, *buf=NULL, buf1[MAXSTRING]; struct FontSizeRec *fs_ptr=NULL; XFontStruct *xfs=NULL; memset(&gstSavedFontInfo, 0, sizeof(struct PushedFontRec)); rotatedVertFontImage = NULL; vertFontBitmap = rotatedVertFontBitmap = None; vertFontBitmapW = vertFontBitmapH = 0; debugScalableFonts = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DebugScalableFonts")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { debugScalableFonts = TRUE; } defaultFontSize = DEFAULT_FONT_SIZE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DefaultFontSize")) != NULL) { if ((defaultFontSize=atoi(c_ptr)) <= 0) { defaultFontSize = DEFAULT_FONT_SIZE; fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "DefaultFontSize", c_ptr, DEFAULT_FONT_SIZE); fprintf(stderr, "\n"); } } strcpy(fontNamePrefix, "-*"); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"FontNamePrefix")) != NULL) { strcpy(fontNamePrefix, c_ptr); } strcpy(defaultLatin1FontCharEncoding, "iso8859-1"); if ((c_ptr= XGetDefault(mainDisplay,TOOL_NAME,"DefaultLatin1FontCharEncoding")) != NULL) { strcpy(defaultLatin1FontCharEncoding, c_ptr); } showFontSizeInPoints = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ShowFontSizeInPoints")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { showFontSizeInPoints = TRUE; } fontSzUnits = NULL; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"FontSizes")) != NULL) { char *size_ptr; int allocated=50, ok=TRUE; numFontSizes = 0; fontSzUnits = (int*)malloc(allocated*sizeof(int)); if (fontSzUnits == NULL) FailAllocMessage(); sizeMenuStr = (char**)malloc(allocated*sizeof(char*)); if (sizeMenuStr == NULL) FailAllocMessage(); buf = UtilStrDup(c_ptr); if (buf == NULL) FailAllocMessage(); if ((size_ptr=strtok(buf," ,\t\n\r")) != NULL) { while (ok && size_ptr != NULL) { int size=0, sz_unit=0; char *psz=NULL, saved_ch='\0'; UtilStrLower(size_ptr); /* do not translate -- program constants */ if ((psz=strstr(size_ptr, "pt")) != NULL) { saved_ch = *psz; *psz = '\0'; size = atoi(size_ptr); sz_unit = PointSizeToSzUnit(size); *psz = saved_ch; } else { size = atoi(size_ptr); sz_unit = FontSizeToSzUnit(size); } if (size <= 0 || size>=1000) { ok = FALSE; break; } if (numFontSizes >= allocated) { allocated += 50; fontSzUnits = (int*)realloc(fontSzUnits, allocated*sizeof(int)); sizeMenuStr = (char**)realloc(sizeMenuStr, allocated*sizeof(char*)); } sizeMenuStr[numFontSizes] = (char*)malloc(40*sizeof(char)); if (sizeMenuStr[numFontSizes] == NULL) FailAllocMessage(); if (showFontSizeInPoints) { sprintf(sizeMenuStr[numFontSizes], "%3d pts", SzUnitToPointSize(sz_unit)); } else { sprintf(sizeMenuStr[numFontSizes], "%3d", SzUnitToFontSize(sz_unit)); } fontSzUnits[numFontSizes++] = sz_unit; size_ptr = strtok(NULL, " ,\t\n\r"); } } UtilFree(buf); if (!ok || numFontSizes <= 0) { for (i=0; i < numFontSizes; i++) free(sizeMenuStr[i]); free(sizeMenuStr); sizeMenuStr = NULL; free(fontSzUnits); fontSzUnits = NULL; numFontSizes = 0; fprintf(stderr, TgLoadString(STID_ERR_PROCESS_SIZE_USE_DEF_SIZE), TOOL_NAME, "FontSizes"); fprintf(stderr, "\n"); } } if (fontSzUnits == NULL) { numFontSizes = (MAXFONTSIZES<<1)-1; fontSzUnits = (int*)malloc(numFontSizes*sizeof(int)); if (fontSzUnits == NULL) FailAllocMessage(); sizeMenuStr = (char**)malloc(numFontSizes*sizeof(char*)); if (sizeMenuStr == NULL) FailAllocMessage(); for (i=0; i<numFontSizes; i++) { char *psz=initSizeMenuStr[i]; fontSzUnits[i] = FontSizeToSzUnit(atoi(psz)); sizeMenuStr[i] = (char*)malloc(40*sizeof(char)); if (sizeMenuStr[i] == NULL) FailAllocMessage(); if (showFontSizeInPoints) { sprintf(sizeMenuStr[i], "%3d pts", SzUnitToPointSize(FontSizeToSzUnit(atoi(psz)))); } else { strcpy(sizeMenuStr[i], psz); } } } hasAlternateDefaultFonts = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"HasAlternateDefaultFonts")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { hasAlternateDefaultFonts = TRUE; } #ifdef _TGIF_DBG reportMissingFonts = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ReportMissingFonts")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { reportMissingFonts = FALSE; } #else /* ~ _TGIF_DBG */ reportMissingFonts = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ReportMissingFonts")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { reportMissingFonts = TRUE; } #endif /* _TGIF_DBG */ InitDontReencode(NULL); InitAdditionalFonts(); InitPSFontAliases(); InitPSFontCharSubs(); curFont = FONT_COU; curStyle = STYLE_NR; curSzUnit = FontSizeToSzUnit(14); ruler_font_size = 10; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "RulerFontSize")) != NULL) { ruler_font_size = atoi(c_ptr); if (ruler_font_size <= 0) { ruler_font_size = defaultFontSize; fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "RulerFontSize", c_ptr, ruler_font_size); fprintf(stderr, "\n"); } } if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "InitialFontDPI")) != NULL) { fprintf(stderr, TgLoadString(STID_OBSOLETE_XDEF_USE_ALT), TOOL_NAME, "InitialFontDPI", TOOL_NAME, "InitialFontSize"); fprintf(stderr, "\n"); } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MsgFontSizeIndex")) != NULL) { fprintf(stderr, TgLoadString(STID_OBSOLETE_XDEF_USE_ALT), TOOL_NAME, "MsgFontSizeIndex", TOOL_NAME, "MsgFontSize"); fprintf(stderr, "\n"); } if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "MsgFontSize")) != NULL) { UtilStrCpyN(buf1, sizeof(buf1), c_ptr); curSzUnit = FontSizeToSzUnit(atoi(buf1)); if (curSzUnit <= 0) { curSzUnit = FontSizeToSzUnit(defaultFontSize); fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "MsgFontSize", buf1, defaultFontSize); fprintf(stderr, "\n"); } } defaultFontPtr = NULL; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DefFixedWidthFont")) != NULL) { defaultFontName = UtilStrDup(c_ptr); if (defaultFontName == NULL) FailAllocMessage(); xfs = XLoadQueryFont(mainDisplay, defaultFontName); if (xfs == NULL) { fprintf(stderr, TgLoadString(STID_CANNOT_LOAD_FONT), TOOL_NAME, "DefFixedWidthFont", defaultFontName); fprintf(stderr, "\n"); if (defaultFontName != NULL) free(defaultFontName); defaultFontName = NULL; defaultFontPtr = NULL; } else { defaultFontPtr = xfs; defaultFontWidth = defaultFontPtr->max_bounds.width; defaultFontAsc = defaultFontPtr->max_bounds.ascent; defaultFontDes = defaultFontPtr->max_bounds.descent; defaultFontHeight = defaultFontAsc + defaultFontDes; } } if (defaultFontPtr == NULL) { fs_ptr = FindFontInfo(curFont, curStyle, curSzUnit, TRUE); if (fs_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_DEF_MSG_FONT_ABORT), gszAttemptedFontName); Error("OpenFont()", gszMsgBox); } defaultFontPtr = fs_ptr->xfs; defaultFontWidth = defaultFontPtr->max_bounds.width; defaultFontAsc = defaultFontPtr->max_bounds.ascent; defaultFontDes = defaultFontPtr->max_bounds.descent; defaultFontHeight = defaultFontAsc + defaultFontDes; } if (defaultFontWidth < 1 || defaultFontHeight < 1) { fprintf(stderr, TgLoadString(STID_WARN_VERY_SMALL_DEF_FONT), defaultFontWidth, defaultFontHeight); fprintf(stderr, "\n"); defaultFontWidth = 9; defaultFontHeight = 14; } rulerFontPtr = NULL; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "DefFixedWidthRulerFont")) != NULL) { rulerFontName = UtilStrDup(c_ptr); if (rulerFontName == NULL) FailAllocMessage(); xfs = XLoadQueryFont(mainDisplay, rulerFontName); if (xfs == NULL) { fprintf(stderr, TgLoadString(STID_CANNOT_LOAD_FONT), TOOL_NAME, "DefFixedWidthRulerFont", rulerFontName); fprintf(stderr, "\n"); if (rulerFontName != NULL) free(rulerFontName); rulerFontName = NULL; rulerFontPtr = NULL; } else { rulerFontPtr = xfs; rulerFontWidth = rulerFontPtr->max_bounds.width; rulerFontAsc = rulerFontPtr->max_bounds.ascent; rulerFontDes = rulerFontPtr->max_bounds.descent; rulerFontHeight = rulerFontAsc + rulerFontDes; } } if (rulerFontPtr == NULL) { fs_ptr = FindFontInfo(curFont, curStyle, FontSizeToSzUnit(ruler_font_size), TRUE); if (fs_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_RULER_FONT_ABORT), gszAttemptedFontName); Error("OpenFont()", gszMsgBox); } rulerFontPtr = fs_ptr->xfs; rulerFontWidth = rulerFontPtr->max_bounds.width; rulerFontAsc = rulerFontPtr->max_bounds.ascent; rulerFontDes = rulerFontPtr->max_bounds.descent; rulerFontHeight = rulerFontAsc + rulerFontDes; } if (rulerFontWidth < 1 || rulerFontHeight < 1) { fprintf(stderr, TgLoadString(STID_WARN_VERY_SMALL_RULER_FONT), rulerFontWidth, rulerFontHeight); fprintf(stderr, "\n"); rulerFontWidth = 7; rulerFontHeight = 12; } InitFontSetsAndBasicFonts(); initialFont = curFont; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "InitialFont")) != NULL) { for (i = 0; i < numFonts; i++) { if (strcmp(c_ptr, fontMenuStr[i]) == 0) { break; } } if (i != numFonts) { initialFont = curFont = i; } else { fprintf(stderr, TgLoadString(STID_CANNOT_SET_INITIAL_FONT_TO), c_ptr); fprintf(stderr, "\n"); } } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"InitialFontStyle")) != NULL) { for (i = 0; i < MAXFONTSTYLES; i++) { if (UtilStrICmp(c_ptr, gaszFontStyles[i]) == 0) { curStyle = i; break; } } if (i == MAXFONTSTYLES) { fprintf(stderr, TgLoadString(STID_CANT_SET_INIT_FONTSTYLE_ALT), c_ptr, "Roman"); fprintf(stderr, "\n"); } } if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "InitialFontJust")) != NULL) { for (i = 0; i < MAXJUSTS; i++) { if (UtilStrICmp(c_ptr, gaszFontJusts[i]) == 0) { textJust = i; break; } } if (i == MAXJUSTS) { fprintf(stderr, TgLoadString(STID_CANT_SET_INIT_FONTJUST_ALT), c_ptr, "Left"); fprintf(stderr, "\n"); } } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"InitialFontSizeIndex")) != NULL) { fprintf(stderr, TgLoadString(STID_OBSOLETE_XDEF_USE_ALT), TOOL_NAME, "InitialFontSizeIndex", TOOL_NAME, "InitialFontSize"); fprintf(stderr, "\n"); } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"InitialFontSize")) != NULL) { UtilStrCpyN(buf1, sizeof(buf1), c_ptr); UtilStrLower(buf1); if ((c_ptr=strstr(buf1, "pt")) != NULL) { char saved_ch=(*c_ptr); *c_ptr = '\0'; curSzUnit = PointSizeToSzUnit(atoi(buf1)); *c_ptr = saved_ch; } else { curSzUnit = FontSizeToSzUnit(atoi(buf1)); } if (curSzUnit <= 0) { curSzUnit = FontSizeToSzUnit(defaultFontSize); fprintf(stderr, TgLoadString(STID_CANT_SET_INIT_FONTSIZE_ALT), buf1, defaultFontSize); fprintf(stderr, "\n"); } } curUnderlineOn = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"InitialUnderlineOn"))!=NULL && UtilStrICmp(c_ptr, "true") == 0) { curUnderlineOn = TRUE; } curUnderlineYOffset = 2; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "InitialUnderlineAmount")) != NULL) { curUnderlineYOffset = atoi(c_ptr); } curOverlineOn = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"InitialOverlineOn"))!=NULL && UtilStrICmp(c_ptr, "true") == 0) { curOverlineOn = TRUE; } curOverlineYOffset = (-1); if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "InitialOverlineAmount")) != NULL) { curOverlineYOffset = atoi(c_ptr); } changePropertiesOfAttrs = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ChangePropertiesOfAttrs")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { changePropertiesOfAttrs = TRUE; } if (FindFontInfo(curFont, curStyle, curSzUnit, TRUE) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_LOAD_INITIAL_FONT), gszAttemptedFontName, TOOL_NAME, TOOL_NAME, TOOL_NAME); fprintf(stderr, "%s\n", gszMsgBox); } } void SaveCurFont() { gstSavedFontInfo.font = curFont; gstSavedFontInfo.sz_unit = curSzUnit; gstSavedFontInfo.style = curStyle; gstSavedFontInfo.double_byte = canvasFontDoubleByte; gstSavedFontInfo.double_byte_mod_bytes = canvasFontDoubleByteModBytes; gstSavedFontInfo.double_byte_vertical = canvasFontDoubleByteVertical; gstSavedFontInfo.just = textJust; gstSavedFontInfo.pen = penPat; gstSavedFontInfo.fill = objFill; gstSavedFontInfo.trans_pat = transPat; gstSavedFontInfo.v_space = textVSpace; gstSavedFontInfo.underline_on = curUnderlineOn; gstSavedFontInfo.underline_y_offset = curUnderlineYOffset; gstSavedFontInfo.overline_on = curOverlineOn; gstSavedFontInfo.overline_y_offset = curOverlineYOffset; } void RestoreCurFont() { curFont = gstSavedFontInfo.font; curSzUnit = gstSavedFontInfo.sz_unit; curStyle = gstSavedFontInfo.style; canvasFontDoubleByte = gstSavedFontInfo.double_byte; canvasFontDoubleByteModBytes = gstSavedFontInfo.double_byte_mod_bytes; canvasFontDoubleByteVertical = gstSavedFontInfo.double_byte_vertical; textJust = gstSavedFontInfo.just; penPat = gstSavedFontInfo.pen; objFill = gstSavedFontInfo.fill; transPat = gstSavedFontInfo.trans_pat; textVSpace = gstSavedFontInfo.v_space; curUnderlineOn = gstSavedFontInfo.underline_on; curUnderlineYOffset = gstSavedFontInfo.underline_y_offset; curOverlineOn = gstSavedFontInfo.overline_on; curOverlineYOffset = gstSavedFontInfo.overline_y_offset; if (!PRTGIF) SetCanvasFont(); } static struct PushedFontRec *topPushedFontStk=NULL; struct PushedFontRec *GetTopFontStk() { return topPushedFontStk; } struct PushedFontRec *PushCurFont() { struct PushedFontRec *pushed_font_ptr=(struct PushedFontRec *)malloc( sizeof(struct PushedFontRec)); if (pushed_font_ptr == NULL) FailAllocMessage(); memset(pushed_font_ptr, 0, sizeof(struct PushedFontRec)); pushed_font_ptr->next = topPushedFontStk; pushed_font_ptr->font = curFont; pushed_font_ptr->sz_unit = curSzUnit; pushed_font_ptr->style = curStyle; pushed_font_ptr->just = textJust; pushed_font_ptr->pen = penPat; pushed_font_ptr->fill = objFill; pushed_font_ptr->trans_pat = transPat; pushed_font_ptr->v_space = textVSpace; pushed_font_ptr->color = colorIndex; pushed_font_ptr->underline_on = curUnderlineOn; pushed_font_ptr->underline_y_offset = curUnderlineYOffset; pushed_font_ptr->overline_on = curOverlineOn; pushed_font_ptr->overline_y_offset = curOverlineYOffset; pushed_font_ptr->double_byte = canvasFontDoubleByte; pushed_font_ptr->double_byte_mod_bytes = canvasFontDoubleByteModBytes; pushed_font_ptr->double_byte_vertical = canvasFontDoubleByteVertical; topPushedFontStk = pushed_font_ptr; return topPushedFontStk; } void PopCurFont() { struct PushedFontRec *pushed_font_ptr=NULL; if (topPushedFontStk == NULL) { /* debug, do not translate */ FatalUnexpectedError("Empty stack in PopCurFont().", NULL); return; } pushed_font_ptr = topPushedFontStk->next; curFont = topPushedFontStk->font; curSzUnit = topPushedFontStk->sz_unit; curStyle = topPushedFontStk->style; textJust = topPushedFontStk->just; penPat = topPushedFontStk->pen; objFill = topPushedFontStk->fill; transPat = topPushedFontStk->trans_pat; textVSpace = topPushedFontStk->v_space; colorIndex = topPushedFontStk->color; curUnderlineOn = topPushedFontStk->underline_on; curUnderlineYOffset = topPushedFontStk->underline_y_offset; curOverlineOn = topPushedFontStk->overline_on; curOverlineYOffset = topPushedFontStk->overline_y_offset; canvasFontDoubleByte = topPushedFontStk->double_byte; canvasFontDoubleByteModBytes = topPushedFontStk->double_byte_mod_bytes; canvasFontDoubleByteVertical = topPushedFontStk->double_byte_vertical; free(topPushedFontStk); topPushedFontStk = pushed_font_ptr; if (!PRTGIF) SetCanvasFont(); } void SetPushedFontValue(which, value) int which, value; { if (topPushedFontStk == NULL) { if (!editingText) { /* NewCurText() doesn't call PushCurFont() */ return; } /* debug, do not translate */ FatalUnexpectedError("Empty stack in SetPushedFontValue().", NULL); return; } switch(which) { case PUSH_FONT: topPushedFontStk->font = value; break; case PUSH_SZ_UNIT: topPushedFontStk->sz_unit = value; break; case PUSH_STYLE: topPushedFontStk->style = value; break; case PUSH_JUST: topPushedFontStk->just = value; break; case PUSH_PEN: topPushedFontStk->pen = value; break; case PUSH_FILL: topPushedFontStk->fill = value; break; case PUSH_TRANSPAT: topPushedFontStk->trans_pat = value; break; case PUSH_VSPACE: topPushedFontStk->v_space = value; break; case PUSH_COLORINDEX: topPushedFontStk->color = value; break; case PUSH_UNDERLINE_ON: topPushedFontStk->underline_on = value; break; case PUSH_UNDERLINE_Y_OFFSET: topPushedFontStk->underline_y_offset = value; break; case PUSH_OVERLINE_ON: topPushedFontStk->overline_on = value; break; case PUSH_OVERLINE_Y_OFFSET: topPushedFontStk->overline_y_offset = value; break; case PUSH_DOUBLEBYTE: topPushedFontStk->double_byte = value; break; } } static int AdjTransformedTextBBox(ObjPtr) struct ObjRec *ObjPtr; /* a transformed text object has just changed it's font */ /* property, so its bounding box needs to be adjusted */ /* returns FALSE if font size is invalid and the text will be read_only */ /* returns INVALID if font size is invalid and the text will be read_only */ { struct XfrmMtrxRec *ctm=ObjPtr->ctm; if (ctm == NULL) { if (UpdTextBBox(ObjPtr)) { return TRUE; } else { return INVALID; } } ObjPtr->ctm = NULL; if (!UpdTextBBox(ObjPtr)) { ObjPtr->ctm = ctm; return FALSE; } SetCTM(ObjPtr, ctm); UpdTextBBox(ObjPtr); AdjObjSplineVs(ObjPtr); AdjObjBBox(ObjPtr); return TRUE; } static int ChangeStrSegFontProp(pStrSeg, which, value) StrSegInfo *pStrSeg; int which, value; { int changed=FALSE, font=0, style=0, sz_unit=0, double_byte=FALSE; font = pStrSeg->font; style = pStrSeg->style; sz_unit = pStrSeg->sz_unit; switch (which) { case PUSH_STYLE: style = value; if (pStrSeg->style == style) return FALSE; break; case PUSH_SZ_UNIT: sz_unit = value; if (pStrSeg->sz_unit == sz_unit) return FALSE; break; case PUSH_FONT: font = value; if (pStrSeg->font == font) return FALSE; double_byte = IsFontDoubleByte(font); if (pStrSeg->double_byte != double_byte) { return FALSE; } break; case PUSH_UNDERLINE_ON: if (pStrSeg->underline_on == value) return FALSE; pStrSeg->underline_on = value; return TRUE; case PUSH_OVERLINE_ON: if (pStrSeg->overline_on == value) return FALSE; pStrSeg->overline_on = value; return TRUE; } if (FindFontInfo(font, style, sz_unit, TRUE) != NULL) { switch (which) { case PUSH_STYLE: pStrSeg->style = style; break; case PUSH_SZ_UNIT: pStrSeg->sz_unit = sz_unit; break; case PUSH_FONT: pStrSeg->font = font; pStrSeg->double_byte = double_byte; if (double_byte) { pStrSeg->double_byte_vertical = IsDoubleByteFontVertical(font, style); } else { pStrSeg->double_byte_vertical = FALSE; } break; } changed = TRUE; } return changed; } static int ChangeStrBlockFontProp(pStrBlock, which, value) StrBlockInfo *pStrBlock; int which, value; { int changed=FALSE; switch (pStrBlock->type) { case SB_SIMPLE: return ChangeStrSegFontProp(pStrBlock->seg, which, value); break; case SB_CHAR_SPACE: break; case SB_SUPSUB_LEFT: case SB_SUPSUB_CENTER: case SB_SUPSUB_RIGHT: if (pStrBlock->sup != NULL) { if (ChangeMiniLinesFontProp(pStrBlock->sup, which, value)) { changed = TRUE; } } if (pStrBlock->sub != NULL) { if (ChangeMiniLinesFontProp(pStrBlock->sub, which, value)) { changed = TRUE; } } if (pStrBlock->type == SB_SUPSUB_CENTER) { /* pStrBlock->seg better not be NULL or it will crash */ if (ChangeStrSegFontProp(pStrBlock->seg, which, value)) { changed = TRUE; } } break; } return changed; } static int ChangeMiniLineFontProp(pMiniLine, which, value) MiniLineInfo *pMiniLine; int which, value; { int changed=FALSE; StrBlockInfo *pStrBlock=NULL; for (pStrBlock=pMiniLine->first_block; pStrBlock != NULL; pStrBlock=pStrBlock->next) { if (ChangeStrBlockFontProp(pStrBlock, which, value)) { changed = TRUE; } } return changed; } int ChangeMiniLinesFontProp(minilines, which, value) MiniLinesInfo *minilines; int which, value; { int changed=FALSE; MiniLineInfo *pMiniLine=NULL; for (pMiniLine=minilines->first; pMiniLine != NULL; pMiniLine=pMiniLine->next) { if (ChangeMiniLineFontProp(pMiniLine, which, value)) { changed = TRUE; } } return changed; } static int ChangeTextFontProp(text_ptr, which, value) struct TextRec *text_ptr; int which, value; { if (which == PUSH_UNDERLINE_Y_OFFSET) { if (text_ptr->underline_y_offset == value) return FALSE; text_ptr->underline_y_offset = value; return TRUE; } if (which == PUSH_OVERLINE_Y_OFFSET) { if (text_ptr->overline_y_offset == value) return FALSE; text_ptr->overline_y_offset = value; return TRUE; } return ChangeMiniLinesFontProp(&text_ptr->minilines, which, value); } int ChangeObjTextStyle(ObjPtr, StyleIndex) struct ObjRec *ObjPtr; int StyleIndex; { struct ObjRec *obj_ptr; int changed=FALSE, obj_changed; switch (ObjPtr->type) { case OBJ_TEXT: if (ChangeTextFontProp(ObjPtr->detail.t, PUSH_STYLE, StyleIndex)) { InvalidateTextCache(ObjPtr->detail.t); UpdTextBBox(ObjPtr); AdjObjBBox(ObjPtr); changed = TRUE; } break; case OBJ_GROUP: case OBJ_SYM: obj_changed = FALSE; for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjTextStyle(obj_ptr, StyleIndex)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } break; } if (changePropertiesOfAttrs && ObjPtr->type != OBJ_TEXT) { struct AttrRec *attr_ptr=ObjPtr->fattr; obj_changed = FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (ChangeObjTextStyle(attr_ptr->obj, StyleIndex)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } } return changed; } void ChangeFontStyle(StyleIndex) int StyleIndex; { struct SelRec *sel_ptr; int ltx, lty, rbx, rby, changed=FALSE, saved_style=curStyle; if (StyleIndex == INVALID) return; if (topSel == NULL || stickyMenuSelection) { int saved_sz_unit=curSzUnit; if (!(curChoice == DRAWTEXT && textCursorShown)) { TieLooseEnds(); } curStyle = StyleIndex; if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { curSzUnit = GetCurSzUnit(); } allowFontFaceSubstitution = FALSE; SetCanvasFont(); allowFontFaceSubstitution = TRUE; if (canvasFontSize == INVALID) { char buf[MAXSTRING]; GetCurFontMsg(buf, NULL); curStyle = saved_style; if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { curSzUnit = saved_sz_unit; } SetCanvasFont(); sprintf(gszMsgBox, TgLoadString(STID_FONT_NOT_AVAILABLE), buf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (SzUnitToFontSize(curSzUnit) != canvasFontSize) { if (showFontSizeInPoints) { sprintf(gszMsgBox, TgLoadString(STID_CANT_CHANGE_SIZEPT_TO_USE_ALT), SzUnitToPointSize(curSzUnit), SzUnitToPointSize(FontSizeToSzUnit(canvasFontSize))); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_CHANGE_SIZE_TO_USE_ALT), SzUnitToFontSize(curSzUnit), canvasFontSize); } curSzUnit = FontSizeToSzUnit(canvasFontSize); if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { PutCurSzUnit(curSzUnit); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { PutCurSzUnit(curSzUnit); } if (curChoice == DRAWTEXT && textCursorShown) { if (ChangeEditTextProperty(PROP_MASK_TEXT_STYLE, StyleIndex)) { curTextModified = TRUE; UpdCurTextBBox(); RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_STYLE, curStyle); } } } else { textCursorShown = FALSE; } ShowCurFont(); ShowTextSize(); UpdatePinnedMenu(MENU_STYLE); if (topSel == NULL) return; } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjTextStyle(sel_ptr->obj, StyleIndex)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } HighLightForward(); } int ChangeObjTextJust(ObjPtr, JustIndex) struct ObjRec *ObjPtr; int JustIndex; { struct ObjRec *obj_ptr; int changed=FALSE, obj_changed; switch (ObjPtr->type) { case OBJ_TEXT: if (ObjPtr->detail.t->minilines.just != JustIndex) { ObjPtr->detail.t->minilines.just = JustIndex; UpdTextBBox(ObjPtr); if (ObjPtr->detail.t->cached_bitmap != None) { XFreePixmap(mainDisplay,ObjPtr->detail.t->cached_bitmap); } ObjPtr->detail.t->cached_zoom = 0; ObjPtr->detail.t->cached_bitmap = None; AdjObjSplineVs(ObjPtr); changed = TRUE; } break; case OBJ_GROUP: case OBJ_SYM: obj_changed = FALSE; for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjTextJust(obj_ptr, JustIndex)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } break; } if (changePropertiesOfAttrs && ObjPtr->type != OBJ_TEXT) { struct AttrRec *attr_ptr=ObjPtr->fattr; obj_changed = FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (ChangeObjTextJust(attr_ptr->obj, JustIndex)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } } return changed; } void ChangeFontJust(JustIndex) int JustIndex; { struct SelRec *sel_ptr; int ltx, lty, rbx, rby, changed=FALSE; if (JustIndex == INVALID) return; if (topSel == NULL || stickyMenuSelection) { if (!(curChoice == DRAWTEXT && textCursorShown)) { TieLooseEnds(); } textJust = JustIndex; ShowJust(); UpdatePinnedMenu(MENU_STYLE); if (curChoice == DRAWTEXT && textCursorShown) { if (ChangeObjTextJust(curTextObj, JustIndex)) { curTextModified = TRUE; UpdCurTextBBox(); SetFileModified(TRUE); ClearAndRedrawDrawWindow(); if (cycleThroughChoice) { SetPushedFontValue(PUSH_JUST, textJust); } } } else { textCursorShown = FALSE; } if (topSel == NULL) return; } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjTextJust(sel_ptr->obj, JustIndex)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } HighLightForward(); } int ChangeObjTextUnderline(ObjPtr, UnderlineIndex) struct ObjRec *ObjPtr; int UnderlineIndex; { struct ObjRec *obj_ptr; int changed=FALSE, obj_changed=FALSE; switch (ObjPtr->type) { case OBJ_TEXT: if (ChangeTextFontProp(ObjPtr->detail.t, PUSH_UNDERLINE_ON, UnderlineIndex)) { InvalidateTextCache(ObjPtr->detail.t); UpdTextBBox(ObjPtr); AdjObjBBox(ObjPtr); changed = TRUE; } break; case OBJ_GROUP: case OBJ_SYM: obj_changed = FALSE; for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjTextUnderline(obj_ptr, UnderlineIndex)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } break; } if (changePropertiesOfAttrs && ObjPtr->type != OBJ_TEXT) { struct AttrRec *attr_ptr=ObjPtr->fattr; obj_changed = FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (ChangeObjTextUnderline(attr_ptr->obj, UnderlineIndex)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } } return changed; } void ChangeFontUnderline(UnderlineIndex) int UnderlineIndex; { struct SelRec *sel_ptr; int ltx, lty, rbx, rby, changed=FALSE; if (UnderlineIndex == INVALID) return; if (topSel == NULL || stickyMenuSelection) { if (!(curChoice == DRAWTEXT && textCursorShown)) { TieLooseEnds(); } curUnderlineOn = UnderlineIndex; if (curChoice == DRAWTEXT && textCursorShown) { if (ChangeEditTextProperty(PROP_MASK_UNDERLINE_ON, UnderlineIndex)) { curTextModified = TRUE; UpdCurTextBBox(); RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_UNDERLINE_ON, curUnderlineOn); } } } else { textCursorShown = FALSE; } ShowCurFont(); UpdatePinnedMenu(MENU_STYLE); if (topSel == NULL) return; } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjTextUnderline(sel_ptr->obj, UnderlineIndex)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } HighLightForward(); } int ChangeObjTextOverline(ObjPtr, OverlineIndex) struct ObjRec *ObjPtr; int OverlineIndex; { struct ObjRec *obj_ptr; int changed=FALSE, obj_changed=FALSE; switch (ObjPtr->type) { case OBJ_TEXT: if (ChangeTextFontProp(ObjPtr->detail.t, PUSH_OVERLINE_ON, OverlineIndex)) { InvalidateTextCache(ObjPtr->detail.t); UpdTextBBox(ObjPtr); AdjObjBBox(ObjPtr); changed = TRUE; } break; case OBJ_GROUP: case OBJ_SYM: obj_changed = FALSE; for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjTextOverline(obj_ptr, OverlineIndex)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } break; } if (changePropertiesOfAttrs && ObjPtr->type != OBJ_TEXT) { struct AttrRec *attr_ptr=ObjPtr->fattr; obj_changed = FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (ChangeObjTextOverline(attr_ptr->obj, OverlineIndex)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } } return changed; } void ChangeFontOverline(OverlineIndex) int OverlineIndex; { struct SelRec *sel_ptr; int ltx, lty, rbx, rby, changed=FALSE; if (OverlineIndex == INVALID) return; if (topSel == NULL || stickyMenuSelection) { if (!(curChoice == DRAWTEXT && textCursorShown)) { TieLooseEnds(); } curOverlineOn = OverlineIndex; if (curChoice == DRAWTEXT && textCursorShown) { if (ChangeEditTextProperty(PROP_MASK_OVERLINE_ON, OverlineIndex)) { curTextModified = TRUE; UpdCurTextBBox(); RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_OVERLINE_ON, curOverlineOn); } } } else { textCursorShown = FALSE; } ShowCurFont(); UpdatePinnedMenu(MENU_STYLE); if (topSel == NULL) return; } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjTextOverline(sel_ptr->obj, OverlineIndex)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } HighLightForward(); } int RefreshFontStyleMenu(menu) TgMenu *menu; { int i, rc=TRUE, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; if (i < MAXFONTSTYLES) { stMenuItem.checked = (i == curStyle); if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_RADIO, &stMenuItem)) { rc = FALSE; } } else if (i > MAXFONTSTYLES && i < MAXFONTSTYLES+MAXJUSTS+1) { stMenuItem.checked = (i-MAXFONTSTYLES-1 == textJust); if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_RADIO, &stMenuItem)) { rc = FALSE; } } else if (i > MAXFONTSTYLES+MAXJUSTS+1 && i < MAXFONTSTYLES+MAXJUSTS+4) { stMenuItem.checked = (i-MAXFONTSTYLES-MAXJUSTS-2 == curUnderlineOn); if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_RADIO, &stMenuItem)) { rc = FALSE; } } else if (i > MAXFONTSTYLES+MAXJUSTS+4) { stMenuItem.checked = (i-MAXFONTSTYLES-MAXJUSTS-5 == curOverlineOn); if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_RADIO, &stMenuItem)) { rc = FALSE; } } } return rc; } TgMenu *CreateFontStyleMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { menu->track_menubar = TRUE; if (!RefreshFontStyleMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshFontStyleMenu); } return menu; } int StyleMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(fontStyleMenuInfo.create_proc)(NULL, X, Y, &fontStyleMenuInfo, INVALID); activeMenu = MENU_STYLE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } int GetSizeMenuIndex() { int i=0, sz_unit=GetCurSzUnit(); for (i=0; i < numFontSizes; i++) { if (fontSzUnits[i] == sz_unit) { return i; } } return INVALID; } int ChangeObjTextSzUnit(ObjPtr, SzUnit) struct ObjRec *ObjPtr; int SzUnit; { struct ObjRec *obj_ptr; int changed=FALSE, obj_changed; switch (ObjPtr->type) { case OBJ_TEXT: if (ChangeTextFontProp(ObjPtr->detail.t, PUSH_SZ_UNIT, SzUnit)) { InvalidateTextCache(ObjPtr->detail.t); UpdTextBBox(ObjPtr); AdjObjBBox(ObjPtr); changed = TRUE; } break; case OBJ_GROUP: case OBJ_SYM: obj_changed = FALSE; for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjTextSzUnit(obj_ptr, SzUnit)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } break; } if (changePropertiesOfAttrs && ObjPtr->type != OBJ_TEXT) { struct AttrRec *attr_ptr=ObjPtr->fattr; obj_changed = FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (ChangeObjTextSzUnit(attr_ptr->obj, SzUnit)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } } return changed; } void ChangeFontSize(SizeIndex) int SizeIndex; { struct SelRec *sel_ptr; int ltx, lty, rbx, rby; int changed=FALSE; int saved_sz_unit=curSzUnit; if (SizeIndex == INVALID) return; if (topSel == NULL || stickyMenuSelection) { if (!(curChoice == DRAWTEXT && textCursorShown)) { TieLooseEnds(); } curSzUnit = fontSzUnits[SizeIndex]; changingFontSizeFromRead = FALSE; allowFontFaceSubstitution = FALSE; SetCanvasFont(); allowFontFaceSubstitution = TRUE; changingFontSizeFromRead = TRUE; if (canvasFontSize == INVALID) { char buf[MAXSTRING]; GetCurFontMsg(buf, NULL); curSzUnit = saved_sz_unit; SizeIndex = GetSizeMenuIndex(); SetCanvasFont(); sprintf(gszMsgBox, TgLoadString(STID_FONT_NOT_AVAILABLE), buf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (SzUnitToFontSize(curSzUnit) != canvasFontSize) { if (showFontSizeInPoints) { sprintf(gszMsgBox, TgLoadString(STID_CANT_CHANGE_SIZEPT_TO_USE_ALT), SzUnitToPointSize(curSzUnit), SzUnitToPointSize(FontSizeToSzUnit(canvasFontSize))); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_CHANGE_SIZE_TO_USE_ALT), SzUnitToFontSize(curSzUnit), canvasFontSize); } curSzUnit = FontSizeToSzUnit(canvasFontSize); SizeIndex = GetSizeMenuIndex(); if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { PutCurSzUnit(curSzUnit); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { PutCurSzUnit(curSzUnit); } if (curChoice == DRAWTEXT && textCursorShown) { if (ChangeEditTextProperty(PROP_MASK_TEXT_SZ_UNIT, fontSzUnits[SizeIndex])) { curTextModified = TRUE; UpdCurTextBBox(); RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_SZ_UNIT, GetCurSzUnit()); } } } else { textCursorShown = FALSE; } ShowCurFont(); ShowTextSize(); UpdatePinnedMenu(MENU_SIZE); if (topSel == NULL) return; } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjTextSzUnit(sel_ptr->obj, fontSzUnits[SizeIndex])) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } HighLightForward(); } int RefreshFontSizeMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items, sz_unit=GetCurSzUnit(); TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (fontSzUnits[i] == sz_unit); if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_RADIO, &stMenuItem)) { return FALSE; } } return TRUE; } TgMenu *CreateFontSizeMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { int i=0; TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); stMenuInfo.items = (TgMenuItemInfo*)malloc( (numFontSizes+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (numFontSizes+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < numFontSizes; item_info++, i++) { item_info->menu_str = UtilStrDup(sizeMenuStr[i]); if (item_info->menu_str == NULL) FailAllocMessage(); item_info->shortcut_str = NULL; if (showFontSizeInPoints) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_FONT_SIZE_TO_PT), SzUnitToPointSize(fontSzUnits[i])); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_FONT_SIZE_TO), SzUnitToFontSize(fontSzUnits[i])); } item_info->status_str = UtilStrDup(gszMsgBox); if (item_info->status_str == NULL) FailAllocMessage(); item_info->submenu_info = NULL; item_info->cmdid = CMDID_CHANGEALLSELFONTSIZE; } stMenuInfo.items[numFontSizes].cmdid = INVALID; stMenuInfo.type |= TGMUTYPE_CANSCROLL; /* the status_str has been translated in TgLoadCachedString() */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < numFontSizes; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (numFontSizes+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { for (i=0; i < numFontSizes; i++) { menu->menuitems[i].menu_str_allocated = TRUE; } if (!RefreshFontSizeMenu(menu)) { return TgDestroyMenu(menu, TRUE); } for (i=0; i < numFontSizes; i++) { if (TgIsMenuItemRadio(menu, i)) { SetScrollableMenuFirstIndex(menu, i); break; } } menu->refresh_proc = ((RefreshMenuFunc*)RefreshFontSizeMenu); } return menu; } int SizeMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(fontSizeMenuInfo.create_proc)(NULL, X, Y, &fontSizeMenuInfo, INVALID); activeMenu = MENU_SIZE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } int ChangeObjTextFont(ObjPtr, FontIndex) struct ObjRec *ObjPtr; int FontIndex; { struct ObjRec *obj_ptr; int changed=FALSE, obj_changed=FALSE; switch (ObjPtr->type) { case OBJ_TEXT: if (ChangeTextFontProp(ObjPtr->detail.t, PUSH_FONT, FontIndex)) { InvalidateTextCache(ObjPtr->detail.t); UpdTextBBox(ObjPtr); AdjObjBBox(ObjPtr); changed = TRUE; } break; case OBJ_GROUP: case OBJ_SYM: obj_changed = FALSE; for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjTextFont(obj_ptr, FontIndex)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } break; } if (changePropertiesOfAttrs && ObjPtr->type != OBJ_TEXT) { struct AttrRec *attr_ptr=ObjPtr->fattr; obj_changed = FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (ChangeObjTextFont(attr_ptr->obj, FontIndex)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } } return changed; } int ChangeFont(FontIndex, ForceNewChoice) int FontIndex, ForceNewChoice; { struct SelRec *sel_ptr=NULL; int ltx, lty, rbx, rby, changed=FALSE, saved_font=curFont, rc=TRUE; if (FontIndex == INVALID) return FALSE; if (topSel == NULL || stickyMenuSelection || ForceNewChoice) { int saved_sz_unit=curSzUnit; if (!(curChoice == DRAWTEXT && textCursorShown)) { TieLooseEnds(); } curFont = FontIndex; if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { curSzUnit = GetCurSzUnit(); } allowFontFaceSubstitution = FALSE; SetCanvasFont(); allowFontFaceSubstitution = TRUE; if (canvasFontSize == INVALID) { char buf[MAXSTRING]; GetCurFontMsg(buf, NULL); curFont = FontIndex = saved_font; if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { curSzUnit = saved_sz_unit; } SetCanvasFont(); sprintf(gszMsgBox, TgLoadString(STID_FONT_NOT_AVAILABLE), buf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); rc = FALSE; } else if (SzUnitToFontSize(curSzUnit) != canvasFontSize) { if (showFontSizeInPoints) { sprintf(gszMsgBox, TgLoadString(STID_CANT_CHANGE_SIZEPT_TO_USE_ALT), SzUnitToPointSize(curSzUnit), SzUnitToPointSize(FontSizeToSzUnit(canvasFontSize))); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_CHANGE_SIZE_TO_USE_ALT), SzUnitToFontSize(curSzUnit), canvasFontSize); } curSzUnit = FontSizeToSzUnit(canvasFontSize); if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { PutCurSzUnit(curSzUnit); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (curChoice == DRAWTEXT && textCursorShown && editTextSize != 0) { PutCurSzUnit(curSzUnit); } if (curChoice == DRAWTEXT && textCursorShown) { if (ChangeEditTextProperty(PROP_MASK_TEXT_FONT, FontIndex)) { curTextModified = TRUE; UpdCurTextBBox(); RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_FONT, curFont); } } } else { textCursorShown = FALSE; } ShowCurFont(); ShowTextSize(); UpdatePinnedMenu(MENU_FONT); if (topSel == NULL) return rc; } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjTextFont(sel_ptr->obj, FontIndex)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } HighLightForward(); return rc; } int RefreshFontMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == curFont); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_RADIO, &stMenuItem); } return TRUE; } TgMenu *CreateFontMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { int i=0; TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); stMenuInfo.items = (TgMenuItemInfo*)malloc( (numFonts+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (numFonts+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < numFonts; item_info++, i++) { item_info->menu_str = UtilStrDup(fontMenuStr[i]); if (item_info->menu_str == NULL) FailAllocMessage(); item_info->shortcut_str = NULL; sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_FONT_TO), fontMenuStr[i]); item_info->status_str = UtilStrDup(gszMsgBox); if (item_info->status_str == NULL) FailAllocMessage(); item_info->submenu_info = NULL; item_info->cmdid = CMDID_CHANGEALLSELFONT; } stMenuInfo.items[numFonts].cmdid = INVALID; stMenuInfo.type |= TGMUTYPE_CANSCROLL; /* the status_str has been translated in TgLoadCachedString() */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < numFonts; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (numFonts+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; menu_item = (&menu->menuitems[curFont]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_RADIO, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } for (i=0; i < numFonts; i++) { menu->menuitems[i].menu_str_allocated = TRUE; } SetScrollableMenuFirstIndex(menu, curFont); menu->refresh_proc = ((RefreshMenuFunc*)RefreshFontMenu); } return menu; } int FontMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(fontMenuInfo.create_proc)(NULL, X, Y, &fontMenuInfo, INVALID); activeMenu = MENU_FONT; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } int ChangeObjVSpace(ObjPtr, VSpace) struct ObjRec *ObjPtr; int VSpace; { struct ObjRec *obj_ptr; int changed=FALSE, obj_changed; int saved_v_space; switch (ObjPtr->type) { case OBJ_TEXT: if (ObjPtr->detail.t->minilines.v_space != VSpace) { saved_v_space = ObjPtr->detail.t->minilines.v_space; ObjPtr->detail.t->minilines.v_space = VSpace; if (AdjTransformedTextBBox(ObjPtr) == FALSE) { Msg(TgLoadString(STID_INVALID_VSPACE_NOT_CHANGED)); ObjPtr->detail.t->minilines.v_space = saved_v_space; UpdTextBBox(ObjPtr); } else { if (ObjPtr->detail.t->cached_bitmap != None) { XFreePixmap(mainDisplay,ObjPtr->detail.t->cached_bitmap); } ObjPtr->detail.t->cached_zoom = 0; ObjPtr->detail.t->cached_bitmap = None; AdjObjBBox(ObjPtr); changed = TRUE; } } break; case OBJ_GROUP: case OBJ_SYM: obj_changed = FALSE; for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjVSpace(obj_ptr, VSpace)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } break; } if (changePropertiesOfAttrs && ObjPtr->type != OBJ_TEXT) { struct AttrRec *attr_ptr=ObjPtr->fattr; obj_changed = FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (ChangeObjVSpace(attr_ptr->obj, VSpace)) { obj_changed = TRUE; } } if (obj_changed) { changed = TRUE; AdjObjBBox(ObjPtr); } } return changed; } void ChangeVSpace(VSpace) int VSpace; { struct SelRec *sel_ptr; int ltx, lty, rbx, rby, changed=FALSE; if (topSel == NULL || stickyMenuSelection) { if (!(curChoice == DRAWTEXT && textCursorShown)) { TieLooseEnds(); } if (textCursorH+textVSpace <= 0) { Msg(TgLoadString(STID_VSPACE_TOO_SMALL_NOT_CHANGED)); } else { textVSpace = VSpace; SetCanvasFont(); ShowTextVSpace(); } if (curChoice == DRAWTEXT && textCursorShown) { if (ChangeObjVSpace(curTextObj, VSpace)) { curTextModified = TRUE; UpdCurTextBBox(); RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_VSPACE, textVSpace); } } } else { textCursorShown = FALSE; } if (topSel == NULL) return; } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjVSpace(sel_ptr->obj, VSpace)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); } HighLightForward(); } void ChangeAllSelRealSzUnit(sz_unit, HighLight) int sz_unit, HighLight; { struct SelRec *sel_ptr=NULL; int changed=FALSE; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (HighLight) HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjTextSzUnit(sel_ptr->obj, sz_unit)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { int ltx=selLtX, lty=selLtY, rbx=selRbX, rby=selRbY; SetFileModified(TRUE); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } if (HighLight) HighLightForward(); } void SetSelFontSize(pszBuf) char *pszBuf; { char *psz=NULL, spec[MAXSTRING+1], spec_copy[MAXSTRING+1]; int sz_unit=(-1), font_size=(-1), point_size=(-1); if (topSel == NULL) { int size=0; if (pszBuf != NULL && sscanf(pszBuf, "%d", &size) == 1) { int i, sz_unit=FontSizeToSzUnit(size); for (i=0; i<numFontSizes; i++) { if (fontSzUnits[i] == sz_unit) { ChangeFontSize(i); return; } } } else if (curChoice == DRAWTEXT && textCursorShown) { /* will call ChangeEditTextProperty() to handle this */ } else { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } } *spec = '\0'; if (pszBuf != NULL) { UtilStrCpyN(spec, sizeof(spec), pszBuf); } else { if (showFontSizeInPoints) { Dialog(TgLoadString(STID_ENTER_POINT_SIZE), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), spec); } else { Dialog(TgLoadString(STID_ENTER_FONT_SIZE), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), spec); } } UtilTrimBlanks(spec); if (*spec == '\0') return; strcpy(spec_copy, spec); UtilStrUpper(spec_copy); /* do not translate -- program constants */ if ((psz=strstr(spec_copy, "point")) != NULL || (psz=strstr(spec_copy, "pt")) != NULL) { *psz = '\0'; point_size = atoi(spec_copy); sz_unit = PointSizeToSzUnit(point_size); } else if (showFontSizeInPoints) { point_size = atoi(spec); sz_unit = PointSizeToSzUnit(point_size); } else { font_size = atoi(spec); sz_unit = FontSizeToSzUnit(font_size); } if (sz_unit <= 0) { sprintf(gszMsgBox, TgLoadString(STID_FONT_SIZE_TOO_SMALL), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (topSel == NULL && curChoice == DRAWTEXT && textCursorShown) { if (ChangeEditTextProperty(PROP_MASK_TEXT_SZ_UNIT, sz_unit)) { curTextModified = TRUE; UpdCurTextBBox(); RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_SZ_UNIT, GetCurSzUnit()); } } ShowCurFont(); ShowTextSize(); UpdatePinnedMenu(MENU_SIZE); } else { ChangeAllSelRealSzUnit(sz_unit, TRUE); } } void CleanUpFonts() { int i; int fmly_index, style_index; struct FontSizeRec *fs_ptr, *next_fs; CleanUpPSFontCharSubs(); CleanUpDontReencode(); if (vertFontBitmap != None) XFreePixmap(mainDisplay, vertFontBitmap); if (rotatedVertFontBitmap != None) { XFreePixmap(mainDisplay, rotatedVertFontBitmap); } if (rotatedVertFontImage != NULL) XDestroyImage(rotatedVertFontImage); rotatedVertFontImage = NULL; vertFontBitmap = rotatedVertFontBitmap = None; vertFontBitmapW = vertFontBitmapH = 0; if (sizeMenuStr != NULL) { for (i=0; i<numFontSizes; i++) { UtilFree(sizeMenuStr[i]); } free(sizeMenuStr); sizeMenuStr = NULL; } if (fontSzUnits != NULL) { free(fontSzUnits); fontSzUnits = NULL; } numFontSizes = 0; CleanUpPSFontAliases(); CleanUpTmpStrings(); CleanUpEncodeCharFonts(); if (fontFamilies != NULL) { for (fmly_index=0; fmly_index<numFonts; fmly_index++) { for (style_index=0; style_index<MAXFONTSTYLES; style_index++) { if (fontFamilies[fmly_index].fr[style_index].xfs != NULL) { XFreeFont(mainDisplay, fontFamilies[fmly_index].fr[style_index].xfs); } for (fs_ptr=fontFamilies[fmly_index].fr[style_index].next; fs_ptr != NULL; fs_ptr = next_fs) { next_fs = fs_ptr->next; if (fs_ptr->xfs != NULL && !fs_ptr->faked) { XFreeFont(mainDisplay, fs_ptr->xfs); } free(fs_ptr); } } UtilFree(fontFamilies[fmly_index].conv_from_utf8_cmd); UtilFree(fontFamilies[fmly_index].conv_to_utf8_cmd); } for (fmly_index=0; fmly_index<numFakedFonts; fmly_index++) { free(fontFamilies[fmly_index+numFonts].name_faked); } free(fontFamilies); fontFamilies = NULL; } if (fontInfoStr != NULL) { for (i=MAXFONTS*MAXFONTSTYLES*3; i<numFonts*MAXFONTSTYLES*3; i++) { free(fontInfoStr[i]); } free(fontInfoStr); fontInfoStr = NULL; } if (altFontInfoStr) { for (i=0; i<MAXFONTS*MAXFONTSTYLES*3; i++) { if (altFontInfoStr[i] != NULL) { free(altFontInfoStr[i]); } } free(altFontInfoStr); altFontInfoStr = NULL; } if (fontMenuStr != NULL) { for (fmly_index=0; fmly_index<numFonts; fmly_index++) { UtilFree(fontMenuStr[fmly_index]); } free(fontMenuStr); fontMenuStr = NULL; } numFonts = MAXFONTS; numFakedFonts = 0; #ifdef ENABLE_NLS if (menuFontSet != NULL) XFreeFontSet(mainDisplay, menuFontSet); if (msgFontSet != NULL) XFreeFontSet(mainDisplay, msgFontSet); if (boldMsgFontSet != NULL) XFreeFontSet(mainDisplay, boldMsgFontSet); if (italicMsgFontSet != NULL) XFreeFontSet(mainDisplay, italicMsgFontSet); if (boldItalicMsgFontSet != NULL) { XFreeFontSet(mainDisplay, boldItalicMsgFontSet); } #endif /* ENABLE_NLS */ menuFontSet = msgFontSet = boldMsgFontSet = italicMsgFontSet = boldItalicMsgFontSet = NULL; if (menuFontPtr != NULL) XFreeFont(mainDisplay, menuFontPtr); if (msgFontPtr != NULL) XFreeFont(mainDisplay, msgFontPtr); if (boldMsgFontPtr != NULL) XFreeFont(mainDisplay, boldMsgFontPtr); if (italicMsgFontPtr != NULL) XFreeFont(mainDisplay, italicMsgFontPtr); if (boldItalicMsgFontPtr != NULL) { XFreeFont(mainDisplay, boldItalicMsgFontPtr); } menuFontPtr = msgFontPtr = boldMsgFontPtr = italicMsgFontPtr = boldItalicMsgFontPtr = NULL; if (rulerFontName != NULL) free(rulerFontName); if (defaultFontName != NULL) free(defaultFontName); rulerFontName = defaultFontName = NULL; if (menuFontName != NULL) free(menuFontName); if (msgFontName != NULL) free(msgFontName); if (boldMsgFontName != NULL) free(boldMsgFontName); if (italicMsgFontName != NULL) free(italicMsgFontName); if (boldItalicMsgFontName != NULL) free(boldItalicMsgFontName); menuFontName = msgFontName = boldMsgFontName = italicMsgFontName = boldItalicMsgFontName = NULL; if (menuFontSetName != NULL) free(menuFontSetName); if (msgFontSetName != NULL) free(msgFontSetName); if (boldMsgFontSetName != NULL) free(boldMsgFontSetName); if (italicMsgFontSetName != NULL) free(italicMsgFontSetName); if (boldItalicMsgFontSetName != NULL) free(boldItalicMsgFontSetName); menuFontSetName = msgFontSetName = boldMsgFontSetName = italicMsgFontSetName = boldItalicMsgFontSetName = NULL; } void VerifyCompatibleFontIndex(font_index) int *font_index; /* should only call this function if fileVersion <= 29 */ { if (*font_index >= MAXFONTS) *font_index = defaultCurFont; } static void GetFontStr(FontIndex, StyleIndex, FontStr) int FontIndex, StyleIndex; char *FontStr; { char font_str[MAXSTRING]; *font_str = '\0'; GetPSFontStr(FontIndex, StyleIndex, font_str); /* font_str[0] is '/' now */ strcpy(FontStr, &font_str[1]); } void GetCompatibleFontName(old_font_index, style, font_str) int old_font_index, style; char *font_str; { int i; int cSingle=0; int cDouble=0; int cpSingle=INVALID; int cpDouble=INVALID; int old_font_single=(old_font_index % 1000); int old_font_double=((old_font_index / 1000) - 1); int num_fonts=((PRTGIF && !cmdLineOpenDisplay) ? MAXFONTS+numFakedFonts: numFonts+numFakedFonts); for (i=0; i < num_fonts; i++) { if (!IsFontDoubleByte(i)) { if (cSingle == old_font_single) cpSingle = i; cSingle++; } else { if (cDouble == old_font_double) cpDouble = i; cDouble++; } } if (cpSingle != INVALID) { GetFontStr(cpSingle, style, font_str); } else { GetFontStr(defaultCurFont, style, font_str); sprintf(gszMsgBox, TgLoadString(STID_FONT_SUB_NO_SUCH_FONT_USR_DEF), font_str, old_font_single); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } if (cpDouble != INVALID) { strcat(font_str, "%"); GetFontStr(cpDouble, style, font_str+strlen(font_str)); } else if (old_font_double >=0) { sprintf(gszMsgBox, TgLoadString(STID_NO_KANJI_FONT_GIVEN_NUMBER), old_font_double); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } } /* The following procedure is used to generate pdrawFontAsc[] and */ /* pDrawFontDes[], to be used in ``prtgif.c''. It is supposed */ /* to be called within dbx and not tgif. */ /* * static * void GenerateFontInfo() * { * register int i, j, num_rows; * * for (i = 0; i < FONTTABLESIZE; i++) * if (!myFontInfo[i].valid) * { * if ((myFontInfo[i].xfs = * XLoadQueryFont(mainDisplay, fontNameStr[i])) == NULL) * { * printf("Cannot open %s. Abort.\n\n", fontNameStr[i]); * exit(-1); * } * myFontInfo[i].valid = TRUE; * } * * num_rows = FONTTABLESIZE / MAXFONTSIZES; * printf("short\tpDrawFontAsc[] =\n{\n"); * for (i = 0; i < num_rows; i++) * { * printf(" "); * for (j = 0; j < MAXFONTSIZES; j++) * if (i == num_rows-1 && j == MAXFONTSIZES-1) * printf("%2d ", * (myFontInfo[i*MAXFONTSIZES+j].xfs)->max_bounds.ascent); * else * printf("%2d, ", * (myFontInfo[i*MAXFONTSIZES+j].xfs)->max_bounds.ascent); * printf("\n"); * } * printf("};\n\n"); * * printf("short\tpDrawFontDes[] =\n{\n"); * for (i = 0; i < num_rows; i++) * { * printf(" "); * for (j = 0; j < MAXFONTSIZES; j++) * if (i == num_rows-1 && j == MAXFONTSIZES-1) * printf("%2d ", * (myFontInfo[i*MAXFONTSIZES+j].xfs)->max_bounds.descent); * else * printf("%2d, ", * (myFontInfo[i*MAXFONTSIZES+j].xfs)->max_bounds.descent); * printf("\n"); * } * printf("};\n"); * } */ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgtwb5.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000013503�11602233313�014347� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgtwb5.c,v 1.11 2011/05/16 16:22:00 william Exp $ */ #ifndef _NO_TGTWB5 #define _INCLUDE_FROM_TGTWB5_C_ #include "tgifdefs.h" #include "big5.h" #include "tidget.h" #include "auxtext.e" #include "dialog.e" #include "font.e" #include "msg.e" #include "setup.e" #include "strtbl.e" #include "tgtwb5.e" #include "tgtwb5dl.e" #include "tgtwb5xl.e" #include "tidget.e" #include "util.e" #include "xbm/tgtwb5.xbm" /* --------------------- Init & Clean Up --------------------- */ void Tgtwb5_CleanUp(dpy, win) Display *dpy; Window win; { if (gZyfhInfo.initialized) { if (gZyfhInfo.dialogbox_tidgetinfo != NULL) { DestroyTdgtb5DialogBox(dpy, gZyfhInfo.dialogbox_tidgetinfo); } } UtilFree(gZyfhInfo.b5_font_name); if (gZyfhInfo.xfs != NULL) { XFreeFont(mainDisplay, gZyfhInfo.xfs); } if (gZyfhInfo.zyfh_bitmap != None) { XFreePixmap(mainDisplay, gZyfhInfo.zyfh_bitmap); } if (gZyfhInfo.symbol_bitmap != None) { XFreePixmap(mainDisplay, gZyfhInfo.symbol_bitmap); } memset(&gZyfhInfo, 0, sizeof(ZyfhInfo)); CleanUpTdgtb5Dlg(); } static char szDefB5FontName[] = "-taipei-fixed-medium-r-normal--16-150-75-75-c-160-big5-0"; int Tgtwb5_Init(dpy, win, arg) Display *dpy; Window win; char *arg; { memset(&gZyfhInfo, 0, sizeof(ZyfhInfo)); if (arg != NULL) { gZyfhInfo.b5_font_name = UtilStrDup(arg); if (gZyfhInfo.b5_font_name == NULL) FailAllocMessage(); } else { gZyfhInfo.b5_font_name = UtilStrDup(szDefB5FontName); if (gZyfhInfo.b5_font_name == NULL) FailAllocMessage(); } if (strstr(gZyfhInfo.b5_font_name, "-gb2312") != NULL) { gZyfhInfo.b5_font_real_encoding = GB_ENCODING; UtilStrCpyN(gZyfhInfo.im_name, sizeof(gZyfhInfo.im_name), "tgchgb"); } else if (strstr(gZyfhInfo.b5_font_name, "-big5") != NULL) { gZyfhInfo.b5_font_real_encoding = BIG5_ENCODING; UtilStrCpyN(gZyfhInfo.im_name, sizeof(gZyfhInfo.im_name), "tgtwb5"); } else { gZyfhInfo.b5_font_real_encoding = INVALID; sprintf(gszMsgBox, TgLoadString(STID_BAD_ENCODING_TGTWB5_FONT), gZyfhInfo.b5_font_name, TOOL_NAME, "DoubleByteInputMethod"); fprintf(stderr, "%s\n", gszMsgBox); Tgtwb5_CleanUp(dpy, win); return FALSE; } gZyfhInfo.xfs = LoadAFontByName(gZyfhInfo.b5_font_name, TRUE, TRUE); if (gZyfhInfo.xfs == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_LOAD_TGTWB5_FONT), gZyfhInfo.b5_font_name, TOOL_NAME, "DoubleByteInputMethod", gZyfhInfo.im_name); fprintf(stderr, "%s\n", gszMsgBox); Tgtwb5_CleanUp(dpy, win); return FALSE; } gZyfhInfo.b5_font_mod_bytes = ((gZyfhInfo.xfs->min_byte1 & 0x80) == 0); gZyfhInfo.b5_font_w = gZyfhInfo.xfs->max_bounds.rbearing; gZyfhInfo.b5_font_asc = gZyfhInfo.xfs->max_bounds.ascent; gZyfhInfo.b5_font_des = gZyfhInfo.xfs->max_bounds.descent; gZyfhInfo.b5_font_h = gZyfhInfo.b5_font_asc + gZyfhInfo.b5_font_des; gZyfhInfo.zyfh_num_cols = 13; gZyfhInfo.zyfh_num_rows = 4; gZyfhInfo.zyfh_max_symbols = gZyfhInfo.zyfh_num_cols*gZyfhInfo.zyfh_num_rows; gZyfhInfo.zyfh_bitmap_w = tgtwb5_width; gZyfhInfo.zyfh_bitmap_h = tgtwb5_height; gZyfhInfo.zyfh_image_wh = round(((double)tgtwb5_width)/((double)gZyfhInfo.zyfh_num_cols)); gZyfhInfo.zyfh_bitmap = XCreateBitmapFromData(mainDisplay, mainWindow, (char*)tgtwb5_bits, tgtwb5_width, tgtwb5_height); gZyfhInfo.symbol_bitmap = XCreatePixmap(mainDisplay, rootWindow, gZyfhInfo.zyfh_image_wh, gZyfhInfo.zyfh_image_wh, 1); if (!InitTdgtb5Dlg()) { Tgtwb5_CleanUp(dpy, win); return FALSE; } return TRUE; } /* --------------------- Tgtwb5_SendKey --------------------- */ static XComposeStatus c_stat; int Tgtwb5_SendKey(dpy, win, key_ev, buf) Display *dpy; Window win; XKeyEvent *key_ev; char *buf; /* return FALSE means key_ev will be handled without modifications */ { int has_ch=0; char s[80]; KeySym key_sym=(KeySym)0; has_ch = XLookupString(key_ev, s, sizeof(s), &key_sym, &c_stat); TranslateKeys(s, &key_sym); return FALSE; } /* --------------------- Tgtwb5_HandleCntrlSpace --------------------- */ int Tgtwb5_HandleCntrlSpace(dpy, win) Display *dpy; Window win; { if (!gZyfhInfo.initialized) { gZyfhInfo.initialized = TRUE; /* create window */ gZyfhInfo.dialogbox_tidgetinfo = CreateTdgtb5DialogBox(dpy, rootWindow); if (gZyfhInfo.dialogbox_tidgetinfo == NULL) { /* print a message */ } } if (gZyfhInfo.dialogbox_tidgetinfo == NULL) { return FALSE; } if (!gZyfhInfo.mapped) { ShowTdgtb5DialogBox(); Tdgtb5DlgLoop(gZyfhInfo.dialogbox_tidgetinfo); } else { HideTdgtb5DialogBox(); } return FALSE; } /* --------------------- Tgtwb5_HandleCreateText --------------------- */ int Tgtwb5_HandleCreateText(dpy, win) Display *dpy; Window win; { if (gZyfhInfo.initialized && gZyfhInfo.mapped) { HideTdgtb5DialogBox(); } return TRUE; } #endif /* ~_NO_TGTWB5 */ ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Tgif.tmpl-solaris��������������������������������������������������������������������0000644�0000764�0000764�00000005770�11602233313�016237� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-solaris,v 1.17 2011/06/02 17:50:39 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif CC = cc PREPROCESSCMD = cc -E $(STD_CPP_DEFINES) EXTRA_LDOPTIONS = EXTRA_LIBRARIES = -lsocket -lnsl -lgen LDCOMBINEFLAGS = -r XCOMM ----------------------------------------------- XCOMM For gcc-2.7.2, you may need -lbind on solaris (before Solaris 2.7): XCOMM CC = gcc -Wall XCOMM PREPROCESSCMD = gcc -E $(STD_CPP_DEFINES) XCOMM CCOPTIONS = XCOMM EXTRA_LIBRARIES = -lsocket -lnsl -lgen -lbind XCOMM ----------------------------------------------- PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/lib/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_HAS_STREAMS_SUPPORT -D_NO_IDNLIB -D_NO_XUTF8FUNCTIONS MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) SYS_LIBRARIES = -lintl -ldl -lm -lz XCOMM SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM SunOS 5.5 XCOMM XCOMM SunOS 5.6 XCOMM XCOMM SunOS 5.7 XCOMM XCOMM SunOS 5.10 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM ��������tgif-QPL-4.2.5/tdgtbrow.c���������������������������������������������������������������������������0000644�0000764�0000764�00000030670�11602233313�014773� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtbrow.c,v 1.7 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TDGTBROW_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "tidget.h" #include "menu.e" #include "msg.e" #include "raster.e" #include "rect.e" #include "setup.e" #include "tdgtbrow.e" #include "tdgtbtn.e" #include "tidget.e" #include "util.e" static void RedrawTdgtBtnRow ARGS_DECL((TidgetInfo *pti)); static int TdgtBtnRowEventHandler ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo *handling_pti)); static int IsTdgtBtnRowEvent ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo **ppti_handler_tidget_return)); static void DestroyTdgtBtnRow ARGS_DECL((TidgetInfo *pti)); static void MapTdgtBtnRow ARGS_DECL((TidgetInfo *pti)); static void TdgtBtnRowMoveResize ARGS_DECL((TidgetInfo *pti, int x, int y, int w, int h)); static int TdgtBtnRowSendCmd ARGS_DECL((TidgetInfo *pti, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); /* --------------------- Utility Functions --------------------- */ static void GetContentWH(pTdgtBtnRow, pn_content_w, pn_content_h) TdgtBtnRow *pTdgtBtnRow; int *pn_content_w, *pn_content_h; { int w=0, h=0; if (ListLength(&pTdgtBtnRow->pti->tci.clist) > 0) { CVListElem *pElem=NULL; for (pElem=ListFirst(&pTdgtBtnRow->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBtnRow->pti->tci.clist, pElem)) { TidgetInfo *pti=(TidgetInfo*)(pElem->obj); w += pti->tci.win_info.w + pTdgtBtnRow->h_gap; if (pti->tci.win_info.h > h) { h = pti->tci.win_info.h; } } w -= pTdgtBtnRow->h_gap; } if (pn_content_w != NULL) *pn_content_w = w; if (pn_content_h != NULL) *pn_content_h = h; } /* --------------------- RedrawTdgtBtnRow() --------------------- */ static void RedrawTdgtBtnRow(pti) TidgetInfo *pti; { TdgtBtnRow *pTdgtBtnRow=(TdgtBtnRow*)(pti->tidget); CVListElem *pElem=NULL; XClearWindow(mainDisplay, pTdgtBtnRow->pti->tci.win); if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, pTdgtBtnRow->pti->tci.win_info.w, pTdgtBtnRow->pti->tci.win_info.h); switch (pTdgtBtnRow->pti->tci.state) { case TGBS_NORMAL: break; default: TgDrawThreeDButton(mainDisplay, pTdgtBtnRow->pti->tci.win, gTidgetManager.gc, &bbox, pTdgtBtnRow->pti->tci.state, 2, TRUE); TidgetManagerResetGC(); break; } } else { /* * XDrawRectangle(mainDisplay, pTdgtBtnRow->pti->tci.win, * gTidgetManager.gc, 0, 0, pTdgtBtnRow->pti->tci.win_info.w, * pTdgtBtnRow->pti->tci.win_info.h); */ } for (pElem=ListFirst(&pTdgtBtnRow->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBtnRow->pti->tci.clist, pElem)) { TidgetInfo *pti=(TidgetInfo*)(pElem->obj); if (pti != NULL && pti->tidget != NULL) { RedrawTidget(pti); } } } /* --------------------- TdgtBtnRowEventHandler() --------------------- */ static int TdgtBtnRowEventHandler(pti, input, handling_pti) TidgetInfo *pti, *handling_pti; XEvent *input; { TdgtBtnRow *pTdgtBtnRow=(TdgtBtnRow*)(pti->tidget); CVListElem *pElem=NULL; if (pti == handling_pti) { if (input->type == Expose && input->xany.window == pTdgtBtnRow->pti->tci.win) { XEvent ev; RedrawTdgtBtnRow(pTdgtBtnRow->pti); while (XCheckWindowEvent(mainDisplay, pTdgtBtnRow->pti->tci.win, ExposureMask, &ev)) ; } } for (pElem=ListFirst(&pTdgtBtnRow->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBtnRow->pti->tci.clist, pElem)) { TidgetInfo *child_pti=(TidgetInfo*)(pElem->obj); if (TidgetEventHandler(child_pti, input, handling_pti)) { return TRUE; } } return FALSE; } /* --------------------- IsTdgtBtnRowEvent() --------------------- */ static int IsTdgtBtnRowEvent(pti, input, ppti_handler_tidget_return) TidgetInfo *pti, **ppti_handler_tidget_return; XEvent *input; { TdgtBtnRow *pTdgtBtnRow=(TdgtBtnRow*)(pti->tidget); CVListElem *pElem=NULL; if (input->xany.window == pTdgtBtnRow->pti->tci.win) return TRUE; for (pElem=ListFirst(&pTdgtBtnRow->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBtnRow->pti->tci.clist, pElem)) { TidgetInfo *child_pti=(TidgetInfo*)(pElem->obj); if (IsTidgetEvent(child_pti, input, ppti_handler_tidget_return)) { return TRUE; } } return FALSE; } /* --------------------- DestroyTdgtBtnRow() --------------------- */ static void DestroyTdgtBtnRow(pti) TidgetInfo *pti; { TdgtBtnRow *pTdgtBtnRow=(TdgtBtnRow*)(pti->tidget); TdgtBtnRowReset(pTdgtBtnRow); free(pTdgtBtnRow); } /* --------------------- MapTdgtBtnRow() --------------------- */ static void MapTdgtBtnRow(pti) TidgetInfo *pti; { TdgtBtnRow *pTdgtBtnRow=(TdgtBtnRow*)(pti->tidget); CVListElem *pElem=NULL; #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, pTdgtBtnRow->pti->tci.win); XSelectInput(mainDisplay, pTdgtBtnRow->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); #else XSelectInput(mainDisplay, pTdgtBtnRow->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, pTdgtBtnRow->pti->tci.win); #endif for (pElem=ListFirst(&pTdgtBtnRow->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBtnRow->pti->tci.clist, pElem)) { TidgetInfo *pti=(TidgetInfo*)(pElem->obj); if (pti != NULL) { MapTidget(pti); } } } /* --------------------- TdgtBtnRowMoveResize() --------------------- */ static void TdgtBtnRowMoveResize(pti, x, y, w, h) TidgetInfo *pti; int x, y, w, h; { TdgtBtnRow *pTdgtBtnRow=(TdgtBtnRow*)(pti->tidget); /* there should be no need to resize a button */ pTdgtBtnRow->pti->tci.win_info.x = x; pTdgtBtnRow->pti->tci.win_info.y = y; pTdgtBtnRow->pti->tci.win_info.w = w; pTdgtBtnRow->pti->tci.win_info.h = h; XMoveResizeWindow(mainDisplay, pTdgtBtnRow->pti->tci.win, x, y, w, h); if (ListLength(&pTdgtBtnRow->pti->tci.clist) > 0) { int x=0; CVListElem *pElem=NULL; switch (pTdgtBtnRow->just) { case JUST_L: x = windowPadding+pti->tci.h_pad; break; case JUST_C: x = ((w-pTdgtBtnRow->content_w)>>1); break; case JUST_R: x = w-pTdgtBtnRow->content_w-windowPadding-pti->tci.h_pad; break; } for (pElem=ListFirst(&pTdgtBtnRow->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBtnRow->pti->tci.clist, pElem)) { TidgetInfo *pti=(TidgetInfo*)(pElem->obj); TidgetMoveResize(pti, x, pti->tci.win_info.y, pti->tci.win_info.w, pti->tci.win_info.h); x += pti->tci.win_info.w + pTdgtBtnRow->h_gap; } } } /* --------------------- TdgtBtnRowSendCmd() --------------------- */ static int TdgtBtnRowSendCmd(pti, cmd_type, cmd_arg, pv_cmd_userdata) TidgetInfo *pti; int cmd_type, cmd_arg; void *pv_cmd_userdata; { TdgtBtnRow *pTdgtBtnRow=(TdgtBtnRow*)(pti->tidget); if (pTdgtBtnRow != NULL) { } return FALSE; } /* --------------------- TdgtBtnRowReset() --------------------- */ void TdgtBtnRowReset(pTdgtBtnRow) TdgtBtnRow *pTdgtBtnRow; { CVListElem *pElem=NULL; for (pElem=ListFirst(&pTdgtBtnRow->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBtnRow->pti->tci.clist, pElem)) { TidgetInfo *pti=(TidgetInfo*)(pElem->obj); DestroyTidget(&pti); } ListUnlinkAll(&pTdgtBtnRow->pti->tci.clist); CVListInit(&pTdgtBtnRow->pti->tci.clist); } /* --------------------- CreateTdgtBtnRow() --------------------- */ static void TdgtBtnRowCalcGeom(pTdgtBtnRow, pn_content_w, pn_content_h) TdgtBtnRow *pTdgtBtnRow; int *pn_content_w, *pn_content_h; { int btn_w=0, btn_h=0; if (pTdgtBtnRow != NULL) { } CalcTdgtBtnDim("Ok", 8, TDGTBTN_DEF_H_PAD, TDGTBTN_DEF_V_PAD, &btn_w, &btn_h); if (pn_content_w != NULL) *pn_content_w = btn_w; if (pn_content_h != NULL) *pn_content_h = btn_h; } TdgtBtnRow *CreateTdgtBtnRow(parent_win, parent_tidgetinfo, ctl_id, x, y, h_pad, v_pad, state, h_gap, just) Window parent_win; TidgetInfo *parent_tidgetinfo; int ctl_id, x, y, h_pad, v_pad, state, h_gap, just; { int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel), w=0, h=0; int content_w=0, content_h=0; TdgtBtnRow *pTdgtBtnRow=NULL; TdgtBtnRowCalcGeom(NULL, &content_w, &content_h); w = content_w + (windowPadding<<1) + (h_pad<<1); h = content_h + (windowPadding<<1) + (v_pad<<1); pTdgtBtnRow = (TdgtBtnRow*)malloc(sizeof(TdgtBtnRow)); if (pTdgtBtnRow == NULL) FailAllocMessage(); memset(pTdgtBtnRow, 0, sizeof(TdgtBtnRow)); pTdgtBtnRow->pti = NewTidgetInfo(parent_tidgetinfo, TIDGET_TYPE_BROW, pTdgtBtnRow, ctl_id, NULL); if ((pTdgtBtnRow->pti->tci.win=XCreateSimpleWindow(mainDisplay, parent_win, x, y, w, h, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("CreateTdgtBtnRow()", NULL, TRUE); } XSelectInput(mainDisplay, pTdgtBtnRow->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); SetTidgetInfoBasic(pTdgtBtnRow->pti, TIDGET_TYPE_BROW, pTdgtBtnRow, parent_win, x, y, w, h, h_pad, v_pad, state, NULL); TidgetCanHaveChildren(pTdgtBtnRow->pti, TRUE); TidgetSetCallbacks(pTdgtBtnRow->pti, RedrawTdgtBtnRow, TdgtBtnRowEventHandler, IsTdgtBtnRowEvent, DestroyTdgtBtnRow, MapTdgtBtnRow, TdgtBtnRowMoveResize, TdgtBtnRowSendCmd); pTdgtBtnRow->client_area.x = windowPadding + h_pad; pTdgtBtnRow->client_area.y = windowPadding + v_pad; pTdgtBtnRow->client_area.w = w-(windowPadding<<1)-(h_pad<<1); pTdgtBtnRow->client_area.h = h-(windowPadding<<1)-(v_pad<<1); pTdgtBtnRow->content_w = content_w; pTdgtBtnRow->content_h = content_h; pTdgtBtnRow->h_gap = h_gap; pTdgtBtnRow->just = just; return pTdgtBtnRow; } /* --------------------- TdgtBtnRowAddBtn() --------------------- */ int TdgtBtnRowAddBtn(pTdgtBtnRow, pTdgtBtn) TdgtBtnRow *pTdgtBtnRow; TdgtBtn *pTdgtBtn; { int x=0, content_w=0, content_h=0; int this_btn_w=pTdgtBtn->pti->tci.win_info.w; int this_btn_h=pTdgtBtn->pti->tci.win_info.h; GetContentWH(pTdgtBtnRow, &content_w, &content_h); if (this_btn_h > content_h) content_h = this_btn_h; if (content_w != 0) { x = content_w+pTdgtBtnRow->h_gap; } content_w = x+this_btn_w; pTdgtBtnRow->content_w = content_w; pTdgtBtnRow->content_h = content_h; /* * Set the client_area to be as small as possible -- just big enough * to include all the buttons. */ pTdgtBtnRow->client_area.w = content_w; pTdgtBtnRow->client_area.h = content_h; pTdgtBtnRow->pti->tci.win_info.w = content_w + (windowPadding<<1) + ((pTdgtBtnRow->pti->tci.h_pad)<<1); pTdgtBtnRow->pti->tci.win_info.h = content_h + (windowPadding<<1) + ((pTdgtBtnRow->pti->tci.v_pad)<<1); TdgtBtnRowMoveResize(pTdgtBtnRow->pti, pTdgtBtnRow->pti->tci.win_info.x, pTdgtBtnRow->pti->tci.win_info.y, pTdgtBtnRow->pti->tci.win_info.w, pTdgtBtnRow->pti->tci.win_info.h); TdgtBtnRowMoveResize(pTdgtBtn->pti, x+windowPadding+pTdgtBtnRow->pti->tci.h_pad, windowPadding+pTdgtBtnRow->pti->tci.v_pad, this_btn_w, this_btn_h); return ListAppend(&pTdgtBtnRow->pti->tci.clist, pTdgtBtn->pti); } /* --------------------- Init & Clean Up --------------------- */ int InitTdgtBtnRow() { return TRUE; } void CleanUpTdgtBtnRow() { } ������������������������������������������������������������������������tgif-QPL-4.2.5/Tgif.tmpl-os2������������������������������������������������������������������������0000644�0000764�0000764�00000004737�11602233313�015270� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-os2,v 1.11 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_DL_SUPPORT -D_NO_LOCALE_SUPPORT -D_NO_LSTAT \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_NO_RAND48 -D_NO_IDNLIB -D_NO_ZLIB MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(XLIB) XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) SYS_LIBRARIES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM OS/2 4.0 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM ���������������������������������tgif-QPL-4.2.5/tgif_dbg.c���������������������������������������������������������������������������0000644�0000764�0000764�00000033212�11602233313�014677� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgif_dbg.c,v 1.8 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TGIF_DBG_C_ #include <sys/types.h> #include <sys/stat.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <X11/Xlib.h> #include <X11/Xutil.h> #include <X11/cursorfont.h> #include <X11/keysym.h> #ifdef _TGIF_DBG /* debug, do not translate */ #undef _Xconst #define _Xconst static char gszTraceFile[]="TGIF_DBG.LOG"; static FILE *gpTraceFile=NULL; int gnAllocCount=0, gnFreeCount=0; int gnCreateGCCount=0, gnFreeGCCount=0; int gnCreateImageCount=0, gnDestroyImageCount=0; int gnCreateCursorCount=0, gnFreeCursorCount=0; int gnCreatePixmapCount=0, gnFreePixmapCount=0; int gnCreateStringCount=0, gnFreeStringCount=0; void tgif_dbg_add_to_log(pszString) char *pszString; { if (gpTraceFile != NULL) { fprintf(gpTraceFile, "%% %s\n", (pszString==NULL) ? "" : pszString); } } void tgif_dbg_enable(nEnable) int nEnable; { static FILE *st_fp=NULL; if (nEnable) { gpTraceFile = st_fp; } else { st_fp = gpTraceFile; gpTraceFile = NULL; } } /* --------------- utility functions --------------- */ void got_trigger(nOne) int nOne; { if (nOne) { } } void tgif_track(nBegin) int nBegin; { switch (nBegin) { case 2: if (gpTraceFile != NULL && gpTraceFile != stderr) fclose(gpTraceFile); gpTraceFile = stderr; break; case 1: if (gpTraceFile != NULL) fclose(gpTraceFile); gpTraceFile = fopen(gszTraceFile, "w"); if (gpTraceFile == NULL) { fprintf(stderr, "Cannot open '%s' for write.\n", gszTraceFile); } else { fprintf(stderr, "Set gnAllocTrigger for alloc().\n"); fprintf(stderr, "Set gnFreeTrigger for free().\n"); } break; case 0: if (gpTraceFile != NULL) { if (gpTraceFile != stderr) fclose(gpTraceFile); gpTraceFile = NULL; } break; } gnAllocCount = gnFreeCount = 0; gnCreateGCCount = gnFreeGCCount = 0; gnCreateImageCount = gnDestroyImageCount = 0; gnCreateCursorCount = gnFreeCursorCount = 0; gnCreatePixmapCount = gnFreePixmapCount = 0; gnCreateStringCount = gnFreeStringCount = 0; } void tgif_dbg_dump_count(msg) char *msg; { if (gpTraceFile != NULL) { fprintf(gpTraceFile, "%% %s Next gnAllocCount is %1d and next gnFreeCount is %1d\n", msg, gnAllocCount+1, gnFreeCount+1); } } /* --------------- malloc, realloc, free --------------- */ int gnAllocTrigger=0, gnFreeTrigger=0; void *tgif_malloc(nSize) size_t nSize; { char *pVoid=malloc(nSize); if (gpTraceFile != NULL) { if (++gnAllocCount == gnAllocTrigger) { got_trigger(1); } fprintf(gpTraceFile, "a: %6d 0x%08x %d\n", gnAllocCount, (unsigned int)pVoid, (unsigned int)(nSize)); } return (void*)pVoid; } void *tgif_realloc(pVoid, nSize) void *pVoid; size_t nSize; { char *pszVoid; if (gpTraceFile != NULL) { if (++gnFreeCount == gnFreeTrigger) { got_trigger(1); } fprintf(gpTraceFile, "f: %6d 0x%08x\n", gnFreeCount, (unsigned int)pVoid); } pszVoid = realloc(pVoid, nSize); if (gpTraceFile != NULL) { if (++gnAllocCount == gnAllocTrigger) { got_trigger(1); } fprintf(gpTraceFile, "a: %6d 0x%08x %d\n", gnAllocCount, (unsigned int)pszVoid, (unsigned int)(nSize)); } return (void*)pszVoid; } void tgif_free(pVoid) void *pVoid; { if (gpTraceFile != NULL) { if (++gnFreeCount == gnFreeTrigger) { got_trigger(1); } fprintf(gpTraceFile, "f: %6d 0x%08x\n", gnFreeCount, (unsigned int)pVoid); } if (pVoid == NULL) { /* debug, do not translate */ fprintf(stderr, "ERROR: free(NULL) called!\n"); return; } free(pVoid); } size_t tgif_strlen(psz) char *psz; { if (psz == NULL) { /* debug, do not translate */ fprintf(stderr, "ERROR: strlen(NULL) called!\n"); } return strlen(psz); } /* --------------- XCreateGC, XFreeGC --------------- */ int gnCreateGCTrigger=0, gnFreeGCTrigger=0; GC Tgif_XCreateGC(display, d, valuemask, values) Display *display; Drawable d; unsigned long valuemask; XGCValues *values; { GC gc=XCreateGC(display, d, valuemask, values); if (gpTraceFile != NULL) { if (++gnCreateGCCount == gnCreateGCTrigger) { got_trigger(1); } fprintf(gpTraceFile, "g: %6d 0x%08x %ld\n", gnCreateGCCount, (unsigned int)gc, (long)valuemask); } return gc; } void Tgif_XFreeGC(display, gc) Display *display; GC gc; { if (gpTraceFile != NULL) { if (++gnFreeGCCount == gnFreeGCTrigger) { got_trigger(1); } fprintf(gpTraceFile, "h: %6d 0x%08x\n", gnFreeGCCount, (unsigned int)gc); } XFreeGC(display, gc); } /* --------------- XCreateImage, XDestroyImage --------------- */ int gnCreateImageTrigger=0, gnDestroyImageTrigger=0; XImage *Tgif_XCreateImage(display, visual, depth, format, offset, data, width, height, bitmap_pad, bytes_per_line) Display *display; Visual *visual; unsigned int depth; int format; int offset; char *data; unsigned int width; unsigned int height; int bitmap_pad; int bytes_per_line; { XImage *ximage=XCreateImage(display, visual, depth, format, offset, data, width, height, bitmap_pad, bytes_per_line); if (gpTraceFile != NULL) { if (++gnCreateImageCount == gnCreateImageTrigger) { got_trigger(1); } fprintf(gpTraceFile, "i: %6d 0x%08x %d\n", gnCreateImageCount, (unsigned int)ximage, (unsigned int)(width*height)); } return ximage; } XImage *Tgif_XGetImage(display, d, x, y, width, height, plane_mask, format) Display *display; Drawable d; int x; int y; unsigned int width; unsigned int height; unsigned long plane_mask; int format; { XImage *ximage=XGetImage(display, d, x, y, width, height, plane_mask, format); if (gpTraceFile != NULL) { if (++gnCreateImageCount == gnCreateImageTrigger) { got_trigger(1); } fprintf(gpTraceFile, "i: %6d 0x%08x %d\n", gnCreateImageCount, (unsigned int)ximage, (unsigned int)(width*height)); } return ximage; } void Tgif_XDestroyImage(ximage) XImage *ximage; { if (gpTraceFile != NULL) { if (++gnDestroyImageCount == gnDestroyImageTrigger) { got_trigger(1); } fprintf(gpTraceFile, "j: %6d 0x%08x\n", gnDestroyImageCount, (unsigned int)ximage); } (*(ximage->f.destroy_image))(ximage); } /* --------------- XCreateFontCursor, XFreeGC --------------- */ int gnCreateCursorTrigger=0, gnFreeCursorTrigger=0; Cursor Tgif_XCreateFontCursor(display, shape) Display *display; unsigned int shape; { Cursor cursor=XCreateFontCursor(display, shape); if (gpTraceFile != NULL) { if (++gnCreateCursorCount == gnCreateCursorTrigger) { got_trigger(1); } fprintf(gpTraceFile, "c: %6d 0x%08x %d\n", gnCreateCursorCount, (unsigned int)cursor, shape); } return cursor; } Cursor Tgif_XCreatePixmapCursor(display, source, mask, foreground_color, background_color, x, y) Display *display; Pixmap source; Pixmap mask; XColor *foreground_color; XColor *background_color; unsigned int x; unsigned int y; { Cursor cursor=XCreatePixmapCursor(display, source, mask, foreground_color, background_color, x, y); if (gpTraceFile != NULL) { if (++gnCreateCursorCount == gnCreateCursorTrigger) { got_trigger(1); } fprintf(gpTraceFile, "c: %6d 0x%08x %d\n", gnCreateCursorCount, (unsigned int)cursor, (unsigned int)source); } return cursor; } void Tgif_XFreeCursor(display, cursor) Display *display; Cursor cursor; { if (gpTraceFile != NULL) { if (++gnFreeCursorCount == gnFreeCursorTrigger) { got_trigger(1); } fprintf(gpTraceFile, "d: %6d 0x%08x\n", gnFreeCursorCount, (unsigned int)cursor); } XFreeCursor(display, cursor); } /* --------------- XCreatePixmap, XFreeGC --------------- */ int gnCreatePixmapTrigger=0, gnFreePixmapTrigger=0; Pixmap Tgif_XCreatePixmap(display, d, width, height, depth) Display *display; Drawable d; unsigned int width; unsigned int height; unsigned int depth; { Pixmap pixmap=XCreatePixmap(display, d, width, height, depth); if (gpTraceFile != NULL) { if (++gnCreatePixmapCount == gnCreatePixmapTrigger) { got_trigger(1); } fprintf(gpTraceFile, "p: %6d 0x%08x %d\n", gnCreatePixmapCount, (unsigned int)pixmap, width*height*(depth>>3)); } return pixmap; } Pixmap Tgif_XCreateBitmapFromData(display, d, data, width, height) Display *display; Drawable d; _Xconst char *data; unsigned int width; unsigned int height; { Pixmap pixmap=XCreateBitmapFromData(display, d, data, width, height); if (gpTraceFile != NULL) { if (++gnCreatePixmapCount == gnCreatePixmapTrigger) { got_trigger(1); } fprintf(gpTraceFile, "p: %6d 0x%08x %d\n", gnCreatePixmapCount, (unsigned int)pixmap, width*height); } return pixmap; } int Tgif_XReadBitmapFile(display, d, filename, width_return, height_return, bitmap_return, x_hot_return, y_hot_return) Display *display; Drawable d; _Xconst char *filename; unsigned int *width_return; unsigned int *height_return; Pixmap *bitmap_return; int *x_hot_return, *y_hot_return; { int rc=XReadBitmapFile(display, d, filename, width_return, height_return, bitmap_return, x_hot_return, y_hot_return); if (gpTraceFile != NULL) { if (++gnCreatePixmapCount == gnCreatePixmapTrigger) { got_trigger(1); } fprintf(gpTraceFile, "p: %6d 0x%08x %d\n", gnCreatePixmapCount, (bitmap_return==NULL || rc != BitmapSuccess) ? 0 : (unsigned int)(*bitmap_return), (width_return==NULL || height_return==NULL) ? 0 : (int)((*width_return)*(*height_return))); } return rc; } void Tgif_XFreePixmap(display, pixmap) Display *display; Pixmap pixmap; { if (gpTraceFile != NULL) { if (++gnFreePixmapCount == gnFreePixmapTrigger) { got_trigger(1); } fprintf(gpTraceFile, "q: %6d 0x%08x\n", gnFreePixmapCount, (unsigned int)pixmap); } XFreePixmap(display, pixmap); } /* ----------- XFetchBytes, XQueryTree, XGetAtomName, XFreeString ----------- */ int gnCreateStringTrigger=0, gnFreeStringTrigger=0; char *Tgif_XFetchBytes(display, nbytes_return) Display *display; int *nbytes_return; { char *pszString=XFetchBytes(display, nbytes_return); if (gpTraceFile != NULL) { if (++gnCreateStringCount == gnCreateStringTrigger) { got_trigger(1); } fprintf(gpTraceFile, "s: %6d 0x%08x %d\n", gnCreateStringCount, (unsigned int)pszString, nbytes_return == NULL ? 0 : (*nbytes_return)); } return pszString; } Status Tgif_XQueryTree(display, w, root_return, parent_return, children_return, nchildren_return) Display *display; Window w; Window *root_return; Window *parent_return; Window **children_return; unsigned int *nchildren_return; { Status status=XQueryTree(display, w, root_return, parent_return, children_return, nchildren_return); if (gpTraceFile != NULL && children_return != NULL && (*children_return) != NULL) { if (++gnCreateStringCount == gnCreateStringTrigger) { got_trigger(1); } fprintf(gpTraceFile, "s: %6d 0x%08x %d\n", gnCreateStringCount, (unsigned int)(*children_return), (unsigned int)w); } return status; } char *Tgif_XGetAtomName(display, atom) Display *display; Atom atom; { char *pszString=XGetAtomName(display, atom); if (gpTraceFile != NULL) { if (++gnCreateStringCount == gnCreateStringTrigger) { got_trigger(1); } fprintf(gpTraceFile, "s: %6d 0x%08x %d\n", gnCreateStringCount, (unsigned int)pszString, (unsigned int)atom); } return pszString; } Colormap *Tgif_XListInstalledColormaps(display, w, num_return) Display *display; Window w; int *num_return; { Colormap *pColormap=XListInstalledColormaps(display, w, num_return); if (gpTraceFile != NULL) { if (++gnCreateStringCount == gnCreateStringTrigger) { got_trigger(1); } fprintf(gpTraceFile, "s: %6d 0x%08x %d\n", gnCreateStringCount, (unsigned int)pColormap, (unsigned int)sizeof(Colormap*)); } return pColormap; } void Tgif_XFree(pVoid) void *pVoid; { if (gpTraceFile != NULL) { if (++gnFreeStringCount == gnFreeStringTrigger) { got_trigger(1); } fprintf(gpTraceFile, "t: %6d 0x%08x\n", gnFreeStringCount, (unsigned int)pVoid); } XFree(pVoid); } #endif /* _TGIF_DBG */ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/markup.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000002705�11602233312�014435� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/markup.e,v 1.6 2011/05/16 16:21:58 william Exp $ */ #ifndef _TGIF_MARKUP_E_ #define _TGIF_MARKUP_E_ extern int cmdLineParseHtml; #ifdef _INCLUDE_FROM_MARKUP_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_MARKUP_C_*/ extern int ParseMarkUpFile ARGS_DECL((char *buf, int buf_sz, int *pn_html, char *psz_content_type)); extern void CleanUpHtml ARGS_DECL((void)); extern int InitHtml ARGS_DECL((void)); #ifdef _INCLUDE_FROM_MARKUP_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_MARKUP_C_*/ #endif /*_TGIF_MARKUP_E_*/ �����������������������������������������������������������tgif-QPL-4.2.5/drawing.c����������������������������������������������������������������������������0000644�0000764�0000764�00000457670�11602233311�014605� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/drawing.c,v 1.69 2011/06/09 16:11:41 cvsps Exp $ */ #define _INCLUDE_FROM_DRAWING_C_ #include "tgifdefs.h" #include "cmdids.h" #include "align.e" #include "animate.e" #include "arc.e" #include "attr.e" #include "auxtext.e" #include "box.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cutpaste.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "edit.e" #include "eps.e" #include "exec.e" #include "file.e" #include "font.e" #include "grid.e" #include "group.e" #include "help.e" #include "imgproc.e" #include "import.e" #include "inmethod.e" #include "mark.e" #include "mainloop.e" #include "mainmenu.e" #include "menu.e" #include "menuinfo.e" #include "miniline.e" #include "msg.e" #include "navigate.e" #include "names.e" #include "obj.e" #include "oval.e" #include "page.e" #include "pattern.e" #include "pin.e" #include "poly.e" #include "polygon.e" #include "raster.e" #include "rcbox.e" #include "rect.e" #include "remote.e" #include "ruler.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "shape.e" #include "shortcut.e" #include "special.e" #include "stk.e" #include "stream.e" #include "stretch.e" #include "strtbl.e" #include "tangram2.e" #include "tcp.e" #include "text.e" #include "tidget.e" #include "util.e" #include "wb.e" #include "xbitmap.e" #include "xpixmap.e" #define O_VIS 4 #define O_INVIS 4 #define O_GRID (O_VIS+O_INVIS) #define DEF_CHECK_INTERVAL 1 int disableRedraw=FALSE; int intrCheckInterval=DEF_CHECK_INTERVAL; int pasteInDrawTextMode=FALSE; int pasteFromFileInDrawTextMode=FALSE; int pasteCompoundTextInDrawTextMode=FALSE; char pasteFromFileName[MAXPATHLENGTH+1]; int copyInDrawTextMode=FALSE; int copyDoubleByteStringInDrawTextMode=FALSE; int numRedrawBBox=INVALID; int numClipRecs=0; int clipOrdering=Unsorted; XRectangle clipRecs[4]; int checkBBox=TRUE; int btn1Warp=FALSE; int userDisableRedraw=FALSE; int executingCommands=FALSE; int escPressedWhileExecutingCommands=FALSE; int gnDisableShortcuts=FALSE; int enableMouseWheel=TRUE; int btn2PopupMainMenu=FALSE; static Pixmap execAnimatePixmap=None; static int execAnimatePixmapW=0, execAnimatePixmapH=0; static int execAnimatePixmapDataW=0, execAnimatePixmapDataH=0; static Pixmap execAnimateRulerPixmap=None; static int execAnimateRulerPixmapW=0, execAnimateRulerPixmapH=0; static struct BBRec smallArea[2]; static int skipCrossHair=FALSE; void SetXorDrawGC(xor_pixel) int xor_pixel; { XGCValues values; values.foreground = xor_pixel; values.function = GXxor; values.fill_style = FillSolid; #ifdef NO_THIN_LINE values.line_width = 1; #else values.line_width = 0; #endif values.line_style = LineSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCLineWidth | GCLineStyle, &values); } void SetDefaultDrawWinClipRecs() { SetRecVals(clipRecs[0], 0, 0, ZOOMED_SIZE(drawWinW), ZOOMED_SIZE(drawWinH)); numClipRecs = 1; clipOrdering = YXBanded; XSetClipRectangles(mainDisplay, drawGC, 0, 0, clipRecs, numClipRecs, clipOrdering); } void SetDefaultIconWinClipRecs() { SetRecVals(clipRecs[0], 0, 0, iconWindowW, iconWindowH); numClipRecs = 1; clipOrdering = YXBanded; XSetClipRectangles(mainDisplay, drawGC, 0, 0, clipRecs, numClipRecs, clipOrdering); } static void DrawHorizOutline(Win, Y, X1, X2, XStart, XEnd) Window Win; int Y, X1, X2, XStart, XEnd; /* XStart and XEnd are the real place, X1 and X2 are on outline grid */ { register int i; if (XStart-X1 < O_VIS) { XDrawLine(mainDisplay, Win, defaultGC, XStart, Y, X1+O_VIS-1, Y); } for (i=X1+O_GRID; i < X2-O_GRID; i+= O_GRID) { XDrawLine(mainDisplay, Win, defaultGC, i, Y, i+O_VIS-1, Y); } if (X2-XEnd < O_VIS) { XDrawLine(mainDisplay, Win, defaultGC, X2-O_GRID, Y, XEnd, Y); } else { XDrawLine(mainDisplay, Win, defaultGC, X2-O_GRID, Y, X2-O_INVIS-1, Y); } } static void DrawVertOutline(Win, X, Y1, Y2, YStart, YEnd) Window Win; int X, Y1, Y2, YStart, YEnd; /* YStart and YEnd are the real place, Y1 and Y2 are on outline grid */ { register int i; if (YStart-Y1 < O_VIS) { XDrawLine(mainDisplay, Win, defaultGC, X, YStart, X, Y1+O_VIS-1); } for (i=Y1+O_GRID; i < Y2-O_GRID; i+= O_GRID) { XDrawLine(mainDisplay, Win, defaultGC, X, i, X, i+O_VIS-1); } if (Y2-YEnd < O_VIS) { XDrawLine(mainDisplay, Win, defaultGC, X, Y2-O_GRID, X, YEnd); } else { XDrawLine(mainDisplay, Win, defaultGC, X, Y2-O_GRID, X, Y2-O_INVIS-1); } } static void DrawSymOutline(Win, XOff, YOff, ObjPtr) Window Win; int XOff, YOff; struct ObjRec *ObjPtr; { int ltx, lty, rbx, rby, x_start, x_end, y_start, y_end; ltx = ZOOMED_SIZE(ObjPtr->obbox.ltx - XOff - QUARTER_INCH) + 1; lty = ZOOMED_SIZE(ObjPtr->obbox.lty - YOff - QUARTER_INCH) + 1; rbx = ZOOMED_SIZE(ObjPtr->obbox.rbx - XOff + QUARTER_INCH) - 1; rby = ZOOMED_SIZE(ObjPtr->obbox.rby - YOff + QUARTER_INCH) - 1; x_start = (ltx % O_GRID == 0) ? ltx : (int)(ltx / O_GRID) * O_GRID; x_end = (rbx % O_GRID == 0) ? rbx : ((int)(rbx / O_GRID) + 1) * O_GRID; DrawHorizOutline(Win, lty, x_start, x_end, ltx, rbx); DrawHorizOutline(Win, rby, x_start, x_end, ltx, rbx); y_start = (lty % O_GRID == 0) ? lty : (int)(lty / O_GRID) * O_GRID; y_end = (rby % O_GRID == 0) ? rby : ((int)(rby / O_GRID) + 1) * O_GRID; DrawVertOutline(Win, ltx, y_start, y_end, lty, rby); DrawVertOutline(Win, rbx, y_start, y_end, lty, rby); } static int NeedToDraw(ObjBBox) struct BBRec ObjBBox; { switch (numRedrawBBox) { case 0: return (BBoxIntersect(ObjBBox, drawWinBBox)); case 1: return (BBoxIntersect(ObjBBox, drawWinBBox) && BBoxIntersect(ObjBBox, smallArea[0])); case 2: return (BBoxIntersect(ObjBBox, drawWinBBox) && (BBoxIntersect(ObjBBox, smallArea[0]) || BBoxIntersect(ObjBBox, smallArea[1]))); default: fprintf(stderr, "%s\n", TgLoadString(STID_WARN_INVALID_NUMREDRAWBBOX)); break; } return TRUE; } #include "xbm/intr.xbm" #include "xbm/trek.xbm" static int intrShown=FALSE; static int checkCount=0; static int savedCheckInterval=(-1); static int intrIndex=(-1); static long intrTick=0L; static void RedrawInterrupt() { GC gc; XGCValues values; int x=0, y=0, bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); #ifdef _NO_GETTIMEOFDAY struct timeb now; #else /* ~_NO_GETTIMEOFDAY */ struct timeval now; struct timezone zone; #endif /* _NO_GETTIMEOFDAY */ long cur_tick; if (!intrShown) return; #ifdef _NO_GETTIMEOFDAY ftime(&now); cur_tick = ((long)(((long)now.millitm) / 200)) + ((long)(((long)now.time) * 5)); #else /* ~_NO_GETTIMEOFDAY */ gettimeofday(&now, &zone); cur_tick = ((long)(now.tv_usec / 200000)) + ((long)(now.tv_sec * 5)); #endif /* _NO_GETTIMEOFDAY */ if (intrIndex != (-1) && intrTick == cur_tick) return; intrTick = cur_tick; if (++intrIndex == MAXINTRS) intrIndex = 0; x = ((rulerW-intr_width)>>1); y = ((rulerW-intr_height)>>1); values.foreground = myFgPixel; values.background = bg_pixel; values.function = GXcopy; values.fill_style = FillSolid; gc = XCreateGC(mainDisplay, dummyWindow1, GCForeground | GCBackground | GCFunction | GCFillStyle, &values); if (gc != NULL) { if (threeDLook) { XSetForeground(mainDisplay, gc, bg_pixel); XFillRectangle(mainDisplay, dummyWindow1, gc, 0, 0, rulerW, rulerW); } values.foreground = myFgPixel; values.fill_style = FillOpaqueStippled; values.stipple = intrPixmap[intrIndex]; values.ts_x_origin = x; values.ts_y_origin = y; XChangeGC(mainDisplay, gc, GCForeground | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, dummyWindow1, gc, x, y, intr_width, intr_height); XFreeGC(mainDisplay, gc); } XSync(mainDisplay, False); } static void ShowHyperSpace() { GC gc; XGCValues values; int x=0, y=0, bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); x = ((rulerW-1-trek_width)>>1); y = ((rulerW-1-trek_height)>>1); values.foreground = myFgPixel; values.background = bg_pixel; values.function = GXcopy; values.fill_style = FillSolid; gc = XCreateGC(mainDisplay, dummyWindow1, GCForeground | GCBackground | GCFunction | GCFillStyle, &values); if (gc != NULL) { if (threeDLook) { XSetForeground(mainDisplay, gc, bg_pixel); XFillRectangle(mainDisplay, dummyWindow1, gc, 0, 0, rulerW, rulerW); } values.foreground = myFgPixel; values.fill_style = FillOpaqueStippled; values.stipple = trekPixmap; values.ts_x_origin = x; values.ts_y_origin = y; XChangeGC(mainDisplay, gc, GCForeground | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(mainDisplay, dummyWindow1, gc, x, y, trek_width, trek_height); XFreeGC(mainDisplay, gc); } } static int interruptLevel=0; void ShowInterrupt(CheckInterval) int CheckInterval; { if (PRTGIF || interruptLevel++ > 0) return; if (CheckInterval > 0) { savedCheckInterval = intrCheckInterval; intrCheckInterval = CheckInterval; } if (intrCheckInterval <= 0) return; intrShown = TRUE; intrIndex = (-1); RedrawInterrupt(); } int HideInterrupt() { if (PRTGIF || --interruptLevel > 0) return interruptLevel; interruptLevel = 0; if (execAnimatePixmap == None) { XEvent ev; while (XCheckWindowEvent(mainDisplay,dummyWindow1,ButtonPressMask,&ev)) ; } XClearWindow(mainDisplay, dummyWindow1); intrShown = FALSE; checkCount = 0; if (savedCheckInterval > 0) { intrCheckInterval = savedCheckInterval; savedCheckInterval = (-1); } if (inHyperSpace) ShowHyperSpace(); XSync(mainDisplay, False); return 0; } static void HighLightDummyWindow1(highlight) int highlight; { if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, rulerW-1, rulerW-1); if (highlight) { TgDrawThreeDButton(mainDisplay, dummyWindow1, textMenuGC, &bbox, TGBS_RAISED, 1, FALSE); } else { TgClearThreeDButton(mainDisplay, dummyWindow1, textMenuGC, &bbox, 1); } } } void RedrawDummyWindow1() { XEvent ev; if (mainDisplay == NULL) return; while (XCheckWindowEvent(mainDisplay, dummyWindow1, ExposureMask, &ev)) ; while (XCheckWindowEvent(mainDisplay, dummyWindow1, ButtonPressMask, &ev)) ; if (intrShown) { RedrawInterrupt(); } else if (inHyperSpace) { ShowHyperSpace(); } else { HideInterrupt(); } if (intr_bits != NULL && trek_bits != NULL) { } /* do nothing but reference the variable */ } #include "xbm/run.xbm" static void ShowRunning(dpy, win, win_w, win_h) Display *dpy; Window win; int win_w, win_h; { GC gc; XGCValues values; int x=0, y=0, bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); x = ((rulerW-run_width)>>1); y = ((rulerW-run_height)>>1); values.foreground = myFgPixel; values.background = bg_pixel; values.function = GXcopy; values.fill_style = FillSolid; gc = XCreateGC(dpy, win, GCForeground | GCBackground | GCFunction | GCFillStyle, &values); if (gc != NULL) { if (threeDLook) { XSetForeground(dpy, gc, bg_pixel); XFillRectangle(dpy, win, gc, 0, 0, win_w, win_h); } values.foreground = myFgPixel; values.fill_style = FillOpaqueStippled; values.stipple = runBitmap; values.ts_x_origin = x; values.ts_y_origin = y; XChangeGC(dpy, gc, GCForeground | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(dpy, win, gc, 0, 0, run_width, run_height); XFreeGC(dpy, gc); } if (run_bits != NULL) { } /* do nothing but reference the variable */ } void RedrawDummyWindow2() { XEvent ev; if (mainDisplay == NULL) return; XClearWindow(mainDisplay, dummyWindow2); while (XCheckWindowEvent(mainDisplay, dummyWindow2, ExposureMask, &ev)) ; if (gnDisableShortcuts) { ShowRunning(mainDisplay, dummyWindow2, scrollBarW, scrollBarW); } if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, scrollBarW, scrollBarW); TgDrawThreeDButton(mainDisplay, dummyWindow2, textMenuGC, &bbox, gnDisableShortcuts ? TGBS_RAISED : TGBS_LOWRED, 2, TRUE); } } void DummiesEventHandler(input) XEvent *input; { if (input->xany.window == dummyWindow1) { if (input->type == Expose) { RedrawDummyWindow1(); } else if (input->type == EnterNotify) { if (intrShown) { SetMouseStatus(TgLoadCachedString(CSTID_INTERRUPT), TgLoadCachedString(CSTID_INTERRUPT), TgLoadCachedString(CSTID_INTERRUPT)); } else if (inHyperSpace) { SetMouseStatus(TgLoadCachedString(CSTID_LEAVE_HYPERSPACE), TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PARANED_NONE)); } else { SetMouseStatus(TgLoadCachedString(CSTID_ENTER_HYPERSPACE), TgLoadCachedString(CSTID_PARANED_NONE), TgLoadCachedString(CSTID_PARANED_NONE)); } if (inHyperSpace) { HighLightDummyWindow1(TRUE); } } else if (input->type == LeaveNotify) { SetMouseStatus("", "", ""); if (inHyperSpace) { HighLightDummyWindow1(FALSE); } } else if (input->type == ButtonPress) { if (!intrShown && execAnimatePixmap == None) { ToggleHyperSpace(FALSE); if (inHyperSpace) { HighLightDummyWindow1(TRUE); } } else if (intrShown) { HideInterrupt(); } } } else if (input->xany.window == dummyWindow2) { if (input->type == Expose) { RedrawDummyWindow2(); } else if (input->type == EnterNotify) { SetMouseStatusToAllNone(); } } } static XComposeStatus c_stat; int KeyPressEventIsEscape(key_ev) XKeyEvent *key_ev; { KeySym key_sym=(KeySym)0; char buf[80]; int has_ch=XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); TranslateKeys(buf, &key_sym); if (CharIsESC(key_ev, buf, key_sym, &has_ch)) { return TRUE; } return FALSE; } static Bool CheckESC(p_display, p_ev, psz_arg) Display *p_display; XEvent *p_ev; char *psz_arg; { if (p_ev->type == KeyPress) { if (KeyPressEventIsEscape(&p_ev->xkey)) { return True; } } return False; } int ESCPressed() { XEvent ev; if (PRTGIF) return FALSE; if (XCheckIfEvent(mainDisplay, &ev, CheckESC, NULL)) { if (executingCommands) { escPressedWhileExecutingCommands = TRUE; } return TRUE; } if (executingCommands) { return escPressedWhileExecutingCommands; } return FALSE; } int CheckInterrupt(check_esc) int check_esc; { if (PRTGIF) return FALSE; if (execAnimatePixmap == None && intrCheckInterval <= 0) return FALSE; if (check_esc && ESCPressed()) return TRUE; if (++checkCount >= intrCheckInterval) { XEvent ev; RedrawInterrupt(); checkCount = 0; if (check_esc && XCheckWindowEvent(mainDisplay, dummyWindow1, ButtonPressMask, &ev)) { while (XCheckWindowEvent(mainDisplay, dummyWindow1, ButtonPressMask, &ev)) ; return TRUE; } } return FALSE; } void DrawClippedPixmap(pixmap, win, gc, pixmap_w, pixmap_h, ltx, lty) Pixmap pixmap; Window win; GC gc; int pixmap_w, pixmap_h, ltx, lty; { if (numClipRecs <= 0) { XCopyArea(mainDisplay, pixmap, win, gc, 0, 0, pixmap_w, pixmap_h, ltx, lty); } else { int i; struct BBRec pixmap_bbox; pixmap_bbox.ltx = ltx; pixmap_bbox.lty = lty; pixmap_bbox.rbx = ltx+pixmap_w; pixmap_bbox.rby = lty+pixmap_h; for (i=0; i < numClipRecs; i++) { struct BBRec bbox; bbox.ltx = (int)clipRecs[i].x; bbox.lty = (int)clipRecs[i].y; bbox.rbx = bbox.ltx + ((int)clipRecs[i].width); bbox.rby = bbox.lty + ((int)clipRecs[i].height); if (BBoxIntersect(pixmap_bbox, bbox)) { int x, y, w, h; bbox.ltx = max(bbox.ltx, pixmap_bbox.ltx); bbox.lty = max(bbox.lty, pixmap_bbox.lty); bbox.rbx = min(bbox.rbx, pixmap_bbox.rbx); bbox.rby = min(bbox.rby, pixmap_bbox.rby); x = bbox.ltx - pixmap_bbox.ltx; y = bbox.lty - pixmap_bbox.lty; w = bbox.rbx - bbox.ltx; h = bbox.rby - bbox.lty; XCopyArea(mainDisplay, pixmap, win, gc, x, y, w, h, ltx+x, lty+y); } } } } void FillClippedRectangle(win, gc, ltx, lty, orig_w, orig_h) Window win; GC gc; int ltx, lty, orig_w, orig_h; { if (numClipRecs <= 0) { XFillRectangle(mainDisplay, win, gc, ltx, lty, orig_w, orig_h); } else { int i; struct BBRec obj_bbox; obj_bbox.ltx = ltx; obj_bbox.lty = lty; obj_bbox.rbx = ltx+orig_w; obj_bbox.rby = lty+orig_h; for (i=0; i < numClipRecs; i++) { struct BBRec bbox; bbox.ltx = (int)clipRecs[i].x; bbox.lty = (int)clipRecs[i].y; bbox.rbx = bbox.ltx + ((int)clipRecs[i].width); bbox.rby = bbox.lty + ((int)clipRecs[i].height); if (BBoxIntersect(obj_bbox, bbox)) { int x, y, w, h; bbox.ltx = max(bbox.ltx, obj_bbox.ltx); bbox.lty = max(bbox.lty, obj_bbox.lty); bbox.rbx = min(bbox.rbx, obj_bbox.rbx); bbox.rby = min(bbox.rby, obj_bbox.rby); x = bbox.ltx - obj_bbox.ltx; y = bbox.lty - obj_bbox.lty; w = bbox.rbx - bbox.ltx; h = bbox.rby - bbox.lty; XFillRectangle(mainDisplay, win, gc, ltx+x, lty+y, w, h); } } } } int ObjInVisibleLayer(ObjPtr) struct ObjRec *ObjPtr; { struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; if (!colorLayers) return TRUE; switch (ObjPtr->type) { case OBJ_POLY: case OBJ_BOX: case OBJ_OVAL: case OBJ_POLYGON: case OBJ_ARC: case OBJ_RCBOX: case OBJ_XBM: if (colorLayerOn[ObjPtr->color]) { return TRUE; } break; case OBJ_TEXT: if (ObjPtr->detail.t->fill != NONEPAT && colorLayerOn[ObjPtr->color]) { return TRUE; } else { return MiniLinesInVisibleLayer(&ObjPtr->detail.t->minilines); } break; case OBJ_XPM: return TRUE; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = ObjPtr; if (ObjInVisibleLayer(obj_ptr)) { return TRUE; } } break; case OBJ_PIN: obj_ptr = GetPinObj(ObjPtr); obj_ptr->tmp_parent = ObjPtr; if (ObjInVisibleLayer(obj_ptr)) { return TRUE; } break; } for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr = attr_ptr->next) { if (attr_ptr->shown && ObjInVisibleLayer(attr_ptr->obj)) { return TRUE; } } return FALSE; } int DrawObj(Win, ObjPtr) Window Win; register struct ObjRec *ObjPtr; /* returns TRUE if all objects are drawn */ /* returns FALSE if interrupted by the user */ { if (disableRedraw || (placingTopObj && ObjPtr==topObj)) { return TRUE; } switch (ObjPtr->type) { case OBJ_POLY: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DrawPolyObj(Win, drawOrigX, drawOrigY, ObjPtr); DrawAttrs(Win, drawOrigX, drawOrigY, ObjPtr->fattr); } break; case OBJ_BOX: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DrawBoxObj(Win, drawOrigX, drawOrigY, ObjPtr); DrawAttrs(Win, drawOrigX, drawOrigY, ObjPtr->fattr); } break; case OBJ_OVAL: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DrawOvalObj(Win, drawOrigX, drawOrigY, ObjPtr); DrawAttrs(Win, drawOrigX, drawOrigY, ObjPtr->fattr); } break; case OBJ_TEXT: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DrawTextObj(Win, drawOrigX, drawOrigY, ObjPtr); } break; case OBJ_POLYGON: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DrawPolygonObj(Win, drawOrigX, drawOrigY, ObjPtr); DrawAttrs(Win, drawOrigX, drawOrigY, ObjPtr->fattr); } break; case OBJ_ARC: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DrawArcObj(Win, drawOrigX, drawOrigY, ObjPtr); DrawAttrs(Win, drawOrigX, drawOrigY, ObjPtr->fattr); } break; case OBJ_RCBOX: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DrawRCBoxObj(Win, drawOrigX, drawOrigY, ObjPtr); DrawAttrs(Win, drawOrigX, drawOrigY, ObjPtr->fattr); } break; case OBJ_XBM: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DrawXBmObj(Win, drawOrigX, drawOrigY, ObjPtr); DrawAttrs(Win, drawOrigX, drawOrigY, ObjPtr->fattr); } break; case OBJ_XPM: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { DrawXPmObj(Win, drawOrigX, drawOrigY, ObjPtr); DrawAttrs(Win, drawOrigX, drawOrigY, ObjPtr->fattr); } break; case OBJ_SYM: case OBJ_ICON: case OBJ_GROUP: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { struct ObjRec *obj_ptr=ObjPtr->detail.r->last; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { if (!checkBBox || NeedToDraw(obj_ptr->bbox)) { obj_ptr->tmp_parent = ObjPtr; if (!DrawObj(Win, obj_ptr)) return FALSE; if (execAnimatePixmap == None && CheckInterrupt(TRUE)) { SetStringStatus(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); Msg(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); return FALSE; } } } if (ObjPtr->type == OBJ_ICON && ObjPtr->dirty) { struct AttrRec *attr_ptr=ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { UpdTextBBox(attr_ptr->obj); } AdjObjBBox(ObjPtr); UpdSelBBox(); ObjPtr->dirty = FALSE; } DrawAttrs(Win, drawOrigX, drawOrigY, ObjPtr->fattr); if (ObjPtr->type == OBJ_SYM) { DrawSymOutline(Win, drawOrigX, drawOrigY, ObjPtr); } } break; case OBJ_PIN: if (!colorLayers || ObjPtr->tmp_parent!=NULL || ObjInVisibleLayer(ObjPtr)) { struct ObjRec *obj_ptr=GetPinObj(ObjPtr); if (!checkBBox || NeedToDraw(obj_ptr->bbox)) { obj_ptr->tmp_parent = ObjPtr; if (!DrawObj(Win, obj_ptr)) return FALSE; if (execAnimatePixmap == None && CheckInterrupt(TRUE)) { SetStringStatus(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); Msg(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); return FALSE; } } DrawAttrs(Win, drawOrigX, drawOrigY, ObjPtr->fattr); } break; } return TRUE; } void DrawPaperBoundary(Win) Window Win; { register int x_end, y_end; if (mainDisplay == NULL || inSlideShow) return; if (drawOrigX+drawWinW > paperWidth) { x_end = OFFSET_X(paperWidth); if (drawOrigY+drawWinH > paperHeight) { y_end = OFFSET_Y(paperHeight); XDrawLine(mainDisplay, Win, defaultGC, x_end, 0, x_end, y_end); XDrawLine(mainDisplay, Win, defaultGC, 0, y_end, x_end, y_end); } else { XDrawLine(mainDisplay, Win, defaultGC, x_end, 0, x_end, ZOOMED_SIZE(drawWinH)); } } else if (drawOrigY+drawWinH > paperHeight) { y_end = OFFSET_Y(paperHeight); XDrawLine(mainDisplay, Win, defaultGC, 0, y_end, ZOOMED_SIZE(drawWinW), y_end); } } void RedrawAnArea(BotObj, LtX, LtY, RbX, RbY) struct ObjRec *BotObj; int LtX, LtY, RbX, RbY; /* LtX, LtY, RbX, RbY are absolute coordinates */ { register struct ObjRec *obj_ptr; int x=OFFSET_X(LtX), y=OFFSET_Y(LtY), redraw_cross_hair=FALSE; int w=ZOOMED_SIZE(RbX-LtX)+1, h=ZOOMED_SIZE(RbY-LtY)+1; if (mainDisplay == NULL || disableRedraw) return; if (!userDisableRedraw) { smallArea[0].ltx = LtX; smallArea[0].lty = LtY; smallArea[0].rbx = RbX; smallArea[0].rby = RbY; if (!BBoxIntersect(smallArea[0], drawWinBBox)) { return; } SetRecVals(clipRecs[0], OFFSET_X(LtX), OFFSET_Y(LtY), ZOOMED_SIZE(RbX-LtX)+1, ZOOMED_SIZE(RbY-LtY)+1); numClipRecs = 1; clipOrdering = YXBanded; XSetClipRectangles(mainDisplay, drawGC, 0, 0, clipRecs, numClipRecs, clipOrdering); if (execAnimatePixmap != None) { XGCValues values; int real_w=(x+w >= execAnimatePixmapW ? execAnimatePixmapW-x : w); int real_h=(y+h >= execAnimatePixmapH ? execAnimatePixmapH-y : h); if (!skipCrossHair && showCrossHair) { int cx, cy; GetCrossHairPosition(&cx, &cy, NULL); if (cx >= x && cx < x+real_w && cy >= y && cy < y+real_h) { RedrawCrossHair(); redraw_cross_hair = TRUE; } } values.foreground = GetDrawingBgPixel(INVALID, INVALID); values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle, &values); XFillRectangle(mainDisplay, execAnimatePixmap, drawGC, x, y, real_w, real_h); } else { if (!skipCrossHair && showCrossHair) { int cx, cy; GetCrossHairPosition(&cx, &cy, NULL); if (cx >= x && cx < x+w && cy >= y && cy < y+h) { RedrawCrossHair(); redraw_cross_hair = TRUE; } } XClearArea(mainDisplay, drawWindow, x, y, w, h, FALSE); } if ((paperWidth >= LtX && paperWidth <= RbX) || (paperHeight >= LtY && paperHeight <= RbY)) { DrawPaperBoundary(execAnimatePixmap==None ? drawWindow : execAnimatePixmap); } if (execAnimatePixmap != None) { DrawGridLines(execAnimatePixmap, x, y, w, h); DrawPageLines(execAnimatePixmap, x, y, w, h); } else { DrawGridLines(drawWindow, x, y, w, h); DrawPageLines(drawWindow, x, y, w, h); } ShowInterrupt(DEF_CHECK_INTERVAL); } numRedrawBBox = 1; smallArea[0].ltx = LtX; smallArea[0].lty = LtY; smallArea[0].rbx = RbX; smallArea[0].rby = RbY; for (obj_ptr = BotObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (BBoxIntersect(obj_ptr->bbox, drawWinBBox) && BBoxIntersect(obj_ptr->bbox, smallArea[0])) { if (!DrawObj(execAnimatePixmap==None ? drawWindow : execAnimatePixmap, obj_ptr)) { break; } if (execAnimatePixmap == None && CheckInterrupt(TRUE)) { SetStringStatus(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); Msg(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); break; } } } if (!userDisableRedraw) { HideInterrupt(); SetDefaultDrawWinClipRecs(); if (execAnimatePixmap != None && execAnimateRedraw && x < execAnimatePixmapW && y < execAnimatePixmapH) { int real_w=(x+w >= execAnimatePixmapW ? execAnimatePixmapW-x : w); int real_h=(y+h >= execAnimatePixmapH ? execAnimatePixmapH-y : h); XSetFunction(mainDisplay, drawGC, GXcopy); XCopyArea(mainDisplay, execAnimatePixmap, drawWindow, drawGC, x, y, real_w, real_h, x, y); } if (redraw_cross_hair) RedrawCrossHair(); } } void RedrawAreas(BotObj, LtX1, LtY1, RbX1, RbY1, LtX2, LtY2, RbX2, RbY2) struct ObjRec *BotObj; int LtX1, LtY1, RbX1, RbY1, LtX2, LtY2, RbX2, RbY2; /* note: these coordinates are absolute */ { register struct ObjRec *obj_ptr; struct BBRec bbox1, bbox2; int rec1_slot, redraw_cross_hair=FALSE; int x1=OFFSET_X(LtX1), y1=OFFSET_Y(LtY1); int w1=ZOOMED_SIZE(RbX1-LtX1)+1, h1=ZOOMED_SIZE(RbY1-LtY1)+1; int x2=OFFSET_X(LtX2), y2=OFFSET_Y(LtY2); int w2=ZOOMED_SIZE(RbX2-LtX2)+1, h2=ZOOMED_SIZE(RbY2-LtY2)+1; if (mainDisplay == NULL || disableRedraw) return; bbox1.ltx = LtX1; bbox1.lty = LtY1; bbox1.rbx = RbX1; bbox1.rby = RbY1; bbox2.ltx = LtX2; bbox2.lty = LtY2; bbox2.rbx = RbX2; bbox2.rby = RbY2; if (Inside(bbox1, bbox2)) { RedrawAnArea(BotObj, LtX2, LtY2, RbX2, RbY2); return; } else if (Inside(bbox2, bbox1)) { RedrawAnArea(BotObj, LtX1, LtY1, RbX1, RbY1); return; } if (!BBoxIntersect(bbox1, drawWinBBox) && !BBoxIntersect(bbox2, drawWinBBox)) { return; } if (!userDisableRedraw) { if (execAnimatePixmap != None) { XGCValues values; int real_w=(x1+w1 >= execAnimatePixmapW ? execAnimatePixmapW-x1 : w1); int real_h=(y1+h1 >= execAnimatePixmapH ? execAnimatePixmapH-y1 : h1); if (!skipCrossHair && showCrossHair) { int cx, cy; GetCrossHairPosition(&cx, &cy, NULL); if (cx >= x1 && cx < x1+real_w && cy >= y1 && cy < y1+real_h) { RedrawCrossHair(); redraw_cross_hair = TRUE; } } values.foreground = GetDrawingBgPixel(INVALID, INVALID); values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle, &values); XFillRectangle(mainDisplay, execAnimatePixmap, drawGC, x1, y1, real_w, real_h); } else { if (!skipCrossHair && showCrossHair) { int cx, cy; GetCrossHairPosition(&cx, &cy, NULL); if (cx >= x1 && cx < x1+w1 && cy >= y1 && cy < y1+h1) { RedrawCrossHair(); redraw_cross_hair = TRUE; } } XClearArea(mainDisplay, drawWindow, x1, y1, w1, h1, FALSE); } if (BBoxIntersect(bbox1, bbox2)) { int union_ltx, union_lty, union_rbx, union_rby; union_ltx = min(LtX1,LtX2); union_lty = min(LtY1,LtY2); union_rbx = max(RbX1,RbX2); union_rby = max(RbY1,RbY2); skipCrossHair = TRUE; RedrawAnArea(BotObj, union_ltx, union_lty, union_rbx, union_rby); skipCrossHair = FALSE; if (redraw_cross_hair) RedrawCrossHair(); return; } if (LtY1 == LtY2) { rec1_slot = (LtX1 <= LtX2) ? 0 : 1; SetRecVals(clipRecs[rec1_slot], OFFSET_X(LtX1), OFFSET_Y(LtY1), ZOOMED_SIZE(RbX1-LtX1)+1, ZOOMED_SIZE(RbY1-LtY1)+1); SetRecVals(clipRecs[!rec1_slot], OFFSET_X(LtX2), OFFSET_Y(LtY2), ZOOMED_SIZE(RbX2-LtX2)+1, ZOOMED_SIZE(RbY2-LtY2)+1); numClipRecs = 2; } else { if (LtY1 < LtY2) { if (RbY1 <= LtY2) { /* y-extents do not intersect */ SetRecVals(clipRecs[0], OFFSET_X(LtX1), OFFSET_Y(LtY1), ZOOMED_SIZE(RbX1-LtX1)+1, ZOOMED_SIZE(RbY1-LtY1)+1); SetRecVals(clipRecs[1], OFFSET_X(LtX2), OFFSET_Y(LtY2), ZOOMED_SIZE(RbX2-LtX2)+1, ZOOMED_SIZE(RbY2-LtY2)+1); numClipRecs = 2; } else if (RbY1 >= RbY2) { /* box 2's y-extents is inside box 1's y-extents */ /* * Updated on 6/7/2009. The old code below using rec1_slot * did not make sense. * * rec1_slot = (LtX1 < LtX2) ? 0 : 1; */ SetRecVals(clipRecs[0], OFFSET_X(LtX1), OFFSET_Y(LtY1), ZOOMED_SIZE(RbX1-LtX1)+1, ZOOMED_SIZE(RbY1-LtY1)+1); SetRecVals(clipRecs[1], OFFSET_X(LtX2), OFFSET_Y(LtY2), ZOOMED_SIZE(RbX2-LtX2)+1, ZOOMED_SIZE(RbY2-LtY2)+1); numClipRecs = 2; } else { SetRecVals(clipRecs[0], OFFSET_X(LtX1), OFFSET_Y(LtY1), ZOOMED_SIZE(RbX1-LtX1)+1, ZOOMED_SIZE(LtY2-LtY1)+1); if (LtX1 < LtX2) { SetRecVals(clipRecs[1], OFFSET_X(LtX1), OFFSET_Y(LtY2), ZOOMED_SIZE(RbX1-LtX1)+1, ZOOMED_SIZE(RbY1-LtY2)+1); SetRecVals(clipRecs[2], OFFSET_X(LtX2), OFFSET_Y(LtY2), ZOOMED_SIZE(RbX2-LtX2)+1, ZOOMED_SIZE(RbY1-LtY2)+1); } else { SetRecVals(clipRecs[1], OFFSET_X(LtX2), OFFSET_Y(LtY2), ZOOMED_SIZE(RbX2-LtX2)+1, ZOOMED_SIZE(RbY1-LtY2)+1); SetRecVals(clipRecs[2], OFFSET_X(LtX1), OFFSET_Y(LtY2), ZOOMED_SIZE(RbX1-LtX1)+1, ZOOMED_SIZE(RbY1-LtY2)+1); } SetRecVals(clipRecs[3], OFFSET_X(LtX2), OFFSET_Y(RbY1), ZOOMED_SIZE(RbX2-LtX2)+1, ZOOMED_SIZE(RbY2-RbY1)+1); numClipRecs = 4; } } else { if (RbY2 <= LtY1) { /* y-extents do not intersect */ SetRecVals(clipRecs[0], OFFSET_X(LtX2), OFFSET_Y(LtY2), ZOOMED_SIZE(RbX2-LtX2)+1, ZOOMED_SIZE(RbY2-LtY2)+1); SetRecVals(clipRecs[1], OFFSET_X(LtX1), OFFSET_Y(LtY1), ZOOMED_SIZE(RbX1-LtX1)+1, ZOOMED_SIZE(RbY1-LtY1)+1); numClipRecs = 2; } else if (RbY2 >= RbY1) { /* box 1's y-extents is inside box 2's y-extents */ rec1_slot = (LtX1 < LtX2) ? 0 : 1; SetRecVals(clipRecs[rec1_slot], OFFSET_X(LtX1), OFFSET_Y(LtY1), ZOOMED_SIZE(RbX1-LtX1)+1, ZOOMED_SIZE(RbY1-LtY1)+1); SetRecVals(clipRecs[!rec1_slot], OFFSET_X(LtX2), OFFSET_Y(LtY2), ZOOMED_SIZE(RbX2-LtX2)+1, ZOOMED_SIZE(RbY2-LtY2)+1); numClipRecs = 2; } else { SetRecVals(clipRecs[0], OFFSET_X(LtX2), OFFSET_Y(LtY2), ZOOMED_SIZE(RbX2-LtX2)+1, ZOOMED_SIZE(LtY1-LtY2)+1); if (LtX1 < LtX2) { SetRecVals(clipRecs[1], OFFSET_X(LtX1), OFFSET_Y(LtY1), ZOOMED_SIZE(RbX1-LtX1)+1, ZOOMED_SIZE(RbY2-LtY1)+1); SetRecVals(clipRecs[2], OFFSET_X(LtX2), OFFSET_Y(LtY1), ZOOMED_SIZE(RbX2-LtX2)+1, ZOOMED_SIZE(RbY2-LtY1)+1); } else { SetRecVals(clipRecs[1], OFFSET_X(LtX2), OFFSET_Y(LtY1), ZOOMED_SIZE(RbX2-LtX2)+1, ZOOMED_SIZE(RbY2-LtY1)+1); SetRecVals(clipRecs[2], OFFSET_X(LtX1), OFFSET_Y(LtY1), ZOOMED_SIZE(RbX1-LtX1)+1, ZOOMED_SIZE(RbY2-LtY1)+1); } SetRecVals(clipRecs[3], OFFSET_X(LtX1), OFFSET_Y(RbY2), ZOOMED_SIZE(RbX1-LtX1)+1, ZOOMED_SIZE(RbY1-RbY2)+1); numClipRecs = 4; } } } clipOrdering = YXSorted; XSetClipRectangles(mainDisplay, drawGC, 0, 0, clipRecs, numClipRecs, clipOrdering); if ((paperWidth >= LtX1 && paperWidth <= RbX1) || (paperHeight >= LtY1 && paperHeight <= RbY1) || (paperWidth >= LtX2 && paperWidth <= RbX2) || (paperHeight >= LtY2 && paperHeight <= RbY2)) { DrawPaperBoundary(execAnimatePixmap==None ? drawWindow : execAnimatePixmap); } if (execAnimatePixmap != None) { DrawGridLines(execAnimatePixmap, x1, y1, w1, h1); DrawPageLines(execAnimatePixmap, x1, y1, w1, h1); } else { DrawGridLines(drawWindow, x1, y1, w1, h1); DrawPageLines(drawWindow, x1, y1, w1, h1); } ShowInterrupt(DEF_CHECK_INTERVAL); } numRedrawBBox = 2; smallArea[0].ltx = LtX1; smallArea[0].lty = LtY1; smallArea[0].rbx = RbX1; smallArea[0].rby = RbY1; smallArea[1].ltx = LtX2; smallArea[1].lty = LtY2; smallArea[1].rbx = RbX2; smallArea[1].rby = RbY2; for (obj_ptr = BotObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (BBoxIntersect(obj_ptr->bbox, drawWinBBox) && (BBoxIntersect(obj_ptr->bbox, bbox1) || BBoxIntersect(obj_ptr->bbox, bbox2))) { if (!DrawObj(execAnimatePixmap==None ? drawWindow : execAnimatePixmap, obj_ptr)) { break; } if (execAnimatePixmap == None && CheckInterrupt(TRUE)) { SetStringStatus(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); Msg(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); break; } } } if (!userDisableRedraw) { HideInterrupt(); SetDefaultDrawWinClipRecs(); if (execAnimatePixmap != None && execAnimateRedraw) { XSetFunction(mainDisplay, drawGC, GXcopy); if (x1 < execAnimatePixmapW && y1 < execAnimatePixmapH) { int real_w=(x1+w1>=execAnimatePixmapW ? execAnimatePixmapW-x1 : w1); int real_h=(y1+h1>=execAnimatePixmapH ? execAnimatePixmapH-y1 : h1); XCopyArea(mainDisplay, execAnimatePixmap, drawWindow, drawGC, x1, y1, real_w, real_h, x1, y1); } if (x2 < execAnimatePixmapW && y2 < execAnimatePixmapH) { int real_w=(x2+w2>=execAnimatePixmapW ? execAnimatePixmapW-x2 : w2); int real_h=(y2+h2>=execAnimatePixmapH ? execAnimatePixmapH-y2 : h2); XCopyArea(mainDisplay, execAnimatePixmap, drawWindow, drawGC, x2, y2, real_w, real_h, x2, y2); } } if (redraw_cross_hair) RedrawCrossHair(); } } static void GetBetterBBox(ObjPtr, LtX, LtY, RbX, RbY, AlreadyFound) struct ObjRec *ObjPtr; int *LtX, *LtY, *RbX, *RbY, *AlreadyFound; { int found, style=INVALID, w=0, ltx, lty, rbx, rby; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; if (colorLayers && ObjPtr->tmp_parent==NULL && !ObjInVisibleLayer(ObjPtr)) { return; } if (*AlreadyFound && ObjPtr->bbox.ltx >= *LtX && ObjPtr->bbox.lty >= *LtY && ObjPtr->bbox.rbx <= *RbX && ObjPtr->bbox.rby <= *RbY) { return; } switch (ObjPtr->type) { case OBJ_POLY: case OBJ_ARC: switch (ObjPtr->type) { case OBJ_POLY: w = ObjPtr->detail.p->width; style = ObjPtr->detail.p->style; break; case OBJ_ARC: w = ObjPtr->detail.a->width; style = ObjPtr->detail.a->style; break; } if (style==LS_PLAIN && (w & 0x1)) { w = (w-1)>>1; ltx = ObjPtr->obbox.ltx-w; lty = ObjPtr->obbox.lty-w; rbx = ObjPtr->obbox.rbx+w; rby = ObjPtr->obbox.rby+w; } else { ltx = ObjPtr->bbox.ltx; lty = ObjPtr->bbox.lty; rbx = ObjPtr->bbox.rbx; rby = ObjPtr->bbox.rby; } break; case OBJ_BOX: case OBJ_OVAL: case OBJ_POLYGON: case OBJ_RCBOX: switch (ObjPtr->type) { case OBJ_BOX: w = ObjPtr->detail.b->width; break; case OBJ_OVAL: w = ObjPtr->detail.o->width; break; case OBJ_POLYGON: w = ObjPtr->detail.g->width; break; case OBJ_RCBOX: w = ObjPtr->detail.rcb->width; break; } if (w & 0x1) { w = (w-1)>>1; ltx = ObjPtr->obbox.ltx-w; lty = ObjPtr->obbox.lty-w; rbx = ObjPtr->obbox.rbx+w; rby = ObjPtr->obbox.rby+w; } else { ltx = ObjPtr->bbox.ltx; lty = ObjPtr->bbox.lty; rbx = ObjPtr->bbox.rbx; rby = ObjPtr->bbox.rby; } break; case OBJ_TEXT: ltx = ObjPtr->bbox.ltx; lty = ObjPtr->bbox.lty; rbx = ObjPtr->bbox.rbx; rby = ObjPtr->bbox.rby; break; case OBJ_XBM: case OBJ_XPM: ltx = ObjPtr->bbox.ltx; lty = ObjPtr->bbox.lty; rbx = ObjPtr->bbox.rbx-1; rby = ObjPtr->bbox.rby-1; break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: found = FALSE; obj_ptr = ObjPtr->detail.r->last; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = ObjPtr; GetBetterBBox(obj_ptr, <x, <y, &rbx, &rby, &found); } if (!found) { return; } break; case OBJ_PIN: found = FALSE; obj_ptr = GetPinObj(ObjPtr); obj_ptr->tmp_parent = ObjPtr; GetBetterBBox(obj_ptr, <x, <y, &rbx, &rby, &found); if (!found) { return; } break; } for (attr_ptr=ObjPtr->lattr; attr_ptr!=NULL; attr_ptr=attr_ptr->prev) { if (attr_ptr->shown) { if (attr_ptr->obj->bbox.ltx < ltx) ltx = attr_ptr->obj->bbox.ltx; if (attr_ptr->obj->bbox.lty < lty) lty = attr_ptr->obj->bbox.lty; if (attr_ptr->obj->bbox.rbx > rbx) rbx = attr_ptr->obj->bbox.rbx; if (attr_ptr->obj->bbox.rby > rby) rby = attr_ptr->obj->bbox.rby; } } if (ObjPtr->type == OBJ_SYM) { if (ObjPtr->obbox.ltx-QUARTER_INCH < ltx) { ltx = ObjPtr->obbox.ltx - QUARTER_INCH; } if (ObjPtr->obbox.lty-QUARTER_INCH < lty) { lty = ObjPtr->obbox.lty - QUARTER_INCH; } if (ObjPtr->obbox.rbx+QUARTER_INCH > rbx) { rbx = ObjPtr->obbox.rbx + QUARTER_INCH; } if (ObjPtr->obbox.rby+QUARTER_INCH > rby) { rby = ObjPtr->obbox.rby + QUARTER_INCH; } } if (*AlreadyFound) { if (ltx < *LtX) *LtX = ltx; if (lty < *LtY) *LtY = lty; if (rbx > *RbX) *RbX = rbx; if (rby > *RbY) *RbY = rby; } else { *LtX = ltx; *LtY = lty; *RbX = rbx; *RbY = rby; } *AlreadyFound = TRUE; } int RedrawDuringScrolling() { return (scrollingCanvas != INVALID && (execAnimatePixmap != None || smoothScrollingCanvas == JUMP_SCROLLING)); } static void RedrawVertSliceFromCache(start_frac, scroll_all_the_way) double start_frac; int scroll_all_the_way; { int y=0; if (start_frac < 0.0) start_frac = 0.0; if (start_frac > 1.0) start_frac = 1.0; if (scroll_all_the_way) { GetMaxScrollOrigin(NULL, &y); } else { double dv=(double)0; switch (gridSystem) { case ENGLISH_GRID: dv = ((double)paperHeight) * start_frac; break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { dv = ((double)paperHeight) * start_frac; } else { dv = ((double)paperHeight) * start_frac; } break; } y = round(dv); } XCopyArea(mainDisplay, execAnimatePixmap, drawWindow, drawGC, 0, ZOOMED_SIZE(y), initDrawWinW, initDrawWinH, 0, 0); XCopyArea(mainDisplay, execAnimateRulerPixmap, vRuleWindow, defaultGC, 0, ZOOMED_SIZE(y), rulerW-windowPadding, initDrawWinH, 0, 0); } static void RedrawHoriSliceFromCache(start_frac, scroll_all_the_way) double start_frac; int scroll_all_the_way; { int x=0; if (start_frac < 0.0) start_frac = 0.0; if (start_frac > 1.0) start_frac = 1.0; if (scroll_all_the_way) { GetMaxScrollOrigin(&x, NULL); } else { double dv=(double)0; switch (gridSystem) { case ENGLISH_GRID: dv = ((double)paperWidth) * start_frac; break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { dv = ((double)paperWidth) * start_frac; } else { dv = ((double)paperWidth) * start_frac; } break; } x = round(dv); } XCopyArea(mainDisplay, execAnimatePixmap, drawWindow, drawGC, ZOOMED_SIZE(x), 0, initDrawWinW, initDrawWinH, 0, 0); XCopyArea(mainDisplay, execAnimateRulerPixmap, hRuleWindow, defaultGC, ZOOMED_SIZE(x), 0, initDrawWinW, rulerW-windowPadding, 0, 0); } void RedrawAreaFromCache(start_frac, scroll_all_the_way) double start_frac; int scroll_all_the_way; { if (mainDisplay == NULL || disableRedraw) return; if (RedrawDuringScrolling()) { switch (scrollingCanvas) { case SCRL_UP: case SCRL_DN: RedrawVertSliceFromCache(start_frac, scroll_all_the_way); break; case SCRL_LF: case SCRL_RT: RedrawHoriSliceFromCache(start_frac, scroll_all_the_way); break; } } } void RedrawDrawWindow(BotObj) struct ObjRec *BotObj; { register struct ObjRec *obj_ptr; if (mainDisplay == NULL || disableRedraw) return; if (!skipCrossHair) { RedrawCrossHair(); } if (execAnimating) { int already_animating=(execAnimatePixmap!=None), x=0, y=0, w=0, h=0; if (execAnimatePixmap != None) { XFreePixmap(mainDisplay, execAnimatePixmap); } if (execAnimateRulerPixmap != None) { XFreePixmap(mainDisplay, execAnimateRulerPixmap); } execAnimatePixmap = execAnimateRulerPixmap = None; switch (scrollingCanvas) { case SCRL_UP: case SCRL_DN: execAnimatePixmapW = ZOOMED_SIZE(drawWinW); GetMaxScrollOrigin(NULL, &y); execAnimatePixmapDataH = ZOOMED_SIZE(y+drawWinH); h = ZOOMED_SIZE(paperHeight); if ((h % initDrawWinH) == 0) { execAnimatePixmapH = (((int)(h / initDrawWinH))+1)*initDrawWinH; } else { execAnimatePixmapH = (((int)(h / initDrawWinH))+2)*initDrawWinH; } execAnimateRulerPixmapW = rulerW-windowPadding; execAnimateRulerPixmapH = execAnimatePixmapH; break; case SCRL_LF: case SCRL_RT: w = ZOOMED_SIZE(paperWidth); if ((w % initDrawWinW) == 0) { execAnimatePixmapW = (((int)(w / initDrawWinW))+1)*initDrawWinW; } else { execAnimatePixmapW = (((int)(w / initDrawWinW))+2)*initDrawWinW; } GetMaxScrollOrigin(&x, NULL); execAnimatePixmapDataW = ZOOMED_SIZE(x+drawWinW); execAnimatePixmapH = ZOOMED_SIZE(drawWinH); execAnimateRulerPixmapW = execAnimatePixmapW; execAnimateRulerPixmapH = rulerW-windowPadding; break; default: execAnimatePixmapW = ZOOMED_SIZE(drawWinW); execAnimatePixmapH = ZOOMED_SIZE(drawWinH); break; } execAnimatePixmap = XCreatePixmap(mainDisplay, mainWindow, execAnimatePixmapW, execAnimatePixmapH, mainDepth); if (execAnimatePixmap == None) { if (already_animating) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_XPM_NO_ANIM), execAnimatePixmapW, execAnimatePixmapH); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } else { XGCValues values; values.foreground = GetDrawingBgPixel(INVALID, INVALID); values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle, &values); if (scrollingCanvas != INVALID) { int saved_win_w=drawWinW, saved_win_h=drawWinH, abort=FALSE; execAnimateRulerPixmap = XCreatePixmap(mainDisplay, mainWindow, execAnimateRulerPixmapW, execAnimateRulerPixmapH, mainDepth); if (execAnimateRulerPixmap == None) { abort = TRUE; } drawWinW = ABS_SIZE(execAnimatePixmapW); drawWinH = ABS_SIZE(execAnimatePixmapH); SetDefaultDrawWinClipRecs(); XFillRectangle(mainDisplay, execAnimatePixmap, drawGC, 0, 0, execAnimatePixmapW, execAnimatePixmapH); if (execAnimateRulerPixmap != None) { XFillRectangle(mainDisplay, execAnimateRulerPixmap, drawGC, 0, 0, execAnimateRulerPixmapW, execAnimateRulerPixmapH); } drawWinW = saved_win_w; drawWinH = saved_win_h; SetDefaultDrawWinClipRecs(); if (abort) { XFreePixmap(mainDisplay, execAnimatePixmap); execAnimatePixmap = None; } } else { XFillRectangle(mainDisplay, execAnimatePixmap, drawGC, 0, 0, execAnimatePixmapW, execAnimatePixmapH); } } } if (execAnimatePixmap != None && scrollingCanvas != INVALID) { int saved_orig_x=drawOrigX, saved_orig_y=drawOrigY, x=0, y=0; int saved_win_w=drawWinW, saved_win_h=drawWinH, scroll_vertical=FALSE; int watch_cursor=watchCursorOnMainWindow; SaveStatusStrings(); SetStringStatus(TgLoadCachedString(CSTID_CACHING_IMAGE)); if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } switch (scrollingCanvas) { case SCRL_UP: case SCRL_DN: x = 0; y = ZOOMED_SIZE(drawOrigY); drawOrigY = 0; drawWinH = ABS_SIZE(execAnimatePixmapH); scroll_vertical = TRUE; break; case SCRL_LF: case SCRL_RT: x = ZOOMED_SIZE(drawOrigX); y = 0; drawOrigX = 0; drawWinW = ABS_SIZE(execAnimatePixmapW); scroll_vertical = FALSE; break; } UpdDrawWinBBox(); SetDefaultDrawWinClipRecs(); DrawPaperBoundary(execAnimatePixmap); RedrawGridLines(execAnimatePixmap); RedrawPageLines(execAnimatePixmap); if (scroll_vertical) { RedrawVRuler(mainDisplay, execAnimateRulerPixmap); } else { RedrawHRuler(mainDisplay, execAnimateRulerPixmap); } AdjSplineVs(); numRedrawBBox = 0; ShowInterrupt(DEF_CHECK_INTERVAL); for (obj_ptr = BotObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (BBoxIntersect(obj_ptr->bbox, drawWinBBox)) { if (!TgAnyButtonDown(mainDisplay, drawWindow)) { /* canceled */ Msg(TgLoadString(STID_SCROLLING_CANCELED)); break; } if (!DrawObj(execAnimatePixmap, obj_ptr) && CheckInterrupt(TRUE)) { break; } } } HideInterrupt(); XSetFunction(mainDisplay, drawGC, GXcopy); XCopyArea(mainDisplay, execAnimatePixmap, drawWindow, drawGC, x, y, initDrawWinW, initDrawWinH, 0, 0); drawOrigX = saved_orig_x; drawOrigY = saved_orig_y; drawWinW = saved_win_w; drawWinH = saved_win_h; UpdDrawWinBBox(); SetDefaultDrawWinClipRecs(); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } RestoreStatusStrings(); } else { DrawPaperBoundary(execAnimatePixmap==None ? drawWindow : execAnimatePixmap); RedrawGridLines(execAnimatePixmap==None ? drawWindow : execAnimatePixmap); RedrawPageLines(execAnimatePixmap==None ? drawWindow : execAnimatePixmap); numRedrawBBox = 0; ShowInterrupt(DEF_CHECK_INTERVAL); for (obj_ptr = BotObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (BBoxIntersect(obj_ptr->bbox, drawWinBBox)) { if (!DrawObj(execAnimatePixmap==None ? drawWindow : execAnimatePixmap, obj_ptr)) { break; } if (execAnimatePixmap == None && CheckInterrupt(TRUE)) { SetStringStatus(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); Msg(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); break; } } } HideInterrupt(); if (execAnimatePixmap != None) { XSetFunction(mainDisplay, drawGC, GXcopy); XCopyArea(mainDisplay, execAnimatePixmap, drawWindow, drawGC, 0, 0, execAnimatePixmapW, execAnimatePixmapH, 0, 0); } if (!skipCrossHair) { RedrawCrossHair(); } } } Pixmap DrawAllOnPixmap(LtX, LtY, W, H, nRedraw) int *LtX, *LtY, *W, *H, nRedraw; { register struct ObjRec *obj_ptr; int ltx, lty, rbx, rby, w, h, saved_zoom_scale, saved_zoomed_in, found=FALSE; int saved_draw_orig_x, saved_draw_orig_y, saved_draw_win_w, saved_draw_win_h; Pixmap pixmap; XGCValues values; ltx = lty = rbx = rby = 0; for (obj_ptr = botObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->tmp_parent = NULL; GetBetterBBox(obj_ptr, <x, <y, &rbx, &rby, &found); } if (!found) { *LtX = *LtY = *W = *H = 0; sprintf(gszMsgBox, "No objects to print!"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return None; } *W = w = rbx - ltx + 1; *H = h = rby - lty + 1; *LtX = ltx; *LtY = lty; saved_draw_orig_x = drawOrigX; saved_draw_orig_y = drawOrigY; saved_draw_win_w = drawWinW; saved_draw_win_h = drawWinH; saved_zoom_scale = zoomScale; saved_zoomed_in = zoomedIn; drawOrigX = ltx; drawOrigY = lty; drawWinW = w; drawWinH = h; zoomScale = 0; zoomedIn = FALSE; SetDefaultDrawWinClipRecs(); pixmap = XCreatePixmap(mainDisplay, mainWindow, w, h, mainDepth); if (pixmap == None) { FailAllocPixmapMessage(w, h); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), w, h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return None; } values.foreground = GetDrawingBgPixel(INVALID, INVALID); values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle, &values); XFillRectangle(mainDisplay, pixmap, drawGC, 0, 0, w, h); AdjCaches(); AdjSplineVs(); checkBBox = FALSE; ShowInterrupt(DEF_CHECK_INTERVAL); for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_parent = NULL; if (!DrawObj(pixmap, obj_ptr)) { XFreePixmap(mainDisplay, pixmap); pixmap = None; break; } if (execAnimatePixmap == None && CheckInterrupt(TRUE)) { SetStringStatus(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); Msg(TgLoadString(STID_USER_INTR_ABORT_REPAINT)); XFreePixmap(mainDisplay, pixmap); pixmap = None; break; } } HideInterrupt(); checkBBox = TRUE; drawOrigX = saved_draw_orig_x; drawOrigY = saved_draw_orig_y; drawWinW = saved_draw_win_w; drawWinH = saved_draw_win_h; zoomedIn = saved_zoomed_in; zoomScale = saved_zoom_scale; AdjSplineVs(); AdjCaches(); SetDefaultDrawWinClipRecs(); skipCrossHair = TRUE; if (nRedraw) RedrawDrawWindow(botObj); skipCrossHair = FALSE; if (gpExportClipBBox != NULL) { int y, intersect_w=0, intersect_h=0; int src_offset_x=0, src_offset_y=0, dest_offset_x=0, dest_offset_y=0; int dest_w=gpExportClipBBox->rbx-gpExportClipBBox->ltx; int dest_h=gpExportClipBBox->rby-gpExportClipBBox->lty; Pixmap dest_pixmap=XCreatePixmap(mainDisplay, mainWindow, dest_w, dest_h, mainDepth); XImage *src_image=NULL, *dest_image=NULL; struct BBRec src_bbox, intersect_bbox; if (dest_pixmap == None) FailAllocBitmapMessage(dest_w, dest_h); XSetForeground(mainDisplay, drawGC, GetDrawingBgPixel(INVALID, INVALID)); XFillRectangle(mainDisplay, dest_pixmap, drawGC, 0, 0, dest_w, dest_h); SetBBRec(&src_bbox, (*LtX), (*LtY), (*LtX)+(*W), (*LtY)+(*H)); if (!IntersectRect(src_bbox, *gpExportClipBBox, &intersect_bbox)) { XFreePixmap(mainDisplay, pixmap); return dest_pixmap; } dest_image = XGetImage(mainDisplay, dest_pixmap, 0, 0, dest_w, dest_h, AllPlanes, ZPixmap); if (dest_image == NULL) FailAllocMessage(); src_image = XGetImage(mainDisplay, pixmap, 0, 0, (*W), (*H), AllPlanes, ZPixmap); if (src_image == NULL) FailAllocMessage(); intersect_w = intersect_bbox.rbx-intersect_bbox.ltx; intersect_h = intersect_bbox.rby-intersect_bbox.lty; src_offset_x = intersect_bbox.ltx-src_bbox.ltx; src_offset_y = intersect_bbox.lty-src_bbox.lty; dest_offset_x = intersect_bbox.ltx-gpExportClipBBox->ltx; dest_offset_y = intersect_bbox.lty-gpExportClipBBox->lty; for (y=0; y < intersect_h; y++) { int x; for (x=0; x < intersect_w; x++) { XPutPixel(dest_image, x+dest_offset_x, y+dest_offset_y, XGetPixel(src_image, x+src_offset_x, y+src_offset_y)); } } XPutImage(mainDisplay, dest_pixmap, xpmGC, dest_image, 0, 0, 0, 0, dest_w, dest_h); XDestroyImage(dest_image); XDestroyImage(src_image); XFreePixmap(mainDisplay, pixmap); *LtX = gpExportClipBBox->ltx; *LtY = gpExportClipBBox->lty; *W = gpExportClipBBox->rbx-(*LtX); *H = gpExportClipBBox->rby-(*LtY); return dest_pixmap; } return pixmap; } void ClearAndRedrawDrawWindow() { if (mainDisplay == NULL || disableRedraw) return; XClearWindow(mainDisplay, drawWindow); if (execAnimatePixmap != None) { XGCValues values; values.foreground = GetDrawingBgPixel(INVALID, INVALID); values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle, &values); XFillRectangle(mainDisplay, execAnimatePixmap, drawGC, 0, 0, execAnimatePixmapW, execAnimatePixmapH); } somethingHighLighted = FALSE; skipCrossHair = TRUE; RedrawDrawWindow(botObj); skipCrossHair = FALSE; ResetDirtyBBoxInfo(); RedrawCurText(); if (!execAnimating) HighLightForward(); RedrawCrossHair(); } void ClearAndRedrawDrawWindowNoCurT() /* use to be ClearAndRedrawDrawWindowDontDrawCurText() */ { if (mainDisplay == NULL || disableRedraw) return; XClearWindow(mainDisplay, drawWindow); if (execAnimatePixmap != None) { XGCValues values; values.foreground = GetDrawingBgPixel(INVALID, INVALID); values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle, &values); XFillRectangle(mainDisplay, execAnimatePixmap, drawGC, 0, 0, execAnimatePixmapW, execAnimatePixmapH); } somethingHighLighted = FALSE; skipCrossHair = TRUE; RedrawDrawWindow(botObj); skipCrossHair = FALSE; HighLightForward(); RedrawCrossHair(); } int BeginExecAnimate() { execAnimating = TRUE; execAnimateRedraw = TRUE; RedrawDrawWindow(botObj); if (execAnimatePixmap == None) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_ALLOC_PIXMAP_OF_SIZE), execAnimatePixmapW, execAnimatePixmapH); if (scrollingCanvas == INVALID) { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { SetStringStatus(gszMsgBox); } execAnimatePixmapW = execAnimatePixmapH = 0; execAnimating = execAnimateRedraw = FALSE; return FALSE; } return TRUE; } void EndExecAnimate() { if (execAnimatePixmap != None) { XFreePixmap(mainDisplay, execAnimatePixmap); } if (execAnimateRulerPixmap != None) { XFreePixmap(mainDisplay, execAnimateRulerPixmap); } execAnimatePixmap = execAnimateRulerPixmap = None; execAnimatePixmapW = execAnimatePixmapH = 0; execAnimatePixmapDataW = execAnimatePixmapDataH = 0; execAnimating = execAnimateRedraw = FALSE; } void CleanUpDrawingWindow() { FreeEditAttrInfo(gpEditAttrInEditorAttrInfo); gpEditAttrInEditorAttrInfo = NULL; if (execAnimatePixmap != None) { Msg(TgLoadString(STID_FORCING_END_ANIMATE)); EndExecAnimate(); } SetCurChoice(NOTHING); if (topSel != NULL) { if (!deserializingFile) HighLightReverse(); RemoveAllSel(); } if (tgifObj != NULL && tgifObj->fattr != NULL) { DelAllAttrs(tgifObj->fattr); tgifObj->fattr = tgifObj->lattr = NULL; } DelAllPages(); ResetRotatePivotValidInfo(); } static long GetElapseTime(long start_sec, long start_msec, long end_sec, long end_msec) { long diff_sec=end_sec-start_sec; long diff_msec=end_msec-start_msec; if (diff_msec < 0) { diff_sec--; diff_msec += 1000; } return ((diff_sec*1000)+diff_msec); } static void BenchMark() { static int count=0; int need_to_check_auto_exec=FALSE, i=0; while (XPending(mainDisplay)) { i++; TryProcessAnXEvent(&need_to_check_auto_exec); } /* debug, do not translate */ fprintf(stderr, "%1d BenchMark Ready (%1d events processed)!\n", count, i); if (count++ < 3) { SendCommandToSelf(CMDID_BENCHMARK, INVALID); } else { long start_sec=0L, start_msec=0L, end_sec=0L, end_msec=0L; long elapsed_msec=0L; int x=0, y=0, z=0, w=64, x_end=(min(drawWinW,drawWinH)-64), total=1000000; XRectangle rectangles[1000]; XSetForeground(mainDisplay, defaultGC, colorPixels[y%maxColors]); UtilGetMilliSecTime(&start_sec, &start_msec); for (i=0; i < total; i++) { XDrawRectangle(mainDisplay, drawWindow, defaultGC, x+y, x, w, w); if (x++ >= x_end) { x=0; if (y++ >= x_end) { y=0; XSetForeground(mainDisplay, defaultGC, colorPixels[(++z)%maxColors]); } } } XSetForeground(mainDisplay, defaultGC, myFgPixel); UtilGetMilliSecTime(&end_sec, &end_msec); elapsed_msec = GetElapseTime(start_sec, start_msec, end_sec, end_msec); if (elapsed_msec > 0) { double avg=((double)total)*((double)1000)/((double)elapsed_msec); /* debug, do not translate */ fprintf(stderr, "Took %ld ms to draw %1d rectangles (%.2f %s).\n", elapsed_msec, total, avg, "rectangles per second"); } x = y = z = 0; XSetForeground(mainDisplay, defaultGC, colorPixels[y%maxColors]); UtilGetMilliSecTime(&start_sec, &start_msec); for (i=0; i < 1000; i++) { rectangles[i].width = rectangles[i].height = w; } w = 0; for (i=0; i < total; i++) { if (w < 1000) { rectangles[w].x = x+y; rectangles[w].y = x; w++; } else { XDrawRectangles(mainDisplay, drawWindow, defaultGC, rectangles, 1000); w = 0; } if (x++ >= x_end) { x=0; if (y++ >= x_end) { y=0; XSetForeground(mainDisplay, defaultGC, colorPixels[(++z)%maxColors]); } } } XSetForeground(mainDisplay, defaultGC, myFgPixel); UtilGetMilliSecTime(&end_sec, &end_msec); elapsed_msec = GetElapseTime(start_sec, start_msec, end_sec, end_msec); if (elapsed_msec > 0) { double avg=((double)total)*((double)1000)/((double)elapsed_msec); /* debug, do not translate */ fprintf(stderr, "Took %ld ms to draw %1d rectangles (%.2f %s).\n", elapsed_msec, total, avg, "rectangles per second"); } } } static void ToggleShowChat() { noChatWindow = !noChatWindow; if (noChatWindow) { XUnmapWindow(mainDisplay, chatWindow); } else { XMapWindow(mainDisplay, chatWindow); } Reconfigure(TRUE); } static int DoShortCut(key_ev, name, key_sym, state, args) XKeyEvent *key_ev; char *name, *args; KeySym key_sym; unsigned int state; /* returns INVALID if the key event can be caught by other windows */ { if (gnDisableShortcuts) { sprintf(gszMsgBox, TgLoadString(STID_TOOL_NOT_FINISH_WITH_EXEC), TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return BAD; } if ((state & ControlMask) && (!(state & METAMASK))) { int rc=BAD; switch (key_sym&0xff) { case 'a': /*^a*/ SelAllObj(TRUE, FALSE); break; case 'b': /*^b*/ BackProc(); break; case 'c': /*^c*/ CopyToCutBuffer(); break; case 'd': /*^d*/ DupSelObj(); break; case 'e': /*^e*/ PushCurChoice(); break; case 'f': /*^f*/ FrontProc(); break; case 'g': /*^g*/ GroupSelObj(TRUE, TRUE, TRUE); break; case 'h': /*^h*/ return(INVALID); case 'i': /*^i*/ Instantiate(); break; case 'j': /*^j*/ return(INVALID); case 'k': /*^k*/ PopIcon(); break; case 'l': /*^l*/ AlignSelObjs(); break; case 'm': /*^m*/ return(INVALID); case 'n': /*^n*/ NewProc(); break; case 'o': /*^o*/ OpenProc((args==NULL || *args=='\0') ? NULL : args); break; case 'p': /*^p*/ Dump(""); break; case 'q': /*^q*/ if ((rc=QuitProc())==INVALID) return BAD; return rc; case 'r': /*^r*/ ClearAndRedrawDrawWindow(); break; case 's': /*^s*/ SaveFile(); break; case 't': /*^t*/ AlignSelToGrid(); break; case 'u': /*^u*/ UngroupSelObj(TRUE, TRUE); break; case 'v': /*^v*/ PasteFromCutBuffer(); break; case 'w': /*^w*/ SetCurChoice(DRAWTEXT); break; case 'x': /*^x*/ CutToCutBuffer(); break; case 'y': /*^y*/ RedoCmd(); break; case 'z': /*^z*/ UndoCmd(); break; case ',': /*^,*/ ScrollLeft(NULL); break; case '.': /*^.*/ ScrollRight(NULL); break; case '-': /*^-*/ PrintWithCommand(""); break; case '1': /*^1*/ ScreenCapture(); break; case '2': /*^2*/ FullScreenCapture(); break; case ' ': case '\\': if (curChoice == DRAWTEXT && textCursorShown && (canvasFontDoubleByte || gstCopyUTF8Info.double_byte_valid)) { if (textHighlight) { curTextModified = TRUE; DelSelText(); } if (!canvasFontDoubleByte && gstCopyUTF8Info.double_byte_valid) { SwitchToDoubleByteFont(&gstCopyUTF8Info.double_byte_seg); } if (tgIMActiveOnCntrlSpace(mainDisplay, drawWindow)) { if (tgIMHandleCntrlSpace(mainDisplay, drawWindow)) { if (gnInputMethod != TGIM_NONE && gnOverTheSpot) { if (!tgIMTellCursorPosition(mainDisplay, drawWindow, textCurX, textCurBaselineY+curStrBlock->seg->des)) { } } } } else { return INVALID; } } break; default: return INVALID; } } else if ((state & METAMASK) && (!(state & ControlMask))) { switch (key_sym&0xff) { case 'a': /*#a*/ AddAttrs(); break; case 'b': /*#b*/ return ProbeProc(); case 'c': /*#c*/ RotateCounter(); break; case 'd': /*#d*/ DecGrid(); break; case 'e': /*#e*/ AnimateSel(); break; case 'f': /*#f*/ FlashSelColor(); break; case 'g': /*#f*/ ToggleGridShown(); break; case 'h': /*#h*/ FlipHorizontal(); break; case 'i': /*#i*/ IncGrid(); break; case 'j': /*#j*/ HideAllAttrNames(); break; case 'k': /*#k*/ SetCurChoice(NOTHING); break; case 'l': /*#l*/ DistrSelObjs(); break; case 'm': /*#m*/ MoveAttr(); break; case 'n': /*#n*/ ShowAllAttrNames(); break; case 'o': /*#o*/ ZoomOut(); break; case 'p': /*#p*/ ImportFile(); break; case 'q': /*#q*/ SetCurChoice(DRAWPOLY); break; case 'r': /*#r*/ SetCurChoice(DRAWBOX); break; case 's': /*#s*/ return SolveProc(); case 't': /*#t*/ DetachAttrs(); break; case 'u': /*#u*/ return AnimateProc(); break; case 'v': /*#v*/ FlipVertical(); break; case 'w': /*#w*/ RotateClockWise(); break; case 'x': /*#x*/ return EscapeProc(); case 'y': /*#y*/ return SimulateProc(); case 'z': /*#z*/ ZoomIn(); break; case '9': /*#9*/ MakePreciseArc(); break; case '0': /*#0*/ UpdateSelObjs(); break; case ',': /*#,*/ ScrollUp(NULL); break; case '.': /*#.*/ ScrollDown(NULL); break; case '-': /*#-*/ ShowAllAttrs(); break; case '{': /*#{*/ AlignObjsTop(); break; case '+': /*#+*/ AlignObjsMiddle(); break; case '}': /*#}*/ AlignObjsBottom(); break; case '[': /*#[*/ AlignObjsLeft(); break; case '=': /*#=*/ AlignObjsCenter(); break; case ']': /*#]*/ AlignObjsRight(); break; case '"': /*#"*/ MakeRegularPolygon(); break; case '%': /*#%*/ SetPrintReduction(); break; case ':': /*#:*/ DefaultZoom(); break; case '`': /*#`*/ ZoomWayOut(); break; case '~': /*#~*/ SaveNewFile(TRUE, NULL); break; case ';': /*#;*/ CutMaps(); break; case '_': /*#_*/ AbutHorizontal(); break; case '|': /*#|*/ AbutVertical(); break; case '#': /*##*/ BreakUpText((args==NULL || *args=='\0') ? NULL : args); break; case '^': /*#^*/ ScrollToOrigin(); break; case '@': /*#@*/ ToggleMoveMode(); break; case '$': /*#$*/ SetCurChoice(VERTEXMODE); break; case '&': /*#&*/ AlignSelToPage(); break; case '*': /*#**/ ChangeDomain(); break; case '(': /*#(*/ ImportEPSFile(FALSE, (args==NULL || *args=='\0') ? NULL : args); break; case ')': /*#)*/ ScaleAllSelObj(); break; case '<': /*#<*/ LockSelObj(); break; case '>': /*#>*/ UnlockSelObj(); break; default: return INVALID; } } else if ((state & METAMASK) && (state & ControlMask)) { switch (key_sym&0xff) { case 'a': /*^#a*/ AddPoint(); break; case 'b': /*^#b*/ ChangeFontStyle(STYLE_BR); break; case 'c': /*^#c*/ ChangeFontJust(JUST_C); break; case 'd': /*^#d*/ DeletePoint(); break; case 'e': /*^#e*/ SetCurChoice(DRAWRCBOX); break; case 'f': /*^#f*/ InvertXBitmaps(); break; case 'g': /*^#g*/ ToggleSnapOn(); break; case 'h': /*^#h*/ HideAllAttrs(); break; case 'i': /*^#i*/ MakeIconic(NULL, TRUE); break; case 'j': /*^#j*/ UnMakeIconic(); break; case 'k': /*^#k*/ ToggleColorPostScript(); break; case 'l': /*^#l*/ ChangeFontJust(JUST_L); break; case 'm': /*^#m*/ MakeSymbolic(); break; case 'n': /*^#n*/ UnMakeSymbolic(); break; case 'o': /*^#o*/ ChangeFontStyle(STYLE_NR); break; case 'p': /*^#p*/ ChangeFontStyle(STYLE_BI); break; case 'q': /*^#q*/ SetCurChoice(DRAWPOLYGON); break; case 'r': /*^#r*/ ChangeFontJust(JUST_R); break; case 's': /*^#s*/ SaveNewFile(FALSE, (args==NULL || *args=='\0') ? NULL : args); break; case 't': /*^#t*/ ChangeFontStyle(STYLE_NI); break; case 'u': /*^#u*/ UpdateSymbols(); break; case 'v': /*^#v*/ SetCurChoice(DRAWCORNEROVAL); break; case 'w': /*^#w*/ ToggleAllSelLineType(); break; case 'x': /*^#x*/ ToggleWhereToPrint(); break; case 'y': /*^#y*/ PushIcon(); break; case 'Y': /*^#Y*/ PasteCompoundText(); break; case 'z': /*^#z*/ SetCurChoice(DRAWARC); break; case '.': /*^#.*/ ImportXBitmapFile(); break; case ',': /*^#,*/ ImportXPixmapFile(); break; case '-': /*^#-*/ ToggleGridSystem(); break; case '=': /*^#=*/ FindAgain(); break; case '5': /*^#5*/ InsertRightSubscript(); break; case '6': /*^#6*/ InsertRightSuperscript(); break; case '7': /*^#7*/ ToggleEqAttrShown(); break; case '8': /*^#8*/ if (inSlideShow) { LeaveSlideShow(); } else { EnterSlideShow(); } break; case '9': /*^#9*/ FindNoCase(); break; case '0': /*^#0*/ FindCaseSensitive(); break; default: return INVALID; } } else if (name != NULL && key_sym == '\0' && state == 0) { XButtonEvent button_ev; button_ev.state = ShiftMask; /* do not translate -- program constants */ if (strcmp(name, "Delete()") == 0) { if (curChoice == DRAWTEXT && textCursorShown) { DelSelText(); } else { DelAllSelObj(); } } else if (strcmp(name, "DrawCornerOval()") == 0) { SetCurChoice(DRAWCORNEROVAL); } else if (strcmp(name, "DrawCenterOval()") == 0) { SetCurChoice(DRAWCENTEROVAL); } else if (strcmp(name, "DrawEdgeOval()") == 0) { SetCurChoice(DRAWEDGECIRCLE); } else if (strcmp(name, "DrawEdgeArc()") == 0) { SetCurChoice(DRAWEDGEARC); } else if (strcmp(name, "ScrollPageUp()") == 0) { ScrollUp(&button_ev); } else if (strcmp(name, "ScrollPageDown()") == 0) { ScrollDown(&button_ev); } else if (strcmp(name, "ScrollPageRight()") == 0) { ScrollRight(&button_ev); } else if (strcmp(name, "ScrollPageLeft()") == 0) { ScrollLeft(&button_ev); } else if (strcmp(name, "FlushUndoBuffer()") == 0) { FlushUndoBuffer(); } else if (strcmp(name, "PrintMsgBuffer()") == 0) { PrintMsgBuffer(); } else if (strcmp(name, "SaveOrigin()") == 0) { SaveOrigin(); } else if (strcmp(name, "RestoreImageWH()") == 0) { RestoreImageWH(); } else if (strcmp(name, "UpdateEPS()") == 0) { UpdateEPS(); } else if (strcmp(name, "ToggleMapShown()") == 0) { ToggleMapShown(); } else if (strcmp(name, "ToggleUseGrayScale()") == 0) { ToggleUseGray(); } else if (strcmp(name, "FreeHandMode()") == 0) { SetCurChoice(FREEHAND); } else if (strcmp(name, "SaveSymInLibrary()") == 0) { SaveSymInLibrary(); } else if (strcmp(name, "CenterAnEndPoint()") == 0 || strcmp(name, "CenterAVertex()") == 0) { CenterAnEndPoint(); } else if (strcmp(name, "NextPage()") == 0) { NextPage(); } else if (strcmp(name, "PrevPage()") == 0) { PrevPage(); } else if (strcmp(name, "NamePages()") == 0) { NamePages(); } else if (strcmp(name, "GotoPage()") == 0) { GotoPage((args==NULL || *args=='\0') ? NULL : args); } else if (strcmp(name, "AddPageBefore()") == 0) { AddPageBefore(); } else if (strcmp(name, "AddPageAfter()") == 0) { AddPageAfter(); } else if (strcmp(name, "DeleteCurPage()") == 0) { DeleteCurPage(); } else if (strcmp(name, "TogglePageLineShown()") == 0) { TogglePageLineShown(); } else if (strcmp(name, "SpecifyDrawingSize()") == 0) { SpecifyDrawingSize(); } else if (strcmp(name, "PrintOnePage()") == 0) { PrintOnePage(); } else if (strcmp(name, "ToggleNamedAttrShown()") == 0) { if (args != NULL) { ToggleNamedAttrShown(args); } } else if (strcmp(name, "AttachFileAttrs()") == 0) { AddFileAttrs(); } else if (strcmp(name, "DetachFileAttrs()") == 0) { DetachFileAttrs(); } else if (strcmp(name, "EditFileAttrs()") == 0) { EditFileAttrs(); } else if (strcmp(name, "PrintSelectedObjs()") == 0) { PrintSelectedObjs(); } else if (strcmp(name, "InputPolyPts()") == 0) { InputPolyPts(); } else if (strcmp(name, "InputPolygonPts()") == 0) { InputPolygonPts(); } else if (strcmp(name, "EditAttrs()") == 0) { EditAttrs(); } else if (strcmp(name, "ConvertIntSpline()") == 0) { ConvertIntSpline(); } else if (strcmp(name, "PasteFromFile()") == 0) { PasteFromFile(); } else if (strcmp(name, "ToggleShowMeasurement()") == 0) { ToggleShowMeasurement(); } else if (strcmp(name, "SetMeasureUnit()") == 0) { SetMeasureUnit(); } else if (strcmp(name, "Cut()") == 0) { CutToCutBuffer(); } else if (strcmp(name, "ToggleSmoothHinge()") == 0) { ToggleSmoothHinge(); } else if (strcmp(name, "ToggleShowMenubar()") == 0) { ToggleShowMenubar(); } else if (strcmp(name, "ToggleShowStatus()") == 0) { ToggleShowStatus(); } else if (strcmp(name, "BrowseXBitmap()") == 0) { BrowseXBitmap(); } else if (strcmp(name, "BrowseXPixmap()") == 0) { BrowseXPixmap(); } else if (strcmp(name, "SpecifyPaperSize()") == 0) { SpecifyPaperSize(); } else if (strcmp(name, "ToggleOneMotionSelMove()") == 0) { ToggleOneMotionSelectMove(); } else if (strcmp(name, "GoBack()") == 0) { NavigateBack(); } else if (strcmp(name, "GoForward()") == 0) { NavigateForward(); } else if (strcmp(name, "RefreshCurrent()") == 0) { NavigateRefresh(); } else if (strcmp(name, "HotList()") == 0) { NavigateHotList(); } else if (strcmp(name, "AddCurrentToHotList()") == 0) { NavigateAddToHotList(); } else if (strcmp(name, "SessionHistory()") == 0) { NavigateSessionHistory(); } else if (strcmp(name, "ToggleHyperSpace()") == 0) { ToggleHyperSpace (FALSE); } else if (strcmp(name, "EmbedEPSFile()") == 0) { ImportEPSFile(TRUE, NULL); } else if (strcmp(name, "SetSelLineWidth()") == 0) { SetSelLineWidth(NULL); } else if (strcmp(name, "AddColor()") == 0) { AddColor(); } else if (strcmp(name, "ImportAttrs()") == 0) { ImportAttrs(); } else if (strcmp(name, "ExportAttrs()") == 0) { ExportAttrs(); } else if (strcmp(name, "MergeWithTable()") == 0) { MergeWithTable(); } else if (strcmp(name, "ExportToTable()") == 0) { ExportToTable(); } else if (strcmp(name, "DeletePages()") == 0) { DeletePages(); } else if (strcmp(name, "PrintOneFilePerPage()") == 0) { PrintOneFilePerPage(); } else if (strcmp(name, "ImportGIFFile()") == 0) { ImportGIFFile(); } else if (strcmp(name, "ImportPNGFile()") == 0) { ImportPNGFile(); } else if (strcmp(name, "ImportJPEGFile()") == 0) { ImportJPEGFile(TRUE, NULL); } else if (strcmp(name, "ImportPBMFile()") == 0) { ImportPBMFile(); } else if (strcmp(name, "ImportPGMFile()") == 0) { ImportPGMFile(); } else if (strcmp(name, "ImportPPMFile()") == 0) { ImportPPMFile(); } else if (strcmp(name, "SetExportPixelTrim()") == 0) { SetExportPixelTrim(FALSE); } else if (strcmp(name, "ToggleColorLayers()") == 0) { ToggleColorLayers(); } else if (strcmp(name, "ToggleStretchableText()") == 0) { ToggleStretchableText(); } else if (strcmp(name, "BreakUpBit/Pixmap()") == 0) { BreakUpMaps(); } else if (strcmp(name, "LayoutOnArc()") == 0) { LayoutOnArc(); } else if (strcmp(name, "PreciseRotate()") == 0) { PreciseRotate(); } else if (strcmp(name, "JoinPoly()") == 0) { JoinPoly(); } else if (strcmp(name, "CutPoly()") == 0) { CutPoly(); } else if (strcmp(name, "GetBoundingBox()") == 0) { GetBoundingBox(); } else if (strcmp(name, "SetTemplate()") == 0) { SetTemplate(); } else if (strcmp(name, "MakeGray()") == 0) { MakeGray(); } else if (strcmp(name, "InvertColor()") == 0) { InvertColor(); } else if (strcmp(name, "InterpolateColor()") == 0) { InterpolateColor(); } else if (strcmp(name, "BrightenDarken()") == 0) { BrightenDarken(); } else if (strcmp(name, "ChangeSaturation()") == 0) { ChangeSaturation(); } else if (strcmp(name, "ChangeHue()") == 0) { ChangeHue(); } else if (strcmp(name, "ContrastEnhance()") == 0) { ContrastEnhance(); } else if (strcmp(name, "ColorBalance()") == 0) { ColorBalance(); } else if (strcmp(name, "Gamma()") == 0) { Gamma(NULL); } else if (strcmp(name, "EdgeDetect()") == 0) { EdgeDetect(); } else if (strcmp(name, "Emboss()") == 0) { Emboss(); } else if (strcmp(name, "ReduceColors()") == 0) { ReduceColors(); } else if (strcmp(name, "ReduceToPixmapColors()") == 0) { ReduceToPixmapColors(); } else if (strcmp(name, "SetDefaultColorLevels()") == 0) { SetDefaultColorLevels(); } else if (strcmp(name, "ReduceToDefaultColors()") == 0) { ReduceToDefaultColors(); } else if (strcmp(name, "DefaultErrorDiffuse()") == 0) { DefaultErrorDiffuse(); } else if (strcmp(name, "Spread()") == 0) { Spread(); } else if (strcmp(name, "Sharpen()") == 0) { Sharpen(); } else if (strcmp(name, "Blur3()") == 0) { Blur3(); } else if (strcmp(name, "Blur5()") == 0) { Blur5(); } else if (strcmp(name, "Blur7()") == 0) { Blur7(); } else if (strcmp(name, "RunBggen()") == 0) { RunBggen(); } else if (strcmp(name, "CircularBggen()") == 0) { CircularBggen(); } else if (strcmp(name, "SimpleRectBggen()") == 0) { SimpleRectBggen(); } else if (strcmp(name, "RegenerateImage()") == 0) { RegenerateImage(); } else if (strcmp(name, "CropImage()") == 0) { CropImage(); } else if (strcmp(name, "GetColor()") == 0) { GetColor(); } else if (strcmp(name, "ReplaceColor()") == 0) { ReplaceColor(); } else if (strcmp(name, "FloodFill()") == 0) { FloodFill(); } else if (strcmp(name, "CreateContour()") == 0) { CreateContour(); } else if (strcmp(name, "Subtract()") == 0) { Subtract(); } else if (strcmp(name, "AlphaCombine()") == 0) { AlphaCombine(); } else if (strcmp(name, "XorColors()") == 0) { XorColors(); } else if (strcmp(name, "ImportOtherFile()") == 0) { ImportOtherFile(); } else if (strcmp(name, "ImportOtherFileType()") == 0) { if (args != NULL) { ImportOtherFileType(args); } } else if (strcmp(name, "BrowseOther()") == 0) { BrowseOther(); } else if (strcmp(name, "BrowseOtherType()") == 0) { if (args != NULL) { BrowseOtherType(args); } } else if (strcmp(name, "ToggleShowCrossHair()") == 0) { ToggleShowCrossHair(); } else if (strcmp(name, "SetShapeShadow()") == 0) { SetShapeShadow(); } else if (strcmp(name, "NoTransform()") == 0) { NoTransform(); } else if (strcmp(name, "About()") == 0) { About(); } else if (strcmp(name, "Copyright()") == 0) { Copyright(); } else if (strcmp(name, "SetSelFontSize()") == 0) { SetSelFontSize(NULL); } else if (strcmp(name, "ZoomInAtCursor()") == 0) { if (key_ev != NULL) { int abs_x=ABS_X(key_ev->x); int abs_y=ABS_Y(key_ev->y); ZoomInAtCursor(abs_x, abs_y); } } else if (strcmp(name, "CenterAtCursor()") == 0) { if (key_ev != NULL) { int abs_x=ABS_X(key_ev->x); int abs_y=ABS_Y(key_ev->y); CenterAtCursor(abs_x, abs_y); } } else if (strcmp(name, "SetEditTextSize()") == 0) { SetEditTextSize(); } else if (strcmp(name, "SetTextRotation()") == 0) { SetTextRotation(NULL); } else if (strcmp(name, "SetRotationIncrement()") == 0) { SetRotationIncrement(NULL); } else if (strcmp(name, "CurrentVersionInfo()") == 0 || strcmp(name, "LatestReleaseInfo()") == 0) { LatestReleaseInfo(); } else if (strcmp(name, "VectorWarp()") == 0) { VectorWarp(); } else if (strcmp(name, "ConnectPins()") == 0) { ConnectPins(); } else if (strcmp(name, "PasteCompoundText()") == 0) { PasteCompoundText(); } else if (strcmp(name, "CopyProperties()") == 0) { CopyProperties(TRUE); } else if (strcmp(name, "SaveProperties()") == 0) { SaveProperties(); } else if (strcmp(name, "PasteProperties()") == 0) { PasteProperties(TRUE); } else if (strcmp(name, "RestoreProperties()") == 0) { RestoreProperties(); } else if (strcmp(name, "RotateShearMode()") == 0) { SetCurChoice(ROTATEMODE); } else if (strcmp(name, "ChangeAllSelFill()") == 0) { if (args != NULL) { ChangeAllSelFill(atoi(args), TRUE); } } else if (strcmp(name, "ChangeAllSelPen()") == 0) { if (args != NULL) { ChangeAllSelPen(atoi(args), TRUE); } } else if (strcmp(name, "ChangeAllSelLineWidth()") == 0) { if (args != NULL) { ChangeAllSelLineWidth(atoi(args), TRUE); } } else if (strcmp(name, "ChangeAllSelLineStyle()") == 0) { if (args != NULL) { ChangeAllSelLineStyle(atoi(args), TRUE); } } else if (strcmp(name, "ChangeAllSelLineType()") == 0) { if (args != NULL) { ChangeAllSelLineType(atoi(args), TRUE); } } else if (strcmp(name, "ChangeAllSelLineDash()") == 0) { if (args != NULL) { ChangeAllSelLineDash(atoi(args), TRUE); } } else if (strcmp(name, "ChangeAllSelFont()") == 0) { if (args != NULL) { ChangeFont(atoi(args), FALSE); } } else if (strcmp(name, "ChangeAllSelFontSize()") == 0) { if (args != NULL) { ChangeFontSize(atoi(args)); } } else if (strcmp(name, "ChangeAllSelFontStyle()") == 0) { if (args != NULL) { ChangeFontStyle(atoi(args)); } } else if (strcmp(name, "ChangeAllSelFontJust()") == 0) { if (args != NULL) { ChangeFontJust(atoi(args)-MAXFONTSTYLES-1); } } else if (strcmp(name, "ChangeAllSelColor()") == 0) { if (args != NULL) { ChangeAllSelColor(atoi(args), TRUE); } } else if (strcmp(name, "LanscapeMode()") == 0) { ChangePageStyle(LANDSCAPE); } else if (strcmp(name, "PortraitMode()") == 0) { ChangePageStyle(PORTRAIT); } else if (strcmp(name, "SetWhereToPrint()") == 0) { if (args != NULL) { SetWhereToPrint(atoi(args)); } } else if (strcmp(name, "SetHoriAlign()") == 0) { if (args != NULL) { HoriAlignSubMenu(atoi(args)); } } else if (strcmp(name, "SetVertAlign()") == 0) { if (args != NULL) { VertAlignSubMenu(atoi(args)); } } else if (strcmp(name, "SetMoveMode()") == 0) { if (args != NULL) { MoveModeSubMenu(atoi(args)); } } else if (strcmp(name, "SetStretchTextMode()") == 0) { if (args != NULL) { StretchableTextModeSubMenu(atoi(args)); } } else if (strcmp(name, "CreateShape()") == 0) { if (args != NULL) { ShapeSubMenu(atoi(args)); } } else if (strcmp(name, "SetPageLayoutMode()") == 0) { if (args != NULL) { PageLayoutSubMenu(atoi(args)); } } else if (strcmp(name, "SetTransPatMode()") == 0) { if (args != NULL) { ChangeAllSelTransPat(atoi(args), TRUE); } } else if (strcmp(name, "ToggleShowMode()") == 0) { ToggleShowMode(); } else if (strcmp(name, "SetSlideShowBorderColor()") == 0) { SetSlideShowBorderColor(); } else if (strcmp(name, "SetSlideShowWindowOffsets()") == 0) { SetSlideShowWindowOffsets(); } else if (strcmp(name, "ExportXPixmapDeckToGIF()") == 0) { ExportXPixmapDeckToGIF(); } else if (strcmp(name, "ImportGIFToXPixmapDeck()") == 0) { ImportGIFToXPixmapDeck(); } else if (strcmp(name, "InsertThinSpace()") == 0) { InsertThinSpace(); } else if (strcmp(name, "InsertVerticalOffset()") == 0) { InsertVerticalOffset(); } else if (strcmp(name, "RemoveVerticalOffset()") == 0) { RemoveVerticalOffset(); } else if (strcmp(name, "InsertLeftSuperscript()") == 0) { InsertLeftSuperscript(); } else if (strcmp(name, "InsertLeftSubscript()") == 0) { InsertLeftSubscript(); } else if (strcmp(name, "InsertCenterSuperscript()") == 0) { InsertCenterSuperscript(); } else if (strcmp(name, "InsertCenterSubscript()") == 0) { InsertCenterSubscript(); } else if (strcmp(name, "SetScriptFraction()") == 0) { SetScriptFraction(); } else if (strcmp(name, "FakeUserAgent()") == 0) { if (args != NULL) { FakeUserAgent(args); } } else if (strcmp(name, "FakeReferer()") == 0) { if (args != NULL) { FakeReferer(args); } } else if (strcmp(name, "ToggleKeepAlive()") == 0) { ToggleKeepAlive(); } else if (strcmp(name, "SizeToWidest()") == 0) { SizeToWidest(); } else if (strcmp(name, "SizeToNarrowest()") == 0) { SizeToNarrowest(); } else if (strcmp(name, "SizeToTallest()") == 0) { SizeToTallest(); } else if (strcmp(name, "SizeToShortest()") == 0) { SizeToShortest(); } else if (strcmp(name, "SizeToGivenWidthHeight()") == 0) { SizeToGivenWidthHeight(); } else if (strcmp(name, "SizeToGivenWidth()") == 0) { SizeToGivenWidth(); } else if (strcmp(name, "SizeToGivenHeight()") == 0) { SizeToGivenHeight(); } else if (strcmp(name, "ExecCmdsFromFile()") == 0) { if (args != NULL) { ExecCmdsFromFile(args); } } else if (strcmp(name, "StartExecCmdsFromFile()") == 0) { StartExecCmdsFromFile(); } else if (strcmp(name, "CopyPlainTextAsObject()") == 0) { CopyPlainTextAsObject(); } else if (strcmp(name, "SetTextFillPatternColor()") == 0) { SetTextFillPatternColor(); } else if (strcmp(name, "AlignDirect()") == 0) { if (args != NULL) { AlignDirect(atoi(args)); } } else if (strcmp(name, "DistributeDirect()") == 0) { if (args != NULL) { DistributeDirect(atoi(args)); } } else if (strcmp(name, "ToggleVisibleGridInSlideShow()") == 0) { ToggleVisibleGridInSlideShow(); } else if (strcmp(name, "ChangeScrollMode()") == 0) { if (args != NULL) { ChangeScrollMode(atoi(args)); } } else if (strcmp(name, "SetAltEditTextBgColor()") == 0) { SetAltEditTextBgColor(); } else if (strcmp(name, "SetAltEditTextHighlightColor()") == 0) { SetAltEditTextHighlightColor(); } else if (strcmp(name, "ToggleAltEditTextBgColor()") == 0) { ToggleAltEditTextBgColor(); } else if (strcmp(name, "ChangeAllSelFontUnderline()") == 0) { if (args != NULL) { ChangeFontUnderline(atoi(args)-MAXFONTSTYLES-MAXJUSTS-2); } } else if (strcmp(name, "ChangeAllSelFontOverline()") == 0) { if (args != NULL) { ChangeFontOverline(atoi(args)-MAXFONTSTYLES-MAXJUSTS-5); } } else if (strcmp(name, "EditPageFileNames()") == 0) { EditPageFileNames(); } else if (strcmp(name, "ExportHalfToneBitmap()") == 0) { ExportHalfToneBitmap(); } else if (strcmp(name, "ExportThresholdBitmap()") == 0) { ExportThresholdBitmap(); } else if (strcmp(name, "SetExportBitmapThreshold()") == 0) { if (args != NULL) { SetExportBitmapThreshold(NULL); } } else if (strcmp(name, "PreciseScaleEverything()") == 0) { PreciseScaleEverything(); } else if (strcmp(name, "SetPaperColor()") == 0) { SetPaperColor(); } else if (strcmp(name, "DelayedFullScreenCapture()") == 0) { DelayedFullScreenCapture(); } else if (strcmp(name, "ToggleHideDuringCapture()") == 0) { ToggleHideDuringCapture(); } else if (strcmp(name, "EditDomainPaths()") == 0) { EditDomainPaths(); } else if (strcmp(name, "SelectDefaultDomain()") == 0) { SelectDefaultDomain(); } else if (strcmp(name, "AddADomain()") == 0) { AddADomain(); } else if (strcmp(name, "DeleteADomain()") == 0) { DeleteADomain(); } else if (strcmp(name, "ReloadDomainInfoFromX()") == 0) { ReloadDomainInfoFromX(); } else if (strcmp(name, "EditIndexedAttrInEditor()") == 0) { if (args != NULL) { EditIndexedAttrInEditor(atoi(args)); } } else if (strcmp(name, "EditIndexedAttrGroupInEditor()") == 0) { if (args != NULL) { EditIndexedAttrGroupInEditor(atoi(args)); } } else if (strcmp(name, "GetProperty()") == 0) { if (args != NULL) { GetProperty(atoi(args)); } } else if (strcmp(name, "PeekDimension()") == 0) { if (args != NULL) { PeekDimension(atoi(args)); } } else if (strcmp(name, "SetHtmlExportTemplate()") == 0) { SetHtmlExportTemplate(); } else if (strcmp(name, "PrintPages()") == 0) { PrintPages(); } else if (strcmp(name, "GoHyperSpaceInSlideShow()") == 0) { GoHyperSpaceInSlideShow(); } else if (strcmp(name, "FreehandModeInSlideShow()") == 0) { FreehandModeInSlideShow(); } else if (strcmp(name, "OpenARecentlyUsedFile()") == 0) { if (args != NULL) { OpenARecentlyUsedFile(atoi(args)); } } else if (strcmp(name, "MoveEditTextBox()") == 0) { MoveEditTextBox(); } else if (strcmp(name, "ReplaceGraphic()") == 0) { ReplaceGraphic(); } else if (strcmp(name, "ToggleShowMeasurementInTooltip()") == 0) { ToggleShowMeasurementInTooltip(); } else if (strcmp(name, "ToggleAutoEPSPreviewBitmap()") == 0) { ToggleAutoEPSPreviewBitmap(); } else if (strcmp(name, "CreateThumbnails()") == 0) { CreateThumbnails(); } else if (strcmp(name, "ConnectTwoPortsByAWire()") == 0) { ConnectTwoPortsByAWire(); } else if (strcmp(name, "RenameSignalNameForAPort()") == 0) { RenameSignalNameForAPort(); } else if (strcmp(name, "ClearSignalNameForAPort()") == 0) { ClearSignalNameForAPort(); } else if (strcmp(name, "ToggleShowWireSignalName()") == 0) { ToggleShowWireSignalName(); } else if (strcmp(name, "ToggleShowChoicebar()") == 0) { ToggleShowChoicebar(); } else if (strcmp(name, "MergePortsWithAnObject()") == 0) { MergePortsWithAnObject(); } else if (strcmp(name, "RenumberObjectIds()") == 0) { RenumberObjectIds(); } else if (strcmp(name, "RepeatConnectTwoPortsByAWire()") == 0) { RepeatConnectTwoPortsByAWire(); } else if (strcmp(name, "ConnectPortsToBroadcastWire()") == 0) { ConnectPortsToBroadcastWire(); } else if (strcmp(name, "ImportMultipageTextFile()") == 0) { ImportMultipageTextFile(); } else if (strcmp(name, "SetMarginsForImportMultipageTextFile()") == 0) { SetMarginsForImportMultipageTextFile(); } else if (strcmp(name, "ToggleWordWrapDuringImportMultipageTextFile()") == 0) { ToggleWordWrapDuringImportMultipageTextFile(); } else if (strcmp(name, "HandleDataInMBuff()") == 0) { HandleDataInMBuff(); } else if (strcmp(name, "BenchMark()") == 0) { BenchMark(); } else if (strcmp(name, "ConvertToBezier()") == 0) { ConvertToBezier(); } else if (strcmp(name, "SetBezierConvertNumSegs()") == 0) { SetBezierConvertNumSegs((args==NULL || *args=='\0') ? NULL : args); } else if (strcmp(name, "AddSquareTickMarks()") == 0) { AddTickMarks(CMDID_ADDSQUARETICKMARKS); } else if (strcmp(name, "AddTriangleTickMarks()") == 0) { AddTickMarks(CMDID_ADDTRIANGLETICKMARKS); } else if (strcmp(name, "AddCircleTickMarks()") == 0) { AddTickMarks(CMDID_ADDCIRCLETICKMARKS); } else if (strcmp(name, "AddXTickMarks()") == 0) { AddTickMarks(CMDID_ADDXTICKMARKS); } else if (strcmp(name, "AddDiamondTickMarks()") == 0) { AddTickMarks(CMDID_ADDDIAMONDTICKMARKS); } else if (strcmp(name, "AddBowtieTickMarks()") == 0) { AddTickMarks(CMDID_ADDBOWTIETICKMARKS); } else if (strcmp(name, "AddInvTriangleTickMarks()") == 0) { AddTickMarks(CMDID_ADDINVTRIANGLETICKMARKS); } else if (strcmp(name, "AddPlusTickMarks()") == 0) { AddTickMarks(CMDID_ADDPLUSTICKMARKS); } else if (strcmp(name, "AddHourGlassTickMarks()") == 0) { AddTickMarks(CMDID_ADDHOURGLASSTICKMARKS); } else if (strcmp(name, "SetTickMarkSize()") == 0) { SetTickMarkSize((args==NULL || *args=='\0') ? NULL : args); } else if (strcmp(name, "ToggleShowChat()") == 0) { ToggleShowChat(); } else if (strcmp(name, "SavePagesAs()") == 0) { SavePagesAs(); } else if (strcmp(name, "AddPageBeforeCopyAll()") == 0) { AddPageBeforeCopyAll(); } else if (strcmp(name, "AddPageAfterCopyAll()") == 0) { AddPageAfterCopyAll(); } else if (strcmp(name, "InsertHexOctalChar()") == 0) { InsertHexOctalChar(); } else if (strcmp(name, "ResetInputMethod()") == 0) { ResetInputMethod(); } else if (strcmp(name, "LinkExtJPEGFile()") == 0) { ImportJPEGFile(FALSE, NULL); } else if (strcmp(name, "NextSlide()") == 0) { NextSlide(); } else if (strcmp(name, "PrevSlide()") == 0) { PrevSlide(); } else if (strcmp(name, "SetObjectShadowColor()") == 0) { SetObjectShadowColor(); } else if (strcmp(name, "SetObjectShadowOffsets()") == 0) { SetObjectShadowOffsets(); } else if (strcmp(name, "AddObjectShadow()") == 0) { AddObjectShadow(); } else if (strcmp(name, "RemoveObjectShadow()") == 0) { RemoveObjectShadow(); } else if (strcmp(name, "CopyDoubleByteString()") == 0) { CopyDoubleByteString(); } else if (strcmp(name, "PasteDoubleByteString()") == 0) { PasteDoubleByteString(); } else if (strcmp(name, "ReduceToMobileWebSafeColors()") == 0) { ReduceToMobileWebSafeColors(); } else if (strcmp(name, "CreatePixmapFromSelected()") == 0) { CreatePixmapFromSelected(); } else if (strcmp(name, "ToggleAutoRotatePivot()") == 0) { ToggleAutoRotatePivot(); } else if (strcmp(name, "SpecifyRotatePivot()") == 0) { SpecifyRotatePivot(); } else if (strcmp(name, "ResetRotatePivot()") == 0) { ResetRotatePivot(); } else if (strcmp(name, "NextPolyRotationPivot()") == 0) { NextPolyRotationPivot(); } else if (strcmp(name, "MoveRotationPivotToArcCenter()") == 0) { MoveRotationPivotToArcCenter(); } else if (strcmp(name, "MoveRotatePivotCenter()") == 0) { MoveRotatePivot(CORNER_NONE); } else if (strcmp(name, "MoveRotatePivotLeftTop()") == 0) { MoveRotatePivot(CORNER_LT); } else if (strcmp(name, "MoveRotatePivotRightTop()") == 0) { MoveRotatePivot(CORNER_RT); } else if (strcmp(name, "MoveRotatePivotLeftBottom()") == 0) { MoveRotatePivot(CORNER_LB); } else if (strcmp(name, "MoveRotatePivotRightBottom()") == 0) { MoveRotatePivot(CORNER_RB); } else if (strcmp(name, "MoveRotatePivotLeft()") == 0) { MoveRotatePivot(CORNER_LEFT); } else if (strcmp(name, "MoveRotatePivotRight()") == 0) { MoveRotatePivot(CORNER_RIGHT); } else if (strcmp(name, "MoveRotatePivotTop()") == 0) { MoveRotatePivot(CORNER_TOP); } else if (strcmp(name, "MoveRotatePivotBottom()") == 0) { MoveRotatePivot(CORNER_BOTTOM); } else if (strcmp(name, "ChooseRotatePivot()") == 0) { if (args != NULL) { AutoRotatePivotSubMenu(atoi(args)); } } else if (strcmp(name, "ChooseColor()") == 0) { ChooseColor(); } else if (strcmp(name, "ExtendSegment()") == 0) { ExtendSegment(); } else if (strcmp(name, "InsertSymbol()") == 0) { InsertSymbol(); } else if (strcmp(name, "ToggleRightMargin()") == 0) { ToggleRightMargin(); } else if (strcmp(name, "SpecifyRightMargin()") == 0) { SpecifyRightMargin(); } else if (strcmp(name, "ToggleFloodReplaceColorThreshold()") == 0) { ToggleFloodReplaceColorThreshold(); } else if (strcmp(name, "SetFloodReplaceColorThreshold()") == 0) { SetFloodReplaceColorThreshold(); } else if (strcmp(name, "RemoveTransparentPixel()") == 0) { RemoveTransparentPixel(); } else if (strcmp(name, "ReplaceColorWithTrans()") == 0) { ReplaceColorWithTrans(); #ifdef NOT_DEFINED } else if (strcmp(name, "ToggleTighterStructuredSplines()") == 0) { ToggleTighterStructuredSplines(); #endif /* NOT_DEFINED */ } else if (strcmp(name, "MakeBoxObjFromBoundingBox()") == 0) { MakeBoxObjFromBoundingBox(); } else if (strcmp(name, "MakeRCBoxObjFromBoundingBox()") == 0) { MakeRCBoxObjFromBoundingBox(); } else if (strcmp(name, "MakeOvalObjFromBoundingBox()") == 0) { MakeOvalObjFromBoundingBox(); } } return BAD; } int ShortHand(input) XEvent *input; /* * returns BAD if the character is a <CONTROL> or a <META> character * this will cause the event to be swollowed * returns INVALID if the character is a normal character, this means * that the event it not processed and will be handled by a * routine later * otherwise, returns the value of sub-functions, such as QuitProc() */ { register int i; char buf[80], *name=NULL, args[MAXSTRING+1]; int valid_shortcut=FALSE, have_ch; KeySym key_sym=(KeySym)0; XKeyEvent *key_ev; key_ev = (&(input->xkey)); have_ch = XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); TranslateKeys(buf, &key_sym); *args = '\0'; if (key_ev->window == drawWindow && CharIsCntrlINS(key_ev, key_sym)) { CopyToCutBuffer(); return BAD; } else if (key_ev->window == drawWindow && CharIsShiftINS(key_ev, key_sym)) { PasteFromCutBuffer(); return BAD; } else if (key_sym >= '\040' && (key_ev->state & (ControlMask | METAMASK))) { valid_shortcut = TRUE; } else if (key_sym >= XK_F1 && key_sym <= XK_F12) { char code='\0'; unsigned int state=0; valid_shortcut = FetchFuncKeyShortCut((int)(key_sym), &code, &state, &name, args, sizeof(args)); if (valid_shortcut) { key_sym = code; key_ev->state = state; } } else if (((key_sym>'\040' && key_sym<='\177') || (key_sym>0xa0 && key_sym<=0xff)) && !(key_ev->state & (ControlMask | METAMASK)) && curChoice != DRAWTEXT && !TidgetHasFocus()) { char code='\0'; unsigned int state=0; for (i = 0; i < numExtraWins; i++) { if (key_ev->window == extraWinInfo[i].window && extraWinInfo[i].window != None) { break; } } if (i == numExtraWins) { valid_shortcut = FetchShortCut((int)(key_sym&0xff), &code, &state, &name, args, sizeof(args)); if (valid_shortcut) { key_sym = code; key_ev->state = state; } } } if (valid_shortcut) { int rc=0; int try_x_lookup_keysym=FALSE; Msg(""); #ifndef _NO_XLOOKUPKEYSYM try_x_lookup_keysym = TRUE; #endif /* ~_NO_XLOOKUPKEYSYM */ rc = DoShortCut(key_ev, name, key_sym, key_ev->state, args); if (rc == INVALID && try_x_lookup_keysym) { key_sym = XLookupKeysym(key_ev, 0); return DoShortCut(key_ev, name, key_sym, key_ev->state, args); } return rc; } return INVALID; } int ExecuteCmdById(nCmdId, nIndex) int nCmdId, nIndex; { char *name=NULL, args[MAXSTRING+1], code='\0'; unsigned int state; KeySym key_sym=(KeySym)0; XKeyEvent key_ev; *args = '\0'; if (FetchCmdById(nCmdId, &code, &state, &name, args)) { if (*args == '\0') sprintf(args, "%d", nIndex); key_sym = code; key_ev.state = state; Msg(""); return DoShortCut(&key_ev, name, key_sym, key_ev.state, args); } else if (cmdLineTgrm2 && ValidTangram2CmdId(nCmdId)) { return DoTangram2Cmd(nCmdId, NULL); } return INVALID; } int CallShortCut(name, argc, argv, code, state) char *name, *argv[], *code; int argc; unsigned int state; { /* do not translate -- program constants */ if (UtilStrICmp(name, "ZoomInAtCursor") == 0 || UtilStrICmp(name, "CenterAtCursor") == 0) { return FALSE; } DoShortCut(NULL, name, (KeySym)(*code), state, (argc<=1 ? NULL : argv[1])); return TRUE; } int SomethingDirty() { register struct ObjRec *obj_ptr=topObj; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->next) { if (obj_ptr->dirty) { return TRUE; } } return FALSE; } static char gszEditorCmd[MAXSTRING]; static char gszDefEditorCmd[]="xterm -title '%s' -e vi '%s'"; static void InitEditor() { static int stInitialized=FALSE; if (!stInitialized) { int count=0; char *psz=NULL; strcpy(gszEditorCmd, gszDefEditorCmd); if ((psz=XGetDefault(mainDisplay, TOOL_NAME, "Editor")) != NULL) { UtilStrCpyN(gszEditorCmd, sizeof(gszEditorCmd), psz); } UtilTrimBlanks(gszEditorCmd); for(psz=strstr(gszEditorCmd,"%s"); psz != NULL; psz=strstr(++psz,"%s")) { count++; } if (count != 2) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "Editor", gszEditorCmd, gszDefEditorCmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(gszEditorCmd, gszDefEditorCmd); } stInitialized = TRUE; } } typedef struct tagTmpFileRec { char tmp_fname[MAXPATHLENGTH]; struct stat stat_buf; } TmpFileInfo; static int WriteAttrToTmp(attr_ptr, ptfi) struct AttrRec *attr_ptr; TmpFileInfo *ptfi; { FILE *fp=NULL; if (MkTempFile(ptfi->tmp_fname, sizeof(ptfi->tmp_fname), tmpDir, TOOL_NAME) == NULL) { return FALSE; } if ((fp=fopen(ptfi->tmp_fname, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), ptfi->tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } writeFileFailed = FALSE; if (*attr_ptr->attr_name.s == '\0') { DumpMiniLinesInAscii(fp, &attr_ptr->obj->detail.t->minilines, NULL); } else { int need_to_free_tmp_buf=FALSE; MiniLineInfo *pMiniLine=attr_ptr->obj->detail.t->minilines.first; char *tmp_buf=NULL, *psz=NULL; tmp_buf = ConvertAttrNameFirstMiniLineToString(attr_ptr, &need_to_free_tmp_buf); psz = strchr(tmp_buf, '='); fprintf(fp, "%s\n", &psz[1]); for (pMiniLine=pMiniLine->next; pMiniLine != NULL; pMiniLine=pMiniLine->next) { DumpMiniLineInAscii(fp, pMiniLine, NULL); if (fprintf(fp, "\n") == EOF) writeFileFailed = TRUE; } if (need_to_free_tmp_buf) UtilFree(tmp_buf); } fclose(fp); if (writeFileFailed) { FailToWriteFileMessage(ptfi->tmp_fname); unlink(ptfi->tmp_fname); return FALSE; } if (tmpFileMode != 0 && chmod(ptfi->tmp_fname, tmpFileMode)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CHMOD), ptfi->tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(ptfi->tmp_fname); return FALSE; } if (stat(ptfi->tmp_fname, &ptfi->stat_buf) != 0) { sprintf(gszMsgBox, TgLoadString(STID_STAT_FAIL_EDIT_ATTR_VAL_SAME), ptfi->tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(ptfi->tmp_fname); return FALSE; } return TRUE; } static int WriteNamedAttrsToTmp(obj_ptr, num_restricted, ppsz_restricted, ptfi, pn_num_exported) struct ObjRec *obj_ptr; int num_restricted, *pn_num_exported; char **ppsz_restricted; TmpFileInfo *ptfi; { int i=0, num_found=0; FILE *fp=NULL; if (MkTempFile(ptfi->tmp_fname, sizeof(ptfi->tmp_fname), tmpDir, TOOL_NAME) == NULL) { return FALSE; } if ((fp=fopen(ptfi->tmp_fname, "w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), ptfi->tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_WRITING_ATTR_TO_NAMED_FILE), ptfi->tmp_fname); Msg(gszMsgBox); writeFileFailed = FALSE; for (i=0; i < num_restricted; i++) { char *attr_name=ppsz_restricted[i]; struct AttrRec *attr_ptr=FindObjAttrWithName(obj_ptr, attr_name); if (attr_ptr == NULL) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANT_FIND_NAMED_ATTR), attr_name); Msg(gszMsgBox); } else { if (*attr_ptr->attr_name.s == '\0') { DumpMiniLinesInAscii(fp, &attr_ptr->obj->detail.t->minilines, NULL); } else { int need_to_free_tmp_buf=FALSE; MiniLineInfo *pMiniLine=attr_ptr->obj->detail.t->minilines.first; char *tmp_buf=NULL; num_found++; tmp_buf = ConvertAttrNameFirstMiniLineToString(attr_ptr, &need_to_free_tmp_buf); fprintf(fp, "%s\n", tmp_buf); for (pMiniLine=pMiniLine->next; pMiniLine != NULL; pMiniLine=pMiniLine->next) { DumpMiniLineInAscii(fp, pMiniLine, NULL); if (fprintf(fp, "\n") == EOF) writeFileFailed = TRUE; } if (need_to_free_tmp_buf) UtilFree(tmp_buf); if (fprintf(fp, "%s\n", gszAttrSeparator) == EOF) { writeFileFailed = TRUE; } } } } fclose(fp); if (writeFileFailed) { FailToWriteFileMessage(ptfi->tmp_fname); unlink(ptfi->tmp_fname); return FALSE; } if (tmpFileMode != 0 && chmod(ptfi->tmp_fname, tmpFileMode)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CHMOD), ptfi->tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(ptfi->tmp_fname); return FALSE; } if (stat(ptfi->tmp_fname, &ptfi->stat_buf) != 0) { sprintf(gszMsgBox, TgLoadString(STID_STAT_FAIL_EDIT_ATTR_VAL_SAME), ptfi->tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(ptfi->tmp_fname); return FALSE; } sprintf(gszMsgBox, TgLoadString(STID_ATTR_EXPORTED_TO_NAMED_FILE), ptfi->tmp_fname); Msg(gszMsgBox); if (pn_num_exported != NULL) *pn_num_exported = num_found; return TRUE; } static int TmpFileChanged(ptfi) TmpFileInfo *ptfi; { struct stat stat_buf; memset(&stat_buf, 0, sizeof(struct stat)); if (stat(ptfi->tmp_fname, &stat_buf) != 0) { sprintf(gszMsgBox, TgLoadString(STID_STAT_FAIL_EDIT_ATTR_VAL_SAME), ptfi->tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (stat_buf.st_mtime == ptfi->stat_buf.st_mtime && stat_buf.st_size == ptfi->stat_buf.st_size) { return FALSE; } return TRUE; } static int ReadAttrFromTmp(attr_ptr, ptfi) struct AttrRec *attr_ptr; TmpFileInfo *ptfi; { struct ObjRec *attr_owner_obj=attr_ptr->owner; FILE *fp=NULL; if ((fp=fopen(ptfi->tmp_fname, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), ptfi->tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } PrepareToReplaceAnObj(attr_owner_obj); JustReadFileIntoAttr(fp, attr_ptr, attr_owner_obj); fclose(fp); return TRUE; } static int ReadNamedAttrsFromTmp(obj_ptr, num_restricted, ppsz_restricted, ptfi) struct ObjRec *obj_ptr; int num_restricted; char **ppsz_restricted; TmpFileInfo *ptfi; { FILE *fp=NULL; int rc=0; if ((fp=fopen(ptfi->tmp_fname, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), ptfi->tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } rc = ImportNamedAttrs(fp, obj_ptr, num_restricted, ppsz_restricted, ptfi->tmp_fname); fclose(fp); return rc; } static int AbortLaunch(pVoid) void *pVoid; { if (MsgBox(TgLoadString(STID_CNTRL_C_ABORT_LAUNCH), TOOL_NAME, YNC_MB) == MB_ID_YES) { return TRUE; } return FALSE; } void EditIndexedAttrInEditor(index) int index; { int i=0, num_attrs=0, total_attrs=0; int restricted=FALSE, num_restricted=0, actual_index=0, found=FALSE; char **attr_strings=NULL, cmd[MAXSTRING<<1], title[MAXSTRING]; char **ppsz_restricted=NULL; struct AttrRec *attr_ptr=NULL, *restricted_attr=NULL; FILE *pfp=NULL; TmpFileInfo tfi; InitEditor(); if (gpEditAttrInEditorAttrInfo == NULL || topSel == NULL || topSel != botSel) { return; } for (attr_ptr=topSel->obj->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next, total_attrs++) { } attr_ptr = topSel->obj->fattr; num_attrs = gpEditAttrInEditorAttrInfo->num_attrs; attr_strings = gpEditAttrInEditorAttrInfo->attr_strings; if (total_attrs <= 0 || num_attrs <= 0 || attr_strings == NULL) return; restricted = HasEditAttrsInContextMenu(topSel->obj, &restricted_attr); if (restricted) { GetRestrictedAttrNames(restricted_attr->obj, &ppsz_restricted, &num_restricted); if (ppsz_restricted == NULL || num_restricted <= 0) { return; } } for (i=0; i < total_attrs; i++, attr_ptr=attr_ptr->next) { if (restricted) { if (!IsRestrictedAttr(attr_ptr->attr_name.s, ppsz_restricted, num_restricted)) { continue; } } if (actual_index == index) { found = TRUE; break; } actual_index++; } FreeRestrictedAttrNames(ppsz_restricted, num_restricted); if (!found) return; memset(&tfi, 0, sizeof(TmpFileInfo)); if (!WriteAttrToTmp(attr_ptr, &tfi)) return; SaveStatusStrings(); if (*attr_ptr->attr_name.s == '\0') { sprintf(title, TgLoadString(STID_EDIT_UNNAME_ATTR_DOTS)); sprintf(cmd, gszEditorCmd, title, tfi.tmp_fname); sprintf(gszMsgBox, TgLoadString(STID_EDIT_UNNAME_ATTR_WITH_CMD), cmd); } else { sprintf(title, TgLoadString(STID_EDIT_VAL_OF_ATTR_DOTS), attr_ptr->attr_name.s); sprintf(cmd, gszEditorCmd, title, tfi.tmp_fname); sprintf(gszMsgBox, TgLoadString(STID_EDIT_VAL_OF_ATTR_WITH_CMD), attr_ptr->attr_name.s, cmd); } if (!FindProgramInPath(cmd, NULL, FALSE)) { RestoreStatusStrings(); unlink(tfi.tmp_fname); return; } ShowInterrupt(DEF_CHECK_INTERVAL); SetStringStatus(gszMsgBox); EndMeasureTooltip(FALSE); if ((pfp=(FILE*)popen(cmd, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { int quit=FALSE, got_eof=FALSE, fd=fileno(pfp); Msg(TgLoadCachedString(CSTID_CNTRL_C_TO_INTR_AND_ABEND)); SetSocketBlockingState(&fd, FALSE); /* * Note: Calling WaitForEvent() with the second argument being * TRUE can lose data in the pipe. Can do this here * because the data in the pipe is ignored. */ while (WaitForEvent(pfp, TRUE, FALSE, &quit, EXPOSE_AND_ESC_X_EV_ONLY, AbortLaunch, NULL)) { if (quit) { break; } else if (PipeReachedEOF(pfp)) { got_eof = TRUE; break; } } if (quit && !got_eof) { sprintf(gszMsgBox, TgLoadString(STID_CMD_ABORT_LAUNCH_CLOSE_TOOL), cmd, TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { pclose(pfp); } } RestoreStatusStrings(); HideInterrupt(); if (TmpFileChanged(&tfi)) { HighLightReverse(); if (ReadAttrFromTmp(attr_ptr, &tfi)) { SetFileModified(TRUE); } HighLightForward(); } unlink(tfi.tmp_fname); } void EditIndexedAttrGroupInEditor(index) int index; { int num_attrs_in_attr_group=0, total_attrs_in_obj=0; int num_restricted=0, num_exported=0, done=FALSE; char **attr_name_array=NULL, cmd[MAXSTRING<<1], title[MAXSTRING]; char **ppsz_restricted=NULL; struct AttrRec *attr_ptr=NULL; FILE *pfp=NULL; TmpFileInfo tfi; InitEditor(); if (gpEditAttrInEditorAttrInfo == NULL || topSel == NULL || topSel != botSel || index >= maxAttrGroups) { return; } for (attr_ptr=topSel->obj->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next, total_attrs_in_obj++) { } attr_ptr = topSel->obj->fattr; num_attrs_in_attr_group = gAttrGroupInfo[index]->num_attrs; attr_name_array = gAttrGroupInfo[index]->attr_name; if (total_attrs_in_obj <= 0 || num_attrs_in_attr_group <= 0 || attr_name_array == NULL) { return; } /* * For this function, we do not need to call HasEditAttrsInContextMenu() * because the "edit_attrs_in_context_menu=" attribute is only for the * "Edit Attribute In Editor" submenu and *not* for the * "Edit Attribute Group In Editor" submenu. * We just pretend that the "edit_attrs_in_context_menu=" attribute is * there so we can reuse the code. */ GetAttrGroupAttrNames(topSel->obj, index, &ppsz_restricted, &num_restricted); if (ppsz_restricted == NULL || num_restricted <= 0) { return; } memset(&tfi, 0, sizeof(TmpFileInfo)); if (!WriteNamedAttrsToTmp(topSel->obj, num_restricted, ppsz_restricted, &tfi, &num_exported)) { FreeRestrictedAttrNames(ppsz_restricted, num_restricted); return; } if (num_restricted != num_exported) { sprintf(gszMsgBox, TgLoadString(STID_WARN_CANNOT_FIND_SOME_ATTRS), gAttrGroupInfo[index]->displayed_names); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) != MB_ID_YES) { FreeRestrictedAttrNames(ppsz_restricted, num_restricted); unlink(tfi.tmp_fname); return; } } SaveStatusStrings(); if (*attr_ptr->attr_name.s == '\0') { sprintf(title, TgLoadString(STID_EDIT_UNNAME_ATTR_DOTS)); sprintf(cmd, gszEditorCmd, title, tfi.tmp_fname); sprintf(gszMsgBox, TgLoadString(STID_EDIT_UNNAME_ATTR_WITH_CMD), cmd); } else { sprintf(title, TgLoadString(STID_EDIT_VAL_OF_ATTR_DOTS), attr_ptr->attr_name.s); sprintf(cmd, gszEditorCmd, title, tfi.tmp_fname); sprintf(gszMsgBox, TgLoadString(STID_EDIT_VAL_OF_ATTR_WITH_CMD), attr_ptr->attr_name.s, cmd); } if (!FindProgramInPath(cmd, NULL, FALSE)) { RestoreStatusStrings(); unlink(tfi.tmp_fname); return; } while (!done) { ShowInterrupt(DEF_CHECK_INTERVAL); SetStringStatus(gszMsgBox); EndMeasureTooltip(FALSE); if ((pfp=(FILE*)popen(cmd, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { int quit=FALSE, got_eof=FALSE, fd=fileno(pfp); Msg(TgLoadCachedString(CSTID_CNTRL_C_TO_INTR_AND_ABEND)); SetSocketBlockingState(&fd, FALSE); /* * Note: Calling WaitForEvent() with the second argument being * TRUE can lose data in the pipe. Can do this here * because the data in the pipe is ignored. */ while (WaitForEvent(pfp, TRUE, FALSE, &quit, EXPOSE_AND_ESC_X_EV_ONLY, AbortLaunch, NULL)) { if (quit) { break; } else if (PipeReachedEOF(pfp)) { got_eof = TRUE; break; } } if (quit && !got_eof) { sprintf(gszMsgBox, TgLoadString(STID_CMD_ABORT_LAUNCH_CLOSE_TOOL), cmd, TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { pclose(pfp); } } RestoreStatusStrings(); HideInterrupt(); if (TmpFileChanged(&tfi)) { HighLightReverse(); if (ReadNamedAttrsFromTmp(topSel->obj, num_restricted, ppsz_restricted, &tfi)) { done = TRUE; } else { /* get the file modified */ if (stat(tfi.tmp_fname, &tfi.stat_buf) != 0) { sprintf(gszMsgBox, TgLoadString(STID_STAT_FAIL_EDIT_ATTR_VAL_SAME), tfi.tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(tfi.tmp_fname); done = TRUE; } } HighLightForward(); } else { done = TRUE; } } unlink(tfi.tmp_fname); } TgMenu *CreateEditAttrInEditorMenu(parent_menu, X, Y, menu_info, status_str_xlated) TgMenu *parent_menu; int X, Y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=NULL; if (topSel == NULL || topSel != botSel) return NULL; FreeEditAttrInfo(gpEditAttrInEditorAttrInfo); gpEditAttrInEditorAttrInfo = NULL; gpEditAttrInEditorAttrInfo = CreateEditAttrInfo(topSel->obj); if (gpEditAttrInEditorAttrInfo == NULL) return NULL; menu = CreateAttrMenu(parent_menu, X, Y, gpEditAttrInEditorAttrInfo->num_attrs, gpEditAttrInEditorAttrInfo->attr_strings, gpEditAttrInEditorAttrInfo->status_strings, gpEditAttrInEditorAttrInfo->fore_colors); if (menu != NULL) { int i=0, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { menuitems[i].cmdid = CMDID_EDITATTRINEDITOR; } } return menu; } TgMenu *CreateEditAttrGroupInEditorMenu(parent_menu, X, Y, menu_info, status_str_xlated) TgMenu *parent_menu; int X, Y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=NULL; if (topSel == NULL || topSel != botSel) return NULL; FreeEditAttrInfo(gpEditAttrInEditorAttrInfo); gpEditAttrInEditorAttrInfo = NULL; gpEditAttrInEditorAttrInfo = CreateEditAttrGroupInfo(topSel->obj); if (gpEditAttrInEditorAttrInfo == NULL) return NULL; menu = CreateAttrMenu(parent_menu, X, Y, gpEditAttrInEditorAttrInfo->num_attrs, gpEditAttrInEditorAttrInfo->attr_strings, gpEditAttrInEditorAttrInfo->status_strings, gpEditAttrInEditorAttrInfo->fore_colors); if (menu != NULL) { int i=0, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { menuitems[i].cmdid = CMDID_EDITATTRGROUPINEDITOR; } } return menu; } void GetProperty(index) int index; { DoGetProperty(index); } TgMenu *CreateGetPropertyMenu(parent_menu, X, Y, menu_info, status_str_xlated) TgMenu *parent_menu; int X, Y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=NULL; if (topSel == NULL || topSel != botSel) return NULL; FreeEditAttrInfo(gpEditAttrInEditorAttrInfo); gpEditAttrInEditorAttrInfo = NULL; gpEditAttrInEditorAttrInfo = CreateGetPropertyInfo(); if (gpEditAttrInEditorAttrInfo == NULL) return NULL; menu = CreateAttrMenu(parent_menu, X, Y, gpEditAttrInEditorAttrInfo->num_attrs, gpEditAttrInEditorAttrInfo->attr_strings, gpEditAttrInEditorAttrInfo->status_strings, gpEditAttrInEditorAttrInfo->fore_colors); if (menu != NULL) { int i=0, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { menuitems[i].cmdid = CMDID_GETPROPERTY; } } return menu; } /* --------------------- PeekDimension stuff --------------------- */ static void SetPeekStrings(attr_strings, status_strings, i, menu_text, status_text) char **attr_strings, **status_strings; int i; char *menu_text, *status_text; { attr_strings[i] = UtilStrDup(menu_text); status_strings[i] = UtilStrDup(status_text); if (attr_strings[i] == NULL || status_strings[i] == NULL) FailAllocMessage(); } static int CanGetArea(obj_ptr) struct ObjRec *obj_ptr; { int type=obj_ptr->type; if (type == OBJ_GROUP || type == OBJ_SYM || type == OBJ_ICON || type == OBJ_PIN) { if (obj_ptr->detail.r->first == obj_ptr->detail.r->last) { return CanGetArea(obj_ptr->detail.r->first); } return FALSE; } return (type == OBJ_BOX || type == OBJ_POLYGON); } static double GetPolygonArea(polygon_ptr) struct PolygonRec *polygon_ptr; { int i=0, n=0, curved=polygon_ptr->curved; int num_smooth_points=0, num_hinge_points=0; double area=(double)0; IntPoint *vs=NULL; char *smooth=NULL; if (curved == LT_STRUCT_SPLINE) { n = polygon_ptr->ssn; vs = polygon_ptr->ssvlist; smooth = polygon_ptr->ssmooth; } else { n = polygon_ptr->n; vs = polygon_ptr->vlist; smooth = polygon_ptr->smooth; } switch (curved) { case LT_STRAIGHT: case LT_SPLINE: case LT_STRUCT_SPLINE: for (i=1; i < n; i++) { if (smooth[i]) { num_smooth_points++; } else { num_hinge_points++; } } if (num_smooth_points == 0) { for (i=0; i < n-1; i++) { area += (double)(((double)vs[i].x) * ((double)vs[i+1].y) - ((double)vs[i+1].x) * ((double)vs[i].y)); } area = area / ((double)2); } else { /* don't know how to calculate with smooth points */ } break; case LT_INTSPLINE: /* don't know how to calculate with smooth points */ break; } for (i=0; i < n-1; i++) { area += (double)(((double)vs[i].x) * ((double)vs[i+1].y) - ((double)vs[i+1].x) * ((double)vs[i].y)); } area = area / ((double)2); return area; } static double GetArea(obj_ptr) struct ObjRec *obj_ptr; { int type=obj_ptr->type, w=0, h=0; double area=(double)0, scale_x=(double)0, scale_y=(double)0; if (type == OBJ_GROUP || type == OBJ_SYM || type == OBJ_ICON || type == OBJ_PIN) { if (obj_ptr->detail.r->first == obj_ptr->detail.r->last) { return GetArea(obj_ptr->detail.r->first); } } switch (type) { case OBJ_BOX: if (obj_ptr->ctm == NULL) { w = obj_ptr->obbox.rbx-obj_ptr->obbox.ltx; h = obj_ptr->obbox.rby-obj_ptr->obbox.lty; area = (double)(((double)w)*((double)h)); } else { w = obj_ptr->orig_obbox.rbx-obj_ptr->orig_obbox.ltx; h = obj_ptr->orig_obbox.rby-obj_ptr->orig_obbox.lty; area = (double)(((double)w)*((double)h)); scale_x = (double) (((double)fabs(obj_ptr->ctm->m[CTM_SX])) / ((double)1000)); scale_y = (double) (((double)fabs(obj_ptr->ctm->m[CTM_SY])) / ((double)1000)); area = area * scale_x * scale_y; } break; case OBJ_POLYGON: area = GetPolygonArea(obj_ptr->detail.g); if (obj_ptr->ctm != NULL) { scale_x = (double) (((double)fabs(obj_ptr->ctm->m[CTM_SX])) / ((double)1000)); scale_y = (double) (((double)fabs(obj_ptr->ctm->m[CTM_SY])) / ((double)1000)); area = area * scale_x * scale_y; } break; } return area; } static EditAttrInfo *CreatePeekDimensionInfo() { EditAttrInfo *pEditAttrInfo=NULL; char **attr_strings=NULL, **status_strings=NULL; char menu_text[MAXSTRING], status_text[MAXSTRING]; char buf[MAXSTRING], buf1[MAXSTRING], *psz=NULL, *psz1=NULL; int num_attrs=10, can_get_area=FALSE; struct ObjRec *obj_ptr=NULL; if (topSel == NULL) return NULL; obj_ptr = topSel->obj; can_get_area = CanGetArea(obj_ptr); if (can_get_area) { num_attrs += 2; } pEditAttrInfo = (EditAttrInfo*)malloc(sizeof(EditAttrInfo)); if (pEditAttrInfo == NULL) FailAllocMessage(); memset(pEditAttrInfo, 0, sizeof(EditAttrInfo)); attr_strings = (char**)malloc(num_attrs*sizeof(char*)); status_strings = (char**)malloc(num_attrs*sizeof(char*)); if (attr_strings == NULL || status_strings == NULL) FailAllocMessage(); memset(attr_strings, 0, num_attrs*sizeof(char*)); memset(status_strings, 0, num_attrs*sizeof(char*)); PixelToMeasurementUnit(buf, obj_ptr->obbox.rbx-obj_ptr->obbox.ltx); PixelToMeasurementUnit(buf1, obj_ptr->bbox.rbx-obj_ptr->bbox.ltx); psz = ((*buf) == '+' ? &buf[1] : buf); psz1 = ((*buf1) == '+' ? &buf1[1] : buf1); /* do not translate -- program constants */ sprintf(menu_text, "width = %s (outer width = %s)", psz, psz1); strcpy(status_text, TgLoadString(STID_PEEK_DIM_WIDTH)); SetPeekStrings(attr_strings, status_strings, 0, menu_text, status_text); PixelToMeasurementUnit(buf, obj_ptr->obbox.rby-obj_ptr->obbox.lty); PixelToMeasurementUnit(buf1, obj_ptr->bbox.rby-obj_ptr->bbox.lty); psz = ((*buf) == '+' ? &buf[1] : buf); psz1 = ((*buf1) == '+' ? &buf1[1] : buf1); /* do not translate -- program constants */ sprintf(menu_text, "height = %s (outer height = %s)", psz, psz1); strcpy(status_text, TgLoadString(STID_PEEK_DIM_HEIGHT)); SetPeekStrings(attr_strings, status_strings, 1, menu_text, status_text); attr_strings[2] = TGMUITEM_SEPARATOR; PixelToMeasurementUnit(buf, obj_ptr->obbox.ltx); PixelToMeasurementUnit(buf1, obj_ptr->bbox.ltx); psz = ((*buf) == '+' ? &buf[1] : buf); psz1 = ((*buf1) == '+' ? &buf1[1] : buf1); /* do not translate -- program constants */ sprintf(menu_text, "left = %s (outer left = %s)", psz, psz1); strcpy(status_text, TgLoadString(STID_PEEK_DIM_LEFT)); SetPeekStrings(attr_strings, status_strings, 3, menu_text, status_text); PixelToMeasurementUnit(buf, obj_ptr->obbox.lty); PixelToMeasurementUnit(buf1, obj_ptr->bbox.lty); psz = ((*buf) == '+' ? &buf[1] : buf); psz1 = ((*buf1) == '+' ? &buf1[1] : buf1); /* do not translate -- program constants */ sprintf(menu_text, "top = %s (outer top = %s)", psz, psz1); strcpy(status_text, TgLoadString(STID_PEEK_DIM_TOP)); SetPeekStrings(attr_strings, status_strings, 4, menu_text, status_text); PixelToMeasurementUnit(buf, obj_ptr->obbox.rbx); PixelToMeasurementUnit(buf1, obj_ptr->bbox.rbx); psz = ((*buf) == '+' ? &buf[1] : buf); psz1 = ((*buf1) == '+' ? &buf1[1] : buf1); /* do not translate -- program constants */ sprintf(menu_text, "right = %s (outer right = %s)", psz, psz1); strcpy(status_text, TgLoadString(STID_PEEK_DIM_RIGHT)); SetPeekStrings(attr_strings, status_strings, 5, menu_text, status_text); PixelToMeasurementUnit(buf, obj_ptr->obbox.rby); PixelToMeasurementUnit(buf1, obj_ptr->bbox.rby); psz = ((*buf) == '+' ? &buf[1] : buf); psz1 = ((*buf1) == '+' ? &buf1[1] : buf1); /* do not translate -- program constants */ sprintf(menu_text, "bottom = %s (outer bottom = %s)", psz, psz1); strcpy(status_text, TgLoadString(STID_PEEK_DIM_BOTTOM)); SetPeekStrings(attr_strings, status_strings, 6, menu_text, status_text); attr_strings[7] = TGMUITEM_SEPARATOR; PixelToMeasurementUnit(buf, ((obj_ptr->obbox.rbx+obj_ptr->obbox.ltx)>>1)); psz = ((*buf) == '+' ? &buf[1] : buf); /* do not translate -- program constants */ sprintf(menu_text, "cx = %s", psz); strcpy(status_text, TgLoadString(STID_PEEK_DIM_CX)); SetPeekStrings(attr_strings, status_strings, 8, menu_text, status_text); PixelToMeasurementUnit(buf, ((obj_ptr->obbox.rby+obj_ptr->obbox.lty)>>1)); psz = ((*buf) == '+' ? &buf[1] : buf); /* do not translate -- program constants */ sprintf(menu_text, "cy = %s", psz); strcpy(status_text, TgLoadString(STID_PEEK_DIM_CY)); SetPeekStrings(attr_strings, status_strings, 9, menu_text, status_text); if (can_get_area) { double area=GetArea(obj_ptr); attr_strings[10] = TGMUITEM_SEPARATOR; SquarePixelToMeasurementUnit(buf, round(area)); psz = ((*buf) == '+' ? &buf[1] : buf); /* do not translate -- program constants */ sprintf(menu_text, "area = %s", psz); strcpy(status_text, TgLoadString(STID_PEEK_AREA)); SetPeekStrings(attr_strings, status_strings, 11, menu_text, status_text); } pEditAttrInfo->num_attrs = num_attrs; pEditAttrInfo->fore_colors = NULL; pEditAttrInfo->attr_indices = NULL; pEditAttrInfo->attr_names = NULL; pEditAttrInfo->attr_values = NULL; pEditAttrInfo->attr_strings = attr_strings; pEditAttrInfo->status_strings = status_strings; return pEditAttrInfo; } void PeekDimension(index) int index; { /* There's really nothing to do! */ } TgMenu *CreatePeekDimensionMenu(parent_menu, X, Y, menu_info, status_str_xlated) TgMenu *parent_menu; int X, Y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=NULL; if (topSel == NULL || topSel != botSel) return NULL; FreeEditAttrInfo(gpEditAttrInEditorAttrInfo); gpEditAttrInEditorAttrInfo = NULL; gpEditAttrInEditorAttrInfo = CreatePeekDimensionInfo(); if (gpEditAttrInEditorAttrInfo == NULL) return NULL; menu = CreateAttrMenu(parent_menu, X, Y, gpEditAttrInEditorAttrInfo->num_attrs, gpEditAttrInEditorAttrInfo->attr_strings, gpEditAttrInEditorAttrInfo->status_strings, gpEditAttrInEditorAttrInfo->fore_colors); if (menu != NULL) { int i=0, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { menuitems[i].cmdid = CMDID_GETPROPERTY; } } return menu; } /* --------------------- RefreshContextMenu() --------------------- */ int RefreshContextMenu(menu) TgMenu *menu; { int ok=TRUE; if (topSel == NULL || topSel != botSel) return FALSE; /* ImageProc submenu */ ok &= TgEnableMenuItemById(menu, MENU_IMAGEPROC, CanPerformImageProc()); /* Edit Attribute In Editor */ ok &= TgEnableMenuItemBySubMenuInfoPtr(menu, &editAttrInEditorMenuInfo, topSel->obj->fattr != NULL); /* Edit Attribute Group In Editor */ ok &= TgEnableMenuItemBySubMenuInfoPtr(menu, &editAttrGroupInEditorMenuInfo, topSel->obj->fattr != NULL && maxAttrGroups > 0); /* Get Property */ ok &= TgEnableMenuItemBySubMenuInfoPtr(menu, &getPropertyMenuInfo, !(topSel->obj->type == OBJ_XPM || (topSel->obj->type == OBJ_XBM && topSel->obj->detail.xbm->real_type==XBM_EPS))); /* Get Dimension */ ok &= TgEnableMenuItemBySubMenuInfoPtr(menu, &peekDimensionMenuInfo, topSel != NULL); return ok; } TgMenu *CreateContextMenu(parent_menu, X, Y, menu_info, status_str_xlated) TgMenu *parent_menu; int X, Y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, X, Y, menu_info, FALSE); if (menu != NULL) { if (!RefreshContextMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshContextMenu); } return menu; } int RefreshEditTextContextMenu(menu) TgMenu *menu; { int ok=TRUE; /* Copy */ ok &= TgEnableMenuItemById(menu, CMDID_COPY, textHighlight); /* CopyPlainTextAsObject */ ok &= TgEnableMenuItemById(menu, CMDID_COPYPLAINTEXTASOBJECT, (curChoice == DRAWTEXT && textHighlight)); /* Cut */ ok &= TgEnableMenuItemById(menu, CMDID_CUT, textHighlight); /* Duplicate */ ok &= TgEnableMenuItemById(menu, CMDID_DUPLICATE, textHighlight); /* Delete */ ok &= TgEnableMenuItemById(menu, CMDID_DELETE, textHighlight); return ok; } TgMenu *CreateEditTextContextMenu(parent_menu, X, Y, menu_info, status_str_xlated) TgMenu *parent_menu; int X, Y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, X, Y, menu_info, FALSE); if (menu != NULL) { if (!RefreshEditTextContextMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshContextMenu); } return menu; } int ContextMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=NULL; if (curChoice == DRAWTEXT && textCursorShown) { menu = (editTextContextMenuInfo.create_proc)(NULL, X, Y, &editTextContextMenuInfo, INVALID); } else { menu = (baseContextMenuInfo.create_proc)(NULL, X, Y, &baseContextMenuInfo, INVALID); } activeMenu = INVALID; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } void HandleMotionForPortInDrawWindow(mouse_x, mouse_y) int mouse_x, mouse_y; { int need_to_highlight=FALSE, something_changed=FALSE; struct ObjRec *owner_obj=NULL, *obj_ptr, *obj_under_cursor=NULL; char port_name[MAXSTRING]; obj_ptr = FindAnObj(mouse_x, mouse_y, &owner_obj, &obj_under_cursor, port_name); if (drawPolyHighlightedNode != NULL) { if (obj_under_cursor != drawPolyHighlightedNode) { /* un-highlight */ SelBox(drawWindow, revGrayGC, OFFSET_X(drawPolyHighlightedNode->bbox.ltx)-2, OFFSET_Y(drawPolyHighlightedNode->bbox.lty)-2, OFFSET_X(drawPolyHighlightedNode->bbox.rbx)+2, OFFSET_Y(drawPolyHighlightedNode->bbox.rby)+2); /* do not translate -- program constants */ if (obj_under_cursor != NULL && ObjIsAPort(obj_under_cursor)) { drawPolyHighlightedNode = obj_under_cursor; SetWiringNodeInfo(obj_under_cursor, owner_obj, port_name, TRUE); } else { drawPolyHighlightedNode = NULL; SetWiringNodeInfo(NULL, NULL, NULL, TRUE); } if (drawPolyHighlightedNode != NULL) { need_to_highlight = TRUE; } something_changed = TRUE; } } else if (obj_under_cursor != NULL) { if (ObjIsAPort(obj_under_cursor)) { drawPolyHighlightedNode = obj_under_cursor; SetWiringNodeInfo(obj_under_cursor, owner_obj, port_name, TRUE); } else { drawPolyHighlightedNode = NULL; SetWiringNodeInfo(NULL, NULL, NULL, TRUE); } if (drawPolyHighlightedNode != NULL) { need_to_highlight = TRUE; something_changed = TRUE; } } if (need_to_highlight) { SelBox(drawWindow, revGrayGC, OFFSET_X(drawPolyHighlightedNode->bbox.ltx)-2, OFFSET_Y(drawPolyHighlightedNode->bbox.lty)-2, OFFSET_X(drawPolyHighlightedNode->bbox.rbx)+2, OFFSET_Y(drawPolyHighlightedNode->bbox.rby)+2); } if (something_changed) { if (*gstWiringInfo.first_port_name != '\0') { char signal_name[MAXSTRING]; struct AttrRec *first_attr_ptr=FindAttrWithName( gstWiringInfo.first_port_obj, "signal_name=", NULL); *signal_name = '\0'; if (first_attr_ptr != NULL) { UtilStrCpyN(signal_name, sizeof(signal_name), first_attr_ptr->attr_value.s); } if (gstWiringInfo.num_ports_to_connect == 99) { /* rename signal_name */ SetHyperSpaceCursor(drawWindow); sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_SIGNAME_FOR_NAMED_PORT), signal_name, gstWiringInfo.first_port_name); } else if (gstWiringInfo.num_ports_to_connect == 999) { /* clear signal_name */ SetHyperSpaceCursor(drawWindow); sprintf(gszMsgBox, TgLoadCachedString(CSTID_CLEAR_SIGNAME_FOR_NAMED_PORT), signal_name, gstWiringInfo.first_port_name); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_START_A_WIRE_FROM_NAMED_PORT), gstWiringInfo.first_port_name); } SetStringStatus(gszMsgBox); } else { if (gstWiringInfo.num_ports_to_connect == 99 || gstWiringInfo.num_ports_to_connect == 999) { SetHandCursor(drawWindow); } ShowCurChoiceMouseStatus(DRAWPOLY, 0, FALSE); } } } static int motionCursorIsMoveCursor=FALSE; static void HandleMotionInDrawWindow(input) XEvent *input; { int mouse_x=0, mouse_y=0, grid_x=0, grid_y=0, cursor_is_move_cursor=FALSE; int saved_motion_cursor_is_move_cursor=motionCursorIsMoveCursor; unsigned int state=0; XEvent ev; while (XCheckWindowEvent(mainDisplay,drawWindow,PointerMotionMask,&ev)) ; state = (input->xmotion).state; mouse_x = (input->xmotion).x; mouse_y = (input->xmotion).y; GridXY(mouse_x, mouse_y, &grid_x, &grid_y); simpleMotionInDrawWin = TRUE; MarkRulers(grid_x, grid_y); simpleMotionInDrawWin = FALSE; if (curChoice == DRAWPOLY && gstWiringInfo.num_ports_to_connect > 0) { HandleMotionForPortInDrawWindow(mouse_x, mouse_y); #ifdef _NOT_DEFINED /* * drawPolyToConnectPins is only set to > 0 in "pin.c" * what's in "pin.c" is not used at this time */ } else if (curChoice == DRAWPOLY && drawPolyToConnectPins > 0) { HandlePinHighlights(mouse_x, mouse_y); if (drawPolyHighlightedNode != NULL) { gpStartPin = drawPolyHighlightedNode; } #endif /* _NOT_DEFINED */ } else if (!inHyperSpace && !btn1Warp && !(inSlideShow && !goHyperSpaceInSlideShow)) { if (curChoice == DRAWTEXT && textCursorShown && MouseInCurText(input)) { if (MouseOnCurTextBoundary(input)) { SetCurChoiceMouseStatusStrings(curChoice, FALSE, NULL, TRUE, state); cursor_is_move_cursor = TRUE; } else { SetCurChoiceMouseStatusStrings(curChoice, FALSE, curTextObj, TRUE, state); } } else { struct ObjRec *obj_ptr=NULL, *owner_obj=NULL; if ((obj_ptr=FindAnObj(mouse_x, mouse_y, &owner_obj, NULL, NULL)) != NULL) { if (owner_obj != NULL) obj_ptr = owner_obj; } ShowCursor(); SetCurChoiceMouseStatusStrings(curChoice, FALSE, obj_ptr, FALSE, state); } } else if (inHyperSpace || btn1Warp) { struct ObjRec *obj_ptr=NULL, *owner_obj=NULL; struct AttrRec *attr_ptr=NULL; if ((obj_ptr=FindAnObj(mouse_x, mouse_y, &owner_obj, NULL, NULL)) != NULL) { if (owner_obj != NULL) obj_ptr = owner_obj; /* do not translate -- program constants */ if ((attr_ptr=FindAttrWithName(obj_ptr, TELEPORT_ATTR, NULL)) != NULL || (((attr_ptr=FindAttrWithName(obj_ptr, "href=", NULL)) != NULL) && *attr_ptr->attr_value.s != '\0')) { char fname[MAXPATHLENGTH+1]; SetHyperSpaceCursor(drawWindow); if (FormNewFileName(curDir, attr_ptr->attr_value.s, (strcmp(attr_ptr->attr_name.s,TELEPORT_ATTR)==0 ? OBJ_FILE_EXT : NULL), fname, NULL)) { SetStringStatus(fname); } } else if ((allowLaunchInHyperSpace && (attr_ptr=FindAttrWithName(obj_ptr, LAUNCH_ATTR, NULL)) != NULL) || (attr_ptr=FindAttrWithName(obj_ptr, EXEC_ATTR, NULL)) != NULL) { SetHyperSpaceCursor(drawWindow); sprintf(gszMsgBox, "%s%s", attr_ptr->attr_name.s, (*attr_ptr->attr_value.s=='\0' ? "..." : attr_ptr->attr_value.s)); SetStringStatus(gszMsgBox); } else { ShowCursor(); ShowCurChoiceMouseStatus(INVALID, 0, FALSE); } } else { ShowCursor(); ShowCurChoiceMouseStatus(INVALID, 0, FALSE); } } if (cursor_is_move_cursor != saved_motion_cursor_is_move_cursor) { if (cursor_is_move_cursor) { XDefineCursor(mainDisplay, drawWindow, moveCursor); } else { ShowCursor(); } motionCursorIsMoveCursor = cursor_is_move_cursor; } } int HandlePressForPortInDrawWindow(cancel) int cancel; { if (drawPolyHighlightedNode != NULL) { /* un-highlight */ SelBox(drawWindow, revGrayGC, OFFSET_X(drawPolyHighlightedNode->bbox.ltx)-2, OFFSET_Y(drawPolyHighlightedNode->bbox.lty)-2, OFFSET_X(drawPolyHighlightedNode->bbox.rbx)+2, OFFSET_Y(drawPolyHighlightedNode->bbox.rby)+2); if (cancel) { drawPolyHighlightedNode = NULL; SetWiringNodeInfo(NULL, NULL, NULL, TRUE); } } if (cancel) { if (connectingPortsByWire) { MakeQuiescent(); Msg(TgLoadString(STID_CONNECT_PORTS_CANCEL_BY_USER)); } return FALSE; } return TRUE; } static int HandlePressInDrawWindow(input, pn_status) XEvent *input; int *pn_status; { XButtonEvent *button_ev; button_ev = &(input->xbutton); if (enableMouseWheel && (button_ev->button == Button4 || button_ev->button == Button5)) { if ((button_ev->state & METAMASK) == METAMASK) { if (button_ev->button == Button4) { ScrollLeft(button_ev); } else if (button_ev->button == Button5) { ScrollRight(button_ev); } } else { if (button_ev->button == Button4) { ScrollUp(button_ev); } else if (button_ev->button == Button5) { ScrollDown(button_ev); } } *pn_status = INVALID; return TRUE; } if ((button_ev->state & ShiftMask) && (button_ev->state & ControlMask)) { int abs_x=ABS_X(button_ev->x); int abs_y=ABS_Y(button_ev->y); if (button_ev->button == Button1) { ZoomInAtCursor(abs_x, abs_y); } else if (button_ev->button == Button2) { CenterAtCursor(abs_x, abs_y); } else if (button_ev->button == Button3) { ZoomOut(); } *pn_status = INVALID; return TRUE; } else if (button_ev->button == Button3 && (button_ev->state & ShiftMask)) { SetCurChoice(NOTHING); *pn_status = INVALID; return TRUE; } else if (button_ev->button == Button2 && curChoice == DRAWTEXT && textCursorShown) { if (((button_ev->state & ControlMask) == ControlMask && MouseInCurText(input)) || MouseOnCurTextBoundary(input)) { MoveEditText(input); *pn_status = INVALID; } else if (btn2PopupMainMenu) { *pn_status = MainMenu(); } else { *pn_status = INVALID; } return TRUE; } else if ((button_ev->button == Button2 && curChoice == NOTHING && (button_ev->state & ShiftMask)) || (inHyperSpace && button_ev->button == Button1)) { Teleport(button_ev); *pn_status = INVALID; return TRUE; } else if (button_ev->button == Button1 && curChoice == NOTHING && ((button_ev->state & (ShiftMask | ControlMask)) == 0) && btn1Warp) { Teleport(button_ev); *pn_status = INVALID; return TRUE; } else if (button_ev->button == Button1 && !inHyperSpace && !btn1Warp && !(inSlideShow && !goHyperSpaceInSlideShow) && curChoice == DRAWTEXT && textCursorShown && MouseOnCurTextBoundary(input)) { MoveEditText(input); *pn_status = INVALID; return TRUE; } else if (button_ev->button == Button2) { if (curChoice == DRAWPOLY && gstWiringInfo.num_ports_to_connect > 0) { return HandlePressForPortInDrawWindow(TRUE); } else if (btn2PopupMainMenu) { *pn_status = MainMenu(); } else { *pn_status = INVALID; } return TRUE; } else if (button_ev->button == Button3) { /* context-sensitive menu? */ if (curChoice == DRAWPOLY && gstWiringInfo.num_ports_to_connect > 0) { return HandlePressForPortInDrawWindow(TRUE); } if (btn3PopupModeMenu) { ModeMenu(button_ev->x_root, button_ev->y_root, FALSE); } else if (!inHyperSpace && !(inSlideShow && !goHyperSpaceInSlideShow)) { if (curChoice == DRAWTEXT && textCursorShown && MouseInCurText(input)) { ContextMenu(button_ev->x_root, button_ev->y_root, FALSE); } else { struct ObjRec *obj_ptr=NULL, *owner_obj=NULL; if ((obj_ptr=FindAnObj(button_ev->x, button_ev->y, &owner_obj, NULL, NULL)) != NULL) { if (owner_obj != NULL) obj_ptr = owner_obj; } if (obj_ptr == NULL) { ModeMenu(button_ev->x_root, button_ev->y_root, FALSE); } else { int obj_may_not_exist=FALSE; if (curChoice == DRAWTEXT && textCursorShown && obj_ptr == curTextObj) { obj_may_not_exist = TRUE; } if (!(topSel != NULL && topSel == botSel && topSel->obj == obj_ptr)) { TieLooseEnds(); if (obj_may_not_exist && textDrawn) { obj_may_not_exist = FALSE; } SetCurChoice(NOTHING); if (topSel != NULL) { HighLightReverse(); RemoveAllSel(); } if (obj_may_not_exist) { UpdSelBBox(); } else { AddNewSelObj(obj_ptr); UpdSelBBox(); justDupped = FALSE; HighLightForward(); } } ContextMenu(button_ev->x_root, button_ev->y_root, FALSE); } } } else if (inSlideShow) { SlideShowModeMenu(button_ev->x_root, button_ev->y_root, FALSE); } *pn_status = INVALID; return TRUE; } return FALSE; } int DrawingEventHandler(input) XEvent *input; { XEvent ev; if (input->type == Expose) { XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, drawWindow, ExposureMask, &ev)) ; if (topSel != NULL || curChoice == VERTEXMODE || SomethingDirty()) { ClearAndRedrawDrawWindow(); } else { RedrawDrawWindow(botObj); ResetDirtyBBoxInfo(); RedrawCurText(); } return INVALID; } else if (input->type == ClientMessage) { if (curChoice == DRAWTEXT && canvasFontDoubleByte && textCursorShown && tgIMExpectClientMessage(mainDisplay, drawWindow)) { if (tgIMHandleClientMessage(mainDisplay, drawWindow, (XClientMessageEvent*)input, NULL, NULL)) { } } return INVALID; } else if (input->type == EnterNotify) { if (input->xcrossing.mode == NotifyNormal) { RestoreDrawWinDrawTextInfo(FALSE); if (curChoice == DRAWTEXT && textCursorShown) { tgIMFocusIn(mainDisplay, drawWindow); } } ShowCurChoiceMouseStatus(curChoice, 0, FALSE); return INVALID; } else if (input->type == LeaveNotify) { EndMeasureTooltip(FALSE); if (input->xcrossing.mode == NotifyNormal) { SaveDrawWinDrawTextInfo(FALSE); if (curChoice == DRAWTEXT && textCursorShown) { tgIMFocusOut(mainDisplay, drawWindow); } } return INVALID; } else if (input->type == MotionNotify) { HandleMotionInDrawWindow(input); return INVALID; } if (input->type == ButtonPress) { int rc=INVALID; EndMeasureTooltip(FALSE); if (HandlePressInDrawWindow(input, &rc)) { return rc; } Msg(""); } if (input->type == KeyPress && inSlideShow && !goHyperSpaceInSlideShow) { XKeyEvent *key_ev=(&(input->xkey)); KeySym key_sym=(KeySym)0; char buf[80]; int has_ch=XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); TranslateKeys(buf, &key_sym); if (CharIsESC(key_ev, buf, key_sym, &has_ch)) { LeaveSlideShow(); return INVALID; } else if (CharIsCRorLF(key_ev, buf, key_sym, &has_ch)) { /* * For now, this only goes to the next page. In the future, * this would single step. */ NextSlide(); return INVALID; } else if (key_sym == XK_Left || key_sym == XK_KP_Left || key_sym == XK_Up || key_sym == XK_KP_Up || key_sym == XK_Right || key_sym == XK_KP_Right || key_sym == XK_Down || key_sym == XK_KP_Down) { switch (key_sym) { case XK_Left: PrevSlide(); break; case XK_KP_Left: PrevSlide(); break; case XK_Up: PrevSlide(); break; case XK_KP_Up: PrevSlide(); break; case XK_Right: NextSlide(); break; case XK_KP_Right: NextSlide(); break; case XK_Down: NextSlide(); break; case XK_KP_Down: NextSlide(); break; } return INVALID; } else if (key_sym == XK_Page_Up || key_sym == XK_KP_Page_Up || key_sym == XK_Page_Down || key_sym == XK_KP_Page_Down) { switch (key_sym) { case XK_Page_Up: PrevSlide(); break; case XK_KP_Page_Up: PrevSlide(); break; case XK_Page_Down: NextSlide(); break; case XK_KP_Page_Down: NextSlide(); break; } return INVALID; } } switch(curChoice) { case NOTHING: Select(input); break; case DRAWTEXT: DrawText(input); break; case DRAWBOX: DrawBox(input); break; case DRAWCORNEROVAL: DrawOval(input); break; case DRAWCENTEROVAL: DrawOval(input); break; case DRAWEDGECIRCLE: DrawOval(input); break; case DRAWPOLY: DrawPoly(input); break; case DRAWPOLYGON: DrawPolygon(input); break; case DRAWARC: DrawArc(input); break; case DRAWEDGEARC: DrawArc(input); break; case DRAWRCBOX: DrawRCBox(input); break; case FREEHAND: DrawPoly(input); break; case VERTEXMODE: Select(input); break; case ROTATEMODE: Select(input); break; } return INVALID; } ������������������������������������������������������������������������tgif-QPL-4.2.5/pattern.c����������������������������������������������������������������������������0000644�0000764�0000764�00000257335�11602233312�014624� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/pattern.c,v 1.26 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_PATTERN_C_ #include "tgifdefs.h" #include "cmdids.h" #include "arc.e" #include "choice.e" #include "color.e" #include "cmd.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "file.e" #include "font.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "menuinfo.e" #include "miniline.e" #include "msg.e" #include "navigate.e" #include "obj.e" #include "pattern.e" #include "poly.e" #include "raster.e" #include "select.e" #include "setup.e" #include "spline.e" #include "strtbl.e" #include "text.e" #include "util.e" int objFill=NONEPAT; int transPat=FALSE; int lineStyle=LS_RIGHT; int lineWidth=0; int penPat=SOLIDPAT; int curSpline=LT_STRAIGHT; int curDash=0; int rcbRadius=DEF_RCB_RADIUS; int useGray=FALSE; char patternStr[]="8 1 0 72 300 32 div div tgifsetpattern"; int stickyMenuSelection=FALSE; static int tileAsGrayDetected=FALSE; static int canFakeGray=FALSE; static char *grayStr[9] = { "0.995", "0.94", "0.868", "0.779", "0.763", "0.55", "0.41", "0.253", "0.079" }; void ResetGrayDetection() { tileAsGrayDetected = FALSE; canFakeGray = FALSE; } char *GrayStr(index) int index; /* this routine should only be called when useGray == TRUE */ { if (index <= 2) { fprintf(stderr, "%s\n", TgLoadCachedString(CSTID_GRAYSTR_CALLED_WITH_IDX_2)); return(""); } else if (index >= 12) { if (!tileAsGrayDetected) { char buf[MAXSTRING]; tileAsGrayDetected = TRUE; strcpy(buf, TgLoadCachedString(CSTID_GRAY_SCALE_USED_FOR_PAT)); if (PRTGIF) { fprintf(stderr, "%s.\n", buf); } else { MsgBox(buf, TOOL_NAME, INFO_MB); } } switch (index) { case 12: index = 5; break; case 13: index = 4; break; case 14: index = 7; break; case 15: index = 6; break; case 16: index = 7; break; case 17: index = 6; break; case 18: index = 6; break; case 19: index = 6; break; case 20: index = 5; break; case 21: index = 6; break; case 22: index = 8; break; case 23: index = 7; break; case 24: index = 9; break; case 25: index = 8; break; case 26: index = 5; break; case 27: index = 6; break; case 28: index = 8; break; case 29: index = 7; break; case 30: index = 9; break; case 31: index = 8; break; } } return (grayStr[index-3]); } void GrayCheck(index) int index; /* this routine should only be called when useGray == FALSE */ { if (index > BACKPAT) { if (index >= 12) { tileAsGrayDetected = TRUE; } else { canFakeGray = TRUE; } } } void EndGrayDetection() /* this routine should only be called when useGray == FALSE */ { int num_msgs = 1; char msg1[MAXSTRING], msg2[MAXSTRING]; if (colorDump) return; if (useGray) { if (!tileAsGrayDetected && !canFakeGray) return; strcpy(msg1, TgLoadString(STID_GRAY_SCALE_USED_IN_PRINT_PAT)); } else if (tileAsGrayDetected) { strcpy(msg1, TgLoadString(STID_NOTE_SLOW_PRINT_DUE_USE_PAT)); } else if (canFakeGray) { num_msgs = 2; strcpy(msg1, TgLoadString(STID_NOTE_SLOW_PRINT_DUE_USE_PAT)); sprintf(msg2, " %s", TgLoadString(STID_SUGGEST_USEGRAYSCALE_TO_SPEED)); } else { return; } if (PRTGIF) { fprintf(stderr, "%s.\n", msg1); if (num_msgs==2) fprintf(stderr, "%s.\n", msg2); } else { if (num_msgs==1) { Msg(msg1); } else { TwoLineMsg(msg1, msg2); } } } int RefreshModeMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items, rc=TRUE; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == curChoice); if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem)) { rc = FALSE; } } if (inSlideShow && !goHyperSpaceInSlideShow) { TgEnableMenuItemByIndex(menu, NOTHING, FALSE); TgEnableMenuItemByIndex(menu, VERTEXMODE, FALSE); TgEnableMenuItemByIndex(menu, ROTATEMODE, FALSE); } return rc; } TgMenu *CreateModeMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = FALSE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, MAXCHOICES); menu_item = (&menu->menuitems[curChoice]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } if (!RefreshModeMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshModeMenu); } return menu; } int ModeMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(modeMenuInfo.create_proc)(NULL, X, Y, &modeMenuInfo, INVALID); activeMenu = MENU_MODE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } /* ------------------ TransPat Functions ------------------ */ int ChangeObjTransPat(ObjPtr, TransPat) struct ObjRec *ObjPtr; int TransPat; { if (ObjPtr->trans_pat != TransPat) { ObjPtr->trans_pat = TransPat; return TRUE; } return FALSE; } void ChangeAllSelTransPat(TransPat, HighLight) int TransPat, HighLight; { struct SelRec *sel_ptr=NULL; int changed=FALSE, ltx=selLtX, lty=selLtY, rbx=selRbX, rby=selRbY; if (topSel == NULL || stickyMenuSelection) { if (!(curChoice == DRAWTEXT && textCursorShown)) { TieLooseEnds(); } transPat = TransPat; if (curChoice == DRAWTEXT && textCursorShown) { if (ChangeObjTransPat(curTextObj, TransPat)) { curTextModified = TRUE; UpdCurTextBBox(); RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_TRANSPAT, transPat); } } } else { textCursorShown = FALSE; } if (topSel == NULL) { switch (transPat) { case NO_TRANSPAT_MODE: Msg(TgLoadString(STID_FILL_PEN_PAT_OPAQUE)); break; case TRANSPAT_MODE: Msg(TgLoadString(STID_FILL_PEN_PAT_TRANSPARENT)); break; } } ShowTransPatMode(); UpdatePinnedMenu(MENU_TRANSPAT); if (topSel == NULL) return; } if (HighLight) HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjTransPat(sel_ptr->obj, TransPat)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } if (HighLight) HighLightForward(); } /* ------------------ Fill Functions ------------------ */ int ChangeObjFill(ObjPtr, FillIndex) struct ObjRec *ObjPtr; int FillIndex; { register struct ObjRec *obj_ptr; int changed=FALSE; switch (ObjPtr->type) { case OBJ_TEXT: if (ObjPtr->detail.t->fill != FillIndex) { ObjPtr->detail.t->fill = FillIndex; changed = TRUE; } break; case OBJ_BOX: if (ObjPtr->detail.b->fill != FillIndex) { ObjPtr->detail.b->fill = FillIndex; changed = TRUE; } break; case OBJ_OVAL: if (ObjPtr->detail.o->fill != FillIndex) { ObjPtr->detail.o->fill = FillIndex; changed = TRUE; } break; case OBJ_POLY: if (ObjPtr->detail.p->fill != FillIndex) { ObjPtr->detail.p->fill = FillIndex; changed = TRUE; } break; case OBJ_POLYGON: if (ObjPtr->detail.g->fill != FillIndex) { ObjPtr->detail.g->fill = FillIndex; changed = TRUE; } break; case OBJ_ARC: if (ObjPtr->detail.a->fill != FillIndex) { if (ObjPtr->detail.a->fill == NONEPAT || FillIndex == NONEPAT) { ObjPtr->detail.a->fill = FillIndex; AdjObjBBox(ObjPtr); } else { ObjPtr->detail.a->fill = FillIndex; } changed = TRUE; } break; case OBJ_RCBOX: if (ObjPtr->detail.rcb->fill != FillIndex) { ObjPtr->detail.rcb->fill = FillIndex; changed = TRUE; } break; case OBJ_XBM: if (ObjPtr->detail.xbm->fill != FillIndex) { ObjPtr->detail.xbm->fill = FillIndex; changed = TRUE; } break; case OBJ_XPM: if (ObjPtr->detail.xpm->fill != FillIndex) { ObjPtr->detail.xpm->fill = FillIndex; changed = TRUE; } break; case OBJ_SYM: case OBJ_GROUP: for (obj_ptr = ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { if (ChangeObjFill(obj_ptr, FillIndex)) { changed = TRUE; } } break; } if (changePropertiesOfAttrs && ObjPtr->type != OBJ_TEXT) { struct AttrRec *attr_ptr=ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { changed |= ChangeObjFill(attr_ptr->obj, FillIndex); } } return changed; } void ChangeAllSelFill(FillIndex, HighLight) int FillIndex, HighLight; { register struct SelRec *sel_ptr; int changed=FALSE, ltx, lty, rbx, rby; if (topSel == NULL || stickyMenuSelection) { if (!(curChoice == DRAWTEXT && textCursorShown)) { TieLooseEnds(); } objFill = FillIndex; if (curChoice == DRAWTEXT && textCursorShown) { if (ChangeObjFill(curTextObj, FillIndex)) { curTextModified = TRUE; UpdCurTextBBox(); RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_FILL, objFill); } } } else { textCursorShown = FALSE; } ShowFill(); UpdatePinnedMenu(MENU_FILL); if (topSel == NULL) return; } if (HighLight) HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjFill(sel_ptr->obj, FillIndex)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } if (HighLight) HighLightForward(); } void RefreshFillMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == objFill); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateFillMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { int i=0; TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); stMenuInfo.items = (TgMenuItemInfo*)malloc( (MAXPATTERNS+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (MAXPATTERNS+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < MAXPATTERNS; item_info++, i++) { item_info->menu_str = (char*)(Pixmap*)(&patPixmap[i]); item_info->shortcut_str = NULL; switch (i) { case NONEPAT: strcpy(gszMsgBox, TgLoadCachedString(CSTID_SET_FILL_TO_NONE)); break; case SOLIDPAT: strcpy(gszMsgBox, TgLoadCachedString(CSTID_SET_FILL_TO_SOLID)); break; case BACKPAT: strcpy(gszMsgBox, TgLoadCachedString(CSTID_SET_FILL_TO_BACKGROUND)); break; default: sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_FILL_TO_PAT_NUMBER), i); break; } item_info->status_str = UtilStrDup(gszMsgBox); if (item_info->status_str == NULL) FailAllocMessage(); item_info->submenu_info = NULL; item_info->cmdid = CMDID_CHANGEALLSELFILL; } stMenuInfo.items[MAXPATTERNS].cmdid = INVALID; /* the status_str has been translated in TgLoadCachedString() */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < MAXPATTERNS; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (MAXPATTERNS+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, 8); menu_item = (&menu->menuitems[objFill]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int FillMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(fillMenuInfo.create_proc)(NULL, X, Y, &fillMenuInfo, INVALID); activeMenu = MENU_FILL; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } /* ------------------ LineStyle Functions ------------------ */ static int ChangeObjLineStyle(ObjPtr, StyleIndex) struct ObjRec *ObjPtr; int StyleIndex; { register struct ObjRec *obj_ptr; register int changed=FALSE; switch (ObjPtr->type) { case OBJ_POLY: if (ObjPtr->detail.p->style != StyleIndex) { ObjPtr->detail.p->style = StyleIndex; changed = TRUE; AdjObjSplineVs(ObjPtr); if (ObjPtr->detail.p->curved != LT_INTSPLINE) { UpdPolyBBox(ObjPtr, ObjPtr->detail.p->n, ObjPtr->detail.p->vlist); } else { UpdPolyBBox(ObjPtr, ObjPtr->detail.p->intn, ObjPtr->detail.p->intvlist); } } break; case OBJ_ARC: if (ObjPtr->detail.a->style != StyleIndex) { ObjPtr->detail.a->style = StyleIndex; changed = TRUE; AdjObjSplineVs(ObjPtr); } break; case OBJ_GROUP: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjLineStyle(obj_ptr, StyleIndex)) { changed = TRUE; } } break; } if (changed) AdjObjBBox(ObjPtr); return changed; } void ChangeAllSelLineStyle(StyleIndex, HighLight) int StyleIndex, HighLight; { register struct SelRec *sel_ptr; int ltx, lty, rbx, rby, changed=FALSE; if (topSel == NULL || stickyMenuSelection) { lineStyle = StyleIndex; ShowLineStyle(); UpdatePinnedMenu(MENU_LINESTYLE); if (topSel == NULL) return; } if (HighLight) HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjLineStyle(sel_ptr->obj, StyleIndex)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } if (HighLight) HighLightForward(); } void RefreshLineStyleMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == lineStyle); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateLineStyleMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, menuImageW, menuImageH, MAXLINESTYLES); menu_item = (&menu->menuitems[lineStyle]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int LineStyleMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(lineStyleMenuInfo.create_proc)(NULL, X, Y, &lineStyleMenuInfo, INVALID); activeMenu = MENU_LINESTYLE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } /* ------------------ LineType Functions ------------------ */ int GetPolyOrPolygonControlPoints(obj_ptr, pp_poly, pp_polygon, pn_curved, pn_num_pts, pp_ip, ppsz_smooth) struct ObjRec *obj_ptr; struct PolyRec **pp_poly; struct PolygonRec **pp_polygon; int *pn_curved, *pn_num_pts; IntPoint **pp_ip; char **ppsz_smooth; { struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; *pn_curved = poly_ptr->curved; if ((*pn_curved) == LT_STRUCT_SPLINE) { *pn_num_pts = poly_ptr->ssn; *pp_ip = poly_ptr->ssvlist; *ppsz_smooth = poly_ptr->ssmooth; } else { *pn_num_pts = poly_ptr->n; *pp_ip = poly_ptr->vlist; *ppsz_smooth = poly_ptr->smooth; } break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; *pn_curved = polygon_ptr->curved; if ((*pn_curved) == LT_STRUCT_SPLINE) { *pn_num_pts = polygon_ptr->ssn; *pp_ip = polygon_ptr->ssvlist; *ppsz_smooth = polygon_ptr->ssmooth; } else { *pn_num_pts = polygon_ptr->n; *pp_ip = polygon_ptr->vlist; *ppsz_smooth = polygon_ptr->smooth; } break; default: return FALSE; } if (pp_poly != NULL) *pp_poly = poly_ptr; if (pp_polygon != NULL) *pp_polygon = polygon_ptr; return TRUE; } static int CanConvertSplineToStructuredSpline(ObjPtr, pn_hinge_count, vlist_updated) struct ObjRec *ObjPtr; int *pn_hinge_count; IntPoint *vlist_updated; /* * returns TRUE means that conversion will be made (and something * will change) */ { int i=0, last_hinge_index=0, hinge_count=1, num_ss_pts=0; struct PolyRec *poly_ptr=NULL; int curved=(-1), n=0, earlier_smooth=FALSE; IntPoint *vs=NULL; char *smooth=NULL; if (!GetPolyOrPolygonControlPoints(ObjPtr, &poly_ptr, NULL, &curved, &n, &vs, &smooth)) { return FALSE; } if (vlist_updated != NULL) { num_ss_pts = ((*pn_hinge_count)*3)-2; vlist_updated[0].x = vs[0].x; vlist_updated[0].y = vs[0].y; vlist_updated[num_ss_pts-1].x = vs[n-1].x; vlist_updated[num_ss_pts-1].y = vs[n-1].y; } for (i=1; i < n; i++) { if (smooth == NULL || !smooth[i]) { int idx=0; hinge_count++; switch (i-last_hinge_index) { case 3: if (last_hinge_index == 0) { /* the first point can be anything, so still okay */ if (vlist_updated != NULL) { vlist_updated[1].x = vs[1].x; vlist_updated[1].y = vs[1].y; } } else if (earlier_smooth) { if ((vs[last_hinge_index].x<<1) == (vs[last_hinge_index-1].x+vs[last_hinge_index+1].x) && (vs[last_hinge_index].y<<1) == (vs[last_hinge_index-1].y+vs[last_hinge_index+1].y)) { /* still okay */ if (vlist_updated != NULL) { idx = (hinge_count-2)*3; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert( vlist_updated[idx-1].x==vs[last_hinge_index-1].x && vlist_updated[idx-1].y==vs[last_hinge_index-1].y && vlist_updated[idx].x==vs[last_hinge_index].x && vlist_updated[idx].y==vs[last_hinge_index].y, "check #1 failed in CanConvertSplineToStructuredSpline()", NULL); #endif /* _TGIF_DBG */ vlist_updated[idx+1].x = vs[last_hinge_index+1].x; vlist_updated[idx+1].y = vs[last_hinge_index+1].y; } } else { return FALSE; } } else { return FALSE; } earlier_smooth = TRUE; if (vlist_updated != NULL) { idx = (hinge_count-1)*3; vlist_updated[idx-1].x = vs[i-1].x; vlist_updated[idx-1].y = vs[i-1].y; vlist_updated[idx].x = vs[i].x; vlist_updated[idx].y = vs[i].y; } break; case 2: if (last_hinge_index == 0) { /* it can go either way */ if (i == n-1) { /* still can go either way */ earlier_smooth = TRUE; if (vlist_updated != NULL) { vlist_updated[1].x = vs[0].x; vlist_updated[1].y = vs[0].y; } } else if (smooth != NULL && smooth[i+1]) { if ((vs[i].x<<1) == (vs[i-1].x+vs[i+1].x) && (vs[i].y<<1) == (vs[i-1].y+vs[i+1].y)) { /* still okay */ earlier_smooth = TRUE; if (vlist_updated != NULL) { vlist_updated[1].x = vs[0].x; vlist_updated[1].y = vs[0].y; } } else { /* still okay */ earlier_smooth = FALSE; } } else { /* still okay */ earlier_smooth = FALSE; } if (vlist_updated != NULL) { idx = (hinge_count-2)*3; if (!earlier_smooth) { vlist_updated[idx+1].x = vs[i-1].x; vlist_updated[idx+1].y = vs[i-1].y; } } } else if (earlier_smooth) { if ((vs[last_hinge_index].x<<1) == (vs[last_hinge_index-1].x+vs[last_hinge_index+1].x) && (vs[last_hinge_index].y<<1) == (vs[last_hinge_index-1].y+vs[last_hinge_index+1].y)) { /* still okay */ earlier_smooth = FALSE; if (vlist_updated != NULL) { idx = (hinge_count-2)*3; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert( vlist_updated[idx-1].x==vs[last_hinge_index-1].x && vlist_updated[idx-1].y==vs[last_hinge_index-1].y && vlist_updated[idx].x==vs[last_hinge_index].x && vlist_updated[idx].y==vs[last_hinge_index].y, "check #2 failed in CanConvertSplineToStructuredSpline()", NULL); #endif /* _TGIF_DBG */ vlist_updated[idx+1].x = vs[last_hinge_index+1].x; vlist_updated[idx+1].y = vs[last_hinge_index+1].y; } } else { return FALSE; } } else { /* still okay */ if (vlist_updated != NULL) { idx = (hinge_count-2)*3; vlist_updated[idx+1].x = vlist_updated[idx].x; vlist_updated[idx+1].y = vlist_updated[idx].y; } earlier_smooth = TRUE; } if (vlist_updated != NULL) { idx = (hinge_count-1)*3; if (earlier_smooth) { vlist_updated[idx-1].x = vs[i-1].x; vlist_updated[idx-1].y = vs[i-1].y; } else { vlist_updated[idx-1].x = vs[i].x; vlist_updated[idx-1].y = vs[i].y; } vlist_updated[idx].x = vs[i].x; vlist_updated[idx].y = vs[i].y; } break; case 1: if (earlier_smooth) { return FALSE; } if (vlist_updated != NULL) { idx = (hinge_count-2)*3; vlist_updated[idx+1].x = vs[last_hinge_index].x; vlist_updated[idx+1].y = vs[last_hinge_index].y; idx = (hinge_count-1)*3; vlist_updated[idx-1].x = vs[i].x; vlist_updated[idx-1].y = vs[i].y; vlist_updated[idx].x = vs[i].x; vlist_updated[idx].y = vs[i].y; } break; default: /* too many consecutive smooth points */ return FALSE; } last_hinge_index = i; } } if (pn_hinge_count != NULL && vlist_updated == NULL) { *pn_hinge_count = hinge_count; } return TRUE; } static int CanConvertClosedSplineToStructuredSpline(ObjPtr, pn_hinge_count, vlist_updated) struct ObjRec *ObjPtr; int *pn_hinge_count; IntPoint *vlist_updated; /* * returns TRUE means that conversion will be made (and something * will change) */ { int i=0, last_hinge_index=0, hinge_count=1, num_ss_pts=0; struct PolygonRec *polygon_ptr=NULL; int curved=(-1), n=0, earlier_smooth=FALSE; IntPoint *vs=NULL; char *smooth=NULL; if (!GetPolyOrPolygonControlPoints(ObjPtr, NULL, &polygon_ptr, &curved, &n, &vs, &smooth)) { return FALSE; } if (vlist_updated != NULL) { num_ss_pts = ((*pn_hinge_count)*3)-2; vlist_updated[0].x = vs[0].x; vlist_updated[0].y = vs[0].y; vlist_updated[num_ss_pts-1].x = vs[n-1].x; vlist_updated[num_ss_pts-1].y = vs[n-1].y; } for (i=1; i < n; i++) { if (smooth == NULL || !smooth[i]) { int idx=0; hinge_count++; switch (i-last_hinge_index) { case 3: if (last_hinge_index == 0) { if (smooth != NULL && smooth[n-2]) { if ((vs[0].x<<1) == (vs[n-2].x+vs[1].x) && (vs[0].y<<1) == (vs[n-2].y+vs[1].y)) { /* still okay */ if (vlist_updated != NULL) { idx = (*pn_hinge_count)*3-3; vlist_updated[1].x = vs[1].x; vlist_updated[1].y = vs[1].y; vlist_updated[idx-1].x = vs[n-2].x; vlist_updated[idx-1].y = vs[n-2].y; } } else { return FALSE; } } else { return FALSE; } } else if (earlier_smooth) { if ((vs[last_hinge_index].x<<1) == (vs[last_hinge_index-1].x+vs[last_hinge_index+1].x) && (vs[last_hinge_index].y<<1) == (vs[last_hinge_index-1].y+vs[last_hinge_index+1].y)) { /* still okay */ if (vlist_updated != NULL) { idx = (hinge_count-2)*3; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert( vlist_updated[idx-1].x==vs[last_hinge_index-1].x && vlist_updated[idx-1].y==vs[last_hinge_index-1].y && vlist_updated[idx].x==vs[last_hinge_index].x && vlist_updated[idx].y==vs[last_hinge_index].y, "check #1 failed in CanConvertClosedSplineToStructuredSpline()", NULL); #endif /* _TGIF_DBG */ vlist_updated[idx+1].x = vs[last_hinge_index+1].x; vlist_updated[idx+1].y = vs[last_hinge_index+1].y; } } else { return FALSE; } } else { return FALSE; } earlier_smooth = TRUE; if (vlist_updated != NULL) { idx = (hinge_count-1)*3; vlist_updated[idx-1].x = vs[i-1].x; vlist_updated[idx-1].y = vs[i-1].y; vlist_updated[idx].x = vs[i].x; vlist_updated[idx].y = vs[i].y; } if (i == n-1) { if (smooth != NULL && smooth[1]) { if ((vs[0].x<<1) == (vs[n-2].x+vs[1].x) && (vs[0].y<<1) == (vs[n-2].y+vs[1].y)) { /* still okay */ } else { return FALSE; } } else { return FALSE; } } break; case 2: if (last_hinge_index == 0) { /* it can go either way */ if (smooth != NULL && smooth[i+1]) { if ((vs[i].x<<1) == (vs[i-1].x+vs[i+1].x) && (vs[i].y<<1) == (vs[i-1].y+vs[i+1].y)) { /* still okay */ earlier_smooth = TRUE; if (vlist_updated != NULL) { vlist_updated[1].x = vs[0].x; vlist_updated[1].y = vs[0].y; idx = (hinge_count-1)*3; vlist_updated[idx-1].x = vs[i-1].x; vlist_updated[idx-1].y = vs[i-1].y; vlist_updated[idx].x = vs[i].x; vlist_updated[idx].y = vs[i].y; } } else { /* still okay */ if (smooth != NULL && smooth[n-2]) { if ((vs[0].x<<1) == (vs[n-2].x+vs[1].x) && (vs[0].y<<1) == (vs[n-2].y+vs[1].y)) { /* still okay */ } else { return FALSE; } } else { return FALSE; } earlier_smooth = FALSE; } } else { /* still okay */ earlier_smooth = FALSE; } } else if (earlier_smooth) { if ((vs[last_hinge_index].x<<1) == (vs[last_hinge_index-1].x+vs[last_hinge_index+1].x) && (vs[last_hinge_index].y<<1) == (vs[last_hinge_index-1].y+vs[last_hinge_index+1].y)) { /* still okay */ earlier_smooth = FALSE; } else { return FALSE; } } else { /* still okay */ earlier_smooth = TRUE; if (i == n-1) { if (smooth != NULL && smooth[1]) { if ((vs[0].x<<1) == (vs[n-2].x+vs[1].x) && (vs[0].y<<1) == (vs[n-2].y+vs[1].y)) { /* still okay */ } else { return FALSE; } } else { return FALSE; } } } if (vlist_updated != NULL) { idx = (hinge_count-1)*3; if (earlier_smooth) { vlist_updated[idx-1].x = vs[i-1].x; vlist_updated[idx-1].y = vs[i-1].y; } else { vlist_updated[idx-1].x = vs[i].x; vlist_updated[idx-1].y = vs[i].y; } vlist_updated[idx].x = vs[i].x; vlist_updated[idx].y = vs[i].y; } break; case 1: if (earlier_smooth) { return FALSE; } if (vlist_updated != NULL) { idx = (hinge_count-2)*3; vlist_updated[idx+1].x = vs[last_hinge_index].x; vlist_updated[idx+1].y = vs[last_hinge_index].y; idx = (hinge_count-1)*3; vlist_updated[idx-1].x = vs[i].x; vlist_updated[idx-1].y = vs[i].y; vlist_updated[idx].x = vs[i].x; vlist_updated[idx].y = vs[i].y; } break; default: /* too many consecutive smooth points */ return FALSE; } last_hinge_index = i; } } if (last_hinge_index == 0) { return FALSE; } if (pn_hinge_count != NULL && vlist_updated == NULL) { *pn_hinge_count = hinge_count; } return TRUE; } static int CanConvertObjLineType(ObjPtr, TypeIndex, pn_failed_count, pn_hinge_count) struct ObjRec *ObjPtr; int TypeIndex, *pn_failed_count, *pn_hinge_count; /* * returns FALSE if ObjPtr has the same line type as TypeIndex or * if there is no way to make the conversion (for example, * from spline to structured spline where the smooth vertices * are not all at the right places); this object will not change * in this case * returns TRUE means that conversion will be made (and something * will change) */ { int i=0; int curved=(-1), n=0; IntPoint *vs=NULL; char *smooth=NULL; if (!GetPolyOrPolygonControlPoints(ObjPtr, NULL, NULL, &curved, &n, &vs, &smooth)) { return FALSE; } switch (TypeIndex) { case LT_STRAIGHT: if (curved == LT_INTSPLINE) return TRUE; if (curved == LT_STRUCT_SPLINE) return TRUE; if (curved == LT_STRAIGHT && smooth == NULL) return FALSE; if (curved == LT_SPLINE && smooth == NULL) return TRUE; switch (ObjPtr->type) { case OBJ_POLY: for (i=1; i < n-1; i++) if (smooth[i]) return TRUE; break; case OBJ_POLYGON: for (i=0; i < n; i++) if (smooth[i]) return TRUE; break; } return FALSE; case LT_SPLINE: if (curved == LT_INTSPLINE) return TRUE; if (curved == LT_STRUCT_SPLINE) return TRUE; if (curved == LT_STRAIGHT && smooth == NULL) return TRUE; if (curved == LT_SPLINE && smooth == NULL) return FALSE; switch (ObjPtr->type) { case OBJ_POLY: for (i=1; i < n-1; i++) if (!smooth[i]) return TRUE; break; case OBJ_POLYGON: for (i=0; i < n; i++) if (!smooth[i]) return TRUE; break; } return FALSE; case LT_INTSPLINE: if (curved == LT_INTSPLINE) return FALSE; if (curved == LT_STRUCT_SPLINE) { int min_num_vertices=0, max_vs_to_check=n, count=1; if (ObjPtr->type == OBJ_POLY) { min_num_vertices = 2; } else { /* ObjPtr->type is OBJ_POLYGON */ min_num_vertices = 4; } if (smooth == NULL) { if (n < min_num_vertices) { (*pn_failed_count)++; return FALSE; } } else { for (i=1; i < max_vs_to_check; i++) { if (!smooth[i]) count++; } if (count < min_num_vertices) { (*pn_failed_count)++; return FALSE; } } } return TRUE; case LT_STRUCT_SPLINE: if (curved == LT_INTSPLINE) { if (pn_hinge_count != NULL) *pn_hinge_count = n; return TRUE; } if (curved == LT_STRUCT_SPLINE) return FALSE; if (curved == LT_STRAIGHT && smooth == NULL) { if (pn_hinge_count != NULL) *pn_hinge_count = n; return TRUE; } if (curved == LT_SPLINE && smooth == NULL) return FALSE; switch (ObjPtr->type) { case OBJ_POLY: if (!CanConvertSplineToStructuredSpline(ObjPtr, pn_hinge_count, NULL)) { (*pn_failed_count)++; return FALSE; } break; case OBJ_POLYGON: if (!CanConvertClosedSplineToStructuredSpline(ObjPtr, pn_hinge_count, NULL)) { (*pn_failed_count)++; return FALSE; } break; } break; } return TRUE; } static IntPoint *GetNumUsableStraightVs(pn_num_usable_vs, num_pts, vs) int *pn_num_usable_vs, num_pts; IntPoint *vs; { int i=0, index=1, x=0, y=0; IntPoint *pv=(IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); memset(pv, 0, num_pts*sizeof(IntPoint)); x = pv[0].x = vs[0].x; y = pv[0].y = vs[0].y; for (i=1; i < num_pts; i++) { if (vs[i].x != x || vs[i].y != y) { x = pv[index].x = vs[i].x; y = pv[index].y = vs[i].y; index++; } } if (index == 1) { *pn_num_usable_vs = 0; free(pv); return NULL; } *pn_num_usable_vs = index; return pv; } static IntPoint *GetNumUsableSplineVs(pn_num_usable_vs, ppsz_smooth, num_pts, vs, smooth) int *pn_num_usable_vs, num_pts; char **ppsz_smooth, *smooth; IntPoint *vs; { int i=0, index=1, x=0, y=0; IntPoint *pv=(IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); char *psz_smooth=(char*)malloc((num_pts+1)*sizeof(char)); if (pv == NULL || psz_smooth == NULL) FailAllocMessage(); memset(pv, 0, num_pts*sizeof(IntPoint)); memset(psz_smooth, 0, num_pts*sizeof(char)); x = pv[0].x = vs[0].x; y = pv[0].y = vs[0].y; psz_smooth[0] = FALSE; for (i=1; i < num_pts; i++) { if (vs[i].x != x || vs[i].y != y) { psz_smooth[index] = smooth[i]; x = pv[index].x = vs[i].x; y = pv[index].y = vs[i].y; index++; } } psz_smooth[index] = FALSE; if (index == 1) { *pn_num_usable_vs = 0; *ppsz_smooth = NULL; free(pv); free(psz_smooth); return NULL; } *pn_num_usable_vs = index; *ppsz_smooth = psz_smooth; return pv; } static IntPoint *GetNumUsableIntSplineVsFromStructuredSpline(pn_num_usable_vs, num_pts, vs) int *pn_num_usable_vs, num_pts; IntPoint *vs; { int j=0, index=1, x=0, y=0; IntPoint *pv=(IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); memset(pv, 0, num_pts*sizeof(IntPoint)); x = pv[0].x = vs[0].x; y = pv[0].y = vs[0].y; for (j=3; j < num_pts; j+=3) { if (abs(vs[j].x-x) > 1 || abs(vs[j].y-y) > 1) { x = pv[index].x = vs[j].x; y = pv[index].y = vs[j].y; index++; } } if (index == 1) { *pn_num_usable_vs = 0; free(pv); return NULL; } *pn_num_usable_vs = index; return pv; } static IntPoint *GetNumUsableIntSplineVs(pn_num_usable_vs, num_pts, vs, smooth) int *pn_num_usable_vs, num_pts; IntPoint *vs; char *smooth; { int i=0, index=1, x=0, y=0; IntPoint *pv=(IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); memset(pv, 0, num_pts*sizeof(IntPoint)); x = pv[0].x = vs[0].x; y = pv[0].y = vs[0].y; for (i=1; i < num_pts; i++) { if (abs(vs[i].x-x) > 1 || abs(vs[i].y-y) > 1) { x = pv[index].x = vs[i].x; y = pv[index].y = vs[i].y; index++; } } if (index == 1) { *pn_num_usable_vs = 0; free(pv); return NULL; } *pn_num_usable_vs = index; return pv; } static IntPoint *GetNumUsableStructuredSplineVs(pn_num_usable_vs, ppsz_smooth, obj_type, n, vs, intn, intvs) int *pn_num_usable_vs, obj_type, n, intn; char **ppsz_smooth; IntPoint *vs, *intvs; { int i=0, j=0, k=0, index=1, x=0, y=0, num_ss_pts=(n*3)-2; IntPoint *pv=(IntPoint*)malloc((num_ss_pts+2)*sizeof(IntPoint)); char *psz_smooth=(char*)malloc((num_ss_pts+2)*sizeof(char)); if (pv == NULL || psz_smooth == NULL) FailAllocMessage(); memset(pv, 0, (num_ss_pts+1)*sizeof(IntPoint)); memset(psz_smooth, 0, (num_ss_pts+1)*sizeof(char)); x = pv[0].x = vs[0].x; y = pv[0].y = vs[0].y; psz_smooth[0] = psz_smooth[num_ss_pts-1] = FALSE; if (obj_type == OBJ_POLY) { pv[1].x = vs[0].x; pv[1].y = vs[0].y; psz_smooth[1] = psz_smooth[num_ss_pts-2] = FALSE; } else { /* obj_type == OBJ_POLYGON */ pv[1].x = intvs[0].x; pv[1].y = intvs[0].y; psz_smooth[1] = psz_smooth[num_ss_pts-2] = TRUE; } for (i=1; i < n; i++) { if (abs(vs[i].x-x) > 3 || abs(vs[i].y-y) > 3) { j = (index*3); k = (i<<1)-1; pv[j-1].x = intvs[k].x; pv[j-1].y = intvs[k].y; x = pv[j].x = vs[i].x; y = pv[j].y = vs[i].y; pv[j+1].x = (x<<1) - pv[j-1].x; pv[j+1].y = (y<<1) - pv[j-1].y; if (pv[j-1].x == pv[j+1].x && pv[j-1].y == pv[j+1].y) { psz_smooth[j-1] = psz_smooth[j+1] = FALSE; } else { psz_smooth[j-1] = psz_smooth[j+1] = TRUE; } psz_smooth[j] = FALSE; index++; } } if (index == 1) { *pn_num_usable_vs = 0; *ppsz_smooth = NULL; free(pv); free(psz_smooth); return NULL; } j = (index-1)*3; pv[j].x = x; pv[j].y = y; psz_smooth[j] = FALSE; if (obj_type == OBJ_POLY) { pv[j-1].x = x; pv[j-1].y = y; psz_smooth[j-1] = FALSE; } else { /* obj_type == OBJ_POLYGON */ if (x != pv[0].x || y != pv[0].y) { /* * need to add more vertices? * let's assume this cannot happen for now */ if (index == n) { x = pv[j].x = pv[0].x; y = pv[j].y = pv[0].y; } else { psz_smooth[j-1] = psz_smooth[j] = psz_smooth[j+1] = FALSE; pv[j-1].x = pv[j+1].x = pv[j].x; pv[j-1].y = pv[j+1].y = pv[j].y; j += 3; x = pv[j-1].x = pv[j].x = pv[0].x; y = pv[j-1].y = pv[j].y = pv[0].y; psz_smooth[j-1] = psz_smooth[j] = FALSE; } } else { pv[j-1].x = (x<<1) - pv[1].x; pv[j-1].y = (y<<1) - pv[1].y; psz_smooth[j-1] = TRUE; } } *pn_num_usable_vs = j+1; *ppsz_smooth = psz_smooth; return pv; } static void SetObjSmooth(ObjPtr, TypeIndex, hinge_count) struct ObjRec *ObjPtr; int TypeIndex, hinge_count; { int i=0, n=0, num_ss_pts=0; char *smooth=NULL, *usable_smooth=NULL; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; IntPoint *vlist=NULL, *usable_vlist=NULL; switch (ObjPtr->type) { case OBJ_POLY: poly_ptr = ObjPtr->detail.p; smooth = poly_ptr->smooth; n = poly_ptr->n; switch (TypeIndex) { case LT_STRAIGHT: if (poly_ptr->curved == LT_STRUCT_SPLINE) { usable_vlist = GetNumUsableStraightVs(&n, poly_ptr->ssn, poly_ptr->ssvlist); } if (usable_vlist != NULL) { if (poly_ptr->vlist != NULL) free(poly_ptr->vlist); poly_ptr->n = n; poly_ptr->vlist = usable_vlist; } if (smooth == NULL) smooth = (char*)malloc((n+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); for (i=0; i < n; i++) smooth[i] = FALSE; poly_ptr->smooth = smooth; return; case LT_SPLINE: if (poly_ptr->curved == LT_STRUCT_SPLINE) { usable_vlist = GetNumUsableSplineVs(&n, &usable_smooth, poly_ptr->ssn, poly_ptr->ssvlist, poly_ptr->ssmooth); } if (usable_vlist != NULL) { if (poly_ptr->vlist != NULL) free(poly_ptr->vlist); if (poly_ptr->smooth != NULL) free(poly_ptr->smooth); poly_ptr->n = n; poly_ptr->vlist = usable_vlist; poly_ptr->smooth = usable_smooth; } else { if (smooth == NULL) smooth = (char*)malloc((n+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); smooth[0] = smooth[n-1] = FALSE; for (i=1; i < n-1; i++) smooth[i] = TRUE; poly_ptr->smooth = smooth; } return; case LT_INTSPLINE: if (poly_ptr->curved == LT_STRUCT_SPLINE) { usable_vlist = GetNumUsableIntSplineVsFromStructuredSpline(&n, poly_ptr->n, poly_ptr->vlist); } else { usable_vlist = GetNumUsableIntSplineVs(&n, poly_ptr->n, poly_ptr->vlist, poly_ptr->smooth); } if (usable_vlist != NULL) { if (poly_ptr->vlist != NULL) free(poly_ptr->vlist); poly_ptr->n = n; poly_ptr->vlist = usable_vlist; } if (smooth != NULL) { free(smooth); poly_ptr->smooth = NULL; } return; case LT_STRUCT_SPLINE: if (poly_ptr->curved == LT_INTSPLINE) { usable_vlist = GetNumUsableStructuredSplineVs(&n, &usable_smooth, OBJ_POLY, poly_ptr->n, poly_ptr->vlist, poly_ptr->intn, poly_ptr->intvlist); } if (usable_vlist != NULL) { if (poly_ptr->vlist != NULL) free(poly_ptr->vlist); poly_ptr->n = n; poly_ptr->vlist = usable_vlist; if (poly_ptr->smooth != NULL) free(poly_ptr->smooth); poly_ptr->smooth = usable_smooth; } else { num_ss_pts = (hinge_count*3)-2; vlist = (IntPoint*)malloc((num_ss_pts+1)*sizeof(IntPoint)); if (vlist == NULL) FailAllocMessage(); memset(vlist, 0, (num_ss_pts+1)*sizeof(IntPoint)); if (!CanConvertSplineToStructuredSpline(ObjPtr, &hinge_count, vlist)) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "conversion failed in SetObjSmooth()", NULL); #endif /* _TGIF_DBG */ return; } if (smooth != NULL) free(smooth); free(poly_ptr->vlist); poly_ptr->vlist = vlist; poly_ptr->n = num_ss_pts; poly_ptr->smooth = NULL; } return; } break; case OBJ_POLYGON: polygon_ptr = ObjPtr->detail.g; smooth = polygon_ptr->smooth; n = polygon_ptr->n; switch (TypeIndex) { case LT_STRAIGHT: if (polygon_ptr->curved == LT_STRUCT_SPLINE) { usable_vlist = GetNumUsableStraightVs(&n, polygon_ptr->ssn, polygon_ptr->ssvlist); } if (usable_vlist != NULL) { if (polygon_ptr->vlist != NULL) free(polygon_ptr->vlist); polygon_ptr->n = n; polygon_ptr->vlist = usable_vlist; } if (smooth == NULL) smooth = (char*)malloc((n+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); for (i=0; i < n; i++) smooth[i] = FALSE; polygon_ptr->smooth = smooth; return; case LT_SPLINE: if (polygon_ptr->curved == LT_STRUCT_SPLINE) { usable_vlist = GetNumUsableSplineVs(&n, &usable_smooth, polygon_ptr->ssn, polygon_ptr->ssvlist, polygon_ptr->ssmooth); } if (usable_vlist != NULL) { if (polygon_ptr->vlist != NULL) free(polygon_ptr->vlist); if (polygon_ptr->smooth != NULL) free(polygon_ptr->smooth); polygon_ptr->n = n; polygon_ptr->vlist = usable_vlist; polygon_ptr->smooth = usable_smooth; } else { if (smooth == NULL) smooth = (char*)malloc((n+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); for (i=0; i < n; i++) smooth[i] = TRUE; polygon_ptr->smooth = smooth; } return; case LT_INTSPLINE: if (polygon_ptr->curved == LT_STRUCT_SPLINE) { usable_vlist = GetNumUsableIntSplineVsFromStructuredSpline(&n, polygon_ptr->n, polygon_ptr->vlist); } else { usable_vlist = GetNumUsableIntSplineVs(&n, polygon_ptr->n, polygon_ptr->vlist, polygon_ptr->smooth); } if (usable_vlist != NULL) { if (polygon_ptr->vlist != NULL) free(polygon_ptr->vlist); polygon_ptr->n = n; polygon_ptr->vlist = usable_vlist; } if (smooth != NULL) { free(smooth); polygon_ptr->smooth = NULL; } return; case LT_STRUCT_SPLINE: if (polygon_ptr->curved == LT_INTSPLINE) { usable_vlist = GetNumUsableStructuredSplineVs(&n, &usable_smooth, OBJ_POLYGON, polygon_ptr->n, polygon_ptr->vlist, polygon_ptr->intn, polygon_ptr->intvlist); } if (usable_vlist != NULL) { if (polygon_ptr->vlist != NULL) free(polygon_ptr->vlist); polygon_ptr->n = n; polygon_ptr->vlist = usable_vlist; if (polygon_ptr->smooth != NULL) free(polygon_ptr->smooth); polygon_ptr->smooth = usable_smooth; } else { num_ss_pts = (hinge_count*3)-2; vlist = (IntPoint*)malloc((num_ss_pts+2)*sizeof(IntPoint)); if (vlist == NULL) FailAllocMessage(); memset(vlist, 0, (num_ss_pts+2)*sizeof(IntPoint)); if (!CanConvertSplineToStructuredSpline(ObjPtr, &hinge_count, vlist)) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "conversion failed in SetObjSmooth()", NULL); #endif /* _TGIF_DBG */ return; } if (smooth != NULL) free(smooth); free(polygon_ptr->vlist); polygon_ptr->vlist = vlist; polygon_ptr->n = num_ss_pts; polygon_ptr->smooth = NULL; } return; } break; } } static int ChangeObjLineType(ObjPtr, TypeIndex, pn_failed_count) struct ObjRec *ObjPtr; int TypeIndex, *pn_failed_count; { struct ObjRec *obj_ptr=NULL; int changed=FALSE, hinge_count=0; switch (ObjPtr->type) { case OBJ_POLY: if (CanConvertObjLineType(ObjPtr, TypeIndex, pn_failed_count, &hinge_count)) { /* hinge_count is only valid if TypeIndex is LT_STRUCT_SPLINE */ SetObjSmooth(ObjPtr, TypeIndex, hinge_count); ObjPtr->detail.p->curved = TypeIndex; changed = TRUE; AdjObjSplineVs(ObjPtr); if (ObjPtr->detail.p->curved != LT_INTSPLINE) { UpdPolyBBox(ObjPtr, ObjPtr->detail.p->n, ObjPtr->detail.p->vlist); } else { UpdPolyBBox(ObjPtr, ObjPtr->detail.p->intn, ObjPtr->detail.p->intvlist); } } break; case OBJ_POLYGON: /* hinge_count is only valid if TypeIndex is LT_STRUCT_SPLINE */ if (CanConvertObjLineType(ObjPtr, TypeIndex, pn_failed_count, &hinge_count)) { SetObjSmooth(ObjPtr, TypeIndex, hinge_count); ObjPtr->detail.g->curved = TypeIndex; changed = TRUE; AdjObjSplineVs(ObjPtr); if (ObjPtr->detail.g->curved != LT_INTSPLINE) { UpdPolyBBox(ObjPtr, ObjPtr->detail.g->n, ObjPtr->detail.g->vlist); } else { UpdPolyBBox(ObjPtr, ObjPtr->detail.g->intn, ObjPtr->detail.g->intvlist); } } break; case OBJ_GROUP: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjLineType(obj_ptr, TypeIndex, pn_failed_count)) { changed = TRUE; } } break; } if (changed) AdjObjBBox(ObjPtr); return changed; } void ChangeAllSelLineType(TypeIndex, HighLight) int TypeIndex, HighLight; { struct SelRec *sel_ptr=NULL; int ltx, lty, rbx, rby, changed=FALSE, dont_do_obj=FALSE, failed_count=0; if (topSel == NULL || stickyMenuSelection) { curSpline = TypeIndex; ShowLineType(); UpdatePinnedMenu(MENU_LINETYPE); if (topSel == NULL) dont_do_obj = TRUE; } *gszMsgBox = '\0'; switch (curSpline) { case LT_STRAIGHT: sprintf(gszMsgBox, TgLoadString(STID_LINE_TYPE_IS_STRAIGHT)); break; case LT_SPLINE: sprintf(gszMsgBox, TgLoadString(STID_LINE_TYPE_IS_SPLINE)); break; case LT_INTSPLINE: sprintf(gszMsgBox, TgLoadString(STID_LINE_TYPE_IS_INTSPLINE)); break; case LT_STRUCT_SPLINE: sprintf(gszMsgBox, TgLoadString(STID_LINE_TYPE_IS_STRUCT_SPLINE)); break; } Msg(gszMsgBox); if (dont_do_obj) return; if (HighLight) HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjLineType(sel_ptr->obj, TypeIndex, &failed_count)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } if (HighLight) HighLightForward(); if (failed_count > 0) { if (HighLight && failed_count == numObjSelected) { MsgBox(TgLoadString(STID_CANNOT_CONVERT_SEL_LINETYPE), TOOL_NAME, INFO_MB); } else { Msg(TgLoadString(STID_SOME_LT_FAILED_TO_CONVERT)); } } } void RefreshLineTypeMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == curSpline); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateLineTypeMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, menuImageW, menuImageH, MAXLINETYPES); menu_item = (&menu->menuitems[curSpline]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int LineTypeMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(lineTypeMenuInfo.create_proc)(NULL, X, Y, &lineTypeMenuInfo, INVALID); activeMenu = MENU_LINETYPE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } /* ------------------ LineWidth Functions ------------------ */ static int ChangeObjLineWidth(ObjPtr, nMask, W, AW, AH, width_spec, aw_spec, ah_spec) struct ObjRec *ObjPtr; int nMask, W, AW, AH; char *width_spec, *aw_spec, *ah_spec; { register struct ObjRec *obj_ptr; register int changed=FALSE; switch (ObjPtr->type) { case OBJ_POLY: if ((((nMask & CHANGE_WIDTH) == CHANGE_WIDTH) && (ObjPtr->detail.p->width != W || strcmp(ObjPtr->detail.p->width_spec, width_spec) != 0)) || (AW != (-1) && ((nMask & CHANGE_AW) == CHANGE_AW) && (ObjPtr->detail.p->aw != AW || strcmp(ObjPtr->detail.p->aw_spec, aw_spec) != 0)) || (AH != (-1) && ((nMask & CHANGE_AH) == CHANGE_AH) && (ObjPtr->detail.p->ah != AH || strcmp(ObjPtr->detail.p->ah_spec, ah_spec) != 0))) { if (((nMask & CHANGE_WIDTH) == CHANGE_WIDTH)) { ObjPtr->detail.p->width = W; UtilStrCpyN(ObjPtr->detail.p->width_spec, sizeof(ObjPtr->detail.p->width_spec), width_spec); } if (AW != (-1) && ((nMask & CHANGE_AW) == CHANGE_AW)) { ObjPtr->detail.p->aw = AW; UtilStrCpyN(ObjPtr->detail.p->aw_spec, sizeof(ObjPtr->detail.p->aw_spec), aw_spec); } if (AH != (-1) && ((nMask & CHANGE_AH) == CHANGE_AH)) { ObjPtr->detail.p->ah = AH; UtilStrCpyN(ObjPtr->detail.p->ah_spec, sizeof(ObjPtr->detail.p->ah_spec), ah_spec); } changed = TRUE; AdjObjSplineVs(ObjPtr); if (ObjPtr->detail.p->curved != LT_INTSPLINE) { UpdPolyBBox(ObjPtr, ObjPtr->detail.p->n, ObjPtr->detail.p->vlist); } else { UpdPolyBBox(ObjPtr, ObjPtr->detail.p->intn, ObjPtr->detail.p->intvlist); } } break; case OBJ_BOX: if ((nMask & CHANGE_WIDTH) == CHANGE_WIDTH) { if (ObjPtr->detail.b->width != W || strcmp(ObjPtr->detail.b->width_spec, width_spec) != 0) { ObjPtr->detail.b->width = W; UtilStrCpyN(ObjPtr->detail.b->width_spec, sizeof(ObjPtr->detail.b->width_spec), width_spec); changed = TRUE; } } break; case OBJ_OVAL: if ((nMask & CHANGE_WIDTH) == CHANGE_WIDTH) { if (ObjPtr->detail.o->width != W || strcmp(ObjPtr->detail.o->width_spec, width_spec) != 0) { ObjPtr->detail.o->width = W; UtilStrCpyN(ObjPtr->detail.o->width_spec, sizeof(ObjPtr->detail.o->width_spec), width_spec); changed = TRUE; } } break; case OBJ_POLYGON: if ((nMask & CHANGE_WIDTH) == CHANGE_WIDTH) { if (ObjPtr->detail.g->width != W || strcmp(ObjPtr->detail.g->width_spec, width_spec) != 0) { ObjPtr->detail.g->width = W; UtilStrCpyN(ObjPtr->detail.g->width_spec, sizeof(ObjPtr->detail.g->width_spec), width_spec); changed = TRUE; } } break; case OBJ_ARC: if ((((nMask & CHANGE_WIDTH) == CHANGE_WIDTH) && (ObjPtr->detail.a->width != W || strcmp(ObjPtr->detail.a->width_spec, width_spec) != 0)) || (AW != (-1) && ((nMask & CHANGE_AW) == CHANGE_AW) && (ObjPtr->detail.a->aw != AW || strcmp(ObjPtr->detail.a->aw_spec, aw_spec) != 0)) || (AH != (-1) && ((nMask & CHANGE_AH) == CHANGE_AH) && (ObjPtr->detail.a->ah != AH || strcmp(ObjPtr->detail.a->ah_spec, ah_spec) != 0))) { if (((nMask & CHANGE_WIDTH) == CHANGE_WIDTH)) { ObjPtr->detail.a->width = W; UtilStrCpyN(ObjPtr->detail.a->width_spec, sizeof(ObjPtr->detail.a->width_spec), width_spec); } if (AW != (-1) && ((nMask & CHANGE_AW) == CHANGE_AW)) { ObjPtr->detail.a->aw = AW; UtilStrCpyN(ObjPtr->detail.a->aw_spec, sizeof(ObjPtr->detail.a->aw_spec), aw_spec); } if (AH != (-1) && ((nMask & CHANGE_AH) == CHANGE_AH)) { ObjPtr->detail.a->ah = AH; UtilStrCpyN(ObjPtr->detail.a->ah_spec, sizeof(ObjPtr->detail.a->ah_spec), ah_spec); } changed = TRUE; AdjObjSplineVs(ObjPtr); } break; case OBJ_RCBOX: if ((nMask & CHANGE_WIDTH) == CHANGE_WIDTH) { if (ObjPtr->detail.rcb->width != W || strcmp(ObjPtr->detail.rcb->width_spec, width_spec) != 0) { ObjPtr->detail.rcb->width = W; UtilStrCpyN(ObjPtr->detail.rcb->width_spec, sizeof(ObjPtr->detail.rcb->width_spec), width_spec); changed = TRUE; } } break; case OBJ_GROUP: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjLineWidth(obj_ptr, nMask, W, AW, AH, width_spec, aw_spec, ah_spec)) { changed = TRUE; } } break; } if (changed) AdjObjBBox(ObjPtr); return changed; } void ChangeAllSelLineWidth(WidthIndex, HighLight) int WidthIndex, HighLight; { struct SelRec *sel_ptr; int ltx, lty, rbx, rby, changed=FALSE, w, aw, ah, dont_do_obj=FALSE; char *width_spec, *aw_spec, *ah_spec; if (topSel == NULL || stickyMenuSelection) { lineWidth = WidthIndex; ShowLineWidth(); UpdatePinnedMenu(MENU_LINEWIDTH); if (topSel == NULL) dont_do_obj = TRUE; } sprintf(gszMsgBox, TgLoadString(STID_LINE_WIDTH_SET_TO_GIVEN_STR), curWidthOfLineSpec[WidthIndex]); Msg(gszMsgBox); if (dont_do_obj) return; w = curWidthOfLine[WidthIndex]; aw = curArrowHeadW[WidthIndex]; ah = curArrowHeadH[WidthIndex]; width_spec = curWidthOfLineSpec[WidthIndex]; aw_spec = curArrowHeadWSpec[WidthIndex]; ah_spec = curArrowHeadHSpec[WidthIndex]; if (HighLight) HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjLineWidth(sel_ptr->obj, CHANGE_LINE_ALL, w, aw, ah, width_spec, aw_spec, ah_spec)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } if (HighLight) HighLightForward(); } static int GetLineWidthMatch(index, width, aw, ah) int index, width, aw, ah; { int diff=0; if (width != INVALID && width != curWidthOfLine[index]) { diff += 10*abs(width-curWidthOfLine[index]); } if (aw != INVALID && aw != curArrowHeadW[index]) { diff += abs(aw-curArrowHeadW[index]); } if (ah != INVALID && ah != curArrowHeadH[index]) { diff += abs(ah-curArrowHeadH[index]); } return diff; } int GetBestLineWidthIndex(width, aw, ah) int width, aw, ah; { int min_diff=0, min_index=0, index=0; min_diff = GetLineWidthMatch(0, width, aw, ah); for (index=1; index < maxLineWidths; index++) { int diff=GetLineWidthMatch(index, width, aw, ah); if (diff < min_diff) { min_diff = diff; min_index = index; } } return min_index; } void RefreshLineWidthMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == lineWidth); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateLineWidthMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { int i=0; TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); stMenuInfo.items = (TgMenuItemInfo*)malloc( (maxLineWidths+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (maxLineWidths+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < maxLineWidths; item_info++, i++) { item_info->menu_str = (char*)(Pixmap*)(&lineWidthPixmap[i]); item_info->shortcut_str = NULL; sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_LINE_WIDTH_TO_GIVEN_S), curWidthOfLineSpec[i]); item_info->status_str = UtilStrDup(gszMsgBox); if (item_info->status_str == NULL) FailAllocMessage(); item_info->submenu_info = NULL; item_info->cmdid = CMDID_CHANGEALLSELLINEWIDTH; } stMenuInfo.items[maxLineWidths].cmdid = INVALID; /* the status_str has been translated in TgLoadCachedString() */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < maxLineWidths; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (maxLineWidths+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, menuImageW, menuImageH, maxLineWidths); menu_item = (&menu->menuitems[lineWidth]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int LineWidthMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(lineWidthMenuInfo.create_proc)(NULL, X, Y, &lineWidthMenuInfo, INVALID); activeMenu = MENU_LINEWIDTH; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } /* ------------------ LineDash Functions ------------------ */ static int ChangeObjLineDash(ObjPtr, DashIndex) struct ObjRec *ObjPtr; int DashIndex; { register struct ObjRec *obj_ptr; int changed=FALSE; switch (ObjPtr->type) { case OBJ_POLY: if (ObjPtr->detail.p->dash != DashIndex) { ObjPtr->detail.p->dash = DashIndex; changed = TRUE; } break; case OBJ_BOX: if (ObjPtr->detail.b->dash != DashIndex) { ObjPtr->detail.b->dash = DashIndex; changed = TRUE; } break; case OBJ_OVAL: if (ObjPtr->detail.o->dash != DashIndex) { ObjPtr->detail.o->dash = DashIndex; changed = TRUE; } break; case OBJ_POLYGON: if (ObjPtr->detail.g->dash != DashIndex) { ObjPtr->detail.g->dash = DashIndex; changed = TRUE; } break; case OBJ_ARC: if (ObjPtr->detail.a->dash != DashIndex) { ObjPtr->detail.a->dash = DashIndex; changed = TRUE; } break; case OBJ_RCBOX: if (ObjPtr->detail.rcb->dash != DashIndex) { ObjPtr->detail.rcb->dash = DashIndex; changed = TRUE; } break; case OBJ_GROUP: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjLineDash(obj_ptr, DashIndex)) { changed = TRUE; } } break; } return changed; } void ChangeAllSelLineDash(DashIndex, HighLight) int DashIndex, HighLight; { register struct SelRec *sel_ptr; int changed=FALSE; if (topSel == NULL || stickyMenuSelection) { curDash = DashIndex; ShowDash(); UpdatePinnedMenu(MENU_LINEDASH); if (topSel == NULL) return; } if (HighLight) HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjLineDash(sel_ptr->obj, DashIndex)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } if (HighLight) HighLightForward(); } void RefreshLineDashMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == curDash); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateLineDashMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { int i=0; TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); stMenuInfo.items = (TgMenuItemInfo*)malloc( (MAXDASHES+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (MAXDASHES+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < MAXDASHES; item_info++, i++) { item_info->menu_str = (char*)(Pixmap*)(&lineDashPixmap[i]); item_info->shortcut_str = NULL; if (i == 0) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_PEN_DASH_PAT_NO_DASH)); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_PEN_DASH_PAT_PAT_NUM), i); } item_info->status_str = UtilStrDup(gszMsgBox); if (item_info->status_str == NULL) FailAllocMessage(); item_info->submenu_info = NULL; item_info->cmdid = CMDID_CHANGEALLSELLINEDASH; } stMenuInfo.items[MAXDASHES].cmdid = INVALID; /* the status_str has been translated in TgLoadCachedString() */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < MAXDASHES; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (MAXDASHES+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, menuImageW, menuImageH, MAXDASHES); menu_item = (&menu->menuitems[curDash]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int LineDashMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(lineDashMenuInfo.create_proc)(NULL, X, Y, &lineDashMenuInfo, INVALID); activeMenu = MENU_LINEDASH; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } /* ------------------ Pen Functions ------------------ */ int ChangeObjPen(ObjPtr, PenIndex) struct ObjRec *ObjPtr; int PenIndex; { register struct ObjRec *obj_ptr; int changed=FALSE; switch (ObjPtr->type) { case OBJ_POLY: if (ObjPtr->detail.p->pen != PenIndex) { ObjPtr->detail.p->pen = PenIndex; changed = TRUE; } break; case OBJ_TEXT: if (ObjPtr->detail.t->pen != PenIndex) { ObjPtr->detail.t->pen = PenIndex; AdjObjCache(ObjPtr); changed = TRUE; } break; case OBJ_BOX: if (ObjPtr->detail.b->pen != PenIndex) { ObjPtr->detail.b->pen = PenIndex; changed = TRUE; } break; case OBJ_OVAL: if (ObjPtr->detail.o->pen != PenIndex) { ObjPtr->detail.o->pen = PenIndex; changed = TRUE; } break; case OBJ_POLYGON: if (ObjPtr->detail.g->pen != PenIndex) { ObjPtr->detail.g->pen = PenIndex; changed = TRUE; } break; case OBJ_ARC: if (ObjPtr->detail.a->pen != PenIndex) { ObjPtr->detail.a->pen = PenIndex; changed = TRUE; } break; case OBJ_RCBOX: if (ObjPtr->detail.rcb->pen != PenIndex) { ObjPtr->detail.rcb->pen = PenIndex; changed = TRUE; } break; case OBJ_GROUP: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjPen(obj_ptr, PenIndex)) { changed = TRUE; } } break; } if (changePropertiesOfAttrs && ObjPtr->type != OBJ_TEXT) { struct AttrRec *attr_ptr=ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { changed |= ChangeObjPen(attr_ptr->obj, PenIndex); } } return changed; } void ChangeAllSelPen(PenIndex, HighLight) int PenIndex, HighLight; { register struct SelRec *sel_ptr; int changed=FALSE; if (topSel == NULL || stickyMenuSelection) { if (!(curChoice == DRAWTEXT && textCursorShown)) { TieLooseEnds(); } penPat = PenIndex; if (curChoice == DRAWTEXT && textCursorShown) { if (ChangeObjPen(curTextObj, PenIndex)) { curTextModified = TRUE; UpdCurTextBBox(); RedrawCurText(); SetFileModified(TRUE); if (cycleThroughChoice) { SetPushedFontValue(PUSH_PEN, penPat); } } } else { textCursorShown = FALSE; } ShowPen(); UpdatePinnedMenu(MENU_PEN); if (topSel == NULL) return; } if (HighLight) HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjPen(sel_ptr->obj, PenIndex)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } if (HighLight) HighLightForward(); } void RefreshPenMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == penPat); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreatePenMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { int i=0; TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); stMenuInfo.items = (TgMenuItemInfo*)malloc( (MAXPATTERNS+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (MAXPATTERNS+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < MAXPATTERNS; item_info++, i++) { item_info->menu_str = (char*)(Pixmap*)(&patPixmap[i]); item_info->shortcut_str = NULL; switch (i) { case NONEPAT: sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_PEN_TO_NONE)); break; case SOLIDPAT: sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_PEN_TO_SOLID)); break; case BACKPAT: sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_PEN_TO_BACKGROUND)); break; default: sprintf(gszMsgBox, TgLoadCachedString(CSTID_SET_PEN_TO_PAT_NUM), i); break; } item_info->status_str = UtilStrDup(gszMsgBox); if (item_info->status_str == NULL) FailAllocMessage(); item_info->submenu_info = NULL; item_info->cmdid = CMDID_CHANGEALLSELPEN; } stMenuInfo.items[MAXPATTERNS].cmdid = INVALID; /* the status_str has been translated in TgLoadCachedString() */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < MAXPATTERNS; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (MAXPATTERNS+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, 8); menu_item = (&menu->menuitems[penPat]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int PenMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(penMenuInfo.create_proc)(NULL, X, Y, &penMenuInfo, INVALID); activeMenu = MENU_PEN; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } /* ------------------ Toggling and Changing Functions ------------------ */ static int ToggleObjLineType(ObjPtr) struct ObjRec *ObjPtr; { register struct ObjRec *obj_ptr; register int changed=FALSE; switch (ObjPtr->type) { case OBJ_POLY: ObjPtr->detail.p->curved = (ObjPtr->detail.p->curved+1) % MAXLINETYPES; changed = TRUE; AdjObjSplineVs(ObjPtr); if (ObjPtr->detail.p->curved != LT_INTSPLINE) { UpdPolyBBox(ObjPtr, ObjPtr->detail.p->n, ObjPtr->detail.p->vlist); } else { UpdPolyBBox(ObjPtr, ObjPtr->detail.p->intn, ObjPtr->detail.p->intvlist); } break; case OBJ_POLYGON: ObjPtr->detail.g->curved = (ObjPtr->detail.g->curved+1) % MAXLINETYPES; changed = TRUE; AdjObjSplineVs(ObjPtr); if (ObjPtr->detail.g->curved != LT_INTSPLINE) { UpdPolyBBox(ObjPtr, ObjPtr->detail.g->n, ObjPtr->detail.g->vlist); } else { UpdPolyBBox(ObjPtr, ObjPtr->detail.g->intn, ObjPtr->detail.g->intvlist); } break; case OBJ_GROUP: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ToggleObjLineType(obj_ptr)) { changed = TRUE; } } break; } if (changed) AdjObjBBox(ObjPtr); return changed; } void ToggleAllSelLineType() { register struct SelRec *sel_ptr; register int changed=FALSE; if (topSel == NULL) { curSpline = (curSpline+1) % MAXLINETYPES; ShowLineType(); UpdatePinnedMenu(MENU_LINETYPE); return; } HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ToggleObjLineType(sel_ptr->obj)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } HighLightForward(); } static int ChangeObjRCBRadius(ObjPtr, Radius) struct ObjRec *ObjPtr; int Radius; { register struct ObjRec *obj_ptr; int changed=FALSE; switch (ObjPtr->type) { case OBJ_RCBOX: if (ObjPtr->detail.rcb->radius != Radius) { ObjPtr->detail.rcb->radius = Radius; AdjObjCache(ObjPtr); changed = TRUE; } break; case OBJ_GROUP: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (ChangeObjRCBRadius(obj_ptr, Radius)) { changed = TRUE; } } break; } return changed; } void ChangeAllSelRCBRadius(Radius) int Radius; { register struct SelRec *sel_ptr; int changed=FALSE; if (topSel == NULL) { rcbRadius = Radius; ShowRCBRadius(); return; } HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjRCBRadius(sel_ptr->obj, Radius)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } HighLightForward(); } void UpdateSelObjs() { struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } BackupCopiedProperties(); HighLightReverse(); topSel = botSel = NULL; CopyProperties(FALSE); topSel = saved_top_sel; botSel = saved_bot_sel; PasteProperties(FALSE); HighLightForward(); RestoreCopiedProperties(); } void ChangeAllSelRealLineWidth(nMask, Width, AW, AH, width_spec, aw_spec, ah_spec, HighLight) int nMask, Width, AW, AH, HighLight; char *width_spec, *aw_spec, *ah_spec; { register struct SelRec *sel_ptr; int changed=FALSE; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (HighLight) HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { PrepareToReplaceAnObj(sel_ptr->obj); if (ChangeObjLineWidth(sel_ptr->obj, nMask, Width, AW, AH, width_spec, aw_spec, ah_spec)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (changed) { int ltx=selLtX, lty=selLtY, rbx=selRbX, rby=selRbY; SetFileModified(TRUE); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } if (HighLight) HighLightForward(); } void SetSelLineWidth(pszBuf) char *pszBuf; { char spec[MAXSTRING+1], *w_str=NULL, *aw_str=NULL, *ah_str=NULL, *c_ptr=NULL; int w=(-1), aw=(-1), ah=(-1), mult_set=FALSE; char width_spec[40], aw_spec[40], ah_spec[40]; float fw, faw, fah, mult=((float)1.0); if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } *spec = '\0'; if (pszBuf == NULL) { Dialog(TgLoadString(STID_ENTER_LINE_WIDTH_OPT_AW_AH), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), spec); } else { UtilStrCpyN(spec, sizeof(spec), pszBuf); } UtilTrimBlanks(spec); if (*spec == '\0') return; *width_spec = *aw_spec = *ah_spec = '\0'; if ((w_str=strtok(spec, ", \t\n\r")) == NULL) return; UtilTrimBlanks(w_str); if ((c_ptr=strstr(w_str, "in")) != NULL || (c_ptr=strstr(w_str, "In")) != NULL || (c_ptr=strstr(w_str, "IN")) != NULL) { *c_ptr = '\0'; mult = (float)PIX_PER_INCH; mult_set = TRUE; } else if ((c_ptr=strstr(w_str, "cm")) != NULL || (c_ptr=strstr(w_str, "Cm")) != NULL || (c_ptr=strstr(w_str, "CM")) != NULL) { *c_ptr = '\0'; mult = (float)ONE_CM; mult_set = TRUE; } if (sscanf(w_str, "%f", &fw) != 1 || fw < (float)0.0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_STR_WIDTH), w_str); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (mult_set) { fw *= mult; sprintf(width_spec, "%.3f", fw); } else { UtilStrCpyN(width_spec, sizeof(width_spec), w_str); } w = round(fw); if ((aw_str=strtok(NULL, ", \t\n\r")) != NULL && (ah_str=strtok(NULL, ", \t\n\r")) != NULL) { int aw_mult_set=FALSE, ah_mult_set=FALSE; float aw_mult=((float)1.0), ah_mult=((float)1.0); UtilTrimBlanks(aw_str); UtilTrimBlanks(ah_str); if ((c_ptr=strstr(aw_str, "in")) != NULL || (c_ptr=strstr(aw_str, "In")) != NULL || (c_ptr=strstr(aw_str, "IN")) != NULL) { *c_ptr = '\0'; aw_mult = (float)PIX_PER_INCH; aw_mult_set = TRUE; } else if ((c_ptr=strstr(aw_str, "cm")) != NULL || (c_ptr=strstr(aw_str, "Cm")) != NULL || (c_ptr=strstr(aw_str, "CM")) != NULL) { *c_ptr = '\0'; aw_mult = (float)ONE_CM; aw_mult_set = TRUE; } if ((c_ptr=strstr(ah_str, "in")) != NULL || (c_ptr=strstr(ah_str, "In")) != NULL || (c_ptr=strstr(ah_str, "IN")) != NULL) { *c_ptr = '\0'; ah_mult = (float)PIX_PER_INCH; ah_mult_set = TRUE; } else if ((c_ptr=strstr(ah_str, "cm")) != NULL || (c_ptr=strstr(ah_str, "Cm")) != NULL || (c_ptr=strstr(ah_str, "CM")) != NULL) { *c_ptr = '\0'; ah_mult = (float)ONE_CM; ah_mult_set = TRUE; } if (sscanf(aw_str, "%f", &faw) != 1 || faw < (float)0.0 || sscanf(ah_str, "%f", &fah) != 1 || fah < (float)0.0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_STR_AW_AH), aw_str, ah_str); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (aw_mult_set) { faw *= aw_mult; sprintf(aw_spec, "%.3f", faw); } else { UtilStrCpyN(aw_spec, sizeof(aw_spec), aw_str); } aw = round(faw); if (ah_mult_set) { fah *= ah_mult; sprintf(ah_spec, "%.3f", fah); } else { UtilStrCpyN(ah_spec, sizeof(ah_spec), ah_str); } ah = round(fah); } ChangeAllSelRealLineWidth(CHANGE_LINE_ALL, w, aw, ah, width_spec, aw_spec, ah_spec, TRUE); } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/config.log���������������������������������������������������������������������������0000644�0000764�0000764�00000107776�11602233424�014762� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by tgif configure 4.2.5, which was generated by GNU Autoconf 2.61. Invocation command line was $ ./configure ## --------- ## ## Platform. ## ## --------- ## hostname = merlot.usc.edu uname -m = i686 uname -r = 2.6.23.1-42.fc8 uname -s = Linux uname -v = #1 SMP Tue Oct 30 13:55:12 EDT 2007 /usr/bin/uname -p = unknown /bin/uname -X = unknown /bin/arch = i686 /usr/bin/arch -k = unknown /usr/convex/getsysinfo = unknown /usr/bin/hostinfo = unknown /bin/machine = unknown /usr/bin/oslevel = unknown /bin/universe = unknown PATH: /merlot/home/william/src/www/serve/ssl/misc PATH: /merlot/home/william/src/www/serve/bin PATH: /usr/lib/qt-2.3.1/bin PATH: /merlot/bistro/serve/bin PATH: /merlot/home/william/bin PATH: /merlot/bin PATH: /usr/X11R6/bin PATH: /usr/local/bin PATH: /bin PATH: /usr/bin PATH: /usr/games PATH: . ## ----------- ## ## Core tests. ## ## ----------- ## configure:1787: checking for a BSD-compatible install configure:1843: result: /usr/bin/install -c configure:1854: checking whether build environment is sane configure:1897: result: yes configure:1925: checking for a thread-safe mkdir -p configure:1964: result: /bin/mkdir -p configure:1977: checking for gawk configure:1993: found /bin/gawk configure:2004: result: gawk configure:2015: checking whether make sets $(MAKE) configure:2036: result: yes configure:2276: checking for gcc configure:2292: found /usr/bin/gcc configure:2303: result: gcc configure:2541: checking for C compiler version configure:2548: gcc --version >&5 gcc (GCC) 4.1.2 20070925 (Red Hat 4.1.2-33) Copyright (C) 2006 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. configure:2551: $? = 0 configure:2558: gcc -v >&5 Using built-in specs. Target: i386-redhat-linux Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --enable-plugin --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-1.5.0.0/jre --enable-libgcj-multifile --enable-java-maintainer-mode --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --with-cpu=generic --host=i386-redhat-linux Thread model: posix gcc version 4.1.2 20070925 (Red Hat 4.1.2-33) configure:2561: $? = 0 configure:2568: gcc -V >&5 gcc: '-V' option must have argument configure:2571: $? = 1 configure:2594: checking for C compiler default output file name configure:2621: gcc conftest.c >&5 configure:2624: $? = 0 configure:2662: result: a.out configure:2679: checking whether the C compiler works configure:2689: ./a.out configure:2692: $? = 0 configure:2709: result: yes configure:2716: checking whether we are cross compiling configure:2718: result: no configure:2721: checking for suffix of executables configure:2728: gcc -o conftest conftest.c >&5 configure:2731: $? = 0 configure:2755: result: configure:2761: checking for suffix of object files configure:2787: gcc -c conftest.c >&5 configure:2790: $? = 0 configure:2813: result: o configure:2817: checking whether we are using the GNU C compiler configure:2846: gcc -c conftest.c >&5 configure:2852: $? = 0 configure:2869: result: yes configure:2874: checking whether gcc accepts -g configure:2904: gcc -c -g conftest.c >&5 configure:2910: $? = 0 configure:3009: result: yes configure:3026: checking for gcc option to accept ISO C89 configure:3100: gcc -c -g -O2 conftest.c >&5 configure:3106: $? = 0 configure:3129: result: none needed configure:3158: checking for style of include used by make configure:3186: result: GNU configure:3211: checking dependency style of gcc configure:3302: result: gcc3 configure:3321: checking for XOpenDisplay in -lX11 configure:3356: gcc -o conftest -g -O2 conftest.c -lX11 >&5 configure:3362: $? = 0 configure:3380: result: yes configure:3392: checking for XtInitialize in -lXt configure:3427: gcc -o conftest -g -O2 conftest.c -lXt -lX11 >&5 configure:3433: $? = 0 configure:3451: result: yes configure:3463: checking for socket in -lsocket configure:3498: gcc -o conftest -g -O2 conftest.c -lsocket -lXt -lX11 >&5 /usr/bin/ld: cannot find -lsocket collect2: ld returned 1 exit status configure:3504: $? = 1 configure: failed program was: | /* confdefs.h. */ | #define PACKAGE_NAME "tgif" | #define PACKAGE_TARNAME "tgif" | #define PACKAGE_VERSION "4.2.5" | #define PACKAGE_STRING "tgif 4.2.5" | #define PACKAGE_BUGREPORT "bill.cheng@acm.org" | #define PACKAGE "tgif" | #define VERSION "4.2.5" | #define HAVE_LIBX11 1 | #define HAVE_LIBXT 1 | /* end confdefs.h. */ | | /* Override any GCC internal prototype to avoid an error. | Use char because int might match the return type of a GCC | builtin and then its argument prototype would still apply. */ | #ifdef __cplusplus | extern "C" | #endif | char socket (); | int | main () | { | return socket (); | ; | return 0; | } configure:3522: result: no configure:3534: checking for inet_addr in -lnsl configure:3569: gcc -o conftest -g -O2 conftest.c -lnsl -lXt -lX11 >&5 configure:3575: $? = 0 configure:3593: result: yes configure:3605: checking for dlsym in -ldl configure:3640: gcc -o conftest -g -O2 conftest.c -ldl -lnsl -lXt -lX11 >&5 configure:3646: $? = 0 configure:3664: result: yes configure:3676: checking for stringprep_convert in -lidn configure:3711: gcc -o conftest -g -O2 conftest.c -lidn -ldl -lnsl -lXt -lX11 >&5 configure:3717: $? = 0 configure:3735: result: yes configure:3747: checking for pow in -lm configure:3782: gcc -o conftest -g -O2 conftest.c -lm -lidn -ldl -lnsl -lXt -lX11 >&5 conftest.c:22: warning: conflicting types for built-in function 'pow' configure:3788: $? = 0 configure:3806: result: yes configure:3818: checking for deflate in -lz configure:3853: gcc -o conftest -g -O2 conftest.c -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:3859: $? = 0 configure:3877: result: yes configure:3889: checking for pthread_create in -lpthread configure:3924: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:3930: $? = 0 configure:3948: result: yes configure:3966: checking how to run the C preprocessor configure:4006: gcc -E conftest.c configure:4012: $? = 0 configure:4043: gcc -E conftest.c conftest.c:18:28: error: ac_nonexistent.h: No such file or directory configure:4049: $? = 1 configure: failed program was: | /* confdefs.h. */ | #define PACKAGE_NAME "tgif" | #define PACKAGE_TARNAME "tgif" | #define PACKAGE_VERSION "4.2.5" | #define PACKAGE_STRING "tgif 4.2.5" | #define PACKAGE_BUGREPORT "bill.cheng@acm.org" | #define PACKAGE "tgif" | #define VERSION "4.2.5" | #define HAVE_LIBX11 1 | #define HAVE_LIBXT 1 | #define HAVE_LIBNSL 1 | #define HAVE_LIBDL 1 | #define HAVE_LIBIDN 1 | #define HAVE_LIBM 1 | #define HAVE_LIBZ 1 | #define HAVE_LIBPTHREAD 1 | /* end confdefs.h. */ | #include <ac_nonexistent.h> configure:4082: result: gcc -E configure:4111: gcc -E conftest.c configure:4117: $? = 0 configure:4148: gcc -E conftest.c conftest.c:18:28: error: ac_nonexistent.h: No such file or directory configure:4154: $? = 1 configure: failed program was: | /* confdefs.h. */ | #define PACKAGE_NAME "tgif" | #define PACKAGE_TARNAME "tgif" | #define PACKAGE_VERSION "4.2.5" | #define PACKAGE_STRING "tgif 4.2.5" | #define PACKAGE_BUGREPORT "bill.cheng@acm.org" | #define PACKAGE "tgif" | #define VERSION "4.2.5" | #define HAVE_LIBX11 1 | #define HAVE_LIBXT 1 | #define HAVE_LIBNSL 1 | #define HAVE_LIBDL 1 | #define HAVE_LIBIDN 1 | #define HAVE_LIBM 1 | #define HAVE_LIBZ 1 | #define HAVE_LIBPTHREAD 1 | /* end confdefs.h. */ | #include <ac_nonexistent.h> configure:4192: checking for X configure:4362: gcc -o conftest -g -O2 conftest.c -lX11 -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:4368: $? = 0 configure:4427: result: libraries , headers configure:4439: checking for dirent.h that defines DIR configure:4468: gcc -c -g -O2 conftest.c >&5 configure:4474: $? = 0 configure:4490: result: yes configure:4503: checking for library containing opendir configure:4544: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:4550: $? = 0 configure:4578: result: none required configure:4672: checking for grep that handles long lines and -e configure:4746: result: /bin/grep configure:4751: checking for egrep configure:4829: result: /bin/grep -E configure:4834: checking for ANSI C header files configure:4864: gcc -c -g -O2 conftest.c >&5 configure:4870: $? = 0 configure:4969: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:4972: $? = 0 configure:4978: ./conftest configure:4981: $? = 0 configure:4998: result: yes configure:5008: checking for sys/wait.h that is POSIX.1 compatible configure:5044: gcc -c -g -O2 conftest.c >&5 configure:5050: $? = 0 configure:5065: result: yes configure:5089: checking for sys/types.h configure:5110: gcc -c -g -O2 conftest.c >&5 configure:5116: $? = 0 configure:5132: result: yes configure:5089: checking for sys/stat.h configure:5110: gcc -c -g -O2 conftest.c >&5 configure:5116: $? = 0 configure:5132: result: yes configure:5089: checking for stdlib.h configure:5110: gcc -c -g -O2 conftest.c >&5 configure:5116: $? = 0 configure:5132: result: yes configure:5089: checking for string.h configure:5110: gcc -c -g -O2 conftest.c >&5 configure:5116: $? = 0 configure:5132: result: yes configure:5089: checking for memory.h configure:5110: gcc -c -g -O2 conftest.c >&5 configure:5116: $? = 0 configure:5132: result: yes configure:5089: checking for strings.h configure:5110: gcc -c -g -O2 conftest.c >&5 configure:5116: $? = 0 configure:5132: result: yes configure:5089: checking for inttypes.h configure:5110: gcc -c -g -O2 conftest.c >&5 configure:5116: $? = 0 configure:5132: result: yes configure:5089: checking for stdint.h configure:5110: gcc -c -g -O2 conftest.c >&5 configure:5116: $? = 0 configure:5132: result: yes configure:5089: checking for unistd.h configure:5110: gcc -c -g -O2 conftest.c >&5 configure:5116: $? = 0 configure:5132: result: yes configure:5172: checking arpa/inet.h usability configure:5189: gcc -c -g -O2 conftest.c >&5 configure:5195: $? = 0 configure:5209: result: yes configure:5213: checking arpa/inet.h presence configure:5228: gcc -E conftest.c configure:5234: $? = 0 configure:5248: result: yes configure:5281: checking for arpa/inet.h configure:5289: result: yes configure:5172: checking fcntl.h usability configure:5189: gcc -c -g -O2 conftest.c >&5 configure:5195: $? = 0 configure:5209: result: yes configure:5213: checking fcntl.h presence configure:5228: gcc -E conftest.c configure:5234: $? = 0 configure:5248: result: yes configure:5281: checking for fcntl.h configure:5289: result: yes configure:5172: checking libintl.h usability configure:5189: gcc -c -g -O2 conftest.c >&5 configure:5195: $? = 0 configure:5209: result: yes configure:5213: checking libintl.h presence configure:5228: gcc -E conftest.c configure:5234: $? = 0 configure:5248: result: yes configure:5281: checking for libintl.h configure:5289: result: yes configure:5172: checking netdb.h usability configure:5189: gcc -c -g -O2 conftest.c >&5 configure:5195: $? = 0 configure:5209: result: yes configure:5213: checking netdb.h presence configure:5228: gcc -E conftest.c configure:5234: $? = 0 configure:5248: result: yes configure:5281: checking for netdb.h configure:5289: result: yes configure:5172: checking netinet/in.h usability configure:5189: gcc -c -g -O2 conftest.c >&5 configure:5195: $? = 0 configure:5209: result: yes configure:5213: checking netinet/in.h presence configure:5228: gcc -E conftest.c configure:5234: $? = 0 configure:5248: result: yes configure:5281: checking for netinet/in.h configure:5289: result: yes configure:5162: checking for stdint.h configure:5168: result: yes configure:5162: checking for stdlib.h configure:5168: result: yes configure:5162: checking for string.h configure:5168: result: yes configure:5172: checking sys/file.h usability configure:5189: gcc -c -g -O2 conftest.c >&5 configure:5195: $? = 0 configure:5209: result: yes configure:5213: checking sys/file.h presence configure:5228: gcc -E conftest.c configure:5234: $? = 0 configure:5248: result: yes configure:5281: checking for sys/file.h configure:5289: result: yes configure:5172: checking sys/ioctl.h usability configure:5189: gcc -c -g -O2 conftest.c >&5 configure:5195: $? = 0 configure:5209: result: yes configure:5213: checking sys/ioctl.h presence configure:5228: gcc -E conftest.c configure:5234: $? = 0 configure:5248: result: yes configure:5281: checking for sys/ioctl.h configure:5289: result: yes configure:5172: checking sys/socket.h usability configure:5189: gcc -c -g -O2 conftest.c >&5 configure:5195: $? = 0 configure:5209: result: yes configure:5213: checking sys/socket.h presence configure:5228: gcc -E conftest.c configure:5234: $? = 0 configure:5248: result: yes configure:5281: checking for sys/socket.h configure:5289: result: yes configure:5172: checking sys/time.h usability configure:5189: gcc -c -g -O2 conftest.c >&5 configure:5195: $? = 0 configure:5209: result: yes configure:5213: checking sys/time.h presence configure:5228: gcc -E conftest.c configure:5234: $? = 0 configure:5248: result: yes configure:5281: checking for sys/time.h configure:5289: result: yes configure:5172: checking sys/timeb.h usability configure:5189: gcc -c -g -O2 conftest.c >&5 configure:5195: $? = 0 configure:5209: result: yes configure:5213: checking sys/timeb.h presence configure:5228: gcc -E conftest.c configure:5234: $? = 0 configure:5248: result: yes configure:5281: checking for sys/timeb.h configure:5289: result: yes configure:5162: checking for unistd.h configure:5168: result: yes configure:5304: checking for an ANSI C-conforming const configure:5379: gcc -c -g -O2 conftest.c >&5 configure:5385: $? = 0 configure:5400: result: yes configure:5410: checking for mode_t configure:5440: gcc -c -g -O2 conftest.c >&5 configure:5446: $? = 0 configure:5461: result: yes configure:5473: checking for size_t configure:5503: gcc -c -g -O2 conftest.c >&5 configure:5509: $? = 0 configure:5524: result: yes configure:5536: checking whether time.h and sys/time.h may both be included configure:5566: gcc -c -g -O2 conftest.c >&5 configure:5572: $? = 0 configure:5587: result: yes configure:5598: checking for uint16_t configure:5629: gcc -c -g -O2 conftest.c >&5 configure:5635: $? = 0 configure:5656: result: yes configure:5670: checking for uint32_t configure:5701: gcc -c -g -O2 conftest.c >&5 configure:5707: $? = 0 configure:5728: result: yes configure:5747: checking whether closedir returns void configure:5781: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:5784: $? = 0 configure:5790: ./conftest configure:5793: $? = 0 configure:5809: result: no configure:5819: checking for pid_t configure:5849: gcc -c -g -O2 conftest.c >&5 configure:5855: $? = 0 configure:5870: result: yes configure:5897: checking vfork.h usability configure:5914: gcc -c -g -O2 conftest.c >&5 conftest.c:78:19: error: vfork.h: No such file or directory configure:5920: $? = 1 configure: failed program was: | /* confdefs.h. */ | #define PACKAGE_NAME "tgif" | #define PACKAGE_TARNAME "tgif" | #define PACKAGE_VERSION "4.2.5" | #define PACKAGE_STRING "tgif 4.2.5" | #define PACKAGE_BUGREPORT "bill.cheng@acm.org" | #define PACKAGE "tgif" | #define VERSION "4.2.5" | #define HAVE_LIBX11 1 | #define HAVE_LIBXT 1 | #define HAVE_LIBNSL 1 | #define HAVE_LIBDL 1 | #define HAVE_LIBIDN 1 | #define HAVE_LIBM 1 | #define HAVE_LIBZ 1 | #define HAVE_LIBPTHREAD 1 | #define HAVE_DIRENT_H 1 | #define STDC_HEADERS 1 | #define HAVE_SYS_WAIT_H 1 | #define HAVE_SYS_TYPES_H 1 | #define HAVE_SYS_STAT_H 1 | #define HAVE_STDLIB_H 1 | #define HAVE_STRING_H 1 | #define HAVE_MEMORY_H 1 | #define HAVE_STRINGS_H 1 | #define HAVE_INTTYPES_H 1 | #define HAVE_STDINT_H 1 | #define HAVE_UNISTD_H 1 | #define HAVE_ARPA_INET_H 1 | #define HAVE_FCNTL_H 1 | #define HAVE_LIBINTL_H 1 | #define HAVE_NETDB_H 1 | #define HAVE_NETINET_IN_H 1 | #define HAVE_STDINT_H 1 | #define HAVE_STDLIB_H 1 | #define HAVE_STRING_H 1 | #define HAVE_SYS_FILE_H 1 | #define HAVE_SYS_IOCTL_H 1 | #define HAVE_SYS_SOCKET_H 1 | #define HAVE_SYS_TIME_H 1 | #define HAVE_SYS_TIMEB_H 1 | #define HAVE_UNISTD_H 1 | #define TIME_WITH_SYS_TIME 1 | /* end confdefs.h. */ | #include <stdio.h> | #ifdef HAVE_SYS_TYPES_H | # include <sys/types.h> | #endif | #ifdef HAVE_SYS_STAT_H | # include <sys/stat.h> | #endif | #ifdef STDC_HEADERS | # include <stdlib.h> | # include <stddef.h> | #else | # ifdef HAVE_STDLIB_H | # include <stdlib.h> | # endif | #endif | #ifdef HAVE_STRING_H | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H | # include <memory.h> | # endif | # include <string.h> | #endif | #ifdef HAVE_STRINGS_H | # include <strings.h> | #endif | #ifdef HAVE_INTTYPES_H | # include <inttypes.h> | #endif | #ifdef HAVE_STDINT_H | # include <stdint.h> | #endif | #ifdef HAVE_UNISTD_H | # include <unistd.h> | #endif | #include <vfork.h> configure:5934: result: no configure:5938: checking vfork.h presence configure:5953: gcc -E conftest.c conftest.c:45:19: error: vfork.h: No such file or directory configure:5959: $? = 1 configure: failed program was: | /* confdefs.h. */ | #define PACKAGE_NAME "tgif" | #define PACKAGE_TARNAME "tgif" | #define PACKAGE_VERSION "4.2.5" | #define PACKAGE_STRING "tgif 4.2.5" | #define PACKAGE_BUGREPORT "bill.cheng@acm.org" | #define PACKAGE "tgif" | #define VERSION "4.2.5" | #define HAVE_LIBX11 1 | #define HAVE_LIBXT 1 | #define HAVE_LIBNSL 1 | #define HAVE_LIBDL 1 | #define HAVE_LIBIDN 1 | #define HAVE_LIBM 1 | #define HAVE_LIBZ 1 | #define HAVE_LIBPTHREAD 1 | #define HAVE_DIRENT_H 1 | #define STDC_HEADERS 1 | #define HAVE_SYS_WAIT_H 1 | #define HAVE_SYS_TYPES_H 1 | #define HAVE_SYS_STAT_H 1 | #define HAVE_STDLIB_H 1 | #define HAVE_STRING_H 1 | #define HAVE_MEMORY_H 1 | #define HAVE_STRINGS_H 1 | #define HAVE_INTTYPES_H 1 | #define HAVE_STDINT_H 1 | #define HAVE_UNISTD_H 1 | #define HAVE_ARPA_INET_H 1 | #define HAVE_FCNTL_H 1 | #define HAVE_LIBINTL_H 1 | #define HAVE_NETDB_H 1 | #define HAVE_NETINET_IN_H 1 | #define HAVE_STDINT_H 1 | #define HAVE_STDLIB_H 1 | #define HAVE_STRING_H 1 | #define HAVE_SYS_FILE_H 1 | #define HAVE_SYS_IOCTL_H 1 | #define HAVE_SYS_SOCKET_H 1 | #define HAVE_SYS_TIME_H 1 | #define HAVE_SYS_TIMEB_H 1 | #define HAVE_UNISTD_H 1 | #define TIME_WITH_SYS_TIME 1 | /* end confdefs.h. */ | #include <vfork.h> configure:5973: result: no configure:6006: checking for vfork.h configure:6014: result: no configure:6032: checking for fork configure:6088: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 conftest.c:68: warning: conflicting types for built-in function 'fork' configure:6094: $? = 0 configure:6112: result: yes configure:6032: checking for vfork configure:6088: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:6094: $? = 0 configure:6112: result: yes configure:6123: checking for working fork configure:6155: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:6158: $? = 0 configure:6164: ./conftest configure:6167: $? = 0 configure:6183: result: yes configure:6204: checking for working vfork configure:6342: result: yes configure:6374: checking whether gcc needs -traditional configure:6416: result: no configure:6423: checking whether lstat dereferences a symlink specified with a trailing slash configure:6459: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:6462: $? = 0 configure:6468: ./conftest configure:6471: $? = 0 configure:6494: result: yes configure:6513: checking whether lstat accepts an empty string configure:6543: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:6546: $? = 0 configure:6552: ./conftest configure:6555: $? = 0 configure:6571: result: no configure:6587: checking whether lstat dereferences a symlink specified with a trailing slash configure:6658: result: yes configure:6682: checking for stdlib.h configure:6688: result: yes configure:6822: checking for GNU libc compatible malloc configure:6856: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:6859: $? = 0 configure:6865: ./conftest configure:6868: $? = 0 configure:6884: result: yes configure:6912: checking for working memcmp configure:6965: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:6968: $? = 0 configure:6974: ./conftest configure:6977: $? = 0 configure:6993: result: yes configure:7007: checking for stdlib.h configure:7013: result: yes configure:7147: checking for GNU libc compatible realloc configure:7181: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7184: $? = 0 configure:7190: ./conftest configure:7193: $? = 0 configure:7209: result: yes configure:7253: checking sys/select.h usability configure:7270: gcc -c -g -O2 conftest.c >&5 configure:7276: $? = 0 configure:7290: result: yes configure:7294: checking sys/select.h presence configure:7309: gcc -E conftest.c configure:7315: $? = 0 configure:7329: result: yes configure:7362: checking for sys/select.h configure:7370: result: yes configure:7243: checking for sys/socket.h configure:7249: result: yes configure:7383: checking types of arguments for select configure:7421: gcc -c -g -O2 conftest.c >&5 configure:7427: $? = 0 configure:7448: result: int,fd_set *,struct timeval * configure:7471: checking return type of signal handlers configure:7499: gcc -c -g -O2 conftest.c >&5 conftest.c: In function 'main': conftest.c:66: error: void value not ignored as it ought to be configure:7505: $? = 1 configure: failed program was: | /* confdefs.h. */ | #define PACKAGE_NAME "tgif" | #define PACKAGE_TARNAME "tgif" | #define PACKAGE_VERSION "4.2.5" | #define PACKAGE_STRING "tgif 4.2.5" | #define PACKAGE_BUGREPORT "bill.cheng@acm.org" | #define PACKAGE "tgif" | #define VERSION "4.2.5" | #define HAVE_LIBX11 1 | #define HAVE_LIBXT 1 | #define HAVE_LIBNSL 1 | #define HAVE_LIBDL 1 | #define HAVE_LIBIDN 1 | #define HAVE_LIBM 1 | #define HAVE_LIBZ 1 | #define HAVE_LIBPTHREAD 1 | #define HAVE_DIRENT_H 1 | #define STDC_HEADERS 1 | #define HAVE_SYS_WAIT_H 1 | #define HAVE_SYS_TYPES_H 1 | #define HAVE_SYS_STAT_H 1 | #define HAVE_STDLIB_H 1 | #define HAVE_STRING_H 1 | #define HAVE_MEMORY_H 1 | #define HAVE_STRINGS_H 1 | #define HAVE_INTTYPES_H 1 | #define HAVE_STDINT_H 1 | #define HAVE_UNISTD_H 1 | #define HAVE_ARPA_INET_H 1 | #define HAVE_FCNTL_H 1 | #define HAVE_LIBINTL_H 1 | #define HAVE_NETDB_H 1 | #define HAVE_NETINET_IN_H 1 | #define HAVE_STDINT_H 1 | #define HAVE_STDLIB_H 1 | #define HAVE_STRING_H 1 | #define HAVE_SYS_FILE_H 1 | #define HAVE_SYS_IOCTL_H 1 | #define HAVE_SYS_SOCKET_H 1 | #define HAVE_SYS_TIME_H 1 | #define HAVE_SYS_TIMEB_H 1 | #define HAVE_UNISTD_H 1 | #define TIME_WITH_SYS_TIME 1 | #define HAVE_FORK 1 | #define HAVE_VFORK 1 | #define HAVE_WORKING_VFORK 1 | #define HAVE_WORKING_FORK 1 | #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1 | #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1 | #define HAVE_STDLIB_H 1 | #define HAVE_MALLOC 1 | #define HAVE_STDLIB_H 1 | #define HAVE_REALLOC 1 | #define HAVE_SYS_SELECT_H 1 | #define HAVE_SYS_SOCKET_H 1 | #define SELECT_TYPE_ARG1 int | #define SELECT_TYPE_ARG234 (fd_set *) | #define SELECT_TYPE_ARG5 (struct timeval *) | /* end confdefs.h. */ | #include <sys/types.h> | #include <signal.h> | | int | main () | { | return *(signal (0, 0)) (0) == 1; | ; | return 0; | } configure:7520: result: void configure:7528: checking whether stat accepts an empty string configure:7558: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7561: $? = 0 configure:7567: ./conftest configure:7570: $? = 0 configure:7586: result: no configure:7602: checking for working strtod configure:7653: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7656: $? = 0 configure:7662: ./conftest configure:7665: $? = 0 configure:7681: result: yes configure:7867: checking for ftime configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for getcwd configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for gethostbyname configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for gethostname configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for gettimeofday configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for memmove configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 conftest.c:89: warning: conflicting types for built-in function 'memmove' configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for memset configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 conftest.c:90: warning: conflicting types for built-in function 'memset' configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for mkdir configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for pow configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 conftest.c:92: warning: conflicting types for built-in function 'pow' configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for putenv configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for select configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for setlocale configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for socket configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for sqrt configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 conftest.c:97: warning: conflicting types for built-in function 'sqrt' configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for strchr configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 conftest.c:98: warning: conflicting types for built-in function 'strchr' configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for strpbrk configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 conftest.c:99: warning: conflicting types for built-in function 'strpbrk' configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for strrchr configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 conftest.c:100: warning: conflicting types for built-in function 'strrchr' configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for strstr configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 conftest.c:101: warning: conflicting types for built-in function 'strstr' configure:7929: $? = 0 configure:7947: result: yes configure:7867: checking for strtol configure:7923: gcc -o conftest -g -O2 conftest.c -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 >&5 configure:7929: $? = 0 configure:7947: result: yes configure:8075: creating ./config.status ## ---------------------- ## ## Running config.status. ## ## ---------------------- ## This file was extended by tgif config.status 4.2.5, which was generated by GNU Autoconf 2.61. Invocation command line was CONFIG_FILES = CONFIG_HEADERS = CONFIG_LINKS = CONFIG_COMMANDS = $ ./config.status on merlot.usc.edu config.status:637: creating Makefile config.status:637: creating config.h config.status:976: executing depfiles commands ## ---------------- ## ## Cache variables. ## ## ---------------- ## ac_cv_c_compiler_gnu=yes ac_cv_c_const=yes ac_cv_c_uint16_t=yes ac_cv_c_uint32_t=yes ac_cv_env_CC_set= ac_cv_env_CC_value= ac_cv_env_CFLAGS_set= ac_cv_env_CFLAGS_value= ac_cv_env_CPPFLAGS_set= ac_cv_env_CPPFLAGS_value= ac_cv_env_CPP_set= ac_cv_env_CPP_value= ac_cv_env_LDFLAGS_set= ac_cv_env_LDFLAGS_value= ac_cv_env_LIBS_set= ac_cv_env_LIBS_value= ac_cv_env_XMKMF_set= ac_cv_env_XMKMF_value= ac_cv_env_build_alias_set= ac_cv_env_build_alias_value= ac_cv_env_host_alias_set= ac_cv_env_host_alias_value= ac_cv_env_target_alias_set= ac_cv_env_target_alias_value= ac_cv_func_closedir_void=no ac_cv_func_fork=yes ac_cv_func_fork_works=yes ac_cv_func_ftime=yes ac_cv_func_getcwd=yes ac_cv_func_gethostbyname=yes ac_cv_func_gethostname=yes ac_cv_func_gettimeofday=yes ac_cv_func_lstat_dereferences_slashed_symlink=yes ac_cv_func_lstat_empty_string_bug=no ac_cv_func_malloc_0_nonnull=yes ac_cv_func_memcmp_working=yes ac_cv_func_memmove=yes ac_cv_func_memset=yes ac_cv_func_mkdir=yes ac_cv_func_pow=yes ac_cv_func_putenv=yes ac_cv_func_realloc_0_nonnull=yes ac_cv_func_select=yes ac_cv_func_select_args='int,fd_set *,struct timeval *' ac_cv_func_setlocale=yes ac_cv_func_socket=yes ac_cv_func_sqrt=yes ac_cv_func_stat_empty_string_bug=no ac_cv_func_strchr=yes ac_cv_func_strpbrk=yes ac_cv_func_strrchr=yes ac_cv_func_strstr=yes ac_cv_func_strtod=yes ac_cv_func_strtol=yes ac_cv_func_vfork=yes ac_cv_func_vfork_works=yes ac_cv_have_x='have_x=yes ac_x_includes='\'''\'' ac_x_libraries='\'''\''' ac_cv_header_arpa_inet_h=yes ac_cv_header_dirent_dirent_h=yes ac_cv_header_fcntl_h=yes ac_cv_header_inttypes_h=yes ac_cv_header_libintl_h=yes ac_cv_header_memory_h=yes ac_cv_header_netdb_h=yes ac_cv_header_netinet_in_h=yes ac_cv_header_stdc=yes ac_cv_header_stdint_h=yes ac_cv_header_stdlib_h=yes ac_cv_header_string_h=yes ac_cv_header_strings_h=yes ac_cv_header_sys_file_h=yes ac_cv_header_sys_ioctl_h=yes ac_cv_header_sys_select_h=yes ac_cv_header_sys_socket_h=yes ac_cv_header_sys_stat_h=yes ac_cv_header_sys_time_h=yes ac_cv_header_sys_timeb_h=yes ac_cv_header_sys_types_h=yes ac_cv_header_sys_wait_h=yes ac_cv_header_time=yes ac_cv_header_unistd_h=yes ac_cv_header_vfork_h=no ac_cv_lib_X11_XOpenDisplay=yes ac_cv_lib_Xt_XtInitialize=yes ac_cv_lib_dl_dlsym=yes ac_cv_lib_idn_stringprep_convert=yes ac_cv_lib_m_pow=yes ac_cv_lib_nsl_inet_addr=yes ac_cv_lib_pthread_pthread_create=yes ac_cv_lib_socket_socket=no ac_cv_lib_z_deflate=yes ac_cv_objext=o ac_cv_path_EGREP='/bin/grep -E' ac_cv_path_GREP=/bin/grep ac_cv_path_install='/usr/bin/install -c' ac_cv_path_mkdir=/bin/mkdir ac_cv_prog_AWK=gawk ac_cv_prog_CPP='gcc -E' ac_cv_prog_ac_ct_CC=gcc ac_cv_prog_cc_c89= ac_cv_prog_cc_g=yes ac_cv_prog_gcc_traditional=no ac_cv_prog_make_make_set=yes ac_cv_search_opendir='none required' ac_cv_type_mode_t=yes ac_cv_type_pid_t=yes ac_cv_type_signal=void ac_cv_type_size_t=yes am_cv_CC_dependencies_compiler_type=gcc3 ## ----------------- ## ## Output variables. ## ## ----------------- ## ACLOCAL='${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run aclocal-1.10' AMDEPBACKSLASH='\' AMDEP_FALSE='#' AMDEP_TRUE='' AMTAR='${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run tar' AUTOCONF='${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run autoconf' AUTOHEADER='${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run autoheader' AUTOMAKE='${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run automake-1.10' AWK='gawk' CC='gcc' CCDEPMODE='depmode=gcc3' CFLAGS='-g -O2' CPP='gcc -E' CPPFLAGS='' CYGPATH_W='echo' DEFS='-DHAVE_CONFIG_H' DEPDIR='.deps' ECHO_C='' ECHO_N='-n' ECHO_T='' EGREP='/bin/grep -E' EXEEXT='' GREP='/bin/grep' INSTALL_DATA='${INSTALL} -m 644' INSTALL_PROGRAM='${INSTALL}' INSTALL_SCRIPT='${INSTALL}' INSTALL_STRIP_PROGRAM='$(install_sh) -c -s' LDFLAGS='' LIBOBJS='' LIBS='-lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 ' LTLIBOBJS='' MAKEINFO='${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run makeinfo' OBJEXT='o' PACKAGE='tgif' PACKAGE_BUGREPORT='bill.cheng@acm.org' PACKAGE_NAME='tgif' PACKAGE_STRING='tgif 4.2.5' PACKAGE_TARNAME='tgif' PACKAGE_VERSION='4.2.5' PATH_SEPARATOR=':' POW_LIB='' SET_MAKE='' SHELL='/bin/sh' STRIP='' VERSION='4.2.5' XMKMF='' ac_ct_CC='gcc' am__fastdepCC_FALSE='#' am__fastdepCC_TRUE='' am__include='include' am__isrc='' am__leading_dot='.' am__quote='' am__tar='${AMTAR} chof - "$$tardir"' am__untar='${AMTAR} xf -' bindir='${exec_prefix}/bin' build_alias='' datadir='${datarootdir}' datarootdir='${prefix}/share' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' dvidir='${docdir}' exec_prefix='${prefix}' host_alias='' htmldir='${docdir}' includedir='${prefix}/include' infodir='${datarootdir}/info' install_sh='$(SHELL) /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/install-sh' libdir='${exec_prefix}/lib' libexecdir='${exec_prefix}/libexec' localedir='${datarootdir}/locale' localstatedir='${prefix}/var' mandir='${datarootdir}/man' mkdir_p='/bin/mkdir -p' oldincludedir='/usr/include' pdfdir='${docdir}' prefix='/usr/local' program_transform_name='s,x,x,' psdir='${docdir}' sbindir='${exec_prefix}/sbin' sharedstatedir='${prefix}/com' sysconfdir='${prefix}/etc' target_alias='' ## ----------- ## ## confdefs.h. ## ## ----------- ## #define PACKAGE_NAME "tgif" #define PACKAGE_TARNAME "tgif" #define PACKAGE_VERSION "4.2.5" #define PACKAGE_STRING "tgif 4.2.5" #define PACKAGE_BUGREPORT "bill.cheng@acm.org" #define PACKAGE "tgif" #define VERSION "4.2.5" #define HAVE_LIBX11 1 #define HAVE_LIBXT 1 #define HAVE_LIBNSL 1 #define HAVE_LIBDL 1 #define HAVE_LIBIDN 1 #define HAVE_LIBM 1 #define HAVE_LIBZ 1 #define HAVE_LIBPTHREAD 1 #define HAVE_DIRENT_H 1 #define STDC_HEADERS 1 #define HAVE_SYS_WAIT_H 1 #define HAVE_SYS_TYPES_H 1 #define HAVE_SYS_STAT_H 1 #define HAVE_STDLIB_H 1 #define HAVE_STRING_H 1 #define HAVE_MEMORY_H 1 #define HAVE_STRINGS_H 1 #define HAVE_INTTYPES_H 1 #define HAVE_STDINT_H 1 #define HAVE_UNISTD_H 1 #define HAVE_ARPA_INET_H 1 #define HAVE_FCNTL_H 1 #define HAVE_LIBINTL_H 1 #define HAVE_NETDB_H 1 #define HAVE_NETINET_IN_H 1 #define HAVE_STDINT_H 1 #define HAVE_STDLIB_H 1 #define HAVE_STRING_H 1 #define HAVE_SYS_FILE_H 1 #define HAVE_SYS_IOCTL_H 1 #define HAVE_SYS_SOCKET_H 1 #define HAVE_SYS_TIME_H 1 #define HAVE_SYS_TIMEB_H 1 #define HAVE_UNISTD_H 1 #define TIME_WITH_SYS_TIME 1 #define HAVE_FORK 1 #define HAVE_VFORK 1 #define HAVE_WORKING_VFORK 1 #define HAVE_WORKING_FORK 1 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1 #define HAVE_STDLIB_H 1 #define HAVE_MALLOC 1 #define HAVE_STDLIB_H 1 #define HAVE_REALLOC 1 #define HAVE_SYS_SELECT_H 1 #define HAVE_SYS_SOCKET_H 1 #define SELECT_TYPE_ARG1 int #define SELECT_TYPE_ARG234 (fd_set *) #define SELECT_TYPE_ARG5 (struct timeval *) #define RETSIGTYPE void #define HAVE_FTIME 1 #define HAVE_GETCWD 1 #define HAVE_GETHOSTBYNAME 1 #define HAVE_GETHOSTNAME 1 #define HAVE_GETTIMEOFDAY 1 #define HAVE_MEMMOVE 1 #define HAVE_MEMSET 1 #define HAVE_MKDIR 1 #define HAVE_POW 1 #define HAVE_PUTENV 1 #define HAVE_SELECT 1 #define HAVE_SETLOCALE 1 #define HAVE_SOCKET 1 #define HAVE_SQRT 1 #define HAVE_STRCHR 1 #define HAVE_STRPBRK 1 #define HAVE_STRRCHR 1 #define HAVE_STRSTR 1 #define HAVE_STRTOL 1 configure: exit 0 ��tgif-QPL-4.2.5/oval.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000107334�11602233312�014101� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/oval.c,v 1.11 2011/06/09 16:11:42 cvsps Exp $ */ #define _INCLUDE_FROM_OVAL_C_ #include "tgifdefs.h" #include "attr.e" #include "auxtext.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "grid.e" #include "mainloop.e" #include "mark.e" #include "msg.e" #include "obj.e" #include "oval.e" #include "pattern.e" #include "poly.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "spline.e" #include "strtbl.e" #include "util.e" #include "xpixmap.e" int ovalDrawn=FALSE; static void GetPSEllipseStr(xc, yc, a, b, s) int xc, yc, a, b; char *s; { if (preDumpSetup) PSUseEllipse(); #ifdef INVERT_CTM_BUG if (preDumpSetup) PSUseMinRadius(); sprintf(s, "%s %1d %1d %1d %s %1d %s TGEL", gPsCmd[PS_NEWPATH], xc, yc, a, "tgif_min_radius", b, "tgif_min_radius"); #else sprintf(s, "%s %1d %1d %1d %1d TGEL", gPsCmd[PS_NEWPATH], xc, yc, a, b); #endif } void MyOval(window, gc, bbox) Window window; GC gc; struct BBRec bbox; { int ltx, lty, w, h; if (bbox.ltx > bbox.rbx) { ltx = bbox.rbx; w = bbox.ltx - ltx; } else { ltx = bbox.ltx; w = bbox.rbx - ltx; } if (bbox.lty > bbox.rby) { lty = bbox.rby; h = bbox.lty - lty; } else { lty = bbox.lty; h = bbox.rby - lty; } XDrawArc(mainDisplay, window, gc, ltx, lty, w, h, 0, (360<<6)); } static void DumpOvalPath(FP, ObjPtr, Xc, Yc, A, B, Width, Pen, Dash, TransPat) FILE *FP; struct ObjRec *ObjPtr; int Xc, Yc, A, B, Width, Pen, Dash, TransPat; { register int i; int w_is_int=TRUE; char *width_spec=ObjPtr->detail.o->width_spec; double dw=GetWidthInDouble(Width, width_spec, &w_is_int); char s[MAXSTRING]; fprintf(FP, " %s\n", gPsCmd[PS_GSAVE]); if (!colorDump && useGray && Pen > BACKPAT) { GrayCheck(Pen); fprintf(FP, " %s %s\n", GrayStr(Pen), gPsCmd[PS_SETGRAY]); } GetPSEllipseStr(Xc, Yc, A, B, s); fprintf(FP, " %s\n", s); if (ObjPtr->ctm != NULL) { fprintf(FP, " %s\n", &(gPsCmd[PS_TGIFSETMATRIX])[1]); } if (w_is_int) { if (Width != 1) { fprintf(FP, " %1d %s\n", Width, gPsCmd[PS_SETLINEWIDTH]); } } else { fprintf(FP, " %.3f %s\n", dw, gPsCmd[PS_SETLINEWIDTH]); } if (Dash != 0) { fprintf(FP, " ["); for (i = 0; i < dashListLength[Dash]-1; i++) { fprintf(FP, "%1d ", (int)(dashList[Dash][i])); } fprintf(FP, "%1d] 0 %s\n", (int)(dashList[Dash][dashListLength[Dash]-1]), gPsCmd[PS_SETDASH]); } switch (Pen) { case SOLIDPAT: fprintf(FP, " %s\n", gPsCmd[PS_STROKE]); break; case BACKPAT: if (!TransPat) { fprintf(FP, " 1 %s %s 0 %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_STROKE], gPsCmd[PS_SETGRAY]); } break; default: if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); fprintf(FP, " %s\n", gPsCmd[PS_FLATTENPATH]); DumpPatFill(FP, Pen, ObjPtr->bbox, 6, TRUE); } else { fprintf(FP, " %s\n", gPsCmd[PS_STROKE]); } break; } fprintf(FP, " %s\n", gPsCmd[PS_GRESTORE]); } void DumpOvalObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { int ltx, lty, rbx, rby, xc, yc, a, b; int trans_pat, fill, width, pen, dash, color_index; char s[MAXSTRING]; struct OvalRec *oval_ptr=ObjPtr->detail.o; if (ObjPtr->ctm == NULL) { ltx = ObjPtr->obbox.ltx; lty = ObjPtr->obbox.lty; rbx = ObjPtr->obbox.rbx; rby = ObjPtr->obbox.rby; } else { ltx = ObjPtr->orig_obbox.ltx; lty = ObjPtr->orig_obbox.lty; rbx = ObjPtr->orig_obbox.rbx; rby = ObjPtr->orig_obbox.rby; } a = (rbx - ltx) / 2; xc = ltx + a; b = (rby - lty) / 2; yc = lty + b; trans_pat = ObjPtr->trans_pat; fill = oval_ptr->fill; width = oval_ptr->width; pen = oval_ptr->pen; dash = oval_ptr->dash; if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } fprintf(FP, "%% OVAL\n"); if (ObjPtr->ctm != NULL) { float m[6]; fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); m[CTM_SX] = ((float)ObjPtr->ctm->m[CTM_SX])/((float)1000.0); m[CTM_SY] = ((float)ObjPtr->ctm->m[CTM_SY])/((float)1000.0); m[CTM_SIN] = ((float)ObjPtr->ctm->m[CTM_SIN])/((float)1000.0); m[CTM_MSIN] = ((float)ObjPtr->ctm->m[CTM_MSIN])/((float)1000.0); fprintf(FP, " %1d %1d %s\n", ObjPtr->x, ObjPtr->y, gPsCmd[PS_TRANSLATE]); fprintf(FP, " [%.3f %.3f %.3f %.3f %1d %1d] %s\n", m[CTM_SX], m[CTM_SIN], m[CTM_MSIN], m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY], gPsCmd[PS_CONCAT]); fprintf(FP, " %1d %s %1d %s %s\n", ObjPtr->x, gPsCmd[PS_NEG], ObjPtr->y, gPsCmd[PS_NEG], gPsCmd[PS_TRANSLATE]); } color_index = ObjPtr->color; DumpRGBColorLine(FP, color_index, 0, TRUE); GetPSEllipseStr(xc, yc, a, b, s); switch (fill) { case NONEPAT: break; case SOLIDPAT: /* solid black oval */ fprintf(FP, "%s %s\n", s, gPsCmd[PS_FILL]); break; case BACKPAT: /* solid white oval */ if (!trans_pat) { fprintf(FP, "%s\n", s); fprintf(FP, "%s 1 %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 3, TRUE); } break; default: /* patterned */ fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); if (!trans_pat) { fprintf(FP, " %s\n", s); fprintf(FP, " %s 1 %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, color_index, 3, TRUE); } fprintf(FP, " %s\n", s); fprintf(FP, " %s %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_EOCLIP], gPsCmd[PS_NEWPATH]); DumpPatFill(FP, fill, ObjPtr->bbox, 3, TRUE); } else { GrayCheck(fill); fprintf(FP, " %s %s\n", GrayStr(fill), gPsCmd[PS_SETGRAY]); fprintf(FP, " %s %s\n", s, gPsCmd[PS_FILL]); } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); break; } if (pen == NONEPAT) { if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); return; } fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if ((colorDump || !useGray) && pen > BACKPAT) { if (!trans_pat) { DumpOvalPath(FP, ObjPtr, xc, yc, a, b, width, BACKPAT, 0, trans_pat); DumpRGBColorLine(FP, color_index, 3, TRUE); } } DumpOvalPath(FP, ObjPtr, xc, yc, a, b, width, pen, dash, trans_pat); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); } int NeedsToCacheOvalObj(ObjPtr) struct ObjRec *ObjPtr; { return (ObjPtr->ctm != NULL); } static double ovalXMag1=(double)0.0, ovalYMag1=(double)0.0; static double ovalXMag2=(double)0.0, ovalYMag2=(double)0.0; static void MakeCachedOval(ObjPtr) struct ObjRec *ObjPtr; { register int i; int sn, cntrln, saved_zoomedin, saved_zoomscale, saved_x, saved_y; struct OvalRec *oval_ptr=ObjPtr->detail.o; XPoint *sv=NULL; DoublePoint *tmp_sv=NULL, *pv=NULL, *cntrlv=NULL; struct BBRec obbox; double w, h, cx, cy; if (ovalXMag1 == (double)0.0) { ovalXMag1 = (double)cos((double)(28.6*M_PI/180.0)); ovalYMag1 = (double)sin((double)(28.6*M_PI/180.0)); ovalXMag2 = (double)cos((double)(61.4*M_PI/180.0)); ovalYMag2 = (double)sin((double)(61.4*M_PI/180.0)); } if (ObjPtr->ctm == NULL) return; if (oval_ptr->rotated_vlist != NULL) free(oval_ptr->rotated_vlist); oval_ptr->rotated_n = 0; oval_ptr->rotated_vlist = NULL; tmp_sv = (DoublePoint*)malloc((13+1)*sizeof(DoublePoint)); pv = (DoublePoint*)malloc((13+1)*sizeof(DoublePoint)); if (tmp_sv == NULL || pv == NULL) FailAllocMessage(); obbox.ltx = ObjPtr->orig_obbox.ltx - ObjPtr->x; obbox.lty = ObjPtr->orig_obbox.lty - ObjPtr->y; obbox.rbx = ObjPtr->orig_obbox.rbx - ObjPtr->x; obbox.rby = ObjPtr->orig_obbox.rby - ObjPtr->y; cx = (((double)(obbox.ltx+obbox.rbx))/2.0); cy = (((double)(obbox.lty+obbox.rby))/2.0); w = (((double)(obbox.rbx-obbox.ltx))/2.0); h = (((double)(obbox.rby-obbox.lty))/2.0); tmp_sv[0].x = (double)obbox.rbx; tmp_sv[0].y = (double)cy; tmp_sv[1].x = ((double)cx)+(w*ovalXMag1); tmp_sv[1].y = ((double)cy)-(h*ovalYMag1); tmp_sv[2].x = ((double)cx)+(w*ovalXMag2); tmp_sv[2].y = ((double)cy)-(h*ovalYMag2); tmp_sv[3].x = (double)cx; tmp_sv[3].y = (double)obbox.lty; tmp_sv[4].x = ((double)cx)-(w*ovalXMag2); tmp_sv[4].y = ((double)cy)-(h*ovalYMag2); tmp_sv[5].x = ((double)cx)-(w*ovalXMag1); tmp_sv[5].y = ((double)cy)-(h*ovalYMag1); tmp_sv[6].x = (double)obbox.ltx; tmp_sv[6].y = (double)cy; tmp_sv[7].x = ((double)cx)-(w*ovalXMag1); tmp_sv[7].y = ((double)cy)+(h*ovalYMag1); tmp_sv[8].x = ((double)cx)-(w*ovalXMag2); tmp_sv[8].y = ((double)cy)+(h*ovalYMag2); tmp_sv[9].x = (double)cx; tmp_sv[9].y = (double)obbox.rby; tmp_sv[10].x = ((double)cx)+(w*ovalXMag2); tmp_sv[10].y = ((double)cy)+(h*ovalYMag2); tmp_sv[11].x = ((double)cx)+(w*ovalXMag1); tmp_sv[11].y = ((double)cy)+(h*ovalYMag1); tmp_sv[12].x = tmp_sv[0].x; tmp_sv[12].y = tmp_sv[0].y; for (i=0; i < 13; i++) { double x, y; TransformDoublePointThroughCTM(tmp_sv[i].x, tmp_sv[i].y, ObjPtr->ctm, &x, &y); tmp_sv[i].x = pv[i].x = OFFSET_DOUBLE_X(x + (double)ObjPtr->x); tmp_sv[i].y = pv[i].y = OFFSET_DOUBLE_Y(y + (double)ObjPtr->y); } saved_zoomedin = zoomedIn; saved_zoomscale = zoomScale; saved_x = drawOrigX; saved_y = drawOrigY; zoomedIn = FALSE; zoomScale = 0; drawOrigX = drawOrigY = 0; sv = MakeDoubleIntSplinePolygonVertex(&sn, &cntrln, &cntrlv, drawOrigX, drawOrigY, 13, pv); zoomedIn = saved_zoomedin; zoomScale = saved_zoomscale; drawOrigX = saved_x; drawOrigY = saved_y; free(pv); if (sv != NULL) { free(tmp_sv); oval_ptr->rotated_n = sn; oval_ptr->rotated_vlist = sv; } else { oval_ptr->rotated_n = 13; } if (cntrlv != NULL) free(cntrlv); } void DrawOvalObj(window, XOff, YOff, ObjPtr) Window window; int XOff, YOff; struct ObjRec *ObjPtr; { int trans_pat, fill, width, pen, dash, pixel, real_x_off, real_y_off; struct BBRec bbox; XGCValues values; struct OvalRec *oval_ptr=ObjPtr->detail.o; real_x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); real_y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); bbox.ltx = ZOOMED_SIZE(ObjPtr->obbox.ltx - real_x_off); bbox.lty = ZOOMED_SIZE(ObjPtr->obbox.lty - real_y_off); bbox.rbx = ZOOMED_SIZE(ObjPtr->obbox.rbx - real_x_off); bbox.rby = ZOOMED_SIZE(ObjPtr->obbox.rby - real_y_off); trans_pat = ObjPtr->trans_pat; fill = oval_ptr->fill; width = oval_ptr->width; pen = oval_ptr->pen; dash = oval_ptr->dash; pixel = colorPixels[ObjPtr->color]; if (NeedsToCacheOvalObj(ObjPtr) && oval_ptr->rotated_vlist==NULL) { MakeCachedOval(ObjPtr); } if (userDisableRedraw) return; if (fill != NONEPAT) { values.foreground = GetDrawingBgPixel(fill, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[fill]; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple, &values); if (ObjPtr->ctm != NULL) { XFillPolygon(mainDisplay, window, drawGC, oval_ptr->rotated_vlist, oval_ptr->rotated_n, Convex, CoordModeOrigin); } else { XFillArc(mainDisplay, window, drawGC, bbox.ltx, bbox.lty, bbox.rbx-bbox.ltx, bbox.rby-bbox.lty, 0, (360<<6)); } } if (pen != NONEPAT) { values.foreground = GetDrawingBgPixel(pen, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[pen]; values.line_width = ZOOMED_SIZE(width); #ifdef NO_THIN_LINE if (values.line_width < 1) values.line_width = 1; #else #ifdef THIN_OVAL_AND_ARC if (values.line_width <= 1) values.line_width = 0; #endif #endif if (dash != 0) { XSetDashes(mainDisplay, drawGC, 0, dashList[dash], dashListLength[dash]); values.line_style = LineOnOffDash; } else { values.line_style = LineSolid; } XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | GCLineStyle, &values); if (ObjPtr->ctm != NULL) { XDrawLines(mainDisplay, window, drawGC, oval_ptr->rotated_vlist, oval_ptr->rotated_n, CoordModeOrigin); } else { XDrawArc(mainDisplay, window, drawGC, bbox.ltx, bbox.lty, bbox.rbx-bbox.ltx, bbox.rby-bbox.lty, 0, (360<<6)); } } } void CreateOvalObj(BBox, CreateAbsolute) struct BBRec *BBox; int CreateAbsolute; { struct OvalRec *oval_ptr; struct ObjRec *obj_ptr; int width, w; oval_ptr = (struct OvalRec *)malloc(sizeof(struct OvalRec)); if (oval_ptr == NULL) FailAllocMessage(); memset(oval_ptr, 0, sizeof(struct OvalRec)); oval_ptr->fill = objFill; oval_ptr->width = width = curWidthOfLine[lineWidth]; UtilStrCpyN(oval_ptr->width_spec, sizeof(oval_ptr->width_spec), curWidthOfLineSpec[lineWidth]); oval_ptr->pen = penPat; oval_ptr->dash = curDash; oval_ptr->rotated_n = 0; oval_ptr->rotated_vlist = NULL; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); if (CreateAbsolute) { obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = BBox->ltx; obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = BBox->lty; obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = BBox->rbx; obj_ptr->bbox.rby = obj_ptr->obbox.rby = BBox->rby; } else { obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = ABS_X(BBox->ltx); obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = ABS_Y(BBox->lty); obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = ABS_X(BBox->rbx); obj_ptr->bbox.rby = obj_ptr->obbox.rby = ABS_Y(BBox->rby); } w = HALF_W(width); obj_ptr->bbox.ltx -= w; obj_ptr->bbox.lty -= w; obj_ptr->bbox.rbx += w; obj_ptr->bbox.rby += w; obj_ptr->type = OBJ_OVAL; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->id = objId++; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->locked = FALSE; obj_ptr->detail.o = oval_ptr; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; obj_ptr->invisible = FALSE; obj_ptr->trans_pat = transPat; AddObj(NULL, topObj, obj_ptr); } static void AdjContinueOvalBBox(pBBoxIn, pBBoxOut) struct BBRec *pBBoxIn, *pBBoxOut; { int w, h, cx, cy; double dx, dy, r; switch (curChoice) { case DRAWCORNEROVAL: memcpy(pBBoxOut, pBBoxIn, sizeof(struct BBRec)); break; case DRAWCENTEROVAL: w = pBBoxIn->rbx - pBBoxIn->ltx; h = pBBoxIn->rby - pBBoxIn->lty; pBBoxOut->ltx = pBBoxIn->rbx - (w<<1); pBBoxOut->lty = pBBoxIn->rby - (h<<1); pBBoxOut->rbx = pBBoxIn->rbx; pBBoxOut->rby = pBBoxIn->rby; break; case DRAWEDGECIRCLE: cx = ((pBBoxIn->rbx + pBBoxIn->ltx) >> 1); cy = ((pBBoxIn->rby + pBBoxIn->lty) >> 1); dx = (double)(cx - pBBoxIn->ltx); dy = (double)(cy - pBBoxIn->lty); r = (double)sqrt(dx*dx+dy*dy); w = round(r); pBBoxOut->ltx = cx-w; pBBoxOut->lty = cy-w; pBBoxOut->rbx = cx+w; pBBoxOut->rby = cy+w; break; } } static void MyContinueOval(d, gc, pBBox) Drawable d; GC gc; struct BBRec *pBBox; { struct BBRec bbox; AdjContinueOvalBBox(pBBox, &bbox); MyOval(d, gc, bbox); } static void ContinueOval(OrigX, OrigY) int OrigX, OrigY; { int end_x, end_y, grid_x, grid_y, done=FALSE, abort=FALSE; char buf[80], w_buf[80], h_buf[80], x_buf[80], y_buf[80]; struct BBRec bbox; XEvent input, ev; XMotionEvent *motion_ev=NULL; bbox.ltx = bbox.rbx = OrigX; bbox.lty = bbox.rby = OrigY; SetXorDrawGC(xorColorPixels[colorIndex]); grid_x = end_x = OrigX; grid_y = end_y = OrigY; PixelToMeasurementUnit(w_buf, 0); PixelToMeasurementUnit(h_buf, 0); PixelToMeasurementUnit(x_buf, ABS_X(grid_x)); PixelToMeasurementUnit(y_buf, ABS_Y(grid_y)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); StartShowMeasureCursor(grid_x, grid_y, buf, TRUE); BeginIntervalRulers(grid_x, grid_y, grid_x, grid_y); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } while (!done) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); SetXorDrawGC(xorColorPixels[colorIndex]); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); MyContinueOval(drawWindow, drawGC, &bbox); EndIntervalRulers(grid_x, grid_y); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(bbox.rbx-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(bbox.rby-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(bbox.rbx)); PixelToMeasurementUnit(y_buf, ABS_Y(bbox.rby)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); EndShowMeasureCursor(bbox.rbx, bbox.rby, buf, TRUE); done = TRUE; } else if (input.type == MotionNotify || input.type == KeyPress || input.type == KeyRelease) { if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { XUngrabPointer(mainDisplay, CurrentTime); MyContinueOval(drawWindow, drawGC, &bbox); EndIntervalRulers(grid_x, grid_y); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(bbox.rbx-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(bbox.rby-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(bbox.rbx)); PixelToMeasurementUnit(y_buf, ABS_Y(bbox.rby)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); EndShowMeasureCursor(bbox.rbx, bbox.rby, buf, TRUE); abort = TRUE; done = TRUE; } } if (done) { break; } motion_ev = (&(input.xmotion)); if (input.type == KeyPress || input.type == KeyRelease) { end_x = grid_x; end_y = grid_y; } else { end_x = motion_ev->x; end_y = motion_ev->y; } if (curChoice == DRAWEDGECIRCLE && shiftForDiagMouseMove && DiagEventCheck(&input)) { if (input.type == KeyRelease) { end_x = input.xkey.x; end_y = input.xkey.y; } else { DiagGridXY(OrigX, OrigY, &end_x, &end_y); } } GridXY(end_x, end_y, &grid_x, &grid_y); if (input.type == MotionNotify && curChoice != DRAWEDGECIRCLE && (motion_ev->state & (ShiftMask | ControlMask)) != 0) { int w, h, pos_w=TRUE, pos_h=TRUE; w = grid_x - bbox.ltx; h = grid_y - bbox.lty; if (w < 0) { w = (-w); pos_w = FALSE; } if (h < 0) { h = (-h); pos_h = FALSE; } if (w > h) { grid_x = (pos_w ? (bbox.ltx+h) : (bbox.ltx-h)); } else { grid_y = (pos_h ? (bbox.lty+w) : (bbox.lty-w)); } } if (grid_x != bbox.rbx || grid_y != bbox.rby) { PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(bbox.rbx-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(bbox.rby-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(bbox.rbx)); PixelToMeasurementUnit(y_buf, ABS_Y(bbox.rby)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); ShowMeasureCursor(bbox.rbx, bbox.rby, buf, TRUE); MyContinueOval(drawWindow, drawGC, &bbox); bbox.rbx = grid_x; bbox.rby = grid_y; MyContinueOval(drawWindow, drawGC, &bbox); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(bbox.rbx-OrigX))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(bbox.rby-OrigY))); PixelToMeasurementUnit(x_buf, ABS_X(bbox.rbx)); PixelToMeasurementUnit(y_buf, ABS_Y(bbox.rby)); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); ShowMeasureCursor(bbox.rbx, bbox.rby, buf, TRUE); } DrawIntervalRulers(OrigX, OrigY, grid_x, grid_y, NULL); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } if (!abort && ((curChoice!=DRAWEDGECIRCLE && OrigX!=grid_x && OrigY!=grid_y) || (curChoice==DRAWEDGECIRCLE && !(OrigX==grid_x && OrigY==grid_y)))) { struct BBRec final_bbox; AdjContinueOvalBBox(&bbox, &final_bbox); if (final_bbox.ltx > final_bbox.rbx) { /* swap final_bbox.ltx & final_bbox.rbx */ end_x = final_bbox.ltx; final_bbox.ltx = final_bbox.rbx; final_bbox.rbx = end_x; } if (final_bbox.lty > final_bbox.rby) { /* swap final_bbox.lty & final_bbox.rby */ end_y = final_bbox.lty; final_bbox.lty = final_bbox.rby; final_bbox.rby = end_y; } CreateOvalObj(&final_bbox, FALSE); RecordNewObjCmd(); DrawOvalObj(drawWindow, drawOrigX, drawOrigY, topObj); ovalDrawn = TRUE; SetFileModified(TRUE); } XSync(mainDisplay, False); } void DrawOval(input) XEvent *input; { XButtonEvent *button_ev; int mouse_x, mouse_y, grid_x, grid_y; if (input->type != ButtonPress) return; button_ev = &(input->xbutton); if (button_ev->button == Button1) { mouse_x = button_ev->x; mouse_y = button_ev->y; GridXY(mouse_x, mouse_y, &grid_x, &grid_y); ContinueOval(grid_x, grid_y); } } void MakeOvalObjFromBoundingBox() { struct BBRec obbox; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (curChoice == VERTEXMODE) SetCurChoice(NOTHING); HighLightReverse(); obbox.ltx = selObjLtX; obbox.lty = selObjLtY; obbox.rbx = selObjRbX; obbox.rby = selObjRbY; CreateOvalObj(&obbox, TRUE); SelectTopObj(); RecordNewObjCmd(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); justDupped = FALSE; SetFileModified(TRUE); } void SaveOvalObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { struct OvalRec *oval_ptr=ObjPtr->detail.o; if (fprintf(FP, "oval('%s','',", colorMenuItems[ObjPtr->color]) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,'%s',%1d,", ObjPtr->obbox.ltx, ObjPtr->obbox.lty, ObjPtr->obbox.rbx, ObjPtr->obbox.rby, oval_ptr->fill, oval_ptr->width, oval_ptr->pen, ObjPtr->id, oval_ptr->dash, ObjPtr->rotation, ObjPtr->locked, ObjPtr->ctm!=NULL, ObjPtr->invisible, oval_ptr->width_spec, ObjPtr->trans_pat) == EOF) { writeFileFailed = TRUE; } if (ObjPtr->ctm != NULL && fprintf(FP, "[\n %1d,%1d,%1d,%1d,%1d,%1d,%g,%g,%g,%g,%1d,%1d],", ObjPtr->x, ObjPtr->y, ObjPtr->orig_obbox.ltx, ObjPtr->orig_obbox.lty, ObjPtr->orig_obbox.rbx, ObjPtr->orig_obbox.rby, ObjPtr->ctm->m[CTM_SX], ObjPtr->ctm->m[CTM_SIN], ObjPtr->ctm->m[CTM_MSIN], ObjPtr->ctm->m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY]) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, " "); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } void ReadOvalObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { struct OvalRec *oval_ptr; char color_str[40], bg_color_str[40], *s, width_spec[40]; int ltx, lty, rbx, rby, trans_pat=FALSE, fill, width, pen, dash, w, id=0; int new_alloc, rotation, locked=FALSE, transformed=FALSE, invisible=FALSE; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_str, sizeof(color_str)); if (fileVersion >= 37) { s = ParseStr(s, (int)',', bg_color_str, sizeof(bg_color_str)); } InitScan(s, "\n\t, "); dash = 0; rotation = 0; *width_spec = '\0'; if (fileVersion <= 5) { if (GETINT("oval", ltx, "ltx") == INVALID || GETINT("oval", lty, "lty") == INVALID || GETINT("oval", rbx, "rbx") == INVALID || GETINT("oval", rby, "rby") == INVALID || GETINT("oval", fill, "fill") == INVALID || GETINT("oval", width, "width") == INVALID || GETINT("oval", pen, "pen") == INVALID) { return; } switch (width) { case 1: width = 3; break; case 2: width = 6; break; } id = objId++; } else if (fileVersion <= 7) { if (GETINT("oval", ltx, "ltx") == INVALID || GETINT("oval", lty, "lty") == INVALID || GETINT("oval", rbx, "rbx") == INVALID || GETINT("oval", rby, "rby") == INVALID || GETINT("oval", fill, "fill") == INVALID || GETINT("oval", width, "width") == INVALID || GETINT("oval", pen, "pen") == INVALID) { return; } id = objId++; } else if (fileVersion <= 8) { if (GETINT("oval", ltx, "ltx") == INVALID || GETINT("oval", lty, "lty") == INVALID || GETINT("oval", rbx, "rbx") == INVALID || GETINT("oval", rby, "rby") == INVALID || GETINT("oval", fill, "fill") == INVALID || GETINT("oval", width, "width") == INVALID || GETINT("oval", pen, "pen") == INVALID || GETINT("oval", id, "id") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 13) { if (GETINT("oval", ltx, "ltx") == INVALID || GETINT("oval", lty, "lty") == INVALID || GETINT("oval", rbx, "rbx") == INVALID || GETINT("oval", rby, "rby") == INVALID || GETINT("oval", fill, "fill") == INVALID || GETINT("oval", width, "width") == INVALID || GETINT("oval", pen, "pen") == INVALID || GETINT("oval", id, "id") == INVALID || GETINT("oval", dash, "dash") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 25) { if (GETINT("oval", ltx, "ltx") == INVALID || GETINT("oval", lty, "lty") == INVALID || GETINT("oval", rbx, "rbx") == INVALID || GETINT("oval", rby, "rby") == INVALID || GETINT("oval", fill, "fill") == INVALID || GETINT("oval", width, "width") == INVALID || GETINT("oval", pen, "pen") == INVALID || GETINT("oval", id, "id") == INVALID || GETINT("oval", dash, "dash") == INVALID || GETINT("oval", rotation, "rotation") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 32) { if (GETINT("oval", ltx, "ltx") == INVALID || GETINT("oval", lty, "lty") == INVALID || GETINT("oval", rbx, "rbx") == INVALID || GETINT("oval", rby, "rby") == INVALID || GETINT("oval", fill, "fill") == INVALID || GETINT("oval", width, "width") == INVALID || GETINT("oval", pen, "pen") == INVALID || GETINT("oval", id, "id") == INVALID || GETINT("oval", dash, "dash") == INVALID || GETINT("oval", rotation, "rotation") == INVALID || GETINT("oval", locked, "locked") == INVALID) { return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 34) { if (GETINT("oval", ltx, "ltx") == INVALID || GETINT("oval", lty, "lty") == INVALID || GETINT("oval", rbx, "rbx") == INVALID || GETINT("oval", rby, "rby") == INVALID || GETINT("oval", fill, "fill") == INVALID || GETINT("oval", width, "width") == INVALID || GETINT("oval", pen, "pen") == INVALID || GETINT("oval", id, "id") == INVALID || GETINT("oval", dash, "dash") == INVALID || GETINT("oval", rotation, "rotation") == INVALID || GETINT("oval", locked, "locked") == INVALID || GETINT("oval", transformed, "transformed") == INVALID || GETINT("oval", invisible, "invisible") == INVALID || GETSTR("oval", width_spec, "width_spec") == INVALID) { return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); } else { if (GETINT("oval", ltx, "ltx") == INVALID || GETINT("oval", lty, "lty") == INVALID || GETINT("oval", rbx, "rbx") == INVALID || GETINT("oval", rby, "rby") == INVALID || GETINT("oval", fill, "fill") == INVALID || GETINT("oval", width, "width") == INVALID || GETINT("oval", pen, "pen") == INVALID || GETINT("oval", id, "id") == INVALID || GETINT("oval", dash, "dash") == INVALID || GETINT("oval", rotation, "rotation") == INVALID || GETINT("oval", locked, "locked") == INVALID || GETINT("oval", transformed, "transformed") == INVALID || GETINT("oval", invisible, "invisible") == INVALID || GETSTR("oval", width_spec, "width_spec") == INVALID || GETINT("oval", trans_pat, "trans_pat") == INVALID) { return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); } if (ltx > rbx || lty > rby) { int tmp_ltx, tmp_lty, tmp_rbx, tmp_rby; if (!PRTGIF) Msg(TgLoadCachedString(CSTID_BAD_OVAL_BBOX_ADJ)); CalcBBox(ltx, lty, rbx, rby, &tmp_ltx, &tmp_lty, &tmp_rbx, &tmp_rby); ltx = tmp_ltx; lty = tmp_lty; rbx = tmp_rbx; rby = tmp_rby; } if (fileVersion <= 16 && width <= 6) width = origWidthOfLine[width]; if (fileVersion <= 32) { sprintf(width_spec, "%1d", width); } fill = UpgradePenFill(fill); pen = UpgradePenFill(pen); *ObjPtr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (*ObjPtr == NULL) FailAllocMessage(); memset(*ObjPtr, 0, sizeof(struct ObjRec)); oval_ptr = (struct OvalRec *)malloc(sizeof(struct OvalRec)); if (oval_ptr == NULL) FailAllocMessage(); memset(oval_ptr, 0, sizeof(struct OvalRec)); oval_ptr->fill = fill; oval_ptr->width = width; UtilStrCpyN(oval_ptr->width_spec, sizeof(oval_ptr->width_spec), width_spec); oval_ptr->pen = pen; oval_ptr->dash = dash; oval_ptr->rotated_n = 0; oval_ptr->rotated_vlist = NULL; (*ObjPtr)->x = ltx; (*ObjPtr)->y = lty; (*ObjPtr)->color = QuickFindColorIndex(*ObjPtr, color_str, &new_alloc, TRUE); UtilStrCpyN((*ObjPtr)->color_str, sizeof((*ObjPtr)->color_str), color_str); (*ObjPtr)->dirty = FALSE; (*ObjPtr)->id = id; (*ObjPtr)->rotation = rotation; (*ObjPtr)->locked = locked; (*ObjPtr)->type = OBJ_OVAL; (*ObjPtr)->obbox.ltx = ltx; (*ObjPtr)->obbox.lty = lty; (*ObjPtr)->obbox.rbx = rbx; (*ObjPtr)->obbox.rby = rby; w = HALF_W(width); (*ObjPtr)->bbox.ltx = ltx - w; (*ObjPtr)->bbox.lty = lty - w; (*ObjPtr)->bbox.rbx = rbx + w; (*ObjPtr)->bbox.rby = rby + w; (*ObjPtr)->detail.o = oval_ptr; (*ObjPtr)->ctm = NULL; (*ObjPtr)->invisible = invisible; (*ObjPtr)->trans_pat = trans_pat; if (fileVersion >= 33 && transformed) { int real_x=0, real_y=0; struct BBRec orig_obbox; char inbuf[MAXSTRING+1]; struct XfrmMtrxRec *ctm; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, "); ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ctm == NULL) FailAllocMessage(); if (GETINT("oval", real_x, "real_x") == INVALID || GETINT("oval", real_y, "real_y") == INVALID || GETINT("oval", orig_obbox.ltx, "orig_obbox.ltx") == INVALID || GETINT("oval", orig_obbox.lty, "orig_obbox.lty") == INVALID || GETINT("oval", orig_obbox.rbx, "orig_obbox.rbx") == INVALID || GETINT("oval", orig_obbox.rby, "orig_obbox.rby") == INVALID || GETDBL("oval", ctm->m[CTM_SX], "CTM_SX") == INVALID || GETDBL("oval", ctm->m[CTM_SIN], "CTM_SIN") == INVALID || GETDBL("oval", ctm->m[CTM_MSIN], "CTM_MSIN") == INVALID || GETDBL("oval", ctm->m[CTM_SY], "CTM_SY") == INVALID || GETINT("oval", ctm->t[CTM_TX], "CTM_TX") == INVALID || GETINT("oval", ctm->t[CTM_TY], "CTM_TY") == INVALID) { return; } (*ObjPtr)->ctm = ctm; if (ctm != NULL) { memcpy(&(*ObjPtr)->orig_obbox, &orig_obbox, sizeof(struct BBRec)); (*ObjPtr)->x = real_x; (*ObjPtr)->y = real_y; GetTransformedOBBoxOffsetVs(*ObjPtr, (*ObjPtr)->rotated_obbox); } } } void SetOvalPropMask(ObjPtr, plMask, plSkip, pProp) struct ObjRec *ObjPtr; long *plMask, *plSkip; struct PropertiesRec *pProp; { struct OvalRec *oval_ptr=ObjPtr->detail.o; SetCTMPropertyMask(ObjPtr->ctm, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_COLOR, ObjPtr->color, colorMenuItems[ObjPtr->color], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_WIDTH, oval_ptr->width, oval_ptr->width_spec, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TRANSPAT, ObjPtr->trans_pat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_FILL, oval_ptr->fill, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_PEN, oval_ptr->pen, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_DASH, oval_ptr->dash, NULL, plMask, plSkip, pProp); } void FreeOvalObj(ObjPtr) struct ObjRec *ObjPtr; { if (ObjPtr->detail.o->rotated_vlist != NULL) { free(ObjPtr->detail.o->rotated_vlist); } free(ObjPtr->detail.o); free(ObjPtr); } ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/xpixmap.e����������������������������������������������������������������������������0000644�0000764�0000764�00000013504�11602233314�014625� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/xpixmap.e,v 1.23 2011/05/16 16:22:00 william Exp $ */ #ifndef _XPIXMAP_E_ #define _XPIXMAP_E_ typedef struct tagXpmTransIndexInfo { int has_transparent_pixel; int found_transparent_pixel; int transparent_pixel_index; int *dump_index_to_color_index; } XpmTransIndexInfo; extern GC xpmGC; extern int newColormapUsed; extern int allocColorFailed; extern int myReadTransparentPixmap; extern int xpmIsArray; extern long xpmArraySeek; extern int xpmHasTooManyColorsForPrinting; extern int hasReadHexString; extern PngHeaderInfo gPngHeaderInfo; extern double rotatedSine[]; extern double rotatedCosine[]; #ifdef _INCLUDE_FROM_XPIXMAP_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_XPIXMAP_C_*/ extern void ResetXPmErrorMessage ARGS_DECL((void)); extern void InitXPm ARGS_DECL((void)); extern void CleanUpXPm ARGS_DECL((void)); extern int IsLinkedJpegObj ARGS_DECL((struct ObjRec *)); extern int IsPpmTrueObj ARGS_DECL((int real_type, int ppm_data_compress, char *ppm_data)); extern int ObjHasIndexedTransPixel ARGS_DECL((struct ObjRec *, int *pn_index)); extern int ObjHasTrueColorTransPixel ARGS_DECL((struct ObjRec *, unsigned char *puch_trans_color_r, unsigned char *puch_trans_color_g, unsigned char *puch_trans_color_b)); extern int ObjHasTransPixel ARGS_DECL((struct ObjRec *)); extern int BuildXPmBuckets ARGS_DECL((int NColors, int *Pixels, int *DumpIndexToColorIndex, int CharsPerPixel, char *ColorChr, XpmTransIndexInfo*)); extern int XPmLookUp ARGS_DECL((int Pixel, int CharsPerPixel, char *ColorChr, int *pnColorIndexReturn)); extern void MakeCachedPixmap ARGS_DECL((struct ObjRec *)); extern int ExtractPixmap ARGS_DECL((Pixmap, XImage*, Pixmap, XImage*, int, int, int, int, Pixmap*, XImage**, Pixmap*, XImage**)); extern struct ObjRec * CutXPixmap ARGS_DECL((struct ObjRec *ObjPtrToCut, int *AbsX, int *AbsY, int *AbsW, int *AbsH)); extern void CleanUpCachedColorsForPrinting ARGS_DECL((void)); extern void CacheColorsForPrinting ARGS_DECL((void)); extern int ConvertPpmTrueToPpm6 ARGS_DECL((char *ppm_data, int ppm_datasize, int ppm_data_compress, char *tmp_ppm6_fname, int tmp_ppm6_sz)); extern void DumpXPmObj ARGS_DECL((FILE *, struct ObjRec *)); extern int NeedsToCacheXPmObj ARGS_DECL((struct ObjRec *)); extern void RecolorXPmObj ARGS_DECL((struct ObjRec *, int color_index)); extern void DrawXPmObj ARGS_DECL((Window, int XOff, int YOff, struct ObjRec *)); extern struct ObjRec * CreateXPmObj ARGS_DECL((int ImageW, int ImageH, int W, int H, Pixmap pixmap, XImage *image, Pixmap bitmap, XImage *bitmap_image, int NColors, int CharsPerPixel, int FirstPixelIsBg, char *ColorChar, char **ColorStr, int *Pixels, char *Data)); extern void BreakUpXPixmap ARGS_DECL((struct ObjRec *, int ColsAndRows, int W, int H)); extern void SaveXPmObj ARGS_DECL((FILE *, struct ObjRec *)); extern int PrTgifFindColorIndex ARGS_DECL((struct ObjRec *, char *Str)); extern int QuickFindColorIndex ARGS_DECL((struct ObjRec *, char *Str, int *NewAlloc, int UseDefault)); extern int MyReadPixmapFile ARGS_DECL((char *FileName, int *ImageW, int *ImageH, int *W, int *H, Pixmap *pixmap, XImage **image, Pixmap *bitmap, XImage **bitmap_image, int *NColors, int *CharsPerPixel, int *FirstPixelIsBg, char **ColorChar, char ***ColorStr, int **Pixels, char **Data)); extern void ReadXPmObj ARGS_DECL((FILE *, char *Inbuf, struct ObjRec **)); extern void ReadJpegObj ARGS_DECL((FILE *, char *Inbuf, struct ObjRec **)); extern int SetupTrueColorInfo ARGS_DECL((TrueColorInfo*)); extern struct ObjRec * CreatePpmTrueObjFromFile ARGS_DECL((char *ppm_fname)); extern void ReadPpmTrueObj ARGS_DECL((FILE *, char *Inbuf, struct ObjRec **)); extern void SetXPmPropMask ARGS_DECL((struct ObjRec *, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void FreeXPmObj ARGS_DECL((struct ObjRec *)); #ifdef _INCLUDE_FROM_XPIXMAP_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_XPIXMAP_C_*/ #endif /*_XPIXMAP_E_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/scroll.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000150011�11602233312�014424� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/scroll.c,v 1.8 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_SCROLL_C_ #include "tgifdefs.h" #include "choice.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "exec.e" #include "grid.e" #include "mainloop.e" #include "menu.e" #include "miniline.e" #include "msg.e" #include "obj.e" #include "page.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "scroll.e" #include "setup.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "xbm/scrl_up.xbm" #define FAKE_CM 80 int autoPan=TRUE; int scrollingCanvas=INVALID; int smoothScrollingCanvas=JUMP_SCROLLING; int resetOriginOnAdvancePage=FALSE; static int scrollAreaH=0, scrollAreaW=0; int TgAnyButtonDown(dpy, win) Display *dpy; Window win; { Window root_win=None, child_win=None; unsigned int status; int parent_root_x, parent_root_y, x=0, y=0; XQueryPointer(dpy, win, &root_win, &child_win, &parent_root_x, &parent_root_y, &x, &y, &status); return ((status & BUTTONSMASK) != 0); } int TgPressButtonLoop(dpy, win, pbbox, psbci) Display *dpy; Window win; struct BBRec *pbbox; ScrollBtnCallbackInfo *psbci; /* returns TRUE if need to scroll one more time */ { time_t tv_usec=(time_t)0; int done=FALSE, need_to_scroll_once=TRUE, initial_timeout=TRUE; if (pbbox != NULL) { TgDrawThreeDButton(dpy, win, textMenuGC, pbbox, TGBS_LOWRED, 2, FALSE); } if (!TgAnyButtonDown(dpy, win)) { if (pbbox != NULL) { TgDrawThreeDButton(dpy, win, textMenuGC, pbbox, TGBS_RAISED, 2, FALSE); } return need_to_scroll_once; } tv_usec = (psbci->ms*1000); XGrabPointer(dpy, win, False, ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); do { struct timeval timeout; fd_set fdset; int select_width=XConnectionNumber(dpy)+1, status=0; timeout.tv_sec = 0; timeout.tv_usec = (initial_timeout ? 600000 : tv_usec); FD_ZERO(&fdset); FD_SET(select_width-1, &fdset); #ifdef __hpux status = select(select_width, (int*)&fdset, NULL, NULL, &timeout); #else /* !__hpux */ status = select(select_width, &fdset, NULL, NULL, &timeout); #endif /* __hpux */ initial_timeout = FALSE; if (status < 0) { if (errno == EINTR) { /* interrupted by a system call, do it again */ if (TgAnyButtonDown(dpy, win)) { need_to_scroll_once = FALSE; if ((psbci->pf_scroll_btn_callback)(psbci->pv_userdata)) { XUngrabPointer(dpy, CurrentTime); return TRUE; } } } else { XUngrabPointer(dpy, CurrentTime); sprintf(gszMsgBox, TgLoadString(STID_FUNC_SELECT_SYS_CALL_FAILED), "TgPressButtonLoop()"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; } } else if (status == 0 && TgAnyButtonDown(dpy, win)) { need_to_scroll_once = FALSE; if ((psbci->pf_scroll_btn_callback)(psbci->pv_userdata)) { XUngrabPointer(dpy, CurrentTime); return TRUE; } } else { XUngrabPointer(dpy, CurrentTime); XFlush(dpy); XSync(dpy, False); if (pbbox != NULL) { TgDrawThreeDButton(dpy, win, textMenuGC, pbbox, TGBS_RAISED, 2, FALSE); } done = TRUE; return need_to_scroll_once; } } while (!done); return need_to_scroll_once; } int TgGetScrollHit(x, y, orientation, scroll_area_w, scroll_area_h, start_frac, length, total, pn_btn_offset) int x, y, scroll_area_w, scroll_area_h, length, total, *pn_btn_offset; double start_frac; { int block_start=0, block_size=0, min_block_size=1+(windowPadding<<1); int block_area=((orientation==VERT_SCROLLBAR)?scroll_area_h:scroll_area_w); double frac=(double)0; if (pn_btn_offset != NULL) *pn_btn_offset = 0; if (orientation == VERT_SCROLLBAR) { y -= scrollBarW; } else { x -= scrollBarW; } block_area -= (scrollBarW<<1); if (total == 0) { frac = (double)1.0; } else { frac = (double)((double)length / (double)total); } if (frac > 1.0) frac = 1.0; block_start = ((int)(block_area * start_frac)); if (start_frac + frac >= 1.0) { block_size = block_area - block_start; } else { block_size = (int)(block_area * frac); } if (block_size < min_block_size) block_size = min_block_size; if (orientation == VERT_SCROLLBAR) { if (block_start > scroll_area_h-min_block_size) { block_start = scroll_area_h-min_block_size; } } else { if (block_start > scroll_area_w-min_block_size) { block_start = scroll_area_w-min_block_size; } } if (orientation == VERT_SCROLLBAR) { if (y < block_start) { return (-1); } else if (y < block_start+block_size) { if (pn_btn_offset != NULL) *pn_btn_offset = block_start-y; return 0; } } else { if (x < block_start) { return (-1); } else if (x < block_start+block_size) { if (pn_btn_offset != NULL) *pn_btn_offset = block_start-x; return 0; } } return 1; } void TgDrawScrollBar(dpy, win, orientation, x_off, y_off, scroll_area_w, scroll_area_h, start_frac, length, total) Display *dpy; Window win; int x_off, y_off, scroll_area_w, scroll_area_h, length, total; double start_frac; { int block_start=0, block_size=0, min_block_size=1+(windowPadding<<1); int block_area=((orientation==VERT_SCROLLBAR)?scroll_area_h:scroll_area_w); double frac=(double)0; XGCValues values; if (threeDLook) { struct BBRec bbox; if (orientation == VERT_SCROLLBAR) { values.foreground = myFgPixel; values.background = myLtGryPixel; values.fill_style = FillOpaqueStippled; values.stipple = scrlBitmap[SCRL_UP]; values.ts_x_origin = x_off+(windowPadding<<1); values.ts_y_origin = y_off+1+(windowPadding<<1); XChangeGC(mainDisplay, textMenuGC, GCForeground | GCBackground | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(dpy, win, textMenuGC, values.ts_x_origin, values.ts_y_origin, scrl_up_width, scrl_up_height); values.stipple = scrlBitmap[SCRL_DN]; values.ts_y_origin = y_off+scroll_area_h-scrollBarW+1+(windowPadding<<1); XChangeGC(mainDisplay, textMenuGC, GCStipple | GCTileStipYOrigin, &values); XFillRectangle(dpy, win, textMenuGC, values.ts_x_origin, values.ts_y_origin, scrl_up_width, scrl_up_height); values.fill_style = FillSolid; values.ts_x_origin = 0; values.ts_y_origin = 0; XChangeGC(mainDisplay, textMenuGC, GCFillStyle | GCTileStipXOrigin | GCTileStipYOrigin, &values); SetBBRec(&bbox, x_off, y_off, x_off+scrollBarW, y_off+scrollBarW); TgDrawThreeDButton(dpy, win, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); SetBBRec(&bbox, x_off, y_off+scroll_area_h-scrollBarW, x_off+scrollBarW, y_off+scroll_area_h); TgDrawThreeDButton(dpy, win, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); } else { values.foreground = myFgPixel; values.background = myLtGryPixel; values.fill_style = FillOpaqueStippled; values.stipple = scrlBitmap[SCRL_LF]; values.ts_x_origin = x_off+(windowPadding<<1); values.ts_y_origin = y_off+(windowPadding<<1); XChangeGC(mainDisplay, textMenuGC, GCForeground | GCBackground | GCFillStyle | GCStipple | GCTileStipXOrigin | GCTileStipYOrigin, &values); XFillRectangle(dpy, win, textMenuGC, values.ts_x_origin, values.ts_y_origin, scrl_up_width, scrl_up_height); values.stipple = scrlBitmap[SCRL_RT]; values.ts_x_origin = x_off+scroll_area_w-scrollBarW+(windowPadding<<1); XChangeGC(mainDisplay, textMenuGC, GCStipple | GCTileStipXOrigin, &values); XFillRectangle(dpy, win, textMenuGC, values.ts_x_origin, values.ts_y_origin, scrl_up_width, scrl_up_height); values.fill_style = FillSolid; values.ts_x_origin = 0; values.ts_y_origin = 0; XChangeGC(mainDisplay, textMenuGC, GCFillStyle | GCTileStipXOrigin | GCTileStipYOrigin, &values); SetBBRec(&bbox, x_off, y_off, x_off+scrollBarW, y_off+scrollBarW); TgDrawThreeDButton(dpy, win, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); SetBBRec(&bbox, x_off+scroll_area_w-scrollBarW, y_off, x_off+scroll_area_w, y_off+scrollBarW); TgDrawThreeDButton(dpy, win, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); } block_area -= (scrollBarW<<1); if (total == 0) { frac = (double)1.0; } else { frac = (double)((double)length / (double)total); } if (frac > 1.0) frac = 1.0; block_start = scrollBarW + ((int)(block_area * start_frac)); if (start_frac + frac >= 1.0) { block_size = block_area - block_start + scrollBarW; } else { block_size = (int)(block_area * frac); } if (block_size < min_block_size) block_size = min_block_size; if (orientation == VERT_SCROLLBAR) { if (block_start > scroll_area_h-scrollBarW-min_block_size) { block_start = scroll_area_h-scrollBarW-min_block_size; } } else { if (block_start > scroll_area_w-scrollBarW-min_block_size) { block_start = scroll_area_w-scrollBarW-min_block_size; } } values.foreground = myLtGryPixel; values.background = myBgPixel; values.fill_style = FillOpaqueStippled; values.stipple = patPixmap[SCROLLPAT]; XChangeGC(dpy, patGC, GCForeground | GCBackground | GCFillStyle | GCStipple, &values); if (orientation == VERT_SCROLLBAR) { XFillRectangle(dpy, win, patGC, x_off, y_off+scrollBarW, scroll_area_w, scroll_area_h-(scrollBarW<<1)); } else { XFillRectangle(dpy, win, patGC, x_off+scrollBarW, y_off, scroll_area_w-(scrollBarW<<1), scroll_area_h); } values.foreground = myLtGryPixel; values.background = myLtGryPixel; values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(dpy, patGC, GCForeground | GCBackground | GCFunction | GCFillStyle, &values); if (orientation == VERT_SCROLLBAR) { XFillRectangle(dpy, win, patGC, x_off, y_off+block_start, scroll_area_w, block_size); SetBBRec(&bbox, x_off, y_off+block_start, x_off+scroll_area_w, y_off+block_start+block_size); } else { XFillRectangle(dpy, win, patGC, x_off+block_start, y_off, block_size, scroll_area_h); SetBBRec(&bbox, x_off+block_start, y_off, x_off+block_start+block_size, y_off+scroll_area_h); } TgDrawThreeDButton(dpy, win, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); } else { if (total == 0) { frac = (double)1.0; } else { frac = (double)((double)length / (double)total); } if (frac > 1.0) frac = 1.0; block_start = (int)(block_area * start_frac); if (start_frac + frac >= 1.0) { block_size = block_area - block_start; } else { block_size = (int)(block_area * frac); } if (block_size <= 0) block_size = 1; values.foreground = myBgPixel; values.background = myFgPixel; values.function = GXcopy; values.fill_style = FillSolid; XChangeGC(dpy, patGC, GCForeground | GCBackground | GCFunction | GCFillStyle, &values); XFillRectangle(dpy, win, patGC, x_off, y_off, scroll_area_w, scroll_area_h); values.foreground = myFgPixel; values.background = myBgPixel; values.fill_style = FillOpaqueStippled; values.stipple = patPixmap[SCROLLPAT]; XChangeGC(dpy, patGC, GCForeground | GCBackground | GCFillStyle | GCStipple, &values); if (orientation == VERT_SCROLLBAR) { XFillRectangle(dpy, win, patGC, x_off, y_off+block_start, scroll_area_w, block_size); } else { XFillRectangle(dpy, win, patGC, x_off+block_start, y_off, block_size, scroll_area_h); } } } void RedrawVScrollWindow() { double start_frac=(double)0; int total=max(paperHeight,(drawOrigY+drawWinH)); XEvent ev; XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, vSBarWindow, ExposureMask, &ev)) ; if (total == 0) { start_frac = (double)1.0; } else { start_frac = (double)((double)drawOrigY / (double)total); } if (start_frac > 1.0) start_frac = 1.0; TgDrawScrollBar(mainDisplay, vSBarWindow, VERT_SCROLLBAR, 0, 0, scrollBarW, scrollAreaH, start_frac, drawWinH, total); } void RedrawHScrollWindow() { double start_frac=(double)0; int total=max(paperWidth,(drawOrigX+drawWinW)); XEvent ev; XSync(mainDisplay, False); while (XCheckWindowEvent(mainDisplay, hSBarWindow, ExposureMask, &ev)) ; if (total == 0) { start_frac = (double)1.0; } else { start_frac = (double)((double)drawOrigX / (double)total); } if (start_frac > 1.0) start_frac = 1.0; TgDrawScrollBar(mainDisplay, hSBarWindow, HORI_SCROLLBAR, 0, 0, scrollAreaW, scrollBarW, start_frac, drawWinW, total); } void RedrawScrollBars() { if (vSBarWindow != None) RedrawVScrollWindow(); if (hSBarWindow != None) RedrawHScrollWindow(); } void GetMaxScrollOrigin(pn_orig_x, pn_orig_y) int *pn_orig_x, *pn_orig_y; { if (pn_orig_y != NULL) { if (paperHeight <= drawWinH) { *pn_orig_y = 0; } else { switch (gridSystem) { case ENGLISH_GRID: if ((paperHeight-drawWinH) % ABS_SIZE(HALF_INCH) == 0) { *pn_orig_y = paperHeight-drawWinH; } else { *pn_orig_y = max(0, ((int)((paperHeight-drawWinH)/ ABS_SIZE(HALF_INCH)) + 1) * ABS_SIZE(HALF_INCH)); } break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { if ((paperHeight-drawWinH) % ABS_SIZE(FAKE_CM) == 0) { *pn_orig_y = paperHeight-drawWinH; } else { *pn_orig_y = max(0, ((int)((paperHeight-drawWinH)/ ABS_SIZE(FAKE_CM)) + 1) * ABS_SIZE(FAKE_CM)); } } else { if ((paperHeight-drawWinH) % ABS_SIZE(ONE_CM) == 0) { *pn_orig_y = paperHeight-drawWinH; } else { *pn_orig_y = max(0, ((int)((paperHeight-drawWinH)/ ABS_SIZE(ONE_CM)) + 1) * ABS_SIZE(ONE_CM)); } } break; } } *pn_orig_y = ABS_SIZE(ZOOMED_SIZE(*pn_orig_y)); } if (pn_orig_x != NULL) { if (paperWidth <= drawWinW) { *pn_orig_x = 0; } else { switch (gridSystem) { case ENGLISH_GRID: if ((paperWidth-drawWinW) % ABS_SIZE(HALF_INCH) == 0) { *pn_orig_x = paperWidth-drawWinW; } else { *pn_orig_x = max(0, ((int)((paperWidth-drawWinW)/ ABS_SIZE(HALF_INCH)) + 1) * ABS_SIZE(HALF_INCH)); } break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { if ((paperWidth-drawWinW) % ABS_SIZE(FAKE_CM) == 0) { *pn_orig_x = paperWidth-drawWinW; } else { *pn_orig_x = max(0, ((int)((paperWidth-drawWinW)/ ABS_SIZE(FAKE_CM)) + 1) * ABS_SIZE(FAKE_CM)); } } else { if ((paperWidth-drawWinW) % ABS_SIZE(ONE_CM) == 0) { *pn_orig_x = paperWidth-drawWinW; } else { *pn_orig_x = max(0, ((int)((paperWidth-drawWinW)/ ABS_SIZE(ONE_CM)) + 1) * ABS_SIZE(ONE_CM)); } } break; } } *pn_orig_x = ABS_SIZE(ZOOMED_SIZE(*pn_orig_x)); } } void ScrollTo(XOff, YOff) int XOff, YOff; { int h_adjust=0, v_adjust=0; static int first_auto_pan_msg=TRUE; if (!autoPan || (XOff >= 0 && ABS_SIZE(XOff) < drawWinW && YOff >= 0 && ABS_SIZE(YOff) < drawWinH)) { return; } if (XOff < 0) { if (ABS_SIZE(-XOff) > drawOrigX) { h_adjust = (-ZOOMED_SIZE(drawOrigX)); } else { switch (gridSystem) { case ENGLISH_GRID: h_adjust = ((-XOff) % HALF_INCH == 0) ? (XOff) : (((int)((-XOff)/HALF_INCH))+1) * (-HALF_INCH); break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { h_adjust = ((-XOff) % FAKE_CM == 0) ? (XOff) : (((int)((-XOff)/FAKE_CM))+1) * (-FAKE_CM); } else { h_adjust = ((-XOff) % ONE_CM == 0) ? (XOff) : (((int)((-XOff)/ONE_CM))+1) * (-ONE_CM); } break; } } } else if (ABS_SIZE(XOff) >= drawWinW) { switch (gridSystem) { case ENGLISH_GRID: h_adjust = (((int)((XOff-ZOOMED_SIZE(drawWinW))/HALF_INCH))+1) * HALF_INCH; break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { h_adjust = (((int)((XOff-ZOOMED_SIZE(drawWinW))/FAKE_CM))+1) * FAKE_CM; } else { h_adjust = (((int)((XOff-ZOOMED_SIZE(drawWinW))/ONE_CM))+1) * ONE_CM; } break; } } if (YOff < 0) { if (ABS_SIZE(-YOff) > drawOrigY) { v_adjust = (-ZOOMED_SIZE(drawOrigY)); } else { switch (gridSystem) { case ENGLISH_GRID: v_adjust = ((-YOff) % HALF_INCH == 0) ? (YOff) : (((int)((-YOff)/HALF_INCH))+1) * (-HALF_INCH); break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { v_adjust = ((-YOff) % FAKE_CM == 0) ? (YOff) : (((int)((-YOff)/FAKE_CM))+1) * (-FAKE_CM); } else { v_adjust = ((-YOff) % ONE_CM == 0) ? (YOff) : (((int)((-YOff)/ONE_CM))+1) * (-ONE_CM); } break; } } } else if (ABS_SIZE(YOff+(textCursorH>>1)) >= drawWinH) { switch (gridSystem) { case ENGLISH_GRID: v_adjust = (((int)((YOff+(textCursorH>>1) - ZOOMED_SIZE(drawWinH))/HALF_INCH))+1) * HALF_INCH; break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { v_adjust = (((int)((YOff+(textCursorH>>1) - ZOOMED_SIZE(drawWinH))/FAKE_CM))+1) * FAKE_CM; } else { v_adjust = (((int)((YOff+(textCursorH>>1) - ZOOMED_SIZE(drawWinH))/ONE_CM))+1) * ONE_CM; } break; } } if (h_adjust == 0 && v_adjust == 0) return; if (first_auto_pan_msg) { first_auto_pan_msg = FALSE; sprintf(gszMsgBox, TgLoadString(STID_TURN_OFF_AUTO_PAN_SET_XDEF), TOOL_NAME, "AutoPanInEditText"); Msg(gszMsgBox); } drawOrigX += ABS_SIZE(h_adjust); drawOrigY += ABS_SIZE(v_adjust); RedrawScrollBars(); UpdDrawWinBBox(); AdjSplineVs(); AdjustCurText((-h_adjust), (-v_adjust)); RedrawRulers(); ClearAndRedrawDrawWindow(); } void ScrollUp(button_ev) XButtonEvent *button_ev; { int adjustment=0; if (drawOrigY != 0) { switch (gridSystem) { case ENGLISH_GRID: if (button_ev!=NULL && (button_ev->state & (ShiftMask|ControlMask))) { adjustment = ((int)(ZOOMED_SIZE(drawWinH)/HALF_INCH))*HALF_INCH; if (drawOrigY-ABS_SIZE(adjustment) < 0) { adjustment = ZOOMED_SIZE(drawOrigY); } } else { adjustment = HALF_INCH; } break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { if (button_ev!=NULL && (button_ev->state & (ShiftMask|ControlMask))) { adjustment = ((int)(ZOOMED_SIZE(drawWinH)/FAKE_CM))*FAKE_CM; if (drawOrigY-ABS_SIZE(adjustment) < 0) adjustment = ZOOMED_SIZE(drawOrigY); } else { adjustment = FAKE_CM; } } else { if (button_ev!=NULL && (button_ev->state & (ShiftMask|ControlMask))) { adjustment = ((int)(ZOOMED_SIZE(drawWinH)/ONE_CM))*ONE_CM; if (drawOrigY-ABS_SIZE(adjustment) < 0) adjustment = ZOOMED_SIZE(drawOrigY); } else { adjustment = ONE_CM; } } break; } if (drawOrigY >= ABS_SIZE(adjustment)) { drawOrigY -= ABS_SIZE(adjustment); } else { adjustment = ZOOMED_SIZE(drawOrigY); drawOrigY -= ABS_SIZE(adjustment); if (drawOrigY < 0) drawOrigY = 0; } RedrawVScrollWindow(); UpdDrawWinBBox(); AdjSplineVs(); AdjustCurText(0, adjustment); RedrawRulers(); ClearAndRedrawDrawWindow(); } } void ForceScrollDown(ScrollAFullWindow) int ScrollAFullWindow; { int adjustment=0; switch (gridSystem) { case ENGLISH_GRID: if (ScrollAFullWindow) { adjustment = ((int)(ZOOMED_SIZE(drawWinH)/HALF_INCH))*HALF_INCH; } else { adjustment = HALF_INCH; } break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { if (ScrollAFullWindow) { adjustment = ((int)(ZOOMED_SIZE(drawWinH)/FAKE_CM))*FAKE_CM; } else { adjustment = FAKE_CM; } } else { if (ScrollAFullWindow) { adjustment = ((int)(ZOOMED_SIZE(drawWinH)/ONE_CM))*ONE_CM; } else { adjustment = ONE_CM; } } break; } drawOrigY += ABS_SIZE(adjustment); RedrawVScrollWindow(); UpdDrawWinBBox(); AdjSplineVs(); AdjustCurText(0, -adjustment); RedrawRulers(); ClearAndRedrawDrawWindow(); } void ScrollDown(button_ev) XButtonEvent *button_ev; { if (paperHeight <= drawWinH) return; if (drawOrigY+drawWinH < paperHeight) { ForceScrollDown(button_ev != NULL && (button_ev->state & (ShiftMask|ControlMask))); } } typedef struct tagSBarInfo { int scroll_page, scroll_dir; } SBarInfo; static int ScrollBtnCallback(pv_userdata) void *pv_userdata; /* returns TRUE to cancel scrolling */ { SBarInfo *psbi=((SBarInfo*)(pv_userdata)); XButtonEvent btn_ev; btn_ev.state = (psbi->scroll_page ? ShiftMask : 0); switch (psbi->scroll_dir) { case SCRL_UP: ScrollUp(&btn_ev); break; case SCRL_DN: ScrollDown(&btn_ev); break; case SCRL_LF: ScrollLeft(&btn_ev); break; case SCRL_RT: ScrollRight(&btn_ev); break; } return FALSE; } static int DoSBarBtnScroll(dpy, win, scroll_page, scroll_dir, pbbox) Display *dpy; Window win; int scroll_page, scroll_dir; struct BBRec *pbbox; /* returns TRUE if the done scrolling */ { ScrollBtnCallbackInfo sbci; SBarInfo sbi; memset(&sbi, 0, sizeof(SBarInfo)); sbi.scroll_page = scroll_page; sbi.scroll_dir = scroll_dir; memset(&sbci, 0, sizeof(ScrollBtnCallbackInfo)); sbci.ms = (scroll_page ? 300 : 200); sbci.pv_userdata = ((void*)(&sbi)); sbci.pf_scroll_btn_callback = ScrollBtnCallback; if (TgPressButtonLoop(dpy, win, pbbox, &sbci)) { XButtonEvent btn_ev; btn_ev.state = (scroll_page ? ShiftMask : 0); switch (scroll_dir) { case SCRL_UP: ScrollUp(&btn_ev); break; case SCRL_DN: ScrollDown(&btn_ev); break; case SCRL_LF: ScrollLeft(&btn_ev); break; case SCRL_RT: ScrollRight(&btn_ev); break; } } return FALSE; } static void DragToInVSBar(lty, block_start, block_h) int lty, block_start, block_h; { double start_frac=(double)0.0; int saved_y=drawOrigY, adjustment=0, scroll_all_the_way=FALSE; if (threeDLook) { start_frac = (double)(((double)(lty-scrollBarW)) / ((double)(scrollAreaH-(scrollBarW<<1)))); if (lty+block_h >= scrollAreaH-scrollBarW) { scroll_all_the_way = TRUE; } } else { start_frac = (double)(((double)block_start)/((double)scrollAreaH)); if (block_start+block_h >= scrollAreaH) { scroll_all_the_way = TRUE; } } if (start_frac < 0.0) start_frac = 0.0; if (start_frac > 1.0) start_frac = 1.0; if (scroll_all_the_way) { GetMaxScrollOrigin(NULL, &drawOrigY); } else { double dv=(double)0; switch (gridSystem) { case ENGLISH_GRID: dv = ((double)paperHeight) * start_frac; break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { dv = ((double)paperHeight) * start_frac; } else { dv = ((double)paperHeight) * start_frac; } break; } drawOrigY = round(dv); drawOrigY = ABS_SIZE(ZOOMED_SIZE(drawOrigY)); } adjustment = saved_y - drawOrigY; if (adjustment != 0) { RedrawVScrollWindow(); UpdDrawWinBBox(); AdjSplineVs(); AdjustCurText(0, ZOOMED_SIZE(adjustment)); RedrawRulers(); ClearAndRedrawDrawWindow(); } else { RedrawVScrollWindow(); } } static void DoDragInVSBar(btn_y, btn_offset) int btn_y, btn_offset; { double frac=(double)0.0, start_frac=(double)0.0; int block_h=0, block_start=0, continuous_drag=FALSE; int done=FALSE, lty=0, min_block_size=1+(windowPadding<<1); int total=max(paperHeight,(drawOrigY+drawWinH)); XEvent ev; scrollingCanvas = SCRL_UP; if (smoothScrollingCanvas == SMOOTH_SCROLLING) { BeginExecAnimate(); if (!TgAnyButtonDown(mainDisplay, vSBarWindow)) { EndExecAnimate(); ClearAndRedrawDrawWindow(); return; } continuous_drag = execAnimating; } block_start = btn_y+btn_offset; frac = (double)((double)drawWinH / (double)(paperHeight)); if (threeDLook) { start_frac = (double)(((double)(block_start-scrollBarW)) / ((double)(scrollAreaH-(scrollBarW<<1)))); block_h = (frac >= 1.0) ? (scrollAreaH-(scrollBarW<<1)) : (int)(((double)(scrollAreaH-(scrollBarW<<1))) * frac); if (block_h < min_block_size) block_h = min_block_size; lty = (start_frac + frac >= 1.0) ? scrollAreaH-scrollBarW-block_h : block_start; start_frac = (double)(((double)(lty-scrollBarW)) / ((double)(scrollAreaH-(scrollBarW<<1)))); } else { start_frac = (double)(((double)block_start)/((double)scrollAreaH)); block_h = (frac >= 1.0) ? scrollAreaH : (int)(((double)scrollAreaH) * frac); if (block_h < 1) block_h = 1; lty = (start_frac + frac >= 1.0) ? scrollAreaH-block_h : block_start; start_frac = (double)(((double)lty)/((double)scrollAreaH)); } TgDrawScrollBar(mainDisplay, vSBarWindow, VERT_SCROLLBAR, 0, 0, scrollBarW, scrollAreaH, start_frac, drawWinH, total); XGrabPointer(mainDisplay, vSBarWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); while (!done) { XNextEvent(mainDisplay, &ev); if (ev.type == Expose || ev.type == VisibilityNotify) { ExposeEventHandler(&ev, TRUE); } else if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); done = TRUE; } else if (ev.type == MotionNotify) { int new_y=0; block_start = ev.xmotion.y; if (threeDLook) { new_y = ev.xmotion.y+btn_offset; if (new_y < scrollBarW) { new_y = scrollBarW; } else if (new_y+block_h >= scrollAreaH-scrollBarW) { new_y = scrollAreaH-block_h-scrollBarW; } if (new_y != lty) { lty = new_y; start_frac = (double)(((double)(lty-scrollBarW)) / ((double)(scrollAreaH-(scrollBarW<<1)))); TgDrawScrollBar(mainDisplay, vSBarWindow, VERT_SCROLLBAR, 0, 0, scrollBarW, scrollAreaH, start_frac, drawWinH, total); } } else { if (block_start <= 0) { new_y = 0; } else if (block_start+block_h >= scrollAreaH) { new_y = scrollAreaH-block_h; } else { new_y = block_start; } if (new_y != lty) { lty = new_y; start_frac = (double)(((double)lty)/((double)scrollAreaH)); TgDrawScrollBar(mainDisplay, vSBarWindow, VERT_SCROLLBAR, 0, 0, scrollBarW, scrollAreaH, start_frac, drawWinH, total); } } if (continuous_drag) { int scroll_all_the_way=FALSE; if (threeDLook) { start_frac = (double)(((double)(lty-scrollBarW)) / ((double)(scrollAreaH-(scrollBarW<<1)))); if (lty+block_h >= scrollAreaH-scrollBarW) { scroll_all_the_way = TRUE; } } else { start_frac = (double)(((double)lty)/((double)scrollAreaH)); if (block_start+block_h >= scrollAreaH) { scroll_all_the_way = TRUE; } } RedrawAreaFromCache(start_frac, scroll_all_the_way); } else if (smoothScrollingCanvas == JUMP_SCROLLING) { DragToInVSBar(lty, block_start, block_h); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } if (smoothScrollingCanvas == SMOOTH_SCROLLING) { EndExecAnimate(); RedrawCurText(); } scrollingCanvas = INVALID; DragToInVSBar(lty, block_start, block_h); } static void VSBarHandler(button_ev) XButtonEvent *button_ev; { int do_drag=FALSE, btn_offset=0; int total=max(paperHeight,(drawOrigY+drawWinH)); if (!threeDLook && button_ev->button == Button3 && button_ev->type == ButtonPress) { DoSBarBtnScroll(mainDisplay, vSBarWindow, ((button_ev->state & (ShiftMask|ControlMask)) != 0), SCRL_UP, NULL); } else if (!threeDLook && button_ev->button == Button1 && button_ev->type == ButtonPress) { DoSBarBtnScroll(mainDisplay, vSBarWindow, ((button_ev->state & (ShiftMask|ControlMask)) != 0), SCRL_DN, NULL); } else if (button_ev->button == Button1 && button_ev->type == ButtonPress) { if (button_ev->y < scrollBarW || button_ev->y >= scrollAreaH-scrollBarW) { int which=0; struct BBRec bbox; if (button_ev->y < scrollBarW) { which = SCRL_UP; SetBBRec(&bbox, 0, 0, scrollBarW, scrollBarW); } else { which = SCRL_DN; SetBBRec(&bbox, 0, scrollAreaH-scrollBarW, scrollBarW, scrollAreaH); } DoSBarBtnScroll(mainDisplay, vSBarWindow, FALSE, which, &bbox); } else { double start_frac=(double)0.0; int hit=0; if (total == 0) { start_frac = (double)1.0; } else { start_frac = (double)((double)drawOrigY / (double)total); } if (start_frac > 1.0) start_frac = 1.0; hit = TgGetScrollHit(button_ev->x, button_ev->y, VERT_SCROLLBAR, scrollBarW, scrollAreaH, start_frac, drawWinH, total, &btn_offset); if (hit == 0) { do_drag = TRUE; } else { DoSBarBtnScroll(mainDisplay, vSBarWindow, TRUE, (hit < 0 ? SCRL_UP : SCRL_DN), NULL); } } } else if (!threeDLook && button_ev->button == Button2 && button_ev->type == ButtonPress) { do_drag = TRUE; } if (do_drag) { DoDragInVSBar(button_ev->y, btn_offset); } } void ScrollLeft(button_ev) XButtonEvent *button_ev; { int adjustment=0; if (drawOrigX != 0) { switch (gridSystem) { case ENGLISH_GRID: if (button_ev!=NULL && (button_ev->state & (ShiftMask|ControlMask))) { adjustment = ((int)(ZOOMED_SIZE(drawWinW)/HALF_INCH))*HALF_INCH; if (drawOrigX-ABS_SIZE(adjustment) < 0) { adjustment = ZOOMED_SIZE(drawOrigX); } } else { adjustment = HALF_INCH; } break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { if (button_ev!=NULL && (button_ev->state & (ShiftMask|ControlMask))) { adjustment = ((int)(ZOOMED_SIZE(drawWinW)/FAKE_CM))*FAKE_CM; if (drawOrigX-ABS_SIZE(adjustment) < 0) { adjustment = ZOOMED_SIZE(drawOrigX); } } else { adjustment = FAKE_CM; } } else { if (button_ev!=NULL && (button_ev->state & (ShiftMask|ControlMask))) { adjustment = ((int)(ZOOMED_SIZE(drawWinW)/ONE_CM))*ONE_CM; if (drawOrigX-ABS_SIZE(adjustment) < 0) { adjustment = ZOOMED_SIZE(drawOrigX); } } else { adjustment = ONE_CM; } } break; } if (drawOrigX >= ABS_SIZE(adjustment)) { drawOrigX -= ABS_SIZE(adjustment); } else { adjustment = ZOOMED_SIZE(drawOrigX); drawOrigX -= ABS_SIZE(adjustment); if (drawOrigX < 0) drawOrigX = 0; } RedrawHScrollWindow(); UpdDrawWinBBox(); AdjSplineVs(); AdjustCurText(adjustment, 0); RedrawHRulerWindow(); ClearAndRedrawDrawWindow(); } } void ScrollRight(button_ev) XButtonEvent *button_ev; { int adjustment=0; if (paperWidth <= drawWinW) return; if (drawOrigX+drawWinW < paperWidth) { switch (gridSystem) { case ENGLISH_GRID: if (button_ev!=NULL && (button_ev->state & (ShiftMask|ControlMask))) { adjustment = ((int)(ZOOMED_SIZE(drawWinW)/HALF_INCH))*HALF_INCH; } else { adjustment = HALF_INCH; } break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { if (button_ev!=NULL && (button_ev->state & (ShiftMask|ControlMask))) { adjustment = ((int)(ZOOMED_SIZE(drawWinW)/FAKE_CM))*FAKE_CM; } else { adjustment = FAKE_CM; } } else { if (button_ev!=NULL && (button_ev->state & (ShiftMask|ControlMask))) { adjustment = ((int)(ZOOMED_SIZE(drawWinW)/ONE_CM))*ONE_CM; } else { adjustment = ONE_CM; } } break; } drawOrigX += ABS_SIZE(adjustment); RedrawHScrollWindow(); UpdDrawWinBBox(); AdjSplineVs(); AdjustCurText(-adjustment, 0); RedrawHRulerWindow(); ClearAndRedrawDrawWindow(); } } static void DragToInHSBar(ltx, block_start, block_w) int ltx, block_start, block_w; { double start_frac=(double)0.0; int saved_x=drawOrigX, adjustment=0, scroll_all_the_way=FALSE; if (threeDLook) { start_frac = (double)((double)(ltx-scrollBarW) / (double)(scrollAreaW-(scrollBarW<<1))); if (ltx+block_w >= scrollAreaW-scrollBarW) { scroll_all_the_way = TRUE; } } else { start_frac = (double)((double)(block_start)/(double)(scrollAreaW)); if (block_start+block_w >= scrollAreaW) { scroll_all_the_way = TRUE; } } if (start_frac < 0.0) start_frac = 0.0; if (start_frac > 1.0) start_frac = 1.0; if (scroll_all_the_way) { GetMaxScrollOrigin(&drawOrigX, NULL); } else { double dv=(double)0; switch (gridSystem) { case ENGLISH_GRID: dv = ((double)paperWidth) * start_frac; break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { dv = ((double)paperWidth) * start_frac; } else { dv = ((double)paperWidth) * start_frac; } break; } drawOrigX = round(dv); drawOrigX = ABS_SIZE(ZOOMED_SIZE(drawOrigX)); } adjustment = saved_x - drawOrigX; if (adjustment != 0) { RedrawHScrollWindow(); UpdDrawWinBBox(); AdjSplineVs(); AdjustCurText(ZOOMED_SIZE(adjustment), 0); RedrawHRulerWindow(); ClearAndRedrawDrawWindow(); } else { RedrawHScrollWindow(); } } static void DoDragInHSBar(btn_x, btn_offset) int btn_x, btn_offset; { double frac=(double)0.0, start_frac=(double)0.0; int block_w=0, block_start=0, continuous_drag=FALSE; int done=FALSE, ltx=0, min_block_size=1+(windowPadding<<1); int total=max(paperWidth,(drawOrigX+drawWinW)); XEvent ev; scrollingCanvas = SCRL_LF; if (smoothScrollingCanvas == SMOOTH_SCROLLING) { BeginExecAnimate(); if (!TgAnyButtonDown(mainDisplay, vSBarWindow)) { EndExecAnimate(); ClearAndRedrawDrawWindow(); return; } continuous_drag = execAnimating; } block_start = btn_x+btn_offset; frac = (double)(((double)drawWinW) / ((double)paperWidth)); if (threeDLook) { start_frac = (double)(((double)(block_start-scrollBarW)) / ((double)(scrollAreaW-(scrollBarW<<1)))); block_w = (frac >= 1.0) ? (scrollAreaW-(scrollBarW<<1)) : (int)(((double)(scrollAreaW-(scrollBarW<<1))) * frac); if (block_w < min_block_size) block_w = min_block_size; ltx = (start_frac + frac >= 1.0) ? scrollAreaW-scrollBarW-block_w : block_start; start_frac = (double)(((double)(ltx-scrollBarW)) / ((double)(scrollAreaW-(scrollBarW<<1)))); } else { start_frac = (double)(((double)block_start)/((double)scrollAreaW)); block_w = (frac >= 1.0) ? scrollAreaW : (int)(((double)scrollAreaW) * frac); if (block_w <= 0) block_w = 1; ltx = (start_frac + frac >= 1.0) ? scrollAreaW-block_w : block_start; start_frac = (double)(((double)ltx)/((double)scrollAreaW)); } TgDrawScrollBar(mainDisplay, hSBarWindow, HORI_SCROLLBAR, 0, 0, scrollAreaW, scrollBarW, start_frac, drawWinW, total); XGrabPointer(mainDisplay, hSBarWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); while (!done) { XNextEvent(mainDisplay, &ev); if (ev.type == Expose || ev.type == VisibilityNotify) { ExposeEventHandler(&ev, TRUE); } else if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); done = TRUE; } else if (ev.type == MotionNotify) { int new_x=0; block_start = ev.xmotion.x; if (threeDLook) { new_x = ev.xmotion.x+btn_offset; if (new_x < scrollBarW) { new_x = scrollBarW; } else if (new_x+block_w >= scrollAreaW-scrollBarW) { new_x = scrollAreaW-block_w-scrollBarW; } if (new_x != ltx) { ltx = new_x; start_frac = (double)(((double)(ltx-scrollBarW)) / ((double)(scrollAreaW-(scrollBarW<<1)))); TgDrawScrollBar(mainDisplay, hSBarWindow, HORI_SCROLLBAR, 0, 0, scrollAreaW, scrollBarW, start_frac, drawWinW, total); } } else { if (block_start <= 0) { new_x = 0; } else if (block_start+block_w >= scrollAreaW) { new_x = scrollAreaW-block_w; } else { new_x = block_start; } if (new_x != ltx) { ltx = new_x; start_frac = (double)(((double)ltx)/((double)scrollAreaW)); TgDrawScrollBar(mainDisplay, hSBarWindow, HORI_SCROLLBAR, 0, 0, scrollAreaW, scrollBarW, start_frac, drawWinW, total); } } if (continuous_drag) { int scroll_all_the_way=FALSE; if (threeDLook) { start_frac = (double)(((double)(ltx-scrollBarW)) / ((double)(scrollAreaW-(scrollBarW<<1)))); if (ltx+block_w >= scrollAreaW-scrollBarW) { scroll_all_the_way = TRUE; } } else { start_frac = (double)(((double)ltx)/((double)scrollAreaW)); if (block_start+block_w >= scrollAreaW) { scroll_all_the_way = TRUE; } } RedrawAreaFromCache(start_frac, scroll_all_the_way); } else if (smoothScrollingCanvas == JUMP_SCROLLING) { DragToInHSBar(ltx, block_start, block_w); } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } if (smoothScrollingCanvas == SMOOTH_SCROLLING) { EndExecAnimate(); RedrawCurText(); } scrollingCanvas = INVALID; DragToInHSBar(ltx, block_start, block_w); } static void HSBarHandler(button_ev) XButtonEvent *button_ev; { int do_drag=FALSE, btn_offset=0; int total=max(paperWidth,(drawOrigX+drawWinW)); if (!threeDLook && button_ev->button == Button3 && button_ev->type == ButtonPress) { DoSBarBtnScroll(mainDisplay, hSBarWindow, ((button_ev->state & (ShiftMask|ControlMask)) != 0), SCRL_LF, NULL); } else if (!threeDLook && button_ev->button == Button1 && button_ev->type == ButtonPress) { DoSBarBtnScroll(mainDisplay, hSBarWindow, ((button_ev->state & (ShiftMask|ControlMask)) != 0), SCRL_RT, NULL); } else if (button_ev->button == Button1 && button_ev->type == ButtonPress) { if (button_ev->x < scrollBarW || button_ev->x >= scrollAreaW-scrollBarW) { int which=0; struct BBRec bbox; if (button_ev->x < scrollBarW) { which = SCRL_LF; SetBBRec(&bbox, 0, 0, scrollBarW, scrollBarW); } else { which = SCRL_RT; SetBBRec(&bbox, scrollAreaW-scrollBarW, 0, scrollAreaW, scrollBarW); } DoSBarBtnScroll(mainDisplay, hSBarWindow, FALSE, which, &bbox); } else { double start_frac=(double)0.0; int hit=0; if (total == 0) { start_frac = (double)1.0; } else { start_frac = (double)((double)drawOrigX / (double)total); } if (start_frac > 1.0) start_frac = 1.0; hit = TgGetScrollHit(button_ev->x, button_ev->y, HORI_SCROLLBAR, scrollAreaW, scrollBarW, start_frac, drawWinW, total, &btn_offset); if (hit == 0) { do_drag = TRUE; } else { DoSBarBtnScroll(mainDisplay, hSBarWindow, TRUE, (hit < 0 ? SCRL_LF : SCRL_RT), NULL); } } } else if (!threeDLook && button_ev->button == Button2 && button_ev->type == ButtonPress) { do_drag = TRUE; } if (do_drag) { DoDragInHSBar(button_ev->x, btn_offset); } } void ScrollEventHandler(input) XEvent *input; { if (input->xany.window == vSBarWindow) { if (input->type == Expose) { XSync(mainDisplay, False); RedrawVScrollWindow(); return; } else if (input->type == MotionNotify) { if (threeDLook) { if (input->xmotion.y < scrollBarW) { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_UP), "", ""); } else if (input->xmotion.y >= scrollAreaH-scrollBarW) { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_DOWN), "", ""); } else { int total=max(paperHeight,(drawOrigY+drawWinH)), hit=FALSE; double start_frac=(double)0.0; if (total == 0) { start_frac = (double)1.0; } else { start_frac = (double)((double)drawOrigY / (double)total); } if (start_frac > 1.0) start_frac = 1.0; hit = TgGetScrollHit(input->xmotion.x, input->xmotion.y, VERT_SCROLLBAR, scrollBarW, scrollAreaH, start_frac, drawWinH, total, NULL); if (hit < 0) { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_PAGE_UP), "", ""); } else if (hit > 0) { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_PAGE_DOWN), "", ""); } else { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_VERTICALLY), "", ""); } } } return; } else if (input->type == EnterNotify) { if (threeDLook) { SetMouseStatus("", "", ""); } else { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_DOWN), TgLoadCachedString(CSTID_SCROLL_VERTICALLY), TgLoadCachedString(CSTID_SCROLL_UP)); } return; } Msg(""); VSBarHandler(&(input->xbutton)); return; } else if (input->xany.window == hSBarWindow) { if (input->type == Expose) { XSync(mainDisplay, False); RedrawHScrollWindow(); return; } else if (input->type == MotionNotify) { if (threeDLook) { if (input->xmotion.x < scrollBarW) { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_LEFT), "", ""); } else if (input->xmotion.x >= scrollAreaW-scrollBarW) { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_RIGHT), "", ""); } else { int total=max(paperWidth,(drawOrigX+drawWinW)), hit=FALSE; double start_frac=(double)0.0; if (total == 0) { start_frac = (double)1.0; } else { start_frac=(double)((double)drawOrigX / (double)total); } if (start_frac > 1.0) start_frac = 1.0; hit = TgGetScrollHit(input->xmotion.x, input->xmotion.y, HORI_SCROLLBAR, scrollAreaW, scrollBarW, start_frac, drawWinW, total, NULL); if (hit < 0) { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_PAGE_LEFT), "", ""); } else if (hit > 0) { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_PAGE_RIGHT), "", ""); } else { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_HORIZONTALLY), "", ""); } } } return; } else if (input->type == EnterNotify) { if (threeDLook) { SetMouseStatus("", "", ""); } else { SetMouseStatus(TgLoadCachedString(CSTID_SCROLL_RIGHT), TgLoadCachedString(CSTID_SCROLL_HORIZONTALLY), TgLoadCachedString(CSTID_SCROLL_LEFT)); } return; } Msg(""); HSBarHandler(&(input->xbutton)); return; } } void ScrollToSpecifiedOrigin(cur_page_num, orig_x, orig_y, zoom_scale, zoomed_in) int cur_page_num, orig_x, orig_y, zoom_scale, zoomed_in; { int adj_caches=(zoomScale != zoom_scale || zoomedIn != zoomed_in); if (cur_page_num <= 0 || cur_page_num > lastPageNum) return; if (drawOrigX == orig_x && drawOrigY == orig_y && cur_page_num == curPageNum && !adj_caches) { return; } drawOrigX = orig_x; drawOrigY = orig_y; zoomScale = zoom_scale; zoomedIn = zoomed_in; UpdDrawWinWH(); UpdDrawWinBBox(); AdjSplineVs(); if (adj_caches) { AdjCaches(); ShowZoom(); } if (cur_page_num != curPageNum) { GotoPageNum(cur_page_num); ShowPage(); } ClearAndRedrawDrawWindow(); RedrawRulers(); RedrawScrollBars(); justDupped = FALSE; } static int xOrigin=0, yOrigin=0, zoomScaleOrigin=0, zoomedInOrigin=FALSE; int ScrollToOrigin() /* * return TRUE of scrolled or zoomed */ { int adj_caches=(zoomScale!=zoomScaleOrigin || zoomedIn!=zoomedInOrigin); if (drawOrigX==xOrigin && drawOrigY==yOrigin && !adj_caches) { return FALSE; } TieLooseEnds(); SetCurChoice(NOTHING); drawOrigX = xOrigin; drawOrigY = yOrigin; zoomScale = zoomScaleOrigin; zoomedIn = zoomedInOrigin; UpdDrawWinWH(); UpdDrawWinBBox(); AdjSplineVs(); if (adj_caches) { AdjCaches(); ShowZoom(); } ClearAndRedrawDrawWindow(); RedrawRulers(); RedrawScrollBars(); justDupped = FALSE; return TRUE; } void SaveOrigin() { xOrigin = drawOrigX; yOrigin = drawOrigY; zoomScaleOrigin = zoomScale; zoomedInOrigin = zoomedIn; } void SetOrigin(x, y, zoom_scale, zoomed_in) int x, y, zoom_scale, zoomed_in; { xOrigin = x; yOrigin = y; zoomScaleOrigin = zoom_scale; zoomedInOrigin = zoomed_in; } void GetOrigin(pn_x, pn_y, pn_zoom_scale, pn_zoomed_in) int *pn_x, *pn_y, *pn_zoom_scale, *pn_zoomed_in; { *pn_x = xOrigin; *pn_y = yOrigin; *pn_zoom_scale = zoomScaleOrigin; *pn_zoomed_in = zoomedInOrigin; } void CleanUpScrolls() { if (scrl_up_bits == NULL) { } } void UpdScrollWinWH() { scrollAreaH = vSBarH; scrollAreaW = hSBarW; RedrawScrollBars(); } void InitScroll() { char *c_ptr=NULL; smoothScrollingCanvas = JUMP_SCROLLING; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "SmoothScrollingCanvas")) != NULL) { if (UtilStrICmp(c_ptr, "smooth") == 0) { smoothScrollingCanvas = SMOOTH_SCROLLING; } else if (UtilStrICmp(c_ptr, "jump") == 0) { smoothScrollingCanvas = JUMP_SCROLLING; } else if (UtilStrICmp(c_ptr, "off") == 0) { smoothScrollingCanvas = NO_UPDATE_SCROLLING; } else { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "SmoothScrollingCanvas", c_ptr, "jump"); fprintf(stderr, "\n"); } } resetOriginOnAdvancePage = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ResetOriginOnAdvancePage")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { resetOriginOnAdvancePage = TRUE; } UpdScrollWinWH(); } void ChangeScrollMode(ModeIndex) int ModeIndex; { smoothScrollingCanvas = ModeIndex; switch (smoothScrollingCanvas) { case SMOOTH_SCROLLING: sprintf(gszMsgBox, TgLoadString(STID_WILL_UPD_WIN_SMOOTH_SCROLL)); break; case JUMP_SCROLLING: sprintf(gszMsgBox, TgLoadString(STID_WILL_UPD_WIN_JUMP_SCROLL)); break; case NO_UPDATE_SCROLLING: sprintf(gszMsgBox, TgLoadString(STID_WILL_NOT_UPD_WIN_SCROLL)); break; } Msg(gszMsgBox); } int RefreshScrollModeMenu(menu) TgMenu *menu; { int i, rc=TRUE, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == smoothScrollingCanvas); if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_RADIO, &stMenuItem)) { rc = FALSE; } } return rc; } TgMenu *CreateScrollModeMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { menu->track_menubar = TRUE; if (!RefreshScrollModeMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshScrollModeMenu); } return menu; } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/convxim.c����������������������������������������������������������������������������0000644�0000764�0000764�00000030120�11602233311�014606� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Yoichiro Ueno (ueno@cs.titech.ac.jp) * * Copyright (C) 1991, 1992, Yoichiro Ueno. * * Permission to use, copy, modify, and distribute this software and * its documentation for any purpose is hereby granted by the Author without * fee, provided that the above copyright notice appear in all copies and * that both the copyright notice and this permission notice appear in * supporting documentation, and that the name of the Author not be used * in advertising or publicity pertaining to distribution of the software * without specific, written prior permission. The Author makes no * representations about the suitability of this software for any purpose. * It is provided "as is" without express or implied warranty. * * THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO * EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR * OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR * PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/convxim.c,v 1.5 2009/08/07 03:41:16 william Exp $ */ #ifndef _NO_XIM #define _INCLUDE_FROM_CONVXIM_C_ #include "tgifdefs.h" #include "convkinput.e" #include "convxim.e" #include "dialog.e" #include "font.e" #include "list.e" #include "miniline.e" #include "msg.e" #include "setup.e" #include "strtbl.e" #include "util.e" #ifndef _NO_XIMP #define DEFAULT_MODIFIERS "" #define DEFAULT_LANG "ja_JP.EUC" #else /* _NO_XIMP */ #define DEFAULT_MODIFIERS "@im=_XWNMO" #define DEFAULT_LANG "ja_JP.ujis" #endif /* ~_NO_XIMP */ typedef struct tagXICInfo { XIC ic; Window win; } XICInfo; static CVList gXICInfoList; char ximConvModifiers[MAXSTRING] = DEFAULT_MODIFIERS; char ximConvLang[MAXSTRING] = DEFAULT_LANG; static char *locale = NULL; static char *modifiers = NULL; static XIM im = NULL; static XIC ic = NULL; typedef void (MYIOErrHandler)ARGS_DECL((void)); static MYIOErrHandler *oldhandler = NULL; static Bool _XIMErrorFlag = False; static Bool overthespot = False; static Bool modscim = False; static int pre_x = 0; static int pre_y = 0; #ifndef _NO_XIMP static MYIOErrHandler *_XipSetIOErrorHandler(new_handler) MYIOErrHandler *new_handler; { return NULL; } #else /* _NO_XIMP */ extern void (*_XipSetIOErrorHandler())(); #endif /* ~_NO_XIMP */ /* --------------------- Utility Functions --------------------- */ static CVListElem *FindXIC(win) Window win; { CVListElem *pElem=NULL; for (pElem=ListFirst(&gXICInfoList); pElem != NULL; pElem=ListNext(&gXICInfoList, pElem)) { XICInfo *pxi=(XICInfo*)(pElem->obj); if (pxi->win == win) { return pElem; } } return NULL; } static void DeleteXICInfo(pElem) CVListElem *pElem; { XICInfo *pxi=(XICInfo*)(pElem->obj); if (pxi->ic != NULL) XDestroyIC(pxi->ic); ListUnlink(&gXICInfoList, pElem); free(pElem); } /* --------------------- Exported Functions --------------------- */ static void _XIMIOError() { _XIMErrorFlag = True; } static void XIMClose(win) Window win; { CVListElem *pElem=FindXIC(win); if (pElem != NULL) { DeleteXICInfo(pElem); } } #define ROOT 1 #define OVERTHESPOT 2 static int style_type=ROOT; XFontSet XIMfs; XFontSetExtents * fs_ext=NULL; char** missing_list=NULL; int missing_count=0; char* def_string=NULL; char* XIMFontSetStr="-misc-fixed-medium-r-normal--14-*"; static void XIMSetLocale() { #ifndef _NO_LOCALE_SUPPORT char buf[80], *c_ptr=NULL; c_ptr = (char*)getenv("LC_ALL"); if (c_ptr != NULL) { UtilStrCpyN(ximConvLang, sizeof(ximConvLang), c_ptr); } else { c_ptr = (char*)getenv("LANG"); if (c_ptr != NULL) { UtilStrCpyN(ximConvLang, sizeof(ximConvLang), c_ptr); } else if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "Lang")) != NULL) { UtilTrimBlanks(c_ptr); UtilStrCpyN(ximConvLang, sizeof(ximConvLang), c_ptr); } } locale = setlocale(LC_ALL, ximConvLang); sprintf(buf, TgLoadString(STID_LOCALE_IS), locale==NULL ? TgLoadCachedString(CSTID_PARANED_NULL) : locale); Msg(buf); c_ptr = (char*)getenv("LC_CTYPE"); if (c_ptr != NULL) { UtilStrCpyN(buf, sizeof(buf), c_ptr); locale = setlocale(LC_CTYPE, buf); #ifdef _TGIF_DBG /* debug, do not translate */ sprintf(buf, "LC_CTYPE is '%s'.", locale==NULL ? "null" : locale); Msg(buf); #endif /* _TGIF_DBG */ } setlocale(LC_NUMERIC, "C"); #endif /* ~_NO_LOCALE_SUPPORT */ } void XIMSetICFocus(dpy, win) Display *dpy; Window win; { char buf[80]; XIMStyles * styles=NULL; Bool style_flag; int style_attr=0; int i; XPoint spot; XRectangle s_rect; XVaNestedList preedit_attr, status_attr; CVListElem *pElem=NULL; if(oldhandler == NULL) oldhandler = _XipSetIOErrorHandler(_XIMIOError); if(locale == NULL) { XIMSetLocale(); } if(modifiers == NULL) { char *c_ptr=(char*)getenv("XMODIFIERS"); if (c_ptr != NULL) { UtilStrCpyN(ximConvModifiers, sizeof(ximConvModifiers), c_ptr); } else { if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "Modifiers")) != NULL) { UtilTrimBlanks(c_ptr); UtilStrCpyN(ximConvModifiers, sizeof(ximConvModifiers), c_ptr); } } modifiers = XSetLocaleModifiers(ximConvModifiers); sprintf(buf, TgLoadString(STID_MODIFIER_IS), modifiers==NULL ? TgLoadCachedString(CSTID_PARANED_NULL) : modifiers); Msg(buf); } for (i = 0; i <= (int)strlen(modifiers) - 4 ; i++) { if (strncmp((char *)&modifiers[i], "SCIM", 4) == 0 || strncmp((char *)&modifiers[i], "scim", 4) == 0) { modscim = True; break; } } if(im == NULL) { im = XOpenIM(mainDisplay, NULL, NULL, NULL); if(im == NULL) { MsgBox(TgLoadString(STID_CANNOT_OPEN_XIM), TOOL_NAME, INFO_MB); return; } } pElem = FindXIC(win); if (pElem != NULL) { XICInfo *pxi=(XICInfo*)(pElem->obj); ic = pxi->ic; } else { XICInfo *pxi=(XICInfo*)malloc(sizeof(XICInfo)); if (pxi == NULL) FailAllocMessage(); memset(pxi, 0, sizeof(XICInfo)); if (!ListAppend(&gXICInfoList, pxi)) { } pxi->win = win; XGetIMValues(im, XNQueryInputStyle, &styles, NULL, NULL); style_flag = False; if (overthespot) { for(i = 0; i < (int)(styles->count_styles); i ++){ if((styles->supported_styles[i] == (XIMPreeditPosition | XIMStatusArea)) || (styles->supported_styles[i] == (XIMPreeditPosition | XIMStatusNothing))){ style_flag = True; style_type = OVERTHESPOT; style_attr = styles->supported_styles[i]; Msg(TgLoadString(STID_OVERTHESPOT_CONV)); } } }else{ for(i = 0; i < (int)(styles->count_styles); i ++){ if(styles->supported_styles[i] == (XIMPreeditNothing | XIMStatusNothing)){ style_flag = True; style_type = ROOT; Msg(TgLoadString(STID_ROOT_CONV)); } } } if(!style_flag) { sprintf(gszMsgBox, TgLoadString(STID_IM_NOT_SUPPORT_GIVEN_STYLE), (overthespot ? "OverTheSpot" : "Root")); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); XCloseIM(im); im = NULL; return; } switch (style_type){ case ROOT: ic = XCreateIC(im, XNInputStyle , XIMPreeditNothing | XIMStatusNothing, XNClientWindow, win, XNFocusWindow, win, NULL, NULL); break; case OVERTHESPOT: XIMfs=XCreateFontSet(dpy, XIMFontSetStr, &missing_list, &missing_count, &def_string); fs_ext=XExtentsOfFontSet(XIMfs); spot.x=0; spot.y=fs_ext->max_logical_extent.height; s_rect.x=0; s_rect.y=fs_ext->max_logical_extent.height; s_rect.width=640; s_rect.height=fs_ext->max_logical_extent.height; preedit_attr=XVaCreateNestedList(0, XNSpotLocation, &spot, XNFontSet, XIMfs, NULL); status_attr=XVaCreateNestedList(0, XNArea, &s_rect, XNFontSet, XIMfs, NULL); ic = XCreateIC(im, XNInputStyle , style_attr, XNClientWindow, win, XNFocusWindow, win, XNPreeditAttributes, preedit_attr, XNStatusAttributes, status_attr, NULL, NULL); XFree(preedit_attr); XFree(status_attr); break; } if(ic == NULL) { fprintf(stderr, "%s\n", TgLoadString(STID_FAIL_TO_CREATE_INPUTCONTEXT)); XCloseIM(im); im = NULL; return; } pxi->ic = ic; Msg(TgLoadString(STID_OPEN_XIM)); } XSetICFocus(ic); if(_XIMErrorFlag) { XIMClose(win); Msg(TgLoadString(STID_CLOSE_XIM)); } } void XIMNextEvent(dpy, win, xev_p) Display * dpy; Window win; XEvent * xev_p; { Bool filter_status; do { XNextEvent(dpy, xev_p); /* * The 2nd argument has been changed from win to None * according to Ambrose Li's investigation. See his * e-mail on "Sun, 09 Mar 2003 19:09:38 EST". */ filter_status = XFilterEvent(xev_p, None); if(_XIMErrorFlag) { XIMClose(win); Msg(TgLoadString(STID_CLOSE_XIM)); } } while(filter_status == True); } int XIMLookupString(key_ev, buf, buf_len, key_sym_p, c_stat_p) XKeyEvent * key_ev; char * buf; int buf_len; KeySym * key_sym_p; XIMStatus * c_stat_p; { int has_ch=0; if(im && ic) { c_stat_p->valid = MB_STATUS; has_ch = XmbLookupString (ic, key_ev, buf, buf_len, key_sym_p, &c_stat_p->mb_status); /* * switch (c_stat_p->mb_status) { * case XLookupKeySym: * case XLookupBoth: * { * unsigned int key_sym=(unsigned int)(*key_sym_p); * * if (key_sym < 0x100) { * has_ch = 1; * *buf = (char)(unsigned char)(key_sym & 0x0ff); * buf[1] = '\0'; * } * } * break; * default: break; * } */ } else { c_stat_p->valid = COMPOSE_STATUS; has_ch = XLookupString (key_ev, buf, buf_len, key_sym_p, &c_stat_p->status); } return has_ch; } void XIMUnsetICFocus(win) Window win; { CVListElem *pElem=FindXIC(win); if (pElem != NULL) { XICInfo *pxi=(XICInfo*)(pElem->obj); ic = pxi->ic; } if(im && ic) { XUnsetICFocus(ic); } } void XIMSetConvOverSpot(gnOverTheSpot) Bool gnOverTheSpot; { overthespot=gnOverTheSpot; } void XIMTellCursorPosition(dpy, win, x, y) Display* dpy; Window win; int x; int y; { XPoint spot; XRectangle s_rect; XVaNestedList preedit_attr,status_attr; char szAttemptedFontName[MAXSTRING+1]; CVListElem *pElem=FindXIC(win); if (pElem != NULL) { XICInfo *pxi=(XICInfo*)(pElem->obj); ic = pxi->ic; } if (im == NULL || ic == NULL || !overthespot) return; if (x == pre_x && y == pre_y) return; pre_x = x; pre_y = y; if (XIMfs) XFreeFontSet(dpy, XIMfs); GetCurFontInfoStr(szAttemptedFontName, sizeof(szAttemptedFontName)); XIMfs=XCreateFontSet(dpy, szAttemptedFontName, &missing_list, &missing_count, &def_string); fs_ext=XExtentsOfFontSet(XIMfs); spot.x=textCurX; spot.y=textCurBaselineY; s_rect.x=textCurX; s_rect.y=textCurBaselineY+3; /*s_rect.width=200; s_rect.height=fs_ext->max_logical_extent.height;*/ s_rect.width=50; s_rect.height=16; preedit_attr=XVaCreateNestedList(0, XNSpotLocation, &spot, XNFontSet, XIMfs, NULL); status_attr=XVaCreateNestedList(0, XNArea, &s_rect, NULL); XSetICValues(ic, XNPreeditAttributes, preedit_attr, XNStatusAttributes, status_attr, NULL); XFree(preedit_attr); XFree(status_attr); if (!modscim) { XSetICFocus(ic); } } void XIMCleanUp() { CVListElem *pElem=NULL; for (pElem=ListFirst(&gXICInfoList); pElem != NULL; pElem=ListNext(&gXICInfoList, pElem)) { XICInfo *pxi=(XICInfo*)(pElem->obj); if (pxi->ic != NULL) XDestroyIC(pxi->ic); free(pxi); } ListUnlinkAll(&gXICInfoList); if(im != NULL) { XCloseIM(im); } im = NULL; ic = NULL; _XIMErrorFlag = False; } int XIMInit() { im = NULL; ic = NULL; _XIMErrorFlag = False; CVListInit(&gXICInfoList); return TRUE; } #endif /* ~_NO_XIM */ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/poly.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000623234�11602233312�014125� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/poly.c,v 1.69 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_POLY_C_ #include "tgifdefs.h" #include "arc.e" #include "attr.e" #include "auxtext.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "grid.e" #include "list.e" #include "mainloop.e" #include "mark.e" #include "msg.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "pin.e" #include "poly.e" #include "polygon.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "special.e" #include "spline.e" #include "stretch.e" #include "strtbl.e" #include "util.e" #include "xpixmap.e" #define RETREAT (0.8) WiringInfo gstWiringInfo; int polyDrawn=FALSE; int queryPolyNameOnConnect=TRUE; /* short widthOfLine[] = { 0, 3, 6, 0 }; */ /* short arrowHeadH[] = { 3, 5, 10, 3 }; */ /* short arrowHeadW[] = { 8, 12, 22, 8 }; */ short origWidthOfLine[] = { 1, 2, 3, 4, 5, 6, 7 }; short origArrowHeadH[] = { 3, 4, 5, 6, 7, 8, 9 }; short origArrowHeadW[] = { 8, 10, 12, 14, 18, 20, 22 }; short *curWidthOfLine=NULL; short *curArrowHeadH=NULL; short *curArrowHeadW=NULL; char **curWidthOfLineSpec=NULL; char **curArrowHeadHSpec=NULL; char **curArrowHeadWSpec=NULL; int numPtsInPoly=0; CVList gStructSplineList; struct PtRec *lastPtPtr=NULL; struct ObjRec *drawPolyHighlightedNode=NULL; IntPoint *GetPolyOrPolygonAbsVs(pn_return, pn_allocated, ObjPtr) int *pn_return, *pn_allocated; struct ObjRec *ObjPtr; { int i=0, n=0; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; IntPoint *vs=NULL, *return_vs=NULL; switch (ObjPtr->type) { case OBJ_POLY: poly_ptr = ObjPtr->detail.p; if (poly_ptr->curved == LT_STRUCT_SPLINE) { n = poly_ptr->ssn; vs = poly_ptr->ssvlist; } else { n = poly_ptr->n; vs = poly_ptr->vlist; } break; case OBJ_POLYGON: polygon_ptr = ObjPtr->detail.g; if (polygon_ptr->curved == LT_STRUCT_SPLINE) { n = polygon_ptr->ssn; vs = polygon_ptr->ssvlist; } else { n = polygon_ptr->n; vs = polygon_ptr->vlist; } break; } *pn_return = n; if (ObjPtr->ctm == NULL) { *pn_allocated = FALSE; return vs; } *pn_allocated = TRUE; return_vs = (IntPoint*)malloc(n*sizeof(IntPoint)); if (return_vs == NULL) FailAllocMessage(); memset(return_vs, 0, n*sizeof(IntPoint)); for (i=0; i < n; i++) { int x_off=0, y_off=0; TransformPointThroughCTM(vs[i].x-ObjPtr->x, vs[i].y-ObjPtr->y, ObjPtr->ctm, &x_off, &y_off); return_vs[i].x = ObjPtr->x + x_off; return_vs[i].y = ObjPtr->y + y_off; } return return_vs; } XPoint *MakePolyVertex(XOff, YOff, NumVs, Vs) int XOff, YOff, NumVs; register IntPoint *Vs; { register XPoint *v; register int i; int real_x_off, real_y_off; real_x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); real_y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); v = (XPoint*)malloc((NumVs+1)*sizeof(XPoint)); if (v == NULL) FailAllocMessage(); for (i = 0; i < NumVs; i++) { v[i].x = (short)ZOOMED_SIZE(Vs[i].x-real_x_off); v[i].y = (short)ZOOMED_SIZE(Vs[i].y-real_y_off); } return v; } void CalcPolyBBox(ObjPtr) struct ObjRec *ObjPtr; { register int x, y; struct PolyRec *poly_ptr=ObjPtr->detail.p; int style=poly_ptr->style, width=poly_ptr->width; int aw=poly_ptr->aw, ah=poly_ptr->ah; int ltx=ObjPtr->obbox.ltx, lty=ObjPtr->obbox.lty; int rbx=ObjPtr->obbox.rbx, rby=ObjPtr->obbox.rby; int dx=0, dy=0, tmp_x=0, tmp_y=0, num_pts=0; double len, sin, cos, w, h; IntPoint *v=NULL; int retracted_arrow=(RetractedArrowAttr(ObjPtr) || AutoRetractedArrowAttr(ObjPtr, TRUE)); switch (poly_ptr->curved) { case LT_STRAIGHT: case LT_SPLINE: num_pts = poly_ptr->n; v = poly_ptr->vlist; break; case LT_STRUCT_SPLINE: num_pts = poly_ptr->ssn; v = poly_ptr->ssvlist; break; case LT_INTSPLINE: num_pts = poly_ptr->intn; v = poly_ptr->intvlist; break; } dx = v[1].x - v[0].x; dy = v[1].y - v[0].y; if ((style & LS_LEFT) && (dx != 0 || dy != 0)) { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin = ((double)dy) / len; cos = ((double)dx) / len; w = (double)aw; h = (double)max(ah,(width>>1)); x = round(v[0].x + w*cos - h*sin); y = round(v[0].y + w*sin + h*cos); if (ObjPtr->ctm != NULL) { TransformPointThroughCTM(x-ObjPtr->x, y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); x = tmp_x+ObjPtr->x; y = tmp_y+ObjPtr->y; } if (x < ltx) ltx = x; if (y < lty) lty = y; if (x > rbx) rbx = x; if (y > rby) rby = y; x = round(v[0].x + w*cos + h*sin); y = round(v[0].y + w*sin - h*cos); if (ObjPtr->ctm != NULL) { TransformPointThroughCTM(x-ObjPtr->x, y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); x = tmp_x+ObjPtr->x; y = tmp_y+ObjPtr->y; } if (x < ltx) ltx = x; if (y < lty) lty = y; if (x > rbx) rbx = x; if (y > rby) rby = y; } dx = v[num_pts-1].x - v[num_pts-2].x; dy = v[num_pts-1].y - v[num_pts-2].y; if ((style & LS_RIGHT) && (dx != 0 || dy != 0)) { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin = ((double)dy) / len; cos = ((double)dx) / len; w = (double)aw; h = (double)max(ah,(width>>1)); x = round(v[num_pts-1].x - w*cos + h*sin); y = round(v[num_pts-1].y - w*sin - h*cos); if (ObjPtr->ctm != NULL) { TransformPointThroughCTM(x-ObjPtr->x, y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); x = tmp_x+ObjPtr->x; y = tmp_y+ObjPtr->y; } if (x < ltx) ltx = x; if (y < lty) lty = y; if (x > rbx) rbx = x; if (y > rby) rby = y; x = round(v[num_pts-1].x - w*cos - h*sin); y = round(v[num_pts-1].y - w*sin + h*cos); if (ObjPtr->ctm != NULL) { TransformPointThroughCTM(x-ObjPtr->x, y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); x = tmp_x+ObjPtr->x; y = tmp_y+ObjPtr->y; } if (x < ltx) ltx = x; if (y < lty) lty = y; if (x > rbx) rbx = x; if (y > rby) rby = y; } if (retracted_arrow) { int i; for (i=1; i < num_pts; i++) { x = v[i].x; y = v[i].y; if (x-ah < ltx) ltx = x-ah; if (y-ah < lty) lty = y-ah; if (x+ah > rbx) rbx = x+ah; if (y+ah > rby) rby = y+ah; } } ObjPtr->bbox.ltx = min(ltx, ObjPtr->obbox.ltx-(width>>1)); ObjPtr->bbox.lty = min(lty, ObjPtr->obbox.lty-(width>>1)); ObjPtr->bbox.rbx = max(rbx, ObjPtr->obbox.rbx+(width>>1)); ObjPtr->bbox.rby = max(rby, ObjPtr->obbox.rby+(width>>1)); } void UpdPolyBBox(ObjPtr, NumPts, V) struct ObjRec *ObjPtr; int NumPts; IntPoint *V; { register int i; int ltx, lty, rbx, rby; ltx = rbx = V[0].x; lty = rby = V[0].y; for (i = 1; i < NumPts; i++) { if (V[i].x < ltx) ltx = V[i].x; if (V[i].y < lty) lty = V[i].y; if (V[i].x > rbx) rbx = V[i].x; if (V[i].y > rby) rby = V[i].y; } if (ObjPtr->ctm == NULL) { ObjPtr->x = ltx; ObjPtr->y = lty; ObjPtr->obbox.ltx = ltx; ObjPtr->obbox.lty = lty; ObjPtr->obbox.rbx = rbx; ObjPtr->obbox.rby = rby; } else { IntPoint abs_obj_obbox_vs[5]; ObjPtr->orig_obbox.ltx = ltx; ObjPtr->orig_obbox.lty = lty; ObjPtr->orig_obbox.rbx = rbx; ObjPtr->orig_obbox.rby = rby; GetTransformedOBBoxAbsVs(ObjPtr, abs_obj_obbox_vs); ObjPtr->obbox.ltx = min(min(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), min(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); ObjPtr->obbox.rbx = max(max(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), max(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); ObjPtr->obbox.lty = min(min(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), min(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); ObjPtr->obbox.rby = max(max(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), max(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); } AdjObjBBox(ObjPtr); } void UpdNonIntSplinePolyBBox(obj_ptr, num_pts, v) struct ObjRec *obj_ptr; int num_pts; IntPoint *v; { switch (obj_ptr->type) { case OBJ_POLY: switch (obj_ptr->detail.p->curved) { case LT_STRAIGHT: case LT_SPLINE: case LT_STRUCT_SPLINE: UpdPolyBBox(obj_ptr, num_pts, v); break; case LT_INTSPLINE: UpdPolyBBox(obj_ptr, obj_ptr->detail.p->intn, obj_ptr->detail.p->intvlist); break; } break; case OBJ_POLYGON: switch (obj_ptr->detail.g->curved) { case LT_STRAIGHT: case LT_SPLINE: case LT_STRUCT_SPLINE: UpdPolyBBox(obj_ptr, num_pts, v); break; case LT_INTSPLINE: UpdPolyBBox(obj_ptr, obj_ptr->detail.g->intn, obj_ptr->detail.g->intvlist); break; } break; } } void UpdPolyOrPolygonBBox(obj_ptr) struct ObjRec *obj_ptr; { switch (obj_ptr->type) { case OBJ_POLY: switch (obj_ptr->detail.p->curved) { case LT_STRAIGHT: case LT_SPLINE: case LT_STRUCT_SPLINE: UpdPolyBBox(obj_ptr, obj_ptr->detail.p->n, obj_ptr->detail.p->vlist); break; case LT_INTSPLINE: UpdPolyBBox(obj_ptr, obj_ptr->detail.p->intn, obj_ptr->detail.p->intvlist); break; } break; case OBJ_POLYGON: switch (obj_ptr->detail.g->curved) { case LT_STRAIGHT: case LT_SPLINE: case LT_STRUCT_SPLINE: UpdPolyBBox(obj_ptr, obj_ptr->detail.g->n, obj_ptr->detail.g->vlist); break; case LT_INTSPLINE: UpdPolyBBox(obj_ptr, obj_ptr->detail.g->intn, obj_ptr->detail.g->intvlist); break; } break; } } #define CREATE_RELATIVE (FALSE) #define CREATE_ABSOLUTE (TRUE) void CreatePolyObj(NumPts, CreateAbsolute) int NumPts; int CreateAbsolute; { struct PtRec *pt_ptr=NULL, *next_pt=NULL; struct PolyRec *poly_ptr=NULL; struct ObjRec *obj_ptr=NULL; register int i; IntPoint *v=NULL; int ltx, lty, rbx, rby, num_ss_pts=0; char *smooth=NULL; CVListElem *elem=NULL; IntPointTriplet *pipt=NULL; poly_ptr = (struct PolyRec *)malloc(sizeof(struct PolyRec)); if (poly_ptr == NULL) FailAllocMessage(); memset(poly_ptr, 0, sizeof(struct PolyRec)); if (curSpline == LT_STRUCT_SPLINE) { num_ss_pts = (NumPts*3)-2; poly_ptr->n = num_ss_pts; v = (IntPoint*)malloc((num_ss_pts+1)*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); smooth = (char*)malloc((num_ss_pts+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); elem = ListLast(&gStructSplineList); pipt = (IntPointTriplet*)(elem->obj); ltx = rbx = pipt->hinge_pt.x; lty = rby = pipt->hinge_pt.y; for (i=NumPts-1; i >= 0; i--, elem=ListPrev(&gStructSplineList, elem)) { pipt = (IntPointTriplet*)(elem->obj); if (i == 0) { v[0].x = CreateAbsolute ? pipt->hinge_pt.x : ABS_X(pipt->hinge_pt.x); v[0].y = CreateAbsolute ? pipt->hinge_pt.y : ABS_Y(pipt->hinge_pt.y); if (pipt->later_valid) { v[1].x = CreateAbsolute ? pipt->later_smooth_pt.x : ABS_X(pipt->later_smooth_pt.x); v[1].y = CreateAbsolute ? pipt->later_smooth_pt.y : ABS_Y(pipt->later_smooth_pt.y); smooth[1] = TRUE; } else { v[1].x = v[0].x; v[1].y = v[0].y; smooth[1] = FALSE; } smooth[0] = FALSE; } else if (i == NumPts-1) { v[num_ss_pts-1].x = CreateAbsolute ? pipt->hinge_pt.x : ABS_X(pipt->hinge_pt.x); v[num_ss_pts-1].y = CreateAbsolute ? pipt->hinge_pt.y : ABS_Y(pipt->hinge_pt.y); if (pipt->earlier_valid) { v[num_ss_pts-2].x = CreateAbsolute ? pipt->earlier_smooth_pt.x : ABS_X(pipt->earlier_smooth_pt.x); v[num_ss_pts-2].y = CreateAbsolute ? pipt->earlier_smooth_pt.y : ABS_Y(pipt->earlier_smooth_pt.y); smooth[num_ss_pts-2] = TRUE; } else { v[num_ss_pts-2].x = v[num_ss_pts-1].x; v[num_ss_pts-2].y = v[num_ss_pts-1].y; smooth[num_ss_pts-2] = FALSE; } smooth[num_ss_pts-1] = FALSE; } else { int index=3*i; v[index-1].x = CreateAbsolute ? pipt->earlier_smooth_pt.x : ABS_X(pipt->earlier_smooth_pt.x); v[index-1].y = CreateAbsolute ? pipt->earlier_smooth_pt.y : ABS_Y(pipt->earlier_smooth_pt.y); v[index].x = CreateAbsolute ? pipt->hinge_pt.x : ABS_X(pipt->hinge_pt.x); v[index].y = CreateAbsolute ? pipt->hinge_pt.y : ABS_Y(pipt->hinge_pt.y); v[index+1].x = CreateAbsolute ? pipt->later_smooth_pt.x : ABS_X(pipt->later_smooth_pt.x); v[index+1].y = CreateAbsolute ? pipt->later_smooth_pt.y : ABS_Y(pipt->later_smooth_pt.y); smooth[index-1] = pipt->earlier_valid; smooth[index] = FALSE; smooth[index+1] = pipt->later_valid; } free(pipt); } for (i=0; i < num_ss_pts; i++) { if (v[i].x < ltx) ltx = v[i].x; if (v[i].y < lty) lty = v[i].y; if (v[i].x > rbx) rbx = v[i].x; if (v[i].y > rby) rby = v[i].y; } numPtsInPoly = 0; ListUnlinkAll(&gStructSplineList); } else { poly_ptr->n = NumPts; v = (IntPoint*)malloc((NumPts+1)*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); if (curSpline != LT_INTSPLINE) { smooth = (char*)malloc((NumPts+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); } pt_ptr = lastPtPtr; ltx = rbx = pt_ptr->x; lty = rby = pt_ptr->y; for (i=NumPts-1; i >= 0; i--, lastPtPtr=next_pt) { next_pt = lastPtPtr->next; v[i].x = CreateAbsolute ? lastPtPtr->x : ABS_X(lastPtPtr->x); v[i].y = CreateAbsolute ? lastPtPtr->y : ABS_Y(lastPtPtr->y); if (curSpline != LT_INTSPLINE) { if (lastPtPtr->x < ltx) ltx = lastPtPtr->x; if (lastPtPtr->y < lty) lty = lastPtPtr->y; if (lastPtPtr->x > rbx) rbx = lastPtPtr->x; if (lastPtPtr->y > rby) rby = lastPtPtr->y; if (curSpline == LT_STRAIGHT) { smooth[i] = FALSE; } else { smooth[i] = (i != 0 && i != NumPts-1); } } free(lastPtPtr); } numPtsInPoly = 0; lastPtPtr = NULL; } poly_ptr->vlist = v; poly_ptr->smooth = smooth; poly_ptr->svlist = poly_ptr->asvlist = NULL; poly_ptr->intvlist = NULL; poly_ptr->style = lineStyle; poly_ptr->width = curWidthOfLine[lineWidth]; poly_ptr->aw = curArrowHeadW[lineWidth]; poly_ptr->ah = curArrowHeadH[lineWidth]; UtilStrCpyN(poly_ptr->width_spec, sizeof(poly_ptr->width_spec), curWidthOfLineSpec[lineWidth]); UtilStrCpyN(poly_ptr->aw_spec, sizeof(poly_ptr->aw_spec), curArrowHeadWSpec[lineWidth]); UtilStrCpyN(poly_ptr->ah_spec, sizeof(poly_ptr->ah_spec), curArrowHeadHSpec[lineWidth]); poly_ptr->pen = penPat; poly_ptr->curved = curSpline; poly_ptr->fill = objFill; poly_ptr->dash = curDash; /* * poly_ptr->tighter = (curSpline == LT_STRUCT_SPLINE) ? * tighterStructSplines : FALSE; */ poly_ptr->rotated_n = 0; poly_ptr->rotated_vlist = NULL; poly_ptr->rotated_asn = 0; poly_ptr->rotated_asvlist = NULL; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); obj_ptr->detail.p = poly_ptr; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->type = OBJ_POLY; if (CreateAbsolute) { obj_ptr->obbox.ltx = obj_ptr->x = ltx; obj_ptr->obbox.lty = obj_ptr->y = lty; obj_ptr->obbox.rbx = rbx; obj_ptr->obbox.rby = rby; } else { obj_ptr->obbox.ltx = obj_ptr->x = ABS_X(ltx); obj_ptr->obbox.lty = obj_ptr->y = ABS_Y(lty); obj_ptr->obbox.rbx = ABS_X(rbx); obj_ptr->obbox.rby = ABS_Y(rby); } obj_ptr->id = objId++; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->locked = FALSE; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; obj_ptr->invisible = FALSE; obj_ptr->trans_pat = transPat; AdjObjSplineVs(obj_ptr); if (curSpline != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, poly_ptr->n, poly_ptr->vlist); } else { UpdPolyBBox(obj_ptr, poly_ptr->intn, poly_ptr->intvlist); } AdjObjBBox(obj_ptr); AddObj(NULL, topObj, obj_ptr); } void ResetCreatePoly() { numPtsInPoly = 0; lastPtPtr = NULL; CVListInit(&gStructSplineList); } void AddPtToCreatePoly(AbsX, AbsY) int AbsX, AbsY; { struct PtRec *pt_ptr=(struct PtRec *)malloc(sizeof(struct PtRec)); if (pt_ptr == NULL) FailAllocMessage(); memset(pt_ptr, 0, sizeof(struct PtRec)); pt_ptr->next = lastPtPtr; numPtsInPoly++; lastPtPtr = pt_ptr; pt_ptr->x = AbsX; pt_ptr->y = AbsY; } #ifdef HP_LINE_BUG static void MyDrawLines(dpy, win, gc, sv, sn) Display *dpy; Window win; GC gc; XPoint *sv; int sn; { if (sn == 2) { XPoint hp_sv[3]; hp_sv[0].x = sv[0].x; hp_sv[0].y = sv[0].y; hp_sv[1].x = sv[0].x; hp_sv[1].y = sv[0].y; hp_sv[2].x = sv[1].x; hp_sv[2].y = sv[1].y; XDrawLines(dpy, win, gc, hp_sv, 3, CoordModeOrigin); } else { XDrawLines(dpy, win, gc, sv, sn, CoordModeOrigin); } } #else /* ~HP_LINE_BUG */ #define MyDrawLines(dpy,win,gc,sv,sn) \ XDrawLines((dpy),(win),(gc),(sv),(sn),CoordModeOrigin) #endif /* HP_LINE_BUG */ static void SetXorDrawGCForPoly(color_index, line_width_index) int color_index, line_width_index; { XGCValues values; values.fill_style = FillSolid; #ifdef NO_THIN_LINE values.line_width = 1; #else /* ~NO_THIN_LINE */ values.line_width = 0; #endif /* NO_THIN_LINE */ if (curChoice == FREEHAND) { values.foreground = colorPixels[color_index]; values.function = GXcopy; values.line_width = curWidthOfLine[line_width_index]; #ifdef NO_THIN_LINE if (curWidthOfLine[lineWidth] < 1) values.line_width = 1; #endif /* NO_THIN_LINE */ } else { values.foreground = xorColorPixels[color_index]; values.function = GXxor; } values.line_style = LineSolid; values.join_style = JoinBevel; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCLineWidth | GCLineStyle | GCJoinStyle, &values); } #define POLY_DRAW (FALSE) #define POLY_ERASE (TRUE) #define POLY_CLICK (FALSE) #define POLY_DRAG (TRUE) #define POLY_STARTSHOW 0 #define POLY_DOSHOW 1 #define POLY_ENDSHOW 2 typedef struct tagPolyMeasureCursorInfo { IntPoint first_pt; IntPoint prev_prev_pt; IntPoint prev_pt; } PolyMeasureCursorInfo; static void DoPolyMeasureCursor(ppmci, start, num_pts, x, y, dx, dy, erase, drag) PolyMeasureCursorInfo *ppmci; int start, num_pts, x, y, dx, dy, erase, drag; { char buf[80], w_buf[80], h_buf[80], x_buf[80], y_buf[80], a_buf[80]; int angle2=0; if (erase == POLY_DRAW && drag == POLY_CLICK) { if (num_pts == 1) { ppmci->first_pt.x = ppmci->prev_pt.x = ppmci->prev_prev_pt.x = x; ppmci->first_pt.y = ppmci->prev_pt.y = ppmci->prev_prev_pt.y = y; } else { ppmci->prev_prev_pt.x = ppmci->prev_pt.x; ppmci->prev_prev_pt.y = ppmci->prev_pt.y; ppmci->prev_pt.x = x; ppmci->prev_pt.y = y; } } if (x == ppmci->prev_pt.x && y == ppmci->prev_pt.y) { strcpy(a_buf, "0"); } else if (num_pts == 1) { PointsToArc(ppmci->prev_pt.x, ppmci->prev_pt.y, ppmci->prev_pt.x+100, ppmci->prev_pt.y, x, y, ARC_CCW, FALSE, NULL, NULL, NULL, NULL, NULL, &angle2); if (angle2 > 180*64) angle2=(360*64)-angle2; FormatAngle(angle2, a_buf); } else { PointsToArc(ppmci->prev_pt.x, ppmci->prev_pt.y, ppmci->prev_prev_pt.x, ppmci->prev_prev_pt.y, x, y, ARC_CCW, FALSE, NULL, NULL, NULL, NULL, NULL, &angle2); if (angle2 > 180*64) angle2=(360*64)-angle2; FormatAngle(angle2, a_buf); } PixelToMeasurementUnit(w_buf, dx); PixelToMeasurementUnit(h_buf, dy); PixelToMeasurementUnit(x_buf, x); PixelToMeasurementUnit(y_buf, y); if (curChoice == FREEHAND) { sprintf(buf, "x=%s\ny=%s", x_buf, y_buf); } else { sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s\nangle=%s", w_buf, h_buf, x_buf, y_buf, a_buf); } x = OFFSET_X(x); y = OFFSET_Y(y); switch (start) { case POLY_STARTSHOW: StartShowMeasureCursor(x, y, buf, TRUE); break; case POLY_DOSHOW: ShowMeasureCursor(x, y, buf, TRUE); break; case POLY_ENDSHOW: EndShowMeasureCursor(x, y, buf, TRUE); break; } } void FreePointsForCont(pn_ltx, pn_lty, pn_rbx, pn_rby) int *pn_ltx, *pn_lty, *pn_rbx, *pn_rby; { int ltx=(*pn_ltx), lty=(*pn_lty), rbx=(*pn_rbx), rby=(*pn_rby); if (curSpline == LT_STRUCT_SPLINE) { CVListElem *elem=NULL; for (elem=ListFirst(&gStructSplineList); elem != NULL; elem=ListNext(&gStructSplineList, elem)) { IntPointTriplet *ipt=(IntPointTriplet*)(elem->obj); if (ipt != NULL) { if (ipt->hinge_pt.x < ltx) ltx = ipt->hinge_pt.x; if (ipt->hinge_pt.y < lty) lty = ipt->hinge_pt.y; if (ipt->hinge_pt.x > rbx) rbx = ipt->hinge_pt.x; if (ipt->hinge_pt.y > rby) rby = ipt->hinge_pt.y; if (ipt->earlier_valid) { if (ipt->earlier_smooth_pt.x < ltx) { ltx = ipt->earlier_smooth_pt.x; } if (ipt->earlier_smooth_pt.y < lty) { lty = ipt->earlier_smooth_pt.y; } if (ipt->earlier_smooth_pt.x > rbx) { rbx = ipt->earlier_smooth_pt.x; } if (ipt->earlier_smooth_pt.y > rby) { rby = ipt->hinge_pt.y; } } if (ipt->later_valid) { if (ipt->later_smooth_pt.x < ltx) ltx = ipt->later_smooth_pt.x; if (ipt->later_smooth_pt.y < lty) lty = ipt->later_smooth_pt.y; if (ipt->later_smooth_pt.x > rbx) rbx = ipt->later_smooth_pt.x; if (ipt->later_smooth_pt.y > rby) rby = ipt->later_smooth_pt.y; } free(ipt); } } ListUnlinkAll(&gStructSplineList); } else { struct PtRec *pt_ptr=NULL, *next_pt=NULL; for (pt_ptr=lastPtPtr; pt_ptr != NULL; pt_ptr=next_pt) { if (curSpline != LT_INTSPLINE) { if (pt_ptr->x < ltx) ltx = pt_ptr->x; if (pt_ptr->y < lty) lty = pt_ptr->y; if (pt_ptr->x > rbx) rbx = pt_ptr->x; if (pt_ptr->y > rby) rby = pt_ptr->y; } next_pt = pt_ptr->next; free(pt_ptr); } } *pn_ltx = ltx; *pn_lty = lty; *pn_rbx = rbx; *pn_rby = rby; } int SetFirstPoint(grid_x, grid_y, pipt_first) int grid_x, grid_y; IntPointTriplet *pipt_first; { if (curSpline == LT_STRUCT_SPLINE) { IntPointTriplet *ipt=(IntPointTriplet*)malloc(sizeof(IntPointTriplet)); if (ipt == NULL) return FailAllocMessage(); memset(ipt, 0, sizeof(IntPointTriplet)); if (pipt_first == NULL) { ipt->earlier_smooth_pt.x = ipt->hinge_pt.x = ipt->later_smooth_pt.x = grid_x; /* offset */ ipt->earlier_smooth_pt.y = ipt->hinge_pt.y = ipt->later_smooth_pt.y = grid_y; /* offset */ ipt->ratio = (double)1; } else { memcpy(ipt, pipt_first, sizeof(IntPointTriplet)); } ListAppend(&gStructSplineList, ipt); } else { numPtsInPoly = 1; lastPtPtr = (struct PtRec *)malloc(sizeof(struct PtRec)); if (lastPtPtr == NULL) return FailAllocMessage(); lastPtPtr->x = grid_x; /* offset */ lastPtPtr->y = grid_y; /* offset */ lastPtPtr->next = NULL; } return TRUE; } int AddPointForCont(grid_x, grid_y, pipt) int grid_x, grid_y; IntPointTriplet *pipt; { if (curSpline == LT_STRUCT_SPLINE) { IntPointTriplet *ipt=(IntPointTriplet*)malloc(sizeof(IntPointTriplet)); if (ipt == NULL) return FailAllocMessage(); memcpy(ipt, pipt, sizeof(IntPointTriplet)); ListAppend(&gStructSplineList, ipt); } else { struct PtRec *pt_ptr=NULL; pt_ptr = (struct PtRec *)malloc(sizeof(struct PtRec)); if (pt_ptr == NULL) FailAllocMessage(); pt_ptr->next = lastPtPtr; lastPtPtr = pt_ptr; pt_ptr->x = grid_x; pt_ptr->y = grid_y; } return TRUE; } void UpdateLastPointForCont(pipt) IntPointTriplet *pipt; { CVListElem *elem=ListLast(&gStructSplineList); IntPointTriplet *ipt=(IntPointTriplet*)(elem->obj); memcpy(ipt, pipt, sizeof(IntPointTriplet)); } void DrawAllStructSplinePointsForCont(num_pts) int num_pts; { int i=0; CVListElem *elem=ListFirst(&gStructSplineList); IntPointTriplet *pipt=(IntPointTriplet*)(elem->obj); for (i=0; i < num_pts-1; i++) { CVListElem *next_elem=ListNext(&gStructSplineList, elem); IntPointTriplet *pipt_next=(IntPointTriplet*)(next_elem->obj); int tmp_n=0; IntPoint tmp_vs[4]; tmp_vs[0].x = ABS_X(pipt->hinge_pt.x); tmp_vs[0].y = ABS_Y(pipt->hinge_pt.y); if (pipt->later_valid) { if (pipt_next->earlier_valid) { tmp_n = 4; tmp_vs[1].x = ABS_X(pipt->later_smooth_pt.x); tmp_vs[1].y = ABS_Y(pipt->later_smooth_pt.y); tmp_vs[2].x = ABS_X(pipt_next->earlier_smooth_pt.x); tmp_vs[2].y = ABS_Y(pipt_next->earlier_smooth_pt.y); } else { tmp_n = 3; tmp_vs[1].x = ABS_X(pipt->later_smooth_pt.x); tmp_vs[1].y = ABS_Y(pipt->later_smooth_pt.y); } } else { if (pipt_next->earlier_valid) { tmp_n = 3; tmp_vs[1].x = ABS_X(pipt_next->earlier_smooth_pt.x); tmp_vs[1].y = ABS_Y(pipt_next->earlier_smooth_pt.y); } else { tmp_n = 2; XDrawLine(mainDisplay, drawWindow, drawGC, pipt->hinge_pt.x, pipt->hinge_pt.y, pipt_next->hinge_pt.x, pipt_next->hinge_pt.y); } } tmp_vs[tmp_n-1].x = ABS_X(pipt_next->hinge_pt.x); tmp_vs[tmp_n-1].y = ABS_Y(pipt_next->hinge_pt.y); if (tmp_n > 2) { int sn=0; XPoint *sv=MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, tmp_n, tmp_vs); XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); free(sv); } } } void UpdatePrevToLastPointForCont(pipt_prev) IntPointTriplet *pipt_prev; { CVListElem *elem=ListLast(&gStructSplineList); IntPointTriplet *pipt=(IntPointTriplet*)(elem->obj); elem = ListPrev(&gStructSplineList, elem); pipt = (IntPointTriplet*)(elem->obj); memcpy(pipt_prev, pipt, sizeof(IntPointTriplet)); } static void ContinueForStructSplinePolyControlPoints(OrigX, OrigY, LastX, LastY, psv, psn, pipt_prev, pipt, pn_abort) int OrigX, OrigY, LastX, LastY, *psn, *pn_abort; XPoint **psv; IntPointTriplet *pipt_prev, *pipt; { int i=0, done=FALSE, grid_x=0, grid_y=0, end_x=0, end_y=0, n=2; int sn=(*psn), orig_sn=(*psn), num_pts=1, first_time=TRUE; IntPoint v[4]; XPoint *sv=NULL, *orig_sv=(*psv), dash_vs[2]; PolyMeasureCursorInfo pmci; XGCValues values; *pn_abort = FALSE; if (orig_sv != NULL) { sv = (XPoint*)malloc(orig_sn*sizeof(XPoint)); if (sv == NULL) FailAllocMessage(); memset(sv, 0, orig_sn*sizeof(XPoint)); for (i=0; i < orig_sn; i++) { sv[i].x = orig_sv[i].x; sv[i].y = orig_sv[i].y; } sn = orig_sn; } memset(pipt, 0, sizeof(IntPointTriplet)); pipt->earlier_valid = pipt->later_valid = FALSE; pipt->hinge_pt.x = pipt->earlier_smooth_pt.x = pipt->later_smooth_pt.x = LastX; pipt->hinge_pt.y = pipt->earlier_smooth_pt.y = pipt->later_smooth_pt.y = LastY; pipt->ratio = (double)1; XSetDashes(mainDisplay, revDefaultGC, 0, dashList[8], dashListLength[8]); grid_x = end_x = dash_vs[0].x = dash_vs[1].x = LastX; grid_y = end_y = dash_vs[0].y = dash_vs[1].y = LastY; v[0].x = ABS_X(OrigX); v[0].y = ABS_Y(OrigY); v[1].x = ABS_X(LastX); v[1].y = ABS_Y(LastY); n = 2; MARKHR(drawWindow, revDefaultGC, LastX, LastY); /* the previous curve has already been drawn */ /* draw the measure cursor */ DoPolyMeasureCursor(&pmci, POLY_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), 0, 0, POLY_ERASE, POLY_DRAG); while (!done) { XEvent input, ev; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); SetXorDrawGCForPoly(colorIndex, lineWidth); } else if (input.type == MotionNotify) { end_x = input.xmotion.x; end_y = input.xmotion.y; /* erase */ if (first_time || grid_x != LastX || grid_y != LastY) { if (sv != NULL) { MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); } first_time = FALSE; } else { if (orig_sv != NULL) { MyDrawLines(mainDisplay, drawWindow, drawGC, orig_sv, orig_sn); } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, LastX, LastY); } } DoPolyMeasureCursor(&pmci, POLY_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-LastX)), ABS_SIZE(abs(grid_y-LastY)), POLY_ERASE, POLY_DRAG); MARKHO(drawWindow, revDefaultGC, dash_vs[0].x, dash_vs[0].y); MARKHO(drawWindow, revDefaultGC, dash_vs[1].x, dash_vs[1].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, dash_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); /* draw */ GridXY(end_x, end_y, &grid_x, &grid_y); MarkRulers(grid_x, grid_y); if (grid_x != LastX || grid_y != LastY) { if (sv != NULL) { free(sv); sv = NULL; } if (pipt_prev->later_valid) { v[1].x = ABS_X(pipt_prev->later_smooth_pt.x); v[1].y = ABS_Y(pipt_prev->later_smooth_pt.y); n = 4; } else { n = 3; } v[n-2].x = ABS_X((LastX<<1)-grid_x); v[n-2].y = ABS_Y((LastY<<1)-grid_y); v[n-1].x = ABS_X(LastX); v[n-1].y = ABS_Y(LastY); sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, v); MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); } else { if (orig_sv != NULL) { MyDrawLines(mainDisplay, drawWindow, drawGC, orig_sv, orig_sn); } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, LastX, LastY); } } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; dash_vs[0].x = grid_x; dash_vs[0].y = grid_y; dash_vs[1].x = (LastX<<1)-grid_x; dash_vs[1].y = (LastY<<1)-grid_y; pipt->later_smooth_pt.x = dash_vs[0].x; pipt->later_smooth_pt.y = dash_vs[0].y; pipt->earlier_smooth_pt.x = dash_vs[1].x; pipt->earlier_smooth_pt.y = dash_vs[1].y; if (grid_x == LastX && grid_y == LastY) { pipt->earlier_valid = pipt->later_valid = FALSE; } else { pipt->earlier_valid = pipt->later_valid = TRUE; } MARKHO(drawWindow, revDefaultGC, dash_vs[0].x, dash_vs[0].y); MARKHO(drawWindow, revDefaultGC, dash_vs[1].x, dash_vs[1].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, dash_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); DoPolyMeasureCursor(&pmci, POLY_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-LastX)), ABS_SIZE(abs(grid_y-LastY)), POLY_DRAW, POLY_DRAG); } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { /* erase */ DoPolyMeasureCursor(&pmci, POLY_ENDSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-LastX)), ABS_SIZE(abs(grid_y-LastY)), POLY_ERASE, POLY_DRAG); MARKHO(drawWindow, revDefaultGC, dash_vs[0].x, dash_vs[0].y); MARKHO(drawWindow, revDefaultGC, dash_vs[1].x, dash_vs[1].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, dash_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); Msg(""); *pn_abort = TRUE; done = TRUE; } } else if (input.type == ButtonRelease) { /* erase */ DoPolyMeasureCursor(&pmci, POLY_ENDSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-LastX)), ABS_SIZE(abs(grid_y-LastY)), POLY_ERASE, POLY_DRAG); MARKHO(drawWindow, revDefaultGC, dash_vs[0].x, dash_vs[0].y); MARKHO(drawWindow, revDefaultGC, dash_vs[1].x, dash_vs[1].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, dash_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); GridXY(input.xbutton.x, input.xbutton.y, &grid_x, &grid_y); pipt->later_smooth_pt.x = grid_x; pipt->later_smooth_pt.y = grid_y; pipt->earlier_smooth_pt.x = (LastX<<1)-grid_x; pipt->earlier_smooth_pt.y = (LastY<<1)-grid_y; if (grid_x == LastX && grid_y == LastY) { pipt->earlier_valid = pipt->later_valid = FALSE; } else { pipt->earlier_valid = pipt->later_valid = TRUE; } done = TRUE; } } MARKHR(drawWindow, revDefaultGC, LastX, LastY); *psv = sv; *psn = sn; if (orig_sv != NULL) free(orig_sv); } static void ContinuePoly(OrigX, OrigY) int OrigX, OrigY; /* OrigX and OrigY are screen coordinates (scaled and translated). */ /* OrigX and OrigY are also on grid. */ { int i; XGCValues values; XEvent input, ev; XButtonEvent *button_ev; int abort=FALSE; int end_x, end_y, grid_x, grid_y, done=FALSE, num_pts=1; int last_x=OrigX, last_y=OrigY, n=2, sn=0, max_n=40, intn=0; int ltx=OrigX, lty=OrigY, rbx=OrigX, rby=OrigY; int one_line_status=FALSE, freehand_n=0, nothing_is_drawn=FALSE; char status_buf[MAX_STATUS_BTNS+1][MAXSTRING+1]; IntPointTriplet ipt_prev, ipt, first_ipt; XPoint *sv=NULL, *freehand_vs=NULL; IntPoint *v=NULL, *cntrlv=NULL; PolyMeasureCursorInfo pmci; memset(&ipt, 0, sizeof(IntPointTriplet)); memset(&ipt_prev, 0, sizeof(IntPointTriplet)); memset(&first_ipt, 0, sizeof(IntPointTriplet)); memset(&pmci, 0, sizeof(PolyMeasureCursorInfo)); SetXorDrawGCForPoly(colorIndex, lineWidth); grid_x = end_x = OrigX; grid_y = end_y = OrigY; if (curChoice == FREEHAND) { freehand_vs = (XPoint*)malloc((max_n+1)*sizeof(XPoint)); if (freehand_vs == NULL) FailAllocMessage(); freehand_vs[0].x = freehand_vs[1].x = OrigX; freehand_vs[0].y = freehand_vs[1].y = OrigY; freehand_n = 1; } else if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { v = (IntPoint*)malloc((max_n+1)*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); v[0].x = v[1].x = v[2].x = ABS_X(OrigX); v[0].y = v[1].y = v[2].y = ABS_Y(OrigY); switch (curSpline) { case LT_SPLINE: sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, v); break; case LT_INTSPLINE: sv = MakeIntSplinePolyVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n, v); for (i=0; i < sn; i++) { if (sv[i].x < ltx) ltx = sv[i].x; if (sv[i].y < lty) lty = sv[i].y; if (sv[i].x > rbx) rbx = sv[i].x; if (sv[i].y > rby) rby = sv[i].y; } break; } } else if (curSpline == LT_STRUCT_SPLINE) { ipt_prev.earlier_valid = ipt_prev.later_valid = FALSE; ipt_prev.earlier_smooth_pt.x = ipt_prev.hinge_pt.x = ipt_prev.later_smooth_pt.x = OrigX; ipt_prev.earlier_smooth_pt.y = ipt_prev.hinge_pt.y = ipt_prev.later_smooth_pt.y = OrigY; memcpy(&first_ipt, &ipt_prev, sizeof(IntPointTriplet)); v = (IntPoint*)malloc((max_n+1)*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); v[0].x = v[1].x = v[2].x = v[3].x = ABS_X(OrigX); v[0].y = v[1].y = v[2].y = v[3].y = ABS_Y(OrigY); sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n+1, v); } SaveStatusStrings(); if (curChoice == FREEHAND) { DoPolyMeasureCursor(&pmci, POLY_STARTSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), 0, 0, POLY_DRAW, POLY_CLICK); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } SetFirstPoint(OrigX, OrigY, NULL); } else { if (curSpline == LT_STRUCT_SPLINE) { SetMouseStatus(TgLoadCachedString(CSTID_ADD_A_STRUCT_VERTEX), TgLoadCachedString(CSTID_ADD_LAST_VERTEX), TgLoadCachedString(CSTID_ADD_LAST_VERTEX)); } else { SetMouseStatus(TgLoadCachedString(CSTID_ADD_A_VERTEX), TgLoadCachedString(CSTID_ADD_LAST_VERTEX), TgLoadCachedString(CSTID_ADD_LAST_VERTEX)); } DoPolyMeasureCursor(&pmci, POLY_STARTSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), 0, 0, POLY_DRAW, POLY_CLICK); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonPressMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } if (curSpline == LT_STRUCT_SPLINE) { DoPolyMeasureCursor(&pmci, POLY_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), 0, 0, POLY_ERASE, POLY_DRAG); ContinueForStructSplinePolyControlPoints(OrigX, OrigY, grid_x, grid_y, &sv, &sn, &ipt_prev, &ipt, &abort); memcpy(&first_ipt, &ipt, sizeof(IntPointTriplet)); memcpy(&ipt_prev, &ipt, sizeof(IntPointTriplet)); if (first_ipt.later_valid) { grid_x = OFFSET_X(first_ipt.later_smooth_pt.x); grid_y = OFFSET_Y(first_ipt.later_smooth_pt.y); } SetFirstPoint(OrigX, OrigY, &first_ipt); DoPolyMeasureCursor(&pmci, POLY_STARTSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLY_DRAW, POLY_CLICK); } else { SetFirstPoint(OrigX, OrigY, NULL); } } if (gstWiringInfo.num_ports_to_connect > 0 || drawPolyToConnectPins > 0) { *gstWiringInfo.last_port_name = '\0'; drawPolyHighlightedNode = NULL; SaveStatusStringsIntoBuf(status_buf, &one_line_status); values.line_width = 3; XChangeGC(mainDisplay, revGrayGC, GCLineWidth, &values); } while (!done) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); SetXorDrawGCForPoly(colorIndex, lineWidth); } else if ((input.type==MotionNotify && input.xany.window==drawWindow) || input.type == KeyPress || input.type == KeyRelease) { if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { /* erase */ DoPolyMeasureCursor(&pmci, POLY_ENDSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLY_ERASE, POLY_CLICK); Msg(""); abort = TRUE; done = TRUE; } } if (done) { break; } /* erase */ if (curChoice == FREEHAND) { if (freehand_n > 1) { MyDrawLines(mainDisplay, drawWindow, drawGC, freehand_vs, freehand_n); } } else { if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); } else if (curSpline == LT_STRUCT_SPLINE) { if (nothing_is_drawn) { /* then there is nothing to erase */ nothing_is_drawn = FALSE; } else { if (sv == NULL) { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); } else { MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); } } } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); } } DoPolyMeasureCursor(&pmci, POLY_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLY_ERASE, POLY_DRAG); if (input.type == KeyPress || input.type == KeyRelease) { end_x = grid_x; end_y = grid_y; } else { end_x = input.xmotion.x; end_y = input.xmotion.y; } if (shiftForDiagMouseMove && DiagEventCheck(&input)) { if (input.type == KeyRelease) { end_x = input.xkey.x; end_y = input.xkey.y; } else { DiagGridXY(OrigX, OrigY, &end_x, &end_y); } } /* draw */ if (curChoice == FREEHAND) { grid_x = end_x; grid_y = end_y; MarkRulers(grid_x, grid_y); if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { if (sv != NULL) { free(sv); sv = NULL; } v[n-1].x = v[n].x = ABS_X(grid_x); v[n-1].y = v[n].y = ABS_Y(grid_y); switch (curSpline) { case LT_SPLINE: sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, v); break; case LT_INTSPLINE: if (cntrlv != NULL) free(cntrlv); sv = MakeIntSplinePolyVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n, v); for (i=0; i < sn; i++) { if (sv[i].x < ltx) ltx = sv[i].x; if (sv[i].y < lty) lty = sv[i].y; if (sv[i].x > rbx) rbx = sv[i].x; if (sv[i].y > rby) rby = sv[i].y; } break; } MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); if (sv != NULL) { free(sv); sv = NULL; } } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; if (grid_x != last_x || grid_y != last_y) { num_pts++; AddPointForCont(grid_x, grid_y, &ipt); last_x = grid_x; last_y = grid_y; if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { if (n >= max_n-2) { max_n += 40; v = (IntPoint*)realloc(v, sizeof(IntPoint)*max_n+1); if (v == NULL) FailAllocMessage(); } MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); if (sv != NULL) { free(sv); sv = NULL; } v[n].x = v[n+1].x = ABS_X(grid_x); v[n].y = v[n+1].y = ABS_Y(grid_y); n++; switch (curSpline) { case LT_SPLINE: sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, v); break; case LT_INTSPLINE: if (cntrlv != NULL) free(cntrlv); sv = MakeIntSplinePolyVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n, v); for (i=0; i < sn; i++) { if (sv[i].x < ltx) ltx = sv[i].x; if (sv[i].y < lty) lty = sv[i].y; if (sv[i].x > rbx) rbx = sv[i].x; if (sv[i].y > rby) rby = sv[i].y; } break; } MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); } else { if (freehand_n >= max_n-2) { max_n += 40; freehand_vs = (XPoint*)realloc(freehand_vs, sizeof(XPoint)*max_n+1); if (freehand_vs == NULL) FailAllocMessage(); } freehand_vs[freehand_n].x = grid_x; freehand_vs[freehand_n].y = grid_y; freehand_n++; } } OrigX = grid_x; OrigY = grid_y; } else { if (gstWiringInfo.num_ports_to_connect > 0) { int need_to_highlight=FALSE, something_changed=FALSE; struct ObjRec *owner_obj=NULL, *obj_ptr, *obj_under_cursor=NULL; char port_name[MAXSTRING]; obj_ptr = FindAnObj(end_x, end_y, &owner_obj, &obj_under_cursor, port_name); if (drawPolyHighlightedNode != NULL) { if (obj_under_cursor != drawPolyHighlightedNode) { /* un-highlight */ SelBox(drawWindow, revGrayGC, OFFSET_X(drawPolyHighlightedNode->bbox.ltx)-2, OFFSET_Y(drawPolyHighlightedNode->bbox.lty)-2, OFFSET_X(drawPolyHighlightedNode->bbox.rbx)+2, OFFSET_Y(drawPolyHighlightedNode->bbox.rby)+2); if (obj_under_cursor != NULL && ObjIsAPort(obj_under_cursor)) { drawPolyHighlightedNode = obj_under_cursor; SetWiringNodeInfo(obj_under_cursor, owner_obj, port_name, FALSE); } else { drawPolyHighlightedNode = NULL; SetWiringNodeInfo(NULL, NULL, NULL, FALSE); } if (drawPolyHighlightedNode != NULL) { need_to_highlight = TRUE; } something_changed = TRUE; } } else { if (obj_under_cursor != NULL) { if (ObjIsAPort(obj_under_cursor)) { drawPolyHighlightedNode = obj_under_cursor; SetWiringNodeInfo(obj_under_cursor, owner_obj, port_name, FALSE); } else { drawPolyHighlightedNode = NULL; SetWiringNodeInfo(NULL, NULL, NULL, FALSE); } if (drawPolyHighlightedNode != NULL) { need_to_highlight = TRUE; something_changed = TRUE; } } } if (need_to_highlight) { SelBox(drawWindow, revGrayGC, OFFSET_X(drawPolyHighlightedNode->bbox.ltx)-2, OFFSET_Y(drawPolyHighlightedNode->bbox.lty)-2, OFFSET_X(drawPolyHighlightedNode->bbox.rbx)+2, OFFSET_Y(drawPolyHighlightedNode->bbox.rby)+2); } if (something_changed) { if (*gstWiringInfo.last_port_name != '\0') { sprintf(gszMsgBox, TgLoadCachedString(CSTID_END_A_WIRE_AT_NAMED_PORT), gstWiringInfo.last_port_name); SetStringStatus(gszMsgBox); } else { RestoreStatusStringsFromBuf(status_buf, one_line_status); SetMouseStatus(TgLoadCachedString(CSTID_ADD_A_VERTEX), TgLoadCachedString(CSTID_ADD_LAST_VERTEX), TgLoadCachedString(CSTID_ADD_LAST_VERTEX)); } } if (drawPolyHighlightedNode != NULL) { grid_x = OFFSET_X((drawPolyHighlightedNode->obbox.ltx + drawPolyHighlightedNode->obbox.rbx)>>1); grid_y = OFFSET_Y((drawPolyHighlightedNode->obbox.lty + drawPolyHighlightedNode->obbox.rby)>>1); } else { GridXY(end_x, end_y, &grid_x, &grid_y); } #ifdef _NOT_DEFINED /* * drawPolyToConnectPins is only set to > 0 in "pin.c" * what's in "pin.c" is not used at this time */ } else if (drawPolyToConnectPins > 0) { HandlePinHighlights(end_x, end_y); if (drawPolyHighlightedNode != NULL) { grid_x = OFFSET_X((drawPolyHighlightedNode->obbox.ltx + drawPolyHighlightedNode->obbox.rbx)>>1); grid_y = OFFSET_Y((drawPolyHighlightedNode->obbox.lty + drawPolyHighlightedNode->obbox.rby)>>1); } else { GridXY(end_x, end_y, &grid_x, &grid_y); } #endif /* _NOT_DEFINED */ } else { GridXY(end_x, end_y, &grid_x, &grid_y); } MarkRulers(grid_x, grid_y); if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { if (sv != NULL) { free(sv); sv = NULL; } v[n-1].x = v[n].x = ABS_X(grid_x); v[n-1].y = v[n].y = ABS_Y(grid_y); switch (curSpline) { case LT_SPLINE: sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, v); break; case LT_INTSPLINE: free(cntrlv); sv = MakeIntSplinePolyVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n, v); for (i=0; i < sn; i++) { if (sv[i].x < ltx) ltx = sv[i].x; if (sv[i].y < lty) lty = sv[i].y; if (sv[i].x > rbx) rbx = sv[i].x; if (sv[i].y > rby) rby = sv[i].y; } break; } MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); } else if (curSpline == LT_STRUCT_SPLINE) { if (sv != NULL) { free(sv); sv = NULL; } if (ipt_prev.later_valid) { v[0].x = ABS_X(OrigX); v[0].y = ABS_Y(OrigY); v[1].x = ABS_X(ipt_prev.later_smooth_pt.x); v[1].y = ABS_Y(ipt_prev.later_smooth_pt.y); v[2].x = v[3].x = ABS_X(grid_x); v[2].y = v[3].y = ABS_Y(grid_y); n = 3; sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, v); MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); if (sv != NULL) { free(sv); sv = NULL; } } } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); } } DoPolyMeasureCursor(&pmci, POLY_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLY_DRAW, POLY_DRAG); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } else if (input.type == ButtonPress && curChoice != FREEHAND) { /* erase */ DoPolyMeasureCursor(&pmci, POLY_ENDSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLY_ERASE, POLY_DRAG); button_ev = &(input.xbutton); end_x = button_ev->x; end_y = button_ev->y; if (shiftForDiagMouseMove && DiagEventCheck(&input)) { DiagGridXY(OrigX, OrigY, &end_x, &end_y); } if (drawPolyHighlightedNode != NULL) { grid_x = OFFSET_X((drawPolyHighlightedNode->obbox.ltx + drawPolyHighlightedNode->obbox.rbx)>>1); grid_y = OFFSET_Y((drawPolyHighlightedNode->obbox.lty + drawPolyHighlightedNode->obbox.rby)>>1); } else { GridXY(end_x, end_y, &grid_x, &grid_y); } if (grid_x == last_x && grid_y == last_y) { if (curSpline == LT_STRUCT_SPLINE) { if (num_pts == 1) { abort = TRUE; } else { /* need to overwrite the previous point */ /* erase */ if (sv != NULL) { MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); free(sv); sv = NULL; } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); } if (ipt_prev.later_valid) { /* erase whole curve */ DrawAllStructSplinePointsForCont(num_pts); ipt_prev.earlier_valid = ipt_prev.later_valid = FALSE; ipt_prev.earlier_smooth_pt.x = ipt_prev.later_smooth_pt.x = ipt_prev.hinge_pt.x; ipt_prev.earlier_smooth_pt.y = ipt_prev.later_smooth_pt.y = ipt_prev.hinge_pt.y; UpdateLastPointForCont(&ipt_prev); /* draw whole curve */ DrawAllStructSplinePointsForCont(num_pts); } UpdatePrevToLastPointForCont(&ipt_prev); ipt.earlier_valid = ipt.later_valid = FALSE; ipt.earlier_smooth_pt.x = ipt.later_smooth_pt.x = ipt.hinge_pt.x = grid_x; ipt.earlier_smooth_pt.y = ipt.later_smooth_pt.y = ipt.hinge_pt.y = grid_y; OrigX = ipt_prev.hinge_pt.x; OrigY = ipt_prev.hinge_pt.y; if (ipt_prev.later_valid) { v[0].x = ABS_X(OrigX); v[0].y = ABS_Y(OrigY); v[1].x = ABS_X(ipt_prev.later_smooth_pt.x); v[1].y = ABS_Y(ipt_prev.later_smooth_pt.y); v[2].x = v[3].x = ABS_X(grid_x); v[2].y = v[3].y = ABS_Y(grid_y); n = 3; sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, v); } } } } else { num_pts++; AddPointForCont(grid_x, grid_y, &ipt); last_x = grid_x; last_y = grid_y; if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { if (n >= max_n-2) { max_n += 40; v = (IntPoint*)realloc(v, sizeof(IntPoint)*max_n+1); if (v == NULL) FailAllocMessage(); } /* erase */ MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); if (sv != NULL) { free(sv); sv = NULL; } v[n].x = v[n+1].x = ABS_X(grid_x); v[n].y = v[n+1].y = ABS_Y(grid_y); n++; switch (curSpline) { case LT_SPLINE: sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, v); break; case LT_INTSPLINE: if (cntrlv != NULL) free(cntrlv); sv = MakeIntSplinePolyVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n, v); for (i=0; i < sn; i++) { if (sv[i].x < ltx) ltx = sv[i].x; if (sv[i].y < lty) lty = sv[i].y; if (sv[i].x > rbx) rbx = sv[i].x; if (sv[i].y > rby) rby = sv[i].y; } break; } /* draw */ MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); } else if (curSpline == LT_STRUCT_SPLINE) { /* erase */ if (sv != NULL) { MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); free(sv); sv = NULL; } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); } /* draw */ if (ipt_prev.later_valid) { v[0].x = ABS_X(OrigX); v[0].y = ABS_Y(OrigY); v[1].x = ABS_X(ipt_prev.later_smooth_pt.x); v[1].y = ABS_Y(ipt_prev.later_smooth_pt.y); v[2].x = v[3].x = ABS_X(grid_x); v[2].y = v[3].y = ABS_Y(grid_y); n = 3; sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, v); MyDrawLines(mainDisplay, drawWindow, drawGC, sv, sn); } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); if (sv != NULL) { free(sv); sv = NULL; } } } } switch (button_ev->button) { case Button1: if ((drawPolyToConnectPins > 0 && drawPolyHighlightedNode != NULL) || (gstWiringInfo.num_ports_to_connect > 0 && drawPolyHighlightedNode != NULL)) { gpEndPin = drawPolyHighlightedNode; done = TRUE; } else { if (curSpline == LT_STRUCT_SPLINE) { ContinueForStructSplinePolyControlPoints(OrigX, OrigY, grid_x, grid_y, &sv, &sn, &ipt_prev, &ipt, &abort); UpdateLastPointForCont(&ipt); /* at this point, the curve has been drawn */ if (sv != NULL) { free(sv); sv = NULL; } nothing_is_drawn = TRUE; if (!abort) { CVListElem *elem=ListLast(&gStructSplineList); if (elem != NULL) { IntPointTriplet *pipt=(IntPointTriplet*)(elem->obj); memcpy(pipt, &ipt, sizeof(IntPointTriplet)); } memcpy(&ipt_prev, &ipt, sizeof(IntPointTriplet)); OrigX = ipt.hinge_pt.x; OrigY = ipt.hinge_pt.y; if (ipt.later_valid) { grid_x = ipt.later_smooth_pt.x; grid_y = ipt.later_smooth_pt.y; } else { grid_x = ipt.hinge_pt.x; grid_y = ipt.hinge_pt.y; } DoPolyMeasureCursor(&pmci, POLY_STARTSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLY_DRAW, POLY_CLICK); } } else { OrigX = grid_x; OrigY = grid_y; /* draw */ DoPolyMeasureCursor(&pmci, POLY_STARTSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), 0, 0, POLY_DRAW, POLY_CLICK); XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); } } break; case Button2: case Button3: #ifdef _NOT_DEFINED /* * drawPolyToConnectPins is only set to > 0 in "pin.c" * what's in "pin.c" is not used at this time */ if (drawPolyToConnectPins > 0) { if (drawPolyHighlightedNode == NULL) { abort = TRUE; } else { gpEndPin = drawPolyHighlightedNode; } } #endif /* _NOT_DEFINED */ if (curSpline == LT_STRUCT_SPLINE) { memset(&ipt, 0, sizeof(IntPointTriplet)); ipt.earlier_valid = ipt.later_valid = FALSE; ipt.hinge_pt.x = ipt.earlier_smooth_pt.x = ipt.later_smooth_pt.x = grid_x; ipt.hinge_pt.y = ipt.earlier_smooth_pt.y = ipt.later_smooth_pt.y = grid_y; ipt.ratio = (double)1; ContinueForStructSplinePolyControlPoints(OrigX, OrigY, grid_x, grid_y, &sv, &sn, &ipt_prev, &ipt, &abort); UpdateLastPointForCont(&ipt); } done = TRUE; break; } } else if (input.type == ButtonRelease && curChoice == FREEHAND) { DoPolyMeasureCursor(&pmci, POLY_ENDSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLY_ERASE, POLY_CLICK); button_ev = &(input.xbutton); if (grid_x != last_x || grid_y != last_y) { num_pts++; AddPointForCont(grid_x, grid_y, &ipt); last_x = grid_x; last_y = grid_y; } done = TRUE; } } if (drawPolyHighlightedNode != NULL) { if (gstWiringInfo.num_ports_to_connect > 0) { SelBox(drawWindow, revGrayGC, OFFSET_X(drawPolyHighlightedNode->bbox.ltx)-2, OFFSET_Y(drawPolyHighlightedNode->bbox.lty)-2, OFFSET_X(drawPolyHighlightedNode->bbox.rbx)+2, OFFSET_Y(drawPolyHighlightedNode->bbox.rby)+2); #ifdef _NOT_DEFINED /* * drawPolyToConnectPins is only set to > 0 in "pin.c" * what's in "pin.c" is not used at this time */ } else if (drawPolyToConnectPins > 0) { HighLightAPin(FALSE); #endif /* _NOT_DEFINED */ } drawPolyHighlightedNode = NULL; } else if (!abort && gstWiringInfo.num_ports_to_connect > 0) { XBell(mainDisplay, 0); Msg(""); Msg(TgLoadString(STID_TRY_AGAIN_AND_END_IN_A_PORT)); abort = TRUE; } XUngrabPointer(mainDisplay, CurrentTime); if (gstWiringInfo.num_ports_to_connect > 0 || drawPolyToConnectPins > 0) { values.line_width = 1; XChangeGC(mainDisplay, revGrayGC, GCLineWidth, &values); RestoreStatusStringsFromBuf(status_buf, one_line_status); } RestoreStatusStrings(); SetMouseStatus(NULL, NULL, NULL); if (!abort) Msg(""); values.join_style = JoinMiter; XChangeGC(mainDisplay, drawGC, GCJoinStyle, &values); if (v != NULL) free(v); if (sv != NULL) free(sv); if (cntrlv != NULL) free(cntrlv); if (curChoice == FREEHAND && freehand_vs != NULL) { free(freehand_vs); } if (!abort && num_pts > 1) { CreatePolyObj(num_pts, CREATE_RELATIVE); RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); polyDrawn = TRUE; SetFileModified(TRUE); } else { if (curSpline != LT_INTSPLINE) { ltx = rbx = grid_x; lty = rby = grid_y; } FreePointsForCont(<x, <y, &rbx, &rby); RedrawAnArea(botObj, ABS_X(ltx)-GRID_ABS_SIZE(1), ABS_Y(lty)-GRID_ABS_SIZE(1), ABS_X(rbx)+GRID_ABS_SIZE(1), ABS_Y(rby)+GRID_ABS_SIZE(1)); numPtsInPoly = 0; lastPtPtr = NULL; polyDrawn = FALSE; } if (gstWiringInfo.num_ports_to_connect == 2 && !polyDrawn) { gstWiringInfo.num_ports_to_connect = (-1); } #ifdef _NOT_DEFINED /* * drawPolyToConnectPins is only set to > 0 in "pin.c" * what's in "pin.c" is not used at this time */ if (drawPolyToConnectPins == 2 && !polyDrawn) { drawPolyToConnectPins = (-1); } #endif /* _NOT_DEFINED */ } void DrawPoly(input) XEvent *input; { int mouse_x, mouse_y, grid_x, grid_y; XButtonEvent *button_ev; if (input->type == KeyPress && curChoice == DRAWPOLY && gstWiringInfo.num_ports_to_connect > 0) { if (KeyPressEventIsEscape(&input->xkey)) { HandlePressForPortInDrawWindow(TRUE); } return; } if (input->type != ButtonPress) return; button_ev = &(input->xbutton); if (button_ev->button == Button1) { int saved_cur_spline=curSpline; mouse_x = input->xbutton.x; mouse_y = input->xbutton.y; if (gstWiringInfo.num_ports_to_connect > 0 || drawPolyToConnectPins > 0 || curChoice == FREEHAND) { if (drawPolyHighlightedNode != NULL) { grid_x = OFFSET_X((drawPolyHighlightedNode->obbox.ltx + drawPolyHighlightedNode->obbox.rbx)>>1); grid_y = OFFSET_Y((drawPolyHighlightedNode->obbox.lty + drawPolyHighlightedNode->obbox.rby)>>1); if (gstWiringInfo.num_ports_to_connect > 0 || curChoice == FREEHAND) { HandlePressForPortInDrawWindow(FALSE); #ifdef _NOT_DEFINED /* * drawPolyToConnectPins is only set to > 0 in "pin.c" * what's in "pin.c" is not used at this time */ } else if (drawPolyToConnectPins > 0) { HighLightAPin(TRUE); #endif /* _NOT_DEFINED */ } drawPolyHighlightedNode = NULL; } else if (gstWiringInfo.num_ports_to_connect > 0 || drawPolyToConnectPins > 0) { XBell(mainDisplay, 0); SetStringStatus(TgLoadString(STID_TRY_AGAIN_AND_CLICK_IN_A_PORT)); return; } else { grid_x = mouse_x; grid_y = mouse_y; } } else { GridXY(mouse_x, mouse_y, &grid_x, &grid_y); } if (curChoice == FREEHAND) curSpline = LT_STRAIGHT; ContinuePoly(grid_x, grid_y); if (curChoice == FREEHAND) curSpline = saved_cur_spline; } } void SetWiringNodeInfo(port_obj, port_owner_obj, port_name, first) struct ObjRec *port_obj, *port_owner_obj; char *port_name; int first; { if (first) { gstWiringInfo.first_port_obj = port_obj; gstWiringInfo.first_port_owner_obj = port_owner_obj; if (port_name == NULL) { *gstWiringInfo.first_port_name = '\0'; } else { UtilStrCpyN(gstWiringInfo.first_port_name, sizeof(gstWiringInfo.first_port_name), port_name); } } else { gstWiringInfo.last_port_obj = port_obj; gstWiringInfo.last_port_owner_obj = port_owner_obj; if (port_name == NULL) { *gstWiringInfo.last_port_name = '\0'; } else { UtilStrCpyN(gstWiringInfo.last_port_name, sizeof(gstWiringInfo.last_port_name), port_name); } } } void ResetWiringNodeInfo() { memset(&gstWiringInfo, 0, sizeof(WiringInfo)); } void InputPolyPts() { char inbuf[MAXSTRING+1]; int more_poly=FALSE, num_polys=0; int started_composite=FALSE; struct ObjRec *saved_top_obj=topObj; MakeQuiescent(); XSync(mainDisplay, False); do { int len, ok=TRUE, num_pts=0, eof=TRUE; struct PtRec *pt_ptr; more_poly = FALSE; numPtsInPoly = 0; lastPtPtr = NULL; printf("%s\n", TgLoadString(STID_INPUT_PAIRS_OF_POINTS_POLY)); printf("> "); fflush(stdout); while (ok && fgets(inbuf, MAXSTRING, stdin) != NULL) { if (strcmp(inbuf, ";\n") == 0) { more_poly = TRUE; eof = FALSE; break; } if (strcmp(inbuf, ".\n") == 0) { eof = FALSE; break; } len = strlen(inbuf); if (len > 0) { char *c_ptr=strtok(inbuf," ,\t\n"), *c_ptr1=NULL; if (c_ptr != NULL) { c_ptr1 = strtok(NULL," ,\t\n"); } if (c_ptr1 != NULL) { while (strchr(" ,\t\n", *c_ptr1)) c_ptr1++; } while (c_ptr != NULL && c_ptr1 != NULL) { num_pts++; pt_ptr = (struct PtRec *)malloc(sizeof(struct PtRec)); if (pt_ptr == NULL) FailAllocMessage(); pt_ptr->next = lastPtPtr; if (sscanf(c_ptr, "%d", &pt_ptr->x) != 1 || sscanf(c_ptr1, "%d", &pt_ptr->y) != 1) { ok = FALSE; MsgBox(TgLoadString(STID_READ_INT_ERROR_FOR_POLY_PTS), TOOL_NAME, INFO_MB); XSync(mainDisplay, False); break; } lastPtPtr = pt_ptr; c_ptr = strtok(NULL," ,\t\n"); if (c_ptr != NULL) { c_ptr1 = strtok(NULL," ,\t\n"); } if (c_ptr1 != NULL) { while (strchr(" ,\t\n", *c_ptr1)) c_ptr1++; } } if (c_ptr != NULL) { ok = FALSE; MsgBox(TgLoadString(STID_READ_INT_ERROR_FOR_POLY_PTS), TOOL_NAME, INFO_MB); XSync(mainDisplay, False); } } printf("> "); fflush(stdout); } printf("\n"); if (eof) rewind(stdin); if (ok && num_pts > 1) { num_polys++; CreatePolyObj(num_pts, CREATE_ABSOLUTE); if (more_poly || num_polys > 1) { if (num_polys <= 1) { StartCompositeCmd(); started_composite = TRUE; } RecordNewObjCmd(); numRedrawBBox = 0; topObj->tmp_parent = NULL; DrawObj(drawWindow, topObj); } else { RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); SelectTopObj(); SetFileModified(TRUE); justDupped = FALSE; } } if (ok && num_pts <= 1) { MsgBox(TgLoadString(STID_TOO_FEW_POINTERS_ENTERED), TOOL_NAME, INFO_MB); XSync(mainDisplay, False); } for ( ; lastPtPtr != NULL; lastPtPtr=pt_ptr) { pt_ptr = lastPtPtr->next; free(pt_ptr); } } while (more_poly); if (num_polys > 1 || started_composite) { SelectAndHighLightNewObjects(saved_top_obj); GroupSelObj(TRUE, TRUE, TRUE); EndCompositeCmd(); SetFileModified(TRUE); justDupped = FALSE; } } /* --------------------- JoinPoly() --------------------- */ static void FinishJoinPoly(obj_ptr1, obj_ptr2, poly_ptr1, vs, smooth, num_pts) struct ObjRec *obj_ptr1, *obj_ptr2; struct PolyRec *poly_ptr1; IntPoint *vs; char *smooth; int num_pts; { struct SelRec *sel_ptr, *top_sel=NULL, *bot_sel=NULL; int x0=0, y0=0, index0=0; if (curChoice == VERTEXMODE) { if (topVSel->obj == obj_ptr1) { index0 = topVSel->v_index[0]; x0 = topVSel->x[0]; y0 = topVSel->y[0]; } else { index0 = botVSel->v_index[0]; x0 = botVSel->x[0]; y0 = botVSel->y[0]; } } RemoveAllSel(); if (obj_ptr2->fattr != NULL) { int count=0; struct SelRec *next_sel; PrepareToReplaceAnObj(obj_ptr2); DetachAllObjAttrs(obj_ptr2, &top_sel, &bot_sel); /* obj_ptr2 is pointed to by bot_sel now */ AdjObjBBox(obj_ptr2); for (sel_ptr=top_sel; sel_ptr != NULL; sel_ptr=sel_ptr->next) count++; RecordCmd(CMD_ONE_TO_MANY, NULL, top_sel, bot_sel, count); sel_ptr = bot_sel; bot_sel = bot_sel->prev; bot_sel->next = NULL; free(sel_ptr); if (curChoice == VERTEXMODE) { for (sel_ptr=top_sel; sel_ptr != NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } top_sel = bot_sel = NULL; } } sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (sel_ptr == NULL) FailAllocMessage(); sel_ptr->next = sel_ptr->prev = NULL; sel_ptr->obj = obj_ptr2; PrepareToRecord(CMD_DELETE, sel_ptr, sel_ptr, 1); UnlinkObj(obj_ptr2); FreeObj(obj_ptr2); RecordCmd(CMD_DELETE, NULL, NULL, NULL, 0); free(sel_ptr); PrepareToReplaceAnObj(obj_ptr1); if (poly_ptr1->vlist != NULL) free(poly_ptr1->vlist); if (poly_ptr1->svlist != NULL) free(poly_ptr1->svlist); if (poly_ptr1->asvlist != NULL) free(poly_ptr1->asvlist); if (poly_ptr1->smooth != NULL) free(poly_ptr1->smooth); if (poly_ptr1->intvlist != NULL) free(poly_ptr1->intvlist); if (poly_ptr1->rotated_vlist != NULL) free(poly_ptr1->rotated_vlist); if (poly_ptr1->rotated_asvlist != NULL) free(poly_ptr1->rotated_asvlist); poly_ptr1->smooth = smooth; poly_ptr1->vlist = poly_ptr1->intvlist = NULL; poly_ptr1->n = poly_ptr1->intn = 0; poly_ptr1->svlist = poly_ptr1->asvlist = poly_ptr1->rotated_vlist = poly_ptr1->rotated_asvlist = NULL; poly_ptr1->sn = poly_ptr1->asn = poly_ptr1->rotated_n = poly_ptr1->rotated_asn = 0; if (obj_ptr1->ctm != NULL) free(obj_ptr1->ctm); obj_ptr1->ctm = NULL; poly_ptr1->vlist = vs; poly_ptr1->n = num_pts; AdjObjSplineVs(obj_ptr1); if (poly_ptr1->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr1, poly_ptr1->n, poly_ptr1->vlist); } else { UpdPolyBBox(obj_ptr1, poly_ptr1->intn, poly_ptr1->intvlist); } AdjObjBBox(obj_ptr1); RecordReplaceAnObj(obj_ptr1); topSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel == NULL) FailAllocMessage(); topSel->obj = obj_ptr1; topSel->prev = NULL; topSel->next = top_sel; if (top_sel != NULL) { top_sel->prev = topSel; botSel = bot_sel; } else { botSel = topSel; } if (curChoice == VERTEXMODE) { topVSel = botVSel = (struct VSelRec *)malloc(sizeof(struct VSelRec)); if (topVSel == NULL) FailAllocMessage(); memset(topVSel, 0, sizeof(struct VSelRec)); topVSel->obj = obj_ptr1; topVSel->max_v = 10; topVSel->v_index = (int*)malloc(10*sizeof(int)); topVSel->x = (int*)malloc(10*sizeof(int)); topVSel->y = (int*)malloc(10*sizeof(int)); if (topVSel->v_index==NULL || topVSel->x==NULL || topVSel->y==NULL) { FailAllocMessage(); } topVSel->v_index[0] = index0; topVSel->x[0] = x0; topVSel->y[0] = y0; topVSel->n = 1; topVSel->next = topVSel->prev = NULL; } } typedef struct tagJoinStructSplineInfo { StretchStructuredSplineInfo sssi1, sssi2; } JoinStructSplineInfo; static void DoJoinPoly(obj_ptr1, obj_ptr2, poly_ptr1, poly_ptr2, min_index, coincide, pjssi) struct ObjRec *obj_ptr1, *obj_ptr2; struct PolyRec *poly_ptr1, *poly_ptr2; int min_index, coincide; JoinStructSplineInfo *pjssi; /* * min_index==0: join point 0 of poly_ptr1 and point 0 of poly_ptr2 * min_index==1: join point 0 of poly_ptr1 and point n-1 of poly_ptr2 * min_index==2: join point n-1 of poly_ptr1 and point 0 of poly_ptr2 * min_index==3: join point n-1 of poly_ptr1 and point n-1 of poly_ptr2 */ { int i, n, n1=poly_ptr1->n, n2=poly_ptr2->n, num_pts, ltx, lty, rbx, rby; int min_val=0, max_val=0, inc=0, curved=poly_ptr1->curved; IntPoint *vlist1=poly_ptr1->vlist, *vlist2=poly_ptr2->vlist; IntPoint *new_vs=NULL, tmp_p; char *new_smooth=NULL; if (pjssi != NULL) { if (coincide) { num_pts = n1+n2-1; } else { num_pts = n1+n2+2; } } else { num_pts = n1+n2; if (coincide) { num_pts = n1+n2-1; } else { num_pts = n1+n2; } } new_vs = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (new_vs == NULL) FailAllocMessage(); if (curved == LT_STRUCT_SPLINE) { IntPoint tmp_p1, tmp_p2; int fix_v1_of_vlist2=FALSE, fix_vn2_minus_2_of_vlist2=FALSE; switch (min_index) { case 0: min_val=n1-1; max_val=0; inc=(-1); break; case 1: min_val=n1-1; max_val=0; inc=(-1); break; case 2: min_val=0; max_val=n1; inc=1; break; case 3: min_val=0; max_val=n1; inc=1; break; } n = 0; i = min_val; while (inc > 0 ? i < max_val : i >= max_val) { if (obj_ptr1->ctm == NULL) { memcpy(&new_vs[n], &vlist1[i], sizeof(IntPoint)); } else { TransformObjectV(obj_ptr1, &vlist1[i], &tmp_p); memcpy(&new_vs[n], &tmp_p, sizeof(IntPoint)); } n++; i += inc; } if (coincide) { int has_smooth_1=FALSE, has_smooth_2=FALSE; switch (min_index) { case 0: /* join pt 0 of poly1 and pt 0 of poly2 */ has_smooth_1 = pjssi->sssi1.ipt.later_valid; has_smooth_2 = pjssi->sssi2.ipt.later_valid; break; case 1: /* join pt 0 of poly1 and pt n-1 of poly2 */ has_smooth_1 = pjssi->sssi1.ipt.later_valid; has_smooth_2 = pjssi->sssi2.ipt.earlier_valid; break; case 2: /* join pt n-1 of poly1 and pt 0 of poly2 */ has_smooth_1 = pjssi->sssi1.ipt.earlier_valid; has_smooth_2 = pjssi->sssi2.ipt.later_valid; break; case 3: /* join pt n-1 of poly1 and pt n-1 of poly2 */ has_smooth_1 = pjssi->sssi1.ipt.earlier_valid; has_smooth_2 = pjssi->sssi2.ipt.earlier_valid; break; } if (has_smooth_1) { /* first point has a corresponding smooth point */ if (has_smooth_2) { /* last point has a corresponding smooth point */ switch (min_index) { case 0: /* join pt 0 of poly1 and pt 0 of poly2 */ case 2: /* join pt n-1 of poly1 and pt 0 of poly2 */ if (obj_ptr2->ctm == NULL) { new_vs[n-2].x = (vlist2[0].x<<1) - vlist2[1].x; new_vs[n-2].y = (vlist2[0].y<<1) - vlist2[1].y; } else { TransformObjectV(obj_ptr2, &vlist2[0], &tmp_p1); TransformObjectV(obj_ptr2, &vlist2[1], &tmp_p2); new_vs[n-2].x = (tmp_p1.x<<1) - tmp_p2.x; new_vs[n-2].y = (tmp_p1.y<<1) - tmp_p2.y; } break; case 1: /* join pt 0 of poly1 and pt n-1 of poly2 */ case 3: /* join pt n-1 of poly1 and pt n-1 of poly2 */ if (obj_ptr2->ctm == NULL) { new_vs[n-2].x = (vlist2[n2-1].x<<1) - vlist2[n2-2].x; new_vs[n-2].y = (vlist2[n2-1].y<<1) - vlist2[n2-2].y; } else { TransformObjectV(obj_ptr2, &vlist2[n2-1], &tmp_p1); TransformObjectV(obj_ptr2, &vlist2[n2-2], &tmp_p2); new_vs[n-2].x = (tmp_p1.x<<1) - tmp_p2.x; new_vs[n-2].y = (tmp_p1.y<<1) - tmp_p2.y; } break; } } else { /* last point does not have a corresponding smooth point */ new_vs[n-2].x = new_vs[n-1].x; new_vs[n-2].y = new_vs[n-1].y; } } else { /* first point does not have a corresponding smooth point */ if (has_smooth_2) { /* last point has a corresponding smooth point */ switch (min_index) { case 0: /* join pt 0 of poly1 and pt 0 of poly2 */ case 2: /* join pt n-1 of poly1 and pt 0 of poly2 */ /* * Cannot really do the following here because it will * mess up undo. So, delay the fixing till the end. * * vlist2[1].x = vlist2[0].x; * vlist2[1].y = vlist2[0].y; */ fix_v1_of_vlist2 = TRUE; break; case 1: /* join pt 0 of poly1 and pt n-1 of poly2 */ case 3: /* join pt n-1 of poly1 and pt n-1 of poly2 */ /* * Cannot really do the following here because it will * mess up undo. So, delay the fixing till the end. * * vlist2[n2-2].x = vlist2[n2-1].x; * vlist2[n2-2].y = vlist2[n2-1].y; */ fix_vn2_minus_2_of_vlist2 = TRUE; break; } } else { /* last point does not have a corresponding smooth point */ } } } else { switch (min_index) { case 0: /* join point 0 of poly_ptr1 and point 0 of poly_ptr2 */ case 1: /* join point 0 of poly_ptr1 and point n-1 of poly_ptr2 */ if (pjssi->sssi1.ipt.later_valid) { /* first point has a corresponding smooth point */ new_vs[n].x = (new_vs[n-1].x<<1) - new_vs[n-2].x; new_vs[n].y = (new_vs[n-1].y<<1) - new_vs[n-2].y; } else { /* first point does not have a corresponding smooth point */ new_vs[n].x = new_vs[n-1].x; new_vs[n].y = new_vs[n-1].y; } n++; break; case 2: /* join point n-1 of poly_ptr1 and point 0 of poly_ptr2 */ case 3: /* join point n-1 of poly_ptr1 and point n-1 of poly_ptr2 */ if (pjssi->sssi1.ipt.earlier_valid) { /* first point has a corresponding smooth point */ new_vs[n].x = (new_vs[n-1].x<<1) - new_vs[n-2].x; new_vs[n].y = (new_vs[n-1].y<<1) - new_vs[n-2].y; } else { /* first point does not have a corresponding smooth point */ new_vs[n].x = new_vs[n-1].x; new_vs[n].y = new_vs[n-1].y; } n++; break; } switch (min_index) { case 0: /* join point 0 of poly_ptr1 and point 0 of poly_ptr2 */ case 2: /* join point n-1 of poly_ptr1 and point 0 of poly_ptr2 */ if (pjssi->sssi2.ipt.later_valid) { /* last point has a corresponding smooth point */ if (obj_ptr2->ctm == NULL) { new_vs[n].x = (vlist2[0].x<<1) - vlist2[1].x; new_vs[n].y = (vlist2[0].y<<1) - vlist2[1].y; } else { TransformObjectV(obj_ptr2, &vlist2[0], &tmp_p1); TransformObjectV(obj_ptr2, &vlist2[1], &tmp_p2); new_vs[n].x = (tmp_p1.x<<1) - tmp_p2.x; new_vs[n].y = (tmp_p1.y<<1) - tmp_p2.y; } } else { /* last point does not have a corresponding smooth point */ if (obj_ptr2->ctm == NULL) { new_vs[n].x = vlist2[0].x; new_vs[n].y = vlist2[0].y; } else { TransformObjectV(obj_ptr2, &vlist2[0], &tmp_p); new_vs[n].x = tmp_p.x; new_vs[n].y = tmp_p.y; } } n++; break; case 1: /* join point 0 of poly_ptr1 and point n-1 of poly_ptr2 */ case 3: /* join point n-1 of poly_ptr1 and point n-1 of poly_ptr2 */ if (pjssi->sssi2.ipt.earlier_valid) { /* last point has a corresponding smooth point */ if (obj_ptr2->ctm == NULL) { new_vs[n].x = (vlist2[n2-1].x<<1) - vlist2[n2-2].x; new_vs[n].y = (vlist2[n2-1].y<<1) - vlist2[n2-2].y; } else { TransformObjectV(obj_ptr2, &vlist2[n2-1], &tmp_p1); TransformObjectV(obj_ptr2, &vlist2[n2-2], &tmp_p2); new_vs[n].x = (tmp_p1.x<<1) - tmp_p2.x; new_vs[n].y = (tmp_p1.y<<1) - tmp_p2.y; } } else { /* last point does not have a corresponding smooth point */ if (obj_ptr2->ctm == NULL) { new_vs[n].x = vlist2[n2-1].x; new_vs[n].y = vlist2[n2-1].y; } else { TransformObjectV(obj_ptr2, &vlist2[n2-1], &tmp_p); new_vs[n].x = tmp_p.x; new_vs[n].y = tmp_p.y; } } n++; break; } } if (coincide) { switch (min_index) { case 0: min_val=1; max_val=n2; inc=1; break; case 1: min_val=n2-2; max_val=0; inc=(-1); break; case 2: min_val=1; max_val=n2; inc=1; break; case 3: min_val=n2-2; max_val=0; inc=(-1); break; } } else { switch (min_index) { case 0: min_val=0; max_val=n2; inc=1; break; case 1: min_val=n2-1; max_val=0; inc=(-1); break; case 2: min_val=0; max_val=n2; inc=1; break; case 3: min_val=n2-1; max_val=0; inc=(-1); break; } } i = min_val; while (inc > 0 ? i < max_val : i >= max_val) { if (obj_ptr2->ctm == NULL) { memcpy(&new_vs[n], &vlist2[i], sizeof(IntPoint)); } else { TransformObjectV(obj_ptr2, &vlist2[i], &tmp_p); memcpy(&new_vs[n], &tmp_p, sizeof(IntPoint)); } n++; i += inc; } if (fix_v1_of_vlist2 || fix_vn2_minus_2_of_vlist2) { new_vs[n1].x = new_vs[n1-1].x; new_vs[n1].y = new_vs[n1-1].y; } } else { if (curved != LT_INTSPLINE) { new_smooth = (char*)malloc((num_pts+1)*sizeof(char)); if (new_smooth == NULL) FailAllocMessage(); } switch (min_index) { case 0: min_val=n1-1; max_val=0; inc=(-1); break; case 1: min_val=n1-1; max_val=0; inc=(-1); break; case 2: min_val=0; max_val=n1; inc=1; break; case 3: min_val=0; max_val=n1; inc=1; break; } n = 0; i = min_val; while (inc > 0 ? i < max_val : i >= max_val) { if (obj_ptr1->ctm == NULL) { memcpy(&new_vs[n], &vlist1[i], sizeof(IntPoint)); } else { TransformObjectV(obj_ptr1, &vlist1[i], &tmp_p); memcpy(&new_vs[n], &tmp_p, sizeof(IntPoint)); } if (new_smooth != NULL) { new_smooth[n] = poly_ptr1->smooth[i]; } n++; i += inc; } if (coincide) { switch (min_index) { case 0: min_val=1; max_val=n2; inc=1; break; case 1: min_val=n2-2; max_val=0; inc=(-1); break; case 2: min_val=1; max_val=n2; inc=1; break; case 3: min_val=n2-2; max_val=0; inc=(-1); break; } } else { switch (min_index) { case 0: min_val=0; max_val=n2; inc=1; break; case 1: min_val=n2-1; max_val=0; inc=(-1); break; case 2: min_val=0; max_val=n2; inc=1; break; case 3: min_val=n2-1; max_val=0; inc=(-1); break; } } i = min_val; while (inc > 0 ? i < max_val : i >= max_val) { if (obj_ptr2->ctm == NULL) { memcpy(&new_vs[n], &vlist2[i], sizeof(IntPoint)); } else { TransformObjectV(obj_ptr2, &vlist2[i], &tmp_p); memcpy(&new_vs[n], &tmp_p, sizeof(IntPoint)); } if (new_smooth != NULL) { new_smooth[n] = poly_ptr2->smooth[i]; } n++; i += inc; } } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); StartCompositeCmd(); FinishJoinPoly(obj_ptr1, obj_ptr2, poly_ptr1, new_vs, new_smooth, num_pts); EndCompositeCmd(); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; HighLightForward(); } static void FinishCloseOnePoly(obj_ptr, poly_ptr, vs, smooth, num_pts) struct ObjRec *obj_ptr; struct PolyRec *poly_ptr; IntPoint *vs; char *smooth; int num_pts; { struct PolygonRec *polygon_ptr=(struct PolygonRec *)malloc( sizeof(struct PolygonRec)); if (polygon_ptr == NULL) FailAllocMessage(); memset(polygon_ptr, 0, sizeof(struct PolygonRec)); polygon_ptr->n = num_pts; polygon_ptr->vlist = vs; polygon_ptr->smooth = smooth; polygon_ptr->sn = 0; polygon_ptr->svlist = NULL; polygon_ptr->intn = 0; polygon_ptr->intvlist = NULL; polygon_ptr->fill = poly_ptr->fill; polygon_ptr->width = poly_ptr->width; UtilStrCpyN(polygon_ptr->width_spec, sizeof(polygon_ptr->width_spec), poly_ptr->width_spec); polygon_ptr->pen = poly_ptr->pen; polygon_ptr->curved = poly_ptr->curved; polygon_ptr->dash = poly_ptr->dash; polygon_ptr->rotated_n = 0; polygon_ptr->rotated_vlist = NULL; PrepareToReplaceAnObj(obj_ptr); if (poly_ptr->vlist != NULL) free(poly_ptr->vlist); if (poly_ptr->svlist != NULL) free(poly_ptr->svlist); if (poly_ptr->asvlist != NULL) free(poly_ptr->asvlist); if (poly_ptr->smooth != NULL) free(poly_ptr->smooth); if (poly_ptr->intvlist != NULL) free(poly_ptr->intvlist); if (poly_ptr->rotated_vlist != NULL) free(poly_ptr->rotated_vlist); if (poly_ptr->rotated_asvlist != NULL) free(poly_ptr->rotated_asvlist); free(poly_ptr); obj_ptr->type = OBJ_POLYGON; obj_ptr->detail.g = polygon_ptr; AdjObjSplineVs(obj_ptr); if (polygon_ptr->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, polygon_ptr->n, polygon_ptr->vlist); } else { UpdPolyBBox(obj_ptr, polygon_ptr->intn, polygon_ptr->intvlist); } AdjObjBBox(obj_ptr); RecordReplaceAnObj(obj_ptr); } static void CloseOnePoly(obj_ptr) struct ObjRec *obj_ptr; { struct PolyRec *poly_ptr=obj_ptr->detail.p; int i, n=0, num_pts=0, ltx, lty, rbx, rby, coincide=FALSE; int curved=poly_ptr->curved; IntPoint *new_vs=NULL, *vs=NULL; char *new_smooth=NULL, *smooth=NULL; StretchStructuredSplineInfo sssi_first, sssi_last; memset(&sssi_first, 0, sizeof(StretchStructuredSplineInfo)); memset(&sssi_last, 0, sizeof(StretchStructuredSplineInfo)); if (curved == LT_STRUCT_SPLINE) { vs = poly_ptr->ssvlist; n = poly_ptr->ssn; smooth = poly_ptr->ssmooth; if (n < 3) { MsgBox(TgLoadString(STID_TOO_FEW_VER_TO_CLOSE_POLY), TOOL_NAME, INFO_MB); return; } } else { vs = poly_ptr->vlist; n = poly_ptr->n; smooth = poly_ptr->smooth; if (n <= 2) { MsgBox(TgLoadString(STID_TOO_FEW_VER_TO_CLOSE_POLY), TOOL_NAME, INFO_MB); return; } } if (vs[0].x == vs[n-1].x && vs[0].y == vs[n-1].y) { coincide = TRUE; if (curved == LT_STRUCT_SPLINE) { if (n <= 4) { MsgBox(TgLoadString(STID_TOO_FEW_VER_TO_CLOSE_POLY), TOOL_NAME, INFO_MB); return; } SetIPTInfoForStretchPoly(0, poly_ptr->n, poly_ptr->vlist, &sssi_first); SetIPTInfoForStretchPoly(n-1, poly_ptr->n, poly_ptr->vlist, &sssi_last); num_pts = poly_ptr->n; } else { num_pts = n; } } else { if (curved == LT_STRUCT_SPLINE) { SetIPTInfoForStretchPoly(0, poly_ptr->n, poly_ptr->vlist, &sssi_first); SetIPTInfoForStretchPoly(n-1, poly_ptr->n, poly_ptr->vlist, &sssi_last); num_pts = poly_ptr->n+3; } else { num_pts = n+1; } } new_vs = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (new_vs == NULL) FailAllocMessage(); memset(new_vs, 0, (num_pts+1)*sizeof(IntPoint)); if (curved == LT_STRUCT_SPLINE) { for (i=0; i < poly_ptr->n; i++) { memcpy(&new_vs[i], &poly_ptr->vlist[i], sizeof(IntPoint)); } if (coincide) { if (sssi_first.ipt.later_valid) { /* first point has a corresponding smooth point */ if (sssi_last.ipt.earlier_valid) { /* last point has a corresponding smooth point */ /* * in this case, move the last smooth point */ new_vs[poly_ptr->n-2].x = (new_vs[0].x<<1) - new_vs[1].x; new_vs[poly_ptr->n-2].y = (new_vs[0].y<<1) - new_vs[1].y; } else { /* last point does not have a corresponding smooth point */ /* * in this case, remove the first smooth point */ new_vs[1].x = new_vs[0].x; new_vs[1].y = new_vs[0].y; } } else { /* first point does not have a corresponding smooth point */ if (sssi_last.ipt.earlier_valid) { /* last point has a corresponding smooth point */ /* * in this case, remove the last smooth point */ new_vs[poly_ptr->n-2].x = new_vs[poly_ptr->n-1].x; new_vs[poly_ptr->n-2].y = new_vs[poly_ptr->n-1].y; } else { /* last point does not have a corresponding smooth point */ /* * in this case, there is nothing to do */ } } } else { new_vs[poly_ptr->n+2].x = new_vs[0].x; new_vs[poly_ptr->n+2].y = new_vs[0].y; if (sssi_first.ipt.later_valid) { /* first point has a corresponding smooth point */ if (sssi_last.ipt.earlier_valid) { /* last point has a corresponding smooth point */ /* * in this case, create 2 new smooth points */ new_vs[poly_ptr->n+1].x = (new_vs[0].x<<1) - new_vs[1].x; new_vs[poly_ptr->n+1].y = (new_vs[0].y<<1) - new_vs[1].y; new_vs[poly_ptr->n].x = (new_vs[poly_ptr->n-1].x<<1) - new_vs[poly_ptr->n-2].x; new_vs[poly_ptr->n].y = (new_vs[poly_ptr->n-1].y<<1) - new_vs[poly_ptr->n-2].y; } else { /* last point does not have a corresponding smooth point */ /* * in this case, create one new smooth point near the 1st point */ new_vs[poly_ptr->n+1].x = (new_vs[0].x<<1) - new_vs[1].x; new_vs[poly_ptr->n+1].y = (new_vs[0].y<<1) - new_vs[1].y; new_vs[poly_ptr->n].x = new_vs[poly_ptr->n-1].x; new_vs[poly_ptr->n].y = new_vs[poly_ptr->n-1].y; } } else { /* first point does not have a corresponding smooth point */ if (sssi_last.ipt.earlier_valid) { /* last point has a corresponding smooth point */ /* * in this case, create one new smooth point near the last point */ new_vs[poly_ptr->n+1].x = new_vs[0].x; new_vs[poly_ptr->n+1].y = new_vs[0].y; new_vs[poly_ptr->n].x = (new_vs[poly_ptr->n-1].x<<1) - new_vs[poly_ptr->n-2].x; new_vs[poly_ptr->n].y = (new_vs[poly_ptr->n-1].y<<1) - new_vs[poly_ptr->n-2].y; } else { /* last point does not have a corresponding smooth point */ /* * in this case, create 2 hinge points */ new_vs[poly_ptr->n+1].x = new_vs[0].x; new_vs[poly_ptr->n+1].y = new_vs[0].y; new_vs[poly_ptr->n].x = new_vs[poly_ptr->n-1].x; new_vs[poly_ptr->n].y = new_vs[poly_ptr->n-1].y; } } } } else { for (i=0; i < n; i++) memcpy(&new_vs[i], &vs[i], sizeof(IntPoint)); memcpy(&new_vs[n], &vs[0], sizeof(IntPoint)); if (poly_ptr->curved != LT_INTSPLINE) { new_smooth = (char*)malloc((num_pts+1)*sizeof(char)); if (new_smooth == NULL) FailAllocMessage(); for (i=0; i < n; i++) new_smooth[i] = smooth[i]; new_smooth[0] = new_smooth[n] = FALSE; } } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); FinishCloseOnePoly(obj_ptr, poly_ptr, new_vs, new_smooth, num_pts); if (curChoice == VERTEXMODE) { if (topVSel == botVSel) { int x0=0, y0=0, first_index=(-1), last_index=(-1); for (i=0; i < topVSel->n; i++) { if (topVSel->v_index[i] == 0) { x0 = topVSel->x[i]; y0 = topVSel->y[i]; first_index = i; } else if (topVSel->v_index[i] == (coincide ? num_pts-1 : num_pts-2)) { if (!coincide) { topVSel->v_index[i]++; } last_index = i; } } if (last_index != (-1) && first_index != (-1)) { topVSel->n = 2; topVSel->x[first_index] = topVSel->x[last_index] = x0; topVSel->y[first_index] = topVSel->y[last_index] = y0; } else { fprintf(stderr, "%s\n", TgLoadString(STID_HUH_WHERE_ARE_THE_VERTICES)); } } else { fprintf(stderr, "%s\n", TgLoadString(STID_HUH_TOPVSEL_NE_BOTVSEL)); } } UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; HighLightForward(); } static int JoinPolyCompatCheck(poly_ptr1, poly_ptr2) struct PolyRec *poly_ptr1, *poly_ptr2; { int rc=TRUE; switch (poly_ptr1->curved) { case LT_STRAIGHT: case LT_SPLINE: if (poly_ptr2->curved == LT_STRAIGHT || poly_ptr2->curved == LT_SPLINE) { /* compatible */ } else { rc = FALSE; } break; case LT_INTSPLINE: if (poly_ptr2->curved == LT_INTSPLINE) { /* compatible */ } else { rc = FALSE; } break; case LT_STRUCT_SPLINE: if (poly_ptr2->curved == LT_STRUCT_SPLINE) { /* compatible */ } else { rc = FALSE; } break; } if (!rc) { MsgBox(TgLoadString(STID_SEL_2_COMPAT_END_PTS_TO_JOIN), TOOL_NAME, INFO_MB); return FALSE; } return TRUE; } void JoinPoly() { struct ObjRec *obj_ptr1=NULL, *obj_ptr2=NULL; struct PolyRec *poly_ptr1=NULL, *poly_ptr2=NULL; long dx=0L, dy=0L, min_lval=0L; int i=0, min_index=(-1); if (curChoice != VERTEXMODE && curChoice != NOTHING) { MsgBox(TgLoadString(STID_CMD_ONLY_AVAIL_IN_VERSEL_MODE), TOOL_NAME, INFO_MB); return; } if (curChoice == VERTEXMODE) { if (CountSelectedVertices() != 2) { MsgBox(TgLoadString(STID_SEL_2_ENDPOINT_VER_TO_JOIN), TOOL_NAME, INFO_MB); return; } obj_ptr1 = topVSel->obj; obj_ptr2 = botVSel->obj; if (obj_ptr1->type != OBJ_POLY || obj_ptr2->type != OBJ_POLY) { MsgBox(TgLoadString(STID_SEL_VER_FROM_POLY_OPEN_ONLY), TOOL_NAME, INFO_MB); return; } poly_ptr1 = obj_ptr1->detail.p; for (i=0; i < topVSel->n; i++) { int index=topVSel->v_index[i]; if (index != 0 && index != poly_ptr1->n-1) { MsgBox(TgLoadString(STID_SEL_2_ENDPOINT_VER_TO_JOIN), TOOL_NAME, INFO_MB); return; } } if (obj_ptr1 == obj_ptr2) { CloseOnePoly(obj_ptr1); return; } poly_ptr2 = obj_ptr2->detail.p; for (i=0; i < botVSel->n; i++) { int index=botVSel->v_index[i]; if (index != 0 && index != poly_ptr2->n-1) { MsgBox(TgLoadString(STID_SEL_2_ENDPOINT_VER_TO_JOIN), TOOL_NAME, INFO_MB); return; } } if (!JoinPolyCompatCheck(poly_ptr1, poly_ptr2)) { return; } if (topVSel->v_index[0] == 0) { if (botVSel->v_index[0] == 0) { min_index = 0; } else { min_index = 1; } } else { if (botVSel->v_index[0] == 0) { min_index = 2; } else { min_index = 3; } } dx = topVSel->x[0] - botVSel->x[0]; dy = topVSel->y[0] - botVSel->y[0]; min_lval = (dx*dx)+(dy*dy); } else { IntPoint p[4], tmp_p; long d[4]; if (numObjSelected == 1 && topSel->obj->type == OBJ_POLY) { CloseOnePoly(topSel->obj); return; } else if (numObjSelected != 2 || topSel == NULL || topSel->obj->type != OBJ_POLY || botSel->obj->type != OBJ_POLY) { MsgBox(TgLoadString(STID_SEL_2_POLYLINES_OPEN_SPLINES), TOOL_NAME, INFO_MB); return; } obj_ptr1 = topSel->obj; obj_ptr2 = botSel->obj; poly_ptr1 = obj_ptr1->detail.p; poly_ptr2 = obj_ptr2->detail.p; if (!JoinPolyCompatCheck(poly_ptr1, poly_ptr2)) { return; } memcpy(&p[0], &poly_ptr1->vlist[0], sizeof(IntPoint)); memcpy(&p[1], &poly_ptr1->vlist[poly_ptr1->n-1], sizeof(IntPoint)); memcpy(&p[2], &poly_ptr2->vlist[0], sizeof(IntPoint)); memcpy(&p[3], &poly_ptr2->vlist[poly_ptr2->n-1], sizeof(IntPoint)); if (obj_ptr1->ctm != NULL) { TransformObjectV(obj_ptr1, &p[0], &tmp_p); memcpy(&p[0], &tmp_p, sizeof(IntPoint)); TransformObjectV(obj_ptr1, &p[1], &tmp_p); memcpy(&p[1], &tmp_p, sizeof(IntPoint)); } if (obj_ptr2->ctm != NULL) { TransformObjectV(obj_ptr2, &p[2], &tmp_p); memcpy(&p[2], &tmp_p, sizeof(IntPoint)); TransformObjectV(obj_ptr2, &p[3], &tmp_p); memcpy(&p[3], &tmp_p, sizeof(IntPoint)); } dx=(long)(p[0].x-p[2].x); dy=(long)(p[0].y-p[2].y); d[0]=dx*dx+dy*dy; dx=(long)(p[0].x-p[3].x); dy=(long)(p[0].y-p[3].y); d[1]=dx*dx+dy*dy; dx=(long)(p[1].x-p[2].x); dy=(long)(p[1].y-p[2].y); d[2]=dx*dx+dy*dy; dx=(long)(p[1].x-p[3].x); dy=(long)(p[1].y-p[3].y); d[3]=dx*dx+dy*dy; min_index = 0; min_lval = d[0]; for (i=1; i < 4; i++) { if (d[i] < min_lval) { min_index = i; min_lval = d[i]; } } } if (poly_ptr1->curved == LT_STRUCT_SPLINE && poly_ptr2->curved == LT_STRUCT_SPLINE) { JoinStructSplineInfo jssi; memset(&jssi, 0, sizeof(JoinStructSplineInfo)); switch (min_index) { case 0: SetIPTInfoForStretchPoly(0, poly_ptr1->n, poly_ptr1->vlist, &jssi.sssi1); SetIPTInfoForStretchPoly(0, poly_ptr2->n, poly_ptr2->vlist, &jssi.sssi2); break; case 1: SetIPTInfoForStretchPoly(0, poly_ptr1->n, poly_ptr1->vlist, &jssi.sssi1); SetIPTInfoForStretchPoly(poly_ptr2->ssn-1, poly_ptr2->n, poly_ptr2->vlist, &jssi.sssi2); break; case 2: SetIPTInfoForStretchPoly(poly_ptr1->ssn-1, poly_ptr1->n, poly_ptr1->vlist, &jssi.sssi1); SetIPTInfoForStretchPoly(0, poly_ptr2->n, poly_ptr2->vlist, &jssi.sssi2); break; case 3: SetIPTInfoForStretchPoly(poly_ptr1->ssn-1, poly_ptr1->n, poly_ptr1->vlist, &jssi.sssi1); SetIPTInfoForStretchPoly(poly_ptr2->ssn-1, poly_ptr2->n, poly_ptr2->vlist, &jssi.sssi2); break; } DoJoinPoly(obj_ptr1, obj_ptr2, poly_ptr1, poly_ptr2, min_index, (min_lval==0L), &jssi); } else { DoJoinPoly(obj_ptr1, obj_ptr2, poly_ptr1, poly_ptr2, min_index, (min_lval==0L), NULL); } } /* --------------------- CutPoly() --------------------- */ static void FinishCutPoly(obj_ptr1, poly_ptr1, vs1, smooth1, vs2, smooth2, num_pts1, num_pts2) struct ObjRec *obj_ptr1; struct PolyRec *poly_ptr1; IntPoint *vs1, *vs2; char *smooth1, *smooth2; int num_pts1, num_pts2; { struct ObjRec *obj_ptr2; struct PolyRec *poly_ptr2; int x0, y0; x0 = topVSel->x[0]; y0 = topVSel->y[0]; RemoveAllSel(); PrepareToReplaceAnObj(obj_ptr1); obj_ptr2 = DupObj(obj_ptr1); poly_ptr2 = obj_ptr2->detail.p; DelAllAttrs(obj_ptr2->fattr); obj_ptr2->fattr = obj_ptr2->lattr = NULL; if (poly_ptr1->vlist != NULL) free(poly_ptr1->vlist); if (poly_ptr1->svlist != NULL) free(poly_ptr1->svlist); if (poly_ptr1->asvlist != NULL) free(poly_ptr1->asvlist); if (poly_ptr1->smooth != NULL) free(poly_ptr1->smooth); if (poly_ptr1->intvlist != NULL) free(poly_ptr1->intvlist); if (poly_ptr1->rotated_vlist != NULL) free(poly_ptr1->rotated_vlist); if (poly_ptr1->rotated_asvlist != NULL) free(poly_ptr1->rotated_asvlist); poly_ptr1->smooth = smooth1; poly_ptr1->vlist = poly_ptr1->intvlist = NULL; poly_ptr1->n = poly_ptr1->intn = 0; poly_ptr1->svlist = poly_ptr1->asvlist = poly_ptr1->rotated_vlist = poly_ptr1->rotated_asvlist = NULL; poly_ptr1->sn = poly_ptr1->asn = poly_ptr1->rotated_n = poly_ptr1->rotated_asn = 0; if (obj_ptr1->ctm != NULL) free(obj_ptr1->ctm); obj_ptr1->ctm = NULL; poly_ptr1->vlist = vs1; poly_ptr1->n = num_pts1; if (poly_ptr2->vlist != NULL) free(poly_ptr2->vlist); if (poly_ptr2->svlist != NULL) free(poly_ptr2->svlist); if (poly_ptr2->asvlist != NULL) free(poly_ptr2->asvlist); if (poly_ptr2->smooth != NULL) free(poly_ptr2->smooth); if (poly_ptr2->intvlist != NULL) free(poly_ptr2->intvlist); if (poly_ptr2->rotated_vlist != NULL) free(poly_ptr2->rotated_vlist); if (poly_ptr2->rotated_asvlist != NULL) free(poly_ptr2->rotated_asvlist); poly_ptr2->smooth = smooth2; poly_ptr2->vlist = poly_ptr2->intvlist = NULL; poly_ptr2->n = poly_ptr2->intn = 0; poly_ptr2->svlist = poly_ptr2->asvlist = poly_ptr2->rotated_vlist = poly_ptr2->rotated_asvlist = NULL; poly_ptr2->sn = poly_ptr2->asn = poly_ptr2->rotated_n = poly_ptr2->rotated_asn = 0; if (obj_ptr2->ctm != NULL) free(obj_ptr2->ctm); obj_ptr2->ctm = NULL; poly_ptr2->vlist = vs2; poly_ptr2->n = num_pts2; AdjObjSplineVs(obj_ptr1); if (poly_ptr1->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr1, poly_ptr1->n, poly_ptr1->vlist); } else { UpdPolyBBox(obj_ptr1, poly_ptr1->intn, poly_ptr1->intvlist); } AdjObjBBox(obj_ptr1); AdjObjSplineVs(obj_ptr2); if (poly_ptr2->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr2, poly_ptr2->n, poly_ptr2->vlist); } else { UpdPolyBBox(obj_ptr2, poly_ptr2->intn, poly_ptr2->intvlist); } AdjObjBBox(obj_ptr2); AddObj(obj_ptr1->prev, obj_ptr1, obj_ptr2); topSel = (struct SelRec *)malloc(sizeof(struct SelRec)); botSel = (struct SelRec *)malloc(sizeof(struct SelRec)); if (topSel==NULL || botSel==NULL) FailAllocMessage(); topSel->obj = obj_ptr2; botSel->obj = obj_ptr1; topSel->prev = botSel->next = NULL; topSel->next = botSel; botSel->prev = topSel; RecordCmd(CMD_ONE_TO_MANY, NULL, topSel, botSel, 2); topVSel = botVSel = (struct VSelRec *)malloc(sizeof(struct VSelRec)); if (topVSel==NULL) FailAllocMessage(); memset(topVSel, 0, sizeof(struct VSelRec)); topVSel->obj = obj_ptr2; topVSel->max_v = 10; topVSel->v_index = (int*)malloc(10*sizeof(int)); topVSel->x = (int*)malloc(10*sizeof(int)); topVSel->y = (int*)malloc(10*sizeof(int)); if (topVSel->v_index==NULL || topVSel->x==NULL || topVSel->y==NULL) { FailAllocMessage(); } topVSel->v_index[0] = 0; topVSel->x[0] = x0; topVSel->y[0] = y0; topVSel->n = 1; topVSel->next = topVSel->prev = NULL; } static void DoCutPoly(obj_ptr, index, poly_ptr) struct ObjRec *obj_ptr; int index; struct PolyRec *poly_ptr; { int i=0, n=poly_ptr->n, n1=0, n2=0, ltx, lty, rbx, rby; int curved=poly_ptr->curved; IntPoint *vs1=NULL, *vs2=NULL; char *smooth1=NULL, *smooth2=NULL; if (curved == LT_STRUCT_SPLINE) { StretchStructuredSplineInfo sssi; memset(&sssi, 0, sizeof(StretchStructuredSplineInfo)); if (index == poly_ptr->ssn-1) { return; } SetIPTInfoForStretchPoly(index, poly_ptr->n, poly_ptr->vlist, &sssi); if (!sssi.hinge) { MsgBox(TgLoadString(STID_CANNOT_CUT_AT_SMOOTH_PT), TOOL_NAME, INFO_MB); return; } n1 = sssi.orig_hinge_index + 1; n2 = n - sssi.orig_hinge_index; vs1 = (IntPoint*)malloc((n1+1)*sizeof(IntPoint)); vs2 = (IntPoint*)malloc((n2+1)*sizeof(IntPoint)); if (vs1==NULL || vs2==NULL) FailAllocMessage(); for (i=0; i <= sssi.orig_hinge_index; i++) { if (obj_ptr->ctm == NULL) { memcpy(&vs1[i], &poly_ptr->vlist[i], sizeof(IntPoint)); } else { IntPoint tmp_p; TransformObjectV(obj_ptr, &poly_ptr->vlist[i], &tmp_p); memcpy(&vs1[i], &tmp_p, sizeof(IntPoint)); } } for (i=sssi.orig_hinge_index; i < n; i++) { if (obj_ptr->ctm == NULL) { memcpy(&vs2[i-sssi.orig_hinge_index], &poly_ptr->vlist[i], sizeof(IntPoint)); } else { IntPoint tmp_p; TransformObjectV(obj_ptr, &poly_ptr->vlist[i], &tmp_p); memcpy(&vs2[i-sssi.orig_hinge_index], &tmp_p, sizeof(IntPoint)); } } } else { n1 = index+1; n2 = n-index; vs1 = (IntPoint*)malloc((n1+1)*sizeof(IntPoint)); vs2 = (IntPoint*)malloc((n2+1)*sizeof(IntPoint)); if (vs1==NULL || vs2==NULL) FailAllocMessage(); if (poly_ptr->curved != LT_INTSPLINE) { smooth1 = (char*)malloc((n1+1)*sizeof(char)); smooth2 = (char*)malloc((n2+1)*sizeof(char)); if (smooth1==NULL || smooth2==NULL) FailAllocMessage(); } for (i=0; i <= index; i++) { if (obj_ptr->ctm == NULL) { memcpy(&vs1[i], &poly_ptr->vlist[i], sizeof(IntPoint)); } else { IntPoint tmp_p; TransformObjectV(obj_ptr, &poly_ptr->vlist[i], &tmp_p); memcpy(&vs1[i], &tmp_p, sizeof(IntPoint)); } if (smooth1 != NULL) { smooth1[i] = poly_ptr->smooth[i]; } } if (smooth1 != NULL) smooth1[0] = smooth1[index] = FALSE; for (i=index; i < n; i++) { if (obj_ptr->ctm == NULL) { memcpy(&vs2[i-index], &poly_ptr->vlist[i], sizeof(IntPoint)); } else { IntPoint tmp_p; TransformObjectV(obj_ptr, &poly_ptr->vlist[i], &tmp_p); memcpy(&vs2[i-index], &tmp_p, sizeof(IntPoint)); } if (smooth2 != NULL) { smooth2[i-index] = poly_ptr->smooth[i]; } } if (smooth2 != NULL) smooth2[0] = smooth2[n-1-index] = FALSE; } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); FinishCutPoly(obj_ptr, poly_ptr, vs1, smooth1, vs2, smooth2, n1, n2); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; HighLightForward(); } static void FinishCutPolygon(obj_ptr1, polygon_ptr1, vs, smooth, num_pts) struct ObjRec *obj_ptr1; struct PolygonRec *polygon_ptr1; IntPoint *vs; char *smooth; int num_pts; { struct ObjRec *obj_ptr2; struct PolyRec *poly_ptr; struct PolygonRec *polygon_ptr2; int x0, y0; x0 = topVSel->x[0]; y0 = topVSel->y[0]; poly_ptr = (struct PolyRec *)malloc(sizeof(struct PolyRec)); if (poly_ptr == NULL) FailAllocMessage(); memset(poly_ptr, 0, sizeof(struct PolyRec)); poly_ptr->n = num_pts; poly_ptr->vlist = vs; poly_ptr->smooth = smooth; poly_ptr->asn = 0; poly_ptr->asvlist = NULL; poly_ptr->sn = 0; poly_ptr->svlist = NULL; poly_ptr->intn = 0; poly_ptr->intvlist = NULL; poly_ptr->style = LS_PLAIN; poly_ptr->width = polygon_ptr1->width; UtilStrCpyN(poly_ptr->width_spec, sizeof(poly_ptr->width_spec), polygon_ptr1->width_spec); poly_ptr->pen = polygon_ptr1->pen; poly_ptr->curved = polygon_ptr1->curved; poly_ptr->fill = polygon_ptr1->fill; poly_ptr->dash = polygon_ptr1->dash; if (poly_ptr->width == curWidthOfLine[lineWidth]) { poly_ptr->aw = curArrowHeadW[lineWidth]; poly_ptr->ah = curArrowHeadH[lineWidth]; UtilStrCpyN(poly_ptr->aw_spec, sizeof(poly_ptr->aw_spec), curArrowHeadWSpec[lineWidth]); UtilStrCpyN(poly_ptr->ah_spec, sizeof(poly_ptr->ah_spec), curArrowHeadHSpec[lineWidth]); } else if (maxLineWidths > 0) { int i, width=poly_ptr->width; int min_diff=abs(curWidthOfLine[0]-width), min_index=0; for (i=1; min_diff > 0 && i < maxLineWidths; i++) { int diff=abs(curWidthOfLine[i]-width); if (diff < min_diff) { min_diff = diff; min_index = i; } } poly_ptr->aw = curArrowHeadW[min_index]; poly_ptr->ah = curArrowHeadH[min_index]; UtilStrCpyN(poly_ptr->aw_spec, sizeof(poly_ptr->aw_spec), curArrowHeadWSpec[min_index]); UtilStrCpyN(poly_ptr->ah_spec, sizeof(poly_ptr->ah_spec), curArrowHeadHSpec[min_index]); } poly_ptr->rotated_n = poly_ptr->rotated_asn = 0; poly_ptr->rotated_vlist = poly_ptr->rotated_asvlist = NULL; JustRemoveAllVSel(); PrepareToReplaceAnObj(obj_ptr1); obj_ptr2 = DupObj(obj_ptr1); obj_ptr2->fattr = obj_ptr1->fattr; obj_ptr2->lattr = obj_ptr1->lattr; obj_ptr1->fattr = obj_ptr1->lattr = NULL; polygon_ptr2 = obj_ptr2->detail.g; if (polygon_ptr2->vlist != NULL) free(polygon_ptr2->vlist); if (polygon_ptr2->svlist != NULL) free(polygon_ptr2->svlist); if (polygon_ptr2->smooth != NULL) free(polygon_ptr2->smooth); if (polygon_ptr2->intvlist != NULL) free(polygon_ptr2->intvlist); if (polygon_ptr2->rotated_vlist != NULL) free(polygon_ptr2->rotated_vlist); free(polygon_ptr2); if (obj_ptr2->ctm != NULL) free(obj_ptr2->ctm); obj_ptr2->ctm = NULL; obj_ptr2->type = OBJ_POLY; obj_ptr2->detail.p = poly_ptr; AdjObjSplineVs(obj_ptr2); if (poly_ptr->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr2, poly_ptr->n, poly_ptr->vlist); } else { UpdPolyBBox(obj_ptr2, poly_ptr->intn, poly_ptr->intvlist); } AdjObjBBox(obj_ptr2); AddObj(obj_ptr1->prev, obj_ptr1, obj_ptr2); UnlinkObj(obj_ptr1); FreeObj(obj_ptr1); topSel->obj = obj_ptr2; topSel->prev = topSel->next = NULL; botSel = topSel; RecordReplaceAnObj(obj_ptr2); topVSel = botVSel = (struct VSelRec *)malloc(sizeof(struct VSelRec)); if (topVSel == NULL) FailAllocMessage(); memset(topVSel, 0, sizeof(struct VSelRec)); topVSel->obj = obj_ptr2; topVSel->max_v = 10; topVSel->v_index = (int*)malloc(10*sizeof(int)); topVSel->x = (int*)malloc(10*sizeof(int)); topVSel->y = (int*)malloc(10*sizeof(int)); if (topVSel->v_index==NULL || topVSel->x==NULL || topVSel->y==NULL) { FailAllocMessage(); } topVSel->v_index[0] = 0; topVSel->x[0] = x0; topVSel->y[0] = y0; topVSel->n = 1; topVSel->next = topVSel->prev = NULL; } static void DoCutPolygon(obj_ptr, index, polygon_ptr) struct ObjRec *obj_ptr; int index; struct PolygonRec *polygon_ptr; { int i, n=polygon_ptr->n, num_pts, ltx, lty, rbx, rby; int curved=polygon_ptr->curved; IntPoint *vs=NULL; char *smooth=NULL; if (curved == LT_STRUCT_SPLINE) { StretchStructuredSplineInfo sssi; memset(&sssi, 0, sizeof(StretchStructuredSplineInfo)); SetIPTInfoForStretchPolygon(index, polygon_ptr->n, polygon_ptr->vlist, &sssi); if (!sssi.hinge) { MsgBox(TgLoadString(STID_CANNOT_CUT_AT_SMOOTH_PT), TOOL_NAME, INFO_MB); return; } num_pts = n; vs = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (vs == NULL) FailAllocMessage(); for (i=sssi.orig_hinge_index; i < num_pts; i++) { if (obj_ptr->ctm == NULL) { memcpy(&vs[i-sssi.orig_hinge_index], &polygon_ptr->vlist[i], sizeof(IntPoint)); } else { IntPoint tmp_p; TransformObjectV(obj_ptr, &polygon_ptr->vlist[i], &tmp_p); memcpy(&vs[i-sssi.orig_hinge_index], &tmp_p, sizeof(IntPoint)); } } for (i=1; i <= sssi.orig_hinge_index; i++) { if (obj_ptr->ctm == NULL) { memcpy(&vs[i+num_pts-sssi.orig_hinge_index-1], &polygon_ptr->vlist[i], sizeof(IntPoint)); } else { IntPoint tmp_p; TransformObjectV(obj_ptr, &polygon_ptr->vlist[i], &tmp_p); memcpy(&vs[i+num_pts-sssi.orig_hinge_index-1], &tmp_p, sizeof(IntPoint)); } } } else { num_pts = n; vs = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (vs == NULL) FailAllocMessage(); if (polygon_ptr->curved != LT_INTSPLINE) { smooth = (char*)malloc((num_pts+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); } for (i=index; i < num_pts; i++) { if (obj_ptr->ctm == NULL) { memcpy(&vs[i-index], &polygon_ptr->vlist[i], sizeof(IntPoint)); } else { IntPoint tmp_p; TransformObjectV(obj_ptr, &polygon_ptr->vlist[i], &tmp_p); memcpy(&vs[i-index], &tmp_p, sizeof(IntPoint)); } if (smooth != NULL) { smooth[i-index] = polygon_ptr->smooth[i]; } } for (i=1; i <= index; i++) { if (obj_ptr->ctm == NULL) { memcpy(&vs[i+num_pts-index-1], &polygon_ptr->vlist[i], sizeof(IntPoint)); } else { IntPoint tmp_p; TransformObjectV(obj_ptr, &polygon_ptr->vlist[i], &tmp_p); memcpy(&vs[i+num_pts-index-1], &tmp_p, sizeof(IntPoint)); } if (smooth != NULL) { smooth[i+num_pts-index-1] = polygon_ptr->smooth[i]; } } if (smooth != NULL) smooth[0] = smooth[num_pts-1] = FALSE; } ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; HighLightReverse(); FinishCutPolygon(obj_ptr, polygon_ptr, vs, smooth, num_pts); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; HighLightForward(); } static void CopyPolySegmentProperties(obj_ptr, poly_ptr, curved) struct ObjRec *obj_ptr; struct PolyRec *poly_ptr; int curved; { struct PolyRec *new_poly_ptr=topObj->detail.p; new_poly_ptr->style = LS_PLAIN; new_poly_ptr->width = poly_ptr->width; new_poly_ptr->aw = poly_ptr->aw; new_poly_ptr->ah = poly_ptr->ah; strcpy(new_poly_ptr->width_spec, poly_ptr->width_spec); strcpy(new_poly_ptr->aw_spec, poly_ptr->aw_spec); strcpy(new_poly_ptr->ah_spec, poly_ptr->ah_spec); new_poly_ptr->pen = poly_ptr->pen; new_poly_ptr->fill = poly_ptr->fill; new_poly_ptr->curved = curved; new_poly_ptr->dash = poly_ptr->dash; topObj->color = obj_ptr->color; topObj->bg_color = obj_ptr->bg_color; memcpy(topObj->color_str, obj_ptr->color_str, sizeof(obj_ptr->color_str)); memcpy(topObj->bg_color_str, obj_ptr->bg_color_str, sizeof(obj_ptr->bg_color_str)); topObj->trans_pat = obj_ptr->trans_pat; AdjObjSplineVs(topObj); AdjObjBBox(topObj); } static void CopyPolygonSegmentProperties(obj_ptr, polygon_ptr, curved) struct ObjRec *obj_ptr; struct PolygonRec *polygon_ptr; int curved; { struct PolyRec *new_poly_ptr=topObj->detail.p; int index=0; new_poly_ptr->style = LS_PLAIN; new_poly_ptr->width = polygon_ptr->width; strcpy(new_poly_ptr->width_spec, polygon_ptr->width_spec); index = GetBestLineWidthIndex(new_poly_ptr->width, INVALID, INVALID); new_poly_ptr->aw = curArrowHeadW[index]; new_poly_ptr->ah = curArrowHeadH[index]; strcpy(new_poly_ptr->aw_spec, curArrowHeadWSpec[index]); strcpy(new_poly_ptr->ah_spec, curArrowHeadHSpec[index]); new_poly_ptr->pen = polygon_ptr->pen; new_poly_ptr->fill = polygon_ptr->fill; new_poly_ptr->curved = curved; new_poly_ptr->dash = polygon_ptr->dash; topObj->color = obj_ptr->color; topObj->bg_color = obj_ptr->bg_color; memcpy(topObj->color_str, obj_ptr->color_str, sizeof(obj_ptr->color_str)); memcpy(topObj->bg_color_str, obj_ptr->bg_color_str, sizeof(obj_ptr->bg_color_str)); topObj->trans_pat = obj_ptr->trans_pat; AdjObjSplineVs(topObj); AdjObjBBox(topObj); } static int CreateSegmentsFromObject(obj_ptr, pp_top_obj, pp_bot_obj) struct ObjRec *obj_ptr, **pp_top_obj, **pp_bot_obj; { int i=0, n=0, ssn=0, saved_line_style=0, saved_spline=0, curved=(-1); IntPoint *vlist=NULL, *ssvlist=NULL, tmp_p; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; struct ObjRec *saved_top_obj=topObj, *saved_bot_obj=botObj; char *ssmooth=NULL; switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; curved = poly_ptr->curved; n = poly_ptr->n; if (n <= 2) return FALSE; vlist = poly_ptr->vlist; if (curved == LT_STRUCT_SPLINE) { ssn = poly_ptr->ssn; if (ssn <= 2) return FALSE; ssvlist = poly_ptr->ssvlist; ssmooth = poly_ptr->ssmooth; } break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; curved = polygon_ptr->curved; n = polygon_ptr->n; if (n <= 2) return FALSE; vlist = polygon_ptr->vlist; if (curved == LT_STRUCT_SPLINE) { ssn = polygon_ptr->ssn; if (ssn <= 2) return FALSE; ssvlist = polygon_ptr->ssvlist; ssmooth = polygon_ptr->ssmooth; } break; } curPage->top = topObj = (*pp_top_obj); curPage->bot = botObj = (*pp_bot_obj); saved_line_style = lineStyle; saved_spline = curSpline; lineStyle = LS_PLAIN; if (curved == LT_STRUCT_SPLINE) { IntPoint tmp_vs[4]; int num_vs=0; curSpline = LT_STRUCT_SPLINE; ResetCreatePoly(); if (obj_ptr->ctm == NULL) { memcpy(&tmp_vs[0], &ssvlist[0], sizeof(IntPoint)); } else { TransformObjectV(obj_ptr, &ssvlist[0], &tmp_p); memcpy(&tmp_vs[0], &tmp_p, sizeof(IntPoint)); } num_vs = 1; for (i=1; i < ssn; i++) { if (obj_ptr->ctm == NULL) { memcpy(&tmp_vs[num_vs], &ssvlist[i], sizeof(IntPoint)); } else { TransformObjectV(obj_ptr, &ssvlist[i], &tmp_p); memcpy(&tmp_vs[num_vs], &tmp_p, sizeof(IntPoint)); } num_vs++; if (!ssmooth[i]) { IntPointTriplet ipt_first, ipt_last; memset(&ipt_first, 0, sizeof(IntPointTriplet)); memset(&ipt_last, 0, sizeof(IntPointTriplet)); memcpy(&ipt_first.hinge_pt, &tmp_vs[0], sizeof(IntPoint)); ipt_first.earlier_valid = ipt_first.later_valid = FALSE; ipt_first.ratio = (double)1; memcpy(&ipt_last.hinge_pt, &tmp_vs[num_vs-1], sizeof(IntPoint)); ipt_last.earlier_valid = ipt_last.later_valid = FALSE; ipt_last.ratio = (double)1; switch (num_vs) { case 2: break; case 3: memcpy(&ipt_first.later_smooth_pt, &tmp_vs[1], sizeof(IntPoint)); ipt_first.later_valid = TRUE; break; case 4: memcpy(&ipt_first.later_smooth_pt, &tmp_vs[1], sizeof(IntPoint)); ipt_first.later_valid = TRUE; memcpy(&ipt_last.earlier_smooth_pt, &tmp_vs[2], sizeof(IntPoint)); ipt_last.earlier_valid = TRUE; break; } AddPointForCont(0, 0, &ipt_first); AddPointForCont(0, 0, &ipt_last); CreatePolyObj(2, TRUE); switch (obj_ptr->type) { case OBJ_POLY: CopyPolySegmentProperties(obj_ptr, poly_ptr, LT_STRUCT_SPLINE); break; case OBJ_POLYGON: CopyPolygonSegmentProperties(obj_ptr, polygon_ptr, LT_STRUCT_SPLINE); break; } ResetCreatePoly(); memcpy(&tmp_vs[0], &tmp_vs[num_vs-1], sizeof(IntPoint)); num_vs = 1; } } } else { IntPoint *tmp_vs=NULL; tmp_vs = (IntPoint*)malloc(n*sizeof(IntPoint)); if (tmp_vs == NULL) FailAllocMessage(); memset(tmp_vs, 0, n*sizeof(IntPoint)); for (i=0; i < n; i++) { if (obj_ptr->ctm == NULL) { memcpy(&tmp_vs[i], &vlist[i], sizeof(IntPoint)); } else { TransformObjectV(obj_ptr, &vlist[i], &tmp_p); memcpy(&tmp_vs[i], &tmp_p, sizeof(IntPoint)); } } curSpline = LT_STRAIGHT; for (i=0; i < n-1; i++) { ResetCreatePoly(); AddPtToCreatePoly(tmp_vs[i].x, tmp_vs[i].y); AddPtToCreatePoly(tmp_vs[i+1].x, tmp_vs[i+1].y); CreatePolyObj(2, TRUE); switch (obj_ptr->type) { case OBJ_POLY: CopyPolySegmentProperties(obj_ptr, poly_ptr, LT_STRAIGHT); break; case OBJ_POLYGON: CopyPolygonSegmentProperties(obj_ptr, polygon_ptr, LT_STRAIGHT); break; } } free(tmp_vs); } lineStyle = saved_line_style; curSpline = saved_spline; (*pp_top_obj) = topObj; (*pp_bot_obj) = botObj; curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; return TRUE; } static void CutPolyIntoSegments() { struct SelRec *sel_ptr=NULL, *new_top_sel=NULL, *new_bot_sel=NULL; int something_changed=FALSE; UnSelNonVertexObjs(TRUE, FALSE); /* with highlight */ UpdSelBBox(); if (topSel == NULL) { MsgBox(TgLoadString(STID_NO_POLY_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { struct ObjRec *new_top_obj=NULL, *new_bot_obj=NULL; PrepareToReplaceAnObj(sel_ptr->obj); if (CreateSegmentsFromObject(sel_ptr->obj, &new_top_obj, &new_bot_obj)) { struct ObjRec *obj_ptr=NULL; struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; int count=0; something_changed = TRUE; UnlinkObj(sel_ptr->obj); FreeObj(sel_ptr->obj); /* add newly created line segments to the top of the object chain */ new_bot_obj->next = topObj; if (topObj == NULL) { curPage->bot = botObj = new_bot_obj; } else { topObj->prev = new_bot_obj; } curPage->top = topObj = new_top_obj; topSel = botSel = NULL; for (obj_ptr=new_bot_obj; obj_ptr != NULL; obj_ptr=obj_ptr->prev, count++) { AddSel(NULL, topSel, SelectThisObject(obj_ptr)); } UpdSelBBox(); RecordCmd(CMD_ONE_TO_MANY, NULL, topSel, botSel, numObjSelected); botSel->next = new_top_sel; if (new_top_sel == NULL) { new_bot_sel = botSel; } else { new_top_sel->prev = botSel; } new_top_sel = topSel; topSel = saved_top_sel; botSel = saved_bot_sel; } else { AbortPrepareCmd(CMD_REPLACE); } } EndCompositeCmd(); if (something_changed) { RemoveAllSel(); topSel = new_top_sel; botSel = new_bot_sel; UpdSelBBox(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; } HighLightForward(); } void CutPoly() { struct ObjRec *obj_ptr; struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; int index; if (curChoice == NOTHING) { if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (MsgBox(TgLoadString(STID_Q_OK_TO_CUT_INTO_SEGMENTS), TOOL_NAME, YNC_MB) != MB_ID_YES) { return; } CutPolyIntoSegments(); return; } else if (curChoice != VERTEXMODE) { MsgBox(TgLoadString(STID_CMD_ONLY_AVAIL_IN_VERTEX_MODE), TOOL_NAME, INFO_MB); return; } else if (CountSelectedVertices() != 1) { MsgBox(TgLoadString(STID_SEL_1_VERTEX_TO_CUT), TOOL_NAME, INFO_MB); return; } obj_ptr = topVSel->obj; index = topVSel->v_index[0]; switch (obj_ptr->type) { case OBJ_POLY: poly_ptr = obj_ptr->detail.p; if (index==0 || index==poly_ptr->n-1) return; DoCutPoly(obj_ptr, index, poly_ptr); break; case OBJ_POLYGON: polygon_ptr = obj_ptr->detail.g; DoCutPolygon(obj_ptr, index, polygon_ptr); break; default: MsgBox(TgLoadString(STID_SEL_A_VERTEX_FROM_POLY_OR_GON), TOOL_NAME, INFO_MB); return; } } /* --------------------- GetWidthInDouble() --------------------- */ double GetWidthInDouble(nVal, pszSpec, pnIsInt) int nVal, *pnIsInt; char *pszSpec; { float fval; if (pnIsInt != NULL) *pnIsInt = TRUE; if (pszSpec == NULL || *pszSpec == '\0') return (double)nVal; if (sscanf(pszSpec, "%f", &fval) != 1) return (double)nVal; if (pnIsInt != NULL) { if (fabs(((float)nVal)-fval) > INT_TOL) { *pnIsInt = FALSE; } } return ((double)fval); } /* --------------------- SetWidthAndSpec() --------------------- */ void SetWidthAndSpec(dWidth, pnWidth, pszWidthSpec) double dWidth; int *pnWidth; char *pszWidthSpec; { float fval=(float)dWidth; FormatFloat(&fval, pszWidthSpec); *pnWidth = round(dWidth); } /* --------------------- ScaleWidthAndSpec() --------------------- */ void ScaleWidthAndSpec(dScale, pnWidth, pszWidthSpec) double dScale; int *pnWidth; char *pszWidthSpec; /* char[40] */ { double dw=GetWidthInDouble(*pnWidth, pszWidthSpec, NULL); dw = dw*dScale; SetWidthAndSpec(dw, pnWidth, pszWidthSpec); } /* --------------------- DumpArrow() --------------------- */ void DumpArrow(FP, TailV, HeadV, ArrowW, ArrowH, aw_spec, ah_spec, Pen, TransPat, ColorIndex) FILE *FP; IntPoint *TailV, *HeadV; int ArrowW, ArrowH, Pen, TransPat, ColorIndex; char *aw_spec, *ah_spec; /* HeadV is where the arrow tip is */ /* Make sure this function is not called with (Pen==BACKPAT && TransPat) */ { int i, dx, dy; struct BBRec bbox; IntPoint v[2]; double len, sin, cos, daw, dah; memset(&bbox, 0, sizeof(struct BBRec)); dx = HeadV->x - TailV->x; dy = HeadV->y - TailV->y; if (dx == 0 && dy == 0) return; fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); fprintf(FP, " %s\n", &(gPsCmd[PS_TGIFSETMATRIX])[1]); daw = GetWidthInDouble(ArrowW, aw_spec, NULL); dah = GetWidthInDouble(ArrowH, ah_spec, NULL); if (colorDump || !useGray) { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin = ((double)dy) / len; cos = ((double)dx) / len; v[0].x = round(HeadV->x - daw*cos + dah*sin); v[0].y = round(HeadV->y - daw*sin - dah*cos); v[1].x = round(HeadV->x - daw*cos - dah*sin); v[1].y = round(HeadV->y - daw*sin + dah*cos); bbox.ltx = bbox.rbx = HeadV->x; bbox.lty = bbox.rby = HeadV->y; for (i = 0; i < 2; i++) { if (v[i].x < bbox.ltx) bbox.ltx = v[i].x; if (v[i].y < bbox.lty) bbox.lty = v[i].y; if (v[i].x > bbox.rbx) bbox.rbx = v[i].x; if (v[i].y > bbox.rby) bbox.rby = v[i].y; } if (preDumpSetup) PSUseArrow(); if (!TransPat) { fprintf(FP, " %s\n", gPsCmd[PS_NEWPATH]); fprintf(FP, " %1d %1d %.3f %.3f %1d %1d TGAT\n", HeadV->x, HeadV->y, daw, dah, dx, dy); fprintf(FP, " 1 %s %s %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_CLOSEPATH], gPsCmd[PS_FILL]); DumpRGBColorLine(FP, ColorIndex, 3, TRUE); } } else { switch (Pen) { case SOLIDPAT: break; case BACKPAT: break; default: GrayCheck(Pen); fprintf(FP, " %s %s\n", GrayStr(Pen), gPsCmd[PS_SETGRAY]); break; } } if (!((colorDump || !useGray) && Pen==BACKPAT)) { if (preDumpSetup) PSUseArrow(); fprintf(FP, " %s\n", gPsCmd[PS_NEWPATH]); fprintf(FP, " %1d %1d %.3f %.3f %1d %1d TGAT\n", HeadV->x, HeadV->y, daw, dah, dx, dy); } if (colorDump || !useGray) { switch (Pen) { case SOLIDPAT: fprintf(FP, " %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_FILL]); break; case BACKPAT: break; default: if (preDumpSetup) PSUseColorPattern(); fprintf(FP, " %s %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_EOCLIP], gPsCmd[PS_NEWPATH]); DumpPatFill(FP, Pen, bbox, 3, TRUE); break; } } else { switch (Pen) { case SOLIDPAT: fprintf(FP, " %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_FILL]); break; case BACKPAT: if (!TransPat) { fprintf(FP, " %s 1 %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_SETGRAY], gPsCmd[PS_FILL]); } break; default: fprintf(FP, " %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_FILL]); break; } } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); } /* --------------------- DumpPolyObj() --------------------- */ static int CalcArrowRetreatPoint(TailV, HeadV, ArrowW, aw_spec, ReturnV) IntPoint *TailV, *HeadV, *ReturnV; int ArrowW; char *aw_spec; /* HeadV is where the arrow tip is */ { int dx, dy; double len, sin, cos, daw; dx = HeadV->x - TailV->x; dy = HeadV->y - TailV->y; if (dx == 0 && dy == 0) return FALSE; len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin = ((double)dy) / len; cos = ((double)dx) / len; daw = GetWidthInDouble(ArrowW, aw_spec, NULL); ReturnV->x = round(HeadV->x-RETREAT*daw*cos); ReturnV->y = round(HeadV->y-RETREAT*daw*sin); return TRUE; } static void DumpPolyPath(FP, ObjPtr, Vs, NumPts, Smooth, Style, Width, ArrowW, ArrowH, width_spec, aw_spec, ah_spec, Pen, Fill, Curved, Dash, Indent, TransPat) FILE *FP; register struct ObjRec *ObjPtr; IntPoint *Vs; int NumPts, Style, Width, ArrowW, ArrowH; char *width_spec, *aw_spec, *ah_spec; int Pen, Fill, Curved, Dash, Indent, TransPat; char *Smooth; { register int i, dx, dy; int retracted_arrow, color_index=ObjPtr->color, w_is_int=TRUE; double daw, dw; retracted_arrow = (RetractedArrowAttr(ObjPtr) || AutoRetractedArrowAttr(ObjPtr, TRUE)); daw = GetWidthInDouble(ArrowW, aw_spec, NULL); dw = GetWidthInDouble(Width, width_spec, &w_is_int); if (Fill == (-1) && Pen != (-1)) { /* dumping the pen */ if (Dash != 0) { for (i=0; i < Indent+3; i++) fprintf(FP, " "); fprintf(FP, "["); for (i = 0; i < dashListLength[Dash]-1; i++) { fprintf(FP, "%1d ", (int)(dashList[Dash][i])); } fprintf(FP, "%1d] 0 %s\n", (int)(dashList[Dash][dashListLength[Dash]-1]), gPsCmd[PS_SETDASH]); } } else if (Fill != (-1) && Pen == (-1)) { /* dumping the fill */ if (Fill > BACKPAT) { if (colorDump || !useGray) { for (i=0; i < Indent; i++) fprintf(FP, " "); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if (preDumpSetup) PSUseColorPattern(); if (!TransPat) { DumpPolyPath(FP, ObjPtr, Vs, NumPts, Smooth, LS_PLAIN, Width, ArrowW, ArrowH, width_spec, aw_spec, ah_spec, (-1), BACKPAT, Curved, Dash, Indent, TransPat); } } else { for (i=0; i < Indent; i++) fprintf(FP, " "); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); GrayCheck(Fill); for (i=0; i < Indent+3; i++) fprintf(FP, " "); fprintf(FP, "%s %s\n", GrayStr(Fill), gPsCmd[PS_SETGRAY]); } } } #ifndef DONT_DRAW_ZERO_LENGTH_POLY_AS_DOT if (NumPts == 2 && Vs[0].x == Vs[1].x && Vs[0].y == Vs[1].y) { for (i=0; i < Indent+3; i++) fprintf(FP, " "); fprintf(FP, "1 %s\n", gPsCmd[PS_SETLINECAP]); } #endif /* ~DONT_DRAW_ZERO_LENGTH_POLY_AS_DOT */ for (i=0; i < Indent+3; i++) fprintf(FP, " "); fprintf(FP, "%s\n", gPsCmd[PS_NEWPATH]); for (i=0; i < Indent+3; i++) fprintf(FP, " "); fprintf(FP, " %1d %1d %s\n", Vs[0].x, Vs[0].y, gPsCmd[PS_MOVETO]); if (Style & LS_LEFT) { dx = Vs[1].x - Vs[0].x; dy = Vs[1].y - Vs[0].y; if (dx != 0 || dy != 0) { if (!retracted_arrow) { if (ObjPtr->ctm == NULL) { for (i=0; i < Indent+6; i++) fprintf(FP, " "); fprintf(FP, "%1d %1d atan %s cos %.3f %s exch sin %.3f %s %s\n", dy, dx, gPsCmd[PS_DUP], daw, gPsCmd[PS_MUL], daw, gPsCmd[PS_MUL], gPsCmd[PS_RMOVETO]); } else { IntPoint ip0, ip1, ip2, ip3; TransformObjectV(ObjPtr, &Vs[1], &ip0); TransformObjectV(ObjPtr, &Vs[0], &ip1); if (CalcArrowRetreatPoint(&ip0, &ip1, ArrowW, aw_spec, &ip2)) { ReversedTransformObjectV(ObjPtr, &ip2, &ip3); for (i=0; i < Indent+6; i++) fprintf(FP, " "); fprintf(FP, "%1d %1d %s\n", ip3.x, ip3.y, gPsCmd[PS_MOVETO]); } } } } } if (Style & LS_RIGHT) { if (Curved == LT_INTSPLINE) { DumpCurvedPolyPoints(FP, Curved, NumPts, Vs, Indent+6); } else { DumpMultiCurvedPolyPoints(FP, Smooth, Style, Curved, NumPts, Vs, Indent+6); } dx = Vs[NumPts-1].x - Vs[NumPts-2].x; dy = Vs[NumPts-1].y - Vs[NumPts-2].y; if (dx != 0 || dy != 0) { if (retracted_arrow) { for (i=0; i < Indent+6; i++) fprintf(FP, " "); fprintf(FP, "%1d %1d", Vs[NumPts-1].x, Vs[NumPts-1].y); } else { if (ObjPtr->ctm == NULL) { for (i=0; i < Indent+6; i++) fprintf(FP, " "); fprintf(FP, "%1d %1d atan %s cos %.3f %s %1d exch %s\n", dy, dx, gPsCmd[PS_DUP], daw, gPsCmd[PS_MUL], Vs[NumPts-1].x, gPsCmd[PS_SUB]); for (i=0; i < Indent+6; i++) fprintf(FP, " "); fprintf(FP, "exch sin %.3f %s %1d exch %s", daw, gPsCmd[PS_MUL], Vs[NumPts-1].y, gPsCmd[PS_SUB]); } else { IntPoint ip0, ip1, ip2, ip3; TransformObjectV(ObjPtr, &Vs[NumPts-2], &ip0); TransformObjectV(ObjPtr, &Vs[NumPts-1], &ip1); if (CalcArrowRetreatPoint(&ip0, &ip1, ArrowW, aw_spec, &ip2)) { ReversedTransformObjectV(ObjPtr, &ip2, &ip3); for (i=0; i < Indent+6; i++) fprintf(FP, " "); fprintf(FP, "%1d %1d", ip3.x, ip3.y); } } } switch (Curved) { case LT_STRAIGHT: case LT_SPLINE: case LT_STRUCT_SPLINE: if (NumPts <= 2 || (Smooth != NULL && !Smooth[NumPts-2])) { fprintf(FP, " %s", gPsCmd[PS_LINETO]); } else { fprintf(FP, " %s", gPsCmd[PS_CURVETO]); } break; case LT_INTSPLINE: if (NumPts <= 2) { fprintf(FP, " %s", gPsCmd[PS_LINETO]); } else { fprintf(FP, " %s", gPsCmd[PS_CURVETO]); } break; } } fprintf(FP, "\n"); } else if (Curved == LT_INTSPLINE) { DumpCurvedPolyPoints(FP, Curved, NumPts, Vs, Indent+6); if (NumPts <= 2) { for (i=0; i < Indent+6; i++) fprintf(FP, " "); fprintf(FP, "%1d %1d %s\n",Vs[NumPts-1].x,Vs[NumPts-1].y, gPsCmd[PS_LINETO]); } else { for (i=0; i < Indent+6; i++) fprintf(FP, " "); fprintf(FP, "%1d %1d %s\n",Vs[NumPts-1].x,Vs[NumPts-1].y, gPsCmd[PS_CURVETO]); } } else { DumpMultiCurvedPolyPoints(FP, Smooth, Style, Curved, NumPts, Vs, Indent+6); } if (Fill == (-1) && Pen != (-1)) { /* dumping the pen */ for (i=0; i < Indent+3; i++) fprintf(FP, " "); fprintf(FP, "%s\n", &(gPsCmd[PS_TGIFSETMATRIX])[1]); for (i=0; i < Indent+3; i++) fprintf(FP, " "); if (w_is_int) { fprintf(FP, "%1d %s\n", Width, gPsCmd[PS_SETLINEWIDTH]); } else { fprintf(FP, "%.3f %s\n", dw, gPsCmd[PS_SETLINEWIDTH]); } for (i=0; i < Indent+3; i++) fprintf(FP, " "); switch (Pen) { case SOLIDPAT: fprintf(FP, "%s\n", gPsCmd[PS_STROKE]); break; case BACKPAT: if (!TransPat) { fprintf(FP, "1 %s %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_STROKE]); } break; default: if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); fprintf(FP, "%s\n", gPsCmd[PS_FLATTENPATH]); for (i=0; i < Indent+3; i++) fprintf(FP, " "); DumpPatFill(FP, Pen, ObjPtr->bbox, 0, TRUE); } else { GrayCheck(Pen); fprintf(FP, "%s %s\n", GrayStr(Pen), gPsCmd[PS_SETGRAY]); for (i=0; i < Indent+3; i++) fprintf(FP, " "); fprintf(FP, "%s\n", gPsCmd[PS_STROKE]); } break; } if (Dash != 0) { for (i=0; i < Indent+3; i++) fprintf(FP, " "); fprintf(FP, "[] 0 %s\n", gPsCmd[PS_SETDASH]); } if (Width != 1) { for (i=0; i < Indent+3; i++) fprintf(FP, " "); fprintf(FP, "1 %s\n", gPsCmd[PS_SETLINEWIDTH]); } } else if (Fill != (-1) && Pen == (-1)) { /* dumping the fill */ for (i=0; i < Indent+3; i++) fprintf(FP, " "); switch (Fill) { case SOLIDPAT: fprintf(FP, "%s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_EOFILL]); break; case BACKPAT: if (!TransPat) { fprintf(FP, "%s 1 %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_SETGRAY], gPsCmd[PS_EOFILL]); for (i=0; i < Indent+3; i++) fprintf(FP, " "); DumpRGBColorLine(FP, color_index, 0, TRUE); } break; default: if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); fprintf(FP, "%s %s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_EOCLIP], gPsCmd[PS_NEWPATH]); for (i=0; i < Indent+3; i++) fprintf(FP, " "); DumpPatFill(FP, Fill, ObjPtr->bbox, 0, TRUE); } else { fprintf(FP, "%s %s\n", gPsCmd[PS_CLOSEPATH], gPsCmd[PS_EOFILL]); } for (i=0; i < Indent; i++) fprintf(FP, " "); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); break; } } } void DumpPolyObj(FP, ObjPtr) FILE *FP; register struct ObjRec *ObjPtr; { IntPoint *intv=NULL, *v=NULL; int num_pts, trans_pat, fill, pen, width, curved, dash, color_index; int style, aw, ah, rotation, intn, retracted_arrow; char *smooth=NULL, *width_spec=NULL, *aw_spec=NULL, *ah_spec=NULL; trans_pat = ObjPtr->trans_pat; fill = ObjPtr->detail.p->fill; width = ObjPtr->detail.p->width; aw = ObjPtr->detail.p->aw; ah = ObjPtr->detail.p->ah; width_spec = ObjPtr->detail.p->width_spec; aw_spec = ObjPtr->detail.p->aw_spec; ah_spec = ObjPtr->detail.p->ah_spec; pen = ObjPtr->detail.p->pen; style = ObjPtr->detail.p->style; curved = ObjPtr->detail.p->curved; dash = ObjPtr->detail.p->dash; rotation = ObjPtr->rotation; if (curved == LT_STRUCT_SPLINE) { v = ObjPtr->detail.p->ssvlist; num_pts = ObjPtr->detail.p->ssn; smooth = ObjPtr->detail.p->ssmooth; } else { v = ObjPtr->detail.p->vlist; num_pts = ObjPtr->detail.p->n; smooth = ObjPtr->detail.p->smooth; } intv = ObjPtr->detail.p->intvlist; intn = ObjPtr->detail.p->intn; if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } fprintf(FP, "%% POLY/OPEN-SPLINE\n"); color_index = ObjPtr->color; DumpRGBColorLine(FP, color_index, 0, TRUE); if (ObjPtr->ctm != NULL) { float m[6]; fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); m[CTM_SX] = ((float)ObjPtr->ctm->m[CTM_SX])/((float)1000.0); m[CTM_SY] = ((float)ObjPtr->ctm->m[CTM_SY])/((float)1000.0); m[CTM_SIN] = ((float)ObjPtr->ctm->m[CTM_SIN])/((float)1000.0); m[CTM_MSIN] = ((float)ObjPtr->ctm->m[CTM_MSIN])/((float)1000.0); fprintf(FP, " %1d %1d %s\n", ObjPtr->x, ObjPtr->y, gPsCmd[PS_TRANSLATE]); fprintf(FP, " [%.3f %.3f %.3f %.3f %1d %1d] %s\n", m[CTM_SX], m[CTM_SIN], m[CTM_MSIN], m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY], gPsCmd[PS_CONCAT]); fprintf(FP, " %1d %s %1d %s %s\n", ObjPtr->x, gPsCmd[PS_NEG], ObjPtr->y, gPsCmd[PS_NEG], gPsCmd[PS_TRANSLATE]); } if (fill != NONEPAT && num_pts > 2 && !(fill == BACKPAT && trans_pat)) { if (curved != LT_INTSPLINE) { DumpPolyPath(FP, ObjPtr, v, num_pts, smooth, LS_PLAIN, width, aw, ah, width_spec, aw_spec, ah_spec, (-1), fill, curved, dash, (fill > BACKPAT ? 0 : (-3)), trans_pat); } else { DumpPolyPath(FP, ObjPtr, intv, intn, smooth, LS_PLAIN, width, aw, ah, width_spec, aw_spec, ah_spec, (-1), fill, curved, dash, (fill > BACKPAT ? 0 : (-3)), trans_pat); } } if (pen == NONEPAT || (pen == BACKPAT && trans_pat)) { if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); return; } fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if ((colorDump || !useGray) && pen > BACKPAT && !trans_pat) { fprintf(FP, " %s\n", gPsCmd[PS_GSAVE]); if (curved != LT_INTSPLINE) { DumpPolyPath(FP, ObjPtr, v, num_pts, smooth, style, width, aw, ah, width_spec, aw_spec, ah_spec, BACKPAT, (-1), curved, 0, 3, trans_pat); } else { DumpPolyPath(FP, ObjPtr, intv, intn, smooth, style, width, aw, ah, width_spec, aw_spec, ah_spec, BACKPAT, (-1), curved, 0, 3, trans_pat); } fprintf(FP, " %s\n", gPsCmd[PS_GRESTORE]); } if (curved != LT_INTSPLINE) { DumpPolyPath(FP, ObjPtr, v, num_pts, smooth, style, width, aw, ah, width_spec, aw_spec, ah_spec, pen, (-1), curved, dash, 0, trans_pat); } else { DumpPolyPath(FP, ObjPtr, intv, intn, smooth, style, width, aw, ah, width_spec, aw_spec, ah_spec, pen, (-1), curved, dash, 0, trans_pat); } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); retracted_arrow = (RetractedArrowAttr(ObjPtr) || AutoRetractedArrowAttr(ObjPtr, TRUE)); if (ObjPtr->ctm == NULL) { if (curved != LT_INTSPLINE) { switch (style) { case LS_PLAIN: break; case LS_LEFT: if (retracted_arrow) { DumpArrow(FP, &v[2], &v[1], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { DumpArrow(FP, &v[1], &v[0], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; case LS_RIGHT: if (retracted_arrow) { DumpArrow(FP, &v[num_pts-3], &v[num_pts-2], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { DumpArrow(FP, &v[num_pts-2], &v[num_pts-1], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; case LS_DOUBLE: if (retracted_arrow) { DumpArrow(FP, &v[2], &v[1], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); DumpArrow(FP, &v[num_pts-3], &v[num_pts-2], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { DumpArrow(FP, &v[1], &v[0], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); DumpArrow(FP, &v[num_pts-2], &v[num_pts-1], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; } } else { switch (style) { case LS_PLAIN: break; case LS_LEFT: if (retracted_arrow) { DumpArrow(FP, &intv[2], &v[1], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { DumpArrow(FP, &intv[1], &intv[0], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; case LS_RIGHT: if (retracted_arrow) { DumpArrow(FP, &intv[intn-3], &v[num_pts-2], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { DumpArrow(FP, &intv[intn-2], &intv[intn-1], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; case LS_DOUBLE: if (retracted_arrow) { DumpArrow(FP, &intv[2], &v[1], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); DumpArrow(FP, &intv[intn-3], &v[num_pts-2], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { DumpArrow(FP, &intv[1], &intv[0], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); DumpArrow(FP, &intv[intn-2], &intv[intn-1], aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; } } } else { IntPoint ip0, ip1; if (curved != LT_INTSPLINE) { switch (style) { case LS_PLAIN: break; case LS_LEFT: if (retracted_arrow) { TransformObjectV(ObjPtr, &v[2], &ip0); TransformObjectV(ObjPtr, &v[1], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { TransformObjectV(ObjPtr, &v[1], &ip0); TransformObjectV(ObjPtr, &v[0], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; case LS_RIGHT: if (retracted_arrow) { TransformObjectV(ObjPtr, &v[num_pts-3], &ip0); TransformObjectV(ObjPtr, &v[num_pts-2], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { TransformObjectV(ObjPtr, &v[num_pts-2], &ip0); TransformObjectV(ObjPtr, &v[num_pts-1], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; case LS_DOUBLE: if (retracted_arrow) { TransformObjectV(ObjPtr, &v[2], &ip0); TransformObjectV(ObjPtr, &v[1], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); TransformObjectV(ObjPtr, &v[num_pts-3], &ip0); TransformObjectV(ObjPtr, &v[num_pts-2], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { TransformObjectV(ObjPtr, &v[1], &ip0); TransformObjectV(ObjPtr, &v[0], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); TransformObjectV(ObjPtr, &v[num_pts-2], &ip0); TransformObjectV(ObjPtr, &v[num_pts-1], &ip1); DumpArrow(FP, &ip0, &ip1,aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; } } else { switch (style) { case LS_PLAIN: break; case LS_LEFT: if (retracted_arrow) { TransformObjectV(ObjPtr, &intv[2], &ip0); TransformObjectV(ObjPtr, &v[1], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { TransformObjectV(ObjPtr, &intv[1], &ip0); TransformObjectV(ObjPtr, &intv[0], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; case LS_RIGHT: if (retracted_arrow) { TransformObjectV(ObjPtr, &intv[intn-3], &ip0); TransformObjectV(ObjPtr, &v[num_pts-2], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { TransformObjectV(ObjPtr, &intv[intn-2], &ip0); TransformObjectV(ObjPtr, &intv[intn-1], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; case LS_DOUBLE: if (retracted_arrow) { TransformObjectV(ObjPtr, &intv[2], &ip0); TransformObjectV(ObjPtr, &v[1], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); TransformObjectV(ObjPtr, &intv[intn-3], &ip0); TransformObjectV(ObjPtr, &v[num_pts-2], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } else { TransformObjectV(ObjPtr, &intv[1], &ip0); TransformObjectV(ObjPtr, &intv[0], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); TransformObjectV(ObjPtr, &intv[intn-2], &ip0); TransformObjectV(ObjPtr, &intv[intn-1], &ip1); DumpArrow(FP, &ip0, &ip1, aw, ah, aw_spec, ah_spec, pen, trans_pat, color_index); } break; } } } if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); } /* --------------------- NeedsToCachePolyObj() --------------------- */ int NeedsToCachePolyObj(ObjPtr) struct ObjRec *ObjPtr; { return (ObjPtr->ctm != NULL); } /* --------------------- DrawPolyObj() --------------------- */ static void MakeCachedPoly(ObjPtr) struct ObjRec *ObjPtr; { int i; struct PolyRec *poly_ptr=ObjPtr->detail.p; IntPoint *pv=poly_ptr->vlist, *intvs=NULL, *vs=NULL; int n=poly_ptr->n, intn=0; if (ObjPtr->ctm == NULL) return; if (poly_ptr->rotated_vlist != NULL) free(poly_ptr->rotated_vlist); if (poly_ptr->rotated_asvlist != NULL) free(poly_ptr->rotated_asvlist); poly_ptr->rotated_n = poly_ptr->rotated_asn = 0; poly_ptr->rotated_vlist = poly_ptr->rotated_asvlist = NULL; if (poly_ptr->curved == LT_STRUCT_SPLINE) { pv = poly_ptr->ssvlist; n = poly_ptr->ssn; } vs = (IntPoint*)malloc((n+1)*sizeof(IntPoint)); if (vs == NULL) FailAllocMessage(); for (i=0; i < n; i++) { int x, y; TransformPointThroughCTM(pv[i].x-ObjPtr->x, pv[i].y-ObjPtr->y, ObjPtr->ctm, &x, &y); vs[i].x = x+ObjPtr->x; vs[i].y = y+ObjPtr->y; } vs[n].x = vs[0].x; vs[n].y = vs[0].y; switch (poly_ptr->curved) { case LT_STRAIGHT: case LT_SPLINE: poly_ptr->rotated_vlist = MakeMultiSplinePolyVertex( poly_ptr->curved, &(poly_ptr->rotated_n), poly_ptr->smooth, drawOrigX, drawOrigY, n, vs); break; case LT_STRUCT_SPLINE: poly_ptr->rotated_vlist = MakeMultiSplinePolyVertex( poly_ptr->curved, &(poly_ptr->rotated_n), poly_ptr->ssmooth, drawOrigX, drawOrigY, n, vs); break; case LT_INTSPLINE: poly_ptr->rotated_vlist = MakeIntSplinePolyVertex( &(poly_ptr->rotated_n), &(intn), &(intvs), drawOrigX, drawOrigY, n, vs); break; } poly_ptr->rotated_vlist[poly_ptr->rotated_n].x = poly_ptr->rotated_vlist[0].x; poly_ptr->rotated_vlist[poly_ptr->rotated_n].y = poly_ptr->rotated_vlist[0].y; if (poly_ptr->style != LS_PLAIN && !RetractedArrowAttr(ObjPtr) && !AutoRetractedArrowAttr(ObjPtr,TRUE)) { int aw=poly_ptr->aw, dx, dy; double len, sin, cos; if (aw == 0) aw = 1; switch (poly_ptr->curved) { case LT_STRAIGHT: case LT_SPLINE: case LT_STRUCT_SPLINE: dx = vs[1].x - vs[0].x; dy = vs[1].y - vs[0].y; if ((poly_ptr->style & LS_LEFT) && (dx != 0 || dy != 0)) { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin = ((double)dy)/len; cos = ((double)dx)/len; vs[0].x = round(vs[0].x+RETREAT*aw*cos); vs[0].y = round(vs[0].y+RETREAT*aw*sin); } dx = vs[n-1].x - vs[n-2].x; dy = vs[n-1].y - vs[n-2].y; if ((poly_ptr->style & LS_RIGHT) && (dx != 0 || dy != 0)) { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin = ((double)dy)/len; cos = ((double)dx)/len; vs[n-1].x = round(vs[n-1].x-(RETREAT*aw*cos)); vs[n-1].y = round(vs[n-1].y-(RETREAT*aw*sin)); } break; case LT_INTSPLINE: dx = intvs[1].x - intvs[0].x; dy = intvs[1].y - intvs[0].y; if ((poly_ptr->style & LS_LEFT) && (dx != 0 || dy != 0)) { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin = ((double)dy)/len; cos = ((double)dx)/len; intvs[0].x = round(intvs[0].x+RETREAT*aw*cos); intvs[0].y = round(intvs[0].y+RETREAT*aw*sin); } dx = intvs[intn-1].x - intvs[intn-2].x; dy = intvs[intn-1].y - intvs[intn-2].y; if ((poly_ptr->style & LS_RIGHT) && (dx != 0 || dy != 0)) { len = (double)sqrt((double)(((double)dx)*((double)dx) + ((double)dy)*((double)dy))); sin = ((double)dy)/len; cos = ((double)dx)/len; intvs[intn-1].x = round(intvs[intn-1].x-(RETREAT*aw*cos)); intvs[intn-1].y = round(intvs[intn-1].y-(RETREAT*aw*sin)); } break; } } if (poly_ptr->style != LS_PLAIN) { switch (poly_ptr->curved) { case LT_STRAIGHT: case LT_SPLINE: poly_ptr->rotated_asvlist = MakeMultiSplinePolyVertex( poly_ptr->curved, &(poly_ptr->rotated_asn), poly_ptr->smooth, drawOrigX, drawOrigY, n, vs); break; case LT_STRUCT_SPLINE: poly_ptr->rotated_asvlist = MakeMultiSplinePolyVertex( poly_ptr->curved, &(poly_ptr->rotated_asn), poly_ptr->ssmooth, drawOrigX, drawOrigY, n, vs); break; case LT_INTSPLINE: poly_ptr->rotated_asvlist = MakeSplinePolyVertex( 0, poly_ptr->curved, &(poly_ptr->rotated_asn), drawOrigX, drawOrigY, intn, intvs); break; } } free(vs); if (intvs != NULL) free(intvs); } static void SetArrowVsForDraw(obj_ptr, retracted_arrow, real_x_off, real_y_off, v0, v1, vnminus2, vnminus1) struct ObjRec *obj_ptr; int retracted_arrow, real_x_off, real_y_off; XPoint *v0, *v1, *vnminus2, *vnminus1; { struct PolyRec *poly_ptr=obj_ptr->detail.p; int n=poly_ptr->n; if (obj_ptr->ctm == NULL) { if (poly_ptr->curved != LT_INTSPLINE) { IntPoint *vs=poly_ptr->vlist; if (poly_ptr->curved == LT_STRUCT_SPLINE) { n = poly_ptr->ssn; vs = poly_ptr->ssvlist; } if (retracted_arrow) { v0->x = ZOOMED_SIZE(vs[1].x-real_x_off); v0->y = ZOOMED_SIZE(vs[1].y-real_y_off); v1->x = ZOOMED_SIZE(vs[2].x-real_x_off); v1->y = ZOOMED_SIZE(vs[2].y-real_y_off); vnminus2->x = ZOOMED_SIZE(vs[n-3].x-real_x_off); vnminus2->y = ZOOMED_SIZE(vs[n-3].y-real_y_off); vnminus1->x = ZOOMED_SIZE(vs[n-2].x-real_x_off); vnminus1->y = ZOOMED_SIZE(vs[n-2].y-real_y_off); } else { v0->x = ZOOMED_SIZE(vs[0].x-real_x_off); v0->y = ZOOMED_SIZE(vs[0].y-real_y_off); v1->x = ZOOMED_SIZE(vs[1].x-real_x_off); v1->y = ZOOMED_SIZE(vs[1].y-real_y_off); vnminus2->x = ZOOMED_SIZE(vs[n-2].x-real_x_off); vnminus2->y = ZOOMED_SIZE(vs[n-2].y-real_y_off); vnminus1->x = ZOOMED_SIZE(vs[n-1].x-real_x_off); vnminus1->y = ZOOMED_SIZE(vs[n-1].y-real_y_off); } } else { int intn=poly_ptr->intn; IntPoint *intvlist=poly_ptr->intvlist; if (retracted_arrow) { int n=poly_ptr->n; IntPoint *vs=poly_ptr->vlist; v0->x = ZOOMED_SIZE(vs[1].x-real_x_off); v0->y = ZOOMED_SIZE(vs[1].y-real_y_off); v1->x = ZOOMED_SIZE(intvlist[2].x-real_x_off); v1->y = ZOOMED_SIZE(intvlist[2].y-real_y_off); vnminus2->x = ZOOMED_SIZE(intvlist[intn-3].x-real_x_off); vnminus2->y = ZOOMED_SIZE(intvlist[intn-3].y-real_y_off); vnminus1->x = ZOOMED_SIZE(vs[n-2].x-real_x_off); vnminus1->y = ZOOMED_SIZE(vs[n-2].y-real_y_off); } else { v0->x = ZOOMED_SIZE(intvlist[0].x-real_x_off); v0->y = ZOOMED_SIZE(intvlist[0].y-real_y_off); v1->x = ZOOMED_SIZE(intvlist[1].x-real_x_off); v1->y = ZOOMED_SIZE(intvlist[1].y-real_y_off); vnminus2->x = ZOOMED_SIZE(intvlist[intn-2].x-real_x_off); vnminus2->y = ZOOMED_SIZE(intvlist[intn-2].y-real_y_off); vnminus1->x = ZOOMED_SIZE(intvlist[intn-1].x-real_x_off); vnminus1->y = ZOOMED_SIZE(intvlist[intn-1].y-real_y_off); } } } else { int x, y; if (poly_ptr->curved != LT_INTSPLINE) { IntPoint *vs=poly_ptr->vlist; if (poly_ptr->curved == LT_STRUCT_SPLINE) { n = poly_ptr->ssn; vs = poly_ptr->ssvlist; } if (retracted_arrow) { TransformPointThroughCTM(vs[1].x-obj_ptr->x, vs[1].y-obj_ptr->y, obj_ptr->ctm, &x, &y); v0->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); v0->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(vs[2].x-obj_ptr->x, vs[2].y-obj_ptr->y, obj_ptr->ctm, &x, &y); v1->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); v1->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(vs[n-3].x-obj_ptr->x, vs[n-3].y-obj_ptr->y, obj_ptr->ctm, &x, &y); vnminus2->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); vnminus2->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(vs[n-2].x-obj_ptr->x, vs[n-2].y-obj_ptr->y, obj_ptr->ctm, &x, &y); vnminus1->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); vnminus1->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); } else { TransformPointThroughCTM(vs[0].x-obj_ptr->x, vs[0].y-obj_ptr->y, obj_ptr->ctm, &x, &y); v0->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); v0->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(vs[1].x-obj_ptr->x, vs[1].y-obj_ptr->y, obj_ptr->ctm, &x, &y); v1->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); v1->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(vs[n-2].x-obj_ptr->x, vs[n-2].y-obj_ptr->y, obj_ptr->ctm, &x, &y); vnminus2->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); vnminus2->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(vs[n-1].x-obj_ptr->x, vs[n-1].y-obj_ptr->y, obj_ptr->ctm, &x, &y); vnminus1->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); vnminus1->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); } } else { int intn=poly_ptr->intn; IntPoint *intvlist=poly_ptr->intvlist; if (retracted_arrow) { int n=poly_ptr->n; IntPoint *vs=poly_ptr->vlist; TransformPointThroughCTM(vs[1].x-obj_ptr->x, vs[1].y-obj_ptr->y, obj_ptr->ctm, &x, &y); v0->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); v0->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(intvlist[2].x-obj_ptr->x, intvlist[2].y-obj_ptr->y, obj_ptr->ctm, &x, &y); v1->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); v1->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(intvlist[intn-3].x-obj_ptr->x, intvlist[intn-3].y-obj_ptr->y, obj_ptr->ctm, &x, &y); vnminus2->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); vnminus2->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(vs[n-2].x-obj_ptr->x, vs[n-2].y-obj_ptr->y, obj_ptr->ctm, &x, &y); vnminus1->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); vnminus1->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); } else { TransformPointThroughCTM(intvlist[0].x-obj_ptr->x, intvlist[0].y-obj_ptr->y, obj_ptr->ctm, &x, &y); v0->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); v0->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(intvlist[1].x-obj_ptr->x, intvlist[1].y-obj_ptr->y, obj_ptr->ctm, &x, &y); v1->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); v1->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(intvlist[intn-2].x-obj_ptr->x, intvlist[intn-2].y-obj_ptr->y, obj_ptr->ctm, &x, &y); vnminus2->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); vnminus2->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); TransformPointThroughCTM(intvlist[intn-1].x-obj_ptr->x, intvlist[intn-1].y-obj_ptr->y, obj_ptr->ctm, &x, &y); vnminus1->x = ZOOMED_SIZE(x+obj_ptr->x-real_x_off); vnminus1->y = ZOOMED_SIZE(y+obj_ptr->y-real_y_off); } } } } void DrawPolyObj(Win, XOff, YOff, ObjPtr) Window Win; int XOff, YOff; struct ObjRec *ObjPtr; { struct PolyRec *poly_ptr=ObjPtr->detail.p; XPoint *v, tmp_v[4]; XPoint v0, v1, vnminus2, vnminus1; int trans_pat, pen, width, pixel, fill, n, dash, real_x_off, real_y_off; int style, aw, ah, num_pts, left_dx, left_dy, right_dx, right_dy; int retracted_arrow=FALSE; short tmps; double len, sin, cos; XGCValues values; trans_pat = ObjPtr->trans_pat; n = poly_ptr->n; fill = poly_ptr->fill; width = poly_ptr->width; aw = poly_ptr->aw; ah = poly_ptr->ah; pen = poly_ptr->pen; style = poly_ptr->style; dash = poly_ptr->dash; pixel = colorPixels[ObjPtr->color]; if (NeedsToCachePolyObj(ObjPtr) && poly_ptr->rotated_vlist==NULL) { MakeCachedPoly(ObjPtr); } if (userDisableRedraw) return; if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } real_x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); real_y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); v = poly_ptr->svlist; num_pts = poly_ptr->sn; if (v != NULL) { v[num_pts].x = v[0].x; v[num_pts].y = v[0].y; } if (fill != NONEPAT) { values.foreground = GetDrawingBgPixel(fill, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[fill]; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple, &values); if (ObjPtr->ctm == NULL) { XFillPolygon(mainDisplay, Win, drawGC, v, num_pts+1, Complex, CoordModeOrigin); } else { XFillPolygon(mainDisplay, Win, drawGC, poly_ptr->rotated_vlist, poly_ptr->rotated_n+1, Complex, CoordModeOrigin); } } if (pen == NONEPAT || (pen == BACKPAT && trans_pat)) return; retracted_arrow = (RetractedArrowAttr(ObjPtr) || AutoRetractedArrowAttr(ObjPtr, TRUE)); SetArrowVsForDraw(ObjPtr, retracted_arrow, real_x_off, real_y_off, &v0, &v1, &vnminus2, &vnminus1); aw = ZOOMED_SIZE(aw); if (aw == 0) aw = 1; ah = ZOOMED_SIZE(ah); if (ah == 0) ah = 1; values.foreground = GetDrawingBgPixel(pen, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[pen]; values.line_width = ZOOMED_SIZE(width); #ifdef NO_THIN_LINE if (values.line_width < 1) values.line_width = 1; #endif values.join_style = JoinBevel; if (dash != 0) { XSetDashes(mainDisplay, drawGC, 0, dashList[dash], dashListLength[dash]); values.line_style = LineOnOffDash; } else { values.line_style = LineSolid; } XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | GCLineStyle | GCJoinStyle, &values); left_dx = v1.x - v0.x; left_dy = v1.y - v0.y; if ((style & LS_LEFT) && (left_dx != 0 || left_dy != 0)) { /* adjust the first point */ len = (double)sqrt((double)(((double)left_dx)*((double)left_dx) + ((double)left_dy)*((double)left_dy))); sin = ((double)left_dy)/len; cos = ((double)left_dx)/len; tmp_v[0].x = tmp_v[3].x = v0.x; tmp_v[0].y = tmp_v[3].y = v0.y; tmps = round(v0.x + aw*cos - ah*sin); tmp_v[1].x = tmps; tmps = round(v0.y + aw*sin + ah*cos); tmp_v[1].y = tmps; tmps = round(v0.x + aw*cos + ah*sin); tmp_v[2].x = tmps; tmps = round(v0.y + aw*sin - ah*cos); tmp_v[2].y = tmps; XFillPolygon(mainDisplay, Win, drawGC, tmp_v, 4, Convex, CoordModeOrigin); } right_dx = vnminus1.x - vnminus2.x; right_dy = vnminus1.y - vnminus2.y; if ((style & LS_RIGHT) && (right_dx != 0 || right_dy != 0)) { /* adjust the last point */ len = (double)sqrt((double)(((double)right_dx)*((double)right_dx) + ((double)right_dy)*((double)right_dy))); sin = ((double)right_dy)/len; cos = ((double)right_dx)/len; tmp_v[0].x = tmp_v[3].x = vnminus1.x; tmp_v[0].y = tmp_v[3].y = vnminus1.y; tmps = round(vnminus1.x - aw*cos + ah*sin); tmp_v[1].x = tmps; tmps = round(vnminus1.y - aw*sin - ah*cos); tmp_v[1].y = tmps; tmps = round(vnminus1.x - aw*cos - ah*sin); tmp_v[2].x = tmps; tmps = round(vnminus1.y - aw*sin + ah*cos); tmp_v[2].y = tmps; XFillPolygon(mainDisplay, Win, drawGC, tmp_v, 4, Convex, CoordModeOrigin); } if (style != LS_PLAIN) { if (ObjPtr->ctm == NULL) { MyDrawLines(mainDisplay, Win, drawGC, poly_ptr->asvlist, poly_ptr->asn); } else { MyDrawLines(mainDisplay, Win, drawGC, poly_ptr->rotated_asvlist, poly_ptr->rotated_asn); } } else { int draw_zero_length_poly=FALSE; #ifndef DONT_DRAW_ZERO_LENGTH_POLY_AS_DOT if (ObjPtr->ctm == NULL) { if (num_pts == 2 && v[0].x == v[1].x && v[0].y == v[1].y) { draw_zero_length_poly = TRUE; } } else { if (poly_ptr->rotated_n == 2 && poly_ptr->rotated_vlist[0].x == poly_ptr->rotated_vlist[1].x && poly_ptr->rotated_vlist[0].y == poly_ptr->rotated_vlist[1].y) { draw_zero_length_poly = TRUE; } } #endif /* ~DONT_DRAW_ZERO_LENGTH_POLY_AS_DOT */ if (ObjPtr->ctm == NULL) { if (draw_zero_length_poly) { values.cap_style = CapRound; XChangeGC(mainDisplay, drawGC, GCCapStyle, &values); } MyDrawLines(mainDisplay, Win, drawGC, v, num_pts); if (draw_zero_length_poly) { values.cap_style = CapButt; XChangeGC(mainDisplay, drawGC, GCCapStyle, &values); } } else { if (draw_zero_length_poly) { values.cap_style = CapRound; XChangeGC(mainDisplay, drawGC, GCCapStyle, &values); } MyDrawLines(mainDisplay, Win, drawGC, poly_ptr->rotated_vlist, poly_ptr->rotated_n); if (draw_zero_length_poly) { values.cap_style = CapButt; XChangeGC(mainDisplay, drawGC, GCCapStyle, &values); } } } values.join_style = JoinMiter; XChangeGC(mainDisplay, drawGC, GCJoinStyle, &values); } /* --------------------- SaveSmoothHinge() --------------------- */ static char hexValue[]="0123456789abcdef"; void SaveSmoothHinge(FP, Curved, NumPts, Smooth) FILE *FP; int Curved, NumPts; char *Smooth; { register int nibble_count=0, bit_count=0, data=0, j; if (Curved == LT_INTSPLINE || Smooth == NULL) return; for (j=0; j < NumPts; j++) { data = (Smooth[j] ? (data<<1) | 1 : (data<<1)); if (++bit_count == 4) { if (nibble_count++ == 64) { nibble_count = 1; if (fprintf(FP, "\n ") == EOF) writeFileFailed = TRUE; } if (fprintf(FP, "%c", hexValue[data]) == EOF) { writeFileFailed = TRUE; } bit_count = 0; data = 0; } } if ((NumPts & 0x3) != 0) { data <<= (4 - (NumPts & 0x3)); if (nibble_count++ == 64) { nibble_count = 1; if (fprintf(FP, "\n ") == EOF) writeFileFailed = TRUE; } if (fprintf(FP, "%c", hexValue[data]) == EOF) writeFileFailed = TRUE; } } /* --------------------- SavePolyObj() --------------------- */ static void SaveArrowSpec(FP, arrow_style, aw, ah, aindent, aw_spec, ah_spec, aindent_spec) FILE *FP; int arrow_style, aw, ah, aindent; char *aw_spec, *ah_spec, *aindent_spec; { if (fprintf(FP, "%1d,%1d,%1d,%1d,'%s','%s','%s'", arrow_style, aw, ah, aindent, aw_spec, ah_spec, aindent_spec) == EOF) { writeFileFailed = TRUE; } } void SavePolyObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { register int i, n; int count, line_cap=LCAP_BUTT; struct PolyRec *poly_ptr=ObjPtr->detail.p; n = poly_ptr->n; if (fprintf(FP, "poly('%s','',%1d,[\n\t", colorMenuItems[ObjPtr->color], poly_ptr->n) == EOF) { writeFileFailed = TRUE; } for (i=0, count = 0; i < n-1; i++) { if (fprintf(FP, "%1d,%1d,", poly_ptr->vlist[i].x, poly_ptr->vlist[i].y) == EOF) { writeFileFailed = TRUE; } if (++count == 8) { count = 0; if (fprintf(FP, "\n\t") == EOF) writeFileFailed = TRUE; } } if (fprintf(FP, "%1d,%1d],", poly_ptr->vlist[n-1].x, poly_ptr->vlist[n-1].y) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,'%s',%1d,%1d,", poly_ptr->style, poly_ptr->width, poly_ptr->pen, ObjPtr->id, poly_ptr->curved, poly_ptr->fill, poly_ptr->dash, ObjPtr->rotation, ObjPtr->locked, ObjPtr->ctm!=NULL, ObjPtr->invisible, poly_ptr->width_spec, ObjPtr->trans_pat, line_cap) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "\n \"") == EOF) writeFileFailed = TRUE; SaveSmoothHinge(FP, poly_ptr->curved, poly_ptr->n, poly_ptr->smooth); if (fprintf(FP, "\",") == EOF) writeFileFailed = TRUE; /* save an empty spline tension spec */ if (fprintf(FP, "\"\",") == EOF) writeFileFailed = TRUE; /* save the left arrow spec */ if (fprintf(FP, "[\n ") == EOF) writeFileFailed = TRUE; SaveArrowSpec(FP, ASTY_COMPAT, poly_ptr->aw, poly_ptr->ah, 0, poly_ptr->aw_spec, poly_ptr->ah_spec, "0"); if (fprintf(FP, "],[") == EOF) writeFileFailed = TRUE; /* save the right arrow spec */ SaveArrowSpec(FP, ASTY_COMPAT, poly_ptr->aw, poly_ptr->ah, 0, poly_ptr->aw_spec, poly_ptr->ah_spec, "0"); if (fprintf(FP, "],") == EOF) writeFileFailed = TRUE; if (ObjPtr->ctm != NULL && fprintf(FP, "[\n\t%1d,%1d,%1d,%1d,%1d,%1d,%g,%g,%g,%g,%1d,%1d],", ObjPtr->x, ObjPtr->y, ObjPtr->orig_obbox.ltx, ObjPtr->orig_obbox.lty, ObjPtr->orig_obbox.rbx, ObjPtr->orig_obbox.rby, ObjPtr->ctm->m[CTM_SX], ObjPtr->ctm->m[CTM_SIN], ObjPtr->ctm->m[CTM_MSIN], ObjPtr->ctm->m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY]) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, " "); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } /* --------------------- ReadSmoothHinge() --------------------- */ int ReadSmoothHinge(FP, Curved, NumPts, Smooth) FILE *FP; int Curved, NumPts; char *Smooth; { int num_nibbles=NumPts>>2, nibble_count=0, bit_count=0, j, k; char *c_ptr, inbuf[MAXSTRING+1]; if ((NumPts & 0x3) != 0) num_nibbles++; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; if (Curved == LT_INTSPLINE || Smooth == NULL) return TRUE; if ((c_ptr=strchr(inbuf, '"')) == NULL) { (void)sprintf(gszMsgBox, TgLoadString(STID_INVALID_SMOOTHHINGE_SPEC_POLY), scanFileName, scanLineNum); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return FALSE; } c_ptr++; for (j=0; *c_ptr != '"' && j < num_nibbles; j++) { int data=0; if (nibble_count++ == 64) { (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; for (c_ptr=inbuf; *c_ptr == ' '; c_ptr++) ; nibble_count = 1; } if (*c_ptr >= '0' && *c_ptr <= '9') { data = (int)(*c_ptr++) - (int)('0'); } else if (*c_ptr >= 'a' && *c_ptr <= 'f') { data = (int)(*c_ptr++) - (int)('a') + 10; } for (k = 0; k < 4; k++) { if (bit_count++ == NumPts) break; Smooth[(j<<2)+k] = (data & (1<<(3-k)) ? TRUE : FALSE); } } /* * Should be reading spline tension here. But this is not implemented, yet. */ return TRUE; } /* --------------------- ReadPolyObj() --------------------- */ void ReadPolyObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { register int i; struct PolyRec *poly_ptr; IntPoint *v; char color_str[40], bg_color_str[40], *s, inbuf[MAXSTRING+1]; char width_spec[40], aw_spec[40], ah_spec[40]; int num_pts, ltx=0, lty=0, rbx=0, rby=0, x, y, id=0; int initialized, rotation, count, new_alloc, line_cap=LCAP_BUTT; int style, width=0, pen, curved, fill, dash, locked=FALSE, trans_pat=FALSE; int aw=origArrowHeadW[6], ah=origArrowHeadH[6], arrow_style=ASTY_COMPAT; char *smooth=NULL; int real_x=0, real_y=0, transformed=FALSE, invisible=FALSE; struct XfrmMtrxRec *ctm=NULL; struct BBRec orig_obbox; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_str, sizeof(color_str)); if (fileVersion >= 37) { s = ParseStr(s, (int)',', bg_color_str, sizeof(bg_color_str)); } InitScan(s, "\t\n, []"); if (GETINT("poly", num_pts, "number of points") == INVALID) { return; } if (num_pts <= 0) { (void)sprintf(gszMsgBox, TgLoadString(STID_INVALID_NUM_PTS_IN_POLY), scanFileName, scanLineNum); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return; } *ObjPtr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (*ObjPtr == NULL) FailAllocMessage(); memset(*ObjPtr, 0, sizeof(struct ObjRec)); poly_ptr = (struct PolyRec *)malloc(sizeof(struct PolyRec)); if (poly_ptr == NULL) FailAllocMessage(); memset(poly_ptr, 0, sizeof(struct PolyRec)); if (num_pts == 1) { v = (IntPoint*)malloc(4*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); memset(v, 0, 4*sizeof(IntPoint)); smooth = (char*)malloc(4*sizeof(char)); if (smooth == NULL) FailAllocMessage(); memset(smooth, 0, 4*sizeof(char)); } else { v = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); memset(v, 0, (num_pts+1)*sizeof(IntPoint)); smooth = (char*)malloc((num_pts+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); memset(smooth, 0, (num_pts+1)*sizeof(char)); } initialized = FALSE; *width_spec = *aw_spec = *ah_spec = '\0'; if (fileVersion <= 13) { for (i=0; i < num_pts; i++) { if (GETINT("poly", x, "x") == INVALID || GETINT("poly", y, "y") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } v[i].x = x; v[i].y = y; if (!initialized) { initialized = TRUE; ltx = rbx = x; lty = rby = y; } else { if (x < ltx) ltx = x; if (y < lty) lty = y; if (x > rbx) rbx = x; if (y > rby) rby = y; } } } else { (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; s = inbuf; InitScan(s, "\t\n, []"); for (i=0, count = 0; i < num_pts; i++) { if (GETINT("poly", x, "x") == INVALID || GETINT("poly", y, "y") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } v[i].x = x; v[i].y = y; if (!initialized) { initialized = TRUE; ltx = rbx = x; lty = rby = y; } else { if (x < ltx) ltx = x; if (y < lty) lty = y; if (x > rbx) rbx = x; if (y > rby) rby = y; } if (++count == 8 && i != num_pts-1) { count = 0; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; s = inbuf; InitScan(s, "\t\n, []"); } } } if (num_pts == 1) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_SINGLE_PT_POLY_CONVERTED), v[0].x, v[0].y); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } v[1].x = v[0].x; v[1].y = v[0].y; num_pts = 2; } poly_ptr->n = num_pts; dash = 0; rotation = 0; if (fileVersion == INVALID) { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } id = objId++; fill = NONEPAT; if (width == LINE_CURVED) { width = 0; curved = TRUE; } else { curved = FALSE; } switch (width) { case 1: width = 3; break; case 2: width = 6; break; } } else if (fileVersion <= 3) { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID || GETINT("poly", id, "id") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; fill = NONEPAT; if (width == LINE_CURVED) { width = 0; curved = TRUE; } else { curved = FALSE; } switch (width) { case 1: width = 3; break; case 2: width = 6; break; } } else if (fileVersion <= 4) { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID || GETINT("poly", id, "id") == INVALID || GETINT("poly", curved, "curved") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; fill = NONEPAT; switch (width) { case 1: width = 3; break; case 2: width = 6; break; } } else if (fileVersion <= 5) { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID || GETINT("poly", id, "id") == INVALID || GETINT("poly", curved, "curved") == INVALID || GETINT("poly", fill, "fill") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; switch (width) { case 1: width = 3; break; case 2: width = 6; break; } } else if (fileVersion <= 8) { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID || GETINT("poly", id, "id") == INVALID || GETINT("poly", curved, "curved") == INVALID || GETINT("poly", fill, "fill") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 13) { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID || GETINT("poly", id, "id") == INVALID || GETINT("poly", curved, "curved") == INVALID || GETINT("poly", fill, "fill") == INVALID || GETINT("poly", dash, "dash") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 16) { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID || GETINT("poly", id, "id") == INVALID || GETINT("poly", curved, "curved") == INVALID || GETINT("poly", fill, "fill") == INVALID || GETINT("poly", dash, "dash") == INVALID || GETINT("poly", rotation, "rotation") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 25) { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID || GETINT("poly", id, "id") == INVALID || GETINT("poly", curved, "curved") == INVALID || GETINT("poly", fill, "fill") == INVALID || GETINT("poly", dash, "dash") == INVALID || GETINT("poly", rotation, "rotation") == INVALID || GETINT("poly", aw, "arrow head width") == INVALID || GETINT("poly", ah, "arrow head height") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 32) { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID || GETINT("poly", id, "id") == INVALID || GETINT("poly", curved, "curved") == INVALID || GETINT("poly", fill, "fill") == INVALID || GETINT("poly", dash, "dash") == INVALID || GETINT("poly", rotation, "rotation") == INVALID || GETINT("poly", aw, "arrow head width") == INVALID || GETINT("poly", ah, "arrow head height") == INVALID || GETINT("poly", locked, "locked") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 34) { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID || GETINT("poly", id, "id") == INVALID || GETINT("poly", curved, "curved") == INVALID || GETINT("poly", fill, "fill") == INVALID || GETINT("poly", dash, "dash") == INVALID || GETINT("poly", rotation, "rotation") == INVALID || GETINT("poly", aw, "arrow head width") == INVALID || GETINT("poly", ah, "arrow head height") == INVALID || GETINT("poly", locked, "locked") == INVALID || GETINT("poly", transformed, "transformed") == INVALID || GETINT("poly", invisible, "invisible") == INVALID || GETSTR("poly", width_spec, "width_spec") == INVALID || GETSTR("poly", aw_spec, "aw_spec") == INVALID || GETSTR("poly", ah_spec, "ah_spec") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); UtilRemoveQuotes(aw_spec); UtilRemoveQuotes(ah_spec); } else if (fileVersion <= 36) { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID || GETINT("poly", id, "id") == INVALID || GETINT("poly", curved, "curved") == INVALID || GETINT("poly", fill, "fill") == INVALID || GETINT("poly", dash, "dash") == INVALID || GETINT("poly", rotation, "rotation") == INVALID || GETINT("poly", aw, "arrow head width") == INVALID || GETINT("poly", ah, "arrow head height") == INVALID || GETINT("poly", locked, "locked") == INVALID || GETINT("poly", transformed, "transformed") == INVALID || GETINT("poly", invisible, "invisible") == INVALID || GETSTR("poly", width_spec, "width_spec") == INVALID || GETSTR("poly", aw_spec, "aw_spec") == INVALID || GETSTR("poly", ah_spec, "ah_spec") == INVALID || GETINT("poly", trans_pat, "trans_pat") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); UtilRemoveQuotes(aw_spec); UtilRemoveQuotes(ah_spec); } else { if (GETINT("poly", style, "style") == INVALID || GETINT("poly", width, "width") == INVALID || GETINT("poly", pen, "pen") == INVALID || GETINT("poly", id, "id") == INVALID || GETINT("poly", curved, "curved") == INVALID || GETINT("poly", fill, "fill") == INVALID || GETINT("poly", dash, "dash") == INVALID || GETINT("poly", rotation, "rotation") == INVALID || GETINT("poly", locked, "locked") == INVALID || GETINT("poly", transformed, "transformed") == INVALID || GETINT("poly", invisible, "invisible") == INVALID || GETSTR("poly", width_spec, "width_spec") == INVALID || GETINT("poly", trans_pat, "trans_pat") == INVALID || GETINT("poly", line_cap, "line_cap") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); UtilRemoveQuotes(aw_spec); UtilRemoveQuotes(ah_spec); if (line_cap != LCAP_BUTT) { /* does not support other linecaps, yet */ line_cap = LCAP_BUTT; } } if (fileVersion <= 16 && width <= 6) { aw = origArrowHeadW[width]; ah = origArrowHeadH[width]; width = origWidthOfLine[width]; } if (curved == LT_INTSPLINE && smooth != NULL) { free(smooth); smooth = NULL; } if (fileVersion <= 30) { switch (curved) { case LT_STRAIGHT: for (i=0; i < num_pts; i++) smooth[i] = FALSE; break; case LT_SPLINE: smooth[0] = smooth[num_pts-1] = FALSE; for (i=1; i < num_pts-1; i++) smooth[i] = TRUE; break; } } else if (!ReadSmoothHinge(FP, curved, num_pts, smooth)) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } if (smooth != NULL && (smooth[0] != FALSE || smooth[num_pts-1] != FALSE)) { smooth[0] = smooth[num_pts-1] = FALSE; SetFileModified(TRUE); sprintf(gszMsgBox, TgLoadCachedString(CSTID_BAD_SMOOTHHINGE_POLY_FIXED)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } if (fileVersion >= 37) { int aindent=0; char aindent_spec[40]; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, []"); /* for now, they both spec are identical */ if (GETINT("poly", arrow_style, "arrow_style") == INVALID || GETINT("poly", aw, "aw") == INVALID || GETINT("poly", ah, "ah") == INVALID || GETINT("poly", aindent, "aindent") == INVALID || GETSTR("poly", aw_spec, "aw_spec") == INVALID || GETSTR("poly", ah_spec, "ah_spec") == INVALID || GETSTR("poly", aindent_spec, "aindent_spec") == INVALID || GETINT("poly", arrow_style, "arrow_style") == INVALID || GETINT("poly", aw, "aw") == INVALID || GETINT("poly", ah, "ah") == INVALID || GETINT("poly", aindent, "aindent") == INVALID || GETSTR("poly", aw_spec, "aw_spec") == INVALID || GETSTR("poly", ah_spec, "ah_spec") == INVALID || GETSTR("poly", aindent_spec, "aindent_spec") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; return; } UtilRemoveQuotes(aw_spec); UtilRemoveQuotes(ah_spec); UtilRemoveQuotes(aindent_spec); } if (fileVersion >= 33 && transformed) { (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, "); ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ctm == NULL) FailAllocMessage(); if (GETINT("poly", real_x, "real_x") == INVALID || GETINT("poly", real_y, "real_y") == INVALID || GETINT("poly", orig_obbox.ltx, "orig_obbox.ltx") == INVALID || GETINT("poly", orig_obbox.lty, "orig_obbox.lty") == INVALID || GETINT("poly", orig_obbox.rbx, "orig_obbox.rbx") == INVALID || GETINT("poly", orig_obbox.rby, "orig_obbox.rby") == INVALID || GETDBL("poly", ctm->m[CTM_SX], "CTM_SX") == INVALID || GETDBL("poly", ctm->m[CTM_SIN], "CTM_SIN") == INVALID || GETDBL("poly", ctm->m[CTM_MSIN], "CTM_MSIN") == INVALID || GETDBL("poly", ctm->m[CTM_SY], "CTM_SY") == INVALID || GETINT("poly", ctm->t[CTM_TX], "CTM_TX") == INVALID || GETINT("poly", ctm->t[CTM_TY], "CTM_TY") == INVALID) { free(*ObjPtr); free(poly_ptr); free(v); *ObjPtr = NULL; free(ctm); return; } } if (fileVersion <= 32) { sprintf(width_spec, "%1d", width); sprintf(aw_spec, "%1d", aw); sprintf(ah_spec, "%1d", ah); } fill = UpgradePenFill(fill); pen = UpgradePenFill(pen); poly_ptr->style = style; poly_ptr->width = width; poly_ptr->aw = aw; poly_ptr->ah = ah; UtilStrCpyN(poly_ptr->width_spec, sizeof(poly_ptr->width_spec), width_spec); UtilStrCpyN(poly_ptr->aw_spec, sizeof(poly_ptr->aw_spec), aw_spec); UtilStrCpyN(poly_ptr->ah_spec, sizeof(poly_ptr->ah_spec), ah_spec); poly_ptr->pen = pen; poly_ptr->curved = curved; poly_ptr->fill = fill; poly_ptr->dash = dash; poly_ptr->vlist = v; poly_ptr->smooth = smooth; poly_ptr->svlist = poly_ptr->asvlist = NULL; poly_ptr->intvlist = NULL; poly_ptr->rotated_n = poly_ptr->rotated_asn = 0; poly_ptr->rotated_vlist = poly_ptr->rotated_asvlist = NULL; (*ObjPtr)->x = ltx; (*ObjPtr)->y = lty; (*ObjPtr)->color = QuickFindColorIndex(*ObjPtr, color_str, &new_alloc, TRUE); UtilStrCpyN((*ObjPtr)->color_str, sizeof((*ObjPtr)->color_str), color_str); (*ObjPtr)->dirty = FALSE; (*ObjPtr)->id = id; (*ObjPtr)->rotation = rotation; (*ObjPtr)->locked = locked; (*ObjPtr)->type = OBJ_POLY; (*ObjPtr)->obbox.ltx = ltx; (*ObjPtr)->obbox.lty = lty; (*ObjPtr)->obbox.rbx = rbx; (*ObjPtr)->obbox.rby = rby; (*ObjPtr)->detail.p = poly_ptr; (*ObjPtr)->ctm = ctm; (*ObjPtr)->invisible = invisible; (*ObjPtr)->trans_pat = trans_pat; if (ctm != NULL) { memcpy(&(*ObjPtr)->orig_obbox, &orig_obbox, sizeof(struct BBRec)); (*ObjPtr)->x = real_x; (*ObjPtr)->y = real_y; GetTransformedOBBoxOffsetVs(*ObjPtr, (*ObjPtr)->rotated_obbox); } AdjObjCache(*ObjPtr); AdjObjSplineVs(*ObjPtr); if (poly_ptr->curved != LT_INTSPLINE) { UpdPolyBBox(*ObjPtr, poly_ptr->n, poly_ptr->vlist); } else { UpdPolyBBox(*ObjPtr, poly_ptr->intn, poly_ptr->intvlist); } } /* --------------------- SetPolyPropMask() --------------------- */ void SetPolyPropMask(ObjPtr, plMask, plSkip, pProp) struct ObjRec *ObjPtr; long *plMask, *plSkip; struct PropertiesRec *pProp; { struct PolyRec *poly_ptr=ObjPtr->detail.p; SetCTMPropertyMask(ObjPtr->ctm, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_COLOR, ObjPtr->color, colorMenuItems[ObjPtr->color], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_WIDTH, poly_ptr->width, poly_ptr->width_spec, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_AW, poly_ptr->aw, poly_ptr->aw_spec, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_AH, poly_ptr->ah, poly_ptr->ah_spec, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TRANSPAT, ObjPtr->trans_pat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_FILL, poly_ptr->fill, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_PEN, poly_ptr->pen, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_DASH, poly_ptr->dash, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_CURVED, poly_ptr->curved, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_ARROW_STYLE, poly_ptr->style, NULL, plMask, plSkip, pProp); } /* --------------------- FreePolyObj() --------------------- */ void FreePolyObj(ObjPtr) struct ObjRec *ObjPtr; { if (ObjPtr->detail.p->ssvlist != NULL) free(ObjPtr->detail.p->ssvlist); if (ObjPtr->detail.p->svlist != NULL) free(ObjPtr->detail.p->svlist); if (ObjPtr->detail.p->asvlist != NULL) free(ObjPtr->detail.p->asvlist); if (ObjPtr->detail.p->intvlist != NULL) free(ObjPtr->detail.p->intvlist); if (ObjPtr->detail.p->rotated_vlist != NULL) { free(ObjPtr->detail.p->rotated_vlist); } if (ObjPtr->detail.p->rotated_asvlist != NULL) { free(ObjPtr->detail.p->rotated_asvlist); } free(ObjPtr->detail.p->vlist); if (ObjPtr->detail.p->smooth != NULL) free(ObjPtr->detail.p->smooth); if (ObjPtr->detail.p->ssmooth != NULL) free(ObjPtr->detail.p->ssmooth); free(ObjPtr->detail.p); free(ObjPtr); } /* --------------------- InitPoly() --------------------- */ void InitPoly() { ResetWiringNodeInfo(); CVListInit(&gStructSplineList); } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/remote.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000207323�11602233312�014432� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/remote.c,v 1.9 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_REMOTE_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "cmd.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "file.e" #include "ftp.e" #include "http.e" #include "mainloop.e" #include "markup.e" #include "menu.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "page.e" #include "remote.e" #include "setup.e" #include "stream.e" #include "strtbl.e" #include "tcp.e" #include "util.e" #include "version.e" int postingCGIQuery=FALSE; int gettingHttpHeaderOnly=FALSE; char *fnameForPostingCGIQuery=NULL; char gszLocalPID[MAXSTRING]; char gzipCmd[MAXPATHLENGTH+1]; char gunzipCmd[MAXPATHLENGTH+1]; static int debugRemote=FALSE; static char uncompressCmd[MAXPATHLENGTH+1]; static char httpProxy[MAXPATHLENGTH+1]; static char ftpProxy[MAXPATHLENGTH+1]; typedef struct DownloadStatRec { int timestamp; int cumulative_bytes; struct DownloadStatRec *next, *prev; } *DownloadStatRecPtr; static struct DownloadStatRec *gpFirstDLS=NULL, *gpLastDLS=NULL; static int gnDownloadStartTime=0; void CleanUpDownloadStats() { struct DownloadStatRec *pdls=NULL, *next_pdls=NULL; for (pdls=gpFirstDLS; pdls != NULL; pdls=next_pdls) { next_pdls = pdls->next; free(pdls); } gpFirstDLS = gpLastDLS = NULL; gnDownloadStartTime = 0; } #define THROUGHPUT_WINDOW 10 int UpdateDownloadStats(bytes, psz_buf) int bytes; char *psz_buf; { struct DownloadStatRec *pdls=NULL; time_t tloc; int curtime=0, count=0, elapsetime=0, interval=0; float bps=(float)0; *psz_buf = '\0'; time(&tloc); curtime = (int)tloc; if (gpFirstDLS == NULL) gnDownloadStartTime = curtime; pdls = gpLastDLS; if (pdls != NULL) { if (curtime == pdls->timestamp) { pdls->cumulative_bytes += bytes; } else { pdls = NULL; } } if (pdls == NULL) { pdls = (struct DownloadStatRec *)malloc(sizeof(struct DownloadStatRec)); if (pdls == NULL) FailAllocMessage(); memset(pdls, 0, sizeof(struct DownloadStatRec)); pdls->timestamp = curtime; pdls->cumulative_bytes = (gpLastDLS==NULL ? 0 : gpLastDLS->cumulative_bytes); pdls->cumulative_bytes += bytes; pdls->prev = gpLastDLS; pdls->next = NULL; if (gpLastDLS == NULL) { gpFirstDLS = pdls; } else { gpLastDLS->next = pdls; } gpLastDLS = pdls; } if (gnDownloadStartTime == curtime) { return FALSE; } for (pdls=gpLastDLS, count=0; pdls != NULL && count < THROUGHPUT_WINDOW; pdls=pdls->prev, count++) { } elapsetime = gpLastDLS->timestamp - gnDownloadStartTime; if (pdls == NULL) { interval = elapsetime; bps = ((float)(gpLastDLS->cumulative_bytes)) / ((float)interval); } else { interval = gpLastDLS->timestamp - pdls->timestamp; bps = ((float)(gpLastDLS->cumulative_bytes - pdls->cumulative_bytes)) / ((float)interval); } bps /= (float)1000; sprintf(psz_buf, TgLoadCachedString(CSTID_PARANED_SEC_ELAPSED_AVG_SPEED), elapsetime, bps); return TRUE; } static int gnUserAgentInitialized=FALSE; static char gszUserAgentName[MAXSTRING]; static void InitUserAgentName() { char *c_ptr=NULL; if (!gnUserAgentInitialized) { gnUserAgentInitialized = TRUE; *gszUserAgentName = '\0'; if (!(PRTGIF && !cmdLineOpenDisplay) && (c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "UserAgentName")) != NULL) { strcpy(gszUserAgentName, c_ptr); UtilTrimBlanks(gszUserAgentName); } } } int GetClientID(psz_buf, buf_sz) char *psz_buf; int buf_sz; { char agent_name[128]; *agent_name = '\0'; InitUserAgentName(); if (*gszUserAgentName != '\0') strcpy(agent_name, gszUserAgentName); if (*agent_name == '\0') { if (*specialBuild == '\0') { sprintf(agent_name, "%s/%s.%1d", TOOL_NAME, versionString, TGIF_PATCHLEVEL); } else { sprintf(agent_name, "%s/%s.%1d-%s", TOOL_NAME, versionString, TGIF_PATCHLEVEL, specialBuild); } } return UtilStrCpyN(psz_buf, buf_sz, agent_name); } void GetUserAgent(buf, buf_sz) char *buf; int buf_sz; { InitUserAgentName(); if (buf == NULL || buf_sz <= 0) return; *buf = '\0'; UtilStrCpyN(buf, buf_sz, gszUserAgentName); } void SetUserAgent(buf) char *buf; { InitUserAgentName(); if (buf == NULL || *buf == '\0') { *gszUserAgentName = '\0'; } else { UtilStrCpyN(gszUserAgentName, sizeof(gszUserAgentName), buf); UtilTrimBlanks(gszUserAgentName); } } int GetUserID(psz_buf, buf_sz) char *psz_buf; int buf_sz; { char user_name[MAXSTRING+1]; int total=0; sprintf(user_name, "%s@", TOOL_NAME); total = strlen(user_name); if (gethostname(&user_name[total], sizeof(user_name)-1-total) < 0) { sprintf(&user_name[total], "UNKNOWN"); } else { struct hostent *p_hostent=gethostbyname(&user_name[total]); if (p_hostent != NULL && p_hostent->h_name != NULL && *p_hostent->h_name != '\0') { if (strchr(p_hostent->h_name, '.') == NULL && strchr(&user_name[total], '.') != NULL) { } else { strcpy(&user_name[total], p_hostent->h_name); } } } return UtilStrCpyN(psz_buf, buf_sz, user_name); } int UserAbortComm() { return CheckInterrupt(TRUE); } int OtherAbortComm() { XEvent ev; if (initializingMain || PRTGIF) return FALSE; while (XCheckMaskEvent(mainDisplay, StructureNotifyMask, &ev)) { if (iconWindowShown) { if ((ev.xany.window == iconBaseWindow && ev.type == UnmapNotify) || (ev.xany.window == mainWindow && ev.type == MapNotify)) { XPutBackEvent(mainDisplay, &ev); return TRUE; } } else if ((ev.xany.window == iconBaseWindow && ev.type == MapNotify) || (ev.xany.window == mainWindow && ev.type == UnmapNotify)) { XPutBackEvent(mainDisplay, &ev); return TRUE; } else if (ev.type == ConfigureNotify) { Reconfigure(FALSE); } } while (XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { if (iconWindowShown) { if (ev.xany.window == mainWindow && ev.type == VisibilityNotify && ev.xvisibility.state == VisibilityUnobscured) { XPutBackEvent(mainDisplay, &ev); return TRUE; } else { ExposeEventHandler(&ev, TRUE); } } else { if (ev.xany.window == iconBaseWindow && ev.type == VisibilityNotify && ev.xvisibility.state == VisibilityUnobscured) { XPutBackEvent(mainDisplay, &ev); return TRUE; } else { ExposeEventHandler(&ev, TRUE); } } } if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); while (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) ; } return FALSE; } int GetPageNumFromPageSpec(psz_spec, pn_page_num) char *psz_spec; int *pn_page_num; { if (*psz_spec == '#') { int i=atoi(&psz_spec[1]); if (i >= 1 && i <= lastPageNum) { if (pn_page_num != NULL) *pn_page_num = i; return TRUE; } } else { struct PageRec *page_ptr; int i; if (pn_page_num != NULL) *pn_page_num = (-1); for (i=1, page_ptr=firstPage; i <= lastPageNum; i++, page_ptr=page_ptr->next) { if (page_ptr->name != NULL && strcmp(psz_spec,page_ptr->name) == 0) { if (pn_page_num != NULL) *pn_page_num = i; return TRUE; } } } if (pn_page_num != NULL) *pn_page_num = (-1); return FALSE; } void FreeRemoteBuf(psz_buf) char *psz_buf; { TcpFreeBuf(psz_buf); } static int ParseURL(url, protocol, host, port, path) char *url, **protocol, **host, **path; int *port; { char *c_ptr=strchr(url, ':'); *protocol = *host = *path = 0; if (c_ptr == NULL) return TG_REMOTE_STATUS_FORMAT; *c_ptr = '\0'; *protocol = UtilStrDup(url); *c_ptr++ = ':'; if (strncmp(c_ptr, "//", 2) == 0) { char *tmp_host=(&c_ptr[2]), *port_ptr; if ((c_ptr=strchr(tmp_host, '/')) == NULL) { *path = UtilStrDup(""); } else { *path = UtilStrDup(c_ptr); *c_ptr = '\0'; } if ((port_ptr=strchr(tmp_host, ':')) != NULL) { *port_ptr = '\0'; *port = (int)atoi(&port_ptr[1]); *host = UtilStrDup(tmp_host); *port_ptr = ':'; if (*port <= 0) { return TG_REMOTE_STATUS_FORMAT; } } else { *host = UtilStrDup(tmp_host); } if (c_ptr != NULL) *c_ptr = '/'; } else { *host = UtilStrDup("localhost"); *path = UtilStrDup(c_ptr); } return TG_REMOTE_STATUS_OK; } static void DumpURL(host, port, path) char *host, *path; int port; { /* debug, do not translate */ fprintf(stderr, "\thost = %s\n", host); fprintf(stderr, "\tport = %1d\n", port); fprintf(stderr, "\tpath = %s\n", path); fprintf(stderr, "\n"); } int DirIsRemote(psz_dir) char *psz_dir; { int port=0; char *protocol=NULL, *host=NULL, *path=NULL; int status=ParseURL(psz_dir, &protocol, &host, &port, &path), rc=FALSE; if (status == TG_REMOTE_STATUS_OK && protocol != NULL) { if (UtilStrICmp(protocol, "http") == 0 || UtilStrICmp(protocol, "ftp") == 0) { rc = TRUE; } } if (protocol != NULL) free(protocol); if (host != NULL) free(host); if (path != NULL) free(path); return rc; } int FileIsRemote(psz_file) char *psz_file; { return DirIsRemote(psz_file); } int UrlIsHtml(psz_url) char *psz_url; { char *ext_str=UtilStrRChr(psz_url, (int)'/'); if (ext_str == NULL) return FALSE; if ((ext_str=strchr(ext_str, '.')) == NULL) return FALSE; ext_str++; return (UtilStrICmp(ext_str,"html")==0 || UtilStrICmp(ext_str,"htm")==0); } static int FormLocalName(psz_file, psz_def_ext, psz_return) char *psz_file, *psz_def_ext, *psz_return; { if (psz_def_ext != NULL) { char *slash_ptr=UtilStrRChr(psz_file, (int)DIR_SEP), *dot_ptr=NULL; if (slash_ptr == NULL) { dot_ptr = strchr(psz_file, '.'); } else { dot_ptr = strchr(slash_ptr, '.'); } if (dot_ptr == NULL) { if (slash_ptr != NULL && slash_ptr[1] == '\0') { sprintf(psz_return, "%s/index.%s", psz_file, psz_def_ext); } else { sprintf(psz_return, "%s.%s", psz_file, psz_def_ext); } } else { strcpy(psz_return, psz_file); } } else { strcpy(psz_return, psz_file); } return UtilShrinkName(psz_return); } int FormRemoteName(psz_file, psz_def_ext, psz_return) char *psz_file, *psz_def_ext, *psz_return; { char *c_ptr=strstr(psz_file, "//"), *path; if (c_ptr == NULL) return FALSE; if ((c_ptr=strchr(&c_ptr[2], '/')) == NULL) { if (!FormLocalName("/", psz_def_ext, psz_return)) return FALSE; path = UtilStrDup(psz_return); sprintf(psz_return, "%s%s", psz_file, path); free(path); } else { if (!FormLocalName(c_ptr, psz_def_ext, psz_return)) return FALSE; path = UtilStrDup(psz_return); *c_ptr = '\0'; sprintf(psz_return, "%s%s", psz_file, path); free(path); *c_ptr = '/'; } return TRUE; } int FormNewFileName(psz_dir, psz_file, psz_def_ext, psz_return, ppsz_page_spec) char *psz_dir, *psz_file, *psz_def_ext, *psz_return, **ppsz_page_spec; { int rc=TRUE; if (ppsz_page_spec != NULL) *ppsz_page_spec = NULL; if (DirIsRemote(psz_dir)) { if (*psz_file == '/') { int len; char *c_ptr=strstr(psz_dir, "//"), *fname=NULL; if (c_ptr == NULL) return FALSE; if ((c_ptr=strchr(&c_ptr[2], '/')) == NULL) return FALSE; *c_ptr = '\0'; len = strlen(psz_dir)+strlen(psz_file); fname = (char*)malloc((len+1)*sizeof(char)); if (fname == NULL) { *c_ptr = '/'; return FailAllocMessage(); } sprintf(fname, "%s%s", psz_dir, psz_file); *c_ptr = '/'; if (!FormRemoteName(fname, psz_def_ext, psz_return)) rc = FALSE; free(fname); } else if (FileIsRemote(psz_file)) { if (!FormRemoteName(psz_file, psz_def_ext, psz_return)) rc = FALSE; } else { int len=strlen(psz_dir)+1+strlen(psz_file); char *fname=(char*)malloc((len+1)*sizeof(char)); if (fname == NULL) return FailAllocMessage(); sprintf(fname, "%s/%s", psz_dir, psz_file); if (!FormRemoteName(fname, psz_def_ext, psz_return)) rc = FALSE; free(fname); } } else { if (*psz_file == DIR_SEP) { if (!FormLocalName(psz_file, psz_def_ext, psz_return)) rc = FALSE; } else if (FileIsRemote(psz_file)) { if (!FormRemoteName(psz_file, psz_def_ext, psz_return)) rc = FALSE; } else { int len=strlen(psz_dir)+1+strlen(psz_file); char *fname=(char*)malloc((len+1)*sizeof(char)); if (fname == NULL) return FailAllocMessage(); sprintf(fname, "%s%c%s", psz_dir, DIR_SEP, psz_file); if (!FormLocalName(fname, psz_def_ext, psz_return)) rc = FALSE; free(fname); } } if (rc && ppsz_page_spec != NULL && psz_return != NULL && *psz_return != '\0') { char *c_ptr=UtilStrRChr(psz_return, (int)'/'); if (c_ptr != NULL) { for (++c_ptr; *c_ptr != '\0'; c_ptr++) { if (*c_ptr == '#') { *c_ptr++ = '\0'; *ppsz_page_spec = UtilStrDup(c_ptr); } else if (*c_ptr == '?') { break; } } } } return rc; } void ShowRemoteStatus(psz_msg) char *psz_msg; { if (PRTGIF) return; if (serializingFile || deserializingFile) return; SetStringStatus(psz_msg); XSync(mainDisplay, False); } char *WriteRemoteFileIntoTemp(psz_buf, buf_sz, psz_ext) char *psz_buf, *psz_ext; int buf_sz; { char *tmp_fname=NULL; int fd=(-1); mode_t mode=((tmpFileMode == 0) ? 0700 : tmpFileMode); tmp_fname = (char*)malloc((strlen(tmpDir)+20)*sizeof(char)); if (tmp_fname == NULL) { FailAllocMessage(); return NULL; } if (MkTempFile(tmp_fname, (strlen(tmpDir)+19)*sizeof(char), tmpDir, TOOL_NAME) == NULL) { free(tmp_fname); return NULL; } if (psz_ext != NULL) strcat(tmp_fname, psz_ext); unlink(tmp_fname); if ((fd=open(tmp_fname, O_WRONLY|O_CREAT|O_TRUNC, mode)) == (-1)) { sprintf(gszMsgBox, TgLoadString(STID_CANT_CREATE_NAMED_TMP_FILE), tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(tmp_fname); return NULL; } else { int ok=TRUE; if (write(fd, psz_buf, buf_sz) != buf_sz) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_WRITE_TO_FILE), tmp_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); ok = FALSE; } close(fd); if (!ok) { unlink(tmp_fname); free(tmp_fname); return NULL; } if (tmpFileMode != 0 && chmod(tmp_fname, tmpFileMode)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CHMOD), tmp_fname, tmpFileMode); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return tmp_fname; } } #define USE_GUNZIP 0 #define USE_UNCOMPRESS 1 static int TgifCompressedUrl(url) char *url; { char *ext_ptr=NULL; int len, count=0, obj_len, sym_len, pin_len, uncompress_method=INVALID; if (url == NULL) return uncompress_method; len = strlen(url); for (ext_ptr=(&url[len-1]); ext_ptr != url; ext_ptr--) { if (*ext_ptr == '.') { if (++count == 2) break; } } if (count != 2) return uncompress_method; ext_ptr++; obj_len = strlen(OBJ_FILE_EXT); sym_len = strlen(SYM_FILE_EXT); pin_len = strlen(PIN_FILE_EXT); if (strcmp(ext_ptr,"obj.gz")==0 || strcmp(ext_ptr,"sym.gz")==0 || strcmp(ext_ptr,"pin.gz")==0) { uncompress_method = USE_GUNZIP; } else if (strcmp(ext_ptr,"obj.Z")==0 || strcmp(ext_ptr,"sym.Z")==0 || strcmp(ext_ptr,"pin.Z")==0) { uncompress_method = USE_UNCOMPRESS; } else if ((strncmp(ext_ptr,OBJ_FILE_EXT,obj_len)==0 && strcmp(&ext_ptr[obj_len],".gz")==0) || (strncmp(ext_ptr,SYM_FILE_EXT,sym_len)==0 && strcmp(&ext_ptr[sym_len],".gz")==0) || (strncmp(ext_ptr,PIN_FILE_EXT,pin_len)==0 && strcmp(&ext_ptr[pin_len],".gz")==0)) { uncompress_method = USE_GUNZIP; } else if ((strncmp(ext_ptr,OBJ_FILE_EXT,obj_len)==0 && strcmp(&ext_ptr[obj_len],".Z")==0) || (strncmp(ext_ptr,SYM_FILE_EXT,sym_len)==0 && strcmp(&ext_ptr[sym_len],".Z")==0) || (strncmp(ext_ptr,PIN_FILE_EXT,pin_len)==0 && strcmp(&ext_ptr[pin_len],".Z")==0)) { uncompress_method = USE_UNCOMPRESS; } return uncompress_method; } static void UncompressTgifFile(url, ppsz_buf, pn_buf_sz, pn_html) char *url, **ppsz_buf; int *pn_buf_sz, *pn_html; { FILE *pfp=NULL; char *uncompress_cmd=NULL, *tmp_fname=NULL, *cmd=NULL; int uncompress_method; if (ppsz_buf == NULL || *ppsz_buf == NULL || pn_buf_sz == NULL || *pn_buf_sz <= 0) { return; } uncompress_method = TgifCompressedUrl(url); switch (uncompress_method) { case USE_GUNZIP: uncompress_cmd = gunzipCmd; sprintf(gszMsgBox, TgLoadCachedString(CSTID_UNZIPPING_WITH_CMD_DOTS), gunzipCmd); ShowRemoteStatus(gszMsgBox); break; case USE_UNCOMPRESS: uncompress_cmd = uncompressCmd; sprintf(gszMsgBox, TgLoadCachedString(CSTID_UNCOMPRESSING_WITH_CMD_DOTS), uncompressCmd); ShowRemoteStatus(gszMsgBox); break; default: return; } if ((tmp_fname=WriteRemoteFileIntoTemp(*ppsz_buf, *pn_buf_sz, (uncompress_method==USE_UNCOMPRESS ? ".Z" : NULL))) == NULL) { return; } cmd = (char*)malloc((strlen(tmp_fname)+strlen(uncompress_cmd)+20) * sizeof(char)); if (cmd == NULL) FailAllocMessage(); if (strstr(uncompress_cmd, "%s") == NULL) { sprintf(cmd, "%s %s", uncompress_cmd, tmp_fname); } else { sprintf(cmd, uncompress_cmd, tmp_fname); } if (!FindProgramInPath(cmd, NULL, FALSE)) { free(cmd); unlink(tmp_fname); free(tmp_fname); return; } if ((pfp=(FILE*)popen(cmd, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_EXECUTE_GIVEN_CMD), cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { int buf_sz=0x1000, total=0, chunk_sz=0x1000, bytes_read; char *buf=(char*)malloc((buf_sz+1)*sizeof(char)); if (buf == NULL) FailAllocMessage(); while (buf != NULL && (bytes_read=fread(&buf[total], sizeof(char), chunk_sz, pfp)) > 0) { total += bytes_read; buf_sz += chunk_sz; buf = (char*)realloc(buf, buf_sz+1); } buf[total] = '\0'; pclose(pfp); if (buf != NULL && total > 0) { free(*ppsz_buf); *ppsz_buf = buf; *pn_buf_sz = total; } else if (buf != NULL) { free(buf); } } unlink(tmp_fname); free(tmp_fname); if (cmd != NULL) free(cmd); } static char *GetProxyHostAndPort(proxy_spec, def_port, pn_port) char *proxy_spec; int def_port, *pn_port; { char *colon_ptr=strchr(proxy_spec, ':'), *return_buf=NULL; int len=(-1); if (colon_ptr == NULL) { len = strlen(proxy_spec); if (len > 0 && proxy_spec[len-1] == '/') { proxy_spec[len-1] = '\0'; } else { len = (-1); } *pn_port = def_port; return_buf = UtilStrDup(proxy_spec); } else { *colon_ptr = '\0'; len = strlen(proxy_spec); if (len > 0 && proxy_spec[len-1] == '/') { proxy_spec[len-1] = '\0'; } else { len = (-1); } *pn_port = atoi(&colon_ptr[1]); return_buf = UtilStrDup(proxy_spec); *colon_ptr = ':'; } if (len != (-1)) proxy_spec[len-1] = '/'; return return_buf; } static int LoadHttpIntoMem(url, host, port, path, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html, pn_http_extracted_text) char *url, *host, *path, **ppsz_buf, **ppsz_content_type; int port, *pn_buf_sz, *pn_html, *pn_http_extracted_text; { int status=TG_REMOTE_STATUS_OK, n_socket=0, proxy_port=0; char *proxy_host=NULL, port_str[20]; if (pn_http_extracted_text != NULL) *pn_http_extracted_text=FALSE; if (port == 0) port = 80; if (debugRemote) DumpURL(host, port, path); ShowInterrupt(1); if (*httpProxy == '\0') { sprintf(port_str, "%1d", port); status = HttpDoConnect(host, port, &n_socket); } else { proxy_host = GetProxyHostAndPort(httpProxy, 80, &proxy_port); sprintf(port_str, "%1d", proxy_port); if (proxy_host == NULL) { status = INVALID; } else { status = HttpDoConnect(proxy_host, proxy_port, &n_socket); } } if (status == TG_REMOTE_STATUS_HOST) { sprintf(gszMsgBox, TgLoadString(STID_CANT_LOCATE_NAMED_SERVER_TRY), "HTTP", (*httpProxy == '\0' ? host : proxy_host)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } else if (status == TG_REMOTE_STATUS_INTR) { sprintf(gszMsgBox, TgLoadString(STID_CONNECTION_INTERRUPTED), "HTTP"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); close(n_socket); } else if (status < 0) { /* n_socket already closed in TcpDoDonnect() */ if (*httpProxy == '\0') { sprintf(gszMsgBox, TgLoadString(STID_CANT_CONN_TO_HOST_PORT), "HTTP", host, port==80 ? "" : ":", port==80 ? "" : port_str); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_CONN_TO_HOST_PORT), "HTTP", proxy_host, proxy_port==80 ? "" : ":", proxy_port==80 ? "" : port_str); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (status == TG_REMOTE_STATUS_OK) { status = HttpDoWrite(n_socket, (*httpProxy=='\0' ? path : url), host, port); if (status == TG_REMOTE_STATUS_OK) { char *buf=NULL; int buf_sz=0; if ((status=HttpDoRead(n_socket, &buf, &buf_sz)) == TG_REMOTE_STATUS_OK && buf != NULL && *buf != '\0') { *ppsz_buf = HttpExtractText(buf, pn_buf_sz, pn_html, ppsz_content_type); if (*ppsz_buf != NULL && pn_buf_sz != NULL && ppsz_content_type != NULL) { if (!ParseMarkUpFile(*ppsz_buf, *pn_buf_sz, pn_html, *ppsz_content_type)) { } } if (*ppsz_buf != NULL && debugHttp > 0) { if ((debugHttp % 100) == 99) { /* * Because of the way HttpExtractText() is coded, * if *ppsz_buf != NULL, (*ppsz_buf)[*pn_buf_sz] is '\0' * no matter what kind of file it is! */ if (cmdLineDumpURL) { (void)fwrite(*ppsz_buf, sizeof(char), (*pn_buf_sz), stdout); } } } if (pn_http_extracted_text != NULL) *pn_http_extracted_text = TRUE; FreeRemoteBuf(buf); } else if (status == TG_REMOTE_STATUS_INTR) { sprintf(gszMsgBox, TgLoadString(STID_CONNECTION_INTERRUPTED), "HTTP"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (buf == NULL || *buf == '\0') { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_GET_DATA_FROM_URL), "HTTP", url); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { if (*httpProxy == '\0') { sprintf(gszMsgBox, TgLoadString(STID_NETWORK_ERR_TALK_TO_HOST_PORT), "HTTP", host, port==80 ? "" : ":", port==80 ? "" : port_str); } else { sprintf(gszMsgBox, TgLoadString(STID_NETWORK_ERR_TALK_TO_HOST_PORT), "HTTP", proxy_host, proxy_port==80 ? "" : ":", proxy_port==80 ? "" : port_str); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } close(n_socket); } else { if (*httpProxy == '\0') { sprintf(gszMsgBox, TgLoadString(STID_CANT_CONN_TO_HOST_PORT), "HTTP", host, port==80 ? "" : ":", port==80 ? "" : port_str); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_CONN_TO_HOST_PORT), "HTTP", proxy_host, proxy_port==80 ? "" : ":", proxy_port==80 ? "" : port_str); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } HideInterrupt(); return status; } static int LoadFtpIntoMem(url, host, port, path, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html) char *url, *host, *path, **ppsz_buf, **ppsz_content_type; int port, *pn_buf_sz, *pn_html; { int status=TG_REMOTE_STATUS_OK, n_socket=0, proxy_port=0; char *proxy_host=NULL, port_str[20]; if (port == 0) port = 21; if (debugRemote) DumpURL(host, port, path); ShowInterrupt(1); if (*ftpProxy == '\0') { sprintf(port_str, "%1d", port); status = FtpDoConnect(host, port, &n_socket); } else { proxy_host = GetProxyHostAndPort(ftpProxy, 21, &proxy_port); sprintf(port_str, "%1d", proxy_port); if (proxy_host == NULL) { status = INVALID; } else { status = FtpDoConnect(proxy_host, proxy_port, &n_socket); } } if (status == TG_REMOTE_STATUS_HOST) { sprintf(gszMsgBox, TgLoadString(STID_CANT_LOCATE_NAMED_SERVER_TRY), "FTP", (*ftpProxy == '\0' ? host : proxy_host)); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } } else if (status == TG_REMOTE_STATUS_INTR) { sprintf(gszMsgBox, TgLoadString(STID_CONNECTION_INTERRUPTED), "FTP"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); close(n_socket); } else if (status < 0) { /* n_socket already closed in TcpDoDonnect() */ if (*ftpProxy == '\0') { sprintf(gszMsgBox, TgLoadString(STID_CANT_CONN_TO_HOST_PORT), "FTP", host, port==21 ? "" : ":", port==21 ? "" : port_str); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_CONN_TO_HOST_PORT), "FTP", proxy_host, proxy_port==21 ? "" : ":", proxy_port==21 ? "" : port_str); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (status == TG_REMOTE_STATUS_OK) { char *buf=NULL; int buf_sz=0; sprintf(gszMsgBox, TgLoadCachedString(CSTID_SENDING_REQUESTS_DOTS), "FTP"); ShowRemoteStatus(gszMsgBox); if (((status=FtpDoTalk(n_socket, (*ftpProxy=='\0' ? path : url), &buf, &buf_sz))&(~FTP_LOGGED_IN)) == TG_REMOTE_STATUS_OK && buf != NULL && *buf != '\0') { *ppsz_buf = buf; if (pn_buf_sz != NULL) *pn_buf_sz = buf_sz; if (*ppsz_buf != NULL && pn_buf_sz != NULL && debugFtp == -99) { /* * Because of the way FtpDoTalk() is coded, * if *ppsz_buf != NULL, (*ppsz_buf)[*pn_buf_sz] is '\0' * no matter what kind of file it is! */ if (cmdLineDumpURL) { (void)fwrite(*ppsz_buf, sizeof(char), (*pn_buf_sz), stdout); } } sprintf(gszMsgBox, TgLoadCachedString(CSTID_DATA_RECEIVED), "FTP"); ShowRemoteStatus(gszMsgBox); } else if ((status & (~FTP_LOGGED_IN)) == TG_REMOTE_STATUS_INTR) { sprintf(gszMsgBox, TgLoadString(STID_CONNECTION_INTERRUPTED), "FTP"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else if (status & FTP_LOGGED_IN) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_GET_DATA_FROM_URL), "FTP", url); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { if (*ftpProxy == '\0') { sprintf(gszMsgBox, TgLoadString(STID_FAILED_TO_LOGIN_TO_HOST_PORT), "FTP", host, port==21 ? "" : ":", port==21 ? "" : port_str); } else { sprintf(gszMsgBox, TgLoadString(STID_FAILED_TO_LOGIN_TO_HOST_PORT), "FTP", proxy_host, proxy_port==21 ? "" : ":", proxy_port==21 ? "" : port_str); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } close(n_socket); } else { if (*ftpProxy == '\0') { sprintf(gszMsgBox, TgLoadString(STID_CANT_CONN_TO_HOST_PORT), "FTP", host, port==21 ? "" : ":", port==21 ? "" : port_str); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_CONN_TO_HOST_PORT), "FTP", proxy_host, proxy_port==21 ? "" : ":", proxy_port==21 ? "" : port_str); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } HideInterrupt(); return status; } static void ResetRemoteBuf(ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html) char **ppsz_buf, **ppsz_content_type; int *pn_buf_sz, *pn_html; { if (ppsz_buf != NULL && *ppsz_buf != NULL) { free(*ppsz_buf); *ppsz_buf = NULL; } if (ppsz_content_type != NULL && *ppsz_content_type != NULL) { free(*ppsz_content_type); *ppsz_content_type = NULL; } if (pn_buf_sz != NULL) *pn_buf_sz = 0; if (pn_html != NULL) *pn_html = FALSE; } static int gnForwardCount=0; static int gnAuthCount=0; static int LoadForwardedFileInMem(url, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html, force_load, psz_final_url, cb_final_url) char *url, **ppsz_buf, **ppsz_content_type, *psz_final_url; int *pn_buf_sz, *pn_html, force_load, cb_final_url; { char *location=HttpHeaderGetLocation(), *dup_location; int rc=TRUE; if (location == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_LOCATION_IN_HDR), "HTTP", url); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return TRUE; } if (gnForwardCount >= 5) { sprintf(gszMsgBox, TgLoadString(STID_LNK_FWD_5_TIMES_LOAD_ABORT), "HTTP", url); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return TRUE; } dup_location = UtilStrDup(location); if (dup_location == NULL) { FailAllocMessage(); return TRUE; } if (psz_final_url != NULL && cb_final_url > 0) { UtilStrCpyN(psz_final_url, cb_final_url, dup_location); } sprintf(gszMsgBox, TgLoadCachedString(CSTID_FORWARDING_URL_TO_URL), "HTTP", url, location); Msg(gszMsgBox); ShowRemoteStatus(gszMsgBox); /* * After calling ResetRemoteBuf(), * can only return TRUE if buffer is filled. */ ResetRemoteBuf(ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html); gnForwardCount++; rc = LoadRemoteFileInMem(dup_location, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html, force_load, psz_final_url, cb_final_url); gnForwardCount--; free(dup_location); return rc; } static char *ParseAuthFields(psz_scheme) char *psz_scheme; { char *realm_ptr, *realm_value; UtilTrimBlanks(psz_scheme); realm_ptr = strchr(psz_scheme, ' '); if (realm_ptr != NULL) { *realm_ptr++ = '\0'; while (*realm_ptr == ' ') { realm_ptr++; } if (*realm_ptr == '\0') { return NULL; } else if ((realm_value=strchr(realm_ptr, '=')) != NULL) { return ++realm_value; } } return NULL; } static int LoadAuthenticatedFileInMem(url, host, port, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html, force_load) char *url, *host, **ppsz_buf, **ppsz_content_type; int port, *pn_buf_sz, *pn_html, force_load; { char *www_authenticate=HttpHeaderGetWWWAuthentication(); char *scheme=NULL, *realm=NULL, *encoded_auth=NULL; int rc=TRUE; if (www_authenticate == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_WWW_AUTHEN_IN_HDR), "HTTP", url); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return TRUE; } scheme = UtilStrDup(www_authenticate); if (scheme == NULL) { FailAllocMessage(); return TRUE; } if ((realm=ParseAuthFields(scheme)) == NULL) { free(scheme); return TRUE; } /* realm has double-quotes around it */ if ((encoded_auth=FindAuthorization(host, port, scheme, realm)) != NULL) { /* committed authorization is cached */ /* * After calling ResetRemoteBuf(), * can only return TRUE if buffer is filled. */ ResetRemoteBuf(ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html); SetAuthorization(host, port, scheme, realm, encoded_auth); gnAuthCount++; rc = LoadRemoteFileInMem(url, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html, force_load, NULL, 0); gnAuthCount--; ResetAuthorization(); } else { char *psz=NULL, user_name[MAXSTRING+1], password[MAXSTRING+1]; *user_name = *password = '\0'; sprintf(gszMsgBox, TgLoadString(STID_AUTHEN_REQ_FOR_REALM), "HTTP", realm); ShowRemoteStatus(gszMsgBox); sprintf(gszMsgBox, TgLoadString(STID_ENTER_USERNAME_FOR_REALM), realm); if (mainDisplay == NULL) { fprintf(stdout, "%s ", gszMsgBox); fflush(stdout); psz = UtilGetALine(stdin); if (psz != NULL) { UtilStrCpyN(user_name, sizeof(user_name), psz); UtilFree(psz); } } else { Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), user_name); } UtilTrimBlanks(user_name); if (*user_name != '\0') { *password = '\0'; sprintf(gszMsgBox, TgLoadString(STID_ENTER_PASSWORD_FOR_REALM), realm); doPassword = TRUE; if (mainDisplay == NULL) { fprintf(stdout, "%s ", gszMsgBox); fflush(stdout); psz = UtilGetALine(stdin); if (psz != NULL) { UtilStrCpyN(password, sizeof(password), psz); UtilFree(psz); } } else { Dialog(gszMsgBox, NULL, password); } doPassword = FALSE; } if (*user_name != '\0' && *password != '\0') { char *tmp_auth; sprintf(gszMsgBox, "%s:%s", user_name, password); if ((tmp_auth=UtilStrDup(gszMsgBox)) == NULL) FailAllocMessage(); if ((encoded_auth=Base64Encode(tmp_auth)) == NULL) FailAllocMessage(); free(tmp_auth); if (!SetAuthorization(host, port, scheme, realm, encoded_auth)) { FailAllocMessage(); } else { /* * After calling ResetRemoteBuf(), * can only return TRUE if buffer is filled. */ ResetRemoteBuf(ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html); SetAuthorization(host, port, scheme, realm, encoded_auth); gnAuthCount++; rc = LoadRemoteFileInMem(url, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html, force_load, NULL, 0); gnAuthCount--; ResetAuthorization(); } free(encoded_auth); } } free(scheme); return rc; } int LoadRemoteFileInMem(url, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html, force_load, psz_final_url, cb_final_url) char *url, **ppsz_buf, **ppsz_content_type, *psz_final_url; int *pn_buf_sz, *pn_html, force_load, cb_final_url; /* if the remote type is http, the url has an extension and it */ /* is not html but the retrieved file is html, then it's */ /* probably an error */ { int status=0, rc; int port=0, protocol_is_http=FALSE, http_extracted_text=FALSE; char *protocol=NULL, *host=NULL, *path=NULL, *proxy_host=NULL; char port_str[20]; struct URLCacheRec *url_cache=NULL; *port_str = '\0'; if (pn_buf_sz != NULL) *pn_buf_sz = 0; if (pn_html != NULL) *pn_html = FALSE; *ppsz_buf = NULL; if (!force_load) url_cache = FindURLCache(url, TRUE); if (url_cache != NULL && url_cache->remote_buf_sz > 0 && url_cache->remote_buf != NULL) { *ppsz_buf = (char*)malloc((url_cache->remote_buf_sz)*sizeof(char)); if (*ppsz_buf == NULL) FailAllocMessage(); memcpy(*ppsz_buf, url_cache->remote_buf, url_cache->remote_buf_sz); *pn_buf_sz = url_cache->remote_buf_sz; if (ppsz_content_type != NULL) { *ppsz_content_type = UtilStrDup(url_cache->content_type); } *pn_html = url_cache->is_html; return TRUE; } status = ParseURL(url, &protocol, &host, &port, &path); if (status != TG_REMOTE_STATUS_OK) { if (protocol != NULL) free(protocol); if (host != NULL) free(host); if (path != NULL) free(path); sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_GIVEN_URL), url); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } if (UtilStrICmp(protocol, "http") == 0) { protocol_is_http = TRUE; status = LoadHttpIntoMem(url, host, port, path, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html, &http_extracted_text); } else if (UtilStrICmp(protocol, "ftp") == 0) { status = LoadFtpIntoMem(url, host, port, path, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html); } else { if (debugRemote) DumpURL(host, port, path); sprintf(gszMsgBox, TgLoadString(STID_TOOL_NOT_KNOW_HOW_TALK_PROTO), protocol); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } status = TG_REMOTE_STATUS_FORMAT; } rc = TRUE; if (status==TG_REMOTE_STATUS_OK && protocol_is_http && http_extracted_text) { int resp_code=HttpHeaderGetResponseCode(); switch (resp_code) { case 301: case 302: rc = LoadForwardedFileInMem(url, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html, force_load, psz_final_url, cb_final_url); break; case 401: rc = LoadAuthenticatedFileInMem(url, host, port, ppsz_buf, ppsz_content_type, pn_buf_sz, pn_html, force_load); break; default: if (gnAuthCount > 0) { /* password verified? */ CommitAuthorization(); } break; } } if (status == TG_REMOTE_STATUS_OK) { UncompressTgifFile(url, ppsz_buf, pn_buf_sz, pn_html); UpdateURLCache(url, *ppsz_buf, (ppsz_content_type==NULL ? NULL : *ppsz_content_type), *pn_buf_sz, *pn_html); } if (protocol != NULL) free(protocol); if (host != NULL) free(host); if (path != NULL) free(path); if (proxy_host != NULL) free(proxy_host); return rc; } static void LaunchViewer(launch_remote_file, psz_viewer, psz_url, psz_new_fname) int launch_remote_file; char *psz_viewer, *psz_url, *psz_new_fname; { if (strcmp(psz_viewer, "NONE") != 0) { #ifndef _BACKGROUND_DONT_FORK int pid=0; #endif /* ~_BACKGROUND_DONT_FORK */ char cmd[MAXSTRING<<2]; if (launch_remote_file) { sprintf(cmd, psz_viewer, psz_url); } else { sprintf(cmd, psz_viewer, psz_new_fname); } sprintf(gszMsgBox, TgLoadString(STID_LAUNCH_GIVEN_VIEWER), cmd); Msg(gszMsgBox); ShowRemoteStatus(gszMsgBox); #ifdef _BACKGROUND_DONT_FORK strcat(cmd, " &"); (void)system(cmd); #else /* ~_BACKGROUND_DONT_FORK */ pid = fork(); if (pid == 0) { (void)system(cmd); exit(0); } #endif /* _BACKGROUND_DONT_FORK */ } else { sprintf(gszMsgBox, TgLoadString(STID_FILE_SAVED), psz_new_fname); Msg(gszMsgBox); } } struct MimeTypeRec { char *main_type, *sub_type; struct MimeTypeRec *next; }; struct MailCapRec { char *main_type, *sub_type; char *cmd, *params; struct MailCapRec *next, *prev; }; static struct MimeTypeRec *topMimeTypesInfo=NULL; static struct MailCapRec *topMailCapInfo=NULL, *botMailCapInfo=NULL; static void AddAMimeType(main_type, sub_type) char *main_type, *sub_type; { struct MimeTypeRec *mime_type_ptr; mime_type_ptr = (struct MimeTypeRec *)malloc(sizeof(struct MimeTypeRec)); if (mime_type_ptr == NULL) { FailAllocMessage(); return; } memset(mime_type_ptr, 0, sizeof(struct MimeTypeRec)); mime_type_ptr->main_type = UtilStrDup(main_type); mime_type_ptr->sub_type = UtilStrDup(sub_type); mime_type_ptr->next = topMimeTypesInfo; topMimeTypesInfo = mime_type_ptr; } static void AddAMailCap(main_type, sub_type, cmd, params) char *main_type, *sub_type, *cmd, *params; { struct MailCapRec *mail_cap_ptr; mail_cap_ptr = (struct MailCapRec *)malloc(sizeof(struct MailCapRec)); if (mail_cap_ptr == NULL) { FailAllocMessage(); return; } memset(mail_cap_ptr, 0, sizeof(struct MailCapRec)); mail_cap_ptr->main_type = UtilStrDup(main_type); mail_cap_ptr->sub_type = UtilStrDup(sub_type); mail_cap_ptr->cmd = UtilStrDup(cmd); mail_cap_ptr->params = (params==NULL ? NULL : UtilStrDup(params)); mail_cap_ptr->prev = botMailCapInfo; mail_cap_ptr->next = NULL; if (botMailCapInfo == NULL) { topMailCapInfo = mail_cap_ptr; } else { botMailCapInfo->next = mail_cap_ptr; } botMailCapInfo = mail_cap_ptr; } static void FreeMimeTypesInfo() { struct MimeTypeRec *next_mime_type_ptr; for ( ; topMimeTypesInfo != NULL; topMimeTypesInfo=next_mime_type_ptr) { next_mime_type_ptr = topMimeTypesInfo->next; if (topMimeTypesInfo->main_type!=NULL) free(topMimeTypesInfo->main_type); if (topMimeTypesInfo->sub_type!=NULL) free(topMimeTypesInfo->sub_type); free(topMimeTypesInfo); } } static void FreeMailCapInfo() { struct MailCapRec *next_mail_cap_ptr; for ( ; topMailCapInfo != NULL; topMailCapInfo=next_mail_cap_ptr) { next_mail_cap_ptr = topMailCapInfo->next; if (topMailCapInfo->main_type != NULL) free(topMailCapInfo->main_type); if (topMailCapInfo->sub_type != NULL) free(topMailCapInfo->sub_type); if (topMailCapInfo->cmd != NULL) free(topMailCapInfo->cmd); if (topMailCapInfo->params != NULL) free(topMailCapInfo->params); free(topMailCapInfo); } botMailCapInfo = NULL; } static void DumpMimeTypesInfo() { struct MimeTypeRec *mime_type_ptr; /* do not translate -- program constants */ fprintf(stderr, "*** Mime Types ***\n"); for (mime_type_ptr=topMimeTypesInfo; mime_type_ptr != NULL; mime_type_ptr=mime_type_ptr->next) { fprintf(stderr, "%s/%s\n", mime_type_ptr->main_type != NULL ? mime_type_ptr->main_type : "", mime_type_ptr->sub_type != NULL ? mime_type_ptr->sub_type : ""); } fprintf(stderr, "\n"); } static void DumpMailCapInfo() { struct MailCapRec *mail_cap_ptr; /* do not translate -- program constants */ fprintf(stderr, "*** Mail Capabilities ***\n"); for (mail_cap_ptr=topMailCapInfo; mail_cap_ptr != NULL; mail_cap_ptr=mail_cap_ptr->next) { fprintf(stderr, "%s/%s; %s; %s\n", mail_cap_ptr->main_type != NULL ? mail_cap_ptr->main_type : "", mail_cap_ptr->sub_type != NULL ? mail_cap_ptr->sub_type : "", mail_cap_ptr->cmd != NULL ? mail_cap_ptr->cmd : "", mail_cap_ptr->params != NULL ? mail_cap_ptr->params : ""); } fprintf(stderr, "\n"); } static void FillMimeTypesInfo() { char *c_ptr, *buf, fname[MAXPATHLENGTH+1]; FILE *fp; int line_num=0; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MimeTypesFile")) != NULL) { strcpy(fname, c_ptr); } else { sprintf(fname, "%s%c.mime.types", homeDir, DIR_SEP); } if ((fp=fopen(fname, "r")) == NULL) return; while ((buf=UtilGetALine(fp)) != NULL) { line_num++; if (*buf != '#') { char *c_ptr1=strtok(buf, " \t\n\r"); if (c_ptr1 != NULL && *c_ptr1 != '\0') { int ok=TRUE; char *sub_type=NULL; if ((sub_type=strchr(c_ptr1, '/')) == NULL) { ok = FALSE; } else { *sub_type++ = '\0'; if (*sub_type == '\0') ok = FALSE; if (*c_ptr1 == '*') ok = FALSE; } if (!ok) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_MALFORMED_LINE_NUM_IN_FILE), line_num, fname); Msg(gszMsgBox); } else { AddAMimeType(c_ptr1, sub_type); } } } free(buf); } fclose(fp); if (debugRemote) DumpMimeTypesInfo(); } static void FillMailCapInfo() { char *spec=NULL, *fname=NULL, *colon_ptr=NULL, *c_ptr=NULL; if ((c_ptr=getenv("MAILCAPS")) != NULL) { spec = UtilStrDup(c_ptr); } else { sprintf(gszMsgBox, "%s%c.mailcap", homeDir, DIR_SEP); spec = UtilStrDup(gszMsgBox); } if (spec == NULL) FailAllocMessage(); fname = spec; colon_ptr = strchr(fname, ':'); while (fname != NULL) { if (colon_ptr != NULL) *colon_ptr = '\0'; if (*fname != '\0') { FILE *fp=NULL; if ((fp=fopen(fname, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_OPEN_GIVEN_MAILCAP_FILE), fname); Msg(gszMsgBox); } else { int line_num=0; char *buf=NULL; while ((buf=UtilGetAContinuedLine(fp)) != NULL) { line_num++; UtilTrimBlanks(buf); if (*buf != '\0' && *buf != '#') { char *first_semi_ptr=strchr(buf, ';'); char *second_semi_ptr=NULL, *sub_type=NULL; int ok=TRUE; if (first_semi_ptr == NULL) { ok = FALSE; } else { *first_semi_ptr++ = '\0'; while (*first_semi_ptr == ' ' && *first_semi_ptr == '\t') { first_semi_ptr++; } second_semi_ptr = strchr(first_semi_ptr, ';'); if (second_semi_ptr != NULL) { *second_semi_ptr++ = '\0'; } if ((sub_type=strchr(buf, '/')) == NULL) { ok = FALSE; } else { *sub_type++ = '\0'; } } if (!ok) { sprintf(gszMsgBox, TgLoadCachedString(CSTID_MALFORMED_LINE_NUM_IN_FILE), line_num, fname); Msg(gszMsgBox); } else { if (first_semi_ptr!=NULL) UtilTrimBlanks(first_semi_ptr); if (second_semi_ptr!=NULL) UtilTrimBlanks(second_semi_ptr); AddAMailCap(buf, sub_type, first_semi_ptr, second_semi_ptr); } } free(buf); } fclose(fp); } } if (colon_ptr == NULL) break; *colon_ptr++ = ':'; fname = colon_ptr; colon_ptr = strchr(fname, ':'); } UtilFree(spec); if (debugRemote) DumpMailCapInfo(); } static void MalformedMailCapEntryMessage(mail_cap_ptr) struct MailCapRec *mail_cap_ptr; { if (mail_cap_ptr->params == NULL) { sprintf(gszMsgBox, TgLoadString(STID_MALFORMED_MAILCAP_ENTRY), mail_cap_ptr->main_type, mail_cap_ptr->sub_type, mail_cap_ptr->cmd); } else { sprintf(gszMsgBox, TgLoadString(STID_MALFORMED_MAILCAP_ENTRY_PARAM), mail_cap_ptr->main_type, mail_cap_ptr->sub_type, mail_cap_ptr->cmd, mail_cap_ptr->params); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } static char *GetContentValue(name, params) char *name, *params; { char *buf, *c_ptr; if (params == NULL) return NULL; buf = UtilStrDup(params); if (buf == NULL) { FailAllocMessage(); return NULL; } for (c_ptr=strtok(buf, ";"); c_ptr != NULL; c_ptr=strtok(NULL, ";")) { char *equal_ptr=strchr(c_ptr, '-'); if (equal_ptr != NULL) { char *c_ptr1=c_ptr; while (*c_ptr1 == ' ' || *c_ptr1 == '\t') c_ptr1++; *equal_ptr = '\0'; if (UtilStrICmp(c_ptr1, name) == 0) { char *return_buf=UtilStrDup(&equal_ptr[1]); free(buf); return return_buf; } *equal_ptr = '='; } } free(buf); return NULL; } static int mimeViewerInitialized=FALSE; static char *GetMimeViewer(psz_content_type) char *psz_content_type; { struct MailCapRec *mail_cap_ptr; struct MimeTypeRec *mime_type_ptr; char *main_type=UtilStrDup(psz_content_type), *sub_type=NULL; char *params=NULL, *buf=NULL, *c_ptr; int buf_sz=0, buf_index=0; if (main_type == NULL) { FailAllocMessage(); return NULL; } UtilTrimBlanks(main_type); params = strchr(main_type, ';'); if (params != NULL) *params++ = '\0'; if (UtilStrICmp(main_type, "application/x-tgif") == 0) { free(main_type); return NULL; } sub_type = strchr(main_type, '/'); if (sub_type == NULL) { free(main_type); return NULL; } *sub_type++ = '\0'; if (UtilStrICmp(main_type, "multipart") == 0) { free(main_type); sprintf(gszMsgBox, TgLoadString(STID_TOOL_CANT_HANDLE_MP_MIME), TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } if (!mimeViewerInitialized) { mimeViewerInitialized = TRUE; FillMimeTypesInfo(); FillMailCapInfo(); } for (mime_type_ptr=topMimeTypesInfo; mime_type_ptr != NULL; mime_type_ptr=mime_type_ptr->next) { if (UtilStrICmp(main_type, mime_type_ptr->main_type) == 0) { if (strcmp(mime_type_ptr->sub_type, "*") == 0) { break; } else if (UtilStrICmp(sub_type, mime_type_ptr->sub_type) == 0) { break; } } } if (mime_type_ptr == NULL) { free(main_type); return NULL; } for (mail_cap_ptr=topMailCapInfo; mail_cap_ptr != NULL; mail_cap_ptr=mail_cap_ptr->next) { if (UtilStrICmp(main_type, mail_cap_ptr->main_type) == 0) { if (strcmp(mail_cap_ptr->sub_type, "*") == 0) { break; } else if (UtilStrICmp(sub_type, mail_cap_ptr->sub_type) == 0) { break; } } } free(main_type); if (mail_cap_ptr == NULL) return NULL; buf_sz = 0x100; buf = (char*)malloc((buf_sz+1)*sizeof(char)); if (buf == NULL) { FailAllocMessage(); return NULL; } c_ptr = mail_cap_ptr->cmd; while (*c_ptr != '\0') { if (*c_ptr == '\\' && c_ptr[1] == '\0') { MalformedMailCapEntryMessage(mail_cap_ptr); free(buf); return NULL; } if (*c_ptr == '%') { char *tmp_buf=NULL, *right_bracket; int num_ch_to_skip=(-1), len; switch (c_ptr[1]) { case 's': tmp_buf=UtilStrDup("%s"); num_ch_to_skip=2; break; case 'S': tmp_buf=UtilStrDup("%S"); num_ch_to_skip=2; break; case 't': len = strlen(main_type)+strlen(sub_type)+1; tmp_buf = (char*)malloc((len+1)*sizeof(char)); if (tmp_buf == NULL) FailAllocMessage(); sprintf(tmp_buf, "%s/%s", main_type, sub_type); num_ch_to_skip = 2; break; case '{': if ((right_bracket=strchr(&c_ptr[2], '}')) == NULL) { if (mail_cap_ptr->params == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_RT_BRACK_MC), mail_cap_ptr->main_type, mail_cap_ptr->sub_type, mail_cap_ptr->cmd); } else { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_RT_BRACK_MC_PARAM), mail_cap_ptr->main_type, mail_cap_ptr->sub_type, mail_cap_ptr->cmd, mail_cap_ptr->params); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(buf); return NULL; } num_ch_to_skip = right_bracket-c_ptr+1; *right_bracket = '\0'; if ((tmp_buf=GetContentValue(&c_ptr[2], params)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANT_FIND_NAMED_INFO_IN_CT), "HTTP", &c_ptr[2]); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *right_bracket = '}'; free(buf); return NULL; } *right_bracket = '}'; break; default: MalformedMailCapEntryMessage(mail_cap_ptr); free(buf); return NULL; } if (num_ch_to_skip < 0 || tmp_buf == NULL) { free(buf); FailAllocMessage(); return NULL; } len = strlen(tmp_buf); while (buf_index+len+1 >= buf_sz) { buf_sz += 0x100; if ((buf=(char*)realloc(buf, buf_sz+1)) == NULL) return NULL; } strcpy(&buf[buf_index], tmp_buf); buf_index += len; free(tmp_buf); c_ptr += num_ch_to_skip; } else { if (buf_index+1 >= buf_sz) { buf_sz += 0x100; if ((buf=(char*)realloc(buf, buf_sz+1)) == NULL) return NULL; } if (*c_ptr == '\\') c_ptr++; buf[buf_index++] = *c_ptr++; } } buf[buf_index] = '\0'; return buf; } static int SaveTmpURLToFile(psz_url, no_viewer_found, tmp_fname, new_file_name) char *psz_url, *tmp_fname, *new_file_name; int no_viewer_found; { char msg[MAXSTRING<<2]; char *msg1=(char*)malloc((strlen(curDirIsLocal ? curDir : curLocalDir)+30) * sizeof(char)); int rc=TG_REMOTE_STATUS_OK; if (msg1 == NULL) { FailAllocMessage(); return INVALID; } if (no_viewer_found) { sprintf(msg, TgLoadString(STID_NO_VIEWER_SAVE_GIVEN_STR_AS), psz_url); } else { sprintf(msg, TgLoadString(STID_SAVE_GIVEN_STR_AS), psz_url); } sprintf(msg1, TgLoadString(STID_WORKING_DIRECTORY_IS), (curDirIsLocal ? curDir : curLocalDir)); *new_file_name = '\0'; Dialog(msg, msg1, new_file_name); free(msg1); UtilTrimBlanks(new_file_name); if (*new_file_name == '\0') return INVALID; if (!OkayToCreateFile(new_file_name)) return INVALID; rc = UtilCopyFile(tmp_fname, new_file_name); if (rc != TG_REMOTE_STATUS_OK) { switch (rc) { case TG_REMOTE_STATUS_READ: sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), tmp_fname); break; case TG_REMOTE_STATUS_WRITE: sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), new_file_name); break; case TG_REMOTE_STATUS_FILE: sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_WRITE_TO_FILE), new_file_name); break; default: strcpy(gszMsgBox, TgLoadString(STID_UNKNOWN_ERR_IN_COPYING_FILES)); break; } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return INVALID; } return rc; } static int UseMimeViewer(psz_url, psz_content_type, tmp_fname) char *psz_url, *psz_content_type, *tmp_fname; /* returns FALSE if psz_url is to be interpreted as a tgif file or text */ /* returns TRUE if external viewer is launched */ /* returns INVALID if there's an error or if the user canceled */ { char new_file_name[MAXPATHLENGTH+1]; char *viewer=NULL, *cmd=NULL, *big_s=NULL; int launch_remote_file=FALSE; if (psz_content_type == NULL || UtilStrICmp(psz_content_type, "application/x-tgif") == 0 || strncmp(psz_url, "http:", 5) != 0) { return FALSE; } sprintf(gszMsgBox, "%s", psz_url); Msg(gszMsgBox); sprintf(gszMsgBox, " Content-type: %s", psz_content_type); Msg(gszMsgBox); /* * fprintf(stderr, "URL: %s\n", psz_url); * fprintf(stderr, "Content-Type: %s\n", psz_content_type); * fprintf(stderr, "tmp_fname: %s\n", tmp_fname); */ viewer = GetMimeViewer(psz_content_type); if (viewer == NULL) { char *slash_ptr=(psz_content_type == NULL ? NULL : strchr(psz_content_type, '/')); if (slash_ptr != NULL) { *slash_ptr = '\0'; if (UtilStrICmp(psz_content_type, "application") == 0 || UtilStrICmp(psz_content_type, "audio") == 0 || UtilStrICmp(psz_content_type, "image") == 0 || UtilStrICmp(psz_content_type, "video") == 0 || ((*psz_content_type == 'X' || *psz_content_type == 'x') && psz_content_type[1] == '-')) { *slash_ptr = '/'; SaveTmpURLToFile(psz_url, TRUE, tmp_fname, new_file_name); return TRUE; } *slash_ptr = '/'; } return FALSE; } /* * fprintf(stderr, "Launch viewer: %s\n", viewer); */ if ((big_s=strstr(viewer, "%S")) == NULL) { if (SaveTmpURLToFile(psz_url, FALSE, tmp_fname, new_file_name) == INVALID) { free(viewer); return INVALID; } cmd = (char*)malloc((strlen(viewer)+strlen(new_file_name)+40) * sizeof(char)); } else { big_s[1] = 's'; launch_remote_file = TRUE; cmd = (char*)malloc((strlen(viewer)+strlen(psz_url)+40)*sizeof(char)); } if (cmd == NULL) { FailAllocMessage(); free(viewer); return INVALID; } LaunchViewer(launch_remote_file, viewer, psz_url, new_file_name); free(viewer); free(cmd); return TRUE; } static char *gpszViewerInfo=NULL; static char *GetViewer(ext_str) char *ext_str; /* caller needs to call free() if not return NULL */ { int ext_len=strlen(ext_str), value_len, orig_len; char resource_str[MAXSTRING+1]; char *value=NULL, *c_ptr; for (c_ptr=gpszViewerInfo; c_ptr != NULL && *c_ptr != '\0'; ) { char *cr=strchr(c_ptr, '\n'), *next_cr=NULL; int cmp_result; if (cr == NULL) { free(gpszViewerInfo); gpszViewerInfo = NULL; return NULL; } *cr = '\0'; cmp_result = UtilStrICmp(c_ptr, ext_str); *cr++ = '\n'; next_cr = strchr(cr, '\n'); if (next_cr == NULL) { free(gpszViewerInfo); gpszViewerInfo = NULL; return NULL; } if (cmp_result == 0) { char *return_str; *next_cr = '\0'; return_str = (*cr == '\0' ? NULL : UtilStrDup(cr)); *next_cr = '\n'; return return_str; } c_ptr = &next_cr[1]; } sprintf(resource_str, "%sViewer", ext_str); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,resource_str)) != NULL) { int count=0; value = (char*)malloc((strlen(c_ptr)+2)*sizeof(char)); if (value == NULL) { FailAllocMessage(); return NULL; } sprintf(value, "%s\n", c_ptr); for (c_ptr=strstr(value,"%s"); c_ptr != NULL; c_ptr=strstr(&c_ptr[2],"%s")) { count++; } for (c_ptr=strstr(value,"%S"); c_ptr != NULL; c_ptr=strstr(&c_ptr[2],"%S")) { count++; } if (count > 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF), TOOL_NAME, resource_str, value); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(value, "\n"); } } else { if ((value=UtilStrDup("\n")) == NULL) return NULL; } value_len = strlen(value); orig_len = (gpszViewerInfo == NULL ? 0 : strlen(gpszViewerInfo)); if ((gpszViewerInfo=(gpszViewerInfo == NULL ? (char*)malloc((orig_len+ext_len+1+value_len+2)*sizeof(char)) : (char*)realloc(gpszViewerInfo, orig_len+ext_len+1+value_len+2))) == NULL) { FailAllocMessage(); return NULL; } sprintf(&gpszViewerInfo[orig_len], "%s\n%s", ext_str, value); if (value[value_len-1] == '\n') value[--value_len] = '\0'; if (*value == '\0') { free(value); return NULL; } return value; } static int UseViewer(psz_url, psz_content_type, tmp_fname) char *psz_url, *psz_content_type, *tmp_fname; /* returns FALSE if psz_url is to be interpreted as a tgif file or text */ /* returns TRUE if external viewer is launched */ /* returns INVALID if there's an error or if the user canceled */ { char *ext_str=UtilStrRChr(psz_url, (int)'/'); char new_file_name[MAXPATHLENGTH+1]; char *viewer=NULL, *cmd=NULL, *big_s=NULL, *separator, saved_ch='\0'; int launch_remote_file=FALSE; if (ext_str == NULL) { return UseMimeViewer(psz_url, psz_content_type, tmp_fname); } for (separator=(&ext_str[1]); *separator != '\0'; separator++) { if (*separator == '#' || *separator == '?') { saved_ch = *separator; *separator = '\0'; break; } } if ((ext_str=strchr(ext_str, '.')) == NULL) { if (separator != NULL) *separator = saved_ch; return UseMimeViewer(psz_url, psz_content_type, tmp_fname); } ext_str++; viewer = GetViewer(ext_str); if (separator != NULL) *separator = saved_ch; if (viewer == NULL) { return UseMimeViewer(psz_url, psz_content_type, tmp_fname); } if ((big_s=strstr(viewer, "%S")) == NULL) { if (SaveTmpURLToFile(psz_url, FALSE, tmp_fname, new_file_name) == INVALID) { free(viewer); return INVALID; } cmd = (char*)malloc((strlen(viewer)+strlen(new_file_name)+40) * sizeof(char)); } else { big_s[1] = 's'; launch_remote_file = TRUE; cmd = (char*)malloc((strlen(viewer)+strlen(psz_url)+40)*sizeof(char)); } if (cmd == NULL) { FailAllocMessage(); free(viewer); return INVALID; } LaunchViewer(launch_remote_file, viewer, psz_url, new_file_name); free(viewer); free(cmd); return TRUE; } int UseExternalViewer(is_html, psz_url, psz_content_type, tmp_fname) int is_html; char *psz_url, *psz_content_type, *tmp_fname; /* returns FALSE if psz_url is to be interpreted as a tgif file or text */ /* returns TRUE if external viewer is launched */ /* returns INVALID if there's an error or if the user canceled */ { char *viewer=NULL; int rc=FALSE; int url_is_html=UrlIsHtml(psz_url); if (url_is_html || !is_html) { if (UseViewer(psz_url, psz_content_type, tmp_fname) != FALSE) { rc = TRUE; } } else if (is_html && (viewer=GetViewer("html")) != NULL) { char new_file_name[MAXPATHLENGTH+1], *cmd=NULL, *big_s=NULL; int launch_remote_file=FALSE; if ((big_s=strstr(viewer, "%S")) == NULL) { if (SaveTmpURLToFile(psz_url, FALSE, tmp_fname, new_file_name) == INVALID) { free(viewer); return INVALID; } cmd = (char*)malloc((strlen(viewer)+strlen(new_file_name)+40) * sizeof(char)); } else { big_s[1] = 's'; launch_remote_file = TRUE; cmd = (char*)malloc((strlen(viewer)+strlen(psz_url)+40)*sizeof(char)); } if (cmd == NULL) { FailAllocMessage(); free(viewer); rc = INVALID; } else { LaunchViewer(launch_remote_file, viewer, psz_url, new_file_name); free(viewer); free(cmd); rc = TRUE; } } else if (UseMimeViewer(psz_url, psz_content_type, tmp_fname) != FALSE) { rc = TRUE; } return rc; } int LoadRemoteFileFromMem(psz_url, psz_buf, psz_content_type, buf_sz, is_html) char *psz_url, *psz_buf, *psz_content_type; int buf_sz, is_html; { char *tmp_fname=WriteRemoteFileIntoTemp(psz_buf, buf_sz, NULL); int navigating=navigatingBackAndForth, rc_loadfile; if (tmp_fname == NULL) return FALSE; if (UseExternalViewer(is_html, psz_url, psz_content_type, tmp_fname) != FALSE) { unlink(tmp_fname); free(tmp_fname); return FALSE; } if (!navigating) { BeforeNavigate(); navigatingBackAndForth = TRUE; } rc_loadfile = LoadFile(tmp_fname, (-1), FALSE); if (!navigating) navigatingBackAndForth = FALSE; if (!rc_loadfile) { NewProc(); PasteString(psz_buf, TRUE, TRUE); } SetCurDir(psz_url); curFileDefined = TRUE; RedrawTitleWindow(); sprintf(gszMsgBox, TgLoadCachedString(CSTID_CUR_FILE_IS), psz_url); Msg(gszMsgBox); unlink(tmp_fname); free(tmp_fname); if (!navigating) CommitNavigate(); return TRUE; } static void ModifyProxy(proxy_host) char *proxy_host; { char *c_ptr, *host=NULL, *port; if ((c_ptr=strstr(proxy_host, "//")) == NULL) { if ((host=UtilStrDup(proxy_host)) == NULL) return; } else { if ((host=UtilStrDup(&c_ptr[2])) == NULL) return; } port = strchr(host, ':'); if (port != NULL) *port++ = '\0'; sprintf(proxy_host, "%s%s%s", host, port==NULL ? "" : ":", port==NULL ? "" : port); free(host); } void InitLocalPID() { static int stInitialized=FALSE; if (!stInitialized) { int pid=(int)getpid(); char sz_host_name[MAXSTRING]; *gszLocalPID = *sz_host_name = '\0'; if (gethostname(sz_host_name, sizeof(sz_host_name)) < 0) { fprintf(stderr, "%s\n", TgLoadString(STID_CANT_GETHOSTNAME_USE_LOCALH)); strcpy(sz_host_name, "localhost"); } sprintf(gszLocalPID, "%1d:%s", pid, sz_host_name); stInitialized = TRUE; } } void InitRemote() { char *c_ptr=NULL; int val=0; InitLocalPID(); autoHyperSpaceOnRemote = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"AutoHyperSpaceOnRemote")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { autoHyperSpaceOnRemote = FALSE; } allowLaunchInHyperSpace = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"AllowLaunchInHyperSpace")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { allowLaunchInHyperSpace = TRUE; } *gzipCmd = '\0'; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"GZipCmd")) == NULL) { strcpy(gzipCmd, "gzip -c"); } else { strcpy(gzipCmd, c_ptr); } *gunzipCmd = '\0'; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"GUnZipCmd")) == NULL) { strcpy(gunzipCmd, "gunzip -c"); } else { strcpy(gunzipCmd, c_ptr); } *uncompressCmd = '\0'; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"UncompressCmd")) == NULL) { strcpy(uncompressCmd, "uncompress -c"); } else { strcpy(uncompressCmd, c_ptr); } *httpProxy = '\0'; if ((c_ptr=getenv("http_proxy")) != NULL) { strcpy(httpProxy, c_ptr); ModifyProxy(httpProxy); } else if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"HttpProxy")) != NULL) { strcpy(httpProxy, c_ptr); ModifyProxy(httpProxy); } else { *httpProxy = '\0'; } *ftpProxy = '\0'; if ((c_ptr=getenv("ftp_proxy")) != NULL) { strcpy(ftpProxy, c_ptr); ModifyProxy(ftpProxy); } else if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"FtpProxy")) != NULL) { strcpy(ftpProxy, c_ptr); ModifyProxy(ftpProxy); } else { *ftpProxy = '\0'; } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DebugHttp")) != NULL && sscanf(c_ptr, "%d", &val) == 1 && val >= 0) { HttpDebug(val); } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DebugFtp")) != NULL && sscanf(c_ptr, "%d", &val) == 1 && val >= 0) { FtpDebug(val); } gnHttpKeepAlive = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"HttpKeepAlive")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { gnHttpKeepAlive = TRUE; } if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"FakedReferer")) != NULL) { HttpFakeReferer(c_ptr); } InitHttp(); InitMime(); } void CleanUpRemote() { gnUserAgentInitialized = FALSE; *gszUserAgentName = '\0'; CleanUpDownloadStats(); CleanUpMime(); CleanUpHttp(); if (gpszViewerInfo != NULL) { free(gpszViewerInfo); gpszViewerInfo = NULL; } FreeMimeTypesInfo(); FreeMailCapInfo(); } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/oval.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000004010�11602233312�014066� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/oval.e,v 1.8 2011/06/09 16:21:18 william Exp $ */ #ifndef _OVAL_E_ #define _OVAL_E_ extern int ovalDrawn; #ifdef _INCLUDE_FROM_OVAL_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_OVAL_C_*/ extern void MyOval ARGS_DECL((Window, GC, struct BBRec)); extern void DumpOvalObj ARGS_DECL((FILE *, struct ObjRec *)); extern int NeedsToCacheOvalObj ARGS_DECL((struct ObjRec *)); extern void CreateOvalObj ARGS_DECL((struct BBRec *, int CreateAbsolute)); extern void DrawOvalObj ARGS_DECL((Window, int XOff, int YOff, struct ObjRec *)); extern void DrawOval ARGS_DECL((XEvent *)); extern void MakeOvalObjFromBoundingBox ARGS_DECL((void)); extern void SaveOvalObj ARGS_DECL((FILE *, struct ObjRec *)); extern void ReadOvalObj ARGS_DECL((FILE *, char *Inbuf, struct ObjRec **)); extern void SetOvalPropMask ARGS_DECL((struct ObjRec *, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void FreeOvalObj ARGS_DECL((struct ObjRec *)); #ifdef _INCLUDE_FROM_OVAL_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_OVAL_C_*/ #endif /*_OVAL_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/wb_seg.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000003141�11602233314�014401� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Denise Jorge de Oliveira <dezinha@land.ufrj.br> in Dec, 1999 * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/wb_seg.e,v 1.2 2005/07/26 18:30:27 william Exp $ */ #ifndef _WB_SEG_E #define _WB_SEG_E #include <stdio.h> #include <string.h> #include <stdlib.h> #include <sys/types.h> #include <netinet/in.h> #ifndef FALSE #define FALSE 0 #define TRUE 1 #endif /* ~FALSE */ #define SEG_ID 256 #define SEG_DATA_SIZE 512 typedef struct SegmentationPack{ char id[SEG_ID]; char data[SEG_DATA_SIZE]; int DataSize; int LogicalClock; int NumSeq; int NumPackets; }* ptrSegPack, SegPack; typedef struct SegmentationList{ char id[SEG_ID]; int LogicalClock; int NumPackets; int ArrivedPcts; struct Fragment *Frag; struct SegmentationList *prev, *next; }* ptrSegList; typedef struct Fragment{ char data[SEG_DATA_SIZE]; int DataSize; }* ptrSegVec; extern struct SegmentationList *first; extern struct SegmentationList *last; #ifdef _INCLUDE_FROM_WB_SEG_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_WB_SEG_C_*/ extern void InitializeSegmentation ARGS_DECL((void)); extern ptrSegPack Segment ARGS_DECL((char *, int, char *, int, int *)); extern char *DeSegment ARGS_DECL((struct SegmentationPack, int *)); #ifdef _INCLUDE_FROM_WB_SEG_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_WB_SEG_C_*/ #endif /* _WB_SEG_E */ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/configure����������������������������������������������������������������������������0000755�0000764�0000764�00000772611�11602233400�014707� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.61 for tgif 4.2.5. # # Report bugs to <bill.cheng@acm.org>. # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, # 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi # PATH needs CR # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset else as_unset=false fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) as_nl=' ' IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. case $0 in *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 { (exit 1); exit 1; } fi # Work around bugs in pre-3.0 UWIN ksh. for as_var in ENV MAIL MAILPATH do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. for as_var in \ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ LC_TELEPHONE LC_TIME do if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then eval $as_var=C; export $as_var else ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var fi done # Required to use basename. if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi # Name of the executable. as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # CDPATH. $as_unset CDPATH if test "x$CONFIG_SHELL" = x; then if (eval ":") 2>/dev/null; then as_have_required=yes else as_have_required=no fi if test $as_have_required = yes && (eval ": (as_func_return () { (exit \$1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = \"\$1\" ); then : else exitcode=1 echo positional parameters were not saved. fi test \$exitcode = 0) || { (exit 1); exit 1; } ( as_lineno_1=\$LINENO as_lineno_2=\$LINENO test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" && test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; } ") 2> /dev/null; then : else as_candidate_shells= as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. case $as_dir in /*) for as_base in sh bash ksh sh5; do as_candidate_shells="$as_candidate_shells $as_dir/$as_base" done;; esac done IFS=$as_save_IFS for as_shell in $as_candidate_shells $SHELL; do # Try only shells that exist, to save several forks. if { test -f "$as_shell" || test -f "$as_shell.exe"; } && { ("$as_shell") 2> /dev/null <<\_ASEOF if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi : _ASEOF }; then CONFIG_SHELL=$as_shell as_have_required=yes if { "$as_shell" 2> /dev/null <<\_ASEOF if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi : (as_func_return () { (exit $1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = "$1" ); then : else exitcode=1 echo positional parameters were not saved. fi test $exitcode = 0) || { (exit 1); exit 1; } ( as_lineno_1=$LINENO as_lineno_2=$LINENO test "x$as_lineno_1" != "x$as_lineno_2" && test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; } _ASEOF }; then break fi fi done if test "x$CONFIG_SHELL" != x; then for as_var in BASH_ENV ENV do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var done export CONFIG_SHELL exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} fi if test $as_have_required = no; then echo This script requires a shell more modern than all the echo shells that I found on your system. Please install a echo modern shell, or manually run the script under such a echo shell if you do have one. { (exit 1); exit 1; } fi fi fi (eval "as_func_return () { (exit \$1) } as_func_success () { as_func_return 0 } as_func_failure () { as_func_return 1 } as_func_ret_success () { return 0 } as_func_ret_failure () { return 1 } exitcode=0 if as_func_success; then : else exitcode=1 echo as_func_success failed. fi if as_func_failure; then exitcode=1 echo as_func_failure succeeded. fi if as_func_ret_success; then : else exitcode=1 echo as_func_ret_success failed. fi if as_func_ret_failure; then exitcode=1 echo as_func_ret_failure succeeded. fi if ( set x; as_func_ret_success y && test x = \"\$1\" ); then : else exitcode=1 echo positional parameters were not saved. fi test \$exitcode = 0") || { echo No shell found that supports shell functions. echo Please tell autoconf@gnu.org about your system, echo including any error possibly output before this echo message } as_lineno_1=$LINENO as_lineno_2=$LINENO test "x$as_lineno_1" != "x$as_lineno_2" && test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || { # Create $as_me.lineno as a copy of $as_myself, but with $LINENO # uniformly replaced by the line number. The first 'sed' inserts a # line-number line after each line using $LINENO; the second 'sed' # does the real work. The second script uses 'N' to pair each # line-number line with the line containing $LINENO, and appends # trailing '-' during substitution so that $LINENO is not a special # case at line end. # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the # scripts with optimization help from Paolo Bonzini. Blame Lee # E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 { (exit 1); exit 1; }; } # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in -n*) case `echo 'x\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. *) ECHO_C='\c';; esac;; *) ECHO_N='-n';; esac if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir fi echo >conf$$.file if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p=: else test -d ./-p && rmdir ./-p as_mkdir_p=false fi if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 7<&0 </dev/null 6>&1 # Name of the host. # hostname on some systems (SVR3.2, Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` # # Initializations. # ac_default_prefix=/usr/local ac_clean_files= ac_config_libobj_dir=. LIBOBJS= cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= SHELL=${CONFIG_SHELL-/bin/sh} # Identity of this package. PACKAGE_NAME='tgif' PACKAGE_TARNAME='tgif' PACKAGE_VERSION='4.2.5' PACKAGE_STRING='tgif 4.2.5' PACKAGE_BUGREPORT='bill.cheng@acm.org' ac_unique_file="wb_seg.c" # Factoring default headers for most tests. ac_includes_default="\ #include <stdio.h> #ifdef HAVE_SYS_TYPES_H # include <sys/types.h> #endif #ifdef HAVE_SYS_STAT_H # include <sys/stat.h> #endif #ifdef STDC_HEADERS # include <stdlib.h> # include <stddef.h> #else # ifdef HAVE_STDLIB_H # include <stdlib.h> # endif #endif #ifdef HAVE_STRING_H # if !defined STDC_HEADERS && defined HAVE_MEMORY_H # include <memory.h> # endif # include <string.h> #endif #ifdef HAVE_STRINGS_H # include <strings.h> #endif #ifdef HAVE_INTTYPES_H # include <inttypes.h> #endif #ifdef HAVE_STDINT_H # include <stdint.h> #endif #ifdef HAVE_UNISTD_H # include <unistd.h> #endif" ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datarootdir datadir sysconfdir sharedstatedir localstatedir includedir oldincludedir docdir infodir htmldir dvidir pdfdir psdir libdir localedir mandir DEFS ECHO_C ECHO_N ECHO_T LIBS build_alias host_alias target_alias INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA am__isrc CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE XMKMF CPP GREP EGREP LIBOBJS POW_LIB LTLIBOBJS' ac_subst_files='' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS XMKMF CPP' # Initialize some variables set by options. ac_init_help= ac_init_version=false # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. # (The list follows the same order as the GNU Coding Standards.) bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datarootdir='${prefix}/share' datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' pdfdir='${docdir}' psdir='${docdir}' libdir='${exec_prefix}/lib' localedir='${datarootdir}/locale' mandir='${datarootdir}/man' ac_prev= ac_dashdash= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval $ac_prev=\$ac_option ac_prev= continue fi case $ac_option in *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=*) datadir=$ac_optarg ;; -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | --dataroo | --dataro | --datar) ac_prev=datarootdir ;; -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) datarootdir=$ac_optarg ;; -disable-* | --disable-*) ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid feature name: $ac_feature" >&2 { (exit 1); exit 1; }; } ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'` eval enable_$ac_feature=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) docdir=$ac_optarg ;; -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) ac_prev=dvidir ;; -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) dvidir=$ac_optarg ;; -enable-* | --enable-*) ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid feature name: $ac_feature" >&2 { (exit 1); exit 1; }; } ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'` eval enable_$ac_feature=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) ac_prev=htmldir ;; -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | --ht=*) htmldir=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localedir | --localedir | --localedi | --localed | --locale) ac_prev=localedir ;; -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) localedir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst | --locals) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) ac_prev=pdfdir ;; -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) pdfdir=$ac_optarg ;; -psdir | --psdir | --psdi | --psd | --ps) ac_prev=psdir ;; -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) psdir=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid package name: $ac_package" >&2 { (exit 1); exit 1; }; } ac_package=`echo $ac_package | sed 's/[-.]/_/g'` eval with_$ac_package=\$ac_optarg ;; -without-* | --without-*) ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid package name: $ac_package" >&2 { (exit 1); exit 1; }; } ac_package=`echo $ac_package | sed 's/[-.]/_/g'` eval with_$ac_package=no ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) { echo "$as_me: error: unrecognized option: $ac_option Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; } ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null && { echo "$as_me: error: invalid variable name: $ac_envvar" >&2 { (exit 1); exit 1; }; } eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` { echo "$as_me: error: missing argument to $ac_option" >&2 { (exit 1); exit 1; }; } fi # Be sure to have absolute directory names. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2 { (exit 1); exit 1; }; } done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. If a cross compiler is detected then cross compile mode will be used." >&2 elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || { echo "$as_me: error: Working directory cannot be determined" >&2 { (exit 1); exit 1; }; } test "X$ac_ls_di" = "X$ac_pwd_ls_di" || { echo "$as_me: error: pwd does not report name of working directory" >&2 { (exit 1); exit 1; }; } # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. ac_confdir=`$as_dirname -- "$0" || $as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$0" : 'X\(//\)[^/]' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || echo X"$0" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` srcdir=$ac_confdir if test ! -r "$srcdir/$ac_unique_file"; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2 { (exit 1); exit 1; }; } fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2 { (exit 1); exit 1; }; } pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then srcdir=. fi # Remove unnecessary trailing slashes from srcdir. # Double slashes in file names in object file debugging info # mess up M-x gdb in Emacs. case $srcdir in */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; esac for ac_var in $ac_precious_vars; do eval ac_env_${ac_var}_set=\${${ac_var}+set} eval ac_env_${ac_var}_value=\$${ac_var} eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} eval ac_cv_env_${ac_var}_value=\$${ac_var} done # # Report the --help message. # if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF \`configure' configures tgif 4.2.5 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] --docdir=DIR documentation root [DATAROOTDIR/doc/tgif] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF Program names: --program-prefix=PREFIX prepend PREFIX to installed program names --program-suffix=SUFFIX append SUFFIX to installed program names --program-transform-name=PROGRAM run sed PROGRAM on installed program names X features: --x-includes=DIR X include files are in DIR --x-libraries=DIR X library files are in DIR _ACEOF fi if test -n "$ac_init_help"; then case $ac_init_help in short | recursive ) echo "Configuration of tgif 4.2.5:";; esac cat <<\_ACEOF Optional Features: --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-x use the X Window System Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a nonstandard directory <lib dir> LIBS libraries to pass to the linker, e.g. -l<library> CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I<include dir> if you have headers in a nonstandard directory <include dir> XMKMF Path to xmkmf, Makefile generator for X Window System CPP C preprocessor Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to <bill.cheng@acm.org>. _ACEOF ac_status=$? fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d "$ac_dir" || continue ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" || { ac_status=$?; continue; } # Check for guested configure. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive elif test -f "$ac_srcdir/configure"; then echo && $SHELL "$ac_srcdir/configure" --help=recursive else echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF tgif configure 4.2.5 generated by GNU Autoconf 2.61 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF exit fi cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by tgif $as_me 4.2.5, which was generated by GNU Autoconf 2.61. Invocation command line was $ $0 $@ _ACEOF exec 5>>config.log { cat <<_ASUNAME ## --------- ## ## Platform. ## ## --------- ## hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. echo "PATH: $as_dir" done IFS=$as_save_IFS } >&5 cat >&5 <<_ACEOF ## ----------- ## ## Core tests. ## ## ----------- ## _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;; 2) ac_configure_args1="$ac_configure_args1 '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi ac_configure_args="$ac_configure_args '$ac_arg'" ;; esac done done $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; } $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; } # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? # Save into config.log some information that might help in debugging. { echo cat <<\_ASBOX ## ---------------- ## ## Cache variables. ## ## ---------------- ## _ASBOX echo # The following way of writing the cache mishandles newlines in values, ( for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( *) $as_unset $ac_var ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( *${as_nl}ac_space=\ *) sed -n \ "s/'\''/'\''\\\\'\'''\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" ;; #( *) sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) echo cat <<\_ASBOX ## ----------------- ## ## Output variables. ## ## ----------------- ## _ASBOX echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac echo "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then cat <<\_ASBOX ## ------------------- ## ## File substitutions. ## ## ------------------- ## _ASBOX echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac echo "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then cat <<\_ASBOX ## ----------- ## ## confdefs.h. ## ## ----------- ## _ASBOX echo cat confdefs.h echo fi test "$ac_signal" != 0 && echo "$as_me: caught signal $ac_signal" echo "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF #define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer explicitly selected file to automatically selected ones. if test -n "$CONFIG_SITE"; then set x "$CONFIG_SITE" elif test "x$prefix" != xNONE; then set x "$prefix/share/config.site" "$prefix/etc/config.site" else set x "$ac_default_prefix/share/config.site" \ "$ac_default_prefix/etc/config.site" fi shift for ac_site_file do if test -r "$ac_site_file"; then { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5 echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special # files actually), so we avoid doing that. if test -f "$cache_file"; then { echo "$as_me:$LINENO: loading cache $cache_file" >&5 echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { echo "$as_me:$LINENO: creating cache $cache_file" >&5 echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in $ac_precious_vars; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val=\$ac_cv_env_${ac_var}_value eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} { echo "$as_me:$LINENO: former value: $ac_old_val" >&5 echo "$as_me: former value: $ac_old_val" >&2;} { echo "$as_me:$LINENO: current value: $ac_new_val" >&5 echo "$as_me: current value: $ac_new_val" >&2;} ac_cache_corrupted=: fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) ac_configure_args="$ac_configure_args '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; then { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5 echo "$as_me: error: changes in the environment can compromise the build" >&2;} { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;} { (exit 1); exit 1; }; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu am__api_version='1.10' ac_aux_dir= for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do if test -f "$ac_dir/install-sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install-sh -c" break elif test -f "$ac_dir/install.sh"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/install.sh -c" break elif test -f "$ac_dir/shtool"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/shtool install -c" break fi done if test -z "$ac_aux_dir"; then { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&5 echo "$as_me: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&2;} { (exit 1); exit 1; }; } fi # These three variables are undocumented and unsupported, # and are intended to be withdrawn in a future Autoconf release. # They can cause serious problems if a builder's source tree is in a directory # whose full name contains unusual characters. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. { echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5 echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; } if test -z "$INSTALL"; then if test "${ac_cv_path_install+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in ./ | .// | /cC/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi done done ;; esac done IFS=$as_save_IFS fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a # value for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. INSTALL=$ac_install_sh fi fi { echo "$as_me:$LINENO: result: $INSTALL" >&5 echo "${ECHO_T}$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { echo "$as_me:$LINENO: checking whether build environment is sane" >&5 echo $ECHO_N "checking whether build environment is sane... $ECHO_C" >&6; } # Just in case sleep 1 echo timestamp > conftest.file # Do `set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` if test "$*" = "X"; then # -L didn't work. set X `ls -t $srcdir/configure conftest.file` fi rm -f conftest.file if test "$*" != "X $srcdir/configure conftest.file" \ && test "$*" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". { { echo "$as_me:$LINENO: error: ls -t appears to fail. Make sure there is not a broken alias in your environment" >&5 echo "$as_me: error: ls -t appears to fail. Make sure there is not a broken alias in your environment" >&2;} { (exit 1); exit 1; }; } fi test "$2" = conftest.file ) then # Ok. : else { { echo "$as_me:$LINENO: error: newly created file is older than distributed files! Check your system clock" >&5 echo "$as_me: error: newly created file is older than distributed files! Check your system clock" >&2;} { (exit 1); exit 1; }; } fi { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. test "$program_suffix" != NONE && program_transform_name="s&\$&$program_suffix&;$program_transform_name" # Double any \ or $. echo might interpret backslashes. # By default was `s,x,x', remove it if useless. cat <<\_ACEOF >conftest.sed s/[\\$]/&&/g;s/;s,x,x,$// _ACEOF program_transform_name=`echo $program_transform_name | sed -f conftest.sed` rm -f conftest.sed # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= { echo "$as_me:$LINENO: WARNING: \`missing' script is too old or missing" >&5 echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} fi { echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5 echo $ECHO_N "checking for a thread-safe mkdir -p... $ECHO_C" >&6; } if test -z "$MKDIR_P"; then if test "${ac_cv_path_mkdir+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in mkdir gmkdir; do for ac_exec_ext in '' $ac_executable_extensions; do { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( 'mkdir (GNU coreutils) '* | \ 'mkdir (coreutils) '* | \ 'mkdir (fileutils) '4.1*) ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext break 3;; esac done done done IFS=$as_save_IFS fi if test "${ac_cv_path_mkdir+set}" = set; then MKDIR_P="$ac_cv_path_mkdir -p" else # As a last resort, use the slow shell script. Don't cache a # value for MKDIR_P within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. test -d ./--version && rmdir ./--version MKDIR_P="$ac_install_sh -d" fi fi { echo "$as_me:$LINENO: result: $MKDIR_P" >&5 echo "${ECHO_T}$MKDIR_P" >&6; } mkdir_p="$MKDIR_P" case $mkdir_p in [\\/$]* | ?:[\\/]*) ;; */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; esac for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_AWK+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_AWK="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then { echo "$as_me:$LINENO: result: $AWK" >&5 echo "${ECHO_T}$AWK" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$AWK" && break done { echo "$as_me:$LINENO: checking whether ${MAKE-make} sets \$(MAKE)" >&5 echo $ECHO_N "checking whether ${MAKE-make} sets \$(MAKE)... $ECHO_C" >&6; } set x ${MAKE-make}; ac_make=`echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF # GNU make sometimes prints "make[1]: Entering...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; *) eval ac_cv_prog_make_${ac_make}_set=no;; esac rm -f conftest.make fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } SET_MAKE= else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null if test "`cd $srcdir && pwd`" != "`pwd`"; then # Use -I$(srcdir) only when $(srcdir) != ., so that make's output # is not polluted with repeated "-I." am__isrc=' -I$(srcdir)' # test to see if srcdir already configured if test -f $srcdir/config.status; then { { echo "$as_me:$LINENO: error: source directory already configured; run \"make distclean\" there first" >&5 echo "$as_me: error: source directory already configured; run \"make distclean\" there first" >&2;} { (exit 1); exit 1; }; } fi fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi # Define the identity of the package. PACKAGE='tgif' VERSION='4.2.5' cat >>confdefs.h <<_ACEOF #define PACKAGE "$PACKAGE" _ACEOF cat >>confdefs.h <<_ACEOF #define VERSION "$VERSION" _ACEOF # Some tools Automake needs. ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} install_sh=${install_sh-"\$(SHELL) $am_aux_dir/install-sh"} # Installed binaries are usually stripped using `strip' when the user # run `make install-strip'. However `strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the `STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { echo "$as_me:$LINENO: result: $STRIP" >&5 echo "${ECHO_T}$STRIP" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_STRIP="strip" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5 echo "${ECHO_T}$ac_ct_STRIP" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi fi INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" # We need awk for the "check" target. The system "awk" is bad on # some platforms. # Always define AMTAR for backward compatibility. AMTAR=${AMTAR-"${am_missing_run}tar"} am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' ac_config_headers="$ac_config_headers config.h" # Checks for programs. ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}gcc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="gcc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}cc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $# != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { echo "$as_me:$LINENO: result: $CC" >&5 echo "${ECHO_T}$CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="$ac_prog" echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5 echo "${ECHO_T}$ac_ct_CC" >&6; } else { echo "$as_me:$LINENO: result: no" >&5 echo "${ECHO_T}no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&5 echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools whose name does not start with the host triplet. If you think this configuration is useful to you, please write to autoconf@gnu.org." >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH See \`config.log' for more details." >&5 echo "$as_me: error: no acceptable C compiler found in \$PATH See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } # Provide some information about the compiler. echo "$as_me:$LINENO: checking for C compiler version" >&5 ac_compiler=`set X $ac_compile; echo $2` { (ac_try="$ac_compiler --version >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler --version >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -v >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -v >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } { (ac_try="$ac_compiler -V >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compiler -V >&5") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. { echo "$as_me:$LINENO: checking for C compiler default output file name" >&5 echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; } ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # # List of possible output files, starting from the most likely. # The algorithm is not robust to junk in `.', hence go to wildcards (a.*) # only as a last resort. b.out is created by i960 compilers. ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out' # # The IRIX 6 linker writes into existing files which may not be # executable, retaining their permissions. Remove them first so a # subsequent execution test works. ac_rmfiles= for ac_file in $ac_files do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done rm -f $ac_rmfiles if { (ac_try="$ac_link_default" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link_default") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. for ac_file in $ac_files '' do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not # safe: cross compilers may not add the suffix if given an `-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. break;; * ) break;; esac done test "$ac_cv_exeext" = no && ac_cv_exeext= else ac_file='' fi { echo "$as_me:$LINENO: result: $ac_file" >&5 echo "${ECHO_T}$ac_file" >&6; } if test -z "$ac_file"; then echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { echo "$as_me:$LINENO: error: C compiler cannot create executables See \`config.log' for more details." >&5 echo "$as_me: error: C compiler cannot create executables See \`config.log' for more details." >&2;} { (exit 77); exit 77; }; } fi ac_exeext=$ac_cv_exeext # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { echo "$as_me:$LINENO: checking whether the C compiler works" >&5 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; } # FIXME: These cross compiler hacks should be removed for Autoconf 3.0 # If not cross compiling, check that we can run a simple program. if test "$cross_compiling" != yes; then if { ac_try='./$ac_file' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else { { echo "$as_me:$LINENO: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&5 echo "$as_me: error: cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi fi fi { echo "$as_me:$LINENO: result: yes" >&5 echo "${ECHO_T}yes" >&6; } rm -f a.out a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { echo "$as_me:$LINENO: checking whether we are cross compiling" >&5 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; } { echo "$as_me:$LINENO: result: $cross_compiling" >&5 echo "${ECHO_T}$cross_compiling" >&6; } { echo "$as_me:$LINENO: checking for suffix of executables" >&5 echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; } if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done else { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&5 echo "$as_me: error: cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi rm -f conftest$ac_cv_exeext { echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5 echo "${ECHO_T}$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT { echo "$as_me:$LINENO: checking for suffix of object files" >&5 echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; } if test "${ac_cv_objext+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.o conftest.obj if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; then for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile See \`config.log' for more details." >&5 echo "$as_me: error: cannot compute suffix of object files: cannot compile See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_objext" >&5 echo "${ECHO_T}$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; } if test "${ac_cv_c_compiler_gnu+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_compiler_gnu=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; } GCC=`test $ac_compiler_gnu = yes && echo yes` ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; } if test "${ac_cv_prog_cc_g+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cc_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 CFLAGS="" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cc_g=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; } if test "$ac_test_CFLAGS" = set; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi { echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5 echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; } if test "${ac_cv_prog_cc_c89+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_prog_cc_c89=no ac_save_CC=$CC cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <stdarg.h> #include <stdio.h> #include <sys/types.h> #include <sys/stat.h> /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); static char *e (p, i) char **p; int i; { return p[i]; } static char *f (char * (*g) (char **, int), char **p, ...) { char *s; va_list v; va_start (v,p); s = g (p, va_arg (v,int)); va_end (v); return s; } /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has function prototypes and stuff, but not '\xHH' hex character constants. These don't provoke an error unfortunately, instead are silently treated as 'x'. The following induces an error, until -std is added to get proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an array size at least. It's necessary to write '\x00'==0 to get something that's true only with -std. */ int osf4_cc_array ['\x00' == 0 ? 1 : -1]; /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters inside strings and character constants. */ #define FOO(x) 'x' int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);}; int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); int argc; char **argv; int main () { return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_prog_cc_c89=$ac_arg else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) { echo "$as_me:$LINENO: result: none needed" >&5 echo "${ECHO_T}none needed" >&6; } ;; xno) { echo "$as_me:$LINENO: result: unsupported" >&5 echo "${ECHO_T}unsupported" >&6; } ;; *) CC="$CC $ac_cv_prog_cc_c89" { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5 echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;; esac ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo done .PHONY: am__doit END # If we don't find an include directive, just comment out the code. { echo "$as_me:$LINENO: checking for style of include used by $am_make" >&5 echo $ECHO_N "checking for style of include used by $am_make... $ECHO_C" >&6; } am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # We grep out `Entering directory' and `Leaving directory' # messages which can occur if `w' ends up in MAKEFLAGS. # In particular we don't look at `^make:' because GNU make might # be invoked under some other name (usually "gmake"), in which # case it prints its new name instead of `make'. if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then am__include=include am__quote= _am_result=GNU fi # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then am__include=.include am__quote="\"" _am_result=BSD fi fi { echo "$as_me:$LINENO: result: $_am_result" >&5 echo "${ECHO_T}$_am_result" >&6; } rm -f confinc confmf # Check whether --enable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then enableval=$enable_dependency_tracking; fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= AMDEP_FALSE='#' else AMDEP_TRUE='#' AMDEP_FALSE= fi depcc="$CC" am_compiler_list= { echo "$as_me:$LINENO: checking dependency style of $depcc" >&5 echo $ECHO_N "checking dependency style of $depcc... $ECHO_C" >&6; } if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CC_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CC_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi { echo "$as_me:$LINENO: result: $am_cv_CC_dependencies_compiler_type" >&5 echo "${ECHO_T}$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then am__fastdepCC_TRUE= am__fastdepCC_FALSE='#' else am__fastdepCC_TRUE='#' am__fastdepCC_FALSE= fi # Checks for libraries. { echo "$as_me:$LINENO: checking for XOpenDisplay in -lX11" >&5 echo $ECHO_N "checking for XOpenDisplay in -lX11... $ECHO_C" >&6; } if test "${ac_cv_lib_X11_XOpenDisplay+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lX11 $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char XOpenDisplay (); int main () { return XOpenDisplay (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_X11_XOpenDisplay=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_X11_XOpenDisplay=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_X11_XOpenDisplay" >&5 echo "${ECHO_T}$ac_cv_lib_X11_XOpenDisplay" >&6; } if test $ac_cv_lib_X11_XOpenDisplay = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_LIBX11 1 _ACEOF LIBS="-lX11 $LIBS" fi { echo "$as_me:$LINENO: checking for XtInitialize in -lXt" >&5 echo $ECHO_N "checking for XtInitialize in -lXt... $ECHO_C" >&6; } if test "${ac_cv_lib_Xt_XtInitialize+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lXt $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char XtInitialize (); int main () { return XtInitialize (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_Xt_XtInitialize=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_Xt_XtInitialize=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_Xt_XtInitialize" >&5 echo "${ECHO_T}$ac_cv_lib_Xt_XtInitialize" >&6; } if test $ac_cv_lib_Xt_XtInitialize = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_LIBXT 1 _ACEOF LIBS="-lXt $LIBS" fi { echo "$as_me:$LINENO: checking for socket in -lsocket" >&5 echo $ECHO_N "checking for socket in -lsocket... $ECHO_C" >&6; } if test "${ac_cv_lib_socket_socket+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lsocket $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char socket (); int main () { return socket (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_socket_socket=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_socket_socket=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_socket_socket" >&5 echo "${ECHO_T}$ac_cv_lib_socket_socket" >&6; } if test $ac_cv_lib_socket_socket = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_LIBSOCKET 1 _ACEOF LIBS="-lsocket $LIBS" fi { echo "$as_me:$LINENO: checking for inet_addr in -lnsl" >&5 echo $ECHO_N "checking for inet_addr in -lnsl... $ECHO_C" >&6; } if test "${ac_cv_lib_nsl_inet_addr+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lnsl $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char inet_addr (); int main () { return inet_addr (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_nsl_inet_addr=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_nsl_inet_addr=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_inet_addr" >&5 echo "${ECHO_T}$ac_cv_lib_nsl_inet_addr" >&6; } if test $ac_cv_lib_nsl_inet_addr = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_LIBNSL 1 _ACEOF LIBS="-lnsl $LIBS" fi { echo "$as_me:$LINENO: checking for dlsym in -ldl" >&5 echo $ECHO_N "checking for dlsym in -ldl... $ECHO_C" >&6; } if test "${ac_cv_lib_dl_dlsym+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-ldl $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char dlsym (); int main () { return dlsym (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_dl_dlsym=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_dl_dlsym=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlsym" >&5 echo "${ECHO_T}$ac_cv_lib_dl_dlsym" >&6; } if test $ac_cv_lib_dl_dlsym = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_LIBDL 1 _ACEOF LIBS="-ldl $LIBS" fi { echo "$as_me:$LINENO: checking for stringprep_convert in -lidn" >&5 echo $ECHO_N "checking for stringprep_convert in -lidn... $ECHO_C" >&6; } if test "${ac_cv_lib_idn_stringprep_convert+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lidn $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char stringprep_convert (); int main () { return stringprep_convert (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_idn_stringprep_convert=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_idn_stringprep_convert=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_idn_stringprep_convert" >&5 echo "${ECHO_T}$ac_cv_lib_idn_stringprep_convert" >&6; } if test $ac_cv_lib_idn_stringprep_convert = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_LIBIDN 1 _ACEOF LIBS="-lidn $LIBS" fi { echo "$as_me:$LINENO: checking for pow in -lm" >&5 echo $ECHO_N "checking for pow in -lm... $ECHO_C" >&6; } if test "${ac_cv_lib_m_pow+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lm $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char pow (); int main () { return pow (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_m_pow=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_m_pow=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_m_pow" >&5 echo "${ECHO_T}$ac_cv_lib_m_pow" >&6; } if test $ac_cv_lib_m_pow = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_LIBM 1 _ACEOF LIBS="-lm $LIBS" fi { echo "$as_me:$LINENO: checking for deflate in -lz" >&5 echo $ECHO_N "checking for deflate in -lz... $ECHO_C" >&6; } if test "${ac_cv_lib_z_deflate+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lz $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char deflate (); int main () { return deflate (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_z_deflate=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_z_deflate=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_z_deflate" >&5 echo "${ECHO_T}$ac_cv_lib_z_deflate" >&6; } if test $ac_cv_lib_z_deflate = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_LIBZ 1 _ACEOF LIBS="-lz $LIBS" fi { echo "$as_me:$LINENO: checking for pthread_create in -lpthread" >&5 echo $ECHO_N "checking for pthread_create in -lpthread... $ECHO_C" >&6; } if test "${ac_cv_lib_pthread_pthread_create+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lpthread $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char pthread_create (); int main () { return pthread_create (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_pthread_pthread_create=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_pthread_pthread_create=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_pthread_pthread_create" >&5 echo "${ECHO_T}$ac_cv_lib_pthread_pthread_create" >&6; } if test $ac_cv_lib_pthread_pthread_create = yes; then cat >>confdefs.h <<_ACEOF #define HAVE_LIBPTHREAD 1 _ACEOF LIBS="-lpthread $LIBS" fi # Checks for header files. ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; } # On Suns, sometimes $CPP names a directory. if test -n "$CPP" && test -d "$CPP"; then CPP= fi if test -z "$CPP"; then if test "${ac_cv_prog_CPP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Double quotes because CPP needs to be expanded for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" do ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since # <limits.h> exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #ifdef __STDC__ # include <limits.h> #else # include <assert.h> #endif Syntax error _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <ac_nonexistent.h> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then break fi done ac_cv_prog_CPP=$CPP fi CPP=$ac_cv_prog_CPP else ac_cv_prog_CPP=$CPP fi { echo "$as_me:$LINENO: result: $CPP" >&5 echo "${ECHO_T}$CPP" >&6; } ac_preproc_ok=false for ac_c_preproc_warn_flag in '' yes do # Use a header file that comes with gcc, so configuring glibc # with a fresh cross-compiler works. # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since # <limits.h> exists even on freestanding compilers. # On the NeXT, cc -E runs the code through the compiler's parser, # not just through cpp. "Syntax error" is here to catch this case. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #ifdef __STDC__ # include <limits.h> #else # include <assert.h> #endif Syntax error _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then : else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Broken: fails on valid input. continue fi rm -f conftest.err conftest.$ac_ext # OK, works on sane cases. Now check whether nonexistent headers # can be detected and how. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <ac_nonexistent.h> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then # Broken: success on invalid input. continue else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 # Passes both tests. ac_preproc_ok=: break fi rm -f conftest.err conftest.$ac_ext done # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. rm -f conftest.err conftest.$ac_ext if $ac_preproc_ok; then : else { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details." >&5 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check See \`config.log' for more details." >&2;} { (exit 1); exit 1; }; } fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu { echo "$as_me:$LINENO: checking for X" >&5 echo $ECHO_N "checking for X... $ECHO_C" >&6; } # Check whether --with-x was given. if test "${with_x+set}" = set; then withval=$with_x; fi # $have_x is `yes', `no', `disabled', or empty when we do not yet know. if test "x$with_x" = xno; then # The user explicitly disabled X. have_x=disabled else case $x_includes,$x_libraries in #( *\'*) { { echo "$as_me:$LINENO: error: Cannot use X directory names containing '" >&5 echo "$as_me: error: Cannot use X directory names containing '" >&2;} { (exit 1); exit 1; }; };; #( *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # One or both of the vars are not set, and there is no cached value. ac_x_includes=no ac_x_libraries=no rm -f -r conftest.dir if mkdir conftest.dir; then cd conftest.dir cat >Imakefile <<'_ACEOF' incroot: @echo incroot='${INCROOT}' usrlibdir: @echo usrlibdir='${USRLIBDIR}' libdir: @echo libdir='${LIBDIR}' _ACEOF if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then # GNU make sometimes prints "make[1]: Entering...", which would confuse us. for ac_var in incroot usrlibdir libdir; do eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" done # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. for ac_extension in a so sl; do if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && test -f "$ac_im_libdir/libX11.$ac_extension"; then ac_im_usrlibdir=$ac_im_libdir; break fi done # Screen out bogus values from the imake configuration. They are # bogus both because they are the default anyway, and because # using them would break gcc on systems where it needs fixed includes. case $ac_im_incroot in /usr/include) ac_x_includes= ;; *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; esac case $ac_im_usrlibdir in /usr/lib | /lib) ;; *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; esac fi cd .. rm -f -r conftest.dir fi # Standard set of common directories for X headers. # Check X11 before X11Rn because it is often a symlink to the current release. ac_x_header_dirs=' /usr/X11/include /usr/X11R6/include /usr/X11R5/include /usr/X11R4/include /usr/include/X11 /usr/include/X11R6 /usr/include/X11R5 /usr/include/X11R4 /usr/local/X11/include /usr/local/X11R6/include /usr/local/X11R5/include /usr/local/X11R4/include /usr/local/include/X11 /usr/local/include/X11R6 /usr/local/include/X11R5 /usr/local/include/X11R4 /usr/X386/include /usr/x386/include /usr/XFree86/include/X11 /usr/include /usr/local/include /usr/unsupported/include /usr/athena/include /usr/local/x11r5/include /usr/lpp/Xamples/include /usr/openwin/include /usr/openwin/share/include' if test "$ac_x_includes" = no; then # Guess where to find include files, by looking for Xlib.h. # First, try using that file with no special directory specified. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <X11/Xlib.h> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then # We can compile using X headers with no special include directory. ac_x_includes= else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 for ac_dir in $ac_x_header_dirs; do if test -r "$ac_dir/X11/Xlib.h"; then ac_x_includes=$ac_dir break fi done fi rm -f conftest.err conftest.$ac_ext fi # $ac_x_includes = no if test "$ac_x_libraries" = no; then # Check for the libraries. # See if we find them without any special options. # Don't add to $LIBS permanently. ac_save_LIBS=$LIBS LIBS="-lX11 $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <X11/Xlib.h> int main () { XrmInitialize () ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then LIBS=$ac_save_LIBS # We can link X programs with no special library path. ac_x_libraries= else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 LIBS=$ac_save_LIBS for ac_dir in `echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` do # Don't even attempt the hair of trying to link an X program! for ac_extension in a so sl; do if test -r "$ac_dir/libX11.$ac_extension"; then ac_x_libraries=$ac_dir break 2 fi done done fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi # $ac_x_libraries = no case $ac_x_includes,$ac_x_libraries in #( no,* | *,no | *\'*) # Didn't find X, or a directory has "'" in its name. ac_cv_have_x="have_x=no";; #( *) # Record where we found X for the cache. ac_cv_have_x="have_x=yes\ ac_x_includes='$ac_x_includes'\ ac_x_libraries='$ac_x_libraries'" esac fi ;; #( *) have_x=yes;; esac eval "$ac_cv_have_x" fi # $with_x != no if test "$have_x" != yes; then { echo "$as_me:$LINENO: result: $have_x" >&5 echo "${ECHO_T}$have_x" >&6; } no_x=yes else # If each of the values was on the command line, it overrides each guess. test "x$x_includes" = xNONE && x_includes=$ac_x_includes test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries # Update the cache value to reflect the command line values. ac_cv_have_x="have_x=yes\ ac_x_includes='$x_includes'\ ac_x_libraries='$x_libraries'" { echo "$as_me:$LINENO: result: libraries $x_libraries, headers $x_includes" >&5 echo "${ECHO_T}libraries $x_libraries, headers $x_includes" >&6; } fi ac_header_dirent=no for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_hdr that defines DIR" >&5 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <sys/types.h> #include <$ac_hdr> int main () { if ((DIR *) 0) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then eval "$as_ac_Header=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_Header=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 _ACEOF ac_header_dirent=$ac_hdr; break fi done # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. if test $ac_header_dirent = dirent.h; then { echo "$as_me:$LINENO: checking for library containing opendir" >&5 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6; } if test "${ac_cv_search_opendir+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_func_search_save_LIBS=$LIBS cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char opendir (); int main () { return opendir (); ; return 0; } _ACEOF for ac_lib in '' dir; do if test -z "$ac_lib"; then ac_res="none required" else ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_search_opendir=$ac_res else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext if test "${ac_cv_search_opendir+set}" = set; then break fi done if test "${ac_cv_search_opendir+set}" = set; then : else ac_cv_search_opendir=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 echo "${ECHO_T}$ac_cv_search_opendir" >&6; } ac_res=$ac_cv_search_opendir if test "$ac_res" != no; then test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi else { echo "$as_me:$LINENO: checking for library containing opendir" >&5 echo $ECHO_N "checking for library containing opendir... $ECHO_C" >&6; } if test "${ac_cv_search_opendir+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_func_search_save_LIBS=$LIBS cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char opendir (); int main () { return opendir (); ; return 0; } _ACEOF for ac_lib in '' x; do if test -z "$ac_lib"; then ac_res="none required" else ac_res=-l$ac_lib LIBS="-l$ac_lib $ac_func_search_save_LIBS" fi rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_search_opendir=$ac_res else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext if test "${ac_cv_search_opendir+set}" = set; then break fi done if test "${ac_cv_search_opendir+set}" = set; then : else ac_cv_search_opendir=no fi rm conftest.$ac_ext LIBS=$ac_func_search_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_search_opendir" >&5 echo "${ECHO_T}$ac_cv_search_opendir" >&6; } ac_res=$ac_cv_search_opendir if test "$ac_res" != no; then test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" fi fi { echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5 echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; } if test "${ac_cv_path_GREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else # Extract the first word of "grep ggrep" to use in msg output if test -z "$GREP"; then set dummy grep ggrep; ac_prog_name=$2 if test "${ac_cv_path_GREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_path_GREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in grep ggrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue # Check for GNU ac_path_GREP and select it if it is found. # Check for GNU $ac_path_GREP case `"$ac_path_GREP" --version 2>&1` in *GNU*) ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; *) ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" echo 'GREP' >> "conftest.nl" "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break ac_count=`expr $ac_count + 1` if test $ac_count -gt ${ac_path_GREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_GREP_found && break 3 done done done IFS=$as_save_IFS fi GREP="$ac_cv_path_GREP" if test -z "$GREP"; then { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} { (exit 1); exit 1; }; } fi else ac_cv_path_GREP=$GREP fi fi { echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5 echo "${ECHO_T}$ac_cv_path_GREP" >&6; } GREP="$ac_cv_path_GREP" { echo "$as_me:$LINENO: checking for egrep" >&5 echo $ECHO_N "checking for egrep... $ECHO_C" >&6; } if test "${ac_cv_path_EGREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 then ac_cv_path_EGREP="$GREP -E" else # Extract the first word of "egrep" to use in msg output if test -z "$EGREP"; then set dummy egrep; ac_prog_name=$2 if test "${ac_cv_path_EGREP+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_path_EGREP_found=false # Loop through the user's path and test for each of PROGNAME-LIST as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_prog in egrep; do for ac_exec_ext in '' $ac_executable_extensions; do ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue # Check for GNU ac_path_EGREP and select it if it is found. # Check for GNU $ac_path_EGREP case `"$ac_path_EGREP" --version 2>&1` in *GNU*) ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; *) ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >"conftest.in" while : do cat "conftest.in" "conftest.in" >"conftest.tmp" mv "conftest.tmp" "conftest.in" cp "conftest.in" "conftest.nl" echo 'EGREP' >> "conftest.nl" "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break ac_count=`expr $ac_count + 1` if test $ac_count -gt ${ac_path_EGREP_max-0}; then # Best one so far, save it but keep looking for a better one ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_max=$ac_count fi # 10*(2^10) chars as input seems more than enough test $ac_count -gt 10 && break done rm -f conftest.in conftest.tmp conftest.nl conftest.out;; esac $ac_path_EGREP_found && break 3 done done done IFS=$as_save_IFS fi EGREP="$ac_cv_path_EGREP" if test -z "$EGREP"; then { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5 echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;} { (exit 1); exit 1; }; } fi else ac_cv_path_EGREP=$EGREP fi fi fi { echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5 echo "${ECHO_T}$ac_cv_path_EGREP" >&6; } EGREP="$ac_cv_path_EGREP" { echo "$as_me:$LINENO: checking for ANSI C header files" >&5 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; } if test "${ac_cv_header_stdc+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <stdlib.h> #include <stdarg.h> #include <string.h> #include <float.h> int main () { ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_header_stdc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_header_stdc=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext if test $ac_cv_header_stdc = yes; then # SunOS 4.x string.h does not declare mem*, contrary to ANSI. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <string.h> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "memchr" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <stdlib.h> _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "free" >/dev/null 2>&1; then : else ac_cv_header_stdc=no fi rm -f conftest* fi if test $ac_cv_header_stdc = yes; then # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. if test "$cross_compiling" = yes; then : else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <ctype.h> #include <stdlib.h> #if ((' ' & 0x0FF) == 0x020) # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) #else # define ISLOWER(c) \ (('a' <= (c) && (c) <= 'i') \ || ('j' <= (c) && (c) <= 'r') \ || ('s' <= (c) && (c) <= 'z')) # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) #endif #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) int main () { int i; for (i = 0; i < 256; i++) if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) return 2; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then : else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_header_stdc=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi fi { echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5 echo "${ECHO_T}$ac_cv_header_stdc" >&6; } if test $ac_cv_header_stdc = yes; then cat >>confdefs.h <<\_ACEOF #define STDC_HEADERS 1 _ACEOF fi { echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5 echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6; } if test "${ac_cv_header_sys_wait_h+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <sys/types.h> #include <sys/wait.h> #ifndef WEXITSTATUS # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8) #endif #ifndef WIFEXITED # define WIFEXITED(stat_val) (((stat_val) & 255) == 0) #endif int main () { int s; wait (&s); s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_header_sys_wait_h=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_header_sys_wait_h=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5 echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6; } if test $ac_cv_header_sys_wait_h = yes; then cat >>confdefs.h <<\_ACEOF #define HAVE_SYS_WAIT_H 1 _ACEOF fi # On IRIX 5.3, sys/types and inttypes.h are conflicting. for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ inttypes.h stdint.h unistd.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then eval "$as_ac_Header=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_Header=no" fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_header in arpa/inet.h fcntl.h libintl.h netdb.h netinet/in.h stdint.h stdlib.h string.h sys/file.h sys/ioctl.h sys/socket.h sys/time.h sys/timeb.h unistd.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## --------------------------------- ## ## Report this to bill.cheng@acm.org ## ## --------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done # Checks for typedefs, structures, and compiler characteristics. { echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6; } if test "${ac_cv_c_const+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ int main () { /* FIXME: Include the comments suggested by Paul. */ #ifndef __cplusplus /* Ultrix mips cc rejects this. */ typedef int charset[2]; const charset cs; /* SunOS 4.1.1 cc rejects this. */ char const *const *pcpcc; char **ppc; /* NEC SVR4.0.2 mips cc rejects this. */ struct point {int x, y;}; static struct point const zero = {0,0}; /* AIX XL C 1.02.0.0 rejects this. It does not let you subtract one const X* pointer from another in an arm of an if-expression whose if-part is not a constant expression */ const char *g = "string"; pcpcc = &g + (g ? g-g : 0); /* HPUX 7.0 cc rejects these. */ ++pcpcc; ppc = (char**) pcpcc; pcpcc = (char const *const *) ppc; { /* SCO 3.2v4 cc rejects this. */ char *t; char const *s = 0 ? (char *) 0 : (char const *) 0; *t++ = 0; if (s) return 0; } { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ int x[] = {25, 17}; const int *foo = &x[0]; ++foo; } { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ typedef const int *iptr; iptr p = 0; ++p; } { /* AIX XL C 1.02.0.0 rejects this saying "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ struct s { int j; const int *ap[3]; }; struct s *b; b->j = 5; } { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ const int foo = 10; if (!foo) return 0; } return !cs[0] && !zero.x; #endif ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_c_const=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_c_const=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5 echo "${ECHO_T}$ac_cv_c_const" >&6; } if test $ac_cv_c_const = no; then cat >>confdefs.h <<\_ACEOF #define const _ACEOF fi { echo "$as_me:$LINENO: checking for mode_t" >&5 echo $ECHO_N "checking for mode_t... $ECHO_C" >&6; } if test "${ac_cv_type_mode_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default typedef mode_t ac__type_new_; int main () { if ((ac__type_new_ *) 0) return 0; if (sizeof (ac__type_new_)) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_type_mode_t=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_type_mode_t=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_type_mode_t" >&5 echo "${ECHO_T}$ac_cv_type_mode_t" >&6; } if test $ac_cv_type_mode_t = yes; then : else cat >>confdefs.h <<_ACEOF #define mode_t int _ACEOF fi { echo "$as_me:$LINENO: checking for size_t" >&5 echo $ECHO_N "checking for size_t... $ECHO_C" >&6; } if test "${ac_cv_type_size_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default typedef size_t ac__type_new_; int main () { if ((ac__type_new_ *) 0) return 0; if (sizeof (ac__type_new_)) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_type_size_t=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_type_size_t=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_type_size_t" >&5 echo "${ECHO_T}$ac_cv_type_size_t" >&6; } if test $ac_cv_type_size_t = yes; then : else cat >>confdefs.h <<_ACEOF #define size_t unsigned int _ACEOF fi { echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6; } if test "${ac_cv_header_time+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <sys/types.h> #include <sys/time.h> #include <time.h> int main () { if ((struct tm *) 0) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_header_time=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_header_time=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5 echo "${ECHO_T}$ac_cv_header_time" >&6; } if test $ac_cv_header_time = yes; then cat >>confdefs.h <<\_ACEOF #define TIME_WITH_SYS_TIME 1 _ACEOF fi { echo "$as_me:$LINENO: checking for uint16_t" >&5 echo $ECHO_N "checking for uint16_t... $ECHO_C" >&6; } if test "${ac_cv_c_uint16_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_c_uint16_t=no for ac_type in 'uint16_t' 'unsigned int' 'unsigned long int' \ 'unsigned long long int' 'unsigned short int' 'unsigned char'; do cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { static int test_array [1 - 2 * !(($ac_type) -1 >> (16 - 1) == 1)]; test_array [0] = 0 ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then case $ac_type in uint16_t) ac_cv_c_uint16_t=yes ;; *) ac_cv_c_uint16_t=$ac_type ;; esac else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext test "$ac_cv_c_uint16_t" != no && break done fi { echo "$as_me:$LINENO: result: $ac_cv_c_uint16_t" >&5 echo "${ECHO_T}$ac_cv_c_uint16_t" >&6; } case $ac_cv_c_uint16_t in #( no|yes) ;; #( *) cat >>confdefs.h <<_ACEOF #define uint16_t $ac_cv_c_uint16_t _ACEOF ;; esac { echo "$as_me:$LINENO: checking for uint32_t" >&5 echo $ECHO_N "checking for uint32_t... $ECHO_C" >&6; } if test "${ac_cv_c_uint32_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_cv_c_uint32_t=no for ac_type in 'uint32_t' 'unsigned int' 'unsigned long int' \ 'unsigned long long int' 'unsigned short int' 'unsigned char'; do cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { static int test_array [1 - 2 * !(($ac_type) -1 >> (32 - 1) == 1)]; test_array [0] = 0 ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then case $ac_type in uint32_t) ac_cv_c_uint32_t=yes ;; *) ac_cv_c_uint32_t=$ac_type ;; esac else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext test "$ac_cv_c_uint32_t" != no && break done fi { echo "$as_me:$LINENO: result: $ac_cv_c_uint32_t" >&5 echo "${ECHO_T}$ac_cv_c_uint32_t" >&6; } case $ac_cv_c_uint32_t in #( no|yes) ;; #( *) cat >>confdefs.h <<\_ACEOF #define _UINT32_T 1 _ACEOF cat >>confdefs.h <<_ACEOF #define uint32_t $ac_cv_c_uint32_t _ACEOF ;; esac # Checks for library functions. { echo "$as_me:$LINENO: checking whether closedir returns void" >&5 echo $ECHO_N "checking whether closedir returns void... $ECHO_C" >&6; } if test "${ac_cv_func_closedir_void+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_closedir_void=yes else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header_dirent> #ifndef __cplusplus int closedir (); #endif int main () { return closedir (opendir (".")) != 0; ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_closedir_void=no else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_closedir_void=yes fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_closedir_void" >&5 echo "${ECHO_T}$ac_cv_func_closedir_void" >&6; } if test $ac_cv_func_closedir_void = yes; then cat >>confdefs.h <<\_ACEOF #define CLOSEDIR_VOID 1 _ACEOF fi { echo "$as_me:$LINENO: checking for pid_t" >&5 echo $ECHO_N "checking for pid_t... $ECHO_C" >&6; } if test "${ac_cv_type_pid_t+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default typedef pid_t ac__type_new_; int main () { if ((ac__type_new_ *) 0) return 0; if (sizeof (ac__type_new_)) return 0; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_type_pid_t=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_type_pid_t=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5 echo "${ECHO_T}$ac_cv_type_pid_t" >&6; } if test $ac_cv_type_pid_t = yes; then : else cat >>confdefs.h <<_ACEOF #define pid_t int _ACEOF fi for ac_header in vfork.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## --------------------------------- ## ## Report this to bill.cheng@acm.org ## ## --------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done for ac_func in fork vfork do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func. For example, HP-UX 11i <limits.h> declares gettimeofday. */ #define $ac_func innocuous_$ac_func /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. Prefer <limits.h> to <assert.h> if __STDC__ is defined, since <limits.h> exists even on freestanding compilers. */ #ifdef __STDC__ # include <limits.h> #else # include <assert.h> #endif #undef $ac_func /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $ac_func (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$ac_func || defined __stub___$ac_func choke me #endif int main () { return $ac_func (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then eval "$as_ac_var=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_var=no" fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_var'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done if test "x$ac_cv_func_fork" = xyes; then { echo "$as_me:$LINENO: checking for working fork" >&5 echo $ECHO_N "checking for working fork... $ECHO_C" >&6; } if test "${ac_cv_func_fork_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_fork_works=cross else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { /* By Ruediger Kuhlmann. */ return fork () < 0; ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_fork_works=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_fork_works=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5 echo "${ECHO_T}$ac_cv_func_fork_works" >&6; } else ac_cv_func_fork_works=$ac_cv_func_fork fi if test "x$ac_cv_func_fork_works" = xcross; then case $host in *-*-amigaos* | *-*-msdosdjgpp*) # Override, as these systems have only a dummy fork() stub ac_cv_func_fork_works=no ;; *) ac_cv_func_fork_works=yes ;; esac { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} fi ac_cv_func_vfork_works=$ac_cv_func_vfork if test "x$ac_cv_func_vfork" = xyes; then { echo "$as_me:$LINENO: checking for working vfork" >&5 echo $ECHO_N "checking for working vfork... $ECHO_C" >&6; } if test "${ac_cv_func_vfork_works+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_vfork_works=cross else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Thanks to Paul Eggert for this test. */ $ac_includes_default #include <sys/wait.h> #ifdef HAVE_VFORK_H # include <vfork.h> #endif /* On some sparc systems, changes by the child to local and incoming argument registers are propagated back to the parent. The compiler is told about this with #include <vfork.h>, but some compilers (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a static variable whose address is put into a register that is clobbered by the vfork. */ static void #ifdef __cplusplus sparc_address_test (int arg) # else sparc_address_test (arg) int arg; #endif { static pid_t child; if (!child) { child = vfork (); if (child < 0) { perror ("vfork"); _exit(2); } if (!child) { arg = getpid(); write(-1, "", 0); _exit (arg); } } } int main () { pid_t parent = getpid (); pid_t child; sparc_address_test (0); child = vfork (); if (child == 0) { /* Here is another test for sparc vfork register problems. This test uses lots of local variables, at least as many local variables as main has allocated so far including compiler temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should reuse the register of parent for one of the local variables, since it will think that parent can't possibly be used any more in this routine. Assigning to the local variable will thus munge parent in the parent process. */ pid_t p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); /* Convince the compiler that p..p7 are live; otherwise, it might use the same hardware register for all 8 local variables. */ if (p != p1 || p != p2 || p != p3 || p != p4 || p != p5 || p != p6 || p != p7) _exit(1); /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent from child file descriptors. If the child closes a descriptor before it execs or exits, this munges the parent's descriptor as well. Test for this by closing stdout in the child. */ _exit(close(fileno(stdout)) != 0); } else { int status; struct stat st; while (wait(&status) != child) ; return ( /* Was there some problem with vforking? */ child < 0 /* Did the child fail? (This shouldn't happen.) */ || status /* Did the vfork/compiler bug occur? */ || parent != getpid() /* Did the file descriptor bug occur? */ || fstat(fileno(stdout), &st) != 0 ); } } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_vfork_works=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_vfork_works=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5 echo "${ECHO_T}$ac_cv_func_vfork_works" >&6; } fi; if test "x$ac_cv_func_fork_works" = xcross; then ac_cv_func_vfork_works=$ac_cv_func_vfork { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} fi if test "x$ac_cv_func_vfork_works" = xyes; then cat >>confdefs.h <<\_ACEOF #define HAVE_WORKING_VFORK 1 _ACEOF else cat >>confdefs.h <<\_ACEOF #define vfork fork _ACEOF fi if test "x$ac_cv_func_fork_works" = xyes; then cat >>confdefs.h <<\_ACEOF #define HAVE_WORKING_FORK 1 _ACEOF fi if test $ac_cv_c_compiler_gnu = yes; then { echo "$as_me:$LINENO: checking whether $CC needs -traditional" >&5 echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6; } if test "${ac_cv_prog_gcc_traditional+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_pattern="Autoconf.*'x'" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <sgtty.h> Autoconf TIOCGETP _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "$ac_pattern" >/dev/null 2>&1; then ac_cv_prog_gcc_traditional=yes else ac_cv_prog_gcc_traditional=no fi rm -f conftest* if test $ac_cv_prog_gcc_traditional = no; then cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <termio.h> Autoconf TCGETA _ACEOF if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | $EGREP "$ac_pattern" >/dev/null 2>&1; then ac_cv_prog_gcc_traditional=yes fi rm -f conftest* fi fi { echo "$as_me:$LINENO: result: $ac_cv_prog_gcc_traditional" >&5 echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6; } if test $ac_cv_prog_gcc_traditional = yes; then CC="$CC -traditional" fi fi { echo "$as_me:$LINENO: checking whether lstat dereferences a symlink specified with a trailing slash" >&5 echo $ECHO_N "checking whether lstat dereferences a symlink specified with a trailing slash... $ECHO_C" >&6; } if test "${ac_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else rm -f conftest.sym conftest.file echo >conftest.file if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then if test "$cross_compiling" = yes; then ac_cv_func_lstat_dereferences_slashed_symlink=no else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { struct stat sbuf; /* Linux will dereference the symlink and fail. That is better in the sense that it means we will not have to compile and use the lstat wrapper. */ return lstat ("conftest.sym/", &sbuf) == 0; ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_lstat_dereferences_slashed_symlink=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_lstat_dereferences_slashed_symlink=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi else # If the `ln -s' command failed, then we probably don't even # have an lstat function. ac_cv_func_lstat_dereferences_slashed_symlink=no fi rm -f conftest.sym conftest.file fi { echo "$as_me:$LINENO: result: $ac_cv_func_lstat_dereferences_slashed_symlink" >&5 echo "${ECHO_T}$ac_cv_func_lstat_dereferences_slashed_symlink" >&6; } test $ac_cv_func_lstat_dereferences_slashed_symlink = yes && cat >>confdefs.h <<_ACEOF #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1 _ACEOF if test $ac_cv_func_lstat_dereferences_slashed_symlink = no; then case " $LIBOBJS " in *" lstat.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS lstat.$ac_objext" ;; esac fi { echo "$as_me:$LINENO: checking whether lstat accepts an empty string" >&5 echo $ECHO_N "checking whether lstat accepts an empty string... $ECHO_C" >&6; } if test "${ac_cv_func_lstat_empty_string_bug+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_lstat_empty_string_bug=yes else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { struct stat sbuf; return lstat ("", &sbuf) == 0; ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_lstat_empty_string_bug=no else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_lstat_empty_string_bug=yes fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_lstat_empty_string_bug" >&5 echo "${ECHO_T}$ac_cv_func_lstat_empty_string_bug" >&6; } if test $ac_cv_func_lstat_empty_string_bug = yes; then case " $LIBOBJS " in *" lstat.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS lstat.$ac_objext" ;; esac cat >>confdefs.h <<_ACEOF #define HAVE_LSTAT_EMPTY_STRING_BUG 1 _ACEOF fi { echo "$as_me:$LINENO: checking whether lstat dereferences a symlink specified with a trailing slash" >&5 echo $ECHO_N "checking whether lstat dereferences a symlink specified with a trailing slash... $ECHO_C" >&6; } if test "${ac_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else rm -f conftest.sym conftest.file echo >conftest.file if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then if test "$cross_compiling" = yes; then ac_cv_func_lstat_dereferences_slashed_symlink=no else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { struct stat sbuf; /* Linux will dereference the symlink and fail. That is better in the sense that it means we will not have to compile and use the lstat wrapper. */ return lstat ("conftest.sym/", &sbuf) == 0; ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_lstat_dereferences_slashed_symlink=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_lstat_dereferences_slashed_symlink=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi else # If the `ln -s' command failed, then we probably don't even # have an lstat function. ac_cv_func_lstat_dereferences_slashed_symlink=no fi rm -f conftest.sym conftest.file fi { echo "$as_me:$LINENO: result: $ac_cv_func_lstat_dereferences_slashed_symlink" >&5 echo "${ECHO_T}$ac_cv_func_lstat_dereferences_slashed_symlink" >&6; } test $ac_cv_func_lstat_dereferences_slashed_symlink = yes && cat >>confdefs.h <<_ACEOF #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1 _ACEOF if test $ac_cv_func_lstat_dereferences_slashed_symlink = no; then case " $LIBOBJS " in *" lstat.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS lstat.$ac_objext" ;; esac fi for ac_header in stdlib.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## --------------------------------- ## ## Report this to bill.cheng@acm.org ## ## --------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done { echo "$as_me:$LINENO: checking for GNU libc compatible malloc" >&5 echo $ECHO_N "checking for GNU libc compatible malloc... $ECHO_C" >&6; } if test "${ac_cv_func_malloc_0_nonnull+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_malloc_0_nonnull=no else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #if defined STDC_HEADERS || defined HAVE_STDLIB_H # include <stdlib.h> #else char *malloc (); #endif int main () { return ! malloc (0); ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_malloc_0_nonnull=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_malloc_0_nonnull=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_malloc_0_nonnull" >&5 echo "${ECHO_T}$ac_cv_func_malloc_0_nonnull" >&6; } if test $ac_cv_func_malloc_0_nonnull = yes; then cat >>confdefs.h <<\_ACEOF #define HAVE_MALLOC 1 _ACEOF else cat >>confdefs.h <<\_ACEOF #define HAVE_MALLOC 0 _ACEOF case " $LIBOBJS " in *" malloc.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS malloc.$ac_objext" ;; esac cat >>confdefs.h <<\_ACEOF #define malloc rpl_malloc _ACEOF fi { echo "$as_me:$LINENO: checking for working memcmp" >&5 echo $ECHO_N "checking for working memcmp... $ECHO_C" >&6; } if test "${ac_cv_func_memcmp_working+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_memcmp_working=no else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { /* Some versions of memcmp are not 8-bit clean. */ char c0 = '\100', c1 = '\200', c2 = '\201'; if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0) return 1; /* The Next x86 OpenStep bug shows up only when comparing 16 bytes or more and with at least one buffer not starting on a 4-byte boundary. William Lewis provided this test program. */ { char foo[21]; char bar[21]; int i; for (i = 0; i < 4; i++) { char *a = foo + i; char *b = bar + i; strcpy (a, "--------01111111"); strcpy (b, "--------10000000"); if (memcmp (a, b, 16) >= 0) return 1; } return 0; } ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_memcmp_working=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_memcmp_working=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5 echo "${ECHO_T}$ac_cv_func_memcmp_working" >&6; } test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in *" memcmp.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS memcmp.$ac_objext" ;; esac for ac_header in stdlib.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## --------------------------------- ## ## Report this to bill.cheng@acm.org ## ## --------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done { echo "$as_me:$LINENO: checking for GNU libc compatible realloc" >&5 echo $ECHO_N "checking for GNU libc compatible realloc... $ECHO_C" >&6; } if test "${ac_cv_func_realloc_0_nonnull+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_realloc_0_nonnull=no else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #if defined STDC_HEADERS || defined HAVE_STDLIB_H # include <stdlib.h> #else char *realloc (); #endif int main () { return ! realloc (0, 0); ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_realloc_0_nonnull=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_realloc_0_nonnull=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_realloc_0_nonnull" >&5 echo "${ECHO_T}$ac_cv_func_realloc_0_nonnull" >&6; } if test $ac_cv_func_realloc_0_nonnull = yes; then cat >>confdefs.h <<\_ACEOF #define HAVE_REALLOC 1 _ACEOF else cat >>confdefs.h <<\_ACEOF #define HAVE_REALLOC 0 _ACEOF case " $LIBOBJS " in *" realloc.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS realloc.$ac_objext" ;; esac cat >>confdefs.h <<\_ACEOF #define realloc rpl_realloc _ACEOF fi for ac_header in sys/select.h sys/socket.h do as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh` if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } else # Is the header compilable? { echo "$as_me:$LINENO: checking $ac_header usability" >&5 echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #include <$ac_header> _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_header_compiler=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_compiler=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_compiler" >&5 echo "${ECHO_T}$ac_header_compiler" >&6; } # Is the header present? { echo "$as_me:$LINENO: checking $ac_header presence" >&5 echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; } cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <$ac_header> _ACEOF if { (ac_try="$ac_cpp conftest.$ac_ext" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } >/dev/null && { test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || test ! -s conftest.err }; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_header_preproc=no fi rm -f conftest.err conftest.$ac_ext { echo "$as_me:$LINENO: result: $ac_header_preproc" >&5 echo "${ECHO_T}$ac_header_preproc" >&6; } # So? What about this header? case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in yes:no: ) { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5 echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;} ac_header_preproc=yes ;; no:yes:* ) { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5 echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5 echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5 echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5 echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5 echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;} { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5 echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;} ( cat <<\_ASBOX ## --------------------------------- ## ## Report this to bill.cheng@acm.org ## ## --------------------------------- ## _ASBOX ) | sed "s/^/$as_me: WARNING: /" >&2 ;; esac { echo "$as_me:$LINENO: checking for $ac_header" >&5 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; } if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else eval "$as_ac_Header=\$ac_header_preproc" fi ac_res=`eval echo '${'$as_ac_Header'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } fi if test `eval echo '${'$as_ac_Header'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_header" | $as_tr_cpp` 1 _ACEOF fi done { echo "$as_me:$LINENO: checking types of arguments for select" >&5 echo $ECHO_N "checking types of arguments for select... $ECHO_C" >&6; } if test "${ac_cv_func_select_args+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else for ac_arg234 in 'fd_set *' 'int *' 'void *'; do for ac_arg1 in 'int' 'size_t' 'unsigned long int' 'unsigned int'; do for ac_arg5 in 'struct timeval *' 'const struct timeval *'; do cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #ifdef HAVE_SYS_SELECT_H # include <sys/select.h> #endif #ifdef HAVE_SYS_SOCKET_H # include <sys/socket.h> #endif int main () { extern int select ($ac_arg1, $ac_arg234, $ac_arg234, $ac_arg234, $ac_arg5); ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_func_select_args="$ac_arg1,$ac_arg234,$ac_arg5"; break 3 else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext done done done # Provide a safe default value. : ${ac_cv_func_select_args='int,int *,struct timeval *'} fi { echo "$as_me:$LINENO: result: $ac_cv_func_select_args" >&5 echo "${ECHO_T}$ac_cv_func_select_args" >&6; } ac_save_IFS=$IFS; IFS=',' set dummy `echo "$ac_cv_func_select_args" | sed 's/\*/\*/g'` IFS=$ac_save_IFS shift cat >>confdefs.h <<_ACEOF #define SELECT_TYPE_ARG1 $1 _ACEOF cat >>confdefs.h <<_ACEOF #define SELECT_TYPE_ARG234 ($2) _ACEOF cat >>confdefs.h <<_ACEOF #define SELECT_TYPE_ARG5 ($3) _ACEOF rm -f conftest* { echo "$as_me:$LINENO: checking return type of signal handlers" >&5 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6; } if test "${ac_cv_type_signal+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #include <sys/types.h> #include <signal.h> int main () { return *(signal (0, 0)) (0) == 1; ; return 0; } _ACEOF rm -f conftest.$ac_objext if { (ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_compile") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then ac_cv_type_signal=int else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_type_signal=void fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_type_signal" >&5 echo "${ECHO_T}$ac_cv_type_signal" >&6; } cat >>confdefs.h <<_ACEOF #define RETSIGTYPE $ac_cv_type_signal _ACEOF { echo "$as_me:$LINENO: checking whether stat accepts an empty string" >&5 echo $ECHO_N "checking whether stat accepts an empty string... $ECHO_C" >&6; } if test "${ac_cv_func_stat_empty_string_bug+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_stat_empty_string_bug=yes else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default int main () { struct stat sbuf; return stat ("", &sbuf) == 0; ; return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_stat_empty_string_bug=no else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_stat_empty_string_bug=yes fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_stat_empty_string_bug" >&5 echo "${ECHO_T}$ac_cv_func_stat_empty_string_bug" >&6; } if test $ac_cv_func_stat_empty_string_bug = yes; then case " $LIBOBJS " in *" stat.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS stat.$ac_objext" ;; esac cat >>confdefs.h <<_ACEOF #define HAVE_STAT_EMPTY_STRING_BUG 1 _ACEOF fi { echo "$as_me:$LINENO: checking for working strtod" >&5 echo $ECHO_N "checking for working strtod... $ECHO_C" >&6; } if test "${ac_cv_func_strtod+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else if test "$cross_compiling" = yes; then ac_cv_func_strtod=no else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ $ac_includes_default #ifndef strtod double strtod (); #endif int main() { { /* Some versions of Linux strtod mis-parse strings with leading '+'. */ char *string = " +69"; char *term; double value; value = strtod (string, &term); if (value != 69 || term != (string + 4)) return 1; } { /* Under Solaris 2.4, strtod returns the wrong value for the terminating character under some conditions. */ char *string = "NaN"; char *term; strtod (string, &term); if (term != string && *(term - 1) == 0) return 1; } return 0; } _ACEOF rm -f conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { ac_try='./conftest$ac_exeext' { (case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_try") 2>&5 ac_status=$? echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); }; }; then ac_cv_func_strtod=yes else echo "$as_me: program exited with status $ac_status" >&5 echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ( exit $ac_status ) ac_cv_func_strtod=no fi rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext fi fi { echo "$as_me:$LINENO: result: $ac_cv_func_strtod" >&5 echo "${ECHO_T}$ac_cv_func_strtod" >&6; } if test $ac_cv_func_strtod = no; then case " $LIBOBJS " in *" strtod.$ac_objext "* ) ;; *) LIBOBJS="$LIBOBJS strtod.$ac_objext" ;; esac { echo "$as_me:$LINENO: checking for pow" >&5 echo $ECHO_N "checking for pow... $ECHO_C" >&6; } if test "${ac_cv_func_pow+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Define pow to an innocuous variant, in case <limits.h> declares pow. For example, HP-UX 11i <limits.h> declares gettimeofday. */ #define pow innocuous_pow /* System header to define __stub macros and hopefully few prototypes, which can conflict with char pow (); below. Prefer <limits.h> to <assert.h> if __STDC__ is defined, since <limits.h> exists even on freestanding compilers. */ #ifdef __STDC__ # include <limits.h> #else # include <assert.h> #endif #undef pow /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char pow (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_pow || defined __stub___pow choke me #endif int main () { return pow (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_func_pow=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_func_pow=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi { echo "$as_me:$LINENO: result: $ac_cv_func_pow" >&5 echo "${ECHO_T}$ac_cv_func_pow" >&6; } if test $ac_cv_func_pow = no; then { echo "$as_me:$LINENO: checking for pow in -lm" >&5 echo $ECHO_N "checking for pow in -lm... $ECHO_C" >&6; } if test "${ac_cv_lib_m_pow+set}" = set; then echo $ECHO_N "(cached) $ECHO_C" >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lm $LIBS" cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char pow (); int main () { return pow (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then ac_cv_lib_m_pow=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_cv_lib_m_pow=no fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { echo "$as_me:$LINENO: result: $ac_cv_lib_m_pow" >&5 echo "${ECHO_T}$ac_cv_lib_m_pow" >&6; } if test $ac_cv_lib_m_pow = yes; then POW_LIB=-lm else { echo "$as_me:$LINENO: WARNING: cannot find library containing definition of pow" >&5 echo "$as_me: WARNING: cannot find library containing definition of pow" >&2;} fi fi fi for ac_func in ftime getcwd gethostbyname gethostname gettimeofday memmove memset mkdir pow putenv select setlocale socket sqrt strchr strpbrk strrchr strstr strtol do as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` { echo "$as_me:$LINENO: checking for $ac_func" >&5 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; } if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then echo $ECHO_N "(cached) $ECHO_C" >&6 else cat >conftest.$ac_ext <<_ACEOF /* confdefs.h. */ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func. For example, HP-UX 11i <limits.h> declares gettimeofday. */ #define $ac_func innocuous_$ac_func /* System header to define __stub macros and hopefully few prototypes, which can conflict with char $ac_func (); below. Prefer <limits.h> to <assert.h> if __STDC__ is defined, since <limits.h> exists even on freestanding compilers. */ #ifdef __STDC__ # include <limits.h> #else # include <assert.h> #endif #undef $ac_func /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char $ac_func (); /* The GNU C library defines this for functions which it implements to always fail with ENOSYS. Some functions are actually named something starting with __ and the normal name is an alias. */ #if defined __stub_$ac_func || defined __stub___$ac_func choke me #endif int main () { return $ac_func (); ; return 0; } _ACEOF rm -f conftest.$ac_objext conftest$ac_exeext if { (ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5 (eval "$ac_link") 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: \$? = $ac_status" >&5 (exit $ac_status); } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && $as_test_x conftest$ac_exeext; then eval "$as_ac_var=yes" else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 eval "$as_ac_var=no" fi rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \ conftest$ac_exeext conftest.$ac_ext fi ac_res=`eval echo '${'$as_ac_var'}'` { echo "$as_me:$LINENO: result: $ac_res" >&5 echo "${ECHO_T}$ac_res" >&6; } if test `eval echo '${'$as_ac_var'}'` = yes; then cat >>confdefs.h <<_ACEOF #define `echo "HAVE_$ac_func" | $as_tr_cpp` 1 _ACEOF fi done ac_config_files="$ac_config_files Makefile" # BC: skipping AC_CONFIG_SUBDIRS([rmcast]) cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure # scripts and configure runs, see configure's option --config-cache. # It is not useful on other systems. If it contains results you don't # want to keep, you may remove or edit it. # # config.status only pays attention to the cache file if you give it # the --recheck option to rerun configure. # # `ac_cv_env_foo' variables (set or unset) will be overridden when # loading this file, other *unset* `ac_cv_foo' will be assigned the # following values. _ACEOF # The following way of writing the cache mishandles newlines in values, # but we know of no workaround that is simple, portable, and efficient. # So, we kill variables containing newlines. # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. ( for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5 echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( *) $as_unset $ac_var ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) # `set' does not quote correctly, so add quotes (double-quote # substitution turns \\\\ into \\, and sed turns \\ into \). sed -n \ "s/'/'\\\\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" ;; #( *) # `set' quotes correctly as required by POSIX, so do not add quotes. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) | sed ' /^ac_cv_env_/b end t clear :clear s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ t end s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then test "x$cache_file" != "x/dev/null" && { echo "$as_me:$LINENO: updating cache $cache_file" >&5 echo "$as_me: updating cache $cache_file" >&6;} cat confcache >$cache_file else { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5 echo "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi rm -f confcache test "x$prefix" = xNONE && prefix=$ac_default_prefix # Let make expand exec_prefix. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' DEFS=-DHAVE_CONFIG_H ac_libobjs= ac_ltlibobjs= for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue # 1. Remove the extension, and $U if already installed. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' ac_i=`echo "$ac_i" | sed "$ac_script"` # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR # will be set to the directory where LIBOBJS objects are built. ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext" ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo' done LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then { { echo "$as_me:$LINENO: error: conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." >&5 echo "$as_me: error: conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." >&2;} { (exit 1); exit 1; }; } fi : ${CONFIG_STATUS=./config.status} ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5 echo "$as_me: creating $CONFIG_STATUS" >&6;} cat >$CONFIG_STATUS <<_ACEOF #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. # Compiler output produced by configure, useful for debugging # configure, is in config.log if it exists. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF ## --------------------- ## ## M4sh Initialization. ## ## --------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix ;; esac fi # PATH needs CR # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then echo "#! /bin/sh" >conf$$.sh echo "exit 0" >>conf$$.sh chmod +x conf$$.sh if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then PATH_SEPARATOR=';' else PATH_SEPARATOR=: fi rm -f conf$$.sh fi # Support unset when possible. if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then as_unset=unset else as_unset=false fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) as_nl=' ' IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. case $0 in *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 { (exit 1); exit 1; } fi # Work around bugs in pre-3.0 UWIN ksh. for as_var in ENV MAIL MAILPATH do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. for as_var in \ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \ LC_TELEPHONE LC_TIME do if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then eval $as_var=C; export $as_var else ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var fi done # Required to use basename. if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi # Name of the executable. as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # CDPATH. $as_unset CDPATH as_lineno_1=$LINENO as_lineno_2=$LINENO test "x$as_lineno_1" != "x$as_lineno_2" && test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || { # Create $as_me.lineno as a copy of $as_myself, but with $LINENO # uniformly replaced by the line number. The first 'sed' inserts a # line-number line after each line using $LINENO; the second 'sed' # does the real work. The second script uses 'N' to pair each # line-number line with the line containing $LINENO, and appends # trailing '-' during substitution so that $LINENO is not a special # case at line end. # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the # scripts with optimization help from Paolo Bonzini. Blame Lee # E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2 { (exit 1); exit 1; }; } # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in -n*) case `echo 'x\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. *) ECHO_C='\c';; esac;; *) ECHO_N='-n';; esac if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir fi echo >conf$$.file if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p=: else test -d ./-p && rmdir ./-p as_mkdir_p=false fi if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 # Save the log message, to keep $[0] and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by tgif $as_me 4.2.5, which was generated by GNU Autoconf 2.61. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ on `(hostname || uname -n) 2>/dev/null | sed 1q` " _ACEOF cat >>$CONFIG_STATUS <<_ACEOF # Files that config.status was made for. config_files="$ac_config_files" config_headers="$ac_config_headers" config_commands="$ac_config_commands" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF ac_cs_usage="\ \`$as_me' instantiates files from templates according to the current configuration. Usage: $0 [OPTIONS] [FILE]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit -q, --quiet do not print progress messages -d, --debug don't remove temporary files --recheck update $as_me by reconfiguring in the same conditions --file=FILE[:TEMPLATE] instantiate the configuration file FILE --header=FILE[:TEMPLATE] instantiate the configuration header FILE Configuration files: $config_files Configuration headers: $config_headers Configuration commands: $config_commands Report bugs to <bug-autoconf@gnu.org>." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF ac_cs_version="\\ tgif config.status 4.2.5 configured by $0, generated by GNU Autoconf 2.61, with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" Copyright (C) 2006 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='$ac_pwd' srcdir='$srcdir' INSTALL='$INSTALL' MKDIR_P='$MKDIR_P' _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # If no file are specified by the user, then we need to provide default # value. By we need to know if files were specified by the user. ac_need_defaults=: while test $# != 0 do case $1 in --*=*) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` ac_shift=: ;; *) ac_option=$1 ac_optarg=$2 ac_shift=shift ;; esac case $ac_option in # Handling of the options. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) echo "$ac_cs_version"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift CONFIG_FILES="$CONFIG_FILES $ac_optarg" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg" ac_need_defaults=false;; --he | --h) # Conflict between --help and --header { echo "$as_me: error: ambiguous option: $1 Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; };; --help | --hel | -h ) echo "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) { echo "$as_me: error: unrecognized option: $1 Try \`$0 --help' for more information." >&2 { (exit 1); exit 1; }; } ;; *) ac_config_targets="$ac_config_targets $1" ac_need_defaults=false ;; esac shift done ac_configure_extra_args= if $ac_cs_silent; then exec 6>/dev/null ac_configure_extra_args="$ac_configure_extra_args --silent" fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF if \$ac_cs_recheck; then echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6 CONFIG_SHELL=$SHELL export CONFIG_SHELL exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion fi _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX echo "$ac_log" } >&5 _ACEOF cat >>$CONFIG_STATUS <<_ACEOF # # INIT-COMMANDS # AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # Handling of arguments. for ac_config_target in $ac_config_targets do case $ac_config_target in "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5 echo "$as_me: error: invalid argument: $ac_config_target" >&2;} { (exit 1); exit 1; }; };; esac done # If the user did not use the arguments to specify the items to instantiate, # then the envvar interface is used. Set only those that are not. # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason against having it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: # after its creation but before its name has been assigned to `$tmp'. $debug || { tmp= trap 'exit_status=$? { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status ' 0 trap '{ (exit 1); exit 1; }' 1 2 13 15 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || { echo "$me: cannot create a temporary directory in ." >&2 { (exit 1); exit 1; } } # # Set up the sed scripts for CONFIG_FILES section. # # No need to generate the scripts if there are no CONFIG_FILES. # This happens for instance when ./config.status config.h if test -n "$CONFIG_FILES"; then _ACEOF ac_delim='%!_!# ' for ac_last_try in false false false false false :; do cat >conf$$subs.sed <<_ACEOF SHELL!$SHELL$ac_delim PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim PACKAGE_NAME!$PACKAGE_NAME$ac_delim PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim PACKAGE_STRING!$PACKAGE_STRING$ac_delim PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim exec_prefix!$exec_prefix$ac_delim prefix!$prefix$ac_delim program_transform_name!$program_transform_name$ac_delim bindir!$bindir$ac_delim sbindir!$sbindir$ac_delim libexecdir!$libexecdir$ac_delim datarootdir!$datarootdir$ac_delim datadir!$datadir$ac_delim sysconfdir!$sysconfdir$ac_delim sharedstatedir!$sharedstatedir$ac_delim localstatedir!$localstatedir$ac_delim includedir!$includedir$ac_delim oldincludedir!$oldincludedir$ac_delim docdir!$docdir$ac_delim infodir!$infodir$ac_delim htmldir!$htmldir$ac_delim dvidir!$dvidir$ac_delim pdfdir!$pdfdir$ac_delim psdir!$psdir$ac_delim libdir!$libdir$ac_delim localedir!$localedir$ac_delim mandir!$mandir$ac_delim DEFS!$DEFS$ac_delim ECHO_C!$ECHO_C$ac_delim ECHO_N!$ECHO_N$ac_delim ECHO_T!$ECHO_T$ac_delim LIBS!$LIBS$ac_delim build_alias!$build_alias$ac_delim host_alias!$host_alias$ac_delim target_alias!$target_alias$ac_delim INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim INSTALL_DATA!$INSTALL_DATA$ac_delim am__isrc!$am__isrc$ac_delim CYGPATH_W!$CYGPATH_W$ac_delim PACKAGE!$PACKAGE$ac_delim VERSION!$VERSION$ac_delim ACLOCAL!$ACLOCAL$ac_delim AUTOCONF!$AUTOCONF$ac_delim AUTOMAKE!$AUTOMAKE$ac_delim AUTOHEADER!$AUTOHEADER$ac_delim MAKEINFO!$MAKEINFO$ac_delim install_sh!$install_sh$ac_delim STRIP!$STRIP$ac_delim INSTALL_STRIP_PROGRAM!$INSTALL_STRIP_PROGRAM$ac_delim mkdir_p!$mkdir_p$ac_delim AWK!$AWK$ac_delim SET_MAKE!$SET_MAKE$ac_delim am__leading_dot!$am__leading_dot$ac_delim AMTAR!$AMTAR$ac_delim am__tar!$am__tar$ac_delim am__untar!$am__untar$ac_delim CC!$CC$ac_delim CFLAGS!$CFLAGS$ac_delim LDFLAGS!$LDFLAGS$ac_delim CPPFLAGS!$CPPFLAGS$ac_delim ac_ct_CC!$ac_ct_CC$ac_delim EXEEXT!$EXEEXT$ac_delim OBJEXT!$OBJEXT$ac_delim DEPDIR!$DEPDIR$ac_delim am__include!$am__include$ac_delim am__quote!$am__quote$ac_delim AMDEP_TRUE!$AMDEP_TRUE$ac_delim AMDEP_FALSE!$AMDEP_FALSE$ac_delim AMDEPBACKSLASH!$AMDEPBACKSLASH$ac_delim CCDEPMODE!$CCDEPMODE$ac_delim am__fastdepCC_TRUE!$am__fastdepCC_TRUE$ac_delim am__fastdepCC_FALSE!$am__fastdepCC_FALSE$ac_delim XMKMF!$XMKMF$ac_delim CPP!$CPP$ac_delim GREP!$GREP$ac_delim EGREP!$EGREP$ac_delim LIBOBJS!$LIBOBJS$ac_delim POW_LIB!$POW_LIB$ac_delim LTLIBOBJS!$LTLIBOBJS$ac_delim _ACEOF if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 82; then break elif $ac_last_try; then { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5 echo "$as_me: error: could not make $CONFIG_STATUS" >&2;} { (exit 1); exit 1; }; } else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed` if test -n "$ac_eof"; then ac_eof=`echo "$ac_eof" | sort -nru | sed 1q` ac_eof=`expr $ac_eof + 1` fi cat >>$CONFIG_STATUS <<_ACEOF cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof /@[a-zA-Z_][a-zA-Z_0-9]*@/!b end _ACEOF sed ' s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g s/^/s,@/; s/!/@,|#_!!_#|/ :n t n s/'"$ac_delim"'$/,g/; t s/$/\\/; p N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n ' >>$CONFIG_STATUS <conf$$subs.sed rm -f conf$$subs.sed cat >>$CONFIG_STATUS <<_ACEOF :end s/|#_!!_#|//g CEOF$ac_eof _ACEOF # VPATH may cause trouble with some makes, so we remove $(srcdir), # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and # trailing colons and then remove the whole line if VPATH becomes empty # (actually we leave an empty line to preserve line numbers). if test "x$srcdir" = x.; then ac_vpsub='/^[ ]*VPATH[ ]*=/{ s/:*\$(srcdir):*/:/ s/:*\${srcdir}:*/:/ s/:*@srcdir@:*/:/ s/^\([^=]*=[ ]*\):*/\1/ s/:*$// s/^[^=]*=[ ]*$// }' fi cat >>$CONFIG_STATUS <<\_ACEOF fi # test -n "$CONFIG_FILES" for ac_tag in :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS do case $ac_tag in :[FHLC]) ac_mode=$ac_tag; continue;; esac case $ac_mode$ac_tag in :[FHL]*:*);; :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5 echo "$as_me: error: Invalid tag $ac_tag." >&2;} { (exit 1); exit 1; }; };; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac ac_save_IFS=$IFS IFS=: set x $ac_tag IFS=$ac_save_IFS shift ac_file=$1 shift case $ac_mode in :L) ac_source=$1;; :[FH]) ac_file_inputs= for ac_f do case $ac_f in -) ac_f="$tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, # because $ac_f cannot contain `:'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5 echo "$as_me: error: cannot find input file: $ac_f" >&2;} { (exit 1); exit 1; }; };; esac ac_file_inputs="$ac_file_inputs $ac_f" done # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input="Generated from "`IFS=: echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure." if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { echo "$as_me:$LINENO: creating $ac_file" >&5 echo "$as_me: creating $ac_file" >&6;} fi case $ac_tag in *:-:* | *:-) cat >"$tmp/stdin";; esac ;; esac ac_dir=`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` { as_dir="$ac_dir" case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 echo "$as_me: error: cannot create directory $as_dir" >&2;} { (exit 1); exit 1; }; }; } ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix case $ac_mode in :F) # # CONFIG_FILE # case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac ac_MKDIR_P=$MKDIR_P case $MKDIR_P in [\\/$]* | ?:[\\/]* ) ;; */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; esac _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= case `sed -n '/datarootdir/ { p q } /@datadir@/p /@docdir@/p /@infodir@/p /@localedir@/p /@mandir@/p ' $ac_file_inputs` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF cat >>$CONFIG_STATUS <<_ACEOF ac_datarootdir_hack=' s&@datadir@&$datadir&g s&@docdir@&$docdir&g s&@infodir@&$infodir&g s&@localedir@&$localedir&g s&@mandir@&$mandir&g s&\\\${datarootdir}&$datarootdir&g' ;; esac _ACEOF # Neutralize VPATH when `$srcdir' = `.'. # Shell code in configure.ac might set extrasub. # FIXME: do we really want to maintain this feature? cat >>$CONFIG_STATUS <<_ACEOF sed "$ac_vpsub $extrasub _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s&@configure_input@&$configure_input&;t t s&@top_builddir@&$ac_top_builddir_sub&;t t s&@srcdir@&$ac_srcdir&;t t s&@abs_srcdir@&$ac_abs_srcdir&;t t s&@top_srcdir@&$ac_top_srcdir&;t t s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t s&@builddir@&$ac_builddir&;t t s&@abs_builddir@&$ac_abs_builddir&;t t s&@abs_top_builddir@&$ac_abs_top_builddir&;t t s&@INSTALL@&$ac_INSTALL&;t t s&@MKDIR_P@&$ac_MKDIR_P&;t t $ac_datarootdir_hack " $ac_file_inputs | sed -f "$tmp/subs-1.sed" >$tmp/out test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&5 echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&2;} rm -f "$tmp/stdin" case $ac_file in -) cat "$tmp/out"; rm -f "$tmp/out";; *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;; esac ;; :H) # # CONFIG_HEADER # _ACEOF # Transform confdefs.h into a sed script `conftest.defines', that # substitutes the proper values into config.h.in to produce config.h. rm -f conftest.defines conftest.tail # First, append a space to every undef/define line, to ease matching. echo 's/$/ /' >conftest.defines # Then, protect against being on the right side of a sed subst, or in # an unquoted here document, in config.status. If some macros were # called several times there might be several #defines for the same # symbol, which is useless. But do not sort them, since the last # AC_DEFINE must be honored. ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* # These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where # NAME is the cpp macro being defined, VALUE is the value it is being given. # PARAMS is the parameter list in the macro definition--in most cases, it's # just an empty string. ac_dA='s,^\\([ #]*\\)[^ ]*\\([ ]*' ac_dB='\\)[ (].*,\\1define\\2' ac_dC=' ' ac_dD=' ,' uniq confdefs.h | sed -n ' t rset :rset s/^[ ]*#[ ]*define[ ][ ]*// t ok d :ok s/[\\&,]/\\&/g s/^\('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p s/^\('"$ac_word_re"'\)[ ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p ' >>conftest.defines # Remove the space that was appended to ease matching. # Then replace #undef with comments. This is necessary, for # example, in the case of _POSIX_SOURCE, which is predefined and required # on some systems where configure will not decide to define it. # (The regexp can be short, since the line contains either #define or #undef.) echo 's/ $// s,^[ #]*u.*,/* & */,' >>conftest.defines # Break up conftest.defines: ac_max_sed_lines=50 # First sed command is: sed -f defines.sed $ac_file_inputs >"$tmp/out1" # Second one is: sed -f defines.sed "$tmp/out1" >"$tmp/out2" # Third one will be: sed -f defines.sed "$tmp/out2" >"$tmp/out1" # et cetera. ac_in='$ac_file_inputs' ac_out='"$tmp/out1"' ac_nxt='"$tmp/out2"' while : do # Write a here document: cat >>$CONFIG_STATUS <<_ACEOF # First, check the format of the line: cat >"\$tmp/defines.sed" <<\\CEOF /^[ ]*#[ ]*undef[ ][ ]*$ac_word_re[ ]*\$/b def /^[ ]*#[ ]*define[ ][ ]*$ac_word_re[( ]/b def b :def _ACEOF sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS echo 'CEOF sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail grep . conftest.tail >/dev/null || break rm -f conftest.defines mv conftest.tail conftest.defines done rm -f conftest.defines conftest.tail echo "ac_result=$ac_in" >>$CONFIG_STATUS cat >>$CONFIG_STATUS <<\_ACEOF if test x"$ac_file" != x-; then echo "/* $configure_input */" >"$tmp/config.h" cat "$ac_result" >>"$tmp/config.h" if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then { echo "$as_me:$LINENO: $ac_file is unchanged" >&5 echo "$as_me: $ac_file is unchanged" >&6;} else rm -f $ac_file mv "$tmp/config.h" $ac_file fi else echo "/* $configure_input */" cat "$ac_result" fi rm -f "$tmp/out12" # Compute $ac_file's index in $config_headers. _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $ac_file | $ac_file:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $ac_file" >`$as_dirname -- $ac_file || $as_expr X$ac_file : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X$ac_file : 'X\(//\)[^/]' \| \ X$ac_file : 'X\(//\)$' \| \ X$ac_file : 'X\(/\)' \| . 2>/dev/null || echo X$ac_file | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'`/stamp-h$_am_stamp_count ;; :C) { echo "$as_me:$LINENO: executing $ac_file commands" >&5 echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "depfiles":C) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # Grep'ing the whole file is not good either: AIX grep has a line # limit of 2048, but all sed's we know have understand at least 4000. if sed 10q "$mf" | grep '^#.*generated by automake' > /dev/null 2>&1; then dirpart=`$as_dirname -- "$mf" || $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$mf" : 'X\(//\)[^/]' \| \ X"$mf" : 'X\(//\)$' \| \ X"$mf" : 'X\(/\)' \| . 2>/dev/null || echo X"$mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`$as_dirname -- "$file" || $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$file" : 'X\(//\)[^/]' \| \ X"$file" : 'X\(//\)$' \| \ X"$file" : 'X\(/\)' \| . 2>/dev/null || echo X"$file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` { as_dir=$dirpart/$fdir case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5 echo "$as_me: error: cannot create directory $as_dir" >&2;} { (exit 1); exit 1; }; }; } # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done ;; esac done # for ac_tag { (exit 0); exit 0; } _ACEOF chmod +x $CONFIG_STATUS ac_clean_files=$ac_clean_files_save # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || { (exit 1); exit 1; } fi �����������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/pattern.e����������������������������������������������������������������������������0000644�0000764�0000764�00000011630�11602233312�014610� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/pattern.e,v 1.7 2011/05/16 16:21:58 william Exp $ */ #ifndef _PATTERN_E_ #define _PATTERN_E_ extern int objFill; extern int transPat; extern int lineStyle; extern int lineWidth; extern int penPat; extern int curSpline; extern int curDash; extern int rcbRadius; extern int useGray; extern char patternStr[]; extern int stickyMenuSelection; #ifdef _INCLUDE_FROM_PATTERN_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_PATTERN_C_*/ extern void ResetGrayDetection ARGS_DECL((void)); extern char * GrayStr ARGS_DECL((int Index)); extern void GrayCheck ARGS_DECL((int Index)); extern void EndGrayDetection ARGS_DECL((void)); extern int RefreshModeMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateModeMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int ModeMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int ChangeObjTransPat ARGS_DECL((struct ObjRec *, int FillIndex)); extern void ChangeAllSelTransPat ARGS_DECL((int Index, int HighLight)); extern int ChangeObjFill ARGS_DECL((struct ObjRec *, int FillIndex)); extern void ChangeAllSelFill ARGS_DECL((int Index, int HighLight)); extern void RefreshFillMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateFillMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int FillMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void ChangeAllSelLineStyle ARGS_DECL((int Index, int HighLight)); extern void RefreshLineStyleMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateLineStyleMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int LineStyleMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int GetPolyOrPolygonControlPoints ARGS_DECL((struct ObjRec *, struct PolyRec **, struct PolygonRec **, int *pn_curved, int *pn_num_pts, IntPoint**, char **ppsz_smooth)); extern void ChangeAllSelLineType ARGS_DECL((int Index, int HighLight)); extern void RefreshLineTypeMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateLineTypeMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int LineTypeMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void ChangeAllSelLineWidth ARGS_DECL((int Index, int HighLight)); extern int GetBestLineWidthIndex ARGS_DECL((int width, int aw, int ah)); extern void RefreshLineWidthMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateLineWidthMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int LineWidthMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void ChangeAllSelLineDash ARGS_DECL((int Index, int HighLight)); extern void RefreshLineDashMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateLineDashMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int LineDashMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern int ChangeObjPen ARGS_DECL((struct ObjRec *, int PenIndex)); extern void ChangeAllSelPen ARGS_DECL((int Index, int HighLight)); extern void RefreshPenMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreatePenMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int PenMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void ToggleAllSelLineType ARGS_DECL((void)); extern void ChangeAllSelRCBRadius ARGS_DECL((int Radius)); extern void UpdateSelObjs ARGS_DECL((void)); extern void ChangeAllSelRealLineWidth ARGS_DECL((int nMask, int Width, int AW, int AH, char*, char*, char*, int HighLight)); extern void SetSelLineWidth ARGS_DECL((char*)); #ifdef _INCLUDE_FROM_PATTERN_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_PATTERN_C_*/ #endif /*_PATTERN_E_*/ ��������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/pin.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000033021�11602233312�013715� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/pin.c,v 1.6 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_PIN_C_ #include "tgifdefs.h" #include "auxtext.e" #include "choice.e" #include "color.e" #include "dialog.e" #include "drawing.e" #include "mainloop.e" #include "msg.e" #include "navigate.e" #include "obj.e" #include "pin.e" #include "poly.e" #include "raster.e" #include "rect.e" #include "select.e" #include "setup.e" #include "strtbl.e" int drawPolyToConnectPins=0; struct ObjRec *gpStartPin=NULL, *gpEndPin=NULL; static struct SelRec *topPinSel=NULL, *botPinSel=NULL; static struct ObjRec *gpHighLightedPin=NULL; static void CleanUpPinInfo() { struct SelRec *next_sel=NULL; for ( ; topPinSel != NULL; topPinSel=next_sel) { next_sel = topPinSel->next; free(topPinSel); } topPinSel = botPinSel = NULL; gpStartPin = gpEndPin = NULL; } static void CachePin(ObjPtr) struct ObjRec *ObjPtr; { struct SelRec *sel_ptr=(struct SelRec *)malloc(sizeof(struct SelRec)); if (sel_ptr == NULL) FailAllocMessage(); memset(sel_ptr, 0, sizeof(struct SelRec)); sel_ptr->obj = ObjPtr; sel_ptr->next = topPinSel; sel_ptr->prev = NULL; if (topPinSel == NULL) { botPinSel = sel_ptr; } else { topPinSel->prev = sel_ptr; } topPinSel = sel_ptr; } static void PreparePinInfoForAnObject(ObjPtr, nInsideAnIcon) struct ObjRec *ObjPtr; int nInsideAnIcon; { struct ObjRec *obj_ptr=NULL; switch (ObjPtr->type) { case OBJ_GROUP: case OBJ_SYM: for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (colorLayers && !ObjInVisibleLayer(obj_ptr)) { continue; } PreparePinInfoForAnObject(obj_ptr, nInsideAnIcon); } break; case OBJ_ICON: if (nInsideAnIcon) return; for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (colorLayers && !ObjInVisibleLayer(obj_ptr)) { continue; } PreparePinInfoForAnObject(obj_ptr, TRUE); } break; case OBJ_PIN: CachePin(ObjPtr); break; default: return; } } static void PreparePinInfo() { struct ObjRec *obj_ptr=NULL; gpStartPin = gpEndPin = NULL; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { obj_ptr->tmp_child = NULL; obj_ptr->tmp_parent = NULL; if (colorLayers && !ObjInVisibleLayer(obj_ptr)) { continue; } PreparePinInfoForAnObject(obj_ptr, FALSE); } } static int GetPins(pObj, ppTopSel, ppBotSel) struct ObjRec *pObj; struct SelRec **ppTopSel, **ppBotSel; { switch (pObj->type) { case OBJ_GROUP: break; case OBJ_SYM: break; case OBJ_ICON: break; case OBJ_PIN: break; default: return FALSE; } topPinSel = botPinSel = NULL; if (pObj->type == OBJ_PIN) { PreparePinInfoForAnObject(pObj, FALSE); } else { struct ObjRec *pSubObj=NULL; int nInsideAnIcon=(pObj->type==OBJ_ICON); for (pSubObj=pObj->detail.r->first; pSubObj != NULL; pSubObj=pSubObj->next) { PreparePinInfoForAnObject(pSubObj, nInsideAnIcon); } } if (topPinSel == NULL) return FALSE; if (ppTopSel != NULL) *ppTopSel = topPinSel; if (ppBotSel != NULL) *ppBotSel = botPinSel; topPinSel = botPinSel = NULL; return TRUE; } static int AddObjToSorted(pObj, ppTopSel, ppBotSel) struct ObjRec *pObj; struct SelRec **ppTopSel, **ppBotSel; { int nIndex=(int)(long)(pObj->userdata); struct SelRec *pSel=NULL; for (pSel=(*ppTopSel); pSel != NULL; pSel=pSel->next) { if (nIndex > (int)(long)(pSel->obj->userdata)) { return (AddObjIntoSel(pObj, pSel->prev, pSel, ppTopSel, ppBotSel) != NULL); } } return (AddObjIntoSel(pObj, (*ppBotSel), NULL, ppTopSel, ppBotSel) != NULL); } int FindExtraPoly(pTopSel, pBotSel, ppTopSel, ppBotSel, pnCount, pBBox) struct SelRec *pTopSel, *pBotSel; struct SelRec **ppTopSel, **ppBotSel; int *pnCount; struct BBRec *pBBox; { struct SelRec *pSel=NULL, *first_poly_sel=NULL, *last_poly_sel=NULL; pBBox->ltx = pTopSel->obj->bbox.ltx; pBBox->lty = pTopSel->obj->bbox.lty; pBBox->rbx = pTopSel->obj->bbox.rbx; pBBox->rby = pTopSel->obj->bbox.rby; if (pnCount != NULL) (*pnCount) = 0; for (pSel=pTopSel; pSel != NULL; pSel=pSel->next) { struct SelRec *top_pin_sel=NULL, *bot_pin_sel=NULL; if (GetPins(pSel->obj, &top_pin_sel, &bot_pin_sel)) { struct SelRec *pin_sel_ptr=NULL; for (pin_sel_ptr=top_pin_sel; pin_sel_ptr != NULL; pin_sel_ptr=pin_sel_ptr->next) { struct ConnRec *conn_ptr=NULL; for (conn_ptr=pin_sel_ptr->obj->detail.r->first_conn; conn_ptr != NULL; conn_ptr=conn_ptr->next) { if (FindObjInSel(conn_ptr->poly_obj, first_poly_sel, last_poly_sel) == NULL) { PrependObjToSel(conn_ptr->poly_obj, &first_poly_sel, &last_poly_sel); } } } JustFreeSel(top_pin_sel, bot_pin_sel); } } if (first_poly_sel == NULL) { return FALSE; } else { struct SelRec *pPolySel=NULL, *pNextPolySel=NULL; struct SelRec *pTopSortedSel=NULL, *pBotSortedSel=NULL; for (pPolySel=first_poly_sel; pPolySel != NULL; pPolySel=pNextPolySel) { struct ObjRec *pPolyObj=pPolySel->obj; pNextPolySel = pPolySel->next; for (pSel=pTopSel; pSel != NULL; pSel=pSel->next) { if (pSel->obj == pPolyObj) { UnlinkSel(pPolySel, &first_poly_sel, &last_poly_sel); free(pPolySel); break; } } if (pSel == NULL) { struct ObjRec *pObj=NULL; int nIndex=0; for (pObj=topObj; pObj != NULL; pObj=pObj->next, nIndex++) { if (pObj == pPolyObj) { pPolyObj->userdata = (void*)(long)nIndex; if (AddObjToSorted(pPolyObj, &pTopSortedSel, &pBotSortedSel)) { } if (pnCount != NULL) (*pnCount)++; ExpandBBox(&pPolyObj->bbox, pBBox); break; } } } } JustFreeSel(first_poly_sel, last_poly_sel); first_poly_sel = pTopSortedSel; last_poly_sel = pBotSortedSel; } if (first_poly_sel == NULL) return FALSE; if (ppTopSel != NULL) *ppTopSel = first_poly_sel; if (ppBotSel != NULL) *ppBotSel = last_poly_sel; return TRUE; } static struct ObjRec *FindPinObj(AbsX, AbsY) int AbsX, AbsY; { struct SelRec *sel_ptr=NULL; for (sel_ptr=topPinSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (PointInBBox(AbsX, AbsY, sel_ptr->obj->obbox)) { return sel_ptr->obj; } } return NULL; } void HighLightAPin(forward) int forward; { if (drawPolyHighlightedNode != NULL) { SelBox(drawWindow, revGrayGC, OFFSET_X(drawPolyHighlightedNode->obbox.ltx)-2, OFFSET_Y(drawPolyHighlightedNode->obbox.lty)-2, OFFSET_X(drawPolyHighlightedNode->obbox.rbx)+2, OFFSET_Y(drawPolyHighlightedNode->obbox.rby)+2); if (forward) { gpHighLightedPin = drawPolyHighlightedNode; } else { gpHighLightedPin = NULL; } } } void HandlePinHighlights(MouseX, MouseY) int MouseX, MouseY; { int need_to_highlight=FALSE, something_changed=FALSE; struct ObjRec *obj_under_cursor=NULL; obj_under_cursor = FindPinObj(ABS_X(MouseX), ABS_Y(MouseY)); if (drawPolyHighlightedNode != NULL) { if (obj_under_cursor != drawPolyHighlightedNode) { /* un-highlight */ HighLightAPin(FALSE); if (obj_under_cursor != NULL) { drawPolyHighlightedNode = obj_under_cursor; /* may need to call something like SetWiringNodeInfo()!? */ } else { drawPolyHighlightedNode = NULL; /* may need to call something like SetWiringNodeInfo()!? */ } if (drawPolyHighlightedNode != NULL) { need_to_highlight = TRUE; } something_changed = TRUE; } } else { if (obj_under_cursor != NULL) { drawPolyHighlightedNode = obj_under_cursor; /* may need to call something like SetWiringNodeInfo()!? */ need_to_highlight = TRUE; something_changed = TRUE; } } if (need_to_highlight) { HighLightAPin(TRUE); } } static void AppendConnToPin(pPinObj, pConn, pPolyObj) struct ObjRec *pPinObj, *pPolyObj; struct ConnRec *pConn; { pPinObj->detail.r->pin_connected++; pConn->pin_obj = pPinObj; pConn->poly_obj = pPolyObj; pConn->prev = pPinObj->detail.r->last_conn; pConn->next = NULL; if (pPinObj->detail.r->last_conn == NULL) { pPinObj->detail.r->first_conn = pConn; } else { pPinObj->detail.r->last_conn->next = pConn; } pPinObj->detail.r->last_conn = pConn; } static void CreateConnection(pStartPin, pEndPin) struct ObjRec *pStartPin, *pEndPin; { struct ConnRec *pStartConn=NULL, *pEndConn=NULL; pStartConn = (struct ConnRec *)malloc(sizeof(struct ConnRec)); pEndConn = (struct ConnRec *)malloc(sizeof(struct ConnRec)); if (pStartConn == NULL || pEndConn == NULL) { FailAllocMessage(); if (pStartConn != NULL) free(pStartConn); if (pEndConn != NULL) free(pEndConn); return; } memset(pStartConn, 0, sizeof(struct ConnRec)); memset(pEndConn, 0, sizeof(struct ConnRec)); topObj->detail.p->start_conn = pStartConn; topObj->detail.p->end_conn = pEndConn; pStartConn->at_start = TRUE; pEndConn->at_start = FALSE; AppendConnToPin(pStartPin, pStartConn, topObj); AppendConnToPin(pEndPin, pEndConn, topObj); } void ConnectPins() { int already_in_hyperspace=inHyperSpace, connecting=TRUE; XGCValues values; PreparePinInfo(); if (topPinSel == NULL) { MsgBox(TgLoadString(STID_NO_PINS_FOUND_IN_CUR_DRAWING), TOOL_NAME, INFO_MB); return; } MakeQuiescent(); ResetWiringNodeInfo(); values.line_width = 3; XChangeGC(mainDisplay, revGrayGC, GCLineWidth, &values); SetCurChoice(DRAWPOLY); gstWiringInfo.num_ports_to_connect = 0; while (connecting) { drawPolyToConnectPins = 2; drawPolyHighlightedNode = gpHighLightedPin = NULL; gpStartPin = gpEndPin = NULL; SetStringStatus(TgLoadCachedString(CSTID_SEL_A_PIN_ESC_TO_END_DOTS)); for (;;) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose) { ExposeEventHandler(&input, TRUE); } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { connecting = FALSE; break; } } else if (input.xany.window == drawWindow) { polyDrawn = FALSE; DrawingEventHandler(&input); if (curChoice == DRAWPOLY) { if (polyDrawn) { break; } else if (drawPolyToConnectPins == (-1)) { break; } } else { polyDrawn = FALSE; break; } } } drawPolyToConnectPins = 0; if (gpHighLightedPin != NULL) { drawPolyHighlightedNode = gpHighLightedPin; /* may need to call something like SetWiringNodeInfo()!? */ HighLightAPin(FALSE); } drawPolyHighlightedNode = gpHighLightedPin = NULL; if (gpStartPin != NULL && gpEndPin != NULL) { CreateConnection(gpStartPin, gpEndPin); } } SetCurChoice(NOTHING); values.line_width = 1; XChangeGC(mainDisplay, revGrayGC, GCLineWidth, &values); if (already_in_hyperspace && !inHyperSpace) ToggleHyperSpace(TRUE); CleanUpPinInfo(); } void FreeConn(pConn) struct ConnRec *pConn; { free(pConn); } static void UnlinkConn(pConn) struct ConnRec *pConn; { struct GroupRec *pGroup=pConn->pin_obj->detail.r; if (pGroup->first_conn == pConn) { pGroup->first_conn = pConn->next; } else { pConn->prev->next = pConn->next; } if (pGroup->last_conn == pConn) { pGroup->last_conn = pConn->prev; } else { pConn->next->prev = pConn->prev; } pGroup->pin_connected--; pConn->pin_obj = NULL; } void DelConnFromPoly(pConn) struct ConnRec *pConn; { pConn->poly_obj = NULL; UnlinkConn(pConn); FreeConn(pConn); } void DelConnFromPin(pConn) struct ConnRec *pConn; { /* struct ObjRec *pPinObj=pConn->pin_obj; */ struct ObjRec *pPolyObj=pConn->poly_obj; if (pConn->at_start) { pPolyObj->detail.p->start_conn = NULL; } else { pPolyObj->detail.p->end_conn = NULL; } UnlinkConn(pConn); FreeConn(pConn); DelObj(pPolyObj); } void CleanUpPins() { } int InitPins() { return TRUE; } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgif.man�����������������������������������������������������������������������������0000644�0000764�0000764�00000731174�11602233313�014430� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������.\" Tgif's man pages. .\" .\" @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgif.man,v 1.104 2011/05/23 02:56:57 william Exp $ .\" .\" .\" .\" .\" .\" .\" .TH tgif n "Version 4.2 Patchlevel 3 and Above" "Tgif" .\" .SH NAME .\" \fItgif\fR \- Xlib based interactive 2-D drawing facility under X11. Supports hierarchical construction of drawings and easy navigation between sets of drawings. It's also a hyper-graphics (or hyper-structured-graphics) browser on the World-Wide-Web. .\" .SH SYNOPSIS .\" .B tgif [\fB-display\fR displayname] [\fB-fg\fR <color>] [\fB-bg\fR <color>] [\fB-bd\fR <color>] [\fB-rv\fR] [\fB-nv\fR] [\fB-bw\fR] [\fB-reqcolor\fR] [\fB-cwo[+sbwarp]\fR] [\fB-hyper\fR] [\fB-exec <file>\fR] [\fB-dbim {xcin|chinput|xim|kinput2|tgtwb5[,font]}\fR] [\fB-sbim xim\fR] [\fB-usexlib\fR] [\fB{-a4|-letter}\fR] [\fB-listdontreencode\fR] [\fB-version\fR] [\fB-pdfspd | -pdfspd=true | -pdfspd=false \fR] [\fB-pssetup "<string>" \fR] [\fB-tgwb2 [-rmcastlibdir <directory> | -rmcastlibpath <path>]\fR] [\fB-nomode\fR] [\fB-geometry\fR <geom>] [\fB=<geom>\fR] [{\fIfile\fR[.\fIobj\fR]|\fB-merge\fR \fIfile1\fR[.\fIobj\fR] \fIfile2\fR[.\fIobj\fR] ...}] .PP or .PP .B tgif \fB-print\fR [\fB-eps\fR] [\fB-p\fR] [\fB-ps\fR] [\fB-f\fR] [\fB-text\fR] [\fB-epsi\fR] [\fB-tiffepsi\fR] [\fB-gif\fR] [\fB-png\fR] [\fB-jpeg\fR] [\fB-ppm\fR] [\fB-pbm\fR] [\fB-xpm\fR] [\fB-xbm\fR] [\fB-html\fR] [\fB-pdf\fR] [\fB-netlist\fR] [\fB-svg\fR] [\fB-display\fR displayname] [\fB-stdout\fR] [\fB-raw[+h[eaderonly]]\fR] [\fB-dosepsfilter\fR [\fB-previewonly\fR]] [\fB-status\fR] [\fB-gray\fR] [\fB-color | -reqcolor\fR] [\fB-adobe | -adobe=<number>/<number> | -adobe=false \fR] [\fB-dontreencode=<string> | -listdontreencode\fR] [\fB-version\fR | \fB-justversion\fR] [\fB-producedby=<string>\fR] [\fB-page <number>\fR] [\fB-print_cmd "<command>"\fR] [\fB-one_file_per_page\fR] [\fB-pepsc\fR] [\fB-pdfspd | -pdfspd=true | -pdfspd=false \fR] [\fB-pssetup "<string>" \fR] [\fB-j2p6_cmd "<command>" \fR] [\fB-dontcondense | -condensed\fR] [\fB{-a4|-letter}\fR] [\fB-noshowpageineps\fR] [\fB-quiet\fR] [\fB-bop_hook "<string>"\fR] [\fB-eop_hook "<string>"\fR] [\fB-tmp_file_mode "<octal number>"\fR] [\fB-patterndir "<xbm directory>"\fR] [\fB-o\fR<dir>] [\fB-exec <file>\fR] [\fIfile1\fR[.\fIobj\fR] \fIfile2\fR[.\fIobj\fR] ...] .\" .SH DESCRIPTION .\" \fITgif\fR is an interactive drawing tool that allows the user to draw and manipulate objects in the X Window System. Tgif runs interactively in the first form. In the second form shown in the SYNOPSIS section, tgif just prints \fIfile1.obj\fR, \fIfile2.obj\fR, etc. (generated by \fItgif\fR) into PostScript(TM) page description files (without opening windows or fonts) and pipes them to lpr(1) if none of the \fB-eps\fR, \fB-p\fR, \fB-epsi\fR, \fB-tiffepsi\fR, \fB-gif\fR, \fB-png\fR, \fB-jpeg\fR, \fB-ppm\fR, \fB-pbm\fR, \fB-xpm\fR, \fB-xbm\fR, \fB-html\fR, \fB-pdf\fR, \fB-ps\fR, \fB-f\fR, \fB-text\fR, \fB-netlist\fR, or \fB-svg\fR options are specified. This form of \fIprinting\fR is tgif's way of \fIexporting\fR a tgif file to another format. In this case, any other unrecognized command line options are sent to lpr(1). In this mode, tgif is compatible with the obsoleted \fIprtgif\fR. A symbol file (see descriptions below) can also be printed by specifying the \fI.sym\fR extension explicitly. .PP The command line argument \fIfile\fR specifies a file or an Uniform Resource Locator (URL) of objects to be initially edited by tgif. Only HTTP or FTP URL's are supported. (For a more detailed description of URL and the World-Wide-Web, the reader is referred to [1].) .PP Tgif is purely based on \fIXlib\fR. It is tested under X11R6, and it requires a 3 button mouse. .\" .SH OPTIONS .\" In the first form shown in the SYNOPSIS section, the command line arguments can be: .TP .B -fg Foreground color specified in <color>. .TP .B -bg Background color specified in <color>. .TP .B -bd Border color specified in <color>. .TP .B -rv Start tgif in reversed-video mode. .TP .B -nv Start tgif in normal-video mode. .TP .B -bw Start tgif in black and white mode. .TP .B -reqcolor Same effect as setting the Tgif.PrintUsingRequestedColor X default to true (see the X DEFAULTS section below). .TP .B -cwo Canvas Window Only. Only the canvas window (see TGIF SUBWINDOWS section below) will be displayed. This has the same effect as setting the Tgif.CanvasWindowOnly X default to true. .TP .B -cwo+sbwarp If \fB-cwo+sbwarp\fR is used, single-button-warp (clicking the left mouse button to warp) is used to activate teleporting (see TELEPORT/HYPERJUMP section below). .TP .B -hyper Start tgif in the \fIhyperspace\fR mode (see HYPERSPACE section below). .TP .B -exec <file> After tgif starts, execute the internal command in <file> (see INTERNAL COMMANDS section below). If <file> is the string "-", tgif executes internal commands from the standard input. .TP .B -dbim \fImethod\fR Use \fImethod\fR as the input method for double-byte fonts (see SQUARE DOUBLE BYTE FONTS section below). This cannot be used in conjunction with \fI-sbim\fR. .TP .B -sbim \fImethod\fR Use \fImethod\fR as the input method for single-byte fonts. This is useful if the X Keyboard Extension is used in inputing international characters (with dead keys). This cannot be used in conjunction with \fI-dbim\fR. .TP .B -usexlib If tgif is compiled with -DUSE_XT_INITIALIZE, X Toolkit initialization routines will be used to setup tgif. Using this command line option will force tgif to ignore the -DUSE_XT_INITIALIZE compiler option and use Xlib only. This is useful when the system resource file for tgif is not installed properly or messed up and needs to be bypassed. .TP .B -a4 Using this option has the same effect as setting the Tgif.PSA4PaperSize X default to true. .TP .B -letter Using this option has the same effect as setting the Tgif.InitialPaperSize X default to "letter" .TP .B -noshowpageineps Using this option has the same effect as setting the Tgif.ShowPageInEPS X default to false. .TP .B -quiet If this option is used, tgif will suppress standard messages. .TP .B -listdontreencode=<string> If this option is used, tgif will print out the list of PostScript font names specified in the -D_DONT_REENCODE compiler option used in compiling tgif. .PP In the second form shown in the SYNOPSIS section, the command line arguments can be: .TP .B -version If this option is used, tgif will print out its version number and copyright on the command line. .TP .B -justversion If this option is used, tgif will print out its version number and copyright on the command line and exits immediately. .TP .B -nomode Using this option has the same effect as setting the Tgif.NoModeWindow X default to true. .TP .B -eps \fR(or\fB -p\fR)\fB Generates an Encapsulated PostScript(TM) file in \fIfile.eps\fR; this file can be included in a LaTeX file through the \\psfig, \\epsf, or \\psfile construct (see the LATEX FIGURE FORMATS section below). .TP .B -ps \fR(or\fB -f\fR)\fB Generates a PostScript file in \fIfile.ps\fR; this file can be printed to a PostScript printer with lpr(1). .TP .B -text Generates a text file in \fIfile.txt\fR; the text file contains all visible text and can be fed to a spell checker. .TP .B -epsi Generates an Encapsulated PostScript (EPS) file with a preview bitmap in \fIfile.eps\fR. Tgif aborts if a valid display is not accessible. .TP .B -tiffepsi Generates an EPS file with a DOS EPS Binary File Header and a trailing TIFF image in \fIfile.eps\fR. See the GENERATING MICROSOFT WINDOWS EPSI FILES section for more details. Tgif aborts if a valid display is not accessible. .TP .B -gif Generates a GIF file in \fIfile.gif\fR. Please see the notes for Tgif.GifToXpm in the X DEFAULTS section below. Tgif aborts if a valid display is not accessible. .TP .B -png Generates a PNG file in \fIfile.png\fR. Tgif aborts if a valid display is not accessible. .TP .B -jpeg Generates a JPEG file in \fIfile.jpg\fR. Tgif aborts if a valid display is not accessible. .TP .B -ppm Generates a PPM file in \fIfile.ppm\fR. Tgif aborts if a valid display is not accessible. .TP .B -pbm Generates a PBM file in \fIfile.pbm\fR. Tgif aborts if a valid display is not accessible. .TP .B -xpm Generates an X11 pixmap (XPM) file in \fIfile.xpm\fR. Tgif aborts if a valid display is not accessible. .TP .B -xbm Generates an X11 bitmap (XBM) file in \fIfile.xbm\fR. Tgif aborts if a valid display is not accessible. .TP .B -html Generates a GIF file in \fIfile.gif\fR and an HTML file in \fIfile.html\fR. Tgif aborts if a valid display is not accessible. .TP .B -pdf Generates a PDF file in \fIfile.pdf\fR. Please see the notes for Tgif.PsToPdf in the X DEFAULTS section below. .TP .B -netlist Generates a text file in \fIfile.net\fR and a text file in \fIfile.cmp\fR. \fIfile.net\fR contains netlist information stored in a table. The first line in it contains column names and each line in it is a port name (surrounded by double-quotes), followed by a comma and a <TAB> character, followed by a signal name (also surrounded by double-quotes). \fIfile.cmp\fR contains information about components in the file. Each component begins with its name followed by its type. The attributes of a component are printed afterwards (indented by <TAB> characters). .TP .B -svg Generates an SVG file in \fIfile.svg\fR. Please see the notes for Tgif.EpsToTmpSvg and Tgif.TmpSvgToSvg in the X DEFAULTS section below. .TP .B -stdout Sends the output to the standard output instead of generating the output in a file. .TP .B -raw Causes the content of the files to be dumped to stdout. .TP .B -raw+h If \fB-raw+h\fR is used and if the file is an HTTP URL, the HTTP header is also dumped to stdout. .TP .B -raw+headeronly If \fB-raw+headeronly\fR is used and if the file is an HTTP URL, the HTTP header is dumped to stdout. .TP .B -dosepsfilter Makes tgif act as a filter for getting rid of the DOS EPS Binary File Header and the trailing TIFF image in a DOS/Windows EPS file. .TP .B -previewonly If \fB-dosepsfilter\fR is specified, \fB-previewonly\fR makes tgif act as a filter for extracting the preview bitmap from the trailing TIFF image in a DOS/Windows EPS file. .TP .B -status If this option is used in conjunction with either \fB-raw\fR, \fB-raw+h\fR, or \fB-raw+headeronly\fR causes a status line to be displayed in stderr. .TP .B -gray Using this option has the same effect as setting the Tgif.UseGrayScale X default to true (see the X DEFAULTS section below). .TP .B -color \fR(or\fB -reqcolor\fR)\fB To print in color, one can use either the \fB-color\fR or the \fB-reqcolor\fR option. The only difference between the two is that using \fB-reqcolor\fR has the same effect as setting the Tgif.PrintUsingRequestedColor X default to true (see the X DEFAULTS section below). .TP .B -adobe \fR(or\fB -adobe=<number>/<number> -adobe=false\fR)\fB Using this option has the same effect as specifying the Tgif.UsePsAdobeString X default. .TP .B -dontreencode=<string> Using this option has the same effect as specifying the Tgif.DontReencode X default. .TP .B -producedby=<string> Using this option has the same effect as specifying the Tgif.ProducedBy X default. .TP .B -page Causes a specified page (specified by <number>) to be printed. .TP .B -print_cmd Using this option has the same effect as specifying the Tgif.PrintCommand X default. .TP .B -one_file_per_page Causes each page to be printed into a separate file. .TP .B -pepsc Preserve EPS Comment. This command line option became obsolete since EPS comments are always preserved starting from tgif-4.0.11. .TP .B -nolandpdfspd This commandline option became obsolete in tgif-4.1.42. It is interpreted as -nopdfspd. .TP .B -pdfspd \fR(or\fB -pdfspd=true -pdfspd=false\fR)\fB If -pdfspd or -pdfspd=true is specified, "setpagedevice" is generated in the interim PostScript file when exporting PDF files or in the final PostScript file when exporting PS files. If -pdfspd=false is specified, no "setpagedevice" will be generated in the interim PostScript file when exporting PDF files or in the final PostScript file when exporting PS files. This option overrides the Tgif.PdfSetPageDevice X default. .TP .B -pssetup Using these options have the same effect as specifying the Tgif.AdditionalPSSetup X default. .TP .B -tgwb2 This commandline option enables the Tangram Whiteboard feature in tgif. It requires \fBlibrmcast.so\fR (Reliable IP-multicast library). The location of the rmcast library can be specified by the optional commandline argument \fB-rmcastlibdir\fR. Alternatively, the full path to the rmcast library can be specified by using the optional commandline argument \fB-rmcastlibpath\fR. (Please note that the rmcast library has only been extensively tested on Linux machines.) .TP .B -j2p6_cmd Using this option has the same effect as specifying the Tgif.JpegToPpm6 X default. .TP .B -dontcondense Using this option has the same effect as setting the Tgif.DontCondensePSFile X default to true. .TP .B -condensed Using this option has the same effect as setting the Tgif.DontCondensePSFile X default to false. .TP .B -bop_hook \fRand\fB -eop_hook Using these options have the same effect as specifying the Tgif.PSBopHook and Tgif.PSEpsHook X defaults. .TP .B -tmp_file_mode Using this option have the same effect as specifying the Tgif.TmpFileMode X defaults. .TP .B -patterndir Using this option have the same effect as specifying the Tgif.CustomPatternDir X defaults. .TP .B -o If this option is not specified, the output file (eps, ps, etc.) goes into the same directory as the input file. If \fB-o\fR<dir> is specified, the output file goes into the directory specified by \fB<dir>\fR. .TP .B -merge \fIfile1\fR \fIfile2\fR ... Using this option merges \fIfile1\fR.obj, \fIfile2\fR.obj, etc. into a multipage file. .\" .SH BASIC FUNCTIONALITIES .\" Primitive objects supported by tgif are rectangles, ovals, rounded-corner rectangles, arcs, polylines, polygons, open-splines, closed-splines, text, X11 bitmaps, some specific forms of X11 pixmaps, and Encapsulated PostScript. (Please note that the splines tgif draw are \fInot\fR Bezier curves.) Objects can be grouped together to form a \fIgrouped\fR object. A primitive or a grouped object can be made into an \fIicon\fR object or a \fIsymbol\fR object through user commands. .PP Tgif objects are stored in two types of files. A file with a .I \.obj extension (referred to as an \fIobject\fR file) is a file of objects, and a file with a .I \.sym extension (referred to as a \fIsymbol\fR file) specifies a ``building-block'' object. A \fIteleport\fR mechanism is provided to \fItravel\fR (or \fIhyperjump\fR) among the .obj files. A building-block object consists of the \fIrepresentation\fR part and the \fIdefinition\fR part (which can be empty) of the object. Tgif supports the ``bottom-up'' construction of hierarchical drawings by providing the capability to ``instantiate'' a building-block object in a drawing. Tgif also supports the ``top-down'' specification of drawings by allowing the user to make any object a \fIrepresentation\fR of an un-specified subsystem. Both types of files are stored in the form of Prolog facts. Prolog code can be written to interpret the drawings! (It is left to the user to produce the code. See the PROLOG/C TESTDRIVE section for more details.) Prolog engines are referred to as \fIdrivers\fR in the sections to follow. (Other types of drivers are also allowed, e.g., written in C.) .PP Text based \fIattributes\fR can be attached to any non-text object. Attributes specified in the representation part of a building-block object are non-detachable when such an object is instantiated. See the ATTRIBUTES section for details. .PP Tgif can generate output in a few different formats. By default, the output is in the PostScript format (color PostScript is supported), and it is generated into a file named /tmp/Tgifa* (produced by mktemp() calls) where * is a number; this file is piped to lpr(1). This takes place when the laser-printer icon is displayed in the Choice Window (see the TGIF SUBWINDOWS section for the naming of tgif windows). This output can be redirected to a file with a .I \.ps extension. This takes place when the \fIPS\fR icon is displayed in the Choice Window. When the \fIPDF\fR icon is displayed in the Choice Window, the output is generated into a file with a .I \.pdf extension. By default, tgif calls ps2pdf(1) from the ghostscript(1) package to convert a \fIPS\fR file to a \fIPDF\fR file. When the \fILaTeX\fR (or \fIEPSI\fR) icon is displayed in the Choice Window, the output is generated into a file with a .I \.eps extension. This file is in the Encapsulated PostScript (or Encapsulated PostScript Interchange) format; it can be included in a LaTeX document with the \fI\\psfig\fR or the \fI\\epsf\fR construct; this will be discussed later. The only difference between the EPS and EPSI formats is that an EPSI file contains a preview bitmap. However, it takes time to generate the preview bitmap. If the EPS/EPSI file is to be incorporated into some tool that does not know how to use the preview bitmap, time can be saved by not using the EPSI format. When the \fIT\fR icon is displayed in the Choice Window, the output is generated into a file with a .I \.txt extension. This is a text file containing all visible text; it can be fed to a spell checker. When the \fIx11bm\fR (X11 bitmap) icon is displayed in the Choice Window and color output is \fInot\fR selected, tgif generates the output with the .I \.xbm extension; the output is in the X11 bitmap format. However, if the x11bm icon is displayed in the Choice Window and color output \fIis\fR selected (through the ^#k keyboard command -- ^ denotes the <Control> and # denotes the <Meta> or <Alt> key), then tgif generates the output with the .I \.xpm extension, and the output is in the X11 pixmap format (the version of this XPM format depends on the settings of the Tgif.XPmOutputVersion X default). When the \fIGIF\fR icon is displayed in the Choice Window, the output is generated into a file with a .I \.gif extension. By default, tgif calls xpmtoppm and ppmtogif from the netpbm(1) package to convert an \fIXPM\fR file to a \fIGIF\fR file. .PP X11 bitmap files, certain forms of X11 pixmap files (such as the one generated by tgif; see the section on X11 PIXMAP for details), GIF files, and Encapsulated PostScript (EPS) files can be \fIimported\fR into tgif and be represented as tgif primitive objects. Files in other raster formats (e.g, JPEG, TIFF, etc.) can also be imported into tgif if external tools can be used to convert them into X11 pixmap files. Please see the IMPORT RASTER GRAPHICS section for details. .PP Tgif drawings are supposed to be printed on letter size paper (8.5in by 11in). Both landscape and portrait page styles are supported by tgif. Reduction (or magnification) can be controlled by the #% keyboard command to set the reduction/magnification. If the compiler flag -DA4PAPER is defined (in Imakefile or Makefile.noimake), then the output is supposed to be printed on A4 papers (which has approximate dimensions of 8.25in by 11.7in). .\" .SH GRAPHICAL OBJECTS .\" An object in an \fIobject\fR (\fI.obj\fR) file can be a primitive object, a grouped object, or an \fIicon\fR object. A \fIsymbol\fR (\fI.sym\fR) file can have any number of objects allowed in an object file and exactly one \fIsymbol\fR object. (Recall that a symbol file specifies a building-block object.) The symbol object in a symbol file is the representation part of the building-block object, and the rest of the symbol file is the definition part of the building-block object. The symbol object is highlighted with a dashed outline to distinguish it from the rest of the objects. When a building-block object is instantiated, the symbol part of the file is copied into the graphics editor, and it becomes the icon for the building-block object. .PP All objects in tgif can be moved, duplicated, deleted, rotated, flipped, and sheared. However, in the non-stretchable text mode, text objects can not be stretched. For an text object, if it has not been stretched, rotated, or sheared, flipping it horizontally will cause the text justification to change and flipping it vertically has no effect. .PP Tgif supports 32 fill patterns, 32 pen patterns, 7 default line widths, 4 line styles (plain, head arrow, tail arrow, double arrows) for polylines and open-splines, 9 dash patterns, 3 types of text justifications, 4 text styles (roman, italic, bold, bold-italic), 11 default text sizes (8, 10, 12, 14, 18, and 24 for the 75dpi fonts and 11, 14, 17, 20, 25, and 34 for the 100dpi fonts), 5 default fonts (Times, Courier, Helvetica, New-Century-Schoolbook, Symbol), and 11 default colors (magenta, red, green, blue, yellow, pink, cyan, cadet-blue, white, black, dark-slate-gray). Additional line widths can be added through the use of Tgif.MaxLineWidths, Tgif.LineWidth#, Tgif.ArrowWidth#, and Tgif.ArrowHeight# X defaults. Additional text sizes can be added through the use of Tgif.FontSizes X default. Additional fonts can be added through the use of Tgif.AdditionalFonts X default. If the defaults fonts are not available, their replacement fonts can be specified by Tgif.HasAlternateDefaultFonts and related X defaults. Additional colors can be added through the use of Tgif.MaxColors, and Tgif.Color# X defaults. One can also select AddColor() or ChooseColor() from the Properties Menu to add a color. Alternate startup colors can be selected through the use of the Tgif.ColorFromXPixmap, Tgif.UseStdPalette8, Tgif.UseStdPalette27, Tgif.UseStdPalette64, Tgif.UseStdPalette216, Tgif.UseMobileWebSafePalette, Tgif.UseOpenOfficeGalaxyPalette, Tgif.UseOpenOfficeGooglePalette, and Tgif.AdditionalColors X defaults. .PP Most commands in tgif can either be activated by a popup menu or by typing an appropriate non-alphanumeric key. All operations that change any object can be undone and then redone. Commands such as zoom, scroll, change fonts while no text objects are selected, etc. are not undoable. The undo/redo history buffer size can be set using the Tgif.HistoryDepth X default. .\" .SH TGIF SUBWINDOWS .\" The tgif windows are described in this section. .TP .I Top Window Displays the current domain and the name of the file tgif is looking at. Mouse clicks and key presses have no effect. .TP .I Menubar Window This window is right under the Top Window. Pull-down menus can be activated from it with any mouse buttons. Key presses have no effect. If HideMenubar() is selected from the Layout Menu, this window becomes invisible. If ShowMenubar() is selected from the Layout Menu (which can be activated from the Canvas Window below), this window becomes visible. .PP .RS The View, Text, and Graphics pull-down menus are cascading menus and can not be \fIpinned\fR (see the \fIPopup Menus\fR subsection below for a description). .RE .TP .I Message Window This is right under the Menubar Window and to the right It displays tgif messages. Clicking the left mouse button in this window scrolls the messages towards the bottom, clicking the right mouse button scrolls towards the top, and clicking or dragging the middle mouse button scrolls to the location in the message history depending on where the mouse is clicked. If the <Shift> (or <Control>) key is held down when clicking the left/right mouse button, it scrolls right/left. .TP .I Panel (Choice) Window This is the window to the left of the Message Window, and it contains a collection of icons (not to be confused with the tgif icon objects) reflecting the current state of tgif. In top/bottom, left/right order, it displays the current drawing mode, the page style (portrait or landscape), edit (see below), print/export mode, zoom factor, move and stretch mode (constrained or unconstrained), radius for rounded-corner rectangles, text rotation, page number or row/column, page layout mode (stacked or tiled), horizontal alignment (L C R S -), vertical alignment (T M B S -), font, text size, vertical spacing between lines of text within the same text object, text justification, shape (see below), stretchable or non-stretchable text mode, dash pattern, line style, polyline, spline, or interpolated spline, line width, fill pattern, pen pattern, color, and special (see below). Key presses have no effect in this window. .PP .RS In addition to displaying the current state of tgif, the icons in the Choice Window can also be used to change the current state. Each icon is associated with a particular state variable of tgif. Clicking the left mouse button on top of an icon cycles the state variable associated with the icon forward; clicking the right mouse button cycles the state variable backwards. Dragging the middle mouse button on top of an icon usually generates a popup menu which corresponds to an entry in the Main Menu for the Canvas Window below. (The ``edit'', ``shape'', and ``special'' icons mentioned above are dummy icons that allow the ``edit'', ``shape'', and ``special'' menus to be accessed in the Choice Window. They do not respond to left and right mouse clicks.) The response to the dragging of the middle mouse button is different for the zoom, radius, and vertical spacing icons. Dragging the mouse left or up increases the zoom or decreases the radius or vertical spacing; dragging the mouse right or down has the opposite effect. .RE .PP .RS If there are objects selected in the canvas window, then the action of the mouse will cause the selected objects to change to the newly selected mode; note that in this case, the current choice won't change if the middle mouse button is used (unless the Tgif.StickyMenuSelection X default is set to true). .RE .PP .RS The settings of the horizontal and vertical alignments determine how objects (or vertices) align with each other when the ^l keyboard command is issued, how each individual object (or vertex) aligns with the grids when the ^t keyboard command is issued, how objects or vertices distribute spatially with respect to each other when the #l keyboard command is issued, and how each icon replaces the old icon when the ^#u keyboard command is issued. The horizontal alignments are left (L), center (C), right (R), space (S), and ignore (-). The vertical alignments are top (T), middle (M), bottom (B), space (S), and ignore (-). In aligning operations, the space (S) and the ignore (-) settings have the same effect. The space settings are used to distribute objects such that the gaps between any two neighboring objects are equal. In vertex mode, any non-ignore setting will cause the selected vertices to be spaced out evenly. The best way to understand them is to try them out. .RE .PP .RS The text vertical spacing determines the vertical distance to advance when a carriage return is pressed during text editing. If the user tries to set the value too negative, such that the next line is exactly at the same position as the current line, such a setting will not be allowed (this distance depends on the current font and font size). .RE .TP .I Canvas Window This is the drawing area. The effects of the actions of the mouse are determined by the current drawing mode. Before tgif-4.x, dragging the right mouse button will generate the Mode Menu. This is disabled by default in tgif-4.x, but you can turn it on using the Tgif.Btn3PopupModeMenu X default. .PP .RS The drawing modes are (in order, as they appear in the Mode Menu) select, text, rectangle, corner oval, center oval, edge circle, polyline (open-spline), polygon (closed-spline), arc (center first), arc (endpoints first), rounded-corner rectangle, freehand polyline (open-spline), select vertices, and rotate/shear. When drawing a rectangle, an oval, or a rounded-corner rectangle, if the <Shift> key is held down, a square, a circle, or a rounded-corner square is drawn. Dragging the middle mouse button will generate the Main Menu. .RE .PP .RS In the select mode, left mouse button selects, moves, stretches, and reshapes objects (double-click will ``de-select'' all selected objects in vertex mode). When an object is selected, it is highlighted by little squares (referred as handles here) at the corners/vertices (using the Tgif.HandleSize X default, the sizes of the handles can be customized). Dragging one of the handles stretches/reshapes the selected object. If one wants to move a selected object, one should not drag the handles. Instead, one should drag other parts of the object. For example, if the object is a hollow rectangle (the fill is NONE and the pen is not NONE), in order to select the rectangle, one should click on the outline of the rectangle with the left mouse button. If one would like to move the rectangle, one should drag the outline of the rectangle with the left mouse button. If the object is a filled rectangle (fill is not NONE), one can click inside the rectangle to select it and drag anywhere inside the rectangle to move it. .RE .PP .RS Holding down the <Shift> key and clicking the left mouse on an object which is not currently selected will add the object to the list of already selected objects. The same action applied to an object which is already selected will cause it to be de-selected. When stretching objects (not reshaping poly-type objects), holding down the <Shift> key \fIafter\fR stretching is initiated activates proportional stretching (basically, a scale operation is being performed). In non-stretchable text mode, text objects can not be stretched or scaled. .RE .PP .RS Double-clicking or clicking the middle mouse button while the <Shift> key is held down will activate the \fIteleport\fR (or \fItravel\fR), the \fIlaunch\fR, or the \fIexecute internal command\fR mechanism. See the sections on TELEPORT/HYPERJUMP, LAUNCH APPLICATIONS, and INTERNAL COMMANDS for details. Teleporting has precedence over launching, which has precedence over executing an internal command. In the text drawing mode, dragging the middle mouse button while the <Cntrl> key is held down inside the edit text area will move the edit text area. .RE .PP .RS The arrow keys can also be used to move selected objects. However, if no objects are selected, using the arrow keys will scroll the drawing area by a small amount, and using the arrow keys when <Control> key is held down will scroll a screen full. .RE .PP .RS In the select vertices mode, left mouse button selects and moves vertices. Only the top-level polyline/open-spline and polygon/closed-spline objects which are selected when the vertex mode is activated are eligible for vertex operations. In this mode, all eligible objects have their vertices highlighted with squares. When a vertex is selected (using similar mechanism as selecting objects described above), it is doubly highlighted with a '+' sign. Operations available to these doubly highlighted vertices are move, delete, align (with each other), distribute (space them equally), and align to grid. The arrow keys can also be used to move selected vertices. .RE .PP .RS Objects can be locked (through the #< keyboard command). Locked object are shown with gray handles, and they can not be moved, stretched, flipped, rotated, or sheared. When objects are grouped, the resulting grouped object will also be locked if any one of it's constituents is locked. Locked objects can have their properties, such as color, font, pen, etc., changed; furthermore, they can be deleted. .RE .PP .RS If the current move/stretch mode is of the constrained type (activated and deactivated by the #@ keyboard command), top-level polylines will have the following behavior. In a move operation, if both endpoints of a polyline lie inside the objects being moved, then the whole polyline is moved; otherwise, if only one endpoint falls inside the objects being moved, then that endpoint is moved. The vertex that is the neighbor of the moved endpoint may also be moved either horizontally or vertically. If the last line segment is horizontal or vertical, then the neighbor vertex may be moved so that the direction of the last line segment is maintained. In a stretch (not reshape) operation, if an endpoint of a polyline lies inside the objects being moved, that endpoint will be moved. The vertex that is the neighbor of the moved endpoint will also be moved in the same manner as described above. .RE .PP .RS When the drawing mode is set to text (a vertical-bar cursor is shown), clicking the left mouse button causes selected text to go into edit mode. Dragging the left mouse button or clicking the left mouse button while the <Shift> key is held down highlights substrings of the text. Double-clicking causes a word to be selected. In edit mode, key presses are treated as text strings being inputed, and arrow keys are used to move the current input position. If a key press is preceded by an <ESC> key, then the character's bit 7 is turned on. This allows non-ASCII (international) characters to be entered. One can use xfd(1) to see what the corresponding international character is for an ASCII character. For the Symbol font, symbols such as the integral, partial derivative, and copyright symbols can all be found in this range. There are some characters that are supported by X11 but not by PostScript; these characters are not accepted by tgif. If the text being edited is an attribute of a object, <Meta><Tab> will move the cursor to the next visible attribute and <Shift><Tab> will move the cursor to the previous visible attribute. .RE .PP .RS If the drawing mode is set to draw polygons (not closed-splines) and if the <Shift> key is held down, the rubber-banded polygon will be self-closing. .RE .PP .RS The freehand drawing mode can be used to draw polylines and open splines. All intermediate points are specified by moving the mouse (as opposed to clicking the mouse buttons as in the polyline mode). The second endpoint is specified by releasing the mouse button. .RE .PP .RS In all drawing modes (other than the text mode), pressing the <ESC> key cancels the drawing (creation) of the current object. .RE .PP .RS Middle mouse button always generates the main tgif popup menu. Holding down the <Shift> key and clicking the right mouse button will change the drawing mode to \fIselect\fR. Key presses with the <Control> or <Meta> key held down (referred to as \fInon-alphanumeric\fR key presses since they can also generate control characters) are treated as commands, and their bindings are summarized in the next section. Users can also define single key commands to emulate the functions of the non-alphanumeric key commands. The SHORTCUTS section will describe the details. .RE .TP .I Scrollbars Clicking the left mouse button in the vertical/horizontal scrollbar causes the canvas window to scroll down/right by a small distance; clicking the right mouse button has the reverse effect. (The scrollbars in the popup windows for selecting file names and domain names behave similarly.) Clicking with the <Shift> key held down will scroll a window full. Clicking or dragging the middle button will cause the page to scroll to the location which corresponds to the gray area in the scrollbars. (Tgif insists that the left-top corner of the Canvas Window is at a distance that is a nonnegative multiple of some internal units from the left-top corner of the actual page.) .TP .I Rulers .br They track the mouse location. Mouse clicks and key presses have no effect. When the page reduction/magnification is set at 100%, the markings in the rulers correspond to centimeters when the metric grid system is used, and they correspond to inches when the English grid system is used. When the page reduction/magnification is not set at 100%, the markings do not correspond to the above mentioned units any more (this is considered as a known bug). .TP .I Interrupt/Hyperspace Window .br This window is right below the Message Window and to the left of the horizontal ruler. When the Tgif.IntrCheckInterval X default has a positive value, an interrupt icon is visible when the Canvas Window is being redrawn. If the user clicks on this window when the interrupt icon is visible, tgif aborts the repainting of the objects. If this is done when a file is being opened (either through Open() or Push()), the drawing of objects is stopped, but the reading of the file continues (reading of the file is not aborted). .PP .RS If tgif is currently in the \fIhyperspace\fR mode (please see the HYPERSPACE section below for more details), a space ship icon will be displayed when the interrupt icon is not being displayed. Clicking any button in this window will switch tgif in and out of the hyperspace mode. .RE .TP .I Page Control Window .br The Page Control Window is to the left of the horizontal scrollbar. This window is empty if the current page mode is set to the \fItiled\fR page mode. If the current page mode is set to the \fIstacked\fR page mode, each page has a tab in tabs subwindow of this window. Clicking the left mouse button on a tab goes to the corresponding page. Clicking the middle mouse button brings up the Page Menu. When there are too many pages in a drawing so that one can not see the tabs for all the pages, one can use the icons to the left side of the Page Control Window to scroll the tabs subwindow. Clicking on the first icon scrolls the tabs subwindow such that the first tab is visible. Clicking on the 4th icon scrolls the tabs subwindow such that the last tab is visible. Clicking on the 2nd icon scrolls the tabs subwindow towards the first tab by one tab and clicking on the 3rd icon scrolls the tabs subwindow towards the last tab by one tab. .TP .I Status Window This window is below the horizontal scrollbar. It shows what action will be taken if a mouse button is depressed. When a menu is pulled down or popped up, this window shows what action will be taken if a menu item is selected. It also displays miscellaneous status information. Mouse clicks and key presses have no effect. If HideStatus() is selected from the Layout Menu, this window becomes invisible. If ShowStatus() is selected from the Layout Menu, this window becomes visible. .PP .RS By default, when this window is displaying mouse button status, right-handed mouse is assumed. Setting the Tgif.ReverseMouseStatusButtons X default to true will reverse the status (as if a left-handed mouse is used). .RE .TP .I Popup Menus .br When a menu is popped up by a mouse drag, the menu can be \fIpinned\fR if it is dragged far enough horizontally (the distance is determined by the setting of the Tgif.MainMenuPinDistance X default). Clicking the right mouse button in a pinned menu will cause it to disappear. Dragging the left mouse button in a pinned menu will reposition the menu (except when the Tgif.TitledPinnedMenu X default is set to true in which case the left mouse button performs the same function as the middle mouse button). Clicking the middle mouse button in it will activate the item right below the mouse. .\" .SH NON-ALPHANUMERIC KEY BINDINGS .\" Most operations that can be performed in tgif can be activated through non-alphanumeric keys (some operations can only be activated through popup menus or shortcut keys). This section summarizes the operations that can be activated by a key stroke with the <Control> and/or the <Meta> key held down. ``^'' denotes the <Control> key and ``#'' denotes the <Meta> key in the following description. (The ``\fIkeys.obj\fR'' file, distributed with tgif, also summarizes the same information, but it is organized differently. This file can be viewed with tgif, and if installed properly, it can be found in the same directory as the ``tgificon.obj'' file, mentioned in the FILES section of this document.) .PP ^a select all ^b send selected objects to the back ^c copy selected objects into the cut buffer ^d duplicate selected objects ^e save/restore drawing mode ^f send selected objects to the front ^g group selected objects (the grouped object will be brought to the front) ^i instantiate a building-block object ^k pop back to (or return to) a higher level and close the symbol file (reverse of ^v) ^l align selected objects according to the current alignment settings ^n open a new un-named object file ^o open an object file to edit ^p print the current page (or export in XBM, XPM, GIF, HTML, PDF, EPS, or PS formats) ^q quit tgif ^r redraw the page ^s save the current object/symbol file ^t align selected objects to the grid according to the current alignment ^u ungroup selected objects ^v paste from the cut buffer ^w change the drawing mode to text ^x delete all selected objects ^y change domain ^z escape to driver ^, scroll left ^. scroll right ^- print the current page with a specified command #a attach selected text objects to a selected non-text object as attributes #b escape to driver #c rotate selected objects counter-clockwise #d decrement the grid size #e send a token on a selected polyline #f flash a selected polyline #g show/un-show grid points #h flip the selected objects horizontally #i increment the grid size #j hide the attribute names of the selected objects #k change the drawing mode to select #l distribute selected objects according to the current alignment #m move/justify an attribute of a selected object #n show all the attribute names of the selected objects #o zoom out #p import a .obj or a .sym file into the current file #q change the drawing mode to polyline/open-spline #r change the drawing mode to rectangle #s escape to driver #t detach all the attributes of the selected objects #u undo #v flip the selected objects vertically #w rotate the selected objects clockwise #x escape to driver #y escape to driver #z zoom in #9 create a user-specified arc (12 o'clock position is 0 degree) #0 update the selected objects according to current settings #, scroll up #. scroll down #- show all the attributes of the selected objects #[ align the left sides of objects #= align the horizontal centers of objects #] align the right sides of objects #{ align the top sides of objects #+ align the vertical centers of objects #} align the bottom sides of objects #" make the selected polygon regular (fit the original bounding box) #% set the percent print reduction (if < 100%) or magnification (if > 100%) #: go to default zoom #` zoom out all the way so that the whole page is visible #~ save selected objects in a new file #; cut and/or magnify a selected bitmap/pixmap object #_ abut selected objects horizontally #| abut selected objects vertically ## break up text objects into single character text objects #^ scroll to the origin set by SaveOrigin() #@ toggle between constrained and unconstrained move (stretch) modes #$ change the drawing mode to select vertices #& align selected objects to the paper according to the current alignment #* redo #( import an Encapsulated PostScript file #) scale selected objects by specifying X and Y scaling factors #< lock the selected objects (can't be moved, stretched, flipped, or rotated) #> unlock the selected objects ^#a add points to the selected poly or spline ^#b change the text style to bold ^#c change to center justified text ^#d delete points from the selected poly or spline ^#e change the drawing mode to rounded-corner rectangles ^#f reverse-video the selected bitmap objects ^#g toggle snapping to the grid points ^#h hide all attributes of the selected objects ^#i make the selected object iconic ^#j make the selected icon object a grouped object ^#k select color or black-and-white output ^#l change to left justified text ^#m make the selected object symbolic ^#n make the selected symbol object a grouped object ^#o change the text style to roman ^#p change the text style to bold-italic ^#q change the drawing mode to polygon/closed-spline ^#r change to right justified text ^#s save the file under a new name ^#t change the text style to italic ^#u update iconic representations of selected objects ^#v change the drawing mode to oval ^#w toggle between poly and spline ^#x cycle among the various output file formats ^#y push into (or edit) the definition part of a building-block (icon) object ^#z change the drawing mode to arcs ^#. import an X11 bitmap file ^#, import an X11 pixmap file ^#- toggle between English and Metric grid systems ^#= repeat the last Find command .br .\" .SH SHORTCUTS .\" The user can define single character \fIshortcut\fR keys to emulate the function of the non-alphanumeric key presses to activate commands. This is done through the use of the Tgif.ShortCuts X default. (Please note that these shortcut keys are only active when the drawing mode is \fInot\fR set to the text mode.) The Tgif.ShortCuts consists of a list of items, each of which specifies the bindings between a key (may be case sensitive) and a command. The items are separated by blanks, and each item is interpreted as follows. It consists of two parts, KEY and COMMAND, which are concatenated together with a ':' character. The format of the KEY part is one of \fI:<Key>x\fR, \fI!<Key>x\fR, or \fI<Key>x\fR (here the character 'x' is used as an example; furthermore, the substring \fI<Key>\fR must be spelled exactly the way it appears here). The first 2 formats are equivalent, they specify the \fIlower case\fR x; the 3rd format specifies both the characters 'x' and 'X'. The COMMAND part is a string that matches strings in tgif's popup menus with space characters removed (exceptions are noted below). This is illustrated by the following example. In the Edit menu, two of the entries are, .PP "Delete ^x" .br "SelectAll ^a" .PP which means that <Control>x activates and Delete() command, and <Control>a activates the SelectAll() command. Therefore, both Delete() and SelectAll() are valid names for the COMMAND part of a shortcut specification. To complete the example, the following line can be used to bind the lower case 'x' to Delete() and 'a' or 'A' to SelectAll(): .PP Tgif.ShortCuts: !<Key>x:Delete() \\n\\ .br <Key>a:SelectAll() .PP For more examples, please see the sample X defaults file, tgif.Xdefaults, included in the tgif distribution. .PP Here is a list of exceptions where the COMMAND does not match a command name in a menu entry. The left entry is a proper COMMAND name, and the right is a list of strings that's shown in popup menus which the COMMAND would correspond to. .PP CyclePrintFormat() Printer, LaTeXFig, RawPSFile, XBitmap, TextFile, EPSI, GIF/ISMAP, TiffEPSI, NetList ToggleBW/ColorPS() BlkWhtPS, ColorPS ToggleGridSystem() EnglishGrid, MetricGrid ToggleMapShown() ShowBit/Pixmap, HideBit/Pixmap ToggleUseGrayScale() UseGrayScale, NoGrayScale ToggleMoveMode() ConstMove, UnConstMove ToggleShowMeasurement() ShowMeasurement, HideMeasurement ToggleLineType() (advances between different curved shapes) ScrollPageUp() (scroll up a window full) ScrollPageDown() (scroll down a window full) ScrollPageLeft() (scroll left a window full) ScrollPageRight() (scroll right a window full) FreeHandMode() (change the drawing mode to freehand poly/open-spline) CenterAnEndPoint() (move an endpoint of a polyline object to the center of another object) ToggleNamedAttrShown(<x>=) (toggle name shown for the attribute <x>) ToggleSmoothHinge() (convert smooth to hinge and hinge to smooth points) ToggleShowMenubar() ShowMenubar, HideMenubar ToggleShowStatus() ShowStatus, HideStatus ToggleShowMode() ShowMode, HideMode ToggleOneMotionSelMove() OneMotionSelMove, ClickSelClickMove ToggleHyperSpace() GoHyperSpace, LeaveHyperSpace ImportOtherFileType(<x>) (import using a filter named <x>) BrowseOtherType(<x>) (browse using a filter named <x>) PrintSelectedObjs() (print selected objects) .br .PP In addition to the above list, the following are also valid COMMAND names (having the obvious meaning): ScrollLeft(), ScrollRight(), ScrollUp(), ScrollDown(), SelectMode(), DrawText(), DrawBox(), DrawOval(), DrawPoly(), DrawPolygon(), DrawRCBox(), DrawArc(), and SelectVertexMode(). .\" .SH COLORS AND COLORMAPS .\" In most X environments, only 256 colors can be displayed at once. In these environment, if an application needs 128 colors and another application needs a totally different 129 colors, both applications can not be displayed at once with all the colors they want. X solves the problem by allowing applications to use their own colormaps (known as private colormaps). Each private colormap can have at most 256 colors. There is also a shared colormap available for applications that do not wish to use private colormaps. The main problem with using private colormaps is that a user will see the the well-known \fIcolormap flashing\fR phenomenon when he/she switches in and out of applications that use private colormaps. .PP Tgif uses the shared colormap initially. When it needs more color than what is available in the shared colormap, it will use a private colormap automatically. When tgif no longer needs the extra colors, it does \fInot\fR automatically revert to using the shared colormap because it needs to be able to undo operations that use the extra colors. If one does no longer needs the objects in the undo buffer, one can select FlushUndoBuffer() from the Edit Menu to flush the undo buffer. At this point, tgif will attempt to use the shared colormap to avoid the colormap flashing problem. If one often uses XPM and GIF objects, one can bind the <Shift>f key to the FlushUndoBuffer() operation by setting the following X default and uses the <Shift>f key to regain entries in the colormap when an XPM/GIF object is deleted: .PP .RS Tgif.ShortCuts: !<Key>F:FlushUndoBuffer() .br .RE .br .PP Even when a private colormap is used, only 256 colors can be used at once. Therefore, it is not possible to import two 256-colors GIF files into the same drawing unless the colors are somehow reduced to fit in the 256-colors colormap. This can be done through \fIdithering\fR which is described in the IMPORT RASTER GRAPHICS section below. .\" .SH IMPORT RASTER GRAPHICS .\" The native raster graphics formats that tgif supports are the XBM and XPM formats. In order to import color raster graphics file of another format, tgif can work with external tools that can convert non-XPM format files to an XPM files. A popular raster format conversion toolkit is the \fIpbmplus\fR(1) (also known as the \fInetpbm\fR(1)) toolkit. It can convert a GIF file (e.g., "foo.gif") to an XPM file (e.g., "foo.xpm") with the following command (\fIgiftopnm\fR is in netpbm; an earlier version of it called \fIgiftoppm\fR exists in pbmplus): .PP .RS giftopnm foo.gif | ppmtoxpm > foo.xpm .br .RE .br .PP When working with tgif, a GIF file name will be supplied by tgif and the output of ppmtoxpm will be directly read by tgif through a pipe; therefore, the previous sequence is replaced by an X default containing the following form (which happens to be the default setting for the Tgif.GifToXpm X default): .PP .RS giftopnm %s | ppmtoxpm .br .RE .br .PP The "%s" is to be replaced by a GIF file name. The above is referred to as a \fIfilter\fR. .PP To be able to import other types of raster graphics files, one can use Tgif.MaxImportFilters and Tgif.ImportFilter# X defaults to specify additional filters. The following example adds a JPEG filter: .PP .RS Tgif.MaxImportFilters: 1 .br Tgif.ImportFilter0: \\n\\ .br JPEG-222 jpg;jpeg \\n\\ .br djpeg -gif -colors 222 %s | \\n\\ .br giftopnm | ppmtoxpm .br .RE .br .PP The "JPEG-222" above is the name given to the filter (must not contain any space character). The "jpg;jpeg" are possible file extensions separated by semicolons. The rest is the filter specification. The djpeg(1) program is part of the libjpeg distribution. It can convert a JPEG file to a GIF file. The above filter also restrict the output to have a maximum of 222 colors. (The 222 is chosen arbitrarily. Many XPM files use some ``standard'' 32 colors, so one may want to leave room form them.) .PP To invoke a filter, one can select ImportOtherFile() or BrowseOther() commands from the File Menu. This will bring up a dialogbox listing the available filters by their names (e.g., "JPEG-222"). After selecting a filter, tgif continues in a similar manner as with invoking ImportXPixmap() or BrowseXPixmap() commands from the File Menu. .PP The above example is not suitable for the BrowseOther() command because only 256 colors can be used in a drawing (as explained in the COLORS AND COLORMAPS section above). In order for BrowseOther() to work well, one can use \fIdithering\fR to represent an image with a \fIdithered\fR image that only uses a set of standard colors. The example below uses ppmdither from the pbmplus/netpbm toolkit: .PP .RS Tgif.MaxImportFilters: 2 .br Tgif.ImportFilter0: \\n\\ .br JPEG-222 jpg;jpeg \\n\\ .br djpeg -gif -colors 222 %s | \\n\\ .br giftopnm | ppmtoxpm .br Tgif.ImportFilter1: \\n\\ .br JPEG-dithered jpg;jpeg \\n\\ .br djpeg -gif %s | \\n\\ .br giftopnm | ppmdither | ppmtoxpm .br .RE .br .PP If one is working with one JPEG image, one can select ImportOtherFile() then select "JPEG-222" to get as many as 222 colors. If one is browsing for JPEG images, one can select BrowseOther() then select "JPEG-dithered". .\" .SH OBJECT NAMES .\" If an object contains an attribute (please see the ATTRIBUTES sections below for details) whose name is the string \fI"name"\fR (case-sensitive), the value part of the attribute is the \fIname\fR of the object. Subobject of a composite object can be named using a \fIpath\fR, e.g., \fI<t>!<s1>!<s2>!...\fR, where \fI<t>\fR is the name of a top-level object which directly contains \fI<s1>\fR which directly contains \fI<s2>\fR, etc. \fI!*\fR refers to the currently selected object (if more than one object is selected, the top-most object in the stacking order is used). \fI!*<s1>!<s2>\fR names the \fI<s2>\fR subobject of the \fI<s1>\fR subobject of the currently selected object. .PP The following is \fInot fully\fR supported, yet (only the \fI#<page>\fR form is supported at this time). Every object in a tgif file can be uniquely named using the notation \fI#<page>!<path>\fR, where \fI<page>\fR can be a string that specifies the name of a page or \fI#<number>\fR which specifies a page number. The \fI<path>\fR is described in the previous paragraph. If an object \fIo1\fR is referenced by another object \fIo2\fR within the same file (no file name or URL is specified before \fI#\fR) and \fI<page>\fR is omitted, then \fIo1\fR must be on the same page as \fIo2\fR. If a file name or URL is specified before \fI#\fR and \fI<page>\fR is omitted, then \fIo1\fR must be on the first page. .\" .SH ATTRIBUTES .\" Attributes are text strings of the form \fIname=value\fR or \fIvalue\fR which are attached to either the current drawing or any non-text objects. An attribute attached to the current drawing is called a \fIfile attribute\fR; otherwise, it is a \fIregular attribute\fR. Attributes can be attached and detached from these objects except in the following case: .IP Attributes appearing in the symbol object in a building-block object file can not be detached when the building-block object is instantiated. These attributes are considered to be the ``inherited'' attributes of the icon object. (If it is really necessary to detach inherited attributes of an icon object, the icon object can be ``de-iconified'' by using UnMakeIconic() in the Special Menu to make it a grouped object; then the attributes can be detached.) .PP A file attribute is always invisible. For a regular attribute, the user has control over which part of the attribute is displayed. An entire attribute can be made invisible, or only its name can be made invisible (accomplished through the commands under the special menu, such as #m, #n, #j, #-, and ^#h). .\" .SH TELEPORT/HYPERJUMP .\" Tgif provides the mechanism to travel between .obj and .sym files. If the middle mouse button is clicked on an object with the <Shift> key held down (or double-clicking such an object), tgif looks for an attribute named \fIwarp_to\fR (by default) or \fIhref\fR of that object. The only difference between \fIwarp_to\fR and \fIhref\fR is that ".obj" is automatically appended to the value of a \fIwarp_to\fR attribute while the value of a \fIhref\fR attribute is taken as is. (Please note that \fIwarp_to\fR is obsolete now. It is still supported for the sake of compatibility.) If such an attribute is found, the value part of the attribute is interpreted as the name of a .obj file to \fItravel\fR to. (If tgif is in the \fIhyperspace\fR mode, then clicking the left mouse button has the same effect.) If there are multiple \fIhref\fR attributes on the object, but are in different colors, tgif will use the one that has the same color as the current color appearing in the Choice Window. If the current file is modified, the user is prompted to save the file before traveling to the next file. If the value part of the \fIhref\fR attribute starts with the '/' character, the value is treated as an absolute file name; otherwise, it is treated as a relative file name. .\" .SH HYPERSPACE .\" Tgif provides a \fIhyperspace\fR mode to facilitate traveling between .obj files. The hyperspace mode is entered when GoHyperSpace() is selected from the Navigate Menu. In hyperspace mode, the little window below the Message Window will show a little space ship. The hyperspace mode is also automatically entered when a remote URL is opened (unless the Tgif.AutoHyperSpaceOnRemote X default is set to false). .PP In the hyperspace mode, certain objects are considered \fIhot-links\fR. When the cursor is placed on top of these object, it will change from a pointer to a hand to indicate that clicking on the left mouse button will invoke some actions. An object is a hot-link if it contains an attribute described in either the TELEPORT/HYPERJUMP, LAUNCH APPLICATIONS, or INTERNAL COMMANDS section. .PP The hyperspace mode is exited when the drawing mode is changed or the LeaveHyperSpace() is selected from the Navigate Menu. .\" .SH LAUNCH APPLICATIONS .\" Tgif provides the mechanism to launch applications. If the middle mouse button is clicked on an object with the <Shift> key held down (or double-clicking such an object), tgif looks for an attribute named \fIlaunch\fR (by default) of that object. If such an attribute is found, the value part of the attribute is interpreted as a sh(1) command to execute. Same color rule applies as described in the TELEPORT/HYPERJUMP section above. If the command ends with the '&' character, tgif forks itself (what actual happens depends on whether the _BACKGROUND_DONT_FORK compiler flag is defined or not at compile time) and the command is executed by the child process; otherwise, popen() is used to execute the command (in this case, if the command hangs, there is no way provided to terminate the command, and tgif will not be able to recover from it). Within the command, values of other attributes of the same object can be used. The syntax is: \fI$(attr)\fR, where \fIattr\fR is the name of another attribute. For example, if one wants to perform a man(1) function, one can draw a box; enter a line of text "title=tgif"; enter another line of text "launch=xterm -rw -e man $(title)"; select all three objects using ^a keyboard command; attach the text strings to the box using #a keyboard command; and launch the man(1) command by clicking the middle mouse button on the box (or the text strings) with the <Shift> key held down. If one wants to be more fancy, the box can be replaced by an X11 pixmap object; the 'launch' attribute can be made invisible; and the 'title' attribute can be center justified and with its name hidden using the #m keyboard command. By default, launching of an application is disabled in the \fIhyperspace\fR mode for security considerations (this can be overridden by the Tgif.AllowLaunchInHyperSpace X default setting). If a lunch command is encountered in the \fIhyperspace\fR mode, the command is displayed and the user is prompted to see if he/she wants to execute the command. .\" .SH INTERNAL COMMANDS .\" Tgif provides the mechanism to execute internal commands. If the middle mouse button is clicked on an object with the <Shift> key held down (or double-clicking such an object), tgif looks for an attribute named \fIexec\fR (by default) of that object. If such an attribute is found, the value part of the attribute is interpreted as a list of internal commands (separated by semicolon) to execute. Same color rule applies as described in the TELEPORT/HYPERJUMP section above. A command usually takes the form: .PP .RS <cmd_name> ( <arg1>, <arg2>, ..., <argN> ) .br .RE .br .PP An argument of a command can be a string argument or a numeric argument. A string argument must be enclosed in double-quotes. A numeric argument can be a numerical value or a string of the form "$(\fIx\fR)", where \fIx\fR is the name of another attribute (this form is referred as the substitution form). A string argument can also contain substitution form. Please note that only one-level substitution are performed (the collection of internal commands should be viewed as a simple scripting language and \fInot\fR a declaration language). When an attribute is referenced in an internal command, the attribute name can be in the form, \fI<obj_name>.<string>\fR, where \fI<obj_name>\fR must be in the form specified in the OBJECT NAMES section above and \fI<string>\fR contains only alphanumeric characters and the underscore ('_') character. If the first 2 characters of an attribute name is "!.", the rest of the attribute name names a file attribute. If the first 2 characters of an attribute name is "!*", the rest of the attribute name names an attribute of the currently selected object (if more than one object is selected, the top-most object in the stacking order is used). Please note that lines that begin with "//" are treated as comments. The following internal commands are supported: .TP .I launch(<attr_name>) The value of the attribute specified by <attr_name> is interpreted as a sh(1) command to execute. Please see the LAUNCH APPLICATIONS section above for more details. .TP .I exec(<attr_name>) The value of the attribute specified by <attr_name> is interpreted as an internal command to execute. This is similar to a subroutine call. Please note that the internal command is executed in the context of the top-level which contain the attribute. .TP .I mktemp(<str>,<attr_name>) This command makes a unique file name. The <str> argument is a template string, e.g., "/tmp/TgifXXXXXX", and it requires at least two "/" in it. The result of mktemp() is stored as the value of the attribute specified by <attr_name>. Please see the man pages of the C library function on mktemp(3C) for more details. (If tgif is compiled with the -D_USE_TMPFILE compiler option, then tempnam(3S) is used instead.) .TP .I create_file_using_simple_template(<template>,<output>,<str>,<attr_name>) The file specified by <template> is scanned for a line that matches <str>. When such a line is found, that line is replaced by the value of the attribute specified by <attr_name>. The result is put into the file specified as <output>. .TP .I update_eps_child(<eps_file_name>) This only works if the object being executed is a composite object. If the object has a component which is an imported EPS (Encapsulated PostScript) object, it is replaced by the EPS file specified by <eps_file_name>. If the object does not contain an EPS subobject, an EPS subobject is created. .TP .I update_xbm_child(<xbm_file_name>) This only works if the object being executed is a composite object. If the object has a component which is an imported XBM (X11 bitmap) object, it is replaced by the XBM file specified by <xbm_file_name>. If the object does not contain an XBM subobject, an XBM subobject is created. .TP .I update_xpm_child(<xpm_file_name>) This only works if the object being executed is a composite object. If the object has a component which is an imported XPM (X11 pixmap) object, it is replaced by the XPM file specified by <xpm_file_name>. If the object does not contain an XPM subobject, an XPM subobject is created. .TP .I delete_eps_child(<obj_name>) This only works if the object named <obj_name> is a composite object. If the object has a component which is an EPS (Encapsulated PostScript) object, it is deleted. If the object does not contain an EPS subobject, no operation is performed. .TP .I delete_xpm_child(<obj_name>) This only works if the object named <obj_name> is a composite object. If the object has a component which is an XPM (X11 pixmap) object, it is deleted. If the object does not contain an XPM subobject, no operation is performed. .TP .I delete_xbm_child(<obj_name>) This only works if the object named <obj_name> is a composite object. If the object has a component which is an XBM (X11 bitmap) object, it is deleted. If the object does not contain an XBM subobject, no operation is performed. .TP .I flip_deck(<times>,<frames_per_second>,<style>) This only works if the object being executed is a composite object and all subobjects of the composite object are X11 bitmap or X11 pixmap objects and have identical positions and sizes. The <times> argument specifies the number of times the deck is flipped. It can be a number or the string "infinite". The <frames_per_second> argument must be a number between 1 and 60. The <style> argument can be either "linear" or "ping_pong". When this command is being executed, any mouse button click or key click aborts command execution. .TP .I read_file_into_attr(<file_name>,<attr_name>) This command reads a file into an attribute. The <file_name> argument names a file, e.g., "/tmp/foo". The content of the file is read as the value of the attribute specified by <attr_name>. If the file can not be opened for read, the attribute's value is set to an empty string. .TP .I write_attr_into_file(<attr_name>,<file_name>) This command writes the value of an attribute into a file. The <file_name> argument names a file, e.g., "/tmp/foo". The value of the attribute specified by <attr_name> is written into <file_name>. .TP .I append_attr_into_file(<attr_name>,<file_name>) This command appends the value of an attribute into a file. The <file_name> argument names a file, e.g., "/tmp/foo". The value of the attribute specified by <attr_name> is appended into <file_name>. .TP .I select_obj_by_name(<obj_name>) This command silently (no highlighting handles) selects an object named <obj_name>. Please see the OBJECT NAMES section above for the specification of object names. .TP .I select_top_obj() This command silently (no highlighting handles) selects the top object. This command fails if there is no object in the current page. .TP .I delete_selected_obj() This command deletes all selected objects. This command fails if no object is selected. .TP .I unselect_all_obj() This command de-selects all selected objects. If the select_obj_by_name() command is used, this command must be used eventually. .TP .I move_selected_obj_relative(<dx>,<dy>) This command moves the selected object by <dx> absolute units in the x direction and <dy> absolute units in the y direction. .TP .I repeat(<cmd_attr_name>,<times>) This command executes the internal command in the <cmd_attr_name> attribute <times> times. .TP .I hyperjump(<attr_name>) This command teleports to the file name or URL name found in the <attr_name> attribute. .TP .I make_cgi_query(<dest_attr_name>,<url_name>,<list_attr_name>) This command constructs an URL in the Common Gateway Interface (CGI) format in the <dest_attr_name> attribute. <url_name> names the CGI server script and <list_attr_name> names an attribute whose value are comma-separated attribute names. For example, if an object has the following attributes: .PP .RS .RS attr_list=last_name,first_name .br last_name=Cheng .br first_name=Bill .br final_url= .br exec=make_cgi_query(final_url, .br http://bourbon.usc.edu:8001/cgi-bin/test-cgi, .br attr_list) .RE .PP Executing this object will construct the following string in final_url: .PP .RS http://bourbon.usc.edu:8001/cgi-bin/test-cgi?last_name=Cheng&first_name=Bill .RE .PP An subsequent hyperjump(final_url) command can be invoked to execute the corresponding "test-cgi" CGI server script with the last_name and first_name arguments. .PP For a detailed description of CGI scripts, the reader is referred to [2]. .RE .TP .I wait_click(<cursor_name>,<grab>,<attr_name>) This command displays the <cursor_name> cursor and waits for the user to click a mouse button. If <cursor_name> is the string \fINULL\fR (case-sensitive), the cursor will not change. If <Btn1> is clicked, the command terminates and 1 is placed in <attr_name>. If <Btn2> is clicked, 2 is placed in <attr_name>, etc. If <grab> set to \fITRUE\fR (case-sensitive), then the mouse is grabbed by tgif. Valid <cursor_name> can be found in <X11/cursorfont.h> (without the XC_ prefix). .TP .I sleep(<cursor_name>,<ms_interval>) This command displays the <cursor_name> cursor and waits for <ms_interval> milliseconds to elapse. If <cursor_name> is the string \fINULL\fR (case-sensitive), the cursor will not change. This command can be interrupted (and aborted) by any mouse clicks or key strokes. Valid <cursor_name> can be found in <X11/cursorfont.h> (without the XC_ prefix). .TP .I begin_animate() This command is used to start an animation sequence (using double-buffering). Please note that, by default, tgif prepares for undo/redo. For a long animation sequence, the undo/redo records may take up a lot of memory. In this case, disable_undo() (described below) should be used before this command. .TP .I end_animate() This command is used to terminate an animation sequence. .TP .I set_redraw(<true_or_false>) This command is used to temporarily disable redraw if <true_or_false> is \fIFALSE\fR (case-sensitive) when tgif is in the \fIanimation\fR mode (turned on by begin_animate()). If a shuffle_obj_to_top() or a shuffle_obj_to_bottom() command is used before a move command, set_redraw(FALSE) and set_redraw(TRUE) should be used immediately before and immediately after, respectively, the shuffle_obj_to_top() or shuffle_obj_to_bottom() command. .TP .I set_selected_obj_color(<color_str>) This command changes the color of the selected object to <color_str>. If no object is selected, the current color will be changed to <color_str>. .TP .I set_selected_obj_fill(<fill_index>) This command changes the fill pattern of the selected object to <fill_index>, which must be between 0 (for no fill) and 31. If no object is selected, the current fill pattern will be changed to <fill_index>. .TP .I set_selected_obj_pen(<pen_index>) This command changes the pen of the selected object to <pen_index>, which must be between 0 (for no pen) and 31. If no object is selected, the current pen will be changed to <pen_index>. .TP .I set_selected_obj_line_width(<width>,<arrow_w>,<arrow_h>) This command changes the line width, arrow width, and arrow height of the selected object to <width>, <arrow_w>, and <arrow_h>, respectively. If <arrow_w> or <arrow_h> is -1, the arrow width or arrow height, respectively, is not changed. If no object is selected, the current line width will be changed to the one that matches <width>, <arrow_w>, and <arrow_h> most closely. (Closeness is measured such that the difference in width is counted 10 times the difference in arrow width and arrow height.) .TP .I set_selected_obj_spline(<spline_type>) This command changes the spline type of the selected object to <spline_type>, which can be \fIstraight\fR, \fIspline\fR, \fIinterpolated\fR, or \fIstructured\fR. If no object is selected, the current spline type will be changed to <spline_type>. .TP .I set_selected_obj_arrow(<arrow_type>) This command changes the arrow type of the selected object to <arrow_type>, which can be \fInone\fR, \fIright\fR, \fIleft\fR, or \fIdouble\fR. If no object is selected, the current arrow type will be changed to <arrow_type>. .TP .I set_selected_obj_dash(<dash_index>) This command changes the dash type of the selected object to <dash_index>, which must be between 0 (solid) and 8. If no object is selected, the current dash type will be changed to <dash_index>. .TP .I set_selected_obj_trans_pat(<trans_pat>) This command changes selected object to have opaque pattern if <trans_pat> is 0; it changes selected object to have transparent pattern if <trans_pat> is any other numeric value. If no object is selected, the current fill and pen pattern will be opaque if <trans_pat> is 0 and will be transparent if <trans_pat> is any other numeric value. .TP .I set_selected_obj_rcb_radius(<rcb_radius>) This command changes the rcbox radius of the selected object to <rcb_radius>, which must be greater or equal to 4. If no object is selected, the current rcbox radius will be changed to <rcb_radius>. .TP .I set_selected_text_vspace(<vspace>) This command changes the text vspace of the selected object to <vspace>. If no object is selected, the current text vspace will be changed to <vspace>. .TP .I set_selected_text_just(<justification>) This command changes the text justification of the selected object to <justification>, which can be \fIleft\fR, \fIcenter\fR, or \fIright\fR. If no object is selected, the current text justification will be changed to <justification>. .TP .I set_selected_text_font(<ps_font_name>) This command changes the font and text style of the selected object to match <ps_font_name>. Examples of valid <ps_font_name> can be found when one selects CopyProperties() from the Properties Menu. The item listed under \fItext font\fR is a valid <ps_font_name>. If no object is selected, the current font and text style will be changed to match <ps_font_name>. This command fails if no match can be found. .TP .I set_selected_text_style(<textstyle>) This command changes the text style of the selected object to <textstyle>, which can be \fIr\fR (for roman), \fIb\fR (for bold), \fIi\fR (for italic), or \fIbi\fR (for bold-italic). If no object is selected, the current text style will be changed to <textstyle>. .TP .I set_selected_text_size(<size>) This command changes the text size of the selected object to <size>. If <size> ends with the substring "pt", then point size is used instead of text size. If such as size cannot be found in the Size Menu, the closest size in the Size Menu will be used. If no object is selected, the current text size will be changed to <size> or the closest size. .TP .I set_selected_text_underline(<underline>) This command removes text underline from the selected object if <underline> is 0; it underlines text in the selected object if <underline> is any other numeric value. If no object is selected, the current text underline will be changed accordingly. .TP .I set_selected_text_overline(<overline>) This command removes text overline from the selected object if <overline> is 0; it overlines text in the selected object if <overline> is any other numeric value. If no object is selected, the current text overline will be changed accordingly. .TP .I inc(<attr_name>,<expr>) This command increment <attr_name> by the expression <expr>. Both the value of <attr_name> and <expr> must be integers. Please see the ARITHMETIC EXPRESSIONS section below for details about expressions. .TP .I dec(<attr_name>,<expr>) This command decrement <attr_name> by <expr>. Both the value of <attr_name> and <expr> must be integers. .TP .I shuffle_obj_to_top(<obj_name>) This command move <obj_name> to the top. If <obj_name> is a subobject, it is raised to the top, relative to its siblings. This command is useful in animation where a selected frame (subobject) can be raised to the top. .TP .I shuffle_obj_to_bottom(<obj_name>) This command move <obj_name> to the bottom. If <obj_name> is a subobject, it is dropped to the bottom, relative to its siblings. This command is useful in animation where a selected frame (subobject) can be dropped to the bottom. .TP .I disable_undo() This command cleans up the undo/redo records and disable undo (and stop recording undo/redo information). The original history depth is saved away. This command should be used before a long animation sequence. .TP .I enable_undo() This command restores the history depth saved away by the disable_undo() command and enables undo/redo. This command should be eventually used after disable_undo() is called. .TP .I get_drawing_area(<ltx_attr>,<lty_attr>,<rbx_attr>,<rby_attr>) This command stores the absolute coordinate of the current drawing area in the specified attributes. <ltx_attr> stores the left-top X coordinate, <lty_attr> stores the left-top Y coordinate, <rbx_attr> stores the right-bottom X coordinate, and <rby_attr> stores the right-bottom Y coordinate. .TP .I get_selected_obj_bbox(<ltx_attr>,<lty_attr>,<rbx_attr>,<rby_attr>) This command stores the absolute coordinate of the bounding box of the selected object in the specified attributes. <ltx_attr> stores the left-top X coordinate, <lty_attr> stores the left-top Y coordinate, <rbx_attr> stores the right-bottom X coordinate, and <rby_attr> stores the right-bottom Y coordinate. The bounding box is computed assuming that all lines are of width 0. .TP .I get_named_obj_bbox(<obj_name>,<ltx_attr>,<lty_attr>,<rbx_attr>,<rby_attr>) This command stores the absolute coordinate of the bounding box of the object named <obj_name> in the specified attributes. <ltx_attr> stores the left-top X coordinate, <lty_attr> stores the left-top Y coordinate, <rbx_attr> stores the right-bottom X coordinate, and <rby_attr> stores the right-bottom Y coordinate. The bounding box is computed assuming that all lines are of width 0. .TP .I move_selected_obj_absolute(<ltx>,<lty>) This command moves left-top corner of the selected object to (<ltx>,<lty>). .TP .I assign(<attr_name>,<expr>) This command assigns <expr> to the attribute specified by <attr_name>. <expr> must be evaluated to a numeric value. .TP .I strcpy(<attr_name>,<string>) This command copies <string> into the attribute specified by <attr_name>. .TP .I copy_string_to_cut_buffer(<string>) This command copies <string> into the cut buffer. .TP .I strcat(<attr_name>,<string>) This command appends <string> to the attribute specified by <attr_name>. .TP .I while(<expr>,<cmd_attr_name>) This command keeps executing the internal command in <cmd_attr_name> until <expr> evaluates to 0. .TP .I if(<expr>,<then_cmd_attr_name>,<else_cmd_attr_name>) If <expr> evaluates to 0, the internal command in <else_cmd_attr_name> is executed; otherwise, the internal command in <then_cmd_attr_name> is executed. <then_cmd_attr_name> or <else_cmd_attr_name> can be the string \fINULL\fR (case-sensitive); in this case, no corresponding action is taken. .TP .I get_current_file(<attr_name>) This command stores the full path name of the current file in <attr_name>. .TP .I get_current_export_file(<attr_name>) This command stores the full path name of the output (print/export) file in <attr_name>. .TP .I get_current_dir(<attr_name>) This command stores the current directory in <attr_name>. .TP .I getenv(<attr_name>,<env_var_name>) This command stores the environment variable named <env_var_name> in <attr_name>. .TP .I strlen(<attr_name>,<string>) This command assigns the number of characters in <string> to <attr_name>. .TP .I substr(<attr_name>,<string>,<start_index>,<length>) This command copies <length> characters, starting from the character index <start_index>, of <string> into <attr_name>. The <start_index> is zero-based. .TP .I strstr(<attr_name>,<string>,<sub_string>) This command finds the first occurrence of <sub_string> in <string> and copies <sub_string> and the rest of the string into <attr_name>. .TP .I strrstr(<attr_name>,<string>,<sub_string>) This command finds the last occurrence of <sub_string> in <string> and copies <sub_string> and the rest of the string into <attr_name>. .TP .I unmake_selected_obj_iconic() This command has the same effect as selecting UnMakeIconic() from the Special Menu except that at least one object must be selected already. .TP .I hyperjump_then_exec(<attr_name>,<attr_name_to_exec>) This command teleports to the file name or URL name found in the <attr_name> attribute then executes the internal command specified by the <attr_name_to_exec> attribute in the new file. .TP .I show_attr(<attr_name>) This command makes the <attr_name> attribute visible. .TP .I hide_attr(<attr_name>) This command makes the <attr_name> attribute invisible. .TP .I show_attr_name(<attr_name>) This command makes the name part of the <attr_name> attribute visible. .TP .I hide_attr_name(<attr_name>) This command makes the name part of the <attr_name> attribute invisible. .TP .I show_value(<attr_value>) This command makes the attribute whose name is empty and whose value is <attr_value> visible. .TP .I hide_value(<attr_value>) This command makes the attribute whose name is empty and whose value is <attr_value> invisible. .TP .I get_attr_bbox(<ltx_attr>,<lty_attr>,<rbx_attr>,<rby_attr>,<attr_name>) This command stores the absolute coordinate of the bounding box of the <attr_name> attribute in the specified attributes. <ltx_attr> stores the left-top X coordinate, <lty_attr> stores the left-top Y coordinate, <rbx_attr> stores the right-bottom X coordinate, and <rby_attr> stores the right-bottom Y coordinate. The bounding box is computed assuming that all lines are of width 0. .TP .I size_selected_obj_absolute(<abs_w>,<abs_h>) This command stretches the right-bottom corner of the selected object so that its width becomes <abs_w> and height becomes <abs_h>. .TP .I size_named_obj_absolute(<obj_name>,<abs_w>,<abs_h>) This command stretches the right-bottom corner of the object named <obj_name> so that its width becomes <abs_w> and height becomes <abs_h>. .TP .I message_box(<attr_name>,<msg>,<title>,<style>) This command displays a messagebox with <title> as the title and <msg> as the message. <style> can be the string "info", "ync", "yn", or "stop". The messagebox display an OK button for the "info" or "stop" styles, YES/NO/CANCEL buttons for the "ync" style, YES/NO buttons for the "yn" style. When the user click a button in the messagebox, the name of the button will be placed in <attr_name>. If the user cancels the messagebox by typing the <ESC> key, <attr_name> will be set to the string "CANCEL". If <attr_name> is the string \fINULL\fR (case-sensitive), the information about which button is clicked is not written anywhere. If <title> is the string \fINULL\fR, \fITgif\fR will be the title for the messagebox. .TP .I get_user_input(<attr_name>,<msg1>,<msg2>) This command displays a dialogbox with <msg1> in the first line and <msg2> in the second line. If <msg2> is the string "USE_CURRENT_DIR", the second line displays the current directory. The user can type in a line in the dialogbox which get placed in <attr_name>. If the user cancels the dialog by typing the <ESC> key, <attr_name> will be set to the empty string. .TP .I add_attr_to_selected_obj(<attr_name>,<attr_value>,<abs_x>,<abs_y>) This command adds <attr_name>=<attr_value> to a selected object and place the attribute at (<abs_x>,<abs_y>). If <attr_name> is the string \fINULL\fR (case-sensitive), the attribute's name will be the empty string. If <abs_x> and <abs_y> are both \fINULL\fR (case-sensitive), the attribute will be placed below the lower left corner of the object. If <attr_name> starts with "!.", a \fIfile attribute\fR will be added. .TP .I delete_attr_from_selected_obj(<attr_name>) This command deletes an attribute named <attr_name> from a selected object. If <attr_name> starts with "!.", a \fIfile attribute\fR will be deleted. .TP .I user_end_an_edge(<attr_name>,<abs_x>,<abs_y>) This command starts a polyline/open-spline at (<abs_x>,<abs_y>), switches the drawing mode to the draw polyline/open-spline, and lets the user finish the polyline/open-spline. If the endpoint falls in an object having an attribute \fItype=port\fR, that object's name will be placed in <attr_name>, if <attr_name> is not the string \fINULL\fR (case-sensitive). .TP .I user_draw_an_edge(<start_attr_name>,<end_attr_name>) This command switches the drawing mode to the draw polyline/open-spline and lets the user draw a polyline/open-spline. If the first endpoint falls in an object having an attribute \fItype=port\fR, that object's name will be placed in <start_attr_name>, if <end_attr_name> is not the string \fINULL\fR (case-sensitive). If the last endpoint falls in an object having an attribute \fItype=port\fR, that object's name will be placed in <end_attr_name>, if <attr_name> is not the string \fINULL\fR (case-sensitive). .TP .I get_a_poly_vertex_absolute(<x_attr_name>,<y_attr_name>,<obj_name>,<index>) This command stores the absolute coordinate of the <index>\fIth\fR vertex of <obj_name> in attributes specified by <x_attr_name> and <y_attr_name>. The object specified by <obj_name> must be either a poly/open-spline or a polygon/closed-spline object. .TP .I move_a_poly_vertex_absolute(<obj_name>,<index>,<abs_x>,<abs_y>) This command moves the <index>\fIth\fR vertex of <obj_name> to the absolute coordinate (<abs_x>,<abs_y>). The object specified by <obj_name> must be either a poly/open-spline or a polygon/closed-spline object. .TP .I post_attr_and_get_cgi_result(<url_attr>,<query_attr>,<result_attr>) This command makes an HTTP request using the \fIPOST\fR method. <url_attr> names the attribute that contains the URL (which usually names a CGI server script). <query_attr> names the attribute whose value is the data to be posted. <result_attr> names the attribute for receiving the results. For example, if an object has the following attributes: .PP .RS .RS url=http://bourbon.usc.edu:8001/cgi-bin/echo-post .br query=Hello World! .br result= .br exec=post_attr_and_get_cgi_result(url,query,result) .RE .RE .PP .RS executing this object will post "Hello World!" to the specified CGI script. In this case, the result of executing the script just echoes "Hello World!" back (along with some other bookkeeping information). .RE .TP .I navigate_back() This command performs the same operation as if the NavigateBack() is selected from the Navigate Menu. .TP .I stop() This command stops the execution of all internal commands. .TP .I sqrt(<attr_name>,<expr>) This command assigns the square-root of <expr> to <attr_name>. <expr> must be evaluated to a non-negative numeric value. .TP .I random(<attr_name>) This command assigns a random integer to <attr_name> using the C library function \fIrand()\fR. 0 is used as a seed for the random number generator. .TP .I srand48(<use_cur_time_as_seed>) This command seeds the random generator used by the C library function \fIdrand48()\fR. If <use_cur_time_as_seed> is 0, 0 will be used as a seed. Otherwise, the current time will be used as a seed. .TP .I drand48(<attr_name>) This command assigns a floating pointer number between 0.0 and 1.0 to <attr_name> using the C library function \fIdrand48()\fR. .TP .I round(<attr_name>,<expr>) This command assigns the round of <expr> to <attr_name>. .TP .I redraw_obj(<obj_name>) This command redraws the area occupied by <obj_name>. .TP .I redraw_drawing_area() This command redraws the whole drawing area (visible through the Canvas Window). .TP .I itox(<attr_name>,<digits>,<expr>) This command assigns <attr_name> to be the hex value of <expr>. <digits> (which must be between 1 and 8, inclusive) is the final width of the hex value (zeroes are added on the left). .TP .I for_i(<attr_name>,<min_val>,<max_val>,<increment>,<cmd_attr_name>) This command is the same as the following sequence of commands: .PP .RS .RS assign(<attr_name>,<min_val>); .br while($(<attr_name>) <= <max_val>,\fIloop\fR) .RE .RE .PP .RS where \fIloop\fR has the following value: .RE .PP .RS .RS exec(<cmd_attr_name>); .br inc(<attr_name>,<increment>) .RE .RE .PP .RS Please note that <min_val>, <max_val>, and <increment> are only evaluated once prior the execution of this command. .RE .TP .I set_file_not_modified() This command sets the file modified flag to false. .TP .I new_id(<attr_name>) This command generates an object ID, which is unique in the current drawing, and stores it in <attr_name>. .TP .I rotate_selected_obj(<angle>) This command rotates the selected object by <angle> degrees. Positive angle is clockwise. .TP .I call_simple_shortcut(<shortcut_name>) This command calls a shortcut named <shortcut_name> which takes no arguments. Please see the SHORTCUTS section for a description of shortcuts. .TP .I call_one_arg_shortcut(<shortcut_name>,<arg>) This command calls a shortcut named <shortcut_name> that takes one argument and passes <arg> to it. Please see the SHORTCUTS section for a description of shortcuts. .TP .I substitute_attr(<attr_name>,<src_attr_name>,<replace_attr_name>,<pattern_str>) This command replaces occurrences of <pattern_str> in the value part of the attribute specified by <src_attr_name> by the value of the attribute specified by <replace_attr_name> and write the result into the attribute specified by <attr_name>. .TP .I get_file_size(<attr_name>,<file_name>) This command puts the size of file specified by <file_name> in the attribute specified by <attr_name>. .TP .I is_file(<attr_name>,<file_name>) This command puts a "1" in the attribute specified by <attr_name> if the file specified by <file_name> exists. It puts a "0" otherwise. .TP .I index(<attr_name>,<string>,<sub_string>) This command finds the first occurrence of <sub_string> in <string> and copies the zero-based index into <attr_name>. .TP .I rindex(<attr_name>,<string>,<sub_string>) This command finds the last occurrence of <sub_string> in <string> and copies the zero-based index into <attr_name>. .TP .I get_number_of_lines_in_attr(<result_attr>,<attr_name>) This command counts the number of lines in the attribute specified by <attr_name> and writes the count into <result_attr>. .TP .I get_line_in_attr(<result_attr>,<attr_name>,<line_number>) This command copies the \fIn\fRth line of the attribute specified by <attr_name> into <result_attr>, where \fIn\fR is a zero-based index specified by <line_number>. .TP .I trim(<attr_name>) This command removes leading and trailing blank characters from the attribute specified by <attr_name>. .TP .I is_attr(<result_attr>,<attr_name>) This command writes a "1" into <result_attr> if the attribute specified by <attr_name> exists. It writes a "0" into <result_attr> otherwise. .TP .I find_obj_names(<result_attr>,<obj_name>,<attr_name_value>) This command finds all objects that are direct sub-objects of the object specified by <obj_name> and writes their names into <result_attr>. If <obj_name> is an empty string, all top-level objects are scanned. .PP .RS <attr_name_value> specifies a filter for the objects. If <attr_name_value> is the empty string, all qualifying objects are selected. If <attr_name_value> is of the form "<string>=*", an object is selected if it has an attribute named <string>. If <attr_name_value> is of the form "<string>=<value>", an object is selected if it has an attribute named <string> and its corresponding value is <value>. If <attr_name_value> does not contain the '=' character, an object is selected if it has an attribute whose name is empty and the corresponding value is identical to <attr_name_value>. .RE .PP .RS If \fIn\fR objects are matched, the attribute specified by <result_attr> is updated with \fIn+1\fR lines. The value of the zeroth line becomes \fIn\fR and the object names becomes lines 1 through \fIn\fR of <result_attr>. The get_line_in_attr() internal command can be used to retrieve the object names. .RE .TP .I find_obj_names_on_all_pages(<result_attr>,<attr_name_value>) This command is similar to find_obj_names() above, except that it only finds top-level objects on all pages. The result is written into <result_attr>. For a multi-page file, a top-level object name \fI<name>\fR will be written into <result_attr> as \fI##<page_num>!<name>\fR. For a single-page file, this command behaves exactly the same as find_obj_names(<result_attr,"",<attr_name_value>). .TP .I tg2_find_obj_names_on_all_pages(<result_attr>,<attr_name_value>) This command is identical to find_obj_names_on_all_pages() above, except that for a multi-page file, a top-level object name \fI<name>\fR will be written into <result_attr> as \fI<name>_Page<page_num>\fR. .TP .I tokenize(<result_attr>,<string>,<separator>) This command breaks <string> into tokens which are separated by the <separator> character and writes the tokens (in the same fashion as in the find_obj_names() internal command above) into <result_attr>. <separator> must be a string of length of 1 and it must not be the space character, the single-quote character, or the double-quote character. If a token contains the separator character, the token can be surrounded by a pair of single-quotes or double-quotes which are automatically removed when this command is executed. .PP .RS If \fIn\fR tokens are found, the attribute specified by <result_attr> is updated with \fIn+1\fR lines. The value of the zeroth line becomes \fIn\fR and the tokens becomes lines 1 through \fIn\fR of <result_attr>. The get_line_in_attr() internal command can be used to retrieve the tokens. .RE .TP .I move_attr_relative(<attr_name>,<dx>,<dy>) This command moves the attribute whose name is <attr_name> by <dx> absolute units in the x direction and <dy> absolute units in the y direction. .TP .I get_number_of_vertices(<result_attr>,<obj_name>) This command copies the number of vertices of the object specified by <obj_name> into <result_attr>. The specified object must be a polyline (open-spline) or a polygon (closed-spline). .TP .I is_obj_transformed(<result_attr>,<obj_name>) This command writes a "1" into <result_attr> if the object specified by <obj_name> is transformed (rotated or sheared). It writes a "0" into <result_attr> otherwise. .TP .I make_selected_obj_iconic(<sym_path>) This command works like the MakeIconic() command from the Special Menu, except that the user is not prompted for the name of the icon. Instead, <sym_path> is used to specify the full path name of the icon. .TP .I get_tgif_version(<major_attr,minor_attr,patchlevel_attr,build_attr>) This command writes tgif's major version number, minor version number, patchlevel, and build information into <major_attr>, <minor_attr>, <patchlevel_attr> and <build_attr>, respectively. If an argument is the string \fINULL\fR (case-sensitive), that information is skipped. .TP .I get_tgif_dir(<result_attr>) This command writes "$HOME/.Tgif" into <result_attr> where $HOME is the home directory of the user. .TP .I get_profile_string(<result_attr>,<section>,<key>,<def_value>,<ini_path>) This command gets the value associated with the key specified by <key> from the section specified by <section> in the file specified by the full path <ini_path> and stores it into the attribute specified by <result_attr>. If there is not value associated with the specified key, <def_value> is stored into <result_attr>. If <key> is an empty string, all the key names in <section> of <ini_path> will be written (in the same fashion as in the find_obj_names() internal command above) into <result_attr>. If <section> is an empty string, all the section names in <ini_path> will be written (in the same fashion as in the find_obj_names() internal command above) into <result_attr>. .TP .I write_profile_string(<section>,<key>,<value>,<ini_path>) This command sets the value associated with the key specified by <key> of the section specified by <section> in the file specified by the full path <ini_path> to be <value>. If <key> is an empty string, all key/value pairs in <section> of <ini_path> will be cleared. <section> should not be an empty string. .TP .I select_additional_obj(<obj_name>) This command silently (no highlighting handles) selects an additional object named <obj_name>. Please see the OBJECT NAMES section above for the specification of object names. .TP .I open_file(<file_number>,<file_name>,<file_mode>) This command opens the file specified by <file_name> in the mode specified by <file_mode> and assigns the opened file a file reference number of <file_number>. <file_number> must be 0 or between 3 and 15. Opening file 0 \fIrewinds\fR the standard input. Examples of modes are "r" for reading, "w" for writing, and "a" for appending. A file is always opened in text (non-binary) mode. .TP .I close_file(<file_number>) This command closes the file associated with file reference number <file_number>. <file_number> must be 0 or between 3 and 15. .TP .I read_file(<file_number>,<result_attr>) This command reads a line from the file associated with file reference number <file_number> and put the line in the attribute specified by <result_attr>. <file_number> must be between 0 (for standard input) or between 3 and 15. .TP .I write_file(<file_number>,<string>) This command writes <string> to the file associated with file reference number <file_number>. <file_number> must be between 1 and 15. Numbers 1 and 2 are for standard output and standard error files. .TP .I flush_file(<file_number>) This command flushes the file associated with file reference number <file_number>. <file_number> must be between 1 and 15. Numbers 1 and 2 are for standard output and standard error files. .TP .I append_file(<dest_file_name>,<src_file_name>) This command appends the file specified by <src_file_name> to the file specified by <dest_file_name>. .TP .I set_output_format(<format>,<color_output>) This command sets the output format to <format>. If <color_output> is 0, black and white output (printing) mode will be used; otherwise, color output (printing) mode will be used. Please see the Tgif.WhereToPrint X default for a list of possible formats. .TP .I set_export_clip_rect(<ltx>,<lty>,<rbx>,<rby>) This command sets the export clipping rectangle to be a rectangular region with left-top corner at (<ltx>,<lty>) and right-bottom corner at (<rbx>,<rby>). <ltx> must be strictly less than <rbx> and <lty> must be strictly less than <rby>. .TP .I import_file(<file_name>,<format>,<ltx>,<lty>) This command imports the file specified by <file_name> and places it at (<ltx>,<lty>). The file is expected to be in the format specified by <format>, which can be "XBM", "XPM", "GIF", "PNG", "JPEG", "PBM", "PGM", "PPM", and names specified by the Tgif.ImportFilter# X defaults. If <format> is "TGIF", the file should either be a tgif file. .TP .I set_xpm_output_version(<version_number>) This command sets the XPM version number when outputting in the X11 pixmap format to be <version_number>. <version_number> can take on values 1 or 3. .TP .I edit_ini_section(<attr_name>,<title>,<section>,<ini_path>) This command brings up a dialogbox to edit the section specified by <section> in the file specified by the full path <ini_path>. If the user press the OK button in the dialogbox, the section is cleared and the content of the dialogbox is written back into the file, and "OK" is placed in the attribute specified by <attr_name>. If the user press the CANCEL button in the dialogbox, the file is unmodified, and "CANCEL" is placed in the attribute specified by <attr_name>. .TP .I select_from_ini_section(<attr_name>,<title>,<section>,<ini_path>) This command brings up a list to select an entry from the section specified by <section> in the file specified by the full path <ini_path>. If nothing is selected, the attribute specified by <attr_name> will be cleared. Otherwise, the selected entry will be written into the attribute specified by <attr_name>. .TP .I append_line_into_attr(<attr_name>,<string>) This command appends the line specified by <string> to the attribute specified by <attr_name>. .TP .I insert_line_into_attr(<attr_name>,<string>,<line_number>) This command inserts the line specified by <string> as the \fIn\fRth line of the attribute specified by <attr_name>, where \fIn\fR is a zero-based index specified by <line_number>. \fIn\fR must be at least 1. If \fIn\fR is larger than the number of lines in the attribute, blank lines are automatically inserted. .TP .I clear_attr(<attr_name>) This command clears the attribute value of the attribute specified by <attr_name> and deletes all other lines of the attribute if the attribute contains multiple lines. .TP .I create_text_obj(<abs_x>,<abs_baseline_y>,<string>) This command creates a text object at the location (<abs_x>,<abs_baseline_y>) with the text specified by <string>. .TP .I create_box_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) This command creates a rectangle defined by (<abs_ltx>,<abs_lty>) and (<abs_rbx>,<abs_rby>). .TP .I create_corner_oval_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) This command creates a corner oval defined by (<abs_ltx>,<abs_lty>) and (<abs_rbx>,<abs_rby>). .TP .I create_center_oval_obj(<abs_x>,<abs_y>,<radius>) This command creates a center oval centered at (<abs_x>,<abs_y>) with radius specified by <radius>. .TP .I create_edge_oval_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) This command creates an edge circle defined by (<abs_ltx>,<abs_lty>) and (<abs_rbx>,<abs_rby>). .TP .I create_rcbox_obj(<abs_ltx>,<abs_lty>,<abs_rbx>,<abs_rby>) This command creates a rounded-corner rectangle defined by (<abs_ltx>,<abs_lty>) and (<abs_rbx>,<abs_rby>). .TP .I create_arc_obj(<abs_x>,<abs_y>,<radius>,<dir>,<angle1>,<angle2>) This command creates an arc centered at (<abs_x>,<abs_y>) with radius, direction, start angle, and end angle specified by <radius>, <dir>, <angle1>, and <angle2>, respectively. The <radius>, <dir>, <angle1>, and <angle2> are specified in the same way as they are specified in the SpecifyAnArc() command under the CreateObject submenu of the Edit Menu. <dir> can be "+" or "-" where "+" is clockwise. <angle1> and <angle2> are in degrees with 0 degree at the 12 o'clock position. .TP .I create_first_vertex(<abs_x>,<abs_y>) This command is used in conjunction with the create_next_vertex() and create_poly_obj() commands to create a polyline/open-spline object. It can also be used in conjunction with the create_next_vertex() and create_polygon_obj() commands to create a polygon/closed-spline object. This command sets the starting point of the polyline/open-spline object or the polygon/closed-spline object to be at (<abs_x>,<abs_y>). .TP .I create_next_vertex(<abs_x>,<abs_y>) This command is used in conjunction with the create_first_vertex() and create_poly_obj() commands to create a polyline/open-spline object. It can also be used in conjunction with the create_first_vertex() and create_polygon_obj() commands to create a polygon/closed-spline object. This command sets the next vertex of the polyline/open-spline object or the polygon/closed-spline object to be at (<abs_x>,<abs_y>). .TP .I create_poly_obj() This command is used in conjunction with the create_first_vertex() and create_next_vertex() commands to create a polyline/open-spline object. .TP .I create_polygon_obj() This command is used in conjunction with the create_first_vertex() and create_next_vertex() commands to create a polygon/closed-spline object. .TP .I start_create_group_obj() This command is used in conjunction with the create_group_obj() command to create a grouped object. This command marks the beginning of the group. .TP .I create_group_obj() This command is used in conjunction with the start_create_group_obj() command to create a grouped object. This command groups all objects created since the last start_create_group_obj() call into a grouped object. .TP .I set_allow_interrupt(<true_or_false>) If <true_or_false> is \fIFALSE\fR (case-sensitive), this command is used to temporarily disable an user interrupt when tgif is executing internal commands. If a user interrupt is received when interrupt is disabled, it will be queued and will interrupt the execution of internal commands when set_allow_interrupt() is called again with <true_or_false> being \fITRUE\fR (case-sensitive). .TP .I select_each_obj_and_exec(<attr_name_to_exec>) This command first unselects any object that is selected. It then selects each object in the current drawing in turn and executes the internal command specified by the <attr_name_to_exec> attribute. If this command is executed as a result of a mouse click over an object, only objects in the current page will be scanned for execution. If this command is executed from a script file, objects in every page will be scanned for execution. .TP .I edit_attr_in_text_mode(<attr_name>) When this command is executed, tgif enters the text drawing mode and edits the attribute specified by <attr_name>. .TP .I set_file_unsavable() This command is used to make the current file unsavable. .TP .I pstoepsi(<target_eps_path>,<src_ps_path>,<scale>) This command generates a preview bitmap for the PostScript file in <src_ps_path> and prepends it to <src_ps_path> and save the output in <target_eps_path> (<src_ps_path> is unmodified). The only accepted values of <scale> is 1 or 2. If the Tgif.ExternalPsToEpsi X default is set to true, this command will simply invoke "pstoepsi <src_ps_path> <target_eps_path>" externally if <scale> is 1 and will invoke "pstoepsi -2x <src_ps_path> <target_eps_path>" if <scale> is 2. This command only works if tgif is running in the interactive (non-batch) mode. .TP .I objs_bbox_intersect(<obj1_name>,<obj2_name>,<result_attr>) This command sets the value of the attribute specified by <result_attr> to "1" if the boundingboxes of objects named <obj1_name> and <obj2_name> intersect. It sets the value of the attribute specified by <result_attr> to "0" otherwise. .TP .I delete_all_attr_from_selected_objs() This command deletes all attributes from selected objects. Please only use this command when commands are taken from an external file! .TP .I random_permute_lines_in_attr(<attr_name>) This command randomly permutes lines of an attribute specified by <attr_name>. .\" .SH ARITHMETIC EXPRESSIONS .\" Certain internal commands allow arithmetic expressions as arguments. Infix notation is used. Supported operators (and their precedences) are listed below. .PP ? 1 if-then-else, e.g. <rel> ? <iftrue> : <else> : 2 if-then-else, e.g. <rel> ? <iftrue> : <else> || 3 logical OR && 4 logical AND | 5 bit-wise OR ^ 5 bit-wise XOR & 5 bit-wise AND == 6 equal != 6 not-equal > 7 greater than < 7 less than >= 7 greater than or equal to <= 7 less than or equal to << 8 shift left >> 8 shift right + 9 add - 9 subtract * 10 multiple / 10 divide // 10 integer divide % 10 mod ! 11 logical NOT ~ 11 bit-wise invert/NOT ) 12 closed parenthesis ( 13 open parenthesis .\" .SH GENERATING IMAGEMAP FILES .\" This section describes how to generate NCSA imagemap and CERN clickable image files. The Tgif.ImageMapFileFormat X default decides whether to generate a NCSA imagemap or a CERN clickable image file. Since the two formats are very similar, we will only discuss how to generate NCSA imagemap files. For more information about NCSA imagemap, please see [3]. For more information about CERN clickable image, please see [4]. .PP The Tgif.GenerateImageMap X default should be set to ``true'' to enable the imagemap generation. When printing in the GIF format (see the BASIC FUNCTIONALITIES section about printing), an XPM file (which will be removed at the end of this process) is generated first. (The value specified by the Tgif.InitExportPixelTrim X default is used to trim extra pixels. Using these values forms an escape mechanism to fix an idiosyncrasy that tgif can not figure out exactly how big the whole image is.) .PP The XPM version is specified by the Tgif.XPmOutputVersion X default unless the Tgif.UseXPmVersion1ForImageMap X default is set to ``true'', which forces the XPM1 format. Then the command specified by the Tgif.XpmToGif X default is executed to convert the XPM file into a GIF (Generic Interchange Format) file which can be used by software such as NCSA's Mosaic(1). The file extension for the GIF file is specified by the Tgif.GifFileExtension X default. Together with the GIF file, an imagemap file with file extension specified by the Tgif.ImageMapFileExtension X default is generated. The content of the imagemap is generated as follows. .PP Tgif first looks for a \fIfile attribute\fR with attribute name \fIhref\fR. The value of the attribute is written as the \fIdefault URL\fR. If such a file attribute can not be found, imagemap generation is aborted. If it is found, then all objects in the file are scanned. For an object having an attribute named \fIhref\fR, the value of the attribute is written as the \fIURL\fR for a \fImethod\fR line in the imagemap. If the object is neither a circle nor a poly/polygon, the \fIrectangle\fR method is used. .PP Similar mechanism is used when printing in the HTML format, except that a generic HTML file is generated with an imagemap in the Spy Glass Client-side Imagemap format. You can generate a custom HTML file if you specify an HTML export template using SetHTMLExportTemplate() from the File Menu. Details about the template file is described below. .\" .SH HTML EXPORT TEMPLATE .\" If an HTML export template file is specified with the SetHTMLExportTemplate() from the File Menu, custom HTML files can be generated when printing in the HTML format. The customization is done through the use of variables embedded in the HTML export template file. These variables have the syntax of an HTML character entity. They all starts with "&tgv" and ends with ";". They are: .TP .I &tgvfilename; This variable will be replaced by the name of the file (without file extension). .TP .I &tgvcurnum; This variable will be replaced by current page number. .TP .I &tgvfirstnum; This variable will be replaced by the first page number (usually 1). .TP .I &tgvlastnum; This variable will be replaced by last page number. .TP .I &tgvprevnum; This variable will be replaced by the previous page number (with wrap around). .TP .I &tgvprevnumnowrap; This variable will be replaced by the previous page number (with no wrap around). .TP .I &tgvnextnum; This variable will be replaced by the next page number (with wrap around). .TP .I &tgvnextnumnowrap; This variable will be replaced by the next page number (with no wrap around). .TP .I &tgvtitle; This variable will be replaced by the title the page or of the file. .TP .I &tgvmapobjs; This variable will be replaced by the objects (specified as <AREA> tabs) in a client-side image map. .PP For example, if a template specifies: .PP .RS <IMG SRC="&tgvfilename;-&tgvcurnum;.gif" .RS USEMAP="#p0"> .RE <MAP NAME="p0"> .br &tgvmapobjs; .br <AREA SHAPE="RECT" .RS COORDS="0,0,&tgvmapwidth;,&tgvmapheight;" .RE .RS HREF="&tgvfilename;-&tgvnextnum;.html"> .RE </MAP> .RE .PP Exporting using PrintOneFilePerPage() with this template may get (for page 2 of a file name "foo.obj" with 5 pages): .PP .RS <IMG SRC="foo-2.gif" .RS USEMAP="#p0"> .RE <MAP NAME="p0"> .br <AREA SHAPE="RECT" ...> .br ... .br <AREA SHAPE="RECT" ...> .br <AREA SHAPE="RECT" .RS COORDS="0,0,145,97" .RE .RS HREF="foo-3.html"> .RE </MAP> .RE .\" .SH GENERATING MICROSOFT WINDOWS EPSI FILES .\" Some Microsoft Windows (TM) applications do not understand standard PostScript %%BeginPreview, %%EndImage, and %%EndPreview comments. This section describes how to generate an EPSI file which is understood by them. This feature is invoked when the current print format is TiffEPSI. In this case, the generated EPSI file will contain 30 bytes of binary information in the beginning of the file and a TIFF image (also binary) at the end of the file. This file also will not contain the %%BeginPreview, %%EndImage, and %%EndPreview comments. A file in this format is normally not considered to be a PostScript file except under Windows. .PP When this feature is enabled, tgif generates a normal EPSI file first, then dump the current content of the file into an X11 bitmap file. The command specified in Tgif.XbmToTiff is executed to generate a TIFF image which is then append at the end of the EPSI file. .\" .SH LOCKING OBJECTS .\" Objects can be locked and unlocked using #< and #> keyboard commands. When a selected object is locked, it is shown with gray handles. A locked object cannot be moved, stretched, flipped, or rotated; however, its properties, such as fill pattern, width, etc., can be changed. Locked objects can also be deleted. When a locked object is grouped with other objects, the resulting grouped object is also locked. A locked object can be used as an anchor to align other objects; however, DistributeObjs() command will fail if any objects are locked. Locked objects do not participate in any operations in the select vertex mode. .\" .SH UNDO/REDO .\" Most operations can be undone and redone. The Tgif.HistoryDepth X default controls the size of the undo buffer. If it is set to -1, then the undo buffer's size is infinite. The undo buffer is flushed when the New() or Open() commands are executed (from the File Menu), when the FlushUndoBuffer() command is executed from the Edit Menu, or when Pop() is executed from a .sym file. If a private colormap is used (automatically done when new colors can not be allocated from the default colormap), executing FlushUndoBuffer() will attempt to reset the colormap (if the -DDONT_FREE_COLORMAP compile option is not used). .\" .SH DOMAINS .\" A \fIdomain\fR is a collection of library symbols suitable for instantiations. A library is implemented as a directory of .sym files, and therefore, a domain is implemented as a search path. If there are symbols with the same file name which reside in different directories specified in the search path, then the one closer to the front of the search path will be made available for the user to instantiate. .PP The number of domains is specified by the MaxDomains X default, and the names of the domains are specified by the DomainPath# X default. The library search paths are specified by csh environment variables. See the section on X DEFAULTS for more details. .PP Domain information can also be loaded into the ~/.Tgif/domain.ini file by setting Tgif.DomainInIni to true and selecting Reload Domain Info From X from the Domain submenu of the File Menu. .\" .SH SELECTING A NAME FROM A POPUP WINDOW .\" When selecting a file name, a symbol name, or a domain name, tgif pops up a window with appropriate names for the user to choose from. The user can use mouse clicks to select an entry. Key strokes can also be used to specify the desired name; however, tgif attempts to match the key strokes with names in the selection on the fly. If a match can not be found, the key strokes are ignored. ^n, ^j, or the DownArrow key advances the selection down by 1 entry; ^p, ^k, or the UpArrow key advances the selection up by 1 entry. ^f, ^d, or the DownArrow key with <Control> key held down advances the selection down by 10 entries; ^b, ^u, or the UpArrow key with <Control> key held down advances the selection up by 10 entries. '$' will select the last entry, while '^' will select the first entry. ^w or ^y un-select the selected entry. If the selected entry is a directory, hitting <CR> will change directory; if not, hitting <CR> finishes the selection process and the selected entry is returned. .PP In selecting file names to open or import, typing '/' is interpreted as going to the root directory or specifying an URL. At this point, the automatic matching of key strokes is temporarily disabled until either a <TAB> or a <CR> is pressed. Also, clicking the middle mouse button in the file name area pastes from the clipboard. .PP The automatic appending of \fIindex.obj\fR or \fI.obj\fR (introduced in version 2.16) became obsolete and an URL is never modified. .PP The current selection is displayed near the top of the popup window. Back-space should be used with caution because it might change the current directory to the parent directory. .\" .SH IMPORTING EPS FILES .\" Encapsulated PostScript (EPS) files can be imported using the #( keyboard command. If the EPS file has a preview bitmap (can be generated using the \fIpstoepsi\fR tool), tgif will display it (HideBit/Pixmap() from the Layout Menu can be used to disable the displaying of bitmap/pixmaps). When the EPS object is saved in a .obj or .sym file, neither the preview bitmap, nor the PostScript content of the EPS file is saved. Therefore, when printing such a file (either from tgif or using prtgif), the EPS file must be present at the same place from which it was originally imported. .\" .SH ADDITIONAL FONTS .\" In addition to the Times, Courier, Helvetica, NewCentury, and Symbol fonts, additional fonts can be specified using the Tgif.AdditionalFonts X default. (The default screen fonts can also be replaced, please see Tgif.HasAlternateDefaultFonts in the X DEFAULTS section for more details.) Each additional font requires \fI4\fR parts, one for each font style (in the order of Roman, Bold, Italic, and BoldItalic). Each part contains \fI3\fR strings. The first string specifies the family, weight, slant, and width of the font (please see the man pages for xfontsel(1) for more details; also there is a second form which is described below). The second string specifies the registry and encoding of the font (see xfontsel(1) again). (One can use xlsfonts(1) to see what fonts are available and pick out the just mentioned two strings from the output.) The third string specifies the PostScript font name. .PP For example, if one wants to use the X Lucida font to represent the PostScript ZapfChancery-MediumItalic font, one can set Tgif.AdditionalFonts as follows: .PP Tgif.AdditionalFonts: \\n\\ .br lucida-medium-r-normal \\n\\ .br iso8859-1 \\n\\ .br ZapfChancery-MediumItalic \\n\\ .br \\n\\ .br lucida-demibold-r-normal \\n\\ .br iso8859-1 \\n\\ .br ZapfChancery-MediumItalic \\n\\ .br \\n\\ .br lucida-medium-i-normal \\n\\ .br iso8859-1 \\n\\ .br ZapfChancery-MediumItalic \\n\\ .br \\n\\ .br lucida-demibold-i-normal \\n\\ .br iso8859-1 \\n\\ .br ZapfChancery-MediumItalic .br .PP The above maps all four font styles of the Lucida font to the ZapfChancery-MediumItalic font (similar to how Symbol font is handled). The first string can also be specified in a second form which is identified by having "%d" as part of the string. For example, one can use "lucidasans-%d" as the first string. In this case, the actual X font used will be the specified string with "%d" replaced by the font size. The encoding string (second string) is ignored (but must be present). The font name prefix (please see Tgif.FontNamePrefix entry in the X DEFAULTS section) is also ignored. .\" .SH POSTSCRIPT CHARACTER ENCODING FOR INTERNATINOAL CHARACTERS .\" Sometimes, different encodings of the same PostScript font is needed for characters \fIwith character codes between 161 and 255 (inclusive)\fR. This can be accomplished in two ways. One way is to use Tgif.AdditionalDontReencode (and Tgif.DontReencode). Another way is to use Tgif.PSFontNeedCharSubs. The difference is that with Tgif.AdditionalDontReencode, a PostScript font's encoding is skipped. With Tgif.PSFontNeedCharSubs, characters in a PostScript font can be given specific encoding. .PP In both cases, there is a need to introduce fake font names (place holders). For example, .PP .RS Tgif.AdditionalFonts: \\n\\ .br utopia-medium-r-normal \\n\\ .br adobe-fontspecific \\n\\ .br UtopiaTmp-Regular \\n\\ .br \\n\\ .br utopia-bold-r-normal \\n\\ .br adobe-fontspecific \\n\\ .br UtopiaTmp-Bold \\n\\ .br \\n\\ .br utopia-medium-i-normal \\n\\ .br adobe-fontspecific \\n\\ .br UtopiaTmp-Italic \\n\\ .br \\n\\ .br utopia-bold-i-normal \\n\\ .br adobe-fontspecific \\n\\ .br UtopiaTmp-BoldItalic .br Tgif.PSFontAliases: \\n\\ .br UtopiaTmp-Regular=Utopia-Regular \\n\\ .br UtopiaTmp-Bold=Utopia-Bold \\n\\ .br UtopiaTmp-Italic=Utopia-Italic \\n\\ .br UtopiaTmp-BoldItalic=Utopia-BoldItalic .RE .br .PP In the above example, 4 fake PostScript font names are created (all have a common "UtopiaTmp" prefix). The encoding for these fonts is adobe-fontspecific, according the X11 fonts being used. Tgif.PSFontAliases maps the fake PostScript font names to the corresponding real PostScript font names. (If Tgif.PSFontAliases is missing, non-existent PostScript font names such as UtopiaTmp-Regular will appear in a PostScript file.) .PP To skip a PostScript font's encoding, one can use the Tgif.AdditionalDontReencode X default. For example, if one specifies: .PP .RS Tgif.AdditionalDontReencode: UtopiaTmp .br .RE .PP characters with character codes between 161 and 255 (inclusive) will not be encoded with ISO-Latin-1 character names. For a list of characters names that are ISO-Latin-1 encoded, please see .br <URL:http://bourbon.usc.edu/tgif/faq/charencode.html#iso8859-1>. .PP To substitute characters in a PostScript font with specific encoding, one can use the Tgif.PSFontNeedCharSubs and Tgif.PSCharSubs_* X defaults. (You still need Tgif.AdditionalFonts and Tgif.PSFontAliases setup as above.) Here is an example: .PP .RS Tgif.PSFontNeedCharSubs: \\n\\ .br Utopia-Regular=Foo \\n\\ .br Utopia-Bold=Foo \\n\\ .br Utopia-Italic=Foo \\n\\ .br Utopia-BoldItalic=Foo .br Tgif.PSCharSubs_Foo: \\n\\ .br exclamdown/Aogonek \\n\\ .br AE/Cacute \\n\\ .br ecircumflex/eogonek .RE .br .PP In the above example, Tgif.PSFontNeedCharSubs specified a list of fake PostScript font names that requires character substitutions and their corresponding TOKEN names. For a fake PostScript font name that maps to \fITOKEN\fR, the list of characters to be substituted is specified in the Tgif.PSCharSubs_TOKEN X default. The format for Tgif.PSCharSubs_TOKEN is a list of OLDCHARCODE/NEWCHARNAME strings where OLDCHARCODE is a character code in decimal or octal format and NEWCHARNAME must be the name of a PostScript character. In the above example, \fIFoo\fR was used as the TOKEN name. In real use, something like \fIiso8895-2\fR may be more appropriate for a TOKEN name. Since decimal or octal codes are allowed, the following is equivalent to the above: .PP .RS Tgif.PSFontNeedCharSubs: \\n\\ .br Utopia-Regular=iso8859-2 \\n\\ .br Utopia-Bold=iso8859-2 \\n\\ .br Utopia-Italic=iso8859-2 \\n\\ .br Utopia-BoldItalic=iso8859-2 .br Tgif.PSCharSubs_iso8859-2: \\n\\ .br 161/Aogonek \\n\\ .br 8#306/Cacute \\n\\ .br 8#312/eogonek .RE .br .PP Please note that substitution \fIonly\fR occurs for characters with character codes between 161 and 255 (inclusive). .PP For more information, please see .br <URL:http://bourbon.usc.edu/tgif/faq/charencode.html#charsubs>. .\" .SH SQUARE DOUBLE BYTE FONTS .\" Starting with version 4.0 of tgif, double-byte fonts are supported. But only double-fonts where every character has the same width and height are supported. Double-byte fonts is specified using the Tgif.SquareDoubleByteFonts X default. The format of this X default is similar to that of the Tgif.AdditionalFonts X default described in the ADDITIONAL FONTS section above with differences described here. Each double-byte font requires \fI4\fR parts, one for each font style (in the order of Roman, Bold, Italic, and BoldItalic). Each part contains \fI3\fR strings. The first string specifies the name of the font. It must contain a "%d" as part of the string. The actual X font used will be the specified string with "%d" replaced by the font size. The second string can be either "*", "H", or "V". When it is the "V" string, each character is rotated 90 degrees counter-clockwise. Otherwise, the characters are not rotated. The third string specifies the PostScript font name. .PP Using input methods (specified by the Tgif.DoubleByteInputMethod X default) one can mix english (single-byte) substrings within a double-byte string. The font to use for the english substring is specified by the Tgif.DefaultSingleByteFont X default. .PP For example, if one wants to use the X Song Ti font to represent PostScript GB-Song-Regular font, one can set Tgif.SquareDoubleByteFonts as follows: .PP Tgif.DefaultSingleByteFont: Helvetica .br Tgif.GBShowFontChar: \271\372 Tgif.GBConvFromUTF8: iconv -f utf8 -t gb2312 Tgif.GBUConvToUTF8: iconv -f gb2312 -t utf8 .br Tgif.SquareDoubleByteFonts: \\n\\ .br -isas-song ti-*-*-*--%d-*-*-*-*-*-gb2312.1980-0 \\n\\ .br * \\n\\ .br GB-Song-Regular \\n\\ .br \\n\\ .br -isas-song ti-*-*-*--%d-*-*-*-*-*-gb2312.1980-0 \\n\\ .br * \\n\\ .br GB-Song-Regular \\n\\ .br \\n\\ .br -isas-song ti-*-*-*--%d-*-*-*-*-*-gb2312.1980-0 \\n\\ .br * \\n\\ .br GB-Song-Regular \\n\\ .br \\n\\ .br -isas-song ti-*-*-*--%d-*-*-*-*-*-gb2312.1980-0 \\n\\ .br * \\n\\ .br GB-Song-Regular .br .PP In the above example, the Song Ti font doesn't have styles such as italic and bold, so all four parts are identical. The Tgif.GBShowFontChar X default specifies a double-byte octal character to be used to represent this font in the Choice Window when this font is selected. The Tgif.GBUConvFromUTF8 X default specifies a command to run when an UTF8-encoded string is to be pasted into a text object in the GB font. The Tgif.GBUConvToUTF8 X default specifies a command to run in a copy operation to convert a selected string (in GB font) to the UTF8 format then copied to the clipboard. .PP Below is another example of using the X JIS fonts to represent PostScript Ryumin-Light-EUC-H and Ryumin-Light-EUC-V fonts as follows: .PP Tgif.RyuminShowFontChar: \244\242 .br Tgif.SquareDoubleByteFonts: \\n\\ .br -jis-fixed-*-*-*--%d-*-*-*-*-*-jisx0208.1983-* \\n\\ .br H \\n\\ .br Ryumin-Light-EUC-H \\n\\ .br -jis-fixed-*-*-*--%d-*-*-*-*-*-jisx0208.1983-* \\n\\ .br H \\n\\ .br Ryumin-Light-EUC-H \\n\\ .br -jis-fixed-*-*-*--%d-*-*-*-*-*-jisx0208.1983-* \\n\\ .br H \\n\\ .br Ryumin-Light-EUC-H \\n\\ .br -jis-fixed-*-*-*--%d-*-*-*-*-*-jisx0208.1983-* \\n\\ .br H \\n\\ .br Ryumin-Light-EUC-H \\n\\ .br \\n\\ .br -jis-fixed-*-*-*--%d-*-*-*-*-*-jisx0208.1983-* \\n\\ .br V \\n\\ .br Ryumin-Light-EUC-V \\n\\ .br -jis-fixed-*-*-*--%d-*-*-*-*-*-jisx0208.1983-* \\n\\ .br V \\n\\ .br Ryumin-Light-EUC-V \\n\\ .br -jis-fixed-*-*-*--%d-*-*-*-*-*-jisx0208.1983-* \\n\\ .br V \\n\\ .br Ryumin-Light-EUC-V \\n\\ .br -jis-fixed-*-*-*--%d-*-*-*-*-*-jisx0208.1983-* \\n\\ .br V \\n\\ .br Ryumin-Light-EUC-V .br .\" .SH MULTIPAGE DRAWING .\" An object file can contain multiple pages. Two layout modes, \fIstacked\fR and \fItiled\fR, for a multipage drawing are supported. In \fIstacked\fR layout mode, pages are considered to be stacked on top of each other, and therefore, an object can only appear on one page. In \fItiled\fR layout mode, pages are tiled to form a large logical page; in this case, an object can exist on several physical pages simultaneously. Swiching between the two modes are considered rare events and can not be undone. Tgif does not allow switching from the tiled layout mode to the stacked mode when there exists an object that spans physical page boundaries because it can not decide which physical page the object belongs. Page numbers are supported through the use of page numbering objects. A page number objecting is an object that contains an attribute whose name is \fI!PAGE_NUM\fR (the name is case-sensitive) and the name part of that attribute is not shown (hiding an attribute name can be achieved by using the Move/JustifyAttr() command under the Attribute submenu of the Special Menu). The value of the attribute determines how the page number is printed. If the value of the attribute contains a \fI!(STACKED_PAGE_NUM)\fR substring, that part of the substring will be replaced by the page number if the page layout mode is \fIstacked\fR. If the page layout mode is tiled, the string will be printed out as is. If the value of the attribute contains a \fI!(STACKED_NUM_PAGES)\fR substring, that part of the substring will be replaced by the number of pages if the page layout mode is \fIstacked\fR. If the value of the attribute contains a \fI!(TILED_PAGE_ROW)\fR or \fI!(TILED_PAGE_COL)\fR substring, that part of the substring will be replaced by the row number or the column number of the physical page if the page layout mode is \fItiled\fR. .\" .SH SPECIAL ATTRIBUTES .\" There are a few special attributes that tgif recognized. There are described in this section. They are all case-sensitive. .IP !PAGE_NUM=<page_number> This specifies the page numbers in a multipage drawing. Please see the MULTIPAGE DRAWING section for details. .IP auto_center_attr If an attribute's name is empty and the value is \fIauto_center_attr\fR, then all the visible attributes of the owner object will automatically be centered relative to the bounding box of the owner object. It doesn't really make sense to have multiple visible attributes because they will overlap. This attribute is useful for making simple flowchart elements. .IP unmakeiconic_on_instantiate If a symbol object's attribute has an empty attribute name and the value is \fIunmakeiconic_on_instantiate\fR, then when the symbol is instantiated, the following commands are performed on the just-instantiated icon object: 1) UnMakeIconic() command from the Special Menu, 2) UnGroup() command from the Arrange Menu, and 3) the "unmakeiconic_on_instantiate" text object is removed. This attribute is useful for making simple flowchart segments. .IP unmakeiconic_on_instantiate_delete_attrs If a symbol object's attribute has an empty attribute name and the value is \fIunmakeiconic_on_instantiate_delete_attrs\fR, then when the symbol is instantiated, the following commands are performed on the just-instantiated icon object: 1) UnMakeIconic() command from the Special Menu, 2) delete all attributes from this object, and 3) UnGroup() command from the Arrange Menu. This attribute is useful for putting a group of "useful" objects into a symbol object. .IP retracted_arrows If an attribute's name is empty and the value is \fIretracted_arrows\fR for a polyline or open-spline object with more than 2 vertices, then the arrows of the spline object is retracted by one vertex. .IP auto_retracted_arrows This is very similar to the \fIretracted_arrows\fR above except that the object must be an interpolated open-spline with only one arrow head. The spline object is forced to have 3 vertices and the middle vertex of the spline object is automatically adjusted when an endpoint is moved. .IP auto_exec=<internal_command> If such a file attribute exists, the value is executed when the file is opened (unless the file is opened as a result of executing the hyperjump_then_exec() internal command). .IP edit_attrs_in_context_menu=... If an object has an attribute named \fIedit_attrs_in_context_menu\fR, the values (starting from the 2nd line and separated by linebreaks) of this attribute are treated as attribute names. The named attributes will be visible in the Edit Attribute In Editor submenu of the Context Menu. For example, if an object has the following attributes: .PP .RS .RS edit_attrs_in_context_menu= .br .RS x .br y .br z .RE w=greetings .br x=hello .br y=world .br z=how are you .br good-bye .RE .RE .PP .RS the Edit Attribute In Editor submenu of the Context Menu will only show "x=hello", "y=world", and "z=how are you". .RE .\" .SH EXPORT TO TABLE .\" When the ExportToTable() command is selected from the Table submenu of the Special Menu, certain attributes of selected objects are written into a user-specified output file in a format which can be easily imported by a spreadsheet program or to be used by the MergeWithTable() command described in the next section. An output file contains columns of strings. Two columns are separated by a single <TAB> character. The first row of a output file contains the column names and all other rows contain values. .PP The names of the attributes to be written are specified by the \fIfile attribute\fR named \fITABLE_ATTRS\fR (which is denoted by \fI!.TABLE_ATTRS\fR here). The value of the TABLE_ATTRS file attribute is a list of comma-separated attribute names. When ExportToTable() command is executed, the attribute names specified by !.TABLE_ATTRS are written to the output file first. Then, for each selected object, every one of its attribute which appears in the list specified by !.TABLE_ATTRS are written to the output file in one line. If an object has no attributes that match the specification, no corresponding line is generated. .\" .SH MERGE WITH TABLE .\" When the MergeWithTable() command is selected from the Table submenu of the Special Menu, a selected object is \fImerged\fR (also known as \fImail-merged\fR on PCs) with a table (data) file (in the same format as the output file described in the previous section) to generate a new multipage drawing having the \fIstacked\fR page layout mode. .PP The selected object contains formating information, and it is also used as a template to be replicated for each data row in the table file. If an attribute of the replica matches the column name of the table, the attribute value is set to the value in the table file. The replicas are tiled horizontally first. .PP Eight attributes must be specified in the template object. They are all case-sensitive. The ones that measure distances can be specified in inches ("in"), centi-meters ("cm"), or pixels (if no units are specified). .RS .TP .I PAPER_WIDTH This specifies the width of the paper. .TP .I PAPER_HEIGHT This specifies the height of the paper. .TP .I LEFT_MARGIN This specifies the distance to the left edge of the paper. .TP .I TOP_MARGIN This specifies the distance to the top edge of the paper. .TP .I H_PITCH This specifies the distance between the left edges of the replicas. .TP .I V_PITCH This specifies the distance between the top edges of the replicas. .TP .I NUM_COLS This specifies the number of replicas to tile horizontally before moving down to the next row. .TP .I NUM_ROWS This specifies the number of replicas to tile vertically before moving to the next page. .RE .PP After each replica is generated, filled with the data from the table file, and placed, its attribute named \fIexec\fR is executed (unless an attribute named \fIEXEC_AFTER_MERGE\fR is specified, in which case, the attribute named by the \fIEXEC_AFTER_MERGE\fR attribute is executed instead). If there is no attribute named by the \fIEXEC_AFTER_MERGE\fR attribute, nothing is executed. (Please see the INTERNAL COMMANDS section for details on command execution.) One can use the \fIexec\fR command to construct other attributes from the attributes associated with the data table. .PP If an attribute whose name is empty and whose value is the string \fIUSER_PLACEMENT\fR, the user will be asked to place the replica (object name will be displayed in the Status Window when the object is being placed). In this case, the 8 placement related attributes are ignored. .PP If an attribute whose name is empty and whose value is the string \fISTRIP_DOUBLE_QUOTES\fR, data fields surrounded by double-quotes are stripped. .\" .SH MIME TYPES AND MAILCAPS .\" When an URL names an HTTP server, the HTTP server sends the \fIContent-type\fR of the URL along with the remote file referenced by the URL to tgif. The \fIContent-type\fR contains information such as the type/subtype of the file plus some optional fields. If the file is not a tgif file, the following mechanism is used to view the file. .PP First, the X defaults are looked up to see if there is an external viewer specified for the file. Please see Tgif.@@@Viewer in the X DEFAULTS section below for details. If there's no match, the type/subtype is matched against entries in the MIME-types file. The default MIME-types file is \fI.mime.types\fR in user's home directory. Please see Tgif.MimeTypesFile in the X DEFAULTS section on how to override the default MIME-types file. The first field in each line of the MIME-types file specifies type/subtype information. If there is a type/subtype match in the MIME-types files, the MailCap files are consulted as follows. .PP A line in a MailCap file consists of fields separated by semi-colons. The first field specifies the type/subtype and the second field specifies a \fIview command\fR for viewing a file that matches the type/subtype. For tgif, the view command must contains a single \fI%s\fR substring to be replaced by local copy of the URL. Only the \fI%t\fR and the \fI%{}\fR optional fields are supported by tgif. The \fImultipart\fR MIME-type is not supported. The type/subtype information of the remote file is matches against the MailCap files. If a match is found, the corresponding view command is executed. If no match is found, but the type of the remote file is either \fIapplication\fR, \fIaudio\fR, \fIimage\fR, or \fIvideo\fR, the file is saved and no external viewer is launched. Otherwise, the remote file is assumed to be pure text and tgif will create a text object to view the text. .PP The MailCap files are the (colon-separated) files specified by the MAILCAP environment variable (if defined). If MAILCAP is not defined, the \fI.mailcap\fR file in the user's home directory is used. .PP MIME is the Multipurpose Internet Mail Extensions specified in RFC1521, and MAILCAP is specified in RFC1524. .\" .SH HOW TO MAKE A BUILDING-BLOCK OBJECT (SYMBOL FILE) .\" Here are the steps for defining a building-block object, to be used in a hierarchical design. .IP 1) Draw the representation part of the building-block object. Group everything together. Select this grouped object. .IP 2) Popup the main menu with the middle mouse button; select ``Special''. Select ``MakeSymbolic'' from the next popup menu. The selected object becomes a symbol and gets a dashed boundary. .IP 3) Type in attributes as individual text strings. Select the symbol object and all the text strings to be attached to the symbol. Type #a (for \fIAttach\fR) to attach attributes to the symbol. .IP 4) (This step is optional.) Build the definition part of the building-block object. Look at the ``flip-flop.sym'' file for an example. To look at that file, first, instantiate a ``flip-flop'' by typing ^i (for \fIInstantiate\fR). Select the flip-flop from the popup window; place the flip-flop; select the flip-flop and type #v (for \fIPush\fR) to see the symbol file. .IP 5) Save and name the file. If the current library path contains the current directory (or '.'), the symbol just built should be instantiatable by typing ^i. .\" .SH X11 PIXMAP (XPM) FORMATS .\" Tgif can only import X11 pixmaps that satisfy the constraints described here. The format of the X11 pixmap must be either 1 (XPM1) or 3 (XPM3). Only a subset of the XPM3 format is supported, namely, the \fIkey\fR field for the color specification must be 'c' (for color visuals). Tools that generate XPM1 format files are (they might have been upgraded to support XPM3), \fIpbmplus\fR (or \fInetpbm\fR), which is a set of bitmap and pixmap conversion freeware (together with \fIxv\fR, the colors for pixmap objects can be manipulated), and \fIxgrabsc\fR, another freeware; also, \fIxloadimage\fR can display XPM1 files. Tools that can generate XPM3 format files are, for example, \fIxsnap\fR(1) and \fIsxpm\fR(1). For each color specified in the color string, a color cell is allocated. If the allocation fails, the current color will be used for that color string. If the first color character is a back-quote (`) or a space, then the corresponding color is substituted with the \fIbackground\fR color of the tgif window if the Tgif.GuessXPmBgColor X default is set to ``true''. (This design choice is made because the pixmap will then look ``right'' on both regular and reverse video.) The following is an example of a very small pixmap file (in XPM1 format). .PP .RS #define arrow_format 1 .br #define arrow_width 5 .br #define arrow_height 3 .br #define arrow_ncolors 3 .br #define arrow_chars_per_pixel 1 .br static char *arrow_colors[] = { .br "`", "Black", "a", "red", "b", "yellow" .br }; .br static char *arrow_pixels[] = { .br "`a```", .br "aabbb", .br "`a```" .br }; .br .RE .\" .SH LATEX FIGURE FORMATS .\" Here we show how to make a figure for a LaTeX file, first with the \fI\\psfig\fR (or \fI\\epsf\fR) special construct, then with the \fIpsfile\fR special construct. (The author does not recommend the \fIpsfile\fR construct.) An example of both can be found in ``example.tex'' which is included with the tgif distribution. .PP To print a tgif file to be included in a LaTeX document with the \fI\\psfig\fR or \fI\\epsf\fR special construct (files generated will be in the \fIEncapsulated PostScript\fR format), first select LaTeX format in the panel window (click the left mouse button on the laser printer icon), then type ^p to generate the Encapsulated PostScript file. If the file name is ``an-sr-flip-flop.obj'', then the LaTeX figure file generated will be named ``an-sr-flip-flop.eps''. This file can be included in a LaTeX document as follows, .PP .RS \\input{psfig} .br \\begin{figure*}[htb] .br \\centerline{\\psfig{figure=an-sr-flip-flop.eps}} .br \\caption{An SR flip-flop. \\label{fig:an-sr-flip-flop}} .br \\end{figure*} .br .RE .br .PP An alternative way is to use the \fI\\epsf\fR construct as follows, .PP .RS \\input{epsf} .br \\begin{figure*}[htb] .br \\centerline{\\epsffile{an-sr-flip-flop.eps}} .br \\caption{An SR flip-flop. \\label{fig:an-sr-flip-flop}} .br \\end{figure*} .br .RE .br .PP The \\centerline command above centers the picture. If one has multiple tgif figures in one's LaTeX document, one only have to include the psfig macro (\\input{psfig} or \\input{epsf}) once, right after the \\begin{document} statement. .PP If Encapsulated PostScript is not available, the \fIpsfile\fR special construct can be used as described here. In this case, since LaTeX doesn't not know where the bounding box of the drawing is, it takes some practice to get this just right. Here is something that seems to work. First, center the picture on the page (e.g., the width of a portrait style page is 8.5 inch, so the center of the page is at the 4.25 inch mark), and make the top object in the picture about 1/4 inch away from the top of the page. Select the LaTeX format in the panel window, then print in the LaTeX format. As with the \fIpsfig\fR construct, a file with the \fI.eps\fR extension will be generated. This file can be included in a LaTeX document as follows, .PP .RS \\begin{figure*}[htb] .br \\special{psfile="an-sr-flip-flop.eps" hoffset=-40} .br \\rule{0in}{1.1in} .br \\caption{An SR flip-flop. \\label{fig:an-sr-flip-flop}} .br \\end{figure*} .br .RE .br .PP The \\rule{0in}{1.1in} above specifies an invisible box of 1.1 inches high, which is the total height of the picture in an-sr-flip-flop. .\" .SH CONNECTING OBJECTS .\" In the world of E-CAD, an icon object can represent an electronic component and a line object can represent a connection between a pair of pins of two electronic components. When a component moves, the endpoint of a wire connecting to the component will also move with the component. Tgif simulates these functionalities in a limited fashion. .PP In tgif, a connection is represented by matching signal names. A wire is defined as a polyline object having a \fItype=tgWire\fR attribute and an attribute named \fIsignal_name\fR. The definition of a \fIpin\fR is more complicated. It is described in the next paragraph. If two pins have identical values for the \fIsignal_name\fR attribute, they are considered to be connected (they do not have to be visually connected by a wire). .PP A \fIpin\fR object must have a \fItype=port\fR attribute and attributes named \fIsignal_name\fR and \fIname\fR. But not all objects having such attributes are pins. In addition, a pin object must be either: .IP (1) a top-level symbol or an icon object .PP or: .IP (2) an immediate subobject of a \fIowner\fR symbol or icon object. or: .IP (3) an immediate subobject of a \fIowner\fR grouped object which has a \fItype=tgBroadcastWire\fR attribute. .PP In (2) above, the \fIowner\fR object must also have an attribute named \fIname\fR and must \fInot\fR be a subobject of another symbol or icon object. If the \fIowner\fR object is a subobject of a grouped object, the \fIname\fR attributes of the grouped object will be ignored. .PP In (3) above, that grouped object can be created using the ConnectPortsToBroadcastWire() command in the PortsAndSignals submenu of the Special Menu when a polyline object and some floating port objects are selected. .PP A \fIpin\fR object can have a connected view and a disconnected view. A connected view is a subobject with a \fIview=conn,FILL,PEN\fR attribute and a disconnected view is a subobject with a \fIview=disconn,FILL,PEN\fR attribute; FILL and PEN are numeric values between 0 and 31 (inclusive). The value corresponds to patterns in the Fill Menu and the Pen Menu. Normally, only 0 or 1 should be used. When the \fIsignal_name\fR attribute of a pin object is changed from an empty string to a non-empty string, the pen and fill of the subobject that corresponds to the disconnected view will be set to 0 (meaning NONE) and the pen and fill of the subobject that corresponds to the connected view will be set to the values specified in the \fIview\fR attribute of the connected view. When the \fIsignal_name\fR attribute of a pin object is changed from a non-empty string to an empty string, the pen and fill of the subobject that corresponds to the connected view will be set to 0 and the pen and fill of the subobject that corresponds to the disconnected view will be set to the values specified in the \fIview\fR attribute of the disconnected view. .PP A connection can be created using the ConnectTwoPortsByAWire() command from the PortsAndSignals submenu of the Special Menu. Please note that if a pin is part of another object, that object must also have a \fIname\fR attribute with a non-empty value. When two pins are connected using this command, the \fIsignal_name\fR attributes of the pins and the wire will be set to have the same value. .PP The moving of endpoints when a component moves is implemented in tgif using the constrained move mode from the MoveMode Menu (please see Tgif.ConstrainedMove in the X DEFAULTS section for additional information). Please note that a connected wire that is not visually connected will not automatically extends itself to follow a connected component even in the constrained move mode. Also, when a wire object is deleted, the \fIsignal_name\fR attributes of connected pins do not change (since they are not really "connected"). .\" .SH X DEFAULTS .\" .TP .I Tgif.Geometry: WIDTHxHEIGHT+X+Y .TP .I Tgif.IconGeometry: +X+Y .TP .I Tgif.Foreground: COLORSTRING The default foreground color is Black. .TP .I Tgif.Background: COLORSTRING The default background color is White. .TP .I Tgif.BorderColor: COLORSTRING If not specified, the foreground color will be used. .TP .I Tgif.ReverseVideo: [on,off] For black and white terminal, reverse video ``on'' means the background is black. For color terminal, reverse video ``on'' means the background is specified by the Tgif.Foreground color. The default is off. .TP .I Tgif.InitialFont: [Times,Courier,Helvetica,NewCentury,Symbol] This specifies the initial font. The default is Courier. .TP .I Tgif.InitialFontStyle: [Roman,Bold,Italic,BoldItalic] This specifies the initial font style. The default is Roman. .TP .I Tgif.InitialFontJust: [Left,Center,Right] This specifies the initial font justification. The default is Left. .TP .I Tgif.InitialFontDPI: [75,100] \fIObsoleted\fR. .TP .I Tgif.InitialFontSizeIndex: [0,1,2,3,4,5] \fIObsoleted\fR. .TP .I Tgif.InitialFontSize: NUMBER This specifies the size of the start-up font. The default is 14. An alternative form allows "pt" to be specified immediately after NUMBER (with no space between "pt" and the NUMBER). .TP .I Tgif.MsgFontSizeIndex: [0,1,2,3,4,5] \fIObsoleted\fR. .TP .I Tgif.MsgFontSize: NUMBER This specifies the size of the font used for messages, menues, and popup windows. The default is 14. .TP .I Tgif.RulerFontSize: NUMBER This specifies the size of the font used for ruler windows. The default is 10. .TP .I Tgif.DefaultFontSize: NUMBER This specifies the size of the font to be used when a requested for a font size can not satisfied. This size \fImust\fR exist for \fIall\fR fonts used in tgif. The default is 14. .TP .I Tgif.FontSizes: NUMBER1 NUMBER2, ... This specified the font sizes. The default is \fI8 10 11 12 14 17 18 20 24 25 34\fR. An alternative form allows "pt" to be specified immediately after a NUMBER (with no space between "pt" the the NUMBER). Please also use Tgif.InitialFontSize to specify the initial font size to use if 14 is not in the specified font sizes. .TP .I Tgif.AdditionalFonts: FONT_SPEC1 FONT_SPEC2 ... In addition to the Times, Courier, Helvetica, NewCentury, and Symbol fonts, additional fonts can be specified here. Please see the ADDITIONAL FONTS section for details. .TP .I Tgif.FontNamePrefix: [\fI-*\fR, \fI*\fR] This specified the prefix to be used when tgif makes a request to the X server. The default is \fI-*\fR. Certain fonts have obscure font names (e.g., does not start with the \fI-\fR character). In order to use these fonts, this X default can be set to \fI*\fR. .TP .I Tgif.DefaultLatin1FontCharEncoding: STRING Tgif uses 4 default fonts, "times", "courier", "helvetica", and "new century schoolbook". By default, the character encoding for these fonts is iso8859-1. These fonts are usually scalable and pre-installed in older Linux systems. In newer Linux system, this is no longer the case. Only a small number of font sizes are pre-installed. The pre-installed scalable versions of these fonts are iso10646-1 (Universal Character Set) encoded. This X default can be used to specify a different character encoding (such as iso10646-1) for the 4 default fonts. This X default does not apply to alternate default fonts or fonts specified by the Tgif.AdditionalFonts X default. The default is iso8859-1. .TP .I Tgif.HasAlternateDefaultFonts: [true,false] The default value of this X default is false. If it is set to ``false'', tgif uses the iso8859 registry with ASN1 encoded screen fonts (unless it's overridden by the Tgif.DefaultFontCharEncoding X default), and it looks for "times", "courier", "helvetica", "new century schoolbook", and "symbol" as part of the screen font names. Some X servers do not support these fonts. In this case, this X default can be used to make tgif use user specified screen and PostScript fonts. If this X default is set to ``true'', tgif will look for additional X defaults of the form \fITgif.<ps_font_name>\fR, where \fI<ps_font_name>\fR can be one of the following strings: .PP .RS .RS Times-Roman .br Times-Bold .br Times-Italic .br Times-BoldItalic .br Courier .br Courier-Bold .br Courier-Oblique .br Courier-BoldOblique .br Helvetica .br Helvetica-Bold .br Helvetica-Oblique .br Helvetica-BoldOblique .br NewCenturySchlbk-Roman .br NewCenturySchlbk-Bold .br NewCenturySchlbk-Italic .br NewCenturySchlbk-BoldItalic .br Symbol .br .RE .RE .br .PP .RS The corresponding value of the X default must contain "%d" as part of the string, and the "%d" string will be replaced by the font size when the font is requested. For example, The following lines will use the Times New Roman screen font instead of the Times screen font and use the Bookman PostScript font instead of the Times PostScript font, if Tgif.HasAlternateDefaultFonts is ``true'': .RE .PP .RS Tgif.Times-Roman: *-times new roman-medium-r-*--%d-*,Bookman-Light .br Tgif.Times-Bold: *-times new roman-bold-r-*--%d-*,Bookman-Demi .br Tgif.Times-Italic: *-times new roman-medium-i-*--%d-*,Bookman-LightItalic .br Tgif.Times-BoldItalic: *-times new roman-bold-i-*--%d-*,Bookman-DemiItalic .br .RE .br .PP .RS Please note that certain X servers require the right-hand-side font specifications to have all the dashes in place. .RE .TP .I Tgif.DefaultCursor: [x_cursor,arrow,...] This specifies the select cursor. Entries in <X11/cursorfont.h> (without the XC_ prefix) are valid names of the cursor. The default is arrow. .TP .I Tgif.DrawCursor: [x_cursor,arrow,...] This specifies the cursor used when drawing objects. Entries in <X11/cursorfont.h> (without the XC_ prefix) are valid names of the cursor. The default is the same as Tgif.DefaultCursor. .TP .I Tgif.DragCursor: [x_cursor,arrow,...] This specifies the cursor used when dragging. Entries in <X11/cursorfont.h> (without the XC_ prefix) are valid names of the cursor. The default is hand2. .TP .I Tgif.VertexCursor: [x_cursor,arrow,...] This specifies the cursor used in the select vertices mode. Entries in <X11/cursorfont.h> (without the XC_ prefix) are valid names of the cursor. The default is plus. .TP .I Tgif.FreeHandCursor: [x_cursor,arrow,...] This specifies the cursor used in freehand drawing mode. Entries in <X11/cursorfont.h> (without the XC_ prefix) are valid names of the cursor. The default is pencil. .TP .I Tgif.RubberBandColor: COLORSTRING This specifies the color to be used for rubber-banding (XORing). The default color is the same as the foreground color. .TP .I Tgif.MaxColors: NUMBER This specifies the maximum number of colors. Color0 through ColorMax, where Max is NUMBER-1, in X defaults are queried. If NUMBER is greater than the default of 11, Color11 through ColorMax \fImust\fR all exist in X defaults. Please see the GRAPHICAL OBJECTS section for a list of the default colors. .TP .I Tgif.Color#: COLORSTRING This specifies the correspondence between a color number and a color. .TP .I Tgif.DefaultColorIndex: NUMBER This specifies the default color index if a certain color can not be found. The default is 0. Please note Tgif.DefaultColor takes precedence over this X default. .TP .I Tgif.ShortCuts: ITEM1 ITEM2 ... The ITEM specifies the correspondence between a key (may be case sensitive) and a non-alphanumeric key command. Please see the SHORTCUTS section for details. .TP .I Tgif.MaxLineWidths: NUMBER This specifies the maximum number of line widths. LineWidth0 through LineWidthMax, ArrowWidth0 through ArrowWidthMax, and ArrowHeight0 through ArrowHeightMax, where Max is NUMBER-1, in X defaults are queried. If NUMBER is greater than the default value of 7, LineWidth7 through LineWidthMax, ArrowWidth7 through ArrowWidthMax, and ArrowHeight7 through ArrowHeightMax \fImust\fR all exist in X defaults. Some default values will be used for those that are not specified in the X defaults. .TP .I Tgif.DefaultLineWidth: NUMBER This specifies the initial line width \fIindex\fR. The default is 0. .TP .I Tgif.LineWidth#: NUMBER This specifies a line width. The default line widths are 1, 2, 3, 4, 5, 6, and 7. .TP .I Tgif.ArrowWidth#: NUMBER This specifies the width (when the arrow is pointing horizontally) of the arrow head for arc and open-spline objects. The default arrow widths are 8, 10, 12, 14, 18, 20, and 22. .TP .I Tgif.ArrowHeight#: NUMBER This specifies \fIhalf\fR the height (when the arrow is also pointing horizontally) of the arrow head for arc and open-spline objects. The default arrow heights are 3, 4, 5, 6, 7, 8, and 9. .TP .I Tgif.MaxDomains: NUMBER This specifies that NUMBER is the number of domains. DomainPath0,DomainPath1,...,DomainPathM all must exist in X defaults. Here M=NUMBER-1. .TP .I Tgif.DomainPath#: DOMAINSTRING This specifies the correspondence between a domain number, a domain name, and the path associated with a domain. Hence one DomainPath# X default is required for each domain defined. Here the # should be replaced with a domain number. The domain numbers should be 0,1,...,MAXDOMAINS-1, where MAXDOMAINS is set in the MaxDomain X default above. The MaxDomain X default in combination with the DomainPath# X default are required to use domains. .PP .RS DOMAINSTRING contains strings which are separated by the ':' symbol. The first string is the name of the domain. Each of the rest of the strings specifies a directory where symbol files are to be searched when the Instantiate command is executed (please see the HOW TO MAKE A BUILDING-BLOCK OBJECT section for details). Another way to look at the DOMAINSTRING specification is that removing the first string (which specifies the domain name) and the first ':' symbol, a DOMAINSTRING has the form of the \fIPATH\fR csh(1) environment variable. For example, to specify the symbol path for domain \fIDEFAULT\fR to look for symbol files, first in the library directory /tmp/tgif/symbols, then in the current directory, DOMAINSTRING should be set to the following value: .RE .PP .RS .RS DEFAULT:/tmp/tgif/symbols:. .br .RE .RE .br .TP .I Tgif.DefaultDomain: NUMBER This specifies the default domain when tgif starts up. The default is 0. .TP .I Tgif.PrintCommand: COMMAND This specifies the print command used for printing the PostScript file. The default is lpr(1). An example would be \fIlpr -h -Pprintername\fR. If COMMAND contains a \fI%s\fR substring, the \fI%s\fR will be replaced by the full path name of the PostScript file which is normally sent to the print command. Therefore, COMMAND without a \fI%s\fR substring behaves identically to \fICOMMAND %s\fR. Please note that this only works when running tgif without the -print command line option. This can be used to send a font file to the printer before the tgif PostScript file is sent as in the following example: .PP .RS .RS cat /somewhere/sansfex.pfa %s | lpr -Pmyprinter .RE .RE .PP .TP .I Tgif.WhereToPrint: STRING This specifies the initial print/export destination/format. STRING can be Printer, EPS, PS, Bitmap, Text, EPSI, GIF, HTML, PDF, WinEPSI, PNG, JPEG, PPM, or NetList. The default is EPS. .TP .I Tgif.PrintDirectory: PATH This specifies the print directory when the output destination is not the printer. The default is a null string, which means that the output goes into the directory in which the current file resides. .TP .I Tgif.NoTgifIcon: [true,false] If set to ``true'', tgif will not use its own icon window. In this case, one should also set Tgif.UseWMIconPixmap described below to true. Modern window managers usually do not allow an application to draw its own icon window, so this X default would have no effect when tgif is running under these window managers. The default is false. .TP .I Tgif.UseWMIconPixmap: [true,false] If set to ``true'', tgif will use the standard icon pixmap. Also, Tgif.NoTgifIcon will be ignored. The default is true. .TP .I Tgif.DontShowVersion: [true,false] If set to ``true'', the tgif version will not be displayed on top of the tgif window. The default is true. .TP .I Tgif.XBmReverseVideo: [true,false] If set to ``true'', an invert bitmap operation will be performed when importing an X11 bitmap file. The default is false. .TP .I Tgif.AskForXBmSpec: [true,false] If set to ``true'', the user will be asked to specify magnification and geometry for an X11 bitmap file being imported. Format of the specification is \fIMAG=WxH+X+Y\fR, where MAG is the magnification, W and H specifies the width and height, and the location specification can be +X+Y, +X-Y, -X+Y, and -X-Y. The '=' is mandatory if any of the geometry information is specified. The default is false. .TP .I Tgif.AskForXPmSpec: [true,false] If set to ``true'', the user will be asked to specify magnification and geometry for an X11 pixmap file being imported. The format of the specification is the same as for AskForXBmSpec. The default is false. .TP .I Tgif.StripEPSComments: (obsolete) This X default became obsolete in tgif-4.0.11 because it turns out that it's not always okay to strip PS comments (it should always be set to false). .TP .I Tgif.GuessXPmBgColor: [true,false] If set to ``true'', then when tgif imports an X11 pixmap file with the first color string being ' ' (the space character) or '`' (the back quote character), it will treat the first color as a \fIbackground\fR color. This means that the specified color in the X11 pixmap file will be changed to the current background color. The default is false. (Please note that this default was \fItrue\fR before patch 2 of tgif-2.7. This X default is there for compatibility reasons; it should be considered obsolete.) .TP .I Tgif.XPmOutputVersion: NUMBER This specifies the XPM version number when outputting in the X11 pixmap format. NUMBER can take on values 1 or 3. The default is 1. .TP .I Tgif.XPmInXGrabSCFormat: [true,false] If Tgif.XpmOutputVersion is set to 1, setting this to ``true'' will force the X11 pixmap output to resemble what xgrabsc generates (i.e., color names will not be used). The default is false. .TP .I Tgif.UseGrayScale: [true,false] If set to ``true'', gray scales will be used for tiling patterns to speed up printing. The default is false. .TP .I Tgif.AutoPanInEditText: [true,false] If set to ``true'', auto panning will be used such that the text cursor is always visible in text edit mode (except when the cursor is to the left or on top of the paper). This should probably be turned off on slow servers. The default is true. .TP .I Tgif.PercentPrintReduction: NUMBER This specifies the initial percent print reduction/magnification. The default is 100. .TP .I Tgif.ConstrainedMove: [true,false] This specifies the initial move mode. When set to ``true'', moving or stretching an object will cause the endpoints of all polylines or open-splines, whose endpoints fall within the object, and may be the neighboring vertices, to be moved. Please see the IDIOSYNCRASIES section for more details. The default value is false. .TP .I Tgif.DoubleQuoteDoubleQuote: [true,false] When set to ``true'', output of the double-quote character will be preceded by a double-quote character; when set to false, output of the double-quote character will be preceded by a back-slash character. The default value is false. .TP .I Tgif.GridSystem: [English,Metric] This sets the initial grid system. The default is English. .TP .I Tgif.InitialGrid: NUMBER This specifies the initial grid size. For the English grid system, NUMBER can be -2, -1, 0, +1, or +2 for grid sizes of 1/32, 1/16, 1/8, 1/4, and 1/2 inch. For the Metric grid system, NUMBER can be -1, 0, +1, or +2 for grid sizes of 1mm, 2mm, 5mm, and 1cm. The default value is 0. .TP .I Tgif.DropObsIconAttrWhenUpdate: [true,false] If set to ``true'', obsolete icon attributes will be dropped without confirmation when the UpdateSymbols command is executed. If set to ``false'', a popup window will prompt the user to specify what to do with the obsoleted icon attributes. The default is false. .TP .I Tgif.UseRecentDupDistance: [true,false] If set to ``true'', the most recent change in position produced by a combination of a duplicate and a move command will be used for the new duplicate command. Otherwise, some default distance will be used to position the duplicate. The default is true. .TP .I Tgif.SplineTolerance: NUMBER This specifies the tolerance of spline drawing. The smaller the number, the smoother the spline. The default is 9 (min is 3 and max is 13). .TP .I Tgif.SplineRubberband: (obsolete) If set to ``true'', spline rubber-bands will be used in drawing, moving, and stretching open and closed splines. (This might not be desirable if the spline contains too many vertices.) The default is true. This X default became obsolete since tgif-4.2 due to the addition of structured spline objects. .TP .I Tgif.Synchronize: [on,off] XSynchronize is called if this X default is set to ``on''. The default is off. .TP .I Tgif.DoubleClickUnIconify: [true,false] If set to ``true'', double mouse clicks are used to de-iconify the icon window (in this mode, the icon window ignores single mouse clicks and drags). The default is false. .TP .I Tgif.MainMenuPinDistance: NUMBER This specifies the horizontal distance (in pixels) the user needs to drag a popup menu before the popup menu is to be pinned down. The default is 80. (If pinned popup menus are not desired, then this should be set to a value greater than the screen width.) Dragging the left mouse button can be used to move the pinned popup menu; clicking the right button in the popup menu will remove it. .TP .I Tgif.DoubleClickInterval: NUMBER This specifies the maximum interval (in milliseconds) between two mouse clicked to be recognized as one double-click. The default is 300. .TP .I Tgif.HandleSize: NUMBER This specifies (half) the size of the handle used to highlight objects. Its allowable value is between 2 and 6. The default is 3. .TP .I Tgif.HistoryDepth: NUMBER This specifies the size of the undo/redo buffer; negative values mean that the buffer is unbounded. The default is -1. .TP .I Tgif.SaveTmpOnReturn: [true,false] If set to ``true'', a tmpmodel file will be saved automatically before returning to the driver. Otherwise, no files will be saved automatically. The default is true. .TP .I Tgif.ImportFromLibrary: [true,false] If set to ``true'', the library directories specified by the current domain are searched for .obj, .sym, xbitmap/xpixmap, and EPS files to import. Otherwise, the current directory will be used as the starting point. The default is false. .TP .I Tgif.WarpToWinCenter: [true,false] If set to ``true'', the mouse is warped to the center of popup windows. Otherwise, the mouse is not warped. The default is true. .TP .I Tgif.SaveCommentsInSaveNew: [true,false] If set to ``true'', "%%" type comments in the file will be stored in the newly created file. The default is true. .TP .I Tgif.CanvasWindowOnly: [true,false] If set to ``true'', only the canvas window will be displayed (this is a kind of the ``demo'' mode). The default is false. .TP .I Tgif.UsePsAdobeString: [true,false,NUMBER_1/NUMBER_2] If set to ``true'', the first line in the PS or EPS file will be "%!PS-Adobe-2.0 EPSF-1.2". If set to ``false'', it is just "%!". If the PS-Adobe string confuses the document manager (such as Transcript) on your site, you should set it to ``false''. If the third form is used, the first line will be "%!PS-Adobe-NUMBER_1 EPSF-NUMBER_2". The default is false. .TP .I Tgif.HalfToneBitmap: [true,false] If set to ``true'', the Floyd-Steinberg half-tone method will be used when printing in the X11 bitmap format. This is useful when the drawing contains X11 pixmap objects. The default is false. .TP .I Tgif.ThresholdBitmap: [true,false] If set to ``true'', a simple thresholding method will be used to decide whether a bit is turned on or off when printing in the X11 bitmap format. If Tgif.HalfToneBitmap is set to true, this X default is ignored. The default is false. .TP .I Tgif.BitmapThreshold: NUMBER This specifies the threshold value used in either the Floyd-Steinberg half-tone algorithm or the simple thresholding algorithm. NUMBER must be between 0 and 1. This X default is only active when either the Tgif.HalfToneBitmap or the Tgif.ThresholdBitmap X default is set to true. The default value is 0.5 if Tgif.HalfToneBitmap is true, and is 1.0 if Tgif.ThresholdBitmap is true (basically, anything that is not white will be black). .TP .I Tgif.EPSIThresholdPreviewBitmap: [true,false] If set to ``true'', a simple thresholding method will be used to decide whether a bit is turned on or off in the preview bitmap when printing in the EPSI format. The default is false. .TP .I Tgif.EPSIPreviewBitmapThreshold: NUMBER This specifies the threshold value used in the simple thresholding algorithm to decide whether a bit is turned on or off in the preview bitmap when printing in the EPSI format. NUMBER must be between 0 and 1. The default value is 0.5 if Tgif.EPSIThresholdPreviewBitmap is true, and is 1.0 if Tgif.EPSIThresholdPreviewBitmap is false (basically, anything that is not white will be black). .TP .I Tgif.GroupedTextEditable: [true,false] If set to ``false'', only top level text objects and attributes of top level objects can be edited when the drawing mode is set to the text mode. If set to ``true'', text objects and attributes everywhere can be edited. The default is false. .TP .I Tgif.DefaultEPSScaling: NUMBER This specifies the scaling factor applied to an imported PS or EPS image. As mentioned in the IDIOSYNCRASIES section below, tgif treats 128 pixels as an inch and PostScript treats 72 points as an inch. In order to have real-size PostScript images, this parameter should be set to 1.7778 (which is 128/72). The default value is 1. .TP .I Tgif.IntrCheckInterval: NUMBER This specifies the number of objects drawn before tgif checks for interrupts. If this is set to be 0 or less, interrupt is not allowed. The default value is 10. .TP .I Tgif.TiledPageScaling: NUMBER This specifies the scaling value used when a multipage drawing in tiled page mode is printed. Since most PostScript printers do not use the full page as the drawing area, setting this number to 1 may get truncated output. The default value is 0.9. .TP .I Tgif.TGIFPATH: STRING This specifies the directory where the files, mentioned in the FILES section below, can be found. The TGIFPATH environment variable may override this option. The default value is specified by the compiler option TGIF_PATH. .TP .I Tgif.TGIFICON: STRING This specifies the name of the object file to be displayed when tgif is iconified. If it starts with a / character, absolute path is used; otherwise, the actual path of the icon file is $TGIFPATH/STRING where TGIFPATH is either defined using the X defaults or an environment variable. The default value is ``tgificon.obj''. .TP .I Tgif.StickyMenuSelection: [true,false] If set to ``true'', when patterns/linewidths/linestyles/... of objects are changed using a menu action, the corresponding pattern/linewidth/linestyle/... becomes the current selection. The default is true. .TP .I Tgif.PSBopHook: STRING If specified, the following PostScript line is added at the beginning of each page when printing to the printer or to a PS file, .PP .RS .RS userdict /STRING known { STRING } if .br .RE .RE .PP .RS This option should only be used if one is very familiar with PostScript. (Setting STRING to "tgif-bop-hook" is recommended since it would not have a name conflict with existing software, such as dvips(1).) .RE .TP .I Tgif.PSEopHook: STRING If specified, the following PostScript line is added at the end of each page when printing to the printer or to a PS file, .PP .RS .RS userdict /STRING known { STRING } if .br .RE .RE .PP .RS This option should only be used if one is very familiar with PostScript. (Setting STRING to "tgif-eop-hook" is recommended since it would not have a name conflict with existing software, such as dvips(1).) .RE .TP .I Tgif.MinimalEPS: [true,false] If set to ``false'', comments such as %%Pages, %%DocumentFonts, %%EndComments, %%BeginProlog, %%EndProlog, %%Page, %%Trailer, and %%EOF will be generated in an EPS output. These comments may confuse certain ``document managers''. Therefore, the default is true if Tgif.UsePsAdobeString is not specified (and the default is false if Tgif.UsePsAdobeString is specified). .TP .I Tgif.InitialPrintInColor: [true,false] If set to ``true'', color output (printing) mode is enabled on startup. Please note that in black and white PS/EPS/EPSI printing mode, the \fIwhite\fR color will be printed as black (only \fIbackground\fR will be printed as white). The default is true (except when the \fB-print\fR command line option is used). .TP .I Tgif.InitialShowGrid: [true,false] If set to ``false'', showing grid is disabled on startup. The default is true. .TP .I Tgif.InitialSnapOn: [true,false] If set to ``false'', snapping to the grid points is disabled on startup. The default is true. .TP .I Tgif.NoMenubar: [true,false] If set to ``true'', no menubar will be shown initially. The default is false. .TP .I Tgif.NoStatusWindow: [true,false] If set to ``true'', no Status Window will be shown initially. The default is false. .TP .I Tgif.ReverseMouseStatusButtons: [true,false] If set to ``true'', the left mouse status and the right mouse status are swapped. This should be used when a ``left-handed mouse'' is used. The default is false. .TP .I Tgif.MinimalMenubar: [true,false] If set to ``false'', the menu items in the Menubar Window will be the same as the main popup menu. This would take up much more space. If set to ``true'', the Page, PageLayout, HoriAlign, VertAlign, and MoveMode menus are collapsed into the View cascading menu; the Font, TextStyle, and TextSize menus are collapsed into the Text cascading menu; and the LineDash, LineStyle, LineType, LineWidth, Fill, and Pen menus are collapsed into the Graphics cascading menu. The default is true. .TP .I Tgif.ColorBgInPrintingColorPS: [true,false] If set to ``true'', the window background color is used as the background color when generating color PostScript output. If set to ``false'', no background color is used. The default is false. .TP .I Tgif.ScrollBarWidth: NUMBER This specifies the width of a scroll bar. NUMBER must be between 2 and 16. The default is 16. .TP .I Tgif.InitialPaperSize: STRING The STRING specifies the initial width and height of the paper. STRING is in the "<width> x <height>" form. <width> and <height> is a numeric value immediately followed by either "in" (inch) or "cm" (centi-meter). The " x " that separate the <width> and <height> is mandatory. If A4PAPER is defined in the Makefile, the default value is "21cm x 29.7cm". If A4PAPER is not defined in the Makefile, the default value is "8.5in x 11in". .TP .I Tgif.UpdateChildUsingAlignment: [true,false,no_overlap] If set to ``true'' or 'no_overlap', when update_eps_child(), update_xbm_child(), or update_xpm_child() internal command is executed, the current horizontal and vertical alignments are used to place the EPS/XBM/XPM subobject. If the horizontal alignment is L, C, R, S, or -, the subobject is aligned to the left, center, right, center, or left, respectively, to the parent object. If the vertical alignment is T, M, B, S, or -, the subobject is placed above, middle, below, middle, or below the parent object if this X default is set to 'no_overlap'; the subobject is aligned to the top, middle, bottom, middle, or below the parent object if this X default is set to ``true''. If this X default is set to ``false'', the subobject is placed left aligned and below the parent object. The default is false. .TP .I Tgif.GenerateImageMap: [true,false] If set to ``true'', NCSA \fIimagemap\fR or CERN \fIClickable Image\fR files will be generated when print in GIF format. In this case, Tgif.XpmToGif, Tgif.ImageMapFileExtension, Tgif.GifFileExtension, Tgif.ImageMapFileFormat, and Tgif.UseXPmVersion1ForImageMap X defaults, described below, will be interpreted; otherwise, they are ignored. Please see the section on GENERATING IMAGEMAP FILES for details. The default is false. .TP .I Tgif.XpmToGif: STRING The STRING specifies a command used to convert an XPM file to a GIF file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the XPM file. The default is "xpmtoppm %s | ppmtogif". .TP .I Tgif.ImageMapFileExtension: STRING The STRING specifies the file extension for a imagemap file. The default is "map". .TP .I Tgif.GifFileExtension: STRING The STRING specifies the file extension for a GIF file. The default is "gif" (lower case). .TP .I Tgif.ImageMapFileFormat: [NCSA,CERN] The STRING specifies either the NCSA imagemap or the CERN clickable image format. The default is NCSA for the NCSA imagemap format. .TP .I Tgif.UseXPmVersion1ForImageMap: [true,false] The setting of this X default should depend on the setting of the Tgif.XpmToGif X default above. If set to ``true'', XPM1 file is generated regardless of the setting of the Tgif.XPmOutputVersion X default. The default is true. .TP .I Tgif.UsePaperSizeStoredInFile: [true,false] If set to ``true'', the paper size information stored in a just opened file is used. The default is true. .TP .I Tgif.OneMotionSelMove: [true,false] If set to ``true'', one can select and move an object in one motion. The default is false. .TP .I Tgif.TiffEPSI: (obsolete) This X default became obsolete because TiffEPSI became a supported export format since tgif-4.0. .TP .I Tgif.XbmToTiff: STRING The STRING specifies a command used to convert an XBM file to a TIFF file. The STRING \fImust\fR contain either one or two \fI%s\fR substring. The first \fI%s\fR substring is to be replaced by the full path name of the XBM file. The optional second \fI%s\fR substring is to be replaced by the full path name of the generated TIFF image. The default is "xbmtopbm %s | pnmtotiff -none > %s". .TP .I Tgif.EPSIExportExtension: STRING STRING specifies the file extension used for exporting \fIEPSI\fR files. The default is "eps". .TP .I Tgif.HotListFileName: STRING STRING specifies a full path name of a file used to store the hot file list. By default, this file is .Tgif_hotlist in the user's home directory. .TP .I Tgif.@@@Viewer: STRING STRING specifies an external viewer for an remote URL with a file extension of @@@. STRING can be in 3 forms. It can be the string "NONE" to indicate that when such a remote file is encountered, tgif should retrieve the file into a user specified directory. For example, if one wishes to retrieve .gz files, one can use: .PP .RS .RS Tgif.gzViewer: NONE .br .RE .RE .PP .RS STRING can also contain the string %S (S is capitalized), this indicates that %S is to be replaced by the URL. For example, if one wishes to view .html files using xmosaic, one can use: .RE .PP .RS .RS Tgif.htmlViewer: xmosaic %S .br .RE .RE .PP .RS Another form of STRING contains the string %s (S is lower-case), this indicates that the remote file is to be retrieved into a user specified directory and view by a tool. For example, if one wishes to view .gif files using xv, one can use: .RE .PP .RS .RS Tgif.gifViewer: xv %s .br .RE .RE .PP .RS Please note that this mechanism has precedence over the mechanism described in the MIME TYPES AND MAILCAPS section above. .RE .TP .I Tgif.AutoHyperSpaceOnRemote: [true,false] If set to ``false'', tgif will not go into the \fIhyperspace\fR mode when a remote URL is visited. The default is true. .TP .I Tgif.AllowLaunchInHyperSpace: [true,false] If set to ``true'', launching of applications is enabled in the \fIhyperspace\fR mode when a remote URL is visited. This is potentially very dangerous because the application may do catastrophic damages. Therefore, it is strongly recommended that it is set to false. The default is false. .TP .I Tgif.CanChangeAttrColor: [true,false] If set to ``true'', color of an attribute can be changed when it is attached to an object. The default is false. .TP .I Tgif.MimeTypesFile: STRING STRING specifies a full path name of the MIME-types file. Tgif only uses the type/subtype field in the MIME-types file and ignores all other fields. The default MIME-types file is \fI.mime.types\fR in user's home directory. .TP .I Tgif.LocalRGBTxt: STRING If one would like to override certain system colors, one can use STRING to specify a full path name of a file to be consulted first before looking up the color in the server. The file must be in the same format as the \fIrgb.txt\fR file. Namely, each line contains 4 fields, the first 3 fields correspond to the red, green, and blue components of the color, and the 4th field is the name of the color. A color component must have a value between 0 and 255 (inclusive). .TP .I Tgif.PrintUsingRequestedColor: [true,false] If set to ``true'', the color PostScript file being printed will use the \fIrequested\fR color instead of the color returned by the X server. The default is false. .TP .I Tgif.ShowMeasurement: [true,false] If set to ``true'', the location of the cursor and the width and height of the object being drawn/dragged/stretched will be shown. The default is false. .TP .I Tgif.ShowMeasurementUnit: STRING The STRING specifies the unit used to display the measurement cursor. There are 2 basic formats. One is just the word "pixel", "inch", or "cm". There are also known as basic units. Another format is NUM BASIC-UNIT/NEW-UNIT, where NUM is a numeric value, BASIC-UNIT is one of the basic units, and NEW-UNIT is any string. For example, "0.1 cm/mm" means that the new display unit is "mm" and 1 "mm" is 0.1 cm. "50 pixel/cm" is identical to "1 cm/cm" and "128 pixel/inch" is identical to "1 inch/inch". The default is pixel. .TP .I Tgif.PageStyleLandscape: [true,false] If set to ``true'', tgif comes up in landscape mode. The default is false. .TP .I Tgif.QueryZoomInPoint: [true,false] or [always,no_select,no_query,never] If set to ``true'' (or ``always''), the user will be asked to select a center point when zooming in. If set to ``no_select'', the user will be asked to select a center point when zooming in if no objects are selected. If set to ``no_query'', the position of the mouse is the zoom-in point. In this case, it is not desirable to zooms in using a menu selection. The default is false (or never). .TP .I Tgif.GZipCmd: STRING The STRING specifies a command used to gzip a .obj file. The command \fImust\fR produce output into its stdout. If the command contains a \fI%s\fR substring, the \fI%s\fR will be replace by the full path name of a temporary copy of the .obj file. The default is "gzip -c". .TP .I Tgif.GUnZipCmd: STRING The STRING specifies a command used to unzip a zipped tgif file (with extension .obj.gz or .sym.gz) into a tgif file. The command \fImust\fR produce output into its stdout. If the command contains a \fI%s\fR substring, the \fI%s\fR will be replace by the full path name of a temporary copy of the zipped file. The default is "gunzip -c". .TP .I Tgif.HttpProxy: STRING The STRING specifies a host name and a port number of an HTTP proxy server. Format of the specification is \fI<host>:<port>\fR. If \fI:<port>\fR is omitted, 80 is used as the default port number. The environment variable \fIhttp_proxy\fR has precedence over this X default. The default is not to use an HTTP proxy server. .TP .I Tgif.FtpProxy: STRING The STRING specifies a host name and a port number of an FTP proxy server. Format of the specification is \fI<host>:<port>\fR. If \fI:<port>\fR is omitted, 21 is used as the default port number. The environment variable \fIftp_proxy\fR has precedence over this X default. The default is not to use an FTP proxy server. .TP .I Tgif.InitialArrowStyle: [NONE,RIGHT,LEFT,DOUBLE] This specifies the initial arrow style for polyline/open-splines/arcs. The default is RIGHT. .TP .I Tgif.ShowPageInEPS: [true,false] If set to ``true'', a \fIshowpage\fR PostScript command will be generated for an EPS or EPSI file. The default is true. .TP .I Tgif.MaxNavigateCacheBuffers: NUMBER This specifies the number of cache buffers allocated to cache remote files (to minimize communication). NUMBER must be non-negative. The default is 40. .TP .I Tgif.NumberFileInPrintOnePage: [true,false] If set to ``true'', when PrintOnePage from the Print Menu is selected for a stacked multipage drawing (e.g., file.obj), file_\fIN\fR with the proper file extension will be generated, where \fIN\fR corresponds to the selected page number. The default is false. .TP .I Tgif.OneMotionTimeout: NUMBER When Tgif.OneMotionSelMove is set to true, moving an object is considered to be making a selection if the elapse time between mouse-down and mouse-up is smaller than the timeout value specified by this X default (in milliseconds). The default is 200. .TP .I Tgif.MinMoveInterval: NUMBER When Tgif.OneMotionSelMove is set to false, moving an object is considered to be making a selection if the elapse time between mouse-down and mouse-up is smaller than the interval specified by this X default (in milliseconds). The default is 0. .TP .I Tgif.GifToXpm: STRING The STRING specifies a command used to convert a GIF file to an XPM file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the GIF file. The default is "giftopnm %s | ppmtoxpm". .TP .I Tgif.InitExportPixelTrim: LEFT_NUMBER,TOP_NUMBER,RIGHT_NUMBER,BOTTOM_NUMBER The numbers specify the number of pixels to trim when printing or exporting in the XBM, XPM, or GIF format. The use of these values forms an escape mechanism to fix an idiosyncrasy that tgif can not figure out exactly how big the whole image is. The default values are all 0's. .TP .I Tgif.QuantizingLevels: NUMBER Some image functions such as Sharpen() uses convolution and may generate an image that uses more than 256 colors which tgif can not handle. The NUMBER specifies the number of colors to quantize down to when such a situation occurs. The default is 222. .TP .I Tgif.RotateCursor: [x_cursor,arrow,...] This specifies the cursor used in the rotate mode. Entries in <X11/cursorfont.h> (without the XC_ prefix) are valid names of the cursor. The default is crosshair. .TP .I Tgif.ColorLayers: [true,false] If set to ``true'', each color is considered to be a different layer which can be individually turned on and off. If a color layer is turned off, primitive objects in that layer will not be visible. A grouped object only becomes invisible when all its constituent objects are invisible. The default is false. .TP .I Tgif.TiffToXbm: STRING The STRING specifies a command used to convert a TIFF file to an XBM file. This command is used when importing an EPSI file generated by a Windows application. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the TIFF file. The default is "tifftopnm %s | pgmtopbm | pbmtoxbm". .TP .I Tgif.DefFixedWidthFont: STRING The STRING specifies a font to be used as the default font for the Status Window, menus, dialogboxes, etc. The default is "-*-courier-medium-r-normal-*-14-*-*-*-*-*-iso8859-1". .TP .I Tgif.DefFixedWidthRulerFont: STRING The STRING specifies a font to be used in the horizontal and vertical ruler windows. The default is "-*-courier-medium-r-normal-*-10-*-*-*-*-*-iso8859-1". .TP .I Tgif.MenuFont: STRING The STRING specifies a font to be used in menus. If this X default is not specified, the default font is used in menus. .TP .I Tgif.BoldMsgFont: STRING The STRING specifies a bold font to be used in buttons and dialogboxes. If this X default is not specified but Tgif.MenuFont is specified, this will take on the value of Tgif.MenuFont. If this X default and Tgif.MenuFont are not specified, the default font is used in bold messages. .TP .I Tgif.MsgFont: STRING The STRING specifies a thin font to be used in the Status Window and dialogboxes. If this X default is not specified, the default font is used in messages. .TP .I Tgif.BggenToXpm: STRING The STRING specifies a command for generating an X11 pixmap file to be executed when RunBggen() is selected from the ImageProc Menu. The STRING \fImust\fR contain two \fI%s\fR substrings. The first \fI%s\fR is to be replaced by a user specified string. The second \fI%s\fR is to be replaced by the geometry of the image. The default is "bggen %s -g %s | ppmquant 64 | ppmtoxpm". Please note that bggen(1) is part of the xv(1) package. .TP .I Tgif.BggenToPpm6: STRING The STRING specifies a command for generating a PPM file to be executed when RunBggen() is selected from the ImageProc Menu. The STRING \fImust\fR contain two \fI%s\fR substrings. The first \fI%s\fR is to be replaced by a user specified string. The second \fI%s\fR is to be replaced by the geometry of the image. The default is "bggen %s -g %s". Please note that bggen(1) is part of the xv(1) package. .TP .I Tgif.LittleEndianPpm6: [true,false] If set to ``true'', when reading a PPM (or PGM) file that uses a maxval of 65535, little endian format will be assumed (the standard for such a format calls for the big endian format). The default is false. .TP .I Tgif.DefaultErrorDiffuseLevels: R_NUMBER G_NUMBER B_NUMBER The NUMBERs specify the number of bits of red, green, and blue to be used when ReduceToDefaultColors() or DefaultErrorDiffuse() are selected from the ImageProc Menu. These values determine a set of default colors to be used for color quantization for the ReduceToDefaultColors() and DefaultErrorDiffuse() methods. R_NUMBER+G_NUMBER+B_NUMBER must be less than or equal to 8, and each number must be greater than 0. The default is 2 2 2. .TP .I Tgif.MaxImportFilters: NUMBER This specifies the maximum number of import filters. ImportFilter0 through ImportFilterMax, where Max is NUMBER-1, in X defaults are queried. The default is 0. .TP .I Tgif.ImportFilter#: FILTERSTRING This specifies an import filter. FILTERSTRING has 3 parts (separated by space characters). The first part is the name of the filter. It must not contain a space character. The second part contains semicolon-separated file extensions. The third part is the actual filter command for converting the named external file type to an X11 pixmap file. Please see the IMPORT RASTER GRAPHICS section for details. .TP .I Tgif.ShowFileNameOnBrowse: [true,false] If set to ``true'', file names will be shown when BrowseXBitmap(), BrowseXPixmap(), or BrowseOther() are selected from the File Menu. The default is true. .TP .I Tgif.HtmlFileExtension: STRING The STRING specifies the file extension used when printing in the HTML format. The default is "html". .TP .I Tgif.GenerateHtmlHref: [true,false] If set to ``true'' and when printing in the HTML format, the value of an \fIhref\fR attribute is parsed. If the value references a .obj file, it's changed to have a HTML file extension. If it is set to ``false'', no conversion will be performed. The default is true. .TP .I Tgif.RotationIncrement: NUMBER This specifies the initial rotation increment in degrees. The default is 45. .TP .I Tgif.PSA4PaperSize: [true,false] If set to ``true'' and A4 size paper is specified, the following line is added to a PS/EPS/EPSI file (before "%%EndComments"): .PP .RS .RS %%DocumentPaperSizes: a4 .br .RE .RE .PP .RS The default is false. .RE .TP .I Tgif.ShapeShadowSpec: STRING The STRING specifies the initial horizontal and vertical offsets of a shape shadow. If both values are zeroes, a shape is created without a shadow. When creating a shape with a shadow, background fill pattern (3rd pattern in the first column of the Fill Menu) usually gives the best result. The default is "0,0". .TP .I Tgif.StretchableText: [true,false] If set to ``true'', stretchable text mode is the initial mode. The default is true. .TP .I Tgif.EditTextSize: NUMBER This specifies the text size to be used in editing existing text objects. NUMBER should either be 0 or a value between 4 and 34 (inclusive). If NUMBER is 0, the actual text size is used in editing existing text objects. The value of the edit text size can later be changed by selecting SetEditTextSize() from the Properties Menu. The default is 0. .TP .I Tgif.IconPixmap: (obsolete) This X default became obsolete in tgif-4.2 because it clashes with the Xtoolket. It's renamed to Tgif.WMIconPixmap. .TP .I Tgif.WMIconPixmap: STRING STRING specifies the path of an XBM or XPM file to be used as tgif's desktop icon. If STRING starts with a / character, absolute path is used; otherwise, the actual path of the icon file is $TGIFPATH/STRING where TGIFPATH is either defined using the X defaults or an environment variable. This X default is only enabled if Tgif.UseWMIcon is set to true. The default value is ``tgificon.xbm'' (which is compiled into tgif). .TP .I Tgif.TmpFileMode: NUMBER (OCTAL) This specifies file mode for temporary and exported files. NUMBER must be an octal number. If NUMBER is 0, no attempt is made to change the file mode. If this value is specified (even if it's 0), it overrides the PSFILE_MOD compile option. There is no default value. .TP .I Tgif.TitledPinnedMenu: [true,false] If set to ``true'', pinned menu will have a title bar and left button is used for selecting menu items in a pinned menu. The default is true. .TP .I Tgif.ColorFromXPixmap: STRING STRING specifies the path of an XPM file to be used to load the initial colors. If this X default is specified, the Tgif.Color# X defaults are ignored but Tgif.AdditionalColors X default can be used to specify additional colors when tgif starts up. .TP .I Tgif.VectorWarpSoftness: NUMBER This specifies the softness value used when VectorWarp() is selected from the ImageProc Menu. VectorWarp() lets the user warp pixels in an X11 pixmap object by specifying a vector. The size of the affected area is controlled by this value, which must lie between 1.0 and 4.0. The larger the value, the larger the affected area. The default value is 2.0. .TP .I Tgif.ChangePropertiesOfAttrs: [true,false] If set to ``true'', changing a property (such as font, font size, color, etc.) of an object will change the property of the attributes attached to the object in the same way. The default is false. .TP .I Tgif.ShiftForDiagMouseMove: [true,false] If set to ``true'', certain mouse movements are restricted to multiple of 45 degrees. The default is true. .TP .I Tgif.UseRecentForDiagMouseMove: [true,false] If set to ``true'', the object that is used as anchor for measuring the moving distance is used as an anchor when objects. This only works if Tgif.UseRecentDupDistance and Tgif.ShiftForDiagMouseMove are both set to true, The default is false. .TP .I Tgif.FlushColormapOnOpen: [true,false] If set to ``true'', colormap is flushed and the initial tgif colors are reloaded when a new file is opened. The default is false. .TP .I Tgif.TransparentPattern: [true,false] If set to ``true'', fill and pen patterns are transparent initially. The default is false. .TP .I Tgif.DontReencode: STRING For fonts that are not iso8859-1 encoded, non-ASCII portion of the font (characters with bit 7 on) is by default reencoded as if it were iso8859-1 encoded. If this is not desirable for a font, reencoding can be bypassed by including the first part of the PostScript font name of the font in STRING. Fields in STRING are colon-separated. For example, if STRING is "Times:Courier:Helvetica", PostScript fonts that begins with "Times", "Courier", or "Helvetica" will not be reencoded. (Please note that this X default overwrite the fonts specified by -D_DONT_REENCODE at compile time.) Please also see the POSTSCRIPT CHARACTER ENCODING FOR INTERNATINOAL CHARACTERS section for an example. .TP .I Tgif.AdditionalDontReencode: STRING Use this X default to augment Tgif.DontReencode (or the fonts specified by -D_DONT_REENCODE at compile time). STRING here is basically concatenated to the STRING specified by Tgif.DontReencode (or the fonts specified by -D_DONT_REENCODE at compile time). .TP .I Tgif.UnsignedInXBmExport: [true,false] If set to ``true'', \fIunsigned char\fR will be used instead of \fIchar\fR in exported XBM files. The default is false. .TP .I Tgif.CommentInBitmapExport: [true,false] If set to ``true'', a blank \fIRCS Header\fR comment will be prepended to exported XBM and XPM files. The default is false. .TP .I Tgif.ShowFontSizeInPoints: [true,false] If set to ``true'', font sizes are displayed in the unit of point sizes. The default is false. .TP .I Tgif.DontCondensePSFile: [true,false] By default, PS/EPS files generated by tgif are not condensed. If this X default is set to ``false'', tgif will generate condensed PS/EPS files. The default is true. .TP .I Tgif.StripCondensedPSComments: (obsolete) This X default became obsolete in tgif-4.0.11 because it turns out that it's not always okay to strip PS comments (it should always be set to false). .TP .I Tgif.PdfFileExtension: STRING The STRING specifies the file extension used when printing in the PDF format. The default is "pdf". .TP .I Tgif.PsToPdf: STRING The STRING specifies a command used to convert a PS file to a PDF file. The STRING \fImust\fR contain 2 \fI%s\fR substrings to be replaced by the full path name of the PS file and the full path name of the PDF file. The default is: .PP .RS .RS ps2pdf "%s" "%s" .br .RE .RE .PP .RS (If you like to use "epstopdf", you can try setting this to "epstopdf %s --outfile=%s".) .RE .TP .I Tgif.EpsToTmpSvg: STRING Converting an EPS file to an SVG file is done in two steps. First the EPS file is converted to a temporary file and then the temporary file is converted to an SVG file. By default, the uniconvertor(1) format is used for the temporary file. The STRING here specifies a command for the first part and it \fImust\fR contain 2 \fI%s\fR substrings to be replaced by the full path name of the EPS file and the full path name of the temporary file. The default is: .PP .RS .RS pstoedit -dt -f sk "%s" "%s" .br .RE .RE .TP .I Tgif.TmpSvgToSvg: STRING This X default is to be used in conjunction with Tgif.EpsToTmpSvg above. The STRING here specifies a command for the second part of the conversion and it \fImust\fR contain 2 \fI%s\fR substrings to be replaced by the full path name of the temporary file and the full path name of the SVG file. The default is: .PP .RS .RS uniconvertor "%s" "%s" .br .RE .RE .TP .I Tgif.TmpSvgFileExtension: STRING The STRING specifies the file extension used for the intermediary file when converting an EPS to an SVG file. The default is "sk". .TP .I Tgif.3DLook: [true,false] If set to ``false'', no 3D decoration of windows and buttons will be used. The default is true. .TP .I Tgif.XpmDeckToGifAnim: STRING The STRING specifies a command used to convert a list of GIF file to a GIF animation file. The STRING \fImust not\fR contain any \fI%s\fR substring. The default is "gifsicle -lforever --delay 10". Gifsicle's home page is <URL:http://www.lcdf.org/gifsicle/>. One can also set this X default to "whirlgif -loop -time 10". Whirlgif's home page is <URL:http://www.msg.net/utility/whirlgif/>. .TP .I Tgif.GifAnimExplode: STRING The STRING specifies a command used to explode an animated GIF file into its constituent GIF files. The STRING \fImust not\fR contain any \fI%s\fR substring. The constituent GIF files must have the following file names. If the animated GIF file is named "foo.gif", the constituent GIF files must be named "foo.gif.0", "foo.gif.1", etc. The default is "gifsicle -eU". Gifsicle's home page is <URL:http://www.lcdf.org/gifsicle/>. .TP .I Tgif.Btn3PopupModeMenu: [true,false] If set to ``true'', pressing the right mouse button in the canvas window will generate the Mode Menu. The default is false. .TP .I Tgif.ScriptFraction: NUMBER This specifies the size of the super/subscript relative to the size of the normal text. The value must be between 0.2 and 0.8. The default value is 0.6. .TP .I Tgif.DeleteNextCharWithDelKey: [true,false] If set to ``true'', pressing the Delete key on the keyboard will delete the character to the right of the cursor in text mode. The default is true. .TP .I Tgif.SquareDoubleByteFonts: FONT_SPEC1 FONT_SPEC2 ... Starting with version 4.0 of tgif, double-byte fonts are supported. But only double-fonts where every character has the same width and height are supported. Please see the SQUARE DOUBLE FONTS section for details. .TP .I Tgif.DefaultSingleByteFont: STRING Using input methods (specified by the Tgif.DoubleByteInputMethod X default below), one can mix english (single-byte) substrings within a double-byte string. The font to use for the english substring is specified by this X default. The default is Times. .TP .I Tgif.@@@ShowFontChar: OCTAL STRING OCTAL STRING specifies a double-byte octal character to be used to represent a double-byte font in the Choice Window when the font is selected. @@@ should be replaced by the name of the double-byte font. Please see the SQUARE DOUBLE FONTS section for examples. .TP .I Tgif.@@@ConvFromUTF8: STRING The STRING specifies a command to be used to convert an UTF8 encoded string to a string to be pasted into a text object when the current font is a double-byte font whose name matches @@@. Please see the SQUARE DOUBLE FONTS section for examples. .TP .I Tgif.@@@ConvToUTF8: STRING The STRING specifies a command to be used to convert a selected string (whose font name matches @@@ and is a double-byte font) to be copied to the clipboard to a string in the UTF8 format. Please see the SQUARE DOUBLE FONTS section for examples. .TP .I Tgif.DoubleByteInputMethod: STRING This specifies the input method for double-byte fonts. Currently, the following values are supported: "xcin", "chinput", "kinput2", "xim", and "tgtwb5". If you are using xcin-2.5 or above, please use "xim" instead of "xcin". The "tgtwb5" input method is built into tgif and can take an optional parameter (by appending ",FONTNAME" after "tgtwb5") specifying a Big5 X font name to be used in selecting a character. If FONTNAME is not specified, "-taipei-fixed-medium-r-normal--16-150-75-75-c-160-big5-0" will be used. Please see the SQUARE DOUBLE BYTE FONTS section for details. .TP .I Tgif.UseNKF: [true,false] If set to ``true'', Network Kanji Filter (NKF) will be used. The default is false. .TP .I Tgif.CopyAndPasteJIS: [true,false] If set to ``true'', copying and pasting text strings will go through additional JIS to EUC conversion. The default is false. .TP .I Tgif.PreeditType: [overthespot,root] If set to ``overthespot'', over-the-spot preediting will be used. The default is root. .TP .I Tgif.Lang: STRING This specifies the locale. The environment variables LANG can override this setting. .TP .I Tgif.Modifiers: STRING This specifies the locale modifiers. The environment variables XMODIFIERS can override this setting. .TP .I Tgif.ConvSelection: STRING This specifies the name of the selection used in converting kinput2 strings. The default value is _JAPANESE_CONVERSION. .TP .I Tgif.VisibleGridInSlideShow: STRING If set to ``true'', grids will be visible in slideshow mode. The default is false. .TP .I Tgif.SmoothScrollingCanvas: [off,jump,smooth] If set to ``smooth'', scrolling the main canvas window will be smooth. However, there may be a delay when scrolling starts to cache the image. If set to ``jump'', scrolling the main canvas window will be jumpy. If set to ``off'', scrolling the main canvas window will not change the canvas until the mouse button is released. The default is jump. .TP .I Tgif.LightGrayColor: COLORSTRING This specifies the color to be used for the background of buttons, menus, etc. The default is gray75. .TP .I Tgif.DarkGrayColor: COLORSTRING This specifies the color to be used for the shadow of buttons, menus, etc. The default is gray50. .TP .I Tgif.DefaultObjectBackground: COLORSTRING This specifies the color to be used for the background of objects. By default, the default background color is used. .TP .I Tgif.UseImagePixelsForTrueColorExport: [true,false] If set to ``true'', the color table of an exported XPM/GIF file will be obtained from the actual image pixels for a TrueColor visual. The default is false. .TP .I Tgif.DialogboxUse3DBorder: [true,false] If set to ``false'', dialogboxes will not have 3D borders. This should be used with X servers such as X-Win32 because dialogboxes already have 3D borders. The default is true. .TP .I Tgif.MenuFontSet: STRING This X default is only used if tgif is compiled with the ENABLE_NLS compiler option. The STRING specifies a list of fonts to be used in menus. STRING can be ``none'' to indicate not to use menu font set. The default is "-*-helvetica-medium-r-normal--12-*-*-*-*-*-*-*,-*-*-medium-r-*--12-*-*-*-*-*-*-*". .TP .I Tgif.MsgFontSet: STRING This X default is only used if tgif is compiled with the ENABLE_NLS compiler option. The STRING specifies a list of fonts to be used in status messages. STRING can be ``none'' to indicate not to use message font set. The default is "-*-helvetica-medium-r-normal--12-*-*-*-*-*-*-*,-*-*-medium-r-*--12-*-*-*-*-*-*-*". .TP .I Tgif.BoldMsgFontSet: STRING This X default is only used if tgif is compiled with the ENABLE_NLS compiler option. The STRING specifies a list of fonts to be used in messageboxes. STRING can be ``none'' to indicate not to use bold message font set. The default is "-*-helvetica-bold-r-normal--12-*-*-*-*-*-*-*,-*-*-medium-r-*--12-*-*-*-*-*-*-*". .TP .I Tgif.BoldMsgFontDoubleByte: [true,false] This X default is only used if tgif is compiled with the ENABLE_NLS compiler option. This X default should be set to ``true'' if the strings used in messageboxes may contain double-byte characters. The default is false. .TP .I Tgif.LocaleDir: STRING This X default is only used if tgif is compiled with the ENABLE_NLS compiler option. The STRING specifies a full path name of a locale directory. .TP .I Tgif.PsRegMarksInTiledPageMode: [true,false] If set to ``true'', small crosshairs will be drawn at the corners defining the clipping regions when printing/exporting PS/EPS files in the tiled page mode. The greyness of the cross hairs will be determined by the Tgif.PsRegMarksGray X default. The default is false. .TP .I Tgif.PsRegMarksGray: NUMBER This specifies the greyness of the crosshairs used when Tgif.PsRegMarksInTiledPageMode is set to true. The default value is 0.95 .TP .I Tgif.PSFontAliases: PSFONTALIAS_SPEC1 PSFONTALIAS_SPEC2 ... Font aliases can be used to represent different encoding, etc. Please see the POSTSCRIPT CHARACTER ENCODING FOR INTERNATINOAL CHARACTERS section for details. .TP .I Tgif.DomainInIni: [true,false] If set to ``true'', domain information will be loaded from the ~/.Tgif/domain.ini file and all the menu items in the Domain submenu of the File Menu will be enabled. The default is false. .TP .I Tgif.UndoRedoRestoreDrawingMode: [true,false] If set to ``true'', the drawing mode just before an undo/redo operation will be restored after undo/redo. The default is true. .TP .I Tgif.MenuRowsBeforeScroll: NUMBER This specifies the maximum number of rows in a user-specifiable text menu (such as the Font Menu and the FontSize Menu) before a vertical scrollbar is automatically used. The default value is 20. .TP .I Tgif.MenuColsBeforeScroll: NUMBER This specifies the maximum number of rows in a user-specifiable bitmap menu (such as the Color Menu) before a horizontal scrollbar is automatically used. The default value is 26. .TP .I Tgif.PngToXpm: STRING The STRING specifies a command used to convert a PNG file to an XPM file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the PNG file. The default is "pngtopnm %s | pnmdepth 255 | ppmquant 222 | ppmtoxpm". .TP .I Tgif.JpegToXpm: STRING The STRING specifies a command used to convert a JPEG file to an XPM file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the JPEG file. The default is "djpeg -gif -color 222 %s | giftopnm | ppmtoxpm". .TP .I Tgif.PbmToXbm: STRING The STRING specifies a command used to convert a PBM file to an XBM file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the PBM file. The default is "pbmtoxbm %s". .TP .I Tgif.PgmToXpm: STRING The STRING specifies a command used to convert a PGM file to an XPM file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the PGM file. The default is "ppmtoxpm %s". .TP .I Tgif.PpmToXpm: STRING The STRING specifies a command used to convert a PPM file to an XPM file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the PPM file. The default is "ppmquant 222 %s | ppmtoxpm". .TP .I Tgif.XpmToPng: STRING The STRING specifies a command used to convert an XPM file to a PNG file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the XPM file. The default is "xpmtoppm %s | pnmtopng". .TP .I Tgif.PngFileExtension: STRING The STRING specifies the file extension for a PNG file. The default is "png" (lower case). .TP .I Tgif.XpmToJpeg: STRING The STRING specifies a command used to convert an XPM file to a JPEG file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the XPM file. The default is "xpmtoppm %s | cjpeg". .TP .I Tgif.PpmToGif: STRING The STRING specifies a command used to convert a PPM file to a GIF file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the PPM file. The default is "ppmquant 222 %s | ppmtogif". .TP .I Tgif.PpmToPng: STRING The STRING specifies a command used to convert a PPM file to a PNG file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the PPM file. The default is "pnmtopng %s". .TP .I Tgif.PpmToJpeg: STRING The STRING specifies a command used to convert a PPM file to a JPEG file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the PPM file. The default is "cjpeg %s". .TP .I Tgif.Ppm6ToXpm3: STRING The STRING specifies a command used to convert a PPM (P6) file to a version 3 XPM file. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the PPM file. The default is "ppmtoxpm %s". .TP .I Tgif.PpmQuantize: STRING The STRING specifies a command used to quantize the colors of a PPM file down to a specified number. The STRING \fImust\fR contain (1) a \fI%d\fR substring to be replaced by the number of colors to reduce to and (2) a \fI%s\fR substring to be replaced by the full path name of the PPM file. The default is "pnmquant %d %s". .TP .I Tgif.PpmFSQuantize: STRING The STRING specifies a command used to quantize the colors of a PPM file down to a specified number using the Floyd-Steinberg half-tone algorithm. The STRING \fImust\fR contain (1) a \fI%d\fR substring to be replaced by the number of colors to reduce to and (2) a \fI%s\fR substring to be replaced by the full path name of the PPM file. The default is "pnmquant -fs %d %s". .TP .I Tgif.JpegFileExtension: STRING The STRING specifies the file extension for a JPEG file. The default is "jpg" (lower case). .TP .I Tgif.ProducedBy: STRING When printing/exporting PS/EPS files, STRING will appear in a %%ProducedBy line in a exported PS/EPS file. Please include your name and e-mail address in STRING. The default is "(unknown)". .TP .I Tgif.Editor: STRING STRING specifies a text editor to use for editing attributes. The STRING \fImust\fR contain two \fI%s\fR substrings to be replaced by the window title and the full path name of the text file. For example, you can use "xemacs -title '%s' '%s'". The default is "xterm -title '%s' -e vi '%s'". .TP .I Tgif.GoHyperSpaceInSlideShow: [true,false] If set to ``true'', \fIhyperspace\fR mode will be entered when tgif enters the slideshow mode. The default is false. .TP .I Tgif.LineWidthIndexInSlideShow: NUMBER This specifies the line width \fIindex\fR to use when tgif is in the slideshow mode. The default value is 4. .TP .I Tgif.MaxRecentFiles: NUMBER This specifies the maximum number of files to remember in the recently used file list. The default value is 10. .TP .I Tgif.ResetOriginOnAdvancePage: [true,false] If set to ``true'', tgif will scroll to the left-top corner of the page when pages are advanced. The default is false. .TP .I Tgif.UseMeasureTooltip: [true,false] If set to ``true'', the location of the cursor and the width and height of the object being drawn/dragged/stretched will be shown in a tooltip window. This X default only takes effect if Tgif.ShowMeasurement is true. The default is false. .TP .I Tgif.MeasureTooltipXFollowMouse: [true,false] If set to ``true'', the X position of the measurement tooptip will follow the mouse. The default is false. .TP .I Tgif.MeasureTooltipYFollowMouse: [true,false] If set to ``true'', the Y position of the measurement tooptip will follow the mouse. The default is false. .TP .I Tgif.MeasureTooltipHorizontalPosition: [left,center,right] Fix the X position of the measurement tooltip to the left, center, or right. This X default only takes effect if Tgif.MeasureTooltipXFollowMouse is false. The default is left. .TP .I Tgif.MeasureTooltipVerticalPosition: [top,middle,bottom] Fix the Y position of the measurement tooltip to the top, middle, or bottom. This X default only takes effect if Tgif.MeasureTooltipYFollowMouse is false. The default is top. .TP .I Tgif.MeasureTooltipVerbose: [true,false] If set to ``true'', additional information about the positions and sizes of objects will be displayed in the tooltip window. The default is false. .TP .I Tgif.NoMinWinSize: [true,false] If set to ``false'', tgif will have a minimum window size so that the whole panel window is always visible. The problem with this setting is that some window manager will show the wrong window size when you resize the window. This setting is left for compatibility reasons. If set to ``true'', a side effect is that the menubar will no longer automatically wraps around when Tgif.MinimalMenubar is set to true. The default is true. .TP .I Tgif.AutoWrapMenubar: [true,false] If set to ``true'', the menubar will automatically wrap around. If Tgif.MinimalMenubar is set to false, menubar will always wrap around automatically. The default is false. .TP .I Tgif.AutoEPSPreviewBitmap: [true,false] If set to ``true'', when importing a PS/EPS file, tgif will automatically generate a preview bitmap if the file does not already contain one. The default is false. .TP .I Tgif.PsToXbm: STRING STRING specifies a command used to convert a PS file to a XBM file. The STRING \fImust\fR contain a single \fI%s\fR substrings to be replaced by the full path name of the PS file. Please note that the above command usually generates a bitmap that's much larger than image in the file. Tgif automatically trims out the blank space similar to the way pbmtoepsi works. The default is "gs -q -dNOPAUSE -sDEVICE=pbm -sOutputFile=- -- "%s" | pbmtoxbm". .TP .I Tgif.TmpDirInHomeDir: [true,false] If set to ``true'', tgif will use the $HOME/.Tgif directory as the temporary directory (unless the Tgif.TmpDir X default below is used) and the compiler option -DTMP_DIR is ignored. The default is false if the -D_TMP_DIR_IN_HOME_DIR compiler option is used. The default is true if the -D_TMP_DIR_IN_HOME_DIR compiler option is \fInot\fR used. .TP .I Tgif.TmpDir: STRING STRING specifies a directory to be used as the temporary directory. The use of this X default is discouraged, especially if tgif is compiled with -DUSE_XT_INITIALIZE and a X resource file found in the directory search path specified by the environment variable $XAPPLRESDIR is used. By default, tgif uses /tmp as the temporary directory. .TP .I Tgif.ThumbnailGeometry: WIDTHxHEIGHT This X default specifies the geometry of thumbnails. The default is 160x120. .TP .I Tgif.ThumbnailPadding: NUMBER This specifies the padding (in pixels) for thumbnail images. The default value is 8. .TP .I Tgif.ThumbnailXGap: NUMBER This specifies the horizontal gap (in pixels) for thumbnail images. The default value is 16. .TP .I Tgif.ThumbnailYGap: NUMBER This specifies the vertical gap (in pixels) for thumbnail images. The default value is 0. .TP .I Tgif.ThumbnailX: NUMBER This specifies the starting x location (in pixels) for thumbnail images. The default value is 32. .TP .I Tgif.ThumbnailY: NUMBER This specifies the starting y location (in pixels) for thumbnail images. The default value is 32. .TP .I Tgif.ShowWireSignalName: [true,false] If set to ``false'', when connecting ports, tgif will automatically place the signal name and hide it. Otherwise, the user will be prompted to place the signal name and it will be visible. The default is true. .TP .I Tgif.LandscapePdfSetPageDevice: (obsolete) This X default became obsolete in tgif-4.1.42 because the name is misleading. Please see Tgif.PdfSetPageDevice below. .TP .I Tgif.PdfSetPageDevice: [true,false] If set to ``true'', when exporting PDF (or PS) files, tgif will use PostScript "setpagedevice" command to specify the paper size in the generated PostScript file before calling ps2pdf(1) (if exporting in PDF format). This should not be necessary (and is considered a bug in ps2pdf). In the future, this X default can be used to turn off the generation of the "setpagedevice" command when ps2pdf can handle landscape PostScript files correctly. .TP .I Tgif.DeleteCmdAsCut: (obsolete) This X default became obsolete in tgif-4.2.3. Now <Cntrl>x binds to the Cut command. .I Tgif.EnableMouseWheel: [true,false] If set to ``false'', Button4 and Button5 mouse wheel scrolling events will be ignored. The default is true. .I Tgif.Btn2PopupMainMenu: [true,false] If set to ``false'', Button2 events will not bring up the Main Menu in the canvas window. The default is true. .TP .I Tgif.NoChoiceWindow: [true,false] If set to ``true'', no Choice and Message Windows will be shown initially. The default is false. .TP .I Tgif.UseXPmVersion1ForXPmDeck: [true,false] The setting of this X default should depend on the setting of the Tgif.XpmDeckToGifAnim X default above. If set to ``true'', XPM1 file is generated when a deck of X11 pixmap objects is being converted to a GIF animation file regardless of the setting of the Tgif.XPmOutputVersion X default. The default is true. .TP .I Tgif.SlideShowWindowOffsets: X_OFFSET,Y_OFFSET The numbers specify the number of pixels to adjust for the slideshow mode. If only one value is given, both X and Y offsets are set to the same value. The default values are all 0's. .TP .I Tgif.SlideShowBorderColor: COLORSTRING This specifies the color to be used for the area outside of the paper boundary in slideshow mode. By default, the color of the border is the same as the background color. .TP .I Tgif.ConvertToBezierSegments: NUMBER This specifies the number of segments used in converting a polyline/spline object to a Bezier curve. The default value is 50. .TP .I Tgif.TickMarkSize: NUMBER This specifies the size of a tick mark to be used when tick marks are added at a vertex of a polyline/polygon/spline. The default value is 8. .TP .I Tgif.NoModeWindow: [true,false] If set to ``true'', no Mode Window will be shown initially. The default is false. .TP .I Tgif.MakeUnsavableInSlideShow: [true,false] If set to ``true'', the current file will be made unsavable when slideshow mode is entered. (If the current file contains auto page numbering objects, the file will be made unsavable regardless of the setting of this X default.) The default is false. .TP .I Tgif.SingleByteInputMethod: STRING This specifies the input method for single-byte fonts. Currently, only "xim" is supported. .TP .I Tgif.IgnoreSlideShowOffsetsInFile: [true,false] If set to ``false'', the slideshow offsets stored in a file will override the Tgif.SlideShowWindowOffsets setting. The default is true. .TP .I Tgif.ItalicMsgFont: STRING The STRING specifies a italic font to be used in some buttons. If this X default is not specified but Tgif.MenuFont is specified, this will take on the value of Tgif.MenuFont. If this X default and Tgif.MenuFont are not specified, the default font is used in italic messages. .TP .I Tgif.ItalicMsgFontSet: STRING This X default is only used if tgif is compiled with the ENABLE_NLS compiler option. The STRING specifies a list of fonts to be used in messageboxes. STRING can be ``none'' to indicate not to use italic message font set. The default is "-*-helvetica-medium-o-normal--12-*-*-*-*-*-*-*,-*-*-medium-r-*--12-*-*-*-*-*-*-*". .TP .I Tgif.BoldItalicMsgFont: STRING The STRING specifies a bold italic font to be used in some text. If this X default is not specified but Tgif.MenuFont is specified, this will take on the value of Tgif.MenuFont. If this X default and Tgif.MenuFont are not specified, the default font is used in bold italic messages. .TP .I Tgif.BoldItalicMsgFontSet: STRING This X default is only used if tgif is compiled with the ENABLE_NLS compiler option. The STRING specifies a list of fonts to be used in some text. STRING can be ``none'' to indicate not to use bold italic message font set. The default is "-*-helvetica-bold-o-normal--12-*-*-*-*-*-*-*,-*-*-medium-r-*--12-*-*-*-*-*-*-*". .TP .I Tgif.ExternalPsToEpsi: [true,false] If set to ``true'', the execution of the pstoepsi() internal command will simply invoke pstoepsi externally. The default is false. .TP .I Tgif.GsPath: STRING The STRING specifies a full path name of the gs (ghostscript) program. The default is "gs" (which implies that the "gs" excutable is in your PATH). .TP .I Tgif.CompoundObjWithTextStretchableForPSE: [true,false] If set to ``false'', when executing the Precise Scale Everything command, a compound object will \fBnot\fR be stretched if it contains a text subobject. This X default only has effect if tgif is in the non-stretchable text mode. (If tgif is in the stretchable text mode, this X default is ignored.) The default is false. .TP .I Tgif.HideWindowsInSlideShow: [true,false] If set to ``false'', tgif will keep all windows visible in slideshow mode. Otherwise, only the canvas window will be visible in slideshow mode. The default is true. .TP .I Tgif.PSDistillerNoImageCompress: [true,false] If set to ``true'', tgif will generate PostScript code so that images in a generated PostScript file will \fInot\fR be compressed by a distiller program such as ps2pdf. The default is false. .TP .I Tgif.AdditionalPSSetup: STRING If specified, the PostScript line specified by STRING is inserted at the end of PostScript file setup (right before %%EndSetup). This option should only be used if one is very familiar with PostScript. Here is an example to ask distiller programs not to compress bitmap images: .PP .RS .RS Tgif.AdditionalPSSetup: \\n\\ .br systemdict /setdistillerparams known \\n\\ .br { << /AutoFilterGrayImages false \\n\\ .br /AutoFilterColorImages false \\n\\ .br /ColorImageFilter /FlateEncode \\n\\ .br /GrayImageFilter /FlateEncode \\n\\ .br >> setdistillerparams } if .br .RE .RE .PP .TP .I Tgif.PSFontNeedCharSubs: FONTSUB_SPEC1 FONTSUB_SPEC2 ... The format of FONTSUB_SPEC is FONTNAME=TOKENNAME where FONTNAME is the name of a PostScript font and TOKENNAME is the name of the extension for the Tgif.PSCharSubs_TOKENNAME X default. For PostScript font names that begins with a string that matches a FONTNAME part of a FONTSUB_SPEC, tgif will read the Tgif.PSCharSubs_TOKENNAME X default to determine which characters will be substituted. For fonts that are not iso8859-1 encoded, non-ASCII portion of the font (characters with bit 7 on) is by default reencoded as if it were iso8859-1 encoded when PS output is generated. If this is not desired, different named PS characters can be substituted for characters with bit 7 on. Please also see the POSTSCRIPT CHARACTER ENCODING FOR INTERNATINOAL CHARACTERS section for an example. .TP .I Tgif.PSCharSubs_TOKENNAME: PSCHARSUBS_SPEC1 PSCHARSUBS_SPEC2 ... TOKENNAME must match a FONTSUB_SPEC in the Tgif.PSFontNeedCharSubs X default. The format for PSCHARSUBS_SPEC is OLDCHARCODE/NEWCHARNAME where OLDCHARCODE is a character code in octal format and NEWCHARNAME is a PostScript character name to use. For more information, please see the POSTSCRIPT CHARACTER ENCODING FOR INTERNATINOAL CHARACTERS section. .TP .I Tgif.DrawTextFuncKey_F#: INTERNAL COMMAND LIST This specifies the correspondence between a function key and a list of internal commands. When function key F# is pressed when tgif is in the text drawing mode, the corresponding list of internal commands is executed. Tgif only recognizes function keys F1 through F12. .TP .I Tgif.PasteFromXSelectionOnly: [true,false] If set to ``false'', if tgif has failed to perform a paste via the X Selections mechanism, it will attempt the old style paste (directly fetch bytes from the X server). This is mainly used with an older X servers. The default is true. .TP .I Tgif.PasteFromSelectionTimeout: NUMBER This specifies the number of seconds for a paste operation to timeout. The default value is 10. .TP .I Tgif.LengthLimit256InInsertChar: [true,false] If set to ``true'', the maximum number of characters per line of text is set at 256. Additional characters are ignored. The default is false. .TP .I Tgif.JpegToPpm6: STRING The STRING specifies a command used to convert a JPEG file to a PPM file in the P6 format. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the JPEG file. The default is: .PP .RS .RS djpeg -ppm "%s" .br .RE .RE .TP .I Tgif.PngToPpm6: STRING The STRING specifies a command used to convert a PNG file to a PPM file in the P6 format. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the PNG file. The default is: .PP .RS .RS pngtopnm "%s" .br .RE .RE .TP .I Tgif.ObjectShadowOffsets: X_OFFSET,Y_OFFSET The numbers specify the number of pixels to be offseted when creating a generic object shadow. If only one value is given, both X and Y offsets are set to the same value. The default values are all 2's. .TP .I Tgif.ObjectShadowColor: COLORSTRING This specifies the color to be used for generic object shadow. The default value is "#c0c0c0". .TP .I Tgif.IgnoreObjectShadowInfoInFile: [true,false] If set to ``false'', the generic object shadow information stored in a file will override the Tgif.ObjectShadowOffsets and Tgif.ObjectShadowColor settings. The default is true. .TP .I Tgif.ReportMissingFonts: [true,false] If set to ``true'', when tgif starts, missing X fonts will be printed to the terminal. The default is false. .TP .I Tgif.CustomPatternDir: STRING STRING specifies a directory that contains custom fill and pen patterns. Any valid XBM file, encoding a bitmap of arbitrary dimensions, name \fBpat\fI#\fB.xbm (for 3<=\f#\fR<=31) in this directory will replace the corresponding default pattern \f#\fR. .TP .I Tgif.EnableTrueColorImages: [true,false] If set to ``true'', on a TrueColor display, PPM and JPEG objects will use 24-bit color. Tgif must be compiled with zlib support to enable this. The default is true. .TP .I Tgif.AutoRotatePivot: [true,false] If set to ``true'', user-specified rotation pivot will be disabled. The default is false. .TP .I Tgif.RightMargin: STRING The STRING specifies the right margin. The right margin must be specified with a unit (the choices are "pixel", "in", or "cm"). The default is "1 in" if Tgif.GridSystem is "English" and "2.5 cm" if Tgif.GridSystem is "Metric". .TP .I Tgif.EnableRightMargin: [true,false] If set to ``true'', a simple right-margin will be used when entering text. This is not a full-featured right-margin. It is only activated under the following conditions: text object is not transformed, text is left-justified, text cursor is not inside a superscript or a subscript, no zoome, and Tgif.EditTextSize is not used. The default is false. .TP .I Tgif.NoOrientationIfPdfSetPageDevice: [true,false] If set to ``true'', the "%%Orientation:" line is not generated in the PostScript file if "setpagedevice" is active when exporting a PS/EPS/PDF file. Please see Tgif.PdfSetPageDevice above. The default is false. .TP .I Tgif.PNGExportHasTransparentColor: [true,false] If set to ``true'', the color specified by the Tgif.PNGExportTransparentColor X default will be made transparent when printing in the PNG format. The default is false. .TP .I Tgif.PNGExportTransparentColor: COLORSTRING This specifies the color to be made transparent when printing in the PNG format. By default, the default background color is used. .TP .I Tgif.PpmToPngWithTransparentColor: STRING The STRING specifies a command used to convert a PPM file to a PNG file with a transparent color. The STRING \fImust\fR contain exactly two \fI%s\fR substring to be replaced by the transparent color and full path name of a PPM file. The default is "pnmtopng -transparent '%s' '%s'". .TP .I Tgif.EnableThresholdFloodReplaceColor: [true,false] If set to ``true'', threshold-based Flood Fill and Replace Color will be used. The default is false. .TP .I Tgif.FloodReplaceColorThreshold: RED_THRESH,GREEN_THRESH,BLUE_THRESH In threshold-based Flood Fill and Replace Color, after a pixel is selected, pixels that have colors similar to the selected pixel will also change color. The similarity is defined by these 3 threshold values. Each value must be between 0 and 255, inclusive. The default values are all 15's. .TP .I Tgif.UseStdPalette8: [true,false] If set to ``true'', a standard 8 palette will be used as the startup colors. These colors correspond to all 8 combination of 0x00 and 0xff in red, green, and blue color components. If this X default is used, the Tgif.AdditionalColors X default can be used to specify additional colors when tgif starts up. The default is false. .TP .I Tgif.UseStdPalette27: [true,false] If set to ``true'', a standard 27-color palette will be used as the startup colors. These colors correspond to all 27 combination of 0x00, 0x80, and 0xff in red, green, and blue color components. If this X default is used, the Tgif.AdditionalColors X default can be used to specify additional colors when tgif starts up. The default is false. .TP .I Tgif.UseStdPalette64: [true,false] If set to ``true'', a standard 64-color palette will be used as the startup colors. These colors correspond to all 64 combination of 0x00, 0x55, 0xaa, and 0xff in red, green, and blue color components. If this X default is used, the Tgif.AdditionalColors X default can be used to specify additional colors when tgif starts up. The default is false. .TP .I Tgif.UseStdPalette216: [true,false] If set to ``true'', a standard 216 palette will be used as the startup colors. These colors are known as Mobile Web-safe colors and they correspond to all 216 combination of 0x00, 0x33, 0x66, 0x99, 0xcc, and 0xff in red, green, and blue color components. If this X default is used, the Tgif.AdditionalColors X default can be used to specify additional colors when tgif starts up. The default is false. .TP .I Tgif.UseMobileWebSafePalette: [true,false] This is identical to Tgif.UseStdPalette216. .TP .I Tgif.UseOpenOfficeGalaxyPalette: [true,false] If set to ``true'', the OpenOffice Galaxy (53-color) palette will be used as the startup colors. If this X default is used, the Tgif.AdditionalColors X default can be used to specify additional colors when tgif starts up. The default is false. .TP .I Tgif.UseOpenOfficeGooglePalette: [true,false] If set to ``true'', the OpenOffice Google (80-color) palette will be used as the startup colors. If this X default is used, the Tgif.AdditionalColors X default can be used to specify additional colors when tgif starts up. The default is false. .TP .I Tgif.AdditionalColors: COLOR1, COLOR2 ... If any of the Tgif.ColorFromXPixmap, Tgif.UseStdPalette8, Tgif.UseStdPalette27, Tgif.UseStdPalette64, Tgif.UseStdPalette216, Tgif.UseMobileWebSafePalette, Tgif.UseOpenOfficeGalaxyPalette, or Tgif.UseOpenOfficeGooglePalette X defaults is used, additional startup colors can be specified using this X default. Since color names can contain space characters, the colors must be separated by commas. .TP .I Tgif.DefaultColor: COLORSTRING This specifies the default color if a certain color can not be found. It has precedence over the Tgif.DefaultColorIndex X default. If this X default is not specified, Tgif.DefaultColorIndex will determine the default color. .I Tgif.GifToPpm6: STRING The STRING specifies a command used to convert a GIF file to a PPM file in the P6 format. The STRING \fImust\fR contain a \fI%s\fR substring to be replaced by the full path name of the GIF file. The default is: .PP .RS .RS giftopnm "%s" .br .RE .RE .TP .\" .\" add new X defaults here .\" .SH ENVIRONMENT VARIABLE .\" .TP .I TGIFPATH This environment variable should be set such that the files, mentioned in the FILES section below, can be found. .TP .I TGIFICON This environment variable should be set to the name of the object file to be displayed when tgif is iconified. By default, it is set to ``tgificon''. If it starts with a / character, absolute path is used; otherwise, the icon file is assumed to be $TGIFPATH/$TGIFICON. .TP .I TGIF_[Domain] \fIObsoleted\fR. .\" .SH FILES .\" $TGIFPATH/tgificon.obj contains the default tgif icon. .br .PP $TGIFPATH/keys.obj contains a summary of the non-alphanumeric key bindings. .br .\" .SH PROLOG/C TESTDRIVE .\" In the tgif distribution, there are three Prolog files which illustrate a simple Prolog driver. \fItgif.pl\fR contains predicates for parsing tgif files (both .obj and .sym). \fIfrontend.pl\fR contains predicates for talking to Prolog engines, such as that of Quintus and SISCtus, through the foreign function interface. To use frontend.pl, \fIfrontend11.o\fR needs to be built (which requires the \fIfrontend11.o\fR entry to be uncommented from the makefiles). Finally, \fItestdrive.pl\fR contains a program which will print out the ID files of all objects in the current drawing, if tgif is escaped with the Solve() (or #s) command. This is also a good way of finding out the structure of a tgif file (especially because the structure is not documented due to the complexity introduced to keep tgif compatible with files created by older versions). .PP A very simple C driver, \fItestdrive.c\fR, is also provided with the tgif distribution which perform the same function as the Prolog driver. The extra code present in this file (and not present in tgif.c) is used to illustrate how the in-memory objects and attributes can be traversed and how new objects can be created and manipulated. .\" .SH SEE ALSO .\" \fBlatex\fR(1L), \fBlpr\fR(1), \fBghostscript\fR(1), \fBenv\fR(1), \fBX\fR(1), \fBdvips\fR(1), \fBcsh\fR(1), \fBpbmplus\fR(1), \fBnetpbm\fR(1), \fBdjpeg\fR(1), \fBbitmap\fR(1), \fBXPM\fR(1), \fBnetpbm\fR(1), \fBxfontsel\fR(1), \fBxlsfonts\fR(1), \fBxgrabsc\fR(1), \fBxloadimage\fR(1), \fBxsnap\fR(1), \fBsxpm\fR(1), \fBxv\fR(1), \fBpstoepsi\fR(1), \fBMosaic\fR(1), \fBbggen\fR(1), \fBrand\fR(3C), \fBps2pdf\fR(1) .\" .SH IDIOSYNCRASIES .\" When any of the ``escape to driver'' commands are (accidentally) executed, the current content of the drawing is saved into ``tmpmodel.obj'' if the drawing indicates that it is a .obj file; then tgif escapes to the driver and returns right away. If the drawing indicates that it is a .sym file, then the content is saved into ``tmpmodel.sym'', but tgif does not return to the driver. .PP The paste operation works on a cut buffer generated by tgif or by non-tgif tools (such as \fIxterm\fR). If the cut buffer is \fInot\fR generated by tgif, its content is treated as a collection of ASCII character strings, which is inserted into the current drawing as a text object (current settings for text objects are used to create the text object). If the cut buffer \fIis\fR generated by tgif, then all the current settings are ignored. .PP The font sizes are the \fIscreen\fR font sizes (which correspond to the X fonts that are used to draw the text on the screen). They appear smaller on the printout. When a 24 point text is printed, it would correspond to about a 13.5 point PostScript text. This is because tgif treats 128 pixels as an inch, and PostScript treats 72 points as an inch. .PP Because characters supported by X11 and PostScript are different, not all the characters, especially in the range 128 to 255 (or \\200 to \\377), which are supported by X11, but are not accepted by tgif. Furthermore, in order to print the supported subset of these characters, character codes must be re-encoded. Therefore, if one would like to hack tgif to support other personalized fonts, one should be careful about the re-encoding mechanism. .PP The grids are not absolute; they are specified as screen pixels, and they scale with the current zoom. For example, if the grid is set at 16 pixels at maximum zoom, and if the user zooms out once, objects can be drawn, moved, or stretched at 16 screen pixel increments, but this corresponds to 32 pixels in the real coordinate system. .PP If the vertical text spacing is set to negative values, highlighted text will look a little strange due to XOR operations. If the vertical text spacing is set to be greater than 100 or less than -100, the panel window will not be cleared properly; to clear the panel window, the user may have to close the tgif window and then open it again. .PP As described in the TGIF SUBWINDOWS section, in constrained move mode, if both endpoints of a not-selected polyline lie inside the object being moved, then the whole polyline is moved. This may look strange sometimes because, for example, if one starts with a line segment pointing to an object, just moving the object will cause the line segment to be ``stretched''; however, if one eventually moves the object so that the other endpoint is also inside the object, any future movement of the object will cause the whole line segment to move (instead of just moving the original endpoint). The moving of the vertex which is the neighbor of a moved endpoint may also look strange at times. At this point, one should switch to the unconstrained move mode. .PP Another idiosyncrasy with respect to the constrained move is that right after duplicating an object, the constrained move is disabled temporarily because it is assumed that at this point the user would want to move the new object to a desirable position, and only after this new object is ``settled down'', the constrained move will be re-enabled. Settling down is signified by doing something other than moving the new object. .PP Locked objects can be deleted. .PP Under the Edit Menu, PasteFromFile() reads a file into the drawing. Pasting from a file is different from the normal pasting operation where copying is performed in something like xterm because tabs are automatically converted to spaces. Tabs are ignored when pasting from a file. .PP When printing a multipage drawing, all pages (even the ones that contains no objects) will be printed. Using the PrintOnePage() command under the Page Menu one can print the selected page (in \fIstacked\fR page layout mode, this is the current page; in \fItiled\fR page layout mode, the user is prompted to select a visible page). .PP Tgif can be setup to use its own icon window (the Tgif.NoTgifIcon and the Tgif.UseWMIconPixmap X defaults must both be set to false). However, it may confuse certain window managers. So, if the effect is undesirable, one can set the Tgif.UseWMIconPixmap X defaults to true. .\" .SH BUGS .\" There seems to be a problem with printing Courier fonts with a non-solid pen on the Apple LaserWriter. (Printing single character does seem to work fine.) As pointed out by the PostScript reference manual, Courier is a ``stroked font'', and it is usually ``difficult'' to construct character paths for such types of fonts. However, Courier fonts work fine with ghostscript(1) and dxpsview. It's not clear how this problem can be fixed. The author recommends avoiding Courier fonts when printing in color if a non-solid pen is desired. .PP Arcs with arrow tips don't look very sharp (the tip is not pointed as in open-splines with arrow tips). .PP At high magnifications, \fIstretching\fR arcs may cause anomalous behavior due to round off errors. .PP When page reduction/magnification is not set at 100%, the markings in the Ruler Windows do not correspond to real measurements. .PP Copying/pasting large objects might not work because tgif does not use the ``selection'' mechanism (yet). .PP If and when tgif crashes, it will try to save the current content of the drawing in a file called ``EmergencySave.obj'' (or ``EmergencySave.sym'' if the current drawing specifies a symbol object). Often, the drawing can be restored by loading the ``EmergencySave.obj'' file. Nevertheless, if the cause of the crash is that some objects are corrupted (due to programming bugs), then the ``EmergencySave.obj'' file may also be corrupted. .PP When launching an application, if the command does not end with the '&' character and the command does not terminate, tgif also hangs. In this case, kill(1) should be used to send HUP signal to the tgif process if one wants to save the content of tgif in ``EmergencySave.obj''. .PP The file \fIexec.c\fR may not compile properly on AIX machines. One might have to add -D_BSD to the DEFINES in either the Imakefile or Makefile.noimake. .\" .SH COPYRIGHT .\" Please see the ``Copyright'' file for details on the copyrights. .PP \fIPostScript\fR is a trademark of Adobe Systems Incorporated. .\" .SH STATUS .\" The current status of tgif can be obtained from tgif's World-Wide-Web home page at <URL:http://bourbon.usc.edu/tgif/>. .\" .SH AUTHOR .\" William Chia-Wei Cheng (bill.cheng@acm.org) .br <URL:http://merlot.usc.edu/william/usc/> .SH REFERENCES .IP [1] ``\fIA Beginner's Guild to HTML\fR'', <URL:http://www.ncsa.uiuc.edu/General/Internet/WWW/HTMLPrimer.html>. .IP [2] ``\fICGI - Common Gateway Interface\fR'', <URL:http://www.w3.org/CGI/overview.html>. .IP [3] ``\fINCSA Imagemap\fR'', <URL:http://hoohoo.ncsa.uiuc.edu/docs/tutorials/imagemapping.html>. .IP [4] ``\fICERN Clickable Image\fR'', <URL:http://www.w3.org/hypertext/WWW/Daemon/User/CGI/HTImageDoc.html>. ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/menu.e�������������������������������������������������������������������������������0000644�0000764�0000764�00000013224�11602233312�014100� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/menu.e,v 1.6 2011/05/16 16:21:58 william Exp $ */ #ifndef _MENU_E_ #define _MENU_E_ typedef struct tagMenuDontSendCommandInfo { int dont_send_command; int selected_index; /* equals INVALID if nothing is selected */ } MenuDontSendCommandInfo; extern int iconWindowShown; extern int iconWindowCreated; extern int importingIconFile; extern int showVersion; extern int activeMenu; extern GC textMenuGC; extern GC rvPixmapMenuGC; extern int menuRowsBeforeScroll; extern int menuColsBeforeScroll; extern int maxScrollableMenuWidth; extern int maxScrollableMenuHeight; extern int deleteCmdAsCut; extern MenuDontSendCommandInfo gstMenuDontSendCommandInfo; #ifdef _INCLUDE_FROM_MENU_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_MENU_C_*/ extern void SendCommandToSelf ARGS_DECL((int nCmdId, int nIndex)); extern TgMenuItem *FindMenuItemByCmdId ARGS_DECL((TgMenu*, int cmdid)); extern TgMenuItem *FindMenuItemByIndex ARGS_DECL((TgMenu*, int index)); extern TgMenuItem *FindMenuItemBySubMenuInfoPtr ARGS_DECL((TgMenu*, TgMenuInfo*)); extern int TgSetMenuItemCheckById ARGS_DECL((TgMenu*, int cmdid, int checked)); extern int TgSetMenuItemRadioById ARGS_DECL((TgMenu*, int cmdid, int checked)); extern int TgIsMenuItemChecked ARGS_DECL((TgMenu*, int index)); extern int TgIsMenuItemRadio ARGS_DECL((TgMenu*, int index)); extern int TgIsMenuItemEnabled ARGS_DECL((TgMenu*, int index)); extern int TgEnableMenuItemById ARGS_DECL((TgMenu*, int cmdid, int enabled)); extern int TgEnableMenuItemByIndex ARGS_DECL((TgMenu*, int index, int enabled)); extern int TgEnableMenuItemBySubMenuInfoPtr ARGS_DECL((TgMenu*, TgMenuInfo*, int enabled)); extern void TgClearThreeDButton ARGS_DECL((Display*, Window, GC, struct BBRec *, int linewidth)); extern void TgDrawThreeDButton ARGS_DECL((Display*, Window, GC, struct BBRec *, int state, int linewidth, int button)); extern void TgDrawStipple ARGS_DECL((Display*, Window, GC, Pixmap, int x, int y, int w, int h, int fg_pixel, int bg_pixel, int fill_style)); extern void TgDraw2DGrayedPixmap ARGS_DECL((Display*, Window, Pixmap, int x, int y, int w, int h, int fg_pixel, int bg_pixel)); extern void TgDrawMenuItem ARGS_DECL((TgMenu*, TgMenuItem*)); extern void TgDrawEntireMenu ARGS_DECL((TgMenu*)); extern int TgWhichMenuIndex ARGS_DECL((TgMenu*, int x, int y, int must_be_in_menu)); extern TgMenu *TgCreatePopUpSubMenu ARGS_DECL((TgMenu*, int selected_index)); extern int TgPopUpSubMenu ARGS_DECL((TgMenu*, int win_x, int win_y)); extern void ScrollMenu ARGS_DECL((TgMenu*, int x, int y, int menu_w, int menu_h, int button_state)); extern int TgMenuLoop ARGS_DECL((TgMenu*)); extern TgMenu *TgDestroyMenu ARGS_DECL((TgMenu*, int free_menu)); extern int TgSetMenuItemInfo ARGS_DECL((TgMenuItem *to_menu_item, int mask, TgMenuItem *from_menu_item)); extern void TgSetMenuCanScroll ARGS_DECL((TgMenu*)); extern void TgAdjustMenuGeometry ARGS_DECL((TgMenu*, int image_w, int image_h, int max_rows)); extern TgMenu *TgCreateMenuFromMenuInfo ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern void SetScrollableMenuFirstIndex ARGS_DECL((TgMenu*, int index)); extern int RefreshMainMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreateMainMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern int MainMenu ARGS_DECL((void)); extern int IsPrefix ARGS_DECL((char *Prefix, char *Str, char **Rest)); extern void RedrawTitleWindow ARGS_DECL((void)); extern void RedrawIconWindow ARGS_DECL((void)); extern void InitTitle ARGS_DECL((void)); extern void InitMenu ARGS_DECL((void)); extern void CleanUpMenu ARGS_DECL((void)); extern void SaveDrawWinInfo ARGS_DECL((void)); extern void UnIconify ARGS_DECL((void)); extern void Iconify ARGS_DECL((void)); extern void IconEventHandler ARGS_DECL((XEvent *)); extern void TitleEventHandler ARGS_DECL((XEvent *)); extern void CalcMenubarWindowHeight ARGS_DECL((void)); extern void RedrawMenubarWindow ARGS_DECL((void)); extern int MenubarEventHandler ARGS_DECL((XEvent *)); #ifdef _INCLUDE_FROM_MENU_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_MENU_C_*/ #endif /*_MENU_E_*/ ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/types.h������������������������������������������������������������������������������0000644�0000764�0000764�00000100433�11602233313�014303� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/types.h,v 1.47 2011/05/16 16:22:00 william Exp $ */ #ifndef _TGIF_TYPES_H_ #define _TGIF_TYPES_H_ #include "const.h" typedef void *(NLFN)ARGS_DECL((void)); /* a NULL function template */ typedef void (VDFN)ARGS_DECL((void)); /* a void procedure template */ #define DO_ALL_X_EV 0 #define EXPOSE_AND_ESC_X_EV_ONLY 1 typedef int (AbortCallbackFunc)ARGS_DECL((void*)); /* returns TRUE for abort */ typedef struct BBRec { int ltx, lty, rbx, rby; } * BBRecPtr; typedef struct PtRec { int x, y; struct PtRec * next; } * PtRecPtr; typedef struct { int x, y; } IntPoint; typedef struct tagIntPointTriplet { int earlier_valid, later_valid; IntPoint hinge_pt; IntPoint earlier_smooth_pt; IntPoint later_smooth_pt; /* this point moves at first */ double ratio; /* segment len earlier = (segment len later * ratio) */ } IntPointTriplet; typedef struct { double x, y; } DoublePoint; typedef struct XfrmMtrxRec { double m[4]; int t[2]; } * XfrmMtrxPtr; typedef struct ObjRec { int x, y, type, color, bg_color, id, dirty, hot_spot; int invisible, trans_pat; int rotation; /* degrees times 64 */ short marked, locked; struct BBRec orig_obbox, obbox; /* object bounding box */ struct BBRec bbox; /* real bounding box */ struct ObjRec * next, * prev; struct AttrRec * fattr, * lattr; /* first and last attributes */ union { struct GroupRec * r; struct PolyRec * p; struct PolygonRec * g; struct BoxRec * b; struct OvalRec * o; struct TextRec * t; struct ArcRec * a; struct RCBoxRec * rcb; struct XBmRec * xbm; struct XPmRec * xpm; struct SSRec * ss; } detail; struct ObjRec * tmp_child; /* used temporarily */ struct ObjRec * tmp_parent; /* used temporarily */ struct XfrmMtrxRec * ctm; struct XfrmMtrxRec * orig_ctm; /* not used, yet */ char color_str[40]; /* copy of the color name in file */ char bg_color_str[40]; /* copy of the color name in file */ XPoint rotated_obbox[5]; /* offsets */ void * userdata; /* for the multicast whiteboard */ char *creator_full_id; /* NULL means created locally */ int unavailable; /* involved in a long transaction of some sort */ } * ObjRecPtr; typedef struct DynStrRec { char *s; int sz; /* size of the buffer, should be strlen(s)+1 */ } * DynStrPtr; typedef struct SSRec { struct DynStrRec dyn_str; int double_byte, double_byte_mod_bytes, double_byte_vertical; } SimpleString; typedef struct AttrRec { struct DynStrRec attr_name; /* attribute name */ struct DynStrRec attr_value; /* attribute value */ short shown; /* TRUE if the attribute is shown */ short nameshown; /* TRUE if the attr name is also shown */ short inherited; /* TRUE if attr was inherited */ struct ObjRec * obj; /* the OBJ_TEXT object that represent the attr */ struct ObjRec * owner; /* ptr to owner obj of the record */ struct AttrRec * next, * prev; /* next and prev attributes */ void * userdata; int tgo_type; /* default to be TGO_STRING */ void * tgo_data; } * AttrRecPtr; /* * Pins are not implemented yet! */ typedef struct ConnRec { struct ObjRec * poly_obj; int at_start; /* TRUE if connect to start_conn of poly */ struct ObjRec * pin_obj; struct ConnRec * next, * prev; } * ConnRecPtr; typedef struct GroupRec { struct ObjRec * first, * last; char s[MAXPATHLENGTH+1]; int rotate, flip, deck_index, pin_connected; /* * For a pin object, if !pin_connected, first is used. * If pin_connected, last is used. This means that * first is the un-connected view of a pin object * and last is the connected view of a pin object. * * Please note that pins are not implemented yet! */ struct ConnRec * first_conn, * last_conn; } * GroupRecPtr; typedef struct ArrowStyleRec { int arrow_style; int aw, ah, aindent; char aw_spec[40], ah_spec[40], aindent_spec[40]; } * ArrowStyleRecPtr; typedef struct PolyRec { int n; /* number of points in the polyline */ IntPoint * vlist; /* absolute */ char * smooth; int ssn; /* number of points in a structured spline */ IntPoint * ssvlist; /* absolute */ char * ssmooth; int sn; /* number of points in the spline polyline */ XPoint * svlist; /* offsets */ int asn; /* spline polyline with arrows */ XPoint * asvlist; /* offsets */ int intn; /* interpolated spline original spec */ IntPoint * intvlist; /* absolute */ int style, width, pen, curved, fill, dash, tension; char width_spec[40]; int rotated_n, rotated_asn; XPoint * rotated_vlist, * rotated_asvlist; /* offsets */ struct ArrowStyleRec start_asty, end_asty; /* * Please note that pins are not implemented yet! */ struct ConnRec * start_conn; /* connection at vlist[0] */ struct ConnRec * end_conn; /* connection at vlist[n-1] */ /* * To be obsoleted! */ int aw, ah; char aw_spec[40], ah_spec[40]; } * PolyRecPtr; typedef struct PolygonRec { int n; /* number of points in the polygon */ IntPoint * vlist; /* absolute */ char * smooth; int ssn; /* number of points in a structured spline */ IntPoint * ssvlist; /* absolute */ char * ssmooth; int sn; /* number of points in the spline polygon */ XPoint * svlist; /* offsets */ int intn; /* interpolated spline original spec */ IntPoint * intvlist; /* absolute */ int fill, width, pen, curved, dash, tension; char width_spec[40]; int rotated_n; XPoint * rotated_vlist; /* offsets */ } * PolygonRecPtr; typedef struct BoxRec { int fill, width, pen, dash; char width_spec[40]; } * BoxRecPtr; typedef struct OvalRec { int fill, width, pen, dash; char width_spec[40]; int rotated_n; XPoint * rotated_vlist; /* offsets */ } * OvalRecPtr; typedef struct KeyValRec { char *key; char *value; struct KeyValRec *next, *prev; } KeyValInfo; typedef struct StrRec { struct DynStrRec dyn_str; struct StrRec * next, * prev; } * StrRecPtr; typedef struct TextExtentsRec { char *buf; int len; /* strlen(buf) */ int w, lbearing, rextra; /* lbearing is always <= 0, rextra >= 0 */ int bbox_w, bbox_h, asc, des; } TextExtentsInfo; typedef struct RecalcMetricsRec { int orig_x, orig_baseline_y; int x, baseline_y; int depth, pre_order; } RecalcMetricsInfo; typedef struct StrSegRec { int color; char color_str[40]; /* copy of the color name in file */ int font, style, sz_unit; int real_sz_unit; /* only used if Tgif.EditTextSize is used */ int double_byte, double_byte_mod_bytes, double_byte_vertical, direction; int underline_on, overline_on; int w, asc, des, min_lbearing, max_rextra; int read_only, orig_w, orig_h, orig_asc, orig_des; /* only if read_only */ char * font_name; /* only used in PRTGIF */ struct DynStrRec dyn_str; struct StrBlockRec * owner; /* * for file version 38! */ int dontreencode; } StrSegInfo; #define SB_SIMPLE 0 #define SB_SUPSUB_LEFT 1 #define SB_SUPSUB_CENTER 2 #define SB_SUPSUB_RIGHT 3 #define SB_CHAR_SPACE 4 /* special_char_w is pixel offsets */ typedef struct StrBlockRec { int w, asc, des, min_lbearing, max_rextra; int read_only, orig_w, orig_h, orig_asc, orig_des; /* only if read_only */ int special_char_w; int depth, pre_order; /* set in RecalcTextMetrics() */ int type; /* one of SB_* */ StrSegInfo *seg; struct MiniLinesRec *sup, *sub; struct MiniLineRec *owner_mini_line; struct StrBlockRec *next, *prev; /* * used to determine what to repaint */ int clean; struct BBRec clean_bbox, bbox; } StrBlockInfo; typedef struct MiniLineRec { int w, asc, des, min_lbearing, max_rextra; int read_only, orig_w, orig_h, orig_asc, orig_des; /* only if read_only */ /* * For the first mini_line, v_gap is always 0. * For other mini_line, v_gap is relative to the mini_line * immediately above it (after asc and des of the mini_line, * and v_space of the minilines). */ int v_gap; struct StrBlockRec *first_block, *last_block; struct MiniLineRec *next, *prev; struct MiniLinesRec *owner_minilines; /* * used to determine what to repaint */ int clean; struct BBRec clean_bbox, bbox; } MiniLineInfo; typedef struct MiniLinesRec { int w, h, min_lbearing, max_rextra; int read_only, orig_w, orig_h, orig_asc, orig_des; /* only if read_only */ int just, v_space; /* * For the minilines of a text_ptr, baseline_offset always 0. * For the sup and sub of a str_block, baseline_offset is relative to * the baseline of the str_block, which is the baseline of the * mini_line which owns the str_block. This offsets the mini_lines * in it all together. */ int baseline_offset; /* * owner_block is NULL for the top minilines; */ struct StrBlockRec *owner_block; struct MiniLineRec *first, *last; /* * used to determine what to repaint */ int clean; struct BBRec clean_bbox, bbox; } MiniLinesInfo; typedef struct TextRec { /* * The height of a line is determined by the font height of the first * substr. V_space is also the v_space of the first substr. */ int lines, pen, fill; int w, h, min_lbearing, max_rextra; struct AttrRec *attr; /* ptr to attr record if text obj is an attr */ Pixmap cached_bitmap, cached_pixmap, cached_bg_bitmap; int cached_zoom, cached_zoomed; struct XfrmMtrxRec cached_ctm; struct BBRec orig_bbox; int underline_y_offset, overline_y_offset; /* these are new */ /* * baseline_y is the real thing! y of struct ObjRec is derived from it * by subtracting minilines->asc */ int baseline_y; int read_only, orig_w, orig_h, orig_asc, orig_des; /* only if read_only */ struct MiniLinesRec minilines; } * TextRecPtr; typedef struct tagStretchStructuredSplineInfo { int hinge; /* TRUE if a hinge point is selected, FALSE otherwise */ int orig_hinge_index; /* this index into vlist */ int earlier_smooth_selected; int prev_valid; /* FALSE if the first point of a poly is selected */ int next_valid; /* FALSE if the last point of a poly is selected */ IntPointTriplet ipt_prev, ipt, ipt_next; /* for drawing */ int num_vs, num_vs2; IntPoint vs[5], vs2[5]; char smooth[5], smooth2[5]; XPoint *sv, *sv2, *saved_sv, *saved_sv2; int sn, sn2, saved_sn, saved_sn2; /* for moving a vertex -- only one vertex can be selected */ int orig_abs_x, orig_abs_y, new_abs_x, new_abs_y, abs_dx, abs_dy; int rotated_orig_abs_x, rotated_orig_abs_y; int rotated_new_abs_x, rotated_new_abs_y; int rotated_abs_dx, rotated_abs_dy; } StretchStructuredSplineInfo; typedef struct SelRec { struct ObjRec * obj; struct SelRec * next, * prev; } * SelRecPtr; typedef struct tagMoveVertexInfo { int orig_abs_x, orig_abs_y, new_abs_x, new_abs_y, abs_dx, abs_dy; int rotated_orig_abs_x, rotated_orig_abs_y; int rotated_new_abs_x, rotated_new_abs_y; int rotated_abs_dx, rotated_abs_dy; } MoveVertexInfo; typedef struct VSelRec { struct ObjRec * obj; int n, max_v, * v_index, * x, * y; struct VSelRec * next, * prev; /* for moving a vertex -- normally pmvi is NULL */ MoveVertexInfo * pmvi; } * VSelRecPtr; typedef struct MoveSubCmdRec { int dx, dy; } * MoveSubCmdRecPtr; typedef struct tagTextFormatInfo { int color_index, font_style; char color_str[40]; } TextFormatInfo; #define CHAT_STATE_NORMAL 0 #define CHAT_STATE_HELLO 1 #define CHAT_STATE_DISCONNECT 2 typedef struct ChatSubCmdRec { int type; TextFormatInfo tfi; char nick_name[MAXSTRING]; char encoding[MAXSTRING]; char *buf; } * ChatSubCmdRecPtr; typedef struct SlideShowSubCmdRec { int into_slideshow; /* TRUE if going into slideshow mode */ } * SlideShowSubCmdRecPtr; typedef struct ClearAllSubCmdRec { int page_style; float print_mag; } * ClearAllSubCmdRecPtr; typedef struct SubCmdRec { union { struct MoveSubCmdRec move; struct ChatSubCmdRec chat; struct SlideShowSubCmdRec slideshow; struct ClearAllSubCmdRec clearall; } detail; } * SubCmdRecPtr; typedef struct CmdRec { int type, undone; int include_tgif_obj, new_colormap, logical_clock; char * sender_process_id; int * pos_before, count_before, pos_before_has_ids; int * pos_after, count_after; struct SelRec * top_before, * bot_before; struct SelRec * top_after, * bot_after; struct CmdRec * next, * prev; struct CmdRec * first, * last; /* * if serialized is TRUE, pos_before should be typecasted to (char**) * and each entry is <creator_full_id> which is "id", "/", * "creator_pid", ":", and "creator_ip" concatenated together. */ int serialized; char * serialization_buf; int first_redo_after_deserialize; int skipped; struct SubCmdRec * subcmd; } * CmdRecPtr; typedef struct PageRec { struct ObjRec * top, * bot; struct PageRec * next, * prev; char * name; char * page_file_name; int draw_orig_x, draw_orig_y, zoom_scale, zoomed_in; int layer_on; } * PageRecPtr; typedef struct StkRec { struct ObjRec * first, * last, * sel; struct StkRec * next; struct CmdRec * first_cmd, * last_cmd, * cur_cmd; int history_count; int name_valid, file_mod, id, page_style; int orig_x, orig_y, zoom, zoomed; int grid_system, english_grid, metric_grid, snap_on; int color, h_align, v_align, line_w, line_s; int fill, pen, dash, just, font, f_style, f_sz_unit; int trans_pat; float print_mag; int v_space, grid_shown, move_mode; int rcb_radius, underline_on, underline_y_offset; int overline_on, overline_y_offset; char name[MAXPATHLENGTH+1], domain[MAXPATHLENGTH+1]; char dir[MAXPATHLENGTH+1], sym_dir[MAXPATHLENGTH+1]; char * saved_comments; int saved_comments_len; struct AttrRec * first_file_attr, * last_file_attr; struct PageRec * first_page, * last_page, * cur_page; int cur_page_num, last_page_num, cols, rows; int page_layout_mode, color_dump; int one_page_width, one_page_height; int file_bg_pixel, file_fg_pixel; int file_bg_pixmap_w, file_bg_pixmap_h; char *file_bg_color_str, *file_fg_color_str; char *file_bg_gif_url; Pixmap file_bg_pixmap; } * StkRecPtr; typedef struct ArcRec { int fill, width, pen, dash, style, aw, ah; char width_spec[40], aw_spec[40], ah_spec[40]; int xc, yc, x1, y1, x2, y2, dir; int ltx, lty, w, h, angle1, angle2; int a_angle1, a_angle2; int rotated_n, rotated_asn; XPoint * rotated_vlist, * rotated_asvlist; /* offsets */ } * ArcRecPtr; typedef struct RCBoxRec { int fill, width, pen, dash, radius; char width_spec[40]; int rotated_n; XPoint * rotated_vlist; /* offsets */ } * RCBoxRecPtr; typedef struct XBmRec { int fill, real_type, flip, image_w, image_h; int eps_w, eps_h; char * data; char * filename; char * * epsflines; char write_date[32]; int num_epsf_lines, epsf_level, save_epsf; int llx, lly, urx, ury; /* these values are x1000 */ XImage * image; Pixmap bitmap; Pixmap cached_bitmap; int cached_zoom, cached_zoomed, cached_flip; int cached_w, cached_h; struct XfrmMtrxRec cached_ctm; } * XBmRecPtr; typedef struct XPmRec { int fill, real_type, flip, image_w, image_h; int linked_jpeg; /* TRUE if JPEG is linked */ char * filename; /* only valid if JPEG is linked */ char tmp_ppm6_fname[MAXPATHLENGTH+1]; /* used temporarily */ int ncolors; int chars_per_pixel; int first_pixel_is_bg; int * pixels, * red, * green, * blue; char * color_char; char * * color_str; char * data; XImage * image, * bitmap_image; Pixmap pixmap, bitmap; Pixmap cached_pixmap, cached_bitmap; int cached_zoom, cached_zoomed, cached_flip; int cached_w, cached_h, cached_color; Pixmap clip_mask; struct XfrmMtrxRec cached_ctm; /* * If real_type is PPM_TRUE, color_char, color_str, pixels, and data are * all NULL and ncolors is 0. * The following are only valid if real_type is PPM_TRUE. */ int ppm_data_compress; /* 0x1: jpeg, 0x2: ppm.z */ char * ppm_data; /* can be raw (jpeg) or deflated (ppm.z) */ unsigned int ppm_data_size; char * ppm_mask_data; /* not used, for future transparency */ unsigned int ppm_mask_size; /* not used, for future transparency */ int has_transparent_color; unsigned char transparent_color[3]; /* r, g, b */ void * userdata; } * XPmRecPtr; typedef struct WinInfoRec { Window window; int mapped; int raise; int (*ev_handler)ARGS_DECL((XEvent*, struct WinInfoRec *)); void (*expose_handler)ARGS_DECL((XEvent*, struct WinInfoRec *)); void (*cleanup)ARGS_DECL((struct WinInfoRec *)); void *userdata; } * WinInfoPtr; typedef struct tagKeyOrBtnEvInfo { int type; Bool send_event; Display *display; Window window; Time time; int x, y; unsigned int keycode_or_button; unsigned int state; } KeyOrBtnEvInfo; typedef struct MtrxRec { float m[2][2], rev_m[2][2], h_scale, v_scale; float image_w, image_h, w, h, transformed_w, transformed_h; float dump_h_scale, dump_v_scale; int rotate, flip, degree; } * MtrxPtr; typedef struct _DspList { char itemstr[MAXPATHLENGTH+1]; char pathstr[MAXPATHLENGTH+1]; int directory; struct _DspList * next; } DspList; typedef struct MouseStatusStrRec { char * l, * m, * r; } MouseStatusStrPtr; typedef struct tagMouseOverStatusInfo { char btn_str[MAX_STATUS_BTNS][MAXSTRING+1]; char one_line_str[MAXSTRING+1]; int one_line_status; struct tagMouseOverStatusInfo *next; } MouseOverStatusInfo; typedef struct VRec { int vtype; union { int i; double d; char *s; } val; } VRecPtr; struct URLCacheRec { int remote_buf_sz, is_html; char *remote_buf, *content_type, *simple_url_name; struct URLCacheRec *next, *prev; }; typedef struct PushedFontRec { int font; int sz_unit; int style; int just; int pen; int fill; int trans_pat; int v_space; int color; int underline_on; int underline_y_offset; int overline_on; int overline_y_offset; int double_byte, double_byte_mod_bytes, double_byte_vertical; struct PushedFontRec *next; } * PushedFontRecPtr; typedef struct ObjListRec { struct ObjRec *top_obj, *bot_obj; struct SelRec *top_sel, *bot_sel; int count; } ObjListInfo; typedef struct tagSimpleWinInfo { int x, y, w, h; } SimpleWinInfo; typedef struct tagDirtyBBoxInfo { int valid; int force_redraw_all; struct BBRec bbox; } DirtyBBoxInfo; typedef struct tagTextHighlightInfo { /* all these values are screen offsets */ int start_x, start_min_y, start_max_y, start_baseline_y; int end_x, end_min_y, end_max_y, end_baseline_y; StrBlockInfo *start_str_block_ptr, *end_str_block_ptr; int start_index, end_index; int highlighting; /* used in PaintMiniLines() */ int mode; /* one of PAINT_* above */ } TextHighlightInfo; typedef struct tagCopyUTF8Info { int single_byte_valid, double_byte_valid; StrSegInfo single_byte_seg; StrSegInfo double_byte_seg; } CopyUTF8Info; typedef struct tagDrawTextInfo { /* the following is from miniline.e */ TextHighlightInfo text_highlight_info; int text_orig_x, text_orig_y, text_orig_baseline_y; int text_abs_x, text_abs_y, text_abs_baseline_y; int text_cur_x, text_cur_y, text_cur_baseline_y; int text_cur_index; int text_end_x, text_end_y, text_end_baseline_y; int text_end_index; int text_abs_min_lbearing, text_abs_max_rextra; int text_w, text_h; int text_highlight; struct ObjRec *cur_text_obj; struct BBRec cur_text_obbox, cur_text_bbox; StrBlockInfo *cur_str_block; StrBlockInfo *end_str_block; MiniLineInfo *first_miniLine, *last_miniLine; int esc_pressed; int cur_text_outline_w, cur_text_outline_half_w; /* the following is from text.e */ int text_drawn; int cur_text_modified; int text_vspace; int text_just; int text_cursor_shown; int text_cursor_h; int editing_text; int cur_text_is_new; int edit_text_size; /* the following is from struct PushedFontRec */ struct PushedFontRec font_info; } DrawTextInfo; typedef struct tagColorBytes { int valid; unsigned char r, g, b; } ColorBytes; typedef struct tagTrueColorInfo { unsigned long r_mask, g_mask, b_mask; unsigned int r_shift, g_shift, b_shift; double dr_maxval, dg_maxval, db_maxval; /* dr_maxval_div255 = dr_maxval/255, etc. */ double dr_maxval_div255, dg_maxval_div255, db_maxval_div255; unsigned int num_r_bits, num_g_bits, num_b_bits; } TrueColorInfo; /* ------------------ imageproc stuff ------------------ */ typedef void (ImageMapColorFunc)ARGS_DECL((int nColorIndex, XColor*)); typedef int (ConvolveFunc)ARGS_DECL((int x, int y)); #define TRAP_NODE_LEAF 0 #define TRAP_NODE_PT 1 #define TRAP_NODE_SEG 2 #define TRAP_PT_L 0 #define TRAP_PT_T 1 #define TRAP_PT_R 2 #define TRAP_PT_B 3 #define TRAP_PT_C 4 #define TRAP_SEG_L 0 #define TRAP_SEG_T 1 #define TRAP_SEG_R 2 #define TRAP_SEG_B 3 #define TRAP_LEAF_LT 0 #define TRAP_LEAF_RT 1 #define TRAP_LEAF_LB 2 #define TRAP_LEAF_RB 3 typedef struct TrapMapSegRec { double m, b; /* y = mx + b */ } TrapMapSeg; typedef struct TrapMapRec { int type; /* TRAP_NODE_* */ union { struct { int which; /* TRAP_LEAF_* */ int *data; /* points to one of gaTrapMapLeaf */ } leaf; struct { int which; /* TRAP_PT_* */ IntPoint *data; /* points to one of gaTrapMapPt */ struct TrapMapRec *left, *right; } pt; struct { int which; /* TRAP_SEG_* */ TrapMapSeg *data; /* points to one of gaTrapMapSeg */ struct TrapMapRec *above, *below; } seg; } detail; } TrapMap; typedef struct TrapMapSpecRec { int type; int which; } TrapMapSpec; /* ------------------ copy and paste properties stuff ------------------ */ typedef struct CheckArrayRec { int num_cols; int num_rows; int **value; /* value[0..(col_index-1)][0..(row_index-1)] */ char **col_name; /* col_name[0..col_index] */ } * CheckArrayRecPtr; typedef int (GetEntriesFunc)ARGS_DECL((DspList**, char***, int *pn_num_entries, int *pn_marked_index, struct CheckArrayRec **, char *inbuf, void*)); typedef int (AfterLoopFunc)ARGS_DECL((DspList**, char***, int *pn_num_entries, int *pn_marked_index, struct CheckArrayRec **, char *cur_buf, int btn_id, int selected_index, void*)); typedef int (CheckUpdateFunc)ARGS_DECL((DspList**, char***, int *pn_num_entries, int *pn_marked_index, struct CheckArrayRec **, char *cur_buf, int col, int row, void*)); typedef struct PropertiesRec { int color, width, aw, ah, width_index; char color_str[40], width_spec[40], aw_spec[40], ah_spec[40]; int fill, pen, dash, arrow_style, curved, rcb_radius; int trans_pat, text_just, text_sz_unit, v_space; int underline_on, overline_on; int double_byte, text_font, text_style; int transformed; struct XfrmMtrxRec ctm; void * userdata; } * PropertiesRecPtr; /* ------------------ pixmap button stuff ------------------ */ #define TGBS_NORMAL 0 /* button state is enabled */ #define TGBS_GRAYED 1 /* button state is disabled */ #define TGBS_RAISED 2 /* button state is mouse-overed */ #define TGBS_LOWRED 3 /* button state is pressed */ typedef struct TgPxMpBtnRec { int flags; /* if (1<<TGBS_* != 0) then pixmap[TGBS_*] is valid */ int state; Pixmap pixmap[4]; } TgPxMpBtn; /* ------------------ menu stuff ------------------ */ #define TGMUITEM_SEPARATOR ((char*)(-1)) #define TGMUITEM_BREAK ((char*)(-2)) #define TGMUITEM_SUBMENU ((char*)(-3)) #define TGMUITEM_PINNABLESUBMENU ((char*)(-4)) /* flasg */ #define TGMU_SEPARATOR 0x00000001 #define TGMU_BREAK 0x00000002 /* does not handle this, yet */ #define TGMU_HAS_CHECK 0x00000004 /* put a check mark if checked */ #define TGMU_HAS_RADIO 0x00000008 /* put a dot mark if checked */ #define TGMU_HAS_SUBMENU 0x00000010 #define TGMU_SUBMENU_PINNABLE 0x00000020 #define TGMU_HAS_SHORTCUT 0x00000040 #define TGMU_MULTICOLOR 0x00000080 #define TGMU_DISABLED 0x00000100 /* masks */ #define TGMU_MASK_STATE 0x00010000 /* set/get state */ #define TGMU_MASK_CMDID 0x00020000 /* set/get cmdid */ #define TGMU_MASK_MULTICOLOR 0x00040000 /* set/get multicolor_pixel */ #define TGMU_MASK_PXMPBTN1 0x00100000 /* set/get checked_pxmpbtn */ #define TGMU_MASK_PXMPBTN2 0x00200000 /* set/get unchecked_pxmpbtn */ #define TGMU_MASK_CHECK 0x00400000 /* set/get check for check mark */ #define TGMU_MASK_RADIO 0x00800000 /* set/get check for radio mark */ #define TGMU_MASK_MENUSTR 0x01000000 /* set/get menu_str */ #define TGMU_MASK_STATUSSTR 0x02000000 /* set/get status_str */ #define TGMU_MASK_SUBMENU 0x04000000 /* set/get status_str */ #define TGMU_MASK_PINNABLESUBMENU 0x08000000 /* set/get status_str */ #define TGMU_MASK_SHORTCUTSTR 0x10000000 /* set/get status_str */ #define TGMU_MASK_LTXY 0x20000000 /* set/get status_str */ #define TGMU_MASK_USERDATA 0x40000000 /* set/get bbox.ltx and bbox.lty */ #define TGMU_MASK_RAWSTATUSSTR 0x80000000 /* need to gettext() before copy */ typedef struct TgMenuItemRec { int flags; /* TGMU_* */ int state; /* one of TGBS_* */ int checked; /* valid if TGMU_HAS_CHECK or TGMU_HAS_RADIO */ int cmdid; /* command identifier */ int multicolor_pixel; /* valid only if TGMU_MULTICOLOR */ struct BBRec bbox; TgPxMpBtn *checked_pxmpbtn; /* valid only if TGMU_HAS_PIXMAP */ TgPxMpBtn *unchecked_pxmpbtn; /* valid only if TGMU_HAS_PIXMAP */ int menu_str_allocated; /* need to free(menu_str) on destroy */ char *menu_str; char *status_str; void *userdata; union { struct TgMenuRec *submenu; char *shortcut_str; } detail; struct TgMenuItemInfoRec *submenu_create_info; } TgMenuItem; #define TGMUTYPE_TEXT 0 #define TGMUTYPE_COLOR 1 #define TGMUTYPE_BITMAP 2 #define TGMUTYPE_MASK 0x0f #define TGMUTYPE_CANSCROLL 0x10 typedef int (RefreshMenuFunc)ARGS_DECL((void *menu)); typedef struct TgMenuRec { int type; /* one of TGMUTYPE_* */ int num_items; int selected_index; struct BBRec bbox; Window window; int padding; /* 0 if not 3D */ int brdr_w; /* 0 if 3D */ int is_main_menu; int track_menubar; int track_parent_menu; int disallow_pinning; int check_start, str_start; /* for TGMUTYPE_TEXT */ int shortcut_start, arrow_start; /* for TGMUTYPE_TEXT */ /* can_scroll -- can have a scroll bar */ int can_scroll; int scroll_start; /* 0: no scrollbar */ int first_index; /* 0: scroll all the way to top or left */ /* multicolumn -- for TGMUTYPE_COLOR or TGMUTYPE_BITMAP */ int image_w, image_h, num_rows, num_cols; TgMenuItem *menuitems; /* for TGMUTYPE_TEXT */ void *userdata; struct TgMenuRec *parent_menu; RefreshMenuFunc *refresh_proc; /* must set this for a submenu */ } TgMenu; typedef struct TgMenuItemInfoRec { /* * for TGMUTYPE_TEXT, menu_str is (char*) * for TGMUTYPE_COLOR, menu_str is (int*) * for TGMUTYPE_BITMAP, menu_str is (Pixmap*) * menu_str can also be just TGMUITEM_SEPARATOR */ char *menu_str; /* * for TGMUTYPE_TEXT, shortcut_str is (char*) or TGMUITEM_SUBMENU * for TGMUTYPE_BITMAP, shortcut_str NULL */ char *shortcut_str; char *status_str; struct TgMenuInfoRec *submenu_info; int cmdid; /* INVALID means no cmdid */ } TgMenuItemInfo; typedef TgMenu *(CreateMenuFunc)ARGS_DECL((TgMenu *parent_menu, int x, int y, struct TgMenuInfoRec *menuinfo, int status_str_xlated)); typedef struct TgMenuInfoRec { int type; /* one of TGMUTYPE_* */ TgMenuItemInfo *items; CreateMenuFunc *create_proc; } TgMenuInfo; /* ------------------ shortcut stuff ------------------ */ #ifdef __DARWIN__ #ifdef _DARWIN_MOD1_AS_META #define METAMASK (Mod1Mask) #else /* ~_DARWIN_MOD1_AS_META */ #define METAMASK (Mod2Mask) #endif /* _DARWIN_MOD1_AS_META */ #else /* ~__DARWIN__ */ #define METAMASK (Mod1Mask) #endif /* __DARWIN__ */ #define CNTRL_ONLY (ControlMask) #define META_ONLY (METAMASK) #define CNTRL_META (ControlMask|METAMASK) typedef struct ShortCutRec { char code; unsigned int state; char name[80]; short num_args; short cmdid; } ShortCutInfo; /* ------------------ edit attr stuff ------------------ */ typedef struct tagEditAttrRec { int num_attrs; char **attr_names; char **attr_values; char **attr_strings; char **status_strings; int *fore_colors; int *attr_indices; } EditAttrInfo; /* ------------------ scroll stuff ------------------ */ typedef int (ScrollBtnCallbackFunc)ARGS_DECL((void*)); typedef int (ScrollingCallbackFunc)ARGS_DECL((XMotionEvent*, void*)); typedef struct tagScrollBtnCallbackInfo { int ms; void *pv_userdata; ScrollBtnCallbackFunc *pf_scroll_btn_callback; } ScrollBtnCallbackInfo; /* ------------------ exec stuff ------------------ */ typedef int (ExecFunc)ARGS_DECL((char **argv, struct ObjRec *obj_ptr, char *orig_cmd)); typedef int (RawExecFunc)ARGS_DECL((char **argv, char **raw_argv, struct ObjRec *obj_ptr, char *orig_cmd)); typedef void (SimpleExecFunc)ARGS_DECL((struct ObjRec *obj_ptr, char *orig_cmd)); typedef struct tagExecInfoRec { NLFN *pfunc; char *func_name; int func_argc; /* * if (func_argc == 0) { * pfunc is (SimpleExecFunc)(); * } else if (func_argc < 0) { * pfunc is (RawExecFunc)(); * } else { * pfunc is (ExecFunc)(); * } */ int double_quotes_for_null; /* * If TRUE, then if $(foo) evaluates to the empty string, "" is * passed. This is mainly used by commands with expression * evaluations. */ } ExecInfo; /* ------------------ page stuff ------------------ */ typedef struct tagSpecifyPagesInfoRec { int num_pages_specified; int *page_specified; } SpecifyPagesInfo; typedef struct tagPageInfoRec { int page_layout_mode, paper_col, paper_row; int cur_page_num, last_page_num; struct PageRec *first_page, *last_page, *cur_page; } PageInfo; /* ------------------ progress stuff ------------------ */ typedef struct tagProgressInfoRec { int total_size; int target_percent; char status_buf[MAX_STATUS_BTNS+1][MAXSTRING+1]; int one_line_status; } ProgressInfo; /* ------------------ generated_by stuff ------------------ */ typedef struct tagGeneratedByInfoRec { char name[40]; int version; /* version for tgif */ char version_str[40]; /* version of the tool */ } GenerateByInfo; /* ------------------ pngtrans stuff ------------------ */ typedef struct tagPngHeaderInfo { int valid; char fname[MAXPATHLENGTH]; FILE *fp; uint32_t image_w; uint32_t image_h; unsigned char bit_depth; unsigned char color_type; unsigned char compression_method; unsigned char filter_method; unsigned char interlace_method; uint32_t palette_sz; unsigned char *palette; int trans_color_pixel_found; unsigned char trans_color_pixel_red; unsigned char trans_color_pixel_green; unsigned char trans_color_pixel_blue; } PngHeaderInfo; #endif /*_TGIF_TYPES_H_*/ �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/testdrive.c��������������������������������������������������������������������������0000644�0000764�0000764�00000021321�11602233313�015141� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/testdrive.c,v 1.6 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TESTDRIVE_C_ #include "tgifdefs.h" #include "mainloop.e" #include "msg.e" #include "obj.e" #include "setup.e" /* * extern int malloc_debug ARGS_DECL((int)); */ int lastFile=TRUE; short *pDrawFontAsc=NULL; short *pDrawFontDes=NULL; /* * static * void Prompt2 (PromptStr, OpName, FileName) * char * PromptStr, * OpName, * FileName; * { * char inbuf[80]; * * printf (PromptStr); * fgets (inbuf, 80, stdin); * sscanf (inbuf, "%s%s", OpName, FileName); * } * * static * void Prompt3 (PromptStr, AttrName, ColorName, ValName) * char * PromptStr, * AttrName, * ColorName, * ValName; * { * char inbuf[80]; * * printf (PromptStr); * fgets (inbuf, 80, stdin); * sscanf (inbuf, "%s%s%s", AttrName, ColorName, ValName); * } */ static void PrintObjId(ObjPtr, Level) struct ObjRec *ObjPtr; int Level; { register int i; int id=ObjPtr->id; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; for (i = 0; i < Level; i++) printf(" "); switch (ObjPtr->type) { /* these are all the tgif object types */ case OBJ_POLY: printf("poly: %1d\n", id); break; case OBJ_BOX: printf("box: %1d\n", id); break; case OBJ_OVAL: printf("oval: %1d\n", id); break; case OBJ_TEXT: printf("text: %1d\n", id); break; case OBJ_ARC: printf("arc: %1d\n", id); break; case OBJ_RCBOX: printf("rcbox: %1d\n", id); break; case OBJ_XBM: printf("xbm: %1d\n", id); break; case OBJ_XPM: printf("xpm: %1d\n", id); break; case OBJ_POLYGON: printf("polygon: %1d\n", id); break; case OBJ_GROUP: printf("group: %1d\n", id); break; case OBJ_SYM: printf("sym: %1d\n", id); break; case OBJ_ICON: printf("icon: %1d\n", id); break; case OBJ_PIN: printf("pin: %1d\n", id); break; } if (ObjPtr->type == OBJ_GROUP || ObjPtr->type == OBJ_SYM || ObjPtr->type == OBJ_ICON || ObjPtr->type == OBJ_PIN) { /* for these composite objects, each on maintains a LIST of objects */ for (obj_ptr=ObjPtr->detail.r->last; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { PrintObjId(obj_ptr, Level+1); } } /* all object can have a list of attributes; the head */ /* of the list is pointed to by the fattr and the */ /* tail of the list is pointed to by the lattr field */ if ((attr_ptr=ObjPtr->lattr) != NULL) { for (i = 0; i < Level+1; i++) printf(" "); printf("attrs:\n"); /* each attribute entry contains a TEXT object */ for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->prev) { PrintObjId(attr_ptr->obj, Level+2); } } } #define DO_CMD(cmd) ExecACommandFromBuffer(cmd,NULL) static void ScriptDemo() { MakeQuiescent(); /* select nothing, edit nothing */ if (BeginExecCommandsFromBuffer()) { int i=0; /* set current color to 'blue' */ DO_CMD("set_selected_obj_color(\"blue\")"); /* create a 200 pixels by 100 pixels blue box */ DO_CMD("create_box_obj(100,100,300,200)"); /* select the top object, which is the box object */ DO_CMD("select_top_obj()"); /* name the box object "the_box" */ DO_CMD("add_attr_to_selected_obj(\"name\",\"the_box\",100,100)"); /* hide all the attributes of the box object */ DO_CMD("call_simple_shortcut(\"HideAttr\")"); /* unselect everything */ DO_CMD("unselect_all_obj()"); /* set current text justification to center justified */ DO_CMD("set_selected_text_just(\"center\")"); /* set current text font to Helvetica Bold */ DO_CMD("set_selected_text_font(\"Helvetica-Bold\")"); /* set current text size to 14 */ DO_CMD("set_selected_text_size(14)"); /* create a text object that sits on top the blue box */ DO_CMD("create_text_obj(200,100,\"My Box\")"); /* select the box object */ DO_CMD("select_obj_by_name(\"the_box\")"); /* sleep for 500ms */ DO_CMD("sleep(NULL,500)"); /* change the box to 'green' */ DO_CMD("set_selected_obj_color(\"green\")"); /* cycle through all the fill patterns */ for (i=31; i >= 0; i--) { char buf[80]; sprintf(buf, "set_selected_obj_fill(%1d)", i); DO_CMD(buf); } /* sleep for another 500ms */ DO_CMD("sleep(NULL,500)"); /* change the box to 'red' */ DO_CMD("set_selected_obj_color(\"red\")"); /* sleep for another 500ms */ DO_CMD("sleep(NULL,500)"); /* lock the box */ DO_CMD("call_simple_shortcut(\"Lock\")"); /* select the top object, which is the text object */ DO_CMD("select_top_obj()"); /* also select the box */ DO_CMD("select_additional_obj(\"the_box\")"); /* align the text object so that it sits in the middle of the box */ DO_CMD("call_simple_shortcut(\"AlignObjsMiddle\")"); /* unlock the box */ DO_CMD("call_simple_shortcut(\"UnLock\")"); /* unselect everything */ DO_CMD("unselect_all_obj()"); EndExecCommandsFromBuffer(); } } int main(argc, argv) int argc; char *argv[]; /* All these strangeness with strings are related to */ /* Prolog's foreign function interface. */ { register int i; char op_name[80], file_name[(MAXPATHLENGTH<<1)+1]; char *sp[6], *func_strp; /* * char color_name[80], val_name[80]; * char attr_name[80], speed_name[80], id_name[80]; */ /* * malloc_debug (1); */ if (!ProcessTgifOptions(argc, argv, file_name, sizeof(file_name))) return 1; if (file_name[0] == '\0') { MainLoop("init", "", &func_strp, &sp[0], &sp[1], &sp[2], &sp[3], &sp[4], &sp[5]); } else { MainLoop("init", file_name, &func_strp, &sp[0], &sp[1], &sp[2], &sp[3], &sp[4], &sp[5]); } /* * for (i = 0; i < 6; i++) * if (strcmp (sp[i], "") != 0) * printf ("%s ", sp[i]); * else * break; * printf ("\n"); */ while (TRUE) { char s[80]; strcpy(s, func_strp); s[4] = '\0'; DeallocStrings(&func_strp,&sp[0],&sp[1],&sp[2],&sp[3],&sp[4],&sp[5]); if (strcmp(s, "Quit") == 0) { *file_name = '\0'; MainLoop("quit", file_name, &func_strp, &sp[0], &sp[1], &sp[2], &sp[3], &sp[4], &sp[5]); DeallocStrings(&func_strp,&sp[0],&sp[1],&sp[2],&sp[3],&sp[4],&sp[5]); break; } else if (strcmp(s, "Solv") == 0) { struct ObjRec *obj_ptr; printf("==============\n"); printf("Listing IDs...\n"); printf("==============\n"); /* botObj points to the last top-level object, and */ /* topObj points to the first top-level object */ for (obj_ptr = botObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { PrintObjId(obj_ptr, 0); } printf("\n"); } else if (strcmp(s, "Anim") == 0) { ScriptDemo(); } Msg("Returned from basic driver."); /* * Prompt2 ("Input an operation and a sub command.\n",op_name,file_name); * * if (strcmp (op_name, "animate") == 0) * { * Prompt3 ("Input poly_id, speed, color.\n", id_name, speed_name, * color_name); * Animate (file_name, id_name, speed_name, color_name, &func_strp); * printf ("Animate RETURNs --> %s %s %s\n", func_strp, sp[0], sp[1]); * } * if (strcmp (op_name, "upd_attr_val") == 0) * { * Prompt3 ("Input attrname, color and value.\n", attr_name, color_name, * val_name); * UpdAttrVal (file_name, attr_name, color_name, val_name, &func_strp); * printf ("UpdAttrVal RETURNs --> %s %s %s\n", func_strp, sp[0], sp[1]); * } */ *op_name = *file_name = '\0'; MainLoop(op_name, file_name, &func_strp, &sp[0], &sp[1], &sp[2], &sp[3], &sp[4], &sp[5]); /* * printf ("RETURN --> %s ", func_strp); * for (i = 0; i < 6; i++) * if (strcmp (sp[i], "") != 0) * printf ("%s ", sp[i]); * else * break; * printf ("\n"); */ } return 0; } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Tgif.tmpl-linux-intl�����������������������������������������������������������������0000644�0000764�0000764�00000005705�11602233313�016664� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-linux-intl,v 1.13 2011/05/16 16:25:17 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif XCOMM ----------------------------------------------- XCOMM For Red Hat Linux 7.2 and above, /usr/bin/xpmtoppm does not XCOMM know how to handle XPM format version 1. Please XCOMM add -D_XPM3TOPPM to the last MOREDEFINES below. XCOMM ----------------------------------------------- PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g -Wall XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif XCOMM MOREDEFINES = -D_HAS_STREAMS_SUPPORT -DENABLE_NLS -D_TGIF_DBG LOCALEDIR = /usr/share/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -DUSE_XT_INITIALIZE -DPTHREAD -D_ENABLE_NLS MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM DEPLIBS = $(DEPXLIB) DEPLIBS = $(DEPXMULIB) $(DEPXTOOLLIB) $(DEPXLIB) XCOMM LOCAL_LIBRARIES = $(XLIB) LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) SYS_LIBRARIES = -ldl -lm -lz -lpthread XCOMM SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM Linux 2.0.35 XCOMM XCOMM Linux 2.4.18-14 XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM �����������������������������������������������������������tgif-QPL-4.2.5/miniline.e���������������������������������������������������������������������������0000644�0000764�0000764�00000031071�11602233312�014740� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/miniline.e,v 1.20 2011/05/16 16:21:58 william Exp $ */ #ifndef _MINILINE_E_ #define _MINILINE_E_ #define PAINT 0x1 #define FRONT_HIGHLIGHT 0x2 #define MID_HIGHLIGHT 0x4 #define BACK_HIGHLIGHT 0x8 #define ERASE 0 #define PAINT_NORM (PAINT) #define PAINT_INV (PAINT|FRONT_HIGHLIGHT|MID_HIGHLIGHT|BACK_HIGHLIGHT) #define PAINT_NORM_INV (PAINT|MID_HIGHLIGHT|BACK_HIGHLIGHT) #define PAINT_INV_NORM (PAINT|FRONT_HIGHLIGHT) #define PAINT_NORM_INV_NORM (PAINT|MID_HIGHLIGHT) typedef void (STRSEGFN)ARGS_DECL((StrSegInfo*, void*)); extern TextHighlightInfo gstTextHighlightInfo; extern CopyUTF8Info gstCopyUTF8Info; extern int textOrigX, textOrigY, textOrigBaselineY; extern int textAbsX, textAbsY, textAbsBaselineY; extern int textCurX, textCurY, textCurBaselineY; extern int textCurIndex; extern int textEndX, textEndY, textEndBaselineY; extern int textEndIndex; extern int textAbsMinLBearing, textAbsMaxRExtra; extern int textW, textH; extern int textHighlight; extern struct ObjRec *curTextObj; extern struct BBRec curTextOBBox, curTextBBox; extern StrBlockInfo *curStrBlock; /* block must always be SB_SIMPLE */ extern StrBlockInfo *endStrBlock; /* block must always be SB_SIMPLE */ extern MiniLineInfo *firstMiniLine, *lastMiniLine; extern int escPressed; extern int dontRecalcStrSegMetrics; extern int curTextOutlineW, curTextOutlineHalfW; extern int drawWinHasFocus; #ifdef _INCLUDE_FROM_MINILINE_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_MINILINE_C_*/ extern void ClearCopyUTF8Info ARGS_DECL((void)); extern void SetCopyUTF8FontInfo ARGS_DECL((StrSegInfo*, int double_byte)); extern int CalcSingleByteInfoForCopyUTF8 ARGS_DECL((int *pn_font_index)); extern int CanFindSingleByteFontAtCursor ARGS_DECL((StrSegInfo*)); extern int CanFindDoubleByteFontAtCursor ARGS_DECL((StrSegInfo*)); extern void SaveDrawTextInfo ARGS_DECL((DrawTextInfo*)); extern void RestoreDrawTextInfo ARGS_DECL((DrawTextInfo*)); extern void ResetDrawTextInfo ARGS_DECL((void)); extern void SaveDrawWinDrawTextInfo ARGS_DECL((int forced)); extern void RestoreDrawWinDrawTextInfo ARGS_DECL((int forced)); extern void ResetDirtyBBoxInfo ARGS_DECL((void)); extern void AddToDirtyBBox ARGS_DECL((struct BBRec *)); extern void ForceDirtyBBoxToRedrawAll ARGS_DECL((void)); extern int GetDirtyBBox ARGS_DECL((struct BBRec *)); extern void CleanUpIndentStrings ARGS_DECL((void)); extern char *GetIndentString ARGS_DECL((int indent)); extern void DumpIndentString ARGS_DECL((FILE*, int indent)); extern void CleanUpMiniLines ARGS_DECL((void)); extern int InitMiniLines ARGS_DECL((void)); extern void FreeStrSeg ARGS_DECL((StrSegInfo*)); extern void FreeStrBlock ARGS_DECL((StrBlockInfo*)); extern void FreeMiniLine ARGS_DECL((MiniLineInfo*)); extern void FreeMiniLines ARGS_DECL((MiniLinesInfo*, int free_minilines)); extern void FreeStrBlockList ARGS_DECL((StrBlockInfo*)); extern void FreeMiniLineList ARGS_DECL((MiniLineInfo*)); extern void UnlinkStrBlock ARGS_DECL((StrBlockInfo*)); extern void UnlinkMiniLine ARGS_DECL((MiniLineInfo*)); extern StrSegInfo *NewStrSeg ARGS_DECL((void)); extern StrBlockInfo *NewStrBlock ARGS_DECL((void)); extern MiniLineInfo *NewMiniLine ARGS_DECL((void)); extern MiniLinesInfo *NewMiniLines ARGS_DECL((void)); extern void InsertStrBlock ARGS_DECL((StrBlockInfo *pPrevStrBlock, StrBlockInfo *pNextStrBlock, StrBlockInfo *pStrBlock, StrBlockInfo **ppFirstStrBlock, StrBlockInfo **ppLastStrBlock)); extern void InsertMiniLine ARGS_DECL((MiniLineInfo *pPrevMiniLine, MiniLineInfo *pNextMiniLine, MiniLineInfo *pMiniLine, MiniLineInfo **ppFirstMiniLine, MiniLineInfo **ppLastMiniLine)); extern int BlankStrSeg ARGS_DECL((StrSegInfo*)); extern int BlankStrBlock ARGS_DECL((StrBlockInfo*)); extern int BlankMiniLine ARGS_DECL((MiniLineInfo*)); extern int BlankMiniLines ARGS_DECL((MiniLinesInfo*)); extern StrSegInfo *GetTextFirstStrSeg ARGS_DECL((struct ObjRec *)); extern struct DynStrRec *GetTextFirstDynStr ARGS_DECL((struct ObjRec *)); /* ===================== TextRec Routines ===================== */ extern void CopyCurInfoIntoStrSeg ARGS_DECL((StrBlockInfo*, StrSegInfo*)); extern void CopyCurInfoFromStrSeg ARGS_DECL((StrSegInfo*)); extern void CopyCurInfoIntoTextPtr ARGS_DECL((struct ObjRec *, struct TextRec *)); extern void CopyCurInfoFromTextPtr ARGS_DECL((struct ObjRec *, struct TextRec *)); /* ===================== RecalcTextMetrics ===================== */ extern int RecalcMiniLineMetrics ARGS_DECL((MiniLineInfo*, RecalcMetricsInfo*)); extern int RecalcMiniLinesMetrics ARGS_DECL((MiniLinesInfo*, RecalcMetricsInfo*)); extern int RecalcTextMetrics ARGS_DECL((struct TextRec *, int x, int baseline_y)); extern void UpdateMiniLinesBBoxes ARGS_DECL((MiniLinesInfo*, int x, int baseline_y, int clean)); extern void UpdateCurTextBBoxes ARGS_DECL((int clean)); extern void DoFuncOnStrSegForMiniLines ARGS_DECL((MiniLinesInfo*, STRSEGFN*, void*)); /* ===================== Text Routines ===================== */ extern void ResetOnCursorKey ARGS_DECL((int drag)); extern void PutTextCursor ARGS_DECL((void)); extern void EraseTextCursor ARGS_DECL((void)); extern void GetCurTextBBoxes ARGS_DECL((struct BBRec *pOBBox, struct BBRec *pBBox)); extern void PaintMiniLines ARGS_DECL((Display*, Drawable, GC, int depth, int x, int baseline_y, MiniLinesInfo*, int use_highlight, int use_as_mask)); extern void DrawCurTextOutLine ARGS_DECL((int x, int y, int w, int h)); extern void RedrawCurText ARGS_DECL((void)); extern void UpdateHighLightedTextBBoxes ARGS_DECL((int clean)); extern void MergeNextMiniLineWhileDeleting ARGS_DECL((MiniLineInfo*)); extern int StrBlocksHasSameProperties ARGS_DECL((StrBlockInfo*, StrBlockInfo*)); extern int MergeStrBlocks ARGS_DECL((StrBlockInfo *pStrBlock, StrBlockInfo *pNextStrBlock)); extern void DoInsertThinSpace ARGS_DECL((int thin_space_w)); extern void InsertHighlightedThinSpace ARGS_DECL((int thin_space_w)); extern void DeleteHighlightedText ARGS_DECL((void)); extern int ShrinkMiniLines ARGS_DECL((MiniLinesInfo*, int *pnRetry)); extern int GetTextXYInMiniLines ARGS_DECL((MiniLinesInfo*, StrBlockInfo*, int index_to_match, int *pn_dx, int *pn_dy)); extern void GetTextXY ARGS_DECL((StrBlockInfo*, int nIndex, int *pn_x, int *pn_baseline_y)); extern void SetTextCurXY ARGS_DECL((void)); extern void SetTextEndXY ARGS_DECL((void)); extern int CurStrBlockInStrBlock ARGS_DECL((StrBlockInfo*)); extern int CurStrBlockInMiniLine ARGS_DECL((MiniLineInfo*)); extern int CurStrBlockInMiniLines ARGS_DECL((MiniLinesInfo*)); extern int GetCursorPositionInMiniLines ARGS_DECL((MiniLinesInfo*, int dx, int dy, int *pn_dx, int *pn_dy, StrBlockInfo**, int *pnIndex)); extern int SameProperty ARGS_DECL((long lWhich, int nValue, StrSegInfo*, int nCheckDoubleByte)); extern int SetStrSegProperty ARGS_DECL((long lWhich, int nValue, StrSegInfo*)); extern int SetMiniLinesProperty ARGS_DECL((long lWhich, int nValue, MiniLinesInfo*)); extern int ChangeHighlightedTextProperty ARGS_DECL((long lWhich, int nValue)); extern int OnePropertyMiniLines ARGS_DECL((long lWhich, int nValue, MiniLinesInfo*, int nCheckDoubleByte)); extern int SingleFontMiniLines ARGS_DECL((MiniLinesInfo*, int *pnSzUnit, int *pnDoubleByte, int *pnFont, int *pnStyle, int *pnUnderlineOn, int *pnOverlineOn)); extern int SingleFontText ARGS_DECL((struct TextRec*, int *pnSzUnit, int *pnDoubleByte, int *pnFont, int *pnStyle, int *pnUnderlineOn, int *pnOverlineOn)); extern int SingleColorMiniLines ARGS_DECL((MiniLinesInfo*, int *pnColorIndex)); extern int SingleColorText ARGS_DECL((struct TextRec*, int *pnColorIndex)); extern int HighlightedTextHasSameProperty ARGS_DECL((long lWhich, int nValue, int nChkDoubleByte)); extern int CheckMiniLinesProperties ARGS_DECL((MiniLinesInfo*, int *pn_valid, int *pn_font, int *pn_style, int *pn_sz_unit, int *pn_color, int *pn_underline_on, int *pn_overline_on)); extern int CanCopyHighLightedTextAsStrings ARGS_DECL((void)); extern int CanCopyHighLightedTextAsUTF8Strings ARGS_DECL(( int *pn_double_byte_font_index)); extern int CanPasteUTF8StringIntoText ARGS_DECL((StrSegInfo*)); extern void GatherHighLightedTextAsStrings ARGS_DECL((char **ppsz_buf, int *pn_buf_sz)); extern struct ObjRec *CreateTextObjFromHighLightedText ARGS_DECL((void)); extern void ReorderCursorStrBlocks ARGS_DECL((void)); extern int FindStringInMiniLines ARGS_DECL((MiniLinesInfo*, int *pn_found_starting_point, char *str_to_match, int str_len_to_match, int case_sensitive, StrBlockInfo **ppStartStrBlock, int *pn_start_index, StrBlockInfo **ppEndStrBlock, int *pn_end_index)); extern int CanBreakMiniLinesIntoWords ARGS_DECL((MiniLinesInfo*)); extern void BreakMiniLines ARGS_DECL((MiniLinesInfo*, int how, int x, int baseline_y, struct ObjRec *prototype, int tx_to_move, int ty_to_move, ObjListInfo*)); extern void DumpMiniLines ARGS_DECL((MiniLinesInfo*, int x, int baseline_y, FILE*, struct BBRec *, int do_dump, int indent)); extern int SimpleTextObj ARGS_DECL((struct TextRec *)); extern void DumpSimpleTextPath ARGS_DECL((FILE*, struct ObjRec *)); extern void DumpMiniLineInAscii ARGS_DECL((FILE*, MiniLineInfo*, int *pnSomethingPrinted)); extern void DumpMiniLinesInAscii ARGS_DECL((FILE*, MiniLinesInfo*, int *pnSomethingPrinted)); extern char *ConvertMiniLineToString ARGS_DECL((MiniLineInfo*, int *pnNeedToFree)); extern char *ConvertAttrNameFirstMiniLineToString ARGS_DECL(( struct AttrRec *, int *pnNeedToFree)); extern int MiniLinesInVisibleLayer ARGS_DECL((MiniLinesInfo*)); #ifdef _INCLUDE_FROM_MINILINE_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_MINILINE_C_*/ #endif /*_MINILINE_E_*/ �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgtwb5dl.c���������������������������������������������������������������������������0000644�0000764�0000764�00000130266�11602233313�014675� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgtwb5dl.c,v 1.15 2011/05/22 22:55:02 william Exp $ */ #ifndef _NO_TGTWB5 #define _INCLUDE_FROM_TGTWB5DL_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "tidget.h" #include "auxtext.e" #include "cursor.e" #include "dialog.e" #include "file.e" #include "font.e" #include "mainloop.e" #include "msg.e" #include "raster.e" #include "rect.e" #include "scroll.e" #include "setup.e" #include "strtbl.e" #include "tdgtbase.e" #include "tdgtbmpl.e" #include "tdgtbrow.e" #include "tdgtbtn.e" #include "tdgtdraw.e" #include "tdgtsedt.e" #include "tdgtlist.e" #include "tdgtmsg.e" #include "text.e" #include "tidget.e" #include "tgtwb5dl.e" #include "tgtwb5xl.e" #include "util.e" #include "xbitmap.e" ZyfhInfo gZyfhInfo; typedef struct tagZyfhDlgInfo { Window parent_win; /* should be the rootWindow */ TdgtMsg *msg_ctl; TdgtDraw *zyfh_ctl; /* the zhu-yin-fu-hao keypad */ TdgtDraw *zyfh_dpy_ctl; /* displays what has been entered */ TdgtSmplEdit *edit_ctl; TdgtBmpList *bmp_list_ctl; TdgtBtnRow *btn_row_ctl; int screen_w, screen_h; int base_win_w, base_win_h; int msg_x, msg_y, msg_w, msg_h; int zyfh_dpy_x, zyfh_dpy_y, zyfh_dpy_w, zyfh_dpy_h; int zyfh_x, zyfh_y, zyfh_w, zyfh_h; int edit_x, edit_y, edit_w, edit_h; int bmp_list_x, bmp_list_y, bmp_list_w, bmp_list_h; int btn_row_x, btn_row_y, btn_row_w, btn_row_h; char **entries; int num_entries; int first_index; int marked_index; DspList *dsp_ptr; char *title_str, *formatted_title_str; int def_btn_id, double_click_btn_id; Time last_click_time; int last_selected; int just_fetched; int english_spelling; /* TRUE means pinyin, FALSE means zhu-yin-fu-hao */ int zyfh_spell_index; int zyfh_spell_buf[MAXZYFH_CHARS+1]; /* each char is one of PH_* */ } ZyfhDlgInfo; /* --------------------- Utility Functions --------------------- */ typedef struct tagZyfhDpyAppendInfo { TdgtBase *base_ctl; int row, col; /* position in zyfh_ctl */ } ZyfhDpyAppendInfo; #define TDGTARG_ZYFH_DPY_CLEAR 1 /* pv_cmd_userdata is NULL */ #define TDGTARG_ZYFH_DPY_APPEND 2 /* pv_cmd_userdata is (ZyfhDpyAppendInfo*) */ static void ClearAllControls(pTdgtBase) TdgtBase *pTdgtBase; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); pzdi->last_selected = INVALID; pzdi->just_fetched = FALSE; pzdi->zyfh_spell_index = 0; memset(pzdi->zyfh_spell_buf, 0, sizeof(pzdi->zyfh_spell_buf)); TidgetSendCmd(pzdi->zyfh_dpy_ctl->pti, TDGTCMD_DRAW_USER, TDGTARG_ZYFH_DPY_CLEAR, pTdgtBase); TdgtSmplEditSetText(pzdi->edit_ctl, ""); TidgetSendCmd(pzdi->bmp_list_ctl->pti, TDGTCMD_LIST_RESETCONTENT, 0, NULL); } static int SendSelectedCharToClient(pTdgtBase) TdgtBase *pTdgtBase; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); int selected_index=INVALID; BmpListItemInfo *pblii=NULL; TidgetSendCmd(pzdi->bmp_list_ctl->pti, TDGTCMD_LIST_GETCURSEL, 0, &selected_index); if (TidgetSendCmd(pzdi->bmp_list_ctl->pti, TDGTCMD_LIST_GETITEM, selected_index, &pblii)) { if (pblii != NULL) { XKeyEvent key_ev; int has_ch=2; char buf[3]; XChar2b *pch16=(XChar2b*)(pblii->pv_userdata); memset(&key_ev, 0, sizeof(XKeyEvent)); buf[0] = pch16->byte1; buf[1] = pch16->byte2; buf[2] = '\0'; HandleTextFromBuffer(&key_ev, buf, (KeySym)0, has_ch); return TRUE; } } return FALSE; } static int SendCRToClient(pTdgtBase) TdgtBase *pTdgtBase; { XKeyEvent key_ev; int has_ch=1; char buf[2]; memset(&key_ev, 0, sizeof(XKeyEvent)); buf[0] = '\n'; buf[1] = '\0'; HandleTextFromBuffer(&key_ev, buf, (KeySym)0, has_ch); return TRUE; } static int InvalidSequence(pTdgtBase) TdgtBase *pTdgtBase; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); if (pzdi->zyfh_spell_index == 4 && (pzdi->zyfh_spell_buf[0] == PH_L || pzdi->zyfh_spell_buf[0] == PH_N) && pzdi->zyfh_spell_buf[1] == PH_Yu && pzdi->zyfh_spell_buf[3] < PH_Er && pzdi->zyfh_spell_buf[2] != PH_Eh) { return TRUE; } return FALSE; } static int Fill2ByteCharFromHexStringBuf(buf, pch16) char *buf; XChar2b *pch16; { int hi_nibble=0, lo_nibble=0, hval=0; if (IsHex(buf[0], &hi_nibble) && IsHex(buf[1], &lo_nibble)) { hval = (((hi_nibble&0x0ff)<<4)+(lo_nibble&0x0ff)); pch16->byte1 = hval; if (IsHex(buf[2], &hi_nibble) && IsHex(buf[3], &lo_nibble)) { hval = (((hi_nibble&0x0ff)<<4)+(lo_nibble&0x0ff)); pch16->byte2 = hval; } else { return FALSE; } } else { return FALSE; } return TRUE; } static void FreeBitmapItemCallback(pblii) BmpListItemInfo *pblii; { if (pblii == NULL) return; if (pblii->pixmap != None) XFreePixmap(mainDisplay, pblii->pixmap); if (pblii->pv_userdata != NULL) { /* XChar2b */ free(pblii->pv_userdata); } free(pblii); } #ifdef NOT_DEFINED /* debug, do not translate */ static void DebugCharBitmap(bitmap, w, h) Pixmap bitmap; int w, h; { static int n=0; int r=0, c=0; XImage *image=XGetImage(mainDisplay, bitmap, 0, 0, w, h, 1, ZPixmap); fprintf(stdout, "Character %1d:\n", ++n); for (r=0; r < h; r++) { fprintf(stdout, " "); for (c=0; c < w; c++) { if (XGetPixel(image, (int)c, (int)r) == 1) { fprintf(stdout, "%1d", 1); } else { fprintf(stdout, "%1d", 0); } } fprintf(stdout, "\n"); } XDestroyImage(image); } void DrawAndDebugChar() { XChar2b str16; XGCValues values; GC tmp_gc; Pixmap bitmap=XCreatePixmap(mainDisplay, mainWindow, gZyfhInfo.b5_font_w, gZyfhInfo.b5_font_h, 1); values.foreground = 1; values.background = 0; values.fill_style = FillSolid; values.function = GXcopy; values.font = gZyfhInfo.xfs->fid; tmp_gc = XCreateGC(mainDisplay, bitmap, GCForeground | GCBackground | GCFillStyle | GCFunction | GCFont, &values); XSetForeground(mainDisplay, tmp_gc, 0); XFillRectangle(mainDisplay, bitmap, tmp_gc, 0, 0, gZyfhInfo.b5_font_w, gZyfhInfo.b5_font_h); XSetForeground(mainDisplay, tmp_gc, 1); switch (gZyfhInfo.b5_font_real_encoding) { case GB_ENCODING: str16.byte1 = 0xb9 & 0x7f; str16.byte2 = 0xfa & 0x7f; break; case BIG5_ENCODING: str16.byte1 = 0xa4; str16.byte2 = 0xad; break; } XDrawString16(mainDisplay, bitmap, tmp_gc, 0, gZyfhInfo.b5_font_asc, &str16, 1); DebugCharBitmap(bitmap, gZyfhInfo.b5_font_w, gZyfhInfo.b5_font_h); XFreeGC(mainDisplay, tmp_gc); XFreePixmap(mainDisplay, bitmap); } #endif /* NOT_DEFINED */ static int DoLoadChars(pTdgtBase, buf, str16, num_char2bs) TdgtBase *pTdgtBase; char *buf; XChar2b *str16; int num_char2bs; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); int i=0, redraw_disabled=FALSE; TidgetSendCmd(pzdi->bmp_list_ctl->pti, TDGTCMD_LIST_RESETCONTENT, 0, NULL); redraw_disabled = TidgetDisableRedraw(pzdi->bmp_list_ctl->pti, TRUE); for (i=0; i < num_char2bs; i++) { XGCValues values; Pixmap bitmap=None; BmpListItemInfo *pblii=NULL; XChar2b *pch16=NULL; XChar2b str16_buf; bitmap = XCreatePixmap(mainDisplay, mainWindow, gZyfhInfo.b5_font_w, gZyfhInfo.b5_font_h, 1); if (bitmap == None) { FailAllocPixmapMessage(gZyfhInfo.b5_font_w, gZyfhInfo.b5_font_h); } XSetForeground(mainDisplay, rotateGC, 0); XFillRectangle(mainDisplay, bitmap, rotateGC, 0, 0, gZyfhInfo.b5_font_w, gZyfhInfo.b5_font_h); values.foreground = 1; values.font = gZyfhInfo.xfs->fid; XChangeGC(mainDisplay, rotateGC, GCForeground | GCFont, &values); if (gZyfhInfo.b5_font_mod_bytes) { str16_buf.byte1 = str16[i].byte1 & 0x7f; str16_buf.byte2 = str16[i].byte2 & 0x7f; } else { str16_buf.byte1 = str16[i].byte1; str16_buf.byte2 = str16[i].byte2; } XDrawString16(mainDisplay, bitmap, rotateGC, 0, gZyfhInfo.b5_font_asc, &str16_buf, 1); #ifdef NOT_DEFINED DebugCharBitmap(bitmap, gZyfhInfo.b5_font_w, gZyfhInfo.b5_font_h); #endif /* NOT_DEFINED */ pch16 = (XChar2b*)malloc(sizeof(XChar2b)); if (pch16 == NULL) FailAllocMessage(); memset(pch16, 0, sizeof(XChar2b)); memcpy(pch16, &str16[i], sizeof(XChar2b)); pblii = (BmpListItemInfo*)malloc(sizeof(BmpListItemInfo)); if (pblii == NULL) FailAllocMessage(); memset(pblii, 0, sizeof(BmpListItemInfo)); pblii->pixmap = bitmap; pblii->depth = 1; pblii->width = gZyfhInfo.b5_font_w; pblii->height = gZyfhInfo.b5_font_h; pblii->pv_userdata = pch16; pblii->pf_free_callback = FreeBitmapItemCallback; if (!TdgtBmpListAddItem(pzdi->bmp_list_ctl, pblii)) { } } TidgetDisableRedraw(pzdi->bmp_list_ctl->pti, redraw_disabled); return TRUE; } #define MAX_PINYIN_ET_BIG5_STR 628 #define MAX_BIG5_STR (MAX_PINYIN_ET_BIG5_STR>>2) static int LoadChars(pTdgtBase, buf) TdgtBase *pTdgtBase; char *buf; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); int len=0, str16_index=0, ok=TRUE; char *psz=NULL, **ppsz=NULL, *psz_found=NULL; XChar2b str16[MAX_BIG5_STR+1]; if (!pzdi->english_spelling && InvalidSequence(pTdgtBase)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PINYIN_SEQ), buf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } switch (gZyfhInfo.b5_font_real_encoding) { case GB_ENCODING: for (ppsz=pinyin_gb2312; *ppsz!=NULL; ppsz++) { if (strcmp(*ppsz, buf) == 0) { psz_found = (*(++ppsz)); break; } ppsz++; } break; case BIG5_ENCODING: for (ppsz=pinyin_et_big5; *ppsz!=NULL; ppsz++) { if (strcmp(*ppsz, buf) == 0) { psz_found = (*(++ppsz)); break; } ppsz++; } break; default: return FALSE; } if (psz_found == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PINYIN_SEQ), buf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } len = strlen(psz_found); #ifdef _TGIF_DBG /* debug, do not translate */ if (len > MAX_PINYIN_ET_BIG5_STR) { sprintf(gszMsgBox, "Fetched hexstring in LoadChars() is too long: %1d (limit is %1d).\n", len, MAX_PINYIN_ET_BIG5_STR); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } #endif /* _TGIF_DBG */ for (psz=psz_found; ok && *psz != '\0'; psz=(&psz[4])) { if (Fill2ByteCharFromHexStringBuf(psz, &str16[str16_index])) { str16_index++; } else { ok = FALSE; } } memset(&str16[str16_index], 0, sizeof(XChar2b)); #ifdef _TGIF_DBG /* debug, do not translate */ if (!ok) { switch (gZyfhInfo.b5_font_real_encoding) { case GB_ENCODING: sprintf(gszMsgBox, "The pinyin_gb2312[] table seems to be corrupted.\n"); break; case BIG5_ENCODING: sprintf(gszMsgBox, "The pinyin_et_big5[] table seems to be corrupted.\n"); break; } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } #endif /* _TGIF_DBG */ return DoLoadChars(pTdgtBase, buf, str16, str16_index); } static int FetchChars(pTdgtBase) TdgtBase *pTdgtBase; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); char *buf=UtilStrDup(TdgtSmplEditGetText(pzdi->edit_ctl)); if (buf != NULL && *buf != '\0') { char saved_ch='\0'; int ok=FALSE; if (buf[0] >= 'a' && buf[0] <= 'z') { saved_ch = buf[0]; buf[0] = buf[0]-'a'+'A'; } ok = LoadChars(pTdgtBase, buf); if (saved_ch != '\0') buf[0] = saved_ch; } pzdi->just_fetched = TRUE; pzdi->last_selected = INVALID; UtilFree(buf); return FALSE; } static void ReverseZhuYenFuHao(index, pn_symbol_ltx, pn_symbol_lty) int index, *pn_symbol_ltx, *pn_symbol_lty; /* * Given an index obtained from pzdi->zyfh_spell_buf[x], calculate * the ltx and lty of a bitmap from the zhfh_ctl. */ { if (pn_symbol_lty != NULL) { *pn_symbol_lty = (index % (gZyfhInfo.zyfh_num_rows)) * (gZyfhInfo.zyfh_image_wh); } if (pn_symbol_ltx != NULL) { *pn_symbol_ltx = ((int)(index / gZyfhInfo.zyfh_num_rows)) * (gZyfhInfo.zyfh_image_wh); } } static int ComposePinYin(pTdgtBase, buf, buf_sz) TdgtBase *pTdgtBase; char *buf; int buf_sz; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); int i=0; if (buf_sz < MAXZYFH_CHARS+1) return FALSE; *buf = '\0'; for (i=0; i < pzdi->zyfh_spell_index; i++) { switch (i) { case 0: if (pzdi->zyfh_spell_index >= 2 && pzdi->zyfh_spell_buf[0] == PH_Yu && pzdi->zyfh_spell_buf[1] == PH_Eng) { strcat (buf, "Yo"); } else { strcpy(buf, firstLargeTransTbl[pzdi->zyfh_spell_buf[0]]); if (pzdi->zyfh_spell_index == 2 && pzdi->zyfh_spell_buf[1] < PH_Er) { strcat(buf, singleExtention[pzdi->zyfh_spell_buf[0]]); } } break; case 1: if (pzdi->zyfh_spell_index >= 3 && pzdi->zyfh_spell_buf[1] == PH_W && pzdi->zyfh_spell_buf[2] == PH_Eng) { strcat(buf, "o"); } else if (pzdi->zyfh_spell_index >= 3 && pzdi->zyfh_spell_buf[1] == PH_Yu && pzdi->zyfh_spell_buf[2] == PH_Eng) { strcat(buf, "io"); } else if (pzdi->zyfh_spell_index >= 2 && pzdi->zyfh_spell_buf[0] == PH_Yu && pzdi->zyfh_spell_buf[1] == PH_Eng) { strcat(buf, "ng"); } else if (pzdi->zyfh_spell_index >= 2 && pzdi->zyfh_spell_buf[0] == PH_Y && pzdi->zyfh_spell_buf[1] == PH_En) { strcat(buf, "in"); } else if (pzdi->zyfh_spell_index >= 2 && pzdi->zyfh_spell_buf[0] == PH_Y && pzdi->zyfh_spell_buf[1] == PH_Eng) { strcat(buf, "ing"); } else { strcat(buf, secondLargeTransTbl[pzdi->zyfh_spell_buf[i]]); } break; case 2: if (pzdi->zyfh_spell_index == 3 && pzdi->zyfh_spell_buf[2] < PH_Er && pzdi->zyfh_spell_buf[1] == PH_Yu && (pzdi->zyfh_spell_buf[0] == PH_L || pzdi->zyfh_spell_buf[0] == PH_N)) { strcat(buf, ":"); } strcat(buf, thirdLargeTransTbl[pzdi->zyfh_spell_buf[i]]); break; case 3: if (pzdi->zyfh_spell_index == 4 && pzdi->zyfh_spell_buf[3] < PH_Er && pzdi->zyfh_spell_buf[2] == PH_Eh && pzdi->zyfh_spell_buf[1] == PH_Yu && (pzdi->zyfh_spell_buf[0] == PH_L || pzdi->zyfh_spell_buf[0] == PH_N)) { strcat(buf, ":"); } strcat(buf, fourthLargeTransTbl[pzdi->zyfh_spell_buf[i]]); break; } } return TRUE; } static void UpdateSpellingAndDpyControls(pTdgtBase) TdgtBase *pTdgtBase; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); char buf[MAXZYFH_CHARS+1]; int fetch_immediately=FALSE; if (ComposePinYin(pTdgtBase, buf, sizeof(buf))) { int len=strlen(buf); TdgtSmplEditSetText(pzdi->edit_ctl, buf); if (!pzdi->english_spelling && pzdi->zyfh_spell_index == 1 && (strcmp(buf, "Punctuations") == 0 || strcmp(buf, "Symbols") == 0)) { fetch_immediately = TRUE; } else if (len > 0 && buf[len-1] >= '1' && buf[len-1] <= '5') { fetch_immediately = TRUE; } } RedrawTidget(pzdi->zyfh_dpy_ctl->pti); if (fetch_immediately) { FetchChars(pTdgtBase); } } static int HandleBackSpace(pTdgtBase) TdgtBase *pTdgtBase; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); if (pzdi->english_spelling) { if (TdgtSmplEditDelLastChar(pzdi->edit_ctl)) { pzdi->just_fetched = FALSE; pzdi->zyfh_spell_index--; pzdi->last_selected = INVALID; TidgetSendCmd(pzdi->bmp_list_ctl->pti, TDGTCMD_LIST_RESETCONTENT, 0, NULL); } else { /* no change */ } } else { if (pzdi->zyfh_spell_index > 0) { pzdi->just_fetched = FALSE; pzdi->zyfh_spell_index--; pzdi->last_selected = INVALID; UpdateSpellingAndDpyControls(pTdgtBase); TidgetSendCmd(pzdi->bmp_list_ctl->pti, TDGTCMD_LIST_RESETCONTENT, 0, NULL); } else { /* no change */ } } return FALSE; } /* --------------------- ZyfhRedrawCallback --------------------- */ static int ZyfhRedrawCallback(pTdgtDraw) TdgtDraw *pTdgtDraw; { XGCValues values; if (pTdgtDraw == NULL) return FALSE; values.fill_style = FillOpaqueStippled; values.ts_x_origin = pTdgtDraw->client_area.x; values.ts_y_origin = pTdgtDraw->client_area.y; values.stipple = gZyfhInfo.zyfh_bitmap; XChangeGC(mainDisplay, gTidgetManager.gc, GCFillStyle | GCTileStipXOrigin | GCTileStipYOrigin | GCStipple, &values); XFillRectangle(mainDisplay, pTdgtDraw->pti->tci.win, gTidgetManager.gc, pTdgtDraw->client_area.x, pTdgtDraw->client_area.y, pTdgtDraw->client_area.w, pTdgtDraw->client_area.h); TidgetManagerResetGC(); return TRUE; } /* --------------------- ZyfhEvHandlerCallback() --------------------- */ static int GetZhuYenFuHao(pTdgtDraw, button_x, button_y, pn_symbol_ltx, pn_symbol_lty) TdgtDraw *pTdgtDraw; int button_x, button_y, *pn_symbol_ltx, *pn_symbol_lty; { struct BBRec bbox; int x=0, y=0, row=0, col=0; bbox.ltx = pTdgtDraw->client_area.x; bbox.lty = pTdgtDraw->client_area.y; bbox.rbx = pTdgtDraw->client_area.x + pTdgtDraw->client_area.w; bbox.rby = pTdgtDraw->client_area.y + pTdgtDraw->client_area.h; if (!PointInBBox(button_x, button_y, bbox)) return INVALID; x = button_x-pTdgtDraw->client_area.x; y = button_y-pTdgtDraw->client_area.y; row = (int)(y/gZyfhInfo.zyfh_image_wh); col = (int)(x/gZyfhInfo.zyfh_image_wh); if (pn_symbol_ltx != NULL) { *pn_symbol_ltx = col*gZyfhInfo.zyfh_image_wh + pTdgtDraw->client_area.x; } if (pn_symbol_lty != NULL) { *pn_symbol_lty = row*gZyfhInfo.zyfh_image_wh + pTdgtDraw->client_area.y; } return ((col*gZyfhInfo.zyfh_num_rows)+row); } static int ClickInZyfh(pTdgtDraw, button_ev) TdgtDraw *pTdgtDraw; XButtonEvent *button_ev; { TdgtBase *pTdgtBase= (TdgtBase*)(pTdgtDraw->pti->tci.parent_tidgetinfo->tidget); ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); int down_ltx=0, down_lty=0, down_index=0, inside=TRUE, highlighted=TRUE; char *psz=NULL; down_index = GetZhuYenFuHao(pTdgtDraw, button_ev->x, button_ev->y, &down_ltx, &down_lty); if (down_index == INVALID) return FALSE; switch (pzdi->zyfh_spell_index) { case 0: psz=firstLargeTransTbl[down_index]; break; case 1: psz=secondLargeTransTbl[down_index]; break; case 2: psz=thirdLargeTransTbl[down_index]; break; case 3: psz=fourthLargeTransTbl[down_index]; break; } if (*psz != '\0') { /* clicked on a symbol */ XFillRectangle(mainDisplay, pTdgtDraw->pti->tci.win, revDefaultGC, down_ltx, down_lty, gZyfhInfo.zyfh_image_wh, gZyfhInfo.zyfh_image_wh); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, pTdgtDraw->pti->tci.win, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, defaultCursor, CurrentTime); } while (TRUE) { XEvent xev; XNextEvent(mainDisplay, &xev); if (xev.type == Expose) { ExposeEventHandler(&xev, FALSE); } else if (xev.type == ButtonRelease) { int up_index=0, up_ltx=0, up_lty=0; XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); up_index = GetZhuYenFuHao(pTdgtDraw, xev.xbutton.x, xev.xbutton.y, &up_ltx, &up_lty); if (up_index == down_index) { if (highlighted) { XFillRectangle(mainDisplay, pTdgtDraw->pti->tci.win, revDefaultGC, down_ltx, down_lty, gZyfhInfo.zyfh_image_wh, gZyfhInfo.zyfh_image_wh); highlighted = FALSE; } pzdi->zyfh_spell_buf[pzdi->zyfh_spell_index++] = down_index; UpdateSpellingAndDpyControls(pTdgtBase); } break; } else if (xev.type == MotionNotify) { int mouse_index=0, mouse_ltx=0, mouse_lty=0; XEvent tmp_xev; while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &tmp_xev)) ; mouse_index = GetZhuYenFuHao(pTdgtDraw, xev.xmotion.x, xev.xmotion.y, &mouse_ltx, &mouse_lty); if (inside) { if (mouse_index != down_index) { XFillRectangle(mainDisplay, pTdgtDraw->pti->tci.win, revDefaultGC, down_ltx, down_lty, gZyfhInfo.zyfh_image_wh, gZyfhInfo.zyfh_image_wh); highlighted = !highlighted; inside = FALSE; } } else { if (mouse_index == down_index) { XFillRectangle(mainDisplay, pTdgtDraw->pti->tci.win, revDefaultGC, down_ltx, down_lty, gZyfhInfo.zyfh_image_wh, gZyfhInfo.zyfh_image_wh); highlighted = !highlighted; inside = TRUE; } } } } } return FALSE; } static int ZyfhEvHandlerCallback(pTdgtDraw, pXEv) TdgtDraw *pTdgtDraw; XEvent *pXEv; { if (pXEv->xany.window == pTdgtDraw->pti->tci.win) { static char ppsz_buf[MAX_STATUS_BTNS+1][MAXSTRING+1]; static int one_line_status=TRUE; if (pXEv->type == EnterNotify) { SaveStatusStringsIntoBuf(ppsz_buf, &one_line_status); SetMouseStatus(TgLoadString(STID_ADD_ZYFH), TgLoadString(STID_FETCH_CHAR), TgLoadString(STID_BACKOUT_ZYFH)); } else if (pXEv->type == LeaveNotify) { RestoreStatusStringsFromBuf(ppsz_buf, one_line_status); } else if (pXEv->type == ButtonPress) { XButtonEvent *button_ev=(&(pXEv->xbutton)); TdgtBase *pTdgtBase= (TdgtBase*)(pTdgtDraw->pti->tci.parent_tidgetinfo->tidget); ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); switch (button_ev->button) { case Button1: if (pzdi->english_spelling) { pzdi->english_spelling = FALSE; pzdi->zyfh_spell_index = 0; } if (pzdi->just_fetched) { ClearAllControls(pTdgtBase); } if (pzdi->zyfh_spell_index >= MAXZYFH_CHARS) { XBell(mainDisplay, 0); } else { return ClickInZyfh(pTdgtDraw, button_ev); } break; case Button2: if (pzdi->just_fetched) { return SendSelectedCharToClient(pTdgtBase); } else { return FetchChars(pTdgtBase); } break; case Button3: return HandleBackSpace(pTdgtBase); } } } return FALSE; } /* --------------------- ZyfhDpyRedrawCallback --------------------- */ static int ZyfhDpyRedrawCallback(pTdgtDraw) TdgtDraw *pTdgtDraw; /* redraw the vertical display area on the left top area */ { TdgtBase *pTdgtBase= (TdgtBase*)(pTdgtDraw->pti->tci.parent_tidgetinfo->tidget); ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); if (pTdgtDraw == NULL) return FALSE; if (pzdi->english_spelling) { /* leave it blank if pinyin is used */ } else { int i=0, x=pTdgtDraw->client_area.x, y=pTdgtDraw->client_area.y; if (pzdi->zyfh_spell_index == 0) return FALSE; for (i=0; i < pzdi->zyfh_spell_index; i++, y+=gZyfhInfo.zyfh_image_wh) { int src_x=0, src_y=0; XGCValues values; values.fill_style = FillSolid; values.function = GXcopy; XChangeGC(mainDisplay, gTidgetManager.gc, GCFillStyle | GCFunction, &values); ReverseZhuYenFuHao(pzdi->zyfh_spell_buf[i], &src_x, &src_y); XCopyArea(mainDisplay, gZyfhInfo.zyfh_bitmap, gZyfhInfo.symbol_bitmap, xbmGC, src_x, src_y, gZyfhInfo.zyfh_image_wh, gZyfhInfo.zyfh_image_wh, 0, 0); values.fill_style = FillStippled; values.ts_x_origin = x; values.ts_y_origin = y; values.stipple = gZyfhInfo.symbol_bitmap; XChangeGC (mainDisplay, gTidgetManager.gc, GCFillStyle | GCTileStipXOrigin | GCTileStipYOrigin | GCStipple, &values); XFillRectangle(mainDisplay, pTdgtDraw->pti->tci.win, gTidgetManager.gc, x, y, gZyfhInfo.zyfh_image_wh, gZyfhInfo.zyfh_image_wh); TidgetManagerResetGC(); } } return TRUE; } /* --------------------- ZyfhDpySendCmdCallback --------------------- */ static int ZyfhDpySendCmdCallback(pTdgtDraw, cmd_type, cmd_arg, pv_cmd_userdata) TdgtDraw *pTdgtDraw; int cmd_type, cmd_arg; void *pv_cmd_userdata; { TdgtBase *pTdgtBase=NULL; ZyfhDlgInfo *pzdi=NULL; switch (cmd_type) { case TDGTCMD_DRAW_USER: switch (cmd_arg) { case TDGTARG_ZYFH_DPY_CLEAR: pTdgtBase = (TdgtBase*)pv_cmd_userdata; pzdi = (ZyfhDlgInfo*)(pTdgtBase->pti->userdata); /* clear it */ RedrawTidget(pzdi->zyfh_dpy_ctl->pti); break; case TDGTARG_ZYFH_DPY_APPEND: break; } break; } return FALSE; } /* ------------------- Tdgtb5DlgKeyPressEvHandlerCallback ------------------- */ static int HandleCursorKey(pTdgtBase, key_sym) TdgtBase *pTdgtBase; KeySym key_sym; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); int cmd_arg=0; switch (key_sym) { case XK_Up: cmd_arg=TDGTARG_MOVE_UP; break; case XK_KP_Up: cmd_arg=TDGTARG_MOVE_UP; break; case XK_Down: cmd_arg=TDGTARG_MOVE_DOWN; break; case XK_KP_Down: cmd_arg=TDGTARG_MOVE_DOWN; break; case XK_Left: cmd_arg=TDGTARG_MOVE_LEFT; break; case XK_KP_Left: cmd_arg=TDGTARG_MOVE_LEFT; break; case XK_Right: cmd_arg=TDGTARG_MOVE_RIGHT; break; case XK_KP_Right: cmd_arg=TDGTARG_MOVE_RIGHT; break; default: switch (key_sym & 0x0ff) { case 'n': cmd_arg=TDGTARG_MOVE_RIGHT; break; case 'N': cmd_arg=TDGTARG_MOVE_RIGHT; break; case 'f': cmd_arg=TDGTARG_MOVE_RIGHT; break; case 'F': cmd_arg=TDGTARG_MOVE_RIGHT; break; case 'p': cmd_arg=TDGTARG_MOVE_LEFT; break; case 'P': cmd_arg=TDGTARG_MOVE_LEFT; break; case 'b': cmd_arg=TDGTARG_MOVE_LEFT; break; case 'B': cmd_arg=TDGTARG_MOVE_LEFT; break; default: return FALSE; } break; } TidgetSendCmd(pzdi->bmp_list_ctl->pti, TDGTCMD_LIST_SEL_NEXT, cmd_arg, NULL); return FALSE; } static int HandleChar(pTdgtBase, key_sym, buf, has_ch) TdgtBase *pTdgtBase; KeySym key_sym; char *buf; int has_ch; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); if (!pzdi->english_spelling) { pzdi->english_spelling = TRUE; ClearAllControls((TdgtBase*)(gZyfhInfo.dialogbox_tidgetinfo->tidget)); } if (pzdi->just_fetched) { ClearAllControls((TdgtBase*)(gZyfhInfo.dialogbox_tidgetinfo->tidget)); } TdgtSmplEditAppendStr(pzdi->edit_ctl, buf, 1); return FALSE; } static XComposeStatus c_stat; static int Tdgtb5DlgKeyPressEvHandlerCallback(pTdgtBase, pXEv) TdgtBase *pTdgtBase; XEvent *pXEv; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); int has_ch=0; char buf[80]; KeySym key_sym=(KeySym)0; XKeyEvent *key_ev=NULL; if (pXEv->type != KeyPress) return FALSE; if (pzdi == NULL) return FALSE; key_ev = (&(pXEv->xkey)); has_ch = XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); TranslateKeys(buf, &key_sym); if (CharIsESC(key_ev, buf, key_sym, &has_ch)) { HideTdgtb5DialogBox(); } else if (CharIsCRorLF(key_ev, buf, key_sym, &has_ch)) { if (pzdi->just_fetched) { return SendSelectedCharToClient(pTdgtBase); } else { return FetchChars(pTdgtBase); } } else if (CharIsCntrlSpace(key_ev, buf, key_sym, &has_ch)) { HideTdgtb5DialogBox(); } else if (CharIsBS(key_ev, buf, key_sym, &has_ch, FALSE)) { return HandleBackSpace(pTdgtBase); } else if (key_sym==XK_Up || key_sym==XK_KP_Up || key_sym==XK_Down || key_sym==XK_KP_Down || key_sym==XK_Left || key_sym==XK_KP_Left || key_sym==XK_Right || key_sym==XK_KP_Right || (key_sym>'\040' && key_sym<='\177' && (key_ev->state & ControlMask) == ControlMask)) { return HandleCursorKey(pTdgtBase, key_sym); } else if (key_sym>='\040' && key_sym<='\177') { return HandleChar(pTdgtBase, key_sym, buf, has_ch); } return FALSE; } /* --------------------- Tdgtb5DlgWmDeleteCallback --------------------- */ static void Tdgtb5DlgWmDeleteCallback(pTdgtBase) TdgtBase *pTdgtBase; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); if (pzdi == NULL) return; HideTdgtb5DialogBox(); } /* --------------------- Tdgtb5DlgSetMsg --------------------- */ static int Tdgtb5DlgSetMsg(pti, msg) TidgetInfo *pti; char *msg; { return TRUE; } /* --------------------- Tdgtb5DlgSetEntries --------------------- */ static int Tdgtb5DlgSetEntries(pti, dsp_ptr, entries, num_entries, marked_index) TidgetInfo *pti; DspList *dsp_ptr; char **entries; int num_entries, marked_index; { return TRUE; } /* --------------------- InitTdgtb5DlgInfo --------------------- */ static void InitTdgtb5DlgInfo(pti) TidgetInfo *pti; { ZyfhDlgInfo *pzdi=NULL; if (pti == NULL) return; pzdi = (ZyfhDlgInfo*)(pti->userdata); if (pzdi == NULL) return; pzdi->num_entries = INVALID; pzdi->first_index = INVALID; pzdi->marked_index = INVALID; pzdi->screen_w = DisplayWidth(mainDisplay, mainScreen); pzdi->screen_h = DisplayHeight(mainDisplay, mainScreen); Tdgtb5DlgSetMsg(pti, ""); pzdi->def_btn_id = BUTTON_OK; pzdi->double_click_btn_id = BUTTON_OK; } /* --------------------- ShowTdgtb5DialogBox --------------------- */ void ShowTdgtb5DialogBox() { TidgetInfo *pti=gZyfhInfo.dialogbox_tidgetinfo; ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pti->userdata); TidgetManagerSetWantAllKeyPressEvents(pti, TRUE); gZyfhInfo.mapped = TRUE; MapTidget(pti); if (pzdi != NULL) { ClearAllControls((TdgtBase*)(pti->tidget)); pzdi->english_spelling = FALSE; } } /* --------------------- HideTdgtb5DialogBox --------------------- */ void HideTdgtb5DialogBox() { TidgetManagerSetWantAllKeyPressEvents(NULL, FALSE); gZyfhInfo.mapped = FALSE; XUnmapWindow(mainDisplay, gZyfhInfo.dialogbox_tidgetinfo->tci.win); if (warpToWinCenter) { XWarpPointer(mainDisplay, None, drawWindow, 0, 0, 0, 0, (int)(ZOOMED_SIZE(drawWinW)>>1), (int)(ZOOMED_SIZE(drawWinH)>>1)); } } /* --------------------- CreateTdgtb5DialogBox --------------------- */ typedef struct tagCreateBtnInfo { char *text; int ctl_id; int cstid; int msg_id; } CreateBtnInfo; #define NUM_ZHFH_BUTTONS 4 static CreateBtnInfo cbi[NUM_ZHFH_BUTTONS]={ { "Fetch", ID_ZYFH_BTN_FETCH, FALSE, STID_FETCH_CHARS_FROM_DB }, { "Send", ID_ZYFH_BTN_SEND, FALSE, STID_SEND_SEL_CHAR_TO_DRAWING_AREA }, { "<CR>", ID_ZYFH_BTN_CR, FALSE, STID_SEND_CR_TO_DRAWING_AREA }, { "Close", ID_ZYFH_BTN_CLOSE, TRUE, CSTID_CLOSE } }; static int CreateTgtwb5Buttons(pTdgtBase) TdgtBase *pTdgtBase; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); TdgtBtnRow *pTdgtBtnRow=pzdi->btn_row_ctl; int i=0; for (i=0; i < NUM_ZHFH_BUTTONS; i++) { TdgtBtn *pTdgtBtn=NULL; MouseOverStatusInfo mosi; int btn_w=0, btn_h=0; memset(&mosi, 0, sizeof(MouseOverStatusInfo)); mosi.one_line_status = TRUE; UtilStrCpyN(mosi.one_line_str, sizeof(mosi.one_line_str), cbi[i].cstid ? TgLoadCachedString(cbi[i].msg_id) : TgLoadString(cbi[i].msg_id)); CalcTdgtBtnDim(cbi[i].text, 8, TDGTBTN_DEF_H_PAD, TDGTBTN_DEF_V_PAD, &btn_w, &btn_h); pTdgtBtn = CreateTdgtBtn(pTdgtBtnRow->pti->tci.win, pTdgtBtnRow->pti, cbi[i].ctl_id, 0, 0, btn_w, btn_h, TDGTBTN_DEF_H_PAD, TDGTBTN_DEF_V_PAD, TGMUTYPE_TEXT, TDGTBTN_CLICK, TGBS_NORMAL, STYLE_NR, cbi[i].text, &mosi); if (pTdgtBtn == NULL) { DestroyTidget(&pTdgtBase->pti); return FALSE; } if (!TdgtBtnRowAddBtn(pTdgtBtnRow, pTdgtBtn)) { DestroyTidget(&pTdgtBase->pti); return FALSE; } } return TRUE; } static void AdjustDialogBoxWidth(dpy, pTdgtBase) Display *dpy; TdgtBase *pTdgtBase; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); int max_w=0, bottom=0, h_pad=pTdgtBase->pti->tci.h_pad; int v_pad=pTdgtBase->pti->tci.v_pad; SimpleWinInfo *pswi=NULL; if (pzdi->msg_ctl != NULL) { pswi = (&(pzdi->msg_ctl->pti->tci.win_info)); if (pswi->w > max_w) max_w = pswi->w; } pswi = (&(pzdi->zyfh_ctl->pti->tci.win_info)); if (pswi->x+pswi->w > max_w) max_w = pswi->x+pswi->w; pswi = (&(pzdi->bmp_list_ctl->pti->tci.win_info)); if (pswi->w > max_w) max_w = pswi->w; pswi = (&(pzdi->btn_row_ctl->pti->tci.win_info)); if (pswi->w > max_w) max_w = pswi->w; bottom = pswi->y+pswi->h; if (pzdi->msg_ctl != NULL) { pswi = (&(pzdi->msg_ctl->pti->tci.win_info)); pswi->x = ((max_w-pswi->w)>>1) + windowPadding + h_pad; TidgetMoveResize(pzdi->msg_ctl->pti, pswi->x, pswi->y, pswi->w, pswi->h); } pswi = (&(pzdi->edit_ctl->pti->tci.win_info)); pswi->w = max_w; TidgetMoveResize(pzdi->edit_ctl->pti, pswi->x, pswi->y, pswi->w, pswi->h); pswi = (&(pzdi->bmp_list_ctl->pti->tci.win_info)); pswi->w = max_w; TidgetMoveResize(pzdi->bmp_list_ctl->pti, pswi->x, pswi->y, pswi->w, pswi->h); pswi = (&(pzdi->btn_row_ctl->pti->tci.win_info)); pswi->w = max_w; TidgetMoveResize(pzdi->btn_row_ctl->pti, pswi->x, pswi->y, pswi->w, pswi->h); pswi = (&(pTdgtBase->pti->tci.win_info)); pswi->w = max_w+(windowPadding<<1)+(h_pad<<1); pswi->h = bottom+windowPadding+v_pad; TidgetMoveResize(pTdgtBase->pti, pswi->x, pswi->y, pswi->w, pswi->h); } static void AdjustDialogBoxSize(dpy, pTdgtBase) Display *dpy; TdgtBase *pTdgtBase; { ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)(pTdgtBase->pti->userdata); int base_win_x=0, base_win_y=0, base_win_w=0, base_win_h=0; XWMHints wmhints; XSizeHints sizehints; if (pTdgtBase == NULL) return; AdjustDialogBoxWidth(dpy, pTdgtBase); base_win_w = pTdgtBase->pti->tci.win_info.w; base_win_h = pTdgtBase->pti->tci.win_info.h; memset(&wmhints, 0, sizeof(XWMHints)); wmhints.flags = InputHint | StateHint; wmhints.input = True; wmhints.initial_state = NormalState; XSetWMHints(dpy, pTdgtBase->pti->tci.win, &wmhints); base_win_x = (base_win_w > pzdi->screen_w) ? 0 : ((pzdi->screen_w-base_win_w)>>1); base_win_y = (base_win_h > pzdi->screen_h) ? 0 : ((pzdi->screen_h-base_win_h)/3); XMoveResizeWindow(dpy, pTdgtBase->pti->tci.win, base_win_x, base_win_y, base_win_w, base_win_h); sizehints.flags = PPosition | PSize | USPosition | PMinSize | PMaxSize; sizehints.x = base_win_x; sizehints.y = base_win_y; sizehints.width = sizehints.min_width = sizehints.max_width = base_win_w; sizehints.height = sizehints.min_height = sizehints.max_height = base_win_h; #ifdef NOTR4MODE XSetNormalHints(dpy, pTdgtBase->pti->tci.win, &sizehints); #else XSetWMNormalHints(dpy, pTdgtBase->pti->tci.win, &sizehints); #endif XSetTransientForHint(dpy, pTdgtBase->pti->tci.win, mainWindow); } TidgetInfo *CreateTdgtb5DialogBox(dpy, parent_win) Display *dpy; Window parent_win; /* should be the rootWindow */ { int orig_x=0, x=0, y=0, v_gap=20, num_bmp_cols=0, h_pad=0, v_pad=0; int max_w=((gZyfhInfo.b5_font_w<<4)+scrollBarW), vh_padding=0; int has_msg_ctl=FALSE; TdgtBase *pTdgtBase=NULL; ZyfhDlgInfo *pzdi=(ZyfhDlgInfo*)malloc(sizeof(ZyfhDlgInfo)); char caption[MAXSTRING]; MouseOverStatusInfo mosi; if (pzdi == NULL) FailAllocMessage(); memset(pzdi, 0, sizeof(ZyfhDlgInfo)); memset(&mosi, 0, sizeof(MouseOverStatusInfo)); UtilStrCpyN(mosi.btn_str[0], sizeof(mosi.btn_str[0]), TgLoadString(STID_SELECT_A_CHAR)); UtilStrCpyN(mosi.btn_str[1], sizeof(mosi.btn_str[1]), TgLoadString(STID_SEND_A_CHAR_TO_DRAWING_AREA)); UtilStrCpyN(mosi.btn_str[2], sizeof(mosi.btn_str[2]), TgLoadCachedString(CSTID_PARANED_NONE)); h_pad = TDGTBASE_DEF_H_PAD; v_pad = TDGTBASE_DEF_V_PAD; if (msgFontSet != NULL || msgFontPtr != NULL) { vh_padding = (msgFontWidth<<1); } else { vh_padding = (defaultFontWidth<<1); } h_pad = v_pad = vh_padding; orig_x = h_pad+windowPadding; x = h_pad+windowPadding; y = v_pad+windowPadding; switch (gZyfhInfo.b5_font_real_encoding) { case GB_ENCODING: sprintf(caption, TgLoadString(STID_TOOL_GB_CHINESE_KEYPAD), TOOL_NAME); break; case BIG5_ENCODING: sprintf(caption, TgLoadString(STID_TOOL_BIG5_CHINESE_KEYPAD), TOOL_NAME); break; default: return NULL; } pTdgtBase = CreateTdgtBase(parent_win, NULL, ID_ZYFH_DIALOG, 0, 0, 100, 100, h_pad, v_pad, (dialogboxUse3DBorder ? TGBS_RAISED : TGBS_NORMAL), caption); if (pTdgtBase == NULL) { free(pzdi); return NULL; } pTdgtBase->pti->userdata = pzdi; InitTdgtb5DlgInfo(pTdgtBase->pti); num_bmp_cols = (int)(((double)(pzdi->screen_w)) / ((double)3) / ((double)(gZyfhInfo.b5_font_w))); if (has_msg_ctl) { pzdi->msg_ctl = CreateTdgtMsg(pTdgtBase->pti->tci.win, pTdgtBase->pti, INVALID, x, y, TDGTMSG_DEF_H_PAD, TDGTMSG_DEF_V_PAD, TGBS_NORMAL, TgLoadString(STID_USE_ZYFH_KEYPAD_OR_PINYING), JUST_L); if (pzdi->msg_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } y += pzdi->msg_ctl->pti->tci.win_info.h; y += v_gap; } pzdi->zyfh_dpy_ctl = CreateTdgtDraw(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_ZYFH_DPY, x, y, gZyfhInfo.zyfh_image_wh, ((gZyfhInfo.zyfh_image_wh)<<2), TDGTDRAW_DEF_H_PAD, TDGTDRAW_DEF_V_PAD, TGBS_LOWRED, NULL); if (pzdi->zyfh_dpy_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } x += ((gZyfhInfo.zyfh_image_wh)<<2); pzdi->zyfh_ctl = CreateTdgtDraw(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_ZYFH_KEYPAD, x, y, gZyfhInfo.zyfh_bitmap_w, gZyfhInfo.zyfh_bitmap_h, TDGTDRAW_DEF_H_PAD, TDGTDRAW_DEF_V_PAD, TGBS_LOWRED, NULL); if (pzdi->zyfh_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } TdgtDrawSetRedrawCallback(pzdi->zyfh_ctl, ZyfhRedrawCallback); TdgtDrawSetEvHandlerCallback(pzdi->zyfh_ctl, ZyfhEvHandlerCallback); TdgtDrawSetRedrawCallback(pzdi->zyfh_dpy_ctl, ZyfhDpyRedrawCallback); TdgtDrawSetSendCmdCallback(pzdi->zyfh_dpy_ctl, ZyfhDpySendCmdCallback); x = orig_x; y += pzdi->zyfh_ctl->pti->tci.win_info.h; y += v_gap; pzdi->edit_ctl = CreateTdgtSmplEdit(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_ZYFH_EDIT, x, y, max_w, TDGTSEDT_DEF_H_PAD, TDGTSEDT_DEF_V_PAD, "", STYLE_NR, INVALID); if (pzdi->edit_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } y += pzdi->edit_ctl->pti->tci.win_info.h; y += v_gap; pzdi->bmp_list_ctl = CreateTdgtBmpList(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_ZYFH_BMPLIST, x, y, TDGTBMPL_DEF_H_PAD, TDGTBMPL_DEF_V_PAD, gZyfhInfo.b5_font_w, gZyfhInfo.b5_font_h, num_bmp_cols, 5, 0, (Button1Mask|Button2Mask), &mosi); if (pzdi->bmp_list_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } y += pzdi->bmp_list_ctl->pti->tci.win_info.h; y += v_gap; pzdi->btn_row_ctl = CreateTdgtBtnRow(pTdgtBase->pti->tci.win, pTdgtBase->pti, INVALID, x, y, TDGTBROW_DEF_H_PAD, TDGTBROW_DEF_V_PAD, TGBS_NORMAL, defaultFontWidth, JUST_C); if (pzdi->btn_row_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } if (!CreateTgtwb5Buttons(pTdgtBase)) { DestroyTidget(&pTdgtBase->pti); return NULL; } Tdgtb5DlgSetEntries(pTdgtBase->pti, NULL, NULL, 0, INVALID); /* * Specify that the base tidget will handle all the KeyPress events * in all its children tidgets. */ TdgtBaseWillHandleKeyPressEvents(pTdgtBase, Tdgtb5DlgKeyPressEvHandlerCallback); /* * Specify that the base tidget will handle all the KeyPress events * in all its children tidgets. */ TdgtBaseSetWmDeleteCallback(pTdgtBase, Tdgtb5DlgWmDeleteCallback); AdjustDialogBoxSize(dpy, pTdgtBase); return pTdgtBase->pti; } /* --------------------- DestroyTdgtb5DialogBox --------------------- */ void DestroyTdgtb5DialogBox(dpy, pti) Display *dpy; TidgetInfo *pti; { ZyfhDlgInfo *pzdi=NULL; if (pti == NULL) return; pzdi = (ZyfhDlgInfo*)(pti->userdata); if (pzdi != NULL) { free(pzdi); } DestroyTidget(&pti); } /* --------------------- Tdgtb5DlgLoop --------------------- */ static int HandleTdgtNotifyEvent(pTdgtBase, pTdgtNtfy) TdgtBase *pTdgtBase; TdgtNtfy *pTdgtNtfy; { switch (pTdgtNtfy->ctl_id) { case ID_ZYFH_BMPLIST: switch (pTdgtNtfy->nf_type) { case TDGTNF_LIST_CLICKED: if (pTdgtNtfy->nf_arg2 == Button2) { return SendSelectedCharToClient(pTdgtBase); } break; case TDGTNF_LIST_DBL_CLICKED: return SendSelectedCharToClient(pTdgtBase); } break; case ID_ZYFH_BTN_FETCH: FetchChars(pTdgtBase); break; case ID_ZYFH_BTN_SEND: SendSelectedCharToClient(pTdgtBase); break; case ID_ZYFH_BTN_CR: SendCRToClient(pTdgtBase); break; case ID_ZYFH_BTN_CLOSE: HideTdgtb5DialogBox(); break; } return FALSE; } int Tdgtb5DlgLoop(pti) TidgetInfo *pti; { TdgtBase *pTdgtBase=(TdgtBase*)(pti->tidget); int which_btn_clicked=INVALID, first_time_config=TRUE; if (pTdgtBase == NULL) return which_btn_clicked; while (gZyfhInfo.mapped) { XEvent xev; TdgtNtfy tdgt_notify; TidgetInfo *handling_pti=NULL; XNextEvent(mainDisplay, &xev); if (xev.type == MotionNotify) { /* do nothing */ } else if (xev.type == ConfigureNotify && xev.xany.window == pti->tci.win) { if (first_time_config) { first_time_config = FALSE; if (warpToWinCenter) { /* does not work because the window has been moved */ XWarpPointer(mainDisplay, None, pti->tci.win, 0, 0, 0, 0, (pti->tci.win_info.w>>1), (pti->tci.win_info.h>>1)); } SetStringStatus(TgLoadString(STID_CLICK_SEND_TO_SEND_CHAR)); } } else if (xev.type == Expose) { ExposeEventHandler(&xev, FALSE); } else if (xev.type == ConfigureNotify && xev.xany.window==mainWindow) { Reconfigure(FALSE); } else if (xev.type == KeyPress) { TidgetManagerHandleAllKeyPressEvent(&xev); } else if (IsTdgtNotifyEvent(pti, &xev, &tdgt_notify)) { HandleTdgtNotifyEvent(pTdgtBase, &tdgt_notify); } else if (IsTidgetEvent(pti, &xev, &handling_pti)) { TidgetEventHandler(pti, &xev, handling_pti); } else { } } return which_btn_clicked; } /* --------------------- Init & Clean Up --------------------- */ int InitTdgtb5Dlg() { return TRUE; } void CleanUpTdgtb5Dlg() { } #endif /* ~_NO_TGTWB5 */ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/ini.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000064231�11602233311�013714� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/ini.c,v 1.7 2011/05/16 16:21:58 william Exp $ */ #define _INCLUDE_FROM_INI_C_ #include "tgifdefs.h" #include "dialog.e" #include "ini.e" #include "msg.e" #include "strtbl.e" #include "util.e" typedef struct TgIniEntryInfoStruct { char *pszEntry; char *pszValue; int bScanned; struct TgIniEntryInfoStruct *pNextEntry, *pPrevEntry; } TGINIENTRYINFO; typedef struct TgIniSectionInfoStruct { char *pszSection; int bAllowDupKey; int bValuelessKey; TGINIENTRYINFO *pFirstEntry, *pLastEntry; struct TgIniSectionInfoStruct *pNextSection, *pPrevSection; } TGINISECTIONINFO; typedef struct TgIniFileInfoStruct { char *pszFile; int bModified; int bStripQuotes; int bCheckFileTime; time_t stFileTime; TGINISECTIONINFO *pFirstSection, *pLastSection; struct TgIniFileInfoStruct *pNextInfo, *pPrevInfo; } TGINIFILEINFO; typedef struct TgIniStruct { TGINIFILEINFO *pFirstInfo, *pLastInfo; } TGINI; static TGINI tgIni; /* -------------------- Utility Functions -------------------- */ static int InvalidPath(pszFile) char *pszFile; { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_PATH_MUST_FULL), pszFile); fprintf(stderr, "%s\n", gszMsgBox); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } static int GetLastModifiedTime(pszFile, pFileTime) char *pszFile; time_t *pFileTime; { struct stat stat_buf; if (stat(pszFile, &stat_buf) == 0) { memcpy(pFileTime, &stat_buf.st_mtime, sizeof(time_t)); return TRUE; } return FALSE; } static int CompareFileTime(pNewFileTime, pOldFileTime) time_t *pNewFileTime, *pOldFileTime; { long lval=((long)(*pNewFileTime)) - ((long)(*pOldFileTime)); int ival=(int)lval; if (lval > 0) { if (ival < 0) return (-ival); } else if (lval < 0) { if (ival > 0) return (-ival); } else { ival = 0; } return ival; } /* -------------------- Discard Functions -------------------- */ static void UnlinkFileInfo(ptifi) TGINIFILEINFO *ptifi; { if (ptifi->pPrevInfo != NULL) { ptifi->pPrevInfo->pNextInfo = ptifi->pNextInfo; } else { tgIni.pFirstInfo = ptifi->pNextInfo; } if (ptifi->pNextInfo != NULL) { ptifi->pNextInfo->pPrevInfo = ptifi->pPrevInfo; } else { tgIni.pLastInfo = ptifi->pPrevInfo; } } static void DiscardEntryInfo(ptiei) TGINIENTRYINFO *ptiei; { UtilFree(ptiei->pszEntry); UtilFree(ptiei->pszValue); } static void DiscardSectionInfo(ptisi) TGINISECTIONINFO *ptisi; { TGINIENTRYINFO *ptiei=NULL, *ptiei_next; for (ptiei=ptisi->pFirstEntry; ptiei != NULL; ptiei=ptiei_next) { ptiei_next = ptiei->pNextEntry; DiscardEntryInfo(ptiei); free(ptiei); } UtilFree(ptisi->pszSection); } static int WriteOutIniFile(ptifi, pszAltFile) TGINIFILEINFO *ptifi; char *pszAltFile; { int ok=TRUE; char *pszFile=(pszAltFile==NULL ? ptifi->pszFile : pszAltFile); char *c_ptr=strchr(pszFile, DIR_SEP); FILE *pFile=NULL; TGINISECTIONINFO *ptisi=NULL; if (c_ptr == NULL) { return InvalidPath(pszFile); } if ((pFile=fopen(pszFile, "w")) == NULL) { return FailToWriteFileMessage(pszFile); } for (ptisi=ptifi->pFirstSection; ok && ptisi != NULL; ptisi=ptisi->pNextSection) { int bValuelessKey=ptisi->bValuelessKey; TGINIENTRYINFO *ptiei=NULL; /* do not translate -- program constants */ if (fprintf(pFile, "[%s]\n", ptisi->pszSection) <= 0) { ok = FALSE; break; } for (ptiei=ptisi->pFirstEntry; ok && ptiei != NULL; ptiei=ptiei->pNextEntry) { /* remember that the key is ";" for a comment line */ if (strcmp(ptiei->pszEntry, ";") == 0) { if (fprintf(pFile, "%s\n", ptiei->pszValue) <= 0) { ok = FailToWriteFileMessage(pszFile); break; } } else if (bValuelessKey) { if (fprintf(pFile, "%s\n", ptiei->pszEntry) <= 0) { ok = FailToWriteFileMessage(pszFile); break; } } else { if (fprintf(pFile, "%s=%s\n", ptiei->pszEntry, ptiei->pszValue) <= 0) { ok = FailToWriteFileMessage(pszFile); break; } } } if (ok && ptisi->pNextSection != NULL) { if (fprintf(pFile, "\n") <= 0) { ok = FailToWriteFileMessage(pszFile); break; } } } if (fclose(pFile) == EOF) { return FailToWriteFileMessage(pszFile); } ptifi->bModified = FALSE; return ok; } static int DiscardFileInfo(ptifi) TGINIFILEINFO *ptifi; { TGINISECTIONINFO *ptisi=NULL, *ptisi_next; int ok=TRUE; if (ptifi->bModified) { ok = WriteOutIniFile(ptifi, NULL); } for (ptisi=ptifi->pFirstSection; ptisi != NULL; ptisi=ptisi_next) { ptisi_next = ptisi->pNextSection; DiscardSectionInfo(ptisi); free(ptisi); } UtilFree(ptifi->pszFile); return ok; } /* -------------------- Allocation Functions -------------------- */ static TGINIENTRYINFO *AllocEntryInfo(ptisi, pszEntry, pszValue) TGINISECTIONINFO *ptisi; char *pszEntry, *pszValue; { /* for a comment line, make the key to be ";" */ char *buf1=UtilStrDup(pszEntry==NULL ? ";" : pszEntry); char *buf2=UtilStrDup(pszValue); TGINIENTRYINFO *ptiei= (TGINIENTRYINFO*)malloc(sizeof(TGINIENTRYINFO)); if (buf1 == NULL || buf2 == NULL || ptiei == NULL) { UtilFree(buf1); UtilFree(buf2); free(ptiei); FailAllocMessage(); return NULL; } memset(ptiei, 0, sizeof(TGINIENTRYINFO)); /* first-in-first-out */ ptiei->pNextEntry = NULL; ptiei->pPrevEntry = ptisi->pLastEntry; if (ptisi->pLastEntry == NULL) { ptisi->pFirstEntry = ptiei; } else { ptisi->pLastEntry->pNextEntry = ptiei; } ptisi->pLastEntry = ptiei; ptiei->pszEntry = buf1; ptiei->pszValue = buf2; ptiei->bScanned = FALSE; return ptiei; } static TGINISECTIONINFO *AllocSectionInfo(ptifi, pszSection, bValuelessKey) TGINIFILEINFO *ptifi; char *pszSection; int bValuelessKey; { char *buf=UtilStrDup(pszSection); TGINISECTIONINFO *ptisi= (TGINISECTIONINFO*)malloc(sizeof(TGINISECTIONINFO)); if (buf == NULL || ptisi == NULL) { UtilFree(buf); free(ptisi); FailAllocMessage(); return NULL; } memset(ptisi, 0, sizeof(TGINISECTIONINFO)); /* first-in-first-out */ ptisi->pNextSection = NULL; ptisi->pPrevSection = ptifi->pLastSection; if (ptifi->pLastSection == NULL) { ptifi->pFirstSection = ptisi; } else { ptifi->pLastSection->pNextSection = ptisi; } ptifi->pLastSection = ptisi; ptisi->pszSection = buf; ptisi->bAllowDupKey = FALSE; ptisi->bValuelessKey = bValuelessKey; return ptisi; } static TGINIFILEINFO *AllocFileInfo(pszFile) char *pszFile; { char *buf=UtilStrDup(pszFile); TGINIFILEINFO *ptifi=(TGINIFILEINFO*)malloc(sizeof(TGINIFILEINFO)); if (buf == NULL || ptifi == NULL) { UtilFree(buf); free(ptifi); FailAllocMessage(); return NULL; } memset(ptifi, 0, sizeof(TGINIFILEINFO)); /* last-in-first-out */ ptifi->pNextInfo = tgIni.pFirstInfo; ptifi->pPrevInfo = NULL; if (tgIni.pFirstInfo == NULL) { tgIni.pLastInfo = ptifi; } else { tgIni.pFirstInfo->pPrevInfo = ptifi; } tgIni.pFirstInfo = ptifi; ptifi->pszFile = buf; ptifi->bModified = FALSE; ptifi->bStripQuotes = TRUE; ptifi->bCheckFileTime = TRUE; memset(&ptifi->stFileTime, 0, sizeof(time_t)); if (!GetLastModifiedTime(pszFile, &ptifi->stFileTime)) { memset(&ptifi->stFileTime, 0, sizeof(time_t)); } return ptifi; } /* -------------------- Parse Functions -------------------- */ static int ParseFile(ptifi) TGINIFILEINFO *ptifi; { char *buf; TGINISECTIONINFO *ptisi=NULL; char *pszFile=ptifi->pszFile; char *c_ptr=strchr(pszFile, DIR_SEP); FILE *pFile=NULL; if (c_ptr == NULL) { return InvalidPath(pszFile); } if ((pFile=fopen(pszFile, "r")) == NULL) return TRUE; while ((buf=UtilGetALine(pFile)) != NULL) { char *c_ptr; UtilTrimBlanks(buf); if (*buf == ';') { /* handle comments, remember that the key is ";" for a comment line */ if (ptisi != NULL) { if (AllocEntryInfo(ptisi, NULL, buf) == NULL) return FALSE; } } else if (*buf == '[') { if ((c_ptr=strchr(&buf[1], ']')) == NULL) { ptisi = NULL; } else { *c_ptr = '\0'; /* * Don't need to call UtilTrimBlanks(&buf[1]) because that's how * GetProfileString() works! */ if ((ptisi=AllocSectionInfo(ptifi, &buf[1], FALSE)) == NULL) { return FALSE; } } } else if (ptisi != NULL) { if ((c_ptr=strchr(buf, '=')) != NULL) { char *psz=(&c_ptr[1]); *c_ptr = '\0'; c_ptr = psz; UtilTrimBlanks(buf); UtilTrimBlanks(c_ptr); if (AllocEntryInfo(ptisi, buf, c_ptr) == NULL) return FALSE; if (ptisi->bValuelessKey) { #ifdef _DEBUG /* debug, do not translate */ fprintf(stderr, "%s [%s] of '%s'.\n", "WARNING: Ambiguous valueless key section", ptisi->pszSection, pszFile); #endif /* _DEBUG */ } } else if (*buf != '\0') { char cNull='\0'; if (AllocEntryInfo(ptisi, buf, &cNull) == NULL) return FALSE; ptisi->bValuelessKey = TRUE; } } UtilFree(buf); } fclose(pFile); return TRUE; } /* -------------------- External Functions -------------------- */ static TGINIENTRYINFO *FindEntryInfo(ptisi, pszEntry) TGINISECTIONINFO *ptisi; char *pszEntry; { if (ptisi == NULL) return NULL; /* finding a comment line is not allowed */ if (pszEntry == NULL || strcmp(pszEntry, ";") == 0) return NULL; if (ptisi->bAllowDupKey) { TGINIENTRYINFO *ptiei=NULL; for (ptiei=ptisi->pFirstEntry; ptiei != NULL; ptiei=ptiei->pNextEntry) { if (!ptiei->bScanned && UtilStrICmp(pszEntry, ptiei->pszEntry) == 0) { ptiei->bScanned = TRUE; return ptiei; } } } else { TGINIENTRYINFO *ptiei=NULL; for (ptiei=ptisi->pFirstEntry; ptiei != NULL; ptiei=ptiei->pNextEntry) { if (UtilStrICmp(pszEntry, ptiei->pszEntry) == 0) { return ptiei; } } } return NULL; } static TGINISECTIONINFO *FindSectionInfo(ptifi, pszSection) TGINIFILEINFO *ptifi; char *pszSection; { TGINISECTIONINFO *ptisi=NULL; if (ptifi == NULL) return NULL; for (ptisi=ptifi->pFirstSection; ptisi != NULL; ptisi=ptisi->pNextSection) { if (UtilStrICmp(pszSection, ptisi->pszSection) == 0) { return ptisi; } } return NULL; } static TGINIFILEINFO *TgIniFindFileInfo(pszFile, bAutoLoad) char *pszFile; int bAutoLoad; { TGINIFILEINFO *ptifi=NULL; if (pszFile == NULL) return NULL; for (ptifi=tgIni.pFirstInfo; ptifi != NULL; ptifi=ptifi->pNextInfo) { if (UtilStrICmp(pszFile, ptifi->pszFile) == 0) { if (ptifi->bCheckFileTime) { time_t stFileTime; memset(&stFileTime, 0, sizeof(time_t)); if (!GetLastModifiedTime(pszFile, &stFileTime) || CompareFileTime(&stFileTime, &ptifi->stFileTime) > 0) { DiscardFileInfo(ptifi); UnlinkFileInfo(ptifi); free(ptifi); ptifi = NULL; break; } } if (ptifi != NULL) return ptifi; } } if (!bAutoLoad) return NULL; if ((ptifi=AllocFileInfo(pszFile)) == NULL) return NULL; if (!ParseFile(ptifi)) { DiscardFileInfo(ptifi); UnlinkFileInfo(ptifi); free(ptifi); return NULL; } return ptifi; } static int TgIniDiscardFileInfo(pszFile) char *pszFile; { TGINIFILEINFO *ptifi=TgIniFindFileInfo(pszFile, FALSE); int ok=TRUE; if (ptifi == NULL) return TRUE; ok = DiscardFileInfo(ptifi); UnlinkFileInfo(ptifi); free(ptifi); return ok; } static void TgIniBeginFastProfile(ptifi) TGINIFILEINFO *ptifi; { if (ptifi != NULL) ptifi->bCheckFileTime = FALSE; } static void TgIniEndFastProfile(ptifi) TGINIFILEINFO *ptifi; { if (ptifi != NULL) ptifi->bCheckFileTime = TRUE; } static int TgIniSetProfileStripQuotes(ptifi, bStripQuotes) TGINIFILEINFO *ptifi; int bStripQuotes; { if (ptifi != NULL) { int bReturn=ptifi->bStripQuotes; ptifi->bStripQuotes = bStripQuotes; return bReturn; } return FALSE; } static char *TgIniGetProfileString(pszSection, pszEntry, ptifi) char *pszSection, *pszEntry; TGINIFILEINFO *ptifi; { char *buf=NULL; int buf_sz=0, cur_len=0; if (pszSection == NULL) { TGINISECTIONINFO *ptisi=NULL; for (ptisi=ptifi->pFirstSection; ptisi != NULL; ptisi=ptisi->pNextSection) { int len=strlen(ptisi->pszSection); while (len+cur_len+6 >= buf_sz) { buf_sz += 0x100; if (buf == NULL) { buf = (char*)malloc(buf_sz); } else { buf = (char*)realloc(buf, (size_t)buf_sz); } if (buf == NULL) { FailAllocMessage(); return NULL; } } strcpy(&buf[cur_len], ptisi->pszSection); cur_len = (int)((&buf[len+cur_len+1]) - buf); } if (buf != NULL) buf[cur_len] = '\0'; } else if (pszEntry == NULL) { TGINISECTIONINFO *ptisi=FindSectionInfo(ptifi, pszSection); if (ptisi != NULL) { TGINIENTRYINFO *ptiei=NULL; for (ptiei=ptisi->pFirstEntry; ptiei != NULL; ptiei=ptiei->pNextEntry) { int len=0; if (strcmp(ptiei->pszEntry, ";") == 0) { /* * skip comments, remember that the key is ";" * for a comment line */ continue; } len = strlen(ptiei->pszEntry); while (len+cur_len+6 >= buf_sz) { buf_sz += 0x100; if (buf == NULL) { buf = (char*)malloc(buf_sz); } else { buf = (char*)realloc(buf, (size_t)buf_sz); } if (buf == NULL) { FailAllocMessage(); return NULL; } } strcpy(&buf[cur_len], ptiei->pszEntry); cur_len = (int)((&buf[len+cur_len+1]) - buf); } } if (buf != NULL) buf[cur_len] = '\0'; } else { TGINISECTIONINFO *ptisi=FindSectionInfo(ptifi, pszSection); if (ptisi != NULL) { TGINIENTRYINFO *ptiei=FindEntryInfo(ptisi, pszEntry); if (ptiei != NULL) { buf = UtilStrDup(ptiei->pszValue); if (buf != NULL && ptifi->bStripQuotes) { int nNumChars=strlen(buf); if (nNumChars > 1 && buf[0] == buf[nNumChars-1]) { char *pszLastChar=(&buf[nNumChars-1]); if (*buf == '\'' || *buf == '"') { char *pby=buf, *pby1=(&buf[1]); while (pby1 != pszLastChar) { *pby++ = *pby1++; } *((char*)pby) = '\0'; } } } } } } return buf; } static int TgIniWriteProfileString(pszSection, pszEntry, pszValue, ptifi) char *pszSection, *pszEntry, *pszValue; TGINIFILEINFO *ptifi; { TGINISECTIONINFO *ptisi=FindSectionInfo(ptifi, pszSection); if (ptisi == NULL) { /* append */ if ((ptisi=AllocSectionInfo(ptifi, pszSection, FALSE)) == NULL) { return FALSE; } } if (pszEntry == NULL) { TGINIENTRYINFO *ptiei=NULL, *ptiei_next; for (ptiei=ptisi->pFirstEntry; ptiei != NULL; ptiei=ptiei_next) { ptiei_next = ptiei->pNextEntry; DiscardEntryInfo(ptiei); free(ptiei); } ptisi->pFirstEntry = ptisi->pLastEntry = NULL; } else if (strcmp(pszEntry, ";") == 0) { /* can't write a comment line into an INI file */ return FALSE; } else { TGINIENTRYINFO *ptiei=NULL; if (!ptisi->bAllowDupKey) { ptiei = FindEntryInfo(ptisi, pszEntry); } if (ptiei == NULL) { /* append */ if (AllocEntryInfo(ptisi, pszEntry, (pszValue==NULL ? "" : pszValue)) == NULL) { return FALSE; } } else if (pszValue == NULL) { if (ptiei->pPrevEntry == NULL) { ptisi->pFirstEntry = ptiei->pNextEntry; } else { ptiei->pPrevEntry->pNextEntry = ptiei->pNextEntry; } if (ptiei->pNextEntry == NULL) { ptisi->pLastEntry = ptiei->pPrevEntry; } else { ptiei->pNextEntry->pPrevEntry = ptiei->pPrevEntry; } DiscardEntryInfo(ptiei); free(ptiei); } else { if (ptisi->bValuelessKey) { #ifdef _DEBUG /* debug, do not translate */ fprintf(stderr, "%s %s section [%s] of '%s'.\n", "WARNING: tgWriteProfileString() is called with a", "non-NULL pszValue for a valueless key", ptisi->pszSection, ptifi->pszFile); #endif /* _DEBUG */ } /* replace */ UtilFree(ptiei->pszValue); if ((ptiei->pszValue=UtilStrDup(pszValue)) == NULL) { return FALSE; } } } ptifi->bModified = TRUE; return TRUE; } static void TgIniBeginDupKeySection(pszSection, ptifi) char *pszSection; TGINIFILEINFO *ptifi; { TGINISECTIONINFO *ptisi=FindSectionInfo(ptifi, pszSection); TGINIENTRYINFO *ptiei=NULL; if (ptisi == NULL) return; for (ptiei=ptisi->pFirstEntry; ptiei != NULL; ptiei=ptiei->pNextEntry) { ptiei->bScanned = FALSE; } ptisi->bAllowDupKey = TRUE; } static void TgIniEndDupKeySection(pszSection, ptifi) char *pszSection; TGINIFILEINFO *ptifi; { TGINISECTIONINFO *ptisi=FindSectionInfo(ptifi, pszSection); if (ptisi == NULL) return; ptisi->bAllowDupKey = FALSE; } static int TgIniBeginValuelessKeySection(pszSection, ptifi) char *pszSection; TGINIFILEINFO *ptifi; { TGINISECTIONINFO *ptisi=FindSectionInfo(ptifi, pszSection); int bValuelessKey=FALSE; if (ptisi == NULL) { if ((ptisi=AllocSectionInfo(ptifi, pszSection, TRUE)) == NULL) { return FALSE; } } if (ptisi->pFirstEntry == NULL) { if (!ptisi->bValuelessKey) { ptisi->bValuelessKey = TRUE; } } else { if (!ptisi->bValuelessKey) { #ifdef _DEBUG /* debug, do not translate */ fprintf(stderr, "%s non-valueless section [%s] of '%s'.\n", "WARNING: tgBeginValuelessKeySection() is called for a", pszSection, ptifi->pszFile); #endif /* _DEBUG */ } } bValuelessKey = ptisi->bValuelessKey; ptisi->bValuelessKey = TRUE; return bValuelessKey; } static void TgIniEndValuelessKeySection(pszSection, ptifi, bValuelessKey) char *pszSection; TGINIFILEINFO *ptifi; int bValuelessKey; { TGINISECTIONINFO *ptisi=FindSectionInfo(ptifi, pszSection); if (ptisi == NULL) return; if (ptisi->bValuelessKey != bValuelessKey) { #ifdef _DEBUG /* debug, do not translate */ fprintf(stderr, "%s valuess-ness for section [%s] of '%s'.\n", "WARNING: tgEndValuelessKeySection() changes the", pszSection, ptifi->pszFile); #endif /* _DEBUG */ } ptisi->bValuelessKey = bValuelessKey; } static int TgIniIsValuelessKeySection(pszSection, ptifi) char *pszSection; TGINIFILEINFO *ptifi; { TGINISECTIONINFO *ptisi=FindSectionInfo(ptifi, pszSection); if (ptisi == NULL) { #ifdef _DEBUG /* debug, do not translate */ fprintf(stderr, "%s section [%s] of '%s'.\n", "WARNING: tgIsValuelessKeySection() is called with a non-existant", pszSection, ptifi->pszFile); #endif /* _DEBUG */ return FALSE; } return ptisi->bValuelessKey; } static int TgIniDeleteDupKeyValue(pszSection, pszEntry, pszValue, ptifi) char *pszSection, *pszEntry, *pszValue; TGINIFILEINFO *ptifi; { TGINISECTIONINFO *ptisi=FindSectionInfo(ptifi, pszSection); TGINIENTRYINFO *ptiei=NULL; if (ptisi == NULL) { return TRUE; } TgIniBeginDupKeySection(pszSection, ptifi); for (ptiei=FindEntryInfo(ptisi, pszEntry); ptiei != NULL; ptiei=FindEntryInfo(ptisi, pszEntry)) { if (UtilStrICmp(pszValue, ptiei->pszValue) == 0) { if (ptiei->pPrevEntry == NULL) { ptisi->pFirstEntry = ptiei->pNextEntry; } else { ptiei->pPrevEntry->pNextEntry = ptiei->pNextEntry; } if (ptiei->pNextEntry == NULL) { ptisi->pLastEntry = ptiei->pPrevEntry; } else { ptiei->pNextEntry->pPrevEntry = ptiei->pPrevEntry; } DiscardEntryInfo(ptiei); free(ptiei); ptifi->bModified = TRUE; break; } } TgIniEndDupKeySection(pszSection, ptifi); return TRUE; } static void TgIniCleanUp() { TGINIFILEINFO *ptifi=NULL, *ptifi_next; for (ptifi=tgIni.pFirstInfo; ptifi != NULL; ptifi=ptifi_next) { ptifi_next = ptifi->pNextInfo; DiscardFileInfo(ptifi); free(ptifi); } tgIni.pFirstInfo = tgIni.pLastInfo = NULL; } /* -------------------- Exported Functions -------------------- */ void tgCleanUpProfile() { TgIniCleanUp(); } char *tgFreeProfileString(pszStr) char *pszStr; { UtilFree(pszStr); return NULL; } void tgBeginFastProfile(pszFile) char *pszFile; { TGINIFILEINFO *ptifi=TgIniFindFileInfo(pszFile, TRUE); if (ptifi == NULL) return; TgIniBeginFastProfile(ptifi); } void tgEndFastProfile(pszFile) char *pszFile; { TGINIFILEINFO *ptifi=TgIniFindFileInfo(pszFile, TRUE); if (ptifi == NULL) return; TgIniEndFastProfile(ptifi); } int tgSetProfileStripQuotes(pszFile, bStripQuotes) char *pszFile; int bStripQuotes; { TGINIFILEINFO *ptifi=TgIniFindFileInfo(pszFile, TRUE); if (ptifi == NULL) return FALSE; return TgIniSetProfileStripQuotes(ptifi, bStripQuotes); } char *tgGetProfileString(pszSection, pszEntry, pszFile) char *pszSection, *pszEntry, *pszFile; { TGINIFILEINFO *ptifi=TgIniFindFileInfo(pszFile, TRUE); if (ptifi == NULL) return NULL; return TgIniGetProfileString(pszSection, pszEntry, ptifi); } int tgGetProfileInt(pszSection, pszEntry, nDefault, pszFile) char *pszSection, *pszEntry, *pszFile; int nDefault; { TGINIFILEINFO *ptifi=NULL; char *c_ptr=NULL; int rc=nDefault; if (pszSection == NULL) { int rc=(TgIniDiscardFileInfo(pszFile) ? nDefault : (int)(nDefault==0)); return rc; } ptifi = TgIniFindFileInfo(pszFile, TRUE); if (ptifi == NULL) return nDefault; c_ptr = TgIniGetProfileString(pszSection, pszEntry, ptifi); rc = (c_ptr == NULL ? nDefault : (int)atoi(c_ptr)); UtilFree(c_ptr); return rc; } int tgWriteProfileString(pszSection, pszEntry, pszString, pszFile) char *pszSection, *pszEntry, *pszString, *pszFile; { TGINIFILEINFO *ptifi=TgIniFindFileInfo(pszFile, TRUE); if (pszSection == NULL) { if (ptifi == NULL || !ptifi->bModified) return TRUE; return WriteOutIniFile(ptifi, NULL); } return TgIniWriteProfileString(pszSection, pszEntry, pszString, ptifi); } void tgBeginDupKeySection(pszSection, pszFile) char *pszSection, *pszFile; { TGINIFILEINFO *ptifi=NULL; if (pszSection == NULL) return; ptifi = TgIniFindFileInfo(pszFile, TRUE); if (ptifi == NULL) return; TgIniBeginDupKeySection(pszSection, ptifi); } void tgEndDupKeySection(pszSection, pszFile) char *pszSection, *pszFile; { TGINIFILEINFO *ptifi=NULL; if (pszSection == NULL) return; ptifi = TgIniFindFileInfo(pszFile, TRUE); if (ptifi == NULL) return; TgIniEndDupKeySection(pszSection, ptifi); } int tgBeginValuelessKeySection(pszSection, pszFile) char *pszSection, *pszFile; { TGINIFILEINFO *ptifi=NULL; if (pszSection == NULL) return FALSE; ptifi = TgIniFindFileInfo(pszFile, TRUE); if (ptifi == NULL) return FALSE; return TgIniBeginValuelessKeySection(pszSection, ptifi); } void tgEndValuelessKeySection(pszSection, pszFile, bValuelessKey) char *pszSection, *pszFile; int bValuelessKey; { TGINIFILEINFO *ptifi=NULL; if (pszSection == NULL) return; ptifi = TgIniFindFileInfo(pszFile, TRUE); if (ptifi == NULL) return; TgIniEndValuelessKeySection(pszSection, ptifi, bValuelessKey); } int tgIsValuelessKeySection(pszSection, pszFile) char *pszSection, *pszFile; { TGINIFILEINFO *ptifi=NULL; if (pszSection == NULL) return FALSE; ptifi = TgIniFindFileInfo(pszFile, TRUE); if (ptifi == NULL) return FALSE; return TgIniIsValuelessKeySection(pszSection, ptifi); } int tgDeleteDupKeyValue(pszSection, pszEntry, pszValue, pszFile) char *pszSection, *pszEntry, *pszValue, *pszFile; { TGINIFILEINFO *ptifi=NULL; if (pszFile == NULL || pszSection == NULL || pszEntry == NULL || pszValue == NULL) { return FALSE; } ptifi = TgIniFindFileInfo(pszFile, TRUE); if (ptifi == NULL) return TRUE; return TgIniDeleteDupKeyValue(pszSection, pszEntry, pszValue, ptifi); } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/imgproc.c����������������������������������������������������������������������������0000644�0000764�0000764�00001246563�11602233311�014610� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/imgproc.c,v 1.82 2011/05/25 16:54:27 cvsps Exp $ */ #define _INCLUDE_FROM_IMGPROC_C_ #include "tgifdefs.h" #include "cmdids.h" #include "auxtext.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "grid.e" #include "hash.e" #include "imgproc.e" #include "list.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "menuinfo.e" #include "move.e" #include "msg.e" #include "names.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "pngtrans.e" #include "poly.e" #include "polygon.e" #include "raster.e" #include "rect.e" #include "remote.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "special.e" #include "strtbl.e" #include "util.e" #include "xbitmap.e" #include "xpixmap.e" #include "z_intrf.e" #define HISTOGRAMCOUNT(i) (gpHistogram[(i)].pixel) #define HISTOGRAMRED(i) (gpHistogram[(i)].red) #define HISTOGRAMGREEN(i) (gpHistogram[(i)].green) #define HISTOGRAMBLUE(i) (gpHistogram[(i)].blue) #define MAXIMAGEPROCS 34 int numImageProc=MAXIMAGEPROCS; int gnInImageProc=FALSE; int gnConvolving=FALSE; int gnNumNewColorsInPixmapFile=0; char gszImageProcXPmFile[MAXPATHLENGTH+1]; float gfVectorWarpSoftness=2.0; int threshFillReplaceEnabled=FALSE; int fillReplaceRedThresh=15; int fillReplaceGreenThresh=15; int fillReplaceBlueThresh=15; static NLFN *gpImageMapColorFunc=NULL; static NLFN *gpConvolveFunc=NULL; static int gpConvolveCmdID=(-1); static int gnCombining=FALSE; static int gnCombineW=0, gnCombineH=0; static char bggenToXpmCmd[MAXSTRING+1]; static char bggenToPpm6Cmd[MAXSTRING+1]; static char ppmquantCmd[MAXSTRING+1]; static char ppmFSquantCmd[MAXSTRING+1]; static XColor gDefErrorDiffuseLevel; static struct ObjRec *gpFgObj=NULL, *gpBgObj=NULL, *gpAlphaObj=NULL; static struct BBRec gTotalCombineBBox; static struct BBRec gFgCombineBBox, gBgCombineBBox, gAlphaCombineBBox; static XImage *gpFgImage=NULL, *gpBgImage=NULL, *gpAlphaImage=NULL; static XImage *gpFgBitmapImage=NULL, *gpBgBitmapImage=NULL, *gpAlphaBitmapImage=NULL; typedef struct tagConvExtraInfo { FILE *fp; /* non-NULL only if (fullTrueColorMode && HasZlibSupport()) */ XColor my_bg_xcolor; int alpha_combine; /* if alpha_combine is TRUE, these are for the foreground object */ int image_w, image_h; XImage *image, *bitmap_image; XColor **xcolors; /* if alpha_combine is not TRUE, everything below are not used */ int final_w, final_h; int alpha_image_w, alpha_image_h, bg_image_w, bg_image_h; XImage *alpha_image, *alpha_bitmap_image, *bg_image, *bg_bitmap_image; XColor **alpha_xcolors, **bg_xcolors; } ConvExtraInfo; static ConvExtraInfo gConvExtraInfo; static TrueColorInfo gTrueColorInfo; typedef struct tagThreshFillReplaceInfo { int use_thresholding; /* for true color */ int min_r, max_r, min_g, max_g, min_b, max_b; TrueColorInfo tci; /* for non-true color */ TgHash hash_table; int *within_threshold; } ThreshFillReplaceInfo; static ThreshFillReplaceInfo gThreshFillReplaceInfo; static int ParseThreshFillReplaceSpec(spec) char *spec; { char *psz=NULL, sz_spec_copy[MAXSTRING]; int red=0, green=0, blue=0; *sz_spec_copy = '\0'; UtilStrCpyN(sz_spec_copy, sizeof(sz_spec_copy), spec); UtilTrimBlanks(sz_spec_copy); if ((psz=strtok(sz_spec_copy, " ,\t\n\r")) == NULL || sscanf(psz, "%d", &red) != 1) { sprintf(gszMsgBox, TgLoadString(STID_ERR_PARSE_THRESH_COLORS), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (red < 0) red = 0; if (red > 255) red = 255; psz = strtok(NULL, " ,\t\n\r"); if (psz == NULL) { fillReplaceRedThresh = fillReplaceGreenThresh = fillReplaceBlueThresh = red; return TRUE; } if (sscanf(psz, "%d", &green) != 1) { sprintf(gszMsgBox, TgLoadString(STID_ERR_PARSE_THRESH_COLORS), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (green < 0) green = 0; if (green > 255) green = 255; psz = strtok(NULL, " ,\t\n\r"); if (psz == NULL || sscanf(psz, "%d", &blue) != 1) { sprintf(gszMsgBox, TgLoadString(STID_ERR_PARSE_THRESH_COLORS), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (blue < 0) blue = 0; if (blue > 255) blue = 255; psz = strtok(NULL, " ,\t\n\r"); if (psz != NULL) { sprintf(gszMsgBox, TgLoadString(STID_ERR_PARSE_THRESH_COLORS), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } fillReplaceRedThresh = red; fillReplaceGreenThresh = green; fillReplaceBlueThresh = blue; return TRUE; } static void ResetThreshFillReplaceInfo() { if (threshFillReplaceEnabled) { gThreshFillReplaceInfo.use_thresholding = TRUE; if (fullTrueColorMode) { SetupTrueColorInfo(&gThreshFillReplaceInfo.tci); } } else { gThreshFillReplaceInfo.use_thresholding = FALSE; } } static int TrueColorPixelWithinRange(pixel, ptfri) int pixel; ThreshFillReplaceInfo *ptfri; { uint32_t pix=(uint32_t)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; TrueColorInfo *ptci=(&ptfri->tci); XColor xcolor; r = (pix & ptci->r_mask) >> ptci->r_shift; g = (pix & ptci->g_mask) >> ptci->g_shift; b = (pix & ptci->b_mask) >> ptci->b_shift; dr = ((double)r) / ptci->dr_maxval_div255; dg = ((double)g) / ptci->dg_maxval_div255; db = ((double)b) / ptci->db_maxval_div255; xcolor.red = round(dr); xcolor.green = round(dg); xcolor.blue = round(db); if (xcolor.red > 255) xcolor.red = 255; if (xcolor.green > 255) xcolor.green = 255; if (xcolor.blue > 255) xcolor.blue = 255; return (xcolor.red >= ptfri->min_r && xcolor.red <= ptfri->max_r && xcolor.green >= ptfri->min_g && xcolor.green <= ptfri->max_g && xcolor.blue >= ptfri->min_b && xcolor.blue <= ptfri->max_b); } static int OtherPixelWithinRange(pixel, ptfri) int pixel; ThreshFillReplaceInfo *ptfri; { double dr=(double)0, dg=(double)0, db=(double)0; XColor xcolor; int global_color_index=(-1); if (!HashLookUpInt(&ptfri->hash_table, (char*)(&pixel), sizeof(int), &global_color_index)) { return FALSE; } if (global_color_index == (-1)) { return FALSE; } memcpy(&xcolor, &tgifColors[global_color_index], sizeof(XColor)); dr = ((double)xcolor.red) / ((double)maxRGB) * ((double)255); dg = ((double)xcolor.green) / ((double)maxRGB) * ((double)255); db = ((double)xcolor.blue) / ((double)maxRGB) * ((double)255); xcolor.red = round(dr); xcolor.green = round(dg); xcolor.blue = round(db); if (xcolor.red > 255) xcolor.red = 255; if (xcolor.green > 255) xcolor.green = 255; if (xcolor.blue > 255) xcolor.blue = 255; return (xcolor.red >= ptfri->min_r && xcolor.red <= ptfri->max_r && xcolor.green >= ptfri->min_g && xcolor.green <= ptfri->max_g && xcolor.blue >= ptfri->min_b && xcolor.blue <= ptfri->max_b); } static int GetPixelRGB(ptfri, pixel, pxc_pixel) ThreshFillReplaceInfo *ptfri; int pixel; XColor *pxc_pixel; { if (fullTrueColorMode) { uint32_t pix=(uint32_t)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; TrueColorInfo *ptci=(&ptfri->tci); XColor xcolor; r = (pix & ptci->r_mask) >> ptci->r_shift; g = (pix & ptci->g_mask) >> ptci->g_shift; b = (pix & ptci->b_mask) >> ptci->b_shift; dr = ((double)r) / ptci->dr_maxval_div255; dg = ((double)g) / ptci->dg_maxval_div255; db = ((double)b) / ptci->db_maxval_div255; pxc_pixel->red = round(dr); pxc_pixel->green = round(dg); pxc_pixel->blue = round(db); if (pxc_pixel->red > 255) pxc_pixel->red = 255; if (pxc_pixel->green > 255) pxc_pixel->green = 255; if (pxc_pixel->blue > 255) xcolor.blue = 255; } else { int i=0, global_color_index=(-1); for (i=0; i < maxColors; i++) { if (pixel == colorPixels[i]) { global_color_index = i; break; } } if (global_color_index != (-1)) { double dr=(double)0, dg=(double)0, db=(double)0; memcpy(pxc_pixel, &tgifColors[global_color_index], sizeof(XColor)); dr = ((double)pxc_pixel->red) / ((double)maxRGB) * ((double)255); dg = ((double)pxc_pixel->green) / ((double)maxRGB) * ((double)255); db = ((double)pxc_pixel->blue) / ((double)maxRGB) * ((double)255); pxc_pixel->red = round(dr); pxc_pixel->green = round(dg); pxc_pixel->blue = round(db); if (pxc_pixel->red > 255) pxc_pixel->red = 255; if (pxc_pixel->green > 255) pxc_pixel->green = 255; if (pxc_pixel->blue > 255) pxc_pixel->blue = 255; } else { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "Canot find pixel indel for pixel=0x%08x in GetPixelRGB().\n", pixel); #endif /* _TGIF_DBG */ return FALSE; } } return TRUE; } static int SetupThreshFillReplaceInfo(ptfri, pixel, pxc_pixel) ThreshFillReplaceInfo *ptfri; int pixel; XColor *pxc_pixel; { if (fullTrueColorMode) { if (!GetPixelRGB(ptfri, pixel, pxc_pixel)) return FALSE; ptfri->min_r = (int)(pxc_pixel->red) - fillReplaceRedThresh; ptfri->max_r = (int)(pxc_pixel->red) + fillReplaceRedThresh; if (ptfri->min_r < 0) ptfri->min_r = 0; if (ptfri->max_r > 255) ptfri->max_r = 255; ptfri->min_g = (int)(pxc_pixel->green) - fillReplaceGreenThresh; ptfri->max_g = (int)(pxc_pixel->green) + fillReplaceGreenThresh; if (ptfri->min_g < 0) ptfri->min_g = 0; if (ptfri->max_g > 255) ptfri->max_g = 255; ptfri->min_b = (int)(pxc_pixel->blue) - fillReplaceBlueThresh; ptfri->max_b = (int)(pxc_pixel->blue) + fillReplaceBlueThresh; if (ptfri->min_b < 0) ptfri->min_b = 0; if (ptfri->max_b > 255) ptfri->max_b = 255; } else { int i=0; TgHash *pth=(&ptfri->hash_table); int global_color_index=(-1); InitHash(pth, TG_HASH_SIZE_LARGE); for (i=0; i < maxColors; i++) { HashStoreInt(pth, (char*)(&colorPixels[i]), sizeof(int), i); } if (HashLookUpInt(pth, (char*)(&pixel), sizeof(int), &global_color_index)) { double dr=(double)0, dg=(double)0, db=(double)0; XColor xcolor; ptfri->within_threshold = (int*)malloc(maxColors*sizeof(int)); if (ptfri->within_threshold == NULL) FailAllocMessage(); memset(ptfri->within_threshold, 0, maxColors*sizeof(int)); memcpy(&xcolor, &tgifColors[global_color_index], sizeof(XColor)); dr = ((double)xcolor.red) / ((double)maxRGB) * ((double)255); dg = ((double)xcolor.green) / ((double)maxRGB) * ((double)255); db = ((double)xcolor.blue) / ((double)maxRGB) * ((double)255); xcolor.red = round(dr); xcolor.green = round(dg); xcolor.blue = round(db); if (xcolor.red > 255) xcolor.red = 255; if (xcolor.green > 255) xcolor.green = 255; if (xcolor.blue > 255) xcolor.blue = 255; ptfri->min_r = (int)(xcolor.red) - fillReplaceRedThresh; ptfri->max_r = (int)(xcolor.red) + fillReplaceRedThresh; if (ptfri->min_r < 0) ptfri->min_r = 0; if (ptfri->max_r > 255) ptfri->max_r = 255; ptfri->min_g = (int)(xcolor.green) - fillReplaceGreenThresh; ptfri->max_g = (int)(xcolor.green) + fillReplaceGreenThresh; if (ptfri->min_g < 0) ptfri->min_g = 0; if (ptfri->max_g > 255) ptfri->max_g = 255; ptfri->min_b = (int)(xcolor.blue) - fillReplaceBlueThresh; ptfri->max_b = (int)(xcolor.blue) + fillReplaceBlueThresh; if (ptfri->min_b < 0) ptfri->min_b = 0; if (ptfri->max_b > 255) ptfri->max_b = 255; for (i=0; i < maxColors; i++) { ptfri->within_threshold[i] = OtherPixelWithinRange(colorPixels[i], ptfri); } } else { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "HashLookup() failed in SetupThreshFillReplaceInfo() for pixel=0x%08x.\n", pixel); #endif /* _TGIF_DBG */ return FALSE; } } return TRUE; } static int DoPpm6(xpm_ptr) struct XPmRec *xpm_ptr; { if (gnCombining || xpm_ptr == NULL) { return (fullTrueColorMode && HasZlibSupport()); } else if (xpm_ptr != NULL && (xpm_ptr->real_type == PPM_TRUE || xpm_ptr->real_type == XPM_JPEG) && xpm_ptr->ppm_mask_data == NULL && fullTrueColorMode && HasZlibSupport()) { return TRUE; } return FALSE; } static int FreePreprocessPixels(h, xcolors) int h; XColor **xcolors; { int i=0; for (i=0; i < h; i++) { if (xcolors[i] != NULL) { free(xcolors[i]); } else { break; } } free(xcolors); gConvExtraInfo.xcolors = NULL; return FALSE; } static void ClearConvExtraInfo() { if (gConvExtraInfo.xcolors != NULL) { FreePreprocessPixels(gConvExtraInfo.image_h, gConvExtraInfo.xcolors); } if (gConvExtraInfo.alpha_xcolors != NULL) { FreePreprocessPixels(gConvExtraInfo.alpha_image_h, gConvExtraInfo.alpha_xcolors); } if (gConvExtraInfo.bg_xcolors != NULL) { FreePreprocessPixels(gConvExtraInfo.bg_image_h, gConvExtraInfo.bg_xcolors); } memset(&gConvExtraInfo, 0, sizeof(ConvExtraInfo)); } static XColor **PreprocessOneImagePixels(w, h, image, bitmap_image) int w, h; XImage *image, *bitmap_image; { int i=0; XColor **xcolors=NULL; ProgressInfo pi; xcolors = (XColor**)malloc(h*sizeof(XColor*)); if (xcolors == NULL) { FailAllocMessage(); return NULL; } memset(xcolors, 0, h*sizeof(XColor*)); for (i=0; i < h; i++) { xcolors[i] = (XColor*)malloc(w*sizeof(XColor)); if (xcolors[i] == NULL) { FailAllocMessage(); FreePreprocessPixels(h, xcolors); return NULL; } memset(xcolors[i], 0, w*sizeof(XColor)); } BeginProgress(&pi, h); for (i=0; i < h; i++) { int j=0; UpdateProgress(&pi, i); for (j=0; j < w; j++) { if (bitmap_image != NULL && XGetPixel(bitmap_image,j,i) == 0) { TgAssert(FALSE, "transparent pixel not supported", NULL); FreePreprocessPixels(h, xcolors); return NULL; } else { unsigned int pixel=(unsigned int)XGetPixel(image,j,i); uint32_t pix=(uint32_t)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval_div255; dg = ((double)g) / gTrueColorInfo.dg_maxval_div255; db = ((double)b) / gTrueColorInfo.db_maxval_div255; xcolors[i][j].red = round(dr); xcolors[i][j].green = round(dg); xcolors[i][j].blue = round(db); if (xcolors[i][j].red > 255) xcolors[i][j].red = 255; if (xcolors[i][j].green > 255) xcolors[i][j].green = 255; if (xcolors[i][j].blue > 255) xcolors[i][j].blue = 255; xcolors[i][j].pixel = pixel; } } } return xcolors; } static int PreprocessPixels() { if (gConvExtraInfo.alpha_combine) { memset(&gConvExtraInfo.my_bg_xcolor, 0, sizeof(XColor)); unsigned int r=(unsigned int)myBgColor.red; unsigned int g=(unsigned int)myBgColor.green; unsigned int b=(unsigned int)myBgColor.blue; double dr=((double)r)/((double)maxRGB)*((double)255); double dg=((double)g)/((double)maxRGB)*((double)255); double db=((double)b)/((double)maxRGB)*((double)255); gConvExtraInfo.my_bg_xcolor.red = round(dr); gConvExtraInfo.my_bg_xcolor.green = round(dg); gConvExtraInfo.my_bg_xcolor.blue = round(db); gConvExtraInfo.my_bg_xcolor.pixel = myBgPixel; /* foreground object */ gConvExtraInfo.xcolors = PreprocessOneImagePixels( gConvExtraInfo.image_w, gConvExtraInfo.image_h, gConvExtraInfo.image, gConvExtraInfo.bitmap_image); if (gConvExtraInfo.xcolors == NULL) { return FALSE; } /* background object */ gConvExtraInfo.bg_xcolors = PreprocessOneImagePixels( gConvExtraInfo.bg_image_w, gConvExtraInfo.bg_image_h, gConvExtraInfo.bg_image, gConvExtraInfo.bg_bitmap_image); if (gConvExtraInfo.bg_xcolors == NULL) { return FALSE; } if (gpConvolveCmdID == CMDID_ALPHACOMBINE) { gConvExtraInfo.alpha_xcolors = PreprocessOneImagePixels( gConvExtraInfo.alpha_image_w, gConvExtraInfo.alpha_image_h, gConvExtraInfo.alpha_image, gConvExtraInfo.alpha_bitmap_image); if (gConvExtraInfo.alpha_xcolors == NULL) { return FALSE; } } } else { gConvExtraInfo.xcolors = PreprocessOneImagePixels(gConvExtraInfo.image_w, gConvExtraInfo.image_h, gConvExtraInfo.image, gConvExtraInfo.bitmap_image); if (gConvExtraInfo.xcolors == NULL) { return FALSE; } if (gpConvolveCmdID == CMDID_VECTORWARP) { gConvExtraInfo.bg_xcolors = PreprocessOneImagePixels( gConvExtraInfo.image_w, gConvExtraInfo.image_h, gConvExtraInfo.image, gConvExtraInfo.bitmap_image); if (gConvExtraInfo.bg_xcolors == NULL) { return FALSE; } } } return TRUE; } static int SetConvExtraInfo(fp, image_w, image_h, image, bitmap_image) FILE *fp; int image_w, image_h; XImage *image, *bitmap_image; { memset(&gConvExtraInfo, 0, sizeof(ConvExtraInfo)); gConvExtraInfo.fp = fp; gConvExtraInfo.image_w = gConvExtraInfo.bg_image_w = image_w; gConvExtraInfo.image_h = gConvExtraInfo.bg_image_h = image_h; gConvExtraInfo.image = image; gConvExtraInfo.bitmap_image = bitmap_image; switch (gpConvolveCmdID) { case CMDID_EDGEDETECT: case CMDID_EMBOSS: case CMDID_SPREAD: case CMDID_SHARPEN: case CMDID_BLUR3: case CMDID_VECTORWARP: if (!PreprocessPixels()) { return FALSE; } break; case CMDID_SUBTRACT: case CMDID_XORCOLORS: gConvExtraInfo.alpha_combine = TRUE; gConvExtraInfo.final_w = gnCombineW; gConvExtraInfo.final_h = gnCombineH; gConvExtraInfo.image_w = gFgCombineBBox.rbx-gFgCombineBBox.ltx; gConvExtraInfo.image_h = gFgCombineBBox.rby-gFgCombineBBox.lty; gConvExtraInfo.image = gpFgImage; gConvExtraInfo.bitmap_image = gpFgBitmapImage; if (!InitTrueColorInfo(gConvExtraInfo.image, &gTrueColorInfo, gConvExtraInfo.image_w)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), gConvExtraInfo.image_w, gConvExtraInfo.image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } gConvExtraInfo.bg_image_w = gBgCombineBBox.rbx-gBgCombineBBox.ltx; gConvExtraInfo.bg_image_h = gBgCombineBBox.rby-gBgCombineBBox.lty; gConvExtraInfo.bg_image = gpBgImage; gConvExtraInfo.bg_bitmap_image = gpBgBitmapImage; if (!PreprocessPixels()) { return FALSE; } break; case CMDID_ALPHACOMBINE: gConvExtraInfo.alpha_combine = TRUE; gConvExtraInfo.final_w = gnCombineW; gConvExtraInfo.final_h = gnCombineH; gConvExtraInfo.image_w = gFgCombineBBox.rbx-gFgCombineBBox.ltx; gConvExtraInfo.image_h = gFgCombineBBox.rby-gFgCombineBBox.lty; gConvExtraInfo.image = gpFgImage; gConvExtraInfo.bitmap_image = gpFgBitmapImage; if (!InitTrueColorInfo(gConvExtraInfo.image, &gTrueColorInfo, gConvExtraInfo.image_w)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), gConvExtraInfo.image_w, gConvExtraInfo.image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } gConvExtraInfo.alpha_image_w = gAlphaCombineBBox.rbx-gAlphaCombineBBox.ltx; gConvExtraInfo.alpha_image_h = gAlphaCombineBBox.rby-gAlphaCombineBBox.lty; gConvExtraInfo.alpha_image = gpAlphaImage; gConvExtraInfo.alpha_bitmap_image = gpAlphaBitmapImage; gConvExtraInfo.bg_image_w = gBgCombineBBox.rbx-gBgCombineBBox.ltx; gConvExtraInfo.bg_image_h = gBgCombineBBox.rby-gBgCombineBBox.lty; gConvExtraInfo.bg_image = gpBgImage; gConvExtraInfo.bg_bitmap_image = gpBgBitmapImage; if (!PreprocessPixels()) { return FALSE; } break; default: break; } return TRUE; } static char *GetImageProcName(nCmdId) int nCmdId; { TgMenuItemInfo *item_info=NULL; for (item_info=imageProcMenuInfo.items; item_info->menu_str != NULL; item_info++) { if (item_info->menu_str != TGMUITEM_SEPARATOR && item_info->cmdid == nCmdId) { /* must use gettext() here */ return _(item_info->menu_str); } else if (item_info->shortcut_str == TGMUITEM_SUBMENU) { TgMenuInfo *submenu_info=item_info->submenu_info; TgMenuItemInfo *submenu_item_info=NULL; for (submenu_item_info=submenu_info->items; submenu_item_info->menu_str != NULL; submenu_item_info++) { if (submenu_item_info->menu_str != TGMUITEM_SEPARATOR && submenu_item_info->cmdid == nCmdId) { /* must use gettext() here */ return _(submenu_item_info->menu_str); } } } } return TgLoadCachedString(CSTID_PARANED_UNKNOWN); } static int TrueColorTransPixelCheck(obj_ptr, cmdid) struct ObjRec *obj_ptr; int cmdid; { if (ObjHasTrueColorTransPixel(obj_ptr, NULL, NULL, NULL)) { sprintf(gszMsgBox, TgLoadString(STID_BAD_CMD_FOR_TRANS_PPMTRUE), GetImageProcName(cmdid)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return TRUE; } return FALSE; } static int CurColorIsTranscolor(trans_color_r, trans_color_g, trans_color_b) unsigned char trans_color_r, trans_color_g, trans_color_b; { TrueColorInfo tci; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; uint32_t pixel=0; double dmaxval=(double)255; if (!SetupTrueColorInfo(&tci)) return FALSE; r = (unsigned int)trans_color_r; g = (unsigned int)trans_color_g; b = (unsigned int)trans_color_b; dr = ((double)r) / dmaxval * tci.dr_maxval; dg = ((double)g) / dmaxval * tci.dg_maxval; db = ((double)b) / dmaxval * tci.db_maxval; r = round(dr); g = round(dg); b = round(db); pixel = ((r << tci.r_shift) & mainVisual->red_mask) | ((g << tci.g_shift) & mainVisual->green_mask) | ((b << tci.b_shift) & mainVisual->blue_mask) ; return (((int)pixel) == colorPixels[colorIndex]); } static int CheckSelectionForImageProc(cmdid) int cmdid; { char szBuf[MAXSTRING+1]; UtilStrCpyN(szBuf, sizeof(szBuf), GetImageProcName(cmdid)); if (topSel == NULL || topSel != botSel || topSel->obj->type != OBJ_XPM) { sprintf(gszMsgBox, TgLoadString(STID_SINGLE_XPM_IMGPROC), szBuf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (topSel->obj->fattr != NULL) { sprintf(gszMsgBox, TgLoadString(STID_XPM_HAS_ATTR_IMGPROC), szBuf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return TRUE; } #define LONG_AXIS_IS_RED 0 #define LONG_AXIS_IS_GREEN 1 #define LONG_AXIS_IS_BLUE 2 typedef struct CubeRec { /* not really a ``cube'' */ int min_index, max_index, level, long_axis; unsigned long num_points; unsigned short red_length, green_length, blue_length; } *CubePointer; typedef struct HGBucketRec { int index; struct HGBucketRec *next; } *HGBucketPoiner; static struct HGBucketRec *gaHGBucket[256]; typedef struct tagTmpBucketInfo { int pixel; int index; struct tagTmpBucketInfo *next; } TmpBucketInfo; static XColor *gpHistogram=NULL; static int *gpnSortedIndex=NULL; static int **gnOrigImageIndex=NULL, **gnFinalImageIndex=NULL; static int gnImageW=(-1), gnImageH=(-1); static int *gpnPixelToIndexMap=NULL, gnPixelToIndexMapSize=0; static int gnHistogramEntries=0, gnHistogramSize=0; static int gnQuantizingLevels=222, gnUserSpecifiedLevels=(-1); static struct CubeRec *gpCube=NULL; static int gnCubeEntries=0; static int gnTransparentIndex=(-1); static int GetXPmImages(xpm_ptr, p_image, p_bitmap_image) struct XPmRec *xpm_ptr; XImage **p_image, **p_bitmap_image; { Pixmap pixmap=xpm_ptr->pixmap, bitmap=xpm_ptr->bitmap; int image_w=xpm_ptr->image_w, image_h=xpm_ptr->image_h; *p_image = XGetImage(mainDisplay, pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (bitmap != None) { *p_bitmap_image = XGetImage(mainDisplay, bitmap, 0, 0, image_w, image_h, 1, ZPixmap); } else { *p_bitmap_image = NULL; } if ((*p_image) == NULL || (bitmap != None && (*p_bitmap_image) == NULL)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return TRUE; } static void CleanUpTmpBuckets() { if (gpnPixelToIndexMap != NULL) { int i=0; TmpBucketInfo **buckets=(TmpBucketInfo**)gpnPixelToIndexMap; for (i=0; i < gnPixelToIndexMapSize; i++) { TmpBucketInfo *ptbi=NULL, *ptbi_next=NULL; for (ptbi=buckets[i]; ptbi != NULL; ptbi=ptbi_next) { ptbi_next = ptbi->next; free(ptbi); } } free(buckets); gpnPixelToIndexMap = NULL; } gnPixelToIndexMapSize = 0; } static void CleanUpIndexOfPixel() { if (mainVisual->class == TrueColor) { CleanUpTmpBuckets(); } else { if (gpnPixelToIndexMap != NULL) free(gpnPixelToIndexMap); gpnPixelToIndexMap = NULL; gnPixelToIndexMapSize = 0; } } void CleanUpConvolution() { register int i; CleanUpIndexOfPixel(); if (gpHistogram != NULL) { free(gpHistogram); gpHistogram = NULL; } if (gpnSortedIndex != NULL) { free(gpnSortedIndex); gpnSortedIndex = NULL; } gnHistogramEntries = gnHistogramSize = 0; if (gpCube != NULL) { free(gpCube); gpCube = NULL; } gnCubeEntries = 0; if (gnOrigImageIndex != NULL) { for (i=0; i < gnImageH; i++) { if (gnOrigImageIndex[i] != NULL) { free(gnOrigImageIndex[i]); } else { break; } } free(gnOrigImageIndex); gnOrigImageIndex = NULL; } if (gnFinalImageIndex != NULL) { for (i=0; i < gnImageH; i++) { if (gnFinalImageIndex[i] != NULL) { free(gnFinalImageIndex[i]); } else { break; } } free(gnFinalImageIndex); gnFinalImageIndex = NULL; } gnImageW = gnImageH = (-1); for (i=0; i < 256; i++) { if (gaHGBucket[i] != NULL) { struct HGBucketRec *bucket_ptr=gaHGBucket[i], *next_bucket; for ( ; bucket_ptr != NULL; bucket_ptr=next_bucket) { next_bucket = bucket_ptr->next; free(bucket_ptr); } gaHGBucket[i] = NULL; } } } static int GetOrAllocHistogramIndex(pcolor) XColor *pcolor; { int hashvalue=0; if (pcolor == NULL) { if (gnTransparentIndex != (-1)) return gnTransparentIndex; } else { struct HGBucketRec *bucket_ptr; hashvalue = (int)((pcolor->red ^ pcolor->green ^ pcolor->blue) & 0xff); if (gaHGBucket[hashvalue] != NULL) { struct HGBucketRec *bucket_ptr=gaHGBucket[hashvalue]; for ( ; bucket_ptr != NULL; bucket_ptr=bucket_ptr->next) { int i=bucket_ptr->index; if (gpHistogram[i].red == pcolor->red && gpHistogram[i].green == pcolor->green && gpHistogram[i].blue == pcolor->blue) { HISTOGRAMCOUNT(i)++; return i; } } } bucket_ptr = (struct HGBucketRec *)malloc(sizeof(struct HGBucketRec)); if (bucket_ptr == NULL) { FailAllocMessage(); return (-1); } bucket_ptr->index = gnHistogramEntries; bucket_ptr->next = gaHGBucket[hashvalue]; gaHGBucket[hashvalue] = bucket_ptr; } if (gnHistogramEntries >= gnHistogramSize) { gnHistogramSize += 256; if ((gpHistogram=(XColor*)realloc(gpHistogram, gnHistogramSize*sizeof(XColor))) == NULL) { FailAllocMessage(); return (-1); } } memset(&gpHistogram[gnHistogramEntries], 0, sizeof(XColor)); HISTOGRAMCOUNT(gnHistogramEntries) = 1; if (pcolor == NULL) { gpHistogram[gnHistogramEntries].red = 0; gpHistogram[gnHistogramEntries].green = 0; gpHistogram[gnHistogramEntries].blue = 0; } else { gpHistogram[gnHistogramEntries].red = pcolor->red; gpHistogram[gnHistogramEntries].green = pcolor->green; gpHistogram[gnHistogramEntries].blue = pcolor->blue; } return (gnHistogramEntries++); } static int PixelToIndexHash(pixel) int pixel; { return (((pixel)==(-1)) ? (gnPixelToIndexMapSize-1) : (pixel % gnPixelToIndexMapSize)); } static int GetIndexOfPixel(pixel) int pixel; { if (mainVisual->class == TrueColor) { TmpBucketInfo **buckets=(TmpBucketInfo**)gpnPixelToIndexMap, *ptbi=NULL; int bucket=PixelToIndexHash(pixel); for (ptbi=buckets[bucket]; ptbi != NULL; ptbi=ptbi->next) { if (ptbi->pixel == pixel) { return ptbi->index; } } return INVALID; } else { return gpnPixelToIndexMap[pixel]; } } static void UpdatePixelToIndexMapping(buckets, pixel, index) TmpBucketInfo **buckets; int pixel, index; { int bucket=PixelToIndexHash(pixel); TmpBucketInfo *ptbi=NULL; for (ptbi=buckets[bucket]; ptbi != NULL; ptbi=ptbi->next) { if (ptbi->pixel == pixel) { return; } } ptbi = (TmpBucketInfo *)malloc(sizeof(TmpBucketInfo)); if (ptbi == NULL) FailAllocMessage(); memset(ptbi, 0, sizeof(TmpBucketInfo)); ptbi->next = buckets[bucket]; buckets[bucket] = ptbi; ptbi->pixel = pixel; ptbi->index = index; } static int AllocTmpBuckets(populate_with_color_pixels) int populate_with_color_pixels; { TmpBucketInfo **buckets=(TmpBucketInfo **)gpnPixelToIndexMap; gnPixelToIndexMapSize = 257; buckets = (TmpBucketInfo**)malloc(gnPixelToIndexMapSize * sizeof(TmpBucketInfo*)); if (buckets == NULL) { FailAllocMessage(); return FALSE; } memset(buckets, 0, gnPixelToIndexMapSize*sizeof(TmpBucketInfo*)); gpnPixelToIndexMap = (int*)buckets; if (populate_with_color_pixels) { int i=0; for (i=0; i < maxColors; i++) { UpdatePixelToIndexMapping(buckets, colorPixels[i], i); } } return TRUE; } static int CreatePixelToIndexMapping() { register int i=0; if (mainVisual->class == TrueColor) { if (!AllocTmpBuckets(TRUE)) { CleanUpConvolution(); return FALSE; } } else { int max_pixel=(-1); for (i=0; i < maxColors; i++) { if (colorPixels[i] > max_pixel) { max_pixel = colorPixels[i]; } } if (max_pixel == (-1)) return FALSE; gpnPixelToIndexMap = (int*)malloc((max_pixel+1)*sizeof(int)); if (gpnPixelToIndexMap == NULL) { FailAllocMessage(); CleanUpConvolution(); return FALSE; } memset(gpnPixelToIndexMap, (-1), (max_pixel+1)*sizeof(int)); for (i=0; i < maxColors; i++) { gpnPixelToIndexMap[colorPixels[i]] = i; } } return TRUE; } static int CreateObjPixelToIndexMapping(xpm_ptr) struct XPmRec *xpm_ptr; { register int i=0; gnTransparentIndex = (-1); if (mainVisual->class == TrueColor) { int start_index=0; XColor *xcolors=NULL; xcolors = (XColor*)malloc(xpm_ptr->ncolors*sizeof(XColor)); if (xcolors == NULL) FailAllocMessage(); memset(xcolors, 0, xpm_ptr->ncolors*sizeof(XColor)); if (!AllocTmpBuckets(TRUE)) { free(xcolors); CleanUpConvolution(); return FALSE; } start_index = (xpm_ptr->first_pixel_is_bg ? 1 : 0); for (i=start_index; i < xpm_ptr->ncolors; i++) { int pixel=xpm_ptr->pixels[i]; /* do not translate -- program constants */ if (UtilStrICmp(xpm_ptr->color_str[i], "None") == 0) { if (gnTransparentIndex == (-1)) { gnTransparentIndex = GetOrAllocHistogramIndex(NULL); } } else { ((ImageMapColorFunc*)gpImageMapColorFunc)(GetIndexOfPixel(pixel), &xcolors[i]); } } CleanUpTmpBuckets(); if (!AllocTmpBuckets(FALSE)) { free(xcolors); CleanUpConvolution(); return FALSE; } for (i=start_index; i < xpm_ptr->ncolors; i++) { UpdatePixelToIndexMapping((TmpBucketInfo**)gpnPixelToIndexMap, xpm_ptr->pixels[i], GetOrAllocHistogramIndex(&xcolors[i])); } free(xcolors); } else { int max_pixel=(-1), start_index, *pixel_to_index_map=NULL; for (i=0; i < maxColors; i++) { if (colorPixels[i] > max_pixel) { max_pixel = colorPixels[i]; } } if (max_pixel == (-1)) return FALSE; gpnPixelToIndexMap = (int*)malloc((max_pixel+1)*sizeof(int)); pixel_to_index_map = (int*)malloc((max_pixel+1)*sizeof(int)); if (gpnPixelToIndexMap == NULL || pixel_to_index_map == NULL) { if (gpnPixelToIndexMap != NULL) free(gpnPixelToIndexMap); if (pixel_to_index_map != NULL) free(pixel_to_index_map); gpnPixelToIndexMap = NULL; FailAllocMessage(); CleanUpConvolution(); return FALSE; } memset(gpnPixelToIndexMap, (-1), (max_pixel+1)*sizeof(int)); memset(pixel_to_index_map, (-1), (max_pixel+1)*sizeof(int)); for (i=0; i < maxColors; i++) { pixel_to_index_map[colorPixels[i]] = i; } start_index = (xpm_ptr->first_pixel_is_bg ? 1 : 0); for (i=start_index; i < xpm_ptr->ncolors; i++) { XColor xcolor; int pixel=xpm_ptr->pixels[i]; memset(&xcolor, 0, sizeof(XColor)); /* do not translate -- program constants */ if (UtilStrICmp(xpm_ptr->color_str[i], "None") == 0) { if (gnTransparentIndex == (-1)) { gnTransparentIndex = GetOrAllocHistogramIndex(NULL); } } else { ((ImageMapColorFunc*)gpImageMapColorFunc)(pixel_to_index_map[pixel], &xcolor); gpnPixelToIndexMap[pixel] = GetOrAllocHistogramIndex(&xcolor); } } free(pixel_to_index_map); } return TRUE; } static int DumpConvolution(fp) FILE *fp; { register int j, i; int chars_per_pixel=(gnHistogramEntries > 20 ? 2 : 1); char c0[27], c1[11]; ProgressInfo pi; /* do not translate -- program constants */ strcpy(c0, "abcdefghijklmnopqrstuvwxyz"); strcpy(c1, "0123456789"); if (fprintf(fp, "#define conv_format 1\n") == EOF || fprintf(fp, "#define conv_width %1d\n", gnImageW) == EOF || fprintf(fp, "#define conv_height %1d\n", gnImageH) == EOF || fprintf(fp, "#define conv_ncolors %1d\n", gnHistogramEntries) == EOF || fprintf(fp, "#define conv_chars_per_pixel %1d\n", chars_per_pixel) == EOF || fprintf(fp, "static char *conv_colors[] = {\n") == EOF) { writeFileFailed = TRUE; } for (j=0; j < gnHistogramEntries; j++) { int red=(int)gpHistogram[j].red; int green=(int)gpHistogram[j].green; int blue=(int)gpHistogram[j].blue; /* do not translate -- program constants */ if (gnTransparentIndex == j) { if (chars_per_pixel == 1) { if (fprintf(fp, " \"%c\", \"None\"", c0[j]) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(fp, " \"%c%c\", \"None\"", c0[(int)(j/10)], c1[j % 10]) == EOF) { writeFileFailed = TRUE; } } } else { if (chars_per_pixel == 1) { if (fprintf(fp, " \"%c\", \"#%04x%04x%04x\"", c0[j], red&0x0ffff, green&0x0ffff, blue&0x0ffff) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(fp, " \"%c%c\", \"#%04x%04x%04x\"", c0[(int)(j/10)], c1[j % 10], red&0x0ffff, green&0x0ffff, blue&0x0ffff) == EOF) { writeFileFailed = TRUE; } } } if (j == gnHistogramEntries-1) { fprintf(fp, "\n};\n"); } else { fprintf(fp, ",\n"); } } if (fprintf(fp, "static char *conv_pixels[] = {\n") == EOF) { writeFileFailed = TRUE; } BeginProgress(&pi, gnImageH); for (i=0; i < gnImageH; i++) { UpdateProgress(&pi, i); fprintf(fp, "\""); for (j=0; j < gnImageW; j++) { int index=gnFinalImageIndex[i][j]; if (chars_per_pixel == 1) { if (fprintf(fp, "%c", c0[index]) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(fp, "%c%c", c0[(int)(index/10)], c1[index % 10]) == EOF) { writeFileFailed = TRUE; } } } if (i == gnImageH-1) { if (fprintf(fp, "\"\n};\n") == EOF) writeFileFailed = TRUE; } else { if (fprintf(fp, "\",\n") == EOF) writeFileFailed = TRUE; } } return TRUE; } static int gnDebugQuantization=FALSE; static int DumpQuantizedConvolution(fp) FILE *fp; { register int j, i; int chars_per_pixel=(gnCubeEntries > 20 ? 2 : 1); char c0[27], c1[11]; ProgressInfo pi; /* do not translate -- program constants */ strcpy(c0, "abcdefghijklmnopqrstuvwxyz"); strcpy(c1, "0123456789"); if (fprintf(fp, "#define conv_format 1\n") == EOF || fprintf(fp, "#define conv_width %1d\n", gnImageW) == EOF || fprintf(fp, "#define conv_height %1d\n", gnImageH) == EOF || fprintf(fp, "#define conv_ncolors %1d\n", gnCubeEntries) == EOF || fprintf(fp, "#define conv_chars_per_pixel %1d\n", chars_per_pixel) == EOF || fprintf(fp, "static char *conv_colors[] = {\n") == EOF) { writeFileFailed = TRUE; } if (gnDebugQuantization) { /* debug, do not translate */ fprintf(stderr, "Dumping colors...\n"); } for (j=0; j < gnCubeEntries; j++) { int min_index=gpCube[j].min_index; int max_index=gpCube[j].max_index; int idx=gpnSortedIndex[min_index]; double num_points=(double)HISTOGRAMCOUNT(idx); double red=((double)HISTOGRAMRED(idx))*num_points; double green=((double)HISTOGRAMGREEN(idx))*num_points; double blue=((double)HISTOGRAMBLUE(idx))*num_points; long lred, lgreen, lblue; for (i=min_index+1; i <= max_index; i++) { double n; idx = gpnSortedIndex[i]; n = (double)HISTOGRAMCOUNT(idx); num_points += n; red += ((long)HISTOGRAMRED(idx))*n; green += ((long)HISTOGRAMGREEN(idx))*n; blue += ((long)HISTOGRAMBLUE(idx))*n; } red /= num_points; green /= num_points; blue /= num_points; lred = (long)red; lgreen = (long)green; lblue = (long)blue; if (gnDebugQuantization) { fprintf(stderr, "\t#%02x%02x%02x %6ld\n", (int)((lred>>8) & 0xff), (int)((lgreen>>8) & 0xff), (int)((lblue>>8) & 0xff), (long)num_points); } if (chars_per_pixel == 1) { if (fprintf(fp, " \"%c\", \"#%04x%04x%04x\"", c0[j], (int)(lred&0x0ffff), (int)(lgreen&0x0ffff), (int)(lblue&0x0ffff)) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(fp, " \"%c%c\", \"#%04x%04x%04x\"", c0[(int)(j/10)], c1[j % 10], (int)(lred&0x0ffff), (int)(lgreen&0x0ffff), (int)(lblue&0x0ffff)) == EOF) { writeFileFailed = TRUE; } } if (j == gnCubeEntries-1) { fprintf(fp, "\n};\n"); } else { fprintf(fp, ",\n"); } /* * use the gpHistogram[*].pixel as the reverse color index */ for (i=min_index; i <= max_index; i++) { HISTOGRAMCOUNT(gpnSortedIndex[i]) = (long)j; } } if (fprintf(fp, "static char *conv_pixels[] = {\n") == EOF) { writeFileFailed = TRUE; } BeginProgress(&pi, gnImageH); for (i=0; i < gnImageH; i++) { UpdateProgress(&pi, i); fprintf(fp, "\""); for (j=0; j < gnImageW; j++) { int orig_index=gnFinalImageIndex[i][j]; int index=HISTOGRAMCOUNT(orig_index); if (chars_per_pixel == 1) { if (fprintf(fp, "%c", c0[index]) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(fp, "%c%c", c0[(int)(index/10)], c1[index % 10]) == EOF) { writeFileFailed = TRUE; } } } if (i == gnImageH-1) { if (fprintf(fp, "\"\n};\n") == EOF) writeFileFailed = TRUE; } else { if (fprintf(fp, "\",\n") == EOF) writeFileFailed = TRUE; } } return TRUE; } static int AlreadySorted(nMinIndex, nMaxIndex, nLongAxis) int nMinIndex, nMaxIndex, nLongAxis; { register int i; switch (nLongAxis) { case LONG_AXIS_IS_RED: for (i=nMinIndex; i < nMaxIndex; i++) { if (HISTOGRAMRED(gpnSortedIndex[i]) < HISTOGRAMRED(gpnSortedIndex[i+1])) { return FALSE; } } break; case LONG_AXIS_IS_GREEN: for (i=nMinIndex; i < nMaxIndex; i++) { if (HISTOGRAMGREEN(gpnSortedIndex[i]) < HISTOGRAMGREEN(gpnSortedIndex[i+1])) { return FALSE; } } break; case LONG_AXIS_IS_BLUE: for (i=nMinIndex; i < nMaxIndex; i++) { if (HISTOGRAMBLUE(gpnSortedIndex[i]) < HISTOGRAMBLUE(gpnSortedIndex[i+1])) { return FALSE; } } break; } return TRUE; } static void DebugSortACube(nMinIndex, nMaxIndex, nLevel, nLongAxis) int nMinIndex, nMaxIndex, nLevel, nLongAxis; { register int i; int sorted=TRUE; /* debug, do not translate */ fprintf(stderr, "Level %1d done (long axis is '%s'):\n", nLevel, (nLongAxis==LONG_AXIS_IS_RED ? "red" : (nLongAxis==LONG_AXIS_IS_GREEN ? "green" : "blue"))); for (i=nMinIndex; i <= nMaxIndex; i++) { fprintf(stderr, "\t%6ld: %6d %6d %6d\n", (long)HISTOGRAMCOUNT(gpnSortedIndex[i]), (int)HISTOGRAMRED(gpnSortedIndex[i]), (int)HISTOGRAMGREEN(gpnSortedIndex[i]), (int)HISTOGRAMBLUE(gpnSortedIndex[i])); switch (nLongAxis) { case LONG_AXIS_IS_RED: if (sorted && i != nMinIndex && HISTOGRAMRED(gpnSortedIndex[i-1]) < HISTOGRAMRED(gpnSortedIndex[i])) { sorted = FALSE; } break; case LONG_AXIS_IS_GREEN: if (sorted && i != nMinIndex && HISTOGRAMGREEN(gpnSortedIndex[i-1]) < HISTOGRAMGREEN(gpnSortedIndex[i])) { sorted = FALSE; } break; case LONG_AXIS_IS_BLUE: if (sorted && i != nMinIndex && HISTOGRAMBLUE(gpnSortedIndex[i-1]) < HISTOGRAMBLUE(gpnSortedIndex[i])) { sorted = FALSE; } break; } } if (!sorted) fprintf(stderr, "Not sorted!\n"); } /* static void DisplaySortACube(nMinIndex, nMaxIndex) int nMinIndex, nMaxIndex; { register int i; int sorted=TRUE; for (i=nMinIndex; i <= nMaxIndex; i++) { fprintf(stderr, "\t%6ld %6d %6d %6d %6d %3d\n", (long)HISTOGRAMCOUNT(gpnSortedIndex[i]), (int)HISTOGRAMRED(gpnSortedIndex[i]), (int)HISTOGRAMGREEN(gpnSortedIndex[i]), (int)HISTOGRAMBLUE(gpnSortedIndex[i]), gpnSortedIndex[i], i); } if (!sorted) fprintf(stderr, "Not sorted!\n"); } */ static int dbg_sort=FALSE; static void QuickSortACube(nMinIndex, nMaxIndex, nLevel, nLongAxis) int nMinIndex, nMaxIndex, nLevel, nLongAxis; { register int i, j; int pivot_index, tmp, something_swapped; unsigned long pivot_value=0; if (nMinIndex > nMaxIndex) return; if (AlreadySorted(nMinIndex, nMaxIndex, nLongAxis)) return; pivot_index = nMaxIndex; switch (nLongAxis) { case LONG_AXIS_IS_RED: pivot_value = HISTOGRAMRED(gpnSortedIndex[pivot_index]); break; case LONG_AXIS_IS_GREEN: pivot_value = HISTOGRAMGREEN(gpnSortedIndex[pivot_index]); break; case LONG_AXIS_IS_BLUE: pivot_value = HISTOGRAMBLUE(gpnSortedIndex[pivot_index]); break; } i = nMinIndex; j = nMaxIndex-1; something_swapped = FALSE; do { switch (nLongAxis) { case LONG_AXIS_IS_RED: while (HISTOGRAMRED(gpnSortedIndex[i]) > pivot_value) i++; while (j > i && HISTOGRAMRED(gpnSortedIndex[j]) < pivot_value) j--; break; case LONG_AXIS_IS_GREEN: while (HISTOGRAMGREEN(gpnSortedIndex[i]) > pivot_value) i++; while (j > i && HISTOGRAMGREEN(gpnSortedIndex[j]) < pivot_value) j--; break; case LONG_AXIS_IS_BLUE: while (HISTOGRAMBLUE(gpnSortedIndex[i]) > pivot_value) i++; while (j > i && HISTOGRAMBLUE(gpnSortedIndex[j]) < pivot_value) j--; break; } if (j > i) { tmp = gpnSortedIndex[j]; gpnSortedIndex[j] = gpnSortedIndex[i]; gpnSortedIndex[i] = tmp; if (something_swapped == FALSE) { something_swapped = TRUE; } if (j == i+1) break; i++; j--; } else { break; } } while (TRUE); if (i == nMaxIndex) { /* pivot_value is the smallest */ if (something_swapped) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "Huh? nMinIndex=%1d, nMaxIndex=%1d, nLevel=%1d\n", nMinIndex, nMaxIndex, nLevel); #endif /* _TGIF_DBG */ } else { QuickSortACube(nMinIndex, j, nLevel+1, nLongAxis); } } else if (j > i) { tmp = gpnSortedIndex[nMaxIndex]; gpnSortedIndex[nMaxIndex] = gpnSortedIndex[j]; gpnSortedIndex[j] = tmp; QuickSortACube(nMinIndex, j-1, nLevel+1, nLongAxis); QuickSortACube(j+1, nMaxIndex, nLevel+1, nLongAxis); } else { tmp = gpnSortedIndex[nMaxIndex]; gpnSortedIndex[nMaxIndex] = gpnSortedIndex[i]; gpnSortedIndex[i] = tmp; QuickSortACube(nMinIndex, i-1, nLevel+1, nLongAxis); QuickSortACube(i+1, nMaxIndex, nLevel+1, nLongAxis); } if (dbg_sort) { DebugSortACube(nMinIndex, nMaxIndex, nLevel, nLongAxis); } } static void SweepACube(cube_index) int cube_index; { register int i; int min_index=gpCube[cube_index].min_index; int max_index=gpCube[cube_index].max_index; unsigned short min_r, max_r, min_g, max_g, min_b, max_b; min_r = max_r = gpHistogram[gpnSortedIndex[min_index]].red; min_g = max_g = gpHistogram[gpnSortedIndex[min_index]].green; min_b = max_b = gpHistogram[gpnSortedIndex[min_index]].blue; gpCube[cube_index].num_points = HISTOGRAMCOUNT(gpnSortedIndex[min_index]); for (i=min_index+1; i <= max_index; i++) { unsigned short red=gpHistogram[gpnSortedIndex[i]].red; unsigned short green=gpHistogram[gpnSortedIndex[i]].green; unsigned short blue=gpHistogram[gpnSortedIndex[i]].blue; gpCube[cube_index].num_points += HISTOGRAMCOUNT(gpnSortedIndex[i]); if (red < min_r) min_r = red; if (red > max_r) max_r = red; if (green < min_g) min_g = green; if (green > max_g) max_g = green; if (blue < min_b) min_b = blue; if (blue > max_b) max_b = blue; } gpCube[cube_index].red_length = max_r-min_r; gpCube[cube_index].green_length = max_g-min_g; gpCube[cube_index].blue_length = max_b-min_b; if (gpCube[cube_index].red_length >= gpCube[cube_index].green_length) { if (gpCube[cube_index].red_length >= gpCube[cube_index].blue_length) { gpCube[cube_index].long_axis = LONG_AXIS_IS_RED; } else { gpCube[cube_index].long_axis = LONG_AXIS_IS_BLUE; } } else { if (gpCube[cube_index].green_length >= gpCube[cube_index].blue_length) { gpCube[cube_index].long_axis = LONG_AXIS_IS_GREEN; } else { gpCube[cube_index].long_axis = LONG_AXIS_IS_BLUE; } } } static int SplitACube(cube_index, pul_before_count, pul_after_count) int cube_index; unsigned long *pul_before_count, *pul_after_count; /* * cube to be split into (min_index,return_index) * and (return_index+1,max_index) */ { register int i; int min_index=gpCube[cube_index].min_index; int max_index=gpCube[cube_index].max_index; unsigned long count; unsigned long half_num_points; if (max_index == min_index+1) { *pul_before_count = HISTOGRAMCOUNT(gpnSortedIndex[min_index]); *pul_after_count = HISTOGRAMCOUNT(gpnSortedIndex[max_index]); return min_index; } count = 0; half_num_points = (gpCube[cube_index].num_points>>1); for (i=min_index; i <= max_index; i++) { unsigned long inc=HISTOGRAMCOUNT(gpnSortedIndex[i]); if (count+inc >= half_num_points) { if (i == min_index) { *pul_before_count = inc; *pul_after_count = gpCube[cube_index].num_points-inc; return i; } else if (i == max_index) { *pul_before_count = count; *pul_after_count = gpCube[cube_index].num_points-count; return i-1; } else if (count+inc == half_num_points) { *pul_before_count = count+inc; *pul_after_count = gpCube[cube_index].num_points-count-inc; return i; } else if (half_num_points-count >= count+inc-half_num_points) { if (i+1 == max_index) { *pul_before_count = count; *pul_after_count = gpCube[cube_index].num_points-count; return i; } else { *pul_before_count = count+inc; *pul_after_count = gpCube[cube_index].num_points-count-inc; return i+1; } } else { *pul_before_count = count; *pul_after_count = gpCube[cube_index].num_points-count; return i; } } count += inc; } count = HISTOGRAMCOUNT(gpnSortedIndex[max_index-1]); *pul_before_count = gpCube[cube_index].num_points-count; *pul_after_count = count; return max_index-1; } static int Quantize() /* median-cut quantization */ { int smallest_level=0, max_level=0, cube_index; gpCube = (struct CubeRec *)malloc(gnQuantizingLevels*sizeof(struct CubeRec)); if (gpCube == NULL) { FailAllocMessage(); return FALSE; } memset(gpCube, 0, gnQuantizingLevels*sizeof(struct CubeRec)); gnCubeEntries = 1; gpCube[0].min_index = 0; gpCube[0].max_index = gnHistogramEntries-1; gpCube[0].level = 0; cube_index = 0; SweepACube(0); if (gnDebugQuantization) { int i; /* debug, do not translate */ fprintf(stderr, "Original histogram in Quantize():\n"); for (i=0; i < gnHistogramEntries; i++) { unsigned long count=(int)HISTOGRAMCOUNT(gpnSortedIndex[i]); int red=(int)((HISTOGRAMRED(gpnSortedIndex[i])>>8) & 0xff); int green=(int)((HISTOGRAMGREEN(gpnSortedIndex[i])>>8) & 0xff); int blue=(int)((HISTOGRAMBLUE(gpnSortedIndex[i])>>8) & 0xff); fprintf(stderr, "\t#%02x%02x%02x %6ld\n", red&0x0ff, green&0x0ff, blue&0x0ff, count); } } while (gnCubeEntries < gnQuantizingLevels) { unsigned long before_count, after_count; int split_index, new_level; while (smallest_level <= max_level) { int saved_cube_index=cube_index, found=FALSE; for ( ; cube_index < gnCubeEntries; cube_index++) { if (gpCube[cube_index].min_index != gpCube[cube_index].max_index && gpCube[cube_index].level == smallest_level) { found = TRUE; break; } } if (found) break; for (cube_index=0; cube_index < saved_cube_index; cube_index++) { if (gpCube[cube_index].min_index != gpCube[cube_index].max_index && gpCube[cube_index].level == smallest_level) { found = TRUE; break; } } if (found) break; smallest_level++; } if (smallest_level > max_level) break; /* * determine which is the longest axis */ QuickSortACube(gpCube[cube_index].min_index, gpCube[cube_index].max_index, 0, gpCube[cube_index].long_axis); /* * cube to be split into (min_index,split_index) * and (split_index+1,max_index) */ split_index = SplitACube(cube_index, &before_count, &after_count); new_level = gpCube[cube_index].level+1; if (gnDebugQuantization) { /* debug, do not translate */ fprintf(stderr, "Level %2d (%2d): [%3d,%3d] -> %6ld/[%3d,%3d] %6ld/[%3d,%3d]\n", gpCube[cube_index].level, cube_index, gpCube[cube_index].min_index, gpCube[cube_index].max_index, before_count, gpCube[cube_index].min_index, split_index, after_count, split_index+1, gpCube[cube_index].max_index); } gpCube[gnCubeEntries].min_index = split_index+1; gpCube[gnCubeEntries].max_index = gpCube[cube_index].max_index; gpCube[gnCubeEntries].level = new_level; gpCube[gnCubeEntries].num_points = after_count; SweepACube(gnCubeEntries); gnCubeEntries++; gpCube[cube_index].min_index = gpCube[cube_index].min_index; gpCube[cube_index].max_index = split_index; gpCube[cube_index].level = new_level; gpCube[cube_index].num_points = before_count; SweepACube(cube_index); if (max_level < new_level) max_level = new_level; cube_index++; } if (gnDebugQuantization) { for (cube_index=0; cube_index < gnCubeEntries; cube_index++) { int i; /* debug, do not translate */ fprintf(stderr, "cube %3d: (%3d) [%3d,%3d] %6ld\n", cube_index, gpCube[cube_index].level, gpCube[cube_index].min_index, gpCube[cube_index].max_index, (long)gpCube[cube_index].num_points); for (i=gpCube[cube_index].min_index; i <= gpCube[cube_index].max_index; i++) { unsigned long count=(int)HISTOGRAMCOUNT(gpnSortedIndex[i]); int red=(int)((HISTOGRAMRED(gpnSortedIndex[i])>>8) & 0xff); int green=(int)((HISTOGRAMGREEN(gpnSortedIndex[i])>>8) & 0xff); int blue=(int)((HISTOGRAMBLUE(gpnSortedIndex[i])>>8) & 0xff); fprintf(stderr, "\t#%02x%02x%02x %6ld\n", red&0x0ff, green&0x0ff, blue&0x0ff, count); } } } return TRUE; } int DoConvolution(fp, image, bitmap_image, w, h, xpm_ptr) FILE *fp; XImage *image, *bitmap_image; int w, h; struct XPmRec *xpm_ptr; { register int j, i; int interrupted=FALSE, rc; ProgressInfo pi; if (gpConvolveFunc == NULL) { return FALSE; } memset(gaHGBucket, 0, sizeof(gaHGBucket)); gnHistogramEntries = 0; if (DoPpm6(xpm_ptr)) { writeFileFailed = FALSE; if (fprintf(fp, "P6\n%1d %1d\n255\n", w, h) == EOF) { writeFileFailed = TRUE; } if (gpConvolveCmdID == CMDID_VECTORWARP) { /* already initialized in ComputeVectorWarpData(), except for fp */ gConvExtraInfo.fp = fp; } else { if (!SetConvExtraInfo(fp, w, h, image, bitmap_image)) { CleanUpConvolution(); return FALSE; } } ShowInterrupt(1); BeginProgress(&pi, h); for (i=0; i < h; i++) { UpdateProgress(&pi, i); if (ESCPressed() || CheckInterrupt(TRUE)) { Msg(TgLoadString(STID_USER_INTR)); interrupted = TRUE; break; } for (j=0; j < w; j++) { ((ConvolveFunc*)gpConvolveFunc)(j, i); } } HideInterrupt(); ClearConvExtraInfo(); if (interrupted) { CleanUpConvolution(); return FALSE; } CleanUpConvolution(); return (writeFileFailed == FALSE); } SetStringStatus(TgLoadCachedString(CSTID_BUILDING_HISTOGRAM_DOTS)); XSync(mainDisplay, False); if (!CreatePixelToIndexMapping()) { return FALSE; } gnHistogramSize = 256; gpHistogram = (XColor*)malloc(gnHistogramSize*sizeof(XColor)); if (gpHistogram == NULL) { FailAllocMessage(); CleanUpConvolution(); return FALSE; } gnImageW = w; gnImageH = h; gnOrigImageIndex = (int**)malloc(h*sizeof(int*)); if (gnOrigImageIndex == NULL) { FailAllocMessage(); CleanUpConvolution(); return FALSE; } memset(gnOrigImageIndex, 0, h*sizeof(int*)); for (i=0; i < h; i++) { gnOrigImageIndex[i] = (int*)malloc(w*sizeof(int)); if (gnOrigImageIndex[i] == NULL) { FailAllocMessage(); CleanUpConvolution(); return FALSE; } } if (image != NULL) { BeginProgress(&pi, h); for (i=0; i < h; i++) { UpdateProgress(&pi, i); for (j=0; j < w; j++) { /* int pixel=XGetPixel(image,j,i); */ /* int index=pnPixelToIndexMap[pixel]; */ gnOrigImageIndex[i][j] = GetIndexOfPixel(XGetPixel(image,j,i)); } } } gnFinalImageIndex = (int**)malloc(h*sizeof(int*)); if (gnFinalImageIndex == NULL) { FailAllocMessage(); CleanUpConvolution(); return FALSE; } memset(gnFinalImageIndex, 0, h*sizeof(int*)); for (i=0; i < h; i++) { gnFinalImageIndex[i] = (int*)malloc(w*sizeof(int)); if (gnFinalImageIndex[i] == NULL) { FailAllocMessage(); CleanUpConvolution(); return FALSE; } } ShowInterrupt(1); BeginProgress(&pi, h); for (i=0; i < h; i++) { UpdateProgress(&pi, i); if (ESCPressed() || CheckInterrupt(TRUE)) { Msg(TgLoadString(STID_USER_INTR)); interrupted = TRUE; break; } for (j=0; j < w; j++) { gnFinalImageIndex[i][j] = ((ConvolveFunc*)gpConvolveFunc)(j, i); } } HideInterrupt(); if (interrupted) { CleanUpConvolution(); return FALSE; } gpnSortedIndex = (int*)malloc(gnHistogramEntries*sizeof(int)); if (gpnSortedIndex == NULL) { FailAllocMessage(); CleanUpConvolution(); return FALSE; } for (i=0; i < gnHistogramEntries; i++) gpnSortedIndex[i] = i; if (gnUserSpecifiedLevels != (-1) || gnHistogramEntries > gnQuantizingLevels) { int saved_levels=gnQuantizingLevels; if (gnUserSpecifiedLevels != (-1)) { gnQuantizingLevels = gnUserSpecifiedLevels; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_QUANTIZING_COLORS_DOTS), gnHistogramEntries, gnQuantizingLevels); Msg(gszMsgBox); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if (Quantize()) { rc = DumpQuantizedConvolution(fp); if (gnUserSpecifiedLevels != (-1)) { gnQuantizingLevels = saved_levels; } CleanUpConvolution(); return rc; } CleanUpConvolution(); gnQuantizingLevels = saved_levels;; return FALSE; } rc = DumpConvolution(fp); CleanUpConvolution(); return rc; } static int DoColorMapping(fp, image, bitmap_image, w, h, xpm_ptr) FILE *fp; XImage *image, *bitmap_image; int w, h; struct XPmRec *xpm_ptr; { register int j, i; int interrupted=FALSE, rc; ProgressInfo pi; if (gpImageMapColorFunc == NULL) { return FALSE; } SetStringStatus(TgLoadCachedString(CSTID_REMAPPING_COLORS_DOTS)); XSync(mainDisplay, False); memset(gaHGBucket, 0, sizeof(gaHGBucket)); gnHistogramEntries = 0; if (DoPpm6(xpm_ptr)) { writeFileFailed = FALSE; if (fprintf(fp, "P6\n%1d %1d\n255\n", w, h) == EOF) { writeFileFailed = TRUE; } ShowInterrupt(1); BeginProgress(&pi, h); for (i=0; i < h; i++) { UpdateProgress(&pi, i); if (ESCPressed() || CheckInterrupt(TRUE)) { Msg(TgLoadString(STID_USER_INTR)); interrupted = TRUE; break; } for (j=0; j < w; j++) { if (bitmap_image != NULL && XGetPixel(bitmap_image,j,i) == 0) { TgAssert(FALSE, "transparent pixel not supported", NULL); } else { ((ImageMapColorFunc*)gpImageMapColorFunc)(XGetPixel(image,j,i), (XColor*)fp); } } } HideInterrupt(); if (interrupted) { CleanUpConvolution(); return FALSE; } CleanUpConvolution(); return (writeFileFailed == FALSE); } gnHistogramSize = 256; gpHistogram = (XColor*)malloc(gnHistogramSize*sizeof(XColor)); if (gpHistogram == NULL) { FailAllocMessage(); CleanUpConvolution(); return FALSE; } if (!CreateObjPixelToIndexMapping(xpm_ptr)) { CleanUpConvolution(); return FALSE; } gnImageW = w; gnImageH = h; gnFinalImageIndex = (int**)malloc(h*sizeof(int*)); if (gnFinalImageIndex == NULL) { FailAllocMessage(); CleanUpConvolution(); return FALSE; } memset(gnFinalImageIndex, 0, h*sizeof(int*)); for (i=0; i < h; i++) { gnFinalImageIndex[i] = (int*)malloc(w*sizeof(int)); if (gnFinalImageIndex[i] == NULL) { FailAllocMessage(); CleanUpConvolution(); return FALSE; } } ShowInterrupt(1); BeginProgress(&pi, h); for (i=0; i < h; i++) { UpdateProgress(&pi, i); if (ESCPressed() || CheckInterrupt(TRUE)) { Msg(TgLoadString(STID_USER_INTR)); interrupted = TRUE; break; } for (j=0; j < w; j++) { /* int pixel=XGetPixel(image,j,i); */ /* int index=pnPixelToIndexMap[pixel]; */ if (bitmap_image != NULL && XGetPixel(bitmap_image,j,i) == 0) { gnFinalImageIndex[i][j] = gnTransparentIndex; } else { gnFinalImageIndex[i][j] = GetIndexOfPixel(XGetPixel(image,j,i)); } } } HideInterrupt(); if (interrupted) { CleanUpConvolution(); return FALSE; } rc = DumpConvolution(fp); CleanUpConvolution(); return rc; } /* ----------------------- ProcessImage ----------------------- */ FILE *GetImageProcOutputFileName(pszPath, path_buf_sz, pnShortName, ppszRest) char *pszPath, **ppszRest; int path_buf_sz, *pnShortName; { FILE *fp=NULL; if (MkTempFile(pszPath, path_buf_sz, tmpDir, TOOL_NAME) == NULL) { return NULL; } if ((*pnShortName=IsPrefix(bootDir, pszPath, ppszRest))) { *ppszRest = (&(*ppszRest)[1]); } if ((fp=fopen(pszPath, "w")) == NULL) { if (*pnShortName) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), *ppszRest); } else { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), pszPath); } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return NULL; } return fp; } static int CleanUpProcessImage(fp, image, bitmap_image) FILE *fp; XImage *image, *bitmap_image; { if (fp != NULL) fclose(fp); if (image != NULL) XDestroyImage(image); if (bitmap_image != NULL) XDestroyImage(bitmap_image); return FALSE; } static int ProcessImage() { int short_name=FALSE, ok=TRUE; char path[MAXPATHLENGTH+1], *rest=NULL; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; FILE *fp=NULL; struct ObjRec *obj_ptr=NULL; int image_w=0, image_h=0; struct XPmRec *xpm_ptr=NULL; if ((fp=GetImageProcOutputFileName(path, sizeof(path), &short_name, &rest)) == NULL) { return FALSE; } if (gnCombining) { obj_ptr = NULL; } else { obj_ptr = topSel->obj; } if (obj_ptr == NULL) { pixmap = None; bitmap = None; image_w = gnCombineW; image_h = gnCombineH; image = bitmap_image = NULL; } else if (obj_ptr->type == OBJ_XPM) { xpm_ptr = obj_ptr->detail.xpm; pixmap = xpm_ptr->pixmap; bitmap = xpm_ptr->bitmap; image_w = xpm_ptr->image_w; image_h = xpm_ptr->image_h; image = XGetImage(mainDisplay, pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (bitmap != None) { bitmap_image = XGetImage(mainDisplay, bitmap, 0, 0, image_w, image_h, 1, ZPixmap); } if (image == NULL || (bitmap != None && bitmap_image == NULL)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return CleanUpProcessImage(fp, image, bitmap_image); } if (DoPpm6(xpm_ptr)) { if (!InitTrueColorInfo(image, &gTrueColorInfo, image_w)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return CleanUpProcessImage(fp, image, bitmap_image); } if (gpConvolveCmdID == CMDID_REDUCECOLORS) { int floyd=FALSE; char tmp_fname[MAXPATHLENGTH]; switch (MsgBox(TgLoadString(STID_Q_FS_ERROR_DIFFUSE), TOOL_NAME, YNC_MB)) { case MB_ID_YES: floyd = TRUE; break; case MB_ID_NO: floyd = FALSE; break; case MB_ID_CANCEL: return CleanUpProcessImage(fp, image, bitmap_image); } if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { return CleanUpProcessImage(fp, image, bitmap_image); } if (DumpXImageToPpmFile(image, image_w, image_h, tmp_fname, FALSE)) { FILE *pfp=NULL; char psz_cmd[MAXPATHLENGTH<<1]; int bytes_read=0; if (floyd) { snprintf(psz_cmd, sizeof(psz_cmd), ppmFSquantCmd, gnUserSpecifiedLevels, tmp_fname); } else { snprintf(psz_cmd, sizeof(psz_cmd), ppmquantCmd, gnUserSpecifiedLevels, tmp_fname); } if ((pfp=(FILE*)popen(psz_cmd,"r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), psz_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(tmp_fname); return CleanUpProcessImage(fp, image, bitmap_image); } writeFileFailed = FALSE; while ((bytes_read=fread(gszMsgBox, sizeof(char), sizeof(gszMsgBox), pfp)) > 0) { if ((int)fwrite(gszMsgBox, sizeof(char), bytes_read, fp) <= 0) { writeFileFailed = TRUE; break; } } pclose(pfp); if (writeFileFailed) { FailToWriteFileMessage(short_name ? rest : tmp_fname); unlink(tmp_fname); return CleanUpProcessImage(fp, image, bitmap_image); } unlink(tmp_fname); CleanUpProcessImage(fp, image, bitmap_image); strcpy(gszImageProcXPmFile, path); if (gnConvolving) { CleanUpConvolution(); } return TRUE; } } } } else { return CleanUpProcessImage(fp, image, bitmap_image); } SaveStatusStrings(); if (gnConvolving) { ok = DoConvolution(fp, image, bitmap_image, image_w, image_h, xpm_ptr); } else { ok = DoColorMapping(fp, image, bitmap_image, image_w, image_h, xpm_ptr); } RestoreStatusStrings(); CleanUpProcessImage(fp, image, bitmap_image); if (!ok) return FALSE; strcpy(gszImageProcXPmFile, path); if (gnConvolving) { CleanUpConvolution(); } return TRUE; } static int DoImageProc(pvImageMapColorFunc) NLFN *pvImageMapColorFunc; { int saved_colordump=colorDump, saved_left=leftExportPixelTrim; int saved_top=topExportPixelTrim, saved_right=rightExportPixelTrim; int saved_bottom=bottomExportPixelTrim, saved_where_to_print=whereToPrint; int saved_ltx, saved_lty, saved_cur_file_defined=curFileDefined; int ltx, lty, rbx, rby, saved_w, saved_h, saved_x=0, saved_y=0; int w, h, image_w, image_h, ncolors, first_pixel_is_bg, ctm_saved=FALSE; int rc, chars_per_pixel, *pixels=NULL, retry_count=0; struct XfrmMtrxRec saved_ctm; struct BBRec saved_orig_obbox; XPoint saved_rotated_obbox[5]; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; struct ObjRec *obj_ptr; struct AttrRec *saved_fattr=NULL, *saved_lattr=NULL; struct XPmRec *xpm_ptr=NULL; if (gnCombining) { saved_ltx = selObjLtX; saved_lty = selObjLtY; saved_w = selObjRbX - saved_ltx; saved_h = selObjRbY - saved_lty; ltx = selLtX; lty = selLtY; rbx = selRbX; rby = selRbY; } else { if (topSel->obj->ctm != NULL) { ctm_saved = TRUE; saved_x = topSel->obj->x; saved_y = topSel->obj->y; memcpy(&saved_ctm, topSel->obj->ctm, sizeof(struct XfrmMtrxRec)); memcpy(&saved_orig_obbox, &topSel->obj->orig_obbox, sizeof(struct BBRec)); memcpy(saved_rotated_obbox, topSel->obj->rotated_obbox, 5*sizeof(XPoint)); } saved_ltx = topSel->obj->obbox.ltx; saved_lty = topSel->obj->obbox.lty; saved_w = topSel->obj->obbox.rbx - saved_ltx; saved_h = topSel->obj->obbox.rby - saved_lty; ltx = topSel->obj->bbox.ltx; lty = topSel->obj->bbox.lty; rbx = topSel->obj->bbox.rbx; rby = topSel->obj->bbox.rby; } leftExportPixelTrim = topExportPixelTrim = rightExportPixelTrim = bottomExportPixelTrim = 0; *gszImageProcXPmFile = '\0'; curFileDefined = TRUE; whereToPrint = XBM_FILE; colorDump = TRUE; gnInImageProc = TRUE; gpImageMapColorFunc = (NLFN*)pvImageMapColorFunc; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); ProcessImage(); SetDefaultCursor(mainWindow); ShowCursor(); gpImageMapColorFunc = NULL; colorDump = saved_colordump; whereToPrint = saved_where_to_print; curFileDefined = saved_cur_file_defined; leftExportPixelTrim = saved_left; topExportPixelTrim = saved_top; rightExportPixelTrim = saved_right; bottomExportPixelTrim = saved_bottom; if (*gszImageProcXPmFile == '\0') { gnInImageProc = FALSE; return FALSE; } if (gnCombining) { struct SelRec *sel_ptr; HighLightReverse(); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); obj_ptr = NULL; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { UnlinkObj(sel_ptr->obj); FreeObj(sel_ptr->obj); } RemoveAllSel(); } else { HighLightReverse(); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); obj_ptr = topSel->obj; xpm_ptr = obj_ptr->detail.xpm; saved_fattr = obj_ptr->fattr; saved_lattr = obj_ptr->lattr; obj_ptr->fattr = obj_ptr->lattr = NULL; RemoveAllSel(); } gnInImageProc = FALSE; if (DoPpm6(xpm_ptr)) { char deflated_fname[MAXPATHLENGTH+1]; if (obj_ptr != NULL) UnlinkObj(obj_ptr); if (obj_ptr != NULL) FreeObj(obj_ptr); ResetPngHeaderInfo(&gPngHeaderInfo); obj_ptr = CreatePpmTrueObjFromFile(gszImageProcXPmFile); if (obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile(gszImageProcXPmFile, deflated_fname)) { /* good */ } else { FreeObj(obj_ptr); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_PPM), gszImageProcXPmFile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(gszImageProcXPmFile); *gszImageProcXPmFile = '\0'; AbortPrepareCmd(CMD_REPLACE); return FALSE; } xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; unlink(deflated_fname); } else { do { int new_colormap_used=newColormapUsed; if (obj_ptr != NULL) UnlinkObj(obj_ptr); if (obj_ptr != NULL) FreeObj(obj_ptr); gnInImageProc = TRUE; if (FlushColormap()) { Msg(TgLoadString(STID_COLORMAP_FLUSHED)); } gnInImageProc = FALSE; allocColorFailed = FALSE; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(gszImageProcXPmFile, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if (rc != BitmapSuccess) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), gszImageProcXPmFile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(gszImageProcXPmFile); *gszImageProcXPmFile = '\0'; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } AbortPrepareCmd(CMD_REPLACE); return FALSE; } obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, FALSE, color_char, color_str, pixels, xpm_data); if (!new_colormap_used && newColormapUsed && allocColorFailed) { if (retry_count > 1) { break; } if (MsgBox(TgLoadString(STID_MAY_USED_UP_COLORS_RETRY), TOOL_NAME, YNC_MB) != MB_ID_YES) { break; } retry_count++; if (saved_fattr != NULL) { obj_ptr->fattr = obj_ptr->lattr = NULL; } } else { break; } } while (retry_count > 0); } unlink(gszImageProcXPmFile); *gszImageProcXPmFile = '\0'; obj_ptr->obbox.rbx = obj_ptr->obbox.ltx+saved_w; obj_ptr->obbox.rby = obj_ptr->obbox.lty+saved_h; AdjObjBBox(obj_ptr); AddObj(NULL, topObj, obj_ptr); MoveObj(obj_ptr, saved_ltx-obj_ptr->obbox.ltx, saved_lty-obj_ptr->obbox.lty); if (ctm_saved) { obj_ptr->x = saved_x; obj_ptr->y = saved_y; obj_ptr->ctm = (struct XfrmMtrxRec*)malloc(sizeof(struct XfrmMtrxRec)); if (obj_ptr->ctm == NULL) FailAllocMessage(); memcpy(obj_ptr->ctm, &saved_ctm, sizeof(struct XfrmMtrxRec)); memcpy(&obj_ptr->orig_obbox, &saved_orig_obbox, sizeof(struct BBRec)); memcpy(obj_ptr->rotated_obbox, saved_rotated_obbox, 5*sizeof(XPoint)); } if (saved_fattr != NULL) { obj_ptr->fattr = saved_fattr; obj_ptr->lattr = saved_lattr; } RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), obj_ptr->bbox.ltx-GRID_ABS_SIZE(1), obj_ptr->bbox.lty-GRID_ABS_SIZE(1), obj_ptr->bbox.rbx+GRID_ABS_SIZE(1), obj_ptr->bbox.rby+GRID_ABS_SIZE(1)); if (saved_fattr != NULL && topObj->fattr == NULL) { topObj->fattr = saved_fattr; topObj->lattr = saved_lattr; } if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } if (gnCombining) { SelectTopObj(); recordCmdUsesNewColormap = TRUE; RecordCmd(CMD_MANY_TO_ONE, NULL, topSel, botSel, 1); recordCmdUsesNewColormap = FALSE; } else { SelectTopObj(); recordCmdUsesNewColormap = TRUE; RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); recordCmdUsesNewColormap = FALSE; } SetFileModified(TRUE); justDupped = FALSE; return TRUE; } /* ----------------------- MakeGray ----------------------- */ static void ChangeToGray(nColorIndex, pColor) int nColorIndex; XColor *pColor; { struct XPmRec *xpm_ptr=topObj->detail.xpm; if (DoPpm6(xpm_ptr)) { int pixel=nColorIndex; FILE *fp=(FILE*)pColor; uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0, igray=0; double dr=(double)0, dg=(double)0, db=(double)0; double dgray=(double)0; unsigned char buf[3]; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval; dg = ((double)g) / gTrueColorInfo.dg_maxval; db = ((double)b) / gTrueColorInfo.db_maxval; dgray = ((double)(0.299*dr + 0.587*dg + 0.114*db))*((double)256.0); igray = (dgray < ((double)0)) ? 0 : ((unsigned int)dgray); if (igray > 255) igray = 255; buf[0] = buf[1] = buf[2] = (unsigned char)(igray&0xff); if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; } else { int red=(int)tgifColors[nColorIndex].red; int green=(int)tgifColors[nColorIndex].green; int blue=(int)tgifColors[nColorIndex].blue; float gray=0.299*((float)red)+0.587*((float)green)+0.114*((float)blue); int val=(int)gray; int real_gray=((val>0x0ffff) ? 0x0ffff : ((val<0) ? 0 : val)); pColor->red = pColor->green = pColor->blue = real_gray; } } void MakeGray() { if (!CheckSelectionForImageProc(CMDID_MAKEGRAY)) return; if (TrueColorTransPixelCheck(topSel->obj, CMDID_MAKEGRAY)) return; DoImageProc((NLFN*)ChangeToGray); } /* ----------------------- InvertColor ----------------------- */ static void ChangeToInvertColor(nColorIndex, pColor) int nColorIndex; XColor *pColor; { struct XPmRec *xpm_ptr=topObj->detail.xpm; if (DoPpm6(xpm_ptr)) { int pixel=nColorIndex; FILE *fp=(FILE*)pColor; uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval; dg = ((double)g) / gTrueColorInfo.dg_maxval; db = ((double)b) / gTrueColorInfo.db_maxval; dr = (((double)1.0) - dr) * ((double)256); dg = (((double)1.0) - dg) * ((double)256); db = (((double)1.0) - db) * ((double)256); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; } else { int red=(int)tgifColors[nColorIndex].red; int green=(int)tgifColors[nColorIndex].green; int blue=(int)tgifColors[nColorIndex].blue; pColor->red = 0x0ffff-((unsigned int)red); pColor->green = 0x0ffff-((unsigned int)green); pColor->blue = 0x0ffff-((unsigned int)blue); } } void InvertColor() { if (!CheckSelectionForImageProc(CMDID_INVERTCOLOR)) return; if (TrueColorTransPixelCheck(topSel->obj, CMDID_INVERTCOLOR)) return; DoImageProc((NLFN*)ChangeToInvertColor); } /* ----------------------- InterpolateColor ----------------------- */ static XColor gInterpFromColor, gInterpToColor; static void ChangeToInterpolateColor(nColorIndex, pColor) int nColorIndex; XColor *pColor; { struct XPmRec *xpm_ptr=topObj->detail.xpm; if (DoPpm6(xpm_ptr)) { int pixel=nColorIndex; FILE *fp=(FILE*)pColor; uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; double dgray=(double)0; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval; dg = ((double)g) / gTrueColorInfo.dg_maxval; db = ((double)b) / gTrueColorInfo.db_maxval; dgray = (0.299*dr) + (0.587*dg) + (0.114*db); dr = (((double)gInterpFromColor.red) + dgray * (((double)gInterpToColor.red) - ((double)gInterpFromColor.red))) / ((double)256); dg = (((double)gInterpFromColor.green) + dgray * (((double)gInterpToColor.green) - ((double)gInterpFromColor.green))) / ((double)256); db = (((double)gInterpFromColor.blue) + dgray * (((double)gInterpToColor.blue) - ((double)gInterpFromColor.blue))) / ((double)256); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; } else { int red=(int)tgifColors[nColorIndex].red; int green=(int)tgifColors[nColorIndex].green; int blue=(int)tgifColors[nColorIndex].blue; float gray=(0.299*((float)red)+0.587*((float)green)+0.114*((float)blue)) / (float)(0x0000ffff), tmp_fval; int val, real_red, real_green, real_blue; tmp_fval = ((float)gInterpFromColor.red) + gray*(((float)gInterpToColor.red)-((float)gInterpFromColor.red)); val = round(tmp_fval); real_red = ((val>0x0ffff) ? 0x0ffff : ((val<0) ? 0 : val)); tmp_fval = ((float)gInterpFromColor.green) + gray*(((float)gInterpToColor.green)-((float)gInterpFromColor.green)); val = round(tmp_fval); real_green = ((val>0x0ffff) ? 0x0ffff : ((val<0) ? 0 : val)); tmp_fval = ((float)gInterpFromColor.blue) + gray*(((float)gInterpToColor.blue)-((float)gInterpFromColor.blue)); val = round(tmp_fval); real_blue = ((val>0x0ffff) ? 0x0ffff : ((val<0) ? 0 : val)); pColor->red = (unsigned int)real_red; pColor->green = (unsigned int)real_green; pColor->blue = (unsigned int)real_blue; } } void InterpolateColor() { char *c_ptr, szFrom[MAXSTRING+1], szTo[MAXSTRING+1]; char szSpec[MAXSTRING+1], szSpecCopy[MAXSTRING+1]; if (!CheckSelectionForImageProc(CMDID_INTERPOLATECOLOR)) return; if (TrueColorTransPixelCheck(topSel->obj, CMDID_INTERPOLATECOLOR)) return; *szSpec = '\0'; Dialog(TgLoadString(STID_ENTER_PAIR_COLORS_INTERPOLATE), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') return; strcpy(szSpecCopy, szSpec); *szFrom = *szTo = '\0'; if ((c_ptr=strtok(szSpec, " ,-\t\n\r")) != NULL) { strcpy(szFrom, c_ptr); if ((c_ptr=strtok(NULL, " ,-\t\n\r")) != NULL) { strcpy(szTo, c_ptr); } } if (*szFrom == '\0' || *szTo == '\0') { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC), szSpecCopy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (!TgifParseColor(szFrom, &gInterpFromColor)) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_IS_NOT_A_VALID_COLOR), szFrom); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } else if (!TgifParseColor(szTo, &gInterpToColor)) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_IS_NOT_A_VALID_COLOR), szTo); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } DoImageProc((NLFN*)ChangeToInterpolateColor); } /* ----------------------- Brighten/Darken ----------------------- */ static double gdBrighten=(double)0; static int gnBrighten=0; static void ChangeToBrightenDarken(nColorIndex, pColor) int nColorIndex; XColor *pColor; { struct XPmRec *xpm_ptr=topObj->detail.xpm; if (DoPpm6(xpm_ptr)) { int pixel=nColorIndex; FILE *fp=(FILE*)pColor; uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval; dg = ((double)g) / gTrueColorInfo.dg_maxval; db = ((double)b) / gTrueColorInfo.db_maxval; dr = (dr + gdBrighten) * ((double)256); dg = (dg + gdBrighten) * ((double)256); db = (db + gdBrighten) * ((double)256); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; } else { int red=((int)tgifColors[nColorIndex].red)+gnBrighten; int green=((int)tgifColors[nColorIndex].green)+gnBrighten; int blue=((int)tgifColors[nColorIndex].blue)+gnBrighten; int real_red, real_green, real_blue; real_red = ((red>0x0ffff) ? 0x0ffff : ((red<0) ? 0 : red)); real_green = ((green>0x0ffff) ? 0x0ffff : ((green<0) ? 0 : green)); real_blue = ((blue>0x0ffff) ? 0x0ffff : ((blue<0) ? 0 : blue)); pColor->red = (unsigned int)real_red; pColor->green = (unsigned int)real_green; pColor->blue = (unsigned int)real_blue; } } void BrightenDarken() { char *c_ptr, szValue[MAXSTRING+1]; char szSpec[MAXSTRING+1], szSpecCopy[MAXSTRING+1]; float fVal; if (!CheckSelectionForImageProc(CMDID_BRIGHTENDARKEN)) return; if (TrueColorTransPixelCheck(topSel->obj, CMDID_BRIGHTENDARKEN)) return; *szSpec = '\0'; Dialog(TgLoadString(STID_ENTER_VAL_MINUS_PLUS_ONE_BW), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') return; strcpy(szSpecCopy, szSpec); if ((c_ptr=strtok(szSpec, " ,\t\n\r")) == NULL) return; strcpy(szValue, c_ptr); if (sscanf(szValue, "%f", &fVal) != 1) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_FOR_A_VAL), szSpecCopy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } gdBrighten = ((double)fVal); gnBrighten = (int)round(gdBrighten*((double)0x0000ffff)); DoImageProc((NLFN*)ChangeToBrightenDarken); } /* ----------------------- ChangeSaturation ----------------------- */ /* * 0 65535 spread * |--------------------r-----| s = -------- * 65535 * |---g----------------------| v * |-----------b--------------| * |<---------v-------->| x * |<----spread---->| h = -------- * 60 * |<--x-->| spread * * 0 60 120 180 240 300 360 * |--r--|--g--|--g--|--b--|--b--|--r--| */ static double gfSaturation=(double)0.0; void RGBtoHSV(r, g, b, h, s, v) int r, g, b, *h, *v; double *s; /* 0 <= r,g,b <= 0x0ffff */ /* 0 <= *h < 360 */ /* 0 <= *s,*v <= 0x0ffff */ { int max_val=max(r,max(g,b)), min_val=min(r,min(g,b)); double spread=(double)(max_val-min_val); *v = max_val; if (max_val == 0) { *s = (double)0.0; } else { *s = (double)((spread*((double)0x0ffff))/((double)max_val)); } if (*s < (double)0.0) *s = (double)0.0; if (*s > INT_TOL) { int hue=0; if (r == max_val) { hue = (int)(((double)(g-b))/spread*((double)60.0)); if (hue < -60) hue = -60; if (hue < 0) { hue += 360; } else if (hue > 60) { hue = 60; } } else if (g == max_val) { hue = (int)(((double)120.0) + (((double)(b-r))/spread*((double)60.0))); if (hue < 60) hue = 60; if (hue > 180) hue = 180; } else if (b == max_val) { hue = (int)(((double)240.0) + (((double)(r-g))/spread*((double)60.0))); if (hue < 180) hue = 180; if (hue > 300) hue = 300; } *h = hue; } else { *h = 0; } } #define R_IS_MAX 0 #define G_IS_MAX 1 #define B_IS_MAX 2 void HSVtoRGB(h, s, v, r, g, b) double s; int h, v, *r, *g, *b; /* 0 <= *r,*g,*b <= 0x0ffff */ /* 0 <= h < 360 */ /* 0 <= s,v <= 0x0ffff */ { if (s <= INT_TOL) { *r = *g = *b = v; } else { double frac, spread; int which, min_val, mid_val; if (h >= 300) { frac = (((double)(360-h))/((double)60.0)); which = R_IS_MAX; } else if (h >= 240) { frac = (((double)(h-240))/((double)60.0)); which = B_IS_MAX; } else if (h >= 180) { frac = (((double)(240-h))/((double)60.0)); which = B_IS_MAX; } else if (h >= 120) { frac = (((double)(h-120))/((double)60.0)); which = G_IS_MAX; } else if (h >= 60) { frac = (((double)(120-h))/((double)60.0)); which = G_IS_MAX; } else { frac = (((double)h)/((double)60.0)); which = R_IS_MAX; } spread = (((double)v)*s/((double)0x0ffff)); min_val = (int)(v-spread); mid_val = min_val+((int)(frac*spread)); switch (which) { case R_IS_MAX: *r = v; if (h >= 300) { /* g < b */ *g = min_val; *b = mid_val; } else { /* g >= b */ *g = mid_val; *b = min_val; } break; case G_IS_MAX: *g = v; if (h >= 120) { /* b >= r */ *b = mid_val; *r = min_val; } else { /* b < r */ *b = min_val; *r = mid_val; } break; case B_IS_MAX: *b = v; if (h >= 240) { /* r >= g */ *r = mid_val; *g = min_val; } else { /* r < g */ *r = min_val; *g = mid_val; } break; } } } static void ChangeToChangeSaturation(nColorIndex, pColor) int nColorIndex; XColor *pColor; { struct XPmRec *xpm_ptr=topObj->detail.xpm; if (DoPpm6(xpm_ptr)) { int pixel=nColorIndex; FILE *fp=(FILE*)pColor; uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; int h=0, v=0; double s=(double)0; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval; dg = ((double)g) / gTrueColorInfo.dg_maxval; db = ((double)b) / gTrueColorInfo.db_maxval; dr *= ((double)0x10000); dg *= ((double)0x10000); db *= ((double)0x10000); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 0x0ffff) r = 0x0ffff; if (g > 0x0ffff) g = 0x0ffff; if (b > 0x0ffff) b = 0x0ffff; RGBtoHSV(r, g, b, &h, &s, &v); s = s * (((double)1.0)+gfSaturation); if (s > (double)0x0ffff) s = (double)0x0ffff; if (s < (double)0.0) s = (double)0.0; HSVtoRGB(h, s, v, (int*)(&r), (int*)(&g), (int*)(&b)); dr = ((double)r) / ((double)256); dg = ((double)g) / ((double)256); db = ((double)b) / ((double)256); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; } else { int red=((int)tgifColors[nColorIndex].red); int green=((int)tgifColors[nColorIndex].green); int blue=((int)tgifColors[nColorIndex].blue); int h, v, real_red, real_green, real_blue; double s=(double)0; RGBtoHSV(red, green, blue, &h, &s, &v); s = s * (((double)1.0)+gfSaturation); if (s > (double)0x0ffff) s = (double)0x0ffff; if (s < (double)0.0) s = (double)0.0; HSVtoRGB(h, s, v, &red, &green, &blue); real_red = ((red>0x0ffff) ? 0x0ffff : ((red<0) ? 0 : red)); real_green = ((green>0x0ffff) ? 0x0ffff : ((green<0) ? 0 : green)); real_blue = ((blue>0x0ffff) ? 0x0ffff : ((blue<0) ? 0 : blue)); pColor->red = (unsigned int)real_red; pColor->green = (unsigned int)real_green; pColor->blue = (unsigned int)real_blue; } } void ChangeSaturation() { char *c_ptr, szValue[MAXSTRING+1]; char szSpec[MAXSTRING+1], szSpecCopy[MAXSTRING+1]; float fVal; if (!CheckSelectionForImageProc(CMDID_CHANGESATURATION)) return; if (TrueColorTransPixelCheck(topSel->obj, CMDID_CHANGESATURATION)) return; *szSpec = '\0'; Dialog(TgLoadString(STID_ENTER_VAL_MINUS_PLUS_ONE_SAT), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') return; strcpy(szSpecCopy, szSpec); if ((c_ptr=strtok(szSpec, " ,\t\n\r")) == NULL) return; strcpy(szValue, c_ptr); if (sscanf(szValue, "%f", &fVal) != 1) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_FOR_A_VAL), szSpecCopy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (fVal > (float)1.0) fVal = (float)1.0; if (fVal < (float)(-1.0)) fVal = (float)(-1.0); gfSaturation = fVal; DoImageProc((NLFN*)ChangeToChangeSaturation); } /* ----------------------- ChangeHue ----------------------- */ static int gnFromHue=0, gnToHue=0; static float gfFromAngle=(float)0.0, gfToAngle=(float)0.0; static float gfFromStart=(float)0.0, gfToStart=(float)0.0; static float gfFromEnd=(float)0.0, gfToEnd=(float)0.0; static int HueInFromRange(fHue) float fHue; { if (gfFromStart >= gfFromEnd) { if (gfFromEnd <= fHue && fHue <= gfFromStart) { return TRUE; } } else { if (gfFromStart <= fHue && fHue <= gfFromEnd) { return TRUE; } } return FALSE; } static void ChangeToChangeHue(nColorIndex, pColor) int nColorIndex; XColor *pColor; { struct XPmRec *xpm_ptr=topObj->detail.xpm; if (DoPpm6(xpm_ptr)) { int pixel=nColorIndex; FILE *fp=(FILE*)pColor; uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; int h=0, v=0; double s=(double)0; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval; dg = ((double)g) / gTrueColorInfo.dg_maxval; db = ((double)b) / gTrueColorInfo.db_maxval; dr *= ((double)0x10000); dg *= ((double)0x10000); db *= ((double)0x10000); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 0x0ffff) r = 0x0ffff; if (g > 0x0ffff) g = 0x0ffff; if (b > 0x0ffff) b = 0x0ffff; RGBtoHSV(r, g, b, &h, &s, &v); if (s > INT_TOL && h > 300) h -= 360; if (s > INT_TOL && HueInFromRange((double)h)) { double fFraction=(double)0.0; if (fabs(gfFromAngle) > INT_TOL) { fFraction = (((double)h)-gfFromStart)/(gfFromAngle*((double)2.0)); } h = (int)(fFraction*gfToAngle*((double)2.0) + gfToStart); while (h >= 360) h -= 360; while (h < 0) h += 360; HSVtoRGB(h, s, v, (int*)(&r), (int*)(&g), (int*)(&b)); } dr = ((double)r) / ((double)256); dg = ((double)g) / ((double)256); db = ((double)b) / ((double)256); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; } else { int red=((int)tgifColors[nColorIndex].red); int green=((int)tgifColors[nColorIndex].green); int blue=((int)tgifColors[nColorIndex].blue); int h, v, real_red, real_green, real_blue; double s=(double)0; RGBtoHSV(red, green, blue, &h, &s, &v); if (s > INT_TOL && h > 300) h -= 360; if (s > INT_TOL && HueInFromRange((double)h)) { double fFraction=(double)0.0; if (fabs(gfFromAngle) > INT_TOL) { fFraction = (((double)h)-gfFromStart)/(gfFromAngle*((double)2.0)); } h = (int)(fFraction*gfToAngle*((double)2.0) + gfToStart); while (h >= 360) h -= 360; while (h < 0) h += 360; HSVtoRGB(h, s, v, &red, &green, &blue); real_red = ((red>0x0ffff) ? 0x0ffff : ((red<0) ? 0 : red)); real_green = ((green>0x0ffff) ? 0x0ffff : ((green<0) ? 0 : green)); real_blue = ((blue>0x0ffff) ? 0x0ffff : ((blue<0) ? 0 : blue)); pColor->red = (unsigned int)real_red; pColor->green = (unsigned int)real_green; pColor->blue = (unsigned int)real_blue; } else { pColor->red = (unsigned int)red; pColor->green = (unsigned int)green; pColor->blue = (unsigned int)blue; } } } void ChangeHue() { char *szFrom=NULL, *szFromAngle=NULL, *szTo=NULL, *szToAngle=NULL; char szSpec[MAXSTRING+1], szSpecCopy[MAXSTRING+1], szValue[MAXSTRING+1]; double sVal=(double)0, dVal=(double)0; int vVal; XColor xcolor; if (!CheckSelectionForImageProc(CMDID_CHANGEHUE)) return; if (TrueColorTransPixelCheck(topSel->obj, CMDID_CHANGEHUE)) return; *szSpec = '\0'; Dialog(TgLoadString(STID_ENTER_VAL_FOR_CHANGE_HUE), NULL, szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') return; strcpy(szSpecCopy, szSpec); if ((szFrom=strtok(szSpec, " ,\t\n\r")) == NULL || (szFromAngle=strtok(NULL, " ,\t\n\r")) == NULL || (szTo=strtok(NULL, " ,\t\n\r")) == NULL || (szToAngle=strtok(NULL, " ,\t\n\r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_FOR_4_VAL), szSpecCopy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (!TgifParseColor(szFrom, &xcolor)) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_IS_NOT_A_VALID_COLOR), szFrom); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } RGBtoHSV(((int)xcolor.red), ((int)xcolor.green), ((int)xcolor.blue), &gnFromHue, &sVal, &vVal); if (!TgifParseColor(szTo, &xcolor)) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_IS_NOT_A_VALID_COLOR), szTo); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } RGBtoHSV(((int)xcolor.red), ((int)xcolor.green), ((int)xcolor.blue), &gnToHue, &sVal, &vVal); strcpy(szValue, szFromAngle); if (sscanf(szValue, "%lf", &dVal) != 1) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_FOR_A_VAL), szFromAngle); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (dVal > (double)180.0) dVal = (double)180.0; if (dVal < (double)(-180.0)) dVal = (double)(-180.0); gfFromAngle = (float)dVal; gfFromStart = ((double)gnFromHue)-gfFromAngle; gfFromEnd = ((double)gnFromHue)+gfFromAngle; strcpy(szValue, szToAngle); if (sscanf(szValue, "%lf", &dVal) != 1) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_FOR_A_VAL), szToAngle); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (dVal > (double)180.0) dVal = (double)180.0; if (dVal < (double)(-180.0)) dVal = (double)(-180.0); gfToAngle = (float)dVal; gfToStart = ((double)gnToHue)-gfToAngle; gfToEnd = ((double)gnToHue)+gfToAngle; DoImageProc((NLFN*)ChangeToChangeHue); } /* ----------------------- ContrastEnhance ----------------------- */ static float gfContrastFactor=1.0; static void ChangeToContrastEnhance(nColorIndex, pColor) int nColorIndex; XColor *pColor; { struct XPmRec *xpm_ptr=topObj->detail.xpm; if (DoPpm6(xpm_ptr)) { int pixel=nColorIndex; FILE *fp=(FILE*)pColor; uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval; dg = ((double)g) / gTrueColorInfo.dg_maxval; db = ((double)b) / gTrueColorInfo.db_maxval; dr = ((dr-0.5) * ((double)gfContrastFactor) + 0.5) * 256.0; dg = ((dg-0.5) * ((double)gfContrastFactor) + 0.5) * 256.0; db = ((db-0.5) * ((double)gfContrastFactor) + 0.5) * 256.0; r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; } else { int red=(int)tgifColors[nColorIndex].red; int green=(int)tgifColors[nColorIndex].green; int blue=(int)tgifColors[nColorIndex].blue; int ival, real_red, real_green, real_blue; float fval; fval = ((float)(red-0x8000))*gfContrastFactor + ((float)0x8000); ival = round(fval); real_red = ((ival>0x0ffff) ? 0x0ffff : ((ival<0) ? 0 : ival)); fval = ((float)(green-0x8000))*gfContrastFactor + ((float)0x8000); ival = round(fval); real_green = ((ival>0x0ffff) ? 0x0ffff : ((ival<0) ? 0 : ival)); fval = ((float)(blue-0x8000))*gfContrastFactor + ((float)0x8000); ival = round(fval); real_blue = ((ival>0x0ffff) ? 0x0ffff : ((ival<0) ? 0 : ival)); pColor->red = (unsigned int)real_red; pColor->green = (unsigned int)real_green; pColor->blue = (unsigned int)real_blue; } } void ContrastEnhance() { char *c_ptr, szValue[MAXSTRING+1]; char szSpec[MAXSTRING+1], szSpecCopy[MAXSTRING+1]; float fVal; if (!CheckSelectionForImageProc(CMDID_CONTRASTENHANCE)) return; if (TrueColorTransPixelCheck(topSel->obj, CMDID_CONTRASTENHANCE)) return; *szSpec = '\0'; Dialog(TgLoadString(STID_ENTER_VAL_FOR_CONTRAST_ENH), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') return; strcpy(szSpecCopy, szSpec); if ((c_ptr=strtok(szSpec, " ,\t\n\r")) == NULL) return; strcpy(szValue, c_ptr); if (strcmp(szValue, "1.0") == 0 || strcmp(szValue, "1") == 0 || strcmp(szValue, "1.") == 0) { return; } else if (sscanf(szValue, "%f", &fVal) != 1) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_FOR_A_VAL), szSpecCopy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } else if (fVal < (float)0.0) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_NEG_VAL_NOT_ALLOWED), szSpecCopy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } gfContrastFactor = fVal; DoImageProc((NLFN*)ChangeToContrastEnhance); } /* ----------------------- ColorBalance ----------------------- */ static float gfRedBalanceFactor=1.0; static float gfGreenBalanceFactor=1.0; static float gfBlueBalanceFactor=1.0; static void ChangeToColorBalance(nColorIndex, pColor) int nColorIndex; XColor *pColor; { struct XPmRec *xpm_ptr=topObj->detail.xpm; if (DoPpm6(xpm_ptr)) { int pixel=nColorIndex; FILE *fp=(FILE*)pColor; uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval; dg = ((double)g) / gTrueColorInfo.dg_maxval; db = ((double)b) / gTrueColorInfo.db_maxval; dr = dr * gfRedBalanceFactor * ((double)256); dg = dg * gfGreenBalanceFactor * ((double)256); db = db * gfBlueBalanceFactor * ((double)256); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; } else { int red=(int)tgifColors[nColorIndex].red; int green=(int)tgifColors[nColorIndex].green; int blue=(int)tgifColors[nColorIndex].blue; int ival, real_red, real_green, real_blue; float fval; fval = ((float)red) * gfRedBalanceFactor; ival = round(fval); real_red = ((ival>0x0ffff) ? 0x0ffff : ((ival<0) ? 0 : ival)); fval = ((float)green) * gfGreenBalanceFactor; ival = round(fval); real_green = ((ival>0x0ffff) ? 0x0ffff : ((ival<0) ? 0 : ival)); fval = ((float)blue) * gfBlueBalanceFactor; ival = round(fval); real_blue = ((ival>0x0ffff) ? 0x0ffff : ((ival<0) ? 0 : ival)); pColor->red = (unsigned int)real_red; pColor->green = (unsigned int)real_green; pColor->blue = (unsigned int)real_blue; } } void ColorBalance() { char *c_ptr, szRed[MAXSTRING+1], szGreen[MAXSTRING+1], szBlue[MAXSTRING+1]; char szSpec[MAXSTRING+1], szSpecCopy[MAXSTRING+1]; if (!CheckSelectionForImageProc(CMDID_COLORBALANCE)) return; if (TrueColorTransPixelCheck(topSel->obj, CMDID_COLORBALANCE)) return; *szSpec = '\0'; Dialog(TgLoadString(STID_ENTER_VAL_FOR_COLOR_BAL), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') return; strcpy(szSpecCopy, szSpec); *szRed = *szGreen = *szBlue = '\0'; if ((c_ptr=strtok(szSpec, " ,\t\n\r")) != NULL) { strcpy(szRed, c_ptr); if ((c_ptr=strtok(NULL, " ,\t\n\r")) != NULL) { strcpy(szGreen, c_ptr); if ((c_ptr=strtok(NULL, " ,\t\n\r")) != NULL) { strcpy(szBlue, c_ptr); } } } if (*szRed == '\0' || *szGreen == '\0' || *szBlue == '\0' || sscanf(szRed, "%f", &gfRedBalanceFactor) != 1 || sscanf(szGreen, "%f", &gfGreenBalanceFactor) != 1 || sscanf(szBlue, "%f", &gfBlueBalanceFactor) != 1) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_FOR_3_VAL), szSpecCopy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } else if (gfRedBalanceFactor < (float)0.0 || gfGreenBalanceFactor < (float)0.0 || gfBlueBalanceFactor < (float)0.0) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_NEG_VAL_NOT_ALLOWED), szSpecCopy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } DoImageProc((NLFN*)ChangeToColorBalance); } /* ----------------------- Gamma ----------------------- */ static float gfOneOverGamma=1.0; static void ChangeToGamma(nColorIndex, pColor) int nColorIndex; XColor *pColor; { struct XPmRec *xpm_ptr=topObj->detail.xpm; if (DoPpm6(xpm_ptr)) { int pixel=nColorIndex; FILE *fp=(FILE*)pColor; uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval; dg = ((double)g) / gTrueColorInfo.dg_maxval; db = ((double)b) / gTrueColorInfo.db_maxval; dr = pow(dr, (double)gfOneOverGamma) * ((double)256); dg = pow(dg, (double)gfOneOverGamma) * ((double)256); db = pow(db, (double)gfOneOverGamma) * ((double)256); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; } else { double red=((double)tgifColors[nColorIndex].red)/((double)0x0ffff); double green=((double)tgifColors[nColorIndex].green)/((double)0x0ffff); double blue=((double)tgifColors[nColorIndex].blue)/((double)0x0ffff); int ival, real_red, real_green, real_blue; double dval; dval = pow(red, (double)gfOneOverGamma) * ((double)0x010000); ival = round(dval); real_red = ((ival>0x0ffff) ? 0x0ffff : ((ival<0) ? 0 : ival)); dval = pow(green, (double)gfOneOverGamma) * ((double)0x010000); ival = round(dval); real_green = ((ival>0x0ffff) ? 0x0ffff : ((ival<0) ? 0 : ival)); dval = pow(blue, (double)gfOneOverGamma) * ((double)0x010000); ival = round(dval); real_blue = ((ival>0x0ffff) ? 0x0ffff : ((ival<0) ? 0 : ival)); pColor->red = (unsigned int)real_red; pColor->green = (unsigned int)real_green; pColor->blue = (unsigned int)real_blue; } } void Gamma(buf) char *buf; { char *c_ptr, szValue[MAXSTRING+1]; char szSpec[MAXSTRING+1], szSpecCopy[MAXSTRING+1]; float gamma=0.0; if (!CheckSelectionForImageProc(CMDID_GAMMA)) return; if (TrueColorTransPixelCheck(topSel->obj, CMDID_GAMMA)) return; if (buf != NULL) { strcpy(szSpec, buf); } else { *szSpec = '\0'; Dialog(TgLoadString(STID_ENTER_VAL_FOR_GAMMA), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); } UtilTrimBlanks(szSpec); if (*szSpec == '\0') return; strcpy(szSpecCopy, szSpec); *szValue = '\0'; if ((c_ptr=strtok(szSpec, " ,\t\n\r")) != NULL) { strcpy(szValue, c_ptr); } if (*szValue == '\0' || sscanf(szValue, "%f", &gamma) != 1) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_FOR_A_VAL), szSpecCopy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } else if (gamma < (float)INT_TOL) { sprintf(gszMsgBox, TgLoadString(STID_GIVEN_NEG_VAL_NOT_ALLOWED), szSpecCopy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } gfOneOverGamma = (float)1.0 / gamma; DoImageProc((NLFN*)ChangeToGamma); } /* ----------------------- Convolution Required ----------------------- */ /* ----------------------- EdgeDetect ----------------------- */ #ifdef NOT_DEFINED static int tx=50, ty=16; #endif /* NOT_DEFINED */ static int ConvolveToEdgeDetect(x, y) int x, y; /* * [ -1 0 +1 ] [ -1 -2 -1 ] * horizontally: [ -2 0 +2 ] vertically: [ 0 0 0 ] * [ -2 0 +1 ] [ +1 +2 +1 ] */ { if (gConvExtraInfo.fp != NULL) { XColor **xcolors=gConvExtraInfo.xcolors; FILE *fp=gConvExtraInfo.fp; int w=gConvExtraInfo.image_w, h=gConvExtraInfo.image_h; unsigned char buf[3]; if (x == 0 || x == w-1 || y == 0 || y == h-1) { buf[0] = (unsigned char)xcolors[y][x].red; buf[1] = (unsigned char)xcolors[y][x].green; buf[2] = (unsigned char)xcolors[y][x].blue; } else { unsigned int r=0, g=0, b=0; double rx=0, gx=0, bx=0, ry=0, gy=0, by=0; double ddr, ddg, ddb; /* * Thinning is not implemented! */ rx = (double)( ((int)xcolors[y][x+1].red) + ((int)xcolors[y][x+1].red) + ((int)xcolors[y-1][x+1].red) + ((int)xcolors[y+1][x+1].red) - ((int)xcolors[y][x-1].red) - ((int)xcolors[y][x-1].red) - ((int)xcolors[y-1][x-1].red) - ((int)xcolors[y+1][x-1].red)); gx = (double)( ((int)xcolors[y][x+1].green) + ((int)xcolors[y][x+1].green) + ((int)xcolors[y-1][x+1].green) + ((int)xcolors[y+1][x+1].green) - ((int)xcolors[y][x-1].green) - ((int)xcolors[y][x-1].green) - ((int)xcolors[y-1][x-1].green) - ((int)xcolors[y+1][x-1].green)); bx = (double)( ((int)xcolors[y][x+1].blue) + ((int)xcolors[y][x+1].blue) + ((int)xcolors[y-1][x+1].blue) + ((int)xcolors[y+1][x+1].blue) - ((int)xcolors[y][x-1].blue) - ((int)xcolors[y][x-1].blue) - ((int)xcolors[y-1][x-1].blue) - ((int)xcolors[y+1][x-1].blue)); #ifdef NOT_DEFINED if (x == tx && y == ty) { fprintf(stderr, "x = %1d, y = %1d\n", x, y); fprintf(stderr, "rx = %g, gx = %g, bx = %g\n", rx, gx, bx); fflush(stderr); fprintf(stderr, "\n"); } #endif /* NOT_DEFINED */ ry = (double)( ((int)xcolors[y+1][x].red) + ((int)xcolors[y+1][x].red) + ((int)xcolors[y+1][x-1].red) + ((int)xcolors[y+1][x+1].red) - ((int)xcolors[y-1][x].red) - ((int)xcolors[y-1][x].red) - ((int)xcolors[y-1][x-1].red) - ((int)xcolors[y-1][x+1].red)); gy = (double)( ((int)xcolors[y+1][x].green) + ((int)xcolors[y+1][x].green) + ((int)xcolors[y+1][x-1].green) + ((int)xcolors[y+1][x+1].green) - ((int)xcolors[y-1][x].green) - ((int)xcolors[y-1][x].green) - ((int)xcolors[y-1][x-1].green) - ((int)xcolors[y-1][x+1].green)); by = (double)( ((int)xcolors[y+1][x].blue) + ((int)xcolors[y+1][x].blue) + ((int)xcolors[y+1][x-1].blue) + ((int)xcolors[y+1][x+1].blue) - ((int)xcolors[y-1][x].blue) - ((int)xcolors[y-1][x].blue) - ((int)xcolors[y-1][x-1].blue) - ((int)xcolors[y-1][x+1].blue)); if (rx == 0 && ry == 0 && gx == 0 && gy == 0 && bx == 0 && by == 0) { buf[0] = (unsigned char)255; buf[1] = (unsigned char)255; buf[2] = (unsigned char)255; } else { ddr = sqrt(rx*rx + ry*ry); ddg = sqrt(gx*gx + gy*gy); ddb = sqrt(bx*bx + by*by); r = (unsigned int)ddr; g = (unsigned int)ddg; b = (unsigned int)ddb; if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; r = 255 - r; g = 255 - g; b = 255 - b; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; } } if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; return TRUE; } else { XColor xcolor; long red, green, blue; if (x == 0 || x == gnImageW-1 || y == 0 || y == gnImageH-1) { return GetOrAllocHistogramIndex(&tgifColors[gnOrigImageIndex[y][x]]); } memset(&xcolor, 0, sizeof(XColor)); red = (((((long)tgifColors[gnOrigImageIndex[y][x]].red)<<2) - ((long)tgifColors[gnOrigImageIndex[y][x-1]].red) - ((long)tgifColors[gnOrigImageIndex[y][x+1]].red) - ((long)tgifColors[gnOrigImageIndex[y-1][x]].red) - ((long)tgifColors[gnOrigImageIndex[y+1][x]].red))>>2); green = (((((long)tgifColors[gnOrigImageIndex[y][x]].green)<<2) - ((long)tgifColors[gnOrigImageIndex[y][x-1]].green) - ((long)tgifColors[gnOrigImageIndex[y][x+1]].green) - ((long)tgifColors[gnOrigImageIndex[y-1][x]].green) - ((long)tgifColors[gnOrigImageIndex[y+1][x]].green))>>2); blue = (((((long)tgifColors[gnOrigImageIndex[y][x]].blue)<<2) - ((long)tgifColors[gnOrigImageIndex[y][x-1]].blue) - ((long)tgifColors[gnOrigImageIndex[y][x+1]].blue) - ((long)tgifColors[gnOrigImageIndex[y-1][x]].blue) - ((long)tgifColors[gnOrigImageIndex[y+1][x]].blue))>>2); xcolor.red = (red > 0L ? (red > 0x0000ffff ? 0x0ffff : (unsigned int)(red&0xffff)) : 0); xcolor.green = (green > 0L ? (green > 0x0000ffff ? 0x0ffff : (unsigned int)(green&0xffff)) : 0); xcolor.blue = (blue > 0L ? (blue > 0x0000ffff ? 0x0ffff : (unsigned int)(blue&0xffff)) : 0); return GetOrAllocHistogramIndex(&xcolor); } } void EdgeDetect() { if (!CheckSelectionForImageProc(CMDID_EDGEDETECT)) { return; } if (topSel->obj->detail.xpm->image_w < 2 || topSel->obj->detail.xpm->image_h < 2) { MsgBox(TgLoadString(STID_SEL_TOO_THIN_FLAT_FOR_EDGE), TOOL_NAME, INFO_MB); return; } gpConvolveFunc = (NLFN*)ConvolveToEdgeDetect; gpConvolveCmdID = CMDID_EDGEDETECT; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); } /* ----------------------- Emboss ----------------------- */ static int ConvolveToEmboss(x, y) int x, y; { if (gConvExtraInfo.fp != NULL) { XColor **xcolors=gConvExtraInfo.xcolors; FILE *fp=gConvExtraInfo.fp; int w=gConvExtraInfo.image_w, h=gConvExtraInfo.image_h; unsigned char buf[3]; if (x == 0 || x == w-1 || y == 0 || y == h-1) { double dgray=(double)0; int gray=0; dgray = 0.299*((double)xcolors[y][x].red) + 0.587*((double)xcolors[y][x].green) + 0.144*((double)xcolors[y][x].blue); gray = (int)round(dgray); if (gray < 0) gray = 0; if (gray > 255) gray = 255; buf[0] = buf[1] = buf[2] = (unsigned char)(unsigned int)gray; } else { double d_lt_gray=(double)0, d_rb_gray=(double)0, dgray=(double)0; int gray=0; d_lt_gray = 0.299*((double)xcolors[y-1][x-1].red) + 0.587*((double)xcolors[y-1][x-1].green) + 0.144*((double)xcolors[y-1][x-1].blue); d_rb_gray = 0.299*((double)xcolors[y+1][x+1].red) + 0.587*((double)xcolors[y+1][x+1].green) + 0.144*((double)xcolors[y+1][x+1].blue); dgray = 128.0 + ((d_rb_gray - d_lt_gray) / 2.0); gray = (int)round(dgray); if (gray < 0) gray = 0; if (gray > 255) gray = 255; buf[0] = buf[1] = buf[2] = (unsigned char)(unsigned int)gray; } if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; return TRUE; } else { XColor xcolor; memset(&xcolor, 0, sizeof(XColor)); if (x == 0 || x == gnImageW-1 || y == 0 || y == gnImageH-1) { float gray=0.299*((float)tgifColors[gnOrigImageIndex[y][x]].red) + 0.587*((float)tgifColors[gnOrigImageIndex[y][x]].green) + 0.144*((float)tgifColors[gnOrigImageIndex[y][x]].blue); xcolor.red = xcolor.green = xcolor.blue = (unsigned short)gray; return GetOrAllocHistogramIndex(&xcolor); } else { float lt_gray, rb_gray; int val; lt_gray=0.299*((float)tgifColors[gnOrigImageIndex[y-1][x-1]].red) + 0.587*((float)tgifColors[gnOrigImageIndex[y-1][x-1]].green) + 0.144*((float)tgifColors[gnOrigImageIndex[y-1][x-1]].blue); rb_gray=0.299*((float)tgifColors[gnOrigImageIndex[y+1][x+1]].red) + 0.587*((float)tgifColors[gnOrigImageIndex[y+1][x+1]].green) + 0.144*((float)tgifColors[gnOrigImageIndex[y+1][x+1]].blue); val = 0x7fff + (int)((rb_gray - lt_gray) / 2.0); val = ((val>0x0ffff) ? 0x0ffff : ((val<0) ? 0 : val)); xcolor.red = xcolor.green = xcolor.blue = (unsigned short)val; return GetOrAllocHistogramIndex(&xcolor); } } } void Emboss() { if (!CheckSelectionForImageProc(CMDID_EMBOSS)) return; if (topSel->obj->detail.xpm->image_w < 2 || topSel->obj->detail.xpm->image_h < 2) { MsgBox(TgLoadString(STID_SEL_TOO_THIN_FLAT_FOR_EMBOSS), TOOL_NAME, INFO_MB); return; } gpConvolveFunc = (NLFN*)ConvolveToEmboss; gpConvolveCmdID = CMDID_EMBOSS; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); } /* ----------------------- ReduceColors ----------------------- */ static int ConvolveToReduceColors(x, y) int x, y; { return GetOrAllocHistogramIndex(&tgifColors[gnOrigImageIndex[y][x]]); } void ReduceColors() { char *c_ptr, szSpec[MAXSTRING+1], szSpecCopy[MAXSTRING+1]; int colors_to_reduce_to=0; struct XPmRec *xpm_ptr=NULL; if (!CheckSelectionForImageProc(CMDID_REDUCECOLORS)) { return; } sprintf(gszMsgBox, TgLoadString(STID_ENTER_NUM_COLORS_TO_REDUCE_TO), topSel->obj->detail.xpm->ncolors); *szSpec = '\0'; Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') return; xpm_ptr = topSel->obj->detail.xpm; strcpy(szSpecCopy, szSpec); if ((c_ptr=strtok(szSpec, " ,\t\n\r")) == NULL) return; colors_to_reduce_to = atoi(c_ptr); if (DoPpm6(xpm_ptr)) { if (colors_to_reduce_to < 2 || colors_to_reduce_to > 256) { sprintf(gszMsgBox, TgLoadString(STID_NUM_COLORS_BETWEEN_2_N_GIVEN), szSpecCopy, 256); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } else { if (colors_to_reduce_to < 2 || colors_to_reduce_to > topSel->obj->detail.xpm->ncolors) { sprintf(gszMsgBox, TgLoadString(STID_NUM_COLORS_BETWEEN_2_N_GIVEN), szSpecCopy, topSel->obj->detail.xpm->ncolors); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } gnUserSpecifiedLevels = colors_to_reduce_to; gpConvolveFunc = (NLFN*)ConvolveToReduceColors; gpConvolveCmdID = CMDID_REDUCECOLORS; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); gnUserSpecifiedLevels = (-1); } /* ----------------------- ReduceToPixmapColors ----------------------- */ static struct XPmRec gXPmTarget; static XColor *gTargetColors=NULL; static int *gTargetColorValid=NULL; static int *gnObjectColorsToTargetColorMapping=NULL; static int *gnTgifColorsToObjectColorMapping=NULL; static int gnFloyd=FALSE; static int **gnImageTargetColor=NULL; static XImage *gpTargetImage=NULL, *gpTargetBitmapImage=NULL; static void FreeTargetColors(ncolors) int ncolors; { if (gTargetColors != NULL) { free(gTargetColors); gTargetColors = NULL; } if (gTargetColorValid != NULL) { free(gTargetColorValid); gTargetColorValid = NULL; } } static int AllocTargetColors(ncolors) int ncolors; { int i=0; gTargetColors = (XColor*)malloc(ncolors*sizeof(XColor)); if (gTargetColors == NULL) FailAllocMessage(); memset(gTargetColors, 0, ncolors*sizeof(XColor)); gTargetColorValid = (int*)malloc(ncolors*sizeof(int)); if (gTargetColorValid == NULL) FailAllocMessage(); for (i=0; i < ncolors; i++) { gTargetColorValid[i] = TRUE; } return TRUE; } static int GetClosestColorIndex(red_bits, green_bits, blue_bits, red, green, blue, target_ncolors) int red_bits, green_bits, blue_bits, red, green, blue, target_ncolors; { int min_index=0; unsigned long dr=(double)0, dg=(double)0, db=(double)0, min_dist=(double)0; if (gXPmTarget.color_str != NULL || gXPmTarget.userdata == (void*)CMDID_REDUCETOMOBILEWEBCOLORS) { /* ReduceToPixmapColors() or ReduceToMobileWebSafeColors() */ int j=0; for (j=0; j < target_ncolors; j++) { if (gTargetColorValid[j]) { dr = (unsigned long)abs(red-(int)(gTargetColors[j].red)); dg = (unsigned long)abs(green-(int)(gTargetColors[j].green)); db = (unsigned long)abs(blue-(int)(gTargetColors[j].blue)); dr >>= 4; dg >>= 4; db >>= 4; break; } } min_index = j; min_dist = dr*dr + dg*dg + db*db; for (j++; j < target_ncolors; j++) { if (gTargetColorValid[j]) { unsigned long new_dist; dr = (unsigned long)abs(red-(int)(gTargetColors[j].red)); dg = (unsigned long)abs(green-(int)(gTargetColors[j].green)); db = (unsigned long)abs(blue-(int)(gTargetColors[j].blue)); dr >>= 4; dg >>= 4; db >>= 4; new_dist = dr*dr + dg*dg + db*db; if (new_dist < min_dist) { min_index = j; min_dist = new_dist; } } } } else if (gXPmTarget.userdata == (void*)CMDID_REDUCETOMOBILEWEBCOLORS) { /* ReduceToDefaultColors() or DefaultErrorDiffuse() */ int k, j, i; int red_max=(1<<red_bits); int green_max=(1<<green_bits); int blue_max=(1<<blue_bits); int red_index=(red >> (16-red_bits)); int green_index=(green >> (16-green_bits)); int blue_index=(blue >> (16-blue_bits)); min_index = 0; dr = (unsigned long)abs(red-(int)(gTargetColors[min_index].red)); dg = (unsigned long)abs(green-(int)(gTargetColors[min_index].green)); db = (unsigned long)abs(blue-(int)(gTargetColors[min_index].blue)); dr >>= 4; dg >>= 4; db >>= 4; min_dist = dr*dr + dg*dg + db*db; for (i=red_index-1; i <= red_index+1; i++) { if (i >= 0 && i < red_max) { for (j=green_index-1; j <= green_index+1; j++) { if (j >= 0 && j < green_max) { for (k=blue_index-1; k <= blue_index+1; k++) { if (k >= 0 && k < blue_max) { if (i!=red_index || j!=green_index || k!=blue_index) { int index=(((i << green_bits) + j) << blue_bits) + k; unsigned long new_dist; dr = (unsigned long)abs(red - (int)(gTargetColors[index].red)); dg = (unsigned long)abs(green - (int)(gTargetColors[index].green)); db = (unsigned long)abs(blue - (int)(gTargetColors[index].blue)); dr >>= 4; dg >>= 4; db >>= 4; new_dist = dr*dr + dg*dg + db*db; if (new_dist < min_dist) { min_index = index; min_dist = new_dist; } } } } } } } } } else { /* ReduceToDefaultColors() or DefaultErrorDiffuse() */ int k, j, i; int red_max=(1<<red_bits); int green_max=(1<<green_bits); int blue_max=(1<<blue_bits); int red_index=(red >> (16-red_bits)); int green_index=(green >> (16-green_bits)); int blue_index=(blue >> (16-blue_bits)); min_index = (((red_index << green_bits) + green_index) << blue_bits) + blue_index; dr = (unsigned long)abs(red-(int)(gTargetColors[min_index].red)); dg = (unsigned long)abs(green-(int)(gTargetColors[min_index].green)); db = (unsigned long)abs(blue-(int)(gTargetColors[min_index].blue)); dr >>= 4; dg >>= 4; db >>= 4; min_dist = dr*dr + dg*dg + db*db; for (i=red_index-1; i <= red_index+1; i++) { if (i >= 0 && i < red_max) { for (j=green_index-1; j <= green_index+1; j++) { if (j >= 0 && j < green_max) { for (k=blue_index-1; k <= blue_index+1; k++) { if (k >= 0 && k < blue_max) { if (i!=red_index || j!=green_index || k!=blue_index) { int index=(((i << green_bits) + j) << blue_bits) + k; unsigned long new_dist; dr = (unsigned long)abs(red - (int)(gTargetColors[index].red)); dg = (unsigned long)abs(green - (int)(gTargetColors[index].green)); db = (unsigned long)abs(blue - (int)(gTargetColors[index].blue)); dr >>= 4; dg >>= 4; db >>= 4; new_dist = dr*dr + dg*dg + db*db; if (new_dist < min_dist) { min_index = index; min_dist = new_dist; } } } } } } } } } return min_index; } static int ConvolveToErrorDiffuse(x, y) int x, y; { int targetcolor_index=gnImageTargetColor[y][x]; if (gConvExtraInfo.fp != NULL) { FILE *fp=gConvExtraInfo.fp; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; unsigned int r=(unsigned int)(gTargetColors[targetcolor_index].red); unsigned int g=(unsigned int)(gTargetColors[targetcolor_index].green); unsigned int b=(unsigned int)(gTargetColors[targetcolor_index].blue); dr = ((double)r) / maxRGB * ((double)255); dg = ((double)g) / maxRGB * ((double)255); db = ((double)b) / maxRGB * ((double)255); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; return TRUE; } else { return GetOrAllocHistogramIndex(&gTargetColors[targetcolor_index]); } } static int ConvolveToReduceToPixmapColors(x, y) int x, y; { if (gConvExtraInfo.fp != NULL) { int index=0, pixel=XGetPixel(gConvExtraInfo.image,x,y); FILE *fp=gConvExtraInfo.fp; uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; unsigned char buf[3]; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval * ((double)maxRGB); dg = ((double)g) / gTrueColorInfo.dg_maxval * ((double)maxRGB); db = ((double)b) / gTrueColorInfo.db_maxval * ((double)maxRGB); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > maxRGB) r = maxRGB; if (g > maxRGB) g = maxRGB; if (b > maxRGB) b = maxRGB; index = GetClosestColorIndex(gDefErrorDiffuseLevel.red, gDefErrorDiffuseLevel.green, gDefErrorDiffuseLevel.blue, (int)r, (int)g, (int)b, gnUserSpecifiedLevels); r = (unsigned int)(gTargetColors[index].red); g = (unsigned int)(gTargetColors[index].green); b = (unsigned int)(gTargetColors[index].blue); dr = ((double)r) / maxRGB * ((double)255); dg = ((double)g) / maxRGB * ((double)255); db = ((double)b) / maxRGB * ((double)255); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; return TRUE; } else { int tgifcolor_index=gnOrigImageIndex[y][x]; /* index into tgifColors */ int objcolor_index=gnTgifColorsToObjectColorMapping[tgifcolor_index]; int targetcolor_index=gnObjectColorsToTargetColorMapping[objcolor_index]; return GetOrAllocHistogramIndex(&gTargetColors[targetcolor_index]); } } static int GetIntensity(index, max_levels) int index, max_levels; /* 0 < max_levels <= 255 */ /* * May be it should be like the following: * * int ival=(int)(((double)index)/((double)max_levels)*((double)maxRGB)); * * return (ival < 0 ? 0 : (ival > maxRGB ? maxRGB : ival)); */ { int ival=(int)(((double)index)/((double)max_levels)*((double)255)); return ((ival < 0 ? 0 : (ival > 0xff ? 0xff : ival))<<8); } #define FS_SCALE 0x400 #define HALF_FS_SCALE 0x200 static int DoPrepareForErrorDiffuse(xpm_ptr) struct XPmRec *xpm_ptr; { int j, i, target_ncolors=gXPmTarget.ncolors, fs_forward=TRUE; int image_w=xpm_ptr->image_w, image_h=xpm_ptr->image_h; int red_bits=0, green_bits=0, blue_bits=0; long *this_r_err, *this_g_err, *this_b_err, *tmp_err; long *next_r_err, *next_g_err, *next_b_err; ProgressInfo pi; if (!CreatePixelToIndexMapping()) return FALSE; if (gXPmTarget.color_str != NULL) { for (i=0; i < target_ncolors; i++) { if (!TgifParseColor(gXPmTarget.color_str[i], &gTargetColors[i])) { gTargetColorValid[i] = FALSE; } } } else { red_bits = gDefErrorDiffuseLevel.red; green_bits = gDefErrorDiffuseLevel.green; blue_bits = gDefErrorDiffuseLevel.blue; } if (!GetXPmImages(xpm_ptr, &gpTargetImage, &gpTargetBitmapImage)) { return FALSE; } gnImageTargetColor = (int**)malloc(image_h*sizeof(int*)); if (gnImageTargetColor == NULL) return FailAllocMessage(); for (i=0; i < image_h; i++) { if ((gnImageTargetColor[i]=(int*)malloc(image_w*sizeof(int))) == NULL) { for (j=0; j < i; j++) free(gnImageTargetColor[j]); free(gnImageTargetColor); gnImageTargetColor = NULL; return FailAllocMessage(); } } this_r_err = (long*)malloc((image_w+2)*sizeof(long)); this_g_err = (long*)malloc((image_w+2)*sizeof(long)); this_b_err = (long*)malloc((image_w+2)*sizeof(long)); next_r_err = (long*)malloc((image_w+2)*sizeof(long)); next_g_err = (long*)malloc((image_w+2)*sizeof(long)); next_b_err = (long*)malloc((image_w+2)*sizeof(long)); if (this_r_err==NULL || this_g_err==NULL || this_b_err==NULL || next_r_err==NULL || next_g_err==NULL || next_b_err==NULL) { if (this_r_err != NULL) free(this_r_err); if (this_g_err != NULL) free(this_g_err); if (this_b_err != NULL) free(this_b_err); if (next_r_err != NULL) free(next_r_err); if (next_g_err != NULL) free(next_g_err); if (next_b_err != NULL) free(next_b_err); return FALSE; } srand(0); for (j=0; j < image_w+2; j++) { this_r_err[j] = (rand() % FS_SCALE - HALF_FS_SCALE) << 4; this_g_err[j] = (rand() % FS_SCALE - HALF_FS_SCALE) << 4; this_b_err[j] = (rand() % FS_SCALE - HALF_FS_SCALE) << 4; } BeginProgress(&pi, image_h); for (i=0; i < image_h; i++) { int col, limitcol; UpdateProgress(&pi, i); /*--------------------------------------------------------*/ /* the error diffusion code is adapted from 'ppmquant.c', */ /* which is part of the netpbm package. */ /* */ /* Copyright (C) 1989, 1991 by Jef Poskanzer */ /*--------------------------------------------------------*/ col = (fs_forward ? 0 : image_w-1); limitcol = (fs_forward ? image_w : (-1)); for (j=0; j < image_w+2; j++) { next_r_err[j] = next_g_err[j] = next_b_err[j] = 0L; } do { int red, green, blue, err, min_index=0; int pixel=XGetPixel(gpTargetImage, col, i); if (DoPpm6(xpm_ptr)) { uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval * ((double)65535); dg = ((double)g) / gTrueColorInfo.dg_maxval * ((double)65535); db = ((double)b) / gTrueColorInfo.db_maxval * ((double)65535); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 65535) r = 65535; if (g > 65535) g = 65535; if (b > 65535) b = 65535; red = (int)(r) + this_r_err[col+1]; green = (int)(g) + this_g_err[col+1]; blue = (int)(b) + this_b_err[col+1]; if (red < 0) red = 0; if (red > 65535) red = 65535; if (green < 0) green = 0; if (green > 65535) green = 65535; if (blue < 0) blue = 0; if (blue > 65535) blue = 65535; min_index = GetClosestColorIndex(gDefErrorDiffuseLevel.red, gDefErrorDiffuseLevel.green, gDefErrorDiffuseLevel.blue, (int)red, (int)green, (int)blue, target_ncolors); } else { int index=GetIndexOfPixel(pixel); red = (int)(tgifColors[index].red) + this_r_err[col+1]; green = (int)(tgifColors[index].green) + this_g_err[col+1]; blue = (int)(tgifColors[index].blue) + this_b_err[col+1]; if (red < 0) red = 0; if (red > 65535) red = 65535; if (green < 0) green = 0; if (green > 65535) green = 65535; if (blue < 0) blue = 0; if (blue > 65535) blue = 65535; min_index = GetClosestColorIndex(red_bits, green_bits, blue_bits, red, green, blue, target_ncolors); } gnImageTargetColor[i][col] = min_index; if (fs_forward) { err = (red - gTargetColors[min_index].red); /* * FS_SCALE; */ this_r_err[col+2] += (err*7) >> 4; next_r_err[col ] += (err*3) >> 4; next_r_err[col+1] += (err*5) >> 4; next_r_err[col+2] += (err ) >> 4; err = (green - gTargetColors[min_index].green); /* * FS_SCALE; */ this_g_err[col+2] += (err*7) >> 4; next_g_err[col ] += (err*3) >> 4; next_g_err[col+1] += (err*5) >> 4; next_g_err[col+2] += (err ) >> 4; err = (blue - gTargetColors[min_index].blue); /* * FS_SCALE; */ this_b_err[col+2] += (err*7) >> 4; next_b_err[col ] += (err*3) >> 4; next_b_err[col+1] += (err*5) >> 4; next_b_err[col+2] += (err ) >> 4; col++; } else { err = (red - gTargetColors[min_index].red); /* * FS_SCALE; */ this_r_err[col ] += (err*7) >> 4; next_r_err[col+2] += (err*3) >> 4; next_r_err[col+1] += (err*5) >> 4; next_r_err[col ] += (err ) >> 4; err = (green - gTargetColors[min_index].green); /* * FS_SCALE; */ this_g_err[col ] += (err*7) >> 4; next_g_err[col+2] += (err*3) >> 4; next_g_err[col+1] += (err*5) >> 4; next_g_err[col ] += (err ) >> 4; err = (blue - gTargetColors[min_index].blue); /* * FS_SCALE; */ this_b_err[col ] += (err*7) >> 4; next_b_err[col+2] += (err*3) >> 4; next_b_err[col+1] += (err*5) >> 4; next_b_err[col ] += (err ) >> 4; col--; } } while (col != limitcol); tmp_err = this_r_err; this_r_err = next_r_err; next_r_err = tmp_err; tmp_err = this_g_err; this_g_err = next_g_err; next_g_err = tmp_err; tmp_err = this_b_err; this_b_err = next_b_err; next_b_err = tmp_err; fs_forward = !fs_forward; } free(this_r_err); free(this_g_err); free(this_b_err); free(next_r_err); free(next_g_err); free(next_b_err); return TRUE; } static int PrepareForErrorDiffuse(xpm_ptr) struct XPmRec *xpm_ptr; { int rc; SaveStatusStrings(); SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = DoPrepareForErrorDiffuse(xpm_ptr); SetDefaultCursor(mainWindow); ShowCursor(); RestoreStatusStrings(); return rc; } static int MapTargetColors(xpm_ptr) struct XPmRec *xpm_ptr; { int i, target_ncolors=gXPmTarget.ncolors; int red_bits=0, green_bits=0, blue_bits=0; if (gXPmTarget.color_str != NULL) { for (i=0; i < target_ncolors; i++) { if (!TgifParseColor(gXPmTarget.color_str[i], &gTargetColors[i])) { gTargetColorValid[i] = FALSE; } } } else { red_bits = gDefErrorDiffuseLevel.red; green_bits = gDefErrorDiffuseLevel.green; blue_bits = gDefErrorDiffuseLevel.blue; } gnTgifColorsToObjectColorMapping = (int*)malloc(maxColors*sizeof(int)); if (gnTgifColorsToObjectColorMapping == NULL) { FailAllocMessage(); return FALSE; } memset(gnTgifColorsToObjectColorMapping, (-1), maxColors*sizeof(int)); for (i=0; i < maxColors; i++) { int cur_pixel=colorPixels[i], ncolors=xpm_ptr->ncolors; int found_index, *pixels=xpm_ptr->pixels; int red, green, blue, min_index; for (found_index=0; found_index < ncolors; found_index++) { if (pixels[found_index] == cur_pixel) { break; } } if (found_index >= ncolors) { continue; } gnTgifColorsToObjectColorMapping[i] = found_index; red = (int)(tgifColors[i].red); green = (int)(tgifColors[i].green); blue = (int)(tgifColors[i].blue); min_index = GetClosestColorIndex(red_bits, green_bits, blue_bits, red, green, blue, target_ncolors); gnObjectColorsToTargetColorMapping[found_index] = min_index; } return TRUE; } void ReduceToPixmapColors() { int i, ok=TRUE, rc, short_name=FALSE; char xpm_fname[MAXPATHLENGTH+1], *rest=NULL, tmp_fname[MAXPATHLENGTH+1]; XEvent ev; int ncolors=0, chars_per_pixel=0, first_pixel_is_bg=0, remote_file=FALSE; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL; struct XPmRec *xpm_ptr=NULL; if (!CheckSelectionForImageProc(CMDID_REDUCETOPIXMAPCOLORS)) { return; } importingFile = TRUE; *xpm_fname = *tmp_fname = '\0'; gnObjectColorsToTargetColorMapping = NULL; if (importFromLibrary) { char name[MAXSTRING+1], path[MAXSTRING+1]; if (SelectFromLibrary(TgLoadString(STID_SEL_XPM_FILE_FOR_RED_COLORS), XPM_FILE_EXT, name, path) == INVALID) { ok = FALSE; } else { sprintf(xpm_fname, "%s%c%s", path, DIR_SEP, name); } } else if (SelectFileNameToImport( TgLoadString(STID_SEL_XPM_FILE_FOR_RED_COLORS), XPM_FILE_EXT, xpm_fname) == INVALID) { ok = FALSE; } else if (FileIsRemote(xpm_fname)) { int is_html=FALSE; if (!DownloadRemoteFile(xpm_fname, NULL, NULL, &is_html, tmp_fname, NULL, 0) || *tmp_fname == '\0') { ok = FALSE; } else { remote_file = TRUE; } } importingFile = FALSE; if (!ok) { if (remote_file) unlink(tmp_fname); return; } XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev)) { ExposeEventHandler(&ev, TRUE); } xpm_ptr = topSel->obj->detail.xpm; if (DoPpm6(xpm_ptr)) { gnObjectColorsToTargetColorMapping = NULL; } else { gnObjectColorsToTargetColorMapping = (int*)malloc(xpm_ptr->ncolors*sizeof(int)); if (gnObjectColorsToTargetColorMapping == NULL) { FailAllocMessage(); if (remote_file) unlink(tmp_fname); return; } memset(gnObjectColorsToTargetColorMapping, 0, xpm_ptr->ncolors*sizeof(int)); } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(remote_file ? tmp_fname : xpm_fname, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, NULL, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if (remote_file) { short_name = FALSE; } else { if ((short_name=IsPrefix(bootDir, xpm_fname, &rest))) ++rest; } if (rc != BitmapSuccess) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_XPM_FILE), (short_name ? rest : xpm_fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (gnObjectColorsToTargetColorMapping != NULL) { free(gnObjectColorsToTargetColorMapping); gnObjectColorsToTargetColorMapping = NULL; } if (remote_file) unlink(tmp_fname); return; } gXPmTarget.ncolors = ncolors; gXPmTarget.chars_per_pixel = chars_per_pixel; gXPmTarget.first_pixel_is_bg = first_pixel_is_bg; gXPmTarget.color_char = color_char; gXPmTarget.color_str = color_str; gXPmTarget.data = xpm_data; gXPmTarget.userdata = (void*)CMDID_REDUCETOPIXMAPCOLORS; if (ncolors <= 0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_XPM_FILE), (short_name ? rest : xpm_fname)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { int image_h=xpm_ptr->image_h; rc = MsgBox(TgLoadString(STID_Q_FS_ERROR_DIFFUSE), TOOL_NAME, YNC_MB); switch (rc) { case MB_ID_YES: gnFloyd = TRUE; break; case MB_ID_NO: gnFloyd = FALSE; break; case MB_ID_CANCEL: if (gnObjectColorsToTargetColorMapping != NULL) { free(gnObjectColorsToTargetColorMapping); gnObjectColorsToTargetColorMapping = NULL; } if (remote_file) unlink(tmp_fname); return; } AllocTargetColors(ncolors); if (gnFloyd) { if (DoPpm6(xpm_ptr)) { if (!InitTrueColorInfo(xpm_ptr->image, &gTrueColorInfo, xpm_ptr->image_w)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), xpm_ptr->image_w, xpm_ptr->image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (gnObjectColorsToTargetColorMapping != NULL) { free(gnObjectColorsToTargetColorMapping); gnObjectColorsToTargetColorMapping = NULL; } if (remote_file) unlink(tmp_fname); return; } } rc = PrepareForErrorDiffuse(xpm_ptr); CleanUpIndexOfPixel(); if (gpTargetImage != NULL) XDestroyImage(gpTargetImage); if (gpTargetBitmapImage != NULL) XDestroyImage(gpTargetBitmapImage); gpTargetImage = gpTargetBitmapImage = NULL; } else { if (DoPpm6(xpm_ptr)) { if (gXPmTarget.color_str != NULL) { for (i=0; i < ncolors; i++) { if (!TgifParseColor(gXPmTarget.color_str[i], &gTargetColors[i])) { gTargetColorValid[i] = FALSE; } } } rc = TRUE; } else { rc = MapTargetColors(xpm_ptr); } } if (rc) { gnUserSpecifiedLevels = ncolors; if (gnFloyd) { gpConvolveFunc = (NLFN*)ConvolveToErrorDiffuse; gpConvolveCmdID = CMDID_REDUCETOPIXMAPCOLORS; } else { gpConvolveFunc = (NLFN*)ConvolveToReduceToPixmapColors; gpConvolveCmdID = CMDID_REDUCETOPIXMAPCOLORS; } gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); gnUserSpecifiedLevels = (-1); } FreeTargetColors(); if (gnFloyd) { if (gnImageTargetColor != NULL) { for (i=0; i < image_h; i++) free(gnImageTargetColor[i]); free(gnImageTargetColor); gnImageTargetColor = NULL; } } gnFloyd = FALSE; } if (gXPmTarget.color_char != NULL) free(gXPmTarget.color_char); if (gXPmTarget.color_str != NULL) { for (i=0; i < gXPmTarget.ncolors; i++) free(gXPmTarget.color_str[i]); free(gXPmTarget.color_str); } if (gXPmTarget.data != NULL) free(gXPmTarget.data); memset(&gXPmTarget, 0, sizeof(struct XPmRec)); if (gnObjectColorsToTargetColorMapping != NULL) { free(gnObjectColorsToTargetColorMapping); gnObjectColorsToTargetColorMapping = NULL; } if (gnTgifColorsToObjectColorMapping != NULL) { free(gnTgifColorsToObjectColorMapping); gnTgifColorsToObjectColorMapping = NULL; } if (remote_file) unlink(tmp_fname); } /* ---------------------- ReduceToMobileWebSafeColors ---------------------- */ static int GetMobileWebSafeIntensity(index) int index; { switch (index) { case 0: return 0x00000; case 1: return 0x03300; case 2: return 0x06600; case 3: return 0x09900; case 4: return 0x0cc00; case 5: return 0x0ff00; } TgAssert(FALSE, "invalid parameter passed to GetMobileWebSafeIntensity()", NULL); return (-1); } void ReduceToMobileWebSafeColors() { int i, red=0, rc=FALSE, ncolors=0, image_h=0; struct XPmRec *xpm_ptr=NULL; if (!CheckSelectionForImageProc(CMDID_REDUCETOMOBILEWEBCOLORS)) { return; } xpm_ptr = topSel->obj->detail.xpm; image_h = xpm_ptr->image_h; if (DoPpm6(xpm_ptr)) { gnObjectColorsToTargetColorMapping = NULL; } else { gnObjectColorsToTargetColorMapping = (int*)malloc(xpm_ptr->ncolors*sizeof(int)); if (gnObjectColorsToTargetColorMapping == NULL) { FailAllocMessage(); return; } memset(gnObjectColorsToTargetColorMapping, 0, xpm_ptr->ncolors*sizeof(int)); } ncolors = 6*6*6; memset(&gXPmTarget, 0, sizeof(struct XPmRec)); gXPmTarget.ncolors = ncolors; gXPmTarget.userdata = (void*)CMDID_REDUCETOMOBILEWEBCOLORS; rc = MsgBox(TgLoadString(STID_Q_FS_ERROR_DIFFUSE), TOOL_NAME, YNC_MB); switch (rc) { case MB_ID_YES: gnFloyd = TRUE; break; case MB_ID_NO: gnFloyd = FALSE; break; case MB_ID_CANCEL: if (gnObjectColorsToTargetColorMapping != NULL) { free(gnObjectColorsToTargetColorMapping); gnObjectColorsToTargetColorMapping = NULL; } return; } AllocTargetColors(ncolors); i = 0; for (red=0; red < 6; red++) { int red_intensity=GetMobileWebSafeIntensity(red), green; for (green=0; green < 6; green++) { int green_intensity=GetMobileWebSafeIntensity(green), blue; for (blue=0; blue < 6; blue++) { int blue_intensity=GetMobileWebSafeIntensity(blue); gTargetColors[i].red = red_intensity; gTargetColors[i].green = green_intensity; gTargetColors[i].blue = blue_intensity; i++; } } } if (gnFloyd) { if (DoPpm6(xpm_ptr)) { if (!InitTrueColorInfo(xpm_ptr->image, &gTrueColorInfo, xpm_ptr->image_w)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), xpm_ptr->image_w, xpm_ptr->image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (gnObjectColorsToTargetColorMapping != NULL) { free(gnObjectColorsToTargetColorMapping); gnObjectColorsToTargetColorMapping = NULL; } return; } } rc = PrepareForErrorDiffuse(xpm_ptr); CleanUpIndexOfPixel(); if (gpTargetImage != NULL) XDestroyImage(gpTargetImage); if (gpTargetBitmapImage != NULL) XDestroyImage(gpTargetBitmapImage); gpTargetImage = gpTargetBitmapImage = NULL; } else { if (DoPpm6(xpm_ptr)) { rc = TRUE; } else { rc = MapTargetColors(xpm_ptr); } } if (rc) { gnUserSpecifiedLevels = ncolors; if (gnFloyd) { gpConvolveFunc = (NLFN*)ConvolveToErrorDiffuse; gpConvolveCmdID = CMDID_REDUCETOMOBILEWEBCOLORS; } else { gpConvolveFunc = (NLFN*)ConvolveToReduceToPixmapColors; gpConvolveCmdID = CMDID_REDUCETOMOBILEWEBCOLORS; } gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); gnUserSpecifiedLevels = (-1); } FreeTargetColors(); if (gnFloyd) { if (gnImageTargetColor != NULL) { for (i=0; i < image_h; i++) free(gnImageTargetColor[i]); free(gnImageTargetColor); gnImageTargetColor = NULL; } } memset(&gXPmTarget, 0, sizeof(struct XPmRec)); if (gnObjectColorsToTargetColorMapping != NULL) { free(gnObjectColorsToTargetColorMapping); gnObjectColorsToTargetColorMapping = NULL; } if (gnTgifColorsToObjectColorMapping != NULL) { free(gnTgifColorsToObjectColorMapping); gnTgifColorsToObjectColorMapping = NULL; } } /* ----------------------- SetDefaultColorLevels ----------------------- */ #define PDCL_OK 0 #define PDCL_TOO_LARGE 1 #define PDCL_TOO_SMALL 2 #define PDCL_BAD_FORMAT 3 static int ParseDefaultColorLevels(buf, p_xcolor) char *buf; XColor *p_xcolor; { char *red_ptr, *green_ptr, *blue_ptr; if ((red_ptr=strtok(buf, " ,:\t\n\r")) != NULL && (green_ptr=strtok(NULL, " ,:\t\n\r")) != NULL && (blue_ptr=strtok(NULL, " ,:\t\n\r")) != NULL) { int red, green, blue; red = atoi(red_ptr); green = atoi(green_ptr); blue = atoi(blue_ptr); if (red+green+blue > 8) { return PDCL_TOO_LARGE; } else if (red <= 0 || green <= 0 || blue <= 0) { return PDCL_TOO_SMALL; } else { p_xcolor->red = red; p_xcolor->green = green; p_xcolor->blue = blue; return PDCL_OK; } } return PDCL_BAD_FORMAT; } void SetDefaultColorLevels() { char szSpec[MAXSTRING+1], szSpecCopy[MAXSTRING+1]; XColor xcolor; sprintf(gszMsgBox, TgLoadString(STID_ENTER_NUM_BITS_IN_RGB), (int)gDefErrorDiffuseLevel.red, (int)gDefErrorDiffuseLevel.green, (int)gDefErrorDiffuseLevel.blue); *szSpec = '\0'; Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') return; strcpy(szSpecCopy, szSpec); switch (ParseDefaultColorLevels(szSpecCopy, &xcolor)) { case PDCL_OK: gDefErrorDiffuseLevel.red = xcolor.red; gDefErrorDiffuseLevel.green = xcolor.green; gDefErrorDiffuseLevel.blue = xcolor.blue; Msg(TgLoadString(STID_RGB_LEVELS_CHANGED_TO)); break; case PDCL_TOO_LARGE: sprintf(gszMsgBox, TgLoadString(STID_BAD_VAL_SUM_RGB_LEVEL), szSpec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; case PDCL_TOO_SMALL: sprintf(gszMsgBox, TgLoadString(STID_BAD_VAL_GT_0_RGB_LEVEL), szSpec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; case PDCL_BAD_FORMAT: sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_FOR_3_VAL), szSpec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; } } /* ----------------------- ReduceToDefaultColors ----------------------- */ void ReduceToDefaultColors() { int i, red=0, rc=FALSE, ncolors=0, image_h=0; int red_bits, green_bits, blue_bits, red_levels, green_levels, blue_levels; struct XPmRec *xpm_ptr=NULL; if (!CheckSelectionForImageProc(CMDID_DEFAULTERRORDIFFUSE)) { return; } xpm_ptr = topSel->obj->detail.xpm; image_h = xpm_ptr->image_h; if (DoPpm6(xpm_ptr)) { gnObjectColorsToTargetColorMapping = NULL; } else { gnObjectColorsToTargetColorMapping = (int*)malloc(xpm_ptr->ncolors*sizeof(int)); if (gnObjectColorsToTargetColorMapping == NULL) { FailAllocMessage(); return; } memset(gnObjectColorsToTargetColorMapping, 0, xpm_ptr->ncolors*sizeof(int)); } red_bits = gDefErrorDiffuseLevel.red; green_bits = gDefErrorDiffuseLevel.green; blue_bits = gDefErrorDiffuseLevel.blue; sprintf(gszMsgBox, TgLoadString(STID_RGB_LEVELS_ARE), red_bits, green_bits, blue_bits); Msg(gszMsgBox); red_levels = (1 << red_bits); green_levels = (1 << green_bits); blue_levels = (1 << blue_bits); ncolors = (1 << (red_bits+green_bits+blue_bits)); if (ncolors > 0x100) ncolors = 0x100; memset(&gXPmTarget, 0, sizeof(struct XPmRec)); gXPmTarget.ncolors = ncolors; gXPmTarget.userdata = (void*)CMDID_DEFAULTERRORDIFFUSE; AllocTargetColors(ncolors); i = 0; for (red=0; red < red_levels; red++) { int red_intensity=GetIntensity(red, red_levels-1), green; for (green=0; green < green_levels; green++) { int green_intensity=GetIntensity(green, green_levels-1), blue; for (blue=0; blue < blue_levels; blue++) { int blue_intensity=GetIntensity(blue, blue_levels-1); gTargetColors[i].red = red_intensity; gTargetColors[i].green = green_intensity; gTargetColors[i].blue = blue_intensity; i++; } } } if (DoPpm6(xpm_ptr)) { rc = TRUE; } else { rc = MapTargetColors(xpm_ptr); } if (rc) { gnUserSpecifiedLevels = ncolors; gpConvolveFunc = (NLFN*)ConvolveToReduceToPixmapColors; gpConvolveCmdID = CMDID_DEFAULTERRORDIFFUSE; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); gnUserSpecifiedLevels = (-1); } FreeTargetColors(); memset(&gXPmTarget, 0, sizeof(struct XPmRec)); if (gnObjectColorsToTargetColorMapping != NULL) { free(gnObjectColorsToTargetColorMapping); gnObjectColorsToTargetColorMapping = NULL; } if (gnTgifColorsToObjectColorMapping != NULL) { free(gnTgifColorsToObjectColorMapping); gnTgifColorsToObjectColorMapping = NULL; } } /* ----------------------- DefaultErrorDiffuse ----------------------- */ void DefaultErrorDiffuse() { int i, red, rc, ncolors, image_h; int red_bits, green_bits, blue_bits, red_levels, green_levels, blue_levels; struct XPmRec *xpm_ptr=NULL; if (!CheckSelectionForImageProc(CMDID_DEFAULTERRORDIFFUSE)) { return; } xpm_ptr = topSel->obj->detail.xpm; image_h = xpm_ptr->image_h; red_bits = gDefErrorDiffuseLevel.red; green_bits = gDefErrorDiffuseLevel.green; blue_bits = gDefErrorDiffuseLevel.blue; sprintf(gszMsgBox, TgLoadString(STID_RGB_LEVELS_ARE), red_bits, green_bits, blue_bits); Msg(gszMsgBox); red_levels = (1 << red_bits); green_levels = (1 << green_bits); blue_levels = (1 << blue_bits); ncolors = (1 << (red_bits+green_bits+blue_bits)); if (ncolors > 0x100) ncolors = 0x100; memset(&gXPmTarget, 0, sizeof(struct XPmRec)); gXPmTarget.ncolors = ncolors; gXPmTarget.userdata = (void*)CMDID_DEFAULTERRORDIFFUSE; gnFloyd = TRUE; AllocTargetColors(ncolors); i = 0; for (red=0; red < red_levels; red++) { int red_intensity=GetIntensity(red, red_levels-1), green; for (green=0; green < green_levels; green++) { int green_intensity=GetIntensity(green, green_levels-1), blue; for (blue=0; blue < blue_levels; blue++) { int blue_intensity=GetIntensity(blue, blue_levels-1); gTargetColors[i].red = red_intensity; gTargetColors[i].green = green_intensity; gTargetColors[i].blue = blue_intensity; i++; } } } if (DoPpm6(xpm_ptr)) { if (!InitTrueColorInfo(xpm_ptr->image, &gTrueColorInfo, xpm_ptr->image_w)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), xpm_ptr->image_w, xpm_ptr->image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } rc = PrepareForErrorDiffuse(xpm_ptr); CleanUpIndexOfPixel(); if (gpTargetImage != NULL) XDestroyImage(gpTargetImage); if (gpTargetBitmapImage != NULL) XDestroyImage(gpTargetBitmapImage); gpTargetImage = gpTargetBitmapImage = NULL; if (rc) { gnUserSpecifiedLevels = ncolors; gpConvolveFunc = (NLFN*)ConvolveToErrorDiffuse; gpConvolveCmdID = CMDID_DEFAULTERRORDIFFUSE; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); gnUserSpecifiedLevels = (-1); } FreeTargetColors(); if (gnImageTargetColor != NULL) { for (i=0; i < image_h; i++) free(gnImageTargetColor[i]); free(gnImageTargetColor); gnImageTargetColor = NULL; } gnFloyd = FALSE; memset(&gXPmTarget, 0, sizeof(struct XPmRec)); } /* ----------------------- Spread ----------------------- */ static int gnAmountToSpread=0; static int **gnSpreadImageIndex=NULL; static int ConvolveToSpread(x, y) int x, y; { if (gConvExtraInfo.fp != NULL) { XColor **xcolors=gConvExtraInfo.xcolors; FILE *fp=gConvExtraInfo.fp; int w=gConvExtraInfo.image_w, h=gConvExtraInfo.image_h; unsigned char buf[3]; if (x == 0 && y == 0) { int r=0; srand(0); for (r=0; r < h; r++) { int c=0; for (c=0; c < w; c++) { int dx=(rand() % gnAmountToSpread) - (gnAmountToSpread>>1); int dy=(rand() % gnAmountToSpread) - (gnAmountToSpread>>1); int tmp_y=r+dy, tmp_x=c+dx; if (tmp_x >= 0 && tmp_x < w && tmp_y >= 0 && tmp_y < h) { XColor tmp_xcolor; memcpy(&tmp_xcolor, &xcolors[r][c], sizeof(XColor)); memcpy(&xcolors[r][c], &xcolors[tmp_y][tmp_x], sizeof(XColor)); memcpy(&xcolors[tmp_y][tmp_x], &tmp_xcolor, sizeof(XColor)); } } } } buf[0] = (unsigned char)xcolors[y][x].red; buf[1] = (unsigned char)xcolors[y][x].green; buf[2] = (unsigned char)xcolors[y][x].blue; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; return TRUE; } else { return GetOrAllocHistogramIndex(&tgifColors[gnSpreadImageIndex[y][x]]); } } static void CleanUpSpreadData() { int i, image_h=topSel->obj->detail.xpm->image_h; if (gnSpreadImageIndex != NULL) { for (i=0; i < image_h; i++) free(gnSpreadImageIndex[i]); free(gnSpreadImageIndex); gnSpreadImageIndex = NULL; } } static int ComputeSpreadData() { struct XPmRec *xpm_ptr=topSel->obj->detail.xpm; int i, image_w=xpm_ptr->image_w, image_h=xpm_ptr->image_h; ProgressInfo pi; Pixmap pixmap=xpm_ptr->pixmap; XImage *image=XGetImage(mainDisplay, pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (image == NULL) { FailAllocMessage(); return FALSE; } if (!CreatePixelToIndexMapping()) { XDestroyImage(image); return FALSE; } gnSpreadImageIndex = (int**)malloc(image_h*sizeof(int*)); if (gnSpreadImageIndex == NULL) { FailAllocMessage(); XDestroyImage(image); CleanUpIndexOfPixel(); return FALSE; } gnAmountToSpread++; BeginProgress(&pi, image_h); for (i=0; i < image_h; i++) { int j; UpdateProgress(&pi, i); gnSpreadImageIndex[i] = (int*)malloc(image_w*sizeof(int)); if (gnSpreadImageIndex[i] == NULL) { FailAllocMessage(); for (j=0; j < i; j++) free(gnSpreadImageIndex[j]); free(gnSpreadImageIndex); gnSpreadImageIndex = NULL; XDestroyImage(image); CleanUpIndexOfPixel(); return FALSE; } for (j=0; j < image_w; j++) { gnSpreadImageIndex[i][j] = GetIndexOfPixel(XGetPixel(image,j,i)); } } BeginProgress(&pi, image_h); srand(0); for (i=0; i < image_h; i++) { int j; UpdateProgress(&pi, i); for (j=0; j < image_w; j++) { int dx=(rand() % gnAmountToSpread) - (gnAmountToSpread>>1); int dy=(rand() % gnAmountToSpread) - (gnAmountToSpread>>1); int y=i+dy, x=j+dx, tmp_index; if (x >= 0 && x < image_w && y >= 0 && y < image_h) { tmp_index = gnSpreadImageIndex[i][j]; gnSpreadImageIndex[i][j] = gnSpreadImageIndex[y][x]; gnSpreadImageIndex[y][x] = tmp_index; } } } XDestroyImage(image); CleanUpIndexOfPixel(); return TRUE; } void Spread() { char *c_ptr=NULL, szSpec[MAXSTRING+1], szSpecCopy[MAXSTRING+1]; if (!CheckSelectionForImageProc(CMDID_SPREAD)) { return; } *szSpec = '\0'; Dialog(TgLoadString(STID_ENTER_INT_AMT_TO_SPREAD), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') return; strcpy(szSpecCopy, szSpec); if ((c_ptr=strtok(szSpec, " ,\t\n\r")) == NULL) return; gnAmountToSpread = atoi(c_ptr); if (gnAmountToSpread <= 0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC), szSpecCopy); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (!DoPpm6(topSel->obj->detail.xpm)) { if (!ComputeSpreadData()) { return; } } gpConvolveFunc = (NLFN*)ConvolveToSpread; gpConvolveCmdID = CMDID_SPREAD; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); CleanUpSpreadData(); } /* ----------------------- Sharpen ----------------------- */ static int ConvolveToSharpen(x, y) int x, y; /* * [ 0 -1 0 ] * [ -1 5 -1 ] * [ 0 -1 0 ] */ { if (gConvExtraInfo.fp != NULL) { XColor **xcolors=gConvExtraInfo.xcolors; FILE *fp=gConvExtraInfo.fp; int w=gConvExtraInfo.image_w, h=gConvExtraInfo.image_h; unsigned char buf[3]; if (x == 0 || x == w-1 || y == 0 || y == h-1) { buf[0] = (unsigned char)xcolors[y][x].red; buf[1] = (unsigned char)xcolors[y][x].green; buf[2] = (unsigned char)xcolors[y][x].blue; } else { int r=0, g=0, b=0; r = (int)( (((int)xcolors[y][x].red)<<3) - ((int)xcolors[y][x-1].red) - ((int)xcolors[y][x+1].red) - ((int)xcolors[y-1][x].red) - ((int)xcolors[y+1][x].red)); g = (int)( (((int)xcolors[y][x].green)<<3) - ((int)xcolors[y][x-1].green) - ((int)xcolors[y][x+1].green) - ((int)xcolors[y-1][x].green) - ((int)xcolors[y+1][x].green)); b = (int)( (((int)xcolors[y][x].blue)<<3) - ((int)xcolors[y][x-1].blue) - ((int)xcolors[y][x+1].blue) - ((int)xcolors[y-1][x].blue) - ((int)xcolors[y+1][x].blue)); r >>= 2; g >>= 2; b >>= 2; if (r < 0) r = 0; if (g < 0) g = 0; if (b < 0) b = 0; if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)(unsigned int)r; buf[1] = (unsigned char)(unsigned int)g; buf[2] = (unsigned char)(unsigned int)b; } if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; return TRUE; } else { register long red, green, blue; XColor xcolor, *color_ptr; if (x == 0 || x == gnImageW-1 || y == 0 || y == gnImageH-1) { return GetOrAllocHistogramIndex(&tgifColors[gnOrigImageIndex[y][x]]); } color_ptr = (&tgifColors[gnOrigImageIndex[y][x]]); red = ((long)color_ptr->red) << 3; green = ((long)color_ptr->green) << 3; blue = ((long)color_ptr->blue) << 3; color_ptr = (&tgifColors[gnOrigImageIndex[y][x-1]]); red -= ((long)color_ptr->red); green -= ((long)color_ptr->green); blue -= ((long)color_ptr->blue); color_ptr = (&tgifColors[gnOrigImageIndex[y][x+1]]); red -= ((long)color_ptr->red); green -= ((long)color_ptr->green); blue -= ((long)color_ptr->blue); color_ptr = (&tgifColors[gnOrigImageIndex[y-1][x]]); red -= ((long)color_ptr->red); green -= ((long)color_ptr->green); blue -= ((long)color_ptr->blue); color_ptr = (&tgifColors[gnOrigImageIndex[y+1][x]]); red = (red - ((long)color_ptr->red)) >> 2; green = (green - ((long)color_ptr->green)) >> 2; blue = (blue - ((long)color_ptr->blue)) >> 2; memset(&xcolor, 0, sizeof(XColor)); xcolor.red = (red > 0L ? (red > 0x0000ffff ? 0x0ffff : (unsigned int)(red&0xffff)) : 0); xcolor.green = (green > 0L ? (green > 0x0000ffff ? 0x0ffff : (unsigned int)(green&0xffff)) : 0); xcolor.blue = (blue > 0L ? (blue > 0x0000ffff ? 0x0ffff : (unsigned int)(blue&0xffff)) : 0); return GetOrAllocHistogramIndex(&xcolor); } } void Sharpen() { if (!CheckSelectionForImageProc(CMDID_SHARPEN)) return; if (topSel->obj->detail.xpm->image_w < 2 || topSel->obj->detail.xpm->image_h < 2) { MsgBox(TgLoadString(STID_SEL_TOO_THIN_FLAT_FOR_SHARPEN), TOOL_NAME, INFO_MB); return; } gpConvolveFunc = (NLFN*)ConvolveToSharpen; gpConvolveCmdID = CMDID_SHARPEN; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); } /* ----------------------- Blur3, Blur5, Blur7 ----------------------- */ static int gnBlurSize=1; static int ConvolveToBlur(x, y) int x, y; /* * [ 1/25 1/25 1/25 ] * [ 1/9 1/9 1/9 ] [ 1/25 1/25 1/25 ] * [ 1/9 1/9 1/9 ] [ 1/25 1/25 1/25 ] ... * [ 1/9 1/9 1/9 ] [ 1/25 1/25 1/25 ] * [ 1/25 1/25 1/25 ] */ { if (gConvExtraInfo.fp != NULL) { XColor **xcolors=gConvExtraInfo.xcolors; FILE *fp=gConvExtraInfo.fp; int w=gConvExtraInfo.image_w, h=gConvExtraInfo.image_h; unsigned char buf[3]; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; int x_index=0, num_cells=0; for (x_index=x-gnBlurSize; x_index <= x+gnBlurSize; x_index++) { int y_index=0; if (x_index >= 0 && x_index < w) { for (y_index=y-gnBlurSize; y_index <= y+gnBlurSize; y_index++) { if (y_index >= 0 && y_index < h) { r += ((int)xcolors[y_index][x_index].red); g += ((int)xcolors[y_index][x_index].green); b += ((int)xcolors[y_index][x_index].blue); num_cells++; } } } } dr = ((double)r) / ((double)num_cells); dg = ((double)g) / ((double)num_cells); db = ((double)b) / ((double)num_cells); r = (unsigned int)round(dr); g = (unsigned int)round(dg); b = (unsigned int)round(db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; return TRUE; } else { register long red=0L, green=0L, blue=0L; XColor xcolor; int x_index, array_size=((gnBlurSize<<1)+1); if (x < gnBlurSize || x >= gnImageW-gnBlurSize || y < gnBlurSize || y >= gnImageH-gnBlurSize) { return GetOrAllocHistogramIndex(&tgifColors[gnOrigImageIndex[y][x]]); } for (x_index=x-gnBlurSize; x_index <= x+gnBlurSize; x_index++) { int y_index; for (y_index=y-gnBlurSize; y_index <= y+gnBlurSize; y_index++) { register XColor *color_ptr; color_ptr = (&tgifColors[gnOrigImageIndex[y_index][x_index]]); red += ((long)color_ptr->red); green += ((long)color_ptr->green); blue += ((long)color_ptr->blue); } } array_size *= array_size; red /= array_size; green /= array_size; blue /= array_size; memset(&xcolor, 0, sizeof(XColor)); xcolor.red = (red > 0L ? (red > 0x0000ffff ? 0x0ffff : (unsigned int)(red&0xffff)) : 0); xcolor.green = (green > 0L ? (green > 0x0000ffff ? 0x0ffff : (unsigned int)(green&0xffff)) : 0); xcolor.blue = (blue > 0L ? (blue > 0x0000ffff ? 0x0ffff : (unsigned int)(blue&0xffff)) : 0); return GetOrAllocHistogramIndex(&xcolor); } } static void Blur(nSize) int nSize; { int cmdid=CMDID_BLUR3; switch (nSize) { case 3: cmdid=CMDID_BLUR3; break; case 5: cmdid=CMDID_BLUR5; break; case 7: cmdid=CMDID_BLUR7; break; } gnBlurSize = ((nSize-1)>>1); if (!CheckSelectionForImageProc(cmdid)) return; if (topSel->obj->detail.xpm->image_w <= gnBlurSize || topSel->obj->detail.xpm->image_h <= gnBlurSize) { sprintf(gszMsgBox, TgLoadString(STID_SEL_TOO_THIN_FLAT_FOR_BLUR), nSize, nSize); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } gpConvolveFunc = (NLFN*)ConvolveToBlur; gpConvolveCmdID = CMDID_BLUR3; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); } void Blur3() { Blur(3); } void Blur5() { Blur(5); } void Blur7() { Blur(7); } /* ----------------------- AlphaCombine ----------------------- */ static int PointInRect(x, y, p_bbox) int x, y; struct BBRec *p_bbox; { return (x>=p_bbox->ltx && y>=p_bbox->lty && x<p_bbox->rbx && y<p_bbox->rby); } #define INSIDE_NONE 0x0 #define INSIDE_FG 0x1 #define INSIDE_BG 0x2 #define INSIDE_ALPHA 0x4 static int ConvolveToAlphaCombine(x, y) int x, y; { XColor fg_xcolor, bg_xcolor, alpha_xcolor, xcolor; int inside_flag=INSIDE_NONE, pixel; double alpha=(double)0, beta=(double)0; long red=0L, green=0L, blue=0L; if (PointInRect(x, y, &gAlphaCombineBBox)) inside_flag |= INSIDE_ALPHA; if (PointInRect(x, y, &gFgCombineBBox)) inside_flag |= INSIDE_FG; if (PointInRect(x, y, &gBgCombineBBox)) inside_flag |= INSIDE_BG; if (gConvExtraInfo.fp != NULL) { FILE *fp=gConvExtraInfo.fp; XColor **xcolors=NULL; int image_x=0, image_y=0; unsigned int r=0, g=0, b=0; unsigned char buf[3]; switch (inside_flag) { case 0x0: case 0x4: /* INSIDE_ALPHA */ buf[0] = (unsigned char)gConvExtraInfo.my_bg_xcolor.red; buf[1] = (unsigned char)gConvExtraInfo.my_bg_xcolor.green; buf[2] = (unsigned char)gConvExtraInfo.my_bg_xcolor.blue; break; case 0x1: /* INSIDE_FG */ case 0x3: /* INSIDE_BG | INSIDE_FG */ case 0x5: /* INSIDE_ALPHA | INSIDE_FG */ xcolors = gConvExtraInfo.xcolors; image_x = x-gFgCombineBBox.ltx; image_y = y-gFgCombineBBox.lty; buf[0] = (unsigned char)xcolors[image_y][image_x].red; buf[1] = (unsigned char)xcolors[image_y][image_x].green; buf[2] = (unsigned char)xcolors[image_y][image_x].blue; break; case 0x2: /* INSIDE_BG */ case 0x6: /* INSIDE_ALPHA | INSIDE_BG */ xcolors = gConvExtraInfo.bg_xcolors; image_x = x-gBgCombineBBox.ltx; image_y = y-gBgCombineBBox.lty; buf[0] = (unsigned char)xcolors[image_y][image_x].red; buf[1] = (unsigned char)xcolors[image_y][image_x].green; buf[2] = (unsigned char)xcolors[image_y][image_x].blue; break; case 0x7: /* INSIDE_ALPHA | INSIDE_BG | INSIDE_FG */ xcolors = gConvExtraInfo.xcolors; image_x = x-gFgCombineBBox.ltx; image_y = y-gFgCombineBBox.lty; memcpy(&fg_xcolor, &xcolors[image_y][image_x], sizeof(XColor)); xcolors = gConvExtraInfo.bg_xcolors; image_x = x-gBgCombineBBox.ltx; image_y = y-gBgCombineBBox.lty; memcpy(&bg_xcolor, &xcolors[image_y][image_x], sizeof(XColor)); xcolors = gConvExtraInfo.alpha_xcolors; image_x = x-gAlphaCombineBBox.ltx; image_y = y-gAlphaCombineBBox.lty; memcpy(&alpha_xcolor, &xcolors[image_y][image_x], sizeof(XColor)); alpha = (0.299*((double)alpha_xcolor.red) + 0.587*((double)alpha_xcolor.green) + 0.114*((double)alpha_xcolor.blue)) / 255.0; beta = ((double)1) - alpha; r = ((double)(fg_xcolor.red)) * alpha + ((double)(bg_xcolor.red)) * beta; g = ((double)(fg_xcolor.green)) * alpha + ((double)(bg_xcolor.green)) * beta; b = ((double)(fg_xcolor.blue)) * alpha + ((double)(bg_xcolor.blue)) * beta; if (r < 0) r = 0; if (g < 0) g = 0; if (b < 0) b = 0; if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; break; } if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; return TRUE; } else { switch (inside_flag) { case 0x0: case 0x4: /* INSIDE_ALPHA */ if (myFileBgColorStr == NULL) { return GetOrAllocHistogramIndex(&myBgColor); } else { return GetOrAllocHistogramIndex(&myFileBgColor); } case 0x1: case 0x3: /* INSIDE_BG | INSIDE_FG */ case 0x5: /* INSIDE_ALPHA | INSIDE_FG */ /* INSIDE_FG */ pixel = XGetPixel(gpFgImage, x-gFgCombineBBox.ltx, y-gFgCombineBBox.lty); return GetOrAllocHistogramIndex(&tgifColors[GetIndexOfPixel(pixel)]); case 0x2: /* INSIDE_BG */ case 0x6: /* INSIDE_ALPHA | INSIDE_BG */ pixel = XGetPixel(gpBgImage, x-gBgCombineBBox.ltx, y-gBgCombineBBox.lty); return GetOrAllocHistogramIndex(&tgifColors[GetIndexOfPixel(pixel)]); case 0x7: /* INSIDE_ALPHA | INSIDE_BG | INSIDE_FG */ pixel = XGetPixel(gpFgImage, x-gFgCombineBBox.ltx, y-gFgCombineBBox.lty); memcpy(&fg_xcolor, &tgifColors[GetIndexOfPixel(pixel)], sizeof(XColor)); pixel = XGetPixel(gpBgImage, x-gBgCombineBBox.ltx, y-gBgCombineBBox.lty); memcpy(&bg_xcolor, &tgifColors[GetIndexOfPixel(pixel)], sizeof(XColor)); pixel = XGetPixel(gpAlphaImage, x-gAlphaCombineBBox.ltx, y-gAlphaCombineBBox.lty); memcpy(&alpha_xcolor, &tgifColors[GetIndexOfPixel(pixel)], sizeof(XColor)); alpha = ((double)(0.299*((double)alpha_xcolor.red) + 0.587*((double)alpha_xcolor.green) + 0.114*((double)alpha_xcolor.blue))) / 65536.0; beta = 1.0 - alpha; red = (long)(((double)fg_xcolor.red)*alpha + ((double)bg_xcolor.red)*beta); green = (long)(((double)fg_xcolor.green)*alpha + ((double)bg_xcolor.green)*beta); blue = (long)(((double)fg_xcolor.blue)*alpha + ((double)bg_xcolor.blue)*beta); break; } memset(&xcolor, 0, sizeof(XColor)); xcolor.red = (red > 0L ? (red > 0x0000ffff ? 0x0ffff : (unsigned int)(red&0xffff)) : 0); xcolor.green = (green > 0L ? (green > 0x0000ffff ? 0x0ffff : (unsigned int)(green&0xffff)) : 0); xcolor.blue = (blue > 0L ? (blue > 0x0000ffff ? 0x0ffff : (unsigned int)(blue&0xffff)) : 0); return GetOrAllocHistogramIndex(&xcolor); } } static void OffsetRect(p_bbox, dx, dy) struct BBRec *p_bbox; int dx, dy; { p_bbox->ltx += dx; p_bbox->lty += dy; p_bbox->rbx += dx; p_bbox->rby += dy; } static void CleanUpAlphaCombine() { if (gpFgImage != NULL) XDestroyImage(gpFgImage); if (gpBgImage != NULL) XDestroyImage(gpBgImage); if (gpAlphaImage != NULL) XDestroyImage(gpAlphaImage); if (gpFgBitmapImage != NULL) XDestroyImage(gpFgBitmapImage); if (gpBgBitmapImage != NULL) XDestroyImage(gpBgBitmapImage); if (gpAlphaBitmapImage != NULL) XDestroyImage(gpAlphaBitmapImage); gpFgImage = gpBgImage = gpAlphaImage = gpFgBitmapImage = gpBgBitmapImage = gpAlphaBitmapImage = NULL; gpFgObj = gpBgObj = gpAlphaObj = NULL; } static int PrepareForAlphaCombine() { memcpy(&gFgCombineBBox, &gpFgObj->obbox, sizeof(struct BBRec)); memcpy(&gBgCombineBBox, &gpBgObj->obbox, sizeof(struct BBRec)); if (gpAlphaObj != NULL) { memcpy(&gAlphaCombineBBox, &gpAlphaObj->obbox, sizeof(struct BBRec)); } UnionRect(&gFgCombineBBox, &gBgCombineBBox, &gTotalCombineBBox); if (gpAlphaObj != NULL) { UnionRect(&gAlphaCombineBBox, &gTotalCombineBBox, &gTotalCombineBBox); } gnCombineW = gTotalCombineBBox.rbx - gTotalCombineBBox.ltx; gnCombineH = gTotalCombineBBox.rby - gTotalCombineBBox.lty; OffsetRect(&gFgCombineBBox, -gTotalCombineBBox.ltx, -gTotalCombineBBox.lty); OffsetRect(&gBgCombineBBox, -gTotalCombineBBox.ltx, -gTotalCombineBBox.lty); if (gpAlphaObj != NULL) { OffsetRect(&gAlphaCombineBBox, -gTotalCombineBBox.ltx, -gTotalCombineBBox.lty); } gpAlphaImage = gpAlphaBitmapImage = NULL; if (!GetXPmImages(gpFgObj->detail.xpm, &gpFgImage, &gpFgBitmapImage) || !GetXPmImages(gpBgObj->detail.xpm, &gpBgImage, &gpBgBitmapImage) || (gpAlphaObj != NULL && !GetXPmImages(gpAlphaObj->detail.xpm, &gpAlphaImage, &gpAlphaBitmapImage))) { return FALSE; } return TRUE; } void AlphaCombine() { char szBuf[MAXSTRING+1]; int num_objs=0; strcpy(szBuf, GetImageProcName(CMDID_ALPHACOMBINE)); gpFgObj = gpBgObj = gpAlphaObj = NULL; if (curChoice == NOTHING && numObjSelected == 3) { struct SelRec *sel_ptr; struct ObjRec *obj_ptr; int ok=TRUE; for (obj_ptr=topObj; ok && obj_ptr != NULL; obj_ptr=obj_ptr->next) { for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (obj_ptr == sel_ptr->obj) { if (obj_ptr->type == OBJ_XPM) { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; int image_w=obj_ptr->obbox.rbx-obj_ptr->obbox.ltx; int image_h=obj_ptr->obbox.rby-obj_ptr->obbox.lty; if (obj_ptr->ctm != NULL || xpm_ptr->image_w != image_w || xpm_ptr->image_h != image_h) { char szBuf1[MAXSTRING+1]; strcpy(szBuf1, GetImageProcName(CMDID_REGENERATEIMAGE)); sprintf(gszMsgBox, TgLoadString(STID_IMAGE_PROC_CANT_USE_XFORMED), szBuf, szBuf1); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } switch (num_objs++) { case 0: gpFgObj = obj_ptr; break; case 1: gpAlphaObj = obj_ptr; break; case 2: gpBgObj = obj_ptr; break; } } else { ok = FALSE; break; } } } } if (!ok) num_objs = 0; } if (num_objs != 3) { sprintf(gszMsgBox, TgLoadString(STID_SEL_3_XPM_FOR_IMAGEPROC_CMD), szBuf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (PrepareForAlphaCombine()) { gnCombining = TRUE; gpConvolveFunc = (NLFN*)ConvolveToAlphaCombine; gpConvolveCmdID = CMDID_ALPHACOMBINE; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); gnCombining = FALSE; } CleanUpAlphaCombine(); } /* ----------------------- Subtract ----------------------- */ static int ConvolveToSubtract(x, y) int x, y; { XColor fg_xcolor, bg_xcolor, xcolor; int inside_flag=INSIDE_NONE, pixel; long red=0L, green=0L, blue=0L; if (PointInRect(x, y, &gFgCombineBBox)) inside_flag |= INSIDE_FG; if (PointInRect(x, y, &gBgCombineBBox)) inside_flag |= INSIDE_BG; if (gConvExtraInfo.fp != NULL) { FILE *fp=gConvExtraInfo.fp; XColor **xcolors=NULL; int r=0, g=0, b=0, image_x=0, image_y=0; unsigned char buf[3]; switch (inside_flag) { case 0x0: buf[0] = (unsigned char)gConvExtraInfo.my_bg_xcolor.red; buf[1] = (unsigned char)gConvExtraInfo.my_bg_xcolor.green; buf[2] = (unsigned char)gConvExtraInfo.my_bg_xcolor.blue; break; case 0x1: /* INSIDE_FG */ xcolors = gConvExtraInfo.xcolors; image_x = x-gFgCombineBBox.ltx; image_y = y-gFgCombineBBox.lty; buf[0] = (unsigned char)xcolors[image_y][image_x].red; buf[1] = (unsigned char)xcolors[image_y][image_x].green; buf[2] = (unsigned char)xcolors[image_y][image_x].blue; break; case 0x2: /* INSIDE_BG */ xcolors = gConvExtraInfo.bg_xcolors; image_x = x-gBgCombineBBox.ltx; image_y = y-gBgCombineBBox.lty; buf[0] = (unsigned char)xcolors[image_y][image_x].red; buf[1] = (unsigned char)xcolors[image_y][image_x].green; buf[2] = (unsigned char)xcolors[image_y][image_x].blue; break; case 0x3: /* INSIDE_BG | INSIDE_FG */ xcolors = gConvExtraInfo.xcolors; image_x = x-gFgCombineBBox.ltx; image_y = y-gFgCombineBBox.lty; memcpy(&fg_xcolor, &xcolors[image_y][image_x], sizeof(XColor)); xcolors = gConvExtraInfo.bg_xcolors; image_x = x-gBgCombineBBox.ltx; image_y = y-gBgCombineBBox.lty; memcpy(&bg_xcolor, &xcolors[image_y][image_x], sizeof(XColor)); r = ((int)fg_xcolor.red) - ((int)bg_xcolor.red); g = ((int)fg_xcolor.green) - ((int)bg_xcolor.green); b = ((int)fg_xcolor.blue) - ((int)bg_xcolor.blue); if (r < 0) r = 0; if (g < 0) g = 0; if (b < 0) b = 0; if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; break; } if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; return TRUE; } else { switch (inside_flag) { case 0x0: if (myFileBgColorStr == NULL) { return GetOrAllocHistogramIndex(&myBgColor); } else { return GetOrAllocHistogramIndex(&myFileBgColor); } case 0x1: /* INSIDE_FG */ pixel = XGetPixel(gpFgImage, x-gFgCombineBBox.ltx, y-gFgCombineBBox.lty); memcpy(&fg_xcolor, &tgifColors[GetIndexOfPixel(pixel)], sizeof(XColor)); red = (long)fg_xcolor.red; green = (long)fg_xcolor.green; blue = (long)fg_xcolor.blue; break; case 0x2: /* INSIDE_BG */ pixel = XGetPixel(gpBgImage, x-gBgCombineBBox.ltx, y-gBgCombineBBox.lty); memcpy(&bg_xcolor, &tgifColors[GetIndexOfPixel(pixel)], sizeof(XColor)); red = (long)bg_xcolor.red; green = (long)bg_xcolor.green; blue = (long)bg_xcolor.blue; break; case 0x3: /* INSIDE_BG | INSIDE_FG */ pixel = XGetPixel(gpFgImage, x-gFgCombineBBox.ltx, y-gFgCombineBBox.lty); memcpy(&fg_xcolor, &tgifColors[GetIndexOfPixel(pixel)], sizeof(XColor)); pixel = XGetPixel(gpBgImage, x-gBgCombineBBox.ltx, y-gBgCombineBBox.lty); memcpy(&bg_xcolor, &tgifColors[GetIndexOfPixel(pixel)], sizeof(XColor)); red = ((long)fg_xcolor.red) - ((long)bg_xcolor.red); green = ((long)fg_xcolor.green) - ((long)bg_xcolor.green); blue = ((long)fg_xcolor.blue) - ((long)bg_xcolor.blue); break; } memset(&xcolor, 0, sizeof(XColor)); xcolor.red = (red > 0L ? (red > 0x0000ffff ? 0x0ffff : (unsigned int)(red&0xffff)) : 0); xcolor.green = (green > 0L ? (green > 0x0000ffff ? 0x0ffff : (unsigned int)(green&0xffff)) : 0); xcolor.blue = (blue > 0L ? (blue > 0x0000ffff ? 0x0ffff : (unsigned int)(blue&0xffff)) : 0); return GetOrAllocHistogramIndex(&xcolor); } } void Subtract() { char szBuf[MAXSTRING+1]; int num_objs=0; strcpy(szBuf, GetImageProcName(CMDID_SUBTRACT)); gpFgObj = gpBgObj = gpAlphaObj = NULL; if (curChoice == NOTHING && numObjSelected == 2) { struct SelRec *sel_ptr; struct ObjRec *obj_ptr; int ok=TRUE; for (obj_ptr=topObj; ok && obj_ptr != NULL; obj_ptr=obj_ptr->next) { for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (obj_ptr == sel_ptr->obj) { if (obj_ptr->type == OBJ_XPM) { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; int image_w=obj_ptr->obbox.rbx-obj_ptr->obbox.ltx; int image_h=obj_ptr->obbox.rby-obj_ptr->obbox.lty; if (obj_ptr->ctm != NULL || xpm_ptr->image_w != image_w || xpm_ptr->image_h != image_h) { char szBuf1[MAXSTRING+1]; strcpy(szBuf1, GetImageProcName(CMDID_REGENERATEIMAGE)); sprintf(gszMsgBox, TgLoadString(STID_IMAGE_PROC_CANT_USE_XFORMED), szBuf, szBuf1); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } switch (num_objs++) { case 0: gpFgObj = obj_ptr; break; case 1: gpBgObj = obj_ptr; break; } } else { ok = FALSE; break; } } } } if (!ok) num_objs = 0; } if (num_objs != 2) { sprintf(gszMsgBox, TgLoadString(STID_SEL_2_XPM_FOR_IMAGEPROC_CMD), szBuf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (PrepareForAlphaCombine()) { gnCombining = TRUE; gpConvolveFunc = (NLFN*)ConvolveToSubtract; gpConvolveCmdID = CMDID_SUBTRACT; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); gnCombining = FALSE; } CleanUpAlphaCombine(); } /* ----------------------- XorColors ----------------------- */ static int ConvolveToXorColors(x, y) int x, y; { XColor fg_xcolor, bg_xcolor, xcolor; int inside_flag=INSIDE_NONE, pixel=0; memset(&xcolor, 0, sizeof(XColor)); if (PointInRect(x, y, &gFgCombineBBox)) inside_flag |= INSIDE_FG; if (PointInRect(x, y, &gBgCombineBBox)) inside_flag |= INSIDE_BG; if (gConvExtraInfo.fp != NULL) { FILE *fp=gConvExtraInfo.fp; XColor **xcolors=NULL; int image_x=0, image_y=0; unsigned int r=0, g=0, b=0; unsigned char buf[3]; switch (inside_flag) { case 0x0: buf[0] = (unsigned char)gConvExtraInfo.my_bg_xcolor.red; buf[1] = (unsigned char)gConvExtraInfo.my_bg_xcolor.green; buf[2] = (unsigned char)gConvExtraInfo.my_bg_xcolor.blue; break; case 0x1: /* INSIDE_FG */ xcolors = gConvExtraInfo.xcolors; image_x = x-gFgCombineBBox.ltx; image_y = y-gFgCombineBBox.lty; buf[0] = (unsigned char)xcolors[image_y][image_x].red; buf[1] = (unsigned char)xcolors[image_y][image_x].green; buf[2] = (unsigned char)xcolors[image_y][image_x].blue; break; case 0x2: /* INSIDE_BG */ xcolors = gConvExtraInfo.bg_xcolors; image_x = x-gBgCombineBBox.ltx; image_y = y-gBgCombineBBox.lty; buf[0] = (unsigned char)xcolors[image_y][image_x].red; buf[1] = (unsigned char)xcolors[image_y][image_x].green; buf[2] = (unsigned char)xcolors[image_y][image_x].blue; break; case 0x3: /* INSIDE_BG | INSIDE_FG */ xcolors = gConvExtraInfo.xcolors; image_x = x-gFgCombineBBox.ltx; image_y = y-gFgCombineBBox.lty; memcpy(&fg_xcolor, &xcolors[image_y][image_x], sizeof(XColor)); xcolors = gConvExtraInfo.bg_xcolors; image_x = x-gBgCombineBBox.ltx; image_y = y-gBgCombineBBox.lty; memcpy(&bg_xcolor, &xcolors[image_y][image_x], sizeof(XColor)); r = (unsigned int)((fg_xcolor.red) ^ (bg_xcolor.red)); g = (unsigned int)((fg_xcolor.green) ^ (bg_xcolor.green)); b = (unsigned int)((fg_xcolor.blue) ^ (bg_xcolor.blue)); if (r < 0) r = 0; if (g < 0) g = 0; if (b < 0) b = 0; if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; buf[0] = (unsigned char)r; buf[1] = (unsigned char)g; buf[2] = (unsigned char)b; break; } if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; return TRUE; } else { switch (inside_flag) { case 0x0: if (myFileBgColorStr == NULL) { return GetOrAllocHistogramIndex(&myBgColor); } else { return GetOrAllocHistogramIndex(&myFileBgColor); } case 0x1: /* INSIDE_FG */ pixel = XGetPixel(gpFgImage, x-gFgCombineBBox.ltx, y-gFgCombineBBox.lty); memcpy(&fg_xcolor, &tgifColors[GetIndexOfPixel(pixel)], sizeof(XColor)); xcolor.red = fg_xcolor.red; xcolor.green = fg_xcolor.green; xcolor.blue = fg_xcolor.blue; break; case 0x2: /* INSIDE_BG */ pixel = XGetPixel(gpBgImage, x-gBgCombineBBox.ltx, y-gBgCombineBBox.lty); memcpy(&bg_xcolor, &tgifColors[GetIndexOfPixel(pixel)], sizeof(XColor)); xcolor.red = bg_xcolor.red; xcolor.green = bg_xcolor.green; xcolor.blue = bg_xcolor.blue; break; case 0x3: /* INSIDE_BG | INSIDE_FG */ pixel = XGetPixel(gpFgImage, x-gFgCombineBBox.ltx, y-gFgCombineBBox.lty); memcpy(&fg_xcolor, &tgifColors[GetIndexOfPixel(pixel)], sizeof(XColor)); pixel = XGetPixel(gpBgImage, x-gBgCombineBBox.ltx, y-gBgCombineBBox.lty); memcpy(&bg_xcolor, &tgifColors[GetIndexOfPixel(pixel)], sizeof(XColor)); xcolor.red = (fg_xcolor.red) ^ (bg_xcolor.red); xcolor.green = (fg_xcolor.green) ^ (bg_xcolor.green); xcolor.blue = (fg_xcolor.blue) ^ (bg_xcolor.blue); break; } return GetOrAllocHistogramIndex(&xcolor); } } void XorColors() { char szBuf[MAXSTRING+1]; int num_objs=0; strcpy(szBuf, GetImageProcName(CMDID_XORCOLORS)); gpFgObj = gpBgObj = gpAlphaObj = NULL; if (curChoice == NOTHING && numObjSelected == 2) { struct SelRec *sel_ptr; struct ObjRec *obj_ptr; int ok=TRUE; for (obj_ptr=topObj; ok && obj_ptr != NULL; obj_ptr=obj_ptr->next) { for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (obj_ptr == sel_ptr->obj) { if (obj_ptr->type == OBJ_XPM) { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; int image_w=obj_ptr->obbox.rbx-obj_ptr->obbox.ltx; int image_h=obj_ptr->obbox.rby-obj_ptr->obbox.lty; if (obj_ptr->ctm != NULL || xpm_ptr->image_w != image_w || xpm_ptr->image_h != image_h) { char szBuf1[MAXSTRING+1]; strcpy(szBuf1, GetImageProcName(CMDID_REGENERATEIMAGE)); sprintf(gszMsgBox, TgLoadString(STID_IMAGE_PROC_CANT_USE_XFORMED), szBuf, szBuf1); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } switch (num_objs++) { case 0: gpFgObj = obj_ptr; break; case 1: gpBgObj = obj_ptr; break; } } else { ok = FALSE; break; } } } } if (!ok) num_objs = 0; } if (num_objs != 2) { sprintf(gszMsgBox, TgLoadString(STID_SEL_2_XPM_FOR_IMAGEPROC_CMD), szBuf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } if (PrepareForAlphaCombine()) { gnCombining = TRUE; gpConvolveFunc = (NLFN*)ConvolveToXorColors; gpConvolveCmdID = CMDID_XORCOLORS; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); gnCombining = FALSE; } CleanUpAlphaCombine(); } /* ======================= Image Warping ======================= */ /* ----------------------- VectorWarp ----------------------- */ typedef struct RevWarpXformRec { /* * x = X + x_coef ( X + w - f(x)W ) ( Y + h - g(y)H ) * y = Y + y_coef ( X + w - f(x)W ) ( Y + h - g(y)H ) * * [ 00 | 10 ] * where f(x)g(y) = [ ---+--- ] * [ 01 | 11 ] * * X and Y are in the warped domain and x and y are in the original domain * * x_coef = -dw / ( ( w + dw - f(x)W ) ( h + dh - g(y)H ) ) * y_coef = -dh / ( ( w + dw - f(x)W ) ( h + dh - g(y)H ) ) * * Nevertheless, this structure is not used! */ double x_coef, y_coef; } RevWarpXform; static IntPoint gaTrapMapPt[5]; static TrapMapSeg gaTrapMapSeg[4]; static int gaTrapMapLeaf[4]; static TrapMapSpec gLeftTrapMapSpec[] = { /* * In-order specification of the trapezoidal map for Cx < Tx. */ { TRAP_NODE_PT, TRAP_PT_C }, { TRAP_NODE_SEG, TRAP_SEG_L }, { TRAP_NODE_LEAF, TRAP_LEAF_LT }, { TRAP_NODE_LEAF, TRAP_LEAF_LB }, { TRAP_NODE_PT, TRAP_PT_T }, { TRAP_NODE_SEG, TRAP_SEG_T }, { TRAP_NODE_LEAF, TRAP_LEAF_LT }, { TRAP_NODE_SEG, TRAP_SEG_R }, { TRAP_NODE_LEAF, TRAP_LEAF_RT }, { TRAP_NODE_SEG, TRAP_SEG_B }, { TRAP_NODE_LEAF, TRAP_LEAF_RB }, { TRAP_NODE_LEAF, TRAP_LEAF_LB }, { TRAP_NODE_SEG, TRAP_SEG_R }, { TRAP_NODE_LEAF, TRAP_LEAF_RT }, { TRAP_NODE_LEAF, TRAP_LEAF_RB }, { -1, -1 } }; static TrapMapSpec gRightTrapMapSpec[] = { /* * In-order specification of the trapezoidal map for Cx > Tx. */ { TRAP_NODE_PT, TRAP_PT_T }, { TRAP_NODE_SEG, TRAP_SEG_L }, { TRAP_NODE_LEAF, TRAP_LEAF_LT }, { TRAP_NODE_LEAF, TRAP_LEAF_LB }, { TRAP_NODE_PT, TRAP_PT_C }, { TRAP_NODE_SEG, TRAP_SEG_T }, { TRAP_NODE_LEAF, TRAP_LEAF_RT }, { TRAP_NODE_SEG, TRAP_SEG_L }, { TRAP_NODE_LEAF, TRAP_LEAF_LT }, { TRAP_NODE_SEG, TRAP_SEG_B }, { TRAP_NODE_LEAF, TRAP_LEAF_LB }, { TRAP_NODE_LEAF, TRAP_LEAF_RB }, { TRAP_NODE_SEG, TRAP_SEG_R }, { TRAP_NODE_LEAF, TRAP_LEAF_RT }, { TRAP_NODE_LEAF, TRAP_LEAF_RB }, { -1, -1 } }; static TrapMapSpec gCenterTrapMapSpec[] = { /* * In-order specification of the trapezoidal map for Cx == Tx. */ { TRAP_NODE_PT, TRAP_PT_T }, { TRAP_NODE_SEG, TRAP_SEG_L }, { TRAP_NODE_LEAF, TRAP_LEAF_LT }, { TRAP_NODE_LEAF, TRAP_LEAF_LB }, { TRAP_NODE_SEG, TRAP_SEG_R }, { TRAP_NODE_LEAF, TRAP_LEAF_RT }, { TRAP_NODE_LEAF, TRAP_LEAF_RB }, { -1, -1 } }; static TrapMap *gpTrapMap=NULL; static TrapMapSpec *gpTrapMapSpec=NULL; static int **gpSegYIntersects=NULL; static int **gpExtraYIntersects=NULL; static void CleanTrapMapNode(pTrapMapNode) TrapMap *pTrapMapNode; { switch (pTrapMapNode->type) { case TRAP_NODE_LEAF: break; case TRAP_NODE_PT: if (pTrapMapNode->detail.pt.left != NULL) { CleanTrapMapNode(pTrapMapNode->detail.pt.left); } if (pTrapMapNode->detail.pt.right != NULL) { CleanTrapMapNode(pTrapMapNode->detail.pt.right); } break; case TRAP_NODE_SEG: if (pTrapMapNode->detail.seg.above != NULL) { CleanTrapMapNode(pTrapMapNode->detail.seg.above); } if (pTrapMapNode->detail.seg.below != NULL) { CleanTrapMapNode(pTrapMapNode->detail.seg.below); } break; } free(pTrapMapNode); } static void CleanTrapMap() { if (gpTrapMap != NULL) { CleanTrapMapNode(gpTrapMap); } gpTrapMap = NULL; if (gpSegYIntersects != NULL) { int i; for (i=0; i < 4; i++) { if (gpSegYIntersects[i] != NULL) { free(gpSegYIntersects[i]); } } free(gpSegYIntersects); gpSegYIntersects = NULL; } if (gpExtraYIntersects != NULL) { int i; for (i=0; i < 4; i++) { if (gpExtraYIntersects[i] != NULL) { free(gpExtraYIntersects[i]); } } free(gpExtraYIntersects); gpExtraYIntersects = NULL; } } static int SetTrapMapLeaf(pTrapMapSpecRoot, pnIndex, pTrapMapNode, nWhich) TrapMapSpec *pTrapMapSpecRoot; int *pnIndex; TrapMap *pTrapMapNode; int nWhich; { pTrapMapNode->type = TRAP_NODE_LEAF; pTrapMapNode->detail.leaf.which = nWhich; pTrapMapNode->detail.leaf.data = (&gaTrapMapLeaf[nWhich]); return TRUE; } static int SetTrapMapPt(pTrapMapSpecRoot, pnIndex, pTrapMapNode, nWhich) TrapMapSpec *pTrapMapSpecRoot; int *pnIndex; TrapMap *pTrapMapNode; int nWhich; { pTrapMapNode->type = TRAP_NODE_PT; pTrapMapNode->detail.pt.which = nWhich; pTrapMapNode->detail.pt.data = (&gaTrapMapPt[nWhich]); pTrapMapNode->detail.pt.left = (TrapMap*)malloc(sizeof(TrapMap)); pTrapMapNode->detail.pt.right = (TrapMap*)malloc(sizeof(TrapMap)); if (pTrapMapNode->detail.pt.left == NULL || pTrapMapNode->detail.pt.right == NULL) { FailAllocMessage(); } memset(pTrapMapNode->detail.pt.left, 0, sizeof(TrapMap)); memset(pTrapMapNode->detail.pt.right, 0, sizeof(TrapMap)); (*pnIndex)++; if (!BuildTrapMapNode(pTrapMapSpecRoot, pnIndex, pTrapMapNode->detail.pt.left)) { return FALSE; } (*pnIndex)++; if (!BuildTrapMapNode(pTrapMapSpecRoot, pnIndex, pTrapMapNode->detail.pt.right)) { return FALSE; } return TRUE; } static int SetTrapMapSeg(pTrapMapSpecRoot, pnIndex, pTrapMapNode, nWhich) TrapMapSpec *pTrapMapSpecRoot; int *pnIndex; TrapMap *pTrapMapNode; int nWhich; { pTrapMapNode->type = TRAP_NODE_SEG; pTrapMapNode->detail.seg.which = nWhich; pTrapMapNode->detail.seg.data = (&gaTrapMapSeg[nWhich]); pTrapMapNode->detail.seg.above = (TrapMap*)malloc(sizeof(TrapMap)); pTrapMapNode->detail.seg.below = (TrapMap*)malloc(sizeof(TrapMap)); if (pTrapMapNode->detail.seg.above == NULL || pTrapMapNode->detail.seg.below == NULL) { FailAllocMessage(); } memset(pTrapMapNode->detail.seg.above, 0, sizeof(TrapMap)); memset(pTrapMapNode->detail.seg.below, 0, sizeof(TrapMap)); (*pnIndex)++; if (!BuildTrapMapNode(pTrapMapSpecRoot, pnIndex, pTrapMapNode->detail.seg.above)) { return FALSE; } (*pnIndex)++; if (!BuildTrapMapNode(pTrapMapSpecRoot, pnIndex, pTrapMapNode->detail.seg.below)) { return FALSE; } return TRUE; } int BuildTrapMapNode(pTrapMapSpecRoot, pnIndex, pTrapMapNode) TrapMapSpec *pTrapMapSpecRoot; int *pnIndex; TrapMap *pTrapMapNode; { TrapMapSpec *pTrapMapSpec=(&pTrapMapSpecRoot[*pnIndex]); switch (pTrapMapSpec->type) { case TRAP_NODE_LEAF: return SetTrapMapLeaf(pTrapMapSpecRoot, pnIndex, pTrapMapNode, pTrapMapSpec->which); case TRAP_NODE_PT: return SetTrapMapPt(pTrapMapSpecRoot, pnIndex, pTrapMapNode, pTrapMapSpec->which); case TRAP_NODE_SEG: return SetTrapMapSeg(pTrapMapSpecRoot, pnIndex, pTrapMapNode, pTrapMapSpec->which); default: break; } return TRUE; } static int BuildTrapMap(pTrapMapSpec) TrapMapSpec *pTrapMapSpec; { int nIndex=0; gpTrapMap = (TrapMap*)malloc(sizeof(TrapMap)); if (gpTrapMap == NULL) FailAllocMessage(); memset(gpTrapMap, 0, sizeof(TrapMap)); if (BuildTrapMapNode(pTrapMapSpec, &nIndex, gpTrapMap)) { return TRUE; } CleanTrapMap(); return FALSE; } /* * L, T, R, B, C are points. Left subtree are to the left of the point. * sL, sT, sR, sB are line segments. Left subtree are above the line segment. * lt, rt, lb, rb are the quardrants (leaves of the tree). * * If Cx == Tx && Cy == Ly: Do not warp. * * If Cx < Tx: * * +-------T-------+ C * | | / \ * | sT | / \ * | | / \ * | C sR | sL T * L sL R / \ / \ * | | lt lb / \ * | sB | / \ * | | sT sR * | | / \ / \ * +-------B-------+ lt sR rt rb * / \ * rt sB * / \ * rb lb * If Cx > Tx: * * +-------T-------+ T * | | / \ * | sT | / \ * | | / \ * | sL C | sL C * L sR R / \ / \ * | | lt lb / \ * | sB | / \ * | | sT sR * | | / \ / \ * +-------B-------+ rt sL rt rb * / \ * lt sB * / \ * lb rb * If Cx == Tx: * * +-------T-------+ T * | | / \ * | sT | / \ * | | / \ * | sL C sR | sL sR * L R / \ / \ * | | lt lb rt rb * | sB | * | | * | | * +-------B-------+ */ static int **gnVectorWarpImageSrcIndex=NULL; static int **gnVectorWarpImageDestIndex=NULL; static int ConvolveToVectorWarp(x, y) int x, y; { if (gConvExtraInfo.fp != NULL) { XColor **xcolors=gConvExtraInfo.xcolors; FILE *fp=gConvExtraInfo.fp; unsigned char buf[3]; buf[0] = (unsigned char)xcolors[y][x].red; buf[1] = (unsigned char)xcolors[y][x].green; buf[2] = (unsigned char)xcolors[y][x].blue; if ((int)fwrite(buf, sizeof(char), 3, fp) <= 0) writeFileFailed = TRUE; return TRUE; } else { return GetOrAllocHistogramIndex( &tgifColors[gnVectorWarpImageDestIndex[y][x]]); } } static void CleanUpVectorWarpData() { int i, image_h=topSel->obj->detail.xpm->image_h; if (gnVectorWarpImageSrcIndex != NULL) { for (i=0; i < image_h; i++) { if (gnVectorWarpImageSrcIndex[i] != NULL) { free(gnVectorWarpImageSrcIndex[i]); } } free(gnVectorWarpImageSrcIndex); gnVectorWarpImageSrcIndex = NULL; } if (gnVectorWarpImageDestIndex != NULL) { for (i=0; i < image_h; i++) { if (gnVectorWarpImageDestIndex[i] != NULL) { free(gnVectorWarpImageDestIndex[i]); } } free(gnVectorWarpImageDestIndex); gnVectorWarpImageDestIndex = NULL; } } static void SetTrapMapSegValue(nSegIndex, nPtIndex, w) int nSegIndex, nPtIndex, w; { int i; double dx=(double)0.0, dy, m, b; dy = (double)(gaTrapMapPt[TRAP_PT_C].y - gaTrapMapPt[nPtIndex].y); if (gaTrapMapPt[TRAP_PT_C].x == gaTrapMapPt[nPtIndex].x) { dx = (double)0.0; m = (double)0.0; } else { dx = (double)(gaTrapMapPt[TRAP_PT_C].x - gaTrapMapPt[nPtIndex].x); m = ((double)dy) / ((double)dx); } b = ((double)(gaTrapMapPt[TRAP_PT_C].y)) - m * ((double)(gaTrapMapPt[TRAP_PT_C].x)); gaTrapMapSeg[nSegIndex].m = m; gaTrapMapSeg[nSegIndex].b = b; for (i=0; i < w; i++) { double y=m*((double)(i))+b; gpSegYIntersects[nSegIndex][i] = round(y); } } static void SetTrapMapExtraValue(nLeafIndex, end_x, end_y, w) int nLeafIndex, end_x, end_y, w; { int i; double dx=(double)0.0, dy, m, b; dy = (double)(gaTrapMapPt[TRAP_PT_C].y - end_y); if (gaTrapMapPt[TRAP_PT_C].x == end_x) { dx = (double)0.0; m = (double)0.0; } else { dx = (double)(gaTrapMapPt[TRAP_PT_C].x - end_x); m = ((double)dy) / ((double)dx); } b = ((double)(gaTrapMapPt[TRAP_PT_C].y)) - m * ((double)(gaTrapMapPt[TRAP_PT_C].x)); for (i=0; i < w; i++) { double y=m*((double)(i))+b; gpExtraYIntersects[nLeafIndex][i] = round(y); } } static int CheckVectorWarpCoords(pFromPt, pToPt, dx, dy, image_w, image_h, pBBox) IntPoint *pFromPt, *pToPt; int dx, dy, image_w, image_h; struct BBRec *pBBox; { IntPoint to_pt; double ddx, ddy, d; int i, diam, ltx, lty, rbx, rby, w, h; char szBuf[MAXSTRING+1]; strcpy(szBuf, GetImageProcName(CMDID_VECTORWARP)); if (pFromPt->x < topSel->obj->obbox.ltx || pFromPt->y < topSel->obj->obbox.lty || pFromPt->x >= topSel->obj->obbox.rbx || pFromPt->y >= topSel->obj->obbox.rby) { MsgBox(TgLoadString(STID_PICK_PT_WITHIN_IMAGE_BOUND), TOOL_NAME, INFO_MB); return FALSE; } else if (image_w <= 4 || image_h <= 4) { sprintf(gszMsgBox, TgLoadString(STID_IMG_TOO_SMALL_IMAGEPROC_CMD), szBuf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } to_pt.x = pFromPt->x+dx; to_pt.y = pFromPt->y+dy; if (to_pt.x < topSel->obj->obbox.ltx || to_pt.y < topSel->obj->obbox.lty || to_pt.x >= topSel->obj->obbox.rbx || to_pt.y >= topSel->obj->obbox.rby) { if (dx == 0) { if (dy > 0) { to_pt.y = topSel->obj->obbox.rby-1; } else { to_pt.y = topSel->obj->obbox.lty; } } else { double m, b, x_intersect, y_intersect; int intersect=CORNER_TOP; m = ((double)dy) / ((double)dx); b = ((double)(pFromPt->y)) - m * ((double)(pFromPt->x)); if (dx < 0) { y_intersect = m * ((double)(topSel->obj->obbox.ltx)) + b; if (y_intersect < topSel->obj->obbox.lty) { intersect = CORNER_TOP; } else if (y_intersect > topSel->obj->obbox.rby-1) { intersect = CORNER_BOTTOM; } else { intersect = CORNER_LEFT; } } else { y_intersect = m * ((double)(topSel->obj->obbox.rbx-1)) + b; if (y_intersect < topSel->obj->obbox.lty) { intersect = CORNER_TOP; } else if (y_intersect > topSel->obj->obbox.rby-1) { intersect = CORNER_BOTTOM; } else { intersect = CORNER_RIGHT; } } switch (intersect) { case CORNER_TOP: /* intersects the obbox at the top */ to_pt.y = topSel->obj->obbox.lty; x_intersect = (((double)(to_pt.y)) - b) / m; to_pt.x = round(x_intersect); if (to_pt.x < topSel->obj->obbox.ltx) { to_pt.x = topSel->obj->obbox.ltx; } else if (to_pt.x >= topSel->obj->obbox.rbx) { to_pt.x = topSel->obj->obbox.rbx-1; } break; case CORNER_BOTTOM: /* intersects the obbox at the bottom */ to_pt.y = topSel->obj->obbox.rby; x_intersect = (((double)(to_pt.y)) - b) / m; to_pt.x = round(x_intersect); if (to_pt.x < topSel->obj->obbox.ltx) { to_pt.x = topSel->obj->obbox.ltx; } else if (to_pt.x >= topSel->obj->obbox.rbx) { to_pt.x = topSel->obj->obbox.rbx-1; } break; case CORNER_LEFT: /* intersects the obbox at the left */ to_pt.x = topSel->obj->obbox.lty; y_intersect = (m * ((double)(to_pt.x))) + b; to_pt.y = round(y_intersect); if (to_pt.y < topSel->obj->obbox.lty) { to_pt.y = topSel->obj->obbox.lty; } else if (to_pt.y >= topSel->obj->obbox.rby) { to_pt.y = topSel->obj->obbox.rby-1; } break; case CORNER_RIGHT: /* intersects the obbox at the right */ to_pt.x = topSel->obj->obbox.rby; y_intersect = (m * ((double)(to_pt.x))) + b; to_pt.y = round(y_intersect); if (to_pt.y < topSel->obj->obbox.lty) { to_pt.y = topSel->obj->obbox.lty; } else if (to_pt.y >= topSel->obj->obbox.rby) { to_pt.y = topSel->obj->obbox.rby-1; } break; } } } ddx = (double)(to_pt.x - pFromPt->x); ddy = (double)(to_pt.y - pFromPt->y); d = ((double)gfVectorWarpSoftness)*(double)sqrt((double)(ddx*ddx+ddy*ddy)); diam = round(d); ltx = pFromPt->x-diam - topSel->obj->obbox.ltx; lty = pFromPt->y-diam - topSel->obj->obbox.lty; rbx = pFromPt->x+diam - topSel->obj->obbox.ltx; rby = pFromPt->y+diam - topSel->obj->obbox.lty; if (ltx < 0) ltx = 0; if (lty < 0) lty = 0; if (rbx >= image_w) rbx = image_w; if (rby >= image_h) rby = image_h; pBBox->ltx = ltx; pBBox->lty = lty; pBBox->rbx = rbx; pBBox->rby = rby; pFromPt->x -= topSel->obj->obbox.ltx; pFromPt->y -= topSel->obj->obbox.lty; pToPt->x = to_pt.x - topSel->obj->obbox.ltx; pToPt->y = to_pt.y - topSel->obj->obbox.lty; if (pToPt->x == pFromPt->x) { if (pToPt->y == pFromPt->y) { Msg(TgLoadString(STID_NO_WARPING)); return FALSE; } gpTrapMapSpec = gCenterTrapMapSpec; } else if (pToPt->x < pFromPt->x) { gpTrapMapSpec = gLeftTrapMapSpec; } else { gpTrapMapSpec = gRightTrapMapSpec; } w = pBBox->rbx-pBBox->ltx; h = pBBox->rby-pBBox->lty; gpSegYIntersects = (int**)malloc(4*sizeof(int*)); gpExtraYIntersects = (int**)malloc(4*sizeof(int*)); if (gpSegYIntersects == NULL || gpExtraYIntersects == NULL) { FailAllocMessage(); if (gpSegYIntersects != NULL) free(gpSegYIntersects); if (gpExtraYIntersects != NULL) free(gpExtraYIntersects); return FALSE; } for (i=0; i < 4; i++) { gpSegYIntersects[i] = (int*)malloc(w*sizeof(int)); gpExtraYIntersects[i] = (int*)malloc(w*sizeof(int)); if (gpSegYIntersects[i] == NULL || gpExtraYIntersects[i] == NULL) { FailAllocMessage(); return FALSE; } memset(gpSegYIntersects[i], 0, w*sizeof(int)); memset(gpExtraYIntersects[i], 0, w*sizeof(int)); } /* sets L, T, R, B, and C points */ gaTrapMapPt[TRAP_PT_L].x = pBBox->ltx - pBBox->ltx; gaTrapMapPt[TRAP_PT_L].y = pFromPt->y - pBBox->lty; gaTrapMapPt[TRAP_PT_T].x = pFromPt->x - pBBox->ltx; gaTrapMapPt[TRAP_PT_T].y = pBBox->lty - pBBox->lty; gaTrapMapPt[TRAP_PT_R].x = pBBox->rbx - pBBox->ltx; gaTrapMapPt[TRAP_PT_R].y = pFromPt->y - pBBox->lty; gaTrapMapPt[TRAP_PT_B].x = pFromPt->x - pBBox->ltx; gaTrapMapPt[TRAP_PT_B].y = pBBox->rby - pBBox->lty; gaTrapMapPt[TRAP_PT_C].x = pToPt->x - pBBox->ltx; gaTrapMapPt[TRAP_PT_C].y = pToPt->y - pBBox->lty; /* sets sL, sT, sR, and sB line segments */ SetTrapMapSegValue(TRAP_SEG_L, TRAP_PT_L, w); SetTrapMapSegValue(TRAP_SEG_T, TRAP_PT_T, w); SetTrapMapSegValue(TRAP_SEG_R, TRAP_PT_R, w); SetTrapMapSegValue(TRAP_SEG_B, TRAP_PT_B, w); /* sets sL, sT, sR, and sB line segments */ SetTrapMapExtraValue(TRAP_LEAF_LT, 0, 0, w); SetTrapMapExtraValue(TRAP_LEAF_RT, w, 0, w); SetTrapMapExtraValue(TRAP_LEAF_LB, 0, h, w); SetTrapMapExtraValue(TRAP_LEAF_RB, w, h, w); /* sets lt, rt, lb, rb quardrants */ gaTrapMapLeaf[TRAP_LEAF_LT] = TRAP_LEAF_LT; gaTrapMapLeaf[TRAP_LEAF_RT] = TRAP_LEAF_RT; gaTrapMapLeaf[TRAP_LEAF_LB] = TRAP_LEAF_LB; gaTrapMapLeaf[TRAP_LEAF_RB] = TRAP_LEAF_RB; return TRUE; } static int GetQuadrant(pTrapMap, x, y) TrapMap *pTrapMap; int x, y; /* returns one of the TRAP_LEAF_*'s */ { switch (pTrapMap->type) { case TRAP_NODE_LEAF: return pTrapMap->detail.leaf.which; case TRAP_NODE_PT: if (x < pTrapMap->detail.pt.data->x) { return GetQuadrant(pTrapMap->detail.pt.left, x, y); } return GetQuadrant(pTrapMap->detail.pt.right, x, y); case TRAP_NODE_SEG: if (y < gpSegYIntersects[pTrapMap->detail.seg.which][x]) { return GetQuadrant(pTrapMap->detail.seg.above, x, y); } return GetQuadrant(pTrapMap->detail.seg.below, x, y); } return (-1); } /* * w w dw * +-----+ +-----+------+ * | o | warp | \ * h|(x,y)| ======> h| o \ * | | | (X,Y) \ X is also known as x_hat * +-----+ +__ \ Y is also known as y_hat * | \__ \ * dh| \__ \ * + \___\ * * w -> x_off, w+dw -> d_new_w, W -> d_bbox_w, x_hat -> new_x * h -> y_off, h+dh -> d_new_h, H -> d_bbox_h, y_hat -> new_y */ static int ComputeVectorWarpData(pFromPt, dx, dy) IntPoint *pFromPt; int dx, dy; { struct XPmRec *xpm_ptr=topSel->obj->detail.xpm; int i, image_w=xpm_ptr->image_w, image_h=xpm_ptr->image_h; int bbox_w, bbox_h, x_off, y_off, ppm6=FALSE; double d_bbox_w, d_bbox_h, d_x_off, d_y_off, d_new_w, d_new_h, ddw, ddh; Pixmap pixmap=xpm_ptr->pixmap; XImage *image=NULL; struct BBRec bbox; /* only points within bbox need to be warped */ IntPoint to_pt; XColor **xcolors=NULL, **bg_xcolors=NULL; ProgressInfo pi; if (!CheckVectorWarpCoords(pFromPt, &to_pt, dx, dy, image_w, image_h, &bbox)) { return FALSE; } ppm6 = DoPpm6(xpm_ptr); /* * w -> x_off, w+dw -> new_w, W -> bbox_w, x_hat -> new_x * h -> y_off, h+dh -> new_h, H -> bbox_h, y_hat -> new_y */ bbox_w = bbox.rbx - bbox.ltx; d_bbox_w = (double)bbox_w; bbox_h = bbox.rby - bbox.lty; d_bbox_h = (double)bbox_h; x_off = pFromPt->x - bbox.ltx; d_x_off = (double)x_off; y_off = pFromPt->y - bbox.lty; d_y_off = (double)y_off; d_new_w = (double)(to_pt.x - bbox.ltx); d_new_h = (double)(to_pt.y - bbox.lty); ddw = d_new_w - ((double)x_off); ddh = d_new_h - ((double)y_off); if (!BuildTrapMap(gpTrapMapSpec)) { return FALSE; } image = XGetImage(mainDisplay, pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (image == NULL) { FailAllocMessage(); return FALSE; } if (ppm6) { if (!InitTrueColorInfo(image, &gTrueColorInfo, image_w)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); XDestroyImage(image); return FALSE; } if (!SetConvExtraInfo(NULL, image_w, image_h, image, NULL)) { XDestroyImage(image); return FALSE; } xcolors = gConvExtraInfo.xcolors; bg_xcolors = gConvExtraInfo.bg_xcolors; } else { if (!CreatePixelToIndexMapping()) { XDestroyImage(image); return FALSE; } gnVectorWarpImageSrcIndex = (int**)malloc(image_h*sizeof(int*)); gnVectorWarpImageDestIndex = (int**)malloc(image_h*sizeof(int*)); if (gnVectorWarpImageSrcIndex == NULL || gnVectorWarpImageDestIndex == NULL) { if (gnVectorWarpImageSrcIndex != NULL) free(gnVectorWarpImageSrcIndex); if (gnVectorWarpImageDestIndex != NULL) { free(gnVectorWarpImageDestIndex); } FailAllocMessage(); XDestroyImage(image); CleanUpIndexOfPixel(); return FALSE; } memset(gnVectorWarpImageSrcIndex, 0, image_h*sizeof(int*)); memset(gnVectorWarpImageDestIndex, 0, image_h*sizeof(int*)); BeginProgress(&pi, image_h); for (i=0; i < image_h; i++) { int j; UpdateProgress(&pi, i); gnVectorWarpImageSrcIndex[i] = (int*)malloc(image_w*sizeof(int)); gnVectorWarpImageDestIndex[i] = (int*)malloc(image_w*sizeof(int)); if (gnVectorWarpImageSrcIndex[i] == NULL || gnVectorWarpImageDestIndex[i] == NULL) { FailAllocMessage(); for (j=0; j < i; j++) { if (gnVectorWarpImageSrcIndex[j] != NULL) { free(gnVectorWarpImageSrcIndex[j]); } } free(gnVectorWarpImageSrcIndex); gnVectorWarpImageSrcIndex = NULL; for (j=0; j < i; j++) { if (gnVectorWarpImageDestIndex[j] != NULL) { free(gnVectorWarpImageDestIndex[j]); } } free(gnVectorWarpImageDestIndex); gnVectorWarpImageDestIndex = NULL; XDestroyImage(image); CleanUpIndexOfPixel(); return FALSE; } for (j=0; j < image_w; j++) { gnVectorWarpImageSrcIndex[i][j] = gnVectorWarpImageDestIndex[i][j] = GetIndexOfPixel(XGetPixel(image,j,i)); } } } BeginProgress(&pi, image_h); srand(0); for (i=0; i < image_h; i++) { int j; UpdateProgress(&pi, i); if (i < bbox.lty || i >= bbox.rby) continue; for (j=0; j < image_w; j++) { int quadrant, new_x, new_y; if (j < bbox.ltx || j >= bbox.rbx) continue; new_x = j - bbox.ltx; new_y = i - bbox.lty; quadrant = GetQuadrant(gpTrapMap, new_x, new_y); if (quadrant != -1) { double d_new_x=(double)new_x, d_new_y=(double)new_y; double ddx=(double)0.0, ddy=(double)0.0, frac; int x, y, above; above = (new_y < gpExtraYIntersects[quadrant][new_x]); switch (quadrant) { case TRAP_LEAF_LT: if (above) { ddx = d_new_x - ddw*d_new_y/d_new_h; ddy = d_y_off*d_new_y/d_new_h; } else { ddx = d_x_off*d_new_x/d_new_w; ddy = d_new_y - ddh*d_new_x/d_new_w; } break; case TRAP_LEAF_RT: if (above) { ddx = d_new_x - ddw*d_new_y/d_new_h; ddy = d_y_off*d_new_y/d_new_h; } else { frac = (d_new_x-d_bbox_w)/(d_new_w-d_bbox_w); ddx = d_bbox_w - (d_bbox_w-d_x_off)*frac; ddy = d_new_y - ddh*frac; } break; case TRAP_LEAF_LB: if (above) { ddx = d_x_off*d_new_x/d_new_w; ddy = d_new_y - ddh*d_new_x/d_new_w; } else { frac = (d_new_y-d_bbox_h)/(d_new_h-d_bbox_h); ddx = d_new_x - ddw*frac; ddy = d_bbox_h - (d_bbox_h-d_y_off)*frac; } break; case TRAP_LEAF_RB: if (above) { frac = (d_new_x-d_bbox_w)/(d_new_w-d_bbox_w); ddx = d_bbox_w - (d_bbox_w-d_x_off)*frac; ddy = d_new_y - ddh*frac; } else { frac = (d_new_y-d_bbox_h)/(d_new_h-d_bbox_h); ddx = d_new_x - ddw*frac; ddy = d_bbox_h - (d_bbox_h-d_y_off)*frac; } break; } x = round(ddx); y = round(ddy); x += bbox.ltx; y += bbox.lty; if (x < bbox.ltx) x = bbox.ltx; if (x >= bbox.rbx) x = bbox.rbx-1; if (y < bbox.lty) y = bbox.lty; if (y >= bbox.rby) y = bbox.rby-1; if (ppm6) { xcolors[i][j] = bg_xcolors[y][x]; } else { gnVectorWarpImageDestIndex[i][j] = gnVectorWarpImageSrcIndex[y][x]; } } } } XDestroyImage(image); CleanUpIndexOfPixel(); return TRUE; } static int SpecifyLineSeg(pnFromAbsX, pnFromAbsY, pnToAbsX, pnToAbsY) int *pnFromAbsX, *pnFromAbsY, *pnToAbsX, *pnToAbsY; { int started=FALSE, done=FALSE, orig_x=0, orig_y=0, grid_x=0, grid_y=0; int root_x, root_y, saved_snap_on=snapOn; char buf[80]; unsigned int status; Window root_win, child_win; snapOn = FALSE; *buf = '\0'; SetMouseStatus(TgLoadString(STID_START_LINE_SEG_DOTS), TgLoadCachedString(CSTID_FINISH), TgLoadCachedString(CSTID_FINISH)); XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonPressMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); XQueryPointer(mainDisplay, drawWindow, &root_win, &child_win, &root_x, &root_y, &orig_x, &orig_y, &status); GridXY(orig_x, orig_y, &grid_x, &grid_y); MarkRulers(grid_x, grid_y); orig_x = grid_x; orig_y = grid_y; while (!done) { XEvent input; XNextEvent(mainDisplay, &input); switch (input.type) { case Expose: ExposeEventHandler(&input, TRUE); break; case VisibilityNotify: ExposeEventHandler(&input, TRUE); break; case ButtonPress: if (input.xbutton.button == Button1) { MarkRulers(grid_x, grid_y); SetMouseStatus(TgLoadString(STID_ENDT_LINE_SEG_DOTS), "", ""); GridXY(input.xbutton.x, input.xbutton.y, &grid_x, &grid_y); orig_x = grid_x; orig_y = grid_y; XDrawLine(mainDisplay, drawWindow, revDefaultGC, orig_x, orig_y, grid_x, grid_y); MarkRulers(grid_x, grid_y); started = TRUE; } else { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); done = TRUE; started = FALSE; } break; case MotionNotify: MarkRulers(grid_x, grid_y); if (started) { XDrawLine(mainDisplay, drawWindow, revDefaultGC, orig_x, orig_y, grid_x, grid_y); } GridXY(input.xmotion.x, input.xmotion.y, &grid_x, &grid_y); if (started) { XDrawLine(mainDisplay, drawWindow, revDefaultGC, orig_x, orig_y, grid_x, grid_y); } MarkRulers(grid_x, grid_y); break; case ButtonRelease: XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); done = TRUE; MarkRulers(grid_x, grid_y); XDrawLine(mainDisplay, drawWindow, revDefaultGC, orig_x, orig_y, grid_x, grid_y); } } snapOn = saved_snap_on; if (started && !(orig_x == grid_x && orig_y == grid_y)) { *pnFromAbsX = ABS_X(orig_x); *pnFromAbsY = ABS_Y(orig_y); *pnToAbsX = ABS_X(grid_x); *pnToAbsY = ABS_Y(grid_y); return TRUE; } return FALSE; } void VectorWarp() { int ok=TRUE; IntPoint from_pt, to_pt; if (!CheckSelectionForImageProc(CMDID_VECTORWARP)) { return; } memset(&from_pt, 0, sizeof(IntPoint)); memset(&to_pt, 0, sizeof(IntPoint)); SaveStatusStrings(); while (ok) { if (somethingHighLighted) HighLightReverse(); ok = SpecifyLineSeg(&from_pt.x, &from_pt.y, &to_pt.x, &to_pt.y); if (!somethingHighLighted) HighLightForward(); if (!ok) break; gpConvolveCmdID = CMDID_VECTORWARP; if (!ComputeVectorWarpData(&from_pt, to_pt.x-from_pt.x, to_pt.y-from_pt.y)) { CleanTrapMap(); gpConvolveCmdID = (-1); break; } CleanTrapMap(); gpConvolveFunc = (NLFN*)ConvolveToVectorWarp; gpConvolveCmdID = CMDID_VECTORWARP; gnConvolving = TRUE; DoImageProc(NULL); gnConvolving = FALSE; gpConvolveFunc = NULL; gpConvolveCmdID = (-1); CleanUpVectorWarpData(); } RestoreStatusStrings(); } /* ======================= Non-Image Processing ======================= */ /* ----------------------- RunBggen ----------------------- */ static int GetBggenImageSize(p_image_w, p_image_h) int *p_image_w, *p_image_h; { char spec[MAXSTRING+1], *dup_spec=NULL, *part1=NULL, *part2=NULL; int ok=TRUE; *spec = '\0'; if (Dialog(TgLoadString(STID_ENTER_IMAGE_SIZE_IN_PIX_RC), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), spec)==INVALID) { return FALSE; } UtilTrimBlanks(spec); if (*spec == '\0') return FALSE; if ((dup_spec=UtilStrDup(spec)) == NULL) { FailAllocMessage(); return FALSE; } if ((part1=strtok(dup_spec, " ,xX[]")) != NULL && (part2=strtok(NULL, " ,xX[]")) != NULL) { *p_image_w = atoi(part1); *p_image_h = atoi(part2); if ((*p_image_w) <= 0 || (*p_image_h) <= 0) { ok = FALSE; } } else { ok = FALSE; } if (!ok) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC), dup_spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } free(dup_spec); return ok; } static int BggenGenerateXpm(image_w, image_h, sz_spec, sz_path, path_buf_sz) int image_w, image_h, path_buf_sz; char *sz_spec, *sz_path; { char *psz_cmd, sz_geom[MAXSTRING+1]; FILE *pFile, *pPipe; int bytes_read; if (MkTempFile(sz_path, path_buf_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } sprintf(sz_geom, "%1dx%1d", image_w, image_h); if (fullTrueColorMode && HasZlibSupport()) { sprintf(gszMsgBox, bggenToPpm6Cmd, sz_spec, sz_geom); } else { sprintf(gszMsgBox, bggenToXpmCmd, sz_spec, sz_geom); } if ((psz_cmd=UtilStrDup(gszMsgBox)) == NULL) { return FailAllocMessage(); } if (!FindProgramInPath(psz_cmd, NULL, FALSE)) { free(psz_cmd); return FALSE; } if ((pFile=fopen(sz_path,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), sz_path); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(psz_cmd); return FALSE; } Msg("Executing:"); sprintf(gszMsgBox, " %s", psz_cmd); Msg(gszMsgBox); sprintf(gszMsgBox, "Executing '%s'...", psz_cmd); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pPipe=(FILE*)popen(psz_cmd,"r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), psz_cmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(psz_cmd); fclose(pFile); unlink(sz_path); return FALSE; } writeFileFailed = FALSE; while ((bytes_read=fread(gszMsgBox, sizeof(char), sizeof(gszMsgBox), pPipe)) > 0) { if ((int)fwrite(gszMsgBox, sizeof(char), bytes_read, pFile) <= 0) { writeFileFailed = TRUE; break; } } pclose(pPipe); SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); free(psz_cmd); fclose(pFile); if (writeFileFailed) { FailToWriteFileMessage(sz_path); unlink(sz_path); return FALSE; } return TRUE; } void RunBggen() { int image_w=0, image_h=0, w, h, short_name, rc, use_obj_pos=FALSE; int ltx=0, lty=0; int ncolors=0, chars_per_pixel=0, first_pixel_is_bg=0, *pixels=NULL; char szSpec[MAXSTRING+1], szPath[MAXPATHLENGTH+1], *rest; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL; struct ObjRec *obj_ptr; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; if (curChoice != NOTHING || topSel == NULL) { MakeQuiescent(); if (!GetBggenImageSize(&image_w, &image_h)) { return; } } else if (!CheckSelectionForImageProc(CMDID_RUNBGGEN)) { return; } else { obj_ptr = topSel->obj; ltx = obj_ptr->obbox.ltx; lty = obj_ptr->obbox.lty; image_w = obj_ptr->obbox.rbx - ltx; image_h = obj_ptr->obbox.rby - lty; use_obj_pos = TRUE; HighLightReverse(); } *szSpec = '\0'; Dialog(TgLoadString(STID_ENTER_CMD_OP_FOR_BGGEN), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') { if (use_obj_pos) HighLightForward(); return; } SaveStatusStrings(); if (!BggenGenerateXpm(image_w, image_h, szSpec, szPath, sizeof(szPath))) { RestoreStatusStrings(); if (use_obj_pos) HighLightForward(); return; } RestoreStatusStrings(); if (fullTrueColorMode && HasZlibSupport()) { char deflated_fname[MAXPATHLENGTH+1]; struct XPmRec *xpm_ptr=NULL; ResetPngHeaderInfo(&gPngHeaderInfo); obj_ptr = CreatePpmTrueObjFromFile(szPath); if (obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile(szPath, deflated_fname)) { /* good */ } else { FreeObj(obj_ptr); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_PPM), szPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); return; } xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; unlink(deflated_fname); } else { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(szPath, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if ((short_name=IsPrefix(bootDir, szPath, &rest))) ++rest; if (rc != BitmapSuccess) { if (use_obj_pos) HighLightForward(); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), (short_name ? rest : szPath)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); return; } obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); } unlink(szPath); AddObj(NULL, topObj, obj_ptr); if (use_obj_pos) { RemoveAllSel(); MoveObj(obj_ptr, ltx-obj_ptr->obbox.ltx, lty-obj_ptr->obbox.lty); numRedrawBBox = 0; obj_ptr->tmp_parent = NULL; DrawObj(drawWindow, obj_ptr); } else { PlaceTopObj(obj_ptr, NULL, NULL); } SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } sprintf(gszMsgBox, TgLoadString(STID_NEW_XPM_WH_GENERATED), image_w, image_h); Msg(gszMsgBox); } /* ----------------------- CircularBggen ----------------------- */ static int CircularBggenGenerateXpm(image_w, image_h, ncolors, sz_path, path_buf_sz) int image_w, image_h, ncolors, path_buf_sz; char *sz_path; { FILE *pFile=NULL; int i=0, cx=0, cy=0; float fval=(float)0, finc=65535.0/((float)(ncolors-1)); double max_dist=(double)0; ProgressInfo pi; if (MkTempFile(sz_path, path_buf_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } gpHistogram = (XColor*)malloc(ncolors*sizeof(XColor)); if (gpHistogram == NULL) return FailAllocMessage(); memset(gpHistogram, 0, ncolors*sizeof(XColor)); for (i=0, fval=0.0; i < ncolors; i++, fval+=finc) { int ival; ival = round(fval); HISTOGRAMRED(i) = HISTOGRAMGREEN(i) = HISTOGRAMBLUE(i) = (unsigned int)ival; } i--; HISTOGRAMRED(i) = HISTOGRAMGREEN(i) = HISTOGRAMBLUE(i) = 65535; cx = (image_w>>1); cy = (image_h>>1); max_dist=(double)sqrt((double)(cx*cx+cy*cy)); if (fullTrueColorMode && HasZlibSupport()) { if ((pFile=fopen(sz_path,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), sz_path); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(gpHistogram); gpHistogram = NULL; return FALSE; } writeFileFailed = FALSE; if (fprintf(pFile, "P6\n%1d %1d\n255\n", image_w, image_h) == EOF) { writeFileFailed = TRUE; } } else { gnFinalImageIndex = (int**)malloc(image_h*sizeof(int*)); if (gnFinalImageIndex == NULL) { free(gpHistogram); gpHistogram = NULL; return FailAllocMessage(); } memset(gnFinalImageIndex, 0, image_h*sizeof(int*)); } BeginProgress(&pi, image_h); for (i=0; i < image_h; i++) { int j, dy2=(i-cy)*(i-cy); UpdateProgress(&pi, i); if (fullTrueColorMode && HasZlibSupport()) { /* don't allocate */ } else { if ((gnFinalImageIndex[i]=(int*)malloc(image_w*sizeof(int))) == NULL) { for (j=0; j < i; j++) free(gnFinalImageIndex[j]); free(gnFinalImageIndex); free(gpHistogram); gnFinalImageIndex = NULL; gpHistogram = NULL; return FailAllocMessage(); } } for (j=0; j < image_w; j++) { int dx2=(j-cx)*(j-cx); double dist=(double)sqrt((double)(dx2+dy2)); double dgray=((double)ncolors)*dist/max_dist+0.5; int index=round(dgray); if (index < 0) index = 0; if (index >= ncolors) index = ncolors-1; if (fullTrueColorMode && HasZlibSupport()) { unsigned int gray=0; unsigned char buf[3]; gray = (unsigned int)HISTOGRAMRED(ncolors-1-index); gray >>= 8; buf[0] = buf[1] = buf[2] = (unsigned char)gray; if ((int)fwrite(buf, sizeof(char), 3, pFile) <= 0) { writeFileFailed = TRUE; } } else { gnFinalImageIndex[i][j] = ncolors-1-index; } } } gnTransparentIndex = (-1); if (fullTrueColorMode && HasZlibSupport()) { fclose(pFile); } else { if ((pFile=fopen(sz_path,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), sz_path); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); for (i=0; i < image_h; i++) free(gnFinalImageIndex[i]); free(gnFinalImageIndex); free(gpHistogram); gnFinalImageIndex = NULL; gpHistogram = NULL; return FALSE; } gnImageW = image_w; gnImageH = image_h; gnHistogramEntries = ncolors; writeFileFailed = FALSE; DumpConvolution(pFile); fclose(pFile); for (i=0; i < image_h; i++) free(gnFinalImageIndex[i]); free(gnFinalImageIndex); } free(gpHistogram); gnFinalImageIndex = NULL; gpHistogram = NULL; if (writeFileFailed) { FailToWriteFileMessage(sz_path); unlink(sz_path); return FALSE; } return TRUE; } void CircularBggen() { int image_w=0, image_h=0, w, h, short_name, rc, use_obj_pos=FALSE; int ltx=0, lty=0; int ncolors=0, chars_per_pixel=0, first_pixel_is_bg=0, *pixels=NULL; char szSpec[MAXSTRING+1], szPath[MAXPATHLENGTH+1], *rest; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL; struct ObjRec *obj_ptr; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; if (curChoice != NOTHING || topSel == NULL) { MakeQuiescent(); if (!GetBggenImageSize(&image_w, &image_h)) { return; } } else if (!CheckSelectionForImageProc(CMDID_CIRCULARBGGEN)) { return; } else { obj_ptr = topSel->obj; ltx = obj_ptr->obbox.ltx; lty = obj_ptr->obbox.lty; image_w = obj_ptr->obbox.rbx - ltx; image_h = obj_ptr->obbox.rby - lty; use_obj_pos = TRUE; HighLightReverse(); } *szSpec = '\0'; Dialog(TgLoadString(STID_ENTER_GRAY_LEVELS_222), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') { if (use_obj_pos) HighLightForward(); return; } ncolors = atoi(szSpec); if (ncolors < 2 || ncolors > 222) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_GIVEN_VALUE_ENTERED), szSpec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (use_obj_pos) HighLightForward(); return; } SaveStatusStrings(); if (!CircularBggenGenerateXpm(image_w, image_h, ncolors, szPath, sizeof(szPath))) { RestoreStatusStrings(); if (use_obj_pos) HighLightForward(); return; } RestoreStatusStrings(); if (fullTrueColorMode && HasZlibSupport()) { char deflated_fname[MAXPATHLENGTH+1]; struct XPmRec *xpm_ptr=NULL; ResetPngHeaderInfo(&gPngHeaderInfo); obj_ptr = CreatePpmTrueObjFromFile(szPath); if (obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile(szPath, deflated_fname)) { /* good */ } else { FreeObj(obj_ptr); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_PPM), szPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); return; } xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; unlink(deflated_fname); } else { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(szPath, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if ((short_name=IsPrefix(bootDir, szPath, &rest))) ++rest; if (rc != BitmapSuccess) { if (use_obj_pos) HighLightForward(); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), (short_name ? rest : szPath)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); return; } obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); } unlink(szPath); AddObj(NULL, topObj, obj_ptr); if (use_obj_pos) { RemoveAllSel(); MoveObj(obj_ptr, ltx-obj_ptr->obbox.ltx, lty-obj_ptr->obbox.lty); numRedrawBBox = 0; obj_ptr->tmp_parent = NULL; DrawObj(drawWindow, obj_ptr); } else { PlaceTopObj(obj_ptr, NULL, NULL); } SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } sprintf(gszMsgBox, TgLoadString(STID_NEW_XPM_WH_GENERATED), image_w, image_h); Msg(gszMsgBox); } /* ----------------------- SimpleRectBggen ----------------------- */ static int SimpleRectBggenGenerateXpm(image_w, image_h, pxcolor, sz_path, path_buf_sz) int image_w, image_h, path_buf_sz; XColor *pxcolor; char *sz_path; { FILE *pFile=NULL; int i=0; ProgressInfo pi; if (MkTempFile(sz_path, path_buf_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } gpHistogram = (XColor*)malloc(sizeof(XColor)); if (gpHistogram == NULL) return FailAllocMessage(); memset(gpHistogram, 0, sizeof(XColor)); HISTOGRAMRED(0) = pxcolor->red; HISTOGRAMGREEN(0) = pxcolor->green; HISTOGRAMBLUE(0) = pxcolor->blue; if (fullTrueColorMode && HasZlibSupport()) { if ((pFile=fopen(sz_path,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), sz_path); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(gpHistogram); gpHistogram = NULL; return FALSE; } writeFileFailed = FALSE; if (fprintf(pFile, "P6\n%1d %1d\n255\n", image_w, image_h) == EOF) { writeFileFailed = TRUE; } } else { gnFinalImageIndex = (int**)malloc(image_h*sizeof(int*)); if (gnFinalImageIndex == NULL) { free(gpHistogram); gpHistogram = NULL; return FailAllocMessage(); } memset(gnFinalImageIndex, 0, image_h*sizeof(int*)); } BeginProgress(&pi, image_h); for (i=0; i < image_h; i++) { int j; UpdateProgress(&pi, i); if (fullTrueColorMode && HasZlibSupport()) { unsigned char buf[3]; unsigned int r=0, g=0, b=0; r = (unsigned int)(pxcolor->red); g = (unsigned int)(pxcolor->green); b = (unsigned int)(pxcolor->blue); buf[0] = (unsigned char)((r>>8)&0x0ff); buf[1] = (unsigned char)((g>>8)&0x0ff); buf[2] = (unsigned char)((b>>8)&0x0ff); for (j=0; j < image_w; j++) { if ((int)fwrite(buf, sizeof(char), 3, pFile) <= 0) { writeFileFailed = TRUE; } } } else { if ((gnFinalImageIndex[i]=(int*)malloc(image_w*sizeof(int))) == NULL) { for (j=0; j < i; j++) free(gnFinalImageIndex[j]); free(gnFinalImageIndex); free(gpHistogram); gnFinalImageIndex = NULL; gpHistogram = NULL; return FailAllocMessage(); } memset(gnFinalImageIndex[i], 0, image_w*sizeof(int)); } } gnTransparentIndex = (-1); if (fullTrueColorMode && HasZlibSupport()) { fclose(pFile); } else { if ((pFile=fopen(sz_path,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), sz_path); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); for (i=0; i < image_h; i++) free(gnFinalImageIndex[i]); free(gnFinalImageIndex); free(gpHistogram); gnFinalImageIndex = NULL; gpHistogram = NULL; return FALSE; } gnImageW = image_w; gnImageH = image_h; gnHistogramEntries = 1; writeFileFailed = FALSE; DumpConvolution(pFile); fclose(pFile); for (i=0; i < image_h; i++) free(gnFinalImageIndex[i]); free(gnFinalImageIndex); } free(gpHistogram); gnFinalImageIndex = NULL; gpHistogram = NULL; if (writeFileFailed) { FailToWriteFileMessage(sz_path); unlink(sz_path); return FALSE; } return TRUE; } void SimpleRectBggen() { int image_w=0, image_h=0, w, h, short_name, rc, use_obj_pos=FALSE; int ltx=0, lty=0; int ncolors=0, chars_per_pixel=0, first_pixel_is_bg=0, *pixels=NULL; char szSpec[MAXSTRING+1], szPath[MAXPATHLENGTH+1], *rest; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL; struct ObjRec *obj_ptr; XColor xcolor; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; if (curChoice != NOTHING || topSel == NULL) { MakeQuiescent(); if (!GetBggenImageSize(&image_w, &image_h)) { return; } } else if (!CheckSelectionForImageProc(CMDID_CIRCULARBGGEN)) { return; } else { obj_ptr = topSel->obj; ltx = obj_ptr->obbox.ltx; lty = obj_ptr->obbox.lty; image_w = obj_ptr->obbox.rbx - ltx; image_h = obj_ptr->obbox.rby - lty; use_obj_pos = TRUE; HighLightReverse(); } *szSpec = '\0'; Dialog(TgLoadString(STID_ENTER_COLOR_FOR_RECT_BGGEN), TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), szSpec); UtilTrimBlanks(szSpec); if (*szSpec == '\0') { if (use_obj_pos) HighLightForward(); return; } if (!TgifParseColor(szSpec, &xcolor)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_PARSE_NAMED_COLOR), szSpec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (use_obj_pos) HighLightForward(); return; } SaveStatusStrings(); if (!SimpleRectBggenGenerateXpm(image_w, image_h, &xcolor, szPath, sizeof(szPath))) { RestoreStatusStrings(); if (use_obj_pos) HighLightForward(); return; } RestoreStatusStrings(); if (fullTrueColorMode && HasZlibSupport()) { char deflated_fname[MAXPATHLENGTH+1]; struct XPmRec *xpm_ptr=NULL; ResetPngHeaderInfo(&gPngHeaderInfo); obj_ptr = CreatePpmTrueObjFromFile(szPath); if (obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile(szPath, deflated_fname)) { /* good */ } else { FreeObj(obj_ptr); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_PPM), szPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); return; } xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; unlink(deflated_fname); } else { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(szPath, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if ((short_name=IsPrefix(bootDir, szPath, &rest))) ++rest; if (rc != BitmapSuccess) { if (use_obj_pos) HighLightForward(); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), (short_name ? rest : szPath)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); return; } obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); } unlink(szPath); AddObj(NULL, topObj, obj_ptr); if (use_obj_pos) { RemoveAllSel(); MoveObj(obj_ptr, ltx-obj_ptr->obbox.ltx, lty-obj_ptr->obbox.lty); numRedrawBBox = 0; obj_ptr->tmp_parent = NULL; DrawObj(drawWindow, obj_ptr); } else { PlaceTopObj(obj_ptr, NULL, NULL); } SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } sprintf(gszMsgBox, TgLoadString(STID_NEW_XPM_WH_GENERATED), image_w, image_h); Msg(gszMsgBox); } /* ----------------------- RegenerateImage ----------------------- */ static int RegenerateImageFile(pszPath, xpm_ptr) char *pszPath; struct XPmRec *xpm_ptr; { int saved_colordump=colorDump, saved_left=leftExportPixelTrim; int saved_top=topExportPixelTrim, saved_right=rightExportPixelTrim; int saved_bottom=bottomExportPixelTrim, saved_where_to_print=whereToPrint; int dump_ppm_preferred=FALSE; leftExportPixelTrim = topExportPixelTrim = rightExportPixelTrim = bottomExportPixelTrim = 0; *gszImageProcXPmFile = '\0'; gnConvolving = FALSE; colorDump = TRUE; if (xpm_ptr == NULL) { /* called from CreatePixmapFromSelected() */ if (fullTrueColorMode && HasZlibSupport()) { whereToPrint = PPM_FILE; dump_ppm_preferred = TRUE; } else { whereToPrint = XBM_FILE; } } else { /* called from RegenerateImage() or CropImage() */ if (DoPpm6(xpm_ptr)) { whereToPrint = PPM_FILE; dump_ppm_preferred = TRUE; } else if (xpm_ptr->real_type == XPM_XPM && fullTrueColorMode && HasZlibSupport()) { whereToPrint = PPM_FILE; dump_ppm_preferred = TRUE; } else { whereToPrint = XBM_FILE; } } gnInImageProc = TRUE; gpImageMapColorFunc = NULL; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); DumpXBitmapFile(gnInImageProc, dump_ppm_preferred, FALSE); SetDefaultCursor(mainWindow); ShowCursor(); gnInImageProc = FALSE; whereToPrint = saved_where_to_print; colorDump = saved_colordump; leftExportPixelTrim = saved_left; topExportPixelTrim = saved_top; rightExportPixelTrim = saved_right; bottomExportPixelTrim = saved_bottom; if (*gszImageProcXPmFile == '\0') return FALSE; strcpy(pszPath, gszImageProcXPmFile); return TRUE; } void RegenerateImage() { int image_w=0, image_h=0, w, h, short_name, rc; int ltx=0, lty=0, ppm6=FALSE; int ncolors=0, chars_per_pixel=0, first_pixel_is_bg=0, *pixels=NULL; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL, *rest; char szPath[MAXPATHLENGTH+1]; struct ObjRec *obj_ptr=NULL, *saved_top_obj=NULL, *saved_bot_obj=NULL; struct SelRec *top_sel_ptr=NULL, *bot_sel_ptr=NULL; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; struct XPmRec *xpm_ptr=NULL; if (!CheckSelectionForImageProc(CMDID_REGENERATEIMAGE)) { return; } obj_ptr = topSel->obj; xpm_ptr = obj_ptr->detail.xpm; if (obj_ptr->ctm == NULL) { if (MsgBox(TgLoadString(STID_XPM_NOT_XFORMED_REGEN_ANYWAY), TOOL_NAME, YNC_MB) != MB_ID_YES) { return; } } if (DoPpm6(xpm_ptr)) { ppm6 = TRUE; } else if (xpm_ptr->real_type == XPM_XPM && fullTrueColorMode && HasZlibSupport()) { ppm6 = TRUE; } ltx = obj_ptr->obbox.ltx; lty = obj_ptr->obbox.lty; HighLightReverse(); PrepareToReplaceAnObj(obj_ptr); PushPageInfo(); saved_top_obj = topObj; saved_bot_obj = botObj; JustDupSelObj(&top_sel_ptr, &bot_sel_ptr); curPage->top = topObj = top_sel_ptr->obj; curPage->bot = botObj = bot_sel_ptr->obj; CopyObjId(topSel->obj, topObj); CopyObjLocks(topSel->obj, topObj); rc = RegenerateImageFile(szPath, topObj->detail.xpm); DelAllObj(); free(top_sel_ptr); PopPageInfo(); curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); if (!rc) { HighLightForward(); AbortPrepareCmd(CMD_REPLACE); return; } UnlinkObj(obj_ptr); FreeObj(obj_ptr); RemoveAllSel(); if (ppm6) { char deflated_fname[MAXPATHLENGTH+1]; struct XPmRec *xpm_ptr=NULL; ResetPngHeaderInfo(&gPngHeaderInfo); obj_ptr = CreatePpmTrueObjFromFile(szPath); if (obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile(szPath, deflated_fname)) { /* good */ } else { FreeObj(obj_ptr); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_PPM), szPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); AbortPrepareCmd(CMD_REPLACE); return; } xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; unlink(deflated_fname); } else { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(szPath, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if ((short_name=IsPrefix(bootDir, szPath, &rest))) ++rest; if (rc != BitmapSuccess) { AbortPrepareCmd(CMD_REPLACE); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), (short_name ? rest : szPath)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); return; } obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); if (obj_ptr == NULL) return; } unlink(szPath); AddObj(NULL, topObj, obj_ptr); MoveObj(obj_ptr, ltx-obj_ptr->obbox.ltx, lty-obj_ptr->obbox.lty); numRedrawBBox = 0; obj_ptr->tmp_parent = NULL; DrawObj(drawWindow, obj_ptr); SelectTopObj(); RecordReplaceAnObj(topObj); SetFileModified(TRUE); justDupped = FALSE; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } sprintf(gszMsgBox, TgLoadString(STID_NEW_XPM_WH_GENERATED), image_w, image_h); Msg(gszMsgBox); } /* ----------------------- CreatePixmapFromSelected ----------------------- */ void CreatePixmapFromSelected() { int image_w=0, image_h=0, w=0, h=0, short_name=FALSE, rc=0; int ltx=0, lty=0, ppm6=FALSE; int ncolors=0, chars_per_pixel=0, first_pixel_is_bg=0, *pixels=NULL; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL, *rest; char szPath[MAXPATHLENGTH+1]; struct ObjRec *obj_ptr=NULL, *saved_top_obj=NULL, *saved_bot_obj=NULL; struct SelRec *top_sel_ptr=NULL, *bot_sel_ptr=NULL, *sel_ptr=NULL; struct SelRec *next_sel=NULL; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (topSel == botSel && topSel->obj->type == OBJ_XPM) { RegenerateImage(); return; } if (fullTrueColorMode && HasZlibSupport()) { ppm6 = TRUE; } ltx = selLtX; lty = selLtY; HighLightReverse(); PushPageInfo(); saved_top_obj = topObj; saved_bot_obj = botObj; JustDupSelObj(&top_sel_ptr, &bot_sel_ptr); curPage->top = topObj = top_sel_ptr->obj; curPage->bot = botObj = bot_sel_ptr->obj; for (sel_ptr=topSel, obj_ptr=topObj; obj_ptr!=NULL; sel_ptr=sel_ptr->next, obj_ptr=obj_ptr->next) { CopyObjId(sel_ptr->obj, obj_ptr); CopyObjLocks(sel_ptr->obj, obj_ptr); } rc = RegenerateImageFile(szPath, NULL); DelAllObj(); for (sel_ptr=top_sel_ptr; sel_ptr != NULL; sel_ptr=next_sel) { next_sel = sel_ptr->next; free(sel_ptr); } PopPageInfo(); curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); if (!rc) { HighLightForward(); return; } RemoveAllSel(); if (ppm6) { char deflated_fname[MAXPATHLENGTH+1]; struct XPmRec *xpm_ptr=NULL; ResetPngHeaderInfo(&gPngHeaderInfo); obj_ptr = CreatePpmTrueObjFromFile(szPath); if (obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile(szPath, deflated_fname)) { /* good */ } else { FreeObj(obj_ptr); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_PPM), szPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); AbortPrepareCmd(CMD_REPLACE); return; } xpm_ptr = obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; unlink(deflated_fname); } else { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(szPath, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if ((short_name=IsPrefix(bootDir, szPath, &rest))) ++rest; if (rc != BitmapSuccess) { AbortPrepareCmd(CMD_REPLACE); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), (short_name ? rest : szPath)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); return; } obj_ptr = CreateXPmObj(image_w, image_h, w, h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); if (obj_ptr == NULL) return; } unlink(szPath); AddObj(NULL, topObj, obj_ptr); MoveObj(obj_ptr, ltx-obj_ptr->obbox.ltx, lty-obj_ptr->obbox.lty); numRedrawBBox = 0; obj_ptr->tmp_parent = NULL; DrawObj(drawWindow, obj_ptr); SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } sprintf(gszMsgBox, TgLoadString(STID_NEW_XPM_WH_GENERATED), image_w, image_h); Msg(gszMsgBox); } /* ----------------------- CropImage ----------------------- */ static void ContinueCrop(nObjAbsLtX, nObjAbsLtY, nStartXOff, nStartYOff, pnEndXOff, pnEndYOff) int nObjAbsLtX, nObjAbsLtY, nStartXOff, nStartYOff, *pnEndXOff, *pnEndYOff; { int end_x, end_y, cropping=TRUE; char buf[80], w_buf[80], h_buf[80], x_buf[80], y_buf[80]; end_x = nStartXOff; end_y = nStartYOff; SelBox(drawWindow, revDefaultGC, nStartXOff, nStartYOff, end_x, end_y); PixelToMeasurementUnit(w_buf, 0); PixelToMeasurementUnit(h_buf, 0); PixelToMeasurementUnit(x_buf, ABS_X(end_x)-nObjAbsLtX); PixelToMeasurementUnit(y_buf, ABS_Y(end_y)-nObjAbsLtY); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); StartShowMeasureCursor(end_x, end_y, buf, TRUE); XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); while (cropping) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(end_x-nStartXOff))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(end_y-nStartYOff))); PixelToMeasurementUnit(x_buf, ABS_X(end_x)-nObjAbsLtX); PixelToMeasurementUnit(y_buf, ABS_Y(end_y)-nObjAbsLtY); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); EndShowMeasureCursor(end_x, end_y, buf, TRUE); SelBox(drawWindow, revDefaultGC, nStartXOff, nStartYOff, end_x, end_y); cropping = FALSE; } else if (input.type == MotionNotify) { int new_end_x, new_end_y; XMotionEvent *motion_ev; XEvent ev; motion_ev = &(input.xmotion); new_end_x = motion_ev->x; new_end_y = motion_ev->y; PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(end_x-nStartXOff))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(end_y-nStartYOff))); PixelToMeasurementUnit(x_buf, ABS_X(end_x)-nObjAbsLtX); PixelToMeasurementUnit(y_buf, ABS_Y(end_y)-nObjAbsLtY); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); ShowMeasureCursor(end_x, end_y, buf, TRUE); SelBox(drawWindow, revDefaultGC, nStartXOff, nStartYOff, end_x, end_y); end_x = new_end_x; end_y = new_end_y; SelBox(drawWindow, revDefaultGC, nStartXOff, nStartYOff, end_x, end_y); PixelToMeasurementUnit(w_buf, ABS_SIZE(abs(end_x-nStartXOff))); PixelToMeasurementUnit(h_buf, ABS_SIZE(abs(end_y-nStartYOff))); PixelToMeasurementUnit(x_buf, ABS_X(end_x)-nObjAbsLtX); PixelToMeasurementUnit(y_buf, ABS_Y(end_y)-nObjAbsLtY); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s", w_buf, h_buf, x_buf, y_buf); ShowMeasureCursor(end_x, end_y, buf, TRUE); MarkRulers(end_x, end_y); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } *pnEndXOff = end_x; *pnEndYOff = end_y; } static int GetCropArea(obj_abs_ltx, obj_abs_lty, pbbox) int obj_abs_ltx, obj_abs_lty; struct BBRec *pbbox; { unsigned int button; int mouse_x=0, mouse_y=0, rc=TRUE; SaveStatusStrings(); Msg(TgLoadString(STID_DRAG_A_RECT_TO_CROP)); SetMouseStatus(TgLoadString(STID_START_CROP_IMAGE), TgLoadString(STID_ABORT_CROP_IMAGE), TgLoadString(STID_ABORT_CROP_IMAGE)); button = DrawWindowLoop(&mouse_x, &mouse_y, cornerCursor, FALSE); if (button == Button1) { int end_x=mouse_x, end_y=mouse_y; ContinueCrop(obj_abs_ltx, obj_abs_lty, mouse_x, mouse_y, &end_x, &end_y); if (pbbox != NULL) { CalcBBox(mouse_x, mouse_y, end_x, end_y, &pbbox->ltx, &pbbox->lty, &pbbox->rbx, &pbbox->rby); } } else { rc = FALSE; } Msg(""); RestoreStatusStrings(); return rc; } void CropImage() { int image_w=0, image_h=0, w, h, short_name, rc, ppm6=FALSE; int ltx=0, lty=0, crop_x=0, crop_y=0, crop_w=0, crop_h=0; int ncolors=0, chars_per_pixel=0, first_pixel_is_bg=0, *pixels=NULL; int saved_ltx=selLtX, saved_lty=selLtY, saved_rbx=selRbX, saved_rby=selRbY; char *color_char=NULL, **color_str=NULL, *xpm_data=NULL, *rest; char szPath[MAXPATHLENGTH+1]; struct ObjRec *obj_ptr=NULL, *saved_top_obj=NULL, *saved_bot_obj=NULL; struct SelRec *top_sel_ptr=NULL, *bot_sel_ptr=NULL; Pixmap pixmap=None, bitmap=None; XImage *image=NULL, *bitmap_image=NULL; struct AttrRec *saved_fattr=NULL, *saved_lattr=NULL; struct BBRec crop_bbox; if (!CheckSelectionForImageProc(CMDID_CROPIMAGE)) { return; } obj_ptr = topSel->obj; if (DoPpm6(obj_ptr->detail.xpm)) { ppm6 = TRUE; } ltx = obj_ptr->obbox.ltx; lty = obj_ptr->obbox.lty; HighLightReverse(); XSync(mainDisplay, False); if (!GetCropArea(ltx, lty, &crop_bbox)) { return; } if (somethingHighLighted) { HighLightReverse(); } XSync(mainDisplay, False); crop_bbox.ltx = ABS_X(crop_bbox.ltx); crop_bbox.lty = ABS_Y(crop_bbox.lty); crop_bbox.rbx = ABS_X(crop_bbox.rbx); crop_bbox.rby = ABS_Y(crop_bbox.rby); if (!BBoxIntersect(crop_bbox, obj_ptr->obbox)) { HighLightForward(); MsgBox(TgLoadString(STID_SEL_AREA_NOT_INTERSECT_IMAGE), TOOL_NAME, INFO_MB); return; } else { crop_bbox.ltx = max(crop_bbox.ltx, obj_ptr->obbox.ltx); crop_bbox.lty = max(crop_bbox.lty, obj_ptr->obbox.lty); crop_bbox.rbx = min(crop_bbox.rbx, obj_ptr->obbox.rbx); crop_bbox.rby = min(crop_bbox.rby, obj_ptr->obbox.rby); crop_x = crop_bbox.ltx-obj_ptr->obbox.ltx; crop_y = crop_bbox.lty-obj_ptr->obbox.lty; crop_w = crop_bbox.rbx-crop_bbox.ltx; crop_h = crop_bbox.rby-crop_bbox.lty; if (crop_x == 0 && crop_y == 0 && crop_w == (obj_ptr->obbox.rbx-obj_ptr->obbox.ltx) && crop_h == (obj_ptr->obbox.rby-obj_ptr->obbox.lty)) { HighLightForward(); return; } if (crop_w == 0 || crop_h == 0) { MsgBox(TgLoadString(STID_XPM_CANT_HAVE_0_W_OR_H), TOOL_NAME, INFO_MB); HighLightForward(); return; } } if (obj_ptr->ctm == NULL) { HighLightForward(); CutXPixmap(NULL, &crop_x, &crop_y, &crop_w, &crop_h); return; } PrepareToReplaceAnObj(obj_ptr); PushPageInfo(); saved_top_obj = topObj; saved_bot_obj = botObj; JustDupSelObj(&top_sel_ptr, &bot_sel_ptr); curPage->top = topObj = top_sel_ptr->obj; curPage->bot = botObj = bot_sel_ptr->obj; CopyObjId(topSel->obj, topObj); CopyObjLocks(topSel->obj, topObj); rc = RegenerateImageFile(szPath, topObj->detail.xpm); DelAllObj(); free(top_sel_ptr); PopPageInfo(); curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; RedrawAnArea(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1)); if (!rc) { HighLightForward(); AbortPrepareCmd(CMD_REPLACE); return; } if (ppm6) { char deflated_fname[MAXPATHLENGTH+1]; struct XPmRec *xpm_ptr=NULL; struct ObjRec *tmp_obj_ptr=NULL; ResetPngHeaderInfo(&gPngHeaderInfo); tmp_obj_ptr = CreatePpmTrueObjFromFile(szPath); if (tmp_obj_ptr != NULL && MkTempFile(deflated_fname, sizeof(deflated_fname), tmpDir, TOOL_NAME) != NULL && DeflateFile(szPath, deflated_fname)) { /* good */ } else { FreeObj(tmp_obj_ptr); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_PPM), szPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); AbortPrepareCmd(CMD_REPLACE); return; } xpm_ptr = tmp_obj_ptr->detail.xpm; xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; xpm_ptr->ppm_data = ReadFileIntoBuf(deflated_fname, &xpm_ptr->ppm_data_size); xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; unlink(deflated_fname); if (tmp_obj_ptr == NULL) { return; } else { struct ObjRec *new_obj_ptr=CutXPixmap(tmp_obj_ptr, &crop_x, &crop_y, &crop_w, &crop_h); if (new_obj_ptr == NULL || new_obj_ptr == tmp_obj_ptr) { FreeObj(tmp_obj_ptr); HighLightForward(); AbortPrepareCmd(CMD_REPLACE); return; } FreeObj(tmp_obj_ptr); UnlinkObj(obj_ptr); FreeObj(obj_ptr); RemoveAllSel(); obj_ptr = new_obj_ptr; } /* drop through */ } else { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadPixmapFile(szPath, &image_w, &image_h, &w, &h, &pixmap, &image, &bitmap, &bitmap_image, &ncolors, &chars_per_pixel, &first_pixel_is_bg, &color_char, &color_str, &pixels, &xpm_data); SetDefaultCursor(mainWindow); ShowCursor(); if (rc == BitmapSuccess) { Pixmap dest_pixmap=None, dest_bitmap=None; XImage *dest_image=NULL, *dest_bitmap_image=NULL; int ok; ok = ExtractPixmap(pixmap, image, bitmap, bitmap_image, crop_x, crop_y, crop_w, crop_h, &dest_pixmap, &dest_image, &dest_bitmap, &dest_bitmap_image); if (ok) { XFreePixmap(mainDisplay, pixmap); XFreePixmap(mainDisplay, bitmap); XDestroyImage(image); XDestroyImage(bitmap_image); pixmap = dest_pixmap; bitmap = dest_bitmap; image = dest_image; bitmap_image = dest_bitmap_image; } else { rc = BitmapFileInvalid; } } if (rc == BitmapSuccess) { saved_fattr = obj_ptr->fattr; saved_lattr = obj_ptr->lattr; obj_ptr->fattr = obj_ptr->lattr = NULL; UnlinkObj(obj_ptr); FreeObj(obj_ptr); RemoveAllSel(); } if ((short_name=IsPrefix(bootDir, szPath, &rest))) ++rest; if (rc != BitmapSuccess) { AbortPrepareCmd(CMD_REPLACE); sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_XPM_FILE), (short_name ? rest : szPath)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); unlink(szPath); return; } obj_ptr = CreateXPmObj(crop_w, crop_h, crop_w, crop_h, pixmap, image, bitmap, bitmap_image, ncolors, chars_per_pixel, first_pixel_is_bg, color_char, color_str, pixels, xpm_data); } unlink(szPath); AddObj(NULL, topObj, obj_ptr); MoveObj(obj_ptr, ltx-obj_ptr->obbox.ltx+crop_x, lty-obj_ptr->obbox.lty+crop_y); if (saved_fattr != NULL) { obj_ptr->fattr = saved_fattr; obj_ptr->lattr = saved_lattr; } RecordReplaceAnObj(topObj); RedrawAnArea(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1)); SelectTopObj(); SetFileModified(TRUE); justDupped = FALSE; if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } sprintf(gszMsgBox, TgLoadString(STID_NEW_XPM_WH_GENERATED), image_w, image_h); Msg(gszMsgBox); } /* ----------------------- GetColor ----------------------- */ static void SetCurrentColor(xpm_ptr, image, bitmap_image, image_x, image_y) struct XPmRec *xpm_ptr; XImage *image, *bitmap_image; int image_x, image_y; { int pixel=(-1); if (bitmap_image == NULL) { pixel = XGetPixel(image, image_x, image_y); } else { if (XGetPixel(bitmap_image, image_x, image_y) == 0) { /* transparent */ } else { pixel = XGetPixel(image, image_x, image_y); } } if (pixel == (-1)) { } else if (DoPpm6(xpm_ptr)) { uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; char color_s[40]; int color_index=0, new_alloc=FALSE; r = (pix & gTrueColorInfo.r_mask) >> gTrueColorInfo.r_shift; g = (pix & gTrueColorInfo.g_mask) >> gTrueColorInfo.g_shift; b = (pix & gTrueColorInfo.b_mask) >> gTrueColorInfo.b_shift; dr = ((double)r) / gTrueColorInfo.dr_maxval * ((double)256); dg = ((double)g) / gTrueColorInfo.dg_maxval * ((double)256); db = ((double)b) / gTrueColorInfo.db_maxval * ((double)256); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; sprintf(color_s, "#%02x%02x%02x", r, g, b); color_index = QuickFindColorIndex(NULL, color_s, &new_alloc, FALSE); if (color_index != INVALID) { ChangeAllSelColor(color_index, FALSE); } } else { int i; for (i=0; i < maxColors; i++) { if (colorPixels[i] == pixel) { struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; topSel = botSel = NULL; ChangeAllSelColor(i, FALSE); topSel = saved_top_sel; botSel = saved_bot_sel; break; } } } } static void DoGetColor(obj_ptr) struct ObjRec *obj_ptr; { int image_w, image_h, done=FALSE; struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; XImage *image, *bitmap_image; image_w = xpm_ptr->image_w; image_h = xpm_ptr->image_h; image = xpm_ptr->image; bitmap_image = xpm_ptr->bitmap_image; if (image == NULL) { image = xpm_ptr->image = XGetImage(mainDisplay, xpm_ptr->pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (image == NULL) FailAllocMessage(); } if (xpm_ptr->bitmap != None && bitmap_image == NULL) { bitmap_image = xpm_ptr->bitmap_image = XGetImage(mainDisplay, xpm_ptr->bitmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (bitmap_image == NULL) FailAllocMessage(); } if (DoPpm6(xpm_ptr)) { if (!InitTrueColorInfo(image, &gTrueColorInfo, image_w)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } SaveStatusStrings(); Msg(TgLoadString(STID_SEL_A_COLOR_TO_USE_AS_CUR)); SetMouseStatus(TgLoadString(STID_SELECT_A_COLOR), TgLoadCachedString(CSTID_FINISH), TgLoadCachedString(CSTID_FINISH)); while (!done) { int mouse_x=0, mouse_y=0; unsigned int button=PickAPoint(&mouse_x, &mouse_y, dripCursor); if (button == Button1) { int abs_x=ABS_X(mouse_x), abs_y=ABS_Y(mouse_y), found=FALSE; int image_x=0, image_y=0; if (obj_ptr->ctm == NULL) { if (abs_x >= obj_ptr->obbox.ltx && abs_y >= obj_ptr->obbox.lty && abs_x < obj_ptr->obbox.rbx && abs_y < obj_ptr->obbox.rby) { image_x = abs_x-obj_ptr->obbox.ltx; image_y = abs_y-obj_ptr->obbox.lty; found = TRUE; } else { SetStringStatus(TgLoadString(STID_SEL_PT_NOT_ON_IMAGE)); } } else { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; double tmp_dx=(double)0, tmp_dy=(double)0; ReverseTransformDoublePointThroughCTM( ((double)(abs_x-obj_ptr->x)+0.5), ((double)(abs_y-obj_ptr->y)+0.5), obj_ptr->ctm, &tmp_dx, &tmp_dy); tmp_dx += (double)(obj_ptr->x-obj_ptr->orig_obbox.ltx); tmp_dy += (double)(obj_ptr->y-obj_ptr->orig_obbox.lty); if (tmp_dx >= ((double)0) && tmp_dx < ((double)xpm_ptr->image_w) && tmp_dy >= ((double)0) && tmp_dy < ((double)xpm_ptr->image_h)) { int tmp_x=(int)tmp_dx, tmp_y=(int)tmp_dy; if (tmp_x < 0) tmp_x = 0; if (tmp_x >= xpm_ptr->image_w) tmp_x = xpm_ptr->image_w-1; if (tmp_y < 0) tmp_y = 0; if (tmp_y >= xpm_ptr->image_h) tmp_y = xpm_ptr->image_h-1; image_x = tmp_x; image_y = tmp_y; found = TRUE; } else { SetStringStatus(TgLoadString(STID_SEL_PT_NOT_ON_IMAGE)); } } if (found) { SetCurrentColor(xpm_ptr, image, bitmap_image, image_x, image_y); } } else { done = TRUE; } } RestoreStatusStrings(); } void GetColor() { int i, pixel; char szBuf[MAXSTRING+1]; struct ObjRec *obj_ptr; strcpy(szBuf, GetImageProcName(CMDID_GETCOLOR)); if (!(curChoice == NOTHING || curChoice == ROTATEMODE) || topSel == NULL || topSel != botSel) { sprintf(gszMsgBox, TgLoadString(STID_ONE_PRIM_FOR_IMAGEPROC_CMD), szBuf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } obj_ptr = topSel->obj; switch (obj_ptr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: sprintf(gszMsgBox, TgLoadString(STID_ONE_PRIM_FOR_IMAGEPROC_CMD), szBuf); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; case OBJ_XPM: HighLightReverse(); XSync(mainDisplay, False); DoGetColor(obj_ptr); if (!somethingHighLighted) HighLightForward(); break; default: pixel = colorPixels[obj_ptr->color]; for (i=0; i < maxColors; i++) { if (colorPixels[i] == pixel) { struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; topSel = botSel = NULL; ChangeAllSelColor(i, FALSE); topSel = saved_top_sel; botSel = saved_bot_sel; break; } } break; } } /* ----------------------- ReplaceColor ----------------------- */ typedef struct tagReplaceColorInfo { int cmdid; int has_pixel_for_trans; int pixel_for_trans; int index_for_trans; struct XPmRec *xpm_ptr; TrueColorInfo tci; } ReplaceColorInfo; static ReplaceColorInfo gReplaceColorInfo; static unsigned int FillReplacePickAPoint(OrigX, OrigY, EndX, EndY, AllowDrag, cursor) int *OrigX, *OrigY, *EndX, *EndY, AllowDrag; /* if AllowDrag is TRUE, EndX and EndY must not be NULL */ Cursor cursor; { unsigned int button=(unsigned int)(-1); int dragging=FALSE; XEvent input; if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonPressMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, cursor, CurrentTime); } for (;;) { XNextEvent(mainDisplay, &input); if (TgWindowIsPinnedMenu(input.xany.window, MENU_COLOR)) { SaveStatusStrings(); TgHandlePinnedMenuEvent(input.xany.window, MENU_COLOR, &input); RestoreStatusStrings(); } else if (TgIsCmdEvent(&input)) { TgHandleCmdEvent(&input); } else if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonPress) { button = input.xbutton.button; *OrigX = input.xbutton.x; *OrigY = input.xbutton.y; if (AllowDrag && button == Button3) { *EndX = *OrigX; *EndY = *OrigY; SelBox(drawWindow, revDefaultGC, *OrigX, *OrigY, *EndX, *EndY); dragging = TRUE; SaveStatusStrings(); SetStringStatus(TgLoadString(STID_DARG_TO_FILL_AN_AREA)); } else { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); return button; } } else if (AllowDrag && dragging && input.type == ButtonRelease) { SelBox(drawWindow, revDefaultGC, *OrigX, *OrigY, *EndX, *EndY); XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); *EndX = input.xbutton.x; *EndY = input.xbutton.y; RestoreStatusStrings(); XSync(mainDisplay, False); return button; } else if (AllowDrag && dragging && input.type == MotionNotify) { SelBox(drawWindow, revDefaultGC, *OrigX, *OrigY, *EndX, *EndY); *EndX = input.xmotion.x; *EndY = input.xmotion.y; SelBox(drawWindow, revDefaultGC, *OrigX, *OrigY, *EndX, *EndY); } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { if (AllowDrag && dragging) { SelBox(drawWindow, revDefaultGC, *OrigX, *OrigY, *EndX, *EndY); RestoreStatusStrings(); } XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); return (unsigned int)(-1); } } } } static void DoReplaceAColor(obj_ptr, image, bitmap_image, image_x, image_y, image_w, image_h) struct ObjRec *obj_ptr; XImage *image, *bitmap_image; int image_x, image_y, image_w, image_h; { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; int pixel=(-1); XColor pixel_color; memset(&pixel_color, 0, sizeof(XColor)); if (bitmap_image == NULL) { pixel = XGetPixel(image, image_x, image_y); } else { if (XGetPixel(bitmap_image, image_x, image_y) == 0) { /* transparent */ } else { pixel = XGetPixel(image, image_x, image_y); } } if (pixel != (-1) && gThreshFillReplaceInfo.use_thresholding) { if (!SetupThreshFillReplaceInfo(&gThreshFillReplaceInfo, pixel, &pixel_color)) { return; } } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if (pixel == (-1)) { } else { int i, r, *pixels=xpm_ptr->pixels, ncolors=xpm_ptr->ncolors; char **color_str=xpm_ptr->color_str; if (gThreshFillReplaceInfo.use_thresholding) { if (fullTrueColorMode) { for (r=0; r < image_h; r++) { int c; for (c=0; c < image_w; c++) { int pix=XGetPixel(image, c, r); if (pix != (-1) && TrueColorPixelWithinRange(pix, &gThreshFillReplaceInfo)) { if (gReplaceColorInfo.cmdid == CMDID_REPLACECOLORWITHTRANS) { XPutPixel(image, c, r, gReplaceColorInfo.pixel_for_trans); XPutPixel(bitmap_image, c, r, 0); } else { XPutPixel(image, c, r, colorPixels[colorIndex]); } } } } } else { for (r=0; r < image_h; r++) { int c; for (c=0; c < image_w; c++) { int pix=XGetPixel(image, c, r), global_color_index=(-1); if (pix != (-1) && HashLookUpInt( &gThreshFillReplaceInfo.hash_table, (char*)(&pix), sizeof(int), &global_color_index)) { if (global_color_index != (-1) && gThreshFillReplaceInfo.within_threshold[global_color_index]) { if (gReplaceColorInfo.cmdid == CMDID_REPLACECOLORWITHTRANS) { XPutPixel(image, c, r, colorPixels[gReplaceColorInfo.index_for_trans]); XPutPixel(bitmap_image, c, r, 0); } else { XPutPixel(image, c, r, colorPixels[colorIndex]); } } } } } if (gThreshFillReplaceInfo.within_threshold != NULL) { free(gThreshFillReplaceInfo.within_threshold); gThreshFillReplaceInfo.within_threshold = NULL; } } } else { if (fullTrueColorMode) { for (r=0; r < image_h; r++) { int c; for (c=0; c < image_w; c++) { if (XGetPixel(image, c, r) == pixel) { if (gReplaceColorInfo.cmdid == CMDID_REPLACECOLORWITHTRANS) { XPutPixel(image, c, r, gReplaceColorInfo.pixel_for_trans); XPutPixel(bitmap_image, c, r, 0); } else { XPutPixel(image, c, r, colorPixels[colorIndex]); } } } } } else { for (r=0; r < image_h; r++) { int c; for (c=0; c < image_w; c++) { if (XGetPixel(image, c, r) == pixel) { if (gReplaceColorInfo.cmdid == CMDID_REPLACECOLORWITHTRANS) { XPutPixel(image, c, r, colorPixels[gReplaceColorInfo.index_for_trans]); XPutPixel(bitmap_image, c, r, 0); } else { XPutPixel(image, c, r, colorPixels[colorIndex]); } } } } } for (i=0; i < ncolors; i++) { if (pixels[i] == pixel) { pixels[i] = colorPixels[colorIndex]; if (color_str[i] != NULL) free(color_str[i]); color_str[i] = UtilStrDup(colorMenuItems[colorIndex]); if (color_str[i] == NULL) FailAllocMessage(); } } } if (xpm_ptr->data != NULL) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "In ReplaceAColor(), unexpected xpm_ptr->data != NULL.\n"); #endif /* _TGIF_DBG */ } } SetDefaultCursor(mainWindow); ShowCursor(); XPutImage(mainDisplay, xpm_ptr->pixmap, xpmGC, image, 0, 0, 0, 0, image_w, image_h); if (bitmap_image != NULL) { XPutImage(mainDisplay, xpm_ptr->bitmap, xbmGC, bitmap_image, 0, 0, 0, 0, image_w, image_h); } if (xpm_ptr->cached_pixmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_pixmap); xpm_ptr->cached_pixmap = None; } if (xpm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_bitmap); xpm_ptr->cached_bitmap = None; } if ((xpm_ptr->real_type == XPM_JPEG || xpm_ptr->real_type == PPM_TRUE) && fullTrueColorMode && HasZlibSupport()) { unsigned int ppm_data_size=0; char tmp_fname[MAXPATHLENGTH], ext[MAXPATHLENGTH]; char *ppm_data=NULL; *tmp_fname = *ext = '\0'; if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { /* print error message? */ return; } if (!DumpXImageToFile(xpm_ptr->image, xpm_ptr->image_w, xpm_ptr->image_h, tmp_fname, ext)) { /* print error message? */ return; } if (strcmp(ext, ".ppm.z") == 0) { char deflated_fname[MAXPATHLENGTH]; snprintf(deflated_fname, sizeof(deflated_fname), "%s%s", tmp_fname, ext); ppm_data = ReadFileIntoBuf(deflated_fname, &ppm_data_size); unlink(deflated_fname); } if (ppm_data != NULL) { if (xpm_ptr->ppm_data != NULL) free(xpm_ptr->ppm_data); if (xpm_ptr->ppm_mask_data != NULL) { free(xpm_ptr->ppm_mask_data); } xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data = ppm_data; xpm_ptr->ppm_data_size = ppm_data_size; xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; } } AdjObjCache(obj_ptr); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; } static int ContinueReplaceColor(obj_ptr) struct ObjRec *obj_ptr; { int done=FALSE, image_w, image_h, changed=FALSE; struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; XImage *image, *bitmap_image; xpm_ptr = obj_ptr->detail.xpm; image_w = xpm_ptr->image_w; image_h = xpm_ptr->image_h; image = xpm_ptr->image; bitmap_image = xpm_ptr->bitmap_image; if (image == NULL) { image = xpm_ptr->image = XGetImage(mainDisplay, xpm_ptr->pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (image == NULL) FailAllocMessage(); } if (xpm_ptr->bitmap != None && bitmap_image == NULL) { bitmap_image = xpm_ptr->bitmap_image = XGetImage(mainDisplay, xpm_ptr->bitmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (bitmap_image == NULL) FailAllocMessage(); } SaveStatusStrings(); Msg(TgLoadString(STID_SEL_A_COLOR_TO_BE_REPLACED)); SetMouseStatus(TgLoadString(STID_SEL_A_COLOR_TO_REPLACE), TgLoadCachedString(CSTID_FINISH), TgLoadCachedString(CSTID_FINISH)); while (!done) { int mouse_x=0, mouse_y=0; unsigned int button=FillReplacePickAPoint(&mouse_x, &mouse_y, NULL, NULL, FALSE, floodCursor); if (button == Button1) { int abs_x=ABS_X(mouse_x), abs_y=ABS_Y(mouse_y), found=FALSE; int image_x=0, image_y=0; if (obj_ptr->ctm == NULL) { if (abs_x >= obj_ptr->obbox.ltx && abs_y >= obj_ptr->obbox.lty && abs_x < obj_ptr->obbox.rbx && abs_y < obj_ptr->obbox.rby) { image_x = abs_x-obj_ptr->obbox.ltx; image_y = abs_y-obj_ptr->obbox.lty; if (image_x >= 0 && image_y >= 0 && image_x < image_w && image_y < image_h) { found = TRUE; } } } else { double image_dx=(double)0, image_dy=(double)0; ReverseTransformDoublePointThroughCTM( ((double)(abs_x-obj_ptr->x)+0.5), ((double)(abs_y-obj_ptr->y)+0.5), obj_ptr->ctm, &image_dx, &image_dy); image_dx += (double)(obj_ptr->x-obj_ptr->orig_obbox.ltx); image_dy += (double)(obj_ptr->y-obj_ptr->orig_obbox.lty); if (image_dx >= ((double)0) && image_dy >= ((double)0) && image_dx < ((double)image_w) && image_dy < ((double)image_h)) { image_x = (int)image_dx; image_y = (int)image_dy; if (image_x < 0) image_x = 0; if (image_x >= image_w) image_x = image_w-1; if (image_y < 0) image_y = 0; if (image_y >= image_h) image_y = image_h-1; found = TRUE; } } if (found) { changed = TRUE; if (somethingHighLighted) HighLightReverse(); DoReplaceAColor(obj_ptr, image, bitmap_image, image_x, image_y, image_w, image_h); if (!somethingHighLighted) HighLightForward(); } else { SetStringStatus(TgLoadString(STID_SEL_PT_NOT_ON_IMAGE)); } } else { done = TRUE; } } RestoreStatusStrings(); return changed; } void ReplaceColor() { struct ObjRec *obj_ptr=NULL; unsigned char trans_color_r='\0', trans_color_g='\0', trans_color_b='\0'; if (!CheckSelectionForImageProc(CMDID_REPLACECOLOR)) { return; } obj_ptr = topSel->obj; if (ObjHasTrueColorTransPixel(obj_ptr, &trans_color_r, &trans_color_g, &trans_color_b)) { if (CurColorIsTranscolor(trans_color_r, trans_color_g, trans_color_b)) { sprintf(gszMsgBox, TgLoadString(STID_CUR_COLOR_IS_TRANS_PIXEL), colorMenuItems[colorIndex], GetImageProcName(CMDID_REPLACECOLOR)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } memset(&gReplaceColorInfo, 0, sizeof(ReplaceColorInfo)); gReplaceColorInfo.cmdid = CMDID_REPLACECOLOR; if (somethingHighLighted) HighLightReverse(); XSync(mainDisplay, False); PrepareToReplaceAnObj(obj_ptr); ResetThreshFillReplaceInfo(); if (!ContinueReplaceColor(obj_ptr)) { AbortPrepareCmd(CMD_REPLACE); } else { RecordReplaceAnObj(obj_ptr); } if (!somethingHighLighted) HighLightForward(); } /* ----------------------- ReplaceColorWithTrans ----------------------- */ static int SetupReplaceColorInfo(obj_ptr, prci) struct ObjRec *obj_ptr; ReplaceColorInfo *prci; { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; int i=0, ncolors=xpm_ptr->ncolors, index=(-1); int image_w=xpm_ptr->image_w, image_h=xpm_ptr->image_h; unsigned char trans_color_r='\0', trans_color_g='\0', trans_color_b='\0'; XImage *image=NULL; TrueColorInfo *ptci=(&prci->tci); prci->xpm_ptr = xpm_ptr; switch (xpm_ptr->real_type) { case XPM_XPM: if (!ObjHasIndexedTransPixel(obj_ptr, &index)) { int chars_per_pixel=xpm_ptr->chars_per_pixel; xpm_ptr->pixels = (int*)realloc(xpm_ptr->pixels, sizeof(int)*(ncolors+1)); if (xpm_ptr->pixels == NULL) FailAllocMessage(); xpm_ptr->pixels[ncolors] = (-1); xpm_ptr->color_str = (char**)realloc(xpm_ptr->color_str, sizeof(char*)*(ncolors+1)); if (xpm_ptr->color_str == NULL) FailAllocMessage(); xpm_ptr->color_str[ncolors] = UtilStrDup("None"); if (xpm_ptr->color_str[ncolors] == NULL) FailAllocMessage(); if (chars_per_pixel == 1 && ncolors >= 20) { /* needs to go from 1 chars_per_pixel to 2 chars_per_pixel */ char *color_char=(char*)malloc(((ncolors+1)<<1)*sizeof(char)); if (color_char == NULL) FailAllocMessage(); for (i=0; i < ncolors+1; i++) { if (i == 0 && xpm_ptr->color_char[0] == '`') { color_char[i<<1] = color_char[(i<<1)+1] = '`'; } else { color_char[i<<1] = (char)(((int)('a'))+(int)(i/10)); color_char[(i<<1)+1] = (char)(((int)('0'))+(int)(i%10)); } } free(xpm_ptr->color_char); xpm_ptr->color_char = color_char; xpm_ptr->chars_per_pixel = 2; } else { char *color_char=NULL; xpm_ptr->color_char = color_char = (char*)realloc(xpm_ptr->color_char, sizeof(char)*chars_per_pixel*(ncolors+1)); if (color_char == NULL) FailAllocMessage(); if (chars_per_pixel == 1) { for (i=0; i < ncolors+1; i++) { if (i == 0 && xpm_ptr->color_char[0] == '`') { color_char[i] = '`'; } else { color_char[i] = (char)(((int)('a'))+i-1); } } } else { for (i=0; i < ncolors+1; i++) { if (i == 0 && xpm_ptr->color_char[0] == '`' && xpm_ptr->color_char[1] == '`') { color_char[i<<1] = color_char[(i<<1)+1] = '`'; } else { color_char[i<<1] = (char)(((int)('a'))+(int)(i/10)); color_char[(i<<1)+1] = (char)(((int)('0'))+(int)(i%10)); } } } } xpm_ptr->ncolors++; index = ncolors; } prci->index_for_trans = index; prci->has_pixel_for_trans = TRUE; break; case XPM_JPEG: break; case PPM_TRUE: image = XGetImage(mainDisplay, xpm_ptr->pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (image == NULL || !InitTrueColorInfo(image, &prci->tci, image_w)) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_GET_IMAGE_OF_SIZE), image_w, image_h); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); XDestroyImage(image); return FALSE; } if (ObjHasTrueColorTransPixel(obj_ptr, &trans_color_r, &trans_color_g, &trans_color_b)) { unsigned int r=(unsigned int)trans_color_r; unsigned int g=(unsigned int)trans_color_g; unsigned int b=(unsigned int)trans_color_b; prci->pixel_for_trans = ((r << ptci->r_shift) & mainVisual->red_mask) | ((g << ptci->g_shift) & mainVisual->green_mask) | ((b << ptci->b_shift) & mainVisual->blue_mask) ; } else { unsigned char has_r[256], has_g[256], has_b[256]; unsigned char can_have_r[256], can_have_g[256], can_have_b[256]; int row=0, found=FALSE; XImage *image=XGetImage(mainDisplay, xpm_ptr->pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); unsigned int r_maxval=((ptci->r_mask)>>ptci->r_shift); unsigned int g_maxval=((ptci->g_mask)>>ptci->g_shift); unsigned int b_maxval=((ptci->b_mask)>>ptci->b_shift); memset(has_r, 0, sizeof(256*sizeof(unsigned char))); memset(has_g, 0, sizeof(256*sizeof(unsigned char))); memset(has_b, 0, sizeof(256*sizeof(unsigned char))); memset(can_have_r, 0, sizeof(256*sizeof(unsigned char))); memset(can_have_g, 0, sizeof(256*sizeof(unsigned char))); memset(can_have_b, 0, sizeof(256*sizeof(unsigned char))); for (i=0; i < r_maxval; i++) { double dval=((double)i)/ptci->dr_maxval_div255; unsigned int uval=round(dval); if (uval > 255) uval = 255; can_have_r[uval] = 1; } for (i=0; i < g_maxval; i++) { double dval=((double)i)/ptci->dg_maxval_div255; unsigned int uval=round(dval); if (uval > 255) uval = 255; can_have_g[uval] = 1; } for (i=0; i < b_maxval; i++) { double dval=((double)i)/ptci->db_maxval_div255; unsigned int uval=round(dval); if (uval > 255) uval = 255; can_have_b[uval] = 1; } for (row=0; row < image_h; row++) { int col=0; for (col=0; col < image_w; col++) { int pixel=XGetPixel(image, col, row); uint32_t pix=(uint32_t)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; r = (pix & ptci->r_mask) >> ptci->r_shift; g = (pix & ptci->g_mask) >> ptci->g_shift; b = (pix & ptci->b_mask) >> ptci->b_shift; dr = ((double)r) / ptci->dr_maxval_div255; dg = ((double)g) / ptci->dg_maxval_div255; db = ((double)b) / ptci->db_maxval_div255; r = round(dr); g = round(dg); b = round(db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; if (r == 255 && g == 255) has_b[b] = 1; if (r == 255 && b == 255) has_g[g] = 1; if (g == 255 && b == 255) has_r[r] = 1; } } XDestroyImage(image); for (i=255; i >= 0 && !found; i--) { if (can_have_r[i] && !has_r[i]) { prci->pixel_for_trans = ((i << ptci->r_shift) & mainVisual->red_mask) | ((255 << ptci->g_shift) & mainVisual->green_mask) | ((255 << ptci->b_shift) & mainVisual->blue_mask) ; found = TRUE; } } for (i=255; i >= 0 && !found; i--) { if (can_have_g[i] && !has_g[i]) { prci->pixel_for_trans = ((i << ptci->g_shift) & mainVisual->green_mask); found = TRUE; } } for (i=255; i >= 0 && !found; i--) { if (can_have_b[i] && !has_b[i]) { prci->pixel_for_trans = ((i << ptci->b_shift) & mainVisual->blue_mask); found = TRUE; } } if (!found) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_CANNOT_FIND_GOOD_TRANSPIX)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } prci->has_pixel_for_trans = TRUE; break; } if (!prci->has_pixel_for_trans) { return FALSE; } #ifdef _TGIF_DBG /* debug, do not translate */ #ifdef NOT_DEFINED if (prci->xpm_ptr->real_type == XPM_XPM) { fprintf(stderr, "index_for_trans = %1d\n", prci->index_for_trans); } else { fprintf(stderr, "pixel_for_trans = %08x\n", prci->pixel_for_trans); } #endif /* NOT_DEFINED */ #endif /* _TGIF_DBG */ return TRUE; } void ReplaceColorWithTrans() { struct ObjRec *obj_ptr=NULL; if (!CheckSelectionForImageProc(CMDID_REPLACECOLORWITHTRANS)) { return; } obj_ptr = topSel->obj; memset(&gReplaceColorInfo, 0, sizeof(ReplaceColorInfo)); gReplaceColorInfo.cmdid = CMDID_REPLACECOLORWITHTRANS; if (!SetupReplaceColorInfo(obj_ptr, &gReplaceColorInfo)) { return; } if (somethingHighLighted) HighLightReverse(); XSync(mainDisplay, False); PrepareToReplaceAnObj(obj_ptr); ResetThreshFillReplaceInfo(); if (!ContinueReplaceColor(obj_ptr)) { AbortPrepareCmd(CMD_REPLACE); } else { RecordReplaceAnObj(obj_ptr); } if (!somethingHighLighted) HighLightForward(); } /* ----------------------- FloodFill ----------------------- */ #define DIR_NONE 0 #define DIR_UP 1 #define DIR_RIGHT 2 #define DIR_DOWN 3 #define DIR_LEFT 4 /* * 1 * ^ * | * 4 <- 0 -> 2 * | * v * 3 */ static int gnPixelToFill=(-1); typedef struct tagCell { int row; int col; int dir; /* direction where it came from */ } Cell; #define CELL_NOTVISITED(map,c,r,image_w) (map[(c)+(r)*(image_w)]==0) static int SelectThisPixelForFloodFill(c, r, pixel, image) int c, r, pixel; XImage *image; { int pix=XGetPixel(image, c, r); if (gThreshFillReplaceInfo.use_thresholding) { if (fullTrueColorMode) { if (pix != (-1) && TrueColorPixelWithinRange(pix, &gThreshFillReplaceInfo)) { /* skip */ } else { return FALSE; } } else { int global_color_index=(-1); if (pix != (-1) && HashLookUpInt( &gThreshFillReplaceInfo.hash_table, (char*)(&pix), sizeof(int), &global_color_index)) { if (global_color_index != (-1) && gThreshFillReplaceInfo.within_threshold[global_color_index]) { /* skip */ } else { return FALSE; } } else { return FALSE; } } } else { if (pix != pixel) { return FALSE; } } return TRUE; } static void FloodFillAddToQueue(plist, c, r, dir, pbbox) CVList *plist; int c, r, dir; struct BBRec *pbbox; { Cell *cell=(Cell*)malloc(sizeof(Cell)); if (cell == NULL) FailAllocMessage(); memset(cell, 0, sizeof(Cell)); cell->row = r; cell->col = c; cell->dir = dir; ListAppend(plist, cell); if (c < pbbox->ltx) pbbox->ltx = c; if (c > pbbox->rbx) pbbox->rbx = c; if (r < pbbox->lty) pbbox->lty = r; if (r > pbbox->rby) pbbox->rby = r; } static void FloodFillBFS(image, pixel, image_w, image_h, plist, map, pbbox) XImage *image; int pixel, image_w, image_h; CVList *plist; unsigned char *map; struct BBRec *pbbox; { while (!ListEmpty(plist)) { CVListElem *elem=ListFirst(plist); Cell *cell=(Cell*)(elem->obj); int c=cell->col, r=cell->row; /* this pixel must be already selected */ int dir=cell->dir; int next_r=0, next_c=0, next_dir=0; ListUnlink(plist, elem); free(elem); free(cell); if (dir != DIR_DOWN && r-1 >= 0) { next_c = c; next_r = r-1; next_dir = DIR_UP; if (CELL_NOTVISITED(map,next_c,next_r,image_w)) { if (SelectThisPixelForFloodFill(next_c, next_r, pixel, image)) { map[next_c+(next_r*image_w)] = 1; FloodFillAddToQueue(plist, next_c, next_r, next_dir, pbbox); } else { map[next_c+(next_r*image_w)] = (-1); } } } if (dir != DIR_LEFT && c+1 < image_w) { next_c = c+1; next_r = r; next_dir = DIR_RIGHT; if (CELL_NOTVISITED(map,next_c,next_r,image_w)) { if (SelectThisPixelForFloodFill(next_c, next_r, pixel, image)) { map[next_c+(next_r*image_w)] = 1; FloodFillAddToQueue(plist, next_c, next_r, next_dir, pbbox); } else { map[next_c+(next_r*image_w)] = (-1); } } } if (dir != DIR_UP && r+1 < image_h) { next_c = c; next_r = r+1; next_dir = DIR_DOWN; if (CELL_NOTVISITED(map,next_c,next_r,image_w)) { if (SelectThisPixelForFloodFill(next_c, next_r, pixel, image)) { map[next_c+(next_r*image_w)] = 1; FloodFillAddToQueue(plist, next_c, next_r, next_dir, pbbox); } else { map[next_c+(next_r*image_w)] = (-1); } } } if (dir != DIR_RIGHT && c-1 >= 0) { next_c = c-1; next_r = r; next_dir = DIR_LEFT; if (CELL_NOTVISITED(map,next_c,next_r,image_w)) { if (SelectThisPixelForFloodFill(next_c, next_r, pixel, image)) { map[next_c+(next_r*image_w)] = 1; FloodFillAddToQueue(plist, next_c, next_r, next_dir, pbbox); } else { map[next_c+(next_r*image_w)] = (-1); } } } } } static void CalcFloodFill(c, r, pixel, image, image_w, image_h, dir, map, pbbox) int c, r, pixel, image_w, image_h, dir; XImage *image; unsigned char *map; struct BBRec *pbbox; { CVList list; CVListInit(&list); FloodFillAddToQueue(&list, c, r, dir, pbbox); FloodFillBFS(image, pixel, image_w, image_h, &list, map, pbbox); } static void DoFloodFill(image, image_w, map, pbbox) XImage *image; int image_w; unsigned char *map; struct BBRec *pbbox; { int r=0; for (r=pbbox->lty; r <= pbbox->rby; r++) { int c=0; for (c=pbbox->ltx; c <= pbbox->rbx; c++) { if (map[c+r*image_w] == 1) { XPutPixel(image, c, r, gnPixelToFill); } } } } static void StartFloodFill(obj_ptr, image, bitmap_image, image_x, image_y, image_w, image_h, do_flood_fill) struct ObjRec *obj_ptr; XImage *image, *bitmap_image; int image_x, image_y, image_w, image_h, do_flood_fill; { struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; int pixel=(-1); XColor pixel_color; memset(&pixel_color, 0, sizeof(XColor)); if (bitmap_image == NULL) { pixel = XGetPixel(image, image_x, image_y); } else { if (XGetPixel(bitmap_image, image_x, image_y) == 0) { /* transparent */ } else { pixel = XGetPixel(image, image_x, image_y); } } if (do_flood_fill && pixel != (-1) && gThreshFillReplaceInfo.use_thresholding) { if (!SetupThreshFillReplaceInfo(&gThreshFillReplaceInfo, pixel, &pixel_color)) { return; } } gnPixelToFill = colorPixels[colorIndex]; if (pixel == (-1)) { } else if (gnPixelToFill != pixel) { int i, *pixels=xpm_ptr->pixels, ncolors=xpm_ptr->ncolors, found=FALSE; if (do_flood_fill) { struct BBRec bbox; unsigned char *map=(unsigned char *)malloc(image_h*image_w*sizeof(unsigned char)); if (map == NULL) FailAllocMessage(); /* 0 means not visited, 1 means update pixel, otherwise, don't update */ memset(map, 0, image_h*image_w*sizeof(unsigned char)); map[image_x+image_y*image_w] = 1; bbox.ltx = bbox.rbx = image_x; bbox.lty = bbox.rby = image_y; CalcFloodFill(image_x, image_y, pixel, image, image_w, image_h, 0, map, &bbox); DoFloodFill(image, image_w, map, &bbox); free(map); if (gThreshFillReplaceInfo.within_threshold != NULL) { free(gThreshFillReplaceInfo.within_threshold); gThreshFillReplaceInfo.within_threshold = NULL; } } else { XPutPixel(image, image_x, image_y, gnPixelToFill); } for (i=0; i < ncolors; i++) { if (pixels[i] == gnPixelToFill) { found = TRUE; } } if (!found && xpm_ptr->real_type == XPM_XPM) { int chars_per_pixel=xpm_ptr->chars_per_pixel; xpm_ptr->pixels = (int*)realloc(xpm_ptr->pixels, sizeof(int)*(ncolors+1)); if (xpm_ptr->pixels == NULL) FailAllocMessage(); xpm_ptr->pixels[ncolors] = colorPixels[colorIndex]; xpm_ptr->color_str = (char**)realloc(xpm_ptr->color_str, sizeof(char*)*(ncolors+1)); if (xpm_ptr->color_str == NULL) FailAllocMessage(); xpm_ptr->color_str[ncolors] = UtilStrDup(colorMenuItems[colorIndex]); if (xpm_ptr->color_str[ncolors] == NULL) FailAllocMessage(); if (chars_per_pixel == 1 && ncolors >= 20) { /* needs to go from 1 chars_per_pixel to 2 chars_per_pixel */ char *color_char=(char*)malloc(((ncolors+1)<<1)*sizeof(char)); if (color_char == NULL) FailAllocMessage(); for (i=0; i < ncolors+1; i++) { if (i == 0 && xpm_ptr->color_char[0] == '`') { color_char[i<<1] = color_char[(i<<1)+1] = '`'; } else { color_char[i<<1] = (char)(((int)('a'))+(int)(i/10)); color_char[(i<<1)+1] = (char)(((int)('0'))+(int)(i%10)); } } free(xpm_ptr->color_char); xpm_ptr->color_char = color_char; xpm_ptr->chars_per_pixel = 2; } else { char *color_char; xpm_ptr->color_char = color_char = (char*)realloc(xpm_ptr->color_char, sizeof(char)*chars_per_pixel*(ncolors+1)); if (color_char == NULL) FailAllocMessage(); if (chars_per_pixel == 1) { for (i=0; i < ncolors+1; i++) { if (i == 0 && xpm_ptr->color_char[0] == '`') { color_char[i] = '`'; } else { color_char[i] = (char)(((int)('a'))+i-1); } } } else { for (i=0; i < ncolors+1; i++) { if (i == 0 && xpm_ptr->color_char[0] == '`' && xpm_ptr->color_char[1] == '`') { color_char[i<<1] = color_char[(i<<1)+1] = '`'; } else { color_char[i<<1] = (char)(((int)('a'))+(int)(i/10)); color_char[(i<<1)+1] = (char)(((int)('0'))+(int)(i%10)); } } } } xpm_ptr->ncolors++; } if (xpm_ptr->data != NULL) { #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "In FloodFill(), unexpected xpm_ptr->data != NULL.\n"); #endif /* _TGIF_DBG */ } } } static int TryFloodFill(obj_ptr, image_w, image_h, image, bitmap_image, button, mouse_x, mouse_y) struct ObjRec *obj_ptr; int image_w, image_h, mouse_x, mouse_y; XImage *image, *bitmap_image; unsigned int button; { int changed=FALSE, abs_x=ABS_X(mouse_x), abs_y=ABS_Y(mouse_y), found=FALSE; int image_x=0, image_y=0; if (obj_ptr->ctm == NULL) { if (abs_x >= obj_ptr->obbox.ltx && abs_y >= obj_ptr->obbox.lty && abs_x < obj_ptr->obbox.rbx && abs_y < obj_ptr->obbox.rby) { image_x = abs_x-obj_ptr->obbox.ltx; image_y = abs_y-obj_ptr->obbox.lty; if (image_x >= 0 && image_y >= 0 && image_x < image_w && image_y < image_h) { found = TRUE; } } } else { double image_dx=(double)0, image_dy=(double)0; ReverseTransformDoublePointThroughCTM( ((double)(abs_x-obj_ptr->x)+0.5), ((double)(abs_y-obj_ptr->y)+0.5), obj_ptr->ctm, &image_dx, &image_dy); image_dx += (double)(obj_ptr->x-obj_ptr->orig_obbox.ltx); image_dy += (double)(obj_ptr->y-obj_ptr->orig_obbox.lty); if (image_dx >= ((double)0) && image_dy >= ((double)0) && image_dx < ((double)image_w) && image_dy < ((double)image_h)) { image_x = (int)image_dx; image_y = (int)image_dy; if (image_x < 0) image_x = 0; if (image_x >= image_w) image_x = image_w-1; if (image_y < 0) image_y = 0; if (image_y >= image_h) image_y = image_h-1; found = TRUE; } } if (found) { changed = TRUE; if (somethingHighLighted) HighLightReverse(); StartFloodFill(obj_ptr, image, bitmap_image, image_x, image_y, image_w, image_h, button==Button1); if (!somethingHighLighted) HighLightForward(); } return changed; } static void GetUntransformedPoint(obj_ptr, abs_x, abs_y, v) struct ObjRec *obj_ptr; int abs_x, abs_y; IntPoint *v; { double image_dx=(double)0, image_dy=(double)0; ReverseTransformDoublePointThroughCTM( ((double)(abs_x-obj_ptr->x)+0.5), ((double)(abs_y-obj_ptr->y)+0.5), obj_ptr->ctm, &image_dx, &image_dy); image_dx += (double)(obj_ptr->x-obj_ptr->orig_obbox.ltx); image_dy += (double)(obj_ptr->y-obj_ptr->orig_obbox.lty); v->x = (int)image_dx; v->y = (int)image_dy; } static int ContinueFloodFill(obj_ptr) struct ObjRec *obj_ptr; { int done=FALSE, image_w, image_h, changed=FALSE; struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; XImage *image=NULL, *bitmap_image=NULL; xpm_ptr = obj_ptr->detail.xpm; image_w = xpm_ptr->image_w; image_h = xpm_ptr->image_h; image = xpm_ptr->image; bitmap_image = xpm_ptr->bitmap_image; if (image == NULL) { image = xpm_ptr->image = XGetImage(mainDisplay, xpm_ptr->pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (image == NULL) FailAllocMessage(); } if (xpm_ptr->bitmap != None && bitmap_image == NULL) { bitmap_image = xpm_ptr->bitmap_image = XGetImage(mainDisplay, xpm_ptr->bitmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (bitmap_image == NULL) FailAllocMessage(); } SaveStatusStrings(); sprintf(gszMsgBox, " %s", TgLoadString(STID_ESC_TO_FINISH)); TwoLineMsg(TgLoadString(STID_BTN1_FLOODFILL_BTN3_SET_COLOR), gszMsgBox); SetMouseStatus(TgLoadString(STID_FLOOD_FILL), TgLoadCachedString(CSTID_FINISH), TgLoadString(STID_SET_A_PIXEL)); while (!done) { int mouse_x=0, mouse_y=0, mouse_end_x=0, mouse_end_y=0; unsigned int button=FillReplacePickAPoint(&mouse_x, &mouse_y, &mouse_end_x, &mouse_end_y, TRUE, floodCursor); SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); if (button == Button1) { changed = TryFloodFill(obj_ptr, image_w, image_h, image, bitmap_image, button, mouse_x, mouse_y); } else if (button == Button3) { if (mouse_x == mouse_end_x && mouse_y == mouse_end_y) { changed = TryFloodFill(obj_ptr, image_w, image_h, image, bitmap_image, button, mouse_x, mouse_y); } else if (obj_ptr->ctm == NULL) { int r=0; struct BBRec bbox; SetBBRec(&bbox, mouse_x, mouse_y, mouse_end_x, mouse_end_y); for (r=bbox.lty; r < bbox.rby; r++) { int c=0; for (c=bbox.ltx; c < bbox.rbx; c++) { if (TryFloodFill(obj_ptr, image_w, image_h, image, bitmap_image, button, c, r)) { changed = TRUE; } } } } else { int r=0, abs_x=ABS_X(mouse_x), abs_y=ABS_Y(mouse_y); int abs_end_x=ABS_X(mouse_end_x), abs_end_y=ABS_Y(mouse_end_y); int ltx=0, lty=0, rbx=0, rby=0; IntPoint ivs[6]; GetUntransformedPoint(obj_ptr, abs_x, abs_y, &ivs[0]); GetUntransformedPoint(obj_ptr, abs_x, abs_end_y, &ivs[1]); GetUntransformedPoint(obj_ptr, abs_end_x, abs_end_y, &ivs[2]); GetUntransformedPoint(obj_ptr, abs_end_x, abs_y, &ivs[3]); memcpy(&ivs[4], &ivs[0], sizeof(IntPoint)); ltx = min(min(ivs[0].x, ivs[1].x),min(ivs[2].x, ivs[3].x)); lty = min(min(ivs[0].y, ivs[1].y),min(ivs[2].y, ivs[3].y)); rbx = max(max(ivs[0].x, ivs[1].x),max(ivs[2].x, ivs[3].x)); rby = max(max(ivs[0].y, ivs[1].y),max(ivs[2].y, ivs[3].y)); for (r=lty; r < rby; r++) { int c=0; if (r < 0 || r >= image_h) continue; for (c=ltx; c < rbx; c++) { if (c < 0 || c >= image_w) continue; if (PointInIntPolygon(c, r, 5, ivs)) { StartFloodFill(obj_ptr, image, bitmap_image, c, r, c, r, FALSE); changed = TRUE; } } } } } else { done = TRUE; } if (!done) { if (changed) { XPutImage(mainDisplay, xpm_ptr->pixmap, xpmGC, image, 0, 0, 0, 0, image_w, image_h); if (bitmap_image != NULL) { XPutImage(mainDisplay, xpm_ptr->bitmap, xbmGC, bitmap_image, 0, 0, 0, 0, image_w, image_h); } if (xpm_ptr->cached_pixmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_pixmap); xpm_ptr->cached_pixmap = None; } if (xpm_ptr->cached_bitmap != None) { XFreePixmap(mainDisplay, xpm_ptr->cached_bitmap); xpm_ptr->cached_bitmap = None; } if ((xpm_ptr->real_type == XPM_JPEG || xpm_ptr->real_type == PPM_TRUE) && fullTrueColorMode && HasZlibSupport()) { unsigned int ppm_data_size=0; char tmp_fname[MAXPATHLENGTH], ext[MAXPATHLENGTH]; char *ppm_data=NULL; *tmp_fname = *ext = '\0'; if (MkTempFile(tmp_fname, sizeof(tmp_fname), tmpDir, TOOL_NAME) == NULL) { /* print error message? */ return FALSE; } if (!DumpXImageToFile(xpm_ptr->image, xpm_ptr->image_w, xpm_ptr->image_h, tmp_fname, ext)) { /* print error message? */ return FALSE; } if (strcmp(ext, ".ppm.z") == 0) { char deflated_fname[MAXPATHLENGTH]; snprintf(deflated_fname, sizeof(deflated_fname), "%s%s", tmp_fname, ext); ppm_data = ReadFileIntoBuf(deflated_fname, &ppm_data_size); unlink(deflated_fname); } if (ppm_data != NULL) { if (xpm_ptr->ppm_data != NULL) free(xpm_ptr->ppm_data); if (xpm_ptr->ppm_mask_data != NULL) { free(xpm_ptr->ppm_mask_data); } xpm_ptr->real_type = PPM_TRUE; xpm_ptr->ppm_data = ppm_data; xpm_ptr->ppm_data_size = ppm_data_size; xpm_ptr->ppm_mask_data = NULL; xpm_ptr->ppm_mask_size = 0; xpm_ptr->ppm_data_compress = PPM_DATA_DEFLATED; } } AdjObjCache(obj_ptr); if (somethingHighLighted) HighLightReverse(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); if (!somethingHighLighted) HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } else { SetStringStatus(TgLoadString(STID_SEL_PT_NOT_ON_IMAGE)); } } SetDefaultCursor(mainWindow); ShowCursor(); } RestoreStatusStrings(); return changed; } void FloodFill() { struct ObjRec *obj_ptr=NULL; unsigned char trans_color_r='\0', trans_color_g='\0', trans_color_b='\0'; if (!CheckSelectionForImageProc(CMDID_FLOODFILL)) { return; } obj_ptr = topSel->obj; if (ObjHasTrueColorTransPixel(obj_ptr, &trans_color_r, &trans_color_g, &trans_color_b)) { if (CurColorIsTranscolor(trans_color_r, trans_color_g, trans_color_b)) { sprintf(gszMsgBox, TgLoadString(STID_CUR_COLOR_IS_TRANS_PIXEL), colorMenuItems[colorIndex], GetImageProcName(CMDID_FLOODFILL)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } if (somethingHighLighted) HighLightReverse(); XSync(mainDisplay, False); PrepareToReplaceAnObj(obj_ptr); ResetThreshFillReplaceInfo(); if (ContinueFloodFill(obj_ptr)) { RecordReplaceAnObj(obj_ptr); } else { AbortPrepareCmd(CMD_REPLACE); } if (!somethingHighLighted) HighLightForward(); } /* ----------------------- ToggleFloodReplaceColorThreshold ----------------------- */ void ToggleFloodReplaceColorThreshold() { threshFillReplaceEnabled = !threshFillReplaceEnabled; if (threshFillReplaceEnabled) { sprintf(gszMsgBox, TgLoadString(STID_FLOOD_REPLACE_ENABLED), fillReplaceRedThresh, fillReplaceGreenThresh, fillReplaceBlueThresh); Msg(gszMsgBox); } else { sprintf(gszMsgBox, TgLoadString(STID_FLOOD_REPLACE_DISABLED)); Msg(gszMsgBox); } } /* ----------------------- SetFloodReplaceColorThreshold ----------------------- */ void SetFloodReplaceColorThreshold() { char spec[MAXSTRING]; *spec = '\0'; sprintf(gszMsgBox, TgLoadString(STID_SET_FLOOD_REPLACE_THRESH), fillReplaceRedThresh, fillReplaceGreenThresh, fillReplaceBlueThresh); if (Dialog(gszMsgBox, NULL, spec) == INVALID) return; UtilTrimBlanks(spec); if (*spec == '\0') return; if (ParseThreshFillReplaceSpec(spec)) { sprintf(gszMsgBox, TgLoadString(STID_FLOOD_REPLACE_THRESH_SET_TO), fillReplaceRedThresh, fillReplaceGreenThresh, fillReplaceBlueThresh); Msg(gszMsgBox); } } /* ----------------------- CreateContour ----------------------- */ /*------------------------------------------------*/ /* the contour code is adapted from Tim Feldman's */ /* contour code in Graphics Gem III */ /*------------------------------------------------*/ typedef struct CDirInfo { /* 5 6 7 */ /* 4 0 */ /* 3 2 1 */ short dir; struct CDirInfo *next; } CDirInfoPtr; static struct CDirInfo *topOfChain=NULL, *botOfChain=NULL; static int gnContourX=0, gnContourY=0; static int gnContourW=0, gnContourH=0; static unsigned short gnContourRed=0, gnContourGreen=0, gnContourBlue=0; static int **gnaContourPixels=NULL; static XImage *gContourImage=NULL, *gContourBitmapImage=NULL; static struct ObjRec *gpContourObj=NULL; static void CleanUpContour() { if (gnaContourPixels != NULL) { int i; for (i=0; i < gnContourH; i++) { if (gnaContourPixels[i] != NULL) { free(gnaContourPixels[i]); } else { break; } } free(gnaContourPixels); } gnaContourPixels = NULL; for ( ; topOfChain != NULL; topOfChain=botOfChain) { botOfChain = topOfChain->next; free(topOfChain); } topOfChain = botOfChain = NULL; } static int OnContour(x, y) int x, y; { if (x >= 0 && x < gnContourW && y >= 0 && y < gnContourH) { int index; if (gnaContourPixels[y][x] == BAD) { gnaContourPixels[y][x] = XGetPixel(gContourImage, x, y); } index = GetIndexOfPixel(gnaContourPixels[y][x]); if (tgifColors[index].red == gnContourRed && tgifColors[index].green == gnContourGreen && tgifColors[index].blue == gnContourBlue) { return TRUE; } } return FALSE; } static int ProbeContour(x, y, dir, pn_new_x, pn_new_y) int x, y, dir, *pn_new_x, *pn_new_y; { switch (dir) { case 0: x++; break; case 1: x++; y++; break; case 2: y++; break; case 3: x--; y++; break; case 4: x--; break; case 5: x--; y--; break; case 6: y--; break; case 7: x++; y--; break; } *pn_new_x = x; *pn_new_y = y; return OnContour(x, y); } static int ContourNeighbor(x, y, last_dir, pn_new_x, pn_new_y) int x, y, last_dir, *pn_new_x, *pn_new_y; /* * if last vector was 0, start looking at 1 * if last vector was 1, start looking at 3 * if last vector was 2, start looking at 3 * if last vector was 3, start looking at 5 * if last vector was 4, start looking at 5 * if last vector was 5, start looking at 7 * if last vector was 6, start looking at 7 * if last vector was 7, start looking at 1 */ { int i; if (last_dir & 0x1) { last_dir += 2; } else { last_dir++; } if (last_dir > 7) last_dir -= 8; for (i=0; i < 8; i++) { if (ProbeContour(x, y, last_dir, pn_new_x, pn_new_y)) { return last_dir; } else { if (--last_dir < 0) last_dir += 8; } } #ifdef _TGIF_DBG /* debug, do not translate */ fprintf(stderr, "Should not have come here ContourNeighbor()!\n"); #endif /* _TGIF_DBG */ return (-1); } static int CreatePolyFromContour(num_pts) int num_pts; { int x=gnContourX, y=gnContourY, generate=(num_pts > 2); struct CDirInfo *pcdi=topOfChain; struct XfrmMtrxRec *ctm=NULL; if (generate) { ResetCreatePolygon(); ctm = gpContourObj->ctm; } else { num_pts = 0; } while (pcdi != NULL) { int dir=pcdi->dir, n=1; struct CDirInfo *pcdi1=pcdi->next; for ( ; pcdi1 != NULL; pcdi1=pcdi1->next) { if (pcdi1->dir != dir) { break; } else { n++; } } if (generate) { if (ctm == NULL) { AddPtToCreatePolygon(gpContourObj->x+x, gpContourObj->y+y); } else { int tmp_x, tmp_y; TransformPointThroughCTM(x, y, ctm, &tmp_x, &tmp_y); AddPtToCreatePolygon(gpContourObj->x+tmp_x, gpContourObj->y+tmp_y); } } else { num_pts++; } switch (dir) { case 0: x += n; break; case 1: x += n; y += n; break; case 2: y += n; break; case 3: x -= n; y += n; break; case 4: x -= n; break; case 5: x -= n; y -= n; break; case 6: y -= n; break; case 7: x += n; y -= n; break; } pcdi = pcdi1; } if (generate) { if (ctm == NULL) { AddPtToCreatePolygon(gpContourObj->x+x, gpContourObj->y+y); } else { int tmp_x, tmp_y; TransformPointThroughCTM(x, y, ctm, &tmp_x, &tmp_y); AddPtToCreatePolygon(gpContourObj->x+tmp_x, gpContourObj->y+tmp_y); } CreatePolygonObj(num_pts, TRUE); } else { num_pts++; } if (generate) { return TRUE; } return num_pts; } static int DoCreateContour() { int x, y, dir, new_x, new_y, last_dir, num_pts=0; while (OnContour(gnContourX, gnContourY)) { gnContourX--; } gnContourX++; topOfChain = NULL; x = new_x = gnContourX; y = new_y = gnContourY; dir = 0; for (;;) { if (ProbeContour(x, y, dir, &new_x, &new_y)) { break; } else if (++dir >= 8) { MsgBox(TgLoadString(STID_NO_CONTOUR_CAN_BE_GEN_HERE), TOOL_NAME, INFO_MB); return FALSE; } } last_dir = 1; for (;;) { struct CDirInfo *pcdi; dir = ContourNeighbor(x, y, last_dir, &new_x, &new_y); pcdi = (struct CDirInfo *)malloc(sizeof(struct CDirInfo)); if (pcdi == NULL) FailAllocMessage(); memset(pcdi, 0, sizeof(struct CDirInfo)); pcdi->dir = dir; pcdi->next = NULL; if (botOfChain == NULL) { topOfChain = pcdi; } else { botOfChain->next = pcdi; } botOfChain = pcdi; if (new_x == gnContourX && new_y == gnContourY) { break; } x = new_x; y = new_y; last_dir = dir; } num_pts = CreatePolyFromContour(0); if (num_pts > 2) { return CreatePolyFromContour(num_pts); } MsgBox(TgLoadString(STID_NO_CONTOUR_CAN_BE_GEN_HERE), TOOL_NAME, INFO_MB); return FALSE; } static int StartCreateContour(obj_ptr, image, bitmap_image, image_x, image_y, image_w, image_h) struct ObjRec *obj_ptr; XImage *image, *bitmap_image; int image_x, image_y, image_w, image_h; { int i, pixel=(-1), created=FALSE; gnContourX = image_x; gnContourY = image_y; gnContourW = image_w; gnContourH = image_h; gContourImage = image; gContourBitmapImage = bitmap_image; gpContourObj = obj_ptr; gnaContourPixels = (int**)malloc(image_h*sizeof(int*)); if (gnaContourPixels == NULL) { return FailAllocMessage(); } memset(gnaContourPixels, 0, image_h*sizeof(int*)); for (i=0; i < image_h; i++) { int j; gnaContourPixels[i] = (int*)malloc(image_w*sizeof(int)); if (gnaContourPixels[i] == NULL) { FailAllocMessage(); CleanUpContour(); return FALSE; } for (j=0; j < image_w; j++) gnaContourPixels[i][j] = BAD; } if (!CreatePixelToIndexMapping()) { CleanUpContour(); return FALSE; } if (bitmap_image == NULL) { pixel = XGetPixel(image, image_x, image_y); } else { if (XGetPixel(bitmap_image, image_x, image_y) == 0) { /* transparent */ } else { pixel = XGetPixel(image, image_x, image_y); } } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); gnPixelToFill = colorPixels[colorIndex]; if (pixel == (-1)) { } else { int index=GetIndexOfPixel(pixel); gnContourRed = tgifColors[index].red; gnContourGreen = tgifColors[index].green; gnContourBlue = tgifColors[index].blue; created = DoCreateContour(); } SetDefaultCursor(mainWindow); ShowCursor(); CleanUpIndexOfPixel(); CleanUpContour(); return created; } static int ContinueCreateContour(obj_ptr) struct ObjRec *obj_ptr; { int image_w, image_h, changed=FALSE, mouse_x=0, mouse_y=0; unsigned int button; struct XPmRec *xpm_ptr=obj_ptr->detail.xpm; XImage *image, *bitmap_image; xpm_ptr = obj_ptr->detail.xpm; image_w = xpm_ptr->image_w; image_h = xpm_ptr->image_h; image = xpm_ptr->image; bitmap_image = xpm_ptr->bitmap_image; if (image == NULL) { image = xpm_ptr->image = XGetImage(mainDisplay, xpm_ptr->pixmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (image == NULL) FailAllocMessage(); } if (xpm_ptr->bitmap != None && bitmap_image == NULL) { bitmap_image = xpm_ptr->bitmap_image = XGetImage(mainDisplay, xpm_ptr->bitmap, 0, 0, image_w, image_h, AllPlanes, ZPixmap); if (bitmap_image == NULL) FailAllocMessage(); } SaveStatusStrings(); Msg(TgLoadString(STID_SEL_A_COLOR_TO_BE_TRACED)); SetMouseStatus(TgLoadString(STID_START_CONTOUR), TgLoadCachedString(CSTID_FINISH), TgLoadCachedString(CSTID_FINISH)); button = FillReplacePickAPoint(&mouse_x, &mouse_y, NULL, NULL, FALSE, handCursor); if (button == Button1) { int abs_x=ABS_X(mouse_x), abs_y=ABS_Y(mouse_y), found=FALSE; int image_x=0, image_y=0; if (obj_ptr->ctm == NULL) { if (abs_x >= obj_ptr->obbox.ltx && abs_y >= obj_ptr->obbox.lty && abs_x < obj_ptr->obbox.rbx && abs_y < obj_ptr->obbox.rby) { image_x = abs_x-obj_ptr->obbox.ltx; image_y = abs_y-obj_ptr->obbox.lty; if (image_x >= 0 && image_y >= 0 && image_x < image_w && image_y < image_h) { found = TRUE; } } } else { double image_dx=(double)0, image_dy=(double)0; ReverseTransformDoublePointThroughCTM( ((double)(abs_x-obj_ptr->x)+0.5), ((double)(abs_y-obj_ptr->y)+0.5), obj_ptr->ctm, &image_dx, &image_dy); image_x += (double)(obj_ptr->x-obj_ptr->orig_obbox.ltx); image_y += (double)(obj_ptr->y-obj_ptr->orig_obbox.lty); if (image_dx >= ((double)0) && image_dy >= ((double)0) && image_dx < ((double)image_w) && image_dy < ((double)image_h)) { image_x = (int)image_dx; image_y = (int)image_dy; if (image_x < 0) image_x = 0; if (image_x >= image_w) image_x = image_w-1; if (image_y < 0) image_y = 0; if (image_y >= image_h) image_y = image_h-1; found = TRUE; } } if (found) { if (somethingHighLighted) HighLightReverse(); changed = StartCreateContour(obj_ptr, image, bitmap_image, image_x, image_y, image_w, image_h); if (!somethingHighLighted) HighLightForward(); } else { SetStringStatus(TgLoadString(STID_SEL_PT_NOT_ON_IMAGE)); } } RestoreStatusStrings(); return changed; } void CreateContour() { struct ObjRec *obj_ptr; if (!CheckSelectionForImageProc(CMDID_CREATECONTOUR)) { return; } obj_ptr = topSel->obj; if (somethingHighLighted) HighLightReverse(); XSync(mainDisplay, False); if (ContinueCreateContour(obj_ptr)) { if (somethingHighLighted) HighLightReverse(); RemoveAllSel(); numRedrawBBox = 0; obj_ptr->tmp_parent = NULL; DrawObj(drawWindow, topObj); SelectTopObj(); RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; } else { if (!somethingHighLighted) HighLightForward(); } } /* ----------------------- Init and Clean Up ----------------------- */ void CleanUpImageProc() { CleanUpConvolution(); } /* do not translate -- program constants */ static char gszDefBggen[]="bggen %s -g %s | ppmquant 64 | ppmtoxpm"; static char gszDefPpm6Bggen[]="bggen %s -g %s"; static char gszDefPpmquant[]="pnmquant %d %s"; static char gszDefPpmFSquant[]="pnmquant -fs %d %s"; void InitImageProc() { char *c_ptr=NULL, spec[MAXSTRING]; memset(&gConvExtraInfo, 0, sizeof(ConvExtraInfo)); memset(&gThreshFillReplaceInfo, 0, sizeof(gThreshFillReplaceInfo)); gnQuantizingLevels = 222; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"QuantizingLevels")) != NULL) { gnQuantizingLevels = atoi(c_ptr); if (gnQuantizingLevels < 2 || gnQuantizingLevels > 256) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_RNG_USE_ALT_VAL), TOOL_NAME, "QuantizingLevels", c_ptr, 2, 256, 256-maxColors); gnQuantizingLevels = 256-maxColors; } } strcpy(bggenToXpmCmd, gszDefBggen); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"BggenToXpm")) != NULL) { int count=0; UtilStrCpyN(bggenToXpmCmd, sizeof(bggenToXpmCmd), c_ptr); for (c_ptr=strstr(bggenToXpmCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 2) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "BggenToXpm", bggenToXpmCmd, gszDefBggen); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(bggenToXpmCmd, gszDefBggen); } } strcpy(bggenToPpm6Cmd, gszDefPpm6Bggen); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"BggenToPpm6")) != NULL) { int count=0; UtilStrCpyN(bggenToPpm6Cmd, sizeof(bggenToPpm6Cmd), c_ptr); for (c_ptr=strstr(bggenToPpm6Cmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 2) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "BggenToPpm6", bggenToPpm6Cmd, gszDefPpm6Bggen); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(bggenToPpm6Cmd, gszDefPpm6Bggen); } } strcpy(ppmquantCmd, gszDefPpmquant); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PpmQuantize")) != NULL) { int count=0; UtilStrCpyN(ppmquantCmd, sizeof(ppmquantCmd), c_ptr); for (c_ptr=strstr(ppmquantCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PpmQuantize", ppmquantCmd, gszDefPpmquant); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(ppmquantCmd, gszDefPpmquant); } for (c_ptr=strstr(ppmquantCmd,"%d"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%d")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PpmQuantize", ppmquantCmd, gszDefPpmquant); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(ppmquantCmd, gszDefPpmquant); } } strcpy(ppmFSquantCmd, gszDefPpmFSquant); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PpmFSQuantize")) != NULL) { int count=0; UtilStrCpyN(ppmFSquantCmd, sizeof(ppmFSquantCmd), c_ptr); for (c_ptr=strstr(ppmFSquantCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PpmQuantize", ppmFSquantCmd, gszDefPpmFSquant); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(ppmFSquantCmd, gszDefPpmFSquant); } for (c_ptr=strstr(ppmFSquantCmd,"%d"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%d")) { count++; } if (count != 1) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PpmQuantize", ppmFSquantCmd, gszDefPpmFSquant); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); strcpy(ppmFSquantCmd, gszDefPpmFSquant); } } gDefErrorDiffuseLevel.red = gDefErrorDiffuseLevel.green = gDefErrorDiffuseLevel.blue = 2; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DefaultErrorDiffuseLevels")) != NULL) { XColor xcolor; char *dup_buf=UtilStrDup(c_ptr); if (dup_buf == NULL) FailAllocMessage(); switch (ParseDefaultColorLevels(dup_buf, &xcolor)) { case PDCL_OK: gDefErrorDiffuseLevel.red = xcolor.red; gDefErrorDiffuseLevel.green = xcolor.green; gDefErrorDiffuseLevel.blue = xcolor.blue; break; case PDCL_TOO_LARGE: fprintf(stderr, TgLoadString(STID_VAL_TOO_LARGE_IN_XDEF_USE_ALT), TOOL_NAME, "DefaultErrorDiffuseLevels", c_ptr, "2 2 2"); fprintf(stderr, "\n"); break; case PDCL_TOO_SMALL: fprintf(stderr, TgLoadString(STID_VAL_TOO_SMALL_IN_XDEF_USE_ALT), TOOL_NAME, "DefaultErrorDiffuseLevels", c_ptr, "2 2 2"); break; case PDCL_BAD_FORMAT: fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "DefaultErrorDiffuseLevels", c_ptr, "2 2 2"); break; } free(dup_buf); } memset(gaHGBucket, 0, sizeof(gaHGBucket)); memset(&gTrueColorInfo, 0, sizeof(TrueColorInfo)); threshFillReplaceEnabled = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "EnableThresholdFloodReplaceColor")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { threshFillReplaceEnabled = TRUE; } *spec = '\0'; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME, "FloodReplaceColorThreshold")) != NULL) { UtilStrCpyN(spec, sizeof(spec), c_ptr); UtilTrimBlanks(spec); if (!ParseThreshFillReplaceSpec(spec)) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "FloodReplaceColorThreshold", spec, "15,15,15"); fprintf(stderr, "\n"); } } } /* ----------------------- Menu Functions ----------------------- */ int RefreshImageProcMenu(menu) TgMenu *menu; { int ok=TRUE; /* Enable Threshold-based Flood and Replace Colors */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEFLOODREPLACECOLORTHRESH, threshFillReplaceEnabled); /* Set Threshold for Flood and Replace Colors */ ok &= TgEnableMenuItemById(menu, CMDID_SETFLOODREPLACECOLORTHRESH, threshFillReplaceEnabled); return ok; } TgMenu *CreateImageProcMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshImageProcMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshImageProcMenu); } return menu; } int ImageProcMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(imageProcMenuInfo.create_proc)(NULL, X, Y, &imageProcMenuInfo, FALSE); activeMenu = MENU_IMAGEPROC; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } ���������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/special.e����������������������������������������������������������������������������0000644�0000764�0000764�00000006252�11602233312�014557� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/special.e,v 1.8 2011/05/16 16:21:59 william Exp $ */ #ifndef _SPECIAL_E_ #define _SPECIAL_E_ extern int placingTopObj; extern int connectingPortsByWire; extern int connectingPortsFromInternalCommand; extern char gszAttrSeparator[]; #ifdef _INCLUDE_FROM_SPECIAL_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_SPECIAL_C_*/ extern struct ObjRec * ReadSymbol ARGS_DECL((FILE *, int FileType)); extern struct ObjRec * GetObjRepresentation ARGS_DECL((char *PathName, char *SymName, int FileType)); extern unsigned int PlaceTopObj ARGS_DECL((struct ObjRec *, struct ObjRec *savedTopObj, struct ObjRec *savedBotObj)); extern void Instantiate ARGS_DECL((void)); extern int ObjIsAPort ARGS_DECL((struct ObjRec *)); extern void ConnectTwoPortsByAWire ARGS_DECL((void)); extern void RepeatConnectTwoPortsByAWire ARGS_DECL((void)); extern void ConnectPortsToBroadcastWire ARGS_DECL((void)); extern void RenameSignalNameForAPort ARGS_DECL((void)); extern void ClearSignalNameForAPort ARGS_DECL((void)); extern void MergePortsWithAnObject ARGS_DECL((void)); extern void RenumberObjectIds ARGS_DECL((void)); extern void MakeSymbolic ARGS_DECL((void)); extern void UnMakeSymbolic ARGS_DECL((void)); extern int MakeIconic ARGS_DECL((char *SymPath, int record_cmd)); extern void UnMakeIconic ARGS_DECL((void)); extern void ImportAttrs ARGS_DECL((void)); extern int ImportNamedAttrs ARGS_DECL((FILE*, struct ObjRec *, int num_restricted, char **ppsz_restricted, char *fname)); extern void ExportAttrs ARGS_DECL((void)); extern void MergeWithTable ARGS_DECL((void)); extern void ExportToTable ARGS_DECL((void)); extern void ToggleShowWireSignalName ARGS_DECL((void)); extern int RefreshPortMenu ARGS_DECL((TgMenu*)); extern TgMenu *CreatePortMenu ARGS_DECL((TgMenu*, int X, int Y, TgMenuInfo*, int status_str_xlated)); extern void RefreshSpecialMenu ARGS_DECL((TgMenu*)); extern int SpecialMenu ARGS_DECL((int X, int Y, int TrackMenubar)); extern void CleanUpSpecial ARGS_DECL((void)); extern int InitSpecial ARGS_DECL((void)); #ifdef _INCLUDE_FROM_SPECIAL_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_SPECIAL_C_*/ #endif /*_SPECIAL_E_*/ ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/scan2ac.awk��������������������������������������������������������������������������0000644�0000764�0000764�00000003231�11602233312�015001� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# # @(#)$Header: /mm2/home/cvs/bc-src/tgif/scan2ac.awk,v 1.9 2010/09/02 18:56:44 william Exp $ # BEGIN { triggered=0; } { if (/^# Checks for libraries/) { triggered=1; } if (/^# Checks for header files/) { triggered=0; print "# Checks for libraries."; print "AC_CHECK_LIB([X11], [XOpenDisplay])"; print "AC_CHECK_LIB([Xt], [XtInitialize])"; print "AC_CHECK_LIB([socket], [socket])"; print "AC_CHECK_LIB([nsl], [inet_addr])"; print "AC_CHECK_LIB([dl], [dlsym])"; print "AC_CHECK_LIB([idn], [stringprep_convert])"; print "AC_CHECK_LIB([m], [pow])"; print "AC_CHECK_LIB([z], [deflate])"; print "AC_CHECK_LIB([pthread], [pthread_create])"; print ""; print "# Checks for header files."; next; } else { if (triggered) { next; } else { if (/^AC_CONFIG_SUBDIRS\(\[rmcast\]\)/) { print "# BC: skipping AC_CONFIG_SUBDIRS([rmcast])"; } else { if (/^AC_PREREQ\(/) { print "AC_PREREQ(2.61)"; } else { if (/^AC_CONFIG_HEADER\(\[config.h\]\)/) { print "AM_INIT_AUTOMAKE"; print "AM_CONFIG_HEADER([config.h])"; } else { if (/^AC_CONFIG_HEADERS\(\[config.h\]\)/) { print "AM_INIT_AUTOMAKE"; print "AC_CONFIG_HEADERS([config.h])"; } else { print; } } } } } } } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tdgtmsg.e����������������������������������������������������������������������������0000644�0000764�0000764�00000003720�11602233313�014606� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtmsg.e,v 1.6 2011/05/16 16:22:00 william Exp $ */ #ifndef _TDGTMSG_E_ #define _TDGTMSG_E_ #include "tidget.h" #define TDGTMSG_DEF_H_PAD 4 #define TDGTMSG_DEF_V_PAD 2 /* * A message tidget displays a string. */ typedef struct tagTdgtMsg { TidgetInfo *pti; int just; /* JUST_L, JUST_C, or JUST_R */ } TdgtMsg; #ifdef _INCLUDE_FROM_TDGTMSG_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TDGTMSG_C_*/ extern void TdgtMsgReset ARGS_DECL((TdgtMsg*)); extern TdgtMsg *CreateTdgtMsg ARGS_DECL((Window parent_win, TidgetInfo *parent_tidgetinfo, int ctl_id, int x, int y, int h_pad, int v_pad, int state, char *caption, int just)); extern int TdgtMsgSetText ARGS_DECL((TdgtMsg*, char *str)); extern char *TdgtMsgGetText ARGS_DECL((TdgtMsg*)); extern int TdgtMsgSetState ARGS_DECL((TdgtMsg*, int)); extern int TdgtMsgGetState ARGS_DECL((TdgtMsg*)); extern int InitTdgtMsg ARGS_DECL((void)); extern void CleanUpTdgtMsg ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TDGTMSG_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TDGTMSG_C_*/ #endif /*_TDGTMSG_E_*/ ������������������������������������������������tgif-QPL-4.2.5/cli_xcin.e���������������������������������������������������������������������������0000644�0000764�0000764�00000001242�11602233311�014720� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * @(#)$Header: /mm2/home/cvs/bc-src/tgif/cli_xcin.e,v 1.3 2011/06/14 02:32:18 william Exp $ */ #ifndef _NO_XCIN #ifndef _CLI_XCIN_E_ #define _CLI_XCIN_E_ #ifdef _INCLUDE_FROM_CLI_XCIN_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_CLI_XCIN_C_*/ extern void Tg_send_FocusIn ARGS_DECL((Display*, Window)); extern void Tg_send_FocusOut ARGS_DECL((Display*, Window)); extern int Tg_send_key ARGS_DECL((Display*, Window, XKeyEvent*, char*)); #ifdef _INCLUDE_FROM_CLI_XCIN_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_CLI_XCIN_C_*/ #endif /*_CLI_XCIN_E_*/ #endif /* ~_NO_XCIN */ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tdgtbase.c���������������������������������������������������������������������������0000644�0000764�0000764�00000031015�11602233313�014726� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtbase.c,v 1.8 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_TDGTBASE_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "tidget.h" #include "cursor.e" #include "menu.e" #include "msg.e" #include "raster.e" #include "rect.e" #include "setup.e" #include "tdgtbase.e" #include "text.e" #include "tidget.e" #include "util.e" static void RedrawTdgtBase ARGS_DECL((TidgetInfo *pti)); static int TdgtBaseEventHandler ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo *handling_pti)); static int IsTdgtBaseEvent ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo **ppti_handler_tidget_return)); static void DestroyTdgtBase ARGS_DECL((TidgetInfo *pti)); static void MapTdgtBase ARGS_DECL((TidgetInfo *pti)); static void TdgtBaseMoveResize ARGS_DECL((TidgetInfo *pti, int x, int y, int w, int h)); static int TdgtBaseSendCmd ARGS_DECL((TidgetInfo *pti, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); /* --------------------- RedrawTdgtBase() --------------------- */ static void RedrawTdgtBase(pti) TidgetInfo *pti; { TdgtBase *pTdgtBase=(TdgtBase*)(pti->tidget); CVListElem *pElem=NULL; XClearWindow(mainDisplay, pTdgtBase->pti->tci.win); if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, pTdgtBase->pti->tci.win_info.w, pTdgtBase->pti->tci.win_info.h); switch (pTdgtBase->pti->tci.state) { case TGBS_NORMAL: break; default: TgDrawThreeDButton(mainDisplay, pTdgtBase->pti->tci.win, gTidgetManager.gc, &bbox, pTdgtBase->pti->tci.state, 2, FALSE); break; } } else { XDrawRectangle(mainDisplay, pTdgtBase->pti->tci.win, gTidgetManager.gc, 0, 0, pTdgtBase->pti->tci.win_info.w, pTdgtBase->pti->tci.win_info.h); } for (pElem=ListFirst(&pTdgtBase->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBase->pti->tci.clist, pElem)) { TidgetInfo *pti=(TidgetInfo*)(pElem->obj); if (pti != NULL) { RedrawTidget(pti); } } TidgetManagerResetGC(); } /* --------------------- TdgtBaseEventHandler() --------------------- */ static int TdgtBaseEventHandler(pti, input, handling_pti) TidgetInfo *pti, *handling_pti; XEvent *input; { TdgtBase *pTdgtBase=(TdgtBase*)(pti->tidget); CVListElem *pElem=NULL; if (pti == handling_pti) { if (input->type == KeyPress && pTdgtBase->pf_key_press_ev_handler_callback != NULL) { return (pTdgtBase->pf_key_press_ev_handler_callback)(pTdgtBase, input); } if (input->xany.window == pTdgtBase->pti->tci.win) { if (IsWM_DELETE_WINDOW(input)) { if (pTdgtBase->pf_wm_delete_ev_handler_callback != NULL) { (pTdgtBase->pf_wm_delete_ev_handler_callback)(pTdgtBase); } } else if (input->type == Expose) { XEvent ev; RedrawTdgtBase(pTdgtBase->pti); while (XCheckWindowEvent(mainDisplay, pTdgtBase->pti->tci.win, ExposureMask, &ev)) ; } else if (input->type == EnterNotify) { /* may be we need to do something here */ } else if (input->type == LeaveNotify) { /* may be we need to do something here */ } return FALSE; } } for (pElem=ListFirst(&pTdgtBase->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBase->pti->tci.clist, pElem)) { TidgetInfo *pti=(TidgetInfo*)(pElem->obj); if (pti != NULL) { if (TdgtBaseEventHandler(pti, input, handling_pti)) { return TRUE; } } } return FALSE; } /* --------------------- IsTdgtBaseEvent() --------------------- */ static int IsTdgtBaseEvent(pti, input, ppti_handler_tidget_return) TidgetInfo *pti, **ppti_handler_tidget_return; XEvent *input; { TdgtBase *pTdgtBase=(TdgtBase*)(pti->tidget); if (input->type == KeyPress && pTdgtBase->pf_key_press_ev_handler_callback != NULL) { CVListElem *pElem=NULL; if (input->xany.window == pTdgtBase->pti->tci.win) { *ppti_handler_tidget_return = pti; return TRUE; } for (pElem=ListFirst(&pTdgtBase->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBase->pti->tci.clist, pElem)) { TidgetInfo *pti=(TidgetInfo*)(pElem->obj); if (pti != NULL) { TidgetInfo *dummy_pti=NULL; if (IsTidgetEvent(pti, input, &dummy_pti)) { *ppti_handler_tidget_return = pti; return TRUE; } } } } return FALSE; } /* --------------------- DestroyTdgtBase() --------------------- */ static void DestroyTdgtBase(pti) TidgetInfo *pti; { TdgtBase *pTdgtBase=(TdgtBase*)(pti->tidget); TdgtBaseReset(pTdgtBase); free(pTdgtBase); } /* --------------------- MapTdgtBase() --------------------- */ static void MapTdgtBase(pti) TidgetInfo *pti; { TdgtBase *pTdgtBase=(TdgtBase*)(pti->tidget); CVListElem *pElem=NULL; #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, pTdgtBase->pti->tci.win); XSelectInput(mainDisplay, pTdgtBase->win, StructureNotifyMask | ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); #else XSelectInput(mainDisplay, pTdgtBase->pti->tci.win, StructureNotifyMask | ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, pTdgtBase->pti->tci.win); #endif for (pElem=ListFirst(&pTdgtBase->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBase->pti->tci.clist, pElem)) { TidgetInfo *pti=(TidgetInfo*)(pElem->obj); if (pti != NULL) { MapTidget(pti); } } } /* --------------------- TdgtBaseMoveResize() --------------------- */ static void TdgtBaseMoveResize(pti, x, y, w, h) TidgetInfo *pti; int x, y, w, h; { TdgtBase *pTdgtBase=(TdgtBase*)(pti->tidget); /* there should be no need to resize a button */ pTdgtBase->pti->tci.win_info.x = x; pTdgtBase->pti->tci.win_info.y = y; pTdgtBase->pti->tci.win_info.w = w; pTdgtBase->pti->tci.win_info.h = h; XMoveResizeWindow(mainDisplay, pTdgtBase->pti->tci.win, x, y, w, h); } /* --------------------- TdgtBaseSendCmd() --------------------- */ static int TdgtBaseSendCmd(pti, cmd_type, cmd_arg, pv_cmd_userdata) TidgetInfo *pti; int cmd_type, cmd_arg; void *pv_cmd_userdata; { TdgtBase *pTdgtBase=(TdgtBase*)(pti->tidget); if (pTdgtBase != NULL) { switch (cmd_type) { case TDGTCMD_CAN_HANDLE_FOCUS_CHANGE: return (pTdgtBase->pf_focus_callback != NULL); case TDGTCMD_REMOVE_FOCUS: return (pTdgtBase->pf_focus_callback)(pTdgtBase, cmd_type, cmd_arg, pv_cmd_userdata); } } return FALSE; } /* --------------------- TdgtBaseReset() --------------------- */ void TdgtBaseReset(pTdgtBase) TdgtBase *pTdgtBase; { CVListElem *pElem=NULL; for (pElem=ListFirst(&pTdgtBase->pti->tci.clist); pElem != NULL; pElem=ListNext(&pTdgtBase->pti->tci.clist, pElem)) { TidgetInfo *pti=(TidgetInfo*)(pElem->obj); if (pti != NULL) { DestroyTidget(&pti); } } ListUnlinkAll(&pTdgtBase->pti->tci.clist); ResetTidgetCommon(&pTdgtBase->pti->tci); } /* --------------------- CreateTdgtBase() --------------------- */ TdgtBase *CreateTdgtBase(parent_win, parent_tidgetinfo, ctl_id, x, y, w, h, h_pad, v_pad, state, caption) Window parent_win; TidgetInfo *parent_tidgetinfo; int ctl_id, x, y, w, h, h_pad, v_pad, state; char *caption; { int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); XWMHints wmhints; XSetWindowAttributes win_attrs; TdgtBase *pTdgtBase=NULL; pTdgtBase = (TdgtBase*)malloc(sizeof(TdgtBase)); if (pTdgtBase == NULL) FailAllocMessage(); memset(pTdgtBase, 0, sizeof(TdgtBase)); pTdgtBase->pti = NewTidgetInfo(parent_tidgetinfo, TIDGET_TYPE_BASE, pTdgtBase, ctl_id, NULL); if ((pTdgtBase->pti->tci.win=XCreateSimpleWindow(mainDisplay, parent_win, x, y, w, h, brdrW, myBorderPixel, bg_pixel)) == 0) { FailToCreateWindowMessage("CreateTdgtBase()", NULL, TRUE); } XSelectInput(mainDisplay, pTdgtBase->pti->tci.win, StructureNotifyMask | ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | EnterWindowMask | LeaveWindowMask); SetTidgetInfoBasic(pTdgtBase->pti, TIDGET_TYPE_BASE, pTdgtBase, parent_win, x, y, w, h, h_pad, v_pad, state, caption); TidgetCanHaveChildren(pTdgtBase->pti, TRUE); TidgetSetCallbacks(pTdgtBase->pti, RedrawTdgtBase, TdgtBaseEventHandler, IsTdgtBaseEvent, DestroyTdgtBase, MapTdgtBase, TdgtBaseMoveResize, TdgtBaseSendCmd); XDefineCursor(mainDisplay, pTdgtBase->pti->tci.win, defaultCursor); memset(&win_attrs, 0, sizeof(XSetWindowAttributes)); win_attrs.save_under = True; win_attrs.colormap = mainColormap; XChangeWindowAttributes(mainDisplay, pTdgtBase->pti->tci.win, CWSaveUnder | CWOverrideRedirect | CWColormap, &win_attrs); memset(&wmhints, 0, sizeof(XWMHints)); wmhints.flags = InputHint; wmhints.input = True; XSetWMHints(mainDisplay, pTdgtBase->pti->tci.win, &wmhints); RegisterWM_DELETE_WINDOW(pTdgtBase->pti->tci.win); if (caption != NULL && *caption != '\0') { XStoreName(mainDisplay, pTdgtBase->pti->tci.win, caption); } return pTdgtBase; } /* --------------------- TdgtBaseSetText() --------------------- */ int TdgtBaseSetText(pTdgtBase, str) TdgtBase *pTdgtBase; char *str; { RedrawTdgtBase(pTdgtBase->pti); if (str != NULL) { FreeDynStrBuf(&(pTdgtBase->pti->tci.dyn_str)); DynStrSet(&(pTdgtBase->pti->tci.dyn_str), str); } return TRUE; } /* --------------------- TdgtBaseGetText() --------------------- */ char *TdgtBaseGetText(pTdgtBase) TdgtBase *pTdgtBase; { return pTdgtBase->pti->tci.dyn_str.s; } /* --------------------- TdgtBaseSetState() --------------------- */ int TdgtBaseSetState(pTdgtBase, new_state) TdgtBase *pTdgtBase; int new_state; { int need_to_redraw=(pTdgtBase->pti->tci.state != new_state); pTdgtBase->pti->tci.state = new_state; if (need_to_redraw) { RedrawTdgtBase(pTdgtBase->pti); } return TRUE; } /* --------------------- TdgtBaseGetState() --------------------- */ int TdgtBaseGetState(pTdgtBase) TdgtBase *pTdgtBase; { return pTdgtBase->pti->tci.state; } /* --------------------- TdgtBaseAddChild() --------------------- */ int TdgtBaseAddChild(pTdgtBase, pChildTidgetInfo) TdgtBase *pTdgtBase; TidgetInfo *pChildTidgetInfo; { return ListAppend(&pTdgtBase->pti->tci.clist, pChildTidgetInfo); } /* ------------------- TdgtBaseWillHandleKeyPressEvents() ------------------- */ void TdgtBaseWillHandleKeyPressEvents(pTdgtBase, pf_key_press_ev_handler_callback) TdgtBase *pTdgtBase; TdgtBaseKeyPressEvHandlerCallbackFunc *pf_key_press_ev_handler_callback; { pTdgtBase->pf_key_press_ev_handler_callback = pf_key_press_ev_handler_callback; } /* ------------------- TdgtBaseSetWmDeleteCallback() ------------------- */ void TdgtBaseSetWmDeleteCallback(pTdgtBase, pf_wm_delete_ev_handler_callback) TdgtBase *pTdgtBase; TdgtBaseWmDeleteEvHandlerCallbackFunc *pf_wm_delete_ev_handler_callback; { pTdgtBase->pf_wm_delete_ev_handler_callback = pf_wm_delete_ev_handler_callback; } /* ------------------- TdgtBaseSetFocusCallback() ------------------- */ void TdgtBaseSetFocusCallback(pTdgtBase, pf_focus_callback) TdgtBase *pTdgtBase; TdgtBaseFocusCallbackFunc *pf_focus_callback; { pTdgtBase->pf_focus_callback = pf_focus_callback; } /* --------------------- Init & Clean Up --------------------- */ int InitTdgtBase() { return TRUE; } void CleanUpTdgtBase() { } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/grid.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000152051�11602233311�014060� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/grid.c,v 1.15 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_GRID_C_ #include "tgifdefs.h" #include "cmdids.h" #include "expfdefs.h" #include "choice.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "grid.e" #include "mainmenu.e" #include "menu.e" #include "menuinfo.e" #include "msg.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "pattern.e" #include "raster.e" #include "ruler.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "stretch.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "wb.e" #include "xprtfltr.e" #define ENGLISH_GRID_STEP 8 #define METRIC_GRID_STEP 5 int gridSystem = ENGLISH_GRID; int snapOn = TRUE; int xyEnglishGrid = DEFAULT_ENGLISH_GRID; int xyMetricGrid = DEFAULT_METRIC_GRID; int pageStyle = PORTRAIT; int whereToPrint = LATEX_FIG; int moveMode = UNCONST_MOVE; int gridShown = TRUE; int mapShown = TRUE; int usePaperSizeStoredInFile = FALSE; int oneMotionSelectMove = FALSE; int queryZoomInPoint=FALSE; int shiftForDiagMouseMove=TRUE; #ifdef RESTRICTED_MOUSE_MOVE int useRecentForDiagMouseMove=TRUE; #else /* ~RESTRICTED_MOUSE_MOVE */ int useRecentForDiagMouseMove=FALSE; #endif /* RESTRICTED_MOUSE_MOVE */ int defRightMargin=(ONE_INCH*TIK_PER_PIXEL); int defRightMarginEnabled=INVALID; int rightMargin=(ONE_INCH*TIK_PER_PIXEL); int rightMarginEnabled=INVALID; int rightMarginActive=TRUE; static void MyHDotLine(Win, gc, Y, XStart, XEnd) Window Win; GC gc; int Y, XStart, XEnd; { int x, step=0; switch (gridSystem) { case ENGLISH_GRID: step = ENGLISH_GRID_STEP; break; case METRIC_GRID: step = METRIC_GRID_STEP; break; } for (x=XStart; x < XEnd; x += step) { PUT_A_POINT(mainDisplay, Win, gc, x, Y); } } static void MyVDotLine(Win, gc, X, YStart, YEnd) Window Win; GC gc; int X, YStart, YEnd; { int y, step=0; switch (gridSystem) { case ENGLISH_GRID: step = ENGLISH_GRID_STEP; break; case METRIC_GRID: step = METRIC_GRID_STEP; break; } for (y=YStart; y < YEnd; y += step) { PUT_A_POINT(mainDisplay, Win, gc, X, y); } } #define FAKE_CM 80 static void DrawGridLinesSetVars(pn_inc, pn_step, pn_abs_inc) int *pn_inc, *pn_step, *pn_abs_inc; { switch (gridSystem) { case ENGLISH_GRID: *pn_inc = HALF_INCH; *pn_step = ENGLISH_GRID_STEP; break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { *pn_inc = (FAKE_CM>>1); } else { *pn_inc = ONE_CM; } *pn_step = METRIC_GRID_STEP; break; } *pn_abs_inc = ABS_SIZE(*pn_inc); } static void PrepareDrawGCForGridPoints() { XGCValues values; values.foreground = myFgPixel; values.function = GXcopy; values.fill_style = FillSolid; values.line_width = 1; values.line_style = LineSolid; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCLineWidth | GCLineStyle, &values); } void RedrawGridLines(Win) Window Win; { int i, inc=0, abs_inc=0, step=ENGLISH_GRID_STEP; int x_start, y_start, x_end, y_end, x_grid_start, y_grid_start; if (!gridShown || (inSlideShow && !visibleGridInSlideShow)) return; DrawGridLinesSetVars(&inc, &step, &abs_inc); if (drawOrigX % abs_inc == 0) { x_start = 0; } else { x_start = OFFSET_X(((int)(drawOrigX / abs_inc) + 1) * abs_inc); } if (drawOrigY % abs_inc == 0) { y_start = 0; } else { y_start = OFFSET_Y(((int)(drawOrigY / abs_inc) + 1) * abs_inc); } x_end = min(OFFSET_X(paperWidth), OFFSET_X(drawOrigX+drawWinW)); y_end = min(OFFSET_Y(paperHeight), OFFSET_Y(drawOrigY+drawWinH)); if (ZOOMED_SIZE(drawOrigX) % step == 0) { x_grid_start = 0; } else { x_grid_start = ((int)(ZOOMED_SIZE(drawOrigX) / step)) * step - ZOOMED_SIZE(drawOrigX); } if (ZOOMED_SIZE(drawOrigY) % step == 0) { y_grid_start = 0; } else { y_grid_start = ((int)(ZOOMED_SIZE(drawOrigY) / step)) * step - ZOOMED_SIZE(drawOrigY); } PrepareDrawGCForGridPoints(); for (i=x_start; i < x_end; i += inc) { MyVDotLine(Win, drawGC, i, y_grid_start, y_end); } for (i=y_start; i < y_end; i += inc) { MyHDotLine(Win, drawGC, i, x_grid_start, x_end); } } void DrawGridLines(Win, LtX, LtY, W, H) Window Win; int LtX, LtY, W, H; /* screen offsets */ { int i, inc=0, abs_inc=0, step=ENGLISH_GRID_STEP; int x_start, y_start, x_end, y_end, x_grid_start, y_grid_start; int x_grid_end=0, y_grid_end=0, x_max=0, y_max=0; if (!gridShown || (inSlideShow && !visibleGridInSlideShow)) return; DrawGridLinesSetVars(&inc, &step, &abs_inc); /* large divisions - use 'inc' */ if (drawOrigX % abs_inc == 0) { x_start = 0; } else { x_start = OFFSET_X(((int)(drawOrigX / abs_inc) + 1) * abs_inc); } if (drawOrigY % abs_inc == 0) { y_start = 0; } else { y_start = OFFSET_Y(((int)(drawOrigY / abs_inc) + 1) * abs_inc); } x_max = min(OFFSET_X(paperWidth), OFFSET_X(drawOrigX+drawWinW)); y_max = min(OFFSET_Y(paperHeight), OFFSET_Y(drawOrigY+drawWinH)); while (x_start+1 < LtX) x_start += inc; while (y_start+1 < LtY) y_start += inc; for (x_end=x_start; x_end < LtX+W+1; x_end += inc) { if (x_end >= x_max) { break; } } x_end -= inc; for (y_end=y_start; y_end < LtY+H+1; y_end += inc) { if (y_end >= y_max) { break; } } y_end -= inc; /* small divisions - use 'step' */ x_grid_start = x_start-inc; y_grid_start = y_start-inc; while (x_grid_start+1 < LtX) x_grid_start += step; while (y_grid_start+1 < LtY) y_grid_start += step; for (x_grid_end=x_end+step; x_grid_end < LtX+W+1; x_grid_end += step) { if (x_grid_end >= x_max) { break; } } for (y_grid_end=y_end+step; y_grid_end < LtY+H+1; y_grid_end += step) { if (y_grid_end >= y_max) { break; } } PrepareDrawGCForGridPoints(); for (i=x_start; i <= x_end; i += inc) { MyVDotLine(Win, drawGC, i, y_grid_start, y_grid_end); } for (i=y_start; i <= y_end; i += inc) { MyHDotLine(Win, drawGC, i, x_grid_start, x_grid_end); } } void RedrawPageLines(Win) Window Win; { register int i, x, y; int end; if (pageLayoutMode == PAGE_STACK || !pageLineShownInTileMode) return; PrepareDrawGCForGridPoints(); end = OFFSET_Y(min(drawOrigY+drawWinH,paperHeight)); for (i=0; i < paperWidth; i += onePageWidth) { x = OFFSET_X(i); if (i >= drawOrigX && i < drawOrigX+drawWinW) { XDrawLine(mainDisplay, Win, drawGC, x, 0, x, end); } if (i > drawOrigX+drawWinW) { break; } } end = OFFSET_X(min(drawOrigX+drawWinW,paperWidth)); for (i=0; i < paperHeight; i += onePageHeight) { y = OFFSET_Y(i); if (i >= drawOrigY && i < drawOrigY+drawWinH) { XDrawLine(mainDisplay, Win, drawGC, 0, y, end, y); } if (i > drawOrigY+drawWinH) { break; } } } void DrawPageLines(Win, LtX, LtY, W, H) Window Win; int LtX, LtY, W, H; /* screen offsets */ { int i, x, y, start, end; if (pageLayoutMode == PAGE_STACK || !pageLineShownInTileMode) return; PrepareDrawGCForGridPoints(); start = max(0,LtY); end = min(LtY+H,OFFSET_Y(min(drawOrigY+drawWinH,paperHeight))); if (end > start) { for (i=0; i < paperWidth; i += onePageWidth) { x = OFFSET_X(i); if (x >= LtX && x < LtX+W) { XDrawLine(mainDisplay, Win, drawGC, x, start, x, end); } if (i > drawOrigX+drawWinW) { break; } } } start = max(0,LtX); end = min(LtX+W,OFFSET_X(min(drawOrigX+drawWinW,paperWidth))); if (end > start) { for (i=0; i < paperHeight; i += onePageHeight) { y = OFFSET_Y(i); if (y >= LtY && y < LtY+H) { XDrawLine(mainDisplay, Win, drawGC, start, y, end, y); } if (i > drawOrigY+drawWinH) { break; } } } } static void GetRightMarginSpec(buf) char *buf; { double dval=(double)0; dval = ((double)rightMargin) * ((double)printMag) / ((double)TIK_PER_PIXEL); dval /= ((double)100); PixelToCurrentUnit(buf, round(dval)); } void ToggleRightMargin() { switch (rightMarginEnabled) { case INVALID: rightMarginEnabled = TRUE; break; case FALSE: rightMarginEnabled = TRUE; break; case TRUE: rightMarginEnabled = FALSE; break; } SetFileModified(TRUE); RedrawHRulerWindow(); if (rightMarginEnabled == TRUE) { char buf[80]; *buf = '\0'; GetRightMarginSpec(buf); sprintf(gszMsgBox, TgLoadString(STID_RIGHT_MARGIN_IS), buf); Msg(gszMsgBox); } else { sprintf(gszMsgBox, TgLoadString(STID_RIGHT_MARGIN_DISABLED)); Msg(gszMsgBox); } } void SpecifyRightMargin() { char buf[MAXSTRING+1], spec[MAXSTRING+1]; double dval=(double)0; *gszMsgBox = '\0'; GetRightMarginSpec(gszMsgBox); sprintf(buf, TgLoadString(STID_CURRENT_RIGHT_MARGIN_IS), gszMsgBox); strcpy(gszMsgBox, TgLoadString(STID_ENTER_RIGHT_MARGIN)); *spec = '\0'; Dialog(gszMsgBox, buf, spec); UtilTrimBlanks(spec); if (*spec == '\0') return; if (GetDimensionInDouble(spec, TRUE, &dval)) { dval = dval * ((double)100) * ((double)TIK_PER_PIXEL) / ((double)printMag); rightMargin = round(dval); RedrawHRulerWindow(); SetFileModified(TRUE); GetRightMarginSpec(buf); sprintf(gszMsgBox, TgLoadString(STID_RIGHT_MARGIN_IS), buf); Msg(gszMsgBox); } } void ToggleGridSystem() { int saved_orig_x, saved_orig_y; switch (gridSystem) { case ENGLISH_GRID: Msg(TgLoadString(STID_USING_METRIC_SYSTEM)); break; case METRIC_GRID: Msg(TgLoadString(STID_USING_ENGLISH_SYSTEM)); break; } gridSystem = !gridSystem; if (drawOrigX != 0 || drawOrigY != 0) { saved_orig_x = drawOrigX; saved_orig_y = drawOrigY; drawOrigX = drawOrigY = 0; RedrawScrollBars(); UpdDrawWinBBox(); AdjSplineVs(); AdjustCurText(-(saved_orig_x), -(saved_orig_y)); } ClearAndRedrawDrawWindow(); RedrawRulers(); UpdatePinnedMenu(MENU_LAYOUT); } void IncGrid() { if (!snapOn) { Msg(TgLoadString(STID_SNAP_NOT_ON_GRID_SZ_SAME)); } else if (gridSystem == ENGLISH_GRID && xyEnglishGrid < HALF_INCH) { xyEnglishGrid <<= 1; RedrawRulers(); } else if (gridSystem == METRIC_GRID && xyMetricGrid < ONE_CM) { switch (xyMetricGrid) { case ONE_MM: xyMetricGrid = TWO_MM; break; case TWO_MM: xyMetricGrid = FIVE_MM; break; case FIVE_MM: xyMetricGrid = ONE_CM; break; } RedrawRulers(); } else { Msg(TgLoadString(STID_AT_MAX_GRID_GRID_SZ_SAME)); } } void DecGrid() { if (!snapOn) { Msg(TgLoadString(STID_SNAP_NOT_ON_GRID_SZ_SAME)); } else if (gridSystem == ENGLISH_GRID && xyEnglishGrid > 4) { xyEnglishGrid >>= 1; RedrawRulers(); } else if (gridSystem == METRIC_GRID && xyMetricGrid > ONE_MM) { switch (xyMetricGrid) { case TWO_MM: xyMetricGrid = ONE_MM; break; case FIVE_MM: xyMetricGrid = TWO_MM; break; case ONE_CM: xyMetricGrid = FIVE_MM; break; } RedrawRulers(); } else { Msg(TgLoadString(STID_AT_MIN_GRID_GRID_SZ_SAME)); } } void ToggleGridShown() { gridShown = !gridShown; ClearAndRedrawDrawWindow(); UpdatePinnedMenu(MENU_LAYOUT); } void ToggleSnapOn() { snapOn = !snapOn; if (snapOn) { Msg(TgLoadString(STID_SNAP_TO_GRID_ACTV)); } else { Msg(TgLoadString(STID_SNAP_TO_GRID_DISABLED)); } RedrawRulers(); UpdatePinnedMenu(MENU_LAYOUT); } void ToggleColorPostScript() { colorDump = !colorDump; if (colorDump) { Msg(TgLoadString(STID_WILL_PRINT_IN_COLOR)); } else { Msg(TgLoadString(STID_WILL_PRINT_IN_BW)); } ShowWhereToPrint(); SetFileModified(TRUE); UpdatePinnedMenu(MENU_LAYOUT); UpdatePinnedMenu(MENU_FILE); } void ToggleMoveMode() { moveMode = !moveMode; switch (moveMode) { case CONST_MOVE: Msg(TgLoadString(STID_CONSTRAINED_MOVE)); break; case UNCONST_MOVE: Msg(TgLoadString(STID_UNCONSTRAINED_MOVE)); break; } ShowMoveMode(); UpdatePinnedMenu(MENU_LAYOUT); UpdatePinnedMenu(MENU_MOVEMODE); } void ToggleMapShown() { mapShown = !mapShown; if (mapShown) { Msg(TgLoadString(STID_WILL_DISPLAY_XBM_XPM)); } else { Msg(TgLoadString(STID_WILL_NOT_DISPLAY_XBM_XPM)); } ClearAndRedrawDrawWindow(); UpdatePinnedMenu(MENU_LAYOUT); } void ToggleUseGray() { useGray = !useGray; if (useGray) { Msg(TgLoadString(STID_GRAY_SCALE_IN_BW_PRINTING)); } else { Msg(TgLoadString(STID_NO_GRAY_SCALE_IN_BW_PRINTING)); } SetFileModified(TRUE); UpdatePinnedMenu(MENU_LAYOUT); } void SetMeasureUnit() { char buf[MAXSTRING+1], spec[MAXSTRING+1]; GetUnitSpec(gszMsgBox); sprintf(buf, TgLoadString(STID_CURRENT_SPEC_IS), gszMsgBox); strcpy(gszMsgBox, TgLoadString(STID_ENTER_MEASURE_UNIT_SPEC)); *spec = '\0'; Dialog(gszMsgBox, buf, spec); UtilTrimBlanks(spec); if (*spec == '\0') return; if (SetUnit(spec)) { RedrawRulers(); ShowUnitMsg(); SetFileModified(TRUE); } } void ToggleShowMenubar() { noMenubar = !noMenubar; if (noMenubar) { XUnmapWindow(mainDisplay, menubarWindow); } else { XMapWindow(mainDisplay, menubarWindow); } Reconfigure(TRUE); UpdatePinnedMenu(MENU_LAYOUT); } void ToggleShowStatus() { noStatusWindow = !noStatusWindow; if (noStatusWindow) { XUnmapWindow(mainDisplay, userRedrawWindow); XUnmapWindow(mainDisplay, statusWindow); } else { XMapWindow(mainDisplay, userRedrawWindow); XMapWindow(mainDisplay, statusWindow); } Reconfigure(TRUE); UpdatePinnedMenu(MENU_LAYOUT); } void ToggleShowChoicebar() { noChoiceWindow = !noChoiceWindow; if (noChoiceWindow) { XUnmapWindow(mainDisplay, choiceWindow); XUnmapWindow(mainDisplay, msgWindow); } else { XMapWindow(mainDisplay, choiceWindow); XMapWindow(mainDisplay, msgWindow); } Reconfigure(TRUE); UpdatePinnedMenu(MENU_LAYOUT); } void ToggleShowMode() { noModeWindow = !noModeWindow; if (noModeWindow) { XUnmapWindow(mainDisplay, modeWindow); } else { XMapWindow(mainDisplay, modeWindow); } Reconfigure(TRUE); UpdatePinnedMenu(MENU_LAYOUT); } static void WhereToPrintMsg() { if (whereToPrint >= MAXDEFWHERETOPRINT) { sprintf(gszMsgBox, TgLoadString(STID_WILL_EXPORT_FORMAT_FILE), GetExportName(whereToPrint, EXPORT_THIS)); Msg(gszMsgBox); } else { switch (whereToPrint) { case PRINTER: Msg(TgLoadString(STID_PRINT_DEV_SET_TO_PRINTER)); break; case LATEX_FIG: Msg(TgLoadString(STID_WILL_EXPORT_EPS_FILE)); break; case PS_FILE: Msg(TgLoadString(STID_WILL_EXPORT_RAW_PS_FILE)); break; case XBM_FILE: Msg(TgLoadString(colorDump ? STID_WILL_EXPORT_XPM_FILE : STID_WILL_EXPORT_XBM_FILE)); break; case TEXT_FILE: Msg(TgLoadString(STID_WILL_EXPORT_TEXT_FILE)); break; case EPSI_FILE: Msg(TgLoadString(STID_WILL_EXPORT_EPSI_FILE)); break; case GIF_FILE: Msg(TgLoadString(STID_WILL_EXPORT_GIF_FILE)); break; case HTML_FILE: Msg(TgLoadString(STID_WILL_EXPORT_HTML_FILE)); break; case PDF_FILE: Msg(TgLoadString(STID_WILL_EXPORT_PDF_FILE)); break; case TIFFEPSI_FILE: Msg(TgLoadString(STID_WILL_EXPORT_TIFFEPSI_FILE)); break; case PNG_FILE: Msg(TgLoadString(STID_WILL_EXPORT_PNG_FILE)); break; case JPEG_FILE: Msg(TgLoadString(STID_WILL_EXPORT_JPEG_FILE)); break; case PPM_FILE: Msg(TgLoadString(colorDump ? STID_WILL_EXPORT_PPM_FILE : STID_WILL_EXPORT_PBM_FILE)); break; case NETLIST_FILE: Msg(TgLoadString(STID_WILL_EXPORT_NETLIST_FILE)); break; case SVG_FILE: Msg(TgLoadString(STID_WILL_EXPORT_SVG_FILE)); break; } } } void SetWhereToPrint(nIndex) int nIndex; { whereToPrint = nIndex; WhereToPrintMsg(); ShowWhereToPrint(); UpdatePinnedMenu(MENU_LAYOUT); UpdatePinnedMenu(MENU_FILE); } void ToggleWhereToPrint() { int nIndex=0; char szLeft[MAXSTRING], szRight[MAXSTRING]; whereToPrint = (whereToPrint+1) % maxWhereToPrint; WhereToPrintMsg(); ShowWhereToPrint(); UpdatePinnedMenu(MENU_FILE); nIndex = GetExportIndex(whereToPrint, EXPORT_NEXT); if (nIndex == PRINTER) { sprintf(szLeft, TgLoadCachedString(CSTID_PRINT_MODE), GetExportName(whereToPrint, EXPORT_NEXT)); } else { sprintf(szLeft, TgLoadCachedString(CSTID_EXPORT_MODE), GetExportName(whereToPrint, EXPORT_NEXT)); } nIndex = GetExportIndex(whereToPrint, EXPORT_PREV); if (nIndex == PRINTER) { sprintf(szRight, TgLoadCachedString(CSTID_PRINT_MODE), GetExportName(whereToPrint, EXPORT_PREV)); } else { sprintf(szRight, TgLoadCachedString(CSTID_EXPORT_MODE), GetExportName(whereToPrint, EXPORT_PREV)); } SetMouseStatus(szLeft, TgLoadCachedString(CSTID_LAYOUT_MENU), szRight); } void ToggleOneMotionSelectMove() { oneMotionSelectMove = !oneMotionSelectMove; if (oneMotionSelectMove) { Msg(TgLoadString(STID_ONE_MOTION_SEL_MOVE_MODE)); } else { Msg(TgLoadString(STID_CLICK_SEL_CLICK_MOVE_MODE)); } UpdatePinnedMenu(MENU_LAYOUT); } void ToggleColorLayers() { if (!colorDisplay) { MsgBox(TgLoadString(STID_CANT_TOGGLE_COLOR_LAYER_BW), TOOL_NAME, INFO_MB); return; } colorLayers = !colorLayers; if (colorLayers) { XMapWindow(mainDisplay, colorWindow); XMapWindow(mainDisplay, colorDummyWindow); Msg(TgLoadString(STID_COLOR_LAYERS_ENABLED)); } else { XUnmapWindow(mainDisplay, colorWindow); XUnmapWindow(mainDisplay, colorDummyWindow); Msg(TgLoadString(STID_COLOR_LAYERS_DISABLED)); } Reconfigure(TRUE); UpdatePinnedMenu(MENU_LAYOUT); ClearAndRedrawDrawWindow(); } void ToggleStretchableText() { stretchableText = !stretchableText; if (stretchableText) { Msg(TgLoadString(STID_STRETCHABLE_TEXT_MODE)); } else { Msg(TgLoadString(STID_NON_STRETCHABLE_TEXT_MODE)); } ShowStretchableTextMode(); UpdatePinnedMenu(MENU_STRETCHTEXT); } void ToggleTransPatMode() { transPat = !transPat; if (transPat) { Msg(TgLoadString(STID_TRANS_PAT_MODE)); } else { Msg(TgLoadString(STID_NON_TRANS_PAT_MODE)); } ShowTransPatMode(); UpdatePinnedMenu(MENU_TRANSPAT); } static void PostZoom(xc, yc) int xc, yc; { int new_orig_x=0, new_orig_y=0; UpdDrawWinWH(); new_orig_x = ((xc<<1)-drawWinW)>>1; new_orig_y = ((yc<<1)-drawWinH)>>1; drawOrigX = max(0,new_orig_x); drawOrigY = max(0,new_orig_y); if (drawOrigX>=0 && drawWinW<paperWidth && drawOrigX+drawWinW>=paperWidth) { switch (gridSystem) { case ENGLISH_GRID: if ((paperWidth-drawWinW) % ABS_SIZE(HALF_INCH) == 0) { drawOrigX = paperWidth-drawWinW; } else { drawOrigX = max(0, ((int)((paperWidth-drawWinW)/ ABS_SIZE(HALF_INCH)) + 1) * ABS_SIZE(HALF_INCH)); } break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { if ((paperWidth-drawWinW) % ABS_SIZE(FAKE_CM) == 0) { drawOrigX = paperWidth-drawWinW; } else { drawOrigX = max(0, ((int)((paperWidth-drawWinW)/ ABS_SIZE(FAKE_CM)) + 1) * ABS_SIZE(FAKE_CM)); } } else { if ((paperWidth-drawWinW) % ABS_SIZE(ONE_CM) == 0) { drawOrigX = paperWidth-drawWinW; } else { drawOrigX = max(0, ((int)((paperWidth-drawWinW)/ ABS_SIZE(ONE_CM)) + 1) * ABS_SIZE(ONE_CM)); } } break; } } else if (drawOrigX < 0 || drawWinW >= paperWidth) { drawOrigX = 0; } if (drawOrigY>=0 && drawWinH<paperHeight && drawOrigY+drawWinH>=paperHeight) { switch (gridSystem) { case ENGLISH_GRID: if ((paperHeight-drawWinH) % ABS_SIZE(HALF_INCH) == 0) { drawOrigY = paperHeight-drawWinH; } else { drawOrigY = max(0, ((int)((paperHeight-drawWinH)/ ABS_SIZE(HALF_INCH)) + 1) * ABS_SIZE(HALF_INCH)); } break; case METRIC_GRID: if (zoomedIn && zoomScale > 1) { if ((paperHeight-drawWinH) % ABS_SIZE(FAKE_CM) == 0) { drawOrigY = paperHeight-drawWinH; } else { drawOrigY = max(0, ((int)((paperHeight-drawWinH)/ ABS_SIZE(FAKE_CM)) + 1) * ABS_SIZE(FAKE_CM)); } } else { if ((paperHeight-drawWinH) % ABS_SIZE(ONE_CM) == 0) { drawOrigY = paperHeight-drawWinH; } else { drawOrigY = max(0, ((int)((paperHeight-drawWinH)/ ABS_SIZE(ONE_CM)) + 1) * ABS_SIZE(ONE_CM)); } } break; } } else if (drawOrigY < 0 || drawWinH >= paperHeight) { drawOrigY = 0; } drawOrigX = ABS_SIZE(ZOOMED_SIZE(drawOrigX)); drawOrigY = ABS_SIZE(ZOOMED_SIZE(drawOrigY)); UpdDrawWinBBox(); SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); RedrawRulers(); RedrawScrollBars(); AdjSplineVs(); AdjCaches(); ShowZoom(); /* use to be ClearAndRedrawDrawWindowDontDrawCurText() */ ClearAndRedrawDrawWindowNoCurT(); SetDefaultCursor(mainWindow); ShowCursor(); justDupped = FALSE; if (!(curChoice==DRAWTEXT && textCursorShown)) { ShowCurChoiceMouseStatus(curChoice, 0, FALSE); } } void DefaultZoom() { int xc, yc; if (zoomScale == 0) { Msg(TgLoadString(STID_ALREADY_AT_DEF_ZOOM)); return; } if (curChoice==DRAWTEXT && textCursorShown) { PrepareZoomCurText(&xc, &yc); } else { xc = (topSel==NULL) ? ((drawOrigX<<1)+drawWinW)>>1 : (selLtX+selRbX)>>1; yc = (topSel==NULL) ? ((drawOrigY<<1)+drawWinH)>>1 : (selLtY+selRbY)>>1; } if (curChoice == VERTEXMODE) { TieLooseEnds(); SetCurChoice(NOTHING); } zoomScale = 0; zoomedIn = FALSE; if (curChoice==DRAWTEXT && textCursorShown) PreZoomCurText(); PostZoom(xc, yc); if (curChoice==DRAWTEXT && textCursorShown) PostZoomCurText(xc, yc); } static int zoomInAbsX=0, zoomInAbsY=0; static int zoomInAtCursor=FALSE; static int panAtCursor=FALSE; static void FixUpZoomCenter(p_abs_cx, p_abs_cy, zooming_in) int *p_abs_cx, *p_abs_cy, zooming_in; { int saved_zoomed_in=zoomedIn, saved_zoom_scale=zoomScale; int anchor_x_off=OFFSET_X(*p_abs_cx), anchor_y_off=OFFSET_Y(*p_abs_cy); int new_anchor_abs_x=0, new_anchor_abs_y=0; int abs_dx=0, abs_dy=0, new_abs_cx=0, new_abs_cy=0; switch (zooming_in) { case INVALID: break; case FALSE: if (!zoomedIn) { zoomScale++; } else if (zoomScale == 1) { zoomedIn = FALSE; zoomScale--; } else { zoomScale--; } break; default: if (zoomedIn) { zoomScale++; } else if (zoomScale == 0) { zoomedIn = TRUE; zoomScale++; } else { zoomScale--; } break; } UpdDrawWinWH(); new_anchor_abs_x = ABS_X(anchor_x_off); new_anchor_abs_y = ABS_Y(anchor_y_off); new_abs_cx = (((drawOrigX<<1)+drawWinW)>>1); new_abs_cy = (((drawOrigY<<1)+drawWinH)>>1); abs_dx = new_abs_cx - new_anchor_abs_x; abs_dy = new_abs_cy - new_anchor_abs_y; if (zooming_in) { *p_abs_cx += (abs_dx); *p_abs_cy += (abs_dy); } else { *p_abs_cx += (abs_dx); *p_abs_cy += (abs_dy); } zoomedIn = saved_zoomed_in; zoomScale = saved_zoom_scale; UpdDrawWinWH(); } void ZoomIn() { int xc=0, yc=0, need_to_restore_cur_choice=FALSE; if (zoomedIn && zoomScale == MAX_ZOOMED_IN && !(zoomInAtCursor && panAtCursor)) { MsgBox(TgLoadString(STID_ALREADY_AT_HIGHEST_MAG), TOOL_NAME, INFO_MB); return; } if (curChoice==DRAWTEXT && textCursorShown) { if (zoomInAtCursor) { sprintf(gszMsgBox, " %s", TgLoadString(STID_CURSOR_IGNORED_CSBTN1)); TwoLineMsg(TgLoadString(STID_ZOOMIN_AROUND_EDIT_TEXT), gszMsgBox); } PrepareZoomCurText(&xc, &yc); } else if (zoomInAtCursor) { xc = zoomInAbsX; yc = zoomInAbsY; if (!panAtCursor) { FixUpZoomCenter(&xc, &yc, TRUE); } } else if (queryZoomInPoint==TRUE || (queryZoomInPoint==INVALID && topSel==NULL)) { if (queryZoomInPoint==INVALID && topSel==NULL) { MakeQuiescent(); need_to_restore_cur_choice = TRUE; } SetMouseStatus(TgLoadString(STID_SEL_ZOOM_CENTER), TgLoadCachedString(CSTID_CANCEL), TgLoadCachedString(CSTID_CANCEL)); if (DrawWindowLoop(&xc, &yc, magCursor, FALSE) != Button1) { Msg(TgLoadString(STID_ZOOMIN_CANCEL_BY_USER)); return; } xc = ABS_X(xc); yc = ABS_Y(yc); FixUpZoomCenter(&xc, &yc, TRUE); } else if (queryZoomInPoint == BAD) { Window root_win, child_win; int root_x, root_y; unsigned int status; XQueryPointer(mainDisplay, drawWindow, &root_win, &child_win, &root_x, &root_y, &xc, &yc, &status); xc = ABS_X(xc); yc = ABS_Y(yc); FixUpZoomCenter(&xc, &yc, TRUE); } else { xc = (topSel==NULL) ? ((drawOrigX<<1)+drawWinW)>>1 : (selLtX+selRbX)>>1; yc = (topSel==NULL) ? ((drawOrigY<<1)+drawWinH)>>1 : (selLtY+selRbY)>>1; } if (curChoice == VERTEXMODE) { TieLooseEnds(); SetCurChoice(NOTHING); } if (!panAtCursor) { if (zoomedIn) { zoomScale++; } else if (zoomScale == 0) { zoomedIn = TRUE; zoomScale++; } else { zoomScale--; } } if (curChoice==DRAWTEXT && textCursorShown) PreZoomCurText(); PostZoom(xc, yc); if (curChoice==DRAWTEXT && textCursorShown) PostZoomCurText(xc, yc); if (need_to_restore_cur_choice) { SetCurChoice(curChoiceBeforeMakeQuiescent); } } void ZoomInAtCursor(abs_x, abs_y) int abs_x, abs_y; { zoomInAbsX = abs_x; zoomInAbsY = abs_y; zoomInAtCursor = TRUE; ZoomIn(); zoomInAtCursor = FALSE; } void ZoomWayOut() { int saved_zoom_scale=zoomScale, saved_zoomed_in=zoomedIn; while ((drawWinW>>1) >= paperWidth && (drawWinH>>1) >= paperHeight) { if (zoomedIn) { zoomScale++; } else if (zoomScale == 0) { zoomedIn = TRUE; zoomScale++; } else { zoomScale--; } drawWinW >>= 1; drawWinH >>= 1; } while (drawWinW < paperWidth || drawWinH < paperHeight) { if (!zoomedIn) { zoomScale++; } else if (zoomScale == 1) { zoomedIn = FALSE; zoomScale--; } else { zoomScale--; } drawWinW <<= 1; drawWinH <<= 1; } if (saved_zoom_scale==zoomScale && saved_zoomed_in==zoomedIn && drawOrigX==0 && drawOrigY==0) { return; } TieLooseEnds(); SetCurChoice(NOTHING); PostZoom(0, 0); } void ZoomOut() { int xc, yc; if (paperWidth <= drawWinW && paperHeight <= drawWinH) { MsgBox(TgLoadString(STID_AT_PAPER_EDGE_CANT_ZOOMOUT), TOOL_NAME, INFO_MB); return; } if (curChoice==DRAWTEXT && textCursorShown) { PrepareZoomCurText(&xc, &yc); } else if (queryZoomInPoint == BAD) { Window root_win, child_win; int root_x, root_y; unsigned int status; XQueryPointer(mainDisplay, drawWindow, &root_win, &child_win, &root_x, &root_y, &xc, &yc, &status); xc = ABS_X(xc); yc = ABS_Y(yc); FixUpZoomCenter(&xc, &yc, FALSE); } else { xc = (topSel==NULL) ? ((drawOrigX<<1)+drawWinW)>>1 : (selLtX+selRbX)>>1; yc = (topSel==NULL) ? ((drawOrigY<<1)+drawWinH)>>1 : (selLtY+selRbY)>>1; } if (curChoice == VERTEXMODE) { TieLooseEnds(); SetCurChoice(NOTHING); } if (!zoomedIn) { zoomScale++; } else if (zoomScale == 1) { zoomedIn = FALSE; zoomScale--; } else { zoomScale--; } if (curChoice==DRAWTEXT && textCursorShown) PreZoomCurText(); PostZoom(xc, yc); if (curChoice==DRAWTEXT && textCursorShown) PostZoomCurText(xc, yc); } void CenterAtCursor(abs_x, abs_y) int abs_x, abs_y; { panAtCursor = TRUE; ZoomInAtCursor(abs_x, abs_y); panAtCursor = FALSE; } void PreciseZoom(zoomed_in, zoom_scale, force_zoom) int zoomed_in, zoom_scale, force_zoom; { int xc, yc; if (!force_zoom && zoomedIn == zoomed_in && zoomScale == zoom_scale) return; if (curChoice==DRAWTEXT && textCursorShown) { PrepareZoomCurText(&xc, &yc); } else { xc = (topSel==NULL) ? ((drawOrigX<<1)+drawWinW)>>1 : (selLtX+selRbX)>>1; yc = (topSel==NULL) ? ((drawOrigY<<1)+drawWinH)>>1 : (selLtY+selRbY)>>1; } if (curChoice == VERTEXMODE) { TieLooseEnds(); SetCurChoice(NOTHING); } zoomedIn = zoomed_in; zoomScale = zoom_scale; if (curChoice==DRAWTEXT && textCursorShown) PreZoomCurText(); PostZoom(xc, yc); if (curChoice==DRAWTEXT && textCursorShown) PostZoomCurText(xc, yc); } void SetPSPageWidthHeight() { if (psYOffStr != NULL && psYOff != NULL) { float fval=(float)0; fval = (float)(((float)onePageHeight)/((float)PIX_PER_INCH)); FormatFloat(&fval, psYOffStr[0]); psYOff[0] = ((float)onePageHeight)/((float)PIX_PER_INCH); psPageWidthInInch[0]=((float)onePageWidth)/((float)PIX_PER_INCH); psPageWidthInInch[1]=((float)onePageHeight)/((float)PIX_PER_INCH); psPageHeightInInch[0]=((float)onePageHeight)/((float)PIX_PER_INCH); psPageHeightInInch[1]=((float)onePageWidth)/((float)PIX_PER_INCH); } } void ResetOnePageSize() { /* reset 8.5in x 11in */ #ifndef A4PAPER onePageWidth = (85*PIX_PER_INCH)/10; onePageHeight = 11*PIX_PER_INCH; #else /* A4PAPER */ onePageWidth = (825*PIX_PER_INCH)/100; onePageHeight = (117*PIX_PER_INCH)/10; #endif /* A4PAPER */ SetPSPageWidthHeight(); } int UpdPageStyle(NewPageStyle) int NewPageStyle; { int changed=FALSE, old_w=paperWidth, old_h=paperHeight; pageStyle = NewPageStyle; onePageWidth = round(psPageWidthInInch[NewPageStyle]*PIX_PER_INCH*100.0/printMag); onePageHeight = round(psPageHeightInInch[NewPageStyle]*PIX_PER_INCH*100.0/printMag); paperWidth = onePageWidth * paperCol; paperHeight = onePageHeight * paperRow; if (drawOrigX+drawWinW > paperWidth || drawOrigX+drawWinW > old_w) { if (drawOrigX+drawWinW > paperWidth) { int tmp_x=paperWidth-drawWinW; switch (gridSystem) { case ENGLISH_GRID: if (zoomedIn) { if ((ZOOMED_SIZE(tmp_x) % HALF_INCH) == 0) { drawOrigX = max(0,tmp_x); } else { drawOrigX = max(0,((int)(ZOOMED_SIZE(tmp_x)/HALF_INCH)) * HALF_INCH); } } else { if ((tmp_x % (ABS_SIZE(HALF_INCH))) == 0) { drawOrigX = max(0,tmp_x); } else { drawOrigX = max(0,((int)(tmp_x/ABS_SIZE(HALF_INCH))) * ABS_SIZE(HALF_INCH)); } } break; case METRIC_GRID: if (zoomedIn) { if (zoomScale > 1) { if ((ZOOMED_SIZE(tmp_x) % ONE_CM) == 0) { drawOrigX = max(0,tmp_x); } else { drawOrigX = max(0,((int)(ZOOMED_SIZE(tmp_x)/ONE_CM)) * ONE_CM); } } else { if ((ZOOMED_SIZE(tmp_x) % FAKE_CM) == 0) { drawOrigX = max(0,tmp_x); } else { drawOrigX = max(0,((int)(ZOOMED_SIZE(tmp_x)/FAKE_CM)) * FAKE_CM); } } } else { if ((tmp_x % (ABS_SIZE(ONE_CM))) == 0) { drawOrigX = max(0,tmp_x); } else { drawOrigX = max(0,((int)(tmp_x/ABS_SIZE(ONE_CM))) * ABS_SIZE(ONE_CM)); } } break; } } drawOrigX = ABS_SIZE(ZOOMED_SIZE(drawOrigX)); changed = TRUE; } if (drawOrigY+drawWinH > paperHeight || drawOrigY+drawWinH > old_h) { if (drawOrigY+drawWinH > paperHeight) { int tmp_y=paperHeight-drawWinH; switch (gridSystem) { case ENGLISH_GRID: if (zoomedIn) { if ((ZOOMED_SIZE(tmp_y) % HALF_INCH) == 0) { drawOrigY = max(0,tmp_y); } else { drawOrigY = max(0,((int)(ZOOMED_SIZE(tmp_y)/HALF_INCH)) * HALF_INCH); } } else { if ((tmp_y % (ABS_SIZE(HALF_INCH))) == 0) { drawOrigY = max(0,tmp_y); } else { drawOrigY = max(0,((int)(tmp_y/ABS_SIZE(HALF_INCH))) * ABS_SIZE(HALF_INCH)); } } break; case METRIC_GRID: if (zoomedIn) { if (zoomScale > 1) { if ((ZOOMED_SIZE(tmp_y) % FAKE_CM) == 0) { drawOrigY = max(0,tmp_y); } else { drawOrigY = max(0,((int)(ZOOMED_SIZE(tmp_y)/FAKE_CM)) * FAKE_CM); } } else { if ((ZOOMED_SIZE(tmp_y) % ONE_CM) == 0) { drawOrigY = max(0,tmp_y); } else { drawOrigY = max(0,((int)(ZOOMED_SIZE(tmp_y)/ONE_CM)) * ONE_CM); } } } else { if ((tmp_y % (ABS_SIZE(ONE_CM))) == 0) { drawOrigY = max(0,tmp_y); } else { drawOrigY = max(0,((int)(tmp_y/ABS_SIZE(ONE_CM))) * ABS_SIZE(ONE_CM)); } } break; } } drawOrigY = ABS_SIZE(ZOOMED_SIZE(drawOrigY)); changed = TRUE; } return changed; } void ChangePageStyle(NewPageStyle) int NewPageStyle; { if (pageStyle != NewPageStyle) { if (UpdPageStyle(NewPageStyle)) { UpdDrawWinBBox(); AdjSplineVs(); ClearAndRedrawDrawWindow(); } ShowFile(); UpdatePinnedMenu(MENU_LAYOUT); RedrawScrollBars(); RedrawRulers(); SetFileModified(TRUE); switch (NewPageStyle) { case LANDSCAPE: Msg(TgLoadString(STID_PAGE_STYLE_CHANGE_TO_LAND)); break; case PORTRAIT: Msg(TgLoadString(STID_PAGE_STYLE_CHANGE_TO_PORT)); break; } } } int RefreshPageStyleMenu(menu) TgMenu *menu; { int ok=TRUE; /* Portrait */ ok &= TgSetMenuItemRadioById(menu, CMDID_PORTRAITMODE, (pageStyle==PORTRAIT)); /* Landscape */ ok &= TgSetMenuItemRadioById(menu, CMDID_LANDSCAPEMODE, (pageStyle==LANDSCAPE)); return ok; } TgMenu *CreatePageStyleMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshPageStyleMenu(menu)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int PageStyleMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(pageStyleMenuInfo.create_proc)(NULL, X, Y, &pageStyleMenuInfo, INVALID); activeMenu = INVALID; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } void RefreshExportFormatMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == whereToPrint); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateExportFormatMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { int i=0; TgMenu *menu=NULL; TgMenuInfo stMenuInfo; TgMenuItemInfo *item_info=NULL; memcpy(&stMenuInfo, menu_info, sizeof(TgMenuInfo)); stMenuInfo.items = (TgMenuItemInfo*)malloc( (maxWhereToPrint+1)*sizeof(TgMenuItemInfo)); if (stMenuInfo.items == NULL) FailAllocMessage(); memset(stMenuInfo.items, 0, (maxWhereToPrint+1)*sizeof(TgMenuItemInfo)); for (item_info=stMenuInfo.items, i=0; i < maxWhereToPrint; item_info++, i++) { item_info->menu_str = (char*)(Pixmap*)(&whereToPrintPixmap[i]); item_info->shortcut_str = NULL; if (i < MAXDEFWHERETOPRINT) { strcpy(gszMsgBox, ExportFormatMenuLoadString(i, colorDump)); } else { sprintf(gszMsgBox, ExportFormatMenuLoadString(i, colorDump), GetExportName(i, EXPORT_THIS)); } item_info->status_str = UtilStrDup(gszMsgBox); if (item_info->status_str == NULL) FailAllocMessage(); item_info->submenu_info = NULL; item_info->cmdid = CMDID_SETWHERETOPRINT; } stMenuInfo.items[maxWhereToPrint].cmdid = INVALID; /* the status_str has been translated in ExportFormatMenuLoadString() */ menu = TgCreateMenuFromMenuInfo(parent_menu, x, y, &stMenuInfo, TRUE); for (item_info=stMenuInfo.items, i=0; i < maxWhereToPrint; item_info++, i++) { UtilFree(item_info->status_str); } memset(stMenuInfo.items, 0, (maxWhereToPrint+1)*sizeof(TgMenuItemInfo)); free(stMenuInfo.items); stMenuInfo.items = NULL; if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, maxWhereToPrint); menu_item = (&menu->menuitems[whereToPrint]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshExportFormatMenu); } return menu; } int ExportFormatMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(exportFormatMenuInfo.create_proc)(NULL, X, Y, &exportFormatMenuInfo, INVALID); activeMenu = INVALID; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } int RefreshShowHideMenu(menu) TgMenu *menu; { int ok=TRUE; /* ShowBit/Pixmap */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEMAPSHOWN, mapShown); /* ShowMeasurement */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLESHOWMEASUREMENT, showMeasurement); if (!showMeasurement) { ok &= TgEnableMenuItemById(menu, CMDID_TOGGLESHOWMEASUREMENTINTT, FALSE); } /* ShowMeasurementInTooltip */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLESHOWMEASUREMENTINTT, showMeasurementInTooltip); /* ShowMenubar */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLESHOWMENUBAR, !noMenubar); /* ShowStatus */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLESHOWSTATUS, !noStatusWindow); /* ShowChoice */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLESHOWCHOICEBAR, !noChoiceWindow); /* ShowMode */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLESHOWMODE, !noModeWindow); /* ToggleRightMargin */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLERIGHTMARGIN, rightMarginEnabled == TRUE); /* SpecifyRightMargin */ ok &= TgEnableMenuItemById(menu, CMDID_SPECIFYRIGHTMARGIN, rightMarginEnabled == TRUE); if (gstWBInfo.do_whiteboard) { /* ShowChat */ ok &= TgEnableMenuItemById(menu, CMDID_TOGGLESHOWCHAT, TRUE); ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLESHOWCHAT, !noChatWindow); } else { ok &= TgEnableMenuItemById(menu, CMDID_TOGGLESHOWCHAT, FALSE); } return ok; } TgMenu *CreateShowHideMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshShowHideMenu(menu)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int RefreshLayoutMenu(menu) TgMenu *menu; { int ok=TRUE; /* VisibleGrid */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEGRID, gridShown); /* SnapToGrid */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLESNAP, snapOn); /* Landscape */ ok &= TgSetMenuItemRadioById(menu, CMDID_LANDSCAPEMODE, (pageStyle==LANDSCAPE)); /* Portrait */ ok &= TgSetMenuItemRadioById(menu, CMDID_PORTRAITMODE, (pageStyle==PORTRAIT)); /* Print/ExportInColor */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEBWCOLORPS, colorDump); /* MetricGrid */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEGRIDSYSTEM, (gridSystem==METRIC_GRID)); /* OneMotionSelMove */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEONEMOTIONSELMOVE, oneMotionSelectMove); /* UseGrayScale */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEUSEGRAYSCALE, useGray); /* UseColorLayers */ ok &= TgEnableMenuItemById(menu, CMDID_TOGGLECOLORLAYERS, colorDisplay); if (colorDisplay) { ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLECOLORLAYERS, colorLayers); } else { ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLECOLORLAYERS, FALSE); } /* StackedPage */ ok &= TgEnableMenuItemById(menu, MENU_STACKEDPAGE, (pageLayoutMode==PAGE_STACK)); /* TiledPage */ ok &= TgEnableMenuItemById(menu, MENU_TILEDPAGE, (pageLayoutMode!=PAGE_STACK)); return ok; } TgMenu *CreateLayoutMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshLayoutMenu(menu)) { return TgDestroyMenu(menu, TRUE); } } return menu; } int LayoutMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(layoutMenuInfo.create_proc)(NULL, X, Y, &layoutMenuInfo, INVALID); activeMenu = MENU_LAYOUT; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } int GridSize() { int grid=1; if (snapOn) { switch (gridSystem) { case ENGLISH_GRID: grid = xyEnglishGrid; break; case METRIC_GRID: grid = xyMetricGrid; break; } if (zoomedIn) { grid <<= zoomScale; } } else { if (zoomedIn) { grid = 1 << zoomScale; } } return grid; } void GridXY(X, Y, GridX, GridY) int X, Y, *GridX, *GridY; { int dx, dy, grid=GridSize(); if (snapOn) { if (zoomedIn) { dx = (X+(drawOrigX<<zoomScale)) % grid; dy = (Y+(drawOrigY<<zoomScale)) % grid; } else { dx = (X+(drawOrigX>>zoomScale)) % grid; dy = (Y+(drawOrigY>>zoomScale)) % grid; } *GridX = ((dx<<1) < grid) ? X-dx : X-dx+grid; *GridY = ((dy<<1) < grid) ? Y-dy : Y-dy+grid; } else { if (zoomedIn) { dx = (X+(drawOrigX<<zoomScale)) % grid; dy = (Y+(drawOrigY<<zoomScale)) % grid; *GridX = ((dx<<1) < grid) ? X-dx : X-dx+grid; *GridY = ((dy<<1) < grid) ? Y-dy : Y-dy+grid; } else { *GridX = X; *GridY = Y; } } } int ControlKeyPressedEvent(ev) XEvent *ev; { if (ev->type == KeyPress || ev->type == KeyRelease) { char s[80]; KeySym key_sym; XLookupString(&(ev->xkey), s, sizeof(s), &key_sym, NULL); if (key_sym == XK_Control_L || key_sym == XK_Control_R) { return (ev->type == KeyPress); } } return FALSE; } int DiagEventCheck(ev) XEvent *ev; { static int prev_diag_state=FALSE; if (ev->type == MotionNotify) { prev_diag_state = (ev->xmotion.state & ShiftMask) && (!(ev->xmotion.state & ControlMask)); } else if (ev->type == KeyPress || ev->type == KeyRelease) { char s[80]; KeySym key_sym; XLookupString(&(ev->xkey), s, sizeof(s), &key_sym, NULL); if (key_sym == XK_Shift_L || key_sym == XK_Shift_R) { prev_diag_state = (ev->type == KeyPress); return TRUE; } } return prev_diag_state; } void DiagGridXY(OrigX, OrigY, NewX, NewY) int OrigX, OrigY, *NewX, *NewY; { int X=(*NewX), Y=(*NewY); int dx, dy; int p0, p1, p2, p3; dx = OrigX - X; dy = OrigY - Y; p0 = dy - (dx >> 1); /* y = x/2 */ p1 = (dy >> 1) - dx; /* y = 2x */ p2 = (dy >> 1) + dx; /* y = -2x */ p3 = dy + (dx >> 1); /* y = -x/2 */ if ( (p3 ^ p0) < 0) { Y = OrigY; } else if ( (p0 ^ p1) < 0) { X = OrigX - ((dx + dy)>>1); Y = OrigY - ((dx + dy)>>1); } else if ( (p1 ^ p2) >= 0) { X = OrigX; } else { X = OrigX - ((dx - dy)>>1); Y = OrigY + ((dx - dy)>>1); if ((GridSize() & 0x1) == 0) { X--; } } (*NewX) = X; (*NewY) = Y; } void CleanUpGrids() { } void MoveModeSubMenu(index) int index; { moveMode = index; switch (moveMode) { case CONST_MOVE: Msg(TgLoadString(STID_CONSTRAINED_MOVE)); break; case UNCONST_MOVE: Msg(TgLoadString(STID_UNCONSTRAINED_MOVE)); break; } ShowMoveMode(); UpdatePinnedMenu(MENU_LAYOUT); UpdatePinnedMenu(MENU_MOVEMODE); } void RefreshMoveModeMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == moveMode); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateMoveModeMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, MAXMOVEMODES); menu_item = (&menu->menuitems[moveMode]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshMoveModeMenu); } return menu; } int MoveModeMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(moveModeMenuInfo.create_proc)(NULL, X, Y, &moveModeMenuInfo, INVALID); activeMenu = MENU_MOVEMODE; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } void StretchableTextModeSubMenu(index) int index; { stretchableText = index; switch (stretchableText) { case NO_STRETCHABLE_TEXT: Msg(TgLoadString(STID_NON_STRETCHABLE_TEXT_MODE)); break; case STRETCHABLE_TEXT: Msg(TgLoadString(STID_STRETCHABLE_TEXT_MODE)); break; } ShowStretchableTextMode(); UpdatePinnedMenu(MENU_STRETCHTEXT); } void RefreshStretchableTextModeMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == stretchableText); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateStretchableTextModeMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, MAXSTRETCHABLEMODES); menu_item = (&menu->menuitems[stretchableText]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshStretchableTextModeMenu); } return menu; } int StretchableTextModeMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(stretchableTextModeMenuInfo.create_proc)(NULL, X, Y, &stretchableTextModeMenuInfo, INVALID); activeMenu = MENU_STRETCHTEXT; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } void RefreshTransPatModeMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == transPat); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateTransPatModeMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, MAXTRANSPATMODES); menu_item = (&menu->menuitems[transPat]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshTransPatModeMenu); } return menu; } int TransPatModeMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(transPatModeMenuInfo.create_proc)(NULL, X, Y, &transPatModeMenuInfo, INVALID); activeMenu = MENU_TRANSPAT; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } int RefreshGridMenu(menu) TgMenu *menu; { int ok=TRUE; /* VisibleGrid */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEGRID, gridShown); /* SnapToGrid */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLESNAP, snapOn); /* MetricGrid */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEGRIDSYSTEM, (gridSystem==METRIC_GRID)); /* ToggleRightMargin */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLERIGHTMARGIN, rightMarginEnabled == TRUE); /* SpecifyRightMargin */ ok &= TgEnableMenuItemById(menu, CMDID_SPECIFYRIGHTMARGIN, rightMarginEnabled == TRUE); return ok; } TgMenu *CreateGridMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshGridMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshGridMenu); } return menu; } int GridMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(gridMenuInfo.create_proc)(NULL, X, Y, &gridMenuInfo, INVALID); activeMenu = INVALID; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/convkinput.e�������������������������������������������������������������������������0000644�0000764�0000764�00000005122�11602233311�015331� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: Yoichiro Ueno (ueno@cs.titech.ac.jp) * * Copyright (C) 1991, 1992, Yoichiro Ueno. * * Permission to use, copy, modify, and distribute this software and * its documentation for any purpose is hereby granted by the Author without * fee, provided that the above copyright notice appear in all copies and * that both the copyright notice and this permission notice appear in * supporting documentation, and that the name of the Author not be used * in advertising or publicity pertaining to distribution of the software * without specific, written prior permission. The Author makes no * representations about the suitability of this software for any purpose. * It is provided "as is" without express or implied warranty. * * THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO * EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF * USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR * OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR * PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/convkinput.e,v 1.1 2004/06/18 23:19:08 william Exp $ */ #ifndef _NO_KINPUT #ifndef _CONVKINPUT_E_ #define _CONVKINPUT_E_ /* protocol of input method */ #define IM_NONE 0 #define IM_KINPUT 1 #define IM_XIM 2 extern int imProtocol; extern int copyAndPasteJIS; extern char kinputConvSelName[]; #ifdef _INCLUDE_FROM_CONVKINPUT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_CONVKINPUT_C_*/ extern void KinputSetConvOverSpot ARGS_DECL((int nConvOverSpot)); extern void KinputTellCursorPosition ARGS_DECL((Display*, Window, int X, int Y)); extern void KinputBeginConversion ARGS_DECL((Display*, Window)); extern void KinputCheckClientMessage ARGS_DECL((Display*, Window, XClientMessageEvent *)); extern void CvtCompoundTextToEuc ARGS_DECL((char *dest, char *src)); extern char * KinputCheckConvProperty ARGS_DECL((Display*, Window, XPropertyEvent *)); extern void KinputEndConversion ARGS_DECL((Display*, Window)); extern void CvtJisToEuc ARGS_DECL((char *dest, char *src)); extern int CvtEucToJis ARGS_DECL((char *dest, char *src)); #ifdef _INCLUDE_FROM_CONVKINPUT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_CONVKINPUT_C_*/ #endif /*_CONVKINPUT_E_*/ #endif /* ~_NO_KINPUT */ ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/dialog.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000137354�11602233311�014403� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/dialog.c,v 1.10 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_DIALOG_C_ #include "tgifdefs.h" #include "auxtext.e" #include "box.e" #include "button.e" #include "cutpaste.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "file.e" #include "font.e" #include "grid.e" #include "mainloop.e" #include "mainmenu.e" #include "menu.e" #include "msg.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "setup.e" #include "strtbl.e" #include "text.e" #include "util.e" int doPassword=FALSE; char gszMsgBox[2048]; int dialogboxUse3DBorder=TRUE; unsigned int CornerLoop(OrigX, OrigY) int *OrigX, *OrigY; { XEvent input; XGrabPointer(mainDisplay, rootWindow, False, ButtonPressMask, GrabModeAsync, GrabModeAsync, None, cornerCursor, CurrentTime); for (;;) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonPress) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); *OrigX = input.xbutton.x; *OrigY = input.xbutton.y; return input.xbutton.button; } } } static XComposeStatus c_stat; unsigned int DrawWindowLoop(OrigX, OrigY, cursor, snap_to_grid) int *OrigX, *OrigY, snap_to_grid; Cursor cursor; { Window focus_win=None; int revert_to=0; XGetInputFocus(mainDisplay, &focus_win, &revert_to); XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonPressMask, GrabModeAsync, GrabModeAsync, None, cursor, CurrentTime); for (;;) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonPress) { XUngrabPointer(mainDisplay, CurrentTime); if (focus_win != mainWindow) { XSetInputFocus(mainDisplay, mainWindow, RevertToPointerRoot, CurrentTime); } XSync(mainDisplay, False); *OrigX = input.xbutton.x; *OrigY = input.xbutton.y; return input.xbutton.button; } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { XUngrabPointer(mainDisplay, CurrentTime); if (focus_win != mainWindow) { XSetInputFocus(mainDisplay, mainWindow, RevertToPointerRoot, CurrentTime); } XSync(mainDisplay, False); return (unsigned int)(-1); } } else if (input.type == MotionNotify) { if (snap_to_grid) { int grid_x, grid_y; GridXY(input.xmotion.x, input.xmotion.y, &grid_x, &grid_y); MarkRulers(grid_x, grid_y); } else { MarkRulers(input.xmotion.x, input.xmotion.y); } } } } unsigned int PickAPoint(OrigX, OrigY, cursor) int *OrigX, *OrigY; Cursor cursor; { XEvent input; #ifdef _TGIF_DBG if (!debugNoPointerGrab) { #endif /* _TGIF_DBG */ XGrabPointer(mainDisplay, drawWindow, False, ButtonPressMask, GrabModeAsync, GrabModeAsync, None, cursor, CurrentTime); #ifdef _TGIF_DBG } #endif /* _TGIF_DBG */ for (;;) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonPress) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); *OrigX = input.xbutton.x; *OrigY = input.xbutton.y; return input.xbutton.button; } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); return (unsigned int)(-1); } } } } #include "xbm/info.xbm" #define ICON_W (info_width) #define ICON_H (info_height) #define X_MARGIN 20 #define Y_MARGIN 16 #define X_GAP 20 #define Y_GAP 20 #define SPACING 0 #define BTN_X_MARGIN 8 #define BTN_Y_MARGIN 2 #define BTN_XY_EXTRA 2 #define BTN_MIN_X_GAP 8 #define MAX_KEYSYMS 10 #define LF_BUTTON 0x01 #define MD_BUTTON 0x02 #define RT_BUTTON 0x03 #define XT_BUTTON 0x04 #define DEF_BUTTON 0x10 #define MAX_BUTTONS 3 #define MAX_BTN_STR_LEN 10 typedef struct BtnInfoRec { char * str; struct BBRec bbox; int id, highlight; KeySym key_sym[MAX_KEYSYMS]; } * BtnInfoRecPtr; typedef struct MBRec { Window main_win, root_win, icon_win, msg_win, btn_win; int main_win_x, main_win_y, main_win_w, main_win_h; int icon_win_w, icon_win_h, msg_win_w, msg_win_h; int btn_win_w, btn_win_h, max_msg_win_w; int max_msg_str_len, max_msg_str_total; int exposed; char * msg_copy; Pixmap cur_bitmap; struct BtnInfoRec btn_info[MAX_BUTTONS+1]; /* dialog specific */ int is_dialog; int cur_x, cur_y, cursor_x, cursor_y, index, str_w; char *return_str; } * MBRecPtr; static struct MBRec mbInfo; static int numButtons=MAX_BUTTONS; static char extraBtnChar='q'; static void SetupMBButton(MBInfoPtr, BtnDesc, BtnCh, BtnID) struct MBRec *MBInfoPtr; int BtnDesc, BtnID; char BtnCh; { char *psz=NULL; int btn_index=(BtnDesc & 0x0f)-1, i=0; switch (BtnID) { case MB_ID_FAILED: psz = NULL; break; case MB_ID_OK: psz = TgLoadCachedString(CSTID_OK); break; case MB_ID_CANCEL: psz = TgLoadCachedString(CSTID_CANCEL); break; case MB_ID_YES: psz = TgLoadCachedString(CSTID_YES); break; case MB_ID_NO: psz = TgLoadCachedString(CSTID_NO); break; case MB_ID_EXTRA: psz = TgLoadCachedString(CSTID_EXTRA); break; } MBInfoPtr->btn_info[btn_index].str = psz; MBInfoPtr->btn_info[btn_index].id = BtnID; switch (BtnCh) { case 'o': MBInfoPtr->btn_info[btn_index].key_sym[i++] = XK_o; MBInfoPtr->btn_info[btn_index].key_sym[i++] = XK_O; break; case 'y': MBInfoPtr->btn_info[btn_index].key_sym[i++] = XK_y; MBInfoPtr->btn_info[btn_index].key_sym[i++] = XK_Y; break; case 'n': MBInfoPtr->btn_info[btn_index].key_sym[i++] = XK_n; MBInfoPtr->btn_info[btn_index].key_sym[i++] = XK_N; break; case 'c': MBInfoPtr->btn_info[btn_index].key_sym[i++] = XK_c; MBInfoPtr->btn_info[btn_index].key_sym[i++] = XK_C; break; } if (BtnDesc & DEF_BUTTON) { MBInfoPtr->btn_info[btn_index].key_sym[i++] = XK_Return; MBInfoPtr->btn_info[btn_index].key_sym[i++] = XK_Linefeed; MBInfoPtr->btn_info[btn_index].highlight = TRUE; } else { MBInfoPtr->btn_info[btn_index].highlight = FALSE; } MBInfoPtr->btn_info[btn_index].key_sym[i] = (KeySym)0; } void CalcFormatStringInBox(buf, xfs, font_height, format_box_w, pn_num_lines, pn_max_w, pn_max_h, ppsz_formated_buf) char *buf, **ppsz_formated_buf; XFontStruct *xfs; int font_height, format_box_w, *pn_num_lines, *pn_max_w, *pn_max_h; { char *dest_ptr=NULL, *c_ptr=NULL, *msg_copy=NULL; int len=strlen(buf), max_len=0, max_w=0, max_h=0, total=0; int num_lines=1, spacing=SPACING, sz=((((len+10)<<1)+1)*sizeof(char)); total = BoldMsgTextWidth(xfs, buf, len); msg_copy = (char*)malloc(sz); if (msg_copy == NULL) FailAllocMessage(); memset(msg_copy, 0, sz); dest_ptr = msg_copy; *dest_ptr = '\0'; c_ptr = buf; while (c_ptr != NULL) { /* a line at a time */ char *lf_ptr=BoldMsgStrChr(c_ptr, '\n'); int full_str_len, full_str_total; if (lf_ptr != NULL) *lf_ptr = '\0'; full_str_len = strlen(c_ptr); full_str_total = BoldMsgTextWidth(xfs, c_ptr, full_str_len); if (full_str_total > max_w) { if (full_str_total > format_box_w) { /* line too long for the message box */ char *line=c_ptr; max_w = format_box_w; while (line != NULL && *line != '\0') { int line_len, line_total; while (*line == ' ') line++; line_len = strlen(line); line_total = BoldMsgTextWidth(xfs, line, line_len); if (line_total > format_box_w) { char *lead_ptr=line, *last_ptr=NULL, saved_last_ch='\0'; int lead_index=0, last_index=0, still_going=TRUE; while (still_going && *lead_ptr != '\0') { char saved_ch='\0'; int w=0; while (*lead_ptr != ' ' && *lead_ptr != '\0') { if (BoldMsgCharBytes(lead_ptr) == 2) { /* for double-byte chars, one can break anywhere */ break; } lead_ptr++; lead_index++; } saved_ch = (*lead_ptr); *lead_ptr = '\0'; w = BoldMsgTextWidth(xfs, line, lead_index); if (w > format_box_w) { if (last_ptr == NULL) { /* very long word */ sprintf(dest_ptr, "%s\n", line); dest_ptr = &dest_ptr[strlen(dest_ptr)]; max_h += font_height+spacing; num_lines++; line = &line[lead_index]; } else { /* find a good space */ saved_last_ch = (*last_ptr); *last_ptr = '\0'; sprintf(dest_ptr, "%s\n", line); *last_ptr = saved_last_ch; dest_ptr = &dest_ptr[strlen(dest_ptr)]; max_h += font_height+spacing; num_lines++; line = BoldMsgNextChar(&line[last_index]); } still_going = FALSE; } else { last_ptr = lead_ptr; last_index = lead_index; } *lead_ptr++ = saved_ch; lead_index++; } if (still_going && *lead_ptr == '\0') { if (last_ptr == NULL) { /* very long word */ sprintf(dest_ptr, "%s\n", line); dest_ptr = &dest_ptr[strlen(dest_ptr)]; max_h += font_height+spacing; num_lines++; line = &line[lead_index]; } else { /* find a good space */ saved_last_ch = (*last_ptr); *last_ptr = '\0'; sprintf(dest_ptr, "%s\n", line); *last_ptr = saved_last_ch; dest_ptr = &dest_ptr[strlen(dest_ptr)]; max_h += font_height+spacing; num_lines++; line = BoldMsgNextChar(&line[last_index]); } } } else if (line_len > 0) { sprintf(dest_ptr, "%s\n", line); dest_ptr = &dest_ptr[strlen(dest_ptr)]; max_h += font_height+spacing; break; } } } else { max_len = full_str_len; max_w = full_str_total; sprintf(dest_ptr, "%s\n", c_ptr); dest_ptr = &dest_ptr[strlen(dest_ptr)]; max_h += font_height+spacing; if (lf_ptr != NULL) num_lines++; } } else { sprintf(dest_ptr, "%s\n", c_ptr); dest_ptr = &dest_ptr[strlen(dest_ptr)]; max_h += font_height+spacing; if (lf_ptr != NULL) num_lines++; } max_h -= spacing; if (lf_ptr != NULL) { *lf_ptr = '\n'; c_ptr = &lf_ptr[1]; } else { break; } } if (pn_num_lines != NULL) *pn_num_lines = num_lines; if (pn_max_w != NULL) *pn_max_w = max_w; if (pn_max_h != NULL) *pn_max_h = max_h; if (ppsz_formated_buf == NULL) { free(msg_copy); } else { *ppsz_formated_buf = msg_copy; } } static void CalcSimpleGeometry(MBInfoPtr, Message) struct MBRec *MBInfoPtr; char *Message; { int i=0, max_h=0, left=0, inc=0, a_btn_w=0, a_btn_h=0, y=0, max_w=0;; CalcFormatStringInBox(Message, defaultFontPtr, defaultFontHeight, MBInfoPtr->max_msg_str_total, NULL, &max_w, &max_h, &MBInfoPtr->msg_copy); if (MBInfoPtr->is_dialog) { MBInfoPtr->msg_win_w = MBInfoPtr->max_msg_str_total; } else { MBInfoPtr->msg_win_w = max_w; } MBInfoPtr->msg_win_h = max_h; MBInfoPtr->icon_win_w = ICON_W; MBInfoPtr->icon_win_h = ICON_H; if (info_bits == NULL) { } if (MBInfoPtr->msg_win_h > MBInfoPtr->icon_win_h) { MBInfoPtr->icon_win_h = MBInfoPtr->msg_win_h; } else { MBInfoPtr->msg_win_h = MBInfoPtr->icon_win_h; } a_btn_w = MAX_BTN_STR_LEN*defaultFontWidth + (BTN_XY_EXTRA<<1); if (MBInfoPtr->is_dialog) { if (msgFontSet == NULL && msgFontPtr == NULL) { a_btn_h = defaultFontHeight + (BTN_Y_MARGIN<<1) + (BTN_XY_EXTRA<<1); } else { a_btn_h = msgFontHeight + (BTN_Y_MARGIN<<1) + (BTN_XY_EXTRA<<1); } } else { if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { a_btn_h = defaultFontHeight + (BTN_Y_MARGIN<<1) + (BTN_XY_EXTRA<<1); } else { a_btn_h = boldMsgFontHeight + (BTN_Y_MARGIN<<1) + (BTN_XY_EXTRA<<1); } } MBInfoPtr->btn_win_w = numButtons*a_btn_w+BTN_MIN_X_GAP*(numButtons-1)+2; MBInfoPtr->btn_win_h = a_btn_h+2+(windowPadding<<2); if (MBInfoPtr->btn_win_w > MBInfoPtr->msg_win_w+MBInfoPtr->icon_win_w+X_GAP) { MBInfoPtr->msg_win_w = MBInfoPtr->btn_win_w-MBInfoPtr->icon_win_w-X_GAP; } else { MBInfoPtr->btn_win_w = MBInfoPtr->msg_win_w+MBInfoPtr->icon_win_w+X_GAP; } MBInfoPtr->main_win_w = MBInfoPtr->btn_win_w + (X_MARGIN<<1) + (brdrW<<1); MBInfoPtr->main_win_h = MBInfoPtr->icon_win_h + MBInfoPtr->btn_win_h + (Y_MARGIN<<1) + Y_GAP + (brdrW<<1); left = ((MBInfoPtr->btn_win_w - numButtons*a_btn_w - BTN_MIN_X_GAP*(numButtons-1))>>1); inc = a_btn_w + ((MBInfoPtr->btn_win_w-(left<<1)-numButtons*a_btn_w) / (numButtons-1)); y = ((MBInfoPtr->btn_win_h - ((BTN_Y_MARGIN<<1) + ((boldMsgFontSet==NULL && boldMsgFontPtr==NULL) ? defaultFontHeight : boldMsgFontHeight))) >> 1); for (i=0; i < numButtons; i++) { MBInfoPtr->btn_info[i].bbox.ltx = left+BTN_XY_EXTRA; MBInfoPtr->btn_info[i].bbox.lty = y; MBInfoPtr->btn_info[i].bbox.rbx = left + MAX_BTN_STR_LEN*defaultFontWidth + BTN_XY_EXTRA; MBInfoPtr->btn_info[i].bbox.rby = y + (BTN_Y_MARGIN<<1) + ((boldMsgFontSet==NULL && boldMsgFontPtr==NULL) ? defaultFontHeight : boldMsgFontHeight); left += inc; } MBInfoPtr->main_win_x = ((DisplayWidth(mainDisplay, mainScreen) - MBInfoPtr->main_win_w)>>1); MBInfoPtr->main_win_y = ((DisplayHeight(mainDisplay, mainScreen) - MBInfoPtr->main_win_h)/3); if (MBInfoPtr->main_win_x < 0) MBInfoPtr->main_win_x = 0; if (MBInfoPtr->main_win_y < 0) MBInfoPtr->main_win_y = 0; } static void CalcGeometry(MBInfoPtr, Message) struct MBRec *MBInfoPtr; char *Message; { int i=0, max_h=0, left=0, inc=0, a_btn_w=0, a_btn_h=0; int font_height=boldMsgFontHeight, y=0, max_w=0; CalcFormatStringInBox(Message, boldMsgFontPtr, boldMsgFontHeight, MBInfoPtr->max_msg_str_total, NULL, &max_w, &max_h, &MBInfoPtr->msg_copy); if (MBInfoPtr->is_dialog) { MBInfoPtr->msg_win_w = MBInfoPtr->max_msg_str_total; } else { MBInfoPtr->msg_win_w = max_w; } MBInfoPtr->msg_win_h = max_h; MBInfoPtr->icon_win_w = ICON_W; MBInfoPtr->icon_win_h = ICON_H; if (MBInfoPtr->msg_win_h > MBInfoPtr->icon_win_h) { MBInfoPtr->icon_win_h = MBInfoPtr->msg_win_h; } else { MBInfoPtr->msg_win_h = MBInfoPtr->icon_win_h; } /* do not translate -- the string is used to measure things */ a_btn_w = BoldMsgTextWidth(boldMsgFontPtr, " CANCEL ", 10) + (BTN_XY_EXTRA<<1); if (MBInfoPtr->is_dialog) { a_btn_h = (BTN_Y_MARGIN<<1) + (BTN_XY_EXTRA<<1) + ((msgFontSet==NULL && msgFontPtr==NULL) ? defaultFontHeight : msgFontHeight); } else { a_btn_h = (BTN_Y_MARGIN<<1) + (BTN_XY_EXTRA<<1) + ((boldMsgFontSet==NULL && boldMsgFontPtr==NULL) ? defaultFontHeight : boldMsgFontHeight); } MBInfoPtr->btn_win_w = numButtons*a_btn_w+BTN_MIN_X_GAP*(numButtons-1)+2; MBInfoPtr->btn_win_h = a_btn_h+2+(windowPadding<<1); if (MBInfoPtr->btn_win_w > MBInfoPtr->msg_win_w+MBInfoPtr->icon_win_w+X_GAP) { MBInfoPtr->msg_win_w = MBInfoPtr->btn_win_w-MBInfoPtr->icon_win_w-X_GAP; } else { MBInfoPtr->btn_win_w = MBInfoPtr->msg_win_w+MBInfoPtr->icon_win_w+X_GAP; } MBInfoPtr->main_win_w = MBInfoPtr->btn_win_w + (X_MARGIN<<1) + (brdrW<<1); MBInfoPtr->main_win_h = MBInfoPtr->icon_win_h + MBInfoPtr->btn_win_h + (Y_MARGIN<<1) + Y_GAP + (brdrW<<1); left = ((MBInfoPtr->btn_win_w - numButtons*a_btn_w - BTN_MIN_X_GAP*(numButtons-1))>>1); inc = a_btn_w + ((MBInfoPtr->btn_win_w-(left<<1)-numButtons*a_btn_w) / (numButtons-1)); y = ((MBInfoPtr->btn_win_h - ((BTN_Y_MARGIN<<1) + font_height)) >> 1); for (i=0; i < numButtons; i++) { MBInfoPtr->btn_info[i].bbox.ltx = left+BTN_XY_EXTRA; MBInfoPtr->btn_info[i].bbox.lty = y; MBInfoPtr->btn_info[i].bbox.rbx = left + (a_btn_w-(BTN_XY_EXTRA<<1)) + BTN_XY_EXTRA; MBInfoPtr->btn_info[i].bbox.rby = y + font_height + (BTN_Y_MARGIN<<1); left += inc; } MBInfoPtr->main_win_x = ((DisplayWidth(mainDisplay, mainScreen) - MBInfoPtr->main_win_w)>>1); MBInfoPtr->main_win_y = ((DisplayHeight(mainDisplay, mainScreen) - MBInfoPtr->main_win_h)/3); if (MBInfoPtr->main_win_x < 0) MBInfoPtr->main_win_x = 0; if (MBInfoPtr->main_win_y < 0) MBInfoPtr->main_win_y = 0; } static int SetupMBWindow(MBInfoPtr, Message, Title, IconAndBtns, IsDialog) struct MBRec *MBInfoPtr; char *Message, *Title; int IconAndBtns, IsDialog; { int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); XWMHints wmhints; XSizeHints sizehints; XSetWindowAttributes win_attrs; memset(MBInfoPtr, 0, sizeof(struct MBRec)); MBInfoPtr->is_dialog = IsDialog; MBInfoPtr->msg_copy = NULL; MBInfoPtr->max_msg_win_w = (DisplayWidth(mainDisplay,mainScreen)>>1); MBInfoPtr->max_msg_str_len = MBInfoPtr->max_msg_win_w / defaultFontWidth; MBInfoPtr->max_msg_str_total = MBInfoPtr->max_msg_win_w; numButtons = MAX_BUTTONS; if (IconAndBtns & MB_BTN_EXTRA) numButtons++; if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { CalcSimpleGeometry(MBInfoPtr, Message); } else { CalcGeometry(MBInfoPtr, Message); } switch (IconAndBtns & MB_BTNMASK) { case MB_BTN_NONE: break; case MB_BTN_OK: SetupMBButton(MBInfoPtr, LF_BUTTON, '\0', MB_ID_FAILED); SetupMBButton(MBInfoPtr, MD_BUTTON | DEF_BUTTON, 'o', MB_ID_OK); SetupMBButton(MBInfoPtr, RT_BUTTON, '\0', MB_ID_FAILED); break; case MB_BTN_YESNOCANCEL: SetupMBButton(MBInfoPtr, LF_BUTTON | DEF_BUTTON, 'y', MB_ID_YES); SetupMBButton(MBInfoPtr, MD_BUTTON, 'n', MB_ID_NO); SetupMBButton(MBInfoPtr, RT_BUTTON, 'c', MB_ID_CANCEL); break; case MB_BTN_OKCANCEL: SetupMBButton(MBInfoPtr, LF_BUTTON | DEF_BUTTON, 'o', MB_ID_OK); SetupMBButton(MBInfoPtr, MD_BUTTON, '\0', MB_ID_FAILED); SetupMBButton(MBInfoPtr, RT_BUTTON, 'c', MB_ID_CANCEL); break; case MB_BTN_YESNO: SetupMBButton(MBInfoPtr, LF_BUTTON | DEF_BUTTON, 'y', MB_ID_YES); SetupMBButton(MBInfoPtr, MD_BUTTON, '\0', MB_ID_FAILED); SetupMBButton(MBInfoPtr, RT_BUTTON, 'n', MB_ID_NO); break; default: SetupMBButton(MBInfoPtr, LF_BUTTON, '\0', MB_ID_FAILED); SetupMBButton(MBInfoPtr, MD_BUTTON, '\0', MB_ID_FAILED); SetupMBButton(MBInfoPtr, RT_BUTTON, '\0', MB_ID_FAILED); break; } if (IconAndBtns & MB_BTN_EXTRA) { if ((IconAndBtns & MB_BTNMASK) != 0) { SetupMBButton(MBInfoPtr, XT_BUTTON, extraBtnChar, MB_ID_EXTRA); } else { SetupMBButton(MBInfoPtr, XT_BUTTON | DEF_BUTTON, extraBtnChar, MB_ID_EXTRA); } } else { SetupMBButton(MBInfoPtr, XT_BUTTON, '\0', MB_ID_FAILED); } switch (IconAndBtns & MB_ICONMASK) { case MB_ICON_STOP: MBInfoPtr->cur_bitmap = msgBoxPixmap[MB_PIXMAP_STOP]; break; case MB_ICON_QUESTION: MBInfoPtr->cur_bitmap = msgBoxPixmap[MB_PIXMAP_QUESTION]; break; case MB_ICON_INFORMATION: MBInfoPtr->cur_bitmap = msgBoxPixmap[MB_PIXMAP_INFORMATION]; break; case MB_ICON_DIALOG: MBInfoPtr->cur_bitmap = msgBoxPixmap[MB_PIXMAP_DIALOG]; break; default: MBInfoPtr->cur_bitmap = None; break; } if ((MBInfoPtr->main_win=XCreateSimpleWindow(mainDisplay, rootWindow, MBInfoPtr->main_win_x, MBInfoPtr->main_win_y, MBInfoPtr->main_win_w, MBInfoPtr->main_win_h, brdrW, myBorderPixel, bg_pixel)) == 0) { fprintf(stderr, "%s\n", TgLoadString(STID_FAIL_TO_CREATE_WINDOW)); return FALSE; } if ((MBInfoPtr->icon_win=XCreateSimpleWindow(mainDisplay, MBInfoPtr->main_win, X_MARGIN, Y_MARGIN, MBInfoPtr->icon_win_w, MBInfoPtr->icon_win_h, 0, myBorderPixel, bg_pixel)) == 0) { fprintf(stderr, "%s\n", TgLoadString(STID_FAIL_TO_CREATE_WINDOW)); return FALSE; } if ((MBInfoPtr->msg_win=XCreateSimpleWindow(mainDisplay, MBInfoPtr->main_win, X_MARGIN+MBInfoPtr->icon_win_w+X_GAP, Y_MARGIN, MBInfoPtr->msg_win_w, MBInfoPtr->msg_win_h, 0, myBorderPixel, bg_pixel)) == 0) { fprintf(stderr, "%s\n", TgLoadString(STID_FAIL_TO_CREATE_WINDOW)); return FALSE; } if ((MBInfoPtr->btn_win=XCreateSimpleWindow(mainDisplay, MBInfoPtr->main_win, X_MARGIN, Y_MARGIN+Y_GAP+MBInfoPtr->icon_win_h, MBInfoPtr->btn_win_w, MBInfoPtr->btn_win_h, 0, myBorderPixel, bg_pixel)) == 0) { fprintf(stderr, "%s\n", TgLoadString(STID_FAIL_TO_CREATE_WINDOW)); return FALSE; } win_attrs.save_under = True; win_attrs.colormap = mainColormap; XChangeWindowAttributes(mainDisplay, MBInfoPtr->main_win, CWSaveUnder | CWColormap, &win_attrs); wmhints.flags = InputHint | StateHint; wmhints.input = True; wmhints.initial_state = NormalState; XSetWMHints(mainDisplay, MBInfoPtr->main_win, &wmhints); wmhints.flags = InputHint; XSetWMHints(mainDisplay, MBInfoPtr->icon_win, &wmhints); XSetWMHints(mainDisplay, MBInfoPtr->msg_win, &wmhints); XSetWMHints(mainDisplay, MBInfoPtr->btn_win, &wmhints); sizehints.flags = PPosition | PSize | USPosition | PMinSize | PMaxSize; sizehints.x = MBInfoPtr->main_win_x; sizehints.y = MBInfoPtr->main_win_y; sizehints.width = sizehints.max_width = sizehints.min_width = MBInfoPtr->main_win_w; sizehints.height = sizehints.max_height = sizehints.min_height = MBInfoPtr->main_win_h; #ifdef NOTR4MODE XSetNormalHints(mainDisplay, MBInfoPtr->main_win, &sizehints); #else XSetWMNormalHints(mainDisplay, MBInfoPtr->main_win, &sizehints); #endif /* NOTR4MODE */ RegisterWM_DELETE_WINDOW(MBInfoPtr->main_win); XStoreName(mainDisplay, MBInfoPtr->main_win, Title); /* so that MessageBox() and Dialog() window stays on top of tgif's window */ XSetTransientForHint(mainDisplay, MBInfoPtr->main_win, mainWindow); #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, MBInfoPtr->main_win); XMapWindow(mainDisplay, MBInfoPtr->icon_win); XMapWindow(mainDisplay, MBInfoPtr->msg_win); XMapWindow(mainDisplay, MBInfoPtr->btn_win); XSelectInput(mainDisplay, MBInfoPtr->main_win, ButtonPressMask | KeyPressMask | StructureNotifyMask | VisibilityChangeMask); XSelectInput(mainDisplay, MBInfoPtr->icon_win, ButtonPressMask | KeyPressMask | ExposureMask); XSelectInput(mainDisplay, MBInfoPtr->msg_win, ButtonPressMask | KeyPressMask | ExposureMask); XSelectInput(mainDisplay, MBInfoPtr->btn_win, ButtonReleaseMask | ButtonPressMask | PointerMotionMask | KeyPressMask | ExposureMask); #else /* !MAPBEFORESELECT */ XSelectInput(mainDisplay, MBInfoPtr->main_win, ButtonPressMask | KeyPressMask | StructureNotifyMask | VisibilityChangeMask); XSelectInput(mainDisplay, MBInfoPtr->icon_win, ButtonPressMask | KeyPressMask | ExposureMask); XSelectInput(mainDisplay, MBInfoPtr->msg_win, ButtonPressMask | KeyPressMask | ExposureMask); XSelectInput(mainDisplay, MBInfoPtr->btn_win, ButtonReleaseMask | ButtonPressMask | PointerMotionMask | KeyPressMask | ExposureMask); XMapWindow(mainDisplay, MBInfoPtr->main_win); XMapWindow(mainDisplay, MBInfoPtr->icon_win); XMapWindow(mainDisplay, MBInfoPtr->msg_win); XMapWindow(mainDisplay, MBInfoPtr->btn_win); #endif /* !MAPBEFORESELECT */ if (warpToWinCenter) { XWarpPointer(mainDisplay, None, MBInfoPtr->main_win, 0, 0, 0, 0, (MBInfoPtr->main_win_w>>1), (MBInfoPtr->main_win_h>>1)); } XSync(mainDisplay, False); return TRUE; } static void DisplayInput(MBInfoPtr) struct MBRec *MBInfoPtr; { Window win=MBInfoPtr->btn_win; char *buf=MBInfoPtr->return_str, *dup_buf=NULL, *msg=NULL; int buf_len; MBInfoPtr->str_w = 0; MBInfoPtr->cur_x = (MBInfoPtr->btn_win_w>>1); if (buf == NULL) return; buf_len = strlen(buf); if (msgFontSet == NULL && msgFontPtr == NULL) { MBInfoPtr->str_w = defaultFontWidth*strlen(buf); } else { MBInfoPtr->str_w = MsgTextWidth(msgFontPtr, buf, buf_len); } MBInfoPtr->cur_x = ((MBInfoPtr->btn_win_w-MBInfoPtr->str_w)>>1); MBInfoPtr->cursor_x = MBInfoPtr->cur_x+MBInfoPtr->str_w+1; if (doPassword) { int i; dup_buf = (char*)malloc((buf_len+1)*sizeof(char)); if (dup_buf == NULL) FailAllocMessage(); for (i=0; i < buf_len; i++) dup_buf[i] = '*'; msg = dup_buf; } else { msg = buf; } if (msgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, msgFontPtr->fid); } DrawMsgString(mainDisplay, win, defaultGC, MBInfoPtr->cur_x, MBInfoPtr->cur_y, msg, buf_len); if (msgFontSet != NULL || msgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, defaultFontPtr->fid); } if (dup_buf != NULL) free(dup_buf); } static int HandleMsgBoxKeyEvent(MBInfoPtr, input) struct MBRec *MBInfoPtr; XEvent *input; { XKeyEvent *key_ev=(&(input->xkey)); KeySym key_sym; char buf[80]; int i, j, has_ch; int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); has_ch = XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); TranslateKeys(buf, &key_sym); if (MBInfoPtr->is_dialog) { /* for Dialog(), return INVALID for <ESC> */ /* return FALSE for a normal character, including <BS> */ /* return TRUE for <CR> or <LF> */ if (MBInfoPtr->exposed) { /* erase the old cursor */ PutCursor(MBInfoPtr->btn_win, MBInfoPtr->cursor_x, MBInfoPtr->cursor_y, bg_pixel); } if (CharIsESC(key_ev, buf, key_sym, &has_ch)) { if (MBInfoPtr->return_str != NULL) *MBInfoPtr->return_str = '\0'; return INVALID; } else if (CharIsCRorLF(key_ev, buf, key_sym, &has_ch)) { if (MBInfoPtr->return_str == NULL) { return INVALID; } return TRUE; } else if (CharIsBSorDEL(key_ev, buf, key_sym, &has_ch, FALSE)) { if (MBInfoPtr->return_str == NULL) { return INVALID; } if (MBInfoPtr->index > 0) { if (MBInfoPtr->exposed) { XClearWindow(mainDisplay, MBInfoPtr->btn_win); } MBInfoPtr->return_str[--MBInfoPtr->index] = '\0'; DisplayInput(MBInfoPtr); } } else if ((key_ev->state & ControlMask)==0 && key_sym>='\040' && key_sym<='\177') { if (MBInfoPtr->return_str == NULL) { return INVALID; } if (buf[0] >= '\040' && MBInfoPtr->index < 80) { if (MBInfoPtr->exposed) { XClearWindow(mainDisplay, MBInfoPtr->btn_win); } MBInfoPtr->return_str[MBInfoPtr->index++] = buf[0]; MBInfoPtr->return_str[MBInfoPtr->index] = '\0'; DisplayInput(MBInfoPtr); } } if (MBInfoPtr->exposed) { PutCursor(MBInfoPtr->btn_win, MBInfoPtr->cursor_x, MBInfoPtr->cursor_y, myFgPixel); } return FALSE; } else { /* for MsgBox(), return a button id */ if (CharIsESC(key_ev, buf, key_sym, &has_ch)) { return (MB_ID_CANCEL); } for (i=0; i < numButtons; i++) { if (MBInfoPtr->btn_info[i].str != NULL) { for (j=0; MBInfoPtr->btn_info[i].key_sym[j] != (KeySym)0; j++) { if (MBInfoPtr->btn_info[i].key_sym[j] == key_sym) { DisplayButtonInBBox(MBInfoPtr->btn_win, MBInfoPtr->btn_info[i].str, strlen(MBInfoPtr->btn_info[i].str), &MBInfoPtr->btn_info[i].bbox, BUTTON_INVERT, MBInfoPtr->btn_info[i].highlight, BTN_XY_EXTRA, NULL); XSync(mainDisplay, False); return MBInfoPtr->btn_info[i].id; } } } } } return INVALID; } static int HandleDeleteMsgBox(MBInfoPtr) struct MBRec *MBInfoPtr; { int bg_pixel=(threeDLook ? myLtGryPixel : myBgPixel); if (MBInfoPtr->is_dialog) { /* for Dialog(), same as <ESC> is pressed */ if (MBInfoPtr->exposed) { /* erase the old cursor */ PutCursor(MBInfoPtr->btn_win, MBInfoPtr->cursor_x, MBInfoPtr->cursor_y, bg_pixel); } if (MBInfoPtr->return_str != NULL) *MBInfoPtr->return_str = '\0'; return INVALID; } /* for MsgBox(), return a button id */ return MB_ID_CANCEL; } static void HandlePasteInDialog(MBInfoPtr, input) struct MBRec *MBInfoPtr; XEvent *input; { XButtonEvent *button_ev=(&(input->xbutton)); int buf_len=0, from_selection=FALSE; char *cut_buffer=NULL; if (button_ev->button != Button2) return; cut_buffer = FetchSelectionOrCutBuffer(&buf_len, &from_selection); if (cut_buffer == NULL) return; if ((unsigned char)(*cut_buffer) != TGIF_HEADER && MBInfoPtr->return_str != NULL) { unsigned char *c_ptr=(unsigned char *)cut_buffer; if (MBInfoPtr->exposed) { XClearWindow(mainDisplay, MBInfoPtr->btn_win); } for ( ; buf_len > 0 && MBInfoPtr->index < 80 && *c_ptr != '\0'; c_ptr++, buf_len--) { if (*c_ptr >= (unsigned char)('\040') && *c_ptr < (unsigned char)('\377')) { MBInfoPtr->return_str[MBInfoPtr->index++] = (char)(*c_ptr); } else { break; } } MBInfoPtr->return_str[MBInfoPtr->index] = '\0'; if (MBInfoPtr->exposed) { DisplayInput(MBInfoPtr); PutCursor(MBInfoPtr->btn_win, MBInfoPtr->cursor_x, MBInfoPtr->cursor_y, myFgPixel); } } FreeSelectionOrCutBuffer(cut_buffer, from_selection); } static int HandleMsgBoxBtnEvent(MBInfoPtr, input) struct MBRec *MBInfoPtr; XEvent *input; { XButtonEvent *button_ev=(&(input->xbutton)); int i, x=button_ev->x, y=button_ev->y; for (i=0; i < numButtons; i++) { if (MBInfoPtr->btn_info[i].str != NULL) { if (x >= MBInfoPtr->btn_info[i].bbox.ltx && x < MBInfoPtr->btn_info[i].bbox.rbx && y >= MBInfoPtr->btn_info[i].bbox.lty && y < MBInfoPtr->btn_info[i].bbox.rby) { int inside=TRUE; DisplayButtonInBBox(MBInfoPtr->btn_win, MBInfoPtr->btn_info[i].str, strlen(MBInfoPtr->btn_info[i].str), &MBInfoPtr->btn_info[i].bbox, BUTTON_INVERT, MBInfoPtr->btn_info[i].highlight, BTN_XY_EXTRA, NULL); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, MBInfoPtr->btn_win, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, defaultCursor, CurrentTime); } while (TRUE) { XEvent ev; XNextEvent(mainDisplay, &ev); if (ev.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); button_ev = &(ev.xbutton); x = button_ev->x; y = button_ev->y; if (x >= MBInfoPtr->btn_info[i].bbox.ltx && x < MBInfoPtr->btn_info[i].bbox.rbx && y >= MBInfoPtr->btn_info[i].bbox.lty && y < MBInfoPtr->btn_info[i].bbox.rby) { DisplayButtonInBBox(MBInfoPtr->btn_win, MBInfoPtr->btn_info[i].str, strlen(MBInfoPtr->btn_info[i].str), &MBInfoPtr->btn_info[i].bbox, BUTTON_NORMAL, MBInfoPtr->btn_info[i].highlight, BTN_XY_EXTRA, NULL); return MBInfoPtr->btn_info[i].id; } break; } else if (ev.type == MotionNotify) { XEvent tmp_ev; XMotionEvent *motion_ev=(&(ev.xmotion)); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &tmp_ev)) ; x = motion_ev->x; y = motion_ev->y; if (inside) { if (!(x >= MBInfoPtr->btn_info[i].bbox.ltx && x < MBInfoPtr->btn_info[i].bbox.rbx && y >= MBInfoPtr->btn_info[i].bbox.lty && y < MBInfoPtr->btn_info[i].bbox.rby)) { DisplayButtonInBBox(MBInfoPtr->btn_win, MBInfoPtr->btn_info[i].str, strlen(MBInfoPtr->btn_info[i].str), &MBInfoPtr->btn_info[i].bbox, BUTTON_NORMAL, MBInfoPtr->btn_info[i].highlight, BTN_XY_EXTRA, NULL); inside = FALSE; } } else { if (x >= MBInfoPtr->btn_info[i].bbox.ltx && x < MBInfoPtr->btn_info[i].bbox.rbx && y >= MBInfoPtr->btn_info[i].bbox.lty && y < MBInfoPtr->btn_info[i].bbox.rby) { DisplayButtonInBBox(MBInfoPtr->btn_win, MBInfoPtr->btn_info[i].str, strlen(MBInfoPtr->btn_info[i].str), &MBInfoPtr->btn_info[i].bbox, BUTTON_INVERT, MBInfoPtr->btn_info[i].highlight, BTN_XY_EXTRA, NULL); inside = TRUE; } } } } return INVALID; } } } return INVALID; } static void RefreshMsgBox(MBInfoPtr) struct MBRec *MBInfoPtr; { int i; XEvent ev; if (MBInfoPtr->msg_copy != NULL && *MBInfoPtr->msg_copy != '\0') { int y=0; char *c_ptr=MBInfoPtr->msg_copy; if (boldMsgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, boldMsgFontPtr->fid); } while (c_ptr != NULL) { char *c_ptr1=BoldMsgStrChr(c_ptr, '\n'); int len, w; if (c_ptr1 != NULL) *c_ptr1 = '\0'; len = strlen(c_ptr); if (boldMsgFontSet == NULL && boldMsgFontPtr == NULL) { if (MBInfoPtr->is_dialog) { w = len * defaultFontWidth; DrawBoldMsgString(mainDisplay, MBInfoPtr->msg_win, defaultGC, (MBInfoPtr->msg_win_w-w)>>1, y+defaultFontAsc, c_ptr, len); } else { DrawBoldMsgString(mainDisplay, MBInfoPtr->msg_win, defaultGC, 0, y+defaultFontAsc, c_ptr, len); } y += defaultFontHeight+SPACING; } else { if (MBInfoPtr->is_dialog) { w = BoldMsgTextWidth(boldMsgFontPtr, c_ptr, len); DrawBoldMsgString(mainDisplay, MBInfoPtr->msg_win, defaultGC, (MBInfoPtr->msg_win_w-w)>>1, y+boldMsgFontAsc, c_ptr, len); } else { DrawBoldMsgString(mainDisplay, MBInfoPtr->msg_win, defaultGC, 0, y+boldMsgFontAsc, c_ptr, len); } y += boldMsgFontHeight+SPACING; } if (c_ptr1 != NULL) { *c_ptr1 = '\n'; c_ptr = &c_ptr1[1]; } else { break; } } if (boldMsgFontSet != NULL || boldMsgFontPtr != NULL) { XSetFont(mainDisplay, defaultGC, defaultFontPtr->fid); } } if (MBInfoPtr->is_dialog) { DisplayInput(MBInfoPtr); PutCursor(MBInfoPtr->btn_win, MBInfoPtr->cursor_x, MBInfoPtr->cursor_y, myFgPixel); } else { for (i=0; i < numButtons; i++) { if (MBInfoPtr->btn_info[i].str != NULL) { DisplayButtonInBBox(MBInfoPtr->btn_win, MBInfoPtr->btn_info[i].str, strlen(MBInfoPtr->btn_info[i].str), &MBInfoPtr->btn_info[i].bbox, BUTTON_NORMAL, MBInfoPtr->btn_info[i].highlight, BTN_XY_EXTRA, NULL); } } } if (MBInfoPtr->cur_bitmap != None) { int y=((MBInfoPtr->icon_win_h-ICON_H)>>1); XSetTSOrigin(mainDisplay, defaultGC, 0, y); XSetFillStyle(mainDisplay, defaultGC, FillOpaqueStippled); XSetStipple(mainDisplay, defaultGC, MBInfoPtr->cur_bitmap); XFillRectangle(mainDisplay, MBInfoPtr->icon_win, defaultGC, 0, y, ICON_W, ICON_H); XSetFillStyle(mainDisplay, defaultGC, FillSolid); XSetTSOrigin(mainDisplay, defaultGC, 0, 0); } while (XCheckWindowEvent(mainDisplay,MBInfoPtr->main_win,ExposureMask,&ev)) ; while (XCheckWindowEvent(mainDisplay,MBInfoPtr->icon_win,ExposureMask,&ev)) ; while (XCheckWindowEvent(mainDisplay,MBInfoPtr->msg_win,ExposureMask,&ev)) ; while (XCheckWindowEvent(mainDisplay,MBInfoPtr->btn_win,ExposureMask,&ev)) ; if (threeDLook && dialogboxUse3DBorder) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, MBInfoPtr->main_win_w, MBInfoPtr->main_win_h); TgDrawThreeDButton(mainDisplay, MBInfoPtr->main_win, textMenuGC, &bbox, TGBS_RAISED, 2, FALSE); } } int MsgBox(Message, Title, IconAndBtns) char *Message, *Title; int IconAndBtns; { static int stShowing=FALSE; char *dup_msg=NULL; int rc=MB_ID_FAILED, looping=TRUE; if (PRTGIF) { fprintf(stderr, "%s\n", Message); return rc; } dup_msg = UtilStrDup(Message); if (dup_msg == NULL) { FailAllocMessage(); return rc; } if (stShowing) return rc; stShowing = TRUE; if (!SetupMBWindow(&mbInfo, dup_msg, Title, IconAndBtns, FALSE)) { char msg[MAXSTRING]; sprintf(msg, TgLoadString(STID_INVALID_PARAM_PASSED_TO_FUNC), "MsgBox()"); fprintf(stderr, "%s\n", msg); Msg(msg); if (mbInfo.msg_copy != NULL) { free(mbInfo.msg_copy); mbInfo.msg_copy = NULL; } free(dup_msg); stShowing = FALSE; return rc; } EndMeasureTooltip(FALSE); while (looping) { XEvent input, ev; XNextEvent(mainDisplay, &input); if ((input.type==MapNotify && input.xany.window==mbInfo.main_win) || (input.type==Expose && (input.xany.window==mbInfo.main_win || input.xany.window==mbInfo.icon_win || input.xany.window==mbInfo.msg_win || input.xany.window==mbInfo.btn_win)) || (!mbInfo.exposed && (XCheckWindowEvent(mainDisplay,mbInfo.main_win,ExposureMask,&ev) || XCheckWindowEvent(mainDisplay,mbInfo.main_win,StructureNotifyMask, &ev)))) { RefreshMsgBox(&mbInfo); mbInfo.exposed = TRUE; XSync(mainDisplay, False); if (input.xany.window==mbInfo.main_win || input.xany.window==mbInfo.icon_win || input.xany.window==mbInfo.msg_win || input.xany.window==mbInfo.btn_win) { continue; } } if (input.type == Expose) { ExposeEventHandler(&input, FALSE); } else if (input.type == ConfigureNotify && input.xany.window == mainWindow) { Reconfigure(FALSE); } else if (input.type == VisibilityNotify && input.xany.window==mainWindow && input.xvisibility.state==VisibilityUnobscured) { int i; while (XCheckWindowEvent(mainDisplay, mainWindow, VisibilityChangeMask, &ev)) ; if (pinnedMainMenu) XMapRaised(mainDisplay, mainMenuWindow); for (i = 0; i < numExtraWins; i++) { if (extraWinInfo[i].mapped && extraWinInfo[i].raise && extraWinInfo[i].window != None) { XMapRaised(mainDisplay, extraWinInfo[i].window); } } XMapRaised(mainDisplay, mbInfo.main_win); } else if (input.type == KeyPress) { if ((rc=HandleMsgBoxKeyEvent(&mbInfo, &input)) != INVALID) { break; } } else if (input.type==ButtonPress && input.xany.window==mbInfo.btn_win) { if ((rc=HandleMsgBoxBtnEvent(&mbInfo, &input)) != INVALID) { break; } } else if (IsWM_DELETE_WINDOW(&input)) { rc = HandleDeleteMsgBox(&mbInfo); break; } } if (mbInfo.msg_copy != NULL) { free(mbInfo.msg_copy); mbInfo.msg_copy = NULL; } free(dup_msg); XDestroyWindow(mainDisplay, mbInfo.main_win); if (warpToWinCenter) { XWarpPointer(mainDisplay, None, drawWindow, 0, 0, 0, 0, (int)(ZOOMED_SIZE(drawWinW)>>1), (int)(ZOOMED_SIZE(drawWinH)>>1)); } stShowing = FALSE; return rc; } static int DoDialog(Message, ReturnStr) char *Message, *ReturnStr; { char *dup_msg=UtilStrDup(Message), szTitle[80]; int rc=FALSE, looping=TRUE; if (dup_msg == NULL) { FailAllocMessage(); return INVALID; } sprintf(szTitle, TgLoadString(STID_TOOL_INPUT), TOOL_NAME); if (!SetupMBWindow(&mbInfo, dup_msg, szTitle, MB_ICON_DIALOG, TRUE)) { char msg[MAXSTRING]; sprintf(msg, TgLoadString(STID_INVALID_PARAM_PASSED_TO_FUNC), "MsgBox()"); fprintf(stderr, "%s\n", msg); Msg(msg); if (mbInfo.msg_copy != NULL) { free(mbInfo.msg_copy); mbInfo.msg_copy = NULL; } free(dup_msg); return INVALID; } if (ReturnStr != NULL) { /* Use as is. */ /* *ReturnStr = '\0'; */ } mbInfo.cur_x = ((mbInfo.btn_win_w)>>1); mbInfo.cursor_x = mbInfo.cur_x + 1; if (msgFontSet == NULL && msgFontPtr == NULL) { mbInfo.cur_y = ((mbInfo.btn_win_h-defaultFontHeight)>>1)+defaultFontAsc; mbInfo.cursor_y = mbInfo.cur_y - defaultFontAsc + ((defaultFontAsc-16)>>1); } else { mbInfo.cur_y = ((mbInfo.btn_win_h-msgFontHeight)>>1)+msgFontAsc; mbInfo.cursor_y = mbInfo.cur_y - msgFontAsc + ((msgFontAsc-16)>>1); } mbInfo.index = 0; if (ReturnStr != NULL) { mbInfo.index = strlen(ReturnStr); } mbInfo.return_str = ReturnStr; while (looping) { XEvent input, ev; XNextEvent(mainDisplay, &input); if ((input.type==MapNotify && input.xany.window==mbInfo.main_win) || (input.type==Expose && (input.xany.window==mbInfo.main_win || input.xany.window==mbInfo.icon_win || input.xany.window==mbInfo.msg_win || input.xany.window==mbInfo.btn_win)) || (!mbInfo.exposed && (XCheckWindowEvent(mainDisplay,mbInfo.main_win,ExposureMask,&ev) || XCheckWindowEvent(mainDisplay,mbInfo.main_win,StructureNotifyMask, &ev)))) { RefreshMsgBox(&mbInfo); mbInfo.exposed = TRUE; XSync(mainDisplay, False); if (input.xany.window==mbInfo.main_win || input.xany.window==mbInfo.icon_win || input.xany.window==mbInfo.msg_win || input.xany.window==mbInfo.btn_win) { continue; } } if (input.type == Expose) { ExposeEventHandler(&input, FALSE); } else if (input.type == ConfigureNotify && input.xany.window == mainWindow) { Reconfigure(FALSE); } else if (input.type == VisibilityNotify && input.xany.window==mainWindow && input.xvisibility.state==VisibilityUnobscured) { int i; while (XCheckWindowEvent(mainDisplay, mainWindow, VisibilityChangeMask, &ev)) ; if (pinnedMainMenu) XMapRaised(mainDisplay, mainMenuWindow); for (i = 0; i < numExtraWins; i++) { if (extraWinInfo[i].mapped && extraWinInfo[i].raise && extraWinInfo[i].window != None) { XMapRaised(mainDisplay, extraWinInfo[i].window); } } XMapRaised(mainDisplay, mbInfo.main_win); } else if (input.type == KeyPress) { switch (HandleMsgBoxKeyEvent(&mbInfo, &input)) { case INVALID: looping = FALSE; rc = INVALID; break; case TRUE: looping = FALSE; rc = TRUE; break; case FALSE: break; } } else if (input.type==ButtonPress && input.xany.window==mbInfo.btn_win) { HandlePasteInDialog(&mbInfo, &input); } else if (IsWM_DELETE_WINDOW(&input)) { looping = FALSE; rc = INVALID; break; } } if (mbInfo.msg_copy != NULL) { free(mbInfo.msg_copy); mbInfo.msg_copy = NULL; } free(dup_msg); XDestroyWindow(mainDisplay, mbInfo.main_win); if (warpToWinCenter) { XWarpPointer(mainDisplay, None, drawWindow, 0, 0, 0, 0, (int)(ZOOMED_SIZE(drawWinW)>>1), (int)(ZOOMED_SIZE(drawWinH)>>1)); } return rc; } int Dialog(Message, Comment, ReturnStr) char *Message, *Comment, *ReturnStr; /* returns INVALID if <ESC> is types */ /* returns FALSE otherwise */ /* if Comment is NULL, "( <CR> or <ESC> to continue )" is assumed */ /* if ReturnStr is NULL, hitting any key will return INVALID */ { static int stDialoging=FALSE; char *real_msg=NULL, def_comment[MAXSTRING+1]; int real_len=strlen(Message), rc; if (Comment == NULL) { strcpy(def_comment, TgLoadCachedString(CSTID_DLG_DEF_CONTINUE)); real_len += strlen(def_comment)+2; } else { real_len += strlen(Comment)+2; } real_msg = (char*)malloc((real_len+1)*sizeof(char)); if (real_msg == NULL) { FailAllocMessage(); return INVALID; } if (stDialoging) return INVALID; stDialoging = TRUE; if (Comment == NULL) { sprintf(real_msg, "%s\n\n%s", Message, def_comment); } else { sprintf(real_msg, "%s\n\n%s", Message, Comment); } EndMeasureTooltip(FALSE); rc = DoDialog(real_msg, ReturnStr); free(real_msg); stDialoging = FALSE; return rc; } ������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/ruler.e������������������������������������������������������������������������������0000644�0000764�0000764�00000007424�11602233312�014272� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/ruler.e,v 1.7 2011/05/16 16:21:59 william Exp $ */ #ifndef _RULER_E_ #define _RULER_E_ extern int showMeasurement; extern int showMeasurementInTooltip; extern int simpleMotionInDrawWin; extern int showCrossHair; #ifdef _INCLUDE_FROM_RULER_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_RULER_C_*/ extern void GetUnitSpec ARGS_DECL((char*)); extern void ShowUnitMsg ARGS_DECL((void)); extern int SetUnit ARGS_DECL((char*)); extern void InitRuler ARGS_DECL((void)); extern void CleanUpRuler ARGS_DECL((void)); extern void PixelToMeasurementUnit ARGS_DECL((char *Buf, int NumPixels)); extern void SquarePixelToMeasurementUnit ARGS_DECL((char *Buf, int NumSquarePixels)); extern void PixelToCurrentUnit ARGS_DECL((char *Buf, int NumPixels)); extern void RedrawHRuler ARGS_DECL((Display*, Window)); extern void RedrawHRulerWindow ARGS_DECL((void)); extern void RedrawVRuler ARGS_DECL((Display*, Window)); extern void RedrawVRulerWindow ARGS_DECL((void)); extern void MarkRulers ARGS_DECL((int XOff, int YOff)); extern void RedrawRulers ARGS_DECL((void)); extern void GetCrossHairPosition ARGS_DECL((int *XOff, int *YOff, int *Shown)); extern void RedrawCrossHair ARGS_DECL((void)); extern void ToggleShowCrossHair ARGS_DECL((void)); extern void RulersEventHandler ARGS_DECL((XEvent *)); extern void FreezeMarkRulerText ARGS_DECL((void)); extern void UnFreezeMarkRulerText ARGS_DECL((void)); extern int VerboseMeasureTooltip ARGS_DECL((void)); extern void BeginIntervalRulers ARGS_DECL((int LtX, int LtY, int RbX, int RbY)); extern void DrawIntervalRulers ARGS_DECL((int LtX, int LtY, int RbX, int RbY, char *delta_str)); extern void EndIntervalRulers ARGS_DECL((int X, int Y)); extern void StartShowMeasureCursor ARGS_DECL((int XOff, int YOff, char *Str, int ExtraSpace)); extern void ShowMeasureCursor ARGS_DECL((int XOff, int YOff, char *Str, int ExtraSpace)); extern void EndShowMeasureCursor ARGS_DECL((int XOff, int YOff, char *Str, int ExtraSpace)); extern void ToggleShowMeasurement ARGS_DECL((void)); extern void ToggleShowMeasurementInTooltip ARGS_DECL((void)); extern void DoIntervalMeasureTooltip ARGS_DECL((int ltx, int lty, int rbx, int rby, int mdx, int mdy, char *delta_str)); extern void StartMeasureTooltip ARGS_DECL((char*)); extern void SetMeasureTooltip ARGS_DECL((char*)); extern void EndMeasureTooltip ARGS_DECL((int force)); extern void CleanUpMeasureTooltip ARGS_DECL((void)); extern int InitMeasureTooltip ARGS_DECL((void)); #ifdef _INCLUDE_FROM_RULER_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_RULER_C_*/ #endif /*_RULER_E_*/ ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Tgif.tmpl-solaris-static�������������������������������������������������������������0000644�0000764�0000764�00000007167�11602233313�017526� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������XCOMM XCOMM Author: William Chia-Wei Cheng (bill.cheng@acm.org) XCOMM XCOMM Copyright (C) 2001-2009, William Chia-Wei Cheng. XCOMM XCOMM This file may be distributed under the terms of the Q Public License XCOMM as defined by Trolltech AS of Norway and appearing in the file XCOMM LICENSE.QPL included in the packaging of this file. XCOMM XCOMM THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING XCOMM THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR XCOMM PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, XCOMM INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING XCOMM FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, XCOMM NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION XCOMM WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. XCOMM XCOMM @(#)$Header: /mm2/home/cvs/bc-src/tgif/Tgif.tmpl-solaris-static,v 1.6 2011/06/14 03:27:09 william Exp $ XCOMM #if ProjectX == 5 #if BuildXimp XIMPDEFINES = #else XIMPDEFINES = -D_NO_XIMP #endif #elif ProjectX > 5 XIMPDEFINES = #endif CC = cc THREADS_CFLAGS = -Bstatic XCOMM ------------------------------------------------------------------------- XCOMM $(OPENWINDIR)/lib is where static X11 libraries are installed. If that's XCOMM not the case, need to overwrite OPENWINDIR. XCOMM For example, at USC, OPENWINDIR should be set to /usr/usc/openwin/5.9. XCOMM ------------------------------------------------------------------------- XCOMM CC = gcc -Wall XCOMM CCOPTIONS = XCOMM OPENWINDIR = /usr/usc/openwin/5.9 OPENWINDIR = /usr/openwin INCROOT = $(OPENWINDIR)/include USRLIBDIR = $(OPENWINDIR)/lib SHLIBDIR = $(OPENWINDIR)/lib MANPATH = $(OPENWINDIR)/man PROJECTROOT = $(OPENWINDIR) PREPROCESSCMD = cc -E $(STD_CPP_DEFINES) EXTRA_LDOPTIONS = EXTRA_LIBRARIES = -lsocket -lnsl -lgen LDCOMBINEFLAGS = -r XCOMM ----------------------------------------------- XCOMM For gcc-2.7.2, you may need -lbind on solaris (before Solaris 2.7): XCOMM CC = gcc -Wall XCOMM PREPROCESSCMD = gcc -E $(STD_CPP_DEFINES) XCOMM CCOPTIONS = XCOMM EXTRA_LIBRARIES = -lsocket -lnsl -lgen -lbind XCOMM ----------------------------------------------- PROGRAMS = tgif XCOMM prtgif frontend11.o testdrive TGIFDIR = $(LIBDIR)/tgif XCOMM CDEBUGFLAGS= -g XCOMM INSTPGMFLAGS= -s XCOMM BINDIR = ${HOME}/bin XCOMM MANPATH = ${HOME}/man XCOMM TGIFDIR = ${HOME}/lib/X11/tgif LOCALEDIR = /usr/lib/locale DIRDEFINES = -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 \@@\ -DLOCALEDIR=\"$(LOCALEDIR)\" \@@\ -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" \@@\ -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" MISCDEFINES = -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT \@@\ -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" \@@\ -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" \@@\ -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN \@@\ -D_HAS_STREAMS_SUPPORT -D_NO_IDNLIB -D_NO_XUTF8FUNCTIONS MOREDEFINES = XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM Please see Imakefile for more defines to be added to MOREDEFINES above XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ DEPLIBS = $(DEPXLIB) LOCAL_LIBRARIES = $(OPENWINDIR)/lib/libX11.a $(OPENWINDIR)/lib/libXext.a XCOMM LOCAL_LIBRARIES = $(XMULIB) $(XTOOLLIB) $(XLIB) SYS_LIBRARIES = -lintl -ldl -lm -lz XCOMM SYS_LIBRARIES = -lm -lz XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM XCOMM This file has been tested under (uname -s -r): XCOMM XCOMM SunOS 5.10 (with 5.9 files) XCOMM XCOMM ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ XCOMM ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/README�������������������������������������������������������������������������������0000644�0000764�0000764�00000007143�11602233312�013651� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/README,v 1.7 2009/10/04 03:02:48 william Exp $ */ This is the ``tgif'' README file. Tgif is pronounced, "T-G-I-F". Tgif is an Xlib base 2-D drawing facility under X11. 1) Please read the "Copyright" file in this distribution for the copyright and licensing information. Please note that starting from tgif-4.1.41, an Open Sourced version of tgif is simulatneously released under the Q Public License. For every tgif-x.y.z release, a corresponding tgif-QPL-x.y.z is also release. Therefore, if you want to use an Open Sourced version of tgif, please look for the tgif-QPL releases. 2) Tgif resources: Home Page: http://bourbon.cs.umd.edu:8001/tgif/ FAQ: http://bourbon.cs.umd.edu:8001/tgif/faq/ Current Release & Download: http://bourbon.cs.umd.edu:8001/tgif/current.html Join to Mailing List: tgif4-announce-subscribe@yahoogroups.com Mailing List: tgif4-announce@yahoogroups.com Bug Reports Send To: bill.cheng@acm.org 3) Please read tgif.man, the man pages that comes with the distribution. nroff -t -man tgif.man | more <== to view psroff -man tgif.man <== to print 4) If you want to use imake, you can copy Tgif.tmpl-PLATFORM to Tgif.tmpl (where PLATFORM depends on the platform you are on). The default Tgif.tmpl is identical to Tgif.tmpl-linux. There's only a few Tgif.tmpl-* files in the current release of tgif. More will be added when they become available. I only have access to limited number of platforms, so if you don't find your platform listed, please ask a local expert to modify Tgif.tmpl and send a working version to me so I can create new Tgif.tmpl-* files. 5) Modify the DEFINES line at the beginning of Tgif.tmpl or Makefile.noimake (see "Things to try..." in the Tgif.tmpl for examples). Please do not change -DTELEPORT_ATTR=\"warp_to=\", -DLAUNCH_ATTR=\"launch=\", or -DEXEC_ATTR=\"exec=\". If you plan to do a "make install" and you don't have root privileges, please uncomment (by remove XCOMM) BINDIR, MANPATH, and the second occurance of TGIFDIR, and replace "/u/halfmoon" with your target directory (such as "/home/yourlogin"). 6) If you have imake and xmkmf, do the following (this is the preferred way of building tgif), xmkmf make tgif make install If you don't have imake, just do the following, cp Makefile.noimake Makefile make tgif If you have imake but don't have xmkmf, do the following, (note that the config directory should be set to wherever you can find Imake.tmpl) imake -DUseInstalled -I/usr/local/libdata/X11/config make tgif make install 7) If you do not have imake or xmkmf, please try the following (you can change "/usr" to a top-level directory where you would like tgif to be installed, e.g., "${HOME}"; this will cause tgif to be installed in ${HOME}/bin and other data files to be installed in ${HOME}/lib/X11/tgif): ./configure --prefix=/usr make make install If "make" does not work, it may be due to platform-specific problems, please do the following for specified platforms: Mac OS X: append "-D__DARWIN__ -D_NO_DL_SUPPORT" after "-DUSE_XT_INITIALIZE" in Makefile Afterwards, please try the following: make clean make make install 8) If your <Meta> key does not work on a HP-UX machine, try doing the following (<Meta> is also labeled <Alt> on some keyboards): xmodmap -e "clear mod1" xmodmap -e "add mod1 = Meta_L Meta_R" 9) Please also note that tgif has nothing to do with GIF files/formats. �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgif.Xdefaults�����������������������������������������������������������������������0000644�0000764�0000764�00000054311�11602233313�015603� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������! ! This file is for reference only; that's why everything is commented out! ! You can uncomment lines and add them to your own resource file (such ! as ~/.Xdefaults if so desired. ! ! You can run tgif without this file. The values in this file are NOT ! identical to the default values used in tgif. You should use ! as few of these as possible! ! ! @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgif.Xdefaults,v 1.77 2011/05/13 15:06:30 william Exp $ ! !Tgif.Geometry: 640x512-40+20 !Tgif.IconGeometry: -224+82 !Tgif.Foreground: Black !Tgif.Background: White !Tgif.BorderColor: White !Tgif.ReverseVideo: off ! !Tgif.InitialFont: Times !Tgif.InitialFont: Courier !Tgif.InitialFont: Helvetica !Tgif.InitialFont: NewCentury !Tgif.InitialFont: Symbol ! !Tgif.InitialFontStyle: Roman !Tgif.InitialFontStyle: Bold !Tgif.InitialFontStyle: Italic !Tgif.InitialFontStyle: BoldItalic ! !Tgif.InitialFontJust: Left !Tgif.InitialFontJust: Center !Tgif.InitialFontJust: Right ! ! The next 3 are obsoleted ! !Tgif.InitialFontDPI: 75 !Tgif.InitialFontSizeIndex: 3 !Tgif.MsgFontSizeIndex: 3 !Tgif.InitialFontSize: 20 !Tgif.MsgFontSize: 14 !Tgif.RulerFontSize: 10 !Tgif.DefaultFontSize: 14 ! !Tgif.FontSizes: 8 10 11 12 14 17 18 20 24 25 34 !Tgif.AdditionalFonts: \n\ ! lucidabright-medium-r-normal,iso8859-1,ZapfChancery-MediumItalic\n\ ! lucidabright-demibold-r-normal,iso8859-1,ZapfChancery-MediumItalic\n\ ! lucidabright-medium-i-normal,iso8859-1,ZapfChancery-MediumItalic\n\ ! lucidabright-demibold-i-normal,iso8859-1,ZapfChancery-MediumItalic !Tgif.AdditionalFonts: \n\ ! lucidasans-%d,iso8859-1,ZapfChancery-MediumItalic\n\ ! lucidasans-bold-%d,iso8859-1,ZapfChancery-MediumItalic\n\ ! lucidasans-italic-%d,iso8859-1,ZapfChancery-MediumItalic\n\ ! lucidasans-bolditalic-%d,iso8859-1,ZapfChancery-MediumItalic !Tgif.FontNamePrefix: -* ! ! To get around font problems... If all you have are ! -*-fixed-medium-r-normal--%d-* fonts, you can set ! Tgif.HasAlternateDefaultFonts to "true" and use the following. ! This will all fonts with the -*-fixed-medium-r-normal--%d-* fonts. ! (You should probably set Tgif.DefFixedWidthFont and ! Tgif.DefFixedWidthRulerFont.) ! !Tgif.HasAlternateDefaultFonts: true !Tgif.Times-Roman: -*-fixed-medium-r-normal--%d-* !Tgif.Times-Bold: -*-fixed-bold-r-normal--%d-* !Tgif.Times-Italic: -*-fixed-medium-r-semicondensed--%d-* !Tgif.Times-BoldItalic: -*-fixed-bold-r-semicondensed--%d-* !Tgif.Courier: -*-fixed-medium-r-normal--%d-* !Tgif.Courier-Bold: -*-fixed-bold-r-normal--%d-* !Tgif.Courier-Oblique: -*-fixed-medium-r-semicondensed--%d-* !Tgif.Courier-BoldOblique: -*-fixed-bold-r-semicondensed--%d-* !Tgif.Helvetica: -*-fixed-medium-r-normal--%d-* !Tgif.Helvetica-Bold: -*-fixed-bold-r-normal--%d-* !Tgif.Helvetica-Oblique: -*-fixed-medium-r-semicondensed--%d-* !Tgif.Helvetica-BoldOblique: -*-fixed-bold-r-semicondensed--%d-* !Tgif.NewCenturySchlbk-Roman: -*-fixed-medium-r-normal--%d-* !Tgif.NewCenturySchlbk-Bold: -*-fixed-bold-r-normal--%d-* !Tgif.NewCenturySchlbk-Italic: -*-fixed-medium-r-semicondensed--%d-* !Tgif.NewCenturySchlbk-BoldItalic: -*-fixed-bold-r-semicondensed--%d-* !Tgif.Symbol: -*-fixed-medium-r-normal--%d-* ! ! Example for Turkish alternate default fonts: ! !Tgif.HasAlternateDefaultFonts: true !Tgif.Times-Roman: -urw-times-medium-r-*-*-%d-*-*-*-*-*-iso8859-9 !Tgif.Times-Bold: -urw-times-bold-r-*-*-%d-*-*-*-*-*-iso8859-9 !Tgif.Times-Italic: -urw-times-medium-i-*-*-%d-*-*-*-*-*-iso8859-9 !Tgif.Times-BoldItalic: -urw-times-bold-i-*-*-%d-*-*-*-*-*-iso8859-9 !Tgif.Courier: -urw-courier-medium-r-*-*-%d-*-*-*-*-*-iso8859-9 !Tgif.Courier-Bold: -urw-courier-bold-r-*-*-%d-*-*-*-*-*-iso8859-9 !Tgif.Courier-Oblique: -urw-courier-medium-o-*-*-%d-*-*-*-*-*-iso8859-9 !Tgif.Courier-BoldOblique: -urw-courier-bold-o-*-*-%d-*-*-*-*-*-iso8859-9 !Tgif.Helvetica: -urw-helvetica-medium-r-*-*-%d-*-*-*-*-*-iso8859-9 !Tgif.Helvetica-Bold: -urw-helvetica-bold-r-*-*-%d-*-*-*-*-*-iso8859-9 !Tgif.Helvetica-Oblique: -urw-helvetica-medium-o-*-*-%d-*-*-*-*-*-iso8859-9 !Tgif.Helvetica-BoldOblique: -urw-helvetica-bold-o-*-*-%d-*-*-*-*-*-iso8859-9 ! !Tgif.DefaultCursor: arrow !Tgif.DrawCursor: arrow !Tgif.DragCursor: hand2 !Tgif.VertexCursor: dotbox !Tgif.FreeHandCursor: pencil !Tgif.RubberBandColor: Aquamarine ! !Tgif.MaxColors: 11 !Tgif.Color0: magenta !Tgif.Color1: red !Tgif.Color2: green !Tgif.Color3: blue !Tgif.Color4: yellow !Tgif.Color5: pink !Tgif.Color6: cyan !Tgif.Color7: CadetBlue !Tgif.Color8: white !Tgif.Color9: black !Tgif.Color10: DarkSlateGray !Tgif.DefaultColorIndex: 0 ! !Tgif.ShortCuts: !<Key>A:SelectAll() \n\ ! !<Key>U:Undo() \n\ ! !<Key>R:Redo() \n\ ! !<Key>X:Delete() \n\ ! !<Key>F:FlushUndoBuffer() \n\ ! !<Key>T:ToggleNamedAttrShown(eq=) \n\ ! !<Key>Q:Quit() ! !Tgif.MaxLineWidths: 7 !Tgif.DefaultLineWidth: 0 !Tgif.LineWidth0: 1 !Tgif.LineWidth1: 2 !Tgif.LineWidth2: 3 !Tgif.LineWidth3: 4 !Tgif.LineWidth4: 5 !Tgif.LineWidth5: 6 !Tgif.LineWidth6: 7 !Tgif.ArrowWidth0: 8 !Tgif.ArrowWidth1: 10 !Tgif.ArrowWidth2: 12 !Tgif.ArrowWidth3: 14 !Tgif.ArrowWidth4: 18 !Tgif.ArrowWidth5: 20 !Tgif.ArrowWidth6: 22 !Tgif.ArrowHeight0: 3 !Tgif.ArrowHeight1: 4 !Tgif.ArrowHeight2: 5 !Tgif.ArrowHeight3: 6 !Tgif.ArrowHeight4: 7 !Tgif.ArrowHeight5: 8 !Tgif.ArrowHeight6: 9 !Tgif.MaxDomains: 1 !Tgif.DomainPath0: DRAWING:\n\ ! /usr/local/lib/tgif/drawing:\n\ ! /usr/local/lib/tgif/msic !Tgif.DefaultDomain: 0 ! Don't need to set the TGIF_DRAWING environment variable any more. ! !Tgif.PrintCommand: lpr ! ! For Epson Stylux 800 ! !Tgif.PrintCommand: gs -q -sDEVICE=escp2 -sOutputFile=- -dNOPAUSE -- %s | lpr ! !Tgif.WhereToPrint: Printer !Tgif.WhereToPrint: EPS !Tgif.WhereToPrint: PS !Tgif.WhereToPrint: Bitmap !Tgif.WhereToPrint: Text !Tgif.WhereToPrint: EPSI !Tgif.WhereToPrint: GIF !Tgif.WhereToPrint: HTML ! !Tgif.PrintDirectory: /tmp !Tgif.NoTgifIcon: false !Tgif.UseWMIconPixmap: false !Tgif.DontShowVersion: true !Tgif.XBmReverseVideo: false !Tgif.AskForXBmSpec: false !Tgif.AskForXPmSpec: false !Tgif.StripEPSComments: false <-- obsolete!!! !Tgif.GuessXPmBgColor: false !Tgif.XPmOutputVersion: 1 !Tgif.XPmInXGrabSCFormat: false !Tgif.UseGrayScale: false !Tgif.AutoPanInEditText: true !Tgif.PercentPrintReduction: 100 !Tgif.ConstrainedMove: false !Tgif.DoubleQuoteDoubleQuote: false ! !Tgif.GridSystem: English !Tgif.GridSystem: Metric ! !Tgif.InitialGrid: -1 !Tgif.DropObsIconAttrWhenUpdate: false !Tgif.UseRecentDupDistance: true !Tgif.SplineTolerance: 7 !Tgif.SplineRubberband: true <-- obsolete!!! !Tgif.Synchronize: off !Tgif.DoubleClickUnIconify: true !Tgif.MainMenuPinDistance: 80 !Tgif.DoubleClickInterval: 300 !Tgif.HandleSize: 2 !Tgif.HistoryDepth: 10 !Tgif.SaveTmpOnReturn: false !Tgif.ImportFromLibrary: false !Tgif.WarpToWinCenter: false !Tgif.SaveCommentsInSaveNew: true !Tgif.CanvasWindowOnly: false ! !Tgif.UsePsAdobeString: false ! The following will generate "%!PS-Adobe-2.0 EPSF-1.2" in EPS files ! which may be needed for some Windows applications. !Tgif.UsePsAdobeString: 2.0/1.2 ! !Tgif.HalfToneBitmap: false !Tgif.ThresholdBitmap: false !Tgif.BitmapThreshold: 0.5 !Tgif.GroupedTextEditable: true !Tgif.ForceClearAfterEPS: false <-- obsolete!!! !Tgif.DefaultEPSScaling: 1 !Tgif.DefaultEPSScaling: 1.7778 <-- good for letter !Tgif.DefaultEPSScaling: 1.7639 <-- good for A4 !Tgif.IntrCheckInterval: 10 !Tgif.TiledPageScaling: 0.95 !Tgif.TGIFPATH: <must be a full path name> !Tgif.TGIFICON: <a full path name or a file name under TGIFPATH> !Tgif.StickyMenuSelection: true !Tgif.PSBopHook: tgif-bop-hook !Tgif.PSEopHook: tgif-eop-hook !Tgif.MinimalEPS: true !Tgif.InitialPrintInColor: true !Tgif.InitialShowGrid: false !Tgif.InitialSnapOn: false !Tgif.NoMenubar: false !Tgif.NoStatusWindow: false !Tgif.ReverseMouseStatusButtons: false !Tgif.MinimalMenubar: true !Tgif.ColorBgInPrintingColorPS: false !Tgif.ScrollBarWidth: 16 ! !Tgif.InitialPaperSize: 8.5in x 11in !Tgif.InitialPaperSize: 21cm x 29.7cm ! !Tgif.UpdateChildUsingAlignment: false !Tgif.UpdateChildUsingAlignment: true !Tgif.UpdateChildUsingAlignment: no_overlap ! !Tgif.GenerateImageMap: false !Tgif.XpmToGif: xpmtoppm %s | ppmtogif !Tgif.ImageMapFileExtension: map !Tgif.GifFileExtension: gif !Tgif.ImageMapFileFormat: NCSA !Tgif.ImageMapFileFormat: CERN !Tgif.UseXPmVersion1ForImageMap: true !Tgif.UsePaperSizeStoredInFile: false !Tgif.OneMotionSelMove: false !Tgif.TiffEPSI: false <-- obsolete!!! !Tgif.XbmToTiff: xbmtopbm %s | pnmtotiff -none > %s !Tgif.EPSIExportExtension: epsi !Tgif.HotListFileName: <Your home directory>/.Tgif_hotlist ! ! Fot the viewers below, use %S if the tool can accept URL; otherwise, use %s. ! If NONE is used, tgif will prompt for a local file name to save into. ! !Tgif.htmlViewer: xmosaic %S !Tgif.gifViewer: xv %s !Tgif.tiffViewer: NONE ! !Tgif.AutoHyperSpaceOnRemote: true !Tgif.AllowLaunchInHyperSpace: false !Tgif.CanChangeAttrColor: false !Tgif.MimeTypesFile: /u/guest/william/.mime.types !Tgif.LocalRGBTxt: /usr/local/lib/X11/rgb.txt !Tgif.PrintUsingRequestedColor: false ! !Tgif.ShowMeasurement: false !Tgif.ShowMeasurementUnit: pixel !Tgif.ShowMeasurementUnit: inch !Tgif.ShowMeasurementUnit: cm ! !Tgif.PageStyleLandscape: false ! !Tgif.QueryZoomInPoint: true !Tgif.QueryZoomInPoint: always !Tgif.QueryZoomInPoint: no_select ! !Tgif.GZipCmd: gzip -c !Tgif.GUnZipCmd: gunzip -c !Tgif.HttpProxy: <host>:<port> !Tgif.FtpProxy: <host>:<port> !Tgif.InitialArrowStyle: RIGHT !Tgif.ShowPageInEPS: false !Tgif.MaxNavigateCacheBuffers: 40 !Tgif.NumberFileInPrintOnePage: false !Tgif.OneMotionTimeout: 200 !Tgif.MinMoveInterval: 0 !Tgif.GifToXpm: giftopnm %s | ppmtoxpm !Tgif.InitExportPixelTrim: 0,0,0,0 ! ! Version 3.0 and above ! !Tgif.QuantizingLevels: 222 !Tgif.RotateCursor: crosshair !Tgif.ColorLayers: false !Tgif.TiffToXbm: tifftopnm %s | pgmtopbm | pbmtoxbm !Tgif.DefFixedWidthFont: -*-courier-medium-r-normal--12-*-*-*-*-*-*-* !Tgif.DefFixedWidthRulerFont: -*-courier-medium-r-normal--10-*-*-*-*-*-*-* !Tgif.MenuFont: -*-helvetica-bold-r-normal--12-*-*-*-*-*-*-* !Tgif.BoldMsgFont: -*-helvetica-bold-r-normal--12-*-*-*-*-*-*-* !Tgif.MsgFont: -*-helvetica-medium-r-normal--12-*-*-*-*-*-*-* !Tgif.BggenToXpm: bggen %s -g %s | ppmquant 64 | ppmtoxpm !Tgif.DefaultErrorDiffuseLevels: 2 3 2 !Tgif.MaxImportFilters: 5 !Tgif.ImportFilter0: GIF-dither gif giftopnm %s | ppmdither | ppmtoxpm !Tgif.ImportFilter1: GIF gif giftopnm %s | ppmquant 222 | ppmtoxpm !Tgif.ImportFilter2: JPEG-dither jpg;jpeg \n\ ! djpeg -gif %s | giftopnm | ppmdither | ppmtoxpm !Tgif.ImportFilter3: JPEG jpg;jpeg \n\ ! djpeg -gif -colors 222 %s | giftopnm | ppmtoxpm !Tgif.ImportFilter4: EPStoHiResPpm ps;eps \n\ ! convert -scale 43%% -density 288 '%s' ppm:- !Tgif.ShowFileNameOnBrowse: true !Tgif.HtmlFileExtension: html !Tgif.GenerateHtmlHref: true !Tgif.RotationIncrement: 45 !Tgif.PSA4PaperSize: false !Tgif.ShapeShadowSpec: 2,2 !Tgif.StretchableText: true !Tgif.EditTextSize: 0 !Tgif.EditTextSize: 14 !Tgif.IconPixmap: /usr/lib/X11/tgif/tgificon.xpm <-- obsolete!!! !Tgif.WMIconPixmap: /usr/local/lib/X11/tgif/tgificon.xpm !Tgif.TmpFileMode: 0664 !Tgif.TitledPinnedMenu: true !Tgif.ColorFromXPixmap: /usr/local/lib/X11/tgif/tgificon.xpm !Tgif.VectorWarpSoftness: 1.5 !Tgif.ChangePropertiesOfAttrs: false !Tgif.ShiftForDiagMouseMove: false !Tgif.UseRecentForDiagMouseMove: false !Tgif.FlushColormapOnOpen: true !Tgif.TransparentPattern: false !Tgif.DontReencode: Times:Courier:Helvetica !Tgif.UnsignedInXBmExport: true !Tgif.CommentInBitmapExport: true !Tgif.ShowFontSizeInPoints: false !Tgif.DontCondensePSFile: true !Tgif.StripCondensedPSComments: false <-- obsolete!!! !Tgif.PdfFileExtension: pdf !Tgif.PsToPdf: ps2pdf "%s" "%s" !Tgif.3DLook: true !Tgif.XpmDeckToGifAnim: gifsicle -lforever --delay 10 !Tgif.XpmDeckToGifAnim: whirlgif -loop -time 10 !Tgif.GifAnimExplode: gifsicle -eU !Tgif.Btn3PopupModeMenu: false <-- obsolete!!! !Tgif.ScriptFraction: 0.6 !Tgif.DeleteNextCharWithDelKey: true ! ! DoubleByte related ! !Tgif.DefaultSingleByteFont: Helvetica !Tgif.SquareDoubleByteFonts: \n\ ! -hku-fixed-medium-r-normal--%d-*-*-*-*-*-big5.hku-0,*,HKU\n\ ! -hku-fixed-medium-r-normal--%d-*-*-*-*-*-big5.hku-0,*,HKU\n\ ! -hku-fixed-medium-r-normal--%d-*-*-*-*-*-big5.hku-0,*,HKU\n\ ! -hku-fixed-medium-r-normal--%d-*-*-*-*-*-big5.hku-0,*,HKU ! ! For zh_TW.big5 ! !Tgif.SquareDoubleByteFonts: \n\ ! -taipei-fixed-medium-r-normal--%d-*-*-*-*-*-big5-0,*,ShanHeiSun-Light-B5-H\n\ ! -taipei-fixed-medium-r-normal--%d-*-*-*-*-*-big5-0,*,ZenKai-Medium-B5-H\n\ ! -taipei-fixed-medium-r-normal--%d-*-*-*-*-*-big5-0,*,ShanHeiSun-Light-B5-H\n\ ! -taipei-fixed-medium-r-normal--%d-*-*-*-*-*-big5-0,*,ZenKai-Medium-B5-H ! ! For zh_CN.euc ! !Tgif.SquareDoubleByteFonts: \n\ ! -isas-fangsong ti-medium-r-normal--%d-*-*-*-*-*-gb2312.1980-0,*,MSungGBK-Light-GB-H\n\ ! -isas-song ti-medium-r-normal--%d-*-*-*-*-*-gb2312.1980-0,*,GBZenKai-Medium-GB-H\n\ ! -isas-fangsong ti-medium-r-normal--%d-*-*-*-*-*-gb2312.1980-0,*,MSungGBK-Light-GB-H\n\ ! -isas-song ti-medium-r-normal--%d-*-*-*-*-*-gb2312.1980-0,*,GBZenKai-Medium-GB-H !Tgif.SquareDoubleByteFonts: \n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,Ryumin-Light-EUC-H\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,Ryumin-Light-EUC-H\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,Ryumin-Light-EUC-H\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,Ryumin-Light-EUC-H\n\ !\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,GothicBBB-Medium-EUC-H\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,GothicBBB-Medium-EUC-H\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,GothicBBB-Medium-EUC-H\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,H,GothicBBB-Medium-EUC-H\n\ !\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,Ryumin-Light-EUC-V\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,Ryumin-Light-EUC-V\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,Ryumin-Light-EUC-V\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,Ryumin-Light-EUC-V\n\ !\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,GothicBBB-Medium-EUC-V\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,GothicBBB-Medium-EUC-V\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,GothicBBB-Medium-EUC-V\n\ !-jis-fixed-medium-r-*--%d-*-*-*-*-*-jisx0208.1983-*,V,GothicBBB-Medium-EUC-V Tgif.HKUShowFontChar: \244\244 Tgif.MSungGBKShowFontChar: \271\372 Tgif.GBZenKaiShowFontChar: \271\372 Tgif.RyuminShowFontChar: \244\242 Tgif.GothicBBBShowFontChar: \244\316 Tgif.ShanHeiSunShowFontChar: \244\244 Tgif.ZenKaiShowFontChar: \244\244 !Tgif.DoubleByteInputMethod: xcin !Tgif.DoubleByteInputMethod: chinput !Tgif.DoubleByteInputMethod: kinput2 !Tgif.DoubleByteInputMethod: tgtwb5,-taipei-fixed-medium-r-normal--16-150-75-75-c-160-big5-0 !Tgif.DoubleByteInputMethod: tgchgb,-isas-fangsong ti-medium-r-normal--16-160-72-72-c-160-gb2312.1980-0 !Tgif.DoubleByteInputMethod: xim ! ! If Tgif.DoubleByteInputMethod is set to kinput2 or xim and you are mainly ! operated in a Japanese environment, please try the following settings: ! ! Please note that the environment variables LANG and XMODIFIERS override the ! Tgif.Lang and Tgif.Modifiers X defaults. ! Tgif.UseNKF: true Tgif.CopyAndPasteJIS: true Tgif.PreeditType: root !Tgif.PreeditType: overthespot !Tgif.Lang: ja_JP.EUC !Tgif.Lang: ja_JP.ujis !Tgif.Modifiers: false !Tgif.ConvSelection: _JAPANESE_CONVERSION ! ! After release 4.0 ! !Tgif.VisibleGridInSlideShow: false !Tgif.SmoothScrollingCanvas: jump !Tgif.SmoothScrollingCanvas: off !Tgif.SmoothScrollingCanvas: smooth !Tgif.LightGrayColor: gray75 !Tgif.DarkGrayColor: gray50 !Tgif.DefaultObjectBackground: white !Tgif.UseImagePixelsForTrueColorExport: false !Tgif.DialogboxUse3DBorder: true ! ! Tgif.MenuFontSet and Tgif.LocaleDir are only useful if tgif is ! compiled with the ENABLE_NLS compiler option. ! !Tgif.MenuFontSet: a14,k14,r14 !Tgif.MsgFontSet: a14,k14,r14 !Tgif.BoldMsgFontSet: a14,k14,r14 !Tgif.BoldMsgFontDoubleByte: true !Tgif.LocaleDir: /usr/share/lib ! ! Added in version 4.1.9 ! !Tgif.PsRegMarksInTiledPageMode: false !Tgif.PsRegMarksGray: 0.95 !Tgif.PSFontAliases: \n\ ! UtopiaSE-Regular=Utopia-Regular \n\ ! UtopiaSE-Bold=Utopia-Bold \n\ ! UtopiaSE-Italic=Utopia-Italic \n\ ! UtopiaSE-BoldItalic=Utopia-BoldItalic ! ! Added in version 4.1.16 ! !Tgif.DomainInIni: false ! ! Added in version 4.1.17 ! !Tgif.UndoRedoRestoreDrawingMode:true !Tgif.MenuRowsBeforeScroll: 20 !Tgif.MenuColsBeforeScroll: 26 !Tgif.PngToXpm: pngtopnm %s | ppmquant 222 | ppmtoxpm !Tgif.XpmToPng: xpmtoppm %s | pnmtopng !Tgif.PngFileExtension: png !Tgif.ProducedBy: Copyright ? 2000, your name <your-e-mail@your.org> !Tgif.Editor: xemacs -title '%s' '%s' !Tgif.Editor: xterm -title '%s' -e vi '%s' ! ! Added in version 4.1.26 ! !Tgif.GoHyperSpaceInSlideShow: false !Tgif.LineWidthIndexInSlideShow: 4 !Tgif.MaxRecentFiles: 10 !Tgif.ResetOriginOnAdvancePage: false ! ! Added in version 4.1.29 ! !Tgif.UseMeasureTooltip: false !Tgif.MeasureTooltipXFollowMouse: false !Tgif.MeasureTooltipYFollowMouse: false !Tgif.MeasureTooltipHorizontalPosition: left/center/right !Tgif.MeasureTooltipVerticalPosition: top/middle/bottom !Tgif.MeasureTooltipVerbose: true ! ! Added in version 4.1.30 ! !Tgif.NoMinWinSize: true !Tgif.JpegToXpm: djpeg -gif -color 222 %s | giftopnm | ppmtoxpm ! ! Added in version 4.1.31 ! !Tgif.AutoWrapMenubar: false ! ! Added in version 4.1.34 ! !Tgif.XpmToJpeg: xpmtoppm %s | cjpeg !Tgif.JpegFileExtension: jpg !Tgif.AutoEPSPreviewBitmap: false !Tgif.PsToXbm: gs -q -dNOPAUSE -sDEVICE=pbm -sOutputFile=- -- "%s" | pbmtoxbm ! ! Added in version 4.1.35 ! !Tgif.TmpDirInHomeDir: true !Tgif.TmpDir: /somewhere/tmp <-- try not to use this entry !Tgif.ThumbnailGeometry: 160x120 !Tgif.ThumbnailPadding: 8 !Tgif.ThumbnailXGap: 16 !Tgif.ThumbnailYGap: 0 !Tgif.ThumbnailX: 32 !Tgif.ThumbnailY: 32 !Tgif.ShowWireSignalName: true ! ! Added in version 4.1.39 ! !Tgif.LandscapePdfSetPageDevice: true ! ! Added in version 4.1.40 ! !Tgif.DeleteCmdAsCut: true <-- obsolete!!! !Tgif.EnableMouseWheel: false !Tgif.Btn2PopupMainMenu: false ! ! Added in version 4.1.41 ! !Tgif.PdfSetPageDevice: true !Tgif.AdditionalDontReencode: FFDingbests:ZapfDingbats !Tgif.NoChoiceWindow: false !Tgif.UseXPmVersion1ForXPmDeck: true !Tgif.SlideShowWindowOffsets: -20,-20 !Tgif.SlideShowBorderColor: red !Tgif.ConvertToBezierSegments: 50 !Tgif.TickMarkSize: 8 ! ! Added in version 4.1.42 ! !Tgif.NoModeWindow: false !Tgif.MakeUnsavableInSlideShow: false ! ! Added in version 4.1.43 ! !Tgif.SingleByteInputMethod: xim !Tgif.IgnoreSlideShowOffsetsInFile: true !Tgif.ItalicMsgFont: -*-helvetica-medium-o-normal--12-*-*-*-*-*-*-* !Tgif.ItalicMsgFontSet: a14,k14,r14 !Tgif.BoldItalicMsgFont: -*-helvetica-bold-o-normal--12-*-*-*-*-*-*-* !Tgif.BoldItalicMsgFontSet: a14,k14,r14 !Tgif.PbmToXbm: pbmtoxbm %s !Tgif.PgmToXpm: ppmtoxpm %s !Tgif.PpmToXpm: ppmquant 222 %s | ppmtoxpm !Tgif.ExternalPsToEpsi: false !Tgif.GsPath: gs !Tgif.CompoundTextStretchableForPSE: true !Tgif.HideWindowsInSlideShow: true ! ! Added in version 4.1.45 ! !Tgif.PSDistillerNoImageCompress: false !Tgif.AdditionalPSSetup: \n\ ! systemdict /setdistillerparams known \n\ ! { << /AutoFilterGrayImages false /AutoFilterColorImages false \n\ ! /ColorImageFilter /FlateEncode /GrayImageFilter /FlateEncode \n\ ! >> setdistillerparams } if !(for iso8859-2 encoded Courier fonts) !Tgif.PSFontNeedCharSubs: \n\ ! Courier=iso8859-2 \n\ ! Courier-Bold=iso8859-2 \n\ ! Courier-Oblique=iso8859-2 \n\ ! Courier-BoldOblique=iso8859-2 !Tgif.PSCharSubs_iso8859-2: \n\ ! 8#241/Aogonek \n\ ! 8#243/Lslash \n\ ! 8#246/Sacute \n\ ! 8#254/Zacute \n\ ! 8#257/Zdotaccent \n\ ! 8#261/aogonek \n\ ! 8#263/lslash \n\ ! 8#266/sacute \n\ ! 8#274/zacute \n\ ! 8#277/zdotaccent \n\ ! 8#306/Cacute \n\ ! 8#312/Eogonek \n\ ! 8#321/Nacute \n\ ! 8#346/cacute \n\ ! 8#352/eogonek \n\ ! 8#361/nacute !(iso8859-13 fonts have the nice looking double quotation marks used in LaTeX) !Tgif.PSCharSubs_iso8859-13: \n\ ! 8#241/quotedblright \n\ ! 8#264/quotedblleft !Tgif.DrawTextFuncKey_F2: \n\ ! set_selected_text_style("b"); \n\ ! set_selected_obj_color("#000000"); !Tgif.DrawTextFuncKey_F4: call_simple_shortcut("InsertSymbol"); !Tgif.DrawTextFuncKey_F6: \n\ ! set_selected_text_style("bi"); \n\ ! set_selected_obj_color("#0000ff"); !Tgif.DrawTextFuncKey_F8: \n\ ! set_selected_text_style("bi"); \n\ ! set_selected_obj_color("#008000"); !Tgif.PasteFromXSelectionOnly: true !Tgif.PasteFromSelectionTimeout: 10 !Tgif.LengthLimit256InInsertChar: false !Tgif.JpegToPpm6: djpeg -ppm "%s" !Tgif.ObjectShadowOffsets: 2,2 !Tgif.ObjectShadowColor: #c0c0c0 !Tgif.IgnoreObjectShadowInfoInFile: true ! ! Added in version 4.2 ! !Tgif.ReportMissingFonts: false !Tgif.CustomPatternDir: /usr/local/lib/tgif/xbm !Tgif.EnableTrueColorImages: true !Tgif.PpmToGif: ppmquant 222 %s | ppmtogif !Tgif.PpmToPng: pnmtopng %s !Tgif.PpmToJpeg: cjpeg %s !Tgif.Ppm6ToXpm3: ppmtoxpm %s !Tgif.PngToPpm6: pngtopnm "%s" !Tgif.PpmQuantize: pnmquant %d %s !Tgif.PpmFSQuantize: pnmquant -fs %d %s !Tgif.BggenToPpm6: bggen %s -g %s !Tgif.LittleEndianPpm6: false !Tgif.EPSIThresholdPreviewBitmap: false !Tgif.EPSIPreviewBitmapThreshold: 0.5 !Tgif.EpsToTmpSvg: pstoedit -dt -f sk "%s" "%s" !Tgif.TmpSvgToSvg: uniconvertor "%s" "%s" !Tgif.SvgFileExtension: sk ! Note: for cygwin, must change "utf8" to "utf-8" for the next 4 lines Tgif.HKUConvFromUTF8: iconv -f utf8 -t big5 Tgif.HKUConvToUTF8: iconv -f big5 -t utf8 Tgif.GBUConvFromUTF8: iconv -f utf8 -t gb2312 Tgif.GBUConvToUTF8: iconv -f gb2312 -t utf8 !Tgif.DefaultLatin1FontCharEncoding: iso10646-1 Tgif.AutoRotatePivot: false ! ! Added in version 4.2.1 ! !Tgif.RightMargin: 128 pixel !Tgif.RightMargin: 2.5 cm !Tgif.RightMargin: 1 in !Tgif.EnableRightMargin: false ! ! Added in version 4.2.3 ! !Tgif.NoOrientationIfPdfSetPageDevice: true !Tgif.PNGExportHasTransparentColor: false !Tgif.PNGExportTransparentColor: #ffffff !Tgif.PpmToPngWithTransparentColor: pnmtopng -transparent '%s' '%s' !Tgif.EnableThresholdFloodReplaceColor: false !Tgif.FloodReplaceColorThreshold: 15,15,15 !Tgif.UseStdPalette8: false !Tgif.UseStdPalette27: false !Tgif.UseStdPalette64: false !Tgif.UseStdPalette216: false !Tgif.UseMobileWebSafePalette: false !Tgif.UseOpenOfficeGalaxyPalette: false !Tgif.UseOpenOfficeGooglePalette: false !Tgif.AdditionalColors: #ff8000,#ffce00,#d02090 !Tgif.DefaultColor: #000000 !Tgif.GifToPpm6: giftopnm "%s" �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/strtbl.e�����������������������������������������������������������������������������0000644�0000764�0000764�00000255025�11602233313�014456� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/strtbl.e,v 1.109 2011/05/16 16:21:59 william Exp $ */ #ifndef _TGIF_STRTBL_E_ #define _TGIF_STRTBL_E_ /* * ID's that starts with CSTID_ are "cached" for fast access. * ID's that starts with STID_ are not cached. */ /* ===================== Cached ===================== */ #define MINCACHEDSTIDS 100 #define CSTID_OK 100 #define CSTID_CANCEL 101 #define CSTID_PARANED_NONE 102 #define CSTID_SET_FONT_TO 103 #define CSTID_NO_OBJ_SELECTED 104 #define CSTID_SPECIFY_ARC_END 105 #define CSTID_SPECIFY_ARC_START 106 #define CSTID_SPECIFY_ARC_THIRD 107 #define CSTID_SET_ARC_END 108 #define CSTID_SET_ARC_START 109 #define CSTID_SET_ARC_THIRD 110 #define CSTID_SPECIFY_ARC_END_CW 111 #define CSTID_SPECIFY_ARC_END_CCW 112 #define CSTID_CANCEL_NOT_AVAIL 113 #define CSTID_DLG_DEF_CONTINUE 114 #define CSTID_DLG_ACCEPT_CANCEL 115 #define CSTID_MALFORMED_INPUT_STR 116 #define CSTID_CACHING_TEXT_BMP 117 #define CSTID_PROGRESS_PERCENT 118 #define CSTID_FINISHED_CACHEING_TEXT_BMP 119 #define CSTID_BAD_BOX_BBOX_ADJUSTED 120 #define CSTID_MAIN_MENU 121 #define CSTID_MODE_MENU 122 #define CSTID_ROTATE_DEGREES_CW 123 #define CSTID_ROTATE_DEGREES_CCW 124 #define CSTID_PRINT_MODE 125 #define CSTID_EXPORT_MODE 126 #define CSTID_PRINT_EXPORT_MENU 127 #define CSTID_FLUSH_UNDO_PERCENT 128 #define CSTID_SET_COLOR_TO 129 #define CSTID_CANNOT_ALLOC_COLOR_USE_ALT 130 #define CSTID_UPDATING_PIXELS 131 #define CSTID_NONE 132 #define CSTID_PARANED_NULL 133 #define CSTID_COPY 134 #define CSTID_SAVE 135 #define CSTID_PASTE 136 #define CSTID_RESTORE 137 #define CSTID_YES 138 #define CSTID_NO 139 #define CSTID_EXTRA 140 #define CSTID_INTERRUPT 141 #define CSTID_LEAVE_HYPERSPACE 142 #define CSTID_ENTER_HYPERSPACE 143 #define CSTID_CACHING_IMAGE 144 #define CSTID_TOGGLE_SMOOTH_HINGE 145 #define CSTID_FINISH 146 #define CSTID_DEL_A_VERTEX 147 #define CSTID_ADD_A_VERTEX 148 #define CSTID_START_LAYOUT_ON_ARC 149 #define CSTID_END_LAYOUT_ON_ARC 150 #define CSTID_EXECUTING_GIVEN_PROGRAM 151 #define CSTID_DOTS_DONE 152 #define CSTID_IMPORTING_FILE 153 #define CSTID_LOADING_FILE 154 #define CSTID_EDIT_TEXT_SIZE_SUBSTR 155 #define CSTID_SET_FONT_SIZE_TO_PT 156 #define CSTID_SET_FONT_SIZE_TO 157 #define CSTID_MAKING_CONN_TO_HOST 158 #define CSTID_CONN_TO_HOST_ESTABLISHED 159 #define CSTID_LOGIN_SUCC_RETRIEVE_DATA 160 #define CSTID_LAYOUT_MENU 161 #define CSTID_MAKING_CONN_TO_HOST_PORT 162 #define CSTID_CONN_TO_HOST_PORT_ESTB 163 #define CSTID_SENDING_REQUESTS_DOTS 164 #define CSTID_PARANED_UNKNOWN 165 #define CSTID_READING_RESPONSE_DOTS 166 #define CSTID_RESPONSES_RECEIVED 167 #define CSTID_GEN_FINAL_PIXELS_PERC 168 #define CSTID_BUILDING_HISTOGRAM_DOTS 169 #define CSTID_HISTOGRAM_PERC 170 #define CSTID_COMP_NEW_PIXELS_PERC 171 #define CSTID_QUANTIZING_COLORS_DOTS 172 #define CSTID_REMAPPING_COLORS_DOTS 173 #define CSTID_COMPUTING_NEW_PIXELS_PERC 174 #define CSTID_CALC_ERR_DIFF_PIX_VAL_PERC 175 #define CSTID_CALC_NEW_PIX_1_VAL_PERC 176 #define CSTID_CALC_NEW_PIX_2_VAL_PERC 177 #define CSTID_DLG_ACCEPT_CONTINUE 178 #define CSTID_OPENING_GIVEN 179 #define CSTID_BACKGROUNDING_CMD 180 #define CSTID_CNTRL_C_TO_INTR_AND_ABEND 181 #define CSTID_MOVE_PINNED_MENU 182 #define CSTID_CLOSE_PINNED_MENU 183 #define CSTID_RELEASE_MOUSE_TO_PIN_MENU 184 #define CSTID_LOCKED_OBJS_NOT_MOVED 185 #define CSTID_SCROLL_DOWN_1_LINE 186 #define CSTID_SCROLL_AROUND 187 #define CSTID_SCROLL_UP_1_LINE 188 #define CSTID_ENABLE_REDRAW 189 #define CSTID_DISABLE_REDRAW 190 #define CSTID_GET_DIR_LIST_PLEASE_WAIT 191 #define CSTID_ENTERING_HYPERSPACE 192 #define CSTID_GOTO 193 #define CSTID_DELETE 194 #define CSTID_CLOSE 195 #define CSTID_BAD_OVAL_BBOX_ADJ 196 #define CSTID_SHIFT_ALL_TABS_RIGHT 197 #define CSTID_SHIFT_TABS_RIGHT 198 #define CSTID_SHIFT_TABS_LEFT 199 #define CSTID_SHIFT_ALL_TABS_LEFT 200 #define CSTID_SHIFT_10_TABS_RIGHT 201 #define CSTID_SHIFT_10_TABS_LEFT 202 #define CSTID_PAGE_MENU 203 #define CSTID_GOTO_GIVEN_PAGE 204 #define CSTID_GOTO_GIVEN_PAGE_WITH_NAME 205 #define CSTID_GRAYSTR_CALLED_WITH_IDX_2 206 #define CSTID_GRAY_SCALE_USED_FOR_PAT 207 #define CSTID_SET_FILL_TO_NONE 208 #define CSTID_SET_FILL_TO_SOLID 209 #define CSTID_SET_FILL_TO_BACKGROUND 210 #define CSTID_SET_FILL_TO_PAT_NUMBER 211 #define CSTID_SET_LINE_WIDTH_TO_GIVEN_S 212 #define CSTID_SET_PEN_DASH_PAT_NO_DASH 213 #define CSTID_SET_PEN_DASH_PAT_PAT_NUM 214 #define CSTID_SET_PEN_TO_NONE 215 #define CSTID_SET_PEN_TO_SOLID 216 #define CSTID_SET_PEN_TO_BACKGROUND 217 #define CSTID_SET_PEN_TO_PAT_NUM 218 #define CSTID_SEL_A_PIN_ESC_TO_END_DOTS 219 #define CSTID_ADD_LAST_VERTEX 220 #define CSTID_SINGLE_PT_POLY_CONVERTED 221 #define CSTID_BAD_SMOOTHHINGE_POLY_FIXED 222 #define CSTID_CLOSE_POLYGON_SPLINE 223 #define CSTID_SNGL_PT_POLYGON_CONVERTED 224 #define CSTID_TWO_PT_POLYGON_CONVERTED 225 #define CSTID_FILEVER_TOO_LARGE_FOR_RCBOX 226 #define CSTID_BAD_RCBOX_BBOX_ADJUSTED 227 #define CSTID_PARANED_SEC_ELAPSED_AVG_SPEED 228 #define CSTID_UNZIPPING_WITH_CMD_DOTS 229 #define CSTID_UNCOMPRESSING_WITH_CMD_DOTS 230 #define CSTID_DATA_RECEIVED 231 #define CSTID_FORWARDING_URL_TO_URL 232 #define CSTID_SCROLL_UP 233 #define CSTID_SCROLL_DOWN 234 #define CSTID_SCROLL_PAGE_UP 235 #define CSTID_SCROLL_PAGE_DOWN 236 #define CSTID_SCROLL_VERTICALLY 237 #define CSTID_SCROLL_HORIZONTALLY 238 #define CSTID_SCROLL_LEFT 239 #define CSTID_SCROLL_RIGHT 240 #define CSTID_SCROLL_PAGE_LEFT 241 #define CSTID_SCROLL_PAGE_RIGHT 242 #define CSTID_CANT_FIND_ATTR_WITH_COLOR 243 #define CSTID_CANT_FIND_FILEATTR_WITH_COLOR 244 #define CSTID_CANT_FIND_NAMED_ATTR 245 #define CSTID_CANT_FIND_INTERPRETABLE_ATTR 246 #define CSTID_NO_ACTION_TAKEN 247 #define CSTID_FAIL_READ_ICONPXMP_USE_BMP 248 #define CSTID_DRAG_MOUSE_CREATE_SHAPE_DOTS 249 #define CSTID_CREATE_A_SHAPE_ABORTED 250 #define CSTID_INSTANTIATING_FILE_DOTS 251 #define CSTID_ATTR_PROMOTED_TO_NEW_SYMBOL 252 #define CSTID_ATTR_PROMOTED_TO_NEW_ICON 253 #define CSTID_CREATING_FILE_DOTS 254 #define CSTID_NAMED_FILE_CREATED 255 #define CSTID_WRITING_ATTR_TO_NAMED_FILE 256 #define CSTID_SEMICOLON_USED_AS_SEPARATOR 257 #define CSTID_TAB_USED_AS_SEPARATOR 258 #define CSTID_PROCESSING_OBJ_NUMBER 259 #define CSTID_PLACING_NAMED_OBJ 260 #define CSTID_WRITING_ATTRS_IN_TBL_FORM_TO 261 #define CSTID_CORRUPTED_POLY_MKMULTISPLINE 262 #define CSTID_CORRUPTED_POLY_DMPMULTICURVE 263 #define CSTID_FIX_ATTEMPTED 264 #define CSTID_PUSHING_INTO_NAMED 265 #define CSTID_CUR_FILE_IS 266 #define CSTID_DONT_KNOW_HOW_HANDLE_FRAME_CT 267 #define CSTID_CANT_FIND_OBJ_NAME_ON_RESIZE 268 #define CSTID_PASTING_LINE_NUM_DOTS 269 #define CSTID_CANT_PASTE_DEL 270 #define CSTID_CANT_PASTE_BS 271 #define CSTID_CANT_PASTE_ESC 272 #define CSTID_CANT_PASTE_TAB_REPLACE_BY_SPC 273 #define CSTID_READING_FILE_DOTS 274 #define CSTID_RETURNED_FROM_BASIC_DRIVER 275 #define CSTID_CACHING_BITMAP 276 #define CSTID_FINISHED_CACHEING_BITMAP 277 #define CSTID_NEW_BMP_SIZE_IS_W_X_H 278 #define CSTID_BLD_COLOR_TBL_FROM_PIXEL_DOTS 279 #define CSTID_GENERATING_IMAGEMAP_FILE_DOTS 280 #define CSTID_GENERATING_HTML_FILE_DOTS 281 #define CSTID_GENERATING_IMAGE 282 #define CSTID_FS_HALFTONE_BMP_THRESH_DOTS 283 #define CSTID_THRESHOLD_BMP_THRESH_DOTS 284 #define CSTID_INVALID_FILEVER_FOR_XBM 285 #define CSTID_FIELD_TOO_LONG_IN_OBJ_TRUNC 286 #define CSTID_FILE_LINE_BAD_FLD_IN_OBJ_STR 287 #define CSTID_MALFORMED_LINE_NUM_IN_FILE 288 #define CSTID_CACHING_PIXMAP 289 #define CSTID_FINISHED_CACHEING_PIXMAP 290 #define CSTID_NEW_XPM_SIZE_IS_W_X_H 291 #define CSTID_MANY_COLORS_GT_255_SKIP_XPM 292 #define CSTID_GIVEN_ADDTNL_COLOR_ALLOCATED 293 #define CSTID_INVALID_FILEVER_FOR_XPM 294 #define CSTID_COLOR_SUBS_FOR_UNRECOG_IN_XPM 295 #define CSTID_CONTEXT_MENU 296 #define CSTID_GEN_TEMPLATE_HTML_FILE_DOTS 297 #define CSTID_SCALING_EVERYTHING_PAGE 298 #define CSTID_SQUARE_BRACK_MODIFIED 299 #define CSTID_SQUARE_BRACK_MODIFIED_UNSAV 300 #define CSTID_SQUARE_BRACK_UNNAMED 301 #define CSTID_PARANED_EMPTY 302 #define CSTID_OPEN_FILE 303 #define CSTID_INC_GRID_SIZE 304 #define CSTID_DEC_GRID_SIZE 305 #define CSTID_GRID_MENU 306 #define CSTID_MOVE_EDIT_TEXT_BOX 307 #define CSTID_START_MOVE_EDIT_TEXT_BOX 308 #define CSTID_EDIT_ATTR_IN_EDITOR 309 #define CSTID_GET_NAMED_PROP_FROM_SEL_OBJ 310 #define CSTID_START_AN_EDGE_FROM_A_PORT 311 #define CSTID_ABORT 312 #define CSTID_START_A_WIRE_FROM_NAMED_PORT 313 #define CSTID_END_A_WIRE_AT_NAMED_PORT 314 #define CSTID_SET_SIGNAME_FOR_NAMED_PORT 315 #define CSTID_CLK_ON_PORT_TO_RENAME_SIGNAME 316 #define CSTID_CLK_ON_PORT_TO_CLEAR_SIGNAME 317 #define CSTID_PORTNAME_TOO_LONG_SKIPPED 318 #define CSTID_CLEAR_SIGNAME_FOR_NAMED_PORT 319 #define CSTID_EDIT_ATTR_GROUP_IN_EDITOR 320 #define CSTID_INVALID_FILEVER_FOR_LINK_JPEG 321 #define CSTID_NO_SUCH_FONT 322 #define CSTID_ACCEPT 323 #define CSTID_ADD_A_STRUCT_VERTEX 324 #define MAXCACHEDSTIDS 325 /* ===================== Non-cached ===================== */ #define MINNONCACHEDSTIDS 1000 #define STID_CANNOT_LOAD_FONTSET 1000 #define STID_CANNOT_LOAD_FONT 1001 #define STID_CANNOT_DISTRIBUTE_LOCKED_OBJS 1002 #define STID_VERTICES_HORI_APART 1003 #define STID_VERTICES_VERT_APART 1004 #define STID_LEFT_SIDES_APART 1005 #define STID_CENTERS_APART 1006 #define STID_RIGHT_SIDES_APART 1007 #define STID_SPACED_APART_HORI 1008 #define STID_TOP_SIDES_APART 1009 #define STID_MIDDLES_APART 1010 #define STID_BOTTOM_SIDES_APART 1011 #define STID_SPACED_APART_VERT 1012 #define STID_DISTR_VERTEX_HORI 1013 #define STID_DISTR_VERTEX_VERT 1014 #define STID_DISTR_VERTEX_VERT_AND_HORI 1015 #define STID_MOVE_ALL_VERTICES_YNC 1016 #define STID_CANNOT_ALIGN_OBJS_TOO_MANY 1017 #define STID_ALIGN_VERTICES_HORI_TO_GRID 1018 #define STID_ALIGN_VERTICES_VERT_TO_GRID 1019 #define STID_ALIGN_VERTICES_HORI 1020 #define STID_ALIGN_VERTICES_VERT 1021 #define STID_ALIGN_VERTICES_TO_GRID 1022 #define STID_ALIGN_VERTICES 1023 #define STID_SELECT_ONE_POLY_ONE_NON_POLY 1024 #define STID_CANNOT_MOVE_A_VERTEX_LOCKED 1025 #define STID_SELECT_ONLY_ONE_POLY 1026 #define STID_NO_ARC_CREATED 1027 #define STID_INVALID_ARC_VERSION 1028 #define STID_WARN_INCONSIST_ARC_DIR 1029 #define STID_ARC_SPEC 1030 #define STID_INVALID_ARC_SPEC_RADIUS 1031 #define STID_INVALID_ARC_SPEC_DIR 1032 #define STID_INVALID_ARC_SPEC_THETA1 1033 #define STID_SELECT_AT_LEAST_ONE_TEXT 1034 #define STID_MORE_THAN_ONE_NON_TEXT 1035 #define STID_NO_TEXT_SELECTED_ADD_ATTRS 1036 #define STID_NO_NON_TEXT_SELECTED 1037 #define STID_TEXT_ATTACHED 1038 #define STID_TEXT_UNLOCKED_AND_ATTACHED 1039 #define STID_UNEXPECTED_EOF_IN_ABORT_READ 1040 #define STID_STRING_LEN_EXCEEDS_AND_TRUNC 1041 #define STID_MOVE_ONE_ATTR_MOUSE_MSG 1042 #define STID_CANNOT_MOVE_ATTR_IF_LOCKED 1043 #define STID_SHOW_MOVE_ATTR 1044 #define STID_TOGGLE_NAME_SHOWN 1045 #define STID_HIDE_ATTR 1046 #define STID_CHANGE_ATTR_JUST_MOUSE_MSG 1047 #define STID_LEFT_JUSTIFY 1048 #define STID_CENTER_JUSTIFY 1049 #define STID_RIGHT_JUSTIFY 1050 #define STID_SELECT_ONLY_ONE_OBJ 1051 #define STID_SELECT_HAS_NO_ATTR 1052 #define STID_DRAG_LEFT_BTN_TO_SEE_ATTR 1053 #define STID_CHANGE_ATTR_JUST 1054 #define STID_IS_ATTR_OBSOLETE_FOR_ICON_YNC 1055 #define STID_BAD_FORMAT_IN_SHORTCUT_SPEC 1056 #define STID_CANNOT_FIND_NAMED_ATTR 1057 #define STID_ATTACH_FILE_ATTRS_IN_WB 1058 #define STID_CANNOT_ATTACH_NON_TEXT_OBJ 1059 #define STID_DETACH_FILE_ATTRS_IN_WB 1060 #define STID_FILE_CONTAINS_NO_ATTRS 1061 #define STID_SHOW_ATTR_NAME_AND_VALUE 1062 #define STID_SHOW_ATTR_VALUE_ONLY 1063 #define STID_NOT_SHOW_ATTR 1064 #define STID_SHOW_ATTR 1065 #define STID_WONT_SHOW_VALUE 1066 #define STID_TGIF_EDIT_ATTR_NAMES 1067 #define STID_EDIT_FILE_ATTRS_IN_WB 1068 #define STID_EDIT_FILE_ATTRS_DOTS 1069 #define STID_FILE_ATTRS_UPDATED 1070 #define STID_SELECT_ONE_OBJ_FOR_EDITATTRS 1071 #define STID_OBJ_CONTAINS_NO_ATTRS 1072 #define STID_EDIT_OBJ_ATTRS_DOTS 1073 #define STID_OBJ_ATTRS_UPDATED 1074 #define STID_INPUT_OCTAL_STR 1075 #define STID_INPUT_STR 1076 #define STID_WARN_PRINT_COURIER_IN_COLOR 1077 #define STID_MAY_CAUSE_ERROR_IN_PRINTOUT 1078 #define STID_BAD_OCTAL_STRING_ENCOUNTERED 1079 #define STID_SERVER_NOT_STARTED 1080 #define STID_INVISIBLE_COLOR_SELECTED_YNC 1081 #define STID_COLOR_IS_CURRENTLY_INVISIBLE 1082 #define STID_COLOR_SET_TO 1083 #define STID_TEXT_VSPACE_TOO_SMALL_RESET_0 1084 #define STID_FONT_AND_SIZE_NOT_AVAILABLE 1085 #define STID_LINE_WIDTH_SET_TO 1086 #define STID_LINE_TYPE_IS_STRAIGHT 1087 #define STID_LINE_TYPE_IS_SPLINE 1088 #define STID_LINE_TYPE_IS_INTSPLINE 1089 #define STID_TAB_FOR_FILE_COMPLETION 1090 #define STID_FAIL_TO_CREATE_WINDOW 1091 #define STID_FAIL_TO_CREATE_NAMED_WINDOW 1092 #define STID_UNDO_REDO_MAY_CAUSE_CRASH 1093 #define STID_UNDO_IN_WB 1094 #define STID_NO_COMMANDS_TO_UNDO 1095 #define STID_REDO_IN_WB 1096 #define STID_NO_COMMANDS_TO_REDO 1097 #define STID_SELECT_LIST_NOT_SORTED_IN 1098 #define STID_WARN_CANNOT_PARSE_NAMED_COLOR 1099 #define STID_CANNOT_ALLOC_NAMED_COLOR 1100 #define STID_CANNOT_BREAKUP_EPS 1101 #define STID_INVALID_FILE_IN_X_DEFAULT 1102 #define STID_INVALID_XDEF_COLORXPM_GET 1103 #define STID_INVALID_XDEF_COLORXPM_TRANS 1104 #define STID_FAIL_ALLOC_EDIT_TEXT_BGCOLOR 1105 #define STID_FAIL_ALLOC_EDIT_TEXT_HICOLOR 1106 #define STID_FAIL_ALLOC_DEF_BGCOLOR 1107 #define STID_INVALID_XDEF_USE_ALT_VALUE 1108 #define STID_NORM_VIDEO_MODE_ASSUMED 1109 #define STID_ZERO_COLORS_SPECIFIED 1110 #define STID_CANNOT_GET_X_DEFAULT 1111 #define STID_INVALID_XDEF_WILL_TRY_STR 1112 #define STID_FAIL_TO_ALLOC_3D_COLORS 1113 #define STID_FAIL_TO_ALLOC_COLOR_NUM 1114 #define STID_DEFCOLORINDEX_GE_MAXCOLORS 1115 #define STID_FAIL_ALLOC_NAMED_COLOR_ABORT 1116 #define STID_FAIL_ALLOC_COLOR_NUM_ABORT 1117 #define STID_UNEXPECTED_MAX_RGB_ZERO 1118 #define STID_FG_BG_SAME_COLOR_WARNING 1119 #define STID_CANNOT_SET_FG_COLOR 1120 #define STID_INVISIBLE_COLOR_SELECTED 1121 #define STID_ALL_COLOR_LAYERS_VISIBLE 1122 #define STID_ALL_COLOR_LAYERS_INVISIBLE 1123 #define STID_A_COLOR_LAYER_TURNED_ON 1124 #define STID_A_COLOR_LAYER_TURNED_OFF 1125 #define STID_TURN_COLOR_LAYER_NUM_ON 1126 #define STID_TURN_COLOR_LAYER_NUM_OFF 1127 #define STID_COLORMAP_NOT_RESETED 1128 #define STID_ADDCOLOR_FOR_BW_DPY 1129 #define STID_ENTER_COLORS_TO_ADD 1130 #define STID_FAIL_ALLOC_NAMED_COLOR 1131 #define STID_ENTER_EDIT_BG_COLOR 1132 #define STID_ENTER_EDIT_HILIGHT_COLOR 1133 #define STID_COLOR_LAYERS_ENABLED 1134 #define STID_COLOR_LAYERS_DISABLED 1135 #define STID_TOO_MANY_LINES_IN_COLORINFO 1136 #define STID_WAIT_FOR_START_CONV 1137 #define STID_NO_NAMED_SELECTION_OWNER 1138 #define STID_FAIL_TO_CHANGE_CONV_PROP 1139 #define STID_FAIL_TO_INTERN_NAMED_ATOM 1140 #define STID_FAIL_TO_CONNECT_TO_OWNER 1141 #define STID_FAIL_TO_GET_WIN_PROP 1142 #define STID_FAIL_TO_DISCONNECT_FROM_OWNER 1143 #define STID_LOCALE_IS 1144 #define STID_MODIFIER_IS 1145 #define STID_CANNOT_OPEN_XIM 1146 #define STID_OVERTHESPOT_CONV 1147 #define STID_ROOT_CONV 1148 #define STID_IM_NOT_SUPPORT_GIVEN_STYLE 1149 #define STID_FAIL_TO_CREATE_INPUTCONTEXT 1150 #define STID_OPEN_XIM 1151 #define STID_CLOSE_XIM 1152 #define STID_INVALID_XDEF_USE_ALT_STR 1153 #define STID_NO_OBJ_SELECTED_FOR_COPY 1154 #define STID_CANNOT_OPEN_FILE_FOR_WRITING 1155 #define STID_CANNOT_OPEN_FILE_FOR_READING 1156 #define STID_FAIL_TO_FSTAT_ABORT_COPY 1157 #define STID_ERR_READING_FILE_COPY_ABORT 1158 #define STID_COPY_FAILED_OBJ_MAYBE_TOO_BIG 1159 #define STID_COPY_BUFFER_UPDATED 1160 #define STID_ESC_KEY_PRESS_IGNORED 1161 #define STID_CUT_BUFFER_EMPTY 1162 #define STID_STR_EXCEEDS_NUM_CH_IGNORED 1163 #define STID_PASTE_FROM_NON_TGIF 1164 #define STID_ERR_WRITING_FILE_PASTE_ABORT 1165 #define STID_FILEVER_TOO_LARGE_PASTE_ABORT 1166 #define STID_CANNOT_PASTE_MIXED_TEXT 1167 #define STID_STR_BLOCKS_PASTED_FROM_TGIF 1168 #define STID_OBJS_PASTED_FROM_TGIF 1169 #define STID_SEL_A_FILE_TO_PASTE_DOTS 1170 #define STID_PASTING_REMOTE_FILE_NOT_SUP 1171 #define STID_NAMED_FILE_IS_EMPTY 1172 #define STID_CANNOT_MALLOC_NUM_BYTES 1173 #define STID_NO_PRIMARY_SELECTION_OWNER 1174 #define STID_CONVERTING_GIVEN_DOTS 1175 #define STID_TIMEOUT_CONVERT_GIVEN 1176 #define STID_PROBLEM_CONVERT_GIVEN 1177 #define STID_PASTE_COMP_TEXT_FROM_NON_TGIF 1178 #define STID_CANNOT_FIND_SIZE_USE_ALT 1179 #define STID_CANNOT_FIND_FONT_USE_ALT 1180 #define STID_CANNOT_PASTE_COMPOUND_OBJ 1181 #define STID_CUT_BUF_HAS_NON_ROT_COMP 1182 #define STID_NO_PROPERTY_TO_PASTE 1183 #define STID_NO_PROPERTY_TO_COPY 1184 #define STID_INVALID_KEY_IN_SEC_OF_INIFILE 1185 #define STID_ENTER_NAME_FOR_PROP_SET 1186 #define STID_PROP_SET_EXISTS_OVERWRITE_YNC 1187 #define STID_NO_PROP_TO_SAVE 1188 #define STID_WILL_COPY_NAMED_PROP 1189 #define STID_WILL_NOT_COPY_NAMED_PROP 1190 #define STID_WILL_SAVE_NAMED_PROP 1191 #define STID_WILL_NOT_SAVE_NAMED_PROP 1192 #define STID_WILL_PASTE_NAMED_PROP 1193 #define STID_WILL_NOT_PASTE_NAMED_PROP 1194 #define STID_WILL_RESTORE_NAMED_PROP 1195 #define STID_WILL_NOT_RESTORE_NAMED_PROP 1196 #define STID_TOOL_COPY_PROP 1197 #define STID_TOOL_SAVE_PROP 1198 #define STID_TOOL_PASTE_PROP 1199 #define STID_TOOL_RESTORE_PROP 1200 #define STID_SEL_ONLY_ONE_FOR_COPY_PROP 1201 #define STID_SEL_ONLY_ONE_FOR_SAVE_PROP 1202 #define STID_UNCHECK_PROP_FOR_COPY_DOTS 1203 #define STID_UNCHECK_PROP_FOR_SAVE_DOTS 1204 #define STID_UNCHECK_PROP_FOR_PASTE_DOTS 1205 #define STID_UNCHECK_PROP_FOR_RESTORE_DOTS 1206 #define STID_MALFORMED_CUT_BUF_WHILE_PASTE 1207 #define STID_NO_PROP_SETS_TO_RESTORE 1208 #define STID_SEL_A_PROP_SET_TO_RESTORE 1209 #define STID_TOOL_EDIT_INI_SECTION 1210 #define STID_BAD_VALUE_FOR_KEY 1211 #define STID_NOTHING_TO_EDIT_SEC_EMPTY 1212 #define STID_EDIT_VALUES_FOR_DOTS 1213 #define STID_TOOL_SEL_FROM_INI_SECTION 1214 #define STID_NOTHING_TO_SEL_SEC_EMPTY 1215 #define STID_SELECT_A_VALUE_FROM_SEC_DOTS 1216 #define STID_COPY_PROP_BEFORE_PASTE 1217 #define STID_INVALID_PARAM_PASSED_TO_FUNC 1218 #define STID_TOOL_INPUT 1219 #define STID_WARN_INVALID_NUMREDRAWBBOX 1220 #define STID_USER_INTR_ABORT_REPAINT 1221 #define STID_CANNOT_ALLOC_XPM_NO_ANIM 1222 #define STID_SCROLLING_CANCELED 1223 #define STID_CANNOT_ALLOC_PIXMAP_OF_SIZE 1224 #define STID_FORCING_END_ANIMATE 1225 #define STID_TOOL_NOT_FINISH_WITH_EXEC 1226 #define STID_NO_INTSPLINE_SELECTED 1227 #define STID_INTSPLINE_CONVERTED_TO_SPLINE 1228 #define STID_SELECT_ONLY_ONE_POLY_POLYGON 1229 #define STID_CANNOT_TOGGLE_FOR_INTSPLINE 1230 #define STID_BAD_POLY_IN_TOGGLE_SMOOTH 1231 #define STID_CLICK_LEFT_BUTTON_TO_TOGGLE 1232 #define STID_CLICK_OTHER_BUTTON_TO_QUIT 1233 #define STID_ONLY_TOGGLE_SMOOTH_IN_MODES 1234 #define STID_SMOOTHNESS_TOGGLED 1235 #define STID_BREAK_TEXT_CWL 1236 #define STID_BREAK_TEXT_CL 1237 #define STID_BREAK_TEXT_CW 1238 #define STID_INVALID_SPEC_ON_BREAK_TEXT 1239 #define STID_NO_TEXT_OBJ_TO_BREAK_UP 1240 #define STID_SOME_TEXT_NOT_BROKEN_UP_SIZE 1241 #define STID_TEXT_BROKEN_INTO_CHARS 1242 #define STID_CUR_TEXT_BG_SET_TO_NAMED 1243 #define STID_SOME_TEXT_BG_SET_TO_NAMED 1244 #define STID_SEL_ONE_POLYGON_TO_MAKE_REG 1245 #define STID_POLYGON_LOCKED 1246 #define STID_POLYGON_TOO_SMALL_FOR_REGULAR 1247 #define STID_VERTEX_AT_3_OCLOCK_YNC 1248 #define STID_CANNOT_DEL_PT_FOR_LOCKED 1249 #define STID_LEFT_BTN_TO_DEL_PTS 1250 #define STID_CANNOT_ADD_PT_FOR_LOCKED 1251 #define STID_CANNOT_ADD_PT_FOR_AUTO_ARROW 1252 #define STID_LEFT_BTN_TO_ADD_PTS 1253 #define STID_UNDO_BUF_AND_CMAP_FLUSHED 1254 #define STID_NUM_COLORS_ALLOCATED 1255 #define STID_UNDO_BUF_FLUSHED 1256 #define STID_SEL_ONE_XBM_OR_XPM_TO_RESTORE 1257 #define STID_CANNOT_RESTORE_LOCKED 1258 #define STID_SEL_ONE_XBM_OR_XPM_TO_CUT 1259 #define STID_CANNOT_CUT_LOCKED 1260 #define STID_CANNOT_CUT_TRANSFORMED_X_OBJ 1261 #define STID_SEL_ONE_XBM_OR_XPM_TO_BREAKUP 1262 #define STID_CANNOT_BREAK_XFORMED_X_OBJ 1263 #define STID_CANNOT_BREAKUP_LOCKED 1264 #define STID_ENTER_NUM_ROWCOL_TO_BREAK 1265 #define STID_INVALID_ROWCOL_SPEC_REENTER 1266 #define STID_ENTER_CONCAVE_OR_CONVEX 1267 #define STID_INVALID_SPEC 1268 #define STID_SEL_AN_ARC_OBJ 1269 #define STID_NO_ARC_OBJ_SELECTED 1270 #define STID_TOO_MANY_ARC_SEL_ONLY_ONE_ARC 1271 #define STID_NO_OTHER_OBJ_FOR_LAYOUTONARC 1272 #define STID_CANNOT_LAYOUTONARC_LOCKED 1273 #define STID_ARC_XFORMED_FOR_LAYOUTONARC 1274 #define STID_ROT_NOT_AVAIL_ON_VERTEX_MODE 1275 #define STID_ENTER_AN_ANGLE_IN_DEGREES 1276 #define STID_INVALID_SPEC_NUM_EXPECTED 1277 #define STID_SOME_GROUP_OBJ_NOT_MODIFIED 1278 #define STID_CANNOT_REM_XFORM_FOR_GROUPED 1279 #define STID_ENTER_EDIT_TEXT_SIZE 1280 #define STID_EDIT_TEXT_SIZE_OUT_OF_RANGE 1281 #define STID_ACTUAL_EDIT_TEXT_SIZE 1282 #define STID_USE_SPECIFIED_EDIT_TEXT_SIZE 1283 #define STID_CANNOT_FIND_NAMED_STRING 1284 #define STID_FIND_CMD_WRAPPED 1285 #define STID_ENTER_CASE_STR_TO_FIND 1286 #define STID_ENTER_NOCASE_STR_TO_FIND 1287 #define STID_NO_PREVIOUS_FIND 1288 #define STID_CANNOT_ABUT_IN_VERTEX_MODE 1289 #define STID_CANNOT_ABUT_LOCKED 1290 #define STID_ABUTTED_HORI 1291 #define STID_ABUTTED_VERT 1292 #define STID_ICONS_BROUGHT_UP_TO_DATE 1293 #define STID_SEL_AT_LEAST_TWO_OBJS 1294 #define STID_CANNOT_SIZE_OF_GIVEN_WIDTH 1295 #define STID_CANNOT_SIZE_OF_GIVEN_HEIGHT 1296 #define STID_SPECIFY_WIDTH_HEIGHT 1297 #define STID_SPECIFY_WIDTH 1298 #define STID_SPECIFY_HEIGHT 1299 #define STID_NAMED_XDEF_IS_OBSOLETE 1300 #define STID_GIVEN_BPS_PREVIEW_NOT_SUP 1301 #define STID_INVALID_PREVIEW_BMP_IN_EPS 1302 #define STID_FAIL_TO_WRITE_TO_STDOUT 1303 #define STID_FAIL_TO_PARSE_WINEPS_FILE 1304 #define STID_INVALID_PREVIEW_BOX_IN_EPS 1305 #define STID_CANNOT_BBOX_IN_GIVEN_FILE 1306 #define STID_CANNOT_CONVERT_WINEPS_PREVIEW 1307 #define STID_CANNOT_OPEN_EPS_FILE_FOR_READ 1308 #define STID_EPS_OBJ_SKIPPED_FOR_PRINT 1309 #define STID_EPS_FILE_NEWER_THAN_EPS_OBJ 1310 #define STID_NO_TOP_LEVEL_EPS_SELECTED 1311 #define STID_CANNOT_IMPORT_GIVEN_EPS 1312 #define STID_EPS_OBJECT_UPDATED 1313 #define STID_CANNOT_EVAL_INVALID_OP_TYPE 1314 #define STID_DIVIDE_BY_ZERO_FOR_OP_TYPE 1315 #define STID_ILLEGAL_EXPR_INVALID_OP_CODE 1316 #define STID_ILLEGAL_EXPR_EMPTY_OP_STACK 1317 #define STID_ILLEGAL_EXPR_BAD_NUM_VALUE 1318 #define STID_ILLEGAL_EXPR_BAD_STR_VALUE 1319 #define STID_ILLEGAL_EXPR_BAD_IDENTIFIER 1320 #define STID_ILLEGAL_EXPR_BAD_OPERATOR 1321 #define STID_ILLEGAL_EXPR_TOO_MANY_SYMBOL 1322 #define STID_ILL_EXPR_OP_STACK_NON_EMPTY 1323 #define STID_ILL_EXPR_VAL_STACK_NON_EMPTY 1324 #define STID_ILL_EXPR_TOO_MANY_VALS_LEFT 1325 #define STID_CANNOT_OPEN_FOR_READ_PRINT 1326 #define STID_CANNOT_OPEN_FOR_WRITE_PRINT 1327 #define STID_CANNOT_FIND_CMD_EXEC 1328 #define STID_CANNOT_FIND_CMD_IN_PATH_EXEC 1329 #define STID_CANT_FIND_CMD_MSG_EXEC 1330 #define STID_CANT_FIND_CMD_INPATH_MSG_EXEC 1331 #define STID_FILE_EXISTS_OK_OVERWRITE_YNC 1332 #define STID_ONE_PAGE_SYM_ABORT_SAVE 1333 #define STID_ONE_PAGE_PIN_ABORT_SAVE 1334 #define STID_TOO_MANY_SYM_ABORT_SAVE 1335 #define STID_CANT_OPEN_WRITE_FILE_NOT_SAVE 1336 #define STID_SAVE_TMP_FILE_DOTS 1337 #define STID_TMP_FILE_SAVED 1338 #define STID_CANNOT_CHMOD 1339 #define STID_WORKING_DIRECTORY_IS 1340 #define STID_ENTER_NEW_FNAME_ACCEPT_CANCEL 1341 #define STID_CANT_SAVE_SYM_NO_SYM_FOUND 1342 #define STID_CANT_SAVE_PIN_NO_SYM_FOUND 1343 #define STID_CANT_SAVE_OJB_ONE_SYM_FOUND 1344 #define STID_CANT_SAVE_SYM_SAVE_AS_PIN 1345 #define STID_CANT_SAVE_PIN_ONE_SYM_FOUND 1346 #define STID_CANT_SAVE_OJB_TWO_SYM_FOUND 1347 #define STID_CANT_SAVE_SYM_TWO_SYM_FOUND 1348 #define STID_CANT_FIND_TYPE_ATTR_NOT_SAVED 1349 #define STID_SYM_TYPE_WRONG_PIN_NOT_SAVED 1350 #define STID_NO_FILE_NAME_FILE_NOT_SAVED 1351 #define STID_SAVING_DOTS 1352 #define STID_PROBLEM_ZIPPING_PLEASE_SAVE 1353 #define STID_FILE_SAVED 1354 #define STID_FILE_NOT_SAVED 1355 #define STID_NO_SYM_FOUND_SYM_NOT_SAVED 1356 #define STID_ENTER_NEW_FILE_NAME 1357 #define STID_CANT_FIND_DOT_IN_SAVEFILE 1358 #define STID_NO_SYM_FOUND_PIN_NOT_SAVED 1359 #define STID_SYM_TYPE_IS_SHOULD_SAVE_PIN 1360 #define STID_TOO_MANY_SYM_FILE_NOT_SAVED 1361 #define STID_BAD_FIELD_IN_FUNC_ABORT_READ 1362 #define STID_UNRECOG_PAGE_STYLE 1363 #define STID_PORTRAIT_STYLE_ASSUMED 1364 #define STID_CANT_FIND_COLOR_NUM_USE_CUR 1365 #define STID_LINEWIDTH_IDX_RANGE_SET_TO_0 1366 #define STID_BAD_FIELD_IN_OBJ_ABORT_READ 1367 #define STID_BAD_INPUT_WHILE_READ_PAGE 1368 #define STID_BAD_PAGE_FILE_NAME_TRUNC_TO 1369 #define STID_CUR_COLOR_CORRECTED_TO_BE 1370 #define STID_FAIL_ALLOC_BGCOLOR_USE_DEF 1371 #define STID_ONLY_PAGE_1_IMPORTED 1372 #define STID_ONLY_GIVEN_PAGE_IMPORTED 1373 #define STID_INVALID_REMOTE_FNAME 1374 #define STID_CANNOT_READ_TMP_FILE 1375 #define STID_CANNOT_IMPORT_FILE 1376 #define STID_INVALID_PAGE_NUM 1377 #define STID_USER_INTR_ABORT_DRAW 1378 #define STID_FILE_VER_ABORT_IMPORT 1379 #define STID_FILE_CORRUPTED_ABORT_IMPORT 1380 #define STID_FILE_IMPORTED 1381 #define STID_SEL_AN_OBJ_FILE_TO_IMPORT 1382 #define STID_CANNOT_ALLOC_BGCOLOR_USE_DEF 1383 #define STID_CANNOT_ALLOC_FGCOLOR_USE_DEF 1384 #define STID_CANNOT_SET_BGXPM_TO 1385 #define STID_COLORMAP_FLUSHED 1386 #define STID_FILE_VER_ABORT_OPEN 1387 #define STID_FILE_CORRUPTED_ABORT_OPEN 1388 #define STID_POP_BACK_TO_NAMED 1389 #define STID_WARN_PS_BBOX_EMPTY 1390 #define STID_TIFFEPSI_DIRECTLY_SUPPORTED 1391 #define STID_INVALID_XDEF 1392 #define STID_FAIL_EXEC_PROG_EPSI_NOT_GEN 1393 #define STID_FAIL_GET_FINFO_EPSI_NOT_GEN 1394 #define STID_CANNOT_OPEN_FILE_FOR_APPEND 1395 #define STID_CANNOT_PRINT_REMOTE_FILE 1396 #define STID_NO_OBJ_TO_PRINT_ON_PAGE 1397 #define STID_NO_OBJ_TO_PRINT 1398 #define STID_NO_CUR_FILE_CANNOT_GEN_FORMAT 1399 #define STID_GENERATING_PRINT_FILE_DOTS 1400 #define STID_NO_OBJ_TO_EXPORT 1401 #define STID_WRITING_TO_DOTS 1402 #define STID_GENERATING_PREVIEW_BITMAP 1403 #define STID_OUTPUT_TRUNC_IN_PRINT_TILED 1404 #define STID_RECOMMEND_REDUCING_SETTING 1405 #define STID_PRINTING_WITH_GIVEN_CMD 1406 #define STID_CANNOT_EXEC_ABORT_PRINT 1407 #define STID_NAMED_FILE_PRINTED 1408 #define STID_PRINT_COMPLETED 1409 #define STID_PRINTING_INTO_NAMED_FILE 1410 #define STID_GENERATING_TIFF_PREVIEW_BMP 1411 #define STID_FORMAT_FILE_NOT_GENERATED 1412 #define STID_CONVERTING_INTO_NAMED_FILE 1413 #define STID_CANNOT_EXEC_FORMAT_NOT_GEN 1414 #define STID_FORMAT_FILE_PRINTED_INTO 1415 #define STID_NO_CUR_FILE_CANNOT_GEN_TEXT 1416 #define STID_TEXT_OUTPUT_NOT_GEN 1417 #define STID_TEXT_PRINTED_INTO_NAMED_FILE 1418 #define STID_TOO_MANY_COLOR_FOR_XPM_EXPORT 1419 #define STID_CANNOT_PRINT_EPS_TILED_PAGE 1420 #define STID_PREPROCESS_PAGE_OF 1421 #define STID_GENERATING_PAGE_OF 1422 #define STID_GIVEN_PAGE_NOT_GENERATED 1423 #define STID_PAGE_RANGE_NOT_GENERATED 1424 #define STID_PRINTWITHCMD_WORKS_PRINTER 1425 #define STID_ENTER_PRINT_CMD_NAME 1426 #define STID_NO_OBJ_SEL_NOTHING_TO_PRINT 1427 #define STID_SPECIFY_PERCENT_REDUCTION 1428 #define STID_INVALID_REDUCTION 1429 #define STID_NEW_REDUCTION_IS_PERCENT 1430 #define STID_NEW_ENLARGEMENT_IS_PERCENT 1431 #define STID_OK_TO_CLEAR_WHITEBOARD 1432 #define STID_FILE_MOD_SAVE_BEFORE_CLEAR 1433 #define STID_EDITING_NO_FILE 1434 #define STID_OPEN_IN_WB 1435 #define STID_FILE_MOD_SAVE_BEFORE_OPEN 1436 #define STID_SELECT_A_FILE_TO_OPEN 1437 #define STID_INVALID_PAGE_SPECIFIED_FOR 1438 #define STID_SETTEMPLATE_IN_WB 1439 #define STID_SELECT_FILE_AS_TEMPLATE 1440 #define STID_NOT_SUP_REMOTE_TEMPLATE_FILE 1441 #define STID_CANNOT_OPEN_STILL_TEMPLATE 1442 #define STID_STILL_USE_AS_TEMPLATE 1443 #define STID_TEMPLATE_SET_TO 1444 #define STID_FILE_MOD_SAVE_BEFORE_QUIT 1445 #define STID_ANCESTER_MOD_STILL_QUIT 1446 #define STID_ILLEGAL_DOUBLE_BYTE_TRUNC 1447 #define STID_TOOL_CANT_HANDLE_DB_FONT 1448 #define STID_FAIL_LOAD_FONT_FONT_SUBS 1449 #define STID_FONT_SUBSTITUTED 1450 #define STID_CANNOT_GET_IMAGE_OF_SIZE 1451 #define STID_UNRECOG_CHARCODE_DISCARD 1452 #define STID_CANT_FIND_FONT_USE_ALT 1453 #define STID_BAD_XDEF_CANT_FIND_EQ_SKIP 1454 #define STID_BAD_XDEF_MISS_FONT_NAME_SKIP 1455 #define STID_MISS_FONT_SPEC_IN_XDEF 1456 #define STID_INVALID_X_FONT_INFO_IN_XDEF 1457 #define STID_INVALID_X_REG_INFO_IN_XDEF 1458 #define STID_INVALID_PS_INFO_IN_XDEF 1459 #define STID_ERR_PROCESS_FONT_USE_ALT 1460 #define STID_INVALID_SB_FONT_USE_DB_FONT 1461 #define STID_ERR_PROCESS_SIZE_USE_DEF_SIZE 1462 #define STID_OBSOLETE_XDEF_USE_ALT 1463 #define STID_CANT_OPEN_DEF_MSG_FONT_ABORT 1464 #define STID_WARN_VERY_SMALL_DEF_FONT 1465 #define STID_CANT_OPEN_RULER_FONT_ABORT 1466 #define STID_WARN_VERY_SMALL_RULER_FONT 1467 #define STID_CANNOT_SET_INITIAL_FONT_TO 1468 #define STID_CANT_SET_INIT_FONTSTYLE_ALT 1469 #define STID_CANT_SET_INIT_FONTJUST_ALT 1470 #define STID_CANT_SET_INIT_FONTSIZE_ALT 1471 #define STID_FONT_NOT_AVAILABLE 1472 #define STID_CANT_CHANGE_SIZEPT_TO_USE_ALT 1473 #define STID_CANT_CHANGE_SIZE_TO_USE_ALT 1474 #define STID_INVALID_VSPACE_NOT_CHANGED 1475 #define STID_VSPACE_TOO_SMALL_NOT_CHANGED 1476 #define STID_ENTER_POINT_SIZE 1477 #define STID_ENTER_FONT_SIZE 1478 #define STID_FONT_SIZE_TOO_SMALL 1479 #define STID_FONT_SUB_NO_SUCH_FONT_USR_DEF 1480 #define STID_NO_KANJI_FONT_GIVEN_NUMBER 1481 #define STID_FAIL_TO_CONN_TO_HOST 1482 #define STID_NETWORK_READ_ERROR 1483 #define STID_NETWORK_ERROR 1484 #define STID_CONN_ABORT_BY_USER 1485 #define STID_CONN_TERM_BY_SERVER 1486 #define STID_FAIL_TO_OPEN_DATA_SOCKET 1487 #define STID_USING_METRIC_SYSTEM 1488 #define STID_USING_ENGLISH_SYSTEM 1489 #define STID_SNAP_NOT_ON_GRID_SZ_SAME 1490 #define STID_AT_MAX_GRID_GRID_SZ_SAME 1491 #define STID_AT_MIN_GRID_GRID_SZ_SAME 1492 #define STID_SNAP_TO_GRID_ACTV 1493 #define STID_SNAP_TO_GRID_DISABLED 1494 #define STID_WILL_PRINT_IN_COLOR 1495 #define STID_WILL_PRINT_IN_BW 1496 #define STID_CONSTRAINED_MOVE 1497 #define STID_UNCONSTRAINED_MOVE 1498 #define STID_WILL_DISPLAY_XBM_XPM 1499 #define STID_WILL_NOT_DISPLAY_XBM_XPM 1500 #define STID_GRAY_SCALE_IN_BW_PRINTING 1501 #define STID_NO_GRAY_SCALE_IN_BW_PRINTING 1502 #define STID_CURRENT_SPEC_IS 1503 #define STID_ENTER_MEASURE_UNIT_SPEC 1504 #define STID_WILL_EXPORT_FORMAT_FILE 1505 #define STID_PRINT_DEV_SET_TO_PRINTER 1506 #define STID_WILL_EXPORT_EPS_FILE 1507 #define STID_WILL_EXPORT_RAW_PS_FILE 1508 #define STID_WILL_EXPORT_XPM_FILE 1509 #define STID_WILL_EXPORT_XBM_FILE 1510 #define STID_WILL_EXPORT_TEXT_FILE 1511 #define STID_WILL_EXPORT_EPSI_FILE 1512 #define STID_WILL_EXPORT_GIF_FILE 1513 #define STID_WILL_EXPORT_HTML_FILE 1514 #define STID_WILL_EXPORT_PDF_FILE 1515 #define STID_WILL_EXPORT_TIFFEPSI_FILE 1516 #define STID_ONE_MOTION_SEL_MOVE_MODE 1517 #define STID_CLICK_SEL_CLICK_MOVE_MODE 1518 #define STID_CANT_TOGGLE_COLOR_LAYER_BW 1519 #define STID_STRETCHABLE_TEXT_MODE 1520 #define STID_NON_STRETCHABLE_TEXT_MODE 1521 #define STID_TRANS_PAT_MODE 1522 #define STID_NON_TRANS_PAT_MODE 1523 #define STID_ALREADY_AT_DEF_ZOOM 1524 #define STID_ALREADY_AT_HIGHEST_MAG 1525 #define STID_CURSOR_IGNORED_CSBTN1 1526 #define STID_ZOOMIN_AROUND_EDIT_TEXT 1527 #define STID_SEL_ZOOM_CENTER 1528 #define STID_ZOOMIN_CANCEL_BY_USER 1529 #define STID_AT_PAPER_EDGE_CANT_ZOOMOUT 1530 #define STID_PAGE_STYLE_CHANGE_TO_LAND 1531 #define STID_PAGE_STYLE_CHANGE_TO_PORT 1532 #define STID_WARN_PIN_NOT_SUPPORTED 1533 #define STID_ONE_SIMPLE_GROUP_UNGROUP_ANY 1534 #define STID_ALL_SIMPLE_GROUP_UNGROUP_ANY 1535 #define STID_SEL_OBJ_ARE_UNGROUPED 1536 #define STID_NO_OBJ_TO_LOCK 1537 #define STID_CANNOT_LOCK_IN_VERTEX_MODE 1538 #define STID_SEL_OBJ_ARE_LOCKED 1539 #define STID_NO_OBJ_TO_UNLOCK 1540 #define STID_CANNOT_UNLOCK_IN_VERTEX_MODE 1541 #define STID_SEL_OBJ_ARE_UNLOCKED 1542 #define STID_TOOL_VERSION 1543 #define STID_TOOL_VERSION_SPC_BUILD 1544 #define STID_TOOL_VERSION_PATCH 1545 #define STID_TOOL_VERSION_PATCH_SPC_BUILD 1546 #define STID_HYPER_TEXT_HOME 1547 #define STID_LATEST_REL_INFO 1548 #define STID_HYPER_GRAPHICS_INFO 1549 #define STID_MAILING_LIST_INFO 1550 #define STID_SEND_BUG_REPORT_TO 1551 #define STID_OPEN_URL_FAIL_USE_BROWSER 1552 #define STID_FIND_VER_FAIL_USE_BROWSER 1553 #define STID_TOOL_CUR_VER_IS_DIFF_INFO 1554 #define STID_TOOL_CUR_VER_IS_DIFF_SPC_INFO 1555 #define STID_TOOL_CUR_VER_PATCH_INFO 1556 #define STID_TOOL_CUR_VER_PATCH_SPC_INFO 1557 #define STID_CANT_DOWNLOAD_VER_USE_BROWSER 1558 #define STID_FAIL_TO_CONN_TO_HOST_PORT 1559 #define STID_LINES_TOO_LONG_CONTENT_LENGTH 1560 #define STID_FAIL_TO_SEND_REQ 1561 #define STID_INVALID_FORMAT_IN_HEADER 1562 #define STID_CHECK_FONT_FAILED_FOR_BROWSE 1563 #define STID_ERROR_ENCOUNTERED_WHILE_RECV 1564 #define STID_SINGLE_XPM_IMGPROC 1565 #define STID_USER_INTR 1566 #define STID_CANNOT_IMPORT_XPM_FILE 1567 #define STID_MAY_USED_UP_COLORS_RETRY 1568 #define STID_ENTER_PAIR_COLORS_INTERPOLATE 1569 #define STID_GIVEN_IS_NOT_A_VALID_COLOR 1570 #define STID_ENTER_VAL_MINUS_PLUS_ONE_BW 1571 #define STID_FAIL_TO_PARSE_FOR_A_VAL 1572 #define STID_ENTER_VAL_MINUS_PLUS_ONE_SAT 1573 #define STID_ENTER_VAL_FOR_CHANGE_HUE 1574 #define STID_FAIL_TO_PARSE_FOR_4_VAL 1575 #define STID_ENTER_VAL_FOR_CONTRAST_ENH 1576 #define STID_GIVEN_NEG_VAL_NOT_ALLOWED 1577 #define STID_ENTER_VAL_FOR_COLOR_BAL 1578 #define STID_FAIL_TO_PARSE_FOR_3_VAL 1579 #define STID_ENTER_VAL_FOR_GAMMA 1580 #define STID_SEL_TOO_THIN_FLAT_FOR_EDGE 1581 #define STID_SEL_TOO_THIN_FLAT_FOR_EMBOSS 1582 #define STID_ENTER_NUM_COLORS_TO_REDUCE_TO 1583 #define STID_NUM_COLORS_BETWEEN_2_N_GIVEN 1584 #define STID_SEL_XPM_FILE_FOR_RED_COLORS 1585 #define STID_INVALID_GIVEN_XPM_FILE 1586 #define STID_Q_FS_ERROR_DIFFUSE 1587 #define STID_ENTER_NUM_BITS_IN_RGB 1588 #define STID_RGB_LEVELS_CHANGED_TO 1589 #define STID_BAD_VAL_SUM_RGB_LEVEL 1590 #define STID_BAD_VAL_GT_0_RGB_LEVEL 1591 #define STID_RGB_LEVELS_ARE 1592 #define STID_ENTER_INT_AMT_TO_SPREAD 1593 #define STID_SEL_TOO_THIN_FLAT_FOR_SHARPEN 1594 #define STID_SEL_TOO_THIN_FLAT_FOR_BLUR 1595 #define STID_IMAGE_PROC_CANT_USE_XFORMED 1596 #define STID_SEL_3_XPM_FOR_IMAGEPROC_CMD 1597 #define STID_SEL_2_XPM_FOR_IMAGEPROC_CMD 1598 #define STID_PICK_PT_WITHIN_IMAGE_BOUND 1599 #define STID_IMG_TOO_SMALL_IMAGEPROC_CMD 1600 #define STID_NO_WARPING 1601 #define STID_START_LINE_SEG_DOTS 1602 #define STID_ENDT_LINE_SEG_DOTS 1603 #define STID_ENTER_IMAGE_SIZE_IN_PIX_RC 1604 #define STID_FAIL_TO_EXECUTE_CMD 1605 #define STID_ENTER_CMD_OP_FOR_BGGEN 1606 #define STID_NEW_XPM_WH_GENERATED 1607 #define STID_ENTER_GRAY_LEVELS_222 1608 #define STID_INVALID_GIVEN_VALUE_ENTERED 1609 #define STID_ENTER_COLOR_FOR_RECT_BGGEN 1610 #define STID_CANNOT_PARSE_NAMED_COLOR 1611 #define STID_XPM_NOT_XFORMED_REGEN_ANYWAY 1612 #define STID_DRAG_A_RECT_TO_CROP 1613 #define STID_START_CROP_IMAGE 1614 #define STID_END_CROP_IMAGE 1615 #define STID_ABORT_CROP_IMAGE 1616 #define STID_SELECT_A_COLOR 1617 #define STID_SEL_A_COLOR_TO_USE_AS_CUR 1618 #define STID_SEL_AREA_NOT_INTERSECT_IMAGE 1619 #define STID_SEL_PT_NOT_ON_IMAGE 1620 #define STID_ONE_PRIM_FOR_IMAGEPROC_CMD 1621 #define STID_DARG_TO_FILL_AN_AREA 1622 #define STID_SEL_A_COLOR_TO_BE_REPLACED 1623 #define STID_SEL_A_COLOR_TO_REPLACE 1624 #define STID_BTN1_FLOODFILL_BTN3_SET_COLOR 1625 #define STID_ESC_TO_FINISH 1626 #define STID_FLOOD_FILL 1627 #define STID_SET_A_PIXEL 1628 #define STID_NO_CONTOUR_CAN_BE_GEN_HERE 1629 #define STID_SEL_A_COLOR_TO_BE_TRACED 1630 #define STID_START_CONTOUR 1631 #define STID_INVALID_XDEF_RNG_USE_ALT_VAL 1632 #define STID_VAL_TOO_LARGE_IN_XDEF_USE_ALT 1633 #define STID_VAL_TOO_SMALL_IN_XDEF_USE_ALT 1634 #define STID_INVALID_GIVEN_PATH_MUST_FULL 1635 #define STID_CANNOT_SET_LOCALE_ENV_VARS 1636 #define STID_XT_CANNOT_SET_LOCALE_ENV_VARS 1637 #define STID_XLIB_CANT_SET_LOCALE_ENV_VARS 1638 #define STID_CANT_SET_LOCALE_MODIFIERS 1639 #define STID_LOCALE_DIR_NOT_EXIST_USE_XDEF 1640 #define STID_WARN_CANT_PUTENV_GIVEN 1641 #define STID_CANT_OPEN_DISPLAY_ABORT 1642 #define STID_CANT_OPEN_GIVEN_DPY_ABORT 1643 #define STID_CUR_EMPTY_FILE_IS 1644 #define STID_LEFT_STEP_MID_RUN_RIGHT_STOP 1645 #define STID_CANT_FIND_POLY_WITH_GIVEN_ID 1646 #define STID_CANT_FIND_OBJ_WITH_GIVEN_ID 1647 #define STID_CANT_FIND_ATTR_NAME_AND_COLOR 1648 #define STID_BAD_FLTR_SPEC_DEF 1649 #define STID_BAD_FLTR_SPEC_MISS_PERC_S 1650 #define STID_BAD_FLTR_SPEC_MANY_PERC_S 1651 #define STID_BAD_XDEF_MUST_BE_GT_0 1652 #define STID_CANT_FIND_XDEF_CONT_LOOK_FLTR 1653 #define STID_SEL_XBM_FILE_TO_IMPORT 1654 #define STID_CANNOT_IMPORT_XBM_FILE 1655 #define STID_ENTER_GEOM_SPEC_ORIG_SIZE 1656 #define STID_GIVEN_XBM_SIZE_FILE_IMPORTED 1657 #define STID_GIVEN_XPM_SIZE_FILE_IMPORTED 1658 #define STID_SEL_XPM_FILE_TO_IMPORT 1659 #define STID_SEL_EPS_FILE_TO_IMPORT 1660 #define STID_IMPORT_REM_FILE_EMBED_INSTEAD 1661 #define STID_GIVEN_EPS_FILE_IMPORTED 1662 #define STID_SEL_GIF_FILE_TO_IMPORT 1663 #define STID_CANNOT_IMPORT_GIVEN_GIF 1664 #define STID_GIVEN_GIF_SIZE_FILE_IMPORTED 1665 #define STID_CANT_FIND_ANY_IMP_FLTR_SPEC 1666 #define STID_SEL_AN_IMPORT_FILTER 1667 #define STID_SEL_A_TYPE_FILE_TO_IMPORT 1668 #define STID_CANT_IMPORT_GIVEN_TYPE_FILE 1669 #define STID_GIVEN_TYPE_SIZE_FILE_IMPORTED 1670 #define STID_INVALID_FMT_IN_SHORTCUT_SPEC 1671 #define STID_CANT_FIND_NAMED_IMP_FLTR 1672 #define STID_SEL_ANIM_GIF_FILE_TO_IMPORT 1673 #define STID_CANT_EXEC_CMD_IMPORT_ANIM_GIF 1674 #define STID_Q_LIKE_TO_USE_AN_IMP_FLTR_GIF 1675 #define STID_CANT_CREATE_NAMED_TMP_FILE 1676 #define STID_CANT_IMP_ANIM_GIF_TMP_DIR 1677 #define STID_CANT_IMP_GIVEN_ANIM_GIF 1678 #define STID_ONLY_ONE_GIF_COMP_EXTRACTED 1679 #define STID_ANIMATING_GIVEN 1680 #define STID_GIF_ANIMATION_STOPPED 1681 #define STID_PRESS_ESC_TO_STOP 1682 #define STID_BROWSING_DIR_FOR_TYPE_FILES 1683 #define STID_SKIP_GIVEN_FILE_SYM_LINK 1684 #define STID_WORKING_DIR_IS_GIVEN 1685 #define STID_MORE_THAN_ONE_CMAP_INSTALLED 1686 #define STID_FIRST_ONE_ON_LIST_USED 1687 #define STID_SPECIFY_AREA 1688 #define STID_SPECIFY_DELAY_FULL_SCR_CAP 1689 #define STID_WILL_HIDE_TOOL_WHILE_CAPTURE 1690 #define STID_WILL_SHOW_TOOL_WHILE_CAPTURE 1691 #define STID_FUNC_SELECT_SYS_CALL_FAILED 1692 #define STID_FUNC_INVALID_RC_FOR_SELECT 1693 #define STID_CNTRL_C_ABORT_LAUNCH 1694 #define STID_CMD_ABORT_LAUNCH_CLOSE_TOOL 1695 #define STID_INVALID_GIVEN_ATTR_SPEC 1696 #define STID_LAUNCH_NOT_AUTO_IN_HYPER_EXEC 1697 #define STID_USER_ABORT_LAUNCH_IN_HYPER 1698 #define STID_MALFORMED_CMD_EXEC_ABORT 1699 #define STID_NO_OBJ_SEL_WHILE_EXEC_CMD 1700 #define STID_CANT_FIND_NAMED_ATTR_EXEC 1701 #define STID_FILE_ATTR_NOT_ALLOWED_FOR_CMD 1702 #define STID_CANT_FIND_NAMED_OBJ_EXEC 1703 #define STID_INVALID_ARG_WHILE_EXEC_CMD 1704 #define STID_MODIFY_FILE_ATTR_IN_WB 1705 #define STID_USER_INTR_TOOL_WAIT_CLEANUP 1706 #define STID_FUNC_USER_INTR 1707 #define STID_BAD_EVAL_INT_EXP_EXEC_CMD 1708 #define STID_BAD_EVAL_FLOAT_EXP_EXEC_CMD 1709 #define STID_FAIL_FUNC_CMD_EXEC_ABORT 1710 #define STID_FUNC_ONLY_WORK_COMPOSITE_OBJ 1711 #define STID_FUNC_FAIL_TO_IMPORT_GIVEN 1712 #define STID_FUNC_OBJ_NON_XBM_XPM_SUB_OBJS 1713 #define STID_WILL_EXPORT_PNG_FILE 1714 #define STID_CANNOT_IMPORT_GIVEN_PNG 1715 #define STID_GIVEN_PNG_SIZE_FILE_IMPORTED 1716 #define STID_SEL_PNG_FILE_TO_IMPORT 1717 #define STID_FUNC_DIFF_SZ_XBM_XPM_SUBOBJS 1718 #define STID_FUNC_MORE_1_XBM_XPM_SUBOBJS 1719 #define STID_FUNC_ARG_RANGE 1720 #define STID_FUNC_UNDEFINED_ARG 1721 #define STID_INTERNAL_CMD_SELECT_FAILED 1722 #define STID_CANT_OPEN_FILE_READ_EXEC_CMD 1723 #define STID_FAIL_TO_EXECUTE_CMD_EXEC_CMD 1724 #define STID_UNEXP_ERR_EXEC_CMD_ABORT 1725 #define STID_BAD_NAME_TOP_LEVEL_ONLY_CMD 1726 #define STID_BAD_CURSOR_WHILE_EXEC_CMD 1727 #define STID_BAD_COLOR_NAME_WHILE_EXEC_CMD 1728 #define STID_WIDTH_RANGE_WHILE_EXEC_CMD 1729 #define STID_SPLINE_TYPE_WHILE_EXEC_CMD 1730 #define STID_ARROW_STYLE_WHILE_EXEC_CMD 1731 #define STID_DASH_INDEX_WHILE_EXEC_CMD 1732 #define STID_RCB_RAD_RANGE_WHILE_EXEC_CMD 1733 #define STID_BAD_TEXT_JUST_WHILE_EXEC_CMD 1734 #define STID_BAD_FONT_NAME_WHILE_EXEC_CMD 1735 #define STID_UNDO_BUF_FLUSHED_BY_CMD 1736 #define STID_BAD_EVAL_NUM_EXP_EXEC_CMD 1737 #define STID_WRITE_CUT_BUF_WHILE_EXEC_CMD 1738 #define STID_CANT_FIND_DOT_WHILE_EXEC_CMD 1739 #define STID_BAD_WIDTH_WHILE_EXEC_CMD 1740 #define STID_BAD_HEIGHT_WHILE_EXEC_CMD 1741 #define STID_BAD_STYLE_WHILE_EXEC_CMD 1742 #define STID_TOO_MANY_OBJ_WHILE_EXEC_CMD 1743 #define STID_BAD_ATTR_NAME_WHILE_EXEC_CMD 1744 #define STID_END_AN_EDGE_AT_A_PORT 1745 #define STID_DRAW_AN_EDGE_BETWEEN_PORTS 1746 #define STID_CANT_FIND_VRTX_WHILE_EXEC_CMD 1747 #define STID_POLY_NOR_PGON_WHILE_EXEC_CMD 1748 #define STID_BAD_REM_FNAME_WHILE_EXEC_CMD 1749 #define STID_CANT_OPEN_FILE_WRITE_EXEC_CMD 1750 #define STID_GIVEN_CMD_EXECUTED 1751 #define STID_SQRT_NEG_NUM_WHILE_EXEC_CMD 1752 #define STID_CMD_NOT_AVAIL_ON_PLATFORM 1753 #define STID_BAD_SHORTCUT_WHILE_EXEC_CMD 1754 #define STID_STAT_FAILED_WHILE_EXEC_CMD 1755 #define STID_NON_GROUPED_WHILE_EXEC_CMD 1756 #define STID_BAD_SEP_LONG_WHILE_EXEC_CMD 1757 #define STID_BAD_SEP_WHILE_EXEC_CMD 1758 #define STID_MORE_THAN_ONE_WHILE_EXEC_CMD 1759 #define STID_MUST_FULL_PATH_WHILE_EXEC_CMD 1760 #define STID_OBJ_ALRDY_SEL_WHILE_EXEC_CMD 1761 #define STID_INVALID_FNAME_WHILE_EXEC_CMD 1762 #define STID_INVALID_FMODE_WHILE_EXEC_CMD 1763 #define STID_INVALID_FNUM_WHILE_EXEC_CMD 1764 #define STID_FNUM_ARDY_OPEN_WHILE_EXEC_CMD 1765 #define STID_CANT_OPEN_FMOD_WRITE_EXEC_CMD 1766 #define STID_FNUM_NOT_OPEN_WHILE_EXEC_CMD 1767 #define STID_EOF_FOR_FNUM_WHILE_EXEC_CMD 1768 #define STID_WRI_FNUM_FAIL_WHILE_EXEC_CMD 1769 #define STID_WRI_FNN_FAIL_WHILE_EXEC_CMD 1770 #define STID_INVALID_PATH_WHILE_EXEC_CMD 1771 #define STID_APPEND_FAILED_WHILE_EXEC_CMD 1772 #define STID_COPY_FAILED_WHILE_EXEC_CMD 1773 #define STID_INVALID_FORMAT_WHILE_EXEC_CMD 1774 #define STID_INVALID_REC_WHILE_EXEC_CMD 1775 #define STID_CONVERT_FORMAT_WHILE_EXEC_CMD 1776 #define STID_IMPORT_FAILED_WHILE_EXEC_CMD 1777 #define STID_BAD_VER_NUM_WHILE_EXEC_CMD 1778 #define STID_EMPTY_INI_SEC_WHILE_EXEC_CMD 1779 #define STID_BAD_LINENUM_WHILE_EXEC_CMD 1780 #define STID_BAD_SMALL_LNUM_WHILE_EXEC_CMD 1781 #define STID_BAD_EMPTY_STR_WHILE_EXEC_CMD 1782 #define STID_BAD_DIRECTION_WHILE_EXEC_CMD 1783 #define STID_NO_START_VRTX_WHILE_EXEC_CMD 1784 #define STID_TOO_FEW_VRTX_WHILE_EXEC_CMD 1785 #define STID_NO_START_OBJ_WHILE_EXEC_CMD 1786 #define STID_CANT_FIND_MARK_WHILE_EXEC_CMD 1787 #define STID_NO_OBJ_GROUP_WHILE_EXEC_CMD 1788 #define STID_CANT_GRP_SNGL_WHILE_EXEC_CMD 1789 #define STID_UNRECOG_CMD_MAY_BE_BLANKS_ABT 1790 #define STID_UNRECOG_CMD_DOWNLOAD_TOOL 1791 #define STID_UNRECOG_CMD_ABORT 1792 #define STID_TOOL_NOT_DONE_WITH_PREV_FUNC 1793 #define STID_ENTER_INTERN_CMD_FILE_NAME 1794 #define STID_FINISH_EXEC_CMD_FROM_STDIN 1795 #define STID_FATAL_ERROR_IN_FUNC_PLUS_DESC 1796 #define STID_TOOL_ABORTED 1797 #define STID_ICON_FILEVER_TOO_LARGE 1798 #define STID_UNEQUAL_DEPTHS_IN_FUNC 1799 #define STID_BASELINE_YS_NOT_EQ_IN_FUNC 1800 #define STID_LOCKED_OBJS_CANT_BE_MOVED 1801 #define STID_HINT_CTL_MOVE_ATTR_ONLY 1802 #define STID_OUT_OF_VMEM_CANNOT_MALLOC 1803 #define STID_CANT_ALLOC_BITMAP_OF_SIZE 1804 #define STID_FAIL_TO_WRITE_TO_FILE 1805 #define STID_SAFEST_SAVE_N_EXIT_REPRODUCE 1806 #define STID_FATAL_UNEXPECTED_ERROR 1807 #define STID_ENTER_FNAME_TO_WRITE_MSG_BUF 1808 #define STID_STDOUT_STDERR_ESC_CANCEL 1809 #define STID_MSG_BUF_SAVED_INTO_GIVEN 1810 #define STID_FILE_LINE_MISS_FIELD_IN_OBJ 1811 #define STID_FILE_LINE_BAD_FIELD_IN_OBJ 1812 #define STID_NAMED_SIG_RECV 1813 #define STID_ERR_COUNT_EXCEED_TOOL_ABORTED 1814 #define STID_WORKING_FILE_SAVED_TO 1815 #define STID_UNABLE_TO_SAVE_WORKING_FILE 1816 #define STID_X_ERROR_MSG 1817 #define STID_BAD_COMPILE_OPT_USE_ALT_STR 1818 #define STID_MISSING_DISPLAY_NAME 1819 #define STID_MISSING_PAGE_NUMBER 1820 #define STID_INVALID_GIVEN_PAGE_NUMBER_STR 1821 #define STID_MISSING_ARG_FOR_CMDLINE_OPT 1822 #define STID_INVALID_ARG_FOR_CMDLINE_OPT 1823 #define STID_TGIF_PATH_SHOULD_NOT_BE_USED 1824 #define STID_PRINT_TO_PRINTER_INCOMPAT 1825 #define STID_BAD_EXEC_FNAME_DASH 1826 #define STID_CANNOT_OPEN_DIR_FOR_READING 1827 #define STID_FAIL_TO_STAT_GIVEN_FILE 1828 #define STID_SET_WORKING_DIR 1829 #define STID_CLICK_SETWORKDIR_TO_SET_DIR 1830 #define STID_SETWORKDIR_NOT_SUP_FOR_STR 1831 #define STID_OPENSAVE_DIR_CHANGE_TO_REMAIN 1832 #define STID_IMPORT_DIR_CHANGED_TO_REMAIN 1833 #define STID_GEN_LIST_OF_DOMAIN_NAMES_WAIT 1834 #define STID_CANT_GEN_DOM_NAMES_INI_ENTRY 1835 #define STID_CANT_GEN_DOM_NAMES_XDEF 1836 #define STID_CANT_GET_LIST_OF_DOM_NAMES 1837 #define STID_PLEASE_SELECT_A_NEW_DOMAIN 1838 #define STID_CURRENT_DOMAIN_IS 1839 #define STID_SYMBOL_PATH_SET_TO 1840 #define STID_PLS_SEL_A_DIR_IN_GIVEN_DOMAIN 1841 #define STID_GEN_LIST_XBM_NAMES_WAIT 1842 #define STID_GEN_LIST_XPM_NAMES_WAIT 1843 #define STID_GEN_LIST_OBJ_NAMES_WAIT 1844 #define STID_GEN_LIST_SYM_NAMES_WAIT 1845 #define STID_GEN_LIST_TYPE_FILE_NAMES_WAIT 1846 #define STID_NO_GIVEN_TYPE_FILE_FOUND 1847 #define STID_NO_DIR_SEP_IN_FUNC_WORK_DIR 1848 #define STID_NO_DIR_SEP_IN_FUNC_SYM_DIR 1849 #define STID_NO_DIR_SEP_IN_FUNC_IMPORT_DIR 1850 #define STID_EMPTY_PATH_DISALLOW_FOR_DOM 1851 #define STID_TOOL_EDIT_DOM_PATHS 1852 #define STID_EDIT_DOMAIN_PATHS_DOTS 1853 #define STID_TOOL_SEL_DEFAULT_DOMAIN 1854 #define STID_SEL_DEFAULT_DOMAIN_DOTS 1855 #define STID_PLS_SPEC_A_NEW_DOMAIN_NAME 1856 #define STID_GIVEN_DOMAIN_ALREADY_EXISTS 1857 #define STID_GIVEN_DOM_ADDED_PATH_SET_TO 1858 #define STID_SEL_DOMAIN_TO_DELETE_DOTS 1859 #define STID_OK_TO_DELETE_NAMED_DOMAIN_YNC 1860 #define STID_OK_TO_RELOAD_DOM_INFO_FROM_X 1861 #define STID_ERR_IN_PARSE_STR_FOR_2_VAL 1862 #define STID_FILE_MOD_SAVE_BEFORE_BACK 1863 #define STID_NOTHING_TO_GO_BACK_TO 1864 #define STID_FILE_MOD_SAVE_BEFORE_FORWARD 1865 #define STID_NOTHING_TO_GO_FORWARD_TO 1866 #define STID_FAIL_TO_FIND_RECORD_IN_FUNC 1867 #define STID_FURTHER_NAVIGATE_MAY_CRASH 1868 #define STID_CANT_REFRESH_UNDEFINED_FILE 1869 #define STID_FILE_MOD_SAVE_BEFORE_RELOAD 1870 #define STID_HOT_LIST_FILE_UNDEF_PLS_SPEC 1871 #define STID_MALFORMED_NAMED_HOT_LIST_FILE 1872 #define STID_HOT_LIST_FILE_IS_EMPTY 1873 #define STID_Q_DEL_NAMED_FROM_HOT_LIST 1874 #define STID_FILE_MOD_SAVE_BEFORE_OPEN_ANO 1875 #define STID_SESSION_HIST_NOT_ESTABLISHED 1876 #define STID_TOOL_HOT_LIST 1877 #define STID_TOOL_HISTORY 1878 #define STID_HOT_LIST_DOTS 1879 #define STID_CANT_ADD_UNDEF_TO_HOT_LIST 1880 #define STID_HOT_LIST_FILE_UPDATED 1881 #define STID_SESSION_HISTORY_DOTS 1882 #define STID_ENTER_HYPERSPACE_DOTS 1883 #define STID_LEAVING_HYPERSPACE_DOTS 1884 #define STID_CANT_SLIDESHOW_IN_TILED_PAGE 1885 #define STID_FILE_MOD_SAVE_BEFORE_SLIDE 1886 #define STID_PAGE_NUM_MOD_IN_SLIDE_NOT_SAV 1887 #define STID_Q_PAGE_NUM_MOD_IN_SLIDE_YNC 1888 #define STID_ENTERING_SLIDESHOW_DOTS 1889 #define STID_LEAVING_SLIDESHOW_DOTS 1890 #define STID_ENTER_A_COLOR_FOR_SLIDE_BRDR 1891 #define STID_PRESS_ENTER_FOR_DEF_COLOR 1892 #define STID_SLIDE_WILL_USE_DEF_BRDR_COLOR 1893 #define STID_SLIDE_BRDR_COLOR_SET_TO_NAMED 1894 #define STID_ENTER_XY_OFFSET_FOR_SLIDE_WIN 1895 #define STID_SLIDE_WIN_XY_OFFSETS_SET_TO 1896 #define STID_GRID_BE_VISIBLE_IN_SLIDE 1897 #define STID_GRID_NOT_BE_VISIBLE_IN_SLIDE 1898 #define STID_CANT_DO_NEXTPAGE_IN_TILED 1899 #define STID_ALREADY_AT_LAST_PAGE 1900 #define STID_CANT_DO_PREVPAGE_IN_TILED 1901 #define STID_ALREADY_AT_FIRST_PAGE 1902 #define STID_TOOL_NAME_PAGES 1903 #define STID_TOOL_GOTO_PAGE 1904 #define STID_CANT_DO_GOTOPAGE_IN_TILED 1905 #define STID_GOTO_PAGE_DOTS 1906 #define STID_NO_PAGE_SELECTED 1907 #define STID_INVALID_GIVEN_PAGE_NUMBER 1908 #define STID_ALREADY_AT_GIVEN_PAGE 1909 #define STID_CUR_PAGE_IS_GIVEN_PAGE_NUM 1910 #define STID_CANT_DO_NAMEPAGES_IN_TILED 1911 #define STID_EDIT_PAGE_NAMES_DOTS 1912 #define STID_CANT_EDITPAGEFNAME_IN_TILED 1913 #define STID_EDIT_PAGE_FILE_NAMES_DOTS 1914 #define STID_PAGE_FNAME_NO_SPACE_TRUNC 1915 #define STID_OK_TO_FLUSH_UNDO_AND_PROCEED 1916 #define STID_ADD_PAGE_BEFORE_GIVEN_FLUSH 1917 #define STID_ADD_PAGE_AFTER_GIVEN_FLUSH 1918 #define STID_DELETE_GIVEN_PAGE_CAUSE_FLUSH 1919 #define STID_DELETE_A_PAGE_CAUSE_FLUSH 1920 #define STID_DELETE_PAGES_PAGE_CAUSE_FLUSH 1921 #define STID_CHNG_PAGE_LAYOUT_FLUSH 1922 #define STID_SET_PAPER_COLOR_CAUSE_FLUSH 1923 #define STID_CANT_DO_ADDPAGE_IN_TILED 1924 #define STID_CANT_DO_DELETEPAGE_IN_TILED 1925 #define STID_CANT_DEL_ONLY_PAGE_IN_TILED 1926 #define STID_CANT_DO_SPECDRAWSIZE_IN_TILED 1927 #define STID_CANT_DO_DELETEPAGES_IN_TILED 1928 #define STID_CANT_DO_POFPP_IN_TILED 1929 #define STID_CANT_DO_POFPP_TO_PRINTER 1930 #define STID_NAMED_TEMPLATE_LOADED 1931 #define STID_PROB_LOADING_NAMED_TEMPLATE 1932 #define STID_GIVEN_PAGE_NUM_ADDED 1933 #define STID_ADDPAGEBEFORE_IN_WB 1934 #define STID_ADDPAGEAFTER_IN_WB 1935 #define STID_GIVEN_PAGE_NUM_DELETED 1936 #define STID_CANT_TPLS_IN_STACKED 1937 #define STID_ENTER_DRAW_SIZE_SPEC_WH 1938 #define STID_BAD_DRAW_SIZE_SPEC_WH 1939 #define STID_BAD_DRAW_SIZE_SPEC_W_TIMES_H 1940 #define STID_INVALID_DRAW_SIZE_SPEC 1941 #define STID_CANT_PRINTONEPAGE_IN_FORMAT 1942 #define STID_BTN1_SEL_PAGE_TO_PRINT 1943 #define STID_OTHER_BTN_CANCEL_PRINTONEPAGE 1944 #define STID_SELECT_A_PAGE_TO_PRINT 1945 #define STID_OPERATION_CANCEL_BY_USER 1946 #define STID_MUST_SEL_A_PT_ON_THE_PAPER 1947 #define STID_MUST_SEL_A_PT_IN_TOOL_WIN 1948 #define STID_NEW_PAPER_SIZE_IS_GIVEN 1949 #define STID_INVALID_GIVEN_PAPER_SIZE_SPEC 1950 #define STID_CUR_PAPER_SIZE_IS_GIVEN 1951 #define STID_ENTER_PAPER_SIZE_WH 1952 #define STID_CANT_DEL_ONLY_PAGE_IN_STACKED 1953 #define STID_SPECIFY_PAGES_TO_DEL_EX 1954 #define STID_GIVEN_PAGE_NUM_IS_OUT_OF_RNG 1955 #define STID_MALFORMED_SPECIFICATION_STR 1956 #define STID_CANT_DEL_ALL_PAGES 1957 #define STID_ONE_PAGE_DELETED 1958 #define STID_MANY_PAGES_DELETED 1959 #define STID_OBJ_OUTSIDE_PAGE_BNRDY_SWITCH 1960 #define STID_SWTCH_TO_TILED_LOSE_ALL_NAMES 1961 #define STID_CHANGE_PAGE_LAYOUT_MODE_IN_WB 1962 #define STID_PAGE_LAYOUT_MODE_IS_STACKED 1963 #define STID_PAGE_LAYOUT_MODE_IS_TILED 1964 #define STID_SPECIFY_A_PAPER_COLOR 1965 #define STID_SPECIFY_A_PAPER_COLOR_CUR_IS 1966 #define STID_ENTER_NONE_TO_REMOVE_COLOR 1967 #define STID_PAPER_COLOR_REMOVED 1968 #define STID_PAPER_COLOR_SET_TO_GIVEN 1969 #define STID_GRAY_SCALE_USED_IN_PRINT_PAT 1970 #define STID_NOTE_SLOW_PRINT_DUE_USE_PAT 1971 #define STID_SUGGEST_USEGRAYSCALE_TO_SPEED 1972 #define STID_FILL_PEN_PAT_OPAQUE 1973 #define STID_FILL_PEN_PAT_TRANSPARENT 1974 #define STID_LINE_WIDTH_SET_TO_GIVEN_STR 1975 #define STID_ENTER_LINE_WIDTH_OPT_AW_AH 1976 #define STID_INVALID_GIVEN_STR_WIDTH 1977 #define STID_INVALID_GIVEN_STR_AW_AH 1978 #define STID_NO_PINS_FOUND_IN_CUR_DRAWING 1979 #define STID_INPUT_PAIRS_OF_POINTS_POLY 1980 #define STID_READ_INT_ERROR_FOR_POLY_PTS 1981 #define STID_TOO_FEW_POINTERS_ENTERED 1982 #define STID_TOO_FEW_VER_TO_CLOSE_POLY 1983 #define STID_HUH_WHERE_ARE_THE_VERTICES 1984 #define STID_HUH_TOPVSEL_NE_BOTVSEL 1985 #define STID_CMD_ONLY_AVAIL_IN_VERSEL_MODE 1986 #define STID_SEL_2_ENDPOINT_VER_TO_JOIN 1987 #define STID_SEL_VER_FROM_POLY_OPEN_ONLY 1988 #define STID_SEL_2_POLYLINES_OPEN_SPLINES 1989 #define STID_CANT_JOIN_INTSPLINE_W_NONEINT 1990 #define STID_SEL_1_VERTEX_TO_CUT 1991 #define STID_SEL_A_VERTEX_FROM_POLY_OR_GON 1992 #define STID_INVALID_SMOOTHHINGE_SPEC_POLY 1993 #define STID_INVALID_NUM_PTS_IN_POLY 1994 #define STID_INPUT_PAIRS_OF_POINTS_POLYGON 1995 #define STID_READ_INT_ERR_FOR_POLYGON_PTS 1996 #define STID_INVALID_NUM_PTS_IN_POLYGON 1997 #define STID_CANT_GET_XDEF_DEF_WIDTHS_USED 1998 #define STID_ERR_SETCTM_CALLED_CTM_NONNULL 1999 #define STID_MEASUREMENT_SHOWN_IN_UNIT 2000 #define STID_BAD_MEASUREMENT_UNIT_SPEC 2001 #define STID_SHOW_CROSSHAIR_ENABLED 2002 #define STID_SHOW_CROSSHAIR_DISABLED 2003 #define STID_SHOW_MEASUREMENT_ENABLED 2004 #define STID_SHOW_MEASUREMENT_DISABLED 2005 #define STID_CANNOT_EXECUTE_GIVEN_CMD 2006 #define STID_CONNECTION_INTERRUPTED 2007 #define STID_CANT_CONN_TO_HOST_PORT 2008 #define STID_FAIL_TO_GET_DATA_FROM_URL 2009 #define STID_NETWORK_ERR_TALK_TO_HOST_PORT 2010 #define STID_FAILED_TO_LOGIN_TO_HOST_PORT 2011 #define STID_CANT_FIND_LOCATION_IN_HDR 2012 #define STID_LNK_FWD_5_TIMES_LOAD_ABORT 2013 #define STID_CANT_FIND_WWW_AUTHEN_IN_HDR 2014 #define STID_AUTHEN_REQ_FOR_REALM 2015 #define STID_ENTER_USERNAME_FOR_REALM 2016 #define STID_ENTER_PASSWORD_FOR_REALM 2017 #define STID_FAIL_TO_PARSE_GIVEN_URL 2018 #define STID_TOOL_NOT_KNOW_HOW_TALK_PROTO 2019 #define STID_LAUNCH_GIVEN_VIEWER 2020 #define STID_CANT_OPEN_GIVEN_MAILCAP_FILE 2021 #define STID_MALFORMED_MAILCAP_ENTRY 2022 #define STID_MALFORMED_MAILCAP_ENTRY_PARAM 2023 #define STID_TOOL_CANT_HANDLE_MP_MIME 2024 #define STID_CANT_FIND_RT_BRACK_MC 2025 #define STID_CANT_FIND_RT_BRACK_MC_PARAM 2026 #define STID_CANT_FIND_NAMED_INFO_IN_CT 2027 #define STID_SAVE_GIVEN_STR_AS 2028 #define STID_NO_VIEWER_SAVE_GIVEN_STR_AS 2029 #define STID_UNKNOWN_ERR_IN_COPYING_FILES 2030 #define STID_CANT_GETHOSTNAME_USE_LOCALH 2031 #define STID_TURN_OFF_AUTO_PAN_SET_XDEF 2032 #define STID_WILL_UPD_WIN_SMOOTH_SCROLL 2033 #define STID_WILL_UPD_WIN_JUMP_SCROLL 2034 #define STID_WILL_NOT_UPD_WIN_SCROLL 2035 #define STID_INCONSIS_VERTEX_SEL_IN_FUNC 2036 #define STID_INVALID_NAMED_TELEPORT_DEST 2037 #define STID_Q_FILE_NOT_EXIST_CREATE 2038 #define STID_CANT_FIND_PAGE_NAMED_TO_TEL 2039 #define STID_CANT_FIND_PAGE_NUM_TO_TEL 2040 #define STID_CANT_GROUP_IN_VERTEX_MODE 2041 #define STID_CANT_GROUP_SINGLE_OBJECT 2042 #define STID_INVALID_XDEF_USE_ALT_OCTVALUE 2043 #define STID_INVALID_XDEF_RNG_USE_ALT_STR 2044 #define STID_CANT_CREATE_NAMED_DIRECTORY 2045 #define STID_OPR_USING_NAMED_DIR_WILL_FAIL 2046 #define STID_CREATE_A_SHAPE_FAILED 2047 #define STID_CREATE_SHADOW_SHAPE_NO_FILL 2048 #define STID_CREATE_SHADOW_SHAPE_TRAN_FILL 2049 #define STID_ENTER_XY_OFFSET_FOR_SHP_SHDW 2050 #define STID_SHAPE_SHDW_XY_OFFSETS_SET_TO 2051 #define STID_INVALID_SHORTCUT_ENTRY_SKIP 2052 #define STID_DUP_SHORTCUT_ENTRY_FOR_CHAR 2053 #define STID_INVALID_SHORTCUT_ENTRY 2054 #define STID_WARN_DUP_CMDID 2055 #define STID_PUSH_IN_WB 2056 #define STID_FILE_VER_ABORT_READ_SYMBOL 2057 #define STID_CANT_FIND_NAMED_OBJ_IN_FUNC 2058 #define STID_SEL_A_SYM_TO_INSTAN_IN_DOMAIN 2059 #define STID_CANT_INSTAN_FILE_UNKNOWN_EXT 2060 #define STID_CANT_MAKESYMBOLIC_VERTEX_MODE 2061 #define STID_SEL_ONLY_ONE_FOR_MAKESYMBOLIC 2062 #define STID_PIN_CANT_MADE_INTO_SYMBOL 2063 #define STID_SEL_OBJ_IS_NOW_SYMBOLIC 2064 #define STID_ENTER_NAME_FOR_THE_ICON 2065 #define STID_NAME_NOT_SPEC_ICON_NOT_CREATE 2066 #define STID_CANT_SAVE_OBJ_ICON_NOT_CREATE 2067 #define STID_CANT_FIND_DOT_IN_ICON_NAME_MI 2068 #define STID_CANT_SAVE_PIN_ICON_NOT_CREATE 2069 #define STID_CANT_OPEN_FOR_WRITE_ICON_CRET 2070 #define STID_SEL_OBJ_IS_NOW_ICONIC 2071 #define STID_SEL_ONLY_ONE_FOR_MAKEICONIC 2072 #define STID_SEL_OBJS_ARE_NOW_GROUP 2073 #define STID_GIVEN_LINE_SKIP_NOT_AN_ATTR 2074 #define STID_GIVEN_LINE_SKIP_ILLEGAL_CHAR 2075 #define STID_SEL_ONE_OBJ_FOR_IMPORTATTRS 2076 #define STID_SEL_TEXT_FILE_OF_ATTR_TO_IMP 2077 #define STID_CANT_IMPORT_REMOTE_TEXT_FILE 2078 #define STID_SEL_ONE_OBJ_FOR_EXPORTATTRS 2079 #define STID_SEL_OBJ_HAS_NO_ATTR_TO_EXPORT 2080 #define STID_ENTER_TXT_FILE_TO_EXPORT_CRES 2081 #define STID_ATTR_EXPORTED_TO_NAMED_FILE 2082 #define STID_CANT_FIND_ATTR_FOR_MERGEWTBL 2083 #define STID_MALFORMED_ATTR_FOR_MERGEWTBL 2084 #define STID_SEL_ONE_OBJ_FOR_MERGEWTBL 2085 #define STID_FILE_MOD_SAVE_BEFORE_MERGE 2086 #define STID_Q_MERGEWTBL_CANT_UNDO_PROCEED 2087 #define STID_SEL_TEXT_FILE_FOR_MERGEWTBL 2088 #define STID_CANT_MERGE_W_REMOTE_TEXT_FILE 2089 #define STID_FIND_COL_NAMES_IN_FILE_ABORT 2090 #define STID_MALFORMED_COL_NAMES_ABORT_MRG 2091 #define STID_LF_BTN_PLACE_MRG_OTHER_CANCEL 2092 #define STID_MALFORMED_TBL_LINE_ABORT_MRG 2093 #define STID_CANT_FND_NAMED_ATTR_ABORT_MRG 2094 #define STID_NUM_OBJECTS_GENERATED 2095 #define STID_CANT_FND_TABLE_ATTRS_FILE_ATT 2096 #define STID_NUM_OBJECTS_EXPORTED 2097 #define STID_ATTRS_EXPORTED_TO_TBL_FILE 2098 #define STID_SEL_ONE_ICON_OBJ_TO_PUSH 2099 #define STID_CANT_FND_SYM_FILE_IN_PATH 2100 #define STID_CANNOT_OPEN_FOR_READ_PUSH 2101 #define STID_FILE_VER_ABORT_PUSH 2102 #define STID_POP_BACK_TO_PARENT_UNDEF 2103 #define STID_ALREADY_AT_TOP_LEVEL 2104 #define STID_FILE_MOD_SAVE_BEFORE_POP 2105 #define STID_CANT_FND_SYM_IN_NAMED_TO_INST 2106 #define STID_CANT_FIND_XDEF 2107 #define STID_ENTER_USERAGENT_FOR_HTTP 2108 #define STID_ENTER_USERAGENT_FOR_HTTP_CUR 2109 #define STID_PRESS_ENTER_FOR_DEF_USERAGENT 2110 #define STID_WILL_USE_DEF_USERAGENT_HTTP 2111 #define STID_WILL_USE_NAMED_USERAGENT_HTTP 2112 #define STID_ENTER_REFERRER_FOR_HTTP 2113 #define STID_ENTER_REFERRER_FOR_HTTP_CUR 2114 #define STID_PRESS_ENTER_FOR_NO_REFERRER 2115 #define STID_WILL_NOT_USE_REFERRER_HTTP 2116 #define STID_WILL_USE_NAMED_REFERRER_HTTP 2117 #define STID_WILL_USE_KEEP_ALIVE_HTTP 2118 #define STID_NOT_WILL_USE_KEEP_ALIVE_HTTP 2119 #define STID_CANT_LOCATE_NAMED_SERVER_TRY 2120 #define STID_FAIL_TO_MAKE_SOCKET_BLOCK 2121 #define STID_FAIL_TO_MAKE_SOCKET_NON_BLOCK 2122 #define STID_BROKEN_PIPE_CONTACT_HOST 2123 #define STID_WRITE_TO_SOCKET_FAILED 2124 #define STID_READ_FROM_SOCKET_FAILED 2125 #define STID_UNEXP_NETWORK_ERR_WRITE_SOCK 2126 #define STID_UNEXP_NETWORK_ERR_READ_SOCK 2127 #define STID_LOCKED_OBJS_CANT_BE_STRETCHED 2128 #define STID_CANT_STRETCH_OBJ_HAS_0_WIDTH 2129 #define STID_CANT_STRETCH_OBJ_HAS_0_HEIGHT 2130 #define STID_LOCKED_OBJS_CANT_BE_SCALED 2131 #define STID_ENTER_SCALING_FACTORS_XY 2132 #define STID_ENTER_A_SCALING_FACTOR 2133 #define STID_ONLY_INPUT_ONE_NUMERIC_VAL 2134 #define STID_SCALING_EVERYTHING_LARGE_SURE 2135 #define STID_DISABLE_ON_RESIZE_ROTATE 2136 #define STID_DISABLE_ON_RESIZE_SHEAR 2137 #define STID_DISABLE_ON_RESIZE_TRANSFORM 2138 #define STID_LOCKED_OBJS_CANT_BE_FLIPPED 2139 #define STID_LOCKED_OBJS_ARE_NOT_FLIPPED 2140 #define STID_LOCKED_OBJS_ARE_NOT_STRETCHED 2141 #define STID_LOCKED_OBJS_ARE_NOT_ROTATED 2142 #define STID_LOCKED_OBJS_ARE_NOT_SHEARED 2143 #define STID_LOCKED_OBJS_ARE_NOT_XFORMED 2144 #define STID_FLIPPED_HORIZONTALLY 2145 #define STID_FLIPPED_VERTICALLY 2146 #define STID_LOCKED_OBJS_CANT_BE_ROTATED 2147 #define STID_ROTATED_CLOCKWISE 2148 #define STID_ROTATED_COUNTER_CLOCKWISE 2149 #define STID_ENTER_TEXT_ROT_IN_DEGREE_CUR 2150 #define STID_CANT_PARSE_ENTER_ONE_NUM_VAL 2151 #define STID_INVALID_VAL_ENTERED_RNG_INC 2152 #define STID_TEXT_ROTATION_SET_TO_GIVEN 2153 #define STID_ENTER_ROT_INC_IN_DEGREE_CUR 2154 #define STID_INVALID_VAL_ENTERED_RNG_EXC 2155 #define STID_TEXT_ROT_INC_SET_TO_GIVEN 2156 #define STID_LOCKED_OBJS_CANT_BE_XFORMED 2157 #define STID_SEL_OBJ_TOO_SMALL_ROT_ANOTHER 2158 #define STID_SEL_OBJ_TOO_SMALL_SHEAR_ANO 2159 #define STID_CANNOT_CREATE_GC 2160 #define STID_READ_ONLY_TEXT_CANT_BE_EDITED 2161 #define STID_TEXT_SZ_NOT_AVAIL_TRY_DIFF 2162 #define STID_CANT_INS_NON_DB_CH_AT_CUR_REM 2163 #define STID_TOO_MANY_BYTES_IN_CH_IGNORED 2164 #define STID_CANT_TAB_OUT_OF_NON_ATTR_TEXT 2165 #define STID_COMPOUND_TEXT_BUF_IS_EMPTY 2166 #define STID_CUT_BUFFER_IS_EMPTY 2167 #define STID_AN_ESC_KEY_PRESS_IGNORED 2168 #define STID_GIVEN_NUM_LINES_PASTED 2169 #define STID_COPY_FAIL_SEL_STR_MAY_TOO_LNG 2170 #define STID_UNEXPECTED_TOK_IN_ABORT_READ 2171 #define STID_ILLEGAL_FIELD_IN_ABORT_READ 2172 #define STID_INVALID_GIVEN_VALUE_SPECIFIED 2173 #define STID_ENTER_SCRIPT_FRACTION_CUR_IS 2174 #define STID_SCRIPT_FRACTION_SET_TO_STR 2175 #define STID_ENTER_INT_WIDTH_FOR_THIN_SPC 2176 #define STID_ENTER_INT_VAL_FOR_VERT_OFFSET 2177 #define STID_FAIL_INSERT_SCRIPT_FONT_SZ 2178 #define STID_TOOL_DONT_KNOW_HOW_RUN_GUNZIP 2179 #define STID_SPECIFY_DISPLAY_ON_CMD_LINE 2180 #define STID_FILE_VER_ABORT_TOOL 2181 #define STID_FILE_SKIP_CONTAINS_ONE_PAGE 2182 #define STID_FILE_SKIP_CONTAINS_NUM_PAGE 2183 #define STID_FILE_NOT_CONTAIN_COLOR_ABORT 2184 #define STID_SPEC_FILE_WHEN_STDOUT_USED 2185 #define STID_TOOL_FILE_NAME_TO_PRINT 2186 #define STID_CANT_ONEFPPAGE_IN_TILED_PAGE 2187 #define STID_ONE_FILE_ONLY_WITH_STDOUT 2188 #define STID_ONE_FILE_ONLY_RAW_PLUS_H 2189 #define STID_ONE_FILE_ONLY_DOSEPSFILTER 2190 #define STID_CANT_PRTGIF_OFPP_TILED_PAGE 2191 #define STID_INVALID_SHARELIB_VER_IN_FILE 2192 #define STID_FAIL_LOAD_SHARELIB 2193 #define STID_FAIL_GET_ENTRY_PT_IN_SHARELIB 2194 #define STID_SHARELIB_TGEF_MSG_INIT_FAIL 2195 #define STID_SHARELIB_CNFLCT_PROTOCOL_VER 2196 #define STID_SHARELIB_TGEF_MSG_LOAD_FAIL 2197 #define STID_SHARELIB_TGEF_MSG_NO_BMP_INFO 2198 #define STID_ALLOC_BMP_FAIL_FOR_SHARELIB 2199 #define STID_UNSUP_PROTOCOL_VER_SHARELIB 2200 #define STID_SHARELIB_TGEF_MSG_DO_EXPORT_F 2201 #define STID_NEG_VAL_IN_EXP_PXL_TRM_ALT 2202 #define STID_EXP_PXL_TRM_VAL_SET_TO 2203 #define STID_SPECIFY_TO_TRIM_EXP_PXL_TRM 2204 #define STID_ENTER_4_NUM_CUR_TOO_LARGE 2205 #define STID_ENTER_4_NUM_OR_CR_ESC 2206 #define STID_OBSOLETE_XDEF_USE_IGNORED 2207 #define STID_WILL_USE_FS_HALFTONE_BMP 2208 #define STID_WILL_NOT_USE_FS_HALFTONE_BMP 2209 #define STID_WILL_USE_GIVE_SMPLE_THRESHOLD 2210 #define STID_WILL_NOT_USE_SIMPLE_THRESHOLD 2211 #define STID_ENTER_BMP_THRESHOLD_CUR_VAL 2212 #define STID_INVALID_THRESHOLD_REMAINS 2213 #define STID_USE_GIVEN_AS_BMP_THRESHOLD 2214 #define STID_XGETIMAGE_MAY_RUN_OUT_VMEM 2215 #define STID_NO_X11_BITMAP_OBJ_SELECTED 2216 #define STID_CANT_CUT_AN_EPS_OBJECT 2217 #define STID_XBM_CANT_HAVE_0_W_OR_H 2218 #define STID_BAD_RED_MASK_TRUE_COLOR_DPY 2219 #define STID_BAD_GREEN_MASK_TRUE_COLOR_DPY 2220 #define STID_BAD_BLUE_MASK_TRUE_COLOR_DPY 2221 #define STID_NETPBM_PROGS_VISIT_HOME_PAGE 2222 #define STID_NETPBM_PNMTOPNG_VST_HOME_PAGE 2223 #define STID_FNAME_FORMAT_ERROR_IN_FUNC 2224 #define STID_NAMED_IMAGEMAP_FILE_GEN 2225 #define STID_CANT_FND_FATTR_IMGMAP_NOT_GEN 2226 #define STID_CANT_FND_FATTR_NO_IMGMAP_GIF 2227 #define STID_NAMED_HTML_FILE_GEN 2228 #define STID_LARGE_EXP_PXL_TRM_WH_0_USED 2229 #define STID_APPLY_EXP_PXL_TRM_VALS 2230 #define STID_TOO_MANY_COLORS_LIMIT_IS 2231 #define STID_UNRECOG_GIVEN_PIXEL_VAL_PRINT 2232 #define STID_UNRECOG_GIVEN_PIXEL_VAL_1_USE 2233 #define STID_FORMAT_FILE_WH_PRINTED_INTO 2234 #define STID_SEL_XPM_DECK_TO_EXPORT 2235 #define STID_MANY_SZ_FAIL_XPM_DESK_EXPORT 2236 #define STID_INVALID_CH_PER_PIX_IN_FUNC 2237 #define STID_XPM_CANT_HAVE_0_W_OR_H 2238 #define STID_WARN_XPM_ALL_NON_BG_BE_BLACK 2239 #define STID_SAVED_FILE_MAY_BE_CORRUPTED 2240 #define STID_CANT_SAVE_XPM_ON_BW_DPY 2241 #define STID_CANT_IMPORT_GIVEN_FORMAT_XPM 2242 #define STID_CANT_IMPORT_GIVEN_CPP_XPM 2243 #define STID_EDIT_UNNAME_ATTR_DOTS 2244 #define STID_EDIT_VAL_OF_ATTR_DOTS 2245 #define STID_EDIT_UNNAME_ATTR_WITH_CMD 2246 #define STID_EDIT_VAL_OF_ATTR_WITH_CMD 2247 #define STID_STAT_FAIL_EDIT_ATTR_VAL_SAME 2248 #define STID_ENTER_HTML_TEMPLATE 2249 #define STID_ENTER_HTML_TEMPLATE_CUR_IS 2250 #define STID_HTML_TEMPLATE_UNCHANGED 2251 #define STID_HTML_TEMPLATE_SET_TO_GIVEN 2252 #define STID_NO_HTML_TEMPLATE_FILE 2253 #define STID_Q_FILE_NOT_EXIST_USE_ANYWAY 2254 #define STID_CANNOT_OPEN_HTML_TMPL_READ 2255 #define STID_OK_TO_FULL_SCREEN_CAPTURE_YNC 2256 #define STID_Q_FILE_UNSAVABLE_SAVE_NEW_YNC 2257 #define STID_WONT_CONDENSE_READHEXSTRING 2258 #define STID_CMD_ONLY_AVAIL_IN_VERTEX_MODE 2259 #define STID_CANNOT_MERGE_WITH_TILED_PAGE 2260 #define STID_SPECIFY_PAGES_TO_PRINT_EX 2261 #define STID_CANT_PRINT_PAGES_IN_TILED 2262 #define STID_CANT_PRINT_PAGES_IN_FORMAT 2263 #define STID_PRECISE_SCALE_EV_CAUSE_FLUSH 2264 #define STID_GO_HYPERSPACE_IN_SLIDE 2265 #define STID_DONT_GO_HYPERSPACE_IN_SLIDE 2266 #define STID_MOVE_EDIT_TEXT_BOX_ABORTED 2267 #define STID_DRAG_MOUSE_MOVE_EDITTEXT_DOTS 2268 #define STID_EXCEED_BUF_SIZE_LIMIT_IN_WB 2269 #define STID_CANT_REPLACE_GRAPHIC_NOT_TGIF 2270 #define STID_CANT_REPLACE_GRAPHIC_TOO_MANY 2271 #define STID_REPLACE_GRAPHIC_ICON_TO_GROUP 2272 #define STID_REPLACE_GRAPHIC_DONE 2273 #define STID_TOO_MANY_ICON_REPLACE_GRAPHIC 2274 #define STID_Q_CVT_ICON_TO_GRP_IN_REPLACE 2275 #define STID_SHOW_MEASUREMENT_IN_TT_ENAB 2276 #define STID_SHOW_MEASUREMENT_IN_TT_DISB 2277 #define STID_SEL_JPEG_FILE_TO_IMPORT 2278 #define STID_CANNOT_IMPORT_GIVEN_JPEG 2279 #define STID_GIVEN_JPEG_SIZE_FILE_IMPORTED 2280 #define STID_WILL_EXPORT_JPEG_FILE 2281 #define STID_NETPBM_JPEG_VST_HOME_PAGE 2282 #define STID_CANT_GEN_PREVIEW_FOR_PS 2283 #define STID_CANT_GEN_PREVIEW_FOR_EMPTY_PS 2284 #define STID_WILL_AUTO_GEN_PREVIEW_BITMAP 2285 #define STID_WONT_AUTO_GEN_PREVIEW_BITMAP 2286 #define STID_TMP_DIR_NOT_EXIST_USE_XDEF 2287 #define STID_INVALID_DIR_IN_X_DEFAULT 2288 #define STID_RACE_IN_CREATE_TMP_FILE 2289 #define STID_INVALID_GEOM_USE_ALT_GEOM 2290 #define STID_REDUCE_BY_FACTOR 2291 #define STID_ENLARGE_BY_FACTOR 2292 #define STID_CREATE_THUMBNAIL_CAUSE_FLUSH 2293 #define STID_CONNECT_PORTS_CANCEL_BY_USER 2294 #define STID_Q_CNFLCT_SIG_NAME_OKAY_TO_CLR 2295 #define STID_PLS_ENT_SIG_NAME 2296 #define STID_SIGNAL_NAMES_CLEARED 2297 #define STID_PLACING_NAMED_SIGNAL 2298 #define STID_PLS_ENT_SIG_NAME_FOR_PORT 2299 #define STID_NO_CUR_FILE_CANNOT_GEN_NETLST 2300 #define STID_NO_SIGNAME_FOUND_EMPTY_NETLST 2301 #define STID_WILL_EXPORT_NETLIST_FILE 2302 #define STID_Q_OK_TO_CUT_INTO_SEGMENTS 2303 #define STID_NO_POLY_OBJ_SELECTED 2304 #define STID_WILL_SHOW_WIRE_SIGNAL_NAME 2305 #define STID_WILL_HIDE_WIRE_SIGNAL_NAME 2306 #define STID_TRY_AGAIN_AND_CLICK_IN_A_PORT 2307 #define STID_TRY_AGAIN_AND_END_IN_A_PORT 2308 #define STID_CANNOT_CREATE_ARC_WITH_RAD1 2309 #define STID_SEL_ONE_NONE_PORT_PLUS_COMP 2310 #define STID_PORT_OBJ_HAS_EMPTY_NAME 2311 #define STID_CANNOT_FIND_INIT_ATTR_PORT_PA 2312 #define STID_CANNOT_FIND_VAR_IN_INIT_ATTR 2313 #define STID_RENUMBER_OBJ_IDS_CAUSE_FLUSH 2314 #define STID_RENUMBER_OBJ_IDS_DONE 2315 #define STID_RENUMBER_OBJ_IDS_IN_WB 2316 #define STID_SEL_ONE_NONE_PORT_PLUS_BRDCST 2317 #define STID_CONFLICT_SIG_NAME_ENT_NEW 2318 #define STID_BAD_SIG_NAME_UNDO_AND_REDO 2319 #define STID_WILL_USE_WORDWRAP_IMPORT_TEXT 2320 #define STID_NO_WORDWRAP_IMPORT_TEXT 2321 #define STID_CUR_MARGINS_ARE_GIVEN 2322 #define STID_ENTER_MARGINS 2323 #define STID_NEW_MARGINS_ARE_GIVEN 2324 #define STID_CANT_OBTAIN_TMP_FILE_NAME 2325 #define STID_NO_OBJ_SPEC_WHILE_EXEC_CMD 2326 #define STID_UNRECOG_GIVEN_TRPIX_VAL_PRINT 2327 #define STID_TGIF_DISTRUBITION 2328 #define STID_WRITE_TO_SELF_PIPE_FAIL 2329 #define STID_CREATE_SELF_PIPE_FAIL 2330 #define STID_READ_FROM_SELF_PIPE_FAIL 2331 #define STID_ENTER_BEZIER_NUM_SEGS_CUR_IS 2332 #define STID_BEZIER_NUM_SEGS_SET_TO_INT 2333 #define STID_ENT_VAL_RANGE_ENTER_GE_INT 2334 #define STID_ENTER_TICK_MARK_SIZE_CUR_IS 2335 #define STID_TICK_MARK_SIZE_SET_TO_INT 2336 #define STID_NO_SPLINE_SELECTED 2337 #define STID_SPLINE_CONVERTED_TO_BEZIER 2338 #define STID_PEEK_DIM_LEFT 2339 #define STID_PEEK_DIM_TOP 2340 #define STID_PEEK_DIM_RIGHT 2341 #define STID_PEEK_DIM_BOTTOM 2342 #define STID_PEEK_DIM_WIDTH 2343 #define STID_PEEK_DIM_HEIGHT 2344 #define STID_PEEK_DIM_CX 2345 #define STID_PEEK_DIM_CY 2346 #define STID_NO_POLY_ETC_SELECTED 2347 #define STID_SEL_A_SYM_TO_INSTAN_IN_NONE 2348 #define STID_WRITE_NOT_AUTO_IN_HYPER_EXEC 2349 #define STID_USER_ABORT_WRITE_IN_HYPER 2350 #define STID_READ_FROM_SELF_PIPE_OVERFLOW 2351 #define STID_BAD_CMDLINE_OPT_USE_ALT_STR 2352 #define STID_BAD_CMDLINE_OPT_IGNORED 2353 #define STID_OBSOLETE_CMDLINE_ASSUME 2354 #define STID_INVALID_XDEF_IGNORED 2355 #define STID_OBSOLETE_XDEF_REPLACED 2356 #define STID_FILE_IS_MARKED_UNSAVABLE 2357 #define STID_ONLYONE_DBIM_OR_SBIM 2358 #define STID_DBIM_UNSUPPORTED 2359 #define STID_SBIM_UNSUPPORTED 2360 #define STID_CANNOT_OPEN_IN_SLIDESHOW 2361 #define STID_TOGGLE_AUTO_SCR_IN_CHAT 2362 #define STID_TOGGLE_BOLD_IN_CHAT 2363 #define STID_TOGGLE_ITALIC_IN_CHAT 2364 #define STID_SEND_CHAT_TEXT 2365 #define STID_MALFORMED_CHAT_LINE 2366 #define STID_UNRECOG_FIELD_IN_CHAT_LINE 2367 #define STID_UNRECOG_BYTE_FROM_SELF_PIPE 2368 #define STID_JOIN_WB_IN_PROGRESS_IGNORED 2369 #define STID_PEEK_AREA 2370 #define STID_CANT_DO_SAVEPAGESAS_IN_TILED 2371 #define STID_SPECIFY_PAGES_TO_SAVE_EX 2372 #define STID_ONE_PAGE_SAVED_INTO_GIVEN 2373 #define STID_MANY_PAGES_SAVED_INTO_GIVEN 2374 #define STID_CANT_IMP_ANIM_GIF_DIR_OR_PATH 2375 #define STID_WILL_EXPORT_PPM_FILE 2376 #define STID_NETPBM_VST_HOME_PAGE 2377 #define STID_SEL_PPM_FILE_TO_IMPORT 2378 #define STID_CANNOT_IMPORT_GIVEN_PPM 2379 #define STID_GIVEN_PPM_SIZE_FILE_IMPORTED 2380 #define STID_IMPORT_FORMAT_WHILE_EXEC_CMD 2381 #define STID_NO_OBJ_TO_IMP_WHILE_EXEC_CMD 2382 #define STID_CANNOT_LOAD_TGTWB5_FONT 2383 #define STID_TOOL_BIG5_CHINESE_KEYPAD 2384 #define STID_USE_ZYFH_KEYPAD_OR_PINYING 2385 #define STID_INVALID_PINYIN_SEQ 2386 #define STID_ADD_ZYFH 2387 #define STID_FETCH_CHAR 2388 #define STID_BACKOUT_ZYFH 2389 #define STID_SELECT_A_CHAR 2390 #define STID_SEND_A_CHAR_TO_DRAWING_AREA 2391 #define STID_CLICK_SEND_TO_SEND_CHAR 2392 #define STID_FETCH_CHARS_FROM_DB 2393 #define STID_SEND_SEL_CHAR_TO_DRAWING_AREA 2394 #define STID_SEND_CR_TO_DRAWING_AREA 2395 #define STID_OK_TO_RESET_GIVEN_IM 2396 #define STID_GIVEN_IM_RESETED 2397 #define STID_WILL_EXPORT_PBM_FILE 2398 #define STID_SEL_PBM_FILE_TO_IMPORT 2399 #define STID_CANNOT_IMPORT_GIVEN_PBM 2400 #define STID_GIVEN_PBM_SIZE_FILE_IMPORTED 2401 #define STID_WILL_EXPORT_PGM_FILE 2402 #define STID_SEL_PGM_FILE_TO_IMPORT 2403 #define STID_CANNOT_IMPORT_GIVEN_PGM 2404 #define STID_GIVEN_PGM_SIZE_FILE_IMPORTED 2405 #define STID_CANNOT_IDEN_GS 2406 #define STID_TOOL_NOT_INTV_WHILE_EXEC_CMD 2407 #define STID_CONVERT_TO_XBM_WHILE_EXEC_CMD 2408 #define STID_FUNC_ARG_STRS_RANGE 2409 #define STID_WARN_CANNOT_FIND_SOME_ATTRS 2410 #define STID_BAD_LINE_MAY_HAVE_DEL_EQUAL 2411 #define STID_ATTR_NAME_CHANGED_IMPORT_Q 2412 #define STID_CANT_IMPORT_ATTR_GROUP_RETRY 2413 #define STID_TGIF_FLAGS 2414 #define STID_INVALID_COMPILER_OPT 2415 #define STID_EXECUTING_GIVEN_SCRIPT 2416 #define STID_STAT_FAILED_WHILE_IMPORT_LINK 2417 #define STID_SEL_JPEG_FILE_TO_LINKTO 2418 #define STID_INVALID_PARAM_LINKED_JPEG 2419 #define STID_INVALID_PATH_WHILE_READ_JPEG 2420 #define STID_PRTGIF_LINK_JPEG_SKIPPED 2421 #define STID_DUP_SHORTCUT_FUNCTION_KEY 2422 #define STID_BAD_STYLE_NAME_WHILE_EXEC_CMD 2423 #define STID_CANT_ACQUIRE_X_SELECTION 2424 #define STID_NO_TEXT_SELECTED_FOR_COPY 2425 #define STID_PASTE_FAILED_CONV_REFUSED 2426 #define STID_BAD_XDEF_MISS_TOKEN_NAME_SKIP 2427 #define STID_BAD_XDEF_CANT_FIND_TOKEN_SKIP 2428 #define STID_BAD_XDEF_MISS_CHAR_NAME_SKIP 2429 #define STID_DUP_CHAR_CODE_XDEF_IGNORED 2430 #define STID_FAIL_TO_PARSE_CHAR_CODE_XDEF 2431 #define STID_CHAR_CODE_OUT_OF_RANGE_XDEF 2432 #define STID_BAD_FAKE_FONT_NAME_NO_ALIAS 2433 #define STID_CANT_FIND_PS_CHAR_SUBS_READ 2434 #define STID_DUP_TOKEN_PS_CHAR_SUBS_READ 2435 #define STID_FAIL_TO_PARSE_CHAR_CODE_FILE 2436 #define STID_CHAR_CODE_OUT_OF_RANGE_FILE 2437 #define STID_DUP_CHAR_CODE_FILE_IGNORED 2438 #define STID_CMDLINE_ARG_GIVEN_TOO_LONG 2439 #define STID_CANT_IMPORT_GIVEN_PPM_MALFORM 2440 #define STID_PPM6_DIM_NOT_MATCH 2441 #define STID_UNSUP_PPM6_MAX_VAL 2442 #define STID_JPEG_DIM_NOT_MATCH_DELETED 2443 #define STID_ENTER_XY_OFFSET_OBJ_SHADOW 2444 #define STID_OBJ_SHADOW_XY_OFFSETS_SET_TO 2445 #define STID_ENTER_A_COLOR_FOR_OBJ_SHADOW 2446 #define STID_OBJ_SHADOW_COLOR_SET_TO_NAMED 2447 #define STID_NO_OBJ_SHADOW_FOUND 2448 #define STID_TRANS_XPM_TOO_MANY_COLORS_SKP 2449 #define STID_NEED_DISABLE_UNDO_WILL_CRASH 2450 #define STID_CANT_LOAD_INITIAL_FONT 2451 #define STID_CANT_CHNG_FONT_SUPSUB_CENTER 2452 #define STID_JOIN_WB_IN_PROGRESS_FAILED 2453 #define STID_JOIN_WB_IN_FAILED_NO_CONTTYPE 2454 #define STID_INVALID_RMCAST_DLIB_PATH 2455 #define STID_NO_INFO_LIBRMCAST_SO 2456 #define STID_BAD_VER_RMCAST_DLIB 2457 #define STID_CANNOT_HANDLE_VER_RMCAST_DLIB 2458 #define STID_MISSING_RMCASTDIR 2459 #define STID_NO_PTHREAD_CONTINUE 2460 #define STID_INVALID_GIVEN_PARAM_GIVEN_OBJ 2461 #define STID_CANNOT_INFLATE_GIVEN_OBJ 2462 #define STID_BAD_LINE_READING_GIVEN_OBJ 2463 #define STID_INSUF_DATA_READING_GIVEN_OBJ 2464 #define STID_PATTERNDIR_NOT_EXIST 2465 #define STID_MISSING_RMCASTLIB 2466 #define STID_INVALID_XBM_CUST_PAT 2467 #define STID_TRANS_PIX_NOT_SUP_PPM_TRUE 2468 #define STID_XPM_HAS_ATTR_IMGPROC 2469 #define STID_PPM_TRUE_LOSSY_CONV_TO_XPM 2470 #define STID_SWITCHED_TO_AUTO_ROTATE_PIVOT 2471 #define STID_SWITCHED_TO_USER_ROTATE_PIVOT 2472 #define STID_NEW_ROTATE_PIVOT_IS 2473 #define STID_ENTER_ROT_PIVOT 2474 #define STID_ENTER_ROT_PIVOT_CUR_IS 2475 #define STID_ROT_PIVOT_SET_TO 2476 #define STID_VISIBLE_ROTATE_PIVOT 2477 #define STID_NOT_VISIBLE_ROTATE_PIVOT 2478 #define STID_SELONLYONEPOLYOBJ 2479 #define STID_SELONLYONEARCOBJ 2480 #define STID_WILL_EXPORT_SVG_FILE 2481 #define STID_TOOL_COLOR_WHEEL 2482 #define STID_COLOR_WHEEL_NOT_AVAIL 2483 #define STID_GIVEN_VAL_MUST_BE_LE 2484 #define STID_TWO_VERTEX_POLY_ONLY 2485 #define STID_ENTER_MULT_FACTOR 2486 #define STID_RES_LINESEG_HAVE_ZERO_LEN 2487 #define STID_WILL_USE_TIGHTER_SPLINES 2488 #define STID_WILL_USE_LOOSER_SPLINES 2489 #define STID_TWO_CONSEC_VERTICES_ONLY 2490 #define STID_LINE_TYPE_IS_STRUCT_SPLINE 2491 #define STID_ONE_V_STRUCT_SPLINE_IN_V_MODE 2492 #define STID_SHUTTING_DOWN_WHITEBOARD 2493 #define STID_SOME_LT_FAILED_TO_CONVERT 2494 #define STID_CANNOT_CONVERT_SEL_LINETYPE 2495 #define STID_CANNOT_CONVERT_TO_STRUCT_SPLN 2496 #define STID_ADD_HINGE_VERTEX 2497 #define STID_ADD_A_SMOOTH_VERTEX 2498 #define STID_CANNOT_ADD_SMOOTH_VERTEX 2499 #define STID_LEFT_ADD_HINGE_MID_ADD_SMOOTH 2500 #define STID_CLICK_RIGHT_BUTTON_TO_QUIT 2501 #define STID_SELECTION_CONV_REFUSED 2502 #define STID_TRY_PASTE_WITH_OLD_X_MECH 2503 #define STID_CANNOT_TOGGLE_FOR_STRUCT_SPLN 2504 #define STID_SEL_2_COMPAT_END_PTS_TO_JOIN 2505 #define STID_CANNOT_CUT_AT_SMOOTH_PT 2506 #define STID_RIGHT_MARGIN_IS 2507 #define STID_RIGHT_MARGIN_DISABLED 2508 #define STID_ENTER_RIGHT_MARGIN 2509 #define STID_CURRENT_RIGHT_MARGIN_IS 2510 #define STID_ERR_PARSE_THRESH_COLORS 2511 #define STID_FLOOD_REPLACE_ENABLED 2512 #define STID_FLOOD_REPLACE_DISABLED 2513 #define STID_SET_FLOOD_REPLACE_THRESH 2514 #define STID_FLOOD_REPLACE_THRESH_SET_TO 2515 #define STID_BADPNG_SHORT_HEADER 2516 #define STID_BADPNG_BAD_HEADER 2517 #define STID_BADPNG_BAD_PALETTE_LEN 2518 #define STID_BADPNG_BAD_CHUNK_LEN 2519 #define STID_BADPNG_SHORT_CHUNK_TYPE 2520 #define STID_BADPNG_SHORT_CRC 2521 #define STID_BAD_TRANS_COLOR_NO_TRANS 2522 #define STID_CUR_COLOR_IS_TRANS_PIXEL 2523 #define STID_BAD_CMD_FOR_TRANS_PPMTRUE 2524 #define STID_SEL_ONE_XPM_TRANSPIX 2525 #define STID_CANNOT_FIND_GOOD_TRANSPIX 2526 #define STID_CANNOT_SET_XDEF_TRUE_NO_ZLIB 2527 #define STID_BAD_GIVEN_LINE_WRITTEN 2528 #define STID_TWO_XDEF_ONE_IGNORED 2529 #define STID_BAD_ENCODING_TGTWB5_FONT 2530 #define STID_TOOL_GB_CHINESE_KEYPAD 2531 #define MAXNONCACHEDSTIDS 2532 extern struct MouseStatusStrRec colorMouseStatus[]; extern struct MouseStatusStrRec hAlignMouseStatus[]; extern struct MouseStatusStrRec vAlignMouseStatus[]; extern struct MouseStatusStrRec pageMouseStatus[]; extern struct MouseStatusStrRec pageLayoutMouseStatus[]; extern struct MouseStatusStrRec justMouseStatus[]; extern struct MouseStatusStrRec fontMouseStatus[]; extern struct MouseStatusStrRec vspaceMouseStatus[]; extern struct MouseStatusStrRec textSizeMouseStatus[]; extern struct MouseStatusStrRec lineWidthMouseStatus[]; extern struct MouseStatusStrRec lineStyleMouseStatus[]; extern struct MouseStatusStrRec lineTypeMouseStatus[]; extern struct MouseStatusStrRec lineDashMouseStatus[]; extern struct MouseStatusStrRec rcbRadiusMouseStatus[]; extern struct MouseStatusStrRec zoomMouseStatus[]; extern struct MouseStatusStrRec moveModeMouseStatus[]; extern struct MouseStatusStrRec shapeMouseStatus[]; extern struct MouseStatusStrRec stretchableTextModeMouseStatus[]; extern struct MouseStatusStrRec fileMouseStatus[]; extern struct MouseStatusStrRec fillMouseStatus[]; extern struct MouseStatusStrRec penMouseStatus[]; extern struct MouseStatusStrRec transPatMouseStatus[]; extern struct MouseStatusStrRec autoRotatePivotMouseStatus[]; #ifdef _INCLUDE_FROM_STRTBL_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_STRTBL_C_*/ extern char *TgLoadCachedString ARGS_DECL((int nID)); extern char *TgLoadString ARGS_DECL((int nID)); extern char *DistrDirectLoadString ARGS_DECL((int nIndex)); extern char *AlignedLoadString ARGS_DECL((int hori_align, int vert_align)); extern char *HoriAlignLoadString ARGS_DECL((int hori_align)); extern char *VertAlignLoadString ARGS_DECL((int vert_align)); extern char *AlignDirectLoadString ARGS_DECL((int nIndex)); extern char *AlignDirectToGridLoadString ARGS_DECL((int nIndex)); extern char *AlignDirectToPageLoadString ARGS_DECL((int nIndex)); extern char *AlignVerticesDirectToPageLoadString ARGS_DECL((int nIndex)); extern void SetCurChoiceMouseStatusStrings ARGS_DECL((int choice, int left_is_none, struct ObjRec *, int cur_text_under_mouse, unsigned int state)); extern void QuickSetMouseStatus ARGS_DECL((struct MouseStatusStrRec *pmssr, int index)); extern void SetColorMouseStatusStrings ARGS_DECL((int index, int shift_or_cntrl_down)); extern char *PropLoadString ARGS_DECL((long lWhich)); extern char *ExportFormatMenuLoadString ARGS_DECL((int where_to_print, int color_dump)); extern void SetMouseStatusToAllNone ARGS_DECL((void)); extern void CleanUpStrTable ARGS_DECL((void)); extern void InitStrTable ARGS_DECL((void)); #ifdef _INCLUDE_FROM_STRTBL_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_STRTBL_C_*/ #endif /*_TGIF_STRTBL_E_*/ �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/pin.e��������������������������������������������������������������������������������0000644�0000764�0000764�00000003654�11602233312�013730� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/pin.e,v 1.6 2011/05/16 16:21:58 william Exp $ */ #ifndef _PIN_E_ #define _PIN_E_ extern int drawPolyToConnectPins; extern struct ObjRec *gpStartPin, *gpEndPin; #ifdef _INCLUDE_FROM_PIN_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_PIN_C_*/ extern int FindExtraPoly ARGS_DECL((struct SelRec *pTopSel, struct SelRec *pBotSel, struct SelRec **ppTopSel, struct SelRec **ppBotSel, int *pnCount, struct BBRec *pBBox)); extern void HighLightAPin ARGS_DECL((int nForward)); extern void HandlePinHighlights ARGS_DECL((int MouseX, int MouseY)); extern void ConnectPins ARGS_DECL((void)); extern void FreeConn ARGS_DECL((struct ConnRec *pConn)); extern void DelConnFromPoly ARGS_DECL((struct ConnRec *pConn)); extern void DelConnFromPin ARGS_DECL((struct ConnRec *pConn)); extern void CleanUpPins ARGS_DECL((void)); extern int InitPins ARGS_DECL((void)); #ifdef _INCLUDE_FROM_PIN_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_PIN_C_*/ #endif /*_PIN_E_*/ ������������������������������������������������������������������������������������tgif-QPL-4.2.5/eq4png.sym���������������������������������������������������������������������������0000644�0000764�0000764�00000056233�11602233311�014724� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.46 state(0,37,100.000,0,64,0,32,1,3,1,1,0,0,1,0,1,0,'Courier',0,57600,0,0,0,10,0,0,1,1,0,16,1,0,1,1,1,0,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/eq4png.sym,v 1.2 2009/07/07 02:22:11 cvsps Exp $ % %W% % unit("1 pixel/pixel"). shapeshadow(3,3). color_info(15,65535,1,[ "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1, "#ff0000", 65535, 0, 0, 65280, 0, 0, 1, "#00ff00", 0, 65535, 0, 0, 65280, 0, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ffff00", 65535, 65535, 0, 65280, 65280, 0, 1, "#000000", 0, 0, 0, 0, 0, 0, 1, "#ffffff", 65535, 65535, 65535, 65280, 65280, 65280, 1, "#ff8000", 65535, 32896, 0, 65280, 32768, 0, 1, "#ffce00", 65535, 52942, 0, 65280, 52736, 0, 1, "#d02090", 53456, 8224, 37008, 53248, 8192, 36864, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1 ]). slideshow_info('#0000b2',-50,-130). script_frac("0.6"). fg_bg_colors('#0000ff','#ffff00'). dont_reencode("UtopiaFS:FFDingbests:ZapfDingbats"). ps_font_aliases([ "UtopiaFS-Regular=Utopia-Regular", "UtopiaFS-Bold=Utopia-Bold", "UtopiaFS-Italic=Utopia-Italic", "UtopiaFS-BoldItalic=Utopia-BoldItalic" ]). objshadow_info('#c0c0c0',2,2). rotate_pivot(0,0,0,0). spline_tightness(1). page(1,"LaTeX equation symbol (uses ps2epsi).",1,''). group([ text('#0000ff',192,229,22,0,1,355,265,1059,11,2,0,-1,0,0,2,355,265,-1,1,"",0,0,0,0,240,'',[ minilines(355,265,-1,1,0,-1,0,[ mini_line(295,11,2,0,1,0,[ str_block(0,79,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,79,11,2,0,-2,0,0,0,0,0, "Make sure that ")]), str_block(0,24,11,2,0,1,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,57600,24,11,2,0,1,0,0,0,0,0, "latex")]), str_block(0,6,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,6,11,2,0,-2,0,0,0,0,0, ", ")]), str_block(0,27,11,2,0,0,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,57600,27,11,2,0,0,0,0,0,0,0, "dvips")]), str_block(0,6,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,6,11,2,0,-2,0,0,0,0,0, ", ")]), str_block(0,113,11,2,0,-2,0,0,0,[ str_seg('#0000ff','Helvetica-BoldOblique',3,57600,113,11,2,0,-2,0,0,0,0,0, "convert (ImageMagic) ")]), str_block(0,40,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,40,11,2,0,-2,0,0,0,0,0, "and the ")]) ]), mini_line(167,11,2,-1,0,0,[ str_block(0,40,11,2,0,-2,0,0,0,[ str_seg('blue','Helvetica-BoldOblique',3,57600,40,11,2,0,-2,0,0,0,0,0, "netpbm ")]), str_block(0,100,11,2,-1,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,100,11,2,-1,-2,0,0,0,0,0, "package are in your ")]), str_block(0,24,9,2,-1,-1,0,0,0,[ str_seg('#ff00ff','Courier-Bold',1,57600,24,9,2,-1,-1,0,0,0,0,0, "PATH")]), str_block(0,3,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,3,11,2,0,-1,0,0,0,0,0, ".")]) ]), mini_line(321,11,2,0,0,0,[ str_block(0,321,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,321,11,2,0,-2,0,0,0,0,0, "After you instantiate this symbol, you can change the resolution ")]) ]), mini_line(290,11,2,0,0,0,[ str_block(0,42,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,42,9,2,0,-1,0,0,0,0,0, "density")]), str_block(0,3,11,2,0,-2,0,0,0,[ str_seg('green','Helvetica-BoldOblique',3,57600,3,11,2,0,-2,0,0,0,0,0, " ")]), str_block(0,40,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,40,11,2,0,-2,0,0,0,0,0, "and the ")]), str_block(0,48,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,48,9,2,0,-1,0,0,0,0,0, "geometry")]), str_block(0,3,11,2,0,-2,0,0,0,[ str_seg('green','Helvetica-BoldOblique',3,57600,3,11,2,0,-2,0,0,0,0,0, " ")]), str_block(0,154,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,154,11,2,0,-1,0,0,0,0,0, "in order to enhance the quality.")]) ]), mini_line(319,11,2,0,0,0,[ str_block(0,319,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,319,11,2,0,-2,0,0,0,0,0, "In addition, you can set the number of colors used in the image. ")]) ]), mini_line(313,11,2,0,0,0,[ str_block(0,55,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,55,11,2,0,-2,0,0,0,0,0, "To do this, ")]), str_block(0,50,11,2,0,0,0,0,0,[ str_seg('magenta','Helvetica-BoldOblique',3,57600,50,11,2,0,0,0,0,0,0,0, "right-click")]), str_block(0,208,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,208,11,2,0,0,0,0,0,0,0, " on the symbol and choose \"Edit Attribute")]) ]), mini_line(329,11,2,0,0,0,[ str_block(0,159,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,159,11,2,0,-2,0,0,0,0,0, "in Editor\". Ther you can find the ")]), str_block(0,48,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,48,9,2,0,-1,0,0,0,0,0, "density=")]), str_block(0,25,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,25,11,2,0,-2,0,0,0,0,0, ", the ")]), str_block(0,54,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,54,9,2,0,-1,0,0,0,0,0, "geometry=")]), str_block(0,43,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,43,11,2,0,-2,0,0,0,0,0, " and the ")]) ]), mini_line(355,11,2,0,0,0,[ str_block(0,48,9,2,0,-5,0,0,0,[ str_seg('blue','Courier',0,57600,48,9,2,0,-5,0,0,0,0,0, "colors= ")]), str_block(0,307,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,307,11,2,0,0,0,0,0,0,0, "Attributes. The default values already give quite a reasonable")]) ]), mini_line(326,11,2,0,1,0,[ str_block(0,326,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,326,11,2,0,1,0,0,0,0,0, "quality of the equation image. Under this menue, you can also find")]) ]), mini_line(316,11,2,0,0,0,[ str_block(0,19,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,19,11,2,0,-2,0,0,0,0,0, "the ")]), str_block(0,18,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,18,9,2,0,-1,0,0,0,0,0, "eq=")]), str_block(0,279,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,279,11,2,0,-1,0,0,0,0,0, " Attribute, where you can edit the equation in TeX-style.")]) ]), mini_line(328,11,2,0,1,0,[ str_block(0,129,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,129,11,2,0,-2,0,0,0,0,0, "As soon as the symbol is ")]), str_block(0,60,11,2,0,0,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,57600,60,11,2,0,0,0,0,0,0,0, "double-click")]), str_block(0,139,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,139,11,2,0,1,0,0,0,0,0, "ed for the first time, you will")]) ]), mini_line(329,11,2,0,0,0,[ str_block(0,329,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,329,11,2,0,0,0,0,0,0,0, "be prompted for an equation name, which you just can answer with")]) ]), mini_line(339,11,2,0,0,0,[ str_block(0,37,11,2,0,-1,0,0,0,[ str_seg('magenta','Helvetica-BoldOblique',3,57600,37,11,2,0,-1,0,0,0,0,0, "ENTER,")]), str_block(0,302,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,302,11,2,0,0,0,0,0,0,0, " if you don't need to refer to the equation. The equation name")]) ]), mini_line(324,11,2,0,0,0,[ str_block(0,324,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,324,11,2,0,0,0,0,0,0,0, "will then be a unique number. After this the LaTeX scripts will run")]) ]), mini_line(171,11,2,0,0,0,[ str_block(0,171,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,171,11,2,0,-2,0,0,0,0,0, "as well as the image conversions. ")]) ]), mini_line(347,11,2,0,1,0,[ str_block(0,28,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,28,11,2,0,-2,0,0,0,0,0, "If the ")]), str_block(0,30,9,2,0,-1,0,0,0,[ str_seg('blue','Courier',0,57600,30,9,2,0,-1,0,0,0,0,0, "proc=")]), str_block(0,94,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,94,11,2,0,-2,0,0,0,0,0, " attribute contains ")]), str_block(0,18,9,2,0,0,0,0,0,[ str_seg('blue','Courier',0,57600,18,9,2,0,0,0,0,0,0,0, "cmd")]), str_block(0,177,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,177,11,2,0,1,0,0,0,0,0, ", then the image will directly appear")]) ]), mini_line(327,11,2,-1,0,0,[ str_block(0,98,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,98,11,2,0,-2,0,0,0,0,0, "in tgif. If it contains ")]), str_block(0,24,9,2,0,0,0,0,0,[ str_seg('blue','Courier',0,57600,24,9,2,0,0,0,0,0,0,0, "ecmd")]), str_block(0,31,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,31,11,2,0,-2,0,0,0,0,0, ", then ")]), str_block(0,11,11,2,-1,0,0,0,0,[ str_seg('blue','Helvetica-BoldOblique',3,57600,11,11,2,-1,0,0,0,0,0,0, "xv")]), str_block(0,163,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,163,11,2,0,0,0,0,0,0,0, " will be launched before inclusion")]) ]), mini_line(348,11,2,0,0,0,[ str_block(0,348,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,348,11,2,0,0,0,0,0,0,0, "of the equation image. You then have the possibility to manipulate the")]) ]), mini_line(337,11,2,0,1,0,[ str_block(0,337,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,337,11,2,0,1,0,0,0,0,0, "image. NOTE that you have to save the image then as XPM and quit")]) ]), mini_line(189,11,2,-1,0,0,[ str_block(0,11,11,2,-1,0,0,0,0,[ str_seg('blue','Helvetica-BoldOblique',3,57600,11,11,2,-1,0,0,0,0,0,0, "xv")]), str_block(0,178,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,178,11,2,0,-1,0,0,0,0,0, " in order to include the image in tgif.")]) ]), mini_line(316,11,2,0,1,0,[ str_block(0,21,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,21,11,2,0,-2,0,0,0,0,0, "The ")]), str_block(0,18,9,2,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,57600,18,9,2,0,-1,0,0,0,0,0, "eq=")]), str_block(0,277,11,2,0,1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,277,11,2,0,1,0,0,0,0,0, "attribute visible in the beginning is hidden after the first")]) ]), mini_line(60,11,2,0,0,0,[ str_block(0,60,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,60,11,2,0,-1,0,0,0,0,0, "compilation.")]) ]) ])]), text('#0000ff',192,194,3,0,1,257,37,643,11,2,0,-1,0,0,2,257,37,0,0,"",0,0,0,0,205,'',[ minilines(257,37,0,0,0,-1,0,[ mini_line(221,11,2,0,0,0,[ str_block(0,136,11,2,0,-2,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,136,11,2,0,-2,0,0,0,0,0, "Make sure you are running ")]), str_block(0,36,11,2,0,0,0,0,0,[ str_seg('#ff00ff','Helvetica-BoldOblique',3,57600,36,11,2,0,0,0,0,0,0,0, "tgif-4.2")]), str_block(0,49,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,49,11,2,0,-1,0,0,0,0,0, " or newer.")]) ]), mini_line(257,11,2,0,0,0,[ str_block(0,257,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,257,11,2,0,0,0,0,0,0,0, "You can find out what version of tgif you are running")]) ]), mini_line(219,11,2,0,0,0,[ str_block(0,219,11,2,0,-1,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,219,11,2,0,-1,0,0,0,0,0, "by selecting About() from the Special menu.")]) ]) ])]), text('#0000ff',160,229,1,0,1,16,13,848,11,2,0,0,0,0,2,16,13,0,0,"",0,0,0,0,240,'',[ minilines(16,13,0,0,0,0,0,[ mini_line(16,11,2,0,0,0,[ str_block(0,16,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,16,11,2,0,0,0,0,0,0,0, "(2)")]) ]) ])]), text('#0000ff',160,194,1,0,1,16,13,863,11,2,0,0,0,0,2,16,13,0,0,"",0,0,0,0,205,'',[ minilines(16,13,0,0,0,0,0,[ mini_line(16,11,2,0,0,0,[ str_block(0,16,11,2,0,0,0,0,0,[ str_seg('red','Helvetica-BoldOblique',3,57600,16,11,2,0,0,0,0,0,0,0, "(1)")]) ]) ])]) ], 13509,0,0,[ ]). sym([ polygon('yellow','',5,[ 64,150,128,150,128,134,64,134,64,150],0,1,0,0,212,0,0,0,0,0,'1',0, "00",[ ]) ], 593,0,0,[ attr("ecmd=", "", 0, 1, 0, text('blue',160,449,6,0,1,1215,96,14196,13,3,0,0,0,0,2,1215,96,0,0,"",0,0,0,0,462,'',[ minilines(1215,96,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "ecmd=")]) ]), mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-4,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(459,13,3,0,0,0,[ str_block(0,459,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,459,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e latex $(file_name);")]) ]), mini_line(711,13,3,0,0,0,[ str_block(0,711,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,711,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e dvips -E -n 1 -o $(file_name).eps $(file_name);")]) ]), mini_line(1215,13,3,0,0,0,[ str_block(0,1215,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1215,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e convert -geometry $(geometry) -density $(density) -colors $(colors) $(file_name).eps $(file_name).ppm;")]) ]), mini_line(369,13,3,0,0,0,[ str_block(0,369,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,369,13,3,0,-4,0,0,0,0,0, " xv -geometry +50+50 $(file_name).ppm;")]) ]) ])])), attr("eq=", "", 1, 1, 0, text('blue',160,98,5,0,1,135,80,25,13,3,0,0,0,0,2,135,80,0,0,"",0,0,0,0,111,'',[ minilines(135,80,0,0,0,0,0,[ mini_line(27,13,3,0,0,0,[ str_block(0,27,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,27,13,3,0,-1,0,0,0,0,0, "eq=")]) ]), mini_line(54,13,3,0,0,0,[ str_block(0,54,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,54,13,3,0,-1,0,0,0,0,0, "\\LARGE")]) ]), mini_line(18,13,3,0,0,0,[ str_block(0,18,13,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,18,13,3,0,-3,0,0,0,0,0, "\\[")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,135,13,3,0,-2,0,0,0,0,0, " E\\,=\\,M\\,C^2")]) ]), mini_line(18,13,3,0,0,0,[ str_block(0,18,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,18,13,3,0,-4,0,0,0,0,0, "\\]")]) ]) ])])), attr("file_name=", "", 0, 1, 0, text('blue',161,939,1,0,1,90,16,29,13,3,0,0,0,0,2,90,16,0,0,"",0,0,0,0,952,'',[ minilines(90,16,0,0,0,0,0,[ mini_line(90,13,3,0,0,0,[ str_block(0,90,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,90,13,3,0,-1,0,0,0,0,0, "file_name=")]) ]) ])])), attr("cleanup=", "", 0, 1, 0, text('blue',162,644,4,0,1,675,64,14750,13,3,0,0,0,0,2,675,64,0,0,"",0,0,0,0,657,'',[ minilines(675,64,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "cleanup=")]) ]), mini_line(540,13,3,0,0,0,[ str_block(0,540,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,540,13,3,0,-2,0,0,0,0,0, " rm -f $(file_name).tex $(file_name).aux $(file_name).dvi")]) ]), mini_line(513,13,3,0,0,0,[ str_block(0,513,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,513,13,3,0,-2,0,0,0,0,0, " $(file_name).log $(file_name).ps $(file_name).eps")]) ]), mini_line(675,13,3,0,0,0,[ str_block(0,675,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,675,13,3,0,-1,0,0,0,0,0, " $(file_name).ppm $(file_name).xpm $(file_name).gif $(file_name).png")]) ]) ])])), attr("exec=", "", 0, 1, 0, text('blue',161,179,14,0,1,477,224,14710,13,3,0,0,0,0,2,477,224,0,0,"",0,0,0,0,192,'',[ minilines(477,224,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "exec=")]) ]), mini_line(378,13,3,0,0,0,[ str_block(0,378,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,378,13,3,0,-4,0,0,0,0,0, " mktemp(\"/tmp/TgifXXXXXX\",\"file_name\");")]) ]), mini_line(306,13,3,0,0,0,[ str_block(0,306,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,306,13,3,0,-4,0,0,0,0,0, " strlen(name_assigned,$(name));")]) ]), mini_line(405,13,3,0,0,0,[ str_block(0,405,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,405,13,3,0,-4,0,0,0,0,0, " if($(name_assigned)==0,assign_name,NULL);")]) ]), mini_line(306,13,3,0,0,0,[ str_block(0,306,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,306,13,3,0,-4,0,0,0,0,0, " strlen(name_assigned,$(name));")]) ]), mini_line(468,13,3,0,0,0,[ str_block(0,468,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,468,13,3,0,-4,0,0,0,0,0, " if($(name_assigned)==0,assign_random_name,NULL);")]) ]), mini_line(468,13,3,0,0,0,[ str_block(0,468,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,468,13,3,0,-4,0,0,0,0,0, " write_attr_into_file(header,\"$(file_name).tex\");")]) ]), mini_line(441,13,3,0,0,0,[ str_block(0,441,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,441,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(eq,\"$(file_name).tex\");")]) ]), mini_line(477,13,3,0,0,0,[ str_block(0,477,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,477,13,3,0,-4,0,0,0,0,0, " append_attr_into_file(footer,\"$(file_name).tex\");")]) ]), mini_line(180,13,3,0,0,0,[ str_block(0,180,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,180,13,3,0,-4,0,0,0,0,0, " launch($(proc));")]) ]), mini_line(369,13,3,0,0,0,[ str_block(0,369,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,369,13,3,0,-4,0,0,0,0,0, " update_xpm_child(\"$(file_name).png\");")]) ]), mini_line(288,13,3,0,0,0,[ str_block(0,288,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,288,13,3,0,-4,0,0,0,0,0, " select_obj_by_name($(name));")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,162,13,3,0,-4,0,0,0,0,0, " hide_attr(eq);")]) ]), mini_line(189,13,3,0,0,0,[ str_block(0,189,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,189,13,3,0,-4,0,0,0,0,0, " launch(\"cleanup\")")]) ]) ])])), attr("header=", "", 0, 1, 0, text('#0000ff',161,711,11,0,1,270,176,14136,13,3,0,0,0,0,2,270,176,0,0,"",0,0,0,0,724,'',[ minilines(270,176,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "header=")]) ]), mini_line(261,13,3,0,0,0,[ str_block(0,261,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,261,13,3,0,-4,0,0,0,0,0, "\\documentclass[12pt]{article}")]) ]), mini_line(162,13,3,0,0,0,[ str_block(0,162,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,162,13,3,0,-1,0,0,0,0,0, "\\oddsidemargin=0in")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,3,0,-1,0,0,0,0,0, "\\textwidth=6.5in")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,13,3,0,-2,0,0,0,0,0, "\\topmargin=0pt")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,13,3,0,-2,0,0,0,0,0, "\\textheight=609pt")]) ]), mini_line(117,13,3,0,0,0,[ str_block(0,117,13,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,117,13,3,0,-2,0,0,0,0,0, "\\parskip=14pt")]) ]), mini_line(270,13,3,0,0,0,[ str_block(0,270,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,270,13,3,0,-4,0,0,0,0,0, "\\setlength{\\unitlength}{0.5cm}")]) ]), mini_line(153,13,3,0,0,0,[ str_block(0,153,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,13,3,0,-4,0,0,0,0,0, "\\pagestyle{empty}")]) ]), mini_line(144,13,3,0,0,0,[ str_block(0,144,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,13,3,0,-4,0,0,0,0,0, "\\begin{document}")]) ]), mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,13,3,0,-1,0,0,0,0,0, "%")]) ]) ])])), attr("footer=", "", 0, 1, 0, text('#ff00ff',162,887,3,0,1,126,48,613,13,3,0,0,0,0,2,126,48,0,0,"",0,0,0,0,900,'',[ minilines(126,48,0,0,0,0,0,[ mini_line(63,13,3,0,0,0,[ str_block(0,63,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,13,3,0,-1,0,0,0,0,0, "footer=")]) ]), mini_line(9,13,3,0,0,0,[ str_block(0,9,13,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,13,3,0,-1,0,0,0,0,0, "%")]) ]), mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,13,3,0,-4,0,0,0,0,0, "\\end{document}")]) ]) ])])), attr("", "not_rigid", 0, 1, 0, text('blue',161,953,1,0,1,81,16,535,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,966,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-1,0,0,0,0,0, "not_rigid")]) ]) ])])), attr("name=", "", 0, 1, 0, text('blue',161,5,1,0,1,45,16,13584,13,3,0,0,0,0,2,45,16,0,0,"",0,0,0,0,18,'',[ minilines(45,16,0,0,0,0,0,[ mini_line(45,13,3,0,0,0,[ str_block(0,45,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,13,3,0,-1,0,0,0,0,0, "name=")]) ]) ])])), attr("name_assigned=", "", 0, 1, 0, text('blue',161,21,1,0,1,126,16,13738,13,3,0,0,0,0,2,126,16,0,0,"",0,0,0,0,34,'',[ minilines(126,16,0,0,0,0,0,[ mini_line(126,13,3,0,0,0,[ str_block(0,126,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,126,13,3,0,-1,0,0,0,0,0, "name_assigned=")]) ]) ])])), attr("assign_name=", "", 0, 1, 0, text('blue',161,37,2,0,1,1413,32,14586,13,3,0,0,0,0,2,1413,32,0,0,"",0,0,0,0,50,'',[ minilines(1413,32,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "assign_name=")]) ]), mini_line(1413,13,3,0,0,0,[ str_block(0,1413,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1413,13,3,0,-4,0,0,0,0,0, " get_user_input(name,\"Please give a name to this equation object:\",\"( A random name will be assigned if an empty string is entered or <ESC> is pressed. )\");")]) ]) ])])), attr("assign_random_name=", "", 0, 1, 0, text('blue',161,69,2,0,1,171,32,13960,13,3,0,0,0,0,2,171,32,0,0,"",0,0,0,0,82,'',[ minilines(171,32,0,0,0,0,0,[ mini_line(171,13,3,0,0,0,[ str_block(0,171,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,171,13,3,0,-1,0,0,0,0,0, "assign_random_name=")]) ]), mini_line(135,13,3,0,0,0,[ str_block(0,135,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,135,13,3,0,-4,0,0,0,0,0, " new_id(name);")]) ]) ])])), attr("geometry=", "25%", 0, 1, 0, text('blue',161,401,1,0,1,108,16,14529,13,3,0,0,0,0,2,108,16,0,0,"",0,0,0,0,414,'',[ minilines(108,16,0,0,0,0,0,[ mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-1,0,0,0,0,0, "geometry=25%")]) ]) ])])), attr("density=", "576", 0, 1, 0, text('blue',161,413,1,0,1,99,16,14548,13,3,0,0,0,0,2,99,16,0,0,"",0,0,0,0,426,'',[ minilines(99,16,0,0,0,0,0,[ mini_line(99,13,3,0,0,0,[ str_block(0,99,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,99,13,3,0,-2,0,0,0,0,0, "density=576")]) ]) ])])), attr("cmd=", "", 0, 1, 0, text('blue',160,545,5,0,1,1197,80,14690,13,3,0,0,0,0,2,1197,80,0,0,"",0,0,0,0,558,'',[ minilines(1197,80,0,0,0,0,0,[ mini_line(36,13,3,0,0,0,[ str_block(0,36,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,36,13,3,0,-1,0,0,0,0,0, "cmd=")]) ]), mini_line(108,13,3,0,0,0,[ str_block(0,108,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,108,13,3,0,-4,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(459,13,3,0,0,0,[ str_block(0,459,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,459,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e latex $(file_name);")]) ]), mini_line(702,13,3,0,0,0,[ str_block(0,702,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,702,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e dvips -E -n 1 -o $(file_name).ps $(file_name);")]) ]), mini_line(1197,13,3,0,0,0,[ str_block(0,1197,13,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1197,13,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e convert -geometry $(geometry) -density $(density) -colors $(colors) $(file_name).ps $(file_name).png;")]) ]) ])])), attr("proc=", "cmd", 0, 1, 0, text('blue',161,437,1,0,1,72,16,14332,13,3,0,0,0,0,2,72,16,0,0,"",0,0,0,0,450,'',[ minilines(72,16,0,0,0,0,0,[ mini_line(72,13,3,0,0,0,[ str_block(0,72,13,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,13,3,0,-1,0,0,0,0,0, "proc=cmd")]) ]) ])])), attr("colors=", "16", 0, 1, 0, text('blue',161,425,1,0,1,81,16,14647,13,3,0,0,0,0,2,81,16,0,0,"",0,0,0,0,438,'',[ minilines(81,16,0,0,0,0,0,[ mini_line(81,13,3,0,0,0,[ str_block(0,81,13,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,81,13,3,0,-2,0,0,0,0,0, "colors=16")]) ]) ])])) ]). ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/NEWS���������������������������������������������������������������������������������0000644�0000764�0000764�00000000055�11602233312�013463� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������Please see: http;//bourbon.usc.edu/tgif �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/stretch.c����������������������������������������������������������������������������0000644�0000764�0000764�00000734413�11602233313�014621� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/stretch.c,v 1.63 2011/05/16 16:21:59 william Exp $ */ #define _INCLUDE_FROM_STRETCH_C_ #include "tgifdefs.h" #include "cmdids.h" #include "align.e" #include "arc.e" #include "auxtext.e" #include "choice.e" #include "cmd.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "exec.e" #include "file.e" #include "font.e" #include "grid.e" #include "mainloop.e" #include "mainmenu.e" #include "mark.e" #include "menu.e" #include "menuinfo.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "navigate.e" #include "obj.e" #include "page.e" #include "poly.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "scroll.e" #include "select.e" #include "setup.e" #include "spline.e" #include "stretch.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "xbitmap.e" #include "xpixmap.e" int stretchableText=FALSE; int compoundObjWithTextStretchableForPSE=TRUE; int rotationIncrement=(45<<6); /* degrees*64 */ int autoRotatePivot=FALSE; int rotatePivotAbsXYValid=FALSE; int rotatePivotAbsX=0; int rotatePivotAbsY=0; static int stretchingEverything=FALSE; static int PtIn4Corners(XOff, YOff, BBox, Corner) int XOff, YOff, * Corner; struct BBRec BBox; { if (PtInMark(XOff, YOff, OFFSET_X(BBox.ltx), OFFSET_Y(BBox.lty))) { *Corner = 1; return TRUE; } if (PtInMark(XOff, YOff, OFFSET_X(BBox.ltx), OFFSET_Y(BBox.rby))) { *Corner = 7; return TRUE; } if (PtInMark(XOff, YOff, OFFSET_X(BBox.rbx), OFFSET_Y(BBox.lty))) { *Corner = 3; return TRUE; } if (PtInMark(XOff, YOff, OFFSET_X(BBox.rbx), OFFSET_Y(BBox.rby))) { *Corner = 5; return TRUE; } return FALSE; } static int PtIn8Places(XOff, YOff, BBox, Corner) int XOff, YOff, *Corner; struct BBRec BBox; { register int xmid, ymid; if (PtIn4Corners(XOff, YOff, BBox, Corner)) return TRUE; xmid = ((BBox.ltx+BBox.rbx)>>1); if (PtInMark(XOff, YOff, OFFSET_X(xmid), OFFSET_Y(BBox.lty))) { *Corner = 2; return TRUE; } if (PtInMark(XOff, YOff, OFFSET_X(xmid), OFFSET_Y(BBox.rby))) { *Corner = 6; return TRUE; } ymid = ((BBox.lty+BBox.rby)>>1); if (PtInMark(XOff, YOff, OFFSET_X(BBox.ltx), OFFSET_Y(ymid))) { *Corner = 8; return TRUE; } if (PtInMark(XOff, YOff, OFFSET_X(BBox.rbx), OFFSET_Y(ymid))) { *Corner = 4; return TRUE; } return FALSE; } int PtInPolyMark(ObjPtr, XOff, YOff, NumPts, V, Index) struct ObjRec *ObjPtr; int XOff, YOff, NumPts, * Index; IntPoint *V; { int i; if (ObjPtr->ctm == NULL) { for (i = 0; i < NumPts; i++) { if (PtInMark(XOff, YOff, OFFSET_X(V[i].x), OFFSET_Y(V[i].y))) { *Index = i; return TRUE; } } } else { for (i = 0; i < NumPts; i++) { int x, y; TransformPointThroughCTM(V[i].x-ObjPtr->x, V[i].y-ObjPtr->y, ObjPtr->ctm, &x, &y); if (PtInMark(XOff, YOff, OFFSET_X(x+ObjPtr->x), OFFSET_Y(y+ObjPtr->y))) { *Index = i; return TRUE; } } } return FALSE; } int RetractedArrowAttr(obj_ptr) struct ObjRec *obj_ptr; { register struct AttrRec *attr_ptr; if (obj_ptr->type != OBJ_POLY) return FALSE; if (obj_ptr->detail.p->n <= 2) return FALSE; for (attr_ptr=obj_ptr->lattr; attr_ptr!=NULL; attr_ptr=attr_ptr->prev) { if (*attr_ptr->attr_name.s=='\0' && strcmp(attr_ptr->attr_value.s, "retracted_arrows")==0) { return TRUE; } } return FALSE; } int AutoRetractedArrowAttr(obj_ptr, check_v_count) /* if check_v_count == TRUE: return FALSE if poly_ptr->n != 3 */ /* if check_v_count == FALSE: skip the poly_ptr->n check */ struct ObjRec *obj_ptr; int check_v_count; { register struct AttrRec *attr_ptr; if (obj_ptr->type == OBJ_POLY) { struct PolyRec *poly_ptr=obj_ptr->detail.p; if (poly_ptr->style == LS_PLAIN || poly_ptr->style == LS_DOUBLE || (check_v_count && poly_ptr->n != 3)) { return FALSE; } } else { return FALSE; } for (attr_ptr=obj_ptr->lattr; attr_ptr!=NULL; attr_ptr=attr_ptr->prev) { if (*attr_ptr->attr_name.s=='\0' && strcmp(attr_ptr->attr_value.s, "auto_retracted_arrows")==0) { return TRUE; } } return FALSE; } int AutoCenterAttr(obj_ptr) struct ObjRec *obj_ptr; { register struct AttrRec *attr_ptr; for (attr_ptr=obj_ptr->lattr; attr_ptr!=NULL; attr_ptr=attr_ptr->prev) { if (*attr_ptr->attr_name.s=='\0' && strcmp(attr_ptr->attr_value.s, "auto_center_attr")==0) { return TRUE; } } return FALSE; } void CenterObjInOBBox(TextObjPtr, OBBox, BBoxReturn) struct ObjRec *TextObjPtr; struct BBRec OBBox, *BBoxReturn; { int text_w, text_h, bbox_w, bbox_h, dx, dy; if (BBoxReturn != NULL) { BBoxReturn->ltx = TextObjPtr->bbox.ltx; BBoxReturn->lty = TextObjPtr->bbox.lty; BBoxReturn->rbx = TextObjPtr->bbox.rbx; BBoxReturn->rby = TextObjPtr->bbox.rby; } text_w = TextObjPtr->obbox.rbx-TextObjPtr->obbox.ltx; text_h = TextObjPtr->obbox.rby-TextObjPtr->obbox.lty; bbox_w = OBBox.rbx - OBBox.ltx; bbox_h = OBBox.rby - OBBox.lty; if (text_w > bbox_w) { dx = OBBox.ltx-((text_w-bbox_w)>>1)-TextObjPtr->obbox.ltx; } else { dx = OBBox.ltx+((bbox_w-text_w)>>1)-TextObjPtr->obbox.ltx; } if (text_h > bbox_h) { dy = OBBox.lty-((text_h-bbox_h)>>1)-TextObjPtr->obbox.lty; } else { dy = OBBox.lty+((bbox_h-text_h)>>1)-TextObjPtr->obbox.lty; } MoveObj(TextObjPtr, dx, dy); if (BBoxReturn != NULL) { if (TextObjPtr->bbox.ltx < BBoxReturn->ltx) { BBoxReturn->ltx = TextObjPtr->bbox.ltx; } if (TextObjPtr->bbox.lty < BBoxReturn->lty) { BBoxReturn->lty = TextObjPtr->bbox.lty; } if (TextObjPtr->bbox.rbx > BBoxReturn->rbx) { BBoxReturn->rbx = TextObjPtr->bbox.rbx; } if (TextObjPtr->bbox.rby > BBoxReturn->rby) { BBoxReturn->rby = TextObjPtr->bbox.rby; } } } struct SelRec *PtInSelMark(XOff, YOff, Corner) int XOff, YOff, *Corner; /* XOff and YOff are screen offsets */ /* 1 2 3 */ /* 8 4 */ /* 7 6 5 */ { register struct SelRec *sel_ptr; register struct ObjRec *obj_ptr; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { obj_ptr = sel_ptr->obj; switch (obj_ptr->type) { case OBJ_POLY: if (obj_ptr->detail.p->curved == LT_STRUCT_SPLINE) { if (PtInPolyMark(obj_ptr, XOff, YOff, obj_ptr->detail.p->ssn, obj_ptr->detail.p->ssvlist, Corner)) { return sel_ptr; } } else { if (PtInPolyMark(obj_ptr, XOff, YOff, obj_ptr->detail.p->n, obj_ptr->detail.p->vlist, Corner)) { return sel_ptr; } } break; case OBJ_POLYGON: if (obj_ptr->detail.g->curved == LT_STRUCT_SPLINE) { if (PtInPolyMark(obj_ptr, XOff, YOff, obj_ptr->detail.g->ssn-1, obj_ptr->detail.g->ssvlist, Corner)) { return sel_ptr; } } else { if (PtInPolyMark(obj_ptr, XOff, YOff, obj_ptr->detail.g->n-1, obj_ptr->detail.g->vlist, Corner)) { return sel_ptr; } } break; case OBJ_BOX: case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: case OBJ_OVAL: case OBJ_ARC: case OBJ_RCBOX: case OBJ_XBM: case OBJ_XPM: if (PtIn8Places(XOff, YOff, obj_ptr->obbox, Corner)) { return sel_ptr; } break; case OBJ_TEXT: if (curChoice == ROTATEMODE) { if (PtIn8Places(XOff, YOff, obj_ptr->obbox, Corner)) { return sel_ptr; } } else if (curChoice == NOTHING) { if (stretchableText && PtIn8Places(XOff, YOff, obj_ptr->obbox, Corner)) { return sel_ptr; } } break; } } return NULL; } int HasOnReshape(obj_ptr, pp_name_attr) struct ObjRec *obj_ptr; struct AttrRec **pp_name_attr; /* returns the name attribute pointer */ { if (pp_name_attr != NULL) *pp_name_attr = NULL; if ((obj_ptr->type == OBJ_POLY || obj_ptr->type == OBJ_POLYGON) && obj_ptr->ctm == NULL) { if (FindAttrWithName(obj_ptr, "on_reshape=", NULL) != NULL) { struct AttrRec *attr=FindAttrWithName(obj_ptr, "name=", NULL); if (attr != NULL && *attr->attr_value.s != '\0') { if (pp_name_attr != NULL) *pp_name_attr = attr; return TRUE; } } } return FALSE; } static int SkipOnResize(obj_ptr) struct ObjRec *obj_ptr; { if (obj_ptr->type != OBJ_GROUP && obj_ptr->type != OBJ_ICON && obj_ptr->type != OBJ_SYM && obj_ptr->type != OBJ_PIN) { if (obj_ptr->ctm != NULL) { return TRUE; } } else { struct ObjRec *sub_obj=obj_ptr->detail.r->last; for ( ; sub_obj != NULL; sub_obj=sub_obj->prev) { if (sub_obj->type != OBJ_GROUP && sub_obj->type != OBJ_ICON && sub_obj->type != OBJ_SYM && sub_obj->type != OBJ_PIN && sub_obj->ctm != NULL) { return TRUE; } } } return FALSE; } static int HasOnResize(obj_ptr, pp_name_attr) struct ObjRec *obj_ptr; struct AttrRec **pp_name_attr; /* returns the name attribute pointer */ { if (pp_name_attr != NULL) *pp_name_attr = NULL; if (!SkipOnResize(obj_ptr)) { if (FindAttrWithName(obj_ptr, "on_resize=", NULL) != NULL) { struct AttrRec *attr=FindAttrWithName(obj_ptr, "name=", NULL); if (attr != NULL && *attr->attr_value.s != '\0') { if (pp_name_attr != NULL) *pp_name_attr = attr; return TRUE; } } } return FALSE; } static char **NeedToProcessOnResize(pn_num_to_resize) int *pn_num_to_resize; { int num_to_resize=0; char **ppsz_names=NULL; struct SelRec *sel_ptr=NULL; *pn_num_to_resize = 0; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { struct AttrRec *name_attr=NULL; if (HasOnResize(sel_ptr->obj, &name_attr) && name_attr != NULL) { num_to_resize++; if (ppsz_names == NULL) { ppsz_names = (char**)malloc(sizeof(char*)); } else { ppsz_names = (char**)realloc(ppsz_names, num_to_resize*sizeof(char*)); } if (ppsz_names == NULL) FailAllocMessage(); ppsz_names[num_to_resize-1] = (char*)(long)(sel_ptr->obj->id); } } if (num_to_resize == 0) return NULL; *pn_num_to_resize = num_to_resize; return ppsz_names; } static struct ObjRec *FindObjWithOID(oid) int oid; { struct ObjRec *obj_ptr=NULL; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (obj_ptr->id == oid) { return obj_ptr; } } return NULL; } static void DoOnResize(ppsz_names, num_to_resize) char **ppsz_names; int num_to_resize; { int i=0; RemoveAllSel(); for (i=0; i < num_to_resize; i++) { struct AttrRec *exec_attr=NULL; struct ObjRec *obj_ptr=FindObjWithOID((int)(long)(ppsz_names[i])); if (obj_ptr != NULL && !SkipOnResize(obj_ptr)) { exec_attr = FindAttrWithName(obj_ptr, "on_resize=", NULL); } if (exec_attr != NULL) { DoExecLoop(obj_ptr, exec_attr); } else { sprintf(gszMsgBox, TgLoadCachedString(CSTID_CANT_FIND_OBJ_NAME_ON_RESIZE), ppsz_names[i]); Msg(gszMsgBox); *ppsz_names[i] = '\0'; } } for (i=0; i < num_to_resize; i++) { struct ObjRec *obj_ptr=FindObjWithOID((int)(long)(ppsz_names[i])); if (obj_ptr != NULL) { if (!AlreadySelected(obj_ptr)) { AddNewSelObj(obj_ptr); } } } free(ppsz_names); UpdSelBBox(); } #define STRETCH_DRAW (FALSE) #define STRETCH_ERASE (TRUE) #define STRETCH_CLICK (FALSE) #define STRETCH_DRAG (TRUE) #define STRETCH_STARTSHOW 0 #define STRETCH_DOSHOW 1 #define STRETCH_ENDSHOW 2 int GetVlistIndexFromStretchStructuredSplineInfo(psssi, ss_index) StretchStructuredSplineInfo *psssi; int ss_index; { if (psssi->hinge) { return psssi->orig_hinge_index; } if (psssi->earlier_smooth_selected) { return psssi->orig_hinge_index-1; } else { return psssi->orig_hinge_index+1; } } static void DoStretchPolyMeasureCursor(start, num_pts, vs, index, dx, dy, erase, drag, obj_type, grid_x, grid_y) int start, num_pts, index, dx, dy, erase, drag, obj_type, grid_x, grid_y; IntPoint *vs; { static IntPoint prev_pt={0,0}, mid_pt={0,0}, next_pt={0,0}; char buf[80], x_buf[80], y_buf[80], a_buf[80]; int x=vs[index].x+dx, y=vs[index].y+dy, angle2=0; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert((obj_type == OBJ_POLY || index != num_pts-1), "index == num_pts-1 for a polygon in DoStretchPolyMeasureCursor()", NULL); #endif /* _TGIF_DBG */ if (index == 0 || index == num_pts-1) { if (obj_type == OBJ_POLY) { if (num_pts > 2) { if (index == 0) { prev_pt.x = x; prev_pt.y = y; mid_pt.x = vs[1].x; mid_pt.y = vs[1].y; next_pt.x = vs[2].x; next_pt.y = vs[2].y; } else { prev_pt.x = vs[num_pts-3].x; prev_pt.y = vs[num_pts-3].y; mid_pt.x = vs[num_pts-2].x; mid_pt.y = vs[num_pts-2].y; next_pt.x = x; next_pt.y = y; } } else { if (index == 0) { prev_pt.x = x; prev_pt.y = y; mid_pt.x = vs[1].x; mid_pt.y = vs[1].y; next_pt.x = vs[1].x+100; next_pt.y = vs[1].y; } else { prev_pt.x = x; prev_pt.y = y; mid_pt.x = vs[0].x; mid_pt.y = vs[0].y; next_pt.x = vs[0].x+100; next_pt.y = vs[0].y; } } } else { prev_pt.x = vs[1].x; prev_pt.y = vs[1].y; mid_pt.x = x; mid_pt.y = y; next_pt.x = vs[num_pts-2].x; next_pt.y = vs[num_pts-2].y; } } else { prev_pt.x = vs[index-1].x; prev_pt.y = vs[index-1].y; mid_pt.x = x; mid_pt.y = y; next_pt.x = vs[index+1].x; next_pt.y = vs[index+1].y; } if (num_pts == 2) { if (index == 0 && x == mid_pt.x && y == mid_pt.y) { strcpy(a_buf, "0"); } else { PointsToArc(mid_pt.x, mid_pt.y, x, y, mid_pt.x+100, mid_pt.y, ARC_CCW, FALSE, NULL, NULL, NULL, NULL, NULL, &angle2); if (angle2 > 180*64) angle2=(360*64)-angle2; FormatAngle(angle2, a_buf); } } else { if ((index == 0 || index == num_pts-1) && (x == mid_pt.x && y == mid_pt.y)) { strcpy(a_buf, "0"); } else if ((index != 0 && index != num_pts-1) && ((x == prev_pt.x && y == prev_pt.y) || (x == next_pt.x && y == next_pt.y))) { strcpy(a_buf, "180"); } else { PointsToArc(mid_pt.x, mid_pt.y, prev_pt.x, prev_pt.y, next_pt.x, next_pt.y, ARC_CCW, FALSE, NULL, NULL, NULL, NULL, NULL, &angle2); if (angle2 > 180*64) angle2=(360*64)-angle2; FormatAngle(angle2, a_buf); } } PixelToMeasurementUnit(x_buf, x); PixelToMeasurementUnit(y_buf, y); if (curChoice == FREEHAND) { sprintf(buf, "x=%s\ny=%s", x_buf, y_buf); } else { sprintf(buf, "x=%s\ny=%s\nangle=%s", x_buf, y_buf, a_buf); } switch (start) { case STRETCH_STARTSHOW: StartShowMeasureCursor(grid_x, grid_y, buf, TRUE); break; case STRETCH_DOSHOW: ShowMeasureCursor(grid_x, grid_y, buf, TRUE); break; case STRETCH_ENDSHOW: EndShowMeasureCursor(grid_x, grid_y, buf, TRUE); break; } } static void DoStretchStructSplineMeasureCursor(start, start_v, dx, dy, grid_x, grid_y) int start, dx, dy, grid_x, grid_y; IntPoint *start_v; { int x=0, y=0; char buf[MAXSTRING], x_buf[80], y_buf[80], dx_buf[80], dy_buf[80]; x = start_v->x + dx; y = start_v->y + dy; PixelToMeasurementUnit(x_buf, x); PixelToMeasurementUnit(y_buf, y); PixelToMeasurementUnit(dx_buf, dx); PixelToMeasurementUnit(dy_buf, dy); sprintf(buf, "x=%s\ny=%s\ndx=%s\ndy=%s", x_buf, y_buf, dx_buf, dy_buf); switch (start) { case STRETCH_STARTSHOW: StartShowMeasureCursor(grid_x, grid_y, buf, TRUE); break; case STRETCH_DOSHOW: ShowMeasureCursor(grid_x, grid_y, buf, TRUE); break; case STRETCH_ENDSHOW: EndShowMeasureCursor(grid_x, grid_y, buf, TRUE); break; } } void SetIPTInfoForStretchPoly(index, n, vs, psssi) int index, n; /* 0 <= index < ssn */ IntPoint *vs; StretchStructuredSplineInfo *psssi; { int i=0, j=0, k=0, num_hinge_vs=(n+2)/3; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert((n+2)%3 == 0, "invalid n in SetIPTInfoForStretchPoly()", NULL); #endif /* _TGIF_DBG */ memset(psssi, 0, sizeof(StretchStructuredSplineInfo)); for (i=0, j=0, k=0; i < num_hinge_vs; i++, j+=3, k++) { int set_the_rest_for_this=FALSE; if (i == 0) { if (k == index) { psssi->hinge = TRUE; set_the_rest_for_this = TRUE; } if (vs[0].x != vs[1].x || vs[0].y != vs[1].y) { k++; if (k == index) { psssi->hinge = FALSE; psssi->earlier_smooth_selected = FALSE; set_the_rest_for_this = TRUE; } } if (set_the_rest_for_this) { psssi->orig_hinge_index = j; psssi->prev_valid = FALSE; psssi->next_valid = TRUE; psssi->ipt.earlier_smooth_pt.x = vs[0].x; psssi->ipt.earlier_smooth_pt.y = vs[0].y; psssi->ipt.hinge_pt.x = vs[0].x; psssi->ipt.hinge_pt.y = vs[0].y; psssi->ipt.later_smooth_pt.x = vs[1].x; psssi->ipt.later_smooth_pt.y = vs[1].y; if (vs[0].x != vs[1].x || vs[0].y != vs[1].y) { psssi->ipt.later_valid = TRUE; } psssi->ipt_next.earlier_smooth_pt.x = vs[2].x; psssi->ipt_next.earlier_smooth_pt.y = vs[2].y; psssi->ipt_next.hinge_pt.x = vs[3].x; psssi->ipt_next.hinge_pt.y = vs[3].y; if (num_hinge_vs > 2) { psssi->ipt_next.later_smooth_pt.x = vs[4].x; psssi->ipt_next.later_smooth_pt.y = vs[4].y; } else { /* this may not be necessary */ psssi->ipt_next.later_smooth_pt.x = vs[3].x; psssi->ipt_next.later_smooth_pt.y = vs[3].y; } if (vs[2].x != vs[3].x || vs[2].y != vs[3].y) { psssi->ipt_next.earlier_valid = TRUE; } if (vs[4].x != vs[3].x || vs[4].y != vs[3].y) { psssi->ipt_next.later_valid = TRUE; } } } else if (i == num_hinge_vs-1) { if (vs[n-1].x != vs[n-2].x || vs[n-1].y != vs[n-2].y) { if (k == index) { psssi->hinge = FALSE; psssi->earlier_smooth_selected = TRUE; set_the_rest_for_this = TRUE; } k++; } if (k == index) { psssi->hinge = TRUE; set_the_rest_for_this = TRUE; } if (set_the_rest_for_this) { psssi->orig_hinge_index = j; psssi->prev_valid = TRUE; psssi->next_valid = FALSE; psssi->ipt.later_smooth_pt.x = vs[n-1].x; psssi->ipt.later_smooth_pt.y = vs[n-1].y; psssi->ipt.hinge_pt.x = vs[n-1].x; psssi->ipt.hinge_pt.y = vs[n-1].y; psssi->ipt.earlier_smooth_pt.x = vs[n-2].x; psssi->ipt.earlier_smooth_pt.y = vs[n-2].y; if (vs[n-1].x != vs[n-2].x || vs[n-1].y != vs[n-2].y) { psssi->ipt.earlier_valid = TRUE; } psssi->ipt_prev.later_smooth_pt.x = vs[n-3].x; psssi->ipt_prev.later_smooth_pt.y = vs[n-3].y; psssi->ipt_prev.hinge_pt.x = vs[n-4].x; psssi->ipt_prev.hinge_pt.y = vs[n-4].y; if (num_hinge_vs > 2) { psssi->ipt_prev.earlier_smooth_pt.x = vs[n-5].x; psssi->ipt_prev.earlier_smooth_pt.y = vs[n-5].y; } else { /* this may not be necessary */ psssi->ipt_prev.earlier_smooth_pt.x = vs[n-4].x; psssi->ipt_prev.earlier_smooth_pt.y = vs[n-4].y; } if (vs[n-5].x != vs[n-4].x || vs[n-5].y != vs[n-4].y) { psssi->ipt_prev.earlier_valid = TRUE; } if (vs[n-3].x != vs[n-4].x || vs[n-3].y != vs[n-4].y) { psssi->ipt_prev.later_valid = TRUE; } } } else { if (vs[j-1].x != vs[j].x || vs[j-1].y != vs[j].y) { if (k == index) { psssi->hinge = FALSE; psssi->earlier_smooth_selected = TRUE; set_the_rest_for_this = TRUE; } k++; } if (k == index) { psssi->hinge = TRUE; set_the_rest_for_this = TRUE; } if (vs[j+1].x != vs[j].x || vs[j+1].y != vs[j].y) { k++; if (k == index) { psssi->hinge = FALSE; psssi->earlier_smooth_selected = FALSE; set_the_rest_for_this = TRUE; } } if (set_the_rest_for_this) { psssi->orig_hinge_index = j; psssi->prev_valid = TRUE; psssi->next_valid = TRUE; if (i > 1) { psssi->ipt_prev.earlier_smooth_pt.x = vs[j-4].x; psssi->ipt_prev.earlier_smooth_pt.y = vs[j-4].y; if (vs[j-4].x != vs[j-3].x || vs[j-4].y != vs[j-3].y) { psssi->ipt_prev.earlier_valid = TRUE; } } else { /* this may not be necessary */ psssi->ipt_prev.earlier_smooth_pt.x = vs[j-3].x; psssi->ipt_prev.earlier_smooth_pt.y = vs[j-3].y; } psssi->ipt_prev.hinge_pt.x = vs[j-3].x; psssi->ipt_prev.hinge_pt.y = vs[j-3].y; psssi->ipt_prev.later_smooth_pt.x = vs[j-2].x; psssi->ipt_prev.later_smooth_pt.y = vs[j-2].y; if (vs[j-2].x != vs[j-3].x || vs[j-2].y != vs[j-3].y) { psssi->ipt_prev.later_valid = TRUE; } psssi->ipt.earlier_smooth_pt.x = vs[j-1].x; psssi->ipt.earlier_smooth_pt.y = vs[j-1].y; psssi->ipt.hinge_pt.x = vs[j].x; psssi->ipt.hinge_pt.y = vs[j].y; psssi->ipt.later_smooth_pt.x = vs[j+1].x; psssi->ipt.later_smooth_pt.y = vs[j+1].y; if (vs[j-1].x != vs[j].x || vs[j-1].y != vs[j].y) { psssi->ipt.earlier_valid = TRUE; } if (vs[j+1].x != vs[j].x || vs[j+1].y != vs[j].y) { psssi->ipt.later_valid = TRUE; } psssi->ipt_next.earlier_smooth_pt.x = vs[j+2].x; psssi->ipt_next.earlier_smooth_pt.y = vs[j+2].y; psssi->ipt_next.hinge_pt.x = vs[j+3].x; psssi->ipt_next.hinge_pt.y = vs[j+3].y; if (i < num_hinge_vs-2) { psssi->ipt_next.later_smooth_pt.x = vs[j+4].x; psssi->ipt_next.later_smooth_pt.y = vs[j+4].y; if (vs[j+4].x != vs[j+3].x || vs[j+4].y != vs[j+3].y) { psssi->ipt_next.later_valid = TRUE; } } else { /* this may not be necessary */ psssi->ipt_next.later_smooth_pt.x = vs[j+3].x; psssi->ipt_next.later_smooth_pt.y = vs[j+3].y; } if (vs[j+2].x != vs[j+3].x || vs[j+2].y != vs[j+3].y) { psssi->ipt_next.earlier_valid = TRUE; } } } } } void SetIPTInfoForStretchPolygon(index, n, vs, psssi) int index, n; /* 0 <= index < ssn */ IntPoint *vs; StretchStructuredSplineInfo *psssi; { int i=0, j=0, k=0, num_hinge_vs=(n+2)/3; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert((n+2)%3 == 0, "invalid n in SetIPTInfoForStretchPolygon()", NULL); #endif /* _TGIF_DBG */ memset(psssi, 0, sizeof(StretchStructuredSplineInfo)); psssi->prev_valid = psssi->next_valid = TRUE; for (i=0, j=0, k=0; i < num_hinge_vs; i++, j+=3, k++) { int set_the_rest_for_this=FALSE; if (i == 0) { if (k == index) { psssi->hinge = TRUE; set_the_rest_for_this = TRUE; } if (vs[0].x != vs[1].x || vs[0].y != vs[1].y) { k++; if (k == index) { psssi->hinge = FALSE; psssi->earlier_smooth_selected = FALSE; set_the_rest_for_this = TRUE; } } if (set_the_rest_for_this) { psssi->orig_hinge_index = j; psssi->ipt_prev.earlier_smooth_pt.x = vs[n-5].x; psssi->ipt_prev.earlier_smooth_pt.y = vs[n-5].y; psssi->ipt_prev.hinge_pt.x = vs[n-4].x; psssi->ipt_prev.hinge_pt.y = vs[n-4].y; psssi->ipt_prev.later_smooth_pt.x = vs[n-3].x; psssi->ipt_prev.later_smooth_pt.y = vs[n-3].y; if (vs[n-3].x != vs[n-4].x || vs[n-3].y != vs[n-4].y) { psssi->ipt_prev.later_valid = TRUE; } if (vs[n-5].x != vs[n-4].x || vs[n-5].y != vs[n-4].y) { psssi->ipt_prev.earlier_valid = TRUE; } psssi->ipt.earlier_smooth_pt.x = vs[n-2].x; psssi->ipt.earlier_smooth_pt.y = vs[n-2].y; psssi->ipt.hinge_pt.x = vs[0].x; psssi->ipt.hinge_pt.y = vs[0].y; psssi->ipt.later_smooth_pt.x = vs[1].x; psssi->ipt.later_smooth_pt.y = vs[1].y; if (vs[1].x != vs[0].x || vs[1].y != vs[0].y) { psssi->ipt.later_valid = TRUE; } if (vs[n-2].x != vs[0].x || vs[n-2].y != vs[0].y) { psssi->ipt.earlier_valid = TRUE; } psssi->ipt_next.earlier_smooth_pt.x = vs[2].x; psssi->ipt_next.earlier_smooth_pt.y = vs[2].y; psssi->ipt_next.hinge_pt.x = vs[3].x; psssi->ipt_next.hinge_pt.y = vs[3].y; psssi->ipt_next.later_smooth_pt.x = vs[4].x; psssi->ipt_next.later_smooth_pt.y = vs[4].y; if (vs[4].x != vs[3].x || vs[4].y != vs[3].y) { psssi->ipt_next.later_valid = TRUE; } if (vs[2].x != vs[3].x || vs[2].y != vs[3].y) { psssi->ipt_next.earlier_valid = TRUE; } } } else if (i == num_hinge_vs-1) { if (vs[n-1].x != vs[n-2].x || vs[n-1].y != vs[n-2].y) { if (k == index) { psssi->hinge = FALSE; psssi->earlier_smooth_selected = TRUE; set_the_rest_for_this = TRUE; } k++; } if (k == index) { psssi->hinge = TRUE; set_the_rest_for_this = TRUE; } if (set_the_rest_for_this) { psssi->orig_hinge_index = j; psssi->ipt_prev.earlier_smooth_pt.x = vs[n-5].x; psssi->ipt_prev.earlier_smooth_pt.y = vs[n-5].y; psssi->ipt_prev.hinge_pt.x = vs[n-4].x; psssi->ipt_prev.hinge_pt.y = vs[n-4].y; psssi->ipt_prev.later_smooth_pt.x = vs[n-3].x; psssi->ipt_prev.later_smooth_pt.y = vs[n-3].y; if (vs[n-3].x != vs[n-4].x || vs[n-3].y != vs[n-4].y) { psssi->ipt_prev.later_valid = TRUE; } if (vs[n-5].x != vs[n-4].x || vs[n-5].y != vs[n-4].y) { psssi->ipt_prev.earlier_valid = TRUE; } psssi->ipt.earlier_smooth_pt.x = vs[n-2].x; psssi->ipt.earlier_smooth_pt.y = vs[n-2].y; psssi->ipt.hinge_pt.x = vs[n-1].x; psssi->ipt.hinge_pt.y = vs[n-1].y; psssi->ipt.later_smooth_pt.x = vs[1].x; psssi->ipt.later_smooth_pt.y = vs[1].y; if (vs[1].x != vs[n-1].x || vs[1].y != vs[n-1].y) { psssi->ipt.later_valid = TRUE; } if (vs[n-2].x != vs[n-1].x || vs[n-2].y != vs[n-1].y) { psssi->ipt.earlier_valid = TRUE; } psssi->ipt_next.earlier_smooth_pt.x = vs[2].x; psssi->ipt_next.earlier_smooth_pt.y = vs[2].y; psssi->ipt_next.hinge_pt.x = vs[3].x; psssi->ipt_next.hinge_pt.y = vs[3].y; psssi->ipt_next.later_smooth_pt.x = vs[4].x; psssi->ipt_next.later_smooth_pt.y = vs[4].y; if (vs[4].x != vs[3].x || vs[4].y != vs[3].y) { psssi->ipt_next.later_valid = TRUE; } if (vs[2].x != vs[3].x || vs[2].y != vs[3].y) { psssi->ipt_next.earlier_valid = TRUE; } } } else { if (vs[j-1].x != vs[j].x || vs[j-1].y != vs[j].y) { if (k == index) { psssi->hinge = FALSE; psssi->earlier_smooth_selected = TRUE; set_the_rest_for_this = TRUE; } k++; } if (k == index) { psssi->hinge = TRUE; set_the_rest_for_this = TRUE; } if (vs[j+1].x != vs[j].x || vs[j+1].y != vs[j].y) { k++; if (k == index) { psssi->hinge = FALSE; psssi->earlier_smooth_selected = FALSE; set_the_rest_for_this = TRUE; } } if (set_the_rest_for_this) { psssi->orig_hinge_index = j; if (i > 1) { psssi->ipt_prev.earlier_smooth_pt.x = vs[j-4].x; psssi->ipt_prev.earlier_smooth_pt.y = vs[j-4].y; if (vs[j-4].x != vs[j-3].x || vs[j-4].y != vs[j-3].y) { psssi->ipt_prev.earlier_valid = TRUE; } } else { psssi->ipt_prev.earlier_smooth_pt.x = vs[n-2].x; psssi->ipt_prev.earlier_smooth_pt.y = vs[n-2].y; if (vs[n-2].x != vs[j-3].x || vs[n-2].y != vs[j-3].y) { psssi->ipt_prev.earlier_valid = TRUE; } } psssi->ipt_prev.hinge_pt.x = vs[j-3].x; psssi->ipt_prev.hinge_pt.y = vs[j-3].y; psssi->ipt_prev.later_smooth_pt.x = vs[j-2].x; psssi->ipt_prev.later_smooth_pt.y = vs[j-2].y; if (vs[j-2].x != vs[j-3].x || vs[j-2].y != vs[j-3].y) { psssi->ipt_prev.later_valid = TRUE; } psssi->ipt.earlier_smooth_pt.x = vs[j-1].x; psssi->ipt.earlier_smooth_pt.y = vs[j-1].y; psssi->ipt.hinge_pt.x = vs[j].x; psssi->ipt.hinge_pt.y = vs[j].y; psssi->ipt.later_smooth_pt.x = vs[j+1].x; psssi->ipt.later_smooth_pt.y = vs[j+1].y; if (vs[j-1].x != vs[j].x || vs[j-1].y != vs[j].y) { psssi->ipt.earlier_valid = TRUE; } if (vs[j+1].x != vs[j].x || vs[j+1].y != vs[j].y) { psssi->ipt.later_valid = TRUE; } psssi->ipt_next.earlier_smooth_pt.x = vs[j+2].x; psssi->ipt_next.earlier_smooth_pt.y = vs[j+2].y; psssi->ipt_next.hinge_pt.x = vs[j+3].x; psssi->ipt_next.hinge_pt.y = vs[j+3].y; if (i < num_hinge_vs-2) { psssi->ipt_next.later_smooth_pt.x = vs[j+4].x; psssi->ipt_next.later_smooth_pt.y = vs[j+4].y; if (vs[j+4].x != vs[j+3].x || vs[j+4].y != vs[j+3].y) { psssi->ipt_next.earlier_valid = TRUE; } } else { psssi->ipt_next.later_smooth_pt.x = vs[1].x; psssi->ipt_next.later_smooth_pt.y = vs[1].y; if (vs[1].x != vs[j+3].x || vs[1].y != vs[j+3].y) { psssi->ipt_next.earlier_valid = TRUE; } } if (vs[j+2].x != vs[j+3].x || vs[j+2].y != vs[j+3].y) { psssi->ipt_next.earlier_valid = TRUE; } } } } } static void SetVsAndVs2ForHinge(psssi, dx, dy, pn_num_vs, vs, pn_num_vs2, vs2) StretchStructuredSplineInfo *psssi; int dx, dy, *pn_num_vs, *pn_num_vs2; IntPoint *vs, *vs2; { int num_vs=0, num_vs2=0; if (!psssi->prev_valid) { /* first poly point */ num_vs = 0; vs2[0].x = psssi->ipt.hinge_pt.x + dx; vs2[0].y = psssi->ipt.hinge_pt.y + dy; if (psssi->ipt.later_valid) { vs2[1].x = psssi->ipt.later_smooth_pt.x + dx; vs2[1].y = psssi->ipt.later_smooth_pt.y + dy; if (psssi->ipt_next.earlier_valid) { num_vs2 = 4; vs2[2].x = psssi->ipt_next.earlier_smooth_pt.x; vs2[2].y = psssi->ipt_next.earlier_smooth_pt.y; } else { num_vs2 = 3; } } else { if (psssi->ipt_next.earlier_valid) { num_vs2 = 3; vs2[1].x = psssi->ipt_next.earlier_smooth_pt.x; vs2[1].y = psssi->ipt_next.earlier_smooth_pt.y; } else { num_vs2 = 2; } } vs2[num_vs2-1].x = psssi->ipt_next.hinge_pt.x; vs2[num_vs2-1].y = psssi->ipt_next.hinge_pt.y; } else if (!psssi->next_valid) { /* last poly point */ num_vs2 = 0; vs[0].x = psssi->ipt.hinge_pt.x + dx; vs[0].y = psssi->ipt.hinge_pt.y + dy; if (psssi->ipt.earlier_valid) { vs[1].x = psssi->ipt.earlier_smooth_pt.x + dx; vs[1].y = psssi->ipt.earlier_smooth_pt.y + dy; if (psssi->ipt_prev.later_valid) { num_vs = 4; vs[2].x = psssi->ipt_prev.later_smooth_pt.x; vs[2].y = psssi->ipt_prev.later_smooth_pt.y; } else { num_vs = 3; } } else { if (psssi->ipt_prev.later_valid) { num_vs = 3; vs[1].x = psssi->ipt_prev.later_smooth_pt.x; vs[1].y = psssi->ipt_prev.later_smooth_pt.y; } else { num_vs = 2; } } vs[num_vs-1].x = psssi->ipt_prev.hinge_pt.x; vs[num_vs-1].y = psssi->ipt_prev.hinge_pt.y; } else { /* set the vs */ vs[0].x = psssi->ipt.hinge_pt.x + dx; vs[0].y = psssi->ipt.hinge_pt.y + dy; if (psssi->ipt.earlier_valid) { vs[1].x = psssi->ipt.earlier_smooth_pt.x + dx; vs[1].y = psssi->ipt.earlier_smooth_pt.y + dy; if (psssi->ipt_prev.later_valid) { num_vs = 4; vs[2].x = psssi->ipt_prev.later_smooth_pt.x; vs[2].y = psssi->ipt_prev.later_smooth_pt.y; } else { num_vs = 3; } } else { if (psssi->ipt_prev.later_valid) { num_vs = 3; vs[1].x = psssi->ipt_prev.later_smooth_pt.x; vs[1].y = psssi->ipt_prev.later_smooth_pt.y; } else { num_vs = 2; } } vs[num_vs-1].x = psssi->ipt_prev.hinge_pt.x; vs[num_vs-1].y = psssi->ipt_prev.hinge_pt.y; /* set the vs2 */ vs2[0].x = psssi->ipt.hinge_pt.x + dx; vs2[0].y = psssi->ipt.hinge_pt.y + dy; if (psssi->ipt.later_valid) { vs2[1].x = psssi->ipt.later_smooth_pt.x + dx; vs2[1].y = psssi->ipt.later_smooth_pt.y + dy; if (psssi->ipt_next.earlier_valid) { num_vs2 = 4; vs2[2].x = psssi->ipt_next.earlier_smooth_pt.x; vs2[2].y = psssi->ipt_next.earlier_smooth_pt.y; } else { num_vs2 = 3; } } else { if (psssi->ipt_next.earlier_valid) { num_vs2 = 3; vs2[1].x = psssi->ipt_next.earlier_smooth_pt.x; vs2[1].y = psssi->ipt_next.earlier_smooth_pt.y; } else { num_vs2 = 2; } } vs2[num_vs2-1].x = psssi->ipt_next.hinge_pt.x; vs2[num_vs2-1].y = psssi->ipt_next.hinge_pt.y; } *pn_num_vs = num_vs; *pn_num_vs2 = num_vs2; } static void SetVsAndVs2ForSmooth(psssi, dx, dy, pn_num_vs, vs, pn_num_vs2, vs2) StretchStructuredSplineInfo *psssi; int dx, dy, *pn_num_vs, *pn_num_vs2; IntPoint *vs, *vs2; { int num_vs=0, num_vs2=0; if (!psssi->prev_valid) { /* first poly point */ num_vs = 0; vs2[0].x = psssi->ipt.hinge_pt.x; vs2[0].y = psssi->ipt.hinge_pt.y; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(psssi->ipt.later_valid, "psssi->ipt.later_valid is FALSE in SetVsAndVs2ForSmooth()", NULL); #endif /* _TGIF_DBG */ vs2[1].x = psssi->ipt.later_smooth_pt.x + dx; vs2[1].y = psssi->ipt.later_smooth_pt.y + dy; if (psssi->ipt_next.earlier_valid) { num_vs2 = 4; vs2[2].x = psssi->ipt_next.earlier_smooth_pt.x; vs2[2].y = psssi->ipt_next.earlier_smooth_pt.y; } else { num_vs2 = 3; } vs2[num_vs2-1].x = psssi->ipt_next.hinge_pt.x; vs2[num_vs2-1].y = psssi->ipt_next.hinge_pt.y; } else if (!psssi->next_valid) { /* last poly point */ num_vs2 = 0; vs[0].x = psssi->ipt.hinge_pt.x; vs[0].y = psssi->ipt.hinge_pt.y; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(psssi->ipt.earlier_valid, "psssi->ipt.earlier_valid is FALSE in SetVsAndVs2ForSmooth()", NULL); #endif /* _TGIF_DBG */ vs[1].x = psssi->ipt.earlier_smooth_pt.x + dx; vs[1].y = psssi->ipt.earlier_smooth_pt.y + dy; if (psssi->ipt_prev.later_valid) { num_vs = 4; vs[2].x = psssi->ipt_prev.later_smooth_pt.x; vs[2].y = psssi->ipt_prev.later_smooth_pt.y; } else { num_vs = 3; } vs[num_vs-1].x = psssi->ipt_prev.hinge_pt.x; vs[num_vs-1].y = psssi->ipt_prev.hinge_pt.y; } else { if (psssi->earlier_smooth_selected) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(psssi->ipt.earlier_valid, "psssi->ipt.earlier_valid is FALSE with psssi->earlier_smooth_selected in SetVsAndVs2ForSmooth()", NULL); #endif /* _TGIF_DBG */ /* set the vs */ vs[0].x = psssi->ipt.hinge_pt.x; vs[0].y = psssi->ipt.hinge_pt.y; vs[1].x = psssi->ipt.earlier_smooth_pt.x + dx; vs[1].y = psssi->ipt.earlier_smooth_pt.y + dy; if (psssi->ipt_prev.later_valid) { num_vs = 4; vs[2].x = psssi->ipt_prev.later_smooth_pt.x; vs[2].y = psssi->ipt_prev.later_smooth_pt.y; } else { num_vs = 3; } vs[num_vs-1].x = psssi->ipt_prev.hinge_pt.x; vs[num_vs-1].y = psssi->ipt_prev.hinge_pt.y; /* set the vs2 */ vs2[0].x = psssi->ipt.hinge_pt.x; vs2[0].y = psssi->ipt.hinge_pt.y; if (psssi->ipt.later_valid) { vs2[1].x = ((psssi->ipt.hinge_pt.x) << 1) - psssi->ipt.earlier_smooth_pt.x - dx; vs2[1].y = ((psssi->ipt.hinge_pt.y) << 1) - psssi->ipt.earlier_smooth_pt.y - dy; if (psssi->ipt_next.earlier_valid) { num_vs2 = 4; vs2[2].x = psssi->ipt_next.earlier_smooth_pt.x; vs2[2].y = psssi->ipt_next.earlier_smooth_pt.y; } else { num_vs2 = 3; } } else { if (psssi->ipt_next.earlier_valid) { num_vs2 = 3; vs2[1].x = psssi->ipt_next.earlier_smooth_pt.x; vs2[1].y = psssi->ipt_next.earlier_smooth_pt.y; } else { num_vs2 = 2; } } vs2[num_vs2-1].x = psssi->ipt_next.hinge_pt.x; vs2[num_vs2-1].y = psssi->ipt_next.hinge_pt.y; } else { /* set the vs */ vs[0].x = psssi->ipt.hinge_pt.x; vs[0].y = psssi->ipt.hinge_pt.y; if (psssi->ipt.earlier_valid) { vs[1].x = ((psssi->ipt.hinge_pt.x) << 1) - psssi->ipt.later_smooth_pt.x - dx; vs[1].y = ((psssi->ipt.hinge_pt.y) << 1) - psssi->ipt.later_smooth_pt.y - dy; if (psssi->ipt_prev.later_valid) { num_vs = 4; vs[2].x = psssi->ipt_prev.later_smooth_pt.x; vs[2].y = psssi->ipt_prev.later_smooth_pt.y; } else { num_vs = 3; } } else { if (psssi->ipt_prev.later_valid) { num_vs = 3; vs[1].x = psssi->ipt_prev.later_smooth_pt.x; vs[1].y = psssi->ipt_prev.later_smooth_pt.y; } else { num_vs = 2; } } vs[num_vs-1].x = psssi->ipt_prev.hinge_pt.x; vs[num_vs-1].y = psssi->ipt_prev.hinge_pt.y; #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(psssi->ipt.later_valid, "psssi->ipt.later_valid is FALSE with !psssi->earlier_smooth_selected in SetVsAndVs2ForSmooth()", NULL); #endif /* _TGIF_DBG */ /* set the vs2 */ vs2[0].x = psssi->ipt.hinge_pt.x; vs2[0].y = psssi->ipt.hinge_pt.y; vs2[1].x = psssi->ipt.later_smooth_pt.x + dx; vs2[1].y = psssi->ipt.later_smooth_pt.y + dy; if (psssi->ipt_next.earlier_valid) { num_vs2 = 4; vs2[2].x = psssi->ipt_next.earlier_smooth_pt.x; vs2[2].y = psssi->ipt_next.earlier_smooth_pt.y; } else { num_vs2 = 3; } vs2[num_vs2-1].x = psssi->ipt_next.hinge_pt.x; vs2[num_vs2-1].y = psssi->ipt_next.hinge_pt.y; } } *pn_num_vs = num_vs; *pn_num_vs2 = num_vs2; } void SetVsAndVs2ForStretchStructSpline(psssi, dx, dy, pn_num_vs, vs, pn_num_vs2, vs2) StretchStructuredSplineInfo *psssi; int dx, dy, *pn_num_vs, *pn_num_vs2; IntPoint *vs, *vs2; { if (psssi->hinge) { SetVsAndVs2ForHinge(psssi, dx, dy, pn_num_vs, vs, pn_num_vs2, vs2); } else { SetVsAndVs2ForSmooth(psssi, dx, dy, pn_num_vs, vs, pn_num_vs2, vs2); } } void FixUpSmoothAndSmooth2ForStretchStructSpline(num_vs, smooth, num_vs2, smooth2) int num_vs, num_vs2; char *smooth, *smooth2; { int i=0; smooth[0] = FALSE; smooth[num_vs-1] = FALSE; for (i=1; i < num_vs-1; i++) smooth[i] = TRUE; smooth2[0] = FALSE; smooth2[num_vs2-1] = FALSE; for (i=1; i < num_vs2-1; i++) smooth2[i] = TRUE; } void EraseHighLightForHinge(psssi, dx, dy, draw_dashed_line, draw_vertices) StretchStructuredSplineInfo *psssi; int dx, dy, draw_dashed_line, draw_vertices; { int x=0, y=0; XPoint vs[2]; XGCValues values; if (draw_dashed_line) { XSetDashes(mainDisplay, revDefaultGC, 0, dashList[8], dashListLength[8]); } if (!psssi->prev_valid) { /* first poly point */ x = psssi->ipt.hinge_pt.x + dx; y = psssi->ipt.hinge_pt.y + dy; if (draw_vertices) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[0].x = OFFSET_X(x); vs[0].y = OFFSET_Y(y); if (psssi->ipt.later_valid) { x = psssi->ipt.later_smooth_pt.x + dx; y = psssi->ipt.later_smooth_pt.y + dy; if (draw_vertices) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[1].x = OFFSET_X(x); vs[1].y = OFFSET_Y(y); if (draw_dashed_line) { values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } } else if (!psssi->next_valid) { /* last poly point */ x = psssi->ipt.hinge_pt.x + dx; y = psssi->ipt.hinge_pt.y + dy; if (draw_vertices) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[0].x = OFFSET_X(x); vs[0].y = OFFSET_Y(y); if (psssi->ipt.earlier_valid) { x = psssi->ipt.earlier_smooth_pt.x + dx; y = psssi->ipt.earlier_smooth_pt.y + dy; if (draw_vertices) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[1].x = OFFSET_X(x); vs[1].y = OFFSET_Y(y); if (draw_dashed_line) { values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } } else { x = psssi->ipt.hinge_pt.x + dx; y = psssi->ipt.hinge_pt.y + dy; if (draw_vertices) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[0].x = OFFSET_X(x); vs[0].y = OFFSET_Y(y); if (psssi->ipt.later_valid) { x = psssi->ipt.later_smooth_pt.x + dx; y = psssi->ipt.later_smooth_pt.y + dy; if (draw_vertices) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[1].x = OFFSET_X(x); vs[1].y = OFFSET_Y(y); if (draw_dashed_line) { values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } if (psssi->ipt.earlier_valid) { x = psssi->ipt.earlier_smooth_pt.x + dx; y = psssi->ipt.earlier_smooth_pt.y + dy; if (draw_vertices) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[1].x = OFFSET_X(x); vs[1].y = OFFSET_Y(y); if (draw_dashed_line) { values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } } } void EraseHighLightForSmooth(psssi, dx, dy, draw_dashed_line, draw_vertices) StretchStructuredSplineInfo *psssi; int dx, dy, draw_dashed_line, draw_vertices; { int x=0, y=0; XPoint vs[2]; XGCValues values; if (draw_dashed_line) { XSetDashes(mainDisplay, revDefaultGC, 0, dashList[8], dashListLength[8]); } if (!psssi->prev_valid) { /* first poly point */ x = psssi->ipt.hinge_pt.x; y = psssi->ipt.hinge_pt.y; if (draw_vertices) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[0].x = OFFSET_X(x); vs[0].y = OFFSET_Y(y); if (psssi->ipt.later_valid) { x = psssi->ipt.later_smooth_pt.x + dx; y = psssi->ipt.later_smooth_pt.y + dy; if (draw_vertices) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[1].x = OFFSET_X(x); vs[1].y = OFFSET_Y(y); if (draw_dashed_line) { values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } } else if (!psssi->next_valid) { /* last poly point */ x = psssi->ipt.hinge_pt.x; y = psssi->ipt.hinge_pt.y; if (draw_vertices) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[0].x = OFFSET_X(x); vs[0].y = OFFSET_Y(y); if (psssi->ipt.earlier_valid) { x = psssi->ipt.earlier_smooth_pt.x + dx; y = psssi->ipt.earlier_smooth_pt.y + dy; if (draw_vertices) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[1].x = OFFSET_X(x); vs[1].y = OFFSET_Y(y); if (draw_dashed_line) { values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } } else { if (psssi->earlier_smooth_selected) { x = psssi->ipt.hinge_pt.x; y = psssi->ipt.hinge_pt.y; if (draw_vertices) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[0].x = OFFSET_X(x); vs[0].y = OFFSET_Y(y); if (psssi->ipt.later_valid) { x = ((psssi->ipt.hinge_pt.x) << 1) - psssi->ipt.earlier_smooth_pt.x - dx; y = ((psssi->ipt.hinge_pt.y) << 1) - psssi->ipt.earlier_smooth_pt.y - dy; if (draw_vertices) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[1].x = OFFSET_X(x); vs[1].y = OFFSET_Y(y); if (draw_dashed_line) { values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } if (psssi->ipt.earlier_valid) { x = psssi->ipt.earlier_smooth_pt.x + dx; y = psssi->ipt.earlier_smooth_pt.y + dy; if (draw_vertices) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[1].x = OFFSET_X(x); vs[1].y = OFFSET_Y(y); if (draw_dashed_line) { values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } } else { x = psssi->ipt.hinge_pt.x; y = psssi->ipt.hinge_pt.y; if (draw_vertices) { MARKHR(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[0].x = OFFSET_X(x); vs[0].y = OFFSET_Y(y); if (psssi->ipt.later_valid) { x = psssi->ipt.later_smooth_pt.x + dx; y = psssi->ipt.later_smooth_pt.y + dy; if (draw_vertices) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[1].x = OFFSET_X(x); vs[1].y = OFFSET_Y(y); if (draw_dashed_line) { values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } if (psssi->ipt.earlier_valid) { x = ((psssi->ipt.hinge_pt.x) << 1) - psssi->ipt.later_smooth_pt.x - dx; y = ((psssi->ipt.hinge_pt.y) << 1) - psssi->ipt.later_smooth_pt.y - dy; if (draw_vertices) { MARKHO(drawWindow, revDefaultGC, OFFSET_X(x), OFFSET_Y(y)); } vs[1].x = OFFSET_X(x); vs[1].y = OFFSET_Y(y); if (draw_dashed_line) { values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); } } } } } void EraseHighLightForStretchStructSpline(psssi, dx, dy, draw_dashed_line, draw_vertices) StretchStructuredSplineInfo *psssi; int dx, dy, draw_dashed_line, draw_vertices; { if (psssi->hinge) { EraseHighLightForHinge(psssi, dx, dy, draw_dashed_line, draw_vertices); } else { EraseHighLightForSmooth(psssi, dx, dy, draw_dashed_line, draw_vertices); } } XPoint *DupVs(pn_return, vs, n) int *pn_return, n; XPoint *vs; { XPoint *vs_return=(XPoint*)malloc(n*sizeof(XPoint)); if (vs_return == NULL) FailAllocMessage(); memcpy(vs_return, vs, n*sizeof(XPoint)); *pn_return = n; return vs_return; } void MoveATransformedPoint(obj_ptr, vs, abs_dx, abs_dy) struct ObjRec *obj_ptr; IntPoint *vs; int abs_dx, abs_dy; { int x=0, y=0; TransformPointThroughCTM(vs->x-obj_ptr->x, vs->y-obj_ptr->y, obj_ptr->ctm, &x, &y); x += obj_ptr->x + abs_dx; y += obj_ptr->y + abs_dy; ReverseTransformPointThroughCTM(x-obj_ptr->x, y-obj_ptr->y, obj_ptr->ctm, &x, &y); vs->x = x + obj_ptr->x; vs->y = y + obj_ptr->y; } void UpdateObjForStretchStructSpline(obj_ptr, n, vs, abs_dx, abs_dy, psssi) struct ObjRec *obj_ptr; int n, abs_dx, abs_dy; IntPoint *vs; StretchStructuredSplineInfo *psssi; { int index=psssi->orig_hinge_index; if (obj_ptr->ctm == NULL) { if (psssi->hinge) { if (!psssi->prev_valid) { /* first poly point */ vs[0].x += abs_dx; vs[0].y += abs_dy; vs[1].x += abs_dx; vs[1].y += abs_dy; } else if (!psssi->next_valid) { /* last poly point */ vs[n-1].x += abs_dx; vs[n-1].y += abs_dy; vs[n-2].x += abs_dx; vs[n-2].y += abs_dy; } else { if (obj_ptr->type == OBJ_POLYGON && index == 0) { vs[0].x += abs_dx; vs[0].y += abs_dy; vs[1].x += abs_dx; vs[1].y += abs_dy; /* since it's a polygon */ vs[n-1].x += abs_dx; vs[n-1].y += abs_dy; vs[n-2].x += abs_dx; vs[n-2].y += abs_dy; } else if (obj_ptr->type == OBJ_POLYGON && index == n-1) { vs[n-1].x += abs_dx; vs[n-1].y += abs_dy; vs[n-2].x += abs_dx; vs[n-2].y += abs_dy; /* since it's a polygon */ vs[0].x += abs_dx; vs[0].y += abs_dy; vs[1].x += abs_dx; vs[1].y += abs_dy; } else { vs[index-1].x += abs_dx; vs[index-1].y += abs_dy; vs[index].x += abs_dx; vs[index].y += abs_dy; vs[index+1].x += abs_dx; vs[index+1].y += abs_dy; } } } else { if (!psssi->prev_valid) { /* first poly point */ vs[1].x += abs_dx; vs[1].y += abs_dy; if (obj_ptr->type == OBJ_POLYGON && index == 0) { vs[n-2].x = ((vs[0].x) << 1) - vs[1].x; vs[n-2].y = ((vs[0].y) << 1) - vs[1].y; } } else if (!psssi->next_valid) { /* last poly point */ vs[n-2].x += abs_dx; vs[n-2].y += abs_dy; if (obj_ptr->type == OBJ_POLYGON && index == n-1) { vs[1].x = ((vs[n-1].x) << 1) - vs[n-2].x; vs[1].y = ((vs[n-1].y) << 1) - vs[n-2].y; } } else { if (psssi->earlier_smooth_selected) { if (obj_ptr->type == OBJ_POLYGON && (index == 0 || index == n-1)) { vs[n-2].x += abs_dx; vs[n-2].y += abs_dy; /* since it's a polygon */ vs[1].x = ((vs[n-1].x) << 1) - vs[n-2].x; vs[1].y = ((vs[n-1].y) << 1) - vs[n-2].y; } else { vs[index-1].x += abs_dx; vs[index-1].y += abs_dy; vs[index+1].x = ((vs[index].x) << 1) - vs[index-1].x; vs[index+1].y = ((vs[index].y) << 1) - vs[index-1].y; } } else { if (obj_ptr->type == OBJ_POLYGON && (index == 0 || index == n-1)) { vs[1].x += abs_dx; vs[1].y += abs_dy; /* since it's a polygon */ vs[n-2].x = ((vs[0].x) << 1) - vs[1].x; vs[n-2].y = ((vs[0].y) << 1) - vs[1].y; } else { vs[index+1].x += abs_dx; vs[index+1].y += abs_dy; vs[index-1].x = ((vs[index].x) << 1) - vs[index+1].x; vs[index-1].y = ((vs[index].y) << 1) - vs[index+1].y; } } } } } else { if (psssi->hinge) { if (!psssi->prev_valid) { /* first poly point */ MoveATransformedPoint(obj_ptr, &vs[0], abs_dx, abs_dy); MoveATransformedPoint(obj_ptr, &vs[1], abs_dx, abs_dy); if (obj_ptr->type == OBJ_POLYGON && index == 0) { MoveATransformedPoint(obj_ptr, &vs[n-1], abs_dx, abs_dy); MoveATransformedPoint(obj_ptr, &vs[n-2], abs_dx, abs_dy); } } else if (!psssi->next_valid) { /* last poly point */ MoveATransformedPoint(obj_ptr, &vs[n-1], abs_dx, abs_dy); MoveATransformedPoint(obj_ptr, &vs[n-2], abs_dx, abs_dy); if (obj_ptr->type == OBJ_POLYGON && index == n-1) { MoveATransformedPoint(obj_ptr, &vs[0], abs_dx, abs_dy); MoveATransformedPoint(obj_ptr, &vs[1], abs_dx, abs_dy); } } else { if (obj_ptr->type == OBJ_POLYGON && index == 0) { MoveATransformedPoint(obj_ptr, &vs[0], abs_dx, abs_dy); MoveATransformedPoint(obj_ptr, &vs[1], abs_dx, abs_dy); /* since it's a polygon */ MoveATransformedPoint(obj_ptr, &vs[n-1], abs_dx, abs_dy); MoveATransformedPoint(obj_ptr, &vs[n-2], abs_dx, abs_dy); } else if (obj_ptr->type == OBJ_POLYGON && index == n-1) { MoveATransformedPoint(obj_ptr, &vs[n-1], abs_dx, abs_dy); MoveATransformedPoint(obj_ptr, &vs[n-2], abs_dx, abs_dy); /* since it's a polygon */ MoveATransformedPoint(obj_ptr, &vs[0], abs_dx, abs_dy); MoveATransformedPoint(obj_ptr, &vs[1], abs_dx, abs_dy); } else { MoveATransformedPoint(obj_ptr, &vs[index-1], abs_dx, abs_dy); MoveATransformedPoint(obj_ptr, &vs[index], abs_dx, abs_dy); MoveATransformedPoint(obj_ptr, &vs[index+1], abs_dx, abs_dy); } } } else { if (!psssi->prev_valid) { /* first poly point */ MoveATransformedPoint(obj_ptr, &vs[1], abs_dx, abs_dy); if (obj_ptr->type == OBJ_POLYGON && index == 0) { vs[n-2].x = ((vs[0].x) << 1) - vs[1].x; vs[n-2].y = ((vs[0].y) << 1) - vs[1].y; } } else if (!psssi->next_valid) { /* last poly point */ MoveATransformedPoint(obj_ptr, &vs[n-2], abs_dx, abs_dy); if (obj_ptr->type == OBJ_POLYGON && index == n-1) { vs[1].x = ((vs[n-1].x) << 1) - vs[n-2].x; vs[1].y = ((vs[n-1].y) << 1) - vs[n-2].y; } } else { if (psssi->earlier_smooth_selected) { if (obj_ptr->type == OBJ_POLYGON && (index == 0 || index == n-1)) { MoveATransformedPoint(obj_ptr, &vs[n-2], abs_dx, abs_dy); /* since it's a polygon */ vs[1].x = ((vs[n-1].x) << 1) - vs[n-2].x; vs[1].y = ((vs[n-1].y) << 1) - vs[n-2].y; } else { MoveATransformedPoint(obj_ptr, &vs[index-1], abs_dx, abs_dy); vs[index+1].x = ((vs[index].x) << 1) - vs[index-1].x; vs[index+1].y = ((vs[index].y) << 1) - vs[index-1].y; } } else { if (obj_ptr->type == OBJ_POLYGON && (index == 0 || index == n-1)) { MoveATransformedPoint(obj_ptr, &vs[1], abs_dx, abs_dy); /* since it's a polygon */ vs[n-2].x = ((vs[0].x) << 1) - vs[1].x; vs[n-2].y = ((vs[0].y) << 1) - vs[1].y; } else { MoveATransformedPoint(obj_ptr, &vs[index+1], abs_dx, abs_dy); vs[index-1].x = ((vs[index].x) << 1) - vs[index+1].x; vs[index-1].y = ((vs[index].y) << 1) - vs[index+1].y; } } } } } } static void StretchStructSpline(XGridOff, YGridOff, ObjPtr, Index) int XGridOff, YGridOff, Index; struct ObjRec *ObjPtr; { struct PolyRec *poly_ptr=NULL; struct PolygonRec *polygon_ptr=NULL; struct AttrRec *name_attr=NULL, *on_reshape_attr=NULL; int i, x, y, dx, dy, stretching=TRUE; int ltx=0, lty=0, rbx=0, rby=0; int grid_x=XGridOff, grid_y=YGridOff, sn=0, sn2=0, saved_sn=0, saved_sn2=0; int auto_center_attr=AutoCenterAttr(ObjPtr); int has_on_reshape=HasOnReshape(ObjPtr, &name_attr); int num_vs=0, num_vs2=0, ruler_x=0, ruler_y=0, n=0; char smooth[5], smooth2[5]; XEvent input, ev; XPoint *sv=NULL, *sv2=NULL, *saved_sv=NULL, *saved_sv2=NULL; IntPoint vs[5], vs2[5], start_v, *vlist=NULL, *pvs=NULL; StretchStructuredSplineInfo sssi; if (ObjPtr->locked) { Msg(TgLoadString(STID_LOCKED_OBJS_CANT_BE_STRETCHED)); return; } memset(&sssi, 0, sizeof(StretchStructuredSplineInfo)); memset(vs, 0, 5*sizeof(IntPoint)); memset(vs2, 0, 5*sizeof(IntPoint)); switch (ObjPtr->type) { case OBJ_POLY: poly_ptr = ObjPtr->detail.p; start_v.x = poly_ptr->ssvlist[Index].x; start_v.y = poly_ptr->ssvlist[Index].y; n = poly_ptr->n; pvs = poly_ptr->vlist; break; case OBJ_POLYGON: polygon_ptr = ObjPtr->detail.g; start_v.x = polygon_ptr->ssvlist[Index].x; start_v.y = polygon_ptr->ssvlist[Index].y; n = polygon_ptr->n; pvs = polygon_ptr->vlist; break; } vlist = (IntPoint*)malloc((n+1)*sizeof(IntPoint)); if (vlist == NULL) FailAllocMessage(); memset(vlist, 0, (n+1)*sizeof(IntPoint)); if (ObjPtr->ctm == NULL) { for (i=0; i < n; i++) { vlist[i].x = pvs[i].x; vlist[i].y = pvs[i].y; } } else { for (i=0; i < n; i++) { TransformPointThroughCTM(pvs[i].x-ObjPtr->x, pvs[i].y-ObjPtr->y, ObjPtr->ctm, &x, &y); vlist[i].x = x+ObjPtr->x; vlist[i].y = y+ObjPtr->y; } } if (poly_ptr != NULL) { SetIPTInfoForStretchPoly(Index, n, vlist, &sssi); } else if (polygon_ptr != NULL) { SetIPTInfoForStretchPolygon(Index, n, vlist, &sssi); } SetVsAndVs2ForStretchStructSpline(&sssi, 0, 0, &num_vs, vs, &num_vs2, vs2); FixUpSmoothAndSmooth2ForStretchStructSpline(num_vs, smooth, num_vs2, smooth2); if (sssi.prev_valid) { sv = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &sn, smooth, drawOrigX, drawOrigY, num_vs, vs); saved_sv = DupVs(&saved_sn, sv, sn); } if (sssi.next_valid) { sv2 = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &sn2, smooth2, drawOrigX, drawOrigY, num_vs2, vs2); saved_sv2 = DupVs(&saved_sn2, sv2, sn2); } ltx = ObjPtr->bbox.ltx - handleSize; lty = ObjPtr->bbox.lty - handleSize; rbx = ObjPtr->bbox.rbx + handleSize; rby = ObjPtr->bbox.rby + handleSize; XFlush(mainDisplay); XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } EraseHighLightForStretchStructSpline(&sssi, 0, 0, TRUE, FALSE); DoStretchStructSplineMeasureCursor(STRETCH_STARTSHOW, &start_v, 0, 0, grid_x, grid_y); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } dx = dy = 0; while (stretching) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); stretching = FALSE; } else if (input.type == MotionNotify || input.type == KeyPress || input.type == KeyRelease) { DoStretchStructSplineMeasureCursor(STRETCH_DOSHOW, &start_v, ABS_SIZE(grid_x-XGridOff), ABS_SIZE(grid_y-YGridOff), grid_x, grid_y); if (input.type == KeyPress || input.type == KeyRelease ) { x = grid_x; y = grid_y; } else { x = input.xmotion.x; y = input.xmotion.y; } if (shiftForDiagMouseMove && DiagEventCheck(&input)) { if (input.type == KeyRelease) { x = input.xkey.x; y = input.xkey.y; } else { DiagGridXY(XGridOff, YGridOff, &x, &y); } } GridXY(x, y, &grid_x, &grid_y); /* erase */ if (sv != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); free(sv); sv = NULL; } if (sv2 != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv2, sn2, CoordModeOrigin); free(sv2); sv2 = NULL; } EraseHighLightForStretchStructSpline(&sssi, ABS_SIZE(dx), ABS_SIZE(dy), TRUE, TRUE); dx = grid_x - XGridOff; dy = grid_y - YGridOff; ruler_x = OFFSET_X(start_v.x) + dx; ruler_y = OFFSET_Y(start_v.y) + dy; MarkRulers(ruler_x, ruler_y); /* draw */ SetVsAndVs2ForStretchStructSpline(&sssi, ABS_SIZE(dx), ABS_SIZE(dy), &num_vs, vs, &num_vs2, vs2); FixUpSmoothAndSmooth2ForStretchStructSpline(num_vs, smooth, num_vs2, smooth2); if (sssi.prev_valid) { sv = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &sn, smooth, drawOrigX, drawOrigY, num_vs, vs); XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); } if (sssi.next_valid) { sv2 = MakeMultiSplinePolyVertex(LT_STRUCT_SPLINE, &sn2, smooth2, drawOrigX, drawOrigY, num_vs2, vs2); XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv2, sn2, CoordModeOrigin); } EraseHighLightForStretchStructSpline(&sssi, ABS_SIZE(dx), ABS_SIZE(dy), TRUE, TRUE); DoStretchStructSplineMeasureCursor(STRETCH_DOSHOW, &start_v, ABS_SIZE(grid_x-XGridOff), ABS_SIZE(grid_y-YGridOff), grid_x, grid_y); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } DoStretchStructSplineMeasureCursor(STRETCH_ENDSHOW, &start_v, ABS_SIZE(grid_x-XGridOff), ABS_SIZE(grid_y-YGridOff), grid_x, grid_y); /* erase */ if (sv != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); free(sv); sv = NULL; } if (sv2 != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv2, sn2, CoordModeOrigin); free(sv2); sv2 = NULL; } if (saved_sv != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, saved_sv, saved_sn, CoordModeOrigin); free(saved_sv); saved_sv = NULL; } if (saved_sv2 != NULL) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, saved_sv2, saved_sn2, CoordModeOrigin); free(saved_sv2); saved_sv2 = NULL; } EraseHighLightForStretchStructSpline(&sssi, ABS_SIZE(dx), ABS_SIZE(dy), TRUE, TRUE); EraseHighLightForHinge(&sssi, 0, 0, FALSE, TRUE); if (dx != 0 || dy != 0) { if (has_on_reshape && name_attr != NULL) { on_reshape_attr = FindAttrWithName(ObjPtr, "on_reshape=", NULL); } HighLightReverse(); if (on_reshape_attr != NULL) { StartCompositeCmd(); } PrepareToReplaceAnObj(ObjPtr); if (poly_ptr != NULL) { UpdateObjForStretchStructSpline(ObjPtr, poly_ptr->n, poly_ptr->vlist, ABS_SIZE(dx), ABS_SIZE(dy), &sssi); AdjObjSplineVs(ObjPtr); UpdPolyBBox(ObjPtr, poly_ptr->ssn, poly_ptr->ssvlist); } else if (polygon_ptr != NULL) { UpdateObjForStretchStructSpline(ObjPtr, polygon_ptr->n, polygon_ptr->vlist, ABS_SIZE(dx), ABS_SIZE(dy), &sssi); AdjObjSplineVs(ObjPtr); UpdPolyBBox(ObjPtr, polygon_ptr->ssn, polygon_ptr->ssvlist); } if (auto_center_attr) { struct AttrRec *attr_ptr=ObjPtr->fattr; int modified=FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { struct BBRec bbox; CenterObjInOBBox(attr_ptr->obj, ObjPtr->obbox, &bbox); if (bbox.ltx < ltx) ltx = bbox.ltx; if (bbox.lty < lty) lty = bbox.lty; if (bbox.rbx > rbx) rbx = bbox.rbx; if (bbox.rby > rby) rby = bbox.rby; modified = TRUE; } } if (modified) AdjObjBBox(ObjPtr); } RecordReplaceAnObj(ObjPtr); if (on_reshape_attr != NULL) { DoExec(on_reshape_attr, ObjPtr); } if (on_reshape_attr != NULL) { EndCompositeCmd(); } UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), ObjPtr->bbox.ltx-GRID_ABS_SIZE(1), ObjPtr->bbox.lty-GRID_ABS_SIZE(1), ObjPtr->bbox.rbx+GRID_ABS_SIZE(1), ObjPtr->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; HighLightForward(); } if (sv != NULL) free(sv); if (sv2 != NULL) free(sv2); if (vlist != NULL) free(vlist); } static XPoint v[5]; static void StretchPoly(XGridOff, YGridOff, ObjPtr, NumPts, V, Index) int XGridOff, YGridOff, NumPts, Index; IntPoint *V; struct ObjRec *ObjPtr; { struct AttrRec *name_attr=NULL, *on_reshape_attr=NULL; int i, x, y, dx, dy, stretching=TRUE; int ltx, lty, rbx, rby, curved=LT_STRAIGHT; int grid_x=XGridOff, grid_y=YGridOff, sn, intn; int auto_center_attr=AutoCenterAttr(ObjPtr); int has_on_reshape=HasOnReshape(ObjPtr, &name_attr); char *smooth=NULL; XEvent input, ev; XPoint *sv=NULL; IntPoint *pv=NULL, *cntrlv=NULL; if (ObjPtr->locked) { Msg(TgLoadString(STID_LOCKED_OBJS_CANT_BE_STRETCHED)); return; } pv = (IntPoint*)malloc((NumPts+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); memset(pv, 0, (NumPts+1)*sizeof(IntPoint)); switch (ObjPtr->type) { case OBJ_POLY: curved = ObjPtr->detail.p->curved; if (curved != LT_INTSPLINE && ObjPtr->detail.p->smooth != NULL) { smooth = (char*)malloc((NumPts+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); } if (ObjPtr->ctm == NULL) { for (i = 0; i < NumPts; i++) { pv[i].x = V[i].x; pv[i].y = V[i].y; if (smooth != NULL) smooth[i] = ObjPtr->detail.p->smooth[i]; } } else { for (i = 0; i < NumPts; i++) { int x, y; TransformPointThroughCTM(V[i].x-ObjPtr->x, V[i].y-ObjPtr->y, ObjPtr->ctm, &x, &y); pv[i].x = x+ObjPtr->x; pv[i].y = y+ObjPtr->y; if (smooth != NULL) smooth[i] = ObjPtr->detail.p->smooth[i]; } } switch (curved) { case LT_STRAIGHT: case LT_SPLINE: sv = MakeMultiSplinePolyVertex(curved, &sn, smooth, drawOrigX, drawOrigY, NumPts, pv); break; case LT_INTSPLINE: sv = MakeIntSplinePolyVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, NumPts, pv); break; } break; case OBJ_POLYGON: curved = ObjPtr->detail.g->curved; if (curved != LT_INTSPLINE && ObjPtr->detail.g->smooth != NULL) { smooth = (char*)malloc((NumPts+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); } if (ObjPtr->ctm == NULL) { for (i = 0; i < NumPts; i++) { pv[i].x = V[i].x; pv[i].y = V[i].y; if (smooth != NULL) smooth[i] = ObjPtr->detail.g->smooth[i]; } } else { for (i = 0; i < NumPts; i++) { int x, y; TransformPointThroughCTM(V[i].x-ObjPtr->x, V[i].y-ObjPtr->y, ObjPtr->ctm, &x, &y); pv[i].x = x+ObjPtr->x; pv[i].y = y+ObjPtr->y; if (smooth != NULL) smooth[i] = ObjPtr->detail.g->smooth[i]; } } switch (curved) { case LT_STRAIGHT: case LT_SPLINE: sv = MakeMultiSplinePolygonVertex(curved, &sn, smooth, drawOrigX, drawOrigY, NumPts, pv); break; case LT_INTSPLINE: sv = MakeIntSplinePolygonVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, NumPts, pv); break; } break; } ltx = ObjPtr->bbox.ltx; lty = ObjPtr->bbox.lty; rbx = ObjPtr->bbox.rbx; rby = ObjPtr->bbox.rby; XFlush(mainDisplay); XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } DoStretchPolyMeasureCursor(STRETCH_STARTSHOW, NumPts, pv, Index, 0, 0, STRETCH_DRAW, STRETCH_CLICK, ObjPtr->type, grid_x, grid_y); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } dx = dy = 0; while (stretching) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); stretching = FALSE; } else if (input.type == MotionNotify || input.type == KeyPress || input.type == KeyRelease) { DoStretchPolyMeasureCursor(STRETCH_DOSHOW, NumPts, pv, Index, ABS_SIZE(grid_x-XGridOff), ABS_SIZE(grid_y-YGridOff), STRETCH_ERASE, STRETCH_DRAG, ObjPtr->type, grid_x, grid_y); if (input.type == KeyPress || input.type == KeyRelease ) { x = grid_x; y = grid_y; } else { x = input.xmotion.x; y = input.xmotion.y; } if (shiftForDiagMouseMove && DiagEventCheck(&input)) { if (input.type == KeyRelease) { x = input.xkey.x; y = input.xkey.y; } else { DiagGridXY(XGridOff, YGridOff, &x, &y); } } GridXY(x, y, &grid_x, &grid_y); XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); dx = grid_x - XGridOff; dy = grid_y - YGridOff; v[1].x = OFFSET_X(V[Index].x) + dx; v[1].y = OFFSET_Y(V[Index].y) + dy; MarkRulers(v[1].x, v[1].y); if (sv != NULL) { free(sv); sv = NULL; } if (ObjPtr->type==OBJ_POLYGON && (Index==0 || Index==NumPts-1)) { if (ObjPtr->ctm == NULL) { pv[0].x = pv[NumPts-1].x = V[0].x + ABS_SIZE(dx); pv[0].y = pv[NumPts-1].y = V[0].y + ABS_SIZE(dy); } else { int x, y; TransformPointThroughCTM(V[0].x-ObjPtr->x, V[0].y-ObjPtr->y, ObjPtr->ctm, &x, &y); pv[0].x = pv[NumPts-1].x = x + ObjPtr->x + ABS_SIZE(dx); pv[0].y = pv[NumPts-1].y = y + ObjPtr->y + ABS_SIZE(dy); } } else { if (ObjPtr->ctm == NULL) { pv[Index].x = V[Index].x + ABS_SIZE(dx); pv[Index].y = V[Index].y + ABS_SIZE(dy); } else { int x, y; TransformPointThroughCTM(V[Index].x-ObjPtr->x, V[Index].y-ObjPtr->y, ObjPtr->ctm, &x, &y); pv[Index].x = x + ObjPtr->x + ABS_SIZE(dx); pv[Index].y = y + ObjPtr->y + ABS_SIZE(dy); } } switch (ObjPtr->type) { case OBJ_POLY: switch (curved) { case LT_STRAIGHT: case LT_SPLINE: sv = MakeMultiSplinePolyVertex(curved, &sn, smooth, drawOrigX, drawOrigY, NumPts, pv); break; case LT_INTSPLINE: free(cntrlv); sv = MakeIntSplinePolyVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, NumPts, pv); break; } break; case OBJ_POLYGON: switch (curved) { case LT_STRAIGHT: case LT_SPLINE: sv = MakeMultiSplinePolygonVertex(curved, &sn, smooth, drawOrigX, drawOrigY, NumPts, pv); break; case LT_INTSPLINE: free(cntrlv); sv = MakeIntSplinePolygonVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, NumPts, pv); break; } break; } XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); DoStretchPolyMeasureCursor(STRETCH_DOSHOW, NumPts, pv, Index, ABS_SIZE(grid_x-XGridOff), ABS_SIZE(grid_y-YGridOff), STRETCH_DRAW, STRETCH_DRAG, ObjPtr->type, grid_x, grid_y); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } DoStretchPolyMeasureCursor(STRETCH_ENDSHOW, NumPts, pv, Index, ABS_SIZE(grid_x-XGridOff), ABS_SIZE(grid_y-YGridOff), STRETCH_ERASE, STRETCH_DRAG, ObjPtr->type, grid_x, grid_y); if (dx != 0 || dy != 0) { if (has_on_reshape && name_attr != NULL) { on_reshape_attr = FindAttrWithName(ObjPtr, "on_reshape=", NULL); } XDrawLines(mainDisplay, drawWindow, revDefaultGC, sv, sn, CoordModeOrigin); HighLightReverse(); if (on_reshape_attr != NULL) { StartCompositeCmd(); } PrepareToReplaceAnObj(ObjPtr); dx = ABS_SIZE(dx); dy = ABS_SIZE(dy); switch (ObjPtr->type) { case OBJ_POLY: if (ObjPtr->ctm == NULL) { V[Index].x += dx; V[Index].y += dy; } else { int x, y, new_x, new_y; TransformPointThroughCTM(V[Index].x-ObjPtr->x, V[Index].y-ObjPtr->y, ObjPtr->ctm, &x, &y); x += ObjPtr->x + dx; y += ObjPtr->y + dy; ReverseTransformPointThroughCTM(x-ObjPtr->x, y-ObjPtr->y, ObjPtr->ctm, &new_x, &new_y); V[Index].x = new_x + ObjPtr->x; V[Index].y = new_y + ObjPtr->y; } AdjObjSplineVs(ObjPtr); if (ObjPtr->detail.p->curved != LT_INTSPLINE) { UpdPolyBBox(ObjPtr, NumPts, V); } else { UpdPolyBBox(ObjPtr, ObjPtr->detail.p->intn, ObjPtr->detail.p->intvlist); } break; case OBJ_POLYGON: if (ObjPtr->ctm == NULL) { V[Index].x += dx; V[Index].y += dy; } else { int x, y, new_x, new_y; TransformPointThroughCTM(V[Index].x-ObjPtr->x, V[Index].y-ObjPtr->y, ObjPtr->ctm, &x, &y); x += ObjPtr->x + dx; y += ObjPtr->y + dy; ReverseTransformPointThroughCTM(x-ObjPtr->x, y-ObjPtr->y, ObjPtr->ctm, &new_x, &new_y); V[Index].x = new_x + ObjPtr->x; V[Index].y = new_y + ObjPtr->y; } if (Index == 0) { V[NumPts-1].x = V[Index].x; V[NumPts-1].y = V[Index].y; } else if (Index == NumPts-1) { V[0].x = V[Index].x; V[0].y = V[Index].y; } AdjObjSplineVs(ObjPtr); if (ObjPtr->detail.g->curved != LT_INTSPLINE) { UpdPolyBBox(ObjPtr, NumPts, V); } else { UpdPolyBBox(ObjPtr, ObjPtr->detail.g->intn, ObjPtr->detail.g->intvlist); } break; } if (auto_center_attr) { struct AttrRec *attr_ptr=ObjPtr->fattr; int modified=FALSE; for ( ; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { struct BBRec bbox; CenterObjInOBBox(attr_ptr->obj, ObjPtr->obbox, &bbox); if (bbox.ltx < ltx) ltx = bbox.ltx; if (bbox.lty < lty) lty = bbox.lty; if (bbox.rbx > rbx) rbx = bbox.rbx; if (bbox.rby > rby) rby = bbox.rby; modified = TRUE; } } if (modified) AdjObjBBox(ObjPtr); } RecordReplaceAnObj(ObjPtr); if (on_reshape_attr != NULL) { DoExec(on_reshape_attr, ObjPtr); } if (on_reshape_attr != NULL) { EndCompositeCmd(); } UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), ObjPtr->bbox.ltx-GRID_ABS_SIZE(1), ObjPtr->bbox.lty-GRID_ABS_SIZE(1), ObjPtr->bbox.rbx+GRID_ABS_SIZE(1), ObjPtr->bbox.rby+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; HighLightForward(); } free(pv); if (sv != NULL) free(sv); if (smooth != NULL) free(smooth); if (curved == LT_INTSPLINE && cntrlv != NULL) free(cntrlv); } static double multX=(double)0.0, multY=(double)0.0; static int pivotX=0, pivotY=0, changeX=0, changeY=0, moveX=0, moveY=0; static int absPivotX=0, absPivotY=0; static void StretchedXY(X, Y, NewX, NewY) int X, Y, * NewX, * NewY; /* screen offsets */ { register int dx, dy; dx = round((double)((double)(X - pivotX) * multX)); dy = round((double)((double)(Y - pivotY) * multY)); *NewX = pivotX + dx; *NewY = pivotY + dy; } static void StretchedAbsXY(X, Y, NewX, NewY) int X, Y, * NewX, * NewY; /* screen offsets */ { register int dx, dy; dx = round((double)((double)(X - absPivotX) * multX)); dy = round((double)((double)(Y - absPivotY) * multY)); *NewX = absPivotX + dx; *NewY = absPivotY + dy; } static void ShearedXY(Corner, x, y, dx_shear, dy_shear, dx_scale, dy_scale, new_x, new_y) int Corner, x, y, *new_x, *new_y; double dx_shear, dy_shear, dx_scale, dy_scale; { double val, dx, dy; if (Corner != CORNER_NONE && Corner != CORNER_RIGHT && Corner != CORNER_LEFT) { if (y == pivotY) { *new_x = x; *new_y = y; } else { dy = ((double)(y-pivotY))*dy_scale/1000.0; val = tan(dx_shear/1000.0)*dy; *new_x = round(val + x); *new_y = round(dy + pivotY); } } if (Corner != CORNER_NONE && Corner != CORNER_TOP && Corner != CORNER_BOTTOM) { if (x == pivotX) { *new_x = x; *new_y = y; } else { dx = ((double)(x-pivotX))*dx_scale/1000.0; val = tan(dy_shear/1000.0)*dx; *new_x = round(dx + pivotX); *new_y = round(val + y); } } } static void ShearedAbsXY(Corner, abs_x, abs_y, dx_shear, dy_shear, dx_scale, dy_scale, new_x, new_y) int Corner, abs_x, abs_y, *new_x, *new_y; double dx_shear, dy_shear, dx_scale, dy_scale; { double val, dx, dy; if (Corner != CORNER_NONE && Corner != CORNER_RIGHT && Corner != CORNER_LEFT) { if (abs_y == absPivotY) { *new_x = abs_x; *new_y = abs_y; } else { dy = ((double)(abs_y-absPivotY))*dy_scale/1000.0; val = tan(dx_shear/1000.0)*dy; *new_x = round(val + abs_x); *new_y = round(dy + absPivotY); } } if (Corner != CORNER_NONE && Corner != CORNER_TOP && Corner != CORNER_BOTTOM) { if (abs_x == absPivotX) { *new_x = abs_x; *new_y = abs_y; } else { dx = ((double)(abs_x-absPivotX))*dx_scale/1000.0; val = tan(dy_shear/1000.0)*dx; *new_x = round(dx + absPivotX); *new_y = round(val + abs_y); } } } static void SetPivot(Corner, pOBBox) int Corner; struct BBRec *pOBBox; /* pivotX, pivotY, moveX, moveY will be set to screen offsets */ { switch (Corner) { case CORNER_NONE: /* same as CORNER_CC */ pivotX = moveX = ((pOBBox->ltx+pOBBox->rbx)>>1); pivotY = moveY = ((pOBBox->lty+pOBBox->rby)>>1); changeX = TRUE; changeY = TRUE; break; case CORNER_LT: pivotX = pOBBox->rbx; pivotY = pOBBox->rby; moveX = pOBBox->ltx; moveY = pOBBox->lty; changeX = changeY = TRUE; break; case CORNER_TOP: pivotX = moveX = ((pOBBox->ltx+pOBBox->rbx)>>1); pivotY = pOBBox->rby; moveY = pOBBox->lty; changeX = FALSE; changeY = TRUE; break; case CORNER_RT: pivotX = pOBBox->ltx; pivotY = pOBBox->rby; moveX = pOBBox->rbx; moveY = pOBBox->lty; changeX = changeY = TRUE; break; case CORNER_RIGHT: pivotX = pOBBox->ltx; pivotY = moveY = ((pOBBox->lty+pOBBox->rby)>>1); moveX = pOBBox->rbx; changeX = TRUE; changeY = FALSE; break; case CORNER_RB: pivotX = pOBBox->ltx; pivotY = pOBBox->lty; moveX = pOBBox->rbx; moveY = pOBBox->rby; changeX = changeY = TRUE; break; case CORNER_BOTTOM: pivotX = moveX = ((pOBBox->ltx+pOBBox->rbx)>>1); pivotY = pOBBox->lty; moveY = pOBBox->rby; changeX = FALSE; changeY = TRUE; break; case CORNER_LB: pivotX = pOBBox->rbx; pivotY = pOBBox->lty; moveX = pOBBox->ltx; moveY = pOBBox->rby; changeX = changeY = TRUE; break; case CORNER_LEFT: pivotX = pOBBox->rbx; pivotY = moveY = ((pOBBox->lty+pOBBox->rby)>>1); moveX = pOBBox->ltx; changeX = TRUE; changeY = FALSE; break; } multX = 1.0; multY = 1.0; absPivotX = pivotX; absPivotY = pivotY; pivotX = OFFSET_X(absPivotX); pivotY = OFFSET_Y(absPivotY); moveX = OFFSET_X(moveX); moveY = OFFSET_Y(moveY); } void ShearObj(ObjPtr, Corner, dxShear, dyShear, dxScale, dyScale, RealLtX, RealLtY) struct ObjRec *ObjPtr; int Corner; double dxShear, dyShear, dxScale, dyScale; /* scaled by 1000 */ int *RealLtX, *RealLtY; { IntPoint abs_obj_obbox_vs[5]; int x, y, new_ltx, new_lty, new_rbx, new_rby; double tan_val; struct XfrmMtrxRec ctm, new_ctm; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; int auto_center_attr=AutoCenterAttr(ObjPtr); switch (ObjPtr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: for (obj_ptr=ObjPtr->detail.r->first; obj_ptr != NULL; obj_ptr=obj_ptr->next) { ShearObj(obj_ptr, Corner, dxShear, dyShear, dxScale, dyScale, RealLtX, RealLtY); } break; default: if (ObjPtr->ctm == NULL) { memcpy(&ObjPtr->orig_obbox, &ObjPtr->obbox, sizeof(struct BBRec)); if (ObjPtr->type == OBJ_TEXT) { memcpy(&ObjPtr->detail.t->orig_bbox, &ObjPtr->bbox, sizeof(struct BBRec)); } ObjPtr->ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ObjPtr->ctm == NULL) FailAllocMessage(); ObjPtr->ctm->m[CTM_SX] = ObjPtr->ctm->m[CTM_SY] = (double)1000; ObjPtr->ctm->m[CTM_SIN] = ObjPtr->ctm->m[CTM_MSIN] = (double)0; ObjPtr->ctm->t[CTM_TX] = ObjPtr->ctm->t[CTM_TY] = 0; } ShearedAbsXY(Corner, ObjPtr->x+ObjPtr->ctm->t[CTM_TX], ObjPtr->y+ObjPtr->ctm->t[CTM_TY], dxShear, dyShear, dxScale, dyScale, &x, &y); switch (Corner) { case CORNER_TOP: case CORNER_BOTTOM: tan_val = tan(dxShear/1000.0); ctm.m[CTM_SX] = (double)1000; ctm.m[CTM_SY] = dyScale; ctm.m[CTM_SIN] = (double)0; ctm.m[CTM_MSIN] = dyScale*tan_val; break; case CORNER_RIGHT: case CORNER_LEFT: tan_val = tan(dyShear/1000.0); ctm.m[CTM_SX] = dxScale; ctm.m[CTM_SY] = (double)1000; ctm.m[CTM_SIN] = dxScale*tan_val; ctm.m[CTM_MSIN] = (double)0; break; default: ctm.m[CTM_SX] = dxScale; ctm.m[CTM_SY] = dyScale; ctm.m[CTM_SIN] = (double)0; ctm.m[CTM_MSIN] = (double)0; break; } ctm.t[CTM_TX] = 0; ctm.t[CTM_TY] = 0; ConcatCTM(ObjPtr->ctm, &ctm, &new_ctm); new_ctm.t[CTM_TX] = x-ObjPtr->x; new_ctm.t[CTM_TY] = y-ObjPtr->y; memcpy(ObjPtr->ctm, &new_ctm, sizeof(struct XfrmMtrxRec)); GetTransformedOBBoxAbsVs(ObjPtr, abs_obj_obbox_vs); new_ltx = min(min(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), min(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); new_rbx = max(max(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), max(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); new_lty = min(min(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), min(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); new_rby = max(max(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), max(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); ObjPtr->obbox.ltx = new_ltx; ObjPtr->obbox.lty = new_lty; ObjPtr->obbox.rbx = new_rbx; ObjPtr->obbox.rby = new_rby; if (RealLtX != NULL && RealLtY != NULL) { MoveObj(ObjPtr, (*RealLtX)-new_ltx, (*RealLtY)-new_lty); } if (ObjPtr->ctm->m[CTM_SX] >= 999.0 && ObjPtr->ctm->m[CTM_SX] <= 1001.0 && ObjPtr->ctm->m[CTM_SY] >= 999.0 && ObjPtr->ctm->m[CTM_SY] <= 1001.0 && ObjPtr->ctm->m[CTM_SIN] >= (-1.0) && ObjPtr->ctm->m[CTM_SIN] <= 1.0 && ObjPtr->ctm->m[CTM_MSIN] >= (-1.0) && ObjPtr->ctm->m[CTM_MSIN] <= 1.0) { int dx=ObjPtr->ctm->t[CTM_TX], dy=ObjPtr->ctm->t[CTM_TY]; free(ObjPtr->ctm); ObjPtr->ctm = NULL; memcpy(&ObjPtr->obbox, &ObjPtr->orig_obbox, sizeof(struct BBRec)); if (ObjPtr->type == OBJ_TEXT) { memcpy(&ObjPtr->bbox, &ObjPtr->detail.t->orig_bbox, sizeof(struct BBRec)); } MoveObj(ObjPtr, dx, dy); } break; } AdjObjOBBox(ObjPtr); if (auto_center_attr) { for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { ShearObj(attr_ptr->obj, Corner, dxShear, dyShear, dxScale, dyScale, NULL, NULL); if (attr_ptr->shown) { CenterObjInOBBox(attr_ptr->obj, ObjPtr->obbox, NULL); } } } else { for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { ShearObj(attr_ptr->obj, Corner, dxShear, dyShear, dxScale, dyScale, NULL, NULL); } } AdjObjSplineVs(ObjPtr); AdjObjCache(ObjPtr); AdjObjBBox(ObjPtr); } static void StretchSimpleText(ObjPtr, Corner) struct ObjRec *ObjPtr; int Corner; { /* !stretchableText */ if (ObjPtr->ctm == NULL) { int new_x, new_y, h=ABS_SIZE(ObjPtr->obbox.rby-ObjPtr->obbox.lty); StretchedAbsXY(ObjPtr->x, ObjPtr->y, &new_x, &new_y); MoveObj(ObjPtr, new_x-ObjPtr->x, new_y-ObjPtr->y); ObjPtr->x = new_x; ObjPtr->y = new_y; if (multX < 0) { ObjPtr->detail.t->minilines.just = MAXJUSTS-1-ObjPtr->detail.t->minilines.just; } if (multY < 0) { MoveObj(ObjPtr, 0, -h); } } else { int abs_x, abs_y, new_x, new_y; abs_x = ObjPtr->x+ObjPtr->ctm->t[CTM_TX]; abs_y = ObjPtr->y+ObjPtr->ctm->t[CTM_TY]; StretchedAbsXY(abs_x, abs_y, &new_x, &new_y); if (multX < 0.0 || multY < 0.0) { int new_ltx, new_lty, new_rbx, new_rby; IntPoint abs_obj_obbox_vs[5]; struct XfrmMtrxRec ctm, new_ctm; ctm.m[CTM_SX] = ctm.m[CTM_SY] = (double)1000; ctm.m[CTM_SIN] = ctm.m[CTM_MSIN] = (double)0; ctm.t[CTM_TX] = ctm.t[CTM_TY] = 0; ctm.m[CTM_SX] = (multX < 0.0) ? (double)(-1000) : (double)1000; ctm.m[CTM_SY] = (multY < 0.0) ? (double)(-1000) : (double)1000; ConcatCTM(ObjPtr->ctm, &ctm, &new_ctm); new_ctm.t[CTM_TX] = new_x-ObjPtr->x; new_ctm.t[CTM_TY] = new_y-ObjPtr->y; memcpy(ObjPtr->ctm, &new_ctm, sizeof(struct XfrmMtrxRec)); GetTransformedOBBoxAbsVs(ObjPtr, abs_obj_obbox_vs); new_ltx = min(min(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), min(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); new_rbx = max(max(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), max(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); new_lty = min(min(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), min(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); new_rby = max(max(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), max(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); ObjPtr->obbox.ltx = new_ltx; ObjPtr->obbox.lty = new_lty; ObjPtr->obbox.rbx = new_rbx; ObjPtr->obbox.rby = new_rby; abs_x = ObjPtr->x+ObjPtr->ctm->t[CTM_TX]; abs_y = ObjPtr->y+ObjPtr->ctm->t[CTM_TY]; } MoveObj(ObjPtr, new_x-abs_x, new_y-abs_y); } UpdTextBBox(ObjPtr); AdjObjSplineVs(ObjPtr); AdjObjBBox(ObjPtr); } static int CompoundObjHasTextSubObj(ObjPtr) struct ObjRec *ObjPtr; { struct ObjRec *sub_obj=ObjPtr->detail.r->last; for ( ; sub_obj != NULL; sub_obj=sub_obj->prev) { if (sub_obj->type == OBJ_GROUP || sub_obj->type == OBJ_ICON || sub_obj->type == OBJ_SYM || sub_obj->type == OBJ_PIN) { if (CompoundObjHasTextSubObj(sub_obj)) { return TRUE; } } else { return (sub_obj->type == OBJ_TEXT); } } return FALSE; } static void JustMoveSimpleCompoundObj(ObjPtr, Corner) struct ObjRec *ObjPtr; int Corner; { /* !stretchableText && !compoundObjWithTextStretchableForPSE */ if (ObjPtr->ctm == NULL) { int new_x, new_y, h=ABS_SIZE(ObjPtr->obbox.rby-ObjPtr->obbox.lty); StretchedAbsXY(ObjPtr->x, ObjPtr->y, &new_x, &new_y); MoveObj(ObjPtr, new_x-ObjPtr->x, new_y-ObjPtr->y); ObjPtr->x = new_x; ObjPtr->y = new_y; if (multY < 0) { MoveObj(ObjPtr, 0, -h); } } else { int abs_x, abs_y, new_x, new_y; abs_x = ObjPtr->x+ObjPtr->ctm->t[CTM_TX]; abs_y = ObjPtr->y+ObjPtr->ctm->t[CTM_TY]; StretchedAbsXY(abs_x, abs_y, &new_x, &new_y); if (multX < 0.0 || multY < 0.0) { int new_ltx, new_lty, new_rbx, new_rby; IntPoint abs_obj_obbox_vs[5]; struct XfrmMtrxRec ctm, new_ctm; ctm.m[CTM_SX] = ctm.m[CTM_SY] = (double)1000; ctm.m[CTM_SIN] = ctm.m[CTM_MSIN] = (double)0; ctm.t[CTM_TX] = ctm.t[CTM_TY] = 0; ctm.m[CTM_SX] = (multX < 0.0) ? (double)(-1000) : (double)1000; ctm.m[CTM_SY] = (multY < 0.0) ? (double)(-1000) : (double)1000; ConcatCTM(ObjPtr->ctm, &ctm, &new_ctm); new_ctm.t[CTM_TX] = new_x-ObjPtr->x; new_ctm.t[CTM_TY] = new_y-ObjPtr->y; memcpy(ObjPtr->ctm, &new_ctm, sizeof(struct XfrmMtrxRec)); GetTransformedOBBoxAbsVs(ObjPtr, abs_obj_obbox_vs); new_ltx = min(min(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), min(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); new_rbx = max(max(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), max(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); new_lty = min(min(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), min(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); new_rby = max(max(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), max(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); ObjPtr->obbox.ltx = new_ltx; ObjPtr->obbox.lty = new_lty; ObjPtr->obbox.rbx = new_rbx; ObjPtr->obbox.rby = new_rby; abs_x = ObjPtr->x+ObjPtr->ctm->t[CTM_TX]; abs_y = ObjPtr->y+ObjPtr->ctm->t[CTM_TY]; } MoveObj(ObjPtr, new_x-abs_x, new_y-abs_y); } AdjObjSplineVs(ObjPtr); AdjObjBBox(ObjPtr); } static void StretchAttr(ObjPtr, Corner, dxScale, dyScale, AutoCenterAttr) struct ObjRec *ObjPtr; int Corner, AutoCenterAttr; double dxScale, dyScale; { struct AttrRec *attr_ptr=ObjPtr->fattr; if (attr_ptr == NULL) return; if (stretchingEverything) { struct BBRec final_obbox; double dz=(double)0; if (AutoCenterAttr) { for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { struct ObjRec *obj_ptr=attr_ptr->obj; int ltx=0, lty=0, rbx=0, rby=0; StretchedAbsXY(obj_ptr->obbox.ltx, obj_ptr->obbox.lty, <x, <y); StretchedAbsXY(obj_ptr->obbox.rbx, obj_ptr->obbox.rby, &rbx, &rby); CalcBBox(ltx, lty, rbx, rby, &final_obbox.ltx, &final_obbox.lty, &final_obbox.rbx, &final_obbox.rby); ShearObj(attr_ptr->obj, Corner, dz, dz, dxScale, dyScale, &final_obbox.ltx, &final_obbox.lty); if (attr_ptr->shown) { CenterObjInOBBox(attr_ptr->obj, ObjPtr->obbox, NULL); } } } else { for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { struct ObjRec *obj_ptr=attr_ptr->obj; int ltx=0, lty=0, rbx=0, rby=0; StretchedAbsXY(obj_ptr->obbox.ltx, obj_ptr->obbox.lty, <x, <y); StretchedAbsXY(obj_ptr->obbox.rbx, obj_ptr->obbox.rby, &rbx, &rby); CalcBBox(ltx, lty, rbx, rby, &final_obbox.ltx, &final_obbox.lty, &final_obbox.rbx, &final_obbox.rby); ShearObj(obj_ptr, Corner, dz, dz, dxScale, dyScale, &final_obbox.ltx, &final_obbox.lty); } } } else { if (AutoCenterAttr) { for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->shown) { CenterObjInOBBox(attr_ptr->obj, ObjPtr->obbox, NULL); } else { StretchSimpleText(attr_ptr->obj, Corner); } } } else { for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { StretchSimpleText(attr_ptr->obj, Corner); } } } } static void StretchSimpleArc(ObjPtr) struct ObjRec *ObjPtr; { struct ArcRec *arc_ptr=ObjPtr->detail.a; int x, y; StretchedAbsXY(arc_ptr->xc, arc_ptr->yc, &x, &y); arc_ptr->xc = ObjPtr->x = x; arc_ptr->yc = ObjPtr->y = y; StretchedAbsXY(arc_ptr->x1, arc_ptr->y1, &x, &y); arc_ptr->x1 = x; arc_ptr->y1 = y; StretchedAbsXY(arc_ptr->x2, arc_ptr->y2, &x, &y); arc_ptr->x2 = x; arc_ptr->y2 = y; StretchedAbsXY(arc_ptr->ltx, arc_ptr->lty, &x, &y); arc_ptr->ltx = arc_ptr->xc-abs(x-arc_ptr->xc); arc_ptr->lty = arc_ptr->yc-abs(y-arc_ptr->yc); arc_ptr->w = (arc_ptr->xc-arc_ptr->ltx)<<1; arc_ptr->h = (arc_ptr->yc-arc_ptr->lty)<<1; if (multX < 0) { arc_ptr->dir = !(arc_ptr->dir); arc_ptr->angle2 = -(arc_ptr->angle2); if (arc_ptr->angle1 > 0) { arc_ptr->angle1 = (180*64) - arc_ptr->angle1; } else { arc_ptr->angle1 = (-180*64) - arc_ptr->angle1; } } if (multY < 0) { arc_ptr->dir = !(arc_ptr->dir); arc_ptr->angle1 = -(arc_ptr->angle1); arc_ptr->angle2 = -(arc_ptr->angle2); } AdjObjSplineVs(ObjPtr); AdjObjBBox(ObjPtr); } static void StretchSimplePoly(ObjPtr) struct ObjRec *ObjPtr; { int i, ltx=0, lty=0, rbx=0, rby=0; struct PolyRec *poly_ptr= ObjPtr->detail.p; IntPoint *vs=poly_ptr->vlist; for (i = 0; i < poly_ptr->n; i++) { int x, y; StretchedAbsXY(vs[i].x, vs[i].y, &x, &y); vs[i].x = x; vs[i].y = y; if (i == 0) { ltx = rbx = x; lty = rby = y; } else { if (x < ltx) ltx = x; if (y < lty) lty = y; if (x > rbx) rbx = x; if (y > rby) rby = y; } } ObjPtr->obbox.ltx = ObjPtr->x = ltx; ObjPtr->obbox.lty = ObjPtr->y = lty; ObjPtr->obbox.rbx = rbx; ObjPtr->obbox.rby = rby; AdjObjSplineVs(ObjPtr); if (poly_ptr->curved == LT_INTSPLINE) { UpdPolyBBox(ObjPtr, poly_ptr->intn, poly_ptr->intvlist); } } static void StretchSimplePolygon(ObjPtr) struct ObjRec *ObjPtr; { int i, ltx=0, lty=0, rbx=0, rby=0; struct PolygonRec *polygon_ptr= ObjPtr->detail.g; IntPoint *vs=polygon_ptr->vlist; for (i = 0; i < polygon_ptr->n; i++) { int x, y; StretchedAbsXY(vs[i].x, vs[i].y, &x, &y); vs[i].x = x; vs[i].y = y; if (i == 0) { ltx = rbx = x; lty = rby = y; } else { if (x < ltx) ltx = x; if (y < lty) lty = y; if (x > rbx) rbx = x; if (y > rby) rby = y; } } ObjPtr->obbox.ltx = ObjPtr->x = ltx; ObjPtr->obbox.lty = ObjPtr->y = lty; ObjPtr->obbox.rbx = rbx; ObjPtr->obbox.rby = rby; AdjObjSplineVs(ObjPtr); if (polygon_ptr->curved == LT_INTSPLINE) { UpdPolyBBox(ObjPtr, polygon_ptr->intn, polygon_ptr->intvlist); } } static void StretchSimpleObj(ObjPtr, Corner, dxScale, dyScale, FinalOBBox, auto_center_attr) struct ObjRec *ObjPtr; int Corner, auto_center_attr; double dxScale, dyScale; struct BBRec *FinalOBBox; { ObjPtr->obbox.ltx = ObjPtr->x = FinalOBBox->ltx; ObjPtr->obbox.lty = ObjPtr->y = FinalOBBox->lty; ObjPtr->obbox.rbx = FinalOBBox->rbx; ObjPtr->obbox.rby = FinalOBBox->rby; switch (ObjPtr->type) { case OBJ_ARC: StretchSimpleArc(ObjPtr); break; case OBJ_POLY: StretchSimplePoly(ObjPtr); break; case OBJ_POLYGON: StretchSimplePolygon(ObjPtr); break; case OBJ_RCBOX: AdjObjSplineVs(ObjPtr); break; case OBJ_BOX: AdjObjSplineVs(ObjPtr); break; case OBJ_OVAL: AdjObjSplineVs(ObjPtr); break; } AdjObjOBBox(ObjPtr); StretchAttr(ObjPtr, Corner, dxScale, dyScale, auto_center_attr); AdjObjBBox(ObjPtr); } static void ScaleLineWidth(ObjPtr, dScale) struct ObjRec *ObjPtr; double dScale; { double dscale=(double)(dScale/1000.0); if (!stretchingEverything) return; switch (ObjPtr->type) { case OBJ_POLY: ScaleWidthAndSpec(dscale, &ObjPtr->detail.p->width, ObjPtr->detail.p->width_spec); ScaleWidthAndSpec(dscale, &ObjPtr->detail.p->aw, ObjPtr->detail.p->aw_spec); ScaleWidthAndSpec(dscale, &ObjPtr->detail.p->ah, ObjPtr->detail.p->ah_spec); break; case OBJ_POLYGON: ScaleWidthAndSpec(dscale, &ObjPtr->detail.g->width, ObjPtr->detail.g->width_spec); break; case OBJ_BOX: ScaleWidthAndSpec(dscale, &ObjPtr->detail.b->width, ObjPtr->detail.b->width_spec); break; case OBJ_OVAL: ScaleWidthAndSpec(dscale, &ObjPtr->detail.o->width, ObjPtr->detail.o->width_spec); break; case OBJ_ARC: ScaleWidthAndSpec(dscale, &ObjPtr->detail.a->width, ObjPtr->detail.a->width_spec); ScaleWidthAndSpec(dscale, &ObjPtr->detail.a->aw, ObjPtr->detail.a->aw_spec); ScaleWidthAndSpec(dscale, &ObjPtr->detail.a->ah, ObjPtr->detail.a->ah_spec); break; case OBJ_RCBOX: ScaleWidthAndSpec(dscale, &ObjPtr->detail.rcb->width, ObjPtr->detail.rcb->width_spec); break; } } static void StretchObj(ObjPtr, Corner, dxScale, dyScale, ForceToUseCTM) struct ObjRec *ObjPtr; int Corner, ForceToUseCTM; double dxScale, dyScale; { int ltx, lty, rbx, rby; int auto_center_attr=AutoCenterAttr(ObjPtr); struct BBRec final_obbox; struct ObjRec *obj_ptr=NULL; struct AttrRec *saved_fattr=NULL, *saved_lattr=NULL; double dz=(double)0; StretchedAbsXY(ObjPtr->obbox.ltx, ObjPtr->obbox.lty, <x, <y); StretchedAbsXY(ObjPtr->obbox.rbx, ObjPtr->obbox.rby, &rbx, &rby); CalcBBox(ltx, lty, rbx, rby, &final_obbox.ltx, &final_obbox.lty, &final_obbox.rbx, &final_obbox.rby); if (ForceToUseCTM && ObjPtr->ctm == NULL && ObjPtr->type != OBJ_GROUP && ObjPtr->type != OBJ_ICON && ObjPtr->type != OBJ_SYM && ObjPtr->type != OBJ_PIN) { memcpy(&ObjPtr->orig_obbox, &ObjPtr->obbox, sizeof(struct BBRec)); if (ObjPtr->type == OBJ_TEXT) { memcpy(&ObjPtr->detail.t->orig_bbox, &ObjPtr->bbox, sizeof(struct BBRec)); } ObjPtr->ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ObjPtr->ctm == NULL) FailAllocMessage(); ObjPtr->ctm->m[CTM_SX] = ObjPtr->ctm->m[CTM_SY] = (double)1000; ObjPtr->ctm->m[CTM_SIN] = ObjPtr->ctm->m[CTM_MSIN] = (double)0; ObjPtr->ctm->t[CTM_TX] = ObjPtr->ctm->t[CTM_TY] = 0; } switch (ObjPtr->type) { case OBJ_POLY: case OBJ_POLYGON: case OBJ_BOX: case OBJ_OVAL: case OBJ_ARC: case OBJ_RCBOX: ScaleLineWidth(ObjPtr, dxScale); if (ObjPtr->ctm == NULL) { StretchSimpleObj(ObjPtr, Corner, dxScale, dyScale, &final_obbox, auto_center_attr); } else { ShearObj(ObjPtr, Corner, dz, dz, dxScale, dyScale, &final_obbox.ltx, &final_obbox.lty); } break; case OBJ_TEXT: if (stretchableText) { ShearObj(ObjPtr, Corner, dz, dz, dxScale, dyScale, &final_obbox.ltx, &final_obbox.lty); } else { StretchSimpleText(ObjPtr, Corner); } break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: if (!stretchableText && !compoundObjWithTextStretchableForPSE && CompoundObjHasTextSubObj(ObjPtr)) { JustMoveSimpleCompoundObj(ObjPtr, Corner); } else { for (obj_ptr=ObjPtr->detail.r->first; obj_ptr != NULL; obj_ptr=obj_ptr->next) { StretchObj(obj_ptr, Corner, dxScale, dyScale, ForceToUseCTM); } AdjObjOBBox(ObjPtr); StretchAttr(ObjPtr, Corner, dxScale, dyScale, auto_center_attr); AdjObjSplineVs(ObjPtr); AdjObjBBox(ObjPtr); } break; case OBJ_XBM: case OBJ_XPM: saved_fattr = ObjPtr->fattr; saved_lattr = ObjPtr->lattr; ObjPtr->fattr = ObjPtr->lattr = NULL; ShearObj(ObjPtr, Corner, dz, dz, dxScale, dyScale, &final_obbox.ltx, &final_obbox.lty); ObjPtr->fattr = saved_fattr; ObjPtr->lattr = saved_lattr; StretchAttr(ObjPtr, Corner, dxScale, dyScale, auto_center_attr); AdjObjBBox(ObjPtr); break; } } static void StretchAllSelObjects(Corner, dxScale, dyScale) int Corner; double dxScale, dyScale; { struct SelRec *sel_ptr; for (sel_ptr = topSel; sel_ptr != NULL; sel_ptr = sel_ptr->next) { if (!sel_ptr->obj->locked) { StretchObj(sel_ptr->obj, Corner, dxScale, dyScale, FALSE); } } if (numObjLocked != 0) { Msg(TgLoadString(STID_LOCKED_OBJS_ARE_NOT_STRETCHED)); } } static void MarkObjectsForStretch() { register struct ObjRec *obj_ptr; register struct SelRec *sel_ptr; for (obj_ptr = botObj; obj_ptr != NULL; obj_ptr = obj_ptr->prev) { obj_ptr->marked = FALSE; } for (sel_ptr = botSel; sel_ptr != NULL; sel_ptr = sel_ptr->prev) { sel_ptr->obj->marked = TRUE; } } static int ConstrainedStretchAllSel(Corner, ltx, lty, rbx, rby) int Corner; int *ltx, *lty, *rbx, *rby; { register struct ObjRec *obj_ptr; int something_stretched=FALSE, num_pts; int x_off, y_off, move_first, move_last, x, y; IntPoint *v; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (!obj_ptr->marked && obj_ptr->type==OBJ_POLY && !obj_ptr->locked) { num_pts = obj_ptr->detail.p->n; v = obj_ptr->detail.p->vlist; if (obj_ptr->ctm == NULL) { x_off = OFFSET_X(v[0].x); y_off = OFFSET_Y(v[0].y); move_first = EndPtInSelected(x_off, y_off); x_off = OFFSET_X(v[num_pts-1].x); y_off = OFFSET_Y(v[num_pts-1].y); move_last = EndPtInSelected(x_off, y_off); } else { int tmp_x, tmp_y; TransformPointThroughCTM(v[0].x-obj_ptr->x, v[0].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); tmp_x += obj_ptr->x; tmp_y += obj_ptr->y; x_off = OFFSET_X(tmp_x); y_off = OFFSET_Y(tmp_y); move_first = EndPtInSelected(x_off, y_off); TransformPointThroughCTM(v[num_pts-1].x-obj_ptr->x, v[num_pts-1].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); tmp_x += obj_ptr->x; tmp_y += obj_ptr->y; x_off = OFFSET_X(tmp_x); y_off = OFFSET_Y(tmp_y); move_last = EndPtInSelected(x_off, y_off); } if (move_first || move_last) { int index=INVALID, seg_dx, seg_dy, dx, dy, cur_seg_dx, cur_seg_dy; PrepareToReplaceAnObj(obj_ptr); if (obj_ptr->ctm != NULL) { /* Remove the transformations! */ int i; for (i=0; i < num_pts; i++) { int tmp_x, tmp_y; TransformPointThroughCTM(v[i].x-obj_ptr->x, v[i].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); v[i].x = tmp_x+obj_ptr->x; v[i].y = tmp_y+obj_ptr->y; } free(obj_ptr->ctm); obj_ptr->ctm = NULL; UpdPolyBBox(obj_ptr, num_pts, v); } if (something_stretched) { if (obj_ptr->bbox.ltx < *ltx) *ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < *lty) *lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > *rbx) *rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > *rby) *rby = obj_ptr->bbox.rby; } else { *ltx = obj_ptr->bbox.ltx; *lty = obj_ptr->bbox.lty; *rbx = obj_ptr->bbox.rbx; *rby = obj_ptr->bbox.rby; } something_stretched = TRUE; if (move_first && move_last && num_pts==3) { StretchedAbsXY(v[0].x, v[0].y, &x, &y); dx = x-v[0].x; dy = y-v[0].y; index = 1; cur_seg_dx = v[index-1].x - v[index].x; cur_seg_dy = v[index-1].y - v[index].y; seg_dx = v[index].x - v[index+1].x; seg_dy = v[index].y - v[index+1].y; if (cur_seg_dy==0 && seg_dx==0 && (seg_dy!=0 || (seg_dy==0 && dx==0))) { v[index].y += dy; } else if (cur_seg_dx==0 && seg_dy==0 && (seg_dx!=0 || (seg_dx==0 && dy==0))) { v[index].x += dx; } } else { if (move_first && num_pts>2) { StretchedAbsXY(v[0].x, v[0].y, &x, &y); dx = x-v[0].x; dy = y-v[0].y; index = 1; cur_seg_dx = v[index-1].x - v[index].x; cur_seg_dy = v[index-1].y - v[index].y; seg_dx = v[index].x - v[index+1].x; seg_dy = v[index].y - v[index+1].y; if (cur_seg_dy==0 && cur_seg_dx!=0 && (seg_dy!=0 || (seg_dy==0 && dx==0))) { v[index].y += dy; } else if (cur_seg_dx==0 && cur_seg_dy!=0 && (seg_dx!=0 || (seg_dx==0 && dy==0))) { v[index].x += dx; } } if (move_last && num_pts>2) { StretchedAbsXY(v[num_pts-1].x, v[num_pts-1].y, &x, &y); dx = x-v[num_pts-1].x; dy = y-v[num_pts-1].y; index = num_pts-2; cur_seg_dx = v[index+1].x - v[index].x; cur_seg_dy = v[index+1].y - v[index].y; seg_dx = v[index].x - v[index-1].x; seg_dy = v[index].y - v[index-1].y; if (cur_seg_dy==0 && cur_seg_dx!=0 && (seg_dy!=0 || (seg_dy==0 && dx==0))) { v[index].y += dy; } else if (cur_seg_dx==0 && cur_seg_dy!=0 && (seg_dx!=0 || (seg_dx==0 && dy==0))) { v[index].x += dx; } } } if (move_first) { StretchedAbsXY(v[0].x, v[0].y, &x, &y); v[0].x = x; v[0].y = y; } if (move_last) { StretchedAbsXY(v[num_pts-1].x, v[num_pts-1].y, &x, &y); v[num_pts-1].x = x; v[num_pts-1].y = y; } AdjObjSplineVs(obj_ptr); switch (obj_ptr->type) { case OBJ_POLY: if (obj_ptr->detail.p->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, num_pts, v); } else { UpdPolyBBox(obj_ptr, obj_ptr->detail.p->intn, obj_ptr->detail.p->intvlist); } break; case OBJ_POLYGON: if (obj_ptr->detail.g->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, num_pts, v); } else { UpdPolyBBox(obj_ptr, obj_ptr->detail.g->intn, obj_ptr->detail.g->intvlist); } break; } AdjObjBBox(obj_ptr); if (AutoCenterAttr(obj_ptr)) { struct AttrRec *attr_ptr=obj_ptr->fattr; int modified=FALSE; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { if (attr_ptr->shown) { struct BBRec bbox; CenterObjInOBBox(attr_ptr->obj, obj_ptr->obbox, &bbox); if (bbox.ltx < *ltx) *ltx = bbox.ltx; if (bbox.lty < *lty) *lty = bbox.lty; if (bbox.rbx > *rbx) *rbx = bbox.rbx; if (bbox.rby > *rby) *rby = bbox.rby; modified = TRUE; } } if (modified) AdjObjBBox(obj_ptr); } if (obj_ptr->bbox.ltx < *ltx) *ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < *lty) *lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > *rbx) *rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > *rby) *rby = obj_ptr->bbox.rby; RecordReplaceAnObj(obj_ptr); } } } return something_stretched; } static void StretchAllSel(Corner, dxScale, dyScale) int Corner; double dxScale, dyScale; /* dxScale and dyScale are scaled by 1000 */ { int ltx, lty, rbx, rby, saved_ltx, saved_lty, saved_rbx, saved_rby; int poly_stretched; saved_ltx = selLtX; saved_lty = selLtY; saved_rbx = selRbX; saved_rby = selRbY; if (moveMode==CONST_MOVE) { MarkObjectsForStretch(); StartCompositeCmd(); PrepareToRecord(CMD_STRETCH, topSel, botSel, numObjSelected); RecordCmd(CMD_STRETCH, NULL, topSel, botSel, numObjSelected); poly_stretched = ConstrainedStretchAllSel(Corner, <x, <y, &rbx, &rby); StretchAllSelObjects(Corner, dxScale, dyScale); UpdSelBBox(); if (poly_stretched) { ltx = min(ltx,min(selLtX,saved_ltx)); lty = min(lty,min(selLtY,saved_lty)); rbx = max(rbx,max(selRbX,saved_rbx)); rby = max(rby,max(selRbY,saved_rby)); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); } else { RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } EndCompositeCmd(); } else { PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); StretchAllSelObjects(Corner, dxScale, dyScale); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); UpdSelBBox(); RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } } static int DiagonalDistance(dx, dy) double dx, dy; { double dval=sqrt(dx*dx+dy*dy); return round(dval); } static double DiagonalAngle(dx, dy) int dx, dy; { double theta=((dx==0) ? ((dy>=0) ? M_PI/2.0 : -M_PI/2.0) : atan2((double)(dy), (double)(dx))); return theta*((double)180.0)/M_PI; } static void GetMeasurement(ObjPtr, buf, buf1) struct ObjRec *ObjPtr; char *buf, *buf1; { int ltx, lty, rbx, rby, real_ltx, real_lty, real_rbx, real_rby, dx, dy; char x_buf[80], y_buf[80], d_buf[80]; double diag_angle; StretchedAbsXY(ObjPtr->obbox.ltx, ObjPtr->obbox.lty, <x, <y); StretchedAbsXY(ObjPtr->obbox.rbx, ObjPtr->obbox.rby, &rbx, &rby); CalcBBox(ltx, lty, rbx, rby, &real_ltx, &real_lty, &real_rbx, &real_rby); PixelToMeasurementUnit(x_buf, abs(real_rbx-real_ltx)); PixelToMeasurementUnit(y_buf, abs(real_rby-real_lty)); sprintf(buf, "w=%s\nh=%s", x_buf, y_buf); dx = real_rbx-real_ltx; dy = real_rby-real_lty; PixelToMeasurementUnit(d_buf, abs(DiagonalDistance((double)dx, (double)dy))); diag_angle = DiagonalAngle(dx, dy); sprintf(buf1, "Diagonal: length=%s angle=%.2f or %.2f", d_buf, (float)diag_angle, (float)(((double)360.0)-diag_angle)); } static void PointsToShearScale(Corner, x_pivot, y_pivot, x_move, y_move, x_current, y_current, dx_shear, dy_shear, dx_scale, dy_scale) int Corner, x_pivot, y_pivot, x_move, y_move, x_current, y_current; double *dx_shear, *dy_shear, *dx_scale, *dy_scale; /* the returned shear value is 1000*arctan() */ /* the returned scale value is 1000*scaling */ { int dx=x_current-x_move, dy=y_current-y_move; switch (Corner) { case CORNER_TOP: case CORNER_BOTTOM: if (dx_scale != NULL) *dx_scale = (double)1000; if (dy_scale != NULL) { *dy_scale = (dy == 0 ? (double)1000 : (double)(((double)(y_current-y_pivot)) / ((double)(y_move-y_pivot))*1000.0)); } if (dx_shear != NULL) { *dx_shear = (dx == 0 ? (double)0 : (double)(atan2((double)dx,(double)y_current-y_pivot)*1000.0)); } if (dy_shear != NULL) *dy_shear = (double)0; break; case CORNER_RIGHT: case CORNER_LEFT: if (dx_scale != NULL) { *dx_scale = (dx == 0 ? (double)1000 : (double)(((double)(x_current-x_pivot)) / ((double)(x_move-x_pivot))*1000.0)); } if (dy_scale != NULL) *dy_scale = (double)1000; if (dx_shear != NULL) *dx_shear = (double)0; if (dy_shear != NULL) { *dy_shear = (dy == 0 ? (double)0 : (double)(atan2((double)dy,(double)x_current-x_pivot)*1000.0)); } break; default: /* scaling only, no shearing */ if (dx_scale != NULL) { *dx_scale = (dx == 0 ? (double)1000 : (double)(((double)(x_current-x_pivot)) / ((double)(x_move-x_pivot))*1000.0)); } if (dy_scale != NULL) { *dy_scale = (dy == 0 ? (double)1000 : (double)(((double)(y_current-y_pivot)) / ((double)(y_move-y_pivot))*1000.0)); } if (dx_shear != NULL) *dx_shear = (double)0; if (dy_shear != NULL) *dy_shear = (double)0; break; } } static void StretchBox(XGridOff, YGridOff, ObjPtr, Corner) int XGridOff, YGridOff, Corner; struct ObjRec *ObjPtr; { int x, y, stretching=TRUE; int ltx, lty, rbx, rby, sel_ltx, sel_lty, sel_rbx, sel_rby; int stretched_ltx, stretched_lty, stretched_rbx, stretched_rby; int stretched_sel_ltx, stretched_sel_lty, stretched_sel_rbx; int stretched_sel_rby; int ruler_ltx, ruler_lty, ruler_rbx, ruler_rby; int sel_obj_ltx, sel_obj_lty, sel_obj_rbx, sel_obj_rby; int grid_x=XGridOff, grid_y=YGridOff, proportional=FALSE; char buf[80], buf1[80]; double obj_w, obj_h; XEvent input, ev; if (numObjSelected == numObjLocked || ObjPtr->locked) { MsgBox(TgLoadString(STID_LOCKED_OBJS_CANT_BE_STRETCHED), TOOL_NAME, INFO_MB); return; } XFlush(mainDisplay); XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } SetPivot(Corner, &ObjPtr->obbox); stretched_sel_ltx = sel_ltx = OFFSET_X(selNoLockLtX); stretched_sel_lty = sel_lty = OFFSET_Y(selNoLockLtY); stretched_sel_rbx = sel_rbx = OFFSET_X(selNoLockRbX); stretched_sel_rby = sel_rby = OFFSET_Y(selNoLockRbY); SelBox(drawWindow, revDefaultGC, stretched_sel_ltx-2, stretched_sel_lty-2, stretched_sel_rbx+2, stretched_sel_rby+2); ruler_ltx = sel_obj_ltx = OFFSET_X(selNoLockObjLtX); ruler_lty = sel_obj_lty = OFFSET_Y(selNoLockObjLtY); ruler_rbx = sel_obj_rbx = OFFSET_X(selNoLockObjRbX); ruler_rby = sel_obj_rby = OFFSET_Y(selNoLockObjRbY); stretched_ltx = ltx = OFFSET_X(ObjPtr->obbox.ltx); stretched_lty = lty = OFFSET_Y(ObjPtr->obbox.lty); stretched_rbx = rbx = OFFSET_X(ObjPtr->obbox.rbx); stretched_rby = rby = OFFSET_Y(ObjPtr->obbox.rby); SelBox(drawWindow, revDefaultGC, stretched_ltx, stretched_lty, stretched_rbx, stretched_rby); if (ltx == rbx || lty == rby) { Msg(TgLoadString(ltx == rbx ? STID_CANT_STRETCH_OBJ_HAS_0_WIDTH : STID_CANT_STRETCH_OBJ_HAS_0_HEIGHT)); SelBox(drawWindow, revDefaultGC, stretched_ltx, stretched_lty, stretched_rbx, stretched_rby); SelBox(drawWindow, revDefaultGC, stretched_sel_ltx-2, stretched_sel_lty-2, stretched_sel_rbx+2, stretched_sel_rby+2); return; } SaveStatusStrings(); obj_w = (double)(moveX - pivotX); obj_h = (double)(moveY - pivotY); GetMeasurement(ObjPtr, buf, buf1); StartShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (showMeasurement) SetStringStatus(buf1); BeginIntervalRulers(ruler_ltx, ruler_lty, ruler_rbx, ruler_rby); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } while (stretching) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { proportional = (input.xbutton.state & (ShiftMask|ControlMask)); XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); stretching = FALSE; } else if (input.type == MotionNotify || input.type == KeyPress || input.type == KeyRelease) { proportional = (input.xmotion.state & (ShiftMask|ControlMask)); GetMeasurement(ObjPtr, buf, buf1); EndShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (showMeasurement) SetStringStatus(buf1); if (input.type == KeyPress || input.type == KeyRelease) { x = grid_x; y = grid_y; } else { x = input.xmotion.x; y = input.xmotion.y; } GridXY(x, y, &grid_x, &grid_y); SelBox(drawWindow, revDefaultGC, stretched_ltx, stretched_lty, stretched_rbx, stretched_rby); SelBox(drawWindow, revDefaultGC, stretched_sel_ltx-2, stretched_sel_lty-2, stretched_sel_rbx+2, stretched_sel_rby+2); if (proportional) { int new_w, new_h; double w_ratio, h_ratio; new_w = moveX + grid_x - XGridOff - pivotX; new_h = moveY + grid_y - YGridOff - pivotY; w_ratio = (moveX!=pivotX) ? fabs(((double)new_w)/obj_w) : 0.0; h_ratio = (moveY!=pivotY) ? fabs(((double)new_h)/obj_h) : 0.0; if (changeX && changeY) { if (w_ratio >= h_ratio) { multX = (moveX!=pivotX) ? ((double)new_w)/obj_w : 1.0; multY = fabs(multX) * ((new_h*obj_h>=0) ? 1.0 : -1.0); } else { multX = fabs(multY) * ((new_w*obj_w>=0) ? 1.0 : -1.0); multY = (moveY!=pivotY) ? ((double)new_h)/obj_h : 1.0; } } else if (changeX) { multX = (moveX!=pivotX) ? ((double)new_w)/obj_w : 1.0; multY = fabs(multX); } else if (changeY) { multX = fabs(multY); multY = (moveY!=pivotY) ? ((double)new_h)/obj_h : 1.0; } } else { if (changeX) { multX = (moveX!=pivotX) ? (double)(moveX+grid_x-XGridOff-pivotX)/obj_w : 1.0; } else { multX = (double)1.0; } if (changeY) { multY = (moveY!=pivotY) ? (double)(moveY+grid_y-YGridOff-pivotY)/obj_h : 1.0; } else { multY = (double)1.0; } } StretchedXY(sel_ltx, sel_lty, &stretched_sel_ltx, &stretched_sel_lty); StretchedXY(sel_rbx, sel_rby, &stretched_sel_rbx, &stretched_sel_rby); StretchedXY(ltx, lty, &stretched_ltx, &stretched_lty); StretchedXY(rbx, rby, &stretched_rbx, &stretched_rby); StretchedXY(sel_obj_ltx, sel_obj_lty, &ruler_ltx, &ruler_lty); StretchedXY(sel_obj_rbx, sel_obj_rby, &ruler_rbx, &ruler_rby); DrawIntervalRulers(ruler_ltx, ruler_lty, ruler_rbx, ruler_rby, NULL); SelBox(drawWindow, revDefaultGC, stretched_sel_ltx-2, stretched_sel_lty-2, stretched_sel_rbx+2, stretched_sel_rby+2); SelBox(drawWindow, revDefaultGC, stretched_ltx, stretched_lty, stretched_rbx, stretched_rby); GetMeasurement(ObjPtr, buf, buf1); EndShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (showMeasurement) SetStringStatus(buf1); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } EndIntervalRulers(grid_x, grid_y); GetMeasurement(ObjPtr, buf, buf1); EndShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (showMeasurement) SetStringStatus(buf1); RestoreStatusStrings(); SelBox(drawWindow, revDefaultGC, stretched_ltx, stretched_lty, stretched_rbx, stretched_rby); SelBox(drawWindow, revDefaultGC, stretched_sel_ltx-2, stretched_sel_lty-2, stretched_sel_rbx+2, stretched_sel_rby+2); if (multX != (double)1.0 || multY != (double)1.0) { int num_to_resize=0; double dx_scale=(double)1000, dy_scale=(double)1000; char **ppsz_names_to_resize=NULL; PointsToShearScale(Corner, pivotX, pivotY, moveX, moveY, moveX+grid_x-XGridOff, moveY+grid_y-YGridOff, NULL, NULL, &dx_scale, &dy_scale); if (proportional) { int abs_x_scale=round(dx_scale), abs_y_scale=round(dy_scale); if (abs_x_scale > abs_y_scale) { dy_scale = dx_scale; } else if (abs_x_scale < abs_y_scale) { dx_scale = dy_scale; } } HighLightReverse(); ppsz_names_to_resize = NeedToProcessOnResize(&num_to_resize); if (ppsz_names_to_resize == NULL) { StretchAllSel(Corner, dx_scale, dy_scale); } else { StartCompositeCmd(); StretchAllSel(Corner, dx_scale, dy_scale); DoOnResize(ppsz_names_to_resize, num_to_resize); EndCompositeCmd(); } HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } } void StretchSel(XGridOff, YGridOff, ObjPtr, Corner) int XGridOff, YGridOff, Corner; struct ObjRec *ObjPtr; { switch (ObjPtr->type) { case OBJ_BOX: case OBJ_OVAL: case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: case OBJ_ARC: case OBJ_RCBOX: case OBJ_XBM: case OBJ_XPM: StretchBox(XGridOff, YGridOff, ObjPtr, Corner); break; case OBJ_POLY: if (ObjPtr->detail.p->curved == LT_STRUCT_SPLINE) { StretchStructSpline(XGridOff, YGridOff, ObjPtr, Corner); } else { StretchPoly(XGridOff, YGridOff, ObjPtr, ObjPtr->detail.p->n, ObjPtr->detail.p->vlist, Corner); } break; case OBJ_POLYGON: if (ObjPtr->detail.g->curved == LT_STRUCT_SPLINE) { StretchStructSpline(XGridOff, YGridOff, ObjPtr, Corner); } else { StretchPoly(XGridOff, YGridOff, ObjPtr, ObjPtr->detail.g->n, ObjPtr->detail.g->vlist, Corner); } break; case OBJ_TEXT: if (stretchableText) { StretchBox(XGridOff, YGridOff, ObjPtr, Corner); } break; } } void ScaleAnEPSObj(ObjPtr, ScalingFactor) struct ObjRec *ObjPtr; float *ScalingFactor; { struct BBRec *obbox=(&(ObjPtr->obbox)); multX = multY = (double)(*ScalingFactor); changeX = changeY = (fabs(multX-1.0) > 1.0e-6); if (!changeX && !changeY) return;; absPivotX = obbox->ltx; absPivotY = obbox->lty; moveX = obbox->rbx; moveY = obbox->rby; StretchObj(ObjPtr, CORNER_RB, (double)(multX*1000.0), (double)(multY*1000.0), FALSE); } static void ScaleAllSelObjects(Corner, dxScale, dyScale) int Corner; double dxScale, dyScale; /* * Force to use CTM! */ { struct SelRec *sel_ptr=NULL; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { sel_ptr->obj->tmp_parent = NULL; } for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (stretchingEverything || !sel_ptr->obj->locked) { StretchObj(sel_ptr->obj, Corner, dxScale, dyScale, TRUE); } } if (!stretchingEverything && numObjLocked != 0) { Msg(TgLoadString(STID_LOCKED_OBJS_CANT_BE_SCALED)); } } static void ScaleAllSel(Corner, dxScale, dyScale, redraw) int Corner, redraw; double dxScale, dyScale; { int ltx, lty, rbx, rby, saved_ltx, saved_lty, saved_rbx, saved_rby; int poly_stretched; saved_ltx = selLtX; saved_lty = selLtY; saved_rbx = selRbX; saved_rby = selRbY; if (moveMode == CONST_MOVE) { MarkObjectsForStretch(); StartCompositeCmd(); PrepareToRecord(CMD_STRETCH, topSel, botSel, numObjSelected); RecordCmd(CMD_STRETCH, NULL, topSel, botSel, numObjSelected); poly_stretched = ConstrainedStretchAllSel(Corner, <x, <y, &rbx, &rby); ScaleAllSelObjects(Corner, dxScale, dyScale); UpdSelBBox(); if (redraw) { if (poly_stretched) { ltx = min(ltx,min(selLtX,saved_ltx)); lty = min(lty,min(selLtY,saved_lty)); rbx = max(rbx,max(selRbX,saved_rbx)); rby = max(rby,max(selRbY,saved_rby)); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); } else { RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } } EndCompositeCmd(); } else { PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); ScaleAllSelObjects(Corner, dxScale, dyScale); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); UpdSelBBox(); if (redraw) { RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } } } static char *FindColon(s) register char *s; { while (*s!=':' && *s!='x' && *s!='X' && *s!=' ' && *s!='\0') s++; return ((*s==':' || *s=='x' || *s=='X' || *s==' ') ? (s) : (char *)NULL); } void ScaleAllSelObj() { char spec[MAXSTRING], *y_spec=NULL, **ppsz_names_to_resize=NULL; int corner=INVALID, saved_h_align=horiAlign, saved_v_align=vertAlign; int num_to_resize=0; struct BBRec obbox; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (numObjSelected == numObjLocked) { MsgBox(TgLoadString(STID_LOCKED_OBJS_CANT_BE_SCALED), TOOL_NAME, INFO_MB); return; } *spec = '\0'; Dialog(TgLoadString(STID_ENTER_SCALING_FACTORS_XY), NULL, spec); UtilTrimBlanks(spec); if (*spec == '\0') return; horiAlign = ALIGN_L; vertAlign = ALIGN_T; corner = CORNER_RB; obbox.ltx = selNoLockObjLtX; obbox.lty = selNoLockObjLtY; obbox.rbx = selNoLockObjRbX; obbox.rby = selNoLockObjRbY; SetPivot(corner, &obbox); horiAlign = saved_h_align; vertAlign = saved_v_align; if ((y_spec=FindColon(spec)) == NULL) { if (sscanf(spec, "%lf", &multX) != 1 || multX <= 0.0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } multY = multX; } else { *y_spec++ = '\0'; if (sscanf(spec, "%lf", &multX) != 1 || sscanf(y_spec, "%lf", &multY) != 1 || multX <= 0.0 || multY <= 0.0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } } changeX = (fabs(multX-1.0) > 1.0e-6); changeY = (fabs(multY-1.0) > 1.0e-6); if (!changeX && !changeY) return; horiAlign = ALIGN_L; vertAlign = ALIGN_T; HighLightReverse(); ppsz_names_to_resize = NeedToProcessOnResize(&num_to_resize); if (ppsz_names_to_resize == NULL) { ScaleAllSel(corner, (double)(multX*1000.0), (double)(multY*1000.0), TRUE); } else { StartCompositeCmd(); ScaleAllSel(corner, (double)(multX*1000.0), (double)(multY*1000.0), TRUE); DoOnResize(ppsz_names_to_resize, num_to_resize); EndCompositeCmd(); } HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; horiAlign = saved_h_align; vertAlign = saved_v_align; } void PreciseScaleEverything() { int corner=CORNER_RB, saved_h_align=horiAlign, saved_v_align=vertAlign; int saved_cur_page_num=curPageNum, prev_page_num=curPageNum; int saved_stretchable_text=stretchableText; char spec[MAXSTRING], buf[MAXSTRING]; struct BBRec obbox; *spec = '\0'; Dialog(TgLoadString(STID_ENTER_A_SCALING_FACTOR), NULL, spec); UtilTrimBlanks(spec); if (*spec == '\0') return; obbox.ltx = obbox.lty = 0; obbox.rbx = onePageWidth; obbox.rby = onePageHeight; SetPivot(corner, &obbox); if (FindColon(spec) != NULL) { MsgBox(TgLoadString(STID_ONLY_INPUT_ONE_NUMERIC_VAL), TOOL_NAME, INFO_MB); return; } else if (sscanf(spec, "%lf", &multX) != 1 || multX <= 0.0) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_SPEC), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } else if (fabs(multX-((float)1.0)) < INT_TOL) { return; } if (round(multX) >= 10) { sprintf(gszMsgBox, TgLoadString(STID_SCALING_EVERYTHING_LARGE_SURE), multX); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) != MB_ID_YES) { return; } } multY = multX; changeX = (fabs(multX-1.0) > 1.0e-6); changeY = (fabs(multY-1.0) > 1.0e-6); if (!changeX && !changeY) return; MakeQuiescent(); if (firstCmd != NULL) { if (!OkToFlushUndoBuffer( TgLoadString(STID_PRECISE_SCALE_EV_CAUSE_FLUSH))) { SetCurChoice(curChoiceBeforeMakeQuiescent); return; } } corner = CORNER_RB; horiAlign = ALIGN_L; vertAlign = ALIGN_T; stretchableText = saved_stretchable_text; printMag /= multX; if (UpdPageStyle(pageStyle)) { UpdDrawWinBBox(); AdjSplineVs(); } FormatFloat(&printMag, buf); if (printMag <= 100.0) { sprintf(gszMsgBox, TgLoadString(STID_NEW_REDUCTION_IS_PERCENT), buf); } else { sprintf(gszMsgBox, TgLoadString(STID_NEW_ENLARGEMENT_IS_PERCENT), buf); } Msg(gszMsgBox); SaveStatusStrings(); StartCompositeCmd(); for (curPageNum=1; curPageNum <= lastPageNum; curPageNum++) { int num_to_resize=0; char **ppsz_names_to_resize=NULL; /* No need for the CMD_GOTO_PAGE stuff since CleanUpCmds will be called */ /* PrepareToRecord(CMD_GOTO_PAGE, NULL, NULL, prev_page_num); */ GotoPageNum(curPageNum); ShowPage(); XSync(mainDisplay, False); /* RecordCmd(CMD_GOTO_PAGE, NULL, NULL, NULL, curPageNum); */ prev_page_num = curPageNum; sprintf(gszMsgBox, TgLoadCachedString(CSTID_SCALING_EVERYTHING_PAGE), curPageNum, lastPageNum); SetStringStatus(gszMsgBox); SelAllObj(FALSE, FALSE); ppsz_names_to_resize = NeedToProcessOnResize(&num_to_resize); stretchingEverything = TRUE; ScaleAllSel(corner, (double)(multX*1000.0), (double)(multY*1000.0), TRUE); stretchingEverything = FALSE; if (ppsz_names_to_resize != NULL) { DoOnResize(ppsz_names_to_resize, num_to_resize); } RemoveAllSel(); } /* PrepareToRecord(CMD_GOTO_PAGE, NULL, NULL, prev_page_num); */ GotoPageNum(saved_cur_page_num); ShowPage(); /* RecordCmd(CMD_GOTO_PAGE, NULL, NULL, NULL, saved_cur_page_num); */ EndCompositeCmd(); CleanUpCmds(); RestoreStatusStrings(); SetFileModified(TRUE); justDupped = FALSE; stretchableText = saved_stretchable_text; horiAlign = saved_h_align; vertAlign = saved_v_align; RedrawScrollBars(); RedrawRulers(); RedrawTitleWindow(); ClearAndRedrawDrawWindow(); SetCurChoice(curChoiceBeforeMakeQuiescent); } void ScaleObjLikeScaleEverything(obj_ptr, scale, redraw) struct ObjRec *obj_ptr; double scale; int redraw; { int corner=CORNER_RB, saved_h_align=horiAlign, saved_v_align=vertAlign; int saved_stretchable_text=stretchableText, saved_move_mode=moveMode; float saved_print_mag=printMag; struct BBRec obbox; obbox.ltx = obbox.lty = 0; obbox.rbx = onePageWidth; obbox.rby = onePageHeight; SetPivot(corner, &obbox); if (fabs(scale-((float)1.0)) < INT_TOL) { return; } multX = multY = ((double)1)/scale; changeX = (fabs(multX-1.0) > 1.0e-6); changeY = (fabs(multY-1.0) > 1.0e-6); if (!changeX && !changeY) return; corner = CORNER_RB; horiAlign = ALIGN_L; vertAlign = ALIGN_T; stretchableText = TRUE; moveMode = UNCONST_MOVE; printMag /= multX; if (UpdPageStyle(pageStyle)) { UpdDrawWinBBox(); AdjSplineVs(); } if (multX < 100.0) { sprintf(gszMsgBox, TgLoadString(STID_REDUCE_BY_FACTOR), multX); } else { sprintf(gszMsgBox, TgLoadString(STID_ENLARGE_BY_FACTOR), multX); } SetStringStatus(gszMsgBox); SaveStatusStrings(); AddObj(NULL, topObj, obj_ptr); topSel = botSel = SelectThisObject(obj_ptr); UpdSelBBox(); StartCompositeCmd(); stretchingEverything = TRUE; ScaleAllSel(corner, (double)(multX*1000.0), (double)(multY*1000.0), redraw); stretchingEverything = FALSE; RemoveAllSel(); EndCompositeCmd(); CleanUpCmds(); UnlinkObj(topObj); RestoreStatusStrings(); SetFileModified(TRUE); justDupped = FALSE; moveMode = saved_move_mode; stretchableText = saved_stretchable_text; horiAlign = saved_h_align; vertAlign = saved_v_align; printMag = saved_print_mag; if (UpdPageStyle(pageStyle)) { UpdDrawWinBBox(); AdjSplineVs(); } } void SizeAllSelObj(AbsW, AbsH) int AbsW, AbsH; { int saved_h_align=horiAlign, saved_v_align=vertAlign, num_to_resize=0; char **ppsz_names_to_resize=NULL; struct BBRec obbox; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (AbsW == selObjRbX-selObjLtX && AbsH == selObjRbY-selObjLtY) return; obbox.ltx = selObjLtX; obbox.lty = selObjLtY; obbox.rbx = selObjRbX; obbox.rby = selObjRbY; SetPivot(CORNER_RB, &obbox); horiAlign = ALIGN_L; vertAlign = ALIGN_T; multX = (selObjRbX==selObjLtX ? ((double)1.0) : ((double)AbsW) / ((double)selObjRbX-selObjLtX)); multY = (selObjRbY==selObjLtY ? ((double)1.0) : ((double)AbsH) / ((double)selObjRbY-selObjLtY)); changeX = (fabs(multX-1.0) > 1.0e-6); changeY = (fabs(multY-1.0) > 1.0e-6); ppsz_names_to_resize = NeedToProcessOnResize(&num_to_resize); if (ppsz_names_to_resize == NULL) { ScaleAllSel(CORNER_RB, (double)(multX*1000.0), (double)(multY*1000.0), TRUE); } else { StartCompositeCmd(); ScaleAllSel(CORNER_RB, (double)(multX*1000.0), (double)(multY*1000.0), TRUE); DoOnResize(ppsz_names_to_resize, num_to_resize); EndCompositeCmd(); } horiAlign = saved_h_align; vertAlign = saved_v_align; UpdSelBBox(); SetFileModified(TRUE); justDupped = FALSE; } void SizeAnObj(ObjPtr, TopOwner, AbsW, AbsH) struct ObjRec *ObjPtr, *TopOwner; int AbsW, AbsH; /* This function is meant to be called from within an internal command */ { int obj_w=ObjPtr->obbox.rbx-ObjPtr->obbox.ltx; int obj_h=ObjPtr->obbox.rby-ObjPtr->obbox.lty; if (execCurDepth <= 0) { #ifdef _TGIF_DBG /* debug, do not translate */ TgAssert(FALSE, "SizeAnObj() called not from an internal command!", NULL); return; #endif /* _TGIF_DBG */ } if (obj_w == AbsW && obj_h == AbsH) { return; } if (ObjPtr == TopOwner) { struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; topSel = botSel = NULL; AddObjIntoSel(ObjPtr, NULL, topSel, &topSel, &botSel); UpdSelBBox(); SizeAllSelObj(AbsW, AbsH); RemoveAllSel(); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); } else { int saved_h_align=horiAlign, saved_v_align=vertAlign; int ltx=TopOwner->bbox.ltx, lty=TopOwner->bbox.lty; int rbx=TopOwner->bbox.rbx, rby=TopOwner->bbox.rby; struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel; SetPivot(CORNER_RB, &ObjPtr->obbox); multX = (obj_w == 0) ? ((double)1.0) : ((double)AbsW) / ((double)obj_w); multY = (obj_h == 0) ? ((double)1.0) : ((double)AbsH) / ((double)obj_h); changeX = (fabs(multX-1.0) > 1.0e-6); changeY = (fabs(multY-1.0) > 1.0e-6); if (!changeX && !changeY) { return; } horiAlign = ALIGN_L; vertAlign = ALIGN_T; topSel = botSel = NULL; UpdSelBBox(); PrepareToReplaceAnObj(TopOwner); StretchObj(ObjPtr, CORNER_RB, (double)(multX*1000.0), (double)(multY*1000.0), FALSE); while (ObjPtr != TopOwner) { ObjPtr = ObjPtr->tmp_parent; AdjObjBBox(ObjPtr); } RecordReplaceAnObj(TopOwner); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), TopOwner->bbox.ltx-GRID_ABS_SIZE(1), TopOwner->bbox.lty-GRID_ABS_SIZE(1), TopOwner->bbox.rbx+GRID_ABS_SIZE(1), TopOwner->bbox.rby+GRID_ABS_SIZE(1)); RemoveAllSel(); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); SetFileModified(TRUE); justDupped = FALSE; horiAlign = saved_h_align; vertAlign = saved_v_align; } } static void DoSizeAllSelToGivenWidthHeight(abs_w, abs_h, do_width, do_height) int abs_h, do_width, do_height; { struct SelRec *saved_top_sel=topSel, *saved_bot_sel=botSel, *sel_ptr=NULL; int saved_h_align=horiAlign, saved_v_align=vertAlign, num_to_resize=0; char **ppsz_names_to_resize=NULL; if (topSel == NULL || (!do_width && !do_height)) { return; } horiAlign = ALIGN_L; vertAlign = ALIGN_T; ppsz_names_to_resize = NeedToProcessOnResize(&num_to_resize); HighLightReverse(); StartCompositeCmd(); for (sel_ptr=saved_top_sel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { struct ObjRec *obj_ptr=sel_ptr->obj; int w=(obj_ptr->obbox.rbx-obj_ptr->obbox.ltx); int h=(obj_ptr->obbox.rby-obj_ptr->obbox.lty); topSel = botSel = SelectThisObject(obj_ptr); UpdSelBBox(); if (do_width && do_height) { SetPivot(CORNER_RB, &obj_ptr->obbox); multX = (w == 0 ? ((double)1.0) : ((double)abs_w) / ((double)w)); multY = (h == 0 ? ((double)1.0) : ((double)abs_h) / ((double)h)); changeX = (fabs(multX-1.0) > 1.0e-6); changeY = (fabs(multY-1.0) > 1.0e-6); ScaleAllSel(CORNER_RB, (double)(multX*1000.0), (double)(multY*1000.0), TRUE); } else if (do_width) { SetPivot(CORNER_RIGHT, &obj_ptr->obbox); multX = (w == 0 ? ((double)1.0) : ((double)abs_w) / ((double)w)); changeX = (fabs(multX-1.0) > 1.0e-6); ScaleAllSel(CORNER_RIGHT, (double)(multX*1000.0), (double)1000, TRUE); } else { SetPivot(CORNER_BOTTOM, &obj_ptr->obbox); multY = (h == 0 ? ((double)1.0) : ((double)abs_h) / ((double)h)); changeY = (fabs(multY-1.0) > 1.0e-6); ScaleAllSel(CORNER_BOTTOM, (double)1000, (double)(multY*1000.0), TRUE); } free(topSel); } if (ppsz_names_to_resize != NULL) { DoOnResize(ppsz_names_to_resize, num_to_resize); } EndCompositeCmd(); horiAlign = saved_h_align; vertAlign = saved_v_align; topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } void SizeAllSelToGivenWidthHeight(AbsW, AbsH) int AbsW, AbsH; { DoSizeAllSelToGivenWidthHeight(AbsW, AbsH, TRUE, TRUE); } void SizeAllSelToGivenWidth(AbsW) int AbsW; { DoSizeAllSelToGivenWidthHeight(AbsW, INVALID, TRUE, FALSE); } void SizeAllSelToGivenHeight(AbsH) int AbsH; { DoSizeAllSelToGivenWidthHeight(INVALID, AbsH, FALSE, TRUE); } void FlipObjHorizontal(ObjPtr) struct ObjRec *ObjPtr; { int two_x_pivot=selNoLockObjLtX+selNoLockObjRbX; int new_obj_ltx=two_x_pivot-ObjPtr->obbox.rbx; int new_obj_rbx=two_x_pivot-ObjPtr->obbox.ltx; int new_obj_lty=ObjPtr->obbox.lty; if (ObjPtr->ctm == NULL && ObjPtr->type != OBJ_XBM && ObjPtr->type != OBJ_XPM) { register IntPoint *v; register int i; int num_pts; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; struct ArcRec *arc_ptr; switch (ObjPtr->type) { case OBJ_TEXT: if (ObjPtr->detail.t->minilines.just != JUST_C) { ObjPtr->detail.t->minilines.just = MAXJUSTS-1-ObjPtr->detail.t->minilines.just; if (ObjPtr->detail.t->cached_bitmap != None) { XFreePixmap(mainDisplay, ObjPtr->detail.t->cached_bitmap); } ObjPtr->detail.t->cached_bitmap = None; if (zoomScale != 0) { ObjPtr->detail.t->cached_zoom = 0; } } MoveObj(ObjPtr, two_x_pivot-((ObjPtr->x)<<1), 0); UpdTextBBox(ObjPtr); break; default: switch (ObjPtr->type) { case OBJ_XBM: ObjPtr->detail.xbm->flip ^= HORI_EVEN; if (ObjPtr->detail.xbm->cached_bitmap != None) { XFreePixmap(mainDisplay, ObjPtr->detail.xbm->cached_bitmap); } ObjPtr->detail.xbm->cached_bitmap = None; if (zoomScale != 0) { ObjPtr->detail.xbm->cached_zoom = 0; } break; case OBJ_XPM: ObjPtr->detail.xpm->flip ^= HORI_EVEN; if (ObjPtr->detail.xpm->cached_pixmap != None) { XFreePixmap(mainDisplay, ObjPtr->detail.xpm->cached_pixmap); } ObjPtr->detail.xpm->cached_pixmap = None; if (ObjPtr->detail.xpm->cached_bitmap != None) { XFreePixmap(mainDisplay, ObjPtr->detail.xpm->cached_bitmap); } ObjPtr->detail.xpm->cached_bitmap = None; ObjPtr->detail.xpm->cached_color = (-1); if (zoomScale != 0) { ObjPtr->detail.xpm->cached_zoom = 0; } break; case OBJ_ICON: case OBJ_PIN: ObjPtr->detail.r->flip ^= HORI_EVEN; break; } ObjPtr->obbox.ltx = ObjPtr->x = new_obj_ltx; ObjPtr->obbox.rbx = new_obj_rbx; break; } switch (ObjPtr->type) { case OBJ_POLY: num_pts = ObjPtr->detail.p->n; v = ObjPtr->detail.p->vlist; for (i = 0; i < num_pts; i++, v++) (*v).x = two_x_pivot - (*v).x; AdjObjSplineVs(ObjPtr); attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjHorizontal(attr_ptr->obj); } break; case OBJ_POLYGON: num_pts = ObjPtr->detail.g->n; v = ObjPtr->detail.g->vlist; for (i = 0; i < num_pts; i++, v++) (*v).x = two_x_pivot - (*v).x; AdjObjSplineVs(ObjPtr); attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjHorizontal(attr_ptr->obj); } break; case OBJ_BOX: case OBJ_OVAL: case OBJ_RCBOX: case OBJ_XBM: case OBJ_XPM: attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjHorizontal(attr_ptr->obj); } AdjObjSplineVs(ObjPtr); break; case OBJ_TEXT: AdjObjSplineVs(ObjPtr); break; case OBJ_ARC: arc_ptr = ObjPtr->detail.a; arc_ptr->xc = two_x_pivot - arc_ptr->xc; arc_ptr->x1 = two_x_pivot - arc_ptr->x1; arc_ptr->x2 = two_x_pivot - arc_ptr->x2; arc_ptr->dir = !(arc_ptr->dir); arc_ptr->ltx = two_x_pivot - arc_ptr->ltx - arc_ptr->w; if (arc_ptr->angle1 > 0) { arc_ptr->angle1 = (180*64) - arc_ptr->angle1; } else { arc_ptr->angle1 = (-180)*64 - arc_ptr->angle1; } arc_ptr->angle2 = -(arc_ptr->angle2); AdjObjBBox(ObjPtr); attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjHorizontal(attr_ptr->obj); } AdjObjSplineVs(ObjPtr); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: obj_ptr = ObjPtr->detail.r->first; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->next) { FlipObjHorizontal(obj_ptr); } attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjHorizontal(attr_ptr->obj); } AdjObjSplineVs(ObjPtr); break; } AdjObjBBox(ObjPtr); } else { double dz=(double)0, d1=(double)1000, dm1=(double)-1000; ShearObj(ObjPtr, CORNER_LEFT, dz, dz, dm1, d1, NULL, NULL); MoveObj(ObjPtr, new_obj_ltx-ObjPtr->obbox.ltx, new_obj_lty-ObjPtr->obbox.lty); } SetFileModified(TRUE); } void FlipIconHorizontal(ObjPtr) struct ObjRec *ObjPtr; { register int two_x_pivot; int new_obj_ltx, new_obj_rbx; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; two_x_pivot = selNoLockObjLtX + selNoLockObjRbX; new_obj_ltx = two_x_pivot - ObjPtr->obbox.rbx; new_obj_rbx = two_x_pivot - ObjPtr->obbox.ltx; ObjPtr->detail.r->flip ^= HORI_EVEN; ObjPtr->obbox.ltx = ObjPtr->x = new_obj_ltx; ObjPtr->obbox.rbx = new_obj_rbx; obj_ptr = ObjPtr->detail.r->first; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->next) { FlipObjHorizontal(obj_ptr); } attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjHorizontal(attr_ptr->obj); } AdjObjBBox(ObjPtr); } void FlipObjVertical(ObjPtr) struct ObjRec *ObjPtr; { int two_x_pivot=selNoLockObjLtY+selNoLockObjRbY; int new_obj_lty=two_x_pivot-ObjPtr->obbox.rby; int new_obj_rby=two_x_pivot-ObjPtr->obbox.lty; int new_obj_ltx=ObjPtr->obbox.ltx; if (ObjPtr->ctm == NULL && ObjPtr->type != OBJ_XBM && ObjPtr->type != OBJ_XPM) { register IntPoint *v; register int i; int num_pts; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; struct ArcRec *arc_ptr; switch (ObjPtr->type) { case OBJ_TEXT: MoveObj(ObjPtr, 0, new_obj_lty-ObjPtr->y); UpdTextBBox(ObjPtr); break; default: switch (ObjPtr->type) { case OBJ_XBM: ObjPtr->detail.xbm->flip ^= VERT_EVEN; if (ObjPtr->detail.xbm->cached_bitmap != None) { XFreePixmap(mainDisplay, ObjPtr->detail.xbm->cached_bitmap); } ObjPtr->detail.xbm->cached_bitmap = None; if (zoomScale != 0) { ObjPtr->detail.xbm->cached_zoom = 0; } break; case OBJ_XPM: ObjPtr->detail.xpm->flip ^= VERT_EVEN; if (ObjPtr->detail.xpm->cached_pixmap != None) { XFreePixmap(mainDisplay, ObjPtr->detail.xpm->cached_pixmap); } ObjPtr->detail.xpm->cached_pixmap = None; if (ObjPtr->detail.xpm->cached_bitmap != None) { XFreePixmap(mainDisplay, ObjPtr->detail.xpm->cached_bitmap); } ObjPtr->detail.xpm->cached_bitmap = None; ObjPtr->detail.xpm->cached_color = (-1); if (zoomScale != 0) { ObjPtr->detail.xpm->cached_zoom = 0; } break; case OBJ_ICON: case OBJ_PIN: ObjPtr->detail.r->flip ^= VERT_EVEN; break; } ObjPtr->obbox.lty = ObjPtr->y = new_obj_lty; ObjPtr->obbox.rby = new_obj_rby; break; } switch (ObjPtr->type) { case OBJ_POLY: num_pts = ObjPtr->detail.p->n; v = ObjPtr->detail.p->vlist; for (i = 0; i < num_pts; i++, v++) (*v).y = two_x_pivot - (*v).y; AdjObjSplineVs(ObjPtr); attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjVertical(attr_ptr->obj); } break; case OBJ_POLYGON: num_pts = ObjPtr->detail.g->n; v = ObjPtr->detail.g->vlist; for (i = 0; i < num_pts; i++, v++) (*v).y = two_x_pivot - (*v).y; AdjObjSplineVs(ObjPtr); attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjVertical(attr_ptr->obj); } break; case OBJ_BOX: case OBJ_OVAL: case OBJ_RCBOX: case OBJ_XBM: case OBJ_XPM: attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjVertical(attr_ptr->obj); } AdjObjSplineVs(ObjPtr); break; case OBJ_TEXT: AdjObjSplineVs(ObjPtr); break; case OBJ_ARC: arc_ptr = ObjPtr->detail.a; arc_ptr->yc = two_x_pivot - arc_ptr->yc; arc_ptr->y1 = two_x_pivot - arc_ptr->y1; arc_ptr->y2 = two_x_pivot - arc_ptr->y2; arc_ptr->dir = !(arc_ptr->dir); arc_ptr->lty = two_x_pivot - arc_ptr->lty - arc_ptr->h; arc_ptr->angle1 = -(arc_ptr->angle1); arc_ptr->angle2 = -(arc_ptr->angle2); AdjObjBBox(ObjPtr); attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjVertical(attr_ptr->obj); } AdjObjSplineVs(ObjPtr); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: obj_ptr = ObjPtr->detail.r->first; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->next) { FlipObjVertical(obj_ptr); } attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjVertical(attr_ptr->obj); } AdjObjSplineVs(ObjPtr); break; } AdjObjBBox(ObjPtr); } else { double dz=(double)0, d1=(double)1000, dm1=(double)-1000; ShearObj(ObjPtr, CORNER_TOP, dz, dz, d1, dm1, NULL, NULL); MoveObj(ObjPtr, new_obj_ltx-ObjPtr->obbox.ltx, new_obj_lty-ObjPtr->obbox.lty); } SetFileModified(TRUE); } void FlipIconVertical(ObjPtr) struct ObjRec *ObjPtr; { register int two_x_pivot; int new_obj_lty, new_obj_rby; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; two_x_pivot = selNoLockObjLtY + selNoLockObjRbY; new_obj_lty = two_x_pivot - ObjPtr->obbox.rby; new_obj_rby = two_x_pivot - ObjPtr->obbox.lty; ObjPtr->detail.r->flip ^= VERT_EVEN; ObjPtr->obbox.lty = ObjPtr->y = new_obj_lty; ObjPtr->obbox.rby = new_obj_rby; obj_ptr = ObjPtr->detail.r->first; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->next) { FlipObjVertical(obj_ptr); } attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { FlipObjVertical(attr_ptr->obj); } AdjObjBBox(ObjPtr); } /* --------------------- Rotation --------------------- */ static int rotatePivotX=0; static int rotatePivotY=0; static int OkToTransform(obj_ptr, stid) struct ObjRec *obj_ptr; int stid; { char obj_name[MAXSTRING]; struct AttrRec *name_attr=NULL; if (obj_ptr->locked) return FALSE; *obj_name = '\0'; if (HasOnResize(obj_ptr, &name_attr) && name_attr != NULL) { UtilStrCpyN(obj_name, sizeof(obj_name), name_attr->attr_value.s); sprintf(gszMsgBox, TgLoadString(stid), obj_name); if (MsgBox(gszMsgBox, TOOL_NAME, YN_MB) != MB_ID_YES) { return FALSE; } } return TRUE; } void SetRotatePivot() { if (!autoRotatePivot && rotatePivotAbsXYValid) { rotatePivotX = rotatePivotAbsX; rotatePivotY = rotatePivotAbsY; } else { rotatePivotX = ((selNoLockObjLtX + selNoLockObjRbX)>>1); rotatePivotY = ((selNoLockObjLtY + selNoLockObjRbY)>>1); } } void SetRotatePivotByObject(ObjPtr) struct ObjRec *ObjPtr; { rotatePivotX = ((ObjPtr->obbox.ltx + ObjPtr->obbox.rbx)>>1); rotatePivotY = ((ObjPtr->obbox.lty + ObjPtr->obbox.rby)>>1); } static void RotatePtClockWise(X, Y, NewX, NewY) int X, Y, *NewX, *NewY; { *NewX = rotatePivotX + rotatePivotY - Y; *NewY = rotatePivotY - rotatePivotX + X; } static void RotatedXY(X, Y, AngleDelta, NewX, NewY) int X, Y, AngleDelta, *NewX, *NewY; /* AngleDelta is degree*64 */ { register double radian, sin_val, cos_val; int dx=X-pivotX, dy=Y-pivotY; if (dx == 0 && dy == 0) { *NewX = pivotX; *NewY = pivotY; } else { radian = (((double)AngleDelta)*M_PI/180.0/64.0); sin_val = sin(radian); cos_val = cos(radian); *NewX = pivotX + round(dx*cos_val - dy*sin_val); *NewY = pivotY + round(dx*sin_val + dy*cos_val); } } static void RotatedAbsXY(X, Y, AngleDelta, NewX, NewY) int X, Y, AngleDelta, *NewX, *NewY; /* AngleDelta is degree*64 */ { register double radian, sin_val, cos_val; int dx=X-absPivotX, dy=Y-absPivotY; if (dx == 0 && dy == 0) { *NewX = absPivotX; *NewY = absPivotY; } else { radian = (((double)AngleDelta)*M_PI/180.0/64.0); sin_val = sin(radian); cos_val = cos(radian); *NewX = absPivotX + round(dx*cos_val - dy*sin_val); *NewY = absPivotY + round(dx*sin_val + dy*cos_val); } } void RotateObj(ObjPtr, Corner, AngleDelta, RealLtX, RealLtY) struct ObjRec *ObjPtr; int Corner, AngleDelta; /* AngleDelta is degree*64 */ int *RealLtX, *RealLtY; { IntPoint abs_obj_obbox_vs[5]; int x, y, new_ltx, new_lty, new_rbx, new_rby; double radian=(((double)AngleDelta)*M_PI/180.0/64.0); double sin_val=sin(radian), cos_val=cos(radian); struct XfrmMtrxRec ctm, new_ctm; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; switch (ObjPtr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: for (obj_ptr=ObjPtr->detail.r->first; obj_ptr != NULL; obj_ptr=obj_ptr->next) { RotateObj(obj_ptr, Corner, AngleDelta, RealLtX, RealLtY); } break; default: if (ObjPtr->ctm == NULL) { memcpy(&ObjPtr->orig_obbox, &ObjPtr->obbox, sizeof(struct BBRec)); if (ObjPtr->type == OBJ_TEXT) { memcpy(&ObjPtr->detail.t->orig_bbox, &ObjPtr->bbox, sizeof(struct BBRec)); } ObjPtr->ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ObjPtr->ctm == NULL) FailAllocMessage(); ObjPtr->ctm->m[CTM_SX] = ObjPtr->ctm->m[CTM_SY] = (double)1000; ObjPtr->ctm->m[CTM_SIN] = ObjPtr->ctm->m[CTM_MSIN] = (double)0; ObjPtr->ctm->t[CTM_TX] = ObjPtr->ctm->t[CTM_TY] = 0; } RotatedAbsXY(ObjPtr->x+ObjPtr->ctm->t[CTM_TX], ObjPtr->y+ObjPtr->ctm->t[CTM_TY], AngleDelta, &x, &y); ctm.m[CTM_SX] = ctm.m[CTM_SY] = ((double)1000.0)*cos_val; ctm.m[CTM_SIN] = ((double)1000.0)*sin_val; ctm.m[CTM_MSIN] = (-ctm.m[CTM_SIN]); ctm.t[CTM_TX] = 0; ctm.t[CTM_TY] = 0; ConcatCTM(ObjPtr->ctm, &ctm, &new_ctm); new_ctm.t[CTM_TX] = x-ObjPtr->x; new_ctm.t[CTM_TY] = y-ObjPtr->y; memcpy(ObjPtr->ctm, &new_ctm, sizeof(struct XfrmMtrxRec)); GetTransformedOBBoxAbsVs(ObjPtr, abs_obj_obbox_vs); new_ltx = min(min(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), min(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); new_rbx = max(max(abs_obj_obbox_vs[0].x,abs_obj_obbox_vs[1].x), max(abs_obj_obbox_vs[2].x,abs_obj_obbox_vs[3].x)); new_lty = min(min(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), min(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); new_rby = max(max(abs_obj_obbox_vs[0].y,abs_obj_obbox_vs[1].y), max(abs_obj_obbox_vs[2].y,abs_obj_obbox_vs[3].y)); ObjPtr->obbox.ltx = new_ltx; ObjPtr->obbox.lty = new_lty; ObjPtr->obbox.rbx = new_rbx; ObjPtr->obbox.rby = new_rby; if (RealLtX != NULL && RealLtY != NULL) { int dx=(*RealLtX)-new_ltx, dy=(*RealLtY)-new_lty; ObjPtr->x += dx; ObjPtr->y += dy; ObjPtr->bbox.ltx += dx; ObjPtr->bbox.lty += dy; ObjPtr->bbox.rbx += dx; ObjPtr->bbox.rby += dy; ObjPtr->obbox.ltx += dx; ObjPtr->obbox.lty += dy; ObjPtr->obbox.rbx += dx; ObjPtr->obbox.rby += dy; MoveRotatedObjCache(ObjPtr, dx, dy); } if (ObjPtr->ctm->m[CTM_SX] >= 999.0 && ObjPtr->ctm->m[CTM_SX] <= 1001.0 && ObjPtr->ctm->m[CTM_SY] >= 999.0 && ObjPtr->ctm->m[CTM_SY] <= 1001.0 && ObjPtr->ctm->m[CTM_SIN] >= (-1.0) && ObjPtr->ctm->m[CTM_SIN] <= 1.0 && ObjPtr->ctm->m[CTM_MSIN] >= (-1.0) && ObjPtr->ctm->m[CTM_MSIN] <= 1.0) { int dx=ObjPtr->ctm->t[CTM_TX], dy=ObjPtr->ctm->t[CTM_TY]; struct AttrRec *saved_fattr=NULL, *saved_lattr=NULL; free(ObjPtr->ctm); ObjPtr->ctm = NULL; memcpy(&ObjPtr->obbox, &ObjPtr->orig_obbox, sizeof(struct BBRec)); if (ObjPtr->type == OBJ_TEXT) { memcpy(&ObjPtr->bbox, &ObjPtr->detail.t->orig_bbox, sizeof(struct BBRec)); } saved_fattr = ObjPtr->fattr; saved_lattr = ObjPtr->lattr; ObjPtr->fattr = ObjPtr->lattr = NULL; MoveObj(ObjPtr, dx, dy); ObjPtr->fattr = saved_fattr; ObjPtr->lattr = saved_lattr; } break; } for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { RotateObj(attr_ptr->obj, Corner, AngleDelta, RealLtX, RealLtY); } AdjObjCache(ObjPtr); AdjObjBBox(ObjPtr); } void RotateObjForLayout(ObjPtr, AngleInRadian, Corner) struct ObjRec *ObjPtr; double AngleInRadian; int Corner; { double angle=AngleInRadian*64.0*180.0/M_PI; SetPivot(Corner, &ObjPtr->obbox); RotateObj(ObjPtr, Corner, round(angle), NULL, NULL); } void RotateObjClockWise(ObjPtr) struct ObjRec *ObjPtr; { double angle_in_radian=((double)(rotationIncrement))*M_PI/180.0/64.0; double sin_val=sin(angle_in_radian); double cos_val=cos(angle_in_radian); int orig_x=((ObjPtr->obbox.ltx+ObjPtr->obbox.rbx)>>1); int orig_y=ObjPtr->obbox.lty; int x=0, y=0, dx=orig_x-rotatePivotX, dy=orig_y-rotatePivotY; if (dx != 0 || dy != 0) { x = (int)round(dx*cos_val - dy*sin_val); y = (int)round(dx*sin_val + dy*cos_val); } x += rotatePivotX; y += rotatePivotY; /* RotateObjForLayout() rotates about center-top */ RotateObjForLayout(ObjPtr, angle_in_radian, CORNER_BOTTOM); MoveObj(ObjPtr, x-orig_x, y-orig_y); SetFileModified(TRUE); } void RotateIconClockWise(ObjPtr) struct ObjRec *ObjPtr; { int ltx, lty, rbx, rby; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; SetRotatePivot(); RotatePtClockWise(ObjPtr->obbox.ltx, ObjPtr->obbox.rby, <x, <y); RotatePtClockWise(ObjPtr->obbox.rbx, ObjPtr->obbox.lty, &rbx, &rby); ObjPtr->obbox.ltx = ObjPtr->x = ltx; ObjPtr->obbox.lty = ObjPtr->y = lty; ObjPtr->obbox.rbx = rbx; ObjPtr->obbox.rby = rby; obj_ptr = ObjPtr->detail.r->first; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->next) { RotateObjClockWise(obj_ptr); } attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { RotateObjClockWise(attr_ptr->obj); } AdjObjBBox(ObjPtr); } static void RotatePtCounter(X, Y, NewX, NewY) int X, Y, *NewX, *NewY; { *NewX = rotatePivotX - rotatePivotY + Y; *NewY = rotatePivotY + rotatePivotX - X; } void RotateObjCounter(ObjPtr) struct ObjRec *ObjPtr; { double angle_in_radian=((double)(-rotationIncrement))*M_PI/180.0/64.0; double sin_val=sin(angle_in_radian); double cos_val=cos(angle_in_radian); int orig_x=((ObjPtr->obbox.ltx+ObjPtr->obbox.rbx)>>1); int orig_y=ObjPtr->obbox.lty; int x=0, y=0, dx=orig_x-rotatePivotX, dy=orig_y-rotatePivotY; if (dx != 0 || dy != 0) { x = (int)round(dx*cos_val - dy*sin_val); y = (int)round(dx*sin_val + dy*cos_val); } x += rotatePivotX; y += rotatePivotY; /* RotateObjForLayout() rotates about center-top */ RotateObjForLayout(ObjPtr, angle_in_radian, CORNER_BOTTOM); MoveObj(ObjPtr, x-orig_x, y-orig_y); SetFileModified(TRUE); } void RotateIconCounter(ObjPtr) struct ObjRec *ObjPtr; { int ltx, lty, rbx, rby; struct ObjRec *obj_ptr; struct AttrRec *attr_ptr; SetRotatePivot(); /* ObjPtr->detail.r->rotate = (ObjPtr->detail.r->rotate+4-1) % 4; */ RotatePtCounter(ObjPtr->obbox.rbx, ObjPtr->obbox.lty, <x, <y); RotatePtCounter(ObjPtr->obbox.ltx, ObjPtr->obbox.rby, &rbx, &rby); ObjPtr->obbox.ltx = ObjPtr->x = ltx; ObjPtr->obbox.lty = ObjPtr->y = lty; ObjPtr->obbox.rbx = rbx; ObjPtr->obbox.rby = rby; obj_ptr = ObjPtr->detail.r->first; for ( ; obj_ptr != NULL; obj_ptr = obj_ptr->next) { RotateObjCounter(obj_ptr); } attr_ptr = ObjPtr->fattr; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { RotateObjCounter(attr_ptr->obj); } AdjObjBBox(ObjPtr); } static void FlipAllSelHorizontal(saved_ltx, saved_lty, saved_rbx, saved_rby) int saved_ltx, saved_lty, saved_rbx, saved_rby; { struct SelRec *sel_ptr; PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); JustRemoveAllVSel(); for (sel_ptr = topSel; sel_ptr != NULL; sel_ptr = sel_ptr->next) { if (!sel_ptr->obj->locked) { FlipObjHorizontal(sel_ptr->obj); } } UpdSelBBox(); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } void FlipHorizontal() { int saved_ltx, saved_lty, saved_rbx, saved_rby, num_to_resize=0; struct BBRec sel_obbox; char **ppsz_names_to_resize=NULL; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (numObjSelected == numObjLocked) { Msg(TgLoadString(STID_LOCKED_OBJS_CANT_BE_FLIPPED)); return; } sel_obbox.ltx = selNoLockObjLtX; sel_obbox.lty = selNoLockObjLtY; sel_obbox.rbx = selNoLockObjRbX; sel_obbox.rby = selNoLockObjRbY; SetPivot(CORNER_LEFT, &sel_obbox); saved_ltx = selLtX; saved_lty = selLtY; saved_rbx = selRbX; saved_rby = selRbY; HighLightReverse(); ppsz_names_to_resize = NeedToProcessOnResize(&num_to_resize); if (ppsz_names_to_resize == NULL) { FlipAllSelHorizontal(saved_ltx, saved_lty, saved_rbx, saved_rby); } else { StartCompositeCmd(); FlipAllSelHorizontal(saved_ltx, saved_lty, saved_rbx, saved_rby); DoOnResize(ppsz_names_to_resize, num_to_resize); EndCompositeCmd(); } HighLightForward(); justDupped = FALSE; if (numObjLocked != 0) { Msg(TgLoadString(STID_LOCKED_OBJS_ARE_NOT_FLIPPED)); } else { Msg(TgLoadString(STID_FLIPPED_HORIZONTALLY)); } } static void FlipAllSelVertical(saved_ltx, saved_lty, saved_rbx, saved_rby) int saved_ltx, saved_lty, saved_rbx, saved_rby; { struct SelRec *sel_ptr; PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); JustRemoveAllVSel(); for (sel_ptr = topSel; sel_ptr != NULL; sel_ptr = sel_ptr->next) { if (!sel_ptr->obj->locked) { FlipObjVertical(sel_ptr->obj); } } UpdSelBBox(); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } void FlipVertical() { int saved_ltx, saved_lty, saved_rbx, saved_rby, num_to_resize=0; struct BBRec sel_obbox; char **ppsz_names_to_resize=NULL; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (numObjSelected == numObjLocked) { Msg(TgLoadString(STID_LOCKED_OBJS_CANT_BE_FLIPPED)); return; } sel_obbox.ltx = selNoLockObjLtX; sel_obbox.lty = selNoLockObjLtY; sel_obbox.rbx = selNoLockObjRbX; sel_obbox.rby = selNoLockObjRbY; SetPivot(CORNER_TOP, &sel_obbox); saved_ltx = selLtX; saved_lty = selLtY; saved_rbx = selRbX; saved_rby = selRbY; HighLightReverse(); ppsz_names_to_resize = NeedToProcessOnResize(&num_to_resize); if (ppsz_names_to_resize == NULL) { FlipAllSelVertical(saved_ltx, saved_lty, saved_rbx, saved_rby); } else { StartCompositeCmd(); FlipAllSelVertical(saved_ltx, saved_lty, saved_rbx, saved_rby); DoOnResize(ppsz_names_to_resize, num_to_resize); EndCompositeCmd(); } HighLightForward(); justDupped = FALSE; if (numObjLocked != 0) { Msg(TgLoadString(STID_LOCKED_OBJS_ARE_NOT_FLIPPED)); } else { Msg(TgLoadString(STID_FLIPPED_VERTICALLY)); } } /* --------------------- Rotate --------------------- */ void RotateClockWise() { register struct SelRec *sel_ptr; int saved_ltx, saved_lty, saved_rbx, saved_rby; int text_obj_created, text_cursor_shown; if (topSel == NULL) { text_cursor_shown = textCursorShown; text_obj_created = TieLooseEnds(); textRotation += rotationIncrement; while (textRotation < 0) textRotation += (360<<6); while (textRotation >= (360<<6)) textRotation -= (360<<6); ShowRotate(); if (!text_obj_created && curChoice == DRAWTEXT && text_cursor_shown) { NewCurText(); RedrawCurText(); } else { textCursorShown = FALSE; } return; } if (numObjSelected == numObjLocked) { MsgBox(TgLoadString(STID_LOCKED_OBJS_CANT_BE_ROTATED), TOOL_NAME, INFO_MB); return; } saved_ltx = selLtX; saved_lty = selLtY; saved_rbx = selRbX; saved_rby = selRbY; HighLightReverse(); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); JustRemoveAllVSel(); SetRotatePivot(); for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (OkToTransform(sel_ptr->obj, STID_DISABLE_ON_RESIZE_ROTATE)) { RotateObjClockWise(sel_ptr->obj); } } UpdSelBBox(); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); justDupped = FALSE; if (numObjLocked != 0) { Msg(TgLoadString(STID_LOCKED_OBJS_ARE_NOT_ROTATED)); } else { Msg(TgLoadString(STID_ROTATED_CLOCKWISE)); } } void RotateCounter() { register struct SelRec *sel_ptr; int saved_ltx, saved_lty, saved_rbx, saved_rby; int text_obj_created, text_cursor_shown; if (topSel == NULL) { text_cursor_shown = textCursorShown; text_obj_created = TieLooseEnds(); textRotation -= rotationIncrement; while (textRotation < 0) textRotation += (360<<6); while (textRotation >= (360<<6)) textRotation -= (360<<6); ShowRotate(); if (!text_obj_created && curChoice == DRAWTEXT && text_cursor_shown) { NewCurText(); RedrawCurText(); } else { textCursorShown = FALSE; } return; } if (numObjSelected == numObjLocked) { MsgBox(TgLoadString(STID_LOCKED_OBJS_CANT_BE_ROTATED), TOOL_NAME, INFO_MB); return; } saved_ltx = selLtX; saved_lty = selLtY; saved_rbx = selRbX; saved_rby = selRbY; HighLightReverse(); PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); JustRemoveAllVSel(); SetRotatePivot(); for (sel_ptr = topSel; sel_ptr != NULL; sel_ptr = sel_ptr->next) { if (OkToTransform(sel_ptr->obj, STID_DISABLE_ON_RESIZE_ROTATE)) { RotateObjCounter(sel_ptr->obj); } } UpdSelBBox(); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); justDupped = FALSE; if (numObjLocked != 0) { Msg(TgLoadString(STID_LOCKED_OBJS_ARE_NOT_ROTATED)); } else { Msg(TgLoadString(STID_ROTATED_COUNTER_CLOCKWISE)); } } void SetTextRotation(pszBuf) char *pszBuf; { char spec[80], buf[80]; float fval; int ival; *spec = '\0'; if (pszBuf != NULL) { strcpy(spec, pszBuf); } else { FormatAngle(textRotation, buf); sprintf(gszMsgBox, TgLoadString(STID_ENTER_TEXT_ROT_IN_DEGREE_CUR), buf); if (Dialog(gszMsgBox, NULL, spec) == INVALID) return; } UtilTrimBlanks(spec); if (*spec == '\0') return; if (sscanf(spec, "%f", &fval) != 1) { sprintf(gszMsgBox, TgLoadString(STID_CANT_PARSE_ENTER_ONE_NUM_VAL), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } fval *= (float)64.0; ival = round(fval); if (ival < 0 || ival >= (360<<6)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_VAL_ENTERED_RNG_INC), spec, 0, 360); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } textRotation = ival; ShowRotate(); FormatAngle(textRotation, buf); sprintf(gszMsgBox, TgLoadString(STID_TEXT_ROTATION_SET_TO_GIVEN), buf); Msg(gszMsgBox); } void SetRotationIncrement(pszBuf) char *pszBuf; { char spec[80], buf[80]; float fval; int ival; *spec = '\0'; if (pszBuf != NULL) { strcpy(spec, pszBuf); } else { FormatAngle(rotationIncrement, buf); sprintf(gszMsgBox, TgLoadString(STID_ENTER_ROT_INC_IN_DEGREE_CUR), buf); if (Dialog(gszMsgBox, NULL, spec) == INVALID) return; } UtilTrimBlanks(spec); if (*spec == '\0') return; if (sscanf(spec, "%f", &fval) != 1) { sprintf(gszMsgBox, TgLoadString(STID_CANT_PARSE_ENTER_ONE_NUM_VAL), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } fval *= (float)64.0; ival = round(fval); if (ival <= 0 || ival >= (360<<6)) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_VAL_ENTERED_RNG_EXC), spec, 0, 360); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } rotationIncrement = ival; FormatAngle(rotationIncrement, buf); sprintf(gszMsgBox, TgLoadString(STID_TEXT_ROT_INC_SET_TO_GIVEN), buf); Msg(gszMsgBox); } static int IdentCTM(ctm1, ctm2) struct XfrmMtrxRec *ctm1, *ctm2; { return ((fabs(ctm1->m[CTM_SX]-ctm2->m[CTM_SX]) < EQ_TOL) && (fabs(ctm1->m[CTM_SY]-ctm2->m[CTM_SY]) < EQ_TOL) && (fabs(ctm1->m[CTM_SIN]-ctm2->m[CTM_SIN]) < EQ_TOL) && (fabs(ctm1->m[CTM_MSIN]-ctm2->m[CTM_MSIN]) < EQ_TOL)); } static int SetObjCTM(ObjPtr, nTransformed, ctm) struct ObjRec *ObjPtr; int nTransformed; struct XfrmMtrxRec *ctm; { int nReturn=FALSE, cx=0, cy=0; switch (ObjPtr->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: break; default: cx = ((ObjPtr->obbox.ltx+ObjPtr->obbox.rbx)>>1); cy = ((ObjPtr->obbox.lty+ObjPtr->obbox.rby)>>1); if (nTransformed) { struct XfrmMtrxRec *saved_ctm=NULL; if (ObjPtr->ctm == NULL) { SetCTM(ObjPtr, ctm); nReturn = TRUE; } else { if (!IdentCTM(ObjPtr->ctm, ctm)) { if (ObjPtr->type == OBJ_TEXT) { saved_ctm = ObjPtr->ctm; ObjPtr->ctm = NULL; if (!UpdTextBBox(ObjPtr)) { /* read-only text */ ObjPtr->ctm = saved_ctm; } else { free(saved_ctm); SetCTM(ObjPtr, ctm); UpdTextBBox(ObjPtr); nReturn = TRUE; } } else { free(ObjPtr->ctm); ObjPtr->ctm = NULL; SetCTM(ObjPtr, ctm); nReturn = TRUE; } } } } else { if (ObjPtr->ctm != NULL) { free(ObjPtr->ctm); ObjPtr->ctm = NULL; nReturn = TRUE; } } if (nReturn) { int new_cx=0, new_cy=0; new_cx = ((ObjPtr->obbox.ltx+ObjPtr->obbox.rbx)>>1); new_cy = ((ObjPtr->obbox.lty+ObjPtr->obbox.rby)>>1); MoveObj(ObjPtr, cx-new_cx, cy-new_cy); AdjObjCache(ObjPtr); AdjObjSplineVs(ObjPtr); AdjObjBBox(ObjPtr); } break; } return nReturn; } void SetSelCTM(nTransformed, ctm) int nTransformed; struct XfrmMtrxRec *ctm; { struct SelRec *sel_ptr=NULL; int ltx=selLtX, lty=selLtY, rbx=selRbX, rby=selRbY, changed=FALSE; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (numObjSelected == numObjLocked) { MsgBox(TgLoadString(STID_LOCKED_OBJS_CANT_BE_XFORMED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { if (OkToTransform(sel_ptr->obj, STID_DISABLE_ON_RESIZE_TRANSFORM)) { PrepareToReplaceAnObj(sel_ptr->obj); if (SetObjCTM(sel_ptr->obj, nTransformed, ctm)) { changed = TRUE; RecordReplaceAnObj(sel_ptr->obj); } else { AbortPrepareCmd(CMD_REPLACE); } } } EndCompositeCmd(); if (changed) { SetFileModified(TRUE); UpdSelBBox(); RedrawAreas(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); justDupped = FALSE; if (numObjLocked != 0) { Msg(TgLoadString(STID_LOCKED_OBJS_ARE_NOT_XFORMED)); } } HighLightForward(); } /* --------------------- Rotate Any Angle --------------------- */ static void RotateBBoxByAnAngle(bbox, d_angle, vs) struct BBRec *bbox; /* the original bounding box */ int d_angle; /* d_angle is degree*64 */ XPoint *vs; /* array of 5 points */ { int x, y; RotatedXY(bbox->ltx, bbox->lty, d_angle, &x, &y); vs[0].x = vs[4].x = x; vs[0].y = vs[4].y = y; RotatedXY(bbox->rbx, bbox->lty, d_angle, &x, &y); vs[1].x = x; vs[1].y = y; RotatedXY(bbox->rbx, bbox->rby, d_angle, &x, &y); vs[2].x = x; vs[2].y = y; RotatedXY(bbox->ltx, bbox->rby, d_angle, &x, &y); vs[3].x = x; vs[3].y = y; } static void RotateVsByAnAngle(InVs, NumPts, d_angle, OutVs) XPoint *InVs, *OutVs; int NumPts, d_angle; { register int i; for (i=0; i < NumPts; i++) { int x, y; RotatedXY(InVs[i].x, InVs[i].y, d_angle, &x, &y); OutVs[i].x = x; OutVs[i].y = y; } } static void RotateAllSelObjects(Corner, AngleDelta) int Corner, AngleDelta; /* AngleDelta is degree*64 */ { register struct SelRec *sel_ptr; for (sel_ptr = topSel; sel_ptr != NULL; sel_ptr = sel_ptr->next) { if (OkToTransform(sel_ptr->obj, STID_DISABLE_ON_RESIZE_ROTATE)) { RotateObj(sel_ptr->obj, Corner, AngleDelta, NULL, NULL); } } if (numObjLocked != 0) { Msg(TgLoadString(STID_LOCKED_OBJS_ARE_NOT_ROTATED)); } } static int ConstrainedRotateAllSel(Corner, AngleDelta, ltx, lty, rbx, rby) int Corner, AngleDelta, *ltx, *lty, *rbx, *rby; { register struct ObjRec *obj_ptr; int something_stretched=FALSE, num_pts; int x_off, y_off, move_first, move_last, x, y; IntPoint *v; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (!obj_ptr->marked && obj_ptr->type==OBJ_POLY && !obj_ptr->locked) { num_pts = obj_ptr->detail.p->n; v = obj_ptr->detail.p->vlist; if (obj_ptr->ctm == NULL) { x_off = OFFSET_X(v[0].x); y_off = OFFSET_Y(v[0].y); move_first = EndPtInSelected(x_off, y_off); x_off = OFFSET_X(v[num_pts-1].x); y_off = OFFSET_Y(v[num_pts-1].y); move_last = EndPtInSelected(x_off, y_off); } else { int tmp_x, tmp_y; TransformPointThroughCTM(v[0].x-obj_ptr->x, v[0].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); tmp_x += obj_ptr->x; tmp_y += obj_ptr->y; x_off = OFFSET_X(tmp_x); y_off = OFFSET_Y(tmp_y); move_first = EndPtInSelected(x_off, y_off); TransformPointThroughCTM(v[num_pts-1].x-obj_ptr->x, v[num_pts-1].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); tmp_x += obj_ptr->x; tmp_y += obj_ptr->y; x_off = OFFSET_X(tmp_x); y_off = OFFSET_Y(tmp_y); move_last = EndPtInSelected(x_off, y_off); } if (move_first || move_last) { int index=INVALID, seg_dx, seg_dy, dx, dy, cur_seg_dx, cur_seg_dy; PrepareToReplaceAnObj(obj_ptr); if (obj_ptr->ctm != NULL) { /* Remove the transformations! */ int i; for (i=0; i < num_pts; i++) { int tmp_x, tmp_y; TransformPointThroughCTM(v[i].x-obj_ptr->x, v[i].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); v[i].x = tmp_x+obj_ptr->x; v[i].y = tmp_y+obj_ptr->y; } free(obj_ptr->ctm); obj_ptr->ctm = NULL; UpdPolyBBox(obj_ptr, num_pts, v); } if (something_stretched) { if (obj_ptr->bbox.ltx < *ltx) *ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < *lty) *lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > *rbx) *rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > *rby) *rby = obj_ptr->bbox.rby; } else { *ltx = obj_ptr->bbox.ltx; *lty = obj_ptr->bbox.lty; *rbx = obj_ptr->bbox.rbx; *rby = obj_ptr->bbox.rby; } something_stretched = TRUE; if (move_first && move_last && num_pts==3) { RotatedAbsXY(v[0].x, v[0].y, AngleDelta, &x, &y); dx = x-v[0].x; dy = y-v[0].y; index = 1; cur_seg_dx = v[index-1].x - v[index].x; cur_seg_dy = v[index-1].y - v[index].y; seg_dx = v[index].x - v[index+1].x; seg_dy = v[index].y - v[index+1].y; if (cur_seg_dy==0 && seg_dx==0 && (seg_dy!=0 || (seg_dy==0 && dx==0))) { v[index].y += dy; } else if (cur_seg_dx==0 && seg_dy==0 && (seg_dx!=0 || (seg_dx==0 && dy==0))) { v[index].x += dx; } } else { if (move_first && num_pts>2) { RotatedAbsXY(v[0].x, v[0].y, AngleDelta, &x, &y); dx = x-v[0].x; dy = y-v[0].y; index = 1; cur_seg_dx = v[index-1].x - v[index].x; cur_seg_dy = v[index-1].y - v[index].y; seg_dx = v[index].x - v[index+1].x; seg_dy = v[index].y - v[index+1].y; if (cur_seg_dy==0 && cur_seg_dx!=0 && (seg_dy!=0 || (seg_dy==0 && dx==0))) { v[index].y += dy; } else if (cur_seg_dx==0 && cur_seg_dy!=0 && (seg_dx!=0 || (seg_dx==0 && dy==0))) { v[index].x += dx; } } if (move_last && num_pts>2) { RotatedAbsXY(v[num_pts-1].x, v[num_pts-1].y, AngleDelta, &x, &y); dx = x-v[num_pts-1].x; dy = y-v[num_pts-1].y; index = num_pts-2; cur_seg_dx = v[index+1].x - v[index].x; cur_seg_dy = v[index+1].y - v[index].y; seg_dx = v[index].x - v[index-1].x; seg_dy = v[index].y - v[index-1].y; if (cur_seg_dy==0 && cur_seg_dx!=0 && (seg_dy!=0 || (seg_dy==0 && dx==0))) { v[index].y += dy; } else if (cur_seg_dx==0 && cur_seg_dy!=0 && (seg_dx!=0 || (seg_dx==0 && dy==0))) { v[index].x += dx; } } } if (move_first) { RotatedAbsXY(v[0].x, v[0].y, AngleDelta, &x, &y); v[0].x = x; v[0].y = y; } if (move_last) { RotatedAbsXY(v[num_pts-1].x, v[num_pts-1].y, AngleDelta, &x, &y); v[num_pts-1].x = x; v[num_pts-1].y = y; } AdjObjSplineVs(obj_ptr); switch (obj_ptr->type) { case OBJ_POLY: if (obj_ptr->detail.p->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, num_pts, v); } else { UpdPolyBBox(obj_ptr, obj_ptr->detail.p->intn, obj_ptr->detail.p->intvlist); } break; case OBJ_POLYGON: if (obj_ptr->detail.g->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, num_pts, v); } else { UpdPolyBBox(obj_ptr, obj_ptr->detail.g->intn, obj_ptr->detail.g->intvlist); } break; } AdjObjBBox(obj_ptr); if (AutoCenterAttr(obj_ptr)) { struct AttrRec *attr_ptr=obj_ptr->fattr; int modified=FALSE; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { if (attr_ptr->shown) { struct BBRec bbox; CenterObjInOBBox(attr_ptr->obj, obj_ptr->obbox, &bbox); if (bbox.ltx < *ltx) *ltx = bbox.ltx; if (bbox.lty < *lty) *lty = bbox.lty; if (bbox.rbx > *rbx) *rbx = bbox.rbx; if (bbox.rby > *rby) *rby = bbox.rby; modified = TRUE; } } if (modified) AdjObjBBox(obj_ptr); } if (obj_ptr->bbox.ltx < *ltx) *ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < *lty) *lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > *rbx) *rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > *rby) *rby = obj_ptr->bbox.rby; RecordReplaceAnObj(obj_ptr); } } } return something_stretched; } static void RotateAllSel(Corner, AngleDelta) int Corner, AngleDelta; /* AngleDelta is degree*64 */ { int ltx=0, lty=0, rbx=0, rby=0, saved_ltx, saved_lty, saved_rbx, saved_rby; int poly_stretched; saved_ltx = selLtX; saved_lty = selLtY; saved_rbx = selRbX; saved_rby = selRbY; if (moveMode==CONST_MOVE) { MarkObjectsForStretch(); StartCompositeCmd(); PrepareToRecord(CMD_STRETCH, topSel, botSel, numObjSelected); RecordCmd(CMD_STRETCH, NULL, topSel, botSel, numObjSelected); poly_stretched = ConstrainedRotateAllSel(Corner, AngleDelta, <x, <y, &rbx, &rby); RotateAllSelObjects(Corner, AngleDelta); UpdSelBBox(); if (poly_stretched) { ltx = min(ltx,min(selLtX,saved_ltx)); lty = min(lty,min(selLtY,saved_lty)); rbx = max(rbx,max(selRbX,saved_rbx)); rby = max(rby,max(selRbY,saved_rby)); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); } else { RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } EndCompositeCmd(); } else { PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); RotateAllSelObjects(Corner, AngleDelta); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); UpdSelBBox(); RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } } static void FormatAngleForRotate(buf, angle) char *buf; int angle; { float fval=(float)(((float)angle)/((float)64.0)); sprintf(buf, "degree=%.2f", fval); } static void RotateSel(XGridOff, YGridOff, ObjPtr, Corner) int XGridOff, YGridOff, Corner; struct ObjRec *ObjPtr; { register int i; XEvent ev; XPoint all_bbox_vs[5], obj_obbox_vs[5], *vs=NULL, *orig_vs=NULL; int grid_x=XGridOff, grid_y=YGridOff, dx, dy, d_angle=0; int saved_x=XGridOff, saved_y=YGridOff; int rotating=TRUE, deg360=(360<<6), n=0; char buf[80]; struct BBRec orig_all_bbox, orig_obj_obbox; if (numObjSelected == numObjLocked || ObjPtr->locked) { MsgBox(TgLoadString(STID_LOCKED_OBJS_CANT_BE_ROTATED), TOOL_NAME, INFO_MB); return; } XFlush(mainDisplay); XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } if (ObjPtr->type==OBJ_POLY || ObjPtr->type==OBJ_POLYGON) { IntPoint *pv; int px, py; if (ObjPtr->ctm == NULL) { pv = (ObjPtr->type==OBJ_POLY ? &ObjPtr->detail.p->vlist[Corner] : &ObjPtr->detail.g->vlist[Corner]); px = pv->x; py = pv->y; } else { pv = (ObjPtr->type==OBJ_POLY ? &ObjPtr->detail.p->vlist[Corner] : &ObjPtr->detail.g->vlist[Corner]); TransformPointThroughCTM(pv->x-ObjPtr->x, pv->y-ObjPtr->y, ObjPtr->ctm, &px, &py); px += ObjPtr->x; py += ObjPtr->y; } absPivotX = (ObjPtr->obbox.ltx+ObjPtr->obbox.rbx)>>1; absPivotY = (ObjPtr->obbox.lty+ObjPtr->obbox.rby)>>1; moveX = OFFSET_X(px); moveY = OFFSET_Y(py); changeX = changeY = TRUE; multX = multY = 1.0; pivotX = OFFSET_X(absPivotX); pivotY = OFFSET_Y(absPivotY); } else { SetPivot(Corner, &ObjPtr->obbox); } if (!autoRotatePivot && rotatePivotAbsXYValid) { absPivotX = rotatePivotAbsX; absPivotY = rotatePivotAbsY; pivotX = OFFSET_X(absPivotX); pivotY = OFFSET_Y(absPivotY); } SetBBRec(&orig_all_bbox, OFFSET_X(selNoLockLtX)-2, OFFSET_Y(selNoLockLtY)-2, OFFSET_X(selNoLockRbX)+2, OFFSET_Y(selNoLockRbY)+2); SetRotateVs(all_bbox_vs, orig_all_bbox.ltx, orig_all_bbox.lty, orig_all_bbox.rbx, orig_all_bbox.rby); XDrawLines(mainDisplay, drawWindow, revDefaultGC, all_bbox_vs, 5, CoordModeOrigin); if (ObjPtr->type==OBJ_POLY || ObjPtr->type==OBJ_POLYGON) { if (ObjPtr->type == OBJ_POLY) { if (ObjPtr->ctm == NULL) { n = ObjPtr->detail.p->sn; orig_vs = (XPoint*)malloc(n*sizeof(XPoint)); vs = (XPoint*)malloc(n*sizeof(XPoint)); if (orig_vs == NULL || vs == NULL) FailAllocMessage(); for (i=0; i < n; i++) { vs[i].x = orig_vs[i].x = ObjPtr->detail.p->svlist[i].x; vs[i].y = orig_vs[i].y = ObjPtr->detail.p->svlist[i].y; } } else { n = ObjPtr->detail.p->rotated_n; orig_vs = (XPoint*)malloc(n*sizeof(XPoint)); vs = (XPoint*)malloc(n*sizeof(XPoint)); if (orig_vs == NULL || vs == NULL) FailAllocMessage(); for (i=0; i < n; i++) { vs[i].x = orig_vs[i].x = ObjPtr->detail.p->rotated_vlist[i].x; vs[i].y = orig_vs[i].y = ObjPtr->detail.p->rotated_vlist[i].y; } } } else { if (ObjPtr->ctm == NULL) { n = ObjPtr->detail.g->sn; orig_vs = (XPoint*)malloc(n*sizeof(XPoint)); vs = (XPoint*)malloc(n*sizeof(XPoint)); if (orig_vs == NULL || vs == NULL) FailAllocMessage(); for (i=0; i < n; i++) { vs[i].x = orig_vs[i].x = ObjPtr->detail.g->svlist[i].x; vs[i].y = orig_vs[i].y = ObjPtr->detail.g->svlist[i].y; } } else { n = ObjPtr->detail.g->rotated_n; orig_vs = (XPoint*)malloc(n*sizeof(XPoint)); vs = (XPoint*)malloc(n*sizeof(XPoint)); if (orig_vs == NULL || vs == NULL) FailAllocMessage(); for (i=0; i < n; i++) { vs[i].x = orig_vs[i].x = ObjPtr->detail.g->rotated_vlist[i].x; vs[i].y = orig_vs[i].y = ObjPtr->detail.g->rotated_vlist[i].y; } } } XDrawLines(mainDisplay, drawWindow, revDefaultGC, vs, n, CoordModeOrigin); } else { if (ObjPtr->ctm == NULL) { SetBBRec(&orig_obj_obbox, OFFSET_X(ObjPtr->obbox.ltx), OFFSET_Y(ObjPtr->obbox.lty), OFFSET_X(ObjPtr->obbox.rbx), OFFSET_Y(ObjPtr->obbox.rby)); SetRotateVs(obj_obbox_vs, orig_obj_obbox.ltx, orig_obj_obbox.lty, orig_obj_obbox.rbx, orig_obj_obbox.rby); XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_obbox_vs, 5, CoordModeOrigin); } else { memcpy(obj_obbox_vs, ObjPtr->rotated_obbox, 5*sizeof(XPoint)); XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_obbox_vs, 5, CoordModeOrigin); } } dx = OFFSET_X(ObjPtr->obbox.rbx) - OFFSET_X(ObjPtr->obbox.ltx); dy = OFFSET_Y(ObjPtr->obbox.rby) - OFFSET_Y(ObjPtr->obbox.lty); if (dx == 0 && dy == 0) { MsgBox(TgLoadString(STID_SEL_OBJ_TOO_SMALL_ROT_ANOTHER), TOOL_NAME, INFO_MB); return; } grid_x = moveX; grid_y = moveY; FormatAngleForRotate(buf, 0); StartShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, rotatingCursor, CurrentTime); } while (rotating) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); rotating = FALSE; FormatAngleForRotate(buf, d_angle); EndShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (ObjPtr->type==OBJ_POLY || ObjPtr->type==OBJ_POLYGON) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, vs, n, CoordModeOrigin); } else { XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_obbox_vs, 5, CoordModeOrigin); } XDrawLines(mainDisplay, drawWindow, revDefaultGC, all_bbox_vs, 5, CoordModeOrigin); } else if (input.type == MotionNotify || input.type == KeyPress || input.type == KeyRelease) { int end_x=0, end_y=0; FormatAngleForRotate(buf, d_angle); ShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (ObjPtr->type==OBJ_POLY || ObjPtr->type==OBJ_POLYGON) { XDrawLines(mainDisplay, drawWindow, revDefaultGC, vs, n, CoordModeOrigin); } else { XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_obbox_vs, 5, CoordModeOrigin); } XDrawLines(mainDisplay, drawWindow, revDefaultGC, all_bbox_vs, 5, CoordModeOrigin); if (input.type == KeyPress || input.type == KeyRelease) { end_x = grid_x; end_y = grid_y; } else { end_x = input.xmotion.x; end_y = input.xmotion.y; } GridXY(end_x, end_y, &grid_x, &grid_y); dx = grid_x - saved_x; dy = grid_y - saved_y; grid_x = moveX + dx; grid_y = moveY + dy; MarkRulers(grid_x, grid_y); PointsToArc(pivotX, pivotY, moveX, moveY, grid_x, grid_y, ARC_CW, FALSE, NULL, NULL, NULL, NULL, NULL, &d_angle); if (shiftForDiagMouseMove && DiagEventCheck(&input)) { int tmp_angle=(int)(((double)d_angle) / ((double)(45<<5))); if (tmp_angle & 0x1) { if (tmp_angle > 0) { tmp_angle = ((tmp_angle+1)>>1); } else { tmp_angle = ((tmp_angle-1)>>1); } } else { tmp_angle >>= 1; } d_angle = tmp_angle * (45<<6); } if (d_angle == deg360) d_angle = 0; d_angle = (-d_angle); while (d_angle >= (deg360)) d_angle -= (deg360); RotateBBoxByAnAngle(&orig_all_bbox, d_angle, all_bbox_vs); XDrawLines(mainDisplay, drawWindow, revDefaultGC, all_bbox_vs, 5, CoordModeOrigin); if (ObjPtr->type==OBJ_POLY || ObjPtr->type==OBJ_POLYGON) { RotateVsByAnAngle(orig_vs, n, d_angle, vs); XDrawLines(mainDisplay, drawWindow, revDefaultGC, vs, n, CoordModeOrigin); } else { if (ObjPtr->ctm == NULL) { RotateBBoxByAnAngle(&orig_obj_obbox, d_angle, obj_obbox_vs); } else { RotateVsByAnAngle(ObjPtr->rotated_obbox, 5, d_angle, obj_obbox_vs); } XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_obbox_vs, 5, CoordModeOrigin); } FormatAngleForRotate(buf, d_angle); ShowMeasureCursor(grid_x, grid_y, buf, TRUE); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } if (d_angle != 0) { HighLightReverse(); RotateAllSel(Corner, d_angle); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } if (vs != NULL) free(vs); if (orig_vs != NULL) free(orig_vs); } /* --------------------- Shearing --------------------- */ static void ShearBBox(Corner, bbox, dx_shear, dy_shear, dx_scale, dy_scale, vs) int Corner; double dx_shear, dy_shear, dx_scale, dy_scale; struct BBRec *bbox; /* the original bounding box */ XPoint *vs; /* array of 5 points */ { int x, y; switch (Corner) { case CORNER_TOP: case CORNER_BOTTOM: if (bbox->lty == pivotY) { vs[0].x = vs[4].x = bbox->ltx; vs[0].y = vs[4].y = bbox->lty; vs[1].x = bbox->rbx; vs[1].y = bbox->lty; } else { ShearedXY(Corner, bbox->ltx, bbox->lty, dx_shear, dy_shear, dx_scale, dy_scale, &x, &y); vs[0].x = vs[4].x = x; vs[0].y = vs[4].y = y; ShearedXY(Corner, bbox->rbx, bbox->lty, dx_shear, dy_shear, dx_scale, dy_scale, &x, &y); vs[1].x = x; vs[1].y = y; } if (bbox->rby == pivotY) { vs[2].x = bbox->rbx; vs[2].y = bbox->rby; vs[3].x = bbox->ltx; vs[3].y = bbox->rby; } else { ShearedXY(Corner, bbox->rbx, bbox->rby, dx_shear, dy_shear, dx_scale, dy_scale, &x, &y); vs[2].x = x; vs[2].y = y; ShearedXY(Corner, bbox->ltx, bbox->rby, dx_shear, dy_shear, dx_scale, dy_scale, &x, &y); vs[3].x = x; vs[3].y = y; } break; case CORNER_RIGHT: case CORNER_LEFT: if (bbox->ltx == pivotX) { vs[0].x = vs[4].x = bbox->ltx; vs[0].y = vs[4].y = bbox->lty; vs[3].x = bbox->ltx; vs[3].y = bbox->rby; } else { ShearedXY(Corner, bbox->ltx, bbox->lty, dx_shear, dy_shear, dx_scale, dy_scale, &x, &y); vs[0].x = vs[4].x = x; vs[0].y = vs[4].y = y; ShearedXY(Corner, bbox->ltx, bbox->rby, dx_shear, dy_shear, dx_scale, dy_scale, &x, &y); vs[3].x = x; vs[3].y = y; } if (bbox->rbx == pivotX) { vs[1].x = bbox->rbx; vs[1].y = bbox->lty; vs[2].x = bbox->rbx; vs[2].y = bbox->rby; } else { ShearedXY(Corner, bbox->rbx, bbox->lty, dx_shear, dy_shear, dx_scale, dy_scale, &x, &y); vs[1].x = x; vs[1].y = y; ShearedXY(Corner, bbox->rbx, bbox->rby, dx_shear, dy_shear, dx_scale, dy_scale, &x, &y); vs[2].x = x; vs[2].y = y; } break; } } static void ShearVs(Corner, InVs, NumPts, dx_shear, dy_shear, dx_scale, dy_scale, OutVs) int Corner, NumPts; double dx_shear, dy_shear, dx_scale, dy_scale; XPoint *InVs, *OutVs; /* array of 5 points */ { register int i; int x, y; switch (Corner) { case CORNER_TOP: case CORNER_BOTTOM: for (i=0; i < NumPts; i++) { if (InVs[i].y == pivotY) { OutVs[i].x = InVs[i].x; OutVs[i].y = InVs[i].y; } else { ShearedXY(Corner, InVs[i].x, InVs[i].y, dx_shear, dy_shear, dx_scale, dy_scale, &x, &y); OutVs[i].x = x; OutVs[i].y = y; } } break; case CORNER_RIGHT: case CORNER_LEFT: for (i=0; i < NumPts; i++) { if (InVs[i].x == pivotX) { OutVs[i].x = InVs[i].x; OutVs[i].y = InVs[i].y; } else { ShearedXY(Corner, InVs[i].x, InVs[i].y, dx_shear, dy_shear, dx_scale, dy_scale, &x, &y); OutVs[i].x = x; OutVs[i].y = y; } } break; } } static void ShearAllSelObjects(Corner, dxShear, dyShear, dxScale, dyScale) int Corner; double dxShear, dyShear, dxScale, dyScale; /* everything scaled by 1000 */ { register struct SelRec *sel_ptr; for (sel_ptr = topSel; sel_ptr != NULL; sel_ptr = sel_ptr->next) { if (OkToTransform(sel_ptr->obj, STID_DISABLE_ON_RESIZE_SHEAR)) { ShearObj(sel_ptr->obj, Corner, dxShear, dyShear, dxScale, dyScale, NULL, NULL); } } if (numObjLocked != 0) { Msg(TgLoadString(STID_LOCKED_OBJS_ARE_NOT_SHEARED)); } } static int ConstrainedShearAllSel(Corner, dxShear, dyShear, dxScale, dyScale, ltx, lty, rbx, rby) int Corner, *ltx, *lty, *rbx, *rby; double dxShear, dyShear, dxScale, dyScale; { register struct ObjRec *obj_ptr; int something_stretched=FALSE, num_pts; int x_off, y_off, move_first, move_last, x, y; IntPoint *v; for (obj_ptr=botObj; obj_ptr != NULL; obj_ptr=obj_ptr->prev) { if (!obj_ptr->marked && obj_ptr->type==OBJ_POLY && !obj_ptr->locked) { num_pts = obj_ptr->detail.p->n; v = obj_ptr->detail.p->vlist; if (obj_ptr->ctm == NULL) { x_off = OFFSET_X(v[0].x); y_off = OFFSET_Y(v[0].y); move_first = EndPtInSelected(x_off, y_off); x_off = OFFSET_X(v[num_pts-1].x); y_off = OFFSET_Y(v[num_pts-1].y); move_last = EndPtInSelected(x_off, y_off); } else { int tmp_x, tmp_y; TransformPointThroughCTM(v[0].x-obj_ptr->x, v[0].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); tmp_x += obj_ptr->x; tmp_y += obj_ptr->y; x_off = OFFSET_X(tmp_x); y_off = OFFSET_Y(tmp_y); move_first = EndPtInSelected(x_off, y_off); TransformPointThroughCTM(v[num_pts-1].x-obj_ptr->x, v[num_pts-1].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); tmp_x += obj_ptr->x; tmp_y += obj_ptr->y; x_off = OFFSET_X(tmp_x); y_off = OFFSET_Y(tmp_y); move_last = EndPtInSelected(x_off, y_off); } if (move_first || move_last) { int index=INVALID, seg_dx, seg_dy, dx, dy, cur_seg_dx, cur_seg_dy; PrepareToReplaceAnObj(obj_ptr); if (obj_ptr->ctm != NULL) { /* Remove the transformations! */ int i; for (i=0; i < num_pts; i++) { int tmp_x, tmp_y; TransformPointThroughCTM(v[i].x-obj_ptr->x, v[i].y-obj_ptr->y, obj_ptr->ctm, &tmp_x, &tmp_y); v[i].x = tmp_x+obj_ptr->x; v[i].y = tmp_y+obj_ptr->y; } free(obj_ptr->ctm); obj_ptr->ctm = NULL; UpdPolyBBox(obj_ptr, num_pts, v); } if (something_stretched) { if (obj_ptr->bbox.ltx < *ltx) *ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < *lty) *lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > *rbx) *rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > *rby) *rby = obj_ptr->bbox.rby; } else { *ltx = obj_ptr->bbox.ltx; *lty = obj_ptr->bbox.lty; *rbx = obj_ptr->bbox.rbx; *rby = obj_ptr->bbox.rby; } something_stretched = TRUE; if (move_first && move_last && num_pts==3) { ShearedAbsXY(Corner, v[0].x, v[0].y, dxShear, dyShear, dxScale, dyScale, &x, &y); dx = x-v[0].x; dy = y-v[0].y; index = 1; cur_seg_dx = v[index-1].x - v[index].x; cur_seg_dy = v[index-1].y - v[index].y; seg_dx = v[index].x - v[index+1].x; seg_dy = v[index].y - v[index+1].y; if (cur_seg_dy==0 && seg_dx==0 && (seg_dy!=0 || (seg_dy==0 && dx==0))) { v[index].y += dy; } else if (cur_seg_dx==0 && seg_dy==0 && (seg_dx!=0 || (seg_dx==0 && dy==0))) { v[index].x += dx; } } else { if (move_first && num_pts>2) { ShearedAbsXY(Corner, v[0].x, v[0].y, dxShear, dyShear, dxScale, dyScale, &x, &y); dx = x-v[0].x; dy = y-v[0].y; index = 1; cur_seg_dx = v[index-1].x - v[index].x; cur_seg_dy = v[index-1].y - v[index].y; seg_dx = v[index].x - v[index+1].x; seg_dy = v[index].y - v[index+1].y; if (cur_seg_dy==0 && cur_seg_dx!=0 && (seg_dy!=0 || (seg_dy==0 && dx==0))) { v[index].y += dy; } else if (cur_seg_dx==0 && cur_seg_dy!=0 && (seg_dx!=0 || (seg_dx==0 && dy==0))) { v[index].x += dx; } } if (move_last && num_pts>2) { ShearedAbsXY(Corner, v[num_pts-1].x, v[num_pts-1].y, dxShear, dyShear, dxScale, dyScale, &x, &y); dx = x-v[num_pts-1].x; dy = y-v[num_pts-1].y; index = num_pts-2; cur_seg_dx = v[index+1].x - v[index].x; cur_seg_dy = v[index+1].y - v[index].y; seg_dx = v[index].x - v[index-1].x; seg_dy = v[index].y - v[index-1].y; if (cur_seg_dy==0 && cur_seg_dx!=0 && (seg_dy!=0 || (seg_dy==0 && dx==0))) { v[index].y += dy; } else if (cur_seg_dx==0 && cur_seg_dy!=0 && (seg_dx!=0 || (seg_dx==0 && dy==0))) { v[index].x += dx; } } } if (move_first) { ShearedAbsXY(Corner, v[0].x, v[0].y, dxShear, dyShear, dxScale, dyScale, &x, &y); v[0].x = x; v[0].y = y; } if (move_last) { ShearedAbsXY(Corner, v[num_pts-1].x, v[num_pts-1].y, dxShear, dyShear, dxScale, dyScale, &x, &y); v[num_pts-1].x = x; v[num_pts-1].y = y; } AdjObjSplineVs(obj_ptr); switch (obj_ptr->type) { case OBJ_POLY: if (obj_ptr->detail.p->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, num_pts, v); } else { UpdPolyBBox(obj_ptr, obj_ptr->detail.p->intn, obj_ptr->detail.p->intvlist); } break; case OBJ_POLYGON: if (obj_ptr->detail.g->curved != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, num_pts, v); } else { UpdPolyBBox(obj_ptr, obj_ptr->detail.g->intn, obj_ptr->detail.g->intvlist); } break; } AdjObjBBox(obj_ptr); if (AutoCenterAttr(obj_ptr)) { struct AttrRec *attr_ptr=obj_ptr->fattr; int modified=FALSE; for ( ; attr_ptr != NULL; attr_ptr = attr_ptr->next) { if (attr_ptr->shown) { struct BBRec bbox; CenterObjInOBBox(attr_ptr->obj, obj_ptr->obbox, &bbox); if (bbox.ltx < *ltx) *ltx = bbox.ltx; if (bbox.lty < *lty) *lty = bbox.lty; if (bbox.rbx > *rbx) *rbx = bbox.rbx; if (bbox.rby > *rby) *rby = bbox.rby; modified = TRUE; } } if (modified) AdjObjBBox(obj_ptr); } if (obj_ptr->bbox.ltx < *ltx) *ltx = obj_ptr->bbox.ltx; if (obj_ptr->bbox.lty < *lty) *lty = obj_ptr->bbox.lty; if (obj_ptr->bbox.rbx > *rbx) *rbx = obj_ptr->bbox.rbx; if (obj_ptr->bbox.rby > *rby) *rby = obj_ptr->bbox.rby; RecordReplaceAnObj(obj_ptr); } } } return something_stretched; } static void ShearAllSel(Corner, dxShear, dyShear, dxScale, dyScale) int Corner; double dxShear, dyShear, dxScale, dyScale; /* everything scaled by 1000 */ { int ltx=0, lty=0, rbx=0, rby=0, saved_ltx, saved_lty, saved_rbx, saved_rby; int poly_stretched; saved_ltx = selLtX; saved_lty = selLtY; saved_rbx = selRbX; saved_rby = selRbY; if (moveMode==CONST_MOVE) { MarkObjectsForStretch(); StartCompositeCmd(); PrepareToRecord(CMD_STRETCH, topSel, botSel, numObjSelected); RecordCmd(CMD_STRETCH, NULL, topSel, botSel, numObjSelected); poly_stretched = ConstrainedShearAllSel(Corner, dxShear, dyShear, dxScale, dyScale, <x, <y, &rbx, &rby); ShearAllSelObjects(Corner, dxShear, dyShear, dxScale, dyScale); UpdSelBBox(); if (poly_stretched) { ltx = min(ltx,min(selLtX,saved_ltx)); lty = min(lty,min(selLtY,saved_lty)); rbx = max(rbx,max(selRbX,saved_rbx)); rby = max(rby,max(selRbY,saved_rby)); RedrawAnArea(botObj, ltx-GRID_ABS_SIZE(1), lty-GRID_ABS_SIZE(1), rbx+GRID_ABS_SIZE(1), rby+GRID_ABS_SIZE(1)); } else { RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } EndCompositeCmd(); } else { PrepareToRecord(CMD_REPLACE, topSel, botSel, numObjSelected); ShearAllSelObjects(Corner, dxShear, dyShear, dxScale, dyScale); RecordCmd(CMD_REPLACE, NULL, topSel, botSel, numObjSelected); UpdSelBBox(); RedrawAreas(botObj, saved_ltx-GRID_ABS_SIZE(1), saved_lty-GRID_ABS_SIZE(1), saved_rbx+GRID_ABS_SIZE(1), saved_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); } } static void ShearSel(XGridOff, YGridOff, ObjPtr, Corner) int XGridOff, YGridOff, Corner; struct ObjRec *ObjPtr; { XEvent ev; XPoint all_bbox_vs[5], obj_obbox_vs[5]; int grid_x=XGridOff, grid_y=YGridOff, dx, dy; int saved_x=XGridOff, saved_y=YGridOff; int shearing=TRUE, shear_hori=FALSE; double dx_scale=(double)1000, dy_scale=(double)1000; double dx_shear=(double)0, dy_shear=(double)0; char buf[80]; struct BBRec orig_all_bbox, orig_obj_obbox; if (numObjSelected == numObjLocked || ObjPtr->locked) { MsgBox(TgLoadString(STID_LOCKED_OBJS_CANT_BE_ROTATED), TOOL_NAME, INFO_MB); return; } XFlush(mainDisplay); XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } SetPivot(Corner, &ObjPtr->obbox); SetBBRec(&orig_all_bbox, OFFSET_X(selNoLockLtX)-2, OFFSET_Y(selNoLockLtY)-2, OFFSET_X(selNoLockRbX)+2, OFFSET_Y(selNoLockRbY)+2); SetRotateVs(all_bbox_vs, orig_all_bbox.ltx, orig_all_bbox.lty, orig_all_bbox.rbx, orig_all_bbox.rby); XDrawLines(mainDisplay, drawWindow, revDefaultGC, all_bbox_vs, 5, CoordModeOrigin); if (ObjPtr->ctm == NULL) { SetBBRec(&orig_obj_obbox, OFFSET_X(ObjPtr->obbox.ltx), OFFSET_Y(ObjPtr->obbox.lty), OFFSET_X(ObjPtr->obbox.rbx), OFFSET_Y(ObjPtr->obbox.rby)); SetRotateVs(obj_obbox_vs, orig_obj_obbox.ltx, orig_obj_obbox.lty, orig_obj_obbox.rbx, orig_obj_obbox.rby); XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_obbox_vs, 5, CoordModeOrigin); } else { memcpy(obj_obbox_vs, ObjPtr->rotated_obbox, 5*sizeof(XPoint)); XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_obbox_vs, 5, CoordModeOrigin); } dx = OFFSET_X(ObjPtr->obbox.rbx) - OFFSET_X(ObjPtr->obbox.ltx); dy = OFFSET_Y(ObjPtr->obbox.rby) - OFFSET_Y(ObjPtr->obbox.lty); if (dx == 0 || dy == 0) { MsgBox(TgLoadString(STID_SEL_OBJ_TOO_SMALL_SHEAR_ANO), TOOL_NAME, INFO_MB); return; } if (Corner == CORNER_TOP || Corner == CORNER_BOTTOM) { shear_hori = TRUE; multX = 0.0; multY = (Corner == CORNER_BOTTOM ? 1.0 : (-1.0)); } else { shear_hori = FALSE; multX = (Corner == CORNER_RIGHT ? 1.0 : (-1.0)); multY = 0.0; } dx = dy = 0; grid_x = moveX; grid_y = moveY; sprintf(buf, "dx=0\ndy=0"); StartShowMeasureCursor(grid_x, grid_y, buf, TRUE); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, False, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, ((Corner==CORNER_TOP || Corner==CORNER_BOTTOM) ? horiShearCursor : vertShearCursor), CurrentTime); } while (shearing) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); shearing = FALSE; sprintf(buf, "dx=%1d\ndy=%1d", dx, dy); EndShowMeasureCursor(grid_x, grid_y, buf, TRUE); XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_obbox_vs, 5, CoordModeOrigin); XDrawLines(mainDisplay, drawWindow, revDefaultGC, all_bbox_vs, 5, CoordModeOrigin); } else if (input.type == MotionNotify) { sprintf(buf, "dx=%1d\ndy=%1d", dx, dy); ShowMeasureCursor(grid_x, grid_y, buf, TRUE); XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_obbox_vs, 5, CoordModeOrigin); XDrawLines(mainDisplay, drawWindow, revDefaultGC, all_bbox_vs, 5, CoordModeOrigin); GridXY(input.xmotion.x, input.xmotion.y, &grid_x, &grid_y); dx = grid_x - saved_x; dy = grid_y - saved_y; grid_x = moveX + dx; grid_y = moveY + dy; MarkRulers(grid_x, grid_y); PointsToShearScale(Corner, pivotX, pivotY, moveX, moveY, grid_x, grid_y, &dx_shear, &dy_shear, &dx_scale, &dy_scale); ShearBBox(Corner, &orig_all_bbox, dx_shear, dy_shear, dx_scale, dy_scale, all_bbox_vs); XDrawLines(mainDisplay, drawWindow, revDefaultGC, all_bbox_vs, 5, CoordModeOrigin); if (ObjPtr->ctm == NULL) { ShearBBox(Corner, &orig_obj_obbox, dx_shear, dy_shear, dx_scale, dy_scale, obj_obbox_vs); } else { ShearVs(Corner, ObjPtr->rotated_obbox, 5, dx_shear, dy_shear, dx_scale, dy_scale, obj_obbox_vs); } XDrawLines(mainDisplay, drawWindow, revDefaultGC, obj_obbox_vs, 5, CoordModeOrigin); sprintf(buf, "dx=%1d\ndy=%1d", dx, dy); ShowMeasureCursor(grid_x, grid_y, buf, TRUE); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } ShowCursor(); if (dx != 0 || dy != 0) { PointsToShearScale(Corner, pivotX, pivotY, moveX, moveY, moveX+dx, moveY+dy, &dx_shear, &dy_shear, &dx_scale, &dy_scale); HighLightReverse(); ShearAllSel(Corner, dx_shear, dy_shear, dx_scale, dy_scale); HighLightForward(); SetFileModified(TRUE); justDupped = FALSE; } } void RotateShearSel(XGridOff, YGridOff, ObjPtr, Corner) int XGridOff, YGridOff, Corner; struct ObjRec *ObjPtr; /* 1 2 3 */ /* 8 4 */ /* 7 6 5 */ { if (ObjPtr->type==OBJ_POLY || ObjPtr->type==OBJ_POLYGON || (Corner & 0x1)) { RotateSel(XGridOff, YGridOff, ObjPtr, Corner); } else { ShearSel(XGridOff, YGridOff, ObjPtr, Corner); } } /* --------------------- Rotation Pivot --------------------- */ static int RefreshFlipRotateMenu(menu) TgMenu *menu; { int ok=TRUE, can_suggest_poly=FALSE, can_suggest_arc=FALSE; /* ResetRotationPivot */ ok &= TgEnableMenuItemById(menu, CMDID_RESETROTATEPIVOT, !autoRotatePivot && topSel != NULL); /* SpecifyRotationPivot */ ok &= TgEnableMenuItemById(menu, CMDID_SPECIFYROTATEPIVOT, curChoice == ROTATEMODE && topSel != NULL); /* NextPolyRotationPivot */ /* MoveRotationPivotToArcCenter */ if (!autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL && topSel == botSel) { struct ObjRec *obj_ptr=topSel->obj; if (obj_ptr->type == OBJ_POLY || obj_ptr->type == OBJ_POLYGON) { can_suggest_poly = TRUE; } else if (obj_ptr->type == OBJ_ARC) { can_suggest_arc = TRUE; } } ok &= TgEnableMenuItemById(menu, CMDID_NEXTPOLYROTATEPIVOT, can_suggest_poly); ok &= TgEnableMenuItemById(menu, CMDID_MOVEROTATEPIVOTARCCNTR, can_suggest_arc); return ok; } TgMenu *CreateFlipRotateMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { menu->track_menubar = TRUE; if (!RefreshFlipRotateMenu(menu)) { return TgDestroyMenu(menu, TRUE); } } return menu; } static void HighLightRotatePivotXY(abs_x, abs_y, Dir) int abs_x, abs_y, Dir; { int scr_x=OFFSET_X(abs_x), scr_y=OFFSET_Y(abs_y); switch (Dir) { case FORWARD: XDrawLine(mainDisplay, drawWindow, revDefaultGC, scr_x-((handleSize<<1)+1), scr_y, scr_x+((handleSize<<1)+1), scr_y); XDrawLine(mainDisplay, drawWindow, revDefaultGC, scr_x, scr_y-((handleSize<<1)+1), scr_x, scr_y+((handleSize<<1)+1)); XDrawArc(mainDisplay, drawWindow, revDefaultGC, scr_x-((handleSize<<1)+1), scr_y-((handleSize<<1)+1), ((handleSize<<2)+2), ((handleSize<<2)+2), 0, (360<<6)); break; case REVERSE: XDrawArc(mainDisplay, drawWindow, revDefaultGC, scr_x-((handleSize<<1)+1), scr_y-((handleSize<<1)+1), ((handleSize<<2)+2), ((handleSize<<2)+2), 0, (360<<6)); XDrawLine(mainDisplay, drawWindow, revDefaultGC, scr_x, scr_y-((handleSize<<1)+1), scr_x, scr_y+((handleSize<<1)+1)); XDrawLine(mainDisplay, drawWindow, revDefaultGC, scr_x-((handleSize<<1)+1), scr_y, scr_x+((handleSize<<1)+1), scr_y); break; } } void HighLightRotatePivot(Dir) int Dir; { int scr_x=0, scr_y=0; if (topSel == NULL || autoRotatePivot) return; if (!rotatePivotAbsXYValid) { rotatePivotAbsX = ((selObjLtX+selObjRbX)>>1); rotatePivotAbsY = ((selObjLtY+selObjRbY)>>1); rotatePivotAbsXYValid = TRUE; sprintf(gszMsgBox, TgLoadString(STID_NEW_ROTATE_PIVOT_IS), rotatePivotAbsX, rotatePivotAbsY); Msg(gszMsgBox); } scr_x = OFFSET_X(rotatePivotAbsX); scr_y = OFFSET_Y(rotatePivotAbsY); switch (Dir) { case FORWARD: XDrawLine(mainDisplay, drawWindow, revDefaultGC, scr_x-((handleSize<<1)+1), scr_y, scr_x+((handleSize<<1)+1), scr_y); XDrawLine(mainDisplay, drawWindow, revDefaultGC, scr_x, scr_y-((handleSize<<1)+1), scr_x, scr_y+((handleSize<<1)+1)); XDrawArc(mainDisplay, drawWindow, revDefaultGC, scr_x-((handleSize<<1)+1), scr_y-((handleSize<<1)+1), ((handleSize<<2)+2), ((handleSize<<2)+2), 0, (360<<6)); break; case REVERSE: XDrawArc(mainDisplay, drawWindow, revDefaultGC, scr_x-((handleSize<<1)+1), scr_y-((handleSize<<1)+1), ((handleSize<<2)+2), ((handleSize<<2)+2), 0, (360<<6)); XDrawLine(mainDisplay, drawWindow, revDefaultGC, scr_x, scr_y-((handleSize<<1)+1), scr_x, scr_y+((handleSize<<1)+1)); XDrawLine(mainDisplay, drawWindow, revDefaultGC, scr_x-((handleSize<<1)+1), scr_y, scr_x+((handleSize<<1)+1), scr_y); break; } } int PtInRotatePivot(mouse_x, mouse_y) int mouse_x, mouse_y; { int scr_x=0, scr_y=0; struct BBRec bbox; if (!rotatePivotAbsXYValid) return FALSE; scr_x = OFFSET_X(rotatePivotAbsX); scr_y = OFFSET_Y(rotatePivotAbsY); bbox.ltx = scr_x-((handleSize<<1)+1); bbox.lty = scr_y-((handleSize<<1)+1); bbox.rbx = scr_x+((handleSize<<1)+1); bbox.rby = scr_y+((handleSize<<1)+1); return PointInBBox(mouse_x, mouse_y, bbox); } static int RefreshMoveStdRotatePivotMenu(menu) TgMenu *menu; { int ok=TRUE; /* MoveRotationPivotToCenter */ ok &= TgEnableMenuItemById(menu, CMDID_MOVEROTATEPIVOTCENTER, !autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL); /* MoveRotationPivotToLeftTopCorner */ ok &= TgEnableMenuItemById(menu, CMDID_MOVEROTATEPIVOTLT, !autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL); /* MoveRotationPivotToRightTopCorner */ ok &= TgEnableMenuItemById(menu, CMDID_MOVEROTATEPIVOTRT, !autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL); /* MoveRotationPivotToLeftBottomCorner */ ok &= TgEnableMenuItemById(menu, CMDID_MOVEROTATEPIVOTLB, !autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL); /* MoveRotationPivotToRightBottomCorner */ ok &= TgEnableMenuItemById(menu, CMDID_MOVEROTATEPIVOTRB, !autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL); /* MoveRotationPivotToLeftCorner */ ok &= TgEnableMenuItemById(menu, CMDID_MOVEROTATEPIVOTLEFT, !autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL); /* MoveRotationPivotToRightCorner */ ok &= TgEnableMenuItemById(menu, CMDID_MOVEROTATEPIVOTRIGHT, !autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL); /* MoveRotationPivotToTopCorner */ ok &= TgEnableMenuItemById(menu, CMDID_MOVEROTATEPIVOTTOP, !autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL); /* MoveRotationPivotToBottomCorner */ ok &= TgEnableMenuItemById(menu, CMDID_MOVEROTATEPIVOTBOTTOM, !autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL); return ok; } TgMenu *CreateMoveStdRotatePivotMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { menu->track_menubar = TRUE; if (!RefreshMoveStdRotatePivotMenu(menu)) { return TgDestroyMenu(menu, TRUE); } } return menu; } void RefreshAutoRotatePivotMenu(menu) TgMenu *menu; { int i, num_items=menu->num_items; TgMenuItem *menuitems=menu->menuitems; for (i=0; i < num_items; i++) { TgMenuItem *menu_item=(&menuitems[i]); TgMenuItem stMenuItem; memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.state = TGBS_NORMAL; stMenuItem.checked = (i == (!autoRotatePivot)); TgSetMenuItemInfo(menu_item, TGMU_MASK_STATE|TGMU_MASK_CHECK, &stMenuItem); } } TgMenu *CreateAutoRotatePivotMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { TgMenuItem *menu_item=NULL; TgMenuItem stMenuItem; menu->track_menubar = TRUE; TgAdjustMenuGeometry(menu, choiceImageW, choiceImageH, MAX_ROTATE_PIVOT); menu_item = (&menu->menuitems[!autoRotatePivot]); memset(&stMenuItem, 0, sizeof(TgMenuItem)); stMenuItem.checked = TRUE; if (!TgSetMenuItemInfo(menu_item, TGMU_MASK_CHECK, &stMenuItem)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshAutoRotatePivotMenu); } return menu; } int AutoRotatePivotMenu(X, Y, TrackMenubar) int X, Y, TrackMenubar; { int rc=INVALID; TgMenu *menu=(autoRotatePivotMenuInfo.create_proc)(NULL, X, Y, &autoRotatePivotMenuInfo, INVALID); activeMenu = INVALID; if (menu != NULL) { menu->track_menubar = TrackMenubar; rc = TgMenuLoop(menu); TgDestroyMenu(menu, TRUE); } return rc; } void ResetRotatePivotValidInfo() { rotatePivotAbsXYValid = FALSE; rotatePivotAbsX = 0; rotatePivotAbsY = 0; } int ReadRotatePivotInfo(buf) char *buf; { int auto_pivot=TRUE, xy_valid=0, abs_x=0, abs_y=0; char *psz=NULL; if (importingFile) return TRUE; psz = FindChar((int)'(', buf); InitScan(psz, "\t\n, "); if (GETINT("rotate_pivot", auto_pivot, "auto_pivot") == INVALID || GETINT("rotate_pivot", xy_valid, "xy_valid") == INVALID || GETINT("rotate_pivot", abs_x, "x") == INVALID || GETINT("rotate_pivot", abs_y, "y") == INVALID) { return FALSE; } autoRotatePivot = auto_pivot; rotatePivotAbsXYValid = xy_valid; rotatePivotAbsX = abs_x; rotatePivotAbsY = abs_y; if (!PRTGIF || cmdLineOpenDisplay) { choicePixmap[ROTATEMODE] = rotateModePixmap[!autoRotatePivot]; RedrawModeWindow(); UpdatePinnedMenu(MENU_MODE); } return TRUE; } void ContinueMoveRotatePivot(OrigX, OrigY) int OrigX, OrigY; { int moving=TRUE, dx=0, dy=0, grid_x=OrigX, grid_y=OrigY; char buf[80], x_buf[80], y_buf[80]; XEvent ev; XFlush(mainDisplay); XSync(mainDisplay, False); if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } PixelToMeasurementUnit(x_buf, rotatePivotAbsX); PixelToMeasurementUnit(y_buf, rotatePivotAbsY); sprintf(buf, "x=%s\ny=%s", x_buf, y_buf); StartShowMeasureCursor(OrigX, OrigY, buf, TRUE); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, moveCursor, CurrentTime); } dx = dy = 0; while (moving) { XEvent input; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); } else if (input.type == ButtonRelease) { XUngrabPointer(mainDisplay, CurrentTime); XSync(mainDisplay, False); moving = FALSE; /* erase */ PixelToMeasurementUnit(x_buf, rotatePivotAbsX+ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, rotatePivotAbsY+ABS_SIZE(dy)); sprintf(buf, "x=%s\ny=%s", x_buf, y_buf); ShowMeasureCursor(grid_x, grid_y, buf, TRUE); HighLightRotatePivotXY(rotatePivotAbsX+ABS_SIZE(dx), rotatePivotAbsY+ABS_SIZE(dy), REVERSE); dx = grid_x - OrigX; dy = grid_y - OrigY; } else if (input.type == MotionNotify) { int x=0, y=0; /* erase */ PixelToMeasurementUnit(x_buf, rotatePivotAbsX+ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, rotatePivotAbsY+ABS_SIZE(dy)); sprintf(buf, "x=%s\ny=%s", x_buf, y_buf); ShowMeasureCursor(grid_x, grid_y, buf, TRUE); HighLightRotatePivotXY(rotatePivotAbsX+ABS_SIZE(dx), rotatePivotAbsY+ABS_SIZE(dy), REVERSE); x = input.xmotion.x; y = input.xmotion.y; GridXY(x, y, &grid_x, &grid_y); dx = grid_x - OrigX; dy = grid_y - OrigY; HighLightRotatePivotXY(rotatePivotAbsX+ABS_SIZE(dx), rotatePivotAbsY+ABS_SIZE(dy), FORWARD); PixelToMeasurementUnit(x_buf, rotatePivotAbsX+ABS_SIZE(dx)); PixelToMeasurementUnit(y_buf, rotatePivotAbsY+ABS_SIZE(dy)); sprintf(buf, "x=%s\ny=%s", x_buf, y_buf); ShowMeasureCursor(grid_x, grid_y, buf, TRUE); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } } if (dx != 0 || dy != 0) { rotatePivotAbsX += ABS_SIZE(dx); rotatePivotAbsY += ABS_SIZE(dy); sprintf(gszMsgBox, TgLoadString(STID_NEW_ROTATE_PIVOT_IS), rotatePivotAbsX, rotatePivotAbsY); Msg(gszMsgBox); } HighLightRotatePivotXY(rotatePivotAbsX, rotatePivotAbsY, FORWARD); } void ToggleAutoRotatePivot() { if (topSel != NULL && curChoice == ROTATEMODE) { if (somethingHighLighted) HighLightReverse(); } autoRotatePivot = !autoRotatePivot; if (autoRotatePivot) { ResetRotatePivotValidInfo(); Msg(TgLoadString(STID_SWITCHED_TO_AUTO_ROTATE_PIVOT)); } else { Msg(TgLoadString(STID_SWITCHED_TO_USER_ROTATE_PIVOT)); } choicePixmap[ROTATEMODE] = rotateModePixmap[!autoRotatePivot]; RedrawModeWindow(); UpdatePinnedMenu(MENU_MODE); if (topSel != NULL && curChoice == ROTATEMODE) { if (!somethingHighLighted) HighLightForward(); } } void SpecifyRotatePivot() { char spec[MAXSTRING]; int abs_x=0, abs_y=0; if (autoRotatePivot) { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_ENTER_ROT_PIVOT)); } else if (rotatePivotAbsXYValid) { sprintf(gszMsgBox, TgLoadString(STID_ENTER_ROT_PIVOT_CUR_IS), rotatePivotAbsX, rotatePivotAbsY); } else { UtilStrCpyN(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_ENTER_ROT_PIVOT)); } *spec = '\0'; Dialog(gszMsgBox, TgLoadCachedString(CSTID_DLG_ACCEPT_CANCEL), spec); UtilTrimBlanks(spec); if (*spec == '\0') return; if (ParseXYSpec(spec, &abs_x, &abs_y)) { if (autoRotatePivot) { ToggleAutoRotatePivot(); rotatePivotAbsXYValid = TRUE; } else if (rotatePivotAbsXYValid) { /* nothing to do here */ } else { rotatePivotAbsXYValid = TRUE; } rotatePivotAbsX = abs_x; rotatePivotAbsY = abs_y; sprintf(gszMsgBox, TgLoadString(STID_ROT_PIVOT_SET_TO), rotatePivotAbsX, rotatePivotAbsY); Msg(gszMsgBox); } } void ResetRotatePivot() { if (topSel != NULL && curChoice == ROTATEMODE) { if (somethingHighLighted) HighLightReverse(); } ResetRotatePivotValidInfo(); if (topSel != NULL && curChoice == ROTATEMODE) { if (!somethingHighLighted) HighLightForward(); } } static IntPoint *GetPolyVertices(N, ObjPtr, NumPts, V, Curved, pn_need_to_free) int *N, NumPts, Curved, *pn_need_to_free; struct ObjRec *ObjPtr; IntPoint *V; { if (ObjPtr->ctm == NULL) { *pn_need_to_free = FALSE; *N = NumPts; return V; } else { int i=0; IntPoint *v=(IntPoint*)malloc(NumPts*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); memset(v, 0, NumPts*sizeof(IntPoint)); for (i=0; i < NumPts; i++) { int x=0, y=0; TransformPointThroughCTM(V[i].x-ObjPtr->x, V[i].y-ObjPtr->y, ObjPtr->ctm, &x, &y); v[i].x = x+ObjPtr->x; v[i].y = y+ObjPtr->y; } *pn_need_to_free = TRUE; *N = NumPts; return v; } } void NextPolyRotationPivot() { int i=0, can_suggest=FALSE, num_pts=0, need_to_free=FALSE, min_index=0; struct ObjRec *obj_ptr=NULL; IntPoint *v=NULL; double min_dist=(double)0; if (!autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL && topSel == botSel) { obj_ptr = topSel->obj; if (obj_ptr->type == OBJ_POLY) { struct PolyRec *poly_ptr=obj_ptr->detail.p; v = GetPolyVertices(&num_pts, obj_ptr, poly_ptr->n, poly_ptr->vlist, poly_ptr->curved, &need_to_free); can_suggest = TRUE; } else if (obj_ptr->type == OBJ_POLYGON) { struct PolygonRec *polygon_ptr=obj_ptr->detail.g; v = GetPolyVertices(&num_pts, obj_ptr, polygon_ptr->n-1, polygon_ptr->vlist, polygon_ptr->curved, &need_to_free); can_suggest = TRUE; } } if (!can_suggest) { MsgBox(TgLoadString(STID_SELONLYONEPOLYOBJ), TOOL_NAME, INFO_MB); return; } HighLightReverse(); if (rotatePivotAbsXYValid) { int dx=rotatePivotAbsX-v[0].x, dy=rotatePivotAbsY-v[0].y; int coincide_index=(-1); double ddx=(double)0, ddy=(double)0, dist=(double)0; min_index = 0; if (dx == 0 && dy == 0) { coincide_index = 0; min_dist = (double)0; } else { ddx = (double)dx; ddy = (double)dy; min_dist = (double)sqrt(ddx*ddx+ddy+ddy); } for (i=1; i < num_pts; i++) { dx = rotatePivotAbsX-v[i].x; dy = rotatePivotAbsY-v[i].y; if (dx == 0 && dy == 0) { if (coincide_index == (-1)) { coincide_index = i; min_index = i; min_dist = (double)0; } else if (coincide_index+1 == i) { coincide_index = i; min_index = i; min_dist = (double)0; } else { /* stick to the original coincide_index */ } } else { ddx = (double)dx; ddy = (double)dy; dist = (double)sqrt(ddx*ddx+ddy+ddy); if (dist < min_dist) { min_index = i; min_dist = dist; } } } if (coincide_index != (-1)) { min_index = coincide_index+1; } if (min_index >= num_pts) { min_index = 0; } } else { min_index = 0; } rotatePivotAbsXYValid = TRUE; rotatePivotAbsX = v[min_index].x; rotatePivotAbsY = v[min_index].y; if (need_to_free) free(v); sprintf(gszMsgBox, TgLoadString(STID_NEW_ROTATE_PIVOT_IS), rotatePivotAbsX, rotatePivotAbsY); Msg(gszMsgBox); HighLightForward(); } void MoveRotationPivotToArcCenter() { int can_suggest=FALSE, x=0, y=0; struct ObjRec *obj_ptr=NULL; struct ArcRec *arc_ptr=NULL; if (!autoRotatePivot && curChoice == ROTATEMODE && topSel != NULL && topSel == botSel) { obj_ptr = topSel->obj; if (obj_ptr->type == OBJ_ARC) { arc_ptr = obj_ptr->detail.a; can_suggest = TRUE; } } if (!can_suggest) { MsgBox(TgLoadString(STID_SELONLYONEARCOBJ), TOOL_NAME, INFO_MB); return; } HighLightReverse(); if (obj_ptr->ctm == NULL) { x = arc_ptr->xc; y = arc_ptr->yc; } else { TransformPointThroughCTM(arc_ptr->xc-obj_ptr->x, arc_ptr->yc-obj_ptr->y, obj_ptr->ctm, &x, &y); x += obj_ptr->x; y += obj_ptr->y; } rotatePivotAbsXYValid = TRUE; rotatePivotAbsX = x; rotatePivotAbsY = y; sprintf(gszMsgBox, TgLoadString(STID_NEW_ROTATE_PIVOT_IS), rotatePivotAbsX, rotatePivotAbsY); Msg(gszMsgBox); HighLightForward(); } void MoveRotatePivot(Corner) int Corner; { if (topSel == NULL || curChoice != ROTATEMODE) return; HighLightReverse(); switch (Corner) { case CORNER_NONE: rotatePivotAbsX = ((selObjLtX+selObjRbX)>>1); rotatePivotAbsY = ((selObjLtY+selObjRbY)>>1); break; case CORNER_LT: rotatePivotAbsX = selObjLtX; rotatePivotAbsY = selObjLtY; break; case CORNER_RT: rotatePivotAbsX = selObjRbX; rotatePivotAbsY = selObjLtY; break; case CORNER_LB: rotatePivotAbsX = selObjLtX; rotatePivotAbsY = selObjRbY; break; case CORNER_RB: rotatePivotAbsX = selObjRbX; rotatePivotAbsY = selObjRbY; break; case CORNER_LEFT: rotatePivotAbsX = selObjLtX; rotatePivotAbsY = ((selObjLtY+selObjRbY)>>1); break; case CORNER_RIGHT: rotatePivotAbsX = selObjRbX; rotatePivotAbsY = ((selObjLtY+selObjRbY)>>1); break; case CORNER_TOP: rotatePivotAbsX = ((selObjLtX+selObjRbX)>>1); rotatePivotAbsY = selObjLtY; break; case CORNER_BOTTOM: rotatePivotAbsX = ((selObjLtX+selObjRbX)>>1); rotatePivotAbsY = selObjRbY; break; } rotatePivotAbsXYValid = TRUE; sprintf(gszMsgBox, TgLoadString(STID_NEW_ROTATE_PIVOT_IS), rotatePivotAbsX, rotatePivotAbsY); Msg(gszMsgBox); HighLightForward(); } void AutoRotatePivotSubMenu(index) int index; { if (!autoRotatePivot == index) return; ToggleAutoRotatePivot(); } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/eq4xpm-land.sym����������������������������������������������������������������������0000644�0000764�0000764�00000053151�11602233311�015654� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������%TGIF 4.1.46-QPL state(0,37,100.000,0,0,0,16,1,9,1,1,0,0,1,0,1,0,'Courier',0,80640,0,0,0,10,0,0,1,1,0,16,0,0,1,1,1,1,1088,1408,1,0,2880,0). % % @(#)$Header: /mm2/home/cvs/bc-src/tgif/eq4xpm-land.sym,v 1.1 2009/07/06 20:10:36 william Exp $ % %W% % unit("1 pixel/pixel"). color_info(13,65535,0,[ "magenta", 65535, 0, 65535, 65535, 0, 65535, 1, "red", 65535, 0, 0, 65535, 0, 0, 1, "green", 0, 65535, 0, 0, 65535, 0, 1, "blue", 0, 0, 65535, 0, 0, 65535, 1, "yellow", 65535, 65535, 0, 65535, 65535, 0, 1, "pink", 65535, 49344, 52171, 65535, 49344, 52171, 1, "cyan", 0, 65535, 65535, 0, 65535, 65535, 1, "CadetBlue", 24415, 40606, 41120, 24415, 40606, 41120, 1, "white", 65535, 65535, 65535, 65535, 65535, 65535, 1, "black", 0, 0, 0, 0, 0, 0, 1, "DarkSlateGray", 12079, 20303, 20303, 12079, 20303, 20303, 1, "#0000ff", 0, 0, 65535, 0, 0, 65280, 1, "#ff00ff", 65535, 0, 65535, 65280, 0, 65280, 1 ]). script_frac("0.6"). fg_bg_colors('black','white'). dont_reencode("FFDingbests:ZapfDingbats"). objshadow_info('#c0c0c0',2,2). page(1,"",1,''). sym([ polygon('yellow','',5,[ 128,134,192,134,192,118,128,118,128,134],0,1,0,0,15817,0,0,0,0,0,'1',0, "00",[ ]), xpm('black','',128,118,328,158,0,8,1,0,16136,0,200,40,0,0,0,0,0,0,[ " ", "black", 0, 0, 0, ".", "black", 0, 0, 0, "X", "black", 0, 0, 0, "o", "black", 0, 0, 0, "O", "black", 0, 0, 0, "+", "black", 0, 0, 0, "@", "black", 0, 0, 0, "#", "None", 0, 0, 0],[ "########################################################################################################################################################################################################", "########################################################################################################################################################################################### #######", "######################################################################################################################################################################################### ######", "######################################################################################################################################################################################### #### #####", "######################################################################################################################################################################################## ###### ####", "######################################################################################################################################################################################## ###### ####", "######################################################################################################################################################################################## ##### ####", "######################################################################################################################################################################################## ##### ####", "############# ### ### ### # ## ############################################################################### #################### ######################### ##### ### ###### ####", "########## ############################################################################ ################# ##################### ### ########## #####", "########## ############################################################################ ################ ################### ###### # ########## #####", "############# ########### ############################################################################### ############### ###################### ########## ######### ######", "############# ############# ############################################################################### ############### ##################### ############ ######### #######", "############# ############# ############################################################################### ############## ##################### ############## ######## ########", "############ ############## ############################################################################### ############## #################### ############### ####### #########", "############ ############## ############################################################################## ############# # ################### ################ ###### #### ####", "############ ############## ############################################################################## # ########### ## ################## ################# ##### ##### ####", "############ ####### ##### ############################################################################### ## ########### # ################## ################## ###### ###### ####", "########### ####### ###### ############################################################################### ## ########## ## ################## ################### ##### ####", "########### ####### ##################################################################################### ## ######### ## ################# ################## #### ####", "########### ####### ##################################################################################### ### ######### ### ################# ######################### #####", "########### # # ###################################################################################### ### ######## ### ################# ##########################################", "########### ############################## ############################# ### ####### ### ################# ##########################################", "########## ############################## ############################ ### ####### #### ################# ##########################################", "########## ####### ############################### # # # # # # # # ############################# #### ###### ##### ################# ##########################################", "########## ####### ###################################################################################### ##### ##### #### ################## ###########################################", "######### ####### ####### ############################################################################## ##### #### ##### ################# ###########################################", "######### ####### ###### ############################################################################# ##### ### ##### ################## ################### ######################", "######### ############### ############################################################################# ###### ### ###### ################## ################## #######################", "######### ############### ######################### ############################ ###### ## ###### ################### ################## #######################", "######### ############## ######################## ########################### ###### # ###### ################### ################# #######################", "######## ############## ########################## ########################## ###### # ####### ################### ################ ########################", "######## ############## ############################################################################## ######## ######## #################### ############### #########################", "######## ############# ############################################################################## ######## ####### ##################### ############# ##########################", "####### ############ ############################################################################## ######## ######## ###################### ########## ###########################", "###### # # # # ############################################################################ ###### ####### # ##################### ####### ############################", "### ########################################################################### ##### ##### ##################### #############################", "#### ############################################################################ ###### ###### ####################### ###############################", "################################################################################################################################################################### ###################################", "########################################################################################################################################################################################################"],[ ]) ], 15816,0,0,[ attr("ecmd=", "", 0, 1, 1, text('blue',224,434,6,0,1,1215,90,15834,12,3,0,0,0,0,2,1215,90,0,0,"",0,0,0,0,446,'',[ minilines(1215,90,0,0,0,0,0,[ mini_line(45,12,3,0,0,0,[ str_block(0,45,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,12,3,0,-1,0,0,0,0,0, "ecmd=")]) ]), mini_line(108,12,3,0,0,0,[ str_block(0,108,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,108,12,3,0,-4,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(459,12,3,0,0,0,[ str_block(0,459,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,459,12,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e latex $(file_name);")]) ]), mini_line(711,12,3,0,0,0,[ str_block(0,711,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,711,12,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e dvips -E -n 1 -o $(file_name).eps $(file_name);")]) ]), mini_line(1215,12,3,0,0,0,[ str_block(0,1215,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1215,12,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e convert -geometry $(geometry) -density $(density) -colors $(colors) $(file_name).eps $(file_name).ppm;")]) ]), mini_line(369,12,3,0,0,0,[ str_block(0,369,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,369,12,3,0,-4,0,0,0,0,0, " xv -geometry +50+50 $(file_name).ppm;")]) ]) ])])), attr("eq=", "", 0, 1, 1, text('blue',224,83,5,0,1,135,75,15833,12,3,0,0,0,0,2,135,75,0,0,"",0,0,0,0,95,'',[ minilines(135,75,0,0,0,0,0,[ mini_line(27,12,3,0,0,0,[ str_block(0,27,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,27,12,3,0,-1,0,0,0,0,0, "eq=")]) ]), mini_line(54,12,3,0,0,0,[ str_block(0,54,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,54,12,3,0,-1,0,0,0,0,0, "\\LARGE")]) ]), mini_line(18,12,3,0,0,0,[ str_block(0,18,12,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,18,12,3,0,-3,0,0,0,0,0, "\\[")]) ]), mini_line(135,12,3,0,0,0,[ str_block(0,135,12,3,0,-3,0,0,0,[ str_seg('blue','Courier',0,80640,135,12,3,0,-3,0,0,0,0,0, " E\\,=\\,M\\,C^2")]) ]), mini_line(18,12,3,0,0,0,[ str_block(0,18,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,18,12,3,0,-4,0,0,0,0,0, "\\]")]) ]) ])])), attr("file_name=", "/tmp/TgiffAG8nM", 0, 1, 1, text('blue',225,924,1,0,1,225,15,15832,12,3,0,0,0,0,2,225,15,0,0,"",0,0,0,0,936,'',[ minilines(225,15,0,0,0,0,0,[ mini_line(225,12,3,0,0,0,[ str_block(0,225,12,3,0,0,0,0,0,[ str_seg('blue','Courier',0,80640,225,12,3,0,0,0,0,0,0,0, "file_name=/tmp/TgiffAG8nM")]) ]) ])])), attr("cleanup=", "", 0, 1, 1, text('blue',226,629,4,0,1,540,60,15831,12,3,0,0,0,0,2,540,60,0,0,"",0,0,0,0,641,'',[ minilines(540,60,0,0,0,0,0,[ mini_line(72,12,3,0,0,0,[ str_block(0,72,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,12,3,0,-1,0,0,0,0,0, "cleanup=")]) ]), mini_line(540,12,3,0,0,0,[ str_block(0,540,12,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,540,12,3,0,-2,0,0,0,0,0, " rm -f $(file_name).tex $(file_name).aux $(file_name).dvi")]) ]), mini_line(513,12,3,0,0,0,[ str_block(0,513,12,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,513,12,3,0,-2,0,0,0,0,0, " $(file_name).log $(file_name).ps $(file_name).eps")]) ]), mini_line(522,12,3,0,0,0,[ str_block(0,522,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,522,12,3,0,-1,0,0,0,0,0, " $(file_name).ppm $(file_name).xpm $(file_name).gif")]) ]) ])])), attr("exec=", "", 0, 1, 1, text('blue',225,164,14,0,1,477,210,15830,12,3,0,0,0,0,2,477,210,0,0,"",0,0,0,0,176,'',[ minilines(477,210,0,0,0,0,0,[ mini_line(45,12,3,0,0,0,[ str_block(0,45,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,45,12,3,0,-1,0,0,0,0,0, "exec=")]) ]), mini_line(378,12,3,0,0,0,[ str_block(0,378,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,378,12,3,0,-4,0,0,0,0,0, " mktemp(\"/tmp/TgifXXXXXX\",\"file_name\");")]) ]), mini_line(306,12,3,0,0,0,[ str_block(0,306,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,306,12,3,0,-4,0,0,0,0,0, " strlen(name_assigned,$(name));")]) ]), mini_line(405,12,3,0,0,0,[ str_block(0,405,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,405,12,3,0,-4,0,0,0,0,0, " if($(name_assigned)==0,assign_name,NULL);")]) ]), mini_line(306,12,3,0,0,0,[ str_block(0,306,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,306,12,3,0,-4,0,0,0,0,0, " strlen(name_assigned,$(name));")]) ]), mini_line(468,12,3,0,0,0,[ str_block(0,468,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,468,12,3,0,-4,0,0,0,0,0, " if($(name_assigned)==0,assign_random_name,NULL);")]) ]), mini_line(468,12,3,0,0,0,[ str_block(0,468,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,468,12,3,0,-4,0,0,0,0,0, " write_attr_into_file(header,\"$(file_name).tex\");")]) ]), mini_line(441,12,3,0,0,0,[ str_block(0,441,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,441,12,3,0,-4,0,0,0,0,0, " append_attr_into_file(eq,\"$(file_name).tex\");")]) ]), mini_line(477,12,3,0,0,0,[ str_block(0,477,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,477,12,3,0,-4,0,0,0,0,0, " append_attr_into_file(footer,\"$(file_name).tex\");")]) ]), mini_line(180,12,3,0,0,0,[ str_block(0,180,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,180,12,3,0,-4,0,0,0,0,0, " launch($(proc));")]) ]), mini_line(369,12,3,0,0,0,[ str_block(0,369,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,369,12,3,0,-4,0,0,0,0,0, " update_xpm_child(\"$(file_name).xpm\");")]) ]), mini_line(288,12,3,0,0,0,[ str_block(0,288,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,288,12,3,0,-4,0,0,0,0,0, " select_obj_by_name($(name));")]) ]), mini_line(162,12,3,0,0,0,[ str_block(0,162,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,162,12,3,0,-4,0,0,0,0,0, " hide_attr(eq);")]) ]), mini_line(189,12,3,0,0,0,[ str_block(0,189,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,189,12,3,0,-4,0,0,0,0,0, " launch(\"cleanup\")")]) ]) ])])), attr("header=", "", 0, 1, 1, text('#0000ff',225,696,12,0,1,270,180,15829,12,3,0,0,0,0,2,270,180,0,0,"",0,0,0,0,708,'',[ minilines(270,180,0,0,0,0,0,[ mini_line(63,12,3,0,0,0,[ str_block(0,63,12,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,12,3,0,-1,0,0,0,0,0, "header=")]) ]), mini_line(261,12,3,0,0,0,[ str_block(0,261,12,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,261,12,3,0,-4,0,0,0,0,0, "\\documentclass[12pt]{article}")]) ]), mini_line(189,12,3,0,0,0,[ str_block(0,189,12,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,189,12,3,0,-4,0,0,0,0,0, "\\usepackage{amsfonts}")]) ]), mini_line(162,12,3,0,0,0,[ str_block(0,162,12,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,162,12,3,0,-1,0,0,0,0,0, "\\oddsidemargin=0in")]) ]), mini_line(144,12,3,0,0,0,[ str_block(0,144,12,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,12,3,0,-1,0,0,0,0,0, "\\textwidth=6.5in")]) ]), mini_line(126,12,3,0,0,0,[ str_block(0,126,12,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,12,3,0,-2,0,0,0,0,0, "\\topmargin=0pt")]) ]), mini_line(153,12,3,0,0,0,[ str_block(0,153,12,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,12,3,0,-2,0,0,0,0,0, "\\textheight=609pt")]) ]), mini_line(117,12,3,0,0,0,[ str_block(0,117,12,3,0,-2,0,0,0,[ str_seg('#0000ff','Courier',0,80640,117,12,3,0,-2,0,0,0,0,0, "\\parskip=14pt")]) ]), mini_line(270,12,3,0,0,0,[ str_block(0,270,12,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,270,12,3,0,-4,0,0,0,0,0, "\\setlength{\\unitlength}{0.5cm}")]) ]), mini_line(153,12,3,0,0,0,[ str_block(0,153,12,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,153,12,3,0,-4,0,0,0,0,0, "\\pagestyle{empty}")]) ]), mini_line(144,12,3,0,0,0,[ str_block(0,144,12,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,144,12,3,0,-4,0,0,0,0,0, "\\begin{document}")]) ]), mini_line(9,12,3,0,0,0,[ str_block(0,9,12,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,12,3,0,-1,0,0,0,0,0, "%")]) ]) ])])), attr("footer=", "", 0, 1, 1, text('#ff00ff',226,872,3,0,1,126,45,15828,12,3,0,0,0,0,2,126,45,0,0,"",0,0,0,0,884,'',[ minilines(126,45,0,0,0,0,0,[ mini_line(63,12,3,0,0,0,[ str_block(0,63,12,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,63,12,3,0,-1,0,0,0,0,0, "footer=")]) ]), mini_line(9,12,3,0,0,0,[ str_block(0,9,12,3,0,-1,0,0,0,[ str_seg('#0000ff','Courier',0,80640,9,12,3,0,-1,0,0,0,0,0, "%")]) ]), mini_line(126,12,3,0,0,0,[ str_block(0,126,12,3,0,-4,0,0,0,[ str_seg('#0000ff','Courier',0,80640,126,12,3,0,-4,0,0,0,0,0, "\\end{document}")]) ]) ])])), attr("", "not_rigid", 0, 1, 1, text('blue',225,938,1,0,1,81,15,15827,12,3,0,0,0,0,2,81,15,0,0,"",0,0,0,0,950,'',[ minilines(81,15,0,0,0,0,0,[ mini_line(81,12,3,0,0,0,[ str_block(0,81,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,81,12,3,0,-1,0,0,0,0,0, "not_rigid")]) ]) ])])), attr("name=", "15933", 0, 1, 1, text('blue',225,-10,1,0,1,90,15,15826,12,3,0,0,0,0,2,90,15,0,0,"",0,0,0,0,2,'',[ minilines(90,15,0,0,0,0,0,[ mini_line(90,12,3,0,0,0,[ str_block(0,90,12,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,90,12,3,0,-2,0,0,0,0,0, "name=15933")]) ]) ])])), attr("name_assigned=", "5", 0, 1, 1, text('blue',225,6,1,0,1,135,15,15825,12,3,0,0,0,0,2,135,15,0,0,"",0,0,0,0,18,'',[ minilines(135,15,0,0,0,0,0,[ mini_line(135,12,3,0,0,0,[ str_block(0,135,12,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,135,12,3,0,-2,0,0,0,0,0, "name_assigned=5")]) ]) ])])), attr("assign_name=", "", 0, 1, 1, text('blue',225,22,2,0,1,1413,30,15824,12,3,0,0,0,0,2,1413,30,0,0,"",0,0,0,0,34,'',[ minilines(1413,30,0,0,0,0,0,[ mini_line(108,12,3,0,0,0,[ str_block(0,108,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,108,12,3,0,-1,0,0,0,0,0, "assign_name=")]) ]), mini_line(1413,12,3,0,0,0,[ str_block(0,1413,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1413,12,3,0,-4,0,0,0,0,0, " get_user_input(name,\"Please give a name to this equation object:\",\"( A random name will be assigned if an empty string is entered or <ESC> is pressed. )\");")]) ]) ])])), attr("assign_random_name=", "", 0, 1, 1, text('blue',225,54,2,0,1,171,30,15823,12,3,0,0,0,0,2,171,30,0,0,"",0,0,0,0,66,'',[ minilines(171,30,0,0,0,0,0,[ mini_line(171,12,3,0,0,0,[ str_block(0,171,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,171,12,3,0,-1,0,0,0,0,0, "assign_random_name=")]) ]), mini_line(135,12,3,0,0,0,[ str_block(0,135,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,135,12,3,0,-4,0,0,0,0,0, " new_id(name);")]) ]) ])])), attr("geometry=", "25%", 0, 1, 1, text('blue',225,386,1,0,1,108,15,15822,12,3,0,0,0,0,2,108,15,0,0,"",0,0,0,0,398,'',[ minilines(108,15,0,0,0,0,0,[ mini_line(108,12,3,0,0,0,[ str_block(0,108,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,108,12,3,0,-1,0,0,0,0,0, "geometry=25%")]) ]) ])])), attr("density=", "576", 0, 1, 1, text('blue',225,398,1,0,1,99,15,15821,12,3,0,0,0,0,2,99,15,0,0,"",0,0,0,0,410,'',[ minilines(99,15,0,0,0,0,0,[ mini_line(99,12,3,0,0,0,[ str_block(0,99,12,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,99,12,3,0,-2,0,0,0,0,0, "density=576")]) ]) ])])), attr("cmd=", "", 0, 1, 1, text('blue',224,530,5,0,1,1197,75,16095,12,3,0,0,0,0,2,1197,75,0,0,"",0,0,0,0,542,'',[ minilines(1197,75,0,0,0,0,0,[ mini_line(36,12,3,0,0,0,[ str_block(0,36,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,36,12,3,0,-1,0,0,0,0,0, "cmd=")]) ]), mini_line(108,12,3,0,0,0,[ str_block(0,108,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,108,12,3,0,-4,0,0,0,0,0, " cd /tmp;")]) ]), mini_line(459,12,3,0,0,0,[ str_block(0,459,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,459,12,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e latex $(file_name);")]) ]), mini_line(702,12,3,0,0,0,[ str_block(0,702,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,702,12,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e dvips -E -n 1 -o $(file_name).ps $(file_name);")]) ]), mini_line(1197,12,3,0,0,0,[ str_block(0,1197,12,3,0,-4,0,0,0,[ str_seg('blue','Courier',0,80640,1197,12,3,0,-4,0,0,0,0,0, " xterm -geom 80x8+300+100 -e convert -geometry $(geometry) -density $(density) -colors $(colors) $(file_name).ps $(file_name).xpm;")]) ]) ])])), attr("proc=", "cmd", 0, 1, 1, text('blue',225,422,1,0,1,72,15,15819,12,3,0,0,0,0,2,72,15,0,0,"",0,0,0,0,434,'',[ minilines(72,15,0,0,0,0,0,[ mini_line(72,12,3,0,0,0,[ str_block(0,72,12,3,0,-1,0,0,0,[ str_seg('blue','Courier',0,80640,72,12,3,0,-1,0,0,0,0,0, "proc=cmd")]) ]) ])])), attr("colors=", "16", 0, 1, 1, text('blue',225,410,1,0,1,81,15,15818,12,3,0,0,0,0,2,81,15,0,0,"",0,0,0,0,422,'',[ minilines(81,15,0,0,0,0,0,[ mini_line(81,12,3,0,0,0,[ str_block(0,81,12,3,0,-2,0,0,0,[ str_seg('blue','Courier',0,80640,81,12,3,0,-2,0,0,0,0,0, "colors=16")]) ]) ])])) ]). �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgcwdl.c�����������������������������������������������������������������������������0000644�0000764�0000764�00000176044�11602233313�014431� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgcwdl.c,v 1.21 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TGCWDL_C_ #include "tgifdefs.h" #include "tidget.h" #include "auxtext.e" #include "button.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "file.e" #include "font.e" #include "imgproc.e" #include "mainloop.e" #include "msg.e" #include "raster.e" #include "rect.e" #include "setup.e" #include "strtbl.e" #include "tdgtbase.e" #include "tdgtbmpl.e" #include "tdgtbrow.e" #include "tdgtbtn.e" #include "tdgtdraw.e" #include "tdgtsedt.e" #include "tdgtlist.e" #include "tdgtmsg.e" #include "tidget.e" #include "tgcwdl.e" #include "util.e" #include "xbitmap.e" #include "xpixmap.e" ColorWheelInfo gColorWheelInfo; typedef struct tagColorWheelDlgInfo { Window parent_win; /* should be the rootWindow */ TdgtDraw *hs_pixmap_ctl; /* user pick HS values here */ TdgtDraw *v_pixmap_ctl; /* user pick V value here */ TdgtMsg *r_msg_ctl, *g_msg_ctl, *b_msg_ctl; TdgtMsg *h_msg_ctl, *s_msg_ctl, *v_msg_ctl; TdgtMsg *cname_msg_ctl; TdgtSmplEdit *r_edit_ctl, *g_edit_ctl, *b_edit_ctl; TdgtSmplEdit *h_edit_ctl, *s_edit_ctl, *v_edit_ctl; TdgtSmplEdit *cname_edit_ctl; TdgtDraw *csmpl_ctl; /* display selected color here */ TdgtBtnRow *btn_row_ctl; int screen_w, screen_h; int base_win_w, base_win_h; int hs_x, hs_y, v_y; int r_msg_x, r_msg_y, r_msg_w, r_msg_h; int g_msg_x, g_msg_y, g_msg_w, g_msg_h; int b_msg_x, b_msg_y, b_msg_w, b_msg_h; int r_ctl_x, r_ctl_y, r_ctl_w, r_ctl_h; int g_ctl_x, g_ctl_y, g_ctl_w, g_ctl_h; int b_ctl_x, b_ctl_y, b_ctl_w, b_ctl_h; int h_msg_x, h_msg_y, h_msg_w, h_msg_h; int s_msg_x, s_msg_y, s_msg_w, s_msg_h; int v_msg_x, v_msg_y, v_msg_w, v_msg_h; int h_ctl_x, h_ctl_y, h_ctl_w, h_ctl_h; int s_ctl_x, s_ctl_y, s_ctl_w, s_ctl_h; int v_ctl_x, v_ctl_y, v_ctl_w, v_ctl_h; int btn_row_x, btn_row_y, btn_row_w, btn_row_h; char *title_str, *formatted_title_str; int def_btn_id; int hs_pixmap_x, hs_pixmap_y, v_pixmap_x, v_pixmap_y; int red_msg_x, red_msg_y, red_edit_x, red_edit_y; int green_msg_x, green_msg_y, green_edit_x, green_edit_y; int blue_msg_x, blue_msg_y, blue_edit_x, blue_edit_y; int hue_msg_x, hue_msg_y, hue_edit_x, hue_edit_y; int sat_msg_x, sat_msg_y, sat_edit_x, sat_edit_y; int val_msg_x, val_msg_y, val_edit_x, val_edit_y; int cname_msg_x, cname_msg_y, cname_edit_x, cname_edit_y; int csmpl_msg_x, csmpl_msg_y, csmpl_edit_x, csmpl_edit_y; unsigned char r, g, b; int h, s, v; /* 0 <= h,s,v <= 255 */ int pixel; char color_str[40]; TrueColorInfo tci; } ColorWheelDlgInfo; /* --------------------- Utility Functions --------------------- */ #define TDGTARG_COLORHWEEL_DPY_CLEAR 1 /* pv_cmd_userdata is NULL */ #define TDGTARG_COLORHWEEL_DPY_APPEND 2 /* pv_cmd_userdata is (ColorWheelDpyAppendInfo*) */ static void ClearAllControls(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); TidgetSendCmd(pcwdi->hs_pixmap_ctl->pti, TDGTCMD_DRAW_USER, TDGTARG_COLORHWEEL_DPY_CLEAR, pTdgtBase); TidgetSendCmd(pcwdi->v_pixmap_ctl->pti, TDGTCMD_DRAW_USER, TDGTARG_COLORHWEEL_DPY_CLEAR, pTdgtBase); TidgetSendCmd(pcwdi->csmpl_ctl->pti, TDGTCMD_DRAW_USER, TDGTARG_COLORHWEEL_DPY_CLEAR, pTdgtBase); TdgtSmplEditSetText(pcwdi->r_edit_ctl, ""); TdgtSmplEditSetText(pcwdi->g_edit_ctl, ""); TdgtSmplEditSetText(pcwdi->b_edit_ctl, ""); TdgtSmplEditSetText(pcwdi->h_edit_ctl, ""); TdgtSmplEditSetText(pcwdi->s_edit_ctl, ""); TdgtSmplEditSetText(pcwdi->v_edit_ctl, ""); TdgtSmplEditSetText(pcwdi->cname_edit_ctl, ""); } static int RGBtoPixel(pcwdi, r, g, b) ColorWheelDlgInfo *pcwdi; unsigned int r, g, b; { return (((r << pcwdi->tci.r_shift) & mainVisual->red_mask) | ((g << pcwdi->tci.g_shift) & mainVisual->green_mask) | ((b << pcwdi->tci.b_shift) & mainVisual->blue_mask)); } static void PixeltoRGB(pcwdi, pixel, pn_r, pn_g, pn_b) ColorWheelDlgInfo *pcwdi; int pixel; unsigned int *pn_r, *pn_g, *pn_b; /* 0 <= r,g,b <= 255 */ { uint32_t pix=(uint32_t)(unsigned int)pixel; unsigned int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; r = (pix & pcwdi->tci.r_mask) >> pcwdi->tci.r_shift; g = (pix & pcwdi->tci.g_mask) >> pcwdi->tci.g_shift; b = (pix & pcwdi->tci.b_mask) >> pcwdi->tci.b_shift; dr = ((double)r) / pcwdi->tci.dr_maxval * ((double)255); dg = ((double)g) / pcwdi->tci.dg_maxval * ((double)255); db = ((double)b) / pcwdi->tci.db_maxval * ((double)255); r = (dr < ((double)0)) ? 0 : ((unsigned int)dr); g = (dg < ((double)0)) ? 0 : ((unsigned int)dg); b = (db < ((double)0)) ? 0 : ((unsigned int)db); if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; *pn_r = r; *pn_g = g; *pn_b = b; } static void HStoXY(pcwdi, h, s, pn_x, pn_y) ColorWheelDlgInfo *pcwdi; int h, s, *pn_x, *pn_y; { double dval=((double)h)/((double)255)*((double)(HS_WIDTH-1)); int x=0, y=0; x = round(dval); if (x < 0) x = 0; if (x > (HS_WIDTH-1)) x = HS_WIDTH-1; dval = ((double)s)/((double)255)*((double)(HS_HEIGHT-1)); y = round(dval); if (y < 0) y = 0; if (y > (HS_HEIGHT-1)) y = HS_HEIGHT-1; *pn_x = x; *pn_y = HS_HEIGHT-y; } static void XYtoHS(pcwdi, x, y, pn_h, pn_s) ColorWheelDlgInfo *pcwdi; int x, y, *pn_h, *pn_s; { double dval=((double)x)/((double)(HS_WIDTH-1))*((double)(255)); int h=0, s=0; h = round(dval); if (h < 0) h = 0; if (h > 255) h = 255; dval = ((double)(HS_HEIGHT-y))/((double)(HS_HEIGHT-1))*((double)255); s = round(dval); if (s < 0) s = 0; if (s > 255) s = 255; *pn_h = h; *pn_s = s; } static void VtoY(pcwdi, v, pn_y) ColorWheelDlgInfo *pcwdi; int v, *pn_y; { double dval=((double)v)/((double)255)*((double)(HS_HEIGHT-1)); int y=round(dval); if (y < 0) y = 0; if (y > (HS_HEIGHT-1)) y = HS_HEIGHT-1; *pn_y = HS_HEIGHT-y; } static void YtoV(pcwdi, y, pn_v) ColorWheelDlgInfo *pcwdi; int y, *pn_v; { double dval=((double)(HS_HEIGHT-y))/((double)(HS_HEIGHT-1))*((double)255); int v=0; v = round(dval); if (v < 0) v = 0; if (v > 255) v = 255; *pn_v = v; } static int SetupVPixmap(pcwdi) ColorWheelDlgInfo *pcwdi; { int row=0; Pixmap pixmap=gColorWheelInfo.v_pixmap; double dh=(((double)pcwdi->h)/((double)255)*((double)360)); double ds=(((double)pcwdi->s)/((double)255)*((double)0x0ffff)); int hue=round(dh); if (hue < 0) hue = 0; if (hue > 360) hue = 360; if (pixmap == None) return FALSE; for (row=0; row < V_HEIGHT; row++) { int r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; uint32_t pixel=0; double val=(((double)(V_HEIGHT-1-row))/((double)(V_HEIGHT-1))); XPoint vs[2]; val *= ((double)0x0ffff); HSVtoRGB(hue, ds, val, &r, &g, &b); dr = ((double)r) / ((double)0x0ffff) * pcwdi->tci.dr_maxval; dg = ((double)g) / ((double)0x0ffff) * pcwdi->tci.dr_maxval; db = ((double)b) / ((double)0x0ffff) * pcwdi->tci.dr_maxval; r = round(dr); g = round(dg); b = round(db); if (r < 0) r = 0; if (g < 0) g = 0; if (b < 0) b = 0; if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; pixel = RGBtoPixel(pcwdi, r, g, b); XSetForeground(mainDisplay, gTidgetManager.gc, pixel); vs[0].x = 0; vs[0].y = row; vs[1].x = V_WIDTH-1; vs[1].y = row; XDrawLines(mainDisplay, pixmap, gTidgetManager.gc, vs, 2, CoordModeOrigin); } TidgetManagerResetGC(); return TRUE; } static void SetHSVFromRGB(pcwdi) ColorWheelDlgInfo *pcwdi; { unsigned int r=pcwdi->r, g=pcwdi->g, b=pcwdi->b; int h=0, s=0, v=0; double dr=(double)0, dg=(double)0, db=(double)0; double dh=(double)0, ds=(double)0, dv=(double)0; dr = ((double)r) / ((double)255) * ((double)0x0ffff); dg = ((double)g) / ((double)255) * ((double)0x0ffff); db = ((double)b) / ((double)255) * ((double)0x0ffff); r = round(dr); g = round(dg); b = round(db); RGBtoHSV(r, g, b, &h, &ds, &v); dh = ((double)h) / ((double)360) * ((double)255); ds = ds / ((double)0x0ffff) * ((double)255); dv = ((double)v) / ((double)0x0ffff) * ((double)255); h = round(dh); s = round(ds); v = round(dv); if (h < 0) h = 0; if (s < 0) s = 0; if (v < 0) v = 0; if (h > 255) h = 255; if (s > 255) s = 255; if (v > 255) v = 255; pcwdi->h = h; pcwdi->s = s; pcwdi->v = v; } static void SetRGBFromHSV(pcwdi) ColorWheelDlgInfo *pcwdi; { double dh=(((double)pcwdi->h)/((double)255)*((double)360)); double ds=(((double)pcwdi->s)/((double)255)*((double)0x0ffff)); double dv=(((double)pcwdi->v)/((double)255)*((double)0x0ffff)); double dr=(double)0, dg=(double)0, db=(double)0; int hue=round(dh), val=round(dv), r=0, g=0, b=0; if (hue < 0) hue = 0; if (hue > 360) hue = 360; if (val < 0) val = 0; if (val > 0x0ffff) val = 0x0ffff; HSVtoRGB(hue, ds, val, &r, &g, &b); dr = ((double)r) / ((double)0x0ffff) * pcwdi->tci.dr_maxval; dg = ((double)g) / ((double)0x0ffff) * pcwdi->tci.dr_maxval; db = ((double)b) / ((double)0x0ffff) * pcwdi->tci.dr_maxval; r = round(dr); g = round(dg); b = round(db); if (r < 0) r = 0; if (g < 0) g = 0; if (b < 0) b = 0; if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; pcwdi->r = r; pcwdi->g = g; pcwdi->b = b; } static void SetColorNameFromRGB(pcwdi) ColorWheelDlgInfo *pcwdi; { sprintf(pcwdi->color_str, "%02x%02x%02x", pcwdi->r, pcwdi->g, pcwdi->b); UtilStrUpper(pcwdi->color_str); } static void SetPixelFromRGB(pcwdi) ColorWheelDlgInfo *pcwdi; { pcwdi->pixel = RGBtoPixel(pcwdi, pcwdi->r, pcwdi->g, pcwdi->b); } static int SetupColorsFromCurrentColor(pcwdi) ColorWheelDlgInfo *pcwdi; { PixeltoRGB(pcwdi, colorPixels[colorIndex], &pcwdi->r, &pcwdi->g, &pcwdi->b); SetPixelFromRGB(pcwdi); SetHSVFromRGB(pcwdi); HStoXY(pcwdi, pcwdi->h, pcwdi->s, &pcwdi->hs_x, &pcwdi->hs_y); VtoY(pcwdi, pcwdi->v, &pcwdi->v_y); SetupVPixmap(pcwdi); SetColorNameFromRGB(pcwdi); return TRUE; } static int AllHexChars(buf) char *buf; { int i=0, len=strlen(buf); for (i=0; i < len; i++) { char ch=buf[i]; if ((ch >= '0' && ch <= '9') || (ch >= 'a' && ch <= 'f') || (ch >= 'A' && ch <= 'F')) { /* keep going */ } else { return FALSE; } } return TRUE; } static int SetColorInAppl(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); char *c_ptr=TdgtSmplEditGetText(pcwdi->cname_edit_ctl), color_str[40]; int new_alloc=FALSE, index=0; if (strlen(c_ptr) == 6 && AllHexChars(c_ptr)) { snprintf(color_str, sizeof(color_str), "#%s", c_ptr); } else { UtilStrCpyN(color_str, sizeof(color_str), c_ptr); } index = QuickFindColorIndex(NULL, color_str, &new_alloc, FALSE); if (index == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR), c_ptr); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } else { ChangeAllSelColor(index, TRUE); } return TRUE; } /* --------------------- Focus Stuff --------------------- */ static void ColorWheelDlgRemoveFocus(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); Window win=TidgetGetFocusWindow(); if (win == None) return; if (win == pcwdi->hs_pixmap_ctl->pti->tci.win) { TidgetDrawFocusRect(pcwdi->hs_pixmap_ctl->pti, &pcwdi->hs_pixmap_ctl->client_area); } else if (win == pcwdi->v_pixmap_ctl->pti->tci.win) { TidgetDrawFocusRect(pcwdi->v_pixmap_ctl->pti, &pcwdi->v_pixmap_ctl->client_area); } else if (win == pcwdi->r_edit_ctl->pti->tci.win) { TidgetDrawFocusRect(pcwdi->r_edit_ctl->pti, &pcwdi->r_edit_ctl->client_area); TdgtSmplEditSetFocus(pcwdi->r_edit_ctl, FALSE); } else if (win == pcwdi->g_edit_ctl->pti->tci.win) { TidgetDrawFocusRect(pcwdi->g_edit_ctl->pti, &pcwdi->g_edit_ctl->client_area); TdgtSmplEditSetFocus(pcwdi->g_edit_ctl, FALSE); } else if (win == pcwdi->b_edit_ctl->pti->tci.win) { TidgetDrawFocusRect(pcwdi->b_edit_ctl->pti, &pcwdi->b_edit_ctl->client_area); TdgtSmplEditSetFocus(pcwdi->b_edit_ctl, FALSE); } else if (win == pcwdi->h_edit_ctl->pti->tci.win) { TidgetDrawFocusRect(pcwdi->h_edit_ctl->pti, &pcwdi->h_edit_ctl->client_area); TdgtSmplEditSetFocus(pcwdi->h_edit_ctl, FALSE); } else if (win == pcwdi->s_edit_ctl->pti->tci.win) { TidgetDrawFocusRect(pcwdi->s_edit_ctl->pti, &pcwdi->s_edit_ctl->client_area); TdgtSmplEditSetFocus(pcwdi->s_edit_ctl, FALSE); } else if (win == pcwdi->v_edit_ctl->pti->tci.win) { TidgetDrawFocusRect(pcwdi->v_edit_ctl->pti, &pcwdi->v_edit_ctl->client_area); TdgtSmplEditSetFocus(pcwdi->v_edit_ctl, FALSE); } else if (win == pcwdi->cname_edit_ctl->pti->tci.win) { TidgetDrawFocusRect(pcwdi->cname_edit_ctl->pti, &pcwdi->cname_edit_ctl->client_area); TdgtSmplEditSetFocus(pcwdi->cname_edit_ctl, FALSE); } } /* --------------------- HSRedrawCallback --------------------- */ static void SetRGBControlValues(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); char caption[MAXSTRING]; sprintf(caption, "%1d", pcwdi->r); TdgtSmplEditSetText(pcwdi->r_edit_ctl, caption); sprintf(caption, "%1d", pcwdi->g); TdgtSmplEditSetText(pcwdi->g_edit_ctl, caption); sprintf(caption, "%1d", pcwdi->b); TdgtSmplEditSetText(pcwdi->b_edit_ctl, caption); } static void SetHSVControlValues(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); char caption[MAXSTRING]; sprintf(caption, "%1d", pcwdi->h); TdgtSmplEditSetText(pcwdi->h_edit_ctl, caption); sprintf(caption, "%1d", pcwdi->s); TdgtSmplEditSetText(pcwdi->s_edit_ctl, caption); sprintf(caption, "%1d", pcwdi->v); TdgtSmplEditSetText(pcwdi->v_edit_ctl, caption); } static void SetColorNameControlValue(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); TdgtSmplEditSetText(pcwdi->cname_edit_ctl, pcwdi->color_str); } static void SetupControls(pTdgtBase) TdgtBase *pTdgtBase; { SetRGBControlValues(pTdgtBase); SetHSVControlValues(pTdgtBase); SetColorNameControlValue(pTdgtBase); } static void RedrawHSPixmapControlValues(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); RedrawTidget(pcwdi->hs_pixmap_ctl->pti); } static void RedrawVPixmapControlValues(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); RedrawTidget(pcwdi->v_pixmap_ctl->pti); } static void RedrawRGBControlValues(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); RedrawTidget(pcwdi->r_edit_ctl->pti); RedrawTidget(pcwdi->g_edit_ctl->pti); RedrawTidget(pcwdi->b_edit_ctl->pti); } static void RedrawHSVControlValues(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); RedrawTidget(pcwdi->h_edit_ctl->pti); RedrawTidget(pcwdi->s_edit_ctl->pti); RedrawTidget(pcwdi->v_edit_ctl->pti); } static void RedrawColorNameControlValue(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); RedrawTidget(pcwdi->cname_edit_ctl->pti); } static void RedrawColorSampleControlValue(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); RedrawTidget(pcwdi->csmpl_ctl->pti); } #define SKIP_NONE 0x0 #define SKIP_HS_PIXMAP 0x1 #define SKIP_V_PIXMAP 0x2 static void RedrawControls(pTdgtBase, skip) TdgtBase *pTdgtBase; int skip; { if ((skip & SKIP_HS_PIXMAP) != SKIP_HS_PIXMAP) { RedrawHSPixmapControlValues(pTdgtBase); } if ((skip & SKIP_V_PIXMAP) != SKIP_V_PIXMAP) { RedrawVPixmapControlValues(pTdgtBase); } RedrawRGBControlValues(pTdgtBase); RedrawHSVControlValues(pTdgtBase); RedrawColorNameControlValue(pTdgtBase); RedrawColorSampleControlValue(pTdgtBase); } static void HSDrawSeg(dpy, win, gc, pTdgtDraw, vs) Display *dpy; Window win; GC gc; TdgtDraw *pTdgtDraw; XPoint *vs; { if (vs[0].x < 0) vs[0].x = 0; if (vs[0].x >= HS_WIDTH) vs[0].x = HS_WIDTH-1; if (vs[0].y < 0) vs[0].y = 0; if (vs[0].y >= HS_HEIGHT) vs[0].y = HS_HEIGHT-1; if (vs[1].x < 1) vs[1].x = 1; if (vs[1].x >= HS_WIDTH) vs[1].x = HS_WIDTH-1; if (vs[1].y < 1) vs[1].y = 1; if (vs[1].y >= HS_HEIGHT) vs[1].y = HS_HEIGHT-1; vs[0].x += pTdgtDraw->client_area.x; vs[0].y += pTdgtDraw->client_area.y; vs[1].x += pTdgtDraw->client_area.x; vs[1].y += pTdgtDraw->client_area.y; XDrawLines(dpy, win, gc, vs, 2, CoordModeOrigin); } static void HSRedrawCrosshair(pcwdi, pTdgtDraw) ColorWheelDlgInfo *pcwdi; TdgtDraw *pTdgtDraw; { int seg_len=6; XPoint vs[2]; XGCValues values; values.line_width = 3; XChangeGC(mainDisplay, revDefaultGC, GCLineWidth, &values); vs[0].x = pcwdi->hs_x; vs[0].y = pcwdi->hs_y - 2; vs[1].x = pcwdi->hs_x; vs[1].y = pcwdi->hs_y - 2 - seg_len; HSDrawSeg(mainDisplay, pTdgtDraw->pti->tci.win, revDefaultGC, pTdgtDraw, vs); vs[0].x = pcwdi->hs_x; vs[0].y = pcwdi->hs_y + 2; vs[1].x = pcwdi->hs_x; vs[1].y = pcwdi->hs_y + 2 + seg_len; HSDrawSeg(mainDisplay, pTdgtDraw->pti->tci.win, revDefaultGC, pTdgtDraw, vs); vs[0].x = pcwdi->hs_x - 2; vs[0].y = pcwdi->hs_y; vs[1].x = pcwdi->hs_x - 2 - seg_len; vs[1].y = pcwdi->hs_y; HSDrawSeg(mainDisplay, pTdgtDraw->pti->tci.win, revDefaultGC, pTdgtDraw, vs); vs[0].x = pcwdi->hs_x + 2; vs[0].y = pcwdi->hs_y; vs[1].x = pcwdi->hs_x + 2 + seg_len; vs[1].y = pcwdi->hs_y; HSDrawSeg(mainDisplay, pTdgtDraw->pti->tci.win, revDefaultGC, pTdgtDraw, vs); values.line_width = 1; XChangeGC(mainDisplay, revDefaultGC, GCLineWidth, &values); } static void VDrawSeg(dpy, win, gc, pTdgtDraw, vs) Display *dpy; Window win; GC gc; TdgtDraw *pTdgtDraw; XPoint *vs; { if (vs[0].x < 0) vs[0].x = 0; if (vs[0].x >= V_WIDTH) vs[0].x = V_WIDTH-1; if (vs[0].y < 0) vs[0].y = 0; if (vs[0].y >= V_HEIGHT) vs[0].y = V_HEIGHT-1; if (vs[1].x < 1) vs[1].x = 1; if (vs[1].x >= V_WIDTH) vs[1].x = V_WIDTH-1; if (vs[1].y < 1) vs[1].y = 1; if (vs[1].y >= V_HEIGHT) vs[1].y = V_HEIGHT-1; vs[0].x += pTdgtDraw->client_area.x; vs[0].y += pTdgtDraw->client_area.y; vs[1].x += pTdgtDraw->client_area.x; vs[1].y += pTdgtDraw->client_area.y; XDrawLines(dpy, win, gc, vs, 2, CoordModeOrigin); } static void VRedrawLine(pcwdi, pTdgtDraw) ColorWheelDlgInfo *pcwdi; TdgtDraw *pTdgtDraw; { XPoint vs[2]; XGCValues values; values.line_width = 3; XChangeGC(mainDisplay, revDefaultGC, GCLineWidth, &values); vs[0].x = 0; vs[0].y = pcwdi->v_y; vs[1].x = V_WIDTH; vs[1].y = pcwdi->v_y; VDrawSeg(mainDisplay, pTdgtDraw->pti->tci.win, revDefaultGC, pTdgtDraw, vs); values.line_width = 1; XChangeGC(mainDisplay, revDefaultGC, GCLineWidth, &values); } static int HSRedrawCallback(pTdgtDraw) TdgtDraw *pTdgtDraw; { TdgtBase *pTdgtBase= (TdgtBase*)(pTdgtDraw->pti->tci.parent_tidgetinfo->tidget); ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); if (pTdgtDraw == NULL) return FALSE; XCopyArea(mainDisplay, gColorWheelInfo.hs_pixmap, pTdgtDraw->pti->tci.win, gTidgetManager.gc, 0, 0, pTdgtDraw->client_area.w, pTdgtDraw->client_area.h, pTdgtDraw->client_area.x, pTdgtDraw->client_area.y); HSRedrawCrosshair(pcwdi, pTdgtDraw); if (TidgetGetFocusWindow() == pTdgtDraw->pti->tci.win) { TidgetDrawFocusRect(pTdgtDraw->pti, &pTdgtDraw->client_area); } TidgetManagerResetGC(); return TRUE; } /* --------------------- HSEvHandlerCallback() --------------------- */ static int ClickInColorWheelHSPixmap(pTdgtDraw, button_ev) TdgtDraw *pTdgtDraw; XButtonEvent *button_ev; { TdgtBase *pTdgtBase= (TdgtBase*)(pTdgtDraw->pti->tci.parent_tidgetinfo->tidget); ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); int x=button_ev->x-pTdgtDraw->client_area.x; int y=button_ev->y-pTdgtDraw->client_area.y; if (TidgetGetFocusWindow() == pTdgtDraw->pti->tci.win) { /* no need to change focus */ } else { /* change focus */ TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TidgetSetFocusWindow(pTdgtDraw->pti->tci.win); } if (x == pcwdi->hs_x && y == pcwdi->hs_y) { /* no change */ } else { if (x < 0) x = 0; if (x >= HS_WIDTH) x = HS_WIDTH-1; if (y < 0) y = 0; if (y >= HS_HEIGHT) y = HS_HEIGHT-1; pcwdi->hs_x = x; pcwdi->hs_y = y; XYtoHS(pcwdi, x, y, &pcwdi->h, &pcwdi->s); SetupVPixmap(pcwdi); SetRGBFromHSV(pcwdi); SetPixelFromRGB(pcwdi); SetColorNameFromRGB(pcwdi); SetupControls(pTdgtBase); RedrawControls(pTdgtBase, SKIP_NONE); } return FALSE; } static int HSEvHandlerCallback(pTdgtDraw, pXEv) TdgtDraw *pTdgtDraw; XEvent *pXEv; { if (pXEv->xany.window == pTdgtDraw->pti->tci.win) { if (pXEv->type == ButtonPress) { XButtonEvent *button_ev=(&(pXEv->xbutton)); return ClickInColorWheelHSPixmap(pTdgtDraw, button_ev); } } return FALSE; } /* --------------------- VRedrawCallback --------------------- */ static int VRedrawCallback(pTdgtDraw) TdgtDraw *pTdgtDraw; { TdgtBase *pTdgtBase= (TdgtBase*)(pTdgtDraw->pti->tci.parent_tidgetinfo->tidget); ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); if (pTdgtDraw == NULL) return FALSE; XCopyArea(mainDisplay, gColorWheelInfo.v_pixmap, pTdgtDraw->pti->tci.win, gTidgetManager.gc, 0, 0, pTdgtDraw->client_area.w, pTdgtDraw->client_area.h, pTdgtDraw->client_area.x, pTdgtDraw->client_area.y); VRedrawLine(pcwdi, pTdgtDraw); if (TidgetGetFocusWindow() == pTdgtDraw->pti->tci.win) { TidgetDrawFocusRect(pTdgtDraw->pti, &pTdgtDraw->client_area); } TidgetManagerResetGC(); return TRUE; } /* --------------------- VEvHandlerCallback() --------------------- */ static int ClickInColorWheelVPixmap(pTdgtDraw, button_ev) TdgtDraw *pTdgtDraw; XButtonEvent *button_ev; { TdgtBase *pTdgtBase= (TdgtBase*)(pTdgtDraw->pti->tci.parent_tidgetinfo->tidget); ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); int y=button_ev->y-pTdgtDraw->client_area.y; if (TidgetGetFocusWindow() == pTdgtDraw->pti->tci.win) { /* no need to change focus */ } else { /* change focus */ TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TidgetSetFocusWindow(pTdgtDraw->pti->tci.win); } if (y == pcwdi->v_y) { /* no change */ } else { if (y < 0) y = 0; if (y >= HS_HEIGHT) y = HS_HEIGHT-1; pcwdi->v_y = y; YtoV(pcwdi, y, &pcwdi->v); SetRGBFromHSV(pcwdi); SetPixelFromRGB(pcwdi); SetColorNameFromRGB(pcwdi); SetupControls(pTdgtBase); RedrawControls(pTdgtBase, SKIP_HS_PIXMAP); } return FALSE; } static int VEvHandlerCallback(pTdgtDraw, pXEv) TdgtDraw *pTdgtDraw; XEvent *pXEv; { if (pXEv->xany.window == pTdgtDraw->pti->tci.win) { if (pXEv->type == ButtonPress) { XButtonEvent *button_ev=(&(pXEv->xbutton)); return ClickInColorWheelVPixmap(pTdgtDraw, button_ev); } } return FALSE; } /* --------------------- CSampleRedrawCallback --------------------- */ static int CSampleRedrawCallback(pTdgtDraw) TdgtDraw *pTdgtDraw; { TdgtBase *pTdgtBase= (TdgtBase*)(pTdgtDraw->pti->tci.parent_tidgetinfo->tidget); ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); if (pTdgtDraw == NULL) return FALSE; XSetForeground(mainDisplay, gTidgetManager.gc, pcwdi->pixel); XFillRectangle(mainDisplay, pTdgtDraw->pti->tci.win, gTidgetManager.gc, pTdgtDraw->client_area.x, pTdgtDraw->client_area.y, pTdgtDraw->client_area.w, pTdgtDraw->client_area.h); TidgetManagerResetGC(); return TRUE; } /* --------------- KeyPress Event Handlers --------------- */ static int ValidateNumber(buf, max, pn_val) char *buf; int max, *pn_val; { int i=0, len=strlen(buf), ival=0;; for (i=0; i < len; i++) { if (buf[i] < '0' || buf[i] > '9') return FALSE; } if (sscanf(buf, "%d", &ival) != 1) return FALSE; if (ival >= 0 && ival <= max) { *pn_val = ival; return TRUE; } return FALSE; } static int ValidateRGB(pcwdi, pn_r, pn_g, pn_b) ColorWheelDlgInfo *pcwdi; int *pn_r, *pn_g, *pn_b; { if (!ValidateNumber(TdgtSmplEditGetText(pcwdi->r_edit_ctl), 255, pn_r)) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_GIVEN_VAL_MUST_BE_LE), "R", 255); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (!ValidateNumber(TdgtSmplEditGetText(pcwdi->g_edit_ctl), 255, pn_g)) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_GIVEN_VAL_MUST_BE_LE), "G", 255); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (!ValidateNumber(TdgtSmplEditGetText(pcwdi->b_edit_ctl), 255, pn_b)) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_GIVEN_VAL_MUST_BE_LE), "B", 255); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return TRUE; } static int ValidateHSV(pcwdi, pn_h, pn_s, pn_v) ColorWheelDlgInfo *pcwdi; int *pn_h, *pn_s, *pn_v; { if (!ValidateNumber(TdgtSmplEditGetText(pcwdi->h_edit_ctl), 255, pn_h)) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_GIVEN_VAL_MUST_BE_LE), "H", 255); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (!ValidateNumber(TdgtSmplEditGetText(pcwdi->s_edit_ctl), 255, pn_s)) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_GIVEN_VAL_MUST_BE_LE), "S", 255); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (!ValidateNumber(TdgtSmplEditGetText(pcwdi->v_edit_ctl), 255, pn_v)) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_GIVEN_VAL_MUST_BE_LE), "V", 255); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return TRUE; } static int ValidateColorName(pcwdi, pn_pixel) ColorWheelDlgInfo *pcwdi; int *pn_pixel; { XColor xcolor; char color_str[40]; char *c_ptr=TdgtSmplEditGetText(pcwdi->cname_edit_ctl); if (strlen(c_ptr) == 6 && AllHexChars(c_ptr)) { snprintf(color_str, sizeof(color_str), "#%s", c_ptr); } else { UtilStrCpyN(color_str, sizeof(color_str), c_ptr); } if (!TgifParseColor(color_str, &xcolor) || !XAllocColor(mainDisplay, mainColormap, &xcolor)) { snprintf(gszMsgBox, sizeof(gszMsgBox), TgLoadString(STID_CANNOT_PARSE_NAMED_COLOR), color_str); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } *pn_pixel = xcolor.pixel; return TRUE; } static int HandleCRorLF(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); Window win=TidgetGetFocusWindow(); int r=0, g=0, b=0, h=0, s=0, v=0, pixel=0; int rgb_changed=FALSE, hsv_changed=FALSE, color_name_changed=FALSE; if (win == None) return FALSE; if (win == pcwdi->r_edit_ctl->pti->tci.win) { if (!ValidateRGB(pcwdi, &r, &g, &b)) { return FALSE; } pcwdi->r = r; pcwdi->g = g; pcwdi->b = b; rgb_changed = TRUE; } else if (win == pcwdi->g_edit_ctl->pti->tci.win) { if (!ValidateRGB(pcwdi, &r, &g, &b)) { return FALSE; } pcwdi->r = r; pcwdi->g = g; pcwdi->b = b; rgb_changed = TRUE; } else if (win == pcwdi->b_edit_ctl->pti->tci.win) { if (!ValidateRGB(pcwdi, &r, &g, &b)) { return FALSE; } pcwdi->r = r; pcwdi->g = g; pcwdi->b = b; rgb_changed = TRUE; } else if (win == pcwdi->h_edit_ctl->pti->tci.win) { if (!ValidateHSV(pcwdi, &h, &s, &v)) { return FALSE; } pcwdi->h = h; pcwdi->s = s; pcwdi->v = v; hsv_changed = TRUE; } else if (win == pcwdi->s_edit_ctl->pti->tci.win) { if (!ValidateHSV(pcwdi, &h, &s, &v)) { return FALSE; } pcwdi->h = h; pcwdi->s = s; pcwdi->v = v; hsv_changed = TRUE; } else if (win == pcwdi->v_edit_ctl->pti->tci.win) { if (!ValidateHSV(pcwdi, &h, &s, &v)) { return FALSE; } pcwdi->h = h; pcwdi->s = s; pcwdi->v = v; hsv_changed = TRUE; } else if (win == pcwdi->cname_edit_ctl->pti->tci.win) { if (!ValidateColorName(pcwdi, &pixel)) { return FALSE; } UtilStrCpyN(pcwdi->color_str, sizeof(pcwdi->color_str), TdgtSmplEditGetText(pcwdi->cname_edit_ctl)); pcwdi->pixel = pixel; color_name_changed = TRUE; } else { return FALSE; } if (rgb_changed || hsv_changed) { if (rgb_changed) { SetPixelFromRGB(pcwdi); SetHSVFromRGB(pcwdi); } else if (hsv_changed) { SetRGBFromHSV(pcwdi); SetPixelFromRGB(pcwdi); } else { /* should not come here */ } HStoXY(pcwdi, pcwdi->h, pcwdi->s, &pcwdi->hs_x, &pcwdi->hs_y); VtoY(pcwdi, pcwdi->v, &pcwdi->v_y); SetupVPixmap(pcwdi); SetColorNameFromRGB(pcwdi); } else if (color_name_changed) { PixeltoRGB(pcwdi, pcwdi->pixel, &pcwdi->r, &pcwdi->g, &pcwdi->b); SetHSVFromRGB(pcwdi); HStoXY(pcwdi, pcwdi->h, pcwdi->s, &pcwdi->hs_x, &pcwdi->hs_y); VtoY(pcwdi, pcwdi->v, &pcwdi->v_y); SetupVPixmap(pcwdi); } SetupControls(pTdgtBase); RedrawControls(pTdgtBase, SKIP_NONE); return FALSE; } static int HandleTab(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); Window win=TidgetGetFocusWindow(); if (win == None) { TidgetSetFocusWindow(pcwdi->cname_edit_ctl->pti->tci.win); return FALSE; } if (win == pcwdi->hs_pixmap_ctl->pti->tci.win) { TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TidgetSetFocusWindow(pcwdi->v_pixmap_ctl->pti->tci.win); TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); } else if (win == pcwdi->v_pixmap_ctl->pti->tci.win) { TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TdgtSmplEditSetFocus(pcwdi->r_edit_ctl, TRUE); } else if (win == pcwdi->r_edit_ctl->pti->tci.win) { HandleCRorLF(pTdgtBase); TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TdgtSmplEditSetFocus(pcwdi->h_edit_ctl, TRUE); } else if (win == pcwdi->g_edit_ctl->pti->tci.win) { HandleCRorLF(pTdgtBase); TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TdgtSmplEditSetFocus(pcwdi->s_edit_ctl, TRUE); } else if (win == pcwdi->b_edit_ctl->pti->tci.win) { HandleCRorLF(pTdgtBase); TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TdgtSmplEditSetFocus(pcwdi->v_edit_ctl, TRUE); } else if (win == pcwdi->h_edit_ctl->pti->tci.win) { HandleCRorLF(pTdgtBase); TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TdgtSmplEditSetFocus(pcwdi->g_edit_ctl, TRUE); } else if (win == pcwdi->s_edit_ctl->pti->tci.win) { HandleCRorLF(pTdgtBase); TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TdgtSmplEditSetFocus(pcwdi->b_edit_ctl, TRUE); } else if (win == pcwdi->v_edit_ctl->pti->tci.win) { HandleCRorLF(pTdgtBase); TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TdgtSmplEditSetFocus(pcwdi->cname_edit_ctl, TRUE); } else if (win == pcwdi->cname_edit_ctl->pti->tci.win) { HandleCRorLF(pTdgtBase); TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); TidgetSetFocusWindow(pcwdi->hs_pixmap_ctl->pti->tci.win); TidgetSendCmd(pTdgtBase->pti, TDGTCMD_REMOVE_FOCUS, 0, NULL); } else { return FALSE; } return FALSE; } static int HandleBackSpace(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); Window win=TidgetGetFocusWindow(); if (win == None) return FALSE; if (win == pcwdi->r_edit_ctl->pti->tci.win) { TdgtSmplEditDelLastChar(pcwdi->r_edit_ctl); } else if (win == pcwdi->g_edit_ctl->pti->tci.win) { TdgtSmplEditDelLastChar(pcwdi->g_edit_ctl); } else if (win == pcwdi->b_edit_ctl->pti->tci.win) { TdgtSmplEditDelLastChar(pcwdi->b_edit_ctl); } else if (win == pcwdi->h_edit_ctl->pti->tci.win) { TdgtSmplEditDelLastChar(pcwdi->h_edit_ctl); } else if (win == pcwdi->s_edit_ctl->pti->tci.win) { TdgtSmplEditDelLastChar(pcwdi->s_edit_ctl); } else if (win == pcwdi->v_edit_ctl->pti->tci.win) { TdgtSmplEditDelLastChar(pcwdi->v_edit_ctl); } else if (win == pcwdi->cname_edit_ctl->pti->tci.win) { TdgtSmplEditDelLastChar(pcwdi->cname_edit_ctl); } return FALSE; } static int HandleCursorKey(pTdgtBase, key_sym) TdgtBase *pTdgtBase; KeySym key_sym; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); TdgtSmplEdit *pTdgtSmplEdit=NULL; char name[40]; Window win=TidgetGetFocusWindow(); int r=0, g=0, b=0, h=0, s=0, v=0; int dir=(-1), rgb_may_change=FALSE, hsv_may_change=FALSE; *name = '\0'; if (win == None) return FALSE; switch (key_sym) { case XK_Up: dir = SCROLL_UP; break; case XK_KP_Up: dir = SCROLL_UP; break; case XK_Down: dir = SCROLL_DOWN; break; case XK_KP_Down: dir = SCROLL_DOWN; break; case XK_Left: dir = SCROLL_LEFT; break; case XK_KP_Left: dir = SCROLL_LEFT; break; case XK_Right: dir = SCROLL_RIGHT; break; case XK_KP_Right: dir = SCROLL_RIGHT; break; default: return FALSE; } if (win == pcwdi->hs_pixmap_ctl->pti->tci.win) { int x=pcwdi->hs_x, y=pcwdi->hs_y; switch (dir) { case SCROLL_UP: y--; break; case SCROLL_DOWN: y++; break; case SCROLL_LEFT: x--; break; case SCROLL_RIGHT: x++; break; } if (x < 0) x = 0; if (x > (HS_WIDTH-1)) x = (HS_WIDTH)-1; if (y < 0) y = 0; if (y > (HS_HEIGHT-1)) y = (HS_HEIGHT)-1; if (x == pcwdi->hs_x && y == pcwdi->hs_y) { /* no change */ } else { pcwdi->hs_x = x; pcwdi->hs_y = y; XYtoHS(pcwdi, x, y, &pcwdi->h, &pcwdi->s); SetupVPixmap(pcwdi); SetRGBFromHSV(pcwdi); SetPixelFromRGB(pcwdi); SetColorNameFromRGB(pcwdi); SetupControls(pTdgtBase); RedrawControls(pTdgtBase, SKIP_NONE); } } else if (win == pcwdi->v_pixmap_ctl->pti->tci.win) { int y=pcwdi->v_y; switch (dir) { case SCROLL_UP: y--; break; case SCROLL_DOWN: y++; break; default: return FALSE; } if (y < 0) y = 0; if (y > (V_HEIGHT-1)) y = (V_HEIGHT)-1; if (y == pcwdi->v_y) { /* no change */ } else { pcwdi->v_y = y; YtoV(pcwdi, y, &pcwdi->v); SetRGBFromHSV(pcwdi); SetPixelFromRGB(pcwdi); SetColorNameFromRGB(pcwdi); SetupControls(pTdgtBase); RedrawControls(pTdgtBase, SKIP_HS_PIXMAP); } } else if (win == pcwdi->r_edit_ctl->pti->tci.win) { strcpy(name, "R"); rgb_may_change = TRUE; pTdgtSmplEdit = pcwdi->r_edit_ctl; } else if (win == pcwdi->g_edit_ctl->pti->tci.win) { strcpy(name, "G"); rgb_may_change = TRUE; pTdgtSmplEdit = pcwdi->g_edit_ctl; } else if (win == pcwdi->b_edit_ctl->pti->tci.win) { strcpy(name, "B"); rgb_may_change = TRUE; pTdgtSmplEdit = pcwdi->b_edit_ctl; } else if (win == pcwdi->h_edit_ctl->pti->tci.win) { strcpy(name, "H"); hsv_may_change = TRUE; pTdgtSmplEdit = pcwdi->h_edit_ctl; } else if (win == pcwdi->s_edit_ctl->pti->tci.win) { strcpy(name, "S"); hsv_may_change = TRUE; pTdgtSmplEdit = pcwdi->s_edit_ctl; } else if (win == pcwdi->v_edit_ctl->pti->tci.win) { strcpy(name, "V"); hsv_may_change = TRUE; pTdgtSmplEdit = pcwdi->v_edit_ctl; } else if (win == pcwdi->cname_edit_ctl->pti->tci.win) { pTdgtSmplEdit = NULL; } if (pTdgtSmplEdit != NULL) { int ival=0, new_ival=0; if (rgb_may_change) { if (!ValidateRGB(pcwdi, &r, &g, &b)) { return FALSE; } } else if (hsv_may_change) { if (!ValidateHSV(pcwdi, &h, &s, &v)) { return FALSE; } } else { /* should not get here */ } switch (dir) { case SCROLL_UP: break; case SCROLL_DOWN: break; default: return FALSE; } if (!ValidateNumber(TdgtSmplEditGetText(pTdgtSmplEdit), 255, &ival)) { /* this shouldn't happen because validated above already */ return FALSE; } new_ival = ival; switch (dir) { case SCROLL_UP: new_ival++; break; case SCROLL_DOWN: new_ival--; break; default: return FALSE; } if (new_ival < 0) new_ival = 0; if (new_ival > 255) new_ival = 255; if (ival == new_ival) { /* no change */ } else { switch (name[0]) { case 'R': pcwdi->r = new_ival; break; case 'G': pcwdi->g = new_ival; break; case 'B': pcwdi->b = new_ival; break; case 'H': pcwdi->h = new_ival; break; case 'S': pcwdi->s = new_ival; break; case 'V': pcwdi->v = new_ival; break; } if (rgb_may_change) { SetPixelFromRGB(pcwdi); SetHSVFromRGB(pcwdi); } else if (hsv_may_change) { SetRGBFromHSV(pcwdi); SetPixelFromRGB(pcwdi); } else { /* should not get here */ } HStoXY(pcwdi, pcwdi->h, pcwdi->s, &pcwdi->hs_x, &pcwdi->hs_y); VtoY(pcwdi, pcwdi->v, &pcwdi->v_y); SetupVPixmap(pcwdi); SetColorNameFromRGB(pcwdi); SetupControls(pTdgtBase); RedrawControls(pTdgtBase, SKIP_NONE); } } return FALSE; } static int HandleChar(pTdgtBase, key_sym, buf, has_ch) TdgtBase *pTdgtBase; KeySym key_sym; char *buf; int has_ch; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); Window win=TidgetGetFocusWindow(); TdgtSmplEdit *pTdgtSmplEdit=NULL; int len=0, len_limit=3; char *caption=NULL; if (win == None) return FALSE; if (win == pcwdi->r_edit_ctl->pti->tci.win) { pTdgtSmplEdit = pcwdi->r_edit_ctl; } else if (win == pcwdi->g_edit_ctl->pti->tci.win) { pTdgtSmplEdit = pcwdi->g_edit_ctl; } else if (win == pcwdi->b_edit_ctl->pti->tci.win) { pTdgtSmplEdit = pcwdi->b_edit_ctl; } else if (win == pcwdi->h_edit_ctl->pti->tci.win) { pTdgtSmplEdit = pcwdi->h_edit_ctl; } else if (win == pcwdi->s_edit_ctl->pti->tci.win) { pTdgtSmplEdit = pcwdi->s_edit_ctl; } else if (win == pcwdi->v_edit_ctl->pti->tci.win) { pTdgtSmplEdit = pcwdi->v_edit_ctl; } else if (win == pcwdi->cname_edit_ctl->pti->tci.win) { pTdgtSmplEdit = pcwdi->cname_edit_ctl; len_limit = 40; } else { return FALSE; } caption = TdgtSmplEditGetText(pTdgtSmplEdit); len = strlen(caption); if (len >= len_limit) return FALSE; if (len_limit == 3) { /* rgb or hsv */ if (*buf < '0' || *buf > '9') return FALSE; } else { /* anything goes */ } TdgtSmplEditAppendStr(pTdgtSmplEdit, buf, 1); return FALSE; } /* --------------- TdgtColorWheelDlgKeyPressEvHandlerCallback --------------- */ static XComposeStatus c_stat; static int TdgtColorWheelDlgKeyPressEvHandlerCallback(pTdgtBase, pXEv) TdgtBase *pTdgtBase; XEvent *pXEv; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); int has_ch=0; char buf[80]; KeySym key_sym=(KeySym)0; XKeyEvent *key_ev=NULL; if (pXEv->type != KeyPress) return FALSE; if (pcwdi == NULL) return FALSE; key_ev = (&(pXEv->xkey)); has_ch = XLookupString(key_ev, buf, sizeof(buf), &key_sym, &c_stat); TranslateKeys(buf, &key_sym); if (CharIsESC(key_ev, buf, key_sym, &has_ch)) { HideTdgtColorWheelDialogBox(); } else if (CharIsCRorLF(key_ev, buf, key_sym, &has_ch)) { return HandleCRorLF(pTdgtBase); } else if (CharIsTAB(key_ev, buf, key_sym, &has_ch)) { return HandleTab(pTdgtBase); } else if (CharIsCntrlSpace(key_ev, buf, key_sym, &has_ch)) { HideTdgtColorWheelDialogBox(); } else if (CharIsBS(key_ev, buf, key_sym, &has_ch, FALSE)) { return HandleBackSpace(pTdgtBase); } else if (key_sym==XK_Up || key_sym==XK_KP_Up || key_sym==XK_Down || key_sym==XK_KP_Down || key_sym==XK_Left || key_sym==XK_KP_Left || key_sym==XK_Right || key_sym==XK_KP_Right || (key_sym>'\040' && key_sym<='\177' && (key_ev->state & ControlMask) == ControlMask)) { return HandleCursorKey(pTdgtBase, key_sym); } else if (key_sym>='\040' && key_sym<='\177') { return HandleChar(pTdgtBase, key_sym, buf, has_ch); } return FALSE; } /* --------------------- ShowTdgtColorWheelDialogBox --------------------- */ void ShowTdgtColorWheelDialogBox() { TidgetInfo *pti=gColorWheelInfo.dialogbox_tidgetinfo; ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pti->userdata); TidgetManagerSetWantAllKeyPressEvents(pti, TRUE); gColorWheelInfo.mapped = TRUE; MapTidget(pti); if (pcwdi != NULL) { ClearAllControls((TdgtBase*)(pti->tidget)); SetupColorsFromCurrentColor(pcwdi); SetupControls((TdgtBase*)(pti->tidget)); } } /* --------------------- HideTdgtColorWheelDialogBox --------------------- */ void HideTdgtColorWheelDialogBox() { TidgetManagerSetWantAllKeyPressEvents(NULL, FALSE); TidgetSetHasFocus(FALSE); gColorWheelInfo.mapped = FALSE; XUnmapWindow(mainDisplay, gColorWheelInfo.dialogbox_tidgetinfo->tci.win); if (warpToWinCenter) { XWarpPointer(mainDisplay, None, drawWindow, 0, 0, 0, 0, (int)(ZOOMED_SIZE(drawWinW)>>1), (int)(ZOOMED_SIZE(drawWinH)>>1)); } } /* --------------------- CreateTdgtColorWheelDialogBox --------------------- */ static int TdgtColorWheelDlgSetEntries(pti, dsp_ptr, entries, num_entries, marked_index) TidgetInfo *pti; DspList *dsp_ptr; char **entries; int num_entries, marked_index; { return TRUE; } static int TdgtColorWheelDlgSetMsg(pti, msg) TidgetInfo *pti; char *msg; { return TRUE; } static void InitTdgtColorWheelDlgInfo(pti) TidgetInfo *pti; { ColorWheelDlgInfo *pcwdi=NULL; if (pti == NULL) return; pcwdi = (ColorWheelDlgInfo*)(pti->userdata); if (pcwdi == NULL) return; pcwdi->screen_w = DisplayWidth(mainDisplay, mainScreen); pcwdi->screen_h = DisplayHeight(mainDisplay, mainScreen); TdgtColorWheelDlgSetMsg(pti, ""); pcwdi->def_btn_id = ID_CWHEEL_BTN_OK; } typedef struct tagCreateBtnInfo { char *text; int ctl_id; } CreateBtnInfo; static CreateBtnInfo cbi[] = { { "Add to Palette", ID_CWHEEL_BTN_ADD }, { "Add and Close", ID_CWHEEL_BTN_OK }, { "Close", ID_CWHEEL_BTN_CANCEL }, { NULL, 0 } }; static int CreateColorWheelButtons(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); TdgtBtnRow *pTdgtBtnRow=pcwdi->btn_row_ctl; int i=0; for (i=0; cbi[i].text != NULL; i++) { TdgtBtn *pTdgtBtn=NULL; int btn_w=0, btn_h=0; CalcTdgtBtnDim(cbi[i].text, 8, TDGTBTN_DEF_H_PAD, TDGTBTN_DEF_V_PAD, &btn_w, &btn_h); pTdgtBtn = CreateTdgtBtn(pTdgtBtnRow->pti->tci.win, pTdgtBtnRow->pti, cbi[i].ctl_id, 0, 0, btn_w, btn_h, TDGTBTN_DEF_H_PAD, TDGTBTN_DEF_V_PAD, TGMUTYPE_TEXT, TDGTBTN_CLICK, TGBS_NORMAL, STYLE_NR, cbi[i].text, NULL); if (pTdgtBtn == NULL) { DestroyTidget(&pTdgtBase->pti); return FALSE; } if (!TdgtBtnRowAddBtn(pTdgtBtnRow, pTdgtBtn)) { DestroyTidget(&pTdgtBase->pti); return FALSE; } } return TRUE; } static void AdjustDialogBoxWidth(dpy, pTdgtBase) Display *dpy; TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); int max_w=0, bottom=0, h_pad=pTdgtBase->pti->tci.h_pad, cur_x=0, cur_y=0; int v_pad=pTdgtBase->pti->tci.v_pad, end_y=0; SimpleWinInfo *pswi=NULL; /* hue edit */ pswi = (&(pcwdi->h_edit_ctl->pti->tci.win_info)); max_w = pcwdi->hue_edit_x + pswi->w - pcwdi->hs_pixmap_x; bottom = pcwdi->btn_row_ctl->pti->tci.win_info.y + pcwdi->btn_row_ctl->pti->tci.win_info.h; cur_x = windowPadding + h_pad; cur_y = windowPadding + v_pad; /* hs_pixmap */ pswi = (&(pcwdi->hs_pixmap_ctl->pti->tci.win_info)); end_y = pswi->y+pswi->h; /* button row */ pswi = (&(pcwdi->btn_row_ctl->pti->tci.win_info)); pswi->w = max_w; TidgetMoveResize(pcwdi->btn_row_ctl->pti, pswi->x, pswi->y, pswi->w, pswi->h); pswi = (&(pTdgtBase->pti->tci.win_info)); pswi->w = max_w+(windowPadding<<1)+(h_pad<<1); pswi->h = bottom+windowPadding+v_pad; TidgetMoveResize(pTdgtBase->pti, pswi->x, pswi->y, pswi->w, pswi->h); } static void TdgtColorWheelDlgWmDeleteCallback(pTdgtBase) TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); if (pcwdi == NULL) return; HideTdgtColorWheelDialogBox(); } static int TdgtColorWheelDlgFocusCallback(pTdgtBase, cmd_type, cmd_arg, pv_cmd_userdata) TdgtBase *pTdgtBase; int cmd_type, cmd_arg; void *pv_cmd_userdata; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); if (pcwdi == NULL) return FALSE; switch (cmd_type) { case TDGTCMD_CAN_HANDLE_FOCUS_CHANGE: return TRUE; case TDGTCMD_REMOVE_FOCUS: ColorWheelDlgRemoveFocus(pTdgtBase); return TRUE; } return FALSE; } static void AdjustDialogBoxSize(dpy, pTdgtBase) Display *dpy; TdgtBase *pTdgtBase; { ColorWheelDlgInfo *pcwdi=(ColorWheelDlgInfo*)(pTdgtBase->pti->userdata); int base_win_x=0, base_win_y=0, base_win_w=0, base_win_h=0; XWMHints wmhints; XSizeHints sizehints; if (pTdgtBase == NULL) return; AdjustDialogBoxWidth(dpy, pTdgtBase); base_win_w = pTdgtBase->pti->tci.win_info.w; base_win_h = pTdgtBase->pti->tci.win_info.h; memset(&wmhints, 0, sizeof(XWMHints)); wmhints.flags = InputHint | StateHint; wmhints.input = True; wmhints.initial_state = NormalState; XSetWMHints(dpy, pTdgtBase->pti->tci.win, &wmhints); base_win_x = (base_win_w > pcwdi->screen_w) ? 0 : ((pcwdi->screen_w-base_win_w)>>1); base_win_y = (base_win_h > pcwdi->screen_h) ? 0 : ((pcwdi->screen_h-base_win_h)/3); XMoveResizeWindow(dpy, pTdgtBase->pti->tci.win, base_win_x, base_win_y, base_win_w, base_win_h); sizehints.flags = PPosition | PSize | USPosition | PMinSize | PMaxSize; sizehints.x = base_win_x; sizehints.y = base_win_y; sizehints.width = sizehints.min_width = sizehints.max_width = base_win_w; sizehints.height = sizehints.min_height = sizehints.max_height = base_win_h; #ifdef NOTR4MODE XSetNormalHints(dpy, pTdgtBase->pti->tci.win, &sizehints); #else XSetWMNormalHints(dpy, pTdgtBase->pti->tci.win, &sizehints); #endif XSetTransientForHint(dpy, pTdgtBase->pti->tci.win, mainWindow); } static int SetupHSPixmap(pcwdi) ColorWheelDlgInfo *pcwdi; { int row=0; Pixmap pixmap=gColorWheelInfo.hs_pixmap; XImage *image=NULL; if (pixmap == None) return FALSE; image = XGetImage(mainDisplay, pixmap, 0, 0, HS_WIDTH, HS_HEIGHT, AllPlanes, ZPixmap); if (image == NULL) { Msg(TgLoadString(STID_XGETIMAGE_MAY_RUN_OUT_VMEM)); return FALSE; } for (row=0; row < HS_HEIGHT; row++) { int col=0; double sat=(((double)(HS_HEIGHT-1-row))/((double)(HS_HEIGHT-1))); sat *= ((double)0x0ffff); for (col=0; col < HS_WIDTH; col++) { int hue=(col*2), r=0, g=0, b=0; double dr=(double)0, dg=(double)0, db=(double)0; uint32_t pixel=0; HSVtoRGB(hue, sat, 0x0ffff, &r, &g, &b); dr = ((double)r) / ((double)0x0ffff) * pcwdi->tci.dr_maxval; dg = ((double)g) / ((double)0x0ffff) * pcwdi->tci.dr_maxval; db = ((double)b) / ((double)0x0ffff) * pcwdi->tci.dr_maxval; r = round(dr); g = round(dg); b = round(db); if (r < 0) r = 0; if (g < 0) g = 0; if (b < 0) b = 0; if (r > 255) r = 255; if (g > 255) g = 255; if (b > 255) b = 255; pixel = RGBtoPixel(pcwdi, r, g, b); XPutPixel(image, col, row, pixel); } } XPutImage(mainDisplay, pixmap, xpmGC, image, 0, 0, 0, 0, HS_WIDTH, HS_HEIGHT); XDestroyImage(image); return TRUE; } TidgetInfo *CreateTdgtColorWheelDialogBox(dpy, parent_win) Display *dpy; Window parent_win; /* should be the rootWindow */ { int cur_x=0, cur_y=0, v_gap=20, h_pad=0, v_pad=0; int w=0, h=0, vh_padding=0, h_gap=14, end_y=0, rgbhsv_width=0; TdgtBase *pTdgtBase=NULL; ColorWheelDlgInfo *pcwdi=NULL; char caption[MAXSTRING]; TidgetSetFocusWindow(None); if (!colorDisplay || mainVisual->class != TrueColor) { sprintf(gszMsgBox, TgLoadString(STID_COLOR_WHEEL_NOT_AVAIL)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pcwdi); return NULL; } pcwdi = (ColorWheelDlgInfo*)malloc(sizeof(ColorWheelDlgInfo)); if (pcwdi == NULL) FailAllocMessage(); memset(pcwdi, 0, sizeof(ColorWheelDlgInfo)); memset(&pcwdi->tci, 0, sizeof(TrueColorInfo)); if (!SetupTrueColorInfo(&pcwdi->tci) || !SetupHSPixmap(pcwdi) || !SetupColorsFromCurrentColor(pcwdi)) { free(pcwdi); return NULL; } if (boldMsgFontSet != NULL || boldMsgFontPtr != NULL) { rgbhsv_width = BoldMsgTextWidth(boldMsgFontPtr, "9999", 4); } else if (msgFontSet != NULL || msgFontPtr != NULL) { rgbhsv_width = MsgTextWidth(msgFontPtr, "9999", 4); } else { rgbhsv_width = defaultFontWidth * 4; } h_pad = TDGTBASE_DEF_H_PAD; v_pad = TDGTBASE_DEF_V_PAD; if (msgFontSet != NULL || msgFontPtr != NULL) { vh_padding = (msgFontWidth<<1); } else { vh_padding = (defaultFontWidth<<1); } cur_x = vh_padding+windowPadding; cur_y = vh_padding+windowPadding; sprintf(caption, TgLoadString(STID_TOOL_COLOR_WHEEL), TOOL_NAME); pTdgtBase = CreateTdgtBase(parent_win, NULL, ID_CWHEEL_DIALOG, 0, 0, 100, 100, vh_padding, vh_padding, (dialogboxUse3DBorder ? TGBS_RAISED : TGBS_NORMAL), caption); if (pTdgtBase == NULL) { free(pcwdi); return NULL; } pTdgtBase->pti->userdata = pcwdi; InitTdgtColorWheelDlgInfo(pTdgtBase->pti); /* hs_pixmap */ pcwdi->hs_pixmap_x = cur_x; pcwdi->hs_pixmap_y = cur_y; pcwdi->hs_pixmap_ctl = CreateTdgtDraw(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_CWHEEL_HS_AREA, cur_x, cur_y, HS_WIDTH, HS_HEIGHT, TDGTDRAW_DEF_H_PAD, TDGTDRAW_DEF_V_PAD, TGBS_LOWRED, NULL); if (pcwdi->hs_pixmap_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } TdgtDrawSetRedrawCallback(pcwdi->hs_pixmap_ctl, HSRedrawCallback); TdgtDrawSetEvHandlerCallback(pcwdi->hs_pixmap_ctl, HSEvHandlerCallback); cur_x += pcwdi->hs_pixmap_ctl->pti->tci.win_info.w + h_gap; end_y = cur_y + pcwdi->hs_pixmap_ctl->pti->tci.win_info.h - windowPadding; /* v_pixmap */ pcwdi->v_pixmap_x = cur_x; pcwdi->v_pixmap_y = cur_y; pcwdi->v_pixmap_ctl = CreateTdgtDraw(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_CWHEEL_V_AREA, cur_x, cur_y, V_WIDTH, V_HEIGHT, TDGTDRAW_DEF_H_PAD, TDGTDRAW_DEF_V_PAD, TGBS_LOWRED, NULL); if (pcwdi->v_pixmap_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } TdgtDrawSetRedrawCallback(pcwdi->v_pixmap_ctl, VRedrawCallback); TdgtDrawSetEvHandlerCallback(pcwdi->v_pixmap_ctl, VEvHandlerCallback); cur_x += pcwdi->v_pixmap_ctl->pti->tci.win_info.w + h_gap; /* row 1 */ /* red msg */ pcwdi->red_msg_x = cur_x; pcwdi->red_msg_y = cur_y; pcwdi->r_msg_ctl = CreateTdgtMsg(pTdgtBase->pti->tci.win, pTdgtBase->pti, INVALID, cur_x, cur_y, TDGTMSG_DEF_H_PAD, TDGTMSG_DEF_V_PAD, TGBS_NORMAL, "R:", JUST_L); if (pcwdi->r_msg_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x += pcwdi->r_msg_ctl->pti->tci.win_info.w; /* red edit */ pcwdi->red_edit_x = cur_x; pcwdi->red_edit_y = cur_y; pcwdi->r_edit_ctl = CreateTdgtSmplEdit(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_CWHEEL_EDIT_R, cur_x, cur_y, rgbhsv_width, TDGTSEDT_DEF_H_PAD, TDGTSEDT_DEF_V_PAD, "", STYLE_NR, INVALID); if (pcwdi->r_edit_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x += pcwdi->r_edit_ctl->pti->tci.win_info.w + 4; /* hue msg */ pcwdi->hue_msg_x = cur_x; pcwdi->hue_msg_y = cur_y; pcwdi->h_msg_ctl = CreateTdgtMsg(pTdgtBase->pti->tci.win, pTdgtBase->pti, INVALID, cur_x, cur_y, TDGTMSG_DEF_H_PAD, TDGTMSG_DEF_V_PAD, TGBS_NORMAL, "H:", JUST_L); if (pcwdi->h_msg_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x += pcwdi->h_msg_ctl->pti->tci.win_info.w; /* hue edit */ pcwdi->hue_edit_x = cur_x; pcwdi->hue_edit_y = cur_y; pcwdi->h_edit_ctl = CreateTdgtSmplEdit(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_CWHEEL_EDIT_H, cur_x, cur_y, rgbhsv_width, TDGTSEDT_DEF_H_PAD, TDGTSEDT_DEF_V_PAD, "", STYLE_NR, INVALID); if (pcwdi->h_edit_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x = pcwdi->red_msg_x; cur_y += pcwdi->h_edit_ctl->pti->tci.win_info.h + 4; /* row 2 */ /* green msg */ pcwdi->green_msg_x = cur_x; pcwdi->green_msg_y = cur_y; pcwdi->g_msg_ctl = CreateTdgtMsg(pTdgtBase->pti->tci.win, pTdgtBase->pti, INVALID, cur_x, cur_y, TDGTMSG_DEF_H_PAD, TDGTMSG_DEF_V_PAD, TGBS_NORMAL, "G:", JUST_L); if (pcwdi->g_msg_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x = pcwdi->red_edit_x; /* green edit */ pcwdi->green_edit_x = cur_x; pcwdi->green_edit_y = cur_y; pcwdi->g_edit_ctl = CreateTdgtSmplEdit(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_CWHEEL_EDIT_G, cur_x, cur_y, rgbhsv_width, TDGTSEDT_DEF_H_PAD, TDGTSEDT_DEF_V_PAD, "", STYLE_NR, INVALID); if (pcwdi->g_edit_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x = pcwdi->hue_msg_x; /* sat msg */ pcwdi->sat_msg_x = cur_x; pcwdi->sat_msg_y = cur_y; pcwdi->s_msg_ctl = CreateTdgtMsg(pTdgtBase->pti->tci.win, pTdgtBase->pti, INVALID, cur_x, cur_y, TDGTMSG_DEF_H_PAD, TDGTMSG_DEF_V_PAD, TGBS_NORMAL, "S:", JUST_L); if (pcwdi->s_msg_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x = pcwdi->hue_edit_x; /* sat edit */ pcwdi->sat_edit_x = cur_x; pcwdi->sat_edit_y = cur_y; pcwdi->s_edit_ctl = CreateTdgtSmplEdit(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_CWHEEL_EDIT_S, cur_x, cur_y, rgbhsv_width, TDGTSEDT_DEF_H_PAD, TDGTSEDT_DEF_V_PAD, "", STYLE_NR, INVALID); if (pcwdi->s_edit_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x = pcwdi->red_msg_x; cur_y += pcwdi->s_edit_ctl->pti->tci.win_info.h + 4; /* row 3 */ /* blue msg */ pcwdi->blue_msg_x = cur_x; pcwdi->blue_msg_y = cur_y; pcwdi->b_msg_ctl = CreateTdgtMsg(pTdgtBase->pti->tci.win, pTdgtBase->pti, INVALID, cur_x, cur_y, TDGTMSG_DEF_H_PAD, TDGTMSG_DEF_V_PAD, TGBS_NORMAL, "B:", JUST_L); if (pcwdi->b_msg_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x += pcwdi->b_msg_ctl->pti->tci.win_info.w; /* blue edit */ pcwdi->blue_edit_x = cur_x; pcwdi->blue_edit_y = cur_y; pcwdi->b_edit_ctl = CreateTdgtSmplEdit(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_CWHEEL_EDIT_B, cur_x, cur_y, rgbhsv_width, TDGTSEDT_DEF_H_PAD, TDGTSEDT_DEF_V_PAD, "", STYLE_NR, INVALID); if (pcwdi->b_edit_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x += pcwdi->b_edit_ctl->pti->tci.win_info.w + 4; /* val msg */ pcwdi->val_msg_x = cur_x; pcwdi->val_msg_y = cur_y; pcwdi->v_msg_ctl = CreateTdgtMsg(pTdgtBase->pti->tci.win, pTdgtBase->pti, INVALID, cur_x, cur_y, TDGTMSG_DEF_H_PAD, TDGTMSG_DEF_V_PAD, TGBS_NORMAL, "V:", JUST_L); if (pcwdi->v_msg_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x += pcwdi->v_msg_ctl->pti->tci.win_info.w; /* val edit */ pcwdi->val_edit_x = cur_x; pcwdi->val_edit_y = cur_y; pcwdi->v_edit_ctl = CreateTdgtSmplEdit(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_CWHEEL_EDIT_V, cur_x, cur_y, rgbhsv_width, TDGTSEDT_DEF_H_PAD, TDGTSEDT_DEF_V_PAD, "", STYLE_NR, INVALID); if (pcwdi->v_edit_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x = pcwdi->red_msg_x; cur_y += pcwdi->v_edit_ctl->pti->tci.win_info.h + 4; /* row 4 */ /* cname msg */ pcwdi->cname_msg_x = cur_x; pcwdi->cname_msg_y = cur_y; pcwdi->cname_msg_ctl = CreateTdgtMsg(pTdgtBase->pti->tci.win, pTdgtBase->pti, INVALID, cur_x, cur_y, TDGTMSG_DEF_H_PAD, TDGTMSG_DEF_V_PAD, TGBS_NORMAL, "Name:", JUST_L); if (pcwdi->cname_msg_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x += pcwdi->cname_msg_ctl->pti->tci.win_info.w; /* cname edit */ pcwdi->cname_edit_x = cur_x; pcwdi->cname_edit_y = cur_y; w = pcwdi->val_edit_x + pcwdi->v_edit_ctl->pti->tci.win_info.w - cur_x - (TDGTSEDT_DEF_H_PAD<<1) - (windowPadding<<1); pcwdi->cname_edit_ctl = CreateTdgtSmplEdit(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_CWHEEL_EDIT_B, cur_x, cur_y, w, TDGTSEDT_DEF_H_PAD, TDGTSEDT_DEF_V_PAD, "", STYLE_NR, INVALID); if (pcwdi->cname_edit_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } cur_x = pcwdi->red_msg_x; cur_y += pcwdi->cname_edit_ctl->pti->tci.win_info.h + 4; /* row 5 */ /* csmpl_ctl */ pcwdi->csmpl_edit_x = cur_x; pcwdi->csmpl_edit_y = cur_y; w = pcwdi->val_edit_x + pcwdi->v_edit_ctl->pti->tci.win_info.w - cur_x - (TDGTSEDT_DEF_H_PAD<<1) - (windowPadding<<1); h = end_y - cur_y - (TDGTSEDT_DEF_V_PAD<<1) - (windowPadding<<1); pcwdi->csmpl_ctl = CreateTdgtDraw(pTdgtBase->pti->tci.win, pTdgtBase->pti, ID_CWHEEL_HS_AREA, cur_x, cur_y, w, h, TDGTDRAW_DEF_H_PAD, TDGTDRAW_DEF_V_PAD, TGBS_LOWRED, NULL); if (pcwdi->hs_pixmap_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } TdgtDrawSetRedrawCallback(pcwdi->csmpl_ctl, CSampleRedrawCallback); /* buttons */ cur_x = vh_padding+windowPadding; cur_y = end_y + v_gap; pcwdi->btn_row_ctl = CreateTdgtBtnRow(pTdgtBase->pti->tci.win, pTdgtBase->pti, INVALID, cur_x, cur_y, TDGTBROW_DEF_H_PAD, TDGTBROW_DEF_V_PAD, TGBS_NORMAL, defaultFontWidth, JUST_C); if (pcwdi->btn_row_ctl == NULL) { DestroyTidget(&pTdgtBase->pti); return NULL; } if (!CreateColorWheelButtons(pTdgtBase)) { DestroyTidget(&pTdgtBase->pti); return NULL; } TdgtColorWheelDlgSetEntries(pTdgtBase->pti, NULL, NULL, 0, INVALID); /* * Specify that the base tidget will handle all the KeyPress events * in all its children tidgets. */ TdgtBaseWillHandleKeyPressEvents(pTdgtBase, TdgtColorWheelDlgKeyPressEvHandlerCallback); /* * Specify that the base tidget will handle all the KeyPress events * in all its children tidgets. */ TdgtBaseSetWmDeleteCallback(pTdgtBase, TdgtColorWheelDlgWmDeleteCallback); /* * Specify a callback function to answer some focus related questions. */ TdgtBaseSetFocusCallback(pTdgtBase, TdgtColorWheelDlgFocusCallback); AdjustDialogBoxSize(dpy, pTdgtBase); TidgetSetFocusWindow(pcwdi->cname_edit_ctl->pti->tci.win); return pTdgtBase->pti; } /* --------------------- DestroyTdgtColorWheelDialogBox --------------------- */ void DestroyTdgtColorWheelDialogBox(dpy, pti) Display *dpy; TidgetInfo *pti; { ColorWheelDlgInfo *pcwdi=NULL; if (pti == NULL) return; pcwdi = (ColorWheelDlgInfo*)(pti->userdata); if (pcwdi != NULL) { free(pcwdi); } DestroyTidget(&pti); } /* --------------------- TdgtColorWheelDlgLoop --------------------- */ static int HandleTdgtNotifyEvent(pTdgtBase, pTdgtNtfy) TdgtBase *pTdgtBase; TdgtNtfy *pTdgtNtfy; { switch (pTdgtNtfy->ctl_id) { case ID_CWHEEL_BTN_ADD: SetColorInAppl(pTdgtBase); break; case ID_CWHEEL_BTN_OK: if (SetColorInAppl(pTdgtBase)) { HideTdgtColorWheelDialogBox(); } break; case ID_CWHEEL_BTN_CANCEL: HideTdgtColorWheelDialogBox(); break; } return FALSE; } int TdgtColorWheelDlgLoop(pti) TidgetInfo *pti; { TdgtBase *pTdgtBase=(TdgtBase*)(pti->tidget); int which_btn_clicked=INVALID, first_time_config=TRUE; if (pTdgtBase == NULL) return which_btn_clicked; while (gColorWheelInfo.mapped) { XEvent xev; TdgtNtfy tdgt_notify; TidgetInfo *handling_pti=NULL; XNextEvent(mainDisplay, &xev); if (xev.type == MotionNotify) { /* do nothing */ } else if (xev.type == ConfigureNotify && xev.xany.window == pti->tci.win) { if (first_time_config) { first_time_config = FALSE; if (warpToWinCenter) { /* does not work because the window has been moved */ XWarpPointer(mainDisplay, None, pti->tci.win, 0, 0, 0, 0, (pti->tci.win_info.w>>1), (pti->tci.win_info.h>>1)); } } } else if (xev.type == Expose) { ExposeEventHandler(&xev, FALSE); } else if (xev.type == ConfigureNotify && xev.xany.window==mainWindow) { Reconfigure(FALSE); } else if (xev.type == KeyPress) { TidgetManagerHandleAllKeyPressEvent(&xev); } else if (IsTdgtNotifyEvent(pti, &xev, &tdgt_notify)) { HandleTdgtNotifyEvent(pTdgtBase, &tdgt_notify); } else if (IsTidgetEvent(pti, &xev, &handling_pti)) { TidgetEventHandler(pti, &xev, handling_pti); } else { /* anything else? */ } } return which_btn_clicked; } /* --------------------- Init & Clean Up --------------------- */ int InitTdgtColorWheelDlg() { return TRUE; } void CleanUpTdgtColorWheelDlg() { } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/menuinfo.e���������������������������������������������������������������������������0000644�0000764�0000764�00000005606�11602233312�014761� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/menuinfo.e,v 1.12 2011/05/16 16:21:58 william Exp $ */ #ifndef _MENUINFO_E_ #define _MENUINFO_E_ extern TgMenuInfo colorMenuInfo; extern TgMenuInfo modeMenuInfo; extern TgMenuInfo fillMenuInfo; extern TgMenuInfo penMenuInfo; extern TgMenuInfo lineWidthMenuInfo; extern TgMenuInfo lineStyleMenuInfo; extern TgMenuInfo lineTypeMenuInfo; extern TgMenuInfo lineDashMenuInfo; extern TgMenuInfo horiAlignMenuInfo; extern TgMenuInfo vertAlignMenuInfo; extern TgMenuInfo moveModeMenuInfo; extern TgMenuInfo stretchableTextModeMenuInfo; extern TgMenuInfo shapeMenuInfo; extern TgMenuInfo pageLayoutMenuInfo; extern TgMenuInfo transPatModeMenuInfo; extern TgMenuInfo pageStyleMenuInfo; extern TgMenuInfo fontMenuInfo; extern TgMenuInfo fontStyleMenuInfo; extern TgMenuInfo fontSizeMenuInfo; extern TgMenuInfo stackedPageMenuInfo; extern TgMenuInfo tiledPageMenuInfo; extern TgMenuInfo pageMenuInfo; extern TgMenuInfo imageProcMenuInfo; extern TgMenuInfo exportFormatMenuInfo; extern TgMenuInfo fileMenuInfo; extern TgMenuInfo polyMenuInfo; extern TgMenuInfo editMenuInfo; extern TgMenuInfo autoRotatePivotMenuInfo; extern TgMenuInfo arrangeMenuInfo; extern TgMenuInfo slideShowModeMenuInfo; extern TgMenuInfo layoutMenuInfo; extern TgMenuInfo propertiesMenuInfo; extern TgMenuInfo navigateMenuInfo; extern TgMenuInfo specialMenuInfo; extern TgMenuInfo helpMenuInfo; extern TgMenuInfo editAttrInEditorMenuInfo; extern TgMenuInfo editAttrGroupInEditorMenuInfo; extern TgMenuInfo getPropertyMenuInfo; extern TgMenuInfo peekDimensionMenuInfo; extern TgMenuInfo baseContextMenuInfo; extern TgMenuInfo editTextContextMenuInfo; extern TgMenuInfo gridMenuInfo; extern TgMenuInfo mainMenuInfo; extern TgMenuInfo minimalMenubarMenuInfo; extern TgMenuInfo maximalMenubarMenuInfo; #ifdef _INCLUDE_FROM_MENUINFO_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_MENUINFO_C_*/ /* * extern function declarations */ #ifdef _INCLUDE_FROM_MENUINFO_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_MENUINFO_C_*/ #endif /*_MENUINFO_E_*/ ��������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/hash.c�������������������������������������������������������������������������������0000644�0000764�0000764�00000016571�11602233311�014064� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/hash.c,v 1.7 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_HASH_C_ #include "tgifdefs.h" #include "hash.e" #include "msg.e" #include "util.e" #define INT_HASH_DATA 0 #define STR_HASH_DATA 1 typedef struct tagHashData { char *psz_key; int key_sz; int type; union { char *sval; int ival; } detail; } HashData; /* ------------------ Utility Functions ------------------ */ static void FreeHashData(phd) HashData *phd; { switch (phd->type) { case INT_HASH_DATA: break; case STR_HASH_DATA: UtilFree(phd->detail.sval); break; } UtilFree(phd->psz_key); free(phd); } static HashData *NewIntHashData(psz_key, key_sz, ival) char *psz_key; int key_sz, ival; { HashData *phd=(HashData*)malloc(sizeof(HashData)); if (phd == NULL) FailAllocMessage(); memset(phd, 0, sizeof(HashData)); phd->psz_key = (char*)malloc(key_sz); if (phd->psz_key == NULL) FailAllocMessage(); memcpy(phd->psz_key, psz_key, key_sz); phd->key_sz = key_sz; phd->type = INT_HASH_DATA; phd->detail.ival = ival; return phd; } static HashData *NewStrHashData(psz_key, key_sz, psz_value) char *psz_key, *psz_value; int key_sz; { HashData *phd=(HashData*)malloc(sizeof(HashData)); if (phd == NULL) FailAllocMessage(); memset(phd, 0, sizeof(HashData)); phd->psz_key = (char*)malloc(key_sz); if (phd->psz_key == NULL) FailAllocMessage(); memcpy(phd->psz_key, psz_key, key_sz); phd->type = STR_HASH_DATA; phd->detail.sval = UtilStrDup(psz_value); if (phd->detail.sval == NULL) FailAllocMessage(); return phd; } static unsigned int GetBucket(p_hash, psz_key, key_sz) TgHash *p_hash; char *psz_key; int key_sz; { unsigned int ival=0, ival2=0, bucket=0; switch (key_sz) { case 0: return FALSE; case 1: ival = (unsigned int)(unsigned char)*psz_key; break; case 2: ival = ((((unsigned int)(unsigned char)psz_key[0]) & 0x0ff) << 8) | (((unsigned int)(unsigned char)psz_key[1]) & 0x0ff); break; case 3: ival = ((((unsigned int)(unsigned char)psz_key[0]) & 0x0ff) << 16) | ((((unsigned int)(unsigned char)psz_key[1]) & 0x0ff) << 8) | (((unsigned int)(unsigned char)psz_key[2]) & 0x0ff); break; default: for ( ; key_sz >= 4; key_sz-=4) { ival2 = ((((unsigned int)(unsigned char)psz_key[0]) & 0x0ff) << 24) | ((((unsigned int)(unsigned char)psz_key[1]) & 0x0ff) << 16) | ((((unsigned int)(unsigned char)psz_key[2]) & 0x0ff) << 8) | (((unsigned int)(unsigned char)psz_key[3]) & 0x0ff); ival = (ival>>1) ^ ival2; psz_key = &psz_key[4]; } switch (key_sz) { case 0: break; case 1: ival2 = ((((unsigned int)(unsigned char)psz_key[0]) & 0x0ff) << 24); ival = (ival>>1) ^ ival2; break; case 2: ival2 = ((((unsigned int)(unsigned char)psz_key[0]) & 0x0ff) << 24) | ((((unsigned int)(unsigned char)psz_key[1]) & 0x0ff) << 16); ival = (ival>>1) ^ ival2; break; case 3: ival2 = ((((unsigned int)(unsigned char)psz_key[0]) & 0x0ff) << 24) | ((((unsigned int)(unsigned char)psz_key[1]) & 0x0ff) << 16) | ((((unsigned int)(unsigned char)psz_key[2]) & 0x0ff) << 8); ival = (ival>>1) ^ ival2; break; } break; } bucket = ival % p_hash->num_buckets; return bucket; } /* ------------------ CleanUpHash() ------------------ */ void CleanUpHash(p_hash) TgHash *p_hash; { int i=0; for (i=0; i < p_hash->num_buckets; i++) { CVList *p_list=(&p_hash->buckets[i]); if (ListLength(p_list) > 0) { CVListElem *e=NULL; for (e=ListFirst(p_list); e != NULL; e=ListNext(p_list,e)) { HashData *phd=(HashData*)(e->obj); FreeHashData(phd); } ListUnlinkAll(p_list); } } free(p_hash->buckets); } /* ------------------ InitHash() ------------------ */ int InitHash(p_hash, which) TgHash *p_hash; int which; { int i=0; switch (which) { case TG_HASH_SIZE_SMALL: break; case TG_HASH_SIZE_MEDIUM: break; case TG_HASH_SIZE_LARGE: break; default: return FALSE; } p_hash->num_buckets = which; p_hash->buckets = (CVList*)malloc(which*sizeof(CVList)); if (p_hash->buckets == NULL) FailAllocMessage(); memset(p_hash->buckets, 0, which*sizeof(CVList)); for (i=0; i < which; i++) { CVListInit(&p_hash->buckets[i]); } return TRUE; } /* ------------------ HashStoreInt() ------------------ */ int HashStoreInt(p_hash, psz_key, key_sz, ival) TgHash *p_hash; char *psz_key; int key_sz, ival; { unsigned int bucket=GetBucket(p_hash, psz_key, key_sz); CVList *list=(&p_hash->buckets[bucket]); HashData *phd=NewIntHashData(psz_key, key_sz, ival); ListPrepend(list, phd); return TRUE; } /* ------------------ HashStoreStr() ------------------ */ int HashStoreStr(p_hash, psz_key, key_sz, psz_val) TgHash *p_hash; char *psz_key, *psz_val; int key_sz; { unsigned int bucket=GetBucket(p_hash, psz_key, key_sz); CVList *list=(&p_hash->buckets[bucket]); HashData *phd=NewStrHashData(psz_key, key_sz, psz_val); ListPrepend(list, phd); return TRUE; } /* ------------------ HashLookUpInt() ------------------ */ int HashLookUpInt(p_hash, psz_key, key_sz, pn_value_return) TgHash *p_hash; char *psz_key; int key_sz, *pn_value_return; { unsigned int bucket=GetBucket(p_hash, psz_key, key_sz); CVList *list=(&p_hash->buckets[bucket]); CVListElem *e=NULL; for (e=ListFirst(list); e != NULL; e=ListNext(list,e)) { HashData *phd=(HashData*)(e->obj); if (phd->key_sz == key_sz && memcmp(phd->psz_key, psz_key, key_sz) == 0) { if (phd->type == INT_HASH_DATA) { *pn_value_return = phd->detail.ival; return TRUE; } return FALSE; } } return FALSE; } /* ------------------ HashLookUpStr() ------------------ */ char *HashLookUpStr(p_hash, psz_key, key_sz) TgHash *p_hash; char *psz_key; int key_sz; { unsigned int bucket=GetBucket(p_hash, psz_key, key_sz); CVList *list=(&p_hash->buckets[bucket]); CVListElem *e=NULL; for (e=ListFirst(list); e != NULL; e=ListNext(list,e)) { HashData *phd=(HashData*)(e->obj); if (phd->key_sz == key_sz && memcmp(phd->psz_key, psz_key, key_sz) == 0) { if (phd->type == STR_HASH_DATA) { return phd->detail.sval; } return NULL; } } return NULL; } ���������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/inmethod.c���������������������������������������������������������������������������0000644�0000764�0000764�00000064036�11602233311�014747� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/inmethod.c,v 1.14 2011/06/14 02:32:18 william Exp $ */ #define _INCLUDE_FROM_INMETHOD_C_ #include "tgifdefs.h" #ifndef _NO_XCIN #include "cli_xcin.e" #endif /* ~_NO_XCIN */ #ifndef _NO_CHINPUT #include "chinput.e" #endif /* ~_NO_CHINPUT */ #ifndef _NO_KINPUT #include "convkinput.e" #endif /* ~_NO_KINPUT */ #ifndef _NO_XIM #include "convxim.e" #endif /* ~_NO_XIM */ #ifndef _NO_TGTWB5 #include "tgtwb5.e" #endif /* ~_NO_TGTWB5 */ #include "dialog.e" #include "inmethod.e" #include "msg.e" #include "util.e" #include "setup.e" #include "strtbl.e" #include "tidget.e" #ifndef _NO_DL_SUPPORT #define CLOSE_DL(handle) dlclose(handle) #define OPEN_DL(path,flag) dlopen((path),(flag)) #define GET_DL_SYM(handle,symbol) dlsym((handle),(symbol)) #ifndef RTLD_NOW #define OPEN_DL_MODE 1 #else /* RTLD_NOW */ #define OPEN_DL_MODE (RTLD_NOW|RTLD_GLOBAL) #endif /* ~RTLD_NOW */ #else /* _NO_DL_SUPPORT */ #define CLOSE_DL(handle) #define OPEN_DL(path,flag) NULL #define GET_DL_SYM(handle,symbol) NULL #define OPEN_DL_MODE 0 #endif /* ~_NO_DL_SUPPORT */ int gnInputMethod=TGIM_NONE; /* one of TGIM_* */ int gnOverTheSpot=FALSE; int cmdLineHasInputMethod=FALSE; int cmdLineDoubleByteInputMethod=FALSE; char cmdLineInputMethod[MAXSTRING]; static int gnInputMethodIndex=INVALID; static int gnSingleOrDoubleByteInputMethod=0; typedef void (CleanUpFunc)ARGS_DECL((Display *dpy, Window win)); typedef int (InitFunc)ARGS_DECL((Display *dpy, Window win, char *arg)); typedef int (FocusInFunc)ARGS_DECL((Display *dpy, Window win)); typedef int (FocusOutFunc)ARGS_DECL((Display *dpy, Window win)); typedef int (SendKeyFunc)ARGS_DECL((Display *dpy, Window win, XKeyEvent *key_ev, char *buf)); typedef int (ConvPropertyFunc)ARGS_DECL((Display *dpy, Window win, XPropertyEvent *prop_ev, char **ppsz_buf)); typedef int (ExpectCMFunc)ARGS_DECL((Display *dpy, Window win)); typedef int (HandleCMFunc)ARGS_DECL((Display *dpy, Window win, XClientMessageEvent *cm_ev, XKeyEvent *key_ev, char *buf)); typedef int (ActivateOnCntrlSpaceFunc)ARGS_DECL((Display *dpy, Window win)); typedef int (HandleCntrlSpaceFunc)ARGS_DECL((Display *dpy, Window win)); typedef int (DeactivateOnCreateTextFunc)ARGS_DECL((Display *dpy, Window win)); typedef int (HandleCreateTextFunc)ARGS_DECL((Display *dpy, Window win)); typedef int (TellCursorPosFunc)ARGS_DECL((Display *dpy, Window win, int cur_x, int cur_y)); typedef int (ExpectNextEventFunc)ARGS_DECL((Display *dpy, Window win)); typedef int (HandleNextEventFunc)ARGS_DECL((Display *dpy, Window win, XEvent *ev)); typedef int (HandleNewCurTextFunc)ARGS_DECL((Display *dpy, Window win)); typedef int (ExpectLookupStringFunc)ARGS_DECL((Display *dpy, Window win)); typedef int (HandleLookupStringFunc)ARGS_DECL((Display *dpy, Window win, XKeyEvent *key_ev, char *psz_buf, int buf_size, KeySym *p_key_sym, int *pn_has_ch)); typedef struct tagIMInfo { char *pszName; int nInputMethod; int nSingleDouble; CleanUpFunc *pCleanUpFunc; InitFunc *pInitFunc; FocusInFunc *pFocusInFunc; FocusOutFunc *pFocusOutFunc; SendKeyFunc *pSendKeyFunc; ConvPropertyFunc *pConvPropertyFunc; ExpectCMFunc *pExpectCMFunc; HandleCMFunc *pHandleCMFunc; ActivateOnCntrlSpaceFunc *pActivateOnCntrlSpaceFunc; HandleCntrlSpaceFunc *pHandleCntrlSpaceFunc; DeactivateOnCreateTextFunc *pDeactivateOnCreateTextFunc; HandleCreateTextFunc *pHandleCreateTextFunc; TellCursorPosFunc *pTellCursorPosFunc; ExpectNextEventFunc *pExpectNextEventFunc; HandleNextEventFunc *pHandleNextEventFunc; HandleNewCurTextFunc *pHandleNewCurTextFunc; ExpectLookupStringFunc *pExpectLookupStringFunc; HandleLookupStringFunc *pHandleLookupStringFunc; } IMInfo; static IMInfo *gpIMInfo=NULL; /* --------------------- xcin Routines --------------------- */ #ifndef _NO_XCIN static int XcinInit(dpy, win, arg) Display *dpy; Window win; char *arg; { return TRUE; } static int XcinFocusIn(dpy, win) Display *dpy; Window win; { Tg_send_FocusIn(dpy, win); return TRUE; } static int XcinFocusOut(dpy, win) Display *dpy; Window win; { Tg_send_FocusOut(dpy, win); return TRUE; } static int XcinSendKey(dpy, win, key_ev, buf) Display *dpy; Window win; XKeyEvent *key_ev; char *buf; { return Tg_send_key(dpy, win, key_ev, buf); } static int XcinExpectCM(dpy, win) Display *dpy; Window win; { return FALSE; } #endif /* ~_NO_XCIN */ /* --------------------- chinput Routines --------------------- */ #ifndef _NO_CHINPUT static int ChinputInit(dpy, win, arg) Display *dpy; Window win; char *arg; { return (Tg_HZclientInit(dpy)==0); } static int ChinputFocusIn(dpy, win) Display *dpy; Window win; { return TRUE; } static int ChinputFocusOut(dpy, win) Display *dpy; Window win; { return TRUE; } static int ChinputSendKey(dpy, win, key_ev, buf) Display *dpy; Window win; XKeyEvent *key_ev; char *buf; { Tg_HZsendKey(dpy, win, key_ev); *buf = '\0'; return TRUE; } static int ChinputExpectCM(dpy, win) Display *dpy; Window win; { return TRUE; } static int ChinputHandleCM(dpy, win, cm_ev, key_ev, buf) Display *dpy; Window win; XClientMessageEvent *cm_ev; XKeyEvent *key_ev; char *buf; { return Tg_HZhandleCM(cm_ev, key_ev, buf); } #endif /* ~_NO_CHINPUT */ /* --------------------- kinput Routines --------------------- */ #ifndef _NO_KINPUT static void KinputCleanUp(dpy, win) Display *dpy; Window win; { imProtocol = IM_NONE; } static int KinputInit(dpy, win, arg) Display *dpy; Window win; char *arg; { char *c_ptr=NULL; copyAndPasteJIS = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "CopyAndPasteJIS")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { copyAndPasteJIS = TRUE; } gnOverTheSpot = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "PreeditType")) != NULL && UtilStrICmp(c_ptr, "overthespot") == 0) { gnOverTheSpot = TRUE; } KinputSetConvOverSpot(gnOverTheSpot); if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "ConvSelection")) != NULL) { UtilTrimBlanks(c_ptr); strncpy(kinputConvSelName, c_ptr, MAXSTRING-1); kinputConvSelName[MAXSTRING-1] = '\0'; } imProtocol = IM_KINPUT; return TRUE; } static int KinputFocusIn(dpy, win) Display *dpy; Window win; { return TRUE; } static int KinputFocusOut(dpy, win) Display *dpy; Window win; { return TRUE; } static int KinputSendKey(dpy, win, key_ev, buf) Display *dpy; Window win; XKeyEvent *key_ev; char *buf; { return FALSE; } static int KinputConvProperty(dpy, win, prop_ev, ppsz_buf) Display *dpy; Window win; XPropertyEvent *prop_ev; char **ppsz_buf; { char *c_ptr=KinputCheckConvProperty(dpy, win, prop_ev); if (c_ptr != NULL && ppsz_buf != NULL) { *ppsz_buf = c_ptr; return TRUE; } return FALSE; } static int KinputExpectCM(dpy, win) Display *dpy; Window win; { return (win == drawWindow || (TidgetHasFocus() && win == TidgetGetFocusWindow())); } static int KinputHandleCM(dpy, win, cm_ev, key_ev, buf) Display *dpy; Window win; XClientMessageEvent *cm_ev; XKeyEvent *key_ev; char *buf; { KinputCheckClientMessage(dpy, win, cm_ev); return FALSE; } static int KinputActiveOnCntrlSpace(dpy, win) Display *dpy; Window win; { return (win == drawWindow || (TidgetHasFocus() && win == TidgetGetFocusWindow())); } static int KinputHandleCntrlSpace(dpy, win) Display *dpy; Window win; { KinputBeginConversion(dpy, win); return TRUE; } static int KinputDeactiveOnCreateText(dpy, win) Display *dpy; Window win; { return TRUE; } static int KinputHandleCreateText(dpy, win) Display *dpy; Window win; { KinputEndConversion(dpy, win); return TRUE; } static int KinputTellCursorPos(dpy, win, cur_x, cur_y) Display *dpy; Window win; int cur_x, cur_y; { KinputTellCursorPosition(dpy, win, cur_x, cur_y); return TRUE; } #endif /* ~_NO_KINPUT */ /* --------------------- xim Routines --------------------- */ #ifndef _NO_XIM static void XimCleanUp(dpy, win) Display *dpy; Window win; { XIMCleanUp(); } static int XimInit(dpy, win, arg) Display *dpy; Window win; char *arg; { char *c_ptr=NULL; XIMInit(); gnOverTheSpot = FALSE; if ((c_ptr=XGetDefault(mainDisplay, TOOL_NAME, "PreeditType")) != NULL && UtilStrICmp(c_ptr, "overthespot") == 0) { gnOverTheSpot = TRUE; } XIMSetConvOverSpot(gnOverTheSpot); return TRUE; } static int XimFocusIn(dpy, win) Display *dpy; Window win; { XIMSetICFocus(dpy, win); return TRUE; } static int XimFocusOut(dpy, win) Display *dpy; Window win; { XIMUnsetICFocus(win); return TRUE; } static int XimDeactiveOnCreateText(dpy, win) Display *dpy; Window win; { return TRUE; } static int XimHandleCreateText(dpy, win) Display *dpy; Window win; { XIMUnsetICFocus(win); return TRUE; } static int XimExpectNextEvent(dpy, win) Display *dpy; Window win; { return (win == drawWindow || (TidgetHasFocus() && win == TidgetGetFocusWindow())); } static int XimHandleNextEvent(dpy, win, ev) Display *dpy; Window win; XEvent *ev; { XIMNextEvent(dpy, win, ev); return TRUE; } static int XimHandleNewCurText(dpy, win) Display *dpy; Window win; { XIMSetICFocus(dpy, win); return TRUE; } static int XimExpectLookupString(dpy, win) Display *dpy; Window win; { return (win == drawWindow || (TidgetHasFocus() && win == TidgetGetFocusWindow())); } static XIMStatus c_stat; static int XimHandleLookupString(dpy, win, key_ev, psz_buf, buf_size, p_key_sym, pn_has_ch) Display *dpy; Window win; XKeyEvent *key_ev; char *psz_buf; int buf_size; KeySym *p_key_sym; int *pn_has_ch; { *pn_has_ch = XIMLookupString(key_ev, psz_buf, buf_size, p_key_sym, &c_stat); return TRUE; } static int XimTellCursorPos(dpy, win, cur_x, cur_y) Display *dpy; Window win; int cur_x, cur_y; { XIMTellCursorPosition(dpy, win, cur_x, cur_y); return TRUE; } #endif /* ~_NO_XIM */ /* --------------------- tgtwb5 Routines --------------------- */ #ifndef _NO_TGTWB5 static void Tgtwb5CleanUp(dpy, win) Display *dpy; Window win; { Tgtwb5_CleanUp(dpy, win); } static int Tgtwb5Init(dpy, win, arg) Display *dpy; Window win; char *arg; { return Tgtwb5_Init(dpy, win, arg); } static int Tgtwb5SendKey(dpy, win, key_ev, buf) Display *dpy; Window win; XKeyEvent *key_ev; char *buf; { return Tgtwb5_SendKey(dpy, win, key_ev, buf); } static int Tgtwb5ExpectCM(dpy, win) Display *dpy; Window win; { return FALSE; } static int Tgtwb5ActiveOnCntrlSpace(dpy, win) Display *dpy; Window win; { return (win == drawWindow || (TidgetHasFocus() && win == TidgetGetFocusWindow())); } static int Tgtwb5HandleCntrlSpace(dpy, win) Display *dpy; Window win; { return Tgtwb5_HandleCntrlSpace(dpy, win); } static int Tgtwb5DeactiveOnCreateText(dpy, win) Display *dpy; Window win; { return TRUE; } static int Tgtwb5HandleCreateText(dpy, win) Display *dpy; Window win; { Tgtwb5_HandleCreateText(dpy, win); return TRUE; } #endif /* ~_NO_XCIN */ /* --------------------- Global Routines --------------------- */ static struct tagIMInfo gstIMInfo[] = { #ifndef _NO_XCIN { "xcin", TGIM_XCIN, TGIM_DBIM, NULL, XcinInit, XcinFocusIn, XcinFocusOut, XcinSendKey, NULL, XcinExpectCM, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }, #endif /* ~_NO_XCIN */ #ifndef _NO_CHINPUT { "chinput", TGIM_CHINPUT, TGIM_DBIM, NULL, ChinputInit, ChinputFocusIn, ChinputFocusOut, ChinputSendKey, NULL, ChinputExpectCM, ChinputHandleCM, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL }, #endif /* ~_NO_CHINPUT */ #ifndef _NO_KINPUT { "kinput2", TGIM_KINPUT, TGIM_DBIM, KinputCleanUp, KinputInit, KinputFocusIn, KinputFocusOut, KinputSendKey, KinputConvProperty, KinputExpectCM, KinputHandleCM, KinputActiveOnCntrlSpace, KinputHandleCntrlSpace, KinputDeactiveOnCreateText, KinputHandleCreateText, KinputTellCursorPos, NULL, NULL, NULL, NULL, NULL }, #endif /* ~_NO_KINPUT */ #ifndef _NO_XIM { "xim", TGIM_XIM, (TGIM_DBIM|TGIM_SBIM), XimCleanUp, XimInit, XimFocusIn, XimFocusOut, NULL, NULL, NULL, NULL, NULL, NULL, XimDeactiveOnCreateText, XimHandleCreateText, XimTellCursorPos, XimExpectNextEvent, XimHandleNextEvent, XimHandleNewCurText, XimExpectLookupString, XimHandleLookupString }, #endif /* ~_NO_XIM */ #ifndef _NO_TGTWB5 { "tgtwb5/tgchgb", TGIM_TGTWB5, TGIM_DBIM, Tgtwb5CleanUp, Tgtwb5Init, NULL, NULL, Tgtwb5SendKey, NULL, Tgtwb5ExpectCM, NULL, Tgtwb5ActiveOnCntrlSpace, Tgtwb5HandleCntrlSpace, Tgtwb5DeactiveOnCreateText, Tgtwb5HandleCreateText, NULL, NULL, NULL, NULL, NULL, NULL }, #endif /* ~_NO_TGTWB5 */ { NULL, TGIM_NONE, 0, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL } }; static void *gpLibIdnHandle=NULL; static Tgim_stringprep_convert_Func *gpfn_stringprep_convert=NULL; static void CleanUpTgim_stringprep_convert() { if (gpLibIdnHandle != NULL) { gpfn_stringprep_convert = NULL; CLOSE_DL(gpLibIdnHandle); gpLibIdnHandle = NULL; } } static void InitTgim_stringprep_convert() { #if (!defined(_NO_IDNLIB) || defined(HAVE_LIBZ)) gpLibIdnHandle = OPEN_DL("libidn.so", OPEN_DL_MODE); if (gpLibIdnHandle != NULL) { gpfn_stringprep_convert = (Tgim_stringprep_convert_Func*)GET_DL_SYM(gpLibIdnHandle, "stringprep_convert"); if (gpfn_stringprep_convert == NULL) { CLOSE_DL(gpLibIdnHandle); gpLibIdnHandle = NULL; } } #endif /* (!defined(_NO_IDNLIB) || defined(HAVE_LIBZ)) */ } int Tgim_has_stringprep_convert() { #if (!defined(_NO_IDNLIB) || defined(HAVE_LIBZ)) if (gpLibIdnHandle != NULL && gpfn_stringprep_convert != NULL) { return TRUE; } #endif /* (!defined(_NO_IDNLIB) || defined(HAVE_LIBZ)) */ return FALSE; } char *Tgim_stringprep_convert(const char *str, const char *to_codeset, const char *from_codeset) { #if (!defined(_NO_IDNLIB) || defined(HAVE_LIBZ)) if (gpLibIdnHandle != NULL && gpfn_stringprep_convert != NULL) { return (gpfn_stringprep_convert)(str, to_codeset, from_codeset); } #endif /* (!defined(_NO_IDNLIB) || defined(HAVE_LIBZ)) */ return NULL; } void CleanUpInputMethods() { CleanUpTgim_stringprep_convert(); if (gnInputMethodIndex != INVALID && gstIMInfo[gnInputMethodIndex].pCleanUpFunc != NULL) { (gstIMInfo[gnInputMethodIndex].pCleanUpFunc)(mainDisplay, mainWindow); } gnInputMethodIndex = INVALID; cmdLineHasInputMethod = FALSE; cmdLineDoubleByteInputMethod = FALSE; *cmdLineInputMethod = '\0'; gpIMInfo = NULL; gnSingleOrDoubleByteInputMethod = 0; } int InitInputMethods() { char *psz=NULL, single_double=0; gnInputMethod = gnInputMethodIndex = INVALID; if (cmdLineHasInputMethod) { UtilTrimBlanks(cmdLineInputMethod); psz = cmdLineInputMethod; single_double = (cmdLineDoubleByteInputMethod ? TGIM_DBIM : TGIM_SBIM); } else { psz = XGetDefault(mainDisplay, TOOL_NAME, "DoubleByteInputMethod"); if (psz == NULL) { psz = XGetDefault(mainDisplay, TOOL_NAME, "SingleByteInputMethod"); single_double = TGIM_SBIM; } else { if (XGetDefault(mainDisplay, TOOL_NAME, "SingleByteInputMethod") != NULL) { sprintf(gszMsgBox, TgLoadString(STID_TWO_XDEF_ONE_IGNORED), TOOL_NAME, "DoubleByteInputMethod", TOOL_NAME, "SingleByteInputMethod", TOOL_NAME, "SingleByteInputMethod"); Msg(gszMsgBox); fprintf(stderr, "%s\n", gszMsgBox); } single_double = TGIM_DBIM; } } gnSingleOrDoubleByteInputMethod = single_double; if (psz != NULL) { IMInfo *pIMInfo=gstIMInfo; char *psz_comma=strchr(psz, ','); int i=0; if (psz_comma != NULL) *psz_comma = '\0'; for ( ; pIMInfo->pszName != NULL; pIMInfo++, i++) { char *psz_slash=strchr(pIMInfo->pszName,'/'); if (psz_slash == NULL) { if (UtilStrICmp(psz, pIMInfo->pszName) == 0 && (single_double & pIMInfo->nSingleDouble) == single_double) { gnInputMethod = pIMInfo->nInputMethod; gnInputMethodIndex = i; gpIMInfo = pIMInfo; if (gstIMInfo[gnInputMethodIndex].pInitFunc != NULL) { if (psz_comma == NULL) { if (!((gstIMInfo[gnInputMethodIndex].pInitFunc)(mainDisplay, mainWindow, NULL))) { /* may not be a problem */ } } else { if (!((gstIMInfo[gnInputMethodIndex].pInitFunc)(mainDisplay, mainWindow, &psz_comma[1]))) { /* may not be a problem */ } } } break; } } else { char *psz_dup=UtilStrDup(pIMInfo->pszName), *psz_cur=NULL; int done=FALSE; if (psz_dup == NULL) FailAllocMessage(); psz_cur = psz_dup; psz_slash = strchr(psz_cur, '/'); while (!done) { if (psz_slash != NULL) *psz_slash = '\0'; if (UtilStrICmp(psz, psz_cur) == 0 && (single_double & pIMInfo->nSingleDouble) == single_double) { gnInputMethod = pIMInfo->nInputMethod; gnInputMethodIndex = i; gpIMInfo = pIMInfo; if (gstIMInfo[gnInputMethodIndex].pInitFunc != NULL) { if (psz_comma == NULL) { if (!((gstIMInfo[gnInputMethodIndex].pInitFunc)(mainDisplay, mainWindow, NULL))) { /* may not be a problem */ } } else { if (!((gstIMInfo[gnInputMethodIndex].pInitFunc)(mainDisplay, mainWindow, &psz_comma[1]))) { /* may not be a problem */ } } } done = TRUE; } if (psz_slash != NULL) { *psz_slash++ = '/'; psz_cur = psz_slash; psz_slash = strchr(psz_cur, '/'); } else { break; } } UtilFree(psz_dup); if (done) { break; } } } if (psz_comma != NULL) *psz_comma++ = ','; if (gnInputMethod == INVALID) { if (single_double == TGIM_DBIM) { fprintf(stderr, TgLoadString(STID_DBIM_UNSUPPORTED), psz); } else { fprintf(stderr, TgLoadString(STID_SBIM_UNSUPPORTED), psz); } fprintf(stderr, "\n"); } } if (gnSingleOrDoubleByteInputMethod == TGIM_SBIM && gnInputMethod != INVALID) { InitTgim_stringprep_convert(); } return TRUE; } int ResetInputMethod() { int rc=FALSE; if (gpIMInfo == NULL) return FALSE; sprintf(gszMsgBox, TgLoadString(STID_OK_TO_RESET_GIVEN_IM), gpIMInfo->pszName); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) != MB_ID_YES) { return FALSE; } CleanUpInputMethods(); rc = InitInputMethods(); sprintf(gszMsgBox, TgLoadString(STID_GIVEN_IM_RESETED), gpIMInfo->pszName); Msg(gszMsgBox); return rc; } int InputMethodTypeMatched(double_byte) int double_byte; { if (gnInputMethodIndex == INVALID || gpIMInfo == NULL) return FALSE; if (double_byte) { return (gnSingleOrDoubleByteInputMethod == TGIM_DBIM && (gpIMInfo->nSingleDouble & TGIM_DBIM) == TGIM_DBIM); } else { return (gnSingleOrDoubleByteInputMethod == TGIM_SBIM && (gpIMInfo->nSingleDouble & TGIM_SBIM) == TGIM_SBIM); } } int tgIMFocusIn(dpy, win) Display *dpy; Window win; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pFocusInFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pFocusInFunc)(dpy, win)); } int tgIMFocusOut(dpy, win) Display *dpy; Window win; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pFocusOutFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pFocusOutFunc)(dpy, win)); } int tgIMTranslateKeyEvent(dpy, win, key_ev, buf) Display *dpy; Window win; XKeyEvent *key_ev; char *buf; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pSendKeyFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pSendKeyFunc)(dpy, win, key_ev, buf)); } int tgIMConvertProperty(dpy, win, prop_ev, ppsz_buf) Display *dpy; Window win; XPropertyEvent *prop_ev; char **ppsz_buf; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pConvPropertyFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pConvPropertyFunc)(dpy, win, prop_ev, ppsz_buf)); } int tgIMExpectClientMessage(dpy, win) Display *dpy; Window win; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pExpectCMFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pExpectCMFunc)(dpy, win)); } int tgIMHandleClientMessage(dpy, win, cm_ev, key_ev, buf) Display *dpy; Window win; XClientMessageEvent *cm_ev; XKeyEvent *key_ev; char *buf; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pHandleCMFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pHandleCMFunc)(dpy, win, cm_ev, key_ev, buf)); } int tgIMActiveOnCntrlSpace(dpy, win) Display *dpy; Window win; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pActivateOnCntrlSpaceFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pActivateOnCntrlSpaceFunc)(dpy, win)); } int tgIMHandleCntrlSpace(dpy, win) Display *dpy; Window win; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pHandleCntrlSpaceFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pHandleCntrlSpaceFunc)(dpy, win)); } int tgIMDeactiveOnCreateText(dpy, win) Display *dpy; Window win; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pDeactivateOnCreateTextFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pDeactivateOnCreateTextFunc)(dpy, win)); } int tgIMHandleCreateText(dpy, win) Display *dpy; Window win; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pHandleCreateTextFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pHandleCreateTextFunc)(dpy, win)); } int tgIMTellCursorPosition(dpy, win, cur_x, cur_y) Display *dpy; Window win; int cur_x, cur_y; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pTellCursorPosFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pTellCursorPosFunc)(dpy, win, cur_x, cur_y)); } int tgIMExpectNextEvent(dpy, win) Display *dpy; Window win; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pExpectNextEventFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pExpectNextEventFunc)(dpy, win)); } int tgIMHandleNextEvent(dpy, win, ev) Display *dpy; Window win; XEvent *ev; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pHandleNextEventFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pHandleNextEventFunc)(dpy, win, ev)); } int tgIMHandleNewCurText(dpy, win) Display *dpy; Window win; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pHandleNewCurTextFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pHandleNewCurTextFunc)(dpy, win)); } int tgIMExpectLookupString(dpy, win) Display *dpy; Window win; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pExpectLookupStringFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pExpectLookupStringFunc)(dpy, win)); } int tgIMHandleLookupString(dpy, win, key_ev, psz_buf, buf_size, p_key_sym, pn_has_ch) Display *dpy; Window win; XKeyEvent *key_ev; char *psz_buf; int buf_size; KeySym *p_key_sym; int *pn_has_ch; { if (gnInputMethodIndex == INVALID || gstIMInfo[gnInputMethodIndex].pHandleLookupStringFunc == NULL) { return FALSE; } return ((gstIMInfo[gnInputMethodIndex].pHandleLookupStringFunc)(dpy, win, key_ev, psz_buf, buf_size, p_key_sym, pn_has_ch)); } ��������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/cutpaste.c���������������������������������������������������������������������������0000644�0000764�0000764�00000433075�11602233311�014773� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/cutpaste.c,v 1.63 2011/06/25 22:36:42 cvsps Exp $ */ #define _INCLUDE_FROM_CUTPASTE_C_ #include "tgifdefs.h" #include "cmdids.h" #include "arc.e" #include "auxtext.e" #include "attr.e" #include "box.e" #include "choice.e" #include "choose.e" #include "cmd.e" #include "color.e" #ifndef _NO_KINPUT #include "convkinput.e" #endif /* ~_NO_KINPUT */ #include "cutpaste.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "file.e" #include "font.e" #include "grid.e" #include "import.e" #include "ini.e" #include "mainloop.e" #include "mark.e" #include "menu.e" #include "miniline.e" #include "move.e" #include "msg.e" #include "names.e" #ifndef _NO_NKF #include "nkf.e" #endif /* ~_NO_NKF */ #include "obj.e" #include "oval.e" #include "page.e" #include "pattern.e" #include "poly.e" #include "polygon.e" #include "raster.e" #include "rcbox.e" #include "remote.e" #include "select.e" #include "setup.e" #include "special.e" #include "stretch.e" #include "strtbl.e" #include "text.e" #include "util.e" #include "xbitmap.e" #include "xpixmap.e" int copyingToCutBuffer=FALSE; int pastingFile=FALSE; char gszFilesIniFile[MAXPATHLENGTH]; /* do not translate -- program constants */ char *gpszRecentFilesSec="Recent Files"; char *gpszRecentFilesCountKey="Count"; int cutBufferIsTgifObj=FALSE; int cutBufferIsUTF8=FALSE; struct DynStrRec dsCutBuffer; Time startSelectionOwnershipTime=(Time)0; Time endSelectionOwnershipTime=(Time)0; int startSelectionOwnershipTimeValid=FALSE; int endSelectionOwnershipTimeValid=FALSE; SetCutBufferInfo gSetCutBufferInfo; static int pasteFromXSelectionOnly=TRUE; static int pasteFromSelectionTimeout=10; static Atom gaCutBufferAtom[] = { XA_CUT_BUFFER0, XA_CUT_BUFFER1, XA_CUT_BUFFER2, XA_CUT_BUFFER3, XA_CUT_BUFFER4, XA_CUT_BUFFER5, XA_CUT_BUFFER6, XA_CUT_BUFFER7, (Atom)0 }; static Atom gaAllSelectionAtom[] = { XA_PRIMARY, /* * It does not appear that you need to try anything other than XA_PRIMARY. * * XA_CUT_BUFFER0, XA_CUT_BUFFER1, XA_CUT_BUFFER2, XA_CUT_BUFFER3, * XA_CUT_BUFFER4, XA_CUT_BUFFER5, XA_CUT_BUFFER6, XA_CUT_BUFFER7, */ (Atom)0 }; static void ResetCutBufferInfo() { UtilFree(gSetCutBufferInfo.tgif_dyn_str.s); UtilFree(gSetCutBufferInfo.utf8_dyn_str.s); UtilFree(gSetCutBufferInfo.text_dyn_str.s); memset(&gSetCutBufferInfo, 0, sizeof(SetCutBufferInfo)); } static void SetCutBuffer(buf, bytes_to_write, buf_is_simple_string, buf_is_utf8_string) char *buf; int bytes_to_write, buf_is_simple_string, buf_is_utf8_string; /* * if buf_is_simple_string is TRUE, this is for text * otherwise, it's an object */ { FreeDynStrBuf(&dsCutBuffer); memset(&dsCutBuffer, 0, sizeof(dsCutBuffer)); dsCutBuffer.s = (char*)malloc((bytes_to_write+1)*sizeof(char)); if (dsCutBuffer.s == NULL) FailAllocMessage(); memcpy(dsCutBuffer.s, buf, bytes_to_write); dsCutBuffer.s[bytes_to_write] = '\0'; dsCutBuffer.sz = bytes_to_write+1; cutBufferIsTgifObj = (buf_is_simple_string ? FALSE : TRUE); cutBufferIsUTF8 = buf_is_utf8_string; if (buf_is_simple_string) { if (buf_is_utf8_string) { DynStrSet(&gSetCutBufferInfo.utf8_dyn_str, dsCutBuffer.s); gSetCutBufferInfo.utf8_valid = TRUE; } else { DynStrSet(&gSetCutBufferInfo.text_dyn_str, dsCutBuffer.s); gSetCutBufferInfo.text_valid = TRUE; } } else { DynStrSet(&gSetCutBufferInfo.tgif_dyn_str, dsCutBuffer.s); gSetCutBufferInfo.tgif_valid = TRUE; } } #ifdef _CALL_XSTOREBYTES_ALSO static int WriteOldStyleCutBuffer() { int xstorebytes_failed=FALSE; copyingToCutBuffer = TRUE; XRotateBuffers(mainDisplay, 1); XStoreBytes(mainDisplay, dsCutBuffer.s, dsCutBuffer.sz-1); XSync(mainDisplay, False); if (copyingToCutBuffer == INVALID) { xstorebytes_failed = TRUE; } copyingToCutBuffer = FALSE; return (!xstorebytes_failed); } #endif /* _CALL_XSTOREBYTES_ALSO */ int WriteBufToCutBuffer(buf, bytes_to_write, buf_is_simple_string, buf_is_utf8_string, pscbi) char *buf; int bytes_to_write, buf_is_simple_string, buf_is_utf8_string; SetCutBufferInfo *pscbi; /* * if buf_is_simple_string is TRUE, this is for text * otherwise, it's an object */ { int copy_failed=FALSE, setselowner_failed=FALSE; ClearSelection(); SetCutBuffer(buf, bytes_to_write, buf_is_simple_string, buf_is_utf8_string); #ifdef _CALL_XSTOREBYTES_ALSO if (!WriteOldStyleCutBuffer()) { ClearSelection(); } #endif /* _CALL_XSTOREBYTES_ALSO */ /* * If use gSelectionMainAtom here, on Fedora 11, pasting anything copied * from other tools ends up pasting from tgif! * So, XA_PRIMARY is hard coded and gSelectionMainAtom is not used. */ XSetSelectionOwner(mainDisplay, XA_PRIMARY, mainWindow, lastKeyOrBtnEvInfo.time); if (XGetSelectionOwner(mainDisplay, XA_PRIMARY) != mainWindow) { setselowner_failed = TRUE; sprintf(gszMsgBox, TgLoadString(STID_CANT_ACQUIRE_X_SELECTION)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { startSelectionOwnershipTimeValid = TRUE; endSelectionOwnershipTimeValid = FALSE; startSelectionOwnershipTime = lastKeyOrBtnEvInfo.time; endSelectionOwnershipTime = (Time)0; } return (!copy_failed); } void ClearSelection() { /* * XStoreBytes(mainDisplay, NULL, 0); * XSetSelectionOwner(mainDisplay, XA_PRIMARY, None, * lastKeyOrBtnEvInfo.time); */ /* * Does not appear to need to do this: * * int i=0; * * for (i=0; gaAllSelectionAtom[i] != (Atom)0; i++) { * XSetSelectionOwner(mainDisplay, gaAllSelectionAtom[i], None, * lastKeyOrBtnEvInfo.time); * } */ } static int CopyObjectToCutBuffer(force) int force; /* if force == TRUE, copy the TGIF object no matter what */ /* if force == FALSE, do not copy if the object is a simple text object, */ /* i.e., all with same font, size, color, etc */ /* returns FALSE if copying in text mode -- this is */ /* interpreted as an attempt to copy highlighted text */ { FILE *fp=NULL; char tmpfile[MAXSTRING], *cut_buffer=NULL; struct stat stat; unsigned char header=TGIF_HEADER; struct ObjRec *partial_text_obj_ptr=NULL; if (curChoice == DRAWTEXT) { if (!textHighlight) { return FALSE; } else { /* create a partial text object with only the minilines */ partial_text_obj_ptr = CreateTextObjFromHighLightedText(); if (partial_text_obj_ptr == NULL) { return FALSE; } if (!force) { struct TextRec *text_ptr=partial_text_obj_ptr->detail.t; MiniLinesInfo *minilines=(&text_ptr->minilines); MiniLineInfo *pMiniLine=minilines->first; StrBlockInfo *pStrBlock=pMiniLine->first_block; StrSegInfo *pStrSeg=pStrBlock->seg; int sz_unit=pStrSeg->sz_unit, double_byte=pStrSeg->double_byte, font=pStrSeg->font, style=pStrSeg->style; int underline_on=pStrSeg->underline_on, overline_on=pStrSeg->overline_on; int color_index=INVALID; if (SingleFontText(text_ptr, &sz_unit, &double_byte, &font, &style, &underline_on, &overline_on) && SingleColorText(text_ptr, &color_index)) { /* since it's a simple text object, don't copy it as a TGIF object */ return FALSE; } } } } else if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return TRUE; } if (MkTempFile(tmpfile, sizeof(tmpfile), tmpDir, TOOL_NAME) == NULL) { return TRUE; } // Naehring: added b to the mode string. if ((fp=fopen(tmpfile, "wb+")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), tmpfile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return TRUE; } writeFileFailed = FALSE; if (write(fileno(fp), (char*)(&header), 1) < 1) writeFileFailed = TRUE; if (curChoice == DRAWTEXT) { /* create a partial text object with only the minilines */ copyInDrawTextMode = TRUE; Save(fp, partial_text_obj_ptr, 0, 1); copyInDrawTextMode = FALSE; FreeObj(partial_text_obj_ptr); } else { struct SelRec *sel_ptr=NULL; struct ObjRec *top_obj=NULL, *bot_obj=NULL; for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { struct ObjRec *obj_ptr=DupObj(sel_ptr->obj); obj_ptr->prev = NULL; obj_ptr->next = top_obj; if (top_obj == NULL) { bot_obj = obj_ptr; } else { top_obj->prev = obj_ptr; } top_obj = obj_ptr; } Save(fp, bot_obj, 0, 1); while (top_obj != NULL) { struct ObjRec *obj_ptr=top_obj->next; FreeObj(top_obj); top_obj = obj_ptr; } } if (writeFileFailed) { FailToWriteFileMessage(tmpfile); fclose(fp); unlink(tmpfile); writeFileFailed = FALSE; return TRUE; } fflush(fp); if (fstat(fileno(fp), &stat) < 0) { fclose(fp); unlink(tmpfile); sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_FSTAT_ABORT_COPY), tmpfile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return TRUE; } if (cut_buffer != NULL) free(cut_buffer); cut_buffer = (char*)malloc((stat.st_size+1)*sizeof(char)); if (cut_buffer == NULL) FailAllocMessage(); rewind(fp); if (read(fileno(fp), cut_buffer, stat.st_size) < stat.st_size) { sprintf(gszMsgBox, TgLoadString(STID_ERR_READING_FILE_COPY_ABORT), tmpfile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { if (!WriteBufToCutBuffer(cut_buffer, stat.st_size, FALSE, FALSE, NULL)) { sprintf(gszMsgBox, TgLoadString(STID_COPY_FAILED_OBJ_MAYBE_TOO_BIG)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { sprintf(gszMsgBox, TgLoadString(STID_COPY_BUFFER_UPDATED)); Msg(gszMsgBox); } } fclose(fp); unlink(tmpfile); UtilFree(cut_buffer); return (curChoice != DRAWTEXT); } int CopyToCutBuffer() /* returns FALSE if copying in text mode -- this is */ /* interpreted as an attempt to copy highlighted text */ { int rc=TRUE, handle_edit_text_size=FALSE; ResetCutBufferInfo(); if (curChoice == DRAWTEXT) { if (escPressed) { escPressed = FALSE; Msg(TgLoadString(STID_ESC_KEY_PRESS_IGNORED)); } if (!textHighlight) { MsgBox(TgLoadString(STID_NO_TEXT_SELECTED_FOR_COPY), TOOL_NAME, INFO_MB); return FALSE; } else { if (editTextSize != 0) { handle_edit_text_size = TRUE; if (RestoreEditTextSize(curTextObj, TRUE)) { UpdTextBBox(curTextObj); } } if (CanCopyHighLightedTextAsUTF8Strings(NULL)) { XEvent ev; if (handle_edit_text_size && editTextSize != 0) { if (RestoreEditTextSize(curTextObj, FALSE)) { UpdTextBBox(curTextObj); } } copyInDrawTextMode = TRUE; copyDoubleByteStringInDrawTextMode = TRUE; ev.type = KeyPress; DrawText(&ev); copyDoubleByteStringInDrawTextMode = FALSE; copyInDrawTextMode = FALSE; } else if (CanCopyHighLightedTextAsStrings()) { XEvent ev; if (handle_edit_text_size && editTextSize != 0) { if (RestoreEditTextSize(curTextObj, FALSE)) { UpdTextBBox(curTextObj); } } copyInDrawTextMode = TRUE; ev.type = KeyPress; DrawText(&ev); copyInDrawTextMode = FALSE; } else { #ifdef NOT_DEFINED char *cut_buffer=NULL; int cut_buffer_size=0; GatherHighLightedTextAsStrings(&cut_buffer, &cut_buffer_size); if (cut_buffer == NULL) { ClearSelection(); } else { if (WriteBufToCutBuffer(cut_buffer, cut_buffer_size-1, TRUE, FALSE, NULL)) { sprintf(gszMsgBox, TgLoadString(STID_COPY_BUFFER_UPDATED)); } else { sprintf(gszMsgBox, TgLoadString(STID_COPY_FAIL_SEL_STR_MAY_TOO_LNG)); } Msg(gszMsgBox); free(cut_buffer); } #endif /* NOT_DEFINED */ /* * create a partial text object with only the minilines, this * will be done in CopyObjectToCutBuffer() below */ } } } else if (topSel == NULL) { MsgBox(TgLoadString(STID_NO_OBJ_SELECTED_FOR_COPY), TOOL_NAME, INFO_MB); return TRUE; } rc = CopyObjectToCutBuffer(FALSE); if (handle_edit_text_size && editTextSize != 0) { if (RestoreEditTextSize(curTextObj, FALSE)) { UpdTextBBox(curTextObj); } } return rc; } int CopyPlainTextAsObject() /* returns FALSE if copying in text mode -- this is */ /* interpreted as an attempt to copy highlighted text */ { if (!(curChoice == DRAWTEXT && textHighlight)) { return (curChoice != DRAWTEXT); } return CopyObjectToCutBuffer(TRUE); } void CutToCutBuffer() { if (curChoice == DRAWTEXT && textCursorShown) { CopyToCutBuffer(); DelSelText(); } if (curChoice == NOTHING && topSel != NULL) { CopyToCutBuffer(); DelAllSelObj(); } } unsigned int PasteString(CutBuffer, highlight, record_cmd) char *CutBuffer; int highlight, record_cmd; { char *c_ptr=NULL, *dest_c_ptr=NULL; int x, y, num_lines=0, char_count, root_x, root_y, grid_x, grid_y; unsigned int status=0, button_pressed=0; struct ObjRec *obj_ptr=NULL; struct TextRec *text_ptr=NULL; Window root_win=None, child_win=None; MiniLineInfo *pFirstMiniLine=NULL, *pLastMiniLine=NULL; if (*CutBuffer == '\0') { MsgBox(TgLoadString(STID_CUT_BUFFER_EMPTY), TOOL_NAME, INFO_MB); return 0; } TieLooseEnds(); SetCurChoice(NOTHING); if (topSel!=NULL) { HighLightReverse(); RemoveAllSel(); } XQueryPointer(mainDisplay, drawWindow, &root_win, &child_win, &root_x, &root_y, &x, &y, &status); GridXY(x, y, &grid_x, &grid_y); obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); text_ptr = (struct TextRec *)malloc(sizeof(struct TextRec)); if (text_ptr == NULL) FailAllocMessage(); memset(text_ptr, 0, sizeof(struct TextRec)); for (c_ptr=CutBuffer, num_lines = 0; *c_ptr != '\0'; num_lines++) { MiniLineInfo *pMiniLine=NULL; if (lengthLimit256InInsertChar) { char s[MAXSTRING+1]; char_count = 0; dest_c_ptr = s; while (*c_ptr != '\0' && *c_ptr != '\n' && *c_ptr != '\r') { *dest_c_ptr++ = *c_ptr++; if (++char_count == MAXSTRING) { sprintf(gszMsgBox, TgLoadString(STID_STRING_LEN_EXCEEDS_AND_TRUNC), MAXSTRING); Msg(gszMsgBox); while (*c_ptr != '\0' && *c_ptr != '\n' && *c_ptr != '\r') { c_ptr++; } break; } } *dest_c_ptr = '\0'; pMiniLine = CreateMiniLineFromString(s, &pFirstMiniLine, &pLastMiniLine); } else { unsigned char *psz_CR=(unsigned char *)strchr(c_ptr, '\r'); unsigned char *psz_LF=(unsigned char *)strchr(c_ptr, '\n'); int use_CR=FALSE, use_LF=FALSE; if (psz_CR == NULL) { if (psz_LF != NULL) { use_LF = TRUE; } } else if (psz_CR == NULL) { use_CR = TRUE; } else if (psz_CR > psz_LF) { use_LF = TRUE; } else { use_CR = TRUE; } if (use_CR) { *psz_CR = '\0'; pMiniLine = CreateMiniLineFromString(c_ptr, &pFirstMiniLine, &pLastMiniLine); *psz_CR = '\n'; c_ptr = (char*)psz_CR; } else if (use_LF) { *psz_LF = '\0'; pMiniLine = CreateMiniLineFromString(c_ptr, &pFirstMiniLine, &pLastMiniLine); *psz_LF = '\r'; c_ptr = (char*)psz_LF; } else { pMiniLine = CreateMiniLineFromString(c_ptr, &pFirstMiniLine, &pLastMiniLine); c_ptr += strlen(c_ptr); } } if (*c_ptr == '\n') { c_ptr++; if (c_ptr[1] == '\r') c_ptr++; } else if (*c_ptr == '\r') { c_ptr++; if (c_ptr[1] == '\n') c_ptr++; } } text_ptr->lines = num_lines; text_ptr->minilines.first = pFirstMiniLine; text_ptr->minilines.last = pLastMiniLine; text_ptr->baseline_y = grid_y+pFirstMiniLine->asc; CopyCurInfoIntoTextPtr(obj_ptr, text_ptr); obj_ptr->x = grid_x; obj_ptr->y = grid_y; obj_ptr->type = OBJ_TEXT; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->id = objId++;; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->detail.t = text_ptr; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; RecalcTextMetrics(text_ptr, grid_x, text_ptr->baseline_y); UpdTextBBox(obj_ptr); AddObj(NULL, topObj, obj_ptr); button_pressed = PlaceTopObj(obj_ptr, NULL, NULL); if (highlight) SelectTopObj(); if (record_cmd) RecordNewObjCmd(); SetFileModified(TRUE); justDupped = FALSE; return button_pressed; } static struct ObjRec *CreateTmpBoxObj(LtX, LtY, RbX, RbY) int LtX, LtY, RbX, RbY; { register struct BoxRec *box_ptr; register struct ObjRec *obj_ptr; box_ptr = (struct BoxRec *)malloc(sizeof(struct BoxRec)); if (box_ptr == NULL) FailAllocMessage(); memset(box_ptr, 0, sizeof(struct BoxRec)); box_ptr->fill = NONEPAT; box_ptr->width = 0; box_ptr->pen = NONEPAT; box_ptr->dash = 0; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = LtX; obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = LtY; obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = RbX; obj_ptr->bbox.rby = obj_ptr->obbox.rby = RbY; obj_ptr->type = OBJ_BOX; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->id = 0; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->detail.b = box_ptr; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; obj_ptr->invisible = FALSE; obj_ptr->trans_pat = FALSE; return obj_ptr; } void AssignNewObjIds(ObjPtr) struct ObjRec *ObjPtr; { register struct ObjRec *obj_ptr; register struct AttrRec *attr_ptr; ObjPtr->id = objId++; switch (ObjPtr->type) { case OBJ_GROUP: case OBJ_SYM: case OBJ_ICON: case OBJ_PIN: for (obj_ptr=ObjPtr->detail.r->first; obj_ptr != NULL; obj_ptr=obj_ptr->next) { AssignNewObjIds(obj_ptr); } break; default: break; } for (attr_ptr=ObjPtr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { AssignNewObjIds(attr_ptr->obj); } } #define CBF_NON_TGIF 0 #define CBF_TGIF_STRING 1 #define CBF_TGIF_OBJ 2 static int CutBufferType(cut_buffer) char *cut_buffer; { unsigned char header=TGIF_HEADER; if (((unsigned char)(*cut_buffer)) == header) { if (strncmp(&cut_buffer[1], "%TGIF", 5) == 0) { return CBF_TGIF_OBJ; } else if (strncmp(&cut_buffer[1], "state(", 6) == 0) { /* very old tgif format (even before tgif-2.12) */ return CBF_TGIF_OBJ; } return CBF_TGIF_STRING; } return CBF_NON_TGIF; } static int GetObjsFromCutBuffer(cut_buffer, len, pp_top_obj, pp_bot_obj) char *cut_buffer; int len; struct ObjRec **pp_top_obj, **pp_bot_obj; /* the cut_buffer is the original cut buffer shifted one byte */ { FILE *fp=NULL; int read_status=0; char tmpfile[MAXSTRING]; struct ObjRec *obj_ptr=NULL, *saved_top_obj=NULL, *saved_bot_obj=NULL; (*pp_top_obj) = (*pp_bot_obj) = NULL; if (MkTempFile(tmpfile, sizeof(tmpfile), tmpDir, TOOL_NAME) == NULL) { return FALSE; } // Naehring: added b to the mode string. if ((fp=fopen(tmpfile, "wb+")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), tmpfile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } writeFileFailed = FALSE; if (write(fileno(fp), cut_buffer, len) < len) { fclose(fp); unlink(tmpfile); sprintf(gszMsgBox, TgLoadString(STID_ERR_WRITING_FILE_PASTE_ABORT), tmpfile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } fflush(fp); rewind(fp); SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); saved_top_obj = topObj; saved_bot_obj = botObj; curPage->top = topObj = NULL; curPage->bot = botObj = NULL; importingFile = TRUE; pastingFile = TRUE; readingPageNum = loadedCurPageNum = 0; foundGoodStateObject = FALSE; while ((read_status=ReadObj(fp, &obj_ptr)) == TRUE) { if (obj_ptr != NULL) { AdjForOldVersion(obj_ptr); UnlockAnObj(obj_ptr); AssignNewObjIds(obj_ptr); AddObj(NULL, topObj, obj_ptr); } } fclose(fp); if (!PRTGIF && colorLayers && needToRedrawColorWindow) { RedrawColorWindow(); } importingFile = FALSE; pastingFile = FALSE; unlink(tmpfile); SetDefaultCursor(mainWindow); ShowCursor(); if (read_status == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FILEVER_TOO_LARGE_PASTE_ABORT), fileVersion); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } (*pp_top_obj) = topObj; (*pp_bot_obj) = botObj; curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; return TRUE; } void FreeSelectionOrCutBuffer(cut_buffer, from_selection) char *cut_buffer; int from_selection; { if (from_selection) { UtilFree(cut_buffer); } else { if (cut_buffer != NULL) XFree(cut_buffer); } } char *FetchSelectionOrCutBuffer(pnLen, pnFromSelection) int *pnLen, *pnFromSelection; { int len=0; unsigned long uLen=0L; char *cut_buffer=GetTextBytesFromSelection(FALSE, &uLen); *pnLen = 0; *pnFromSelection = FALSE; if (cut_buffer == NULL || uLen == 0L) { if (pasteFromXSelectionOnly) return NULL; cut_buffer = (char*)XFetchBytes(mainDisplay, &len); if (len == 0) { return NULL; } } else { *pnFromSelection = TRUE; len = (int)uLen; } *pnLen = len; return cut_buffer; } static int pastingUTF8String=FALSE; int PasteFromCutBuffer() /* returns FALSE if pasting in text mode and non-tgif bytes are */ /* in the cut buffer -- this is interpreted as an attempt to */ /* paste into the current text */ { int len=0, ltx=0, lty=0, rbx=0, rby=0, dx=0, dy=0, from_selection=FALSE; char *cut_buffer=NULL, *orig_cut_buffer=NULL; struct ObjRec *obj_ptr=NULL, *tmp_obj=NULL; struct ObjRec *saved_top_obj=NULL, *saved_bot_obj=NULL; struct ObjRec *pasted_top_obj=NULL, *pasted_bot_obj=NULL; struct ObjRec *tmp_top_obj=NULL, *tmp_bot_obj=NULL; StrSegInfo ssi; memset(&ssi, 0, sizeof(StrSegInfo)); if (curChoice == DRAWTEXT && textCursorShown && CanPasteUTF8StringIntoText(&ssi)) { pastingUTF8String = TRUE; } cut_buffer = FetchSelectionOrCutBuffer(&len, &from_selection); if (cut_buffer == NULL) { MsgBox(TgLoadString(STID_CUT_BUFFER_EMPTY), TOOL_NAME, INFO_MB); pastingUTF8String = FALSE; return TRUE; } orig_cut_buffer = cut_buffer; if (CutBufferType(cut_buffer) != CBF_TGIF_OBJ) { if (curChoice == DRAWTEXT) { XEvent ev; FreeSelectionOrCutBuffer(cut_buffer, from_selection); pasteInDrawTextMode = TRUE; ev.type = KeyPress; DrawText(&ev); pastingUTF8String = FALSE; return FALSE; } #ifndef _NO_KINPUT if (copyAndPasteJIS) { CvtJisToEuc(cut_buffer, cut_buffer); } #endif /* ~_NO_KINPUT */ Msg(TgLoadString(STID_PASTE_FROM_NON_TGIF)); PasteString(cut_buffer, TRUE, TRUE); FreeSelectionOrCutBuffer(cut_buffer, from_selection); pastingUTF8String = FALSE; return TRUE; } if (curChoice == DRAWTEXT) { SaveCursorPositionInCurText(); } else { MakeQuiescent(); } if (!GetObjsFromCutBuffer(&cut_buffer[1], len-1, &pasted_top_obj, &pasted_bot_obj)) { FreeSelectionOrCutBuffer(orig_cut_buffer, from_selection); pastingUTF8String = FALSE; return TRUE; } FreeSelectionOrCutBuffer(orig_cut_buffer, from_selection); saved_top_obj = topObj; saved_bot_obj = botObj; curPage->top = topObj = pasted_top_obj; curPage->bot = botObj = pasted_bot_obj; if (curChoice == DRAWTEXT && textCursorShown && topObj != NULL && topObj == botObj && topObj->type == OBJ_TEXT) { /* we are pasting minilines and not object */ struct ObjRec *partial_text_obj_ptr=topObj; RestoreCursorPositionInCurText(); curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; if (curStrBlock->type == SB_SUPSUB_CENTER) { strcpy(gszMsgBox, TgLoadString(STID_CANNOT_PASTE_MIXED_TEXT)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { Msg(TgLoadString(STID_STR_BLOCKS_PASTED_FROM_TGIF)); PasteMiniLinesAtCursor(partial_text_obj_ptr); } FreeObj(partial_text_obj_ptr); pastingUTF8String = FALSE; return FALSE; } if (curChoice == DRAWTEXT) { /* we've made a mistake earlier on, should have MakeQuiescent() */ struct ObjRec *pasted_top_obj=topObj, *pasted_bot_obj=botObj; curPage->top = topObj = saved_top_obj; curPage->bot = botObj = saved_bot_obj; RestoreCursorPositionInCurText(); MakeQuiescent(); saved_top_obj = topObj; saved_bot_obj = botObj; curPage->top = topObj = pasted_top_obj; curPage->bot = botObj = pasted_bot_obj; } if (topObj != NULL) SetFileModified(TRUE); ltx = topObj->obbox.ltx; lty = topObj->obbox.lty; rbx = topObj->obbox.rbx; rby = topObj->obbox.rby; for (obj_ptr = topObj->next; obj_ptr != NULL; obj_ptr = obj_ptr->next) { if (obj_ptr->obbox.ltx < ltx) ltx = obj_ptr->obbox.ltx; if (obj_ptr->obbox.lty < lty) lty = obj_ptr->obbox.lty; if (obj_ptr->obbox.rbx > rbx) rbx = obj_ptr->obbox.rbx; if (obj_ptr->obbox.rby > rby) rby = obj_ptr->obbox.rby; } tmp_obj = CreateTmpBoxObj(ltx, lty, rbx, rby); tmp_top_obj = topObj; tmp_bot_obj = botObj; curPage->top = topObj = NULL; curPage->bot = botObj = NULL; PlaceTopObj(tmp_obj, saved_top_obj, saved_bot_obj); curPage->top = topObj = tmp_top_obj; curPage->bot = botObj = tmp_bot_obj; dx = tmp_obj->obbox.ltx - ltx; dy = tmp_obj->obbox.lty - lty; FreeBoxObj(tmp_obj); for (obj_ptr=topObj; obj_ptr != NULL; obj_ptr=obj_ptr->next) { MoveObj(obj_ptr, dx, dy); } SelAllObj(FALSE, FALSE); if (botObj != NULL) { botObj->next = saved_top_obj; } else { curPage->top = topObj = saved_top_obj; } if (saved_top_obj != NULL) { saved_top_obj->prev = botObj; curPage->bot = botObj = saved_bot_obj; } RedrawDrawWindow(botObj); PrepareToRecord(CMD_NEW, NULL, NULL, 0); RecordCmd(CMD_NEW, NULL, topSel, botSel, numObjSelected); HighLightForward(); Msg(TgLoadString(STID_OBJS_PASTED_FROM_TGIF)); pastingUTF8String = FALSE; return TRUE; } int PasteFromFile() /* returns FALSE if pasting in text mode and non-tgif bytes are */ /* in the cut buffer -- this is interpreted as an attempt to */ /* paste into the current text */ { char file_name[MAXPATHLENGTH+1]; FILE *fp=NULL; char inbuf[MAXSTRING+1], *cut_buffer=NULL; int size=0, pos=0; if (SelectFileNameToPaste(TgLoadString(STID_SEL_A_FILE_TO_PASTE_DOTS), file_name) == INVALID) { return TRUE; } else if (FileIsRemote(file_name)) { MsgBox(TgLoadString(STID_PASTING_REMOTE_FILE_NOT_SUP), TOOL_NAME, INFO_MB); return TRUE; } if (curChoice == DRAWTEXT) { XEvent ev; pasteInDrawTextMode = TRUE; pasteFromFileInDrawTextMode = TRUE; strcpy(pasteFromFileName, file_name); ev.type = KeyPress; DrawText(&ev); return FALSE; } if ((fp=fopen(file_name, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return TRUE; } while (fgets(inbuf, MAXSTRING, fp) != NULL) size += strlen(inbuf); fclose(fp); if (size == 0) { sprintf(gszMsgBox, TgLoadString(STID_NAMED_FILE_IS_EMPTY), file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return TRUE; } cut_buffer = (char*)malloc((size+2)*sizeof(char)); if (cut_buffer == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_MALLOC_NUM_BYTES), size+2); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return TRUE; } if ((fp=fopen(file_name, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_READING), file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return TRUE; } while (fgets(&cut_buffer[pos], MAXSTRING, fp) != NULL) { pos += strlen(&cut_buffer[pos]); } fclose(fp); #ifndef _NO_NKF if (Tg_useNKF()) { char *out_buffer=(char*)malloc(size+2); if (out_buffer == NULL) FailAllocMessage(); Tg_do_kconv(cut_buffer, out_buffer, size+2); PasteString(out_buffer, TRUE, TRUE); free(out_buffer); } else { #ifndef _NO_KINPUT if (copyAndPasteJIS) { CvtJisToEuc(cut_buffer, cut_buffer); } #endif /* ~_NO_KINPUT */ PasteString(cut_buffer, TRUE, TRUE); } #else /* _NO_NKF */ PasteString(cut_buffer, TRUE, TRUE); #endif /* ~_NO_NKF */ return TRUE; } #ifdef NOT_DEFINED static int WindowPropertyExists(dpy, win, property) Display *dpy; Window win; Atom property; { Atom type_atom=(Atom)0; unsigned long ulBytesLeft=0L, ulLen=0L; char *psz=NULL; int nFormat=0, rc=FALSE; unsigned long ulCurSize=0L, ulTotalLeft=0x10000L; int nStatus=XGetWindowProperty(dpy, win, property, ulCurSize, ulTotalLeft, False, AnyPropertyType, &type_atom, &nFormat, &ulLen, &ulBytesLeft, (unsigned char **)(&psz)); rc = (nStatus != None); if (psz != NULL) XFree(psz); return rc; } #endif /* NOT_DEFINED */ static char *GetTextBytesFromWindowProperty(win, property, compound_text, pul_len, delete_prop) Window win; Atom property; int compound_text, delete_prop; unsigned long *pul_len; { int actual_format=0; unsigned long long_offset=0L, bytes_after=0L, nitems=0L, total=0L; char *cut_buffer=NULL, *psz=NULL; Atom actual_type=(Atom)0; /* * Accorind to the documentation for XGetWindowProperty(), if it is called * with AnyPropertyType, the following is true: * N = actual length of the stored property in bytes * (even if the format is 16 or 32) * I = 4 * long_offset * T = N - I * L = MINIMUM(T, 4 * long_length) * A = N - (I + L) * We use a fixed long_legnth of 0x4000L * L is nitems * A is bytes_after */ if (debugCopyPaste > 1) { char *atom_name=NULL; atom_name = XGetAtomName(mainDisplay, property); fprintf(stderr, "Property name is '%s'.\n", atom_name); XFree(atom_name); } while (XGetWindowProperty(mainDisplay, win, property, long_offset, 0x4000L, delete_prop, AnyPropertyType, &actual_type, &actual_format, &nitems, &bytes_after, (unsigned char **)(&psz)) == Success) { if (debugCopyPaste) { static int n=0; fprintf(stderr, "[%1d] actual_format = %1d, nitems = %1d\n", ++n, (int)actual_format, (int)nitems); } if (psz != NULL && nitems > 0) { unsigned int bytes_per_item=(actual_format>>3); unsigned int bytes_got=(bytes_per_item==1 ? nitems : (bytes_per_item*nitems)); total += bytes_got; if (cut_buffer == NULL) { cut_buffer = (char*)malloc(total+1); } else { cut_buffer = (char*)realloc(cut_buffer, total+1); } if (cut_buffer == NULL) FailAllocMessage(); memcpy(&cut_buffer[long_offset<<2], psz, bytes_got); cut_buffer[total] = '\0'; long_offset += (bytes_got>>2); } if (psz != NULL) XFree(psz); if (nitems == 0 || bytes_after == 0L) { break; } } *pul_len = total; return cut_buffer; } static char *GetTextBytesFromGivenSelection(compound_text, pulLen, which_selection, paste_utf8_string, pssi, pn_timeout_msg_displayed) int compound_text, which_selection, paste_utf8_string; int *pn_timeout_msg_displayed; unsigned long *pulLen; StrSegInfo *pssi; /* the returned string should be freed by calling UtilFree() */ { int done=FALSE, need_to_try_text=FALSE, need_to_try_utf8=FALSE; char *cut_buffer=NULL; time_t tloc, endtime; Window selection_owner_win=None; XEvent ev; selection_owner_win = XGetSelectionOwner(mainDisplay, which_selection); if (selection_owner_win == None) { return NULL; } if (compound_text) { XConvertSelection(mainDisplay, which_selection, compoundTextAtom, tmpSelectionAtom, mainWindow, lastKeyOrBtnEvInfo.time); } else { if (paste_utf8_string) { /* try tgif object first, then try utf8, then try text */ need_to_try_utf8 = TRUE; } else { /* try tgif object then try text */ need_to_try_text = TRUE; } XConvertSelection(mainDisplay, which_selection, tgifProtocolAtom, tmpSelectionAtom, mainWindow, lastKeyOrBtnEvInfo.time); } if (XCheckMaskEvent(mainDisplay, ExposureMask, &ev) || XCheckMaskEvent(mainDisplay, VisibilityChangeMask, &ev)) { ExposeEventHandler(&ev, TRUE); } XFlush(mainDisplay); time(&tloc); endtime = tloc + pasteFromSelectionTimeout; SaveStatusStrings(); sprintf(gszMsgBox, TgLoadString(STID_CONVERTING_GIVEN_DOTS), (compound_text ? "COMPOUND_TEXT" : "TEXT")); SetStringStatus(gszMsgBox); while (!done) { if (XPending(mainDisplay)) { XNextEvent(mainDisplay, &ev); if (ev.type == SelectionNotify) { XSelectionEvent *xselectionev=(&ev.xselection); if (xselectionev->property == None) { /* conversion has been refused */ if (paste_utf8_string) { if (need_to_try_utf8) { need_to_try_utf8 = FALSE; need_to_try_text = TRUE; XConvertSelection(mainDisplay, which_selection, utf8StringAtom, tmpSelectionAtom, mainWindow, lastKeyOrBtnEvInfo.time); continue; } else if (need_to_try_text) { need_to_try_text = FALSE; XConvertSelection(mainDisplay, which_selection, textAtom, tmpSelectionAtom, mainWindow, lastKeyOrBtnEvInfo.time); continue; } } else { if (need_to_try_text) { need_to_try_text = FALSE; need_to_try_utf8 = TRUE; XConvertSelection(mainDisplay, which_selection, textAtom, tmpSelectionAtom, mainWindow, lastKeyOrBtnEvInfo.time); continue; } else if (need_to_try_utf8) { need_to_try_utf8 = FALSE; XConvertSelection(mainDisplay, which_selection, utf8StringAtom, tmpSelectionAtom, mainWindow, lastKeyOrBtnEvInfo.time); continue; } } if (pasteFromXSelectionOnly) { Msg(TgLoadString(STID_SELECTION_CONV_REFUSED)); } else { TwoLineMsg(TgLoadString(STID_SELECTION_CONV_REFUSED), TgLoadString(STID_TRY_PASTE_WITH_OLD_X_MECH)); } } else { cut_buffer = GetTextBytesFromWindowProperty( ev.xselection.requestor, ev.xselection.property, compound_text, pulLen, True); if (cut_buffer == NULL || (pulLen != NULL && *pulLen == 0L)) { if (paste_utf8_string) { if (need_to_try_utf8) { need_to_try_utf8 = FALSE; need_to_try_text = TRUE; XConvertSelection(mainDisplay, which_selection, utf8StringAtom, tmpSelectionAtom, mainWindow, lastKeyOrBtnEvInfo.time); continue; } else if (need_to_try_text) { need_to_try_text = FALSE; XConvertSelection(mainDisplay, which_selection, textAtom, tmpSelectionAtom, mainWindow, lastKeyOrBtnEvInfo.time); continue; } } else { if (need_to_try_text) { need_to_try_text = FALSE; need_to_try_utf8 = TRUE; XConvertSelection(mainDisplay, which_selection, textAtom, tmpSelectionAtom, mainWindow, lastKeyOrBtnEvInfo.time); continue; } else if (need_to_try_utf8) { need_to_try_utf8 = FALSE; XConvertSelection(mainDisplay, which_selection, utf8StringAtom, tmpSelectionAtom, mainWindow, lastKeyOrBtnEvInfo.time); continue; } } } } done = TRUE; } else if (ev.type == SelectionRequest) { HandleSelectionRequest(&ev); } } else { MillisecondSleep(100); } time(&tloc); if (tloc >= endtime) break; } RestoreStatusStrings(); if (!done) { if (*pn_timeout_msg_displayed) { /* don't display the timeout message again */ } else { *pn_timeout_msg_displayed = TRUE; sprintf(gszMsgBox, TgLoadString(STID_TIMEOUT_CONVERT_GIVEN), (compound_text ? "COMPOUND_TEXT" : "TEXT")); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } UtilFree(cut_buffer); return NULL; } if (cut_buffer != NULL) { if (paste_utf8_string && CutBufferType(cut_buffer) != CBF_TGIF_OBJ) { if (!ConvertToOrFromUTF8(CONVERT_FROM_UTF8, (canvasFontDoubleByte ? curFont : pssi->font), &cut_buffer)) { UtilFree(cut_buffer); return NULL; } } else { #ifndef _NO_KINPUT if (cut_buffer) CvtCompoundTextToEuc(cut_buffer, cut_buffer); #endif /* ~_NO_KINPUT */ } } return cut_buffer; } char *GetTextBytesFromSelection(compound_text, pulLen) int compound_text; unsigned long *pulLen; /* the returned string should be freed by calling UtilFree() */ { int i=0, paste_utf8_string=FALSE, timeout_msg_displayed=FALSE; char *cut_buffer=NULL; StrSegInfo ssi; if (pulLen != NULL) *pulLen = 0L; memset(&ssi, 0, sizeof(StrSegInfo)); if (curChoice == DRAWTEXT && textCursorShown && pastingUTF8String) { if (!textHighlight) { if (canvasFontDoubleByte && CanPasteUTF8StringIntoText(&ssi)) { if (ssi.double_byte) { SetCopyUTF8FontInfo(&ssi, TRUE); } paste_utf8_string = TRUE; } else if (CanFindDoubleByteFontAtCursor(&ssi)) { if (ssi.double_byte) { SetCopyUTF8FontInfo(&ssi, TRUE); } paste_utf8_string = TRUE; } } else if (CanPasteUTF8StringIntoText(&ssi)) { if (ssi.double_byte) { SetCopyUTF8FontInfo(&ssi, TRUE); } paste_utf8_string = TRUE; } } SaveStatusStrings(); sprintf(gszMsgBox, TgLoadString(STID_CONVERTING_GIVEN_DOTS), (compound_text ? "COMPOUND_TEXT" : "TEXT")); SetStringStatus(gszMsgBox); for (i=0; gaAllSelectionAtom[i] != (Atom)0; i++) { cut_buffer = GetTextBytesFromGivenSelection(compound_text, pulLen, gaAllSelectionAtom[i], paste_utf8_string, &ssi, &timeout_msg_displayed); if (cut_buffer == NULL || (pulLen != NULL && *pulLen == 0L)) { continue; } else { return cut_buffer; } } RestoreStatusStrings(); /* * If nothing else worked, go back to the the old way of getting data from * the root window. */ if (!timeout_msg_displayed) { cut_buffer = GetTextBytesFromWindowProperty(rootWindow, XA_CUT_BUFFER0, compound_text, pulLen, False); if (cut_buffer != NULL) { if (paste_utf8_string && CutBufferType(cut_buffer) != CBF_TGIF_OBJ) { if (!ConvertToOrFromUTF8(CONVERT_FROM_UTF8, (canvasFontDoubleByte ? curFont: ssi.font), &cut_buffer)) { UtilFree(cut_buffer); return NULL; } } else { #ifndef _NO_KINPUT if (cut_buffer) CvtCompoundTextToEuc(cut_buffer, cut_buffer); #endif /* ~_NO_KINPUT */ } } } return cut_buffer; } int PasteCompoundText() { unsigned long uLen=0L; char *cut_buffer=NULL; if (curChoice == DRAWTEXT) { XEvent ev; pasteInDrawTextMode = TRUE; pasteCompoundTextInDrawTextMode = TRUE; ev.type = KeyPress; DrawText(&ev); return FALSE; } cut_buffer = GetTextBytesFromSelection(TRUE, &uLen); if (cut_buffer == NULL || uLen == 0L) { return TRUE; } Msg(TgLoadString(STID_PASTE_COMP_TEXT_FROM_NON_TGIF)); PasteString(cut_buffer, TRUE, TRUE); UtilFree(cut_buffer); return TRUE; } int CopyDoubleByteString() /* returns FALSE if copying in text mode -- this is */ /* interpreted as an attempt to copy highlighted text */ { int handle_edit_text_size=FALSE; if (curChoice == DRAWTEXT) { if (escPressed) { escPressed = FALSE; Msg(TgLoadString(STID_ESC_KEY_PRESS_IGNORED)); } if (!textHighlight) { MsgBox(TgLoadString(STID_NO_TEXT_SELECTED_FOR_COPY), TOOL_NAME, INFO_MB); return FALSE; } else { if (editTextSize != 0) { handle_edit_text_size = TRUE; if (RestoreEditTextSize(curTextObj, TRUE)) { UpdTextBBox(curTextObj); } } if (CanCopyHighLightedTextAsUTF8Strings(NULL)) { XEvent ev; if (handle_edit_text_size && editTextSize != 0) { if (RestoreEditTextSize(curTextObj, FALSE)) { UpdTextBBox(curTextObj); } } copyInDrawTextMode = TRUE; copyDoubleByteStringInDrawTextMode = TRUE; ev.type = KeyPress; DrawText(&ev); copyDoubleByteStringInDrawTextMode = FALSE; copyInDrawTextMode = FALSE; return FALSE; } } } return TRUE; } int PasteDoubleByteString() { int rc=0; pastingUTF8String = TRUE; rc = PasteFromCutBuffer(); pastingUTF8String = FALSE; return rc; } void CleanUpCutBuffer() { copyingToCutBuffer = FALSE; } /* ----------------------- Properties ----------------------- */ static void SkipIntProp(lWhich, plSkip) long lWhich, *plSkip; { (*plSkip) |= lWhich; } static void TestStringProp(n1, n2, psz1, psz2, lWhich, plSkip) int n1, n2; char *psz1, *psz2; /* psz2 cannot be NULL */ long lWhich, *plSkip; { if (n1 != n2 || ((psz1 == NULL || *psz1 == '\0') && *psz2 != '\0') || ((psz1 != NULL && *psz1 != '\0') && strcmp(psz1, psz2) != 0)) { SkipIntProp(lWhich, plSkip); } } static void SetStringProp(n1, pn2, psz1, psz2) int n1, *pn2; char *psz1, *psz2; /* psz2 cannot be NULL */ { *pn2 = n1; if (psz1 == NULL) { *psz2 = '\0'; } else { strcpy(psz2, psz1); } } static void TestIntProp(n1, n2, lWhich, plSkip) int n1, n2; long lWhich, *plSkip; { if (n1 != n2) SkipIntProp(lWhich, plSkip); } static void TestFontProp(nDoubleByte1, nFont1, nStyle1, nDoubleByte2, nFont2, nStyle2, lWhich, plSkip) int nDoubleByte1, nFont1, nStyle1; int nDoubleByte2, nFont2, nStyle2; long lWhich, *plSkip; { if (nStyle1 != nStyle2) { SkipIntProp(lWhich, plSkip); } else if (nDoubleByte1 != nDoubleByte2) { SkipIntProp(lWhich, plSkip); } else if (nDoubleByte1) { if (nFont1 != nFont2) { SkipIntProp(lWhich, plSkip); } } else { if (nFont1 != nFont2) { SkipIntProp(lWhich, plSkip); } } } static void TestCTMProp(ctm1, transformed, ctm2, lWhich, plSkip) struct XfrmMtrxRec *ctm1, *ctm2; int transformed; long lWhich, *plSkip; { if ((ctm1 == NULL && transformed) || (ctm1 != NULL && (!transformed || ctm1->m[0] != ctm2->m[0] || ctm1->m[1] != ctm2->m[1] || ctm1->m[2] != ctm2->m[2] || ctm1->m[3] != ctm2->m[3] || ctm1->t[0] != ctm2->t[0] || ctm1->t[1] != ctm2->t[1]))) { SkipIntProp(lWhich, plSkip); } } void SetIntPropertyMask(lWhich, nValue, pszValue, plMask, plSkip, pProp) long lWhich, *plMask, *plSkip; int nValue; char *pszValue; struct PropertiesRec *pProp; { if (((*plSkip) & lWhich) == lWhich) { /* * this property is inconsistent, continue skipping it */ } else if (((*plMask) & lWhich) == lWhich) { /* * this property was set before, if it's not the same, skip/invalidate it */ switch (lWhich) { case PROP_MASK_COLOR: TestStringProp(nValue, pProp->color, pszValue, pProp->color_str, lWhich, plSkip); break; case PROP_MASK_WIDTH: TestStringProp(nValue, pProp->width, pszValue, pProp->width_spec, lWhich, plSkip); break; case PROP_MASK_AW: TestStringProp(nValue, pProp->aw, pszValue, pProp->aw_spec, lWhich, plSkip); break; case PROP_MASK_AH: TestStringProp(nValue, pProp->ah, pszValue, pProp->ah_spec, lWhich, plSkip); break; case PROP_MASK_TRANSPAT: TestIntProp(nValue, pProp->trans_pat, lWhich, plSkip); break; case PROP_MASK_FILL: TestIntProp(nValue, pProp->fill, lWhich, plSkip); break; case PROP_MASK_PEN: TestIntProp(nValue, pProp->pen, lWhich, plSkip); break; case PROP_MASK_DASH: TestIntProp(nValue, pProp->dash, lWhich, plSkip); break; case PROP_MASK_ARROW_STYLE: TestIntProp(nValue, pProp->arrow_style, lWhich, plSkip); break; case PROP_MASK_CURVED: TestIntProp(nValue, pProp->curved, lWhich, plSkip); break; case PROP_MASK_RCB_RADIUS: TestIntProp(nValue, pProp->rcb_radius, lWhich, plSkip); break; case PROP_MASK_TEXT_JUST: TestIntProp(nValue, pProp->text_just, lWhich, plSkip); break; case PROP_MASK_TEXT_SZ_UNIT: TestIntProp(nValue, pProp->text_sz_unit, lWhich, plSkip); break; case PROP_MASK_UNDERLINE_ON: TestIntProp(nValue, pProp->underline_on, lWhich, plSkip); break; case PROP_MASK_OVERLINE_ON: TestIntProp(nValue, pProp->overline_on, lWhich, plSkip); break; } } else { /* this property is never set, go set it */ (*plMask) |= lWhich; switch (lWhich) { case PROP_MASK_COLOR: SetStringProp(nValue, &pProp->color, pszValue, pProp->color_str); break; case PROP_MASK_WIDTH: SetStringProp(nValue, &pProp->width, pszValue, pProp->width_spec); break; case PROP_MASK_AW: SetStringProp(nValue, &pProp->aw, pszValue, pProp->aw_spec); break; case PROP_MASK_AH: SetStringProp(nValue, &pProp->ah, pszValue, pProp->ah_spec); break; case PROP_MASK_TRANSPAT: pProp->trans_pat = nValue; break; case PROP_MASK_FILL: pProp->fill = nValue; break; case PROP_MASK_PEN: pProp->pen = nValue; break; case PROP_MASK_DASH: pProp->dash = nValue; break; case PROP_MASK_ARROW_STYLE: pProp->arrow_style = nValue; break; case PROP_MASK_CURVED: pProp->curved = nValue; break; case PROP_MASK_RCB_RADIUS: pProp->rcb_radius = nValue; break; case PROP_MASK_TEXT_JUST: pProp->text_just = nValue; break; case PROP_MASK_TEXT_SZ_UNIT: pProp->text_sz_unit = nValue; break; case PROP_MASK_VSPACE: pProp->v_space = nValue; break; case PROP_MASK_UNDERLINE_ON: pProp->underline_on = nValue; break; case PROP_MASK_OVERLINE_ON: pProp->overline_on = nValue; break; } } } void SetFontPropertyMask(nDoubleByte, nFont, nStyle, plMask, plSkip, pProp) int nDoubleByte, nFont, nStyle; long *plMask, *plSkip; struct PropertiesRec *pProp; { if (((*plSkip) & PROP_MASK_TEXT_FONT) == PROP_MASK_TEXT_FONT) { /* * this property is inconsistent, continue skipping it */ } else if (((*plMask) & PROP_MASK_TEXT_FONT) == PROP_MASK_TEXT_FONT) { /* * this property was set before, if it's not the same, skip/invalidate it */ TestFontProp(nDoubleByte, nFont, nStyle, pProp->double_byte, pProp->text_font, pProp->text_style, PROP_MASK_TEXT_FONT, plSkip); } else { /* this property is never set, go set it */ (*plMask) |= PROP_MASK_TEXT_FONT; pProp->double_byte = nDoubleByte; pProp->text_font = nFont; pProp->text_style = nStyle; } } void SetCTMPropertyMask(ctm, plMask, plSkip, pProp) struct XfrmMtrxRec *ctm; long *plMask, *plSkip; struct PropertiesRec *pProp; { if (((*plSkip) & PROP_MASK_CTM) == PROP_MASK_CTM) { /* * this property is inconsistent, continue skipping it */ } else if (((*plMask) & PROP_MASK_CTM) == PROP_MASK_CTM) { /* * this property was set before, if it's not the same, skip/invalidate it */ TestCTMProp(ctm, pProp->transformed, &pProp->ctm, PROP_MASK_CTM, plSkip); } else { /* this property is never set, go set it */ (*plMask) |= PROP_MASK_CTM; if (ctm == NULL) { pProp->transformed = FALSE; } else { pProp->transformed = TRUE; memcpy(&pProp->ctm, ctm, sizeof(struct XfrmMtrxRec)); } } } void SetTextPropMask(ObjPtr, plMask, plSkip, pProp) struct ObjRec *ObjPtr; long *plMask, *plSkip; struct PropertiesRec *pProp; { struct TextRec *text_ptr=ObjPtr->detail.t; int sz_unit=INVALID, double_byte=INVALID, font=INVALID, style=INVALID; int underline_on=FALSE, overline_on=FALSE; SetCTMPropertyMask(ObjPtr->ctm, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_COLOR, ObjPtr->color, colorMenuItems[ObjPtr->color], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TRANSPAT, ObjPtr->trans_pat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_FILL, text_ptr->fill, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_PEN, text_ptr->pen, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TEXT_JUST, text_ptr->minilines.just, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_VSPACE, text_ptr->minilines.v_space, NULL, plMask, plSkip, pProp); if (SingleFontText(text_ptr, &sz_unit, &double_byte, &font, &style, &underline_on, &overline_on)) { SetIntPropertyMask(PROP_MASK_TEXT_SZ_UNIT, sz_unit, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_UNDERLINE_ON, underline_on, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_OVERLINE_ON, overline_on, NULL, plMask, plSkip, pProp); SetFontPropertyMask(double_byte, font, style, plMask, plSkip, pProp); } } static void SetPropMask(ObjPtr, plMask, plSkip, pProp) struct ObjRec *ObjPtr; long *plMask, *plSkip; struct PropertiesRec *pProp; { if (curChoice == DRAWTEXT) { if (textCursorShown && textHighlight) { SetIntPropertyMask(PROP_MASK_TRANSPAT, transPat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_FILL, objFill, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_PEN, penPat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TEXT_JUST, textJust, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_VSPACE, textVSpace, NULL, plMask, plSkip, pProp); if (HighlightedTextHasSameProperty(PROP_MASK_COLOR, curStrBlock->seg->color, TRUE)) { SetIntPropertyMask(PROP_MASK_COLOR, colorIndex, colorMenuItems[colorIndex], plMask, plSkip, pProp); } if (HighlightedTextHasSameProperty(PROP_MASK_TEXT_SZ_UNIT, curStrBlock->seg->sz_unit, TRUE)) { SetIntPropertyMask(PROP_MASK_TEXT_SZ_UNIT, GetCurSzUnit(), NULL, plMask, plSkip, pProp); } if (HighlightedTextHasSameProperty(PROP_MASK_UNDERLINE_ON, curStrBlock->seg->underline_on, TRUE)) { SetIntPropertyMask(PROP_MASK_UNDERLINE_ON, curUnderlineOn, NULL, plMask, plSkip, pProp); } if (HighlightedTextHasSameProperty(PROP_MASK_OVERLINE_ON, curStrBlock->seg->overline_on, TRUE)) { SetIntPropertyMask(PROP_MASK_OVERLINE_ON, curOverlineOn, NULL, plMask, plSkip, pProp); } if (HighlightedTextHasSameProperty(PROP_MASK_TEXT_FONT, curStrBlock->seg->font, TRUE) && HighlightedTextHasSameProperty(PROP_MASK_TEXT_STYLE, curStrBlock->seg->style, TRUE)) { SetFontPropertyMask(canvasFontDoubleByte, curFont, curStyle, plMask, plSkip, pProp); } } else { SetIntPropertyMask(PROP_MASK_TRANSPAT, transPat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_FILL, objFill, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_PEN, penPat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TEXT_JUST, textJust, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_VSPACE, textVSpace, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_COLOR, colorIndex, colorMenuItems[colorIndex], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TEXT_SZ_UNIT, GetCurSzUnit(), NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_UNDERLINE_ON, curUnderlineOn, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_OVERLINE_ON, curOverlineOn, NULL, plMask, plSkip, pProp); SetFontPropertyMask(canvasFontDoubleByte, curFont, curStyle, plMask, plSkip, pProp); } } else if (ObjPtr == NULL) { double radian=((double)(textRotation))*M_PI/180.0/64.0; double sin_val=sin(radian); double cos_val=cos(radian); struct XfrmMtrxRec ctm; ctm.m[CTM_SX] = ctm.m[CTM_SY] = ((double)1000)*cos_val; ctm.m[CTM_SIN] = ((double)1000)*sin_val; ctm.m[CTM_MSIN] = (-ctm.m[CTM_SIN]); ctm.t[CTM_TX] = ctm.t[CTM_TY] = 0; SetCTMPropertyMask(&ctm, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_COLOR, colorIndex, colorMenuItems[colorIndex], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_WIDTH, curWidthOfLine[lineWidth], curWidthOfLineSpec[lineWidth], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_AW, curArrowHeadW[lineWidth], curArrowHeadWSpec[lineWidth], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_AH, curArrowHeadH[lineWidth], curArrowHeadHSpec[lineWidth], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TRANSPAT, transPat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_FILL, objFill, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_PEN, penPat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_DASH, curDash, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_CURVED, curSpline, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_ARROW_STYLE, lineStyle, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_RCB_RADIUS, rcbRadius, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TEXT_JUST, textJust, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TEXT_SZ_UNIT, GetCurSzUnit(), NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_VSPACE, textVSpace, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_UNDERLINE_ON, curUnderlineOn, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_OVERLINE_ON, curOverlineOn, NULL, plMask, plSkip, pProp); SetFontPropertyMask(canvasFontDoubleByte, curFont, curStyle, plMask, plSkip, pProp); } else { struct ObjRec *obj_ptr=NULL; switch (ObjPtr->type) { case OBJ_POLY: SetPolyPropMask(ObjPtr, plMask, plSkip, pProp); break; case OBJ_BOX: SetBoxPropMask(ObjPtr, plMask, plSkip, pProp); break; case OBJ_OVAL: SetOvalPropMask(ObjPtr, plMask, plSkip, pProp); break; case OBJ_TEXT: SetTextPropMask(ObjPtr, plMask, plSkip, pProp); break; case OBJ_POLYGON: SetPolygonPropMask(ObjPtr, plMask, plSkip, pProp); break; case OBJ_ARC: SetArcPropMask(ObjPtr, plMask, plSkip, pProp); break; case OBJ_RCBOX: SetRCBoxPropMask(ObjPtr, plMask, plSkip, pProp); break; case OBJ_XBM: SetXBmPropMask(ObjPtr, plMask, plSkip, pProp); break; case OBJ_XPM: SetXPmPropMask(ObjPtr, plMask, plSkip, pProp); break; case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: for (obj_ptr=ObjPtr->detail.r->first; obj_ptr != NULL; obj_ptr=obj_ptr->next) { SetPropMask(obj_ptr, plMask, plSkip, pProp); } break; } } } static int GetAngleFromCTM(ctm) struct XfrmMtrxRec *ctm; /* returned angle is degree*64 */ { double sin_val=(double)(ctm->m[CTM_SIN]/((double)1000)); double cos_val=(double)(ctm->m[CTM_SX]/((double)1000)); double radian=(double)0; int angle=0; if (fabs(sin_val) < EQ_TOL) { if (cos_val > 0) { radian = (double)0; } else { radian = (double)M_PI; } } else if (fabs(cos_val) < EQ_TOL) { if (sin_val> 0) { radian = (double)(M_PI/2.0); } else { radian = (double)(M_PI*3.0/2.0); } } else { radian = (double)atan(sin_val/cos_val); if (radian >= 0) { if (sin_val < 0) { radian += (double)M_PI; } } else { if (cos_val > 0) { radian += (double)(M_PI*2.0); } else { radian += (double)M_PI; } } } angle = (int)(radian*((double)180)*((double)64)/M_PI); return angle; } static void DoPasteAProperty(lWhich, pProp) long lWhich; struct PropertiesRec *pProp; { char szBuf[MAXSTRING]; int index=0, new_alloc=FALSE; switch (lWhich) { case PROP_MASK_COLOR: index = QuickFindColorIndex(NULL, pProp->color_str, &new_alloc, FALSE); if (index == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR), pProp->color_str); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } else { ChangeAllSelColor(index, TRUE); } break; case PROP_MASK_WIDTH: ChangeAllSelRealLineWidth(CHANGE_WIDTH, pProp->width, (-1), (-1), pProp->width_spec, NULL, NULL, TRUE); break; case PROP_MASK_AW: ChangeAllSelRealLineWidth(CHANGE_AW, (-1), pProp->aw, (-1), NULL, pProp->aw_spec, NULL, TRUE); break; case PROP_MASK_AH: ChangeAllSelRealLineWidth(CHANGE_AH, (-1), (-1), pProp->ah, NULL, NULL, pProp->ah_spec, TRUE); break; case PROP_MASK_TRANSPAT: ChangeAllSelTransPat(pProp->trans_pat, TRUE); break; case PROP_MASK_FILL: ChangeAllSelFill(pProp->fill, TRUE); break; case PROP_MASK_PEN: ChangeAllSelPen(pProp->pen, TRUE); break; case PROP_MASK_DASH: ChangeAllSelLineDash(pProp->dash, TRUE); break; case PROP_MASK_ARROW_STYLE: ChangeAllSelLineStyle(pProp->arrow_style, TRUE); break; case PROP_MASK_CURVED: ChangeAllSelLineType(pProp->curved, TRUE); break; case PROP_MASK_RCB_RADIUS: ChangeAllSelRCBRadius(pProp->rcb_radius); break; case PROP_MASK_TEXT_JUST: ChangeFontJust(pProp->text_just); break; case PROP_MASK_TEXT_SZ_UNIT: sprintf(szBuf, "%1d", SzUnitToFontSize(pProp->text_sz_unit)); SetSelFontSize(szBuf); break; case PROP_MASK_VSPACE: ChangeVSpace(pProp->v_space); break; case PROP_MASK_UNDERLINE_ON: ChangeFontUnderline(pProp->underline_on); break; case PROP_MASK_OVERLINE_ON: ChangeFontOverline(pProp->overline_on); break; case PROP_MASK_TEXT_FONT: ChangeFont(pProp->text_font, TRUE); ChangeFontStyle(pProp->text_style); break; case PROP_MASK_CTM: if (topSel == NULL) { if (pProp->transformed) { int angle=GetAngleFromCTM(&pProp->ctm); FormatAngle(angle, szBuf); } else { strcpy(szBuf, "0"); } SetTextRotation(szBuf); } else { SetSelCTM(pProp->transformed, &pProp->ctm); } break; } } static void DoGetAProperty(lWhich, pProp) long lWhich; struct PropertiesRec *pProp; { char szBuf[MAXSTRING]; int index=0, new_alloc=FALSE; switch (lWhich) { case PROP_MASK_COLOR: index = QuickFindColorIndex(NULL, pProp->color_str, &new_alloc, FALSE); if (index == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_ALLOC_NAMED_COLOR), pProp->color_str); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } else { ChangeAllSelColor(index, TRUE); } break; case PROP_MASK_WIDTH_INDEX: ChangeAllSelLineWidth(pProp->width_index, TRUE); break; case PROP_MASK_WIDTH: ChangeAllSelRealLineWidth(CHANGE_WIDTH, pProp->width, (-1), (-1), pProp->width_spec, NULL, NULL, TRUE); break; case PROP_MASK_AW: ChangeAllSelRealLineWidth(CHANGE_AW, (-1), pProp->aw, (-1), NULL, pProp->aw_spec, NULL, TRUE); break; case PROP_MASK_AH: ChangeAllSelRealLineWidth(CHANGE_AH, (-1), (-1), pProp->ah, NULL, NULL, pProp->ah_spec, TRUE); break; case PROP_MASK_TRANSPAT: ChangeAllSelTransPat(pProp->trans_pat, TRUE); break; case PROP_MASK_FILL: ChangeAllSelFill(pProp->fill, TRUE); break; case PROP_MASK_PEN: ChangeAllSelPen(pProp->pen, TRUE); break; case PROP_MASK_DASH: ChangeAllSelLineDash(pProp->dash, TRUE); break; case PROP_MASK_ARROW_STYLE: ChangeAllSelLineStyle(pProp->arrow_style, TRUE); break; case PROP_MASK_CURVED: ChangeAllSelLineType(pProp->curved, TRUE); break; case PROP_MASK_RCB_RADIUS: ChangeAllSelRCBRadius(pProp->rcb_radius); break; case PROP_MASK_TEXT_JUST: ChangeFontJust(pProp->text_just); break; case PROP_MASK_TEXT_SZ_UNIT: sprintf(szBuf, "%1d", SzUnitToFontSize(pProp->text_sz_unit)); SetSelFontSize(szBuf); break; case PROP_MASK_VSPACE: ChangeVSpace(pProp->v_space); break; case PROP_MASK_UNDERLINE_ON: ChangeFontUnderline(pProp->underline_on); break; case PROP_MASK_OVERLINE_ON: ChangeFontOverline(pProp->overline_on); break; case PROP_MASK_TEXT_FONT: ChangeFont(pProp->text_font, TRUE); ChangeFontStyle(pProp->text_style); break; case PROP_MASK_CTM: if (topSel == NULL) { if (pProp->transformed) { int angle=GetAngleFromCTM(&pProp->ctm); FormatAngle(angle, szBuf); } else { strcpy(szBuf, "0"); } SetTextRotation(szBuf); } else { SetSelCTM(pProp->transformed, &pProp->ctm); } break; } } static char gszPropIniFile[MAXPATHLENGTH]; static char gszCopyPasteSec[MAXSTRING]; static char gszCopyPasteBackupSec[MAXSTRING]; static char gszPropSetSec[MAXSTRING]; static char gszPropProfilePrefix[MAXSTRING]; struct PropInfoRec { long bit; int checked; char *key; char *desc; }; static struct PropInfoRec gstPropInfo[] = { { PROP_MASK_AH, FALSE, NULL, NULL }, { PROP_MASK_AW, FALSE, NULL, NULL }, { PROP_MASK_ARROW_STYLE, FALSE, NULL, NULL }, { PROP_MASK_COLOR, FALSE, NULL, NULL }, { PROP_MASK_DASH, FALSE, NULL, NULL }, { PROP_MASK_WIDTH, FALSE, NULL, NULL }, { PROP_MASK_TRANSPAT, FALSE, NULL, NULL }, { PROP_MASK_FILL, FALSE, NULL, NULL }, { PROP_MASK_PEN, FALSE, NULL, NULL }, { PROP_MASK_RCB_RADIUS, FALSE, NULL, NULL }, { PROP_MASK_CURVED, FALSE, NULL, NULL }, { PROP_MASK_TEXT_FONT, FALSE, NULL, NULL }, { PROP_MASK_TEXT_STYLE, FALSE, NULL, NULL }, { PROP_MASK_TEXT_JUST, FALSE, NULL, NULL }, { PROP_MASK_TEXT_SZ_UNIT, FALSE, NULL, NULL }, { PROP_MASK_VSPACE, FALSE, NULL, NULL }, { PROP_MASK_UNDERLINE_ON, FALSE, NULL, NULL }, { PROP_MASK_OVERLINE_ON, FALSE, NULL, NULL }, { PROP_MASK_CTM, FALSE, NULL, NULL }, { PROP_MASK_WIDTH_INDEX, FALSE, NULL, NULL }, { 0L, FALSE, NULL, NULL } }; static struct PropInfoRec gstCompatPropInfo[] = { /* * do not translate -- program constants * * These are used for compatibility reasons. In an earlier version, * the keys in "cutpaste.ini" are these strings. In the current * version, hex numbers are used. gstCompatPropInfo are only used * by UpdateSavedPropKeys() to update the old keys to new ones. */ { PROP_MASK_AH, FALSE, NULL, "arrow height" }, { PROP_MASK_AW, FALSE, NULL, "arrow width" }, { PROP_MASK_ARROW_STYLE, FALSE, NULL, "arrow style" }, { PROP_MASK_COLOR, FALSE, NULL, "color" }, { PROP_MASK_DASH, FALSE, NULL, "dash" }, { PROP_MASK_WIDTH, FALSE, NULL, "line width" }, { PROP_MASK_TRANSPAT, FALSE, NULL, "pattern transparency" }, { PROP_MASK_FILL, FALSE, NULL, "fill" }, { PROP_MASK_PEN, FALSE, NULL, "pen" }, { PROP_MASK_RCB_RADIUS, FALSE, NULL, "rcbox radius" }, { PROP_MASK_CURVED, FALSE, NULL, "spline" }, { PROP_MASK_TEXT_FONT, FALSE, NULL, "text font" }, { PROP_MASK_TEXT_STYLE, FALSE, NULL, "text style (no use, part of text font)" }, { PROP_MASK_TEXT_JUST, FALSE, NULL, "text justification" }, { PROP_MASK_TEXT_SZ_UNIT, FALSE, NULL, "text size" }, { PROP_MASK_VSPACE, FALSE, NULL, "text vertical spacing" }, { PROP_MASK_UNDERLINE_ON, FALSE, NULL, "text underline" }, { PROP_MASK_CTM, FALSE, NULL, "transformation matrix" }, { 0L, FALSE, NULL, NULL } }; static void WriteIntProp(pszSec, pszKey, nValue) char *pszSec, *pszKey; int nValue; { sprintf(gszMsgBox, "%1d", nValue); tgWriteProfileString(pszSec, pszKey, gszMsgBox, gszPropIniFile); } static void WriteStringProp(pszSec, pszKey, nValue, pszValue) char *pszSec, *pszKey; int nValue; char *pszValue; { sprintf(gszMsgBox, "%1d,%s", nValue, (pszValue==NULL ? "" : pszValue)); tgWriteProfileString(pszSec, pszKey, gszMsgBox, gszPropIniFile); } static void WriteFontProp(pszSec, pszKey, nFont, nStyle) char *pszSec, *pszKey; int nFont, nStyle; { char font_str[MAXSTRING]; *font_str = '\0'; GetPSFontStr(nFont, nStyle, font_str); /* font_str starts with the '/' character */ sprintf(gszMsgBox, "%1d,%s", nStyle, &font_str[1]); tgWriteProfileString(pszSec, pszKey, gszMsgBox, gszPropIniFile); } static void WriteCTMProp(pszSec, pszKey, nTransformed, ctm) char *pszSec, *pszKey; int nTransformed; struct XfrmMtrxRec *ctm; { if (nTransformed) { sprintf(gszMsgBox, "%1d,%g,%g,%g,%g,%1d,%1d", nTransformed, ctm->m[CTM_SX], ctm->m[CTM_SIN], ctm->m[CTM_MSIN], ctm->m[CTM_SY], ctm->t[CTM_TX], ctm->t[CTM_TY]); } else { sprintf(gszMsgBox, "%1d,%g,%g,%g,%g,%1d,%1d", nTransformed, (double)1000, (double)0, (double)0, (double)1000, 0, 0); } tgWriteProfileString(pszSec, pszKey, gszMsgBox, gszPropIniFile); } static int ParseIntProp(pszBuf, pnValue) char *pszBuf; int *pnValue; { return (sscanf(pszBuf, "%d", pnValue) == 1); } static int ParseStringProp(pszBuf, pnValue, pszValue) char *pszBuf; int *pnValue; char *pszValue; { char *psz1=strtok(pszBuf, ","), *psz2=NULL; if (psz1 == NULL) return FALSE; psz2 = strtok(NULL, ","); if (psz2 == NULL) return FALSE; if (sscanf(psz1, "%d", pnValue) != 1) return FALSE; strcpy(pszValue, psz2); return TRUE; } static int ParseFontSzUnitProp(pszBuf, pnSzUnit) char *pszBuf; int *pnSzUnit; { int i, sz_unit=0; if (sscanf(pszBuf, "%d", &sz_unit) != 1) return FALSE; for (i=0; i < numFontSizes; i++) { if (sz_unit == fontSzUnits[i]) { *pnSzUnit = sz_unit; return TRUE; } } if (topSel == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_FIND_SIZE_USE_ALT), SzUnitToFontSize(sz_unit), defaultFontSize); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *pnSzUnit = FontSizeToSzUnit(defaultFontSize); } else { *pnSzUnit = sz_unit; } return TRUE; } static int ParseFontProp(pszBuf, pnDoubleByte, pnFont, pnStyle) char *pszBuf; int *pnDoubleByte, *pnFont, *pnStyle; { char font_str[MAXSTRING], *psz=NULL; *font_str = '\0'; psz = strchr(pszBuf, ','); if (psz == NULL) return FALSE; *psz = '\0'; if (sscanf(pszBuf, "%d", pnStyle) != 1) { *psz = ','; return FALSE; } *psz++ = ','; strcpy(font_str, psz); *pnFont = GetFontIndex(font_str, *pnStyle, TRUE); *pnDoubleByte = FALSE; if (*pnFont == INVALID) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_FIND_FONT_USE_ALT), font_str, "Times"); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *pnDoubleByte = FALSE; *pnFont = FONT_TIM; } return TRUE; } static int ParseCTMProp(pszBuf, pnTransformed, ctm) char *pszBuf; int *pnTransformed; struct XfrmMtrxRec *ctm; { struct PropInfoRec *ppir=NULL; char *psz=strchr(pszBuf, ','); if (psz == NULL) return FALSE; *psz = '\0'; if (sscanf(pszBuf, "%d", pnTransformed) != 1) { *psz = ','; return FALSE; } *psz++ = ','; if (sscanf(psz, "%lg , %lg , %lg, %lg , %d , %d", &ctm->m[CTM_SX], &ctm->m[CTM_SIN], &ctm->m[CTM_MSIN], &ctm->m[CTM_SY], &ctm->t[CTM_TX], &ctm->t[CTM_TY]) != 6) { return FALSE; } if (topSel != NULL) { struct SelRec *sel_ptr=NULL; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { switch (sel_ptr->obj->type) { case OBJ_GROUP: case OBJ_ICON: case OBJ_SYM: case OBJ_PIN: for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { if (ppir->bit == PROP_MASK_CTM) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_PASTE_COMPOUND_OBJ), ppir->desc, ppir->desc); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; } } return FALSE; } } } else if (topSel == NULL && (*pnTransformed)) { if ((fabs(ctm->m[CTM_SX]-ctm->m[CTM_SY]) < EQ_TOL) && (fabs(ctm->m[CTM_SIN]+ctm->m[CTM_MSIN]) < EQ_TOL)) { return TRUE; } for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { if (ppir->bit == PROP_MASK_CTM) { sprintf(gszMsgBox, TgLoadString(STID_CUT_BUF_HAS_NON_ROT_COMP), ppir->desc); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); break; } } *pnTransformed = FALSE; } return TRUE; } static void WritePropToIni(lWhich, pszSec, pszKey, pProp) long lWhich; char *pszSec, *pszKey; struct PropertiesRec *pProp; { switch (lWhich) { case PROP_MASK_AH: WriteStringProp(pszSec, pszKey, pProp->ah, pProp->ah_spec); break; case PROP_MASK_AW: WriteStringProp(pszSec, pszKey, pProp->aw, pProp->aw_spec); break; case PROP_MASK_ARROW_STYLE: WriteIntProp(pszSec, pszKey, pProp->arrow_style); break; case PROP_MASK_COLOR: WriteStringProp(pszSec, pszKey, pProp->color, pProp->color_str); break; case PROP_MASK_DASH: WriteIntProp(pszSec, pszKey, pProp->dash); break; case PROP_MASK_WIDTH: WriteStringProp(pszSec, pszKey, pProp->width, pProp->width_spec); break; case PROP_MASK_TRANSPAT: WriteIntProp(pszSec, pszKey, pProp->trans_pat); break; case PROP_MASK_FILL: WriteIntProp(pszSec, pszKey, pProp->fill); break; case PROP_MASK_PEN: WriteIntProp(pszSec, pszKey, pProp->pen); break; case PROP_MASK_RCB_RADIUS: WriteIntProp(pszSec, pszKey, pProp->rcb_radius); break; case PROP_MASK_CURVED: WriteIntProp(pszSec, pszKey, pProp->curved); break; case PROP_MASK_TEXT_FONT: WriteFontProp(pszSec, pszKey, pProp->text_font, pProp->text_style); break; case PROP_MASK_TEXT_JUST: WriteIntProp(pszSec, pszKey, pProp->text_just); break; case PROP_MASK_TEXT_SZ_UNIT: WriteIntProp(pszSec, pszKey, pProp->text_sz_unit); break; case PROP_MASK_UNDERLINE_ON: WriteIntProp(pszSec, pszKey, pProp->underline_on); break; case PROP_MASK_OVERLINE_ON: WriteIntProp(pszSec, pszKey, pProp->overline_on); break; case PROP_MASK_VSPACE: WriteIntProp(pszSec, pszKey, pProp->v_space); break; case PROP_MASK_CTM: WriteCTMProp(pszSec, pszKey, pProp->transformed, &pProp->ctm); break; } } static int ParseAProp(lWhich, pszBuf, pProp) long lWhich; char *pszBuf; struct PropertiesRec *pProp; { switch (lWhich) { case PROP_MASK_AH: return ParseStringProp(pszBuf, &pProp->ah, pProp->ah_spec); case PROP_MASK_AW: return ParseStringProp(pszBuf, &pProp->aw, pProp->aw_spec); case PROP_MASK_ARROW_STYLE: return ParseIntProp(pszBuf, &pProp->arrow_style); case PROP_MASK_COLOR: return ParseStringProp(pszBuf, &pProp->color, pProp->color_str); case PROP_MASK_DASH: return ParseIntProp(pszBuf, &pProp->dash); case PROP_MASK_WIDTH: return ParseStringProp(pszBuf, &pProp->width, pProp->width_spec); case PROP_MASK_TRANSPAT: return ParseIntProp(pszBuf, &pProp->trans_pat); case PROP_MASK_FILL: return ParseIntProp(pszBuf, &pProp->fill); case PROP_MASK_PEN: return ParseIntProp(pszBuf, &pProp->pen); case PROP_MASK_RCB_RADIUS: return ParseIntProp(pszBuf, &pProp->rcb_radius); case PROP_MASK_CURVED: return ParseIntProp(pszBuf, &pProp->curved); case PROP_MASK_TEXT_FONT: return ParseFontProp(pszBuf, &pProp->double_byte, &pProp->text_font, &pProp->text_style); case PROP_MASK_TEXT_JUST: return ParseIntProp(pszBuf, &pProp->text_just); case PROP_MASK_TEXT_SZ_UNIT: return ParseFontSzUnitProp(pszBuf, &pProp->text_sz_unit); case PROP_MASK_UNDERLINE_ON: return ParseIntProp(pszBuf, &pProp->underline_on); case PROP_MASK_OVERLINE_ON: return ParseIntProp(pszBuf, &pProp->overline_on); case PROP_MASK_VSPACE: return ParseIntProp(pszBuf, &pProp->v_space); case PROP_MASK_CTM: return ParseCTMProp(pszBuf, &pProp->transformed, &pProp->ctm); } return FALSE; } static int ReadPropFromIni(pszSec, plMask, pCheckArray, pProp) /* * This routine sets *plMask according to what's in the ini file. * All associated fields in pProp are filled in. * This routine sets pCheckArray->num_cols and pCheckArray->num_rows; * pCheckArray->value is set to NULL. */ char *pszSec; long *plMask; struct CheckArrayRec *pCheckArray; struct PropertiesRec *pProp; { struct PropInfoRec *ppir=NULL; char *pszKey=NULL; char *pszKeys=tgGetProfileString(pszSec, NULL, gszPropIniFile); *plMask = 0L; for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) ppir->checked = FALSE; pCheckArray->num_cols = 1; if (pszKeys == NULL) { strcpy(gszMsgBox, TgLoadString(STID_NO_PROPERTY_TO_PASTE)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } for (pszKey=pszKeys; *pszKey != '\0'; pszKey++) { for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { if (strcmp(pszKey, ppir->key) == 0) { break; } } if (ppir != NULL) { char *pszValue=tgGetProfileString(pszSec, pszKey, gszPropIniFile); if (topSel == NULL && (ppir->bit == PROP_MASK_WIDTH || ppir->bit == PROP_MASK_AW || ppir->bit == PROP_MASK_AH)) { } else { if (ParseAProp(ppir->bit, ((pszValue==NULL)?"":pszValue), pProp)) { ppir->checked = TRUE; pCheckArray->num_rows++; *plMask |= ppir->bit; } } if (pszValue != NULL) tgFreeProfileString(pszValue); } else { sprintf(gszMsgBox, TgLoadString(STID_INVALID_KEY_IN_SEC_OF_INIFILE), pszKey, pszSec, gszPropIniFile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } pszKey += strlen(pszKey); } tgFreeProfileString(pszKeys); return TRUE; } #define COPY_BUTTON 101 #define PASTE_BUTTON 102 #define SAVE_BUTTON 103 #define RESTORE_BUTTON 104 void CleanUpProperties() { struct PropInfoRec *ppir=NULL; for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { UtilFree(ppir->desc); UtilFree(ppir->key); ppir->desc = ppir->key = NULL; } } static void UpdateSavedPropKeys() { char *pszName=NULL; char *pszNames=tgGetProfileString(gszPropSetSec, NULL, gszPropIniFile); int already_updated=FALSE; if (pszNames == NULL) return; for (pszName=pszNames; !already_updated && *pszName != '\0'; pszName++) { char szPropSetSec[MAXSTRING], *pszKeys=NULL; sprintf(szPropSetSec, "%s: %s", gszPropProfilePrefix, pszName); pszKeys = tgGetProfileString(szPropSetSec, NULL, gszPropIniFile); if (pszKeys != NULL) { char *pszKey=NULL; for (pszKey=pszKeys; *pszKey != '\0'; pszKey++) { if (pszKey[0] == '0' && pszKey[1] == 'x') { /* already updated */ already_updated = TRUE; break; } else { char *pszValue=tgGetProfileString(szPropSetSec, pszKey, gszPropIniFile); if (pszValue != NULL) { struct PropInfoRec *ppir_compat=NULL, *ppir=NULL; for (ppir_compat=gstCompatPropInfo, ppir=gstPropInfo; ppir_compat->bit != 0L; ppir_compat++, ppir++) { if (strcmp(ppir_compat->desc, pszKey) == 0) { tgWriteProfileString(szPropSetSec, ppir->key, pszValue, gszPropIniFile); tgWriteProfileString(szPropSetSec, pszKey, NULL, gszPropIniFile); break; } } tgFreeProfileString(pszValue); } } pszKey += strlen(pszKey); } tgFreeProfileString(pszKeys); } pszName += strlen(pszName); } tgFreeProfileString(pszNames); if (!already_updated) { tgWriteProfileString(NULL, NULL, NULL, gszPropIniFile); } } void InitProperties() { struct PropInfoRec *ppir=NULL; /* do not translate -- program constants */ sprintf(gszPropIniFile, "%s%ccutpaste.ini", tgifDir, DIR_SEP); strcpy(gszCopyPasteSec, "Copy/Paste Properties"); strcpy(gszCopyPasteBackupSec, "Copy/Paste Properties - Backup"); strcpy(gszPropSetSec, "Property Set Names"); strcpy(gszPropProfilePrefix, "Property Profile"); for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { if (ppir->key != NULL) return; ppir->desc = UtilStrDup(PropLoadString(ppir->bit)); if (ppir->desc == NULL) FailAllocMessage(); sprintf(gszMsgBox, "0x%08lx", ppir->bit); ppir->key = UtilStrDup(gszMsgBox); if (ppir->key == NULL) FailAllocMessage(); } UpdateSavedPropKeys(); } static void FormatPropForDisplay(lWhich, pProp, ppir, pszBuf) long lWhich; struct PropertiesRec *pProp; struct PropInfoRec *ppir; char *pszBuf; { char font_str[MAXSTRING]; int nLen=0; sprintf(pszBuf, "%s: ", ppir->desc); nLen = strlen(pszBuf); switch (lWhich) { case PROP_MASK_CTM: strcat(pszBuf, "..."); break; case PROP_MASK_COLOR: strcat(pszBuf, pProp->color_str); break; case PROP_MASK_WIDTH_INDEX: sprintf(&pszBuf[nLen], "%1d", pProp->width_index); break; case PROP_MASK_WIDTH: strcat(pszBuf, pProp->width_spec); break; case PROP_MASK_AW: strcat(pszBuf, pProp->aw_spec); break; case PROP_MASK_AH: strcat(pszBuf, pProp->ah_spec); break; case PROP_MASK_TRANSPAT: sprintf(&pszBuf[nLen], "%1d", pProp->trans_pat); break; case PROP_MASK_FILL: sprintf(&pszBuf[nLen], "%1d", pProp->fill); break; case PROP_MASK_PEN: sprintf(&pszBuf[nLen], "%1d", pProp->pen); break; case PROP_MASK_DASH: sprintf(&pszBuf[nLen], "%1d", pProp->dash); break; case PROP_MASK_ARROW_STYLE: sprintf(&pszBuf[nLen], "%1d", pProp->arrow_style); break; case PROP_MASK_CURVED: sprintf(&pszBuf[nLen], "%1d", pProp->curved); break; case PROP_MASK_RCB_RADIUS: sprintf(&pszBuf[nLen], "%1d", pProp->rcb_radius); break; case PROP_MASK_TEXT_JUST: sprintf(&pszBuf[nLen], "%1d", pProp->text_just); break; case PROP_MASK_TEXT_SZ_UNIT: if (showFontSizeInPoints) { sprintf(&pszBuf[nLen], "%1dpt", SzUnitToPointSize(pProp->text_sz_unit)); } else { sprintf(&pszBuf[nLen], "%1d", SzUnitToFontSize(pProp->text_sz_unit)); } break; case PROP_MASK_VSPACE: sprintf(&pszBuf[nLen], "%1d", pProp->v_space); break; case PROP_MASK_UNDERLINE_ON: sprintf(&pszBuf[nLen], "%1d", pProp->underline_on); break; case PROP_MASK_OVERLINE_ON: sprintf(&pszBuf[nLen], "%1d", pProp->overline_on); break; case PROP_MASK_TEXT_FONT: *font_str = '\0'; GetPSFontStr(pProp->text_font, pProp->text_style, font_str); /* font_str starts with the '/' character */ strcat(pszBuf, &font_str[1]); break; } } static int GetPropSelection(pp_dsp_ptr, ppsz_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, p_void) DspList **pp_dsp_ptr; char ***ppsz_entries, *cur_buf; int *pn_num_entries, *pn_marked_index; struct CheckArrayRec **pp_check_array; void *p_void; { struct PropertiesRec *pProp=(struct PropertiesRec *)p_void; struct PropInfoRec *ppir=NULL; int num_rows=0; char **ppsz=NULL; for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { if (ppir->checked) { num_rows++; } } *ppsz_entries = (char**)malloc(num_rows*sizeof(char*)); if (*ppsz_entries == NULL) FailAllocMessage(); memset(*ppsz_entries, 0, num_rows*sizeof(char*)); for (ppir=gstPropInfo, ppsz=(*ppsz_entries); ppir->bit != 0L; ppir++) { if (ppir->checked) { char szBuf[MAXSTRING]; *szBuf = '\0'; FormatPropForDisplay(ppir->bit, pProp, ppir, szBuf); *ppsz = UtilStrDup(szBuf); if ((*ppsz) == NULL) FailAllocMessage(); ppsz++; } } *pn_num_entries = num_rows; return TRUE; } static int DoCopyProperties(pCheckArray, pProp) /* * Returns FALSE if nothing copied. */ struct CheckArrayRec *pCheckArray; struct PropertiesRec *pProp; { struct PropInfoRec *ppir=NULL; int index=0, count=0; char *pszKeys=NULL; tgWriteProfileString(gszCopyPasteSec, NULL, NULL, gszPropIniFile); for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { if (ppir->checked) { if (pCheckArray->value[0][index]) { WritePropToIni(ppir->bit, gszCopyPasteSec, ppir->key, pProp); count++; } index++; } } tgWriteProfileString(NULL, NULL, NULL, gszPropIniFile); if (count == 0) { strcpy(gszMsgBox, TgLoadString(STID_NO_PROPERTY_TO_COPY)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } pszKeys = tgGetProfileString(gszCopyPasteSec, NULL, gszPropIniFile); if (pszKeys != NULL) { int total=(strlen(gszCopyPasteSec)+4), offset=0; char *pszKey=NULL; char *buf=(char*)malloc(total+1); /* sizeof buf is always total+1 */ if (buf == NULL) FailAllocMessage(); memset(buf, 0, total+1); *buf = TGIF_HEADER; sprintf(&buf[1], "[%s]", gszCopyPasteSec); offset = total; for (pszKey=pszKeys; *pszKey != '\0'; pszKey++) { int key_len=strlen(pszKey); char *pszValue=tgGetProfileString(gszCopyPasteSec, pszKey, gszPropIniFile); if (pszValue != NULL) { int value_len=strlen(pszValue); buf = (char*)realloc(buf, total+key_len+value_len+3); if (buf == NULL) FailAllocMessage(); sprintf(&buf[offset], "%s=%s", pszKey, pszValue); offset += key_len+value_len+2; total += key_len+value_len+2; tgFreeProfileString(pszValue); } else { buf = (char*)realloc(buf, total+key_len+3); if (buf == NULL) FailAllocMessage(); sprintf(&buf[offset], "%s=", pszKey); offset += key_len+2; total += key_len+2; } pszKey += key_len; } buf[total] = '\0'; tgFreeProfileString(pszKeys); if (!WriteBufToCutBuffer(buf, total+1, TRUE, FALSE, NULL)) { strcpy(gszMsgBox, TgLoadString(STID_COPY_FAILED_OBJ_MAYBE_TOO_BIG)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { strcpy(gszMsgBox, TgLoadString(STID_COPY_BUFFER_UPDATED)); Msg(gszMsgBox); } free(buf); } return TRUE; } static int PropSetExists(pszPropSet) char *pszPropSet; { int nReturn=FALSE; char *pszKeys=tgGetProfileString(gszPropSetSec, NULL, gszPropIniFile); if (pszKeys != NULL) { char *pszKey=NULL; for (pszKey=pszKeys; *pszKey != '\0'; pszKey++) { if (UtilStrICmp(pszPropSet, pszKey) == 0) { nReturn = TRUE; break; } pszKey += strlen(pszKey); } tgFreeProfileString(pszKeys); } return nReturn; } static int DoSaveProperties(pCheckArray, pProp) /* * Returns FALSE if nothing saved. */ struct CheckArrayRec *pCheckArray; struct PropertiesRec *pProp; { char szPropSet[MAXSTRING], szPropSetSec[MAXSTRING]; struct PropInfoRec *ppir=NULL; int index=0, count=0; *szPropSet = *szPropSetSec = '\0'; strcpy(gszMsgBox, TgLoadString(STID_ENTER_NAME_FOR_PROP_SET)); if (Dialog(gszMsgBox, NULL, szPropSet) == INVALID) return FALSE; UtilTrimBlanks(szPropSet); if (*szPropSet == '\0') return FALSE; if (PropSetExists(szPropSet)) { sprintf(gszMsgBox, TgLoadString(STID_PROP_SET_EXISTS_OVERWRITE_YNC), szPropSet); if (MsgBox(gszMsgBox, TOOL_NAME, YNC_MB) != MB_ID_YES) { return FALSE; } } sprintf(szPropSetSec, "%s: %s", gszPropProfilePrefix, szPropSet); tgWriteProfileString(gszPropSetSec, szPropSet, "", gszPropIniFile); tgWriteProfileString(szPropSetSec, NULL, NULL, gszPropIniFile); for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { if (ppir->checked) { if (pCheckArray->value[0][index]) { WritePropToIni(ppir->bit, szPropSetSec, ppir->key, pProp); count++; } index++; } } tgWriteProfileString(NULL, NULL, NULL, gszPropIniFile); if (count == 0) { strcpy(gszMsgBox, TgLoadString(STID_NO_PROP_TO_SAVE)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } return TRUE; } static int DoPasteProperties(pCheckArray, pProp) /* * Returns FALSE if nothing pasted. */ struct CheckArrayRec *pCheckArray; struct PropertiesRec *pProp; { struct PropInfoRec *ppir=NULL; int index=0, count=0; int paste_sel=FALSE; if ((curChoice == NOTHING || curChoice == VERTEXMODE || curChoice == ROTATEMODE)) { paste_sel = (topSel != NULL); } for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { if (ppir->checked) { if (pCheckArray->value[0][index]) { count++; } index++; } } if (count == 0) { strcpy(gszMsgBox, TgLoadString(STID_NO_PROPERTY_TO_PASTE)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } if (paste_sel) { HighLightReverse(); StartCompositeCmd(); } for (ppir=gstPropInfo, index=0; ppir->bit != 0L; ppir++) { if (ppir->checked) { if (pCheckArray->value[0][index]) { DoPasteAProperty(ppir->bit, pProp); } index++; } } if (paste_sel) { EndCompositeCmd(); HighLightForward(); } return TRUE; } #define COPY_PROP 0 #define PASTE_PROP 1 #define SAVE_PROP 2 #define RESTORE_PROP 3 static int FreePropSelection(pp_dsp_ptr, ppsz_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, btn_id, selected_index, p_void) DspList **pp_dsp_ptr; char ***ppsz_entries, *cur_buf; int *pn_num_entries, *pn_marked_index, btn_id, selected_index; struct CheckArrayRec **pp_check_array; void *p_void; { struct PropertiesRec *pProp=(struct PropertiesRec *)p_void; struct PropInfoRec *ppir=NULL; int nReturn=TRUE; switch ((int)(long)(pProp->userdata)) { case COPY_PROP: if (btn_id == COPY_BUTTON) { nReturn = !DoCopyProperties(*pp_check_array, pProp); } break; case SAVE_PROP: if (btn_id == SAVE_BUTTON) { nReturn = !DoSaveProperties(*pp_check_array, pProp); } break; case PASTE_PROP: if (btn_id == PASTE_BUTTON) { nReturn = !DoPasteProperties(*pp_check_array, pProp); } break; case RESTORE_PROP: if (btn_id == RESTORE_BUTTON) { nReturn = !DoPasteProperties(*pp_check_array, pProp); } break; } if (*ppsz_entries != NULL) { char **ppsz=(*ppsz_entries); for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { if (ppir->checked) { UtilFree(*ppsz); ppsz++; } } free(*ppsz_entries); *ppsz_entries = NULL; } return nReturn; } static int PropSelectionCheckUpdate(pp_dsp_ptr, ppsz_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, col, row, p_void) DspList **pp_dsp_ptr; char ***ppsz_entries, *cur_buf; int *pn_num_entries, *pn_marked_index, col, row; struct CheckArrayRec **pp_check_array; void *p_void; { struct PropertiesRec *pProp=(struct PropertiesRec *)p_void; char *psz=NULL, saved_ch='\0', *buf=NULL; int checked=FALSE; if (ppsz_entries == NULL || *ppsz_entries == NULL || (*ppsz_entries)[row] == NULL || pp_check_array == NULL || (*pp_check_array) == NULL || (*pp_check_array)->value == NULL) { return FALSE; } buf = (*ppsz_entries)[row]; checked = (*pp_check_array)->value[0][row]; psz = strchr(buf, ':'); if (psz != NULL) { saved_ch = *psz; *psz = '\0'; switch ((int)(long)(pProp->userdata)) { case COPY_PROP: sprintf(gszMsgBox, TgLoadString(checked ? STID_WILL_COPY_NAMED_PROP : STID_WILL_NOT_COPY_NAMED_PROP), buf); break; case SAVE_PROP: sprintf(gszMsgBox, TgLoadString(checked ? STID_WILL_SAVE_NAMED_PROP : STID_WILL_NOT_SAVE_NAMED_PROP), buf); break; case PASTE_PROP: sprintf(gszMsgBox, TgLoadString(checked ? STID_WILL_PASTE_NAMED_PROP : STID_WILL_NOT_PASTE_NAMED_PROP), buf); break; case RESTORE_PROP: sprintf(gszMsgBox, TgLoadString(checked ? STID_WILL_RESTORE_NAMED_PROP : STID_WILL_NOT_RESTORE_NAMED_PROP), buf); break; } *psz = saved_ch; } SetStringStatus(gszMsgBox); return TRUE; } static void SelectProperties(pszTitle, nWhich, pCheckArray, pProp) char *pszTitle; int nWhich; struct CheckArrayRec *pCheckArray; struct PropertiesRec *pProp; { char win_name[128]; ResetNamesInfo(); NamesSetTitle(pszTitle); switch (nWhich) { case COPY_PROP: NamesAddButton(TgLoadCachedString(CSTID_COPY), COPY_BUTTON); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); /* ignore double-click and <CR> */ NamesSetDefaultBtnId(COPY_BUTTON, INVALID); NamesSetEntries(NULL, NULL, 0, pCheckArray, TRUE, INVALID, 0); NamesSetStyle(NAMES_SIMPLE_SELECT_NAME, NAMES_LOOP_MANY); NamesSetCallback((GetEntriesFunc*)GetPropSelection, (AfterLoopFunc*)FreePropSelection, (CheckUpdateFunc*)PropSelectionCheckUpdate); sprintf(win_name, TgLoadString(STID_TOOL_COPY_PROP), TOOL_NAME); break; case SAVE_PROP: NamesAddButton(TgLoadCachedString(CSTID_SAVE), SAVE_BUTTON); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); /* ignore double-click and <CR> */ NamesSetDefaultBtnId(SAVE_BUTTON, INVALID); NamesSetEntries(NULL, NULL, 0, pCheckArray, TRUE, INVALID, 0); NamesSetStyle(NAMES_SIMPLE_SELECT_NAME, NAMES_LOOP_MANY); NamesSetCallback((GetEntriesFunc*)GetPropSelection, (AfterLoopFunc*)FreePropSelection, (CheckUpdateFunc*)PropSelectionCheckUpdate); sprintf(win_name, TgLoadString(STID_TOOL_SAVE_PROP), TOOL_NAME); break; case PASTE_PROP: NamesAddButton(TgLoadCachedString(CSTID_PASTE), PASTE_BUTTON); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); /* ignore double-click and <CR> */ NamesSetDefaultBtnId(PASTE_BUTTON, INVALID); NamesSetEntries(NULL, NULL, 0, pCheckArray, TRUE, INVALID, 0); NamesSetStyle(NAMES_SIMPLE_SELECT_NAME, NAMES_LOOP_MANY); NamesSetCallback((GetEntriesFunc*)GetPropSelection, (AfterLoopFunc*)FreePropSelection, (CheckUpdateFunc*)PropSelectionCheckUpdate); sprintf(win_name, TgLoadString(STID_TOOL_PASTE_PROP), TOOL_NAME); break; case RESTORE_PROP: NamesAddButton(TgLoadCachedString(CSTID_RESTORE), RESTORE_BUTTON); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); /* ignore double-click and <CR> */ NamesSetDefaultBtnId(RESTORE_BUTTON, INVALID); NamesSetEntries(NULL, NULL, 0, pCheckArray, TRUE, INVALID, 0); NamesSetStyle(NAMES_SIMPLE_SELECT_NAME, NAMES_LOOP_MANY); NamesSetCallback((GetEntriesFunc*)GetPropSelection, (AfterLoopFunc*)FreePropSelection, (CheckUpdateFunc*)PropSelectionCheckUpdate); sprintf(win_name, TgLoadString(STID_TOOL_RESTORE_PROP), TOOL_NAME); break; } Names(win_name, NULL, NULL, 0, pProp); } static int PrepareToCopyProperties(pProp, lMask, lSkip, pCheckArray) struct PropertiesRec *pProp; long lMask, lSkip; struct CheckArrayRec *pCheckArray; { struct PropInfoRec *ppir=NULL; int index=0, num_rows=0; for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { ppir->checked = FALSE; if ((lMask & ppir->bit) != 0L && (lSkip & ppir->bit) == 0) { num_rows++; } } pCheckArray->num_cols = 1; pCheckArray->num_rows = num_rows; pCheckArray->value = (int**)malloc(sizeof(int*)); if (pCheckArray->value == NULL) FailAllocMessage(); memset(pCheckArray->value, 0, sizeof(int*)); pCheckArray->value[0] = (int*)malloc(num_rows*sizeof(int)); if (pCheckArray->value[0] == NULL) FailAllocMessage(); memset(pCheckArray->value[0], 0, num_rows*sizeof(int)); for (ppir=gstPropInfo, index=0; ppir->bit != 0L; ppir++) { long bit=ppir->bit; if ((lMask & bit) != 0L && (lSkip & bit) == 0) { ppir->checked = TRUE; pCheckArray->value[0][index++] = TRUE; } } return TRUE; } static int PrepareToPasteProperties(pszSec, plMask, pCheckArray, pProp) char *pszSec; struct PropertiesRec *pProp; long *plMask; struct CheckArrayRec *pCheckArray; { struct PropInfoRec *ppir=NULL; int index=0, num_rows=0; for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { ppir->checked = FALSE; } if (!ReadPropFromIni(pszSec, plMask, pCheckArray, pProp)) { return FALSE; } num_rows = pCheckArray->num_rows; pCheckArray->value = (int**)malloc(sizeof(int*)); if (pCheckArray->value == NULL) FailAllocMessage(); memset(pCheckArray->value, 0, sizeof(int*)); pCheckArray->value[0] = (int*)malloc(num_rows*sizeof(int)); if (pCheckArray->value[0] == NULL) FailAllocMessage(); memset(pCheckArray->value[0], 0, num_rows*sizeof(int)); for (ppir=gstPropInfo, index=0; ppir->bit != 0L; ppir++) { long bit=ppir->bit; if (((*plMask) & bit) != 0L) { ppir->checked = TRUE; pCheckArray->value[0][index++] = TRUE; } } return TRUE; } static int SetupProperties(pProp, plMask, plSkip, pCheckArray, nWhich) struct PropertiesRec *pProp; long *plMask, *plSkip; struct CheckArrayRec *pCheckArray; int nWhich; { int copy_sel=FALSE; pProp->userdata = (void*)(long)nWhich; if ((curChoice == NOTHING || curChoice == VERTEXMODE || curChoice == ROTATEMODE)) { if (topSel == NULL) { copy_sel = FALSE; } else if (topSel == botSel) { copy_sel = TRUE; } else { switch (nWhich) { case COPY_PROP: strcpy(gszMsgBox, TgLoadString(STID_SEL_ONLY_ONE_FOR_COPY_PROP)); break; case SAVE_PROP: strcpy(gszMsgBox, TgLoadString(STID_SEL_ONLY_ONE_FOR_SAVE_PROP)); break; } MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } } if (copy_sel) { SetPropMask(topSel->obj, plMask, plSkip, pProp); } else { SetPropMask(NULL, plMask, plSkip, pProp); } /* shouldn't do this if we support multiple objects */ *plSkip = ~((*plMask) | PROP_MASK_WIDTH_INDEX); if (pCheckArray != NULL) { return PrepareToCopyProperties(pProp, *plMask, *plSkip, pCheckArray); } return TRUE; } static void FixMasksForGetProperty(pProp, plMask, plSkip) struct PropertiesRec *pProp; long *plMask, *plSkip; { long lMask=(*plMask); *plSkip |= PROP_MASK_CTM; if ((lMask & PROP_MASK_WIDTH) == PROP_MASK_WIDTH) { int i=0; char *width_spec=pProp->width_spec; if (((lMask & PROP_MASK_AW) == PROP_MASK_AW) && ((lMask & PROP_MASK_AH) == PROP_MASK_AH)) { char *aw_spec=pProp->aw_spec; char *ah_spec=pProp->ah_spec; *plSkip |= (PROP_MASK_WIDTH | PROP_MASK_AW | PROP_MASK_AH); for (i=0; i < maxLineWidths; i++) { if (strcmp(width_spec, curWidthOfLineSpec[i]) == 0 && strcmp(aw_spec, curArrowHeadWSpec[i]) == 0 && strcmp(ah_spec, curArrowHeadHSpec[i]) == 0) { pProp->width_index = i; *plMask |= PROP_MASK_WIDTH_INDEX; break; } } } else { *plSkip |= (PROP_MASK_WIDTH); for (i=0; i < maxLineWidths; i++) { if (strcmp(width_spec, curWidthOfLineSpec[i]) == 0) { pProp->width_index = i; *plMask |= PROP_MASK_WIDTH_INDEX; break; } } } } } void DoGetProperty(target_index) int target_index; { struct PropertiesRec properties; struct PropInfoRec *ppir=NULL; long lMask=0L, lSkip=0L; int index=0; struct SelRec *saved_top_sel=NULL, *saved_bot_sel=NULL; memset(&properties, 0, sizeof(struct PropertiesRec)); if (!SetupProperties(&properties, &lMask, &lSkip, NULL, COPY_PROP)) { return; } FixMasksForGetProperty(&properties, &lMask, &lSkip); HighLightReverse(); saved_top_sel = topSel; saved_bot_sel = botSel; topSel = botSel = NULL; UpdSelBBox(); for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { if ((lMask & ppir->bit) != 0L && (lSkip & ppir->bit) == 0) { if (index == target_index) { /* do something */ DoGetAProperty(ppir->bit, &properties); break; } index++; } } topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); HighLightReverse(); } EditAttrInfo *CreateGetPropertyInfo() { struct PropertiesRec properties; struct PropInfoRec *ppir=NULL; EditAttrInfo *pEditAttrInfo=NULL; long lMask=0L, lSkip=0L; int index=0, num_attrs=0; char **attr_strings=NULL, **status_strings=NULL; pEditAttrInfo = (EditAttrInfo*)malloc(sizeof(EditAttrInfo)); if (pEditAttrInfo == NULL) FailAllocMessage(); memset(pEditAttrInfo, 0, sizeof(EditAttrInfo)); memset(&properties, 0, sizeof(struct PropertiesRec)); if (!SetupProperties(&properties, &lMask, &lSkip, NULL, COPY_PROP)) { return NULL; } FixMasksForGetProperty(&properties, &lMask, &lSkip); for (ppir=gstPropInfo; ppir->bit != 0L; ppir++) { ppir->checked = FALSE; if ((lMask & ppir->bit) != 0L && (lSkip & ppir->bit) == 0) { num_attrs++; } } attr_strings = (char**)malloc(num_attrs*sizeof(char*)); status_strings = (char**)malloc(num_attrs*sizeof(char*)); if (attr_strings == NULL || status_strings == NULL) FailAllocMessage(); memset(attr_strings, 0, num_attrs*sizeof(char*)); memset(status_strings, 0, num_attrs*sizeof(char*)); for (ppir=gstPropInfo, index=0; ppir->bit != 0L; ppir++) { long bit=ppir->bit; if ((lMask & bit) != 0L && (lSkip & bit) == 0) { char *psz=NULL, szBuf[MAXSTRING]; *szBuf = '\0'; FormatPropForDisplay(ppir->bit, &properties, ppir, szBuf); attr_strings[index] = UtilStrDup(szBuf); if (attr_strings[index] == NULL) FailAllocMessage(); if ((psz=strchr(szBuf, ':')) != NULL) { *psz++ = '\0'; UtilTrimBlanks(psz); sprintf(gszMsgBox, TgLoadCachedString(CSTID_GET_NAMED_PROP_FROM_SEL_OBJ), szBuf); status_strings[index] = UtilStrDup(gszMsgBox); if (status_strings[index] == NULL) FailAllocMessage(); } ppir->checked = TRUE; index++; } } pEditAttrInfo->num_attrs = num_attrs; pEditAttrInfo->fore_colors = NULL; pEditAttrInfo->attr_indices = NULL; pEditAttrInfo->attr_names = NULL; pEditAttrInfo->attr_values = NULL; pEditAttrInfo->attr_strings = attr_strings; pEditAttrInfo->status_strings = status_strings; return pEditAttrInfo; } void CopyProperties(nPrompt) int nPrompt; { struct PropertiesRec properties; long lMask=0L, lSkip=0L; struct CheckArrayRec check_array; memset(&properties, 0, sizeof(struct PropertiesRec)); memset(&check_array, 0, sizeof(struct CheckArrayRec)); if (!SetupProperties(&properties, &lMask, &lSkip, &check_array, COPY_PROP)) { return; } tgWriteProfileString(gszCopyPasteSec, NULL, NULL, gszPropIniFile); tgWriteProfileString(NULL, NULL, NULL, gszPropIniFile); if (nPrompt) { SelectProperties(TgLoadString(STID_UNCHECK_PROP_FOR_COPY_DOTS), COPY_PROP, &check_array, &properties); } else { DoCopyProperties(&check_array, &properties); } CleanUpCheckArray(&check_array); } void SaveProperties() { struct PropertiesRec properties; long lMask=0L, lSkip=0L; struct CheckArrayRec check_array; memset(&properties, 0, sizeof(struct PropertiesRec)); memset(&check_array, 0, sizeof(struct CheckArrayRec)); if (!SetupProperties(&properties, &lMask, &lSkip, &check_array, SAVE_PROP)) { return; } SelectProperties(TgLoadString(STID_UNCHECK_PROP_FOR_SAVE_DOTS), SAVE_PROP, &check_array, &properties); CleanUpCheckArray(&check_array); } static int WriteBufToIni(buf, ini_fname) char *buf, *ini_fname; { char *pszSec=buf, *pszKey=NULL, *pszKeyStart=NULL; int len=strlen(pszSec); pszKeyStart = (&buf[len+1]); if (*pszSec == '[' && pszSec[len-1] == ']') { pszSec[len-1] = '\0'; pszSec++; } tgWriteProfileString(pszSec, NULL, NULL, ini_fname); for (pszKey=pszKeyStart; *pszKey != '\0'; pszKey++) { char *psz=strchr(pszKey, '='); if (psz == NULL) { tgWriteProfileString(pszSec, NULL, NULL, ini_fname); tgWriteProfileString(NULL, NULL, NULL, ini_fname); return FALSE; } *psz = '\0'; tgWriteProfileString(pszSec, pszKey, &psz[1], ini_fname); *psz = '='; pszKey += strlen(pszKey); } tgWriteProfileString(NULL, NULL, NULL, ini_fname); return TRUE; } void PasteProperties(nPrompt) int nPrompt; { struct PropertiesRec properties; long lMask=0L, lSkip=0L; struct CheckArrayRec check_array; int len=0, from_selection=FALSE; char *cut_buffer=NULL; cut_buffer = FetchSelectionOrCutBuffer(&len, &from_selection); if (cut_buffer == NULL) { MsgBox(TgLoadString(STID_CUT_BUFFER_EMPTY), TOOL_NAME, INFO_MB); return; } sprintf(gszMsgBox, "[%s]", gszCopyPasteSec); if (((unsigned char)(*cut_buffer)) != TGIF_HEADER || strcmp(&cut_buffer[1], gszMsgBox) != 0) { FreeSelectionOrCutBuffer(cut_buffer, from_selection); MsgBox(TgLoadString(STID_COPY_PROP_BEFORE_PASTE), TOOL_NAME, INFO_MB); return; } if (!WriteBufToIni(&cut_buffer[1], gszPropIniFile)) { strcpy(gszMsgBox, TgLoadString(STID_MALFORMED_CUT_BUF_WHILE_PASTE)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); FreeSelectionOrCutBuffer(cut_buffer, from_selection); return; } FreeSelectionOrCutBuffer(cut_buffer, from_selection); memset(&check_array, 0, sizeof(struct CheckArrayRec)); memset(&properties, 0, sizeof(struct PropertiesRec)); properties.userdata = (void*)PASTE_PROP; if (!PrepareToPasteProperties(gszCopyPasteSec, &lMask, &check_array, &properties)) { return; } lSkip = (~lMask); if (nPrompt) { SelectProperties(TgLoadString(STID_UNCHECK_PROP_FOR_PASTE_DOTS), PASTE_PROP, &check_array, &properties); } else { DoPasteProperties(&check_array, &properties); } CleanUpCheckArray(&check_array); } static int GetPropSetNames(pp_dsp_ptr, ppsz_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, p_void) DspList **pp_dsp_ptr; char ***ppsz_entries, *cur_buf; int *pn_num_entries, *pn_marked_index; struct CheckArrayRec **pp_check_array; void *p_void; { int num_rows=0; char **ppsz=NULL, *pszName=NULL; char *pszNames=tgGetProfileString(gszPropSetSec, NULL, gszPropIniFile); if (pszNames == NULL) { strcpy(gszMsgBox, TgLoadString(STID_NO_PROP_SETS_TO_RESTORE)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } for (pszName=pszNames; *pszName != '\0'; pszName++, num_rows++) { pszName += strlen(pszName); } if (num_rows == 0) { tgWriteProfileString(gszPropSetSec, NULL, NULL, gszPropIniFile); tgWriteProfileString(NULL, NULL, NULL, gszPropIniFile); strcpy(gszMsgBox, TgLoadString(STID_NO_PROP_SETS_TO_RESTORE)); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } *ppsz_entries = (char**)malloc(num_rows*sizeof(char*)); if (*ppsz_entries == NULL) FailAllocMessage(); memset(*ppsz_entries, 0, num_rows*sizeof(char*)); for (pszName=pszNames, ppsz=(*ppsz_entries); *pszName != '\0'; pszName++) { *ppsz = UtilStrDup(pszName); if ((*ppsz) == NULL) FailAllocMessage(); ppsz++; pszName += strlen(pszName); } tgFreeProfileString(pszNames); *pn_num_entries = num_rows; return TRUE; } static int FreePropSetNames(pp_dsp_ptr, ppsz_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, btn_id, selected_index, p_void) DspList **pp_dsp_ptr; char ***ppsz_entries, *cur_buf; int *pn_num_entries, *pn_marked_index, btn_id, selected_index; struct CheckArrayRec **pp_check_array; void *p_void; { int nReturn=TRUE; if (btn_id == BUTTON_OK) { nReturn = FALSE; } if (*ppsz_entries != NULL) { char **ppsz=(*ppsz_entries); int i=0; for (i=0; i < *pn_num_entries; i++) { UtilFree(*ppsz); ppsz++; } free(*ppsz_entries); *ppsz_entries = NULL; } return nReturn; } static int SelectPropSetForRestore(pszTitle, pszPropSet, nPropSetSize) char *pszTitle, *pszPropSet; int nPropSetSize; { char win_name[128]; ResetNamesInfo(); NamesSetTitle(pszTitle); NamesAddButton(TgLoadCachedString(CSTID_OK), BUTTON_OK); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); NamesSetDefaultBtnId(BUTTON_OK, BUTTON_OK); NamesSetEntries(NULL, NULL, 0, NULL, TRUE, INVALID, 0); NamesSetStyle(NAMES_SIMPLE_SELECT_NAME, NAMES_LOOP_MANY); NamesSetCallback((GetEntriesFunc*)GetPropSetNames, (AfterLoopFunc*)FreePropSetNames, NULL); sprintf(win_name, TgLoadString(STID_TOOL_RESTORE_PROP), TOOL_NAME); Names(win_name, NULL, pszPropSet, nPropSetSize, pszPropSet); return (*pszPropSet != '\0'); } void RestoreProperties() { struct PropertiesRec properties; long lMask=0L, lSkip=0L; struct CheckArrayRec check_array; char szPropSet[MAXSTRING], szPropSetSec[MAXSTRING]; memset(&check_array, 0, sizeof(struct CheckArrayRec)); memset(&properties, 0, sizeof(struct PropertiesRec)); properties.userdata = (void*)RESTORE_PROP; *szPropSet = '\0'; if (!SelectPropSetForRestore(TgLoadString(STID_SEL_A_PROP_SET_TO_RESTORE), szPropSet, sizeof(szPropSet))) { return; } sprintf(szPropSetSec, "%s: %s", gszPropProfilePrefix, szPropSet); if (!PrepareToPasteProperties(szPropSetSec, &lMask, &check_array, &properties)) { return; } lSkip = (~lMask); SelectProperties(TgLoadString(STID_UNCHECK_PROP_FOR_RESTORE_DOTS), RESTORE_PROP, &check_array, &properties); CleanUpCheckArray(&check_array); } void BackupCopiedProperties() { char *pszKeys=tgGetProfileString(gszCopyPasteSec, NULL, gszPropIniFile); tgWriteProfileString(gszCopyPasteBackupSec, NULL, NULL, gszPropIniFile); if (pszKeys != NULL) { char *pszKey=NULL; for (pszKey=pszKeys; *pszKey != '\0'; pszKey++) { char *pszValue=tgGetProfileString(gszCopyPasteSec, pszKey, gszPropIniFile); if (pszValue != NULL) { tgWriteProfileString(gszCopyPasteBackupSec, pszKey, pszValue, gszPropIniFile); tgFreeProfileString(pszValue); } pszKey += strlen(pszKey); } tgFreeProfileString(pszKeys); } tgWriteProfileString(NULL, NULL, NULL, gszPropIniFile); } void RestoreCopiedProperties() { char *pszKeys=tgGetProfileString(gszCopyPasteBackupSec, NULL, gszPropIniFile); tgWriteProfileString(gszCopyPasteSec, NULL, NULL, gszPropIniFile); if (pszKeys != NULL) { char *pszKey=NULL; for (pszKey=pszKeys; *pszKey != '\0'; pszKey++) { char *pszValue=tgGetProfileString(gszCopyPasteBackupSec, pszKey, gszPropIniFile); if (pszValue != NULL) { tgWriteProfileString(gszCopyPasteSec, pszKey, pszValue, gszPropIniFile); tgFreeProfileString(pszValue); } pszKey += strlen(pszKey); } tgFreeProfileString(pszKeys); } tgWriteProfileString(NULL, NULL, NULL, gszPropIniFile); } static DspList *IniSectionListing(pszSection, pszIniFile, pnEntries) char *pszSection, *pszIniFile; int *pnEntries; { DspList *dsp_ptr=NULL; char *pszKeys=NULL; int num_entries=0; *pnEntries = 0; if ((pszKeys=tgGetProfileString(pszSection, NULL, pszIniFile)) != NULL) { DspList *pdl=NULL; char *pszKey=NULL; for (pszKey=pszKeys; *pszKey != '\0'; pszKey++) { num_entries++; pszKey += strlen(pszKey); } dsp_ptr = (DspList*)malloc(num_entries*sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, num_entries*sizeof(DspList)); for (pszKey=pszKeys, pdl=dsp_ptr; *pszKey != '\0'; pszKey++, pdl++) { char *pszValue=tgGetProfileString(pszSection, pszKey, pszIniFile); sprintf(gszMsgBox, "%s=%s", pszKey, (pszValue==NULL ? "" : pszValue)); UtilStrCpyN(pdl->itemstr, sizeof(pdl->itemstr), gszMsgBox); /* use the directory field for inherited */ pdl->directory = TRUE; pdl->next = (&pdl[1]); if (pszValue != NULL) tgFreeProfileString(pszValue); pszKey += strlen(pszKey); } tgFreeProfileString(pszKeys); } if (num_entries == 0) return NULL; dsp_ptr[num_entries-1].next = NULL; *pnEntries = num_entries; return dsp_ptr; } static int EditIniSectionStrings(psz_title, dsp_ptr, entries, num_entries, pf_after_loop) char *psz_title, **entries; DspList *dsp_ptr; int num_entries; AfterLoopFunc *pf_after_loop; { char win_name[128]; sprintf(win_name, TgLoadString(STID_TOOL_EDIT_INI_SECTION), TOOL_NAME); ResetNamesInfo(); NamesSetTitle(psz_title); NamesAddButton(TgLoadCachedString(CSTID_OK), BUTTON_OK); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); /* ignore double-click and <CR> */ NamesSetDefaultBtnId(BUTTON_OK, INVALID); NamesSetStyle(NAMES_EDIT_ATTR, NAMES_LOOP_MANY); NamesSetCallback(NULL, pf_after_loop, NULL); NamesSetEntries(dsp_ptr, entries, num_entries, NULL, TRUE, INVALID, 0); return (Names(win_name, NULL, NULL, 0, NULL)==BUTTON_OK); } static int DefEditIniSectionCheck(psz_key, psz_value) char *psz_key, *psz_value; { return TRUE; } static int EditIniSectionDefAfterLoop(pp_dsp_ptr, ppsz_entries, pn_num_entries, pn_marked_index, pp_check_array, cur_buf, btn_id, selected_index, p_void) DspList **pp_dsp_ptr; char ***ppsz_entries, *cur_buf; int *pn_num_entries, *pn_marked_index, btn_id, selected_index; struct CheckArrayRec **pp_check_array; void *p_void; /* * Returns FALSE if the content of the dialogbox is acceptable and * the dialogbox will be closed. * Returns TRUE to tell the dialogbox to continue to loop. In this case, * this function should call MsgBox() to let the user know why * the dialogbox is not closed. */ { int i=0, num_entries=(*pn_num_entries); if (btn_id == BUTTON_CANCEL) { return FALSE; } for (i=0; i < num_entries; i++) { char *psz_key=(*ppsz_entries)[i], *psz_value=NULL; char *psz=strchr(psz_key, '='); *psz = '\0'; psz_value = (&psz[1]); if (!DefEditIniSectionCheck(psz_key, psz_value)) { /* psz_value is not an acceptable value for psz_key */ sprintf(gszMsgBox, TgLoadString(STID_BAD_VALUE_FOR_KEY), psz_key, psz_value); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); *psz = '='; return TRUE; } *psz = '='; } /* everything is fine */ return FALSE; } int EditIniSection(pszTitle, pszSection, pszIniFile, pf_after_loop) char *pszTitle, *pszSection, *pszIniFile; AfterLoopFunc *pf_after_loop; { int num_entries=0, ok_pressed=FALSE; DspList *dsp_ptr=NULL; char sz_title[MAXSTRING], **entries=NULL; dsp_ptr = IniSectionListing(pszSection, pszIniFile, &num_entries); if (dsp_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_NOTHING_TO_EDIT_SEC_EMPTY), pszSection, pszIniFile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } MakeQuiescent(); ignoreDirectoryFlag = TRUE; entries = MakeNameDspItemArray(num_entries, dsp_ptr); ignoreDirectoryFlag = FALSE; if (pszTitle == NULL) { sprintf(sz_title, TgLoadString(STID_EDIT_VALUES_FOR_DOTS), pszSection); } else { UtilStrCpyN(sz_title, sizeof(sz_title), pszTitle); } if (pf_after_loop == NULL) { pf_after_loop = (AfterLoopFunc*)EditIniSectionDefAfterLoop; } if (EditIniSectionStrings(sz_title, dsp_ptr, entries, num_entries, pf_after_loop)) { int i=0; tgWriteProfileString(pszSection, NULL, NULL, pszIniFile); for (i=0; i < num_entries; i++) { char *psz=strchr(entries[i], '='); *psz++ = '\0'; tgWriteProfileString(pszSection, entries[i], psz, pszIniFile); } tgWriteProfileString(NULL, NULL, NULL, pszIniFile); ok_pressed = TRUE; } free(dsp_ptr); free(*entries); free(entries); SetCurChoice(curChoiceBeforeMakeQuiescent); return ok_pressed; } static DspList *IniSectionKeysListing(pszSection, pszIniFile, pnEntries) char *pszSection, *pszIniFile; int *pnEntries; { DspList *dsp_ptr=NULL; char *pszKeys=NULL; int num_entries=0; *pnEntries = 0; if ((pszKeys=tgGetProfileString(pszSection, NULL, pszIniFile)) != NULL) { DspList *pdl=NULL; char *pszKey=NULL; for (pszKey=pszKeys; *pszKey != '\0'; pszKey++) { num_entries++; pszKey += strlen(pszKey); } dsp_ptr = (DspList*)malloc(num_entries*sizeof(DspList)); if (dsp_ptr == NULL) FailAllocMessage(); memset(dsp_ptr, 0, num_entries*sizeof(DspList)); for (pszKey=pszKeys, pdl=dsp_ptr; *pszKey != '\0'; pszKey++, pdl++) { UtilStrCpyN(pdl->itemstr, sizeof(pdl->itemstr), pszKey); /* use the directory field for inherited */ pdl->next = (&pdl[1]); pszKey += strlen(pszKey); } tgFreeProfileString(pszKeys); } if (num_entries == 0) return NULL; dsp_ptr[num_entries-1].next = NULL; *pnEntries = num_entries; return dsp_ptr; } static int SelectFromIniSectionStrings(psz_title, dsp_ptr, entries, num_entries, selected_str, selected_str_sz) char *psz_title, **entries, *selected_str; DspList *dsp_ptr; int num_entries, selected_str_sz; { char win_name[128]; sprintf(win_name, TgLoadString(STID_TOOL_SEL_FROM_INI_SECTION), TOOL_NAME); ResetNamesInfo(); NamesSetTitle(psz_title); NamesAddButton(TgLoadCachedString(CSTID_OK), BUTTON_OK); NamesAddButton(TgLoadCachedString(CSTID_CANCEL), BUTTON_CANCEL); /* ignore double-click and <CR> */ NamesSetDefaultBtnId(BUTTON_OK, BUTTON_OK); NamesSetStyle(NAMES_SIMPLE_SELECT_NAME, NAMES_LOOP_ONCE); NamesSetEntries(dsp_ptr, entries, num_entries, NULL, TRUE, INVALID, 0); return (Names(win_name, NULL, selected_str, selected_str_sz, NULL)==BUTTON_OK); } char *SelectFromIniSection(pszTitle, pszSection, pszIniFile) char *pszTitle, *pszSection, *pszIniFile; { int num_entries=0; DspList *dsp_ptr=NULL; char sz_title[MAXSTRING], **entries=NULL, selected_str[MAXSTRING]; MakeQuiescent(); dsp_ptr = IniSectionKeysListing(pszSection, pszIniFile, &num_entries); if (dsp_ptr == NULL) { sprintf(gszMsgBox, TgLoadString(STID_NOTHING_TO_SEL_SEC_EMPTY), pszSection, pszIniFile); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } ignoreDirectoryFlag = TRUE; entries = MakeNameDspItemArray(num_entries, dsp_ptr); ignoreDirectoryFlag = FALSE; if (pszTitle == NULL) { sprintf(sz_title, TgLoadString(STID_SELECT_A_VALUE_FROM_SEC_DOTS), pszSection); } else { UtilStrCpyN(sz_title, sizeof(sz_title), pszTitle); } *selected_str = '\0'; if (!SelectFromIniSectionStrings(sz_title, dsp_ptr, entries, num_entries, selected_str, sizeof(selected_str))) { *selected_str = '\0'; } free(dsp_ptr); free(*entries); free(entries); return (*selected_str=='\0' ? NULL : UtilStrDup(selected_str)); } /* ----------------------- Recently Used Files ----------------------- */ static int maxRecentFiles=10; void FreeRecentFilesListing(pkvi, max_count) KeyValInfo *pkvi; int max_count; { if (pkvi != NULL) { int i=0; for (i=0; i < max_count; i++) { UtilFree(pkvi[i].key); UtilFree(pkvi[i].value); } free(pkvi); } } KeyValInfo *RecentFilesListing(pnEntries) int *pnEntries; /* * key will store the file name * value will store the full path */ { int i=0, count=0, real_count=0, fix_up=FALSE; char *buf=NULL; KeyValInfo *pkvi=NULL; *pnEntries = 0; if ((buf=tgGetProfileString(gpszRecentFilesSec, gpszRecentFilesCountKey, gszFilesIniFile)) == NULL) { return NULL; } count = atoi(buf); tgFreeProfileString(buf); pkvi = (KeyValInfo*)malloc(count*sizeof(KeyValInfo)); if (pkvi == NULL) FailAllocMessage(); memset(pkvi, 0, count*sizeof(KeyValInfo)); for (i=0; i < count; i++) { char sz_key[40], *psz=NULL; sprintf(sz_key, "%1d", i); buf = tgGetProfileString(gpszRecentFilesSec, sz_key, gszFilesIniFile); /* just in case the ini file is corrupted */ if (buf == NULL) { fix_up = TRUE; continue; } psz = UtilStrRChr(buf, DIR_SEP); if (psz != NULL) { *psz = '\0'; pkvi[real_count].key = UtilStrDup(&psz[1]); if (pkvi[real_count].key == NULL) FailAllocMessage(); *psz = DIR_SEP; } else { pkvi[real_count].key = UtilStrDup(buf); if (pkvi[real_count].key == NULL) FailAllocMessage(); } pkvi[real_count].value = UtilStrDup(buf); if (pkvi[real_count].value == NULL) FailAllocMessage(); if (fix_up) { tgWriteProfileString(gpszRecentFilesSec, sz_key, buf, gszFilesIniFile); } tgFreeProfileString(buf); real_count++; } if (fix_up) { sprintf(gszMsgBox, "%1d", real_count); tgWriteProfileString(gpszRecentFilesSec, gpszRecentFilesCountKey, gszMsgBox, gszFilesIniFile); tgWriteProfileString(NULL, NULL, NULL, gszFilesIniFile); } if (real_count == 0) { FreeRecentFilesListing(pkvi, count); pkvi = NULL; } *pnEntries = real_count; return pkvi; } void OpenARecentlyUsedFile(file_index) int file_index; { int count=0, do_not_save=FALSE, need_to_check_auto_exec=FALSE; KeyValInfo *pkvi=RecentFilesListing(&count); char *psz_url=NULL; if (pkvi == NULL || count == 0 || file_index >= count) return; psz_url = pkvi[file_index].value; if (!BeforeOpenURL(&do_not_save)) { return; } OpenURL(psz_url, do_not_save, &need_to_check_auto_exec); FreeRecentFilesListing(pkvi, count); AfterOpenURL(need_to_check_auto_exec); } void AddARecentlyUsedFile(path) char *path; { int i=0, count=0, move_index=INVALID; KeyValInfo *pkvi=RecentFilesListing(&count); if (count == 0) { /* do not translate -- program constants */ tgWriteProfileString(gpszRecentFilesSec, NULL, NULL, gszFilesIniFile); tgWriteProfileString(gpszRecentFilesSec, "0", path, gszFilesIniFile); } else { char sz_key[40]; for (i=0; i < count; i++) { if (strcmp(path, pkvi[i].value) == 0) { if (i == 0) { FreeRecentFilesListing(pkvi, count); return; } move_index = i; break; } } tgWriteProfileString(gpszRecentFilesSec, NULL, NULL, gszFilesIniFile); if (move_index == INVALID) { if (count+1 > maxRecentFiles) { count = maxRecentFiles-1; } for (i=0; i < count+1; i++) { sprintf(sz_key, "%1d", i); if (i == 0) { tgWriteProfileString(gpszRecentFilesSec, sz_key, path, gszFilesIniFile); } else { tgWriteProfileString(gpszRecentFilesSec, sz_key, pkvi[i-1].value, gszFilesIniFile); } } } else { if (count > maxRecentFiles) { count = maxRecentFiles; } for (i=0; i < count; i++) { sprintf(sz_key, "%1d", i); if (i == 0) { tgWriteProfileString(gpszRecentFilesSec, sz_key, pkvi[move_index].value, gszFilesIniFile); } else if (i <= move_index) { tgWriteProfileString(gpszRecentFilesSec, sz_key, pkvi[i-1].value, gszFilesIniFile); } else { tgWriteProfileString(gpszRecentFilesSec, sz_key, pkvi[i].value, gszFilesIniFile); } } } } sprintf(gszMsgBox, "%1d", (move_index==INVALID ? count+1 : count)); tgWriteProfileString(gpszRecentFilesSec, gpszRecentFilesCountKey, gszMsgBox, gszFilesIniFile); tgWriteProfileString(NULL, NULL, NULL, gszFilesIniFile); FreeRecentFilesListing(pkvi, count); } int InitRecentFiles() { char *c_ptr=NULL; if (PRTGIF) return TRUE; /* do not translate -- program constants */ sprintf(gszFilesIniFile, "%s%cfiles.ini", tgifDir, DIR_SEP); maxRecentFiles = 10; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"MaxRecentFiles")) != NULL) { maxRecentFiles = atoi(c_ptr); if (maxRecentFiles <= 0 || maxRecentFiles > 99) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_XDEF_RNG_USE_ALT_VAL), TOOL_NAME, "MaxRecentFiles", c_ptr, 1, 99, 10); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); maxRecentFiles = 10; } } if ((c_ptr=tgGetProfileString(gpszRecentFilesSec, gpszRecentFilesCountKey, gszFilesIniFile)) != NULL) { int count = atoi(c_ptr); if (count > maxRecentFiles) { sprintf(gszMsgBox, "%1d", maxRecentFiles); tgWriteProfileString(gpszRecentFilesSec, gpszRecentFilesCountKey, gszMsgBox, gszFilesIniFile); tgWriteProfileString(NULL, NULL, NULL, gszFilesIniFile); } tgFreeProfileString(c_ptr); } return TRUE; } void CleanUpRecentFiles() { } /* ----------------------- SimpleString Object ----------------------- */ int CreateSimpleStringObj(buf) char *buf; { SimpleString *ss_ptr=NULL; struct ObjRec *obj_ptr=NULL; ss_ptr = (SimpleString *)malloc(sizeof(SimpleString)); if (ss_ptr == NULL) FailAllocMessage(); memset(ss_ptr, 0, sizeof(SimpleString)); DynStrSet(&ss_ptr->dyn_str, buf); obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); obj_ptr->type = OBJ_SS; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->id = objId++; obj_ptr->detail.ss = ss_ptr; /* * the double-byte stuff is left alone, always single byte for now */ AddObj(NULL, topObj, obj_ptr); return TRUE; } void SaveSimpleStringObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { SimpleString *ss_ptr=ObjPtr->detail.ss; if (fprintf(FP, "simple_string('%s',%1d,%1d,%1d,%1d,\n\t\"", colorMenuItems[ObjPtr->color], ObjPtr->id, ss_ptr->double_byte, ss_ptr->double_byte_mod_bytes, ss_ptr->double_byte_vertical) == EOF) { writeFileFailed = TRUE; } if (ss_ptr->double_byte) { SaveDoubleByteString(FP, ss_ptr->dyn_str.s); } else { SaveString(FP, ss_ptr->dyn_str.s); } if (fprintf(FP, "\")") == EOF) writeFileFailed = TRUE; } void ReadSimpleStringObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { SimpleString *ss_ptr=NULL; char *psz=NULL, *s=NULL, color_str[40], *line=NULL; int id=0, double_byte=FALSE, db_mod_bytes=FALSE, db_vertical=FALSE; int new_alloc=FALSE; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_str, sizeof(color_str)); InitScan(s, "\t\n, "); if (GETINT("simple_string", id, "id") == INVALID || GETINT("simple_string", double_byte, "double_byte") == INVALID || GETINT("simple_string", db_mod_bytes, "db_mod_bytes") == INVALID || GETINT("simple_string", db_vertical, "db_vertical") == INVALID) { return; } if (id >= objId) objId = id+1; if ((line=UtilGetALine(FP)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_UNEXPECTED_EOF_IN_ABORT_READ), scanFileName, scanLineNum, "ReadSimpleStringObj()"); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return; } scanLineNum++; psz = FindChar((int)'"', line); s = ReadString(psz); *(--s) = '\0'; *ObjPtr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (*ObjPtr == NULL) FailAllocMessage(); memset(*ObjPtr, 0, sizeof(struct ObjRec)); ss_ptr = (SimpleString *)malloc(sizeof(SimpleString)); if (ss_ptr == NULL) FailAllocMessage(); memset(ss_ptr, 0, sizeof(SimpleString)); DynStrSet(&ss_ptr->dyn_str, psz); free(line); ss_ptr->double_byte = double_byte; ss_ptr->double_byte_mod_bytes = db_mod_bytes; ss_ptr->double_byte_vertical = db_vertical; (*ObjPtr)->color = QuickFindColorIndex(*ObjPtr, color_str, &new_alloc, TRUE); UtilStrCpyN((*ObjPtr)->color_str, sizeof((*ObjPtr)->color_str), color_str); (*ObjPtr)->id = id; } void FreeSimpleStringObj(ObjPtr) struct ObjRec *ObjPtr; { UtilFree(ObjPtr->detail.ss->dyn_str.s); free(ObjPtr->detail.ss); free(ObjPtr); } /* ----------------------- ReplaceGraphic() ----------------------- */ static void UnInheritAllAttrs(obj_ptr) struct ObjRec *obj_ptr; { struct AttrRec *attr_ptr; for (attr_ptr=obj_ptr->fattr; attr_ptr != NULL; attr_ptr=attr_ptr->next) { if (attr_ptr->inherited) { attr_ptr->inherited = FALSE; } } } void ReplaceGraphic() { struct SelRec *saved_top_sel=NULL, *saved_bot_sel=NULL, *sel_ptr=NULL; struct SelRec *prev_sel=NULL; struct ObjRec *pasted_top_obj=NULL, *pasted_bot_obj=NULL; struct ObjRec *icon_obj_to_replace=NULL; char *orig_cut_buffer=NULL; int sel_ltx=selLtX, sel_lty=selLtY, sel_rbx=selRbX, sel_rby=selRbY; int len=0, changed=FALSE, icons_converted_to_groups=FALSE, icon_count=0; int from_selection=FALSE; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { if (sel_ptr->obj->type == OBJ_ICON) { icon_obj_to_replace = sel_ptr->obj; icon_count++; } } if (icon_count > 1) { MsgBox(TgLoadString(STID_TOO_MANY_ICON_REPLACE_GRAPHIC), TOOL_NAME, INFO_MB); return; } orig_cut_buffer = FetchSelectionOrCutBuffer(&len, &from_selection); if (orig_cut_buffer == NULL) { MsgBox(TgLoadString(STID_CUT_BUFFER_EMPTY), TOOL_NAME, INFO_MB); return; } if (CutBufferType(orig_cut_buffer) != CBF_TGIF_OBJ) { sprintf(gszMsgBox, TgLoadString(STID_CANT_REPLACE_GRAPHIC_NOT_TGIF), TOOL_NAME); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return; } HighLightReverse(); saved_top_sel = topSel; saved_bot_sel = botSel; topSel = botSel = NULL; UpdSelBBox(); if (!GetObjsFromCutBuffer(&orig_cut_buffer[1], len-1, &pasted_top_obj, &pasted_bot_obj)) { FreeSelectionOrCutBuffer(orig_cut_buffer, from_selection); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); HighLightForward(); return; } FreeSelectionOrCutBuffer(orig_cut_buffer, from_selection); if (pasted_top_obj == NULL || pasted_top_obj != pasted_bot_obj) { MsgBox(TgLoadString(STID_CANT_REPLACE_GRAPHIC_TOO_MANY), TOOL_NAME, INFO_MB); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); HighLightForward(); return; } if (pasted_top_obj->type == OBJ_SYM || pasted_top_obj->type == OBJ_ICON || pasted_top_obj->type == OBJ_PIN) { pasted_top_obj->type = OBJ_GROUP; } DelAllAttrs(pasted_top_obj->fattr); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=prev_sel) { struct ObjRec *obj_ptr=sel_ptr->obj, *new_obj_ptr=NULL; int convert_to_group=TRUE; prev_sel = sel_ptr->prev; if (obj_ptr->type == OBJ_TEXT) continue; if (obj_ptr->type == OBJ_ICON && obj_ptr == icon_obj_to_replace) { switch (MsgBox(TgLoadString(STID_Q_CVT_ICON_TO_GRP_IN_REPLACE), TOOL_NAME, YNC_MB)) { case MB_ID_YES: break; case MB_ID_NO: convert_to_group = FALSE; break; case MB_ID_CANCEL: continue; } } changed = TRUE; PrepareToReplaceAnObj(obj_ptr); new_obj_ptr = DupObj(pasted_top_obj); MoveObj(new_obj_ptr, obj_ptr->obbox.ltx-new_obj_ptr->obbox.ltx, obj_ptr->obbox.lty-new_obj_ptr->obbox.lty); new_obj_ptr->prev = obj_ptr->prev; new_obj_ptr->next = obj_ptr->next; new_obj_ptr->fattr = obj_ptr->fattr; new_obj_ptr->lattr = obj_ptr->lattr; obj_ptr->fattr = obj_ptr->lattr = NULL; UnlinkObj(obj_ptr); if (obj_ptr->type == OBJ_SYM) new_obj_ptr->type = OBJ_SYM; UpdAttrOwner(new_obj_ptr->fattr, new_obj_ptr); if (new_obj_ptr->prev == NULL) { curPage->top = topObj = new_obj_ptr; } else { new_obj_ptr->prev->next = new_obj_ptr; } if (new_obj_ptr->next == NULL) { curPage->bot = botObj = new_obj_ptr; } else { new_obj_ptr->next->prev = new_obj_ptr; } AdjObjBBox(new_obj_ptr); ExpandCurSelBBoxes(new_obj_ptr); sel_ptr->obj = new_obj_ptr; if (convert_to_group) { icons_converted_to_groups = TRUE; UnInheritAllAttrs(new_obj_ptr); } else { struct SelRec *tmp_sel=NULL; saved_top_sel = topSel; saved_bot_sel = botSel; topSel = botSel = tmp_sel = SelectThisObject(new_obj_ptr); UpdSelBBox(); MakeIconic(NULL, FALSE); topSel = saved_top_sel; botSel = saved_bot_sel; UpdSelBBox(); free(tmp_sel); } RecordReplaceAnObj(new_obj_ptr); FreeObj(obj_ptr); } EndCompositeCmd(); if (changed) { UpdSelBBox(); RedrawAreas(botObj, sel_ltx-GRID_ABS_SIZE(1), sel_lty-GRID_ABS_SIZE(1), sel_rbx+GRID_ABS_SIZE(1), sel_rby+GRID_ABS_SIZE(1), selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; if (icons_converted_to_groups) { MsgBox(TgLoadString(STID_REPLACE_GRAPHIC_ICON_TO_GROUP), TOOL_NAME, INFO_MB); } else { Msg(TgLoadString(STID_REPLACE_GRAPHIC_DONE)); } } HighLightForward(); } /* ----------------------- ReplaceGraphic() ----------------------- */ static int wordWrapDuringImportTextFile=FALSE; #ifndef A4PAPER static int topMarginForImportTextFile=HALF_INCH; static int leftMarginForImportTextFile=HALF_INCH; static int rightMarginForImportTextFile=HALF_INCH; static int bottomMarginForImportTextFile=HALF_INCH; #else /* A4PAPER */ static int topMarginForImportTextFile=ONE_CM; static int leftMarginForImportTextFile=ONE_CM; static int rightMarginForImportTextFile=ONE_CM; static int bottomMarginForImportTextFile=ONE_CM; #endif /* A4PAPER */ static int DoSetMarginsForImportMultipageTextFile(spec) char *spec; { int top=0, bottom=0, left=0, right=0; char *top_str=NULL, *bottom_str=NULL, *left_str=NULL, *right_str=NULL; UtilTrimBlanks(spec); top_str = strtok(spec, ",\t\n\r"); if (top_str == NULL) return FALSE; bottom_str = strtok(NULL, ",\t\n\r"); if (bottom_str == NULL) return FALSE; left_str = strtok(NULL, ",\t\n\r"); if (left_str == NULL) return FALSE; right_str = strtok(NULL, ",\t\n\r"); if (right_str == NULL) return FALSE; if (GetDimension(top_str, FALSE, &top) && GetDimension(bottom_str, FALSE, &bottom) && GetDimension(left_str, FALSE, &left) && GetDimension(right_str, FALSE, &right)) { topMarginForImportTextFile = top; bottomMarginForImportTextFile = bottom; leftMarginForImportTextFile = left; rightMarginForImportTextFile = right; return TRUE; } return FALSE; } static void GetCurMarginsForImportTextFile(buf) char *buf; { char n_str[MAXSTRING], s_str[MAXSTRING], w_str[MAXSTRING], e_str[MAXSTRING]; float n=((float)topMarginForImportTextFile)*printMag/((float)100.0); float s=((float)bottomMarginForImportTextFile)*printMag/((float)100.0); float w=((float)leftMarginForImportTextFile)*printMag/((float)100.0); float e=((float)rightMarginForImportTextFile)*printMag/((float)100.0); float n_val=(float)0.0, s_val=(float)0.0, w_val=(float)0.0, e_val=(float)0.0; float unit=(float)0.0; switch (gridSystem) { case ENGLISH_GRID: unit = (float)PIX_PER_INCH; n_val = n / unit; s_val = s / unit; w_val = w / unit; e_val = e / unit; FormatFloat(&n_val, n_str); FormatFloat(&s_val, s_str); FormatFloat(&w_val, w_str); FormatFloat(&e_val, e_str); /* do not translate -- program constants */ sprintf(buf, "[ %s in, %s in, %s in, %s in ]", n_str, s_str, w_str, e_str); break; case METRIC_GRID: unit = (float)ONE_CM; n_val = n / unit; s_val = s / unit; w_val = w / unit; e_val = e / unit; FormatFloat(&n_val, n_str); FormatFloat(&s_val, s_str); FormatFloat(&w_val, w_str); FormatFloat(&e_val, e_str); /* do not translate -- program constants */ sprintf(buf, "[ %s cm, %s cm, %s cm, %s cm ]", n_str, s_str, w_str, e_str); break; } } void ImportMultipageTextFile() { } void SetMarginsForImportMultipageTextFile() { char buf[MAXSTRING<<1], spec[MAXSTRING+1], spec_copy[MAXSTRING+1]; GetCurMarginsForImportTextFile(gszMsgBox); sprintf(buf, TgLoadString(STID_CUR_MARGINS_ARE_GIVEN), gszMsgBox); *spec = '\0'; switch (gridSystem) { case ENGLISH_GRID: sprintf(gszMsgBox, TgLoadString(STID_ENTER_MARGINS), "0.5in,0.5in,0.5in,0.5in"); break; case METRIC_GRID: sprintf(gszMsgBox, TgLoadString(STID_ENTER_MARGINS), "1cm,1cm,1cm,1cm"); break; } if (Dialog(gszMsgBox, buf, spec) == INVALID) { return; } UtilStrCpyN(spec_copy, sizeof(spec_copy), spec); if (!DoSetMarginsForImportMultipageTextFile(spec_copy)) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_FOR_4_VAL), spec); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } else { char buf[MAXSTRING<<1]; strcpy(buf, " "); GetCurMarginsForImportTextFile(&buf[4]); TwoLineMsg(TgLoadString(STID_NEW_MARGINS_ARE_GIVEN), buf); } } void ToggleWordWrapDuringImportMultipageTextFile() { wordWrapDuringImportTextFile = !wordWrapDuringImportTextFile; sprintf(gszMsgBox, TgLoadString(wordWrapDuringImportTextFile ? STID_WILL_USE_WORDWRAP_IMPORT_TEXT : STID_NO_WORDWRAP_IMPORT_TEXT), TOOL_NAME); Msg(gszMsgBox); } int RefreshImportMutipageTextFileMenu(menu) TgMenu *menu; { int ok=TRUE; /* Word Wrap */ ok &= TgSetMenuItemCheckById(menu, CMDID_TOGGLEWORDWRAPONIMPORTTEXT, wordWrapDuringImportTextFile); /* * Well, don't know how to do all these yet. Just disable them for now. */ ok &= TgEnableMenuItemById(menu, CMDID_IMPORTMULTIPAGETEXTFILE, FALSE); ok &= TgEnableMenuItemById(menu, CMDID_SETMARGINSONIMPORTTEXT, FALSE); ok &= TgEnableMenuItemById(menu, CMDID_TOGGLEWORDWRAPONIMPORTTEXT, FALSE); return ok; } TgMenu *CreateImportMutipageTextFileMenu(parent_menu, x, y, menu_info, status_str_xlated) TgMenu *parent_menu; int x, y; TgMenuInfo *menu_info; int status_str_xlated; /* ignored, always 0 */ { TgMenu *menu=TgCreateMenuFromMenuInfo(parent_menu, x, y, menu_info, FALSE); if (menu != NULL) { if (!RefreshImportMutipageTextFileMenu(menu)) { return TgDestroyMenu(menu, TRUE); } menu->refresh_proc = ((RefreshMenuFunc*)RefreshImportMutipageTextFileMenu); } return menu; } /* ----------------------- Init and CleanUp ----------------------- */ static void CleanUpCutBufferInfo() { ResetCutBufferInfo(); } void CleanUpCutPaste() { cutBufferIsTgifObj = FALSE; cutBufferIsUTF8 = FALSE; FreeDynStrBuf(&dsCutBuffer); CleanUpCutBufferInfo(); } static void ResetXCutBuffers() { int i=0; for (i=0; gaCutBufferAtom[i] != (Atom)0; i++) { XChangeProperty(mainDisplay, rootWindow, gaCutBufferAtom[i], XA_STRING, 8, PropModeAppend, (unsigned char *)"", 0); } } static void InitCutBufferInfo() { memset(&gSetCutBufferInfo, 0, sizeof(SetCutBufferInfo)); } int InitCutPaste() { char *c_ptr=NULL; int ival=0; InitCutBufferInfo(); pasteFromXSelectionOnly = TRUE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PasteFromXSelectionOnly")) != NULL && UtilStrICmp(c_ptr, "false") == 0) { pasteFromXSelectionOnly = FALSE; } pasteFromSelectionTimeout = 10; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PasteFromSelectionTimeout")) != NULL) { if (sscanf(c_ptr, "%d", &ival) != 1 || ival < 0) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF), TOOL_NAME, "PasteFromSelectionTimeout", c_ptr); fprintf(stderr, "\n"); } else { pasteFromSelectionTimeout = ival; } } debugCopyPaste = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DebugCopyPaste")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { debugCopyPaste = TRUE; } memset(&dsCutBuffer, 0, sizeof(dsCutBuffer)); ResetXCutBuffers(); return TRUE; } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tdgtdraw.c���������������������������������������������������������������������������0000644�0000764�0000764�00000023443�11602233313�014757� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtdraw.c,v 1.7 2011/05/16 16:22:00 william Exp $ */ #define _INCLUDE_FROM_TDGTDRAW_C_ #include "tgifdefs.h" #include "patchlvl.h" #include "tidget.h" #include "button.e" #include "color.e" #include "cursor.e" #include "font.e" #include "menu.e" #include "msg.e" #include "raster.e" #include "rect.e" #include "setup.e" #include "tdgtdraw.e" #include "tidget.e" #include "util.e" static void RedrawTdgtDraw ARGS_DECL((TidgetInfo *pti)); static int TdgtDrawEventHandler ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo *handling_pti)); static int IsTdgtDrawEvent ARGS_DECL((TidgetInfo *pti, XEvent *input, TidgetInfo **ppti_handler_tidget_return)); static void DestroyTdgtDraw ARGS_DECL((TidgetInfo *pti)); static void MapTdgtDraw ARGS_DECL((TidgetInfo *pti)); static void TdgtDrawMoveResize ARGS_DECL((TidgetInfo *pti, int x, int y, int w, int h)); static int TdgtDrawSendCmd ARGS_DECL((TidgetInfo *pti, int cmd_type, int cmd_arg, void *pv_cmd_userdata)); /* --------------------- RedrawTdgtDraw() --------------------- */ static void RedrawTdgtDraw(pti) TidgetInfo *pti; { TdgtDraw *pTdgtDraw=(TdgtDraw*)(pti->tidget); XClearWindow(mainDisplay, pTdgtDraw->pti->tci.win); if (threeDLook) { struct BBRec bbox; SetBBRec(&bbox, 0, 0, pTdgtDraw->pti->tci.win_info.w, pTdgtDraw->pti->tci.win_info.h); switch (pTdgtDraw->pti->tci.state) { case TGBS_NORMAL: break; default: TgDrawThreeDButton(mainDisplay, pTdgtDraw->pti->tci.win, gTidgetManager.gc, &bbox, pTdgtDraw->pti->tci.state, 2, FALSE); TidgetManagerResetGC(); break; } } else { /* * XDrawRectangle(mainDisplay, pTdgtDraw->pti->tci.win, gTidgetManager.gc, * 0, 0, pTdgtDraw->pti->tci.win_info.w, * pTdgtDraw->pti->tci.win_info.h); */ } if (pTdgtDraw->pf_redraw_callback != NULL) { if ((pTdgtDraw->pf_redraw_callback)(pTdgtDraw)) { /* do nothing */ } } } /* --------------------- TdgtDrawEventHandler() --------------------- */ static int TdgtDrawEventHandler(pti, input, handling_pti) TidgetInfo *pti, *handling_pti; XEvent *input; { TdgtDraw *pTdgtDraw=(TdgtDraw*)(pti->tidget); if (pti != handling_pti) return FALSE; if (input->type == Expose) { XEvent ev; RedrawTdgtDraw(pTdgtDraw->pti); while (XCheckWindowEvent(mainDisplay, pTdgtDraw->pti->tci.win, ExposureMask, &ev)) ; } else if (pTdgtDraw->pf_ev_handler_callback != NULL) { return (pTdgtDraw->pf_ev_handler_callback)(pTdgtDraw, input); } return FALSE; } /* --------------------- IsTdgtDrawEvent() --------------------- */ static int IsTdgtDrawEvent(pti, input, ppti_handler_tidget_return) TidgetInfo *pti, **ppti_handler_tidget_return; XEvent *input; { TdgtDraw *pTdgtDraw=(TdgtDraw*)(pti->tidget); if (input->xany.window == pTdgtDraw->pti->tci.win) { *ppti_handler_tidget_return = pti; return TRUE; } return FALSE; } /* --------------------- DestroyTdgtDraw() --------------------- */ static void DestroyTdgtDraw(pti) TidgetInfo *pti; { TdgtDraw *pTdgtDraw=(TdgtDraw*)(pti->tidget); TdgtDrawReset(pTdgtDraw); free(pTdgtDraw); } /* --------------------- MapTdgtDraw() --------------------- */ static void MapTdgtDraw(pti) TidgetInfo *pti; { TdgtDraw *pTdgtDraw=(TdgtDraw*)(pti->tidget); #ifdef MAPBEFORESELECT XMapWindow(mainDisplay, pTdgtDraw->pti->tci.win); XSelectInput(mainDisplay, pTdgtDraw->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | PointerMotionMask | EnterWindowMask | LeaveWindowMask); #else XSelectInput(mainDisplay, pTdgtDraw->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | PointerMotionMask | EnterWindowMask | LeaveWindowMask); XMapWindow(mainDisplay, pTdgtDraw->pti->tci.win); #endif } /* --------------------- TdgtDrawMoveResize() --------------------- */ static void TdgtDrawMoveResize(pti, x, y, w, h) TidgetInfo *pti; int x, y, w, h; { TdgtDraw *pTdgtDraw=(TdgtDraw*)(pti->tidget); /* there should be no need to resize a button */ pTdgtDraw->pti->tci.win_info.x = x; pTdgtDraw->pti->tci.win_info.y = y; pTdgtDraw->pti->tci.win_info.w = w; pTdgtDraw->pti->tci.win_info.h = h; XMoveResizeWindow(mainDisplay, pTdgtDraw->pti->tci.win, x, y, w, h); } /* --------------------- TdgtDrawSendCmd() --------------------- */ static int TdgtDrawSendCmd(pti, cmd_type, cmd_arg, pv_cmd_userdata) TidgetInfo *pti; int cmd_type, cmd_arg; void *pv_cmd_userdata; { TdgtDraw *pTdgtDraw=(TdgtDraw*)(pti->tidget); if (pTdgtDraw->pf_sendcmd_callback != NULL) { return ((pTdgtDraw->pf_sendcmd_callback)(pTdgtDraw, cmd_type, cmd_arg, pv_cmd_userdata)); } return FALSE; } /* --------------------- TdgtDrawReset() --------------------- */ void TdgtDrawReset(pTdgtDraw) TdgtDraw *pTdgtDraw; { if (pTdgtDraw->pf_reset_callback != NULL) { if ((pTdgtDraw->pf_reset_callback)(pTdgtDraw)) { /* do nothing */ } } } /* --------------------- CreateTdgtDraw() --------------------- */ TdgtDraw *CreateTdgtDraw(parent_win, parent_tidgetinfo, ctl_id, x, y, client_w, client_h, h_pad, v_pad, state, pv_userdata) Window parent_win; TidgetInfo *parent_tidgetinfo; int ctl_id, x, y, client_w, client_h, h_pad, v_pad, state; void *pv_userdata; { TdgtDraw *pTdgtDraw=NULL; int w=client_w+(windowPadding<<1)+(h_pad<<1); int h=client_h+(windowPadding<<1)+(v_pad<<1); pTdgtDraw = (TdgtDraw*)malloc(sizeof(TdgtDraw)); if (pTdgtDraw == NULL) FailAllocMessage(); memset(pTdgtDraw, 0, sizeof(TdgtDraw)); pTdgtDraw->pti = NewTidgetInfo(parent_tidgetinfo, TIDGET_TYPE_DRAW, pTdgtDraw, ctl_id, NULL); if ((pTdgtDraw->pti->tci.win=XCreateSimpleWindow(mainDisplay, parent_win, x, y, w, h, brdrW, myBorderPixel, myBgPixel)) == 0) { FailToCreateWindowMessage("CreateTdgtDraw()", NULL, TRUE); } XSelectInput(mainDisplay, pTdgtDraw->pti->tci.win, ButtonReleaseMask | ButtonPressMask | KeyPressMask | ExposureMask | PointerMotionMask | EnterWindowMask | LeaveWindowMask); SetTidgetInfoBasic(pTdgtDraw->pti, TIDGET_TYPE_DRAW, pTdgtDraw, parent_win, x, y, w, h, h_pad, v_pad, state, NULL); TidgetSetCallbacks(pTdgtDraw->pti, RedrawTdgtDraw, TdgtDrawEventHandler, IsTdgtDrawEvent, DestroyTdgtDraw, MapTdgtDraw, TdgtDrawMoveResize, TdgtDrawSendCmd); pTdgtDraw->client_area.x = windowPadding + h_pad; pTdgtDraw->client_area.y = windowPadding + v_pad; pTdgtDraw->client_area.w = w-(windowPadding<<1)-(h_pad<<1); pTdgtDraw->client_area.h = h-(windowPadding<<1)-(v_pad<<1); pTdgtDraw->pv_userdata = pv_userdata; return pTdgtDraw; } /* --------------------- TdgtDrawSetUserData() --------------------- */ int TdgtDrawSetUserData(pTdgtDraw, pv_userdata) TdgtDraw *pTdgtDraw; void *pv_userdata; { pTdgtDraw->pv_userdata = pv_userdata; RedrawTdgtDraw(pTdgtDraw->pti); return TRUE; } /* --------------------- TdgtDrawGetUserData() --------------------- */ char *TdgtDrawGetUserData(pTdgtDraw) TdgtDraw *pTdgtDraw; { return (char*)(pTdgtDraw->pv_userdata); } /* --------------------- TdgtDrawSetState() --------------------- */ int TdgtDrawSetState(pTdgtDraw, new_state) TdgtDraw *pTdgtDraw; int new_state; { int need_to_redraw=(pTdgtDraw->pti->tci.state != new_state); pTdgtDraw->pti->tci.state = new_state; if (need_to_redraw) { RedrawTdgtDraw(pTdgtDraw->pti); } return TRUE; } /* --------------------- TdgtDrawGetState() --------------------- */ int TdgtDrawGetState(pTdgtDraw) TdgtDraw *pTdgtDraw; { return pTdgtDraw->pti->tci.state; } /* --------------------- TdgtDrawSetRedrawCallback() --------------------- */ void TdgtDrawSetRedrawCallback(pTdgtDraw, pf_redraw_callback) TdgtDraw *pTdgtDraw; TdgtDrawRedrawCallbackFunc *pf_redraw_callback; { pTdgtDraw->pf_redraw_callback = pf_redraw_callback; } /* --------------------- TdgtDrawSetEvHandlerCallback() --------------------- */ void TdgtDrawSetEvHandlerCallback(pTdgtDraw, pf_ev_handler_callback) TdgtDraw *pTdgtDraw; TdgtDrawEvHandlerCallbackFunc *pf_ev_handler_callback; { pTdgtDraw->pf_ev_handler_callback = pf_ev_handler_callback; } /* --------------------- TdgtDrawSetResetCallback() --------------------- */ void TdgtDrawSetResetCallback(pTdgtDraw, pf_reset_callback) TdgtDraw *pTdgtDraw; TdgtDrawResetCallbackFunc *pf_reset_callback; { pTdgtDraw->pf_reset_callback = pf_reset_callback; } /* --------------------- TdgtDrawSetSendCmdCallback() --------------------- */ void TdgtDrawSetSendCmdCallback(pTdgtDraw, pf_sendcmd_callback) TdgtDraw *pTdgtDraw; TdgtDrawSendCmdCallbackFunc *pf_sendcmd_callback; { pTdgtDraw->pf_sendcmd_callback = pf_sendcmd_callback; } /* --------------------- Init & Clean Up --------------------- */ int InitTdgtDraw() { return TRUE; } void CleanUpTdgtDraw() { } �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tdgtsedt.e���������������������������������������������������������������������������0000644�0000764�0000764�00000005363�11602233313�014764� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tdgtsedt.e,v 1.6 2011/05/16 16:22:00 william Exp $ */ #ifndef _TDGTSEDT_E_ #define _TDGTSEDT_E_ #include "tidget.h" #define TDGTSEDT_DEF_H_PAD 2 #define TDGTSEDT_DEF_V_PAD 1 /* * A simple edit tidget is left-justitified, single-line, and single-color. */ typedef struct tagTdgtSmplEdit { TidgetInfo *pti; SimpleWinInfo client_area; int font_style; /* can be STYLE_NR, STYLE_BR, STYLE_NI, or STYLE_BI */ int color_index; char color_str[40]; int cursor_shown; int w, h, min_lbearing, max_rextra, x_start; Pixmap text_pixmap; } TdgtSmplEdit; #ifdef _INCLUDE_FROM_TDGTSEDT_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_TDGTSEDT_C_*/ extern void TdgtSmplEditReset ARGS_DECL((TdgtSmplEdit*)); extern TdgtSmplEdit *CreateTdgtSmplEdit ARGS_DECL((Window parent_win, TidgetInfo *parent_tidgetinfo, int ctl_id, int x, int y, int w, int h_pad, int v_pad, char *caption, int font_style, int color_index)); extern int TdgtSmplEditSetText ARGS_DECL((TdgtSmplEdit*, char *str)); extern char *TdgtSmplEditGetText ARGS_DECL((TdgtSmplEdit*)); extern void TdgtSmplEditGetTextFormatInfo ARGS_DECL((TdgtSmplEdit*, TextFormatInfo*)); extern int TdgtSmplEditSetColorIndex ARGS_DECL((TdgtSmplEdit*, int)); extern int TdgtSmplEditGetColorIndex ARGS_DECL((TdgtSmplEdit*)); extern int TdgtSmplEditSetFontStyle ARGS_DECL((TdgtSmplEdit*, int)); extern int TdgtSmplEditGetFontStyle ARGS_DECL((TdgtSmplEdit*)); extern int TdgtSmplEditAppendStr ARGS_DECL((TdgtSmplEdit*, char *str, int len)); extern int TdgtSmplEditDelLastChar ARGS_DECL((TdgtSmplEdit*)); extern void TdgtSmplEditSetFocus ARGS_DECL((TdgtSmplEdit*, int nSet)); extern int InitTdgtSmplEdit ARGS_DECL((void)); extern void CleanUpTdgtSmplEdit ARGS_DECL((void)); #ifdef _INCLUDE_FROM_TDGTSEDT_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_TDGTSEDT_C_*/ #endif /*_TDGTSEDT_E_*/ �����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/tgcwheel.c���������������������������������������������������������������������������0000644�0000764�0000764�00000010517�11602233313�014737� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/tgcwheel.c,v 1.5 2011/06/02 15:53:08 william Exp $ */ #define _INCLUDE_FROM_TGCWHEEL__C_ #include "tgifdefs.h" #include "tidget.h" #include "auxtext.e" #include "dialog.e" #include "font.e" #include "msg.e" #include "setup.e" #include "strtbl.e" #include "tgcwheel.e" #include "tgcwdl.e" #include "tidget.e" #include "util.e" /* --------------------- Init & Clean Up --------------------- */ void TgColorWheel_CleanUp(dpy, win) Display *dpy; Window win; { if (gColorWheelInfo.initialized) { if (gColorWheelInfo.dialogbox_tidgetinfo != NULL) { DestroyTdgtColorWheelDialogBox(dpy, gColorWheelInfo.dialogbox_tidgetinfo); } } if (gColorWheelInfo.hs_pixmap != None) { XFreePixmap(mainDisplay, gColorWheelInfo.hs_pixmap); } if (gColorWheelInfo.v_pixmap != None) { XFreePixmap(mainDisplay, gColorWheelInfo.v_pixmap); } memset(&gColorWheelInfo, 0, sizeof(ColorWheelInfo)); CleanUpTdgtColorWheelDlg(); } int TgColorWheel_Init(dpy, win, arg) Display *dpy; Window win; char *arg; { memset(&gColorWheelInfo, 0, sizeof(ColorWheelInfo)); gColorWheelInfo.hs_pixmap = XCreatePixmap(mainDisplay, rootWindow, HS_WIDTH, HS_HEIGHT, mainDepth); if (arg != NULL) { UtilStrCpyN(gColorWheelInfo.color_str, sizeof(gColorWheelInfo.color_str), arg); } if (gColorWheelInfo.hs_pixmap == None) { FailAllocPixmapMessage(HS_WIDTH, HS_HEIGHT); TgColorWheel_CleanUp(dpy, win); return FALSE; } gColorWheelInfo.v_pixmap = XCreatePixmap(mainDisplay, rootWindow, V_WIDTH, V_HEIGHT, mainDepth); if (gColorWheelInfo.v_pixmap == None) { FailAllocPixmapMessage(V_WIDTH, V_HEIGHT); TgColorWheel_CleanUp(dpy, win); return FALSE; } if (!InitTdgtColorWheelDlg()) { TgColorWheel_CleanUp(dpy, win); return FALSE; } return TRUE; } void CleanUpColorWheel() { TgColorWheel_CleanUp(mainDisplay, drawWindow); } int InitColorWheel() { return TgColorWheel_Init(mainDisplay, drawWindow, NULL); } /* --------------------- TgColorWheel_SendKey --------------------- */ static XComposeStatus c_stat; int TgColorWheel_SendKey(dpy, win, key_ev, buf) Display *dpy; Window win; XKeyEvent *key_ev; char *buf; /* return FALSE means key_ev will be handled without modifications */ { int has_ch=0; char s[80]; KeySym key_sym=(KeySym)0; has_ch = XLookupString(key_ev, s, sizeof(s), &key_sym, &c_stat); TranslateKeys(s, &key_sym); return FALSE; } /* --------------------- TgColorWheel_HandleCntrlSpace --------------------- */ int TgColorWheel_HandleCntrlSpace(dpy, win) Display *dpy; Window win; { if (!gColorWheelInfo.initialized) { gColorWheelInfo.initialized = TRUE; /* create window */ gColorWheelInfo.dialogbox_tidgetinfo = CreateTdgtColorWheelDialogBox(dpy, rootWindow); if (gColorWheelInfo.dialogbox_tidgetinfo == NULL) { /* print a message */ } } if (gColorWheelInfo.dialogbox_tidgetinfo == NULL) { return FALSE; } if (!gColorWheelInfo.mapped) { ShowTdgtColorWheelDialogBox(); TdgtColorWheelDlgLoop(gColorWheelInfo.dialogbox_tidgetinfo); } else { HideTdgtColorWheelDialogBox(); } return FALSE; } /* --------------------- TgColorWheel_HandleCreateText --------------------- */ int TgColorWheel_HandleCreateText(dpy, win) Display *dpy; Window win; { if (gColorWheelInfo.initialized && gColorWheelInfo.mapped) { HideTdgtColorWheelDialogBox(); } return TRUE; } ���������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/Makefile�����������������������������������������������������������������������������0000644�0000764�0000764�00000063444�11602233423�014442� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������# Makefile.in generated by automake 1.10 from Makefile.am. # Makefile. Generated from Makefile.in by configure. # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, # 2003, 2004, 2005, 2006 Free Software Foundation, Inc. # This Makefile.in is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. pkgdatadir = $(datadir)/tgif pkglibdir = $(libdir)/tgif pkgincludedir = $(includedir)/tgif am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd install_sh_DATA = $(install_sh) -c -m 644 install_sh_PROGRAM = $(install_sh) -c install_sh_SCRIPT = $(install_sh) -c INSTALL_HEADER = $(INSTALL_DATA) transform = $(program_transform_name) NORMAL_INSTALL = : PRE_INSTALL = : POST_INSTALL = : NORMAL_UNINSTALL = : PRE_UNINSTALL = : POST_UNINSTALL = : bin_PROGRAMS = tgif$(EXEEXT) subdir = . DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ $(srcdir)/Makefile.in $(srcdir)/config.h.in \ $(top_srcdir)/configure AUTHORS ChangeLog NEWS depcomp \ install-sh missing mkinstalldirs ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 am__aclocal_m4_deps = $(top_srcdir)/configure.ac am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ configure.lineno config.status.lineno mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs CONFIG_HEADER = config.h CONFIG_CLEAN_FILES = am__installdirs = "$(DESTDIR)$(bindir)" "$(DESTDIR)$(tgifdir)" binPROGRAMS_INSTALL = $(INSTALL_PROGRAM) PROGRAMS = $(bin_PROGRAMS) am_tgif_OBJECTS = align.$(OBJEXT) animate.$(OBJEXT) arc.$(OBJEXT) \ attr.$(OBJEXT) auxtext.$(OBJEXT) box.$(OBJEXT) \ button.$(OBJEXT) chat.$(OBJEXT) chinput.$(OBJEXT) \ choice.$(OBJEXT) choose.$(OBJEXT) cli_xcin.$(OBJEXT) \ convkinput.$(OBJEXT) convxim.$(OBJEXT) cmd.$(OBJEXT) \ color.$(OBJEXT) cutpaste.$(OBJEXT) cursor.$(OBJEXT) \ dialog.$(OBJEXT) drawing.$(OBJEXT) dup.$(OBJEXT) \ edit.$(OBJEXT) eps.$(OBJEXT) exec.$(OBJEXT) expr.$(OBJEXT) \ file.$(OBJEXT) font.$(OBJEXT) ftp.$(OBJEXT) grid.$(OBJEXT) \ group.$(OBJEXT) hash.$(OBJEXT) help.$(OBJEXT) http.$(OBJEXT) \ imgproc.$(OBJEXT) import.$(OBJEXT) ini.$(OBJEXT) \ inmethod.$(OBJEXT) list.$(OBJEXT) mainloop.$(OBJEXT) \ mainmenu.$(OBJEXT) mark.$(OBJEXT) markup.$(OBJEXT) \ menu.$(OBJEXT) menuinfo.$(OBJEXT) miniline.$(OBJEXT) \ move.$(OBJEXT) msg.$(OBJEXT) names.$(OBJEXT) \ navigate.$(OBJEXT) nkf.$(OBJEXT) obj.$(OBJEXT) oval.$(OBJEXT) \ page.$(OBJEXT) pattern.$(OBJEXT) pin.$(OBJEXT) \ pngtrans.$(OBJEXT) poly.$(OBJEXT) polygon.$(OBJEXT) \ ps.$(OBJEXT) raster.$(OBJEXT) rcbox.$(OBJEXT) rect.$(OBJEXT) \ remote.$(OBJEXT) rm_intrf.$(OBJEXT) ruler.$(OBJEXT) \ scroll.$(OBJEXT) select.$(OBJEXT) setup.$(OBJEXT) \ shape.$(OBJEXT) shortcut.$(OBJEXT) special.$(OBJEXT) \ spline.$(OBJEXT) stk.$(OBJEXT) stream.$(OBJEXT) \ stretch.$(OBJEXT) strtbl.$(OBJEXT) tangram2.$(OBJEXT) \ tdgtbase.$(OBJEXT) tdgtbmpl.$(OBJEXT) tdgtbrow.$(OBJEXT) \ tdgtbtn.$(OBJEXT) tdgtdraw.$(OBJEXT) tdgtlist.$(OBJEXT) \ tdgtmsg.$(OBJEXT) tdgtsedt.$(OBJEXT) tgif_dbg.$(OBJEXT) \ tgcwheel.$(OBJEXT) tgcwdl.$(OBJEXT) tginssym.$(OBJEXT) \ tgisdl.$(OBJEXT) tgtwb5.$(OBJEXT) tgif.$(OBJEXT) \ tgtwb5dl.$(OBJEXT) tgtwb5xl.$(OBJEXT) tidget.$(OBJEXT) \ tcp.$(OBJEXT) text.$(OBJEXT) util.$(OBJEXT) version.$(OBJEXT) \ vms_comp.$(OBJEXT) wb.$(OBJEXT) wb1.$(OBJEXT) wb2.$(OBJEXT) \ wb3.$(OBJEXT) wb_buff.$(OBJEXT) wb_mcast.$(OBJEXT) \ wb_seg.$(OBJEXT) xbitmap.$(OBJEXT) xpixmap.$(OBJEXT) \ xprtfltr.$(OBJEXT) z_intrf.$(OBJEXT) tgif_OBJECTS = $(am_tgif_OBJECTS) tgif_DEPENDENCIES = DEFAULT_INCLUDES = -I. depcomp = $(SHELL) $(top_srcdir)/depcomp am__depfiles_maybe = depfiles COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) CCLD = $(CC) LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ SOURCES = $(tgif_SOURCES) DIST_SOURCES = $(tgif_SOURCES) am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; am__vpath_adj = case $$p in \ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ *) f=$$p;; \ esac; am__strip_dir = `echo $$p | sed -e 's|^.*/||'`; tgifDATA_INSTALL = $(INSTALL_DATA) DATA = $(tgif_DATA) ETAGS = etags CTAGS = ctags DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) am__remove_distdir = \ { test ! -d $(distdir) \ || { find $(distdir) -type d ! -perm -200 -exec chmod u+w {} ';' \ && rm -fr $(distdir); }; } DIST_ARCHIVES = $(distdir).tar.gz GZIP_ENV = --best distuninstallcheck_listfiles = find . -type f -print distcleancheck_listfiles = find . -type f -print ACLOCAL = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run aclocal-1.10 AMTAR = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run tar AUTOCONF = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run autoconf AUTOHEADER = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run autoheader AUTOMAKE = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run automake-1.10 AWK = gawk CC = gcc CCDEPMODE = depmode=gcc3 CFLAGS = -DVERSION=\"$(VERSION)\" -DPROG="\"$(PACKAGE)\"" \ -Wall -I/usr/X11R6/include -DHAVE_CONFIG_H -DTGIF_PATH=\"$(TGIFDIR)\" -DPSFILE_MOD=0664 -DLOCALEDIR=\"/usr/share/locale\" -DTELEPORT_ATTR=\"warp_to=\" -DTMP_DIR=\"/tmp/\" -DLAUNCH_ATTR=\"launch=\" -DEXEC_ATTR=\"exec=\" -DEPSF_FILE_EXT=\"eps\" -DPS_FILE_EXT=\"ps\" -DXBM_FILE_EXT=\"xbm\" -DXPM_FILE_EXT=\"xpm\" -DOBJ_FILE_EXT=\"obj\" -DSYM_FILE_EXT=\"sym\" -DTEXT_FILE_EXT=\"txt\" -DPIN_FILE_EXT=\"pin\" -DNETLIST_FILE_EXT=\"net\" -DCOMP_FILE_EXT=\"cmp\" -D_BACKGROUND_DONT_FORK -D_USE_XDRAWPOINT_TO_PUT_A_POINT -D_USE_PS_ADOBE_STRING=\"3.0/3.0\" -D_DONT_USE_MKTEMP -D_DONT_REENCODE=\"FFDingbests:ZapfDingbats\" -DDEFATTRGROUP=\"TANGRAM-II:Declaration:Events:Messages:Rewards:Initialization:Watches\" -D_NO_NKF -D_NO_CHINPUT -D_NO_XCIN -DUSE_XT_INITIALIZE -D_NO_LOCALE_SUPPORT CPP = gcc -E CPPFLAGS = CYGPATH_W = echo DEFS = -DHAVE_CONFIG_H DEPDIR = .deps ECHO_C = ECHO_N = -n ECHO_T = EGREP = /bin/grep -E EXEEXT = GREP = /bin/grep INSTALL = /usr/bin/install -c INSTALL_DATA = ${INSTALL} -m 644 INSTALL_PROGRAM = ${INSTALL} INSTALL_SCRIPT = ${INSTALL} INSTALL_STRIP_PROGRAM = $(install_sh) -c -s LDFLAGS = LIBOBJS = LIBS = -lpthread -lz -lm -lidn -ldl -lnsl -lXt -lX11 LTLIBOBJS = MAKEINFO = ${SHELL} /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/missing --run makeinfo MKDIR_P = /bin/mkdir -p OBJEXT = o PACKAGE = tgif PACKAGE_BUGREPORT = bill.cheng@acm.org PACKAGE_NAME = tgif PACKAGE_STRING = tgif 4.2.5 PACKAGE_TARNAME = tgif PACKAGE_VERSION = 4.2.5 PATH_SEPARATOR = : POW_LIB = SET_MAKE = SHELL = /bin/sh STRIP = VERSION = 4.2.5 XMKMF = abs_builddir = /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5 abs_srcdir = /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5 abs_top_builddir = /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5 abs_top_srcdir = /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5 ac_ct_CC = gcc am__include = include am__leading_dot = . am__quote = am__tar = ${AMTAR} chof - "$$tardir" am__untar = ${AMTAR} xf - bindir = ${exec_prefix}/bin build_alias = builddir = . datadir = ${datarootdir} datarootdir = ${prefix}/share docdir = ${datarootdir}/doc/${PACKAGE_TARNAME} dvidir = ${docdir} exec_prefix = ${prefix} host_alias = htmldir = ${docdir} includedir = ${prefix}/include infodir = ${datarootdir}/info install_sh = $(SHELL) /merlot/home/william/cvs/bc-src/tgif/OLD/tgif-4.2.5/tgif-QPL-4.2.5/install-sh libdir = ${exec_prefix}/lib libexecdir = ${exec_prefix}/libexec localedir = ${datarootdir}/locale localstatedir = ${prefix}/var mandir = ${datarootdir}/man mkdir_p = /bin/mkdir -p oldincludedir = /usr/include pdfdir = ${docdir} prefix = /usr/local program_transform_name = s,x,x, psdir = ${docdir} sbindir = ${exec_prefix}/sbin sharedstatedir = ${prefix}/com srcdir = . sysconfdir = ${prefix}/etc target_alias = top_builddir = . top_srcdir = . # # @(#)$Header: /mm2/home/cvs/bc-src/tgif/Makefile.am,v 1.21 2011/01/18 05:17:27 william Exp $ # AUTOMAKE_OPTIONS = foreign TGIFDIR = $(libdir)/X11/tgif tgif_SOURCES = \ align.c animate.c arc.c attr.c auxtext.c \ box.c button.c \ chat.c chinput.c choice.c choose.c cli_xcin.c \ convkinput.c convxim.c cmd.c color.c cutpaste.c \ cursor.c \ dialog.c drawing.c dup.c \ edit.c eps.c exec.c expr.c \ file.c font.c ftp.c \ grid.c group.c \ hash.c help.c http.c \ imgproc.c import.c ini.c inmethod.c \ list.c \ mainloop.c mainmenu.c mark.c markup.c menu.c \ menuinfo.c miniline.c move.c msg.c \ names.c navigate.c nkf.c \ obj.c oval.c \ page.c pattern.c pin.c pngtrans.c poly.c polygon.c ps.c \ raster.c rcbox.c rect.c remote.c rm_intrf.c ruler.c \ scroll.c select.c setup.c shape.c shortcut.c \ special.c spline.c stk.c stream.c stretch.c \ strtbl.c \ tangram2.c tdgtbase.c tdgtbmpl.c tdgtbrow.c tdgtbtn.c tdgtdraw.c \ tdgtlist.c tdgtmsg.c tdgtsedt.c tgif_dbg.c tgcwheel.c \ tgcwdl.c tginssym.c tgisdl.c tgtwb5.c tgif.c tgtwb5dl.c \ tgtwb5xl.c tidget.c tcp.c text.c \ util.c \ version.c vms_comp.c \ wb.c wb1.c wb2.c wb3.c wb_buff.c wb_mcast.c \ wb_seg.c \ xbitmap.c xpixmap.c xprtfltr.c \ z_intrf.c tgif_LDADD = -L/usr/X11R6/lib -lXext -lX11 -lXt -lSM -lICE -lXmu -lm -lz tgifdir = $(TGIFDIR) tgif_DATA = tgif.Xdefaults tgificon.eps tgificon.obj tgificon.xbm tgificon.xpm tgif.gif tangram.sym eq4.sym eq4-2x.sym eq4-ps2epsi.sym eq4-epstool.sym eq4xpm.sym eq4-lyx-ps2epsi.sym eq4xpm-land.sym eq4png.sym eq4jpg.sym eq4-2x-jpg.sym eq4-2x-nowin-jpg.sym keys.obj Copyright License all: config.h $(MAKE) $(AM_MAKEFLAGS) all-am .SUFFIXES: .SUFFIXES: .c .o .obj am--refresh: @: $(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps) @for dep in $?; do \ case '$(am__configure_deps)' in \ *$$dep*) \ echo ' cd $(srcdir) && $(AUTOMAKE) --foreign '; \ cd $(srcdir) && $(AUTOMAKE) --foreign \ && exit 0; \ exit 1;; \ esac; \ done; \ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ cd $(top_srcdir) && \ $(AUTOMAKE) --foreign Makefile .PRECIOUS: Makefile Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status @case '$?' in \ *config.status*) \ echo ' $(SHELL) ./config.status'; \ $(SHELL) ./config.status;; \ *) \ echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ esac; $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) $(SHELL) ./config.status --recheck $(top_srcdir)/configure: $(am__configure_deps) cd $(srcdir) && $(AUTOCONF) $(ACLOCAL_M4): $(am__aclocal_m4_deps) cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) config.h: stamp-h1 @if test ! -f $@; then \ rm -f stamp-h1; \ $(MAKE) $(AM_MAKEFLAGS) stamp-h1; \ else :; fi stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status @rm -f stamp-h1 cd $(top_builddir) && $(SHELL) ./config.status config.h $(srcdir)/config.h.in: $(am__configure_deps) cd $(top_srcdir) && $(AUTOHEADER) rm -f stamp-h1 touch $@ distclean-hdr: -rm -f config.h stamp-h1 install-binPROGRAMS: $(bin_PROGRAMS) @$(NORMAL_INSTALL) test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" @list='$(bin_PROGRAMS)'; for p in $$list; do \ p1=`echo $$p|sed 's/$(EXEEXT)$$//'`; \ if test -f $$p \ ; then \ f=`echo "$$p1" | sed 's,^.*/,,;$(transform);s/$$/$(EXEEXT)/'`; \ echo " $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) '$$p' '$(DESTDIR)$(bindir)/$$f'"; \ $(INSTALL_PROGRAM_ENV) $(binPROGRAMS_INSTALL) "$$p" "$(DESTDIR)$(bindir)/$$f" || exit 1; \ else :; fi; \ done uninstall-binPROGRAMS: @$(NORMAL_UNINSTALL) @list='$(bin_PROGRAMS)'; for p in $$list; do \ f=`echo "$$p" | sed 's,^.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/'`; \ echo " rm -f '$(DESTDIR)$(bindir)/$$f'"; \ rm -f "$(DESTDIR)$(bindir)/$$f"; \ done clean-binPROGRAMS: -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) tgif$(EXEEXT): $(tgif_OBJECTS) $(tgif_DEPENDENCIES) @rm -f tgif$(EXEEXT) $(LINK) $(tgif_OBJECTS) $(tgif_LDADD) $(LIBS) mostlyclean-compile: -rm -f *.$(OBJEXT) distclean-compile: -rm -f *.tab.c include ./$(DEPDIR)/align.Po include ./$(DEPDIR)/animate.Po include ./$(DEPDIR)/arc.Po include ./$(DEPDIR)/attr.Po include ./$(DEPDIR)/auxtext.Po include ./$(DEPDIR)/box.Po include ./$(DEPDIR)/button.Po include ./$(DEPDIR)/chat.Po include ./$(DEPDIR)/chinput.Po include ./$(DEPDIR)/choice.Po include ./$(DEPDIR)/choose.Po include ./$(DEPDIR)/cli_xcin.Po include ./$(DEPDIR)/cmd.Po include ./$(DEPDIR)/color.Po include ./$(DEPDIR)/convkinput.Po include ./$(DEPDIR)/convxim.Po include ./$(DEPDIR)/cursor.Po include ./$(DEPDIR)/cutpaste.Po include ./$(DEPDIR)/dialog.Po include ./$(DEPDIR)/drawing.Po include ./$(DEPDIR)/dup.Po include ./$(DEPDIR)/edit.Po include ./$(DEPDIR)/eps.Po include ./$(DEPDIR)/exec.Po include ./$(DEPDIR)/expr.Po include ./$(DEPDIR)/file.Po include ./$(DEPDIR)/font.Po include ./$(DEPDIR)/ftp.Po include ./$(DEPDIR)/grid.Po include ./$(DEPDIR)/group.Po include ./$(DEPDIR)/hash.Po include ./$(DEPDIR)/help.Po include ./$(DEPDIR)/http.Po include ./$(DEPDIR)/imgproc.Po include ./$(DEPDIR)/import.Po include ./$(DEPDIR)/ini.Po include ./$(DEPDIR)/inmethod.Po include ./$(DEPDIR)/list.Po include ./$(DEPDIR)/mainloop.Po include ./$(DEPDIR)/mainmenu.Po include ./$(DEPDIR)/mark.Po include ./$(DEPDIR)/markup.Po include ./$(DEPDIR)/menu.Po include ./$(DEPDIR)/menuinfo.Po include ./$(DEPDIR)/miniline.Po include ./$(DEPDIR)/move.Po include ./$(DEPDIR)/msg.Po include ./$(DEPDIR)/names.Po include ./$(DEPDIR)/navigate.Po include ./$(DEPDIR)/nkf.Po include ./$(DEPDIR)/obj.Po include ./$(DEPDIR)/oval.Po include ./$(DEPDIR)/page.Po include ./$(DEPDIR)/pattern.Po include ./$(DEPDIR)/pin.Po include ./$(DEPDIR)/pngtrans.Po include ./$(DEPDIR)/poly.Po include ./$(DEPDIR)/polygon.Po include ./$(DEPDIR)/ps.Po include ./$(DEPDIR)/raster.Po include ./$(DEPDIR)/rcbox.Po include ./$(DEPDIR)/rect.Po include ./$(DEPDIR)/remote.Po include ./$(DEPDIR)/rm_intrf.Po include ./$(DEPDIR)/ruler.Po include ./$(DEPDIR)/scroll.Po include ./$(DEPDIR)/select.Po include ./$(DEPDIR)/setup.Po include ./$(DEPDIR)/shape.Po include ./$(DEPDIR)/shortcut.Po include ./$(DEPDIR)/special.Po include ./$(DEPDIR)/spline.Po include ./$(DEPDIR)/stk.Po include ./$(DEPDIR)/stream.Po include ./$(DEPDIR)/stretch.Po include ./$(DEPDIR)/strtbl.Po include ./$(DEPDIR)/tangram2.Po include ./$(DEPDIR)/tcp.Po include ./$(DEPDIR)/tdgtbase.Po include ./$(DEPDIR)/tdgtbmpl.Po include ./$(DEPDIR)/tdgtbrow.Po include ./$(DEPDIR)/tdgtbtn.Po include ./$(DEPDIR)/tdgtdraw.Po include ./$(DEPDIR)/tdgtlist.Po include ./$(DEPDIR)/tdgtmsg.Po include ./$(DEPDIR)/tdgtsedt.Po include ./$(DEPDIR)/text.Po include ./$(DEPDIR)/tgcwdl.Po include ./$(DEPDIR)/tgcwheel.Po include ./$(DEPDIR)/tgif.Po include ./$(DEPDIR)/tgif_dbg.Po include ./$(DEPDIR)/tginssym.Po include ./$(DEPDIR)/tgisdl.Po include ./$(DEPDIR)/tgtwb5.Po include ./$(DEPDIR)/tgtwb5dl.Po include ./$(DEPDIR)/tgtwb5xl.Po include ./$(DEPDIR)/tidget.Po include ./$(DEPDIR)/util.Po include ./$(DEPDIR)/version.Po include ./$(DEPDIR)/vms_comp.Po include ./$(DEPDIR)/wb.Po include ./$(DEPDIR)/wb1.Po include ./$(DEPDIR)/wb2.Po include ./$(DEPDIR)/wb3.Po include ./$(DEPDIR)/wb_buff.Po include ./$(DEPDIR)/wb_mcast.Po include ./$(DEPDIR)/wb_seg.Po include ./$(DEPDIR)/xbitmap.Po include ./$(DEPDIR)/xpixmap.Po include ./$(DEPDIR)/xprtfltr.Po include ./$(DEPDIR)/z_intrf.Po .c.o: $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po # source='$<' object='$@' libtool=no \ # DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) \ # $(COMPILE) -c $< .c.obj: $(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po # source='$<' object='$@' libtool=no \ # DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) \ # $(COMPILE) -c `$(CYGPATH_W) '$<'` install-tgifDATA: $(tgif_DATA) @$(NORMAL_INSTALL) test -z "$(tgifdir)" || $(MKDIR_P) "$(DESTDIR)$(tgifdir)" @list='$(tgif_DATA)'; for p in $$list; do \ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ f=$(am__strip_dir) \ echo " $(tgifDATA_INSTALL) '$$d$$p' '$(DESTDIR)$(tgifdir)/$$f'"; \ $(tgifDATA_INSTALL) "$$d$$p" "$(DESTDIR)$(tgifdir)/$$f"; \ done uninstall-tgifDATA: @$(NORMAL_UNINSTALL) @list='$(tgif_DATA)'; for p in $$list; do \ f=$(am__strip_dir) \ echo " rm -f '$(DESTDIR)$(tgifdir)/$$f'"; \ rm -f "$(DESTDIR)$(tgifdir)/$$f"; \ done ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ mkid -fID $$unique tags: TAGS TAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \ test -n "$$unique" || unique=$$empty_fix; \ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ $$tags $$unique; \ fi ctags: CTAGS CTAGS: $(HEADERS) $(SOURCES) config.h.in $(TAGS_DEPENDENCIES) \ $(TAGS_FILES) $(LISP) tags=; \ here=`pwd`; \ list='$(SOURCES) $(HEADERS) config.h.in $(LISP) $(TAGS_FILES)'; \ unique=`for i in $$list; do \ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ done | \ $(AWK) ' { files[$$0] = 1; } \ END { for (i in files) print i; }'`; \ test -z "$(CTAGS_ARGS)$$tags$$unique" \ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ $$tags $$unique GTAGS: here=`$(am__cd) $(top_builddir) && pwd` \ && cd $(top_srcdir) \ && gtags -i $(GTAGS_ARGS) $$here distclean-tags: -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags distdir: $(DISTFILES) $(am__remove_distdir) test -d $(distdir) || mkdir $(distdir) @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ list='$(DISTFILES)'; \ dist_files=`for file in $$list; do echo $$file; done | \ sed -e "s|^$$srcdirstrip/||;t" \ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ case $$dist_files in \ */*) $(MKDIR_P) `echo "$$dist_files" | \ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ sort -u` ;; \ esac; \ for file in $$dist_files; do \ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ if test -d $$d/$$file; then \ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \ fi; \ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \ else \ test -f $(distdir)/$$file \ || cp -p $$d/$$file $(distdir)/$$file \ || exit 1; \ fi; \ done -find $(distdir) -type d ! -perm -777 -exec chmod a+rwx {} \; -o \ ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ || chmod -R a+r $(distdir) dist-gzip: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) dist-bzip2: distdir tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 $(am__remove_distdir) dist-tarZ: distdir tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z $(am__remove_distdir) dist-shar: distdir shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz $(am__remove_distdir) dist-zip: distdir -rm -f $(distdir).zip zip -rq $(distdir).zip $(distdir) $(am__remove_distdir) dist dist-all: distdir tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz $(am__remove_distdir) # This target untars the dist file and tries a VPATH configuration. Then # it guarantees that the distribution is self-contained by making another # tarfile. distcheck: dist case '$(DIST_ARCHIVES)' in \ *.tar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).tar.gz | $(am__untar) ;;\ *.tar.bz2*) \ bunzip2 -c $(distdir).tar.bz2 | $(am__untar) ;;\ *.tar.Z*) \ uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ *.shar.gz*) \ GZIP=$(GZIP_ENV) gunzip -c $(distdir).shar.gz | unshar ;;\ *.zip*) \ unzip $(distdir).zip ;;\ esac chmod -R a-w $(distdir); chmod a+w $(distdir) mkdir $(distdir)/_build mkdir $(distdir)/_inst chmod a-w $(distdir) dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ && cd $(distdir)/_build \ && ../configure --srcdir=.. --prefix="$$dc_install_base" \ $(DISTCHECK_CONFIGURE_FLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) \ && $(MAKE) $(AM_MAKEFLAGS) dvi \ && $(MAKE) $(AM_MAKEFLAGS) check \ && $(MAKE) $(AM_MAKEFLAGS) install \ && $(MAKE) $(AM_MAKEFLAGS) installcheck \ && $(MAKE) $(AM_MAKEFLAGS) uninstall \ && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ distuninstallcheck \ && chmod -R a-w "$$dc_install_base" \ && ({ \ (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ } || { rm -rf "$$dc_destdir"; exit 1; }) \ && rm -rf "$$dc_destdir" \ && $(MAKE) $(AM_MAKEFLAGS) dist \ && rm -rf $(DIST_ARCHIVES) \ && $(MAKE) $(AM_MAKEFLAGS) distcleancheck $(am__remove_distdir) @(echo "$(distdir) archives ready for distribution: "; \ list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' distuninstallcheck: @cd $(distuninstallcheck_dir) \ && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ || { echo "ERROR: files left after uninstall:" ; \ if test -n "$(DESTDIR)"; then \ echo " (check DESTDIR support)"; \ fi ; \ $(distuninstallcheck_listfiles) ; \ exit 1; } >&2 distcleancheck: distclean @if test '$(srcdir)' = . ; then \ echo "ERROR: distcleancheck can only run from a VPATH build" ; \ exit 1 ; \ fi @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ || { echo "ERROR: files left in build directory after distclean:" ; \ $(distcleancheck_listfiles) ; \ exit 1; } >&2 check-am: all-am check: check-am all-am: Makefile $(PROGRAMS) $(DATA) config.h installdirs: for dir in "$(DESTDIR)$(bindir)" "$(DESTDIR)$(tgifdir)"; do \ test -z "$$dir" || $(MKDIR_P) "$$dir"; \ done install: install-am install-exec: install-exec-am install-data: install-data-am uninstall: uninstall-am install-am: all-am @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am installcheck: installcheck-am install-strip: $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ `test -z '$(STRIP)' || \ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install mostlyclean-generic: clean-generic: distclean-generic: -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) maintainer-clean-generic: @echo "This command is intended for maintainers to use" @echo "it deletes files that may require special tools to rebuild." clean: clean-am clean-am: clean-binPROGRAMS clean-generic mostlyclean-am distclean: distclean-am -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf ./$(DEPDIR) -rm -f Makefile distclean-am: clean-am distclean-compile distclean-generic \ distclean-hdr distclean-tags dvi: dvi-am dvi-am: html: html-am info: info-am info-am: install-data-am: install-tgifDATA install-dvi: install-dvi-am install-exec-am: install-binPROGRAMS install-html: install-html-am install-info: install-info-am install-man: install-pdf: install-pdf-am install-ps: install-ps-am installcheck-am: maintainer-clean: maintainer-clean-am -rm -f $(am__CONFIG_DISTCLEAN_FILES) -rm -rf $(top_srcdir)/autom4te.cache -rm -rf ./$(DEPDIR) -rm -f Makefile maintainer-clean-am: distclean-am maintainer-clean-generic mostlyclean: mostlyclean-am mostlyclean-am: mostlyclean-compile mostlyclean-generic pdf: pdf-am pdf-am: ps: ps-am ps-am: uninstall-am: uninstall-binPROGRAMS uninstall-tgifDATA .MAKE: install-am install-strip .PHONY: CTAGS GTAGS all all-am am--refresh check check-am clean \ clean-binPROGRAMS clean-generic ctags dist dist-all dist-bzip2 \ dist-gzip dist-shar dist-tarZ dist-zip distcheck distclean \ distclean-compile distclean-generic distclean-hdr \ distclean-tags distcleancheck distdir distuninstallcheck dvi \ dvi-am html html-am info info-am install install-am \ install-binPROGRAMS install-data install-data-am install-dvi \ install-dvi-am install-exec install-exec-am install-html \ install-html-am install-info install-info-am install-man \ install-pdf install-pdf-am install-ps install-ps-am \ install-strip install-tgifDATA installcheck installcheck-am \ installdirs maintainer-clean maintainer-clean-generic \ mostlyclean mostlyclean-compile mostlyclean-generic pdf pdf-am \ ps ps-am tags uninstall uninstall-am uninstall-binPROGRAMS \ uninstall-tgifDATA # Tell versions [3.59,3.63) of GNU make to not export all variables. # Otherwise a system limit (for SysV at least) may be exceeded. .NOEXPORT: ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/polygon.c����������������������������������������������������������������������������0000644�0000764�0000764�00000267323�11602233312�014634� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/polygon.c,v 1.41 2011/06/09 15:55:15 cvsps Exp $ */ #define _INCLUDE_FROM_POLYGON_C_ #include "tgifdefs.h" #include "arc.e" #include "attr.e" #include "auxtext.e" #include "box.e" #include "cmd.e" #include "color.e" #include "choice.e" #include "cursor.e" #include "cutpaste.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "grid.e" #include "file.e" #include "mainloop.e" #include "mark.e" #include "msg.e" #include "obj.e" #include "pattern.e" #include "poly.e" #include "polygon.e" #include "ps.e" #include "raster.e" #include "rect.e" #include "ruler.e" #include "select.e" #include "setup.e" #include "spline.e" #include "strtbl.e" #include "util.e" #include "xpixmap.e" int polygonDrawn=FALSE; XPoint *MakePolygonVertex(XOff, YOff, NumVs, Vs) int XOff, YOff, NumVs; register IntPoint *Vs; { register XPoint *v; register int i; int real_x_off, real_y_off; real_x_off = (zoomedIn ? XOff : (XOff>>zoomScale)<<zoomScale); real_y_off = (zoomedIn ? YOff : (YOff>>zoomScale)<<zoomScale); v = (XPoint*)malloc((NumVs+1)*sizeof(XPoint)); if (v == NULL) FailAllocMessage(); for (i = 0; i < NumVs; i++) { v[i].x = (short)ZOOMED_SIZE(Vs[i].x-real_x_off); v[i].y = (short)ZOOMED_SIZE(Vs[i].y-real_y_off); } return v; } void DumpPoints(FP, NumPts, V, Indent) FILE *FP; int NumPts, Indent; IntPoint *V; { register int i, j; for (i=1; i < NumPts; i++) { for (j = 0; j < Indent; j++) fprintf(FP, " "); fprintf(FP, "%1d %1d %s\n", V[i].x, V[i].y, gPsCmd[PS_LINETO]); } } static void DumpJustPolygonPath(FP, Vs, NumPts, Smooth, Curved) FILE *FP; IntPoint *Vs; char *Smooth; int NumPts, Curved; { fprintf(FP, "%s\n", gPsCmd[PS_NEWPATH]); if (Curved == LT_INTSPLINE) { DumpCurvedPolygonPoints(FP, Curved, NumPts, Vs, 3); } else { DumpMultiCurvedPolygonPoints(FP, Smooth, Curved, NumPts, Vs, 3); } fprintf(FP, "%s\n", gPsCmd[PS_CLOSEPATH]); } static void DumpPolygonPath(FP, ObjPtr, Vs, NumPts, Width, Pen, Fill, Dash, TransPat) FILE *FP; struct ObjRec *ObjPtr; IntPoint *Vs; int NumPts, Width, Pen, Fill, Dash, TransPat; { register int i; int w_is_int=TRUE; char *width_spec=ObjPtr->detail.g->width_spec; double dw=GetWidthInDouble(Width, width_spec, &w_is_int); if (Fill != (-1) && Pen == (-1)) { /* dumping the fill */ switch (Fill) { case SOLIDPAT: fprintf(FP, " %s\n", gPsCmd[PS_EOFILL]); break; case BACKPAT: if (!TransPat) { fprintf(FP, " 1 %s %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_EOFILL]); } break; default: if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); fprintf(FP, " %s %s\n", gPsCmd[PS_EOCLIP], gPsCmd[PS_NEWPATH]); for (i=0; i < 3; i++) fprintf(FP, " "); DumpPatFill(FP, Fill, ObjPtr->bbox, 0, TRUE); } else { GrayCheck(Fill); for (i=0; i < 3; i++) fprintf(FP, " "); fprintf(FP, "%s %s\n", GrayStr(Fill), gPsCmd[PS_SETGRAY]); fprintf(FP, " %s\n", gPsCmd[PS_EOFILL]); } break; } } else if (Fill == (-1) && Pen != (-1)) { /* dumping the pen */ if (ObjPtr->ctm != NULL) { fprintf(FP, " %s\n", &(gPsCmd[PS_TGIFSETMATRIX])[1]); } if (w_is_int) { if (Width != 1) { fprintf(FP, " %1d %s\n", Width, gPsCmd[PS_SETLINEWIDTH]); } } else { fprintf(FP, " %.3f %s\n", dw, gPsCmd[PS_SETLINEWIDTH]); } if (Dash != 0) { fprintf(FP, " ["); for (i = 0; i < dashListLength[Dash]-1; i++) { fprintf(FP, "%1d ", (int)(dashList[Dash][i])); } fprintf(FP, "%1d] 0 %s\n", (int)(dashList[Dash][dashListLength[Dash]-1]), gPsCmd[PS_SETDASH]); } switch (Pen) { case SOLIDPAT: fprintf(FP, " %s\n", gPsCmd[PS_STROKE]); break; case BACKPAT: if (!TransPat) { fprintf(FP, " 1 %s %s 0 %s\n", gPsCmd[PS_SETGRAY], gPsCmd[PS_STROKE], gPsCmd[PS_SETGRAY]); } break; default: if (colorDump || !useGray) { if (preDumpSetup) PSUseColorPattern(); fprintf(FP, " %s\n", gPsCmd[PS_FLATTENPATH]); for (i=0; i < 3; i++) fprintf(FP, " "); DumpPatFill(FP, Pen, ObjPtr->bbox, 0, TRUE); } else { GrayCheck(Pen); fprintf(FP, " %s %s\n", GrayStr(Pen), gPsCmd[PS_SETGRAY]); fprintf(FP, " %s\n", gPsCmd[PS_STROKE]); } break; } } } void DumpPolygonObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { IntPoint *v=NULL, *intv=NULL; int num_pts=0, trans_pat, fill, width, pen, curved, dash, color_index, intn; char *smooth=NULL; trans_pat = ObjPtr->trans_pat; fill = ObjPtr->detail.g->fill; width = ObjPtr->detail.g->width; pen = ObjPtr->detail.g->pen; curved = ObjPtr->detail.g->curved; dash = ObjPtr->detail.g->dash; intv = ObjPtr->detail.g->intvlist; intn = ObjPtr->detail.g->intn; if (curved == LT_STRUCT_SPLINE) { v = ObjPtr->detail.g->ssvlist; num_pts = ObjPtr->detail.g->ssn; smooth = ObjPtr->detail.g->ssmooth; } else { v = ObjPtr->detail.g->vlist; num_pts = ObjPtr->detail.g->n; smooth = ObjPtr->detail.g->smooth; } if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } fprintf(FP, "%% POLYGON/CLOSED-SPLINE\n"); color_index = ObjPtr->color; DumpRGBColorLine(FP, color_index, 0, TRUE); if (ObjPtr->ctm != NULL) { float m[6]; fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); m[CTM_SX] = ((float)ObjPtr->ctm->m[CTM_SX])/((float)1000.0); m[CTM_SY] = ((float)ObjPtr->ctm->m[CTM_SY])/((float)1000.0); m[CTM_SIN] = ((float)ObjPtr->ctm->m[CTM_SIN])/((float)1000.0); m[CTM_MSIN] = ((float)ObjPtr->ctm->m[CTM_MSIN])/((float)1000.0); fprintf(FP, " %1d %1d %s\n", ObjPtr->x, ObjPtr->y, gPsCmd[PS_TRANSLATE]); fprintf(FP, " [%.3f %.3f %.3f %.3f %1d %1d] %s\n", m[CTM_SX], m[CTM_SIN], m[CTM_MSIN], m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY], gPsCmd[PS_CONCAT]); fprintf(FP, " %1d %s %1d %s %s\n", ObjPtr->x, gPsCmd[PS_NEG], ObjPtr->y, gPsCmd[PS_NEG], gPsCmd[PS_TRANSLATE]); } if (curved != LT_INTSPLINE) { DumpJustPolygonPath(FP, v, num_pts, smooth, curved); } else { DumpJustPolygonPath(FP, intv, intn, smooth, curved); } fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if (fill != NONEPAT) { if (curved != LT_INTSPLINE) { if ((colorDump || !useGray) && fill > BACKPAT && !trans_pat) { DumpPolygonPath(FP, ObjPtr, v, num_pts, width, (-1), BACKPAT, 0, trans_pat); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); } DumpPolygonPath(FP, ObjPtr, v, num_pts, width, (-1), fill, 0, trans_pat); } else { if ((colorDump || !useGray) && fill > BACKPAT && !trans_pat) { DumpPolygonPath(FP, ObjPtr, intv, intn, width, (-1), BACKPAT, 0, trans_pat); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); } DumpPolygonPath(FP, ObjPtr, intv, intn, width, (-1), fill, 0, trans_pat); } } if (pen != NONEPAT) { fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); if (curved != LT_INTSPLINE) { if ((colorDump || !useGray) && pen > BACKPAT && !trans_pat) { DumpPolygonPath(FP, ObjPtr, v, num_pts, width, BACKPAT, (-1), 0, trans_pat); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); } DumpPolygonPath(FP, ObjPtr, v, num_pts, width, pen, (-1), dash, trans_pat); } else { if ((colorDump || !useGray) && pen > BACKPAT && !trans_pat) { DumpPolygonPath(FP, ObjPtr, intv, intn, width, BACKPAT, (-1), 0, trans_pat); fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "%s\n", gPsCmd[PS_GSAVE]); } DumpPolygonPath(FP, ObjPtr, intv, intn, width, pen, (-1), dash, trans_pat); } } fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); if (ObjPtr->ctm != NULL) fprintf(FP, "%s\n", gPsCmd[PS_GRESTORE]); fprintf(FP, "\n"); } int NeedsToCachePolygonObj(ObjPtr) struct ObjRec *ObjPtr; { return (ObjPtr->ctm != NULL); } static void MakeCachedPolygon(ObjPtr) struct ObjRec *ObjPtr; { register int i; struct PolygonRec *polygon_ptr=ObjPtr->detail.g; IntPoint *v=polygon_ptr->vlist, *pv=NULL, *pv1=NULL; int num_pts=polygon_ptr->n, num_pts1=0; if (ObjPtr->ctm == NULL) return; if (polygon_ptr->rotated_vlist != NULL) free(polygon_ptr->rotated_vlist); polygon_ptr->rotated_n = 0; polygon_ptr->rotated_vlist = NULL; if (polygon_ptr->curved == LT_STRUCT_SPLINE) { v = polygon_ptr->ssvlist; num_pts = polygon_ptr->ssn; } pv = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (pv == NULL) { FailAllocMessage(); return; } for (i=0; i < num_pts; i++) { int x, y; TransformPointThroughCTM(v[i].x-ObjPtr->x, v[i].y-ObjPtr->y, ObjPtr->ctm, &x, &y); pv[i].x = x+ObjPtr->x; pv[i].y = y+ObjPtr->y; } switch (polygon_ptr->curved) { case LT_STRAIGHT: case LT_SPLINE: polygon_ptr->rotated_vlist = MakeMultiSplinePolygonVertex( polygon_ptr->curved, &(polygon_ptr->rotated_n), polygon_ptr->smooth, drawOrigX, drawOrigY, num_pts, pv); break; case LT_STRUCT_SPLINE: polygon_ptr->rotated_vlist = MakeMultiSplinePolygonVertex( polygon_ptr->curved, &(polygon_ptr->rotated_n), polygon_ptr->ssmooth, drawOrigX, drawOrigY, num_pts, pv); break; case LT_INTSPLINE: polygon_ptr->rotated_vlist = MakeIntSplinePolygonVertex( &(polygon_ptr->rotated_n), &(num_pts1), &(pv1), drawOrigX, drawOrigY, num_pts, pv); free(pv1); break; } free(pv); } void DrawPolygonObj(Win, XOff, YOff, ObjPtr) Window Win; int XOff, YOff; struct ObjRec *ObjPtr; { struct PolygonRec *polygon_ptr=ObjPtr->detail.g; XPoint *v; int trans_pat, fill, width, pen, dash, pixel, num_pts; XGCValues values; trans_pat = ObjPtr->trans_pat; fill = polygon_ptr->fill; width = polygon_ptr->width; pen = polygon_ptr->pen; dash = polygon_ptr->dash; pixel = colorPixels[ObjPtr->color]; if (NeedsToCachePolygonObj(ObjPtr) && polygon_ptr->rotated_vlist==NULL) { MakeCachedPolygon(ObjPtr); } if (userDisableRedraw) return; if ((fill == NONEPAT || (trans_pat && fill == BACKPAT)) && (pen == NONEPAT || (trans_pat && pen == BACKPAT))) { return; } v = polygon_ptr->svlist; num_pts = polygon_ptr->sn; if (fill != 0) { values.foreground = GetDrawingBgPixel(fill, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[fill]; XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple, &values); if (ObjPtr->ctm == NULL) { XFillPolygon(mainDisplay, Win, drawGC, v, num_pts, Complex, CoordModeOrigin); } else { XFillPolygon(mainDisplay, Win, drawGC, polygon_ptr->rotated_vlist, polygon_ptr->rotated_n, Complex, CoordModeOrigin); } } if (pen == NONEPAT) return; values.foreground = GetDrawingBgPixel(pen, pixel); values.function = GXcopy; values.fill_style = (trans_pat ? FillStippled : FillOpaqueStippled); values.stipple = patPixmap[pen]; values.line_width = ZOOMED_SIZE(width); #ifdef NO_THIN_LINE if (values.line_width < 1) values.line_width = 1; #endif values.join_style = JoinBevel; if (dash != 0) { XSetDashes(mainDisplay, drawGC, 0, dashList[dash], dashListLength[dash]); values.line_style = LineOnOffDash; } else { values.line_style = LineSolid; } XChangeGC(mainDisplay, drawGC, GCForeground | GCFunction | GCFillStyle | GCStipple | GCLineWidth | GCLineStyle | GCJoinStyle, &values); if (ObjPtr->ctm == NULL) { XDrawLines(mainDisplay, Win, drawGC, v, num_pts, CoordModeOrigin); } else { XDrawLines(mainDisplay, Win, drawGC, polygon_ptr->rotated_vlist, polygon_ptr->rotated_n, CoordModeOrigin); } values.join_style = JoinMiter; XChangeGC(mainDisplay, drawGC, GCJoinStyle, &values); } #define CREATE_RELATIVE (FALSE) #define CREATE_ABSOLUTE (TRUE) void CreatePolygonObj(NumPts, CreateAbsolute) int NumPts; int CreateAbsolute; { register int i; struct PtRec *pt_ptr=NULL, *next_pt=NULL; struct PolygonRec *polygon_ptr=NULL; struct ObjRec *obj_ptr=NULL; IntPoint *v=NULL; int width, w, ltx, lty, rbx, rby, num_ss_pts=0; char *smooth=NULL; CVListElem *elem=NULL; IntPointTriplet *pipt=NULL; polygon_ptr = (struct PolygonRec *)malloc(sizeof(struct PolygonRec)); if (polygon_ptr == NULL) FailAllocMessage(); memset(polygon_ptr, 0, sizeof(struct PolygonRec)); if (curSpline == LT_STRUCT_SPLINE) { num_ss_pts = ((NumPts-1)*3)+1; polygon_ptr->n = num_ss_pts; v = (IntPoint*)malloc((num_ss_pts+1)*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); smooth = (char*)malloc((num_ss_pts+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); elem = ListLast(&gStructSplineList); pipt = (IntPointTriplet*)(elem->obj); ltx = rbx = pipt->hinge_pt.x; lty = rby = pipt->hinge_pt.y; for (i=NumPts-1; i >= 0; i--, elem=ListPrev(&gStructSplineList, elem)) { pipt = (IntPointTriplet*)(elem->obj); if (i == 0) { v[0].x = CreateAbsolute ? pipt->hinge_pt.x : ABS_X(pipt->hinge_pt.x); v[0].y = CreateAbsolute ? pipt->hinge_pt.y : ABS_Y(pipt->hinge_pt.y); if (pipt->later_valid) { v[1].x = CreateAbsolute ? pipt->later_smooth_pt.x : ABS_X(pipt->later_smooth_pt.x); v[1].y = CreateAbsolute ? pipt->later_smooth_pt.y : ABS_Y(pipt->later_smooth_pt.y); smooth[1] = TRUE; } else { v[1].x = v[0].x; v[1].y = v[0].y; smooth[1] = FALSE; } smooth[0] = FALSE; } else if (i == NumPts-1) { v[num_ss_pts-1].x = CreateAbsolute ? pipt->hinge_pt.x : ABS_X(pipt->hinge_pt.x); v[num_ss_pts-1].y = CreateAbsolute ? pipt->hinge_pt.y : ABS_Y(pipt->hinge_pt.y); if (pipt->earlier_valid) { v[num_ss_pts-2].x = CreateAbsolute ? pipt->earlier_smooth_pt.x : ABS_X(pipt->earlier_smooth_pt.x); v[num_ss_pts-2].y = CreateAbsolute ? pipt->earlier_smooth_pt.y : ABS_Y(pipt->earlier_smooth_pt.y); smooth[num_ss_pts-2] = TRUE; } else { v[num_ss_pts-2].x = v[num_ss_pts-1].x; v[num_ss_pts-2].y = v[num_ss_pts-1].y; smooth[num_ss_pts-2] = FALSE; } smooth[num_ss_pts-1] = FALSE; } else { int index=3*i; v[index-1].x = CreateAbsolute ? pipt->earlier_smooth_pt.x : ABS_X(pipt->earlier_smooth_pt.x); v[index-1].y = CreateAbsolute ? pipt->earlier_smooth_pt.y : ABS_Y(pipt->earlier_smooth_pt.y); v[index].x = CreateAbsolute ? pipt->hinge_pt.x : ABS_X(pipt->hinge_pt.x); v[index].y = CreateAbsolute ? pipt->hinge_pt.y : ABS_Y(pipt->hinge_pt.y); v[index+1].x = CreateAbsolute ? pipt->later_smooth_pt.x : ABS_X(pipt->later_smooth_pt.x); v[index+1].y = CreateAbsolute ? pipt->later_smooth_pt.y : ABS_Y(pipt->later_smooth_pt.y); smooth[index-1] = pipt->earlier_valid; smooth[index] = FALSE; smooth[index+1] = pipt->later_valid; } free(pipt); } for (i=0; i < num_ss_pts; i++) { if (v[i].x < ltx) ltx = v[i].x; if (v[i].y < lty) lty = v[i].y; if (v[i].x > rbx) rbx = v[i].x; if (v[i].y > rby) rby = v[i].y; } numPtsInPoly = 0; ListUnlinkAll(&gStructSplineList); } else { polygon_ptr->n = NumPts; v = (IntPoint*)malloc((NumPts+1)*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); if (curSpline != LT_INTSPLINE) { smooth = (char*)malloc((NumPts+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); } pt_ptr = lastPtPtr; ltx = rbx = pt_ptr->x; lty = rby = pt_ptr->y; for (i=NumPts-1; i >= 0; i--, lastPtPtr = next_pt) { next_pt = lastPtPtr->next; v[i].x = CreateAbsolute ? lastPtPtr->x : ABS_X(lastPtPtr->x); v[i].y = CreateAbsolute ? lastPtPtr->y : ABS_Y(lastPtPtr->y); if (curSpline != LT_INTSPLINE) { if (lastPtPtr->x < ltx) ltx = lastPtPtr->x; if (lastPtPtr->y < lty) lty = lastPtPtr->y; if (lastPtPtr->x > rbx) rbx = lastPtPtr->x; if (lastPtPtr->y > rby) rby = lastPtPtr->y; smooth[i] = (curSpline != LT_STRAIGHT); } free(lastPtPtr); } numPtsInPoly = 0; lastPtPtr = NULL; } polygon_ptr->vlist = v; polygon_ptr->smooth = smooth; polygon_ptr->svlist = NULL; polygon_ptr->intvlist = NULL; polygon_ptr->fill = objFill; polygon_ptr->width = width = curWidthOfLine[lineWidth]; UtilStrCpyN(polygon_ptr->width_spec, sizeof(polygon_ptr->width_spec), curWidthOfLineSpec[lineWidth]); polygon_ptr->pen = penPat; polygon_ptr->curved = curSpline; polygon_ptr->dash = curDash; /* * polygon_ptr->tighter = (curSpline == LT_STRUCT_SPLINE) ? * tighterStructSplines : FALSE; */ polygon_ptr->rotated_n = 0; polygon_ptr->rotated_vlist = NULL; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); obj_ptr->detail.g = polygon_ptr; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->type = OBJ_POLYGON; if (CreateAbsolute) { obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = ltx; obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = lty; obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = rbx; obj_ptr->bbox.rby = obj_ptr->obbox.rby = rby; } else { obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = ABS_X(ltx); obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = ABS_Y(lty); obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = ABS_X(rbx); obj_ptr->bbox.rby = obj_ptr->obbox.rby = ABS_Y(rby); } w = HALF_W(width); obj_ptr->bbox.ltx -= w; obj_ptr->bbox.lty -= w; obj_ptr->bbox.rbx += w; obj_ptr->bbox.rby += w; obj_ptr->id = objId++; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->locked = FALSE; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; obj_ptr->invisible = FALSE; obj_ptr->trans_pat = transPat; AdjObjSplineVs(obj_ptr); if (curSpline != LT_INTSPLINE) { UpdPolyBBox(obj_ptr, polygon_ptr->n, polygon_ptr->vlist); } else { UpdPolyBBox(obj_ptr, polygon_ptr->intn, polygon_ptr->intvlist); } AdjObjBBox(obj_ptr); AddObj(NULL, topObj, obj_ptr); } void ResetCreatePolygon() { numPtsInPoly = 0; lastPtPtr = NULL; } void AddPtToCreatePolygon(AbsX, AbsY) int AbsX, AbsY; { struct PtRec *pt_ptr=(struct PtRec *)malloc(sizeof(struct PtRec)); if (pt_ptr == NULL) FailAllocMessage(); memset(pt_ptr, 0, sizeof(struct PtRec)); pt_ptr->next = lastPtPtr; numPtsInPoly++; lastPtPtr = pt_ptr; pt_ptr->x = AbsX; pt_ptr->y = AbsY; } #define POLYGON_DRAW (FALSE) #define POLYGON_ERASE (TRUE) #define POLYGON_CLICK (FALSE) #define POLYGON_DRAG (TRUE) #define POLYGON_STARTSHOW 0 #define POLYGON_DOSHOW 1 #define POLYGON_ENDSHOW 2 typedef struct tagPolygonMeasureCursorInfo { IntPoint first_pt; IntPoint prev_prev_pt; IntPoint prev_pt; } PolygonMeasureCursorInfo; static void DoPolygonMeasureCursor(ppmci, start, num_pts, x, y, dx, dy, erase, drag, closed) PolygonMeasureCursorInfo *ppmci; int start, num_pts, x, y, dx, dy, erase, drag, closed; { char buf[80], w_buf[80], h_buf[80], x_buf[80], y_buf[80], a_buf[80]; int angle2=0; if (erase == POLYGON_DRAW && drag == POLYGON_CLICK) { if (num_pts == 1) { ppmci->first_pt.x = ppmci->prev_pt.x = ppmci->prev_prev_pt.x = x; ppmci->first_pt.y = ppmci->prev_pt.y = ppmci->prev_prev_pt.y = y; } else { ppmci->prev_prev_pt.x = ppmci->prev_pt.x; ppmci->prev_prev_pt.y = ppmci->prev_pt.y; ppmci->prev_pt.x = x; ppmci->prev_pt.y = y; } } if (x == ppmci->prev_pt.x && y == ppmci->prev_pt.y) { strcpy(a_buf, "0"); } else if (num_pts == 1) { PointsToArc(ppmci->prev_pt.x, ppmci->prev_pt.y, ppmci->prev_pt.x+100, ppmci->prev_pt.y, x, y, ARC_CCW, FALSE, NULL, NULL, NULL, NULL, NULL, &angle2); if (angle2 > 180*64) angle2=(360*64)-angle2; FormatAngle(angle2, a_buf); } else if (closed) { if (x == ppmci->first_pt.x && y == ppmci->first_pt.y) { strcpy(a_buf, "0"); } else { PointsToArc(x, y, ppmci->first_pt.x, ppmci->first_pt.y, ppmci->prev_pt.x, ppmci->prev_pt.y, ARC_CCW, FALSE, NULL, NULL, NULL, NULL, NULL, &angle2); if (angle2 > 180*64) angle2=(360*64)-angle2; FormatAngle(angle2, a_buf); } } else { PointsToArc(ppmci->prev_pt.x, ppmci->prev_pt.y, ppmci->prev_prev_pt.x, ppmci->prev_prev_pt.y, x, y, ARC_CCW, FALSE, NULL, NULL, NULL, NULL, NULL, &angle2); if (angle2 > 180*64) angle2=(360*64)-angle2; FormatAngle(angle2, a_buf); } PixelToMeasurementUnit(w_buf, dx); PixelToMeasurementUnit(h_buf, dy); PixelToMeasurementUnit(x_buf, x); PixelToMeasurementUnit(y_buf, y); sprintf(buf, "w=%s\nh=%s\nx=%s\ny=%s\nangle=%s", w_buf, h_buf, x_buf, y_buf, a_buf); x = OFFSET_X(x); y = OFFSET_Y(y); switch (start) { case POLYGON_STARTSHOW: StartShowMeasureCursor(x, y, buf, TRUE); break; case POLYGON_DOSHOW: ShowMeasureCursor(x, y, buf, TRUE); break; case POLYGON_ENDSHOW: EndShowMeasureCursor(x, y, buf, TRUE); break; } } static void EraseStructSplineLinesForCont(OrigX, OrigY, grid_x, grid_y, sv, sn, sv2, sn2) int OrigX, OrigY, grid_x, grid_y, sn, sn2; XPoint *sv, *sv2; { if (sv == NULL && sv2 == NULL) { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); } else { if (sv != NULL) { XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); } if (sv2 != NULL) { XDrawLines(mainDisplay, drawWindow, drawGC, sv2, sn2, CoordModeOrigin); } } } static void ContinueForStructSplinePolygonControlPoints(OrigX, OrigY, LastX, LastY, psv, psn, psv2, psn2, pipt_first, pipt_prev, pipt, pn_abort) int OrigX, OrigY, LastX, LastY, *psn, *psn2, *pn_abort; XPoint **psv, **psv2; IntPointTriplet *pipt_first, *pipt_prev, *pipt; { int i=0, done=FALSE, grid_x=0, grid_y=0, end_x=0, end_y=0, n=2; int sn=(*psn), orig_sn=(*psn), sn2=(*psn2), orig_sn2=(*psn2); int num_pts=1, first_time=TRUE; IntPoint v[4]; XPoint *sv=NULL, *orig_sv=(*psv), *sv2=NULL, *orig_sv2=(*psv2), dash_vs[2]; PolygonMeasureCursorInfo pmci; XGCValues values; *pn_abort = FALSE; if (orig_sv != NULL) { sv = (XPoint*)malloc(orig_sn*sizeof(XPoint)); if (sv == NULL) FailAllocMessage(); memset(sv, 0, orig_sn*sizeof(XPoint)); for (i=0; i < orig_sn; i++) { sv[i].x = orig_sv[i].x; sv[i].y = orig_sv[i].y; } sn = orig_sn; } if (orig_sv2 != NULL) { sv2 = (XPoint*)malloc(orig_sn2*sizeof(XPoint)); if (sv2 == NULL) FailAllocMessage(); memset(sv2, 0, orig_sn2*sizeof(XPoint)); for (i=0; i < orig_sn2; i++) { sv2[i].x = orig_sv2[i].x; sv2[i].y = orig_sv2[i].y; } sn2 = orig_sn2; } memset(pipt, 0, sizeof(IntPointTriplet)); pipt->earlier_valid = pipt->later_valid = FALSE; pipt->hinge_pt.x = pipt->earlier_smooth_pt.x = pipt->later_smooth_pt.x = LastX; pipt->hinge_pt.y = pipt->earlier_smooth_pt.y = pipt->later_smooth_pt.y = LastY; pipt->ratio = (double)1; XSetDashes(mainDisplay, revDefaultGC, 0, dashList[8], dashListLength[8]); grid_x = end_x = dash_vs[0].x = dash_vs[1].x = LastX; grid_y = end_y = dash_vs[0].y = dash_vs[1].y = LastY; v[0].x = ABS_X(OrigX); v[0].y = ABS_Y(OrigY); v[1].x = ABS_X(LastX); v[1].y = ABS_Y(LastY); n = 2; MARKHR(drawWindow, revDefaultGC, LastX, LastY); /* the previous curve has already been drawn */ /* draw the measure cursor */ DoPolygonMeasureCursor(&pmci, POLYGON_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), 0, 0, POLYGON_ERASE, POLYGON_DRAG); while (!done) { XEvent input, ev; XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); SetXorDrawGC(colorIndex); } else if (input.type == MotionNotify) { end_x = input.xmotion.x; end_y = input.xmotion.y; /* erase */ if (first_time || grid_x != LastX || grid_y != LastY) { EraseStructSplineLinesForCont(OrigX, OrigY, grid_x, grid_y, sv, sn, sv2, sn2); if (!pipt_first->earlier_valid && sv != NULL && sv2 == NULL) { XDrawLine(mainDisplay, drawWindow, drawGC, grid_x, grid_y, pipt_first->earlier_smooth_pt.x, pipt_first->earlier_smooth_pt.y); } first_time = FALSE; } else { if (orig_sv != NULL || orig_sv2 != NULL) { if (orig_sv != NULL) { XDrawLines(mainDisplay, drawWindow, drawGC, orig_sv, orig_sn, CoordModeOrigin); } if (orig_sv2 != NULL) { XDrawLines(mainDisplay, drawWindow, drawGC, orig_sv2, orig_sn2, CoordModeOrigin); } } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, LastX, LastY); } } DoPolygonMeasureCursor(&pmci, POLYGON_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-LastX)), ABS_SIZE(abs(grid_y-LastY)), POLYGON_ERASE, POLYGON_DRAG); MARKHO(drawWindow, revDefaultGC, dash_vs[0].x, dash_vs[0].y); MARKHO(drawWindow, revDefaultGC, dash_vs[1].x, dash_vs[1].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, dash_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); /* draw */ GridXY(end_x, end_y, &grid_x, &grid_y); MarkRulers(grid_x, grid_y); if (grid_x != LastX || grid_y != LastY) { if (sv != NULL) { free(sv); sv = NULL; } if (sv2 != NULL) { free(sv2); sv2 = NULL; } v[0].x = ABS_X(OrigX); v[0].y = ABS_Y(OrigY); if (pipt_prev->later_valid) { v[1].x = ABS_X(pipt_prev->later_smooth_pt.x); v[1].y = ABS_Y(pipt_prev->later_smooth_pt.y); n = 4; } else { n = 3; } v[n-2].x = ABS_X((LastX<<1)-grid_x); v[n-2].y = ABS_Y((LastY<<1)-grid_y); v[n-1].x = ABS_X(LastX); v[n-1].y = ABS_Y(LastY); sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, v); XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); v[0].x = ABS_X(pipt_first->hinge_pt.x); v[0].y = ABS_Y(pipt_first->hinge_pt.y); if (pipt_first->earlier_valid) { v[1].x = ABS_X(pipt_first->earlier_smooth_pt.x); v[1].y = ABS_Y(pipt_first->earlier_smooth_pt.y); n = 4; } else { n = 3; } v[n-2].x = ABS_X(grid_x); v[n-2].y = ABS_Y(grid_y); v[n-1].x = ABS_X(LastX); v[n-1].y = ABS_Y(LastY); sv2 = MakeSplinePolyVertex(0, curSpline, &sn2, drawOrigX, drawOrigY, n, v); XDrawLines(mainDisplay, drawWindow, drawGC, sv2, sn2, CoordModeOrigin); } else { if (orig_sv != NULL || orig_sv2 != NULL) { if (orig_sv != NULL) { XDrawLines(mainDisplay, drawWindow, drawGC, orig_sv, orig_sn, CoordModeOrigin); } if (orig_sv2 != NULL) { XDrawLines(mainDisplay, drawWindow, drawGC, orig_sv2, orig_sn2, CoordModeOrigin); } } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, LastX, LastY); } } while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; dash_vs[0].x = grid_x; dash_vs[0].y = grid_y; dash_vs[1].x = (LastX<<1)-grid_x; dash_vs[1].y = (LastY<<1)-grid_y; pipt->later_smooth_pt.x = dash_vs[0].x; pipt->later_smooth_pt.y = dash_vs[0].y; pipt->earlier_smooth_pt.x = dash_vs[1].x; pipt->earlier_smooth_pt.y = dash_vs[1].y; if (grid_x == LastX && grid_y == LastY) { pipt->earlier_valid = pipt->later_valid = FALSE; } else { pipt->earlier_valid = pipt->later_valid = TRUE; } MARKHO(drawWindow, revDefaultGC, dash_vs[0].x, dash_vs[0].y); MARKHO(drawWindow, revDefaultGC, dash_vs[1].x, dash_vs[1].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, dash_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); DoPolygonMeasureCursor(&pmci, POLYGON_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-LastX)), ABS_SIZE(abs(grid_y-LastY)), POLYGON_DRAW, POLYGON_DRAG); } else if (input.type == KeyPress) { if (KeyPressEventIsEscape(&input.xkey)) { /* erase */ DoPolygonMeasureCursor(&pmci, POLYGON_ENDSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-LastX)), ABS_SIZE(abs(grid_y-LastY)), POLYGON_ERASE, POLYGON_DRAG); MARKHO(drawWindow, revDefaultGC, dash_vs[0].x, dash_vs[0].y); MARKHO(drawWindow, revDefaultGC, dash_vs[1].x, dash_vs[1].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, dash_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); Msg(""); *pn_abort = TRUE; done = TRUE; } } else if (input.type == ButtonRelease) { /* erase */ DoPolygonMeasureCursor(&pmci, POLYGON_ENDSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-LastX)), ABS_SIZE(abs(grid_y-LastY)), POLYGON_ERASE, POLYGON_DRAG); MARKHO(drawWindow, revDefaultGC, dash_vs[0].x, dash_vs[0].y); MARKHO(drawWindow, revDefaultGC, dash_vs[1].x, dash_vs[1].y); values.line_style = LineOnOffDash; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); MyDashedLine(drawWindow, revDefaultGC, dash_vs, 2); values.line_style = LineSolid; XChangeGC(mainDisplay, revDefaultGC, GCLineStyle, &values); GridXY(input.xbutton.x, input.xbutton.y, &grid_x, &grid_y); pipt->later_smooth_pt.x = grid_x; pipt->later_smooth_pt.y = grid_y; pipt->earlier_smooth_pt.x = (LastX<<1)-grid_x; pipt->earlier_smooth_pt.y = (LastY<<1)-grid_y; if (grid_x == LastX && grid_y == LastY) { pipt->earlier_valid = pipt->later_valid = FALSE; if (sv2 != NULL) { free(sv2); sv2 = NULL; v[0].x = ABS_X(pipt_first->hinge_pt.x); v[0].y = ABS_Y(pipt_first->hinge_pt.y); if (pipt_first->earlier_valid) { v[1].x = ABS_X(pipt_first->earlier_smooth_pt.x); v[1].y = ABS_Y(pipt_first->earlier_smooth_pt.y); n = 3; } else { n = 2; } v[n-1].x = ABS_X(LastX); v[n-1].y = ABS_Y(LastY); if (n > 2) { sv2 = MakeSplinePolyVertex(0, curSpline, &sn2, drawOrigX, drawOrigY, n, v); } else { XDrawLine(mainDisplay, drawWindow, drawGC, pipt_first->hinge_pt.x, pipt_first->hinge_pt.y, LastX, LastY); } } } else { pipt->earlier_valid = pipt->later_valid = TRUE; } done = TRUE; } } MARKHR(drawWindow, revDefaultGC, LastX, LastY); *psv = sv; *psn = sn; *psv2 = sv2; *psn2 = sn2; if (orig_sv != NULL) free(orig_sv); if (orig_sv2 != NULL) free(orig_sv2); } static void EraseStructSplineLinesForContAndUpdateSvs(OrigX, OrigY, grid_x, grid_y, pev, num_pts, psv, sn, psv2, sn2, pipt_prev, pipt_first) int OrigX, OrigY, grid_x, grid_y, sn, sn2; XEvent *pev; XPoint **psv, **psv2; IntPointTriplet *pipt_prev, *pipt_first; { XPoint *sv=(*psv), *sv2=(*psv2); /* erase */ if (sv == NULL && sv2 != NULL && !pipt_prev->later_valid) { /* erase the straight line */ XDrawLine(mainDisplay, drawWindow, drawGC, pipt_prev->later_smooth_pt.x, pipt_prev->later_smooth_pt.y, grid_x, grid_y); } EraseStructSplineLinesForCont(OrigX, OrigY, grid_x, grid_y, sv, sn, sv2, sn2); if ((pev->type == MotionNotify && num_pts > 1) || (pev->type == ButtonPress && num_pts > 2)) { if (pipt_first->earlier_valid) { /* don't need to do anything here */ } else { XDrawLine(mainDisplay, drawWindow, drawGC, pipt_first->hinge_pt.x, pipt_first->hinge_pt.y, grid_x, grid_y); } } if (sv != NULL) free(sv); if (sv2 != NULL) free(sv2); *psv = *psv2 = NULL; } static int CountStructuredSplinePolygonVs() { int i=0, len=ListLength(&gStructSplineList), num_vs=0; CVListElem *elem=NULL; for (i=0, elem=ListFirst(&gStructSplineList); elem != NULL; i++, elem=ListNext(&gStructSplineList, elem)) { IntPointTriplet *ipt=(IntPointTriplet*)(elem->obj); if (i == 0) { if (ipt->later_valid) { num_vs++; } } else if (i == len-1) { if (ipt->earlier_valid) { num_vs++; } } else { if (ipt->later_valid) { num_vs++; } if (ipt->earlier_valid) { num_vs++; } } num_vs++; } return num_vs; } #ifdef _TGIF_DBG void sync() { XSync(mainDisplay,0); } #endif /* _TGIF_DBG */ static XComposeStatus c_stat; static void ContinuePolygon(OrigX, OrigY) int OrigX, OrigY; /* OrigX and OrigY are screen coordinates (scaled and translated). */ { register int i; XEvent input, ev; XButtonEvent *button_ev; XMotionEvent *motion_ev; KeySym key_sym; int start_polygon_x=OrigX, start_polygon_y=OrigY; int end_x, end_y, grid_x, grid_y, done=FALSE; int saved_x, saved_y, closed=FALSE, abort=FALSE; int num_pts=1, n=2, sn=0, sn2=0, max_n=40, intn=0, tmp_n=0; int ltx=OrigX, lty=OrigY, rbx=OrigX, rby=OrigY, nothing_is_drawn=TRUE; XPoint *sv=NULL, *sv2=NULL; IntPoint *pv=NULL, *cntrlv=NULL, tmp_vs[4]; IntPointTriplet ipt_prev, ipt, first_ipt; PolygonMeasureCursorInfo pmci; memset(&ipt, 0, sizeof(IntPointTriplet)); memset(&ipt_prev, 0, sizeof(IntPointTriplet)); memset(&first_ipt, 0, sizeof(IntPointTriplet)); memset(&pmci, 0, sizeof(PolygonMeasureCursorInfo)); SetXorDrawGC(xorColorPixels[colorIndex]); grid_x = end_x = saved_x = OrigX; grid_y = end_y = saved_y = OrigY; if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { pv = (IntPoint*)malloc((max_n+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); pv[0].x = pv[1].x = pv[2].x = ABS_X(OrigX); pv[0].y = pv[1].y = pv[2].y = ABS_Y(OrigY); switch (curSpline) { case LT_SPLINE: sv = MakeSplinePolygonVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n+1, pv); break; case LT_INTSPLINE: sv = MakeIntSplinePolygonVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n+1, pv); for (i=0; i < sn; i++) { if (sv[i].x < ltx) ltx = sv[i].x; if (sv[i].y < lty) lty = sv[i].y; if (sv[i].x > rbx) rbx = sv[i].x; if (sv[i].y > rby) rby = sv[i].y; } break; } } else if (curSpline == LT_STRUCT_SPLINE) { ipt_prev.earlier_valid = ipt_prev.later_valid = FALSE; ipt_prev.earlier_smooth_pt.x = ipt_prev.hinge_pt.x = ipt_prev.later_smooth_pt.x = OrigX; ipt_prev.earlier_smooth_pt.y = ipt_prev.hinge_pt.y = ipt_prev.later_smooth_pt.y = OrigY; memcpy(&first_ipt, &ipt_prev, sizeof(IntPointTriplet)); pv = (IntPoint*)malloc((max_n+1)*sizeof(IntPoint)); if (pv == NULL) FailAllocMessage(); pv[0].x = pv[1].x = pv[2].x = pv[3].x = ABS_X(OrigX); pv[0].y = pv[1].y = pv[2].y = pv[3].y = ABS_Y(OrigY); sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n+1, pv); } SaveStatusStrings(); if (curSpline == LT_STRUCT_SPLINE) { SetMouseStatus(TgLoadCachedString(CSTID_ADD_A_STRUCT_VERTEX), TgLoadCachedString(CSTID_CLOSE_POLYGON_SPLINE), TgLoadCachedString(CSTID_CLOSE_POLYGON_SPLINE)); } else { SetMouseStatus(TgLoadCachedString(CSTID_ADD_A_VERTEX), TgLoadCachedString(CSTID_CLOSE_POLYGON_SPLINE), TgLoadCachedString(CSTID_CLOSE_POLYGON_SPLINE)); } DoPolygonMeasureCursor(&pmci, POLYGON_STARTSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), 0, 0, POLYGON_DRAW, POLYGON_CLICK, closed); if (!debugNoPointerGrab) { XGrabPointer(mainDisplay, drawWindow, FALSE, PointerMotionMask | ButtonPressMask | ButtonReleaseMask, GrabModeAsync, GrabModeAsync, None, handCursor, CurrentTime); } if (curSpline == LT_STRUCT_SPLINE) { DoPolygonMeasureCursor(&pmci, POLYGON_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), 0, 0, POLYGON_ERASE, POLYGON_DRAG, closed); ContinueForStructSplinePolygonControlPoints(OrigX, OrigY, grid_x, grid_y, &sv, &sn, &sv2, &sn2, &first_ipt, &ipt_prev, &ipt, &abort); memcpy(&first_ipt, &ipt, sizeof(IntPointTriplet)); memcpy(&ipt_prev, &ipt, sizeof(IntPointTriplet)); if (first_ipt.later_valid) { grid_x = OFFSET_X(first_ipt.later_smooth_pt.x); grid_y = OFFSET_Y(first_ipt.later_smooth_pt.y); } SetFirstPoint(OrigX, OrigY, &first_ipt); DoPolygonMeasureCursor(&pmci, POLYGON_STARTSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLYGON_DRAW, POLYGON_CLICK, closed); } else { SetFirstPoint(OrigX, OrigY, NULL); } while (!done && !abort) { XNextEvent(mainDisplay, &input); if (input.type == Expose || input.type == VisibilityNotify) { ExposeEventHandler(&input, TRUE); SetXorDrawGC(xorColorPixels[colorIndex]); } else if ((!(shiftForDiagMouseMove && DiagEventCheck(&input))) && (input.type == KeyPress || input.type == KeyRelease)) { char s[80]; int has_ch=FALSE; has_ch = XLookupString(&(input.xkey), s, sizeof(s), &key_sym, &c_stat); if (num_pts > 1 && !(curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) && (key_sym == XK_Control_L || key_sym == XK_Control_R)) { XDrawLine(mainDisplay, drawWindow, drawGC, saved_x, saved_y, grid_x, grid_y); /* erase */ DoPolygonMeasureCursor(&pmci, POLYGON_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLYGON_ERASE, POLYGON_DRAG, closed); if (ControlKeyPressedEvent(&input)) { closed = TRUE; } else { closed = FALSE; } /* draw */ DoPolygonMeasureCursor(&pmci, POLYGON_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLYGON_DRAW, POLYGON_DRAG, closed); } else if (CharIsESC(&(input.xkey), s, key_sym, &has_ch)) { /* erase */ DoPolygonMeasureCursor(&pmci, POLYGON_ENDSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLYGON_ERASE, POLYGON_CLICK, closed); abort = TRUE; done = TRUE; } } else if ((input.type==MotionNotify && input.xany.window==drawWindow) || (shiftForDiagMouseMove && DiagEventCheck(&input) && (input.type == KeyPress || input.type == KeyRelease))) { unsigned int event_state=0; /* erase */ DoPolygonMeasureCursor(&pmci, POLYGON_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLYGON_ERASE, POLYGON_DRAG, closed); if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); } else if (curSpline == LT_STRUCT_SPLINE) { if (nothing_is_drawn) { /* then there is nothing to erase */ nothing_is_drawn = FALSE; } else { EraseStructSplineLinesForContAndUpdateSvs(OrigX, OrigY, grid_x, grid_y, &input, num_pts, &sv, sn, &sv2, sn2, &ipt_prev, &first_ipt); } } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); } if (num_pts > 1 && closed) { XDrawLine(mainDisplay, drawWindow, drawGC, saved_x, saved_y, grid_x, grid_y); } if (input.type == KeyPress || input.type == KeyRelease) { end_x = grid_x; end_y = grid_y; event_state = input.xkey.state; } else { motion_ev = &(input.xmotion); end_x = motion_ev->x; end_y = motion_ev->y; event_state = motion_ev->state; } if (shiftForDiagMouseMove && DiagEventCheck(&input)) { if (input.type == KeyRelease) { end_x = input.xkey.x; end_y = input.xkey.y; } else { DiagGridXY(OrigX, OrigY, &end_x, &end_y); } } /* draw */ GridXY(end_x, end_y, &grid_x, &grid_y); MarkRulers(grid_x, grid_y); if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { if (sv != NULL) { free(sv); sv = NULL; } pv[n-1].x = ABS_X(grid_x); pv[n-1].y = ABS_Y(grid_y); switch (curSpline) { case LT_SPLINE: sv = MakeSplinePolygonVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n+1, pv); break; case LT_INTSPLINE: if (cntrlv != NULL) free(cntrlv); sv = MakeIntSplinePolygonVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n+1, pv); for (i=0; i < sn; i++) { if (sv[i].x < ltx) ltx = sv[i].x; if (sv[i].y < lty) lty = sv[i].y; if (sv[i].x > rbx) rbx = sv[i].x; if (sv[i].y > rby) rby = sv[i].y; } break; } XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); } else if (curSpline == LT_STRUCT_SPLINE) { if (sv != NULL) { free(sv); sv = NULL; } if (sv2 != NULL) { free(sv2); sv2 = NULL; } if (ipt_prev.later_valid) { pv[0].x = ABS_X(OrigX); pv[0].y = ABS_Y(OrigY); pv[1].x = ABS_X(ipt_prev.later_smooth_pt.x); pv[1].y = ABS_Y(ipt_prev.later_smooth_pt.y); pv[2].x = pv[3].x = ABS_X(grid_x); pv[2].y = pv[3].y = ABS_Y(grid_y); n = 3; sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, pv); XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); if (first_ipt.earlier_valid) { tmp_n = 3; tmp_vs[0].x = ABS_X(grid_x); tmp_vs[0].y = ABS_Y(grid_y); tmp_vs[1].x = ABS_X(first_ipt.earlier_smooth_pt.x); tmp_vs[1].y = ABS_Y(first_ipt.earlier_smooth_pt.y); tmp_vs[2].x = ABS_X(first_ipt.hinge_pt.x); tmp_vs[2].y = ABS_Y(first_ipt.hinge_pt.y); sv2 = MakeSplinePolyVertex(0, curSpline, &sn2, drawOrigX, drawOrigY, tmp_n, tmp_vs); XDrawLines(mainDisplay, drawWindow, drawGC, sv2, sn2, CoordModeOrigin); } else { XDrawLine(mainDisplay, drawWindow, drawGC, first_ipt.hinge_pt.x, first_ipt.hinge_pt.y, grid_x, grid_y); } } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); if (num_pts > 1) { if (first_ipt.earlier_valid) { tmp_n = 3; tmp_vs[0].x = ABS_X(grid_x); tmp_vs[0].y = ABS_Y(grid_y); tmp_vs[1].x = ABS_X(first_ipt.earlier_smooth_pt.x); tmp_vs[1].y = ABS_Y(first_ipt.earlier_smooth_pt.y); tmp_vs[2].x = ABS_X(first_ipt.hinge_pt.x); tmp_vs[2].y = ABS_Y(first_ipt.hinge_pt.y); sv2 = MakeSplinePolyVertex(0, curSpline, &sn2, drawOrigX, drawOrigY, tmp_n, tmp_vs); XDrawLines(mainDisplay, drawWindow, drawGC, sv2, sn2, CoordModeOrigin); } else { XDrawLine(mainDisplay, drawWindow, drawGC, first_ipt.hinge_pt.x, first_ipt.hinge_pt.y, grid_x, grid_y); } } } } else { if (num_pts > 1) { if (event_state & ControlMask) { XDrawLine(mainDisplay, drawWindow, drawGC, saved_x, saved_y, grid_x, grid_y); closed = TRUE; } else { closed = FALSE; } } XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); } DoPolygonMeasureCursor(&pmci, POLYGON_DOSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLYGON_DRAW, POLYGON_DRAG, closed); while (XCheckMaskEvent(mainDisplay, PointerMotionMask, &ev)) ; } else if (input.type == ButtonPress) { /* erase */ DoPolygonMeasureCursor(&pmci, POLYGON_ENDSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLYGON_ERASE, POLYGON_DRAG, closed); button_ev = &(input.xbutton); end_x = button_ev->x; end_y = button_ev->y; if (shiftForDiagMouseMove && DiagEventCheck(&input)) { DiagGridXY(OrigX, OrigY, &end_x, &end_y); } GridXY(end_x, end_y, &grid_x, &grid_y); if (grid_x == OrigX && grid_y == OrigY) { if (curSpline == LT_STRUCT_SPLINE) { if (num_pts == 1) { abort = TRUE; } else { /* need to overwrite the previous point */ /* erase */ /* * since we've clicked at the same point, need to pretend * that num_pts is one more */ EraseStructSplineLinesForContAndUpdateSvs(OrigX, OrigY, grid_x, grid_y, &input, num_pts+1, &sv, sn, &sv2, sn2, &ipt_prev, &first_ipt); if (ipt_prev.later_valid) { /* erase whole curve */ DrawAllStructSplinePointsForCont(num_pts); ipt_prev.earlier_valid = ipt_prev.later_valid = FALSE; ipt_prev.earlier_smooth_pt.x = ipt_prev.later_smooth_pt.x = ipt_prev.hinge_pt.x; ipt_prev.earlier_smooth_pt.y = ipt_prev.later_smooth_pt.y = ipt_prev.hinge_pt.y; UpdateLastPointForCont(&ipt_prev); /* draw whole curve */ DrawAllStructSplinePointsForCont(num_pts); } UpdatePrevToLastPointForCont(&ipt_prev); ipt.earlier_valid = ipt.later_valid = FALSE; ipt.earlier_smooth_pt.x = ipt.later_smooth_pt.x = ipt.hinge_pt.x = grid_x; ipt.earlier_smooth_pt.y = ipt.later_smooth_pt.y = ipt.hinge_pt.y = grid_y; OrigX = ipt_prev.hinge_pt.x; OrigY = ipt_prev.hinge_pt.y; if (ipt_prev.later_valid) { pv[0].x = ABS_X(OrigX); pv[0].y = ABS_Y(OrigY); pv[1].x = ABS_X(ipt_prev.later_smooth_pt.x); pv[1].y = ABS_Y(ipt_prev.later_smooth_pt.y); pv[2].x = pv[3].x = ABS_X(grid_x); pv[2].y = pv[3].y = ABS_Y(grid_y); n = 3; sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, pv); } if (first_ipt.earlier_valid) { tmp_n = 3; tmp_vs[0].x = ABS_X(grid_x); tmp_vs[0].y = ABS_Y(grid_y); tmp_vs[1].x = ABS_X(first_ipt.earlier_smooth_pt.x); tmp_vs[1].y = ABS_Y(first_ipt.earlier_smooth_pt.y); tmp_vs[2].x = ABS_X(first_ipt.hinge_pt.x); tmp_vs[2].y = ABS_Y(first_ipt.hinge_pt.y); sv2 = MakeSplinePolyVertex(0, curSpline, &sn2, drawOrigX, drawOrigY, tmp_n, tmp_vs); XDrawLines(mainDisplay, drawWindow, drawGC, sv2, sn2, CoordModeOrigin); } } } } else { num_pts++; ipt.earlier_valid = ipt.later_valid = FALSE; ipt.earlier_smooth_pt.x = ipt.later_smooth_pt.x = ipt.hinge_pt.x = grid_x; ipt.earlier_smooth_pt.y = ipt.later_smooth_pt.y = ipt.hinge_pt.y = grid_y; ipt.ratio = (double)1; AddPointForCont(grid_x, grid_y, &ipt); if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { if (n >= max_n-3) { max_n += 40; pv = (IntPoint*)realloc(pv, sizeof(IntPoint)*max_n+1); if (pv == NULL) FailAllocMessage(); } /* erase */ XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); if (sv != NULL) { free(sv); sv = NULL; } pv[n].x = ABS_X(grid_x); pv[n].y = ABS_Y(grid_y); n++; pv[n].x = pv[0].x; pv[n].y = pv[0].y; switch (curSpline) { case LT_SPLINE: sv = MakeSplinePolygonVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n+1, pv); break; case LT_INTSPLINE: if (cntrlv != NULL) free(cntrlv); sv = MakeIntSplinePolygonVertex(&sn, &intn, &cntrlv, drawOrigX, drawOrigY, n+1, pv); for (i=0; i < sn; i++) { if (sv[i].x < ltx) ltx = sv[i].x; if (sv[i].y < lty) lty = sv[i].y; if (sv[i].x > rbx) rbx = sv[i].x; if (sv[i].y > rby) rby = sv[i].y; } break; } /* draw */ XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); } else if (curSpline == LT_STRUCT_SPLINE) { /* erase */ EraseStructSplineLinesForContAndUpdateSvs(OrigX, OrigY, grid_x, grid_y, &input, num_pts, &sv, sn, &sv2, sn2, &ipt_prev, &first_ipt); /* draw */ if (ipt_prev.later_valid) { pv[0].x = ABS_X(OrigX); pv[0].y = ABS_Y(OrigY); pv[1].x = ABS_X(ipt_prev.later_smooth_pt.x); pv[1].y = ABS_Y(ipt_prev.later_smooth_pt.y); pv[2].x = pv[3].x = ABS_X(grid_x); pv[2].y = pv[3].y = ABS_Y(grid_y); n = 3; sv = MakeSplinePolyVertex(0, curSpline, &sn, drawOrigX, drawOrigY, n, pv); XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); if (first_ipt.earlier_valid) { tmp_n = 3; tmp_vs[0].x = ABS_X(grid_x); tmp_vs[0].y = ABS_Y(grid_y); tmp_vs[1].x = ABS_X(first_ipt.earlier_smooth_pt.x); tmp_vs[1].y = ABS_Y(first_ipt.earlier_smooth_pt.y); tmp_vs[2].x = ABS_X(first_ipt.hinge_pt.x); tmp_vs[2].y = ABS_Y(first_ipt.hinge_pt.y); sv2 = MakeSplinePolyVertex(0, curSpline, &sn2, drawOrigX, drawOrigY, tmp_n, tmp_vs); XDrawLines(mainDisplay, drawWindow, drawGC, sv2, sn2, CoordModeOrigin); } else { XDrawLine(mainDisplay, drawWindow, drawGC, first_ipt.hinge_pt.x, first_ipt.hinge_pt.y, grid_x, grid_y); } } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); if (sv != NULL) { free(sv); sv = NULL; } } } } if (abort) { continue; } if (num_pts == 2 && closed && button_ev->button == Button1 && curSpline == LT_STRAIGHT) { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); } if (grid_x == start_polygon_x && grid_y == start_polygon_y) { if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { /* erase the whole thing */ XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); } else if (curSpline == LT_STRUCT_SPLINE) { CVListElem *elem=ListFirst(&gStructSplineList); IntPointTriplet *pipt=(IntPointTriplet*)(elem->obj); /* erase the last part */ if (nothing_is_drawn) { /* then there is nothing to erase */ nothing_is_drawn = FALSE; } else { EraseStructSplineLinesForContAndUpdateSvs(OrigX, OrigY, grid_x, grid_y, &input, num_pts, &sv, sn, &sv2, sn2, &ipt_prev, &first_ipt); } /* make the last point identical to the first point */ UpdateLastPointForCont(pipt); } else { /* erase the last part */ XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); if (num_pts > 1 && closed) { XDrawLine(mainDisplay, drawWindow, drawGC, saved_x, saved_y, grid_x, grid_y); } if (num_pts < 4) { XDrawLine(mainDisplay, drawWindow, drawGC, saved_x, saved_y, OrigX, OrigY); } } done = TRUE; } else { switch(button_ev->button) { case Button1: if (curSpline == LT_STRUCT_SPLINE) { /* * if the first point is curved, both the curve "before" * and "after have been drawn at this point * if the first point is *not* curved, only the curve "before" * has been drawn, the line "after" is open (not drawn) */ ContinueForStructSplinePolygonControlPoints(OrigX, OrigY, grid_x, grid_y, &sv, &sn, &sv2, &sn2, &first_ipt, &ipt_prev, &ipt, &abort); UpdateLastPointForCont(&ipt); /* at this point, the curve has been drawn */ if (sv != NULL) { free(sv); sv = NULL; if (sv2 == NULL && !first_ipt.earlier_valid) { /* erase it */ XDrawLine(mainDisplay, drawWindow, drawGC, first_ipt.hinge_pt.x, first_ipt.hinge_pt.y, ipt.hinge_pt.x, ipt.hinge_pt.y); } } if (sv2 != NULL) { /* erase it */ XDrawLines(mainDisplay, drawWindow, drawGC, sv2, sn2, CoordModeOrigin); free(sv2); sv2 = NULL; if (ipt.later_valid) { sn = 2; sv = (XPoint*)malloc((sn+1)*sizeof(XPoint)); if (sv == NULL) FailAllocMessage(); sv[0].x = ABS_X(ipt.later_smooth_pt.x); sv[0].y = ABS_Y(ipt.later_smooth_pt.y); sv[1].x = ABS_X(ipt.hinge_pt.x); sv[1].y = ABS_Y(ipt.hinge_pt.y); XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); if (first_ipt.earlier_valid) { tmp_n = 3; tmp_vs[0].x = ABS_X(ipt.later_smooth_pt.x); tmp_vs[0].y = ABS_Y(ipt.later_smooth_pt.y); tmp_vs[1].x = ABS_X(first_ipt.earlier_smooth_pt.x); tmp_vs[1].y = ABS_Y(first_ipt.earlier_smooth_pt.y); tmp_vs[2].x = ABS_X(first_ipt.hinge_pt.x); tmp_vs[2].y = ABS_Y(first_ipt.hinge_pt.y); sv2 = MakeSplinePolyVertex(0, curSpline, &sn2, drawOrigX, drawOrigY, tmp_n, tmp_vs); XDrawLines(mainDisplay, drawWindow, drawGC, sv2, sn2, CoordModeOrigin); } else { XDrawLine(mainDisplay, drawWindow, drawGC, first_ipt.hinge_pt.x, first_ipt.hinge_pt.y, ipt.later_smooth_pt.x, ipt.later_smooth_pt.y); } } else { nothing_is_drawn = TRUE; } } else { nothing_is_drawn = TRUE; } if (!abort) { CVListElem *elem=ListLast(&gStructSplineList); if (elem != NULL) { IntPointTriplet *pipt=(IntPointTriplet*)(elem->obj); memcpy(pipt, &ipt, sizeof(IntPointTriplet)); } memcpy(&ipt_prev, &ipt, sizeof(IntPointTriplet)); OrigX = ipt.hinge_pt.x; OrigY = ipt.hinge_pt.y; if (ipt.later_valid) { grid_x = ipt.later_smooth_pt.x; grid_y = ipt.later_smooth_pt.y; } else { grid_x = ipt.hinge_pt.x; grid_y = ipt.hinge_pt.y; } DoPolygonMeasureCursor(&pmci, POLYGON_STARTSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), ABS_SIZE(abs(grid_x-OrigX)), ABS_SIZE(abs(grid_y-OrigY)), POLYGON_DRAW, POLYGON_CLICK, closed); } } else { OrigX = grid_x; OrigY = grid_y; /* draw */ DoPolygonMeasureCursor(&pmci, POLYGON_STARTSHOW, num_pts, ABS_X(grid_x), ABS_Y(grid_y), 0, 0, POLYGON_DRAW, POLYGON_CLICK, closed); } break; case Button2: case Button3: if (curSpline != LT_STRAIGHT && curSpline != LT_STRUCT_SPLINE) { XDrawLines(mainDisplay, drawWindow, drawGC, sv, sn, CoordModeOrigin); if (num_pts == 1) { done = TRUE; break; } } else if (curSpline == LT_STRUCT_SPLINE) { /* * if the first point is curved, both the curve "before" * and "after have been drawn at this point * if the first point is *not* curved, only the curve "before" * has been drawn, the line "after" is open (not drawn) */ memset(&ipt, 0, sizeof(IntPointTriplet)); ipt.earlier_valid = ipt.later_valid = FALSE; ipt.hinge_pt.x = ipt.earlier_smooth_pt.x = ipt.later_smooth_pt.x = grid_x; ipt.hinge_pt.y = ipt.earlier_smooth_pt.y = ipt.later_smooth_pt.y = grid_y; ipt.ratio = (double)1; ContinueForStructSplinePolygonControlPoints(OrigX, OrigY, grid_x, grid_y, &sv, &sn, &sv2, &sn2, &first_ipt, &ipt_prev, &ipt, &abort); UpdateLastPointForCont(&ipt); if (num_pts == 1 && !first_ipt.later_valid && !ipt.earlier_valid) { done = TRUE; break; } } else { XDrawLine(mainDisplay, drawWindow, drawGC, OrigX, OrigY, grid_x, grid_y); if (num_pts > 1 && closed) { XDrawLine(mainDisplay, drawWindow, drawGC, saved_x, saved_y, grid_x, grid_y); } if (num_pts < 3) { XDrawLine(mainDisplay, drawWindow, drawGC, saved_x, saved_y, OrigX, OrigY); } if (num_pts == 1) { done = TRUE; break; } } num_pts++; AddPointForCont(start_polygon_x, start_polygon_y, &first_ipt); done = TRUE; break; } } } } XUngrabPointer(mainDisplay, CurrentTime); RestoreStatusStrings(); SetMouseStatus(NULL, NULL, NULL); Msg(""); if (pv != NULL) free(pv); if (sv != NULL) free(sv); if (cntrlv != NULL) free(cntrlv); if (!abort) { if (curSpline == LT_STRUCT_SPLINE) { int num_actual_vs=CountStructuredSplinePolygonVs(); if (num_actual_vs <= 3) { abort = TRUE; } } else if (num_pts <= 3) { abort = TRUE; } } if (!abort) { CreatePolygonObj(num_pts, CREATE_RELATIVE); RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); polygonDrawn = TRUE; SetFileModified(TRUE); } else { if (curSpline != LT_INTSPLINE) { ltx = rbx = grid_x; lty = rby = grid_y; } FreePointsForCont(<x, <y, &rbx, &rby); RedrawAnArea(botObj, ABS_X(ltx)-GRID_ABS_SIZE(1), ABS_Y(lty)-GRID_ABS_SIZE(1), ABS_X(rbx)+GRID_ABS_SIZE(1), ABS_Y(rby)+GRID_ABS_SIZE(1)); numPtsInPoly = 0; lastPtPtr = NULL; polygonDrawn = FALSE; } } void DrawPolygon(input) XEvent *input; { XButtonEvent *button_ev; int mouse_x, mouse_y, grid_x, grid_y; if (input->type != ButtonPress) return; button_ev = &(input->xbutton); if (button_ev->button == Button1) { mouse_x = button_ev->x; mouse_y = button_ev->y; GridXY(mouse_x, mouse_y, &grid_x, &grid_y); ContinuePolygon(grid_x, grid_y); } } void SelectAndHighLightNewObjects(PrevTopObj) struct ObjRec *PrevTopObj; { register struct ObjRec *obj_ptr; register struct SelRec *sel_ptr; if (topSel != NULL) { HighLightReverse(); RemoveAllSel(); } for (obj_ptr=topObj; obj_ptr != PrevTopObj; obj_ptr=obj_ptr->next) { sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (sel_ptr == NULL) FailAllocMessage(); sel_ptr->obj = obj_ptr; sel_ptr->prev = sel_ptr->next = NULL; AddSel(botSel, NULL, sel_ptr); } UpdSelBBox(); HighLightForward(); } void InputPolygonPts() { char inbuf[MAXSTRING+1]; int more_polygon=FALSE, num_polygons=0; int started_composite=FALSE; struct ObjRec *saved_top_obj=topObj; MakeQuiescent(); XSync(mainDisplay, False); do { int len, ok=TRUE, num_pts=0; int first_x=0, first_y=0, eof=TRUE; struct PtRec *pt_ptr; more_polygon = FALSE; numPtsInPoly = 0; lastPtPtr = NULL; printf("%s\n", TgLoadString(STID_INPUT_PAIRS_OF_POINTS_POLYGON)); printf("> "); fflush(stdout); while (ok && fgets(inbuf, MAXSTRING, stdin) != NULL) { if (strcmp(inbuf, ";\n") == 0) { eof = FALSE; more_polygon = TRUE; break; } if (strcmp(inbuf, ".\n") == 0) { eof = FALSE; break; } len = strlen(inbuf); if (len > 0) { char *c_ptr=strtok(inbuf," ,\t\n"), *c_ptr1=NULL; if (c_ptr != NULL) c_ptr1 = strtok(NULL," ,\t\n"); if (c_ptr1 != NULL) while (strchr(" ,\t\n", *c_ptr1)) c_ptr1++; while (c_ptr != NULL && c_ptr1 != NULL) { num_pts++; pt_ptr = (struct PtRec *)malloc(sizeof(struct PtRec)); if (pt_ptr == NULL) FailAllocMessage(); pt_ptr->next = lastPtPtr; if (sscanf(c_ptr, "%d", &pt_ptr->x) != 1 || sscanf(c_ptr1, "%d", &pt_ptr->y) != 1) { ok = FALSE; MsgBox(TgLoadString(STID_READ_INT_ERR_FOR_POLYGON_PTS), TOOL_NAME, INFO_MB); XSync(mainDisplay, False); break; } if (lastPtPtr == NULL) { first_x = pt_ptr->x; first_y = pt_ptr->y; } lastPtPtr = pt_ptr; c_ptr = strtok(NULL," ,\t\n"); if (c_ptr != NULL) c_ptr1 = strtok(NULL," ,\t\n"); if (c_ptr1 != NULL) while (strchr(" ,\t\n", *c_ptr1)) c_ptr1++; } if (c_ptr != NULL) { ok = FALSE; MsgBox(TgLoadString(STID_READ_INT_ERR_FOR_POLYGON_PTS), TOOL_NAME, INFO_MB); XSync(mainDisplay, False); } } printf("> "); fflush(stdout); } printf("\n"); if (eof) rewind(stdin); if (ok && num_pts > 2) { num_polygons++; if (lastPtPtr->x != first_x || lastPtPtr->y != first_y) { num_pts++; pt_ptr = (struct PtRec *)malloc(sizeof(struct PtRec)); if (pt_ptr == NULL) FailAllocMessage(); pt_ptr->next = lastPtPtr; pt_ptr->x = first_x; pt_ptr->y = first_y; lastPtPtr = pt_ptr; } CreatePolygonObj(num_pts, CREATE_ABSOLUTE); if (more_polygon || num_polygons > 1) { if (num_polygons <= 1) { StartCompositeCmd(); started_composite = TRUE; } RecordNewObjCmd(); numRedrawBBox = 0; topObj->tmp_parent = NULL; DrawObj(drawWindow, topObj); } else { RecordNewObjCmd(); RedrawAnArea(botObj, topObj->bbox.ltx-GRID_ABS_SIZE(1), topObj->bbox.lty-GRID_ABS_SIZE(1), topObj->bbox.rbx+GRID_ABS_SIZE(1), topObj->bbox.rby+GRID_ABS_SIZE(1)); SelectTopObj(); SetFileModified(TRUE); justDupped = FALSE; } } if (ok && num_pts <= 2) { MsgBox(TgLoadString(STID_TOO_FEW_POINTERS_ENTERED), TOOL_NAME, INFO_MB); XSync(mainDisplay, False); } for ( ; lastPtPtr != NULL; lastPtPtr=pt_ptr) { pt_ptr = lastPtPtr->next; free(pt_ptr); } } while (more_polygon); if (num_polygons > 1 || started_composite) { SelectAndHighLightNewObjects(saved_top_obj); GroupSelObj(TRUE, TRUE, TRUE); EndCompositeCmd(); SetFileModified(TRUE); justDupped = FALSE; } } static void AddToLastPoint(XOff, YOff) int XOff, YOff; { struct PtRec *pt_ptr=(struct PtRec *)malloc(sizeof(struct PtRec)); if (pt_ptr == NULL) FailAllocMessage(); pt_ptr->next = lastPtPtr; numPtsInPoly++; lastPtPtr = pt_ptr; pt_ptr->x = XOff; pt_ptr->y = YOff; } void GetBoundingBox() { struct SelRec *sel_ptr, *tmp_top_sel=NULL, *tmp_bot_sel=NULL; int num_created=0, saved_cur_spline=curSpline; if (topSel == NULL) { MsgBox(TgLoadCachedString(CSTID_NO_OBJ_SELECTED), TOOL_NAME, INFO_MB); return; } if (curChoice == VERTEXMODE) SetCurChoice(NOTHING); curSpline = LT_STRAIGHT; tmp_top_sel = tmp_bot_sel = NULL; HighLightReverse(); StartCompositeCmd(); for (sel_ptr=botSel; sel_ptr != NULL; sel_ptr=sel_ptr->prev) { struct ObjRec *obj_ptr=sel_ptr->obj; struct SelRec *new_sel_ptr; if (obj_ptr->ctm == NULL) { struct BBRec *p_obbox=(&obj_ptr->obbox); AddToLastPoint(p_obbox->ltx, p_obbox->lty); AddToLastPoint(p_obbox->ltx, p_obbox->rby); AddToLastPoint(p_obbox->rbx, p_obbox->rby); AddToLastPoint(p_obbox->rbx, p_obbox->lty); AddToLastPoint(p_obbox->ltx, p_obbox->lty); CreatePolygonObj(5, CREATE_ABSOLUTE); } else { int i; numPtsInPoly = 0; lastPtPtr = NULL; for (i=0; i < 5; i++) { AddToLastPoint(obj_ptr->rotated_obbox[i].x, obj_ptr->rotated_obbox[i].y); } CreatePolygonObj(5, CREATE_RELATIVE); } new_sel_ptr = (struct SelRec *)malloc(sizeof(struct SelRec)); if (new_sel_ptr == NULL) FailAllocMessage(); new_sel_ptr->obj = topObj; new_sel_ptr->next = NULL; new_sel_ptr->prev = NULL; PrepareToRecord(CMD_NEW, NULL, NULL, 0); RecordCmd(CMD_NEW, NULL, new_sel_ptr, new_sel_ptr, 1); new_sel_ptr->next = tmp_top_sel; if (tmp_top_sel == NULL) { tmp_bot_sel = new_sel_ptr; } else { tmp_top_sel->prev = new_sel_ptr; } tmp_top_sel = new_sel_ptr; num_created++; } EndCompositeCmd(); curSpline = saved_cur_spline; RemoveAllSel(); topSel = tmp_top_sel; botSel = tmp_bot_sel; UpdSelBBox(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); HighLightForward(); justDupped = FALSE; SetFileModified(TRUE); } void SavePolygonObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { register int i, n; int count; struct PolygonRec *polygon_ptr=ObjPtr->detail.g; n = polygon_ptr->n; if (fprintf(FP, "polygon('%s','',%1d,[\n\t", colorMenuItems[ObjPtr->color], polygon_ptr->n) == EOF) { writeFileFailed = TRUE; } for (i=0, count = 0; i < n-1; i++) { if (fprintf(FP, "%1d,%1d,", polygon_ptr->vlist[i].x, polygon_ptr->vlist[i].y) == EOF) { writeFileFailed = TRUE; } if (++count == 8) { count = 0; if (fprintf(FP, "\n\t") == EOF) writeFileFailed = TRUE; } } if (fprintf(FP, "%1d,%1d],", polygon_ptr->vlist[n-1].x, polygon_ptr->vlist[n-1].y) == EOF) writeFileFailed = TRUE; if (fprintf(FP, "%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,%1d,'%s',%1d,", polygon_ptr->fill, polygon_ptr->width, polygon_ptr->pen, polygon_ptr->curved, ObjPtr->id, polygon_ptr->dash, ObjPtr->rotation, ObjPtr->locked, ObjPtr->ctm!=NULL, ObjPtr->invisible, polygon_ptr->width_spec, ObjPtr->trans_pat) == EOF) { writeFileFailed = TRUE; } if (fprintf(FP, "\n \"") == EOF) writeFileFailed = TRUE; SaveSmoothHinge(FP, polygon_ptr->curved, polygon_ptr->n, polygon_ptr->smooth); if (fprintf(FP, "\",") == EOF) writeFileFailed = TRUE; if (ObjPtr->ctm != NULL && fprintf(FP, "[\n\t%1d,%1d,%1d,%1d,%1d,%1d,%g,%g,%g,%g,%1d,%1d],", ObjPtr->x, ObjPtr->y, ObjPtr->orig_obbox.ltx, ObjPtr->orig_obbox.lty, ObjPtr->orig_obbox.rbx, ObjPtr->orig_obbox.rby, ObjPtr->ctm->m[CTM_SX], ObjPtr->ctm->m[CTM_SIN], ObjPtr->ctm->m[CTM_MSIN], ObjPtr->ctm->m[CTM_SY], ObjPtr->ctm->t[CTM_TX], ObjPtr->ctm->t[CTM_TY]) == EOF) { writeFileFailed = TRUE; } if (serializingFile) SaveCreatorID(FP, ObjPtr, " "); SaveAttrs(FP, ObjPtr->lattr); if (fprintf(FP, ")") == EOF) writeFileFailed = TRUE; } void ReadPolygonObj(FP, Inbuf, ObjPtr) FILE *FP; char *Inbuf; struct ObjRec **ObjPtr; { register int i; struct PolygonRec *polygon_ptr; IntPoint *v; char color_str[40], bg_color_str[40], *s, inbuf[MAXSTRING]; int num_pts, ltx=0, lty=0, rbx=0, rby=0, x, y, id=0; int trans_pat=FALSE, fill, width, pen, w, new_alloc, locked=FALSE; int curved, dash, initialized, rotation, count; int real_x=0, real_y=0, transformed=FALSE, invisible=FALSE; char *smooth=NULL, width_spec[40]; struct XfrmMtrxRec *ctm=NULL; struct BBRec orig_obbox; *ObjPtr = NULL; s = FindChar((int)'(', Inbuf); s = ParseStr(s, (int)',', color_str, sizeof(color_str)); if (fileVersion >= 37) { s = ParseStr(s, (int)',', bg_color_str, sizeof(bg_color_str)); } InitScan(s, "\t\n, []"); if (GETINT("polygon", num_pts, "number of points") == INVALID) { return; } if (num_pts <= 0) { (void)sprintf(gszMsgBox, TgLoadString(STID_INVALID_NUM_PTS_IN_POLYGON), scanFileName, scanLineNum); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } return; } *ObjPtr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (*ObjPtr == NULL) FailAllocMessage(); memset(*ObjPtr, 0, sizeof(struct ObjRec)); polygon_ptr = (struct PolygonRec *)malloc(sizeof(struct PolygonRec)); if (polygon_ptr == NULL) FailAllocMessage(); memset(polygon_ptr, 0, sizeof(struct PolygonRec)); if (num_pts < 3) { v = (IntPoint*)malloc(5*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); smooth = (char*)malloc(5*sizeof(char)); if (smooth == NULL) FailAllocMessage(); } else { v = (IntPoint*)malloc((num_pts+1)*sizeof(IntPoint)); if (v == NULL) FailAllocMessage(); smooth = (char*)malloc((num_pts+1)*sizeof(char)); if (smooth == NULL) FailAllocMessage(); } initialized = FALSE; *width_spec = '\0'; if (fileVersion <= 13) { for (i=0; i < num_pts; i++) { if (GETINT("polygon", x, "x") == INVALID || GETINT("polygon", y, "y") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } v[i].x = x; v[i].y = y; if (!initialized) { initialized = TRUE; ltx = rbx = x; lty = rby = y; } else { if (x < ltx) ltx = x; if (y < lty) lty = y; if (x > rbx) rbx = x; if (y > rby) rby = y; } } } else { (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; s = inbuf; InitScan(s, "\t\n, []"); for (i=0, count = 0; i < num_pts; i++) { if (GETINT("polygon", x, "x") == INVALID || GETINT("polygon", y, "y") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } v[i].x = x; v[i].y = y; if (!initialized) { initialized = TRUE; ltx = rbx = x; lty = rby = y; } else { if (x < ltx) ltx = x; if (y < lty) lty = y; if (x > rbx) rbx = x; if (y > rby) rby = y; } if (++count == 8 && i != num_pts-1) { count = 0; (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; s = inbuf; InitScan(s, "\t\n, []"); } } } switch (num_pts) { case 1: sprintf(gszMsgBox, TgLoadCachedString(CSTID_SNGL_PT_POLYGON_CONVERTED), v[0].x, v[0].y); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } v[3].x = v[2].x = v[1].x = v[0].x; v[3].y = v[2].y = v[1].y = v[0].y; num_pts = 4; break; case 2: sprintf(gszMsgBox, TgLoadCachedString(CSTID_TWO_PT_POLYGON_CONVERTED), v[0].x, v[0].y, v[1].x, v[1].y); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } v[3].x = v[2].x = v[0].x; v[3].y = v[2].y = v[0].y; num_pts = 4; break; case 3: sprintf(gszMsgBox, TgLoadCachedString(CSTID_TWO_PT_POLYGON_CONVERTED), v[0].x, v[0].y, v[1].x, v[1].y); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } v[3].x = v[2].x = v[0].x; v[3].y = v[2].y = v[0].y; num_pts = 4; break; } polygon_ptr->n = num_pts; dash = 0; rotation = 0; if (fileVersion <= 3) { if (GETINT("polygon", fill, "fill") == INVALID || GETINT("polygon", width, "width") == INVALID || GETINT("polygon", pen, "pen") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } if (width == LINE_CURVED) { width = 0; curved = TRUE; } else { curved = FALSE; } switch (width) { case 1: width = 3; break; case 2: width = 6; break; } id = objId++; } else if (fileVersion <= 5) { if (GETINT("polygon", fill, "fill") == INVALID || GETINT("polygon", width, "width") == INVALID || GETINT("polygon", pen, "pen") == INVALID || GETINT("polygon", curved, "curved") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } switch (width) { case 1: width = 3; break; case 2: width = 6; break; } id = objId++; } else if (fileVersion <= 7) { if (GETINT("polygon", fill, "fill") == INVALID || GETINT("polygon", width, "width") == INVALID || GETINT("polygon", pen, "pen") == INVALID || GETINT("polygon", curved, "curved") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } id = objId++; } else if (fileVersion <= 8) { if (GETINT("polygon", fill, "fill") == INVALID || GETINT("polygon", width, "width") == INVALID || GETINT("polygon", pen, "pen") == INVALID || GETINT("polygon", curved, "curved") == INVALID || GETINT("polygon", id, "id") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 13) { if (GETINT("polygon", fill, "fill") == INVALID || GETINT("polygon", width, "width") == INVALID || GETINT("polygon", pen, "pen") == INVALID || GETINT("polygon", curved, "curved") == INVALID || GETINT("polygon", id, "id") == INVALID || GETINT("polygon", dash, "dash") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 25) { if (GETINT("polygon", fill, "fill") == INVALID || GETINT("polygon", width, "width") == INVALID || GETINT("polygon", pen, "pen") == INVALID || GETINT("polygon", curved, "curved") == INVALID || GETINT("polygon", id, "id") == INVALID || GETINT("polygon", dash, "dash") == INVALID || GETINT("polygon", rotation, "rotation") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 32) { if (GETINT("polygon", fill, "fill") == INVALID || GETINT("polygon", width, "width") == INVALID || GETINT("polygon", pen, "pen") == INVALID || GETINT("polygon", curved, "curved") == INVALID || GETINT("polygon", id, "id") == INVALID || GETINT("polygon", dash, "dash") == INVALID || GETINT("polygon", rotation, "rotation") == INVALID || GETINT("polygon", locked, "locked") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; } else if (fileVersion <= 34) { if (GETINT("polygon", fill, "fill") == INVALID || GETINT("polygon", width, "width") == INVALID || GETINT("polygon", pen, "pen") == INVALID || GETINT("polygon", curved, "curved") == INVALID || GETINT("polygon", id, "id") == INVALID || GETINT("polygon", dash, "dash") == INVALID || GETINT("polygon", rotation, "rotation") == INVALID || GETINT("polygon", locked, "locked") == INVALID || GETINT("polygon", transformed, "transformed") == INVALID || GETINT("polygon", invisible, "invisible") == INVALID || GETSTR("polygon", width_spec, "width_spec") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); } else { if (GETINT("polygon", fill, "fill") == INVALID || GETINT("polygon", width, "width") == INVALID || GETINT("polygon", pen, "pen") == INVALID || GETINT("polygon", curved, "curved") == INVALID || GETINT("polygon", id, "id") == INVALID || GETINT("polygon", dash, "dash") == INVALID || GETINT("polygon", rotation, "rotation") == INVALID || GETINT("polygon", locked, "locked") == INVALID || GETINT("polygon", transformed, "transformed") == INVALID || GETINT("polygon", invisible, "invisible") == INVALID || GETSTR("polygon", width_spec, "width_spec") == INVALID || GETINT("polygon", trans_pat, "trans_pat") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } if (id >= objId) objId = id+1; UtilRemoveQuotes(width_spec); } if (fileVersion <= 16 && width <= 6) width = origWidthOfLine[width]; if (fileVersion <= 25 && curved > 1) curved = 0; if (curved == LT_INTSPLINE && smooth != NULL) { free(smooth); smooth = NULL; } if (fileVersion <= 30) { switch (curved) { case LT_STRAIGHT: for (i=0; i < num_pts; i++) smooth[i] = FALSE; break; case LT_SPLINE: for (i=0; i < num_pts; i++) smooth[i] = TRUE; break; } } else if (!ReadSmoothHinge(FP, curved, num_pts, smooth)) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; return; } if (fileVersion >= 33 && transformed) { (void)fgets(inbuf, MAXSTRING, FP); scanLineNum++; InitScan(inbuf, "\t\n, "); ctm = (struct XfrmMtrxRec *)malloc(sizeof(struct XfrmMtrxRec)); if (ctm == NULL) FailAllocMessage(); if (GETINT("polygon", real_x, "real_x") == INVALID || GETINT("polygon", real_y, "real_y") == INVALID || GETINT("polygon", orig_obbox.ltx, "orig_obbox.ltx") == INVALID || GETINT("polygon", orig_obbox.lty, "orig_obbox.lty") == INVALID || GETINT("polygon", orig_obbox.rbx, "orig_obbox.rbx") == INVALID || GETINT("polygon", orig_obbox.rby, "orig_obbox.rby") == INVALID || GETDBL("polygon", ctm->m[CTM_SX], "CTM_SX") == INVALID || GETDBL("polygon", ctm->m[CTM_SIN], "CTM_SIN") == INVALID || GETDBL("polygon", ctm->m[CTM_MSIN], "CTM_MSIN") == INVALID || GETDBL("polygon", ctm->m[CTM_SY], "CTM_SY") == INVALID || GETINT("polygon", ctm->t[CTM_TX], "CTM_TX") == INVALID || GETINT("polygon", ctm->t[CTM_TY], "CTM_TY") == INVALID) { free(*ObjPtr); free(polygon_ptr); free(v); *ObjPtr = NULL; free(ctm); return; } } if (fileVersion <= 32) { sprintf(width_spec, "%1d", width); } fill = UpgradePenFill(fill); pen = UpgradePenFill(pen); polygon_ptr->fill = fill; polygon_ptr->width = width; UtilStrCpyN(polygon_ptr->width_spec, sizeof(polygon_ptr->width_spec), width_spec); polygon_ptr->pen = pen; polygon_ptr->curved = curved; polygon_ptr->dash = dash; polygon_ptr->vlist = v; polygon_ptr->smooth = smooth; polygon_ptr->svlist = NULL; polygon_ptr->intvlist = NULL; polygon_ptr->rotated_n = 0; polygon_ptr->rotated_vlist = NULL; (*ObjPtr)->x = ltx; (*ObjPtr)->y = lty; (*ObjPtr)->color = QuickFindColorIndex(*ObjPtr, color_str, &new_alloc, TRUE); UtilStrCpyN((*ObjPtr)->color_str, sizeof((*ObjPtr)->color_str), color_str); (*ObjPtr)->dirty = FALSE; (*ObjPtr)->id = id; (*ObjPtr)->rotation = rotation; (*ObjPtr)->locked = locked; (*ObjPtr)->type = OBJ_POLYGON; (*ObjPtr)->obbox.ltx = ltx; (*ObjPtr)->obbox.lty = lty; (*ObjPtr)->obbox.rbx = rbx; (*ObjPtr)->obbox.rby = rby; w = HALF_W(width); (*ObjPtr)->bbox.ltx = ltx - w; (*ObjPtr)->bbox.lty = lty - w; (*ObjPtr)->bbox.rbx = rbx + w; (*ObjPtr)->bbox.rby = rby + w; (*ObjPtr)->detail.g = polygon_ptr; (*ObjPtr)->ctm = ctm; (*ObjPtr)->invisible = invisible; (*ObjPtr)->trans_pat = trans_pat; if (ctm != NULL) { memcpy(&(*ObjPtr)->orig_obbox, &orig_obbox, sizeof(struct BBRec)); (*ObjPtr)->x = real_x; (*ObjPtr)->y = real_y; GetTransformedOBBoxOffsetVs(*ObjPtr, (*ObjPtr)->rotated_obbox); } AdjObjCache(*ObjPtr); AdjObjSplineVs(*ObjPtr); if (polygon_ptr->curved != LT_INTSPLINE) { UpdPolyBBox(*ObjPtr, polygon_ptr->n, polygon_ptr->vlist); } else { UpdPolyBBox(*ObjPtr, polygon_ptr->intn, polygon_ptr->intvlist); } } void SetPolygonPropMask(ObjPtr, plMask, plSkip, pProp) struct ObjRec *ObjPtr; long *plMask, *plSkip; struct PropertiesRec *pProp; { struct PolygonRec *polygon_ptr=ObjPtr->detail.g; SetCTMPropertyMask(ObjPtr->ctm, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_COLOR, ObjPtr->color, colorMenuItems[ObjPtr->color], plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_WIDTH, polygon_ptr->width, polygon_ptr->width_spec, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_TRANSPAT, ObjPtr->trans_pat, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_FILL, polygon_ptr->fill, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_PEN, polygon_ptr->pen, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_DASH, polygon_ptr->dash, NULL, plMask, plSkip, pProp); SetIntPropertyMask(PROP_MASK_CURVED, polygon_ptr->curved, NULL, plMask, plSkip, pProp); } void FreePolygonObj(ObjPtr) struct ObjRec *ObjPtr; { if (ObjPtr->detail.g->ssvlist != NULL) free(ObjPtr->detail.g->ssvlist); if (ObjPtr->detail.g->intvlist != NULL) free(ObjPtr->detail.g->intvlist); if (ObjPtr->detail.g->svlist != NULL) free(ObjPtr->detail.g->svlist); if (ObjPtr->detail.g->rotated_vlist != NULL) { free(ObjPtr->detail.g->rotated_vlist); } free(ObjPtr->detail.g->vlist); if (ObjPtr->detail.g->smooth != NULL) free(ObjPtr->detail.g->smooth); if (ObjPtr->detail.g->ssmooth != NULL) free(ObjPtr->detail.g->ssmooth); free(ObjPtr->detail.g); free(ObjPtr); } �������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/eps.c��������������������������������������������������������������������������������0000644�0000764�0000764�00000171623�11602233311�013730� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/eps.c,v 1.9 2011/05/16 16:21:57 william Exp $ */ #define _INCLUDE_FROM_EPS_C_ #include "tgifdefs.h" #include "cmd.e" #include "color.e" #include "cursor.e" #include "dialog.e" #include "drawing.e" #include "dup.e" #include "eps.e" #include "file.e" #include "grid.e" #include "mark.e" #include "msg.e" #include "names.e" #include "obj.e" #include "pattern.e" #include "ps.e" #include "rect.e" #include "select.e" #include "setup.e" #include "special.e" #include "strtbl.e" #include "util.e" #include "xbitmap.e" #ifndef SEEK_SET #define SEEK_SET 0 #endif /* ~SEEK_SET */ typedef struct EPSLineRec { char *s; struct EPSLineRec *next, *prev; } *EPSLineRecPtr; float defaultEPSScaling=1.0; char defaultEPSScalingStr[80]; int autoEPSPreviewBitmap=FALSE; static struct EPSLineRec *topLine=NULL, *botLine=NULL; static int numLines=0; static char tiffToXbmCmd[MAXSTRING+1]; static int tiffToXbmCmdInitialized=FALSE; static char psToXbmCmd[MAXSTRING+1]; /* do not translate -- program constants */ static char hexValue[]="0123456789abcdef"; static char flippedHexValue[]="084c2a6e195d3b7f"; static char defTiffToXbmCmd[]="tifftopnm %s | pgmtopbm | pbmtoxbm"; static char defPsToXbmCmd[] = "gs -q -dNOPAUSE -sDEVICE=pbm -sOutputFile=- -- \"%s\" | pbmtoxbm"; static float bitmapThresholdFor8bpsPreviewBitmap=(float)0.5; void InitEPS() { char *c_ptr=NULL; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"ForceClearAfterEPS")) != NULL) { fprintf(stderr, TgLoadString(STID_NAMED_XDEF_IS_OBSOLETE), TOOL_NAME, "ForceClearAfterEPS"); fprintf(stderr, "\n"); } defaultEPSScaling = 1.0; strcpy(defaultEPSScalingStr, "1"); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"DefaultEPSScaling")) != NULL) { strcpy(defaultEPSScalingStr, c_ptr); defaultEPSScaling = (float)atof(c_ptr); if (defaultEPSScaling <= 0.0) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_VALUE), TOOL_NAME, "DefaultEPSScaling", c_ptr, 1); defaultEPSScaling = 1.0; strcpy(defaultEPSScalingStr, "1"); } else if (strcmp(defaultEPSScalingStr,"1")==0 || strcmp(defaultEPSScalingStr,"1.0")==0) { defaultEPSScaling = 1.0; strcpy(defaultEPSScalingStr, "1"); } } tiffToXbmCmdInitialized = TRUE; /* do not translate -- program constants */ strcpy(tiffToXbmCmd, defTiffToXbmCmd); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"TiffToXbm")) != NULL) { int count=0; strcpy(tiffToXbmCmd, c_ptr); for (c_ptr=strstr(tiffToXbmCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "TiffToXbm", tiffToXbmCmd, defTiffToXbmCmd); strcpy(tiffToXbmCmd, defTiffToXbmCmd); } } /* do not translate -- program constants */ strcpy(psToXbmCmd, defPsToXbmCmd); if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"PsToXbm")) != NULL) { int count=0; strcpy(psToXbmCmd, c_ptr); for (c_ptr=strstr(psToXbmCmd,"%s"); c_ptr!=NULL; c_ptr=strstr(++c_ptr,"%s")) { count++; } if (count != 1) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "PsToXbm", psToXbmCmd, defPsToXbmCmd); strcpy(psToXbmCmd, defPsToXbmCmd); } } autoEPSPreviewBitmap = FALSE; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"AutoEPSPreviewBitmap")) != NULL && UtilStrICmp(c_ptr, "true") == 0) { autoEPSPreviewBitmap = TRUE; } bitmapThresholdFor8bpsPreviewBitmap = (float)0.5; if ((c_ptr=XGetDefault(mainDisplay,TOOL_NAME,"BitmapThreshold"))!=NULL) { bitmapThresholdFor8bpsPreviewBitmap = (float) atof(c_ptr); if (bitmapThresholdFor8bpsPreviewBitmap < ((float)0) || bitmapThresholdFor8bpsPreviewBitmap > (((float)1)+INT_TOL)) { fprintf(stderr, TgLoadString(STID_INVALID_XDEF_USE_ALT_STR), TOOL_NAME, "BitmapThreshold", c_ptr, "0.5"); fprintf(stderr, "\n"); bitmapThresholdFor8bpsPreviewBitmap = (float)0.5; } } } static void CleanUpLines() { struct EPSLineRec *line_ptr, *next_line; for (line_ptr=topLine; line_ptr != NULL; line_ptr=next_line) { next_line = line_ptr->next; if (line_ptr->s != NULL) free(line_ptr->s); free(line_ptr); } topLine = botLine = NULL; numLines = 0; } void CleanUpEPS() { CleanUpLines(); stripEPSComments = FALSE; } static void DumpXBmByte(fp, num_nibbles, image_h, nibble_index, row_index, byte_data, pn_out_byte_count) FILE *fp; int num_nibbles, image_h, nibble_index, row_index; int byte_data, *pn_out_byte_count; { if ((*pn_out_byte_count)++ == 12) { (*pn_out_byte_count) = 1; if (fprintf(fp, "\n ") == EOF) writeFileFailed = TRUE; } if (fprintf(fp, "0x%c", flippedHexValue[(byte_data>>4) & 0xf]) == EOF) { writeFileFailed = TRUE; } if (row_index == image_h-1 && nibble_index == num_nibbles-1) { if (fprintf(fp, "%c};\n", flippedHexValue[byte_data & 0xf]) == EOF) { writeFileFailed = TRUE; } } else { if (fprintf(fp, "%c, ", flippedHexValue[byte_data & 0xf]) == EOF) { writeFileFailed = TRUE; } } } static int UpdateEndDetectState(c, p_end_detect_state, p_line_count) char c; int *p_end_detect_state; int *p_line_count; { int end_detect_state=(*p_end_detect_state); if (c == '\n') { (*p_line_count)++; *p_end_detect_state = 0; return FALSE; } switch (end_detect_state) { case 0: *p_end_detect_state = ((c == '%') ? 1 : 0); break; case 1: *p_end_detect_state = ((c == '%') ? 2 : 0); break; case 2: *p_end_detect_state = ((c == 'E' || c == 'e') ? 3 : 0); break; case 3: *p_end_detect_state = ((c == 'n') ? 4 : 0); break; case 4: *p_end_detect_state = ((c == 'd') ? 5 : 0); break; default: *p_end_detect_state = 0; break; } return (*p_end_detect_state == 5); } static int ReadPreviewBitmap(fp, file_name, image_w, image_h, bps, bitmap, image) FILE *fp; char *file_name; int image_w, image_h, bps; Pixmap *bitmap; XImage **image; { int k=0, j=0, i=0, num_nibbles=0, bit_count=0, out_byte_count=0, line_sz=0; int line_count=0, end_detect_state=0; /* detecting "%%End..." */ char *line=NULL, *c_ptr=NULL; switch (bps) { case 1: num_nibbles = ((image_w & 0x3)==0) ? (int)(image_w>>2) : (int)(image_w>>2)+1; if (num_nibbles & 0x1) num_nibbles++; break; case 8: num_nibbles = (image_w<<1); break; default: sprintf(gszMsgBox, TgLoadString(STID_GIVEN_BPS_PREVIEW_NOT_SUP), bps); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } line_sz = (num_nibbles+10)*sizeof(char); line = (char*)malloc(line_sz); if (line == NULL) FailAllocMessage(); if (cmdLineDosEpsFilter && cmdLinePreviewOnly) { *bitmap = None; *image = NULL; /* do not translate -- program constants */ printf("#define noname_width %1d\n", image_w); printf("#define noname_height %1d\n", image_h); printf("#define noname_x_hot 0\n"); printf("#define noname_y_hot 0\n"); printf("static char noname_bits[] = {\n "); } else { *bitmap = XCreatePixmap(mainDisplay, dummyBitmap, image_w, image_h, 1); XFillRectangle(mainDisplay, *bitmap, xbmGC, 0, 0, image_w, image_h); *image = XGetImage(mainDisplay,*bitmap,0,0,image_w,image_h,1,ZPixmap); } for (i=0; i < image_h; i++) { int byte_data=0; for (j=0, c_ptr=line; j < num_nibbles; j++, c_ptr++) { while (TRUE) { int c=getc(fp); if (c == EOF) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PREVIEW_BMP_IN_EPS), file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(line); if (*bitmap != None) { XFreePixmap(mainDisplay, *bitmap); *bitmap = None; } if (*image != NULL) { XDestroyImage(*image); *image = NULL; } return FALSE; } *c_ptr = (char)c; if (UpdateEndDetectState(*c_ptr, &end_detect_state, &line_count)) { /* %%End... detected */ sprintf(gszMsgBox, TgLoadString(STID_INVALID_PREVIEW_BMP_IN_EPS), file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(line); if (*bitmap != None) { XFreePixmap(mainDisplay, *bitmap); *bitmap = None; } if (*image != NULL) { XDestroyImage(*image); *image = NULL; } return FALSE; } if ((*c_ptr >= '0' && *c_ptr <= '9') || (*c_ptr >= 'a' && *c_ptr <= 'f') || (*c_ptr >= 'A' && *c_ptr <= 'F')) { break; } } } *c_ptr = '\0'; bit_count = 0; c_ptr = line; for (j=0; j<num_nibbles && *c_ptr!='\0'; j++, c_ptr++) { int data=0; if (*c_ptr >= '0' && *c_ptr <= '9') { data = (int)(*c_ptr) - (int)('0'); } else if (*c_ptr >= 'a' && *c_ptr <= 'f') { data = (int)(*c_ptr) - (int)('a') + 10; } else if (*c_ptr >= 'A' && *c_ptr <= 'F') { data = (int)(*c_ptr) - (int)('A') + 10; } else { break; } if (cmdLineDosEpsFilter && cmdLinePreviewOnly) { if (j & 0x1) { byte_data |= (data<<4); DumpXBmByte(stdout, num_nibbles, image_h, j, i, byte_data, &out_byte_count); } else { byte_data = data; } } else { switch (bps) { case 1: for (k = 0; k < 4; k++) { if (bit_count++ == image_w) break; if (data & (1<<(3-k))) { XPutPixel(*image, j*4+k, i, 1); } } break; case 8: if (j & 0x1) { double dval=(double)0; byte_data |= (data<<4); dval = (((double)byte_data) / ((double)255)); if (dval > ((double)bitmapThresholdFor8bpsPreviewBitmap)) { XPutPixel(*image, (j>>1), i, 1); } } else { byte_data = data; } break; default: /* should not get here */ break; } } } if (cmdLineDosEpsFilter && cmdLinePreviewOnly) { if (num_nibbles & 0x1) { DumpXBmByte(stdout, num_nibbles, image_h, j, i, byte_data, &out_byte_count); } } } if (fgets(line, line_sz, fp) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PREVIEW_BMP_IN_EPS), file_name); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(line); if (*bitmap != None) { XFreePixmap(mainDisplay, *bitmap); *bitmap = None; } if (*image != NULL) { XDestroyImage(*image); *image = NULL; } return FALSE; } if (cmdLineDosEpsFilter && cmdLinePreviewOnly) { } else { XPutImage(mainDisplay,*bitmap,xbmGC,*image,0,0,0,0,image_w,image_h); } free(line); return TRUE; } static void AddLine(s) char *s; { struct EPSLineRec *line_ptr; line_ptr = (struct EPSLineRec *)malloc(sizeof(struct EPSLineRec)); if (line_ptr == NULL) FailAllocMessage(); line_ptr->s = s; line_ptr->next = NULL; line_ptr->prev = botLine; if (botLine == NULL) { topLine = line_ptr; } else { botLine->next = line_ptr; } botLine = line_ptr; numLines++; } static unsigned long ReadDoubleWord(buf) char *buf; { unsigned long lval, total=0L; unsigned char *c_ptr=(unsigned char *)buf; lval = (unsigned long)(*c_ptr++); total += lval; lval = (unsigned long)(*c_ptr++); total += (lval<<8); lval = (unsigned long)(*c_ptr++); total += (lval<<16); lval = (unsigned long)(*c_ptr++); total += (lval<<24); return total; } static int XbmToPreviewBitmap(FP, xbm_fname) FILE *FP; char *xbm_fname; { unsigned int image_w, image_h; int rc, x_hot, y_hot, **data, num_image_bytes_per_row, num_lines; int row, col; Pixmap bitmap; XImage *image; if ((rc=XReadBitmapFile(mainDisplay, mainWindow, xbm_fname, &image_w, &image_h, &bitmap, &x_hot, &y_hot)) != BitmapSuccess) { return FALSE; } image = XGetImage(mainDisplay, bitmap, 0, 0, image_w, image_h, 1, ZPixmap); if (image == NULL) { XFreePixmap(mainDisplay, bitmap); return FALSE; } num_image_bytes_per_row = ((image_w & 0x7) ? (image_w>>3)+1 : (image_w>>3)); num_lines = ((image_w & 0x7) ? (((image_w>>3)+1)<<1) : ((image_w>>3)<<1)); num_lines = ((num_lines & 0x3f) ? (num_lines>>6)+1 : (num_lines>>6)); if ((data=(int**)malloc(image_h*sizeof(int*))) == NULL) { XFreePixmap(mainDisplay, bitmap); XDestroyImage(image); return FailAllocMessage(); } for (row=0; row < image_h; row++) { if ((data[row]=(int*)malloc(num_image_bytes_per_row*sizeof(int))) == NULL) { int i; for (i=0; i < row; i++) free(data[i]); free(data); XFreePixmap(mainDisplay, bitmap); XDestroyImage(image); return FailAllocMessage(); } else { for (col=0; col<num_image_bytes_per_row; col++) { data[row][col] = 0; } } } /* do not translate -- program constants */ fprintf(FP, "%%!\n"); fprintf(FP, "%%%%BeginPreview: %1d %1d 1 %1d\n", image_w, image_h, num_lines*image_h); for (row=0; row < image_h; row++) { for (col=0; col < image_w; col++) { if (XGetPixel(image, col, row) != 0) { data[row][col>>3] |= (1<<(7 - (col & 0x7))); } } } for (row=0; row < image_h; row++) { int byte_count=0; fprintf(FP, "%% "); for (col=0; col < num_image_bytes_per_row; col++) { if (byte_count++ == 32) { byte_count = 1; fprintf(FP, "\n%% "); } fprintf(FP, "%c", hexValue[(data[row][col]>>4) & 0xf]); fprintf(FP, "%c", hexValue[data[row][col] & 0xf]); } fprintf(FP, "\n"); } fprintf(FP, "%%%%EndImage\n"); fprintf(FP, "%%%%EndPreview\n"); for (row=0; row < image_h; row++) free(data[row]); free(data); XDestroyImage(image); XFreePixmap(mainDisplay, bitmap); return TRUE; } static int ErrorInConvertTiffToXbm(fp, tiff_fp, xbm_fp, fname) FILE *fp, *tiff_fp, *xbm_fp; char *fname; { if (fp != NULL) fclose(fp); if (tiff_fp != NULL) fclose(tiff_fp); if (xbm_fp != NULL) fclose(xbm_fp); if (fname != NULL) { if (writeFileFailed) { FailToWriteFileMessage(fname); } unlink(fname); } return FALSE; } static int ConvertTiffToXbm(fp, tiff_offset, tiff_sz, xbm_fname, xbm_sz) FILE *fp; int tiff_offset, tiff_sz, xbm_sz; char *xbm_fname; { FILE *tiff_fp=NULL, *xbm_fp=NULL, *pfp; int bytes_to_read, bytes_read; char tiff_fname[MAXPATHLENGTH+1]; char cmd[(MAXSTRING<<1)+1]; *tiff_fname = *xbm_fname = '\0'; /* extract TIFF into a file */ if (fseek(fp, tiff_offset, SEEK_SET) != 0) { return ErrorInConvertTiffToXbm(fp, NULL, NULL, NULL); } if (MkTempFile(tiff_fname, sizeof(tiff_fname), tmpDir, TOOL_NAME) == NULL) { return ErrorInConvertTiffToXbm(fp, NULL, NULL, NULL); } /* do not translate -- program constants */ if ((tiff_fp=fopen(tiff_fname, "w")) == NULL) { return ErrorInConvertTiffToXbm(fp, NULL, NULL, NULL); } while (tiff_sz > 0) { bytes_to_read = min(tiff_sz, sizeof(gszMsgBox)); if (bytes_to_read != (int)fread(gszMsgBox, sizeof(char), bytes_to_read, fp)) { return ErrorInConvertTiffToXbm(fp, tiff_fp, NULL, tiff_fname); } if ((int)fwrite(gszMsgBox, sizeof(char), bytes_to_read, tiff_fp) <= 0) { writeFileFailed = TRUE; return ErrorInConvertTiffToXbm(fp, tiff_fp, NULL, tiff_fname); } tiff_sz -= bytes_to_read; } fclose(tiff_fp); tiff_fp = NULL; /* convert TIFF to XBM */ if (MkTempFile(xbm_fname, xbm_sz, tmpDir, TOOL_NAME) == NULL) { return ErrorInConvertTiffToXbm(fp, NULL, NULL, NULL); } if (!tiffToXbmCmdInitialized) { strcpy(tiffToXbmCmd, "tifftopnm %s | pgmtopbm | pbmtoxbm"); } sprintf(cmd, tiffToXbmCmd, tiff_fname); if (!FindProgramInPath(cmd, NULL, FALSE)) { return ErrorInConvertTiffToXbm(fp, NULL, NULL, NULL); } if ((xbm_fp=fopen(xbm_fname, "w")) == NULL) { return ErrorInConvertTiffToXbm(fp, NULL, NULL, NULL); } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), cmd); SetStringStatus(gszMsgBox); if (mainDisplay != NULL) XSync(mainDisplay, False); if ((pfp=(FILE*)popen(cmd,"r")) == NULL) { unlink(tiff_fname); return ErrorInConvertTiffToXbm(fp, NULL, xbm_fp, xbm_fname); } while ((bytes_read=(int)fread(gszMsgBox, sizeof(char), sizeof(gszMsgBox), pfp)) > 0) { if ((int)fwrite(gszMsgBox, sizeof(char), bytes_read, xbm_fp) <= 0) { writeFileFailed = TRUE; break; } } pclose(pfp); SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); fclose(xbm_fp); xbm_fp = NULL; unlink(tiff_fname); *tiff_fname = '\0'; if (writeFileFailed) { return ErrorInConvertTiffToXbm(fp, NULL, xbm_fp, xbm_fname); } return TRUE; } static FILE *ErrorInGetTiffEPSIInfo(fp, eps_fp, fname) FILE *fp, *eps_fp; char *fname; { if (fp != NULL) fclose(fp); if (eps_fp != NULL) fclose(eps_fp); if (fname != NULL) { if (writeFileFailed) { FailToWriteFileMessage(fname); } unlink(fname); } return NULL; } static FILE *GetTiffEPSIInfo(fp, pszEPS, file_buf_sz, pnPreviewOK) FILE *fp; char *pszEPS; int file_buf_sz, *pnPreviewOK; { int bytes_to_read=0x1e, tiff_sz, tiff_offset, eps_sz; int need_to_check_ps=TRUE; char buf[0x20], xbm_fname[MAXPATHLENGTH+1]; FILE *eps_fp=NULL; writeFileFailed = FALSE; *xbm_fname = '\0'; *pszEPS = '\0'; rewind(fp); if (fread(buf, sizeof(char), bytes_to_read, fp) != bytes_to_read) { return ErrorInGetTiffEPSIInfo(fp, eps_fp, NULL); } eps_sz = ReadDoubleWord(&buf[0x08]); tiff_offset = ReadDoubleWord(&buf[0x14]); tiff_sz = ReadDoubleWord(&buf[0x18]); if (cmdLineDosEpsFilter) { if (cmdLinePreviewOnly) { FILE *xbm_fp=NULL; int bytes_read=0; *pnPreviewOK = ConvertTiffToXbm(fp, tiff_offset, tiff_sz, xbm_fname, sizeof(xbm_fname)); if (fseek(fp, 0x1e, SEEK_SET) != 0) { return ErrorInGetTiffEPSIInfo(fp, NULL, NULL); } if ((xbm_fp=fopen(xbm_fname,"r")) == NULL) { unlink(xbm_fname); *xbm_fname = '\0'; return ErrorInGetTiffEPSIInfo(fp, NULL, NULL); } while ((bytes_read=(int)fread(gszMsgBox, sizeof(char), sizeof(gszMsgBox), xbm_fp)) > 0) { if ((int)fwrite(gszMsgBox, sizeof(char), bytes_read, stdout) <= 0) { writeFileFailed = TRUE; break; } } fclose(xbm_fp); if (writeFileFailed) { fprintf(stderr, TgLoadString(STID_FAIL_TO_WRITE_TO_STDOUT)); } unlink(xbm_fname); *xbm_fname = '\0'; return ((FILE*)TRUE); } else { *pnPreviewOK = TRUE; if (fseek(fp, 0x1e, SEEK_SET) != 0) { return ErrorInGetTiffEPSIInfo(fp, NULL, NULL); } } } else { *pnPreviewOK = ConvertTiffToXbm(fp, tiff_offset, tiff_sz, xbm_fname, sizeof(xbm_fname)); if (fseek(fp, 0x1e, SEEK_SET) != 0) { return ErrorInGetTiffEPSIInfo(fp, NULL, NULL); } if (MkTempFile(pszEPS, file_buf_sz, tmpDir, TOOL_NAME) == NULL) { return ErrorInGetTiffEPSIInfo(fp, NULL, NULL); } if ((eps_fp=fopen(pszEPS, "w")) == NULL) { return ErrorInGetTiffEPSIInfo(fp, NULL, NULL); } if (*pnPreviewOK && !XbmToPreviewBitmap(eps_fp, xbm_fname)) { *pnPreviewOK = FALSE; } unlink(xbm_fname); *xbm_fname = '\0'; } /* copy the EPS content from the original file to the new EPS file */ while (eps_sz > 0) { bytes_to_read = min(eps_sz, sizeof(gszMsgBox)); if (bytes_to_read != (int)fread(gszMsgBox, sizeof(char), bytes_to_read, fp)) { return ErrorInGetTiffEPSIInfo(fp, eps_fp, pszEPS); } if (need_to_check_ps) { need_to_check_ps = FALSE; if (!(bytes_to_read>=2 && gszMsgBox[0]=='%' && gszMsgBox[1]=='!')) { fclose(fp); fclose(eps_fp); unlink(pszEPS); return NULL; } } if (cmdLineDosEpsFilter) { if ((int)fwrite(gszMsgBox, sizeof(char), bytes_to_read, stdout) <= 0) { writeFileFailed = TRUE; return ErrorInGetTiffEPSIInfo(fp, eps_fp, pszEPS); } } else { if ((int)fwrite(gszMsgBox, sizeof(char), bytes_to_read, eps_fp) <= 0) { writeFileFailed = TRUE; return ErrorInGetTiffEPSIInfo(fp, eps_fp, pszEPS); } } eps_sz -= bytes_to_read; } if (fp != NULL) fclose(fp); if (eps_fp != NULL) fclose(eps_fp); if (cmdLineDosEpsFilter) { return ((FILE*)TRUE); } return fopen(pszEPS, "r"); } static void GetEPSFullPath(file_name, full_path, buf_sz) char *file_name, *full_path; int buf_sz; { if (*file_name == DIR_SEP) { UtilStrCpyN(full_path, buf_sz, file_name); } else { char *c_ptr=NULL; if (PRTGIF && !cmdLineOpenDisplay && *cmdLineOpenFile != '\0') { UtilStrCpyN(full_path, buf_sz, cmdLineOpenFile); } else if (*scanFileFullPath == DIR_SEP) { UtilStrCpyN(full_path, buf_sz, scanFileFullPath); } else { sprintf(full_path, "%s%c%s", curDir, DIR_SEP, scanFileFullPath); } if ((c_ptr=UtilStrRChr(full_path, (int)DIR_SEP)) != NULL) { strcpy(++c_ptr, file_name); } else { /* Umm... this should not happen */ UtilStrCpyN(full_path, buf_sz, file_name); } } } static int ConvertPsToXbm(pszPsPath, pszXbmPath, file_buf_sz) char *pszPsPath, *pszXbmPath; int file_buf_sz; { FILE *pFile=NULL, *pPipe=NULL; char *pszCmd=NULL, szBuf[MAXSTRING]; int bytes_read=0, watch_cursor=watchCursorOnMainWindow; if (MkTempFile(pszXbmPath, file_buf_sz, tmpDir, TOOL_NAME) == NULL) { return FALSE; } pszCmd = (char*)malloc( (strlen(psToXbmCmd)+strlen(pszPsPath)+10)*sizeof(char)); if (pszCmd == NULL) { FailAllocMessage(); return FALSE; } sprintf(pszCmd, psToXbmCmd, pszPsPath); if (!FindProgramInPath(pszCmd, NULL, FALSE)) { free(pszCmd); return FALSE; } if ((pFile=fopen(pszXbmPath,"w")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_FILE_FOR_WRITING), pszXbmPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); return FALSE; } sprintf(gszMsgBox, TgLoadCachedString(CSTID_EXECUTING_GIVEN_PROGRAM), pszCmd); SetStringStatus(gszMsgBox); XSync(mainDisplay, False); if ((pPipe=(FILE*)popen(pszCmd,"r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_EXECUTE_CMD), pszCmd); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); free(pszCmd); fclose(pFile); unlink(pszXbmPath); return FALSE; } if (!watch_cursor) { SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); } writeFileFailed = FALSE; while ((bytes_read=fread(szBuf, sizeof(char), sizeof(szBuf), pPipe)) > 0) { if ((int)fwrite(szBuf, sizeof(char), bytes_read, pFile) <= 0) { writeFileFailed = TRUE; break; } } pclose(pPipe); if (!watch_cursor) { SetDefaultCursor(mainWindow); ShowCursor(); } SetStringStatus(TgLoadCachedString(CSTID_DOTS_DONE)); free(pszCmd); fclose(pFile); if (writeFileFailed) { FailToWriteFileMessage(pszXbmPath); unlink(pszXbmPath); return FALSE; } return TRUE; } static int AutoGeneratePreviewBitmap(pszPsPath, pBitmap, pImage, pnImageW, pnImageH) char *pszPsPath; Pixmap *pBitmap; XImage **pImage; int *pnImageW, *pnImageH; { char xbm_fname[MAXPATHLENGTH+1]; unsigned int tmp_w=0, tmp_h=0; int rc=0, x_hot=0, y_hot=0, empty_image=FALSE, dont_free_orig_bitmap=FALSE; Pixmap orig_bitmap=None; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); SaveStatusStrings(); rc = ConvertPsToXbm(pszPsPath, xbm_fname, sizeof(xbm_fname)); RestoreStatusStrings(); SetDefaultCursor(mainWindow); ShowCursor(); if (!rc) { return FALSE; } SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = XReadBitmapFile(mainDisplay, mainWindow, xbm_fname, &tmp_w, &tmp_h, &orig_bitmap, &x_hot, &y_hot); SetDefaultCursor(mainWindow); ShowCursor(); unlink(xbm_fname); if (rc != BitmapSuccess) { sprintf(gszMsgBox, TgLoadString(STID_CANT_GEN_PREVIEW_FOR_PS), pszPsPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); return FALSE; } *pnImageW = (int)tmp_w; *pnImageH = (int)tmp_h; rc = AutoTrimBitmap(orig_bitmap, pnImageW, pnImageH, pBitmap, pImage, &empty_image, &dont_free_orig_bitmap); if (!dont_free_orig_bitmap) { XFreePixmap(mainDisplay, orig_bitmap); } if (!rc) { if (empty_image) { sprintf(gszMsgBox, TgLoadString(STID_CANT_GEN_PREVIEW_FOR_EMPTY_PS), pszPsPath); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } return FALSE; } return rc; } static int DoMyReadEPSFile(file_name, pn_image_w, pn_image_h, p_bitmap, p_image, pn_num_lines, ppsz_epsflines, pn_epsf_level, pf_llx, pf_lly, pf_urx, pf_ury, psz_write_date) char *file_name; int *pn_image_w, *pn_image_h, *pn_num_lines, *pn_epsf_level; Pixmap *p_bitmap; XImage **p_image; char ***ppsz_epsflines, *psz_write_date; float *pf_llx, *pf_lly, *pf_urx, *pf_ury; { struct EPSLineRec *line_ptr, *next_line; int i; char *line=NULL, *c_ptr, loc_time[MAXSTRING+1]; char tiff_eps_fname[MAXPATHLENGTH+1]; char real_fname[MAXPATHLENGTH+1]; int first_line=TRUE, image_w=0, image_h=0, epsf_level=0; int boundingbox_found=FALSE, preview_found=FALSE, found; int boundingbox_atend=FALSE, tiff_preview_ok=FALSE; int boundingbox_image_w=0, boundingbox_image_h=0; FILE *fp=NULL; struct stat stat_buf; Pixmap bitmap=None; XImage *image=NULL; float llx=0.0, lly=0.0, urx=0.0, ury=0.0; if (!cmdLineDosEpsFilter) { *pn_image_w = *pn_image_h = *pn_epsf_level = 0; *p_bitmap = None; *p_image = NULL; if (pn_num_lines != NULL) *pn_num_lines = 0; if (ppsz_epsflines != NULL) *ppsz_epsflines = NULL; *pn_epsf_level = 0; *pf_llx = llx; *pf_lly = lly; *pf_urx = urx; *pf_ury = ury; *psz_write_date = '\0'; } *real_fname = '\0'; GetEPSFullPath(file_name, real_fname, sizeof(real_fname)); if ((fp=fopen(real_fname, "r")) == NULL) return BitmapOpenFailed; CleanUpLines(); *tiff_eps_fname = '\0'; while ((line=UtilGetALine(fp)) != NULL) { int need_to_free_line=TRUE; if (first_line) { if (line[0] == ((char)0xc5) && line[1] == ((char)0xd0) && line[2] == ((char)0xd3) && line[3] == ((char)0xc6) && line[4] == ((char)0x1e) && line[5] == '\0') { free(line); if (cmdLineDosEpsFilter) { if ((fp=GetTiffEPSIInfo(fp, tiff_eps_fname, sizeof(tiff_eps_fname), &tiff_preview_ok)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_WINEPS_FILE), real_fname); if (PRTGIF || mainWindow==None) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } if (fp != NULL) fclose(fp); if (*tiff_eps_fname != '\0') unlink(tiff_eps_fname); CleanUpLines(); return BitmapFileInvalid; } fp = NULL; return BitmapSuccess; } else if ((fp=GetTiffEPSIInfo(fp, tiff_eps_fname, sizeof(tiff_eps_fname), &tiff_preview_ok)) == NULL || (line=UtilGetALine(fp)) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_FAIL_TO_PARSE_WINEPS_FILE), real_fname); if (PRTGIF || mainWindow==None) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } if (fp != NULL) fclose(fp); if (*tiff_eps_fname != '\0') unlink(tiff_eps_fname); CleanUpLines(); return BitmapFileInvalid; } } else if (cmdLineDosEpsFilter && !cmdLinePreviewOnly) { printf("%s\n", line); free(line); while ((line=UtilGetALine(fp)) != NULL) { printf("%s\n", line); free(line); } fclose(fp); return BitmapSuccess; } first_line = FALSE; if (line[0] != '%' || line[1] != '!') { free(line); fclose(fp); if (*tiff_eps_fname != '\0') unlink(tiff_eps_fname); CleanUpLines(); return BitmapFileInvalid; } if (cmdLineDosEpsFilter) { if (!cmdLinePreviewOnly) { printf("%s\n", line); } } else { AddLine(line); } need_to_free_line = FALSE; } else if (!cmdLineDosEpsFilter && (!boundingbox_found || boundingbox_atend) && strncmp(line, "%%BoundingBox:", 14) == 0) { if (sscanf(&(line[14]), "%f %f %f %f", &llx, &lly, &urx, &ury) == 4) { boundingbox_found = TRUE; boundingbox_image_w = abs(round(urx-llx)); boundingbox_image_h = abs(round(ury-lly)); } else if (!boundingbox_found) { c_ptr = FindChar((int)'(', &(line[14])); if (strncmp(c_ptr, "atend)", 6) == 0) { boundingbox_atend = TRUE; } } } else if (!(cmdLineDosEpsFilter && !cmdLinePreviewOnly) && !preview_found && strncmp(line, "%%BeginPreview:", 15) == 0) { int bps=1; char *preview_line=NULL; /* * The 4th argument to %%BeginPreview is the number of lines * in the preview image. It's probably a good idea * to handle it or have a way not to read beyond * %%EndImage or %%EndPreview. */ if (sscanf(&(line[15]), "%d %d %d", &image_w, &image_h, &bps) != 3) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PREVIEW_BOX_IN_EPS), real_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (need_to_free_line) free(line); fclose(fp); if (*tiff_eps_fname != '\0') unlink(tiff_eps_fname); CleanUpLines(); return BitmapFileInvalid; } else { switch (bps) { case 1: break; case 8: break; default: sprintf(gszMsgBox, TgLoadString(STID_GIVEN_BPS_PREVIEW_NOT_SUP), bps); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (need_to_free_line) free(line); fclose(fp); if (*tiff_eps_fname != '\0') unlink(tiff_eps_fname); CleanUpLines(); return BitmapFileInvalid; } } if (boundingbox_found) { /* * If the width and height information in the boundingbox and * the preview bitmap are differ only by one, we consider * this a round-off error and adjust the boundingbox so * that they become identical! */ int diff=0; diff = image_w - boundingbox_image_w; if (diff == 1 || diff == (-1)) { if (urx >= llx) { urx += (float)diff; } else { urx -= (float)diff; } } diff = image_h - boundingbox_image_h; if (diff == 1 || diff == (-1)) { if (ury >= lly) { ury += (float)diff; } else { ury -= (float)diff; } } } preview_found = TRUE; if (!ReadPreviewBitmap(fp, real_fname, image_w, image_h, bps, &bitmap, &image)) { /* error message already displayed in ReadPreviewBitmap() */ if (need_to_free_line) free(line); fclose(fp); if (*tiff_eps_fname != '\0') unlink(tiff_eps_fname); CleanUpLines(); return BitmapFileInvalid; } found = FALSE; while ((preview_line=UtilGetALine(fp)) != NULL) { if (strncmp(preview_line, "%%EndPreview", 12) == 0) { found = TRUE; free(preview_line); break; } free(preview_line); } if (!found) { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PREVIEW_BOX_IN_EPS), real_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (need_to_free_line) free(line); if (bitmap != None) { XFreePixmap(mainDisplay, bitmap); bitmap = None; } if (image != NULL) { XDestroyImage(image); image = NULL; } fclose(fp); if (*tiff_eps_fname != '\0') unlink(tiff_eps_fname); CleanUpLines(); return BitmapFileInvalid; } } else { if (line[0] == '%' && line[1] == '!') epsf_level++; if (line[0] == '%' && line[1] == '%' && line[2] != '%') { /* Actaully, need to check DCS conformance! */ } else if (!stripEPSComments || line[0] != '%') { if (cmdLineDosEpsFilter) { if (!cmdLinePreviewOnly) { printf("%s\n", line); } } else { AddLine(line); } need_to_free_line = FALSE; } } if (need_to_free_line) free(line); } if (fp != NULL) fclose(fp); if (*tiff_eps_fname != '\0') unlink(tiff_eps_fname); if (!cmdLineDosEpsFilter) { if (!boundingbox_found) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_BBOX_IN_GIVEN_FILE), real_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); if (bitmap != None) { XFreePixmap(mainDisplay, bitmap); bitmap = None; } if (image != NULL) { XDestroyImage(image); image = NULL; } CleanUpLines(); return BitmapFileInvalid; } if (*tiff_eps_fname != '\0' && !tiff_preview_ok) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_CONVERT_WINEPS_PREVIEW), real_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } if (autoEPSPreviewBitmap && image == NULL && bitmap == None && !preview_found && !(*tiff_eps_fname != '\0' && tiff_preview_ok)) { if (AutoGeneratePreviewBitmap(real_fname, &bitmap, &image, &image_w, &image_h)) { } } if (stat(real_fname, &stat_buf) == 0) { strcpy(loc_time, ctime (&(stat_buf.st_mtime))); loc_time[24] = '\0'; } else { /* do not translate -- program constants */ strcpy(loc_time, "(unknown)"); } *pn_image_w = image_w; *pn_image_h = image_h; *p_bitmap = bitmap; *p_image = image; if (pn_num_lines != NULL) *pn_num_lines = numLines; if (ppsz_epsflines != NULL) { *ppsz_epsflines = (char**)malloc(numLines*sizeof(char*)); if (*ppsz_epsflines == NULL) FailAllocMessage(); } for (i=0, line_ptr=topLine; line_ptr != NULL; line_ptr = next_line, i++) { next_line = line_ptr->next; if (ppsz_epsflines != NULL) { (*ppsz_epsflines)[i] = UtilStrDup(line_ptr->s); if ((*ppsz_epsflines)[i] == NULL) FailAllocMessage(); } free(line_ptr->s); free(line_ptr); } *pn_epsf_level = epsf_level; *pf_llx = llx; *pf_lly = lly; *pf_urx = urx; *pf_ury = ury; strcpy(psz_write_date, loc_time); } else { for (i=0, line_ptr=topLine; line_ptr != NULL; line_ptr = next_line, i++) { next_line = line_ptr->next; free(line_ptr->s); free(line_ptr); } } topLine = botLine = NULL; numLines = 0; return BitmapSuccess; } int MyReadEPSFile(file_name, image_w, image_h, bitmap, image, num_lines, epsflines, epsf_level, llx, lly, urx, ury, write_date) char *file_name; int *image_w, *image_h, *num_lines, *epsf_level; Pixmap *bitmap; XImage **image; char ***epsflines, *write_date; float *llx, *lly, *urx, *ury; { int rc; SaveStatusStrings(); rc = DoMyReadEPSFile(file_name, image_w, image_h, bitmap, image, num_lines, epsflines, epsf_level, llx, lly, urx, ury, write_date); RestoreStatusStrings(); return rc; } static FILE *JustGetTiffEPSIInfo(fp, pszEPS, file_buf_sz) FILE *fp; char *pszEPS; int file_buf_sz; { int bytes_to_read=0x1e, eps_sz, need_to_check_ps=TRUE; char buf[0x20]; FILE *eps_fp=NULL; writeFileFailed = FALSE; *pszEPS = '\0'; rewind(fp); if (fread(buf, sizeof(char), bytes_to_read, fp) != bytes_to_read) { fclose(fp); fclose(eps_fp); return NULL; } eps_sz = ReadDoubleWord(&buf[0x08]); if (MkTempFile(pszEPS, file_buf_sz, tmpDir, TOOL_NAME) == NULL) { fclose(fp); unlink(pszEPS); return NULL; } if ((eps_fp=fopen(pszEPS, "w")) == NULL) { fclose(fp); unlink(pszEPS); return NULL; } /* copy the EPS content from the original file to the new EPS file */ while (eps_sz > 0) { bytes_to_read = min(eps_sz, sizeof(gszMsgBox)); if (bytes_to_read != (int)fread(gszMsgBox, sizeof(char), bytes_to_read, fp)) { fclose(fp); fclose(eps_fp); unlink(pszEPS); return NULL; } if (need_to_check_ps) { need_to_check_ps = FALSE; if (!(bytes_to_read>=2 && gszMsgBox[0]=='%' && gszMsgBox[1]=='!')) { fclose(fp); fclose(eps_fp); unlink(pszEPS); return NULL; } } if ((int)fwrite(gszMsgBox, sizeof(char), bytes_to_read, eps_fp) <= 0) { writeFileFailed = TRUE; fclose(fp); fclose(eps_fp); unlink(pszEPS); return NULL; } eps_sz -= bytes_to_read; } fclose(fp); fclose(eps_fp); return fopen(pszEPS, "r"); } static int JustReadEPSLines(xbm_ptr) struct XBmRec *xbm_ptr; { struct EPSLineRec *line_ptr, *next_line; int i=0; char *c_ptr, *line, loc_time[MAXSTRING+1]; char tiff_eps_fname[MAXPATHLENGTH+1]; char real_fname[MAXPATHLENGTH+1]; int first_line=TRUE, propagated_eps_status=INVALID; int boundingbox_found=FALSE, preview_found=FALSE, found; int boundingbox_atend=FALSE; float llx, lly, urx, ury; char *file_name=xbm_ptr->filename; FILE *fp=NULL; struct stat stat_buf; *real_fname = '\0'; GetEPSFullPath(file_name, real_fname, sizeof(real_fname)); if ((fp=fopen(real_fname, "r")) == NULL) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_OPEN_EPS_FILE_FOR_READ), real_fname); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); fprintf(stderr, " %s\n", TgLoadString(STID_EPS_OBJ_SKIPPED_FOR_PRINT)); } else { char msg1[MAXSTRING]; sprintf(msg1, " %s", TgLoadString(STID_EPS_OBJ_SKIPPED_FOR_PRINT)); TwoLineMsg(gszMsgBox, msg1); } return FALSE; } if (xbm_ptr->epsflines != NULL) { for (i = 0; i < xbm_ptr->num_epsf_lines; i++) { if (xbm_ptr->epsflines[i] != NULL) { free(xbm_ptr->epsflines[i]); } } free(xbm_ptr->epsflines); xbm_ptr->epsflines = NULL; } CleanUpLines(); *tiff_eps_fname = '\0'; while ((line=UtilGetALine(fp)) != NULL) { int need_to_free_line=TRUE; if (first_line) { if (line[0] == ((char)0xc5) && line[1] == ((char)0xd0) && line[2] == ((char)0xd3) && line[3] == ((char)0xc6) && line[4] == ((char)0x1e)) { free(line); if ((fp=JustGetTiffEPSIInfo(fp, tiff_eps_fname, sizeof(tiff_eps_fname))) == NULL || (line=UtilGetALine(fp)) == NULL) { if (fp != NULL) fclose(fp); if (*tiff_eps_fname != '\0') unlink(tiff_eps_fname); CleanUpLines(); return FALSE; } } first_line = FALSE; if (line[0] != '%' || line[1] != '!') { if (need_to_free_line) free(line); fclose (fp); CleanUpLines(); return FALSE; } AddLine(line); need_to_free_line = FALSE; propagated_eps_status = INVALID; } else if ((!boundingbox_found || boundingbox_atend) && strncmp(line, "%%BoundingBox:", 14) == 0) { if (sscanf(&(line[14]), "%f %f %f %f", &llx, &lly, &urx, &ury) == 4) { boundingbox_found = TRUE; } else if (!boundingbox_found) { c_ptr = FindChar((int)'(', &(line[14])); if (strncmp(c_ptr, "atend)", 6) == 0) { boundingbox_atend = TRUE; } } propagated_eps_status = INVALID; } else if (!preview_found && strncmp(line, "%%BeginPreview:", 15) == 0) { char *preview_line=NULL; preview_found = TRUE; found = FALSE; while ((preview_line=UtilGetALine(fp)) != NULL) { if (strncmp(preview_line, "%%EndPreview", 12) == 0) { found = TRUE; free(preview_line); break; } free(preview_line); } if (!found) { if (PRTGIF) { fprintf(stderr, TgLoadString(STID_INVALID_PREVIEW_BMP_IN_EPS), real_fname); } else { sprintf(gszMsgBox, TgLoadString(STID_INVALID_PREVIEW_BMP_IN_EPS), real_fname); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } free(line); if (need_to_free_line) free(line); fclose(fp); CleanUpLines(); return FALSE; } propagated_eps_status = INVALID; } else if (line[0] == '%' && line[1] == '%' && line[2] != '%') { /* Actaully, need to check DCS conformance! */ if (propagated_eps_status != INVALID && line[2] != '+') { propagated_eps_status = INVALID; } UpdatePropagatedEPSInfo(line, &propagated_eps_status); } else { if (line[0] == '%' && line[1] == '!') { (xbm_ptr->epsf_level)++; } else if (!stripEPSComments || line[0] != '%') { AddLine(line); need_to_free_line = FALSE; } propagated_eps_status = INVALID; } if (need_to_free_line) free(line); } fclose(fp); if (*tiff_eps_fname != '\0') unlink(tiff_eps_fname); if (!boundingbox_found) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_BBOX_IN_GIVEN_FILE), real_fname); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); } CleanUpLines(); return FALSE; } if (stat(real_fname, &stat_buf) == 0) { strcpy(loc_time, ctime(&(stat_buf.st_mtime))); loc_time[24] = '\0'; } else { /* do not translate -- program constants */ strcpy(loc_time, "(unknown)"); } if (strcmp(xbm_ptr->write_date, loc_time) != 0) { sprintf(gszMsgBox, TgLoadString(STID_EPS_FILE_NEWER_THAN_EPS_OBJ), real_fname); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } } xbm_ptr->epsflines = (char**)malloc(numLines*sizeof(char*)); if (xbm_ptr->epsflines == NULL) FailAllocMessage(); xbm_ptr->num_epsf_lines = numLines; for (i=0, line_ptr=topLine; line_ptr != NULL; line_ptr = next_line, i++) { next_line = line_ptr->next; (xbm_ptr->epsflines)[i] = UtilStrDup(line_ptr->s); free(line_ptr->s); free(line_ptr); } topLine = botLine = NULL; numLines = 0; return TRUE; } void DumpEPSObj(FP, ObjPtr) FILE *FP; struct ObjRec *ObjPtr; { int i; float scale=0, llx_psu, lly_psu, urx_psu, ury_psu, x_psu=0, y_psu=0; float w_psu, h_psu, bbox_w_psu, bbox_h_psu, dx_psu, dy_psu, ltx_psu, rby_psu; struct XBmRec *xbm_ptr=ObjPtr->detail.xbm; struct MtrxRec mtrx; int no_rotate=(ObjPtr->ctm==NULL), need_to_free_epsflines=FALSE; /* (ObjPtr->ctm->m[CTM_SIN]== 0 && ObjPtr->ctm->m[CTM_MSIN] == 0); */ if (!xbm_ptr->save_epsf) { if (xbm_ptr->bitmap == None || xbm_ptr->epsflines == NULL) { if (!JustReadEPSLines(xbm_ptr)) { return; } need_to_free_epsflines = TRUE; } else { char loc_time[MAXSTRING+1], real_fname[MAXPATHLENGTH+1]; struct stat stat_buf; *real_fname = '\0'; GetEPSFullPath(xbm_ptr->filename, real_fname, sizeof(real_fname)); if (stat(real_fname, &stat_buf) == 0) { strcpy(loc_time, ctime(&(stat_buf.st_mtime))); loc_time[24] = '\0'; } else { /* do not translate -- program constants */ strcpy(loc_time, "(unknown)"); } if (strcmp(xbm_ptr->write_date, loc_time) != 0) { sprintf(gszMsgBox, TgLoadString(STID_EPS_FILE_NEWER_THAN_EPS_OBJ), xbm_ptr->filename); if (PRTGIF) { fprintf(stderr, "%s\n", gszMsgBox); } else { Msg(gszMsgBox); } } } } /* * psu is PostScript Unit (72 psu/inch) and px be pixel. * scale's unit is psu/px. */ scale = ((float)psDotsPerInch)/((float)PIX_PER_INCH*100.0)*printMag; llx_psu = (float)(((float)xbm_ptr->llx) / 1000.0); lly_psu = (float)(((float)xbm_ptr->lly) / 1000.0); urx_psu = (float)(((float)xbm_ptr->urx) / 1000.0); ury_psu = (float)(((float)xbm_ptr->ury) / 1000.0); if (no_rotate) { w_psu = (float)((float)(ObjPtr->obbox.rbx-ObjPtr->obbox.ltx) * scale); h_psu = (float)((float)(ObjPtr->obbox.rby-ObjPtr->obbox.lty) * scale); } else { w_psu = (float)((float)(ObjPtr->orig_obbox.rbx-ObjPtr->orig_obbox.ltx) * scale); h_psu = (float)((float)(ObjPtr->orig_obbox.rby-ObjPtr->orig_obbox.lty) * scale); } bbox_w_psu = urx_psu - llx_psu; bbox_h_psu = ury_psu - lly_psu; memset(&mtrx, 0, sizeof(struct MtrxRec)); mtrx.image_w = (float)bbox_w_psu; mtrx.image_h = (float)bbox_h_psu; mtrx.w = w_psu; mtrx.h = h_psu; mtrx.rotate = ROTATE0; mtrx.flip = xbm_ptr->flip; CalcTransform(&mtrx); dx_psu = llx_psu*mtrx.m[0][0] + lly_psu*mtrx.m[1][0]; dy_psu = llx_psu*mtrx.m[0][1] + lly_psu*mtrx.m[1][1]; if (no_rotate) { ltx_psu = (float)((float)(ObjPtr->obbox.ltx) * scale); rby_psu = (float)(((float)psDotsPerInch)*psYOff[pageStyle] - ((float)(ObjPtr->obbox.rby) * scale)); x_psu = (mtrx.transformed_w >= 0.0) ? (ltx_psu)-dx_psu : (ltx_psu+w_psu)-dx_psu; y_psu = (mtrx.transformed_h >= 0.0) ? (rby_psu)-dy_psu : (rby_psu+h_psu)-dy_psu; } else { float tmp_dx, tmp_dy; int dx, dy, ltx, rby, x, y, tmp_x, tmp_y; if (llx_psu == 0 && lly_psu == 0) { tmp_dx = dx_psu / scale; tmp_dy = dy_psu / scale; } else { tmp_dx = dx_psu / mtrx.dump_h_scale; /* tmp_dx = llx_psu */ tmp_dy = dy_psu / mtrx.dump_v_scale; /* tmp_dy = lly_psu */ } dx = round(tmp_dx); dy = round(tmp_dy); ltx = ObjPtr->orig_obbox.ltx; rby = ObjPtr->orig_obbox.rby; x = ltx - dx; y = rby + dy; TransformPointThroughCTM(x-ObjPtr->x, y-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); tmp_x += ObjPtr->x; tmp_y += ObjPtr->y; if (llx_psu == 0 && lly_psu == 0) { x_psu = (float)(((float)tmp_x) * scale); y_psu = (float)(((float)psDotsPerInch)*psYOff[pageStyle] - (((float)tmp_y) * scale)); } else { x_psu = (float)(((float)tmp_x) * mtrx.dump_h_scale); y_psu = (float)(((float)psDotsPerInch)*psYOff[pageStyle] - (((float)tmp_y) * mtrx.dump_v_scale)); } } /* do not translate -- program constants */ fprintf(FP, "%% EPS\n"); fprintf(FP, "end\n"); fprintf(FP, "/tgiflevel%1d save def\n", xbm_ptr->epsf_level); fprintf(FP, "/tgifdictcount%1d countdictstack def\n", xbm_ptr->epsf_level); fprintf(FP, "/tgifopcount%1d count 1 sub def\n", xbm_ptr->epsf_level); fprintf(FP, "userdict begin\n"); fprintf(FP, "/showpage {} def\n"); fprintf(FP, "/letter {} def\n"); fprintf(FP, "/legal {} def\n"); fprintf(FP, "/a4 {} def\n"); fprintf(FP, "/setpagedevice {pop} def\n"); fprintf(FP, "/erasepage {} def\n"); fprintf(FP, "/bop-hook {} def\n"); fprintf(FP, "/eop-hook {} def\n"); fprintf(FP, "/start-hook {} def\n"); fprintf(FP, "/end-hook {} def\n"); fprintf(FP, "0 setgray 0 setlinecap 1 setlinewidth\n"); fprintf(FP, "0 setlinejoin 10 setmiterlimit [] 0 setdash newpath\n"); fprintf(FP, "1 %1d %1d div %.3f mul 100 div div dup neg scale\n", psDotsPerInch, PIX_PER_INCH, printMag); fprintf(FP, "%1d %s mul neg %1d %s mul neg translate\n", psDotsPerInch, psXOffStr[pageStyle], psDotsPerInch, psYOffStr[pageStyle]); fprintf(FP, "\n"); if (no_rotate) { fprintf(FP, "%.3f %.3f translate %.3f %.3f scale %1d rotate\n", x_psu, y_psu, mtrx.dump_h_scale, mtrx.dump_v_scale, (-mtrx.degree)); } else { float m[6], ftmp_x, ftmp_y; int abs_ltx=ABS_X(ObjPtr->rotated_obbox[0].x); int abs_lty=ABS_Y(ObjPtr->rotated_obbox[0].y); int tmp_x, tmp_y; ReverseTransformPointThroughCTM(abs_ltx-ObjPtr->x, abs_lty-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); tmp_x += ObjPtr->x; tmp_y += ObjPtr->y; ftmp_x = ((float)tmp_x) - llx_psu; ftmp_y = ((float)tmp_y) - ury_psu; abs_ltx = round(ftmp_x); abs_lty = round(ftmp_y); TransformPointThroughCTM(abs_ltx-ObjPtr->x, abs_lty-ObjPtr->y, ObjPtr->ctm, &tmp_x, &tmp_y); ftmp_x = ((float)tmp_x) + ObjPtr->x; ftmp_y = ((float)tmp_y) + ObjPtr->y; fprintf(FP, "%.3f %.3f translate %.3f %.3f scale %1d rotate\n", x_psu, y_psu, mtrx.dump_h_scale, mtrx.dump_v_scale, (-mtrx.degree)); m[CTM_SX] = ((float)ObjPtr->ctm->m[CTM_SX])/((float)1000.0); m[CTM_SY] = ((float)ObjPtr->ctm->m[CTM_SY])/((float)1000.0); m[CTM_SIN] = ((float)ObjPtr->ctm->m[CTM_SIN])/((float)1000.0); m[CTM_MSIN] = ((float)ObjPtr->ctm->m[CTM_MSIN])/((float)1000.0); fprintf(FP, "[%.3f %.3f %.3f %.3f 0 0] concat\n", m[CTM_SX], -m[CTM_SIN], -m[CTM_MSIN], m[CTM_SY]); } fprintf(FP, "\n"); fprintf(FP, "%%%%BeginDocument: %s\n", xbm_ptr->filename); for (i = 0; i < xbm_ptr->num_epsf_lines; i++) { fprintf(FP, "%s\n", xbm_ptr->epsflines[i]); } fprintf(FP, "%%%%EndDocument\n"); fprintf(FP, "count tgifopcount%1d sub dup 0 gt %s\n", xbm_ptr->epsf_level, "{{pop} repeat} {pop} ifelse"); fprintf(FP, "countdictstack tgifdictcount%1d sub dup 0 gt %s\n", xbm_ptr->epsf_level, "{{end} repeat} {pop} ifelse"); fprintf(FP, "tgiflevel%1d restore\n", xbm_ptr->epsf_level); fprintf(FP, "tgifdict begin\n"); fprintf(FP, "\n"); if (need_to_free_epsflines && xbm_ptr->epsflines != NULL) { for (i=0; i < xbm_ptr->num_epsf_lines; i++) { if (xbm_ptr->epsflines[i] != NULL) { free(xbm_ptr->epsflines[i]); } } if (xbm_ptr->epsflines != NULL) free(xbm_ptr->epsflines); xbm_ptr->num_epsf_lines = 0; xbm_ptr->epsflines = NULL; } } void SetEPSObjCTM(obj_ptr, p_orig_obbox) struct ObjRec *obj_ptr; struct BBRec *p_orig_obbox; { struct XBmRec *xbm_ptr=obj_ptr->detail.xbm; int w=(p_orig_obbox->rbx-p_orig_obbox->ltx); int h=(p_orig_obbox->rby-p_orig_obbox->lty), image_w=0, image_h=0; if (obj_ptr->ctm != NULL) return; if (xbm_ptr->real_type == XBM_XBM) { image_w = xbm_ptr->image_w; image_h = xbm_ptr->image_h; } else { image_w = xbm_ptr->eps_w; image_h = xbm_ptr->eps_h; } if (image_w != w || image_h != h) { float fval=(float)0; struct XfrmMtrxRec ctm; memset(&ctm, 0, sizeof(struct XfrmMtrxRec)); obj_ptr->orig_obbox.ltx = p_orig_obbox->ltx; obj_ptr->orig_obbox.lty = p_orig_obbox->lty; obj_ptr->orig_obbox.rbx = p_orig_obbox->rbx; obj_ptr->orig_obbox.rby = p_orig_obbox->rby; fval = ((float)w)/((float)image_w)*((float)1000.0); ctm.m[CTM_SX] = (double)fval; fval = ((float)h)/((float)image_h)*((float)1000.0); ctm.m[CTM_SY] = (double)fval; obj_ptr->obbox.rbx = obj_ptr->bbox.rbx = p_orig_obbox->ltx+image_w; obj_ptr->obbox.rby = obj_ptr->bbox.rby = p_orig_obbox->lty+image_h; SetCTM(obj_ptr, &ctm); AdjObjBBox(obj_ptr); } } struct ObjRec *CreateEPSObj(FileName, ImageW, ImageH, bitmap, image, num_lines, lines, epsf_level, llx, lly, urx, ury, write_date) char *FileName, **lines, *write_date; int ImageW, ImageH, num_lines, epsf_level; Pixmap bitmap; XImage *image; float *llx, *lly, *urx, *ury; { struct XBmRec *xbm_ptr=NULL; struct ObjRec *obj_ptr=NULL; struct BBRec orig_obbox; int len=strlen(FileName), w=0, h=0; char *name=NULL; name = (char*)malloc((len+1)*sizeof(char)); if (name == NULL) FailAllocMessage(); strcpy(name, FileName); xbm_ptr = (struct XBmRec *)malloc(sizeof(struct XBmRec)); if (xbm_ptr == NULL) FailAllocMessage(); memset(xbm_ptr, 0, sizeof(struct XBmRec)); xbm_ptr->image = image; xbm_ptr->image_w = ImageW; xbm_ptr->image_h = ImageH; xbm_ptr->bitmap = bitmap; xbm_ptr->data = NULL; if (bitmap == None) { xbm_ptr->eps_w = w = ((*urx) >= (*llx)) ? (int)((*urx)-(*llx)) : (int)((*llx)-(*urx)); xbm_ptr->eps_h = h = ((*ury) >= (*lly)) ? (int)((*ury)-(*lly)) : (int)((*lly)-(*ury)); } else { /* same as above! */ xbm_ptr->eps_w = w = ((*urx) >= (*llx)) ? (int)((*urx)-(*llx)) : (int)((*llx)-(*urx)); xbm_ptr->eps_h = h = ((*ury) >= (*lly)) ? (int)((*ury)-(*lly)) : (int)((*lly)-(*ury)); w = ImageW; h = ImageH; } xbm_ptr->fill = objFill; xbm_ptr->flip = xbm_ptr->cached_flip = 0; xbm_ptr->llx = (int)((*llx)*1000.0); xbm_ptr->lly = (int)((*lly)*1000.0); xbm_ptr->urx = (int)((*urx)*1000.0); xbm_ptr->ury = (int)((*ury)*1000.0); xbm_ptr->cached_zoom = 0; xbm_ptr->cached_bitmap = None; xbm_ptr->cached_w = xbm_ptr->cached_h = 0; xbm_ptr->real_type = XBM_EPS; xbm_ptr->filename = name; strcpy(xbm_ptr->write_date, write_date); xbm_ptr->epsflines = lines; xbm_ptr->num_epsf_lines = num_lines; xbm_ptr->epsf_level = epsf_level; xbm_ptr->save_epsf = saveEPSLines; obj_ptr = (struct ObjRec *)malloc(sizeof(struct ObjRec)); if (obj_ptr == NULL) FailAllocMessage(); memset(obj_ptr, 0, sizeof(struct ObjRec)); obj_ptr->bbox.ltx = obj_ptr->obbox.ltx = obj_ptr->x = drawOrigX; obj_ptr->bbox.lty = obj_ptr->obbox.lty = obj_ptr->y = drawOrigY; obj_ptr->bbox.rbx = obj_ptr->obbox.rbx = w + drawOrigX; obj_ptr->bbox.rby = obj_ptr->obbox.rby = h + drawOrigY; obj_ptr->type = OBJ_XBM; obj_ptr->color = colorIndex; if (mainDisplay != NULL) { UtilStrCpyN(obj_ptr->color_str, sizeof(obj_ptr->color_str), colorMenuItems[colorIndex]); } obj_ptr->id = objId++; obj_ptr->dirty = FALSE; obj_ptr->rotation = 0; obj_ptr->locked = FALSE; obj_ptr->detail.xbm = xbm_ptr; obj_ptr->fattr = obj_ptr->lattr = NULL; obj_ptr->ctm = NULL; memcpy(&orig_obbox, &obj_ptr->obbox, sizeof(struct BBRec)); SetEPSObjCTM(obj_ptr, &orig_obbox); return obj_ptr; } void UpdateEPS() { struct SelRec *sel_ptr; int count=0; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (sel_ptr->obj->type == OBJ_XBM && sel_ptr->obj->detail.xbm->real_type == XBM_EPS) { count++; } } if (count == 0) { MsgBox(TgLoadString(STID_NO_TOP_LEVEL_EPS_SELECTED), TOOL_NAME, INFO_MB); return; } HighLightReverse(); StartCompositeCmd(); count = 0; for (sel_ptr=topSel; sel_ptr != NULL; sel_ptr=sel_ptr->next) { if (sel_ptr->obj->type == OBJ_XBM && sel_ptr->obj->detail.xbm->real_type == XBM_EPS) { struct XBmRec *xbm_ptr, *new_xbm_ptr; struct ObjRec *obj_ptr, *new_obj_ptr; char write_date[32], **lines=NULL; int rc, num_lines=0, epsf_level, image_w, image_h, save_epsf; int transformed; float llx, lly, urx, ury; Pixmap bitmap; XImage *image=NULL; obj_ptr = sel_ptr->obj; xbm_ptr = obj_ptr->detail.xbm; transformed = (obj_ptr->ctm!=NULL); save_epsf = xbm_ptr->save_epsf; importingFile = TRUE; SetWatchCursor(drawWindow); SetWatchCursor(mainWindow); rc = MyReadEPSFile(xbm_ptr->filename, &image_w, &image_h, &bitmap, &image, (save_epsf ? &num_lines : NULL), (save_epsf ? &lines : NULL), &epsf_level, &llx, &lly, &urx, &ury, write_date); SetDefaultCursor(mainWindow); ShowCursor(); if (rc != BitmapSuccess) { sprintf(gszMsgBox, TgLoadString(STID_CANNOT_IMPORT_GIVEN_EPS), xbm_ptr->filename); MsgBox(gszMsgBox, TOOL_NAME, INFO_MB); importingFile = FALSE; return; } importingFile = FALSE; PrepareToReplaceAnObj(obj_ptr); if (save_epsf) saveEPSLines = TRUE; new_obj_ptr = CreateEPSObj(xbm_ptr->filename, image_w, image_h, bitmap, image, num_lines, lines, epsf_level, &llx, &lly, &urx, &ury, write_date); saveEPSLines = FALSE; if (!save_epsf && lines != NULL) { int i=0; for (i=0; i < num_lines; i++) { if (lines[i] != NULL) free(lines[i]); } free(lines); } new_obj_ptr->x = obj_ptr->x; new_obj_ptr->y = obj_ptr->y; if (transformed) { new_obj_ptr->obbox.ltx = obj_ptr->orig_obbox.ltx; new_obj_ptr->obbox.lty = obj_ptr->orig_obbox.lty; new_obj_ptr->obbox.rbx = obj_ptr->orig_obbox.rbx; new_obj_ptr->obbox.rby = obj_ptr->orig_obbox.rby; new_obj_ptr->obbox.rby = obj_ptr->orig_obbox.rby; SetCTM(new_obj_ptr, obj_ptr->ctm); AdjObjBBox(new_obj_ptr); } else { new_obj_ptr->bbox.ltx = obj_ptr->bbox.ltx; new_obj_ptr->bbox.lty = obj_ptr->bbox.lty; new_obj_ptr->bbox.rbx = obj_ptr->bbox.rbx; new_obj_ptr->bbox.rby = obj_ptr->bbox.rby; new_obj_ptr->obbox.ltx = obj_ptr->obbox.ltx; new_obj_ptr->obbox.lty = obj_ptr->obbox.lty; new_obj_ptr->obbox.rbx = obj_ptr->obbox.rbx; new_obj_ptr->obbox.rby = obj_ptr->obbox.rby; } new_xbm_ptr = new_obj_ptr->detail.xbm; new_xbm_ptr->flip = xbm_ptr->flip; ReplaceObj(obj_ptr, new_obj_ptr); sel_ptr->obj = new_obj_ptr; RecordReplaceAnObj(new_obj_ptr); FreeObj(obj_ptr); count++; } } EndCompositeCmd(); if (count > 0) { UpdSelBBox(); RedrawAnArea(botObj, selLtX-GRID_ABS_SIZE(1), selLtY-GRID_ABS_SIZE(1), selRbX+GRID_ABS_SIZE(1), selRbY+GRID_ABS_SIZE(1)); SetFileModified(TRUE); justDupped = FALSE; Msg(TgLoadString(STID_EPS_OBJECT_UPDATED)); } HighLightForward(); } �������������������������������������������������������������������������������������������������������������tgif-QPL-4.2.5/rcbox.e������������������������������������������������������������������������������0000644�0000764�0000764�00000004354�11602233312�014255� 0����������������������������������������������������������������������������������������������������ustar �william�������������������������william����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������/* * Author: William Chia-Wei Cheng (bill.cheng@acm.org) * * Copyright (C) 2001-2009, William Chia-Wei Cheng. * * This file may be distributed under the terms of the Q Public License * as defined by Trolltech AS of Norway and appearing in the file * LICENSE.QPL included in the packaging of this file. * * THIS FILE IS PROVIDED AS IS WITH NO WARRANTY OF ANY KIND, INCLUDING * THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR * PURPOSE. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING * FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * * @(#)$Header: /mm2/home/cvs/bc-src/tgif/rcbox.e,v 1.7 2011/06/09 15:55:15 cvsps Exp $ */ #ifndef _RCBOX_E_ #define _RCBOX_E_ extern int rcBoxDrawn; #ifdef _INCLUDE_FROM_RCBOX_C_ #undef extern #define extern #endif /*_INCLUDE_FROM_RCBOX_C_*/ extern void SetRCBoxVertex ARGS_DECL((int X1, int Y1, int X2, int Y2, int Radius)); extern void MyRCBox ARGS_DECL((Window, GC, int X1, int Y1, int X2, int Y2, int Radius)); extern void DumpRCBoxObj ARGS_DECL((FILE *, struct ObjRec *)); extern int NeedsToCacheRCBoxObj ARGS_DECL((struct ObjRec *)); extern void CreateRCBoxObj ARGS_DECL((int X1, int Y1, int X2, int Y2, int CreateAbsolute)); extern void DrawRCBoxObj ARGS_DECL((Window, int XOff, int YOff, struct ObjRec *)); extern void DrawRCBox ARGS_DECL((XEvent *)); extern void MakeRCBoxObjFromBoundingBox ARGS_DECL((void)); extern void SaveRCBoxObj ARGS_DECL((FILE *, struct ObjRec *)); extern void ReadRCBoxObj ARGS_DECL((FILE *, char *Inbuf, struct ObjRec **)); extern void SetRCBoxPropMask ARGS_DECL((struct ObjRec *, long *plMask, long *plSkip, struct PropertiesRec *pProp)); extern void FreeRCBoxObj ARGS_DECL((struct ObjRec *)); #ifdef _INCLUDE_FROM_RCBOX_C_ #undef extern #ifndef _NO_RECURSIVE_EXTERN #define extern extern #endif /* ~_NO_RECURSIVE_EXTERN */ #endif /*_INCLUDE_FROM_RCBOX_C_*/ #endif /*_RCBOX_E_*/ ����������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������������